diff --git a/packages/site/.dumirc.ts b/packages/site/.dumirc.ts index a6c81c19cc..cc0653b07e 100644 --- a/packages/site/.dumirc.ts +++ b/packages/site/.dumirc.ts @@ -1,17 +1,20 @@ import { defineConfig } from 'dumi'; const path = require('path'); const env = process.env.NODE_ENV; -const GaodeTokenScript = env === 'production' ? [ - ` window._AMapSecurityConfig = { +const GaodeTokenScript = + env === 'production' + ? [ + ` window._AMapSecurityConfig = { securityJsCode: '2653011adeb04230b3a26cc9a780a800', }`, - 'https://webapi.amap.com/maps?v=2.0&key=f59bcf249433f8b05caaee19f349b3d7', -] : [ - ` window._AMapSecurityConfig = { + 'https://webapi.amap.com/maps?v=2.0&key=f59bcf249433f8b05caaee19f349b3d7', + ] + : [ + ` window._AMapSecurityConfig = { securityJsCode: "290ddc4b0d33be7bc9b354bc6a4ca614" }`, - 'https://webapi.amap.com/maps?v=2.0&key=6f025e700cbacbb0bb866712d20bb35c', -]; + 'https://webapi.amap.com/maps?v=2.0&key=6f025e700cbacbb0bb866712d20bb35c', + ]; export default defineConfig({ locales: [ { id: 'zh', name: '中文' }, diff --git a/packages/site/public/weather/737.b3e3e1f0.async.js b/packages/site/public/weather/737.b3e3e1f0.async.js new file mode 100644 index 0000000000..bf1ace3879 --- /dev/null +++ b/packages/site/public/weather/737.b3e3e1f0.async.js @@ -0,0 +1,8511 @@ +var Jj=Object.defineProperty,eV=Object.defineProperties;var tV=Object.getOwnPropertyDescriptors;var B2=Object.getOwnPropertySymbols;var FM=Object.prototype.hasOwnProperty,BM=Object.prototype.propertyIsEnumerable;var hm=Math.pow,kM=(Ye,ye,A)=>ye in Ye?Jj(Ye,ye,{enumerable:!0,configurable:!0,writable:!0,value:A}):Ye[ye]=A,bd=(Ye,ye)=>{for(var A in ye||(ye={}))FM.call(ye,A)&&kM(Ye,A,ye[A]);if(B2)for(var A of B2(ye))BM.call(ye,A)&&kM(Ye,A,ye[A]);return Ye},dm=(Ye,ye)=>eV(Ye,tV(ye));var NM=(Ye,ye)=>{var A={};for(var R in Ye)FM.call(Ye,R)&&ye.indexOf(R)<0&&(A[R]=Ye[R]);if(Ye!=null&&B2)for(var R of B2(Ye))ye.indexOf(R)<0&&BM.call(Ye,R)&&(A[R]=Ye[R]);return A};var rE=(Ye,ye,A)=>{if(!ye.has(Ye))throw TypeError("Cannot "+A)};var ra=(Ye,ye,A)=>(rE(Ye,ye,"read from private field"),A?A.call(Ye):ye.get(Ye)),Sh=(Ye,ye,A)=>{if(ye.has(Ye))throw TypeError("Cannot add the same private member more than once");ye instanceof WeakSet?ye.add(Ye):ye.set(Ye,A)},Rf=(Ye,ye,A,R)=>(rE(Ye,ye,"write to private field"),R?R.call(Ye,A):ye.set(Ye,A),A),N2=(Ye,ye,A,R)=>({set _(V){Rf(Ye,ye,V,A)},get _(){return ra(Ye,ye,R)}}),gp=(Ye,ye,A)=>(rE(Ye,ye,"access private method"),A);var m_=(Ye,ye,A)=>new Promise((R,V)=>{var y=X=>{try{$(A.next(X))}catch(se){V(se)}},p=X=>{try{$(A.throw(X))}catch(se){V(se)}},$=X=>X.done?R(X.value):Promise.resolve(X.value).then(y,p);$((A=A.apply(Ye,ye)).next())});(self.webpackChunk=self.webpackChunk||[]).push([[737],{95906:function(Ye){"use strict";(function(ye,A){Ye.exports=A()})(this,function(){function ye(ae){var ce=[];return ae.AMapUI&&ce.push(A(ae.AMapUI)),ae.Loca&&ce.push(R(ae.Loca)),Promise.all(ce)}function A(ae){return new Promise(function(ce,le){var De=[];if(ae.plugins)for(var we=0;we=60&&Math.round(We.h)<=240?Qe=st?Math.round(We.h)-y*Me:Math.round(We.h)+y*Me:Qe=st?Math.round(We.h)+y*Me:Math.round(We.h)-y*Me,Qe<0?Qe+=360:Qe>=360&&(Qe-=360),Qe}function Ge(We,Me,st){if(We.h===0&&We.s===0)return We.s;var Qe;return st?Qe=We.s-p*Me:Me===ce?Qe=We.s+p:Qe=We.s+$*Me,Qe>1&&(Qe=1),st&&Me===ae&&Qe>.1&&(Qe=.1),Qe<.06&&(Qe=.06),Number(Qe.toFixed(2))}function ct(We,Me,st){var Qe;return st?Qe=We.v+X*Me:Qe=We.v-se*Me,Qe>1&&(Qe=1),Number(Qe.toFixed(2))}function Ve(We){for(var Me=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},st=[],Qe=(0,V.uA)(We),dr=ae;dr>0;dr-=1){var Kt=De(Qe),Yr=we((0,V.uA)({h:qe(Kt,dr,!0),s:Ge(Kt,dr,!0),v:ct(Kt,dr,!0)}));st.push(Yr)}st.push(we(Qe));for(var hn=1;hn<=ce;hn+=1){var ln=De(Qe),oi=we((0,V.uA)({h:qe(ln,hn),s:Ge(ln,hn),v:ct(ln,hn)}));st.push(oi)}return Me.theme==="dark"?le.map(function(Nn){var $n=Nn.index,_i=Nn.opacity,Qn=we(Ee((0,V.uA)(Me.backgroundColor||"#141414"),(0,V.uA)(st[$n]),_i*100));return Qn}):st}var ut={red:"#F5222D",volcano:"#FA541C",orange:"#FA8C16",gold:"#FAAD14",yellow:"#FADB14",lime:"#A0D911",green:"#52C41A",cyan:"#13C2C2",blue:"#1677FF",geekblue:"#2F54EB",purple:"#722ED1",magenta:"#EB2F96",grey:"#666666"},Xe={},Rt={};Object.keys(ut).forEach(function(We){Xe[We]=Ve(ut[We]),Xe[We].primary=Xe[We][5],Rt[We]=Ve(ut[We],{theme:"dark",backgroundColor:"#141414"}),Rt[We].primary=Rt[We][5]});var gt=Xe.red,Ct=Xe.volcano,tt=Xe.gold,Ne=Xe.orange,bt=Xe.yellow,et=Xe.lime,pt=Xe.green,Ke=Xe.cyan,ft=Xe.blue,wt=Xe.geekblue,Se=Xe.purple,Ft=Xe.magenta,mt=Xe.grey,ot=Xe.grey},78600:function(Ye,ye,A){"use strict";A.d(ye,{E4:function(){return ps},jG:function(){return We},t2:function(){return Jt},ks:function(){return li},bf:function(){return xo},CI:function(){return Zs},fp:function(){return hr},xy:function(){return rc}});var R=A(16514),V=A(35372),y=A(49397),p=A(54131);function $(cn){for(var an=0,Xn,vi=0,to=cn.length;to>=4;++vi,to-=4)Xn=cn.charCodeAt(vi)&255|(cn.charCodeAt(++vi)&255)<<8|(cn.charCodeAt(++vi)&255)<<16|(cn.charCodeAt(++vi)&255)<<24,Xn=(Xn&65535)*1540483477+((Xn>>>16)*59797<<16),Xn^=Xn>>>24,an=(Xn&65535)*1540483477+((Xn>>>16)*59797<<16)^(an&65535)*1540483477+((an>>>16)*59797<<16);switch(to){case 3:an^=(cn.charCodeAt(vi+2)&255)<<16;case 2:an^=(cn.charCodeAt(vi+1)&255)<<8;case 1:an^=cn.charCodeAt(vi)&255,an=(an&65535)*1540483477+((an>>>16)*59797<<16)}return an^=an>>>13,an=(an&65535)*1540483477+((an>>>16)*59797<<16),((an^an>>>15)>>>0).toString(36)}var X=$,se=A(75966),ae=A(77617),ce=A.t(ae,2),le=A(4065),De=A(70780),we=A(61577),Ee=A(22946),qe="%";function Ge(cn){return cn.join(qe)}var ct=function(){function cn(an){(0,we.Z)(this,cn),(0,R.Z)(this,"instanceId",void 0),(0,R.Z)(this,"cache",new Map),this.instanceId=an}return(0,Ee.Z)(cn,[{key:"get",value:function(Xn){return this.opGet(Ge(Xn))}},{key:"opGet",value:function(Xn){return this.cache.get(Xn)||null}},{key:"update",value:function(Xn,vi){return this.opUpdate(Ge(Xn),vi)}},{key:"opUpdate",value:function(Xn,vi){var to=this.cache.get(Xn),zo=vi(to);zo===null?this.cache.delete(Xn):this.cache.set(Xn,zo)}}]),cn}(),Ve=ct,ut=null,Xe="data-token-hash",Rt="data-css-hash",gt="data-cache-path",Ct="__cssinjs_instance__";function tt(){var cn=Math.random().toString(12).slice(2);if(typeof document!="undefined"&&document.head&&document.body){var an=document.body.querySelectorAll("style[".concat(Rt,"]"))||[],Xn=document.head.firstChild;Array.from(an).forEach(function(to){to[Ct]=to[Ct]||cn,to[Ct]===cn&&document.head.insertBefore(to,Xn)});var vi={};Array.from(document.querySelectorAll("style[".concat(Rt,"]"))).forEach(function(to){var zo=to.getAttribute(Rt);if(vi[zo]){if(to[Ct]===cn){var Ia;(Ia=to.parentNode)===null||Ia===void 0||Ia.removeChild(to)}}else vi[zo]=!0})}return new Ve(cn)}var Ne=ae.createContext({hashPriority:"low",cache:tt(),defaultCache:!0}),bt=function(an){var Xn=an.children,vi=_objectWithoutProperties(an,ut),to=React.useContext(Ne),zo=useMemo(function(){var Ia=_objectSpread({},to);Object.keys(vi).forEach(function(fa){var cs=vi[fa];vi[fa]!==void 0&&(Ia[fa]=cs)});var Sa=vi.cache;return Ia.cache=Ia.cache||tt(),Ia.defaultCache=!Sa&&to.defaultCache,Ia},[to,vi],function(Ia,Sa){return!isEqual(Ia[0],Sa[0],!0)||!isEqual(Ia[1],Sa[1],!0)});return React.createElement(Ne.Provider,{value:zo},Xn)},et=Ne,pt=A(13255),Ke=A(42871);function ft(cn,an){if(cn.length!==an.length)return!1;for(var Xn=0;Xn1&&arguments[1]!==void 0?arguments[1]:!1,Ia={map:this.cache};return Xn.forEach(function(Sa){if(!Ia)Ia=void 0;else{var fa;Ia=(fa=Ia)===null||fa===void 0||(fa=fa.map)===null||fa===void 0?void 0:fa.get(Sa)}}),(vi=Ia)!==null&&vi!==void 0&&vi.value&&zo&&(Ia.value[1]=this.cacheCallTimes++),(to=Ia)===null||to===void 0?void 0:to.value}},{key:"get",value:function(Xn){var vi;return(vi=this.internalGet(Xn,!0))===null||vi===void 0?void 0:vi[0]}},{key:"has",value:function(Xn){return!!this.internalGet(Xn)}},{key:"set",value:function(Xn,vi){var to=this;if(!this.has(Xn)){if(this.size()+1>cn.MAX_CACHE_SIZE+cn.MAX_CACHE_OFFSET){var zo=this.keys.reduce(function(cs,Ys){var mu=(0,V.Z)(cs,2),Is=mu[1];return to.internalGet(Ys)[1]0,"[Ant Design CSS-in-JS] Theme should have at least one derivative function."),Ft+=1}return(0,Ee.Z)(cn,[{key:"getDerivativeToken",value:function(Xn){return this.derivatives.reduce(function(vi,to){return to(Xn,vi)},void 0)}}]),cn}(),ot=new wt;function We(cn){var an=Array.isArray(cn)?cn:[cn];return ot.has(an)||ot.set(an,new mt(an)),ot.get(an)}var Me=new WeakMap,st={};function Qe(cn,an){for(var Xn=Me,vi=0;vi3&&arguments[3]!==void 0?arguments[3]:{},zo=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1;if(zo)return cn;var Ia=(0,p.Z)((0,p.Z)({},to),{},(vi={},(0,R.Z)(vi,Xe,an),(0,R.Z)(vi,Rt,Xn),vi)),Sa=Object.keys(Ia).map(function(fa){var cs=Ia[fa];return cs?"".concat(fa,'="').concat(cs,'"'):null}).filter(function(fa){return fa}).join(" ");return"")}var li=function(an){var Xn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";return"--".concat(Xn?"".concat(Xn,"-"):"").concat(an).replace(/([a-z0-9])([A-Z])/g,"$1-$2").replace(/([A-Z]+)([A-Z][a-z0-9]+)/g,"$1-$2").replace(/([a-z])([A-Z0-9])/g,"$1-$2").toLowerCase()},En=function(an,Xn,vi){return Object.keys(an).length?".".concat(Xn).concat(vi!=null&&vi.scope?".".concat(vi.scope):"","{").concat(Object.entries(an).map(function(to){var zo=(0,V.Z)(to,2),Ia=zo[0],Sa=zo[1];return"".concat(Ia,":").concat(Sa,";")}).join(""),"}"):""},or=function(an,Xn,vi){var to={},zo={};return Object.entries(an).forEach(function(Ia){var Sa,fa,cs=(0,V.Z)(Ia,2),Ys=cs[0],mu=cs[1];if(vi!=null&&(Sa=vi.preserve)!==null&&Sa!==void 0&&Sa[Ys])zo[Ys]=mu;else if((typeof mu=="string"||typeof mu=="number")&&!(vi!=null&&(fa=vi.ignore)!==null&&fa!==void 0&&fa[Ys])){var Is,Sl=li(Ys,vi==null?void 0:vi.prefix);to[Sl]=typeof mu=="number"&&!(vi!=null&&(Is=vi.unitless)!==null&&Is!==void 0&&Is[Ys])?"".concat(mu,"px"):String(mu),zo[Ys]="var(".concat(Sl,")")}}),[zo,En(to,Xn,{scope:vi==null?void 0:vi.scope})]},qi=A(70658),Bo=(0,p.Z)({},ce),Mo=Bo.useInsertionEffect,Wi=function(an,Xn,vi){ae.useMemo(an,vi),(0,qi.Z)(function(){return Xn(!0)},vi)},Ii=Mo?function(cn,an,Xn){return Mo(function(){return cn(),an()},Xn)}:Wi,ko=Ii,Fn=(0,p.Z)({},ce),zn=Fn.useInsertionEffect,Un=function(an){var Xn=[],vi=!1;function to(zo){vi||Xn.push(zo)}return ae.useEffect(function(){return vi=!1,function(){vi=!0,Xn.length&&Xn.forEach(function(zo){return zo()})}},an),to},Hi=function(){return function(an){an()}},Ki=typeof zn!="undefined"?Un:Hi,Fo=Ki;function xt(){return!1}var it=!1;function kt(){return it}var ir=xt;if(!1)var Pr,kr;function An(cn,an,Xn,vi,to){var zo=ae.useContext(et),Ia=zo.cache,Sa=[cn].concat((0,y.Z)(an)),fa=Ge(Sa),cs=Fo([fa]),Ys=ir(),mu=function(vu){Ia.opUpdate(fa,function(ml){var ll=ml||[void 0,void 0],Fu=(0,V.Z)(ll,2),Bu=Fu[0],al=Bu===void 0?0:Bu,Ac=Fu[1],$l=Ac,Yu=$l||Xn(),Gu=[al,Yu];return vu?vu(Gu):Gu})};ae.useMemo(function(){mu()},[fa]);var Is=Ia.opGet(fa),Sl=Is[1];return ko(function(){to==null||to(Sl)},function(wl){return mu(function(vu){var ml=(0,V.Z)(vu,2),ll=ml[0],Fu=ml[1];return wl&&ll===0&&(to==null||to(Sl)),[ll+1,Fu]}),function(){Ia.opUpdate(fa,function(vu){var ml=vu||[],ll=(0,V.Z)(ml,2),Fu=ll[0],Bu=Fu===void 0?0:Fu,al=ll[1],Ac=Bu-1;return Ac===0?(cs(function(){(wl||!Ia.opGet(fa))&&(vi==null||vi(al,!1))}),null):[Bu-1,al]})}},[fa]),Sl}var Dn={},Ht="css",Lt=new Map;function je(cn){Lt.set(cn,(Lt.get(cn)||0)+1)}function $e(cn,an){if(typeof document!="undefined"){var Xn=document.querySelectorAll("style[".concat(Xe,'="').concat(cn,'"]'));Xn.forEach(function(vi){if(vi[Ct]===an){var to;(to=vi.parentNode)===null||to===void 0||to.removeChild(vi)}})}}var At=0;function Bt(cn,an){Lt.set(cn,(Lt.get(cn)||0)-1);var Xn=Array.from(Lt.keys()),vi=Xn.filter(function(to){var zo=Lt.get(to)||0;return zo<=0});Xn.length-vi.length>At&&vi.forEach(function(to){$e(to,an),Lt.delete(to)})}var Jt=function(an,Xn,vi,to){var zo=vi.getDerivativeToken(an),Ia=(0,p.Z)((0,p.Z)({},zo),Xn);return to&&(Ia=to(Ia)),Ia},ar="token";function hr(cn,an){var Xn=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},vi=(0,ae.useContext)(et),to=vi.cache.instanceId,zo=vi.container,Ia=Xn.salt,Sa=Ia===void 0?"":Ia,fa=Xn.override,cs=fa===void 0?Dn:fa,Ys=Xn.formatToken,mu=Xn.getComputedToken,Is=Xn.cssVar,Sl=Qe(function(){return Object.assign.apply(Object,[{}].concat((0,y.Z)(an)))},an),wl=Kt(Sl),vu=Kt(cs),ml=Is?Kt(Is):"",ll=An(ar,[Sa,cn.id,wl,vu,ml],function(){var Fu,Bu=mu?mu(Sl,cs,cn):Jt(Sl,cs,cn,Ys),al=(0,p.Z)({},Bu),Ac="";if(Is){var $l=or(Bu,Is.key,{prefix:Is.prefix,ignore:Is.ignore,unitless:Is.unitless,preserve:Is.preserve}),Yu=(0,V.Z)($l,2);Bu=Yu[0],Ac=Yu[1]}var Gu=Yr(Bu,Sa);Bu._tokenKey=Gu,al._tokenKey=Yr(al,Sa);var Sf=(Fu=Is==null?void 0:Is.key)!==null&&Fu!==void 0?Fu:Gu;Bu._themeKey=Sf,je(Sf);var Cl="".concat(Ht,"-").concat(X(Gu));return Bu._hashId=Cl,[Bu,Cl,al,Ac,(Is==null?void 0:Is.key)||""]},function(Fu){Bt(Fu[0]._themeKey,to)},function(Fu){var Bu=(0,V.Z)(Fu,4),al=Bu[0],Ac=Bu[3];if(Is&&Ac){var $l=(0,se.hq)(Ac,X("css-variables-".concat(al._themeKey)),{mark:Rt,prepend:"queue",attachTo:zo,priority:-999});$l[Ct]=to,$l.setAttribute(Xe,al._themeKey)}});return ll}var Gt=function(an,Xn,vi){var to=(0,V.Z)(an,5),zo=to[2],Ia=to[3],Sa=to[4],fa=vi||{},cs=fa.plain;if(!Ia)return null;var Ys=zo._tokenKey,mu=-999,Is={"data-rc-order":"prependQueue","data-rc-priority":"".concat(mu)},Sl=sn(Ia,Sa,Ys,Is,cs);return[mu,Ys,Sl]},Tr=A(79384),nn={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},bn=nn,Bi="-ms-",on="-moz-",dn="-webkit-",ri="comm",Wn="rule",Rn="decl",di="@page",zi="@media",Gi="@import",Lo="@charset",eo="@viewport",ba="@supports",va="@document",Do="@namespace",Ps="@keyframes",Nr="@font-face",fo="@counter-style",hi="@font-feature-values",Yi="@layer",ga=Math.abs,Xi=String.fromCharCode,On=Object.assign;function gi(cn,an){return Ks(cn,0)^45?(((an<<2^Ks(cn,0))<<2^Ks(cn,1))<<2^Ks(cn,2))<<2^Ks(cn,3):0}function ol(cn){return cn.trim()}function ks(cn,an){return(cn=an.exec(cn))?cn[0]:cn}function as(cn,an,Xn){return cn.replace(an,Xn)}function _s(cn,an,Xn){return cn.indexOf(an,Xn)}function Ks(cn,an){return cn.charCodeAt(an)|0}function Ea(cn,an,Xn){return cn.slice(an,Xn)}function hs(cn){return cn.length}function Ju(cn){return cn.length}function Fa(cn,an){return an.push(cn),cn}function dc(cn,an){return cn.map(an).join("")}function el(cn,an){return cn.filter(function(Xn){return!ks(Xn,an)})}function fl(cn,an){for(var Xn="",vi=0;vi0?Ks(Wr,--lu):0,dl--,Pn===10&&(dl=1,Rl--),Pn}function un(){return Pn=lu<_c?Ks(Wr,lu++):0,dl++,Pn===10&&(dl=1,Rl++),Pn}function Zi(){return Ks(Wr,lu)}function ho(){return lu}function Na(cn,an){return Ea(Wr,cn,an)}function mn(cn){switch(cn){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function Lr(cn){return Rl=dl=1,_c=hs(Wr=cn),lu=0,[]}function yr(cn){return Wr="",cn}function Mr(cn){return ol(Na(lu-1,Mi(cn===91?cn+2:cn===40?cn+1:cn)))}function Zr(cn){return yr(In(Lr(cn)))}function Vn(cn){for(;(Pn=Zi())&&Pn<33;)un();return mn(cn)>2||mn(Pn)>3?"":" "}function In(cn){for(;un();)switch(mn(Pn)){case 0:append(ro(lu-1),cn);break;case 2:append(Mr(Pn),cn);break;default:append(from(Pn),cn)}return cn}function Kn(cn,an){for(;--an&&un()&&!(Pn<48||Pn>102||Pn>57&&Pn<65||Pn>70&&Pn<97););return Na(cn,ho()+(an<6&&Zi()==32&&un()==32))}function Mi(cn){for(;un();)switch(Pn){case cn:return lu;case 34:case 39:cn!==34&&cn!==39&&Mi(Pn);break;case 40:cn===41&&Mi(cn);break;case 92:un();break}return lu}function so(cn,an){for(;un()&&cn+Pn!==47+10;)if(cn+Pn===42+42&&Zi()===47)break;return"/*"+Na(an,lu-1)+"*"+Xi(cn===47?cn:un())}function ro(cn){for(;!mn(Zi());)un();return Na(cn,lu)}function Ho(cn){return yr(ya("",null,null,null,[""],cn=Lr(cn),0,[0],cn))}function ya(cn,an,Xn,vi,to,zo,Ia,Sa,fa){for(var cs=0,Ys=0,mu=Ia,Is=0,Sl=0,wl=0,vu=1,ml=1,ll=1,Fu=0,Bu="",al=to,Ac=zo,$l=vi,Yu=Bu;ml;)switch(wl=Fu,Fu=un()){case 40:if(wl!=108&&Ks(Yu,mu-1)==58){_s(Yu+=as(Mr(Fu),"&","&\f"),"&\f",ga(cs?Sa[cs-1]:0))!=-1&&(ll=-1);break}case 34:case 39:case 91:Yu+=Mr(Fu);break;case 9:case 10:case 13:case 32:Yu+=Vn(wl);break;case 92:Yu+=Kn(ho()-1,7);continue;case 47:switch(Zi()){case 42:case 47:Fa(lo(so(un(),ho()),an,Xn,fa),fa);break;default:Yu+="/"}break;case 123*vu:Sa[cs++]=hs(Yu)*ll;case 125*vu:case 59:case 0:switch(Fu){case 0:case 125:ml=0;case 59+Ys:ll==-1&&(Yu=as(Yu,/\f/g,"")),Sl>0&&hs(Yu)-mu&&Fa(Sl>32?No(Yu+";",vi,Xn,mu-1,fa):No(as(Yu," ","")+";",vi,Xn,mu-2,fa),fa);break;case 59:Yu+=";";default:if(Fa($l=gs(Yu,an,Xn,cs,Ys,to,Sa,Bu,al=[],Ac=[],mu,zo),zo),Fu===123)if(Ys===0)ya(Yu,an,$l,$l,al,zo,mu,Sa,Ac);else switch(Is===99&&Ks(Yu,3)===110?100:Is){case 100:case 108:case 109:case 115:ya(cn,$l,$l,vi&&Fa(gs(cn,$l,$l,0,0,to,Sa,Bu,to,al=[],mu,Ac),Ac),to,Ac,mu,Sa,vi?al:Ac);break;default:ya(Yu,$l,$l,$l,[""],Ac,0,Sa,Ac)}}cs=Ys=Sl=0,vu=ll=1,Bu=Yu="",mu=Ia;break;case 58:mu=1+hs(Yu),Sl=wl;default:if(vu<1){if(Fu==123)--vu;else if(Fu==125&&vu++==0&&gn()==125)continue}switch(Yu+=Xi(Fu),Fu*vu){case 38:ll=Ys>0?1:(Yu+="\f",-1);break;case 44:Sa[cs++]=(hs(Yu)-1)*ll,ll=1;break;case 64:Zi()===45&&(Yu+=Mr(un())),Is=Zi(),Ys=mu=hs(Bu=Yu+=ro(ho())),Fu++;break;case 45:wl===45&&hs(Yu)==2&&(vu=0)}}return zo}function gs(cn,an,Xn,vi,to,zo,Ia,Sa,fa,cs,Ys,mu){for(var Is=to-1,Sl=to===0?zo:[""],wl=Ju(Sl),vu=0,ml=0,ll=0;vu0?Sl[Fu]+" "+Bu:as(Bu,/&\f/g,Sl[Fu])))&&(fa[ll++]=al);return Ci(cn,an,Xn,to===0?Wn:Sa,fa,cs,Ys,mu)}function lo(cn,an,Xn,vi){return Ci(cn,an,Xn,ri,Xi(gr()),Ea(cn,2,-2),0,vi)}function No(cn,an,Xn,vi,to){return Ci(cn,an,Xn,Rn,Ea(cn,0,vi),Ea(cn,vi+1,-1),vi,to)}function Da(cn,an){var Xn=an.path,vi=an.parentSelectors;devWarning(!1,"[Ant Design CSS-in-JS] ".concat(Xn?"Error in ".concat(Xn,": "):"").concat(cn).concat(vi.length?" Selector: ".concat(vi.join(" | ")):""))}var ta=function(an,Xn,vi){if(an==="content"){var to=/(attr|counters?|url|(((repeating-)?(linear|radial))|conic)-gradient)\(|(no-)?(open|close)-quote/,zo=["normal","none","initial","inherit","unset"];(typeof Xn!="string"||zo.indexOf(Xn)===-1&&!to.test(Xn)&&(Xn.charAt(0)!==Xn.charAt(Xn.length-1)||Xn.charAt(0)!=='"'&&Xn.charAt(0)!=="'"))&&lintWarning("You seem to be using a value for 'content' without quotes, try replacing it with `content: '\"".concat(Xn,"\"'`."),vi)}},Ra=null,ns=function(an,Xn,vi){an==="animation"&&vi.hashId&&Xn!=="none"&&lintWarning("You seem to be using hashed animation '".concat(Xn,"', in which case 'animationName' with Keyframe as value is recommended."),vi)},Vo=null;function bs(cn){var an,Xn=((an=cn.match(/:not\(([^)]*)\)/))===null||an===void 0?void 0:an[1])||"",vi=Xn.split(/(\[[^[]*])|(?=[.#])/).filter(function(to){return to});return vi.length>1}function Js(cn){return cn.parentSelectors.reduce(function(an,Xn){return an?Xn.includes("&")?Xn.replace(/&/g,an):"".concat(an," ").concat(Xn):Xn},"")}var Hu=function(an,Xn,vi){var to=Js(vi),zo=to.match(/:not\([^)]*\)/g)||[];zo.length>0&&zo.some(bs)&&lintWarning("Concat ':not' selector not support in legacy browsers.",vi)},Of=null,en=function(an,Xn,vi){switch(an){case"marginLeft":case"marginRight":case"paddingLeft":case"paddingRight":case"left":case"right":case"borderLeft":case"borderLeftWidth":case"borderLeftStyle":case"borderLeftColor":case"borderRight":case"borderRightWidth":case"borderRightStyle":case"borderRightColor":case"borderTopLeftRadius":case"borderTopRightRadius":case"borderBottomLeftRadius":case"borderBottomRightRadius":lintWarning("You seem to be using non-logical property '".concat(an,"' which is not compatible with RTL mode. Please use logical properties and values instead. For more information: https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Logical_Properties."),vi);return;case"margin":case"padding":case"borderWidth":case"borderStyle":if(typeof Xn=="string"){var to=Xn.split(" ").map(function(Sa){return Sa.trim()});to.length===4&&to[1]!==to[3]&&lintWarning("You seem to be using '".concat(an,"' property with different left ").concat(an," and right ").concat(an,", which is not compatible with RTL mode. Please use logical properties and values instead. For more information: https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Logical_Properties."),vi)}return;case"clear":case"textAlign":(Xn==="left"||Xn==="right")&&lintWarning("You seem to be using non-logical value '".concat(Xn,"' of ").concat(an,", which is not compatible with RTL mode. Please use logical properties and values instead. For more information: https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Logical_Properties."),vi);return;case"borderRadius":if(typeof Xn=="string"){var zo=Xn.split("/").map(function(Sa){return Sa.trim()}),Ia=zo.reduce(function(Sa,fa){if(Sa)return Sa;var cs=fa.split(" ").map(function(Ys){return Ys.trim()});return cs.length>=2&&cs[0]!==cs[1]||cs.length===3&&cs[1]!==cs[2]||cs.length===4&&cs[2]!==cs[3]?!0:Sa},!1);Ia&&lintWarning("You seem to be using non-logical value '".concat(Xn,"' of ").concat(an,", which is not compatible with RTL mode. Please use logical properties and values instead. For more information: https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Logical_Properties."),vi)}return;default:}},xn=null,Vi=function(an,Xn,vi){(typeof Xn=="string"&&/NaN/g.test(Xn)||Number.isNaN(Xn))&&lintWarning("Unexpected 'NaN' in property '".concat(an,": ").concat(Xn,"'."),vi)},wi=null,oo=function(an,Xn,vi){vi.parentSelectors.some(function(to){var zo=to.split(",");return zo.some(function(Ia){return Ia.split("&").length>2})})&&lintWarning("Should not use more than one `&` in a selector.",vi)},io=null,Uo="data-ant-cssinjs-cache-path",na="_FILE_STYLE__";function $a(cn){return Object.keys(cn).map(function(an){var Xn=cn[an];return"".concat(an,":").concat(Xn)}).join(";")}var Co,wo=!0;function Pa(cn){var an=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;Co=cn,wo=an}function ss(){if(!Co&&(Co={},(0,Ke.Z)())){var cn=document.createElement("div");cn.className=Uo,cn.style.position="fixed",cn.style.visibility="hidden",cn.style.top="-9999px",document.body.appendChild(cn);var an=getComputedStyle(cn).content||"";an=an.replace(/^"/,"").replace(/"$/,""),an.split(";").forEach(function(to){var zo=to.split(":"),Ia=(0,V.Z)(zo,2),Sa=Ia[0],fa=Ia[1];Co[Sa]=fa});var Xn=document.querySelector("style[".concat(Uo,"]"));if(Xn){var vi;wo=!1,(vi=Xn.parentNode)===null||vi===void 0||vi.removeChild(Xn)}document.body.removeChild(cn)}}function si(cn){return ss(),!!Co[cn]}function Ms(cn){var an=Co[cn],Xn=null;if(an&&(0,Ke.Z)())if(wo)Xn=na;else{var vi=document.querySelector("style[".concat(Rt,'="').concat(Co[cn],'"]'));vi?Xn=vi.innerHTML:delete Co[cn]}return[Xn,an]}var Ns="_skip_check_",Aa="_multi_value_";function qs(cn){var an=fl(Ho(cn),As);return an.replace(/\{%%%\:[^;];}/g,";")}function Eu(cn){return(0,pt.Z)(cn)==="object"&&cn&&(Ns in cn||Aa in cn)}function Cs(cn,an,Xn){if(!an)return cn;var vi=".".concat(an),to=Xn==="low"?":where(".concat(vi,")"):vi,zo=cn.split(",").map(function(Ia){var Sa,fa=Ia.trim().split(/\s+/),cs=fa[0]||"",Ys=((Sa=cs.match(/^\w+/))===null||Sa===void 0?void 0:Sa[0])||"";return cs="".concat(Ys).concat(to).concat(cs.slice(Ys.length)),[cs].concat((0,y.Z)(fa.slice(1))).join(" ")});return zo.join(",")}var su=function cn(an){var Xn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},vi=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{root:!0,parentSelectors:[]},to=vi.root,zo=vi.injectHash,Ia=vi.parentSelectors,Sa=Xn.hashId,fa=Xn.layer,cs=Xn.path,Ys=Xn.hashPriority,mu=Xn.transformers,Is=mu===void 0?[]:mu,Sl=Xn.linters,wl=Sl===void 0?[]:Sl,vu="",ml={};function ll($l){var Yu=$l.getName(Sa);if(!ml[Yu]){var Gu=cn($l.style,Xn,{root:!1,parentSelectors:Ia}),Sf=(0,V.Z)(Gu,1),Cl=Sf[0];ml[Yu]="@keyframes ".concat($l.getName(Sa)).concat(Cl)}}function Fu($l){var Yu=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return $l.forEach(function(Gu){Array.isArray(Gu)?Fu(Gu,Yu):Gu&&Yu.push(Gu)}),Yu}var Bu=Fu(Array.isArray(an)?an:[an]);if(Bu.forEach(function($l){var Yu=typeof $l=="string"&&!to?{}:$l;if(typeof Yu=="string")vu+="".concat(Yu,` +`);else if(Yu._keyframe)ll(Yu);else{var Gu=Is.reduce(function(Sf,Cl){var Df;return(Cl==null||(Df=Cl.visit)===null||Df===void 0?void 0:Df.call(Cl,Sf))||Sf},Yu);Object.keys(Gu).forEach(function(Sf){var Cl=Gu[Sf];if((0,pt.Z)(Cl)==="object"&&Cl&&(Sf!=="animationName"||!Cl._keyframe)&&!Eu(Cl)){var Df=!1,bu=Sf.trim(),Ic=!1;(to||zo)&&Sa?bu.startsWith("@")?Df=!0:bu=Cs(Sf,Sa,Ys):to&&!Sa&&(bu==="&"||bu==="")&&(bu="",Ic=!0);var af=cn(Cl,Xn,{root:Ic,injectHash:Df,parentSelectors:[].concat((0,y.Z)(Ia),[bu])}),zf=(0,V.Z)(af,2),tf=zf[0],kf=zf[1];ml=(0,p.Z)((0,p.Z)({},ml),kf),vu+="".concat(bu).concat(tf)}else{let wc=function(ac,cl){var Us=ac.replace(/[A-Z]/g,function(iu){return"-".concat(iu.toLowerCase())}),vl=cl;!bn[ac]&&typeof vl=="number"&&vl!==0&&(vl="".concat(vl,"px")),ac==="animationName"&&cl!==null&&cl!==void 0&&cl._keyframe&&(ll(cl),vl=cl.getName(Sa)),vu+="".concat(Us,":").concat(vl,";")};var ff,vf=(ff=Cl==null?void 0:Cl.value)!==null&&ff!==void 0?ff:Cl;(0,pt.Z)(Cl)==="object"&&Cl!==null&&Cl!==void 0&&Cl[Aa]&&Array.isArray(vf)?vf.forEach(function(ac){wc(Sf,ac)}):wc(Sf,vf)}})}}),!to)vu="{".concat(vu,"}");else if(fa&&$n()){var al=fa.split(","),Ac=al[al.length-1].trim();vu="@layer ".concat(Ac," {").concat(vu,"}"),al.length>1&&(vu="@layer ".concat(fa,"{%%%:%}").concat(vu))}return[vu,ml]};function Vs(cn,an){return X("".concat(cn.join("%")).concat(an))}function tl(){return null}var Xs="style";function rc(cn,an){var Xn=cn.token,vi=cn.path,to=cn.hashId,zo=cn.layer,Ia=cn.nonce,Sa=cn.clientOnly,fa=cn.order,cs=fa===void 0?0:fa,Ys=ae.useContext(et),mu=Ys.autoClear,Is=Ys.mock,Sl=Ys.defaultCache,wl=Ys.hashPriority,vu=Ys.container,ml=Ys.ssrInline,ll=Ys.transformers,Fu=Ys.linters,Bu=Ys.cache,al=Xn._tokenKey,Ac=[al].concat((0,y.Z)(vi)),$l=Ei,Yu=An(Xs,Ac,function(){var bu=Ac.join("|");if(si(bu)){var Ic=Ms(bu),af=(0,V.Z)(Ic,2),zf=af[0],tf=af[1];if(zf)return[zf,al,tf,{},Sa,cs]}var kf=an(),ff=su(kf,{hashId:to,hashPriority:wl,layer:zo,path:vi.join("-"),transformers:ll,linters:Fu}),vf=(0,V.Z)(ff,2),wc=vf[0],ac=vf[1],cl=qs(wc),Us=Vs(Ac,cl);return[cl,al,Us,ac,Sa,cs]},function(bu,Ic){var af=(0,V.Z)(bu,3),zf=af[2];(Ic||mu)&&Ei&&(0,se.jL)(zf,{mark:Rt})},function(bu){var Ic=(0,V.Z)(bu,4),af=Ic[0],zf=Ic[1],tf=Ic[2],kf=Ic[3];if($l&&af!==na){var ff={mark:Rt,prepend:"queue",attachTo:vu,priority:cs},vf=typeof Ia=="function"?Ia():Ia;vf&&(ff.csp={nonce:vf});var wc=(0,se.hq)(af,tf,ff);wc[Ct]=Bu.instanceId,wc.setAttribute(Xe,al),Object.keys(kf).forEach(function(ac){(0,se.hq)(qs(kf[ac]),"_effect-".concat(ac),ff)})}}),Gu=(0,V.Z)(Yu,3),Sf=Gu[0],Cl=Gu[1],Df=Gu[2];return function(bu){var Ic;if(!ml||$l||!Sl)Ic=ae.createElement(tl,null);else{var af;Ic=ae.createElement("style",(0,Tr.Z)({},(af={},(0,R.Z)(af,Xe,Cl),(0,R.Z)(af,Rt,Df),af),{dangerouslySetInnerHTML:{__html:Sf}}))}return ae.createElement(ae.Fragment,null,Ic,bu)}}var Ha=function(an,Xn,vi){var to=(0,V.Z)(an,6),zo=to[0],Ia=to[1],Sa=to[2],fa=to[3],cs=to[4],Ys=to[5],mu=vi||{},Is=mu.plain;if(cs)return null;var Sl=zo,wl={"data-rc-order":"prependQueue","data-rc-priority":"".concat(Ys)};return Sl=sn(zo,Ia,Sa,wl,Is),fa&&Object.keys(fa).forEach(function(vu){if(!Xn[vu]){Xn[vu]=!0;var ml=qs(fa[vu]);Sl+=sn(ml,Ia,"_effect-".concat(vu),wl,Is)}}),[Ys,Sa,Sl]},Qs="cssVar",Uu=function(an,Xn){var vi=an.key,to=an.prefix,zo=an.unitless,Ia=an.ignore,Sa=an.token,fa=an.scope,cs=fa===void 0?"":fa,Ys=(0,ae.useContext)(et),mu=Ys.cache.instanceId,Is=Ys.container,Sl=Sa._tokenKey,wl=[].concat((0,y.Z)(an.path),[vi,cs,Sl]),vu=An(Qs,wl,function(){var ml=Xn(),ll=or(ml,vi,{prefix:to,unitless:zo,ignore:Ia,scope:cs}),Fu=(0,V.Z)(ll,2),Bu=Fu[0],al=Fu[1],Ac=Vs(wl,al);return[Bu,al,Ac,vi]},function(ml){var ll=(0,V.Z)(ml,3),Fu=ll[2];Ei&&(0,se.jL)(Fu,{mark:Rt})},function(ml){var ll=(0,V.Z)(ml,3),Fu=ll[1],Bu=ll[2];if(Fu){var al=(0,se.hq)(Fu,Bu,{mark:Rt,prepend:"queue",attachTo:Is,priority:-999});al[Ct]=mu,al.setAttribute(Xe,vi)}});return vu},St=function(an,Xn,vi){var to=(0,V.Z)(an,4),zo=to[1],Ia=to[2],Sa=to[3],fa=vi||{},cs=fa.plain;if(!zo)return null;var Ys=-999,mu={"data-rc-order":"prependQueue","data-rc-priority":"".concat(Ys)},Is=sn(zo,Sa,Ia,mu,cs);return[Ys,Ia,Is]},Zs=Uu,yu,pl=(yu={},(0,R.Z)(yu,Xs,Ha),(0,R.Z)(yu,ar,Gt),(0,R.Z)(yu,Qs,St),yu);function Ku(cn){return cn!==null}function eu(cn,an){var Xn=typeof an=="boolean"?{plain:an}:an||{},vi=Xn.plain,to=vi===void 0?!1:vi,zo=Xn.types,Ia=zo===void 0?["style","token","cssVar"]:zo,Sa=new RegExp("^(".concat((typeof Ia=="string"?[Ia]:Ia).join("|"),")%")),fa=Array.from(cn.cache.keys()).filter(function(Is){return Sa.test(Is)}),cs={},Ys={},mu="";return fa.map(function(Is){var Sl=Is.replace(Sa,"").replace(/%/g,"|"),wl=Is.split("%"),vu=_slicedToArray(wl,1),ml=vu[0],ll=pl[ml],Fu=ll(cn.cache.get(Is)[1],cs,{plain:to});if(!Fu)return null;var Bu=_slicedToArray(Fu,3),al=Bu[0],Ac=Bu[1],$l=Bu[2];return Is.startsWith("style")&&(Ys[Sl]=Ac),[al,$l]}).filter(Ku).sort(function(Is,Sl){var wl=_slicedToArray(Is,1),vu=wl[0],ml=_slicedToArray(Sl,1),ll=ml[0];return vu-ll}).forEach(function(Is){var Sl=_slicedToArray(Is,2),wl=Sl[1];mu+=wl}),mu+=toStyleStr(".".concat(ATTR_CACHE_MAP,'{content:"').concat(serializeCacheMap(Ys),'";}'),void 0,void 0,_defineProperty({},ATTR_CACHE_MAP,ATTR_CACHE_MAP),to),mu}var Qo=function(){function cn(an,Xn){(0,we.Z)(this,cn),(0,R.Z)(this,"name",void 0),(0,R.Z)(this,"style",void 0),(0,R.Z)(this,"_keyframe",!0),this.name=an,this.style=Xn}return(0,Ee.Z)(cn,[{key:"getName",value:function(){var Xn=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return Xn?"".concat(Xn,"-").concat(this.name):this.name}}]),cn}(),ps=Qo;function xl(cn){if(typeof cn=="number")return[[cn],!1];var an=String(cn).trim(),Xn=an.match(/(.*)(!important)/),vi=(Xn?Xn[1]:an).trim().split(/\s+/),to="",zo=0;return[vi.reduce(function(Ia,Sa){if(Sa.includes("(")||Sa.includes(")")){var fa=Sa.split("(").length-1,cs=Sa.split(")").length-1;zo+=fa-cs}return zo===0?(Ia.push(to+Sa),to=""):zo>0&&(to+=Sa),Ia},[]),!!Xn]}function Yl(cn){return cn.notSplit=!0,cn}var ul={inset:["top","right","bottom","left"],insetBlock:["top","bottom"],insetBlockStart:["top"],insetBlockEnd:["bottom"],insetInline:["left","right"],insetInlineStart:["left"],insetInlineEnd:["right"],marginBlock:["marginTop","marginBottom"],marginBlockStart:["marginTop"],marginBlockEnd:["marginBottom"],marginInline:["marginLeft","marginRight"],marginInlineStart:["marginLeft"],marginInlineEnd:["marginRight"],paddingBlock:["paddingTop","paddingBottom"],paddingBlockStart:["paddingTop"],paddingBlockEnd:["paddingBottom"],paddingInline:["paddingLeft","paddingRight"],paddingInlineStart:["paddingLeft"],paddingInlineEnd:["paddingRight"],borderBlock:Yl(["borderTop","borderBottom"]),borderBlockStart:Yl(["borderTop"]),borderBlockEnd:Yl(["borderBottom"]),borderInline:Yl(["borderLeft","borderRight"]),borderInlineStart:Yl(["borderLeft"]),borderInlineEnd:Yl(["borderRight"]),borderBlockWidth:["borderTopWidth","borderBottomWidth"],borderBlockStartWidth:["borderTopWidth"],borderBlockEndWidth:["borderBottomWidth"],borderInlineWidth:["borderLeftWidth","borderRightWidth"],borderInlineStartWidth:["borderLeftWidth"],borderInlineEndWidth:["borderRightWidth"],borderBlockStyle:["borderTopStyle","borderBottomStyle"],borderBlockStartStyle:["borderTopStyle"],borderBlockEndStyle:["borderBottomStyle"],borderInlineStyle:["borderLeftStyle","borderRightStyle"],borderInlineStartStyle:["borderLeftStyle"],borderInlineEndStyle:["borderRightStyle"],borderBlockColor:["borderTopColor","borderBottomColor"],borderBlockStartColor:["borderTopColor"],borderBlockEndColor:["borderBottomColor"],borderInlineColor:["borderLeftColor","borderRightColor"],borderInlineStartColor:["borderLeftColor"],borderInlineEndColor:["borderRightColor"],borderStartStartRadius:["borderTopLeftRadius"],borderStartEndRadius:["borderTopRightRadius"],borderEndStartRadius:["borderBottomLeftRadius"],borderEndEndRadius:["borderBottomRightRadius"]};function Ef(cn,an){var Xn=cn;return an&&(Xn="".concat(Xn," !important")),{_skip_check_:!0,value:Xn}}var sf={visit:function(an){var Xn={};return Object.keys(an).forEach(function(vi){var to=an[vi],zo=ul[vi];if(zo&&(typeof to=="number"||typeof to=="string")){var Ia=xl(to),Sa=(0,V.Z)(Ia,2),fa=Sa[0],cs=Sa[1];zo.length&&zo.notSplit?zo.forEach(function(Ys){Xn[Ys]=Ef(to,cs)}):zo.length===1?Xn[zo[0]]=Ef(to,cs):zo.length===2?zo.forEach(function(Ys,mu){var Is;Xn[Ys]=Ef((Is=fa[mu])!==null&&Is!==void 0?Is:fa[0],cs)}):zo.length===4?zo.forEach(function(Ys,mu){var Is,Sl;Xn[Ys]=Ef((Is=(Sl=fa[mu])!==null&&Sl!==void 0?Sl:fa[mu-2])!==null&&Is!==void 0?Is:fa[0],cs)}):Xn[vi]=to}else Xn[vi]=to}),Xn}},Hf=null,Ul=/url\([^)]+\)|var\([^)]+\)|(\d*\.?\d+)px/g;function Lf(cn,an){var Xn=Math.pow(10,an+1),vi=Math.floor(cn*Xn);return Math.round(vi/10)*10/Xn}var Fc=function(){var an=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},Xn=an.rootValue,vi=Xn===void 0?16:Xn,to=an.precision,zo=to===void 0?5:to,Ia=an.mediaQuery,Sa=Ia===void 0?!1:Ia,fa=function(mu,Is){if(!Is)return mu;var Sl=parseFloat(Is);if(Sl<=1)return mu;var wl=Lf(Sl/vi,zo);return"".concat(wl,"rem")},cs=function(mu){var Is=_objectSpread({},mu);return Object.entries(mu).forEach(function(Sl){var wl=_slicedToArray(Sl,2),vu=wl[0],ml=wl[1];if(typeof ml=="string"&&ml.includes("px")){var ll=ml.replace(Ul,fa);Is[vu]=ll}!unitless[vu]&&typeof ml=="number"&&ml!==0&&(Is[vu]="".concat(ml,"px").replace(Ul,fa));var Fu=vu.trim();if(Fu.startsWith("@")&&Fu.includes("px")&&Sa){var Bu=vu.replace(Ul,fa);Is[Bu]=Is[vu],delete Is[vu]}}),Is};return{visit:cs}},Ol=null,_l={supportModernCSS:function(){return Qn()&&ni()}}},12213:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return Ct}});var R=A(79384),V=A(35372),y=A(16514),p=A(56348),$=A(77617),X=A(92310),se=A.n(X),ae=A(10129),ce=A(48081),le=A(54131),De=A(43963),we=["icon","className","onClick","style","primaryColor","secondaryColor"],Ee={primaryColor:"#333",secondaryColor:"#E6E6E6",calculated:!1};function qe(tt){var Ne=tt.primaryColor,bt=tt.secondaryColor;Ee.primaryColor=Ne,Ee.secondaryColor=bt||(0,De.pw)(Ne),Ee.calculated=!!bt}function Ge(){return(0,le.Z)({},Ee)}var ct=function(Ne){var bt=Ne.icon,et=Ne.className,pt=Ne.onClick,Ke=Ne.style,ft=Ne.primaryColor,wt=Ne.secondaryColor,Se=(0,p.Z)(Ne,we),Ft=$.useRef(),mt=Ee;if(ft&&(mt={primaryColor:ft,secondaryColor:wt||(0,De.pw)(ft)}),(0,De.C3)(Ft),(0,De.Kp)((0,De.r)(bt),"icon should be icon definiton, but got ".concat(bt)),!(0,De.r)(bt))return null;var ot=bt;return ot&&typeof ot.icon=="function"&&(ot=(0,le.Z)((0,le.Z)({},ot),{},{icon:ot.icon(mt.primaryColor,mt.secondaryColor)})),(0,De.R_)(ot.icon,"svg-".concat(ot.name),(0,le.Z)((0,le.Z)({className:et,onClick:pt,style:Ke,"data-icon":ot.name,width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true"},Se),{},{ref:Ft}))};ct.displayName="IconReact",ct.getTwoToneColors=Ge,ct.setTwoToneColors=qe;var Ve=ct;function ut(tt){var Ne=(0,De.H9)(tt),bt=(0,V.Z)(Ne,2),et=bt[0],pt=bt[1];return Ve.setTwoToneColors({primaryColor:et,secondaryColor:pt})}function Xe(){var tt=Ve.getTwoToneColors();return tt.calculated?[tt.primaryColor,tt.secondaryColor]:tt.primaryColor}var Rt=["className","icon","spin","rotate","tabIndex","onClick","twoToneColor"];ut(ae.iN.primary);var gt=$.forwardRef(function(tt,Ne){var bt=tt.className,et=tt.icon,pt=tt.spin,Ke=tt.rotate,ft=tt.tabIndex,wt=tt.onClick,Se=tt.twoToneColor,Ft=(0,p.Z)(tt,Rt),mt=$.useContext(ce.Z),ot=mt.prefixCls,We=ot===void 0?"anticon":ot,Me=mt.rootClassName,st=se()(Me,We,(0,y.Z)((0,y.Z)({},"".concat(We,"-").concat(et.name),!!et.name),"".concat(We,"-spin"),!!pt||et.name==="loading"),bt),Qe=ft;Qe===void 0&&wt&&(Qe=-1);var dr=Ke?{msTransform:"rotate(".concat(Ke,"deg)"),transform:"rotate(".concat(Ke,"deg)")}:void 0,Kt=(0,De.H9)(Se),Yr=(0,V.Z)(Kt,2),hn=Yr[0],ln=Yr[1];return $.createElement("span",(0,R.Z)({role:"img","aria-label":et.name},Ft,{ref:Ne,tabIndex:Qe,onClick:wt,className:st}),$.createElement(Ve,{icon:et,primaryColor:hn,secondaryColor:ln,style:dr}))});gt.displayName="AntdIcon",gt.getTwoToneColor=Xe,gt.setTwoToneColor=ut;var Ct=gt},48081:function(Ye,ye,A){"use strict";var R=A(77617),V=(0,R.createContext)({});ye.Z=V},50555:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return se}});var R=A(79384),V=A(77617),y={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z"}}]},name:"check-circle",theme:"filled"},p=y,$=A(12213),X=function(ce,le){return V.createElement($.Z,(0,R.Z)({},ce,{ref:le,icon:p}))},se=V.forwardRef(X)},43418:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return se}});var R=A(79384),V=A(77617),y={icon:{tag:"svg",attrs:{"fill-rule":"evenodd",viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64c247.4 0 448 200.6 448 448S759.4 960 512 960 64 759.4 64 512 264.6 64 512 64zm127.98 274.82h-.04l-.08.06L512 466.75 384.14 338.88c-.04-.05-.06-.06-.08-.06a.12.12 0 00-.07 0c-.03 0-.05.01-.09.05l-45.02 45.02a.2.2 0 00-.05.09.12.12 0 000 .07v.02a.27.27 0 00.06.06L466.75 512 338.88 639.86c-.05.04-.06.06-.06.08a.12.12 0 000 .07c0 .03.01.05.05.09l45.02 45.02a.2.2 0 00.09.05.12.12 0 00.07 0c.02 0 .04-.01.08-.05L512 557.25l127.86 127.87c.04.04.06.05.08.05a.12.12 0 00.07 0c.03 0 .05-.01.09-.05l45.02-45.02a.2.2 0 00.05-.09.12.12 0 000-.07v-.02a.27.27 0 00-.05-.06L557.25 512l127.87-127.86c.04-.04.05-.06.05-.08a.12.12 0 000-.07c0-.03-.01-.05-.05-.09l-45.02-45.02a.2.2 0 00-.09-.05.12.12 0 00-.07 0z"}}]},name:"close-circle",theme:"filled"},p=y,$=A(12213),X=function(ce,le){return V.createElement($.Z,(0,R.Z)({},ce,{ref:le,icon:p}))},se=V.forwardRef(X)},39694:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return se}});var R=A(79384),V=A(77617),y={icon:{tag:"svg",attrs:{"fill-rule":"evenodd",viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M799.86 166.31c.02 0 .04.02.08.06l57.69 57.7c.04.03.05.05.06.08a.12.12 0 010 .06c0 .03-.02.05-.06.09L569.93 512l287.7 287.7c.04.04.05.06.06.09a.12.12 0 010 .07c0 .02-.02.04-.06.08l-57.7 57.69c-.03.04-.05.05-.07.06a.12.12 0 01-.07 0c-.03 0-.05-.02-.09-.06L512 569.93l-287.7 287.7c-.04.04-.06.05-.09.06a.12.12 0 01-.07 0c-.02 0-.04-.02-.08-.06l-57.69-57.7c-.04-.03-.05-.05-.06-.07a.12.12 0 010-.07c0-.03.02-.05.06-.09L454.07 512l-287.7-287.7c-.04-.04-.05-.06-.06-.09a.12.12 0 010-.07c0-.02.02-.04.06-.08l57.7-57.69c.03-.04.05-.05.07-.06a.12.12 0 01.07 0c.03 0 .05.02.09.06L512 454.07l287.7-287.7c.04-.04.06-.05.09-.06a.12.12 0 01.07 0z"}}]},name:"close",theme:"outlined"},p=y,$=A(12213),X=function(ce,le){return V.createElement($.Z,(0,R.Z)({},ce,{ref:le,icon:p}))},se=V.forwardRef(X)},81664:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return se}});var R=A(79384),V=A(77617),y={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"exclamation-circle",theme:"filled"},p=y,$=A(12213),X=function(ce,le){return V.createElement($.Z,(0,R.Z)({},ce,{ref:le,icon:p}))},se=V.forwardRef(X)},20906:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return se}});var R=A(79384),V=A(77617),y={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm32 664c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V456c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272zm-32-344a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"info-circle",theme:"filled"},p=y,$=A(12213),X=function(ce,le){return V.createElement($.Z,(0,R.Z)({},ce,{ref:le,icon:p}))},se=V.forwardRef(X)},20555:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return se}});var R=A(79384),V=A(77617),y={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"}}]},name:"loading",theme:"outlined"},p=y,$=A(12213),X=function(ce,le){return V.createElement($.Z,(0,R.Z)({},ce,{ref:le,icon:p}))},se=V.forwardRef(X)},86289:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return se}});var R=A(79384),V=A(77617),y={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M847.9 592H152c-4.4 0-8 3.6-8 8v60c0 4.4 3.6 8 8 8h605.2L612.9 851c-4.1 5.2-.4 13 6.3 13h72.5c4.9 0 9.5-2.2 12.6-6.1l168.8-214.1c16.5-21 1.6-51.8-25.2-51.8zM872 356H266.8l144.3-183c4.1-5.2.4-13-6.3-13h-72.5c-4.9 0-9.5 2.2-12.6 6.1L150.9 380.2c-16.5 21-1.6 51.8 25.1 51.8h696c4.4 0 8-3.6 8-8v-60c0-4.4-3.6-8-8-8z"}}]},name:"swap",theme:"outlined"},p=y,$=A(12213),X=function(ce,le){return V.createElement($.Z,(0,R.Z)({},ce,{ref:le,icon:p}))},se=V.forwardRef(X)},43963:function(Ye,ye,A){"use strict";A.d(ye,{C3:function(){return ut},H9:function(){return Ge},Kp:function(){return le},R_:function(){return Ee},pw:function(){return qe},r:function(){return De},vD:function(){return ct}});var R=A(54131),V=A(13255),y=A(10129),p=A(75966),$=A(39057),X=A(36014),se=A(77617),ae=A(48081);function ce(Xe){return Xe.replace(/-(.)/g,function(Rt,gt){return gt.toUpperCase()})}function le(Xe,Rt){(0,X.ZP)(Xe,"[@ant-design/icons] ".concat(Rt))}function De(Xe){return(0,V.Z)(Xe)==="object"&&typeof Xe.name=="string"&&typeof Xe.theme=="string"&&((0,V.Z)(Xe.icon)==="object"||typeof Xe.icon=="function")}function we(){var Xe=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return Object.keys(Xe).reduce(function(Rt,gt){var Ct=Xe[gt];switch(gt){case"class":Rt.className=Ct,delete Rt.class;break;default:delete Rt[gt],Rt[ce(gt)]=Ct}return Rt},{})}function Ee(Xe,Rt,gt){return gt?se.createElement(Xe.tag,(0,R.Z)((0,R.Z)({key:Rt},we(Xe.attrs)),gt),(Xe.children||[]).map(function(Ct,tt){return Ee(Ct,"".concat(Rt,"-").concat(Xe.tag,"-").concat(tt))})):se.createElement(Xe.tag,(0,R.Z)({key:Rt},we(Xe.attrs)),(Xe.children||[]).map(function(Ct,tt){return Ee(Ct,"".concat(Rt,"-").concat(Xe.tag,"-").concat(tt))}))}function qe(Xe){return(0,y.R_)(Xe)[0]}function Ge(Xe){return Xe?Array.isArray(Xe)?Xe:[Xe]:[]}var ct={width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true",focusable:"false"},Ve=` +.anticon { + display: inline-block; + color: inherit; + font-style: normal; + line-height: 0; + text-align: center; + text-transform: none; + vertical-align: -0.125em; + text-rendering: optimizeLegibility; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} + +.anticon > * { + line-height: 1; +} + +.anticon svg { + display: inline-block; +} + +.anticon::before { + display: none; +} + +.anticon .anticon-icon { + display: block; +} + +.anticon[tabindex] { + cursor: pointer; +} + +.anticon-spin::before, +.anticon-spin { + display: inline-block; + -webkit-animation: loadingCircle 1s infinite linear; + animation: loadingCircle 1s infinite linear; +} + +@-webkit-keyframes loadingCircle { + 100% { + -webkit-transform: rotate(360deg); + transform: rotate(360deg); + } +} + +@keyframes loadingCircle { + 100% { + -webkit-transform: rotate(360deg); + transform: rotate(360deg); + } +} +`,ut=function(Rt){var gt=(0,se.useContext)(ae.Z),Ct=gt.csp,tt=gt.prefixCls,Ne=Ve;tt&&(Ne=Ne.replace(/anticon/g,tt)),(0,se.useEffect)(function(){var bt=Rt.current,et=(0,$.A)(bt);(0,p.hq)(Ne,"@ant-design-icons",{prepend:!0,csp:Ct,attachTo:et})},[])}},49336:function(Ye,ye){"use strict";var A="*",R=function(){function V(){this._events={}}return V.prototype.on=function(y,p,$){return this._events[y]||(this._events[y]=[]),this._events[y].push({callback:p,once:!!$}),this},V.prototype.once=function(y,p){return this.on(y,p,!0)},V.prototype.emit=function(y){for(var p=this,$=[],X=1;X',function(Ye){try{let ce=function(){$||($=!0,y())},le=function(){try{p.documentElement.doScroll("left")}catch(De){return void setTimeout(le,50)}ce()};var se=ce,ae=le,A=(A=document.getElementsByTagName("script"))[A.length-1],ye=A.getAttribute("data-injectcss"),A=A.getAttribute("data-disable-injectsvg");if(!A){var R,V,y,p,$,X=function(we,Ee){Ee.parentNode.insertBefore(we,Ee)};if(ye&&!Ye.__iconfont__svg__cssinject__){Ye.__iconfont__svg__cssinject__=!0;try{document.write("")}catch(De){console&&console.log(De)}}R=function(){var we,Ee=document.createElement("div");Ee.innerHTML=Ye._iconfont_svg_string_3580659,(Ee=Ee.getElementsByTagName("svg")[0])&&(Ee.setAttribute("aria-hidden","true"),Ee.style.position="absolute",Ee.style.width=0,Ee.style.height=0,Ee.style.overflow="hidden",Ee=Ee,(we=document.body).firstChild?X(Ee,we.firstChild):we.appendChild(Ee))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(R,0):(V=function(){document.removeEventListener("DOMContentLoaded",V,!1),R()},document.addEventListener("DOMContentLoaded",V,!1)):document.attachEvent&&(y=R,p=Ye.document,$=!1,le(),p.onreadystatechange=function(){p.readyState=="complete"&&(p.onreadystatechange=null,ce())})}}catch(ce){}}(window)},29075:function(Ye,ye,A){(function(R,V){V(ye,A(60965))})(this,function(R,V){"use strict";var y={draw:"crosshair",pointHover:"pointer",pointDrag:"move",lineHover:"pointer",lineDrag:"move",polygonHover:"pointer",polygonDrag:"move"},p={point:[],line:[],polygon:[],midPoint:[],dashLine:[],text:[]},$="top",X="bottom",se="right",ae="left",ce="auto",le=[$,X,se,ae],De="start",we="end",Ee="clippingParents",qe="viewport",Ge="popper",ct="reference",Ve=le.reduce(function(oe,o){return oe.concat([o+"-"+De,o+"-"+we])},[]),ut=[].concat(le,[ce]).reduce(function(oe,o){return oe.concat([o,o+"-"+De,o+"-"+we])},[]),Xe=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function Rt(oe){return oe?(oe.nodeName||"").toLowerCase():null}function gt(oe){if(oe==null)return window;if(""+oe!="[object Window]"){var o=oe.ownerDocument;return o&&o.defaultView||window}return oe}function Ct(oe){return oe instanceof gt(oe).Element||oe instanceof Element}function tt(oe){return oe instanceof gt(oe).HTMLElement||oe instanceof HTMLElement}function Ne(oe){return typeof ShadowRoot!="undefined"&&(oe instanceof gt(oe).ShadowRoot||oe instanceof ShadowRoot)}var bt={name:"applyStyles",enabled:!0,phase:"write",fn:function(oe){var o=oe.state;Object.keys(o.elements).forEach(function(s){var l=o.styles[s]||{},g=o.attributes[s]||{},M=o.elements[s];tt(M)&&Rt(M)&&(Object.assign(M.style,l),Object.keys(g).forEach(function(j){var J=g[j];J===!1?M.removeAttribute(j):M.setAttribute(j,J===!0?"":J)}))})},effect:function(oe){var o=oe.state,s={popper:{position:o.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(o.elements.popper.style,s.popper),o.styles=s,o.elements.arrow&&Object.assign(o.elements.arrow.style,s.arrow),function(){Object.keys(o.elements).forEach(function(l){var g=o.elements[l],M=o.attributes[l]||{},j=Object.keys(o.styles.hasOwnProperty(l)?o.styles[l]:s[l]).reduce(function(J,ve){return J[ve]="",J},{});tt(g)&&Rt(g)&&(Object.assign(g.style,j),Object.keys(M).forEach(function(J){g.removeAttribute(J)}))})}},requires:["computeStyles"]};function et(oe){return oe.split("-")[0]}var pt=Math.max,Ke=Math.min,ft=Math.round;function wt(){var oe=navigator.userAgentData;return oe!=null&&oe.brands&&Array.isArray(oe.brands)?oe.brands.map(function(o){return o.brand+"/"+o.version}).join(" "):navigator.userAgent}function Se(){return!/^((?!chrome|android).)*safari/i.test(wt())}function Ft(oe,o,s){o===void 0&&(o=!1),s===void 0&&(s=!1);var l=oe.getBoundingClientRect(),g=1,M=1;o&&tt(oe)&&(g=oe.offsetWidth>0&&ft(l.width)/oe.offsetWidth||1,M=oe.offsetHeight>0&&ft(l.height)/oe.offsetHeight||1);var j=(Ct(oe)?gt(oe):window).visualViewport,J=!Se()&&s,ve=(l.left+(J&&j?j.offsetLeft:0))/g,ze=(l.top+(J&&j?j.offsetTop:0))/M,lt=l.width/g,Dt=l.height/M;return{width:lt,height:Dt,top:ze,right:ve+lt,bottom:ze+Dt,left:ve,x:ve,y:ze}}function mt(oe){var o=Ft(oe),s=oe.offsetWidth,l=oe.offsetHeight;return Math.abs(o.width-s)>1||(s=o.width),Math.abs(o.height-l)>1||(l=o.height),{x:oe.offsetLeft,y:oe.offsetTop,width:s,height:l}}function ot(oe,o){var s=o.getRootNode&&o.getRootNode();if(oe.contains(o))return!0;if(s&&Ne(s)){var l=o;do{if(l&&oe.isSameNode(l))return!0;l=l.parentNode||l.host}while(l)}return!1}function We(oe){return gt(oe).getComputedStyle(oe)}function Me(oe){return["table","td","th"].indexOf(Rt(oe))>=0}function st(oe){return((Ct(oe)?oe.ownerDocument:oe.document)||window.document).documentElement}function Qe(oe){return Rt(oe)==="html"?oe:oe.assignedSlot||oe.parentNode||(Ne(oe)?oe.host:null)||st(oe)}function dr(oe){return tt(oe)&&We(oe).position!=="fixed"?oe.offsetParent:null}function Kt(oe){for(var o=gt(oe),s=dr(oe);s&&Me(s)&&We(s).position==="static";)s=dr(s);return s&&(Rt(s)==="html"||Rt(s)==="body"&&We(s).position==="static")?o:s||function(l){var g=/firefox/i.test(wt());if(/Trident/i.test(wt())&&tt(l)&&We(l).position==="fixed")return null;var M=Qe(l);for(Ne(M)&&(M=M.host);tt(M)&&0>["html","body"].indexOf(Rt(M));){var j=We(M);if(j.transform!=="none"||j.perspective!=="none"||j.contain==="paint"||["transform","perspective"].indexOf(j.willChange)!==-1||g&&j.willChange==="filter"||g&&j.filter&&j.filter!=="none")return M;M=M.parentNode}return null}(oe)||o}function Yr(oe){return 0>["top","bottom"].indexOf(oe)?"y":"x"}function hn(oe,o,s){return pt(oe,Ke(o,s))}function ln(oe){return Object.assign({},{top:0,right:0,bottom:0,left:0},oe)}function oi(oe,o){return o.reduce(function(s,l){return s[l]=oe,s},{})}var Nn={name:"arrow",enabled:!0,phase:"main",fn:function(oe){var o,s=oe.state,l=oe.name,g=oe.options,M=s.elements.arrow,j=s.modifiersData.popperOffsets,J=et(s.placement),ve=Yr(J),ze=[ae,se].indexOf(J)>=0?"height":"width";if(M&&j){var lt=function(Tn,Hn){return ln(typeof(Tn=typeof Tn=="function"?Tn(Object.assign({},Hn.rects,{placement:Hn.placement})):Tn)!="number"?Tn:oi(Tn,le))}(g.padding,s),Dt=mt(M),$t=ve==="y"?$:ae,lr=ve==="y"?X:se,wr=s.rects.reference[ze]+s.rects.reference[ve]-j[ve]-s.rects.popper[ze],Vr=j[ve]-s.rects.reference[ve],$r=Kt(M),Xr=$r?ve==="y"?$r.clientHeight||0:$r.clientWidth||0:0,Gr=Xr/2-Dt[ze]/2+(wr/2-Vr/2),Br=hn(lt[$t],Gr,Xr-Dt[ze]-lt[lr]);s.modifiersData[l]=((o={})[ve]=Br,o.centerOffset=Br-Gr,o)}},effect:function(oe){var o=oe.state,s=oe.options.element,l=s===void 0?"[data-popper-arrow]":s;l!=null&&(typeof l!="string"||(l=o.elements.popper.querySelector(l)))&&ot(o.elements.popper,l)&&(o.elements.arrow=l)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function $n(oe){return oe.split("-")[1]}var _i={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Qn(oe){var o,s=oe.popper,l=oe.popperRect,g=oe.placement,M=oe.variation,j=oe.offsets,J=oe.position,ve=oe.gpuAcceleration,ze=oe.adaptive,lt=oe.roundOffsets,Dt=oe.isFixed,$t=j.x,lr=$t===void 0?0:$t,wr=j.y,Vr=wr===void 0?0:wr,$r=typeof lt=="function"?lt({x:lr,y:Vr}):{x:lr,y:Vr};lr=$r.x,Vr=$r.y;var Xr=j.hasOwnProperty("x"),Gr=j.hasOwnProperty("y"),Br=ae,Tn=$,Hn=window;if(ze){var yi=Kt(s),vo="clientHeight",Eo="clientWidth";yi===gt(s)&&We(yi=st(s)).position!=="static"&&J==="absolute"&&(vo="scrollHeight",Eo="scrollWidth"),(g===$||(g===ae||g===se)&&M===we)&&(Tn=X,Vr-=(Dt&&yi===Hn&&Hn.visualViewport?Hn.visualViewport.height:yi[vo])-l.height,Vr*=ve?1:-1),(g===ae||(g===$||g===X)&&M===we)&&(Br=se,lr-=(Dt&&yi===Hn&&Hn.visualViewport?Hn.visualViewport.width:yi[Eo])-l.width,lr*=ve?1:-1)}var Xo,ys=Object.assign({position:J},ze&&_i),Yo=lt===!0?function(es,qa){var Ts=es.y,is=qa.devicePixelRatio||1;return{x:ft(es.x*is)/is||0,y:ft(Ts*is)/is||0}}({x:lr,y:Vr},gt(s)):{x:lr,y:Vr};return lr=Yo.x,Vr=Yo.y,Object.assign({},ys,ve?((Xo={})[Tn]=Gr?"0":"",Xo[Br]=Xr?"0":"",Xo.transform=(Hn.devicePixelRatio||1)>1?"translate3d("+lr+"px, "+Vr+"px, 0)":"translate("+lr+"px, "+Vr+"px)",Xo):((o={})[Tn]=Gr?Vr+"px":"",o[Br]=Xr?lr+"px":"",o.transform="",o))}var Ji={passive:!0},ni={left:"right",right:"left",bottom:"top",top:"bottom"};function Ei(oe){return oe.replace(/left|right|bottom|top/g,function(o){return ni[o]})}var xo={start:"end",end:"start"};function sn(oe){return oe.replace(/start|end/g,function(o){return xo[o]})}function li(oe){var o=gt(oe);return{scrollLeft:o.pageXOffset,scrollTop:o.pageYOffset}}function En(oe){return Ft(st(oe)).left+li(oe).scrollLeft}function or(oe){var o=We(oe);return/auto|scroll|overlay|hidden/.test(o.overflow+o.overflowY+o.overflowX)}function qi(oe){return 0>["html","body","#document"].indexOf(Rt(oe))?tt(oe)&&or(oe)?oe:qi(Qe(oe)):oe.ownerDocument.body}function Bo(oe,o){var s;o===void 0&&(o=[]);var l=qi(oe),g=l===((s=oe.ownerDocument)==null?void 0:s.body),M=gt(l),j=g?[M].concat(M.visualViewport||[],or(l)?l:[]):l,J=o.concat(j);return g?J:J.concat(Bo(Qe(j)))}function Mo(oe){return Object.assign({},oe,{left:oe.x,top:oe.y,right:oe.x+oe.width,bottom:oe.y+oe.height})}function Wi(oe,o,s){return o===qe?Mo(function(l,g){var M=gt(l),j=st(l),J=M.visualViewport,ve=j.clientWidth,ze=j.clientHeight,lt=0,Dt=0;if(J){ve=J.width,ze=J.height;var $t=Se();($t||!$t&&g==="fixed")&&(lt=J.offsetLeft,Dt=J.offsetTop)}return{width:ve,height:ze,x:lt+En(l),y:Dt}}(oe,s)):Ct(o)?function(l,g){var M=Ft(l,!1,g==="fixed");return M.top=M.top+l.clientTop,M.left=M.left+l.clientLeft,M.bottom=M.top+l.clientHeight,M.right=M.left+l.clientWidth,M.width=l.clientWidth,M.height=l.clientHeight,M.x=M.left,M.y=M.top,M}(o,s):Mo(function(l){var g,M=st(l),j=li(l),J=(g=l.ownerDocument)==null?void 0:g.body,ve=pt(M.scrollWidth,M.clientWidth,J?J.scrollWidth:0,J?J.clientWidth:0),ze=pt(M.scrollHeight,M.clientHeight,J?J.scrollHeight:0,J?J.clientHeight:0),lt=-j.scrollLeft+En(l),Dt=-j.scrollTop;return We(J||M).direction==="rtl"&&(lt+=pt(M.clientWidth,J?J.clientWidth:0)-ve),{width:ve,height:ze,x:lt,y:Dt}}(st(oe)))}function Ii(oe,o,s,l){var g=o==="clippingParents"?function(J){var ve=Bo(Qe(J)),ze=["absolute","fixed"].indexOf(We(J).position)>=0&&tt(J)?Kt(J):J;return Ct(ze)?ve.filter(function(lt){return Ct(lt)&&ot(lt,ze)&&Rt(lt)!=="body"}):[]}(oe):[].concat(o),M=[].concat(g,[s]),j=M.reduce(function(J,ve){var ze=Wi(oe,ve,l);return J.top=pt(ze.top,J.top),J.right=Ke(ze.right,J.right),J.bottom=Ke(ze.bottom,J.bottom),J.left=pt(ze.left,J.left),J},Wi(oe,M[0],l));return j.width=j.right-j.left,j.height=j.bottom-j.top,j.x=j.left,j.y=j.top,j}function ko(oe){var o,s=oe.reference,l=oe.element,g=oe.placement,M=g?et(g):null,j=g?$n(g):null,J=s.x+s.width/2-l.width/2,ve=s.y+s.height/2-l.height/2;switch(M){case $:o={x:J,y:s.y-l.height};break;case X:o={x:J,y:s.y+s.height};break;case se:o={x:s.x+s.width,y:ve};break;case ae:o={x:s.x-l.width,y:ve};break;default:o={x:s.x,y:s.y}}var ze=M?Yr(M):null;if(ze!=null){var lt=ze==="y"?"height":"width";switch(j){case De:o[ze]=o[ze]-(s[lt]/2-l[lt]/2);break;case we:o[ze]=o[ze]+(s[lt]/2-l[lt]/2)}}return o}function Fn(oe,o){o===void 0&&(o={});var s=o.placement,l=s===void 0?oe.placement:s,g=o.strategy,M=g===void 0?oe.strategy:g,j=o.boundary,J=j===void 0?Ee:j,ve=o.rootBoundary,ze=ve===void 0?qe:ve,lt=o.elementContext,Dt=lt===void 0?Ge:lt,$t=o.altBoundary,lr=$t!==void 0&&$t,wr=o.padding,Vr=wr===void 0?0:wr,$r=ln(typeof Vr!="number"?Vr:oi(Vr,le)),Xr=oe.rects.popper,Gr=oe.elements[lr?Dt===Ge?ct:Ge:Dt],Br=Ii(Ct(Gr)?Gr:Gr.contextElement||st(oe.elements.popper),J,ze,M),Tn=Ft(oe.elements.reference),Hn=ko({reference:Tn,element:Xr,strategy:"absolute",placement:l}),yi=Mo(Object.assign({},Xr,Hn)),vo=Dt===Ge?yi:Tn,Eo={top:Br.top-vo.top+$r.top,bottom:vo.bottom-Br.bottom+$r.bottom,left:Br.left-vo.left+$r.left,right:vo.right-Br.right+$r.right},Xo=oe.modifiersData.offset;if(Dt===Ge&&Xo){var ys=Xo[l];Object.keys(Eo).forEach(function(Yo){var es=0>[se,X].indexOf(Yo)?-1:1;Eo[Yo]+=ys[0>[$,X].indexOf(Yo)?"x":"y"]*es})}return Eo}function zn(oe,o){o===void 0&&(o={});var s=o.boundary,l=o.rootBoundary,g=o.padding,M=o.flipVariations,j=o.allowedAutoPlacements,J=j===void 0?ut:j,ve=$n(o.placement),ze=ve?M?Ve:Ve.filter(function($t){return $n($t)===ve}):le,lt=ze.filter(function($t){return J.indexOf($t)>=0});lt.length===0&&(lt=ze);var Dt=lt.reduce(function($t,lr){return $t[lr]=Fn(oe,{placement:lr,boundary:s,rootBoundary:l,padding:g})[et(lr)],$t},{});return Object.keys(Dt).sort(function($t,lr){return Dt[$t]-Dt[lr]})}var Un={name:"flip",enabled:!0,phase:"main",fn:function(oe){var o=oe.state,s=oe.options,l=oe.name;if(!o.modifiersData[l]._skip){for(var g=s.mainAxis,M=g===void 0||g,j=s.altAxis,J=j===void 0||j,ve=s.fallbackPlacements,ze=s.padding,lt=s.boundary,Dt=s.rootBoundary,$t=s.altBoundary,lr=s.flipVariations,wr=lr===void 0||lr,Vr=s.allowedAutoPlacements,$r=o.options.placement,Xr=et($r),Gr=ve||(Xr===$r||!wr?[Ei($r)]:function(Es){if(et(Es)===ce)return[];var sl=Ei(Es);return[sn(Es),sl,sn(sl)]}($r)),Br=[$r].concat(Gr).reduce(function(Es,sl){return Es.concat(et(sl)===ce?zn(o,{placement:sl,boundary:lt,rootBoundary:Dt,padding:ze,flipVariations:wr,allowedAutoPlacements:Vr}):sl)},[]),Tn=o.rects.reference,Hn=o.rects.popper,yi=new Map,vo=!0,Eo=Br[0],Xo=0;Br.length>Xo;Xo++){var ys=Br[Xo],Yo=et(ys),es=$n(ys)===De,qa=[$,X].indexOf(Yo)>=0,Ts=qa?"width":"height",is=Fn(o,{placement:ys,boundary:lt,rootBoundary:Dt,altBoundary:$t,padding:ze}),ts=qa?es?se:ae:es?X:$;Tn[Ts]>Hn[Ts]&&(ts=Ei(ts));var Rs=Ei(ts),pu=[];if(M&&pu.push(0>=is[Yo]),J&&pu.push(0>=is[ts],0>=is[Rs]),pu.every(function(Es){return Es})){Eo=ys,vo=!1;break}yi.set(ys,pu)}if(vo)for(var nl=function(Es){var sl=Br.find(function(Bf){var Vl=yi.get(Bf);if(Vl)return Vl.slice(0,Es).every(function(oc){return oc})});if(sl)return Eo=sl,"break"},la=wr?3:1;la>0&&nl(la)!=="break";la--);o.placement!==Eo&&(o.modifiersData[l]._skip=!0,o.placement=Eo,o.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function Hi(oe,o,s){return s===void 0&&(s={x:0,y:0}),{top:oe.top-o.height-s.y,right:oe.right-o.width+s.x,bottom:oe.bottom-o.height+s.y,left:oe.left-o.width-s.x}}function Ki(oe){return[$,se,X,ae].some(function(o){return oe[o]>=0})}var Fo={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(oe){var o=oe.state,s=oe.name,l=oe.options.offset,g=l===void 0?[0,0]:l,M=ut.reduce(function(ve,ze){return ve[ze]=function(lt,Dt,$t){var lr=et(lt),wr=0>[ae,$].indexOf(lr)?1:-1,Vr=typeof $t=="function"?$t(Object.assign({},Dt,{placement:lt})):$t,$r=Vr[0],Xr=Vr[1];return $r=$r||0,Xr=(Xr||0)*wr,0>[ae,se].indexOf(lr)?{x:$r,y:Xr}:{x:Xr,y:$r}}(ze,o.rects,g),ve},{}),j=M[o.placement],J=j.y;o.modifiersData.popperOffsets!=null&&(o.modifiersData.popperOffsets.x+=j.x,o.modifiersData.popperOffsets.y+=J),o.modifiersData[s]=M}},xt={name:"preventOverflow",enabled:!0,phase:"main",fn:function(oe){var o=oe.state,s=oe.options,l=oe.name,g=s.mainAxis,M=g===void 0||g,j=s.altAxis,J=j!==void 0&&j,ve=s.tether,ze=ve===void 0||ve,lt=s.tetherOffset,Dt=lt===void 0?0:lt,$t=Fn(o,{boundary:s.boundary,rootBoundary:s.rootBoundary,padding:s.padding,altBoundary:s.altBoundary}),lr=et(o.placement),wr=$n(o.placement),Vr=!wr,$r=Yr(lr),Xr=$r==="x"?"y":"x",Gr=o.modifiersData.popperOffsets,Br=o.rects.reference,Tn=o.rects.popper,Hn=typeof Dt=="function"?Dt(Object.assign({},o.rects,{placement:o.placement})):Dt,yi=typeof Hn=="number"?{mainAxis:Hn,altAxis:Hn}:Object.assign({mainAxis:0,altAxis:0},Hn),vo=o.modifiersData.offset?o.modifiersData.offset[o.placement]:null,Eo={x:0,y:0};if(Gr){if(M){var Xo,ys=$r==="y"?$:ae,Yo=$r==="y"?X:se,es=$r==="y"?"height":"width",qa=Gr[$r],Ts=qa+$t[ys],is=qa-$t[Yo],ts=ze?-Tn[es]/2:0,Rs=wr===De?Br[es]:Tn[es],pu=wr===De?-Tn[es]:-Br[es],nl=o.elements.arrow,la=ze&&nl?mt(nl):{width:0,height:0},Es=o.modifiersData["arrow#persistent"]?o.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},sl=Es[ys],Bf=Es[Yo],Vl=hn(0,Br[es],la[es]),oc=Vr?Br[es]/2-ts-Vl-sl-yi.mainAxis:Rs-Vl-sl-yi.mainAxis,zc=Vr?-Br[es]/2+ts+Vl+Bf+yi.mainAxis:pu+Vl+Bf+yi.mainAxis,xc=o.elements.arrow&&Kt(o.elements.arrow),ih=(Xo=vo==null?void 0:vo[$r])!=null?Xo:0,wh=qa+zc-ih,hh=hn(ze?Ke(Ts,qa+oc-ih-(xc?$r==="y"?xc.clientTop||0:xc.clientLeft||0:0)):Ts,qa,ze?pt(is,wh):is);Gr[$r]=hh,Eo[$r]=hh-qa}if(J){var dh,Jf=Gr[Xr],pf=Xr==="y"?"height":"width",ec=Jf+$t[$r==="x"?$:ae],Jc=Jf-$t[$r==="x"?X:se],zl=[$,ae].indexOf(lr)!==-1,Zc=(dh=vo==null?void 0:vo[Xr])!=null?dh:0,Lh=zl?ec:Jf-Br[pf]-Tn[pf]-Zc+yi.altAxis,sd=zl?Jf+Br[pf]+Tn[pf]-Zc-yi.altAxis:Jc,pa=ze&&zl?function(gc,Rc,tc){var oh=hn(gc,Rc,tc);return oh>tc?tc:oh}(Lh,Jf,sd):hn(ze?Lh:ec,Jf,ze?sd:Jc);Gr[Xr]=pa,Eo[Xr]=pa-Jf}o.modifiersData[l]=Eo}},requiresIfExists:["offset"]};function it(oe,o,s){s===void 0&&(s=!1);var l,g,M=tt(o),j=tt(o)&&function(Dt){var $t=Dt.getBoundingClientRect(),lr=ft($t.width)/Dt.offsetWidth||1,wr=ft($t.height)/Dt.offsetHeight||1;return lr!==1||wr!==1}(o),J=st(o),ve=Ft(oe,j,s),ze={scrollLeft:0,scrollTop:0},lt={x:0,y:0};return(M||!M&&!s)&&((Rt(o)!=="body"||or(J))&&(ze=(l=o)!==gt(l)&&tt(l)?{scrollLeft:(g=l).scrollLeft,scrollTop:g.scrollTop}:li(l)),tt(o)?((lt=Ft(o,!0)).x+=o.clientLeft,lt.y+=o.clientTop):J&&(lt.x=En(J))),{x:ve.left+ze.scrollLeft-lt.x,y:ve.top+ze.scrollTop-lt.y,width:ve.width,height:ve.height}}function kt(oe){var o=new Map,s=new Set,l=[];function g(M){s.add(M.name),[].concat(M.requires||[],M.requiresIfExists||[]).forEach(function(j){if(!s.has(j)){var J=o.get(j);J&&g(J)}}),l.push(M)}return oe.forEach(function(M){o.set(M.name,M)}),oe.forEach(function(M){s.has(M.name)||g(M)}),l}var ir={placement:"bottom",modifiers:[],strategy:"absolute"};function Pr(){for(var oe=arguments.length,o=Array(oe),s=0;oe>s;s++)o[s]=arguments[s];return!o.some(function(l){return!(l&&typeof l.getBoundingClientRect=="function")})}function kr(oe){oe===void 0&&(oe={});var o=oe.defaultModifiers,s=o===void 0?[]:o,l=oe.defaultOptions,g=l===void 0?ir:l;return function(M,j,J){J===void 0&&(J=g);var ve,ze,lt={placement:"bottom",orderedModifiers:[],options:Object.assign({},ir,g),modifiersData:{},elements:{reference:M,popper:j},attributes:{},styles:{}},Dt=[],$t=!1,lr={state:lt,setOptions:function(Vr){var $r=typeof Vr=="function"?Vr(lt.options):Vr;wr(),lt.options=Object.assign({},g,lt.options,$r),lt.scrollParents={reference:Ct(M)?Bo(M):M.contextElement?Bo(M.contextElement):[],popper:Bo(j)};var Xr,Gr,Br=function(Tn){var Hn=kt(Tn);return Xe.reduce(function(yi,vo){return yi.concat(Hn.filter(function(Eo){return Eo.phase===vo}))},[])}((Xr=[].concat(s,lt.options.modifiers),Gr=Xr.reduce(function(Tn,Hn){var yi=Tn[Hn.name];return Tn[Hn.name]=yi?Object.assign({},yi,Hn,{options:Object.assign({},yi.options,Hn.options),data:Object.assign({},yi.data,Hn.data)}):Hn,Tn},{}),Object.keys(Gr).map(function(Tn){return Gr[Tn]})));return lt.orderedModifiers=Br.filter(function(Tn){return Tn.enabled}),lt.orderedModifiers.forEach(function(Tn){var Hn=Tn.options,yi=Tn.effect;if(typeof yi=="function"){var vo=yi({state:lt,name:Tn.name,instance:lr,options:Hn===void 0?{}:Hn});Dt.push(vo||function(){})}}),lr.update()},forceUpdate:function(){if(!$t){var Vr=lt.elements,$r=Vr.reference,Xr=Vr.popper;if(Pr($r,Xr)){lt.rects={reference:it($r,Kt(Xr),lt.options.strategy==="fixed"),popper:mt(Xr)},lt.reset=!1,lt.placement=lt.options.placement,lt.orderedModifiers.forEach(function(yi){return lt.modifiersData[yi.name]=Object.assign({},yi.data)});for(var Gr=0;lt.orderedModifiers.length>Gr;Gr++)if(lt.reset!==!0){var Br=lt.orderedModifiers[Gr],Tn=Br.fn,Hn=Br.options;typeof Tn=="function"&&(lt=Tn({state:lt,options:Hn===void 0?{}:Hn,name:Br.name,instance:lr})||lt)}else lt.reset=!1,Gr=-1}}},update:(ve=function(){return new Promise(function(Vr){lr.forceUpdate(),Vr(lt)})},function(){return ze||(ze=new Promise(function(Vr){Promise.resolve().then(function(){ze=void 0,Vr(ve())})})),ze}),destroy:function(){wr(),$t=!0}};if(!Pr(M,j))return lr;function wr(){Dt.forEach(function(Vr){return Vr()}),Dt=[]}return lr.setOptions(J).then(function(Vr){!$t&&J.onFirstUpdate&&J.onFirstUpdate(Vr)}),lr}}var An=kr({defaultModifiers:[{name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(oe){var o=oe.state,s=oe.instance,l=oe.options,g=l.scroll,M=g===void 0||g,j=l.resize,J=j===void 0||j,ve=gt(o.elements.popper),ze=[].concat(o.scrollParents.reference,o.scrollParents.popper);return M&&ze.forEach(function(lt){lt.addEventListener("scroll",s.update,Ji)}),J&&ve.addEventListener("resize",s.update,Ji),function(){M&&ze.forEach(function(lt){lt.removeEventListener("scroll",s.update,Ji)}),J&&ve.removeEventListener("resize",s.update,Ji)}},data:{}},{name:"popperOffsets",enabled:!0,phase:"read",fn:function(oe){var o=oe.state;o.modifiersData[oe.name]=ko({reference:o.rects.reference,element:o.rects.popper,strategy:"absolute",placement:o.placement})},data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(oe){var o=oe.state,s=oe.options,l=s.gpuAcceleration,g=l===void 0||l,M=s.adaptive,j=M===void 0||M,J=s.roundOffsets,ve=J===void 0||J,ze={placement:et(o.placement),variation:$n(o.placement),popper:o.elements.popper,popperRect:o.rects.popper,gpuAcceleration:g,isFixed:o.options.strategy==="fixed"};o.modifiersData.popperOffsets!=null&&(o.styles.popper=Object.assign({},o.styles.popper,Qn(Object.assign({},ze,{offsets:o.modifiersData.popperOffsets,position:o.options.strategy,adaptive:j,roundOffsets:ve})))),o.modifiersData.arrow!=null&&(o.styles.arrow=Object.assign({},o.styles.arrow,Qn(Object.assign({},ze,{offsets:o.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:ve})))),o.attributes.popper=Object.assign({},o.attributes.popper,{"data-popper-placement":o.placement})},data:{}},bt,Fo,Un,xt,Nn,{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(oe){var o=oe.state,s=oe.name,l=o.rects.reference,g=o.rects.popper,M=o.modifiersData.preventOverflow,j=Fn(o,{elementContext:"reference"}),J=Fn(o,{altBoundary:!0}),ve=Hi(j,l),ze=Hi(J,g,M),lt=Ki(ve),Dt=Ki(ze);o.modifiersData[s]={referenceClippingOffsets:ve,popperEscapeOffsets:ze,isReferenceHidden:lt,hasPopperEscaped:Dt},o.attributes.popper=Object.assign({},o.attributes.popper,{"data-popper-reference-hidden":lt,"data-popper-escaped":Dt})}}]}),Dn="tippy-content",Ht="tippy-backdrop",Lt="tippy-arrow",je="tippy-svg-arrow",$e={passive:!0,capture:!0},At=function(){return document.body};function Bt(oe,o,s){if(Array.isArray(oe)){var l=oe[o];return l==null?Array.isArray(s)?s[o]:s:l}return oe}function Jt(oe,o){var s={}.toString.call(oe);return s.indexOf("[object")===0&&s.indexOf(o+"]")>-1}function ar(oe,o){return typeof oe=="function"?oe.apply(void 0,o):oe}function hr(oe,o){return o===0?oe:function(l){clearTimeout(s),s=setTimeout(function(){oe(l)},o)};var s}function Gt(oe){return[].concat(oe)}function Tr(oe,o){oe.indexOf(o)===-1&&oe.push(o)}function nn(oe){return[].slice.call(oe)}function bn(oe){return Object.keys(oe).reduce(function(o,s){return oe[s]!==void 0&&(o[s]=oe[s]),o},{})}function Bi(){return document.createElement("div")}function on(oe){return["Element","Fragment"].some(function(o){return Jt(oe,o)})}function dn(oe){return Jt(oe,"MouseEvent")}function ri(oe){return on(oe)?[oe]:function(o){return Jt(o,"NodeList")}(oe)?nn(oe):Array.isArray(oe)?oe:nn(document.querySelectorAll(oe))}function Wn(oe,o){oe.forEach(function(s){s&&(s.style.transitionDuration=o+"ms")})}function Rn(oe,o){oe.forEach(function(s){s&&s.setAttribute("data-state",o)})}function di(oe){var o,s=Gt(oe)[0];return s!=null&&(o=s.ownerDocument)!=null&&o.body?s.ownerDocument:document}function zi(oe,o,s){var l=o+"EventListener";["transitionend","webkitTransitionEnd"].forEach(function(g){oe[l](g,s)})}function Gi(oe,o){for(var s=o;s;){var l;if(oe.contains(s))return!0;s=s.getRootNode==null||(l=s.getRootNode())==null?void 0:l.host}return!1}var Lo={isTouch:!1},eo=0;function ba(){Lo.isTouch||(Lo.isTouch=!0,window.performance&&document.addEventListener("mousemove",va))}function va(){var oe=performance.now();20>oe-eo&&(Lo.isTouch=!1,document.removeEventListener("mousemove",va)),eo=oe}function Do(){var oe,o=document.activeElement;(oe=o)&&oe._tippy&&oe._tippy.reference===oe&&o.blur&&!o._tippy.state.isVisible&&o.blur()}var Ps=typeof window!="undefined"&&typeof document!="undefined"&&!!window.msCrypto,Nr=Object.assign({appendTo:At,aria:{content:"auto",expanded:"auto"},delay:0,duration:[300,250],getReferenceClientRect:null,hideOnClick:!0,ignoreAttributes:!1,interactive:!1,interactiveBorder:2,interactiveDebounce:0,moveTransition:"",offset:[0,10],onAfterUpdate:function(){},onBeforeUpdate:function(){},onCreate:function(){},onDestroy:function(){},onHidden:function(){},onHide:function(){},onMount:function(){},onShow:function(){},onShown:function(){},onTrigger:function(){},onUntrigger:function(){},onClickOutside:function(){},placement:"top",plugins:[],popperOptions:{},render:null,showOnCreate:!1,touch:!0,trigger:"mouseenter focus",triggerTarget:null},{animateFill:!1,followCursor:!1,inlinePositioning:!1,sticky:!1},{allowHTML:!1,animation:"fade",arrow:!0,content:"",inertia:!1,maxWidth:350,role:"tooltip",theme:"",zIndex:9999}),fo=Object.keys(Nr);function hi(oe){var o=(oe.plugins||[]).reduce(function(s,l){var g,M=l.name;return M&&(s[M]=oe[M]!==void 0?oe[M]:(g=Nr[M])!=null?g:l.defaultValue),s},{});return Object.assign({},oe,o)}function Yi(oe,o){var s=Object.assign({},o,{content:ar(o.content,[oe])},o.ignoreAttributes?{}:function(l,g){return(g?Object.keys(hi(Object.assign({},Nr,{plugins:g}))):fo).reduce(function(M,j){var J=(l.getAttribute("data-tippy-"+j)||"").trim();if(!J)return M;if(j==="content")M[j]=J;else try{M[j]=JSON.parse(J)}catch(ve){M[j]=J}return M},{})}(oe,o.plugins));return s.aria=Object.assign({},Nr.aria,s.aria),s.aria={expanded:s.aria.expanded==="auto"?o.interactive:s.aria.expanded,content:s.aria.content==="auto"?o.interactive?null:"describedby":s.aria.content},s}var ga=function(){return"innerHTML"};function Xi(oe,o){oe[ga()]=o}function On(oe){var o=Bi();return oe===!0?o.className=Lt:(o.className=je,on(oe)?o.appendChild(oe):Xi(o,oe)),o}function gi(oe,o){on(o.content)?(Xi(oe,""),oe.appendChild(o.content)):typeof o.content!="function"&&(o.allowHTML?Xi(oe,o.content):oe.textContent=o.content)}function ol(oe){var o=oe.firstElementChild,s=nn(o.children);return{box:o,content:s.find(function(l){return l.classList.contains(Dn)}),arrow:s.find(function(l){return l.classList.contains(Lt)||l.classList.contains(je)}),backdrop:s.find(function(l){return l.classList.contains(Ht)})}}function ks(oe){var o=Bi(),s=Bi();s.className="tippy-box",s.setAttribute("data-state","hidden"),s.setAttribute("tabindex","-1");var l=Bi();function g(M,j){var J=ol(o),ve=J.box,ze=J.content,lt=J.arrow;j.theme?ve.setAttribute("data-theme",j.theme):ve.removeAttribute("data-theme"),typeof j.animation=="string"?ve.setAttribute("data-animation",j.animation):ve.removeAttribute("data-animation"),j.inertia?ve.setAttribute("data-inertia",""):ve.removeAttribute("data-inertia"),ve.style.maxWidth=typeof j.maxWidth=="number"?j.maxWidth+"px":j.maxWidth,j.role?ve.setAttribute("role",j.role):ve.removeAttribute("role"),M.content===j.content&&M.allowHTML===j.allowHTML||gi(ze,oe.props),j.arrow?lt?M.arrow!==j.arrow&&(ve.removeChild(lt),ve.appendChild(On(j.arrow))):ve.appendChild(On(j.arrow)):lt&&ve.removeChild(lt)}return l.className=Dn,l.setAttribute("data-state","hidden"),gi(l,oe.props),o.appendChild(s),s.appendChild(l),g(oe.props,oe.props),{popper:o,onUpdate:g}}ks.$$tippy=!0;var as=1,_s=[],Ks=[];function Ea(oe,o){var s,l,g,M,j,J,ve,ze,lt=Yi(oe,Object.assign({},Nr,hi(bn(o)))),Dt=!1,$t=!1,lr=!1,wr=!1,Vr=[],$r=hr(dh,lt.interactiveDebounce),Xr=as++,Gr=(ze=lt.plugins).filter(function(pa,gc){return ze.indexOf(pa)===gc}),Br={id:Xr,reference:oe,popper:Bi(),popperInstance:null,props:lt,state:{isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},plugins:Gr,clearDelayTimeouts:function(){clearTimeout(s),clearTimeout(l),cancelAnimationFrame(g)},setProps:function(pa){if(!Br.state.isDestroyed){Rs("onBeforeUpdate",[Br,pa]),wh();var gc=Br.props,Rc=Yi(oe,Object.assign({},gc,bn(pa),{ignoreAttributes:!0}));Br.props=Rc,ih(),gc.interactiveDebounce!==Rc.interactiveDebounce&&(la(),$r=hr(dh,Rc.interactiveDebounce)),gc.triggerTarget&&!Rc.triggerTarget?Gt(gc.triggerTarget).forEach(function(tc){tc.removeAttribute("aria-expanded")}):Rc.triggerTarget&&oe.removeAttribute("aria-expanded"),nl(),ts(),yi&&yi(gc,Rc),Br.popperInstance&&(Jc(),Zc().forEach(function(tc){requestAnimationFrame(tc._tippy.popperInstance.forceUpdate)})),Rs("onAfterUpdate",[Br,pa])}},setContent:function(pa){Br.setProps({content:pa})},show:function(){var pa=Br.state.isVisible,gc=Br.state.isDestroyed,Rc=!Br.state.isEnabled,tc=Lo.isTouch&&!Br.props.touch,oh=Bt(Br.props.duration,0,Nr.duration);if(!(pa||gc||Rc||tc)&&!es().hasAttribute("disabled")&&(Rs("onShow",[Br],!1),Br.props.onShow(Br)!==!1)){if(Br.state.isVisible=!0,Yo()&&(Hn.style.visibility="visible"),ts(),Vl(),Br.state.isMounted||(Hn.style.transition="none"),Yo()){var _=Ts();Wn([_.box,_.content],0)}J=function(){var d;if(Br.state.isVisible&&!wr){if(wr=!0,Hn.style.transition=Br.props.moveTransition,Yo()&&Br.props.animation){var C=Ts(),G=C.box,de=C.content;Wn([G,de],oh),Rn([G,de],"visible")}pu(),nl(),Tr(Ks,Br),(d=Br.popperInstance)==null||d.forceUpdate(),Rs("onMount",[Br]),Br.props.animation&&Yo()&&function(Te,Re){zc(Te,Re)}(oh,function(){Br.state.isShown=!0,Rs("onShown",[Br])})}},function(){var d,C=Br.props.appendTo,G=es();d=Br.props.interactive&&C===At||C==="parent"?G.parentNode:ar(C,[G]),d.contains(Hn)||d.appendChild(Hn),Br.state.isMounted=!0,Jc()}()}},hide:function(){var pa=!Br.state.isVisible,gc=Br.state.isDestroyed,Rc=!Br.state.isEnabled,tc=Bt(Br.props.duration,1,Nr.duration);if(!(pa||gc||Rc)&&(Rs("onHide",[Br],!1),Br.props.onHide(Br)!==!1)){if(Br.state.isVisible=!1,Br.state.isShown=!1,wr=!1,Dt=!1,Yo()&&(Hn.style.visibility="hidden"),la(),oc(),ts(!0),Yo()){var oh=Ts(),_=oh.box,d=oh.content;Br.props.animation&&(Wn([_,d],tc),Rn([_,d],"hidden"))}pu(),nl(),Br.props.animation?Yo()&&function(C,G){zc(C,function(){!Br.state.isVisible&&Hn.parentNode&&Hn.parentNode.contains(Hn)&&G()})}(tc,Br.unmount):Br.unmount()}},hideWithInteractivity:function(pa){qa().addEventListener("mousemove",$r),Tr(_s,$r),$r(pa)},enable:function(){Br.state.isEnabled=!0},disable:function(){Br.hide(),Br.state.isEnabled=!1},unmount:function(){Br.state.isVisible&&Br.hide(),Br.state.isMounted&&(zl(),Zc().forEach(function(pa){pa._tippy.unmount()}),Hn.parentNode&&Hn.parentNode.removeChild(Hn),Ks=Ks.filter(function(pa){return pa!==Br}),Br.state.isMounted=!1,Rs("onHidden",[Br]))},destroy:function(){Br.state.isDestroyed||(Br.clearDelayTimeouts(),Br.unmount(),wh(),delete oe._tippy,Br.state.isDestroyed=!0,Rs("onDestroy",[Br]))}};if(!lt.render)return Br;var Tn=lt.render(Br),Hn=Tn.popper,yi=Tn.onUpdate;Hn.setAttribute("data-tippy-root",""),Hn.id="tippy-"+Br.id,Br.popper=Hn,oe._tippy=Br,Hn._tippy=Br;var vo=Gr.map(function(pa){return pa.fn(Br)}),Eo=oe.hasAttribute("aria-expanded");return ih(),nl(),ts(),Rs("onCreate",[Br]),lt.showOnCreate&&Lh(),Hn.addEventListener("mouseenter",function(){Br.props.interactive&&Br.state.isVisible&&Br.clearDelayTimeouts()}),Hn.addEventListener("mouseleave",function(){Br.props.interactive&&Br.props.trigger.indexOf("mouseenter")>=0&&qa().addEventListener("mousemove",$r)}),Br;function Xo(){var pa=Br.props.touch;return Array.isArray(pa)?pa:[pa,0]}function ys(){return Xo()[0]==="hold"}function Yo(){var pa;return!((pa=Br.props.render)==null||!pa.$$tippy)}function es(){return ve||oe}function qa(){var pa=es().parentNode;return pa?di(pa):document}function Ts(){return ol(Hn)}function is(pa){return Br.state.isMounted&&!Br.state.isVisible||Lo.isTouch||M&&M.type==="focus"?0:Bt(Br.props.delay,pa?0:1,Nr.delay)}function ts(pa){pa===void 0&&(pa=!1),Hn.style.pointerEvents=Br.props.interactive&&!pa?"":"none",Hn.style.zIndex=""+Br.props.zIndex}function Rs(pa,gc,Rc){var tc;Rc===void 0&&(Rc=!0),vo.forEach(function(oh){oh[pa]&&oh[pa].apply(oh,gc)}),Rc&&(tc=Br.props)[pa].apply(tc,gc)}function pu(){var pa=Br.props.aria;if(pa.content){var gc="aria-"+pa.content,Rc=Hn.id;Gt(Br.props.triggerTarget||oe).forEach(function(tc){var oh=tc.getAttribute(gc);if(Br.state.isVisible)tc.setAttribute(gc,oh?oh+" "+Rc:Rc);else{var _=oh&&oh.replace(Rc,"").trim();_?tc.setAttribute(gc,_):tc.removeAttribute(gc)}})}}function nl(){!Eo&&Br.props.aria.expanded&&Gt(Br.props.triggerTarget||oe).forEach(function(pa){Br.props.interactive?pa.setAttribute("aria-expanded",Br.state.isVisible&&pa===es()?"true":"false"):pa.removeAttribute("aria-expanded")})}function la(){qa().removeEventListener("mousemove",$r),_s=_s.filter(function(pa){return pa!==$r})}function Es(pa){if(!Lo.isTouch||!lr&&pa.type!=="mousedown"){var gc=pa.composedPath&&pa.composedPath()[0]||pa.target;if(!Br.props.interactive||!Gi(Hn,gc)){if(Gt(Br.props.triggerTarget||oe).some(function(Rc){return Gi(Rc,gc)})){if(Lo.isTouch||Br.state.isVisible&&Br.props.trigger.indexOf("click")>=0)return}else Rs("onClickOutside",[Br,pa]);Br.props.hideOnClick===!0&&(Br.clearDelayTimeouts(),Br.hide(),$t=!0,setTimeout(function(){$t=!1}),Br.state.isMounted||oc())}}}function sl(){lr=!0}function Bf(){lr=!1}function Vl(){var pa=qa();pa.addEventListener("mousedown",Es,!0),pa.addEventListener("touchend",Es,$e),pa.addEventListener("touchstart",Bf,$e),pa.addEventListener("touchmove",sl,$e)}function oc(){var pa=qa();pa.removeEventListener("mousedown",Es,!0),pa.removeEventListener("touchend",Es,$e),pa.removeEventListener("touchstart",Bf,$e),pa.removeEventListener("touchmove",sl,$e)}function zc(pa,gc){var Rc=Ts().box;function tc(oh){oh.target===Rc&&(zi(Rc,"remove",tc),gc())}if(pa===0)return gc();zi(Rc,"remove",j),zi(Rc,"add",tc),j=tc}function xc(pa,gc,Rc){Rc===void 0&&(Rc=!1),Gt(Br.props.triggerTarget||oe).forEach(function(tc){tc.addEventListener(pa,gc,Rc),Vr.push({node:tc,eventType:pa,handler:gc,options:Rc})})}function ih(){var pa;ys()&&(xc("touchstart",hh,{passive:!0}),xc("touchend",Jf,{passive:!0})),(pa=Br.props.trigger,pa.split(/\s+/).filter(Boolean)).forEach(function(gc){if(gc!=="manual")switch(xc(gc,hh),gc){case"mouseenter":xc("mouseleave",Jf);break;case"focus":xc(Ps?"focusout":"blur",pf);break;case"focusin":xc("focusout",pf)}})}function wh(){Vr.forEach(function(pa){pa.node.removeEventListener(pa.eventType,pa.handler,pa.options)}),Vr=[]}function hh(pa){var gc,Rc=!1;if(Br.state.isEnabled&&!ec(pa)&&!$t){var tc=((gc=M)==null?void 0:gc.type)==="focus";M=pa,ve=pa.currentTarget,nl(),!Br.state.isVisible&&dn(pa)&&_s.forEach(function(oh){return oh(pa)}),pa.type==="click"&&(0>Br.props.trigger.indexOf("mouseenter")||Dt)&&Br.props.hideOnClick!==!1&&Br.state.isVisible?Rc=!0:Lh(pa),pa.type==="click"&&(Dt=!Rc),Rc&&!tc&&sd(pa)}}function dh(pa){var gc=pa.target,Rc=es().contains(gc)||Hn.contains(gc);if(pa.type!=="mousemove"||!Rc){var tc=Zc().concat(Hn).map(function(oh){var _,d=(_=oh._tippy.popperInstance)==null?void 0:_.state;return d?{popperRect:oh.getBoundingClientRect(),popperState:d,props:lt}:null}).filter(Boolean);(function(oh,_){var d=_.clientX,C=_.clientY;return oh.every(function(G){var de=G.popperRect,Te=G.popperState,Re=G.props.interactiveBorder,ht=Te.placement.split("-")[0],Mt=Te.modifiersData.offset;return!Mt||de.top-C+(ht==="bottom"?Mt.top.y:0)>Re||C-de.bottom-(ht==="top"?Mt.bottom.y:0)>Re||de.left-d+(ht==="right"?Mt.left.x:0)>Re||d-de.right-(ht==="left"?Mt.right.x:0)>Re})})(tc,pa)&&(la(),sd(pa))}}function Jf(pa){ec(pa)||Br.props.trigger.indexOf("click")>=0&&Dt||(Br.props.interactive?Br.hideWithInteractivity(pa):sd(pa))}function pf(pa){0>Br.props.trigger.indexOf("focusin")&&pa.target!==es()||Br.props.interactive&&pa.relatedTarget&&Hn.contains(pa.relatedTarget)||sd(pa)}function ec(pa){return!!Lo.isTouch&&ys()!==pa.type.indexOf("touch")>=0}function Jc(){zl();var pa=Br.props,gc=pa.popperOptions,Rc=pa.placement,tc=pa.offset,oh=pa.getReferenceClientRect,_=pa.moveTransition,d=Yo()?ol(Hn).arrow:null,C=oh?{getBoundingClientRect:oh,contextElement:oh.contextElement||es()}:oe,G={name:"$$tippy",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(Te){var Re=Te.state;if(Yo()){var ht=Ts().box;["placement","reference-hidden","escaped"].forEach(function(Mt){Mt==="placement"?ht.setAttribute("data-placement",Re.placement):Re.attributes.popper["data-popper-"+Mt]?ht.setAttribute("data-"+Mt,""):ht.removeAttribute("data-"+Mt)}),Re.attributes.popper={}}}},de=[{name:"offset",options:{offset:tc}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5}},{name:"computeStyles",options:{adaptive:!_}},G];Yo()&&d&&de.push({name:"arrow",options:{element:d,padding:3}}),de.push.apply(de,(gc==null?void 0:gc.modifiers)||[]),Br.popperInstance=An(C,Hn,Object.assign({},gc,{placement:Rc,onFirstUpdate:J,modifiers:de}))}function zl(){Br.popperInstance&&(Br.popperInstance.destroy(),Br.popperInstance=null)}function Zc(){return nn(Hn.querySelectorAll("[data-tippy-root]"))}function Lh(pa){Br.clearDelayTimeouts(),pa&&Rs("onTrigger",[Br,pa]),Vl();var gc=is(!0),Rc=Xo(),tc=Rc[1];Lo.isTouch&&Rc[0]==="hold"&&tc&&(gc=tc),gc?s=setTimeout(function(){Br.show()},gc):Br.show()}function sd(pa){if(Br.clearDelayTimeouts(),Rs("onUntrigger",[Br,pa]),Br.state.isVisible){if(0>Br.props.trigger.indexOf("mouseenter")||0>Br.props.trigger.indexOf("click")||0>["mouseleave","mousemove"].indexOf(pa.type)||!Dt){var gc=is(!1);gc?l=setTimeout(function(){Br.state.isVisible&&Br.hide()},gc):g=requestAnimationFrame(function(){Br.hide()})}}else oc()}}function hs(oe,o){o===void 0&&(o={});var s=Nr.plugins.concat(o.plugins||[]);document.addEventListener("touchstart",ba,$e),window.addEventListener("blur",Do);var l=Object.assign({},o,{plugins:s}),g=ri(oe).reduce(function(M,j){var J=j&&Ea(j,l);return J&&M.push(J),M},[]);return on(oe)?g[0]:g}hs.defaultProps=Nr,hs.setDefaultProps=function(oe){Object.keys(oe).forEach(function(o){Nr[o]=oe[o]})},hs.currentInput=Lo,Object.assign({},bt,{effect:function(oe){var o=oe.state,s={popper:{position:o.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};Object.assign(o.elements.popper.style,s.popper),o.styles=s,o.elements.arrow&&Object.assign(o.elements.arrow.style,s.arrow)}});var Ju={clientX:0,clientY:0},Fa=[];function dc(oe){Ju={clientX:oe.clientX,clientY:oe.clientY}}var el={name:"followCursor",defaultValue:!1,fn:function(oe){var o=oe.reference,s=di(oe.props.triggerTarget||o),l=!1,g=!1,M=!0,j=oe.props;function J(){return oe.props.followCursor==="initial"&&oe.state.isVisible}function ve(){s.addEventListener("mousemove",Dt)}function ze(){s.removeEventListener("mousemove",Dt)}function lt(){l=!0,oe.setProps({getReferenceClientRect:null}),l=!1}function Dt(wr){var Vr=!wr.target||o.contains(wr.target),$r=oe.props.followCursor,Xr=wr.clientX,Gr=wr.clientY,Br=o.getBoundingClientRect(),Tn=Xr-Br.left,Hn=Gr-Br.top;!Vr&&oe.props.interactive||oe.setProps({getReferenceClientRect:function(){var yi=o.getBoundingClientRect(),vo=Xr,Eo=Gr;$r==="initial"&&(vo=yi.left+Tn,Eo=yi.top+Hn);var Xo=$r==="horizontal"?yi.top:Eo,ys=$r==="vertical"?yi.right:vo,Yo=$r==="horizontal"?yi.bottom:Eo,es=$r==="vertical"?yi.left:vo;return{width:ys-es,height:Yo-Xo,top:Xo,right:ys,bottom:Yo,left:es}}})}function $t(){oe.props.followCursor&&(Fa.push({instance:oe,doc:s}),function(wr){wr.addEventListener("mousemove",dc)}(s))}function lr(){(Fa=Fa.filter(function(wr){return wr.instance!==oe})).filter(function(wr){return wr.doc===s}).length===0&&function(wr){wr.removeEventListener("mousemove",dc)}(s)}return{onCreate:$t,onDestroy:lr,onBeforeUpdate:function(){j=oe.props},onAfterUpdate:function(wr,Vr){var $r=Vr.followCursor;l||$r!==void 0&&j.followCursor!==$r&&(lr(),$r?($t(),!oe.state.isMounted||g||J()||ve()):(ze(),lt()))},onMount:function(){oe.props.followCursor&&!g&&(M&&(Dt(Ju),M=!1),J()||ve())},onTrigger:function(wr,Vr){dn(Vr)&&(Ju={clientX:Vr.clientX,clientY:Vr.clientY}),g=Vr.type==="focus"},onHidden:function(){oe.props.followCursor&&(lt(),ze(),M=!0)}}}};hs.setDefaultProps({render:ks});var fl,As,Rl,dl,_c,lu,Pn={showTotalDistance:!1,showDashDistance:!0,showWhen:["normal","active"],format:function(oe){return 1e3>oe?+oe.toFixed(2)+"m":+(oe/1e3).toFixed(2)+"km"}},Wr={showWhen:["normal","active"],format:function(oe){return oe>1e6?"".concat(+(oe/1e6).toFixed(2),"km\xB2"):"".concat(+oe.toFixed(2),"m\xB2")}},Ci={maxSize:100},at={remove:["del","backspace"],revert:["command+z","ctrl+z"],redo:["command+shift+z","ctrl+shift+z"]},Vt={allowHTML:!0,followCursor:!0,placement:"bottom-start",offset:[-10,20],plugins:[el],trigger:"manual",hideOnClick:!1,theme:"light"},gr={data:"drawData",pointAdsorbPixel:12,lineAdsorbPixel:10};function gn(oe,o){var s=Object.keys(oe);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(oe);o&&(l=l.filter(function(g){return Object.getOwnPropertyDescriptor(oe,g).enumerable})),s.push.apply(s,l)}return s}function un(oe){for(var o=1;arguments.length>o;o++){var s=arguments[o]!=null?arguments[o]:{};o%2?gn(Object(s),!0).forEach(function(l){Lr(oe,l,s[l])}):Object.getOwnPropertyDescriptors?Object.defineProperties(oe,Object.getOwnPropertyDescriptors(s)):gn(Object(s)).forEach(function(l){Object.defineProperty(oe,l,Object.getOwnPropertyDescriptor(s,l))})}return oe}function Zi(oe){return Zi=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(o){return typeof o}:function(o){return o&&typeof Symbol=="function"&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o},Zi(oe)}function ho(oe,o){if(!(oe instanceof o))throw new TypeError("Cannot call a class as a function")}function Na(oe,o){for(var s=0;o.length>s;s++){var l=o[s];l.enumerable=l.enumerable||!1,l.configurable=!0,"value"in l&&(l.writable=!0),Object.defineProperty(oe,ya(l.key),l)}}function mn(oe,o,s){return o&&Na(oe.prototype,o),s&&Na(oe,s),Object.defineProperty(oe,"prototype",{writable:!1}),oe}function Lr(oe,o,s){return(o=ya(o))in oe?Object.defineProperty(oe,o,{value:s,enumerable:!0,configurable:!0,writable:!0}):oe[o]=s,oe}function yr(oe,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function");oe.prototype=Object.create(o&&o.prototype,{constructor:{value:oe,writable:!0,configurable:!0}}),Object.defineProperty(oe,"prototype",{writable:!1}),o&&Zr(oe,o)}function Mr(oe){return Mr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(o){return o.__proto__||Object.getPrototypeOf(o)},Mr(oe)}function Zr(oe,o){return Zr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(s,l){return s.__proto__=l,s},Zr(oe,o)}function Vn(oe){if(oe===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return oe}function In(oe){var o=function(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(s){return!1}}();return function(){var s,l=Mr(oe);if(o){var g=Mr(this).constructor;s=Reflect.construct(l,arguments,g)}else s=l.apply(this,arguments);return function(M,j){if(j&&(typeof j=="object"||typeof j=="function"))return j;if(j!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Vn(M)}(this,s)}}function Kn(){return Kn=typeof Reflect!="undefined"&&Reflect.get?Reflect.get.bind():function(oe,o,s){var l=function(M,j){for(;!Object.prototype.hasOwnProperty.call(M,j)&&(M=Mr(M))!==null;);return M}(oe,o);if(l){var g=Object.getOwnPropertyDescriptor(l,o);return g.get?g.get.call(3>arguments.length?oe:s):g.value}},Kn.apply(this,arguments)}function Mi(oe,o){return function(s){if(Array.isArray(s))return s}(oe)||function(s,l){var g=s==null?null:typeof Symbol!="undefined"&&s[Symbol.iterator]||s["@@iterator"];if(g!=null){var M,j,J,ve,ze=[],lt=!0,Dt=!1;try{if(J=(g=g.call(s)).next,l===0){if(Object(g)!==g)return;lt=!1}else for(;!(lt=(M=J.call(g)).done)&&(ze.push(M.value),ze.length!==l);lt=!0);}catch($t){Dt=!0,j=$t}finally{try{if(!lt&&g.return!=null&&(ve=g.return(),Object(ve)!==ve))return}finally{if(Dt)throw j}}return ze}}(oe,o)||ro(oe,o)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function so(oe){return function(o){if(Array.isArray(o))return Ho(o)}(oe)||function(o){if(typeof Symbol!="undefined"&&o[Symbol.iterator]!=null||o["@@iterator"]!=null)return Array.from(o)}(oe)||ro(oe)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function ro(oe,o){if(oe){if(typeof oe=="string")return Ho(oe,o);var s=Object.prototype.toString.call(oe).slice(8,-1);return s==="Object"&&oe.constructor&&(s=oe.constructor.name),s==="Map"||s==="Set"?Array.from(oe):s==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(s)?Ho(oe,o):void 0}}function Ho(oe,o){(o==null||o>oe.length)&&(o=oe.length);for(var s=0,l=Array(o);o>s;s++)l[s]=oe[s];return l}function ya(oe){var o=function(s,l){if(typeof s!="object"||s===null)return s;var g=s[Symbol.toPrimitive];if(g!==void 0){var M=g.call(s,l||"default");if(typeof M!="object")return M;throw new TypeError("@@toPrimitive must return a primitive value.")}return(l==="string"?String:Number)(s)}(oe,"string");return typeof o=="symbol"?o:o+""}(fl=R.DrawEvent||(R.DrawEvent={})).Init="init",fl.Destroy="destroy",fl.Enable="enable",fl.Disable="disable",fl.Add="add",fl.Edit="edit",fl.Remove="remove",fl.Clear="clear",fl.Change="change",fl.DragStart="dragStart",fl.Dragging="dragging",fl.DragEnd="dragEnd",fl.Select="select",fl.AddNode="addNode",fl.RemoveNode="removeNode",(As=R.SourceEvent||(R.SourceEvent={})).Change="change",As.Update="update",(Rl=R.RenderEvent||(R.RenderEvent={})).Click="click",Rl.UnClick="unclick",Rl.Dragstart="dragstart",Rl.Mousemove="mousemove",Rl.Mouseout="mouseout",Rl.Dragging="dragging",Rl.Dragend="dragend",Rl.DblClick="dblClick",Rl.Contextmenu="contextmenu",(dl=R.LayerEvent||(R.LayerEvent={})).Mousedown="mousedown",dl.Mouseup="mouseup",dl.Click="click",dl.UnClick="unclick",dl.Dblclick="dblclick",dl.Mousemove="mousemove",dl.Mouseover="mouseover",dl.Mouseenter="mouseenter",dl.Mouseleave="mouseleave",dl.Mouseout="mouseout",dl.Contextmenu="contextmenu",(_c=R.SceneEvent||(R.SceneEvent={})).Loaded="loaded",_c.MapMove="mapmove",_c.MoveStart="movestart",_c.MoveEnd="moveend",_c.ZoomChange="zoomchange",_c.ZoomStart="zoomstart",_c.ZoomEnd="zoomend",_c.Click="click",_c.Dblclick="dblclick",_c.Mousemove="mousemove",_c.Mousewheel="mousewheel",_c.Mouseover="mouseover",_c.Mouseout="mouseout",_c.Mouseup="mouseup",_c.Mousedown="mousedown",_c.Contextmenu="contextmenu",_c.Dragstart="dragstart",_c.Dragging="dragging",_c.Dragend="dragend",(lu=R.ControlEvent||(R.ControlEvent={})).DrawChange="drawchange",lu.DataChange="datachange",lu.DrawSelect="drawselect",lu.DrawClear="drawclear";var gs=63710088e-1,lo={centimeters:637100880,centimetres:637100880,degrees:57.22891354143274,feet:20902260511392e-6,inches:39.37*gs,kilometers:6371.0088,kilometres:6371.0088,meters:gs,metres:gs,miles:3958.761333810546,millimeters:6371008800,millimetres:6371008800,nauticalmiles:gs/1852,radians:1,yards:6967335223679999e-9},No={acres:247105e-9,centimeters:1e4,centimetres:1e4,feet:10.763910417,hectares:1e-4,inches:1550.003100006,kilometers:1e-6,kilometres:1e-6,meters:1,metres:1,miles:386e-9,millimeters:1e6,millimetres:1e6,yards:1.195990046};function Da(oe,o,s){s===void 0&&(s={});var l={type:"Feature"};return(s.id===0||s.id)&&(l.id=s.id),s.bbox&&(l.bbox=s.bbox),l.properties=o||{},l.geometry=oe,l}function ta(oe,o,s){if(s===void 0&&(s={}),!oe)throw Error("coordinates is required");if(!Array.isArray(oe))throw Error("coordinates must be an Array");if(2>oe.length)throw Error("coordinates must be at least 2 numbers long");if(!wi(oe[0])||!wi(oe[1]))throw Error("coordinates must contain numbers");return Da({type:"Point",coordinates:oe},o,s)}function Ra(oe,o,s){s===void 0&&(s={});for(var l=0,g=oe;g.length>l;l++){var M=g[l];if(4>M.length)throw Error("Each LinearRing of a Polygon must have 4 or more Positions.");for(var j=0;M[M.length-1].length>j;j++)if(M[M.length-1][j]!==M[0][j])throw Error("First and last Position are not equivalent.")}return Da({type:"Polygon",coordinates:oe},o,s)}function ns(oe,o,s){if(s===void 0&&(s={}),2>oe.length)throw Error("coordinates must be an array of two or more positions");return Da({type:"LineString",coordinates:oe},o,s)}function Vo(oe,o){o===void 0&&(o={});var s={type:"FeatureCollection"};return o.id&&(s.id=o.id),o.bbox&&(s.bbox=o.bbox),s.features=oe,s}function bs(oe,o,s){return s===void 0&&(s={}),Da({type:"MultiLineString",coordinates:oe},o,s)}function Js(oe,o,s){return s===void 0&&(s={}),Da({type:"MultiPoint",coordinates:oe},o,s)}function Hu(oe,o,s){return s===void 0&&(s={}),Da({type:"MultiPolygon",coordinates:oe},o,s)}function Of(oe,o){o===void 0&&(o="kilometers");var s=lo[o];if(!s)throw Error(o+" units is invalid");return oe*s}function en(oe,o){o===void 0&&(o="kilometers");var s=lo[o];if(!s)throw Error(o+" units is invalid");return oe/s}function xn(oe){return 180*(oe%(2*Math.PI))/Math.PI}function Vi(oe){return oe%360*Math.PI/180}function wi(oe){return!isNaN(oe)&&oe!==null&&!Array.isArray(oe)}function oo(oe){return!!oe&&oe.constructor===Object}var io=Object.freeze({__proto__:null,earthRadius:gs,factors:lo,unitsFactors:{centimeters:100,centimetres:100,degrees:1/111325,feet:3.28084,inches:39.37,kilometers:.001,kilometres:.001,meters:1,metres:1,miles:1/1609.344,millimeters:1e3,millimetres:1e3,nauticalmiles:1/1852,radians:1/gs,yards:1.0936133},areaFactors:No,feature:Da,geometry:function(oe,o,s){switch(oe){case"Point":return ta(o).geometry;case"LineString":return ns(o).geometry;case"Polygon":return Ra(o).geometry;case"MultiPoint":return Js(o).geometry;case"MultiLineString":return bs(o).geometry;case"MultiPolygon":return Hu(o).geometry;default:throw Error(oe+" is invalid")}},point:ta,points:function(oe,o,s){return s===void 0&&(s={}),Vo(oe.map(function(l){return ta(l,o)}),s)},polygon:Ra,polygons:function(oe,o,s){return s===void 0&&(s={}),Vo(oe.map(function(l){return Ra(l,o)}),s)},lineString:ns,lineStrings:function(oe,o,s){return s===void 0&&(s={}),Vo(oe.map(function(l){return ns(l,o)}),s)},featureCollection:Vo,multiLineString:bs,multiPoint:Js,multiPolygon:Hu,geometryCollection:function(oe,o,s){return s===void 0&&(s={}),Da({type:"GeometryCollection",geometries:oe},o,s)},round:function(oe,o){if(o===void 0&&(o=0),o&&o<0)throw Error("precision must be a positive number");var s=Math.pow(10,o||0);return Math.round(oe*s)/s},radiansToLength:Of,lengthToRadians:en,lengthToDegrees:function(oe,o){return xn(en(oe,o))},bearingToAzimuth:function(oe){var o=oe%360;return 0>o&&(o+=360),o},radiansToDegrees:xn,degreesToRadians:Vi,convertLength:function(oe,o,s){if(o===void 0&&(o="kilometers"),s===void 0&&(s="kilometers"),oe<0)throw Error("length must be a positive number");return Of(en(oe,o),s)},convertArea:function(oe,o,s){if(o===void 0&&(o="meters"),s===void 0&&(s="kilometers"),oe<0)throw Error("area must be a positive number");var l=No[o];if(!l)throw Error("invalid original units");var g=No[s];if(!g)throw Error("invalid final units");return oe/l*g},isNumber:wi,isObject:oo,validateBBox:function(oe){if(!oe)throw Error("bbox is required");if(!Array.isArray(oe))throw Error("bbox must be an Array");if(oe.length!==4&&oe.length!==6)throw Error("bbox must be an Array of 4 or 6 numbers");oe.forEach(function(o){if(!wi(o))throw Error("bbox must only contain numbers")})},validateId:function(oe){if(!oe)throw Error("id is required");if(["string","number"].indexOf(typeof oe)===-1)throw Error("id must be a number or a string")}});function Uo(oe,o,s){if(oe!==null)for(var l,g,M,j,J,ve,ze,lt,Dt=0,$t=0,lr=oe.type,wr=lr==="FeatureCollection",Vr=lr==="Feature",$r=wr?oe.features.length:1,Xr=0;$r>Xr;Xr++){J=(lt=!!(ze=wr?oe.features[Xr].geometry:Vr?oe.geometry:oe)&&ze.type==="GeometryCollection")?ze.geometries.length:1;for(var Gr=0;J>Gr;Gr++){var Br=0,Tn=0;if((j=lt?ze.geometries[Gr]:ze)!==null){ve=j.coordinates;var Hn=j.type;switch(Dt=!s||Hn!=="Polygon"&&Hn!=="MultiPolygon"?0:1,Hn){case null:break;case"Point":if(o(ve,$t,Xr,Br,Tn)===!1)return!1;$t++,Br++;break;case"LineString":case"MultiPoint":for(l=0;ve.length>l;l++){if(o(ve[l],$t,Xr,Br,Tn)===!1)return!1;$t++,Hn==="MultiPoint"&&Br++}Hn==="LineString"&&Br++;break;case"Polygon":case"MultiLineString":for(l=0;ve.length>l;l++){for(g=0;ve[l].length-Dt>g;g++){if(o(ve[l][g],$t,Xr,Br,Tn)===!1)return!1;$t++}Hn==="MultiLineString"&&Br++,Hn==="Polygon"&&Tn++}Hn==="Polygon"&&Br++;break;case"MultiPolygon":for(l=0;ve.length>l;l++){for(Tn=0,g=0;ve[l].length>g;g++){for(M=0;ve[l][g].length-Dt>M;M++){if(o(ve[l][g][M],$t,Xr,Br,Tn)===!1)return!1;$t++}Tn++}Br++}break;case"GeometryCollection":for(l=0;j.geometries.length>l;l++)if(Uo(j.geometries[l],o,s)===!1)return!1;break;default:throw Error("Unknown Geometry Type")}}}}}function na(oe,o){var s;switch(oe.type){case"FeatureCollection":for(s=0;oe.features.length>s&&o(oe.features[s].properties,s)!==!1;s++);break;case"Feature":o(oe.properties,0)}}function $a(oe,o){if(oe.type==="Feature")o(oe,0);else if(oe.type==="FeatureCollection")for(var s=0;oe.features.length>s&&o(oe.features[s],s)!==!1;s++);}function Co(oe){var o=[];return Uo(oe,function(s){o.push(s)}),o}function wo(oe,o){var s,l,g,M,j,J,ve,ze,lt,Dt,$t=0,lr=oe.type==="FeatureCollection",wr=oe.type==="Feature",Vr=lr?oe.features.length:1;for(s=0;Vr>s;s++){for(ze=lr?oe.features[s].properties:wr?oe.properties:{},lt=lr?oe.features[s].bbox:wr?oe.bbox:void 0,Dt=lr?oe.features[s].id:wr?oe.id:void 0,j=(ve=!!(J=lr?oe.features[s].geometry:wr?oe.geometry:oe)&&J.type==="GeometryCollection")?J.geometries.length:1,g=0;j>g;g++)if((M=ve?J.geometries[g]:J)!==null)switch(M.type){case"Point":case"LineString":case"MultiPoint":case"Polygon":case"MultiLineString":case"MultiPolygon":if(o(M,$t,ze,lt,Dt)===!1)return!1;break;case"GeometryCollection":for(l=0;M.geometries.length>l;l++)if(o(M.geometries[l],$t,ze,lt,Dt)===!1)return!1;break;default:throw Error("Unknown Geometry Type")}else if(o(null,$t,ze,lt,Dt)===!1)return!1;$t++}}function Pa(oe,o,s){var l=s;return wo(oe,function(g,M,j,J,ve){l=M===0&&s===void 0?g:o(l,g,M,j,J,ve)}),l}function ss(oe,o){wo(oe,function(s,l,g,M,j){var J,ve=s===null?null:s.type;switch(ve){case null:case"Point":case"LineString":case"Polygon":return o(Da(s,g,{bbox:M,id:j}),l,0)!==!1&&void 0}switch(ve){case"MultiPoint":J="Point";break;case"MultiLineString":J="LineString";break;case"MultiPolygon":J="Polygon"}for(var ze=0;s.coordinates.length>ze;ze++)if(o(Da({type:J,coordinates:s.coordinates[ze]},g),l,ze)===!1)return!1})}function si(oe,o){ss(oe,function(s,l,g){var M=0;if(s.geometry){var j=s.geometry.type;if(j!=="Point"&&j!=="MultiPoint"){var J,ve=0,ze=0,lt=0;return Uo(s,function(Dt,$t,lr,wr,Vr){if(J===void 0||l>ve||wr>ze||Vr>lt)return J=Dt,ve=l,ze=wr,lt=Vr,void(M=0);var $r=ns([J,Dt],s.properties);if(o($r,l,g,Vr,M)===!1)return!1;M++,J=Dt})!==!1&&void 0}}})}function Ms(oe,o,s){var l=s,g=!1;return si(oe,function(M,j,J,ve,ze){l=g===!1&&s===void 0?M:o(l,M,j,J,ve,ze),g=!0}),l}function Ns(oe,o){if(!oe)throw Error("geojson is required");ss(oe,function(s,l,g){if(s.geometry!==null){var M=s.geometry.coordinates;switch(s.geometry.type){case"LineString":if(o(s,l,g,0,0)===!1)return!1;break;case"Polygon":for(var j=0;M.length>j;j++)if(o(ns(M[j],s.properties),l,g,j)===!1)return!1}}})}var Aa=Object.freeze({__proto__:null,coordAll:Co,coordEach:Uo,coordReduce:function(oe,o,s,l){var g=s;return Uo(oe,function(M,j,J,ve,ze){g=j===0&&s===void 0?M:o(g,M,j,J,ve,ze)},l),g},featureEach:$a,featureReduce:function(oe,o,s){var l=s;return $a(oe,function(g,M){l=M===0&&s===void 0?g:o(l,g,M)}),l},findPoint:function(oe,o){if(!oo(o=o||{}))throw Error("options is invalid");var s,l=o.featureIndex||0,g=o.multiFeatureIndex||0,M=o.geometryIndex||0,j=o.coordIndex||0,J=o.properties;switch(oe.type){case"FeatureCollection":0>l&&(l=oe.features.length+l),J=J||oe.features[l].properties,s=oe.features[l].geometry;break;case"Feature":J=J||oe.properties,s=oe.geometry;break;case"Point":case"MultiPoint":return null;case"LineString":case"Polygon":case"MultiLineString":case"MultiPolygon":s=oe;break;default:throw Error("geojson is invalid")}if(s===null)return null;var ve=s.coordinates;switch(s.type){case"Point":return ta(ve,J,o);case"MultiPoint":return 0>g&&(g=ve.length+g),ta(ve[g],J,o);case"LineString":return 0>j&&(j=ve.length+j),ta(ve[j],J,o);case"Polygon":return 0>M&&(M=ve.length+M),0>j&&(j=ve[M].length+j),ta(ve[M][j],J,o);case"MultiLineString":return 0>g&&(g=ve.length+g),0>j&&(j=ve[g].length+j),ta(ve[g][j],J,o);case"MultiPolygon":return 0>g&&(g=ve.length+g),0>M&&(M=ve[g].length+M),0>j&&(j=ve[g][M].length-j),ta(ve[g][M][j],J,o)}throw Error("geojson is invalid")},findSegment:function(oe,o){if(!oo(o=o||{}))throw Error("options is invalid");var s,l=o.featureIndex||0,g=o.multiFeatureIndex||0,M=o.geometryIndex||0,j=o.segmentIndex||0,J=o.properties;switch(oe.type){case"FeatureCollection":0>l&&(l=oe.features.length+l),J=J||oe.features[l].properties,s=oe.features[l].geometry;break;case"Feature":J=J||oe.properties,s=oe.geometry;break;case"Point":case"MultiPoint":return null;case"LineString":case"Polygon":case"MultiLineString":case"MultiPolygon":s=oe;break;default:throw Error("geojson is invalid")}if(s===null)return null;var ve=s.coordinates;switch(s.type){case"Point":case"MultiPoint":return null;case"LineString":return 0>j&&(j=ve.length+j-1),ns([ve[j],ve[j+1]],J,o);case"Polygon":return 0>M&&(M=ve.length+M),0>j&&(j=ve[M].length+j-1),ns([ve[M][j],ve[M][j+1]],J,o);case"MultiLineString":return 0>g&&(g=ve.length+g),0>j&&(j=ve[g].length+j-1),ns([ve[g][j],ve[g][j+1]],J,o);case"MultiPolygon":return 0>g&&(g=ve.length+g),0>M&&(M=ve[g].length+M),0>j&&(j=ve[g][M].length-j-1),ns([ve[g][M][j],ve[g][M][j+1]],J,o)}throw Error("geojson is invalid")},flattenEach:ss,flattenReduce:function(oe,o,s){var l=s;return ss(oe,function(g,M,j){l=M===0&&j===0&&s===void 0?g:o(l,g,M,j)}),l},geomEach:wo,geomReduce:Pa,lineEach:Ns,lineReduce:function(oe,o,s){var l=s;return Ns(oe,function(g,M,j,J){l=M===0&&s===void 0?g:o(l,g,M,j,J)}),l},propEach:na,propReduce:function(oe,o,s){var l=s;return na(oe,function(g,M){l=M===0&&s===void 0?g:o(l,g,M)}),l},segmentEach:si,segmentReduce:Ms});function qs(oe){var o=[1/0,1/0,-1/0,-1/0];return Uo(oe,function(s){o[0]>s[0]&&(o[0]=s[0]),o[1]>s[1]&&(o[1]=s[1]),s[0]>o[2]&&(o[2]=s[0]),s[1]>o[3]&&(o[3]=s[1])}),o}qs.default=qs;var Eu=Object.freeze({__proto__:null,default:qs});function Cs(oe){if(!oe)throw Error("coord is required");if(!Array.isArray(oe)){if(oe.type==="Feature"&&oe.geometry!==null&&oe.geometry.type==="Point")return oe.geometry.coordinates;if(oe.type==="Point")return oe.coordinates}if(Array.isArray(oe)&&oe.length>=2&&!Array.isArray(oe[0])&&!Array.isArray(oe[1]))return oe;throw Error("coord must be GeoJSON Point or an Array of numbers")}function su(oe){if(Array.isArray(oe))return oe;if(oe.type==="Feature"){if(oe.geometry!==null)return oe.geometry.coordinates}else if(oe.coordinates)return oe.coordinates;throw Error("coords must be GeoJSON Feature, Geometry Object or an Array")}function Vs(oe){return oe.type==="Feature"?oe.geometry:oe}function tl(oe,o){return oe.type==="FeatureCollection"?"FeatureCollection":oe.type==="GeometryCollection"?"GeometryCollection":oe.type==="Feature"&&oe.geometry!==null?oe.geometry.type:oe.type}function Xs(oe,o,s,l,g){rc(oe,o,s||0,l||oe.length-1,g||Qs)}function rc(oe,o,s,l,g){for(;l>s;){if(l-s>600){var M=l-s+1,j=o-s+1,J=Math.log(M),ve=.5*Math.exp(2*J/3),ze=.5*Math.sqrt(J*ve*(M-ve)/M)*(0>j-M/2?-1:1);rc(oe,o,Math.max(s,Math.floor(o-j*ve/M+ze)),Math.min(l,Math.floor(o+(M-j)*ve/M+ze)),g)}var lt=oe[o],Dt=s,$t=l;for(Ha(oe,s,o),g(oe[l],lt)>0&&Ha(oe,s,l);$t>Dt;){for(Ha(oe,Dt,$t),Dt++,$t--;0>g(oe[Dt],lt);)Dt++;for(;g(oe[$t],lt)>0;)$t--}g(oe[s],lt)===0?Ha(oe,s,$t):Ha(oe,++$t,l),$t>o||(s=$t+1),o>$t||(l=$t-1)}}function Ha(oe,o,s){var l=oe[o];oe[o]=oe[s],oe[s]=l}function Qs(oe,o){return o>oe?-1:oe>o?1:0}function Uu(oe,o,s){if(!s)return o.indexOf(oe);for(let l=0;o.length>l;l++)if(s(oe,o[l]))return l;return-1}function St(oe,o){Zs(oe,0,oe.children.length,o,oe)}function Zs(oe,o,s,l,g){g||(g=ul(null)),g.minX=1/0,g.minY=1/0,g.maxX=-1/0,g.maxY=-1/0;for(let M=o;s>M;M++){const j=oe.children[M];yu(g,oe.leaf?l(j):j)}return g}function yu(oe,o){return oe.minX=Math.min(oe.minX,o.minX),oe.minY=Math.min(oe.minY,o.minY),oe.maxX=Math.max(oe.maxX,o.maxX),oe.maxY=Math.max(oe.maxY,o.maxY),oe}function pl(oe,o){return oe.minX-o.minX}function Ku(oe,o){return oe.minY-o.minY}function eu(oe){return(oe.maxX-oe.minX)*(oe.maxY-oe.minY)}function Qo(oe){return oe.maxX-oe.minX+(oe.maxY-oe.minY)}function ps(oe,o){const s=Math.max(oe.minX,o.minX),l=Math.max(oe.minY,o.minY),g=Math.min(oe.maxX,o.maxX),M=Math.min(oe.maxY,o.maxY);return Math.max(0,g-s)*Math.max(0,M-l)}function xl(oe,o){return!(oe.minX>o.minX||oe.minY>o.minY||o.maxX>oe.maxX||o.maxY>oe.maxY)}function Yl(oe,o){return!(o.minX>oe.maxX||o.minY>oe.maxY||oe.minX>o.maxX||oe.minY>o.maxY)}function ul(oe){return{children:oe,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function Ef(oe,o,s,l,g){const M=[o,s];for(;M.length;){if(l>=(s=M.pop())-(o=M.pop()))continue;const j=o+Math.ceil((s-o)/l/2)*l;Xs(oe,j,o,s,g),M.push(o,j,j,s)}}var sf=Object.freeze({__proto__:null,default:class{constructor(oe=9){this._maxEntries=Math.max(4,oe),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),this.clear()}all(){return this._all(this.data,[])}search(oe){let o=this.data;const s=[];if(!Yl(oe,o))return s;const l=this.toBBox,g=[];for(;o;){for(let M=0;o.children.length>M;M++){const j=o.children[M],J=o.leaf?l(j):j;Yl(oe,J)&&(o.leaf?s.push(j):xl(oe,J)?this._all(j,s):g.push(j))}o=g.pop()}return s}collides(oe){let o=this.data;if(!Yl(oe,o))return!1;const s=[];for(;o;){for(let l=0;o.children.length>l;l++){const g=o.children[l],M=o.leaf?this.toBBox(g):g;if(Yl(oe,M)){if(o.leaf||xl(oe,M))return!0;s.push(g)}}o=s.pop()}return!1}load(oe){if(!oe||!oe.length)return this;if(this._minEntries>oe.length){for(let s=0;oe.length>s;s++)this.insert(oe[s]);return this}let o=this._build(oe.slice(),0,oe.length-1,0);if(this.data.children.length)if(this.data.height===o.height)this._splitRoot(this.data,o);else{if(o.height>this.data.height){const s=this.data;this.data=o,o=s}this._insert(o,this.data.height-o.height-1,!0)}else this.data=o;return this}insert(oe){return oe&&this._insert(oe,this.data.height-1),this}clear(){return this.data=ul([]),this}remove(oe,o){if(!oe)return this;let s=this.data;const l=this.toBBox(oe),g=[],M=[];let j,J,ve;for(;s||g.length;){if(s||(s=g.pop(),J=g[g.length-1],j=M.pop(),ve=!0),s.leaf){const ze=Uu(oe,s.children,o);if(ze!==-1)return s.children.splice(ze,1),g.push(s),this._condense(g),this}ve||s.leaf||!xl(s,l)?J?(j++,s=J.children[j],ve=!1):s=null:(g.push(s),M.push(j),j=0,J=s,s=s.children[0])}return this}toBBox(oe){return oe}compareMinX(oe,o){return oe.minX-o.minX}compareMinY(oe,o){return oe.minY-o.minY}toJSON(){return this.data}fromJSON(oe){return this.data=oe,this}_all(oe,o){const s=[];for(;oe;)oe.leaf?o.push(...oe.children):s.push(...oe.children),oe=s.pop();return o}_build(oe,o,s,l){const g=s-o+1;let M,j=this._maxEntries;if(j>=g)return M=ul(oe.slice(o,s+1)),St(M,this.toBBox),M;l||(j=Math.ceil(g/Math.pow(j,(l=Math.ceil(Math.log(g)/Math.log(j)))-1))),M=ul([]),M.leaf=!1,M.height=l;const J=Math.ceil(g/j),ve=J*Math.ceil(Math.sqrt(j));Ef(oe,o,s,ve,this.compareMinX);for(let ze=o;s>=ze;ze+=ve){const lt=Math.min(ze+ve-1,s);Ef(oe,ze,lt,J,this.compareMinY);for(let Dt=ze;lt>=Dt;Dt+=J)M.children.push(this._build(oe,Dt,Math.min(Dt+J-1,lt),l-1))}return St(M,this.toBBox),M}_chooseSubtree(oe,o,s,l){for(;l.push(o),!o.leaf&&l.length-1!==s;){let j,J=1/0,ve=1/0;for(let ze=0;o.children.length>ze;ze++){const lt=o.children[ze],Dt=eu(lt),$t=(Math.max((M=lt).maxX,(g=oe).maxX)-Math.min(M.minX,g.minX))*(Math.max(M.maxY,g.maxY)-Math.min(M.minY,g.minY))-Dt;ve>$t?(ve=$t,J=J>Dt?Dt:J,j=lt):$t===ve&&J>Dt&&(J=Dt,j=lt)}o=j||o.children[0]}var g,M;return o}_insert(oe,o,s){const l=s?oe:this.toBBox(oe),g=[],M=this._chooseSubtree(l,this.data,o,g);for(M.children.push(oe),yu(M,l);o>=0&&g[o].children.length>this._maxEntries;)this._split(g,o),o--;this._adjustParentBBoxes(l,g,o)}_split(oe,o){const s=oe[o],l=s.children.length,g=this._minEntries;this._chooseSplitAxis(s,g,l);const M=this._chooseSplitIndex(s,g,l),j=ul(s.children.splice(M,s.children.length-M));j.height=s.height,j.leaf=s.leaf,St(s,this.toBBox),St(j,this.toBBox),o?oe[o-1].children.push(j):this._splitRoot(s,j)}_splitRoot(oe,o){this.data=ul([oe,o]),this.data.height=oe.height+1,this.data.leaf=!1,St(this.data,this.toBBox)}_chooseSplitIndex(oe,o,s){let l,g=1/0,M=1/0;for(let j=o;s-o>=j;j++){const J=Zs(oe,0,j,this.toBBox),ve=Zs(oe,j,s,this.toBBox),ze=ps(J,ve),lt=eu(J)+eu(ve);g>ze?(g=ze,l=j,M=M>lt?lt:M):ze===g&&M>lt&&(M=lt,l=j)}return l||s-o}_chooseSplitAxis(oe,o,s){const l=oe.leaf?this.compareMinX:pl,g=oe.leaf?this.compareMinY:Ku,M=this._allDistMargin(oe,o,s,l);this._allDistMargin(oe,o,s,g)>M&&oe.children.sort(l)}_allDistMargin(oe,o,s,l){oe.children.sort(l);const g=this.toBBox,M=Zs(oe,0,o,g),j=Zs(oe,s-o,s,g);let J=Qo(M)+Qo(j);for(let ve=o;s-o>ve;ve++){const ze=oe.children[ve];yu(M,oe.leaf?g(ze):ze),J+=Qo(M)}for(let ve=s-o-1;ve>=o;ve--){const ze=oe.children[ve];yu(j,oe.leaf?g(ze):ze),J+=Qo(j)}return J}_adjustParentBBoxes(oe,o,s){for(let l=s;l>=0;l--)yu(o[l],oe)}_condense(oe){for(let o,s=oe.length-1;s>=0;s--)oe[s].children.length===0?s>0?(o=oe[s-1].children,o.splice(o.indexOf(oe[s]),1)):this.clear():St(oe[s],this.toBBox)}}});function Hf(oe,o){return o>oe?-1:oe>o?1:0}var Ul=Object.freeze({__proto__:null,default:class{constructor(oe=[],o=Hf){if(this.data=oe,this.length=this.data.length,this.compare=o,this.length>0)for(let s=(this.length>>1)-1;s>=0;s--)this._down(s)}push(oe){this.data.push(oe),this.length++,this._up(this.length-1)}pop(){if(this.length===0)return;const oe=this.data[0],o=this.data.pop();return this.length--,this.length>0&&(this.data[0]=o,this._down(0)),oe}peek(){return this.data[0]}_up(oe){const{data:o,compare:s}=this,l=o[oe];for(;oe>0;){const g=oe-1>>1,M=o[g];if(s(l,M)>=0)break;o[oe]=M,oe=g}o[oe]=l}_down(oe){const{data:o,compare:s}=this,l=this.length>>1,g=o[oe];for(;l>oe;){let M=1+(oe<<1),j=o[M];const J=M+1;if(this.length>J&&0>s(o[J],j)&&(M=J,j=o[J]),s(j,g)>=0)break;o[oe]=j,oe=M}o[oe]=g}}}),Lf=function(oe,o,s,l){var g=oe[0],M=oe[1],j=!1;s===void 0&&(s=0),l===void 0&&(l=o.length);for(var J=(l-s)/2,ve=0,ze=J-1;J>ve;ze=ve++){var lt=o[s+2*ve+0],Dt=o[s+2*ve+1],$t=o[s+2*ze+1];Dt>M!=$t>M&&(o[s+2*ze+0]-lt)*(M-Dt)/($t-Dt)+lt>g&&(j=!j)}return j},Fc=function(oe,o,s,l){var g=oe[0],M=oe[1],j=!1;s===void 0&&(s=0),l===void 0&&(l=o.length);for(var J=l-s,ve=0,ze=J-1;J>ve;ze=ve++){var lt=o[ve+s][0],Dt=o[ve+s][1],$t=o[ze+s][1];Dt>M!=$t>M&&(o[ze+s][0]-lt)*(M-Dt)/($t-Dt)+lt>g&&(j=!j)}return j},Ol=function(oe,o,s,l){return o.length>0&&Array.isArray(o[0])?Fc(oe,o,s,l):Lf(oe,o,s,l)},_l=Lf;Ol.nested=Fc,Ol.flat=_l;var cn=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof A.g!="undefined"?A.g:typeof self!="undefined"?self:{};function an(oe,o,s){return oe(s={path:o,exports:{},require:function(l,g){return function(){throw Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}()}},s.exports),s.exports}function Xn(oe){if(oe.__esModule)return oe;var o=Object.defineProperty({},"__esModule",{value:!0});return Object.keys(oe).forEach(function(s){var l=Object.getOwnPropertyDescriptor(oe,s);Object.defineProperty(o,s,l.get?l:{enumerable:!0,get:function(){return oe[s]}})}),o}var vi=an(function(oe,o){(function(s){const g=33306690738754706e-32;function M(Vr,$r,Xr,Gr,Br){let Tn,Hn,yi,vo,Eo=$r[0],Xo=Gr[0],ys=0,Yo=0;Xo>Eo==Xo>-Eo?(Tn=Eo,Eo=$r[++ys]):(Tn=Xo,Xo=Gr[++Yo]);let es=0;if(Vr>ys&&Xr>Yo)for(Xo>Eo==Xo>-Eo?(yi=Tn-((Hn=Eo+Tn)-Eo),Eo=$r[++ys]):(yi=Tn-((Hn=Xo+Tn)-Xo),Xo=Gr[++Yo]),Tn=Hn,yi!==0&&(Br[es++]=yi);Vr>ys&&Xr>Yo;)Xo>Eo==Xo>-Eo?(yi=Tn-((Hn=Tn+Eo)-(vo=Hn-Tn))+(Eo-vo),Eo=$r[++ys]):(yi=Tn-((Hn=Tn+Xo)-(vo=Hn-Tn))+(Xo-vo),Xo=Gr[++Yo]),Tn=Hn,yi!==0&&(Br[es++]=yi);for(;Vr>ys;)yi=Tn-((Hn=Tn+Eo)-(vo=Hn-Tn))+(Eo-vo),Eo=$r[++ys],Tn=Hn,yi!==0&&(Br[es++]=yi);for(;Xr>Yo;)yi=Tn-((Hn=Tn+Xo)-(vo=Hn-Tn))+(Xo-vo),Xo=Gr[++Yo],Tn=Hn,yi!==0&&(Br[es++]=yi);return Tn===0&&es!==0||(Br[es++]=Tn),es}function j(Vr){return new Float64Array(Vr)}const J=33306690738754716e-32,ve=22204460492503146e-32,ze=11093356479670487e-47,lt=j(4),Dt=j(8),$t=j(12),lr=j(16),wr=j(4);s.orient2d=function(Vr,$r,Xr,Gr,Br,Tn){const Hn=($r-Tn)*(Xr-Br),yi=(Vr-Br)*(Gr-Tn),vo=Hn-yi;if(Hn===0||yi===0||Hn>0!=yi>0)return vo;const Eo=Math.abs(Hn+yi);return J*Eo>Math.abs(vo)?-function(Xo,ys,Yo,es,qa,Ts,is){let ts,Rs,pu,nl,la,Es,sl,Bf,Vl,oc,zc,xc,ih,wh,hh,dh,Jf,pf;const ec=Xo-qa,Jc=Yo-qa,zl=ys-Ts,Zc=es-Ts;la=(hh=(Bf=ec-(sl=(Es=134217729*ec)-(Es-ec)))*(oc=Zc-(Vl=(Es=134217729*Zc)-(Es-Zc)))-((wh=ec*Zc)-sl*Vl-Bf*Vl-sl*oc))-(zc=hh-(Jf=(Bf=zl-(sl=(Es=134217729*zl)-(Es-zl)))*(oc=Jc-(Vl=(Es=134217729*Jc)-(Es-Jc)))-((dh=zl*Jc)-sl*Vl-Bf*Vl-sl*oc))),lt[0]=hh-(zc+la)+(la-Jf),la=(ih=wh-((xc=wh+zc)-(la=xc-wh))+(zc-la))-(zc=ih-dh),lt[1]=ih-(zc+la)+(la-dh),la=(pf=xc+zc)-xc,lt[2]=xc-(pf-la)+(zc-la),lt[3]=pf;let Lh=function(tc,oh){let _=oh[0];for(let d=1;tc>d;d++)_+=oh[d];return _}(4,lt),sd=ve*is;if(Lh>=sd||-Lh>=sd||(ts=Xo-(ec+(la=Xo-ec))+(la-qa),pu=Yo-(Jc+(la=Yo-Jc))+(la-qa),Rs=ys-(zl+(la=ys-zl))+(la-Ts),nl=es-(Zc+(la=es-Zc))+(la-Ts),ts===0&&Rs===0&&pu===0&&nl===0)||(sd=ze*is+g*Math.abs(Lh),(Lh+=ec*nl+Zc*ts-(zl*pu+Jc*Rs))>=sd||-Lh>=sd))return Lh;la=(hh=(Bf=ts-(sl=(Es=134217729*ts)-(Es-ts)))*(oc=Zc-(Vl=(Es=134217729*Zc)-(Es-Zc)))-((wh=ts*Zc)-sl*Vl-Bf*Vl-sl*oc))-(zc=hh-(Jf=(Bf=Rs-(sl=(Es=134217729*Rs)-(Es-Rs)))*(oc=Jc-(Vl=(Es=134217729*Jc)-(Es-Jc)))-((dh=Rs*Jc)-sl*Vl-Bf*Vl-sl*oc))),wr[0]=hh-(zc+la)+(la-Jf),la=(ih=wh-((xc=wh+zc)-(la=xc-wh))+(zc-la))-(zc=ih-dh),wr[1]=ih-(zc+la)+(la-dh),la=(pf=xc+zc)-xc,wr[2]=xc-(pf-la)+(zc-la),wr[3]=pf;const pa=M(4,lt,4,wr,Dt);la=(hh=(Bf=ec-(sl=(Es=134217729*ec)-(Es-ec)))*(oc=nl-(Vl=(Es=134217729*nl)-(Es-nl)))-((wh=ec*nl)-sl*Vl-Bf*Vl-sl*oc))-(zc=hh-(Jf=(Bf=zl-(sl=(Es=134217729*zl)-(Es-zl)))*(oc=pu-(Vl=(Es=134217729*pu)-(Es-pu)))-((dh=zl*pu)-sl*Vl-Bf*Vl-sl*oc))),wr[0]=hh-(zc+la)+(la-Jf),la=(ih=wh-((xc=wh+zc)-(la=xc-wh))+(zc-la))-(zc=ih-dh),wr[1]=ih-(zc+la)+(la-dh),la=(pf=xc+zc)-xc,wr[2]=xc-(pf-la)+(zc-la),wr[3]=pf;const gc=M(pa,Dt,4,wr,$t);la=(hh=(Bf=ts-(sl=(Es=134217729*ts)-(Es-ts)))*(oc=nl-(Vl=(Es=134217729*nl)-(Es-nl)))-((wh=ts*nl)-sl*Vl-Bf*Vl-sl*oc))-(zc=hh-(Jf=(Bf=Rs-(sl=(Es=134217729*Rs)-(Es-Rs)))*(oc=pu-(Vl=(Es=134217729*pu)-(Es-pu)))-((dh=Rs*pu)-sl*Vl-Bf*Vl-sl*oc))),wr[0]=hh-(zc+la)+(la-Jf),la=(ih=wh-((xc=wh+zc)-(la=xc-wh))+(zc-la))-(zc=ih-dh),wr[1]=ih-(zc+la)+(la-dh),la=(pf=xc+zc)-xc,wr[2]=xc-(pf-la)+(zc-la),wr[3]=pf;const Rc=M(gc,$t,4,wr,lr);return lr[Rc-1]}(Vr,$r,Xr,Gr,Br,Tn,Eo):vo},s.orient2dfast=function(Vr,$r,Xr,Gr,Br,Tn){return($r-Tn)*(Xr-Br)-(Vr-Br)*(Gr-Tn)},Object.defineProperty(s,"__esModule",{value:!0})})(o)}),to=Xn(sf),zo=Xn(Ul),Ia=vi.orient2d;zo.default&&(zo=zo.default);var Sa=fa;function fa(oe,o,s){o=Math.max(0,o===void 0?2:o),s=s||0;var l=function(Gr){for(var Br=Gr[0],Tn=Gr[0],Hn=Gr[0],yi=Gr[0],vo=0;Gr.length>vo;vo++){var Eo=Gr[vo];Br[0]>Eo[0]&&(Br=Eo),Eo[0]>Hn[0]&&(Hn=Eo),Tn[1]>Eo[1]&&(Tn=Eo),Eo[1]>yi[1]&&(yi=Eo)}var Xo=[Br,Tn,Hn,yi],ys=Xo.slice();for(vo=0;Gr.length>vo;vo++)Ol(Gr[vo],Xo)||ys.push(Gr[vo]);return function(Yo){Yo.sort(al);for(var es=[],qa=0;Yo.length>qa;qa++){for(;es.length>=2&&0>=wl(es[es.length-2],es[es.length-1],Yo[qa]);)es.pop();es.push(Yo[qa])}for(var Ts=[],is=Yo.length-1;is>=0;is--){for(;Ts.length>=2&&0>=wl(Ts[Ts.length-2],Ts[Ts.length-1],Yo[is]);)Ts.pop();Ts.push(Yo[is])}return Ts.pop(),es.pop(),es.concat(Ts)}(ys)}(oe),g=new to(16);g.toBBox=function(Gr){return{minX:Gr[0],minY:Gr[1],maxX:Gr[0],maxY:Gr[1]}},g.compareMinX=function(Gr,Br){return Gr[0]-Br[0]},g.compareMinY=function(Gr,Br){return Gr[1]-Br[1]},g.load(oe);for(var M,j=[],J=0;l.length>J;J++){var ve=l[J];g.remove(ve),M=ml(ve,M),j.push(M)}var ze=new to(16);for(J=0;j.length>J;J++)ze.insert(vu(j[J]));for(var lt=o*o,Dt=s*s;j.length;){var $t=j.shift(),lr=$t.p,wr=$t.next.p,Vr=ll(lr,wr);if(Vr>=Dt){var $r=Vr/lt;(ve=cs(g,$t.prev.p,lr,wr,$t.next.next.p,$r,ze))&&Math.min(ll(ve,lr),ll(ve,wr))<=$r&&(j.push($t),j.push(ml(ve,$t)),g.remove(ve),ze.remove($t),ze.insert(vu($t)),ze.insert(vu($t.next)))}}$t=M;var Xr=[];do Xr.push($t.p),$t=$t.next;while($t!==M);return Xr.push($t.p),Xr}function cs(oe,o,s,l,g,M,j){for(var J=new zo([],Ys),ve=oe.data;ve;){for(var ze=0;ve.children.length>ze;ze++){var lt=ve.children[ze],Dt=ve.leaf?Fu(lt,s,l):mu(s,l,lt);M$t.dist&&Vr>$t.dist&&Sl(s,lr,j)&&Sl(l,lr,j))return lr}(ve=J.pop())&&(ve=ve.node)}return null}function Ys(oe,o){return oe.dist-o.dist}function mu(oe,o,s){if(Is(oe,s)||Is(o,s))return 0;var l=Bu(oe[0],oe[1],o[0],o[1],s.minX,s.minY,s.maxX,s.minY);if(l===0)return 0;var g=Bu(oe[0],oe[1],o[0],o[1],s.minX,s.minY,s.minX,s.maxY);if(g===0)return 0;var M=Bu(oe[0],oe[1],o[0],o[1],s.maxX,s.minY,s.maxX,s.maxY);if(M===0)return 0;var j=Bu(oe[0],oe[1],o[0],o[1],s.minX,s.maxY,s.maxX,s.maxY);return j===0?0:Math.min(l,g,M,j)}function Is(oe,o){return!(o.minX>oe[0]||oe[0]>o.maxX||o.minY>oe[1]||oe[1]>o.maxY)}function Sl(oe,o,s){for(var l,g,M,j,J=s.search({minX:Math.min(oe[0],o[0]),minY:Math.min(oe[1],o[1]),maxX:Math.max(oe[0],o[0]),maxY:Math.max(oe[1],o[1])}),ve=0;J.length>ve;ve++)if(g=J[ve].next.p,M=oe,(l=J[ve].p)!==(j=o)&&g!==M&&wl(l,g,M)>0!=wl(l,g,j)>0&&wl(M,j,l)>0!=wl(M,j,g)>0)return!1;return!0}function wl(oe,o,s){return Ia(oe[0],oe[1],o[0],o[1],s[0],s[1])}function vu(oe){var o=oe.p,s=oe.next.p;return oe.minX=Math.min(o[0],s[0]),oe.minY=Math.min(o[1],s[1]),oe.maxX=Math.max(o[0],s[0]),oe.maxY=Math.max(o[1],s[1]),oe}function ml(oe,o){var s={p:oe,prev:null,next:null,minX:0,minY:0,maxX:0,maxY:0};return o?(s.next=o.next,s.prev=o,o.next.prev=s,o.next=s):(s.prev=s,s.next=s),s}function ll(oe,o){var s=oe[0]-o[0],l=oe[1]-o[1];return s*s+l*l}function Fu(oe,o,s){var l=o[0],g=o[1],M=s[0]-l,j=s[1]-g;if(M!==0||j!==0){var J=((oe[0]-l)*M+(oe[1]-g)*j)/(M*M+j*j);J>1?(l=s[0],g=s[1]):J>0&&(l+=M*J,g+=j*J)}return(M=oe[0]-l)*M+(j=oe[1]-g)*j}function Bu(oe,o,s,l,g,M,j,J){var ve,ze,lt,Dt,$t=s-oe,lr=l-o,wr=j-g,Vr=J-M,$r=oe-g,Xr=o-M,Gr=$t*$t+lr*lr,Br=$t*wr+lr*Vr,Tn=wr*wr+Vr*Vr,Hn=$t*$r+lr*Xr,yi=wr*$r+Vr*Xr,vo=Gr*Tn-Br*Br,Eo=vo,Xo=vo;vo===0?(ze=0,Eo=1,Dt=yi,Xo=Tn):(Dt=Gr*yi-Br*Hn,0>(ze=Br*yi-Tn*Hn)?(ze=0,Dt=yi,Xo=Tn):ze>Eo&&(ze=Eo,Dt=yi+Br,Xo=Tn)),0>Dt?(Dt=0,0>-Hn?ze=0:-Hn>Gr?ze=Eo:(ze=-Hn,Eo=Gr)):Dt>Xo&&(Dt=Xo,0>-Hn+Br?ze=0:-Hn+Br>Gr?ze=Eo:(ze=-Hn+Br,Eo=Gr));var ys=(1-(lt=Dt===0?0:Dt/Xo))*g+lt*j-((1-(ve=ze===0?0:ze/Eo))*oe+ve*s),Yo=(1-lt)*M+lt*J-((1-ve)*o+ve*l);return ys*ys+Yo*Yo}function al(oe,o){return oe[0]===o[0]?oe[1]-o[1]:oe[0]-o[0]}function Ac(oe,o,s){s===void 0&&(s={});var l=Cs(oe),g=Cs(o),M=Vi(g[1]-l[1]),j=Vi(g[0]-l[0]),J=Vi(l[1]),ve=Vi(g[1]),ze=Math.pow(Math.sin(M/2),2)+Math.pow(Math.sin(j/2),2)*Math.cos(J)*Math.cos(ve);return Of(2*Math.atan2(Math.sqrt(ze),Math.sqrt(1-ze)),s.units)}function $l(oe){return function(o,s){s===void 0&&(s={});var l=Number(o[0]),g=Number(o[1]),M=Number(o[2]),j=Number(o[3]);if(o.length===6)throw Error("@turf/bbox-polygon does not support BBox with 6 positions");var J=[l,g];return Ra([[J,[M,g],[M,j],[l,j],J]],s.properties,{bbox:o,id:s.id})}(qs(oe))}function Yu(oe,o,s,l){l===void 0&&(l={});var g=Cs(oe),M=Vi(g[0]),j=Vi(g[1]),J=Vi(s),ve=en(o,l.units),ze=Math.asin(Math.sin(j)*Math.cos(ve)+Math.cos(j)*Math.sin(ve)*Math.cos(J));return ta([xn(M+Math.atan2(Math.sin(J)*Math.sin(ve)*Math.cos(j),Math.cos(ve)-Math.sin(j)*Math.sin(ze))),xn(ze)],l.properties)}function Gu(oe,o,s){if(s===void 0&&(s={}),s.final===!0)return function(ze,lt){var Dt=Gu(lt,ze);return Dt=(Dt+180)%360}(oe,o);var l=Cs(oe),g=Cs(o),M=Vi(l[0]),j=Vi(g[0]),J=Vi(l[1]),ve=Vi(g[1]);return xn(Math.atan2(Math.sin(j-M)*Math.cos(ve),Math.cos(J)*Math.sin(ve)-Math.sin(J)*Math.cos(ve)*Math.cos(j-M)))}function Sf(oe,o){o===void 0&&(o={});var s=qs(oe);return ta([(s[0]+s[2])/2,(s[1]+s[3])/2],o.properties,o)}function Cl(oe,o){o===void 0&&(o={});var s=0,l=0,g=0;return Uo(oe,function(M){s+=M[0],l+=M[1],g++},!0),ta([s/g,l/g],o.properties)}function Df(oe,o){switch(o===void 0&&(o={}),tl(oe)){case"Point":return ta(Cs(oe),o.properties);case"Polygon":var s=[];Uo(oe,function(Br){s.push(Br)});var l,g,M,j,J,ve,ze,lt,Dt=Cl(oe,{properties:o.properties}),$t=Dt.geometry.coordinates,lr=0,wr=0,Vr=0,$r=s.map(function(Br){return[Br[0]-$t[0],Br[1]-$t[1]]});for(l=0;s.length-1>l;l++)Vr+=lt=(j=(g=$r[l])[0])*(ze=(M=$r[l+1])[1])-(J=M[0])*(ve=g[1]),lr+=(j+J)*lt,wr+=(ve+ze)*lt;if(Vr===0)return Dt;var Xr=1/(6*(.5*Vr));return ta([$t[0]+Xr*lr,$t[1]+Xr*wr],o.properties);default:var Gr=function(Br,Tn){Tn===void 0&&(Tn={}),Tn.concavity=Tn.concavity||1/0;var Hn=[];if(Uo(Br,function(vo){Hn.push([vo[0],vo[1]])}),!Hn.length)return null;var yi=Sa(Hn,Tn.concavity);return yi.length>3?Ra([yi]):null}(oe);return Gr?Df(Gr,{properties:o.properties}):Cl(oe,{properties:o.properties})}}function bu(oe){if(!oe)throw Error("geojson is required");var o=[];return ss(oe,function(s){(function(l,g){var M=[],j=l.geometry;if(j!==null){switch(j.type){case"Polygon":M=su(j);break;case"LineString":M=[su(j)]}M.forEach(function(J){var ve=function(ze,lt){var Dt=[];return ze.reduce(function($t,lr){var wr,Vr,$r,Xr,Gr,Br,Tn=ns([$t,lr],lt);return Tn.bbox=[(Gr=(Vr=lr)[0])>($r=(wr=$t)[0])?$r:Gr,(Br=Vr[1])>(Xr=wr[1])?Xr:Br,$r>Gr?$r:Gr,Xr>Br?Xr:Br],Dt.push(Tn),lr}),Dt}(J,l.properties);ve.forEach(function(ze){ze.id=g.length,g.push(ze)})})}})(s,o)}),Vo(o)}Sa.default=fa;function Ic(oe,o,s){if(!s)return o.indexOf(oe);for(let l=0;o.length>l;l++)if(s(oe,o[l]))return l;return-1}function af(oe,o){zf(oe,0,oe.children.length,o,oe)}function zf(oe,o,s,l,g){g||(g=vl(null)),g.minX=1/0,g.minY=1/0,g.maxX=-1/0,g.maxY=-1/0;for(let M=o;s>M;M++){const j=oe.children[M];tf(g,oe.leaf?l(j):j)}return g}function tf(oe,o){return oe.minX=Math.min(oe.minX,o.minX),oe.minY=Math.min(oe.minY,o.minY),oe.maxX=Math.max(oe.maxX,o.maxX),oe.maxY=Math.max(oe.maxY,o.maxY),oe}function kf(oe,o){return oe.minX-o.minX}function ff(oe,o){return oe.minY-o.minY}function vf(oe){return(oe.maxX-oe.minX)*(oe.maxY-oe.minY)}function wc(oe){return oe.maxX-oe.minX+(oe.maxY-oe.minY)}function ac(oe,o){const s=Math.max(oe.minX,o.minX),l=Math.max(oe.minY,o.minY),g=Math.min(oe.maxX,o.maxX),M=Math.min(oe.maxY,o.maxY);return Math.max(0,g-s)*Math.max(0,M-l)}function cl(oe,o){return!(oe.minX>o.minX||oe.minY>o.minY||o.maxX>oe.maxX||o.maxY>oe.maxY)}function Us(oe,o){return!(o.minX>oe.maxX||o.minY>oe.maxY||oe.minX>o.maxX||oe.minY>o.maxY)}function vl(oe){return{children:oe,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function iu(oe,o,s,l,g){const M=[o,s];for(;M.length;){if(l>=(s=M.pop())-(o=M.pop()))continue;const j=o+Math.ceil((s-o)/l/2)*l;Xs(oe,j,o,s,g),M.push(o,j,j,s)}}var Ca=Object.freeze({__proto__:null,default:class{constructor(oe=9){this._maxEntries=Math.max(4,oe),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),this.clear()}all(){return this._all(this.data,[])}search(oe){let o=this.data;const s=[];if(!Us(oe,o))return s;const l=this.toBBox,g=[];for(;o;){for(let M=0;o.children.length>M;M++){const j=o.children[M],J=o.leaf?l(j):j;Us(oe,J)&&(o.leaf?s.push(j):cl(oe,J)?this._all(j,s):g.push(j))}o=g.pop()}return s}collides(oe){let o=this.data;if(!Us(oe,o))return!1;const s=[];for(;o;){for(let l=0;o.children.length>l;l++){const g=o.children[l],M=o.leaf?this.toBBox(g):g;if(Us(oe,M)){if(o.leaf||cl(oe,M))return!0;s.push(g)}}o=s.pop()}return!1}load(oe){if(!oe||!oe.length)return this;if(this._minEntries>oe.length){for(let s=0;oe.length>s;s++)this.insert(oe[s]);return this}let o=this._build(oe.slice(),0,oe.length-1,0);if(this.data.children.length)if(this.data.height===o.height)this._splitRoot(this.data,o);else{if(o.height>this.data.height){const s=this.data;this.data=o,o=s}this._insert(o,this.data.height-o.height-1,!0)}else this.data=o;return this}insert(oe){return oe&&this._insert(oe,this.data.height-1),this}clear(){return this.data=vl([]),this}remove(oe,o){if(!oe)return this;let s=this.data;const l=this.toBBox(oe),g=[],M=[];let j,J,ve;for(;s||g.length;){if(s||(s=g.pop(),J=g[g.length-1],j=M.pop(),ve=!0),s.leaf){const ze=Ic(oe,s.children,o);if(ze!==-1)return s.children.splice(ze,1),g.push(s),this._condense(g),this}ve||s.leaf||!cl(s,l)?J?(j++,s=J.children[j],ve=!1):s=null:(g.push(s),M.push(j),j=0,J=s,s=s.children[0])}return this}toBBox(oe){return oe}compareMinX(oe,o){return oe.minX-o.minX}compareMinY(oe,o){return oe.minY-o.minY}toJSON(){return this.data}fromJSON(oe){return this.data=oe,this}_all(oe,o){const s=[];for(;oe;)oe.leaf?o.push(...oe.children):s.push(...oe.children),oe=s.pop();return o}_build(oe,o,s,l){const g=s-o+1;let M,j=this._maxEntries;if(j>=g)return M=vl(oe.slice(o,s+1)),af(M,this.toBBox),M;l||(j=Math.ceil(g/Math.pow(j,(l=Math.ceil(Math.log(g)/Math.log(j)))-1))),M=vl([]),M.leaf=!1,M.height=l;const J=Math.ceil(g/j),ve=J*Math.ceil(Math.sqrt(j));iu(oe,o,s,ve,this.compareMinX);for(let ze=o;s>=ze;ze+=ve){const lt=Math.min(ze+ve-1,s);iu(oe,ze,lt,J,this.compareMinY);for(let Dt=ze;lt>=Dt;Dt+=J)M.children.push(this._build(oe,Dt,Math.min(Dt+J-1,lt),l-1))}return af(M,this.toBBox),M}_chooseSubtree(oe,o,s,l){for(;l.push(o),!o.leaf&&l.length-1!==s;){let j,J=1/0,ve=1/0;for(let ze=0;o.children.length>ze;ze++){const lt=o.children[ze],Dt=vf(lt),$t=(Math.max((M=lt).maxX,(g=oe).maxX)-Math.min(M.minX,g.minX))*(Math.max(M.maxY,g.maxY)-Math.min(M.minY,g.minY))-Dt;ve>$t?(ve=$t,J=J>Dt?Dt:J,j=lt):$t===ve&&J>Dt&&(J=Dt,j=lt)}o=j||o.children[0]}var g,M;return o}_insert(oe,o,s){const l=s?oe:this.toBBox(oe),g=[],M=this._chooseSubtree(l,this.data,o,g);for(M.children.push(oe),tf(M,l);o>=0&&g[o].children.length>this._maxEntries;)this._split(g,o),o--;this._adjustParentBBoxes(l,g,o)}_split(oe,o){const s=oe[o],l=s.children.length,g=this._minEntries;this._chooseSplitAxis(s,g,l);const M=this._chooseSplitIndex(s,g,l),j=vl(s.children.splice(M,s.children.length-M));j.height=s.height,j.leaf=s.leaf,af(s,this.toBBox),af(j,this.toBBox),o?oe[o-1].children.push(j):this._splitRoot(s,j)}_splitRoot(oe,o){this.data=vl([oe,o]),this.data.height=oe.height+1,this.data.leaf=!1,af(this.data,this.toBBox)}_chooseSplitIndex(oe,o,s){let l,g=1/0,M=1/0;for(let j=o;s-o>=j;j++){const J=zf(oe,0,j,this.toBBox),ve=zf(oe,j,s,this.toBBox),ze=ac(J,ve),lt=vf(J)+vf(ve);g>ze?(g=ze,l=j,M=M>lt?lt:M):ze===g&&M>lt&&(M=lt,l=j)}return l||s-o}_chooseSplitAxis(oe,o,s){const l=oe.leaf?this.compareMinX:kf,g=oe.leaf?this.compareMinY:ff,M=this._allDistMargin(oe,o,s,l);this._allDistMargin(oe,o,s,g)>M&&oe.children.sort(l)}_allDistMargin(oe,o,s,l){oe.children.sort(l);const g=this.toBBox,M=zf(oe,0,o,g),j=zf(oe,s-o,s,g);let J=wc(M)+wc(j);for(let ve=o;s-o>ve;ve++){const ze=oe.children[ve];tf(M,oe.leaf?g(ze):ze),J+=wc(M)}for(let ve=s-o-1;ve>=o;ve--){const ze=oe.children[ve];tf(j,oe.leaf?g(ze):ze),J+=wc(j)}return J}_adjustParentBBoxes(oe,o,s){for(let l=s;l>=0;l--)tf(o[l],oe)}_condense(oe){for(let o,s=oe.length-1;s>=0;s--)oe[s].children.length===0?s>0?(o=oe[s-1].children,o.splice(o.indexOf(oe[s]),1)):this.clear():af(oe[s],this.toBBox)}}}),xa=Xn(Ca),Dl=Xn(io),Gf=Xn(Aa),Li=Xn(Eu).default,Fr=Gf.featureEach,Hl=Dl.featureCollection;function Ur(oe){var o=new xa(oe);return o.insert=function(s){if(s.type!=="Feature")throw Error("invalid feature");return s.bbox=s.bbox?s.bbox:Li(s),xa.prototype.insert.call(this,s)},o.load=function(s){var l=[];return Array.isArray(s)?s.forEach(function(g){if(g.type!=="Feature")throw Error("invalid features");g.bbox=g.bbox?g.bbox:Li(g),l.push(g)}):Fr(s,function(g){if(g.type!=="Feature")throw Error("invalid features");g.bbox=g.bbox?g.bbox:Li(g),l.push(g)}),xa.prototype.load.call(this,l)},o.remove=function(s,l){if(s.type!=="Feature")throw Error("invalid feature");return s.bbox=s.bbox?s.bbox:Li(s),xa.prototype.remove.call(this,s,l)},o.clear=function(){return xa.prototype.clear.call(this)},o.search=function(s){var l=xa.prototype.search.call(this,this.toBBox(s));return Hl(l)},o.collides=function(s){return xa.prototype.collides.call(this,this.toBBox(s))},o.all=function(){var s=xa.prototype.all.call(this);return Hl(s)},o.toJSON=function(){return xa.prototype.toJSON.call(this)},o.fromJSON=function(s){return xa.prototype.fromJSON.call(this,s)},o.toBBox=function(s){var l;if(s.bbox)l=s.bbox;else if(Array.isArray(s)&&s.length===4)l=s;else if(Array.isArray(s)&&s.length===6)l=[s[0],s[1],s[3],s[4]];else if(s.type==="Feature")l=Li(s);else{if(s.type!=="FeatureCollection")throw Error("invalid geojson");l=Li(s)}return{minX:l[0],minY:l[1],maxX:l[2],maxY:l[3]}},o}var ja=Ur;function cu(oe,o){var s={},l=[];if(oe.type==="LineString"&&(oe=Da(oe)),o.type==="LineString"&&(o=Da(o)),oe.type==="Feature"&&o.type==="Feature"&&oe.geometry!==null&&o.geometry!==null&&oe.geometry.type==="LineString"&&o.geometry.type==="LineString"&&oe.geometry.coordinates.length===2&&o.geometry.coordinates.length===2){var g=fu(oe,o);return g&&l.push(g),Vo(l)}var M=ja();return M.load(bu(o)),$a(bu(oe),function(j){$a(M.search(j),function(J){var ve=fu(j,J);if(ve){var ze=su(ve).join(",");s[ze]||(s[ze]=!0,l.push(ve))}})}),Vo(l)}function fu(oe,o){var s=su(oe),l=su(o);if(s.length!==2)throw Error(" line1 must only contain 2 coordinates");if(l.length!==2)throw Error(" line2 must only contain 2 coordinates");var g=s[0][0],M=s[0][1],j=s[1][0],J=s[1][1],ve=l[0][0],ze=l[0][1],lt=l[1][0],Dt=l[1][1],$t=(Dt-ze)*(j-g)-(lt-ve)*(J-M),lr=(lt-ve)*(M-ze)-(Dt-ze)*(g-ve),wr=(j-g)*(M-ze)-(J-M)*(g-ve);if($t===0)return null;var Vr=lr/$t,$r=wr/$t;return 0>Vr||Vr>1||0>$r||$r>1?null:ta([g+Vr*(j-g),M+Vr*(J-M)])}ja.default=Ur;var nc=6378137;function Su(oe){return Pa(oe,function(o,s){return o+function(l){var g,M=0;switch(l.type){case"Polygon":return Wu(l.coordinates);case"MultiPolygon":for(g=0;l.coordinates.length>g;g++)M+=Wu(l.coordinates[g]);return M;case"Point":case"MultiPoint":case"LineString":case"MultiLineString":return 0}return 0}(s)},0)}function Wu(oe){var o=0;if(oe&&oe.length>0){o+=Math.abs(Hc(oe[0]));for(var s=1;oe.length>s;s++)o-=Math.abs(Hc(oe[s]))}return o}function Hc(oe){var o,s,l,g,M,j,J=0,ve=oe.length;if(ve>2){for(j=0;ve>j;j++)j===ve-2?(l=ve-2,g=ve-1,M=0):j===ve-1?(l=ve-1,g=0,M=1):(l=j,g=j+1,M=j+2),o=oe[l],s=oe[g],J+=(Lc(oe[M][0])-Lc(o[0]))*Math.sin(Lc(s[1]));J=J*nc*nc/2}return J}function Lc(oe){return oe*Math.PI/180}function Kl(oe,o){return o===void 0&&(o={}),Ms(oe,function(s,l){var g=l.geometry.coordinates;return s+Ac(g[0],g[1],o)},0)}function Ec(oe,o){o===void 0&&(o={});var s=Vs(oe);switch(o.properties||oe.type!=="Feature"||(o.properties=oe.properties),s.type){case"Polygon":return function(l,g){g===void 0&&(g={});var M=Vs(l),j=M.coordinates,J=g.properties?g.properties:l.type==="Feature"?l.properties:{};return bl(j,J)}(s,o);case"MultiPolygon":return function(l,g){g===void 0&&(g={});var M=Vs(l),j=M.coordinates,J=g.properties?g.properties:l.type==="Feature"?l.properties:{},ve=[];return j.forEach(function(ze){ve.push(bl(ze,J))}),Vo(ve)}(s,o);default:throw Error("invalid poly")}}function bl(oe,o){return oe.length>1?bs(oe,o):ns(oe[0],o)}function kl(oe){for(var o,s,l=su(oe),g=0,M=1;l.length>M;)o=s||l[0],g+=((s=l[M])[0]-o[0])*(s[1]+o[1]),M++;return g>0}var Wc=an(function(oe){var o=Object.prototype.hasOwnProperty,s="~";function l(){}function g(ve,ze,lt){this.fn=ve,this.context=ze,this.once=lt||!1}function M(ve,ze,lt,Dt,$t){if(typeof lt!="function")throw new TypeError("The listener must be a function");var lr=new g(lt,Dt||ve,$t),wr=s?s+ze:ze;return ve._events[wr]?ve._events[wr].fn?ve._events[wr]=[ve._events[wr],lr]:ve._events[wr].push(lr):(ve._events[wr]=lr,ve._eventsCount++),ve}function j(ve,ze){--ve._eventsCount==0?ve._events=new l:delete ve._events[ze]}function J(){this._events=new l,this._eventsCount=0}Object.create&&(l.prototype=Object.create(null),new l().__proto__||(s=!1)),J.prototype.eventNames=function(){var ve,ze,lt=[];if(this._eventsCount===0)return lt;for(ze in ve=this._events)o.call(ve,ze)&<.push(s?ze.slice(1):ze);return Object.getOwnPropertySymbols?lt.concat(Object.getOwnPropertySymbols(ve)):lt},J.prototype.listeners=function(ve){var ze=this._events[s?s+ve:ve];if(!ze)return[];if(ze.fn)return[ze.fn];for(var lt=0,Dt=ze.length,$t=Array(Dt);Dt>lt;lt++)$t[lt]=ze[lt].fn;return $t},J.prototype.listenerCount=function(ve){var ze=this._events[s?s+ve:ve];return ze?ze.fn?1:ze.length:0},J.prototype.emit=function(ve,ze,lt,Dt,$t,lr){var wr=s?s+ve:ve;if(!this._events[wr])return!1;var Vr,$r,Xr=this._events[wr],Gr=arguments.length;if(Xr.fn){switch(Xr.once&&this.removeListener(ve,Xr.fn,void 0,!0),Gr){case 1:return Xr.fn.call(Xr.context),!0;case 2:return Xr.fn.call(Xr.context,ze),!0;case 3:return Xr.fn.call(Xr.context,ze,lt),!0;case 4:return Xr.fn.call(Xr.context,ze,lt,Dt),!0;case 5:return Xr.fn.call(Xr.context,ze,lt,Dt,$t),!0;case 6:return Xr.fn.call(Xr.context,ze,lt,Dt,$t,lr),!0}for($r=1,Vr=Array(Gr-1);Gr>$r;$r++)Vr[$r-1]=arguments[$r];Xr.fn.apply(Xr.context,Vr)}else{var Br,Tn=Xr.length;for($r=0;Tn>$r;$r++)switch(Xr[$r].once&&this.removeListener(ve,Xr[$r].fn,void 0,!0),Gr){case 1:Xr[$r].fn.call(Xr[$r].context);break;case 2:Xr[$r].fn.call(Xr[$r].context,ze);break;case 3:Xr[$r].fn.call(Xr[$r].context,ze,lt);break;case 4:Xr[$r].fn.call(Xr[$r].context,ze,lt,Dt);break;default:if(!Vr)for(Br=1,Vr=Array(Gr-1);Gr>Br;Br++)Vr[Br-1]=arguments[Br];Xr[$r].fn.apply(Xr[$r].context,Vr)}}return!0},J.prototype.on=function(ve,ze,lt){return M(this,ve,ze,lt,!1)},J.prototype.once=function(ve,ze,lt){return M(this,ve,ze,lt,!0)},J.prototype.removeListener=function(ve,ze,lt,Dt){var $t=s?s+ve:ve;if(!this._events[$t])return this;if(!ze)return j(this,$t),this;var lr=this._events[$t];if(lr.fn)lr.fn!==ze||Dt&&!lr.once||lt&&lr.context!==lt||j(this,$t);else{for(var wr=0,Vr=[],$r=lr.length;$r>wr;wr++)(lr[wr].fn!==ze||Dt&&!lr[wr].once||lt&&lr[wr].context!==lt)&&Vr.push(lr[wr]);Vr.length?this._events[$t]=Vr.length===1?Vr[0]:Vr:j(this,$t)}return this},J.prototype.removeAllListeners=function(ve){var ze;return ve?this._events[ze=s?s+ve:ve]&&j(this,ze):(this._events=new l,this._eventsCount=0),this},J.prototype.off=J.prototype.removeListener,J.prototype.addListener=J.prototype.on,J.prefixed=s,J.EventEmitter=J,oe.exports=J}),Tl=function(oe){yr(s,oe);var o=In(s);function s(l,g){var M,j=g.style;return ho(this,s),(M=o.call(this)).scene=void 0,M.style=void 0,M.layers=void 0,M.data=[],M.scene=l,M.style=j,M.layers=M.initLayers(),M.layers.forEach(function(J){l.addLayer(J)}),j.callback instanceof Function&&j.callback(M.layers),M}return mn(s,[{key:"getLayers",value:function(){return this.layers}},{key:"show",value:function(){this.layers.forEach(function(l){l.show()})}},{key:"hide",value:function(){this.layers.forEach(function(l){l.hide()})}},{key:"setData",value:function(l){var g=so(l).sort(function(M,j){return+M.properties.isActive-+j.properties.isActive});this.data=g,this.layers.forEach(function(M){M.setData(Vo(g))})}},{key:"destroy",value:function(){var l=this;this.layers.forEach(function(g){l.scene.removeLayer(g)})}}]),s}(Wc.EventEmitter),ql=function(oe){yr(s,oe);var o=In(s);function s(){return ho(this,s),o.apply(this,arguments)}return mn(s,[{key:"initLayers",value:function(){var l=this.style,g=l.normal,M=l.style,j=l.options;return[new V.LineLayer(j!=null?j:{}).source(Vo([])).size(g.size).color(g.color).shape("line").style(M)]}}]),s}(Tl),ic=function(oe){var o=typeof oe;return oe!=null&&(o=="object"||o=="function")},Ls=typeof cn=="object"&&cn&&cn.Object===Object&&cn,cc=typeof self=="object"&&self&&self.Object===Object&&self,gu=Ls||cc||Function("return this")(),Cu=function(){return gu.Date.now()},Qc=/\s/,hf=function(oe){for(var o=oe.length;o--&&Qc.test(oe.charAt(o)););return o},Xc=/^\s+/,Al=function(oe){return oe&&oe.slice(0,hf(oe)+1).replace(Xc,"")},Sc=gu.Symbol,Ka=Object.prototype,ea=Ka.hasOwnProperty,qo=Ka.toString,tu=Sc?Sc.toStringTag:void 0,bh=function(oe){var o=ea.call(oe,tu),s=oe[tu];try{oe[tu]=void 0;var l=!0}catch(M){}var g=qo.call(oe);return l&&(o?oe[tu]=s:delete oe[tu]),g},pc=Object.prototype.toString,Wf=function(oe){return pc.call(oe)},Tu=Sc?Sc.toStringTag:void 0,Ih=function(oe){return oe==null?oe===void 0?"[object Undefined]":"[object Null]":Tu&&Tu in Object(oe)?bh(oe):Wf(oe)},Bl=function(oe){return oe!=null&&typeof oe=="object"},Xf=function(oe){return typeof oe=="symbol"||Bl(oe)&&Ih(oe)=="[object Symbol]"},fh=/^[-+]0x[0-9a-f]+$/i,uf=/^0b[01]+$/i,Yf=/^0o[0-7]+$/i,rh=parseInt,ud=function(oe){if(typeof oe=="number")return oe;if(Xf(oe))return NaN;if(ic(oe)){var o=typeof oe.valueOf=="function"?oe.valueOf():oe;oe=ic(o)?o+"":o}if(typeof oe!="string")return oe===0?oe:+oe;oe=Al(oe);var s=uf.test(oe);return s||Yf.test(oe)?rh(oe.slice(2),s?2:8):fh.test(oe)?NaN:+oe},fp=Math.max,h=Math.min,v=function(oe,o,s){var l,g,M,j,J,ve,ze=0,lt=!1,Dt=!1,$t=!0;if(typeof oe!="function")throw new TypeError("Expected a function");function lr(Gr){var Br=l,Tn=g;return l=g=void 0,ze=Gr,j=oe.apply(Tn,Br)}function wr(Gr){var Br=Gr-ve;return ve===void 0||Br>=o||0>Br||Dt&&Gr-ze>=M}function Vr(){var Gr=Cu();if(wr(Gr))return $r(Gr);J=setTimeout(Vr,function(Br){var Tn=o-(Br-ve);return Dt?h(Tn,M-(Br-ze)):Tn}(Gr))}function $r(Gr){return J=void 0,$t&&l?lr(Gr):(l=g=void 0,j)}function Xr(){var Gr=Cu(),Br=wr(Gr);if(l=arguments,g=this,ve=Gr,Br){if(J===void 0)return function(Tn){return ze=Tn,J=setTimeout(Vr,o),lt?lr(Tn):j}(ve);if(Dt)return clearTimeout(J),J=setTimeout(Vr,o),lr(ve)}return J===void 0&&(J=setTimeout(Vr,o)),j}return o=ud(o)||0,ic(s)&&(lt=!!s.leading,M=(Dt="maxWait"in s)?fp(ud(s.maxWait)||0,o):M,$t="trailing"in s?!!s.trailing:$t),Xr.cancel=function(){J!==void 0&&clearTimeout(J),ze=0,l=ve=g=J=void 0},Xr.flush=function(){return J===void 0?j:$r(Cu())},Xr},B=function(oe){yr(s,oe);var o=In(s);function s(){var l;ho(this,s);for(var g=arguments.length,M=Array(g),j=0;g>j;j++)M[j]=arguments[j];return(l=o.call.apply(o,[this].concat(M))).onMouseMove=function(J){l.emit(R.RenderEvent.Mousemove,J)},l.onMouseOut=function(J){l.emit(R.RenderEvent.Mouseout,J)},l.onMouseDown=function(J){l.emit(R.RenderEvent.Dragstart,J)},l.onDragging=function(J){l.emit(R.RenderEvent.Dragging,J)},l.onDragEnd=v(function(J){l.emit(R.RenderEvent.Dragend,J)},0),l.onUnClick=function(J){l.emit(R.RenderEvent.UnClick,J)},l.enableHover=function(){var J,ve;l.disableHover(),(J=l.layers[0])===null||J===void 0||J.on(R.LayerEvent.Mousemove,l.onMouseMove),(ve=l.layers[0])===null||ve===void 0||ve.on(R.LayerEvent.Mouseout,l.onMouseOut)},l.disableHover=function(){var J,ve;(J=l.layers[0])===null||J===void 0||J.off(R.LayerEvent.Mousemove,l.onMouseMove),(ve=l.layers[0])===null||ve===void 0||ve.off(R.LayerEvent.Mouseout,l.onMouseOut)},l}return mn(s,[{key:"initLayers",value:function(){var l=this.style,g=l.normal,M=l.hover,j=l.active,J=l.style,ve=l.options;return[new V.LineLayer(ve!=null?ve:{}).source(Vo([])).size("isHover*isActive",function(ze,lt){return lt?j.size:ze?M.size:g.size}).color("isHover*isActive",function(ze,lt){return lt?j.color:ze?M.color:g.color}).shape("line").style(J)]}},{key:"enableDrag",value:function(){this.disableDrag(),this.layers[0].on(R.LayerEvent.Mousedown,this.onMouseDown),this.scene.on(R.SceneEvent.Dragging,this.onDragging),this.scene.on(R.SceneEvent.Mouseup,this.onDragEnd),this.scene.on(R.SceneEvent.Dragend,this.onDragEnd)}},{key:"disableDrag",value:function(){this.layers[0].off(R.LayerEvent.Mousedown,this.onMouseDown),this.scene.off(R.SceneEvent.Dragging,this.onDragging),this.scene.off(R.SceneEvent.Mouseup,this.onDragEnd),this.scene.off(R.SceneEvent.Dragend,this.onDragEnd)}},{key:"enableUnClick",value:function(){this.disableUnClick(),this.layers[0].on(R.LayerEvent.UnClick,this.onUnClick)}},{key:"disableUnClick",value:function(){this.layers[0].off(R.LayerEvent.UnClick,this.onUnClick)}}]),s}(Tl),W=function(oe){yr(s,oe);var o=In(s);function s(){var l;ho(this,s);for(var g=arguments.length,M=Array(g),j=0;g>j;j++)M[j]=arguments[j];return(l=o.call.apply(o,[this].concat(M))).onMouseMove=function(J){l.emit(R.RenderEvent.Mousemove,J)},l.onMouseOut=function(J){l.emit(R.RenderEvent.Mouseout,J)},l.onMouseDown=function(J){l.emit(R.RenderEvent.Click,J)},l}return mn(s,[{key:"initLayers",value:function(){var l=this.style,g=l.normal,M=l.style,j=M===void 0?{}:M,J=l.options,ve=g.shape,ze=g.size,lt=g.color;return[new V.PointLayer(J!=null?J:{}).source(Vo([])).size(ze).color(lt).shape(ve).style(j)]}},{key:"enableClick",value:function(){this.disableClick(),this.layers[0].on(R.LayerEvent.Mousedown,this.onMouseDown)}},{key:"disableClick",value:function(){this.layers[0].off(R.LayerEvent.Mousedown,this.onMouseDown)}},{key:"enableHover",value:function(){var l,g;this.disableHover(),(l=this.layers[0])===null||l===void 0||l.on(R.LayerEvent.Mousemove,this.onMouseMove),(g=this.layers[0])===null||g===void 0||g.on(R.LayerEvent.Mouseout,this.onMouseOut)}},{key:"disableHover",value:function(){var l,g;(l=this.layers[0])===null||l===void 0||l.off(R.LayerEvent.Mousemove,this.onMouseMove),(g=this.layers[0])===null||g===void 0||g.off(R.LayerEvent.Mouseout,this.onMouseOut)}}]),s}(Tl),_e=function(oe){yr(s,oe);var o=In(s);function s(){var l;ho(this,s);for(var g=arguments.length,M=Array(g),j=0;g>j;j++)M[j]=arguments[j];return(l=o.call.apply(o,[this].concat(M))).onCreate=function(J){l.emit(R.RenderEvent.UnClick,J)},l.onMouseMove=function(J){l.emit(R.RenderEvent.Mousemove,J)},l.onMouseOut=function(J){l.emit(R.RenderEvent.Mouseout,J)},l.onMouseDown=function(J){l.emit(R.RenderEvent.Dragstart,J)},l.onDragging=function(J){l.emit(R.RenderEvent.Dragging,J)},l.onDragEnd=v(function(J){l.emit(R.RenderEvent.Dragend,J)},0),l.onClick=function(J){l.emit(R.RenderEvent.Click,J)},l.onContextmenu=function(J){l.emit(R.RenderEvent.Contextmenu,J)},l}return mn(s,[{key:"initLayers",value:function(){var l=this.style,g=l.normal,M=l.hover,j=l.active,J=l.style,ve=J===void 0?{}:J,ze=l.options;return[new V.PointLayer(ze!=null?ze:{}).source(Vo([])).size("isHover*isActive",function(lt,Dt){return Dt?j.size:lt?M.size:g.size}).color("isHover*isActive",function(lt,Dt){return Dt?j.color:lt?M.color:g.color}).shape("isHover*isActive",function(lt,Dt){return Dt?j.shape:lt?M.shape:g.shape}).style(ve)]}},{key:"enableCreate",value:function(){this.disableCreate(),this.layers[0].on(R.LayerEvent.UnClick,this.onCreate)}},{key:"disableCreate",value:function(){this.layers[0].off(R.LayerEvent.UnClick,this.onCreate)}},{key:"enableHover",value:function(){var l,g;this.disableHover(),(l=this.layers[0])===null||l===void 0||l.on(R.LayerEvent.Mousemove,this.onMouseMove),(g=this.layers[0])===null||g===void 0||g.on(R.LayerEvent.Mouseout,this.onMouseOut)}},{key:"disableHover",value:function(){var l,g;(l=this.layers[0])===null||l===void 0||l.off(R.LayerEvent.Mousemove,this.onMouseMove),(g=this.layers[0])===null||g===void 0||g.off(R.LayerEvent.Mouseout,this.onMouseOut)}},{key:"enableDrag",value:function(){this.disableDrag(),this.layers[0].on(R.LayerEvent.Mousedown,this.onMouseDown),this.scene.on(R.SceneEvent.Dragging,this.onDragging),this.scene.on(R.SceneEvent.Mouseup,this.onDragEnd),this.scene.on(R.SceneEvent.Dragend,this.onDragEnd)}},{key:"disableDrag",value:function(){this.layers[0].off(R.LayerEvent.Mousedown,this.onMouseDown),this.scene.off(R.SceneEvent.Dragging,this.onDragging),this.scene.off(R.SceneEvent.Mouseup,this.onDragEnd),this.scene.off(R.SceneEvent.Dragend,this.onDragEnd)}},{key:"enableClick",value:function(){this.disableClick(),this.layers[0].on(R.LayerEvent.Click,this.onClick)}},{key:"disableClick",value:function(){this.layers[0].off(R.LayerEvent.Click,this.onClick)}},{key:"enableContextMenu",value:function(){this.disableContextMenu(),this.layers[0].on(R.LayerEvent.Contextmenu,this.onContextmenu)}},{key:"disableContextMenu",value:function(){this.layers[0].off(R.LayerEvent.Contextmenu,this.onContextmenu)}}]),s}(Tl),_t=function(oe){yr(s,oe);var o=In(s);function s(){var l;ho(this,s);for(var g=arguments.length,M=Array(g),j=0;g>j;j++)M[j]=arguments[j];return(l=o.call.apply(o,[this].concat(M))).onMouseMove=function(J){l.emit(R.RenderEvent.Mousemove,J)},l.onMouseOut=function(J){l.emit(R.RenderEvent.Mouseout,J)},l.onMouseDown=function(J){l.emit(R.RenderEvent.Dragstart,J)},l.onDragging=function(J){l.emit(R.RenderEvent.Dragging,J)},l.onDragEnd=v(function(J){l.emit(R.RenderEvent.Dragend,J)},0),l.onUnClick=function(J){l.emit(R.RenderEvent.UnClick,J)},l.enableHover=function(){var J,ve;l.disableHover(),(J=l.layers[0])===null||J===void 0||J.on(R.LayerEvent.Mousemove,l.onMouseMove),(ve=l.layers[0])===null||ve===void 0||ve.on(R.LayerEvent.Mouseout,l.onMouseOut)},l.disableHover=function(){var J,ve;(J=l.layers[0])===null||J===void 0||J.off(R.LayerEvent.Mousemove,l.onMouseMove),(ve=l.layers[0])===null||ve===void 0||ve.off(R.LayerEvent.Mouseout,l.onMouseOut)},l}return mn(s,[{key:"initLayers",value:function(){var l=this.style,g=l.normal,M=l.hover,j=l.active,J=l.style,ve=l.options,ze=new V.PolygonLayer(ve!=null?ve:{});return ze.source(Vo([])).color("isHover*isActive",function(lt,Dt){return Dt?j.color:lt?M.color:g.color}).style(J),[ze]}},{key:"enableDrag",value:function(){this.disableDrag(),this.layers[0].on(R.LayerEvent.Mousedown,this.onMouseDown),this.scene.on(R.SceneEvent.Dragging,this.onDragging),this.scene.on(R.SceneEvent.Mouseup,this.onDragEnd),this.scene.on(R.SceneEvent.Dragend,this.onDragEnd)}},{key:"disableDrag",value:function(){this.layers[0].off(R.LayerEvent.Mousedown,this.onMouseDown),this.scene.off(R.SceneEvent.Dragging,this.onDragging),this.scene.off(R.SceneEvent.Mouseup,this.onDragEnd),this.scene.off(R.SceneEvent.Dragend,this.onDragEnd)}},{key:"enableUnClick",value:function(){this.disableUnClick(),this.layers[0].on(R.LayerEvent.UnClick,this.onUnClick)}},{key:"disableUnClick",value:function(){this.layers[0].off(R.LayerEvent.UnClick,this.onUnClick)}}]),s}(Tl),jt=function(oe){yr(s,oe);var o=In(s);function s(l){var g;return ho(this,s),(g=o.call(this)).scene=void 0,g.previousClick=void 0,g.onDblClick=function(M){var j,J,ve=(j=(J=M.pixel)!==null&&J!==void 0?J:M.point)!==null&&j!==void 0?j:{},ze=ve.x,lt=ze===void 0?0:ze,Dt=ve.y,$t=Dt===void 0?0:Dt,lr=Date.now();if(g.previousClick){var wr=g.previousClick,Vr=wr.y;300>lr-wr.time&&5>Math.abs(lt-wr.x)&&5>Math.abs($t-Vr)&&g.emit(R.RenderEvent.DblClick,M)}g.previousClick={x:lt,y:$t,time:lr}},g.onMouseMove=function(M){g.emit(R.RenderEvent.Mousemove,M)},g.onMouseDown=function(M){g.emit(R.RenderEvent.Dragstart,M)},g.onDragging=function(M){g.emit(R.RenderEvent.Dragging,M)},g.onDragEnd=v(function(M){g.emit(R.RenderEvent.Dragend,M)},0),g.scene=l,g}return mn(s,[{key:"enableDrag",value:function(){this.disableDrag(),this.scene.on(R.SceneEvent.Mousedown,this.onMouseDown),this.scene.on(R.SceneEvent.Dragging,this.onDragging),this.scene.on(R.SceneEvent.Mouseup,this.onDragEnd),this.scene.on(R.SceneEvent.Dragend,this.onDragEnd)}},{key:"disableDrag",value:function(){this.scene.off(R.SceneEvent.Mousedown,this.onMouseDown),this.scene.off(R.SceneEvent.Dragging,this.onDragging),this.scene.off(R.SceneEvent.Mouseup,this.onDragEnd),this.scene.off(R.SceneEvent.Dragend,this.onDragEnd)}},{key:"enableMouseMove",value:function(){this.disableMouseMove(),this.scene.on(R.SceneEvent.Mousemove,this.onMouseMove)}},{key:"disableMouseMove",value:function(){this.scene.off(R.SceneEvent.Mousemove,this.onMouseMove)}},{key:"enableDblClick",value:function(){this.disableDblClick(),this.scene.on(R.SceneEvent.Mousedown,this.onDblClick)}},{key:"disableDblClick",value:function(){this.scene.off(R.SceneEvent.Mousedown,this.onDblClick)}}]),s}(Wc),ie=function(oe){yr(s,oe);var o=In(s);function s(){return ho(this,s),o.apply(this,arguments)}return mn(s,[{key:"initLayers",value:function(){var l=this.style,g=l.normal,M=l.active,j=l.style,J=j===void 0?{}:j,ve=l.options;return[new V.PointLayer(ve!=null?ve:{}).source(Vo([])).size("isActive",function(ze){return ze?M.size:g.size}).color("isActive",function(ze){return ze?M.color:g.color}).shape("text","text").style(J)]}}]),s}(Tl),f={point:_e,line:B,dashLine:ql,midPoint:W,text:ie,polygon:_t},L="#1990FF",ee="#ED9D48",te={blend:"normal",pickingBuffer:5},me={color:L,shape:"circle",size:6},He={color:ee,shape:"circle",size:6},nt={shape:"circle",size:6,color:ee},w={options:te,normal:me,hover:un(un({},me),{},{size:8}),active:un(un({},me),{},{size:8,color:ee}),style:{stroke:"#ffffff",strokeWidth:2}},Wt={options:te,normal:He,hover:un(un({},He),{},{size:8}),active:un(un({},He),{},{size:8}),style:{stroke:"#ffffff",strokeWidth:2}},b={color:L,size:12},x={point:Wt,line:{options:te,normal:{color:L,size:2},hover:{color:L,size:2},active:{color:ee,size:2},style:{}},polygon:{options:te,normal:{color:L},hover:{color:L},active:{color:ee},style:{opacity:.15}},midPoint:{options:te,normal:nt},dashLine:{options:te,normal:{color:ee,size:2},style:{lineType:"dash",dashArray:[6,6]}},text:{options:te,normal:b,active:un(un({},b),{},{color:ee}),style:{fontWeight:"800",textOffset:[0,b.size+6],textAllowOverlap:!0,stroke:"#ffffff",strokeWidth:2}}},S=function(oe,o){return oe===o||oe!=oe&&o!=o},U=function(oe,o){for(var s=oe.length;s--;)if(S(oe[s][0],o))return s;return-1},pe=Array.prototype.splice,Ce=function(oe){var o=this.__data__,s=U(o,oe);return s>=0&&(s==o.length-1?o.pop():pe.call(o,s,1),--this.size,!0)},Oe=function(oe){var o=this.__data__,s=U(o,oe);return 0>s?void 0:o[s][1]},dt=function(oe){return U(this.__data__,oe)>-1},zt=function(oe,o){var s=this.__data__,l=U(s,oe);return 0>l?(++this.size,s.push([oe,o])):s[l][1]=o,this};function Tt(oe){var o=-1,s=oe==null?0:oe.length;for(this.clear();++ol.length)return l.push([oe,o]),this.size=++s.size,this;s=this.__data__=new Kf(l)}return s.set(oe,o),this.size=s.size,this};function Rh(oe){var o=this.__data__=new Qt(oe);this.size=o.size}Rh.prototype.clear=cr,Rh.prototype.delete=pr,Rh.prototype.get=zr,Rh.prototype.has=jr,Rh.prototype.set=nh;var Ff=Rh,kd=function(oe,o){for(var s=-1,l=oe==null?0:oe.length;++s-1&&oe%1==0&&o>oe},dd=function(oe){return typeof oe=="number"&&oe>-1&&oe%1==0&&9007199254740991>=oe},Jh={};Jh["[object Float32Array]"]=Jh["[object Float64Array]"]=Jh["[object Int8Array]"]=Jh["[object Int16Array]"]=Jh["[object Int32Array]"]=Jh["[object Uint8Array]"]=Jh["[object Uint8ClampedArray]"]=Jh["[object Uint16Array]"]=Jh["[object Uint32Array]"]=!0,Jh["[object Arguments]"]=Jh["[object Array]"]=Jh["[object ArrayBuffer]"]=Jh["[object Boolean]"]=Jh["[object DataView]"]=Jh["[object Date]"]=Jh["[object Error]"]=Jh["[object Function]"]=Jh["[object Map]"]=Jh["[object Number]"]=Jh["[object Object]"]=Jh["[object RegExp]"]=Jh["[object Set]"]=Jh["[object String]"]=Jh["[object WeakMap]"]=!1;var g0=function(oe){return Bl(oe)&&dd(oe.length)&&!!Jh[Ih(oe)]},b0=function(oe){return function(o){return oe(o)}},Gp=an(function(oe,o){var s=o&&!o.nodeType&&o,l=s&&oe&&!oe.nodeType&&oe,g=l&&l.exports===s&&Ls.process,M=function(){try{var j=l&&l.require&&l.require("util").types;return j||g&&g.binding&&g.binding("util")}catch(J){}}();oe.exports=M}),Wp=Gp&&Gp.isTypedArray,xp=Wp?b0(Wp):g0,U0=Object.prototype.hasOwnProperty,x0=function(oe,o){var s=lf(oe),l=!s&&od(oe),g=!s&&!l&&Tc(oe),M=!s&&!l&&!g&&xp(oe),j=s||l||g||M,J=j?hd(oe.length,String):[],ve=J.length;for(var ze in oe)!o&&!U0.call(oe,ze)||j&&(ze=="length"||g&&(ze=="offset"||ze=="parent")||M&&(ze=="buffer"||ze=="byteLength"||ze=="byteOffset")||Zh(ze,ve))||J.push(ze);return J},t0=Object.prototype,np=function(oe){var o=oe&&oe.constructor;return oe===(typeof o=="function"&&o.prototype||t0)},M0=function(oe,o){return function(s){return oe(o(s))}},kp=M0(Object.keys,Object),r0=Object.prototype.hasOwnProperty,hp=function(oe){if(!np(oe))return kp(oe);var o=[];for(var s in Object(oe))r0.call(oe,s)&&s!="constructor"&&o.push(s);return o},Xp=function(oe){return oe!=null&&dd(oe.length)&&!Hr(oe)},pm=function(oe){return Xp(oe)?x0(oe):hp(oe)},Tp=function(oe,o){return oe&&qf(o,pm(o),oe)},mm=function(oe){var o=[];if(oe!=null)for(var s in Object(oe))o.push(s);return o},dp=Object.prototype.hasOwnProperty,j0=function(oe){if(!ic(oe))return mm(oe);var o=np(oe),s=[];for(var l in oe)(l!="constructor"||!o&&dp.call(oe,l))&&s.push(l);return s},Fp=function(oe){return Xp(oe)?x0(oe,!0):j0(oe)},P0=function(oe,o){return oe&&qf(o,Fp(o),oe)},I0=an(function(oe,o){var s=o&&!o.nodeType&&o,l=s&&oe&&!oe.nodeType&&oe,g=l&&l.exports===s?gu.Buffer:void 0,M=g?g.allocUnsafe:void 0;oe.exports=function(j,J){if(J)return j.slice();var ve=j.length,ze=M?M(ve):new j.constructor(ve);return j.copy(ze),ze}}),V0=function(oe,o){var s=-1,l=oe.length;for(o||(o=Array(l));++sJ))return!1;var ze=M.get(oe),lt=M.get(o);if(ze&<)return ze==o&<==oe;var Dt=-1,$t=!0,lr=2&s?new G0:void 0;for(M.set(oe,o),M.set(o,oe);++Dt0){if(++o>=800)return arguments[0]}else o=0;return oe.apply(void 0,arguments)}},lc=Ql(Ud?function(oe,o){return Ud(oe,"toString",{configurable:!0,enumerable:!1,value:ws(o),writable:!0})}:Lu),zu=function(oe,o){return lc(Mu(oe,o,Lu),oe+"")},jl=function(oe,o,s){if(!ic(s))return!1;var l=typeof o;return!!(l=="number"?Xp(s)&&Zh(o,s.length):l=="string"&&o in s)&&S(s[o],oe)},Dc=function(oe){return zu(function(o,s){var l=-1,g=s.length,M=g>1?s[g-1]:void 0,j=g>2?s[2]:void 0;for(M=oe.length>3&&typeof M=="function"?(g--,M):void 0,j&&jl(s[0],s[1],j)&&(M=3>g?void 0:M,g=1),o=Object(o);++l":".","?":"/","|":"\\"},ve={option:"alt",command:"meta",return:"enter",escape:"esc",plus:"+",mod:/Mac|iPod|iPhone|iPad/.test(navigator.platform)?"meta":"ctrl"},ze=1;20>ze;++ze)M[111+ze]="f"+ze;for(ze=0;9>=ze;++ze)M[ze+96]=""+ze;$r.prototype.bind=function(Xr,Gr,Br){var Tn=this;return Tn._bindMultiple.call(Tn,Xr=Xr instanceof Array?Xr:[Xr],Gr,Br),Tn},$r.prototype.unbind=function(Xr,Gr){return this.bind.call(this,Xr,function(){},Gr)},$r.prototype.trigger=function(Xr,Gr){var Br=this;return Br._directMap[Xr+":"+Gr]&&Br._directMap[Xr+":"+Gr]({},Xr),Br},$r.prototype.reset=function(){var Xr=this;return Xr._callbacks={},Xr._directMap={},Xr},$r.prototype.stopCallback=function(Xr,Gr){if((" "+Gr.className+" ").indexOf(" mousetrap ")>-1||Vr(Gr,this.target))return!1;if("composedPath"in Xr&&typeof Xr.composedPath=="function"){var Br=Xr.composedPath()[0];Br!==Xr.target&&(Gr=Br)}return Gr.tagName=="INPUT"||Gr.tagName=="SELECT"||Gr.tagName=="TEXTAREA"||Gr.isContentEditable},$r.prototype.handleKey=function(){return this._handleKey.apply(this,arguments)},$r.addKeycodes=function(Xr){for(var Gr in Xr)Xr.hasOwnProperty(Gr)&&(M[Gr]=Xr[Gr]);g=null},$r.init=function(){var Xr=$r(s);for(var Gr in Xr)Gr.charAt(0)!=="_"&&($r[Gr]=function(Br){return function(){return Xr[Br].apply(Xr,arguments)}}(Gr))},$r.init(),o.Mousetrap=$r,oe.exports&&(oe.exports=$r)}function lt(Xr,Gr,Br){Xr.addEventListener?Xr.addEventListener(Gr,Br,!1):Xr.attachEvent("on"+Gr,Br)}function Dt(Xr){if(Xr.type=="keypress"){var Gr=String.fromCharCode(Xr.which);return Xr.shiftKey||(Gr=Gr.toLowerCase()),Gr}return M[Xr.which]?M[Xr.which]:j[Xr.which]?j[Xr.which]:String.fromCharCode(Xr.which).toLowerCase()}function $t(Xr){return Xr=="shift"||Xr=="ctrl"||Xr=="alt"||Xr=="meta"}function lr(Xr,Gr,Br){return Br||(Br=function(){if(!g)for(var Tn in g={},M)Tn>95&&112>Tn||M.hasOwnProperty(Tn)&&(g[M[Tn]]=Tn);return g}()[Xr]?"keydown":"keypress"),Br=="keypress"&&Gr.length&&(Br="keydown"),Br}function wr(Xr,Gr){var Br,Tn,Hn,yi=[];for(Br=function(vo){return vo==="+"?["+"]:(vo=vo.replace(/\+{2}/g,"+plus")).split("+")}(Xr),Hn=0;Br.length>Hn;++Hn)ve[Tn=Br[Hn]]&&(Tn=ve[Tn]),Gr&&Gr!="keypress"&&J[Tn]&&(Tn=J[Tn],yi.push("shift")),$t(Tn)&&yi.push(Tn);return{key:Tn,modifiers:yi,action:Gr=lr(Tn,yi,Gr)}}function Vr(Xr,Gr){return Xr!==null&&Xr!==s&&(Xr===Gr||Vr(Xr.parentNode,Gr))}function $r(Xr){var Gr=this;if(Xr=Xr||s,!(Gr instanceof $r))return new $r(Xr);Gr.target=Xr,Gr._callbacks={},Gr._directMap={};var Br,Tn={},Hn=!1,yi=!1,vo=!1;function Eo(Ts){Ts=Ts||{};var is,ts=!1;for(is in Tn)Ts[is]?ts=!0:Tn[is]=0;ts||(vo=!1)}function Xo(Ts,is,ts,Rs,pu,nl){var la,Es,sl,Bf=[],Vl=ts.type;if(!Gr._callbacks[Ts])return[];for(Vl=="keyup"&&$t(Ts)&&(is=[Ts]),la=0;Gr._callbacks[Ts].length>la;++la)Es=Gr._callbacks[Ts][la],(Rs||!Es.seq||Tn[Es.seq]==Es.level)&&Vl==Es.action&&(Vl=="keypress"&&!ts.metaKey&&!ts.ctrlKey||(sl=Es.modifiers,is.sort().join(",")===sl.sort().join(",")))&&((!Rs&&Es.combo==pu||Rs&&Es.seq==Rs&&Es.level==nl)&&Gr._callbacks[Ts].splice(la,1),Bf.push(Es));return Bf}function ys(Ts,is,ts,Rs){Gr.stopCallback(is,is.target||is.srcElement,ts,Rs)||Ts(is,ts)===!1&&(function(pu){pu.preventDefault?pu.preventDefault():pu.returnValue=!1}(is),function(pu){pu.stopPropagation?pu.stopPropagation():pu.cancelBubble=!0}(is))}function Yo(Ts){typeof Ts.which!="number"&&(Ts.which=Ts.keyCode);var is=Dt(Ts);is&&(Ts.type!="keyup"||Hn!==is?Gr.handleKey(is,function(ts){var Rs=[];return ts.shiftKey&&Rs.push("shift"),ts.altKey&&Rs.push("alt"),ts.ctrlKey&&Rs.push("ctrl"),ts.metaKey&&Rs.push("meta"),Rs}(Ts),Ts):Hn=!1)}function es(Ts,is,ts,Rs){function pu(sl){return function(){vo=sl,++Tn[Ts],clearTimeout(Br),Br=setTimeout(Eo,1e3)}}function nl(sl){ys(ts,sl,Ts),Rs!=="keyup"&&(Hn=Dt(sl)),setTimeout(Eo,10)}Tn[Ts]=0;for(var la=0;is.length>la;++la){var Es=la+1===is.length?nl:pu(Rs||wr(is[la+1]).action);qa(is[la],Es,Rs,Ts,la)}}function qa(Ts,is,ts,Rs,pu){Gr._directMap[Ts+":"+ts]=is;var nl,la=(Ts=Ts.replace(/\s+/g," ")).split(" ");la.length>1?es(Ts,la,is,ts):(nl=wr(Ts,ts),Gr._callbacks[nl.key]=Gr._callbacks[nl.key]||[],Xo(nl.key,nl.modifiers,{type:nl.action},Rs,Ts,pu),Gr._callbacks[nl.key][Rs?"unshift":"push"]({callback:is,modifiers:nl.modifiers,action:nl.action,seq:Rs,level:pu,combo:Ts}))}Gr._handleKey=function(Ts,is,ts){var Rs,pu=Xo(Ts,is,ts),nl={},la=0,Es=!1;for(Rs=0;pu.length>Rs;++Rs)pu[Rs].seq&&(la=Math.max(la,pu[Rs].level));for(Rs=0;pu.length>Rs;++Rs)if(pu[Rs].seq){if(pu[Rs].level!=la)continue;Es=!0,nl[pu[Rs].seq]=1,ys(pu[Rs].callback,ts,pu[Rs].combo,pu[Rs].seq)}else Es||ys(pu[Rs].callback,ts,pu[Rs].combo);var sl=ts.type=="keypress"&&yi;ts.type!=vo||$t(Ts)||sl||Eo(nl),yi=Es&&ts.type=="keydown"},Gr._bindMultiple=function(Ts,is,ts){for(var Rs=0;Ts.length>Rs;++Rs)qa(Ts[Rs],is,ts)},lt(Xr,"keypress",Yo),lt(Xr,"keydown",Yo),lt(Xr,"keyup",Yo)}})(typeof window!="undefined"?window:null,typeof window!="undefined"?document:null)}),Ch,Tf=function(oe){return oe&&oe.length?oe[0]:void 0},ed=(Ch=1,function(oe){return"".concat(oe,"-").concat(Ch++)}),If=function(oe,o){var s,l;return!(!oe||!o||((s=oe.properties)===null||s===void 0?void 0:s.id)!==((l=o.properties)===null||l===void 0?void 0:l.id))},$h=function(oe){var o=oe.target,s=oe.targetHandler,l=oe.otherHandler;return oe.data.map(function(g,M){var j,J=If(g,o)?s:l;return(j=J==null?void 0:J(g,M))!==null&&j!==void 0?j:g})},nf=function(){return{id:ed("point"),isHover:!1,isActive:!1,isDrag:!1,createTime:Date.now()}},Od=function(){return{id:ed("line"),isHover:!1,isActive:!1,isDrag:!1,isDraw:!1,createTime:Date.now()}},Yc=function(){return{id:ed("polygon"),isHover:!1,isActive:!1,isDrag:!1,isDraw:!1,createTime:Date.now()}},Qf=function(oe){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return ta(oe,un(un({},nf()),o))},Pu=function(oe){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return{type:"Feature",properties:un(un({},Od()),{},{nodes:oe},o),geometry:{type:"LineString",coordinates:Co(Vo(oe))}}},hl=function(oe){return ns(oe,{id:ed("dashLine")})},Gs=function(oe){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return{type:"Feature",properties:un(un({},Yc()),{},{nodes:oe},o),geometry:{type:"Polygon",coordinates:[Co(Vo([].concat(so(oe),[Tf(oe)])))]}}},of=function(oe){return function(o,s,l){l===void 0&&(l={});for(var g=Vs(o).coordinates,M=0,j=0;g.length>j&&(M>s||j!==g.length-1);j++){if(M>=s){var J=s-M;if(J){var ve=Gu(g[j],g[j-1])-180;return Yu(g[j],J,ve,l)}return ta(g[j])}M+=Ac(g[j],g[j+1],l)}return ta(g[g.length-1])}(oe,Kl(oe,{units:"meters"})/2,{units:"meters"})},Oh=function(oe,o){var s=o.format,l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},g=[];if(o.showTotalDistance){var M=of(oe),j=Kl(oe,{units:"meters"}),J=Co(oe).map(function(wr){return ta(wr)});M.properties=un({id:ed("text"),isActive:!1,meters:j,text:s(j,J),type:"totalDistance"},l),g.push(M)}else for(var ve=oe.geometry.coordinates,ze=0;ve.length-1>ze;ze++){var lt=ta(ve[ze]),Dt=ta(ve[ze+1]),$t=Ac(lt,Dt,{units:"meters"}),lr=Sf(Vo([lt,Dt]));lr.properties=un({id:ed("text"),isActive:!1,meters:$t,text:s($t,[lt,Dt]),type:"distance"},l),g.push(lr)}return g},Vp=function(oe,o){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},l=o.format,g=Su(oe);return Df(oe,{properties:un({meters:g,text:l(g,oe),type:"area",isActive:!1},s)})},ei=function(oe){var o,s,l,g,M,j,J=oe.getContainer();return(o=(s=(l=(g=(M=(j=J==null?void 0:J.querySelector(".l7-marker-container"))!==null&&j!==void 0?j:J==null?void 0:J.querySelector(".BMap_mask"))!==null&&M!==void 0?M:oe.getMapCanvasContainer())!==null&&g!==void 0?g:J==null?void 0:J.querySelector(".l7-scene"))!==null&&l!==void 0?l:J==null?void 0:J.querySelector(".l7-control-container"))!==null&&s!==void 0?s:J==null?void 0:J.querySelector(".l7-marker-container2"))!==null&&o!==void 0?o:null},Zo=function(oe){return oe.lngLat||oe.lnglat},ao=function(oe){var o=Zo(oe);return[o.lng,o.lat]},Iu=function(oe){return[oe.lng,oe.lat]},Kc=function(oe){for(var o=Number.MAX_SAFE_INTEGER,s=0,l=oe.length,g=0;l>g;g++)o>oe[g]&&(o=oe[g],s=g);return s},sa=function(oe,o){var s=[],l=[];return oe.forEach(function(g){Bs(g,o)?l.length&&(s.push(l),l=[]):l.push(g)}),l.length&&s.push(l),s},Rr=function(oe,o,s){var l=[],g=[],M=[];return l=oe==="allDrawData"?D.instances.map(function(j){return j.getData()}).flat():oe==="drawData"?o.getData():oe instanceof Function?oe(s):oe,l.length&&(g=l.map(function(j){var J,ve=(J=j.properties)!==null&&J!==void 0?J:{},ze=ve.nodes,lt=ze===void 0?[]:ze,Dt=ve.isActive;return Dt!==void 0&&Dt?lt.filter(function($t){return!Bs($t.geometry.coordinates,s)}):lt}).flat().filter(function(j){return j}),g.length||(g=Co(Vo(l)).map(function(j){return ta(j)})),M=l.map(function(j){var J,ve,ze=(J=j.properties)===null||J===void 0?void 0:J.line;return!((ve=j.properties)===null||ve===void 0)&&ve.isActive&&ze?sa(ze.properties.nodes.map(function(lt){return lt.geometry.coordinates}),s).filter(function(lt){return lt.length>1}).map(function(lt){return ns(lt)}):[ze]}).flat().filter(function(j){return j}),M.length||l.forEach(function(j){var J=tl(j);if(/linestring/i.test(J)&&M.push(j),/polygon/i.test(J)){var ve,ze,lt=Ec(j);return(ve=M).push.apply(ve,so((ze=lt==null?void 0:lt.features)!==null&&ze!==void 0?ze:[lt]))}})),{points:g,lines:M}},sr=function(oe,o,s,l){var g=s.pointAdsorbPixel,M=Mi(oe,2),j=l.lngLatToPixel([M[0],M[1]]),J=j.x,ve=j.y,ze=o.map(function(Dt){var $t=Mi(Dt.geometry.coordinates,2),lr=l.lngLatToPixel([$t[0],$t[1]]),wr=lr.y;return Math.pow(J-lr.x,2)+Math.pow(ve-wr,2)}),lt=Kc(ze);return Math.pow(ze[lt],.5)>g?null:o[lt].geometry.coordinates},ti=function(oe,o,s,l){var g=s.lineAdsorbPixel,M=Mi(oe,2),j=l.lngLatToPixel([M[0],M[1]]),J=j.x,ve=j.y,ze=o.filter(function($t){return Co($t).length>1}).map(function($t){return function(lr,wr,Vr){Vr===void 0&&(Vr={});var $r=ta([1/0,1/0],{dist:1/0}),Xr=0;return ss(lr,function(Gr){for(var Br=su(Gr),Tn=0;Br.length-1>Tn;Tn++){var Hn=ta(Br[Tn]);Hn.properties.dist=Ac(wr,Hn,Vr);var yi=ta(Br[Tn+1]);yi.properties.dist=Ac(wr,yi,Vr);var vo=Ac(Hn,yi,Vr),Eo=Math.max(Hn.properties.dist,yi.properties.dist),Xo=Gu(Hn,yi),ys=Yu(wr,Eo,Xo+90,Vr),Yo=Yu(wr,Eo,Xo-90,Vr),es=cu(ns([ys.geometry.coordinates,Yo.geometry.coordinates]),ns([Hn.geometry.coordinates,yi.geometry.coordinates])),qa=null;es.features.length>0&&((qa=es.features[0]).properties.dist=Ac(wr,qa,Vr),qa.properties.location=Xr+Ac(Hn,qa,Vr)),$r.properties.dist>Hn.properties.dist&&(($r=Hn).properties.index=Tn,$r.properties.location=Xr),$r.properties.dist>yi.properties.dist&&(($r=yi).properties.index=Tn+1,$r.properties.location=Xr+vo),qa&&$r.properties.dist>qa.properties.dist&&(($r=qa).properties.index=Tn),Xr+=vo}}),$r}($t,oe)});if(!ze.length)return null;var lt=ze.map(function($t){var lr=Mi($t.geometry.coordinates,2),wr=l.lngLatToPixel([lr[0],lr[1]]),Vr=wr.y;return Math.pow(J-wr.x,2)+Math.pow(ve-Vr,2)}),Dt=Kc(lt);return Math.pow(lt[Dt],.5)>g?null:ze[Dt].geometry.coordinates},_o=function(oe,o){var s=Mi(o,2),l=s[0],g=s[1];oe.lngLat&&(oe.lngLat={lng:l,lat:g}),oe.lnglat&&(oe.lnglat={lng:l,lat:g})},bo=function(){function oe(o,s){ho(this,oe),this.container=void 0,this.cursor=null,this.options=void 0,this.container=ei(o),this.options=s}return mn(oe,[{key:"setCursor",value:function(o){o!==this.cursor&&this.container&&(this.container.style.cursor=o?this.options[o]:"",this.cursor=o)}},{key:"destroy",value:function(){this.setCursor(null)}}]),oe}();function Pi(oe,o){o===void 0&&(o={});var s=o.insertAt;if(oe&&typeof document!="undefined"){var l=document.head||document.getElementsByTagName("head")[0],g=document.createElement("style");g.type="text/css",s==="top"&&l.firstChild?l.insertBefore(g,l.firstChild):l.appendChild(g),g.styleSheet?g.styleSheet.cssText=oe:g.appendChild(document.createTextNode(oe))}}Pi('.tippy-box[data-animation=fade][data-state=hidden]{opacity:0}[data-tippy-root]{max-width:calc(100vw - 10px)}.tippy-box{position:relative;background-color:#333;color:#fff;border-radius:4px;font-size:14px;line-height:1.4;white-space:normal;outline:0;transition-property:transform,visibility,opacity}.tippy-box[data-placement^=top]>.tippy-arrow{bottom:0}.tippy-box[data-placement^=top]>.tippy-arrow:before{bottom:-7px;left:0;border-width:8px 8px 0;border-top-color:initial;transform-origin:center top}.tippy-box[data-placement^=bottom]>.tippy-arrow{top:0}.tippy-box[data-placement^=bottom]>.tippy-arrow:before{top:-7px;left:0;border-width:0 8px 8px;border-bottom-color:initial;transform-origin:center bottom}.tippy-box[data-placement^=left]>.tippy-arrow{right:0}.tippy-box[data-placement^=left]>.tippy-arrow:before{border-width:8px 0 8px 8px;border-left-color:initial;right:-7px;transform-origin:center left}.tippy-box[data-placement^=right]>.tippy-arrow{left:0}.tippy-box[data-placement^=right]>.tippy-arrow:before{left:-7px;border-width:8px 8px 8px 0;border-right-color:initial;transform-origin:center right}.tippy-box[data-inertia][data-state=visible]{transition-timing-function:cubic-bezier(.54,1.5,.38,1.11)}.tippy-arrow{width:16px;height:16px;color:#333}.tippy-arrow:before{content:"";position:absolute;border-color:transparent;border-style:solid}.tippy-content{position:relative;padding:5px 9px;z-index:1}'),Pi(".tippy-box[data-theme~=light]{color:#26323d;box-shadow:0 0 20px 4px rgba(154,161,177,.15),0 4px 80px -8px rgba(36,40,47,.25),0 4px 4px -2px rgba(91,94,105,.15);background-color:#fff}.tippy-box[data-theme~=light][data-placement^=top]>.tippy-arrow:before{border-top-color:#fff}.tippy-box[data-theme~=light][data-placement^=bottom]>.tippy-arrow:before{border-bottom-color:#fff}.tippy-box[data-theme~=light][data-placement^=left]>.tippy-arrow:before{border-left-color:#fff}.tippy-box[data-theme~=light][data-placement^=right]>.tippy-arrow:before{border-right-color:#fff}.tippy-box[data-theme~=light]>.tippy-backdrop{background-color:#fff}.tippy-box[data-theme~=light]>.tippy-svg-arrow{fill:#fff}");var ji=function(){function oe(o,s){var l=this;ho(this,oe),this.content="",this.tippy=void 0,this.scene=void 0,this.isMouseInner=!1,this.onMouseMove=function(){l.isMouseInner=!0,l.checkTippyShow()},this.onMouseOut=function(){l.isMouseInner=!1,l.checkTippyShow()},this.setContent=v(function(M){var j;l.content=M!=null?M:"",(j=l.tippy)===null||j===void 0||j.setContent(M!=null?M:""),l.checkTippyShow()},16,{maxWait:16});var g=ei(o);this.scene=o,g&&(this.tippy=hs(ei(o),un(un({},Vt),s)),this.tippy.hide(),o.on(R.SceneEvent.Mousemove,this.onMouseMove),o.on(R.SceneEvent.Mouseout,this.onMouseOut))}return mn(oe,[{key:"getContent",value:function(){return this.content}},{key:"checkTippyShow",value:function(){var o,s;this.content&&this.isMouseInner?(o=this.tippy)===null||o===void 0||o.show():(s=this.tippy)===null||s===void 0||s.hide()}},{key:"destroy",value:function(){var o;this.scene.off(R.SceneEvent.Mousemove,this.onMouseMove),this.scene.off(R.SceneEvent.Mouseout,this.onMouseOut),(o=this.tippy)===null||o===void 0||o.destroy()}}]),oe}(),Di=function(){function oe(o){var s=o.config;ho(this,oe),this.historyList=[],this.historyIndex=0,this.config=void 0,this.config=s}return mn(oe,[{key:"save",value:function(o){if(this.config){var s=this.config.maxSize;this.historyIndex&&(this.historyList=this.historyList.slice(this.historyIndex),this.historyIndex=0),s>this.historyList.length||this.historyList.pop();var l=Vh(o);return this.historyList.unshift(l),l}}},{key:"revert",value:function(){if(this.historyList.length&&this.historyList.length-1>this.historyIndex){var o=this.historyList[++this.historyIndex];return o?Vh(o):void 0}}},{key:"redo",value:function(){if(this.historyList.length&&this.historyIndex>0){var o=this.historyList[--this.historyIndex];return o?Vh(o):void 0}}}]),oe}(),jn=function(oe){yr(s,oe);var o=In(s);function s(l){var g,M=l.data,j=l.render,J=l.history,ve=l.scene;return ho(this,s),(g=o.call(this)).scene=void 0,g.render=void 0,g.data=Vh(p),g.timeout=null,g.diffData={},g.history=void 0,g.scene=ve,g.render=j,J&&(g.history=new Di({config:J})),M&&g.setData(M),g}return mn(s,[{key:"saveHistory",value:function(){var l;return(l=this.history)===null||l===void 0?void 0:l.save(this.data)}},{key:"revertHistory",value:function(){var l,g=(l=this.history)===null||l===void 0?void 0:l.revert();if(g)return this.setData(g),g}},{key:"redoHistory",value:function(){var l,g=(l=this.history)===null||l===void 0?void 0:l.redo();if(g)return this.setData(g),g}},{key:"setData",value:function(l){var g=this;return Object.keys(l).length&&(this.data=un(un({},this.data),l),this.diffData=un(un({},this.diffData),l),this.timeout||(this.timeout=requestAnimationFrame(function(){return g.updateDiffData()})),this.emit(R.SourceEvent.Change,{data:this.data})),this.data}},{key:"getData",value:function(){return this.data}},{key:"getRenderData",value:function(l){return this.data[l]}},{key:"setRenderData",value:function(l,g){var M=typeof g=="function"?g(this.getRenderData(l)):g;return this.setData(Lr({},l,M)),this.emit(R.SourceEvent.Change,this.data),M}},{key:"updateDiffData",value:function(){var l=this,g=Object.entries(this.diffData);g.length&&(g.forEach(function(M){var j,J=Mi(M,2),ve=J[0],ze=J[1];Array.isArray(ze)&&((j=l.getRender(ve))===null||j===void 0||j.setData(ze))}),this.emit(R.SourceEvent.Update,this.data,this.diffData),this.diffData={},this.timeout=null,requestAnimationFrame(function(){l.scene.render()}))}},{key:"getRender",value:function(l){return this.render[l]}},{key:"clear",value:function(){this.setData(B0(Object.keys(this.render).map(function(l){return[l,[]]})))}}]),s}(Wc),D=function(oe){yr(s,oe);var o=In(s);function s(l,g){var M;ho(this,s),(M=o.call(this)).scene=void 0,M.source=void 0,M.render=void 0,M.cursor=void 0,M.options=void 0,M.enabled=!1,M.allowCreate=!1,M.sceneRender=void 0,M.mouseLngLat={lng:0,lat:0},M.popup=void 0,M.addCount=0,M.saveMouseLngLat=v(function(ze){M.mouseLngLat=Zo(ze)},100,{maxWait:100}),M.saveHistory=v(function(){M.options.history&&M.source.saveHistory()},100),M.bindThis(),M.scene=l,M.sceneRender=new jt(l),M.options=Jl({},M.getDefaultOptions(g),g),M.render=M.initRender(),M.source=new jn({render:M.render,history:M.options.history||void 0,scene:l}),M.cursor=new bo(l,M.options.cursor);var j=M.options,J=j.initialData,ve=j.popup;return J&&M.setData(J),ve&&(M.popup=new ji(l,ve instanceof Object?ve:{})),M.saveHistory(),M.bindCommonEvent(),M.emit(R.DrawEvent.Init,Vn(M)),M.bindEnableEvent(),s.instances.push(Vn(M)),M}return mn(s,[{key:"addable",get:function(){var l=this.getData(),g=this.options,M=g.multiple,j=g.maxCount,J=l.find(function(ve){return ve.properties.isDraw});return!(!this.enabled||!this.allowCreate)&&(!!(M&&0>=j||J)||!(!M&&this.addCount>=1)&&(0>=j||j>l.length))}},{key:"getOptions",value:function(){return this.options}},{key:"getEditItem",value:function(){return this.editItem}},{key:"getDragItem",value:function(){return this.dragItem}},{key:"setHelper",value:function(l){var g,M,j=this.options.helper;if(j){var J=(g=l in j?j[l]:l)!==null&&g!==void 0?g:null;(M=this.popup)===null||M===void 0||M.setContent(J)}}},{key:"isEnable",value:function(){return this.enabled}},{key:"bindThis",value:function(){this.initRender=this.initRender.bind(this),this.getData=this.getData.bind(this),this.setData=this.setData.bind(this),this.emitChangeEvent=this.emitChangeEvent.bind(this),this.saveHistory=this.saveHistory.bind(this),this.onSceneMouseMove=this.onSceneMouseMove.bind(this),this.revertHistory=this.revertHistory.bind(this),this.redoHistory=this.redoHistory.bind(this),this.removeActiveFeature=this.removeActiveFeature.bind(this),this.bindCommonEvent=this.bindCommonEvent.bind(this),this.bindEnableEvent=this.bindEnableEvent.bind(this),this.unbindEnableEvent=this.unbindEnableEvent.bind(this),this.setActiveFeature=this.setActiveFeature.bind(this)}},{key:"bindCommonEvent",value:function(){var l=this;this.on(R.DrawEvent.Add,this.emitChangeEvent),this.on(R.DrawEvent.Add,function(){l.addCount++}),this.on(R.DrawEvent.Edit,this.emitChangeEvent),this.on(R.DrawEvent.Remove,this.emitChangeEvent),this.on(R.DrawEvent.Clear,this.emitChangeEvent),this.on(R.DrawEvent.AddNode,this.saveHistory),this.on(R.DrawEvent.RemoveNode,this.emitChangeEvent),this.bindEmitSelectEvent(!0)}},{key:"bindEmitSelectEvent",value:function(){var l=this,g=arguments.length>0&&arguments[0]!==void 0&&arguments[0],M=null,j=function(){var J,ve,ze,lt=l.getData().find(function(Dt){var $t;return($t=Dt.properties)===null||$t===void 0?void 0:$t.isActive})||null;((J=M)===null||J===void 0||(ve=J.properties)===null||ve===void 0?void 0:ve.id)!==(lt==null||(ze=lt.properties)===null||ze===void 0?void 0:ze.id)&&(M=lt,l.emit(R.DrawEvent.Select,lt))};this.source.on(R.SourceEvent.Change,j),g&&j()}},{key:"bindEnableEvent",value:function(){this.unbindKeyboardEvent(),this.scene.setMapStatus({doubleClickZoom:!1}),this.scene.on(R.SceneEvent.Mousemove,this.saveMouseLngLat),this.bindKeyboardEvent()}},{key:"unbindEnableEvent",value:function(){this.scene.setMapStatus({doubleClickZoom:!0}),this.scene.off(R.SceneEvent.Mousemove,this.saveMouseLngLat),this.unbindKeyboardEvent()}},{key:"bindKeyboardEvent",value:function(){var l=this,g=this.options.keyboard||{},M=g.revert,j=g.redo,J=g.remove;J&&yd.bind(J,function(){l.removeActiveFeature()}),this.options.history&&(M&&yd.bind(M,this.revertHistory),j&&yd.bind(j,this.redoHistory))}},{key:"unbindKeyboardEvent",value:function(){var l=this.options.keyboard||{},g=l.revert,M=l.redo,j=l.remove;j&&yd.unbind(j),this.options.history&&(g&&yd.unbind(g),M&&yd.unbind(M))}},{key:"emitChangeEvent",value:function(){this.emit(R.DrawEvent.Change,this.getData()),this.saveHistory()}},{key:"revertHistory",value:function(){this.enabled&&this.options.history&&this.source.revertHistory()&&(this.correctDrawItem(),this.emit(R.DrawEvent.Change,this.getData()))}},{key:"redoHistory",value:function(){this.enabled&&this.options.history&&this.source.redoHistory()&&(this.correctDrawItem(),this.emit(R.DrawEvent.Change,this.getData()))}},{key:"getRenderLayers",value:function(){return B0(Cf(this.render).map(function(l){var g=Mi(l,2);return[g[0],g[1].getLayers()]}))}},{key:"getTargetFeature",value:function(l){var g,M,j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.getData(),J=null;return l&&(J=(g=j.find(function(ve){var ze;return ve.properties.id===(typeof l=="string"?l:(ze=l.properties)===null||ze===void 0?void 0:ze.id)}))!==null&&g!==void 0?g:null,!J&&l instanceof Object&&(J=(M=j.find(function(ve){return Bs(l.geometry,ve.geometry)}))!==null&&M!==void 0?M:null)),J}},{key:"removeActiveFeature",value:function(){var l=this.getData().find(function(g){var M=g.properties;return M.isActive||M.isDraw});return l&&this.removeFeature(l),l}},{key:"removeFeature",value:function(l){var g=this.getData(),M=this.getTargetFeature(l);M&&(this.setData(g.filter(function(j){return!If(M,j)})),this.emit(R.DrawEvent.Remove,l,this.getData()))}},{key:"correctDrawItem",value:function(){this.getData().find(function(l){return l.properties.isDraw})&&this.onSceneMouseMove({type:"mousemove",lnglat:this.mouseLngLat,lngLat:this.mouseLngLat})}},{key:"initRender",value:function(){var l,g={},M=function(J,ve){var ze=typeof Symbol!="undefined"&&J[Symbol.iterator]||J["@@iterator"];if(!ze){if(Array.isArray(J)||(ze=ro(J))||ve&&J&&typeof J.length=="number"){ze&&(J=ze);var lt=0,Dt=function(){};return{s:Dt,n:function(){return J.length>lt?{done:!1,value:J[lt++]}:{done:!0}},e:function(Vr){throw Vr},f:Dt}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var $t,lr=!0,wr=!1;return{s:function(){ze=ze.call(J)},n:function(){var Vr=ze.next();return lr=Vr.done,Vr},e:function(Vr){wr=!0,$t=Vr},f:function(){try{lr||ze.return==null||ze.return()}finally{if(wr)throw $t}}}}(this.getRenderTypes());try{for(M.s();!(l=M.n()).done;){var j=l.value;g[j]=new f[j](this.scene,{style:this.options.style[j]})}}catch(J){M.e(J)}finally{M.f()}return g}},{key:"getCommonOptions",value:function(l){return{initialData:[],autoActive:!0,cursor:Vh(y),editable:!0,style:Vh(x),multiple:!0,history:Vh(Ci),keyboard:Vh(at),popup:!0,helper:{},maxCount:-1}}},{key:"setCursor",value:function(l){this.cursor.setCursor(l)}},{key:"resetCursor",value:function(){this.setCursor(this.addable?"draw":null)}},{key:"enable",value:function(){var l=this;this.allowCreate=0>=arguments.length||arguments[0]===void 0||arguments[0],this.addCount=0,this.enabled=!0,this.bindEnableEvent(),this.resetCursor(),this.setHelper(this.addable?"draw":null),setTimeout(function(){l.emit(R.DrawEvent.Enable,l)},0)}},{key:"disable",value:function(){var l=this;this.resetFeatures(),this.enabled=!1,this.setCursor(null),this.unbindEnableEvent(),this.addCount=0,this.setHelper(null),setTimeout(function(){l.emit(R.DrawEvent.Disable,l)},0)}},{key:"clear",value:function(){var l=arguments.length>0&&arguments[0]!==void 0&&arguments[0];this.source.clear(),this.emit(R.DrawEvent.Clear,this),l&&this.disable()}},{key:"show",value:function(){return Object.values(this.render).forEach(function(l){l.show()})}},{key:"hide",value:function(){return Object.values(this.render).forEach(function(l){l.hide()})}},{key:"destroy",value:function(){var l,g=this;Object.values(this.render).forEach(function(j){j.destroy()}),Object.values(R.RenderEvent).forEach(function(j){Object.values(g.render).forEach(function(J){J.removeAllListeners(j)}),g.sceneRender.removeAllListeners(j)}),setTimeout(function(){Object.values(R.DrawEvent).forEach(function(j){g.removeAllListeners(j)})},0),(l=this.popup)===null||l===void 0||l.destroy(),this.cursor.destroy(),this.emit(R.DrawEvent.Destroy,this);var M=s.instances.indexOf(this);M>-1&&s.instances.splice(M,1)}}]),s}(Wc);D.instances=[];var P=function(oe){var o=oe==null?0:oe.length;return o?oe[o-1]:void 0},F=function(oe){yr(s,oe);var o=In(s);function s(){return ho(this,s),o.apply(this,arguments)}return mn(s,[{key:"pointRender",get:function(){return this.render.point}},{key:"dragPoint",get:function(){return this.getPointData().find(function(l){return l.properties.isDrag})}},{key:"editPoint",get:function(){return this.getPointData().find(function(l){return l.properties.isActive})}},{key:"hoverPoint",get:function(){return this.getPointData().find(function(l){return l.properties.isHover})}},{key:"getDragPoint",value:function(){return this.dragPoint}},{key:"getEditPoint",value:function(){return this.editPoint}},{key:"getPointData",value:function(){return this.source.getRenderData("point")}},{key:"setPointData",value:function(l){return this.source.setRenderData("point",l)}},{key:"bindPointRenderEvent",value:function(){var l,g,M,j,J,ve;(l=this.pointRender)===null||l===void 0||l.on(R.RenderEvent.UnClick,this.onPointCreate.bind(this)),(g=this.pointRender)===null||g===void 0||g.on(R.RenderEvent.Mousemove,this.onPointMouseMove.bind(this)),(M=this.pointRender)===null||M===void 0||M.on(R.RenderEvent.Mouseout,this.onPointMouseOut.bind(this)),(j=this.pointRender)===null||j===void 0||j.on(R.RenderEvent.Dragstart,this.onPointDragStart.bind(this)),(J=this.pointRender)===null||J===void 0||J.on(R.RenderEvent.Dragging,this.onPointDragging.bind(this)),(ve=this.pointRender)===null||ve===void 0||ve.on(R.RenderEvent.Dragend,this.onPointDragEnd.bind(this))}},{key:"handleCreatePoint",value:function(l){var g=this.options,M=g.autoActive,j=g.editable,J=Qf(l);return this.setPointData(function(ve){return $h({target:J,data:[].concat(so(ve),[J]),targetHandler:function(ze){ze.properties=un(un({},ze.properties),{},{isHover:j,isActive:M&&j})},otherHandler:function(ze){ze.properties=un(un({},ze.properties),{},{isHover:!1,isActive:!1,isDrag:!1})}})}),J}},{key:"handlePointHover",value:function(l){return this.setCursor("pointHover"),If(l,this.hoverPoint)||this.setPointData(function(g){return $h({target:l,data:g,targetHandler:function(M){M.properties.isHover=!0},otherHandler:function(M){M.properties.isHover=!1}})}),l}},{key:"handlePointUnHover",value:function(l){return this.resetCursor(),this.setPointData(function(g){return g.map(function(M){return M.properties.isHover=!1,M})}),l}},{key:"handlePointDragStart",value:function(l){return this.setPointData(function(g){return $h({target:l,data:g,targetHandler:function(M){M.properties=un(un({},M.properties),{},{isDrag:!0,isActive:!0})},otherHandler:function(M){M.properties=un(un({},M.properties),{},{isDrag:!1,isActive:!1})}})}),this.scene.setMapStatus({dragEnable:!1}),this.setCursor("pointDrag"),l}},{key:"handlePointDragging",value:function(l,g){return this.setPointData(function(M){return $h({target:l,data:M,targetHandler:function(j){j.geometry.coordinates=Iu(g)}})}),this.scene.setMapStatus({dragEnable:!1}),this.setCursor("pointDrag"),l}},{key:"handlePointDragEnd",value:function(l){return this.setPointData(function(g){return $h({target:l,data:g,targetHandler:function(M){M.properties.isDrag=!1}})}),this.scene.setMapStatus({dragEnable:!0}),this.setCursor("pointHover"),l}},{key:"onPointCreate",value:function(l){return this.handleCreatePoint(Iu(Zo(l)))}},{key:"onPointMouseMove",value:function(l){return this.handlePointHover(l.feature)}},{key:"onPointMouseOut",value:function(l){return this.handlePointUnHover(l.feature)}},{key:"onPointDragStart",value:function(l){if(this.options.editable)return this.handlePointDragStart(l.feature)}},{key:"onPointDragging",value:function(l){var g=this.dragPoint;if(this.options.editable&&g)return this.handlePointDragging(g,Zo(l))}},{key:"onPointDragEnd",value:function(l){var g=this.dragPoint;if(this.options.editable&&g)return this.handlePointDragEnd(g)}},{key:"enablePointRenderAction",value:function(){var l,g,M,j,J=this.options.editable;this.enabled&&((g=this.pointRender)===null||g===void 0||g.enableCreate()),(l=this.pointRender)===null||l===void 0||l.enableClick(),J&&((M=this.pointRender)===null||M===void 0||M.enableHover(),(j=this.pointRender)===null||j===void 0||j.enableDrag())}},{key:"disablePointRenderAction",value:function(){var l,g,M,j;(l=this.pointRender)===null||l===void 0||l.disableCreate(),(g=this.pointRender)===null||g===void 0||g.disableHover(),(M=this.pointRender)===null||M===void 0||M.disableDrag(),(j=this.pointRender)===null||j===void 0||j.disableClick()}}]),s}(D),q=function(oe){yr(s,oe);var o=In(s);function s(){return ho(this,s),o.apply(this,arguments)}return mn(s,[{key:"midPointRender",get:function(){return this.render.midPoint}},{key:"getCommonOptions",value:function(l){return un(un({},Kn(Mr(s.prototype),"getCommonOptions",this).call(this,l)),{},{showMidPoint:!0})}},{key:"bindMidPointRenderEvent",value:function(){var l,g,M;(l=this.midPointRender)===null||l===void 0||l.on(R.RenderEvent.Click,this.onMidPointClick.bind(this)),(g=this.midPointRender)===null||g===void 0||g.on(R.RenderEvent.Mousemove,this.onMidPointHover.bind(this)),(M=this.midPointRender)===null||M===void 0||M.on(R.RenderEvent.Mouseout,this.onMidPointUnHover.bind(this))}},{key:"getMidPointData",value:function(){return this.source.getRenderData("midPoint")}},{key:"setMidPointData",value:function(l){return this.source.setRenderData("midPoint",l)}},{key:"getMidPointsByLine",value:function(l){var g=l.properties.nodes;if(!this.options.showMidPoint||2>g.length)return[];for(var M=[],j=0;g.length-1>j;j++){var J,ve,ze,lt,Dt=Sf(Vo([g[j],g[j+1]]),{properties:{id:ed("midPoint"),startId:(J=(ve=g[j].properties)===null||ve===void 0?void 0:ve.id)!==null&&J!==void 0?J:"",endId:(ze=(lt=g[j+1].properties)===null||lt===void 0?void 0:lt.id)!==null&&ze!==void 0?ze:""}});M.push(Dt)}return M}},{key:"onMidPointHover",value:function(l){this.setCursor("pointHover")}},{key:"onMidPointUnHover",value:function(l){this.resetCursor()}},{key:"enableMidPointRenderAction",value:function(){var l,g;(l=this.midPointRender)===null||l===void 0||l.enableClick(),(g=this.midPointRender)===null||g===void 0||g.enableHover()}},{key:"disableMidPointRenderAction",value:function(){var l,g;(l=this.midPointRender)===null||l===void 0||l.disableClick(),(g=this.midPointRender)===null||g===void 0||g.disableHover()}}]),s}(F),fe={draw:"\u5355\u51FB\u7ED8\u5236\u70B9",pointHover:"\u53EF\u62D6\u62FD\u8C03\u6574\u70B9\u4F4D\u7F6E",pointDrag:null},Ae={draw:"\u5355\u51FB\u7ED8\u5236\u9996\u4E2A\u8282\u70B9",pointHover:"\u53EF\u62D6\u62FD\u8C03\u6574\u8282\u70B9\u4F4D\u7F6E",pointDrag:null,lineHover:"\u53EF\u62D6\u62FD\u8C03\u6574\u7EBF\u4F4D\u7F6E",lineDrag:null,midPointHover:"\u5355\u51FB\u5728\u8BE5\u4F4D\u7F6E\u65B0\u589E\u8282\u70B9",drawFinish:"\u5355\u51FB\u7EE7\u7EED\u7ED8\u5236\uFF0C\u53CC\u51FB\u7ED3\u675F\u7ED8\u5236"},Ie={draw:"\u5355\u51FB\u7ED8\u5236\u9996\u4E2A\u8282\u70B9",drawContinue:"\u5355\u51FB\u7EE7\u7EED\u7ED8\u5236",drawFinish:"\u5355\u51FB\u7EE7\u7EED\u7ED8\u5236\uFF0C\u53CC\u51FB\u7ED3\u675F\u7ED8\u5236",midPointHover:"\u5355\u51FB\u5728\u8BE5\u4F4D\u7F6E\u65B0\u589E\u8282\u70B9",pointHover:"\u53EF\u62D6\u62FD\u8C03\u6574\u8282\u70B9\u4F4D\u7F6E",pointDrag:null,lineHover:"\u53EF\u62D6\u62FD\u8C03\u6574\u9762\u4F4D\u7F6E",lineDrag:null,polygonHover:"\u53EF\u62D6\u62FD\u8C03\u6574\u9762\u4F4D\u7F6E",polygonDrag:null},Ze=un(un({},Ie),{},{draw:"\u5355\u51FB\u7ED8\u5236\u9996\u4E2A\u8282\u70B9",drawFinish:"\u5355\u51FB\u7ED3\u675F\u7ED8\u5236"}),Ot={draw:"\u62D6\u62FD\u5F00\u59CB\u7ED8\u5236",drawFinish:"\u677E\u5F00\u9F20\u6807\u7ED3\u675F\u7ED8\u5236"},rr={lineHover:"\u53EF\u62D6\u62FD\u8C03\u6574\u77E9\u5F62\u4F4D\u7F6E",polygonHover:"\u53EF\u62D6\u62FD\u8C03\u6574\u77E9\u5F62\u4F4D\u7F6E"},mr={lineHover:"\u53EF\u62D6\u62FD\u8C03\u6574\u5706\u4F4D\u7F6E",polygonHover:"\u53EF\u62D6\u62FD\u8C03\u6574\u5706\u4F4D\u7F6E"},pn=function(oe){yr(s,oe);var o=In(s);function s(){var l;ho(this,s);for(var g=arguments.length,M=Array(g),j=0;g>j;j++)M[j]=arguments[j];return(l=o.call.apply(o,[this].concat(M))).previousPosition=[0,0],l}return mn(s,[{key:"lineRender",get:function(){return this.render.line}},{key:"dragLine",get:function(){return this.getLineData().find(function(l){return l.properties.isDrag})}},{key:"drawLine",get:function(){return this.getLineData().find(function(l){return l.properties.isDraw})}},{key:"editLine",get:function(){return this.getLineData().find(function(l){var g=l.properties;return!g.isDraw&&g.isActive})}},{key:"hoverLine",get:function(){return this.getLineData().find(function(l){return l.properties.isHover})}},{key:"getDragLine",value:function(){return this.dragLine}},{key:"getDrawLine",value:function(){return this.drawLine}},{key:"getEditLine",value:function(){return this.editLine}},{key:"getDefaultOptions",value:function(l){var g=un(un({},this.getCommonOptions(l)),{},{showMidPoint:!0,distanceOptions:!1,helper:Vh(Ae)});return l.distanceOptions&&(g.distanceOptions=un(un({},Pn),g.distanceOptions)),l.adsorbOptions&&(g.adsorbOptions=un(un({},gr),g.adsorbOptions)),g}},{key:"getAdsorbPosition",value:function(l){var g=this.options.adsorbOptions;if(typeof g=="boolean")return l;var M=this.scene,j=g.pointAdsorbPixel,J=g.lineAdsorbPixel,ve=null,ze=Rr(g.data,this,l),lt=ze.points,Dt=ze.lines;return lt.length&&j>0&&(ve=sr(l,lt,g,M)),!ve&&Dt.length&&J>0&&(ve=ti(l,Dt,g,M)),ve}},{key:"bindSceneEvent",value:function(){this.sceneRender.on(R.RenderEvent.Mousemove,this.onSceneMouseMove.bind(this))}},{key:"bindPointRenderEvent",value:function(){var l;Kn(Mr(s.prototype),"bindPointRenderEvent",this).call(this),(l=this.pointRender)===null||l===void 0||l.on(R.RenderEvent.Click,this.onPointClick.bind(this))}},{key:"bindLineRenderEvent",value:function(){var l,g,M,j,J,ve;(l=this.lineRender)===null||l===void 0||l.on(R.RenderEvent.UnClick,this.onLineUnClick.bind(this)),(g=this.lineRender)===null||g===void 0||g.on(R.RenderEvent.Mousemove,this.onLineMouseMove.bind(this)),(M=this.lineRender)===null||M===void 0||M.on(R.RenderEvent.Mouseout,this.onLineMouseOut.bind(this)),(j=this.lineRender)===null||j===void 0||j.on(R.RenderEvent.Dragstart,this.onLineDragStart.bind(this)),(J=this.lineRender)===null||J===void 0||J.on(R.RenderEvent.Dragging,this.onLineDragging.bind(this)),(ve=this.lineRender)===null||ve===void 0||ve.on(R.RenderEvent.Dragend,this.onLineDragEnd.bind(this))}},{key:"getDashLineDistanceTexts",value:function(l,g){var M=g.showTotalDistance,j=g.format;return g.showDashDistance?l.map(function(J){return Oh(J,{showTotalDistance:M,format:j},{isActive:!0,type:"dash"})}).flat():[]}},{key:"getLineDistanceTexts",value:function(l,g){var M=g.showTotalDistance,j=g.format,J=g.showWhen,ve=[];if(J.includes("active")){var ze=l.filter(function(Dt){return Dt.properties.isActive&&Dt.properties.nodes.length>1});ve.push.apply(ve,so(ze.map(function(Dt){return Oh(Dt,{showTotalDistance:M,format:j},{isActive:!0})}).flat()))}if(J.includes("normal")){var lt=l.filter(function(Dt){return!Dt.properties.isActive&&Dt.properties.nodes.length>1});ve.push.apply(ve,so(lt.map(function(Dt){return Oh(Dt,{showTotalDistance:M,format:j})}).flat()))}return ve}},{key:"getDistanceTexts",value:function(){var l=this.options.distanceOptions;if(!l)return[];var g=[],M=l.showWhen,j=l.showDashDistance,J=l.format,ve=l.showTotalDistance;return g.push.apply(g,so(this.getDashLineDistanceTexts(this.getDashLineData(),{showTotalDistance:!1,format:J,showDashDistance:j})).concat(so(this.getLineDistanceTexts(this.getLineData(),{showTotalDistance:ve,format:J,showWhen:M})))),g}},{key:"getAllTexts",value:function(){return this.getDistanceTexts()}},{key:"handleCreateLine",value:function(l){var g=Pu([l],{isActive:!0,isDraw:!0});return this.setLineData(function(M){return $h({target:g,data:[].concat(so(M),[g]),otherHandler:function(j){j.properties.isActive=!1}})}),this.setPointData([l]),this.setTextData(this.getAllTexts()),g}},{key:"syncLineNodes",value:function(l,g){return l.properties.nodes=g,l.geometry.coordinates=Co(Vo(g)),this.setLineData(function(M){return M.map(function(j){return If(j,l)?l:j})}),If(this.editLine,l)&&this.setMidPointData(this.getMidPointsByLine(l)),this.setPointData(l.properties.nodes),this.setTextData(this.getAllTexts()),l}},{key:"setActiveLine",value:function(l){var g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return this.setLineData(function(M){return $h({target:l,data:M,targetHandler:function(j){j.properties=un(un({},j.properties),{},{isDraw:!1,isActive:!0,isDrag:!1,isHover:!1},g)},otherHandler:function(j){j.properties=un(un({},j.properties),{},{isDraw:!1,isActive:!1,isDrag:!1})}})}),this.setPointData(l.properties.nodes.map(function(M){return M.properties=un(un({},M.properties),{},{isHover:!1,isActive:!1}),M})),this.setMidPointData(this.getMidPointsByLine(l)),this.setDashLineData([]),this.setTextData(this.getAllTexts()),l}},{key:"clearActiveLine",value:function(){this.source.setData({point:[],line:this.getLineData().map(function(l){return l.properties=un(un({},l.properties),{},{isDrag:!1,isActive:!1,isHover:!1}),l}),midPoint:[],text:this.getAllTexts()})}},{key:"handleLineUnClick",value:function(l){return this.clearActiveLine(),l}},{key:"handleLineHover",value:function(l){if(!this.drawLine)return this.setCursor("lineHover"),If(l,this.hoverLine)||this.setLineData(function(g){return $h({target:l,data:g,targetHandler:function(M){M.properties.isHover=!0},otherHandler:function(M){M.properties.isHover=!1}})}),l}},{key:"handleLineUnHover",value:function(l){if(!this.drawLine)return this.resetCursor(),this.setLineData(function(g){return g.map(function(M){return M.properties.isHover=!1,M})}),l}},{key:"handleLineDragStart",value:function(l){return this.setActiveLine(l,{isDrag:!0,isActive:!0}),this.scene.setMapStatus({dragEnable:!1}),this.setCursor("lineDrag"),l}},{key:"handleLineDragging",value:function(l,g){var M=g.lng,j=g.lat,J=l.properties.nodes,ve=Mi(this.previousPosition,2),ze=ve[0],lt=ve[1];return J.forEach(function(Dt){var $t=Dt.geometry.coordinates;Dt.geometry.coordinates=[$t[0]+M-ze,$t[1]+j-lt]}),this.syncLineNodes(l,J),this.setActiveLine(l,{isDrag:!0}),this.setCursor("lineDrag"),this.previousPosition=[M,j],l}},{key:"handleLineDragEnd",value:function(l){return l.properties.isDrag=!1,this.setLineData(function(g){return g}),this.scene.setMapStatus({dragEnable:!0}),l}},{key:"resetAdsorbLngLat",value:function(l){if(this.options.adsorbOptions){var g=this.getAdsorbPosition(Iu(Zo(l)));return g&&_o(l,g),g}}},{key:"onPointCreate",value:function(l){if(!this.editLine){this.resetAdsorbLngLat(l);var g=Kn(Mr(s.prototype),"onPointCreate",this).call(this,l),M=this.drawLine;if(g)return M?(this.syncLineNodes(M,[].concat(so(M.properties.nodes),[g])),this.setDashLineData([])):this.handleCreateLine(g),g}}},{key:"onPointDragStart",value:function(l){if(this.editLine)return this.setHelper("pointDrag"),Kn(Mr(s.prototype),"onPointDragStart",this).call(this,l)}},{key:"onPointDragging",value:function(l){var g=Kn(Mr(s.prototype),"onPointDragging",this).call(this,l);if(g){var M=this.resetAdsorbLngLat(l);M&&(g.geometry.coordinates=Vh(M))}var j=this.editLine;return j&&g&&(this.syncLineNodes(j,j.properties.nodes.map(function(J){return If(g,J)?g:J})),this.setActiveLine(j)),g}},{key:"onPointDragEnd",value:function(l){if(this.editLine){var g=Kn(Mr(s.prototype),"onPointDragEnd",this).call(this,l);return this.setPointData(function(M){return M.map(function(j){return j.properties.isActive=!1,j})}),this.setHelper("pointHover"),g}}},{key:"onLineUnClick",value:function(l){var g=this.editLine;if(g)return this.handleLineUnClick(g)}},{key:"onLineMouseMove",value:function(l){if(!this.drawLine)return this.dragLine||this.drawLine||!this.options.editable||this.setHelper("lineHover"),this.handleLineHover(l.feature)}},{key:"onLineMouseOut",value:function(l){if(!this.drawLine)return this.dragLine||this.drawLine||this.setHelper(this.addable?"draw":null),this.handleLineUnHover(l.feature)}},{key:"onLineDragStart",value:function(l){if(this.options.editable&&!this.drawLine)return this.previousPosition=ao(l),this.setHelper("lineDrag"),this.handleLineDragStart(l.feature)}},{key:"onLineDragging",value:function(l){var g=this.dragLine;if(g)return this.handleLineDragging(g,Zo(l))}},{key:"onLineDragEnd",value:function(l){var g=this.dragLine;if(g)return this.setHelper("lineHover"),this.handleLineDragEnd(g)}},{key:"onPointMouseMove",value:function(l){var g=Kn(Mr(s.prototype),"onPointMouseMove",this).call(this,l);return this.dragLine||this.drawLine||this.dragPoint||this.setHelper("pointHover"),g}},{key:"onPointMouseOut",value:function(l){var g=Kn(Mr(s.prototype),"onPointMouseOut",this).call(this,l);return this.dragLine||this.drawLine||this.dragPoint||this.setHelper(this.addable?"draw":null),g}},{key:"onMidPointHover",value:function(l){Kn(Mr(s.prototype),"onMidPointHover",this).call(this,l),this.setHelper("midPointHover")}},{key:"onMidPointUnHover",value:function(l){Kn(Mr(s.prototype),"onMidPointUnHover",this).call(this,l),this.setHelper(null)}},{key:"onPointClick",value:function(l){}},{key:"getLineData",value:function(){return this.source.getRenderData("line")}},{key:"setLineData",value:function(l){return this.source.setRenderData("line",l)}},{key:"getTextData",value:function(){return this.source.getRenderData("text")}},{key:"setTextData",value:function(l){return this.source.setRenderData("text",l)}},{key:"getDashLineData",value:function(){return this.source.getRenderData("dashLine")}},{key:"setDashLineData",value:function(l){return this.source.setRenderData("dashLine",l)}},{key:"onMidPointClick",value:function(l){var g=this.editLine,M=l.feature;if(g&&M&&!this.dragPoint){var j=g.properties.nodes,J=M.properties,ve=J.startId,ze=J.endId,lt=j.findIndex(function(lr){return lr.properties.id===ve}),Dt=j.findIndex(function(lr){return lr.properties.id===ze});if(lt>-1&&Dt>-1){var $t=Qf(M.geometry.coordinates,{isDrag:!0,isHover:!0});return this.setHelper("pointDrag"),j.splice(Dt,0,$t),g.geometry.coordinates=Co(Vo(j)),this.syncLineNodes(g,j),this.setActiveLine(g),$t}}}},{key:"enableSceneRenderAction",value:function(){this.sceneRender.enableDrag(),this.sceneRender.enableMouseMove(),this.sceneRender.enableDblClick()}},{key:"disableSceneRenderAction",value:function(){this.sceneRender.disableDrag(),this.sceneRender.disableMouseMove(),this.sceneRender.disableDblClick()}},{key:"enableLineRenderAction",value:function(){var l,g,M,j=this.options.editable;(l=this.lineRender)===null||l===void 0||l.enableUnClick(),j&&((g=this.lineRender)===null||g===void 0||g.enableHover(),(M=this.lineRender)===null||M===void 0||M.enableDrag())}},{key:"disableLineRenderAction",value:function(){var l,g,M;(l=this.lineRender)===null||l===void 0||l.disableUnClick(),(g=this.lineRender)===null||g===void 0||g.disableHover(),(M=this.lineRender)===null||M===void 0||M.disableDrag()}}]),s}(q),Jn=function(oe){yr(s,oe);var o=In(s);function s(){return ho(this,s),o.apply(this,arguments)}return mn(s,[{key:"dragItem",get:function(){return this.dragPolygon}},{key:"editItem",get:function(){return this.editPolygon}},{key:"polygonRender",get:function(){return this.render.polygon}},{key:"dragPolygon",get:function(){return this.getPolygonData().find(function(l){return l.properties.isDrag})}},{key:"drawPolygon",get:function(){return this.getPolygonData().find(function(l){return l.properties.isDraw})}},{key:"editPolygon",get:function(){return this.getPolygonData().find(function(l){var g=l.properties;return!g.isDraw&&g.isActive})}},{key:"hoverPolygon",get:function(){return this.getPolygonData().find(function(l){return l.properties.isHover})}},{key:"getDragPolygon",value:function(){return this.dragPolygon}},{key:"getDrawPolygon",value:function(){return this.drawPolygon}},{key:"getEditPolygon",value:function(){return this.editPolygon}},{key:"getRenderTypes",value:function(){return["polygon","line","dashLine","midPoint","point","text"]}},{key:"getData",value:function(){return this.getPolygonData()}},{key:"getMainLayer",value:function(){var l,g;return(l=(g=this.render.polygon)===null||g===void 0?void 0:g.getLayers())!==null&&l!==void 0?l:[]}},{key:"getDefaultOptions",value:function(l){var g=un(un({},Kn(Mr(s.prototype),"getDefaultOptions",this).call(this,l)),{},{areaOptions:!1,helper:Vh(Ie)});return l.areaOptions&&(g.areaOptions=un(un({},Wr),l.areaOptions)),g}},{key:"getAreaTexts",value:function(l){var g=this.options.areaOptions;if(!g)return[];var M=g.format,j=g.showWhen,J=[],ve=l.filter(function(ze){return ze.geometry.coordinates[0].length>=4});return j.includes("active")&&ve.filter(function(ze){return ze.properties.isActive}).forEach(function(ze){J.push(Vp(ze,{format:M},{isActive:!0}))}),j.includes("normal")&&ve.filter(function(ze){return!ze.properties.isActive}).forEach(function(ze){J.push(Vp(ze,{format:M},{isActive:!1}))}),J}},{key:"getAllTexts",value:function(){return[].concat(so(Kn(Mr(s.prototype),"getAllTexts",this).call(this)),so(this.getAreaTexts(this.getPolygonData())))}},{key:"getPolygonData",value:function(){return this.source.getRenderData("polygon")}},{key:"setPolygonData",value:function(l){return this.source.setRenderData("polygon",l)}},{key:"handleCreatePolygon",value:function(l,g){var M=Gs(l,{nodes:l,line:g,isActive:!0,isDraw:!0});return this.setPolygonData(function(j){return $h({target:M,data:[].concat(so(j),[M]),otherHandler:function(J){J.properties.isActive=!1}})}),M}},{key:"handlePolygonUnClick",value:function(l){return this.clearActivePolygon(),l}},{key:"handlePolygonHover",value:function(l){return this.setCursor("polygonHover"),If(l,this.hoverPolygon)||this.setPolygonData(function(g){return $h({target:l,data:g,targetHandler:function(M){M.properties.isHover=!0},otherHandler:function(M){M.properties.isHover=!1}})}),l}},{key:"handlePolygonUnHover",value:function(){this.resetCursor(),this.setPolygonData(function(l){return l.map(function(g){return g.properties.isHover=!1,g})})}},{key:"handlePolygonDragStart",value:function(l){return this.setActivePolygon(l,{isDrag:!0}),this.scene.setMapStatus({dragEnable:!1}),this.setCursor("polygonDrag"),l}},{key:"bindPolygonRenderEvent",value:function(){var l,g,M,j;(l=this.polygonRender)===null||l===void 0||l.on(R.RenderEvent.UnClick,this.onPolygonUnClick.bind(this)),(g=this.polygonRender)===null||g===void 0||g.on(R.RenderEvent.Mousemove,this.onPolygonHover.bind(this)),(M=this.polygonRender)===null||M===void 0||M.on(R.RenderEvent.Mouseout,this.onPolygonUnHover.bind(this)),(j=this.polygonRender)===null||j===void 0||j.on(R.RenderEvent.Dragstart,this.onPolygonDragStart.bind(this))}},{key:"syncPolygonNodes",value:function(l,g){var M=Co(Vo([].concat(so(g),[Tf(g)]))),j=l.properties,J=j.line;if(l.properties.nodes=g,l.geometry.coordinates=[kl(ns(M))?M:M.reverse()],this.setPolygonData(function($t){return $t.map(function(lr){return If(lr,l)?l:lr})}),!If(this.drawPolygon,l)){var ve=J.properties.nodes,ze=so(g),lt=Tf(ze);ze.push(ve.length===g.length?Qf(lt.geometry.coordinates):P(ve));var Dt=P(ze);Bs(lt.geometry.coordinates,Dt.geometry.coordinates)||(Dt.geometry.coordinates=Vh(lt.geometry.coordinates)),this.syncLineNodes(J,ze)}return l}},{key:"setActivePolygon",value:function(l){var g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return this.setActiveLine(l.properties.line,g),this.setPolygonData(function(M){return $h({target:l,data:M,targetHandler:function(j){j.properties=un(un({},j.properties),{},{isDraw:!1,isActive:!0,isDrag:!1,isHover:!1},g)},otherHandler:function(j){j.properties=un(un({},j.properties),{},{isDraw:!1,isActive:!1,isDrag:!1})}})}),this.setTextData(this.getAllTexts()),l}},{key:"clearActivePolygon",value:function(){this.setPolygonData(function(l){return l.map(function(g){return g.properties=un(un({},g.properties),{},{isDrag:!1,isActive:!1,isHover:!1}),g})}),this.clearActiveLine()}},{key:"onLineDragStart",value:function(l){var g=Kn(Mr(s.prototype),"onLineDragStart",this).call(this,l),M=this.getPolygonData().find(function(j){return If(j.properties.line,g)});return M&&(this.setActivePolygon(M,{isDrag:!0}),this.emit(R.DrawEvent.DragStart,M,this.getPolygonData())),g}},{key:"onLineUnClick",value:function(l){return this.editLine}},{key:"onLineDragEnd",value:function(l){var g=Kn(Mr(s.prototype),"onLineDragEnd",this).call(this,l),M=this.dragPolygon;return g&&M&&(M.properties.isDrag=!1,this.emit(R.DrawEvent.DragEnd,M,this.getPolygonData()),this.emit(R.DrawEvent.Edit,M,this.getPolygonData())),g}},{key:"onPolygonUnClick",value:function(l){var g=this.editPolygon;if(g)return this.handlePolygonUnClick(g)}},{key:"onPolygonHover",value:function(l){if(!this.drawPolygon)return this.dragPolygon||this.setHelper("polygonHover"),this.handlePolygonHover(l.feature)}},{key:"onPolygonUnHover",value:function(l){if(!this.drawPolygon)return this.setHelper(this.addable?"draw":null),this.handlePolygonUnHover()}},{key:"onPolygonDragStart",value:function(l){if(this.options.editable&&!this.drawPolygon){var g=l.feature;return this.previousPosition=ao(l),this.setHelper("polygonDrag"),this.emit(R.DrawEvent.DragStart,g,this.getPolygonData()),this.handlePolygonDragStart(g)}}},{key:"onMidPointClick",value:function(l){var g=this.editPolygon,M=Kn(Mr(s.prototype),"onMidPointClick",this).call(this,l);if(M&&g){var j=g.properties.line.properties.nodes;this.syncPolygonNodes(g,j.slice(0,j.length-1)),this.setActivePolygon(g)}return M}},{key:"onPointDragEnd",value:function(l){var g=this.editPolygon,M=Kn(Mr(s.prototype),"onPointDragEnd",this).call(this,l);return M&&g&&this.emit(R.DrawEvent.Edit,g,this.getPolygonData()),M}},{key:"enablePolygonRenderAction",value:function(){var l,g,M,j=this.options.editable;(l=this.polygonRender)===null||l===void 0||l.enableUnClick(),j&&((g=this.polygonRender)===null||g===void 0||g.enableHover(),(M=this.polygonRender)===null||M===void 0||M.enableDrag())}},{key:"disablePolygonRenderAction",value:function(){var l,g,M;(l=this.polygonRender)===null||l===void 0||l.disableUnClick(),(g=this.polygonRender)===null||g===void 0||g.disableHover(),(M=this.polygonRender)===null||M===void 0||M.disableDrag()}},{key:"bindEnableEvent",value:function(){Kn(Mr(s.prototype),"bindEnableEvent",this).call(this),this.enableSceneRenderAction(),this.enablePointRenderAction(),this.enableLineRenderAction(),this.enableMidPointRenderAction(),this.enablePolygonRenderAction()}},{key:"unbindEnableEvent",value:function(){Kn(Mr(s.prototype),"unbindEnableEvent",this).call(this),this.disableSceneRenderAction(),this.disablePointRenderAction(),this.disableLineRenderAction(),this.disableMidPointRenderAction(),this.disablePolygonRenderAction()}},{key:"bindThis",value:function(){Kn(Mr(s.prototype),"bindThis",this).call(this),this.bindPointRenderEvent=this.bindPointRenderEvent.bind(this),this.bindSceneEvent=this.bindSceneEvent.bind(this),this.bindLineRenderEvent=this.bindLineRenderEvent.bind(this),this.bindMidPointRenderEvent=this.bindMidPointRenderEvent.bind(this),this.bindPolygonRenderEvent=this.bindPolygonRenderEvent.bind(this)}},{key:"setActiveFeature",value:function(l){var g=this.getTargetFeature(l);g?this.setActivePolygon(g):this.clearActivePolygon()}},{key:"resetFeatures",value:function(){var l=this.getPolygonData();this.drawPolygon&&(l=l.filter(function(g){return!g.properties.isDraw}),this.source.setData({point:[],dashLine:[],midPoint:[]}),this.setLineData(function(g){return g.filter(function(M){return!M.properties.isDraw})}),this.setTextData(function(g){return g.filter(function(M){return!M.properties.isActive})})),this.editPolygon&&this.handlePolygonUnClick(this.editPolygon),this.setPolygonData(l.map(function(g){return g.properties=un(un({},g.properties),{},{isDrag:!1,isActive:!1,isHover:!1}),g}))}}]),s}(pn),ui=function(oe){yr(s,oe);var o=In(s);function s(l,g){var M;return ho(this,s),(M=o.call(this,l,g)).onSceneDragStart=M.onSceneDragStart.bind(Vn(M)),M.onSceneDragEnd=M.onSceneDragEnd.bind(Vn(M)),M}return mn(s,[{key:"drawLine",get:function(){var l;return(l=this.drawPolygon)===null||l===void 0?void 0:l.properties.line}},{key:"isDragTrigger",get:function(){return this.options.trigger==="drag"}},{key:"isClickTrigger",get:function(){return this.options.trigger==="click"}},{key:"getDefaultOptions",value:function(l){var g=un(un({},Kn(Mr(s.prototype),"getDefaultOptions",this).call(this,l)),{},{showMidPoint:!1,trigger:"click",autoActive:!1,helper:Vh(Ze)});return l.trigger==="drag"&&(g.helper=un(un({},g.helper),Ot)),g}},{key:"getMidPointsByLine",value:function(l){return[]}},{key:"handleCreatePolygon",value:function(l,g){var M=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},j=g.properties.nodes;return Gs(j.slice(0,j.length-1),un({nodes:l,line:g},M))}},{key:"handleFirstNodeCreate",value:function(l){var g=Qf(l.geometry.coordinates),M=this.handleCreatePolygonLine(l,g,{isDraw:!0,isActive:!0}),j=this.handleCreatePolygon([l,g],M,{isDraw:!0,isActive:!0});return this.setPolygonData(function(J){return $h({target:j,data:[].concat(so(J),[j]),targetHandler:function(ve){ve.properties=un(un({},ve.properties),{},{isDraw:!0,isActive:!0})}})}),this.emit(R.DrawEvent.AddNode,l,this.drawPolygon,this.getPolygonData()),this.setHelper("drawFinish"),l}},{key:"handleLastNodeCreate",value:function(l){var g=this.options,M=g.autoActive,j=g.editable,J=this.drawPolygon;return J&&(this.setLineData(function(ve){return[].concat(so(ve),[J.properties.line])}),this.setActivePolygon(J),M&&j||this.handlePolygonUnClick(J),this.emit(R.DrawEvent.Add,J,this.getPolygonData()),this.emit(R.DrawEvent.AddNode,J.properties.nodes[1],this.drawPolygon,this.getPolygonData()),this.setHelper(j?M?"pointHover":"polygonHover":this.addable?"draw":null)),l}},{key:"onPointCreate",value:function(l){var g=this;if(this.addable&&!this.dragPoint&&!this.editLine&&this.isClickTrigger){var M=this.drawPolygon,j=ao(l),J=this.handleCreatePoint(j);return M?requestAnimationFrame(function(){g.handleLastNodeCreate(J)}):this.handleFirstNodeCreate(J),J}}},{key:"setActivePolygon",value:function(l){var g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.setActiveLine(l.properties.line,g),this.setPolygonData(function(j){return $h({target:l,data:j,targetHandler:function(J){J.properties=un(un({},J.properties),{},{isDraw:!1,isActive:!0,isDrag:!1,isHover:!1},g)},otherHandler:function(J){J.properties=un(un({},J.properties),{},{isDraw:!1,isActive:!1,isDrag:!1})}})}),this.setPointData(l.properties.nodes),this.setDashLineData([]);var M=this.getAllTexts();return this.setTextData(M),l}},{key:"onPointDragging",value:function(l){var g=this.dragPoint;if(g){var M=this.handlePointDragging(g,Zo(l)),j=this.editPolygon;return M&&j&&(this.syncPolygonNodes(j,j.properties.nodes.map(function(J){return If(J,M)?M:J})),this.setActivePolygon(j)),M}}},{key:"onSceneDragStart",value:function(l){this.isDragTrigger&&this.addable&&!this.dragPoint&&!this.editLine&&(this.scene.setMapStatus({dragEnable:!1}),this.handleFirstNodeCreate(this.handleCreatePoint(ao(l))))}},{key:"onSceneDragEnd",value:function(l){this.isDragTrigger&&this.addable&&!this.dragPoint&&!this.editLine&&this.drawPolygon&&(this.scene.setMapStatus({dragEnable:!1}),this.handleLastNodeCreate(this.handleCreatePoint(ao(l))))}},{key:"onSceneMouseMove",value:function(l){var g=this.drawPolygon;if(g){var M=g.properties.nodes,j=Tf(M),J=P(M);J.geometry.coordinates=ao(l),this.syncPolygonNodes(g,[j,J]),this.setDashLineData([g.properties.line]),this.setTextData(this.getAllTexts()),this.resetCursor()}}},{key:"bindSceneDragEvent",value:function(){this.unbindSceneDragEvent(),this.sceneRender.on(R.RenderEvent.Dragstart,this.onSceneDragStart),this.sceneRender.on(R.RenderEvent.Dragend,this.onSceneDragEnd),this.scene.setMapStatus({dragEnable:!1})}},{key:"unbindSceneDragEvent",value:function(){this.sceneRender.off(R.RenderEvent.Dragstart,this.onSceneDragStart),this.sceneRender.off(R.RenderEvent.Dragend,this.onSceneDragEnd),this.scene.setMapStatus({dragEnable:!0})}},{key:"bindEnableEvent",value:function(){Kn(Mr(s.prototype),"bindEnableEvent",this).call(this),this.isDragTrigger&&this.bindSceneDragEvent()}},{key:"unbindEnableEvent",value:function(){Kn(Mr(s.prototype),"unbindEnableEvent",this).call(this),this.isDragTrigger&&this.unbindSceneDragEvent()}},{key:"bindThis",value:function(){Kn(Mr(s.prototype),"bindThis",this).call(this),this.onSceneDragStart=this.onSceneDragStart.bind(this),this.onSceneDragEnd=this.onSceneDragEnd.bind(this)}}]),s}(Jn),ci=function(oe){yr(s,oe);var o=In(s);function s(l,g){var M;return ho(this,s),(M=o.call(this,l,g)).bindPointRenderEvent(),M.bindSceneEvent(),M.bindMidPointRenderEvent(),M.bindLineRenderEvent(),M.bindPolygonRenderEvent(),M}return mn(s,[{key:"getDefaultOptions",value:function(l){var g=un(un({},Kn(Mr(s.prototype),"getDefaultOptions",this).call(this,l)),{},{showMidPoint:!1,circleSteps:60});return g.distanceOptions&&(g.distanceOptions.showTotalDistance=!0,g.distanceOptions.showOnRadius===void 0&&(g.distanceOptions.showOnRadius=!0)),g.helper&&(g.helper=un(un({},g.helper),mr)),g}},{key:"getDistanceTexts",value:function(){var l=this.options.distanceOptions;if(!l)return[];var g=[],M=l.showWhen,j=l.showDashDistance,J=l.format,ve=l.showTotalDistance;return g.push.apply(g,so(this.getDashLineDistanceTexts(this.getDashLineData(),{showTotalDistance:!0,format:J,showDashDistance:j})).concat(so(this.getLineDistanceTexts(this.getLineData(),{showTotalDistance:ve,format:J,showWhen:M})))),g}},{key:"setData",value:function(l){var g=this,M=l.map(function(j){var J,ve,ze;j.properties=un(un({},Yc()),j.properties);var lt=(J=j.properties)===null||J===void 0?void 0:J.nodes;if(((ve=lt)===null||ve===void 0?void 0:ve.length)!==2){var Dt=Mi(Sf(j).geometry.coordinates,2),$t=Dt[0],lr=Dt[1],wr=qs(j),Vr=wr[2],$r=(wr[1]+wr[3])/2;lt=[Qf([$t,lr]),Qf([Vr,$r])],j.properties.nodes=lt}var Xr=lt[0],Gr=lt[1],Br=!!(!((ze=j.properties)===null||ze===void 0)&&ze.isActive),Tn=j.properties.line;return Tn||(Tn=g.handleCreatePolygonLine(Xr,Gr,{isActive:Br}),j.properties.line=Tn),g.handleCreatePolygon([Xr,Gr],Tn,un(un({},j.properties),{},{isActive:Br}))});this.source.setData({point:[],midPoint:[],dashLine:[],polygon:M,line:M.map(function(j){return j.properties.line})}),this.setTextData(this.getAllTexts()),this.editPolygon&&this.setActivePolygon(this.editPolygon)}},{key:"handleCreatePolygonLine",value:function(l,g){var M=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},j=this.getBoundaryPositions(l,g).map(function(J){return Qf(J)});return Pu(j,M)}},{key:"syncPolygonNodes",value:function(l,g){var M=l.properties.line,j=this.getBoundaryPositions(g[0],g[1]);return l.properties.nodes=g,l.geometry.coordinates=[j],this.setPolygonData(function(J){return J.map(function(ve){return If(ve,l)?l:ve})}),this.setPointData(l.properties.isDraw?[g[0]]:g),M.properties.nodes.forEach(function(J,ve){J.geometry.coordinates=j[ve]}),M.geometry.coordinates=j,l}},{key:"onLineDragging",value:function(l){var g=this.dragPolygon,M=Mi(this.previousPosition,2),j=M[0],J=M[1],ve=Kn(Mr(s.prototype),"onLineDragging",this).call(this,l);if(g){var ze=Mi(ao(l),2),lt=ze[0],Dt=ze[1];g.properties.nodes.forEach(function($t){var lr=Mi($t.geometry.coordinates,2);$t.geometry.coordinates=[lr[0]+lt-j,lr[1]+Dt-J]}),this.syncPolygonNodes(g,g.properties.nodes),this.setActivePolygon(g,{isDrag:!0}),this.emit(R.DrawEvent.Dragging,g,this.getPolygonData())}return ve}},{key:"getBoundaryPositions",value:function(l,g){for(var M=this.options.circleSteps,j=Ac(l,g,{units:"meters"}),J=[],ve=0;M>ve;ve++)J.push(Yu(l,j,-360*ve/M,{units:"meters"}).geometry.coordinates);return J.push(J[0]),J}}]),s}(ui),no=function(oe){yr(s,oe);var o=In(s);function s(l,g){var M;return ho(this,s),(M=o.call(this,l,g)).drawLineFinish=function(){var j,J=M.drawLine,ve=(j=J==null?void 0:J.properties.nodes)!==null&&j!==void 0?j:[];if(J&&(ve==null?void 0:ve.length)>1){M.setActiveLine(J);var ze=M.options,lt=ze.autoActive,Dt=ze.editable;lt&&Dt||M.handleLineUnClick(J),M.setHelper(Dt&<?"pointHover":M.addable?"draw":null),M.emit(R.DrawEvent.Add,J,M.getLineData())}},M.sceneRender.on(R.RenderEvent.DblClick,M.drawLineFinish),M.bindPointRenderEvent(),M.bindSceneEvent(),M.bindMidPointRenderEvent(),M.bindLineRenderEvent(),M}return mn(s,[{key:"dragItem",get:function(){return this.dragLine}},{key:"editItem",get:function(){return this.editLine}},{key:"getMainLayer",value:function(){var l,g;return(l=(g=this.render.line)===null||g===void 0?void 0:g.getLayers())!==null&&l!==void 0?l:[]}},{key:"setData",value:function(l){var g=l.map(function(M){var j,J;return M.properties=un(un({},Od()),(j=M.properties)!==null&&j!==void 0?j:{}),!((J=M.properties.nodes)===null||J===void 0)&&J.length||(M.properties.nodes=Co(M).map(function(ve){return Qf(ve)})),M});this.source.setData({point:[],midPoint:[],dashLine:[],line:g}),this.setTextData(this.getAllTexts()),this.editLine&&this.setActiveLine(this.editLine)}},{key:"getData",value:function(){return this.getLineData()}},{key:"getRenderTypes",value:function(){return["line","dashLine","midPoint","point","text"]}},{key:"bindPointRenderEvent",value:function(){var l;Kn(Mr(s.prototype),"bindPointRenderEvent",this).call(this),(l=this.pointRender)===null||l===void 0||l.on(R.RenderEvent.Contextmenu,this.onPointContextMenu.bind(this))}},{key:"onPointClick",value:function(l){var g,M=this,j=this.drawLine,J=(g=j==null?void 0:j.properties.nodes)!==null&&g!==void 0?g:[],ve=l.feature;if(If(ve,P(J)))requestAnimationFrame(function(){M.drawLineFinish()});else{var ze=Mi(ve.geometry.coordinates,2);l.lngLat={lng:ze[0],lat:ze[1]},this.onPointCreate(l)}}},{key:"removeNode",value:function(l,g){var M,j=this.getTargetFeature(g),J=this.getTargetFeature(l,(M=j==null?void 0:j.properties.nodes)!==null&&M!==void 0?M:[]);if(j&&J){var ve,ze=(ve=j==null?void 0:j.properties.nodes)!==null&&ve!==void 0?ve:[];if(3>ze.length)return;this.syncLineNodes(j,ze.filter(function(lt){return!If(J,lt)})),this.emit(R.DrawEvent.RemoveNode,J,j,this.getLineData()),this.emit(R.DrawEvent.Edit,j,this.getLineData())}}},{key:"onPointContextMenu",value:function(l){var g,M=this.editLine,j=l.feature,J=(g=M==null?void 0:M.properties.nodes)!==null&&g!==void 0?g:[];if(M&&J.length>=3)return this.removeNode(j,M),this.scene.setMapStatus({dragEnable:!0}),j}},{key:"onPointCreate",value:function(l){if(this.addable){var g=Kn(Mr(s.prototype),"onPointCreate",this).call(this,l);return g&&(this.setHelper("drawFinish"),this.emit(R.DrawEvent.AddNode,g,this.drawLine,this.getLineData())),g}}},{key:"onPointDragEnd",value:function(l){var g=this.editLine,M=Kn(Mr(s.prototype),"onPointDragEnd",this).call(this,l);return g&&M&&this.emit(R.DrawEvent.Edit,g,this.getLineData()),M}},{key:"onLineDragStart",value:function(l){var g=Kn(Mr(s.prototype),"onLineDragStart",this).call(this,l);return g&&this.emit(R.DrawEvent.DragStart,g,this.getLineData()),g}},{key:"onLineDragging",value:function(l){var g=Kn(Mr(s.prototype),"onLineDragging",this).call(this,l);return g&&this.emit(R.DrawEvent.Dragging,g,this.getLineData()),g}},{key:"onLineDragEnd",value:function(l){var g=Kn(Mr(s.prototype),"onLineDragEnd",this).call(this,l);return g&&(this.emit(R.DrawEvent.DragEnd,g,this.getLineData()),this.emit(R.DrawEvent.Edit,g,this.getLineData())),g}},{key:"onMidPointClick",value:function(l){var g=this.editLine,M=Kn(Mr(s.prototype),"onMidPointClick",this).call(this,l);return g&&M&&(this.emit(R.DrawEvent.Edit,g,this.getLineData()),this.emit(R.DrawEvent.AddNode,M,g,this.getLineData())),M}},{key:"onSceneMouseMove",value:function(l){var g=this.drawLine;if(g){var M,j=P(g.properties.nodes),J=ao(l);this.options.adsorbOptions&&(J=(M=this.getAdsorbPosition(J))!==null&&M!==void 0?M:J),this.setDashLineData([hl([J,j.geometry.coordinates])]),this.setTextData(this.getAllTexts())}}},{key:"setActiveFeature",value:function(l){var g=this.getTargetFeature(l);g?this.setActiveLine(g):this.clearActiveLine()}},{key:"resetFeatures",value:function(){var l=this.getLineData();this.drawLine&&(l=l.filter(function(g){return!g.properties.isDraw}),this.source.setData({point:[],dashLine:[],midPoint:[]}),this.setTextData(function(g){return g.filter(function(M){return!M.properties.isActive})})),this.editLine&&this.handleLineUnClick(this.editLine),this.setLineData(l.map(function(g){return g.properties=un(un({},g.properties),{},{isDrag:!1,isActive:!1,isHover:!1}),g}))}},{key:"enablePointRenderAction",value:function(){var l;Kn(Mr(s.prototype),"enablePointRenderAction",this).call(this),this.options.editable&&((l=this.pointRender)===null||l===void 0||l.enableContextMenu())}},{key:"disablePointRenderAction",value:function(){var l;Kn(Mr(s.prototype),"disablePointRenderAction",this).call(this),(l=this.pointRender)===null||l===void 0||l.disableContextMenu()}},{key:"bindEnableEvent",value:function(){Kn(Mr(s.prototype),"bindEnableEvent",this).call(this),this.enableSceneRenderAction(),this.enablePointRenderAction(),this.enableLineRenderAction(),this.enableMidPointRenderAction(),this.sceneRender.enableDblClick()}},{key:"unbindEnableEvent",value:function(){Kn(Mr(s.prototype),"unbindEnableEvent",this).call(this),this.disableSceneRenderAction(),this.disablePointRenderAction(),this.disableLineRenderAction(),this.disableMidPointRenderAction(),this.sceneRender.disableDblClick()}},{key:"bindThis",value:function(){Kn(Mr(s.prototype),"bindThis",this).call(this),this.bindPointRenderEvent=this.bindPointRenderEvent.bind(this),this.bindSceneEvent=this.bindSceneEvent.bind(this),this.bindLineRenderEvent=this.bindLineRenderEvent.bind(this),this.bindMidPointRenderEvent=this.bindMidPointRenderEvent.bind(this)}}]),s}(pn),Wa=function(oe){yr(s,oe);var o=In(s);function s(l,g){var M;return ho(this,s),(M=o.call(this,l,g)).bindPointRenderEvent(),M}return mn(s,[{key:"dragItem",get:function(){return this.dragPoint}},{key:"editItem",get:function(){return this.editPoint}},{key:"getDefaultOptions",value:function(l){var g=un(un({},this.getCommonOptions(l)),{},{helper:Vh(fe),initialData:l.initialData});return g.style.point=w,g}},{key:"bindEnableEvent",value:function(){Kn(Mr(s.prototype),"bindEnableEvent",this).call(this),this.enablePointRenderAction()}},{key:"unbindEnableEvent",value:function(){Kn(Mr(s.prototype),"unbindEnableEvent",this).call(this),this.disablePointRenderAction()}},{key:"getRenderTypes",value:function(){return["point"]}},{key:"getMainLayer",value:function(){var l,g;return(l=(g=this.render.point)===null||g===void 0?void 0:g.getLayers())!==null&&l!==void 0?l:[]}},{key:"setData",value:function(l){this.setPointData(l.map(function(g){var M;return g.properties=un(un({},nf()),(M=g.properties)!==null&&M!==void 0?M:{}),g}))}},{key:"getData",value:function(){return this.getPointData()}},{key:"onPointCreate",value:function(l){if(this.addable){var g=Kn(Mr(s.prototype),"onPointCreate",this).call(this,l);if(g)return this.options.editable&&this.setHelper("pointHover"),this.emit(R.DrawEvent.Add,g,this.getData()),g}else this.setPointData(function(M){return M.map(function(j){return j.properties=un(un({},j.properties),{},{isHover:!1,isActive:!1}),j})})}},{key:"onPointMouseMove",value:function(l){var g=Kn(Mr(s.prototype),"onPointMouseMove",this).call(this,l);return this.options.editable&&!this.dragPoint&&this.setHelper("pointHover"),g}},{key:"onPointMouseOut",value:function(l){var g=Kn(Mr(s.prototype),"onPointMouseOut",this).call(this,l);return this.setHelper(this.addable?"draw":null),g}},{key:"onPointDragStart",value:function(l){var g=Kn(Mr(s.prototype),"onPointDragStart",this).call(this,l);return this.setHelper("pointDrag"),this.emit(R.DrawEvent.DragStart,g,this.getData()),g}},{key:"onPointDragging",value:function(l){var g=Kn(Mr(s.prototype),"onPointDragging",this).call(this,l);return g&&this.options.editable&&this.emit(R.DrawEvent.Dragging,g,this.getData()),g}},{key:"onPointDragEnd",value:function(l){var g=Kn(Mr(s.prototype),"onPointDragEnd",this).call(this,l);return g&&this.options.editable&&(this.setHelper("pointHover"),this.emit(R.DrawEvent.DragEnd,g,this.getData()),this.emit(R.DrawEvent.Edit,g,this.getData())),g}},{key:"bindThis",value:function(){Kn(Mr(s.prototype),"bindThis",this).call(this),this.bindPointRenderEvent=this.bindPointRenderEvent.bind(this)}},{key:"onSceneMouseMove",value:function(l){}},{key:"setActiveFeature",value:function(l){var g=this.getTargetFeature(l);this.setPointData(function(M){return M.map(function(j){return j.properties.isActive=If(g,j),j})})}},{key:"resetFeatures",value:function(){this.setPointData(function(l){return l.map(function(g){return g.properties=un(un({},g.properties),{},{isDrag:!1,isActive:!1,isHover:!1}),g})})}}]),s}(F),ha=function(oe){yr(s,oe);var o=In(s);function s(l,g){var M;return ho(this,s),(M=o.call(this,l,g)).drawPolygonFinish=function(){var j,J=M.drawPolygon,ve=(j=J==null?void 0:J.properties.nodes)!==null&&j!==void 0?j:[];if(J&&ve.length>=3){J.properties.isDraw=!1,M.syncPolygonNodes(J,ve),M.setActivePolygon(J);var ze=M.options,lt=ze.autoActive,Dt=ze.editable;lt&&Dt||M.handlePolygonUnClick(J),M.setHelper(Dt?lt?"pointHover":"polygonHover":M.addable?"draw":null),M.emit(R.DrawEvent.Add,J,M.getPolygonData())}},M.sceneRender.on(R.RenderEvent.DblClick,M.drawPolygonFinish),M.bindPointRenderEvent(),M.bindSceneEvent(),M.bindMidPointRenderEvent(),M.bindLineRenderEvent(),M.bindPolygonRenderEvent(),M}return mn(s,[{key:"getDefaultOptions",value:function(l){return un(un({},Kn(Mr(s.prototype),"getDefaultOptions",this).call(this,l)),{},{liveUpdate:!1})}},{key:"setData",value:function(l){var g=l.map(function(M){var j,J;if(M.properties=un(un({},Yc()),(j=M.properties)!==null&&j!==void 0?j:{}),!(!((J=M.properties.nodes)===null||J===void 0)&&J.length)){var ve=Co(M);ve=ve.slice(0,ve.length-1),M.properties.nodes=ve.map(function(lt){return Qf(lt)})}if(!M.properties.line){var ze=M.properties.nodes;M.properties.line=Pu([].concat(so(ze),[Qf(Tf(ze).geometry.coordinates)]))}return M});this.source.setData({point:[],midPoint:[],dashLine:[],polygon:g,line:g.map(function(M){return M.properties.line})}),this.setTextData(this.getAllTexts()),this.editPolygon&&this.setActivePolygon(this.editPolygon)}},{key:"onPointCreate",value:function(l){if(this.addable&&!this.dragPoint){var g=Kn(Mr(s.prototype),"onPointCreate",this).call(this,l),M=this.drawPolygon,j=this.drawLine;return g&&(M?(this.syncPolygonNodes(M,[].concat(so(M.properties.nodes),[g])),this.setDashLineData([hl([ao(l),M.properties.nodes[0].geometry.coordinates])]),M.properties.nodes.length>1&&this.setHelper("drawFinish")):j&&(this.handleCreatePolygon([g],j),this.setHelper("drawContinue")),this.emit(R.DrawEvent.AddNode,g,M,this.getPolygonData())),g}}},{key:"onPointClick",value:function(l){var g=this,M=this.drawPolygon,j=l.feature;if(M){var J=M.properties.nodes;if(J.length<3||!If(Tf(J),j)&&!If(P(J),j)){var ve=Mi(j.geometry.coordinates,2);l.lngLat={lng:ve[0],lat:ve[1]},this.onPointCreate(l)}else requestAnimationFrame(function(){g.drawPolygonFinish()})}}},{key:"onPointDragging",value:function(l){var g=this.dragPoint,M=this.editPolygon;if(g&&M){var j=M.properties.line;j.properties.nodes=j.properties.nodes.map(function(lr){return If(lr,g)?g:lr});var J=j.properties.nodes,ve=J.slice(0,J.length-1),ze=Tf(J),lt=P(J),Dt=If(ze,g)||If(lt,g);if(Dt&&(ze.geometry.coordinates=lt.geometry.coordinates=ao(l)),this.options.adsorbOptions&&Dt){var $t=this.resetAdsorbLngLat(l);$t&&(ze.geometry.coordinates=lt.geometry.coordinates=$t)}Kn(Mr(s.prototype),"onPointDragging",this).call(this,l),this.syncPolygonNodes(M,ve),this.setActivePolygon(M)}return g}},{key:"onLineDragging",value:function(l){var g=this.dragPolygon,M=Kn(Mr(s.prototype),"onLineDragging",this).call(this,l);if(M&&g){var j=M.properties.nodes;this.syncPolygonNodes(g,j.slice(0,j.length-1)),this.emit(R.DrawEvent.Dragging,g,this.getPolygonData())}return M}},{key:"onMidPointClick",value:function(l){var g=Kn(Mr(s.prototype),"onMidPointClick",this).call(this,l),M=this.editPolygon;return g&&M&&(this.emit(R.DrawEvent.Edit,M,this.getPolygonData()),this.emit(R.DrawEvent.AddNode,g,M,this.getPolygonData())),g}},{key:"onSceneMouseMove",value:function(l){var g,M=this.drawPolygon,j=(g=M==null?void 0:M.properties.nodes)!==null&&g!==void 0?g:[];if(M&&j.length){this.options.adsorbOptions&&this.resetAdsorbLngLat(l);var J=ao(l),ve=[];if(ve.push(hl([J,Tf(j).geometry.coordinates])),j.length>1&&ve.push(hl([J,P(j).geometry.coordinates])),this.options.liveUpdate&&j.length>=2){var ze=Co(Vo(j));M.geometry.coordinates=[[].concat(so(ze),[J,ze[0]])],this.setPolygonData(this.getPolygonData())}this.setDashLineData(ve),this.setTextData(this.getAllTexts())}}},{key:"removeNode",value:function(l,g){var M,j=this.getTargetFeature(g),J=this.getTargetFeature(l,(M=j==null?void 0:j.properties.nodes)!==null&&M!==void 0?M:[]);if(j&&J){var ve,ze=(ve=j==null?void 0:j.properties.nodes)!==null&&ve!==void 0?ve:[];if(4>ze.length)return;this.syncPolygonNodes(j,ze.filter(function(lt){return!If(J,lt)})),this.emit(R.DrawEvent.RemoveNode,J,j,this.getLineData()),this.emit(R.DrawEvent.Edit,j,this.getPolygonData())}}},{key:"onPointContextMenu",value:function(l){var g,M=this.editPolygon,j=l.feature,J=(g=M==null?void 0:M.properties.nodes)!==null&&g!==void 0?g:[];if(M&&J.length>=4)return J.find(function(ve){return If(ve,j)})||(j=J[0]),this.removeNode(j,M),j}},{key:"bindPointRenderEvent",value:function(){var l;Kn(Mr(s.prototype),"bindPointRenderEvent",this).call(this),(l=this.pointRender)===null||l===void 0||l.on(R.RenderEvent.Contextmenu,this.onPointContextMenu.bind(this))}},{key:"enablePointRenderAction",value:function(){var l;Kn(Mr(s.prototype),"enablePointRenderAction",this).call(this),this.options.editable&&((l=this.pointRender)===null||l===void 0||l.enableContextMenu())}},{key:"disablePointRenderAction",value:function(){var l;Kn(Mr(s.prototype),"disablePointRenderAction",this).call(this),(l=this.pointRender)===null||l===void 0||l.disableContextMenu()}}]),s}(Jn),Go=function(oe){yr(s,oe);var o=In(s);function s(l,g){var M;return ho(this,s),(M=o.call(this,l,g)).bindPointRenderEvent(),M.bindSceneEvent(),M.bindMidPointRenderEvent(),M.bindLineRenderEvent(),M.bindPolygonRenderEvent(),M}return mn(s,[{key:"getDefaultOptions",value:function(l){var g=Kn(Mr(s.prototype),"getDefaultOptions",this).call(this,l);return g.helper&&(g.helper=un(un({},g.helper),rr)),g}},{key:"setData",value:function(l){var g=this,M=l.map(function(j){var J,ve,ze;j.properties=un(un({},Yc()),(J=j.properties)!==null&&J!==void 0?J:{});var lt=j.properties.nodes;if(((ve=lt)===null||ve===void 0?void 0:ve.length)!==2){var Dt=Mi(qs(j),4),$t=Dt[2],lr=Dt[3];lt=[Qf([Dt[0],Dt[1]]),Qf([$t,lr])],j.properties.nodes=lt}var wr=Mi(lt,2),Vr=wr[0],$r=wr[1],Xr=!!(!((ze=j.properties)===null||ze===void 0)&&ze.isActive),Gr=j.properties.line;return Gr||(Gr=g.handleCreatePolygonLine(Vr,$r,{isActive:Xr}),j.properties.line=Gr),g.handleCreatePolygon([Vr,$r],Gr,un(un({},j.properties),{},{isActive:Xr}))});this.source.setData({point:[],midPoint:[],dashLine:[],polygon:M,line:M.map(function(j){return j.properties.line})}),this.setTextData(this.getAllTexts()),this.editPolygon&&this.setActivePolygon(this.editPolygon)}},{key:"handleCreatePolygonLine",value:function(l,g){var M=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},j=Co($l(Vo([l,g]))).map(function(J,ve){return ve===0?l:ve===2?g:Qf(J)});return Pu(j,M)}},{key:"syncPolygonNodes",value:function(l,g){var M=l.properties.line,j=Co($l(Vo(g)));l.properties.nodes=g,l.geometry.coordinates=[j],this.setPolygonData(function(ze){return ze.map(function(lt){return If(lt,l)?l:lt})}),this.setPointData(l.properties.isDraw?[g[0]]:g);var J=M.properties.nodes,ve=j.filter(function(ze){return!Bs(ze,g[0].geometry.coordinates)&&!Bs(ze,g[1].geometry.coordinates)});return J.forEach(function(ze,lt){var Dt=[0,0];switch(lt){case 0:Dt=g[0].geometry.coordinates;break;case 1:Dt=ve[0];break;case 2:Dt=g[1].geometry.coordinates;break;case 3:Dt=ve[1];break;case 4:Dt=Vh(g[0].geometry.coordinates)}ze.geometry.coordinates=Dt}),M.geometry.coordinates=j,l}},{key:"onLineDragging",value:function(l){var g=Kn(Mr(s.prototype),"onLineDragging",this).call(this,l),M=this.dragPolygon;if(g&&M){var j=M.properties.line.properties.nodes;this.syncPolygonNodes(M,[j[0],j[2]]),this.setActivePolygon(M,{isDrag:!0}),this.emit(R.DrawEvent.Dragging,M,this.getPolygonData())}return g}}]),s}(ui),Wo=function(oe,o){for(var s=oe;s&&!Array.from(s.classList).includes(o);)s=s.parentElement;return s},To=["point","line","polygon","rect","circle","clear"],El={point:"#l7draw-point",line:"#l7draw-line",polygon:"#l7draw-polygon",rect:"#l7draw-rect",circle:"#l7draw-circle",clear:"#l7draw-qingkong"},gl={point:Wa,line:no,polygon:ha,rect:Go,circle:ci},du="data-draw-type",Qu="l7-draw-control",_h="".concat(Qu,"__btn"),Th="".concat(_h,"--active");(function(oe){var o,s,l,g,M,j='',J=(J=document.getElementsByTagName("script"))[J.length-1].getAttribute("data-injectcss");if(J&&!oe.__iconfont__svg__cssinject__){oe.__iconfont__svg__cssinject__=!0;try{document.write("")}catch(ze){console&&console.log(ze)}}function ve(){M||(M=!0,l())}o=function(){var ze,lt=document.createElement("div");lt.innerHTML=j,j=null,(lt=lt.getElementsByTagName("svg")[0])&&(lt.setAttribute("aria-hidden","true"),lt.style.position="absolute",lt.style.width=0,lt.style.height=0,lt.style.overflow="hidden",(ze=document.body).firstChild?function(Dt,$t){$t.parentNode.insertBefore(Dt,$t)}(lt,ze.firstChild):ze.appendChild(lt))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(o,0):(s=function(){document.removeEventListener("DOMContentLoaded",s,!1),o()},document.addEventListener("DOMContentLoaded",s,!1)):document.attachEvent&&(l=o,g=oe.document,M=!1,function ze(){try{g.documentElement.doScroll("left")}catch(lt){return void setTimeout(ze,50)}ve()}(),g.onreadystatechange=function(){g.readyState=="complete"&&(g.onreadystatechange=null,ve())})})(window),Pi(".l7-draw-control{display:flex;overflow:hidden;background:#fff;border-radius:2px;box-shadow:0 0 20px rgba(0,0,0,.14901960784313725)}.l7-draw-control__btn{display:inline-flex;align-items:center;justify-content:center;width:30px;height:30px;padding:0;text-align:center;background:transparent;border-width:0;border-right:1px solid #e0e0e0;outline:0;cursor:pointer}.l7-draw-control__btn:hover{background-color:#e5e5e5}.l7-draw-control__btn:last-child{border-right:0;border-bottom:0}.l7-draw-control__btn .l7-draw-icon{width:26px;height:26px;overflow:hidden;fill:currentColor}.l7-draw-control__btn--active svg{color:#0370fe}");var vh=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,$f=/^\w*$/,Nl=function(oe,o){if(lf(oe))return!1;var s=typeof oe;return!(s!="number"&&s!="symbol"&&s!="boolean"&&oe!=null&&!Xf(oe))||$f.test(oe)||!vh.test(oe)||o!=null&&oe in Object(o)};function vc(oe,o){if(typeof oe!="function"||o!=null&&typeof o!="function")throw new TypeError("Expected a function");var s=function(){var l=arguments,g=o?o.apply(this,l):l[0],M=s.cache;if(M.has(g))return M.get(g);var j=oe.apply(this,l);return s.cache=M.set(g,j)||M,j};return s.cache=new(vc.Cache||Kf),s}vc.Cache=Kf;var Hh=vc,Af=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Fh=/\\(\\)?/g,Mf=function(oe){var o=Hh(oe,function(l){return s.size===500&&s.clear(),l}),s=o.cache;return o}(function(oe){var o=[];return oe.charCodeAt(0)===46&&o.push(""),oe.replace(Af,function(s,l,g,M){o.push(g?M.replace(Fh,"$1"):l||s)}),o}),lm=Sc?Sc.prototype:void 0,bm=lm?lm.toString:void 0,xm=function oe(o){if(typeof o=="string")return o;if(lf(o))return yh(o,oe)+"";if(Xf(o))return bm?bm.call(o):"";var s=o+"";return s=="0"&&1/o==-1/0?"-0":s},Rp=function(oe){return oe==null?"":xm(oe)},Om=function(oe,o){return lf(oe)?oe:Nl(oe,o)?[oe]:Mf(Rp(oe))},qd=function(oe){if(typeof oe=="string"||Xf(oe))return oe;var o=oe+"";return o=="0"&&1/oe==-1/0?"-0":o},N0=function(oe,o){for(var s=0,l=(o=Om(o,oe)).length;oe!=null&&l>s;)oe=oe[qd(o[s++])];return s&&s==l?oe:void 0},ld=function(oe,o,s){var l=-1,g=oe.length;0>o&&(o=-o>g?0:g+o),0>(s=s>g?g:s)&&(s+=g),g=o>s?0:s-o>>>0,o>>>=0;for(var M=Array(g);++lo.length?oe:N0(oe,ld(o,0,-1))},Gh=function(oe,o){return o=Om(o,oe),(oe=Qp(oe,o))==null||delete oe[qd(P(o))]},wd=function(oe){return ls(oe)?void 0:oe},Md=Sc?Sc.isConcatSpreadable:void 0,em=function(oe){return lf(oe)||od(oe)||!!(Md&&oe&&oe[Md])},Bd=function oe(o,s,l,g,M){var j=-1,J=o.length;for(l||(l=em),M||(M=[]);++j0&&l(ve)?s>1?oe(ve,s-1,l,g,M):Yp(M,ve):g||(M[M.length]=ve)}return M},Qd=function(oe){return oe!=null&&oe.length?Bd(oe,1):[]},Jd=function(oe){return lc(Mu(oe,void 0,Qd),oe+"")}(function(oe,o){var s={};if(oe==null)return s;var l=!1;o=yh(o,function(M){return M=Om(M,oe),l||(l=M.length>1),M}),qf(oe,Bp(oe),s),l&&(s=um(s,7,wd));for(var g=o.length;g--;)Gh(s,o[g]);return s}),Ed=Jd,_p=function(oe){yr(s,oe);var o=In(s);function s(l){var g,M=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return ho(this,s),(g=o.call(this,M)).controlOption=void 0,g.sceneInstance=void 0,g.drawMap={},g.btnMap={},g.activeType=null,g.emitDataChange=v(function(){g.emit(R.ControlEvent.DataChange,g.getDrawData())},16),g.emitDrawSelect=function(j,J){g.emit(R.ControlEvent.DrawSelect,j,J)},g.sceneInstance=l,g.controlOption=un(un({},g.getDefault()),M||{}),g.onBtnClick=g.onBtnClick.bind(Vn(g)),g}return mn(s,[{key:"getActiveType",value:function(){return this.activeType}},{key:"getDefault",value:function(){return un(un({},Kn(Mr(s.prototype),"getDefault",this).call(this)),{},{className:"",buttonClassName:"",activeButtonClassName:"",style:"",position:"topleft",commonDrawOptions:{},drawConfig:{point:!0,line:!0,polygon:!0,rect:!0,circle:!0,clear:!0}})}},{key:"addTo",value:function(l){return Kn(Mr(s.prototype),"addTo",this).call(this,l),this.init(),this}},{key:"onAdd",value:function(){var l=this.controlOption,g=l.className,M=l.style,j=V.DOM.create("div","".concat(Qu," ").concat(g));return M&&j.setAttribute("style",M),j}},{key:"onRemove",value:function(){Object.values(this.drawMap).forEach(function(l){l.clear(!0)})}},{key:"init",value:function(){var l,g=this,M=[];Object.entries(this.controlOption.drawConfig).filter(function(j){var J=Mi(j,2);return J[1]}).sort(function(j,J){var ve=Mi(j,2)[1],ze=Mi(J,2)[1],lt=Number.MAX_SAFE_INTEGER;return(typeof ve=="boolean"?lt:ve.order)-(typeof ze=="boolean"?lt:ze.order)}).map(function(j){var J=Mi(j,2),ve=J[1];return[J[0],Zi(ve)==="object"?Ed(ve,"order"):ve]}).forEach(function(j){var J=Mi(j,2),ve=J[0],ze=J[1];if(Zi(ze)==="object"&&ze.button){var lt=ze.button;lt.classList.contains("l7-draw-control__btn")||lt.classList.add("l7-draw-control__btn"),g.btnMap[ve]=lt,M.push(lt)}else if(ze&&To.includes(ve)){var Dt=g.initBtn(ve);Dt.addEventListener("click",g.onBtnClick),M.push(Dt),g.btnMap[ve]=Dt;var $t=gl[ve];if($t&&g.sceneInstance){var lr=new $t(g.sceneInstance,un(un({},g.controlOption.commonDrawOptions),typeof ze=="boolean"?{}:ze));lr.on(R.DrawEvent.Change,g.emitDataChange),lr.on(R.DrawEvent.Select,function(wr){g.emitDrawSelect(ve,wr)}),g.drawMap[ve]=lr}}}),(l=this.container).append.apply(l,M),this.controlOption.defaultActiveType&&this.onDrawClick(this.controlOption.defaultActiveType)}},{key:"getDrawData",value:function(){return B0(Cf(this.drawMap).map(function(l){var g=Mi(l,2);return[g[0],g[1].getData()]}))}},{key:"getTypeDraw",value:function(l){var g;return(g=this.drawMap[l])!==null&&g!==void 0?g:null}},{key:"onBtnClick",value:function(l){var g=Wo(l.target,_h);if(g){var M=g.getAttribute(du);M==="clear"?this.clearDrawData():this.onDrawClick(M)}}},{key:"setActiveType",value:function(l){var g=null,M=this.activeType;if(M){var j,J=this.btnMap[M];if(J){V.DOM.removeClass(J,Th);var ve=this.controlOption.activeButtonClassName;ve&&V.DOM.removeClass(J,ve)}(j=this.drawMap[M])===null||j===void 0||j.disable(),g=null}if(M!==l&&l){var ze;(ze=this.drawMap[l])===null||ze===void 0||ze.enable();var lt=this.btnMap[l];lt&&V.DOM.addClass(lt,"".concat(Th," ").concat(this.controlOption.activeButtonClassName)),g=l}this.activeType=g,this.emit(R.ControlEvent.DrawChange,g)}},{key:"onDrawClick",value:function(l){this.setActiveType(l)}},{key:"clearDrawData",value:function(){Object.values(this.drawMap).forEach(function(l){l==null||l.clear()}),this.emit(R.ControlEvent.DrawClear)}},{key:"initBtn",value:function(l){var g=V.DOM.create("button","".concat(_h," ").concat(this.controlOption.buttonClassName));return g.innerHTML=``),g.setAttribute(du,l),g}}]),s}(V.Control);R.ACTIVE_COLOR=ee,R.BaseMode=D,R.CircleDrawer=ci,R.DEFAULT_ADSORB_CONFIG=gr,R.DEFAULT_AREA_OPTIONS=Wr,R.DEFAULT_COMMON_OPTIONS=te,R.DEFAULT_CURSOR_MAP=y,R.DEFAULT_DISTANCE_OPTIONS=Pn,R.DEFAULT_HISTORY_CONFIG=Ci,R.DEFAULT_KEYBOARD_CONFIG=at,R.DEFAULT_MID_POINT_STYLE=nt,R.DEFAULT_NODE_NORMAL_STYLE=He,R.DEFAULT_NODE_STYLE=Wt,R.DEFAULT_POINT_NORMAL_STYLE=me,R.DEFAULT_POINT_STYLE=w,R.DEFAULT_POPUP_CONFIG=Vt,R.DEFAULT_SOURCE_DATA=p,R.DEFAULT_STYLE=x,R.DEFAULT_TEXT_NORMAL_STYLE=b,R.DashLineRender=ql,R.DragPolygonMode=ui,R.DrawCircle=ci,R.DrawControl=_p,R.DrawLine=no,R.DrawPoint=Wa,R.DrawPolygon=ha,R.DrawRect=Go,R.LayerRender=Tl,R.LineDrawer=no,R.LineMode=pn,R.LineRender=B,R.MidPointMode=q,R.MidPointRender=W,R.NORMAL_COLOR=L,R.PointDrawer=Wa,R.PointMode=F,R.PointRender=_e,R.PolygonDrawer=ha,R.PolygonMode=Jn,R.PolygonRender=_t,R.RENDER_MAP=f,R.RectDrawer=Go,R.SceneRender=jt,R.Source=jn,R.TextRender=ie,R.calcAreaText=Vp,R.calcDistanceTextsByLine=Oh,R.createDashLine=hl,R.createLineFeature=Pu,R.createPointFeature=Qf,R.createPolygonFeature=Gs,R.findMinIndex=Kc,R.getAdsorbFeature=Rr,R.getAdsorbLine=ti,R.getAdsorbPoint=sr,R.getDefaultLineProperties=Od,R.getDefaultPointProperties=nf,R.getDefaultPolygonProperties=Yc,R.getLineCenterPoint=of,R.getLngLat=Zo,R.getMapDom=ei,R.getParentByClassName=Wo,R.getPosition=ao,R.getSingleColorStyle=function(oe){return{point:{normal:{color:oe},hover:{color:oe},active:{color:oe}},line:{normal:{color:oe},hover:{color:oe},active:{color:oe}},polygon:{normal:{color:oe},hover:{color:oe},active:{color:oe},style:{opacity:.2}},text:{normal:{color:oe},active:{color:oe}},midPoint:{normal:{color:oe}},dashLine:{normal:{color:oe}}}},R.getUuid=ed,R.isDev=!1,R.isSameFeature=If,R.resetEventLngLat=_o,R.splitByPosition=sa,R.transLngLat2Position=Iu,R.updateTargetFeature=$h,Object.defineProperty(R,"__esModule",{value:!0})})},60965:function(Ye,ye,A){"use strict";A.r(ye),A.d(ye,{AJAXError:function(){return Qn},AttributeType:function(){return Vu},BKDRHash:function(){return ll},BaiduMap:function(){return DB},BaseLayer:function(){return hv},BaseMapService:function(){return Ng},BaseMapWrapper:function(){return Vv},BaseModel:function(){return Kd},BasePostProcessingPass:function(){return Pv},BlendType:function(){return pf},ButtonControl:function(){return O_},CameraUniform:function(){return sg},CanvasLayer:function(){return UP},CanvasUpdateType:function(){return R1},CityBuildingLayer:function(){return jI},Control:function(){return dy},CoordinateSystem:function(){return ne},CoordinateUniform:function(){return ue},DOM:function(){return R},Earth:function(){return V9},EarthLayer:function(){return ED},ExportImage:function(){return Y4},FrequencyController:function(){return yu},Fullscreen:function(){return eP},GaodeMap:function(){return RT},GaodeMapV1:function(){return dB},GaodeMapV2:function(){return RT},GeoLocate:function(){return nP},GeometryLayer:function(){return uR},GoogleMap:function(){return qz},HeatmapLayer:function(){return NR},IDebugLog:function(){return zd},ILayerStage:function(){return zl},ImageLayer:function(){return vS},InteractionEvent:function(){return Du},LRUCache:function(){return ac},LayerPopup:function(){return LF},LayerSwitch:function(){return aP},LineLayer:function(){return Yx},LineTriangulation:function(){return n0},LinearDir:function(){return Bx},LoadTileDataStatus:function(){return Su},Logo:function(){return IE},Map:function(){return K9},MapLibre:function(){return gz},MapServiceEvent:function(){return e0},MapTheme:function(){return dP},MapType:function(){return al},Mapbox:function(){return sz},Marker:function(){return wE},MarkerLayer:function(){return k4},MaskLayer:function(){return qx},MaskOperation:function(){return Jc},MouseLocation:function(){return vP},PassType:function(){return Uv},PointFillTriangulation:function(){return Np},PointLayer:function(){return yb},PolygonLayer:function(){return _b},PopperControl:function(){return SE},Popup:function(){return Q3},PositionType:function(){return nl},RasterLayer:function(){return Ab},RasterTileType:function(){return Y0},Satistics:function(){return V},Scale:function(){return _P},ScaleTypes:function(){return ch},Scene:function(){return qj},SceneConifg:function(){return oi},SceneEventList:function(){return Jm},SelectControl:function(){return Rx},SizeUnitType:function(){return fb},Source:function(){return Ix},SourceTile:function(){return qo},StencilType:function(){return ec},StyleScaleType:function(){return _d},Swipe:function(){return EF},TMap:function(){return zz},TYPES:function(){return sr},TencentMap:function(){return Iz},TextureBlend:function(){return $E},TextureUsage:function(){return Eh},TileDebugLayer:function(){return rD},TilesetManager:function(){return uf},UpdateTileStrategy:function(){return nc},Viewport:function(){return by},WindLayer:function(){return QD},WorkerSourceMap:function(){return Ep},Zoom:function(){return TF},aProjectFlat:function(){return Ol},amap2Project:function(){return cn},amap2UnProject:function(){return an},anchorTranslate:function(){return Fn},anchorType:function(){return ko},applyAnchorClass:function(){return zn},bBoxToBounds:function(){return Ia},bindAll:function(){return Zs},boundsContains:function(){return zo},calAngle:function(){return mu},calDistance:function(){return fa},calculateCentroid:function(){return wl},calculatePointsCenterAndRadius:function(){return vu},container:function(){return ym},createLayerContainer:function(){return Rm},createSceneContainer:function(){return og},decodePickingColor:function(){return eo},defaultValue:function(){return Id},djb2hash:function(){return Fu},encodePickingColor:function(){return ba},executeWorkerTask:function(){return sm},expandUrl:function(){return rh},extent:function(){return xl},flow:function(){return Sl},formatImage:function(){return Ii},generateCatRamp:function(){return Ps},generateColorRamp:function(){return va},generateCustomRamp:function(){return fo},generateLinearRamp:function(){return Do},generateQuantizeRamp:function(){return Nr},getAngle:function(){return Is},getArrayBuffer:function(){return sn},getBBoxFromPoints:function(){return ml},getCullFace:function(){return Xi},getData:function(){return En},getDefaultDomain:function(){return Yi},getImage:function(){return Wi},getJSON:function(){return xo},getProtocolAction:function(){return _i},getReferrer:function(){return Xs},getTileIndices:function(){return Al},getTileWarpXY:function(){return Sc},getURLFromTemplate:function(){return ud},getWMTSURLFromTemplate:function(){return fp},gl:function(){return Er},guid:function(){return Bu},isAndroid:function(){return Qs},isColor:function(){return Gi},isImageBitmap:function(){return Vs},isPC:function(){return Uu},isURLTemplate:function(){return Yf},isWorker:function(){return tl},isiOS:function(){return Ha},latitude:function(){return Lf},lazyInject:function(){return Qm},lazyMultiInject:function(){return Rv},lineAtOffset:function(){return ff},lineAtOffsetAsyc:function(){return vf},lineStyleType:function(){return LP},lngLatInExtent:function(){return ps},lngLatToMeters:function(){return sf},lnglatDistance:function(){return Xn},lodashUtil:function(){return lo},longitude:function(){return Ul},makeXMLHttpRequestPromise:function(){return ni},metersToLngLat:function(){return Hf},normalize:function(){return Sa},osmLonLat2TileXY:function(){return Qc},osmTileXY2LonLat:function(){return hf},packCircleVertex:function(){return sb},padBounds:function(){return to},polygonFillTriangulation:function(){return L0},postData:function(){return li},project:function(){return vi},removeDuplicateUniforms:function(){return Hy},rgb2arr:function(){return Lo},sameOrigin:function(){return or},setL7WorkerSource:function(){return i0},tileToBounds:function(){return Xc},tranfrormCoord:function(){return ul},unProjectFlat:function(){return _l},validateLngLat:function(){return Fc},version:function(){return Qj}});var R={};A.r(R),A.d(R,{DPR:function(){return Co},addClass:function(){return Js},addStyle:function(){return wo},appendElementType:function(){return Eu},clearChildren:function(){return Aa},create:function(){return Vo},css2Style:function(){return si},empty:function(){return wi},findParentElement:function(){return Cs},getClass:function(){return Vi},getContainer:function(){return Da},getDiffRect:function(){return Ms},getStyleList:function(){return Pa},getViewPortScale:function(){return $a},hasClass:function(){return Of},printCanvas:function(){return na},remove:function(){return bs},removeClass:function(){return Hu},removeStyle:function(){return ss},setChecked:function(){return Ns},setClass:function(){return en},setTransform:function(){return io},setUnDraggable:function(){return qs},splitWords:function(){return Ra},toggleClass:function(){return xn},triggerResize:function(){return Uo},trim:function(){return ta}});var V={};A.r(V),A.d(V,{getColumn:function(){return Dl},getSatByColumn:function(){return Gf},max:function(){return cl},mean:function(){return iu},min:function(){return Us},mode:function(){return Ca},statMap:function(){return xa},sum:function(){return vl}});var y={};A.r(y),A.d(y,{add:function(){return Eo},adjoint:function(){return ld},clone:function(){return lm},copy:function(){return bm},create:function(){return Mf},determinant:function(){return Qp},equals:function(){return qa},exactEquals:function(){return es},frob:function(){return vo},fromQuat:function(){return Dt},fromQuat2:function(){return M},fromRotation:function(){return oe},fromRotationTranslation:function(){return g},fromRotationTranslationScale:function(){return ze},fromRotationTranslationScaleOrigin:function(){return lt},fromScaling:function(){return _p},fromTranslation:function(){return Ed},fromValues:function(){return xm},fromXRotation:function(){return o},fromYRotation:function(){return s},fromZRotation:function(){return l},frustum:function(){return $t},getRotation:function(){return ve},getScaling:function(){return J},getTranslation:function(){return j},identity:function(){return Om},invert:function(){return N0},lookAt:function(){return Tn},mul:function(){return Ts},multiply:function(){return Gh},multiplyScalar:function(){return ys},multiplyScalarAndAdd:function(){return Yo},ortho:function(){return Gr},orthoNO:function(){return Xr},orthoZO:function(){return Br},perspective:function(){return wr},perspectiveFromFieldOfView:function(){return $r},perspectiveNO:function(){return lr},perspectiveZO:function(){return Vr},rotate:function(){return em},rotateX:function(){return Bd},rotateY:function(){return Qd},rotateZ:function(){return Jd},scale:function(){return Md},set:function(){return Rp},str:function(){return yi},sub:function(){return is},subtract:function(){return Xo},targetTo:function(){return Hn},translate:function(){return wd},transpose:function(){return qd}});var p={};A.r(p),A.d(p,{add:function(){return HP},angle:function(){return Zx},bezier:function(){return tI},ceil:function(){return GP},clone:function(){return jP},copy:function(){return VP},create:function(){return vy},cross:function(){return hb},dist:function(){return pI},distance:function(){return XE},div:function(){return dI},divide:function(){return WE},dot:function(){return QE},equals:function(){return fI},exactEquals:function(){return cI},floor:function(){return WP},forEach:function(){return yI},fromValues:function(){return Zd},hermite:function(){return eI},inverse:function(){return QP},len:function(){return vI},length:function(){return HE},lerp:function(){return JP},max:function(){return YP},min:function(){return XP},mul:function(){return hI},multiply:function(){return Nx},negate:function(){return qE},normalize:function(){return gy},random:function(){return rI},rotateX:function(){return oI},rotateY:function(){return aI},rotateZ:function(){return sI},round:function(){return KP},scale:function(){return zx},scaleAndAdd:function(){return qP},set:function(){return $P},sqrDist:function(){return mI},sqrLen:function(){return gI},squaredDistance:function(){return YE},squaredLength:function(){return KE},str:function(){return lI},sub:function(){return Ux},subtract:function(){return GE},transformMat3:function(){return nI},transformMat4:function(){return Ky},transformQuat:function(){return iI},zero:function(){return uI}});var $={},X={},se=function(i){return X[i]},ae=function(i,r){X[i]=r},ce=function(i){return $[i]},le=function(i,r){$[i]=r},De={},we={},Ee=34,qe=10,Ge=13;function ct(e){return new Function("d","return {"+e.map(function(i,r){return JSON.stringify(i)+": d["+r+'] || ""'}).join(",")+"}")}function Ve(e,i){var r=ct(e);return function(n,t){return i(r(n),t,e)}}function ut(e){var i=Object.create(null),r=[];return e.forEach(function(n){for(var t in n)t in i||r.push(i[t]=t)}),r}function Xe(e,i){var r=e+"",n=r.length;return n9999?"+"+Xe(e,6):Xe(e,4)}function gt(e){var i=e.getUTCHours(),r=e.getUTCMinutes(),n=e.getUTCSeconds(),t=e.getUTCMilliseconds();return isNaN(e)?"Invalid Date":Rt(e.getUTCFullYear(),4)+"-"+Xe(e.getUTCMonth()+1,2)+"-"+Xe(e.getUTCDate(),2)+(t?"T"+Xe(i,2)+":"+Xe(r,2)+":"+Xe(n,2)+"."+Xe(t,3)+"Z":n?"T"+Xe(i,2)+":"+Xe(r,2)+":"+Xe(n,2)+"Z":r||i?"T"+Xe(i,2)+":"+Xe(r,2)+"Z":"")}function Ct(e){var i=new RegExp('["'+e+` +\r]`),r=e.charCodeAt(0);function n(re,xe){var ke,rt,vt=t(re,function(It,er){if(ke)return ke(It,er-1);rt=It,ke=xe?Ve(It,xe):ct(It)});return vt.columns=rt||[],vt}function t(re,xe){var ke=[],rt=re.length,vt=0,It=0,er,Ar=rt<=0,Or=!1;re.charCodeAt(rt-1)===qe&&--rt,re.charCodeAt(rt-1)===Ge&&--rt;function rn(){if(Ar)return we;if(Or)return Or=!1,De;var wn,Cn=vt,qn;if(re.charCodeAt(Cn)===Ee){for(;vt++=rt?Ar=!0:(qn=re.charCodeAt(vt++))===qe?Or=!0:qn===Ge&&(Or=!0,re.charCodeAt(vt)===qe&&++vt),re.slice(Cn+1,wn-1).replace(/""/g,'"')}for(;vt=200&&r.status<300||r.status===0)&&r.response!==null){var a=r.response;if(e.type==="json")try{a=JSON.parse(r.response)}catch(c){return i(c)}i(null,a,r.getResponseHeader("Cache-Control"),r.getResponseHeader("Expires"),r)}else{var u=new Blob([r.response],{type:r.getResponseHeader("Content-Type")});i(new Qn(r.status,r.statusText,n.toString(),u))}},r.cancel=r.abort,r.send(e.body),r}function ni(e){return new Promise(function(i,r){Ji(e,function(n,t,a,u,c){n?r({err:n,data:null,xhr:c}):i({err:null,data:t,cacheControl:a,expires:u,xhr:c})})})}function Ei(e,i){return Ji(e,i)}var xo=function(i,r){var n=_i(i.url)||Ei;return n((0,Se.Z)((0,Se.Z)({},i),{},{type:"json"}),r)},sn=function(i,r){var n=_i(i.url)||Ei;return n((0,Se.Z)((0,Se.Z)({},i),{},{type:"arrayBuffer"}),r)},li=function(i,r){return Ei((0,Se.Z)((0,Se.Z)({},i),{},{method:"POST"}),r)},En=function(i,r){return Ei((0,Se.Z)((0,Se.Z)({},i),{},{method:"GET"}),r)};function or(e){var i=window.document.createElement("a");return i.href=e,i.protocol===window.document.location.protocol&&i.host===window.document.location.host}var qi="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAC0lEQVQYV2NgAAIAAAUAAarVyFEAAAAASUVORK5CYII=";function Bo(e,i){var r=new window.Image,n=window.URL||window.webkitURL;r.crossOrigin="anonymous",r.onload=function(){i(null,r),n.revokeObjectURL(r.src),r.onload=null,window.requestAnimationFrame(function(){r.src=qi})},r.onerror=function(){return i(new Error("Could not load image. Please make sure to use a supported image type such as PNG or JPEG. Note that SVGs are not supported."))};var t=new Blob([new Uint8Array(e)],{type:"image/png"});r.src=e.byteLength?n.createObjectURL(t):qi}function Mo(e,i){var r=new Blob([new Uint8Array(e)],{type:"image/png"});createImageBitmap(r).then(function(n){i(null,n)}).catch(function(n){i(new Error("Could not load image because of ".concat(n.message,". Please make sure to use a supported image type such as PNG or JPEG. Note that SVGs are not supported.")))})}var Wi=function(i,r,n){var t=function(u,c){if(u)r(u);else if(c){var m=typeof createImageBitmap=="function",E=n?n(c):c;m?Mo(E,r):Bo(E,r)}};return i.type==="json"?xo(i,t):sn(i,t)},Ii=function(i,r){var n=typeof createImageBitmap=="function";n?Mo(i,r):Bo(i,r)},ko=function(e){return e.CENTER="center",e.TOP="top",e["TOP-LEFT"]="top-left",e["TOP-RIGHT"]="top-right",e.BOTTOM="bottom",e["BOTTOM-LEFT"]="bottom-left",e["BOTTOM-RIGHT"]="bottom-right",e.LEFT="left",e.RIGHT="right",e}({}),Fn={center:"translate(-50%,-50%)",top:"translate(-50%,0)","top-left":"translate(0,0)","top-right":"translate(-100%,0)",bottom:"translate(-50%,-100%)","bottom-left":"translate(0,-100%)","bottom-right":"translate(-100%,-100%)",left:"translate(0,-50%)",right:"translate(-100%,-50%)"};function zn(e,i,r){var n=e.classList;for(var t in Fn)Fn.hasOwnProperty(t)&&n.remove("l7-".concat(r,"-anchor-").concat(t));n.add("l7-".concat(r,"-anchor-").concat(i))}function Un(e,i,r){e.prototype=i.prototype=r,r.constructor=e}function Hi(e,i){var r=Object.create(e.prototype);for(var n in i)r[n]=i[n];return r}function Ki(){}var Fo=.7,xt=1/Fo,it="\\s*([+-]?\\d+)\\s*",kt="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",ir="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Pr=/^#([0-9a-f]{3,8})$/,kr=new RegExp("^rgb\\("+[it,it,it]+"\\)$"),An=new RegExp("^rgb\\("+[ir,ir,ir]+"\\)$"),Dn=new RegExp("^rgba\\("+[it,it,it,kt]+"\\)$"),Ht=new RegExp("^rgba\\("+[ir,ir,ir,kt]+"\\)$"),Lt=new RegExp("^hsl\\("+[kt,ir,ir]+"\\)$"),je=new RegExp("^hsla\\("+[kt,ir,ir,kt]+"\\)$"),$e={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Un(Ki,ar,{copy:function(e){return Object.assign(new this.constructor,this,e)},displayable:function(){return this.rgb().displayable()},hex:At,formatHex:At,formatHsl:Bt,formatRgb:Jt,toString:Jt});function At(){return this.rgb().formatHex()}function Bt(){return Wn(this).formatHsl()}function Jt(){return this.rgb().formatRgb()}function ar(e){var i,r;return e=(e+"").trim().toLowerCase(),(i=Pr.exec(e))?(r=i[1].length,i=parseInt(i[1],16),r===6?hr(i):r===3?new bn(i>>8&15|i>>4&240,i>>4&15|i&240,(i&15)<<4|i&15,1):r===8?Gt(i>>24&255,i>>16&255,i>>8&255,(i&255)/255):r===4?Gt(i>>12&15|i>>8&240,i>>8&15|i>>4&240,i>>4&15|i&240,((i&15)<<4|i&15)/255):null):(i=kr.exec(e))?new bn(i[1],i[2],i[3],1):(i=An.exec(e))?new bn(i[1]*255/100,i[2]*255/100,i[3]*255/100,1):(i=Dn.exec(e))?Gt(i[1],i[2],i[3],i[4]):(i=Ht.exec(e))?Gt(i[1]*255/100,i[2]*255/100,i[3]*255/100,i[4]):(i=Lt.exec(e))?ri(i[1],i[2]/100,i[3]/100,1):(i=je.exec(e))?ri(i[1],i[2]/100,i[3]/100,i[4]):$e.hasOwnProperty(e)?hr($e[e]):e==="transparent"?new bn(NaN,NaN,NaN,0):null}function hr(e){return new bn(e>>16&255,e>>8&255,e&255,1)}function Gt(e,i,r,n){return n<=0&&(e=i=r=NaN),new bn(e,i,r,n)}function Tr(e){return e instanceof Ki||(e=ar(e)),e?(e=e.rgb(),new bn(e.r,e.g,e.b,e.opacity)):new bn}function nn(e,i,r,n){return arguments.length===1?Tr(e):new bn(e,i,r,n==null?1:n)}function bn(e,i,r,n){this.r=+e,this.g=+i,this.b=+r,this.opacity=+n}Un(bn,nn,Hi(Ki,{brighter:function(e){return e=e==null?xt:Math.pow(xt,e),new bn(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=e==null?Fo:Math.pow(Fo,e),new bn(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Bi,formatHex:Bi,formatRgb:on,toString:on}));function Bi(){return"#"+dn(this.r)+dn(this.g)+dn(this.b)}function on(){var e=this.opacity;return e=isNaN(e)?1:Math.max(0,Math.min(1,e)),(e===1?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(e===1?")":", "+e+")")}function dn(e){return e=Math.max(0,Math.min(255,Math.round(e)||0)),(e<16?"0":"")+e.toString(16)}function ri(e,i,r,n){return n<=0?e=i=r=NaN:r<=0||r>=1?e=i=NaN:i<=0&&(e=NaN),new di(e,i,r,n)}function Wn(e){if(e instanceof di)return new di(e.h,e.s,e.l,e.opacity);if(e instanceof Ki||(e=ar(e)),!e)return new di;if(e instanceof di)return e;e=e.rgb();var i=e.r/255,r=e.g/255,n=e.b/255,t=Math.min(i,r,n),a=Math.max(i,r,n),u=NaN,c=a-t,m=(a+t)/2;return c?(i===a?u=(r-n)/c+(r0&&m<1?0:u,new di(u,c,m,e.opacity)}function Rn(e,i,r,n){return arguments.length===1?Wn(e):new di(e,i,r,n==null?1:n)}function di(e,i,r,n){this.h=+e,this.s=+i,this.l=+r,this.opacity=+n}Un(di,Rn,Hi(Ki,{brighter:function(e){return e=e==null?xt:Math.pow(xt,e),new di(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=e==null?Fo:Math.pow(Fo,e),new di(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+(this.h<0)*360,i=isNaN(e)||isNaN(this.s)?0:this.s,r=this.l,n=r+(r<.5?r:1-r)*i,t=2*r-n;return new bn(zi(e>=240?e-240:e+120,t,n),zi(e,t,n),zi(e<120?e+240:e-120,t,n),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var e=this.opacity;return e=isNaN(e)?1:Math.max(0,Math.min(1,e)),(e===1?"hsl(":"hsla(")+(this.h||0)+", "+(this.s||0)*100+"%, "+(this.l||0)*100+"%"+(e===1?")":", "+e+")")}}));function zi(e,i,r){return(e<60?i+(r-i)*e/60:e<180?r:e<240?i+(r-i)*(240-e)/60:i)*255}function Gi(e){return typeof e=="string"?!!ar(e):!1}function Lo(e){var i=ar(e),r=[0,0,0,0];return i!=null&&(r[0]=i.r/255,r[1]=i.g/255,r[2]=i.b/255,r[3]=i.opacity),r}function eo(e){var i=e&&e[0],r=e&&e[1],n=e&&e[2],t=i+r*256+n*65536-1;return t}function ba(e){return[e+1&255,e+1>>8&255,e+1>>8>>8&255]}function va(e){var i=window.document.createElement("canvas"),r=i.getContext("2d");i.width=256,i.height=1;for(var n=null,t=r.createLinearGradient(0,0,256,1),a=e.positions[0],u=e.positions[e.positions.length-1],c=0;c0&&new RegExp("(^|\\s)"+i+"(\\s|$)").test(r)}function en(e,i){e instanceof HTMLElement?e.className=i:e.className.baseVal=i}function xn(e,i,r){r===void 0?Of(e,i)?Hu(e,i):Js(e,i):r?Js(e,i):Hu(e,i)}function Vi(e){return e instanceof SVGElement&&(e=e.correspondingElement),e.className.baseVal===void 0?e.className:e.className.baseVal}function wi(e){for(;e&&e.firstChild;)e.removeChild(e.firstChild)}var oo=ns(["transform","WebkitTransform"]);function io(e,i){e.style[oo]=i}function Uo(){if(typeof Event=="function")window.dispatchEvent(new Event("resize"));else{var e=window.document.createEvent("UIEvents");e.initUIEvent("resize",!0,!1,window,0),window.dispatchEvent(e)}}function na(e){var i=["padding: "+(e.height/2-8)+"px "+e.width/2+"px;","line-height: "+e.height+"px;","background-image: url("+e.toDataURL()+");"];console.log(`%c +`,i.join(""))}function $a(){var e,i=window.document.querySelector('meta[name="viewport"]');if(!i)return 1;var r=(e=i.content)===null||e===void 0?void 0:e.split(","),n=r.find(function(t){var a=t.split("="),u=(0,gi.Z)(a,1),c=u[0];return c==="initial-scale"});return n?n.split("=")[1]*1:1}var Co=$a()<1?1:window.devicePixelRatio;function wo(e,i){e.setAttribute("style","".concat(e.style.cssText).concat(i))}function Pa(e){return e.split(";").map(function(i){return i.trim()}).filter(function(i){return i})}function ss(e,i){var r,n=Pa((r=e.getAttribute("style"))!==null&&r!==void 0?r:""),t=Pa(i),a=No.apply(void 0,[n].concat((0,On.Z)(t)));e.setAttribute("style",a.join(";"))}function si(e){return Object.entries(e).map(function(i){var r=(0,gi.Z)(i,2),n=r[0],t=r[1];return"".concat(n,": ").concat(t)}).join(";")}function Ms(e,i){return{left:e.left-i.left,top:e.top-i.top,right:i.left+i.width-e.left-e.width,bottom:i.top+i.height-e.top-e.height}}function Ns(e,i){e.checked=i,i?e.setAttribute("checked","true"):e.removeAttribute("checked")}function Aa(e){e.innerHTML=""}function qs(e){e.setAttribute("draggable","false")}function Eu(e,i){if(typeof i=="string"){var r=document.createElement("div");for(r.innerHTML=i;r.firstChild;)e.append(r.firstChild)}else Array.isArray(i)?e.append.apply(e,(0,On.Z)(i)):e.append(i)}function Cs(e,i){for(var r=Array.isArray(i)?i:[i],n=e;n instanceof Element&&n!==window.document.body;){var t,a;if(r.find(function(u){var c;return(c=n)===null||c===void 0?void 0:c.matches(u)}))return n;n=(t=(a=n)===null||a===void 0?void 0:a.parentElement)!==null&&t!==void 0?t:null}}var su;function Vs(e){return typeof ImageBitmap!="undefined"&&e instanceof ImageBitmap}function tl(){return typeof importScripts=="function"}var Xs=tl()?function(){return self.worker&&self.worker.referrer}:function(){return(window.location.protocol==="blob:"?window.parent:window).location.href},rc=(su=navigator)===null||su===void 0?void 0:su.userAgent,Ha=!!rc.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/),Qs=rc.indexOf("Android")>-1||rc.indexOf("Adr")>-1;function Uu(){for(var e=rc,i=["Android","iPhone","SymbianOS","Windows Phone","iPad","iPod"],r=!0,n=0,t=i;n0){r=!1;break}}return r}var St=A(16514);function Zs(e,i){e.forEach(function(r){i[r]&&(i[r]=i[r].bind(i))})}var yu=function(){function e(){var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:16;(0,We.Z)(this,e),(0,St.Z)(this,"duration",16),(0,St.Z)(this,"timestamp",new Date().getTime()),this.duration=i}return(0,ot.Z)(e,[{key:"run",value:function(r){var n=new Date().getTime(),t=n-this.timestamp;this.timestamp=n,t>=this.duration&&r()}}]),e}(),pl=A(86461),Ku=A(8822);function eu(e){return typeof e=="number"}var Qo=2*Math.PI*6378137/2;function ps(e,i){var r=(0,gi.Z)(i,4),n=r[0],t=r[1],a=r[2],u=r[3];return e.lng>n&&e.lng<=a&&e.lat>t&&e.lat<=u}function xl(e){var i=[1/0,1/0,-1/0,-1/0];return e.forEach(function(r){var n=r.coordinates;Yl(i,n)}),i}function Yl(e,i){return Array.isArray(i[0])?i.forEach(function(r){Yl(e,r)}):(e[0]>i[0]&&(e[0]=i[0]),e[1]>i[1]&&(e[1]=i[1]),e[2]1&&arguments[1]!==void 0?arguments[1]:!0,r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{enable:!0,decimal:1};e=Fc(e,i);var n=e[0],t=e[1],a=n*Qo/180,u=Math.log(Math.tan((90+t)*Math.PI/360))/(Math.PI/180);return u=u*Qo/180,r.enable&&(a=Number(a.toFixed(r.decimal)),u=Number(u.toFixed(r.decimal))),e.length===3?[a,u,e[2]]:[a,u]}function Hf(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,r=e[0],n=e[1],t=r/Qo*180,a=n/Qo*180;return a=180/Math.PI*(2*Math.atan(Math.exp(a*Math.PI/180))-Math.PI/2),i!=null&&(t=Number(t.toFixed(i)),a=Number(a.toFixed(i))),e.length===3?[t,a,e[2]]:[t,a]}function Ul(e){if(e==null)throw new Error("lng is required");return(e>180||e<-180)&&(e=e%360,e>180&&(e=-360+e),e<-180&&(e=360+e),e===0&&(e=0)),e}function Lf(e){if(e==null)throw new Error("lat is required");return(e>90||e<-90)&&(e=e%180,e>90&&(e=-180+e),e<-90&&(e=180+e),e===0&&(e=0)),e}function Fc(e,i){if(i===!1)return e;var r=Ul(e[0]),n=Lf(e[1]);return n>85&&(n=85),n<-85&&(n=-85),e.length===3?[r,n,e[2]]:[r,n]}function Ol(e){var i=85.0511287798,r=Math.max(Math.min(i,e[1]),-i),n=256<<20,t=Math.PI/180,a=e[0]*t,u=r*t;u=Math.log(Math.tan(Math.PI/4+u/2));var c=.5/Math.PI,m=.5,E=-.5/Math.PI;return t=.5,a=n*(c*a+m),u=n*(E*u+t),[Math.floor(a),Math.floor(u)]}function _l(e){var i=.5/Math.PI,r=.5,n=-.5/Math.PI,t=.5,a=256<<20,u=(0,gi.Z)(e,2),c=u[0],m=u[1];c=(c/a-r)/i,m=(m/a-t)/n,m=(Math.atan(Math.pow(Math.E,m))-Math.PI/4)*2,t=Math.PI/180;var E=m/t,H=c/t;return[H,E]}function cn(e,i){var r=85.0511287798,n=Math.PI/180,t=6378137;return i=Math.max(Math.min(r,i),-r),e*=n,i*=n,i=Math.log(Math.tan(Math.PI/4+i/2)),[e*t,i*t]}function an(e,i){var r=Math.PI/180,n=6378137,t=e/n/r,a=2*(Math.atan(Math.exp(i/n))-Math.PI/4)/r;return[t,a]}function Xn(e,i,r){var n=(0,Ku.Ht)(i[1]-e[1]),t=(0,Ku.Ht)(i[0]-e[0]),a=(0,Ku.Ht)(e[1]),u=(0,Ku.Ht)(i[1]),c=Math.pow(Math.sin(n/2),2)+Math.pow(Math.sin(t/2),2)*Math.cos(a)*Math.cos(u);return(0,Ku.DL)(2*Math.atan2(Math.sqrt(c),Math.sqrt(1-c)),r="meters")}function vi(e){var i=Math.PI/180,r=85.0511287798,n=6378137,t=Math.max(Math.min(r,e[1]),-r),a=Math.sin(t*i),u=n*e[0]*i,c=n*Math.log((1+a)/(1-a))/2;return[u,c]}function to(e,i){var r=Math.abs(e[1][1]-e[0][1])*i,n=Math.abs(e[1][0]-e[0][0])*i;return[[e[0][0]-n,e[0][1]-r],[e[1][0]+n,e[1][1]+r]]}function zo(e,i){return e[0][0]<=i[0][0]&&e[0][1]<=i[0][1]&&e[1][0]>=i[1][0]&&e[1][1]>=i[1][1]}function Ia(e){return[[e[0],e[1]],[e[2],e[3]]]}function Sa(e){var i=fa(e,[0,0]);return[e[0]/i,e[1]/i]}function fa(e,i){return Math.sqrt(Math.pow(e[0]-i[0],2)+Math.pow(e[1]-i[1],2))}function cs(e,i){return e[0]*i[0]+e[1]*i[1]}function Ys(e){return Math.sqrt(e[0]*e[0]+e[1]*e[1])}function mu(e,i){return Math.acos(cs(e,i)/(Ys(e)*Ys(i)))*180/Math.PI}function Is(e,i){return i[0]>0?i[1]>0?90-Math.atan(i[1]/i[0])*180/Math.PI:90+Math.atan(-i[1]/i[0])*180/Math.PI:i[1]<0?180+(90-Math.atan(i[1]/i[0])*180/Math.PI):270+Math.atan(i[1]/-i[0])*180/Math.PI}function Sl(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:100;if(!(!e||e.length<2)){for(var r=[0,1],n=0,t=[],a=0;a0){var re=t[a-1].rotation;re-H>360-re+H&&(H=H+360)}t.push({start:u,end:c,dis:m,rotation:H,duration:0})}return t.map(function(xe){xe.duration=i*(xe.dis/n)}),t}}function wl(e){if(eu(e[0]))return e;if(eu(e[0][0]))throw new Error("\u5F53\u524D\u6570\u636E\u4E0D\u652F\u6301\u6807\u6CE8");if(eu(e[0][0][0])){var i=e,r=0,n=0,t=0;return i.forEach(function(a){a.forEach(function(u){r+=u[0],n+=u[1],t++})}),[r/t,n/t,0]}else throw new Error("\u5F53\u524D\u6570\u636E\u4E0D\u652F\u6301\u6807\u6CE8")}function vu(e){for(var i=e[0],r=e[1],n=e[0],t=e[1],a=0,u=0,c=0,m=0;mt&&(n=Math.floor(n/r)),n=n*i+e.charCodeAt(a);return n}function Fu(e){e=e.toString();for(var i=5381,r=e.length;r;)i=i*33^e.charCodeAt(--r);return i>>>0}function Bu(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){var i=Math.random()*16|0,r=e==="x"?i:i&3|8;return r.toString(16)})}var al=function(e){return e["GAODE1.x"]="GAODE1.x",e["GAODE2.x"]="GAODE2.x",e.MAPBOX="MAPBOX",e.DEFAULT="DEFAUlTMAP",e.SIMPLE="SIMPLE",e.GLOBEL="GLOBEL",e}({});function Ac(e,i,r,n,t){var a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:30,u=arguments.length>6?arguments[6]:void 0,c=r;return u&&(c=Math.round(r*(a-1))/(a-1)),n?Sf(e,i,c,n,t):Sf(e,i,c,.314,t)}function $l(e,i){var r=1-i;return(e[0]*r+e[1]*i)*r+(e[1]*r+e[2]*i)*i}function Yu(e,i){return Math.sqrt(Math.pow(e[0]-i[0],2)+Math.pow(e[1]-i[1],2))}function Gu(e,i,r){var n=[i[0]-e[0],i[1]-e[1]],t=Yu(n,[0,0]),a=Math.atan2(n[1],n[0]),u=t/2/Math.cos(r),c=a+r,m=[u*Math.cos(c)+e[0],u*Math.sin(c)+e[1]];return m}function Sf(e,i,r,n,t){if(t===al["GAODE2.x"]){var a=cn(e[0],e[1]),u=cn(i[0],i[1]),c=Gu(a,u,n),m=[a[0],c[0],u[0]],E=[a[1],c[1],u[1]];return[].concat((0,On.Z)(an($l(m,r),$l(E,r))),[0])}else{var H=Gu(e,i,n),re=[e[0],H[0],i[0]],xe=[e[1],H[1],i[1]];return[$l(re,r),$l(xe,r),0]}}function Cl(e,i,r,n,t){var a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:30,u=arguments.length>6?arguments[6]:void 0,c=r;return u&&(c=Math.round(r*29)/29),af(e,i,c,t)}function Df(e,i){var r=[i[0]-e[0],i[1]-e[1]],n=fa(r,[0,0]),t=Math.atan2(r[1],r[0]),a=.314,u=n/2/Math.cos(a),c=t+a,m=[u*Math.cos(c)+e[0],u*Math.sin(c)+e[1]];return m}function bu(e,i){var r=1-i;return(e[0]*r+e[1]*i)*r+(e[1]*r+e[2]*i)*i}function Ic(e,i){var r=[e[0]-i[0],e[1]-i[1]],n=[Math.sin(r[0]/2),Math.sin(r[1]/2)],t=n[1]*n[1]+Math.cos(e[1])*Math.cos(i[1])*n[0]*n[0];return 2*Math.atan2(Math.sqrt(t),Math.sqrt(1-t))}function af(e,i,r,n){var t=[(0,Ku.Ht)(e[0]),(0,Ku.Ht)(e[1])],a=[(0,Ku.Ht)(i[0]),(0,Ku.Ht)(i[1])];if(n==="GAODE2.x"){var u=Df(t,a),c=[t[0],u[0],a[0]],m=[t[1],u[1],a[1]];return[bu(c,r),bu(m,r),0]}else{var E=Ic(t,a);if(Math.abs(E-Math.PI)<.001)return[(1-r)*t[0]+r*a[0],(1-r)*t[1]+r*a[1]];var H=Math.sin((1-r)*E)/Math.sin(E),re=Math.sin(r*E)/Math.sin(E),xe=[Math.sin(t[0]),Math.sin(t[1])],ke=[Math.cos(t[0]),Math.cos(t[1])],rt=[Math.sin(a[0]),Math.sin(a[1])],vt=[Math.cos(a[0]),Math.cos(a[1])],It=H*ke[1]*ke[0]+re*vt[1]*vt[0],er=H*ke[1]*xe[0]+re*vt[1]*rt[0],Ar=H*xe[1]+re*rt[1];return[(0,Ku.vi)(Math.atan2(er,It)),(0,Ku.vi)(Math.atan2(Ar,Math.sqrt(It*It+er*er)))]}}function zf(e,i){for(var r=0,n=[],t=0;tE){var It=rt.p1,er=rt.p2,Ar=(E-rt.lastTotalDistance)/rt.distance,Or=tf(er,It,Ar);H=Or[0],re=Or[1];break}}return{lng:H,lat:re,height:0}}function tf(e,i,r){return[e[0]*r+i[0]*(1-r),e[1]*r+i[1]*(1-r)]}function kf(e,i){return Math.sqrt(Math.pow(e[0]-i[0],2)+Math.pow(e[1]-i[1],2))}function ff(e,i){var r=i.featureId,n=e.data.dataArray;return typeof r=="number"&&(n=n.filter(function(t){var a=t.id;return a===r})),n.map(function(t){var a=wc(t,i);return(0,Se.Z)((0,Se.Z)({},t),a)})}function vf(e,i){return new Promise(function(r){e.inited?r(ff(e,i)):e.once("update",function(){r(ff(e,i))})})}function wc(e,i){var r=i.offset,n=i.shape,t=i.thetaOffset,a=i.mapVersion,u=i.segmentNumber,c=u===void 0?30:u,m=i.autoFit,E=m===void 0?!0:m,H=e.coordinates;if(n==="line")return zf(H,r);var re=H[0],xe=H[1],ke=typeof t=="string"?e[t]||0:t,rt;switch(n){case"arc":rt=Ac;break;case"greatcircle":rt=Cl;break;default:rt=Ac}var vt=rt(re,xe,r,ke,a,c,E),It=(0,gi.Z)(vt,3),er=It[0],Ar=It[1],Or=It[2];return{lng:er,lat:Ar,height:Or}}var ac=function(){function e(){var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:50,r=arguments.length>1?arguments[1]:void 0;(0,We.Z)(this,e),this.limit=i,this.destroy=r||this.defaultDestroy,this.order=[],this.clear()}return(0,ot.Z)(e,[{key:"clear",value:function(){var r=this;this.order.forEach(function(n){r.delete(n)}),this.cache={},this.order=[]}},{key:"get",value:function(r){var n=this.cache[r];return n&&(this.deleteOrder(r),this.appendOrder(r)),n}},{key:"set",value:function(r,n){this.cache[r]?(this.delete(r),this.cache[r]=n,this.appendOrder(r)):(Object.keys(this.cache).length===this.limit&&this.delete(this.order[0]),this.cache[r]=n,this.appendOrder(r))}},{key:"delete",value:function(r){var n=this.cache[r];n&&(this.deleteCache(r),this.deleteOrder(r),this.destroy(n,r))}},{key:"deleteCache",value:function(r){delete this.cache[r]}},{key:"deleteOrder",value:function(r){var n=this.order.findIndex(function(t){return t===r});n>=0&&this.order.splice(n,1)}},{key:"appendOrder",value:function(r){this.order.push(r)}},{key:"defaultDestroy",value:function(r,n){return null}}]),e}();function cl(e){if(e.length===0)throw new Error("max requires at least one data point");for(var i=e[0],r=1;ri&&(i=e[r]);return i*1}function Us(e){if(e.length===0)throw new Error("min requires at least one data point");for(var i=e[0],r=1;rn&&(n=t,r=i),t=1,i=e[a]):t++;return r*1}var xa={min:Us,max:cl,mean:iu,sum:vl,mode:Ca};function Dl(e,i){return e.map(function(r){return r[i]})}function Gf(e,i){return xa[e](i)}var Li=A(90304),Fr=A(7963),Hl=A(57168),Ur=A.n(Hl),ja=A(39511),cu=A(40666),fu=A.n(cu),nc=function(e){return e.Realtime="realtime",e.Overlap="overlap",e.Replace="replace",e}({}),Su=function(e){return e.Loading="Loading",e.Loaded="Loaded",e.Failure="Failure",e.Cancelled="Cancelled",e}({}),Wu=0,Hc=1,Lc=2;function Kl(e){e.forEach(function(i){i.isCurrent&&(i.isVisible=i.isLoaded)})}function Ec(e){e.forEach(function(i){i.properties.state=Wu}),e.forEach(function(i){i.isCurrent&&!kl(i)&&Wc(i)}),e.forEach(function(i){i.isVisible=!!(i.properties.state&Lc)})}function bl(e){e.forEach(function(r){r.properties.state=Wu}),e.forEach(function(r){r.isCurrent&&kl(r)});var i=e.slice().sort(function(r,n){return r.z-n.z});i.forEach(function(r){r.isVisible=!!(r.properties.state&Lc),r.children.length&&(r.isVisible||r.properties.state&Hc)?r.children.forEach(function(n){n.properties.state=Hc}):r.isCurrent&&Wc(r)})}function kl(e){for(;e;){if(e.isLoaded)return e.properties.state|=Lc,!0;e=e.parent}return!1}function Wc(e){e.children.forEach(function(i){i.isLoaded?i.properties.state|=Lc:Wc(i)})}var Tl,ql=256,ic=[-1/0,-1/0,1/0,1/0],Ls=.2,cc=5,gu=(Tl={},(0,St.Z)(Tl,nc.Realtime,Kl),(0,St.Z)(Tl,nc.Overlap,Ec),(0,St.Z)(Tl,nc.Replace,bl),Tl),Cu=function(){};function Qc(e,i,r){var n=Math.floor((e+180)/360*Math.pow(2,r)),t=Math.floor((1-Math.log(Math.tan(i*Math.PI/180)+1/Math.cos(i*Math.PI/180))/Math.PI)/2*Math.pow(2,r));return[n,t]}function hf(e,i,r){var n=e/Math.pow(2,r)*360-180,t=Math.PI-2*Math.PI*i/Math.pow(2,r),a=180/Math.PI*Math.atan(.5*(Math.exp(t)-Math.exp(-t)));return[n,a]}var Xc=function(i,r,n){var t=hf(i,r,n),a=(0,gi.Z)(t,2),u=a[0],c=a[1],m=hf(i+1,r+1,n),E=(0,gi.Z)(m,2),H=E[0],re=E[1];return[u,re,H,c]};function Al(e){var i=e.zoom,r=e.latLonBounds,n=e.maxZoom,t=n===void 0?1/0:n,a=e.minZoom,u=a===void 0?0:a,c=e.zoomOffset,m=c===void 0?0:c,E=e.extent,H=E===void 0?ic:E,re=Math.ceil(i)+m;if(Number.isFinite(u)&&ret&&(re=t);for(var xe=(0,gi.Z)(r,4),ke=xe[0],rt=xe[1],vt=xe[2],It=xe[3],er=[Math.max(ke,H[0]),Math.max(rt,H[1]),Math.min(vt,H[2]),Math.min(It,H[3])],Ar=[],Or=Qc(er[0],er[1],re),rn=(0,gi.Z)(Or,2),Ln=rn[0],wn=rn[1],Cn=Qc(er[2],er[3],re),qn=(0,gi.Z)(Cn,2),Si=qn[0],po=qn[1],Ao=Ln;Ao<=Si;Ao++)for(var ma=po;ma<=wn;ma++)Ar.push({x:Ao,y:ma,z:re});var Ya=(Si+Ln)/2,fs=(wn+po)/2,bf=function(Yh,Lp){return Math.abs(Yh-Ya)+Math.abs(Lp-fs)};return Ar.sort(function(th,Yh){return bf(th.x,th.y)-bf(Yh.x,Yh.y)}),Ar}var Sc=function(i,r,n){var t=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,a=Math.pow(2,n),u=a-1,c=a,m=i,E=r;return t&&(m<0?m=m+c:m>u&&(m=m%c)),{warpX:m,warpY:E}};function Ka(e){var i=ea();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function ea(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var qo=function(e){(0,Me.Z)(r,e);var i=Ka(r);function r(n){var t;(0,We.Z)(this,r),t=i.call(this),(0,St.Z)((0,Fr.Z)(t),"tileSize",256),(0,St.Z)((0,Fr.Z)(t),"isVisible",!1),(0,St.Z)((0,Fr.Z)(t),"isCurrent",!1),(0,St.Z)((0,Fr.Z)(t),"isVisibleChange",!1),(0,St.Z)((0,Fr.Z)(t),"loadedLayers",0),(0,St.Z)((0,Fr.Z)(t),"isLayerLoaded",!1),(0,St.Z)((0,Fr.Z)(t),"isLoad",!1),(0,St.Z)((0,Fr.Z)(t),"isChildLoad",!1),(0,St.Z)((0,Fr.Z)(t),"parent",null),(0,St.Z)((0,Fr.Z)(t),"children",[]),(0,St.Z)((0,Fr.Z)(t),"data",null),(0,St.Z)((0,Fr.Z)(t),"properties",{}),(0,St.Z)((0,Fr.Z)(t),"loadDataId",0);var a=n.x,u=n.y,c=n.z,m=n.tileSize,E=n.warp,H=E===void 0?!0:E;return t.x=a,t.y=u,t.z=c,t.warp=H||!0,t.tileSize=m,t}return(0,ot.Z)(r,[{key:"isLoading",get:function(){return this.loadStatus===Su.Loading}},{key:"isLoaded",get:function(){return this.loadStatus===Su.Loaded}},{key:"isFailure",get:function(){return this.loadStatus===Su.Failure}},{key:"setTileLayerLoaded",value:function(){this.isLayerLoaded=!0}},{key:"isCancelled",get:function(){return this.loadStatus===Su.Cancelled}},{key:"isDone",get:function(){return[Su.Loaded,Su.Cancelled,Su.Failure].includes(this.loadStatus)}},{key:"bounds",get:function(){return Xc(this.x,this.y,this.z)}},{key:"bboxPolygon",get:function(){var t=(0,gi.Z)(this.bounds,4),a=t[0],u=t[1],c=t[2],m=t[3],E=[(c-a)/2,(m-u)/2],H=(0,ja.Z)(this.bounds,{properties:{key:this.key,id:this.key,bbox:this.bounds,center:E,meta:` + `.concat(this.key,` + `)}});return H}},{key:"key",get:function(){var t="".concat(this.x,"_").concat(this.y,"_").concat(this.z);return t}},{key:"layerLoad",value:function(){this.loadedLayers++,this.emit("layerLoaded")}},{key:"loadData",value:function(){var n=(0,Li.Z)(Ur().mark(function a(u){var c,m,E,H,re,xe,ke,rt,vt,It,er,Ar,Or,rn,Ln,wn,Cn;return Ur().wrap(function(Si){for(;;)switch(Si.prev=Si.next){case 0:return c=u.getData,m=u.onLoad,E=u.onError,this.loadDataId++,H=this.loadDataId,this.isLoading&&this.abortLoad(),this.abortController=new AbortController,this.loadStatus=Su.Loading,re=null,Si.prev=7,ke=this.x,rt=this.y,vt=this.z,It=this.bounds,er=this.tileSize,Ar=this.warp,Or=Sc(ke,rt,vt,Ar),rn=Or.warpX,Ln=Or.warpY,wn=this.abortController.signal,Cn={x:rn,y:Ln,z:vt,bounds:It,tileSize:er,signal:wn,warp:Ar},Si.next=14,c(Cn,this);case 14:re=Si.sent,Si.next=20;break;case 17:Si.prev=17,Si.t0=Si.catch(7),xe=Si.t0;case 20:if(H===this.loadDataId){Si.next=22;break}return Si.abrupt("return");case 22:if(!(this.isCancelled&&!re)){Si.next=24;break}return Si.abrupt("return");case 24:if(!(xe||!re)){Si.next=28;break}return this.loadStatus=Su.Failure,E(xe,this),Si.abrupt("return");case 28:this.loadStatus=Su.Loaded,this.data=re,m(this);case 31:case"end":return Si.stop()}},a,this,[[7,17]])}));function t(a){return n.apply(this,arguments)}return t}()},{key:"reloadData",value:function(t){this.isLoading&&this.abortLoad(),this.loadData(t)}},{key:"abortLoad",value:function(){this.isLoaded||this.isCancelled||(this.loadStatus=Su.Cancelled,this.abortController.abort(),this.xhrCancel&&this.xhrCancel())}}]),r}(cu.EventEmitter),tu=function(i,r){var n=Ia(i),t=to(n,r),a=360*3-180,u=85.0511287798065,c=[Math.max(t[0][0],-a),Math.max(t[0][1],-u),Math.min(t[1][0],a),Math.min(t[1][1],u)];return c},bh=function(i,r){var n=Ia(i),t=Ia(r),a=zo(n,t);return a};function pc(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=Wf(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function Wf(e,i){if(e){if(typeof e=="string")return Tu(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Tu(e,i)}}function Tu(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r=0&&re.x0;){var m=t.shift();m.abortLoad()}}},{key:"getTileByLngLat",value:function(t,a,u){var c=this.options.zoomOffset,m=Math.ceil(u)+c,E=Qc(t,a,m),H=this.tiles.filter(function(re){return re.key==="".concat(E[0],"_").concat(E[1],"_").concat(m)});return H[0]}},{key:"getTileExtent",value:function(t,a){return this.getTileIndices(a,t)}},{key:"getTileByZXY",value:function(t,a,u){var c=this.tiles.filter(function(m){return m.key==="".concat(a,"_").concat(u,"_").concat(t)});return c[0]}},{key:"clear",value:function(){var t=pc(this.cacheTiles.values()),a;try{for(t.s();!(a=t.n()).done;){var u=a.value;u.isLoading?u.abortLoad():this.onTileUnload(u)}}catch(c){t.e(c)}finally{t.f()}this.lastViewStates=void 0,this.cacheTiles.clear(),this.currentTiles=[]}},{key:"destroy",value:function(){this.clear(),this.removeAllListeners()}},{key:"updateTileVisible",value:function(){var t=this.options.updateStrategy,a=new Map,u=pc(this.cacheTiles.values()),c;try{for(u.s();!(c=u.n()).done;){var m=c.value;a.set(m.key,m.isVisible),m.isCurrent=!1,m.isVisible=!1}}catch(rt){u.e(rt)}finally{u.f()}var E=pc(this.currentTiles),H;try{for(E.s();!(H=E.n()).done;){var re=H.value;re.isCurrent=!0,re.isVisible=!0}}catch(rt){E.e(rt)}finally{E.f()}var xe=Array.from(this.cacheTiles.values());typeof t=="function"?t(xe):gu[t](xe);var ke=!1;Array.from(this.cacheTiles.values()).forEach(function(rt){rt.isVisible!==a.get(rt.key)?(rt.isVisibleChange=!0,ke=!0):rt.isVisibleChange=!1}),ke&&this.emit(fh.TileUpdate)}},{key:"getTileIndices",value:function(t,a){var u=this.options,c=u.tileSize,m=u.extent,E=u.zoomOffset,H=Math.floor(this.options.maxZoom),re=Math.ceil(this.options.minZoom),xe=Al({maxZoom:H,minZoom:re,zoomOffset:E,tileSize:c,zoom:t,latLonBounds:a,extent:m});return xe}},{key:"getTileId",value:function(t,a,u){var c="".concat(t,",").concat(a,",").concat(u);return c}},{key:"loadFinished",value:function(){var t=!this.currentTiles.some(function(a){return!a.isDone});return t&&this.emit(fh.TilesLoadFinished),t}},{key:"getTile",value:function(t,a,u){var c=this.getTileId(t,a,u),m=this.cacheTiles.get(c);return m}},{key:"createTile",value:function(t,a,u){var c=this.getTileId(t,a,u),m=new qo({x:t,y:a,z:u,tileSize:this.options.tileSize,warp:this.options.warp});return this.cacheTiles.set(c,m),m.loadData({getData:this.options.getTileData,onLoad:this.onTileLoad,onError:this.onTileError}),m}},{key:"resizeCacheTiles",value:function(){var t=cc*this.currentTiles.length,a=this.cacheTiles.size>t;if(a){var u=pc(this.cacheTiles),c;try{for(u.s();!(c=u.n()).done;){var m=(0,gi.Z)(c.value,2),E=m[0],H=m[1];if(!H.isVisible&&!this.currentTiles.includes(H)&&(this.cacheTiles.delete(E),this.onTileUnload(H)),this.cacheTiles.size<=t)break}}catch(re){u.e(re)}finally{u.f()}}this.rebuildTileTree()}},{key:"rebuildTileTree",value:function(){var t=pc(this.cacheTiles.values()),a;try{for(t.s();!(a=t.n()).done;){var u=a.value;u.parent=null,u.children.length=0}}catch(re){t.e(re)}finally{t.f()}var c=pc(this.cacheTiles.values()),m;try{for(c.s();!(m=c.n()).done;){var E=m.value,H=this.getNearestAncestor(E.x,E.y,E.z);E.parent=H,H!=null&&H.children&&H.children.push(E)}}catch(re){c.e(re)}finally{c.f()}}},{key:"getNearestAncestor",value:function(t,a,u){for(;u>this.options.minZoom;){t=Math.floor(t/2),a=Math.floor(a/2),u=u-1;var c=this.getTile(t,a,u);if(c)return c}return null}}]),r}(fu());function Yf(e){return/(?=.*{box})(?=.*{z})(?=.*{x})(?=.*({y}|{-y}))/.test(e)}function rh(e){var i=[],r=/\{([a-z])-([a-z])\}/.exec(e);if(r){var n=r[1].charCodeAt(0),t=r[2].charCodeAt(0),a;for(a=n;a<=t;++a)i.push(e.replace(r[0],String.fromCharCode(a)));return i}if(r=/\{(\d+)-(\d+)\}/.exec(e),r){for(var u=parseInt(r[2],10),c=parseInt(r[1],10);c<=u;c++)i.push(e.replace(r[0],c.toString()));return i}return i.push(e),i}function ud(e,i){if(!e||!e.length)throw new Error("url is not allowed to be empty");var r=i.x,n=i.y,t=i.z,a=rh(e),u=Math.abs(r+n)%a.length,c=_i(a[u])?"".concat(a[u],"/{z}/{x}/{y}"):a[u];return c.replace(/\{x\}/g,r.toString()).replace(/\{y\}/g,n.toString()).replace(/\{z\}/g,t.toString()).replace(/\{bbox\}/g,Xc(r,n,t).join(",")).replace(/\{-y\}/g,(Math.pow(2,t)-n-1).toString())}function fp(e,i){var r=i.x,n=i.y,t=i.z,a=i.layer,u=i.version,c=u===void 0?"1.0.0":u,m=i.style,E=m===void 0?"default":m,H=i.format,re=i.service,xe=re===void 0?"WMTS":re,ke=i.tileMatrixset,rt=rh(e),vt=Math.abs(r+n)%rt.length,It="".concat(rt[vt],"&SERVICE=").concat(xe,"&REQUEST=GetTile&VERSION=").concat(c,"&LAYER=").concat(a,"&STYLE=").concat(E,"&TILEMATRIXSET=").concat(ke,"&FORMAT=").concat(H,"&TILECOL=").concat(r,"&TILEROW=").concat(n,"&TILEMATRIX=").concat(t);return It}function h(e,i){if(!e)throw new Error(i||"web worker helper assertion failed.")}var v={self:typeof self!="undefined"&&self,window:typeof window!="undefined"&&window,document:typeof document!="undefined"&&document},B=v.self||v.window||{},W=v.window||v.self||{},_e=v.self||v.window||{},_t=v.document||{},jt=typeof importScripts=="function",ie=typeof window!="undefined"&&typeof window.orientation!="undefined",f=function(){function e(i,r){var n=this;this.name=i,this.workerThread=r,this.isRunning=!0,this.resolve=function(){},this.reject=function(){},this.result=new Promise(function(t,a){n.resolve=t,n.reject=a})}return e.prototype.postMessage=function(i,r){this.workerThread.postMessage({source:"Main thread",type:i,payload:r})},e.prototype.done=function(i){h(this.isRunning,"WorkerJob isRunning false."),this.isRunning=!1,this.resolve(i)},e.prototype.error=function(i){h(this.isRunning,"WorkerJob isRunning false."),this.isRunning=!1,this.reject(i)},e}(),L=f,ee=new Map;function te(e){h(e.source&&!e.url||!e.source&&e.url);var i=ee.get(e.source||e.url);return i||(e.url&&(i=me(e.url),ee.set(e.url,i)),e.source&&(i=He(e.source),ee.set(e.source,i))),h(i),i}function me(e){if(!e.startsWith("http"))return e;var i=nt(e);return He(i)}function He(e){var i=new Blob([e],{type:"application/javascript"});return URL.createObjectURL(i)}function nt(e){return`try { + importScripts('`+e+`'); +} catch (error) { + console.error(error); + throw error; +}`}function w(e,i,r){i===void 0&&(i=!0);var n=r||new Set;if(e){if(Wt(e))n.add(e);else if(Wt(e.buffer))n.add(e.buffer);else if(!ArrayBuffer.isView(e)){if(i&&typeof e=="object")for(var t in e)w(e[t],i,n)}}return r===void 0?Array.from(n):[]}function Wt(e){return e?e instanceof ArrayBuffer||typeof MessagePort!="undefined"&&e instanceof MessagePort||typeof ImageBitmap!="undefined"&&e instanceof ImageBitmap||typeof OffscreenCanvas!="undefined"&&e instanceof OffscreenCanvas:!1}var b=function(){},x=function(){function e(i){this.terminated=!1,this.loadableURL="";var r=i.name,n=i.source,t=i.url;h(n||t),this.name=r,this.source=n,this.url=t,this.onMessage=b,this.onError=function(a){return console.log(a)},this.worker=this.createBrowserWorker()}return e.isSupported=function(){return typeof Worker!="undefined"},e.prototype.destroy=function(){this.onMessage=b,this.onError=b,this.worker.terminate(),this.terminated=!0},Object.defineProperty(e.prototype,"isRunning",{get:function(){return!!this.onMessage},enumerable:!1,configurable:!0}),e.prototype.postMessage=function(i,r){r=r||w(i),this.worker.postMessage(i,r)},e.prototype.getErrorFromErrorEvent=function(i){var r="Failed to load ";return r+="worker "+this.name+" from "+this.url+". ",i.message&&(r+=i.message+" in "),i.lineno&&(r+=":"+i.lineno+":"+i.colno),new Error(r)},e.prototype.createBrowserWorker=function(){var i=this;this.loadableURL=te({source:this.source,url:this.url});var r=new Worker(this.loadableURL,{name:this.name});return r.onmessage=function(n){n.data?i.onMessage(n.data):i.onError(new Error("No data received"))},r.onerror=function(n){i.onError(i.getErrorFromErrorEvent(n)),i.terminated=!0},r.onmessageerror=function(n){return console.error("worker "+i.name+", message error: "+n)},r},e}(),S=x,U=function(){return U=Object.assign||function(e){for(var i,r=1,n=arguments.length;r0&&a[a.length-1])&&(E[0]===6||E[0]===2)){r=0;continue}if(E[0]===3&&(!a||E[1]>a[0]&&E[1]this.getMaxConcurrency();r?(i.destroy(),this.count--):this.idleQueue.push(i),this.isDestroyed||this.startQueuedJob()},e.prototype.getAvailableWorker=function(){if(this.idleQueue.length>0)return this.idleQueue.shift()||null;if(this.count=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(i?"Object is not iterable.":"Symbol.iterator is not defined.")},Qt={maxConcurrency:3,maxMobileConcurrency:1,onDebug:function(){},reuseWorkers:!0},cr=function(){function e(i){this.workerPools=new Map,this.props=zt({},Qt),this.setProps(i),this.workerPools=new Map}return e.isSupported=function(){return S.isSupported()},e.getWorkerFarm=function(i){return i===void 0&&(i={}),e.workerFarm=e.workerFarm||new e({}),e.workerFarm.setProps(i),e.workerFarm},e.prototype.destroy=function(){var i,r;try{for(var n=Tt(this.workerPools.values()),t=n.next();!t.done;t=n.next()){var a=t.value;a.destroy()}}catch(u){i={error:u}}finally{try{t&&!t.done&&(r=n.return)&&r.call(n)}finally{if(i)throw i.error}}},e.prototype.setProps=function(i){var r,n;this.props=zt(zt({},this.props),i);try{for(var t=Tt(this.workerPools.values()),a=t.next();!a.done;a=t.next()){var u=a.value;u.setProps(this.getWorkerPoolProps())}}catch(c){r={error:c}}finally{try{a&&!a.done&&(n=t.return)&&n.call(t)}finally{if(r)throw r.error}}},e.prototype.getWorkerPool=function(i){var r=i.name,n=i.source,t=i.url,a=this.workerPools.get(r);return a||(a=new dt({name:r,source:n,url:t}),a.setProps(this.getWorkerPoolProps()),this.workerPools.set(r,a)),a},e.prototype.getWorkerPoolProps=function(){return{maxConcurrency:this.props.maxConcurrency,maxMobileConcurrency:this.props.maxMobileConcurrency,reuseWorkers:this.props.reuseWorkers,onDebug:this.props.onDebug}},e}(),pr=cr,zr=new Map,jr=function(){function e(){}return Object.defineProperty(e,"onmessage",{set:function(i){self.onmessage=function(r){if(Hr(r)){var n=r.data,t=n.type,a=n.payload;i(t,a)}}},enumerable:!1,configurable:!0}),e.addEventListener=function(i){var r=zr.get(i);r||(r=function(n){if(Hr(n)){var t=n.data,a=t.type,u=t.payload;i(a,u)}}),self.addEventListener("message",r)},e.removeEventListener=function(i){var r=zr.get(i);zr.delete(i),self.removeEventListener("message",r)},e.postMessage=function(i,r){if(self){var n={source:"Worker thread",type:i,payload:r},t=w(r);self.postMessage(n,t)}},e}(),tn=null;function Hr(e){var i=e.type,r=e.data;return i==="message"&&r&&typeof r.source=="string"&&r.source==="Main thread"}function fn(e){return JSON.parse(qt(e))}function qt(e){var i=new Set;return JSON.stringify(e,function(r,n){if(typeof n=="object"&&n!==null){if(i.has(n))try{return JSON.parse(JSON.stringify(n))}catch(t){return}i.add(n)}return n})}function ii(e){return""+e.name}function Ai(e,i){i===void 0&&(i={});var r=i[e.id]||{},n=e.name+".worker.js",t=r.workerUrl;return i._workerType==="test"&&(t=e.module+"/dist/"+n),t||(t="https://unpkg.com/"+e.module+"/dist/"+n),assert(t),t}var xr=function(e,i,r,n){function t(a){return a instanceof r?a:new r(function(u){u(a)})}return new(r||(r=Promise))(function(a,u){function c(H){try{E(n.next(H))}catch(re){u(re)}}function m(H){try{E(n.throw(H))}catch(re){u(re)}}function E(H){H.done?a(H.value):t(H.value).then(c,m)}E((n=n.apply(e,i||[])).next())})},Ni=function(e,i){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,t,a,u;return u={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(u[Symbol.iterator]=function(){return this}),u;function c(E){return function(H){return m([E,H])}}function m(E){if(n)throw new TypeError("Generator is already executing.");for(;r;)try{if(n=1,t&&(a=E[0]&2?t.return:E[0]?t.throw||((a=t.return)&&a.call(t),0):t.next)&&!(a=a.call(t,E[1])).done)return a;switch(t=0,a&&(E=[E[0]&2,a.value]),E[0]){case 0:case 1:a=E;break;case 4:return r.label++,{value:E[1],done:!1};case 5:r.label++,t=E[1],E=[0];continue;case 7:E=r.ops.pop(),r.trys.pop();continue;default:if(a=r.trys,!(a=a.length>0&&a[a.length-1])&&(E[0]===6||E[0]===2)){r=0;continue}if(E[0]===3&&(!a||E[1]>a[0]&&E[1]0){if(this._values.length>0)throw new Error("Illegal internal state");var r=this._settlers.shift();i instanceof Error?r.reject(i):r.resolve({value:i})}else this._values.push(i)},e.prototype.close=function(){for(;this._settlers.length>0;){var i=this._settlers.shift();i.resolve({done:!0})}this._closed=!0},e.prototype.next=function(){var i=this;if(this._values.length>0){var r=this._values.shift();return r instanceof Error?Promise.reject(r):Promise.resolve({done:!1,value:r})}if(this._closed){if(this._settlers.length>0)throw new Error("Illegal internal state");return Promise.resolve({done:!0,value:void 0})}return new Promise(function(n,t){i._settlers.push({resolve:n,reject:t})})},e}(),hu=null,qr=function(e,i,r,n){function t(a){return a instanceof r?a:new r(function(u){u(a)})}return new(r||(r=Promise))(function(a,u){function c(H){try{E(n.next(H))}catch(re){u(re)}}function m(H){try{E(n.throw(H))}catch(re){u(re)}}function E(H){H.done?a(H.value):t(H.value).then(c,m)}E((n=n.apply(e,i||[])).next())})},Zu=function(e,i){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,t,a,u;return u={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(u[Symbol.iterator]=function(){return this}),u;function c(E){return function(H){return m([E,H])}}function m(E){if(n)throw new TypeError("Generator is already executing.");for(;r;)try{if(n=1,t&&(a=E[0]&2?t.return:E[0]?t.throw||((a=t.return)&&a.call(t),0):t.next)&&!(a=a.call(t,E[1])).done)return a;switch(t=0,a&&(E=[E[0]&2,a.value]),E[0]){case 0:case 1:a=E;break;case 4:return r.label++,{value:E[1],done:!1};case 5:r.label++,t=E[1],E=[0];continue;case 7:E=r.ops.pop(),r.trys.pop();continue;default:if(a=r.trys,!(a=a.length>0&&a[a.length-1])&&(E[0]===6||E[0]===2)){r=0;continue}if(E[0]===3&&(!a||E[1]>a[0]&&E[1]0&&a[a.length-1])&&(E[0]===6||E[0]===2)){r=0;continue}if(E[0]===3&&(!a||E[1]>a[0]&&E[1]0&&(t=1/Math.sqrt(t)),e[0]=i[0]*t,e[1]=i[1]*t,e}function Xp(e,i){return e[0]*i[0]+e[1]*i[1]}function pm(e,i,r){var n=i[0]*r[1]-i[1]*r[0];return e[0]=e[1]=0,e[2]=n,e}function Tp(e,i,r,n){var t=i[0],a=i[1];return e[0]=t+n*(r[0]-t),e[1]=a+n*(r[1]-a),e}function mm(e,i){i=i||1;var r=glMatrix.RANDOM()*2*Math.PI;return e[0]=Math.cos(r)*i,e[1]=Math.sin(r)*i,e}function dp(e,i,r){var n=i[0],t=i[1];return e[0]=r[0]*n+r[2]*t,e[1]=r[1]*n+r[3]*t,e}function j0(e,i,r){var n=i[0],t=i[1];return e[0]=r[0]*n+r[2]*t+r[4],e[1]=r[1]*n+r[3]*t+r[5],e}function Fp(e,i,r){var n=i[0],t=i[1];return e[0]=r[0]*n+r[3]*t+r[6],e[1]=r[1]*n+r[4]*t+r[7],e}function P0(e,i,r){var n=i[0],t=i[1];return e[0]=r[0]*n+r[4]*t+r[12],e[1]=r[1]*n+r[5]*t+r[13],e}function I0(e,i,r,n){var t=i[0]-r[0],a=i[1]-r[1],u=Math.sin(n),c=Math.cos(n);return e[0]=t*c-a*u+r[0],e[1]=t*u+a*c+r[1],e}function V0(e,i){var r=e[0],n=e[1],t=i[0],a=i[1],u=Math.sqrt(r*r+n*n)*Math.sqrt(t*t+a*a),c=u&&(r*t+n*a)/u;return Math.acos(Math.min(Math.max(c,-1),1))}function d0(e){return e[0]=0,e[1]=0,e}function Q0(e){return"vec2("+e[0]+", "+e[1]+")"}function Mc(e,i){return e[0]===i[0]&&e[1]===i[1]}function R0(e,i){var r=e[0],n=e[1],t=i[0],a=i[1];return Math.abs(r-t)<=glMatrix.EPSILON*Math.max(1,Math.abs(r),Math.abs(t))&&Math.abs(n-a)<=glMatrix.EPSILON*Math.max(1,Math.abs(n),Math.abs(a))}var w0=null,ad=Vf,Yp=null,E0=null,S0=null,gd=null,ip=null,O0=function(){var e=mc();return function(i,r,n,t,a,u){var c,m;for(r||(r=2),n||(n=0),t?m=Math.min(t*r+n,i.length):m=i.length,c=n;c0&&arguments[0]!==void 0?arguments[0]:{};(0,We.Z)(this,e),(0,St.Z)(this,"lastFlip",-1),(0,St.Z)(this,"miter",od(0,0)),(0,St.Z)(this,"started",!1),(0,St.Z)(this,"dash",!1),(0,St.Z)(this,"totalDistance",0),(0,St.Z)(this,"currentIndex",0),this.join=i.join||"miter",this.cap=i.cap||"butt",this.miterLimit=i.miterLimit||10,this.thickness=i.thickness||1,this.dash=i.dash||!1,this.complex={positions:[],indices:[],normals:[],startIndex:0,indexes:[]}}return(0,ot.Z)(e,[{key:"extrude_gaode2",value:function(r,n){var t=this.complex;if(r.length<=1)return t;this.lastFlip=-1,this.started=!1,this.normal=null,this.totalDistance=0;for(var a=r.length,u=t.startIndex,c=1;cthis.miterLimit&&(ma=!0)}ma?(ke.push(this.normal[0],this.normal[1],0),ke.push(po[0],po[1],0),xe.push(a[0],a[1],a[2]|0,this.totalDistance,-this.thickness*Ao,a[2]|0),this.complex.indexes.push(this.currentIndex),xe.push(a[0],a[1],a[2]|0,this.totalDistance,this.thickness*Ao,a[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++,re.push.apply(re,(0,On.Z)(this.lastFlip!==-Ao?[n,n+2,n+3]:[n+2,n+1,n+3])),re.push(n+2,n+3,n+4),op(Bp,Kp),lf(this.normal,Bp),ke.push(this.normal[0],this.normal[1],0),xe.push(a[0],a[1],a[2]|0,this.totalDistance,-this.thickness*Ao,a[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++,H+=3):(this.extrusions(xe,ke,a,po,Si,this.totalDistance),re.push.apply(re,(0,On.Z)(this.lastFlip===1?[n,n+2,n+3]:[n+2,n+1,n+3])),Ao=-1,lf(this.normal,po),H+=2),this.lastFlip=Ao}else{if(op(this.normal,pd),rt){var Ln=mc(),wn=mc();ad(wn,pd,this.normal),Tc(Ln,pd,this.normal),ke.push(wn[0],wn[1],0),ke.push(Ln[0],Ln[1],0),xe.push(a[0],a[1],a[2]|0,this.totalDistance,this.thickness,a[2]|0),this.complex.indexes.push(this.currentIndex),xe.push(a[0],a[1],a[2]|0,this.totalDistance,this.thickness,a[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++}else this.extrusions(xe,ke,a,this.normal,this.thickness,this.totalDistance);re.push.apply(re,(0,On.Z)(this.lastFlip===1?[n,n+2,n+3]:[n+2,n+1,n+3])),H+=2}return H}},{key:"simpleSegment",value:function(r,n,t,a,u){var c=0,m=r.indices,E=r.positions,H=r.normals,re=Ol([a[0],a[1]]),xe=Ol([t[0],t[1]]);pp(pd,re,xe);var ke=0;if(this.dash&&(ke=this.lineSegmentDistance(re,xe),this.totalDistance+=ke),this.normal||(this.normal=mc(),op(this.normal,pd)),this.started||(this.started=!0,this.extrusions(E,H,t,this.normal,this.thickness,this.totalDistance-ke)),m.push(n+0,n+1,n+2),!u)op(this.normal,pd),this.extrusions(E,H,a,this.normal,this.thickness,this.totalDistance),m.push.apply(m,(0,On.Z)(this.lastFlip===1?[n,n+2,n+3]:[n+2,n+1,n+3])),c+=2;else{var rt=Ol([u[0],u[1]]);H0(re,rt)&&Tc(rt,re,hp(rt,Vf(rt,re,xe))),pp(Kp,rt,re);var vt=wp(Mp,mc(),pd,Kp,this.thickness),It=(0,gi.Z)(vt,2),er=It[0],Ar=It[1],Or=Xp(Mp,this.normal)<0?-1:1;this.extrusions(E,H,a,Ar,er,this.totalDistance),m.push.apply(m,(0,On.Z)(this.lastFlip===1?[n,n+2,n+3]:[n+2,n+1,n+3])),Or=-1,lf(this.normal,Ar),c+=2,this.lastFlip=Or}return c}},{key:"segment",value:function(r,n,t,a,u){var c=0,m=r.indices,E=r.positions,H=r.normals,re=this.cap==="square",xe=this.join==="bevel",ke=Ol([a[0],a[1]]),rt=Ol([t[0],t[1]]);pp(pd,ke,rt);var vt=0;if(this.dash&&(vt=this.lineSegmentDistance(ke,rt),this.totalDistance+=vt),this.normal||(this.normal=mc(),op(this.normal,pd)),!this.started)if(this.started=!0,re){var It=mc(),er=mc();Tc(It,this.normal,pd),Tc(er,this.normal,pd),H.push(er[0],er[1],0),H.push(It[0],It[1],0),E.push(t[0],t[1],t[2]|0,this.totalDistance-vt,-this.thickness,t[2]|0),this.complex.indexes.push(this.currentIndex),E.push(t[0],t[1],t[2]|0,this.totalDistance-vt,this.thickness,t[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++}else this.extrusions(E,H,t,this.normal,this.thickness,this.totalDistance-vt);if(m.push(n+0,n+1,n+2),u){var rn=Ol([u[0],u[1]]);H0(ke,rn)&&Tc(rn,ke,hp(rn,Vf(rn,ke,rt))),pp(Kp,rn,ke);var Ln=wp(Mp,mc(),pd,Kp,this.thickness),wn=(0,gi.Z)(Ln,2),Cn=wn[0],qn=wn[1],Si=Xp(Mp,this.normal)<0?-1:1,po=xe;if(!po&&this.join==="miter"){var Ao=Cn;Ao>this.miterLimit&&(po=!0)}po?(H.push(this.normal[0],this.normal[1],0),H.push(qn[0],qn[1],0),E.push(a[0],a[1],a[2]|0,this.totalDistance,-this.thickness*Si,a[2]|0),this.complex.indexes.push(this.currentIndex),E.push(a[0],a[1],a[2]|0,this.totalDistance,this.thickness*Si,a[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++,m.push.apply(m,(0,On.Z)(this.lastFlip!==-Si?[n,n+2,n+3]:[n+2,n+1,n+3])),m.push(n+2,n+3,n+4),op(Bp,Kp),lf(this.normal,Bp),H.push(this.normal[0],this.normal[1],0),E.push(a[0],a[1],a[2]|0,this.totalDistance,-this.thickness*Si,a[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++,c+=3):(this.extrusions(E,H,a,qn,Cn,this.totalDistance),m.push.apply(m,(0,On.Z)(this.lastFlip===1?[n,n+2,n+3]:[n+2,n+1,n+3])),Si=-1,lf(this.normal,qn),c+=2),this.lastFlip=Si}else{if(op(this.normal,pd),re){var Ar=mc(),Or=mc();ad(Or,pd,this.normal),Tc(Ar,pd,this.normal),H.push(Or[0],Or[1],0),H.push(Ar[0],Ar[1],0),E.push(a[0],a[1],a[2]|0,this.totalDistance,this.thickness,a[2]|0),this.complex.indexes.push(this.currentIndex),E.push(a[0],a[1],a[2]|0,this.totalDistance,this.thickness,a[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++}else this.extrusions(E,H,a,this.normal,this.thickness,this.totalDistance);m.push.apply(m,(0,On.Z)(this.lastFlip===1?[n,n+2,n+3]:[n+2,n+1,n+3])),c+=2}return c}},{key:"extrusions",value:function(r,n,t,a,u,c){n.push(a[0],a[1],0),n.push(a[0],a[1],0),r.push(t[0],t[1],t[2]|0,c,-u,t[2]|0),this.complex.indexes.push(this.currentIndex),r.push(t[0],t[1],t[2]|0,c,u,t[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++}},{key:"lineSegmentDistance",value:function(r,n){var t=n[0]-r[0],a=n[1]-r[1];return Math.sqrt(t*t+a*a)}}]),e}();function n0(e){var i=e.coordinates,r=e.originCoordinates,n=e.version,t=new y0({dash:!0,join:"bevel"});if(n==="GAODE2.x"){var a=i;Array.isArray(a[0][0])||(a=[i]);var u=r;Array.isArray(u[0][0])||(u=[r]);for(var c=0;c0}).forEach(function(er,Ar){var Or=jp(er[c]);(0,mt.nG)(Or,function(rn){var Ln=(0,Ft.r7)(rn),wn=(0,Se.Z)((0,Se.Z)({},er),{},{_id:Ar,coordinates:Ln});m.push(wn)})}),{dataArray:m};for(var E=0;E>>0}function Vh(e,i){return i===void 0?null:(0,df.Z)(e.properties[i])*1==="number"?e.properties[i]*1:e.properties&&e.properties[i]?um(e.properties[i]+"")%1000019:null}function B0(e,i){var r=[],n={};return e.features?(e.features=e.features.filter(function(t){var a=t.geometry;return t!=null&&a&&a.type&&a.coordinates&&a.coordinates.length>0}),e=jp(e),e.features.length===0?{dataArray:[],featureKeys:n}:((0,mt.nG)(e,function(t,a){var u=Vh(t,i==null?void 0:i.featureId);u===null&&(u=a);var c=u,m=(0,Ft.r7)(t),E=(0,Se.Z)((0,Se.Z)({},t.properties),{},{coordinates:m,_id:c});r.push(E)}),{dataArray:r,featureKeys:n})):(e.features=[],{dataArray:[]})}function mp(e,i,r,n){for(var t=n,a=r-i>>1,u=r-i,c,m=e[i],E=e[i+1],H=e[r],re=e[r+1],xe=i+3;xet)c=xe,t=ke;else if(ke===t){var rt=Math.abs(xe-a);rtn&&(c-i>3&&mp(e,i,c,n),e[c+2]=t,r-c>3&&mp(e,c,r,n))}function J0(e,i,r,n,t,a){var u=t-r,c=a-n;if(u!==0||c!==0){var m=((e-r)*u+(i-n)*c)/(u*u+c*c);m>1?(r=t,n=a):m>0&&(r+=u*m,n+=c*m)}return u=e-r,c=i-n,u*u+c*c}function G0(e,i,r,n){var t={id:typeof e=="undefined"?null:e,type:i,geometry:r,tags:n,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0};return W0(t),t}function W0(e){var i=e.geometry,r=e.type;if(r==="Point"||r==="MultiPoint"||r==="LineString")Td(e,i);else if(r==="Polygon"||r==="MultiLineString")for(var n=0;n0&&(n?u+=(t*E-m*a)/2:u+=Math.sqrt(Math.pow(m-t,2)+Math.pow(E-a,2))),t=m,a=E}var H=i.length-3;i[2]=1,mp(i,0,H,r),i[H+2]=1,i.size=Math.abs(u),i.start=0,i.end=i.size}function Sn(e,i,r,n){for(var t=0;t1?1:r}function Ta(e,i,r,n,t,a,u,c){if(r/=i,n/=i,a>=r&&u=n)return null;for(var m=[],E=0;E=r&&rt=n)continue;var vt=[];if(xe==="Point"||xe==="MultiPoint")$o(re,vt,r,n,t);else if(xe==="LineString")Po(re,vt,r,n,t,!1,c.lineMetrics);else if(xe==="MultiLineString")Ja(re,vt,r,n,t,!1);else if(xe==="Polygon")Ja(re,vt,r,n,t,!0);else if(xe==="MultiPolygon")for(var It=0;It=r&&u<=n&&(i.push(e[a]),i.push(e[a+1]),i.push(e[a+2]))}}function Po(e,i,r,n,t,a,u){for(var c=ds(e),m=t===0?Ds:Bs,E=e.start,H,re,xe=0;xer&&(re=m(c,ke,rt,It,er,r),u&&(c.start=E+H*re)):Ar>n?Or=r&&(re=m(c,ke,rt,It,er,r),rn=!0),Or>n&&Ar<=n&&(re=m(c,ke,rt,It,er,n),rn=!0),!a&&rn&&(u&&(c.end=E+H*re),i.push(c),c=ds(e)),u&&(E+=H)}var Ln=e.length-3;ke=e[Ln],rt=e[Ln+1],vt=e[Ln+2],Ar=t===0?ke:rt,Ar>=r&&Ar<=n&&au(c,ke,rt,vt),Ln=c.length-3,a&&Ln>=3&&(c[Ln]!==c[0]||c[Ln+1]!==c[1])&&au(c,c[0],c[1],c[2]),c.length&&i.push(c)}function ds(e){var i=[];return i.size=e.size,i.start=e.start,i.end=e.end,i}function Ja(e,i,r,n,t,a){for(var u=0;uu.maxX&&(u.maxX=H),re>u.maxY&&(u.maxY=re)}return u}function Ru(e,i,r,n){var t=i.geometry,a=i.type,u=[];if(a==="Point"||a==="MultiPoint")for(var c=0;c0&&i.size<(t?u:n)){r.numPoints+=i.length/3;return}for(var c=[],m=0;mu)&&(r.numSimplified++,c.push(i[m]),c.push(i[m+1])),r.numPoints++;t&&qu(c,a),e.push(c)}function qu(e,i){for(var r=0,n=0,t=e.length,a=t-2;n0===i)for(n=0,t=e.length;n24)throw new Error("maxZoom should be in the 0-24 range");if(i.promoteId&&i.generateId)throw new Error("promoteId and generateId cannot be used together.");var n=o0(e,i);this.tiles={},this.tileCoords=[],r&&(console.timeEnd("preprocess data"),console.log("index: maxZoom: %d, maxPoints: %d",i.indexMaxZoom,i.indexMaxPoints),console.time("generate tiles"),this.stats={},this.total=0),n=ru(n,i),n.length&&this.splitTile(n,0,0,0),r&&(n.length&&console.log("features: %d, points: %d",this.tiles[0].numFeatures,this.tiles[0].numPoints),console.timeEnd("generate tiles"),console.log("tiles generated:",this.total,JSON.stringify(this.stats)))}Ou.prototype.options={maxZoom:14,indexMaxZoom:5,indexMaxPoints:1e5,tolerance:3,extent:4096,buffer:64,lineMetrics:!1,promoteId:null,generateId:!1,debug:0},Ou.prototype.splitTile=function(e,i,r,n,t,a,u){for(var c=[e,i,r,n],m=this.options,E=m.debug;c.length;){n=c.pop(),r=c.pop(),i=c.pop(),e=c.pop();var H=1<1&&console.time("creation"),xe=this.tiles[re]=zs(e,i,r,n,m),this.tileCoords.push({z:i,x:r,y:n}),E)){E>1&&(console.log("tile z%d-%d-%d (features: %d, points: %d, simplified: %d)",i,r,n,xe.numFeatures,xe.numPoints,xe.numSimplified),console.timeEnd("creation"));var ke="z"+i;this.stats[ke]=(this.stats[ke]||0)+1,this.total++}if(xe.source=e,t){if(i===m.maxZoom||i===t)continue;var rt=1<1&&console.time("clipping");var vt=.5*m.buffer/m.extent,It=.5-vt,er=.5+vt,Ar=1+vt,Or,rn,Ln,wn,Cn,qn;Or=rn=Ln=wn=null,Cn=Ta(e,H,r-vt,r+er,0,xe.minX,xe.maxX,m),qn=Ta(e,H,r+It,r+Ar,0,xe.minX,xe.maxX,m),e=null,Cn&&(Or=Ta(Cn,H,n-vt,n+er,1,xe.minY,xe.maxY,m),rn=Ta(Cn,H,n+It,n+Ar,1,xe.minY,xe.maxY,m),Cn=null),qn&&(Ln=Ta(qn,H,n-vt,n+er,1,xe.minY,xe.maxY,m),wn=Ta(qn,H,n+It,n+Ar,1,xe.minY,xe.maxY,m),qn=null),E>1&&console.timeEnd("clipping"),c.push(Or||[],i+1,r*2,n*2),c.push(rn||[],i+1,r*2,n*2+1),c.push(Ln||[],i+1,r*2+1,n*2),c.push(wn||[],i+1,r*2+1,n*2+1)}}},Ou.prototype.getTile=function(e,i,r){var n=this.options,t=n.extent,a=n.debug;if(e<0||e>24)return null;var u=1<1&&console.log("drilling down to z%d-%d-%d",e,i,r);for(var m=e,E=i,H=r,re;!re&&m>0;)m--,E=Math.floor(E/2),H=Math.floor(H/2),re=this.tiles[Ba(m,E,H)];return!re||!re.source?null:(a>1&&console.log("found parent tile z%d-%d-%d",m,E,H),a>1&&console.time("drilling down"),this.splitTile(re.source,m,E,H,e,i,r),a>1&&console.timeEnd("drilling down"),this.tiles[c]?co(this.tiles[c],t):null)};function Ba(e,i,r){return((1<0)switch(n[0]){case"band":try{e[t]=i[n[1]][r]}catch(a){console.warn("Raster Data err!"),e[t]=0}break;default:Od(n,i,r)}})}function Yc(e){var i=(0,gi.Z)(e,3),r=i[0],n=i[1],t=n===void 0?-1:n,a=i[2],u=a===void 0?-1:a;if(r===void 0)return console.warn("Express err!"),["+",0,0];var c=r.replace(/\s+/g,"");return[c,t,u]}function Qf(e){var i=Yc(e),r=i[0],n=i[1],t=i[2];return Array.isArray(n)&&(n=Qf(e[1])),Array.isArray(t)&&(t=Qf(e[2])),$h(r,n,t)}var Pu={nd:{type:"operation",expression:["/",["-",["band",1],["band",0]],["+",["band",1],["band",0]]]},rgb:{type:"function",method:hl}};function hl(e,i){for(var r=e[0].rasterData,n=e[1].rasterData,t=e[2].rasterData,a=[],u=(i==null?void 0:i.countCut)||[2,98],c=(0,gi.Z)(u,2),m=c[0],E=c[1],H=(i==null?void 0:i.RMinMax)||Gs(r,m,E),re=(i==null?void 0:i.GMinMax)||Gs(n,m,E),xe=(i==null?void 0:i.BMinMax)||Gs(t,m,E),ke=0;ke"),IRendererService:Symbol.for("IRendererService"),IShaderModuleService:Symbol.for("IShaderModuleService"),IIconService:Symbol.for("IIconService"),IFontService:Symbol.for("IFontService"),IInteractionService:Symbol.for("IInteractionService"),IPickingService:Symbol.for("IPickingService"),IControlService:Symbol.for("IControlService"),IStyleAttributeService:Symbol.for("IStyleAttributeService"),ILayer:Symbol.for("ILayer"),ILayerPlugin:Symbol.for("ILayerPlugin"),INormalPass:Symbol.for("INormalPass"),IPostProcessor:Symbol.for("IPostProcessor"),IPostProcessingPass:Symbol.for("IPostProcessingPass"),IFactoryPostProcessingPass:Symbol.for("Factory"),IFactoryNormalPass:Symbol.for("Factory"),IMultiPassRenderer:Symbol.for("IMultiPassRenderer"),SceneID:Symbol.for("SceneID"),MapConfig:Symbol.for("MapConfig")},ti=A(52155),_o=A.n(ti);function bo(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=Pi(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function Pi(e,i){if(e){if(typeof e=="string")return ji(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return ji(e,i)}}function ji(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);ra&&(ke=0,xe++),c[vt]={x:ke,y:re+xe*Di,width:Di,height:Di,advance:er},ke+=Di}});var rt=n+t*2;return{mapping:c,xOffset:ke,yOffset:re+xe*rt,canvasHeight:F(re+(xe+1)*rt)}}function D(e,i,r){var n=0,t=0,a=0,u=[],c={},m=bo(e),E;try{for(m.s();!(E=m.n()).done;){var H=E.value;if(!c[H.id]){var re=H.size;n+re+i>r&&(P(c,u,t),n=0,t=a+t+i,a=0,u=[]),u.push({icon:H,xOffset:n}),n=n+re+i,a=Math.max(a,re)}}}catch(ke){m.e(ke)}finally{m.f()}u.length>0&&P(c,u,t);var xe=F(a+t+i);return{mapping:c,canvasHeight:xe}}function P(e,i,r){var n=bo(i),t;try{for(n.s();!(t=n.n()).done;){var a=t.value,u=a.icon,c=a.xOffset;e[u.id]=(0,Se.Z)((0,Se.Z)({},u),{},{x:c,y:r,image:u.image,width:u.width,height:u.height})}}catch(m){n.e(m)}finally{n.f()}}function F(e){return Math.pow(2,Math.ceil(Math.log2(e)))}var q,fe;function Ae(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=Ie(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function Ie(e,i){if(e){if(typeof e=="string")return Ze(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Ze(e,i)}}function Ze(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r0?(r[0]=(c*u+H*n+m*a-E*t)*2/re,r[1]=(m*u+H*t+E*n-c*a)*2/re,r[2]=(E*u+H*a+c*t-m*n)*2/re):(r[0]=(c*u+H*n+m*a-E*t)*2,r[1]=(m*u+H*t+E*n-c*a)*2,r[2]=(E*u+H*a+c*t-m*n)*2),g(e,i,r),e}function j(e,i){return e[0]=i[12],e[1]=i[13],e[2]=i[14],e}function J(e,i){var r=i[0],n=i[1],t=i[2],a=i[4],u=i[5],c=i[6],m=i[8],E=i[9],H=i[10];return e[0]=Math.hypot(r,n,t),e[1]=Math.hypot(a,u,c),e[2]=Math.hypot(m,E,H),e}function ve(e,i){var r=new xh(3);J(r,i);var n=1/r[0],t=1/r[1],a=1/r[2],u=i[0]*n,c=i[1]*t,m=i[2]*a,E=i[4]*n,H=i[5]*t,re=i[6]*a,xe=i[8]*n,ke=i[9]*t,rt=i[10]*a,vt=u+H+rt,It=0;return vt>0?(It=Math.sqrt(vt+1)*2,e[3]=.25*It,e[0]=(re-ke)/It,e[1]=(xe-m)/It,e[2]=(c-E)/It):u>H&&u>rt?(It=Math.sqrt(1+u-H-rt)*2,e[3]=(re-ke)/It,e[0]=.25*It,e[1]=(c+E)/It,e[2]=(xe+m)/It):H>rt?(It=Math.sqrt(1+H-u-rt)*2,e[3]=(xe-m)/It,e[0]=(c+E)/It,e[1]=.25*It,e[2]=(re+ke)/It):(It=Math.sqrt(1+rt-u-H)*2,e[3]=(c-E)/It,e[0]=(xe+m)/It,e[1]=(re+ke)/It,e[2]=.25*It),e}function ze(e,i,r,n){var t=i[0],a=i[1],u=i[2],c=i[3],m=t+t,E=a+a,H=u+u,re=t*m,xe=t*E,ke=t*H,rt=a*E,vt=a*H,It=u*H,er=c*m,Ar=c*E,Or=c*H,rn=n[0],Ln=n[1],wn=n[2];return e[0]=(1-(rt+It))*rn,e[1]=(xe+Or)*rn,e[2]=(ke-Ar)*rn,e[3]=0,e[4]=(xe-Or)*Ln,e[5]=(1-(re+It))*Ln,e[6]=(vt+er)*Ln,e[7]=0,e[8]=(ke+Ar)*wn,e[9]=(vt-er)*wn,e[10]=(1-(re+rt))*wn,e[11]=0,e[12]=r[0],e[13]=r[1],e[14]=r[2],e[15]=1,e}function lt(e,i,r,n,t){var a=i[0],u=i[1],c=i[2],m=i[3],E=a+a,H=u+u,re=c+c,xe=a*E,ke=a*H,rt=a*re,vt=u*H,It=u*re,er=c*re,Ar=m*E,Or=m*H,rn=m*re,Ln=n[0],wn=n[1],Cn=n[2],qn=t[0],Si=t[1],po=t[2],Ao=(1-(vt+er))*Ln,ma=(ke+rn)*Ln,Ya=(rt-Or)*Ln,fs=(ke-rn)*wn,bf=(1-(xe+er))*wn,th=(It+Ar)*wn,Yh=(rt+Or)*Cn,Lp=(It-Ar)*Cn,vd=(1-(xe+vt))*Cn;return e[0]=Ao,e[1]=ma,e[2]=Ya,e[3]=0,e[4]=fs,e[5]=bf,e[6]=th,e[7]=0,e[8]=Yh,e[9]=Lp,e[10]=vd,e[11]=0,e[12]=r[0]+qn-(Ao*qn+fs*Si+Yh*po),e[13]=r[1]+Si-(ma*qn+bf*Si+Lp*po),e[14]=r[2]+po-(Ya*qn+th*Si+vd*po),e[15]=1,e}function Dt(e,i){var r=i[0],n=i[1],t=i[2],a=i[3],u=r+r,c=n+n,m=t+t,E=r*u,H=n*u,re=n*c,xe=t*u,ke=t*c,rt=t*m,vt=a*u,It=a*c,er=a*m;return e[0]=1-re-rt,e[1]=H+er,e[2]=xe-It,e[3]=0,e[4]=H-er,e[5]=1-E-rt,e[6]=ke+vt,e[7]=0,e[8]=xe+It,e[9]=ke-vt,e[10]=1-E-re,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function $t(e,i,r,n,t,a,u){var c=1/(r-i),m=1/(t-n),E=1/(a-u);return e[0]=a*2*c,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=a*2*m,e[6]=0,e[7]=0,e[8]=(r+i)*c,e[9]=(t+n)*m,e[10]=(u+a)*E,e[11]=-1,e[12]=0,e[13]=0,e[14]=u*a*2*E,e[15]=0,e}function lr(e,i,r,n,t){var a=1/Math.tan(i/2),u;return 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,t!=null&&t!==1/0?(u=1/(n-t),e[10]=(t+n)*u,e[14]=2*t*n*u):(e[10]=-1,e[14]=-2*n),e}var wr=lr;function Vr(e,i,r,n,t){var a=1/Math.tan(i/2),u;return 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,t!=null&&t!==1/0?(u=1/(n-t),e[10]=t*u,e[14]=t*n*u):(e[10]=-1,e[14]=-n),e}function $r(e,i,r,n){var t=Math.tan(i.upDegrees*Math.PI/180),a=Math.tan(i.downDegrees*Math.PI/180),u=Math.tan(i.leftDegrees*Math.PI/180),c=Math.tan(i.rightDegrees*Math.PI/180),m=2/(u+c),E=2/(t+a);return e[0]=m,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=E,e[6]=0,e[7]=0,e[8]=-((u-c)*m*.5),e[9]=(t-a)*E*.5,e[10]=n/(r-n),e[11]=-1,e[12]=0,e[13]=0,e[14]=n*r/(r-n),e[15]=0,e}function Xr(e,i,r,n,t,a,u){var c=1/(i-r),m=1/(n-t),E=1/(a-u);return e[0]=-2*c,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=-2*m,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=2*E,e[11]=0,e[12]=(i+r)*c,e[13]=(t+n)*m,e[14]=(u+a)*E,e[15]=1,e}var Gr=Xr;function Br(e,i,r,n,t,a,u){var c=1/(i-r),m=1/(n-t),E=1/(a-u);return e[0]=-2*c,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=-2*m,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=E,e[11]=0,e[12]=(i+r)*c,e[13]=(t+n)*m,e[14]=a*E,e[15]=1,e}function Tn(e,i,r,n){var t,a,u,c,m,E,H,re,xe,ke,rt=i[0],vt=i[1],It=i[2],er=n[0],Ar=n[1],Or=n[2],rn=r[0],Ln=r[1],wn=r[2];return Math.abs(rt-rn)0&&(ke=1/Math.sqrt(ke),H*=ke,re*=ke,xe*=ke);var rt=m*xe-E*re,vt=E*H-c*xe,It=c*re-m*H;return ke=rt*rt+vt*vt+It*It,ke>0&&(ke=1/Math.sqrt(ke),rt*=ke,vt*=ke,It*=ke),e[0]=rt,e[1]=vt,e[2]=It,e[3]=0,e[4]=re*It-xe*vt,e[5]=xe*rt-H*It,e[6]=H*vt-re*rt,e[7]=0,e[8]=H,e[9]=re,e[10]=xe,e[11]=0,e[12]=t,e[13]=a,e[14]=u,e[15]=1,e}function yi(e){return"mat4("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+", "+e[4]+", "+e[5]+", "+e[6]+", "+e[7]+", "+e[8]+", "+e[9]+", "+e[10]+", "+e[11]+", "+e[12]+", "+e[13]+", "+e[14]+", "+e[15]+")"}function vo(e){return Math.hypot(e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8],e[9],e[10],e[11],e[12],e[13],e[14],e[15])}function Eo(e,i,r){return e[0]=i[0]+r[0],e[1]=i[1]+r[1],e[2]=i[2]+r[2],e[3]=i[3]+r[3],e[4]=i[4]+r[4],e[5]=i[5]+r[5],e[6]=i[6]+r[6],e[7]=i[7]+r[7],e[8]=i[8]+r[8],e[9]=i[9]+r[9],e[10]=i[10]+r[10],e[11]=i[11]+r[11],e[12]=i[12]+r[12],e[13]=i[13]+r[13],e[14]=i[14]+r[14],e[15]=i[15]+r[15],e}function Xo(e,i,r){return e[0]=i[0]-r[0],e[1]=i[1]-r[1],e[2]=i[2]-r[2],e[3]=i[3]-r[3],e[4]=i[4]-r[4],e[5]=i[5]-r[5],e[6]=i[6]-r[6],e[7]=i[7]-r[7],e[8]=i[8]-r[8],e[9]=i[9]-r[9],e[10]=i[10]-r[10],e[11]=i[11]-r[11],e[12]=i[12]-r[12],e[13]=i[13]-r[13],e[14]=i[14]-r[14],e[15]=i[15]-r[15],e}function ys(e,i,r){return e[0]=i[0]*r,e[1]=i[1]*r,e[2]=i[2]*r,e[3]=i[3]*r,e[4]=i[4]*r,e[5]=i[5]*r,e[6]=i[6]*r,e[7]=i[7]*r,e[8]=i[8]*r,e[9]=i[9]*r,e[10]=i[10]*r,e[11]=i[11]*r,e[12]=i[12]*r,e[13]=i[13]*r,e[14]=i[14]*r,e[15]=i[15]*r,e}function Yo(e,i,r,n){return e[0]=i[0]+r[0]*n,e[1]=i[1]+r[1]*n,e[2]=i[2]+r[2]*n,e[3]=i[3]+r[3]*n,e[4]=i[4]+r[4]*n,e[5]=i[5]+r[5]*n,e[6]=i[6]+r[6]*n,e[7]=i[7]+r[7]*n,e[8]=i[8]+r[8]*n,e[9]=i[9]+r[9]*n,e[10]=i[10]+r[10]*n,e[11]=i[11]+r[11]*n,e[12]=i[12]+r[12]*n,e[13]=i[13]+r[13]*n,e[14]=i[14]+r[14]*n,e[15]=i[15]+r[15]*n,e}function es(e,i){return e[0]===i[0]&&e[1]===i[1]&&e[2]===i[2]&&e[3]===i[3]&&e[4]===i[4]&&e[5]===i[5]&&e[6]===i[6]&&e[7]===i[7]&&e[8]===i[8]&&e[9]===i[9]&&e[10]===i[10]&&e[11]===i[11]&&e[12]===i[12]&&e[13]===i[13]&&e[14]===i[14]&&e[15]===i[15]}function qa(e,i){var r=e[0],n=e[1],t=e[2],a=e[3],u=e[4],c=e[5],m=e[6],E=e[7],H=e[8],re=e[9],xe=e[10],ke=e[11],rt=e[12],vt=e[13],It=e[14],er=e[15],Ar=i[0],Or=i[1],rn=i[2],Ln=i[3],wn=i[4],Cn=i[5],qn=i[6],Si=i[7],po=i[8],Ao=i[9],ma=i[10],Ya=i[11],fs=i[12],bf=i[13],th=i[14],Yh=i[15];return Math.abs(r-Ar)<=jh*Math.max(1,Math.abs(r),Math.abs(Ar))&&Math.abs(n-Or)<=jh*Math.max(1,Math.abs(n),Math.abs(Or))&&Math.abs(t-rn)<=jh*Math.max(1,Math.abs(t),Math.abs(rn))&&Math.abs(a-Ln)<=jh*Math.max(1,Math.abs(a),Math.abs(Ln))&&Math.abs(u-wn)<=jh*Math.max(1,Math.abs(u),Math.abs(wn))&&Math.abs(c-Cn)<=jh*Math.max(1,Math.abs(c),Math.abs(Cn))&&Math.abs(m-qn)<=jh*Math.max(1,Math.abs(m),Math.abs(qn))&&Math.abs(E-Si)<=jh*Math.max(1,Math.abs(E),Math.abs(Si))&&Math.abs(H-po)<=jh*Math.max(1,Math.abs(H),Math.abs(po))&&Math.abs(re-Ao)<=jh*Math.max(1,Math.abs(re),Math.abs(Ao))&&Math.abs(xe-ma)<=jh*Math.max(1,Math.abs(xe),Math.abs(ma))&&Math.abs(ke-Ya)<=jh*Math.max(1,Math.abs(ke),Math.abs(Ya))&&Math.abs(rt-fs)<=jh*Math.max(1,Math.abs(rt),Math.abs(fs))&&Math.abs(vt-bf)<=jh*Math.max(1,Math.abs(vt),Math.abs(bf))&&Math.abs(It-th)<=jh*Math.max(1,Math.abs(It),Math.abs(th))&&Math.abs(er-Yh)<=jh*Math.max(1,Math.abs(er),Math.abs(Yh))}var Ts=Gh,is=Xo,ts,Rs,pu=(ts=(0,sa.b2)(),ts(Rs=function(){function e(){(0,We.Z)(this,e),(0,St.Z)(this,"viewport",void 0),(0,St.Z)(this,"overridedViewProjectionMatrix",void 0),(0,St.Z)(this,"jitteredViewProjectionMatrix",void 0),(0,St.Z)(this,"jitteredProjectionMatrix",void 0),(0,St.Z)(this,"viewMatrixInverse",void 0),(0,St.Z)(this,"cameraPosition",void 0)}return(0,ot.Z)(e,[{key:"init",value:function(){}},{key:"update",value:function(r){this.viewport=r,this.viewMatrixInverse=Mf(),N0(this.viewMatrixInverse,r.getViewMatrix()),this.cameraPosition=[this.viewMatrixInverse[12],this.viewMatrixInverse[13],this.viewMatrixInverse[14]]}},{key:"getProjectionMatrix",value:function(){return this.jitteredProjectionMatrix||this.viewport.getProjectionMatrix()}},{key:"getModelMatrix",value:function(){return this.viewport.getModelMatrix()}},{key:"getViewMatrix",value:function(){return this.viewport.getViewMatrix()}},{key:"getViewMatrixUncentered",value:function(){return this.viewport.getViewMatrixUncentered()}},{key:"getViewProjectionMatrixUncentered",value:function(){return this.viewport.getViewProjectionMatrixUncentered()}},{key:"getViewProjectionMatrix",value:function(){return this.overridedViewProjectionMatrix||this.jitteredViewProjectionMatrix||this.viewport.getViewProjectionMatrix()}},{key:"getZoom",value:function(){return this.viewport.getZoom()}},{key:"getZoomScale",value:function(){return this.viewport.getZoomScale()}},{key:"getCenter",value:function(){var r=this.viewport.getCenter(),n=(0,gi.Z)(r,2),t=n[0],a=n[1];return[t,a]}},{key:"getFocalDistance",value:function(){return this.viewport.getFocalDistance()}},{key:"getCameraPosition",value:function(){return this.cameraPosition}},{key:"projectFlat",value:function(r,n){return this.viewport.projectFlat(r,n)}},{key:"setViewProjectionMatrix",value:function(r){this.overridedViewProjectionMatrix=r}},{key:"jitterProjectionMatrix",value:function(r,n){var t=Ed(Mf(),[r,n,0]);this.jitteredProjectionMatrix=Gh(Mf(),t,this.viewport.getProjectionMatrix()),this.jitteredViewProjectionMatrix=Gh(Mf(),this.jitteredProjectionMatrix,this.viewport.getViewMatrix())}},{key:"clearJitterProjectionMatrix",value:function(){this.jitteredProjectionMatrix=void 0,this.jitteredViewProjectionMatrix=void 0}}]),e}())||Rs),nl=function(e){return e.TOPRIGHT="topright",e.TOPLEFT="topleft",e.BOTTOMRIGHT="bottomright",e.BOTTOMLEFT="bottomleft",e.TOPCENTER="topcenter",e.BOTTOMCENTER="bottomcenter",e.LEFTCENTER="leftcenter",e.RIGHTCENTER="rightcenter",e.LEFTTOP="lefttop",e.RIGHTTOP="righttop",e.LEFTBOTTOM="leftbottom",e.RIGHTBOTTOM="rightbottom",e}({}),la,Es;function sl(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=Bf(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function Bf(e,i){if(e){if(typeof e=="string")return Vl(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Vl(e,i)}}function Vl(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r-1&&this.controls.splice(n,1),r.remove(),this}},{key:"addControls",value:function(){var r=this;this.unAddControls.forEach(function(n){n.addTo(r.scene),r.controls.push(n)}),this.unAddControls=[]}},{key:"destroy",value:function(){var r=sl(this.controls),n;try{for(r.s();!(n=r.n()).done;){var t=n.value;t.remove()}}catch(a){r.e(a)}finally{r.f()}this.controls=[],this.clearControlPos()}},{key:"initControlPos",value:function(){var r=this.controlCorners={},n="l7-",t=this.controlContainer=Vo("div",n+"control-container",this.container);function a(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],m=c.map(function(E){return n+E}).join(" ");r[c.filter(function(E){return!["row","column"].includes(E)}).join("")]=Vo("div",m,t)}function u(c){var m=c.replace(/^(top|bottom|left|right|center)/,"$1-").split("-");return[].concat((0,On.Z)(m),[oc[c]])}Object.values(nl).forEach(function(c){a(u(c))}),this.checkCornerOverlap()}},{key:"clearControlPos",value:function(){for(var r in this.controlCorners)this.controlCorners[r]&&bs(this.controlCorners[r]);this.controlContainer&&bs(this.controlContainer)}},{key:"checkCornerOverlap",value:function(){var r=this,n=window.MutationObserver;if(n)for(var t=function(){var m=u[a],E=m.match(/^(top|bottom)(left|right)$/);if(E){var H=(0,gi.Z)(E,3),re=H[1],xe=H[2],ke=r.controlCorners["".concat(re).concat(xe)],rt=new n(function(vt){var It=(0,gi.Z)(vt,1),er=It[0].target;ke&&(ke.style[re]=er.clientHeight+"px")});rt.observe(r.controlCorners["".concat(xe).concat(re)],{childList:!0,attributes:!0})}},a=0,u=Object.keys(this.controlCorners);a-1&&this.markerLayers.splice(n,1)}},{key:"addMarker",value:function(r){this.mapsService.map&&this.mapsService.getMarkerContainer()?(this.markers.push(r),r.addTo(this.scene)):this.unAddMarkers.push(r)}},{key:"addMarkers",value:function(){var r=this;this.unAddMarkers.forEach(function(n){n.addTo(r.scene),r.markers.push(n)}),this.unAddMarkers=[]}},{key:"addMarkerLayers",value:function(){var r=this;this.unAddMarkerLayers.forEach(function(n){r.markerLayers.push(n),n.addTo(r.scene)}),this.unAddMarkers=[]}},{key:"removeMarker",value:function(r){r.remove(),this.markers.indexOf(r);var n=this.markers.indexOf(r);n>-1&&this.markers.splice(n,1)}},{key:"removeAllMarkers",value:function(){this.destroy()}},{key:"init",value:function(r){this.scene=r,this.mapsService=r.get(sr.IMapService)}},{key:"destroy",value:function(){this.markers.forEach(function(r){r.remove()}),this.markers=[],this.markerLayers.forEach(function(r){r.destroy()}),this.markerLayers=[]}},{key:"removeMakerLayerMarker",value:function(r){r.destroy()}}]),e}())||ih),hh,dh,Jf=(hh=(0,sa.b2)(),hh(dh=function(){function e(){(0,We.Z)(this,e),(0,St.Z)(this,"scene",void 0),(0,St.Z)(this,"mapsService",void 0),(0,St.Z)(this,"popups",[]),(0,St.Z)(this,"unAddPopups",[])}return(0,ot.Z)(e,[{key:"isMarkerReady",get:function(){return this.mapsService.map&&this.mapsService.getMarkerContainer()}},{key:"removePopup",value:function(r){r!=null&&r.isOpen()&&r.remove();var n=this.popups.indexOf(r);n>-1&&this.popups.splice(n,1);var t=this.unAddPopups.indexOf(r);t>-1&&this.unAddPopups.splice(t,1)}},{key:"destroy",value:function(){this.popups.forEach(function(r){return r.remove()})}},{key:"addPopup",value:function(r){var n=this;r&&r.getOptions().autoClose&&[].concat((0,On.Z)(this.popups),(0,On.Z)(this.unAddPopups)).forEach(function(t){t.getOptions().autoClose&&n.removePopup(t)}),this.isMarkerReady?(r.addTo(this.scene),this.popups.push(r)):this.unAddPopups.push(r),r.on("close",function(){n.removePopup(r)})}},{key:"initPopup",value:function(){var r=this;this.unAddPopups.length&&this.unAddPopups.forEach(function(n){r.addPopup(n),r.unAddPopups=[]})}},{key:"init",value:function(r){this.scene=r,this.mapsService=r.get(sr.IMapService)}}]),e}())||dh),pf=function(e){return e.normal="normal",e.additive="additive",e.subtractive="subtractive",e.min="min",e.max="max",e.none="none",e}({}),ec=function(e){return e.MULTIPLE="MULTIPLE",e.SINGLE="SINGLE",e}({}),Jc=function(e){return e.AND="and",e.OR="or",e}({}),zl=function(e){return e.INIT="init",e.UPDATE="update",e}({}),Zc={MapToken:"\u60A8\u6B63\u5728\u4F7F\u7528 Demo \u6D4B\u8BD5 Token, \u751F\u4EA7\u73AF\u5883\u52A1\u5FC5\u81EA\u884C\u6CE8\u518C Token \u786E\u4FDD\u670D\u52A1\u7A33\u5B9A \u9AD8\u5FB7\u5730\u56FE\u7533\u8BF7\u5730\u5740 https://lbs.amap.com/api/javascript-api/guide/abc/prepare Mapbox\u5730\u56FE\u7533\u8BF7\u5730\u5740 https://docs.mapbox.com/help/glossary/access-token/",SDK:"\u8BF7\u786E\u8BA4\u5F15\u5165\u4E86mapbox-gl api\u4E14\u5728L7\u4E4B\u524D\u5F15\u5165"},Lh=Zc,sd,pa,gc=lo.merge,Rc={id:"map",logoPosition:"bottomleft",logoVisible:!0,antialias:!0,stencil:!0,preserveDrawingBuffer:!1,pickBufferScale:1,fitBoundsOptions:{animate:!1}},tc={colors:["rgb(103,0,31)","rgb(178,24,43)","rgb(214,96,77)","rgb(244,165,130)","rgb(253,219,199)","rgb(247,247,247)","rgb(209,229,240)","rgb(146,197,222)","rgb(67,147,195)","rgb(33,102,172)","rgb(5,48,97)"],size:10,shape:"circle",scales:{},shape2d:["circle","triangle","square","pentagon","hexagon","octogon","hexagram","rhombus","vesica"],shape3d:["cylinder","triangleColumn","hexagonColumn","squareColumn"],minZoom:-1,maxZoom:24,visible:!0,autoFit:!1,pickingBuffer:0,enablePropagation:!1,zIndex:0,blend:"normal",maskLayers:[],enableMask:!0,maskOperation:Jc.AND,pickedFeatureID:-1,enableMultiPassRenderer:!1,enablePicking:!0,active:!1,activeColor:"#2f54eb",enableHighlight:!1,enableSelect:!1,highlightColor:"#2f54eb",activeMix:0,selectColor:"blue",selectMix:0,enableTAA:!1,jitterScale:1,enableLighting:!1,animateOption:{enable:!1,interval:.2,duration:4,trailLength:.15},forward:!0},oh=(sd=(0,sa.b2)(),sd(pa=function(){function e(){(0,We.Z)(this,e),(0,St.Z)(this,"sceneConfigCache",{}),(0,St.Z)(this,"layerConfigCache",{}),(0,St.Z)(this,"layerAttributeConfigCache",{})}return(0,ot.Z)(e,[{key:"getSceneConfig",value:function(r){return this.sceneConfigCache[r]}},{key:"getSceneWarninfo",value:function(r){return Lh[r]}},{key:"setSceneConfig",value:function(r,n){this.sceneConfigCache[r]=(0,Se.Z)((0,Se.Z)({},Rc),n)}},{key:"getLayerConfig",value:function(r){return this.layerConfigCache[r]}},{key:"setLayerConfig",value:function(r,n,t){this.layerConfigCache[n]=(0,Se.Z)({},gc({},this.sceneConfigCache[r],tc,t))}},{key:"getAttributeConfig",value:function(r){return this.layerAttributeConfigCache[r]}},{key:"setAttributeConfig",value:function(r,n){this.layerAttributeConfigCache[r]=(0,Se.Z)((0,Se.Z)({},this.layerAttributeConfigCache[r]),n)}},{key:"clean",value:function(){this.sceneConfigCache={},this.layerConfigCache={}}}]),e}())||pa);function _(e,i,r,n){r&&Object.defineProperty(e,i,{enumerable:r.enumerable,configurable:r.configurable,writable:r.writable,value:r.initializer?r.initializer.call(n):void 0})}function d(e,i,r,n,t){var a={};return Object.keys(n).forEach(function(u){a[u]=n[u]}),a.enumerable=!!a.enumerable,a.configurable=!!a.configurable,("value"in a||a.initializer)&&(a.writable=!0),a=r.slice().reverse().reduce(function(u,c){return c(e,i,u)||u},a),t&&a.initializer!==void 0&&(a.value=a.initializer?a.initializer.call(t):void 0,a.initializer=void 0),a.initializer===void 0&&(Object.defineProperty(e,i,a),a=null),a}function C(){var e=new xh(4);return xh!=Float32Array&&(e[0]=0,e[1]=0,e[2]=0,e[3]=0),e}function G(e){var i=new glMatrix.ARRAY_TYPE(4);return i[0]=e[0],i[1]=e[1],i[2]=e[2],i[3]=e[3],i}function de(e,i,r,n){var t=new xh(4);return t[0]=e,t[1]=i,t[2]=r,t[3]=n,t}function Te(e,i){return e[0]=i[0],e[1]=i[1],e[2]=i[2],e[3]=i[3],e}function Re(e,i,r,n,t){return e[0]=i,e[1]=r,e[2]=n,e[3]=t,e}function ht(e,i,r){return e[0]=i[0]+r[0],e[1]=i[1]+r[1],e[2]=i[2]+r[2],e[3]=i[3]+r[3],e}function Mt(e,i,r){return e[0]=i[0]-r[0],e[1]=i[1]-r[1],e[2]=i[2]-r[2],e[3]=i[3]-r[3],e}function Yt(e,i,r){return e[0]=i[0]*r[0],e[1]=i[1]*r[1],e[2]=i[2]*r[2],e[3]=i[3]*r[3],e}function br(e,i,r){return e[0]=i[0]/r[0],e[1]=i[1]/r[1],e[2]=i[2]/r[2],e[3]=i[3]/r[3],e}function Ir(e,i){return e[0]=Math.ceil(i[0]),e[1]=Math.ceil(i[1]),e[2]=Math.ceil(i[2]),e[3]=Math.ceil(i[3]),e}function Z(e,i){return e[0]=Math.floor(i[0]),e[1]=Math.floor(i[1]),e[2]=Math.floor(i[2]),e[3]=Math.floor(i[3]),e}function z(e,i,r){return e[0]=Math.min(i[0],r[0]),e[1]=Math.min(i[1],r[1]),e[2]=Math.min(i[2],r[2]),e[3]=Math.min(i[3],r[3]),e}function Q(e,i,r){return e[0]=Math.max(i[0],r[0]),e[1]=Math.max(i[1],r[1]),e[2]=Math.max(i[2],r[2]),e[3]=Math.max(i[3],r[3]),e}function Pe(e,i){return e[0]=Math.round(i[0]),e[1]=Math.round(i[1]),e[2]=Math.round(i[2]),e[3]=Math.round(i[3]),e}function Pt(e,i,r){return e[0]=i[0]*r,e[1]=i[1]*r,e[2]=i[2]*r,e[3]=i[3]*r,e}function tr(e,i,r,n){return e[0]=i[0]+r[0]*n,e[1]=i[1]+r[1]*n,e[2]=i[2]+r[2]*n,e[3]=i[3]+r[3]*n,e}function Sr(e,i){var r=i[0]-e[0],n=i[1]-e[1],t=i[2]-e[2],a=i[3]-e[3];return Math.hypot(r,n,t,a)}function Dr(e,i){var r=i[0]-e[0],n=i[1]-e[1],t=i[2]-e[2],a=i[3]-e[3];return r*r+n*n+t*t+a*a}function Kr(e){var i=e[0],r=e[1],n=e[2],t=e[3];return Math.hypot(i,r,n,t)}function Zn(e){var i=e[0],r=e[1],n=e[2],t=e[3];return i*i+r*r+n*n+t*t}function ai(e,i){return e[0]=-i[0],e[1]=-i[1],e[2]=-i[2],e[3]=-i[3],e}function Va(e,i){return e[0]=1/i[0],e[1]=1/i[1],e[2]=1/i[2],e[3]=1/i[3],e}function za(e,i){var r=i[0],n=i[1],t=i[2],a=i[3],u=r*r+n*n+t*t+a*a;return u>0&&(u=1/Math.sqrt(u)),e[0]=r*u,e[1]=n*u,e[2]=t*u,e[3]=a*u,e}function ua(e,i){return e[0]*i[0]+e[1]*i[1]+e[2]*i[2]+e[3]*i[3]}function Za(e,i,r,n){var t=r[0]*n[1]-r[1]*n[0],a=r[0]*n[2]-r[2]*n[0],u=r[0]*n[3]-r[3]*n[0],c=r[1]*n[2]-r[2]*n[1],m=r[1]*n[3]-r[3]*n[1],E=r[2]*n[3]-r[3]*n[2],H=i[0],re=i[1],xe=i[2],ke=i[3];return e[0]=re*E-xe*m+ke*c,e[1]=-(H*E)+xe*u-ke*a,e[2]=H*m-re*u+ke*t,e[3]=-(H*c)+re*a-xe*t,e}function rs(e,i,r,n){var t=i[0],a=i[1],u=i[2],c=i[3];return e[0]=t+n*(r[0]-t),e[1]=a+n*(r[1]-a),e[2]=u+n*(r[2]-u),e[3]=c+n*(r[3]-c),e}function os(e,i){i=i||1;var r,n,t,a,u,c;do r=glMatrix.RANDOM()*2-1,n=glMatrix.RANDOM()*2-1,u=r*r+n*n;while(u>=1);do t=glMatrix.RANDOM()*2-1,a=glMatrix.RANDOM()*2-1,c=t*t+a*a;while(c>=1);var m=Math.sqrt((1-u)/c);return e[0]=i*r,e[1]=i*n,e[2]=i*t*m,e[3]=i*a*m,e}function Ua(e,i,r){var n=i[0],t=i[1],a=i[2],u=i[3];return e[0]=r[0]*n+r[4]*t+r[8]*a+r[12]*u,e[1]=r[1]*n+r[5]*t+r[9]*a+r[13]*u,e[2]=r[2]*n+r[6]*t+r[10]*a+r[14]*u,e[3]=r[3]*n+r[7]*t+r[11]*a+r[15]*u,e}function us(e,i,r){var n=i[0],t=i[1],a=i[2],u=r[0],c=r[1],m=r[2],E=r[3],H=E*n+c*a-m*t,re=E*t+m*n-u*a,xe=E*a+u*t-c*n,ke=-u*n-c*t-m*a;return e[0]=H*E+ke*-u+re*-m-xe*-c,e[1]=re*E+ke*-c+xe*-u-H*-m,e[2]=xe*E+ke*-m+H*-c-re*-u,e[3]=i[3],e}function Xu(e){return e[0]=0,e[1]=0,e[2]=0,e[3]=0,e}function _u(e){return"vec4("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")"}function Uc(e,i){return e[0]===i[0]&&e[1]===i[1]&&e[2]===i[2]&&e[3]===i[3]}function ah(e,i){var r=e[0],n=e[1],t=e[2],a=e[3],u=i[0],c=i[1],m=i[2],E=i[3];return Math.abs(r-u)<=glMatrix.EPSILON*Math.max(1,Math.abs(r),Math.abs(u))&&Math.abs(n-c)<=glMatrix.EPSILON*Math.max(1,Math.abs(n),Math.abs(c))&&Math.abs(t-m)<=glMatrix.EPSILON*Math.max(1,Math.abs(t),Math.abs(m))&&Math.abs(a-E)<=glMatrix.EPSILON*Math.max(1,Math.abs(a),Math.abs(E))}var gf=null,sh=null,sp=null,Ld=null,ep=null,up=null,Ap=null,a0=function(){var e=C();return function(i,r,n,t,a,u){var c,m;for(r||(r=4),n||(n=0),t?m=Math.min(t*r+n,i.length):m=i.length,c=n;c0){var m=c.changedTouches[0];n.onHover({clientX:m.clientX,clientY:m.clientY,type:"touchend"})}}),(0,St.Z)((0,Fr.Z)(n),"onTouchMove",function(c){var m=c.changedTouches[0];n.onHover({clientX:m.clientX,clientY:m.clientY,type:"touchmove"})}),(0,St.Z)((0,Fr.Z)(n),"onHover",function(c){var m=c.clientX,E=c.clientY,H=m,re=E,xe=c.type,ke=n.mapService.getMapContainer();if(ke){var rt=ke.getBoundingClientRect(),vt=rt.top,It=rt.left;H=H-It-ke.clientLeft,re=re-vt-ke.clientTop}var er=n.mapService.containerToLngLat([H,re]);if(xe==="click"){n.isDoubleTap(H,re,er);return}if(xe==="touch"){n.isDoubleTap(H,re,er);return}xe!=="click"&&xe!=="dblclick"&&n.emit(Du.Hover,{x:H,y:re,lngLat:er,type:xe,target:c})}),n}return(0,ot.Z)(r,[{key:"init",value:function(){this.addEventListenerOnMap(),this.$containter=this.mapService.getMapContainer()}},{key:"destroy",value:function(){this.hammertime&&this.hammertime.destroy(),this.removeEventListenerOnMap(),this.off(Du.Hover)}},{key:"triggerHover",value:function(t){var a=t.x,u=t.y;this.emit(Du.Hover,{x:a,y:u})}},{key:"triggerSelect",value:function(t){this.emit(Du.Select,{featureId:t})}},{key:"triggerActive",value:function(t){this.emit(Du.Active,{featureId:t})}},{key:"addEventListenerOnMap",value:function(){var t=this.mapService.getMapContainer();if(t){var a=new($s()).Manager(t);a.add(new($s()).Tap({event:"dblclick",taps:2})),a.add(new($s()).Tap({event:"click"})),a.add(new($s()).Pan({threshold:0,pointers:0})),a.add(new($s()).Press({})),a.on("dblclick click",this.onHammer),a.on("panstart panmove panend pancancel",this.onDrag),t.addEventListener("touchstart",this.onTouch),t.addEventListener("touchend",this.onTouchEnd),t.addEventListener("touchmove",this.onTouchMove),t.addEventListener("mousedown",this.onHover,!0),t.addEventListener("mouseup",this.onHover),t.addEventListener("contextmenu",this.onHover),this.hammertime=a}}},{key:"removeEventListenerOnMap",value:function(){var t=this.mapService.getMapContainer();t&&(t.removeEventListener("mousemove",this.onHover),this.hammertime.off("dblclick click",this.onHammer),this.hammertime.off("panstart panmove panend pancancel",this.onDrag),t.removeEventListener("touchstart",this.onTouch),t.removeEventListener("touchend",this.onTouchEnd),t.removeEventListener("mousedown",this.onHover),t.removeEventListener("mouseup",this.onHover),t.removeEventListener("contextmenu",this.onHover))}},{key:"interactionEvent",value:function(t){var a=t.type,u=t.pointerType,c,m;u==="touch"?(m=Math.floor(t.pointers[0].clientY),c=Math.floor(t.pointers[0].clientX)):(m=Math.floor(t.srcEvent.y),c=Math.floor(t.srcEvent.x));var E=this.mapService.getMapContainer();if(E){var H=E.getBoundingClientRect(),re=H.top,xe=H.left;c-=xe,m-=re}var ke=this.mapService.containerToLngLat([c,m]);return{x:c,y:m,lngLat:ke,type:a,target:t.srcEvent}}},{key:"isDoubleTap",value:function(t,a,u){var c=this,m=new Date().getTime(),E="click";m-this.lastClickTime<400&&Math.abs(this.lastClickXY[0]-t)<10&&Math.abs(this.lastClickXY[1]-a)<10?(this.lastClickTime=0,this.lastClickXY=[-1,-1],this.clickTimer&&clearTimeout(this.clickTimer),E="dblclick",this.emit(Du.Hover,{x:t,y:a,lngLat:u,type:E})):(this.lastClickTime=m,this.lastClickXY=[t,a],this.clickTimer=setTimeout(function(){E="click",c.emit(Du.Hover,{x:t,y:a,lngLat:u,type:E})},400))}}]),r}(fu()),cf=d(Nf.prototype,"mapService",[Wl],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),Nf))||yf),mf=0;function Dh(e){var i=e;if(typeof e=="string"&&(i=document.getElementById(e)),i){var r=document.createElement("div");return r.style.cssText+=` + position: absolute; + z-index:2; + height: 100%; + width: 100%; + pointer-events: none; + `,r.id="l7-scene-".concat(mf++),r.classList.add("l7-scene"),i.appendChild(r),r}return null}function lh(e){var i,r=!0;if((e==null||(i=e.target)===null||i===void 0?void 0:i.target)instanceof HTMLElement)for(var n,t=e==null||(n=e.target)===null||n===void 0?void 0:n.target;t;){var a,u=Array.from(t.classList);if(u.includes("l7-marker")||u.includes("l7-popup")){r=!1;break}t=(a=t)===null||a===void 0?void 0:a.parentElement}return r}var Eh=function(e){return e[e.SAMPLED=0]="SAMPLED",e[e.RENDER_TARGET=1]="RENDER_TARGET",e}({}),Uh,Qi,Yn,Ti,ca,Qa,Oa,Xl,Vc,Pf,$d,qh,Xd;function wm(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=Oy(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function Oy(e,i){if(e){if(typeof e=="string")return qv(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return qv(e,i)}}function qv(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);rIt-1*Co||Ln<0||wn>er-1*Co||wn<0)){fs.next=11;break}return fs.abrupt("return",!1);case 11:return fs.next=13,ke({x:Math.floor(Ln/i.pickBufferScale),y:Math.floor((er-(c+1)*Co)/i.pickBufferScale),width:1,height:1,data:new Uint8Array(4),framebuffer:i.pickingFBO});case 13:return Cn=fs.sent,i.pickedColors=Cn,Cn[0]!==0||Cn[1]!==0||Cn[2]!==0?(qn=eo(Cn),Si=t.layerPickService.getFeatureById(qn),qn!==t.getCurrentPickId()&&E==="mousemove"&&(E="mouseenter"),po={x:u,y:c,type:E,lngLat:m,featureId:qn,feature:Si,target:H},Si&&(re=!0,t.setCurrentPickId(qn),i.triggerHoverOnLayer(t,po))):(Ao={x:u,y:c,lngLat:m,type:t.getCurrentPickId()!==null&&E==="mousemove"?"mouseout":"un"+E,featureId:null,target:H,feature:null},i.triggerHoverOnLayer(t,(0,Se.Z)((0,Se.Z)({},Ao),{},{type:"unpick"})),i.triggerHoverOnLayer(t,Ao),t.setCurrentPickId(null)),Or&&t.layerPickService.highlightPickedFeature(Cn),rn&&E==="click"&&(Cn==null?void 0:Cn.toString())!==[0,0,0,0].toString()&&(ma=eo(Cn),t.getCurrentSelectedId()===null||ma!==t.getCurrentSelectedId()?(t.layerPickService.selectFeature(Cn),t.setCurrentSelectedId(ma)):(t.layerPickService.selectFeature(new Uint8Array([0,0,0,0])),t.setCurrentSelectedId(null))),fs.abrupt("return",re);case 19:case"end":return fs.stop()}},n)}));return function(n,t){return r.apply(this,arguments)}}())}return(0,ot.Z)(e,[{key:"init",value:function(r){var n=this.rendererService,t=n.createTexture2D,a=n.createFramebuffer,u=n.getContainer,c=this.getContainerSize(u()),m=c.width,E=c.height;m*=Co,E*=Co,this.pickBufferScale=this.configService.getSceneConfig(r).pickBufferScale||1,m=Math.round(m/this.pickBufferScale),E=Math.round(E/this.pickBufferScale);var H=t({width:m,height:E,usage:Eh.RENDER_TARGET,label:"Picking Texture"});this.pickingFBO=a({color:H,depth:!0,width:m,height:E}),this.interactionService.on(Du.Hover,this.pickingAllLayer.bind(this))}},{key:"boxPickLayer",value:function(){var i=(0,Li.Z)(Ur().mark(function n(t,a,u){var c=this,m,E,H,re;return Ur().wrap(function(ke){for(;;)switch(ke.prev=ke.next){case 0:return m=this.rendererService,E=m.useFramebufferAsync,H=m.clear,this.resizePickingFBO(),t.hooks.beforePickingEncode.call(),ke.next=5,E(this.pickingFBO,(0,Li.Z)(Ur().mark(function rt(){return Ur().wrap(function(It){for(;;)switch(It.prev=It.next){case 0:H({framebuffer:c.pickingFBO,color:[0,0,0,0],stencil:0,depth:1}),t.renderModels({ispick:!0});case 2:case"end":return It.stop()}},rt)})));case 5:return t.hooks.afterPickingEncode.call(),ke.next=8,this.pickBox(t,a);case 8:re=ke.sent,u(re);case 10:case"end":return ke.stop()}},n,this)}));function r(n,t,a){return i.apply(this,arguments)}return r}()},{key:"pickBox",value:function(){var i=(0,Li.Z)(Ur().mark(function n(t,a){var u=this,c,m,E,H,re,xe,ke,rt,vt,It,er,Ar,Or,rn,Ln,wn,Cn,qn,Si,po,Ao;return Ur().wrap(function(Ya){for(;;)switch(Ya.prev=Ya.next){case 0:if(c=a.map(function(fs){var bf=fs<0?0:fs;return Math.floor(bf*Co/u.pickBufferScale)}),m=(0,gi.Z)(c,4),E=m[0],H=m[1],re=m[2],xe=m[3],ke=this.rendererService,rt=ke.readPixelsAsync,vt=ke.getContainer,It=this.getContainerSize(vt()),er=It.width,Ar=It.height,er*=Co,Ar*=Co,!(E>(er-1)*Co/this.pickBufferScale||re<0||H>(Ar-1)*Co/this.pickBufferScale||xe<0)){Ya.next=7;break}return Ya.abrupt("return",[]);case 7:return Or=Math.min(er/this.pickBufferScale,re)-E,rn=Math.min(Ar/this.pickBufferScale,xe)-H,Ya.next=11,rt({x:E,y:Math.floor(Ar/this.pickBufferScale-(xe+1)),width:Or,height:rn,data:new Uint8Array(Or*rn*4),framebuffer:this.pickingFBO});case 11:for(Ln=Ya.sent,wn=[],Cn={},qn=0;qn0&&arguments[0]!==void 0?arguments[0]:!0;(0,We.Z)(this,e),(0,St.Z)(this,"autoStart",void 0),(0,St.Z)(this,"startTime",0),(0,St.Z)(this,"oldTime",0),(0,St.Z)(this,"running",!1),(0,St.Z)(this,"elapsedTime",0),this.autoStart=i}return(0,ot.Z)(e,[{key:"start",value:function(){this.startTime=(typeof performance=="undefined"?Date:performance).now(),this.oldTime=this.startTime,this.elapsedTime=0,this.running=!0}},{key:"stop",value:function(){this.getElapsedTime(),this.running=!1,this.autoStart=!1}},{key:"getElapsedTime",value:function(){return this.getDelta(),this.elapsedTime}},{key:"getDelta",value:function(){var r=0;if(this.autoStart&&!this.running)return this.start(),0;if(this.running){var n=(typeof performance=="undefined"?Date:performance).now();r=(n-this.oldTime)/1e3,this.oldTime=n,this.elapsedTime+=r}return r}}]),e}(),Qg,Ly,Ag,Jg,Dy,Nv,ey,bg,qm;function lv(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=h1(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function h1(e,i){if(e){if(typeof e=="string")return zv(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return zv(e,i)}}function zv(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r-1&&c.layerChildren.splice(m,1)):(E=this.layers.indexOf(u),E>-1&&this.layers.splice(E,1)),u.destroy(),this.reRender(),this.emit("layerChange",this.layers);case 4:case"end":return re.stop()}},a,this)}));function t(a,u){return n.apply(this,arguments)}return t}()},{key:"removeAllLayers",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:this.destroy(),this.reRender();case 2:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"setEnableRender",value:function(t){this.enableRender=t}},{key:"renderLayers",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E,H,re,xe,ke,rt;return Ur().wrap(function(It){for(;;)switch(It.prev=It.next){case 0:if(!(this.alreadyInRendering||!this.enableRender)){It.next=2;break}return It.abrupt("return");case 2:this.updateLayerRenderList(),u=this.debugService.generateRenderUid(),this.debugService.renderStart(u),this.alreadyInRendering=!0,this.clear(),c=lv(this.layerList);try{for(c.s();!(m=c.n()).done;)E=m.value,E.prerender()}catch(er){c.e(er)}finally{c.f()}this.renderService.beginFrame(),H=lv(this.layerList),It.prev=11,H.s();case 13:if((re=H.n()).done){It.next=25;break}if(xe=re.value,ke=xe.getLayerConfig(),rt=ke.enableMask,xe.masks.filter(function(er){return er.inited}).length>0&&rt&&this.renderMask(xe.masks),!xe.getLayerConfig().enableMultiPassRenderer){It.next=22;break}return It.next=20,xe.renderMultiPass();case 20:It.next=23;break;case 22:xe.render();case 23:It.next=13;break;case 25:It.next=30;break;case 27:It.prev=27,It.t0=It.catch(11),H.e(It.t0);case 30:return It.prev=30,H.f(),It.finish(30);case 33:this.renderService.endFrame(),this.debugService.renderEnd(u),this.alreadyInRendering=!1;case 36:case"end":return It.stop()}},a,this,[[11,27,30,33]])}));function t(){return n.apply(this,arguments)}return t}()},{key:"renderMask",value:function(t){var a=0;this.renderService.clear({stencil:0,depth:1,framebuffer:null});var u=t.length>1?ec.MULTIPLE:ec.SINGLE,c=lv(t),m;try{for(c.s();!(m=c.n()).done;){var E=m.value;E.render({isStencil:!0,stencilType:u,stencilIndex:a++})}}catch(H){c.e(H)}finally{c.f()}}},{key:"beforeRenderData",value:function(){var n=(0,Li.Z)(Ur().mark(function a(u){var c;return Ur().wrap(function(E){for(;;)switch(E.prev=E.next){case 0:return E.next=2,u.hooks.beforeRenderData.promise();case 2:c=E.sent,c&&this.renderLayers();case 4:case"end":return E.stop()}},a,this)}));function t(a){return n.apply(this,arguments)}return t}()},{key:"renderTileLayerMask",value:function(t){var a=0,u=t.getLayerConfig(),c=u.enableMask,m=c===void 0?!0:c,E=t.tileMask?1:0,H=t.masks.filter(function(vt){return vt.inited});E=E+(m?H.length:1);var re=E>1?ec.MULTIPLE:ec.SINGLE;if((t.tileMask||H.length&&m)&&this.renderService.clear({stencil:0,depth:1,framebuffer:null}),H.length&&m){var xe=lv(H),ke;try{for(xe.s();!(ke=xe.n()).done;){var rt=ke.value;rt.render({isStencil:!0,stencilType:re,stencilIndex:a++})}}catch(vt){xe.e(vt)}finally{xe.f()}}t.tileMask&&t.tileMask.render({isStencil:!0,stencilType:re,stencilIndex:a++,stencilOperation:Jc.OR})}},{key:"renderTileLayer",value:function(){var n=(0,Li.Z)(Ur().mark(function a(u){return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:if(this.renderTileLayerMask(u),!u.getLayerConfig().enableMultiPassRenderer){m.next=6;break}return m.next=4,u.renderMultiPass();case 4:m.next=8;break;case 6:return m.next=8,u.render();case 8:case"end":return m.stop()}},a,this)}));function t(a){return n.apply(this,arguments)}return t}()},{key:"updateLayerRenderList",value:function(){var t=this;this.layerList=[],this.layers.filter(function(a){return a.inited}).filter(function(a){return a.isVisible()}).sort(function(a,u){return a.zIndex-u.zIndex}).forEach(function(a){t.layerList.push(a)})}},{key:"destroy",value:function(){this.layers.forEach(function(t){t.destroy()}),this.layers=[],this.layerList=[],this.emit("layerChange",this.layers)}},{key:"startAnimate",value:function(){this.animateInstanceCount++===0&&(this.clock.start(),this.runRender())}},{key:"stopAnimate",value:function(){--this.animateInstanceCount===0&&(this.stopRender(),this.clock.stop())}},{key:"getOESTextureFloat",value:function(){return this.renderService.extensionObject.OES_texture_float}},{key:"enableShaderPick",value:function(){this.shaderPicking=!0}},{key:"disableShaderPick",value:function(){this.shaderPicking=!1}},{key:"getShaderPickStat",value:function(){return this.shaderPicking}},{key:"clear",value:function(){var t=Lo(this.mapService.bgColor);this.renderService.clear({color:t,depth:1,stencil:0,framebuffer:null})}},{key:"runRender",value:function(){this.renderLayers(),this.layerRenderID=window.requestAnimationFrame(this.runRender.bind(this))}},{key:"stopRender",value:function(){window.cancelAnimationFrame(this.layerRenderID)}}]),r}(cu.EventEmitter),ey=d(Nv.prototype,"renderService",[Ly],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),bg=d(Nv.prototype,"mapService",[Ag],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),qm=d(Nv.prototype,"debugService",[Jg],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),Nv))||Dy),X0=A(56348),Er=function(e){return e[e.DEPTH_BUFFER_BIT=256]="DEPTH_BUFFER_BIT",e[e.STENCIL_BUFFER_BIT=1024]="STENCIL_BUFFER_BIT",e[e.COLOR_BUFFER_BIT=16384]="COLOR_BUFFER_BIT",e[e.POINTS=0]="POINTS",e[e.LINES=1]="LINES",e[e.LINE_LOOP=2]="LINE_LOOP",e[e.LINE_STRIP=3]="LINE_STRIP",e[e.TRIANGLES=4]="TRIANGLES",e[e.TRIANGLE_STRIP=5]="TRIANGLE_STRIP",e[e.TRIANGLE_FAN=6]="TRIANGLE_FAN",e[e.ZERO=0]="ZERO",e[e.ONE=1]="ONE",e[e.SRC_COLOR=768]="SRC_COLOR",e[e.ONE_MINUS_SRC_COLOR=769]="ONE_MINUS_SRC_COLOR",e[e.SRC_ALPHA=770]="SRC_ALPHA",e[e.ONE_MINUS_SRC_ALPHA=771]="ONE_MINUS_SRC_ALPHA",e[e.DST_ALPHA=772]="DST_ALPHA",e[e.ONE_MINUS_DST_ALPHA=773]="ONE_MINUS_DST_ALPHA",e[e.DST_COLOR=774]="DST_COLOR",e[e.ONE_MINUS_DST_COLOR=775]="ONE_MINUS_DST_COLOR",e[e.SRC_ALPHA_SATURATE=776]="SRC_ALPHA_SATURATE",e[e.FUNC_ADD=32774]="FUNC_ADD",e[e.BLEND_EQUATION=32777]="BLEND_EQUATION",e[e.BLEND_EQUATION_RGB=32777]="BLEND_EQUATION_RGB",e[e.BLEND_EQUATION_ALPHA=34877]="BLEND_EQUATION_ALPHA",e[e.FUNC_SUBTRACT=32778]="FUNC_SUBTRACT",e[e.FUNC_REVERSE_SUBTRACT=32779]="FUNC_REVERSE_SUBTRACT",e[e.MAX_EXT=32776]="MAX_EXT",e[e.MIN_EXT=32775]="MIN_EXT",e[e.BLEND_DST_RGB=32968]="BLEND_DST_RGB",e[e.BLEND_SRC_RGB=32969]="BLEND_SRC_RGB",e[e.BLEND_DST_ALPHA=32970]="BLEND_DST_ALPHA",e[e.BLEND_SRC_ALPHA=32971]="BLEND_SRC_ALPHA",e[e.CONSTANT_COLOR=32769]="CONSTANT_COLOR",e[e.ONE_MINUS_CONSTANT_COLOR=32770]="ONE_MINUS_CONSTANT_COLOR",e[e.CONSTANT_ALPHA=32771]="CONSTANT_ALPHA",e[e.ONE_MINUS_CONSTANT_ALPHA=32772]="ONE_MINUS_CONSTANT_ALPHA",e[e.BLEND_COLOR=32773]="BLEND_COLOR",e[e.ARRAY_BUFFER=34962]="ARRAY_BUFFER",e[e.ELEMENT_ARRAY_BUFFER=34963]="ELEMENT_ARRAY_BUFFER",e[e.ARRAY_BUFFER_BINDING=34964]="ARRAY_BUFFER_BINDING",e[e.ELEMENT_ARRAY_BUFFER_BINDING=34965]="ELEMENT_ARRAY_BUFFER_BINDING",e[e.STREAM_DRAW=35040]="STREAM_DRAW",e[e.STATIC_DRAW=35044]="STATIC_DRAW",e[e.DYNAMIC_DRAW=35048]="DYNAMIC_DRAW",e[e.BUFFER_SIZE=34660]="BUFFER_SIZE",e[e.BUFFER_USAGE=34661]="BUFFER_USAGE",e[e.CURRENT_VERTEX_ATTRIB=34342]="CURRENT_VERTEX_ATTRIB",e[e.FRONT=1028]="FRONT",e[e.BACK=1029]="BACK",e[e.FRONT_AND_BACK=1032]="FRONT_AND_BACK",e[e.CULL_FACE=2884]="CULL_FACE",e[e.BLEND=3042]="BLEND",e[e.DITHER=3024]="DITHER",e[e.STENCIL_TEST=2960]="STENCIL_TEST",e[e.DEPTH_TEST=2929]="DEPTH_TEST",e[e.SCISSOR_TEST=3089]="SCISSOR_TEST",e[e.POLYGON_OFFSET_FILL=32823]="POLYGON_OFFSET_FILL",e[e.SAMPLE_ALPHA_TO_COVERAGE=32926]="SAMPLE_ALPHA_TO_COVERAGE",e[e.SAMPLE_COVERAGE=32928]="SAMPLE_COVERAGE",e[e.NO_ERROR=0]="NO_ERROR",e[e.INVALID_ENUM=1280]="INVALID_ENUM",e[e.INVALID_VALUE=1281]="INVALID_VALUE",e[e.INVALID_OPERATION=1282]="INVALID_OPERATION",e[e.OUT_OF_MEMORY=1285]="OUT_OF_MEMORY",e[e.CW=2304]="CW",e[e.CCW=2305]="CCW",e[e.LINE_WIDTH=2849]="LINE_WIDTH",e[e.ALIASED_POINT_SIZE_RANGE=33901]="ALIASED_POINT_SIZE_RANGE",e[e.ALIASED_LINE_WIDTH_RANGE=33902]="ALIASED_LINE_WIDTH_RANGE",e[e.CULL_FACE_MODE=2885]="CULL_FACE_MODE",e[e.FRONT_FACE=2886]="FRONT_FACE",e[e.DEPTH_RANGE=2928]="DEPTH_RANGE",e[e.DEPTH_WRITEMASK=2930]="DEPTH_WRITEMASK",e[e.DEPTH_CLEAR_VALUE=2931]="DEPTH_CLEAR_VALUE",e[e.DEPTH_FUNC=2932]="DEPTH_FUNC",e[e.STENCIL_CLEAR_VALUE=2961]="STENCIL_CLEAR_VALUE",e[e.STENCIL_FUNC=2962]="STENCIL_FUNC",e[e.STENCIL_FAIL=2964]="STENCIL_FAIL",e[e.STENCIL_PASS_DEPTH_FAIL=2965]="STENCIL_PASS_DEPTH_FAIL",e[e.STENCIL_PASS_DEPTH_PASS=2966]="STENCIL_PASS_DEPTH_PASS",e[e.STENCIL_REF=2967]="STENCIL_REF",e[e.STENCIL_VALUE_MASK=2963]="STENCIL_VALUE_MASK",e[e.STENCIL_WRITEMASK=2968]="STENCIL_WRITEMASK",e[e.STENCIL_BACK_FUNC=34816]="STENCIL_BACK_FUNC",e[e.STENCIL_BACK_FAIL=34817]="STENCIL_BACK_FAIL",e[e.STENCIL_BACK_PASS_DEPTH_FAIL=34818]="STENCIL_BACK_PASS_DEPTH_FAIL",e[e.STENCIL_BACK_PASS_DEPTH_PASS=34819]="STENCIL_BACK_PASS_DEPTH_PASS",e[e.STENCIL_BACK_REF=36003]="STENCIL_BACK_REF",e[e.STENCIL_BACK_VALUE_MASK=36004]="STENCIL_BACK_VALUE_MASK",e[e.STENCIL_BACK_WRITEMASK=36005]="STENCIL_BACK_WRITEMASK",e[e.VIEWPORT=2978]="VIEWPORT",e[e.SCISSOR_BOX=3088]="SCISSOR_BOX",e[e.COLOR_CLEAR_VALUE=3106]="COLOR_CLEAR_VALUE",e[e.COLOR_WRITEMASK=3107]="COLOR_WRITEMASK",e[e.UNPACK_ALIGNMENT=3317]="UNPACK_ALIGNMENT",e[e.PACK_ALIGNMENT=3333]="PACK_ALIGNMENT",e[e.MAX_TEXTURE_SIZE=3379]="MAX_TEXTURE_SIZE",e[e.MAX_VIEWPORT_DIMS=3386]="MAX_VIEWPORT_DIMS",e[e.SUBPIXEL_BITS=3408]="SUBPIXEL_BITS",e[e.RED_BITS=3410]="RED_BITS",e[e.GREEN_BITS=3411]="GREEN_BITS",e[e.BLUE_BITS=3412]="BLUE_BITS",e[e.ALPHA_BITS=3413]="ALPHA_BITS",e[e.DEPTH_BITS=3414]="DEPTH_BITS",e[e.STENCIL_BITS=3415]="STENCIL_BITS",e[e.POLYGON_OFFSET_UNITS=10752]="POLYGON_OFFSET_UNITS",e[e.POLYGON_OFFSET_FACTOR=32824]="POLYGON_OFFSET_FACTOR",e[e.TEXTURE_BINDING_2D=32873]="TEXTURE_BINDING_2D",e[e.SAMPLE_BUFFERS=32936]="SAMPLE_BUFFERS",e[e.SAMPLES=32937]="SAMPLES",e[e.SAMPLE_COVERAGE_VALUE=32938]="SAMPLE_COVERAGE_VALUE",e[e.SAMPLE_COVERAGE_INVERT=32939]="SAMPLE_COVERAGE_INVERT",e[e.COMPRESSED_TEXTURE_FORMATS=34467]="COMPRESSED_TEXTURE_FORMATS",e[e.DONT_CARE=4352]="DONT_CARE",e[e.FASTEST=4353]="FASTEST",e[e.NICEST=4354]="NICEST",e[e.GENERATE_MIPMAP_HINT=33170]="GENERATE_MIPMAP_HINT",e[e.BYTE=5120]="BYTE",e[e.UNSIGNED_BYTE=5121]="UNSIGNED_BYTE",e[e.SHORT=5122]="SHORT",e[e.UNSIGNED_SHORT=5123]="UNSIGNED_SHORT",e[e.INT=5124]="INT",e[e.UNSIGNED_INT=5125]="UNSIGNED_INT",e[e.FLOAT=5126]="FLOAT",e[e.DEPTH_COMPONENT=6402]="DEPTH_COMPONENT",e[e.ALPHA=6406]="ALPHA",e[e.RGB=6407]="RGB",e[e.RGBA=6408]="RGBA",e[e.LUMINANCE=6409]="LUMINANCE",e[e.LUMINANCE_ALPHA=6410]="LUMINANCE_ALPHA",e[e.RED=6403]="RED",e[e.UNSIGNED_SHORT_4_4_4_4=32819]="UNSIGNED_SHORT_4_4_4_4",e[e.UNSIGNED_SHORT_5_5_5_1=32820]="UNSIGNED_SHORT_5_5_5_1",e[e.UNSIGNED_SHORT_5_6_5=33635]="UNSIGNED_SHORT_5_6_5",e[e.FRAGMENT_SHADER=35632]="FRAGMENT_SHADER",e[e.VERTEX_SHADER=35633]="VERTEX_SHADER",e[e.MAX_VERTEX_ATTRIBS=34921]="MAX_VERTEX_ATTRIBS",e[e.MAX_VERTEX_UNIFORM_VECTORS=36347]="MAX_VERTEX_UNIFORM_VECTORS",e[e.MAX_VARYING_VECTORS=36348]="MAX_VARYING_VECTORS",e[e.MAX_COMBINED_TEXTURE_IMAGE_UNITS=35661]="MAX_COMBINED_TEXTURE_IMAGE_UNITS",e[e.MAX_VERTEX_TEXTURE_IMAGE_UNITS=35660]="MAX_VERTEX_TEXTURE_IMAGE_UNITS",e[e.MAX_TEXTURE_IMAGE_UNITS=34930]="MAX_TEXTURE_IMAGE_UNITS",e[e.MAX_FRAGMENT_UNIFORM_VECTORS=36349]="MAX_FRAGMENT_UNIFORM_VECTORS",e[e.SHADER_TYPE=35663]="SHADER_TYPE",e[e.DELETE_STATUS=35712]="DELETE_STATUS",e[e.LINK_STATUS=35714]="LINK_STATUS",e[e.VALIDATE_STATUS=35715]="VALIDATE_STATUS",e[e.ATTACHED_SHADERS=35717]="ATTACHED_SHADERS",e[e.ACTIVE_UNIFORMS=35718]="ACTIVE_UNIFORMS",e[e.ACTIVE_ATTRIBUTES=35721]="ACTIVE_ATTRIBUTES",e[e.SHADING_LANGUAGE_VERSION=35724]="SHADING_LANGUAGE_VERSION",e[e.CURRENT_PROGRAM=35725]="CURRENT_PROGRAM",e[e.NEVER=512]="NEVER",e[e.LESS=513]="LESS",e[e.EQUAL=514]="EQUAL",e[e.LEQUAL=515]="LEQUAL",e[e.GREATER=516]="GREATER",e[e.NOTEQUAL=517]="NOTEQUAL",e[e.GEQUAL=518]="GEQUAL",e[e.ALWAYS=519]="ALWAYS",e[e.KEEP=7680]="KEEP",e[e.REPLACE=7681]="REPLACE",e[e.INCR=7682]="INCR",e[e.DECR=7683]="DECR",e[e.INVERT=5386]="INVERT",e[e.INCR_WRAP=34055]="INCR_WRAP",e[e.DECR_WRAP=34056]="DECR_WRAP",e[e.VENDOR=7936]="VENDOR",e[e.RENDERER=7937]="RENDERER",e[e.VERSION=7938]="VERSION",e[e.NEAREST=9728]="NEAREST",e[e.LINEAR=9729]="LINEAR",e[e.NEAREST_MIPMAP_NEAREST=9984]="NEAREST_MIPMAP_NEAREST",e[e.LINEAR_MIPMAP_NEAREST=9985]="LINEAR_MIPMAP_NEAREST",e[e.NEAREST_MIPMAP_LINEAR=9986]="NEAREST_MIPMAP_LINEAR",e[e.LINEAR_MIPMAP_LINEAR=9987]="LINEAR_MIPMAP_LINEAR",e[e.TEXTURE_MAG_FILTER=10240]="TEXTURE_MAG_FILTER",e[e.TEXTURE_MIN_FILTER=10241]="TEXTURE_MIN_FILTER",e[e.TEXTURE_WRAP_S=10242]="TEXTURE_WRAP_S",e[e.TEXTURE_WRAP_T=10243]="TEXTURE_WRAP_T",e[e.TEXTURE_2D=3553]="TEXTURE_2D",e[e.TEXTURE=5890]="TEXTURE",e[e.TEXTURE_CUBE_MAP=34067]="TEXTURE_CUBE_MAP",e[e.TEXTURE_BINDING_CUBE_MAP=34068]="TEXTURE_BINDING_CUBE_MAP",e[e.TEXTURE_CUBE_MAP_POSITIVE_X=34069]="TEXTURE_CUBE_MAP_POSITIVE_X",e[e.TEXTURE_CUBE_MAP_NEGATIVE_X=34070]="TEXTURE_CUBE_MAP_NEGATIVE_X",e[e.TEXTURE_CUBE_MAP_POSITIVE_Y=34071]="TEXTURE_CUBE_MAP_POSITIVE_Y",e[e.TEXTURE_CUBE_MAP_NEGATIVE_Y=34072]="TEXTURE_CUBE_MAP_NEGATIVE_Y",e[e.TEXTURE_CUBE_MAP_POSITIVE_Z=34073]="TEXTURE_CUBE_MAP_POSITIVE_Z",e[e.TEXTURE_CUBE_MAP_NEGATIVE_Z=34074]="TEXTURE_CUBE_MAP_NEGATIVE_Z",e[e.MAX_CUBE_MAP_TEXTURE_SIZE=34076]="MAX_CUBE_MAP_TEXTURE_SIZE",e[e.TEXTURE0=33984]="TEXTURE0",e[e.TEXTURE1=33985]="TEXTURE1",e[e.TEXTURE2=33986]="TEXTURE2",e[e.TEXTURE3=33987]="TEXTURE3",e[e.TEXTURE4=33988]="TEXTURE4",e[e.TEXTURE5=33989]="TEXTURE5",e[e.TEXTURE6=33990]="TEXTURE6",e[e.TEXTURE7=33991]="TEXTURE7",e[e.TEXTURE8=33992]="TEXTURE8",e[e.TEXTURE9=33993]="TEXTURE9",e[e.TEXTURE10=33994]="TEXTURE10",e[e.TEXTURE11=33995]="TEXTURE11",e[e.TEXTURE12=33996]="TEXTURE12",e[e.TEXTURE13=33997]="TEXTURE13",e[e.TEXTURE14=33998]="TEXTURE14",e[e.TEXTURE15=33999]="TEXTURE15",e[e.TEXTURE16=34e3]="TEXTURE16",e[e.TEXTURE17=34001]="TEXTURE17",e[e.TEXTURE18=34002]="TEXTURE18",e[e.TEXTURE19=34003]="TEXTURE19",e[e.TEXTURE20=34004]="TEXTURE20",e[e.TEXTURE21=34005]="TEXTURE21",e[e.TEXTURE22=34006]="TEXTURE22",e[e.TEXTURE23=34007]="TEXTURE23",e[e.TEXTURE24=34008]="TEXTURE24",e[e.TEXTURE25=34009]="TEXTURE25",e[e.TEXTURE26=34010]="TEXTURE26",e[e.TEXTURE27=34011]="TEXTURE27",e[e.TEXTURE28=34012]="TEXTURE28",e[e.TEXTURE29=34013]="TEXTURE29",e[e.TEXTURE30=34014]="TEXTURE30",e[e.TEXTURE31=34015]="TEXTURE31",e[e.ACTIVE_TEXTURE=34016]="ACTIVE_TEXTURE",e[e.REPEAT=10497]="REPEAT",e[e.CLAMP_TO_EDGE=33071]="CLAMP_TO_EDGE",e[e.MIRRORED_REPEAT=33648]="MIRRORED_REPEAT",e[e.FLOAT_VEC2=35664]="FLOAT_VEC2",e[e.FLOAT_VEC3=35665]="FLOAT_VEC3",e[e.FLOAT_VEC4=35666]="FLOAT_VEC4",e[e.INT_VEC2=35667]="INT_VEC2",e[e.INT_VEC3=35668]="INT_VEC3",e[e.INT_VEC4=35669]="INT_VEC4",e[e.BOOL=35670]="BOOL",e[e.BOOL_VEC2=35671]="BOOL_VEC2",e[e.BOOL_VEC3=35672]="BOOL_VEC3",e[e.BOOL_VEC4=35673]="BOOL_VEC4",e[e.FLOAT_MAT2=35674]="FLOAT_MAT2",e[e.FLOAT_MAT3=35675]="FLOAT_MAT3",e[e.FLOAT_MAT4=35676]="FLOAT_MAT4",e[e.SAMPLER_2D=35678]="SAMPLER_2D",e[e.SAMPLER_CUBE=35680]="SAMPLER_CUBE",e[e.VERTEX_ATTRIB_ARRAY_ENABLED=34338]="VERTEX_ATTRIB_ARRAY_ENABLED",e[e.VERTEX_ATTRIB_ARRAY_SIZE=34339]="VERTEX_ATTRIB_ARRAY_SIZE",e[e.VERTEX_ATTRIB_ARRAY_STRIDE=34340]="VERTEX_ATTRIB_ARRAY_STRIDE",e[e.VERTEX_ATTRIB_ARRAY_TYPE=34341]="VERTEX_ATTRIB_ARRAY_TYPE",e[e.VERTEX_ATTRIB_ARRAY_NORMALIZED=34922]="VERTEX_ATTRIB_ARRAY_NORMALIZED",e[e.VERTEX_ATTRIB_ARRAY_POINTER=34373]="VERTEX_ATTRIB_ARRAY_POINTER",e[e.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING=34975]="VERTEX_ATTRIB_ARRAY_BUFFER_BINDING",e[e.COMPILE_STATUS=35713]="COMPILE_STATUS",e[e.LOW_FLOAT=36336]="LOW_FLOAT",e[e.MEDIUM_FLOAT=36337]="MEDIUM_FLOAT",e[e.HIGH_FLOAT=36338]="HIGH_FLOAT",e[e.LOW_INT=36339]="LOW_INT",e[e.MEDIUM_INT=36340]="MEDIUM_INT",e[e.HIGH_INT=36341]="HIGH_INT",e[e.FRAMEBUFFER=36160]="FRAMEBUFFER",e[e.RENDERBUFFER=36161]="RENDERBUFFER",e[e.RGBA4=32854]="RGBA4",e[e.RGB5_A1=32855]="RGB5_A1",e[e.RGB565=36194]="RGB565",e[e.DEPTH_COMPONENT16=33189]="DEPTH_COMPONENT16",e[e.STENCIL_INDEX=6401]="STENCIL_INDEX",e[e.STENCIL_INDEX8=36168]="STENCIL_INDEX8",e[e.DEPTH_STENCIL=34041]="DEPTH_STENCIL",e[e.RENDERBUFFER_WIDTH=36162]="RENDERBUFFER_WIDTH",e[e.RENDERBUFFER_HEIGHT=36163]="RENDERBUFFER_HEIGHT",e[e.RENDERBUFFER_INTERNAL_FORMAT=36164]="RENDERBUFFER_INTERNAL_FORMAT",e[e.RENDERBUFFER_RED_SIZE=36176]="RENDERBUFFER_RED_SIZE",e[e.RENDERBUFFER_GREEN_SIZE=36177]="RENDERBUFFER_GREEN_SIZE",e[e.RENDERBUFFER_BLUE_SIZE=36178]="RENDERBUFFER_BLUE_SIZE",e[e.RENDERBUFFER_ALPHA_SIZE=36179]="RENDERBUFFER_ALPHA_SIZE",e[e.RENDERBUFFER_DEPTH_SIZE=36180]="RENDERBUFFER_DEPTH_SIZE",e[e.RENDERBUFFER_STENCIL_SIZE=36181]="RENDERBUFFER_STENCIL_SIZE",e[e.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE=36048]="FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE",e[e.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME=36049]="FRAMEBUFFER_ATTACHMENT_OBJECT_NAME",e[e.FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL=36050]="FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL",e[e.FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE=36051]="FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE",e[e.COLOR_ATTACHMENT0=36064]="COLOR_ATTACHMENT0",e[e.DEPTH_ATTACHMENT=36096]="DEPTH_ATTACHMENT",e[e.STENCIL_ATTACHMENT=36128]="STENCIL_ATTACHMENT",e[e.DEPTH_STENCIL_ATTACHMENT=33306]="DEPTH_STENCIL_ATTACHMENT",e[e.NONE=0]="NONE",e[e.FRAMEBUFFER_COMPLETE=36053]="FRAMEBUFFER_COMPLETE",e[e.FRAMEBUFFER_INCOMPLETE_ATTACHMENT=36054]="FRAMEBUFFER_INCOMPLETE_ATTACHMENT",e[e.FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT=36055]="FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT",e[e.FRAMEBUFFER_INCOMPLETE_DIMENSIONS=36057]="FRAMEBUFFER_INCOMPLETE_DIMENSIONS",e[e.FRAMEBUFFER_UNSUPPORTED=36061]="FRAMEBUFFER_UNSUPPORTED",e[e.FRAMEBUFFER_BINDING=36006]="FRAMEBUFFER_BINDING",e[e.RENDERBUFFER_BINDING=36007]="RENDERBUFFER_BINDING",e[e.MAX_RENDERBUFFER_SIZE=34024]="MAX_RENDERBUFFER_SIZE",e[e.INVALID_FRAMEBUFFER_OPERATION=1286]="INVALID_FRAMEBUFFER_OPERATION",e[e.UNPACK_FLIP_Y_WEBGL=37440]="UNPACK_FLIP_Y_WEBGL",e[e.UNPACK_PREMULTIPLY_ALPHA_WEBGL=37441]="UNPACK_PREMULTIPLY_ALPHA_WEBGL",e[e.CONTEXT_LOST_WEBGL=37442]="CONTEXT_LOST_WEBGL",e[e.UNPACK_COLORSPACE_CONVERSION_WEBGL=37443]="UNPACK_COLORSPACE_CONVERSION_WEBGL",e[e.BROWSER_DEFAULT_WEBGL=37444]="BROWSER_DEFAULT_WEBGL",e}({}),wg=lo.isNil,ky=function(){function e(i){var r=this;(0,We.Z)(this,e),(0,St.Z)(this,"name",void 0),(0,St.Z)(this,"type",void 0),(0,St.Z)(this,"scale",void 0),(0,St.Z)(this,"descriptor",void 0),(0,St.Z)(this,"featureBufferLayout",[]),(0,St.Z)(this,"needRescale",!1),(0,St.Z)(this,"needRemapping",!1),(0,St.Z)(this,"needRegenerateVertices",!1),(0,St.Z)(this,"featureRange",{startIndex:0,endIndex:1/0}),(0,St.Z)(this,"vertexAttribute",void 0),(0,St.Z)(this,"defaultCallback",function(n){if(n.length===0){var t;return((t=r.scale)===null||t===void 0?void 0:t.defaultValues)||[]}return n.map(function(a,u){var c,m=(c=r.scale)===null||c===void 0?void 0:c.scalers[u].func,E=m(a);return E})}),this.setProps(i)}return(0,ot.Z)(e,[{key:"setProps",value:function(r){Object.assign(this,r)}},{key:"mapping",value:function(r){var n;if((n=this.scale)!==null&&n!==void 0&&n.callback){var t,a=(t=this.scale)===null||t===void 0?void 0:t.callback.apply(t,(0,On.Z)(r));if(!wg(a))return[a]}return this.defaultCallback(r)}},{key:"resetDescriptor",value:function(){this.descriptor&&(this.descriptor.buffer.data=[])}}]),e}(),_A=["buffer","update","name"],m1=["buffer","update","name"],Eg,ty,g_,v1,Qv,g1,AA=(Eg={},(0,St.Z)(Eg,Er.FLOAT,4),(0,St.Z)(Eg,Er.UNSIGNED_BYTE,1),(0,St.Z)(Eg,Er.UNSIGNED_SHORT,2),Eg),Fy=(ty=(0,sa.b2)(),g_=(0,sa.f3)(sr.IRendererService),ty(v1=(Qv=function(){function e(){(0,We.Z)(this,e),(0,St.Z)(this,"attributesAndIndices",void 0),_(this,"rendererService",g1,this),(0,St.Z)(this,"attributes",[]),(0,St.Z)(this,"triangulation",void 0),(0,St.Z)(this,"featureLayout",{sizePerElement:0,elements:[]})}return(0,ot.Z)(e,[{key:"registerStyleAttribute",value:function(r){var n=this.getLayerStyleAttribute(r.name||"");return n?n.setProps(r):(n=new ky(r),this.attributes.push(n)),n}},{key:"unRegisterStyleAttribute",value:function(r){var n=this.attributes.findIndex(function(t){return t.name===r});n>-1&&this.attributes.splice(n,1)}},{key:"updateScaleAttribute",value:function(r){this.attributes.forEach(function(n){var t,a=n.name,u=(t=n.scale)===null||t===void 0?void 0:t.field;(r[a]||u&&r[u])&&(n.needRescale=!0,n.needRemapping=!0,n.needRegenerateVertices=!0)})}},{key:"updateStyleAttribute",value:function(r,n,t){var a=this.getLayerStyleAttribute(r);a||(a=this.registerStyleAttribute((0,Se.Z)((0,Se.Z)({},n),{},{name:r})));var u=n.scale;u&&a&&(a.scale=u,a.needRescale=!0,a.needRemapping=!0,a.needRegenerateVertices=!0,t&&t.featureRange&&(a.featureRange=t.featureRange))}},{key:"getLayerStyleAttributes",value:function(){return this.attributes}},{key:"getLayerStyleAttribute",value:function(r){return this.attributes.find(function(n){return n.name===r})}},{key:"getLayerAttributeScale",value:function(r){var n,t=this.getLayerStyleAttribute(r),a=t==null||(n=t.scale)===null||n===void 0?void 0:n.scalers;return a&&a[0]?a[0].func:null}},{key:"updateAttributeByFeatureRange",value:function(r,n){var t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,a=arguments.length>3?arguments[3]:void 0,u=arguments.length>4?arguments[4]:void 0,c=this.attributes.find(function(Ln){return Ln.name===r});if(c&&c.descriptor){var m=c.descriptor,E=m.update,H=m.buffer,re=m.size,xe=re===void 0?0:re,ke=AA[H.type||Er.FLOAT];if(E){var rt=this.featureLayout,vt=rt.elements,It=rt.sizePerElement,er=vt.slice(t,a);if(!er.length)return;var Ar=er[0].offset,Or=Ar*xe*ke,rn=er.map(function(Ln,wn){for(var Cn=Ln.featureIdx,qn=Ln.vertices,Si=Ln.normals,po=qn.length/It,Ao=[],ma=0;ma0&&a[a.length-1])&&(E[0]===6||E[0]===2)){r=0;continue}if(E[0]===3&&(!a||E[1]>a[0]&&E[1]0)&&!(t=n.next()).done;)a.push(t.value)}catch(c){u={error:c}}finally{try{t&&!t.done&&(r=n.return)&&r.call(n)}finally{if(u)throw u.error}}return a}function By(e,i,r){if(r||arguments.length===2)for(var n=0,t=i.length,a;n=0&&n.length%1===0}e.exports=i.default})(ny,ny.exports);var Fm={},Ny={exports:{}},Tg={exports:{}};(function(e,i){Object.defineProperty(i,"__esModule",{value:!0}),i.default=function(r){return function(){for(var n=[],t=arguments.length;t--;)n[t]=arguments[t];var a=n.pop();return r.call(this,n,a)}},e.exports=i.default})(Tg,Tg.exports);var Mv={};Object.defineProperty(Mv,"__esModule",{value:!0}),Mv.fallback=Mg,Mv.wrap=zy;var b1=Mv.hasQueueMicrotask=typeof queueMicrotask=="function"&&queueMicrotask,bA=Mv.hasSetImmediate=typeof setImmediate=="function"&&setImmediate,xA=Mv.hasNextTick=typeof y1=="object"&&typeof y1.nextTick=="function";function Mg(e){setTimeout(e,0)}function zy(e){return function(i){for(var r=[],n=arguments.length-1;n-- >0;)r[n]=arguments[n+1];return e(function(){return i.apply(void 0,r)})}}var eg;b1?eg=queueMicrotask:bA?eg=setImmediate:xA?eg=y1.nextTick:eg=Mg,Mv.default=zy(eg),function(e,i){Object.defineProperty(i,"__esModule",{value:!0}),i.default=m;var r=Tg.exports,n=c(r),t=Mv,a=c(t),u=Fm;function c(re){return re&&re.__esModule?re:{default:re}}function m(re){return(0,u.isAsync)(re)?function(){for(var xe=[],ke=arguments.length;ke--;)xe[ke]=arguments[ke];var rt=xe.pop(),vt=re.apply(this,xe);return E(vt,rt)}:(0,n.default)(function(xe,ke){var rt;try{rt=re.apply(this,xe)}catch(vt){return ke(vt)}if(rt&&typeof rt.then=="function")return E(rt,ke);ke(null,rt)})}function E(re,xe){return re.then(function(ke){H(xe,null,ke)},function(ke){H(xe,ke&&ke.message?ke:new Error(ke))})}function H(re,xe,ke){try{re(xe,ke)}catch(rt){(0,a.default)(function(vt){throw vt},rt)}}e.exports=i.default}(Ny,Ny.exports),Object.defineProperty(Fm,"__esModule",{value:!0}),Fm.isAsyncIterable=Fm.isAsyncGenerator=Fm.isAsync=void 0;var x1=Ny.exports,y_=wA(x1);function wA(e){return e&&e.__esModule?e:{default:e}}function iy(e){return e[Symbol.toStringTag]==="AsyncFunction"}function EA(e){return e[Symbol.toStringTag]==="AsyncGenerator"}function __(e){return typeof e[Symbol.asyncIterator]=="function"}function SA(e){if(typeof e!="function")throw new Error("expected a function");return iy(e)?(0,y_.default)(e):e}Fm.default=SA,Fm.isAsync=iy,Fm.isAsyncGenerator=EA,Fm.isAsyncIterable=__;var tg={exports:{}};(function(e,i){Object.defineProperty(i,"__esModule",{value:!0}),i.default=r;function r(n,t){if(t===void 0&&(t=n.length),!t)throw new Error("arity is undefined");function a(){for(var u=this,c=[],m=arguments.length;m--;)c[m]=arguments[m];return typeof c[t-1]=="function"?n.apply(this,c):new Promise(function(E,H){c[t-1]=function(re){for(var xe=[],ke=arguments.length-1;ke-- >0;)xe[ke]=arguments[ke+1];if(re)return H(re);E(xe.length>1?xe:xe[0])},n.apply(u,c)})}return a}e.exports=i.default})(tg,tg.exports),function(e,i){Object.defineProperty(i,"__esModule",{value:!0});var r=ny.exports,n=m(r),t=Fm,a=m(t),u=tg.exports,c=m(u);function m(E){return E&&E.__esModule?E:{default:E}}i.default=(0,c.default)(function(E,H,re){var xe=(0,n.default)(H)?[]:{};E(H,function(ke,rt,vt){(0,a.default)(ke)(function(It){for(var er,Ar=[],Or=arguments.length-1;Or-- >0;)Ar[Or]=arguments[Or+1];Ar.length<2&&(er=Ar,Ar=er[0]),xe[rt]=Ar,vt(It)})},function(ke){return re(ke,xe)})},3),e.exports=i.default}(Cg,Cg.exports);var _v={exports:{}},rg={exports:{}},oy={exports:{}},Av={exports:{}};(function(e,i){Object.defineProperty(i,"__esModule",{value:!0}),i.default=r;function r(n){function t(){for(var a=[],u=arguments.length;u--;)a[u]=arguments[u];if(n!==null){var c=n;n=null,c.apply(this,a)}}return Object.assign(t,n),t}e.exports=i.default})(Av,Av.exports);var Zy={exports:{}},ay={exports:{}};(function(e,i){Object.defineProperty(i,"__esModule",{value:!0}),i.default=function(r){return r[Symbol.iterator]&&r[Symbol.iterator]()},e.exports=i.default})(ay,ay.exports),function(e,i){Object.defineProperty(i,"__esModule",{value:!0}),i.default=H;var r=ny.exports,n=u(r),t=ay.exports,a=u(t);function u(re){return re&&re.__esModule?re:{default:re}}function c(re){var xe=-1,ke=re.length;return function(){return++xe=c||xe||H||(xe=!0,u.next().then(function(Ar){var Or=Ar.value,rn=Ar.done;if(!(re||H)){if(xe=!1,rn){H=!0,ke<=0&&E(null);return}ke++,m(Or,rt,It),rt++,vt()}}).catch(er))}function It(Ar,Or){if(ke-=1,!re){if(Ar)return er(Ar);if(Ar===!1){H=!0,re=!0;return}if(Or===n.default||H&&ke<=0)return H=!0,E(null);vt()}}function er(Ar){re||(xe=!1,H=!0,E(Ar))}vt()}e.exports=i.default}(w1,w1.exports),function(e,i){Object.defineProperty(i,"__esModule",{value:!0});var r=Av.exports,n=ke(r),t=Zy.exports,a=ke(t),u=Pg.exports,c=ke(u),m=Fm,E=w1.exports,H=ke(E),re=sy.exports,xe=ke(re);function ke(rt){return rt&&rt.__esModule?rt:{default:rt}}i.default=function(rt){return function(vt,It,er){if(er=(0,n.default)(er),rt<=0)throw new RangeError("concurrency limit cannot be less than 1");if(!vt)return er(null);if((0,m.isAsyncGenerator)(vt))return(0,H.default)(vt,rt,It,er);if((0,m.isAsyncIterable)(vt))return(0,H.default)(vt[Symbol.asyncIterator](),rt,It,er);var Ar=(0,a.default)(vt),Or=!1,rn=!1,Ln=0,wn=!1;function Cn(Si,po){if(!rn)if(Ln-=1,Si)Or=!0,er(Si);else if(Si===!1)Or=!0,rn=!0;else{if(po===xe.default||Or&&Ln<=0)return Or=!0,er(null);wn||qn()}}function qn(){for(wn=!0;Ln0;)Ar[Or]=arguments[Or+1];if(er!==!1){if(er||rt===xe.length)return ke.apply(void 0,[er].concat(Ar));vt(Ar)}}vt([])}i.default=(0,E.default)(re),e.exports=i.default})(I,I.exports);var k=Jv(I.exports),Y=function(){function e(){this.tasks=[]}return e.prototype.call=function(){return k(this.tasks)},e.prototype.tap=function(i,r){this.tasks.length===0?this.tasks.push(function(n){var t=r();n(t?null:!1,t)}):this.tasks.push(function(n,t){var a=r.apply(void 0,By([],Sg(n),!1));t(a?null:!1,i)})},e}(),he=function(){function e(){this.tasks=[]}return e.prototype.call=function(){return Uy(this.tasks)},e.prototype.tap=function(i,r){this.tasks.push(function(n){var t=r();n(t,i)})},e}(),be=function(){function e(){this.args=[],this.tasks=[]}return e.prototype.promise=function(){for(var i=arguments,r=[],n=0;n1&&arguments[1]!==void 0?arguments[1]:!1,r={};return e=e.replace(C1,function(n,t,a){var u=a.split(":"),c=u[0].trim(),m="";switch(u.length>1&&(m=u[1].trim()),t){case"bool":m=m==="true";break;case"float":case"int":m=Number(m);break;case"vec2":case"vec3":case"vec4":case"ivec2":case"ivec3":case"ivec4":case"mat2":case"mat3":case"mat4":m?m=m.replace("[","").replace("]","").split(",").reduce(function(E,H){return E.push(Number(H.trim())),E},[]):m=new Array(ly(t)).fill(0);break;default:}return r[c]=m,"".concat(i?"uniform ":"").concat(t," ").concat(c,`; +`)}),{content:e,uniforms:r}}function $y(e){var i=Vy(e,!0),r=i.content,n=i.uniforms;return r=r.replace(/(\s*uniform\s*.*\s*){((?:\s*.*\s*)*?)};/g,function(t,a,u){u=u.trim().replace(/^.*$/gm,function(H){return"uniform ".concat(H)});var c=Vy(u),m=c.content,E=c.uniforms;return Object.assign(n,E),"".concat(a,`{ +`).concat(m,` +};`)}),{content:r,uniforms:n}}function Hy(e){var i={};return e.replace(C1,function(r,n,t){var a=t.trim();return i[a]?"":(i[a]=!0,"uniform ".concat(n," ").concat(a,`; +`))})}var TA,MA,U2=lo.uniq,PA="#define PI 3.14159265359",cE=`#define SHIFT_RIGHT17 1.0 / 131072.0 +#define SHIFT_RIGHT18 1.0 / 262144.0 +#define SHIFT_RIGHT19 1.0 / 524288.0 +#define SHIFT_RIGHT20 1.0 / 1048576.0 +#define SHIFT_RIGHT21 1.0 / 2097152.0 +#define SHIFT_RIGHT22 1.0 / 4194304.0 +#define SHIFT_RIGHT23 1.0 / 8388608.0 +#define SHIFT_RIGHT24 1.0 / 16777216.0 + +#define SHIFT_LEFT17 131072.0 +#define SHIFT_LEFT18 262144.0 +#define SHIFT_LEFT19 524288.0 +#define SHIFT_LEFT20 1048576.0 +#define SHIFT_LEFT21 2097152.0 +#define SHIFT_LEFT22 4194304.0 +#define SHIFT_LEFT23 8388608.0 +#define SHIFT_LEFT24 16777216.0 + +vec2 unpack_float(float packedValue) { + int packedIntValue = int(packedValue); + int v0 = packedIntValue / 256; + return vec2(v0, packedIntValue - v0 * 256); +} + +vec4 decode_color(vec2 encodedColor) { + return vec4( + unpack_float(encodedColor[0]) / 255.0, + unpack_float(encodedColor[1]) / 255.0 + ); +} +`,A_=`layout(std140) uniform SceneUniforms { + mat4 u_ViewMatrix; + mat4 u_ProjectionMatrix; + mat4 u_ViewProjectionMatrix; + mat4 u_ModelMatrix; + vec4 u_ViewportCenterProjection; + vec3 u_PixelsPerDegree; + float u_Zoom; + vec3 u_PixelsPerDegree2; + float u_ZoomScale; + vec3 u_PixelsPerMeter; + float u_CoordinateSystem; + vec3 u_CameraPosition; + float u_DevicePixelRatio; + vec2 u_ViewportCenter; + vec2 u_ViewportSize; + float u_FocalDistance; +}; + +layout(std140) uniform LayerUniforms { + mat4 u_Mvp; + vec2 u_sceneCenterMercator; +}; +`,Gy=`layout(std140) uniform PickingUniforms { + vec4 u_HighlightColor; + vec4 u_SelectColor; + vec3 u_PickingColor; + float u_PickingStage; + vec3 u_CurrentSelectedId; + float u_PickingThreshold; + float u_PickingBuffer; + float u_shaderPick; + float u_EnableSelect; + float u_activeMix; +};`,j2=`#define ambientRatio 0.5 +#define diffuseRatio 0.3 +#define specularRatio 0.2 + + +float calc_lighting(vec4 pos) { + + vec3 worldPos = vec3(pos * u_ModelMatrix); + + vec3 worldNormal = a_Normal; + // //cal light weight + vec3 viewDir = normalize(u_CameraPosition - worldPos); + + vec3 lightDir = normalize(vec3(1, -10.5, 12)); + + vec3 halfDir = normalize(viewDir+lightDir); + // //lambert + float lambert = dot(worldNormal, lightDir); + //specular + float specular = pow(max(0.0, dot(worldNormal, halfDir)), 32.0); + //sum to light weight + float lightWeight = ambientRatio + diffuseRatio * lambert + specularRatio * specular; + + return lightWeight; +} +`,V2=`// Blinn-Phong model +// apply lighting in vertex shader instead of fragment shader +// @see https://learnopengl.com/Advanced-Lighting/Advanced-Lighting +uniform float u_Ambient : 1.0; +uniform float u_Diffuse : 1.0; +uniform float u_Specular : 1.0; +uniform int u_NumOfDirectionalLights : 1; +uniform int u_NumOfSpotLights : 0; + +#define SHININESS 32.0 +#define MAX_NUM_OF_DIRECTIONAL_LIGHTS 3 +#define MAX_NUM_OF_SPOT_LIGHTS 3 + +struct DirectionalLight { + vec3 direction; + vec3 ambient; + vec3 diffuse; + vec3 specular; +}; + +struct SpotLight { + vec3 position; + vec3 direction; + vec3 ambient; + vec3 diffuse; + vec3 specular; + float constant; + float linear; + float quadratic; + float angle; + float blur; + float exponent; +}; + +uniform DirectionalLight u_DirectionalLights[MAX_NUM_OF_DIRECTIONAL_LIGHTS]; +uniform SpotLight u_SpotLights[MAX_NUM_OF_SPOT_LIGHTS]; + +vec3 calc_directional_light(DirectionalLight light, vec3 normal, vec3 viewDir) { + vec3 lightDir = normalize(light.direction); + // diffuse shading + float diff = max(dot(normal, lightDir), 0.0); + // Blinn-Phong specular shading + vec3 halfwayDir = normalize(lightDir + viewDir); + float spec = pow(max(dot(normal, halfwayDir), 0.0), SHININESS); + + vec3 ambient = light.ambient * u_Ambient; + vec3 diffuse = light.diffuse * diff * u_Diffuse; + vec3 specular = light.specular * spec * u_Specular; + + return ambient + diffuse + specular; +} + + +vec3 calc_lighting(vec3 position, vec3 normal, vec3 viewDir) { + vec3 weight = vec3(0.0); + for (int i = 0; i < MAX_NUM_OF_DIRECTIONAL_LIGHTS; i++) { + if (i >= u_NumOfDirectionalLights) { + break; + } + weight += calc_directional_light(u_DirectionalLights[i], normal, viewDir); + } + return weight; +} +`,$2=` +in vec4 v_PickingResult; + +#pragma include "picking_uniforms" + +#define PICKING_NONE 0.0 +#define PICKING_ENCODE 1.0 +#define PICKING_HIGHLIGHT 2.0 +#define COLOR_SCALE 1. / 255. + +#define HIGHLIGHT 1.0 +#define SELECT 2.0 + +/* + * Returns highlight color if this item is selected. + */ +vec4 filterHighlightColor(vec4 color, float weight) { + // float selected = v_PickingResult.a; + bool selected = bool(v_PickingResult.a); + + // if (selected == SELECT) { + if (selected) { + // // \u70B9\u51FB\u9009\u4E2D\u72B6\u6001 + // vec4 selectColor = u_SelectColor * COLOR_SCALE; + // return selectColor; + // } else if (selected == HIGHLIGHT) { + // // hover \u9AD8\u4EAE\u72B6\u6001 + vec4 highLightColor = u_HighlightColor * COLOR_SCALE; + + float highLightAlpha = highLightColor.a; + float highLightRatio = highLightAlpha / (highLightAlpha + color.a * (1.0 - highLightAlpha)); + + vec3 resultRGB = mix(color.rgb, highLightColor.rgb, highLightRatio); + return vec4(mix(resultRGB * weight, color.rgb, u_activeMix), color.a); + } else { + return color; + } +} + +/* + * Returns picking color if picking enabled else unmodified argument. + */ +vec4 filterPickingColor(vec4 color) { + vec3 pickingColor = v_PickingResult.rgb; + if (u_PickingStage == PICKING_ENCODE && length(pickingColor) < 0.001) { + discard; + } + return u_PickingStage == PICKING_ENCODE ? vec4(pickingColor, step(0.001,color.a)): color; +} + +/* + * Returns picking color if picking is enabled if not + * highlight color if this item is selected, otherwise unmodified argument. + */ +vec4 filterColor(vec4 color) { + // \u8FC7\u6EE4\u591A\u4F59\u7684 shader \u8BA1\u7B97 + // return color; + if(u_shaderPick < 0.5) { + return color; // \u6682\u65F6\u53BB\u9664 \u76F4\u63A5\u53D6\u6D88\u8BA1\u7B97\u5728\u9009\u4E2D\u65F6\u62D6\u62FD\u5730\u56FE\u4F1A\u6709\u95EE\u9898 + } else { + return filterPickingColor(filterHighlightColor(color, 1.0)); + } + +} + +vec4 filterColorAlpha(vec4 color, float alpha) { + // \u8FC7\u6EE4\u591A\u4F59\u7684 shader \u8BA1\u7B97 + // return color; + if(u_shaderPick < 0.5) { + return color; // \u6682\u65F6\u53BB\u9664 \u76F4\u63A5\u53D6\u6D88\u8BA1\u7B97\u5728\u9009\u4E2D\u65F6\u62D6\u62FD\u5730\u56FE\u4F1A\u6709\u95EE\u9898 + } else { + return filterPickingColor(filterHighlightColor(color, alpha)); + } +} + +`,IA=`layout(location = 3) in vec3 a_PickingColor; +out vec4 v_PickingResult; + +#pragma include "picking_uniforms" + +#define PICKING_NONE 0.0 +#define PICKING_ENCODE 1.0 +#define PICKING_HIGHLIGHT 2.0 +#define COLOR_SCALE 1. / 255. + +#define NORMAL 0.0 +#define HIGHLIGHT 1.0 +#define SELECT 2.0 + +bool isVertexPicked(vec3 vertexColor) { + return distance(vertexColor,u_PickingColor.rgb) < 0.01; +} + +// \u5224\u65AD\u5F53\u524D\u70B9\u662F\u5426\u5DF2\u7ECF\u88AB select \u9009\u4E2D +bool isVertexSelected(vec3 vertexColor) { + return distance(vertexColor,u_CurrentSelectedId.rgb) < 0.01; +} + +void setPickingColor(vec3 pickingColor) { + if(u_shaderPick < 0.5) { + return; + } + // compares only in highlight stage + + v_PickingResult.a = float((u_PickingStage == PICKING_HIGHLIGHT) && isVertexPicked(pickingColor)); + + // Stores the picking color so that the fragment shader can render it during picking + v_PickingResult.rgb = pickingColor * COLOR_SCALE; +} + +float setPickingSize(float x) { + return u_PickingStage == PICKING_ENCODE ? x + u_PickingBuffer : x; +} + +float setPickingOrder(float z) { + bool selected = bool(v_PickingResult.a); + return selected ? z + 1. : 0.; +} +`,H2=` +#define E 2.718281828459045 +vec2 ProjectFlat(vec2 lnglat){ + float maxs=85.0511287798; + float lat=max(min(maxs,lnglat.y),-maxs); + float scale= 268435456.; + float d=PI/180.; + float x=lnglat.x*d; + float y=lat*d; + y=log(tan((PI/4.)+(y/2.))); + + float a=.5/PI, + b=.5, + c=-.5/PI; + d=.5; + x=scale*(a*x+b); + y=scale*(c*y+d); + return vec2(x,y); +} + +vec2 unProjectFlat(vec2 px){ + float a=.5/PI; + float b=.5; + float c=-.5/PI; + float d=.5; + float scale = 268435456.; + float x=(px.x/scale-b)/a; + float y=(px.y/scale-d)/c; + y=(atan(pow(E,y))-(PI/4.))*2.; + d=PI/180.; + float lat=y/d; + float lng=x/d; + return vec2(lng,lat); +} + +float pixelDistance(vec2 from, vec2 to) { + vec2 a1 = ProjectFlat(from); + vec2 b1 = ProjectFlat(to); + return distance(a1, b1); +} + +// gaode2.0 +vec2 customProject(vec2 lnglat) { // \u7ECF\u7EAC\u5EA6 => \u5E73\u9762\u5750\u6807 + float t = lnglat.x; + float e = lnglat.y; + float Sm = 180.0 / PI; + float Tm = 6378137.0; + float Rm = PI / 180.0; + float r = 85.0511287798; + e = max(min(r, e), -r); + t *= Rm; + e *= Rm; + e = log(tan(PI / 4.0 + e / 2.0)); + return vec2(t * Tm, e * Tm); +} + +vec2 unProjCustomCoord(vec2 point) { // \u5E73\u9762\u5750\u6807 => \u7ECF\u7EAC\u5EA6 + float Sm = 57.29577951308232; //180 / Math.PI + float Tm = 6378137.0; + float t = point.x; + float e = point.y; + return vec2(t / Tm * Sm, (2.0 * atan(exp(e / Tm)) - PI / 2.0) * Sm); +} + + +float customPixelDistance(vec2 from, vec2 to) { + vec2 a1 = ProjectFlat(from); + vec2 b1 = ProjectFlat(to); + return distance(a1, b1); +}`,RA=`#define TILE_SIZE 512.0 +#define PI 3.1415926536 +#define WORLD_SCALE TILE_SIZE / (PI * 2.0) +#define EARTH_CIRCUMFERENCE 40.03e6 + +#define COORDINATE_SYSTEM_LNGLAT 1.0 // mapbox +#define COORDINATE_SYSTEM_LNGLAT_OFFSET 2.0 // mapbox offset +#define COORDINATE_SYSTEM_VECTOR_TILE 3.0 +#define COORDINATE_SYSTEM_IDENTITY 4.0 +#define COORDINATE_SYSTEM_P20 5.0 // amap +#define COORDINATE_SYSTEM_P20_OFFSET 6.0 // amap offset +#define COORDINATE_SYSTEM_METER_OFFSET 7.0 + +#define COORDINATE_SYSTEM_P20_2 8.0 // amap2.0 +#pragma include "scene_uniforms" + + +// web mercator coords -> world coords +vec2 project_mercator(vec2 lnglat) { + if (u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { // gaode2.0 + return lnglat; + } + float x = lnglat.x; + return vec2( + radians(x) + PI, + PI - log(tan(PI * 0.25 + radians(lnglat.y) * 0.5)) + ); +} + +float project_scale(float meters) { + return meters * u_PixelsPerMeter.z; +} + + +// offset coords -> world coords +vec4 project_offset(vec4 offset) { + float dy = offset.y; + dy = clamp(dy, -1., 1.); + vec3 pixels_per_unit = u_PixelsPerDegree + u_PixelsPerDegree2 * dy; + return vec4(offset.xyz * pixels_per_unit, offset.w); +} + +vec3 project_normal(vec3 normal) { + vec4 normal_modelspace = u_ModelMatrix * vec4(normal, 0.0); + return normalize(normal_modelspace.xyz * u_PixelsPerMeter); +} + +vec3 project_offset_normal(vec3 vector) { + if (u_CoordinateSystem < COORDINATE_SYSTEM_LNGLAT + 0.01 && u_CoordinateSystem >COORDINATE_SYSTEM_LNGLAT - 0.01 + || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + // normals generated by the polygon tesselator are in lnglat offsets instead of meters + return normalize(vector * u_PixelsPerDegree); + } + return project_normal(vector); +} +// || u_CoordinateSystem < COORDINATE_SYSTEM_P20_OFFSET + 0.01 && u_CoordinateSystem >COORDINATE_SYSTEM_P20_OFFSET - 0.01 +// reverse Y +vec3 reverse_offset_normal(vec3 vector) { + if (u_CoordinateSystem == COORDINATE_SYSTEM_P20 ||u_CoordinateSystem == COORDINATE_SYSTEM_P20_OFFSET ) { + return vector * vec3(1.0, -1.0, 1.0); + } + + if (u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { // gaode2.0 + return vector; + } + return vector; +} + +vec4 project_mvt_offset_position(vec4 position) { + float a = COORDINATE_SYSTEM_LNGLAT_OFFSET; + float b = COORDINATE_SYSTEM_P20_OFFSET; + float c = COORDINATE_SYSTEM_LNGLAT; + if (u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET || u_CoordinateSystem == COORDINATE_SYSTEM_P20_OFFSET) { + return project_offset(vec4(0.0, 0.0, position.z, position.w)); + } + if (u_CoordinateSystem < COORDINATE_SYSTEM_LNGLAT + 0.01 && u_CoordinateSystem >COORDINATE_SYSTEM_LNGLAT - 0.01) { + return vec4( + project_mercator(position.xy) * WORLD_SCALE * u_ZoomScale, + project_scale(position.z), + position.w + ); + } + return position; +} + +vec4 project_position(vec4 position) { + float a = COORDINATE_SYSTEM_LNGLAT_OFFSET; + float b = COORDINATE_SYSTEM_P20_OFFSET; + float c = COORDINATE_SYSTEM_LNGLAT; + if (u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET + || u_CoordinateSystem == COORDINATE_SYSTEM_P20_OFFSET) { + float X = position.x - u_ViewportCenter.x; + float Y = position.y - u_ViewportCenter.y; + return project_offset(vec4(X, Y, position.z, position.w)); + } + if (u_CoordinateSystem < COORDINATE_SYSTEM_LNGLAT + 0.01 && u_CoordinateSystem >COORDINATE_SYSTEM_LNGLAT - 0.01) { + return vec4( + project_mercator(position.xy) * WORLD_SCALE * u_ZoomScale, + project_scale(position.z), + position.w + ); + } + if (u_CoordinateSystem == COORDINATE_SYSTEM_P20) { + return vec4( + (project_mercator(position.xy) * WORLD_SCALE * u_ZoomScale - vec2(215440491., 106744817.)) * vec2(1., -1.), + project_scale(position.z), + position.w + ); + } + + // if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { + + + // return vec4( + // position.xy, + // project_scale(position.z), + // position.w); + // } + return position; + + // TODO: \u74E6\u7247\u5750\u6807\u7CFB & \u5E38\u89C4\u4E16\u754C\u5750\u6807\u7CFB +} +vec2 project_pixel_size_to_clipspace(vec2 pixels) { + vec2 offset = pixels / u_ViewportSize * u_DevicePixelRatio * 2.0; + return offset * u_FocalDistance; +} + + + +float project_pixel_allmap(float pixel) { + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT) { + return pixel * pow(2.0, u_Zoom); + } + return pixel * u_FocalDistance ; +} + +// \u9002\u914D\u7EB9\u7406\u8D34\u56FE\u7684\u7B49\u50CF\u7D20\u5927\u5C0F +float project_pixel_texture(float pixel) { + // mapbox zoom > 12 + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + return pixel * pow(0.5, u_Zoom) * u_FocalDistance ; + } + + // amap2 zoom > 12 + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { + return pixel * pow(2.0, (19.0 - 3.0 - u_Zoom))* u_FocalDistance ; + } + + // amap zoom > 12 + if (u_CoordinateSystem == COORDINATE_SYSTEM_P20_OFFSET) { + return pixel * pow(0.5, u_Zoom)* u_FocalDistance ; + } + + // amap zoom < 12 + if (u_CoordinateSystem == COORDINATE_SYSTEM_P20) { + return pixel * pow(2.0, (20.0 - u_Zoom))* u_FocalDistance ; + } + return pixel * 2.0 * u_FocalDistance;; +} + +// \u5728\u4E0D\u8BBA\u4EC0\u4E48\u5E95\u56FE\u4E0B\u9700\u8981\u7EDF\u4E00\u5904\u7406\u7684\u65F6\u5019\u4F7F\u7528 +float project_float_pixel(float pixel) { + if (u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + // mapbox P20 \u5750\u6807\u7CFB\u4E0B\uFF0C\u4E3A\u4E86\u548C Web \u58A8\u5361\u6258\u5750\u6807\u7CFB\u7EDF\u4E00\uFF0Czoom \u9ED8\u8BA4\u51CF1 + return pixel * pow(2.0, (19.0 - u_Zoom)) * u_FocalDistance ; + } + if (u_CoordinateSystem == COORDINATE_SYSTEM_P20 || u_CoordinateSystem == COORDINATE_SYSTEM_P20_OFFSET) { + // amap P20 \u5750\u6807\u7CFB\u4E0B\uFF0C\u4E3A\u4E86\u548C Web \u58A8\u5361\u6258\u5750\u6807\u7CFB\u7EDF\u4E00\uFF0Czoom \u9ED8\u8BA4\u51CF1 + return pixel * pow(2.0, (19.0 - u_Zoom)); + } + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { + // amap2 P20_2 \u5750\u6807\u7CFB\u4E0B\uFF0C\u4E3A\u4E86\u548C Web \u58A8\u5361\u6258\u5750\u6807\u7CFB\u7EDF\u4E00\uFF0Czoom \u9ED8\u8BA4\u51CF3 + return pixel * pow(2.0, (19.0 - 3.0 - u_Zoom))* u_FocalDistance ; + } + return pixel * u_FocalDistance; +} + +// Project meter into the unit of pixel which used in the camera world space +float project_float_meter(float meter) { + if (u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + // Since the zoom level uniform is updated by mapservice and it's alread been subtracted by 1 + // Not sure if we are supposed to do that again + return meter; + } else { + return project_float_pixel(meter); + } + + // TODO: change the following code to make adaptations for amap + // return u_FocalDistance * TILE_SIZE * pow(2.0, u_Zoom) * meter / EARTH_CIRCUMFERENCE; +} + +float project_pixel(float pixel) { + if (u_CoordinateSystem == COORDINATE_SYSTEM_P20 || u_CoordinateSystem == COORDINATE_SYSTEM_P20_OFFSET) { + // amap P20 \u5750\u6807\u7CFB\u4E0B\uFF0C\u4E3A\u4E86\u548C Web \u58A8\u5361\u6258\u5750\u6807\u7CFB\u7EDF\u4E00\uFF0Czoom \u9ED8\u8BA4\u51CF1 + return pixel * pow(2.0, (19.0 - u_Zoom)) * u_FocalDistance ; + } + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { + // amap2 P20_2 \u5750\u6807\u7CFB\u4E0B\uFF0C\u4E3A\u4E86\u548C Web \u58A8\u5361\u6258\u5750\u6807\u7CFB\u7EDF\u4E00\uFF0Czoom \u9ED8\u8BA4\u51CF3 + return pixel * pow(2.0, (19.0 - 3.0 - u_Zoom)) * u_FocalDistance ; + } + return pixel * u_FocalDistance; +} +vec2 project_pixel(vec2 pixel) { + if (u_CoordinateSystem == COORDINATE_SYSTEM_P20 || u_CoordinateSystem == COORDINATE_SYSTEM_P20_OFFSET) { + // P20 \u5750\u6807\u7CFB\u4E0B\uFF0C\u4E3A\u4E86\u548C Web \u58A8\u5361\u6258\u5750\u6807\u7CFB\u7EDF\u4E00\uFF0Czoom \u9ED8\u8BA4\u51CF1 + return pixel * pow(2.0, (19.0 - u_Zoom)) * u_FocalDistance ; + } + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { + // P20_2 \u5750\u6807\u7CFB\u4E0B\uFF0C\u4E3A\u4E86\u548C Web \u58A8\u5361\u6258\u5750\u6807\u7CFB\u7EDF\u4E00\uFF0Czoom \u9ED8\u8BA4\u51CF3 + return pixel * pow(2.0, (19.0 - 3.0 - u_Zoom)) * u_FocalDistance ; + } + return pixel * -1. * u_FocalDistance; +} +vec3 project_pixel(vec3 pixel) { + if (u_CoordinateSystem == COORDINATE_SYSTEM_P20 || u_CoordinateSystem == COORDINATE_SYSTEM_P20_OFFSET) { + // P20 \u5750\u6807\u7CFB\u4E0B\uFF0C\u4E3A\u4E86\u548C Web \u58A8\u5361\u6258\u5750\u6807\u7CFB\u7EDF\u4E00\uFF0Czoom \u9ED8\u8BA4\u51CF1 + return pixel * pow(2.0, (19.0 - u_Zoom)) * u_FocalDistance ; + } + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { + // P20_2 \u5750\u6807\u7CFB\u4E0B\uFF0C\u4E3A\u4E86\u548C Web \u58A8\u5361\u6258\u5750\u6807\u7CFB\u7EDF\u4E00\uFF0Czoom \u9ED8\u8BA4\u51CF3 + return pixel * pow(2.0, (19.0 - 3.0 - u_Zoom)) * u_FocalDistance ; + } + return pixel * -1. * u_FocalDistance; +} + +vec4 project_common_position_to_clipspace(vec4 position, mat4 viewProjectionMatrix, vec4 center) { + if (u_CoordinateSystem == COORDINATE_SYSTEM_METER_OFFSET || + u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + // Needs to be divided with project_uCommonUnitsPerMeter + position.w *= u_PixelsPerMeter.z; + } + + return viewProjectionMatrix * position + center; +} + +// Projects from common space coordinates to clip space +vec4 project_common_position_to_clipspace(vec4 position) { + return project_common_position_to_clipspace( + position, + u_ViewProjectionMatrix, + u_ViewportCenterProjection + ); +} + +vec4 unproject_clipspace_to_position(vec4 clipspacePos, mat4 u_InverseViewProjectionMatrix) { + vec4 pos = u_InverseViewProjectionMatrix * (clipspacePos - u_ViewportCenterProjection); + + if (u_CoordinateSystem == COORDINATE_SYSTEM_METER_OFFSET || + u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + // Needs to be divided with project_uCommonUnitsPerMeter + pos.w = pos.w / u_PixelsPerMeter.z; + } + return pos; +} + + +bool isEqual( float a, float b) { + return a< b + 0.001 && a > b - 0.001; +} + +// \u652F\u6301 GaodeV2\u3001Mapbox +vec4 project_common_position_to_clipspace_v2(vec4 position) { + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { // gaode2.x + return u_Mvp * position; + } else { + return project_common_position_to_clipspace(position); + } +} +`,G2=`vec2 rotate_matrix(vec2 v, float a) { + float b = a / 180.0 * 3.1415926535897932384626433832795; + float s = sin(b); + float c = cos(b); + mat2 m = mat2(c, s, -s, c); + return m * v; +}`,fE=`/** + * 2D signed distance field functions + * @see http://www.iquilezles.org/www/articles/distfunctions2d/distfunctions2d.htm + */ + +float ndot(vec2 a, vec2 b ) { return a.x*b.x - a.y*b.y; } + +float sdCircle(vec2 p, float r) { + return length(p) - r; +} + +float sdEquilateralTriangle(vec2 p) { + float k = sqrt(3.0); + p.x = abs(p.x) - 1.0; + p.y = p.y + 1.0/k; + if( p.x + k*p.y > 0.0 ) p = vec2(p.x-k*p.y,-k*p.x-p.y)/2.0; + p.x -= clamp( p.x, -2.0, 0.0 ); + return -length(p)*sign(p.y); +} + +float sdBox(vec2 p, vec2 b) { + vec2 d = abs(p)-b; + return length(max(d,vec2(0))) + min(max(d.x,d.y),0.0); +} + +float sdPentagon(vec2 p, float r) { + vec3 k = vec3(0.809016994,0.587785252,0.726542528); + p.x = abs(p.x); + p -= 2.0*min(dot(vec2(-k.x,k.y),p),0.0)*vec2(-k.x,k.y); + p -= 2.0*min(dot(vec2( k.x,k.y),p),0.0)*vec2( k.x,k.y); + p -= vec2(clamp(p.x,-r*k.z,r*k.z),r); + return length(p)*sign(p.y); +} + +float sdHexagon(vec2 p, float r) { + vec3 k = vec3(-0.866025404,0.5,0.577350269); + p = abs(p); + p -= 2.0*min(dot(k.xy,p),0.0)*k.xy; + p -= vec2(clamp(p.x, -k.z*r, k.z*r), r); + return length(p)*sign(p.y); +} + +float sdOctogon(vec2 p, float r) { + vec3 k = vec3(-0.9238795325, 0.3826834323, 0.4142135623 ); + p = abs(p); + p -= 2.0*min(dot(vec2( k.x,k.y),p),0.0)*vec2( k.x,k.y); + p -= 2.0*min(dot(vec2(-k.x,k.y),p),0.0)*vec2(-k.x,k.y); + p -= vec2(clamp(p.x, -k.z*r, k.z*r), r); + return length(p)*sign(p.y); +} + +float sdHexagram(vec2 p, float r) { + vec4 k=vec4(-0.5,0.8660254038,0.5773502692,1.7320508076); + p = abs(p); + p -= 2.0*min(dot(k.xy,p),0.0)*k.xy; + p -= 2.0*min(dot(k.yx,p),0.0)*k.yx; + p -= vec2(clamp(p.x,r*k.z,r*k.w),r); + return length(p)*sign(p.y); +} + +float sdRhombus(vec2 p, vec2 b) { + vec2 q = abs(p); + float h = clamp((-2.0*ndot(q,b)+ndot(b,b))/dot(b,b),-1.0,1.0); + float d = length( q - 0.5*b*vec2(1.0-h,1.0+h) ); + return d * sign( q.x*b.y + q.y*b.x - b.x*b.y ); +} + +float sdVesica(vec2 p, float r, float d) { + p = abs(p); + float b = sqrt(r*r-d*d); // can delay this sqrt + return ((p.y-b)*d>p.x*b) + ? length(p-vec2(0.0,b)) + : length(p-vec2(-d,0.0))-r; +} +`,OA=/precision\s+(high|low|medium)p\s+float/,LA=`#ifdef GL_FRAGMENT_PRECISION_HIGH + precision highp float; + #else + precision mediump float; +#endif +`,W2=/#pragma include (["^+"]?["[a-zA-Z_0-9](.*)"]*?)/g,DA=/void\s+main\s*\([^)]*\)\s*\{\n?/,hE=/}\n?[^{}]*$/,kA=(TA=(0,sa.b2)(),TA(MA=function(){function e(){(0,We.Z)(this,e),(0,St.Z)(this,"moduleCache",{}),(0,St.Z)(this,"rawContentCache",{})}return(0,ot.Z)(e,[{key:"registerBuiltinModules",value:function(){this.destroy(),this.registerModule("common",{vs:PA,fs:PA}),this.registerModule("decode",{vs:cE,fs:""}),this.registerModule("scene_uniforms",{vs:A_,fs:A_}),this.registerModule("picking_uniforms",{vs:Gy,fs:Gy}),this.registerModule("projection",{vs:RA,fs:RA}),this.registerModule("project",{vs:H2,fs:""}),this.registerModule("sdf_2d",{vs:"",fs:fE}),this.registerModule("lighting",{vs:V2,fs:""}),this.registerModule("light",{vs:j2,fs:""}),this.registerModule("picking",{vs:IA,fs:$2}),this.registerModule("rotation_2d",{vs:G2,fs:""})}},{key:"registerModule",value:function(r,n){n.vs=n.vs.replace(/\r\n/g,` +`),n.fs=n.fs.replace(/\r\n/g,` +`);var t=n.vs,a=n.fs,u=n.uniforms,c=n.inject,m=$y(t),E=m.content,H=m.uniforms,re=$y(a),xe=re.content,ke=re.uniforms;this.rawContentCache[r]={fs:xe,inject:c,uniforms:(0,Se.Z)((0,Se.Z)((0,Se.Z)({},H),ke),u),vs:E}}},{key:"destroy",value:function(){this.moduleCache={},this.rawContentCache={}}},{key:"getModule",value:function(r){var n=this,t=this.rawContentCache[r].vs,a=this.rawContentCache[r].fs,u=this.rawContentCache[r].inject,c={};u!=null&&u["vs:#decl"]&&(t=(u==null?void 0:u["vs:#decl"])+t,c=$y(u==null?void 0:u["vs:#decl"]).uniforms),u!=null&&u["vs:#main-start"]&&(t=t.replace(DA,function(er){return er+(u==null?void 0:u["vs:#main-start"])})),u!=null&&u["fs:#decl"]&&(a=(u==null?void 0:u["fs:#decl"])+a);var m=this.processModule(t,[],"vs"),E=m.content,H=m.includeList,re=this.processModule(a,[],"fs"),xe=re.content,ke=re.includeList,rt="",vt=U2(H.concat(ke).concat(r)).reduce(function(er,Ar){return(0,Se.Z)((0,Se.Z)({},er),n.rawContentCache[Ar].uniforms)},(0,Se.Z)({},c));OA.test(xe)||(rt=rt+LA),rt=rt+xe;var It="";return OA.test(E)||(It=It+LA),It=It+E,this.moduleCache[r]={fs:rt.trim(),uniforms:vt,vs:It.trim()},this.moduleCache[r]}},{key:"processModule",value:function(r,n,t){var a=this,u=r.replace(W2,function(c,m){var E=m.split(" "),H=E[0].replace(/"/g,"");if(n.indexOf(H)>-1)return"";var re=a.rawContentCache[H][t];n.push(H);var xe=a.processModule(re,n,t),ke=xe.content;return ke});return{content:u,includeList:n}}},{key:"injectDefines",value:function(r){var n=Object.keys(r).reduce(function(t,a){return t+"#define ".concat(a.toUpperCase()," ").concat(r[a],`; +`)},` +`);return n}}]),e}())||MA);function FA(e,i){for(;!Object.prototype.hasOwnProperty.call(e,i)&&(e=(0,Qe.Z)(e),e!==null););return e}function Sd(){return typeof Reflect!="undefined"&&Reflect.get?Sd=Reflect.get.bind():Sd=function(i,r,n){var t=FA(i,r);if(t){var a=Object.getOwnPropertyDescriptor(t,r);return a.get?a.get.call(arguments.length<3?i:n):a.value}},Sd.apply(this,arguments)}var Uv=function(e){return e.Normal="normal",e.PostProcessing="post-processing",e}({}),BA,NA,ng=(BA=(0,sa.b2)(),BA(NA=function(){function e(){(0,We.Z)(this,e),(0,St.Z)(this,"shaderModuleService",void 0),(0,St.Z)(this,"rendererService",void 0),(0,St.Z)(this,"cameraService",void 0),(0,St.Z)(this,"mapService",void 0),(0,St.Z)(this,"interactionService",void 0),(0,St.Z)(this,"layerService",void 0),(0,St.Z)(this,"config",void 0)}return(0,ot.Z)(e,[{key:"getName",value:function(){return""}},{key:"getType",value:function(){return Uv.Normal}},{key:"init",value:function(r,n){this.config=n,this.rendererService=r.getContainer().get(sr.IRendererService),this.cameraService=r.getContainer().get(sr.ICameraService),this.mapService=r.getContainer().get(sr.IMapService),this.interactionService=r.getContainer().get(sr.IInteractionService),this.layerService=r.getContainer().get(sr.ILayerService),this.shaderModuleService=r.getContainer().get(sr.IShaderModuleService)}},{key:"render",value:function(r){}}]),e}())||NA),zA,b_;function T1(e){var i=X2();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function X2(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var Y2=(zA=(0,sa.b2)(),zA(b_=function(e){(0,Me.Z)(r,e);var i=T1(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getName",value:function(){return"clear"}},{key:"init",value:function(t,a){Sd((0,Qe.Z)(r.prototype),"init",this).call(this,t,a)}},{key:"render",value:function(){this.rendererService.clear({color:[0,0,0,0],depth:1,framebuffer:null})}}]),r}(ng))||b_),x_,ZA,UA,w_,jA;function K2(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=q2(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function q2(e,i){if(e){if(typeof e=="string")return E_(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return E_(e,i)}}function E_(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);rer||wn<0||Cn>Ar||Cn<0)){var qn;vt(n.pickingFBO,(0,Li.Z)(Ur().mark(function Si(){var po,Ao,ma,Ya,fs;return Ur().wrap(function(th){for(;;)switch(th.prev=th.next){case 0:return th.next=2,rt({x:Math.round(wn),y:Math.round(Ar-(E+1)*Co),width:1,height:1,data:new Uint8Array(1*1*4),framebuffer:n.pickingFBO});case 2:qn=th.sent,qn[0]!==0||qn[1]!==0||qn[2]!==0?(Ao=eo(qn),ma=n.layer.getSource().getFeatureById(Ao),Ya={x:m,y:E,type:re,lngLat:H,featureId:Ao,feature:ma},ma&&(n.layer.setCurrentPickId(Ao),n.triggerHoverOnLayer(Ya))):(fs={x:m,y:E,lngLat:H,type:n.layer.getCurrentPickId()===null?"un"+re:"mouseout",featureId:null,feature:null},n.triggerHoverOnLayer((0,Se.Z)((0,Se.Z)({},fs),{},{type:"unpick"})),n.triggerHoverOnLayer(fs),n.layer.setCurrentPickId(null)),rn&&n.highlightPickedFeature(qn),Ln&&re==="click"&&((po=qn)===null||po===void 0?void 0:po.toString())!==[0,0,0,0].toString()&&n.selectFeature(qn);case 6:case"end":return th.stop()}},Si)})))}}}),n}return(0,ot.Z)(r,[{key:"getType",value:function(){return Uv.Normal}},{key:"getName",value:function(){return"pixelPicking"}},{key:"init",value:function(t,a){Sd((0,Qe.Z)(r.prototype),"init",this).call(this,t,a),this.layer=t;var u=this.rendererService,c=u.createTexture2D,m=u.createFramebuffer,E=u.getViewportSize,H=E(),re=H.width,xe=H.height,ke=c({width:re,height:xe,wrapS:Er.CLAMP_TO_EDGE,wrapT:Er.CLAMP_TO_EDGE,label:"Picking Texture"});this.pickingFBO=m({color:ke}),this.interactionService.on(Du.Hover,this.pickFromPickingFBO),this.interactionService.on(Du.Select,this.selectFeatureHandle.bind(this)),this.interactionService.on(Du.Active,this.highlightFeatureHandle.bind(this))}},{key:"render",value:function(t){var a=this;if(!this.alreadyInRendering){var u=this.rendererService,c=u.getViewportSize,m=u.useFramebuffer,E=u.clear,H=c(),re=H.width,xe=H.height;this.alreadyInRendering=!0,(this.width!==re||this.height!==xe)&&(this.pickingFBO.resize({width:re,height:xe}),this.width=re,this.height=xe),m(this.pickingFBO,function(){E({framebuffer:a.pickingFBO,color:[0,0,0,0],stencil:0,depth:1});var ke=a.layer.multiPassRenderer.getRenderFlag();a.layer.multiPassRenderer.setRenderFlag(!1),t.hooks.beforePickingEncode.call(),t.render(),t.hooks.afterPickingEncode.call(),a.layer.multiPassRenderer.setRenderFlag(ke),a.alreadyInRendering=!1})}}},{key:"triggerHoverOnLayer",value:function(t){this.layer.emit(t.type,t)}},{key:"highlightPickedFeature",value:function(t){var a=(0,gi.Z)(t,3),u=a[0],c=a[1],m=a[2];this.layer.hooks.beforeHighlight.call([u,c,m]),this.layerService.renderLayers()}},{key:"selectFeature",value:function(t){var a=(0,gi.Z)(t,3),u=a[0],c=a[1],m=a[2];this.layer.hooks.beforeSelect.call([u,c,m]),this.layerService.renderLayers()}},{key:"selectFeatureHandle",value:function(t){var a=t.featureId,u=ba(a);this.selectFeature(new Uint8Array(u))}},{key:"highlightFeatureHandle",value:function(t){var a=t.featureId,u=ba(a);this.highlightPickedFeature(new Uint8Array(u))}}]),r}(ng))||C_),ig,WA,XA,T_,M1,Ig=lo.camelCase,Q2=lo.isNil,J2=lo.upperFirst,Wy=`attribute vec2 a_Position; + +varying vec2 v_UV; + +void main() { + v_UV = 0.5 * (a_Position + 1.0); + gl_Position = vec4(a_Position, 0., 1.); +}`,Pv=(ig=(0,sa.b2)(),WA=(0,sa.f3)(sr.IShaderModuleService),ig(XA=(T_=function(){function e(){(0,We.Z)(this,e),_(this,"shaderModuleService",M1,this),(0,St.Z)(this,"rendererService",void 0),(0,St.Z)(this,"config",void 0),(0,St.Z)(this,"quad",Wy),(0,St.Z)(this,"enabled",!0),(0,St.Z)(this,"renderToScreen",!1),(0,St.Z)(this,"model",void 0),(0,St.Z)(this,"name",void 0),(0,St.Z)(this,"optionsToUpdate",{})}return(0,ot.Z)(e,[{key:"getName",value:function(){return this.name}},{key:"setName",value:function(r){this.name=r}},{key:"getType",value:function(){return Uv.PostProcessing}},{key:"init",value:function(r,n){this.config=n,this.rendererService=r.getContainer().get(sr.IRendererService),this.shaderModuleService=r.getContainer().get(sr.IShaderModuleService);var t=this.rendererService,a=t.createAttribute,u=t.createBuffer,c=t.createModel,m=this.setupShaders(),E=m.vs,H=m.fs,re=m.uniforms;this.model=c({vs:E,fs:H,attributes:{a_Position:a({buffer:u({data:[-4,-4,4,-4,0,4],type:Er.FLOAT}),size:2})},uniforms:(0,Se.Z)((0,Se.Z)({u_Texture:null},re),this.config&&this.convertOptionsToUniforms(this.config)),depth:{enable:!1},count:3,blend:{enable:this.getName()==="copy"}})}},{key:"render",value:function(r,n){var t=this,a=r.multiPassRenderer.getPostProcessor(),u=this.rendererService,c=u.useFramebuffer,m=u.getViewportSize,E=u.clear,H=m(),re=H.width,xe=H.height;c(this.renderToScreen?null:a.getWriteFBO(),function(){E({framebuffer:a.getWriteFBO(),color:[0,0,0,0],depth:1,stencil:0});var ke=(0,Se.Z)({u_BloomFinal:0,u_Texture:a.getReadFBO(),u_ViewportSize:[re,xe]},t.convertOptionsToUniforms(t.optionsToUpdate));n&&(ke.u_BloomFinal=1,ke.u_Texture2=n),t.model.draw({uniforms:ke})})}},{key:"isEnabled",value:function(){return this.enabled}},{key:"setEnabled",value:function(r){this.enabled=r}},{key:"setRenderToScreen",value:function(r){this.renderToScreen=r}},{key:"updateOptions",value:function(r){this.optionsToUpdate=(0,Se.Z)((0,Se.Z)({},this.optionsToUpdate),r)}},{key:"setupShaders",value:function(){throw new Error("Method not implemented.")}},{key:"convertOptionsToUniforms",value:function(r){var n={};return Object.keys(r).forEach(function(t){Q2(r[t])||(n["u_".concat(J2(Ig(t)))]=r[t])}),n}}]),e}(),M1=d(T_.prototype,"shaderModuleService",[WA],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),T_))||XA),YA,KA;function ex(e){var i=tx();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function tx(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var qA=`varying vec2 v_UV; + +uniform float u_BloomFinal: 0.0; +uniform sampler2D u_Texture; +uniform sampler2D u_Texture2; + +uniform vec2 u_ViewportSize: [1.0, 1.0]; +uniform float u_radius: 5.0; +uniform float u_intensity: 0.3; +uniform float u_baseRadio: 0.5; + +// https://github.com/Jam3/glsl-fast-gaussian-blur/blob/master/9.glsl +vec4 blur9(sampler2D image, vec2 uv, vec2 resolution, vec2 direction) { + vec4 color = vec4(0.0); + vec2 off1 = vec2(1.3846153846) * direction; + vec2 off2 = vec2(3.2307692308) * direction; + color += texture2D(image, uv) * 0.2270270270; + color += texture2D(image, uv + (off1 / resolution)) * 0.3162162162; + color += texture2D(image, uv - (off1 / resolution)) * 0.3162162162; + color += texture2D(image, uv + (off2 / resolution)) * 0.0702702703; + color += texture2D(image, uv - (off2 / resolution)) * 0.0702702703; + return color; +} + +float luminance(vec4 color) { + return 0.2125 * color.r + 0.7154 * color.g + 0.0721 * color.b; +} + +void main() { + // vec4 baseColor = texture2D(u_Texture, v_UV); + + float r = sqrt(u_radius); + + vec4 c1 = blur9(u_Texture, v_UV, u_ViewportSize, vec2(u_radius, 0.0)); + // c1 *= luminance(c1); + vec4 c2 = blur9(u_Texture, v_UV, u_ViewportSize, vec2(0.0, u_radius)); + // c2 *= luminance(c2); + vec4 c3 = blur9(u_Texture, v_UV, u_ViewportSize, vec2(r, r)); + // c3 *= luminance(c3); + vec4 c4 = blur9(u_Texture, v_UV, u_ViewportSize, vec2(r, -r)); + // c4 *= luminance(c4); + vec4 inbloomColor = (c1 + c2 + c3 + c4) * 0.25; + + // float lum = luminance(inbloomColor); + // inbloomColor.rgb *= lum; + + if(u_BloomFinal > 0.0) { + vec4 baseColor = texture2D(u_Texture2, v_UV); + float baselum = luminance(baseColor); + gl_FragColor = mix(inbloomColor, baseColor, u_baseRadio); + if(baselum <= 0.2) { + gl_FragColor = inbloomColor * u_intensity; + } + } else { + gl_FragColor = inbloomColor; + } +}`,rx=`attribute vec2 a_Position; + +varying vec2 v_UV; + +void main() { + v_UV = 0.5 * (a_Position + 1.0); + gl_Position = vec4(a_Position, 0., 1.); +}`,M_=lo.isNil,QA=(YA=(0,sa.b2)(),YA(KA=function(e){(0,Me.Z)(r,e);var i=ex(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"setupShaders",value:function(){this.shaderModuleService.registerModule("blur-pass",{vs:rx,fs:qA});var t=this.shaderModuleService.getModule("blur-pass"),a=t.vs,u=t.fs,c=t.uniforms,m=this.rendererService.getViewportSize(),E=m.width,H=m.height;return{vs:a,fs:u,uniforms:(0,Se.Z)((0,Se.Z)({},c),{},{u_ViewportSize:[E,H]})}}},{key:"convertOptionsToUniforms",value:function(t){var a={};return M_(t.bloomRadius)||(a.u_radius=t.bloomRadius),M_(t.bloomIntensity)||(a.u_intensity=t.bloomIntensity),M_(t.bloomBaseRadio)||(a.u_baseRadio=t.bloomBaseRadio),a}}]),r}(Pv))||KA),cy,P_;function nx(e){var i=ix();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function ix(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var JA=`varying vec2 v_UV; + +uniform sampler2D u_Texture; + +uniform vec2 u_ViewportSize: [1.0, 1.0]; +uniform vec2 u_BlurDir: [1.0, 0.0]; + +// https://github.com/Jam3/glsl-fast-gaussian-blur/blob/master/9.glsl +vec4 blur9(sampler2D image, vec2 uv, vec2 resolution, vec2 direction) { + vec4 color = vec4(0.0); + vec2 off1 = vec2(1.3846153846) * direction; + vec2 off2 = vec2(3.2307692308) * direction; + color += texture2D(image, uv) * 0.2270270270; + color += texture2D(image, uv + (off1 / resolution)) * 0.3162162162; + color += texture2D(image, uv - (off1 / resolution)) * 0.3162162162; + color += texture2D(image, uv + (off2 / resolution)) * 0.0702702703; + color += texture2D(image, uv - (off2 / resolution)) * 0.0702702703; + return color; +} + +void main() { + gl_FragColor = blur9(u_Texture, v_UV, u_ViewportSize, u_BlurDir); +}`,ox=`attribute vec2 a_Position; + +varying vec2 v_UV; + +void main() { + v_UV = 0.5 * (a_Position + 1.0); + gl_Position = vec4(a_Position, 0., 1.); +}`,ax=lo.isNil,sx=(cy=(0,sa.b2)(),cy(P_=function(e){(0,Me.Z)(r,e);var i=nx(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"setupShaders",value:function(){this.shaderModuleService.registerModule("blur-pass",{vs:ox,fs:JA});var t=this.shaderModuleService.getModule("blur-pass"),a=t.vs,u=t.fs,c=t.uniforms,m=this.rendererService.getViewportSize(),E=m.width,H=m.height;return{vs:a,fs:u,uniforms:(0,Se.Z)((0,Se.Z)({},c),{},{u_ViewportSize:[E,H]})}}},{key:"convertOptionsToUniforms",value:function(t){var a={};return ax(t.blurRadius)||(a.u_BlurDir=[t.blurRadius,0]),a}}]),r}(Pv))||P_),eb,tb;function ux(e){var i=lx();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function lx(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var cx=`varying vec2 v_UV; + +uniform sampler2D u_Texture; + +uniform vec2 u_ViewportSize: [1.0, 1.0]; +uniform vec2 u_BlurDir: [1.0, 0.0]; + +// https://github.com/Jam3/glsl-fast-gaussian-blur/blob/master/9.glsl +vec4 blur9(sampler2D image, vec2 uv, vec2 resolution, vec2 direction) { + vec4 color = vec4(0.0); + vec2 off1 = vec2(1.3846153846) * direction; + vec2 off2 = vec2(3.2307692308) * direction; + color += texture2D(image, uv) * 0.2270270270; + color += texture2D(image, uv + (off1 / resolution)) * 0.3162162162; + color += texture2D(image, uv - (off1 / resolution)) * 0.3162162162; + color += texture2D(image, uv + (off2 / resolution)) * 0.0702702703; + color += texture2D(image, uv - (off2 / resolution)) * 0.0702702703; + return color; +} + +void main() { + gl_FragColor = blur9(u_Texture, v_UV, u_ViewportSize, u_BlurDir); +}`,fx=`attribute vec2 a_Position; + +varying vec2 v_UV; + +void main() { + v_UV = 0.5 * (a_Position + 1.0); + gl_Position = vec4(a_Position, 0., 1.); +}`,hx=lo.isNil,dx=(eb=(0,sa.b2)(),eb(tb=function(e){(0,Me.Z)(r,e);var i=ux(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"setupShaders",value:function(){this.shaderModuleService.registerModule("blur-pass",{vs:fx,fs:cx});var t=this.shaderModuleService.getModule("blur-pass"),a=t.vs,u=t.fs,c=t.uniforms,m=this.rendererService.getViewportSize(),E=m.width,H=m.height;return{vs:a,fs:u,uniforms:(0,Se.Z)((0,Se.Z)({},c),{},{u_ViewportSize:[E,H]})}}},{key:"convertOptionsToUniforms",value:function(t){var a={};return hx(t.blurRadius)||(a.u_BlurDir=[0,t.blurRadius]),a}}]),r}(Pv))||tb),rb,nb;function px(e){var i=mx();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function mx(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var vx=`varying vec2 v_UV; + +uniform sampler2D u_Texture; +uniform vec2 u_ViewportSize: [1.0, 1.0]; +uniform vec2 u_Center : [0.5, 0.5]; +uniform float u_Angle : 0; +uniform float u_Size : 8; + +#pragma include "common" + +float scale = PI / u_Size; + +float pattern(float u_Angle, vec2 texSize, vec2 texCoord) { + float s = sin(u_Angle), c = cos(u_Angle); + vec2 tex = texCoord * texSize - u_Center * texSize; + vec2 point = vec2( + c * tex.x - s * tex.y, + s * tex.x + c * tex.y + ) * scale; + return (sin(point.x) * sin(point.y)) * 4.0; +} + +// https://github.com/evanw/glfx.js/blob/master/src/filters/fun/colorhalftone.js +vec4 colorHalftone_filterColor(vec4 color, vec2 texSize, vec2 texCoord) { + vec3 cmy = 1.0 - color.rgb; + float k = min(cmy.x, min(cmy.y, cmy.z)); + cmy = (cmy - k) / (1.0 - k); + cmy = clamp( + cmy * 10.0 - 3.0 + vec3( + pattern(u_Angle + 0.26179, texSize, texCoord), + pattern(u_Angle + 1.30899, texSize, texCoord), + pattern(u_Angle, texSize, texCoord) + ), + 0.0, + 1.0 + ); + k = clamp(k * 10.0 - 5.0 + pattern(u_Angle + 0.78539, texSize, texCoord), 0.0, 1.0); + return vec4(1.0 - cmy - k, color.a); +} + +void main() { + gl_FragColor = vec4(texture2D(u_Texture, v_UV)); + gl_FragColor = colorHalftone_filterColor(gl_FragColor, u_ViewportSize, v_UV); +}`,O=`attribute vec2 a_Position; + +varying vec2 v_UV; + +void main() { + v_UV = 0.5 * (a_Position + 1.0); + gl_Position = vec4(a_Position, 0., 1.); +}`,N=(rb=(0,sa.b2)(),rb(nb=function(e){(0,Me.Z)(r,e);var i=px(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"setupShaders",value:function(){this.shaderModuleService.registerModule("colorhalftone-pass",{vs:O,fs:vx});var t=this.shaderModuleService.getModule("colorhalftone-pass"),a=t.vs,u=t.fs,c=t.uniforms,m=this.rendererService.getViewportSize(),E=m.width,H=m.height;return{vs:a,fs:u,uniforms:(0,Se.Z)((0,Se.Z)({},c),{},{u_ViewportSize:[E,H]})}}}]),r}(Pv))||nb),ge,Fe;function Xt(e){var i=fr();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function fr(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var Qr=`varying vec2 v_UV; + +uniform sampler2D u_Texture; + +void main() { + gl_FragColor = vec4(texture2D(u_Texture, v_UV)); +}`,yn=`attribute vec2 a_Position; + +varying vec2 v_UV; + +void main() { + v_UV = 0.5 * (a_Position + 1.0); + gl_Position = vec4(a_Position, 0., 1.); +}`,_n=(ge=(0,sa.b2)(),ge(Fe=function(e){(0,Me.Z)(r,e);var i=Xt(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"setupShaders",value:function(){return this.shaderModuleService.registerModule("copy-pass",{vs:yn,fs:Qr}),this.shaderModuleService.getModule("copy-pass")}}]),r}(Pv))||Fe),vn,Oi;function ki(e){var i=Io();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function Io(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var Fi=`varying vec2 v_UV; + +uniform sampler2D u_Texture; +uniform vec2 u_ViewportSize: [1.0, 1.0]; +uniform vec2 u_Center : [0.5, 0.5]; +uniform float u_Scale : 10; + +// https://github.com/evanw/glfx.js/blob/master/src/filters/fun/hexagonalpixelate.js +vec4 hexagonalPixelate_sampleColor(sampler2D texture, vec2 texSize, vec2 texCoord) { + vec2 tex = (texCoord * texSize - u_Center * texSize) / u_Scale; + tex.y /= 0.866025404; + tex.x -= tex.y * 0.5; + vec2 a; + if (tex.x + tex.y - floor(tex.x) - floor(tex.y) < 1.0) { + a = vec2(floor(tex.x), floor(tex.y)); + } + else a = vec2(ceil(tex.x), ceil(tex.y)); + vec2 b = vec2(ceil(tex.x), floor(tex.y)); + vec2 c = vec2(floor(tex.x), ceil(tex.y)); + vec3 TEX = vec3(tex.x, tex.y, 1.0 - tex.x - tex.y); + vec3 A = vec3(a.x, a.y, 1.0 - a.x - a.y); + vec3 B = vec3(b.x, b.y, 1.0 - b.x - b.y); + vec3 C = vec3(c.x, c.y, 1.0 - c.x - c.y); + float alen = length(TEX - A); + float blen = length(TEX - B); + float clen = length(TEX - C); + vec2 choice; + if (alen < blen) { + if (alen < clen) choice = a; + else choice = c; + } else { + if (blen < clen) choice = b; + else choice = c; + } + choice.x += choice.y * 0.5; + choice.y *= 0.866025404; + choice *= u_Scale / texSize; + return texture2D(texture, choice + u_Center); +} + +void main() { + gl_FragColor = vec4(texture2D(u_Texture, v_UV)); + gl_FragColor = hexagonalPixelate_sampleColor(u_Texture, u_ViewportSize, v_UV); +}`,Oo=`attribute vec2 a_Position; + +varying vec2 v_UV; + +void main() { + v_UV = 0.5 * (a_Position + 1.0); + gl_Position = vec4(a_Position, 0., 1.); +}`,Ko=(vn=(0,sa.b2)(),vn(Oi=function(e){(0,Me.Z)(r,e);var i=ki(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"setupShaders",value:function(){this.shaderModuleService.registerModule("hexagonalpixelate-pass",{vs:Oo,fs:Fi});var t=this.shaderModuleService.getModule("hexagonalpixelate-pass"),a=t.vs,u=t.fs,c=t.uniforms,m=this.rendererService.getViewportSize(),E=m.width,H=m.height;return{vs:a,fs:u,uniforms:(0,Se.Z)((0,Se.Z)({},c),{},{u_ViewportSize:[E,H]})}}}]),r}(Pv))||Oi),_a,Ma;function go(e){var i=Ga();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function Ga(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var uu=`varying vec2 v_UV; + +uniform sampler2D u_Texture; +uniform vec2 u_ViewportSize: [1.0, 1.0]; +uniform float u_Strength : 0.6; + +vec4 ink_sampleColor(sampler2D texture, vec2 texSize, vec2 texCoord) { + vec2 dx = vec2(1.0 / texSize.x, 0.0); + vec2 dy = vec2(0.0, 1.0 / texSize.y); + vec4 color = texture2D(texture, texCoord); + float bigTotal = 0.0; + float smallTotal = 0.0; + vec3 bigAverage = vec3(0.0); + vec3 smallAverage = vec3(0.0); + for (float x = -2.0; x <= 2.0; x += 1.0) { + for (float y = -2.0; y <= 2.0; y += 1.0) { + vec3 sample = texture2D(texture, texCoord + dx * x + dy * y).rgb; + bigAverage += sample; + bigTotal += 1.0; + if (abs(x) + abs(y) < 2.0) { + smallAverage += sample; + smallTotal += 1.0; + } + } + } + vec3 edge = max(vec3(0.0), bigAverage / bigTotal - smallAverage / smallTotal); + float power = u_Strength * u_Strength * u_Strength * u_Strength * u_Strength; + return vec4(color.rgb - dot(edge, edge) * power * 100000.0, color.a); +} + +void main() { + gl_FragColor = vec4(texture2D(u_Texture, v_UV)); + gl_FragColor = ink_sampleColor(u_Texture, u_ViewportSize, v_UV); +}`,Ss=`attribute vec2 a_Position; + +varying vec2 v_UV; + +void main() { + v_UV = 0.5 * (a_Position + 1.0); + gl_Position = vec4(a_Position, 0., 1.); +}`,$u=(_a=(0,sa.b2)(),_a(Ma=function(e){(0,Me.Z)(r,e);var i=go(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"setupShaders",value:function(){this.shaderModuleService.registerModule("ink-pass",{vs:Ss,fs:uu});var t=this.shaderModuleService.getModule("ink-pass"),a=t.vs,u=t.fs,c=t.uniforms,m=this.rendererService.getViewportSize(),E=m.width,H=m.height;return{vs:a,fs:u,uniforms:(0,Se.Z)((0,Se.Z)({},c),{},{u_ViewportSize:[E,H]})}}}]),r}(Pv))||Ma),il,Pl;function Au(e){var i=Ll();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function Ll(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var Il=`varying vec2 v_UV; + +uniform sampler2D u_Texture; +uniform float u_Amount : 0.5; + +float rand(vec2 co) { + return fract(sin(dot(co.xy ,vec2(12.9898,78.233))) * 43758.5453); +} + +// https://github.com/evanw/glfx.js/blob/master/src/filters/adjust/noise.js +vec4 noise_filterColor(vec4 color, vec2 texCoord) { + float diff = (rand(texCoord) - 0.5) * u_Amount; + color.r += diff; + color.g += diff; + color.b += diff; + return color; +} + +void main() { + gl_FragColor = vec4(texture2D(u_Texture, v_UV)); + gl_FragColor = noise_filterColor(gl_FragColor, v_UV); +}`,Ah=`attribute vec2 a_Position; + +varying vec2 v_UV; + +void main() { + v_UV = 0.5 * (a_Position + 1.0); + gl_Position = vec4(a_Position, 0., 1.); +}`,Nh=(il=(0,sa.b2)(),il(Pl=function(e){(0,Me.Z)(r,e);var i=Au(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"setupShaders",value:function(){return this.shaderModuleService.registerModule("noise-pass",{vs:Ah,fs:Il}),this.shaderModuleService.getModule("noise-pass")}}]),r}(Pv))||Pl),kh,Xh;function xu(e){var i=Xa();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function Xa(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var vs=`attribute vec2 a_Position; + +varying vec2 v_UV; + +void main() { + v_UV = 0.5 * (a_Position + 1.0); + gl_Position = vec4(a_Position, 0., 1.); +}`,ku=`varying vec2 v_UV; + +uniform sampler2D u_Texture; + +uniform float u_Amount : 0.5; + +// https://github.com/evanw/glfx.js/blob/master/src/filters/adjust/sepia.js +vec4 sepia_filterColor(vec4 color) { + float r = color.r; + float g = color.g; + float b = color.b; + color.r = + min(1.0, (r * (1.0 - (0.607 * u_Amount))) + (g * (0.769 * u_Amount)) + (b * (0.189 * u_Amount))); + color.g = min(1.0, (r * 0.349 * u_Amount) + (g * (1.0 - (0.314 * u_Amount))) + (b * 0.168 * u_Amount)); + color.b = min(1.0, (r * 0.272 * u_Amount) + (g * 0.534 * u_Amount) + (b * (1.0 - (0.869 * u_Amount)))); + return color; +} + +void main() { + gl_FragColor = vec4(texture2D(u_Texture, v_UV)); + gl_FragColor = sepia_filterColor(gl_FragColor); +}`,yc=(kh=(0,sa.b2)(),kh(Xh=function(e){(0,Me.Z)(r,e);var i=xu(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"setupShaders",value:function(){return this.shaderModuleService.registerModule("sepia-pass",{vs,fs:ku}),this.shaderModuleService.getModule("sepia-pass")}}]),r}(Pv))||Xh),$c,Ph,zh,rp,td,md,fd=($c=(0,sa.b2)(),Ph=(0,sa.f3)(sr.IRendererService),zh=(0,sa.zY)(),$c(rp=(td=function(){function e(){(0,We.Z)(this,e),_(this,"rendererService",md,this),(0,St.Z)(this,"passes",[]),(0,St.Z)(this,"readFBO",void 0),(0,St.Z)(this,"writeFBO",void 0)}return(0,ot.Z)(e,[{key:"getReadFBO",value:function(){return this.readFBO}},{key:"getWriteFBO",value:function(){return this.writeFBO}},{key:"getCurrentFBOTex",value:function(){var r=this.rendererService,n=r.getViewportSize,t=r.createTexture2D,a=n(),u=a.width,c=a.height;return t({x:0,y:0,width:u,height:c,copy:!0})}},{key:"getReadFBOTex",value:function(){var r=this,n=this.rendererService.useFramebuffer;return new Promise(function(t){n(r.readFBO,(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:t(r.getCurrentFBOTex());case 1:case"end":return c.stop()}},a)})))})}},{key:"renderBloomPass",value:function(){var i=(0,Li.Z)(Ur().mark(function n(t,a){var u,c;return Ur().wrap(function(E){for(;;)switch(E.prev=E.next){case 0:return E.next=2,this.getReadFBOTex();case 2:u=E.sent,c=0;case 4:if(!(c<4)){E.next=11;break}return E.next=7,a.render(t,u);case 7:this.swap(),c++,E.next=4;break;case 11:case"end":return E.stop()}},n,this)}));function r(n,t){return i.apply(this,arguments)}return r}()},{key:"render",value:function(){var i=(0,Li.Z)(Ur().mark(function n(t){var a,u;return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:a=0;case 1:if(!(a0;)r=r+n*(t%i),t=Math.floor(t/i),n=n/i;return r}var Im=1,fv=(cp=(0,sa.b2)(),cm=(0,sa.f3)(sr.IShaderModuleService),cp(rm=(Bm=function(e){(0,Me.Z)(r,e);var i=Nm(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u=1&&(E(this.copyRenderTarget,function(){a.outputModel.draw({uniforms:{u_Texture:a.outputRenderTarget}})}),E(t.multiPassRenderer.getPostProcessor().getReadFBO(),function(){a.copyModel.draw({uniforms:{u_Texture:a.copyRenderTarget}})}),t.multiPassRenderer.getPostProcessor().render(t));var Ar=this.prevRenderTarget;this.prevRenderTarget=this.outputRenderTarget,this.outputRenderTarget=Ar,this.frame++,this.cameraService.clearJitterProjectionMatrix()}},{key:"isFinished",value:function(){return this.frame>=this.haltonSequence.length}},{key:"resetFrame",value:function(){this.frame=0}},{key:"stopAccumulating",value:function(){this.accumulatingId=0,window.clearTimeout(this.timer)}},{key:"createTriangleModel",value:function(t,a,u){this.shaderModuleService.registerModule(t,{vs:Vm,fs:a});var c=this.shaderModuleService.getModule(t),m=c.vs,E=c.fs,H=c.uniforms,re=this.rendererService,xe=re.createAttribute,ke=re.createBuffer,rt=re.createModel;return rt((0,Se.Z)({vs:m,fs:E,attributes:{a_Position:xe({buffer:ke({data:[-4,-4,4,-4,0,4],type:Er.FLOAT}),size:2})},uniforms:(0,Se.Z)({},H),depth:{enable:!1},count:3},u))}}]),r}(ng),A0=d(Bm.prototype,"shaderModuleService",[cm],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),Bm))||rm),Iv=new sa.W2;Iv.bind(sr.IGlobalConfigService).to(oh).inSingletonScope(),(0,sa.GW)((0,sa.b2)(),cu.EventEmitter),Iv.bind(sr.IEventEmitter).to(cu.EventEmitter);var jv=(0,Rr.Z)(Iv,!1),Qm=function(i){var r=jv.lazyInject(i);return function(n,t,a){r.call(this,n,t),a&&(a.initializer=function(){return n[t]})}},Rv=function(i){var r=jv.lazyMultiInject(i);return function(n,t,a){r.call(this,n,t),a&&(a.initializer=function(){return n[t]})}},ym=Iv,ov=0;function og(){var e=new sa.W2;return e.parent=Iv,e.bind(sr.SceneID).toConstantValue("".concat(ov++)),e.bind(sr.IShaderModuleService).to(kA).inSingletonScope(),e.bind(sr.ILayerService).to(p1).inSingletonScope(),e.bind(sr.IDebugService).to(yl).inSingletonScope(),e.bind(sr.ISceneService).to(jy).inSingletonScope(),e.bind(sr.ICameraService).to(pu).inSingletonScope(),e.bind(sr.ICoordinateSystemService).to(kn).inSingletonScope(),e.bind(sr.IInteractionService).to(qc).inSingletonScope(),e.bind(sr.IPickingService).to(rv).inSingletonScope(),e.bind(sr.IControlService).to(zc).inSingletonScope(),e.bind(sr.IMarkerService).to(wh).inSingletonScope(),e.bind(sr.IIconService).to(Fh).inSingletonScope(),e.bind(sr.IFontService).to(_h).inSingletonScope(),e.bind(sr.IPopupService).to(Jf).inSingletonScope(),e.bind(sr.INormalPass).to(Y2).whenTargetNamed("clear"),e.bind(sr.INormalPass).to(GA).whenTargetNamed("pixelPicking"),e.bind(sr.INormalPass).to(T0).whenTargetNamed("render"),e.bind(sr.INormalPass).to(fv).whenTargetNamed("taa"),e.bind(sr.IFactoryNormalPass).toFactory(function(i){return function(r){return i.container.getNamed(sr.INormalPass,r)}}),e.bind(sr.IPostProcessingPass).to(_n).whenTargetNamed("copy"),e.bind(sr.IPostProcessingPass).to(QA).whenTargetNamed("bloom"),e.bind(sr.IPostProcessingPass).to(sx).whenTargetNamed("blurH"),e.bind(sr.IPostProcessingPass).to(dx).whenTargetNamed("blurV"),e.bind(sr.IPostProcessingPass).to(Nh).whenTargetNamed("noise"),e.bind(sr.IPostProcessingPass).to(yc).whenTargetNamed("sepia"),e.bind(sr.IPostProcessingPass).to(N).whenTargetNamed("colorHalftone"),e.bind(sr.IPostProcessingPass).to(Ko).whenTargetNamed("hexagonalPixelate"),e.bind(sr.IPostProcessingPass).to($u).whenTargetNamed("ink"),e.bind(sr.IFactoryPostProcessingPass).toFactory(function(i){return function(r){var n=i.container.getNamed(sr.IPostProcessingPass,r);return n.setName(r),n}}),e}function Rm(e){var i=new sa.W2;return i.parent=e,i.bind(sr.IStyleAttributeService).to(Fy).inSingletonScope(),i.bind(sr.IMultiPassRenderer).to(VA).inSingletonScope(),i.bind(sr.IPostProcessor).to(fd).inSingletonScope(),i}var Rg=["circle","triangle","square","pentagon","hexagon","octogon","hexagram","rhombus","vesica"];function ag(e){return Rg.indexOf(e)}var Og=lo.clamp,$m=2,Em=4,P1=64,gx=128,yx=256,I_=512,_x=8192,Ax=16384,dE=32768,bx=null,R_=131072,ib=262144,ob=524288,pE=1048576,xx=2097152,Ex=4194304,ab=8388608,fy=16777216,Sx=null;function Xy(e,i){return e=Og(Math.floor(e),0,255),i=Og(Math.floor(i),0,255),256*e+i}function sb(e){var i=e.color,r=e.radius,n=e.tileX,t=e.tileY,a=e.shape,u=e.opacity,c=e.stroke,m=e.strokeWidth,E=e.strokeOpacity,H=[],re=[],xe=[],ke=[Xy(i[0],i[1]),Xy(i[2],i[3])],rt=[Xy(c[0],c[1]),Xy(c[2],c[3])];return[[-1,-1],[1,-1],[1,1],[-1,1]].forEach(function(vt){var It=(0,gi.Z)(vt,2),er=It[0],Ar=It[1];H.push([].concat(ke,[(er+1)*ab+(Ar+1)*xx+ag(a)*R_+r,(n+512)*ob+(t+512)*P1])),re.push([].concat(rt,[m,E])),xe.push([u,0,0,0])}),{packedBuffer:H,packedBuffer2:re,packedBuffer3:xe}}function Cx(e,i){if(e===0&&!i)return 0;if(e===1&&i)return 4294967295;var r=i?1:0,n=Math.floor(e*127);return n*Sx+r*fy+n*R_+r*bx+n*I_+r*yx+n*$m+r}var sg={ProjectionMatrix:"u_ProjectionMatrix",ViewMatrix:"u_ViewMatrix",ViewProjectionMatrix:"u_ViewProjectionMatrix",Zoom:"u_Zoom",ZoomScale:"u_ZoomScale",FocalDistance:"u_FocalDistance",CameraPosition:"u_CameraPosition"},zd={MapInitStart:"mapInitStart",LayerInitStart:"layerInitStart",LayerInitEnd:"layerInitEnd",SourceInitStart:"sourceInitStart",SourceInitEnd:"sourceInitEnd",ScaleInitStart:"scaleInitStart",ScaleInitEnd:"scaleInitEnd",MappingStart:"mappingStart",MappingEnd:"mappingEnd",BuildModelStart:"buildModelStart",BuildModelEnd:"buildModelEnd"},ch=function(e){return e.LINEAR="linear",e.SEQUENTIAL="sequential",e.POWER="power",e.LOG="log",e.IDENTITY="identity",e.TIME="time",e.QUANTILE="quantile",e.QUANTIZE="quantize",e.THRESHOLD="threshold",e.CAT="cat",e.DIVERGING="diverging",e}({}),_d=function(e){return e.CONSTANT="constant",e.VARIABLE="variable",e}({}),Vu=function(e){return e[e.Attribute=0]="Attribute",e[e.InstancedAttribute=1]="InstancedAttribute",e[e.Uniform=2]="Uniform",e}({}),e0=["mapload","mapchange","mapAfterFrameChange"],Jm=["loaded","fontloaded","maploaded","resize","destroy","dragstart","dragging","dragend","dragcancel"],Y0=function(e){return e.IMAGE="image",e.CUSTOMIMAGE="customImage",e.ARRAYBUFFER="arraybuffer",e.RGB="rgb",e.TERRAINRGB="terrainRGB",e.CUSTOMRGB="customRGB",e.CUSTOMARRAYBUFFER="customArrayBuffer",e.CUSTOMTERRAINRGB="customTerrainRGB",e}({}),Lg=function(){var e=(0,Li.Z)(Ur().mark(function i(r,n,t,a){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.abrupt("return",new Promise(function(m,E){n({x:r.x,y:r.y,z:r.z},function(H,re){if(H||re.length===0){E(H);return}re&&Zo([{data:re,bands:[0]}],t,a,function(xe,ke){xe?E(xe):ke&&m(ke)})})}));case 1:case"end":return c.stop()}},i)}));return function(r,n,t,a){return e.apply(this,arguments)}}(),ug=function(){var e=(0,Li.Z)(Ur().mark(function i(r,n){return Ur().wrap(function(a){for(;;)switch(a.prev=a.next){case 0:return a.abrupt("return",new Promise(function(u,c){n({x:r.x,y:r.y,z:r.z},function(m,E){if(m||!E){c(m);return}E instanceof ArrayBuffer?Ii(E,function(H,re){H&&c(H),u(re)}):E instanceof HTMLImageElement?u(E):c(m)})}));case 1:case"end":return a.stop()}},i)}));return function(r,n){return e.apply(this,arguments)}}();function ub(e,i){return Array.isArray(e)?typeof e[0]=="string"?e.map(function(r){return ud(r,i)}):e.map(function(r){return{url:ud(r.url,i),bands:r.bands||[0]}}):ud(e,i)}function lb(e){return typeof e=="string"?[{url:e,bands:[0]}]:typeof e[0]=="string"?e.map(function(i){return{url:i,bands:[0]}}):e}function hy(e,i){e.xhrCancel=function(){i.map(function(r){r.abort()})}}var Tx=function(){var e=(0,Li.Z)(Ur().mark(function i(r,n,t,a,u){var c,m,E,H,re,xe;return Ur().wrap(function(rt){for(;;)switch(rt.prev=rt.next){case 0:if(c=lb(n.url),!(c.length>1)){rt.next=15;break}return rt.next=4,UM(c,n);case 4:if(m=rt.sent,E=m.rasterFiles,H=m.xhrList,re=m.errList,hy(r,H),!(re.length>0)){rt.next=12;break}return t(re,null),rt.abrupt("return");case 12:Zo(E,a,u,t),rt.next=17;break;case 15:xe=sn(n,function(vt,It){if(vt)t(vt);else if(It){var er=[{data:It,bands:c[0].bands}];Zo(er,a,u,t)}}),hy(r,[xe]);case 17:case"end":return rt.stop()}},i)}));return function(r,n,t,a,u){return e.apply(this,arguments)}}();function UM(e,i){return Mx.apply(this,arguments)}function Mx(){return Mx=(0,Li.Z)(Ur().mark(function e(i,r){var n,t,a,u,c,m,E,H,re,xe,ke;return Ur().wrap(function(vt){for(;;)switch(vt.prev=vt.next){case 0:n=[],t=[],a=[],u=0;case 4:if(!(u1&&arguments[1]!==void 0?arguments[1]:{};if($M(e))throw new Error("tile server url is error");var r=(i==null?void 0:i.dataType)||Y0.IMAGE;r===Y0.RGB&&(r=Y0.ARRAYBUFFER);var n=function(u,c){switch(r){case Y0.IMAGE:return mE(e,u,c,i);case Y0.CUSTOMIMAGE:case Y0.CUSTOMTERRAINRGB:return ug(c,i==null?void 0:i.getCustomData);case Y0.ARRAYBUFFER:return jM(e,u,c,(i==null?void 0:i.format)||vE,i==null?void 0:i.operation);case Y0.CUSTOMARRAYBUFFER:case Y0.CUSTOMRGB:return Lg(c,i==null?void 0:i.getCustomData,(i==null?void 0:i.format)||vE,i==null?void 0:i.operation);default:return mE(e,u,c,i)}},t=(0,Se.Z)((0,Se.Z)((0,Se.Z)({},VM),i),{},{getTileData:n});return{data:e,dataArray:[],tilesetOptions:t,isTile:!0}}var GM=["extent","min","max","width","height","format","operation"];function WM(e,i){var r=i.extent,n=i.min,t=i.max,a=i.width,u=i.height,c=i.format,m=i.operation,E=(0,X0.Z)(i,GM),H;if(c===void 0||k0(e))H=Array.from(e);else{var re=Array.isArray(e)?e:[e];H=of(re,c,m)}var xe={_id:1,dataArray:[(0,Se.Z)((0,Se.Z)({_id:1,data:H,width:a,height:u},E),{},{min:n,max:t,coordinates:[[r[0],r[1]],[r[2],r[3]]]})]};return xe}var XM={tileSize:256,minZoom:0,maxZoom:1/0,zoomOffset:0},YM=function(){var e=(0,Li.Z)(Ur().mark(function i(r){return Ur().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.abrupt("return",new Promise(function(a){var u=(0,gi.Z)(r.bounds,4),c=u[0],m=u[1],E=u[2],H=u[3],re={layers:{testTile:{features:[{type:"Feature",properties:{key:r.x+"/"+r.y+"/"+r.z,x:(c+E)/2,y:(m+H)/2},geometry:{type:"LineString",coordinates:[[E,H],[E,m],[c,m],[c,m]]}}]}}};a(re)}));case 1:case"end":return t.stop()}},i)}));return function(r){return e.apply(this,arguments)}}();function KM(e,i){var r=function(a){return YM(a)},n=(0,Se.Z)((0,Se.Z)((0,Se.Z)({},XM),i),{},{getTileData:r});return{data:e,dataArray:[],tilesetOptions:n,isTile:!0}}var qM=["extent","width","height"];function QM(e,i){var r=i.extent,n=i.width,t=i.height,a=(0,X0.Z)(i,qM);e.length<3&&console.warn("RGB\u89E3\u6790\u9700\u8981\u4E09\u4E2A\u6CE2\u6BB5\u7684\u6570\u636E");for(var u=a.bands||[0,1,2],c=(0,gi.Z)(u,3),m=c[0],E=c[1],H=c[2],re=[e[m],e[E],e[H]],xe=[],ke=(a==null?void 0:a.countCut)||[2,98],rt=(0,gi.Z)(ke,2),vt=rt[0],It=rt[1],er=(a==null?void 0:a.RMinMax)||Gs(re[0],vt,It),Ar=(a==null?void 0:a.GMinMax)||Gs(re[1],vt,It),Or=(a==null?void 0:a.BMinMax)||Gs(re[2],vt,It),rn=0;rni&&(i=e[r]);return i}function i4(e){if(e.length===0)throw new Error("min requires at least one data point");for(var i=e[0],r=1;r=Math.abs(e[t])?r+=i-n+e[t]:r+=e[t]-n+i,i=n;return i+r*1}function o4(e){if(e.length===0)throw new Error("mean requires at least one data point");return _E(e)/e.length}var a4={min:i4,max:n4,mean:o4,sum:_E};function s4(e){var i=u4();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function u4(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var l4=lo.cloneDeep,AE=lo.isFunction,c4=lo.isString,f4=lo.mergeWith;function h4(e,i){if(Array.isArray(i))return i}var d4=function(e){(0,Me.Z)(r,e);var i=s4(r);function r(n,t){var a;return(0,We.Z)(this,r),a=i.call(this),(0,St.Z)((0,Fr.Z)(a),"type","source"),(0,St.Z)((0,Fr.Z)(a),"isTile",!1),(0,St.Z)((0,Fr.Z)(a),"inited",!1),(0,St.Z)((0,Fr.Z)(a),"hooks",{init:new cv}),(0,St.Z)((0,Fr.Z)(a),"parser",{type:"geojson"}),(0,St.Z)((0,Fr.Z)(a),"transforms",[]),(0,St.Z)((0,Fr.Z)(a),"cluster",!1),(0,St.Z)((0,Fr.Z)(a),"clusterOptions",{enable:!1,radius:40,maxZoom:20,zoom:-99,method:"count"}),(0,St.Z)((0,Fr.Z)(a),"invalidExtent",!1),(0,St.Z)((0,Fr.Z)(a),"dataArrayChanged",!1),(0,St.Z)((0,Fr.Z)(a),"cfg",{autoRender:!0}),a.originData=n,a.initCfg(t),a.init().then(function(){a.inited=!0,a.emit("update",{type:"inited"})}),a}return(0,ot.Z)(r,[{key:"getSourceCfg",value:function(){return this.cfg}},{key:"getClusters",value:function(t){return this.clusterIndex.getClusters(this.caculClusterExtent(2),t)}},{key:"getClustersLeaves",value:function(t){return this.clusterIndex.getLeaves(t,1/0)}},{key:"getParserType",value:function(){return this.parser.type}},{key:"updateClusterData",value:function(t){var a=this,u=this.clusterOptions,c=u.method,m=c===void 0?"sum":c,E=u.field,H=this.clusterIndex.getClusters(this.caculClusterExtent(2),Math.floor(t));this.clusterOptions.zoom=t,H.forEach(function(re){re.id||(re.properties.point_count=1)}),(E||AE(m))&&(H=H.map(function(re){var xe=re.id;if(xe){var ke=a.clusterIndex.getLeaves(xe,1/0),rt=ke.map(function(er){return er.properties}),vt;if(c4(m)&&E){var It=Up(rt,E);vt=a4[m](It)}AE(m)&&(vt=m(rt)),re.properties.stat=vt}else re.properties.point_count=1;return re})),this.data=se("geojson")({type:"FeatureCollection",features:H}),this.executeTrans()}},{key:"getFeatureById",value:function(t){var a=this.parser,u=a.type,c=u===void 0?"geojson":u,m=a.geometry;if(c==="geojson"&&!this.cluster){var E=t=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function m4(e,i){if(e){if(typeof e=="string")return xE(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return xE(e,i)}}function xE(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);rn?t:n)}}catch(Or){a.e(Or)}finally{a.f()}var m=(r+n)/2,E=y4(i,m);if(E.xOffset<=0||E.yOffset<=0)return{gridHash:{},gridOffset:E};var H={},re=bE(e),xe;try{for(re.s();!(xe=re.n()).done;){var ke=xe.value,rt=ke.coordinates[1],vt=ke.coordinates[0];if(Number.isFinite(rt)&&Number.isFinite(vt)){var It=Math.floor((rt+90)/E.yOffset),er=Math.floor((vt+180)/E.xOffset),Ar="".concat(It,"-").concat(er);H[Ar]=H[Ar]||{count:0,points:[]},H[Ar].count+=1,H[Ar].points.push(ke)}}}catch(Or){re.e(Or)}finally{re.f()}return{gridHash:H,gridOffset:E}}function y4(e,i){var r=_4(e),n=A4(i,e);return{yOffset:r,xOffset:n}}function _4(e){return e/Px*(180/Math.PI)}function A4(e,i){return i/Px*(180/Math.PI)/Math.cos(e*Math.PI/180)}function b4(e,i,r){return Object.keys(e).reduce(function(n,t,a){var u=t.split("-"),c=parseInt(u[0],10),m=parseInt(u[1],10),E={};if(r.field&&r.method){var H=Dl(e[t].points,r.field);E[r.method]=xa[r.method](H)}return Object.assign(E,{_id:a,coordinates:Ol([-180+i.xOffset*(m+.5),-90+i.yOffset*(c+.5)]),rawData:e[t].points,count:e[t].count}),n.push(E),n},[])}var I1=Math.PI/3,x4=[0,I1,2*I1,3*I1,4*I1,5*I1];function w4(e){return e[0]}function E4(e){return e[1]}function S4(){var e=0,i=0,r=1,n=1,t=w4,a=E4,u,c,m;function E(re){var xe={},ke=[],rt,vt=re.length;for(rt=0;rt1){var wn=er-rn,Cn=rn+(erSi*Si+po*po&&(rn=Cn+(Or&1?1:-1)/2,Or=qn)}var Ao=rn+"-"+Or,ma=xe[Ao];ma?ma.push(It):(ke.push(ma=xe[Ao]=[It]),ma.x=(rn+(Or&1)/2)*c,ma.y=Or*m)}return ke}function H(re){var xe=0,ke=0;return x4.map(function(rt){var vt=Math.sin(rt)*re,It=-Math.cos(rt)*re,er=vt-xe,Ar=It-ke;return xe=vt,ke=It,[er,Ar]})}return E.hexagon=function(re){return"m"+H(re==null?u:+re).join("l")+"z"},E.centers=function(){for(var re=[],xe=Math.round(i/m),ke=Math.round(e/c),rt=xe*m;rt180||Math.abs(rt[1][0])>180){if(H.x>ke){var vt=this.mapsService.lngLatToContainer([m-360,E]);H.x=vt.x}if(H.x<0){var It=this.mapsService.lngLatToContainer([m+360,E]);H.x=It.x}}(H.x>ke||H.x<0||H.y>xe||H.y<0)&&(a.style.display="none"),a.style.left=H.x+u[0]+"px",a.style.top=H.y-u[1]+"px"}}}},{key:"init",value:function(){var t=this,a=this.markerOption.element,u=this.markerOption,c=u.color,m=u.anchor;if(!a){this.defaultMarker=!0,a=Vo("div"),this.markerOption.element=a;var E=document.createElementNS("http://www.w3.org/2000/svg","svg");E.setAttributeNS(null,"display","block"),E.setAttributeNS(null,"height","48px"),E.setAttributeNS(null,"width","48px"),E.setAttributeNS(null,"viewBox","0 0 1024 1024");var H=document.createElementNS("http://www.w3.org/2000/svg","path");H.setAttributeNS(null,"d","M512 490.666667C453.12 490.666667 405.333333 442.88 405.333333 384 405.333333 325.12 453.12 277.333333 512 277.333333 570.88 277.333333 618.666667 325.12 618.666667 384 618.666667 442.88 570.88 490.666667 512 490.666667M512 85.333333C346.88 85.333333 213.333333 218.88 213.333333 384 213.333333 608 512 938.666667 512 938.666667 512 938.666667 810.666667 608 810.666667 384 810.666667 218.88 677.12 85.333333 512 85.333333Z"),H.setAttributeNS(null,"fill",c),E.appendChild(H),a.appendChild(E)}Js(a,"l7-marker"),Object.keys(this.markerOption.style||{}).forEach(function(re){var xe,ke,rt=((xe=t.markerOption)===null||xe===void 0?void 0:xe.style)&&((ke=t.markerOption)===null||ke===void 0?void 0:ke.style[re]);a&&(a.style[re]=rt)}),zn(a,m,"marker")}},{key:"registerMarkerEvent",value:function(t){t.addEventListener("click",this.onMapClick),t.addEventListener("mousemove",this.eventHandle),t.addEventListener("click",this.eventHandle),t.addEventListener("mousedown",this.eventHandle),t.addEventListener("mouseup",this.eventHandle),t.addEventListener("dblclick",this.eventHandle),t.addEventListener("contextmenu",this.eventHandle),t.addEventListener("mouseover",this.eventHandle),t.addEventListener("mouseout",this.eventHandle),t.addEventListener("touchstart",this.eventHandle),t.addEventListener("touchend",this.eventHandle)}},{key:"unRegisterMarkerEvent",value:function(){var t=this.getElement();t.removeEventListener("click",this.onMapClick),t.removeEventListener("mousemove",this.eventHandle),t.removeEventListener("click",this.eventHandle),t.removeEventListener("mousedown",this.eventHandle),t.removeEventListener("mouseup",this.eventHandle),t.removeEventListener("dblclick",this.eventHandle),t.removeEventListener("contextmenu",this.eventHandle),t.removeEventListener("mouseover",this.eventHandle),t.removeEventListener("mouseout",this.eventHandle),t.removeEventListener("touchstart",this.eventHandle),t.removeEventListener("touchend",this.eventHandle)}},{key:"polyfillEvent",value:function(t){!this.mapsService||this.mapsService.version!=="GAODE2.x"||Uu()||(t.type==="touchstart"&&(this.touchStartTime=Date.now()),t.type==="touchend"&&Date.now()-this.touchStartTime<300&&this.emit("click",{target:t,data:this.markerOption.extData,lngLat:this.lngLat}))}},{key:"addDragHandler",value:function(t){return null}},{key:"onUp",value:function(t){throw new Error("Method not implemented.")}}]),r}(cu.EventEmitter);function O4(e){var i=L4();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function L4(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var D4=lo.merge,k4=function(e){(0,Me.Z)(r,e);var i=O4(r);function r(n){var t,a;return(0,We.Z)(this,r),a=i.call(this),(0,St.Z)((0,Fr.Z)(a),"markers",[]),(0,St.Z)((0,Fr.Z)(a),"points",[]),(0,St.Z)((0,Fr.Z)(a),"clusterMarkers",[]),a.markerLayerOption=D4(a.getDefault(),n),Zs(["update"],(0,Fr.Z)(a)),a.zoom=((t=a.markerLayerOption.clusterOption)===null||t===void 0?void 0:t.zoom)||-99,a}return(0,ot.Z)(r,[{key:"getDefault",value:function(){return{cluster:!1,clusterOption:{radius:80,maxZoom:20,minZoom:0,zoom:-99,style:{},className:""}}}},{key:"addTo",value:function(t){return this.scene=t,this.mapsService=t.get(sr.IMapService),this.markerLayerOption.cluster&&(this.initCluster(),this.update(),this.mapsService.on("camerachange",this.update),this.mapsService.on("viewchange",this.update)),this.mapsService.on("camerachange",this.setContainerSize.bind(this)),this.mapsService.on("viewchange",this.setContainerSize.bind(this)),this.addMarkers(),this.inited=!0,this}},{key:"setContainerSize",value:function(){if(this.mapsService){var t=this.mapsService.getContainer();this.containerSize={containerWidth:(t==null?void 0:t.scrollWidth)||0,containerHeight:(t==null?void 0:t.scrollHeight)||0,bounds:this.mapsService.getBounds()}}}},{key:"getContainerSize",value:function(){return this.containerSize}},{key:"addMarker",value:function(t){var a=this.markerLayerOption.cluster;if(t.getMarkerLayerContainerSize=this.getContainerSize.bind(this),a&&(this.addPoint(t,this.markers.length),this.mapsService)){var u=this.mapsService.getZoom(),c=this.mapsService.getBounds();this.bbox=to(c,.5),this.zoom=Math.floor(u),this.getClusterMarker(this.bbox,this.zoom)}this.markers.push(t)}},{key:"removeMarker",value:function(t){this.markers.indexOf(t);var a=this.markers.indexOf(t);a>-1&&(this.markers.splice(a,1),this.markerLayerOption.cluster&&(this.removePoint(a),this.mapsService&&this.getClusterMarker(this.bbox,this.zoom)))}},{key:"hide",value:function(){this.markers.map(function(t){t.getElement().style.opacity="0"}),this.clusterMarkers.map(function(t){t.getElement().style.opacity="0"})}},{key:"show",value:function(){this.markers.map(function(t){t.getElement().style.opacity="1"}),this.clusterMarkers.map(function(t){t.getElement().style.opacity="1"})}},{key:"getMarkers",value:function(){var t=this.markerLayerOption.cluster;return t?this.clusterMarkers:this.markers}},{key:"getOriginMarkers",value:function(){return this.markers}},{key:"addMarkers",value:function(){var t=this;this.getMarkers().forEach(function(a){a.addTo(t.scene)})}},{key:"clear",value:function(){this.markers.forEach(function(t){t.remove()}),this.clusterMarkers.forEach(function(t){t.remove()}),this.markers=[],this.points=[],this.clusterMarkers=[]}},{key:"destroy",value:function(){this.clear(),this.removeAllListeners(),this.mapsService.off("camerachange",this.update),this.mapsService.off("viewchange",this.update),this.mapsService.off("camerachange",this.setContainerSize.bind(this)),this.mapsService.off("viewchange",this.setContainerSize.bind(this))}},{key:"addPoint",value:function(t,a){var u=t.getLnglat(),c=u.lng,m=u.lat,E={geometry:{type:"Point",coordinates:[c,m]},properties:(0,Se.Z)((0,Se.Z)({},t.getExtData()),{},{marker_id:a})};this.points.push(E),this.clusterIndex&&this.clusterIndex.load(this.points)}},{key:"removePoint",value:function(t){var a=this.points.findIndex(function(u){return u.properties.marker_id===t});a>-1&&this.points.splice(a,1),this.clusterIndex&&this.clusterIndex.load(this.points)}},{key:"initCluster",value:function(){if(this.markerLayerOption.cluster){var t=this.markerLayerOption.clusterOption,a=t.radius,u=t.minZoom,c=u===void 0?0:u,m=t.maxZoom;this.clusterIndex=new(gE())({radius:a,minZoom:c,maxZoom:m}),this.clusterIndex.load(this.points)}}},{key:"getClusterMarker",value:function(t,a){var u=this,c=t[0].concat(t[1]),m=this.clusterIndex.getClusters(c,a);this.clusterMarkers.forEach(function(E){E.remove()}),this.clusterMarkers=[],m.forEach(function(E){var H,re=u.markerLayerOption.clusterOption,xe=re.field,ke=re.method;if((H=E.properties)!==null&&H!==void 0&&H.cluster_id){var rt,vt=u.getLeaves((rt=E.properties)===null||rt===void 0?void 0:rt.cluster_id);if(E.properties.clusterData=vt,xe&&ke){var It=vt==null?void 0:vt.map(function(Ln){var wn=(0,St.Z)({},xe,Ln.properties[xe]);return wn}),er=Dl(It,xe),Ar=Gf(ke,er),Or="point_"+ke;E.properties[Or]=Ar.toFixed(2)}}var rn=u.clusterMarker(E);u.clusterMarkers.push(rn),rn.addTo(u.scene)})}},{key:"getLeaves",value:function(t){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1/0,u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;return t?this.clusterIndex.getLeaves(t,a,u):null}},{key:"clusterMarker",value:function(t){var a=this.markerLayerOption.clusterOption,u=a,c=u.element,m=c===void 0?this.generateElement.bind(this):c,E=new wE({element:m(t)}).setLnglat({lng:t.geometry.coordinates[0],lat:t.geometry.coordinates[1]});return E}},{key:"normalMarker",value:function(t){var a=t.properties.marker_id;return this.markers[a]}},{key:"update",value:function(){if(this.mapsService&&this.markers.length!==0){var t=this.mapsService.getZoom(),a=this.mapsService.getBounds();(!this.bbox||Math.abs(t-this.zoom)>=1||!zo(this.bbox,a))&&(this.bbox=to(a,.5),this.zoom=Math.floor(t),this.getClusterMarker(this.bbox,this.zoom))}}},{key:"generateElement",value:function(t){var a=Vo("div","l7-marker-cluster"),u=Vo("div","",a),c=Vo("span","",u),m=this.markerLayerOption.clusterOption,E=m.field,H=m.method;t.properties.point_count=t.properties.point_count||1;var re=E&&H?t.properties["point_"+H]||t.properties[E]:t.properties.point_count;return c.textContent=re,a}}]),r}(cu.EventEmitter),nV=A(14243);function F4(e){var i=B4();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function B4(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var dy=function(e){(0,Me.Z)(r,e);var i=F4(r);function r(n){var t;return(0,We.Z)(this,r),t=i.call(this),r.controlCount++,t.controlOption=(0,Se.Z)((0,Se.Z)({},t.getDefault(n)),n||{}),t}return(0,ot.Z)(r,[{key:"getOptions",value:function(){return this.controlOption}},{key:"setOptions",value:function(t){var a=this.getDefault(t);Object.entries(t).forEach(function(u){var c=(0,gi.Z)(u,2),m=c[0],E=c[1];E===void 0&&(t[m]=a[m])}),"position"in t&&this.setPosition(t.position),"className"in t&&this.setClassName(t.className),"style"in t&&this.setStyle(t.style),this.controlOption=(0,Se.Z)((0,Se.Z)({},this.controlOption),t)}},{key:"addTo",value:function(t){this.mapsService=t.get(sr.IMapService),this.renderService=t.get(sr.IRendererService),this.layerService=t.get(sr.ILayerService),this.controlService=t.get(sr.IControlService),this.configService=t.get(sr.IGlobalConfigService),this.scene=t.get(sr.ISceneService),this.sceneContainer=t,this.isShow=!0,this.container=this.onAdd(),Js(this.container,"l7-control");var a=this.controlOption,u=a.className,c=a.style;return u&&this.setClassName(u),c&&this.setStyle(c),this.insertContainer(),this.emit("add",this),this}},{key:"remove",value:function(){if(!this.mapsService)return this;bs(this.container),this.onRemove(),this.emit("remove",this)}},{key:"onAdd",value:function(){return Vo("div")}},{key:"onRemove",value:function(){}},{key:"show",value:function(){var t=this.container;Hu(t,"l7-control--hide"),this.isShow=!0,this.emit("show",this)}},{key:"hide",value:function(){var t=this.container;Js(t,"l7-control--hide"),this.isShow=!1,this.emit("hide",this)}},{key:"getDefault",value:function(t){return{position:nl.TOPRIGHT,name:"".concat(r.controlCount)}}},{key:"getContainer",value:function(){return this.container}},{key:"getIsShow",value:function(){return this.isShow}},{key:"_refocusOnMap",value:function(t){if(this.mapsService&&t&&t.screenX>0&&t.screenY>0){var a=this.mapsService.getContainer();a!==null&&a.focus()}}},{key:"setPosition",value:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:nl.TOPLEFT,a=this.controlService;return a&&a.removeControl(this),this.controlOption.position=t,a&&a.addControl(this,this.sceneContainer),this}},{key:"setClassName",value:function(t){var a=this.container,u=this.controlOption.className;u&&Hu(a,u),t&&Js(a,t)}},{key:"setStyle",value:function(t){var a=this.container;t?a.setAttribute("style",t):a.removeAttribute("style")}},{key:"insertContainer",value:function(){var t=this.controlOption.position,a=this.container;if(t instanceof Element)t.appendChild(a);else{var u=this.controlService.controlCorners[t];["bottomleft","bottomright","righttop","rightbottom"].includes(t)?u.insertBefore(a,u.firstChild):u.appendChild(a)}}},{key:"checkUpdateOption",value:function(t,a){return a.some(function(u){return u in t})}}]),r}(fu());(0,St.Z)(dy,"controlCount",0);function N4(e){var i=z4();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function z4(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var O_=function(e){(0,Me.Z)(r,e);var i=N4(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u0&&arguments[0]!==void 0?arguments[0]:"";return Vo("button","l7-button-control ".concat(t))}},{key:"onAdd",value:function(){this.button=this.createButton(),this.isDisable=!1;var t=this.controlOption,a=t.title,u=t.btnText,c=t.btnIcon;return this.setBtnTitle(a),this.setBtnText(u),this.setBtnIcon(c),this.button}},{key:"onRemove",value:function(){this.button=this.buttonIcon=this.buttonText=void 0,this.isDisable=!1}},{key:"setOptions",value:function(t){var a=t.title,u=t.btnText,c=t.btnIcon;this.checkUpdateOption(t,["title"])&&this.setBtnTitle(a),this.checkUpdateOption(t,["btnIcon"])&&this.setBtnIcon(c),this.checkUpdateOption(t,["btnText"])&&this.setBtnText(u),Sd((0,Qe.Z)(r.prototype),"setOptions",this).call(this,t)}},{key:"setBtnTitle",value:function(t){var a;(a=this.button)===null||a===void 0||a.setAttribute("title",t!=null?t:"")}},{key:"setBtnIcon",value:function(t){if(this.buttonIcon&&bs(this.buttonIcon),t){var a,u=(a=this.button)===null||a===void 0?void 0:a.firstChild;if(u){var c;(c=this.button)===null||c===void 0||c.insertBefore(t,u)}else{var m;(m=this.button)===null||m===void 0||m.appendChild(t)}this.buttonIcon=t}}},{key:"setBtnText",value:function(t){if(this.button)if(Hu(this.button,"l7-button-control--row"),Hu(this.button,"l7-button-control--column"),t){var a=this.buttonText;if(!a){var u;a=Vo("div","l7-button-control__text"),(u=this.button)===null||u===void 0||u.appendChild(a),this.buttonText=a}a.innerText=t,Js(this.button,this.controlOption.vertical?"l7-button-control--column":"l7-button-control--row")}else!t&&this.buttonText&&(bs(this.buttonText),this.buttonText=void 0)}}]),r}(dy);function Z4(e){var i=U4();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function U4(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var EE=function(e){(0,Me.Z)(r,e);var i=Z4(r);function r(n,t){var a;return(0,We.Z)(this,r),a=i.call(this),(0,St.Z)((0,Fr.Z)(a),"isShow",!1),(0,St.Z)((0,Fr.Z)(a),"timeout",null),(0,St.Z)((0,Fr.Z)(a),"show",function(){return a.isShow||!a.contentDOM.innerHTML||(a.resetPopperPosition(),Hu(a.popperDOM,"l7-popper-hide"),a.isShow=!0,a.option.unique&&r.conflictPopperList.forEach(function(u){u!==(0,Fr.Z)(a)&&u.isShow&&u.hide()}),a.emit("show"),window.addEventListener("pointerdown",a.onPopperUnClick)),(0,Fr.Z)(a)}),(0,St.Z)((0,Fr.Z)(a),"hide",function(){return a.isShow&&(Js(a.popperDOM,"l7-popper-hide"),a.isShow=!1,a.emit("hide"),window.removeEventListener("pointerdown",a.onPopperUnClick)),(0,Fr.Z)(a)}),(0,St.Z)((0,Fr.Z)(a),"setHideTimeout",function(){a.timeout||(a.timeout=window.setTimeout(function(){a.isShow&&(a.hide(),a.timeout=null)},300))}),(0,St.Z)((0,Fr.Z)(a),"clearHideTimeout",function(){a.timeout&&(window.clearTimeout(a.timeout),a.timeout=null)}),(0,St.Z)((0,Fr.Z)(a),"onBtnClick",function(){a.isShow?a.hide():a.show()}),(0,St.Z)((0,Fr.Z)(a),"onPopperUnClick",function(u){Cs(u.target,[".l7-button-control",".l7-popper-content"])||a.hide()}),(0,St.Z)((0,Fr.Z)(a),"onBtnMouseLeave",function(){a.setHideTimeout()}),(0,St.Z)((0,Fr.Z)(a),"onBtnMouseMove",function(){a.clearHideTimeout(),!a.isShow&&a.show()}),a.button=n,a.option=t,a.init(),t.unique&&r.conflictPopperList.push((0,Fr.Z)(a)),a}return(0,ot.Z)(r,[{key:"buttonRect",get:function(){return this.button.getBoundingClientRect()}},{key:"getPopperDOM",value:function(){return this.popperDOM}},{key:"getIsShow",value:function(){return this.isShow}},{key:"getContent",value:function(){return this.content}},{key:"setContent",value:function(t){typeof t=="string"?this.contentDOM.innerHTML=t:t instanceof HTMLElement&&(Aa(this.contentDOM),this.contentDOM.appendChild(t)),this.content=t}},{key:"init",value:function(){var t=this.option.trigger;this.popperDOM=this.createPopper(),t==="click"?this.button.addEventListener("click",this.onBtnClick):(this.button.addEventListener("mousemove",this.onBtnMouseMove),this.button.addEventListener("mouseleave",this.onBtnMouseLeave),this.popperDOM.addEventListener("mousemove",this.onBtnMouseMove),this.popperDOM.addEventListener("mouseleave",this.onBtnMouseLeave))}},{key:"destroy",value:function(){this.button.removeEventListener("click",this.onBtnClick),this.button.removeEventListener("mousemove",this.onBtnMouseMove),this.button.removeEventListener("mousemove",this.onBtnMouseLeave),this.popperDOM.removeEventListener("mousemove",this.onBtnMouseMove),this.popperDOM.removeEventListener("mouseleave",this.onBtnMouseLeave),bs(this.popperDOM)}},{key:"resetPopperPosition",value:function(){var t={},a=this.option,u=a.container,c=a.offset,m=c===void 0?[0,0]:c,E=a.placement,H=(0,gi.Z)(m,2),re=H[0],xe=H[1],ke=this.button.getBoundingClientRect(),rt=u.getBoundingClientRect(),vt=Ms(ke,rt),It=vt.left,er=vt.right,Ar=vt.top,Or=vt.bottom,rn=!1,Ln=!1;/^(left|right)/.test(E)?(E.includes("left")?t.right="".concat(ke.width+er,"px"):E.includes("right")&&(t.left="".concat(ke.width+It,"px")),E.includes("start")?t.top="".concat(Ar,"px"):E.includes("end")?t.bottom="".concat(Or,"px"):(t.top="".concat(Ar+ke.height/2,"px"),Ln=!0,t.transform="translate(".concat(re,"px, calc(").concat(xe,"px - 50%))"))):/^(top|bottom)/.test(E)&&(E.includes("top")?t.bottom="".concat(ke.height+Or,"px"):E.includes("bottom")&&(t.top="".concat(ke.height+Ar,"px")),E.includes("start")?t.left="".concat(It,"px"):E.includes("end")?t.right="".concat(er,"px"):(t.left="".concat(It+ke.width/2,"px"),rn=!0,t.transform="translate(calc(".concat(re,"px - 50%), ").concat(xe,"px)"))),t.transform="translate(calc(".concat(re,"px - ").concat(rn?"50%":"0%","), calc(").concat(xe,"px - ").concat(Ln?"50%":"0%",")");var wn=E.split("-");wn.length&&Js(this.popperDOM,wn.map(function(Cn){return"l7-popper-".concat(Cn)}).join(" ")),wo(this.popperDOM,si(t))}},{key:"createPopper",value:function(){var t=this.option,a=t.container,u=t.className,c=u===void 0?"":u,m=t.content,E=Vo("div","l7-popper l7-popper-hide ".concat(c)),H=Vo("div","l7-popper-content"),re=Vo("div","l7-popper-arrow");return E.appendChild(H),E.appendChild(re),a.appendChild(E),this.popperDOM=E,this.contentDOM=H,m&&this.setContent(m),E}}]),r}(cu.EventEmitter);(0,St.Z)(EE,"conflictPopperList",[]);function j4(e){var i=V4();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function V4(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var $4={topleft:"right-start",topcenter:"bottom",topright:"left-start",bottomleft:"right-end",bottomcenter:"top",bottomright:"left-end",lefttop:"bottom-start",leftcenter:"right",leftbottom:"top-start",righttop:"bottom-end",rightcenter:"left",rightbottom:"top-end"},SE=function(e){(0,Me.Z)(r,e);var i=j4(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getPopper",value:function(){return this.popper}},{key:"hide",value:function(){this.popper.hide(),Sd((0,Qe.Z)(r.prototype),"hide",this).call(this)}},{key:"getDefault",value:function(t){var a,u=Sd((0,Qe.Z)(r.prototype),"getDefault",this).call(this,t),c=(a=t==null?void 0:t.position)!==null&&a!==void 0?a:u.position;return(0,Se.Z)((0,Se.Z)({},Sd((0,Qe.Z)(r.prototype),"getDefault",this).call(this,t)),{},{popperPlacement:c instanceof Element?"bottom":$4[c],popperTrigger:"click"})}},{key:"onAdd",value:function(){var t=Sd((0,Qe.Z)(r.prototype),"onAdd",this).call(this);return this.initPopper(),t}},{key:"onRemove",value:function(){this.popper.destroy()}},{key:"initPopper",value:function(){var t=this,a=this.controlOption,u=a.popperClassName,c=a.popperPlacement,m=a.popperTrigger,E=this.mapsService.getMapContainer();return this.popper=new EE(this.button,{className:u,placement:c,trigger:m,container:E,unique:!0}),this.popper.on("show",function(){t.emit("popperShow",t)}).on("hide",function(){t.emit("popperHide",t)}),this.popper}},{key:"setOptions",value:function(t){if(Sd((0,Qe.Z)(r.prototype),"setOptions",this).call(this,t),this.checkUpdateOption(t,["popperPlacement","popperTrigger","popperClassName"])){var a=this.popper.getContent();this.popper.destroy(),this.initPopper(),this.popper.setContent(a)}}}]),r}(O_);function H4(e){var i=G4();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function G4(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var Yy=function(e){return e.ActiveOptionClassName="l7-select-control-item-active",e.OptionValueAttrKey="data-option-value",e.OptionIndexAttrKey="data-option-index",e}(Yy||{}),Rx=function(e){(0,Me.Z)(r,e);var i=H4(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u-1?n.selectValue.splice(m,1):n.selectValue=[].concat((0,On.Z)(n.selectValue),[c.value])}else n.selectValue=[c.value];n.setSelectValue(n.selectValue)}),n}return(0,ot.Z)(r,[{key:"setOptions",value:function(t){Sd((0,Qe.Z)(r.prototype),"setOptions",this).call(this,t);var a=t.options;a&&this.popper.setContent(this.getPopperContent(a))}},{key:"onAdd",value:function(){var t=Sd((0,Qe.Z)(r.prototype),"onAdd",this).call(this),a=this.controlOption.defaultValue;return a&&(this.selectValue=this.transSelectValue(a)),this.popper.setContent(this.getPopperContent(this.controlOption.options)),t}},{key:"getSelectValue",value:function(){return this.getIsMultiple()?this.selectValue:this.selectValue[0]}},{key:"setSelectValue",value:function(t){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,u=this.transSelectValue(t);this.optionDOMList.forEach(function(c){var m=c.getAttribute(Yy.OptionValueAttrKey),E=c.querySelector("input[type=checkbox]"),H=c.querySelector("input[type=radio]"),re=u.includes(m),xe=function(rt,vt){xn(c,Yy.ActiveOptionClassName,vt),rt&&Ns(rt,vt)};xe(E,re),xe(H,re)}),this.selectValue=u,a&&this.emit("selectChange",this.getIsMultiple()?u:u[0])}},{key:"getIsMultiple",value:function(){return!1}},{key:"getPopperContent",value:function(t){var a=this,u=this.isImageOptions(),c=Vo("div",u?"l7-select-control--image":"l7-select-control--normal");this.getIsMultiple()&&Js(c,"l7-select-control--multiple");var m=t.map(function(E,H){var re=u?a.createImageOption(E):a.createNormalOption(E);return re.setAttribute(Yy.OptionValueAttrKey,E.value),re.setAttribute(Yy.OptionIndexAttrKey,window.String(H)),re.addEventListener("click",a.onItemClick.bind(a,E)),re});return c.append.apply(c,(0,On.Z)(m)),this.optionDOMList=m,c}},{key:"createImageOption",value:function(t){var a=this.selectValue.includes(t.value),u=Vo("div","l7-select-control-item ".concat(a?Yy.ActiveOptionClassName:"")),c=Vo("img");c.setAttribute("src",t.img),qs(c),u.appendChild(c);var m=Vo("div","l7-select-control-item-row");this.getIsMultiple()&&u.appendChild(this.createCheckbox(a));var E=Vo("span");return E.innerText=t.text,m.appendChild(E),u.appendChild(m),u}},{key:"createCheckbox",value:function(t){var a=Vo("input");return a.setAttribute("type","checkbox"),t&&Ns(a,!0),a}},{key:"createRadio",value:function(t){var a=Vo("input");return a.setAttribute("type","radio"),t&&Ns(a,!0),a}},{key:"isImageOptions",value:function(){return!!this.controlOption.options.find(function(t){return t.img})}},{key:"transSelectValue",value:function(t){return Array.isArray(t)?t:[t]}}]),r}(SE),Dg=function(i){var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.classList.add("l7-iconfont"),r.setAttribute("aria-hidden","true");var n=document.createElementNS("http://www.w3.org/2000/svg","use");return n.setAttributeNS("http://www.w3.org/1999/xlink","href","#".concat(i)),r.appendChild(n),r};function W4(e){var i=X4();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function X4(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var Y4=function(e){(0,Me.Z)(r,e);var i=W4(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function q4(e,i){if(e){if(typeof e=="string")return CE(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return CE(e,i)}}function CE(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r0&&arguments[0]!==void 0?arguments[0]:document.documentElement,r=arguments.length>1?arguments[1]:void 0;return new Promise(function(n,t){var a=function c(){bv.off("change",c),n()};bv.on("change",a);var u=i[kg.requestFullscreen](r);u instanceof Promise&&u.then(a).catch(t)})},exit:function(){return new Promise(function(i,r){if(!bv.isFullscreen){i();return}var n=function a(){bv.off("change",a),i()};bv.on("change",n);var t=document[kg.exitFullscreen]();t instanceof Promise&&t.then(n).catch(r)})},toggle:function(i,r){return bv.isFullscreen?bv.exit():bv.request(i,r)},onchange:function(i){bv.on("change",i)},onerror:function(i){bv.on("error",i)},on:function(i,r){var n=ME[i];n&&document.addEventListener(n,r,!1)},off:function(i,r){var n=ME[i];n&&document.removeEventListener(n,r,!1)},raw:kg};Object.defineProperties(bv,{isFullscreen:{get:function(){return!!document[kg.fullscreenElement]}},element:{enumerable:!0,get:function(){var i;return(i=document[kg.fullscreenElement])!==null&&i!==void 0?i:void 0}},isEnabled:{enumerable:!0,get:function(){return!!document[kg.fullscreenEnabled]}}}),kg||(bv={isEnabled:!1});var Ox=bv;function Q4(e){var i=J4();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function J4(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var eP=function(e){(0,Me.Z)(r,e);var i=Q4(r);function r(n){var t;return(0,We.Z)(this,r),t=i.call(this,n),(0,St.Z)((0,Fr.Z)(t),"isFullscreen",!1),(0,St.Z)((0,Fr.Z)(t),"toggleFullscreen",(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:if(!Ox.isEnabled){c.next=3;break}return c.next=3,Ox.toggle(t.mapContainer);case 3:case"end":return c.stop()}},a)}))),(0,St.Z)((0,Fr.Z)(t),"onClick",function(){t.toggleFullscreen()}),(0,St.Z)((0,Fr.Z)(t),"onFullscreenChange",function(){t.isFullscreen=!!document.fullscreenElement;var a=t.controlOption,u=a.btnText,c=a.btnIcon,m=a.title,E=a.exitBtnText,H=a.exitBtnIcon,re=a.exitTitle;t.isFullscreen?(t.setBtnTitle(re),t.setBtnText(E),t.setBtnIcon(H)):(t.setBtnTitle(m),t.setBtnText(u),t.setBtnIcon(c)),t.emit("fullscreenChange",t.isFullscreen)}),Ox.isEnabled||console.warn("\u5F53\u524D\u6D4F\u89C8\u5668\u73AF\u5883\u4E0D\u652F\u6301\u5BF9\u5730\u56FE\u5168\u5C4F\u5316"),t}return(0,ot.Z)(r,[{key:"setOptions",value:function(t){var a=t.exitBtnText,u=t.exitBtnIcon,c=t.exitTitle;this.isFullscreen&&(this.checkUpdateOption(t,["exitBtnIcon"])&&this.setBtnIcon(u),this.checkUpdateOption(t,["exitBtnText"])&&this.setBtnText(a),this.checkUpdateOption(t,["exitTitle"])&&this.setBtnTitle(c)),Sd((0,Qe.Z)(r.prototype),"setOptions",this).call(this,t)}},{key:"onAdd",value:function(){var t=Sd((0,Qe.Z)(r.prototype),"onAdd",this).call(this);return t.addEventListener("click",this.onClick),this.mapContainer=Da(this.scene.getSceneConfig().id),this.mapContainer.addEventListener("fullscreenchange",this.onFullscreenChange),t}},{key:"onRemove",value:function(){Sd((0,Qe.Z)(r.prototype),"onRemove",this).call(this),this.mapContainer.removeEventListener("fullscreenchange",this.onFullscreenChange)}},{key:"getDefault",value:function(t){return(0,Se.Z)((0,Se.Z)({},Sd((0,Qe.Z)(r.prototype),"getDefault",this).call(this,t)),{},{title:"\u5168\u5C4F",btnIcon:Dg("l7-icon-fullscreen"),exitTitle:"\u9000\u51FA\u5168\u5C4F",exitBtnIcon:Dg("l7-icon-exit-fullscreen")})}}]),r}(O_);function tP(e){var i=rP();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function rP(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var nP=function(e){(0,Me.Z)(r,e);var i=tP(r);function r(n){var t;return(0,We.Z)(this,r),t=i.call(this,n),(0,St.Z)((0,Fr.Z)(t),"getGeoLocation",function(){return new Promise(function(a,u){window.navigator.geolocation.getCurrentPosition(function(c){var m=c.coords,E=m!=null?m:{},H=E.longitude,re=E.latitude;!isNaN(H)&&!isNaN(re)?a([H,re]):u()},function(c){u(c)})})}),(0,St.Z)((0,Fr.Z)(t),"onClick",(0,Li.Z)(Ur().mark(function a(){var u,c,m;return Ur().wrap(function(H){for(;;)switch(H.prev=H.next){case 0:if(window.navigator.geolocation){H.next=2;break}return H.abrupt("return");case 2:return u=t.controlOption.transform,H.next=5,t.getGeoLocation();case 5:if(c=H.sent,m=t.mapsService.getZoom(),H.t0=t.mapsService,H.t1=m>15?m:15,!u){H.next=15;break}return H.next=12,u(c);case 12:H.t2=H.sent,H.next=16;break;case 15:H.t2=c;case 16:H.t3=H.t2,H.t0.setZoomAndCenter.call(H.t0,H.t1,H.t3);case 18:case"end":return H.stop()}},a)}))),window.navigator.geolocation||console.warn("\u5F53\u524D\u6D4F\u89C8\u5668\u73AF\u5883\u4E0D\u652F\u6301\u83B7\u53D6\u5730\u7406\u5B9A\u4F4D"),t}return(0,ot.Z)(r,[{key:"getDefault",value:function(t){return(0,Se.Z)((0,Se.Z)({},Sd((0,Qe.Z)(r.prototype),"getDefault",this).call(this,t)),{},{title:"\u5B9A\u4F4D",btnIcon:Dg("l7-icon-reposition")})}},{key:"onAdd",value:function(){var t=Sd((0,Qe.Z)(r.prototype),"onAdd",this).call(this);return t.addEventListener("click",this.onClick),t}}]),r}(O_);function iP(e){var i=oP();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function oP(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}function PE(e){return Object.keys(e!=null?e:{}).every(function(i){return["layer","name","img"].includes(i)})}var aP=function(e){(0,Me.Z)(r,e);var i=iP(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u=10?10:u>=5?5:u>=3?3:u>=2?2:1,a*u}},{key:"updateMetric",value:function(t){var a=this.getRoundNum(t),u=a<1e3?a+" m":a/1e3+" km";this.updateScale(this.mScale,u,a/t)}},{key:"updateImperial",value:function(t){var a=t*3.2808399,u,c,m;a>5280?(u=a/5280,c=this.getRoundNum(u),this.updateScale(this.iScale,c+" mi",c/u)):(m=this.getRoundNum(a),this.updateScale(this.iScale,m+" ft",m/a))}}]),r}(dy),py,RE=(py={},(0,St.Z)(py,pf.additive,{enable:!0,func:{srcRGB:Er.ONE,dstRGB:Er.ONE,srcAlpha:1,dstAlpha:1}}),(0,St.Z)(py,pf.none,{enable:!1}),(0,St.Z)(py,pf.normal,{enable:!0,func:{srcRGB:Er.SRC_ALPHA,dstRGB:Er.ONE_MINUS_SRC_ALPHA,srcAlpha:1,dstAlpha:1}}),(0,St.Z)(py,pf.subtractive,{enable:!0,func:{srcRGB:Er.ONE,dstRGB:Er.ONE,srcAlpha:Er.ZERO,dstAlpha:Er.ONE_MINUS_SRC_COLOR},equation:{rgb:Er.FUNC_SUBTRACT,alpha:Er.FUNC_SUBTRACT}}),(0,St.Z)(py,pf.max,{enable:!0,func:{srcRGB:Er.ONE,dstRGB:Er.ONE},equation:{rgb:Er.MAX_EXT}}),(0,St.Z)(py,pf.min,{enable:!0,func:{srcRGB:Er.ONE,dstRGB:Er.ONE},equation:{rgb:Er.MIN_EXT}}),py);function OE(e){return e.map(function(i){return typeof i=="string"&&(i=[i,{}]),i})}function LE(e,i,r,n){var t=e.multiPassRenderer,a=e.getLayerConfig(),u=a.enableTAA;return u?t.add(n("taa")):t.add(n("render")),OE(i).forEach(function(c){var m=(0,gi.Z)(c,2),E=m[0],H=m[1];t.add(r(E),H)}),t.add(r("copy")),t}var AP=function(){function e(i){(0,We.Z)(this,e),this.layer=i}return(0,ot.Z)(e,[{key:"pickRender",value:function(r){var n=this.layer.getContainer(),t=n.get(sr.ILayerService),a=this.layer;if(a.tileLayer)return a.tileLayer.pickRender(r);t.renderTileLayerMask(a),a.renderModels({ispick:!0})}},{key:"pick",value:function(){var i=(0,Li.Z)(Ur().mark(function n(t,a){var u,c;return Ur().wrap(function(E){for(;;)switch(E.prev=E.next){case 0:if(u=this.layer.getContainer(),c=u.get(sr.IPickingService),t.type!=="RasterLayer"){E.next=4;break}return E.abrupt("return",this.pickRasterLayer(t,a));case 4:return this.pickRender(a),E.abrupt("return",c.pickFromPickingFBO(t,a));case 6:case"end":return E.stop()}},n,this)}));function r(n,t){return i.apply(this,arguments)}return r}()},{key:"pickRasterLayer",value:function(r,n,t){var a=this.layer.getContainer(),u=a.get(sr.IPickingService),c=a.get(sr.IMapService),m=this.layer.getSource().extent,E=ps(n.lngLat,m),H={x:n.x,y:n.y,type:n.type,lngLat:n.lngLat,target:n,rasterValue:null},re=t||r;if(E){var xe=this.readRasterValue(r,m,c,n.x,n.y);return H.rasterValue=xe,u.triggerHoverOnLayer(re,H),!0}else return H.type=n.type==="mousemove"?"mouseout":"un"+n.type,u.triggerHoverOnLayer(re,(0,Se.Z)((0,Se.Z)({},H),{},{type:"unpick"})),u.triggerHoverOnLayer(re,H),!1}},{key:"readRasterValue",value:function(r,n,t,a,u){var c=r.getSource().data.dataArray[0],m=(0,gi.Z)(n,4),E=m[0],H=E===void 0?0:E,re=m[1],xe=re===void 0?0:re,ke=m[2],rt=ke===void 0?10:ke,vt=m[3],It=vt===void 0?-10:vt,er=t.lngLatToContainer([H,xe]),Ar=t.lngLatToContainer([rt,It]),Or=Ar.x-er.x,rn=er.y-Ar.y,Ln=[(a-er.x)/Or,(u-Ar.y)/rn],wn=c.width||1,Cn=c.height||1,qn=Math.floor(Ln[0]*wn),Si=Math.floor(Ln[1]*Cn),po=Math.max(0,Si-1)*wn+qn,Ao=c.data[po];return Ao}},{key:"selectFeature",value:function(r){var n=this.layer,t=(0,gi.Z)(r,3),a=t[0],u=t[1],c=t[2];n.hooks.beforeSelect.call([a,u,c])}},{key:"highlightPickedFeature",value:function(r){var n=(0,gi.Z)(r,3),t=n[0],a=n[1],u=n[2];this.layer.hooks.beforeHighlight.call([t,a,u])}},{key:"getFeatureById",value:function(r){return this.layer.getSource().getFeatureById(r)}}]),e}(),bP=function(){function e(i){(0,We.Z)(this,e),this.layer=i;var r=this.layer.getContainer();this.rendererService=r.get(sr.IRendererService)}return(0,ot.Z)(e,[{key:"getColorTexture",value:function(r,n){var t=this.getTextureKey(r,n);return this.key===t?this.colorTexture:(this.createColorTexture(r,n),this.key=t,this.colorTexture)}},{key:"createColorTexture",value:function(r,n){var t=this.rendererService.createTexture2D,a=this.getColorRampBar(r,n),u=t({data:new Uint8Array(a.data),width:a.width,height:a.height,flipY:!1,unorm:!0});return this.colorTexture=u,u}},{key:"setColorTexture",value:function(r,n,t){this.key=this.getTextureKey(n,t),this.colorTexture=r}},{key:"destroy",value:function(){var r;(r=this.colorTexture)===null||r===void 0||r.destroy()}},{key:"getColorRampBar",value:function(r,n){switch(r.type){case"cat":return Ps(r);case"quantize":return Nr(r);case"custom":return fo(r,n);case"linear":return Do(r,n);default:return va(r)}}},{key:"getTextureKey",value:function(r,n){var t;return"".concat(r.colors.join("_"),"_").concat(r==null||(t=r.positions)===null||t===void 0?void 0:t.join("_"),"_").concat(r.type,"_").concat(n==null?void 0:n.join("_"))}}]),e}(),xP=["passes"],wP=["moduleName","vertexShader","fragmentShader","inject","triangulation","styleOption","pickingEnabled"],DE,Lx,kE;function EP(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=SP(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function SP(e,i){if(e){if(typeof e=="string")return FE(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return FE(e,i)}}function FE(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r0&&arguments[0]!==void 0?arguments[0]:{};return(0,We.Z)(this,r),n=i.call(this),(0,St.Z)((0,Fr.Z)(n),"id","".concat(zE++)),(0,St.Z)((0,Fr.Z)(n),"name","".concat(zE)),(0,St.Z)((0,Fr.Z)(n),"visible",!0),(0,St.Z)((0,Fr.Z)(n),"zIndex",0),(0,St.Z)((0,Fr.Z)(n),"inited",!1),(0,St.Z)((0,Fr.Z)(n),"layerModelNeedUpdate",!1),(0,St.Z)((0,Fr.Z)(n),"pickedFeatureID",null),(0,St.Z)((0,Fr.Z)(n),"selectedFeatureID",null),(0,St.Z)((0,Fr.Z)(n),"styleNeedUpdate",!1),(0,St.Z)((0,Fr.Z)(n),"forceRender",!1),(0,St.Z)((0,Fr.Z)(n),"clusterZoom",0),(0,St.Z)((0,Fr.Z)(n),"defaultSourceConfig",{data:[],options:{parser:{type:"json"}}}),(0,St.Z)((0,Fr.Z)(n),"dataState",{dataSourceNeedUpdate:!1,dataMappingNeedUpdate:!1,filterNeedUpdate:!1,featureScaleNeedUpdate:!1,StyleAttrNeedUpdate:!1}),(0,St.Z)((0,Fr.Z)(n),"hooks",{init:new Le,afterInit:new he,beforeRender:new he,beforeRenderData:new Be,afterRender:new cv,beforePickingEncode:new cv,afterPickingEncode:new cv,beforeHighlight:new cv(["pickedColor"]),afterHighlight:new cv,beforeSelect:new cv(["pickedColor"]),afterSelect:new cv,beforeDestroy:new cv,afterDestroy:new cv}),(0,St.Z)((0,Fr.Z)(n),"models",[]),(0,St.Z)((0,Fr.Z)(n),"startInit",!1),(0,St.Z)((0,Fr.Z)(n),"layerChildren",[]),(0,St.Z)((0,Fr.Z)(n),"masks",[]),_((0,Fr.Z)(n),"configService",kE,(0,Fr.Z)(n)),(0,St.Z)((0,Fr.Z)(n),"animateOptions",{enable:!1}),(0,St.Z)((0,Fr.Z)(n),"currentPickId",null),(0,St.Z)((0,Fr.Z)(n),"encodeStyleAttribute",{}),(0,St.Z)((0,Fr.Z)(n),"enableShaderEncodeStyles",[]),(0,St.Z)((0,Fr.Z)(n),"enableDataEncodeStyles",[]),(0,St.Z)((0,Fr.Z)(n),"pendingStyleAttributes",[]),(0,St.Z)((0,Fr.Z)(n),"scaleOptions",{}),(0,St.Z)((0,Fr.Z)(n),"animateStatus",!1),(0,St.Z)((0,Fr.Z)(n),"isDestroyed",!1),(0,St.Z)((0,Fr.Z)(n),"uniformBuffers",[]),(0,St.Z)((0,Fr.Z)(n),"encodeDataLength",0),(0,St.Z)((0,Fr.Z)(n),"sourceEvent",function(){n.dataState.dataSourceNeedUpdate=!0;var a=n.getLayerConfig();a&&a.autoFit&&n.fitBounds(a.fitBoundsOptions);var u=n.layerSource.getSourceCfg().autoRender;u&&setTimeout(function(){n.reRender()},10)}),n.name=t.name||n.id,n.zIndex=t.zIndex||0,n.rawConfig=t,n}return(0,ot.Z)(r,[{key:"addMask",value:function(t){this.masks.push(t),this.updateLayerConfig({maskLayers:this.masks}),this.enableMask()}},{key:"removeMask",value:function(t){var a=this.masks.indexOf(t);a>-1&&this.masks.splice(a,1),this.updateLayerConfig({maskLayers:this.masks})}},{key:"disableMask",value:function(){this.updateLayerConfig({enableMask:!1})}},{key:"enableMask",value:function(){this.updateLayerConfig({enableMask:!0})}},{key:"addMaskLayer",value:function(t){this.masks.push(t)}},{key:"removeMaskLayer",value:function(t){var a=this.masks.indexOf(t);a>-1&&this.masks.splice(a,1),t.destroy()}},{key:"getAttribute",value:function(t){return this.styleAttributeService.getLayerStyleAttribute(t)}},{key:"getLayerConfig",value:function(){return this.configService.getLayerConfig(this.id)}},{key:"updateLayerConfig",value:function(t){var a=this;if(Object.keys(t).map(function(c){c in a.rawConfig&&(a.rawConfig[c]=t[c])}),!this.startInit)this.needUpdateConfig=(0,Se.Z)((0,Se.Z)({},this.needUpdateConfig),t);else{var u=this.container.get(sr.SceneID);this.configService.setLayerConfig(u,this.id,(0,Se.Z)((0,Se.Z)((0,Se.Z)({},this.configService.getLayerConfig(this.id)),this.needUpdateConfig),t)),this.needUpdateConfig={}}}},{key:"setContainer",value:function(t,a){this.container=t,this.sceneContainer=a}},{key:"getContainer",value:function(){return this.container}},{key:"addPlugin",value:function(t){return this.plugins.push(t),this}},{key:"init",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u=this,c,m,E,H,re,xe,ke;return Ur().wrap(function(vt){for(;;)switch(vt.prev=vt.next){case 0:c=this.container.get(sr.SceneID),this.startInit=!0,this.configService.setLayerConfig(c,this.id,this.rawConfig),this.layerType=this.rawConfig.layerType,this.iconService=this.container.get(sr.IIconService),this.fontService=this.container.get(sr.IFontService),this.rendererService=this.container.get(sr.IRendererService),this.layerService=this.container.get(sr.ILayerService),this.debugService=this.container.get(sr.IDebugService),this.interactionService=this.container.get(sr.IInteractionService),this.pickingService=this.container.get(sr.IPickingService),this.mapService=this.container.get(sr.IMapService),m=this.getLayerConfig(),E=m.enableMultiPassRenderer,H=m.passes,E&&H!==null&&H!==void 0&&H.length&&H.length>0&&this.mapService.on("mapAfterFrameChange",function(){u.renderLayers()}),this.cameraService=this.container.get(sr.ICameraService),this.coordinateService=this.container.get(sr.ICoordinateSystemService),this.shaderModuleService=this.container.get(sr.IShaderModuleService),this.postProcessingPassFactory=this.container.get(sr.IFactoryPostProcessingPass),this.normalPassFactory=this.container.get(sr.IFactoryNormalPass),this.styleAttributeService=this.container.get(sr.IStyleAttributeService),E&&(this.multiPassRenderer=this.container.get(sr.IMultiPassRenderer),this.multiPassRenderer.setLayer(this)),this.pendingStyleAttributes.forEach(function(It){var er=It.attributeName,Ar=It.attributeField,Or=It.attributeValues,rn=It.updateOptions;u.styleAttributeService.updateStyleAttribute(er,{scale:(0,Se.Z)({field:Ar},u.splitValuesAndCallbackInAttribute(Or,Ar?void 0:u.getLayerConfig()[er]))},rn)}),this.pendingStyleAttributes=[],this.plugins=this.container.getAll(sr.ILayerPlugin),re=EP(this.plugins);try{for(re.s();!(xe=re.n()).done;)ke=xe.value,ke.apply(this,{rendererService:this.rendererService,mapService:this.mapService,styleAttributeService:this.styleAttributeService,normalPassFactory:this.normalPassFactory,postProcessingPassFactory:this.postProcessingPassFactory})}catch(It){re.e(It)}finally{re.f()}return this.layerPickService=new AP(this),this.textureService=new bP(this),this.log(zd.LayerInitStart),vt.next=31,this.hooks.init.promise();case 31:this.log(zd.LayerInitEnd),this.inited=!0,this.emit("inited",{target:this,type:"inited"}),this.emit("add",{target:this,type:"add"}),this.hooks.afterInit.call();case 36:case"end":return vt.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"log",value:function(t){var a,u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"init";if(!(this.tileLayer||this.isTileLayer)){var c="".concat(this.id,".").concat(u,".").concat(t),m={id:this.id,type:this.type};(a=this.debugService)===null||a===void 0||a.log(c,m)}}},{key:"updateModelData",value:function(t){t.attributes&&t.elements?this.models.map(function(a){a.updateAttributesAndElements(t.attributes,t.elements)}):console.warn("data error")}},{key:"setLayerPickService",value:function(t){this.layerPickService=t}},{key:"prepareBuildModel",value:function(){Object.keys(this.needUpdateConfig||{}).length!==0&&this.updateLayerConfig({});var t=this.getLayerConfig(),a=t.animateOption;a!=null&&a.enable&&(this.layerService.startAnimate(),this.animateStatus=!0)}},{key:"color",value:function(t,a,u){return this.updateStyleAttribute("color",t,a,u),this}},{key:"texture",value:function(t,a,u){return this.updateStyleAttribute("texture",t,a,u),this}},{key:"rotate",value:function(t,a,u){return this.updateStyleAttribute("rotate",t,a,u),this}},{key:"size",value:function(t,a,u){return this.updateStyleAttribute("size",t,a,u),this}},{key:"filter",value:function(t,a,u){var c=this.updateStyleAttribute("filter",t,a,u);return this.dataState.dataSourceNeedUpdate=c&&this.inited,this}},{key:"shape",value:function(t,a,u){this.shapeOption={field:t,values:a};var c=this.updateStyleAttribute("shape",t,a,u);return this.dataState.dataSourceNeedUpdate=c&&this.inited,this}},{key:"label",value:function(t,a,u){return this.pendingStyleAttributes.push({attributeName:"label",attributeField:t,attributeValues:a,updateOptions:u}),this}},{key:"animate",value:function(t){var a={};return Hm(t)?(a.enable=!0,a=(0,Se.Z)((0,Se.Z)({},a),t)):a.enable=t,this.updateLayerConfig({animateOption:a}),this}},{key:"source",value:function(t,a){return(t==null?void 0:t.type)==="source"?(this.setSource(t),this):(this.sourceOption={data:t,options:a},this.clusterZoom=0,this)}},{key:"setData",value:function(t,a){var u=this;return this.inited?(this.log(zd.SourceInitStart,zl.UPDATE),this.layerSource.setData(t,a),this.log(zd.SourceInitEnd,zl.UPDATE)):this.on("inited",function(){u.log(zd.SourceInitStart,zl.UPDATE);var c=u.getSource();c?u.layerSource.setData(t,a):u.source(new Ix(t,a)),u.layerSource.once("update",function(){u.log(zd.SourceInitEnd,zl.UPDATE)})}),this}},{key:"style",value:function(t){var a=this,u=t.passes,c=(0,X0.Z)(t,xP);u&&OE(u).forEach(function(E){var H=a.multiPassRenderer.getPostProcessor().getPostProcessingPassByName(E[0]);H&&H.updateOptions(E[1])}),c.borderColor&&(c.stroke=c.borderColor),c.borderWidth&&(c.strokeWidth=c.borderWidth);var m=c;return Object.keys(c).forEach(function(E){var H=c[E];Array.isArray(H)&&H.length===2&&!NE(H[0])&&!NE(H[1])&&(m[E]={field:H[0],value:H[1]})}),this.encodeStyle(m),this.updateLayerConfig(m),this}},{key:"encodeStyle",value:function(t){var a=this;Object.keys(t).forEach(function(u){[].concat((0,On.Z)(a.enableShaderEncodeStyles),(0,On.Z)(a.enableDataEncodeStyles)).includes(u)&&MP(t[u])&&(t[u].field||t[u].value)&&!Dx(a.encodeStyleAttribute[u],t[u])?(a.encodeStyleAttribute[u]=t[u],a.updateStyleAttribute(u,t[u].field,t[u].value),a.inited&&(a.dataState.dataMappingNeedUpdate=!0)):a.encodeStyleAttribute[u]&&(delete a.encodeStyleAttribute[u],a.dataState.dataSourceNeedUpdate=!0)})}},{key:"scale",value:function(t,a){var u=(0,Se.Z)({},this.scaleOptions);if(Hm(t)?this.scaleOptions=(0,Se.Z)((0,Se.Z)({},this.scaleOptions),t):this.scaleOptions[t]=a,this.styleAttributeService&&!Dx(u,this.scaleOptions)){var c=Hm(t)?t:(0,St.Z)({},t,a);this.styleAttributeService.updateScaleAttribute(c)}return this}},{key:"renderLayers",value:function(){this.rendering=!0,this.layerService.reRender(),this.rendering=!1}},{key:"prerender",value:function(){}},{key:"render",value:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return this.tileLayer?(this.tileLayer.render(),this):(this.layerService.beforeRenderData(this),this.encodeDataLength<=0&&!this.forceRender?this:(this.renderModels(t),this))}},{key:"renderMultiPass",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:if(!(this.encodeDataLength<=0&&!this.forceRender)){c.next=2;break}return c.abrupt("return");case 2:if(!(this.multiPassRenderer&&this.multiPassRenderer.getRenderFlag())){c.next=7;break}return c.next=5,this.multiPassRenderer.render();case 5:c.next=8;break;case 7:this.multiPassRenderer?this.renderModels():this.renderModels();case 8:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"active",value:function(t){var a={};return a.enableHighlight=Hm(t)?!0:t,Hm(t)?(a.enableHighlight=!0,t.color&&(a.highlightColor=t.color),t.mix&&(a.activeMix=t.mix)):a.enableHighlight=!!t,this.updateLayerConfig(a),this}},{key:"setActive",value:function(t,a){var u=this;if(Hm(t)){var c=t.x,m=c===void 0?0:c,E=t.y,H=E===void 0?0:E;this.updateLayerConfig({highlightColor:Hm(a)?a.color:this.getLayerConfig().highlightColor,activeMix:Hm(a)?a.mix:this.getLayerConfig().activeMix}),this.pick({x:m,y:H})}else this.updateLayerConfig({pickedFeatureID:t,highlightColor:Hm(a)?a.color:this.getLayerConfig().highlightColor,activeMix:Hm(a)?a.mix:this.getLayerConfig().activeMix}),this.hooks.beforeHighlight.call(ba(t)).then(function(){setTimeout(function(){u.reRender()},1)})}},{key:"select",value:function(t){var a={};return a.enableSelect=Hm(t)?!0:t,Hm(t)?(a.enableSelect=!0,t.color&&(a.selectColor=t.color),t.mix&&(a.selectMix=t.mix)):a.enableSelect=!!t,this.updateLayerConfig(a),this}},{key:"setSelect",value:function(t,a){var u=this;if(Hm(t)){var c=t.x,m=c===void 0?0:c,E=t.y,H=E===void 0?0:E;this.updateLayerConfig({selectColor:Hm(a)?a.color:this.getLayerConfig().selectColor,selectMix:Hm(a)?a.mix:this.getLayerConfig().selectMix}),this.pick({x:m,y:H})}else this.updateLayerConfig({pickedFeatureID:t,selectColor:Hm(a)?a.color:this.getLayerConfig().selectColor,selectMix:Hm(a)?a.mix:this.getLayerConfig().selectMix}),this.hooks.beforeSelect.call(ba(t)).then(function(){setTimeout(function(){u.reRender()},1)})}},{key:"setBlend",value:function(t){return this.updateLayerConfig({blend:t}),this.reRender(),this}},{key:"show",value:function(){return this.updateLayerConfig({visible:!0}),this.reRender(),this.emit("show"),this}},{key:"hide",value:function(){return this.updateLayerConfig({visible:!1}),this.reRender(),this.emit("hide"),this}},{key:"setIndex",value:function(t){return this.zIndex=t,this.layerService.updateLayerRenderList(),this.layerService.renderLayers(),this}},{key:"setCurrentPickId",value:function(t){this.currentPickId=t}},{key:"getCurrentPickId",value:function(){return this.currentPickId}},{key:"setCurrentSelectedId",value:function(t){this.selectedFeatureID=t}},{key:"getCurrentSelectedId",value:function(){return this.selectedFeatureID}},{key:"isVisible",value:function(){var t=this.mapService.getZoom(),a=this.getLayerConfig(),u=a.visible,c=a.minZoom,m=c===void 0?-1/0:c,E=a.maxZoom,H=E===void 0?1/0:E;return!!u&&t>=m&&t0&&arguments[0]!==void 0?arguments[0]:!0;if(!this.isDestroyed){(t=this.layerModel)===null||t===void 0||t.uniformBuffers.forEach(function(xe){xe.destroy()}),this.layerChildren.map(function(xe){return xe.destroy(!1)}),this.layerChildren=[];var H=this.getLayerConfig(),re=H.maskfence;re&&(this.masks.map(function(xe){return xe.destroy(!1)}),this.masks=[]),this.hooks.beforeDestroy.call(),this.layerSource.off("update",this.sourceEvent),(a=this.multiPassRenderer)===null||a===void 0||a.destroy(),this.textureService.destroy(),this.styleAttributeService.clearAllAttributes(),this.hooks.afterDestroy.call(),(u=this.layerModel)===null||u===void 0||u.clearModels(E),(c=this.tileLayer)===null||c===void 0||c.destroy(),this.models=[],(m=this.debugService)===null||m===void 0||m.removeLog(this.id),this.emit("remove",{target:this,type:"remove"}),this.emit("destroy",{target:this,type:"destroy"}),this.removeAllListeners(),this.isDestroyed=!0}}},{key:"clear",value:function(){this.styleAttributeService.clearAllAttributes()}},{key:"clearModels",value:function(){var t;this.models.forEach(function(a){return a.destroy()}),(t=this.layerModel)===null||t===void 0||t.clearModels(),this.models=[]}},{key:"isDirty",value:function(){return!!(this.styleAttributeService.getLayerStyleAttributes()||[]).filter(function(t){return t.needRescale||t.needRemapping||t.needRegenerateVertices}).length}},{key:"setSource",value:function(t){var a=this;if(this.layerSource&&this.layerSource.off("update",this.sourceEvent),this.layerSource=t,this.clusterZoom=0,this.inited&&this.layerSource.cluster){var u=this.mapService.getZoom();this.layerSource.updateClusterData(u)}this.layerSource.inited&&this.sourceEvent(),this.layerSource.on("update",function(c){var m=c.type;if(a.coordCenter===void 0){var E,H=a.layerSource.center;a.coordCenter=H,(E=a.mapService)!==null&&E!==void 0&&E.setCoordCenter&&a.mapService.setCoordCenter(H)}if(m==="update"){if(a.tileLayer){a.tileLayer.reload();return}a.sourceEvent()}})}},{key:"getSource",value:function(){return this.layerSource}},{key:"getScaleOptions",value:function(){return this.scaleOptions}},{key:"setEncodedData",value:function(t){this.encodedData=t,this.encodeDataLength=t.length}},{key:"getEncodedData",value:function(){return this.encodedData}},{key:"getScale",value:function(t){return this.styleAttributeService.getLayerAttributeScale(t)}},{key:"getLegend",value:function(t){var a,u,c,m=this.styleAttributeService.getLayerStyleAttribute(t),E=(m==null||(a=m.scale)===null||a===void 0?void 0:a.scalers)||[];return{type:(u=E[0].option)===null||u===void 0?void 0:u.type,field:m==null||(c=m.scale)===null||c===void 0?void 0:c.field,items:this.getLegendItems(t)}}},{key:"getLegendItems",value:function(t){var a=this.styleAttributeService.getLayerAttributeScale(t);if(!a)return[];if(a.invertExtent){var u=a.range().map(function(E){return(0,St.Z)({value:a.invertExtent(E)},t,E)});return u}else if(a.ticks){var c=a.ticks().map(function(E){return(0,St.Z)({value:E},t,a(E))});return c}else if(a!=null&&a.domain){var m=a.domain().filter(function(E){return!PP(E)}).map(function(E){return(0,St.Z)({value:E},t,a(E))});return m}return[]}},{key:"pick",value:function(t){var a=t.x,u=t.y;this.interactionService.triggerHover({x:a,y:u})}},{key:"boxSelect",value:function(t,a){this.pickingService.boxPickLayer(this,t,a)}},{key:"buildLayerModel",value:function(){var n=(0,Li.Z)(Ur().mark(function a(u){var c=this,m,E,H,re,xe,ke,rt,vt,It,er,Ar,Or,rn,Ln;return Ur().wrap(function(Cn){for(;;)switch(Cn.prev=Cn.next){case 0:return m=u.moduleName,E=u.vertexShader,H=u.fragmentShader,re=u.inject,xe=u.triangulation,ke=u.styleOption,rt=u.pickingEnabled,vt=rt===void 0?!0:rt,It=(0,X0.Z)(u,wP),this.shaderModuleService.registerModule(m,{vs:E,fs:H,inject:re}),er=this.shaderModuleService.getModule(m),Ar=er.vs,Or=er.fs,rn=er.uniforms,Ln=this.rendererService.createModel,Cn.abrupt("return",new Promise(function(qn){var Si=c.styleAttributeService.createAttributesAndIndices(c.encodedData,xe,ke),po=Si.attributes,Ao=Si.elements,ma=Si.count,Ya=[].concat((0,On.Z)(c.layerModel.uniformBuffers),(0,On.Z)(c.rendererService.uniformBuffers),[c.getLayerUniformBuffer()]);vt&&Ya.push(c.getPickingUniformBuffer());var fs=(0,Se.Z)({attributes:po,uniforms:rn,fs:Or,vs:Ar,elements:Ao,blend:RE[pf.normal],uniformBuffers:Ya,textures:c.layerModel.textures},It);ma&&(fs.count=ma);var bf=Ln(fs);qn(bf)}));case 5:case"end":return Cn.stop()}},a,this)}));function t(a){return n.apply(this,arguments)}return t}()},{key:"createAttributes",value:function(t){var a=t.triangulation,u=this.styleAttributeService.createAttributes(this.encodedData,a),c=u.attributes;return c}},{key:"getTime",value:function(){return this.layerService.clock.getDelta()}},{key:"setAnimateStartTime",value:function(){this.animateStartTime=this.layerService.clock.getElapsedTime()}},{key:"stopAnimate",value:function(){this.animateStatus&&(this.layerService.stopAnimate(),this.animateStatus=!1,this.updateLayerConfig({animateOption:{enable:!1}}))}},{key:"getLayerAnimateTime",value:function(){return this.layerService.clock.getElapsedTime()-this.animateStartTime}},{key:"needPick",value:function(t){var a=this.getLayerConfig(),u=a.enableHighlight,c=u===void 0?!0:u,m=a.enableSelect,E=m===void 0?!0:m,H=this.eventNames().indexOf(t)!==-1||this.eventNames().indexOf("un"+t)!==-1;return(t==="click"||t==="dblclick")&&E&&(H=!0),t==="mousemove"&&(c||this.eventNames().indexOf("mouseenter")!==-1||this.eventNames().indexOf("unmousemove")!==-1||this.eventNames().indexOf("mouseout")!==-1)&&(H=!0),this.isVisible()&&H}},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:throw new Error("Method not implemented.");case 1:case"end":return c.stop()}},a)}));function t(){return n.apply(this,arguments)}return t}()},{key:"rebuildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.next=2,this.buildModels();case 2:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"renderMulPass",value:function(){var n=(0,Li.Z)(Ur().mark(function a(u){return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return m.next=2,u.render();case 2:case"end":return m.stop()}},a)}));function t(a){return n.apply(this,arguments)}return t}()},{key:"renderModels",value:function(){var t=this,a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return this.encodeDataLength<=0&&!this.forceRender?(this.clearModels(),this):(this.hooks.beforeRender.call(),this.models.forEach(function(u){u.draw({uniforms:t.layerModel.getUninforms(),blend:t.layerModel.getBlend(),stencil:t.layerModel.getStencil(a),textures:t.layerModel.textures},(a==null?void 0:a.ispick)||!1)}),this.hooks.afterRender.call(),this)}},{key:"updateStyleAttribute",value:function(t,a,u,c){var m=this.configService.getAttributeConfig(this.id)||{};return Dx(m[t],{field:a,values:u})?!1:(["color","size","texture","rotate","filter","label","shape"].indexOf(t)!==-1&&this.configService.setAttributeConfig(this.id,(0,St.Z)({},t,{field:a,values:u})),this.startInit?this.styleAttributeService.updateStyleAttribute(t,{scale:(0,Se.Z)({field:a},this.splitValuesAndCallbackInAttribute(u,this.getLayerConfig()[a]))},c):this.pendingStyleAttributes.push({attributeName:t,attributeField:a,attributeValues:u,updateOptions:c}),!0)}},{key:"getLayerAttributeConfig",value:function(){return this.configService.getAttributeConfig(this.id)}},{key:"getShaderPickStat",value:function(){return this.layerService.getShaderPickStat()}},{key:"setEarthTime",value:function(t){console.warn("empty fn")}},{key:"processData",value:function(t){return t}},{key:"getModelType",value:function(){throw new Error("Method not implemented.")}},{key:"getDefaultConfig",value:function(){return{}}},{key:"initLayerModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c;return Ur().wrap(function(E){for(;;)switch(E.prev=E.next){case 0:return this.models.forEach(function(H){return H.destroy()}),this.models=[],this.uniformBuffers.forEach(function(H){H.destroy()}),this.uniformBuffers=[],u=this.rendererService.createBuffer({data:new Float32Array(20).fill(0),isUBO:!0}),this.uniformBuffers.push(u),c=this.rendererService.createBuffer({data:new Float32Array(20).fill(0),isUBO:!0}),this.uniformBuffers.push(c),E.next=10,this.layerModel.initModels();case 10:this.models=E.sent;case 11:case"end":return E.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"getLayerUniformBuffer",value:function(){return this.uniformBuffers[0]}},{key:"getPickingUniformBuffer",value:function(){return this.uniformBuffers[1]}},{key:"reRender",value:function(){this.inited&&this.layerService.reRender()}},{key:"splitValuesAndCallbackInAttribute",value:function(t){return{values:BE(t)?void 0:t,callback:BE(t)?t:void 0}}}]),r}(cu.EventEmitter),kE=d(Lx.prototype,"configService",[DE],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),Lx);function IP(e,i){return{enable:e,mask:255,func:{cmp:Er.EQUAL,ref:i?1:0,mask:1}}}function ZE(e){return e.maskOperation===Jc.OR?{enable:!0,mask:255,func:{cmp:Er.ALWAYS,ref:1,mask:255},opFront:{fail:Er.KEEP,zfail:Er.REPLACE,zpass:Er.REPLACE}}:{enable:!0,mask:255,func:{cmp:e.stencilType===ec.SINGLE||e.stencilIndex===0?Er.ALWAYS:Er.LESS,ref:e.stencilType===ec.SINGLE?1:e.stencilIndex===0?2:1,mask:255},opFront:{fail:Er.KEEP,zfail:Er.REPLACE,zpass:Er.REPLACE}}}var Gc=function(e){return e[e.POSITION=0]="POSITION",e[e.COLOR=1]="COLOR",e[e.VERTEX_ID=2]="VERTEX_ID",e[e.PICKING_COLOR=3]="PICKING_COLOR",e[e.STROKE=4]="STROKE",e[e.OPACITY=5]="OPACITY",e[e.OFFSETS=6]="OFFSETS",e[e.ROTATION=7]="ROTATION",e[e.EXTRUSION_BASE=8]="EXTRUSION_BASE",e[e.SIZE=9]="SIZE",e[e.SHAPE=10]="SHAPE",e[e.EXTRUDE=11]="EXTRUDE",e[e.MAX=12]="MAX",e[e.NORMAL=13]="NORMAL",e[e.UV=14]="UV",e[e.LINEAR=15]="LINEAR",e}({});function RP(e){switch(e){case"rotation":return{name:"Rotation",type:Vu.Attribute,descriptor:{name:"a_Rotation",shaderLocation:Gc.ROTATION,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(r){var n=r.rotation,t=n===void 0?0:n;return Array.isArray(t)?[t[0]]:[t]}}};case"stroke":return{name:"stroke",type:Vu.Attribute,descriptor:{name:"a_Stroke",shaderLocation:Gc.STROKE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:4,update:function(r){var n=r.stroke,t=n===void 0?[1,1,1,1]:n;return t}}};case"opacity":return{name:"opacity",type:Vu.Attribute,descriptor:{name:"a_Opacity",shaderLocation:Gc.OPACITY,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(r){var n=r.opacity,t=n===void 0?1:n;return[t]}}};case"extrusionBase":return{name:"extrusionBase",type:Vu.Attribute,descriptor:{name:"a_ExtrusionBase",shaderLocation:Gc.EXTRUSION_BASE,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(r){var n=r.extrusionBase,t=n===void 0?0:n;return[t]}}};case"offsets":return{name:"offsets",type:Vu.Attribute,descriptor:{name:"a_Offsets",shaderLocation:Gc.OFFSETS,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:2,update:function(r){var n=r.offsets;return n}}};case"thetaOffset":return{name:"thetaOffset",type:Vu.Attribute,descriptor:{name:"a_ThetaOffset",shaderLocation:15,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(r){var n=r.thetaOffset,t=n===void 0?1:n;return[t]}}};default:return}}var OP={opacity:1,stroke:[1,0,0,1],offsets:[0,0],rotation:0,extrusionBase:0,strokeOpacity:1,thetaOffset:.314},cb={opacity:"float",stroke:"vec4",offsets:"vec2",textOffset:"vec2",rotation:"float",extrusionBase:"float",strokeOpacity:"float",thetaOffset:"float"};function iV(e){var i="";return Object.keys(e).forEach(function(r){var n=e[r];Array.isArray(n)?i+="vec".concat(n.length," ").concat(r,`; +`):i+="flot ".concat(r,`; +`)}),i}function UE(e){return Math.max(Math.ceil(e/4)*4,4)}var jE,kx,VE,Fx={opacity:Gc.OPACITY,stroke:Gc.STROKE,offsets:Gc.OFFSETS,rotation:Gc.ROTATION,extrusionBase:Gc.EXTRUSION_BASE,thetaOffset:15},Kd=(jE=Qm(sr.IGlobalConfigService),kx=function(){function e(i){(0,We.Z)(this,e),(0,St.Z)(this,"uniformBuffers",[]),(0,St.Z)(this,"textures",[]),(0,St.Z)(this,"preStyleAttribute",{}),(0,St.Z)(this,"encodeStyleAttribute",{}),_(this,"configService",VE,this),this.layer=i,this.rendererService=i.getContainer().get(sr.IRendererService),this.pickingService=i.getContainer().get(sr.IPickingService),this.shaderModuleService=i.getContainer().get(sr.IShaderModuleService),this.styleAttributeService=i.getContainer().get(sr.IStyleAttributeService),this.mapService=i.getContainer().get(sr.IMapService),this.iconService=i.getContainer().get(sr.IIconService),this.fontService=i.getContainer().get(sr.IFontService),this.cameraService=i.getContainer().get(sr.ICameraService),this.layerService=i.getContainer().get(sr.ILayerService),this.registerStyleAttribute(),this.registerBuiltinAttributes(),this.startModelAnimate();var r=this.rendererService.createTexture2D;this.createTexture2D=r}return(0,ot.Z)(e,[{key:"getBlend",value:function(){var r=this.layer.getLayerConfig(),n=r.blend,t=n===void 0?"normal":n;return RE[pf[t]]}},{key:"getStencil",value:function(r){var n=this.layer.getLayerConfig(),t=n.mask,a=t===void 0?!1:t,u=n.maskInside,c=u===void 0?!0:u,m=n.enableMask,E=n.maskOperation,H=E===void 0?Jc.AND:E;if(this.layer.type==="MaskLayer")return ZE({isStencil:!0,stencilType:ec.SINGLE});if(r.isStencil)return ZE((0,Se.Z)((0,Se.Z)({},r),{},{maskOperation:H}));var re=a||m&&this.layer.masks.length!==0||this.layer.tileMask!==void 0;return IP(re,c)}},{key:"getDefaultStyle",value:function(){return{}}},{key:"getUninforms",value:function(){var r=this.getCommonUniformsInfo(),n=this.getUniformsBufferInfo(this.getStyleAttribute());this.updateStyleUnifoms();var t=(0,Se.Z)((0,Se.Z)({},n.uniformsOption),r.uniformsOption);return!this.rendererService.hasOwnProperty("device")&&this.textures&&this.textures.length===1&&(t.u_texture=this.textures[0]),t}},{key:"getAnimateUniforms",value:function(){return{}}},{key:"needUpdate",value:function(){var i=(0,Li.Z)(Ur().mark(function n(){return Ur().wrap(function(a){for(;;)switch(a.prev=a.next){case 0:return a.abrupt("return",!1);case 1:case"end":return a.stop()}},n)}));function r(){return i.apply(this,arguments)}return r}()},{key:"buildModels",value:function(){var i=(0,Li.Z)(Ur().mark(function n(){return Ur().wrap(function(a){for(;;)switch(a.prev=a.next){case 0:throw new Error("Method not implemented.");case 1:case"end":return a.stop()}},n)}));function r(){return i.apply(this,arguments)}return r}()},{key:"initModels",value:function(){var i=(0,Li.Z)(Ur().mark(function n(){return Ur().wrap(function(a){for(;;)switch(a.prev=a.next){case 0:throw new Error("Method not implemented.");case 1:case"end":return a.stop()}},n)}));function r(){return i.apply(this,arguments)}return r}()},{key:"clearModels",value:function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0}},{key:"getAttribute",value:function(){throw new Error("Method not implemented.")}},{key:"prerender",value:function(){}},{key:"render",value:function(r){throw new Error("Method not implemented.")}},{key:"registerBuiltinAttributes",value:function(){throw new Error("Method not implemented.")}},{key:"animateOption2Array",value:function(r){return[r.enable?0:1,r.duration||4,r.interval||.2,r.trailLength||.1]}},{key:"startModelAnimate",value:function(){var r=this.layer.getLayerConfig(),n=r.animateOption;n.enable&&this.layer.setAnimateStartTime()}},{key:"getInject",value:function(){var r=this.layer.encodeStyleAttribute,n="",t=[];this.layer.enableShaderEncodeStyles.forEach(function(c){r[c]?n+="#define USE_ATTRIBUTE_".concat(c.toUpperCase(),` 0.0; + +`):t.push(" ".concat(cb[c]," u_").concat(c,";"));var m=Fx[c];!m&&c==="THETA_OFFSET"&&(m=15),n+=` + #ifdef USE_ATTRIBUTE_`.concat(c.toUpperCase(),` + layout(location = `).concat(Fx[c],") in ").concat(cb[c]," a_").concat(c.charAt(0).toUpperCase()+c.slice(1),`; + #endif + + `)});var a=t.length?` +layout(std140) uniform AttributeUniforms { +`.concat(t.join(` +`),` +}; + `):"";n+=a;var u="";return this.layer.enableShaderEncodeStyles.forEach(function(c){u+=` + + #ifdef USE_ATTRIBUTE_`.concat(c.toUpperCase(),` + `).concat(cb[c]," ").concat(c," = a_").concat(c.charAt(0).toUpperCase()+c.slice(1),`; + #else + `).concat(cb[c]," ").concat(c," = u_").concat(c,`; + #endif + + `)}),{"vs:#decl":n,"fs:#decl":a,"vs:#main-start":u}}},{key:"getStyleAttribute",value:function(){var r=this,n={};return this.layer.enableShaderEncodeStyles.forEach(function(t){if(!r.layer.encodeStyleAttribute[t]){var a=r.layer.getLayerConfig()[t],u=typeof a=="undefined"?OP[t]:a;t==="stroke"&&(u=Lo(u)),n["u_"+t]=u}}),n}},{key:"registerStyleAttribute",value:function(){var r=this;Object.keys(this.layer.encodeStyleAttribute).forEach(function(n){var t=RP(n);t&&(r.styleAttributeService.registerStyleAttribute(t),t.descriptor&&(t.descriptor.shaderLocation=Fx[n]))})}},{key:"updateEncodeAttribute",value:function(r,n){this.encodeStyleAttribute[r]=n}},{key:"initUniformsBuffer",value:function(){var r=this.getUniformsBufferInfo(this.getStyleAttribute()),n=this.getCommonUniformsInfo();r.uniformsLength!==0&&(this.attributeUnifoms=this.rendererService.createBuffer({data:new Float32Array(UE(r.uniformsLength)).fill(0),isUBO:!0}),this.uniformBuffers.push(this.attributeUnifoms)),n.uniformsLength!==0&&(this.commonUnifoms=this.rendererService.createBuffer({data:new Float32Array(UE(n.uniformsLength)).fill(0),isUBO:!0}),this.uniformBuffers.push(this.commonUnifoms))}},{key:"getUniformsBufferInfo",value:function(r){var n=0,t=[];return Object.values(r).forEach(function(a){Array.isArray(a)?(t.push.apply(t,(0,On.Z)(a)),n+=a.length):typeof a=="number"?(t.push(a),n+=1):typeof a=="boolean"&&(t.push(Number(a)),n+=1)}),{uniformsOption:r,uniformsLength:n,uniformsArray:t}}},{key:"getCommonUniformsInfo",value:function(){return{uniformsLength:0,uniformsArray:[],uniformsOption:{}}}},{key:"updateStyleUnifoms",value:function(){var r,n,t=this.getUniformsBufferInfo(this.getStyleAttribute()),a=t.uniformsArray,u=this.getCommonUniformsInfo(),c=u.uniformsArray;(r=this.attributeUnifoms)===null||r===void 0||r.subData({offset:0,data:new Uint8Array(new Float32Array(a).buffer)}),(n=this.commonUnifoms)===null||n===void 0||n.subData({offset:0,data:new Uint8Array(new Float32Array(c).buffer)})}}]),e}(),VE=d(kx.prototype,"configService",[jE],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),kx),LP=function(e){return e[e.solid=0]="solid",e[e.dash=1]="dash",e}({}),Bx=function(e){return e.VERTICAL="vertical",e.HORIZONTAL="horizontal",e}({}),$E=function(e){return e.NORMAL="normal",e.REPLACE="replace",e}({}),fb=function(e){return e[e.pixel=0]="pixel",e[e.meter=1]="meter",e}({}),R1=function(e){return e.ALWAYS="always",e.DRAGEND="dragend",e}({});function DP(e){var i=kP();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function kP(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var FP=function(e){(0,Me.Z)(r,e);var i=DP(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u0&&(a=1/Math.sqrt(a)),e[0]=i[0]*a,e[1]=i[1]*a,e[2]=i[2]*a,e}function QE(e,i){return e[0]*i[0]+e[1]*i[1]+e[2]*i[2]}function hb(e,i,r){var n=i[0],t=i[1],a=i[2],u=r[0],c=r[1],m=r[2];return e[0]=t*m-a*c,e[1]=a*u-n*m,e[2]=n*c-t*u,e}function JP(e,i,r,n){var t=i[0],a=i[1],u=i[2];return e[0]=t+n*(r[0]-t),e[1]=a+n*(r[1]-a),e[2]=u+n*(r[2]-u),e}function eI(e,i,r,n,t,a){var u=a*a,c=u*(2*a-3)+1,m=u*(a-2)+a,E=u*(a-1),H=u*(3-2*a);return e[0]=i[0]*c+r[0]*m+n[0]*E+t[0]*H,e[1]=i[1]*c+r[1]*m+n[1]*E+t[1]*H,e[2]=i[2]*c+r[2]*m+n[2]*E+t[2]*H,e}function tI(e,i,r,n,t,a){var u=1-a,c=u*u,m=a*a,E=c*u,H=3*a*c,re=3*m*u,xe=m*a;return e[0]=i[0]*E+r[0]*H+n[0]*re+t[0]*xe,e[1]=i[1]*E+r[1]*H+n[1]*re+t[1]*xe,e[2]=i[2]*E+r[2]*H+n[2]*re+t[2]*xe,e}function rI(e,i){i=i||1;var r=qf()*2*Math.PI,n=qf()*2-1,t=Math.sqrt(1-n*n)*i;return e[0]=Math.cos(r)*t,e[1]=Math.sin(r)*t,e[2]=n*i,e}function Ky(e,i,r){var n=i[0],t=i[1],a=i[2],u=r[3]*n+r[7]*t+r[11]*a+r[15];return u=u||1,e[0]=(r[0]*n+r[4]*t+r[8]*a+r[12])/u,e[1]=(r[1]*n+r[5]*t+r[9]*a+r[13])/u,e[2]=(r[2]*n+r[6]*t+r[10]*a+r[14])/u,e}function nI(e,i,r){var n=i[0],t=i[1],a=i[2];return e[0]=n*r[0]+t*r[3]+a*r[6],e[1]=n*r[1]+t*r[4]+a*r[7],e[2]=n*r[2]+t*r[5]+a*r[8],e}function iI(e,i,r){var n=r[0],t=r[1],a=r[2],u=r[3],c=i[0],m=i[1],E=i[2],H=t*E-a*m,re=a*c-n*E,xe=n*m-t*c,ke=t*xe-a*re,rt=a*H-n*xe,vt=n*re-t*H,It=u*2;return H*=It,re*=It,xe*=It,ke*=2,rt*=2,vt*=2,e[0]=c+H+ke,e[1]=m+re+rt,e[2]=E+xe+vt,e}function oI(e,i,r,n){var t=[],a=[];return t[0]=i[0]-r[0],t[1]=i[1]-r[1],t[2]=i[2]-r[2],a[0]=t[0],a[1]=t[1]*Math.cos(n)-t[2]*Math.sin(n),a[2]=t[1]*Math.sin(n)+t[2]*Math.cos(n),e[0]=a[0]+r[0],e[1]=a[1]+r[1],e[2]=a[2]+r[2],e}function aI(e,i,r,n){var t=[],a=[];return t[0]=i[0]-r[0],t[1]=i[1]-r[1],t[2]=i[2]-r[2],a[0]=t[2]*Math.sin(n)+t[0]*Math.cos(n),a[1]=t[1],a[2]=t[2]*Math.cos(n)-t[0]*Math.sin(n),e[0]=a[0]+r[0],e[1]=a[1]+r[1],e[2]=a[2]+r[2],e}function sI(e,i,r,n){var t=[],a=[];return t[0]=i[0]-r[0],t[1]=i[1]-r[1],t[2]=i[2]-r[2],a[0]=t[0]*Math.cos(n)-t[1]*Math.sin(n),a[1]=t[0]*Math.sin(n)+t[1]*Math.cos(n),a[2]=t[2],e[0]=a[0]+r[0],e[1]=a[1]+r[1],e[2]=a[2]+r[2],e}function Zx(e,i){var r=e[0],n=e[1],t=e[2],a=i[0],u=i[1],c=i[2],m=Math.sqrt(r*r+n*n+t*t),E=Math.sqrt(a*a+u*u+c*c),H=m*E,re=H&&QE(e,i)/H;return Math.acos(Math.min(Math.max(re,-1),1))}function uI(e){return e[0]=0,e[1]=0,e[2]=0,e}function lI(e){return"vec3("+e[0]+", "+e[1]+", "+e[2]+")"}function cI(e,i){return e[0]===i[0]&&e[1]===i[1]&&e[2]===i[2]}function fI(e,i){var r=e[0],n=e[1],t=e[2],a=i[0],u=i[1],c=i[2];return Math.abs(r-a)<=jh*Math.max(1,Math.abs(r),Math.abs(a))&&Math.abs(n-u)<=jh*Math.max(1,Math.abs(n),Math.abs(u))&&Math.abs(t-c)<=jh*Math.max(1,Math.abs(t),Math.abs(c))}var Ux=GE,hI=Nx,dI=WE,pI=XE,mI=YE,vI=HE,gI=KE,yI=function(){var e=vy();return function(i,r,n,t,a,u){var c,m;for(r||(r=3),n||(n=0),t?m=Math.min(t*r+n,i.length):m=i.length,c=n;c0)for(var Ln=re.length,wn=Ln-2*(m+1);wn+m+20&&arguments[0]!==void 0?arguments[0]:{};(0,We.Z)(this,e),(0,St.Z)(this,"lastFlip",-1),(0,St.Z)(this,"miter",od(0,0)),(0,St.Z)(this,"started",!1),(0,St.Z)(this,"dash",!1),(0,St.Z)(this,"totalDistance",0),(0,St.Z)(this,"currentIndex",0),this.join=i.join||"miter",this.cap=i.cap||"butt",this.miterLimit=i.miterLimit||10,this.thickness=i.thickness||1,this.dash=i.dash||!1,this.complex={positions:[],indices:[],normals:[],startIndex:0,indexes:[]}}return(0,ot.Z)(e,[{key:"simpleExtrude",value:function(r){var n=this.complex;if(r.length<=1)return n;this.lastFlip=-1,this.started=!1,this.normal=null,this.totalDistance=0;for(var t=r.length,a=n.startIndex,u=1;uthis.miterLimit&&(ma=!0)}ma?(ke.push(this.normal[0],this.normal[1],0),ke.push(po[0],po[1],0),xe.push(a[0],a[1],a[2]|0,this.totalDistance,-this.thickness*Ao,a[2]|0),this.complex.indexes.push(this.currentIndex),xe.push(a[0],a[1],a[2]|0,this.totalDistance,this.thickness*Ao,a[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++,re.push.apply(re,(0,On.Z)(this.lastFlip!==-Ao?[n,n+2,n+3]:[n+2,n+1,n+3])),re.push(n+2,n+3,n+4),_y(pb,yy),lf(this.normal,pb),ke.push(this.normal[0],this.normal[1],0),xe.push(a[0],a[1],a[2]|0,this.totalDistance,-this.thickness*Ao,a[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++,H+=3):(this.extrusions(xe,ke,a,po,Si,this.totalDistance),re.push.apply(re,(0,On.Z)(this.lastFlip===1?[n,n+2,n+3]:[n+2,n+1,n+3])),Ao=-1,lf(this.normal,po),H+=2),this.lastFlip=Ao}else{if(_y(this.normal,Lm),rt){var Ln=mc(),wn=mc();ad(wn,Lm,this.normal),Tc(Ln,Lm,this.normal),ke.push(wn[0],wn[1],0),ke.push(Ln[0],Ln[1],0),xe.push(a[0],a[1],a[2]|0,this.totalDistance,this.thickness,a[2]|0),this.complex.indexes.push(this.currentIndex),xe.push(a[0],a[1],a[2]|0,this.totalDistance,this.thickness,a[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++}else this.extrusions(xe,ke,a,this.normal,this.thickness,this.totalDistance);re.push.apply(re,(0,On.Z)(this.lastFlip===1?[n,n+2,n+3]:[n+2,n+1,n+3])),H+=2}return H}},{key:"segment",value:function(r,n,t,a,u){var c=0,m=r.indices,E=r.positions,H=r.normals,re=this.cap==="square",xe=this.join==="bevel",ke=Ol([a[0],a[1]]),rt=Ol([t[0],t[1]]);L1(Lm,ke,rt);var vt=0;if(this.dash&&(vt=this.lineSegmentDistance(ke,rt),this.totalDistance+=vt),this.normal||(this.normal=mc(),_y(this.normal,Lm)),!this.started)if(this.started=!0,re){var It=mc(),er=mc();Tc(It,this.normal,Lm),Tc(er,this.normal,Lm),H.push(er[0],er[1],0),H.push(It[0],It[1],0),E.push(t[0],t[1],t[2]|0,this.totalDistance-vt,-this.thickness,t[2]|0),this.complex.indexes.push(this.currentIndex),E.push(t[0],t[1],t[2]|0,this.totalDistance-vt,this.thickness,t[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++}else this.extrusions(E,H,t,this.normal,this.thickness,this.totalDistance-vt);if(m.push(n+0,n+1,n+2),u){var rn=Ol([u[0],u[1]]);Vx(ke,rn)&&Tc(rn,ke,hp(rn,Vf(rn,ke,rt))),L1(yy,rn,ke);var Ln=jx(O1,mc(),Lm,yy,this.thickness),wn=(0,gi.Z)(Ln,2),Cn=wn[0],qn=wn[1],Si=Xp(O1,this.normal)<0?-1:1,po=xe;if(!po&&this.join==="miter"){var Ao=Cn;Ao>this.miterLimit&&(po=!0)}po?(H.push(this.normal[0],this.normal[1],0),H.push(qn[0],qn[1],0),E.push(a[0],a[1],a[2]|0,this.totalDistance,-this.thickness*Si,a[2]|0),this.complex.indexes.push(this.currentIndex),E.push(a[0],a[1],a[2]|0,this.totalDistance,this.thickness*Si,a[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++,m.push.apply(m,(0,On.Z)(this.lastFlip!==-Si?[n,n+2,n+3]:[n+2,n+1,n+3])),m.push(n+2,n+3,n+4),_y(pb,yy),lf(this.normal,pb),H.push(this.normal[0],this.normal[1],0),E.push(a[0],a[1],a[2]|0,this.totalDistance,-this.thickness*Si,a[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++,c+=3):(this.extrusions(E,H,a,qn,Cn,this.totalDistance),m.push.apply(m,(0,On.Z)(this.lastFlip===1?[n,n+2,n+3]:[n+2,n+1,n+3])),Si=-1,lf(this.normal,qn),c+=2),this.lastFlip=Si}else{if(_y(this.normal,Lm),re){var Ar=mc(),Or=mc();ad(Or,Lm,this.normal),Tc(Ar,Lm,this.normal),H.push(Or[0],Or[1],0),H.push(Ar[0],Ar[1],0),E.push(a[0],a[1],a[2]|0,this.totalDistance,this.thickness,a[2]|0),this.complex.indexes.push(this.currentIndex),E.push(a[0],a[1],a[2]|0,this.totalDistance,this.thickness,a[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++}else this.extrusions(E,H,a,this.normal,this.thickness,this.totalDistance);m.push.apply(m,(0,On.Z)(this.lastFlip===1?[n,n+2,n+3]:[n+2,n+1,n+3])),c+=2}return c}},{key:"extrusions",value:function(r,n,t,a,u,c){n.push(a[0],a[1],0),n.push(a[0],a[1],0),r.push(t[0],t[1],t[2]|0,c,-u,t[2]|0),this.complex.indexes.push(this.currentIndex),r.push(t[0],t[1],t[2]|0,c,u,t[2]|0),this.complex.indexes.push(this.currentIndex),this.currentIndex++}},{key:"lineSegmentDistance",value:function(r,n){var t=n[0]-r[0],a=n[1]-r[1];return Math.sqrt(t*t+a*a)}}]),e}();function bI(e){var i=e[0][0],r=e[0][e[0].length-1];i[0]===r[0]&&i[1]===r[1]&&(e[0]=e[0].slice(0,e[0].length-1));for(var n=e[0].length,t=Qh().flatten(e),a=t.vertices,u=t.dimensions,c=[],m=[],E=0;E1&&arguments[1]!==void 0?arguments[1]:!1,r=e[0][0],n=e[0][e[0].length-1];r[0]===n[0]&&r[1]===n[1]&&(e[0]=e[0].slice(0,e[0].length-1));for(var t=e[0].length,a=Qh().flatten(e),u=a.vertices,c=a.dimensions,m=[],E=[],H=[],re=0;re3&&arguments[3]!==void 0?arguments[3]:!1,t=vy(),a=vy(),u=vy();n&&(e=sf(e),i=sf(i),r=sf(r));var c=Zd.apply(p,(0,On.Z)(e)),m=Zd.apply(p,(0,On.Z)(i)),E=Zd.apply(p,(0,On.Z)(r));Ux(t,E,m),Ux(a,c,m),hb(u,t,a);var H=vy();return gy(H,u),H}var Ov,L_=function(e){return e.CYLINDER="cylinder",e.SQUARECOLUMN="squareColumn",e.TRIANGLECOLUMN="triangleColumn",e.HEXAGONCOLUMN="hexagonColumn",e.PENTAGONCOLUMN="pentagonColumn",e}({}),D_=function(e){return e.CIRCLE="circle",e.SQUARE="square",e.TRIANGLE="triangle",e.HEXAGON="hexagon",e.PENTAGON="pentagon",e}({});function k_(e){for(var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r=Math.PI*2/e,n=[],t=0;t1&&arguments[1]!==void 0?arguments[1]:!1;if(mb&&mb[e])return mb[e];var r=D1[e]?D1[e]():D1.cylinder(),n=nS([r],i);return mb[e]=n,n}function lV(e,i){for(var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:3,n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1,t=new Float32Array(e.length/r*3),a,u,c,m=vec3.create(),E=vec3.create(),H=vec3.create(),re=0,xe=i.length;re 0.0 && v_worldDis < u_cityMinSize) { + float r = fract(((v_worldDis/u_cityMinSize) - u_time * u_circleSweepSpeed) * 2.0); + outputColor.rgb += r * r * u_circleSweepColor.rgb; + } + + outputColor.a *= u_opacity; + outputColor = filterColor(outputColor); +} +`,NI=`precision highp float; + +#define ambientRatio 0.5 +#define diffuseRatio 0.3 +#define specularRatio 0.2 + +layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in float a_Size; +layout(location = 13) in vec3 a_Normal; +layout(location = 14) in vec2 a_Uv; + +out vec2 v_texCoord; +out vec4 v_Color; +out float v_worldDis; + +layout(std140) uniform commonUniforms { + vec4 u_baseColor : [ 1.0, 0, 0, 1.0 ]; + vec4 u_brightColor : [ 1.0, 0, 0, 1.0 ]; + vec4 u_windowColor : [ 1.0, 0, 0, 1.0 ]; + vec4 u_circleSweepColor; + vec2 u_cityCenter; + float u_circleSweep; + float u_cityMinSize; + float u_circleSweepSpeed; + float u_opacity: 1.0; + float u_near : 0; + float u_far : 1; + float u_time; +}; +#pragma include "projection" +#pragma include "light" +#pragma include "picking" + + +void main() { + vec4 pos = vec4(a_Position.xy, a_Position.z * a_Size, 1.0); + vec4 project_pos = project_position(pos); + + v_texCoord = a_Uv; + + if(u_circleSweep > 0.0) { + vec2 lnglatscale = vec2(0.0); + if(u_CoordinateSystem != COORDINATE_SYSTEM_P20_2) { + lnglatscale = (a_Position.xy - u_cityCenter) * vec2(0.0, 0.135); + } + v_worldDis = length(a_Position.xy + lnglatscale - u_cityCenter); + } + + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { // gaode2.x + gl_Position = u_Mvp * (vec4(project_pos.xyz, 1.0)); + } else { + gl_Position = project_common_position_to_clipspace(vec4(project_pos.xyz, 1.0)); + } + + float lightWeight = calc_lighting(pos); + // v_Color = a_Color; + v_Color = vec4(a_Color.rgb * lightWeight, a_Color.w); + + setPickingColor(a_PickingColor); +} +`,zI=function(e){(0,Me.Z)(r,e);var i=kI(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.opacity,u=a===void 0?1:a,c=t.baseColor,m=c===void 0?"rgb(16,16,16)":c,E=t.brightColor,H=E===void 0?"rgb(255,176,38)":E,re=t.windowColor,xe=re===void 0?"rgb(30,60,89)":re,ke=t.time,rt=ke===void 0?0:ke,vt=t.sweep,It=vt===void 0?{enable:!1,sweepRadius:1,sweepColor:"rgb(255, 255, 255)",sweepSpeed:.4,sweepCenter:this.cityCenter}:vt,er={u_baseColor:Lo(m),u_brightColor:Lo(H),u_windowColor:Lo(xe),u_circleSweepColor:[].concat((0,On.Z)(Lo(It.sweepColor).slice(0,3)),[1]),u_cityCenter:It.sweepCenter||this.cityCenter,u_circleSweep:It.enable?1:0,u_cityMinSize:this.cityMinSize*It.sweepRadius,u_circleSweepSpeed:It.sweepSpeed,u_opacity:u,u_near:0,u_far:1,u_time:this.layer.getLayerAnimateTime()||rt},Ar=this.getUniformsBufferInfo(er);return Ar}},{key:"calCityGeo",value:function(){var t=(0,gi.Z)(this.layer.getSource().extent,4),a=t[0],u=t[1],c=t[2],m=t[3];if(this.mapService.version==="GAODE2.x"){this.cityCenter=this.mapService.lngLatToCoord([(c+a)/2,(m+u)/2]);var E=this.mapService.lngLatToCoord([c,m]),H=this.mapService.lngLatToCoord([a,u]);this.cityMinSize=Math.sqrt(Math.pow(E[0]-H[0],2)+Math.pow(E[1]-H[1],2))/4}else{var re=c-a,xe=m-u;this.cityCenter=[(c+a)/2,(m+u)/2],this.cityMinSize=Math.sqrt(Math.pow(re,2)+Math.pow(xe,2))/4}}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return this.calCityGeo(),this.initUniformsBuffer(),this.startModelAnimate(),c.abrupt("return",this.buildModels());case 4:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u;return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return m.next=2,this.layer.buildLayerModel({moduleName:"cityBuilding",vertexShader:NI,fragmentShader:BI,triangulation:Wx,depth:{enable:!0},inject:this.getInject(),cull:{enable:!0,face:Er.BACK}});case 2:return u=m.sent,m.abrupt("return",[u]);case 4:case"end":return m.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"registerBuiltinAttributes",value:function(){this.styleAttributeService.registerStyleAttribute({name:"normal",type:Vu.Attribute,descriptor:{name:"a_Normal",shaderLocation:Gc.NORMAL,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(a,u,c,m,E){return E}}}),this.styleAttributeService.registerStyleAttribute({name:"size",type:Vu.Attribute,descriptor:{name:"a_Size",shaderLocation:Gc.SIZE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(a){var u=a.size,c=u===void 0?10:u;return Array.isArray(c)?[c[0]]:[c]}}}),this.styleAttributeService.registerStyleAttribute({name:"uv",type:Vu.Attribute,descriptor:{name:"a_Uv",shaderLocation:Gc.UV,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:2,update:function(a,u,c){return[c[3],c[4]]}}})}}]),r}(Kd);function ZI(e){var i=UI();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function UI(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var jI=function(e){(0,Me.Z)(r,e);var i=ZI(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u 0.0) { + outputColor = texture(SAMPLER_2D(u_texture), vec2(v_uv.x, 1.0 - v_uv.y)); + outputColor.a *= u_opacity; + } else { + // gl_FragColor = vec4(v_uv, 0.0, u_opacity); + outputColor = vec4(v_Color, u_opacity); + } + outputColor.a *= v_clip; + outputColor = filterColor(outputColor); +} +`,qI=` +layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec3 a_Color; +layout(location = 14) in vec2 a_Uv; + +layout(std140) uniform commonUniforms { + float u_opacity; + float u_mapFlag; + float u_terrainClipHeight; +}; + +out vec3 v_Color; +out vec2 v_uv; +out float v_clip; + +#pragma include "projection" +#pragma include "picking" +void main() { + v_Color = a_Color; + v_uv = a_Uv; + + vec4 project_pos = project_position(vec4(a_Position, 1.0)); + + v_clip = 1.0; + if(a_Position.z < u_terrainClipHeight) { + v_clip = 0.0; + } + + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xy, a_Position.z, 1.0)); + + setPickingColor(a_PickingColor); +} +`,QI=function(e){(0,Me.Z)(r,e);var i=XI(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u0&&arguments[0]!==void 0?arguments[0]:1,a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1,m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:120,E=arguments.length>5&&arguments[5]!==void 0?arguments[5]:30,H=t/2,re=a/2,xe=Math.floor(u),ke=Math.floor(c),rt=xe+1,vt=ke+1,It=t/xe,er=a/ke,Ar=[],Or=[],rn=0;rn 0.0) { + outputColor = texture(SAMPLER_2D(u_texture), gl_PointCoord); + outputColor.a *= u_opacity; + } else { + outputColor = vec4(v_Color, u_opacity); + } +} +`,rR=`layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec3 a_Color; + +layout(std140) uniform commonUniforms { + float u_opacity; + float u_mapFlag; + float u_Scale; +}; + +out vec3 v_Color; +out float v_d; + +#pragma include "projection" +void main() { + v_Color = a_Color.xyz; + + vec4 project_pos = project_position(vec4(a_Position, 1.0)); + + v_d = a_Position.z; + + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xy, a_Position.z, 1.0)); +gl_PointSize = pow((u_Zoom - 1.0), 2.0) * u_Scale; +} +`,F1=function(e){return e.UP="up",e.DOWN="down",e}(F1||{}),nR=function(e){(0,Me.Z)(r,e);var i=JI(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;uxe&&(n.positions[ke+2]=re)):(n.positions[ke+2]-=H,n.positions[ke+2]0&&arguments[0]!==void 0?arguments[0]:10,a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:100,u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:120,c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:30,m=[],E=[],H=this.mapService,re=this.spriteAnimate===F1.UP?-this.spriteTop:this.spriteTop,xe=0;xe 1 \u7684 uv \u8F6C\u6362\u4E3A -1 -> 1 \u7684\u6807\u51C6\u5750\u6807\u7A7A\u95F4\uFF08NDC\uFF09 + + vec4 p1 = vec4(pos, 0.0, 1.0); // x/y \u5E73\u9762\u4E0A\u7684\u70B9\uFF08z == 0\uFF09\u53EF\u4EE5\u8BA4\u4E3A\u662F\u4E09\u7EF4\u4E0A\u7684\u70B9\u88AB\u6295\u5F71\u5230\u5E73\u9762\u540E\u7684\u70B9 + vec4 p2 = vec4(pos, 1.0, 1.0); // \u5E73\u884C\u4E8Ex/y\u5E73\u9762\u3001z==1 \u7684\u5E73\u9762\u4E0A\u7684\u70B9 + + vec4 inverseP1 = u_InverseViewProjectionMatrix * p1; // \u6839\u636E\u89C6\u56FE\u6295\u5F71\u77E9\u9635\u7684\u9006\u77E9\u9635\u5E73\u9762\u4E0A\u7684\u53CD\u7B97\u51FA\u4E09\u7EF4\u7A7A\u95F4\u4E2D\u7684\u70B9\uFF08p1\u5E73\u9762\u4E0A\u7684\u70B9\uFF09 + vec4 inverseP2 = u_InverseViewProjectionMatrix * p2; + + inverseP1 = inverseP1 / inverseP1.w; // \u5F52\u4E00\u5316\u64CD\u4F5C\uFF08\u5F52\u4E00\u5316\u540E\u4E3A\u4E16\u754C\u5750\u6807\uFF09 + inverseP2 = inverseP2 / inverseP2.w; + + float zPos = (0.0 - inverseP1.z) / (inverseP2.z - inverseP1.z); // ?? + vec4 position = inverseP1 + zPos * (inverseP2 - inverseP1); + + vec4 b= vec4(0.5000, 0.0, 1.0, 0.5000); + float fh; + + v_intensity = texture(SAMPLER_2D(u_texture), v_texCoord).r; + fh = toBezier(v_intensity, b).y; + gl_Position = u_ViewProjectionMatrixUncentered * vec4(position.xy, fh * project_pixel(50.), 1.0); + +} +`,ER=`uniform sampler2D u_texture; // \u70ED\u529B\u5F3A\u5EA6\u56FE +uniform sampler2D u_colorTexture; // \u6839\u636E\u5F3A\u5EA6\u5206\u5E03\u7684\u8272\u5E26 + +layout(std140) uniform commonUniforms { + float u_opacity; + float u_common_uniforms_padding1; + float u_common_uniforms_padding2; + float u_common_uniforms_padding3; +}; +in vec2 v_texCoord; +out vec4 outputColor; + +#pragma include "scene_uniforms" + +float getBlurIndusty() { + float vW = 2.0/ u_ViewportSize.x; + float vH = 2.0/ u_ViewportSize.y; + vec2 vUv = v_texCoord; + float i11 = texture(SAMPLER_2D(u_texture), vec2( vUv.x - 1.0 * vW, vUv.y + 1.0 * vH) ).r; + float i12 = texture(SAMPLER_2D(u_texture), vec2( vUv.x - 0.0 * vW, vUv.y + 1.0 * vH) ).r; + float i13 = texture(SAMPLER_2D(u_texture), vec2( vUv.x + 1.0 * vW, vUv.y + 1.0 * vH) ).r; + + float i21 = texture(SAMPLER_2D(u_texture), vec2( vUv.x - 1.0 * vW, vUv.y) ).r; + float i22 = texture(SAMPLER_2D(u_texture), vec2( vUv.x , vUv.y) ).r; + float i23 = texture(SAMPLER_2D(u_texture), vec2( vUv.x + 1.0 * vW, vUv.y) ).r; + + float i31 = texture(SAMPLER_2D(u_texture), vec2( vUv.x - 1.0 * vW, vUv.y-1.0*vH) ).r; + float i32 = texture(SAMPLER_2D(u_texture), vec2( vUv.x - 0.0 * vW, vUv.y-1.0*vH) ).r; + float i33 = texture(SAMPLER_2D(u_texture), vec2( vUv.x + 1.0 * vW, vUv.y-1.0*vH) ).r; + + return( + i11 + + i12 + + i13 + + i21 + + i21 + + i22 + + i23 + + i31 + + i32 + + i33 + )/9.0; +} + + +void main(){ + // float intensity = texture(u_texture, v_texCoord).r; + float intensity = getBlurIndusty(); + vec4 color = texture(SAMPLER_2D(u_colorTexture), vec2(intensity, 0.0)); + outputColor = color; + outputColor.a = color.a * smoothstep(0.,0.1,intensity) * u_opacity; +} +`,SR=` +layout(location = 0) in vec3 a_Position; +layout(location = 14) in vec2 a_Uv; + +layout(std140) uniform commonUniforms { + float u_opacity; + float u_common_uniforms_padding1; + float u_common_uniforms_padding2; + float u_common_uniforms_padding3; +}; + +#pragma include "scene_uniforms" + +out vec2 v_texCoord; +void main() { + v_texCoord = a_Uv; + #ifdef VIEWPORT_ORIGIN_TL + v_texCoord.y = 1.0 - v_texCoord.y; + #endif + + gl_Position = vec4(a_Position.xy, 0, 1.); +} +`,CR=`layout(std140) uniform commonUniforms { + float u_radius; + float u_intensity; + float u_common_uniforms_padding1; + float u_common_uniforms_padding2; +}; + +in vec2 v_extrude; +in float v_weight; +out vec4 outputColor; +#define GAUSS_COEF 0.3989422804014327 + +void main(){ + float d = -0.5 * 3.0 * 3.0 * dot(v_extrude, v_extrude); + float val = v_weight * u_intensity * GAUSS_COEF * exp(d); + outputColor = vec4(val, 1., 1., 1.); +} +`,TR=`layout(location = 0) in vec3 a_Position; +layout(location = 9) in float a_Size; +layout(location = 10) in vec2 a_Dir; + + +layout(std140) uniform commonUniforms { + float u_radius; + float u_intensity; + float u_common_uniforms_padding1; + float u_common_uniforms_padding2; +}; + +out vec2 v_extrude; +out float v_weight; + +#define GAUSS_COEF 0.3989422804014327 + +#pragma include "projection" +#pragma include "picking" + +void main(){ + vec3 picking_color_placeholder = u_PickingColor; + + v_weight = a_Size; + float ZERO = 1.0 / 255.0 / 16.0; + float extrude_x = a_Dir.x * 2.0 -1.0; + float extrude_y = a_Dir.y * 2.0 -1.0; + vec2 extrude_dir = normalize(vec2(extrude_x,extrude_y)); + float S = sqrt(-2.0 * log(ZERO / a_Size / u_intensity / GAUSS_COEF)) / 2.5; + v_extrude = extrude_dir * S; + + vec2 offset = project_pixel(v_extrude * u_radius); + vec4 project_pos = project_position(vec4(a_Position.xy, 0.0, 1.0)); + + // gl_Position = project_common_position_to_clipspace(vec4(project_pos.xy + offset, 0.0, 1.0)); + + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { // gaode2.x + gl_Position = u_Mvp * (vec4(project_pos.xy + offset, 0.0, 1.0)); + } else { + gl_Position = project_common_position_to_clipspace(vec4(project_pos.xy + offset, 0.0, 1.0)); + } +} +`,MR=lo.isEqual,mS=(dS=(0,sa.b2)(),dS(pS=function(e){(0,Me.Z)(r,e);var i=AR(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u0&&arguments[0]!==void 0?arguments[0]:{},u=this.getModelType();return u==="heatmap"?(this.layerModel&&this.layerModel.render(a),this):this.encodeDataLength<=0&&!this.forceRender?this:(this.hooks.beforeRender.call(),this.models.forEach(function(c){return c.draw({uniforms:t.layerModel.getUninforms(),blend:t.layerModel.getBlend(),stencil:t.layerModel.getStencil(a)})}),this.hooks.afterRender.call(),this)}},{key:"updateModelData",value:function(t){t.attributes&&t.elements?this.models[0].updateAttributesAndElements(t.attributes,t.elements):console.warn("data error")}},{key:"getModelType",value:function(){var t,a=this.styleAttributeService.getLayerStyleAttribute("shape"),u=this.getLayerConfig(),c=u.shape3d,m=this.getSource(),E=m.data.type,H=(a==null||(t=a.scale)===null||t===void 0?void 0:t.field)||"heatmap";return H==="heatmap"||H==="heatmap3d"?"heatmap":E==="hexagon"?(c==null?void 0:c.indexOf(H))===-1?"hexagon":"grid3d":E==="grid"?(c==null?void 0:c.indexOf(H))===-1?"grid":"grid3d":"heatmap"}}]),r}(hv);function zR(e){var i=ZR();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function ZR(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var UR=`uniform sampler2D u_texture; +layout(std140) uniform commonUniforms { + float u_opacity:1.0; + float u_brightness:1.0; + float u_contrast:1.0; + float u_saturation:1.0; + float u_gamma:1.0; +}; + +in vec2 v_texCoord; +out vec4 outputColor; +vec3 setContrast(vec3 rgb, float contrast) { + vec3 color = mix(vec3(0.5), rgb, contrast); + color = clamp(color, 0.0, 1.0); + return color; +} +vec3 setSaturation(vec3 rgb, float adjustment) { + const vec3 grayVector = vec3(0.2125, 0.7154, 0.0721); + vec3 intensity = vec3(dot(rgb, grayVector)); + vec3 color = mix(intensity, rgb, adjustment); + color = clamp(color, 0.0, 1.0); + return color; +} +void main() { + vec4 color = texture(SAMPLER_2D(u_texture),vec2(v_texCoord.x,v_texCoord.y)); + //brightness + color.rgb = mix(vec3(0.0, 0.0, 0.0), color.rgb, u_brightness); + //contrast + color.rgb = setContrast(color.rgb, u_contrast); + // saturation + color.rgb = setSaturation(color.rgb, u_saturation); + // gamma + color.rgb = pow(color.rgb, vec3(u_gamma)); + outputColor = color; + outputColor.a *= u_opacity; + if(outputColor.a < 0.01) + discard; +} +`,jR=`layout(location = 0) in vec3 a_Position; +layout(location = 14) in vec2 a_Uv; + +layout(std140) uniform commonUniforms { + float u_opacity:1.0; + float u_brightness:1.0; + float u_contrast:1.0; + float u_saturation:1.0; + float u_gamma:1.0; +}; + +out vec2 v_texCoord; +#pragma include "projection" +void main() { + v_texCoord = a_Uv; + vec4 project_pos = project_position(vec4(a_Position, 1.0)); + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xy,0., 1.0)); + +} +`,VR=function(e){(0,Me.Z)(r,e);var i=zR(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.opacity,u=t.brightness,c=t.contrast,m=t.saturation,E=t.gamma,H={u_opacity:Id(a,1),u_brightness:Id(u,1),u_contrast:Id(c,1),u_saturation:Id(m,1),u_gamma:Id(E,1)};this.textures=[this.texture];var re=this.getUniformsBufferInfo(H);return re}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.next=2,this.loadTexture();case 2:return c.abrupt("return",this.buildModels());case 3:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"clearModels",value:function(){var t;(t=this.texture)===null||t===void 0||t.destroy()}},{key:"loadTexture",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m;return Ur().wrap(function(H){for(;;)switch(H.prev=H.next){case 0:return u=this.rendererService.createTexture2D,this.texture=u({height:1,width:1}),c=this.layer.getSource(),H.next=5,c.data.images;case 5:m=H.sent,this.texture=u({data:m[0],width:m[0].width,height:m[0].height,mag:Er.LINEAR,min:Er.LINEAR});case 7:case"end":return H.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u;return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return this.initUniformsBuffer(),m.next=3,this.layer.buildLayerModel({moduleName:"rasterImage",vertexShader:jR,fragmentShader:UR,triangulation:F_,primitive:Er.TRIANGLES,blend:{enable:!0},depth:{enable:!1},pickingEnabled:!1});case 3:return u=m.sent,m.abrupt("return",[u]);case 5:case"end":return m.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"registerBuiltinAttributes",value:function(){this.styleAttributeService.registerStyleAttribute({name:"uv",type:Vu.Attribute,descriptor:{name:"a_Uv",shaderLocation:Gc.UV,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:2,update:function(a,u,c){return[c[3],c[4]]}}})}}]),r}(Kd),$R={image:VR},HR=$R;function GR(e){var i=WR();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function WR(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var vS=function(e){(0,Me.Z)(r,e);var i=GR(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u (v_dash_array.x + v_dash_array.y) && dashLength < v_dash_array.x + v_dash_array.y + v_dash_array.z))) { + discard; + }; + } + float animateSpeed = 0.0; // \u8FD0\u52A8\u901F\u5EA6 + outputColor = v_color; + if(u_animate.x == Animate && u_line_texture != LineTexture) { + animateSpeed = u_time / u_animate.y; + float alpha =1.0 - fract( mod(1.0- v_lineData.b, u_animate.z)* (1.0/ u_animate.z) + u_time / u_animate.y); + alpha = (alpha + u_animate.w -1.0) / u_animate.w; + // alpha = smoothstep(0., 1., alpha); + alpha = clamp(alpha, 0.0, 1.0); + outputColor.a *= alpha; + } + + // \u5F53\u5B58\u5728\u8D34\u56FE\u65F6\u5728\u5E95\u8272\u4E0A\u8D34\u4E0A\u8D34\u56FE + if(u_line_texture == LineTexture) { // while load texture + float arcRadio = smoothstep( 0.0, 1.0, (v_lineData.r / segmentNumber)); + // float arcRadio = smoothstep( 0.0, 1.0, d_distance_ratio); + + float count = v_lineData.g; // \u8D34\u56FE\u5728\u5F27\u7EBF\u4E0A\u91CD\u590D\u7684\u6570\u91CF + + float time = 0.0; + if(u_animate.x == Animate) { + time = u_time / u_animate.y; + } + float redioCount = arcRadio * count; + + float u = fract(redioCount - time); + float v = v_lineData.a; // \u6A2A\u5411 v + vec2 uv= v_iconMapUV / u_textSize + vec2(u, v) / u_textSize * 64.; + + vec4 pattern = texture(SAMPLER_2D(u_texture), uv); + + if(u_animate.x == Animate) { + float currentPlane = floor(redioCount - time); + float textureStep = floor(count * u_animate.z); + float a = mod(currentPlane, textureStep); + if(a < textureStep - 1.0) { + pattern = vec4(0.0); + } + } + + if(u_textureBlend == 0.0) { // normal + pattern.a = 0.0; + outputColor = filterColor(outputColor + pattern); + } else { // replace + pattern.a *= v_color.a; + if(outputColor.a <= 0.0) { + pattern.a = 0.0; + } + outputColor = filterColor(pattern); + } + + } else { + outputColor = filterColor(outputColor); + } +}`,qR=`#define Animate 0.0 +#define LineTexture 1.0 +layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in float a_Size; +layout(location = 12) in vec4 a_Instance; +layout(location = 14) in vec2 a_iconMapUV; + +layout(std140) uniform commonUniorm { + vec4 u_animate: [ 1., 2., 1.0, 0.2 ]; + vec4 u_dash_array; + vec4 u_sourceColor; + vec4 u_targetColor; + vec2 u_textSize; + float segmentNumber; + float u_lineDir: 1.0; + float u_icon_step: 100; + float u_line_texture: 0.0; + float u_textureBlend; + float u_blur : 0.9; + float u_line_type: 0.0; + float u_time; + float u_linearColor: 0.0; +}; +out vec4 v_color; +out vec2 v_iconMapUV; +out vec4 v_lineData; +//dash +out vec4 v_dash_array; +out float v_distance_ratio; + + +#pragma include "projection" +#pragma include "project" +#pragma include "picking" + +float bezier3(vec3 arr, float t) { + float ut = 1. - t; + return (arr.x * ut + arr.y * t) * ut + (arr.y * ut + arr.z * t) * t; +} +vec2 midPoint(vec2 source, vec2 target, float arcThetaOffset) { + vec2 center = target - source; + float r = length(center); + float theta = atan(center.y, center.x); + float thetaOffset = arcThetaOffset; + float r2 = r / 2.0 / cos(thetaOffset); + float theta2 = theta + thetaOffset; + vec2 mid = vec2(r2*cos(theta2) + source.x, r2*sin(theta2) + source.y); + if(u_lineDir == 1.0) { // \u6B63\u5411 + return mid; + } else { // \u9006\u5411 + // (mid + vmin)/2 = (s + t)/2 + vec2 vmid = source + target - mid; + return vmid; + } + // return mid; +} +float getSegmentRatio(float index) { + // dash: index / (segmentNumber - 1.); + // normal: smoothstep(0.0, 1.0, index / (segmentNumber - 1.)); + return smoothstep(0.0, 1.0, index / (segmentNumber - 1.)); + // return index / (segmentNumber - 1.); +} +vec2 interpolate (vec2 source, vec2 target, float t, float arcThetaOffset) { + // if the angularDist is PI, linear interpolation is applied. otherwise, use spherical interpolation + vec2 mid = midPoint(source, target, arcThetaOffset); + vec3 x = vec3(source.x, mid.x, target.x); + vec3 y = vec3(source.y, mid.y, target.y); + return vec2(bezier3(x ,t), bezier3(y,t)); +} +vec2 getExtrusionOffset(vec2 line_clipspace, float offset_direction) { + // normalized direction of the line + vec2 dir_screenspace = normalize(line_clipspace); + // rotate by 90 degrees + dir_screenspace = vec2(-dir_screenspace.y, dir_screenspace.x); + vec2 offset = dir_screenspace * offset_direction * setPickingSize(a_Size) / 2.0; + return offset; +} +vec2 getNormal(vec2 line_clipspace, float offset_direction) { + // normalized direction of the line + vec2 dir_screenspace = normalize(line_clipspace); + // rotate by 90 degrees + dir_screenspace = vec2(-dir_screenspace.y, dir_screenspace.x); + return reverse_offset_normal(vec3(dir_screenspace,1.0)).xy * sign(offset_direction); +} + +void main() { + //vs\u4E2D\u8BA1\u7B97\u6E10\u53D8\u8272 + if(u_linearColor==1.0){ + float d_segmentIndex = a_Position.x + 1.0; // \u5F53\u524D\u9876\u70B9\u5728\u5F27\u7EBF\u4E2D\u6240\u5904\u7684\u5206\u6BB5\u4F4D\u7F6E + v_color = mix(u_sourceColor, u_targetColor, d_segmentIndex/segmentNumber); + } + else{ + v_color = a_Color; + } + v_color.a = v_color.a * opacity; + + vec2 source = a_Instance.rg; // \u8D77\u59CB\u70B9 + vec2 target = a_Instance.ba; // \u7EC8\u70B9 + + + + float segmentIndex = a_Position.x; + float segmentRatio = getSegmentRatio(segmentIndex); + + //\u8BA1\u7B97dashArray\u548CdistanceRatio \u8F93\u51FA\u5230\u7247\u5143 + vec2 s = source; + vec2 t = target; + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { // gaode2.x + s = unProjCustomCoord(source); + t = unProjCustomCoord(target); + } + float total_Distance = pixelDistance(s, t) / 2.0 * PI; + v_dash_array = pow(2.0, 20.0 - u_Zoom) * u_dash_array / total_Distance; + v_distance_ratio = segmentIndex / segmentNumber; + + float indexDir = mix(-1.0, 1.0, step(segmentIndex, 0.0)); + float nextSegmentRatio = getSegmentRatio(segmentIndex + indexDir); + float d_distance_ratio; + + if(u_animate.x == Animate) { + d_distance_ratio = segmentIndex / segmentNumber; + if(u_lineDir != 1.0) { + d_distance_ratio = 1.0 - d_distance_ratio; + } + } + + v_lineData.b = d_distance_ratio; + + vec4 curr = project_position(vec4(interpolate(source, target, segmentRatio, thetaOffset), 0.0, 1.0)); + vec4 next = project_position(vec4(interpolate(source, target, nextSegmentRatio, thetaOffset), 0.0, 1.0)); + + + vec2 offset = project_pixel(getExtrusionOffset((next.xy - curr.xy) * indexDir, a_Position.y)); + + + float d_segmentIndex = a_Position.x + 1.0; // \u5F53\u524D\u9876\u70B9\u5728\u5F27\u7EBF\u4E2D\u6240\u5904\u7684\u5206\u6BB5\u4F4D\u7F6E + v_lineData.r = d_segmentIndex; + + if(LineTexture == u_line_texture) { // \u5F00\u542F\u8D34\u56FE\u6A21\u5F0F + + float arcDistrance = length(source - target); // \u8D77\u59CB\u70B9\u548C\u7EC8\u70B9\u7684\u8DDD\u79BB + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20) { // amap + arcDistrance *= 1000000.0; + } + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { // mapbox + // arcDistrance *= 8.0; + arcDistrance = project_pixel_allmap(arcDistrance); + } + v_iconMapUV = a_iconMapUV; + + float pixelLen = project_pixel_texture(u_icon_step); // \u8D34\u56FE\u6CBF\u5F27\u7EBF\u65B9\u5411\u7684\u957F\u5EA6 - \u968F\u5730\u56FE\u7F29\u653E\u6539\u53D8 + float texCount = floor(arcDistrance/pixelLen); // \u8D34\u56FE\u5728\u5F27\u7EBF\u4E0A\u91CD\u590D\u7684\u6570\u91CF + v_lineData.g = texCount; + + float lineOffsetWidth = length(offset + offset * sign(a_Position.y)); // \u7EBF\u6A2A\u5411\u504F\u79FB\u7684\u8DDD\u79BB + float linePixelSize = project_pixel(a_Size); // \u5B9A\u70B9\u4F4D\u7F6E\u504F\u79FB + v_lineData.a = lineOffsetWidth/linePixelSize; // \u7EBF\u56FE\u5C42\u8D34\u56FE\u90E8\u5206\u7684 v \u5750\u6807\u503C + } + + gl_Position = project_common_position_to_clipspace_v2(vec4(curr.xy + offset, 0, 1.0)); + + setPickingColor(a_PickingColor); +} +`,QR={solid:0,dash:1},hV=lo.isNumber,JR=function(e){(0,Me.Z)(r,e);var i=XR(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u (v_dash_array.x + v_dash_array.y) && dashLength < v_dash_array.x + v_dash_array.y + v_dash_array.z)) { + flag = 1.; + } + outputColor.a *=flag; + } + + if(u_animate.x == Animate && u_line_texture != LineTexture) { + animateSpeed = u_time / u_animate.y; + float alpha =1.0 - fract( mod(1.0- d_distance_ratio, u_animate.z)* (1.0/ u_animate.z) + u_time / u_animate.y); + + alpha = (alpha + u_animate.w -1.0) / u_animate.w; + // alpha = smoothstep(0., 1., alpha); + alpha = clamp(alpha, 0.0, 1.0); + outputColor.a *= alpha; + + // u_animate + // x enable + // y duration + // z interval + // w trailLength + } + + if(u_line_texture == LineTexture && u_line_type != LineTypeDash) { // while load texture + // float arcRadio = smoothstep( 0.0, 1.0, (v_segmentIndex / segmentNumber)); + float arcRadio = v_segmentIndex / (segmentNumber - 1.0); + float count = v_line_data.b; // // \u8D34\u56FE\u5728\u5F27\u7EBF\u4E0A\u91CD\u590D\u7684\u6570\u91CF + + float time = 0.0; + if(u_animate.x == Animate) { + time = u_time / u_animate.y; + } + float redioCount = arcRadio * count; + + float u = fract(redioCount - time); + + float v = v_line_data.a; // \u7EBF\u56FE\u5C42\u8D34\u56FE\u90E8\u5206\u7684 v \u5750\u6807\u503C + vec2 uv= v_iconMapUV / u_textSize + vec2(u, v) / u_textSize * 64.; + vec4 pattern = texture(SAMPLER_2D(u_texture), uv); + + if(u_animate.x == Animate) { + float currentPlane = floor(redioCount - time); + float textureStep = floor(count * u_animate.z); + float a = mod(currentPlane, textureStep); + if(a < textureStep - 1.0) { + pattern = vec4(0.0); + } + } + + if(u_textureBlend == 0.0) { // normal + pattern.a = 0.0; + outputColor = filterColor(outputColor + pattern); + } else { // replace + pattern.a *= v_color.a; + if(outputColor.a <= 0.0) { + pattern.a = 0.0; + discard; + } else { + outputColor = filterColor(pattern); + } + } + + } else { + outputColor = filterColor(outputColor); + } +} +`,n6=`#define LineTypeSolid 0.0 +#define LineTypeDash 1.0 +#define Animate 0.0 +#define LineTexture 1.0 +layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in float a_Size; +layout(location = 12) in vec4 a_Instance; +layout(location = 14) in vec2 a_iconMapUV; + + +layout(std140) uniform commonUniorm { + vec4 u_animate: [ 1., 2., 1.0, 0.2 ]; + vec4 u_dash_array: [10.0, 5., 0, 0]; + vec4 u_sourceColor; + vec4 u_targetColor; + vec2 u_textSize; + float u_globel; + float u_globel_radius; + float u_global_height: 10; + float segmentNumber; + float u_line_type: 0.0; + float u_icon_step: 100; + float u_line_texture: 0.0; + float u_textureBlend; + float u_time; + float u_linearColor: 0.0; +}; +out vec4 v_color; +out vec4 v_dash_array; +out float v_segmentIndex; +out vec2 v_iconMapUV; +out vec4 v_line_data; + +#pragma include "projection" +#pragma include "project" +#pragma include "picking" + +float maps (float value, float start1, float stop1, float start2, float stop2) { + return start2 + (stop2 - start2) * ((value - start1) / (stop1 - start1)); +} + +float getSegmentRatio(float index) { + return smoothstep(0.0, 1.0, index / (segmentNumber - 1.0)); +} + +float paraboloid(vec2 source, vec2 target, float ratio) { + vec2 x = mix(source, target, ratio); + vec2 center = mix(source, target, 0.5); + float dSourceCenter = distance(source, center); + float dXCenter = distance(x, center); + return (dSourceCenter + dXCenter) * (dSourceCenter - dXCenter); +} + +vec3 getPos(vec2 source, vec2 target, float segmentRatio) { + float vertex_height = paraboloid(source, target, segmentRatio); + + return vec3( + mix(source, target, segmentRatio), + sqrt(max(0.0, vertex_height)) + ); +} +vec2 getExtrusionOffset(vec2 line_clipspace, float offset_direction) { + // normalized direction of the line + vec2 dir_screenspace = normalize(line_clipspace); + // rotate by 90 degrees + dir_screenspace = vec2(-dir_screenspace.y, dir_screenspace.x); + + vec2 offset = dir_screenspace * offset_direction * setPickingSize(a_Size) / 2.0; + + return offset; +} +vec2 getNormal(vec2 line_clipspace, float offset_direction) { + // normalized direction of the line + vec2 dir_screenspace = normalize(line_clipspace); + // rotate by 90 degrees + dir_screenspace = vec2(-dir_screenspace.y, dir_screenspace.x); + return reverse_offset_normal(vec3(dir_screenspace,1.0)).xy * sign(offset_direction); +} + +float torad(float deg) { + return (deg / 180.0) * acos(-1.0); +} + +vec3 lglt2xyz(vec2 lnglat) { + float pi = 3.1415926; + // + Math.PI/2 \u662F\u4E3A\u4E86\u5BF9\u9F50\u5750\u6807 + float lng = torad(lnglat.x) + pi / 2.0; + float lat = torad(lnglat.y); + + // \u624B\u52A8\u589E\u52A0\u4E00\u4E9B\u504F\u79FB\uFF0C\u51CF\u8F7B\u9762\u7684\u51B2\u7A81 + float radius = u_globel_radius; + + float z = radius * cos(lat) * cos(lng); + float x = radius * cos(lat) * sin(lng); + float y = radius * sin(lat); + return vec3(x, y, z); +} + +void main() { + //vs\u4E2D\u8BA1\u7B97\u6E10\u53D8\u8272 + if(u_linearColor==1.0){ + float d_segmentIndex = a_Position.x + 1.0; // \u5F53\u524D\u9876\u70B9\u5728\u5F27\u7EBF\u4E2D\u6240\u5904\u7684\u5206\u6BB5\u4F4D\u7F6E + v_color = mix(u_sourceColor, u_targetColor, d_segmentIndex/segmentNumber); + } + else{ + v_color = a_Color; + } + v_color.a = v_color.a * opacity; + vec2 source = project_position(vec4(a_Instance.rg, 0, 0)).xy; + vec2 target = project_position(vec4(a_Instance.ba, 0, 0)).xy; + float segmentIndex = a_Position.x; + float segmentRatio = getSegmentRatio(segmentIndex); + float indexDir = mix(-1.0, 1.0, step(segmentIndex, 0.0)); + + float d_distance_ratio; + if(u_line_type == LineTypeDash) { + d_distance_ratio = segmentIndex / segmentNumber; + vec2 s = source; + vec2 t = target; + + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { // gaode2.x + s = unProjCustomCoord(source); + t = unProjCustomCoord(target); + } + float total_Distance = pixelDistance(s, t) / 2.0 * PI; + v_dash_array = pow(2.0, 20.0 - u_Zoom) * u_dash_array / (total_Distance / segmentNumber * segmentIndex); + } + if(u_animate.x == Animate) { + d_distance_ratio = segmentIndex / segmentNumber; + } + v_line_data.g = d_distance_ratio; // \u5F53\u524D\u70B9\u4F4D\u8DDD\u79BB\u5360\u7EBF\u603B\u957F\u7684\u6BD4\u4F8B + + float nextSegmentRatio = getSegmentRatio(segmentIndex + indexDir); + vec3 curr = getPos(source, target, segmentRatio); + vec3 next = getPos(source, target, nextSegmentRatio); + vec2 offset = getExtrusionOffset((next.xy - curr.xy) * indexDir, a_Position.y); + // v_normal = getNormal((next.xy - curr.xy) * indexDir, a_Position.y); + + + v_segmentIndex = a_Position.x; + if(LineTexture == u_line_texture && u_line_type != LineTypeDash) { // \u5F00\u542F\u8D34\u56FE\u6A21\u5F0F + + float arcDistrance = length(source - target); + float pixelLen = project_pixel_texture(u_icon_step); + v_line_data.b = floor(arcDistrance/pixelLen); // \u8D34\u56FE\u5728\u5F27\u7EBF\u4E0A\u91CD\u590D\u7684\u6570\u91CF + + vec2 projectOffset = project_pixel(offset); + float lineOffsetWidth = length(projectOffset + projectOffset * sign(a_Position.y)); // \u7EBF\u6A2A\u5411\u504F\u79FB\u7684\u8DDD\u79BB + float linePixelSize = project_pixel(a_Size); // \u5B9A\u70B9\u4F4D\u7F6E\u504F\u79FB\uFF0C\u6309\u5730\u56FE\u7B49\u7EA7\u7F29\u653E\u540E\u7684\u8DDD\u79BB + v_line_data.a = lineOffsetWidth/linePixelSize; // \u7EBF\u56FE\u5C42\u8D34\u56FE\u90E8\u5206\u7684 v \u5750\u6807\u503C + + v_iconMapUV = a_iconMapUV; + } + + + gl_Position = project_common_position_to_clipspace_v2(vec4(curr.xy + project_pixel(offset), curr.z * thetaOffset, 1.0)); + + // \u5730\u7403\u6A21\u5F0F + if(u_globel > 0.0) { + vec3 startLngLat = lglt2xyz(a_Instance.rg); + vec3 endLngLat = lglt2xyz(a_Instance.ba); + float globalRadius = length(startLngLat); + + vec3 lineDir = normalize(endLngLat - startLngLat); + vec3 midPointDir = normalize((startLngLat + endLngLat)/2.0); + + // \u7EBF\u7684\u504F\u79FB + vec3 lnglatOffset = cross(lineDir, midPointDir) * a_Position.y; + // \u8BA1\u7B97\u8D77\u59CB\u70B9\u548C\u7EC8\u6B62\u70B9\u7684\u8DDD\u79BB + float lnglatLength = length(a_Instance.rg - a_Instance.ba)/50.0; + // \u8BA1\u7B97\u98DE\u7EBF\u5404\u4E2A\u8282\u70B9\u76F8\u5E94\u7684\u9AD8\u5EA6 + float lineHeight = u_global_height * (-4.0*segmentRatio*segmentRatio + 4.0 * segmentRatio) * lnglatLength; + // \u5730\u7403\u70B9\u4F4D + vec3 globalPoint = normalize(mix(startLngLat, endLngLat, segmentRatio)) * (globalRadius + lineHeight) + lnglatOffset * a_Size; + + gl_Position = u_ViewProjectionMatrix * vec4(globalPoint, 1.0); + } + + + setPickingColor(a_PickingColor); +} +`,i6={solid:0,dash:1},gS=function(e){(0,Me.Z)(r,e);var i=e6(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u1&&arguments[1]!==void 0?arguments[1]:0,r=arguments.length>2?arguments[2]:void 0,n=(0,df.Z)(r.source)==="object"?r.source.type:r.source,t=(0,df.Z)(r.target)==="object"?r.target.type:r.target,a=(0,df.Z)(r.source)==="object"?r.source:{},u=a.width,c=u===void 0?n?yS[n]:0:u,m=a.height,E=m===void 0?2:m,H=(0,df.Z)(r.target)==="object"?r.target:{},re=H.width,xe=re===void 0?t?yS[t]:0:re,ke=H.height,rt=ke===void 0?2:ke;return{vertices:[0,dv,1*c].concat((0,On.Z)(e),[1,dv,-1*xe],(0,On.Z)(e),[1,-dv,-1*xe],(0,On.Z)(e),[0,-dv,1*c],(0,On.Z)(e),[0,dv,1*c],(0,On.Z)(e),[1,dv,-1*xe],(0,On.Z)(e),[1,-dv,-1*xe],(0,On.Z)(e),[0,-dv,1*c],(0,On.Z)(e)),outLineIndices:[0,1,2,0,2,3].map(function(vt){return vt+i}),indices:[4,5,6,4,6,7].map(function(vt){return vt+i}),normals:[1,-1,1,1,1,1,-1,0,1,-1,0,1,0,0,0,0,0,0,0,0,0,0,0,0],dimensions:2}}function _S(e,i){var r=(0,df.Z)(e)==="object"?e.type:e,n=i==="source"?1:-1,t=(0,df.Z)(e)==="object"?e:{};switch(r){case"circle":return c6(n,t);case"triangle":return a6(n,t);case"diamond":return u6(n,t);case"rect":return s6(n,t);case"classic":return l6(n,t);case"halfTriangle":return o6(n,t);default:return{vertices:[],indices:[],normals:[],dimensions:2,outLineIndices:[],outLineNormals:[]}}}function h6(e){var i=e.coordinates.flat(),r=1,n=1;return{vertices:[1,0,0].concat((0,On.Z)(i),[1,2,-3],(0,On.Z)(i),[1,1,-3],(0,On.Z)(i),[0,1,0],(0,On.Z)(i),[0,0,0],(0,On.Z)(i),[1,0,0],(0,On.Z)(i),[1,2,-3],(0,On.Z)(i),[1,1,-3],(0,On.Z)(i),[0,1,0],(0,On.Z)(i),[0,0,0],(0,On.Z)(i)),normals:[-r,2*n,1,2*n,-n,1,n,-n,1,n,-n,1,-r,-n,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],indices:[0,1,2,0,2,3,0,3,4,5,6,7,5,7,8,5,8,9],size:7}}function d6(e,i){return i?p6(e,i):h6(e)}function p6(e,i){var r=e.coordinates.flat(),n=i,t=n.target,a=t===void 0?"classic":t,u=n.source,c=u===void 0?"circle":u,m=AS(_S(c,"source"),r,0,0),E=f6(r,m.vertices.length/7,i),H=AS(_S(a,"target"),r,1,m.vertices.length/7+E.vertices.length/7),re={vertices:[].concat((0,On.Z)(m.vertices),(0,On.Z)(E.vertices),(0,On.Z)(H.vertices)),indices:[].concat((0,On.Z)(m.outLineIndices),(0,On.Z)(E.outLineIndices),(0,On.Z)(H.outLineIndices),(0,On.Z)(m.indices),(0,On.Z)(E.indices),(0,On.Z)(H.indices)),normals:[].concat((0,On.Z)(m.normals),(0,On.Z)(E.normals),(0,On.Z)(H.normals)),size:7};return re}function AS(e,i){for(var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,t=[],a=e.vertices,u=e.indices,c=e.dimensions,m=e.outLineIndices,E=0;E (v_dash_array.x + v_dash_array.y) && dashLength < v_dash_array.x + v_dash_array.y + v_dash_array.z)) { + // \u5B9E\u7EBF\u90E8\u5206 + } else { + // \u865A\u7EBF\u90E8\u5206 + discard; + }; + } + + // \u8BBE\u7F6E\u5F27\u7EBF\u7684\u52A8\u753B\u6A21\u5F0F + if(u_animate.x == Animate) { + animateSpeed = u_time / u_animate.y; + float alpha =1.0 - fract( mod(1.0- v_distance_ratio, u_animate.z)* (1.0/ u_animate.z) + u_time / u_animate.y); + alpha = (alpha + u_animate.w -1.0) / u_animate.w; + alpha = smoothstep(0., 1., alpha); + outputColor.a *= alpha; + } + + // \u8BBE\u7F6E\u5F27\u7EBF\u7684\u8D34\u56FE + if(LineTexture == u_line_texture && u_line_type != LineTypeDash) { + float arcRadio = smoothstep( 0.0, 1.0, (d_segmentIndex / (segmentNumber - 1.0))); + // float arcRadio = d_segmentIndex / (segmentNumber - 1.0); + float count = v_line_data.b; // \u8D34\u56FE\u5728\u5F27\u7EBF\u4E0A\u91CD\u590D\u7684\u6570\u91CF + float u = fract(arcRadio * count - animateSpeed * count); + // float u = fract(arcRadio * count - animateSpeed); + if(u_animate.x == Animate) { + u = outputColor.a/v_color.a; + } + + float v = v_line_data.a; // \u7EBF\u56FE\u5C42\u8D34\u56FE\u90E8\u5206\u7684 v \u5750\u6807\u503C + + vec2 uv= v_iconMapUV / u_textSize + vec2(u, v) / u_textSize * 64.; + vec4 pattern = texture(SAMPLER_2D(u_texture), uv); + + // \u8BBE\u7F6E\u8D34\u56FE\u548C\u5E95\u8272\u7684\u53E0\u52A0\u6A21\u5F0F + if(u_textureBlend == 0.0) { // normal + pattern.a = 0.0; + outputColor = filterColor(outputColor + pattern); + } else { // replace + pattern.a *= v_color.a; + if(outputColor.a <= 0.0) { + pattern.a = 0.0; + } + outputColor = filterColor(pattern); + } + } else { + outputColor = filterColor(outputColor); + } + + // gl_FragColor = filterColor(gl_FragColor); +}`,w6=`#define LineTypeSolid 0.0 +#define LineTypeDash 1.0 +#define Animate 0.0 +#define LineTexture 1.0 + +layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in float a_Size; +layout(location = 12) in vec4 a_Instance; +layout(location = 14) in vec2 a_iconMapUV; + +layout(std140) uniform commonUniorm { + vec4 u_animate: [ 1., 2., 1.0, 0.2 ]; + vec4 u_dash_array: [10.0, 5., 0, 0]; + vec4 u_sourceColor; + vec4 u_targetColor; + vec2 u_textSize; + float segmentNumber; + float u_line_type: 0.0; + float u_icon_step: 100; + float u_line_texture: 0.0; + float u_textureBlend; + float u_time; + float u_linearColor: 0; +}; + +out vec4 v_dash_array; +out vec4 v_color; +out vec2 v_iconMapUV; +out vec4 v_line_data; +out float v_distance_ratio; + +#pragma include "projection" +#pragma include "project" +#pragma include "picking" + +float maps (float value, float start1, float stop1, float start2, float stop2) { + return start2 + (stop2 - start2) * ((value - start1) / (stop1 - start1)); +} + +float getSegmentRatio(float index) { + return index / (segmentNumber - 1.); +} + +float paraboloid(vec2 source, vec2 target, float ratio) { + vec2 x = mix(source, target, ratio); + vec2 center = mix(source, target, 0.5); + float dSourceCenter = distance(source, center); + float dXCenter = distance(x, center); + return (dSourceCenter + dXCenter) * (dSourceCenter - dXCenter); +} + +vec3 getPos(vec2 source, vec2 target, float segmentRatio) { + float vertex_height = paraboloid(source, target, segmentRatio); + + return vec3( + mix(source, target, segmentRatio), + sqrt(max(0.0, vertex_height)) + ); +} +vec2 getExtrusionOffset(vec2 line_clipspace, float offset_direction) { + // normalized direction of the line + vec2 dir_screenspace = normalize(line_clipspace); + // rotate by 90 degrees + dir_screenspace = vec2(-dir_screenspace.y, dir_screenspace.x); + vec2 offset = dir_screenspace * offset_direction * setPickingSize(a_Size)/ 2.0; + return offset; +} +vec2 getNormal(vec2 line_clipspace, float offset_direction) { + // normalized direction of the line + vec2 dir_screenspace = normalize(line_clipspace); + // rotate by 90 degrees + dir_screenspace = vec2(-dir_screenspace.y, dir_screenspace.x); + return reverse_offset_normal(vec3(dir_screenspace,1.0)).xy * sign(offset_direction); +} +float getAngularDist (vec2 source, vec2 target) { + vec2 delta = source - target; + vec2 sin_half_delta = sin(delta / 2.0); + float a = + sin_half_delta.y * sin_half_delta.y + + cos(source.y) * cos(target.y) * + sin_half_delta.x * sin_half_delta.x; + return 2.0 * atan(sqrt(a), sqrt(1.0 - a)); +} + +vec2 midPoint(vec2 source, vec2 target) { + vec2 center = target - source; + float r = length(center); + float theta = atan(center.y, center.x); + float thetaOffset = 0.314; + float r2 = r / 2.0 / cos(thetaOffset); + float theta2 = theta + thetaOffset; + vec2 mid = vec2(r2*cos(theta2) + source.x, r2*sin(theta2) + source.y); + return mid; +} +float bezier3(vec3 arr, float t) { + float ut = 1. - t; + return (arr.x * ut + arr.y * t) * ut + (arr.y * ut + arr.z * t) * t; +} + +vec2 interpolate (vec2 source, vec2 target, float angularDist, float t) { + // if the angularDist is PI, linear interpolation is applied. otherwise, use spherical interpolation + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { // gaode2.x + vec2 mid = midPoint(source, target); + vec3 x = vec3(source.x, mid.x, target.x); + vec3 y = vec3(source.y, mid.y, target.y); + return vec2(bezier3(x ,t), bezier3(y,t)); + } + else { + if(abs(angularDist - PI) < 0.001) { + return (1.0 - t) * source + t * target; + } + float a = sin((1.0 - t) * angularDist) / sin(angularDist); + float b = sin(t * angularDist) / sin(angularDist); + vec2 sin_source = sin(source); + vec2 cos_source = cos(source); + vec2 sin_target = sin(target); + vec2 cos_target = cos(target); + float x = a * cos_source.y * cos_source.x + b * cos_target.y * cos_target.x; + float y = a * cos_source.y * sin_source.x + b * cos_target.y * sin_target.x; + float z = a * sin_source.y + b * sin_target.y; + return vec2(atan(y, x), atan(z, sqrt(x * x + y * y))); + } +} + +void main() { + v_color = a_Color; + v_color.a = v_color.a * opacity; + vec2 source = radians(a_Instance.rg); + vec2 target = radians(a_Instance.ba); + float angularDist = getAngularDist(source, target); + float segmentIndex = a_Position.x; + float segmentRatio = getSegmentRatio(segmentIndex); + float indexDir = mix(-1.0, 1.0, step(segmentIndex, 0.0)); + + if(u_line_type == LineTypeDash) { + v_distance_ratio = segmentIndex / segmentNumber; + vec2 s = source; + vec2 t = target; + + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { // gaode2.x + s = unProjCustomCoord(source); + t = unProjCustomCoord(target); + } + float total_Distance = pixelDistance(s, t) / 2.0 * PI; + total_Distance = total_Distance*16.0; // total_Distance*16.0 \u8C03\u6574\u9ED8\u8BA4\u7684\u6548\u679C + v_dash_array = pow(2.0, 20.0 - u_Zoom) * u_dash_array / total_Distance; + } + + if(u_animate.x == Animate) { + v_distance_ratio = segmentIndex / segmentNumber; + } + + float nextSegmentRatio = getSegmentRatio(segmentIndex + indexDir); + v_distance_ratio = segmentIndex / segmentNumber; + vec4 curr = project_position(vec4(degrees(interpolate(source, target, angularDist, segmentRatio)), 0.0, 1.0)); + vec4 next = project_position(vec4(degrees(interpolate(source, target, angularDist, nextSegmentRatio)), 0.0, 1.0)); + // v_normal = getNormal((next.xy - curr.xy) * indexDir, a_Position.y); + vec2 offset = project_pixel(getExtrusionOffset((next.xy - curr.xy) * indexDir, a_Position.y)); + // vec4 project_pos = project_position(vec4(curr.xy, 0, 1.0)); + // gl_Position = project_common_position_to_clipspace(vec4(curr.xy + offset, curr.z, 1.0)); + + v_line_data.g = a_Position.x; // \u8BE5\u9876\u70B9\u5728\u5F27\u7EBF\u4E0A\u7684\u5206\u6BB5\u6392\u5E8F + if(LineTexture == u_line_texture) { // \u5F00\u542F\u8D34\u56FE\u6A21\u5F0F + // float mapZoomScale = u_CoordinateSystem !== COORDINATE_SYSTEM_P20_2?10000000.0:1.0; + float d_arcDistrance = length(source - target); + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20) { // amap + d_arcDistrance = d_arcDistrance * 1000000.0; + } + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { // mapbox + d_arcDistrance = project_pixel_allmap(d_arcDistrance); + } + float d_pixelLen = project_pixel(u_icon_step)/8.0; + v_line_data.b = floor(d_arcDistrance/d_pixelLen); // \u8D34\u56FE\u5728\u5F27\u7EBF\u4E0A\u91CD\u590D\u7684\u6570\u91CF + + float lineOffsetWidth = length(offset + offset * sign(a_Position.y)); // \u7EBF\u6A2A\u5411\u504F\u79FB\u7684\u8DDD\u79BB + float linePixelSize = project_pixel(a_Size); // \u5B9A\u70B9\u4F4D\u7F6E\u504F\u79FB\uFF0C\u6309\u5730\u56FE\u7B49\u7EA7\u7F29\u653E\u540E\u7684\u8DDD\u79BB + v_line_data.a = lineOffsetWidth/linePixelSize; // \u7EBF\u56FE\u5C42\u8D34\u56FE\u90E8\u5206\u7684 v \u5750\u6807\u503C + + v_iconMapUV = a_iconMapUV; + } + + gl_Position = project_common_position_to_clipspace_v2(vec4(curr.xy + offset, 0, 1.0)); + setPickingColor(a_PickingColor); +} + +`,E6={solid:0,dash:1},S6=function(e){(0,Me.Z)(r,e);var i=A6(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u (v_dash_array.x + v_dash_array.y) && dashLength < v_dash_array.x + v_dash_array.y + v_dash_array.z))) { + // \u865A\u7EBF\u90E8\u5206 + discard; + }; + } + float animateSpeed = 0.0; // \u8FD0\u52A8\u901F\u5EA6 + float d_distance_ratio = v_texture_data.r; // \u5F53\u524D\u70B9\u4F4D\u8DDD\u79BB\u5360\u7EBF\u603B\u957F\u7684\u6BD4\u4F8B + if(u_linearDir < 1.0) { + d_distance_ratio = v_texture_data.a; + } + if(u_linearColor == 1.0) { // \u4F7F\u7528\u6E10\u53D8\u989C\u8272 + outputColor = mix(u_sourceColor, u_targetColor, d_distance_ratio); + outputColor.a *= v_color.a; + } else { // \u4F7F\u7528 color \u65B9\u6CD5\u4F20\u5165\u7684\u989C\u8272 + outputColor = v_color; + } + // anti-alias + // float blur = 1.0 - smoothstep(u_blur, 1., length(v_normal.xy)); + if(u_animate.x == Animate) { + animateSpeed = u_time / u_animate.y; + float alpha =1.0 - fract( mod(1.0- d_distance_ratio, u_animate.z)* (1.0/ u_animate.z) + animateSpeed); + alpha = (alpha + u_animate.w -1.0) / u_animate.w; + alpha = smoothstep(0., 1., alpha); + outputColor.a *= alpha; + } + + if(u_line_texture == LineTexture) { // while load texture + float aDistance = v_texture_data.g; // \u5F53\u524D\u9876\u70B9\u7684\u8DDD\u79BB + float d_texPixelLen = v_texture_data.b; // \u8D34\u56FE\u7684\u50CF\u7D20\u957F\u5EA6\uFF0C\u6839\u636E\u5730\u56FE\u5C42\u7EA7\u7F29\u653E + float u = fract(mod(aDistance, d_texPixelLen)/d_texPixelLen - animateSpeed); + float v = v_texture_data.a; // \u7EBF\u56FE\u5C42\u8D34\u56FE\u90E8\u5206\u7684 v \u5750\u6807\u503C + + // v = max(smoothstep(0.95, 1.0, v), v); + vec2 uv= v_iconMapUV / u_textSize + vec2(u, v) / u_textSize * 64.; + vec4 pattern = texture(SAMPLER_2D(u_texture), uv); + + if(u_textureBlend == 0.0) { // normal + pattern.a = 0.0; + outputColor += pattern; + } else { // replace + pattern.a *= v_color.a; + if(outputColor.a <= 0.0) { + pattern.a = 0.0; + } + outputColor = pattern; + } + } + + float v = v_texture_data.a; + float strokeWidth = min(0.5, u_strokeWidth); + // \u7ED8\u5236 border + if(strokeWidth > 0.01) { + float borderOuterWidth = strokeWidth / 2.0; + + + if(v >= 1.0 - strokeWidth || v <= strokeWidth) { + if(v > strokeWidth) { // \u5916\u4FA7 + float linear = smoothstep(0.0, 1.0, (v - (1.0 - strokeWidth))/strokeWidth); + // float linear = step(0.0, (v - (1.0 - borderWidth))/borderWidth); + outputColor.rgb = mix(outputColor.rgb, v_stroke.rgb, linear); + } else if(v <= strokeWidth) { + float linear = smoothstep(0.0, 1.0, v/strokeWidth); + outputColor.rgb = mix(v_stroke.rgb, outputColor.rgb, linear); + } + } + + if(v < borderOuterWidth) { + outputColor.a = mix(0.0, outputColor.a, v/borderOuterWidth); + } else if(v > 1.0 - borderOuterWidth) { + outputColor.a = mix(outputColor.a, 0.0, (v - (1.0 - borderOuterWidth))/borderOuterWidth); + } + } + + // blur + float blurV = v_texture_data.a; + if(blurV < 0.5) { + outputColor.a *= mix(u_blur.r, u_blur.g, blurV/0.5); + } else { + outputColor.a *= mix(u_blur.g, u_blur.b, (blurV - 0.5)/0.5); + } + + outputColor = filterColor(outputColor); +} +`,P6=` +#define Animate 0.0 + +layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in vec2 a_Size; +layout(location = 10) in vec3 a_DistanceAndIndexAndMiter; +layout(location = 13) in vec4 a_Normal_Total_Distance; +layout(location = 14) in vec2 a_iconMapUV; + +layout(std140) uniform commonUniorm { + vec4 u_animate: [ 1., 2., 1.0, 0.2 ]; + vec4 u_dash_array; + vec4 u_blur; + vec4 u_sourceColor; + vec4 u_targetColor; + vec2 u_textSize; + float u_icon_step: 100; + float u_heightfixed: 0.0; + float u_vertexScale: 1.0; + float u_raisingHeight: 0.0; + float u_strokeWidth: 0.0; + float u_textureBlend; + float u_line_texture; + float u_linearDir: 1.0; + float u_linearColor: 0; + float u_time; +}; + + +out vec4 v_color; +out vec4 v_stroke; +//dash +out vec4 v_dash_array; +out float v_d_distance_ratio; +// texV \u7EBF\u56FE\u5C42 - \u8D34\u56FE\u90E8\u5206\u7684 v \u5750\u6807\uFF08\u7EBF\u7684\u5BBD\u5EA6\u65B9\u5411\uFF09 +out vec2 v_iconMapUV; +out vec4 v_texture_data; + +#pragma include "projection" +#pragma include "picking" + +void main() { + vec2 a_DistanceAndIndex = a_DistanceAndIndexAndMiter.xy; + float a_Miter = a_DistanceAndIndexAndMiter.z; + vec3 a_Normal = a_Normal_Total_Distance.xyz; + float a_Total_Distance = a_Normal_Total_Distance.w; + //dash\u8F93\u51FA + v_dash_array = pow(2.0, 20.0 - u_Zoom) * u_dash_array / a_Total_Distance; + v_d_distance_ratio = a_DistanceAndIndex.x / a_Total_Distance; + + // cal style mapping - \u6570\u636E\u7EB9\u7406\u6620\u5C04\u90E8\u5206\u7684\u8BA1\u7B97 + float d_texPixelLen; // \u8D34\u56FE\u7684\u50CF\u7D20\u957F\u5EA6\uFF0C\u6839\u636E\u5730\u56FE\u5C42\u7EA7\u7F29\u653E + v_iconMapUV = a_iconMapUV; + d_texPixelLen = project_float_pixel(u_icon_step); + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { + d_texPixelLen *= 10.0; + } + + v_color = a_Color; + v_color.a *= opacity; + v_stroke = stroke; + + vec3 size = a_Miter * setPickingSize(a_Size.x) * reverse_offset_normal(a_Normal); + + vec2 offset = project_pixel(size.xy); + + float lineDistance = a_DistanceAndIndex.x; + float currentLinePointRatio = lineDistance / a_Total_Distance; + + + float lineOffsetWidth = length(offset + offset * sign(a_Miter)); // \u7EBF\u6A2A\u5411\u504F\u79FB\u7684\u8DDD\u79BB\uFF08\u5411\u4E24\u4FA7\u504F\u79FB\u7684\u548C\uFF09 + float linePixelSize = project_pixel(a_Size.x) * 2.0; // \u5B9A\u70B9\u4F4D\u7F6E\u504F\u79FB\uFF0C\u6309\u5730\u56FE\u7B49\u7EA7\u7F29\u653E\u540E\u7684\u8DDD\u79BB \u5355\u4FA7 * 2 + float texV = lineOffsetWidth/linePixelSize; // \u7EBF\u56FE\u5C42\u8D34\u56FE\u90E8\u5206\u7684 v \u5750\u6807\u503C + + v_texture_data = vec4(currentLinePointRatio, lineDistance, d_texPixelLen, texV); + // \u8BBE\u7F6E\u6570\u636E\u96C6\u7684\u53C2\u6570 + + vec4 project_pos = project_position(vec4(a_Position.xy, 0, 1.0)); + + // gl_Position = project_common_position_to_clipspace(vec4(project_pos.xy + offset, a_Size.y, 1.0)); + + float h = float(a_Position.z) * u_vertexScale; // \u7EBF\u9876\u70B9\u7684\u9AD8\u5EA6 - \u517C\u5BB9\u4E0D\u5B58\u5728\u7B2C\u4E09\u4E2A\u6570\u503C\u7684\u60C5\u51B5 vertex height + float lineHeight = a_Size.y; // size \u7B2C\u4E8C\u4E2A\u53C2\u6570\u4EE3\u8868\u7684\u9AD8\u5EA6 [linewidth, lineheight] + + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { // gaode2.x + lineHeight *= 0.2; // \u4FDD\u6301\u548C amap/mapbox \u4E00\u81F4\u7684\u6548\u679C + h *= 0.2; + if(u_heightfixed < 1.0) { + lineHeight = project_pixel(a_Size.y); + } + gl_Position = u_Mvp * (vec4(project_pos.xy + offset, lineHeight + h + u_raisingHeight, 1.0)); + } else { + // mapbox - amap + + // \u517C\u5BB9 mapbox \u5728\u7EBF\u9AD8\u5EA6\u4E0A\u7684\u6548\u679C\u8868\u73B0\u57FA\u672C\u4E00\u81F4 + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + // mapbox + // \u4FDD\u6301\u9AD8\u5EA6\u76F8\u5BF9\u4E0D\u53D8 + float mapboxZoomScale = 4.0/pow(2.0, 21.0 - u_Zoom); + h *= mapboxZoomScale; + h += u_raisingHeight * mapboxZoomScale; + if(u_heightfixed > 0.0) { + lineHeight *= mapboxZoomScale; + } + + } else { + // amap + h += u_raisingHeight; + // lineHeight \u9876\u70B9\u504F\u79FB\u9AD8\u5EA6 + if(u_heightfixed < 1.0) { + lineHeight *= pow(2.0, 20.0 - u_Zoom); + } + } + + gl_Position = project_common_position_to_clipspace(vec4(project_pos.xy + offset, lineHeight + h, 1.0)); + } + + setPickingColor(a_PickingColor); +} +`,dV={solid:0,dash:1},bS=function(e){(0,Me.Z)(r,e);var i=C6(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u (v_dash_array.x + v_dash_array.y) && dashLength < v_dash_array.x + v_dash_array.y + v_dash_array.z))) { + // \u865A\u7EBF\u90E8\u5206 + discard; + }; + } + if(u_linearColor==1.0){ + outputColor = mix(u_sourceColor, u_targetColor, v_distanceScale); + outputColor.a *= v_color.a; // \u5168\u5C40\u900F\u660E\u5EA6 + } + else{ + outputColor = v_color; + } +} +`,L6=`layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in vec4 a_SizeDistanceAndTotalDistance; + +layout(std140) uniform commonUniorm { + vec4 u_sourceColor; + vec4 u_targetColor; + vec4 u_dash_array; + float u_vertexScale: 1.0; + float u_linearColor: 0; +}; + +#pragma include "projection" +#pragma include "picking" + +out vec4 v_color; +out float v_distanceScale; +out vec4 v_dash_array; + +void main() { + //dash\u8F93\u51FA + v_dash_array = pow(2.0, 20.0 - u_Zoom) * u_dash_array / a_SizeDistanceAndTotalDistance.a; + + v_color = a_Color; + v_distanceScale = a_SizeDistanceAndTotalDistance.b / a_SizeDistanceAndTotalDistance.a; + v_color.a = v_color.a * opacity; + vec4 project_pos = project_position(vec4(a_Position.xy, 0, 1.0)); + + float h = float(a_Position.z) * u_vertexScale; // \u7EBF\u9876\u70B9\u7684\u9AD8\u5EA6 - \u517C\u5BB9\u4E0D\u5B58\u5728\u7B2C\u4E09\u4E2A\u6570\u503C\u7684\u60C5\u51B5 + + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { // gaode2.x + gl_Position = u_Mvp * (vec4(project_pos.xy, project_pixel(a_SizeDistanceAndTotalDistance.y) + h * 0.2, 1.0)); + } else { + float lineHeight = a_SizeDistanceAndTotalDistance.y; + // \u517C\u5BB9 mapbox \u5728\u7EBF\u9AD8\u5EA6\u4E0A\u7684\u6548\u679C\u8868\u73B0\u57FA\u672C\u4E00\u81F4 + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + // \u4FDD\u6301\u9AD8\u5EA6\u76F8\u5BF9\u4E0D\u53D8 + h *= 2.0/pow(2.0, 20.0 - u_Zoom); + } + + // amap1.x + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20 || u_CoordinateSystem == COORDINATE_SYSTEM_P20_OFFSET) { + // \u4FDD\u6301\u9AD8\u5EA6\u76F8\u5BF9\u4E0D\u53D8 + lineHeight *= pow(2.0, 20.0 - u_Zoom); + } + + gl_Position = project_common_position_to_clipspace(vec4(project_pos.xy, lineHeight + h, 1.0)); + gl_PointSize = 10.0; + } +} +`,pV=lo.isNumber,D6=function(e){(0,Me.Z)(r,e);var i=I6(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.sourceColor,u=t.targetColor,c=t.lineType,m=c===void 0?"solid":c,E=t.dashArray,H=E===void 0?[10,5,0,0]:E,re=t.vertexHeightScale,xe=re===void 0?20:re,ke=H;m!=="dash"&&(ke=[0,0,0,0]),ke.length===2&&ke.push(0,0);var rt=0,vt=[0,0,0,0],It=[0,0,0,0];a&&u&&(vt=Lo(a),It=Lo(u),rt=1);var er={u_sourceColor:vt,u_targetColor:It,u_dash_array:ke,u_vertexScale:xe,u_linearColor:rt},Ar=this.getUniformsBufferInfo(er);return Ar}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.abrupt("return",this.buildModels());case 1:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"getShaders",value:function(){return{frag:O6,vert:L6,type:"lineSimpleNormal"}}},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E,H;return Ur().wrap(function(xe){for(;;)switch(xe.prev=xe.next){case 0:return this.initUniformsBuffer(),u=this.getShaders(),c=u.frag,m=u.vert,E=u.type,xe.next=4,this.layer.buildLayerModel({moduleName:E,vertexShader:m,fragmentShader:c,triangulation:CI,inject:this.getInject(),primitive:Er.LINES,depth:{enable:!1},pick:!1});case 4:return H=xe.sent,xe.abrupt("return",[H]);case 6:case"end":return xe.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"registerBuiltinAttributes",value:function(){this.styleAttributeService.registerStyleAttribute({name:"sizeDistanceAndTotalDistance",type:Vu.Attribute,descriptor:{name:"a_SizeDistanceAndTotalDistance",shaderLocation:Gc.SIZE,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:4,update:function(a,u,c){var m=a.size,E=m===void 0?1:m,H=Array.isArray(E)?[E[0],E[1]]:[E,0];return[H[0],H[1],c[3],c[5]]}}})}}]),r}(Kd);function k6(e){var i=F6();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function F6(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var B6=`#define Animate 0.0 +#define LineTexture 1.0 + +// line texture + +uniform sampler2D u_texture; +layout(std140) uniform commonUniorm { + vec4 u_animate: [ 1., 2., 1.0, 0.2 ]; + vec4 u_sourceColor; + vec4 u_targetColor; + vec2 u_textSize; + float u_icon_step: 100; + float u_heightfixed; + float u_linearColor: 0; + float u_line_texture; + float u_textureBlend; + float u_iconStepCount; + float u_time; +}; +in vec2 v_iconMapUV; +in float v_blur; +in float v_radio; +in vec4 v_color; +in vec4 v_dataset; + +out vec4 outputColor; +#pragma include "picking" + +void main() { + float animateSpeed = 0.0; // \u8FD0\u52A8\u901F\u5EA6 + float d_distance_ratio = v_dataset.r; // \u5F53\u524D\u70B9\u4F4D\u8DDD\u79BB\u5360\u7EBF\u603B\u957F\u7684\u6BD4\u4F8B + float v = v_dataset.a; + + if(u_linearColor == 1.0) { // \u4F7F\u7528\u6E10\u53D8\u989C\u8272 + outputColor = mix(u_sourceColor, u_targetColor, v); + } else { // \u4F7F\u7528 color \u65B9\u6CD5\u4F20\u5165\u7684\u989C\u8272 + outputColor = v_color; + } + + outputColor.a *= v_color.a; // \u5168\u5C40\u900F\u660E\u5EA6 + if(u_animate.x == Animate) { + animateSpeed = u_time / u_animate.y; + float alpha =1.0 - fract( mod(1.0- d_distance_ratio, u_animate.z)* (1.0/ u_animate.z) + animateSpeed); + alpha = (alpha + u_animate.w -1.0) / u_animate.w; + alpha = smoothstep(0., 1., alpha); + outputColor.a *= alpha; + } + + if(u_line_texture == LineTexture) { // while load texture + float aDistance = v_dataset.g; // \u5F53\u524D\u9876\u70B9\u7684\u8DDD\u79BB + float d_texPixelLen = v_dataset.b; // \u8D34\u56FE\u7684\u50CF\u7D20\u957F\u5EA6\uFF0C\u6839\u636E\u5730\u56FE\u5C42\u7EA7\u7F29\u653E + float u = fract(mod(aDistance, d_texPixelLen)/d_texPixelLen - animateSpeed); + float v = v_dataset.a; // \u7EBF\u56FE\u5C42\u8D34\u56FE\u90E8\u5206\u7684 v \u5750\u6807\u503C + + // \u8BA1\u7B97\u7EB9\u7406\u95F4\u9694 start + float flag = 0.0; + if(u > 1.0/u_iconStepCount) { + flag = 1.0; + } + u = fract(u*u_iconStepCount); + // \u8BA1\u7B97\u7EB9\u7406\u95F4\u9694 end + + vec2 uv= v_iconMapUV / u_textSize + vec2(u, v) / u_textSize * 64.; + vec4 pattern = texture(SAMPLER_2D(u_texture), uv); + + // Tip: \u5224\u65AD\u7EB9\u7406\u95F4\u9694 + if(flag > 0.0) { + pattern = vec4(0.0); + } + + if(u_textureBlend == 0.0) { // normal + pattern.a = 0.0; + outputColor = filterColor(outputColor + pattern); + } else { // replace + pattern.a *= v_color.a; + if(outputColor.a <= 0.0) { + pattern.a = 0.0; + } + outputColor = filterColor(pattern); + } + } + + + // blur - AA + if(v < v_blur) { + outputColor.a = mix(0.0, outputColor.a, v/v_blur); + } else if(v > 1.0 - v_blur) { + outputColor.a = mix(outputColor.a, 0.0, (v - (1.0 - v_blur))/v_blur); + } + + outputColor = filterColor(outputColor); +} +`,N6=`#define Animate 0.0 +layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in vec2 a_Size; +layout(location = 10) in float a_Miter; +layout(location = 11) in float a_Total_Distance; +layout(location = 12) in vec4 a_Instance; +layout(location = 13) in vec3 a_Normal; +layout(location = 14) in vec2 a_iconMapUV; +layout(location = 15) in float a_Distance; + + +layout(std140) uniform commonUniorm { + vec4 u_animate: [ 1., 2., 1.0, 0.2 ]; + vec4 u_sourceColor; + vec4 u_targetColor; + vec2 u_textSize; + float u_icon_step: 100; + float u_heightfixed; + float u_linearColor: 0; + float u_line_texture; + float u_textureBlend; + float u_iconStepCount; + float u_time; +}; +#pragma include "projection" +#pragma include "light" +#pragma include "picking" + +// texV \u7EBF\u56FE\u5C42 - \u8D34\u56FE\u90E8\u5206\u7684 v \u5750\u6807\uFF08\u7EBF\u7684\u5BBD\u5EA6\u65B9\u5411\uFF09 +out vec2 v_iconMapUV; +out vec4 v_color; +out float v_blur; +out float v_radio; +out vec4 v_dataset; + +void main() { + + + float d_distance_ratio; // \u5F53\u524D\u70B9\u4F4D\u8DDD\u79BB\u5360\u7EBF\u603B\u957F\u7684\u6BD4\u4F8B + float d_texPixelLen; // \u8D34\u56FE\u7684\u50CF\u7D20\u957F\u5EA6\uFF0C\u6839\u636E\u5730\u56FE\u5C42\u7EA7\u7F29\u653E + + v_iconMapUV = a_iconMapUV; + if(u_heightfixed < 1.0) { // \u9AD8\u5EA6\u968F zoom \u8C03\u6574 + d_texPixelLen = project_pixel(u_icon_step); + } else { + d_texPixelLen = u_icon_step; + } + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { + d_texPixelLen *= 10.0; + } + + if(u_animate.x == Animate || u_linearColor == 1.0) { + d_distance_ratio = a_Distance / a_Total_Distance; + } + + float miter = (a_Miter + 1.0)/2.0; + // \u8BBE\u7F6E\u6570\u636E\u96C6\u7684\u53C2\u6570 + v_dataset[0] = d_distance_ratio; // \u5F53\u524D\u70B9\u4F4D\u8DDD\u79BB\u5360\u7EBF\u603B\u957F\u7684\u6BD4\u4F8B + v_dataset[1] = a_Distance; // \u5F53\u524D\u9876\u70B9\u7684\u8DDD\u79BB + v_dataset[2] = d_texPixelLen; // \u8D34\u56FE\u7684\u50CF\u7D20\u957F\u5EA6\uFF0C\u6839\u636E\u5730\u56FE\u5C42\u7EA7\u7F29\u653E + v_dataset[3] = miter; // \u7EBF\u56FE\u5C42\u8D34\u56FE\u90E8\u5206\u7684 v \u5750\u6807\u503C 0 - 1 + + vec4 project_pos = project_position(vec4(a_Position.xy, 0, 1.0)); + + float originSize = a_Size.x; // \u56FA\u5B9A\u9AD8\u5EA6 + if(u_heightfixed < 1.0) { + originSize = project_float_meter(a_Size.x); // \u9AD8\u5EA6\u968F zoom \u8C03\u6574 + } + + + float wallHeight = originSize * miter; + float lightWeight = calc_lighting(vec4(project_pos.xy, wallHeight, 1.0)); + + v_blur = min(project_float_pixel(2.0) / originSize, 0.05); + v_color = vec4(a_Color.rgb * lightWeight, a_Color.w * opacity); + + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { // gaode2.x + gl_Position = u_Mvp * (vec4(project_pos.xy, wallHeight, 1.0)); + } else { + gl_Position = project_common_position_to_clipspace(vec4(project_pos.xy, wallHeight, 1.0)); + } + + setPickingColor(a_PickingColor); +} +`,z6=function(e){(0,Me.Z)(r,e);var i=k6(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u 0.01 + float blurWidth = (1.0 - v_blur)/2.0; + vec4 stroke = vec4(u_stroke_color.rgb, u_stroke_opacity); + if(fragmengTocenter > v_innerRadius + blurWidth) { + outputColor = stroke; + } else if(fragmengTocenter > v_innerRadius - blurWidth){ + float mixR = (fragmengTocenter - (v_innerRadius - blurWidth)) / (blurWidth * 2.0); + outputColor = mix(v_color, stroke, mixR); + } else { + outputColor = v_color; + } + } else { + // \u5F53\u4E0D\u5B58\u5728 stroke \u6216 stroke <= 0.01 + outputColor = v_color; + } + + outputColor = filterColor(outputColor); + + if(u_additive > 0.0) { + outputColor *= circleClipOpacity; + } else { + outputColor.a *= circleClipOpacity; + } + +} +`,W6=` +layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in float a_Size; + +layout(std140) uniform commonUniorm { + vec4 u_stroke_color; + float u_additive; + float u_stroke_opacity; + float u_stroke_width; +}; + +out vec4 v_color; +out float v_blur; +out float v_innerRadius; + +#pragma include "projection" +#pragma include "picking" +#pragma include "project" +void main() { + v_color = vec4(a_Color.xyz, a_Color.w * opacity); + v_blur = 1.0 - max(2.0/a_Size, 0.05); + v_innerRadius = max((a_Size - u_stroke_width) / a_Size, 0.0); + + vec2 offset = project_pixel(u_offsets); + + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { // gaode2.x + gl_Position = u_Mvp * vec4(a_Position.xy + offset, a_Position.z, 1.0); + } else { // else + vec4 project_pos = project_position(vec4(a_Position, 1.0)) + vec4(a_Size / 2.,-a_Size /2.,0.,0.); + gl_Position = project_common_position_to_clipspace(vec4(vec2(project_pos.xy+offset),project_pos.z,project_pos.w)); + } + + gl_PointSize = a_Size * 2.0 * u_DevicePixelRatio; + setPickingColor(a_PickingColor); +} +`;function xS(e){var i=e.coordinates;return{vertices:(0,On.Z)(i),indices:[0],size:i.length}}var X6=function(e){(0,Me.Z)(r,e);var i=$6(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getDefaultStyle",value:function(){return{blend:"additive"}}},{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.blend,u=t.strokeOpacity,c=u===void 0?1:u,m=t.strokeWidth,E=m===void 0?0:m,H=t.stroke,re=H===void 0?"#fff":H,xe={u_stroke_color:Lo(re),u_additive:a==="additive"?1:0,u_stroke_opacity:c,u_stroke_width:E},ke=this.getUniformsBufferInfo(xe);return ke}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.abrupt("return",this.buildModels());case 1:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u;return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return this.layer.triangulation=xS,this.initUniformsBuffer(),m.next=4,this.layer.buildLayerModel({moduleName:"pointSimple",vertexShader:W6,fragmentShader:G6,inject:this.getInject(),triangulation:xS,depth:{enable:!1},primitive:Er.POINTS});case 4:return u=m.sent,m.abrupt("return",[u]);case 6:case"end":return m.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"registerBuiltinAttributes",value:function(){this.styleAttributeService.registerStyleAttribute({name:"size",type:Vu.Attribute,descriptor:{name:"a_Size",shaderLocation:Gc.SIZE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(a){var u=a.size,c=u===void 0?1:u;return Array.isArray(c)?[c[0]]:[c]}}})}}]),r}(Kd);function Y6(e){var i=K6();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function K6(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var q6=`precision highp float; +in vec4 v_color; + +#pragma include "picking" + +layout(std140) uniform commonUniform { + vec4 u_sourceColor; + vec4 u_targetColor; + float u_linearColor: 0; + float u_heightfixed: 0.0; // \u9ED8\u8BA4\u4E0D\u56FA\u5B9A + float u_globel; + float u_r; + float u_pickLight: 0.0; + float u_opacitylinear: 0.0; + float u_opacitylinear_dir: 1.0; + float u_lightEnable: 1.0; +}; +in float v_lightWeight; +in float v_barLinearZ; +out vec4 outputColor; +void main() { + + outputColor = v_color; + + // \u5F00\u542F\u900F\u660E\u5EA6\u6E10\u53D8 + if(u_opacitylinear > 0.0) { + outputColor.a *= u_opacitylinear_dir > 0.0 ? (1.0 - v_barLinearZ): v_barLinearZ; + } + + // picking + if(u_pickLight > 0.0) { + outputColor = filterColorAlpha(outputColor, v_lightWeight); + } else { + outputColor = filterColor(outputColor); + } +} +`,Q6=`precision highp float; + +#define pi 3.1415926535 +#define ambientRatio 0.5 +#define diffuseRatio 0.3 +#define specularRatio 0.2 + + +layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in vec3 a_Size; +layout(location = 11) in vec3 a_Pos; +layout(location = 13) in vec3 a_Normal; + + +layout(std140) uniform commonUniform { + vec4 u_sourceColor; + vec4 u_targetColor; + float u_linearColor: 0; + float u_heightfixed: 0.0; // \u9ED8\u8BA4\u4E0D\u56FA\u5B9A + float u_globel; + float u_r; + float u_pickLight: 0.0; + float u_opacitylinear: 0.0; + float u_opacitylinear_dir: 1.0; + float u_lightEnable: 1.0; +}; + +out vec4 v_color; +out float v_lightWeight; +out float v_barLinearZ; +// \u7528\u4E8E\u5C06\u5728\u9876\u70B9\u7740\u8272\u5668\u4E2D\u8BA1\u7B97\u597D\u7684\u6837\u5F0F\u503C\u4F20\u9012\u7ED9\u7247\u5143 + + +#pragma include "projection" +#pragma include "light" +#pragma include "picking" + +float getYRadian(float x, float z) { + if(x > 0.0 && z > 0.0) { + return atan(x/z); + } else if(x > 0.0 && z <= 0.0){ + return atan(-z/x) + pi/2.0; + } else if(x <= 0.0 && z <= 0.0) { + return pi + atan(x/z); //atan(x/z) + + } else { + return atan(z/-x) + pi*3.0/2.0; + } +} + +float getXRadian(float y, float r) { + return atan(y/r); +} + +void main() { + + // cal style mapping - \u6570\u636E\u7EB9\u7406\u6620\u5C04\u90E8\u5206\u7684\u8BA1\u7B97 + vec3 size = a_Size * a_Position; + + // a_Position.z \u662F\u5728\u6784\u5EFA\u7F51\u683C\u7684\u65F6\u5019\u4F20\u5165\u7684\u6807\u51C6\u503C 0 - 1\uFF0C\u5728\u63D2\u503C\u5668\u63D2\u503C\u53EF\u4EE5\u83B7\u53D6 0\uFF5E1 \u7EBF\u6027\u6E10\u53D8\u7684\u503C + v_barLinearZ = a_Position.z; + + vec3 offset = size; // \u63A7\u5236\u5706\u67F1\u4F53\u7684\u5927\u5C0F - \u4ECE\u6807\u51C6\u5355\u4F4D\u5706\u67F1\u4F53\u8FDB\u884C\u504F\u79FB + if(u_heightfixed < 1.0) { // \u5706\u67F1\u4F53\u4E0D\u56FA\u5B9A\u9AD8\u5EA6 + + if (u_CoordinateSystem == COORDINATE_SYSTEM_P20 || u_CoordinateSystem == COORDINATE_SYSTEM_P20_OFFSET) { + // P20 \u5750\u6807\u7CFB\u4E0B\uFF0C\u4E3A\u4E86\u548C Web \u58A8\u5361\u6258\u5750\u6807\u7CFB\u7EDF\u4E00\uFF0Czoom \u9ED8\u8BA4\u51CF1 + offset = offset * pow(2.0, (19.0 - u_Zoom)); + } + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { + // P20_2 \u5750\u6807\u7CFB\u4E0B\uFF0C\u4E3A\u4E86\u548C Web \u58A8\u5361\u6258\u5750\u6807\u7CFB\u7EDF\u4E00\uFF0Czoom \u9ED8\u8BA4\u51CF3 + offset = offset * pow(2.0, (19.0 - 3.0 - u_Zoom)); + } + } else {// \u5706\u67F1\u4F53\u56FA\u5B9A\u9AD8\u5EA6 \uFF08 \u5904\u7406 mapbox \uFF09 + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + offset *= 4.0/pow(2.0, 21.0 - u_Zoom); + } + } + + + vec4 project_pos = project_position(vec4(a_Pos.xy, 0., 1.0)); + + // u_r \u63A7\u5236\u5706\u67F1\u7684\u751F\u957F + vec4 pos = vec4(project_pos.xy + offset.xy, offset.z * u_r, 1.0); + + // \u5706\u67F1\u5149\u7167\u6548\u679C + float lightWeight = 1.0; + if(u_lightEnable > 0.0) { // \u53D6\u6D88\u4E09\u5143\u8868\u8FBE\u5F0F\uFF0C\u589E\u5F3A\u5065\u58EE\u6027 + lightWeight = calc_lighting(pos); + } + v_lightWeight = lightWeight; + // \u8BBE\u7F6E\u5706\u67F1\u7684\u5E95\u8272 + if(u_linearColor == 1.0) { // \u4F7F\u7528\u6E10\u53D8\u989C\u8272 + v_color = mix(u_sourceColor, u_targetColor, v_barLinearZ); + v_color.rgb *= lightWeight; + } else { // \u4F7F\u7528 color \u65B9\u6CD5\u4F20\u5165\u7684\u989C\u8272 + v_color = a_Color; + } + v_color.a *= u_opacity; + + + // \u5728\u5730\u7403\u6A21\u5F0F\u4E0B\uFF0C\u5C06\u539F\u672C\u5782\u76F4\u4E8E xy \u5E73\u9762\u7684\u5706\u67F1\u8C03\u6574\u59FF\u6001\u5230\u9002\u5E94\u5706\u7684\u89D2\u5EA6 + //\u65CB\u8F6C\u77E9\u9635mx\uFF0C\u521B\u5EFA\u7ED5x\u8F74\u65CB\u8F6C\u77E9\u9635 + float r = sqrt(a_Pos.z*a_Pos.z + a_Pos.x*a_Pos.x); + float xRadian = getXRadian(a_Pos.y, r); + float xcos = cos(xRadian);//\u6C42\u89E3\u65CB\u8F6C\u89D2\u5EA6\u4F59\u5F26\u503C + float xsin = sin(xRadian);//\u6C42\u89E3\u65CB\u8F6C\u89D2\u5EA6\u6B63\u5F26\u503C + mat4 mx = mat4( + 1,0,0,0, + 0,xcos,-xsin,0, + 0,xsin,xcos,0, + 0,0,0,1); + + //\u65CB\u8F6C\u77E9\u9635my\uFF0C\u521B\u5EFA\u7ED5y\u8F74\u65CB\u8F6C\u77E9\u9635 + float yRadian = getYRadian(a_Pos.x, a_Pos.z); + float ycos = cos(yRadian);//\u6C42\u89E3\u65CB\u8F6C\u89D2\u5EA6\u4F59\u5F26\u503C + float ysin = sin(yRadian);//\u6C42\u89E3\u65CB\u8F6C\u89D2\u5EA6\u6B63\u5F26\u503C + mat4 my = mat4( + ycos,0,-ysin,0, + 0,1,0,0, + ysin,0,ycos,0, + 0,0,0,1); + + gl_Position = u_ViewProjectionMatrix * vec4(( my * mx * vec4(a_Position * a_Size, 1.0)).xyz + a_Pos, 1.0); + + + setPickingColor(a_PickingColor); +} +`,J6=lo.isNumber,eO=function(e){(0,Me.Z)(r,e);var i=Y6(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u0&&u.enable){var wn=u.speed,Cn=wn===void 0?.01:wn;this.raiseCount+=Cn,this.raiseCount>=1&&(this.raiseRepeat>1?(this.raiseCount=0,this.raiseRepeat--):this.raiseCount=1)}var qn={u_sourceColor:rn,u_targetColor:Ln,u_linearColor:Or,u_pickLight:Number(xe),u_heightfixed:Number(rt),u_r:u.enable&&this.raiseRepeat>0?this.raiseCount:1,u_opacity:J6(m)?m:1,u_opacitylinear:Number(It.enable),u_opacitylinear_dir:It.dir==="up"?1:0,u_lightEnable:Number(Ar)},Si=this.getUniformsBufferInfo(qn);return Si}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return this.initUniformsBuffer(),c.abrupt("return",this.buildModels());case 2:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E;return Ur().wrap(function(re){for(;;)switch(re.prev=re.next){case 0:return u=this.layer.getLayerConfig(),c=u.animateOption.repeat,m=c===void 0?1:c,this.raiseRepeat=m,re.next=4,this.layer.buildLayerModel({moduleName:"pointEarthExtrude",vertexShader:Q6,fragmentShader:q6,triangulation:Hx,depth:{enable:!0},inject:this.getInject(),cull:{enable:!0,face:Xi(this.mapService.version)},blend:this.getBlend()});case 4:return E=re.sent,re.abrupt("return",[E]);case 6:case"end":return re.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"registerBuiltinAttributes",value:function(){this.styleAttributeService.registerStyleAttribute({name:"size",type:Vu.Attribute,descriptor:{name:"a_Size",shaderLocation:Gc.SIZE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(a){var u=a.size;if(u){var c=[];return Array.isArray(u)&&(c=u.length===2?[u[0],u[0],u[1]]:u),Array.isArray(u)||(c=[u,u,u]),c}else return[2,2,2]}}}),this.styleAttributeService.registerStyleAttribute({name:"normal",type:Vu.Attribute,descriptor:{name:"a_Normal",shaderLocation:Gc.NORMAL,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(a,u,c,m,E){return E}}}),this.styleAttributeService.registerStyleAttribute({name:"pos",type:Vu.Attribute,descriptor:{name:"a_Pos",shaderLocation:15,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(a){var u=wl(a.coordinates);return tS([u[0],u[1]])}}})}}]),r}(Kd);function tO(e){var i=rO();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function rO(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var nO=`in vec4 v_data; +in vec4 v_color; +in float v_radius; + +layout(std140) uniform commonUniform { + float u_additive; + float u_stroke_opacity : 1; + float u_stroke_width : 2; + float u_blur : 0.0; +}; +#pragma include "sdf_2d" +#pragma include "picking" + +out vec4 outputColor; + +void main() { + int shape = int(floor(v_data.w + 0.5)); + + vec4 strokeColor = u_stroke == vec4(0.0) ? v_color : u_stroke; + + lowp float antialiasblur = v_data.z; + float r = v_radius / (v_radius + u_stroke_width); + + float outer_df; + float inner_df; + // 'circle', 'triangle', 'square', 'pentagon', 'hexagon', 'octogon', 'hexagram', 'rhombus', 'vesica' + if (shape == 0) { + outer_df = sdCircle(v_data.xy, 1.0); + inner_df = sdCircle(v_data.xy, r); + } else if (shape == 1) { + outer_df = sdEquilateralTriangle(1.1 * v_data.xy); + inner_df = sdEquilateralTriangle(1.1 / r * v_data.xy); + } else if (shape == 2) { + outer_df = sdBox(v_data.xy, vec2(1.)); + inner_df = sdBox(v_data.xy, vec2(r)); + } else if (shape == 3) { + outer_df = sdPentagon(v_data.xy, 0.8); + inner_df = sdPentagon(v_data.xy, r * 0.8); + } else if (shape == 4) { + outer_df = sdHexagon(v_data.xy, 0.8); + inner_df = sdHexagon(v_data.xy, r * 0.8); + } else if (shape == 5) { + outer_df = sdOctogon(v_data.xy, 1.0); + inner_df = sdOctogon(v_data.xy, r); + } else if (shape == 6) { + outer_df = sdHexagram(v_data.xy, 0.52); + inner_df = sdHexagram(v_data.xy, r * 0.52); + } else if (shape == 7) { + outer_df = sdRhombus(v_data.xy, vec2(1.0)); + inner_df = sdRhombus(v_data.xy, vec2(r)); + } else if (shape == 8) { + outer_df = sdVesica(v_data.xy, 1.1, 0.8); + inner_df = sdVesica(v_data.xy, r * 1.1, r * 0.8); + } + + if(outer_df > antialiasblur + 0.018) discard; + + float opacity_t = smoothstep(0.0, antialiasblur, outer_df); + + float color_t = u_stroke_width < 0.01 ? 0.0 : smoothstep( + antialiasblur, + 0.0, + inner_df + ); + + if(u_stroke_width < 0.01) { + outputColor = vec4(v_color.rgb, v_color.a * u_opacity); + } else { + outputColor = mix(vec4(v_color.rgb, v_color.a * u_opacity), strokeColor * u_stroke_opacity, color_t); + } + + if(u_additive > 0.0) { + outputColor *= opacity_t; + outputColor = filterColorAlpha(outputColor, outputColor.a); + } else { + outputColor.a *= opacity_t; + outputColor = filterColor(outputColor); + } +} +`,iO=`layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in float a_Size; +layout(location = 10) in float a_Shape; +layout(location = 11) in vec3 a_Extrude; + +layout(std140) uniform commonUniform { + float u_additive; + float u_stroke_opacity : 1; + float u_stroke_width : 2; + float u_blur : 0.0; +}; +out vec4 v_data; +out vec4 v_color; +out float v_radius; + +#pragma include "projection" +#pragma include "picking" + + +void main() { + vec3 extrude = a_Extrude; + float shape_type = a_Shape; + /* + * setPickingSize \u8BBE\u7F6E\u62FE\u53D6\u5927\u5C0F + */ + float newSize = setPickingSize(a_Size); + // float newSize = setPickingSize(a_Size) * 0.00001038445708445579; + + // unpack color(vec2) + v_color = a_Color; + + // radius(16-bit) + v_radius = newSize; + + // anti-alias + // float antialiased_blur = -max(u_blur, antialiasblur); + float antialiasblur = -max(2.0 / u_DevicePixelRatio / newSize, u_blur); + + // TODP: /abs(extrude.x) \u662F\u4E3A\u4E86\u517C\u5BB9\u5730\u7403\u6A21\u5F0F + v_data = vec4(extrude.x/abs(extrude.x), extrude.y/abs(extrude.y), antialiasblur,shape_type); + + gl_Position = u_ViewProjectionMatrix * vec4(a_Position + extrude * newSize * 0.1 + vec3(u_offsets,0.0), 1.0); + + setPickingColor(a_PickingColor); +}`,oO=function(e){(0,Me.Z)(r,e);var i=tO(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.strokeOpacity,u=a===void 0?1:a,c=t.strokeWidth,m=c===void 0?0:c,E=t.blend,H=t.blur,re=H===void 0?0:H;this.layer.getLayerConfig();var xe={u_additive:E==="additive"?1:0,u_stroke_opacity:u,u_stroke_width:m,u_blur:re},ke=this.getUniformsBufferInfo(xe);return ke}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return this.initUniformsBuffer(),c.abrupt("return",this.buildModels());case 2:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u;return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return this.layer.triangulation=uS,m.next=3,this.layer.buildLayerModel({moduleName:"pointEarthFill",vertexShader:iO,fragmentShader:nO,triangulation:uS,inject:this.getInject(),depth:{enable:!0},blend:this.getBlend()});case 3:return u=m.sent,m.abrupt("return",[u]);case 5:case"end":return m.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"animateOption2Array",value:function(t){return[t.enable?0:1,t.speed||1,t.rings||3,0]}},{key:"registerBuiltinAttributes",value:function(){var t=this;this.styleAttributeService.registerStyleAttribute({name:"extrude",type:Vu.Attribute,descriptor:{name:"a_Extrude",shaderLocation:Gc.EXTRUDE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(u,c,m,E){var H=(0,gi.Z)(m,3),re=H[0],xe=H[1],ke=H[2],rt=Zd(0,0,1),vt=Zd(re,0,ke),It=re>=0?Zx(rt,vt):Math.PI*2-Zx(rt,vt),er=Math.PI*2-Math.asin(xe/100),Ar=Mf();Qd(Ar,Ar,It),Bd(Ar,Ar,er);var Or=Zd(1,1,0);Ky(Or,Or,Ar),gy(Or,Or);var rn=Zd(-1,1,0);Ky(rn,rn,Ar),gy(rn,rn);var Ln=Zd(-1,-1,0);Ky(Ln,Ln,Ar),gy(Ln,Ln);var wn=Zd(1,-1,0);Ky(wn,wn,Ar),gy(wn,wn);var Cn=[].concat((0,On.Z)(Or),(0,On.Z)(rn),(0,On.Z)(Ln),(0,On.Z)(wn)),qn=E%4*3;return[Cn[qn],Cn[qn+1],Cn[qn+2]]}}}),this.styleAttributeService.registerStyleAttribute({name:"size",type:Vu.Attribute,descriptor:{name:"a_Size",shaderLocation:Gc.SIZE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(u){var c=u.size,m=c===void 0?5:c;return Array.isArray(m)?[m[0]]:[m]}}}),this.styleAttributeService.registerStyleAttribute({name:"shape",type:Vu.Attribute,descriptor:{name:"a_Shape",shaderLocation:Gc.SHAPE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(u){var c=u.shape,m=c===void 0?2:c,E=t.layer.getLayerConfig().shape2d,H=E.indexOf(m);return[H]}}})}}]),r}(Kd);function aO(e){var i=sO();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function sO(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var uO=` +in vec4 v_color; +in float v_lightWeight; +out vec4 outputColor; + +layout(std140) uniform commonUniforms { + float u_pickLight; + float u_heightfixed; + float u_r; + float u_linearColor; + vec4 u_sourceColor; + vec4 u_targetColor; + float u_opacitylinear; + float u_opacitylinear_dir; + float u_lightEnable; +}; + +#pragma include "scene_uniforms" +#pragma include "picking" + +void main() { + + outputColor = v_color; + // \u5F00\u542F\u900F\u660E\u5EA6\u6E10\u53D8 + // picking + if(u_pickLight > 0.0) { + outputColor = filterColorAlpha(outputColor, v_lightWeight); + } else { + outputColor = filterColor(outputColor); + } +} +`,lO=`#define pi 3.1415926535 + +layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in vec3 a_Size; +layout(location = 11) in vec3 a_Extrude; +layout(location = 13) in vec3 a_Normal; + +layout(std140) uniform commonUniforms { + float u_pickLight; + float u_heightfixed; + float u_r; + float u_linearColor; + vec4 u_sourceColor; + vec4 u_targetColor; + float u_opacitylinear; + float u_opacitylinear_dir; + float u_lightEnable; +}; +out vec4 v_color; +out float v_lightWeight; + +#pragma include "projection" +#pragma include "light" +#pragma include "picking" + +float getYRadian(float x, float z) { + if(x > 0.0 && z > 0.0) { + return atan(x/z); + } else if(x > 0.0 && z <= 0.0){ + return atan(-z/x) + pi/2.0; + } else if(x <= 0.0 && z <= 0.0) { + return pi + atan(x/z); //atan(x/z) + + } else { + return atan(z/-x) + pi*3.0/2.0; + } +} + +float getXRadian(float y, float r) { + return atan(y/r); +} + +void main() { + + + vec3 size = a_Size * a_Position; + + vec3 offset = size; // \u63A7\u5236\u5706\u67F1\u4F53\u7684\u5927\u5C0F - \u4ECE\u6807\u51C6\u5355\u4F4D\u5706\u67F1\u4F53\u8FDB\u884C\u504F\u79FB + + if(u_heightfixed < 1.0) { // \u5706\u67F1\u4F53\u4E0D\u56FA\u5B9A\u9AD8\u5EA6 + + if (u_CoordinateSystem == COORDINATE_SYSTEM_P20 || u_CoordinateSystem == COORDINATE_SYSTEM_P20_OFFSET) { + // P20 \u5750\u6807\u7CFB\u4E0B\uFF0C\u4E3A\u4E86\u548C Web \u58A8\u5361\u6258\u5750\u6807\u7CFB\u7EDF\u4E00\uFF0Czoom \u9ED8\u8BA4\u51CF1 + offset = offset * pow(2.0, (19.0 - u_Zoom)); + } + if(u_CoordinateSystem == COORDINATE_SYSTEM_P20_2) { + // P20_2 \u5750\u6807\u7CFB\u4E0B\uFF0C\u4E3A\u4E86\u548C Web \u58A8\u5361\u6258\u5750\u6807\u7CFB\u7EDF\u4E00\uFF0Czoom \u9ED8\u8BA4\u51CF3 + offset = offset * pow(2.0, (19.0 - 3.0 - u_Zoom)); + } + } else {// \u5706\u67F1\u4F53\u56FA\u5B9A\u9AD8\u5EA6 \uFF08 \u5904\u7406 mapbox \uFF09 + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + offset *= 4.0/pow(2.0, 21.0 - u_Zoom); + } + } + + + vec4 project_pos = project_position(vec4(a_Extrude.xy, 0., 1.0)); + + // u_r \u63A7\u5236\u5706\u67F1\u7684\u751F\u957F + vec4 pos = vec4(project_pos.xy + offset.xy, offset.z * u_r, 1.0); + + // // \u5706\u67F1\u5149\u7167\u6548\u679C + float lightWeight = 1.0; + + if(u_lightEnable > 0.0) { // \u53D6\u6D88\u4E09\u5143\u8868\u8FBE\u5F0F\uFF0C\u589E\u5F3A\u5065\u58EE\u6027 + lightWeight = calc_lighting(pos); + } + + v_lightWeight = lightWeight; + + v_color = a_Color; + + // \u8BBE\u7F6E\u5706\u67F1\u7684\u5E95\u8272 + if(u_linearColor == 1.0) { // \u4F7F\u7528\u6E10\u53D8\u989C\u8272 + v_color = mix(u_sourceColor, u_targetColor, a_Position.z); + v_color.a = v_color.a * opacity; + } else { + v_color = vec4(a_Color.rgb * lightWeight, a_Color.w * opacity); + } + + if(u_opacitylinear > 0.0) { + v_color.a *= u_opacitylinear_dir > 0.0 ? (1.0 - a_Position.z): a_Position.z; + } + + + gl_Position = project_common_position_to_clipspace_v2(pos); + + setPickingColor(a_PickingColor); +} +`,wS=function(e){(0,Me.Z)(r,e);var i=aO(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u0&&u.enable){var rn=u.speed,Ln=rn===void 0?.01:rn;this.raiseCount+=Ln,this.raiseCount>=1&&(this.raiseRepeat>1?(this.raiseCount=0,this.raiseRepeat--):this.raiseCount=1)}var wn={u_pickLight:Number(H),u_heightfixed:Number(xe),u_r:u.enable&&this.raiseRepeat>0?this.raiseCount:1,u_linearColor:er,u_sourceColor:Ar,u_targetColor:Or,u_opacitylinear:Number(rt.enable),u_opacitylinear_dir:rt.dir==="up"?1:0,u_lightEnable:Number(It)},Cn=this.getUniformsBufferInfo(wn);return Cn}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.abrupt("return",this.buildModels());case 1:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E,H,re;return Ur().wrap(function(ke){for(;;)switch(ke.prev=ke.next){case 0:return u=this.layer.getLayerConfig(),c=u.depth,m=c===void 0?!0:c,E=u.animateOption.repeat,H=E===void 0?1:E,this.raiseRepeat=H,this.initUniformsBuffer(),ke.next=5,this.layer.buildLayerModel({moduleName:"pointExtrude",vertexShader:lO,fragmentShader:uO,triangulation:Hx,inject:this.getInject(),cull:{enable:!0,face:Xi(this.mapService.version)},depth:{enable:m}});case 5:return re=ke.sent,ke.abrupt("return",[re]);case 7:case"end":return ke.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"registerBuiltinAttributes",value:function(){this.styleAttributeService.registerStyleAttribute({name:"size",type:Vu.Attribute,descriptor:{name:"a_Size",shaderLocation:Gc.SIZE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(a){var u=a.size;if(u){var c=[];return Array.isArray(u)&&(c=u.length===2?[u[0],u[0],u[1]]:u),Array.isArray(u)||(c=[u,u,u]),c}else return[2,2,2]}}}),this.styleAttributeService.registerStyleAttribute({name:"normal",type:Vu.Attribute,descriptor:{name:"a_Normal",shaderLocation:Gc.NORMAL,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(a,u,c,m,E){return E}}}),this.styleAttributeService.registerStyleAttribute({name:"extrude",type:Vu.Attribute,descriptor:{name:"a_Extrude",shaderLocation:Gc.EXTRUDE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(a){var u=wl(a.coordinates);return[u[0],u[1],0]}}})}}]),r}(Kd);function cO(e){var i=fO();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function fO(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var hO=` +layout(std140) uniform commonUniforms { + vec3 u_blur_height_fixed; + float u_stroke_width; + float u_additive; + float u_stroke_opacity; + float u_size_unit; + float u_time; + vec4 u_animate; +}; + +in vec4 v_color; +in vec4 v_stroke; +in vec4 v_data; +in float v_radius; + +#pragma include "scene_uniforms" +#pragma include "sdf_2d" +#pragma include "picking" + +out vec4 outputColor; + +void main() { + int shape = int(floor(v_data.w + 0.5)); + lowp float antialiasblur = v_data.z; + float r = v_radius / (v_radius + u_stroke_width); + + float outer_df; + float inner_df; + // 'circle', 'triangle', 'square', 'pentagon', 'hexagon', 'octogon', 'hexagram', 'rhombus', 'vesica' + if (shape == 0) { + outer_df = sdCircle(v_data.xy, 1.0); + inner_df = sdCircle(v_data.xy, r); + } else if (shape == 1) { + outer_df = sdEquilateralTriangle(1.1 * v_data.xy); + inner_df = sdEquilateralTriangle(1.1 / r * v_data.xy); + } else if (shape == 2) { + outer_df = sdBox(v_data.xy, vec2(1.)); + inner_df = sdBox(v_data.xy, vec2(r)); + } else if (shape == 3) { + outer_df = sdPentagon(v_data.xy, 0.8); + inner_df = sdPentagon(v_data.xy, r * 0.8); + } else if (shape == 4) { + outer_df = sdHexagon(v_data.xy, 0.8); + inner_df = sdHexagon(v_data.xy, r * 0.8); + } else if (shape == 5) { + outer_df = sdOctogon(v_data.xy, 1.0); + inner_df = sdOctogon(v_data.xy, r); + } else if (shape == 6) { + outer_df = sdHexagram(v_data.xy, 0.52); + inner_df = sdHexagram(v_data.xy, r * 0.52); + } else if (shape == 7) { + outer_df = sdRhombus(v_data.xy, vec2(1.0)); + inner_df = sdRhombus(v_data.xy, vec2(r)); + } else if (shape == 8) { + outer_df = sdVesica(v_data.xy, 1.1, 0.8); + inner_df = sdVesica(v_data.xy, r * 1.1, r * 0.8); + } + + float opacity_t = smoothstep(0.0, antialiasblur, outer_df); + + float color_t = u_stroke_width < 0.01 ? 0.0 : smoothstep( + antialiasblur, + 0.0, + inner_df + ); + + float PI = 3.14159; + float N_RINGS = 3.0; + float FREQ = 1.0; + + if(u_stroke_width < 0.01) { + outputColor = v_color; + } else { + outputColor = mix(v_color, v_stroke * u_stroke_opacity, color_t); + } + float intensity = 1.0; + if(u_time!=-1.0){ + //wave\u76F8\u5173\u903B\u8F91 + float d = length(v_data.xy); + if(d > 0.5) { + discard; + } + intensity = clamp(cos(d * PI), 0.0, 1.0) * clamp(cos(2.0 * PI * (d * 2.0 * u_animate.z - u_animate.y * u_time)), 0.0, 1.0); + } + + if(u_additive > 0.0) { + outputColor *= opacity_t; + outputColor *= intensity;//wave + outputColor = filterColorAlpha(outputColor, outputColor.a); + } else { + outputColor.a *= opacity_t; + outputColor.a *= intensity;//wave + outputColor = filterColor(outputColor); + } + // \u4F5C\u4E3A mask \u6A21\u677F\u65F6\u9700\u8981\u4E22\u5F03\u900F\u660E\u7684\u50CF\u7D20 + if(outputColor.a < 0.01) { + discard; + } +} +`,dO=`layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in float a_Size; +layout(location = 10) in float a_Shape; +layout(location = 11) in vec3 a_Extrude; + +layout(std140) uniform commonUniforms { + vec3 u_blur_height_fixed; + float u_stroke_width; + float u_additive; + float u_stroke_opacity; + float u_size_unit; + float u_time; + vec4 u_animate; +}; + +out vec4 v_color; +out vec4 v_stroke; +out vec4 v_data; +out float v_radius; + +#pragma include "projection" +#pragma include "picking" +#pragma include "rotation_2d" + +void main() { + // \u900F\u660E\u5EA6\u8BA1\u7B97 + v_stroke = stroke; + vec3 extrude = a_Extrude; + float shape_type = a_Shape; + /* + * setPickingSize \u8BBE\u7F6E\u62FE\u53D6\u5927\u5C0F + * u_meter2coord \u5728\u7B49\u9762\u79EF\u5927\u5C0F\u7684\u65F6\u5019\u8BBE\u7F6E\u5355\u4F4D + */ + float newSize = setPickingSize(a_Size); + // float newSize = setPickingSize(a_Size) * 0.00001038445708445579; + + + + // unpack color(vec2) + v_color = vec4(a_Color.xyz, a_Color.w * opacity); + + if(u_size_unit == 1.0) { + newSize = newSize * u_PixelsPerMeter.z; + } + + v_radius = newSize; + + // anti-alias + // float antialiased_blur = -max(u_blur, antialiasblur); + float antialiasblur = -max(2.0 / u_DevicePixelRatio / newSize, u_blur_height_fixed.x); + + vec2 offset = (extrude.xy * (newSize + u_stroke_width) + u_offsets); + vec3 aPosition = a_Position; + + offset = project_pixel(offset); + offset = rotate_matrix(offset,rotation); + + // TODP: /abs(extrude.x) \u662F\u4E3A\u4E86\u517C\u5BB9\u5730\u7403\u6A21\u5F0F + v_data = vec4(extrude.x/abs(extrude.x), extrude.y/abs(extrude.y), antialiasblur,shape_type); + + + // vec4 project_pos = project_position(vec4(a_Position.xy, 0.0, 1.0)); + vec4 project_pos = project_position(vec4(aPosition.xy, 0.0, 1.0)); + // gl_Position = project_common_position_to_clipspace(vec4(project_pos.xy + offset, project_pixel(setPickingOrder(0.0)), 1.0)); + + float raisingHeight = u_blur_height_fixed.y; + + if(u_blur_height_fixed.z < 1.0) { // false + raisingHeight = project_pixel(u_blur_height_fixed.y); + } else { + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + float mapboxZoomScale = 4.0/pow(2.0, 21.0 - u_Zoom); + raisingHeight = u_blur_height_fixed.y * mapboxZoomScale; + } + } + + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xy + offset, raisingHeight, 1.0)); + + setPickingColor(a_PickingColor); +} +`,ES=function(e){(0,Me.Z)(r,e);var i=cO(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.strokeOpacity,u=a===void 0?1:a,c=t.strokeWidth,m=c===void 0?0:c,E=t.blend,H=t.blur,re=H===void 0?0:H,xe=t.raisingHeight,ke=xe===void 0?0:xe,rt=t.heightfixed,vt=rt===void 0?!1:rt,It=t.unit,er=It===void 0?"pixel":It,Ar=this.getAnimateUniforms().u_time;isNaN(Ar)&&(Ar=-1);var Or={u_blur_height_fixed:[re,Number(ke),Number(vt)],u_stroke_width:m,u_additive:E==="additive"?1:0,u_stroke_opacity:u,u_size_unit:fb[er],u_time:Ar,u_animate:this.getAnimateUniforms().u_animate},rn=this.getUniformsBufferInfo(Or);return rn}},{key:"getAnimateUniforms",value:function(){var t=this.layer.getLayerConfig(),a=t.animateOption,u=a===void 0?{enable:!1}:a;return{u_animate:this.animateOption2Array(u),u_time:this.layer.getLayerAnimateTime()}}},{key:"getAttribute",value:function(){return this.styleAttributeService.createAttributesAndIndices(this.layer.getEncodedData(),Np)}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.abrupt("return",this.buildModels());case 1:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E,H,re,xe,ke;return Ur().wrap(function(vt){for(;;)switch(vt.prev=vt.next){case 0:return u=this.layer.getLayerConfig(),c=u.animateOption,m=c===void 0?{enable:!1}:c,E=this.getShaders(m),H=E.frag,re=E.vert,xe=E.type,this.layer.triangulation=Np,this.initUniformsBuffer(),vt.next=6,this.layer.buildLayerModel({moduleName:xe,vertexShader:re,fragmentShader:H,inject:this.getInject(),triangulation:Np,depth:{enable:!1}});case 6:return ke=vt.sent,vt.abrupt("return",[ke]);case 8:case"end":return vt.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"getShaders",value:function(t){return{frag:hO,vert:dO,type:"pointFill"}}},{key:"animateOption2Array",value:function(t){return[t.enable?0:1,t.speed||1,t.rings||3,0]}},{key:"registerBuiltinAttributes",value:function(){var t=this.layer.getLayerConfig().shape2d;this.styleAttributeService.registerStyleAttribute({name:"extrude",type:Vu.Attribute,descriptor:{name:"a_Extrude",shaderLocation:Gc.EXTRUDE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(u,c,m,E){var H=[1,1,0,-1,1,0,-1,-1,0,1,-1,0],re=E%4*3;return[H[re],H[re+1],H[re+2]]}}}),this.styleAttributeService.registerStyleAttribute({name:"size",type:Vu.Attribute,descriptor:{name:"a_Size",shaderLocation:Gc.SIZE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(u){var c=u.size,m=c===void 0?5:c;return Array.isArray(m)?[m[0]]:[m]}}}),this.styleAttributeService.registerStyleAttribute({name:"shape",type:Vu.Attribute,descriptor:{name:"a_Shape",shaderLocation:Gc.SHAPE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(u){var c=u.shape,m=c===void 0?2:c,E=t.indexOf(m);return[E]}}})}}]),r}(Kd);function pO(e){var i=mO();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function mO(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var vO=`in vec2 v_uv;// \u672C\u8EAB\u7684 uv \u5750\u6807 +in vec2 v_Iconuv; +in float v_opacity; +out vec4 outputColor; + +uniform sampler2D u_texture; +layout(std140) uniform commonUniform { + vec2 u_textSize; + float u_heightfixed: 0.0; + float u_raisingHeight: 0.0; + float u_size_unit; +}; + +#pragma include "scene_uniforms" +#pragma include "sdf_2d" +#pragma include "picking" + +void main() { + vec2 pos = v_Iconuv / u_textSize + v_uv / u_textSize * 64.; + outputColor = texture(SAMPLER_2D(u_texture), pos); + outputColor.a *= v_opacity; + outputColor = filterColor(outputColor); +} +`,gO=`layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in float a_Size; +layout(location = 11) in vec3 a_Extrude; +layout(location = 14) in vec2 a_Uv; + +layout(std140) uniform commonUniform { + vec2 u_textSize; + float u_heightfixed: 0.0; + float u_raisingHeight: 0.0; + float u_size_unit; +}; + +out vec2 v_uv; +out vec2 v_Iconuv; +out float v_opacity; + + +#pragma include "projection" +#pragma include "picking" +#pragma include "rotation_2d" + +void main() { + vec3 extrude = a_Extrude; + v_uv = (a_Extrude.xy + 1.0)/2.0; + v_uv.y = 1.0 - v_uv.y; + v_Iconuv = a_Uv; + v_opacity = opacity; + float newSize = a_Size; + if(u_size_unit == 1.0) { + newSize = newSize * u_PixelsPerMeter.z; + } + + // vec2 offset = (u_RotateMatrix * extrude.xy * (a_Size) + textrueOffsets); + vec2 offset = (extrude.xy * (newSize) + offsets); + + offset = rotate_matrix(offset,rotation); + + vec3 aPosition = a_Position; + + offset = project_pixel(offset); + + vec4 project_pos = project_position(vec4(aPosition.xy, 0.0, 1.0)); + float raisingHeight = u_raisingHeight; + if(u_heightfixed < 1.0) { // height fixed + raisingHeight = project_pixel(u_raisingHeight); + } else { + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + float mapboxZoomScale = 4.0/pow(2.0, 21.0 - u_Zoom); + raisingHeight = u_raisingHeight * mapboxZoomScale; + } + } + + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xy + offset, 0.0, 1.0)); + + setPickingColor(a_PickingColor); +} +`,yO=function(e){(0,Me.Z)(r,e);var i=pO(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u= 0.5) { + float luma = 0.299 * textureColor.r + 0.587 * textureColor.g + 0.114 * textureColor.b; + textureColor.a *= luma; + } + + if(all(lessThan(v_color, vec4(1.0+0.00001))) && all(greaterThan(v_color, vec4(1.0-0.00001))) || v_color==vec4(1.0)){ + outputColor= textureColor; + }else { + outputColor= step(0.01, textureColor.z) * v_color; + } + outputColor.a *= v_opacity; + if (outputColor.a < 0.01) { + discard; + } + outputColor = filterColor(outputColor); +} +`,xO=`layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in float a_Size; +layout(location = 14) in vec2 a_Uv; + +layout(std140) uniform commonUniforms { + vec2 u_textSize; + float u_raisingHeight; + float u_heightfixed; +}; + +out vec4 v_color; +out vec2 v_uv; +out float v_opacity; + +#pragma include "projection" +#pragma include "picking" + +void main() { + + // cal style mapping - \u6570\u636E\u7EB9\u7406\u6620\u5C04\u90E8\u5206\u7684\u8BA1\u7B97 + v_color = a_Color; + v_opacity = opacity; + v_uv = a_Uv; + vec4 project_pos = project_position(vec4(a_Position, 1.0)); + + vec2 offset = project_pixel(offsets); + + float raisingHeight = u_raisingHeight; + if(u_heightfixed < 1.0) { // false + raisingHeight = project_pixel(u_raisingHeight); + } else { + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + float mapboxZoomScale = 4.0/pow(2.0, 21.0 - u_Zoom); + raisingHeight = u_raisingHeight * mapboxZoomScale; + } + } + + + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xy + offset, raisingHeight, 1.0)); + + gl_PointSize = a_Size * 2.0 * u_DevicePixelRatio; + setPickingColor(a_PickingColor); +} +`,SS=function(e){(0,Me.Z)(r,e);var i=_O(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u 0.0) { + outputColor *= opacity_t; + } else { + outputColor.a *= opacity_t; + } + + if(outputColor.a > 0.0) { + outputColor = filterColor(outputColor); + } + + vec2 extrude = v_extrude; + vec2 dir = normalize(extrude); + vec2 baseDir = vec2(1.0, 0.0); + float pi = 3.14159265359; + float flag = sign(dir.y); + float rades = dot(dir, baseDir); + float radar_v = (flag - 1.0) * -0.5 * acos(rades)/pi; + // simple AA + if(radar_v > 0.99) { + radar_v = 1.0 - (radar_v - 0.99)/0.01; + } + + outputColor.a *= radar_v; +} +`,IO=`layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in float a_Size; +layout(location = 11) in vec3 a_Extrude; + +layout(std140) uniform commonUniorm { + float u_additive; + float u_size_unit; + float u_speed: 1.0; + float u_time; +}; + +out vec4 v_data; +out vec4 v_color; +out float v_radius; +out vec2 v_extrude; + +#pragma include "projection" +#pragma include "picking" + +void main() { + float newSize = setPickingSize(a_Size); + + float time = u_time * u_speed; + mat2 rotateMatrix = mat2( + cos(time), sin(time), + -sin(time), cos(time) + ); + v_extrude = rotateMatrix * a_Extrude.xy; + + v_color = a_Color; + v_color.a *= opacity; + + float blur = 0.0; + float antialiasblur = -max(2.0 / u_DevicePixelRatio / a_Size, blur); + + if(u_size_unit == 1.) { + newSize = newSize * u_PixelsPerMeter.z; + } + v_radius = newSize; + + vec2 offset = (a_Extrude.xy * (newSize)); + vec3 aPosition = a_Position; + + offset = project_pixel(offset); + + v_data = vec4(a_Extrude.x, a_Extrude.y, antialiasblur, -1.0); + + vec4 project_pos = project_position(vec4(aPosition.xy, 0.0, 1.0)); + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xy + offset, project_pixel(setPickingOrder(0.0)), 1.0)); + + setPickingColor(a_PickingColor); +} +`,RO=function(e){(0,Me.Z)(r,e);var i=TO(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.blend,u=t.speed,c=u===void 0?1:u,m=t.unit,E=m===void 0?"pixel":m,H={u_additive:a==="additive"?1:0,u_size_unit:fb[E],u_speed:c,u_time:this.layer.getLayerAnimateTime()},re=this.getUniformsBufferInfo(H);return re}},{key:"getAnimateUniforms",value:function(){return{}}},{key:"getAttribute",value:function(){return this.styleAttributeService.createAttributesAndIndices(this.layer.getEncodedData(),vb)}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.abrupt("return",this.buildModels());case 1:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u;return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return this.initUniformsBuffer(),m.next=3,this.layer.buildLayerModel({moduleName:"pointRadar",vertexShader:IO,fragmentShader:PO,triangulation:vb,inject:this.getInject(),depth:{enable:!1}});case 3:return u=m.sent,m.abrupt("return",[u]);case 5:case"end":return m.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"animateOption2Array",value:function(t){return[t.enable?0:1,t.speed||1,t.rings||3,0]}},{key:"registerBuiltinAttributes",value:function(){this.styleAttributeService.registerStyleAttribute({name:"extrude",type:Vu.Attribute,descriptor:{name:"a_Extrude",shaderLocation:Gc.EXTRUDE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(a,u,c,m){var E=[1,1,0,-1,1,0,-1,-1,0,1,-1,0],H=m%4*3;return[E[H],E[H+1],E[H+2]]}}}),this.styleAttributeService.registerStyleAttribute({name:"size",type:Vu.Attribute,descriptor:{shaderLocation:Gc.SIZE,name:"a_Size",buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(a){var u=a.size,c=u===void 0?5:u;return Array.isArray(c)?[c[0]]:[c]}}})}}]),r}(Kd);function OO(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=LO(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function LO(e,i){if(e){if(typeof e=="string")return PS(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return PS(e,i)}}function PS(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);rthis.width||a<0||n>this.height)return u?!1:[];var m=[];if(r<=0&&n<=0&&this.width<=t&&this.height<=a){if(u)return!0;for(var E=0;E0:m}},{key:"queryCell",value:function(r,n,t,a,u,c,m,E){var H=m.seenUids,re=this.boxCells[u];if(re!==null){var xe=this.bboxes,ke=OO(re),rt;try{for(ke.s();!(rt=ke.n()).done;){var vt=rt.value;if(!H.box[vt]){H.box[vt]=!0;var It=vt*4;if(r<=xe[It+2]&&n<=xe[It+3]&&t>=xe[It+0]&&a>=xe[It+1]&&(!E||E(this.boxKeys[vt]))){if(m.hitTest)return c.push(!0),!0;c.push({key:this.boxKeys[vt],x1:xe[It],y1:xe[It+1],x2:xe[It+2],y2:xe[It+3]})}}}}catch(er){ke.e(er)}finally{ke.f()}}return!1}},{key:"forEachCell",value:function(r,n,t,a,u,c,m,E){for(var H=this.convertToXCellCoord(r),re=this.convertToYCellCoord(n),xe=this.convertToXCellCoord(t),ke=this.convertToYCellCoord(a),rt=H;rt<=xe;rt++)for(var vt=re;vt<=ke;vt++){var It=this.xCellCount*vt+rt;if(u.call(this,r,n,t,a,It,c,m,E))return}}},{key:"convertToXCellCoord",value:function(r){return Math.max(0,Math.min(this.xCellCount-1,Math.floor(r*this.xScale)))}},{key:"convertToYCellCoord",value:function(r){return Math.max(0,Math.min(this.yCellCount-1,Math.floor(r*this.yScale)))}}]),e}(),kO=DO,FO=function(){function e(i,r){(0,We.Z)(this,e),(0,St.Z)(this,"viewportPadding",100),this.width=i,this.height=r,this.viewportPadding=Math.max(i,r),this.grid=new kO(i+this.viewportPadding,r+this.viewportPadding,25),this.screenRightBoundary=i+this.viewportPadding,this.screenBottomBoundary=r+this.viewportPadding,this.gridRightBoundary=i+2*this.viewportPadding,this.gridBottomBoundary=r+2*this.viewportPadding}return(0,ot.Z)(e,[{key:"placeCollisionBox",value:function(r){var n=r.x1+r.anchorPointX+this.viewportPadding,t=r.y1+r.anchorPointY+this.viewportPadding,a=r.x2+r.anchorPointX+this.viewportPadding,u=r.y2+r.anchorPointY+this.viewportPadding;return!this.isInsideGrid(n,t,a,u)||this.grid.hitTest(n,t,a,u)?{box:[]}:{box:[n,t,a,u]}}},{key:"insertCollisionBox",value:function(r,n){var t={featureIndex:n};this.grid.insert(t,r[0],r[1],r[2],r[3])}},{key:"project",value:function(r,n,t){var a=de(n,t,0,1),u=C(),c=xm.apply(y,(0,On.Z)(r));return Ua(u,a,c),{x:(u[0]/u[3]+1)/2*this.width+this.viewportPadding,y:(-u[1]/u[3]+1)/2*this.height+this.viewportPadding}}},{key:"isInsideGrid",value:function(r,n,t,a){return t>=0&&r=0&&n=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function BO(e,i){if(e){if(typeof e=="string")return RS(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return RS(e,i)}}function RS(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r6&&arguments[6]!==void 0?arguments[6]:[0,0],c=arguments.length>7?arguments[7]:void 0,m=e.split(` +`),E=[],H={positionedGlyphs:E,top:u[1],bottom:u[1],left:u[0],right:u[0],lineCount:m.length,text:e};return c?zO(H,i,m,r,n,t,a):NO(H,i,m,r,n,t,a),E.length?H:!1}function UO(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[0,0],r=arguments.length>2?arguments[2]:void 0,n=e.positionedGlyphs,t=n===void 0?[]:n,a=[],u=IS(t),c;try{for(u.s();!(c=u.n()).done;){var m=c.value,E=m.metrics,H=4,re=E.advance*m.scale/2,xe=r?[m.x+re,m.y]:[0,0],ke=r?[0,0]:[m.x+re+i[0],m.y+i[1]],rt=(0-H)*m.scale-re+ke[0],vt=(0-H)*m.scale+ke[1],It=rt+E.width*m.scale,er=vt+E.height*m.scale,Ar={x:rt,y:vt},Or={x:It,y:vt},rn={x:rt,y:er},Ln={x:It,y:er};a.push({tl:Ar,tr:Or,bl:rn,br:Ln,tex:E,glyphOffset:xe})}}catch(wn){u.e(wn)}finally{u.f()}return a}function jO(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=VO(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function VO(e,i){if(e){if(typeof e=="string")return kS(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return kS(e,i)}}function kS(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r.5||!er||m!==this.preTextStyle.textAllowOverlap)){Or.next=14;break}return Or.next=13,this.reBuildModel();case 13:return Or.abrupt("return",!0);case 14:return Or.abrupt("return",!1);case 15:case"end":return Or.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"clearModels",value:function(){var t;(t=this.texture)===null||t===void 0||t.destroy(),this.layer.off("remapping",this.mapping)}},{key:"registerBuiltinAttributes",value:function(){this.styleAttributeService.registerStyleAttribute({name:"textOffsets",type:Vu.Attribute,descriptor:{shaderLocation:10,name:"a_textOffsets",buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:2,update:function(a,u,c){return[c[5],c[6]]}}}),this.styleAttributeService.registerStyleAttribute({name:"textUv",type:Vu.Attribute,descriptor:{name:"a_tex",shaderLocation:Gc.UV,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:2,update:function(a,u,c){return[c[3],c[4]]}}}),this.styleAttributeService.registerStyleAttribute({name:"size",type:Vu.Attribute,descriptor:{name:"a_Size",shaderLocation:Gc.SIZE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(a){var u=a.size,c=u===void 0?12:u;return Array.isArray(c)?[c[0]]:[c]}}})}},{key:"bindEvent",value:function(){this.layer.isTileLayer||this.layer.on("remapping",this.mapping)}},{key:"textExtent",value:function(){var t=this.mapService.getBounds();return to(t,.5)}},{key:"initTextFont",value:function(){var t=this.getTextStyle(),a=t.fontWeight,u=t.fontFamily,c=this.rawEncodeData,m=[];c.forEach(function(E){var H=E.shape,re=H===void 0?"":H;re=re.toString();var xe=jO(re),ke;try{for(xe.s();!(ke=xe.n()).done;){var rt=ke.value;m.indexOf(rt)===-1&&m.push(rt)}}catch(vt){xe.e(vt)}finally{xe.f()}}),this.fontService.setFontOptions({characterSet:m,fontWeight:a,fontFamily:u,iconfont:!1})}},{key:"initIconFontTex",value:function(){var t=this.getTextStyle(),a=t.fontWeight,u=t.fontFamily,c=this.rawEncodeData,m=[];c.forEach(function(E){var H=E.shape,re=H===void 0?"":H;re="".concat(re),m.indexOf(re)===-1&&m.push(re)}),this.fontService.setFontOptions({characterSet:m,fontWeight:a,fontFamily:u,iconfont:!0})}},{key:"getTextStyle",value:function(){var t=this.layer.getLayerConfig(),a=t.fontWeight,u=a===void 0?"400":a,c=t.fontFamily,m=c===void 0?"sans-serif":c,E=t.textAllowOverlap,H=E===void 0?!1:E,re=t.padding,xe=re===void 0?[0,0]:re,ke=t.textAnchor,rt=ke===void 0?"center":ke,vt=t.textOffset,It=vt===void 0?[0,0]:vt,er=t.opacity,Ar=er===void 0?1:er,Or=t.strokeOpacity,rn=Or===void 0?1:Or,Ln=t.strokeWidth,wn=Ln===void 0?0:Ln,Cn=t.stroke,qn=Cn===void 0?"#000":Cn;return{fontWeight:u,fontFamily:m,textAllowOverlap:H,padding:xe,textAnchor:rt,textOffset:It,opacity:Ar,strokeOpacity:rn,strokeWidth:wn,stroke:qn}}},{key:"generateGlyphLayout",value:function(t){var a=this,u=this.getFontServiceMapping(),c=this.layer.getLayerConfig(),m=c.spacing,E=m===void 0?2:m,H=c.textAnchor,re=H===void 0?"center":H,xe=c.textOffset,ke=this.rawEncodeData;this.glyphInfo=ke.map(function(rt){var vt=rt.shape,It=vt===void 0?"":vt,er=rt.id,Ar=rt.size,Or=Ar===void 0?1:Ar,rn=rt.textOffset?rt.textOffset:xe||[0,0],Ln=rt.textAnchor?rt.textAnchor:re||"center",wn=ZO(It.toString(),u,Or,Ln,"left",E,rn,t),Cn=UO(wn,rn,!1);return rt.shaping=wn,rt.glyphQuads=Cn,rt.centroid=wl(rt.coordinates),rt.originCentroid=rt.version==="GAODE2.x"?wl(rt.originCoordinates):rt.originCentroid=rt.centroid,a.glyphInfoMap[er]={shaping:wn,glyphQuads:Cn,centroid:wl(rt.coordinates)},rt})}},{key:"getFontServiceMapping",value:function(){var t=this.layer.getLayerConfig(),a=t.fontWeight,u=a===void 0?"400":a,c=t.fontFamily,m=c===void 0?"sans-serif":c;return this.fontService.getMappingByKey("".concat(m,"_").concat(u))}},{key:"getFontServiceCanvas",value:function(){var t=this.layer.getLayerConfig(),a=t.fontWeight,u=a===void 0?"400":a,c=t.fontFamily,m=c===void 0?"sans-serif":c;return this.fontService.getCanvasByKey("".concat(m,"_").concat(u))}},{key:"filterGlyphs",value:function(){var t=this,a=this.layer.getLayerConfig(),u=a.padding,c=u===void 0?[0,0]:u,m=a.textAllowOverlap,E=m===void 0?!1:m;if(!E){this.glyphInfoMap={},this.currentZoom=this.mapService.getZoom(),this.extent=this.textExtent();var H=this.rendererService.getViewportSize(),re=H.width,xe=H.height,ke=new FO(re,xe),rt=this.glyphInfo.filter(function(vt){var It=vt.shaping,er=vt.id,Ar=er===void 0?0:er,Or=vt.version==="GAODE2.x"?vt.originCentroid:vt.centroid,rn=vt.size,Ln=rn/16,wn=t.mapService.lngLatToContainer(Or),Cn=ke.placeCollisionBox({x1:It.left*Ln-c[0],x2:It.right*Ln+c[0],y1:It.top*Ln-c[1],y2:It.bottom*Ln+c[1],anchorPointX:wn.x,anchorPointY:wn.y}),qn=Cn.box;return qn&&qn.length?(ke.insertCollisionBox(qn,Ar),!0):!1});rt.forEach(function(vt){t.glyphInfoMap[vt.id]=vt})}}},{key:"initGlyph",value:function(){var t=this.layer.getLayerConfig(),a=t.iconfont,u=a===void 0?!1:a;u?this.initIconFontTex():this.initTextFont(),this.generateGlyphLayout(u)}},{key:"updateTexture",value:function(){var t=this.rendererService.createTexture2D,a=this.getFontServiceCanvas();this.textureHeight=a.height,this.texture&&this.texture.destroy(),this.texture=t({data:a,mag:Er.LINEAR,min:Er.LINEAR,width:a.width,height:a.height}),this.textures=[this.texture]}},{key:"reBuildModel",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u;return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return this.filterGlyphs(),m.next=3,this.layer.buildLayerModel({moduleName:"pointText",vertexShader:BS,fragmentShader:FS,triangulation:NS.bind(this),inject:this.getInject(),depth:{enable:!1}});case 3:u=m.sent,this.layer.models=[u];case 5:case"end":return m.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()}]),r}(Kd),GO={fillImage:yO,fill:ES,radar:RO,image:SS,normal:TS,simplePoint:X6,extrude:wS,text:zS,earthFill:oO,earthExtrude:eO},WO=GO;function XO(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=YO(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function YO(e,i){if(e){if(typeof e=="string")return ZS(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return ZS(e,i)}}function ZS(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r 0.0) { // \u5224\u65AD\u51E0\u4F55\u4F53\u662F\u5426\u56FA\u5B9A\u9AD8\u5EA6 + project_pos.z = a_Position.z * a_Size; + project_pos.z += u_raisingHeight; + + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + float mapboxZoomScale = 4.0/pow(2.0, 21.0 - u_Zoom); + project_pos.z *= mapboxZoomScale; + project_pos.z += u_raisingHeight * mapboxZoomScale; + } + } + + + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xyz, 1.0)); + + // Tip: \u90E8\u5206\u673A\u578B GPU \u8BA1\u7B97\u7CBE\u5EA6\u517C\u5BB9 + if(isSide < 0.999) { + // side face + // if(u_sidesurface < 1.0) { + // discard; + // } + + if(u_linearColor == 1.0) { + vec4 linearColor = mix(u_targetColor, u_sourceColor, sidey); + linearColor.rgb *= lightWeight; + v_Color = linearColor; + } else { + v_Color = a_Color; + } + + } else { + v_Color = a_Color; + } + + v_Color = vec4(v_Color.rgb * lightWeight, v_Color.w * opacity); + + + setPickingColor(a_PickingColor); +} +`,nL=`uniform sampler2D u_texture; + +layout(std140) uniform commonUniforms { + vec4 u_sourceColor; + vec4 u_targetColor; + float u_linearColor; + float u_topsurface; + float u_sidesurface; + float u_heightfixed; // \u9ED8\u8BA4\u4E0D\u56FA\u5B9A + float u_raisingHeight; +}; + +in vec4 v_Color; +in vec3 v_uvs; +in vec2 v_texture_data; + +#pragma include "scene_uniforms" +#pragma include "picking" + +out vec4 outputColor; + +void main() { + float opacity = u_opacity; + float isSide = v_texture_data.x; + float lightWeight = v_texture_data.y; + float topU = v_uvs[0]; + float topV = 1.0 - v_uvs[1]; + float sidey = v_uvs[2]; + + outputColor = texture(SAMPLER_2D(u_texture), vec2(topU, topV)); + // Tip: \u90E8\u5206\u673A\u578B GPU \u8BA1\u7B97\u7CBE\u5EA6\u517C\u5BB9 + if (isSide < 0.999) {// \u662F\u5426\u662F\u8FB9\u7F18 + // side face + if (u_sidesurface < 1.0) { + discard; + } + + if (u_linearColor == 1.0) { + vec4 linearColor = mix(u_targetColor, u_sourceColor, sidey); + linearColor.rgb *= lightWeight; + outputColor = linearColor; + } else { + outputColor = v_Color; + } + } else { + // top face + if (u_topsurface < 1.0) { + discard; + } + } + + outputColor.a *= opacity; + outputColor = filterColor(outputColor); +} +`,iL=`layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in float a_Size; +layout(location = 13) in vec3 a_Normal; +layout(location = 14) in vec3 a_uvs; + + +layout(std140) uniform commonUniforms { + vec4 u_sourceColor; + vec4 u_targetColor; + float u_linearColor; + float u_topsurface; + float u_sidesurface; + float u_heightfixed; // \u9ED8\u8BA4\u4E0D\u56FA\u5B9A + float u_raisingHeight; +}; + +out vec4 v_Color; +out vec3 v_uvs; +out vec2 v_texture_data; + +#pragma include "projection" +#pragma include "light" +#pragma include "picking" + +void main() { + + vec4 pos = vec4(a_Position.xy, a_Position.z * a_Size, 1.0); + float lightWeight = calc_lighting(pos); + vec4 project_pos = project_position(pos); + v_uvs = a_uvs; + v_Color = a_Color; + v_Color.a *= opacity; + + v_texture_data = vec2(a_Position.z, lightWeight); + + if(u_heightfixed > 0.0) { // \u5224\u65AD\u51E0\u4F55\u4F53\u662F\u5426\u56FA\u5B9A\u9AD8\u5EA6 + project_pos.z = a_Position.z * a_Size; + project_pos.z += u_raisingHeight; + + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + float mapboxZoomScale = 4.0/pow(2.0, 21.0 - u_Zoom); + project_pos.z *= mapboxZoomScale; + project_pos.z += u_raisingHeight * mapboxZoomScale; + } + } + + + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xyz, 1.0)); + + + + setPickingColor(a_PickingColor); +} +`,oL=` +layout(std140) uniform commonUniforms { + vec4 u_sourceColor; + vec4 u_targetColor; + float u_linearColor; + float u_topsurface; + float u_sidesurface; + float u_heightfixed; // \u9ED8\u8BA4\u4E0D\u56FA\u5B9A + float u_raisingHeight; +}; + +in vec4 v_Color; +in vec3 v_uvs; +in vec2 v_texture_data; +out vec4 outputColor; + +#pragma include "scene_uniforms" +#pragma include "picking" + +void main() { + float isSide = v_texture_data.x; + float sidey = v_uvs[2]; + float lightWeight = v_texture_data.y; + + // Tip: \u90E8\u5206\u673A\u578B GPU \u8BA1\u7B97\u7CBE\u5EA6\u517C\u5BB9 + if(isSide < 0.999) { + // side face + if(u_sidesurface < 1.0) { + discard; + } + + if( u_linearColor == 1.0) { + // side use linear + vec4 linearColor = mix(u_targetColor, u_sourceColor, sidey); + linearColor.rgb *= lightWeight; + outputColor = linearColor; + } else { + // side notuse linear + outputColor = v_Color; + } + } else { + // top face + if(u_topsurface < 1.0) { + discard; + } + outputColor = v_Color; + } + + outputColor = filterColorAlpha(outputColor, lightWeight); +} +`,aL=`layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in float a_Size; +layout(location = 13) in vec3 a_Normal; +layout(location = 14) in vec3 a_uvs; + + +layout(std140) uniform commonUniforms { + vec4 u_sourceColor; + vec4 u_targetColor; + float u_linearColor; + float u_topsurface; + float u_sidesurface; + float u_heightfixed; // \u9ED8\u8BA4\u4E0D\u56FA\u5B9A + float u_raisingHeight; +}; + +out vec4 v_Color; +out vec3 v_uvs; +out vec2 v_texture_data; + +#pragma include "projection" +#pragma include "light" +#pragma include "picking" + +void main() { + + + v_uvs = a_uvs; + // cal style mapping - \u6570\u636E\u7EB9\u7406\u6620\u5C04\u90E8\u5206\u7684\u8BA1\u7B97 + vec4 pos = vec4(a_Position.xy, a_Position.z * a_Size, 1.0); + vec4 project_pos = project_position(pos); + + if(u_heightfixed > 0.0) { // \u5224\u65AD\u51E0\u4F55\u4F53\u662F\u5426\u56FA\u5B9A\u9AD8\u5EA6 + project_pos.z = a_Position.z * a_Size; + project_pos.z += u_raisingHeight; + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + float mapboxZoomScale = 4.0/pow(2.0, 21.0 - u_Zoom); + project_pos.z *= mapboxZoomScale; + project_pos.z += u_raisingHeight * mapboxZoomScale; + } + } + + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xyz, 1.0)); + float lightWeight = calc_lighting(pos); + v_texture_data = vec2(a_Position.z,lightWeight); + + v_Color = vec4(a_Color.rgb * lightWeight, a_Color.w * opacity); + + setPickingColor(a_PickingColor); +} +`,sL=function(e){(0,Me.Z)(r,e);var i=JO(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getUninforms",value:function(){var t=this.getCommonUniformsInfo(),a=this.getUniformsBufferInfo(this.getStyleAttribute());return this.updateStyleUnifoms(),(0,Se.Z)((0,Se.Z)({},t.uniformsOption),a.uniformsOption)}},{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.mapTexture,u=t.heightfixed,c=u===void 0?!1:u,m=t.raisingHeight,E=m===void 0?0:m,H=t.topsurface,re=H===void 0?!0:H,xe=t.sidesurface,ke=xe===void 0?!0:xe,rt=t.sourceColor,vt=t.targetColor,It=0,er=[1,1,1,1],Ar=[1,1,1,1];rt&&vt&&(er=Lo(rt),Ar=Lo(vt),It=1);var Or={u_sourceColor:er,u_targetColor:Ar,u_linearColor:It,u_topsurface:Number(re),u_sidesurface:Number(ke),u_heightfixed:Number(c),u_raisingHeight:Number(E)};a&&this.texture&&(Or.u_texture=this.texture,this.textures=[this.texture]);var rn=this.getUniformsBufferInfo(Or);return rn}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.next=2,this.loadTexture();case 2:return c.abrupt("return",this.buildModels());case 3:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E,H;return Ur().wrap(function(xe){for(;;)switch(xe.prev=xe.next){case 0:return u=this.getShaders(),c=u.frag,m=u.vert,E=u.type,this.initUniformsBuffer(),xe.next=4,this.layer.buildLayerModel({moduleName:E,vertexShader:m,fragmentShader:c,depth:{enable:!0},inject:this.getInject(),triangulation:Wx});case 4:return H=xe.sent,xe.abrupt("return",[H]);case 6:case"end":return xe.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"getShaders",value:function(){var t=this.layer.getLayerConfig(),a=t.pickLight,u=t.mapTexture;return u?{frag:nL,vert:iL,type:"polygonExtrudeTexture"}:a?{frag:oL,vert:aL,type:"polygonExtrudePickLight"}:{frag:tL,vert:rL,type:"polygonExtrude"}}},{key:"clearModels",value:function(){var t;(t=this.texture)===null||t===void 0||t.destroy(),this.textures=[]}},{key:"registerBuiltinAttributes",value:function(){var t=this.layer.getSource().extent,a=t,u=this.layer.coordCenter||this.layer.getSource().center,c=a[2]-a[0],m=a[3]-a[1];if(this.mapService.version==="GAODE2.x"){var E=this.mapService.coordToAMap2RelativeCoordinates([t[0],t[1]],u),H=(0,gi.Z)(E,2),re=H[0],xe=H[1],ke=this.mapService.coordToAMap2RelativeCoordinates([t[2],t[3]],u),rt=(0,gi.Z)(ke,2),vt=rt[0],It=rt[1];c=vt-re,m=It-xe,a=[re,xe,vt,It]}this.styleAttributeService.registerStyleAttribute({name:"uvs",type:Vu.Attribute,descriptor:{name:"a_uvs",shaderLocation:Gc.UV,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(Ar,Or,rn){var Ln=rn[0],wn=rn[1];return[(Ln-a[0])/c,(wn-a[1])/m,rn[4]]}}}),this.styleAttributeService.registerStyleAttribute({name:"normal",type:Vu.Attribute,descriptor:{name:"a_Normal",shaderLocation:Gc.NORMAL,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(Ar,Or,rn,Ln,wn){return wn}}}),this.styleAttributeService.registerStyleAttribute({name:"size",type:Vu.Attribute,descriptor:{name:"a_Size",shaderLocation:Gc.SIZE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(Ar){var Or=Ar.size,rn=Or===void 0?10:Or;return Array.isArray(rn)?[rn[0]]:[rn]}}})}},{key:"loadTexture",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E;return Ur().wrap(function(re){for(;;)switch(re.prev=re.next){case 0:if(u=this.layer.getLayerConfig(),c=u.mapTexture,m=this.rendererService.createTexture2D,this.texture=m({height:1,width:1}),!c){re.next=8;break}return re.next=6,QO(c);case 6:E=re.sent,this.texture=m({data:E,width:E.width,height:E.height,wrapS:Er.CLAMP_TO_EDGE,wrapT:Er.CLAMP_TO_EDGE,min:Er.LINEAR,mag:Er.LINEAR});case 8:case"end":return re.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()}]),r}(Kd);function uL(e){var i=lL();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function lL(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var cL=` +in vec4 v_Color; +#pragma include "scene_uniforms" +#pragma include "picking" +out vec4 outputColor; +void main() { + + outputColor = v_Color; + outputColor = filterColor(outputColor); +} +`,fL=`layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 9) in float a_Size; +layout(location = 13) in vec3 a_Normal; + +out vec4 v_Color; + +#pragma include "projection" +#pragma include "light" +#pragma include "picking" + +void main() { + + vec4 pos = vec4(a_Position.xy, a_Position.z * a_Size + (1.0 - a_Position.z) * extrusionBase, 1.0); + + vec4 project_pos = project_position(pos); + float lightWeight = calc_lighting(project_pos); + v_Color = a_Color; + v_Color = vec4(v_Color.rgb * lightWeight, v_Color.w * opacity); + + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xyz, 1.0)); + + setPickingColor(a_PickingColor); +} +`,hL=function(e){(0,Me.Z)(r,e);var i=uL(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getUninforms",value:function(){var t=this.getCommonUniformsInfo(),a=this.getUniformsBufferInfo(this.getStyleAttribute());return this.updateStyleUnifoms(),(0,Se.Z)((0,Se.Z)({},t.uniformsOption),a.uniformsOption)}},{key:"getCommonUniformsInfo",value:function(){var t={},a=this.getUniformsBufferInfo(t);return a}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.abrupt("return",this.buildModels());case 1:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E,H;return Ur().wrap(function(xe){for(;;)switch(xe.prev=xe.next){case 0:return u=this.getShaders(),c=u.frag,m=u.vert,E=u.type,this.initUniformsBuffer(),xe.next=4,this.layer.buildLayerModel({moduleName:E,vertexShader:m,fragmentShader:c,inject:this.getInject(),triangulation:Wx,depth:{enable:!0}});case 4:return H=xe.sent,xe.abrupt("return",[H]);case 6:case"end":return xe.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"getShaders",value:function(){return{frag:cL,vert:fL,type:"polygonExtrude"}}},{key:"clearModels",value:function(){var t;(t=this.texture)===null||t===void 0||t.destroy()}},{key:"registerBuiltinAttributes",value:function(){this.styleAttributeService.registerStyleAttribute({name:"normal",type:Vu.Attribute,descriptor:{name:"a_Normal",shaderLocation:Gc.NORMAL,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(a,u,c,m,E){return E}}}),this.styleAttributeService.registerStyleAttribute({name:"size",type:Vu.Attribute,descriptor:{name:"a_Size",shaderLocation:Gc.SIZE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(a){var u=a.size,c=u===void 0?10:u;return Array.isArray(c)?[c[0]]:[c]}}})}}]),r}(Kd);function dL(e){var i=pL();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function pL(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var mL=`in vec4 v_color; +#pragma include "scene_uniforms" +#pragma include "picking" +out vec4 outputColor; +void main() { + outputColor = v_color; + outputColor = filterColor(outputColor); +} +`,vL=` +layout(std140) uniform commonUniforms { + float u_raisingHeight; + float u_opacitylinear; + float u_dir; +}; + +in vec4 v_color; +in vec3 v_linear; +in vec2 v_pos; +out vec4 outputColor; +#pragma include "scene_uniforms" +#pragma include "picking" + +void main() { + outputColor = v_color; + if (u_opacitylinear > 0.0) { + outputColor.a *= u_dir == 1.0 ? 1.0 - length(v_pos - v_linear.xy)/v_linear.z : length(v_pos - v_linear.xy)/v_linear.z; + } + outputColor = filterColor(outputColor); +} +`,gL=`layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 15) in vec3 a_linear; + +layout(std140) uniform commonUniforms { + float u_raisingHeight; + float u_opacitylinear; + float u_dir; +}; + +out vec4 v_color; +out vec3 v_linear; +out vec2 v_pos; + +#pragma include "projection" +#pragma include "picking" + +void main() { + if (u_opacitylinear > 0.0) { + v_linear = a_linear; + v_pos = a_Position.xy; + } + v_color = vec4(a_Color.xyz, a_Color.w * opacity); + vec4 project_pos = project_position(vec4(a_Position, 1.0)); + project_pos.z += u_raisingHeight; + + if (u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + float mapboxZoomScale = 4.0/pow(2.0, 21.0 - u_Zoom); + project_pos.z *= mapboxZoomScale; + project_pos.z += u_raisingHeight * mapboxZoomScale; + } + + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xyz, 1.0)); + setPickingColor(a_PickingColor); +}`,yL=`layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; + +layout(std140) uniform commonUniforms { + float u_raisingHeight; +}; + + +out vec4 v_color; + + +#pragma include "projection" +#pragma include "picking" + +void main() { + // cal style mapping - \u6570\u636E\u7EB9\u7406\u6620\u5C04\u90E8\u5206\u7684\u8BA1\u7B97 + + // cal style mapping - \u6570\u636E\u7EB9\u7406\u6620\u5C04\u90E8\u5206\u7684\u8BA1\u7B97 + + v_color = vec4(a_Color.xyz, a_Color.w * opacity); + vec4 project_pos = project_position(vec4(a_Position, 1.0)); + // gl_Position = project_common_position_to_clipspace(vec4(project_pos.xyz, 1.0)); + + project_pos.z += u_raisingHeight; + + if(u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT || u_CoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSET) { + float mapboxZoomScale = 4.0/pow(2.0, 21.0 - u_Zoom); + project_pos.z *= mapboxZoomScale; + project_pos.z += u_raisingHeight * mapboxZoomScale; + } + + + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xyz, 1.0)); + + setPickingColor(a_PickingColor); +} + +`,_L=function(e){(0,Me.Z)(r,e);var i=dL(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getUninforms",value:function(){var t=this.getCommonUniformsInfo(),a=this.getUniformsBufferInfo(this.getStyleAttribute());return this.updateStyleUnifoms(),(0,Se.Z)((0,Se.Z)({},t.uniformsOption),a.uniformsOption)}},{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.raisingHeight,u=a===void 0?0:a,c=t.opacityLinear,m=c===void 0?{enable:!1,dir:"in"}:c,E={u_raisingHeight:Number(u),u_opacitylinear:Number(m.enable),u_dir:m.dir==="in"?1:0},H=this.getUniformsBufferInfo(E);return H}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.abrupt("return",this.buildModels());case 1:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E,H,re;return Ur().wrap(function(ke){for(;;)switch(ke.prev=ke.next){case 0:return u=this.getModelParams(),c=u.frag,m=u.vert,E=u.triangulation,H=u.type,this.initUniformsBuffer(),this.layer.triangulation=E,ke.next=5,this.layer.buildLayerModel({moduleName:H,vertexShader:m,fragmentShader:c,inject:this.getInject(),triangulation:E,primitive:Er.TRIANGLES,depth:{enable:!1}});case 5:return re=ke.sent,ke.abrupt("return",[re]);case 7:case"end":return ke.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"registerBuiltinAttributes",value:function(){var t=this.layer.getLayerConfig(),a=t.opacityLinear,u=a===void 0?{enable:!1,dir:"in"}:a;u.enable&&this.styleAttributeService.registerStyleAttribute({name:"linear",type:Vu.Attribute,descriptor:{name:"a_linear",shaderLocation:Gc.LINEAR,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(m,E,H){return[H[3],H[4],H[5]]}}})}},{key:"getModelParams",value:function(){var t=this.layer.getLayerConfig(),a=t.opacityLinear,u=a===void 0?{enable:!1}:a;return u.enable?{frag:vL,vert:gL,type:"polygonLinear",triangulation:PI}:{frag:mL,vert:yL,type:"polygonFill",triangulation:L0}}}]),r}(Kd);function AL(e){var i=bL();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function bL(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var xL=` +layout(std140) uniform commonUniforms { + vec4 u_watercolor; + vec4 u_watercolor2; + float u_time; +}; + +in vec2 v_uv; +in float v_opacity; +out vec4 outputColor; + +float coast2water_fadedepth = 0.10; +float large_waveheight = .750; // change to adjust the "heavy" waves +float large_wavesize = 3.4; // factor to adjust the large wave size +float small_waveheight = 0.6; // change to adjust the small random waves +float small_wavesize = 0.5; // factor to ajust the small wave size +float water_softlight_fact = 15.; // range [1..200] (should be << smaller than glossy-fact) +float water_glossylight_fact= 120.; // range [1..200] +float particle_amount = 70.; + +vec3 water_specularcolor = vec3(1.3, 1.3, 0.9); // specular Color (RGB) of the water-highlights +#define light vec3(-0., sin(u_time*0.5)*.5 + .35, 2.8) // position of the sun + +uniform sampler2D u_texture1; +uniform sampler2D u_texture2; +uniform sampler2D u_texture3; + + + +float hash( float n ) { + return fract(sin(n)*43758.5453123); +} + +// 2d noise function +float noise1( in vec2 x ) { + vec2 p = floor(x); + vec2 f = smoothstep(0.0, 1.0, fract(x)); + float n = p.x + p.y*57.0; + return mix(mix( hash(n+ 0.0), hash(n+ 1.0),f.x), + mix( hash(n+ 57.0), hash(n+ 58.0),f.x),f.y); +} + +float noise(vec2 p) { + return texture(SAMPLER_2D(u_texture2),p*vec2(1./256.)).x; +} + +vec4 highness(vec2 p) { + vec4 t = texture(SAMPLER_2D(u_texture1),fract(p)); + float clipped = -2.0-smoothstep(3.,10.,t.a)*6.9-smoothstep(10.,100.,t.a)*89.9-smoothstep(0.,10000.,t.a)*10000.0; + return clamp(t, 0.0,3.0)+clamp(t/3.0-1.0, 0.0,1.0)+clamp(t/16.0-1.0, 0.0,1.0); +} + +float height_map( vec2 p ) { + vec4 height=highness(p); + /* + height = -0.5+ + 0.5*smoothstep(-100.,0.,-height)+ + 2.75*smoothstep(0.,2.,height)+ + 1.75*smoothstep(2.,4.,height)+ + 2.75*smoothstep(4.,16.,height)+ + 1.5*smoothstep(16.,1000.,height); + */ + + mat2 m = mat2( 0.9563*1.4, -0.2924*1.4, 0.2924*1.4, 0.9563*1.4 ); + //p = p*6.; + float f = 0.6000*noise1( p ); p = m*p*1.1*6.; + f += 0.2500*noise( p ); p = m*p*1.32; + f += 0.1666*noise( p ); p = m*p*1.11; + f += 0.0834*noise( p ); p = m*p*1.12; + f += 0.0634*noise( p ); p = m*p*1.13; + f += 0.0444*noise( p ); p = m*p*1.14; + f += 0.0274*noise( p ); p = m*p*1.15; + f += 0.0134*noise( p ); p = m*p*1.16; + f += 0.0104*noise( p ); p = m*p*1.17; + f += 0.0084*noise( p ); + f = .25*f+dot(height,vec4(-.03125,-.125,.25,.25))*.5; + const float FLAT_LEVEL = 0.92525; + //f = f*0.25+height*0.75; + if (f level) + { + col = CalcTerrain(uv, height); + } + if (height <= level) + { + vec2 dif = vec2(.0, .01); + vec2 pos = uv*15. + vec2(u_time*.01); + float h1 = water_map(pos-dif,waveheight); + float h2 = water_map(pos+dif,waveheight); + float h3 = water_map(pos-dif.yx,waveheight); + float h4 = water_map(pos+dif.yx,waveheight); + vec3 normwater = normalize(vec3(h3-h4, h1-h2, .125)); // norm-vector of the 'bumpy' water-plane + uv += normwater.xy*.002*(level-height); + + col = CalcTerrain(uv, height); + + float coastfade = clamp((level-height)/coast2water_fadedepth, 0., 1.); + float coastfade2= clamp((level-height)/deepwater_fadedepth, 0., 1.); + float intensity = col.r*.2126+col.g*.7152+col.b*.0722; + watercolor = mix(watercolor*intensity, watercolor2, smoothstep(0., 1., coastfade2)); + + vec3 r0 = vec3(uv, WATER_LEVEL); + vec3 rd = normalize( light - r0 ); // ray-direction to the light from water-position + float grad = dot(normwater, rd); // dot-product of norm-vector and light-direction + float specular = pow(grad, water_softlight_fact); // used for soft highlights + float specular2= pow(grad, water_glossylight_fact); // used for glossy highlights + float gradpos = dot(vec3(0., 0., 1.), rd); + float specular1= smoothstep(0., 1., pow(gradpos, 5.)); // used for diffusity (some darker corona around light's specular reflections...) + float watershade = test_shadow( uv, level ); + watercolor *= 2.2+watershade; + watercolor += (.2+.8*watershade) * ((grad-1.0)*.5+specular) * .25; + watercolor /= (1.+specular1*1.25); + watercolor += watershade*specular2*water_specularcolor; + watercolor += watershade*coastfade*(1.-coastfade2)*(vec3(.5, .6, .7)*nautic(uv)+vec3(1., 1., 1.)*particles(uv)); + + col = mix(col, watercolor, coastfade); + } + + outputColor = vec4(col, v_opacity); +} +`,wL=`layout(location = 0) in vec3 a_Position; +layout(location = 14) in vec2 a_uv; + +layout(std140) uniform commonUniforms { + vec4 u_watercolor; + vec4 u_watercolor2; + float u_time; +}; + + +out vec2 v_uv; +out float v_opacity; + +#pragma include "projection" + +void main() { + v_uv = a_uv; + v_opacity = opacity; + vec4 project_pos = project_position(vec4(a_Position, 1.0)); + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xyz, 1.0)); +} + +`,mV=lo.isNumber,EL=function(e){(0,Me.Z)(r,e);var i=AL(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getUninforms",value:function(){var t=this.getCommonUniformsInfo(),a=this.getUniformsBufferInfo(this.getStyleAttribute());return this.updateStyleUnifoms(),(0,Se.Z)((0,Se.Z)({},t.uniformsOption),a.uniformsOption)}},{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.watercolor,u=a===void 0?"#6D99A8":a,c=t.watercolor2,m=c===void 0?"#0F121C":c,E={u_watercolor:Lo(u),u_watercolor2:Lo(m),u_time:this.layer.getLayerAnimateTime(),u_texture1:this.texture1,u_texture2:this.texture2,u_texture3:this.texture3};this.textures=[this.texture1,this.texture2,this.texture3];var H=this.getUniformsBufferInfo(E);return H}},{key:"getAnimateUniforms",value:function(){return{u_time:this.layer.getLayerAnimateTime()}}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return this.loadTexture(),c.abrupt("return",this.buildModels());case 2:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u;return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return this.initUniformsBuffer(),m.next=3,this.layer.buildLayerModel({moduleName:"polygonOcean",vertexShader:wL,fragmentShader:xL,inject:this.getInject(),triangulation:Gx,primitive:Er.TRIANGLES,depth:{enable:!1}});case 3:return u=m.sent,m.abrupt("return",[u]);case 5:case"end":return m.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"clearModels",value:function(){var t,a,u;(t=this.texture1)===null||t===void 0||t.destroy(),(a=this.texture2)===null||a===void 0||a.destroy(),(u=this.texture3)===null||u===void 0||u.destroy()}},{key:"registerBuiltinAttributes",value:function(){var t=this.layer.getSource().extent,a=(0,gi.Z)(t,4),u=a[0],c=a[1],m=a[2],E=a[3],H=m-u,re=E-c;this.styleAttributeService.registerStyleAttribute({name:"oceanUv",type:Vu.Attribute,descriptor:{name:"a_uv",shaderLocation:Gc.UV,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:2,update:function(ke,rt,vt,It){var er=ke.version==="GAODE2.x"?ke.originCoordinates[0][It]:vt,Ar=(0,gi.Z)(er,2),Or=Ar[0],rn=Ar[1];return[(Or-u)/H,(rn-c)/re]}}})}},{key:"loadTexture",value:function(){var t=this,a=this.rendererService.createTexture2D,u={height:0,width:0};this.texture1=a(u),this.texture2=a(u),this.texture3=a(u),c(function(E){t.texture1=m(E[0]),t.texture2=m(E[1]),t.texture3=m(E[2]),t.layerService.reRender()});function c(E){var H=0,re=[],xe=["https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*EojwT4VzSiYAAAAAAAAAAAAAARQnAQ","https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*MJ22QbpuCzIAAAAAAAAAAAAAARQnAQ","https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*-z2HSIVDsHIAAAAAAAAAAAAAARQnAQ"];xe.map(function(ke){var rt=new Image;rt.crossOrigin="",rt.src=ke,re.push(rt),rt.onload=function(){H++,H===3&&E(re)}})}function m(E){return a({data:E,width:E.width,height:E.height,wrapS:Er.MIRRORED_REPEAT,wrapT:Er.MIRRORED_REPEAT,min:Er.LINEAR,mag:Er.LINEAR})}}}]),r}(Kd);function SL(e){var i=CL();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function CL(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var TL=`uniform sampler2D u_texture; +layout(std140) uniform commonUniforms { + float u_speed; + float u_time; +}; + +out vec4 outputColor; + + +in vec4 v_Color; +in vec2 v_uv; + +float rand(vec2 n) { return 0.5 + 0.5 * fract(sin(dot(n.xy, vec2(12.9898, 78.233)))* 43758.5453); } + +float water(vec3 p) { + float t = u_time * u_speed; + p.z += t * 2.; p.x += t * 2.; + vec3 c1 = texture(SAMPLER_2D(u_texture), p.xz / 30.).xyz; + p.z += t * 3.; p.x += t * 0.52; + vec3 c2 = texture(SAMPLER_2D(u_texture), p.xz / 30.).xyz; + p.z += t * 4.; p.x += t * 0.8; + vec3 c3 = texture(SAMPLER_2D(u_texture), p.xz / 30.).xyz; + c1 += c2 - c3; + float z = (c1.x + c1.y + c1.z) / 3.; + return p.y + z / 4.; +} + +float map(vec3 p) { + float d = 100.0; + d = water(p); + return d; +} + +float intersect(vec3 ro, vec3 rd) { + float d = 0.0; + for (int i = 0; i <= 100; i++) { + float h = map(ro + rd * d); + if (h < 0.1) return d; + d += h; + } + return 0.0; +} + +vec3 norm(vec3 p) { + float eps = .1; + return normalize(vec3( + map(p + vec3(eps, 0, 0)) - map(p + vec3(-eps, 0, 0)), + map(p + vec3(0, eps, 0)) - map(p + vec3(0, -eps, 0)), + map(p + vec3(0, 0, eps)) - map(p + vec3(0, 0, -eps)) + )); +} + +float calSpc() { + vec3 l1 = normalize(vec3(1, 1, 1)); + vec3 ro = vec3(-3, 20, -8); + vec3 rc = vec3(0, 0, 0); + vec3 ww = normalize(rc - ro); + vec3 uu = normalize(cross(vec3(0,1,0), ww)); + vec3 vv = normalize(cross(rc - ro, uu)); + vec3 rd = normalize(uu * v_uv.x + vv * v_uv.y + ww); + float d = intersect(ro, rd); + vec3 p = ro + rd * d; + vec3 n = norm(p); + float spc = pow(max(0.0, dot(reflect(l1, n), rd)), 30.0); + return spc; +} + +void main() { + + outputColor = v_Color; + float spc = calSpc(); + outputColor += spc * 0.4; +} +`,ML=`layout(location = 0) in vec3 a_Position; +layout(location = 1) in vec4 a_Color; +layout(location = 14) in vec2 a_uv; +layout(std140) uniform commonUniforms { + float u_speed; + float u_time; +}; +out vec4 v_Color; +out vec2 v_uv; + + +#pragma include "projection" + +void main() { + v_uv = a_uv; + v_Color = a_Color; + v_Color.a *= opacity; + vec4 project_pos = project_position(vec4(a_Position, 1.0)); + + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xyz, 1.0)); +} + +`,vV=lo.isNumber,PL=function(e){(0,Me.Z)(r,e);var i=SL(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getUninforms",value:function(){var t=this.getCommonUniformsInfo(),a=this.getUniformsBufferInfo(this.getStyleAttribute());return this.updateStyleUnifoms(),(0,Se.Z)((0,Se.Z)({},t.uniformsOption),a.uniformsOption)}},{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.speed,u=a===void 0?.5:a,c={u_speed:u,u_time:this.layer.getLayerAnimateTime(),u_texture:this.texture};this.textures=[this.texture];var m=this.getUniformsBufferInfo(c);return m}},{key:"getAnimateUniforms",value:function(){return{u_time:this.layer.getLayerAnimateTime()}}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return this.loadTexture(),c.abrupt("return",this.buildModels());case 2:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u;return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return this.initUniformsBuffer(),m.next=3,this.layer.buildLayerModel({moduleName:"polygonWater",vertexShader:ML,fragmentShader:TL,triangulation:Gx,inject:this.getInject(),primitive:Er.TRIANGLES,depth:{enable:!1},pickingEnabled:!1,diagnosticDerivativeUniformityEnabled:!1});case 3:return u=m.sent,m.abrupt("return",[u]);case 5:case"end":return m.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"clearModels",value:function(){var t;(t=this.texture)===null||t===void 0||t.destroy()}},{key:"registerBuiltinAttributes",value:function(){var t=this.layer.getSource().extent,a=(0,gi.Z)(t,4),u=a[0],c=a[1],m=a[2],E=a[3],H=m-u,re=E-c;this.styleAttributeService.registerStyleAttribute({name:"waterUv",type:Vu.Attribute,descriptor:{name:"a_uv",shaderLocation:Gc.UV,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:2,update:function(ke,rt,vt,It){var er=ke.version==="GAODE2.x"?ke.originCoordinates[0][It]:vt,Ar=(0,gi.Z)(er,2),Or=Ar[0],rn=Ar[1];return[(Or-u)/H,(rn-c)/re]}}})}},{key:"loadTexture",value:function(){var t=this,a=this.layer.getLayerConfig(),u=a.waterTexture,c=this.rendererService.createTexture2D;this.texture=c({height:1,width:1});var m=new Image;m.crossOrigin="",u?(console.warn("L7 recommend\uFF1Ahttps://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*EojwT4VzSiYAAAAAAAAAAAAAARQnAQ"),m.src=u):m.src="https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*EojwT4VzSiYAAAAAAAAAAAAAARQnAQ",m.onload=function(){t.texture=c({data:m,width:m.width,height:m.height,wrapS:Er.MIRRORED_REPEAT,wrapT:Er.MIRRORED_REPEAT,min:Er.LINEAR,mag:Er.LINEAR}),t.layerService.reRender()}}}]),r}(Kd),IL={fill:_L,line:bS,extrude:sL,text:zS,point_fill:ES,point_image:SS,point_normal:TS,point_extrude:wS,water:PL,ocean:EL,extrusion:hL},RL=IL;function OL(e){var i=LL();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function LL(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var _b=function(e){(0,Me.Z)(r,e);var i=OL(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u 0.0 || x < 0.0) ? x != x : x != 0.0; } + +out vec4 outputColor; + +void main() { + // Can use any component here since u_rasterTexture is under luminance format. + float value = texture(SAMPLER_2D(u_rasterTexture), vec2(v_texCoord.x, v_texCoord.y)).r; + if (value == u_noDataValue || isnan_emu(value)) { + discard; + } else if ((u_clampLow < 0.5 && value < u_domain[0]) || (u_clampHigh < 0.5 && value > u_domain[1])) { + discard; + } else { + float normalisedValue =(value - u_domain[0]) / (u_domain[1] - u_domain[0]); + vec4 color = texture(SAMPLER_2D(u_colorTexture), vec2(normalisedValue, 0)); + + outputColor = color; + outputColor.a = outputColor.a * u_opacity ; + if (outputColor.a < 0.01) + discard; + } +} +`,BL=` +layout(location = 0) in vec3 a_Position; +layout(location = 14) in vec2 a_Uv; + +layout(std140) uniform commonUniforms { + vec2 u_domain; + float u_opacity; + float u_noDataValue; + float u_clampLow; + float u_clampHigh; +}; + +out vec2 v_texCoord; + +#pragma include "projection" + +void main() { + v_texCoord = a_Uv; + vec4 project_pos = project_position(vec4(a_Position, 1.0)); + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xy,0., 1.0)); +} +`,US=function(e){(0,Me.Z)(r,e);var i=DL(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getUninforms",value:function(){var t=this.getCommonUniformsInfo(),a=this.getUniformsBufferInfo(this.getStyleAttribute());return this.updateStyleUnifoms(),(0,Se.Z)((0,Se.Z)({},t.uniformsOption),a.uniformsOption)}},{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.opacity,u=a===void 0?1:a,c=t.clampLow,m=c===void 0?!0:c,E=t.clampHigh,H=E===void 0?!0:E,re=t.noDataValue,xe=re===void 0?-9999999:re,ke=t.domain,rt=t.rampColors,vt=ke||Yi(rt);this.colorTexture=this.layer.textureService.getColorTexture(rt,vt);var It={u_domain:vt,u_opacity:u||1,u_noDataValue:xe,u_clampLow:m?1:0,u_clampHigh:(typeof H!="undefined"?H:m)?1:0,u_rasterTexture:this.texture,u_colorTexture:this.colorTexture};this.textures=[this.texture,this.colorTexture];var er=this.getUniformsBufferInfo(It);return er}},{key:"getRasterData",value:function(){var n=(0,Li.Z)(Ur().mark(function a(u){var c,m,E,H;return Ur().wrap(function(xe){for(;;)switch(xe.prev=xe.next){case 0:if(!Array.isArray(u.data)){xe.next=4;break}return xe.abrupt("return",{data:u.data,width:u.width,height:u.height});case 4:return xe.next=6,u.data;case 6:return c=xe.sent,m=c.rasterData,E=c.width,H=c.height,xe.abrupt("return",{data:Array.from(m),width:E,height:H});case 11:case"end":return xe.stop()}},a)}));function t(a){return n.apply(this,arguments)}return t}()},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.abrupt("return",this.buildModels());case 1:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E,H,re,xe,ke,rt,vt;return Ur().wrap(function(er){for(;;)switch(er.prev=er.next){case 0:return this.initUniformsBuffer(),u=this.layer.getSource(),c=this.rendererService,m=c.createTexture2D,E=c.queryVerdorInfo,H=u.data.dataArray[0],er.next=6,this.getRasterData(H);case 6:return re=er.sent,xe=re.data,ke=re.width,rt=re.height,this.texture=m({data:new Float32Array(xe),width:ke,height:rt,format:E()==="WebGL1"?Er.LUMINANCE:Er.RED,type:Er.FLOAT,alignment:1}),er.next=13,this.layer.buildLayerModel({moduleName:"rasterImageData",vertexShader:BL,fragmentShader:FL,triangulation:F_,primitive:Er.TRIANGLES,depth:{enable:!1},pickingEnabled:!1});case 13:return vt=er.sent,er.abrupt("return",[vt]);case 15:case"end":return er.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"clearModels",value:function(){var t,a;(t=this.texture)===null||t===void 0||t.destroy(),(a=this.colorTexture)===null||a===void 0||a.destroy()}},{key:"registerBuiltinAttributes",value:function(){this.styleAttributeService.registerStyleAttribute({name:"uv",type:Vu.Attribute,descriptor:{shaderLocation:Gc.UV,name:"a_Uv",buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:2,update:function(a,u,c){return[c[3],c[4]]}}})}}]),r}(Kd),NL=["data"],zL=["rasterData"];function ZL(e){var i=UL();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function UL(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var jL=`uniform sampler2D u_texture; +layout(std140) uniform commonUniforms { + vec2 u_rminmax; + vec2 u_gminmax; + vec2 u_bminmax; + float u_opacity; + float u_noDataValue; +}; + +in vec2 v_texCoord; + +out vec4 outputColor; + +void main() { + + vec3 rgb = texture(SAMPLER_2D(u_texture),vec2(v_texCoord.x,v_texCoord.y)).rgb; + + if(rgb == vec3(u_noDataValue)) { + outputColor = vec4(0.0, 0, 0, 0.0); + } else { + outputColor = vec4(rgb.r / (u_rminmax.y -u_rminmax.x), rgb.g /(u_gminmax.y -u_gminmax.x), rgb.b/ (u_bminmax.y - u_bminmax.x), u_opacity); + } + + if(outputColor.a < 0.01) + discard; + +}`,VL=` +layout(location = 0) in vec3 a_Position; +layout(location = 14) in vec2 a_Uv; + +layout(std140) uniform commonUniforms { + vec2 u_rminmax; + vec2 u_gminmax; + vec2 u_bminmax; + float u_opacity; + float u_noDataValue; +}; + +out vec2 v_texCoord; + +#pragma include "projection" + +void main() { + v_texCoord = a_Uv; + vec4 project_pos = project_position(vec4(a_Position, 1.0)); + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xy,0., 1.0)); +} +`,$L=function(e){(0,Me.Z)(r,e);var i=ZL(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u u_domain[1])) { + outputColor = vec4(0.0, 0, 0, 0.0); + } else { + + outputColor = getColor(value); + outputColor.a = outputColor.a * u_opacity ; + if(outputColor.a < 0.01) + discard; + } +} +`,XL=`layout(location = 0) in vec3 a_Position; +layout(location = 14) in vec2 a_Uv; + +layout(std140) uniform commonUniforms { + vec4 u_unpack; + vec2 u_domain; + float u_opacity; + float u_noDataValue; + float u_clampLow; + float u_clampHigh; +}; +out vec2 v_texCoord; +#pragma include "projection" + +void main() { + v_texCoord = a_Uv; + vec4 project_pos = project_position(vec4(a_Position, 1.0)); + gl_Position = project_common_position_to_clipspace_v2(vec4(project_pos.xy,0., 1.0)); +} +`,YL=function(e){(0,Me.Z)(r,e);var i=HL(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.opacity,u=t.clampLow,c=u===void 0?!0:u,m=t.clampHigh,E=m===void 0?!0:m,H=t.noDataValue,re=H===void 0?-9999999:H,xe=t.domain,ke=t.rampColors,rt=t.colorTexture,vt=t.rScaler,It=vt===void 0?6553.6:vt,er=t.gScaler,Ar=er===void 0?25.6:er,Or=t.bScaler,rn=Or===void 0?.1:Or,Ln=t.offset,wn=Ln===void 0?1e4:Ln,Cn=xe||Yi(ke),qn=rt;rt?this.layer.textureService.setColorTexture(rt,ke,Cn):qn=this.layer.textureService.getColorTexture(ke,Cn);var Si={u_unpack:[It,Ar,rn,wn],u_domain:Cn,u_opacity:a||1,u_noDataValue:re,u_clampLow:c,u_clampHigh:typeof E!="undefined"?E:c,u_texture:this.texture,u_colorTexture:qn};this.textures=[this.texture,qn];var po=this.getUniformsBufferInfo(Si);return po}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E;return Ur().wrap(function(re){for(;;)switch(re.prev=re.next){case 0:return this.initUniformsBuffer(),u=this.layer.getSource(),c=this.rendererService.createTexture2D,re.next=5,u.data.images;case 5:return m=re.sent,this.texture=c({data:m[0],width:m[0].width,height:m[0].height,min:Er.LINEAR,mag:Er.LINEAR}),re.next=9,this.layer.buildLayerModel({moduleName:"RasterTileDataImage",vertexShader:XL,fragmentShader:WL,triangulation:F_,primitive:Er.TRIANGLES,depth:{enable:!1}});case 9:return E=re.sent,re.abrupt("return",[E]);case 11:case"end":return re.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"clearModels",value:function(){var t;(t=this.texture)===null||t===void 0||t.destroy()}},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.abrupt("return",this.initModels());case 1:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"registerBuiltinAttributes",value:function(){this.styleAttributeService.registerStyleAttribute({name:"uv",type:Vu.Attribute,descriptor:{name:"a_Uv",shaderLocation:Gc.UV,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:2,update:function(a,u,c){return[c[3],c[4]]}}})}}]),r}(Kd),KL={raster:US,rasterRgb:$L,raster3d:US,rasterTerrainRgb:YL},qL=KL;function QL(e){var i=JL();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function JL(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var Ab=function(e){(0,Me.Z)(r,e);var i=QL(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u 1.0) intensity = 0.0; + + outputColor = vec4(v_Color.rgb, v_Color.a * intensity * u_opacity); +} +`,aD=`layout(location = 0) in vec3 a_Position; +layout(location = 1) vec4 a_Color; +layout(location = 13) in vec3 a_Normal; +layout(location = 14) in vec2 a_Uv; +layout(std140) uniform commonUniforms { + float u_opacity; +}; +#pragma include "scene_uniforms" +out vec3 vVertexNormal; +out vec4 v_Color; +out float v_offset; + +void main() { + float EARTH_RADIUS = 100.0; + + v_Color = a_Color; + + v_offset = min(((length(u_CameraPosition) - EARTH_RADIUS)/600.0) * 0.5 + 0.4, 1.0); + vVertexNormal = a_Normal; + + gl_Position = u_ViewProjectionMatrix * u_ModelMatrix * vec4(a_Position, 1.0); +} +`,sD=lo.isNumber,uD=function(e){(0,Me.Z)(r,e);var i=nD(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.opacity,u=a===void 0?1:a,c={u_opacity:sD(u)?u:1},m=this.getUniformsBufferInfo(c);return m}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return this.initUniformsBuffer(),c.abrupt("return",this.buildModels());case 2:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"clearModels",value:function(){return""}},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u;return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return this.layer.zIndex=-997,m.next=3,this.layer.buildLayerModel({moduleName:"earthAtmoSphere",vertexShader:aD,fragmentShader:oD,triangulation:hS,depth:{enable:!1},blend:this.getBlend()});case 3:return u=m.sent,m.abrupt("return",[u]);case 5:case"end":return m.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"registerBuiltinAttributes",value:function(){this.styleAttributeService.registerStyleAttribute({name:"size",type:Vu.Attribute,descriptor:{name:"a_Size",shaderLocation:Gc.SIZE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(a){var u=a.size,c=u===void 0?1:u;return Array.isArray(c)?[c[0]]:[c]}}}),this.styleAttributeService.registerStyleAttribute({name:"normal",type:Vu.Attribute,descriptor:{name:"a_Normal",shaderLocation:Gc.NORMAL,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(a,u,c,m,E){return E}}}),this.styleAttributeService.registerStyleAttribute({name:"uv",type:Vu.Attribute,descriptor:{name:"a_Uv",shaderLocation:Gc.UV,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:2,update:function(a,u,c){return[c[3],c[4]]}}})}}]),r}(Kd);function lD(e){var i=cD();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function cD(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var fD=`uniform sampler2D u_texture; + +in vec2 v_texCoord; +in float v_lightWeight; +out vec4 outputColor; + +void main() { + vec4 color = texture(SAMPLER_2D(u_texture),vec2(v_texCoord.x,v_texCoord.y)); + color.xyz = color.xyz * v_lightWeight; + outputColor = color; +} +`,hD=`// attribute vec4 a_Color; +layout(location = 0) in vec3 a_Position; +layout(location = 13) in vec3 a_Normal; +layout(location = 14) in vec2 a_Uv; + +// attribute vec2 a_Extrude; +// attribute float a_Size; +// attribute float a_Shape; + +layout(std140) uniform commonUniforms { + vec4 u_sunLight: [1.0, -10.5, 12.0,0.0]; + float u_ambientRatio : 0.5; + float u_diffuseRatio : 0.3; + float u_specularRatio : 0.2; +}; + +#pragma include "scene_uniforms" + +out vec2 v_texCoord; +out float v_lightWeight; + +float calc_lighting(vec4 pos) { + + vec3 worldPos = vec3(pos * u_ModelMatrix); + + vec3 worldNormal = a_Normal; + + // cal light weight + vec3 viewDir = normalize(u_CameraPosition - worldPos); + + vec3 lightDir = normalize(u_sunLight.xyz); + + vec3 halfDir = normalize(viewDir+lightDir); + // lambert + float lambert = dot(worldNormal, lightDir); + // specular + float specular = pow(max(0.0, dot(worldNormal, halfDir)), 32.0); + //sum to light weight + float lightWeight = u_ambientRatio + u_diffuseRatio * lambert + u_specularRatio * specular; + + return lightWeight; +} + +void main() { + + v_texCoord = a_Uv; + + float lightWeight = calc_lighting(vec4(a_Position, 1.0)); + v_lightWeight = lightWeight; + + gl_Position = u_ViewProjectionMatrix * u_ModelMatrix * vec4(a_Position, 1.0); +} +`,dD=function(e){(0,Me.Z)(r,e);var i=lD(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u 1.0) intensity = 0.0; + + outputColor = vec4(v_Color.rgb, v_Color.a * intensity * u_opacity); +} +`,gD=`layout(location = 0) in vec3 a_Position; +layout(location = 1) vec4 a_Color; +layout(location = 13) in vec3 a_Normal; +layout(location = 14) in vec2 a_Uv; +layout(std140) uniform commonUniforms { + float u_opacity; +}; +#pragma include "scene_uniforms" + +out vec3 vVertexNormal; +out vec4 v_Color; + +void main() { + v_Color = a_Color; + + vVertexNormal = a_Normal; + + gl_Position = u_ViewProjectionMatrix * u_ModelMatrix * vec4(a_Position, 1.0); +} +`,yD=lo.isNumber,_D=function(e){(0,Me.Z)(r,e);var i=pD(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getCommonUniformsInfo",value:function(){var t=this.layer.getLayerConfig(),a=t.opacity,u=a===void 0?1:a,c={u_opacity:yD(u)?u:1},m=this.getUniformsBufferInfo(c);return m}},{key:"initModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return this.initUniformsBuffer(),c.abrupt("return",this.buildModels());case 2:case"end":return c.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"clearModels",value:function(){return""}},{key:"buildModels",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u;return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return this.layer.zIndex=-999,m.next=3,this.layer.buildLayerModel({moduleName:"earthBloom",vertexShader:gD,fragmentShader:vD,triangulation:DI,depth:{enable:!1},blend:this.getBlend()});case 3:return u=m.sent,m.abrupt("return",[u]);case 5:case"end":return m.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"registerBuiltinAttributes",value:function(){this.styleAttributeService.registerStyleAttribute({name:"size",type:Vu.Attribute,descriptor:{name:"a_Size",shaderLocation:Gc.SIZE,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:1,update:function(a){var u=a.size,c=u===void 0?1:u;return Array.isArray(c)?[c[0]]:[c]}}}),this.styleAttributeService.registerStyleAttribute({name:"normal",type:Vu.Attribute,descriptor:{name:"a_Normal",shaderLocation:Gc.NORMAL,buffer:{usage:Er.STATIC_DRAW,data:[],type:Er.FLOAT},size:3,update:function(a,u,c,m,E){return E}}}),this.styleAttributeService.registerStyleAttribute({name:"uv",type:Vu.Attribute,descriptor:{name:"a_Uv",shaderLocation:Gc.UV,buffer:{usage:Er.DYNAMIC_DRAW,data:[],type:Er.FLOAT},size:2,update:function(a,u,c){return[c[3],c[4]]}}})}}]),r}(Kd);function AD(e){var i=bD();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function bD(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var xD={base:dD,atomSphere:uD,bloomSphere:_D},wD=["base","atomSphere","bloomSphere"],ED=function(e){(0,Me.Z)(r,e);var i=AD(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u0&&arguments[0]!==void 0?arguments[0]:!0;t&&this.layerService.clear()}},{key:"registerBuiltinAttributes",value:function(){return""}}]),r}(Kd),ID={fill:PD},RD=ID;function OD(e){var i=LD();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function LD(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var qx=function(e){(0,Me.Z)(r,e);var i=OD(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u0&&arguments[0]!==void 0?arguments[0]:{},u=this.layer.getLayerConfig(),c=u.opacity;this.layerService.beforeRenderData(this.layer),this.layer.hooks.beforeRender.call(),this.layerService.renderMask(this.layer.masks),(t=this.colorModel)===null||t===void 0||t.draw({uniforms:{u_opacity:c||1,u_texture:this.texture},blend:this.getBlend(),stencil:this.getStencil(a)}),this.layer.hooks.afterRender.call()}}]),r}(Kd),XD={wind:WD},YD=XD;function KD(e){var i=qD();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function qD(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var QD=function(e){(0,Me.Z)(r,e);var i=KD(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u0&&arguments[0]!==void 0?arguments[0]:{};return this.layerModel&&this.layerModel.render(t),this}},{key:"getDefaultConfig",value:function(){var t=this.getModelType(),a={wind:{}};return a[t]}},{key:"getModelType",value:function(){return"wind"}}]),r}(hv),GS,WS,XS,YS,wb,KS,qS,JD=lo.cloneDeep,e8=(GS=(0,sa.b2)(),WS=(0,sa.f3)(sr.IMapService),XS=(0,sa.f3)(sr.IFontService),GS(YS=(wb=function(){function e(){(0,We.Z)(this,e),_(this,"mapService",KS,this),_(this,"fontService",qS,this)}return(0,ot.Z)(e,[{key:"apply",value:function(r,n){var t=this,a=n.styleAttributeService;r.hooks.init.tapPromise("DataMappingPlugin",(0,Li.Z)(Ur().mark(function u(){return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:r.log(zd.MappingStart,zl.INIT),t.generateMaping(r,{styleAttributeService:a}),r.log(zd.MappingEnd,zl.INIT);case 3:case"end":return m.stop()}},u)}))),r.hooks.beforeRenderData.tapPromise("DataMappingPlugin",function(){var u=(0,Li.Z)(Ur().mark(function c(m){var E;return Ur().wrap(function(re){for(;;)switch(re.prev=re.next){case 0:if(m){re.next=2;break}return re.abrupt("return",m);case 2:return r.dataState.dataMappingNeedUpdate=!1,r.log(zd.MappingStart,zl.UPDATE),E=t.generateMaping(r,{styleAttributeService:a}),r.log(zd.MappingEnd,zl.UPDATE),re.abrupt("return",E);case 7:case"end":return re.stop()}},c)}));return function(c){return u.apply(this,arguments)}}()),r.hooks.beforeRender.tap("DataMappingPlugin",function(){var u=r.getSource();if(!(r.layerModelNeedUpdate||!u||!u.inited)){var c=a.getLayerStyleAttributes()||[],m=a.getLayerStyleAttribute("filter"),E=u.data.dataArray;if(!(Array.isArray(E)&&E.length===0)){var H=c.filter(function(ke){return ke.needRemapping}),re=E;if(m!=null&&m.needRemapping&&m!==null&&m!==void 0&&m.scale&&(re=E.filter(function(ke){return t.applyAttributeMapping(m,ke)[0]})),H.length){var xe=t.mapping(r,H,re,r.getEncodedData());r.setEncodedData(xe)}}}})}},{key:"generateMaping",value:function(r,n){var t=this,a=n.styleAttributeService,u=a.getLayerStyleAttributes()||[],c=a.getLayerStyleAttribute("filter"),m=r.getSource().data.dataArray,E=m;c!=null&&c.scale&&(E=m.filter(function(re){return t.applyAttributeMapping(c,re)[0]})),E=r.processData(E);var H=this.mapping(r,u,E,void 0);return r.setEncodedData(H),r.emit("dataUpdate",null),!0}},{key:"mapping",value:function(r,n,t,a){var u=this,c=n.filter(function(E){return E.scale!==void 0}).filter(function(E){return E.name!=="filter"}),m=t.map(function(E,H){var re=a?a[H]:{},xe=(0,Se.Z)({id:E._id,coordinates:E.coordinates},re);return c.forEach(function(ke){var rt=u.applyAttributeMapping(ke,E);(ke.name==="color"||ke.name==="stroke")&&(rt=rt.map(function(vt){return Lo(vt)})),xe[ke.name]=Array.isArray(rt)&&rt.length===1?rt[0]:rt,ke.name==="shape"&&(xe.shape=u.fontService.getIconFontKey(xe[ke.name]))}),xe});return n.forEach(function(E){E.needRemapping=!1}),this.adjustData2Amap2Coordinates(m,r),this.adjustData2SimpleCoordinates(m),m}},{key:"adjustData2Amap2Coordinates",value:function(r,n){var t=this;if(r.length>0&&this.mapService.version==="GAODE2.x"){var a=n.coordCenter||n.getSource().center;r.filter(function(u){return!u.originCoordinates}).map(function(u){u.version="GAODE2.x",u.originCoordinates=JD(u.coordinates),u.coordinates=t.mapService.coordToAMap2RelativeCoordinates(u.coordinates,a)})}}},{key:"adjustData2SimpleCoordinates",value:function(r){var n=this;r.length>0&&this.mapService.version==="SIMPLE"&&r.map(function(t){t.simpleCoordinate||(t.coordinates=n.unProjectCoordinates(t.coordinates),t.simpleCoordinate=!0)})}},{key:"unProjectCoordinates",value:function(r){var n=this;if(typeof r[0]=="number")return this.mapService.simpleMapCoord.unproject(r);if(r[0]&&r[0][0]instanceof Array){var t=[];return r.map(function(u){var c=[];u.map(function(m){c.push(n.mapService.simpleMapCoord.unproject(m))}),t.push(c)}),t}else{var a=[];return r.map(function(u){a.push(n.mapService.simpleMapCoord.unproject(u))}),a}}},{key:"applyAttributeMapping",value:function(r,n){var t;if(!r.scale)return[];var a=(r==null||(t=r.scale)===null||t===void 0?void 0:t.scalers)||[],u=[];a.forEach(function(m){var E,H=m.field;(n.hasOwnProperty(H)||((E=r.scale)===null||E===void 0?void 0:E.type)==="variable")&&u.push(n[H])});var c=r.mapping?r.mapping(u):[];return c}},{key:"getArrowPoints",value:function(r,n){var t=[n[0]-r[0],n[1]-r[1]],a=Sa(t),u=[r[0]+a[0]*1e-4,r[1]+a[1]*1e-4];return u}}]),e}(),KS=d(wb.prototype,"mapService",[WS],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),qS=d(wb.prototype,"fontService",[XS],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),wb))||YS),QS,JS,t8=(QS=(0,sa.b2)(),QS(JS=function(){function e(){(0,We.Z)(this,e)}return(0,ot.Z)(e,[{key:"apply",value:function(r){var n=this;this.mapService=r.getContainer().get(sr.IMapService),r.hooks.init.tapPromise("DataSourcePlugin",(0,Li.Z)(Ur().mark(function t(){var a,u,c,m;return Ur().wrap(function(H){for(;;)switch(H.prev=H.next){case 0:if(r.log(zd.SourceInitStart,zl.INIT),a=r.getSource(),a||(u=r.sourceOption||r.defaultSourceConfig,c=u.data,m=u.options,a=new Ix(c,m),r.setSource(a)),!a.inited){H.next=8;break}n.updateClusterData(r),r.log(zd.SourceInitEnd,zl.INIT),H.next=10;break;case 8:return H.next=10,new Promise(function(re){a.on("update",function(xe){xe.type==="inited"&&(n.updateClusterData(r),r.log(zd.SourceInitEnd,zl.INIT)),re(null)})});case 10:case"end":return H.stop()}},t)}))),r.hooks.beforeRenderData.tapPromise("DataSourcePlugin",(0,Li.Z)(Ur().mark(function t(){var a,u,c;return Ur().wrap(function(E){for(;;)switch(E.prev=E.next){case 0:return a=n.updateClusterData(r),u=r.dataState.dataSourceNeedUpdate,r.dataState.dataSourceNeedUpdate=!1,c=a||u,E.abrupt("return",c);case 5:case"end":return E.stop()}},t)})))}},{key:"updateClusterData",value:function(r){if(r.isTileLayer||r.tileLayer||!r.getSource())return!1;var n=r.getSource(),t=n.cluster,a=n.clusterOptions.zoom,u=a===void 0?0:a,c=this.mapService.getZoom()-1,m=r.dataState.dataSourceNeedUpdate;return t&&m&&n.updateClusterData(Math.floor(c)),t&&Math.abs(r.clusterZoom-c)>=1?(u!==Math.floor(c)&&n.updateClusterData(Math.floor(c)),r.clusterZoom=c,!0):!1}}]),e}())||JS),Gm=A(57965);function eC(e,i,r,n,t){var a=e*e,u=a*e;return((1-3*e+3*a-u)*i+(4-6*a+3*u)*r+(1+3*e+3*a-3*u)*n+u*t)/6}function r8(e){var i=e.length-1;return function(r){var n=r<=0?r=0:r>=1?(r=1,i-1):Math.floor(r*i),t=e[n],a=e[n+1],u=n>0?e[n-1]:2*t-a,c=n180||r<-180?r-360*Math.round(r/360):r):constant(isNaN(e)?i:e)}function o8(e){return(e=+e)==1?rC:function(i,r){return r-i?i8(i,r,e):ew(isNaN(i)?r:i)}}function rC(e,i){var r=i-e;return r?tC(e,r):ew(isNaN(e)?i:e)}var nC=function e(i){var r=o8(i);function n(t,a){var u=r((t=nn(t)).r,(a=nn(a)).r),c=r(t.g,a.g),m=r(t.b,a.b),E=rC(t.opacity,a.opacity);return function(H){return t.r=u(H),t.g=c(H),t.b=m(H),t.opacity=E(H),t+""}}return n.gamma=e,n}(1);function iC(e){return function(i){var r=i.length,n=new Array(r),t=new Array(r),a=new Array(r),u,c;for(u=0;u=e.length)return r!=null&&c.sort(r),n!=null?n(c):c;for(var re=-1,xe=c.length,ke=e[m++],rt,vt,It=map(),er,Ar=E();++ree.length)return c;var E,H=i[m-1];return n!=null&&m>=e.length?E=c.entries():(E=[],c.each(function(re,xe){E.push({key:xe,values:u(re,m)})})),H!=null?E.sort(function(re,xe){return H(re.key,xe.key)}):E}return t={object:function(c){return a(c,0,s8,u8)},map:function(c){return a(c,0,aC,sC)},entries:function(c){return u(a(c,0,aC,sC),0)},key:function(c){return e.push(c),t},sortKeys:function(c){return i[e.length-1]=c,t},sortValues:function(c){return r=c,t},rollup:function(c){return n=c,t}}}function s8(){return{}}function u8(e,i,r){e[i]=r}function aC(){return map()}function sC(e,i,r){e.set(i,r)}function Sb(){}var qy=tw.prototype;Sb.prototype=l8.prototype={constructor:Sb,has:qy.has,add:function(e){return e+="",this[Lv+e]=e,this},remove:qy.remove,clear:qy.clear,values:qy.keys,size:qy.size,empty:qy.empty,each:qy.each};function l8(e,i){var r=new Sb;if(e instanceof Sb)e.each(function(a){r.add(a)});else if(e){var n=-1,t=e.length;if(i==null)for(;++nr&&(a=i.slice(r,a),c[u]?c[u]+=a:c[++u]=a),(n=n[0])===(t=t[0])?c[u]?c[u]+=t:c[++u]=t:(c[++u]=null,m.push({i:u,x:Tb(n,t)})),r=nw.lastIndex;return rr&&(n=i,i=r,r=n),function(t){return Math.max(i,Math.min(r,t))}}function A8(e,i,r){var n=e[0],t=e[1],a=i[0],u=i[1];return t2?b8:A8,m=E=null,re}function re(xe){return isNaN(xe=+xe)?a:(m||(m=c(e.map(n),i,r)))(n(u(xe)))}return re.invert=function(xe){return u(t((E||(E=c(i,e.map(n),Tb)))(xe)))},re.domain=function(xe){return arguments.length?(e=lC.call(xe,_8),u===ev||(u=vC(e)),H()):e.slice()},re.range=function(xe){return arguments.length?(i=Qy.call(xe),H()):i.slice()},re.rangeRound=function(xe){return i=Qy.call(xe),r=g8,H()},re.clamp=function(xe){return arguments.length?(u=xe?vC(e):ev,re):u!==ev},re.interpolate=function(xe){return arguments.length?(r=xe,H()):r},re.unknown=function(xe){return arguments.length?(a=xe,re):a},function(xe,ke){return n=xe,t=ke,H()}}function gC(e,i){return aw()(e,i)}var x8=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Pb(e){if(!(i=x8.exec(e)))throw new Error("invalid format: "+e);var i;return new sw({fill:i[1],align:i[2],sign:i[3],symbol:i[4],zero:i[5],width:i[6],comma:i[7],precision:i[8]&&i[8].slice(1),trim:i[9],type:i[10]})}Pb.prototype=sw.prototype;function sw(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}sw.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function w8(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Ib(e,i){if((r=(e=i?e.toExponential(i-1):e.toExponential()).indexOf("e"))<0)return null;var r,n=e.slice(0,r);return[n.length>1?n[0]+n.slice(2):n,+e.slice(r+1)]}function B1(e){return e=Ib(Math.abs(e)),e?e[1]:NaN}function E8(e,i){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(B1(i)/3)))*3-B1(Math.abs(e)))}function S8(e,i){return function(r,n){for(var t=r.length,a=[],u=0,c=e[0],m=0;t>0&&c>0&&(m+c+1>n&&(c=Math.max(1,n-m)),a.push(r.substring(t-=c,t+c)),!((m+=c+1)>n));)c=e[u=(u+1)%e.length];return a.reverse().join(i)}}function C8(e){return function(i){return i.replace(/[0-9]/g,function(r){return e[+r]})}}function T8(e){e:for(var i=e.length,r=1,n=-1,t;r0&&(n=0);break}return n>0?e.slice(0,n)+e.slice(t+1):e}var yC;function M8(e,i){var r=Ib(e,i);if(!r)return e+"";var n=r[0],t=r[1],a=t-(yC=Math.max(-8,Math.min(8,Math.floor(t/3)))*3)+1,u=n.length;return a===u?n:a>u?n+new Array(a-u+1).join("0"):a>0?n.slice(0,a)+"."+n.slice(a):"0."+new Array(1-a).join("0")+Ib(e,Math.max(0,i+a-1))[0]}function _C(e,i){var r=Ib(e,i);if(!r)return e+"";var n=r[0],t=r[1];return t<0?"0."+new Array(-t).join("0")+n:n.length>t+1?n.slice(0,t+1)+"."+n.slice(t+1):n+new Array(t-n.length+2).join("0")}var AC={"%":function(e,i){return(e*100).toFixed(i)},b:function(e){return Math.round(e).toString(2)},c:function(e){return e+""},d:w8,e:function(e,i){return e.toExponential(i)},f:function(e,i){return e.toFixed(i)},g:function(e,i){return e.toPrecision(i)},o:function(e){return Math.round(e).toString(8)},p:function(e,i){return _C(e*100,i)},r:_C,s:M8,X:function(e){return Math.round(e).toString(16).toUpperCase()},x:function(e){return Math.round(e).toString(16)}};function bC(e){return e}var xC=Array.prototype.map,wC=["y","z","a","f","p","n","\xB5","m","","k","M","G","T","P","E","Z","Y"];function P8(e){var i=e.grouping===void 0||e.thousands===void 0?bC:S8(xC.call(e.grouping,Number),e.thousands+""),r=e.currency===void 0?"":e.currency[0]+"",n=e.currency===void 0?"":e.currency[1]+"",t=e.decimal===void 0?".":e.decimal+"",a=e.numerals===void 0?bC:C8(xC.call(e.numerals,String)),u=e.percent===void 0?"%":e.percent+"",c=e.minus===void 0?"-":e.minus+"",m=e.nan===void 0?"NaN":e.nan+"";function E(re){re=Pb(re);var xe=re.fill,ke=re.align,rt=re.sign,vt=re.symbol,It=re.zero,er=re.width,Ar=re.comma,Or=re.precision,rn=re.trim,Ln=re.type;Ln==="n"?(Ar=!0,Ln="g"):AC[Ln]||(Or===void 0&&(Or=12),rn=!0,Ln="g"),(It||xe==="0"&&ke==="=")&&(It=!0,xe="0",ke="=");var wn=vt==="$"?r:vt==="#"&&/[boxX]/.test(Ln)?"0"+Ln.toLowerCase():"",Cn=vt==="$"?n:/[%p]/.test(Ln)?u:"",qn=AC[Ln],Si=/[defgprs%]/.test(Ln);Or=Or===void 0?6:/[gprs]/.test(Ln)?Math.max(1,Math.min(21,Or)):Math.max(0,Math.min(20,Or));function po(Ao){var ma=wn,Ya=Cn,fs,bf,th;if(Ln==="c")Ya=qn(Ao)+Ya,Ao="";else{Ao=+Ao;var Yh=Ao<0||1/Ao<0;if(Ao=isNaN(Ao)?m:qn(Math.abs(Ao),Or),rn&&(Ao=T8(Ao)),Yh&&+Ao==0&&rt!=="+"&&(Yh=!1),ma=(Yh?rt==="("?rt:c:rt==="-"||rt==="("?"":rt)+ma,Ya=(Ln==="s"?wC[8+yC/3]:"")+Ya+(Yh&&rt==="("?")":""),Si){for(fs=-1,bf=Ao.length;++fsth||th>57){Ya=(th===46?t+Ao.slice(fs+1):Ao.slice(fs))+Ya,Ao=Ao.slice(0,fs);break}}}Ar&&!It&&(Ao=i(Ao,1/0));var Lp=ma.length+Ao.length+Ya.length,vd=Lp>1)+ma+Ao+Ya+vd.slice(Lp);break;default:Ao=vd+ma+Ao+Ya;break}return a(Ao)}return po.toString=function(){return re+""},po}function H(re,xe){var ke=E((re=Pb(re),re.type="f",re)),rt=Math.max(-8,Math.min(8,Math.floor(B1(xe)/3)))*3,vt=Math.pow(10,-rt),It=wC[8+rt/3];return function(er){return ke(vt*er)+It}}return{format:E,formatPrefix:H}}var Rb,uw,EC;I8({decimal:".",thousands:",",grouping:[3],currency:["$",""],minus:"-"});function I8(e){return Rb=P8(e),uw=Rb.format,EC=Rb.formatPrefix,Rb}function R8(e,i){return e=Math.abs(e),i=Math.abs(i)-e,Math.max(0,B1(i)-B1(e))+1}function O8(e){return Math.max(0,-B1(Math.abs(e)))}function L8(e,i,r,n){var t=(0,Gm.ly)(e,i,r),a;switch(n=Pb(n==null?",f":n),n.type){case"s":{var u=Math.max(Math.abs(e),Math.abs(i));return n.precision==null&&!isNaN(a=E8(t,u))&&(n.precision=a),EC(n,u)}case"":case"e":case"g":case"p":case"r":{n.precision==null&&!isNaN(a=R8(t,Math.max(Math.abs(e),Math.abs(i))))&&(n.precision=a-(n.type==="e"));break}case"f":case"%":{n.precision==null&&!isNaN(a=O8(t))&&(n.precision=a-(n.type==="%")*2);break}}return uw(n)}function N_(e){var i=e.domain;return e.ticks=function(r){var n=i();return(0,Gm.sd)(n[0],n[n.length-1],r==null?10:r)},e.tickFormat=function(r,n){var t=i();return L8(t[0],t[t.length-1],r==null?10:r,n)},e.nice=function(r){r==null&&(r=10);var n=i(),t=0,a=n.length-1,u=n[t],c=n[a],m;return c0?(u=Math.floor(u/m)*m,c=Math.ceil(c/m)*m,m=(0,Gm.G9)(u,c,r)):m<0&&(u=Math.ceil(u*m)/m,c=Math.floor(c*m)/m,m=(0,Gm.G9)(u,c,r)),m>0?(n[t]=Math.floor(u/m)*m,n[a]=Math.ceil(c/m)*m,i(n)):m<0&&(n[t]=Math.ceil(u*m)/m,n[a]=Math.floor(c*m)/m,i(n)),e},e}function SC(){var e=gC(ev,ev);return e.copy=function(){return Mb(e,SC())},Ay.apply(e,arguments),N_(e)}function D8(e){var i;function r(n){return isNaN(n=+n)?i:n}return r.invert=r,r.domain=r.range=function(n){return arguments.length?(e=map.call(n,number),r):e.slice()},r.unknown=function(n){return arguments.length?(i=n,r):i},r.copy=function(){return D8(e).unknown(i)},e=arguments.length?map.call(e,number):[0,1],linearish(r)}function CC(e,i){e=e.slice();var r=0,n=e.length-1,t=e[r],a=e[n],u;return a0){for(;xeH)break;Ar.push(It)}}else for(;xe=1;--vt)if(It=rt*vt,!(ItH)break;Ar.push(It)}}else Ar=(0,Gm.sd)(xe,ke,Math.min(ke-xe,er)).map(a);return re?Ar.reverse():Ar},i.tickFormat=function(c,m){if(m==null&&(m=n===10?".0e":","),typeof m!="function"&&(m=uw(m)),c===1/0)return m;c==null&&(c=10);var E=Math.max(1,n*c/i.ticks().length);return function(H){var re=H/a(Math.round(t(H)));return re*n0?r[c-1]:e[0],c=r?[n[r-1],i]:[n[E-1],n[E]]},u.unknown=function(m){return arguments.length&&(a=m),u},u.thresholds=function(){return n.slice()},u.copy=function(){return kC().domain([e,i]).range(t).unknown(a)},Ay.apply(N_(u),arguments)}function FC(){var e=[.5],i=[0,1],r,n=1;function t(a){return a<=a?i[(0,Gm.b4)(e,a,0,n)]:r}return t.domain=function(a){return arguments.length?(e=Qy.call(a),n=Math.min(e.length,i.length-1),t):e.slice()},t.range=function(a){return arguments.length?(i=Qy.call(a),n=Math.min(e.length,i.length-1),t):i.slice()},t.invertExtent=function(a){var u=i.indexOf(a);return[e[u-1],e[u]]},t.unknown=function(a){return arguments.length?(r=a,t):r},t.copy=function(){return FC().domain(e).range(i).unknown(r)},Ay.apply(t,arguments)}var cw=new Date,fw=new Date;function av(e,i,r,n){function t(a){return e(a=arguments.length===0?new Date:new Date(+a)),a}return t.floor=function(a){return e(a=new Date(+a)),a},t.ceil=function(a){return e(a=new Date(a-1)),i(a,1),e(a),a},t.round=function(a){var u=t(a),c=t.ceil(a);return a-u0))return m;do m.push(E=new Date(+a)),i(a,c),e(a);while(E=u)for(;e(u),!a(u);)u.setTime(u-1)},function(u,c){if(u>=u)if(c<0)for(;++c<=0;)for(;i(u,-1),!a(u););else for(;--c>=0;)for(;i(u,1),!a(u););})},r&&(t.count=function(a,u){return cw.setTime(+a),fw.setTime(+u),e(cw),e(fw),Math.floor(r(cw,fw))},t.every=function(a){return a=Math.floor(a),!isFinite(a)||!(a>0)?null:a>1?t.filter(n?function(u){return n(u)%a===0}:function(u){return t.count(0,u)%a===0}):t}),t}var hw=av(function(e){e.setMonth(0,1),e.setHours(0,0,0,0)},function(e,i){e.setFullYear(e.getFullYear()+i)},function(e,i){return i.getFullYear()-e.getFullYear()},function(e){return e.getFullYear()});hw.every=function(e){return!isFinite(e=Math.floor(e))||!(e>0)?null:av(function(i){i.setFullYear(Math.floor(i.getFullYear()/e)*e),i.setMonth(0,1),i.setHours(0,0,0,0)},function(i,r){i.setFullYear(i.getFullYear()+r*e)})};var N1=hw,MV=hw.range,BC=av(function(e){e.setDate(1),e.setHours(0,0,0,0)},function(e,i){e.setMonth(e.getMonth()+i)},function(e,i){return i.getMonth()-e.getMonth()+(i.getFullYear()-e.getFullYear())*12},function(e){return e.getMonth()}),G8=BC,PV=BC.range,Ob=1e3,z_=6e4,NC=36e5,zC=864e5,ZC=6048e5;function Jy(e){return av(function(i){i.setDate(i.getDate()-(i.getDay()+7-e)%7),i.setHours(0,0,0,0)},function(i,r){i.setDate(i.getDate()+r*7)},function(i,r){return(r-i-(r.getTimezoneOffset()-i.getTimezoneOffset())*z_)/ZC})}var dw=Jy(0),Lb=Jy(1),W8=Jy(2),X8=Jy(3),z1=Jy(4),Y8=Jy(5),K8=Jy(6),IV=dw.range,RV=Lb.range,OV=W8.range,LV=X8.range,DV=z1.range,kV=Y8.range,FV=K8.range,UC=av(function(e){e.setHours(0,0,0,0)},function(e,i){e.setDate(e.getDate()+i)},function(e,i){return(i-e-(i.getTimezoneOffset()-e.getTimezoneOffset())*z_)/zC},function(e){return e.getDate()-1}),pw=UC,BV=UC.range,jC=av(function(e){e.setTime(e-e.getMilliseconds()-e.getSeconds()*Ob-e.getMinutes()*z_)},function(e,i){e.setTime(+e+i*NC)},function(e,i){return(i-e)/NC},function(e){return e.getHours()}),q8=jC,NV=jC.range,VC=av(function(e){e.setTime(e-e.getMilliseconds()-e.getSeconds()*Ob)},function(e,i){e.setTime(+e+i*z_)},function(e,i){return(i-e)/z_},function(e){return e.getMinutes()}),Q8=VC,zV=VC.range,$C=av(function(e){e.setTime(e-e.getMilliseconds())},function(e,i){e.setTime(+e+i*Ob)},function(e,i){return(i-e)/Ob},function(e){return e.getUTCSeconds()}),J8=$C,ZV=$C.range,Db=av(function(){},function(e,i){e.setTime(+e+i)},function(e,i){return i-e});Db.every=function(e){return e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?av(function(i){i.setTime(Math.floor(i/e)*e)},function(i,r){i.setTime(+i+r*e)},function(i,r){return(r-i)/e}):Db};var ek=Db,UV=Db.range;function e1(e){return av(function(i){i.setUTCDate(i.getUTCDate()-(i.getUTCDay()+7-e)%7),i.setUTCHours(0,0,0,0)},function(i,r){i.setUTCDate(i.getUTCDate()+r*7)},function(i,r){return(r-i)/ZC})}var HC=e1(0),kb=e1(1),tk=e1(2),rk=e1(3),Z1=e1(4),nk=e1(5),ik=e1(6),jV=HC.range,VV=kb.range,$V=tk.range,HV=rk.range,GV=Z1.range,WV=nk.range,XV=ik.range,GC=av(function(e){e.setUTCHours(0,0,0,0)},function(e,i){e.setUTCDate(e.getUTCDate()+i)},function(e,i){return(i-e)/zC},function(e){return e.getUTCDate()-1}),WC=GC,YV=GC.range,mw=av(function(e){e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},function(e,i){e.setUTCFullYear(e.getUTCFullYear()+i)},function(e,i){return i.getUTCFullYear()-e.getUTCFullYear()},function(e){return e.getUTCFullYear()});mw.every=function(e){return!isFinite(e=Math.floor(e))||!(e>0)?null:av(function(i){i.setUTCFullYear(Math.floor(i.getUTCFullYear()/e)*e),i.setUTCMonth(0,1),i.setUTCHours(0,0,0,0)},function(i,r){i.setUTCFullYear(i.getUTCFullYear()+r*e)})};var Z_=mw,KV=mw.range;function vw(e){if(0<=e.y&&e.y<100){var i=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return i.setFullYear(e.y),i}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function gw(e){if(0<=e.y&&e.y<100){var i=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return i.setUTCFullYear(e.y),i}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function U_(e,i,r){return{y:e,m:i,d:r,H:0,M:0,S:0,L:0}}function ok(e){var i=e.dateTime,r=e.date,n=e.time,t=e.periods,a=e.days,u=e.shortDays,c=e.months,m=e.shortMonths,E=j_(t),H=V_(t),re=j_(a),xe=V_(a),ke=j_(u),rt=V_(u),vt=j_(c),It=V_(c),er=j_(m),Ar=V_(m),Or={a:Yh,A:Lp,b:vd,B:Tm,c:null,d:JC,e:JC,f:Mk,g:Nk,G:Zk,H:Sk,I:Ck,j:Tk,L:e3,m:Pk,M:Ik,p:Iy,q:Kg,Q:a3,s:s3,S:Rk,u:Ok,U:Lk,V:Dk,w:kk,W:Fk,x:null,X:null,y:Bk,Y:zk,Z:Uk,"%":o3},rn={a:d_,A:p_,b:K0,B:gv,c:null,d:r3,e:r3,f:Hk,g:t7,G:n7,H:jk,I:Vk,j:$k,L:n3,m:Gk,M:Wk,p:k2,q:F2,Q:a3,s:s3,S:Xk,u:Yk,U:Kk,V:qk,w:Qk,W:Jk,x:null,X:null,y:e7,Y:r7,Z:i7,"%":o3},Ln={a:po,A:Ao,b:ma,B:Ya,c:fs,d:qC,e:qC,f:bk,g:KC,G:YC,H:QC,I:QC,j:gk,L:Ak,m:vk,M:yk,p:Si,q:mk,Q:wk,s:Ek,S:_k,u:ck,U:fk,V:hk,w:lk,W:dk,x:bf,X:th,y:KC,Y:YC,Z:pk,"%":xk};Or.x=wn(r,Or),Or.X=wn(n,Or),Or.c=wn(i,Or),rn.x=wn(r,rn),rn.X=wn(n,rn),rn.c=wn(i,rn);function wn(mh,Cp){return function(l0){var hc=[],yv=-1,q0=0,Sv=mh.length,Cv,f1,DM;for(l0 instanceof Date||(l0=new Date(+l0));++yv53)return null;"w"in hc||(hc.w=1),"Z"in hc?(q0=gw(U_(hc.y,0,1)),Sv=q0.getUTCDay(),q0=Sv>4||Sv===0?kb.ceil(q0):kb(q0),q0=WC.offset(q0,(hc.V-1)*7),hc.y=q0.getUTCFullYear(),hc.m=q0.getUTCMonth(),hc.d=q0.getUTCDate()+(hc.w+6)%7):(q0=vw(U_(hc.y,0,1)),Sv=q0.getDay(),q0=Sv>4||Sv===0?Lb.ceil(q0):Lb(q0),q0=pw.offset(q0,(hc.V-1)*7),hc.y=q0.getFullYear(),hc.m=q0.getMonth(),hc.d=q0.getDate()+(hc.w+6)%7)}else("W"in hc||"U"in hc)&&("w"in hc||(hc.w="u"in hc?hc.u%7:"W"in hc?1:0),Sv="Z"in hc?gw(U_(hc.y,0,1)).getUTCDay():vw(U_(hc.y,0,1)).getDay(),hc.m=0,hc.d="W"in hc?(hc.w+6)%7+hc.W*7-(Sv+5)%7:hc.w+hc.U*7-(Sv+6)%7);return"Z"in hc?(hc.H+=hc.Z/100|0,hc.M+=hc.Z%100,gw(hc)):vw(hc)}}function qn(mh,Cp,l0,hc){for(var yv=0,q0=Cp.length,Sv=l0.length,Cv,f1;yv=Sv)return-1;if(Cv=Cp.charCodeAt(yv++),Cv===37){if(Cv=Cp.charAt(yv++),f1=Ln[Cv in XC?Cp.charAt(yv++):Cv],!f1||(hc=f1(mh,l0,hc))<0)return-1}else if(Cv!=l0.charCodeAt(hc++))return-1}return hc}function Si(mh,Cp,l0){var hc=E.exec(Cp.slice(l0));return hc?(mh.p=H[hc[0].toLowerCase()],l0+hc[0].length):-1}function po(mh,Cp,l0){var hc=ke.exec(Cp.slice(l0));return hc?(mh.w=rt[hc[0].toLowerCase()],l0+hc[0].length):-1}function Ao(mh,Cp,l0){var hc=re.exec(Cp.slice(l0));return hc?(mh.w=xe[hc[0].toLowerCase()],l0+hc[0].length):-1}function ma(mh,Cp,l0){var hc=er.exec(Cp.slice(l0));return hc?(mh.m=Ar[hc[0].toLowerCase()],l0+hc[0].length):-1}function Ya(mh,Cp,l0){var hc=vt.exec(Cp.slice(l0));return hc?(mh.m=It[hc[0].toLowerCase()],l0+hc[0].length):-1}function fs(mh,Cp,l0){return qn(mh,i,Cp,l0)}function bf(mh,Cp,l0){return qn(mh,r,Cp,l0)}function th(mh,Cp,l0){return qn(mh,n,Cp,l0)}function Yh(mh){return u[mh.getDay()]}function Lp(mh){return a[mh.getDay()]}function vd(mh){return m[mh.getMonth()]}function Tm(mh){return c[mh.getMonth()]}function Iy(mh){return t[+(mh.getHours()>=12)]}function Kg(mh){return 1+~~(mh.getMonth()/3)}function d_(mh){return u[mh.getUTCDay()]}function p_(mh){return a[mh.getUTCDay()]}function K0(mh){return m[mh.getUTCMonth()]}function gv(mh){return c[mh.getUTCMonth()]}function k2(mh){return t[+(mh.getUTCHours()>=12)]}function F2(mh){return 1+~~(mh.getUTCMonth()/3)}return{format:function(mh){var Cp=wn(mh+="",Or);return Cp.toString=function(){return mh},Cp},parse:function(mh){var Cp=Cn(mh+="",!1);return Cp.toString=function(){return mh},Cp},utcFormat:function(mh){var Cp=wn(mh+="",rn);return Cp.toString=function(){return mh},Cp},utcParse:function(mh){var Cp=Cn(mh+="",!0);return Cp.toString=function(){return mh},Cp}}}var XC={"-":"",_:" ",0:"0"},jm=/^\s*\d+/,ak=/^%/,sk=/[\\^$*+?|[\]().{}]/g;function s0(e,i,r){var n=e<0?"-":"",t=(n?-e:e)+"",a=t.length;return n+(a68?1900:2e3),r+n[0].length):-1}function pk(e,i,r){var n=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(i.slice(r,r+6));return n?(e.Z=n[1]?0:-(n[2]+(n[3]||"00")),r+n[0].length):-1}function mk(e,i,r){var n=jm.exec(i.slice(r,r+1));return n?(e.q=n[0]*3-3,r+n[0].length):-1}function vk(e,i,r){var n=jm.exec(i.slice(r,r+2));return n?(e.m=n[0]-1,r+n[0].length):-1}function qC(e,i,r){var n=jm.exec(i.slice(r,r+2));return n?(e.d=+n[0],r+n[0].length):-1}function gk(e,i,r){var n=jm.exec(i.slice(r,r+3));return n?(e.m=0,e.d=+n[0],r+n[0].length):-1}function QC(e,i,r){var n=jm.exec(i.slice(r,r+2));return n?(e.H=+n[0],r+n[0].length):-1}function yk(e,i,r){var n=jm.exec(i.slice(r,r+2));return n?(e.M=+n[0],r+n[0].length):-1}function _k(e,i,r){var n=jm.exec(i.slice(r,r+2));return n?(e.S=+n[0],r+n[0].length):-1}function Ak(e,i,r){var n=jm.exec(i.slice(r,r+3));return n?(e.L=+n[0],r+n[0].length):-1}function bk(e,i,r){var n=jm.exec(i.slice(r,r+6));return n?(e.L=Math.floor(n[0]/1e3),r+n[0].length):-1}function xk(e,i,r){var n=ak.exec(i.slice(r,r+1));return n?r+n[0].length:-1}function wk(e,i,r){var n=jm.exec(i.slice(r));return n?(e.Q=+n[0],r+n[0].length):-1}function Ek(e,i,r){var n=jm.exec(i.slice(r));return n?(e.s=+n[0],r+n[0].length):-1}function JC(e,i){return s0(e.getDate(),i,2)}function Sk(e,i){return s0(e.getHours(),i,2)}function Ck(e,i){return s0(e.getHours()%12||12,i,2)}function Tk(e,i){return s0(1+pw.count(N1(e),e),i,3)}function e3(e,i){return s0(e.getMilliseconds(),i,3)}function Mk(e,i){return e3(e,i)+"000"}function Pk(e,i){return s0(e.getMonth()+1,i,2)}function Ik(e,i){return s0(e.getMinutes(),i,2)}function Rk(e,i){return s0(e.getSeconds(),i,2)}function Ok(e){var i=e.getDay();return i===0?7:i}function Lk(e,i){return s0(dw.count(N1(e)-1,e),i,2)}function t3(e){var i=e.getDay();return i>=4||i===0?z1(e):z1.ceil(e)}function Dk(e,i){return e=t3(e),s0(z1.count(N1(e),e)+(N1(e).getDay()===4),i,2)}function kk(e){return e.getDay()}function Fk(e,i){return s0(Lb.count(N1(e)-1,e),i,2)}function Bk(e,i){return s0(e.getFullYear()%100,i,2)}function Nk(e,i){return e=t3(e),s0(e.getFullYear()%100,i,2)}function zk(e,i){return s0(e.getFullYear()%1e4,i,4)}function Zk(e,i){var r=e.getDay();return e=r>=4||r===0?z1(e):z1.ceil(e),s0(e.getFullYear()%1e4,i,4)}function Uk(e){var i=e.getTimezoneOffset();return(i>0?"-":(i*=-1,"+"))+s0(i/60|0,"0",2)+s0(i%60,"0",2)}function r3(e,i){return s0(e.getUTCDate(),i,2)}function jk(e,i){return s0(e.getUTCHours(),i,2)}function Vk(e,i){return s0(e.getUTCHours()%12||12,i,2)}function $k(e,i){return s0(1+WC.count(Z_(e),e),i,3)}function n3(e,i){return s0(e.getUTCMilliseconds(),i,3)}function Hk(e,i){return n3(e,i)+"000"}function Gk(e,i){return s0(e.getUTCMonth()+1,i,2)}function Wk(e,i){return s0(e.getUTCMinutes(),i,2)}function Xk(e,i){return s0(e.getUTCSeconds(),i,2)}function Yk(e){var i=e.getUTCDay();return i===0?7:i}function Kk(e,i){return s0(HC.count(Z_(e)-1,e),i,2)}function i3(e){var i=e.getUTCDay();return i>=4||i===0?Z1(e):Z1.ceil(e)}function qk(e,i){return e=i3(e),s0(Z1.count(Z_(e),e)+(Z_(e).getUTCDay()===4),i,2)}function Qk(e){return e.getUTCDay()}function Jk(e,i){return s0(kb.count(Z_(e)-1,e),i,2)}function e7(e,i){return s0(e.getUTCFullYear()%100,i,2)}function t7(e,i){return e=i3(e),s0(e.getUTCFullYear()%100,i,2)}function r7(e,i){return s0(e.getUTCFullYear()%1e4,i,4)}function n7(e,i){var r=e.getUTCDay();return e=r>=4||r===0?Z1(e):Z1.ceil(e),s0(e.getUTCFullYear()%1e4,i,4)}function i7(){return"+0000"}function o3(){return"%"}function a3(e){return+e}function s3(e){return Math.floor(+e/1e3)}var U1,u3,o7,a7,s7;u7({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function u7(e){return U1=ok(e),u3=U1.format,o7=U1.parse,a7=U1.utcFormat,s7=U1.utcParse,U1}var $_=1e3,H_=$_*60,G_=H_*60,W_=G_*24,l7=W_*7,l3=W_*30,yw=W_*365;function c7(e){return new Date(e)}function f7(e){return e instanceof Date?+e:+new Date(+e)}function c3(e,i,r,n,t,a,u,c,m){var E=gC(ev,ev),H=E.invert,re=E.domain,xe=m(".%L"),ke=m(":%S"),rt=m("%I:%M"),vt=m("%I %p"),It=m("%a %d"),er=m("%b %d"),Ar=m("%B"),Or=m("%Y"),rn=[[u,1,$_],[u,5,5*$_],[u,15,15*$_],[u,30,30*$_],[a,1,H_],[a,5,5*H_],[a,15,15*H_],[a,30,30*H_],[t,1,G_],[t,3,3*G_],[t,6,6*G_],[t,12,12*G_],[n,1,W_],[n,2,2*W_],[r,1,l7],[i,1,l3],[i,3,3*l3],[e,1,yw]];function Ln(Cn){return(u(Cn)2){var re=E.scale.ticks(u.values.length);E.scale.domain(re)}u.values?E.scale.range(u.values):E.scale.range(E.option.domain);break;case ch.QUANTILE:case ch.QUANTIZE:case ch.THRESHOLD:E.scale.range(u.values);break;case ch.IDENTITY:break;case ch.CAT:u.values?E.scale.range(u.values):E.scale.range(E.option.domain);break;case ch.DIVERGING:case ch.SEQUENTIAL:E.scale.interpolator(a8(u.values));break}}if(u.values==="text"){var xe;E.scale.range((xe=E.option)===null||xe===void 0?void 0:xe.domain)}})):(u.type=_d.CONSTANT,u.defaultValues=m.map(function(E,H){return E.scale(u.names[H])})),u.scalers=m.map(function(E){return{field:E.field,func:E.scale,option:E.option}}),a.needRescale=!1}})}},{key:"parseFields",value:function(r){return Array.isArray(r)?r:y7(r)?r.split("*"):[r]}},{key:"createScale",value:function(r,n,t,a){var u,c,m=this.scaleOptions[n]&&((u=this.scaleOptions[n])===null||u===void 0?void 0:u.field)===r?this.scaleOptions[n]:this.scaleOptions[r],E={field:r,scale:void 0,type:_d.VARIABLE,option:m};if(!a||!a.length)return m&&m.type?E.scale=this.createDefaultScale(m):(E.scale=Cb([r]),E.type=_d.CONSTANT),E;var H=(c=a.find(function(ke){return!_w(ke[r])}))===null||c===void 0?void 0:c[r];if(this.isNumber(r)||_w(H)&&!m)E.scale=Cb([r]),E.type=_d.CONSTANT;else{var re=m&&m.type||this.getDefaultType(H);t==="text"&&(re=ch.CAT),t===void 0&&(re=ch.IDENTITY);var xe=this.createScaleConfig(re,r,m,a);E.scale=this.createDefaultScale(xe),E.option=xe}return E}},{key:"getDefaultType",value:function(r){var n=ch.LINEAR;return typeof r=="string"&&(n=A7.test(r)?ch.TIME:ch.CAT),n}},{key:"createScaleConfig",value:function(r,n,t,a){var u={type:r},c=[];if(r===ch.QUANTILE){var m=new Map;a==null||a.forEach(function(re){m.set(re._id,re[n])}),c=Array.from(m.values())}else c=(a==null?void 0:a.map(function(re){return re[n]}))||[];if(t!=null&&t.domain)u.domain=t==null?void 0:t.domain;else if(r===ch.CAT||r===ch.IDENTITY)u.domain=_7(c);else if(r===ch.QUANTILE)u.domain=c;else if(r===ch.DIVERGING){var E=(0,Gm.We)(c),H=(t==null?void 0:t.neutral)!==void 0?t==null?void 0:t.neutral:(E[0]+E[1])/2;u.domain=[E[0],H,E[1]]}else u.domain=(0,Gm.We)(c);return(0,Se.Z)((0,Se.Z)({},u),t)}},{key:"createDefaultScale",value:function(r){var n=r.type,t=r.domain,a=r.unknown,u=r.clamp,c=r.nice,m=b7[n]();return t&&m.domain&&m.domain(t),a&&m.unknown(a),u!==void 0&&m.clamp&&m.clamp(u),c!==void 0&&m.nice&&m.nice(c),m}}]),e}())||g3),y3,_3,w7=(y3=(0,sa.b2)(),y3(_3=function(){function e(){(0,We.Z)(this,e)}return(0,ot.Z)(e,[{key:"apply",value:function(r){r.hooks.beforeRender.tap("LayerAnimateStylePlugin",function(){var n=r.animateStatus;n&&r.models.forEach(function(t){t.addUniforms((0,Se.Z)({},r.layerModel.getAnimateUniforms()))})})}}]),e}())||_3),A3,b3,E7=(A3=(0,sa.b2)(),A3(b3=function(){function e(){(0,We.Z)(this,e)}return(0,ot.Z)(e,[{key:"apply",value:function(r){r.hooks.afterInit.tap("LayerMaskPlugin",function(){var n=r.getLayerConfig(),t=n.maskLayers,a=n.enableMask;if(!r.tileLayer&&t&&t.length>0){var u;(u=r.masks).push.apply(u,(0,On.Z)(t)),r.updateLayerConfig({mask:a})}})}}]),e}())||b3),S7=function(){function e(i){var r=i.rendererService,n=i.layerService,t=i.parent;(0,We.Z)(this,e),(0,St.Z)(this,"tileResource",new Map),(0,St.Z)(this,"layerTiles",[]),this.rendererService=r,this.layerService=n,this.parent=t}return(0,ot.Z)(e,[{key:"tiles",get:function(){return this.layerTiles}},{key:"hasTile",value:function(r){return this.layerTiles.some(function(n){return n.key===r})}},{key:"addTile",value:function(r){this.layerTiles.push(r)}},{key:"getTile",value:function(r){return this.layerTiles.find(function(n){return n.key===r})}},{key:"getVisibleTileBylngLat",value:function(r){return this.layerTiles.find(function(n){return n.isLoaded&&n.visible&&n.lnglatInBounds(r)})}},{key:"removeTile",value:function(r){var n=this.layerTiles.findIndex(function(a){return a.key===r}),t=this.layerTiles.splice(n,1);t[0]&&t[0].destroy()}},{key:"updateTileVisible",value:function(r){var n=this.getTile(r.key);if(r.isVisible)if(r.parent){var t=this.isChildrenLoaded(r.parent);n==null||n.updateVisible(t)}else n==null||n.updateVisible(!0);else if(r.parent){var a=this.isChildrenLoaded(r.parent);n==null||n.updateVisible(!a)}else n==null||n.updateVisible(!1)}},{key:"isParentLoaded",value:function(r){var n=r.parent;if(!n)return!0;var t=this.getTile(n==null?void 0:n.key);return!!(t!=null&&t.isLoaded)}},{key:"isChildrenLoaded",value:function(r){var n=this,t=r==null?void 0:r.children;return t.length===0?!0:t.every(function(a){var u=n.getTile(a==null?void 0:a.key);return u?(u==null?void 0:u.isLoaded)===!0:!0})}},{key:"render",value:function(){var i=(0,Li.Z)(Ur().mark(function n(){var t=this,a,u;return Ur().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return a=this.getRenderLayers(),u=a.map(function(){var E=(0,Li.Z)(Ur().mark(function H(re){return Ur().wrap(function(ke){for(;;)switch(ke.prev=ke.next){case 0:return ke.next=2,t.layerService.renderTileLayer(re);case 2:case"end":return ke.stop()}},H)}));return function(H){return E.apply(this,arguments)}}()),m.next=4,Promise.all(u);case 4:case"end":return m.stop()}},n,this)}));function r(){return i.apply(this,arguments)}return r}()},{key:"getRenderLayers",value:function(){var r=this.layerTiles.filter(function(t){return t.visible&&t.isLoaded}),n=[];return r.map(function(t){return n.push.apply(n,(0,On.Z)(t.getLayers()))}),n}},{key:"getLayers",value:function(){var r=this.layerTiles.filter(function(t){return t.isLoaded}),n=[];return r.map(function(t){return n.push.apply(n,(0,On.Z)(t.getLayers()))}),n}},{key:"getTiles",value:function(){return this.layerTiles}},{key:"destroy",value:function(){this.layerTiles.forEach(function(r){return r.destroy()}),this.tileResource.clear()}}]),e}(),C7=A(35486),T7=function(){function e(){(0,We.Z)(this,e)}return(0,ot.Z)(e,[{key:"getCombineFeature",value:function(r){var n=null,t=r[0];return r.map(function(a){var u=Ku.yu(a.coordinates);n===null?n=u:n=(0,C7.Z)(n,u)}),t&&(n.properties=(0,Se.Z)({},t)),n}}]),e}(),Y_="select",K_="active",M7=function(){function e(i){var r=i.layerService,n=i.tileLayerService,t=i.parent;(0,We.Z)(this,e),(0,St.Z)(this,"tilePickID",new Map),this.layerService=r,this.tileLayerService=n,this.parent=t,this.tileSourceService=new T7}return(0,ot.Z)(e,[{key:"pickRender",value:function(r){var n=this.tileLayerService.getVisibleTileBylngLat(r.lngLat);if(n){var t=n.getMainLayer();t==null||t.layerPickService.pickRender(r)}}},{key:"pick",value:function(){var i=(0,Li.Z)(Ur().mark(function n(t,a){var u,c,m,E;return Ur().wrap(function(re){for(;;)switch(re.prev=re.next){case 0:if(u=this.parent.getContainer(),c=u.get(sr.IPickingService),t.type!=="RasterLayer"){re.next=8;break}if(m=this.tileLayerService.getVisibleTileBylngLat(a.lngLat),!(m&&m.getMainLayer()!==void 0)){re.next=7;break}return E=m.getMainLayer(),re.abrupt("return",E.layerPickService.pickRasterLayer(E,a,this.parent));case 7:return re.abrupt("return",!1);case 8:return this.pickRender(a),re.abrupt("return",c.pickFromPickingFBO(t,a));case 10:case"end":return re.stop()}},n,this)}));function r(n,t){return i.apply(this,arguments)}return r}()},{key:"selectFeature",value:function(r){var n=(0,gi.Z)(r,3),t=n[0],a=n[1],u=n[2],c=this.color2PickId(t,a,u);this.tilePickID.set(Y_,c),this.updateHighLight(t,a,u,Y_)}},{key:"highlightPickedFeature",value:function(r){var n=(0,gi.Z)(r,3),t=n[0],a=n[1],u=n[2],c=this.color2PickId(t,a,u);this.tilePickID.set(K_,c),this.updateHighLight(t,a,u,K_)}},{key:"updateHighLight",value:function(r,n,t,a){this.tileLayerService.tiles.map(function(u){var c=u.getMainLayer();switch(a){case Y_:c==null||c.hooks.beforeSelect.call([r,n,t]);break;case K_:c==null||c.hooks.beforeHighlight.call([r,n,t]);break}})}},{key:"setPickState",value:function(){var r=this.tilePickID.get(Y_),n=this.tilePickID.get(K_);if(r){var t=this.pickId2Color(r),a=(0,gi.Z)(t,3),u=a[0],c=a[1],m=a[2];this.updateHighLight(u,c,m,Y_);return}if(n){var E=this.pickId2Color(n),H=(0,gi.Z)(E,3),re=H[0],xe=H[1],ke=H[2];this.updateHighLight(re,xe,ke,K_);return}}},{key:"color2PickId",value:function(r,n,t){return eo(new Uint8Array([r,n,t]))}},{key:"pickId2Color",value:function(r){return ba(r)}},{key:"getFeatureById",value:function(r){var n=this.tileLayerService.getTiles().filter(function(a){return a.visible}),t=[];return n.forEach(function(a){t.push.apply(t,(0,On.Z)(a.getFeatureById(r)))}),t}},{key:"pickRasterLayer",value:function(r,n,t){return!1}}]),e}();function P7(e){return e==="PolygonLayer"?_b:e==="LineLayer"?Yx:yb}function I7(e){return["PolygonLayer","LineLayer"].indexOf(e)!==-1}function R7(e){var i=O7();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function O7(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var t1=function(e){(0,Me.Z)(r,e);var i=R7(r);function r(n,t){var a;return(0,We.Z)(this,r),a=i.call(this),(0,St.Z)((0,Fr.Z)(a),"visible",!0),(0,St.Z)((0,Fr.Z)(a),"layers",[]),(0,St.Z)((0,Fr.Z)(a),"isLoaded",!1),(0,St.Z)((0,Fr.Z)(a),"tileMaskLayers",[]),a.parent=t,a.sourceTile=n,a.x=n.x,a.y=n.y,a.z=n.z,a.key="".concat(a.x,"_").concat(a.y,"_").concat(a.z),a}return(0,ot.Z)(r,[{key:"getLayers",value:function(){return this.layers}},{key:"styleUpdate",value:function(){}},{key:"lnglatInBounds",value:function(t){var a=(0,gi.Z)(this.sourceTile.bounds,4),u=a[0],c=a[1],m=a[2],E=a[3],H=t.lng,re=t.lat;return H>=u&&H<=m&&re>=c&&re<=E}},{key:"getLayerOptions",value:function(){var t,a=this.parent.getLayerConfig();return(0,Se.Z)((0,Se.Z)({},a),{},{textAllowOverlap:!0,autoFit:!1,maskLayers:this.getMaskLayer(),tileMask:I7(this.parent.type),mask:a.mask||((t=a.maskLayers)===null||t===void 0?void 0:t.length)!==0&&a.enableMask})}},{key:"getMaskLayer",value:function(){var t=this,a=this.parent.getLayerConfig(),u=a.maskLayers,c=[];return u==null||u.forEach(function(m){if(!m.tileLayer)return c.push(m),m;var E=m.tileLayer,H=E.getTile(t.sourceTile.key),re=H==null?void 0:H.getLayers()[0];re&&c.push(re)}),c}},{key:"addTileMask",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m;return Ur().wrap(function(H){for(;;)switch(H.prev=H.next){case 0:return u=new _b({name:"mask",visible:!0,enablePicking:!1}).source({type:"FeatureCollection",features:[this.sourceTile.bboxPolygon]},{parser:{type:"geojson",featureId:"id"}}).shape("fill").color("#0f0").style({opacity:.5}),c=Rm(this.parent.sceneContainer),u.setContainer(c,this.parent.sceneContainer),H.next=5,u.init();case 5:return this.tileMask=u,m=this.getMainLayer(),m!==void 0&&(m.tileMask=u),H.abrupt("return",u);case 9:case"end":return H.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"addMask",value:function(){var n=(0,Li.Z)(Ur().mark(function a(u,c){var m;return Ur().wrap(function(H){for(;;)switch(H.prev=H.next){case 0:return m=Rm(this.parent.sceneContainer),c.setContainer(m,this.parent.sceneContainer),H.next=4,c.init();case 4:u.addMask(c),this.tileMaskLayers.push(c);case 6:case"end":return H.stop()}},a,this)}));function t(a,u){return n.apply(this,arguments)}return t}()},{key:"addLayer",value:function(){var n=(0,Li.Z)(Ur().mark(function a(u){var c;return Ur().wrap(function(E){for(;;)switch(E.prev=E.next){case 0:return u.isTileLayer=!0,c=Rm(this.parent.sceneContainer),u.setContainer(c,this.parent.sceneContainer),this.layers.push(u),E.next=6,u.init();case 6:case"end":return E.stop()}},a,this)}));function t(a){return n.apply(this,arguments)}return t}()},{key:"updateVisible",value:function(t){this.visible=t,this.updateOptions("visible",t)}},{key:"updateOptions",value:function(t,a){this.layers.forEach(function(u){u.updateLayerConfig((0,St.Z)({},t,a))})}},{key:"getMainLayer",value:function(){return this.layers[0]}},{key:"getFeatures",value:function(t){return[]}},{key:"getFeatureById",value:function(t){return[]}},{key:"destroy",value:function(){var t;(t=this.tileMask)===null||t===void 0||t.destroy(),this.layers.forEach(function(a){return a.destroy()})}}]),r}(cu.EventEmitter);function L7(e){var i=D7();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function D7(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var k7=function(e){(0,Me.Z)(r,e);var i=L7(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"initTileLayer",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E;return Ur().wrap(function(re){for(;;)switch(re.prev=re.next){case 0:return u=this.getSourceOption(),c=u.data.features[0].properties,m=new Yx().source(u.data,u.options).size(1).shape("line").color("red"),E=new yb({minZoom:this.z-1,maxZoom:this.z+1,textAllowOverlap:!0}).source([c],{parser:{type:"json",x:"x",y:"y"}}).size(20).color("red").shape(this.key).style({stroke:"#fff",strokeWidth:2}),re.next=6,this.addLayer(m);case 6:return re.next=8,this.addLayer(E);case 8:this.isLoaded=!0;case 9:case"end":return re.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"getSourceOption",value:function(){var t=this.parent.getSource(),a=this.sourceTile.data.layers.testTile.features;return{data:{type:"FeatureCollection",features:a},options:{parser:{type:"geojson"},transforms:t.transforms}}}}]),r}(t1);function F7(e){var i=B7();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function B7(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var N7=function(e){(0,Me.Z)(r,e);var i=F7(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"initTileLayer",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E;return Ur().wrap(function(re){for(;;)switch(re.prev=re.next){case 0:return u=this.parent.getLayerAttributeConfig(),c=this.getLayerOptions(),m=this.getSourceOption(),E=new vS((0,Se.Z)({},c)).source(m.data,m.options),u&&Object.keys(u).forEach(function(xe){var ke,rt,vt=xe;E[vt]((ke=u[vt])===null||ke===void 0?void 0:ke.field,(rt=u[vt])===null||rt===void 0?void 0:rt.values)}),re.next=7,this.addLayer(E);case 7:this.isLoaded=!0;case 8:case"end":return re.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"getSourceOption",value:function(){var t=this.parent.getSource();return{data:this.sourceTile.data,options:{parser:{type:"image",extent:this.sourceTile.bounds},transforms:t.transforms}}}}]),r}(t1);function z7(e){var i=Z7();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function Z7(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var U7=function(e){(0,Me.Z)(r,e);var i=z7(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"initTileLayer",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E;return Ur().wrap(function(re){for(;;)switch(re.prev=re.next){case 0:return u=this.parent.getLayerAttributeConfig(),c=this.getLayerOptions(),m=this.getSourceOption(),E=new qx((0,Se.Z)({},c)).source(m.data,m.options),u&&Object.keys(u).forEach(function(xe){var ke,rt,vt=xe;E[vt]((ke=u[vt])===null||ke===void 0?void 0:ke.field,(rt=u[vt])===null||rt===void 0?void 0:rt.values)}),re.next=7,this.addLayer(E);case 7:this.isLoaded=!0;case 8:case"end":return re.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"getFeatures",value:function(t){if(!t)return[];var a=this.sourceTile.data;return a.getTileData(t)}},{key:"getSourceOption",value:function(){var t=this.parent.getSource(),a=this.parent.getLayerConfig(),u=a.sourceLayer,c=a.featureId,m=this.getFeatures(u);return{data:{type:"FeatureCollection",features:m},options:{parser:{type:"geojson",featureId:c},transforms:t.transforms}}}}]),r}(t1),j7=["rasterData"];function V7(e){var i=$7();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function $7(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var H7=function(e){(0,Me.Z)(r,e);var i=V7(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"initTileLayer",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E;return Ur().wrap(function(re){for(;;)switch(re.prev=re.next){case 0:return u=this.parent.getLayerAttributeConfig(),c=this.getLayerOptions(),m=this.getSourceOption(),E=new Ab((0,Se.Z)({},c)).source(m.data,m.options),u&&Object.keys(u).forEach(function(xe){var ke,rt,vt=xe;E[vt]((ke=u[vt])===null||ke===void 0?void 0:ke.field,(rt=u[vt])===null||rt===void 0?void 0:rt.values)}),re.next=7,this.addLayer(E);case 7:this.isLoaded=!0;case 8:case"end":return re.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"getSourceOption",value:function(){var t=this.parent.getSource(),a=this.sourceTile.data.data,u=a.rasterData,c=(0,X0.Z)(a,j7);return{data:u,options:{parser:(0,Se.Z)({type:"rasterRgb",extent:this.sourceTile.bounds},c),transforms:t.transforms}}}}]),r}(t1);function G7(e){var i=W7();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function W7(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var X7=function(e){(0,Me.Z)(r,e);var i=G7(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"initTileLayer",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E;return Ur().wrap(function(re){for(;;)switch(re.prev=re.next){case 0:return u=this.parent.getLayerAttributeConfig(),c=this.getLayerOptions(),m=this.getSourceOption(),E=new Ab((0,Se.Z)({},c)).source(m.data,m.options),u&&Object.keys(u).forEach(function(xe){var ke,rt,vt=xe;E[vt]((ke=u[vt])===null||ke===void 0?void 0:ke.field,(rt=u[vt])===null||rt===void 0?void 0:rt.values)}),re.next=7,this.addLayer(E);case 7:this.isLoaded=!0;case 8:case"end":return re.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"getSourceOption",value:function(){var t=this.parent.getSource();return{data:this.sourceTile.data,options:{parser:{type:"image",extent:this.sourceTile.bounds},transforms:t.transforms}}}}]),r}(t1),Y7=["rasterData"];function K7(e){var i=q7();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function q7(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var Q7={positions:[0,1],colors:["#000","#fff"]},J7=function(e){(0,Me.Z)(r,e);var i=K7(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"initTileLayer",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E,H,re,xe;return Ur().wrap(function(rt){for(;;)switch(rt.prev=rt.next){case 0:return u=this.parent.getLayerAttributeConfig(),c=this.getLayerOptions(),m=this.getSourceOption(),E=this.getLayerOptions(),H=E.rampColors,re=E.domain,this.colorTexture=this.parent.textureService.getColorTexture(H,re),xe=new Ab((0,Se.Z)((0,Se.Z)({},c),{},{colorTexture:this.colorTexture})).source(m.data,m.options),u&&Object.keys(u).forEach(function(vt){var It,er,Ar=vt;xe[Ar]((It=u[Ar])===null||It===void 0?void 0:It.field,(er=u[Ar])===null||er===void 0?void 0:er.values)}),rt.next=9,this.addLayer(xe);case 9:this.isLoaded=!0;case 10:case"end":return rt.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"getSourceOption",value:function(){var t=this.parent.getSource(),a=this.sourceTile.data.data,u=a.rasterData,c=(0,X0.Z)(a,Y7);return{data:u,options:{parser:(0,Se.Z)({type:"raster",extent:this.sourceTile.bounds},c),transforms:t.transforms}}}},{key:"styleUpdate",value:function(){for(var t=this,a=arguments.length,u=new Array(a),c=0;c=2&&!E&&(r.parent.updateLayerConfig({visible:!0}),r.layerService.reRender())}r.lastViewStates&&r.lastViewStates.zoom===c&&r.lastViewStates.latLonBounds.toString()===u.toString()||(r.lastViewStates={zoom:c,latLonBounds:u},(t=r.tilesetManager)===null||t===void 0||t.throttleUpdate(c,u))}}),(0,St.Z)(this,"viewchange",iF(this.mapchange,24)),this.parent=i;var n=this.parent.getContainer();this.rendererService=n.get(sr.IRendererService),this.layerService=n.get(sr.ILayerService),this.mapService=n.get(sr.IMapService),this.pickingService=n.get(sr.IPickingService),this.tileLayerService=new S7({rendererService:this.rendererService,layerService:this.layerService,parent:i}),this.tilePickService=new M7({tileLayerService:this.tileLayerService,layerService:this.layerService,parent:i}),this.parent.setLayerPickService(this.tilePickService),this.proxy(i),this.initTileSetManager()}return(0,ot.Z)(e,[{key:"initTileSetManager",value:function(){var r,n=this.parent.getSource();if(this.tilesetManager=n.tileset,this.initedTileset||(this.bindTilesetEvent(),this.initedTileset=!0),this.parent.isVisible()!==!1){var t=this.getCurrentView(),a=t.latLonBounds,u=t.zoom;(r=this.tilesetManager)===null||r===void 0||r.update(u,a)}}},{key:"getCurrentView",value:function(){var r=this.mapService.getBounds(),n=[r[0][0],r[0][1],r[1][0],r[1][1]],t=this.mapService.getZoom();return{latLonBounds:n,zoom:t}}},{key:"bindTilesetEvent",value:function(){var r=this;this.tilesetManager.on("tile-loaded",function(n){}),this.tilesetManager.on("tile-unload",function(n){r.tileUnLoad(n)}),this.tilesetManager.on("tile-error",function(n,t){r.tileError(n)}),this.tilesetManager.on("tile-update",function(){r.tileUpdate()}),this.mapService.on("zoomend",this.mapchange),this.mapService.on("moveend",this.viewchange)}},{key:"render",value:function(){this.tileLayerService.render()}},{key:"getLayers",value:function(){return this.tileLayerService.getLayers()}},{key:"getTiles",value:function(){return this.tileLayerService.getTiles()}},{key:"getTile",value:function(r){return this.tileLayerService.getTile(r)}},{key:"tileLoaded",value:function(r){}},{key:"tileError",value:function(r){console.warn("error:",r)}},{key:"destroy",value:function(){var r;this.mapService.off("zoomend",this.mapchange),this.mapService.off("moveend",this.viewchange),(r=this.tilesetManager)===null||r===void 0||r.destroy(),this.tileLayerService.destroy()}},{key:"reload",value:function(){var r;this.tilesetManager.clear();var n=this.getCurrentView(),t=n.latLonBounds,a=n.zoom;(r=this.tilesetManager)===null||r===void 0||r.update(a,t)}},{key:"tileUnLoad",value:function(r){this.tileLayerService.removeTile(r.key)}},{key:"tileUpdate",value:function(){var i=(0,Li.Z)(Ur().mark(function n(){var t=this,a,u,c;return Ur().wrap(function(E){for(;;)switch(E.prev=E.next){case 0:if(this.tilesetManager){E.next=2;break}return E.abrupt("return");case 2:return a=this.parent.getMinZoom(),u=this.parent.getMaxZoom(),c=this.tilesetManager.tiles.filter(function(H){return H.isLoaded}).filter(function(H){return H.isVisibleChange}).filter(function(H){return H.data}).filter(function(H){return H.z>=a&&H.z0&&arguments[0]!==void 0?arguments[0]:"vertical",a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:.5;this.container.classList.remove("horizontal","vertical"),this.container.classList.add(t),t==="horizontal"?(this.container.style.top=a*100+"%",this.container.style.left=""):(this.container.style.left=a*100+"%",this.container.style.top="")}},{key:"setLayers",value:function(t,a){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,c=t.filter(function(E){return a.includes(E)===!1}),m=a.filter(function(E){return t.includes(E)===!1});this.addMaskToLayers(c,u),this.removeMaskFromLayers(m)}},{key:"addMaskToLayers",value:function(t,a){var u=this;t.forEach(function(c){c.updateLayerConfig({maskInside:!a}),c.addMask(u.maskLayer)})}},{key:"removeMaskFromLayers",value:function(t){var a=this;t.forEach(function(u){u.updateLayerConfig({maskInside:!0}),u.removeMask(a.maskLayer)})}},{key:"getMaskGeoData",value:function(){var t=this.controlOption,a=t.ratio,u=a===void 0?.5:a,c=t.orientation,m=c===void 0?"vertical":c,E=m==="vertical",H=this.getBounds(),re=(0,gi.Z)(H,2),xe=re[0],ke=re[1],rt=(0,gi.Z)(xe,2),vt=rt[0],It=rt[1],er=(0,gi.Z)(ke,2),Ar=er[0],Or=er[1],rn;if(E){var Ln=vt+(Ar-vt)*u;rn=[[vt,Or],[Ln,Or],[Ln,It],xe,[vt,Or]]}else{var wn=this.getContainerSize(),Cn=this.mapsService.containerToLngLat([wn[0],wn[1]*u]),qn=Cn.lat;rn=[[vt,Or],ke,[Ar,qn],[vt,qn],[vt,Or]]}var Si={type:"FeatureCollection",features:[{type:"Feature",properties:{},geometry:{type:"Polygon",coordinates:[rn]}}]};return Si}},{key:"getContainerDOMRect",value:function(){var t,a=(t=this.mapsService.getContainer())===null||t===void 0?void 0:t.getBoundingClientRect();return a}},{key:"getContainerSize",value:function(){var t=this.mapsService.getSize();return t}},{key:"getBounds",value:function(){var t=this.mapsService.getBounds();return t}},{key:"addLayer",value:function(t){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,u=Array.isArray(t)?t:[t];if(a){var c,m=(c=this.controlOption.rightLayers).concat.apply(c,(0,On.Z)(u));this.setOptions({rightLayers:m})}else{var E,H=(E=this.controlOption.layers).concat.apply(E,(0,On.Z)(u));this.setOptions({layers:H})}}},{key:"removeLayer",value:function(t){var a=Array.isArray(t)?t:[t],u=this.controlOption.layers.filter(function(m){return a.includes(m)}),c=this.controlOption.rightLayers.filter(function(m){return a.includes(m)});this.setOptions({layers:u,rightLayers:c})}},{key:"removeLayers",value:function(){this.setOptions({layers:[],rightLayers:[]})}}]),r}(dy);function SF(e){var i=CF();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function CF(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var TF=function(e){(0,Me.Z)(r,e);var i=SF(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;un.mapsService.getMinZoom()&&n.mapsService.zoomOut()}),(0,St.Z)((0,Fr.Z)(n),"updateDisabled",function(){var c=n.mapsService;n.zoomInButton.removeAttribute("disabled"),n.zoomOutButton.removeAttribute("disabled"),(n.disabled||c.getZoom()<=c.getMinZoom())&&n.zoomOutButton.setAttribute("disabled","true"),n.controlOption.showZoom&&n.zoomNumDiv&&(n.zoomNumDiv.innerText=String(Math.floor(c.getZoom()))),(n.disabled||c.getZoom()>=c.getMaxZoom())&&n.zoomInButton.setAttribute("disabled","true")}),n}return(0,ot.Z)(r,[{key:"getDefault",value:function(t){return(0,Se.Z)((0,Se.Z)({},Sd((0,Qe.Z)(r.prototype),"getDefault",this).call(this,t)),{},{position:nl.BOTTOMRIGHT,name:"zoom",zoomInText:Dg("l7-icon-enlarge"),zoomInTitle:"Zoom in",zoomOutText:Dg("l7-icon-narrow"),zoomOutTitle:"Zoom out",showZoom:!1})}},{key:"setOptions",value:function(t){Sd((0,Qe.Z)(r.prototype),"setOptions",this).call(this,t),this.checkUpdateOption(t,["zoomInText","zoomInTitle","zoomOutText","zoomOutTitle","showZoom"])&&this.resetButtonGroup(this.container)}},{key:"onAdd",value:function(){var t=Vo("div","l7-control-zoom");return this.resetButtonGroup(t),this.mapsService.on("zoomend",this.updateDisabled),this.mapsService.on("zoomchange",this.updateDisabled),t}},{key:"onRemove",value:function(){this.mapsService.off("zoomend",this.updateDisabled),this.mapsService.off("zoomchange",this.updateDisabled)}},{key:"disable",value:function(){return this.disabled=!0,this.updateDisabled(),this}},{key:"enable",value:function(){return this.disabled=!1,this.updateDisabled(),this}},{key:"resetButtonGroup",value:function(t){Aa(t),this.zoomInButton=this.createButton(this.controlOption.zoomInText,this.controlOption.zoomInTitle,"l7-button-control",t,this.zoomIn),this.controlOption.showZoom&&(this.zoomNumDiv=this.createButton("0","","l7-button-control l7-control-zoom__number",t)),this.zoomOutButton=this.createButton(this.controlOption.zoomOutText,this.controlOption.zoomOutTitle,"l7-button-control",t,this.zoomOut),this.updateDisabled()}},{key:"createButton",value:function(t,a,u,c,m){var E=Vo("button",u,c);return typeof t=="string"?E.innerHTML=t:E.append(t),E.title=a,m&&E.addEventListener("click",m),E}}]),r}(dy);function MF(e){var i=PF();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function PF(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var Q3=function(e){(0,Me.Z)(r,e);var i=MF(r);function r(n){var t;(0,We.Z)(this,r),t=i.call(this),(0,St.Z)((0,Fr.Z)(t),"isShow",!0),(0,St.Z)((0,Fr.Z)(t),"onMouseMove",function(u){var c,m=t.mapsService.getMapContainer(),E=(c=m==null?void 0:m.getBoundingClientRect())!==null&&c!==void 0?c:{},H=E.left,re=H===void 0?0:H,xe=E.top,ke=xe===void 0?0:xe;t.setPopupPosition(u.clientX-re,u.clientY-ke)}),(0,St.Z)((0,Fr.Z)(t),"updateLngLatPosition",function(){if(!(!t.mapsService||t.popupOption.followCursor)){var u=t.lngLat,c=u.lng,m=u.lat,E=t.mapsService.lngLatToContainer([c,m]),H=E.x,re=E.y;t.setPopupPosition(H,re)}}),(0,St.Z)((0,Fr.Z)(t),"onKeyDown",function(u){u.keyCode===27&&t.remove()}),(0,St.Z)((0,Fr.Z)(t),"onCloseButtonClick",function(u){u.stopPropagation&&u.stopPropagation(),t.hide()}),(0,St.Z)((0,Fr.Z)(t),"update",function(){var u=!!t.lngLat,c=t.popupOption,m=c.className,E=c.style,H=c.maxWidth,re=c.anchor,xe=c.stopPropagation;if(!(!t.mapsService||!u||!t.content)){var ke=t.mapsService.getMarkerContainer();if(!t.container&&ke&&(t.container=Vo("div","l7-popup ".concat(m!=null?m:""," ").concat(t.isShow?"":"l7-popup-hide"),ke),E&&t.container.setAttribute("style",E),t.tip=Vo("div","l7-popup-tip",t.container),t.container.appendChild(t.content),xe&&["mousemove","mousedown","mouseup","click","dblclick"].forEach(function(It){t.container.addEventListener(It,function(er){er.stopPropagation()})}),t.container.style.whiteSpace="nowrap"),t.updateLngLatPosition(),io(t.container,"".concat(Fn[re])),zn(t.container,re,"popup"),H){var rt=t.container.getBoundingClientRect(),vt=rt.width;vt>parseFloat(H)&&(t.container.style.width=H)}else t.container.style.removeProperty("width")}}),t.popupOption=(0,Se.Z)((0,Se.Z)({},t.getDefault(n!=null?n:{})),n);var a=t.popupOption.lngLat;return a&&(t.lngLat=a),t}return(0,ot.Z)(r,[{key:"lngLat",get:function(){var t;return(t=this.popupOption.lngLat)!==null&&t!==void 0?t:{lng:0,lat:0}},set:function(t){this.popupOption.lngLat=t}},{key:"getIsShow",value:function(){return this.isShow}},{key:"addTo",value:function(t){this.mapsService=t.get(sr.IMapService),this.sceneService=t.get(sr.ISceneService),this.layerService=t.get(sr.ILayerService),this.mapsService.on("camerachange",this.update),this.mapsService.on("viewchange",this.update),this.scene=t,this.update(),this.updateCloseOnClick(),this.updateCloseOnEsc(),this.updateFollowCursor();var a=this.popupOption,u=a.html,c=a.text,m=a.title;return u?this.setHTML(u):c&&this.setText(c),m&&this.setTitle(m),this.emit("open"),this}},{key:"remove",value:function(){if(this!==null&&this!==void 0&&this.isOpen())return this.content&&bs(this.content),this.container&&(bs(this.container),delete this.container),this.mapsService&&(this.mapsService.off("camerachange",this.update),this.mapsService.off("viewchange",this.update),this.updateCloseOnClick(!0),this.updateCloseOnEsc(!0),this.updateFollowCursor(!0),delete this.mapsService),this.emit("close"),this}},{key:"getOptions",value:function(){return this.popupOption}},{key:"setOptions",value:function(t){return this.show(),this.popupOption=(0,Se.Z)((0,Se.Z)({},this.popupOption),t),this.checkUpdateOption(t,["html","text","title","closeButton","closeButtonOffsets","maxWidth","anchor","stopPropagation","className","style","lngLat","offsets"])&&(this.container&&(bs(this.container),this.container=void 0),this.popupOption.html?this.setHTML(this.popupOption.html):this.popupOption.text&&this.setText(this.popupOption.text),this.popupOption.title&&this.setTitle(this.popupOption.title)),this.checkUpdateOption(t,["closeOnEsc"])&&this.updateCloseOnEsc(),this.checkUpdateOption(t,["closeOnClick"])&&this.updateCloseOnClick(),this.checkUpdateOption(t,["followCursor"])&&this.updateFollowCursor(),this.checkUpdateOption(t,["html"])&&t.html?this.setHTML(t.html):this.checkUpdateOption(t,["text"])&&t.text&&this.setText(t.text),this.checkUpdateOption(t,["lngLat"])&&t.lngLat&&this.setLnglat(t.lngLat),this}},{key:"open",value:function(){return this.addTo(this.scene),this}},{key:"close",value:function(){return this.remove(),this}},{key:"show",value:function(){if(!this.isShow)return this.container&&Hu(this.container,"l7-popup-hide"),this.isShow=!0,this.emit("show"),this}},{key:"hide",value:function(){if(this.isShow)return this.container&&Js(this.container,"l7-popup-hide"),this.isShow=!1,this.emit("hide"),this}},{key:"setHTML",value:function(t){return this.popupOption.html=t,this.setDOMContent(t)}},{key:"setText",value:function(t){return this.popupOption.text=t,this.setDOMContent(window.document.createTextNode(t))}},{key:"setTitle",value:function(t){this.show(),this.popupOption.title=t,t?(this.contentTitle||(this.contentTitle=Vo("div","l7-popup-content__title"),this.content.firstChild?this.content.insertBefore(this.contentTitle,this.content.firstChild):this.content.append(this.contentTitle)),Aa(this.contentTitle),Eu(this.contentTitle,t)):this.contentTitle&&(bs(this.contentTitle),this.contentTitle=void 0)}},{key:"panToPopup",value:function(){var t=this.lngLat,a=t.lng,u=t.lat;return this.popupOption.autoPan&&this.mapsService.panTo([a,u]),this}},{key:"setLngLat",value:function(t){return this.setLnglat(t)}},{key:"setLnglat",value:function(t){var a=this;return this.show(),this.lngLat=t,Array.isArray(t)&&(this.lngLat={lng:t[0],lat:t[1]}),this.mapsService&&(this.mapsService.off("camerachange",this.update),this.mapsService.off("viewchange",this.update),this.mapsService.on("camerachange",this.update),this.mapsService.on("viewchange",this.update)),this.update(),this.popupOption.autoPan&&setTimeout(function(){a.panToPopup()},0),this}},{key:"getLnglat",value:function(){return this.lngLat}},{key:"setMaxWidth",value:function(t){return this.popupOption.maxWidth=t,this.update(),this}},{key:"isOpen",value:function(){return!!this.mapsService}},{key:"getDefault",value:function(t){return{closeButton:!0,closeOnClick:!1,maxWidth:"240px",offsets:[0,0],anchor:ko.BOTTOM,stopPropagation:!0,autoPan:!1,autoClose:!0,closeOnEsc:!1,followCursor:!1}}},{key:"setDOMContent",value:function(t){return this.show(),this.createContent(),Eu(this.contentPanel,t),this.update(),this}},{key:"updateCloseOnClick",value:function(t){var a=this,u=this.mapsService;u&&(u==null||u.off("click",this.onCloseButtonClick),this.popupOption.closeOnClick&&!t&&requestAnimationFrame(function(){u==null||u.on("click",a.onCloseButtonClick)}))}},{key:"updateCloseOnEsc",value:function(t){window.removeEventListener("keydown",this.onKeyDown),this.popupOption.closeOnEsc&&!t&&window.addEventListener("keydown",this.onKeyDown)}},{key:"updateFollowCursor",value:function(t){var a,u=(a=this.mapsService)===null||a===void 0?void 0:a.getContainer();u&&(u==null||u.removeEventListener("mousemove",this.onMouseMove),this.popupOption.followCursor&&!t&&(u==null||u.addEventListener("mousemove",this.onMouseMove)))}},{key:"createContent",value:function(){var t=this;if(this.content&&bs(this.content),this.contentTitle=void 0,this.content=Vo("div","l7-popup-content",this.container),this.setTitle(this.popupOption.title),this.popupOption.closeButton){var a=Dg("l7-icon-guanbi");Js(a,"l7-popup-close-button"),this.content.appendChild(a),this.popupOption.closeButtonOffsets&&(a.style.right=this.popupOption.closeButtonOffsets[0]+"px",a.style.top=this.popupOption.closeButtonOffsets[1]+"px"),a.setAttribute("aria-label","Close popup"),a.addEventListener("click",function(){t.hide()}),a.addEventListener("pointerup",function(u){u.stopPropagation()}),a.addEventListener("pointerdown",function(u){u.stopPropagation()}),this.closeButton=a}else this.closeButton=void 0;this.contentPanel=Vo("div","l7-popup-content__panel",this.content)}},{key:"setPopupPosition",value:function(t,a){if(this.container){var u=this.popupOption.offsets;this.container.style.left=t+u[0]+"px",this.container.style.top=a-u[1]+"px"}}},{key:"checkUpdateOption",value:function(t,a){return a.some(function(u){return u in t})}}]),r}(cu.EventEmitter);function IF(e){var i=RF();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function RF(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var OF=lo.get,LF=function(e){(0,Me.Z)(r,e);var i=IF(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u * + * { + margin-left: 6px; +} +.l7-select-control--normal .l7-select-control-item input[type='checkbox'] { + width: 14px; + height: 14px; +} +.l7-select-control--normal .l7-select-control-item:hover { + background-color: #f3f3f3; +} +.l7-select-control--image { + display: -webkit-box; + display: -ms-flexbox; + display: flex; + -ms-flex-wrap: wrap; + flex-wrap: wrap; + -webkit-box-align: start; + -ms-flex-align: start; + align-items: flex-start; + -webkit-box-sizing: content-box; + box-sizing: content-box; + max-width: 460px; + max-height: 400px; + margin: 12px 0 0 12px; + overflow-x: hidden; + overflow-y: auto; +} +.l7-select-control--image .l7-select-control-item { + position: relative; + display: -webkit-box; + display: -ms-flexbox; + display: flex; + -webkit-box-flex: 0; + -ms-flex: 0 0 calc((100% - (12px + 9px) * 2) / 3); + flex: 0 0 calc((100% - (12px + 9px) * 2) / 3); + -webkit-box-orient: vertical; + -webkit-box-direction: normal; + -ms-flex-direction: column; + flex-direction: column; + -webkit-box-pack: center; + -ms-flex-pack: center; + justify-content: center; + -webkit-box-sizing: content-box; + box-sizing: content-box; + margin-right: 12px; + margin-bottom: 12px; + overflow: hidden; + font-size: 12px; + border: 1px solid #fff; + border-radius: 2px; +} +.l7-select-control--image .l7-select-control-item img { + width: 100%; + height: 80px; +} +.l7-select-control--image .l7-select-control-item input[type='checkbox'] { + position: absolute; + top: 0; + right: 0; +} +.l7-select-control--image .l7-select-control-item input[type='radio'] { + position: absolute; + top: 0; + right: 0; +} +.l7-select-control--image .l7-select-control-item .l7-select-control-item-row { + display: -webkit-box; + display: -ms-flexbox; + display: flex; + -webkit-box-align: center; + -ms-flex-align: center; + align-items: center; + -webkit-box-pack: center; + -ms-flex-pack: center; + justify-content: center; + line-height: 26px; +} +.l7-select-control--image .l7-select-control-item .l7-select-control-item-row > * + * { + margin-left: 8px; +} +.l7-select-control--image .l7-select-control-item.l7-select-control-item-active { + border-color: #0370fe; +} +.l7-select-control-item { + cursor: pointer; +} +.l7-select-control-item input[type='checkbox'] { + margin: 0; + cursor: pointer; +} +.l7-select-control--multiple .l7-select-control-item:hover { + background-color: transparent; +} +.l7-control-logo { + width: 89px; + height: 16px; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} +.l7-control-logo img { + height: 100%; + width: 100%; +} +.l7-control-logo .l7-control-logo-link { + display: block; + cursor: pointer; +} +.l7-control-logo .l7-control-logo-link img { + cursor: pointer; +} +.l7-control-mouse-location { + background-color: #fff; + border-radius: 2px; + -webkit-box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.15); + box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.15); + padding: 2px 4px; + min-width: 130px; +} +.l7-control-zoom { + overflow: hidden; + border-radius: 2px; + -webkit-box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.15); + box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.15); +} +.l7-control-zoom .l7-button-control { + font-size: 16px; + border-bottom: 1px solid #f0f0f0; + border-radius: 0; + -webkit-box-shadow: 0 0 0; + box-shadow: 0 0 0; +} +.l7-control-zoom .l7-button-control .l7-iconfont { + width: 14px; + height: 14px; +} +.l7-control-zoom .l7-button-control:last-child { + border-bottom: 0; +} +.l7-control-zoom .l7-control-zoom__number { + color: #595959; + padding: 0; +} +.l7-control-zoom .l7-control-zoom__number:hover { + background-color: #fff; +} +.l7-control-scale { + display: -webkit-box; + display: -ms-flexbox; + display: flex; + -webkit-box-orient: vertical; + -webkit-box-direction: normal; + -ms-flex-direction: column; + flex-direction: column; +} +.l7-control-scale .l7-control-scale-line { + -webkit-box-sizing: border-box; + box-sizing: border-box; + padding: 2px 5px 1px; + overflow: hidden; + color: #595959; + font-size: 10px; + line-height: 1.1; + white-space: nowrap; + background: #fff; + border: 2px solid #000; + border-top: 0; + -webkit-transition: width 0.1s; + transition: width 0.1s; +} +.l7-control-scale .l7-control-scale-line + .l7-control-scale .l7-control-scale-line { + margin-top: -2px; + border-top: 2px solid #777; + border-bottom: none; +} +.l7-right .l7-control-scale { + display: -webkit-box; + display: -ms-flexbox; + display: flex; + -webkit-box-align: end; + -ms-flex-align: end; + align-items: flex-end; +} +.l7-right .l7-control-scale .l7-control-scale-line { + text-align: right; +} +.l7-popup { + position: absolute; + top: 0; + left: 0; + z-index: 5; + display: -webkit-box; + display: -ms-flexbox; + display: flex; + will-change: transform; + pointer-events: none; +} +.l7-popup.l7-popup-hide { + display: none; +} +.l7-popup .l7-popup-content { + position: relative; + padding: 16px; + font-size: 14px; + background: #fff; + border-radius: 3px; + -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1); + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1); +} +.l7-popup .l7-popup-content .l7-popup-content__title { + margin-bottom: 8px; + font-weight: bold; +} +.l7-popup .l7-popup-content .l7-popup-close-button, +.l7-popup .l7-popup-content .l7-popup-content__title, +.l7-popup .l7-popup-content .l7-popup-content__panel { + white-space: normal; + -webkit-user-select: text; + -moz-user-select: text; + -ms-user-select: text; + user-select: text; + pointer-events: initial; +} +.l7-popup .l7-popup-content .l7-popup-close-button { + position: absolute; + top: 0; + right: 0; + width: 18px; + height: 18px; + padding: 0; + font-size: 14px; + line-height: 18px; + text-align: center; + background-color: transparent; + border: 0; + border-radius: 0 3px 0 0; + cursor: pointer; +} +.l7-popup .l7-popup-tip { + position: relative; + z-index: 1; + width: 0; + height: 0; + border: 10px solid transparent; +} +.l7-popup.l7-popup-anchor-bottom, +.l7-popup.l7-popup-anchor-bottom-left, +.l7-popup.l7-popup-anchor-bottom-right { + -webkit-box-orient: vertical; + -webkit-box-direction: reverse; + -ms-flex-direction: column-reverse; + flex-direction: column-reverse; +} +.l7-popup.l7-popup-anchor-bottom .l7-popup-tip, +.l7-popup.l7-popup-anchor-bottom-left .l7-popup-tip, +.l7-popup.l7-popup-anchor-bottom-right .l7-popup-tip { + bottom: 1px; +} +.l7-popup.l7-popup-anchor-top, +.l7-popup.l7-popup-anchor-top-left, +.l7-popup.l7-popup-anchor-top-right { + -webkit-box-orient: vertical; + -webkit-box-direction: normal; + -ms-flex-direction: column; + flex-direction: column; +} +.l7-popup.l7-popup-anchor-top .l7-popup-tip, +.l7-popup.l7-popup-anchor-top-left .l7-popup-tip, +.l7-popup.l7-popup-anchor-top-right .l7-popup-tip { + top: 1px; +} +.l7-popup.l7-popup-anchor-left { + -webkit-box-orient: horizontal; + -webkit-box-direction: normal; + -ms-flex-direction: row; + flex-direction: row; +} +.l7-popup.l7-popup-anchor-right { + -webkit-box-orient: horizontal; + -webkit-box-direction: reverse; + -ms-flex-direction: row-reverse; + flex-direction: row-reverse; +} +.l7-popup-anchor-top .l7-popup-tip { + position: relative; + -webkit-align-self: center; + -ms-flex-item-align: center; + align-self: center; + border-top: none; + border-bottom-color: #fff; +} +.l7-popup-anchor-top-left .l7-popup-tip { + -webkit-align-self: flex-start; + -ms-flex-item-align: start; + align-self: flex-start; + border-top: none; + border-bottom-color: #fff; + border-left: none; +} +.l7-popup-anchor-top-right .l7-popup-tip { + -webkit-align-self: flex-end; + -ms-flex-item-align: end; + align-self: flex-end; + border-top: none; + border-right: none; + border-bottom-color: #fff; +} +.l7-popup-anchor-bottom .l7-popup-tip { + -webkit-align-self: center; + -ms-flex-item-align: center; + align-self: center; + border-top-color: #fff; + border-bottom: none; +} +.l7-popup-anchor-bottom-left .l7-popup-tip { + -webkit-align-self: flex-start; + -ms-flex-item-align: start; + align-self: flex-start; + border-top-color: #fff; + border-bottom: none; + border-left: none; +} +.l7-popup-anchor-bottom-right .l7-popup-tip { + -webkit-align-self: flex-end; + -ms-flex-item-align: end; + align-self: flex-end; + border-top-color: #fff; + border-right: none; + border-bottom: none; +} +.l7-popup-anchor-left .l7-popup-tip { + -webkit-align-self: center; + -ms-flex-item-align: center; + align-self: center; + border-right-color: #fff; + border-left: none; +} +.l7-popup-anchor-right .l7-popup-tip { + right: 1px; + -webkit-align-self: center; + -ms-flex-item-align: center; + align-self: center; + border-right: none; + border-left-color: #fff; +} +.l7-popup-anchor-top-left .l7-popup-content { + border-top-left-radius: 0; +} +.l7-popup-anchor-top-right .l7-popup-content { + border-top-right-radius: 0; +} +.l7-popup-anchor-bottom-left .l7-popup-content { + border-bottom-left-radius: 0; +} +.l7-popup-anchor-bottom-right .l7-popup-content { + border-bottom-right-radius: 0; +} +.l7-popup-track-pointer { + display: none; +} +.l7-popup-track-pointer * { + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + pointer-events: none; +} +.l7-map:hover .l7-popup-track-pointer { + display: -webkit-box; + display: -ms-flexbox; + display: flex; +} +.l7-map:active .l7-popup-track-pointer { + display: none; +} +.l7-layer-popup__row { + font-size: 12px; +} +.l7-layer-popup__row + .l7-layer-popup__row { + margin-top: 4px; +} +.l7-control-swipe { + position: absolute; + top: 50%; + left: 50%; + z-index: 6; + -webkit-transform: translate(-50%, -50%); + transform: translate(-50%, -50%); + -ms-touch-action: none; + touch-action: none; +} +.l7-control-swipe_hide { + display: none; +} +.l7-control-swipe:before { + position: absolute; + top: -5000px; + bottom: -5000px; + left: 50%; + z-index: -1; + width: 4px; + background: #fff; + -webkit-transform: translate(-2px, 0); + transform: translate(-2px, 0); + content: ''; +} +.l7-control-swipe.horizontal:before { + top: 50%; + right: -5000px; + bottom: auto; + left: -5000px; + width: auto; + height: 4px; +} +.l7-control-swipe__button { + display: block; + width: 28px; + height: 28px; + margin: 0; + padding: 0; + color: #595959; + font-weight: bold; + font-size: inherit; + text-align: center; + text-decoration: none; + background-color: #fff; + border: none; + border-radius: 2px; + outline: none; +} +.l7-control-swipe, +.l7-control-swipe__button { + cursor: ew-resize; +} +.l7-control-swipe.horizontal, +.l7-control-swipe.horizontal button { + cursor: ns-resize; +} +.l7-control-swipe:after, +.l7-control-swipe__button:before, +.l7-control-swipe__button:after { + position: absolute; + top: 25%; + bottom: 25%; + left: 50%; + width: 2px; + background: currentColor; + -webkit-transform: translate(-1px, 0); + transform: translate(-1px, 0); + content: ''; +} +.l7-control-swipe__button:after { + -webkit-transform: translateX(4px); + transform: translateX(4px); +} +.l7-control-swipe__button:before { + -webkit-transform: translateX(-6px); + transform: translateX(-6px); +} +`);var J3,Aw,eT,Vv=(J3=Qm(sr.IGlobalConfigService),Aw=function(){function e(i){(0,We.Z)(this,e),_(this,"configService",eT,this),this.config=i}return(0,ot.Z)(e,[{key:"setContainer",value:function(r,n,t){r.bind(sr.MapConfig).toConstantValue((0,Se.Z)((0,Se.Z)({},this.config),{},{id:n,canvas:t})),r.bind(sr.IMapService).to(this.getServiceConstructor()).inSingletonScope()}},{key:"getServiceConstructor",value:function(){throw new Error("Method not implemented.")}}]),e}(),eT=d(Aw.prototype,"configService",[J3],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),Aw),kF=A(95906),tT=A.n(kF);function q_(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}function zb(e,i){var r=Ua([],i,e);return Pt(r,r,1/r[3]),r}function t$(e,i){var r=e%i;return r<0?i+r:r}function r$(e,i,r){return r*i+(1-r)*e}function n1(e,i){if(!e)throw new Error(i||"viewport-mercator-project: assertion failed.")}var $v=Math.PI,rT=$v/4,Fg=$v/180,nT=180/$v,bw=512,xw=4003e4,FF=1.5;function iT(e){return Math.pow(2,e)}function BF(e){return Math.log2(e)}function Zb(e,i){var r=(0,gi.Z)(e,2),n=r[0],t=r[1];n1(Number.isFinite(n)&&Number.isFinite(i)),n1(Number.isFinite(t)&&t>=-90&&t<=90,"invalid latitude"),i*=bw;var a=n*Fg,u=t*Fg,c=i*(a+$v)/(2*$v),m=i*($v-Math.log(Math.tan(rT+u*.5)))/(2*$v);return[c,m]}function ww(e,i){var r=(0,gi.Z)(e,2),n=r[0],t=r[1];i*=bw;var a=n/i*(2*$v)-$v,u=2*(Math.atan(Math.exp($v-t/i*(2*$v)))-rT);return[a*nT,u*nT]}function n$(e){var i=e.latitude;assert(Number.isFinite(i));var r=Math.cos(i*Fg);return BF(xw*r)-9}function oT(e){var i=e.latitude,r=e.longitude,n=e.zoom,t=e.scale,a=e.highPrecision,u=a===void 0?!1:a;t=t!==void 0?t:iT(n),n1(Number.isFinite(i)&&Number.isFinite(r)&&Number.isFinite(t));var c={},m=bw*t,E=Math.cos(i*Fg),H=m/360,re=H/E,xe=m/xw/E;if(c.pixelsPerMeter=[xe,-xe,xe],c.metersPerPixel=[1/xe,-1/xe,1/xe],c.pixelsPerDegree=[H,-re,xe],c.degreesPerPixel=[1/H,-1/re,1/xe],u){var ke=Fg*Math.tan(i*Fg)/E,rt=H*ke/2,vt=m/xw*ke,It=vt/re*xe;c.pixelsPerDegree2=[0,-rt,vt],c.pixelsPerMeter2=[It,0,It]}return c}function i$(e,i){var r=_slicedToArray(e,3),n=r[0],t=r[1],a=r[2],u=_slicedToArray(i,3),c=u[0],m=u[1],E=u[2],H=1,re=oT({longitude:n,latitude:t,scale:H,highPrecision:!0}),xe=re.pixelsPerMeter,ke=re.pixelsPerMeter2,rt=Zb(e,H);rt[0]+=c*(xe[0]+ke[0]*m),rt[1]+=m*(xe[1]+ke[1]*m);var vt=ww(rt,H),It=(a||0)+(E||0);return Number.isFinite(a)||Number.isFinite(E)?[vt[0],vt[1],It]:vt}function NF(e){var i=e.height,r=e.pitch,n=e.bearing,t=e.altitude,a=e.center,u=a===void 0?null:a,c=e.flipY,m=c===void 0?!1:c,E=q_();return wd(E,E,[0,0,-t]),Md(E,E,[1,1,1/i]),Bd(E,E,-r*Fg),Jd(E,E,n*Fg),m&&Md(E,E,[1,-1,1]),u&&wd(E,E,qE([],u)),E}function zF(e){var i=e.width,r=e.height,n=e.altitude,t=n===void 0?FF:n,a=e.pitch,u=a===void 0?0:a,c=e.nearZMultiplier,m=c===void 0?1:c,E=e.farZMultiplier,H=E===void 0?1:E,re=u*Fg,xe=Math.atan(.5/t),ke=Math.sin(xe)*t/Math.sin(Math.PI/2-re-xe),rt=Math.cos(Math.PI/2-re)*ke+t;return{fov:2*Math.atan(r/2/t),aspect:i/r,focalDistance:t,near:m,far:rt*H}}function ZF(e){var i=e.width,r=e.height,n=e.pitch,t=e.altitude,a=e.nearZMultiplier,u=e.farZMultiplier,c=zF({width:i,height:r,altitude:t,pitch:n,nearZMultiplier:a,farZMultiplier:u}),m=c.fov,E=c.aspect,H=c.near,re=c.far,xe=wr([],m,E,H,re);return xe}function UF(e,i){var r=(0,gi.Z)(e,3),n=r[0],t=r[1],a=r[2],u=a===void 0?0:a;return n1(Number.isFinite(n)&&Number.isFinite(t)&&Number.isFinite(u)),zb(i,[n,t,u,1])}function aT(e,i){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,n=(0,gi.Z)(e,3),t=n[0],a=n[1],u=n[2];if(n1(Number.isFinite(t)&&Number.isFinite(a),"invalid pixel coordinate"),Number.isFinite(u)){var c=zb(i,[t,a,u,1]);return c}var m=zb(i,[t,a,0,1]),E=zb(i,[t,a,1,1]),H=m[2],re=E[2],xe=H===re?0:((r||0)-H)/(re-H);return Tp([],m,E,xe)}var sT=q_(),jF=function(){function e(){var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=i.width,n=i.height,t=i.viewMatrix,a=t===void 0?sT:t,u=i.projectionMatrix,c=u===void 0?sT:u;(0,We.Z)(this,e),this.width=r||1,this.height=n||1,this.scale=1,this.pixelsPerMeter=1,this.viewMatrix=a,this.projectionMatrix=c;var m=q_();Gh(m,m,this.projectionMatrix),Gh(m,m,this.viewMatrix),this.viewProjectionMatrix=m;var E=q_();Md(E,E,[this.width/2,-this.height/2,1]),wd(E,E,[1,-1,0]),Gh(E,E,this.viewProjectionMatrix);var H=N0(q_(),E);if(!H)throw new Error("Pixel project matrix not invertible");this.pixelProjectionMatrix=E,this.pixelUnprojectionMatrix=H,this.equals=this.equals.bind(this),this.project=this.project.bind(this),this.unproject=this.unproject.bind(this),this.projectPosition=this.projectPosition.bind(this),this.unprojectPosition=this.unprojectPosition.bind(this),this.projectFlat=this.projectFlat.bind(this),this.unprojectFlat=this.unprojectFlat.bind(this)}return(0,ot.Z)(e,[{key:"equals",value:function(r){return r instanceof e?r.width===this.width&&r.height===this.height&&qa(r.projectionMatrix,this.projectionMatrix)&&qa(r.viewMatrix,this.viewMatrix):!1}},{key:"project",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},t=n.topLeft,a=t===void 0?!0:t,u=this.projectPosition(r),c=UF(u,this.pixelProjectionMatrix),m=(0,gi.Z)(c,2),E=m[0],H=m[1],re=a?H:this.height-H;return r.length===2?[E,re]:[E,re,c[2]]}},{key:"unproject",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},t=n.topLeft,a=t===void 0?!0:t,u=n.targetZ,c=(0,gi.Z)(r,3),m=c[0],E=c[1],H=c[2],re=a?E:this.height-E,xe=u&&u*this.pixelsPerMeter,ke=aT([m,re,H],this.pixelUnprojectionMatrix,xe),rt=this.unprojectPosition(ke),vt=(0,gi.Z)(rt,3),It=vt[0],er=vt[1],Ar=vt[2];return Number.isFinite(H)?[It,er,Ar]:Number.isFinite(u)?[It,er,u]:[It,er]}},{key:"projectPosition",value:function(r){var n=this.projectFlat(r),t=(0,gi.Z)(n,2),a=t[0],u=t[1],c=(r[2]||0)*this.pixelsPerMeter;return[a,u,c]}},{key:"unprojectPosition",value:function(r){var n=this.unprojectFlat(r),t=(0,gi.Z)(n,2),a=t[0],u=t[1],c=(r[2]||0)/this.pixelsPerMeter;return[a,u,c]}},{key:"projectFlat",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.scale;return r}},{key:"unprojectFlat",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.scale;return r}}]),e}();function VF(e){var i=e.width,r=e.height,n=e.bounds,t=e.minExtent,a=t===void 0?0:t,u=e.maxZoom,c=u===void 0?24:u,m=e.padding,E=m===void 0?0:m,H=e.offset,re=H===void 0?[0,0]:H,xe=(0,gi.Z)(n,2),ke=(0,gi.Z)(xe[0],2),rt=ke[0],vt=ke[1],It=(0,gi.Z)(xe[1],2),er=It[0],Ar=It[1];if(Number.isFinite(E)){var Or=E;E={top:Or,bottom:Or,left:Or,right:Or}}else n1(Number.isFinite(E.top)&&Number.isFinite(E.bottom)&&Number.isFinite(E.left)&&Number.isFinite(E.right));var rn=new Ew({width:i,height:r,longitude:0,latitude:0,zoom:0}),Ln=rn.project([rt,Ar]),wn=rn.project([er,vt]),Cn=[Math.max(Math.abs(wn[0]-Ln[0]),a),Math.max(Math.abs(wn[1]-Ln[1]),a)],qn=[i-E.left-E.right-Math.abs(re[0])*2,r-E.top-E.bottom-Math.abs(re[1])*2];n1(qn[0]>0&&qn[1]>0);var Si=qn[0]/Cn[0],po=qn[1]/Cn[1],Ao=(E.right-E.left)/2/Si,ma=(E.bottom-E.top)/2/po,Ya=[(wn[0]+Ln[0])/2+Ao,(wn[1]+Ln[1])/2+ma],fs=rn.unproject(Ya),bf=rn.zoom+Math.log2(Math.abs(Math.min(Si,po)));return{longitude:fs[0],latitude:fs[1],zoom:Math.min(bf,c)}}var Ew=function(e){(0,Me.Z)(i,e);function i(){var r,n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=n.width,a=n.height,u=n.latitude,c=u===void 0?0:u,m=n.longitude,E=m===void 0?0:m,H=n.zoom,re=H===void 0?0:H,xe=n.pitch,ke=xe===void 0?0:xe,rt=n.bearing,vt=rt===void 0?0:rt,It=n.altitude,er=It===void 0?1.5:It,Ar=n.nearZMultiplier,Or=n.farZMultiplier;(0,We.Z)(this,i),t=t||1,a=a||1;var rn=iT(re);er=Math.max(.75,er);var Ln=Zb([E,c],rn);Ln[2]=0;var wn=ZF({width:t,height:a,pitch:ke,bearing:vt,altitude:er,nearZMultiplier:Ar||1/a,farZMultiplier:Or||1.01}),Cn=NF({height:a,center:Ln,pitch:ke,bearing:vt,altitude:er,flipY:!0});return r=(0,st.Z)(this,(0,Qe.Z)(i).call(this,{width:t,height:a,viewMatrix:Cn,projectionMatrix:wn})),r.latitude=c,r.longitude=E,r.zoom=re,r.pitch=ke,r.bearing=vt,r.altitude=er,r.scale=rn,r.center=Ln,r.pixelsPerMeter=oT((0,Fr.Z)((0,Fr.Z)(r))).pixelsPerMeter[2],Object.freeze((0,Fr.Z)((0,Fr.Z)(r))),r}return(0,ot.Z)(i,[{key:"projectFlat",value:function(n){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.scale;return Zb(n,t)}},{key:"unprojectFlat",value:function(n){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.scale;return ww(n,t)}},{key:"getMapCenterByLngLatPosition",value:function(n){var t=n.lngLat,a=n.pos,u=aT(a,this.pixelUnprojectionMatrix),c=Zb(t,this.scale),m=Tc([],c,kp([],u)),E=Tc([],this.center,m);return ww(E,this.scale)}},{key:"getLocationAtPoint",value:function(n){var t=n.lngLat,a=n.pos;return this.getMapCenterByLngLatPosition({lngLat:t,pos:a})}},{key:"fitBounds",value:function(n){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=this.width,u=this.height,c=VF(Object.assign({width:a,height:u,bounds:n},t)),m=c.longitude,E=c.latitude,H=c.zoom;return new i({width:a,height:u,longitude:m,latitude:E,zoom:H})}}]),i}(jF),by=function(){function e(){(0,We.Z)(this,e)}return(0,ot.Z)(e,[{key:"syncWithMapCamera",value:function(r){var n=r.center,t=r.zoom,a=r.pitch,u=r.bearing,c=r.viewportHeight,m=r.viewportWidth,E=this.viewport?{width:this.viewport.width,height:this.viewport.height,longitude:this.viewport.center[0],latitude:this.viewport.center[1],zoom:this.viewport.zoom,pitch:this.viewport.pitch,bearing:this.viewport.bearing}:{};this.viewport=new Ew((0,Se.Z)((0,Se.Z)({},E),{},{width:m,height:c,longitude:n&&n[0],latitude:n&&n[1],zoom:t,pitch:a,bearing:u}))}},{key:"getZoom",value:function(){return this.viewport.zoom}},{key:"getZoomScale",value:function(){return Math.pow(2,this.getZoom())}},{key:"getCenter",value:function(){return[this.viewport.longitude,this.viewport.latitude]}},{key:"getProjectionMatrix",value:function(){return this.viewport.projectionMatrix}},{key:"getModelMatrix",value:function(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}},{key:"getViewMatrix",value:function(){return this.viewport.viewMatrix}},{key:"getViewMatrixUncentered",value:function(){return this.viewport.viewMatrixUncentered}},{key:"getViewProjectionMatrix",value:function(){return this.viewport.viewProjectionMatrix}},{key:"getViewProjectionMatrixUncentered",value:function(){return this.viewport.viewProjectionMatrix}},{key:"getFocalDistance",value:function(){return 1}},{key:"projectFlat",value:function(r,n){return this.viewport.projectFlat(r,n)}}]),e}(),uT=function(){function e(i){(0,We.Z)(this,e),(0,St.Z)(this,"size",1e4),this.size=i||1e4}return(0,ot.Z)(e,[{key:"setSize",value:function(r){this.size=r}},{key:"getSize",value:function(){return[this.size,this.size]}},{key:"mercatorXfromLng",value:function(r){return(180+r)/360*this.size}},{key:"mercatorYfromLat",value:function(r){return(1-(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+r*Math.PI/360)))/360)*this.size}},{key:"lngFromMercatorX",value:function(r){return r/this.size*360-180}},{key:"latFromMercatorY",value:function(r){var n=180-(1-r/this.size)*360;return 360/Math.PI*Math.atan(Math.exp(n*Math.PI/180))-90}},{key:"project",value:function(r){var n=this.mercatorXfromLng(r[0]),t=this.mercatorYfromLat(r[1]);return[n,t]}},{key:"unproject",value:function(r){var n=this.lngFromMercatorX(r[0]),t=this.latFromMercatorY(r[1]);return[n,t]}}]),e}();function Ub(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},i={top:0,right:0,bottom:0,left:0};if(typeof e=="number")return{top:e,right:e,bottom:e,left:e};if(Array.isArray(e)){if(e.length===4)return{top:e[0],right:e[1],bottom:e[2],left:e[3]};if(e.length===2)return{top:e[0],right:e[1],bottom:e[0],left:e[1]}}return(0,Se.Z)((0,Se.Z)({},i),e)}var $F={normal:"amap://styles/normal",light:"amap://styles/c422f5c0cfced5be9fe3a83f05f28a68?isPublic=true",dark:"amap://styles/c9f1d10cae34f8ab05e425462c5a58d7?isPublic=true",blank:"amap://styles/07c17002b38775b32a7a76c66cf90e99?isPublic=true",fresh:"amap://styles/fresh",grey:"amap://styles/grey",graffiti:"amap://styles/graffiti",macaron:"amap://styles/macaron",darkblue:"amap://styles/darkblue",wine:"amap://styles/wine"},HF=["id","style","minZoom","maxZoom","token","mapInstance","plugin"],lT,cT,fT,hT,dT,pT,V1,mT,vT,gT,yT;function GF(e,i){var r=typeof my!="undefined"&&!!my&&typeof my.showToast=="function"&&my.isFRM!==!0,n=typeof wx!="undefined"&&wx!==null&&(typeof wx.request!="undefined"||typeof wx.miniProgram!="undefined");if(!(r||n)&&(i||(i=document),!!i)){var t=i.head||i.getElementsByTagName("head")[0];if(!t){t=i.createElement("head");var a=i.body||i.getElementsByTagName("body")[0];a?a.parentNode.insertBefore(t,a):i.documentElement.appendChild(t)}var u=i.createElement("style");return u.type="text/css",u.styleSheet?u.styleSheet.cssText=e:u.appendChild(i.createTextNode(e)),t.appendChild(u),u}}GF(`.amap-logo{ + display: none !important; +} +.amap-copyright { + display: none !important; +} +`);var WF={contextmenu:"rightclick"},XF={contextmenu:"rightclick",camerachange:"viewchange"},_T={"GAODE1.x":WF,"GAODE2.x":XF},YF=0;window.forceWebGL=!0;var AT="15cd8a57710d40c9b7c0e3cc120f1200",KF="1.4.15",qF="amap-script",Sw=!1,jb=[],QF=12,bT=(lT=(0,sa.b2)(),cT=(0,sa.f3)(sr.IGlobalConfigService),fT=(0,sa.f3)(sr.MapConfig),hT=(0,sa.f3)(sr.ICoordinateSystemService),dT=(0,sa.f3)(sr.IEventEmitter),lT(pT=(V1=function(){function e(){var i=this;(0,We.Z)(this,e),(0,St.Z)(this,"version",al["GAODE1.x"]),(0,St.Z)(this,"simpleMapCoord",new uT),(0,St.Z)(this,"bgColor","rgba(0, 0, 0, 0)"),_(this,"configService",mT,this),_(this,"config",vT,this),_(this,"coordinateSystemService",gT,this),_(this,"eventEmitter",yT,this),(0,St.Z)(this,"handleCameraChanged",function(r){var n=r.camera,t=n.fov,a=n.near,u=n.far,c=n.height,m=n.pitch,E=n.rotation,H=n.aspect,re=n.position,xe=i.getCenter(),ke=xe.lng,rt=xe.lat;if(i.emit("mapchange"),i.cameraChangedCallback){i.viewport.syncWithMapCamera({aspect:H,bearing:360-E,far:u,fov:t,cameraHeight:c,near:a,pitch:m,zoom:i.map.getZoom()-1,center:[ke,rt],offsetOrigin:[re.x,re.y]});var vt=i.config.offsetZoom,It=vt===void 0?QF:vt;i.viewport.getZoom()>It?i.coordinateSystemService.setCoordinateSystem(ne.P20_OFFSET):i.coordinateSystemService.setCoordinateSystem(ne.P20),i.cameraChangedCallback(i.viewport)}})}return(0,ot.Z)(e,[{key:"setBgColor",value:function(r){this.bgColor=r}},{key:"addMarkerContainer",value:function(){var r=this.map.getContainer();if(r!==null){var n=r.getElementsByClassName("amap-maps")[0];this.markerContainer=Vo("div","l7-marker-container",n)}}},{key:"getMarkerContainer",value:function(){return this.markerContainer}},{key:"on",value:function(r,n){e0.indexOf(r)!==-1?this.eventEmitter.on(r,n):this.map.on(_T[this.version][r]||r,n)}},{key:"off",value:function(r,n){e0.indexOf(r)!==-1?this.eventEmitter.off(r,n):this.map.off(_T[this.version][r]||r,n)}},{key:"getContainer",value:function(){return this.map.getContainer()}},{key:"getMapCanvasContainer",value:function(){var r;return(r=this.map.getContainer())===null||r===void 0?void 0:r.getElementsByClassName("amap-maps")[0]}},{key:"getSize",value:function(){var r=this.map.getSize();return[r.getWidth(),r.getHeight()]}},{key:"getType",value:function(){return"amap"}},{key:"getZoom",value:function(){return this.map.getZoom()-1}},{key:"setZoom",value:function(r){return this.map.setZoom(r+1)}},{key:"getCenter",value:function(r){if(r!=null&&r.padding){var n=this.getCenter(),t=Ub(r.padding),a=this.lngLatToPixel([n.lng,n.lat]),u=[(t.right-t.left)/2,(t.bottom-t.top)/2],c=this.pixelToLngLat([a.x-u[0],a.y-u[1]]);return c}var m=this.map.getCenter();return{lng:m.getLng(),lat:m.getLat()}}},{key:"setCenter",value:function(r,n){if(n!=null&&n.padding){var t=Ub(n.padding),a=this.lngLatToPixel(r),u=[(t.right-t.left)/2,(t.bottom-t.top)/2],c=this.pixelToLngLat([a.x+u[0],a.y+u[1]]);this.map.setCenter([c.lng,c.lat])}else this.map.setCenter(r)}},{key:"getPitch",value:function(){return this.map.getPitch()}},{key:"getRotation",value:function(){return 360-this.map.getRotation()}},{key:"getBounds",value:function(){var r=this.map.getBounds().toBounds(),n=r.getNorthEast(),t=r.getSouthWest(),a=this.getCenter(),u=a.lng>n.getLng()||a.lng0&&arguments[0]!==void 0?arguments[0]:0,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;this.map.panBy(r,n)}},{key:"fitBounds",value:function(r){this.map.setBounds(new AMap.Bounds([r[0][0],r[0][1],r[1][0],r[1][1]]))}},{key:"setZoomAndCenter",value:function(r,n){this.map.setZoomAndCenter(r+1,n)}},{key:"setMapStyle",value:function(r){this.map.setMapStyle(this.getMapStyleValue(r))}},{key:"setMapStatus",value:function(r){this.map.setStatus(r)}},{key:"getMapStyleConfig",value:function(){return $F}},{key:"getMapStyleValue",value:function(r){return this.getMapStyleConfig()[r]||r}},{key:"getMapStyle",value:function(){return this.map.getMapStyle()}},{key:"pixelToLngLat",value:function(r){var n=this.map.pixelToLngLat(new AMap.Pixel(r[0],r[1]));return{lng:n.getLng(),lat:n.getLat()}}},{key:"lngLatToPixel",value:function(r){var n=this.map.lnglatToPixel(new AMap.LngLat(r[0],r[1]));return{x:n.getX(),y:n.getY()}}},{key:"containerToLngLat",value:function(r){var n=new AMap.Pixel(r[0],r[1]),t=this.map.containerToLngLat(n);return{lng:t==null?void 0:t.getLng(),lat:t==null?void 0:t.getLat()}}},{key:"lngLatToContainer",value:function(r){var n=new AMap.LngLat(r[0],r[1]),t=this.map.lngLatToContainer(n);return{x:t.getX(),y:t.getY()}}},{key:"lngLatToCoord",value:function(r){var n=this.map.lngLatToGeodeticCoord(r),t=n.x,a=n.y;return[t,-a]}},{key:"lngLatToMercator",value:function(r,n){return{x:0,y:0,z:0}}},{key:"getModelMatrix",value:function(r,n,t){var a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:[1,1,1],u=this.viewport.projectFlat(r),c=Mf();return wd(c,c,Zd(u[0],u[1],n)),Md(c,c,Zd(a[0],a[1],a[2])),Bd(c,c,t[0]),Qd(c,c,t[1]),Jd(c,c,t[2]),c}},{key:"init",value:function(){var i=(0,Li.Z)(Ur().mark(function n(){var t=this,a,u,c,m,E,H,re,xe,ke,rt,vt,It,er,Ar;return Ur().wrap(function(rn){for(;;)switch(rn.prev=rn.next){case 0:return a=this.config,u=a.id,c=a.style,m=c===void 0?"light":c,E=a.minZoom,H=E===void 0?0:E,re=a.maxZoom,xe=re===void 0?18:re,ke=a.token,rt=ke===void 0?AT:ke,vt=a.mapInstance,It=a.plugin,er=It===void 0?[]:It,Ar=(0,X0.Z)(a,HF),rn.next=3,new Promise(function(Ln){var wn=function(){if(vt)t.map=vt,t.$mapContainer=t.map.getContainer(),setTimeout(function(){t.map.on("camerachange",t.handleCameraChanged),Ln()},30);else{t.$mapContainer=t.creatMapContainer(u);var qn=(0,Se.Z)({mapStyle:t.getMapStyleValue(m),zooms:[H,xe],viewMode:"3D"},Ar);qn.zoom&&(qn.zoom+=1);var Si=new AMap.Map(t.$mapContainer,qn);Si.on("camerachange",t.handleCameraChanged),Si.on("camerachange",function(){setTimeout(function(){return t.handleAfterMapChange()})}),t.map=Si,setTimeout(function(){Ln()},10)}};!Sw&&!vt?(rt===AT&&console.warn("%c".concat(t.configService.getSceneWarninfo("MapToken"),"!"),"color: #873bf4;font-weigh:900;font-size: 16px;"),Sw=!0,er.push("Map3D"),tT().load({key:rt,version:KF,plugins:er}).then(function(){wn(),jb.length&&(jb.forEach(function(Cn){return Cn()}),jb=[])}).catch(function(Cn){throw new Error(Cn)})):Sw&&window.AMap||vt?wn():jb.push(wn)});case 3:this.viewport=new by;case 4:case"end":return rn.stop()}},n,this)}));function r(){return i.apply(this,arguments)}return r}()},{key:"meterToCoord",value:function(r,n){var t=AMap.GeometryUtil.distance(hn(AMap.LngLat,(0,On.Z)(r)),hn(AMap.LngLat,(0,On.Z)(n))),a=this.lngLatToCoord(r),u=(0,gi.Z)(a,2),c=u[0],m=u[1],E=this.lngLatToCoord(n),H=(0,gi.Z)(E,2),re=H[0],xe=H[1],ke=Math.sqrt(Math.pow(c-re,2)+Math.pow(m-xe,2));return ke/t}},{key:"updateView",value:function(r){}},{key:"getOverlayContainer",value:function(){}},{key:"exportMap",value:function(r){var n,t=(n=this.getContainer())===null||n===void 0?void 0:n.getElementsByClassName("amap-layer")[0],a=r==="jpg"?t==null?void 0:t.toDataURL("image/jpeg"):t==null?void 0:t.toDataURL("image/png");return a}},{key:"emit",value:function(r){for(var n,t=arguments.length,a=new Array(t>1?t-1:0),u=1;u1?t-1:0),u=1;uLn?n.coordinateSystemService.setCoordinateSystem(ne.P20_OFFSET):n.coordinateSystemService.setCoordinateSystem(ne.P20),n.cameraChangedCallback(n.viewport)}}),n}return(0,ot.Z)(r,[{key:"getModelMatrix",value:function(t,a,u){var c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:[1,1,1],m=this.viewport.projectFlat(t),E=Mf();return wd(E,E,Zd(m[0],m[1],a)),Md(E,E,Zd(c[0],c[1],c[2])),Bd(E,E,u[0]),Qd(E,E,u[1]),Jd(E,E,u[2]),E}},{key:"init",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u=this,c,m,E,H,re,xe,ke,rt,vt,It,er,Ar,Or,rn;return Ur().wrap(function(wn){for(;;)switch(wn.prev=wn.next){case 0:return c=this.config,m=c.id,E=c.style,H=E===void 0?"light":E,re=c.minZoom,xe=re===void 0?0:re,ke=c.maxZoom,rt=ke===void 0?18:ke,vt=c.token,It=vt===void 0?ST:vt,er=c.mapInstance,Ar=c.plugin,Or=Ar===void 0?[]:Ar,rn=(0,X0.Z)(c,oB),wn.next=3,new Promise(function(Cn){var qn=function(){if(er)u.map=er,u.$mapContainer=u.map.getContainer(),setTimeout(function(){u.map.on("camerachange",u.handleCameraChanged),Cn()},30);else{u.$mapContainer=u.creatMapContainer(m);var po=(0,Se.Z)({mapStyle:u.getMapStyleValue(H),zooms:[xe,rt],viewMode:"3D"},rn);po.zoom&&(po.zoom+=1);var Ao=new AMap.Map(u.$mapContainer,po);Ao.on("camerachange",u.handleCameraChanged),Ao.on("camerachange",function(){setTimeout(function(){return u.handleAfterMapChange()})}),u.map=Ao,setTimeout(function(){Cn()},10)}};!Cw&&!er?(It===ST&&console.warn(u.configService.getSceneWarninfo("MapToken")),Cw=!0,Or.push("Map3D"),nB.load({key:It,version:uB,plugins:Or}).then(function(Si){qn(),Vb.length&&(Vb.forEach(function(po){return po()}),Vb=[])}).catch(function(Si){throw new Error(Si)})):Cw&&window.AMap||er?qn():Vb.push(qn)});case 3:this.viewport=new iB;case 4:case"end":return wn.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"meterToCoord",value:function(t,a){var u=AMap.GeometryUtil.distance(hn(AMap.LngLat,(0,On.Z)(t)),hn(AMap.LngLat,(0,On.Z)(a))),c=this.lngLatToCoord(t),m=(0,gi.Z)(c,2),E=m[0],H=m[1],re=this.lngLatToCoord(a),xe=(0,gi.Z)(re,2),ke=xe[0],rt=xe[1],vt=Math.sqrt(Math.pow(E-ke,2)+Math.pow(H-rt,2));return vt/u}},{key:"updateView",value:function(t){}},{key:"getOverlayContainer",value:function(){}},{key:"exportMap",value:function(t){var a,u=(a=this.getContainer())===null||a===void 0?void 0:a.getElementsByClassName("amap-layer")[0],c=t==="jpg"?u==null?void 0:u.toDataURL("image/jpeg"):u==null?void 0:u.toDataURL("image/png");return c}},{key:"onCameraChanged",value:function(t){this.cameraChangedCallback=t}}]),r}(bT))||ET);function fB(e){var i=hB();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function hB(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var dB=function(e){(0,Me.Z)(r,e);var i=fB(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getServiceConstructor",value:function(){return cB}}]),r}(Vv),pB=function(){function e(){(0,We.Z)(this,e),(0,St.Z)(this,"projectionMatrix",Mf()),(0,St.Z)(this,"viewMatrix",Mf()),(0,St.Z)(this,"viewProjectionMatrix",Mf()),(0,St.Z)(this,"ViewProjectionMatrixUncentered",Mf()),(0,St.Z)(this,"viewUncenteredMatrix",Mf())}return(0,ot.Z)(e,[{key:"syncWithMapCamera",value:function(r){var n=r.zoom,t=n===void 0?1:n,a=r.center,u=a===void 0?[0,0]:a,c=r.offsetOrigin,m=c===void 0?[0,0]:c,E=r.cameraPosition,H=E===void 0?[0,0,0]:E,re=r.up,xe=re===void 0?[0,1,0]:re,ke=r.lookAt,rt=ke===void 0?[0,0,0]:ke,vt=r.aspect,It=vt===void 0?1:vt,er=r.near,Ar=er===void 0?.1:er,Or=r.far,rn=Or===void 0?1e3:Or,Ln=r.fov,wn=Ln===void 0?45:Ln;this.zoom=t,this.center=u,wr(this.projectionMatrix,wn/180*Math.PI,It,Ar,rn);var Cn=Zd.apply(p,(0,On.Z)(H)),qn=Zd.apply(p,(0,On.Z)(rt)),Si=Zd.apply(p,(0,On.Z)(xe));Tn(this.viewMatrix,Cn,qn,Si),this.viewUncenteredMatrix=lm(this.viewMatrix),wd(this.viewMatrix,this.viewMatrix,Zd(-m[0],m[1],0)),Gh(this.viewProjectionMatrix,this.projectionMatrix,this.viewMatrix),Gh(this.ViewProjectionMatrixUncentered,this.projectionMatrix,this.viewMatrix)}},{key:"getZoom",value:function(){return this.zoom}},{key:"getZoomScale",value:function(){return 1048576}},{key:"getCenter",value:function(){var r=(0,gi.Z)(this.center,2),n=r[0],t=r[1];return[n,t]}},{key:"getProjectionMatrix",value:function(){return this.projectionMatrix}},{key:"getModelMatrix",value:function(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}},{key:"getViewMatrix",value:function(){return this.viewMatrix}},{key:"getViewMatrixUncentered",value:function(){return this.viewUncenteredMatrix}},{key:"getViewProjectionMatrix",value:function(){return this.viewProjectionMatrix}},{key:"getViewProjectionMatrixUncentered",value:function(){return this.ViewProjectionMatrixUncentered}},{key:"getFocalDistance",value:function(){return 1.2}},{key:"projectFlat",value:function(r){var n=85.0511287798,t=Math.max(Math.min(n,r[1]),-n),a=256<<20,u=Math.PI/180,c=r[0]*u,m=t*u;m=Math.log(Math.tan(Math.PI/4+m/2));var E=.5/Math.PI,H=.5,re=-.5/Math.PI;return u=.5,c=a*(E*c+H)-215440491,m=-(a*(re*m+u)-106744817),[c,m]}}]),e}(),mB=["id","style","minZoom","maxZoom","token","mapInstance","plugin","version"],CT,TT;function vB(e){var i=gB();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function gB(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}function yB(e,i){var r=typeof my!="undefined"&&!!my&&typeof my.showToast=="function"&&my.isFRM!==!0,n=typeof wx!="undefined"&&wx!==null&&(typeof wx.request!="undefined"||typeof wx.miniProgram!="undefined");if(!(r||n)&&(i||(i=document),!!i)){var t=i.head||i.getElementsByTagName("head")[0];if(!t){t=i.createElement("head");var a=i.body||i.getElementsByTagName("body")[0];a?a.parentNode.insertBefore(t,a):i.documentElement.appendChild(t)}var u=i.createElement("style");return u.type="text/css",u.styleSheet?u.styleSheet.cssText=e:u.appendChild(i.createTextNode(e)),t.appendChild(u),u}}yB(`.amap-logo{ + display: none !important; +} +.amap-copyright { + display: none !important; +} +`);var MT=[108.92361,34.54083];window.forceWebGL=!0;var PT="f59bcf249433f8b05caaee19f349b3d7",IT="2.0",o$=!1,a$=null,_B=(CT=(0,sa.b2)(),CT(TT=function(e){(0,Me.Z)(r,e);var i=vB(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;ua.getLng()||c.lng3&&arguments[3]!==void 0?arguments[3]:[1,1,1],m=this.map.customCoords.lngLatToCoord(t),E=Mf();return wd(E,E,Zd(m[0],m[1],a)),Md(E,E,Zd(c[0],c[1],c[2])),Bd(E,E,u[0]),Qd(E,E,u[1]),Jd(E,E,u[2]),E}},{key:"init",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E,H,re,xe,ke,rt,vt,It,er,Ar,Or,rn,Ln,wn,Cn,qn,Si,po,Ao;return Ur().wrap(function(Ya){for(;;)switch(Ya.prev=Ya.next){case 0:if(u=this.config,c=u.id,m=u.style,E=m===void 0?"light":m,H=u.minZoom,re=H===void 0?0:H,xe=u.maxZoom,ke=xe===void 0?24:xe,rt=u.token,vt=rt===void 0?PT:rt,It=u.mapInstance,er=u.plugin,Ar=er===void 0?[]:er,Or=u.version,rn=Or===void 0?IT:Or,Ln=(0,X0.Z)(u,mB),this.viewport=new pB,window.AMap||It){Ya.next=6;break}return Ar.push("Map3D"),Ya.next=6,tT().load({key:vt,version:IT,plugins:Ar});case 6:It?(this.map=It,this.$mapContainer=this.map.getContainer(),Cn=this.map.getCenter(),(wn=this.map.customCoords)===null||wn===void 0||wn.setCenter([Cn.lng,Cn.lat]),this.setCustomCoordCenter([Cn.lng,Cn.lat]),this.map.on("viewchange",this.handleViewChanged)):(this.$mapContainer=this.creatMapContainer(c),Si=(0,Se.Z)({mapStyle:this.getMapStyleValue(E),zooms:[re,ke],viewMode:"3D"},Ln),Si.zoom&&(Si.zoom+=1),vt===PT&&(window._AMapSecurityConfig={securityJsCode:"2653011adeb04230b3a26cc9a780a800"},console.warn("%c".concat(this.configService.getSceneWarninfo("MapToken"),"!"),"color: #873bf4;font-weigh:900;font-size: 16px;")),po=new AMap.Map(this.$mapContainer,Si),this.map=po,Ao=po.getCenter(),(qn=this.map.customCoords)===null||qn===void 0||qn.setCenter([Ao.lng,Ao.lat]),this.setCustomCoordCenter([Ao.lng,Ao.lat]),po.on("viewchange",this.handleViewChanged)),this.initViewPort();case 8:case"end":return Ya.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"getMapContainer",value:function(){return this.$mapContainer}},{key:"onCameraChanged",value:function(t){this.cameraChangedCallback=t}},{key:"initViewPort",value:function(){var t,a=((t=this.map.customCoords)===null||t===void 0?void 0:t.getCameraParams())||{},u=a.fov,c=a.near,m=a.far,E=a.aspect,H=a.position,re=a.lookAt,xe=a.up;this.emit("mapchange");var ke=this.map.customCoords.getCenter(),rt=this.map.getZoom();this.cameraChangedCallback&&(this.viewport.syncWithMapCamera({aspect:E,far:m,fov:u,cameraPosition:H,lookAt:re,near:c,up:xe,zoom:rt-1,center:ke,offsetOrigin:[H[0],H[1]]}),this.coordinateSystemService.setCoordinateSystem(ne.P20_2),this.cameraChangedCallback(this.viewport))}},{key:"_sub",value:function(t,a){var u=[0,0];return u[0]=t[0]-a[0],u[1]=t[1]-a[1],u}}]),r}(bT))||TT);function AB(e){var i=bB();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function bB(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var RT=function(e){(0,Me.Z)(r,e);var i=AB(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getServiceConstructor",value:function(){return _B}}]),r}(Vv),xB={light:"mapbox://styles/zcxduo/ck2ypyb1r3q9o1co1766dex29",dark:"mapbox://styles/zcxduo/ck241p6413s0b1cpayzldv7x7",normal:"mapbox://styles/mapbox/streets-v11",blank:{version:8,sources:{},layers:[{id:"background",type:"background",layout:{visibility:"none"}}]}},OT,LT,DT,kT,FT,BT,$1,NT,zT,ZT,UT,jT={mapmove:"move",camerachange:"move",zoomchange:"zoom",dragging:"drag"},wB=12,Ng=(OT=(0,sa.b2)(),LT=(0,sa.f3)(sr.MapConfig),DT=(0,sa.f3)(sr.IGlobalConfigService),kT=(0,sa.f3)(sr.ICoordinateSystemService),FT=(0,sa.f3)(sr.IEventEmitter),OT(BT=($1=function(){function e(){var i=this;(0,We.Z)(this,e),(0,St.Z)(this,"version","DEFAUlTMAP"),(0,St.Z)(this,"simpleMapCoord",new uT),(0,St.Z)(this,"bgColor","rgba(0.0, 0.0, 0.0, 0.0)"),_(this,"config",NT,this),_(this,"configService",zT,this),_(this,"coordinateSystemService",ZT,this),_(this,"eventEmitter",UT,this),(0,St.Z)(this,"handleCameraChanged",function(r){var n=i.map.getCenter(),t=n.lat,a=n.lng;i.emit("mapchange"),i.viewport.syncWithMapCamera({bearing:i.map.getBearing(),center:[a,t],viewportHeight:i.map.transform.height,pitch:i.map.getPitch(),viewportWidth:i.map.transform.width,zoom:i.map.getZoom(),cameraHeight:0}),i.updateCoordinateSystemService(),i.cameraChangedCallback(i.viewport)})}return(0,ot.Z)(e,[{key:"setBgColor",value:function(r){this.bgColor=r}},{key:"addMarkerContainer",value:function(){var r=this.map.getCanvasContainer();this.markerContainer=Vo("div","l7-marker-container",r),this.markerContainer.setAttribute("tabindex","-1")}},{key:"getMarkerContainer",value:function(){return this.markerContainer}},{key:"getOverlayContainer",value:function(){}},{key:"on",value:function(r,n){e0.indexOf(r)!==-1?this.eventEmitter.on(r,n):this.map.on(jT[r]||r,n)}},{key:"off",value:function(r,n){this.map.off(jT[r]||r,n),this.eventEmitter.off(r,n)}},{key:"getContainer",value:function(){return this.map.getContainer()}},{key:"getMapCanvasContainer",value:function(){return this.map.getCanvasContainer()}},{key:"getSize",value:function(){if(this.version==="SIMPLE")return this.simpleMapCoord.getSize();var r=this.map.transform;return[r.width,r.height]}},{key:"getType",value:function(){return"default"}},{key:"getZoom",value:function(){return this.map.getZoom()}},{key:"setZoom",value:function(r){return this.map.setZoom(r)}},{key:"getCenter",value:function(){return this.map.getCenter()}},{key:"setCenter",value:function(r){this.map.setCenter(r)}},{key:"getPitch",value:function(){return this.map.getPitch()}},{key:"getRotation",value:function(){return this.map.getBearing()}},{key:"getBounds",value:function(){return this.map.getBounds().toArray()}},{key:"getMinZoom",value:function(){return this.map.getMinZoom()}},{key:"getMaxZoom",value:function(){return this.map.getMaxZoom()}},{key:"setRotation",value:function(r){this.map.setBearing(r)}},{key:"zoomIn",value:function(r,n){this.map.zoomIn(r,n)}},{key:"zoomOut",value:function(r,n){this.map.zoomOut(r,n)}},{key:"setPitch",value:function(r){return this.map.setPitch(r)}},{key:"panTo",value:function(r){this.map.panTo(r)}},{key:"panBy",value:function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;this.map.panBy([r,n])}},{key:"fitBounds",value:function(r,n){this.map.fitBounds(r,n)}},{key:"setMaxZoom",value:function(r){this.map.setMaxZoom(r)}},{key:"setMinZoom",value:function(r){this.map.setMinZoom(r)}},{key:"setMapStatus",value:function(r){r.doubleClickZoom===!0&&this.map.doubleClickZoom.enable(),r.doubleClickZoom===!1&&this.map.doubleClickZoom.disable(),r.dragEnable===!1&&this.map.dragPan.disable(),r.dragEnable===!0&&this.map.dragPan.enable(),r.rotateEnable===!1&&this.map.dragRotate.disable(),r.dragEnable===!0&&this.map.dragRotate.enable(),r.keyboardEnable===!1&&this.map.keyboard.disable(),r.keyboardEnable===!0&&this.map.keyboard.enable(),r.zoomEnable===!1&&this.map.scrollZoom.disable(),r.zoomEnable===!0&&this.map.scrollZoom.enable()}},{key:"setZoomAndCenter",value:function(r,n){this.map.flyTo({zoom:r,center:n})}},{key:"setMapStyle",value:function(r){this.map.setStyle(this.getMapStyleValue(r))}},{key:"meterToCoord",value:function(r,n){return 1}},{key:"pixelToLngLat",value:function(r){return this.map.unproject(r)}},{key:"lngLatToPixel",value:function(r){return this.map.project(r)}},{key:"containerToLngLat",value:function(r){return this.map.unproject(r)}},{key:"lngLatToContainer",value:function(r){return this.map.project(r)}},{key:"getMapStyle",value:function(){try{var r,n=(r=this.map.getStyle().sprite)!==null&&r!==void 0?r:"";return/^mapbox:\/\/sprites\/zcxduo\/\w+\/\w+$/.test(n)?n==null?void 0:n.replace(/\/\w+$/,"").replace(/sprites/,"styles"):n}catch(t){return""}}},{key:"getMapStyleConfig",value:function(){return xB}},{key:"getMapStyleValue",value:function(r){var n;return(n=this.getMapStyleConfig()[r])!==null&&n!==void 0?n:r}},{key:"destroy",value:function(){this.eventEmitter.removeAllListeners(),this.map&&(this.map.remove(),this.$mapContainer=null)}},{key:"emit",value:function(r){for(var n,t=arguments.length,a=new Array(t>1?t-1:0),u=1;u1?t-1:0),u=1;uwB&&n?this.coordinateSystemService.setCoordinateSystem(ne.LNGLAT_OFFSET):this.coordinateSystemService.setCoordinateSystem(ne.LNGLAT)}}]),e}(),NT=d($1.prototype,"config",[LT],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),zT=d($1.prototype,"configService",[DT],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),ZT=d($1.prototype,"coordinateSystemService",[kT],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),UT=d($1.prototype,"eventEmitter",[FT],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),$1))||BT);if(!window)throw Error("BMapGL JSAPI can only be used in Browser.");var Gv=function(e){return e.notload="notload",e.loading="loading",e.loaded="loaded",e.failed="failed",e}(Gv||{}),cg={key:"",BMapGL:{version:"1.0"}},zg={BMapGL:Gv.notload},Tw=[],VT=function(i){if(typeof i=="function"){if(zg.BMapGL===Gv.loaded){i(window.BMapGL);return}Tw.push(i)}},EB=function(i){return new Promise(function(r,n){if(zg.BMapGL===Gv.failed)n("");else if(zg.BMapGL===Gv.notload){var t=i.key,a=i.version;if(!t){n("\u8BF7\u586B\u5199key");return}cg.key=t,cg.BMapGL.version=a||cg.BMapGL.version,zg.BMapGL=Gv.loading;var u=document.body||document.head;window.___onBMapGLAPILoaded=function(m){if(delete window.___onBMapGLAPILoaded,m)zg.BMapGL=Gv.failed,n(m);else for(zg.BMapGL=Gv.loaded;Tw.length;)Tw.splice(0,1)[0](window.BMapGL)};var c=document.createElement("script");c.type="text/javascript",c.src="https://api.map.baidu.com/api?type=webgl&v=".concat(cg.BMapGL.version,"&ak=").concat(cg.key,"&callback=___onBMapGLAPILoaded"),c.onerror=function(m){zg.BMapGL=Gv.failed,n(m)},u.appendChild(c),VT(r)}else if(zg.BMapGL===Gv.loaded){if(i.key&&i.key!==cg.key){n("\u591A\u4E2A\u4E0D\u4E00\u81F4\u7684 key");return}if(i.version&&i.version!==cg.BMapGL.version){n("\u4E0D\u5141\u8BB8\u591A\u4E2A\u7248\u672C JSAPI \u6DF7\u7528");return}r(window.BMapGL)}else{if(i.key&&i.key!==cg.key){n("\u591A\u4E2A\u4E0D\u4E00\u81F4\u7684 key");return}if(i.version&&i.version!==cg.BMapGL.version){n("\u4E0D\u5141\u8BB8\u591A\u4E2A\u7248\u672C JSAPI \u6DF7\u7528");return}VT(r)}})},SB=function(){delete window.BMapGL,cg={key:"",BMapGL:{version:"1.0"}},zg={BMapGL:Gv.notload}},CB={load:EB,reset:SB},TB=["id","center","zoom","token","mapInstance","version","mapSize","minZoom","maxZoom"];function MB(e){var i=PB();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function PB(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}function IB(e,i){var r=typeof my!="undefined"&&!!my&&typeof my.showToast=="function"&&my.isFRM!==!0,n=typeof wx!="undefined"&&wx!==null&&(typeof wx.request!="undefined"||typeof wx.miniProgram!="undefined");if(!(r||n)&&(i||(i=document),!!i)){var t=i.head||i.getElementsByTagName("head")[0];if(!t){t=i.createElement("head");var a=i.body||i.getElementsByTagName("body")[0];a?a.parentNode.insertBefore(t,a):i.documentElement.appendChild(t)}var u=i.createElement("style");return u.type="text/css",u.styleSheet?u.styleSheet.cssText=e:u.appendChild(i.createTextNode(e)),t.appendChild(u),u}}IB(`.BMap_cpyCtrl .anchorBL { + display: none !important; +} + +.anchorBL { + display: none !important; +} +`);var $T={mapmove:"moving",contextmenu:"rightclick",camerachange:"update",zoomchange:"zoomend"},HT="zLhopYPPERGtpGOgimcdKcCimGRyyIsh",GT="1.0",RB=function(e){(0,Me.Z)(r,e);var i=MB(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u3&&arguments[3]!==void 0?arguments[3]:[1,1,1],m=this.viewport.projectFlat(t),E=Mf();return wd(E,E,Zd(m[0],m[1],a)),Md(E,E,Zd(c[0],c[1],c[2])),Bd(E,E,u[0]),Qd(E,E,u[1]),Jd(E,E,u[2]),E}},{key:"getCustomCoordCenter",value:function(){throw new Error("Method not implemented.")}},{key:"exportMap",value:function(t){var a=this.getMap()._webglPainter._canvas,u=t==="jpg"?a==null?void 0:a.toDataURL("image/jpeg"):a==null?void 0:a.toDataURL("image/png");return u}},{key:"hideLogo",value:function(){var t=this.map.getContainer();t&&Js(t,"bmap-contianer--hide-logo")}},{key:"initMapByConfig",value:function(t){var a=t.style,u=t.pitch,c=u===void 0?0:u,m=t.rotation,E=m===void 0?0:m,H=t.logoVisible,re=H===void 0?!0:H;a&&this.setMapStyle(a),c&&this.setPitch(c),E&&this.setRotation(E),re===!1&&this.hideLogo()}}]),r}(Ng);function OB(e){var i=LB();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function LB(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var DB=function(e){(0,Me.Z)(r,e);var i=OB(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getServiceConstructor",value:function(){return RB}}]),r}(Vv),kB=A(58240),FB=A.n(kB);function BB(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=NB(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function NB(e,i){if(e){if(typeof e=="string")return WT(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return WT(e,i)}}function WT(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r1?i-1:0),n=1;n90||this.lat<-90)throw new Error("Invalid LngLat latitude value: must be between -90 and 90")}return(0,ot.Z)(e,[{key:"wrap",value:function(){return new e(Pw(this.lng,-180,180),this.lat)}},{key:"toArray",value:function(){return[this.lng,this.lat]}},{key:"toString",value:function(){return"LngLat(".concat(this.lng,", ").concat(this.lat,")")}},{key:"distanceTo",value:function(r){var n=Math.PI/180,t=this.lat*n,a=r.lat*n,u=Math.sin(t)*Math.sin(a)+Math.cos(t)*Math.cos(a)*Math.cos((r.lng-this.lng)*n),c=YT*Math.acos(Math.min(u,1));return c}}],[{key:"convert",value:function(r){if(r instanceof e)return r;if(Array.isArray(r)&&(r.length===2||r.length===3))return new e(Number(r[0]),Number(r[1]));if(!Array.isArray(r)&&(0,df.Z)(r)==="object"&&r!==null){var n="lng"in r?r.lng:r.lon;return new e(Number(n),Number(r.lat))}throw new Error("`LngLatLike` argument must be specified as a LngLat instance, an object {lng: , lat: }, an object {lon: , lat: }, or an array of [, ]")}}]),e}(),Q_=function(){function e(i,r){(0,We.Z)(this,e),i&&(r?this.setSouthWest(i).setNorthEast(r):i.length===4?this.setSouthWest([i[0],i[1]]).setNorthEast([i[2],i[3]]):this.setSouthWest(i[0]).setNorthEast(i[1]))}return(0,ot.Z)(e,[{key:"setNorthEast",value:function(r){return this.ne=r instanceof Z0?new Z0(r.lng,r.lat):Z0.convert(r),this}},{key:"setSouthWest",value:function(r){return this.sw=r instanceof Z0?new Z0(r.lng,r.lat):Z0.convert(r),this}},{key:"extend",value:function(r){var n=this.sw,t=this.ne,a,u;if(r instanceof Z0)a=r,u=r;else if(r instanceof e){if(a=r.sw,u=r.ne,!a||!u)return this}else{if(Array.isArray(r))if(r.length===4||r.every(Array.isArray)){var c=r;return this.extend(e.convert(c))}else{var m=r;return this.extend(Z0.convert(m))}return this}return!n&&!t?(this.sw=new Z0(a.lng,a.lat),this.ne=new Z0(u.lng,u.lat)):(n.lng=Math.min(a.lng,n.lng),n.lat=Math.min(a.lat,n.lat),t.lng=Math.max(u.lng,t.lng),t.lat=Math.max(u.lat,t.lat)),this}},{key:"getCenter",value:function(){return new Z0((this.sw.lng+this.ne.lng)/2,(this.sw.lat+this.ne.lat)/2)}},{key:"getSouthWest",value:function(){return this.sw}},{key:"getNorthEast",value:function(){return this.ne}},{key:"getNorthWest",value:function(){return new Z0(this.getWest(),this.getNorth())}},{key:"getSouthEast",value:function(){return new Z0(this.getEast(),this.getSouth())}},{key:"getWest",value:function(){return this.sw.lng}},{key:"getSouth",value:function(){return this.sw.lat}},{key:"getEast",value:function(){return this.ne.lng}},{key:"getNorth",value:function(){return this.ne.lat}},{key:"toArray",value:function(){return[this.sw.toArray(),this.ne.toArray()]}},{key:"toString",value:function(){return"LngLatBounds(".concat(this.sw.toString(),", ").concat(this.ne.toString(),")")}},{key:"isEmpty",value:function(){return!(this.sw&&this.ne)}},{key:"contains",value:function(r){var n=Z0.convert(r),t=n.lng,a=n.lat,u=this.sw.lat<=a&&a<=this.ne.lat,c=this.sw.lng<=t&&t<=this.ne.lng;return this.sw.lng>this.ne.lng&&(c=this.sw.lng>=t&&t>=this.ne.lng),u&&c}}],[{key:"convert",value:function(r){return r instanceof e?r:new e(r)}}]),e}(),bp=function(){function e(i,r){(0,We.Z)(this,e),this.x=i,this.y=r}return(0,ot.Z)(e,[{key:"clone",value:function(){return new e(this.x,this.y)}},{key:"_add",value:function(r){return this.x+=r.x,this.y+=r.y,this}},{key:"add",value:function(r){return this.clone()._add(r)}},{key:"_sub",value:function(r){return this.x-=r.x,this.y-=r.y,this}},{key:"sub",value:function(r){return this.clone()._sub(r)}},{key:"_multByPoint",value:function(r){return this.x*=r.x,this.y*=r.y,this}},{key:"multByPoint",value:function(r){return this.clone()._multByPoint(r)}},{key:"_divByPoint",value:function(r){return this.x/=r.x,this.y/=r.y,this}},{key:"divByPoint",value:function(r){return this.clone()._divByPoint(r)}},{key:"_mult",value:function(r){return this.x*=r,this.y*=r,this}},{key:"mult",value:function(r){return this.clone()._mult(r)}},{key:"_div",value:function(r){return this.x/=r,this.y/=r,this}},{key:"div",value:function(r){return this.clone()._div(r)}},{key:"_rotate",value:function(r){var n=Math.cos(r),t=Math.sin(r),a=n*this.x-t*this.y,u=t*this.x+n*this.y;return this.x=a,this.y=u,this}},{key:"rotate",value:function(r){return this.clone()._rotate(r)}},{key:"_rotateAround",value:function(r,n){var t=Math.cos(r),a=Math.sin(r),u=n.x+t*(this.x-n.x)-a*(this.y-n.y),c=n.y+a*(this.x-n.x)+t*(this.y-n.y);return this.x=u,this.y=c,this}},{key:"roateAround",value:function(r,n){return this.clone()._rotateAround(r,n)}},{key:"_matMult",value:function(r){var n=r[0]*this.x+r[1]*this.y,t=r[2]*this.x+r[3]*this.y;return this.x=n,this.y=t,this}},{key:"matMult",value:function(r){return this.clone()._matMult(r)}},{key:"_unit",value:function(){return this.div(this.mag()),this}},{key:"unit",value:function(){return this.clone()._unit()}},{key:"_perp",value:function(){var r=this.y;return this.y=this.x,this.x=-r,this}},{key:"perp",value:function(){return this.clone()._perp()}},{key:"_round",value:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}},{key:"round",value:function(){return this.clone()._round()}},{key:"mag",value:function(){return Math.sqrt(this.x*this.x+this.y*this.y)}},{key:"equals",value:function(r){return this.x===r.x&&this.y===r.y}},{key:"dist",value:function(r){return Math.sqrt(this.distSqr(r))}},{key:"distSqr",value:function(r){var n=r.x-this.x,t=r.y-this.y;return n*n+t*t}},{key:"angle",value:function(){return Math.atan2(this.y,this.x)}},{key:"angleTo",value:function(r){return Math.atan2(this.y-r.y,this.x-r.x)}},{key:"angleWith",value:function(r){return this.angleWithSep(r.x,r.y)}},{key:"angleWithSep",value:function(r,n){return Math.atan2(this.x*n-this.y*r,this.x*r+this.y*n)}}],[{key:"convert",value:function(r){return r instanceof e?r:Array.isArray(r)?new e(r[0],r[1]):r}}]),e}();function VB(){var e=new xh(4);return xh!=Float32Array&&(e[1]=0,e[2]=0),e[0]=1,e[3]=1,e}function s$(e){var i=new glMatrix.ARRAY_TYPE(4);return i[0]=e[0],i[1]=e[1],i[2]=e[2],i[3]=e[3],i}function u$(e,i){return e[0]=i[0],e[1]=i[1],e[2]=i[2],e[3]=i[3],e}function l$(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=1,e}function c$(e,i,r,n){var t=new glMatrix.ARRAY_TYPE(4);return t[0]=e,t[1]=i,t[2]=r,t[3]=n,t}function f$(e,i,r,n,t){return e[0]=i,e[1]=r,e[2]=n,e[3]=t,e}function h$(e,i){if(e===i){var r=i[1];e[1]=i[2],e[2]=r}else e[0]=i[0],e[1]=i[2],e[2]=i[1],e[3]=i[3];return e}function d$(e,i){var r=i[0],n=i[1],t=i[2],a=i[3],u=r*a-t*n;return u?(u=1/u,e[0]=a*u,e[1]=-n*u,e[2]=-t*u,e[3]=r*u,e):null}function p$(e,i){var r=i[0];return e[0]=i[3],e[1]=-i[1],e[2]=-i[2],e[3]=r,e}function m$(e){return e[0]*e[3]-e[2]*e[1]}function v$(e,i,r){var n=i[0],t=i[1],a=i[2],u=i[3],c=r[0],m=r[1],E=r[2],H=r[3];return e[0]=n*c+a*m,e[1]=t*c+u*m,e[2]=n*E+a*H,e[3]=t*E+u*H,e}function $B(e,i,r){var n=i[0],t=i[1],a=i[2],u=i[3],c=Math.sin(r),m=Math.cos(r);return e[0]=n*m+a*c,e[1]=t*m+u*c,e[2]=n*-c+a*m,e[3]=t*-c+u*m,e}function g$(e,i,r){var n=i[0],t=i[1],a=i[2],u=i[3],c=r[0],m=r[1];return e[0]=n*c,e[1]=t*c,e[2]=a*m,e[3]=u*m,e}function y$(e,i){var r=Math.sin(i),n=Math.cos(i);return e[0]=n,e[1]=r,e[2]=-r,e[3]=n,e}function _$(e,i){return e[0]=i[0],e[1]=0,e[2]=0,e[3]=i[1],e}function A$(e){return"mat2("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")"}function b$(e){return Math.hypot(e[0],e[1],e[2],e[3])}function x$(e,i,r,n){return e[2]=n[2]/n[0],r[0]=n[0],r[1]=n[1],r[3]=n[3]-e[2]*r[1],[e,i,r]}function w$(e,i,r){return e[0]=i[0]+r[0],e[1]=i[1]+r[1],e[2]=i[2]+r[2],e[3]=i[3]+r[3],e}function E$(e,i,r){return e[0]=i[0]-r[0],e[1]=i[1]-r[1],e[2]=i[2]-r[2],e[3]=i[3]-r[3],e}function S$(e,i){return e[0]===i[0]&&e[1]===i[1]&&e[2]===i[2]&&e[3]===i[3]}function C$(e,i){var r=e[0],n=e[1],t=e[2],a=e[3],u=i[0],c=i[1],m=i[2],E=i[3];return Math.abs(r-u)<=glMatrix.EPSILON*Math.max(1,Math.abs(r),Math.abs(u))&&Math.abs(n-c)<=glMatrix.EPSILON*Math.max(1,Math.abs(n),Math.abs(c))&&Math.abs(t-m)<=glMatrix.EPSILON*Math.max(1,Math.abs(t),Math.abs(m))&&Math.abs(a-E)<=glMatrix.EPSILON*Math.max(1,Math.abs(a),Math.abs(E))}function T$(e,i,r){return e[0]=i[0]*r,e[1]=i[1]*r,e[2]=i[2]*r,e[3]=i[3]*r,e}function M$(e,i,r,n){return e[0]=i[0]+r[0]*n,e[1]=i[1]+r[1]*n,e[2]=i[2]+r[2]*n,e[3]=i[3]+r[3]*n,e}var P$=null,I$=null,HB=function(){function e(){var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,t=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0;if((0,We.Z)(this,e),isNaN(i)||i<0||isNaN(r)||r<0||isNaN(n)||n<0||isNaN(t)||t<0)throw new Error("Invalid value for edge-insets, top, bottom, left and right must all be numbers");this.top=i,this.bottom=r,this.left=n,this.right=t}return(0,ot.Z)(e,[{key:"interpolate",value:function(r,n,t){return n.top!=null&&r.top!=null&&(this.top=Dv(r.top,n.top,t)),n.bottom!=null&&r.bottom!=null&&(this.bottom=Dv(r.bottom,n.bottom,t)),n.left!=null&&r.left!=null&&(this.left=Dv(r.left,n.left,t)),n.right!=null&&r.right!=null&&(this.right=Dv(r.right,n.right,t)),this}},{key:"getCenter",value:function(r,n){var t=Zg((this.left+r-this.right)/2,0,r),a=Zg((this.top+n-this.bottom)/2,0,n);return new bp(t,a)}},{key:"equals",value:function(r){return this.top===r.top&&this.bottom===r.bottom&&this.left===r.left&&this.right===r.right}},{key:"clone",value:function(){return new e(this.top,this.bottom,this.left,this.right)}},{key:"toJSON",value:function(){return{top:this.top,bottom:this.bottom,left:this.left,right:this.right}}}]),e}(),KT=2*Math.PI*YT;function qT(e){return KT*Math.cos(e*Math.PI/180)}function Hb(e){return(180+e)/360}function Gb(e){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+e*Math.PI/360)))/360}function QT(e,i){return e/qT(i)}function GB(e){return e*360-180}function Ow(e){var i=180-e*360;return 360/Math.PI*Math.atan(Math.exp(i*Math.PI/180))-90}function WB(e,i){return e*qT(Ow(i))}function XB(e){return 1/Math.cos(e*Math.PI/180)}var Ug=function(){function e(i,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;(0,We.Z)(this,e),this.x=+i,this.y=+r,this.z=+n}return(0,ot.Z)(e,[{key:"toLngLat",value:function(){return new Z0(GB(this.x),Ow(this.y))}},{key:"toAltitude",value:function(){return WB(this.z,this.y)}},{key:"meterInMercatorCoordinateUnits",value:function(){return 1/KT*XB(Ow(this.y))}}],[{key:"fromLngLat",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,t=Z0.convert(r);return new e(Hb(t.lng),Gb(t.lat),QT(n,t.lat))}}]),e}();function YB(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=KB(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function KB(e,i){if(e){if(typeof e=="string")return JT(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return JT(e,i)}}function JT(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);rn&&(E=n-er)}if(this.lngRange){var Ar=rt.x,Or=H.x/2;Ar-Ora&&(m=a-Or)}(m!==void 0||E!==void 0)&&(this.center=this.unproject(new bp(m!==void 0?m:rt.x,E!==void 0?E:rt.y))),this.unmodified=re,this.constraining=!1}}},{key:"calcMatrices",value:function(){if(this.height){var r=this._fov/2,n=this.centerOffset;this.cameraToCenterDistance=.5/Math.tan(r)*this.height;var t=Math.PI/2+this._pitch,a=this._fov*(.5+n.y/this.height),u=Math.sin(a)*this.cameraToCenterDistance/Math.sin(Zg(Math.PI-t-a,.01,Math.PI-.01)),c=this.point,m=c.x,E=c.y,H=Math.cos(Math.PI/2-this._pitch)*u+this.cameraToCenterDistance,re=H*1.01,xe=this.height/50,ke=new Float64Array(16);wr(ke,this._fov,this.width/this.height,xe,re),ke[8]=-n.x*2/this.width,ke[9]=n.y*2/this.height,Md(ke,ke,[1,-1,1]),wd(ke,ke,[0,0,-this.cameraToCenterDistance]),Bd(ke,ke,this._pitch),Jd(ke,ke,this.angle),wd(ke,ke,[-m,-E,0]),this.mercatorMatrix=Md([],ke,[this.worldSize,this.worldSize,this.worldSize]),Md(ke,ke,[1,1,QT(1,this.center.lat)*this.worldSize,1]),this.projMatrix=ke,this.invProjMatrix=N0([],this.projMatrix);var rt=this.width%2/2,vt=this.height%2/2,It=Math.cos(this.angle),er=Math.sin(this.angle),Ar=m-Math.round(m)+It*rt+er*vt,Or=E-Math.round(E)+It*vt+er*rt,rn=new Float64Array(ke);if(wd(rn,rn,[Ar>.5?Ar-1:Ar,Or>.5?Or-1:Or,0]),this.alignedProjMatrix=rn,ke=Mf(),Md(ke,ke,[this.width/2,-this.height/2,1]),wd(ke,ke,[1,-1,0]),this.labelPlaneMatrix=ke,ke=Mf(),Md(ke,ke,[1,-1,1]),wd(ke,ke,[-1,-1,0]),Md(ke,ke,[2/this.width,2/this.height,1]),this.glCoordMatrix=ke,this.pixelMatrix=Gh(new Float64Array(16),this.labelPlaneMatrix,this.projMatrix),ke=N0(new Float64Array(16),this.pixelMatrix),!ke)throw new Error("failed to invert matrix");this.pixelMatrixInverse=ke,this.posMatrixCache={},this.alignedPosMatrixCache={}}}}]),e}(),QB=lo.merge,u0=(0,ot.Z)(function e(i){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};(0,We.Z)(this,e),QB(this,r),this.type=i});function JB(e){var i=eN();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function eN(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var fg=lo.merge,e5=function(e){(0,Me.Z)(r,e);var i=JB(r);function r(n){var t;(0,We.Z)(this,r),t=i.call(this),(0,St.Z)((0,Fr.Z)(t),"renderFrameCallback",function(){var H=Math.min((xy()-t.easeStart)/t.easeOptions.duration,1);t.onEaseFrame(t.easeOptions.easing(H)),H<1?t.easeFrameId=t.requestRenderFrame(t.renderFrameCallback):t.stop()}),t.options=n;var a=n.minZoom,u=n.maxZoom,c=n.minPitch,m=n.maxPitch,E=n.renderWorldCopies;return t.moving=!1,t.zooming=!1,t.bearingSnap=n.bearingSnap,t.pitchEnabled=n.pitchEnabled,t.rotateEnabled=n.rotateEnabled,t.transform=new qB(a,u,c,m,E),t}return(0,ot.Z)(r,[{key:"requestRenderFrame",value:function(t){return 0}},{key:"cancelRenderFrame",value:function(t){}},{key:"getCenter",value:function(){var t=this.transform.center,a=t.lng,u=t.lat;return new Z0(a,u)}},{key:"getZoom",value:function(){return this.transform.zoom}},{key:"getPitch",value:function(){return this.transform.pitch}},{key:"setCenter",value:function(t,a){return this.jumpTo({center:t},a)}},{key:"setPitch",value:function(t,a){return this.jumpTo({pitch:t},a),this}},{key:"getBearing",value:function(){return this.transform.bearing}},{key:"panTo",value:function(t,a,u){return this.easeTo(fg({center:t},a),u)}},{key:"panBy",value:function(t,a,u){return t=bp.convert(t).mult(-1),this.panTo(this.transform.center,jB({offset:t},a||{}),u)}},{key:"zoomOut",value:function(t,a){return this.zoomTo(this.getZoom()-1,t,a),this}},{key:"setBearing",value:function(t,a){return this.jumpTo({bearing:t},a),this}},{key:"setZoom",value:function(t,a){return this.jumpTo({zoom:t},a),this}},{key:"zoomIn",value:function(t,a){return this.zoomTo(this.getZoom()+1,t,a),this}},{key:"zoomTo",value:function(t,a,u){return this.easeTo(fg({zoom:t},a),u)}},{key:"getPadding",value:function(){return this.transform.padding}},{key:"setPadding",value:function(t,a){return this.jumpTo({padding:t},a),this}},{key:"rotateTo",value:function(t,a,u){return this.easeTo(fg({bearing:t},a),u)}},{key:"resetNorth",value:function(t,a){return this.rotateTo(0,fg({duration:1e3},t),a),this}},{key:"resetNorthPitch",value:function(t,a){return this.easeTo(fg({bearing:0,pitch:0,duration:1e3},t),a),this}},{key:"fitBounds",value:function(t,a,u){return this.fitInternal(this.cameraForBounds(t,a),a,u)}},{key:"cameraForBounds",value:function(t,a){return t=Q_.convert(t),this.cameraForBoxAndBearing(t.getNorthWest(),t.getSouthEast(),0,a)}},{key:"snapToNorth",value:function(t,a){return Math.abs(this.getBearing())0&&arguments[0]!==void 0?arguments[0]:{},a=arguments.length>1?arguments[1]:void 0;this.stop();var u=this.transform,c=!1,m=!1,E=!1;return t.zoom!==void 0&&u.zoom!==+t.zoom&&(c=!0,u.zoom=+t.zoom),t.center!==void 0&&(u.center=Z0.convert(t.center)),t.bearing!==void 0&&u.bearing!==+t.bearing&&(m=!0,u.bearing=+t.bearing),t.pitch!==void 0&&u.pitch!==+t.pitch&&(E=!0,u.pitch=+t.pitch),t.padding!==void 0&&!u.isPaddingEqual(t.padding)&&(u.padding=t.padding),this.emit("movestart",new u0("movestart",a)),this.emit("move",new u0("move",a)),c&&(this.emit("zoomstart",new u0("zoomstart",a)),this.emit("zoom",new u0("zoom",a)),this.emit("zoomend",new u0("zoomend",a))),m&&(this.emit("rotatestart",new u0("rotatestart",a)),this.emit("rotate",new u0("rotate",a)),this.emit("rotateend",new u0("rotateend",a))),E&&(this.emit("pitchstart",new u0("pitchstart",a)),this.emit("pitch",new u0("pitch",a)),this.emit("pitchend",new u0("pitchend",a))),this.emit("moveend",new u0("moveend",a))}},{key:"easeTo",value:function(){var t=this,a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},u=arguments.length>1?arguments[1]:void 0;a=fg({offset:[0,0],duration:500,easing:Rw},a),(a.animate===!1||!a.essential&&XT())&&(a.duration=0);var c=this.transform,m=this.getZoom(),E=this.getBearing(),H=this.getPitch(),re=this.getPadding(),xe=a.zoom?+a.zoom:m,ke=a.bearing?this.normalizeBearing(a.bearing,E):E,rt=a.pitch?+a.pitch:H,vt=a.padding?a.padding:c.padding,It=bp.convert(a.offset),er=c.centerPoint.add(It),Ar=c.pointLocation(er),Or=Z0.convert(a.center||Ar);this.normalizeCenter(Or);var rn=c.project(Ar),Ln=c.project(Or).sub(rn),wn=c.zoomScale(xe-m),Cn,qn;a.around&&(Cn=Z0.convert(a.around),qn=c.locationPoint(Cn));var Si={moving:this.moving,zooming:this.zooming,rotating:this.rotating,pitching:this.pitching};return this.zooming=this.zooming||xe!==m,this.rotating=this.rotating||E!==ke,this.pitching=this.pitching||rt!==H,this.padding=!c.isPaddingEqual(vt),this.easeId=a.easeId,this.prepareEase(u,a.noMoveStart,Si),clearTimeout(this.easeEndTimeoutID),this.ease(function(po){if(t.zooming&&(c.zoom=Dv(m,xe,po)),t.rotating&&t.rotateEnabled&&(c.bearing=Dv(E,ke,po)),t.pitching&&t.pitchEnabled&&(c.pitch=Dv(H,rt,po)),t.padding&&(c.interpolatePadding(re,vt,po),er=c.centerPoint.add(It)),Cn)c.setLocationAtPoint(Cn,qn);else{var Ao=c.zoomScale(c.zoom-m),ma=xe>m?Math.min(2,wn):Math.max(.5,wn),Ya=Math.pow(ma,1-po),fs=c.unproject(rn.add(Ln.mult(po*Ya)).mult(Ao));c.setLocationAtPoint(c.renderWorldCopies?fs.wrap():fs,er)}t.fireMoveEvents(u)},function(po){t.afterEase(u,po)},a),this}},{key:"flyTo",value:function(){var t=this,a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},u=arguments.length>1?arguments[1]:void 0;if(!a.essential&&XT()){var c=zB(a,["center","zoom","bearing","pitch","around"]);return this.jumpTo(c,u)}this.stop(),a=fg({offset:[0,0],speed:1.2,curve:1.42,easing:Rw},a);var m=this.transform,E=this.getZoom(),H=this.getBearing(),re=this.getPitch(),xe=this.getPadding(),ke=a.zoom?Zg(+a.zoom,m.minZoom,m.maxZoom):E,rt=a.bearing?this.normalizeBearing(a.bearing,H):H,vt=a.pitch?+a.pitch:re,It="padding"in a?a.padding:m.padding,er=m.zoomScale(ke-E),Ar=bp.convert(a.offset),Or=m.centerPoint.add(Ar),rn=m.pointLocation(Or),Ln=Z0.convert(a.center||rn);this.normalizeCenter(Ln);var wn=m.project(rn),Cn=m.project(Ln).sub(wn),qn=a.curve,Si=Math.max(m.width,m.height),po=Si/er,Ao=Cn.mag();if("minZoom"in a){var ma=Zg(Math.min(a.minZoom,E,ke),m.minZoom,m.maxZoom),Ya=Si/m.zoomScale(ma-E);qn=Math.sqrt(Ya/Ao*2)}var fs=qn*qn;function bf(K0){var gv=(po*po-Si*Si+(K0?-1:1)*fs*fs*Ao*Ao)/(2*(K0?po:Si)*fs*Ao);return Math.log(Math.sqrt(gv*gv+1)-gv)}function th(K0){return(Math.exp(K0)-Math.exp(-K0))/2}function Yh(K0){return(Math.exp(K0)+Math.exp(-K0))/2}function Lp(K0){return th(K0)/Yh(K0)}var vd=bf(0),Tm=function(gv){return Yh(vd)/Yh(vd+qn*gv)},Iy=function(gv){return Si*((Yh(vd)*Lp(vd+qn*gv)-th(vd))/fs)/Ao},Kg=(bf(1)-vd)/qn;if(Math.abs(Ao)<1e-6||!isFinite(Kg)){if(Math.abs(Si-po)<1e-6)return this.easeTo(a,u);var d_=poa.maxDuration&&(a.duration=0),this.zooming=!0,this.rotating=H!==rt,this.pitching=vt!==re,this.padding=!m.isPaddingEqual(It),this.prepareEase(u,!1),this.ease(function(K0){var gv=K0*Kg,k2=1/Tm(gv);m.zoom=K0===1?ke:E+m.scaleZoom(k2),t.rotating&&(m.bearing=Dv(H,rt,K0)),t.pitching&&(m.pitch=Dv(re,vt,K0)),t.padding&&(m.interpolatePadding(xe,It,K0),Or=m.centerPoint.add(Ar));var F2=K0===1?Ln:m.unproject(wn.add(Cn.mult(Iy(gv))).mult(k2));m.setLocationAtPoint(m.renderWorldCopies?F2.wrap():F2,Or),t.fireMoveEvents(u)},function(){return t.afterEase(u)},a),this}},{key:"fitScreenCoordinates",value:function(t,a,u,c,m){return this.fitInternal(this.cameraForBoxAndBearing(this.transform.pointLocation(bp.convert(t)),this.transform.pointLocation(bp.convert(a)),u,c),c,m)}},{key:"stop",value:function(t,a){if(this.easeFrameId&&(this.cancelRenderFrame(this.easeFrameId),delete this.easeFrameId,delete this.onEaseFrame),this.onEaseEnd){var u=this.onEaseEnd;delete this.onEaseEnd,u.call(this,a)}return this}},{key:"normalizeBearing",value:function(t,a){t=Pw(t,-180,180);var u=Math.abs(t-a);return Math.abs(t-360-a)180?-360:u<-180?360:0}}},{key:"fireMoveEvents",value:function(t){this.emit("move",new u0("move",t)),this.zooming&&this.emit("zoom",new u0("zoom",t)),this.rotating&&this.emit("rotate",new u0("rotate",t)),this.pitching&&this.emit("rotate",new u0("pitch",t))}},{key:"prepareEase",value:function(t){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.moving=!0,!a&&!u.moving&&this.emit("movestart",new u0("movestart",t)),this.zooming&&!u.zooming&&this.emit("zoomstart",new u0("zoomstart",t)),this.rotating&&!u.rotating&&this.emit("rotatestart",new u0("rotatestart",t)),this.pitching&&!u.pitching&&this.emit("pitchstart",new u0("pitchstart",t))}},{key:"afterEase",value:function(t,a){if(!(this.easeId&&a&&this.easeId===a)){delete this.easeId;var u=this.zooming,c=this.rotating,m=this.pitching;this.moving=!1,this.zooming=!1,this.rotating=!1,this.pitching=!1,this.padding=!1,u&&this.emit("zoomend",new u0("zoomend",t)),c&&this.emit("rotateend",new u0("rotateend",t)),m&&this.emit("pitchend",new u0("pitchend",t)),this.emit("moveend",new u0("moveend",t))}}},{key:"ease",value:function(t,a,u){u.animate===!1||u.duration===0?(t(1),a()):(this.easeStart=xy(),this.easeOptions=u,this.onEaseFrame=t,this.onEaseEnd=a,this.easeFrameId=this.requestRenderFrame(this.renderFrameCallback))}},{key:"cameraForBoxAndBearing",value:function(t,a,u,c){var m={top:0,bottom:0,right:0,left:0};if(c=fg({padding:m,offset:[0,0],maxZoom:this.transform.maxZoom},c),typeof c.padding=="number"){var E=c.padding;c.padding={top:E,bottom:E,right:E,left:E}}c.padding=fg(m,c.padding);var H=this.transform,re=H.padding,xe=H.project(Z0.convert(t)),ke=H.project(Z0.convert(a)),rt=xe.rotate(-u*Math.PI/180),vt=ke.rotate(-u*Math.PI/180),It=new bp(Math.max(rt.x,vt.x),Math.max(rt.y,vt.y)),er=new bp(Math.min(rt.x,vt.x),Math.min(rt.y,vt.y)),Ar=It.sub(er),Or=(H.width-(re.left+re.right+c.padding.left+c.padding.right))/Ar.x,rn=(H.height-(re.top+re.bottom+c.padding.top+c.padding.bottom))/Ar.y;if(!(rn<0||Or<0)){var Ln=Math.min(H.scaleZoom(H.scale*Math.min(Or,rn)),c.maxZoom),wn=bp.convert(c.offset),Cn=(c.padding.left-c.padding.right)/2,qn=(c.padding.top-c.padding.bottom)/2,Si=new bp(wn.x+Cn,wn.y+qn),po=Si.mult(H.scale/H.zoomScale(Ln)),Ao=H.unproject(xe.add(ke).div(2).sub(po));return{center:Ao,zoom:Ln,bearing:u}}}},{key:"fitInternal",value:function(t,a,u){return t?(a=fg(t,a),delete a.padding,a.linear?this.easeTo(a,u):this.flyTo(a,u)):this}}]),r}(cu.EventEmitter);function t5(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=tN(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function tN(e,i){if(e){if(typeof e=="string")return r5(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return r5(e,i)}}function r5(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r3&&arguments[3]!==void 0?arguments[3]:{};"passive"in n&&Wb?e.addEventListener(i,r,n):e.addEventListener(i,r,n.capture)},wv.removeEventListener=function(e,i,r){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};"passive"in n&&Wb?e.removeEventListener(i,r,n):e.removeEventListener(i,r,n.capture)};var o5=function e(i){i.preventDefault(),i.stopPropagation(),window.removeEventListener("click",e,!0)};wv.suppressClick=function(){window.addEventListener("click",o5,!0),setTimeout(function(){window.removeEventListener("click",o5,!0)},0)},wv.mousePos=function(e,i){var r=e.getBoundingClientRect();return new bp(i.clientX-r.left-e.clientLeft,i.clientY-r.top-e.clientTop)},wv.touchPos=function(e,i){var r=e.getBoundingClientRect(),n=[],t=t5(i),a;try{for(t.s();!(a=t.n()).done;){var u=a.value;n.push(new bp(u.clientX-r.left-e.clientLeft,u.clientY-r.top-e.clientTop))}}catch(c){t.e(c)}finally{t.f()}return n},wv.mouseButton=function(e){return e.button},wv.remove=function(e){e.parentNode&&e.parentNode.removeChild(e)};function nN(e){var i=iN();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function iN(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var oN=lo.merge,jg=function(e){(0,Me.Z)(r,e);var i=nN(r);function r(n,t,a){var u,c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};(0,We.Z)(this,r);var m=Wm.mousePos(t.getCanvasContainer(),a),E=t.unproject(m);return u=i.call(this,n,oN({point:m,lngLat:E,originalEvent:a},c)),u.defaultPrevented=!1,u.target=t,u}return(0,ot.Z)(r,[{key:"preventDefault",value:function(){this.defaultPrevented=!0}}]),r}(u0);function aN(e){var i=sN();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function sN(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var Yb=function(e){(0,Me.Z)(r,e);var i=aN(r);function r(n,t,a){var u;(0,We.Z)(this,r);var c=n==="touchend"?a.changedTouches:a.touches,m=Wm.touchPos(t.getCanvasContainer(),c),E=m.map(function(xe){return t.unproject(xe)}),H=m.reduce(function(xe,ke,rt,vt){return xe.add(ke.div(vt.length))},new bp(0,0)),re=t.unproject(H);return u=i.call(this,n,{points:m,point:H,lngLats:E,lngLat:re,originalEvent:a}),u.defaultPrevented=!1,u}return(0,ot.Z)(r,[{key:"preventDefault",value:function(){this.defaultPrevented=!0}}]),r}(u0);function uN(e){var i=lN();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function lN(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var cN=function(e){(0,Me.Z)(r,e);var i=uN(r);function r(n,t,a){var u;return(0,We.Z)(this,r),u=i.call(this,n,{originalEvent:a}),u.defaultPrevented=!1,u}return(0,ot.Z)(r,[{key:"preventDefault",value:function(){this.defaultPrevented=!0}}]),r}(u0),fN=function(){function e(i){(0,We.Z)(this,e),this.map=i}return(0,ot.Z)(e,[{key:"reset",value:function(){this.delayContextMenu=!1,delete this.contextMenuEvent}},{key:"mousemove",value:function(r){this.map.emit(r.type,new jg(r.type,this.map,r))}},{key:"mousedown",value:function(){this.delayContextMenu=!0}},{key:"mouseup",value:function(){this.delayContextMenu=!1,this.contextMenuEvent&&(this.map.emit("contextmenu",new jg("contextmenu",this.map,this.contextMenuEvent)),delete this.contextMenuEvent)}},{key:"contextmenu",value:function(r){this.delayContextMenu?this.contextMenuEvent=r:this.map.emit(r.type,new jg(r.type,this.map,r)),this.map.listeners("contextmenu")&&r.preventDefault()}},{key:"isEnabled",value:function(){return!0}},{key:"isActive",value:function(){return!1}},{key:"enable",value:function(){return!0}},{key:"disable",value:function(){return!1}}]),e}(),hN=function(){function e(i,r){(0,We.Z)(this,e),this.map=i,this.el=i.getCanvasContainer(),this.container=i.getContainer(),this.clickTolerance=r.clickTolerance||1}return(0,ot.Z)(e,[{key:"isEnabled",value:function(){return!!this.enabled}},{key:"isActive",value:function(){return!!this.active}},{key:"enable",value:function(){this.isEnabled()||(this.enabled=!0)}},{key:"disable",value:function(){this.isEnabled()&&(this.enabled=!1)}},{key:"mousedown",value:function(r,n){this.isEnabled()&&r.shiftKey&&r.button===0&&(Wm.disableDrag(),this.startPos=this.lastPos=n,this.active=!0)}},{key:"mousemoveWindow",value:function(r,n){if(this.active){var t=n;if(!(this.lastPos.equals(t)||!this.box&&t.dist(this.startPos)=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function _N(e,i){if(e){if(typeof e=="string")return a5(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return a5(e,i)}}function a5(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r0&&n-r[0].time>t;)r.shift()}},{key:"onMoveEnd",value:function(r){if(this.drainInertiaBuffer(),!(this.inertiaBuffer.length<2)){var n={zoom:0,bearing:0,pitch:0,pan:new bp(0,0),pinchAround:void 0,around:void 0},t=yN(this.inertiaBuffer),a;try{for(t.s();!(a=t.n()).done;){var u=a.value.settings;n.zoom+=u.zoomDelta||0,n.bearing+=u.bearingDelta||0,n.pitch+=u.pitchDelta||0,u.panDelta&&n.pan._add(u.panDelta),u.around&&(n.around=u.around),u.pinchAround&&(n.pinchAround=u.pinchAround)}}catch(vt){t.e(vt)}finally{t.f()}var c=this.inertiaBuffer[this.inertiaBuffer.length-1],m=c.time-this.inertiaBuffer[0].time,E={};if(n.pan.mag()){var H=Qb(n.pan.mag(),m,H1({},AN,r||{}));E.offset=n.pan.mult(H.amount/n.pan.mag()),E.center=this.map.transform.center,qb(E,H)}if(n.zoom){var re=Qb(n.zoom,m,bN);E.zoom=this.map.transform.zoom+re.amount,qb(E,re)}if(n.bearing){var xe=Qb(n.bearing,m,xN);E.bearing=this.map.transform.bearing+Zg(xe.amount,-179,179),qb(E,xe)}if(n.pitch){var ke=Qb(n.pitch,m,wN);E.pitch=this.map.transform.pitch+ke.amount,qb(E,ke)}if(E.zoom||E.bearing){var rt=n.pinchAround===void 0?n.around:n.pinchAround;E.around=rt?this.map.unproject(rt):this.map.getCenter()}return this.clear(),H1(E,{noMoveStart:!0})}}}]),e}();function qb(e,i){(!e.duration||e.duration=this.clickTolerance||this.map.emit(r.type,new jg(r.type,this.map,r))}},{key:"dblclick",value:function(r){return this.firePreventable(new jg(r.type,this.map,r))}},{key:"mouseover",value:function(r){this.map.emit(r.type,new jg(r.type,this.map,r))}},{key:"mouseout",value:function(r){this.map.emit(r.type,new jg(r.type,this.map,r))}},{key:"touchstart",value:function(r){return this.firePreventable(new Yb(r.type,this.map,r))}},{key:"touchmove",value:function(r){this.map.emit(r.type,new Yb(r.type,this.map,r))}},{key:"touchend",value:function(r){this.map.emit(r.type,new Yb(r.type,this.map,r))}},{key:"touchcancel",value:function(r){this.map.emit(r.type,new Yb(r.type,this.map,r))}},{key:"firePreventable",value:function(r){if(this.map.emit(r.type,r),r.defaultPrevented)return{}}},{key:"isEnabled",value:function(){return!0}},{key:"isActive",value:function(){return!1}},{key:"enable",value:function(){return!1}},{key:"disable",value:function(){return!1}}]),e}(),Jb,e2=0,Lw=2,IN=(Jb={},(0,St.Z)(Jb,e2,1),(0,St.Z)(Jb,Lw,2),Jb);function RN(e,i){var r=IN[i];return e.buttons===void 0||(e.buttons&r)!==r}var Dw=function(){function e(i){(0,We.Z)(this,e),this.reset(),this.clickTolerance=i.clickTolerance||1}return(0,ot.Z)(e,[{key:"reset",value:function(){this.active=!1,this.moved=!1,delete this.lastPoint,delete this.eventButton}},{key:"mousedown",value:function(r,n){if(!this.lastPoint){var t=Wm.mouseButton(r);this.correctButton(r,t)&&(this.lastPoint=n,this.eventButton=t)}}},{key:"mousemoveWindow",value:function(r,n){var t=this.lastPoint;if(t){if(r.preventDefault(),RN(r,this.eventButton)){this.reset();return}if(!(!this.moved&&n.dist(t)s5?n.wheelZoomRate:n.defaultZoomRate,u=VN/(1+Math.exp(-Math.abs(n.delta*a)));n.delta<0&&u!==0&&(u=1/u);var c=typeof n.targetZoom=="number"?t.zoomScale(n.targetZoom):t.scale;n.targetZoom=Math.min(t.maxZoom,Math.max(t.minZoom,t.scaleZoom(c*u))),n.type==="wheel"&&(n.startZoom=t.zoom,n.easing=n.smoothOutEasing(200)),n.delta=0}var m=typeof n.targetZoom=="number"?n.targetZoom:t.zoom,E=n.startZoom,H=n.easing,re=!1,xe;if(n.type==="wheel"&&E&&H){var ke=Math.min((xy()-n.lastWheelEventTime)/200,1),rt=H(ke);xe=Dv(E,m,rt),ke<1?n.frameId||(n.frameId=!0):re=!0}else xe=m,re=!0;return n.active=!0,re&&(n.active=!1,n.finishTimeout=setTimeout(function(){n.zooming=!1,n.handler.triggerRenderFrame(),delete n.targetZoom,delete n.finishTimeout},200)),{noInertia:!0,needsRenderFrame:!re,zoomDelta:xe-t.zoom,around:n.aroundPoint,originalEvent:n.lastWheelEvent}}}),this.map=i,this.el=i.getCanvasContainer(),this.handler=r,this.delta=0,this.defaultZoomRate=UN,this.wheelZoomRate=jN}return(0,ot.Z)(e,[{key:"setZoomRate",value:function(r){this.defaultZoomRate=r}},{key:"setWheelZoomRate",value:function(r){this.wheelZoomRate=r}},{key:"isEnabled",value:function(){return!!this.enabled}},{key:"isActive",value:function(){return!!this.active||this.finishTimeout!==void 0}},{key:"isZooming",value:function(){return!!this.zooming}},{key:"enable",value:function(r){this.isEnabled()||(this.enabled=!0,this.aroundCenter=r&&r.around==="center")}},{key:"disable",value:function(){this.isEnabled()&&(this.enabled=!1)}},{key:"wheel",value:function(r){if(this.isEnabled()){var n=r.deltaMode===window.WheelEvent.DOM_DELTA_LINE?r.deltaY*40:r.deltaY,t=xy(),a=t-(this.lastWheelEventTime||0);this.lastWheelEventTime=t,n!==0&&n%s5===0?this.type="wheel":n!==0&&Math.abs(n)<4?this.type="trackpad":a>400?(this.type=null,this.lastValue=n,this.timeout=setTimeout(this.onTimeout,40,r)):this.type||(this.type=Math.abs(a*n)<200?"trackpad":"wheel",this.timeout&&(clearTimeout(this.timeout),this.timeout=null,n+=this.lastValue)),r.shiftKey&&n&&(n=n/4),this.type&&(this.lastWheelEvent=r,this.delta-=n,this.active||this.start(r)),r.preventDefault()}}},{key:"renderFrame",value:function(){return this.onScrollFrame()}},{key:"reset",value:function(){this.active=!1}},{key:"onTimeout",value:function(r){this.type="wheel",this.delta-=this.lastValue,!this.active&&this.start&&this.start(r)}},{key:"start",value:function(r){if(this.delta){this.frameId&&(this.frameId=null),this.active=!0,this.isZooming()||(this.zooming=!0),this.finishTimeout&&(clearTimeout(this.finishTimeout),delete this.finishTimeout);var n=Wm.mousePos(this.el,r);this.around=Z0.convert(this.aroundCenter?this.map.getCenter():this.map.unproject(n)),this.aroundPoint=this.map.transform.locationPoint(this.around),this.frameId||(this.frameId=!0,this.handler.triggerRenderFrame())}}},{key:"smoothOutEasing",value:function(r){var n=Rw;if(this.prevEase){var t=this.prevEase,a=(xy()-t.start)/t.duration,u=t.easing(a+.01)-t.easing(a),c=.27/Math.sqrt(u*u+1e-4)*.01,m=Math.sqrt(.27*.27-c*c);n=Iw(c,m,.25,1)}return this.prevEase={start:xy(),duration:r,easing:n},n}}]),e}(),HN=$N,GN=function(){function e(i,r){(0,We.Z)(this,e),this.clickZoom=i,this.tapZoom=r}return(0,ot.Z)(e,[{key:"enable",value:function(){this.clickZoom.enable(),this.tapZoom.enable()}},{key:"disable",value:function(){this.clickZoom.disable(),this.tapZoom.disable()}},{key:"isEnabled",value:function(){return this.clickZoom.isEnabled()&&this.tapZoom.isEnabled()}},{key:"isActive",value:function(){return this.clickZoom.isActive()||this.tapZoom.isActive()}}]),e}(),WN=function(){function e(i,r,n){(0,We.Z)(this,e),this.el=i,this.mousePan=r,this.touchPan=n}return(0,ot.Z)(e,[{key:"enable",value:function(r){this.inertiaOptions=r||{},this.mousePan.enable(),this.touchPan.enable(),this.el.classList.add("l7-touch-drag-pan")}},{key:"disable",value:function(){this.mousePan.disable(),this.touchPan.disable(),this.el.classList.remove("l7-touch-drag-pan")}},{key:"isEnabled",value:function(){return this.mousePan.isEnabled()&&this.touchPan.isEnabled()}},{key:"isActive",value:function(){return this.mousePan.isActive()||this.touchPan.isActive()}}]),e}(),XN=function(){function e(i,r,n){(0,We.Z)(this,e),this.pitchWithRotate=i.pitchWithRotate,this.mouseRotate=r,this.mousePitch=n}return(0,ot.Z)(e,[{key:"enable",value:function(){this.mouseRotate.enable(),this.pitchWithRotate&&this.mousePitch.enable()}},{key:"disable",value:function(){this.mouseRotate.disable(),this.mousePitch.disable()}},{key:"isEnabled",value:function(){return this.mouseRotate.isEnabled()&&(!this.pitchWithRotate||this.mousePitch.isEnabled())}},{key:"isActive",value:function(){return this.mouseRotate.isActive()||this.mousePitch.isActive()}}]),e}(),YN=function(){function e(i,r,n,t){(0,We.Z)(this,e),this.el=i,this.touchZoom=r,this.touchRotate=n,this.tapDragZoom=t,this.rotationDisabled=!1,this.enabled=!0}return(0,ot.Z)(e,[{key:"enable",value:function(r){this.touchZoom.enable(r),this.rotationDisabled||this.touchRotate.enable(r),this.tapDragZoom.enable(),this.el.classList.add("l7-touch-zoom-rotate")}},{key:"disable",value:function(){this.touchZoom.disable(),this.touchRotate.disable(),this.tapDragZoom.disable(),this.el.classList.remove("l7-touch-zoom-rotate")}},{key:"isEnabled",value:function(){return this.touchZoom.isEnabled()&&(this.rotationDisabled||this.touchRotate.isEnabled())&&this.tapDragZoom.isEnabled()}},{key:"isActive",value:function(){return this.touchZoom.isActive()||this.touchRotate.isActive()||this.tapDragZoom.isActive()}},{key:"disableRotation",value:function(){this.rotationDisabled=!0,this.touchRotate.disable()}},{key:"enableRotation",value:function(){this.rotationDisabled=!1,this.touchZoom.isEnabled()&&this.touchRotate.enable()}}]),e}();function kw(e,i){for(var r={},n=0;n=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function qN(e,i){if(e){if(typeof e=="string")return u5(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return u5(e,i)}}function u5(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);rthis.numTouches)&&(this.aborted=!0),!this.aborted&&(this.startTime===void 0&&(this.startTime=r.timeStamp),t.length===this.numTouches&&(this.centroid=QN(n),this.touches=kw(t,n)))}},{key:"touchmove",value:function(r,n,t){if(!(this.aborted||!this.centroid)){var a=kw(t,n);for(var u in this.touches)if(this.touches[u]){var c=this.touches[u],m=a[u];(!m||m.dist(c)>c5)&&(this.aborted=!0)}}}},{key:"touchend",value:function(r,n,t){if((!this.centroid||r.timeStamp-this.startTime>JN)&&(this.aborted=!0),t.length===0){var a=!this.aborted&&this.centroid;if(this.reset(),a)return a}}}]),e}(),Fw=function(){function e(i){(0,We.Z)(this,e),this.singleTap=new e9(i),this.numTaps=i.numTaps,this.reset()}return(0,ot.Z)(e,[{key:"reset",value:function(){this.lastTime=1/0,delete this.lastTap,this.count=0,this.singleTap.reset()}},{key:"touchstart",value:function(r,n,t){this.singleTap.touchstart(r,n,t)}},{key:"touchmove",value:function(r,n,t){this.singleTap.touchmove(r,n,t)}},{key:"touchend",value:function(r,n,t){var a=this.singleTap.touchend(r,n,t);if(a){var u=r.timeStamp-this.lastTimel5&&this.reset(),this.tapTime?t.length>0&&(this.swipePoint=n[0],this.swipeTouch=t[0].identifier):this.tap.touchstart(r,n,t))}},{key:"touchmove",value:function(r,n,t){if(!this.tapTime)this.tap.touchmove(r,n,t);else if(this.swipePoint){if(t[0].identifier!==this.swipeTouch)return;var a=n[0],u=a.y-this.swipePoint.y;return this.swipePoint=a,r.preventDefault(),this.active=!0,{zoomDelta:u/128}}}},{key:"touchend",value:function(r,n,t){if(this.tapTime)this.swipePoint&&t.length===0&&this.reset();else{var a=this.tap.touchend(r,n,t);a&&(this.tapTime=r.timeStamp)}}},{key:"touchcancel",value:function(){this.reset()}},{key:"enable",value:function(){this.enabled=!0}},{key:"disable",value:function(){this.enabled=!1,this.reset()}},{key:"isEnabled",value:function(){return this.enabled}},{key:"isActive",value:function(){return this.active}}]),e}(),r9=function(){function e(){(0,We.Z)(this,e),this.zoomIn=new Fw({numTouches:1,numTaps:2}),this.zoomOut=new Fw({numTouches:2,numTaps:1}),this.reset()}return(0,ot.Z)(e,[{key:"reset",value:function(){this.active=!1,this.zoomIn.reset(),this.zoomOut.reset()}},{key:"touchstart",value:function(r,n,t){this.zoomIn.touchstart(r,n,t),this.zoomOut.touchstart(r,n,t)}},{key:"touchmove",value:function(r,n,t){this.zoomIn.touchmove(r,n,t),this.zoomOut.touchmove(r,n,t)}},{key:"touchend",value:function(r,n,t){var a=this,u=this.zoomIn.touchend(r,n,t),c=this.zoomOut.touchend(r,n,t);if(u)return this.active=!0,r.preventDefault(),setTimeout(function(){return a.reset()},0),{cameraAnimation:function(E){return E.easeTo({duration:300,zoom:E.getZoom()+1,around:E.unproject(u)},{originalEvent:r})}};if(c)return this.active=!0,r.preventDefault(),setTimeout(function(){return a.reset()},0),{cameraAnimation:function(E){return E.easeTo({duration:300,zoom:E.getZoom()-1,around:E.unproject(c)},{originalEvent:r})}}}},{key:"touchcancel",value:function(){this.reset()}},{key:"enable",value:function(){this.enabled=!0}},{key:"disable",value:function(){this.enabled=!1,this.reset()}},{key:"isEnabled",value:function(){return this.enabled}},{key:"isActive",value:function(){return this.active}}]),e}(),n9=function(){function e(i){(0,We.Z)(this,e),this.minTouches=1,this.clickTolerance=i.clickTolerance||1,this.reset()}return(0,ot.Z)(e,[{key:"reset",value:function(){this.active=!1,this.touches={},this.sum=new bp(0,0)}},{key:"touchstart",value:function(r,n,t){return this.calculateTransform(r,n,t)}},{key:"touchmove",value:function(r,n,t){if(this.active)return r.preventDefault(),this.calculateTransform(r,n,t)}},{key:"touchend",value:function(r,n,t){this.calculateTransform(r,n,t),this.active&&t.length0&&(this.active=!0);var a=kw(t,n),u=new bp(0,0),c=new bp(0,0),m=0;for(var E in a)if(a[E]){var H=a[E],re=this.touches[E];re&&(u._add(H),c._add(H.sub(re)),m++,a[E]=H)}if(this.touches=a,!(mMath.abs(e.x)}var a9=100,s9=function(e){(0,Me.Z)(r,e);var i=i9(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"reset",value:function(){Sd((0,Qe.Z)(r.prototype),"reset",this).call(this),this.valid=void 0,delete this.firstMove,delete this.lastPoints}},{key:"start",value:function(t){this.lastPoints=t,Nw(t[0].sub(t[1]))&&(this.valid=!1)}},{key:"move",value:function(t,a,u){var c=t[0].sub(this.lastPoints[0]),m=t[1].sub(this.lastPoints[1]);if(this.valid=this.gestureBeginsVertically(c,m,u.timeStamp),!!this.valid){this.lastPoints=t,this.active=!0;var E=(c.y+m.y)/2,H=-.5;return{pitchDelta:E*H}}}},{key:"gestureBeginsVertically",value:function(t,a,u){if(this.valid!==void 0)return this.valid;var c=2,m=t.mag()>=c,E=a.mag()>=c;if(!(!m&&!E)){if(!m||!E)return this.firstMove===void 0&&(this.firstMove=u),u-this.firstMove0==a.y>0;return Nw(t)&&Nw(a)&&H}}}]),r}(Bw);function u9(e){var i=l9();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function l9(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var c9=25;function f5(e,i){return e.angleWith(i)*180/Math.PI}var f9=function(e){(0,Me.Z)(r,e);var i=u9(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"reset",value:function(){Sd((0,Qe.Z)(r.prototype),"reset",this).call(this),delete this.minDiameter,delete this.startVector,delete this.vector}},{key:"start",value:function(t){this.startVector=this.vector=t[0].sub(t[1]),this.minDiameter=t[0].dist(t[1])}},{key:"move",value:function(t,a){var u=this.vector;if(this.vector=t[0].sub(t[1]),!(!this.active&&this.isBelowThreshold(this.vector)))return this.active=!0,{bearingDelta:f5(this.vector,u),pinchAround:a}}},{key:"isBelowThreshold",value:function(t){this.minDiameter=Math.min(this.minDiameter,t.mag());var a=Math.PI*this.minDiameter,u=c9/a*360,c=f5(t,this.startVector);return Math.abs(c)=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function v9(e,i){if(e){if(typeof e=="string")return d5(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return d5(e,i)}}function d5(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);rUw}).reduce(function(m,E){return m+(E-Uw)/Uw},0),c=u/(n+u)*100;return{loadTime:i,fullLoadTime:r,fps:a,percentDroppedFrames:c}}};function m5(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=_9(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function _9(e,i){if(e){if(typeof e=="string")return v5(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return v5(e,i)}}function v5(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r0&&arguments[0]!==void 0?arguments[0]:0,n=this.currentlyRunning=this.queue;this.queue=[];var t=m5(n),a;try{for(t.s();!(a=t.n()).done;){var u=a.value;if(!u.cancelled&&(u.callback(r),this.cleared))break}}catch(c){t.e(c)}finally{t.f()}this.cleared=!1,this.currentlyRunning=!1}},{key:"clear",value:function(){this.currentlyRunning&&(this.cleared=!0),this.queue=[]}}]),e}(),g5=A9;function b9(e){var i=x9();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function x9(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}function w9(e,i){var r=typeof my!="undefined"&&!!my&&typeof my.showToast=="function"&&my.isFRM!==!0,n=typeof wx!="undefined"&&wx!==null&&(typeof wx.request!="undefined"||typeof wx.miniProgram!="undefined");if(!(r||n)&&(i||(i=document),!!i)){var t=i.head||i.getElementsByTagName("head")[0];if(!t){t=i.createElement("head");var a=i.body||i.getElementsByTagName("body")[0];a?a.parentNode.insertBefore(t,a):i.documentElement.appendChild(t)}var u=i.createElement("style");return u.type="text/css",u.styleSheet?u.styleSheet.cssText=e:u.appendChild(i.createTextNode(e)),t.appendChild(u),u}}w9(`.l7-map { + font: 12px/20px 'Helvetica Neue', Arial, Helvetica, sans-serif; + overflow: hidden; + position: relative; + -webkit-tap-highlight-color: rgba(0, 0, 0, 0); +} + +.l7-canvas { + position: absolute; + left: 0; + top: 0; +} + +.l7-map:-webkit-full-screen { + width: 100%; + height: 100%; +} + +.l7-canary { + background-color: salmon; +} + +.l7-canvas-container.l7-interactive, +.l7-ctrl-group button.l7-ctrl-compass { + cursor: -webkit-grab; + cursor: grab; + -moz-user-select: none; + -webkit-user-select: none; + -ms-user-select: none; + user-select: none; +} + +.l7-canvas-container.l7-interactive.l7-track-pointer { + cursor: pointer; +} + +.l7-canvas-container.l7-interactive:active, +.l7-ctrl-group button.l7-ctrl-compass:active { + cursor: -webkit-grabbing; + cursor: grabbing; +} + +.l7-canvas-container.l7-touch-zoom-rotate, +.l7-canvas-container.l7-touch-zoom-rotate .l7-canvas { + -ms-touch-action: pan-x pan-y; + touch-action: pan-x pan-y; +} + +.l7-canvas-container.l7-touch-drag-pan, +.l7-canvas-container.l7-touch-drag-pan .l7-canvas { + -ms-touch-action: pinch-zoom; + touch-action: pinch-zoom; +} + +.l7-canvas-container.l7-touch-zoom-rotate.l7-touch-drag-pan, +.l7-canvas-container.l7-touch-zoom-rotate.l7-touch-drag-pan .l7-canvas { + -ms-touch-action: none; + touch-action: none; +} + +.l7-ctrl-top-left, +.l7-ctrl-top-right, +.l7-ctrl-bottom-left, +.l7-ctrl-bottom-right { position: absolute; pointer-events: none; z-index: 2; } +.l7-ctrl-top-left { top: 0; left: 0; } +.l7-ctrl-top-right { top: 0; right: 0; } +.l7-ctrl-bottom-left { bottom: 0; left: 0; } +.l7-ctrl-bottom-right { right: 0; bottom: 0; } + +.l7-ctrl { + clear: both; + pointer-events: auto; + + /* workaround for a Safari bug https://github.com/mapbox/mapbox-gl-js/issues/8185 */ + -webkit-transform: translate(0, 0); + transform: translate(0, 0); +} +.l7-ctrl-top-left .l7-ctrl { margin: 10px 0 0 10px; float: left; } +.l7-ctrl-top-right .l7-ctrl { margin: 10px 10px 0 0; float: right; } +.l7-ctrl-bottom-left .l7-ctrl { margin: 0 0 10px 10px; float: left; } +.l7-ctrl-bottom-right .l7-ctrl { margin: 0 10px 10px 0; float: right; } + + +.l7-crosshair, +.l7-crosshair .l7-interactive, +.l7-crosshair .l7-interactive:active { + cursor: crosshair; +} + +.l7-boxzoom { + position: absolute; + top: 0; + left: 0; + width: 0; + height: 0; + background: #fff; + border: 2px dotted #202020; + opacity: 0.5; + z-index: 10; +} +`);var o2=-2,y5=22,E9=lo.merge,X1=0,a2=60,S9={hash:!1,zoom:-1,center:[112,32],pitch:0,bearing:0,interactive:!0,minZoom:o2,maxZoom:y5,minPitch:X1,maxPitch:a2,scrollZoom:!0,boxZoom:!0,dragRotate:!0,dragPan:!0,keyboard:!0,doubleClickZoom:!0,touchZoomRotate:!0,touchPitch:!0,bearingSnap:7,clickTolerance:3,pitchWithRotate:!0,trackResize:!0,renderWorldCopies:!0,pitchEnabled:!0,rotateEnabled:!0},C9=function(e){(0,Me.Z)(r,e);var i=b9(r);function r(n){var t;return(0,We.Z)(this,r),t=i.call(this,E9({},S9,n)),(0,St.Z)((0,Fr.Z)(t),"renderTaskQueue",new g5),(0,St.Z)((0,Fr.Z)(t),"trackResize",!0),(0,St.Z)((0,Fr.Z)(t),"onWindowOnline",function(){t.update()}),(0,St.Z)((0,Fr.Z)(t),"onWindowResize",function(a){t.trackResize&&t.resize({originalEvent:a}).update()}),t.initContainer(),t.resize(),t.handlers=new p5((0,Fr.Z)(t),t.options),typeof window!="undefined"&&(window.addEventListener("online",t.onWindowOnline,!1),window.addEventListener("resize",t.onWindowResize,!1),window.addEventListener("orientationchange",t.onWindowResize,!1)),t}return(0,ot.Z)(r,[{key:"resize",value:function(t){var a=this.containerDimensions(),u=a[0],c=a[1];this.transform.resize(u,c);var m=!this.moving;return m&&(this.stop(),this.emit("movestart",new Event("movestart",t)),this.emit("move",new Event("move",t))),this.emit("resize",new Event("resize",t)),m&&this.emit("moveend",new Event("moveend",t)),this}},{key:"getContainer",value:function(){return this.container}},{key:"getCanvas",value:function(){return this.canvas}},{key:"getCanvasContainer",value:function(){return this.canvasContainer}},{key:"project",value:function(t){return this.transform.locationPoint(Z0.convert(t))}},{key:"unproject",value:function(t){return this.transform.pointLocation(bp.convert(t))}},{key:"getBounds",value:function(){return this.transform.getBounds()}},{key:"getMaxBounds",value:function(){return this.transform.getMaxBounds()}},{key:"setMaxBounds",value:function(t){this.transform.setMaxBounds(Q_.convert(t))}},{key:"setStyle",value:function(t){}},{key:"setMinZoom",value:function(t){if(t=t==null?o2:t,t>=o2&&t<=this.transform.maxZoom)return this.transform.minZoom=t,this.getZoom()=this.transform.minZoom)return this.transform.maxZoom=t,this.getZoom()>t&&this.setZoom(t),this;throw new Error("maxZoom must be greater than the current minZoom")}},{key:"getMaxZoom",value:function(){return this.transform.maxZoom}},{key:"setMinPitch",value:function(t){if(t=t==null?X1:t,t=X1&&t<=this.transform.maxPitch)return this.transform.minPitch=t,this.getPitch()a2)throw new Error("maxPitch must be less than or equal to ".concat(a2));if(t>=this.transform.minPitch)return this.transform.maxPitch=t,this.getPitch()>t&&this.setPitch(t),this;throw new Error("maxPitch must be greater than the current minPitch")}},{key:"getMaxPitch",value:function(){return this.transform.maxPitch}},{key:"getRenderWorldCopies",value:function(){return this.transform.renderWorldCopies}},{key:"setRenderWorldCopies",value:function(t){this.transform.renderWorldCopies=!!t}},{key:"remove",value:function(){this.frame&&(this.frame.cancel(),this.frame=null),this.renderTaskQueue.clear(),this.handlers.destroy(),typeof window!="undefined"&&(window.removeEventListener("online",this.onWindowOnline,!1),window.removeEventListener("resize",this.onWindowResize,!1),window.removeEventListener("orientationchange",this.onWindowResize,!1))}},{key:"requestRenderFrame",value:function(t){return this.update(),this.renderTaskQueue.add(t)}},{key:"cancelRenderFrame",value:function(t){return this.renderTaskQueue.remove(t)}},{key:"triggerRepaint",value:function(){var t=this;this.frame||(this.frame=$b(function(a){i2.frame(a),t.frame=null,t.update(a)}))}},{key:"update",value:function(t){var a=this;this.frame||(this.frame=$b(function(u){i2.frame(u),a.frame=null,a.renderTaskQueue.run(t)}))}},{key:"initContainer",value:function(){if(typeof this.options.container=="string"){if(this.container=window.document.getElementById(this.options.container),!this.container)throw new Error("Container '".concat(this.options.container,"' not found."))}else if(this.options.container instanceof HTMLElement)this.container=this.options.container;else throw new Error("Invalid type: 'container' must be a String or HTMLElement.");var t=this.container;t.classList.add("l7-map");var a=this.canvasContainer=Vo("div","l7-canvas-container",t);this.options.interactive&&a.classList.add("l7-interactive")}},{key:"containerDimensions",value:function(){var t=0,a=0;return this.container&&(t=this.container.clientWidth||400,a=this.container.clientHeight||300),[t,a]}},{key:"resizeCanvas",value:function(t,a){var u=Co||1;this.canvas.width=u*t,this.canvas.height=u*a,this.canvas.style.width="".concat(t,"px"),this.canvas.style.height="".concat(a,"px")}}]),r}(e5),T9=lo.throttle,M9=function(){function e(i){var r=this;(0,We.Z)(this,e),(0,St.Z)(this,"onHashChange",function(){var n=r.getCurrentHash();if(n.length>=3&&!n.some(function(a){return isNaN(+a)})){var t=r.map.dragRotate.isEnabled()&&r.map.touchZoomRotate.isEnabled()?+(n[3]||0):r.map.getBearing();return r.map.jumpTo({center:[+n[2],+n[1]],zoom:+n[0],bearing:t,pitch:+(n[4]||0)}),!0}return!1}),(0,St.Z)(this,"getCurrentHash",function(){var n=window.location.hash.replace("#","");if(r.hashName){var t;return n.split("&").map(function(a){return a.split("=")}).forEach(function(a){a[0]===r.hashName&&(t=a)}),(t&&t[1]||"").split("/")}return n.split("/")}),(0,St.Z)(this,"updateHashUnthrottled",function(){var n=r.getHashString();try{window.history.replaceState(window.history.state,"",n)}catch(t){}}),this.hashName=i&&encodeURIComponent(i),this.updateHash=T9(this.updateHashUnthrottled,30*1e3/100)}return(0,ot.Z)(e,[{key:"addTo",value:function(r){return this.map=r,window.addEventListener("hashchange",this.onHashChange,!1),this.map.on("moveend",this.updateHash),this}},{key:"remove",value:function(){return window.removeEventListener("hashchange",this.onHashChange,!1),this.map.off("moveend",this.updateHash),delete this.map,this}},{key:"getHashString",value:function(r){var n=this.map.getCenter(),t=Math.round(this.map.getZoom()*100)/100,a=Math.ceil((t*Math.LN2+Math.log(512/360/.5))/Math.LN10),u=Math.pow(10,a),c=Math.round(n.lng*u)/u,m=Math.round(n.lat*u)/u,E=this.map.getBearing(),H=this.map.getPitch(),re="";if(r?re+="/".concat(c,"/").concat(m,"/").concat(t):re+="".concat(t,"/").concat(m,"/").concat(c),(E||H)&&(re+="/".concat(Math.round(E*10)/10)),H&&(re+="/".concat(Math.round(H))),this.hashName){var xe=this.hashName,ke=!1,rt=window.location.hash.slice(1).split("&").map(function(vt){var It=vt.split("=")[0];return It===xe?(ke=!0,"".concat(It,"=").concat(re)):vt}).filter(function(vt){return vt});return ke||rt.push("".concat(xe,"=").concat(re)),"#".concat(rt.join("&"))}return"#".concat(re)}}]),e}(),P9=M9;function I9(e){var i=R9();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function R9(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}function O9(e,i){var r=typeof my!="undefined"&&!!my&&typeof my.showToast=="function"&&my.isFRM!==!0,n=typeof wx!="undefined"&&wx!==null&&(typeof wx.request!="undefined"||typeof wx.miniProgram!="undefined");if(!(r||n)&&(i||(i=document),!!i)){var t=i.head||i.getElementsByTagName("head")[0];if(!t){t=i.createElement("head");var a=i.body||i.getElementsByTagName("body")[0];a?a.parentNode.insertBefore(t,a):i.documentElement.appendChild(t)}var u=i.createElement("style");return u.type="text/css",u.styleSheet?u.styleSheet.cssText=e:u.appendChild(i.createTextNode(e)),t.appendChild(u),u}}O9(`.l7-map { + font: 12px/20px 'Helvetica Neue', Arial, Helvetica, sans-serif; + overflow: hidden; + position: relative; + -webkit-tap-highlight-color: rgba(0, 0, 0, 0); +} + +.l7-canvas { + position: absolute; + left: 0; + top: 0; +} + +.l7-map:-webkit-full-screen { + width: 100%; + height: 100%; +} + +.l7-canary { + background-color: salmon; +} + +.l7-canvas-container.l7-interactive, +.l7-ctrl-group button.l7-ctrl-compass { + cursor: -webkit-grab; + cursor: grab; + -moz-user-select: none; + -webkit-user-select: none; + -ms-user-select: none; + user-select: none; +} + +.l7-canvas-container.l7-interactive.l7-track-pointer { + cursor: pointer; +} + +.l7-canvas-container.l7-interactive:active, +.l7-ctrl-group button.l7-ctrl-compass:active { + cursor: -webkit-grabbing; + cursor: grabbing; +} + +.l7-canvas-container.l7-touch-zoom-rotate, +.l7-canvas-container.l7-touch-zoom-rotate .l7-canvas { + -ms-touch-action: pan-x pan-y; + touch-action: pan-x pan-y; +} + +.l7-canvas-container.l7-touch-drag-pan, +.l7-canvas-container.l7-touch-drag-pan .l7-canvas { + -ms-touch-action: pinch-zoom; + touch-action: pinch-zoom; +} + +.l7-canvas-container.l7-touch-zoom-rotate.l7-touch-drag-pan, +.l7-canvas-container.l7-touch-zoom-rotate.l7-touch-drag-pan .l7-canvas { + -ms-touch-action: none; + touch-action: none; +} + +.l7-ctrl-top-left, +.l7-ctrl-top-right, +.l7-ctrl-bottom-left, +.l7-ctrl-bottom-right { position: absolute; pointer-events: none; z-index: 2; } +.l7-ctrl-top-left { top: 0; left: 0; } +.l7-ctrl-top-right { top: 0; right: 0; } +.l7-ctrl-bottom-left { bottom: 0; left: 0; } +.l7-ctrl-bottom-right { right: 0; bottom: 0; } + +.l7-ctrl { + clear: both; + pointer-events: auto; + + /* workaround for a Safari bug https://github.com/mapbox/mapbox-gl-js/issues/8185 */ + -webkit-transform: translate(0, 0); + transform: translate(0, 0); +} +.l7-ctrl-top-left .l7-ctrl { margin: 10px 0 0 10px; float: left; } +.l7-ctrl-top-right .l7-ctrl { margin: 10px 10px 0 0; float: right; } +.l7-ctrl-bottom-left .l7-ctrl { margin: 0 0 10px 10px; float: left; } +.l7-ctrl-bottom-right .l7-ctrl { margin: 0 10px 10px 0; float: right; } + + +.l7-crosshair, +.l7-crosshair .l7-interactive, +.l7-crosshair .l7-interactive:active { + cursor: crosshair; +} + +.l7-boxzoom { + position: absolute; + top: 0; + left: 0; + width: 0; + height: 0; + background: #fff; + border: 2px dotted #202020; + opacity: 0.5; + z-index: 10; +} +`),function(){if(typeof window.CustomEvent=="function")return!1;function e(i,r){r=r||{bubbles:!1,cancelable:!1,detail:void 0};var n=document.createEvent("CustomEvent");return n.initCustomEvent(i,r.bubbles,r.cancelable,r.detail),n}e.prototype=window.Event.prototype,window.CustomEvent=e}();var s2=-2,_5=22,A5=lo.merge,Y1=0,u2=60,L9={hash:!1,zoom:-1,center:[112,32],pitch:0,bearing:0,interactive:!0,minZoom:s2,maxZoom:_5,minPitch:Y1,maxPitch:u2,scrollZoom:!0,boxZoom:!0,dragRotate:!0,dragPan:!0,keyboard:!0,doubleClickZoom:!0,touchZoomRotate:!0,touchPitch:!0,bearingSnap:7,clickTolerance:3,pitchWithRotate:!0,trackResize:!0,renderWorldCopies:!0,pitchEnabled:!0,rotateEnabled:!0},D9=function(e){(0,Me.Z)(r,e);var i=I9(r);function r(n){var t;(0,We.Z)(this,r),t=i.call(this,A5({},L9,n)),(0,St.Z)((0,Fr.Z)(t),"renderTaskQueue",new g5),(0,St.Z)((0,Fr.Z)(t),"trackResize",!0),(0,St.Z)((0,Fr.Z)(t),"onWindowOnline",function(){t.update()}),(0,St.Z)((0,Fr.Z)(t),"onWindowResize",function(u){t.trackResize&&t.resize({originalEvent:u}).update()}),t.initContainer(),t.resize(),t.handlers=new p5((0,Fr.Z)(t),t.options),typeof window!="undefined"&&(window.addEventListener("online",t.onWindowOnline,!1),window.addEventListener("resize",t.onWindowResize,!1),window.addEventListener("orientationchange",t.onWindowResize,!1));var a=typeof n.hash=="string"&&n.hash||void 0;return n.hash&&(t.hash=new P9(a).addTo((0,Fr.Z)(t))),(!t.hash||!t.hash.onHashChange())&&(t.jumpTo({center:n.center,zoom:n.zoom,bearing:n.bearing,pitch:n.pitch}),n.bounds&&(t.resize(),t.fitBounds(n.bounds,A5({},n.fitBoundsOptions,{duration:0})))),t}return(0,ot.Z)(r,[{key:"resize",value:function(t){var a=this.containerDimensions(),u=(0,gi.Z)(a,2),c=u[0],m=u[1];this.transform.resize(c,m);var E=!this.moving;return E&&(this.stop(),this.emit("movestart",new window.CustomEvent("movestart",t)),this.emit("move",new window.CustomEvent("move",t))),this.emit("resize",new window.CustomEvent("resize",t)),E&&this.emit("moveend",new window.CustomEvent("moveend",t)),this}},{key:"getContainer",value:function(){return this.container}},{key:"getCanvas",value:function(){return this.canvas}},{key:"getCanvasContainer",value:function(){return this.canvasContainer}},{key:"project",value:function(t){return this.transform.locationPoint(Z0.convert(t))}},{key:"unproject",value:function(t){return this.transform.pointLocation(bp.convert(t))}},{key:"getBounds",value:function(){return this.transform.getBounds()}},{key:"getMaxBounds",value:function(){return this.transform.getMaxBounds()}},{key:"setMaxBounds",value:function(t){this.transform.setMaxBounds(Q_.convert(t))}},{key:"setStyle",value:function(t){}},{key:"setMinZoom",value:function(t){if(t=t==null?s2:t,t>=s2&&t<=this.transform.maxZoom)return this.transform.minZoom=t,this.getZoom()=this.transform.minZoom)return this.transform.maxZoom=t,this.getZoom()>t&&this.setZoom(t),this;throw new Error("maxZoom must be greater than the current minZoom")}},{key:"getMaxZoom",value:function(){return this.transform.maxZoom}},{key:"setMinPitch",value:function(t){if(t=t==null?Y1:t,t=Y1&&t<=this.transform.maxPitch)return this.transform.minPitch=t,this.getPitch()u2)throw new Error("maxPitch must be less than or equal to ".concat(u2));if(t>=this.transform.minPitch)return this.transform.maxPitch=t,this.getPitch()>t&&this.setPitch(t),this;throw new Error("maxPitch must be greater than the current minPitch")}},{key:"getMaxPitch",value:function(){return this.transform.maxPitch}},{key:"getRenderWorldCopies",value:function(){return this.transform.renderWorldCopies}},{key:"setRenderWorldCopies",value:function(t){this.transform.renderWorldCopies=!!t}},{key:"remove",value:function(){this.container.removeChild(this.canvasContainer),this.canvasContainer=null,this.frame&&(this.frame.cancel(),this.frame=null),this.renderTaskQueue.clear(),this.handlers.destroy(),typeof window!="undefined"&&(window.removeEventListener("online",this.onWindowOnline,!1),window.removeEventListener("resize",this.onWindowResize,!1),window.removeEventListener("orientationchange",this.onWindowResize,!1))}},{key:"requestRenderFrame",value:function(t){return this.update(),this.renderTaskQueue.add(t)}},{key:"cancelRenderFrame",value:function(t){return this.renderTaskQueue.remove(t)}},{key:"triggerRepaint",value:function(){var t=this;this.frame||(this.frame=$b(function(a){i2.frame(a),t.frame=null,t.update(a)}))}},{key:"update",value:function(t){var a=this;this.frame||(this.frame=$b(function(u){i2.frame(u),a.frame=null,a.renderTaskQueue.run(t)}))}},{key:"initContainer",value:function(){if(typeof this.options.container=="string"){if(this.container=window.document.getElementById(this.options.container),!this.container)throw new Error("Container '".concat(this.options.container,"' not found."))}else if(this.options.container instanceof HTMLElement)this.container=this.options.container;else throw new Error("Invalid type: 'container' must be a String or HTMLElement.");var t=this.container;t.classList.add("l7-map");var a=this.canvasContainer=Vo("div","l7-canvas-container",t);this.options.interactive&&a.classList.add("l7-interactive")}},{key:"initMiniContainer",value:function(){this.container=this.options.canvas,this.canvasContainer=this.container}},{key:"containerDimensions",value:function(){var t=0,a=0;return this.container&&(t=this.container.clientWidth,a=this.container.clientHeight,t=t===0?400:t,a=a===0?300:a),[t,a]}}]),r}(e5),k9=function(){function e(){(0,We.Z)(this,e),(0,St.Z)(this,"xzReg",-Math.PI*.6),(0,St.Z)(this,"yReg",Math.PI*.2),(0,St.Z)(this,"earthCameraRadius",200),(0,St.Z)(this,"earthCameraZoom",1),(0,St.Z)(this,"cameraPosition",vy()),(0,St.Z)(this,"projectionMatrix",Mf()),(0,St.Z)(this,"modelMatrix",Mf()),(0,St.Z)(this,"viewMatrix",Mf()),(0,St.Z)(this,"viewProjectionMatrix",Mf()),(0,St.Z)(this,"ViewProjectionMatrixUncentered",Mf()),(0,St.Z)(this,"viewUncenteredMatrix",Mf())}return(0,ot.Z)(e,[{key:"syncWithMapCamera",value:function(r){var n=r.viewportHeight,t=n===void 0?1:n,a=r.viewportWidth,u=a===void 0?1:a,c=u/t,m=.1,E=1e4,H=20;wr(this.projectionMatrix,H,c,m,E);var re=this.earthCameraRadius*Math.cos(this.xzReg),xe=this.earthCameraRadius*Math.sin(this.xzReg),ke=this.earthCameraRadius*Math.sin(this.yReg);this.cameraPosition=Zd(re,ke,xe),gy(this.cameraPosition,this.cameraPosition),Nx(this.cameraPosition,this.cameraPosition,Zd(this.earthCameraRadius,this.earthCameraRadius,this.earthCameraRadius)),zx(this.cameraPosition,this.cameraPosition,this.earthCameraZoom);var rt=vy();hb(rt,this.cameraPosition,Zd(0,1,0));var vt=Zd(0,1,0);hb(vt,rt,this.cameraPosition);var It=Zd(0,0,0);Tn(this.viewMatrix,this.cameraPosition,It,vt),this.viewUncenteredMatrix=lm(this.viewMatrix),Gh(this.viewProjectionMatrix,this.projectionMatrix,this.viewMatrix),Gh(this.ViewProjectionMatrixUncentered,this.projectionMatrix,this.viewMatrix)}},{key:"rotateY",value:function(r){this.xzReg+=r*Math.min(this.earthCameraZoom*this.earthCameraZoom,1)}},{key:"rotateX",value:function(r){this.yReg+=r*Math.min(this.earthCameraZoom*this.earthCameraZoom,1)}},{key:"scaleZoom",value:function(r){this.earthCameraZoom+=r,this.earthCameraZoom=Math.max(this.earthCameraZoom,.6)}},{key:"getZoom",value:function(){return 4}},{key:"getZoomScale",value:function(){return Math.pow(2,this.getZoom())}},{key:"getCenter",value:function(){return[0,0]}},{key:"getProjectionMatrix",value:function(){return this.projectionMatrix}},{key:"getModelMatrix",value:function(){return this.modelMatrix}},{key:"getViewMatrix",value:function(){return this.viewMatrix}},{key:"getViewMatrixUncentered",value:function(){return this.viewMatrix}},{key:"getViewProjectionMatrix",value:function(){return this.viewProjectionMatrix}},{key:"getViewProjectionMatrixUncentered",value:function(){return this.viewProjectionMatrix}},{key:"getFocalDistance",value:function(){return 1}},{key:"projectFlat",value:function(r,n){return this.viewport.projectFlat(r,n)}}]),e}(),F9=["id","style","rotation"],b5,x5;function B9(e){var i=N9();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function N9(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var w5={mapmove:"move",camerachange:"move",zoomchange:"zoom",dragging:"drag"},z9=12,Z9=(b5=(0,sa.b2)(),b5(x5=function(e){(0,Me.Z)(r,e);var i=B9(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;uMath.abs(c.originalEvent.movementY)?c.originalEvent.movementX>0?n.viewport.rotateY(E):c.originalEvent.movementX<0&&n.viewport.rotateY(-E):c.originalEvent.movementY>0?n.viewport.rotateX(E):c.originalEvent.movementY<0&&n.viewport.rotateX(-E));var H=n.config.offsetCoordinate,re=H===void 0?!0:H;n.viewport.syncWithMapCamera({viewportHeight:n.map.transform.height,viewportWidth:n.map.transform.width}),n.viewport.getZoom()>z9&&re?n.coordinateSystemService.setCoordinateSystem(ne.LNGLAT_OFFSET):n.coordinateSystemService.setCoordinateSystem(ne.LNGLAT),n.cameraChangedCallback(n.viewport)}),n}return(0,ot.Z)(r,[{key:"lngLatToMercator",value:function(t,a){throw new Error("Method not implemented.")}},{key:"getModelMatrix",value:function(t,a,u,c,m){throw new Error("Method not implemented.")}},{key:"on",value:function(t,a){e0.indexOf(t)!==-1?this.eventEmitter.on(t,a):this.map.on(w5[t]||t,a)}},{key:"off",value:function(t,a){this.map.off(w5[t]||t,a),this.eventEmitter.off(t,a)}},{key:"getMapCanvasContainer",value:function(){return this.map.getCanvasContainer()}},{key:"getSize",value:function(){var t=this.map.transform;return[t.width,t.height]}},{key:"getType",value:function(){return"earth"}},{key:"init",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u,c,m,E,H,re,xe,ke;return Ur().wrap(function(vt){for(;;)switch(vt.prev=vt.next){case 0:u=this.config,c=u.id,m=c===void 0?"map":c,E=u.style,H=E===void 0?"light":E,re=u.rotation,xe=re===void 0?0:re,ke=(0,X0.Z)(u,F9),this.viewport=new k9,this.$mapContainer=this.creatMapContainer(m),this.map=new C9((0,Se.Z)({container:this.$mapContainer,style:this.getMapStyleValue(H),bearing:xe},ke)),this.map.on("load",this.handleCameraChanged),this.map.on("move",this.handleCameraChanged),this.handleCameraChanged({});case 7:case"end":return vt.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"destroy",value:function(){var t;(t=this.$mapContainer)===null||t===void 0||(t=t.parentNode)===null||t===void 0||t.removeChild(this.$mapContainer),this.eventEmitter.removeAllListeners(),this.map&&(this.map.remove(),this.$mapContainer=null)}},{key:"emit",value:function(t){for(var a,u=arguments.length,c=new Array(u>1?u-1:0),m=1;m1?u-1:0),m=1;m1&&arguments[1]!==void 0?arguments[1]:{x:0,y:0,z:0},u=this.lngLatToMercator(t,0),c=u.x,m=u.y;return[c-a.x,m-a.y]}},{key:"lngLatToMercator",value:function(t,a){var u=Ug.fromLngLat(t,a),c=u.x,m=c===void 0?0:c,E=u.y,H=E===void 0?0:E,re=u.z,xe=re===void 0?0:re;return{x:m,y:H,z:xe}}},{key:"getModelMatrix",value:function(t,a,u){var c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:[1,1,1],m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{x:0,y:0,z:0},E=Ug.fromLngLat(t,a),H=E.meterInMercatorCoordinateUnits(),re=Mf();return wd(re,re,Zd(E.x-m.x,E.y-m.y,E.z||0-m.z)),Md(re,re,Zd(H*c[0],-H*c[1],H*c[2])),Bd(re,re,u[0]),Qd(re,re,u[1]),Jd(re,re,u[2]),re}},{key:"init",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u=this,c,m,E,H,re,xe,ke,rt,vt,It,er,Ar,Or,rn,Ln;return Ur().wrap(function(Cn){for(;;)switch(Cn.prev=Cn.next){case 0:c=this.config,m=c.id,E=m===void 0?"map":m,H=c.style,re=H===void 0?"light":H,xe=c.rotation,ke=xe===void 0?0:xe,rt=c.mapInstance,vt=c.version,It=vt===void 0?"DEFAULTMAP":vt,er=c.mapSize,Ar=er===void 0?1e4:er,Or=c.interactive,rn=Or===void 0?!0:Or,Ln=(0,X0.Z)(c,$9),this.viewport=new by,this.version=It,this.simpleMapCoord.setSize(Ar),It==="SIMPLE"&&Ln.center&&(Ln.center=this.simpleMapCoord.unproject(Ln.center)),rt?(this.map=rt,this.$mapContainer=this.map.getContainer()):(this.$mapContainer=this.creatMapContainer(E),this.map=new D9((0,Se.Z)({container:this.$mapContainer,style:this.getMapStyleValue(re),bearing:ke},Ln))),this.map.on("load",function(){u.handleCameraChanged()}),rn&&this.map.on("move",this.handleCameraChanged),setTimeout(function(){u.handleCameraChanged()},100),this.handleCameraChanged();case 10:case"end":return Cn.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"exportMap",value:function(t){var a=this.map.getCanvas(),u=t==="jpg"?a==null?void 0:a.toDataURL("image/jpeg"):a==null?void 0:a.toDataURL("image/png");return u}}]),r}(Ng))||S5);function X9(e){var i=Y9();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function Y9(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var K9=function(e){(0,Me.Z)(r,e);var i=X9(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getServiceConstructor",value:function(){return W9}}]),r}(Vv),q9=A(17369),tA=A.n(q9),C5=function(){function e(){(0,We.Z)(this,e)}return(0,ot.Z)(e,[{key:"syncWithMapCamera",value:function(r){var n=r.center,t=r.zoom,a=r.pitch,u=r.bearing,c=r.viewportHeight,m=r.viewportWidth;this.viewport=new Ew({width:m,height:c,longitude:n&&n[0],latitude:n&&n[1],zoom:t,pitch:a,bearing:u})}},{key:"getZoom",value:function(){return this.viewport.zoom}},{key:"getZoomScale",value:function(){return Math.pow(2,this.getZoom())}},{key:"getCenter",value:function(){return[this.viewport.longitude,this.viewport.latitude]}},{key:"getProjectionMatrix",value:function(){return this.viewport.projectionMatrix}},{key:"getModelMatrix",value:function(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}},{key:"getViewMatrix",value:function(){return this.viewport.viewMatrix}},{key:"getViewMatrixUncentered",value:function(){return this.viewport.viewMatrixUncentered}},{key:"getViewProjectionMatrix",value:function(){return this.viewport.viewProjectionMatrix}},{key:"getViewProjectionMatrixUncentered",value:function(){return this.viewport.viewProjectionMatrix}},{key:"getFocalDistance",value:function(){return 1}},{key:"projectFlat",value:function(r,n){return this.viewport.projectFlat(r,n)}}]),e}(),Q9=["id","attributionControl","style","token","rotation","mapInstance"],T5,M5;function J9(e){var i=ez();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function ez(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}function tz(e,i){var r=typeof my!="undefined"&&!!my&&typeof my.showToast=="function"&&my.isFRM!==!0,n=typeof wx!="undefined"&&wx!==null&&(typeof wx.request!="undefined"||typeof wx.miniProgram!="undefined");if(!(r||n)&&(i||(i=document),!!i)){var t=i.head||i.getElementsByTagName("head")[0];if(!t){t=i.createElement("head");var a=i.body||i.getElementsByTagName("body")[0];a?a.parentNode.insertBefore(t,a):i.documentElement.appendChild(t)}var u=i.createElement("style");return u.type="text/css",u.styleSheet?u.styleSheet.cssText=e:u.appendChild(i.createTextNode(e)),t.appendChild(u),u}}tz(`.mapboxgl-map{font:12px/20px Helvetica Neue,Arial,Helvetica,sans-serif;overflow:hidden;position:relative;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mapboxgl-canvas{position:absolute;left:0;top:0}.mapboxgl-map:-webkit-full-screen{width:100%;height:100%}.mapboxgl-canary{background-color:salmon}.mapboxgl-canvas-container.mapboxgl-interactive,.mapboxgl-ctrl-group button.mapboxgl-ctrl-compass{cursor:-webkit-grab;cursor:grab;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}.mapboxgl-canvas-container.mapboxgl-interactive.mapboxgl-track-pointer{cursor:pointer}.mapboxgl-canvas-container.mapboxgl-interactive:active,.mapboxgl-ctrl-group button.mapboxgl-ctrl-compass:active{cursor:-webkit-grabbing;cursor:grabbing}.mapboxgl-canvas-container.mapboxgl-touch-zoom-rotate,.mapboxgl-canvas-container.mapboxgl-touch-zoom-rotate .mapboxgl-canvas{-ms-touch-action:pan-x pan-y;touch-action:pan-x pan-y}.mapboxgl-canvas-container.mapboxgl-touch-drag-pan,.mapboxgl-canvas-container.mapboxgl-touch-drag-pan .mapboxgl-canvas{-ms-touch-action:pinch-zoom;touch-action:pinch-zoom}.mapboxgl-canvas-container.mapboxgl-touch-zoom-rotate.mapboxgl-touch-drag-pan,.mapboxgl-canvas-container.mapboxgl-touch-zoom-rotate.mapboxgl-touch-drag-pan .mapboxgl-canvas{-ms-touch-action:none;touch-action:none}.mapboxgl-ctrl-bottom-left,.mapboxgl-ctrl-bottom-right,.mapboxgl-ctrl-top-left,.mapboxgl-ctrl-top-right{position:absolute;pointer-events:none;z-index:2}.mapboxgl-ctrl-top-left{top:0;left:0}.mapboxgl-ctrl-top-right{top:0;right:0}.mapboxgl-ctrl-bottom-left{bottom:0;left:0}.mapboxgl-ctrl-bottom-right{right:0;bottom:0}.mapboxgl-ctrl{clear:both;pointer-events:auto;-webkit-transform:translate(0);transform:translate(0)}.mapboxgl-ctrl-top-left .mapboxgl-ctrl{margin:10px 0 0 10px;float:left}.mapboxgl-ctrl-top-right .mapboxgl-ctrl{margin:10px 10px 0 0;float:right}.mapboxgl-ctrl-bottom-left .mapboxgl-ctrl{margin:0 0 10px 10px;float:left}.mapboxgl-ctrl-bottom-right .mapboxgl-ctrl{margin:0 10px 10px 0;float:right}.mapboxgl-ctrl-group{border-radius:4px;background:#fff}.mapboxgl-ctrl-group:not(:empty){-webkit-box-shadow:0 0 2px rgba(0,0,0,.1);box-shadow:0 0 0 2px rgba(0,0,0,.1)}@media (-ms-high-contrast:active){.mapboxgl-ctrl-group:not(:empty){-webkit-box-shadow:0 0 0 2px ButtonText;box-shadow:0 0 0 2px ButtonText}}.mapboxgl-ctrl-group button{width:29px;height:29px;display:block;padding:0;outline:none;border:0;-webkit-box-sizing:border-box;box-sizing:border-box;background-color:transparent;cursor:pointer}.mapboxgl-ctrl-group button+button{border-top:1px solid #ddd}.mapboxgl-ctrl button .mapboxgl-ctrl-icon{display:block;width:100%;height:100%;background-repeat:no-repeat;background-position:50%}@media (-ms-high-contrast:active){.mapboxgl-ctrl-icon{background-color:transparent}.mapboxgl-ctrl-group button+button{border-top:1px solid ButtonText}}.mapboxgl-ctrl button::-moz-focus-inner{border:0;padding:0}.mapboxgl-ctrl-attrib-button:focus,.mapboxgl-ctrl-group button:focus{-webkit-box-shadow:0 0 2px 2px #0096ff;box-shadow:0 0 2px 2px #0096ff}.mapboxgl-ctrl button:disabled{cursor:not-allowed}.mapboxgl-ctrl button:disabled .mapboxgl-ctrl-icon{opacity:.25}.mapboxgl-ctrl button:not(:disabled):hover{background-color:rgba(0,0,0,.05)}.mapboxgl-ctrl-group button:focus:focus-visible{-webkit-box-shadow:0 0 2px 2px #0096ff;box-shadow:0 0 2px 2px #0096ff}.mapboxgl-ctrl-group button:focus:not(:focus-visible){-webkit-box-shadow:none;box-shadow:none}.mapboxgl-ctrl-group button:focus:first-child{border-radius:4px 4px 0 0}.mapboxgl-ctrl-group button:focus:last-child{border-radius:0 0 4px 4px}.mapboxgl-ctrl-group button:focus:only-child{border-radius:inherit}.mapboxgl-ctrl button.mapboxgl-ctrl-zoom-out .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg' fill='%23333'%3E%3Cpath d='M10 13c-.75 0-1.5.75-1.5 1.5S9.25 16 10 16h9c.75 0 1.5-.75 1.5-1.5S19.75 13 19 13h-9z'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-zoom-in .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg' fill='%23333'%3E%3Cpath d='M14.5 8.5c-.75 0-1.5.75-1.5 1.5v3h-3c-.75 0-1.5.75-1.5 1.5S9.25 16 10 16h3v3c0 .75.75 1.5 1.5 1.5S16 19.75 16 19v-3h3c.75 0 1.5-.75 1.5-1.5S19.75 13 19 13h-3v-3c0-.75-.75-1.5-1.5-1.5z'/%3E%3C/svg%3E")}@media (-ms-high-contrast:active){.mapboxgl-ctrl button.mapboxgl-ctrl-zoom-out .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg' fill='%23fff'%3E%3Cpath d='M10 13c-.75 0-1.5.75-1.5 1.5S9.25 16 10 16h9c.75 0 1.5-.75 1.5-1.5S19.75 13 19 13h-9z'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-zoom-in .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg' fill='%23fff'%3E%3Cpath d='M14.5 8.5c-.75 0-1.5.75-1.5 1.5v3h-3c-.75 0-1.5.75-1.5 1.5S9.25 16 10 16h3v3c0 .75.75 1.5 1.5 1.5S16 19.75 16 19v-3h3c.75 0 1.5-.75 1.5-1.5S19.75 13 19 13h-3v-3c0-.75-.75-1.5-1.5-1.5z'/%3E%3C/svg%3E")}}@media (-ms-high-contrast:black-on-white){.mapboxgl-ctrl button.mapboxgl-ctrl-zoom-out .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10 13c-.75 0-1.5.75-1.5 1.5S9.25 16 10 16h9c.75 0 1.5-.75 1.5-1.5S19.75 13 19 13h-9z'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-zoom-in .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M14.5 8.5c-.75 0-1.5.75-1.5 1.5v3h-3c-.75 0-1.5.75-1.5 1.5S9.25 16 10 16h3v3c0 .75.75 1.5 1.5 1.5S16 19.75 16 19v-3h3c.75 0 1.5-.75 1.5-1.5S19.75 13 19 13h-3v-3c0-.75-.75-1.5-1.5-1.5z'/%3E%3C/svg%3E")}}.mapboxgl-ctrl button.mapboxgl-ctrl-fullscreen .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg' fill='%23333'%3E%3Cpath d='M24 16v5.5c0 1.75-.75 2.5-2.5 2.5H16v-1l3-1.5-4-5.5 1-1 5.5 4 1.5-3h1zM6 16l1.5 3 5.5-4 1 1-4 5.5 3 1.5v1H7.5C5.75 24 5 23.25 5 21.5V16h1zm7-11v1l-3 1.5 4 5.5-1 1-5.5-4L6 13H5V7.5C5 5.75 5.75 5 7.5 5H13zm11 2.5c0-1.75-.75-2.5-2.5-2.5H16v1l3 1.5-4 5.5 1 1 5.5-4 1.5 3h1V7.5z'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-shrink .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M18.5 16c-1.75 0-2.5.75-2.5 2.5V24h1l1.5-3 5.5 4 1-1-4-5.5 3-1.5v-1h-5.5zM13 18.5c0-1.75-.75-2.5-2.5-2.5H5v1l3 1.5L4 24l1 1 5.5-4 1.5 3h1v-5.5zm3-8c0 1.75.75 2.5 2.5 2.5H24v-1l-3-1.5L25 5l-1-1-5.5 4L17 5h-1v5.5zM10.5 13c1.75 0 2.5-.75 2.5-2.5V5h-1l-1.5 3L5 4 4 5l4 5.5L5 12v1h5.5z'/%3E%3C/svg%3E")}@media (-ms-high-contrast:active){.mapboxgl-ctrl button.mapboxgl-ctrl-fullscreen .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg' fill='%23fff'%3E%3Cpath d='M24 16v5.5c0 1.75-.75 2.5-2.5 2.5H16v-1l3-1.5-4-5.5 1-1 5.5 4 1.5-3h1zM6 16l1.5 3 5.5-4 1 1-4 5.5 3 1.5v1H7.5C5.75 24 5 23.25 5 21.5V16h1zm7-11v1l-3 1.5 4 5.5-1 1-5.5-4L6 13H5V7.5C5 5.75 5.75 5 7.5 5H13zm11 2.5c0-1.75-.75-2.5-2.5-2.5H16v1l3 1.5-4 5.5 1 1 5.5-4 1.5 3h1V7.5z'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-shrink .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg' fill='%23fff'%3E%3Cpath d='M18.5 16c-1.75 0-2.5.75-2.5 2.5V24h1l1.5-3 5.5 4 1-1-4-5.5 3-1.5v-1h-5.5zM13 18.5c0-1.75-.75-2.5-2.5-2.5H5v1l3 1.5L4 24l1 1 5.5-4 1.5 3h1v-5.5zm3-8c0 1.75.75 2.5 2.5 2.5H24v-1l-3-1.5L25 5l-1-1-5.5 4L17 5h-1v5.5zM10.5 13c1.75 0 2.5-.75 2.5-2.5V5h-1l-1.5 3L5 4 4 5l4 5.5L5 12v1h5.5z'/%3E%3C/svg%3E")}}@media (-ms-high-contrast:black-on-white){.mapboxgl-ctrl button.mapboxgl-ctrl-fullscreen .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M24 16v5.5c0 1.75-.75 2.5-2.5 2.5H16v-1l3-1.5-4-5.5 1-1 5.5 4 1.5-3h1zM6 16l1.5 3 5.5-4 1 1-4 5.5 3 1.5v1H7.5C5.75 24 5 23.25 5 21.5V16h1zm7-11v1l-3 1.5 4 5.5-1 1-5.5-4L6 13H5V7.5C5 5.75 5.75 5 7.5 5H13zm11 2.5c0-1.75-.75-2.5-2.5-2.5H16v1l3 1.5-4 5.5 1 1 5.5-4 1.5 3h1V7.5z'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-shrink .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M18.5 16c-1.75 0-2.5.75-2.5 2.5V24h1l1.5-3 5.5 4 1-1-4-5.5 3-1.5v-1h-5.5zM13 18.5c0-1.75-.75-2.5-2.5-2.5H5v1l3 1.5L4 24l1 1 5.5-4 1.5 3h1v-5.5zm3-8c0 1.75.75 2.5 2.5 2.5H24v-1l-3-1.5L25 5l-1-1-5.5 4L17 5h-1v5.5zM10.5 13c1.75 0 2.5-.75 2.5-2.5V5h-1l-1.5 3L5 4 4 5l4 5.5L5 12v1h5.5z'/%3E%3C/svg%3E")}}.mapboxgl-ctrl button.mapboxgl-ctrl-compass .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg' fill='%23333'%3E%3Cpath d='M10.5 14l4-8 4 8h-8z'/%3E%3Cpath d='M10.5 16l4 8 4-8h-8z' fill='%23ccc'/%3E%3C/svg%3E")}@media (-ms-high-contrast:active){.mapboxgl-ctrl button.mapboxgl-ctrl-compass .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg' fill='%23fff'%3E%3Cpath d='M10.5 14l4-8 4 8h-8z'/%3E%3Cpath d='M10.5 16l4 8 4-8h-8z' fill='%23999'/%3E%3C/svg%3E")}}@media (-ms-high-contrast:black-on-white){.mapboxgl-ctrl button.mapboxgl-ctrl-compass .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 29 29' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10.5 14l4-8 4 8h-8z'/%3E%3Cpath d='M10.5 16l4 8 4-8h-8z' fill='%23ccc'/%3E%3C/svg%3E")}}.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill='%23333'%3E%3Cpath d='M10 4C9 4 9 5 9 5v.1A5 5 0 005.1 9H5s-1 0-1 1 1 1 1 1h.1A5 5 0 009 14.9v.1s0 1 1 1 1-1 1-1v-.1a5 5 0 003.9-3.9h.1s1 0 1-1-1-1-1-1h-.1A5 5 0 0011 5.1V5s0-1-1-1zm0 2.5a3.5 3.5 0 110 7 3.5 3.5 0 110-7z'/%3E%3Ccircle cx='10' cy='10' r='2'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate:disabled .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill='%23aaa'%3E%3Cpath d='M10 4C9 4 9 5 9 5v.1A5 5 0 005.1 9H5s-1 0-1 1 1 1 1 1h.1A5 5 0 009 14.9v.1s0 1 1 1 1-1 1-1v-.1a5 5 0 003.9-3.9h.1s1 0 1-1-1-1-1-1h-.1A5 5 0 0011 5.1V5s0-1-1-1zm0 2.5a3.5 3.5 0 110 7 3.5 3.5 0 110-7z'/%3E%3Ccircle cx='10' cy='10' r='2'/%3E%3Cpath d='M14 5l1 1-9 9-1-1 9-9z' fill='red'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate.mapboxgl-ctrl-geolocate-active .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill='%2333b5e5'%3E%3Cpath d='M10 4C9 4 9 5 9 5v.1A5 5 0 005.1 9H5s-1 0-1 1 1 1 1 1h.1A5 5 0 009 14.9v.1s0 1 1 1 1-1 1-1v-.1a5 5 0 003.9-3.9h.1s1 0 1-1-1-1-1-1h-.1A5 5 0 0011 5.1V5s0-1-1-1zm0 2.5a3.5 3.5 0 110 7 3.5 3.5 0 110-7z'/%3E%3Ccircle cx='10' cy='10' r='2'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate.mapboxgl-ctrl-geolocate-active-error .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill='%23e58978'%3E%3Cpath d='M10 4C9 4 9 5 9 5v.1A5 5 0 005.1 9H5s-1 0-1 1 1 1 1 1h.1A5 5 0 009 14.9v.1s0 1 1 1 1-1 1-1v-.1a5 5 0 003.9-3.9h.1s1 0 1-1-1-1-1-1h-.1A5 5 0 0011 5.1V5s0-1-1-1zm0 2.5a3.5 3.5 0 110 7 3.5 3.5 0 110-7z'/%3E%3Ccircle cx='10' cy='10' r='2'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate.mapboxgl-ctrl-geolocate-background .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill='%2333b5e5'%3E%3Cpath d='M10 4C9 4 9 5 9 5v.1A5 5 0 005.1 9H5s-1 0-1 1 1 1 1 1h.1A5 5 0 009 14.9v.1s0 1 1 1 1-1 1-1v-.1a5 5 0 003.9-3.9h.1s1 0 1-1-1-1-1-1h-.1A5 5 0 0011 5.1V5s0-1-1-1zm0 2.5a3.5 3.5 0 110 7 3.5 3.5 0 110-7z'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate.mapboxgl-ctrl-geolocate-background-error .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill='%23e54e33'%3E%3Cpath d='M10 4C9 4 9 5 9 5v.1A5 5 0 005.1 9H5s-1 0-1 1 1 1 1 1h.1A5 5 0 009 14.9v.1s0 1 1 1 1-1 1-1v-.1a5 5 0 003.9-3.9h.1s1 0 1-1-1-1-1-1h-.1A5 5 0 0011 5.1V5s0-1-1-1zm0 2.5a3.5 3.5 0 110 7 3.5 3.5 0 110-7z'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate.mapboxgl-ctrl-geolocate-waiting .mapboxgl-ctrl-icon{-webkit-animation:mapboxgl-spin 2s linear infinite;animation:mapboxgl-spin 2s linear infinite}@media (-ms-high-contrast:active){.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill='%23fff'%3E%3Cpath d='M10 4C9 4 9 5 9 5v.1A5 5 0 005.1 9H5s-1 0-1 1 1 1 1 1h.1A5 5 0 009 14.9v.1s0 1 1 1 1-1 1-1v-.1a5 5 0 003.9-3.9h.1s1 0 1-1-1-1-1-1h-.1A5 5 0 0011 5.1V5s0-1-1-1zm0 2.5a3.5 3.5 0 110 7 3.5 3.5 0 110-7z'/%3E%3Ccircle cx='10' cy='10' r='2'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate:disabled .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill='%23999'%3E%3Cpath d='M10 4C9 4 9 5 9 5v.1A5 5 0 005.1 9H5s-1 0-1 1 1 1 1 1h.1A5 5 0 009 14.9v.1s0 1 1 1 1-1 1-1v-.1a5 5 0 003.9-3.9h.1s1 0 1-1-1-1-1-1h-.1A5 5 0 0011 5.1V5s0-1-1-1zm0 2.5a3.5 3.5 0 110 7 3.5 3.5 0 110-7z'/%3E%3Ccircle cx='10' cy='10' r='2'/%3E%3Cpath d='M14 5l1 1-9 9-1-1 9-9z' fill='red'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate.mapboxgl-ctrl-geolocate-active .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill='%2333b5e5'%3E%3Cpath d='M10 4C9 4 9 5 9 5v.1A5 5 0 005.1 9H5s-1 0-1 1 1 1 1 1h.1A5 5 0 009 14.9v.1s0 1 1 1 1-1 1-1v-.1a5 5 0 003.9-3.9h.1s1 0 1-1-1-1-1-1h-.1A5 5 0 0011 5.1V5s0-1-1-1zm0 2.5a3.5 3.5 0 110 7 3.5 3.5 0 110-7z'/%3E%3Ccircle cx='10' cy='10' r='2'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate.mapboxgl-ctrl-geolocate-active-error .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill='%23e58978'%3E%3Cpath d='M10 4C9 4 9 5 9 5v.1A5 5 0 005.1 9H5s-1 0-1 1 1 1 1 1h.1A5 5 0 009 14.9v.1s0 1 1 1 1-1 1-1v-.1a5 5 0 003.9-3.9h.1s1 0 1-1-1-1-1-1h-.1A5 5 0 0011 5.1V5s0-1-1-1zm0 2.5a3.5 3.5 0 110 7 3.5 3.5 0 110-7z'/%3E%3Ccircle cx='10' cy='10' r='2'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate.mapboxgl-ctrl-geolocate-background .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill='%2333b5e5'%3E%3Cpath d='M10 4C9 4 9 5 9 5v.1A5 5 0 005.1 9H5s-1 0-1 1 1 1 1 1h.1A5 5 0 009 14.9v.1s0 1 1 1 1-1 1-1v-.1a5 5 0 003.9-3.9h.1s1 0 1-1-1-1-1-1h-.1A5 5 0 0011 5.1V5s0-1-1-1zm0 2.5a3.5 3.5 0 110 7 3.5 3.5 0 110-7z'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate.mapboxgl-ctrl-geolocate-background-error .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill='%23e54e33'%3E%3Cpath d='M10 4C9 4 9 5 9 5v.1A5 5 0 005.1 9H5s-1 0-1 1 1 1 1 1h.1A5 5 0 009 14.9v.1s0 1 1 1 1-1 1-1v-.1a5 5 0 003.9-3.9h.1s1 0 1-1-1-1-1-1h-.1A5 5 0 0011 5.1V5s0-1-1-1zm0 2.5a3.5 3.5 0 110 7 3.5 3.5 0 110-7z'/%3E%3C/svg%3E")}}@media (-ms-high-contrast:black-on-white){.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10 4C9 4 9 5 9 5v.1A5 5 0 005.1 9H5s-1 0-1 1 1 1 1 1h.1A5 5 0 009 14.9v.1s0 1 1 1 1-1 1-1v-.1a5 5 0 003.9-3.9h.1s1 0 1-1-1-1-1-1h-.1A5 5 0 0011 5.1V5s0-1-1-1zm0 2.5a3.5 3.5 0 110 7 3.5 3.5 0 110-7z'/%3E%3Ccircle cx='10' cy='10' r='2'/%3E%3C/svg%3E")}.mapboxgl-ctrl button.mapboxgl-ctrl-geolocate:disabled .mapboxgl-ctrl-icon{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='29' height='29' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill='%23666'%3E%3Cpath d='M10 4C9 4 9 5 9 5v.1A5 5 0 005.1 9H5s-1 0-1 1 1 1 1 1h.1A5 5 0 009 14.9v.1s0 1 1 1 1-1 1-1v-.1a5 5 0 003.9-3.9h.1s1 0 1-1-1-1-1-1h-.1A5 5 0 0011 5.1V5s0-1-1-1zm0 2.5a3.5 3.5 0 110 7 3.5 3.5 0 110-7z'/%3E%3Ccircle cx='10' cy='10' r='2'/%3E%3Cpath d='M14 5l1 1-9 9-1-1 9-9z' fill='red'/%3E%3C/svg%3E")}}@-webkit-keyframes mapboxgl-spin{0%{-webkit-transform:rotate(0deg)}to{-webkit-transform:rotate(1turn)}}@keyframes mapboxgl-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}a.mapboxgl-ctrl-logo{width:88px;height:23px;margin:0 0 -4px -4px;display:block;background-repeat:no-repeat;cursor:pointer;overflow:hidden;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='88' height='23' viewBox='0 0 88 23' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' fill-rule='evenodd'%3E%3Cdefs%3E%3Cpath id='a' d='M11.5 2.25c5.105 0 9.25 4.145 9.25 9.25s-4.145 9.25-9.25 9.25-9.25-4.145-9.25-9.25 4.145-9.25 9.25-9.25zM6.997 15.983c-.051-.338-.828-5.802 2.233-8.873a4.395 4.395 0 013.13-1.28c1.27 0 2.49.51 3.39 1.42.91.9 1.42 2.12 1.42 3.39 0 1.18-.449 2.301-1.28 3.13C12.72 16.93 7 16 7 16l-.003-.017zM15.3 10.5l-2 .8-.8 2-.8-2-2-.8 2-.8.8-2 .8 2 2 .8z'/%3E%3Cpath id='b' d='M50.63 8c.13 0 .23.1.23.23V9c.7-.76 1.7-1.18 2.73-1.18 2.17 0 3.95 1.85 3.95 4.17s-1.77 4.19-3.94 4.19c-1.04 0-2.03-.43-2.74-1.18v3.77c0 .13-.1.23-.23.23h-1.4c-.13 0-.23-.1-.23-.23V8.23c0-.12.1-.23.23-.23h1.4zm-3.86.01c.01 0 .01 0 .01-.01.13 0 .22.1.22.22v7.55c0 .12-.1.23-.23.23h-1.4c-.13 0-.23-.1-.23-.23V15c-.7.76-1.69 1.19-2.73 1.19-2.17 0-3.94-1.87-3.94-4.19 0-2.32 1.77-4.19 3.94-4.19 1.03 0 2.02.43 2.73 1.18v-.75c0-.12.1-.23.23-.23h1.4zm26.375-.19a4.24 4.24 0 00-4.16 3.29c-.13.59-.13 1.19 0 1.77a4.233 4.233 0 004.17 3.3c2.35 0 4.26-1.87 4.26-4.19 0-2.32-1.9-4.17-4.27-4.17zM60.63 5c.13 0 .23.1.23.23v3.76c.7-.76 1.7-1.18 2.73-1.18 1.88 0 3.45 1.4 3.84 3.28.13.59.13 1.2 0 1.8-.39 1.88-1.96 3.29-3.84 3.29-1.03 0-2.02-.43-2.73-1.18v.77c0 .12-.1.23-.23.23h-1.4c-.13 0-.23-.1-.23-.23V5.23c0-.12.1-.23.23-.23h1.4zm-34 11h-1.4c-.13 0-.23-.11-.23-.23V8.22c.01-.13.1-.22.23-.22h1.4c.13 0 .22.11.23.22v.68c.5-.68 1.3-1.09 2.16-1.1h.03c1.09 0 2.09.6 2.6 1.55.45-.95 1.4-1.55 2.44-1.56 1.62 0 2.93 1.25 2.9 2.78l.03 5.2c0 .13-.1.23-.23.23h-1.41c-.13 0-.23-.11-.23-.23v-4.59c0-.98-.74-1.71-1.62-1.71-.8 0-1.46.7-1.59 1.62l.01 4.68c0 .13-.11.23-.23.23h-1.41c-.13 0-.23-.11-.23-.23v-4.59c0-.98-.74-1.71-1.62-1.71-.85 0-1.54.79-1.6 1.8v4.5c0 .13-.1.23-.23.23zm53.615 0h-1.61c-.04 0-.08-.01-.12-.03-.09-.06-.13-.19-.06-.28l2.43-3.71-2.39-3.65a.213.213 0 01-.03-.12c0-.12.09-.21.21-.21h1.61c.13 0 .24.06.3.17l1.41 2.37 1.4-2.37a.34.34 0 01.3-.17h1.6c.04 0 .08.01.12.03.09.06.13.19.06.28l-2.37 3.65 2.43 3.7c0 .05.01.09.01.13 0 .12-.09.21-.21.21h-1.61c-.13 0-.24-.06-.3-.17l-1.44-2.42-1.44 2.42a.34.34 0 01-.3.17zm-7.12-1.49c-1.33 0-2.42-1.12-2.42-2.51 0-1.39 1.08-2.52 2.42-2.52 1.33 0 2.42 1.12 2.42 2.51 0 1.39-1.08 2.51-2.42 2.52zm-19.865 0c-1.32 0-2.39-1.11-2.42-2.48v-.07c.02-1.38 1.09-2.49 2.4-2.49 1.32 0 2.41 1.12 2.41 2.51 0 1.39-1.07 2.52-2.39 2.53zm-8.11-2.48c-.01 1.37-1.09 2.47-2.41 2.47s-2.42-1.12-2.42-2.51c0-1.39 1.08-2.52 2.4-2.52 1.33 0 2.39 1.11 2.41 2.48l.02.08zm18.12 2.47c-1.32 0-2.39-1.11-2.41-2.48v-.06c.02-1.38 1.09-2.48 2.41-2.48s2.42 1.12 2.42 2.51c0 1.39-1.09 2.51-2.42 2.51z'/%3E%3C/defs%3E%3Cmask id='c'%3E%3Crect width='100%25' height='100%25' fill='%23fff'/%3E%3Cuse xlink:href='%23a'/%3E%3Cuse xlink:href='%23b'/%3E%3C/mask%3E%3Cg opacity='.3' stroke='%23000' stroke-width='3'%3E%3Ccircle mask='url(%23c)' cx='11.5' cy='11.5' r='9.25'/%3E%3Cuse xlink:href='%23b' mask='url(%23c)'/%3E%3C/g%3E%3Cg opacity='.9' fill='%23fff'%3E%3Cuse xlink:href='%23a'/%3E%3Cuse xlink:href='%23b'/%3E%3C/g%3E%3C/svg%3E")}a.mapboxgl-ctrl-logo.mapboxgl-compact{width:23px}@media (-ms-high-contrast:active){a.mapboxgl-ctrl-logo{background-color:transparent;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='88' height='23' viewBox='0 0 88 23' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' fill-rule='evenodd'%3E%3Cdefs%3E%3Cpath id='a' d='M11.5 2.25c5.105 0 9.25 4.145 9.25 9.25s-4.145 9.25-9.25 9.25-9.25-4.145-9.25-9.25 4.145-9.25 9.25-9.25zM6.997 15.983c-.051-.338-.828-5.802 2.233-8.873a4.395 4.395 0 013.13-1.28c1.27 0 2.49.51 3.39 1.42.91.9 1.42 2.12 1.42 3.39 0 1.18-.449 2.301-1.28 3.13C12.72 16.93 7 16 7 16l-.003-.017zM15.3 10.5l-2 .8-.8 2-.8-2-2-.8 2-.8.8-2 .8 2 2 .8z'/%3E%3Cpath id='b' d='M50.63 8c.13 0 .23.1.23.23V9c.7-.76 1.7-1.18 2.73-1.18 2.17 0 3.95 1.85 3.95 4.17s-1.77 4.19-3.94 4.19c-1.04 0-2.03-.43-2.74-1.18v3.77c0 .13-.1.23-.23.23h-1.4c-.13 0-.23-.1-.23-.23V8.23c0-.12.1-.23.23-.23h1.4zm-3.86.01c.01 0 .01 0 .01-.01.13 0 .22.1.22.22v7.55c0 .12-.1.23-.23.23h-1.4c-.13 0-.23-.1-.23-.23V15c-.7.76-1.69 1.19-2.73 1.19-2.17 0-3.94-1.87-3.94-4.19 0-2.32 1.77-4.19 3.94-4.19 1.03 0 2.02.43 2.73 1.18v-.75c0-.12.1-.23.23-.23h1.4zm26.375-.19a4.24 4.24 0 00-4.16 3.29c-.13.59-.13 1.19 0 1.77a4.233 4.233 0 004.17 3.3c2.35 0 4.26-1.87 4.26-4.19 0-2.32-1.9-4.17-4.27-4.17zM60.63 5c.13 0 .23.1.23.23v3.76c.7-.76 1.7-1.18 2.73-1.18 1.88 0 3.45 1.4 3.84 3.28.13.59.13 1.2 0 1.8-.39 1.88-1.96 3.29-3.84 3.29-1.03 0-2.02-.43-2.73-1.18v.77c0 .12-.1.23-.23.23h-1.4c-.13 0-.23-.1-.23-.23V5.23c0-.12.1-.23.23-.23h1.4zm-34 11h-1.4c-.13 0-.23-.11-.23-.23V8.22c.01-.13.1-.22.23-.22h1.4c.13 0 .22.11.23.22v.68c.5-.68 1.3-1.09 2.16-1.1h.03c1.09 0 2.09.6 2.6 1.55.45-.95 1.4-1.55 2.44-1.56 1.62 0 2.93 1.25 2.9 2.78l.03 5.2c0 .13-.1.23-.23.23h-1.41c-.13 0-.23-.11-.23-.23v-4.59c0-.98-.74-1.71-1.62-1.71-.8 0-1.46.7-1.59 1.62l.01 4.68c0 .13-.11.23-.23.23h-1.41c-.13 0-.23-.11-.23-.23v-4.59c0-.98-.74-1.71-1.62-1.71-.85 0-1.54.79-1.6 1.8v4.5c0 .13-.1.23-.23.23zm53.615 0h-1.61c-.04 0-.08-.01-.12-.03-.09-.06-.13-.19-.06-.28l2.43-3.71-2.39-3.65a.213.213 0 01-.03-.12c0-.12.09-.21.21-.21h1.61c.13 0 .24.06.3.17l1.41 2.37 1.4-2.37a.34.34 0 01.3-.17h1.6c.04 0 .08.01.12.03.09.06.13.19.06.28l-2.37 3.65 2.43 3.7c0 .05.01.09.01.13 0 .12-.09.21-.21.21h-1.61c-.13 0-.24-.06-.3-.17l-1.44-2.42-1.44 2.42a.34.34 0 01-.3.17zm-7.12-1.49c-1.33 0-2.42-1.12-2.42-2.51 0-1.39 1.08-2.52 2.42-2.52 1.33 0 2.42 1.12 2.42 2.51 0 1.39-1.08 2.51-2.42 2.52zm-19.865 0c-1.32 0-2.39-1.11-2.42-2.48v-.07c.02-1.38 1.09-2.49 2.4-2.49 1.32 0 2.41 1.12 2.41 2.51 0 1.39-1.07 2.52-2.39 2.53zm-8.11-2.48c-.01 1.37-1.09 2.47-2.41 2.47s-2.42-1.12-2.42-2.51c0-1.39 1.08-2.52 2.4-2.52 1.33 0 2.39 1.11 2.41 2.48l.02.08zm18.12 2.47c-1.32 0-2.39-1.11-2.41-2.48v-.06c.02-1.38 1.09-2.48 2.41-2.48s2.42 1.12 2.42 2.51c0 1.39-1.09 2.51-2.42 2.51z'/%3E%3C/defs%3E%3Cmask id='c'%3E%3Crect width='100%25' height='100%25' fill='%23fff'/%3E%3Cuse xlink:href='%23a'/%3E%3Cuse xlink:href='%23b'/%3E%3C/mask%3E%3Cg stroke='%23000' stroke-width='3'%3E%3Ccircle mask='url(%23c)' cx='11.5' cy='11.5' r='9.25'/%3E%3Cuse xlink:href='%23b' mask='url(%23c)'/%3E%3C/g%3E%3Cg fill='%23fff'%3E%3Cuse xlink:href='%23a'/%3E%3Cuse xlink:href='%23b'/%3E%3C/g%3E%3C/svg%3E")}}@media (-ms-high-contrast:black-on-white){a.mapboxgl-ctrl-logo{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='88' height='23' viewBox='0 0 88 23' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' fill-rule='evenodd'%3E%3Cdefs%3E%3Cpath id='a' d='M11.5 2.25c5.105 0 9.25 4.145 9.25 9.25s-4.145 9.25-9.25 9.25-9.25-4.145-9.25-9.25 4.145-9.25 9.25-9.25zM6.997 15.983c-.051-.338-.828-5.802 2.233-8.873a4.395 4.395 0 013.13-1.28c1.27 0 2.49.51 3.39 1.42.91.9 1.42 2.12 1.42 3.39 0 1.18-.449 2.301-1.28 3.13C12.72 16.93 7 16 7 16l-.003-.017zM15.3 10.5l-2 .8-.8 2-.8-2-2-.8 2-.8.8-2 .8 2 2 .8z'/%3E%3Cpath id='b' d='M50.63 8c.13 0 .23.1.23.23V9c.7-.76 1.7-1.18 2.73-1.18 2.17 0 3.95 1.85 3.95 4.17s-1.77 4.19-3.94 4.19c-1.04 0-2.03-.43-2.74-1.18v3.77c0 .13-.1.23-.23.23h-1.4c-.13 0-.23-.1-.23-.23V8.23c0-.12.1-.23.23-.23h1.4zm-3.86.01c.01 0 .01 0 .01-.01.13 0 .22.1.22.22v7.55c0 .12-.1.23-.23.23h-1.4c-.13 0-.23-.1-.23-.23V15c-.7.76-1.69 1.19-2.73 1.19-2.17 0-3.94-1.87-3.94-4.19 0-2.32 1.77-4.19 3.94-4.19 1.03 0 2.02.43 2.73 1.18v-.75c0-.12.1-.23.23-.23h1.4zm26.375-.19a4.24 4.24 0 00-4.16 3.29c-.13.59-.13 1.19 0 1.77a4.233 4.233 0 004.17 3.3c2.35 0 4.26-1.87 4.26-4.19 0-2.32-1.9-4.17-4.27-4.17zM60.63 5c.13 0 .23.1.23.23v3.76c.7-.76 1.7-1.18 2.73-1.18 1.88 0 3.45 1.4 3.84 3.28.13.59.13 1.2 0 1.8-.39 1.88-1.96 3.29-3.84 3.29-1.03 0-2.02-.43-2.73-1.18v.77c0 .12-.1.23-.23.23h-1.4c-.13 0-.23-.1-.23-.23V5.23c0-.12.1-.23.23-.23h1.4zm-34 11h-1.4c-.13 0-.23-.11-.23-.23V8.22c.01-.13.1-.22.23-.22h1.4c.13 0 .22.11.23.22v.68c.5-.68 1.3-1.09 2.16-1.1h.03c1.09 0 2.09.6 2.6 1.55.45-.95 1.4-1.55 2.44-1.56 1.62 0 2.93 1.25 2.9 2.78l.03 5.2c0 .13-.1.23-.23.23h-1.41c-.13 0-.23-.11-.23-.23v-4.59c0-.98-.74-1.71-1.62-1.71-.8 0-1.46.7-1.59 1.62l.01 4.68c0 .13-.11.23-.23.23h-1.41c-.13 0-.23-.11-.23-.23v-4.59c0-.98-.74-1.71-1.62-1.71-.85 0-1.54.79-1.6 1.8v4.5c0 .13-.1.23-.23.23zm53.615 0h-1.61c-.04 0-.08-.01-.12-.03-.09-.06-.13-.19-.06-.28l2.43-3.71-2.39-3.65a.213.213 0 01-.03-.12c0-.12.09-.21.21-.21h1.61c.13 0 .24.06.3.17l1.41 2.37 1.4-2.37a.34.34 0 01.3-.17h1.6c.04 0 .08.01.12.03.09.06.13.19.06.28l-2.37 3.65 2.43 3.7c0 .05.01.09.01.13 0 .12-.09.21-.21.21h-1.61c-.13 0-.24-.06-.3-.17l-1.44-2.42-1.44 2.42a.34.34 0 01-.3.17zm-7.12-1.49c-1.33 0-2.42-1.12-2.42-2.51 0-1.39 1.08-2.52 2.42-2.52 1.33 0 2.42 1.12 2.42 2.51 0 1.39-1.08 2.51-2.42 2.52zm-19.865 0c-1.32 0-2.39-1.11-2.42-2.48v-.07c.02-1.38 1.09-2.49 2.4-2.49 1.32 0 2.41 1.12 2.41 2.51 0 1.39-1.07 2.52-2.39 2.53zm-8.11-2.48c-.01 1.37-1.09 2.47-2.41 2.47s-2.42-1.12-2.42-2.51c0-1.39 1.08-2.52 2.4-2.52 1.33 0 2.39 1.11 2.41 2.48l.02.08zm18.12 2.47c-1.32 0-2.39-1.11-2.41-2.48v-.06c.02-1.38 1.09-2.48 2.41-2.48s2.42 1.12 2.42 2.51c0 1.39-1.09 2.51-2.42 2.51z'/%3E%3C/defs%3E%3Cmask id='c'%3E%3Crect width='100%25' height='100%25' fill='%23fff'/%3E%3Cuse xlink:href='%23a'/%3E%3Cuse xlink:href='%23b'/%3E%3C/mask%3E%3Cg stroke='%23fff' stroke-width='3' fill='%23fff'%3E%3Ccircle mask='url(%23c)' cx='11.5' cy='11.5' r='9.25'/%3E%3Cuse xlink:href='%23b' mask='url(%23c)'/%3E%3C/g%3E%3Cuse xlink:href='%23a'/%3E%3Cuse xlink:href='%23b'/%3E%3C/svg%3E")}}.mapboxgl-ctrl.mapboxgl-ctrl-attrib{padding:0 5px;background-color:hsla(0,0%,100%,.5);margin:0}@media screen{.mapboxgl-ctrl-attrib.mapboxgl-compact{min-height:20px;padding:2px 24px 2px 0;margin:10px;position:relative;background-color:#fff;border-radius:12px}.mapboxgl-ctrl-attrib.mapboxgl-compact-show{padding:2px 28px 2px 8px;visibility:visible}.mapboxgl-ctrl-bottom-left>.mapboxgl-ctrl-attrib.mapboxgl-compact-show,.mapboxgl-ctrl-top-left>.mapboxgl-ctrl-attrib.mapboxgl-compact-show{padding:2px 8px 2px 28px;border-radius:12px}.mapboxgl-ctrl-attrib.mapboxgl-compact .mapboxgl-ctrl-attrib-inner{display:none}.mapboxgl-ctrl-attrib-button{display:none;cursor:pointer;position:absolute;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='24' height='24' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill-rule='evenodd'%3E%3Cpath d='M4 10a6 6 0 1012 0 6 6 0 10-12 0m5-3a1 1 0 102 0 1 1 0 10-2 0m0 3a1 1 0 112 0v3a1 1 0 11-2 0'/%3E%3C/svg%3E");background-color:hsla(0,0%,100%,.5);width:24px;height:24px;-webkit-box-sizing:border-box;box-sizing:border-box;border-radius:12px;outline:none;top:0;right:0;border:0}.mapboxgl-ctrl-bottom-left .mapboxgl-ctrl-attrib-button,.mapboxgl-ctrl-top-left .mapboxgl-ctrl-attrib-button{left:0}.mapboxgl-ctrl-attrib.mapboxgl-compact-show .mapboxgl-ctrl-attrib-inner,.mapboxgl-ctrl-attrib.mapboxgl-compact .mapboxgl-ctrl-attrib-button{display:block}.mapboxgl-ctrl-attrib.mapboxgl-compact-show .mapboxgl-ctrl-attrib-button{background-color:rgba(0,0,0,.05)}.mapboxgl-ctrl-bottom-right>.mapboxgl-ctrl-attrib.mapboxgl-compact:after{bottom:0;right:0}.mapboxgl-ctrl-top-right>.mapboxgl-ctrl-attrib.mapboxgl-compact:after{top:0;right:0}.mapboxgl-ctrl-top-left>.mapboxgl-ctrl-attrib.mapboxgl-compact:after{top:0;left:0}.mapboxgl-ctrl-bottom-left>.mapboxgl-ctrl-attrib.mapboxgl-compact:after{bottom:0;left:0}}@media screen and (-ms-high-contrast:active){.mapboxgl-ctrl-attrib.mapboxgl-compact:after{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='24' height='24' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill-rule='evenodd' fill='%23fff'%3E%3Cpath d='M4 10a6 6 0 1012 0 6 6 0 10-12 0m5-3a1 1 0 102 0 1 1 0 10-2 0m0 3a1 1 0 112 0v3a1 1 0 11-2 0'/%3E%3C/svg%3E")}}@media screen and (-ms-high-contrast:black-on-white){.mapboxgl-ctrl-attrib.mapboxgl-compact:after{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='24' height='24' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg' fill-rule='evenodd'%3E%3Cpath d='M4 10a6 6 0 1012 0 6 6 0 10-12 0m5-3a1 1 0 102 0 1 1 0 10-2 0m0 3a1 1 0 112 0v3a1 1 0 11-2 0'/%3E%3C/svg%3E")}}.mapboxgl-ctrl-attrib a{color:rgba(0,0,0,.75);text-decoration:none}.mapboxgl-ctrl-attrib a:hover{color:inherit;text-decoration:underline}.mapboxgl-ctrl-attrib .mapbox-improve-map{font-weight:700;margin-left:2px}.mapboxgl-attrib-empty{display:none}.mapboxgl-ctrl-scale{background-color:hsla(0,0%,100%,.75);font-size:10px;border:2px solid #333;border-top:#333;padding:0 5px;color:#333;-webkit-box-sizing:border-box;box-sizing:border-box}.mapboxgl-popup{position:absolute;top:0;left:0;display:-webkit-box;display:-ms-flexbox;display:flex;will-change:transform;pointer-events:none}.mapboxgl-popup-anchor-top,.mapboxgl-popup-anchor-top-left,.mapboxgl-popup-anchor-top-right{-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column}.mapboxgl-popup-anchor-bottom,.mapboxgl-popup-anchor-bottom-left,.mapboxgl-popup-anchor-bottom-right{-webkit-box-orient:vertical;-webkit-box-direction:reverse;-ms-flex-direction:column-reverse;flex-direction:column-reverse}.mapboxgl-popup-anchor-left{-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row}.mapboxgl-popup-anchor-right{-webkit-box-orient:horizontal;-webkit-box-direction:reverse;-ms-flex-direction:row-reverse;flex-direction:row-reverse}.mapboxgl-popup-tip{width:0;height:0;border:10px solid transparent;z-index:1}.mapboxgl-popup-anchor-top .mapboxgl-popup-tip{-webkit-align-self:center;-ms-flex-item-align:center;align-self:center;border-top:none;border-bottom-color:#fff}.mapboxgl-popup-anchor-top-left .mapboxgl-popup-tip{-webkit-align-self:flex-start;-ms-flex-item-align:start;align-self:flex-start;border-top:none;border-left:none;border-bottom-color:#fff}.mapboxgl-popup-anchor-top-right .mapboxgl-popup-tip{-webkit-align-self:flex-end;-ms-flex-item-align:end;align-self:flex-end;border-top:none;border-right:none;border-bottom-color:#fff}.mapboxgl-popup-anchor-bottom .mapboxgl-popup-tip{-webkit-align-self:center;-ms-flex-item-align:center;align-self:center;border-bottom:none;border-top-color:#fff}.mapboxgl-popup-anchor-bottom-left .mapboxgl-popup-tip{-webkit-align-self:flex-start;-ms-flex-item-align:start;align-self:flex-start;border-bottom:none;border-left:none;border-top-color:#fff}.mapboxgl-popup-anchor-bottom-right .mapboxgl-popup-tip{-webkit-align-self:flex-end;-ms-flex-item-align:end;align-self:flex-end;border-bottom:none;border-right:none;border-top-color:#fff}.mapboxgl-popup-anchor-left .mapboxgl-popup-tip{-webkit-align-self:center;-ms-flex-item-align:center;align-self:center;border-left:none;border-right-color:#fff}.mapboxgl-popup-anchor-right .mapboxgl-popup-tip{-webkit-align-self:center;-ms-flex-item-align:center;align-self:center;border-right:none;border-left-color:#fff}.mapboxgl-popup-close-button{position:absolute;right:0;top:0;border:0;border-radius:0 3px 0 0;cursor:pointer;background-color:transparent}.mapboxgl-popup-close-button:hover{background-color:rgba(0,0,0,.05)}.mapboxgl-popup-content{position:relative;background:#fff;border-radius:3px;-webkit-box-shadow:0 1px 2px rgba(0,0,0,.1);box-shadow:0 1px 2px rgba(0,0,0,.1);padding:10px 10px 15px;pointer-events:auto}.mapboxgl-popup-anchor-top-left .mapboxgl-popup-content{border-top-left-radius:0}.mapboxgl-popup-anchor-top-right .mapboxgl-popup-content{border-top-right-radius:0}.mapboxgl-popup-anchor-bottom-left .mapboxgl-popup-content{border-bottom-left-radius:0}.mapboxgl-popup-anchor-bottom-right .mapboxgl-popup-content{border-bottom-right-radius:0}.mapboxgl-popup-track-pointer{display:none}.mapboxgl-popup-track-pointer *{pointer-events:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.mapboxgl-map:hover .mapboxgl-popup-track-pointer{display:-webkit-box;display:-ms-flexbox;display:flex}.mapboxgl-map:active .mapboxgl-popup-track-pointer{display:none}.mapboxgl-marker{position:absolute;top:0;left:0;will-change:transform}.mapboxgl-user-location-dot,.mapboxgl-user-location-dot:before{background-color:#1da1f2;width:15px;height:15px;border-radius:50%}.mapboxgl-user-location-dot:before{content:"";position:absolute;-webkit-animation:mapboxgl-user-location-dot-pulse 2s infinite;animation:mapboxgl-user-location-dot-pulse 2s infinite}.mapboxgl-user-location-dot:after{border-radius:50%;border:2px solid #fff;content:"";height:19px;left:-2px;position:absolute;top:-2px;width:19px;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-box-shadow:0 0 3px rgba(0,0,0,.35);box-shadow:0 0 3px rgba(0,0,0,.35)}@-webkit-keyframes mapboxgl-user-location-dot-pulse{0%{-webkit-transform:scale(1);opacity:1}70%{-webkit-transform:scale(3);opacity:0}to{-webkit-transform:scale(1);opacity:0}}@keyframes mapboxgl-user-location-dot-pulse{0%{-webkit-transform:scale(1);transform:scale(1);opacity:1}70%{-webkit-transform:scale(3);transform:scale(3);opacity:0}to{-webkit-transform:scale(1);transform:scale(1);opacity:0}}.mapboxgl-user-location-dot-stale{background-color:#aaa}.mapboxgl-user-location-dot-stale:after{display:none}.mapboxgl-user-location-accuracy-circle{background-color:rgba(29,161,242,.2);width:1px;height:1px;border-radius:100%}.mapboxgl-crosshair,.mapboxgl-crosshair .mapboxgl-interactive,.mapboxgl-crosshair .mapboxgl-interactive:active{cursor:crosshair}.mapboxgl-boxzoom{position:absolute;top:0;left:0;width:0;height:0;background:#fff;border:2px dotted #202020;opacity:.5}@media print{.mapbox-improve-map{display:none}}`),window.mapboxgl=tA();var rz=0,P5="101MlGsZ2AmmA&access_token=pk.eyJ1IjoiZXhhbXBsZXMiLCJhIjoiY2p0MG01MXRqMW45cjQzb2R6b2ptc3J4MSJ9.zA2W0IkI0c6KaAhJfk9bWg",nz=(T5=(0,sa.b2)(),T5(M5=function(e){(0,Me.Z)(r,e);var i=J9(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u1&&arguments[1]!==void 0?arguments[1]:{x:0,y:0,z:0},u=this.lngLatToMercator(t,0),c=u.x,m=u.y;return[c-a.x,m-a.y]}},{key:"lngLatToMercator",value:function(t,a){var u=window.mapboxgl.MercatorCoordinate.fromLngLat(t,a),c=u.x,m=c===void 0?0:c,E=u.y,H=E===void 0?0:E,re=u.z,xe=re===void 0?0:re;return{x:m,y:H,z:xe}}},{key:"getModelMatrix",value:function(t,a,u){var c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:[1,1,1],m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{x:0,y:0,z:0},E=window.mapboxgl.MercatorCoordinate.fromLngLat(t,a),H=E.meterInMercatorCoordinateUnits(),re=Mf();return wd(re,re,Zd(E.x-m.x,E.y-m.y,E.z||0-m.z)),Md(re,re,Zd(H*c[0],-H*c[1],H*c[2])),Bd(re,re,u[0]),Qd(re,re,u[1]),Jd(re,re,u[2]),re}},{key:"init",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u=this,c,m,E,H,re,xe,ke,rt,vt,It,er,Ar,Or;return Ur().wrap(function(Ln){for(;;)switch(Ln.prev=Ln.next){case 0:c=this.config,m=c.id,E=m===void 0?"map":m,H=c.attributionControl,re=H===void 0?!1:H,xe=c.style,ke=xe===void 0?"light":xe,rt=c.token,vt=rt===void 0?P5:rt,It=c.rotation,er=It===void 0?0:It,Ar=c.mapInstance,Or=(0,X0.Z)(c,Q9),this.viewport=new C5,!Ar&&!window.mapboxgl&&console.error(this.configService.getSceneWarninfo("SDK")),vt===P5&&ke!=="blank"&&!window.mapboxgl.accessToken&&!Ar&&console.warn(this.configService.getSceneWarninfo("MapToken")),!Ar&&!window.mapboxgl.accessToken&&(window.mapboxgl.accessToken=vt),Ar?(this.map=Ar,this.$mapContainer=this.map.getContainer()):(this.$mapContainer=this.creatMapContainer(E),this.map=new window.mapboxgl.Map((0,Se.Z)({container:this.$mapContainer,style:this.getMapStyleValue(ke),attributionControl:re,bearing:er},Or))),this.map.on("load",function(){u.handleCameraChanged()}),this.map.on("move",this.handleCameraChanged),this.handleCameraChanged();case 9:case"end":return Ln.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"destroy",value:function(){var t;(t=this.$mapContainer)===null||t===void 0||(t=t.parentNode)===null||t===void 0||t.removeChild(this.$mapContainer),this.eventEmitter.removeAllListeners(),this.map&&(this.map.remove(),this.$mapContainer=null)}},{key:"emit",value:function(t){for(var a,u=arguments.length,c=new Array(u>1?u-1:0),m=1;m1?u-1:0),m=1;m.maplibregl-ctrl-attrib.maplibregl-compact-show,.maplibregl-ctrl-top-left>.maplibregl-ctrl-attrib.maplibregl-compact-show{border-radius:12px;padding:2px 8px 2px 28px}.maplibregl-ctrl-attrib.maplibregl-compact .maplibregl-ctrl-attrib-inner{display:none}.maplibregl-ctrl-attrib-button{background-color:hsla(0,0%,100%,.5);background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill-rule='evenodd' viewBox='0 0 20 20'%3E%3Cpath d='M4 10a6 6 0 1 0 12 0 6 6 0 1 0-12 0m5-3a1 1 0 1 0 2 0 1 1 0 1 0-2 0m0 3a1 1 0 1 1 2 0v3a1 1 0 1 1-2 0'/%3E%3C/svg%3E");border:0;border-radius:12px;-webkit-box-sizing:border-box;box-sizing:border-box;cursor:pointer;display:none;height:24px;outline:none;position:absolute;right:0;top:0;width:24px}.maplibregl-ctrl-attrib summary.maplibregl-ctrl-attrib-button{-webkit-appearance:none;-moz-appearance:none;appearance:none;list-style:none}.maplibregl-ctrl-attrib summary.maplibregl-ctrl-attrib-button::-webkit-details-marker{display:none}.maplibregl-ctrl-bottom-left .maplibregl-ctrl-attrib-button,.maplibregl-ctrl-top-left .maplibregl-ctrl-attrib-button{left:0}.maplibregl-ctrl-attrib.maplibregl-compact .maplibregl-ctrl-attrib-button,.maplibregl-ctrl-attrib.maplibregl-compact-show .maplibregl-ctrl-attrib-inner{display:block}.maplibregl-ctrl-attrib.maplibregl-compact-show .maplibregl-ctrl-attrib-button{background-color:rgb(0 0 0/5%)}.maplibregl-ctrl-bottom-right>.maplibregl-ctrl-attrib.maplibregl-compact:after{bottom:0;right:0}.maplibregl-ctrl-top-right>.maplibregl-ctrl-attrib.maplibregl-compact:after{right:0;top:0}.maplibregl-ctrl-top-left>.maplibregl-ctrl-attrib.maplibregl-compact:after{left:0;top:0}.maplibregl-ctrl-bottom-left>.maplibregl-ctrl-attrib.maplibregl-compact:after{bottom:0;left:0}}@media screen and (-ms-high-contrast:active){.maplibregl-ctrl-attrib.maplibregl-compact:after{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill='%23fff' fill-rule='evenodd' viewBox='0 0 20 20'%3E%3Cpath d='M4 10a6 6 0 1 0 12 0 6 6 0 1 0-12 0m5-3a1 1 0 1 0 2 0 1 1 0 1 0-2 0m0 3a1 1 0 1 1 2 0v3a1 1 0 1 1-2 0'/%3E%3C/svg%3E")}}@media screen and (-ms-high-contrast:black-on-white){.maplibregl-ctrl-attrib.maplibregl-compact:after{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill-rule='evenodd' viewBox='0 0 20 20'%3E%3Cpath d='M4 10a6 6 0 1 0 12 0 6 6 0 1 0-12 0m5-3a1 1 0 1 0 2 0 1 1 0 1 0-2 0m0 3a1 1 0 1 1 2 0v3a1 1 0 1 1-2 0'/%3E%3C/svg%3E")}}.maplibregl-ctrl-attrib a{color:rgba(0,0,0,.75);text-decoration:none}.maplibregl-ctrl-attrib a:hover{color:inherit;text-decoration:underline}.maplibregl-attrib-empty{display:none}.maplibregl-ctrl-scale{background-color:hsla(0,0%,100%,.75);border:2px solid #333;border-top:#333;-webkit-box-sizing:border-box;box-sizing:border-box;color:#333;font-size:10px;padding:0 5px}.maplibregl-popup{display:-webkit-box;display:-ms-flexbox;display:flex;left:0;pointer-events:none;position:absolute;top:0;will-change:transform}.maplibregl-popup-anchor-top,.maplibregl-popup-anchor-top-left,.maplibregl-popup-anchor-top-right{-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column}.maplibregl-popup-anchor-bottom,.maplibregl-popup-anchor-bottom-left,.maplibregl-popup-anchor-bottom-right{-webkit-box-orient:vertical;-webkit-box-direction:reverse;-ms-flex-direction:column-reverse;flex-direction:column-reverse}.maplibregl-popup-anchor-left{-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row}.maplibregl-popup-anchor-right{-webkit-box-orient:horizontal;-webkit-box-direction:reverse;-ms-flex-direction:row-reverse;flex-direction:row-reverse}.maplibregl-popup-tip{border:10px solid transparent;height:0;width:0;z-index:1}.maplibregl-popup-anchor-top .maplibregl-popup-tip{-ms-flex-item-align:center;align-self:center;border-bottom-color:#fff;border-top:none}.maplibregl-popup-anchor-top-left .maplibregl-popup-tip{-ms-flex-item-align:start;align-self:flex-start;border-bottom-color:#fff;border-left:none;border-top:none}.maplibregl-popup-anchor-top-right .maplibregl-popup-tip{-ms-flex-item-align:end;align-self:flex-end;border-bottom-color:#fff;border-right:none;border-top:none}.maplibregl-popup-anchor-bottom .maplibregl-popup-tip{-ms-flex-item-align:center;align-self:center;border-bottom:none;border-top-color:#fff}.maplibregl-popup-anchor-bottom-left .maplibregl-popup-tip{-ms-flex-item-align:start;align-self:flex-start;border-bottom:none;border-left:none;border-top-color:#fff}.maplibregl-popup-anchor-bottom-right .maplibregl-popup-tip{-ms-flex-item-align:end;align-self:flex-end;border-bottom:none;border-right:none;border-top-color:#fff}.maplibregl-popup-anchor-left .maplibregl-popup-tip{-ms-flex-item-align:center;align-self:center;border-left:none;border-right-color:#fff}.maplibregl-popup-anchor-right .maplibregl-popup-tip{-ms-flex-item-align:center;align-self:center;border-left-color:#fff;border-right:none}.maplibregl-popup-close-button{background-color:transparent;border:0;border-radius:0 3px 0 0;cursor:pointer;position:absolute;right:0;top:0}.maplibregl-popup-close-button:hover{background-color:rgb(0 0 0/5%)}.maplibregl-popup-content{background:#fff;border-radius:3px;-webkit-box-shadow:0 1px 2px rgba(0,0,0,.1);box-shadow:0 1px 2px rgba(0,0,0,.1);padding:15px 10px;pointer-events:auto;position:relative}.maplibregl-popup-anchor-top-left .maplibregl-popup-content{border-top-left-radius:0}.maplibregl-popup-anchor-top-right .maplibregl-popup-content{border-top-right-radius:0}.maplibregl-popup-anchor-bottom-left .maplibregl-popup-content{border-bottom-left-radius:0}.maplibregl-popup-anchor-bottom-right .maplibregl-popup-content{border-bottom-right-radius:0}.maplibregl-popup-track-pointer{display:none}.maplibregl-popup-track-pointer *{pointer-events:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.maplibregl-map:hover .maplibregl-popup-track-pointer{display:-webkit-box;display:-ms-flexbox;display:flex}.maplibregl-map:active .maplibregl-popup-track-pointer{display:none}.maplibregl-marker{left:0;position:absolute;top:0;will-change:transform}.maplibregl-user-location-dot,.maplibregl-user-location-dot:before{background-color:#1da1f2;border-radius:50%;height:15px;width:15px}.maplibregl-user-location-dot:before{-webkit-animation:maplibregl-user-location-dot-pulse 2s infinite;animation:maplibregl-user-location-dot-pulse 2s infinite;content:"";position:absolute}.maplibregl-user-location-dot:after{border:2px solid #fff;border-radius:50%;-webkit-box-shadow:0 0 3px rgba(0,0,0,.35);box-shadow:0 0 3px rgba(0,0,0,.35);-webkit-box-sizing:border-box;box-sizing:border-box;content:"";height:19px;left:-2px;position:absolute;top:-2px;width:19px}@-webkit-keyframes maplibregl-user-location-dot-pulse{0%{opacity:1;-webkit-transform:scale(1);transform:scale(1)}70%{opacity:0;-webkit-transform:scale(3);transform:scale(3)}to{opacity:0;-webkit-transform:scale(1);transform:scale(1)}}@keyframes maplibregl-user-location-dot-pulse{0%{opacity:1;-webkit-transform:scale(1);transform:scale(1)}70%{opacity:0;-webkit-transform:scale(3);transform:scale(3)}to{opacity:0;-webkit-transform:scale(1);transform:scale(1)}}.maplibregl-user-location-dot-stale{background-color:#aaa}.maplibregl-user-location-dot-stale:after{display:none}.maplibregl-user-location-accuracy-circle{background-color:#1da1f233;border-radius:100%;height:1px;width:1px}.maplibregl-crosshair,.maplibregl-crosshair .maplibregl-interactive,.maplibregl-crosshair .maplibregl-interactive:active{cursor:crosshair}.maplibregl-boxzoom{background:#fff;border:2px dotted #202020;height:0;left:0;opacity:.5;position:absolute;top:0;width:0}.maplibregl-cooperative-gesture-screen{-webkit-box-align:center;-ms-flex-align:center;align-items:center;background:rgba(0,0,0,.4);color:#fff;display:-webkit-box;display:-ms-flexbox;display:flex;font-size:1.4em;inset:0;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;line-height:1.2;opacity:0;padding:1rem;pointer-events:none;position:absolute;-webkit-transition:opacity 1s ease 1s;transition:opacity 1s ease 1s;z-index:99999}.maplibregl-cooperative-gesture-screen.maplibregl-show{opacity:1;-webkit-transition:opacity .05s;transition:opacity .05s}.maplibregl-cooperative-gesture-screen .maplibregl-mobile-message{display:none}@media (hover:none),(width <= 480px){.maplibregl-cooperative-gesture-screen .maplibregl-desktop-message{display:none}.maplibregl-cooperative-gesture-screen .maplibregl-mobile-message{display:block}}.maplibregl-pseudo-fullscreen{height:100%!important;left:0!important;position:fixed!important;top:0!important;width:100%!important;z-index:99999}`),window.maplibregl=rA();var dz=0,pz=(I5=(0,sa.b2)(),I5(R5=function(e){(0,Me.Z)(r,e);var i=cz(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u1&&arguments[1]!==void 0?arguments[1]:{x:0,y:0,z:0},u=this.lngLatToMercator(t,0),c=u.x,m=u.y;return[c-a.x,m-a.y]}},{key:"lngLatToMercator",value:function(t,a){var u=window.maplibregl.MercatorCoordinate.fromLngLat(t,a),c=u.x,m=c===void 0?0:c,E=u.y,H=E===void 0?0:E,re=u.z,xe=re===void 0?0:re;return{x:m,y:H,z:xe}}},{key:"getModelMatrix",value:function(t,a,u){var c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:[1,1,1],m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{x:0,y:0,z:0},E=window.maplibregl.MercatorCoordinate.fromLngLat(t,a),H=E.meterInMercatorCoordinateUnits(),re=Mf();return wd(re,re,Zd(E.x-m.x,E.y-m.y,E.z||0-m.z)),Md(re,re,Zd(H*c[0],-H*c[1],H*c[2])),Bd(re,re,u[0]),Qd(re,re,u[1]),Jd(re,re,u[2]),re}},{key:"init",value:function(){var n=(0,Li.Z)(Ur().mark(function a(){var u=this,c,m,E,H,re,xe,ke,rt,vt,It,er;return Ur().wrap(function(Or){for(;;)switch(Or.prev=Or.next){case 0:c=this.config,m=c.id,E=m===void 0?"map":m,H=c.attributionControl,re=H===void 0?!1:H,xe=c.style,ke=xe===void 0?"light":xe,rt=c.rotation,vt=rt===void 0?0:rt,It=c.mapInstance,er=(0,X0.Z)(c,lz),this.viewport=new C5,!It&&!window.maplibregl&&console.error(this.configService.getSceneWarninfo("SDK")),It?(this.map=It,this.$mapContainer=this.map.getContainer()):(this.$mapContainer=this.creatMapContainer(E),this.map=new window.maplibregl.Map((0,Se.Z)({container:this.$mapContainer,style:this.getMapStyleValue(ke),attributionControl:re,bearing:vt},er))),this.map.on("load",function(){u.handleCameraChanged()}),this.map.on("move",this.handleCameraChanged),this.handleCameraChanged();case 7:case"end":return Or.stop()}},a,this)}));function t(){return n.apply(this,arguments)}return t}()},{key:"destroy",value:function(){var t;(t=this.$mapContainer)===null||t===void 0||(t=t.parentNode)===null||t===void 0||t.removeChild(this.$mapContainer),this.eventEmitter.removeAllListeners(),this.map&&(this.map.remove(),this.$mapContainer=null)}},{key:"emit",value:function(t){for(var a,u=arguments.length,c=new Array(u>1?u-1:0),m=1;m1?u-1:0),m=1;m3&&arguments[3]!==void 0?arguments[3]:[1,1,1],m=this.viewport.projectFlat(t),E=Mf();return wd(E,E,Zd(m[0],m[1],a)),Md(E,E,Zd(c[0],c[1],c[2])),Bd(E,E,u[0]),Qd(E,E,u[1]),Jd(E,E,u[2]),E}},{key:"getCustomCoordCenter",value:function(){throw new Error("Method not implemented.")}},{key:"exportMap",value:function(t){var a=this.getMapCanvasContainer(),u=t==="jpg"?a==null?void 0:a.toDataURL("image/jpeg"):a==null?void 0:a.toDataURL("image/png");return u}},{key:"rotateY",value:function(){throw new Error("Method not implemented.")}},{key:"hideLogo",value:function(){var t=this.map.getContainer();t&&Js(t,"tmap-contianer--hide-logo")}}]),r}(Ng);function Mz(e){var i=Pz();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function Pz(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var Iz=function(e){(0,Me.Z)(r,e);var i=Mz(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getServiceConstructor",value:function(){return Tz}}]),r}(Vv),Rz=function(i){var r=i.tk;return new Promise(function(n,t){var a=document.createElement("script");a.type="text/javascript",a.src="https://api.tianditu.gov.cn/api?v=4.0&tk=".concat(r),a.onload=function(){console.log("TianDiTu API script loaded."),n(!0)},a.onerror=function(){console.error("Failed to load TianDiTu API script."),n(!1)},document.head.appendChild(a)})},O$=function(){},Oz=["id","mapInstance","center","token","version","minZoom","maxZoom","logoVisible","zoom"];function Lz(e){var i=Dz();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function Dz(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var kz=0,q1={camerachange:["move"]},Fz=function(e){(0,Me.Z)(r,e);var i=Lz(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u0&&arguments[0]!==void 0?arguments[0]:0,a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;this.map.panBy([t,a])}},{key:"fitBounds",value:function(t,a){var u=(0,gi.Z)(t,2),c=u[0],m=u[1];this.map.setViewport([new window.T.LngLat(c[0],c[1]),new window.T.LngLat(m[0],m[1])])}},{key:"setMaxZoom",value:function(t){this.map.setMaxZoom(t)}},{key:"setMinZoom",value:function(t){this.map.setMinZoom(t)}},{key:"setMapStatus",value:function(t){t.doubleClickZoom===!0&&this.map.enableDoubleClickZoom(),t.doubleClickZoom===!1&&this.map.disableDoubleClickZoom(),t.dragEnable===!1&&this.map.disableDrag(),t.dragEnable===!0&&this.map.enableDrag(),t.keyboardEnable===!1&&this.map.disableKeyboard(),t.keyboardEnable===!0&&this.map.enableKeyboard(),t.zoomEnable===!1&&this.map.disableScrollWheelZoom(),t.zoomEnable===!0&&this.map.enableScrollWheelZoom()}},{key:"getModelMatrix",value:function(t,a,u,c,m){throw new Error("Method not implemented.")}},{key:"pixelToLngLat",value:function(t){var a=(0,gi.Z)(t,2),u=a[0],c=a[1],m=this.map.layerPointToLngLat({x:u,y:c});return{lng:m.lng,lat:m.lat}}},{key:"lngLatToPixel",value:function(t){var a=(0,gi.Z)(t,2),u=a[0],c=a[1],m=this.map.lngLatToLayerPoint({lng:u,lat:c});return{x:m.x,y:m.y}}},{key:"containerToLngLat",value:function(t){var a=(0,gi.Z)(t,2),u=a[0],c=a[1],m=this.map.containerPointToLngLat({x:u,y:c});return{lng:m.lng,lat:m.lat}}},{key:"lngLatToContainer",value:function(t){var a=(0,gi.Z)(t,2),u=a[0],c=a[1],m=this.map.lngLatToContainerPoint({lat:c,lng:u});return{x:m.x,y:m.y}}},{key:"lngLatToCoord",value:function(t){var a=(0,gi.Z)(t,2),u=a[0],c=a[1],m=this.lngLatToPixel([u,c]);return[m.x,m.y]}},{key:"lngLatToCoords",value:function(t){var a=this;return t.map(function(u){return Array.isArray(u[0])?a.lngLatToCoords(u):a.lngLatToCoord(u)})}},{key:"getBounds",value:function(){var t=this.map.getBounds(),a=t.getSouthWest(),u=t.getNorthEast();return[[a.lng,a.lat],[u.lng,u.lat]]}},{key:"lngLatToMercator",value:function(t,a){var u=Ug.fromLngLat(t,a),c=u.x,m=c===void 0?0:c,E=u.y,H=E===void 0?0:E,re=u.z,xe=re===void 0?0:re;return{x:m,y:H,z:xe}}},{key:"getCustomCoordCenter",value:function(){throw new Error("Method not implemented.")}},{key:"creatMapContainer",value:function(t){var a=t;typeof t=="string"&&(a=document.getElementById(t));var u=document.createElement("div");return u.style.cssText+=` + position: absolute; + top: 0; + height: 100%; + width: 100%; + `,u.id="l7_tdt_div"+kz++,a.appendChild(u),u}}]),r}(Ng);function Bz(e){var i=Nz();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function Nz(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var zz=function(e){(0,Me.Z)(r,e);var i=Bz(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getServiceConstructor",value:function(){return Fz}}]),r}(Vv);if(!window)throw Error("Google Map JSAPI can only be used in Browser.");var Xv=function(e){return e.notload="notload",e.loading="loading",e.loaded="loaded",e.failed="failed",e}(Xv||{}),Vw={key:""},Hg={GMap:Xv.notload},$w=[],L5=function(i){if(typeof i=="function"){if(Hg.GMap===Xv.loaded){i(window.google.maps.Map);return}$w.push(i)}},Zz=function(i){return new Promise(function(r,n){if(Hg.GMap===Xv.failed)n("");else if(Hg.GMap===Xv.notload){var t=i.key;if(!t){n("\u8BF7\u586B\u5199key");return}Vw.key=t,Hg.GMap=Xv.loading,window.initMap=function(c){if(delete window.initMap,c)Hg.GMap=Xv.failed,n(c);else for(Hg.GMap=Xv.loaded;$w.length;)$w.splice(0,1)[0](window.google.maps.Map)};var a=document.createElement("script");a.type="text/javascript",a.async=!1,a.src="https://maps.googleapis.com/maps/api/js?key=".concat(Vw.key,"&callback=initMap"),a.onerror=function(c){Hg.GMap=Xv.failed,n(c)};var u=document.body||document.head;u.appendChild(a),L5(r)}else if(Hg.GMap===Xv.loaded){if(i.key&&i.key!==Vw.key){n("\u591A\u4E2A\u4E0D\u4E00\u81F4\u7684 key");return}L5(r)}})},Uz=function(){delete window.google,Hg={GMap:Xv.notload}},jz={load:Zz,reset:Uz},Vz=["id","mapInstance","center","token","minZoom","maxZoom","rotation","pitch","mapSize","logoVisible"];function $z(e){var i=Hz();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function Hz(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}function Gz(e,i){var r=typeof my!="undefined"&&!!my&&typeof my.showToast=="function"&&my.isFRM!==!0,n=typeof wx!="undefined"&&wx!==null&&(typeof wx.request!="undefined"||typeof wx.miniProgram!="undefined");if(!(r||n)&&(i||(i=document),!!i)){var t=i.head||i.getElementsByTagName("head")[0];if(!t){t=i.createElement("head");var a=i.body||i.getElementsByTagName("body")[0];a?a.parentNode.insertBefore(t,a):i.documentElement.appendChild(t)}var u=i.createElement("style");return u.type="text/css",u.styleSheet?u.styleSheet.cssText=e:u.appendChild(i.createTextNode(e)),t.appendChild(u),u}}Gz(`img[src*='//mapapi.qq.com/web/jsapi/logo/logo_def.png'],.logo-text { + display: none !important; +} +`);var Wz="AIzaSyDBDCfl4pvuDtaazdCog3LmhA7CQLhmcRE",Q1={mapmove:"center_changed",camerachange:["drag","pan","rotate","tilt","zoom_changed"],zoomchange:"zoom_changed",dragging:"drag"},Xz=function(e){(0,Me.Z)(r,e);var i=$z(r);function r(){var n;(0,We.Z)(this,r);for(var t=arguments.length,a=new Array(t),u=0;u3&&arguments[3]!==void 0?arguments[3]:[1,1,1],m=this.viewport.projectFlat(t),E=Mf();return wd(E,E,Zd(m[0],m[1],a)),Md(E,E,Zd(c[0],c[1],c[2])),Bd(E,E,u[0]),Qd(E,E,u[1]),Jd(E,E,u[2]),E}},{key:"getCustomCoordCenter",value:function(){throw new Error("Method not implemented.")}},{key:"exportMap",value:function(t){var a=this.getMapCanvasContainer(),u=t==="jpg"?a==null?void 0:a.toDataURL("image/jpeg"):a==null?void 0:a.toDataURL("image/png");return u}},{key:"rotateY",value:function(){throw new Error("Method not implemented.")}},{key:"hideLogo",value:function(){var t=this.map.getDiv();t&&Js(t,"tmap-contianer--hide-logo")}}]),r}(Ng);function Yz(e){var i=Kz();return function(){var n=(0,Qe.Z)(e),t;if(i){var a=(0,Qe.Z)(this).constructor;t=Reflect.construct(n,arguments,a)}else t=n.apply(this,arguments);return(0,st.Z)(this,t)}}function Kz(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}var qz=function(e){(0,Me.Z)(r,e);var i=Yz(r);function r(){return(0,We.Z)(this,r),i.apply(this,arguments)}return(0,ot.Z)(r,[{key:"getServiceConstructor",value:function(){return Xz}}]),r}(Vv),Qz=A(45409),Jz=A.n(Qz),eZ=function(){function e(i,r){(0,We.Z)(this,e);var n=r.buffer,t=r.offset,a=r.stride,u=r.normalized,c=r.size,m=r.divisor;this.buffer=n,this.attribute={buffer:n.get(),offset:t||0,stride:a||0,normalized:u||!1,divisor:m||0},c&&(this.attribute.size=c)}return(0,ot.Z)(e,[{key:"get",value:function(){return this.attribute}},{key:"updateBuffer",value:function(r){this.buffer.subData(r)}},{key:"destroy",value:function(){this.buffer.destroy()}}]),e}(),Gg,nA,wy,kv,iA,Ey,oA,l2,hg,a1,Xm,dg,pg,c2,tZ=(Gg={},(0,St.Z)(Gg,Er.POINTS,"points"),(0,St.Z)(Gg,Er.LINES,"lines"),(0,St.Z)(Gg,Er.LINE_LOOP,"line loop"),(0,St.Z)(Gg,Er.LINE_STRIP,"line strip"),(0,St.Z)(Gg,Er.TRIANGLES,"triangles"),(0,St.Z)(Gg,Er.TRIANGLE_FAN,"triangle fan"),(0,St.Z)(Gg,Er.TRIANGLE_STRIP,"triangle strip"),Gg),D5=(nA={},(0,St.Z)(nA,Er.STATIC_DRAW,"static"),(0,St.Z)(nA,Er.DYNAMIC_DRAW,"dynamic"),(0,St.Z)(nA,Er.STREAM_DRAW,"stream"),nA),Hw=(wy={},(0,St.Z)(wy,Er.BYTE,"int8"),(0,St.Z)(wy,Er.INT,"int32"),(0,St.Z)(wy,Er.UNSIGNED_BYTE,"uint8"),(0,St.Z)(wy,Er.UNSIGNED_SHORT,"uint16"),(0,St.Z)(wy,Er.UNSIGNED_INT,"uint32"),(0,St.Z)(wy,Er.FLOAT,"float"),wy),rZ=(kv={},(0,St.Z)(kv,Er.ALPHA,"alpha"),(0,St.Z)(kv,Er.LUMINANCE,"luminance"),(0,St.Z)(kv,Er.LUMINANCE_ALPHA,"luminance alpha"),(0,St.Z)(kv,Er.RGB,"rgb"),(0,St.Z)(kv,Er.RGBA,"rgba"),(0,St.Z)(kv,Er.RGBA4,"rgba4"),(0,St.Z)(kv,Er.RGB5_A1,"rgb5 a1"),(0,St.Z)(kv,Er.RGB565,"rgb565"),(0,St.Z)(kv,Er.DEPTH_COMPONENT,"depth"),(0,St.Z)(kv,Er.DEPTH_STENCIL,"depth stencil"),kv),nZ=(iA={},(0,St.Z)(iA,Er.DONT_CARE,"dont care"),(0,St.Z)(iA,Er.NICEST,"nice"),(0,St.Z)(iA,Er.FASTEST,"fast"),iA),k5=(Ey={},(0,St.Z)(Ey,Er.NEAREST,"nearest"),(0,St.Z)(Ey,Er.LINEAR,"linear"),(0,St.Z)(Ey,Er.LINEAR_MIPMAP_LINEAR,"mipmap"),(0,St.Z)(Ey,Er.NEAREST_MIPMAP_LINEAR,"nearest mipmap linear"),(0,St.Z)(Ey,Er.LINEAR_MIPMAP_NEAREST,"linear mipmap nearest"),(0,St.Z)(Ey,Er.NEAREST_MIPMAP_NEAREST,"nearest mipmap nearest"),Ey),F5=(oA={},(0,St.Z)(oA,Er.REPEAT,"repeat"),(0,St.Z)(oA,Er.CLAMP_TO_EDGE,"clamp"),(0,St.Z)(oA,Er.MIRRORED_REPEAT,"mirror"),oA),iZ=(l2={},(0,St.Z)(l2,Er.NONE,"none"),(0,St.Z)(l2,Er.BROWSER_DEFAULT_WEBGL,"browser"),l2),oZ=(hg={},(0,St.Z)(hg,Er.NEVER,"never"),(0,St.Z)(hg,Er.ALWAYS,"always"),(0,St.Z)(hg,Er.LESS,"less"),(0,St.Z)(hg,Er.LEQUAL,"lequal"),(0,St.Z)(hg,Er.GREATER,"greater"),(0,St.Z)(hg,Er.GEQUAL,"gequal"),(0,St.Z)(hg,Er.EQUAL,"equal"),(0,St.Z)(hg,Er.NOTEQUAL,"notequal"),hg),B5=(a1={},(0,St.Z)(a1,Er.FUNC_ADD,"add"),(0,St.Z)(a1,Er.MIN_EXT,"min"),(0,St.Z)(a1,Er.MAX_EXT,"max"),(0,St.Z)(a1,Er.FUNC_SUBTRACT,"subtract"),(0,St.Z)(a1,Er.FUNC_REVERSE_SUBTRACT,"reverse subtract"),a1),f2=(Xm={},(0,St.Z)(Xm,Er.ZERO,"zero"),(0,St.Z)(Xm,Er.ONE,"one"),(0,St.Z)(Xm,Er.SRC_COLOR,"src color"),(0,St.Z)(Xm,Er.ONE_MINUS_SRC_COLOR,"one minus src color"),(0,St.Z)(Xm,Er.SRC_ALPHA,"src alpha"),(0,St.Z)(Xm,Er.ONE_MINUS_SRC_ALPHA,"one minus src alpha"),(0,St.Z)(Xm,Er.DST_COLOR,"dst color"),(0,St.Z)(Xm,Er.ONE_MINUS_DST_COLOR,"one minus dst color"),(0,St.Z)(Xm,Er.DST_ALPHA,"dst alpha"),(0,St.Z)(Xm,Er.ONE_MINUS_DST_ALPHA,"one minus dst alpha"),(0,St.Z)(Xm,Er.CONSTANT_COLOR,"constant color"),(0,St.Z)(Xm,Er.ONE_MINUS_CONSTANT_COLOR,"one minus constant color"),(0,St.Z)(Xm,Er.CONSTANT_ALPHA,"constant alpha"),(0,St.Z)(Xm,Er.ONE_MINUS_CONSTANT_ALPHA,"one minus constant alpha"),(0,St.Z)(Xm,Er.SRC_ALPHA_SATURATE,"src alpha saturate"),Xm),aZ=(dg={},(0,St.Z)(dg,Er.NEVER,"never"),(0,St.Z)(dg,Er.ALWAYS,"always"),(0,St.Z)(dg,Er.LESS,"less"),(0,St.Z)(dg,Er.LEQUAL,"lequal"),(0,St.Z)(dg,Er.GREATER,"greater"),(0,St.Z)(dg,Er.GEQUAL,"gequal"),(0,St.Z)(dg,Er.EQUAL,"equal"),(0,St.Z)(dg,Er.NOTEQUAL,"notequal"),dg),J1=(pg={},(0,St.Z)(pg,Er.ZERO,"zero"),(0,St.Z)(pg,Er.KEEP,"keep"),(0,St.Z)(pg,Er.REPLACE,"replace"),(0,St.Z)(pg,Er.INVERT,"invert"),(0,St.Z)(pg,Er.INCR,"increment"),(0,St.Z)(pg,Er.DECR,"decrement"),(0,St.Z)(pg,Er.INCR_WRAP,"increment wrap"),(0,St.Z)(pg,Er.DECR_WRAP,"decrement wrap"),pg),sZ=(c2={},(0,St.Z)(c2,Er.FRONT,"front"),(0,St.Z)(c2,Er.BACK,"back"),c2),uZ=function(){function e(i,r){(0,We.Z)(this,e),(0,St.Z)(this,"isDestroyed",!1);var n=r.data,t=r.usage,a=r.type;this.buffer=i.buffer({data:n,usage:D5[t||Er.STATIC_DRAW],type:Hw[a||Er.UNSIGNED_BYTE]})}return(0,ot.Z)(e,[{key:"get",value:function(){return this.buffer}},{key:"destroy",value:function(){this.isDestroyed||this.buffer.destroy(),this.isDestroyed=!0}},{key:"subData",value:function(r){var n=r.data,t=r.offset;this.buffer.subdata(n,t)}}]),e}(),lZ=function(){function e(i,r){(0,We.Z)(this,e);var n=r.data,t=r.usage,a=r.type,u=r.count;this.elements=i.elements({data:n,usage:D5[t||Er.STATIC_DRAW],type:Hw[a||Er.UNSIGNED_BYTE],count:u})}return(0,ot.Z)(e,[{key:"get",value:function(){return this.elements}},{key:"subData",value:function(r){var n=r.data;this.elements.subdata(n)}},{key:"destroy",value:function(){}}]),e}(),cZ=function(){function e(i,r){(0,We.Z)(this,e);var n=r.width,t=r.height,a=r.color,u=r.colors,c={width:n,height:t};Array.isArray(u)&&(c.colors=u.map(function(m){return m.get()})),a&&typeof a!="boolean"&&(c.color=a.get()),this.framebuffer=i.framebuffer(c)}return(0,ot.Z)(e,[{key:"get",value:function(){return this.framebuffer}},{key:"destroy",value:function(){this.framebuffer.destroy()}},{key:"resize",value:function(r){var n=r.width,t=r.height;this.framebuffer.resize(n,t)}}]),e}(),fZ=function(e){return e==null},Fv=fZ,hZ={}.toString,dZ=function(e,i){return hZ.call(e)==="[object "+i+"]"},pZ=dZ,mZ=function(e){return pZ(e,"Number")},e_=mZ,vZ=function(e,i,r){return er?r:e},gZ=vZ,kc=A(32290),yZ=A(37271),N5=yZ,Ri;(function(e){e[e.DEPTH_BUFFER_BIT=256]="DEPTH_BUFFER_BIT",e[e.STENCIL_BUFFER_BIT=1024]="STENCIL_BUFFER_BIT",e[e.COLOR_BUFFER_BIT=16384]="COLOR_BUFFER_BIT",e[e.POINTS=0]="POINTS",e[e.LINES=1]="LINES",e[e.LINE_LOOP=2]="LINE_LOOP",e[e.LINE_STRIP=3]="LINE_STRIP",e[e.TRIANGLES=4]="TRIANGLES",e[e.TRIANGLE_STRIP=5]="TRIANGLE_STRIP",e[e.TRIANGLE_FAN=6]="TRIANGLE_FAN",e[e.ZERO=0]="ZERO",e[e.ONE=1]="ONE",e[e.SRC_COLOR=768]="SRC_COLOR",e[e.ONE_MINUS_SRC_COLOR=769]="ONE_MINUS_SRC_COLOR",e[e.SRC_ALPHA=770]="SRC_ALPHA",e[e.ONE_MINUS_SRC_ALPHA=771]="ONE_MINUS_SRC_ALPHA",e[e.DST_ALPHA=772]="DST_ALPHA",e[e.ONE_MINUS_DST_ALPHA=773]="ONE_MINUS_DST_ALPHA",e[e.DST_COLOR=774]="DST_COLOR",e[e.ONE_MINUS_DST_COLOR=775]="ONE_MINUS_DST_COLOR",e[e.SRC_ALPHA_SATURATE=776]="SRC_ALPHA_SATURATE",e[e.CONSTANT_COLOR=32769]="CONSTANT_COLOR",e[e.ONE_MINUS_CONSTANT_COLOR=32770]="ONE_MINUS_CONSTANT_COLOR",e[e.CONSTANT_ALPHA=32771]="CONSTANT_ALPHA",e[e.ONE_MINUS_CONSTANT_ALPHA=32772]="ONE_MINUS_CONSTANT_ALPHA",e[e.FUNC_ADD=32774]="FUNC_ADD",e[e.FUNC_SUBTRACT=32778]="FUNC_SUBTRACT",e[e.FUNC_REVERSE_SUBTRACT=32779]="FUNC_REVERSE_SUBTRACT",e[e.BLEND_EQUATION=32777]="BLEND_EQUATION",e[e.BLEND_EQUATION_RGB=32777]="BLEND_EQUATION_RGB",e[e.BLEND_EQUATION_ALPHA=34877]="BLEND_EQUATION_ALPHA",e[e.BLEND_DST_RGB=32968]="BLEND_DST_RGB",e[e.BLEND_SRC_RGB=32969]="BLEND_SRC_RGB",e[e.BLEND_DST_ALPHA=32970]="BLEND_DST_ALPHA",e[e.BLEND_SRC_ALPHA=32971]="BLEND_SRC_ALPHA",e[e.BLEND_COLOR=32773]="BLEND_COLOR",e[e.ARRAY_BUFFER_BINDING=34964]="ARRAY_BUFFER_BINDING",e[e.ELEMENT_ARRAY_BUFFER_BINDING=34965]="ELEMENT_ARRAY_BUFFER_BINDING",e[e.LINE_WIDTH=2849]="LINE_WIDTH",e[e.ALIASED_POINT_SIZE_RANGE=33901]="ALIASED_POINT_SIZE_RANGE",e[e.ALIASED_LINE_WIDTH_RANGE=33902]="ALIASED_LINE_WIDTH_RANGE",e[e.CULL_FACE_MODE=2885]="CULL_FACE_MODE",e[e.FRONT_FACE=2886]="FRONT_FACE",e[e.DEPTH_RANGE=2928]="DEPTH_RANGE",e[e.DEPTH_WRITEMASK=2930]="DEPTH_WRITEMASK",e[e.DEPTH_CLEAR_VALUE=2931]="DEPTH_CLEAR_VALUE",e[e.DEPTH_FUNC=2932]="DEPTH_FUNC",e[e.STENCIL_CLEAR_VALUE=2961]="STENCIL_CLEAR_VALUE",e[e.STENCIL_FUNC=2962]="STENCIL_FUNC",e[e.STENCIL_FAIL=2964]="STENCIL_FAIL",e[e.STENCIL_PASS_DEPTH_FAIL=2965]="STENCIL_PASS_DEPTH_FAIL",e[e.STENCIL_PASS_DEPTH_PASS=2966]="STENCIL_PASS_DEPTH_PASS",e[e.STENCIL_REF=2967]="STENCIL_REF",e[e.STENCIL_VALUE_MASK=2963]="STENCIL_VALUE_MASK",e[e.STENCIL_WRITEMASK=2968]="STENCIL_WRITEMASK",e[e.STENCIL_BACK_FUNC=34816]="STENCIL_BACK_FUNC",e[e.STENCIL_BACK_FAIL=34817]="STENCIL_BACK_FAIL",e[e.STENCIL_BACK_PASS_DEPTH_FAIL=34818]="STENCIL_BACK_PASS_DEPTH_FAIL",e[e.STENCIL_BACK_PASS_DEPTH_PASS=34819]="STENCIL_BACK_PASS_DEPTH_PASS",e[e.STENCIL_BACK_REF=36003]="STENCIL_BACK_REF",e[e.STENCIL_BACK_VALUE_MASK=36004]="STENCIL_BACK_VALUE_MASK",e[e.STENCIL_BACK_WRITEMASK=36005]="STENCIL_BACK_WRITEMASK",e[e.VIEWPORT=2978]="VIEWPORT",e[e.SCISSOR_BOX=3088]="SCISSOR_BOX",e[e.COLOR_CLEAR_VALUE=3106]="COLOR_CLEAR_VALUE",e[e.COLOR_WRITEMASK=3107]="COLOR_WRITEMASK",e[e.UNPACK_ALIGNMENT=3317]="UNPACK_ALIGNMENT",e[e.PACK_ALIGNMENT=3333]="PACK_ALIGNMENT",e[e.MAX_TEXTURE_SIZE=3379]="MAX_TEXTURE_SIZE",e[e.MAX_VIEWPORT_DIMS=3386]="MAX_VIEWPORT_DIMS",e[e.SUBPIXEL_BITS=3408]="SUBPIXEL_BITS",e[e.RED_BITS=3410]="RED_BITS",e[e.GREEN_BITS=3411]="GREEN_BITS",e[e.BLUE_BITS=3412]="BLUE_BITS",e[e.ALPHA_BITS=3413]="ALPHA_BITS",e[e.DEPTH_BITS=3414]="DEPTH_BITS",e[e.STENCIL_BITS=3415]="STENCIL_BITS",e[e.POLYGON_OFFSET_UNITS=10752]="POLYGON_OFFSET_UNITS",e[e.POLYGON_OFFSET_FACTOR=32824]="POLYGON_OFFSET_FACTOR",e[e.TEXTURE_BINDING_2D=32873]="TEXTURE_BINDING_2D",e[e.SAMPLE_BUFFERS=32936]="SAMPLE_BUFFERS",e[e.SAMPLES=32937]="SAMPLES",e[e.SAMPLE_COVERAGE_VALUE=32938]="SAMPLE_COVERAGE_VALUE",e[e.SAMPLE_COVERAGE_INVERT=32939]="SAMPLE_COVERAGE_INVERT",e[e.COMPRESSED_TEXTURE_FORMATS=34467]="COMPRESSED_TEXTURE_FORMATS",e[e.VENDOR=7936]="VENDOR",e[e.RENDERER=7937]="RENDERER",e[e.VERSION=7938]="VERSION",e[e.IMPLEMENTATION_COLOR_READ_TYPE=35738]="IMPLEMENTATION_COLOR_READ_TYPE",e[e.IMPLEMENTATION_COLOR_READ_FORMAT=35739]="IMPLEMENTATION_COLOR_READ_FORMAT",e[e.BROWSER_DEFAULT_WEBGL=37444]="BROWSER_DEFAULT_WEBGL",e[e.STATIC_DRAW=35044]="STATIC_DRAW",e[e.STREAM_DRAW=35040]="STREAM_DRAW",e[e.DYNAMIC_DRAW=35048]="DYNAMIC_DRAW",e[e.ARRAY_BUFFER=34962]="ARRAY_BUFFER",e[e.ELEMENT_ARRAY_BUFFER=34963]="ELEMENT_ARRAY_BUFFER",e[e.BUFFER_SIZE=34660]="BUFFER_SIZE",e[e.BUFFER_USAGE=34661]="BUFFER_USAGE",e[e.CURRENT_VERTEX_ATTRIB=34342]="CURRENT_VERTEX_ATTRIB",e[e.VERTEX_ATTRIB_ARRAY_ENABLED=34338]="VERTEX_ATTRIB_ARRAY_ENABLED",e[e.VERTEX_ATTRIB_ARRAY_SIZE=34339]="VERTEX_ATTRIB_ARRAY_SIZE",e[e.VERTEX_ATTRIB_ARRAY_STRIDE=34340]="VERTEX_ATTRIB_ARRAY_STRIDE",e[e.VERTEX_ATTRIB_ARRAY_TYPE=34341]="VERTEX_ATTRIB_ARRAY_TYPE",e[e.VERTEX_ATTRIB_ARRAY_NORMALIZED=34922]="VERTEX_ATTRIB_ARRAY_NORMALIZED",e[e.VERTEX_ATTRIB_ARRAY_POINTER=34373]="VERTEX_ATTRIB_ARRAY_POINTER",e[e.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING=34975]="VERTEX_ATTRIB_ARRAY_BUFFER_BINDING",e[e.CULL_FACE=2884]="CULL_FACE",e[e.FRONT=1028]="FRONT",e[e.BACK=1029]="BACK",e[e.FRONT_AND_BACK=1032]="FRONT_AND_BACK",e[e.BLEND=3042]="BLEND",e[e.DEPTH_TEST=2929]="DEPTH_TEST",e[e.DITHER=3024]="DITHER",e[e.POLYGON_OFFSET_FILL=32823]="POLYGON_OFFSET_FILL",e[e.SAMPLE_ALPHA_TO_COVERAGE=32926]="SAMPLE_ALPHA_TO_COVERAGE",e[e.SAMPLE_COVERAGE=32928]="SAMPLE_COVERAGE",e[e.SCISSOR_TEST=3089]="SCISSOR_TEST",e[e.STENCIL_TEST=2960]="STENCIL_TEST",e[e.NO_ERROR=0]="NO_ERROR",e[e.INVALID_ENUM=1280]="INVALID_ENUM",e[e.INVALID_VALUE=1281]="INVALID_VALUE",e[e.INVALID_OPERATION=1282]="INVALID_OPERATION",e[e.OUT_OF_MEMORY=1285]="OUT_OF_MEMORY",e[e.CONTEXT_LOST_WEBGL=37442]="CONTEXT_LOST_WEBGL",e[e.CW=2304]="CW",e[e.CCW=2305]="CCW",e[e.DONT_CARE=4352]="DONT_CARE",e[e.FASTEST=4353]="FASTEST",e[e.NICEST=4354]="NICEST",e[e.GENERATE_MIPMAP_HINT=33170]="GENERATE_MIPMAP_HINT",e[e.BYTE=5120]="BYTE",e[e.UNSIGNED_BYTE=5121]="UNSIGNED_BYTE",e[e.SHORT=5122]="SHORT",e[e.UNSIGNED_SHORT=5123]="UNSIGNED_SHORT",e[e.INT=5124]="INT",e[e.UNSIGNED_INT=5125]="UNSIGNED_INT",e[e.FLOAT=5126]="FLOAT",e[e.DOUBLE=5130]="DOUBLE",e[e.DEPTH_COMPONENT=6402]="DEPTH_COMPONENT",e[e.ALPHA=6406]="ALPHA",e[e.RGB=6407]="RGB",e[e.RGBA=6408]="RGBA",e[e.LUMINANCE=6409]="LUMINANCE",e[e.LUMINANCE_ALPHA=6410]="LUMINANCE_ALPHA",e[e.UNSIGNED_SHORT_4_4_4_4=32819]="UNSIGNED_SHORT_4_4_4_4",e[e.UNSIGNED_SHORT_5_5_5_1=32820]="UNSIGNED_SHORT_5_5_5_1",e[e.UNSIGNED_SHORT_5_6_5=33635]="UNSIGNED_SHORT_5_6_5",e[e.FRAGMENT_SHADER=35632]="FRAGMENT_SHADER",e[e.VERTEX_SHADER=35633]="VERTEX_SHADER",e[e.COMPILE_STATUS=35713]="COMPILE_STATUS",e[e.DELETE_STATUS=35712]="DELETE_STATUS",e[e.LINK_STATUS=35714]="LINK_STATUS",e[e.VALIDATE_STATUS=35715]="VALIDATE_STATUS",e[e.ATTACHED_SHADERS=35717]="ATTACHED_SHADERS",e[e.ACTIVE_ATTRIBUTES=35721]="ACTIVE_ATTRIBUTES",e[e.ACTIVE_UNIFORMS=35718]="ACTIVE_UNIFORMS",e[e.MAX_VERTEX_ATTRIBS=34921]="MAX_VERTEX_ATTRIBS",e[e.MAX_VERTEX_UNIFORM_VECTORS=36347]="MAX_VERTEX_UNIFORM_VECTORS",e[e.MAX_VARYING_VECTORS=36348]="MAX_VARYING_VECTORS",e[e.MAX_COMBINED_TEXTURE_IMAGE_UNITS=35661]="MAX_COMBINED_TEXTURE_IMAGE_UNITS",e[e.MAX_VERTEX_TEXTURE_IMAGE_UNITS=35660]="MAX_VERTEX_TEXTURE_IMAGE_UNITS",e[e.MAX_TEXTURE_IMAGE_UNITS=34930]="MAX_TEXTURE_IMAGE_UNITS",e[e.MAX_FRAGMENT_UNIFORM_VECTORS=36349]="MAX_FRAGMENT_UNIFORM_VECTORS",e[e.SHADER_TYPE=35663]="SHADER_TYPE",e[e.SHADING_LANGUAGE_VERSION=35724]="SHADING_LANGUAGE_VERSION",e[e.CURRENT_PROGRAM=35725]="CURRENT_PROGRAM",e[e.NEVER=512]="NEVER",e[e.ALWAYS=519]="ALWAYS",e[e.LESS=513]="LESS",e[e.EQUAL=514]="EQUAL",e[e.LEQUAL=515]="LEQUAL",e[e.GREATER=516]="GREATER",e[e.GEQUAL=518]="GEQUAL",e[e.NOTEQUAL=517]="NOTEQUAL",e[e.KEEP=7680]="KEEP",e[e.REPLACE=7681]="REPLACE",e[e.INCR=7682]="INCR",e[e.DECR=7683]="DECR",e[e.INVERT=5386]="INVERT",e[e.INCR_WRAP=34055]="INCR_WRAP",e[e.DECR_WRAP=34056]="DECR_WRAP",e[e.NEAREST=9728]="NEAREST",e[e.LINEAR=9729]="LINEAR",e[e.NEAREST_MIPMAP_NEAREST=9984]="NEAREST_MIPMAP_NEAREST",e[e.LINEAR_MIPMAP_NEAREST=9985]="LINEAR_MIPMAP_NEAREST",e[e.NEAREST_MIPMAP_LINEAR=9986]="NEAREST_MIPMAP_LINEAR",e[e.LINEAR_MIPMAP_LINEAR=9987]="LINEAR_MIPMAP_LINEAR",e[e.TEXTURE_MAG_FILTER=10240]="TEXTURE_MAG_FILTER",e[e.TEXTURE_MIN_FILTER=10241]="TEXTURE_MIN_FILTER",e[e.TEXTURE_WRAP_S=10242]="TEXTURE_WRAP_S",e[e.TEXTURE_WRAP_T=10243]="TEXTURE_WRAP_T",e[e.TEXTURE_2D=3553]="TEXTURE_2D",e[e.TEXTURE=5890]="TEXTURE",e[e.TEXTURE_CUBE_MAP=34067]="TEXTURE_CUBE_MAP",e[e.TEXTURE_BINDING_CUBE_MAP=34068]="TEXTURE_BINDING_CUBE_MAP",e[e.TEXTURE_CUBE_MAP_POSITIVE_X=34069]="TEXTURE_CUBE_MAP_POSITIVE_X",e[e.TEXTURE_CUBE_MAP_NEGATIVE_X=34070]="TEXTURE_CUBE_MAP_NEGATIVE_X",e[e.TEXTURE_CUBE_MAP_POSITIVE_Y=34071]="TEXTURE_CUBE_MAP_POSITIVE_Y",e[e.TEXTURE_CUBE_MAP_NEGATIVE_Y=34072]="TEXTURE_CUBE_MAP_NEGATIVE_Y",e[e.TEXTURE_CUBE_MAP_POSITIVE_Z=34073]="TEXTURE_CUBE_MAP_POSITIVE_Z",e[e.TEXTURE_CUBE_MAP_NEGATIVE_Z=34074]="TEXTURE_CUBE_MAP_NEGATIVE_Z",e[e.MAX_CUBE_MAP_TEXTURE_SIZE=34076]="MAX_CUBE_MAP_TEXTURE_SIZE",e[e.TEXTURE0=33984]="TEXTURE0",e[e.ACTIVE_TEXTURE=34016]="ACTIVE_TEXTURE",e[e.REPEAT=10497]="REPEAT",e[e.CLAMP_TO_EDGE=33071]="CLAMP_TO_EDGE",e[e.MIRRORED_REPEAT=33648]="MIRRORED_REPEAT",e[e.TEXTURE_WIDTH=4096]="TEXTURE_WIDTH",e[e.TEXTURE_HEIGHT=4097]="TEXTURE_HEIGHT",e[e.FLOAT_VEC2=35664]="FLOAT_VEC2",e[e.FLOAT_VEC3=35665]="FLOAT_VEC3",e[e.FLOAT_VEC4=35666]="FLOAT_VEC4",e[e.INT_VEC2=35667]="INT_VEC2",e[e.INT_VEC3=35668]="INT_VEC3",e[e.INT_VEC4=35669]="INT_VEC4",e[e.BOOL=35670]="BOOL",e[e.BOOL_VEC2=35671]="BOOL_VEC2",e[e.BOOL_VEC3=35672]="BOOL_VEC3",e[e.BOOL_VEC4=35673]="BOOL_VEC4",e[e.FLOAT_MAT2=35674]="FLOAT_MAT2",e[e.FLOAT_MAT3=35675]="FLOAT_MAT3",e[e.FLOAT_MAT4=35676]="FLOAT_MAT4",e[e.SAMPLER_2D=35678]="SAMPLER_2D",e[e.SAMPLER_CUBE=35680]="SAMPLER_CUBE",e[e.LOW_FLOAT=36336]="LOW_FLOAT",e[e.MEDIUM_FLOAT=36337]="MEDIUM_FLOAT",e[e.HIGH_FLOAT=36338]="HIGH_FLOAT",e[e.LOW_INT=36339]="LOW_INT",e[e.MEDIUM_INT=36340]="MEDIUM_INT",e[e.HIGH_INT=36341]="HIGH_INT",e[e.FRAMEBUFFER=36160]="FRAMEBUFFER",e[e.RENDERBUFFER=36161]="RENDERBUFFER",e[e.RGBA4=32854]="RGBA4",e[e.RGB5_A1=32855]="RGB5_A1",e[e.RGB565=36194]="RGB565",e[e.DEPTH_COMPONENT16=33189]="DEPTH_COMPONENT16",e[e.STENCIL_INDEX=6401]="STENCIL_INDEX",e[e.STENCIL_INDEX8=36168]="STENCIL_INDEX8",e[e.DEPTH_STENCIL=34041]="DEPTH_STENCIL",e[e.RENDERBUFFER_WIDTH=36162]="RENDERBUFFER_WIDTH",e[e.RENDERBUFFER_HEIGHT=36163]="RENDERBUFFER_HEIGHT",e[e.RENDERBUFFER_INTERNAL_FORMAT=36164]="RENDERBUFFER_INTERNAL_FORMAT",e[e.RENDERBUFFER_RED_SIZE=36176]="RENDERBUFFER_RED_SIZE",e[e.RENDERBUFFER_GREEN_SIZE=36177]="RENDERBUFFER_GREEN_SIZE",e[e.RENDERBUFFER_BLUE_SIZE=36178]="RENDERBUFFER_BLUE_SIZE",e[e.RENDERBUFFER_ALPHA_SIZE=36179]="RENDERBUFFER_ALPHA_SIZE",e[e.RENDERBUFFER_DEPTH_SIZE=36180]="RENDERBUFFER_DEPTH_SIZE",e[e.RENDERBUFFER_STENCIL_SIZE=36181]="RENDERBUFFER_STENCIL_SIZE",e[e.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE=36048]="FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE",e[e.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME=36049]="FRAMEBUFFER_ATTACHMENT_OBJECT_NAME",e[e.FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL=36050]="FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL",e[e.FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE=36051]="FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE",e[e.COLOR_ATTACHMENT0=36064]="COLOR_ATTACHMENT0",e[e.DEPTH_ATTACHMENT=36096]="DEPTH_ATTACHMENT",e[e.STENCIL_ATTACHMENT=36128]="STENCIL_ATTACHMENT",e[e.DEPTH_STENCIL_ATTACHMENT=33306]="DEPTH_STENCIL_ATTACHMENT",e[e.NONE=0]="NONE",e[e.FRAMEBUFFER_COMPLETE=36053]="FRAMEBUFFER_COMPLETE",e[e.FRAMEBUFFER_INCOMPLETE_ATTACHMENT=36054]="FRAMEBUFFER_INCOMPLETE_ATTACHMENT",e[e.FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT=36055]="FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT",e[e.FRAMEBUFFER_INCOMPLETE_DIMENSIONS=36057]="FRAMEBUFFER_INCOMPLETE_DIMENSIONS",e[e.FRAMEBUFFER_UNSUPPORTED=36061]="FRAMEBUFFER_UNSUPPORTED",e[e.FRAMEBUFFER_BINDING=36006]="FRAMEBUFFER_BINDING",e[e.RENDERBUFFER_BINDING=36007]="RENDERBUFFER_BINDING",e[e.READ_FRAMEBUFFER=36008]="READ_FRAMEBUFFER",e[e.DRAW_FRAMEBUFFER=36009]="DRAW_FRAMEBUFFER",e[e.MAX_RENDERBUFFER_SIZE=34024]="MAX_RENDERBUFFER_SIZE",e[e.INVALID_FRAMEBUFFER_OPERATION=1286]="INVALID_FRAMEBUFFER_OPERATION",e[e.UNPACK_FLIP_Y_WEBGL=37440]="UNPACK_FLIP_Y_WEBGL",e[e.UNPACK_PREMULTIPLY_ALPHA_WEBGL=37441]="UNPACK_PREMULTIPLY_ALPHA_WEBGL",e[e.UNPACK_COLORSPACE_CONVERSION_WEBGL=37443]="UNPACK_COLORSPACE_CONVERSION_WEBGL",e[e.READ_BUFFER=3074]="READ_BUFFER",e[e.UNPACK_ROW_LENGTH=3314]="UNPACK_ROW_LENGTH",e[e.UNPACK_SKIP_ROWS=3315]="UNPACK_SKIP_ROWS",e[e.UNPACK_SKIP_PIXELS=3316]="UNPACK_SKIP_PIXELS",e[e.PACK_ROW_LENGTH=3330]="PACK_ROW_LENGTH",e[e.PACK_SKIP_ROWS=3331]="PACK_SKIP_ROWS",e[e.PACK_SKIP_PIXELS=3332]="PACK_SKIP_PIXELS",e[e.TEXTURE_BINDING_3D=32874]="TEXTURE_BINDING_3D",e[e.UNPACK_SKIP_IMAGES=32877]="UNPACK_SKIP_IMAGES",e[e.UNPACK_IMAGE_HEIGHT=32878]="UNPACK_IMAGE_HEIGHT",e[e.MAX_3D_TEXTURE_SIZE=32883]="MAX_3D_TEXTURE_SIZE",e[e.MAX_ELEMENTS_VERTICES=33e3]="MAX_ELEMENTS_VERTICES",e[e.MAX_ELEMENTS_INDICES=33001]="MAX_ELEMENTS_INDICES",e[e.MAX_TEXTURE_LOD_BIAS=34045]="MAX_TEXTURE_LOD_BIAS",e[e.MAX_FRAGMENT_UNIFORM_COMPONENTS=35657]="MAX_FRAGMENT_UNIFORM_COMPONENTS",e[e.MAX_VERTEX_UNIFORM_COMPONENTS=35658]="MAX_VERTEX_UNIFORM_COMPONENTS",e[e.MAX_ARRAY_TEXTURE_LAYERS=35071]="MAX_ARRAY_TEXTURE_LAYERS",e[e.MIN_PROGRAM_TEXEL_OFFSET=35076]="MIN_PROGRAM_TEXEL_OFFSET",e[e.MAX_PROGRAM_TEXEL_OFFSET=35077]="MAX_PROGRAM_TEXEL_OFFSET",e[e.MAX_VARYING_COMPONENTS=35659]="MAX_VARYING_COMPONENTS",e[e.FRAGMENT_SHADER_DERIVATIVE_HINT=35723]="FRAGMENT_SHADER_DERIVATIVE_HINT",e[e.RASTERIZER_DISCARD=35977]="RASTERIZER_DISCARD",e[e.VERTEX_ARRAY_BINDING=34229]="VERTEX_ARRAY_BINDING",e[e.MAX_VERTEX_OUTPUT_COMPONENTS=37154]="MAX_VERTEX_OUTPUT_COMPONENTS",e[e.MAX_FRAGMENT_INPUT_COMPONENTS=37157]="MAX_FRAGMENT_INPUT_COMPONENTS",e[e.MAX_SERVER_WAIT_TIMEOUT=37137]="MAX_SERVER_WAIT_TIMEOUT",e[e.MAX_ELEMENT_INDEX=36203]="MAX_ELEMENT_INDEX",e[e.RED=6403]="RED",e[e.RGB8=32849]="RGB8",e[e.RGBA8=32856]="RGBA8",e[e.RGB10_A2=32857]="RGB10_A2",e[e.TEXTURE_3D=32879]="TEXTURE_3D",e[e.TEXTURE_WRAP_R=32882]="TEXTURE_WRAP_R",e[e.TEXTURE_MIN_LOD=33082]="TEXTURE_MIN_LOD",e[e.TEXTURE_MAX_LOD=33083]="TEXTURE_MAX_LOD",e[e.TEXTURE_BASE_LEVEL=33084]="TEXTURE_BASE_LEVEL",e[e.TEXTURE_MAX_LEVEL=33085]="TEXTURE_MAX_LEVEL",e[e.TEXTURE_COMPARE_MODE=34892]="TEXTURE_COMPARE_MODE",e[e.TEXTURE_COMPARE_FUNC=34893]="TEXTURE_COMPARE_FUNC",e[e.SRGB=35904]="SRGB",e[e.SRGB8=35905]="SRGB8",e[e.SRGB8_ALPHA8=35907]="SRGB8_ALPHA8",e[e.COMPARE_REF_TO_TEXTURE=34894]="COMPARE_REF_TO_TEXTURE",e[e.RGBA32F=34836]="RGBA32F",e[e.RGB32F=34837]="RGB32F",e[e.RGBA16F=34842]="RGBA16F",e[e.RGB16F=34843]="RGB16F",e[e.TEXTURE_2D_ARRAY=35866]="TEXTURE_2D_ARRAY",e[e.TEXTURE_BINDING_2D_ARRAY=35869]="TEXTURE_BINDING_2D_ARRAY",e[e.R11F_G11F_B10F=35898]="R11F_G11F_B10F",e[e.RGB9_E5=35901]="RGB9_E5",e[e.RGBA32UI=36208]="RGBA32UI",e[e.RGB32UI=36209]="RGB32UI",e[e.RGBA16UI=36214]="RGBA16UI",e[e.RGB16UI=36215]="RGB16UI",e[e.RGBA8UI=36220]="RGBA8UI",e[e.RGB8UI=36221]="RGB8UI",e[e.RGBA32I=36226]="RGBA32I",e[e.RGB32I=36227]="RGB32I",e[e.RGBA16I=36232]="RGBA16I",e[e.RGB16I=36233]="RGB16I",e[e.RGBA8I=36238]="RGBA8I",e[e.RGB8I=36239]="RGB8I",e[e.RED_INTEGER=36244]="RED_INTEGER",e[e.RGB_INTEGER=36248]="RGB_INTEGER",e[e.RGBA_INTEGER=36249]="RGBA_INTEGER",e[e.R8=33321]="R8",e[e.RG8=33323]="RG8",e[e.R16F=33325]="R16F",e[e.R32F=33326]="R32F",e[e.RG16F=33327]="RG16F",e[e.RG32F=33328]="RG32F",e[e.R8I=33329]="R8I",e[e.R8UI=33330]="R8UI",e[e.R16I=33331]="R16I",e[e.R16UI=33332]="R16UI",e[e.R32I=33333]="R32I",e[e.R32UI=33334]="R32UI",e[e.RG8I=33335]="RG8I",e[e.RG8UI=33336]="RG8UI",e[e.RG16I=33337]="RG16I",e[e.RG16UI=33338]="RG16UI",e[e.RG32I=33339]="RG32I",e[e.RG32UI=33340]="RG32UI",e[e.R8_SNORM=36756]="R8_SNORM",e[e.RG8_SNORM=36757]="RG8_SNORM",e[e.RGB8_SNORM=36758]="RGB8_SNORM",e[e.RGBA8_SNORM=36759]="RGBA8_SNORM",e[e.RGB10_A2UI=36975]="RGB10_A2UI",e[e.TEXTURE_IMMUTABLE_FORMAT=37167]="TEXTURE_IMMUTABLE_FORMAT",e[e.TEXTURE_IMMUTABLE_LEVELS=33503]="TEXTURE_IMMUTABLE_LEVELS",e[e.UNSIGNED_INT_2_10_10_10_REV=33640]="UNSIGNED_INT_2_10_10_10_REV",e[e.UNSIGNED_INT_10F_11F_11F_REV=35899]="UNSIGNED_INT_10F_11F_11F_REV",e[e.UNSIGNED_INT_5_9_9_9_REV=35902]="UNSIGNED_INT_5_9_9_9_REV",e[e.FLOAT_32_UNSIGNED_INT_24_8_REV=36269]="FLOAT_32_UNSIGNED_INT_24_8_REV",e[e.UNSIGNED_INT_24_8=34042]="UNSIGNED_INT_24_8",e[e.HALF_FLOAT=5131]="HALF_FLOAT",e[e.RG=33319]="RG",e[e.RG_INTEGER=33320]="RG_INTEGER",e[e.INT_2_10_10_10_REV=36255]="INT_2_10_10_10_REV",e[e.CURRENT_QUERY=34917]="CURRENT_QUERY",e[e.QUERY_RESULT=34918]="QUERY_RESULT",e[e.QUERY_RESULT_AVAILABLE=34919]="QUERY_RESULT_AVAILABLE",e[e.ANY_SAMPLES_PASSED=35887]="ANY_SAMPLES_PASSED",e[e.ANY_SAMPLES_PASSED_CONSERVATIVE=36202]="ANY_SAMPLES_PASSED_CONSERVATIVE",e[e.MAX_DRAW_BUFFERS=34852]="MAX_DRAW_BUFFERS",e[e.DRAW_BUFFER0=34853]="DRAW_BUFFER0",e[e.DRAW_BUFFER1=34854]="DRAW_BUFFER1",e[e.DRAW_BUFFER2=34855]="DRAW_BUFFER2",e[e.DRAW_BUFFER3=34856]="DRAW_BUFFER3",e[e.DRAW_BUFFER4=34857]="DRAW_BUFFER4",e[e.DRAW_BUFFER5=34858]="DRAW_BUFFER5",e[e.DRAW_BUFFER6=34859]="DRAW_BUFFER6",e[e.DRAW_BUFFER7=34860]="DRAW_BUFFER7",e[e.DRAW_BUFFER8=34861]="DRAW_BUFFER8",e[e.DRAW_BUFFER9=34862]="DRAW_BUFFER9",e[e.DRAW_BUFFER10=34863]="DRAW_BUFFER10",e[e.DRAW_BUFFER11=34864]="DRAW_BUFFER11",e[e.DRAW_BUFFER12=34865]="DRAW_BUFFER12",e[e.DRAW_BUFFER13=34866]="DRAW_BUFFER13",e[e.DRAW_BUFFER14=34867]="DRAW_BUFFER14",e[e.DRAW_BUFFER15=34868]="DRAW_BUFFER15",e[e.MAX_COLOR_ATTACHMENTS=36063]="MAX_COLOR_ATTACHMENTS",e[e.COLOR_ATTACHMENT1=36065]="COLOR_ATTACHMENT1",e[e.COLOR_ATTACHMENT2=36066]="COLOR_ATTACHMENT2",e[e.COLOR_ATTACHMENT3=36067]="COLOR_ATTACHMENT3",e[e.COLOR_ATTACHMENT4=36068]="COLOR_ATTACHMENT4",e[e.COLOR_ATTACHMENT5=36069]="COLOR_ATTACHMENT5",e[e.COLOR_ATTACHMENT6=36070]="COLOR_ATTACHMENT6",e[e.COLOR_ATTACHMENT7=36071]="COLOR_ATTACHMENT7",e[e.COLOR_ATTACHMENT8=36072]="COLOR_ATTACHMENT8",e[e.COLOR_ATTACHMENT9=36073]="COLOR_ATTACHMENT9",e[e.COLOR_ATTACHMENT10=36074]="COLOR_ATTACHMENT10",e[e.COLOR_ATTACHMENT11=36075]="COLOR_ATTACHMENT11",e[e.COLOR_ATTACHMENT12=36076]="COLOR_ATTACHMENT12",e[e.COLOR_ATTACHMENT13=36077]="COLOR_ATTACHMENT13",e[e.COLOR_ATTACHMENT14=36078]="COLOR_ATTACHMENT14",e[e.COLOR_ATTACHMENT15=36079]="COLOR_ATTACHMENT15",e[e.SAMPLER_3D=35679]="SAMPLER_3D",e[e.SAMPLER_2D_SHADOW=35682]="SAMPLER_2D_SHADOW",e[e.SAMPLER_2D_ARRAY=36289]="SAMPLER_2D_ARRAY",e[e.SAMPLER_2D_ARRAY_SHADOW=36292]="SAMPLER_2D_ARRAY_SHADOW",e[e.SAMPLER_CUBE_SHADOW=36293]="SAMPLER_CUBE_SHADOW",e[e.INT_SAMPLER_2D=36298]="INT_SAMPLER_2D",e[e.INT_SAMPLER_3D=36299]="INT_SAMPLER_3D",e[e.INT_SAMPLER_CUBE=36300]="INT_SAMPLER_CUBE",e[e.INT_SAMPLER_2D_ARRAY=36303]="INT_SAMPLER_2D_ARRAY",e[e.UNSIGNED_INT_SAMPLER_2D=36306]="UNSIGNED_INT_SAMPLER_2D",e[e.UNSIGNED_INT_SAMPLER_3D=36307]="UNSIGNED_INT_SAMPLER_3D",e[e.UNSIGNED_INT_SAMPLER_CUBE=36308]="UNSIGNED_INT_SAMPLER_CUBE",e[e.UNSIGNED_INT_SAMPLER_2D_ARRAY=36311]="UNSIGNED_INT_SAMPLER_2D_ARRAY",e[e.MAX_SAMPLES=36183]="MAX_SAMPLES",e[e.SAMPLER_BINDING=35097]="SAMPLER_BINDING",e[e.PIXEL_PACK_BUFFER=35051]="PIXEL_PACK_BUFFER",e[e.PIXEL_UNPACK_BUFFER=35052]="PIXEL_UNPACK_BUFFER",e[e.PIXEL_PACK_BUFFER_BINDING=35053]="PIXEL_PACK_BUFFER_BINDING",e[e.PIXEL_UNPACK_BUFFER_BINDING=35055]="PIXEL_UNPACK_BUFFER_BINDING",e[e.COPY_READ_BUFFER=36662]="COPY_READ_BUFFER",e[e.COPY_WRITE_BUFFER=36663]="COPY_WRITE_BUFFER",e[e.COPY_READ_BUFFER_BINDING=36662]="COPY_READ_BUFFER_BINDING",e[e.COPY_WRITE_BUFFER_BINDING=36663]="COPY_WRITE_BUFFER_BINDING",e[e.FLOAT_MAT2x3=35685]="FLOAT_MAT2x3",e[e.FLOAT_MAT2x4=35686]="FLOAT_MAT2x4",e[e.FLOAT_MAT3x2=35687]="FLOAT_MAT3x2",e[e.FLOAT_MAT3x4=35688]="FLOAT_MAT3x4",e[e.FLOAT_MAT4x2=35689]="FLOAT_MAT4x2",e[e.FLOAT_MAT4x3=35690]="FLOAT_MAT4x3",e[e.UNSIGNED_INT_VEC2=36294]="UNSIGNED_INT_VEC2",e[e.UNSIGNED_INT_VEC3=36295]="UNSIGNED_INT_VEC3",e[e.UNSIGNED_INT_VEC4=36296]="UNSIGNED_INT_VEC4",e[e.UNSIGNED_NORMALIZED=35863]="UNSIGNED_NORMALIZED",e[e.SIGNED_NORMALIZED=36764]="SIGNED_NORMALIZED",e[e.VERTEX_ATTRIB_ARRAY_INTEGER=35069]="VERTEX_ATTRIB_ARRAY_INTEGER",e[e.VERTEX_ATTRIB_ARRAY_DIVISOR=35070]="VERTEX_ATTRIB_ARRAY_DIVISOR",e[e.TRANSFORM_FEEDBACK_BUFFER_MODE=35967]="TRANSFORM_FEEDBACK_BUFFER_MODE",e[e.MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS=35968]="MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS",e[e.TRANSFORM_FEEDBACK_VARYINGS=35971]="TRANSFORM_FEEDBACK_VARYINGS",e[e.TRANSFORM_FEEDBACK_BUFFER_START=35972]="TRANSFORM_FEEDBACK_BUFFER_START",e[e.TRANSFORM_FEEDBACK_BUFFER_SIZE=35973]="TRANSFORM_FEEDBACK_BUFFER_SIZE",e[e.TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN=35976]="TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN",e[e.MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS=35978]="MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS",e[e.MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS=35979]="MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS",e[e.INTERLEAVED_ATTRIBS=35980]="INTERLEAVED_ATTRIBS",e[e.SEPARATE_ATTRIBS=35981]="SEPARATE_ATTRIBS",e[e.TRANSFORM_FEEDBACK_BUFFER=35982]="TRANSFORM_FEEDBACK_BUFFER",e[e.TRANSFORM_FEEDBACK_BUFFER_BINDING=35983]="TRANSFORM_FEEDBACK_BUFFER_BINDING",e[e.TRANSFORM_FEEDBACK=36386]="TRANSFORM_FEEDBACK",e[e.TRANSFORM_FEEDBACK_PAUSED=36387]="TRANSFORM_FEEDBACK_PAUSED",e[e.TRANSFORM_FEEDBACK_ACTIVE=36388]="TRANSFORM_FEEDBACK_ACTIVE",e[e.TRANSFORM_FEEDBACK_BINDING=36389]="TRANSFORM_FEEDBACK_BINDING",e[e.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING=33296]="FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING",e[e.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE=33297]="FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE",e[e.FRAMEBUFFER_ATTACHMENT_RED_SIZE=33298]="FRAMEBUFFER_ATTACHMENT_RED_SIZE",e[e.FRAMEBUFFER_ATTACHMENT_GREEN_SIZE=33299]="FRAMEBUFFER_ATTACHMENT_GREEN_SIZE",e[e.FRAMEBUFFER_ATTACHMENT_BLUE_SIZE=33300]="FRAMEBUFFER_ATTACHMENT_BLUE_SIZE",e[e.FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE=33301]="FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE",e[e.FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE=33302]="FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE",e[e.FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE=33303]="FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE",e[e.FRAMEBUFFER_DEFAULT=33304]="FRAMEBUFFER_DEFAULT",e[e.DEPTH24_STENCIL8=35056]="DEPTH24_STENCIL8",e[e.DRAW_FRAMEBUFFER_BINDING=36006]="DRAW_FRAMEBUFFER_BINDING",e[e.READ_FRAMEBUFFER_BINDING=36010]="READ_FRAMEBUFFER_BINDING",e[e.RENDERBUFFER_SAMPLES=36011]="RENDERBUFFER_SAMPLES",e[e.FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER=36052]="FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER",e[e.FRAMEBUFFER_INCOMPLETE_MULTISAMPLE=36182]="FRAMEBUFFER_INCOMPLETE_MULTISAMPLE",e[e.UNIFORM_BUFFER=35345]="UNIFORM_BUFFER",e[e.UNIFORM_BUFFER_BINDING=35368]="UNIFORM_BUFFER_BINDING",e[e.UNIFORM_BUFFER_START=35369]="UNIFORM_BUFFER_START",e[e.UNIFORM_BUFFER_SIZE=35370]="UNIFORM_BUFFER_SIZE",e[e.MAX_VERTEX_UNIFORM_BLOCKS=35371]="MAX_VERTEX_UNIFORM_BLOCKS",e[e.MAX_FRAGMENT_UNIFORM_BLOCKS=35373]="MAX_FRAGMENT_UNIFORM_BLOCKS",e[e.MAX_COMBINED_UNIFORM_BLOCKS=35374]="MAX_COMBINED_UNIFORM_BLOCKS",e[e.MAX_UNIFORM_BUFFER_BINDINGS=35375]="MAX_UNIFORM_BUFFER_BINDINGS",e[e.MAX_UNIFORM_BLOCK_SIZE=35376]="MAX_UNIFORM_BLOCK_SIZE",e[e.MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS=35377]="MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS",e[e.MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS=35379]="MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS",e[e.UNIFORM_BUFFER_OFFSET_ALIGNMENT=35380]="UNIFORM_BUFFER_OFFSET_ALIGNMENT",e[e.ACTIVE_UNIFORM_BLOCKS=35382]="ACTIVE_UNIFORM_BLOCKS",e[e.UNIFORM_TYPE=35383]="UNIFORM_TYPE",e[e.UNIFORM_SIZE=35384]="UNIFORM_SIZE",e[e.UNIFORM_BLOCK_INDEX=35386]="UNIFORM_BLOCK_INDEX",e[e.UNIFORM_OFFSET=35387]="UNIFORM_OFFSET",e[e.UNIFORM_ARRAY_STRIDE=35388]="UNIFORM_ARRAY_STRIDE",e[e.UNIFORM_MATRIX_STRIDE=35389]="UNIFORM_MATRIX_STRIDE",e[e.UNIFORM_IS_ROW_MAJOR=35390]="UNIFORM_IS_ROW_MAJOR",e[e.UNIFORM_BLOCK_BINDING=35391]="UNIFORM_BLOCK_BINDING",e[e.UNIFORM_BLOCK_DATA_SIZE=35392]="UNIFORM_BLOCK_DATA_SIZE",e[e.UNIFORM_BLOCK_ACTIVE_UNIFORMS=35394]="UNIFORM_BLOCK_ACTIVE_UNIFORMS",e[e.UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES=35395]="UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES",e[e.UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER=35396]="UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER",e[e.UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER=35398]="UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER",e[e.OBJECT_TYPE=37138]="OBJECT_TYPE",e[e.SYNC_CONDITION=37139]="SYNC_CONDITION",e[e.SYNC_STATUS=37140]="SYNC_STATUS",e[e.SYNC_FLAGS=37141]="SYNC_FLAGS",e[e.SYNC_FENCE=37142]="SYNC_FENCE",e[e.SYNC_GPU_COMMANDS_COMPLETE=37143]="SYNC_GPU_COMMANDS_COMPLETE",e[e.UNSIGNALED=37144]="UNSIGNALED",e[e.SIGNALED=37145]="SIGNALED",e[e.ALREADY_SIGNALED=37146]="ALREADY_SIGNALED",e[e.TIMEOUT_EXPIRED=37147]="TIMEOUT_EXPIRED",e[e.CONDITION_SATISFIED=37148]="CONDITION_SATISFIED",e[e.WAIT_FAILED=37149]="WAIT_FAILED",e[e.SYNC_FLUSH_COMMANDS_BIT=1]="SYNC_FLUSH_COMMANDS_BIT",e[e.COLOR=6144]="COLOR",e[e.DEPTH=6145]="DEPTH",e[e.STENCIL=6146]="STENCIL",e[e.MIN=32775]="MIN",e[e.MAX=32776]="MAX",e[e.DEPTH_COMPONENT24=33190]="DEPTH_COMPONENT24",e[e.STREAM_READ=35041]="STREAM_READ",e[e.STREAM_COPY=35042]="STREAM_COPY",e[e.STATIC_READ=35045]="STATIC_READ",e[e.STATIC_COPY=35046]="STATIC_COPY",e[e.DYNAMIC_READ=35049]="DYNAMIC_READ",e[e.DYNAMIC_COPY=35050]="DYNAMIC_COPY",e[e.DEPTH_COMPONENT32F=36012]="DEPTH_COMPONENT32F",e[e.DEPTH32F_STENCIL8=36013]="DEPTH32F_STENCIL8",e[e.INVALID_INDEX=4294967295]="INVALID_INDEX",e[e.TIMEOUT_IGNORED=-1]="TIMEOUT_IGNORED",e[e.MAX_CLIENT_WAIT_TIMEOUT_WEBGL=37447]="MAX_CLIENT_WAIT_TIMEOUT_WEBGL",e[e.VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE=35070]="VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE",e[e.UNMASKED_VENDOR_WEBGL=37445]="UNMASKED_VENDOR_WEBGL",e[e.UNMASKED_RENDERER_WEBGL=37446]="UNMASKED_RENDERER_WEBGL",e[e.MAX_TEXTURE_MAX_ANISOTROPY_EXT=34047]="MAX_TEXTURE_MAX_ANISOTROPY_EXT",e[e.TEXTURE_MAX_ANISOTROPY_EXT=34046]="TEXTURE_MAX_ANISOTROPY_EXT",e[e.COMPRESSED_RGB_S3TC_DXT1_EXT=33776]="COMPRESSED_RGB_S3TC_DXT1_EXT",e[e.COMPRESSED_RGBA_S3TC_DXT1_EXT=33777]="COMPRESSED_RGBA_S3TC_DXT1_EXT",e[e.COMPRESSED_RGBA_S3TC_DXT3_EXT=33778]="COMPRESSED_RGBA_S3TC_DXT3_EXT",e[e.COMPRESSED_RGBA_S3TC_DXT5_EXT=33779]="COMPRESSED_RGBA_S3TC_DXT5_EXT",e[e.COMPRESSED_R11_EAC=37488]="COMPRESSED_R11_EAC",e[e.COMPRESSED_SIGNED_R11_EAC=37489]="COMPRESSED_SIGNED_R11_EAC",e[e.COMPRESSED_RG11_EAC=37490]="COMPRESSED_RG11_EAC",e[e.COMPRESSED_SIGNED_RG11_EAC=37491]="COMPRESSED_SIGNED_RG11_EAC",e[e.COMPRESSED_RGB8_ETC2=37492]="COMPRESSED_RGB8_ETC2",e[e.COMPRESSED_RGBA8_ETC2_EAC=37493]="COMPRESSED_RGBA8_ETC2_EAC",e[e.COMPRESSED_SRGB8_ETC2=37494]="COMPRESSED_SRGB8_ETC2",e[e.COMPRESSED_SRGB8_ALPHA8_ETC2_EAC=37495]="COMPRESSED_SRGB8_ALPHA8_ETC2_EAC",e[e.COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2=37496]="COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2",e[e.COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2=37497]="COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2",e[e.COMPRESSED_RGB_PVRTC_4BPPV1_IMG=35840]="COMPRESSED_RGB_PVRTC_4BPPV1_IMG",e[e.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG=35842]="COMPRESSED_RGBA_PVRTC_4BPPV1_IMG",e[e.COMPRESSED_RGB_PVRTC_2BPPV1_IMG=35841]="COMPRESSED_RGB_PVRTC_2BPPV1_IMG",e[e.COMPRESSED_RGBA_PVRTC_2BPPV1_IMG=35843]="COMPRESSED_RGBA_PVRTC_2BPPV1_IMG",e[e.COMPRESSED_RGB_ETC1_WEBGL=36196]="COMPRESSED_RGB_ETC1_WEBGL",e[e.COMPRESSED_RGB_ATC_WEBGL=35986]="COMPRESSED_RGB_ATC_WEBGL",e[e.COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL=35986]="COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL",e[e.COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL=34798]="COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL",e[e.UNSIGNED_INT_24_8_WEBGL=34042]="UNSIGNED_INT_24_8_WEBGL",e[e.HALF_FLOAT_OES=36193]="HALF_FLOAT_OES",e[e.RGBA32F_EXT=34836]="RGBA32F_EXT",e[e.RGB32F_EXT=34837]="RGB32F_EXT",e[e.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE_EXT=33297]="FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE_EXT",e[e.UNSIGNED_NORMALIZED_EXT=35863]="UNSIGNED_NORMALIZED_EXT",e[e.MIN_EXT=32775]="MIN_EXT",e[e.MAX_EXT=32776]="MAX_EXT",e[e.SRGB_EXT=35904]="SRGB_EXT",e[e.SRGB_ALPHA_EXT=35906]="SRGB_ALPHA_EXT",e[e.SRGB8_ALPHA8_EXT=35907]="SRGB8_ALPHA8_EXT",e[e.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING_EXT=33296]="FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING_EXT",e[e.FRAGMENT_SHADER_DERIVATIVE_HINT_OES=35723]="FRAGMENT_SHADER_DERIVATIVE_HINT_OES",e[e.COLOR_ATTACHMENT0_WEBGL=36064]="COLOR_ATTACHMENT0_WEBGL",e[e.COLOR_ATTACHMENT1_WEBGL=36065]="COLOR_ATTACHMENT1_WEBGL",e[e.COLOR_ATTACHMENT2_WEBGL=36066]="COLOR_ATTACHMENT2_WEBGL",e[e.COLOR_ATTACHMENT3_WEBGL=36067]="COLOR_ATTACHMENT3_WEBGL",e[e.COLOR_ATTACHMENT4_WEBGL=36068]="COLOR_ATTACHMENT4_WEBGL",e[e.COLOR_ATTACHMENT5_WEBGL=36069]="COLOR_ATTACHMENT5_WEBGL",e[e.COLOR_ATTACHMENT6_WEBGL=36070]="COLOR_ATTACHMENT6_WEBGL",e[e.COLOR_ATTACHMENT7_WEBGL=36071]="COLOR_ATTACHMENT7_WEBGL",e[e.COLOR_ATTACHMENT8_WEBGL=36072]="COLOR_ATTACHMENT8_WEBGL",e[e.COLOR_ATTACHMENT9_WEBGL=36073]="COLOR_ATTACHMENT9_WEBGL",e[e.COLOR_ATTACHMENT10_WEBGL=36074]="COLOR_ATTACHMENT10_WEBGL",e[e.COLOR_ATTACHMENT11_WEBGL=36075]="COLOR_ATTACHMENT11_WEBGL",e[e.COLOR_ATTACHMENT12_WEBGL=36076]="COLOR_ATTACHMENT12_WEBGL",e[e.COLOR_ATTACHMENT13_WEBGL=36077]="COLOR_ATTACHMENT13_WEBGL",e[e.COLOR_ATTACHMENT14_WEBGL=36078]="COLOR_ATTACHMENT14_WEBGL",e[e.COLOR_ATTACHMENT15_WEBGL=36079]="COLOR_ATTACHMENT15_WEBGL",e[e.DRAW_BUFFER0_WEBGL=34853]="DRAW_BUFFER0_WEBGL",e[e.DRAW_BUFFER1_WEBGL=34854]="DRAW_BUFFER1_WEBGL",e[e.DRAW_BUFFER2_WEBGL=34855]="DRAW_BUFFER2_WEBGL",e[e.DRAW_BUFFER3_WEBGL=34856]="DRAW_BUFFER3_WEBGL",e[e.DRAW_BUFFER4_WEBGL=34857]="DRAW_BUFFER4_WEBGL",e[e.DRAW_BUFFER5_WEBGL=34858]="DRAW_BUFFER5_WEBGL",e[e.DRAW_BUFFER6_WEBGL=34859]="DRAW_BUFFER6_WEBGL",e[e.DRAW_BUFFER7_WEBGL=34860]="DRAW_BUFFER7_WEBGL",e[e.DRAW_BUFFER8_WEBGL=34861]="DRAW_BUFFER8_WEBGL",e[e.DRAW_BUFFER9_WEBGL=34862]="DRAW_BUFFER9_WEBGL",e[e.DRAW_BUFFER10_WEBGL=34863]="DRAW_BUFFER10_WEBGL",e[e.DRAW_BUFFER11_WEBGL=34864]="DRAW_BUFFER11_WEBGL",e[e.DRAW_BUFFER12_WEBGL=34865]="DRAW_BUFFER12_WEBGL",e[e.DRAW_BUFFER13_WEBGL=34866]="DRAW_BUFFER13_WEBGL",e[e.DRAW_BUFFER14_WEBGL=34867]="DRAW_BUFFER14_WEBGL",e[e.DRAW_BUFFER15_WEBGL=34868]="DRAW_BUFFER15_WEBGL",e[e.MAX_COLOR_ATTACHMENTS_WEBGL=36063]="MAX_COLOR_ATTACHMENTS_WEBGL",e[e.MAX_DRAW_BUFFERS_WEBGL=34852]="MAX_DRAW_BUFFERS_WEBGL",e[e.VERTEX_ARRAY_BINDING_OES=34229]="VERTEX_ARRAY_BINDING_OES",e[e.QUERY_COUNTER_BITS_EXT=34916]="QUERY_COUNTER_BITS_EXT",e[e.CURRENT_QUERY_EXT=34917]="CURRENT_QUERY_EXT",e[e.QUERY_RESULT_EXT=34918]="QUERY_RESULT_EXT",e[e.QUERY_RESULT_AVAILABLE_EXT=34919]="QUERY_RESULT_AVAILABLE_EXT",e[e.TIME_ELAPSED_EXT=35007]="TIME_ELAPSED_EXT",e[e.TIMESTAMP_EXT=36392]="TIMESTAMP_EXT",e[e.GPU_DISJOINT_EXT=36795]="GPU_DISJOINT_EXT"})(Ri||(Ri={}));var vp;(function(e){e[e.Buffer=0]="Buffer",e[e.Texture=1]="Texture",e[e.RenderTarget=2]="RenderTarget",e[e.Sampler=3]="Sampler",e[e.Program=4]="Program",e[e.Bindings=5]="Bindings",e[e.InputLayout=6]="InputLayout",e[e.RenderPipeline=7]="RenderPipeline",e[e.ComputePipeline=8]="ComputePipeline",e[e.Readback=9]="Readback",e[e.QueryPool=10]="QueryPool",e[e.RenderBundle=11]="RenderBundle"})(vp||(vp={}));var Ad;(function(e){e[e.NEVER=512]="NEVER",e[e.LESS=513]="LESS",e[e.EQUAL=514]="EQUAL",e[e.LEQUAL=515]="LEQUAL",e[e.GREATER=516]="GREATER",e[e.NOTEQUAL=517]="NOTEQUAL",e[e.GEQUAL=518]="GEQUAL",e[e.ALWAYS=519]="ALWAYS"})(Ad||(Ad={}));var aA;(function(e){e[e.CCW=2305]="CCW",e[e.CW=2304]="CW"})(aA||(aA={}));var mv;(function(e){e[e.NONE=0]="NONE",e[e.FRONT=1]="FRONT",e[e.BACK=2]="BACK",e[e.FRONT_AND_BACK=3]="FRONT_AND_BACK"})(mv||(mv={}));var Dd;(function(e){e[e.ZERO=0]="ZERO",e[e.ONE=1]="ONE",e[e.SRC=768]="SRC",e[e.ONE_MINUS_SRC=769]="ONE_MINUS_SRC",e[e.DST=774]="DST",e[e.ONE_MINUS_DST=775]="ONE_MINUS_DST",e[e.SRC_ALPHA=770]="SRC_ALPHA",e[e.ONE_MINUS_SRC_ALPHA=771]="ONE_MINUS_SRC_ALPHA",e[e.DST_ALPHA=772]="DST_ALPHA",e[e.ONE_MINUS_DST_ALPHA=773]="ONE_MINUS_DST_ALPHA",e[e.CONST=32769]="CONST",e[e.ONE_MINUS_CONSTANT=32770]="ONE_MINUS_CONSTANT",e[e.SRC_ALPHA_SATURATE=776]="SRC_ALPHA_SATURATE"})(Dd||(Dd={}));var Zm;(function(e){e[e.ADD=32774]="ADD",e[e.SUBSTRACT=32778]="SUBSTRACT",e[e.REVERSE_SUBSTRACT=32779]="REVERSE_SUBSTRACT",e[e.MIN=32775]="MIN",e[e.MAX=32776]="MAX"})(Zm||(Zm={}));var sv;(function(e){e[e.CLAMP_TO_EDGE=0]="CLAMP_TO_EDGE",e[e.REPEAT=1]="REPEAT",e[e.MIRRORED_REPEAT=2]="MIRRORED_REPEAT"})(sv||(sv={}));var fm;(function(e){e[e.POINT=0]="POINT",e[e.BILINEAR=1]="BILINEAR"})(fm||(fm={}));var Dm;(function(e){e[e.NO_MIP=0]="NO_MIP",e[e.NEAREST=1]="NEAREST",e[e.LINEAR=2]="LINEAR"})(Dm||(Dm={}));var Sm;(function(e){e[e.POINTS=0]="POINTS",e[e.TRIANGLES=1]="TRIANGLES",e[e.TRIANGLE_STRIP=2]="TRIANGLE_STRIP",e[e.LINES=3]="LINES",e[e.LINE_STRIP=4]="LINE_STRIP"})(Sm||(Sm={}));var h0;(function(e){e[e.MAP_READ=1]="MAP_READ",e[e.MAP_WRITE=2]="MAP_WRITE",e[e.COPY_SRC=4]="COPY_SRC",e[e.COPY_DST=8]="COPY_DST",e[e.INDEX=16]="INDEX",e[e.VERTEX=32]="VERTEX",e[e.UNIFORM=64]="UNIFORM",e[e.STORAGE=128]="STORAGE",e[e.INDIRECT=256]="INDIRECT",e[e.QUERY_RESOLVE=512]="QUERY_RESOLVE"})(h0||(h0={}));var Yv;(function(e){e[e.STATIC=1]="STATIC",e[e.DYNAMIC=2]="DYNAMIC"})(Yv||(Yv={}));var s1;(function(e){e[e.VERTEX=1]="VERTEX",e[e.INSTANCE=2]="INSTANCE"})(s1||(s1={}));var z5;(function(e){e.LOADED="loaded"})(z5||(z5={}));var Pd;(function(e){e[e.TEXTURE_2D=0]="TEXTURE_2D",e[e.TEXTURE_2D_ARRAY=1]="TEXTURE_2D_ARRAY",e[e.TEXTURE_3D=2]="TEXTURE_3D",e[e.TEXTURE_CUBE_MAP=3]="TEXTURE_CUBE_MAP"})(Pd||(Pd={}));var Ym;(function(e){e[e.SAMPLED=1]="SAMPLED",e[e.RENDER_TARGET=2]="RENDER_TARGET",e[e.STORAGE=4]="STORAGE"})(Ym||(Ym={}));var Um;(function(e){e[e.NONE=0]="NONE",e[e.RED=1]="RED",e[e.GREEN=2]="GREEN",e[e.BLUE=4]="BLUE",e[e.ALPHA=8]="ALPHA",e[e.RGB=7]="RGB",e[e.ALL=15]="ALL"})(Um||(Um={}));var im;(function(e){e[e.KEEP=7680]="KEEP",e[e.ZERO=0]="ZERO",e[e.REPLACE=7681]="REPLACE",e[e.INVERT=5386]="INVERT",e[e.INCREMENT_CLAMP=7682]="INCREMENT_CLAMP",e[e.DECREMENT_CLAMP=7683]="DECREMENT_CLAMP",e[e.INCREMENT_WRAP=34055]="INCREMENT_WRAP",e[e.DECREMENT_WRAP=34056]="DECREMENT_WRAP"})(im||(im={}));function L$(e,i,r,n){var t=Pd.TEXTURE_2D,a=1,u=Ym.SAMPLED;return{dimension:t,format:e,width:i,height:r,depthOrArrayLayers:a,mipLevelCount:n,usage:u}}var om;(function(e){e[e.Float=0]="Float",e[e.UnfilterableFloat=1]="UnfilterableFloat",e[e.Uint=2]="Uint",e[e.Sint=3]="Sint",e[e.Depth=4]="Depth"})(om||(om={}));var mg;(function(e){e[e.LOWER_LEFT=0]="LOWER_LEFT",e[e.UPPER_LEFT=1]="UPPER_LEFT"})(mg||(mg={}));var t_;(function(e){e[e.NEGATIVE_ONE=0]="NEGATIVE_ONE",e[e.ZERO=1]="ZERO"})(t_||(t_={}));var h2;(function(e){e[e.OcclusionConservative=0]="OcclusionConservative"})(h2||(h2={}));var Hs;(function(e){e[e.U8=1]="U8",e[e.U16=2]="U16",e[e.U32=3]="U32",e[e.S8=4]="S8",e[e.S16=5]="S16",e[e.S32=6]="S32",e[e.F16=7]="F16",e[e.F32=8]="F32",e[e.BC1=65]="BC1",e[e.BC2=66]="BC2",e[e.BC3=67]="BC3",e[e.BC4_UNORM=68]="BC4_UNORM",e[e.BC4_SNORM=69]="BC4_SNORM",e[e.BC5_UNORM=70]="BC5_UNORM",e[e.BC5_SNORM=71]="BC5_SNORM",e[e.U16_PACKED_5551=97]="U16_PACKED_5551",e[e.U16_PACKED_565=98]="U16_PACKED_565",e[e.D24=129]="D24",e[e.D32F=130]="D32F",e[e.D24S8=131]="D24S8",e[e.D32FS8=132]="D32FS8"})(Hs||(Hs={}));var ef;(function(e){e[e.R=1]="R",e[e.RG=2]="RG",e[e.RGB=3]="RGB",e[e.RGBA=4]="RGBA",e[e.A=5]="A"})(ef||(ef={}));function D$(e){return e}var fc;(function(e){e[e.None=0]="None",e[e.Normalized=1]="Normalized",e[e.sRGB=2]="sRGB",e[e.Depth=4]="Depth",e[e.Stencil=8]="Stencil",e[e.RenderTarget=16]="RenderTarget",e[e.Luminance=32]="Luminance"})(fc||(fc={}));function jf(e,i,r){return e<<16|i<<8|r}var yo;(function(e){e[e.ALPHA=jf(Hs.U8,ef.A,fc.None)]="ALPHA",e[e.U8_LUMINANCE=jf(Hs.U8,ef.A,fc.Luminance)]="U8_LUMINANCE",e[e.F16_LUMINANCE=jf(Hs.F16,ef.A,fc.Luminance)]="F16_LUMINANCE",e[e.F32_LUMINANCE=jf(Hs.F32,ef.A,fc.Luminance)]="F32_LUMINANCE",e[e.F16_R=jf(Hs.F16,ef.R,fc.None)]="F16_R",e[e.F16_RG=jf(Hs.F16,ef.RG,fc.None)]="F16_RG",e[e.F16_RGB=jf(Hs.F16,ef.RGB,fc.None)]="F16_RGB",e[e.F16_RGBA=jf(Hs.F16,ef.RGBA,fc.None)]="F16_RGBA",e[e.F32_R=jf(Hs.F32,ef.R,fc.None)]="F32_R",e[e.F32_RG=jf(Hs.F32,ef.RG,fc.None)]="F32_RG",e[e.F32_RGB=jf(Hs.F32,ef.RGB,fc.None)]="F32_RGB",e[e.F32_RGBA=jf(Hs.F32,ef.RGBA,fc.None)]="F32_RGBA",e[e.U8_R=jf(Hs.U8,ef.R,fc.None)]="U8_R",e[e.U8_R_NORM=jf(Hs.U8,ef.R,fc.Normalized)]="U8_R_NORM",e[e.U8_RG=jf(Hs.U8,ef.RG,fc.None)]="U8_RG",e[e.U8_RG_NORM=jf(Hs.U8,ef.RG,fc.Normalized)]="U8_RG_NORM",e[e.U8_RGB=jf(Hs.U8,ef.RGB,fc.None)]="U8_RGB",e[e.U8_RGB_NORM=jf(Hs.U8,ef.RGB,fc.Normalized)]="U8_RGB_NORM",e[e.U8_RGB_SRGB=jf(Hs.U8,ef.RGB,fc.sRGB|fc.Normalized)]="U8_RGB_SRGB",e[e.U8_RGBA=jf(Hs.U8,ef.RGBA,fc.None)]="U8_RGBA",e[e.U8_RGBA_NORM=jf(Hs.U8,ef.RGBA,fc.Normalized)]="U8_RGBA_NORM",e[e.U8_RGBA_SRGB=jf(Hs.U8,ef.RGBA,fc.sRGB|fc.Normalized)]="U8_RGBA_SRGB",e[e.U16_R=jf(Hs.U16,ef.R,fc.None)]="U16_R",e[e.U16_R_NORM=jf(Hs.U16,ef.R,fc.Normalized)]="U16_R_NORM",e[e.U16_RG_NORM=jf(Hs.U16,ef.RG,fc.Normalized)]="U16_RG_NORM",e[e.U16_RGBA_NORM=jf(Hs.U16,ef.RGBA,fc.Normalized)]="U16_RGBA_NORM",e[e.U16_RGBA=jf(Hs.U16,ef.RGBA,fc.None)]="U16_RGBA",e[e.U16_RGB=jf(Hs.U16,ef.RGB,fc.None)]="U16_RGB",e[e.U16_RG=jf(Hs.U16,ef.RG,fc.None)]="U16_RG",e[e.U32_R=jf(Hs.U32,ef.R,fc.None)]="U32_R",e[e.U32_RG=jf(Hs.U32,ef.RG,fc.None)]="U32_RG",e[e.U32_RGB=jf(Hs.U32,ef.RGB,fc.None)]="U32_RGB",e[e.U32_RGBA=jf(Hs.U32,ef.RGBA,fc.None)]="U32_RGBA",e[e.S8_R=jf(Hs.S8,ef.R,fc.None)]="S8_R",e[e.S8_R_NORM=jf(Hs.S8,ef.R,fc.Normalized)]="S8_R_NORM",e[e.S8_RG_NORM=jf(Hs.S8,ef.RG,fc.Normalized)]="S8_RG_NORM",e[e.S8_RGB_NORM=jf(Hs.S8,ef.RGB,fc.Normalized)]="S8_RGB_NORM",e[e.S8_RGBA_NORM=jf(Hs.S8,ef.RGBA,fc.Normalized)]="S8_RGBA_NORM",e[e.S16_R=jf(Hs.S16,ef.R,fc.None)]="S16_R",e[e.S16_RG=jf(Hs.S16,ef.RG,fc.None)]="S16_RG",e[e.S16_RG_NORM=jf(Hs.S16,ef.RG,fc.Normalized)]="S16_RG_NORM",e[e.S16_RGB_NORM=jf(Hs.S16,ef.RGB,fc.Normalized)]="S16_RGB_NORM",e[e.S16_RGBA=jf(Hs.S16,ef.RGBA,fc.None)]="S16_RGBA",e[e.S16_RGBA_NORM=jf(Hs.S16,ef.RGBA,fc.Normalized)]="S16_RGBA_NORM",e[e.S32_R=jf(Hs.S32,ef.R,fc.None)]="S32_R",e[e.S32_RG=jf(Hs.S32,ef.RG,fc.None)]="S32_RG",e[e.S32_RGB=jf(Hs.S32,ef.RGB,fc.None)]="S32_RGB",e[e.S32_RGBA=jf(Hs.S32,ef.RGBA,fc.None)]="S32_RGBA",e[e.U16_RGBA_5551=jf(Hs.U16_PACKED_5551,ef.RGBA,fc.Normalized)]="U16_RGBA_5551",e[e.U16_RGB_565=jf(Hs.U16_PACKED_565,ef.RGB,fc.Normalized)]="U16_RGB_565",e[e.BC1=jf(Hs.BC1,ef.RGBA,fc.Normalized)]="BC1",e[e.BC1_SRGB=jf(Hs.BC1,ef.RGBA,fc.Normalized|fc.sRGB)]="BC1_SRGB",e[e.BC2=jf(Hs.BC2,ef.RGBA,fc.Normalized)]="BC2",e[e.BC2_SRGB=jf(Hs.BC2,ef.RGBA,fc.Normalized|fc.sRGB)]="BC2_SRGB",e[e.BC3=jf(Hs.BC3,ef.RGBA,fc.Normalized)]="BC3",e[e.BC3_SRGB=jf(Hs.BC3,ef.RGBA,fc.Normalized|fc.sRGB)]="BC3_SRGB",e[e.BC4_UNORM=jf(Hs.BC4_UNORM,ef.R,fc.Normalized)]="BC4_UNORM",e[e.BC4_SNORM=jf(Hs.BC4_SNORM,ef.R,fc.Normalized)]="BC4_SNORM",e[e.BC5_UNORM=jf(Hs.BC5_UNORM,ef.RG,fc.Normalized)]="BC5_UNORM",e[e.BC5_SNORM=jf(Hs.BC5_SNORM,ef.RG,fc.Normalized)]="BC5_SNORM",e[e.D24=jf(Hs.D24,ef.R,fc.Depth)]="D24",e[e.D24_S8=jf(Hs.D24S8,ef.RG,fc.Depth|fc.Stencil)]="D24_S8",e[e.D32F=jf(Hs.D32F,ef.R,fc.Depth)]="D32F",e[e.D32F_S8=jf(Hs.D32FS8,ef.RG,fc.Depth|fc.Stencil)]="D32F_S8",e[e.U8_RGB_RT=jf(Hs.U8,ef.RGB,fc.RenderTarget|fc.Normalized)]="U8_RGB_RT",e[e.U8_RGBA_RT=jf(Hs.U8,ef.RGBA,fc.RenderTarget|fc.Normalized)]="U8_RGBA_RT",e[e.U8_RGBA_RT_SRGB=jf(Hs.U8,ef.RGBA,fc.RenderTarget|fc.Normalized|fc.sRGB)]="U8_RGBA_RT_SRGB"})(yo||(yo={}));function d2(e){return e>>>8&255}function vg(e){return e>>>16&255}function r_(e){return e&255}function Z5(e){switch(e){case Hs.F32:case Hs.U32:case Hs.S32:return 4;case Hs.U16:case Hs.S16:case Hs.F16:return 2;case Hs.U8:case Hs.S8:return 1;default:throw new Error("whoops")}}function U5(e){return Z5(vg(e))}function k$(e){return d2(e)}function _Z(e){var i=Z5(vg(e)),r=d2(e);return i*r}function F$(e,i){return e&4294967040|i}function B$(e,i){return e&4294902015|i<<8}function j5(e){var i=r_(e);if(i&fc.Depth)return om.Depth;if(i&fc.Normalized)return om.Float;var r=vg(e);if(r===Hs.F16||r===Hs.F32)return om.Float;if(r===Hs.U8||r===Hs.U16||r===Hs.U32)return om.Uint;if(r===Hs.S8||r===Hs.S16||r===Hs.S32)return om.Sint;throw new Error("whoops")}function rd(e,i){if(i===void 0&&(i=""),!e)throw new Error("Assert fail: ".concat(i))}function u1(e){if(e!=null)return e;throw new Error("Missing object")}function V5(e,i){return e.r===i.r&&e.g===i.g&&e.b===i.b&&e.a===i.a}function $5(e,i){e.r=i.r,e.g=i.g,e.b=i.b,e.a=i.a}function H5(e){var i=e.r,r=e.g,n=e.b,t=e.a;return{r:i,g:r,b:n,a:t}}function sA(e,i,r,n){return n===void 0&&(n=1),{r:e,g:i,b:r,a:n}}var p2=sA(0,0,0,0),N$=sA(0,0,0,1),AZ=sA(1,1,1,0),z$=sA(1,1,1,1),n_=!0;function Z$(e,i){i===void 0&&(i=n_),i&&(e[10]=-e[10],e[14]=-e[14])}function U$(e,i){i===void 0&&(i=n_),i&&(e[10]=-e[10],e[14]=-e[14]+1)}function bZ(e,i){if(i===void 0&&(i=n_),i)switch(e){case Ad.LESS:return Ad.GREATER;case Ad.LEQUAL:return Ad.GEQUAL;case Ad.GEQUAL:return Ad.LEQUAL;case Ad.GREATER:return Ad.LESS;default:return e}else return e}function j$(e,i){return i===void 0&&(i=n_),i?1-e:e}function V$(e,i){return i===void 0&&(i=n_),i?-e:e}function $$(e,i,r,n){if(n===void 0&&(n=n_),r=bZ(r,n),r===Ad.LESS)return ei;if(r===Ad.GEQUAL)return e>=i;throw new Error("whoops")}function m2(e){return!!(e&&!(e&e-1))}function i_(e,i){return e!=null?e:i}function xZ(e){return e===void 0?null:e}function H$(e,i,r){e.length=i,e.fill(r)}function v2(e,i){var r=i-1;return e+r&~r}function G$(e,i){return((e+i-1)/i|0)*i}function wZ(e,i,r){for(var n=0,t=e.length;n>>1),u=r(i,e[a]);u<0?t=a:n=a+1}return n}function W$(e,i,r){var n=wZ(e,i,r);e.splice(n,0,i)}function X$(e,i,r){return r?e|=i:e&=~i,e}function EZ(e,i){for(var r=new Array(e),n=0;n-1;if(m=m.replace(";","").replace("[","").trim(),!c.startsWith("#")){if(c){var H=r.find(function(ke){return c===ke.type});if(H)if(E)for(var re=function(ke){H.uniforms.forEach(function(rt){i.push("".concat(m,"[").concat(ke,"].").concat(rt.name))})},xe=0;xe<5;xe++)re(xe);else H.uniforms.forEach(function(ke){i.push("".concat(m,".").concat(ke.name))})}m&&i.push(m)}}),""}),i}function rM(e){if(e===void 0)return null;var i=/binding\s*=\s*(\d+)/.exec(e);if(i!==null){var r=parseInt(i[1],10);if(!Number.isNaN(r))return r}return null}function nU(e){var i="",r=e;return[r,i]}function Ty(e,i,r,n,t){var a;n===void 0&&(n=null),t===void 0&&(t=!0);var u=e.glslVersion==="#version 100",c=i==="frag"&&((a=r.match(/^\s*layout\(location\s*=\s*\d*\)\s*out\s+vec4\s*(.*);$/gm))===null||a===void 0?void 0:a.length)>1,m=r.replace(`\r +`,` +`).split(` +`).map(function(wn){return wn.replace(/[/][/].*$/,"")}).filter(function(wn){var Cn=!wn||/^\s+$/.test(wn);return!Cn}),E="";n!==null&&(E=Object.keys(n).map(function(wn){return uA(wn,n[wn])}).join(` +`));var H=m.find(function(wn){return wn.startsWith("precision")})||"precision mediump float;",re=t?m.filter(function(wn){return!wn.startsWith("precision")}).join(` +`):m.join(` +`),xe="";if(e.viewportOrigin===mg.UPPER_LEFT&&(xe+="".concat(uA("VIEWPORT_ORIGIN_TL","1"),` +`)),e.clipSpaceNearZ===t_.ZERO&&(xe+="".concat(uA("CLIPSPACE_NEAR_ZERO","1"),` +`)),e.explicitBindingLocations){var ke=0,rt=0,vt=0;re=re.replace(/^\s*(layout\((.*)\))?\s*uniform(.+{)$/gm,function(wn,Cn,qn,Si){var po=qn?"".concat(qn,", "):"";return"layout(".concat(po,"set = ").concat(ke,", binding = ").concat(rt++,") uniform ").concat(Si)}),ke++,rt=0,rd(e.separateSamplerTextures),re=re.replace(/^\s*(layout\((.*)\))?\s*uniform sampler(\w+) (.*);/gm,function(wn,Cn,qn,Si,po){var Ao=rM(qn);Ao===null&&(Ao=rt++);var ma=(0,kc.CR)(nU(Si),2),Ya=ma[0],fs=ma[1];return i==="frag"?` +layout(set = `.concat(ke,", binding = ").concat(Ao*2+0,") uniform texture").concat(Ya," T_").concat(po,`; +layout(set = `).concat(ke,", binding = ").concat(Ao*2+1,") uniform sampler").concat(fs," S_").concat(po,";").trim():""}),re=re.replace(i==="frag"?/^\s*\b(varying|in)\b/gm:/^\s*\b(varying|out)\b/gm,function(wn,Cn){return"layout(location = ".concat(vt++,") ").concat(Cn)}),xe+="".concat(uA("gl_VertexID","gl_VertexIndex"),` +`),xe+="".concat(uA("gl_InstanceID","gl_InstanceIndex"),` +`),H=H.replace(/^precision (.*) sampler(.*);$/gm,"")}else{var It=0;re=re.replace(/^\s*(layout\((.*)\))?\s*uniform sampler(\w+) (.*);/gm,function(wn,Cn,qn,Si,po){var Ao=rM(qn);return Ao===null&&(Ao=It++),"uniform sampler".concat(Si," ").concat(po,"; // BINDING=").concat(Ao)})}if(e.separateSamplerTextures)re=re.replace(/\bSAMPLER_(\w+)\((.*?)\)/g,function(wn,Cn,qn){return"sampler".concat(Cn,"(T_").concat(qn,", S_").concat(qn,")")}),re=re.replace(/\bTEXTURE\((.*?)\)/g,function(wn,Cn){return"T_".concat(Cn)});else{var er=[];re=re.replace(/\bSAMPLER_(\w+)\((.*?)\)/g,function(wn,Cn,qn){return er.push([qn,Cn]),qn}),u&&er.forEach(function(wn){var Cn=(0,kc.CR)(wn,2),qn=Cn[0],Si=Cn[1];re=re.replace(new RegExp("texture\\(".concat(qn),"g"),function(){return"texture".concat(Si,"(").concat(qn)})}),re=re.replace(/\bTEXTURE\((.*?)\)/g,function(wn,Cn){return Cn})}var Ar="".concat(u?"":e.glslVersion,` +`).concat(u&&c?`#extension GL_EXT_draw_buffers : require +`:"",` +`).concat(u&&i==="frag"?`#extension GL_OES_standard_derivatives : enable +`:"").concat(t?H:"",` +`).concat(xe||"").concat(E?E+` +`:"",` +`).concat(re,` +`).trim();if(e.explicitBindingLocations&&i==="frag"&&(Ar=Ar.replace(/^\b(out)\b/g,function(wn,Cn){return"layout(location = 0) ".concat(Cn)})),u){if(i==="frag"&&(Ar=Ar.replace(/^\s*in\s+(\S+)\s*(.*);$/gm,function(wn,Cn,qn){return"varying ".concat(Cn," ").concat(qn,`; +`)})),i==="vert"&&(Ar=Ar.replace(/^\s*out\s+(\S+)\s*(.*);$/gm,function(wn,Cn,qn){return"varying ".concat(Cn," ").concat(qn,`; +`)}),Ar=Ar.replace(/^\s*layout\(location\s*=\s*\S*\)\s*in\s+(\S+)\s*(.*);$/gm,function(wn,Cn,qn){return"attribute ".concat(Cn," ").concat(qn,`; +`)})),Ar=Ar.replace(/\s*uniform\s*.*\s*{((?:\s*.*\s*)*?)};/g,function(wn,Cn){return Cn.trim().replace(/^.*$/gm,function(qn){var Si=qn.trim();return Si.startsWith("#")?Si:qn?"uniform ".concat(Si):""})}),i==="frag")if(c){var Or=[];Ar=Ar.replace(/^\s*layout\(location\s*=\s*\d*\)\s*out\s+vec4\s*(.*);$/gm,function(wn,Cn){return Or.push(Cn),"vec4 ".concat(Cn,`; +`)});var rn=Ar.lastIndexOf("}");Ar=Ar.substring(0,rn)+` + `.concat(Or.map(function(wn,Cn){return"gl_FragData[".concat(Cn,"] = ").concat(wn,`; + `)}).join(` +`))+Ar.substring(rn)}else{var Ln;if(Ar=Ar.replace(/^\s*out\s+(\S+)\s*(.*);$/gm,function(wn,Cn,qn){return Ln=qn,"".concat(Cn," ").concat(qn,`; +`)}),Ln){var rn=Ar.lastIndexOf("}");Ar=Ar.substring(0,rn)+` + gl_FragColor = vec4(`.concat(Ln,`); +`)+Ar.substring(rn)}}Ar=Ar.replace(/^\s*layout\((.*)\)/gm,"")}return Ar}function eH(e,i,r,n){n===void 0&&(n=null);var t=Ty(e,"vert",i,n),a=Ty(e,"frag",r,n);return{vert:i,frag:r,preprocessedVert:t,preprocessedFrag:a}}var Bv=function(e){(0,kc.ZT)(i,e);function i(r){var n=r.id,t=r.device,a=e.call(this)||this;return a.id=n,a.device=t,a.device.resourceCreationTracker!==null&&a.device.resourceCreationTracker.trackResourceCreated(a),a}return i.prototype.destroy=function(){this.device.resourceCreationTracker!==null&&this.device.resourceCreationTracker.trackResourceDestroyed(this)},i}(N5),iU=function(e){(0,kc.ZT)(i,e);function i(r){var n=r.id,t=r.device,a=r.descriptor,u=e.call(this,{id:n,device:t})||this;u.type=vp.Bindings;var c=a.uniformBufferBindings,m=a.samplerBindings;return u.uniformBufferBindings=c||[],u.samplerBindings=m||[],u.bindingLayouts=u.createBindingLayouts(),u}return i.prototype.createBindingLayouts=function(){var r=0,n=0,t=[],a=this.uniformBufferBindings.length,u=this.samplerBindings.length;return t.push({firstUniformBuffer:r,numUniformBuffers:a,firstSampler:n,numSamplers:u}),r+=a,n+=u,{numUniformBuffers:r,numSamplers:n,bindingLayoutTables:t}},i}(Bv);function _f(e){return typeof WebGL2RenderingContext!="undefined"&&e instanceof WebGL2RenderingContext?!0:!!(e&&e._version===2)}function nM(e){var i=vg(e);switch(i){case Hs.BC1:case Hs.BC2:case Hs.BC3:case Hs.BC4_UNORM:case Hs.BC4_SNORM:case Hs.BC5_UNORM:case Hs.BC5_SNORM:return!0;default:return!1}}function iM(e){var i=r_(e);if(i&fc.Normalized)return!1;var r=vg(e);return r===Hs.S8||r===Hs.S16||r===Hs.S32||r===Hs.U8||r===Hs.U16||r===Hs.U32}function oU(e){switch(e){case Yv.STATIC:return Ri.STATIC_DRAW;case Yv.DYNAMIC:return Ri.DYNAMIC_DRAW}}function oM(e){if(e&h0.INDEX)return Ri.ELEMENT_ARRAY_BUFFER;if(e&h0.VERTEX)return Ri.ARRAY_BUFFER;if(e&h0.UNIFORM)return Ri.UNIFORM_BUFFER}function aU(e){switch(e){case Sm.TRIANGLES:return Ri.TRIANGLES;case Sm.POINTS:return Ri.POINTS;case Sm.TRIANGLE_STRIP:return Ri.TRIANGLE_STRIP;case Sm.LINES:return Ri.LINES;case Sm.LINE_STRIP:return Ri.LINE_STRIP;default:throw new Error("Unknown primitive topology mode")}}function sU(e){switch(e){case Hs.U8:return Ri.UNSIGNED_BYTE;case Hs.U16:return Ri.UNSIGNED_SHORT;case Hs.U32:return Ri.UNSIGNED_INT;case Hs.S8:return Ri.BYTE;case Hs.S16:return Ri.SHORT;case Hs.S32:return Ri.INT;case Hs.F16:return Ri.HALF_FLOAT;case Hs.F32:return Ri.FLOAT;default:throw new Error("whoops")}}function uU(e){switch(e){case ef.R:return 1;case ef.RG:return 2;case ef.RGB:return 3;case ef.RGBA:return 4;default:return 1}}function lU(e){var i=vg(e),r=d2(e),n=r_(e),t=sU(i),a=uU(r),u=!!(n&fc.Normalized);return{size:a,type:t,normalized:u}}function cU(e){switch(e){case yo.U8_R:return Ri.UNSIGNED_BYTE;case yo.U16_R:return Ri.UNSIGNED_SHORT;case yo.U32_R:return Ri.UNSIGNED_INT;default:throw new Error("whoops")}}function lA(e){switch(e){case sv.CLAMP_TO_EDGE:return Ri.CLAMP_TO_EDGE;case sv.REPEAT:return Ri.REPEAT;case sv.MIRRORED_REPEAT:return Ri.MIRRORED_REPEAT;default:throw new Error("whoops")}}function A2(e,i){if(i===Dm.LINEAR&&e===fm.BILINEAR)return Ri.LINEAR_MIPMAP_LINEAR;if(i===Dm.LINEAR&&e===fm.POINT)return Ri.NEAREST_MIPMAP_LINEAR;if(i===Dm.NEAREST&&e===fm.BILINEAR)return Ri.LINEAR_MIPMAP_NEAREST;if(i===Dm.NEAREST&&e===fm.POINT)return Ri.NEAREST_MIPMAP_NEAREST;if(i===Dm.NO_MIP&&e===fm.BILINEAR)return Ri.LINEAR;if(i===Dm.NO_MIP&&e===fm.POINT)return Ri.NEAREST;throw new Error("Unknown texture filter mode")}function s_(e,i){i===void 0&&(i=0);var r=e;return r.gl_buffer_pages[i/r.pageByteSize|0]}function u_(e){var i=e;return i.gl_texture}function Xw(e){var i=e;return i.gl_sampler}function cA(e,i){e.name=i,e.__SPECTOR_Metadata={name:i}}function aM(e,i){for(var r=[];;){var n=i.exec(e);if(!n)break;r.push(n)}return r}function My(e){return e.blendMode==Zm.ADD&&e.blendSrcFactor==Dd.ONE&&e.blendDstFactor===Dd.ZERO}function fU(e){switch(e){case h2.OcclusionConservative:return Ri.ANY_SAMPLES_PASSED_CONSERVATIVE;default:throw new Error("whoops")}}function hU(e){if(e===Pd.TEXTURE_2D)return Ri.TEXTURE_2D;if(e===Pd.TEXTURE_2D_ARRAY)return Ri.TEXTURE_2D_ARRAY;if(e===Pd.TEXTURE_CUBE_MAP)return Ri.TEXTURE_CUBE_MAP;if(e===Pd.TEXTURE_3D)return Ri.TEXTURE_3D;throw new Error("whoops")}function Yw(e,i,r,n){return!(e%r!==0||i%n!==0)}var dU=function(e){(0,kc.ZT)(i,e);function i(r){var n=r.id,t=r.device,a=r.descriptor,u=e.call(this,{id:n,device:t})||this;u.type=vp.Buffer;var c=a.viewOrSize,m=a.usage,E=a.hint,H=E===void 0?Yv.STATIC:E,re=t.uniformBufferMaxPageByteSize,xe=t.gl,ke=m&h0.UNIFORM;ke||(_f(xe)?xe.bindVertexArray(null):t.OES_vertex_array_object.bindVertexArrayOES(null));var rt=e_(c)?v2(c,4):v2(c.byteLength,4);u.gl_buffer_pages=[];var vt;if(ke){for(var It=rt;It>0;)u.gl_buffer_pages.push(u.createBufferPage(Math.min(It,re),m,H)),It-=re;vt=re}else u.gl_buffer_pages.push(u.createBufferPage(rt,m,H)),vt=rt;return u.pageByteSize=vt,u.byteSize=rt,u.usage=m,u.gl_target=oM(m),e_(c)||u.setSubData(0,new Uint8Array(c.buffer)),ke||(_f(xe)?xe.bindVertexArray(u.device.currentBoundVAO):t.OES_vertex_array_object.bindVertexArrayOES(u.device.currentBoundVAO)),u}return i.prototype.setSubData=function(r,n,t,a){t===void 0&&(t=0),a===void 0&&(a=n.byteLength-t);for(var u=this.device.gl,c=this.pageByteSize,m=r+a,E=r,H=r%c;E=1,!u){H=c.device.ensureResourceExists(m.createTexture());var xe=c.device.translateTextureType(a.format),ke=c.device.translateTextureInternalFormat(a.format);if(c.device.setActiveTexture(m.TEXTURE0),c.device.currentTextures[0]=null,c.preprocessImage(),a.dimension===Pd.TEXTURE_2D){if(E=Ri.TEXTURE_2D,m.bindTexture(E,H),c.immutable)if(_f(m))m.texStorage2D(E,re,ke,a.width,a.height);else{var rt=(ke===Ri.DEPTH_COMPONENT||c.isNPOT(),0);(c.format===yo.D32F||c.format===yo.D24_S8)&&!_f(m)&&!t.WEBGL_depth_texture||(m.texImage2D(E,rt,ke,a.width,a.height,0,ke,xe,null),c.mipmaps&&(c.mipmaps=!1,m.texParameteri(Ri.TEXTURE_2D,Ri.TEXTURE_MIN_FILTER,Ri.LINEAR),m.texParameteri(Ri.TEXTURE_2D,Ri.TEXTURE_WRAP_S,Ri.CLAMP_TO_EDGE),m.texParameteri(Ri.TEXTURE_2D,Ri.TEXTURE_WRAP_T,Ri.CLAMP_TO_EDGE)))}rd(a.depthOrArrayLayers===1)}else if(a.dimension===Pd.TEXTURE_2D_ARRAY)E=Ri.TEXTURE_2D_ARRAY,m.bindTexture(E,H),c.immutable&&_f(m)&&m.texStorage3D(E,re,ke,a.width,a.height,a.depthOrArrayLayers);else if(a.dimension===Pd.TEXTURE_3D)E=Ri.TEXTURE_3D,m.bindTexture(E,H),c.immutable&&_f(m)&&m.texStorage3D(E,re,ke,a.width,a.height,a.depthOrArrayLayers);else if(a.dimension===Pd.TEXTURE_CUBE_MAP)E=Ri.TEXTURE_CUBE_MAP,m.bindTexture(E,H),c.immutable&&_f(m)&&m.texStorage2D(E,re,ke,a.width,a.height),rd(a.depthOrArrayLayers===6);else throw new Error("whoops")}return c.gl_texture=H,c.gl_target=E,c.mipLevelCount=re,c}return i.prototype.setImageData=function(r,n){n===void 0&&(n=0);var t=this.device.gl;nM(this.format);var a=this.gl_target===Ri.TEXTURE_3D||this.gl_target===Ri.TEXTURE_2D_ARRAY,u=this.gl_target===Ri.TEXTURE_CUBE_MAP,c=eU(r[0]);this.device.setActiveTexture(t.TEXTURE0),this.device.currentTextures[0]=null;var m=r[0],E,H;c?(E=this.width,H=this.height):(E=m.width,H=m.height,this.width=E,this.height=H),t.bindTexture(this.gl_target,this.gl_texture);var re=this.device.translateTextureFormat(this.format),xe=_f(t)?this.device.translateInternalTextureFormat(this.format):re,ke=this.device.translateTextureType(this.format);this.preprocessImage();for(var rt=0;rt1){var n=vg(r.format);if(n===Hs.BC1)for(var t=r.width,a=r.height,u=0;u1?c.renderbufferStorageMultisample(Ri.RENDERBUFFER,xe,vt,E,H):c.renderbufferStorage(Ri.RENDERBUFFER,vt,E,H)}return u.format=m,u.width=E,u.height=H,u.sampleCount=xe,u}return i.prototype.destroy=function(){e.prototype.destroy.call(this),this.gl_renderbuffer!==null&&this.device.gl.deleteRenderbuffer(this.gl_renderbuffer),this.texture&&this.texture.destroy()},i}(Bv),vv;(function(e){e[e.NeedsCompile=0]="NeedsCompile",e[e.Compiling=1]="Compiling",e[e.NeedsBind=2]="NeedsBind",e[e.ReadyToUse=3]="ReadyToUse"})(vv||(vv={}));var vU=function(e){(0,kc.ZT)(i,e);function i(r,n){var t=r.id,a=r.device,u=r.descriptor,c=e.call(this,{id:t,device:a})||this;c.rawVertexGLSL=n,c.type=vp.Program,c.uniformSetters={},c.attributes=[];var m=c.device.gl;return c.descriptor=u,c.gl_program=c.device.ensureResourceExists(m.createProgram()),c.gl_shader_vert=null,c.gl_shader_frag=null,c.compileState=vv.NeedsCompile,c.tryCompileProgram(),c}return i.prototype.destroy=function(){e.prototype.destroy.call(this),this.device.gl.deleteProgram(this.gl_program),this.device.gl.deleteShader(this.gl_shader_vert),this.device.gl.deleteShader(this.gl_shader_frag)},i.prototype.tryCompileProgram=function(){rd(this.compileState===vv.NeedsCompile);var r=this.descriptor,n=r.vertex,t=r.fragment,a=this.device.gl;n!=null&&n.glsl&&(t!=null&&t.glsl)&&(this.gl_shader_vert=this.compileShader(n.postprocess?n.postprocess(n.glsl):n.glsl,a.VERTEX_SHADER),this.gl_shader_frag=this.compileShader(t.postprocess?t.postprocess(t.glsl):t.glsl,a.FRAGMENT_SHADER),a.attachShader(this.gl_program,this.gl_shader_vert),a.attachShader(this.gl_program,this.gl_shader_frag),a.linkProgram(this.gl_program),this.compileState=vv.Compiling,_f(a)||(this.readUniformLocationsFromLinkedProgram(),this.readAttributesFromLinkedProgram()))},i.prototype.readAttributesFromLinkedProgram=function(){for(var r,n=this.device.gl,t=n.getProgramParameter(this.gl_program,n.ACTIVE_ATTRIBUTES),a=tU(this.descriptor.vertex.glsl),u=rU(this.rawVertexGLSL,a),c=function(H){var re=n.getActiveAttrib(m.gl_program,H),xe=re.name,ke=re.type,rt=re.size,vt=n.getAttribLocation(m.gl_program,xe),It=(r=u.find(function(er){return er.name===xe}))===null||r===void 0?void 0:r.location;vt>=0&&!Fv(It)&&(m.attributes[It]={name:xe,location:vt,type:ke,size:rt})},m=this,E=0;E1)for(var m=0;m1&&m.device.EXT_texture_filter_anisotropic!==null&&(rd(a.minFilter===fm.BILINEAR&&a.magFilter===fm.BILINEAR&&a.mipmapFilter===Dm.LINEAR),E.samplerParameterf(H,m.device.EXT_texture_filter_anisotropic.TEXTURE_MAX_ANISOTROPY_EXT,re)),m.gl_sampler=H}else m.descriptor=a;return m}return i.prototype.setTextureParameters=function(r,n,t){var a,u=this.device.gl,c=this.descriptor;this.isNPOT(n,t)?u.texParameteri(Ri.TEXTURE_2D,Ri.TEXTURE_MIN_FILTER,Ri.LINEAR):u.texParameteri(r,Ri.TEXTURE_MIN_FILTER,A2(c.minFilter,c.mipmapFilter)),u.texParameteri(Ri.TEXTURE_2D,Ri.TEXTURE_WRAP_S,lA(c.addressModeU)),u.texParameteri(Ri.TEXTURE_2D,Ri.TEXTURE_WRAP_T,lA(c.addressModeV)),u.texParameteri(r,Ri.TEXTURE_MAG_FILTER,A2(c.magFilter,Dm.NO_MIP));var m=(a=c.maxAnisotropy)!==null&&a!==void 0?a:1;m>1&&this.device.EXT_texture_filter_anisotropic!==null&&(rd(c.minFilter===fm.BILINEAR&&c.magFilter===fm.BILINEAR&&c.mipmapFilter===Dm.LINEAR),u.texParameteri(r,this.device.EXT_texture_filter_anisotropic.TEXTURE_MAX_ANISOTROPY_EXT,m))},i.prototype.destroy=function(){e.prototype.destroy.call(this),_f(this.device.gl)&&this.device.gl.deleteSampler(Xw(this))},i.prototype.isNPOT=function(r,n){return!m2(r)||!m2(n)},i}(Bv),wU=function(){function e(){}return e.prototype.dispatchWorkgroups=function(i,r,n){},e.prototype.dispatchWorkgroupsIndirect=function(i,r){},e.prototype.setPipeline=function(i){},e.prototype.setBindings=function(i){},e.prototype.pushDebugGroup=function(i){},e.prototype.popDebugGroup=function(){},e.prototype.insertDebugMarker=function(i){},e}(),EU=function(e){(0,kc.ZT)(i,e);function i(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=vp.RenderBundle,r.commands=[],r}return i.prototype.push=function(r){this.commands.push(r)},i.prototype.replay=function(){this.commands.forEach(function(r){return r()})},i}(Bv),sM=65536,SU=/uniform(?:\s+)(\w+)(?:\s?){([^]*?)}/g,CU=function(){function e(i,r){r===void 0&&(r={}),this.shaderDebug=!1,this.OES_vertex_array_object=null,this.ANGLE_instanced_arrays=null,this.OES_texture_float=null,this.OES_draw_buffers_indexed=null,this.WEBGL_draw_buffers=null,this.WEBGL_depth_texture=null,this.WEBGL_color_buffer_float=null,this.EXT_color_buffer_half_float=null,this.WEBGL_compressed_texture_s3tc=null,this.WEBGL_compressed_texture_s3tc_srgb=null,this.EXT_texture_compression_rgtc=null,this.EXT_texture_filter_anisotropic=null,this.KHR_parallel_shader_compile=null,this.EXT_texture_norm16=null,this.EXT_color_buffer_float=null,this.OES_texture_float_linear=null,this.OES_texture_half_float_linear=null,this.scTexture=null,this.scPlatformFramebuffer=null,this.currentActiveTexture=null,this.currentBoundVAO=null,this.currentProgram=null,this.resourceCreationTracker=null,this.resourceUniqueId=0,this.currentColorAttachments=[],this.currentColorAttachmentLevels=[],this.currentColorResolveTos=[],this.currentColorResolveToLevels=[],this.currentSampleCount=-1,this.currentIndexBufferByteOffset=null,this.currentMegaState=o_(l1),this.currentSamplers=[],this.currentTextures=[],this.currentUniformBuffers=[],this.currentUniformBufferByteOffsets=[],this.currentUniformBufferByteSizes=[],this.currentScissorEnabled=!1,this.currentStencilRef=null,this.currentRenderPassDescriptor=null,this.currentRenderPassDescriptorStack=[],this.debugGroupStack=[],this.resolveColorAttachmentsChanged=!1,this.resolveDepthStencilAttachmentsChanged=!1,this.explicitBindingLocations=!1,this.separateSamplerTextures=!1,this.viewportOrigin=mg.LOWER_LEFT,this.clipSpaceNearZ=t_.NEGATIVE_ONE,this.supportMRT=!1,this.inBlitRenderPass=!1,this.supportedSampleCounts=[],this.occlusionQueriesRecommended=!1,this.computeShadersSupported=!1,this.gl=i,this.contextAttributes=u1(i.getContextAttributes()),_f(i)?(this.EXT_texture_norm16=i.getExtension("EXT_texture_norm16"),this.EXT_color_buffer_float=i.getExtension("EXT_color_buffer_float")):(this.OES_vertex_array_object=i.getExtension("OES_vertex_array_object"),this.ANGLE_instanced_arrays=i.getExtension("ANGLE_instanced_arrays"),this.OES_texture_float=i.getExtension("OES_texture_float"),this.WEBGL_draw_buffers=i.getExtension("WEBGL_draw_buffers"),this.WEBGL_depth_texture=i.getExtension("WEBGL_depth_texture"),this.WEBGL_color_buffer_float=i.getExtension("WEBGL_color_buffer_float"),this.EXT_color_buffer_half_float=i.getExtension("EXT_color_buffer_half_float"),i.getExtension("EXT_frag_depth"),i.getExtension("OES_element_index_uint"),i.getExtension("OES_standard_derivatives")),this.WEBGL_compressed_texture_s3tc=i.getExtension("WEBGL_compressed_texture_s3tc"),this.WEBGL_compressed_texture_s3tc_srgb=i.getExtension("WEBGL_compressed_texture_s3tc_srgb"),this.EXT_texture_compression_rgtc=i.getExtension("EXT_texture_compression_rgtc"),this.EXT_texture_filter_anisotropic=i.getExtension("EXT_texture_filter_anisotropic"),this.EXT_texture_norm16=i.getExtension("EXT_texture_norm16"),this.OES_texture_float_linear=i.getExtension("OES_texture_float_linear"),this.OES_texture_half_float_linear=i.getExtension("OES_texture_half_float_linear"),this.KHR_parallel_shader_compile=i.getExtension("KHR_parallel_shader_compile"),_f(i)?(this.platformString="WebGL2",this.glslVersion="#version 300 es"):(this.platformString="WebGL1",this.glslVersion="#version 100"),this.scTexture=new Kw({id:this.getNextUniqueId(),device:this,descriptor:{width:0,height:0,depthOrArrayLayers:1,dimension:Pd.TEXTURE_2D,mipLevelCount:1,usage:Ym.RENDER_TARGET,format:this.contextAttributes.alpha===!1?yo.U8_RGB_RT:yo.U8_RGBA_RT},fake:!0}),this.scTexture.formatKind=om.Float,this.scTexture.gl_target=null,this.scTexture.gl_texture=null,this.resolveColorReadFramebuffer=this.ensureResourceExists(i.createFramebuffer()),this.resolveColorDrawFramebuffer=this.ensureResourceExists(i.createFramebuffer()),this.resolveDepthStencilReadFramebuffer=this.ensureResourceExists(i.createFramebuffer()),this.resolveDepthStencilDrawFramebuffer=this.ensureResourceExists(i.createFramebuffer()),this.renderPassDrawFramebuffer=this.ensureResourceExists(i.createFramebuffer()),this.readbackFramebuffer=this.ensureResourceExists(i.createFramebuffer()),this.fallbackTexture2D=this.createFallbackTexture(Pd.TEXTURE_2D,om.Float),this.fallbackTexture2DDepth=this.createFallbackTexture(Pd.TEXTURE_2D,om.Depth),this.fallbackVertexBuffer=this.createBuffer({viewOrSize:1,usage:h0.VERTEX,hint:Yv.STATIC}),_f(i)&&(this.fallbackTexture2DArray=this.createFallbackTexture(Pd.TEXTURE_2D_ARRAY,om.Float),this.fallbackTexture3D=this.createFallbackTexture(Pd.TEXTURE_3D,om.Float),this.fallbackTextureCube=this.createFallbackTexture(Pd.TEXTURE_CUBE_MAP,om.Float)),this.currentMegaState.depthCompare=Ad.LESS,this.currentMegaState.depthWrite=!1,this.currentMegaState.attachmentsState[0].channelWriteMask=Um.ALL,i.enable(i.DEPTH_TEST),i.enable(i.STENCIL_TEST),this.checkLimits(),r.shaderDebug&&(this.shaderDebug=!0),r.trackResources&&(this.resourceCreationTracker=new bU)}return e.prototype.destroy=function(){this.blitBindings&&this.blitBindings.destroy(),this.blitInputLayout&&this.blitInputLayout.destroy(),this.blitRenderPipeline&&this.blitRenderPipeline.destroy(),this.blitVertexBuffer&&this.blitVertexBuffer.destroy(),this.blitProgram&&this.blitProgram.destroy()},e.prototype.createFallbackTexture=function(i,r){var n=i===Pd.TEXTURE_CUBE_MAP?6:1,t=r===om.Depth?yo.D32F:yo.U8_RGBA_NORM,a=this.createTexture({dimension:i,format:t,usage:Ym.SAMPLED,width:1,height:1,depthOrArrayLayers:n,mipLevelCount:1});return r===om.Float&&a.setImageData([new Uint8Array(4*n)]),u_(a)},e.prototype.getNextUniqueId=function(){return++this.resourceUniqueId},e.prototype.checkLimits=function(){var i=this.gl;if(this.maxVertexAttribs=i.getParameter(Ri.MAX_VERTEX_ATTRIBS),_f(i)){this.uniformBufferMaxPageByteSize=Math.min(i.getParameter(Ri.MAX_UNIFORM_BLOCK_SIZE),sM),this.uniformBufferWordAlignment=i.getParameter(i.UNIFORM_BUFFER_OFFSET_ALIGNMENT)/4;var r=i.getInternalformatParameter(i.RENDERBUFFER,i.DEPTH32F_STENCIL8,i.SAMPLES);this.supportedSampleCounts=r?(0,kc.ev)([],(0,kc.CR)(r),!1):[],this.occlusionQueriesRecommended=!0}else this.uniformBufferWordAlignment=64,this.uniformBufferMaxPageByteSize=sM;this.uniformBufferMaxPageWordSize=this.uniformBufferMaxPageByteSize/4,this.supportedSampleCounts.includes(1)||this.supportedSampleCounts.push(1),this.supportedSampleCounts.sort(function(n,t){return n-t})},e.prototype.configureSwapChain=function(i,r,n){var t=this.scTexture;t.width=i,t.height=r,this.scPlatformFramebuffer=xZ(n)},e.prototype.getDevice=function(){return this},e.prototype.getCanvas=function(){return this.gl.canvas},e.prototype.getOnscreenTexture=function(){return this.scTexture},e.prototype.beginFrame=function(){},e.prototype.endFrame=function(){},e.prototype.translateTextureInternalFormat=function(i,r){switch(r===void 0&&(r=!1),i){case yo.ALPHA:return Ri.ALPHA;case yo.U8_LUMINANCE:case yo.F16_LUMINANCE:case yo.F32_LUMINANCE:return Ri.LUMINANCE;case yo.F16_R:return Ri.R16F;case yo.F16_RG:return Ri.RG16F;case yo.F16_RGB:return Ri.RGB16F;case yo.F16_RGBA:return Ri.RGBA16F;case yo.F32_R:return Ri.R32F;case yo.F32_RG:return Ri.RG32F;case yo.F32_RGB:return Ri.RGB32F;case yo.F32_RGBA:return _f(this.gl)?Ri.RGBA32F:r?this.WEBGL_color_buffer_float.RGBA32F_EXT:Ri.RGBA;case yo.U8_R_NORM:return Ri.R8;case yo.U8_RG_NORM:return Ri.RG8;case yo.U8_RGB_NORM:case yo.U8_RGB_RT:return Ri.RGB8;case yo.U8_RGB_SRGB:return Ri.SRGB8;case yo.U8_RGBA_NORM:case yo.U8_RGBA_RT:return _f(this.gl)?Ri.RGBA8:r?Ri.RGBA4:Ri.RGBA;case yo.U8_RGBA:return Ri.RGBA;case yo.U8_RGBA_SRGB:case yo.U8_RGBA_RT_SRGB:return Ri.SRGB8_ALPHA8;case yo.U16_R:return Ri.R16UI;case yo.U16_R_NORM:return this.EXT_texture_norm16.R16_EXT;case yo.U16_RG_NORM:return this.EXT_texture_norm16.RG16_EXT;case yo.U16_RGBA_NORM:return this.EXT_texture_norm16.RGBA16_EXT;case yo.U16_RGBA_5551:return Ri.RGB5_A1;case yo.U16_RGB_565:return Ri.RGB565;case yo.U32_R:return Ri.R32UI;case yo.S8_RGBA_NORM:return Ri.RGBA8_SNORM;case yo.S8_RG_NORM:return Ri.RG8_SNORM;case yo.BC1:return this.WEBGL_compressed_texture_s3tc.COMPRESSED_RGBA_S3TC_DXT1_EXT;case yo.BC1_SRGB:return this.WEBGL_compressed_texture_s3tc_srgb.COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT;case yo.BC2:return this.WEBGL_compressed_texture_s3tc.COMPRESSED_RGBA_S3TC_DXT3_EXT;case yo.BC2_SRGB:return this.WEBGL_compressed_texture_s3tc_srgb.COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT;case yo.BC3:return this.WEBGL_compressed_texture_s3tc.COMPRESSED_RGBA_S3TC_DXT5_EXT;case yo.BC3_SRGB:return this.WEBGL_compressed_texture_s3tc_srgb.COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT;case yo.BC4_UNORM:return this.EXT_texture_compression_rgtc.COMPRESSED_RED_RGTC1_EXT;case yo.BC4_SNORM:return this.EXT_texture_compression_rgtc.COMPRESSED_SIGNED_RED_RGTC1_EXT;case yo.BC5_UNORM:return this.EXT_texture_compression_rgtc.COMPRESSED_RED_GREEN_RGTC2_EXT;case yo.BC5_SNORM:return this.EXT_texture_compression_rgtc.COMPRESSED_SIGNED_RED_GREEN_RGTC2_EXT;case yo.D32F_S8:return _f(this.gl)?Ri.DEPTH32F_STENCIL8:this.WEBGL_depth_texture?Ri.DEPTH_STENCIL:Ri.DEPTH_COMPONENT16;case yo.D24_S8:return _f(this.gl)?Ri.DEPTH24_STENCIL8:this.WEBGL_depth_texture?Ri.DEPTH_STENCIL:Ri.DEPTH_COMPONENT16;case yo.D32F:return _f(this.gl)?Ri.DEPTH_COMPONENT32F:this.WEBGL_depth_texture?Ri.DEPTH_COMPONENT:Ri.DEPTH_COMPONENT16;case yo.D24:return _f(this.gl)?Ri.DEPTH_COMPONENT24:this.WEBGL_depth_texture?Ri.DEPTH_COMPONENT:Ri.DEPTH_COMPONENT16;default:throw new Error("whoops")}},e.prototype.translateTextureType=function(i){var r=vg(i);switch(r){case Hs.U8:return Ri.UNSIGNED_BYTE;case Hs.U16:return Ri.UNSIGNED_SHORT;case Hs.U32:return Ri.UNSIGNED_INT;case Hs.S8:return Ri.BYTE;case Hs.F16:return Ri.HALF_FLOAT;case Hs.F32:return Ri.FLOAT;case Hs.U16_PACKED_5551:return Ri.UNSIGNED_SHORT_5_5_5_1;case Hs.D32F:return _f(this.gl)?Ri.FLOAT:this.WEBGL_depth_texture?Ri.UNSIGNED_INT:Ri.UNSIGNED_BYTE;case Hs.D24:return _f(this.gl)?Ri.UNSIGNED_INT_24_8:this.WEBGL_depth_texture?Ri.UNSIGNED_SHORT:Ri.UNSIGNED_BYTE;case Hs.D24S8:return _f(this.gl)?Ri.UNSIGNED_INT_24_8:this.WEBGL_depth_texture?Ri.UNSIGNED_INT_24_8_WEBGL:Ri.UNSIGNED_BYTE;case Hs.D32FS8:return Ri.FLOAT_32_UNSIGNED_INT_24_8_REV;default:throw new Error("whoops")}},e.prototype.translateInternalTextureFormat=function(i){switch(i){case yo.F32_R:return Ri.R32F;case yo.F32_RG:return Ri.RG32F;case yo.F32_RGB:return Ri.RGB32F;case yo.F32_RGBA:return Ri.RGBA32F;case yo.F16_R:return Ri.R16F;case yo.F16_RG:return Ri.RG16F;case yo.F16_RGB:return Ri.RGB16F;case yo.F16_RGBA:return Ri.RGBA16F}return this.translateTextureFormat(i)},e.prototype.translateTextureFormat=function(i){if(nM(i)||i===yo.F32_LUMINANCE||i===yo.U8_LUMINANCE)return this.translateTextureInternalFormat(i);var r=_f(this.gl)||!_f(this.gl)&&!!this.WEBGL_depth_texture;switch(i){case yo.D24_S8:case yo.D32F_S8:return r?Ri.DEPTH_STENCIL:Ri.RGBA;case yo.D24:case yo.D32F:return r?Ri.DEPTH_COMPONENT:Ri.RGBA}var n=iM(i),t=d2(i);switch(t){case ef.A:return Ri.ALPHA;case ef.R:return n?Ri.RED_INTEGER:Ri.RED;case ef.RG:return n?Ri.RG_INTEGER:Ri.RG;case ef.RGB:return n?Ri.RGB_INTEGER:Ri.RGB;case ef.RGBA:return Ri.RGBA}},e.prototype.setActiveTexture=function(i){this.currentActiveTexture!==i&&(this.gl.activeTexture(i),this.currentActiveTexture=i)},e.prototype.bindVAO=function(i){this.currentBoundVAO!==i&&(_f(this.gl)?this.gl.bindVertexArray(i):this.OES_vertex_array_object.bindVertexArrayOES(i),this.currentBoundVAO=i)},e.prototype.programCompiled=function(i){rd(i.compileState!==vv.NeedsCompile),i.compileState===vv.Compiling&&(i.compileState=vv.NeedsBind,this.shaderDebug&&this.checkProgramCompilationForErrors(i))},e.prototype.useProgram=function(i){this.currentProgram!==i&&(this.programCompiled(i),this.gl.useProgram(i.gl_program),this.currentProgram=i)},e.prototype.ensureResourceExists=function(i){if(i===null){var r=this.gl.getError();throw new Error("Created resource is null; GL error encountered: ".concat(r))}else return i},e.prototype.createBuffer=function(i){return new dU({id:this.getNextUniqueId(),device:this,descriptor:i})},e.prototype.createTexture=function(i){return new Kw({id:this.getNextUniqueId(),device:this,descriptor:i})},e.prototype.createSampler=function(i){return new xU({id:this.getNextUniqueId(),device:this,descriptor:i})},e.prototype.createRenderTarget=function(i){return new mU({id:this.getNextUniqueId(),device:this,descriptor:i})},e.prototype.createRenderTargetFromTexture=function(i){var r=i,n=r.format,t=r.width,a=r.height,u=r.mipLevelCount;return rd(u===1),this.createRenderTarget({format:n,width:t,height:a,sampleCount:1,texture:i})},e.prototype.createProgram=function(i){var r,n,t,a=(r=i.vertex)===null||r===void 0?void 0:r.glsl;return!((n=i.vertex)===null||n===void 0)&&n.glsl&&(i.vertex.glsl=Ty(this.queryVendorInfo(),"vert",i.vertex.glsl)),!((t=i.fragment)===null||t===void 0)&&t.glsl&&(i.fragment.glsl=Ty(this.queryVendorInfo(),"frag",i.fragment.glsl)),this.createProgramSimple(i,a)},e.prototype.createProgramSimple=function(i,r){var n=new vU({id:this.getNextUniqueId(),device:this,descriptor:i},r);return n},e.prototype.createBindings=function(i){return new iU({id:this.getNextUniqueId(),device:this,descriptor:i})},e.prototype.createInputLayout=function(i){return new pU({id:this.getNextUniqueId(),device:this,descriptor:i})},e.prototype.createRenderPipeline=function(i){return new _U({id:this.getNextUniqueId(),device:this,descriptor:i})},e.prototype.createComputePass=function(){return new wU},e.prototype.createComputePipeline=function(i){return new AU({id:this.getNextUniqueId(),device:this,descriptor:i})},e.prototype.createReadback=function(){return new yU({id:this.getNextUniqueId(),device:this})},e.prototype.createQueryPool=function(i,r){return new gU({id:this.getNextUniqueId(),device:this,descriptor:{type:i,elemCount:r}})},e.prototype.formatRenderPassDescriptor=function(i){var r,n,t,a,u,c,m=i.colorAttachment;i.depthClearValue=(r=i.depthClearValue)!==null&&r!==void 0?r:"load",i.stencilClearValue=(n=i.stencilClearValue)!==null&&n!==void 0?n:"load";for(var E=0;E=0;r--)this.debugGroupStack[r].drawCallCount+=i},e.prototype.debugGroupStatisticsBufferUpload=function(i){i===void 0&&(i=1);for(var r=this.debugGroupStack.length-1;r>=0;r--)this.debugGroupStack[r].bufferUploadCount+=i},e.prototype.debugGroupStatisticsTextureBind=function(i){i===void 0&&(i=1);for(var r=this.debugGroupStack.length-1;r>=0;r--)this.debugGroupStack[r].textureBindCount+=i},e.prototype.debugGroupStatisticsTriangles=function(i){for(var r=this.debugGroupStack.length-1;r>=0;r--)this.debugGroupStack[r].triangleCount+=i},e.prototype.reportShaderError=function(i,r){var n=this.gl,t=n.getShaderParameter(i,n.COMPILE_STATUS);if(!t){console.error(SZ(r));var a=n.getExtension("WEBGL_debug_shaders");a&&console.error(a.getTranslatedShaderSource(i)),console.error(n.getShaderInfoLog(i))}return t},e.prototype.checkProgramCompilationForErrors=function(i){var r=this.gl,n=i.gl_program;if(!r.getProgramParameter(n,r.LINK_STATUS)){var t=i.descriptor;if(!this.reportShaderError(i.gl_shader_vert,t.vertex.glsl)||!this.reportShaderError(i.gl_shader_frag,t.fragment.glsl))return;console.error(r.getProgramInfoLog(i.gl_program))}},e.prototype.bindFramebufferAttachment=function(i,r,n,t){var a=this.gl;if(Fv(n))a.framebufferRenderbuffer(i,r,a.RENDERBUFFER,null);else if(n.type===vp.RenderTarget)n.gl_renderbuffer!==null?a.framebufferRenderbuffer(i,r,a.RENDERBUFFER,n.gl_renderbuffer):n.texture!==null&&a.framebufferTexture2D(i,r,Ri.TEXTURE_2D,u_(n.texture),t);else if(n.type===vp.Texture){var u=u_(n);n.dimension===Pd.TEXTURE_2D?a.framebufferTexture2D(i,r,Ri.TEXTURE_2D,u,t):_f(a)&&(n.dimension,Pd.TEXTURE_2D_ARRAY)}},e.prototype.bindFramebufferDepthStencilAttachment=function(i,r){var n=this.gl,t=Fv(r)?fc.Depth|fc.Stencil:r_(r.format),a=!!(t&fc.Depth),u=!!(t&fc.Stencil);if(a&&u){var c=_f(this.gl)||!_f(this.gl)&&!!this.WEBGL_depth_texture;c?this.bindFramebufferAttachment(i,n.DEPTH_STENCIL_ATTACHMENT,r,0):this.bindFramebufferAttachment(i,n.DEPTH_ATTACHMENT,r,0)}else a?(this.bindFramebufferAttachment(i,n.DEPTH_ATTACHMENT,r,0),this.bindFramebufferAttachment(i,n.STENCIL_ATTACHMENT,null,0)):u&&(this.bindFramebufferAttachment(i,n.STENCIL_ATTACHMENT,r,0),this.bindFramebufferAttachment(i,n.DEPTH_ATTACHMENT,null,0))},e.prototype.validateCurrentAttachments=function(){for(var i=-1,r=-1,n=-1,t=0;t=E.numUniformBuffers),rd(c.length>=E.numSamplers);for(var H=0;H{throw Error("TextDecoder not available")}};typeof TextDecoder!="undefined"&&uM.decode();let fA=null;function b2(){return(fA===null||fA.byteLength===0)&&(fA=new Uint8Array(Cm.memory.buffer)),fA}function x2(e,i){return e=e>>>0,uM.decode(b2().subarray(e,e+i))}const Xg=new Array(128).fill(void 0);Xg.push(void 0,null,!0,!1);let hA=Xg.length;function MU(e){hA===Xg.length&&Xg.push(Xg.length+1);const i=hA;return hA=Xg[i],Xg[i]=e,i}function w2(e){return Xg[e]}function PU(e){e<132||(Xg[e]=hA,hA=e)}function IU(e){const i=w2(e);return PU(e),i}let dA=0;const E2=typeof TextEncoder!="undefined"?new TextEncoder("utf-8"):{encode:()=>{throw Error("TextEncoder not available")}},RU=typeof E2.encodeInto=="function"?function(e,i){return E2.encodeInto(e,i)}:function(e,i){const r=E2.encode(e);return i.set(r),{read:e.length,written:r.length}};function qw(e,i,r){if(r===void 0){const c=E2.encode(e),m=i(c.length,1)>>>0;return b2().subarray(m,m+c.length).set(c),dA=c.length,m}let n=e.length,t=i(n,1)>>>0;const a=b2();let u=0;for(;u127)break;a[t+u]=c}if(u!==n){u!==0&&(e=e.slice(u)),t=r(t,n,n=u+e.length*3,1)>>>0;const c=b2().subarray(t+u,t+n),m=RU(e,c);u+=m.written}return dA=u,t}let pA=null;function S2(){return(pA===null||pA.byteLength===0)&&(pA=new Int32Array(Cm.memory.buffer)),pA}function OU(e,i,r){let n,t;try{const c=Cm.__wbindgen_add_to_stack_pointer(-16),m=qw(e,Cm.__wbindgen_malloc,Cm.__wbindgen_realloc),E=dA,H=qw(i,Cm.__wbindgen_malloc,Cm.__wbindgen_realloc),re=dA;Cm.glsl_compile(c,m,E,H,re,r);var a=S2()[c/4+0],u=S2()[c/4+1];return n=a,t=u,x2(a,u)}finally{Cm.__wbindgen_add_to_stack_pointer(16),Cm.__wbindgen_free(n,t,1)}}class mA{static __wrap(i){i=i>>>0;const r=Object.create(mA.prototype);return r.__wbg_ptr=i,r}__destroy_into_raw(){const i=this.__wbg_ptr;return this.__wbg_ptr=0,i}free(){const i=this.__destroy_into_raw();Cm.__wbg_wgslcomposer_free(i)}constructor(){const i=Cm.wgslcomposer_new();return mA.__wrap(i)}wgsl_compile(i){let r,n;try{const u=Cm.__wbindgen_add_to_stack_pointer(-16),c=qw(i,Cm.__wbindgen_malloc,Cm.__wbindgen_realloc),m=dA;Cm.wgslcomposer_wgsl_compile(u,this.__wbg_ptr,c,m);var t=S2()[u/4+0],a=S2()[u/4+1];return r=t,n=a,x2(t,a)}finally{Cm.__wbindgen_add_to_stack_pointer(16),Cm.__wbindgen_free(r,n,1)}}}function LU(e,i){return m_(this,null,function*(){if(typeof Response=="function"&&e instanceof Response){if(typeof WebAssembly.instantiateStreaming=="function")try{return yield WebAssembly.instantiateStreaming(e,i)}catch(n){if(e.headers.get("Content-Type")!="application/wasm")console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",n);else throw n}const r=yield e.arrayBuffer();return yield WebAssembly.instantiate(r,i)}else{const r=yield WebAssembly.instantiate(e,i);return r instanceof WebAssembly.Instance?{instance:r,module:e}:r}})}function DU(){const e={};return e.wbg={},e.wbg.__wbindgen_string_new=function(i,r){const n=x2(i,r);return MU(n)},e.wbg.__wbindgen_object_drop_ref=function(i){IU(i)},e.wbg.__wbg_log_1d3ae0273d8f4f8a=function(i){console.log(w2(i))},e.wbg.__wbg_log_576ca876af0d4a77=function(i,r){console.log(w2(i),w2(r))},e.wbg.__wbindgen_throw=function(i,r){throw new Error(x2(i,r))},e}function kU(e,i){return Cm=e.exports,lM.__wbindgen_wasm_module=i,pA=null,fA=null,Cm}function lM(e){return m_(this,null,function*(){if(Cm!==void 0)return Cm;const i=DU();(typeof e=="string"||typeof Request=="function"&&e instanceof Request||typeof URL=="function"&&e instanceof URL)&&(e=fetch(e));const{instance:r,module:n}=yield LU(yield e,i);return kU(r,n)})}var km;(function(e){e[e.COPY_SRC=1]="COPY_SRC",e[e.COPY_DST=2]="COPY_DST",e[e.TEXTURE_BINDING=4]="TEXTURE_BINDING",e[e.STORAGE_BINDING=8]="STORAGE_BINDING",e[e.STORAGE=8]="STORAGE",e[e.RENDER_ATTACHMENT=16]="RENDER_ATTACHMENT"})(km||(km={}));var Qw;(function(e){e[e.READ=1]="READ",e[e.WRITE=2]="WRITE"})(Qw||(Qw={}));function FU(e){var i=0;return e&Ym.SAMPLED&&(i|=km.TEXTURE_BINDING|km.COPY_DST|km.COPY_SRC),e&Ym.STORAGE&&(i|=km.TEXTURE_BINDING|km.STORAGE_BINDING|km.COPY_SRC|km.COPY_DST),e&Ym.RENDER_TARGET&&(i|=km.RENDER_ATTACHMENT|km.TEXTURE_BINDING|km.COPY_SRC|km.COPY_DST),i}function Jw(e){if(e===yo.U8_R_NORM)return"r8unorm";if(e===yo.S8_R_NORM)return"r8snorm";if(e===yo.U8_RG_NORM)return"rg8unorm";if(e===yo.S8_RG_NORM)return"rg8snorm";if(e===yo.U32_R)return"r32uint";if(e===yo.S32_R)return"r32sint";if(e===yo.F32_R)return"r32float";if(e===yo.U16_RG)return"rg16uint";if(e===yo.S16_RG)return"rg16sint";if(e===yo.F16_RG)return"rg16float";if(e===yo.U8_RGBA_RT)return"bgra8unorm";if(e===yo.U8_RGBA_RT_SRGB)return"bgra8unorm-srgb";if(e===yo.U8_RGBA_NORM)return"rgba8unorm";if(e===yo.U8_RGBA_SRGB)return"rgba8unorm-srgb";if(e===yo.S8_RGBA_NORM)return"rgba8snorm";if(e===yo.F32_RGB)return"rgb9e5ufloat";if(e===yo.U32_RG)return"rg32uint";if(e===yo.S32_RG)return"rg32sint";if(e===yo.F32_RG)return"rg32float";if(e===yo.U16_RGBA)return"rgba16uint";if(e===yo.S16_RGBA)return"rgba16sint";if(e===yo.F16_RGBA)return"rgba16float";if(e===yo.F32_RGBA)return"rgba32float";if(e===yo.U32_RGBA)return"rgba32uint";if(e===yo.S32_RGBA)return"rgba32sint";if(e===yo.D24)return"depth24plus";if(e===yo.D24_S8)return"depth24plus-stencil8";if(e===yo.D32F)return"depth32float";if(e===yo.D32F_S8)return"depth32float-stencil8";if(e===yo.BC1)return"bc1-rgba-unorm";if(e===yo.BC1_SRGB)return"bc1-rgba-unorm-srgb";if(e===yo.BC2)return"bc2-rgba-unorm";if(e===yo.BC2_SRGB)return"bc2-rgba-unorm-srgb";if(e===yo.BC3)return"bc3-rgba-unorm";if(e===yo.BC3_SRGB)return"bc3-rgba-unorm-srgb";if(e===yo.BC4_SNORM)return"bc4-r-snorm";if(e===yo.BC4_UNORM)return"bc4-r-unorm";if(e===yo.BC5_SNORM)return"bc5-rg-snorm";if(e===yo.BC5_UNORM)return"bc5-rg-unorm";throw"whoops"}function BU(e){if(e===Pd.TEXTURE_2D)return"2d";if(e===Pd.TEXTURE_CUBE_MAP)return"2d";if(e===Pd.TEXTURE_2D_ARRAY)return"2d";if(e===Pd.TEXTURE_3D)return"3d";throw new Error("whoops")}function NU(e){if(e===Pd.TEXTURE_2D)return"2d";if(e===Pd.TEXTURE_CUBE_MAP)return"cube";if(e===Pd.TEXTURE_2D_ARRAY)return"2d-array";if(e===Pd.TEXTURE_3D)return"3d";throw new Error("whoops")}function zU(e){var i=0;return e&h0.INDEX&&(i|=GPUBufferUsage.INDEX),e&h0.VERTEX&&(i|=GPUBufferUsage.VERTEX),e&h0.UNIFORM&&(i|=GPUBufferUsage.UNIFORM),e&h0.STORAGE&&(i|=GPUBufferUsage.STORAGE),e&h0.COPY_SRC&&(i|=GPUBufferUsage.COPY_SRC),e&h0.INDIRECT&&(i|=GPUBufferUsage.INDIRECT),i|=GPUBufferUsage.COPY_DST,i}function eE(e){if(e===sv.CLAMP_TO_EDGE)return"clamp-to-edge";if(e===sv.REPEAT)return"repeat";if(e===sv.MIRRORED_REPEAT)return"mirror-repeat";throw new Error("whoops")}function cM(e){if(e===fm.BILINEAR)return"linear";if(e===fm.POINT)return"nearest";throw new Error("whoops")}function ZU(e){if(e===Dm.LINEAR)return"linear";if(e===Dm.NEAREST)return"nearest";if(e===Dm.NO_MIP)return"nearest";throw new Error("whoops")}function l_(e){var i=e;return i.gpuBuffer}function UU(e){var i=e;return i.gpuSampler}function jU(e){var i=e;return i.querySet}function VU(e){if(e===h2.OcclusionConservative)return"occlusion";throw new Error("whoops")}function $U(e){switch(e){case Sm.TRIANGLES:return"triangle-list";case Sm.POINTS:return"point-list";case Sm.TRIANGLE_STRIP:return"triangle-strip";case Sm.LINES:return"line-list";case Sm.LINE_STRIP:return"line-strip";default:throw new Error("Unknown primitive topology mode")}}function HU(e){if(e===mv.NONE)return"none";if(e===mv.FRONT)return"front";if(e===mv.BACK)return"back";throw new Error("whoops")}function GU(e){if(e===aA.CCW)return"ccw";if(e===aA.CW)return"cw";throw new Error("whoops")}function WU(e,i){return{topology:$U(e),cullMode:HU(i.cullMode),frontFace:GU(i.frontFace)}}function fM(e){if(e===Dd.ZERO)return"zero";if(e===Dd.ONE)return"one";if(e===Dd.SRC)return"src";if(e===Dd.ONE_MINUS_SRC)return"one-minus-src";if(e===Dd.DST)return"dst";if(e===Dd.ONE_MINUS_DST)return"one-minus-dst";if(e===Dd.SRC_ALPHA)return"src-alpha";if(e===Dd.ONE_MINUS_SRC_ALPHA)return"one-minus-src-alpha";if(e===Dd.DST_ALPHA)return"dst-alpha";if(e===Dd.ONE_MINUS_DST_ALPHA)return"one-minus-dst-alpha";if(e===Dd.CONST)return"constant";if(e===Dd.ONE_MINUS_CONSTANT)return"one-minus-constant";if(e===Dd.SRC_ALPHA_SATURATE)return"src-alpha-saturated";throw new Error("whoops")}function XU(e){if(e===Zm.ADD)return"add";if(e===Zm.SUBSTRACT)return"subtract";if(e===Zm.REVERSE_SUBSTRACT)return"reverse-subtract";if(e===Zm.MIN)return"min";if(e===Zm.MAX)return"max";throw new Error("whoops")}function hM(e){return{operation:XU(e.blendMode),srcFactor:fM(e.blendSrcFactor),dstFactor:fM(e.blendDstFactor)}}function dM(e){return e.blendMode===Zm.ADD&&e.blendSrcFactor===Dd.ONE&&e.blendDstFactor===Dd.ZERO}function YU(e){if(!(dM(e.rgbBlendState)&&dM(e.alphaBlendState)))return{color:hM(e.rgbBlendState),alpha:hM(e.alphaBlendState)}}function KU(e,i){return{format:Jw(i),blend:YU(e),writeMask:e.channelWriteMask}}function qU(e,i){return i.attachmentsState.map(function(r,n){return KU(r,e[n])})}function C2(e){if(e===Ad.NEVER)return"never";if(e===Ad.LESS)return"less";if(e===Ad.EQUAL)return"equal";if(e===Ad.LEQUAL)return"less-equal";if(e===Ad.GREATER)return"greater";if(e===Ad.NOTEQUAL)return"not-equal";if(e===Ad.GEQUAL)return"greater-equal";if(e===Ad.ALWAYS)return"always";throw new Error("whoops")}function c_(e){if(e===im.KEEP)return"keep";if(e===im.REPLACE)return"replace";if(e===im.ZERO)return"zero";if(e===im.DECREMENT_CLAMP)return"decrement-clamp";if(e===im.DECREMENT_WRAP)return"decrement-wrap";if(e===im.INCREMENT_CLAMP)return"increment-clamp";if(e===im.INCREMENT_WRAP)return"increment-wrap";if(e===im.INVERT)return"invert";throw new Error("whoops")}function QU(e,i){if(!Fv(e))return{format:Jw(e),depthWriteEnabled:!!i.depthWrite,depthCompare:C2(i.depthCompare),depthBias:i.polygonOffset?1:0,depthBiasSlopeScale:i.polygonOffset?1:0,stencilFront:{compare:C2(i.stencilFront.compare),passOp:c_(i.stencilFront.passOp),failOp:c_(i.stencilFront.failOp),depthFailOp:c_(i.stencilFront.depthFailOp)},stencilBack:{compare:C2(i.stencilBack.compare),passOp:c_(i.stencilBack.passOp),failOp:c_(i.stencilBack.failOp),depthFailOp:c_(i.stencilBack.depthFailOp)},stencilReadMask:1,stencilWriteMask:1}}function JU(e){if(e!==null){if(e===yo.U16_R)return"uint16";if(e===yo.U32_R)return"uint32";throw new Error("whoops")}}function ej(e){if(e===s1.VERTEX)return"vertex";if(e===s1.INSTANCE)return"instance";throw new Error("whoops")}function tj(e){if(e===yo.U8_R)return"uint8x2";if(e===yo.U8_RG)return"uint8x2";if(e===yo.U8_RGB)return"uint8x4";if(e===yo.U8_RGBA)return"uint8x4";if(e===yo.U8_RG_NORM)return"unorm8x2";if(e===yo.U8_RGBA_NORM)return"unorm8x4";if(e===yo.S8_RGB_NORM)return"snorm8x4";if(e===yo.S8_RGBA_NORM)return"snorm8x4";if(e===yo.U16_RG_NORM)return"unorm16x2";if(e===yo.U16_RGBA_NORM)return"unorm16x4";if(e===yo.S16_RG_NORM)return"snorm16x2";if(e===yo.S16_RGBA_NORM)return"snorm16x4";if(e===yo.S16_RG)return"uint16x2";if(e===yo.F16_RG)return"float16x2";if(e===yo.F16_RGBA)return"float16x4";if(e===yo.F32_R)return"float32";if(e===yo.F32_RG)return"float32x2";if(e===yo.F32_RGB)return"float32x3";if(e===yo.F32_RGBA)return"float32x4";throw"whoops"}function rj(e){var i=vg(e);switch(i){case Hs.BC1:case Hs.BC2:case Hs.BC3:case Hs.BC4_SNORM:case Hs.BC4_UNORM:case Hs.BC5_SNORM:case Hs.BC5_UNORM:return!0;default:return!1}}function nj(e){var i=vg(e);switch(i){case Hs.BC1:case Hs.BC2:case Hs.BC3:case Hs.BC4_SNORM:case Hs.BC4_UNORM:case Hs.BC5_SNORM:case Hs.BC5_UNORM:return 4;default:return 1}}function pM(e,i,r,n){switch(r===void 0&&(r=!1),e){case yo.S8_R:case yo.S8_R_NORM:case yo.S8_RG_NORM:case yo.S8_RGB_NORM:case yo.S8_RGBA_NORM:{var t=i instanceof ArrayBuffer?new Int8Array(i):new Int8Array(i);return n&&t.set(new Int8Array(n)),t}case yo.U8_R:case yo.U8_R_NORM:case yo.U8_RG:case yo.U8_RG_NORM:case yo.U8_RGB:case yo.U8_RGB_NORM:case yo.U8_RGB_SRGB:case yo.U8_RGBA:case yo.U8_RGBA_NORM:case yo.U8_RGBA_SRGB:{var a=i instanceof ArrayBuffer?new Uint8Array(i):new Uint8Array(i);return n&&a.set(new Uint8Array(n)),a}case yo.S16_R:case yo.S16_RG:case yo.S16_RG_NORM:case yo.S16_RGB_NORM:case yo.S16_RGBA:case yo.S16_RGBA_NORM:{var u=i instanceof ArrayBuffer?new Int16Array(i):new Int16Array(r?i/2:i);return n&&u.set(new Int16Array(n)),u}case yo.U16_R:case yo.U16_RGB:case yo.U16_RGBA_5551:case yo.U16_RGBA_NORM:case yo.U16_RG_NORM:case yo.U16_R_NORM:{var c=i instanceof ArrayBuffer?new Uint16Array(i):new Uint16Array(r?i/2:i);return n&&c.set(new Uint16Array(n)),c}case yo.S32_R:{var m=i instanceof ArrayBuffer?new Int32Array(i):new Int32Array(r?i/4:i);return n&&m.set(new Int32Array(n)),m}case yo.U32_R:case yo.U32_RG:{var E=i instanceof ArrayBuffer?new Uint32Array(i):new Uint32Array(r?i/4:i);return n&&E.set(new Uint32Array(n)),E}case yo.F32_R:case yo.F32_RG:case yo.F32_RGB:case yo.F32_RGBA:{var H=i instanceof ArrayBuffer?new Float32Array(i):new Float32Array(r?i/4:i);return n&&H.set(new Float32Array(n)),H}}var re=i instanceof ArrayBuffer?new Uint8Array(i):new Uint8Array(i);return n&&re.set(new Uint8Array(n)),re}function ij(e){var i=(e&32768)>>15,r=(e&31744)>>10,n=e&1023;return r===0?(i?-1:1)*Math.pow(2,-14)*(n/Math.pow(2,10)):r==31?n?NaN:(i?-1:1)*(1/0):(i?-1:1)*Math.pow(2,r-15)*(1+n/Math.pow(2,10))}function mM(e){switch(e){case"r8unorm":case"r8snorm":case"r8uint":case"r8sint":return{width:1,height:1,length:1};case"r16uint":case"r16sint":case"r16float":case"rg8unorm":case"rg8snorm":case"rg8uint":case"rg8sint":return{width:1,height:1,length:2};case"r32uint":case"r32sint":case"r32float":case"rg16uint":case"rg16sint":case"rg16float":case"rgba8unorm":case"rgba8unorm-srgb":case"rgba8snorm":case"rgba8uint":case"rgba8sint":case"bgra8unorm":case"bgra8unorm-srgb":case"rgb9e5ufloat":case"rgb10a2unorm":case"rg11b10ufloat":return{width:1,height:1,length:4};case"rg32uint":case"rg32sint":case"rg32float":case"rgba16uint":case"rgba16sint":case"rgba16float":return{width:1,height:1,length:8};case"rgba32uint":case"rgba32sint":case"rgba32float":return{width:1,height:1,length:16};case"stencil8":throw new Error("No fixed size for Stencil8 format!");case"depth16unorm":return{width:1,height:1,length:2};case"depth24plus":throw new Error("No fixed size for Depth24Plus format!");case"depth24plus-stencil8":throw new Error("No fixed size for Depth24PlusStencil8 format!");case"depth32float":return{width:1,height:1,length:4};case"depth32float-stencil8":return{width:1,height:1,length:5};case"bc7-rgba-unorm":case"bc7-rgba-unorm-srgb":case"bc6h-rgb-ufloat":case"bc6h-rgb-float":case"bc2-rgba-unorm":case"bc2-rgba-unorm-srgb":case"bc3-rgba-unorm":case"bc3-rgba-unorm-srgb":case"bc5-rg-unorm":case"bc5-rg-snorm":return{width:4,height:4,length:16};case"bc4-r-unorm":case"bc4-r-snorm":case"bc1-rgba-unorm":case"bc1-rgba-unorm-srgb":return{width:4,height:4,length:8};default:return{width:1,height:1,length:4}}}var Kv=function(e){(0,kc.ZT)(i,e);function i(r){var n=r.id,t=r.device,a=e.call(this)||this;return a.id=n,a.device=t,a}return i.prototype.destroy=function(){},i}(N5),oj=function(e){(0,kc.ZT)(i,e);function i(r){var n=r.id,t=r.device,a=r.descriptor,u,c,m=e.call(this,{id:n,device:t})||this;m.type=vp.Bindings;var E=a.pipeline;rd(!!E);var H=a.uniformBufferBindings,re=a.storageBufferBindings,xe=a.samplerBindings,ke=a.storageTextureBindings;m.numUniformBuffers=(H==null?void 0:H.length)||0;var rt=[[],[],[],[]],vt=0;if(H&&H.length)for(var It=0;Itre;)this.device.device.queue.writeBuffer(u,r+xe,n.buffer,c+xe,re),xe+=re;this.device.device.queue.writeBuffer(u,r+xe,n.buffer,c+xe,a-xe)},i.prototype.destroy=function(){e.prototype.destroy.call(this),this.gpuBuffer.destroy()},i}(Kv),vM=function(){function e(){this.gpuComputePassEncoder=null}return e.prototype.dispatchWorkgroups=function(i,r,n){this.gpuComputePassEncoder.dispatchWorkgroups(i,r,n)},e.prototype.dispatchWorkgroupsIndirect=function(i,r){this.gpuComputePassEncoder.dispatchWorkgroupsIndirect(i.gpuBuffer,r)},e.prototype.finish=function(){this.gpuComputePassEncoder.end(),this.gpuComputePassEncoder=null,this.frameCommandEncoder=null},e.prototype.beginComputePass=function(i){rd(this.gpuComputePassEncoder===null),this.frameCommandEncoder=i,this.gpuComputePassEncoder=this.frameCommandEncoder.beginComputePass(this.gpuComputePassDescriptor)},e.prototype.setPipeline=function(i){var r=i,n=u1(r.gpuComputePipeline);this.gpuComputePassEncoder.setPipeline(n)},e.prototype.setBindings=function(i){var r=this,n=i;n.gpuBindGroup.forEach(function(t,a){t&&r.gpuComputePassEncoder.setBindGroup(a,n.gpuBindGroup[a])})},e.prototype.pushDebugGroup=function(i){this.gpuComputePassEncoder.pushDebugGroup(i)},e.prototype.popDebugGroup=function(){this.gpuComputePassEncoder.popDebugGroup()},e.prototype.insertDebugMarker=function(i){this.gpuComputePassEncoder.insertDebugMarker(i)},e}(),sj=function(e){(0,kc.ZT)(i,e);function i(r){var n=r.id,t=r.device,a=r.descriptor,u=e.call(this,{id:n,device:t})||this;u.type=vp.ComputePipeline,u.gpuComputePipeline=null,u.descriptor=a;var c=a.program,m=c.computeStage;if(m===null)return u;var E={layout:"auto",compute:(0,kc.pi)({},m)};return u.gpuComputePipeline=u.device.device.createComputePipeline(E),u.name!==void 0&&(u.gpuComputePipeline.label=u.name),u}return i.prototype.getBindGroupLayout=function(r){return this.gpuComputePipeline.getBindGroupLayout(r)},i}(Kv),uj=function(e){(0,kc.ZT)(i,e);function i(r){var n,t,a,u,c=r.id,m=r.device,E=r.descriptor,H=e.call(this,{id:c,device:m})||this;H.type=vp.InputLayout;var re=[];try{for(var xe=(0,kc.XA)(E.vertexBufferDescriptors),ke=xe.next();!ke.done;ke=xe.next()){var rt=ke.value,vt=rt.arrayStride,It=rt.stepMode,er=rt.attributes;re.push({arrayStride:vt,stepMode:ej(It),attributes:[]});try{for(var Ar=(a=void 0,(0,kc.XA)(er)),Or=Ar.next();!Or.done;Or=Ar.next()){var rn=Or.value,Ln=rn.shaderLocation,wn=rn.format,Cn=rn.offset;re[re.length-1].attributes.push({shaderLocation:Ln,format:tj(wn),offset:Cn})}}catch(qn){a={error:qn}}finally{try{Or&&!Or.done&&(u=Ar.return)&&u.call(Ar)}finally{if(a)throw a.error}}}}catch(qn){n={error:qn}}finally{try{ke&&!ke.done&&(t=xe.return)&&t.call(xe)}finally{if(n)throw n.error}}return H.indexFormat=JU(E.indexBufferFormat),H.buffers=re,H}return i}(Kv),gM=function(e){(0,kc.ZT)(i,e);function i(r){var n=r.id,t=r.device,a=r.descriptor,u=e.call(this,{id:n,device:t})||this;return u.type=vp.Program,u.vertexStage=null,u.fragmentStage=null,u.computeStage=null,u.descriptor=a,a.vertex&&(u.vertexStage=u.createShaderStage(a.vertex,"vertex")),a.fragment&&(u.fragmentStage=u.createShaderStage(a.fragment,"fragment")),a.compute&&(u.computeStage=u.createShaderStage(a.compute,"compute")),u}return i.prototype.setUniformsLegacy=function(r){},i.prototype.createShaderStage=function(r,n){var t,a,u=r.glsl,c=r.wgsl,m=r.entryPoint,E=r.postprocess,H=!1,re=c;if(!re)try{re=this.device.glsl_compile(u,n,H)}catch(er){throw console.error(er,u),new Error("whoops")}var xe=function(er){if(!re.includes(er))return"continue";re=re.replace("var T_".concat(er,": texture_2d;"),"var T_".concat(er,": texture_depth_2d;")),re=re.replace(new RegExp("textureSample\\(T_".concat(er,"(.*)\\);$"),"gm"),function(Ar,Or){return"vec4(textureSample(T_".concat(er).concat(Or,"), 0.0, 0.0, 0.0);")})};try{for(var ke=(0,kc.XA)(["u_TextureFramebufferDepth"]),rt=ke.next();!rt.done;rt=ke.next()){var vt=rt.value;xe(vt)}}catch(er){t={error:er}}finally{try{rt&&!rt.done&&(a=ke.return)&&a.call(ke)}finally{if(t)throw t.error}}E&&(re=E(re));var It=this.device.device.createShaderModule({code:re});return{module:It,entryPoint:m||"main"}},i}(Kv),lj=function(e){(0,kc.ZT)(i,e);function i(r){var n=r.id,t=r.device,a=r.descriptor,u=e.call(this,{id:n,device:t})||this;u.type=vp.QueryPool;var c=a.elemCount,m=a.type;return u.querySet=u.device.device.createQuerySet({type:VU(m),count:c}),u.resolveBuffer=u.device.device.createBuffer({size:c*8,usage:GPUBufferUsage.QUERY_RESOLVE|GPUBufferUsage.COPY_SRC}),u.cpuBuffer=u.device.device.createBuffer({size:c*8,usage:GPUBufferUsage.COPY_DST|GPUBufferUsage.MAP_READ}),u.results=null,u}return i.prototype.queryResultOcclusion=function(r){return this.results===null?null:this.results[r]!==BigInt(0)},i.prototype.destroy=function(){e.prototype.destroy.call(this),this.querySet.destroy(),this.resolveBuffer.destroy(),this.cpuBuffer.destroy()},i}(Kv),cj=function(e){(0,kc.ZT)(i,e);function i(r){var n=r.id,t=r.device,a=e.call(this,{id:n,device:t})||this;return a.type=vp.Readback,a}return i.prototype.readTexture=function(r,n,t,a,u,c,m,E){return m===void 0&&(m=0),(0,kc.mG)(this,void 0,void 0,function(){var H,re,xe,ke,rt,vt,It,er;return(0,kc.Jh)(this,function(Ar){return H=r,re=0,xe=mM(H.gpuTextureformat),ke=Math.ceil(a/xe.width)*xe.length,rt=Math.ceil(ke/256)*256,vt=rt*u,It=this.device.createBuffer({usage:h0.STORAGE|h0.MAP_READ|h0.COPY_DST,hint:Yv.STATIC,viewOrSize:vt}),er=this.device.device.createCommandEncoder(),er.copyTextureToBuffer({texture:H.gpuTexture,mipLevel:0,origin:{x:n,y:t,z:Math.max(re,0)}},{buffer:It.gpuBuffer,offset:0,bytesPerRow:rt},{width:a,height:u,depthOrArrayLayers:1}),this.device.device.queue.submit([er.finish()]),[2,this.readBuffer(It,0,c.byteLength===vt?c:null,m,vt,H.format,!0,!1,ke,rt,u)]})})},i.prototype.readTextureSync=function(r,n,t,a,u,c,m,E){throw new Error("ERROR_MSG_METHOD_NOT_IMPLEMENTED")},i.prototype.readBuffer=function(r,n,t,a,u,c,m,E,H,re,xe){var ke=this;n===void 0&&(n=0),t===void 0&&(t=null),u===void 0&&(u=0),c===void 0&&(c=yo.U8_RGB),m===void 0&&(m=!1),H===void 0&&(H=0),re===void 0&&(re=0),xe===void 0&&(xe=0);var rt=r,vt=u||rt.size,It=t||rt.view,er=It&&It.constructor&&It.constructor.BYTES_PER_ELEMENT||U5(c),Ar=rt;if(!(rt.usage&h0.MAP_READ&&rt.usage&h0.COPY_DST)){var Or=this.device.device.createCommandEncoder();Ar=this.device.createBuffer({usage:h0.STORAGE|h0.MAP_READ|h0.COPY_DST,hint:Yv.STATIC,viewOrSize:vt}),Or.copyBufferToBuffer(rt.gpuBuffer,n,Ar.gpuBuffer,0,vt),this.device.device.queue.submit([Or.finish()])}return new Promise(function(rn,Ln){Ar.gpuBuffer.mapAsync(Qw.READ,n,vt).then(function(){var wn=Ar.gpuBuffer.getMappedRange(n,vt),Cn=It;if(m)Cn===null?Cn=pM(c,vt,!0,wn):Cn=pM(c,Cn.buffer,void 0,wn);else if(Cn===null)switch(er){case 1:Cn=new Uint8Array(vt),Cn.set(new Uint8Array(wn));break;case 2:Cn=ke.getHalfFloatAsFloatRGBAArrayBuffer(vt/2,wn);break;case 4:Cn=new Float32Array(vt/4),Cn.set(new Float32Array(wn));break}else switch(er){case 1:Cn=new Uint8Array(Cn.buffer),Cn.set(new Uint8Array(wn));break;case 2:Cn=ke.getHalfFloatAsFloatRGBAArrayBuffer(vt/2,wn,It);break;case 4:var qn=It&&It.constructor||Float32Array;Cn=new qn(Cn.buffer),Cn.set(new qn(wn));break}if(H!==re){er===1&&!m&&(H*=2,re*=2);for(var Si=new Uint8Array(Cn.buffer),po=H,Ao=0,ma=1;ma1?xe.resolveTarget=this.getTextureView(re,this.gfxColorResolveToLevel[E]):xe.storeOp="store")}else{this.gpuColorAttachments.length=E,this.gfxColorAttachment.length=E,this.gfxColorResolveTo.length=E;break}}if(this.gfxDepthStencilAttachment=i.depthStencilAttachment,this.gfxDepthStencilResolveTo=i.depthStencilResolveTo,i.depthStencilAttachment){var rt=i.depthStencilAttachment,xe=this.gpuDepthStencilAttachment;xe.view=rt.gpuTextureView;var vt=!!(r_(rt.format)&fc.Depth);vt?(i.depthClearValue==="load"?xe.depthLoadOp="load":(xe.depthLoadOp="clear",xe.depthClearValue=i.depthClearValue),i.depthStencilStore||this.gfxDepthStencilResolveTo!==null?xe.depthStoreOp="store":xe.depthStoreOp="discard"):(xe.depthLoadOp=void 0,xe.depthStoreOp=void 0);var It=!!(r_(rt.format)&fc.Stencil);It?(i.stencilClearValue==="load"?xe.stencilLoadOp="load":(xe.stencilLoadOp="clear",xe.stencilClearValue=i.stencilClearValue),i.depthStencilStore||this.gfxDepthStencilResolveTo!==null?xe.stencilStoreOp="store":xe.stencilStoreOp="discard"):(xe.stencilLoadOp=void 0,xe.stencilStoreOp=void 0),this.gpuRenderPassDescriptor.depthStencilAttachment=this.gpuDepthStencilAttachment}else this.gpuRenderPassDescriptor.depthStencilAttachment=void 0;this.gpuRenderPassDescriptor.occlusionQuerySet=Fv(i.occlusionQueryPool)?void 0:jU(i.occlusionQueryPool)},e.prototype.beginRenderPass=function(i,r){rd(this.gpuRenderPassEncoder===null),this.setRenderPassDescriptor(r),this.frameCommandEncoder=i,this.gpuRenderPassEncoder=this.frameCommandEncoder.beginRenderPass(this.gpuRenderPassDescriptor)},e.prototype.flipY=function(i,r){var n=this.device.swapChainHeight;return n-i-r},e.prototype.setViewport=function(i,r,n,t,a,u){a===void 0&&(a=0),u===void 0&&(u=1),this.gpuRenderPassEncoder.setViewport(i,this.flipY(r,t),n,t,a,u)},e.prototype.setScissorRect=function(i,r,n,t){this.gpuRenderPassEncoder.setScissorRect(i,this.flipY(r,t),n,t)},e.prototype.setPipeline=function(i){var r=i,n=u1(r.gpuRenderPipeline);this.getEncoder().setPipeline(n)},e.prototype.setVertexInput=function(i,r,n){if(i!==null){var t=this.getEncoder(),a=i;n!==null&&t.setIndexBuffer(l_(n.buffer),u1(a.indexFormat),n.offset);for(var u=0;u1||this.copyAttachment(this.gfxDepthStencilResolveTo,0,this.gfxDepthStencilAttachment,0)),this.frameCommandEncoder=null},e.prototype.copyAttachment=function(i,r,n,t){rd(n.sampleCount===1);var a={texture:n.gpuTexture,mipLevel:t},u={texture:i.gpuTexture,mipLevel:r};rd(n.width>>>t===i.width>>>r),rd(n.height>>>t===i.height>>>r),rd(!!(n.usage&km.COPY_SRC)),rd(!!(i.usage&km.COPY_DST)),this.frameCommandEncoder.copyTextureToTexture(a,u,[i.width,i.height,1])},e}(),fj=function(e){(0,kc.ZT)(i,e);function i(r){var n=r.id,t=r.device,a=r.descriptor,u=e.call(this,{id:n,device:t})||this;return u.type=vp.RenderPipeline,u.isCreatingAsync=!1,u.gpuRenderPipeline=null,u.descriptor=a,u.device.createRenderPipelineInternal(u,!1),u}return i.prototype.getBindGroupLayout=function(r){return this.gpuRenderPipeline.getBindGroupLayout(r)},i}(Kv),hj=function(e){(0,kc.ZT)(i,e);function i(r){var n=r.id,t=r.device,a=r.descriptor,u,c,m=e.call(this,{id:n,device:t})||this;m.type=vp.Sampler;var E=a.lodMinClamp,H=a.mipmapFilter===Dm.NO_MIP?a.lodMinClamp:a.lodMaxClamp,re=(u=a.maxAnisotropy)!==null&&u!==void 0?u:1;return re>1&&rd(a.minFilter===fm.BILINEAR&&a.magFilter===fm.BILINEAR&&a.mipmapFilter===Dm.LINEAR),m.gpuSampler=m.device.device.createSampler({addressModeU:eE(a.addressModeU),addressModeV:eE(a.addressModeV),addressModeW:eE((c=a.addressModeW)!==null&&c!==void 0?c:a.addressModeU),lodMinClamp:E,lodMaxClamp:H,minFilter:cM(a.minFilter),magFilter:cM(a.magFilter),mipmapFilter:ZU(a.mipmapFilter),compare:a.compareFunction!==void 0?C2(a.compareFunction):void 0,maxAnisotropy:re}),m}return i}(Kv),T2=function(e){(0,kc.ZT)(i,e);function i(r){var n=r.id,t=r.device,a=r.descriptor,u=r.skipCreate,c=r.sampleCount,m=e.call(this,{id:n,device:t})||this;m.type=vp.Texture,m.flipY=!1;var E=a.format,H=a.dimension,re=a.width,xe=a.height,ke=a.depthOrArrayLayers,rt=a.mipLevelCount,vt=a.usage,It=a.pixelStore;return m.flipY=!!(It!=null&&It.unpackFlipY),m.device.createTextureShared({format:E,dimension:H!=null?H:Pd.TEXTURE_2D,width:re,height:xe,depthOrArrayLayers:ke!=null?ke:1,mipLevelCount:rt!=null?rt:1,usage:vt,sampleCount:c!=null?c:1},m,u),m}return i.prototype.textureFromImageBitmapOrCanvas=function(r,n,t){for(var a=n[0].width,u=n[0].height,c={size:{width:a,height:u,depthOrArrayLayers:t},format:"rgba8unorm",usage:GPUTextureUsage.TEXTURE_BINDING|GPUTextureUsage.COPY_DST|GPUTextureUsage.RENDER_ATTACHMENT},m=r.createTexture(c),E=0;E>>2,uniformBufferWordAlignment:this.device.limits.minUniformBufferOffsetAlignment>>>2,supportedSampleCounts:[1],occlusionQueriesRecommended:!0,computeShadersSupported:!0}},e.prototype.queryTextureFormatSupported=function(i,r,n){if(rj(i)){if(!this.featureTextureCompressionBC)return!1;var t=nj(i);return r%t!==0||n%t!==0?!1:this.featureTextureCompressionBC}switch(i){case yo.U16_RGBA_NORM:return!1;case yo.F32_RGBA:return!1}return!0},e.prototype.queryPlatformAvailable=function(){return!0},e.prototype.queryVendorInfo=function(){return this},e.prototype.queryRenderPass=function(i){var r=i;return r.descriptor},e.prototype.queryRenderTarget=function(i){var r=i;return r},e.prototype.setResourceName=function(i,r){if(i.name=r,i.type===vp.Buffer){var n=i;n.gpuBuffer.label=r}else if(i.type===vp.Texture){var n=i;n.gpuTexture.label=r,n.gpuTextureView.label=r}else if(i.type===vp.RenderTarget){var n=i;n.gpuTexture.label=r,n.gpuTextureView.label=r}else if(i.type===vp.Sampler){var n=i;n.gpuSampler.label=r}else if(i.type===vp.RenderPipeline){var n=i;n.gpuRenderPipeline!==null&&(n.gpuRenderPipeline.label=r)}},e.prototype.setResourceLeakCheck=function(i,r){},e.prototype.checkForLeaks=function(){},e.prototype.programPatched=function(i){},e.prototype.pipelineQueryReady=function(i){var r=i;return r.gpuRenderPipeline!==null},e.prototype.pipelineForceReady=function(i){var r=i;this.createRenderPipelineInternal(r,!1)},e}(),mj=function(){function e(i){this.pluginOptions=i}return e.prototype.createSwapChain=function(i){return(0,kc.mG)(this,void 0,void 0,function(){var r,n,t,a,u,c,m,E;return(0,kc.Jh)(this,function(H){switch(H.label){case 0:if(globalThis.navigator.gpu===void 0)return[2,null];r=null,H.label=1;case 1:return H.trys.push([1,3,,4]),n=this.pluginOptions.xrCompatible,[4,globalThis.navigator.gpu.requestAdapter({xrCompatible:n})];case 2:return r=H.sent(),[3,4];case 3:return t=H.sent(),console.log(t),[3,4];case 4:return r===null?[2,null]:(a=["depth32float-stencil8","texture-compression-bc","float32-filterable"],u=a.filter(function(re){return r.features.has(re)}),[4,r.requestDevice({requiredFeatures:u})]);case 5:if(c=H.sent(),c&&(m=this.pluginOptions.onContextLost,c.lost.then(function(){m&&m()})),c===null)return[2,null];if(E=i.getContext("webgpu"),!E)return[2,null];H.label=6;case 6:return H.trys.push([6,8,,9]),[4,lM(this.pluginOptions.shaderCompilerPath)];case 7:return H.sent(),[3,9];case 8:return H.sent(),[3,9];case 9:return[2,new pj(r,c,i,E,OU,mA&&new mA)]}})})},e}(),vj=lo.isPlainObject,gj=lo.isTypedArray,yj=function(){function e(i,r){(0,We.Z)(this,e),(0,St.Z)(this,"destroyed",!1),(0,St.Z)(this,"uniforms",{}),this.reGl=i;var n=r.vs,t=r.fs,a=r.attributes,u=r.uniforms,c=r.primitive,m=r.count,E=r.elements,H=r.depth,re=r.cull,xe=r.instances,ke={platformString:"WebGL1",glslVersion:"#version 100",explicitBindingLocations:!1,separateSamplerTextures:!1,viewportOrigin:mg.LOWER_LEFT,clipSpaceNearZ:t_.NEGATIVE_ONE,supportMRT:!1},rt={};this.options=r,u&&(this.uniforms=this.extractUniforms(u),Object.keys(u).forEach(function(Or){rt[Or]=i.prop(Or)}));var vt={};Object.keys(a).forEach(function(Or){vt[Or]=a[Or].get()});var It=Hy(Ty(ke,"frag",t,null,!1)),er=Hy(Ty(ke,"vert",n,null,!1)),Ar={attributes:vt,frag:It,uniforms:rt,vert:er,colorMask:i.prop("colorMask"),lineWidth:1,blend:{enable:i.prop("blend.enable"),func:i.prop("blend.func"),equation:i.prop("blend.equation"),color:i.prop("blend.color")},stencil:{enable:i.prop("stencil.enable"),mask:i.prop("stencil.mask"),func:i.prop("stencil.func"),opFront:i.prop("stencil.opFront"),opBack:i.prop("stencil.opBack")},primitive:tZ[c===void 0?Er.TRIANGLES:c]};xe&&(Ar.instances=xe),m?Ar.count=m:E&&(Ar.elements=E.get()),this.initDepthDrawParams({depth:H},Ar),this.initCullDrawParams({cull:re},Ar),this.drawCommand=i(Ar),this.drawParams=Ar}return(0,ot.Z)(e,[{key:"updateAttributesAndElements",value:function(r,n){var t={};Object.keys(r).forEach(function(a){t[a]=r[a].get()}),this.drawParams.attributes=t,this.drawParams.elements=n.get(),this.drawCommand=this.reGl(this.drawParams)}},{key:"updateAttributes",value:function(r){var n={};Object.keys(r).forEach(function(t){n[t]=r[t].get()}),this.drawParams.attributes=n,this.drawCommand=this.reGl(this.drawParams)}},{key:"addUniforms",value:function(r){this.uniforms=(0,Se.Z)((0,Se.Z)({},this.uniforms),this.extractUniforms(r))}},{key:"draw",value:function(r,n){if(!(this.drawParams.attributes&&Object.keys(this.drawParams.attributes).length===0)){var t=(0,Se.Z)((0,Se.Z)({},this.uniforms),this.extractUniforms(r.uniforms||{})),a={};Object.keys(t).forEach(function(u){var c=(0,df.Z)(t[u]);c==="boolean"||c==="number"||Array.isArray(t[u])||t[u].BYTES_PER_ELEMENT?a[u]=t[u]:a[u]=t[u].get()}),a.blend=n?this.getBlendDrawParams({blend:{enable:!1}}):this.getBlendDrawParams(r),a.stencil=this.getStencilDrawParams(r),a.colorMask=this.getColorMaskDrawParams(r,n),this.drawCommand(a)}}},{key:"destroy",value:function(){var r;(r=this.drawParams)===null||r===void 0||(r=r.elements)===null||r===void 0||r.destroy(),this.options.attributes&&Object.values(this.options.attributes).forEach(function(n){n==null||n.destroy()}),this.destroyed=!0}},{key:"initDepthDrawParams",value:function(r,n){var t=r.depth;t&&(n.depth={enable:t.enable===void 0?!0:!!t.enable,mask:t.mask===void 0?!0:!!t.mask,func:oZ[t.func||Er.LESS],range:t.range||[0,1]})}},{key:"getBlendDrawParams",value:function(r){var n=r.blend,t=n||{},a=t.enable,u=t.func,c=t.equation,m=t.color,E=m===void 0?[0,0,0,0]:m;return{enable:!!a,func:{srcRGB:f2[u&&u.srcRGB||Er.SRC_ALPHA],srcAlpha:f2[u&&u.srcAlpha||Er.SRC_ALPHA],dstRGB:f2[u&&u.dstRGB||Er.ONE_MINUS_SRC_ALPHA],dstAlpha:f2[u&&u.dstAlpha||Er.ONE_MINUS_SRC_ALPHA]},equation:{rgb:B5[c&&c.rgb||Er.FUNC_ADD],alpha:B5[c&&c.alpha||Er.FUNC_ADD]},color:E}}},{key:"getStencilDrawParams",value:function(r){var n=r.stencil,t=n||{},a=t.enable,u=t.mask,c=u===void 0?-1:u,m=t.func,E=m===void 0?{cmp:Er.ALWAYS,ref:0,mask:-1}:m,H=t.opFront,re=H===void 0?{fail:Er.KEEP,zfail:Er.KEEP,zpass:Er.KEEP}:H,xe=t.opBack,ke=xe===void 0?{fail:Er.KEEP,zfail:Er.KEEP,zpass:Er.KEEP}:xe;return{enable:!!a,mask:c,func:(0,Se.Z)((0,Se.Z)({},E),{},{cmp:aZ[E.cmp]}),opFront:{fail:J1[re.fail],zfail:J1[re.zfail],zpass:J1[re.zpass]},opBack:{fail:J1[ke.fail],zfail:J1[ke.zfail],zpass:J1[ke.zpass]}}}},{key:"getColorMaskDrawParams",value:function(r,n){var t=r.stencil,a=t!=null&&t.enable&&t.opFront&&!n?[!1,!1,!1,!1]:[!0,!0,!0,!0];return a}},{key:"initCullDrawParams",value:function(r,n){var t=r.cull;if(t){var a=t.enable,u=t.face,c=u===void 0?Er.BACK:u;n.cull={enable:!!a,face:sZ[c]}}}},{key:"extractUniforms",value:function(r){var n=this,t={};return Object.keys(r).forEach(function(a){n.extractUniformsRecursively(a,r[a],t,"")}),t}},{key:"extractUniformsRecursively",value:function(r,n,t,a){var u=this;if(n===null||typeof n=="number"||typeof n=="boolean"||Array.isArray(n)&&typeof n[0]=="number"||gj(n)||n===""||"resize"in n){t["".concat(a&&a+".").concat(r)]=n;return}vj(n)&&Object.keys(n).forEach(function(c){u.extractUniformsRecursively(c,n[c],t,"".concat(a&&a+".").concat(r))}),Array.isArray(n)&&n.forEach(function(c,m){Object.keys(c).forEach(function(E){u.extractUniformsRecursively(E,c[E],t,"".concat(a&&a+".").concat(r,"[").concat(m,"]"))})})}}]),e}(),_j=function(){function e(i,r){(0,We.Z)(this,e),(0,St.Z)(this,"isDestroy",!1);var n=r.data,t=r.type,a=t===void 0?Er.UNSIGNED_BYTE:t,u=r.width,c=r.height,m=r.flipY,E=m===void 0?!1:m,H=r.format,re=H===void 0?Er.RGBA:H,xe=r.mipmap,ke=xe===void 0?!1:xe,rt=r.wrapS,vt=rt===void 0?Er.CLAMP_TO_EDGE:rt,It=r.wrapT,er=It===void 0?Er.CLAMP_TO_EDGE:It,Ar=r.aniso,Or=Ar===void 0?0:Ar,rn=r.alignment,Ln=rn===void 0?1:rn,wn=r.premultiplyAlpha,Cn=wn===void 0?!1:wn,qn=r.mag,Si=qn===void 0?Er.NEAREST:qn,po=r.min,Ao=po===void 0?Er.NEAREST:po,ma=r.colorSpace,Ya=ma===void 0?Er.BROWSER_DEFAULT_WEBGL:ma,fs=r.x,bf=fs===void 0?0:fs,th=r.y,Yh=th===void 0?0:th,Lp=r.copy,vd=Lp===void 0?!1:Lp;this.width=u,this.height=c;var Tm={width:u,height:c,type:Hw[a],format:rZ[re],wrapS:F5[vt],wrapT:F5[er],mag:k5[Si],min:k5[Ao],alignment:Ln,flipY:E,colorSpace:iZ[Ya],premultiplyAlpha:Cn,aniso:Or,x:bf,y:Yh,copy:vd};n&&(Tm.data=n),typeof ke=="number"?Tm.mipmap=nZ[ke]:typeof ke=="boolean"&&(Tm.mipmap=ke),this.texture=i.texture(Tm)}return(0,ot.Z)(e,[{key:"get",value:function(){return this.texture}},{key:"update",value:function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.texture(r)}},{key:"bind",value:function(){this.texture._texture.bind()}},{key:"resize",value:function(r){var n=r.width,t=r.height;this.texture.resize(n,t),this.width=n,this.height=t}},{key:"getSize",value:function(){return[this.width,this.height]}},{key:"destroy",value:function(){if(!this.isDestroy){var r;(r=this.texture)===null||r===void 0||r.destroy()}this.isDestroy=!0}}]),e}(),_M,AM,Aj=(_M=(0,sa.b2)(),_M(AM=function(){function e(){var i=this;(0,We.Z)(this,e),(0,St.Z)(this,"uniformBuffers",[]),(0,St.Z)(this,"queryVerdorInfo",function(){return"WebGL1"}),(0,St.Z)(this,"createModel",function(r){return new yj(i.gl,r)}),(0,St.Z)(this,"createAttribute",function(r){return new eZ(i.gl,r)}),(0,St.Z)(this,"createBuffer",function(r){return new uZ(i.gl,r)}),(0,St.Z)(this,"createElements",function(r){return new lZ(i.gl,r)}),(0,St.Z)(this,"createTexture2D",function(r){return new _j(i.gl,r)}),(0,St.Z)(this,"createFramebuffer",function(r){return new cZ(i.gl,r)}),(0,St.Z)(this,"useFramebuffer",function(r,n){i.gl({framebuffer:r?r.get():null})(n)}),(0,St.Z)(this,"useFramebufferAsync",function(){var r=(0,Li.Z)(Ur().mark(function n(t,a){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:i.gl({framebuffer:t?t.get():null})(a);case 1:case"end":return c.stop()}},n)}));return function(n,t){return r.apply(this,arguments)}}()),(0,St.Z)(this,"clear",function(r){var n,t=r.color,a=r.depth,u=r.stencil,c=r.framebuffer,m=c===void 0?null:c,E={color:t,depth:a,stencil:u};E.framebuffer=m===null?m:m.get(),(n=i.gl)===null||n===void 0||n.clear(E)}),(0,St.Z)(this,"viewport",function(r){var n=r.x,t=r.y,a=r.width,u=r.height;i.gl._gl.viewport(n,t,a,u),i.width=a,i.height=u,i.gl._refresh()}),(0,St.Z)(this,"readPixels",function(r){var n=r.framebuffer,t=r.x,a=r.y,u=r.width,c=r.height,m={x:t,y:a,width:u,height:c};return n&&(m.framebuffer=n.get()),i.gl.read(m)}),(0,St.Z)(this,"readPixelsAsync",function(){var r=(0,Li.Z)(Ur().mark(function n(t){return Ur().wrap(function(u){for(;;)switch(u.prev=u.next){case 0:return u.abrupt("return",i.readPixels(t));case 1:case"end":return u.stop()}},n)}));return function(n){return r.apply(this,arguments)}}()),(0,St.Z)(this,"getViewportSize",function(){return{width:i.gl._gl.drawingBufferWidth,height:i.gl._gl.drawingBufferHeight}}),(0,St.Z)(this,"getContainer",function(){var r;return(r=i.canvas)===null||r===void 0?void 0:r.parentElement}),(0,St.Z)(this,"getCanvas",function(){return i.canvas}),(0,St.Z)(this,"getGLContext",function(){return i.gl._gl}),(0,St.Z)(this,"destroy",function(){var r;i.canvas=null,(r=i.gl)===null||r===void 0||(r=r._gl)===null||r===void 0||(r=r.getExtension("WEBGL_lose_context"))===null||r===void 0||r.loseContext(),i.gl.destroy(),i.gl=null})}return(0,ot.Z)(e,[{key:"init",value:function(){var i=(0,Li.Z)(Ur().mark(function n(t,a,u){var c=this;return Ur().wrap(function(E){for(;;)switch(E.prev=E.next){case 0:if(this.canvas=t,!u){E.next=5;break}this.gl=u,E.next=8;break;case 5:return E.next=7,new Promise(function(H,re){Jz()({canvas:c.canvas,attributes:{alpha:!0,antialias:a.antialias,premultipliedAlpha:!0,preserveDrawingBuffer:a.preserveDrawingBuffer,stencil:a.stencil},extensions:["OES_element_index_uint","OES_standard_derivatives","ANGLE_instanced_arrays"],optionalExtensions:["oes_texture_float_linear","OES_texture_float","EXT_texture_filter_anisotropic","EXT_blend_minmax","WEBGL_depth_texture","WEBGL_lose_context"],profile:!0,onDone:function(ke,rt){(ke||!rt)&&re(ke),H(rt)}})});case 7:this.gl=E.sent;case 8:this.extensionObject={OES_texture_float:this.testExtension("OES_texture_float")};case 9:case"end":return E.stop()}},n,this)}));function r(n,t,a){return i.apply(this,arguments)}return r}()},{key:"getPointSizeRange",value:function(){return this.gl._gl.getParameter(this.gl._gl.ALIASED_POINT_SIZE_RANGE)}},{key:"testExtension",value:function(r){return!!this.getGLContext().getExtension(r)}},{key:"setState",value:function(){this.gl({cull:{enable:!1,face:"back"},viewport:{x:0,y:0,height:this.width,width:this.height},blend:{enable:!0,equation:"add"},framebuffer:null}),this.gl._refresh()}},{key:"setBaseState",value:function(){this.gl({cull:{enable:!1,face:"back"},viewport:{x:0,y:0,height:this.width,width:this.height},blend:{enable:!1,equation:"add"},framebuffer:null}),this.gl._refresh()}},{key:"setCustomLayerDefaults",value:function(){var r=this.getGLContext();r.disable(r.CULL_FACE)}},{key:"setDirty",value:function(r){this.isDirty=r}},{key:"getDirty",value:function(){return this.isDirty}},{key:"beginFrame",value:function(){}},{key:"endFrame",value:function(){}}]),e}())||AM),bj=function(){function e(i,r){(0,We.Z)(this,e);var n=r.buffer,t=r.offset,a=r.stride,u=r.normalized,c=r.size,m=r.divisor,E=r.shaderLocation;this.buffer=n,this.attribute={shaderLocation:E,buffer:n.get(),offset:t||0,stride:a||0,normalized:u||!1,divisor:m||0},c&&(this.attribute.size=c)}return(0,ot.Z)(e,[{key:"get",value:function(){return this.buffer}},{key:"updateBuffer",value:function(r){this.buffer.subData(r)}},{key:"destroy",value:function(){this.buffer.destroy()}}]),e}(),Py,Yg,f_,vA,gA,gg,M2,c1,Km,yg,_g,P2=(Py={},(0,St.Z)(Py,Er.FLOAT,Float32Array),(0,St.Z)(Py,Er.UNSIGNED_BYTE,Uint8Array),(0,St.Z)(Py,Er.SHORT,Int16Array),(0,St.Z)(Py,Er.UNSIGNED_SHORT,Uint16Array),(0,St.Z)(Py,Er.INT,Int32Array),(0,St.Z)(Py,Er.UNSIGNED_INT,Uint32Array),Py),xj=(Yg={},(0,St.Z)(Yg,Er.POINTS,Sm.POINTS),(0,St.Z)(Yg,Er.LINES,Sm.LINES),(0,St.Z)(Yg,Er.LINE_LOOP,Sm.LINES),(0,St.Z)(Yg,Er.LINE_STRIP,Sm.LINE_STRIP),(0,St.Z)(Yg,Er.TRIANGLES,Sm.TRIANGLES),(0,St.Z)(Yg,Er.TRIANGLE_FAN,Sm.TRIANGLES),(0,St.Z)(Yg,Er.TRIANGLE_STRIP,Sm.TRIANGLE_STRIP),Yg),wj=(f_={},(0,St.Z)(f_,1,yo.F32_R),(0,St.Z)(f_,2,yo.F32_RG),(0,St.Z)(f_,3,yo.F32_RGB),(0,St.Z)(f_,4,yo.F32_RGBA),f_),Ej=(vA={},(0,St.Z)(vA,Er.STATIC_DRAW,Yv.STATIC),(0,St.Z)(vA,Er.DYNAMIC_DRAW,Yv.DYNAMIC),(0,St.Z)(vA,Er.STREAM_DRAW,Yv.DYNAMIC),vA),bM=(gA={},(0,St.Z)(gA,Er.REPEAT,sv.REPEAT),(0,St.Z)(gA,Er.CLAMP_TO_EDGE,sv.CLAMP_TO_EDGE),(0,St.Z)(gA,Er.MIRRORED_REPEAT,sv.MIRRORED_REPEAT),gA),Sj=(gg={},(0,St.Z)(gg,Er.NEVER,Ad.NEVER),(0,St.Z)(gg,Er.ALWAYS,Ad.ALWAYS),(0,St.Z)(gg,Er.LESS,Ad.LESS),(0,St.Z)(gg,Er.LEQUAL,Ad.LEQUAL),(0,St.Z)(gg,Er.GREATER,Ad.GREATER),(0,St.Z)(gg,Er.GEQUAL,Ad.GEQUAL),(0,St.Z)(gg,Er.EQUAL,Ad.EQUAL),(0,St.Z)(gg,Er.NOTEQUAL,Ad.NOTEQUAL),gg),Cj=(M2={},(0,St.Z)(M2,Er.FRONT,mv.FRONT),(0,St.Z)(M2,Er.BACK,mv.BACK),M2),xM=(c1={},(0,St.Z)(c1,Er.FUNC_ADD,Zm.ADD),(0,St.Z)(c1,Er.MIN_EXT,Zm.MIN),(0,St.Z)(c1,Er.MAX_EXT,Zm.MAX),(0,St.Z)(c1,Er.FUNC_SUBTRACT,Zm.SUBSTRACT),(0,St.Z)(c1,Er.FUNC_REVERSE_SUBTRACT,Zm.REVERSE_SUBSTRACT),c1),I2=(Km={},(0,St.Z)(Km,Er.ZERO,Dd.ZERO),(0,St.Z)(Km,Er.ONE,Dd.ONE),(0,St.Z)(Km,Er.SRC_COLOR,Dd.SRC),(0,St.Z)(Km,Er.ONE_MINUS_SRC_COLOR,Dd.ONE_MINUS_SRC),(0,St.Z)(Km,Er.SRC_ALPHA,Dd.SRC_ALPHA),(0,St.Z)(Km,Er.ONE_MINUS_SRC_ALPHA,Dd.ONE_MINUS_SRC_ALPHA),(0,St.Z)(Km,Er.DST_COLOR,Dd.DST),(0,St.Z)(Km,Er.ONE_MINUS_DST_COLOR,Dd.ONE_MINUS_DST),(0,St.Z)(Km,Er.DST_ALPHA,Dd.DST_ALPHA),(0,St.Z)(Km,Er.ONE_MINUS_DST_ALPHA,Dd.ONE_MINUS_DST_ALPHA),(0,St.Z)(Km,Er.CONSTANT_COLOR,Dd.CONST),(0,St.Z)(Km,Er.ONE_MINUS_CONSTANT_COLOR,Dd.ONE_MINUS_CONSTANT),(0,St.Z)(Km,Er.CONSTANT_ALPHA,Dd.CONST),(0,St.Z)(Km,Er.ONE_MINUS_CONSTANT_ALPHA,Dd.ONE_MINUS_CONSTANT),(0,St.Z)(Km,Er.SRC_ALPHA_SATURATE,Dd.SRC_ALPHA_SATURATE),Km),h_=(yg={},(0,St.Z)(yg,Er.REPLACE,im.REPLACE),(0,St.Z)(yg,Er.KEEP,im.KEEP),(0,St.Z)(yg,Er.ZERO,im.ZERO),(0,St.Z)(yg,Er.INVERT,im.INVERT),(0,St.Z)(yg,Er.INCR,im.INCREMENT_CLAMP),(0,St.Z)(yg,Er.DECR,im.DECREMENT_CLAMP),(0,St.Z)(yg,Er.INCR_WRAP,im.INCREMENT_WRAP),(0,St.Z)(yg,Er.DECR_WRAP,im.DECREMENT_WRAP),yg),Tj=(_g={},(0,St.Z)(_g,Er.ALWAYS,Ad.ALWAYS),(0,St.Z)(_g,Er.EQUAL,Ad.EQUAL),(0,St.Z)(_g,Er.GEQUAL,Ad.GEQUAL),(0,St.Z)(_g,Er.GREATER,Ad.GREATER),(0,St.Z)(_g,Er.LEQUAL,Ad.LEQUAL),(0,St.Z)(_g,Er.LESS,Ad.LESS),(0,St.Z)(_g,Er.NEVER,Ad.NEVER),(0,St.Z)(_g,Er.NOTEQUAL,Ad.NOTEQUAL),_g),Mj={"[object Int8Array]":5120,"[object Int16Array]":5122,"[object Int32Array]":5124,"[object Uint8Array]":5121,"[object Uint8ClampedArray]":5121,"[object Uint16Array]":5123,"[object Uint32Array]":5125,"[object Float32Array]":5126,"[object Float64Array]":5121,"[object ArrayBuffer]":5121};function R2(e){return Object.prototype.toString.call(e)in Mj}function Pj(e,i){for(var r=e.length,n=Math.ceil(r/3),t=r+n,a=new Float32Array(t),u=0;u=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function Rj(e,i){if(e){if(typeof e=="string")return EM(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return EM(e,i)}}function EM(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r1&&arguments[1]!==void 0?arguments[1]:0;return e+=i,e+=e<<10,e+=e>>>6,e>>>0}function SM(e){return e+=e<<3,e^=e>>>11,e+=e<<15,e>>>0}function CM(e){return 0}var Oj=(0,ot.Z)(function e(){(0,We.Z)(this,e),(0,St.Z)(this,"keys",[]),(0,St.Z)(this,"values",[])}),O2=function(){function e(i,r){(0,We.Z)(this,e),(0,St.Z)(this,"buckets",new Map),this.keyEqualFunc=i,this.keyHashFunc=r}return(0,ot.Z)(e,[{key:"findBucketIndex",value:function(r,n){for(var t=0;t=0)){c.next=12;break}return c.next=9,t.values[a];case 9:a--,c.next=6;break;case 12:c.next=3;break;case 14:c.next=19;break;case 16:c.prev=16,c.t0=c.catch(1),r.e(c.t0);case 19:return c.prev=19,r.f(),c.finish(19);case 22:case"end":return c.stop()}},i,this,[[1,16,19,22]])})}]),e}();function L2(e,i){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=Lj(e))||i&&e&&typeof e.length=="number"){r&&(e=r);var n=0,t=function(){};return{s:t,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(E){throw E},f:t}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,u=!1,c;return{s:function(){r=r.call(e)},n:function(){var E=r.next();return a=E.done,E},e:function(E){u=!0,c=E},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(u)throw c}}}}function Lj(e,i){if(e){if(typeof e=="string")return TM(e,i);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return TM(e,i)}}function TM(e,i){(i==null||i>e.length)&&(i=e.length);for(var r=0,n=new Array(i);r0}),n=this.device.createBindings(a),this.bindingsCache.add(a,n)}return n}},{key:"createRenderPipeline",value:function(r){var n=this.renderPipelinesCache.get(r);if(n===null){var t=VZ(r);t.colorAttachmentFormats=t.colorAttachmentFormats.filter(function(a){return a}),n=this.device.createRenderPipeline(t),this.renderPipelinesCache.add(t,n)}return n}},{key:"createInputLayout",value:function(r){r.vertexBufferDescriptors=r.vertexBufferDescriptors.filter(function(a){return!!a});var n=this.inputLayoutsCache.get(r);if(n===null){var t=GZ(r);n=this.device.createInputLayout(t),this.inputLayoutsCache.add(t,n)}return n}},{key:"createProgram",value:function(r){var n=this.programCache.get(r);if(n===null){var t=Zj(r);n=this.device.createProgram(r),this.programCache.add(t,n)}return n}},{key:"destroy",value:function(){var r=L2(this.bindingsCache.values()),n;try{for(r.s();!(n=r.n()).done;){var t=n.value;t.destroy()}}catch(rt){r.e(rt)}finally{r.f()}var a=L2(this.renderPipelinesCache.values()),u;try{for(a.s();!(u=a.n()).done;){var c=u.value;c.destroy()}}catch(rt){a.e(rt)}finally{a.f()}var m=L2(this.inputLayoutsCache.values()),E;try{for(m.s();!(E=m.n()).done;){var H=E.value;H.destroy()}}catch(rt){m.e(rt)}finally{m.f()}var re=L2(this.programCache.values()),xe;try{for(re.s();!(xe=re.n()).done;){var ke=xe.value;ke.destroy()}}catch(rt){re.e(rt)}finally{re.f()}this.bindingsCache.clear(),this.renderPipelinesCache.clear(),this.inputLayoutsCache.clear(),this.programCache.clear()}}]),e}(),jj=function(){function e(i,r){(0,We.Z)(this,e);var n=r.data,t=r.type,a=r.count,u=a===void 0?0:a,c;R2(n)?c=n:c=new P2[this.type||Er.UNSIGNED_INT](n),this.type=t,this.count=u,this.indexBuffer=i.createBuffer({viewOrSize:c,usage:h0.INDEX})}return(0,ot.Z)(e,[{key:"get",value:function(){return this.indexBuffer}},{key:"subData",value:function(r){var n=r.data,t;R2(n)?t=n:t=new P2[this.type||Er.UNSIGNED_INT](n),this.indexBuffer.setSubData(0,new Uint8Array(t.buffer))}},{key:"destroy",value:function(){this.indexBuffer.destroy()}}]),e}();function PM(e){return!!(e&&e.texture)}var IM=function(){function e(i,r){(0,We.Z)(this,e),(0,St.Z)(this,"isDestroy",!1),this.device=i,this.options=r;var n=r.wrapS,t=n===void 0?Er.CLAMP_TO_EDGE:n,a=r.wrapT,u=a===void 0?Er.CLAMP_TO_EDGE:a,c=r.aniso,m=r.mipmap,E=m===void 0?!1:m,H=r.mag,re=H===void 0?Er.NEAREST:H,xe=r.min,ke=xe===void 0?Er.NEAREST:xe;this.createTexture(r),this.sampler=i.createSampler({addressModeU:bM[t],addressModeV:bM[u],minFilter:ke===Er.NEAREST?fm.POINT:fm.BILINEAR,magFilter:re===Er.NEAREST?fm.POINT:fm.BILINEAR,mipmapFilter:Dm.NO_MIP,maxAnisotropy:c})}return(0,ot.Z)(e,[{key:"createTexture",value:function(r){var n=r.type,t=n===void 0?Er.UNSIGNED_BYTE:n,a=r.width,u=r.height,c=r.flipY,m=c===void 0?!1:c,E=r.format,H=E===void 0?Er.RGBA:E,re=r.aniso,xe=r.alignment,ke=xe===void 0?1:xe,rt=r.usage,vt=rt===void 0?Eh.SAMPLED:rt,It=r.unorm,er=It===void 0?!1:It,Ar=r.label,Or=r.data;this.width=a,this.height=u;var rn=yo.U8_RGBA_RT;if(t===Er.UNSIGNED_BYTE&&H===Er.RGBA)rn=er?yo.U8_RGBA_NORM:yo.U8_RGBA_RT;else if(t===Er.UNSIGNED_BYTE&&H===Er.LUMINANCE)rn=yo.U8_LUMINANCE;else if(t===Er.FLOAT&&H===Er.RGB)this.device.queryVendorInfo().platformString==="WebGPU"?(Or&&(Or=Pj(Or,0)),rn=yo.F32_RGBA):rn=yo.F32_RGB;else if(t===Er.FLOAT&&H===Er.RGBA)rn=yo.F32_RGBA;else if(t===Er.FLOAT&&H===Er.RED)rn=yo.F32_R;else throw new Error("create texture error, type: ".concat(t,", format: ").concat(H));this.texture=this.device.createTexture({format:rn,width:a,height:u,usage:vt===Eh.SAMPLED?Ym.SAMPLED:Ym.RENDER_TARGET,pixelStore:{unpackFlipY:m,packAlignment:ke},mipLevelCount:1}),Ar&&this.device.setResourceName(this.texture,Ar),Or&&this.texture.setImageData([Or])}},{key:"get",value:function(){return this.texture}},{key:"update",value:function(r){var n=r.data;this.texture.setImageData([n])}},{key:"bind",value:function(){}},{key:"resize",value:function(r){var n=r.width,t=r.height;(this.width!==n||this.height!==t)&&this.destroy(),this.options.width=n,this.options.height=t,this.createTexture(this.options),this.isDestroy=!1}},{key:"getSize",value:function(){return[this.width,this.height]}},{key:"destroy",value:function(){if(!this.isDestroy&&!this.texture.destroyed){var r;(r=this.texture)===null||r===void 0||r.destroy()}this.isDestroy=!0}}]),e}(),RM=function(){function e(i,r){(0,We.Z)(this,e),this.device=i,this.options=r,this.createColorRenderTarget(),this.createDepthRenderTarget()}return(0,ot.Z)(e,[{key:"createColorRenderTarget",value:function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,n=this.options,t=n.width,a=n.height,u=n.color;u&&(PM(u)?(r&&u.resize({width:t,height:a}),this.colorTexture=u.get(),this.colorRenderTarget=this.device.createRenderTargetFromTexture(this.colorTexture),this.width=u.width,this.height=u.height):t&&a&&(this.colorTexture=this.device.createTexture({format:yo.U8_RGBA_RT,usage:Ym.RENDER_TARGET,width:t,height:a}),this.colorRenderTarget=this.device.createRenderTargetFromTexture(this.colorTexture),this.width=t,this.height=a))}},{key:"createDepthRenderTarget",value:function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,n=this.options,t=n.width,a=n.height,u=n.depth;u&&(PM(u)?(r&&u.resize({width:t,height:a}),this.depthTexture=u.get(),this.depthRenderTarget=this.device.createRenderTargetFromTexture(this.depthTexture),this.width=u.width,this.height=u.height):t&&a&&(this.depthTexture=this.device.createTexture({format:yo.D24_S8,usage:Ym.RENDER_TARGET,width:t,height:a}),this.depthRenderTarget=this.device.createRenderTargetFromTexture(this.depthTexture),this.width=t,this.height=a))}},{key:"get",value:function(){return this.colorRenderTarget}},{key:"destroy",value:function(){var r,n;(r=this.colorRenderTarget)===null||r===void 0||r.destroy(),(n=this.depthRenderTarget)===null||n===void 0||n.destroy()}},{key:"resize",value:function(r){var n=r.width,t=r.height;(this.width!==n||this.height!==t)&&(this.destroy(),this.colorTexture.destroyed=!0,this.depthTexture.destroyed=!0,this.options.width=n,this.options.height=t,this.createColorRenderTarget(!0),this.createDepthRenderTarget(!0))}}]),e}(),Vj=lo.isPlainObject,$j=lo.isTypedArray,Hj=function(){function e(i,r,n){var t=this;(0,We.Z)(this,e),(0,St.Z)(this,"destroyed",!1),(0,St.Z)(this,"uniforms",{}),(0,St.Z)(this,"vertexBuffers",[]),this.device=i,this.options=r,this.service=n;var a=r.vs,u=r.fs,c=r.attributes,m=r.uniforms,E=r.count,H=r.elements,re=r.diagnosticDerivativeUniformityEnabled;this.options=r;var xe=re?"":this.service.viewportOrigin===mg.UPPER_LEFT?"diagnostic(off,derivative_uniformity);":"";this.program=n.renderCache.createProgram({vertex:{glsl:a},fragment:{glsl:u,postprocess:function(er){return xe+er}}}),m&&(this.uniforms=this.extractUniforms(m));var ke=[],rt=0;Object.keys(c).forEach(function(It){var er=c[It],Ar=er.get();t.vertexBuffers.push(Ar.get());var Or=er.attribute,rn=Or.offset,Ln=rn===void 0?0:rn,wn=Or.stride,Cn=wn===void 0?0:wn,qn=Or.size,Si=qn===void 0?1:qn,po=Or.divisor,Ao=po===void 0?0:po,ma=Or.shaderLocation,Ya=ma===void 0?0:ma;ke.push({arrayStride:Cn||Si*4,stepMode:s1.VERTEX,attributes:[{format:wj[Si],shaderLocation:Ya,offset:Ln,divisor:Ao}]}),rt=Ar.size/Si}),E||(this.options.count=rt),H&&(this.indexBuffer=H.get());var vt=n.renderCache.createInputLayout({vertexBufferDescriptors:ke,indexBufferFormat:H?yo.U32_R:null,program:this.program});this.inputLayout=vt,this.pipeline=this.createPipeline(r)}return(0,ot.Z)(e,[{key:"createPipeline",value:function(r,n){var t=r.primitive,a=t===void 0?Er.TRIANGLES:t,u=r.depth,c=r.cull,m=r.blend,E=r.stencil,H=this.initDepthDrawParams({depth:u}),re=!!(H&&H.enable),xe=this.initCullDrawParams({cull:c}),ke=!!(xe&&xe.enable),rt=this.getBlendDrawParams({blend:m}),vt=!!(rt&&rt.enable),It=this.getStencilDrawParams({stencil:E}),er=!!(It&&It.enable);return this.device.createRenderPipeline({inputLayout:this.inputLayout,program:this.program,topology:xj[a],colorAttachmentFormats:[yo.U8_RGBA_RT],depthStencilAttachmentFormat:yo.D24_S8,megaStateDescriptor:{attachmentsState:[n?{channelWriteMask:Um.ALL,rgbBlendState:{blendMode:Zm.ADD,blendSrcFactor:Dd.ONE,blendDstFactor:Dd.ZERO},alphaBlendState:{blendMode:Zm.ADD,blendSrcFactor:Dd.ONE,blendDstFactor:Dd.ZERO}}:{channelWriteMask:er&&It.opFront.zpass===im.REPLACE?Um.NONE:Um.ALL,rgbBlendState:{blendMode:vt&&rt.equation.rgb||Zm.ADD,blendSrcFactor:vt&&rt.func.srcRGB||Dd.SRC_ALPHA,blendDstFactor:vt&&rt.func.dstRGB||Dd.ONE_MINUS_SRC_ALPHA},alphaBlendState:{blendMode:vt&&rt.equation.alpha||Zm.ADD,blendSrcFactor:vt&&rt.func.srcAlpha||Dd.ONE,blendDstFactor:vt&&rt.func.dstAlpha||Dd.ONE}}],blendConstant:vt?p2:void 0,depthWrite:re,depthCompare:re&&H.func||Ad.LESS,cullMode:ke&&xe.face||mv.NONE,stencilWrite:er,stencilFront:{compare:er?It.func.cmp:Ad.ALWAYS,passOp:It.opFront.zpass,failOp:It.opFront.fail,depthFailOp:It.opFront.zfail,mask:It.opFront.mask},stencilBack:{compare:er?It.func.cmp:Ad.ALWAYS,passOp:It.opBack.zpass,failOp:It.opBack.fail,depthFailOp:It.opBack.zfail,mask:It.opBack.mask}}})}},{key:"updateAttributesAndElements",value:function(){}},{key:"updateAttributes",value:function(){}},{key:"addUniforms",value:function(r){this.uniforms=(0,Se.Z)((0,Se.Z)({},this.uniforms),this.extractUniforms(r))}},{key:"draw",value:function(r,n){var t=this,a=(0,Se.Z)((0,Se.Z)({},this.options),r),u=a.count,c=u===void 0?0:u,m=a.instances,E=a.elements,H=a.uniforms,re=H===void 0?{}:H,xe=a.uniformBuffers,ke=a.textures;this.uniforms=(0,Se.Z)((0,Se.Z)({},this.uniforms),this.extractUniforms(re));var rt=this.service,vt=rt.renderPass,It=rt.currentFramebuffer,er=rt.width,Ar=rt.height,Or=rt.renderCache;this.pipeline=this.createPipeline(a,n);var rn=this.service.device,Ln=rn.swapChainHeight;if(rn.swapChainHeight=(It==null?void 0:It.height)||Ar,vt.setViewport(0,0,(It==null?void 0:It.width)||er,(It==null?void 0:It.height)||Ar),rn.swapChainHeight=Ln,vt.setPipeline(this.pipeline),vt.setStencilReference(1),vt.setVertexInput(this.inputLayout,this.vertexBuffers.map(function(Cn){return{buffer:Cn}}),E?{buffer:this.indexBuffer,offset:0}:null),xe&&(this.bindings=Or.createBindings({pipeline:this.pipeline,uniformBufferBindings:xe.map(function(Cn,qn){var Si=Cn;return{binding:qn,buffer:Si.get(),size:Si.size}}),samplerBindings:ke==null?void 0:ke.map(function(Cn){return{texture:Cn.texture,sampler:Cn.sampler}})})),this.bindings&&(vt.setBindings(this.bindings),Object.keys(this.uniforms).forEach(function(Cn){var qn=t.uniforms[Cn];qn instanceof IM?t.uniforms[Cn]=qn.get():qn instanceof RM&&(t.uniforms[Cn]=qn.get().texture)}),this.program.setUniformsLegacy(this.uniforms)),E){var wn=E.count;wn===0?vt.draw(c,m):vt.drawIndexed(wn,m)}else vt.draw(c,m)}},{key:"destroy",value:function(){var r,n,t;this.program.destroy(),(r=this.vertexBuffers)===null||r===void 0||r.forEach(function(a){return a.destroy()}),(n=this.indexBuffer)===null||n===void 0||n.destroy(),(t=this.bindings)===null||t===void 0||t.destroy(),this.inputLayout.destroy(),this.pipeline.destroy(),this.destroyed=!0}},{key:"initDepthDrawParams",value:function(r){var n=r.depth;if(n)return{enable:n.enable===void 0?!0:!!n.enable,mask:n.mask===void 0?!0:!!n.mask,func:Sj[n.func||Er.LESS],range:n.range||[0,1]}}},{key:"getBlendDrawParams",value:function(r){var n=r.blend,t=n||{},a=t.enable,u=t.func,c=t.equation,m=t.color,E=m===void 0?[0,0,0,0]:m;return{enable:!!a,func:{srcRGB:I2[u&&u.srcRGB||Er.SRC_ALPHA],srcAlpha:I2[u&&u.srcAlpha||Er.SRC_ALPHA],dstRGB:I2[u&&u.dstRGB||Er.ONE_MINUS_SRC_ALPHA],dstAlpha:I2[u&&u.dstAlpha||Er.ONE_MINUS_SRC_ALPHA]},equation:{rgb:xM[c&&c.rgb||Er.FUNC_ADD],alpha:xM[c&&c.alpha||Er.FUNC_ADD]},color:E}}},{key:"getStencilDrawParams",value:function(r){var n=r.stencil,t=n||{},a=t.enable,u=t.mask,c=u===void 0?4294967295:u,m=t.func,E=m===void 0?{cmp:Er.ALWAYS,ref:0,mask:4294967295}:m,H=t.opFront,re=H===void 0?{fail:Er.KEEP,zfail:Er.KEEP,zpass:Er.KEEP}:H,xe=t.opBack,ke=xe===void 0?{fail:Er.KEEP,zfail:Er.KEEP,zpass:Er.KEEP}:xe;return{enable:!!a,mask:c,func:(0,Se.Z)((0,Se.Z)({},E),{},{cmp:Tj[E.cmp]}),opFront:{fail:h_[re.fail],zfail:h_[re.zfail],zpass:h_[re.zpass],mask:E.mask},opBack:{fail:h_[ke.fail],zfail:h_[ke.zfail],zpass:h_[ke.zpass],mask:E.mask}}}},{key:"initCullDrawParams",value:function(r){var n=r.cull;if(n){var t=n.enable,a=n.face,u=a===void 0?Er.BACK:a;return{enable:!!t,face:Cj[u]}}}},{key:"extractUniforms",value:function(r){var n=this,t={};return Object.keys(r).forEach(function(a){n.extractUniformsRecursively(a,r[a],t,"")}),t}},{key:"extractUniformsRecursively",value:function(r,n,t,a){var u=this;if(n===null||typeof n=="number"||typeof n=="boolean"||Array.isArray(n)&&typeof n[0]=="number"||$j(n)||n===""||"resize"in n){t["".concat(a&&a+".").concat(r)]=n;return}Vj(n)&&Object.keys(n).forEach(function(c){u.extractUniformsRecursively(c,n[c],t,"".concat(a&&a+".").concat(r))}),Array.isArray(n)&&n.forEach(function(c,m){Object.keys(c).forEach(function(E){u.extractUniformsRecursively(E,c[E],t,"".concat(a&&a+".").concat(r,"[").concat(m,"]"))})})}}]),e}();function Gj(e){return typeof WebGL2RenderingContext!="undefined"&&e instanceof WebGL2RenderingContext?!0:!!(e&&e._version===2)}var OM,LM,D2=lo.isUndefined,Wj=(OM=(0,sa.b2)(),OM(LM=function(){function e(){var i=this;(0,We.Z)(this,e),(0,St.Z)(this,"uniformBuffers",[]),(0,St.Z)(this,"queryVerdorInfo",function(){return i.device.queryVendorInfo().platformString}),(0,St.Z)(this,"createModel",function(r){return new Hj(i.device,r,i)}),(0,St.Z)(this,"createAttribute",function(r){return new bj(i.device,r)}),(0,St.Z)(this,"createBuffer",function(r){return new Ij(i.device,r)}),(0,St.Z)(this,"createElements",function(r){return new jj(i.device,r)}),(0,St.Z)(this,"createTexture2D",function(r){return new IM(i.device,r)}),(0,St.Z)(this,"createFramebuffer",function(r){return new RM(i.device,r)}),(0,St.Z)(this,"useFramebuffer",function(r,n){i.currentFramebuffer=r,i.beginFrame(),n(),i.endFrame(),i.currentFramebuffer=null}),(0,St.Z)(this,"useFramebufferAsync",function(){var r=(0,Li.Z)(Ur().mark(function n(t,a){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return i.currentFramebuffer=t,i.preRenderPass=i.renderPass,i.beginFrame(),c.next=5,a();case 5:i.endFrame(),i.currentFramebuffer=null,i.renderPass=i.preRenderPass;case 8:case"end":return c.stop()}},n)}));return function(n,t){return r.apply(this,arguments)}}()),(0,St.Z)(this,"clear",function(r){var n=r.color,t=r.depth,a=r.stencil,u=r.framebuffer,c=u===void 0?null:u;if(c)c.clearOptions={color:n,depth:t,stencil:a};else{var m=i.queryVerdorInfo();if(m==="WebGL1"){var E=i.getGLContext();D2(a)?D2(t)||(E.clearDepth(t),E.clear(E.DEPTH_BUFFER_BIT)):(E.clearStencil(a),E.clear(E.STENCIL_BUFFER_BIT))}else if(m==="WebGL2"){var H=i.getGLContext();D2(a)?D2(t)||H.clearBufferfv(H.DEPTH,0,[t]):H.clearBufferiv(H.STENCIL,0,[a])}}}),(0,St.Z)(this,"viewport",function(r){var n=r.width,t=r.height;i.swapChain.configureSwapChain(n,t),i.createMainColorDepthRT(n,t),i.width=n,i.height=t}),(0,St.Z)(this,"readPixels",function(r){var n=r.framebuffer,t=r.x,a=r.y,u=r.width,c=r.height,m=i.device.createReadback(),E=n.colorTexture,H=m.readTextureSync(E,t,i.viewportOrigin===mg.LOWER_LEFT?a:i.height-a,u,c,new Uint8Array(u*c*4));return m.destroy(),H}),(0,St.Z)(this,"readPixelsAsync",function(){var r=(0,Li.Z)(Ur().mark(function n(t){var a,u,c,m,E,H,re,xe,ke,rt;return Ur().wrap(function(It){for(;;)switch(It.prev=It.next){case 0:return a=t.framebuffer,u=t.x,c=t.y,m=t.width,E=t.height,H=i.device.createReadback(),re=a.colorTexture,It.next=5,H.readTexture(re,u,i.viewportOrigin===mg.LOWER_LEFT?c:i.height-c,m,E,new Uint8Array(m*E*4));case 5:if(xe=It.sent,i.viewportOrigin!==mg.LOWER_LEFT)for(ke=0;ke1&&arguments[1]!==void 0?arguments[1]:{};return(0,We.Z)(this,r),t=i.call(this),(0,St.Z)((0,Fr.Z)(t),"isEnable",!1),(0,St.Z)((0,Fr.Z)(t),"onDragStart",function(u){t.box.style.display="block",t.startEvent=t.endEvent=u,t.syncBoxBound(),t.emit("selectstart",t.getLngLatBox(),t.startEvent,t.endEvent)}),(0,St.Z)((0,Fr.Z)(t),"onDragging",function(u){t.endEvent=u,t.syncBoxBound(),t.emit("selecting",t.getLngLatBox(),t.startEvent,t.endEvent)}),(0,St.Z)((0,Fr.Z)(t),"onDragEnd",function(u){t.endEvent=u,t.box.style.display="none",t.emit("selectend",t.getLngLatBox(),t.startEvent,t.endEvent)}),t.scene=n,t.options=a,t}return(0,ot.Z)(r,[{key:"container",get:function(){return this.scene.getMapService().getMarkerContainer()}},{key:"enable",value:function(){if(!this.isEnable){var t=this.options.className;if(this.scene.setMapStatus({dragEnable:!1}),this.container.style.cursor="crosshair",!this.box){var a=Vo("div",void 0,this.container);a.classList.add("l7-select-box"),t&&a.classList.add(t),a.style.display="none",this.box=a}this.scene.on("dragstart",this.onDragStart),this.scene.on("dragging",this.onDragging),this.scene.on("dragend",this.onDragEnd),this.isEnable=!0}}},{key:"disable",value:function(){this.isEnable&&(this.scene.setMapStatus({dragEnable:!0}),this.container.style.cursor="auto",this.scene.off("dragstart",this.onDragStart),this.scene.off("dragging",this.onDragging),this.scene.off("dragend",this.onDragEnd),this.isEnable=!1)}},{key:"syncBoxBound",value:function(){var t=this.startEvent,a=t.x,u=t.y,c=this.endEvent,m=c.x,E=c.y,H=Math.min(a,m),re=Math.min(u,E),xe=Math.abs(a-m),ke=Math.abs(u-E);this.box.style.top="".concat(re,"px"),this.box.style.left="".concat(H,"px"),this.box.style.width="".concat(xe,"px"),this.box.style.height="".concat(ke,"px")}},{key:"getLngLatBox",value:function(){var t=this.startEvent.lngLat,a=t.lng,u=t.lat,c=this.endEvent.lngLat,m=c.lng,E=c.lat;return ml([[a,u],[m,E]])}}]),r}(cu.EventEmitter),qj=function(){function e(i){(0,We.Z)(this,e);var r=i.id,n=i.map,t=i.canvas,a=i.renderer,u=a===void 0?"regl":a,c=og();this.container=c,n.setContainer(c,r,t),c.bind(sr.IRendererService).to(u==="regl"?Aj:Wj).inSingletonScope(),this.sceneService=c.get(sr.ISceneService),this.mapService=c.get(sr.IMapService),this.iconService=c.get(sr.IIconService),this.fontService=c.get(sr.IFontService),this.controlService=c.get(sr.IControlService),this.layerService=c.get(sr.ILayerService),this.debugService=c.get(sr.IDebugService),this.debugService.setEnable(i.debug),this.markerService=c.get(sr.IMarkerService),this.interactionService=c.get(sr.IInteractionService),this.popupService=c.get(sr.IPopupService),this.boxSelect=new Kj(this,{}),this.initComponent(r),this.sceneService.init(i),this.initControl()}return(0,ot.Z)(e,[{key:"map",get:function(){return this.mapService.map}},{key:"loaded",get:function(){return this.sceneService.loaded}},{key:"getServiceContainer",value:function(){return this.container}},{key:"getSize",value:function(){return this.mapService.getSize()}},{key:"getMinZoom",value:function(){return this.mapService.getMinZoom()}},{key:"getMaxZoom",value:function(){return this.mapService.getMaxZoom()}},{key:"getType",value:function(){return this.mapService.getType()}},{key:"getMapContainer",value:function(){return this.mapService.getMapContainer()}},{key:"getMapCanvasContainer",value:function(){return this.mapService.getMapCanvasContainer()}},{key:"getMapService",value:function(){return this.mapService}},{key:"getDebugService",value:function(){return this.debugService}},{key:"exportPng",value:function(){var i=(0,Li.Z)(Ur().mark(function n(t){return Ur().wrap(function(u){for(;;)switch(u.prev=u.next){case 0:return u.abrupt("return",this.sceneService.exportPng(t));case 1:case"end":return u.stop()}},n,this)}));function r(n){return i.apply(this,arguments)}return r}()},{key:"exportMap",value:function(){var i=(0,Li.Z)(Ur().mark(function n(t){return Ur().wrap(function(u){for(;;)switch(u.prev=u.next){case 0:return u.abrupt("return",this.sceneService.exportPng(t));case 1:case"end":return u.stop()}},n,this)}));function r(n){return i.apply(this,arguments)}return r}()},{key:"registerRenderService",value:function(r){var n=this;if(this.sceneService.loaded){var t=new r(this);t.init()}else this.on("loaded",function(){var a=new r(n);a.init()})}},{key:"setBgColor",value:function(r){this.mapService.setBgColor(r)}},{key:"addLayer",value:function(r){var n=this,t=Rm(this.container);if(r.setContainer(t,this.container),this.sceneService.addLayer(r),r.inited){var a=this.initMask(r);this.addMask(a,r.id)}else r.on("inited",function(){var u=n.initMask(r);n.addMask(u,r.id)})}},{key:"initMask",value:function(r){var n=r.getLayerConfig(),t=n.mask,a=n.maskfence,u=n.maskColor,c=u===void 0?"#000":u,m=n.maskOpacity,E=m===void 0?0:m;if(!(!t||!a)){var H=new qx().source(a).shape("fill").style({color:c,opacity:E});return H}}},{key:"addMask",value:function(r,n){if(r){var t=this.getLayer(n);if(t){var a=Rm(this.container);r.setContainer(a,this.container),t.addMaskLayer(r),this.sceneService.addMask(r)}else console.warn("parent layer not find!")}}},{key:"getPickedLayer",value:function(){return this.layerService.pickedLayerId}},{key:"getLayers",value:function(){return this.layerService.getLayers()}},{key:"getLayer",value:function(r){return this.layerService.getLayer(r)}},{key:"getLayerByName",value:function(r){return this.layerService.getLayerByName(r)}},{key:"removeLayer",value:function(){var i=(0,Li.Z)(Ur().mark(function n(t,a){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.next=2,this.layerService.remove(t,a);case 2:case"end":return c.stop()}},n,this)}));function r(n,t){return i.apply(this,arguments)}return r}()},{key:"removeAllLayer",value:function(){var i=(0,Li.Z)(Ur().mark(function n(){return Ur().wrap(function(a){for(;;)switch(a.prev=a.next){case 0:return a.next=2,this.layerService.removeAllLayers();case 2:case"end":return a.stop()}},n,this)}));function r(){return i.apply(this,arguments)}return r}()},{key:"render",value:function(){this.sceneService.render()}},{key:"setEnableRender",value:function(r){this.layerService.setEnableRender(r)}},{key:"addIconFont",value:function(r,n){this.fontService.addIconFont(r,n)}},{key:"addIconFonts",value:function(r){var n=this;r.forEach(function(t){var a=(0,gi.Z)(t,2),u=a[0],c=a[1];n.fontService.addIconFont(u,c)})}},{key:"addFontFace",value:function(r,n){var t=this;this.fontService.once("fontloaded",function(a){t.emit("fontloaded",a)}),this.fontService.addFontFace(r,n)}},{key:"addImage",value:function(){var i=(0,Li.Z)(Ur().mark(function n(t,a){return Ur().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.next=2,this.iconService.addImage(t,a);case 2:case"end":return c.stop()}},n,this)}));function r(n,t){return i.apply(this,arguments)}return r}()},{key:"hasImage",value:function(r){return this.iconService.hasImage(r)}},{key:"removeImage",value:function(r){this.iconService.removeImage(r)}},{key:"addIconFontGlyphs",value:function(r,n){this.fontService.addIconGlyphs(n)}},{key:"addControl",value:function(r){this.controlService.addControl(r,this.container)}},{key:"removeControl",value:function(r){this.controlService.removeControl(r)}},{key:"getControlByName",value:function(r){return this.controlService.getControlByName(r)}},{key:"addMarker",value:function(r){this.markerService.addMarker(r)}},{key:"addMarkerLayer",value:function(r){this.markerService.addMarkerLayer(r)}},{key:"removeMarkerLayer",value:function(r){this.markerService.removeMarkerLayer(r)}},{key:"removeAllMarkers",value:function(){this.markerService.removeAllMarkers()}},{key:"removeAllMakers",value:function(){console.warn("removeAllMakers \u5DF2\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528 removeAllMarkers"),this.markerService.removeAllMarkers()}},{key:"addPopup",value:function(r){this.popupService.addPopup(r)}},{key:"removePopup",value:function(r){this.popupService.removePopup(r)}},{key:"on",value:function(r,n){if(tE.includes(r)){var t;(t=this.boxSelect)===null||t===void 0||t.on(r,n)}else Jm.includes(r)?this.sceneService.on(r,n):this.mapService.on(r,n)}},{key:"once",value:function(r,n){if(tE.includes(r)){var t;(t=this.boxSelect)===null||t===void 0||t.once(r,n)}else Jm.includes(r)?this.sceneService.once(r,n):this.mapService.once(r,n)}},{key:"emit",value:function(r,n){Jm.indexOf(r)===-1?this.mapService.on(r,n):this.sceneService.emit(r,n)}},{key:"off",value:function(r,n){if(tE.includes(r)){var t;(t=this.boxSelect)===null||t===void 0||t.off(r,n)}else Jm.includes(r)?this.sceneService.off(r,n):this.mapService.off(r,n)}},{key:"getZoom",value:function(){return this.mapService.getZoom()}},{key:"getCenter",value:function(r){return this.mapService.getCenter(r)}},{key:"setCenter",value:function(r,n){return this.mapService.setCenter(r,n)}},{key:"getPitch",value:function(){return this.mapService.getPitch()}},{key:"setPitch",value:function(r){return this.mapService.setPitch(r)}},{key:"getRotation",value:function(){return this.mapService.getRotation()}},{key:"getBounds",value:function(){return this.mapService.getBounds()}},{key:"setRotation",value:function(r){this.mapService.setRotation(r)}},{key:"zoomIn",value:function(){this.mapService.zoomIn()}},{key:"zoomOut",value:function(){this.mapService.zoomOut()}},{key:"panTo",value:function(r){this.mapService.panTo(r)}},{key:"panBy",value:function(r,n){this.mapService.panBy(r,n)}},{key:"getContainer",value:function(){return this.mapService.getContainer()}},{key:"setZoom",value:function(r){this.mapService.setZoom(r)}},{key:"fitBounds",value:function(r,n){var t=this.sceneService.getSceneConfig(),a=t.fitBoundsOptions,u=t.animate;this.mapService.fitBounds(r,n||(0,Se.Z)((0,Se.Z)({},a),{},{animate:u}))}},{key:"setZoomAndCenter",value:function(r,n){this.mapService.setZoomAndCenter(r,n)}},{key:"setMapStyle",value:function(r){this.mapService.setMapStyle(r)}},{key:"setMapStatus",value:function(r){this.mapService.setMapStatus(r)}},{key:"pixelToLngLat",value:function(r){return this.mapService.pixelToLngLat(r)}},{key:"lngLatToPixel",value:function(r){return this.mapService.lngLatToPixel(r)}},{key:"containerToLngLat",value:function(r){return this.mapService.containerToLngLat(r)}},{key:"lngLatToContainer",value:function(r){return this.mapService.lngLatToContainer(r)}},{key:"destroy",value:function(){this.sceneService.destroy()}},{key:"registerPostProcessingPass",value:function(r,n){this.container.bind(sr.IPostProcessingPass).to(r).whenTargetNamed(n)}},{key:"enableShaderPick",value:function(){this.layerService.enableShaderPick()}},{key:"diasbleShaderPick",value:function(){this.layerService.disableShaderPick()}},{key:"enableBoxSelect",value:function(){var r=this,n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.boxSelect.enable(),n&&this.boxSelect.once("selectend",function(){r.disableBoxSelect()})}},{key:"disableBoxSelect",value:function(){this.boxSelect.disable()}},{key:"getProtocol",value:function(r){return oi.REGISTERED_PROTOCOLS[r]}},{key:"startAnimate",value:function(){this.layerService.startAnimate()}},{key:"stopAnimate",value:function(){this.layerService.stopAnimate()}},{key:"getPointSizeRange",value:function(){return this.sceneService.getPointSizeRange()}},{key:"initComponent",value:function(r){this.controlService.init({container:Da(r)},this.container),this.markerService.init(this.container),this.popupService.init(this.container)}},{key:"initControl",value:function(){var r=this.sceneService.getSceneConfig(),n=r.logoVisible,t=r.logoPosition;n&&this.addControl(new IE({position:t}))}}],[{key:"addProtocol",value:function(r,n){oi.REGISTERED_PROTOCOLS[r]=n}},{key:"removeProtocol",value:function(r){delete oi.REGISTERED_PROTOCOLS[r]}}]),e}(),Qj="2.20.15"},7292:function(Ye,ye,A){"use strict";A.d(ye,{FM:function(){return xh},Co:function(){return lf},br:function(){return xp},L6:function(){return S0},ot:function(){return Kp},l_:function(){return y0},zP:function(){return da},yD:function(){return Gp},$2:function(){return ns},Kh:function(){return zu},Ie:function(){return qr},OB:function(){return $o},w3:function(){return p0},Jx:function(){return xs},CB:function(){return k0},ns:function(){return Bc},dW:function(){return rl},YY:function(){return Cc},jf:function(){return B0},Ly:function(){return m0}});var R=A(60965),V=A(77617),y=A(98621),p=A.n(y),$=function(K,ne){return K===void 0&&(K=[]),ne===void 0&&(ne=[]),p()(K,ne)},X=function(K){return function(ne,ue){var Ue=(0,V.useRef)(),Ut=(0,V.useRef)(0);(ue===void 0||!$(ue,Ue.current))&&(Ue.current=ue,Ut.current+=1),K(ne,[Ut.current])}},se=X(V.useEffect),ae=A(92310),ce=A.n(ae),le=A(63364);function De(K){return K===null}var we=De,Ee=A(59657),qe=A(21314),Ge="[object Number]";function ct(K){return typeof K=="number"||(0,qe.Z)(K)&&(0,Ee.Z)(K)==Ge}var Ve=ct,ut=A(49336);function Xe(K){"@babel/helpers - typeof";return Xe=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(ne){return typeof ne}:function(ne){return ne&&typeof Symbol=="function"&&ne.constructor===Symbol&&ne!==Symbol.prototype?"symbol":typeof ne},Xe(K)}function Rt(K,ne){var ue=typeof Symbol!="undefined"&&K[Symbol.iterator]||K["@@iterator"];if(!ue){if(Array.isArray(K)||(ue=gt(K))||ne&&K&&typeof K.length=="number"){ue&&(K=ue);var Ue=0,Ut=function(){};return{s:Ut,n:function(){return Ue>=K.length?{done:!0}:{done:!1,value:K[Ue++]}},e:function(kn){throw kn},f:Ut}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var vr=!0,Cr=!1,Jr;return{s:function(){ue=ue.call(K)},n:function(){var kn=ue.next();return vr=kn.done,kn},e:function(kn){Cr=!0,Jr=kn},f:function(){try{!vr&&ue.return!=null&&ue.return()}finally{if(Cr)throw Jr}}}}function gt(K,ne){if(K){if(typeof K=="string")return Ct(K,ne);var ue=Object.prototype.toString.call(K).slice(8,-1);if(ue==="Object"&&K.constructor&&(ue=K.constructor.name),ue==="Map"||ue==="Set")return Array.from(K);if(ue==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ue))return Ct(K,ne)}}function Ct(K,ne){(ne==null||ne>K.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ue0&&arguments[0]!==void 0?arguments[0]:{};return Object.entries(ne!=null?ne:{}).map(function(ue){var Ue=On(ue,2),Ut=Ue[0],vr=Ue[1],Cr=Xi(Ut),Jr=vr;return typeof Jr=="number"?Jr="".concat(Jr,"px"):typeof Jr=="string"&&(Jr=Jr.replace("'","")),"".concat(Cr," :").concat(Jr)}).join("; ")};function Ea(K,ne){return el(K)||dc(K,ne)||Ju(K,ne)||hs()}function hs(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ju(K,ne){if(K){if(typeof K=="string")return Fa(K,ne);var ue=Object.prototype.toString.call(K).slice(8,-1);if(ue==="Object"&&K.constructor&&(ue=K.constructor.name),ue==="Map"||ue==="Set")return Array.from(K);if(ue==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ue))return Fa(K,ne)}}function Fa(K,ne){(ne==null||ne>K.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ue1&&arguments[1]!==void 0?arguments[1]:!1;return Object.entries(K).sort(function(ue,Ue){var Ut=Ea(ue,1),vr=Ut[0],Cr=Ea(Ue,1),Jr=Cr[0];return vr.localeCompare(Jr)}).map(function(ue){var Ue=Ea(ue,2),Ut=Ue[0],vr=Ue[1],Cr=String(vr);return ne&&(Cr=window.encodeURI(String(vr))),"".concat(Ut,"=").concat(Cr)}).join("&")}function As(K,ne){return"".concat(K,"?").concat(fl(ne,!0))}function Rl(K){"@babel/helpers - typeof";return Rl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(ne){return typeof ne}:function(ne){return ne&&typeof Symbol=="function"&&ne.constructor===Symbol&&ne!==Symbol.prototype?"symbol":typeof ne},Rl(K)}function dl(){"use strict";dl=function(){return ne};var K,ne={},ue=Object.prototype,Ue=ue.hasOwnProperty,Ut=Object.defineProperty||function(Qi,Yn,Ti){Qi[Yn]=Ti.value},vr=typeof Symbol=="function"?Symbol:{},Cr=vr.iterator||"@@iterator",Jr=vr.asyncIterator||"@@asyncIterator",Mn=vr.toStringTag||"@@toStringTag";function kn(Qi,Yn,Ti){return Object.defineProperty(Qi,Yn,{value:Ti,enumerable:!0,configurable:!0,writable:!0}),Qi[Yn]}try{kn({},"")}catch(Qi){kn=function(Ti,ca,Qa){return Ti[ca]=Qa}}function $i(Qi,Yn,Ti,ca){var Qa=Yn&&Yn.prototype instanceof Du?Yn:Du,Oa=Object.create(Qa.prototype),Xl=new Eh(ca||[]);return Ut(Oa,"_invoke",{value:qc(Qi,Ti,Xl)}),Oa}function wa(Qi,Yn,Ti){try{return{type:"normal",arg:Qi.call(Yn,Ti)}}catch(ca){return{type:"throw",arg:ca}}}ne.wrap=$i;var Os="suspendedStart",Nu="suspendedYield",yl="executing",js="completed",$s={};function Du(){}function Ml(){}function Wl(){}var yf={};kn(yf,Cr,function(){return this});var Nf=Object.getPrototypeOf,cf=Nf&&Nf(Nf(Uh([])));cf&&cf!==ue&&Ue.call(cf,Cr)&&(yf=cf);var jc=Wl.prototype=Du.prototype=Object.create(yf);function eh(Qi){["next","throw","return"].forEach(function(Yn){kn(Qi,Yn,function(Ti){return this._invoke(Yn,Ti)})})}function uh(Qi,Yn){function Ti(Qa,Oa,Xl,Vc){var Pf=wa(Qi[Qa],Qi,Oa);if(Pf.type!=="throw"){var $d=Pf.arg,qh=$d.value;return qh&&Rl(qh)=="object"&&Ue.call(qh,"__await")?Yn.resolve(qh.__await).then(function(Xd){Ti("next",Xd,Xl,Vc)},function(Xd){Ti("throw",Xd,Xl,Vc)}):Yn.resolve(qh).then(function(Xd){$d.value=Xd,Xl($d)},function(Xd){return Ti("throw",Xd,Xl,Vc)})}Vc(Pf.arg)}var ca;Ut(this,"_invoke",{value:function(Oa,Xl){function Vc(){return new Yn(function(Pf,$d){Ti(Oa,Xl,Pf,$d)})}return ca=ca?ca.then(Vc,Vc):Vc()}})}function qc(Qi,Yn,Ti){var ca=Os;return function(Qa,Oa){if(ca===yl)throw new Error("Generator is already running");if(ca===js){if(Qa==="throw")throw Oa;return{value:K,done:!0}}for(Ti.method=Qa,Ti.arg=Oa;;){var Xl=Ti.delegate;if(Xl){var Vc=mf(Xl,Ti);if(Vc){if(Vc===$s)continue;return Vc}}if(Ti.method==="next")Ti.sent=Ti._sent=Ti.arg;else if(Ti.method==="throw"){if(ca===Os)throw ca=js,Ti.arg;Ti.dispatchException(Ti.arg)}else Ti.method==="return"&&Ti.abrupt("return",Ti.arg);ca=yl;var Pf=wa(Qi,Yn,Ti);if(Pf.type==="normal"){if(ca=Ti.done?js:Nu,Pf.arg===$s)continue;return{value:Pf.arg,done:Ti.done}}Pf.type==="throw"&&(ca=js,Ti.method="throw",Ti.arg=Pf.arg)}}}function mf(Qi,Yn){var Ti=Yn.method,ca=Qi.iterator[Ti];if(ca===K)return Yn.delegate=null,Ti==="throw"&&Qi.iterator.return&&(Yn.method="return",Yn.arg=K,mf(Qi,Yn),Yn.method==="throw")||Ti!=="return"&&(Yn.method="throw",Yn.arg=new TypeError("The iterator does not provide a '"+Ti+"' method")),$s;var Qa=wa(ca,Qi.iterator,Yn.arg);if(Qa.type==="throw")return Yn.method="throw",Yn.arg=Qa.arg,Yn.delegate=null,$s;var Oa=Qa.arg;return Oa?Oa.done?(Yn[Qi.resultName]=Oa.value,Yn.next=Qi.nextLoc,Yn.method!=="return"&&(Yn.method="next",Yn.arg=K),Yn.delegate=null,$s):Oa:(Yn.method="throw",Yn.arg=new TypeError("iterator result is not an object"),Yn.delegate=null,$s)}function Dh(Qi){var Yn={tryLoc:Qi[0]};1 in Qi&&(Yn.catchLoc=Qi[1]),2 in Qi&&(Yn.finallyLoc=Qi[2],Yn.afterLoc=Qi[3]),this.tryEntries.push(Yn)}function lh(Qi){var Yn=Qi.completion||{};Yn.type="normal",delete Yn.arg,Qi.completion=Yn}function Eh(Qi){this.tryEntries=[{tryLoc:"root"}],Qi.forEach(Dh,this),this.reset(!0)}function Uh(Qi){if(Qi||Qi===""){var Yn=Qi[Cr];if(Yn)return Yn.call(Qi);if(typeof Qi.next=="function")return Qi;if(!isNaN(Qi.length)){var Ti=-1,ca=function Qa(){for(;++Ti=0;--Qa){var Oa=this.tryEntries[Qa],Xl=Oa.completion;if(Oa.tryLoc==="root")return ca("end");if(Oa.tryLoc<=this.prev){var Vc=Ue.call(Oa,"catchLoc"),Pf=Ue.call(Oa,"finallyLoc");if(Vc&&Pf){if(this.prev=0;--ca){var Qa=this.tryEntries[ca];if(Qa.tryLoc<=this.prev&&Ue.call(Qa,"finallyLoc")&&this.prev=0;--Ti){var ca=this.tryEntries[Ti];if(ca.finallyLoc===Yn)return this.complete(ca.completion,ca.afterLoc),lh(ca),$s}},catch:function(Yn){for(var Ti=this.tryEntries.length-1;Ti>=0;--Ti){var ca=this.tryEntries[Ti];if(ca.tryLoc===Yn){var Qa=ca.completion;if(Qa.type==="throw"){var Oa=Qa.arg;lh(ca)}return Oa}}throw new Error("illegal catch attempt")},delegateYield:function(Yn,Ti,ca){return this.delegate={iterator:Uh(Yn),resultName:Ti,nextLoc:ca},this.method==="next"&&(this.arg=K),$s}},ne}function _c(K,ne,ue,Ue,Ut,vr,Cr){try{var Jr=K[vr](Cr),Mn=Jr.value}catch(kn){ue(kn);return}Jr.done?ne(Mn):Promise.resolve(Mn).then(Ue,Ut)}function lu(K){return function(){var ne=this,ue=arguments;return new Promise(function(Ue,Ut){var vr=K.apply(ne,ue);function Cr(Mn){_c(vr,Ue,Ut,Cr,Jr,"next",Mn)}function Jr(Mn){_c(vr,Ue,Ut,Cr,Jr,"throw",Mn)}Cr(void 0)})}}var Pn=function(){var K=lu(dl().mark(function ne(ue,Ue){return dl().wrap(function(vr){for(;;)switch(vr.prev=vr.next){case 0:if(ue!=="Map"){vr.next=2;break}return vr.abrupt("return",new R.Map(Ue));case 2:if(ue!=="Gaode"){vr.next=6;break}return vr.abrupt("return",new R.GaodeMap(Ue));case 6:if(ue!=="GaodeV1"){vr.next=10;break}return vr.abrupt("return",new R.GaodeMapV1(Ue));case 10:if(ue!=="GaodeV2"){vr.next=12;break}return vr.abrupt("return",new R.GaodeMapV2(Ue));case 12:if(ue!=="Tencent"){vr.next=14;break}return vr.abrupt("return",Promise.resolve(Promise.resolve().then(A.bind(A,60965))).then(function(Cr){var Jr=Cr.TencentMap;return new Jr(Ue)}));case 14:if(ue!=="Baidu"){vr.next=16;break}return vr.abrupt("return",Promise.resolve(Promise.resolve().then(A.bind(A,60965))).then(function(Cr){var Jr=Cr.BaiduMap;return new Jr(Ue)}));case 16:return vr.abrupt("return",Promise.resolve(Promise.resolve().then(A.bind(A,60965))).then(function(Cr){var Jr=Cr.Mapbox;return new Jr(Ue)}));case 17:case"end":return vr.stop()}},ne)}));return function(ue,Ue){return K.apply(this,arguments)}}(),Wr=function(K,ne){return K?K.map(function(ue,Ue){return Object.is(K[Ue],ne==null?void 0:ne[Ue])?-1:Ue}).filter(function(ue){return ue>=0}):ne?ne.map(function(ue,Ue){return Ue}):[]},Ci=function(K,ne){var ue=(0,V.useRef)();(0,V.useEffect)(function(){var Ue=Wr(ue.current,ne),Ut=ue.current;return ue.current=ne,K(Ue,Ut,ne)},ne)},at=Ci,Vt=A(41806),gr={onLoaded:"loaded",onDestroy:"destroy",onResize:"resize",onMapMove:"mapmove",onMoveStart:"movestart",onMoveEnd:"moveend",onZoomChange:"zoomchange",onZoomStart:"zoomstart",onZoomEnd:"zoomend",onClick:"click",onDblclick:"dblclick",onContextMenu:"contextmenu",onMouseMove:"mousemove",onMouseWheel:"mousewheel",onMouseDown:"mousedown",onMouseOver:"mouseover",onMouseOut:"mouseout",onMouseUp:"mouseup",onDragStart:"dragstart",onDragging:"dragging",onDragEnd:"dragend"},gn=Object.keys(gr);function un(K){return mn(K)||Na(K)||ho(K)||Zi()}function Zi(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ho(K,ne){if(K){if(typeof K=="string")return Lr(K,ne);var ue=Object.prototype.toString.call(K).slice(8,-1);if(ue==="Object"&&K.constructor&&(ue=K.constructor.name),ue==="Map"||ue==="Set")return Array.from(K);if(ue==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ue))return Lr(K,ne)}}function Na(K){if(typeof Symbol!="undefined"&&K[Symbol.iterator]!=null||K["@@iterator"]!=null)return Array.from(K)}function mn(K){if(Array.isArray(K))return Lr(K)}function Lr(K,ne){(ne==null||ne>K.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ue=0)&&Object.prototype.propertyIsEnumerable.call(K,Ue)&&(ue[Ue]=K[Ue])}return ue}function ta(K,ne){if(K==null)return{};var ue={},Ue=Object.keys(K),Ut,vr;for(vr=0;vr=0)&&(ue[Ut]=K[Ut]);return ue}var Ra=V.createContext(null),ns=(0,V.memo)((0,V.forwardRef)(function(ne,ue){var Ue=ne.id,Ut=ne.style,vr=ne.className,Cr=ne.map,Jr=ne.mapType,Mn=Jr===void 0?"Gaode":Jr,kn=ne.mapOptions,$i=kn===void 0?{}:kn,wa=ne.onLayerManagerCreated,Os=ne.onSceneLoaded,Nu=ne.children,yl=Da(ne,Zr),js=(0,V.useRef)(),$s=(0,V.useState)(null),Du=ro($s,2),Ml=Du[0],Wl=Du[1],yf=(0,V.useRef)({scene:null,layerManager:null}),Nf=yf.current;(0,V.useEffect)(function(){var jc,eh=!0,uh=(0,le.Z)(Cr)?Pn(Mn,$i):typeof Cr=="function"?Cr():Cr;return Promise.resolve(uh).then(function(qc){if(eh){jc=new R.Scene(In(In({},yl),{},{id:js.current,map:qc}));var mf=new st({scene:jc});Nf.scene=jc,Nf.layerManager=mf,jc.once("loaded",function(){Os&&Os(jc),wa&&wa(mf),Wl(jc)})}}).catch(function(qc){console.error(qc)}),function(){eh=!1,jc&&(Nf.scene=null,Nf.layerManager=null,jc.destroy())}},[]),yr(Ml,ne),(0,V.useImperativeHandle)(ue,function(){return{getScene:function(){return Ml},getMap:function(){return Ml.map}}},[Ml]),(0,V.useEffect)(function(){Ml&&$i.style&&Ml.setMapStyle($i.style)},[$i.style]),se(function(){we(Ml)||($i.center&&Ve($i.zoom)?Ml.setZoomAndCenter($i.zoom,$i.center):Ve($i.zoom)?Ml.setZoom($i.zoom):$i.center&&Ml.setCenter($i.center))},[$i.zoom,$i.center]),(0,V.useEffect)(function(){Ml&&Ve($i.pitch)&&Ml.setPitch($i.pitch)},[$i.pitch]),(0,V.useEffect)(function(){Ml&&Ve($i.rotation)&&Ml.setRotation($i.rotation)},[$i.rotation]);var cf=(0,V.useMemo)(function(){return In({position:"relative"},Ut)},[Ut]);return V.createElement("div",{id:Ue,ref:js,style:cf,className:ce()("larkmap",vr)},Ml&&V.createElement(Ra.Provider,{value:Nf},Nu))})),Vo=A(8142),bs=function(){var ne=(0,V.useContext)(Ra);if(!ne)throw new Error("The useScene must be used in the LarkMap container");var ue=ne.scene;return ue},Js=function(ne,ue,Ue){var Ut=bs(),vr=(0,V.useRef)();(0,V.useEffect)(function(){var Cr=new R.Control(Ue);return Cr.onAdd=function(){return ne(Ut)},Cr.onRemove=function(){},vr.current=Cr,Ut.addControl(Cr),function(){typeof ue=="function"&&ue(Ut),vr.current=null,Ut.removeControl(Cr)}},[]),(0,Vo.Z)(function(){var Cr;(Cr=vr.current)===null||Cr===void 0||Cr.setOptions(Ue)},[Ue])},Hu=function(){var ne=(0,V.useContext)(Ra);if(!ne)throw new Error("The useLayerManager must be used in the LarkMap container");var ue=ne.layerManager;return ue};function Of(K,ne){return oo(K)||wi(K,ne)||xn(K,ne)||en()}function en(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function xn(K,ne){if(K){if(typeof K=="string")return Vi(K,ne);var ue=Object.prototype.toString.call(K).slice(8,-1);if(ue==="Object"&&K.constructor&&(ue=K.constructor.name),ue==="Map"||ue==="Set")return Array.from(K);if(ue==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ue))return Vi(K,ne)}}function Vi(K,ne){(ne==null||ne>K.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ue-1;)Lf.call(K,vr,1);return K},_l=null,cn=Array.prototype.splice,an=function(ne,ue){if(!isArrayLike(ne))return[];for(var Ue=ne?ue.length:0,Ut=Ue-1;Ue--;){var vr=void 0,Cr=ue[Ue];(Ue===Ut||Cr!==vr)&&(vr=Cr,cn.call(ne,Cr,1))}return ne},Xn=null,vi=function(K,ne,ue){if(!Eu(K)&&!Zs(K))return K;var Ue=ue;return Vs(K,function(Ut,vr){Ue=ne(Ue,Ut,vr)}),Ue},to=vi,zo=function(K,ne){var ue=[];if(!isArrayLike(K))return ue;for(var Ue=-1,Ut=[],vr=K.length;++Uevr[Jr])return 1;if(Ut[Jr]0},cl=null,Us=function(K,ne){if(isArray(K)){for(var ue,Ue=-1/0,Ut=0;UtUe&&(ue=vr,Ue=Cr)}return ue}},vl=function(K,ne){if(isArray(K)){for(var ue,Ue=1/0,Ut=0;UtJr&&$i>Jr);)if(Mn.push(kn),Jr-=$i,Cr=Cr.substr(Ut),!Cr)return Mn.join("");for(;kn=Cr.substr(0,1),$i=measureTextWidth(kn,ue),!($i+vr>Jr);)if(Mn.push(kn),Jr-=$i,Cr=Cr.substr(1),!Cr)return Mn.join("");return""+Mn.join("")+Ue},ie=function(){function K(){this.map={}}return K.prototype.has=function(ne){return this.map[ne]!==void 0},K.prototype.get=function(ne,ue){var Ue=this.map[ne];return Ue===void 0?ue:Ue},K.prototype.set=function(ne,ue){this.map[ne]=ue},K.prototype.clear=function(){this.map={}},K.prototype.delete=function(ne){delete this.map[ne]},K.prototype.size=function(){return Object.keys(this.map).length},K}(),f=null;function L(K,ne){return function(){for(var ue=[],Ue=0;Ue=0)&&Object.prototype.propertyIsEnumerable.call(K,Ue)&&(ue[Ue]=K[Ue])}return ue}function xr(K,ne){if(K==null)return{};var ue={},Ue=Object.keys(K),Ut,vr;for(vr=0;vr=0)&&(ue[Ut]=K[Ut]);return ue}var Ni=function(ne,ue){var Ue=ue.onCreated,Ut=ue.source,vr=Ai(ue,pr),Cr=Hu(),Jr=(0,V.useRef)(),Mn=(0,V.useRef)(vr),kn=(0,V.useRef)(Ut);return Jr.current||(Jr.current=new ne(ue),Ue&&Jr.current.once("inited",function(){return Ue(Jr.current)}),Cr.addLayer(Jr.current)),(0,Vo.Z)(function(){if(Jr.current){var $i=!(0,Ce.Z)(Mn.current,vr);$i&&(Jr.current.update(vr),Mn.current=Qt(vr))}},[vr]),(0,Vo.Z)(function(){if(Jr.current){var $i=Ut.data,wa=Ai(Ut,zr),Os=kn.current,Nu=Os.data,yl=Ai(Os,jr),js=$i!==Nu||!(0,Ce.Z)(wa,yl);js&&(Jr.current.changeData(Ut),kn.current=Hr({},Ut))}},[Ut]),(0,V.useEffect)(function(){return function(){Jr.current&&(Cr.removeLayer(Jr.current),Jr.current=null)}},[]),Jr},uo={onRemove:"remove",onShow:"show",onHide:"hide",onDataUpdate:"dataUpdate",onLegend:"legend",onLegendColor:"legend:color",onLegendSize:"legend:size",onClick:"click",onUnClick:"unclick",onDblClick:"dblclick",onUndblclick:"undblclick",onContextMenu:"contextmenu",onUnContextMenu:"uncontextmenu",onMouseEnter:"mouseenter",onMouseMove:"mousemove",onMouseOut:"mouseout",onMouseUp:"mouseup",onMouseDown:"mousedown",onUnMousemove:"unmousemove",onUnMouseup:"unmouseup",onUnMousedown:"unmousedown",onUnPick:"unpick"},oa=function(ne,ue){var Ue=arguments.length>2&&arguments[2]!==void 0?arguments[2]:uo,Ut=(0,V.useMemo)(function(){return Object.keys(Ue)},[Ue]),vr=function($i){Ut.forEach(function(wa){var Os=Ue[wa],Nu=ue[wa];wa&&Nu&&ne[$i](Os,Nu)})},Cr=function(){return vr("on")},Jr=function(){return vr("off")},Mn=(0,V.useRef)(!0);Mn.current&&Cr(),(0,V.useEffect)(function(){return Mn.current?Mn.current=!1:Cr(),function(){Jr()}},Ut.map(function(kn){return ue[kn]})),(0,Vt.Z)(function(){Jr()})},da=(0,V.memo)((0,V.forwardRef)(function(ne,ue){var Ue=Ni(pe,ne);return oa(Ue.current,ne),(0,V.useImperativeHandle)(ue,function(){return Ue.current}),null})),Fs=null,hu=function(K){(0,si.ZT)(ne,K);function ne(){var ue=K.apply(this,(0,si.ev)([],(0,si.CR)(arguments),!1))||this;return ue.type="lineLayer",ue}return ne.prototype.createLayer=function(){var ue=this.getLayerConfig(),Ue=new R.LineLayer(ue);return Ue},ne}(U),qr=(0,V.memo)((0,V.forwardRef)(function(ne,ue){var Ue=Ni(hu,ne);return oa(Ue.current,ne),(0,V.useImperativeHandle)(ue,function(){return Ue.current}),null})),Zu=function(K){(0,si.ZT)(ne,K);function ne(){var ue=K.apply(this,(0,si.ev)([],(0,si.CR)(arguments),!1))||this;return ue.type="pointLayer",ue}return ne.prototype.createLayer=function(){var ue=this.getLayerConfig(),Ue=new R.PointLayer(ue);return Ue},ne}(U),Bc=(0,V.memo)((0,V.forwardRef)(function(ne,ue){var Ue=Ni(Zu,ne);return oa(Ue.current,ne),(0,V.useImperativeHandle)(ue,function(){return Ue.current}),null})),ou=function(K){(0,si.ZT)(ne,K);function ne(){var ue=K.apply(this,(0,si.ev)([],(0,si.CR)(arguments),!1))||this;return ue.type="polygonLayer",ue}return ne.prototype.createLayer=function(){var ue=this.getLayerConfig(),Ue=new R.PolygonLayer(ue);return Ue},ne}(U),rl=(0,V.memo)((0,V.forwardRef)(function(ne,ue){var Ue=Ni(ou,ne);return oa(Ue.current,ne),(0,V.useImperativeHandle)(ue,function(){return Ue.current}),null})),Nc=function(K){(0,si.ZT)(ne,K);function ne(){var ue=K.apply(this,(0,si.ev)([],(0,si.CR)(arguments),!1))||this;return ue.type="rasterLayer",ue}return ne.prototype.createLayer=function(){var ue=this.getLayerConfig(),Ue=new R.RasterLayer(ue);return Ue},ne}(U),Cc=(0,V.memo)((0,V.forwardRef)(function(ne,ue){var Ue=Ni(Nc,ne);return oa(Ue.current,ne),(0,V.useImperativeHandle)(ue,function(){return Ue.current}),null})),Gl=null,Oc;(function(K){K.BubbleLayer="bubbleLayer",K.ChoroplethLayer="choroplethLayer",K.IconImageLayer="iconImageLayer",K.IconFontLayer="iconFontLayer",K.FlowLayer="flowLayer"})(Oc||(Oc={}));var bc=function(K){(0,si.ZT)(ne,K);function ne(ue,Ue){ue===void 0&&(ue=[]),Ue===void 0&&(Ue={});var Ut=K.call(this)||this;Ut.layerMap=new Map,Ut.name=Ue.name?Ue.name:W("layerGroup");for(var vr=0;vrK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ue=0)&&Object.prototype.propertyIsEnumerable.call(K,Ue)&&(ue[Ue]=K[Ue])}return ue}function Zo(K,ne){if(K==null)return{};var ue={},Ue=Object.keys(K),Ut,vr;for(vr=0;vr=0)&&(ue[Ut]=K[Ut]);return ue}var ao="SECRET_COMBOBOX_MODE_DO_NOT_USE",Iu="larkmap-select",Kc=function(ne,ue){var Ue=ne.prefixCls,Ut=ne.bordered,vr=Ut===void 0?!0:Ut,Cr=ne.className,Jr=ne.getPopupContainer,Mn=ne.dropdownClassName,kn=ne.popupClassName,$i=ne.listHeight,wa=$i===void 0?256:$i,Os=ne.placement,Nu=ne.listItemHeight,yl=Nu===void 0?24:Nu,js=ne.disabled,$s=ne.notFoundContent,Du=ei(ne,hl),Ml=V.useMemo(function(){var Nf=Du,cf=Nf.mode;if(cf!=="combobox")return cf===ao?"combobox":cf},[Du]),Wl=(0,Yc.Z)(Du,"suffixIcon","itemIcon"),yf=ce()(of({},"".concat(Iu,"-borderless"),!vr),Cr);return V.createElement(Qf.ZP,Gs({ref:ue},Wl,{listHeight:wa,listItemHeight:yl,mode:Ml,prefixCls:Iu,placement:Os,notFoundContent:$s!=null?$s:"\u5F53\u524D\u65E0\u6570\u636E",className:yf,getPopupContainer:Jr,dropdownClassName:kn,disabled:js}))},sa=V.forwardRef(Kc);sa.SECRET_COMBOBOX_MODE_DO_NOT_USE=ao,sa.Option=Qf.Wx,sa.OptGroup=Qf.Xo;var Rr=sa;function sr(K){"@babel/helpers - typeof";return sr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(ne){return typeof ne}:function(ne){return ne&&typeof Symbol=="function"&&ne.constructor===Symbol&&ne!==Symbol.prototype?"symbol":typeof ne},sr(K)}var ti=["searchParams","showDistrict","showAddress","onSearchFinish","onChange"],_o=["keywords","privateKey"];function bo(){return bo=Object.assign?Object.assign.bind():function(K){for(var ne=1;ne=0;--Qa){var Oa=this.tryEntries[Qa],Xl=Oa.completion;if(Oa.tryLoc==="root")return ca("end");if(Oa.tryLoc<=this.prev){var Vc=Ue.call(Oa,"catchLoc"),Pf=Ue.call(Oa,"finallyLoc");if(Vc&&Pf){if(this.prev=0;--ca){var Qa=this.tryEntries[ca];if(Qa.tryLoc<=this.prev&&Ue.call(Qa,"finallyLoc")&&this.prev=0;--Ti){var ca=this.tryEntries[Ti];if(ca.finallyLoc===Yn)return this.complete(ca.completion,ca.afterLoc),lh(ca),$s}},catch:function(Yn){for(var Ti=this.tryEntries.length-1;Ti>=0;--Ti){var ca=this.tryEntries[Ti];if(ca.tryLoc===Yn){var Qa=ca.completion;if(Qa.type==="throw"){var Oa=Qa.arg;lh(ca)}return Oa}}throw new Error("illegal catch attempt")},delegateYield:function(Yn,Ti,ca){return this.delegate={iterator:Uh(Yn),resultName:Ti,nextLoc:ca},this.method==="next"&&(this.arg=K),$s}},ne}function ji(K){return D(K)||jn(K)||mr(K)||Di()}function Di(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function jn(K){if(typeof Symbol!="undefined"&&K[Symbol.iterator]!=null||K["@@iterator"]!=null)return Array.from(K)}function D(K){if(Array.isArray(K))return pn(K)}function P(K,ne){var ue=Object.keys(K);if(Object.getOwnPropertySymbols){var Ue=Object.getOwnPropertySymbols(K);ne&&(Ue=Ue.filter(function(Ut){return Object.getOwnPropertyDescriptor(K,Ut).enumerable})),ue.push.apply(ue,Ue)}return ue}function F(K){for(var ne=1;neK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ue=0)&&Object.prototype.propertyIsEnumerable.call(K,Ue)&&(ue[Ue]=K[Ue])}return ue}function no(K,ne){if(K==null)return{};var ue={},Ue=Object.keys(K),Ut,vr;for(vr=0;vr=0)&&(ue[Ut]=K[Ut]);return ue}var Wa=Rr.Option,ha=function(ne){var ue=ne.searchParams,Ue=ne.showDistrict,Ut=ne.showAddress,vr=ne.onSearchFinish,Cr=ne.onChange,Jr=ci(ne,ti),Mn=(0,V.useState)([]),kn=Ot(Mn,2),$i=kn[0],wa=kn[1];(0,V.useEffect)(function(){vr==null||vr($i)},[vr,$i]);var Os=(0,ed.Z)(function(){var js=Ze(Pi().mark(function $s(Du){var Ml,Wl,yf,Nf,cf,jc,eh;return Pi().wrap(function(qc){for(;;)switch(qc.prev=qc.next){case 0:if(Du){qc.next=3;break}return wa([]),qc.abrupt("return");case 3:return Wl=ue.keywords,yf=ue.privateKey,Nf=ci(ue,_o),cf=F(F({},Nf),{},{keywords:[].concat(ji((Wl!=null?Wl:"").split("|")),[Du]).filter(function(mf){return!!mf}).join("|")}),yf&&(cf.sig=$h()(fl(cf,!1)+yf)),jc="".concat(Od,"?").concat(fl(cf,!0)),qc.next=9,fetch(jc);case 9:return qc.next=11,qc.sent.json();case 11:eh=qc.sent,wa(((Ml=eh==null?void 0:eh.tips)!==null&&Ml!==void 0?Ml:[]).filter(function(mf){return mf.location&&mf.location.length}).map(function(mf){var Dh=mf.location.split(","),lh=Ot(Dh,2),Eh=lh[0],Uh=lh[1];return mf.longitude=+Eh,mf.latitude=+Uh,mf}));case 13:case"end":return qc.stop()}},$s)}));return function($s){return js.apply(this,arguments)}}(),{wait:1e3}),Nu=Os.run,yl=(0,V.useCallback)(function(js){var $s=js&&$i.find(function(Du){return Du.name===js});Cr==null||Cr(js||void 0,$s||void 0)},[Cr,$i]);return V.createElement(Rr,bo({className:"".concat(nf),onSearch:Nu,onChange:yl,clearIcon:function(){return null}},Jr),$i.map(function(js){var $s="".concat(Ue?js.district:"").concat(Ut?js.address:"");return V.createElement(Wa,{key:js.id,value:js.name},V.createElement("div",{title:js.name,className:"".concat(nf,"__option-name")},js.name),$s&&V.createElement("div",{title:$s,className:"".concat(nf,"__option-tip")},$s))}))};ha.defaultProps={placeholder:"\u8BF7\u8F93\u5165\u8981\u641C\u7D22\u5730\u540D",showSearch:!0,allowClear:!0,filterOption:!1,defaultActiveFirstOption:!1,showAddress:!0,showDistrict:!0};function Go(K){"@babel/helpers - typeof";return Go=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(ne){return typeof ne}:function(ne){return ne&&typeof Symbol=="function"&&ne.constructor===Symbol&&ne!==Symbol.prototype?"symbol":typeof ne},Go(K)}function Wo(){"use strict";Wo=function(){return ne};var K,ne={},ue=Object.prototype,Ue=ue.hasOwnProperty,Ut=Object.defineProperty||function(Qi,Yn,Ti){Qi[Yn]=Ti.value},vr=typeof Symbol=="function"?Symbol:{},Cr=vr.iterator||"@@iterator",Jr=vr.asyncIterator||"@@asyncIterator",Mn=vr.toStringTag||"@@toStringTag";function kn(Qi,Yn,Ti){return Object.defineProperty(Qi,Yn,{value:Ti,enumerable:!0,configurable:!0,writable:!0}),Qi[Yn]}try{kn({},"")}catch(Qi){kn=function(Ti,ca,Qa){return Ti[ca]=Qa}}function $i(Qi,Yn,Ti,ca){var Qa=Yn&&Yn.prototype instanceof Du?Yn:Du,Oa=Object.create(Qa.prototype),Xl=new Eh(ca||[]);return Ut(Oa,"_invoke",{value:qc(Qi,Ti,Xl)}),Oa}function wa(Qi,Yn,Ti){try{return{type:"normal",arg:Qi.call(Yn,Ti)}}catch(ca){return{type:"throw",arg:ca}}}ne.wrap=$i;var Os="suspendedStart",Nu="suspendedYield",yl="executing",js="completed",$s={};function Du(){}function Ml(){}function Wl(){}var yf={};kn(yf,Cr,function(){return this});var Nf=Object.getPrototypeOf,cf=Nf&&Nf(Nf(Uh([])));cf&&cf!==ue&&Ue.call(cf,Cr)&&(yf=cf);var jc=Wl.prototype=Du.prototype=Object.create(yf);function eh(Qi){["next","throw","return"].forEach(function(Yn){kn(Qi,Yn,function(Ti){return this._invoke(Yn,Ti)})})}function uh(Qi,Yn){function Ti(Qa,Oa,Xl,Vc){var Pf=wa(Qi[Qa],Qi,Oa);if(Pf.type!=="throw"){var $d=Pf.arg,qh=$d.value;return qh&&Go(qh)=="object"&&Ue.call(qh,"__await")?Yn.resolve(qh.__await).then(function(Xd){Ti("next",Xd,Xl,Vc)},function(Xd){Ti("throw",Xd,Xl,Vc)}):Yn.resolve(qh).then(function(Xd){$d.value=Xd,Xl($d)},function(Xd){return Ti("throw",Xd,Xl,Vc)})}Vc(Pf.arg)}var ca;Ut(this,"_invoke",{value:function(Oa,Xl){function Vc(){return new Yn(function(Pf,$d){Ti(Oa,Xl,Pf,$d)})}return ca=ca?ca.then(Vc,Vc):Vc()}})}function qc(Qi,Yn,Ti){var ca=Os;return function(Qa,Oa){if(ca===yl)throw new Error("Generator is already running");if(ca===js){if(Qa==="throw")throw Oa;return{value:K,done:!0}}for(Ti.method=Qa,Ti.arg=Oa;;){var Xl=Ti.delegate;if(Xl){var Vc=mf(Xl,Ti);if(Vc){if(Vc===$s)continue;return Vc}}if(Ti.method==="next")Ti.sent=Ti._sent=Ti.arg;else if(Ti.method==="throw"){if(ca===Os)throw ca=js,Ti.arg;Ti.dispatchException(Ti.arg)}else Ti.method==="return"&&Ti.abrupt("return",Ti.arg);ca=yl;var Pf=wa(Qi,Yn,Ti);if(Pf.type==="normal"){if(ca=Ti.done?js:Nu,Pf.arg===$s)continue;return{value:Pf.arg,done:Ti.done}}Pf.type==="throw"&&(ca=js,Ti.method="throw",Ti.arg=Pf.arg)}}}function mf(Qi,Yn){var Ti=Yn.method,ca=Qi.iterator[Ti];if(ca===K)return Yn.delegate=null,Ti==="throw"&&Qi.iterator.return&&(Yn.method="return",Yn.arg=K,mf(Qi,Yn),Yn.method==="throw")||Ti!=="return"&&(Yn.method="throw",Yn.arg=new TypeError("The iterator does not provide a '"+Ti+"' method")),$s;var Qa=wa(ca,Qi.iterator,Yn.arg);if(Qa.type==="throw")return Yn.method="throw",Yn.arg=Qa.arg,Yn.delegate=null,$s;var Oa=Qa.arg;return Oa?Oa.done?(Yn[Qi.resultName]=Oa.value,Yn.next=Qi.nextLoc,Yn.method!=="return"&&(Yn.method="next",Yn.arg=K),Yn.delegate=null,$s):Oa:(Yn.method="throw",Yn.arg=new TypeError("iterator result is not an object"),Yn.delegate=null,$s)}function Dh(Qi){var Yn={tryLoc:Qi[0]};1 in Qi&&(Yn.catchLoc=Qi[1]),2 in Qi&&(Yn.finallyLoc=Qi[2],Yn.afterLoc=Qi[3]),this.tryEntries.push(Yn)}function lh(Qi){var Yn=Qi.completion||{};Yn.type="normal",delete Yn.arg,Qi.completion=Yn}function Eh(Qi){this.tryEntries=[{tryLoc:"root"}],Qi.forEach(Dh,this),this.reset(!0)}function Uh(Qi){if(Qi||Qi===""){var Yn=Qi[Cr];if(Yn)return Yn.call(Qi);if(typeof Qi.next=="function")return Qi;if(!isNaN(Qi.length)){var Ti=-1,ca=function Qa(){for(;++Ti=0;--Qa){var Oa=this.tryEntries[Qa],Xl=Oa.completion;if(Oa.tryLoc==="root")return ca("end");if(Oa.tryLoc<=this.prev){var Vc=Ue.call(Oa,"catchLoc"),Pf=Ue.call(Oa,"finallyLoc");if(Vc&&Pf){if(this.prev=0;--ca){var Qa=this.tryEntries[ca];if(Qa.tryLoc<=this.prev&&Ue.call(Qa,"finallyLoc")&&this.prev=0;--Ti){var ca=this.tryEntries[Ti];if(ca.finallyLoc===Yn)return this.complete(ca.completion,ca.afterLoc),lh(ca),$s}},catch:function(Yn){for(var Ti=this.tryEntries.length-1;Ti>=0;--Ti){var ca=this.tryEntries[Ti];if(ca.tryLoc===Yn){var Qa=ca.completion;if(Qa.type==="throw"){var Oa=Qa.arg;lh(ca)}return Oa}}throw new Error("illegal catch attempt")},delegateYield:function(Yn,Ti,ca){return this.delegate={iterator:Uh(Yn),resultName:Ti,nextLoc:ca},this.method==="next"&&(this.arg=K),$s}},ne}function To(K){return du(K)||gl(K)||Fh(K)||El()}function El(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function gl(K){if(typeof Symbol!="undefined"&&K[Symbol.iterator]!=null||K["@@iterator"]!=null)return Array.from(K)}function du(K){if(Array.isArray(K))return Mf(K)}function Qu(K,ne){var ue=Object.keys(K);if(Object.getOwnPropertySymbols){var Ue=Object.getOwnPropertySymbols(K);ne&&(Ue=Ue.filter(function(Ut){return Object.getOwnPropertyDescriptor(K,Ut).enumerable})),ue.push.apply(ue,Ue)}return ue}function _h(K){for(var ne=1;neK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ue2&&arguments[2]!==void 0?arguments[2]:5,Ut=[ne],vr=l()(ne).object(),Cr=l()(ue).object();if(Ue<2)return Ue<1?[]:Ut;var Jr={r:(vr.r-Cr.r)/(Ue-1),g:(vr.g-Cr.g)/(Ue-1),b:(vr.b-Cr.b)/(Ue-1)};return Br(new Array(Ue-2),function(Mn,kn){return Ut.push(l()({r:dh(vr.r-Jr.r*(kn+1),0),g:dh(vr.g-Jr.g*(kn+1),0),b:dh(vr.b-Jr.b*(kn+1),0)}).hex())}),Ut.push(ue),Ut};function pf(K){"@babel/helpers - typeof";return pf=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(ne){return typeof ne}:function(ne){return ne&&typeof Symbol=="function"&&ne.constructor===Symbol&&ne!==Symbol.prototype?"symbol":typeof ne},pf(K)}function ec(K,ne,ue){return ne=Jc(ne),ne in K?Object.defineProperty(K,ne,{value:ue,enumerable:!0,configurable:!0,writable:!0}):K[ne]=ue,K}function Jc(K){var ne=zl(K,"string");return pf(ne)==="symbol"?ne:String(ne)}function zl(K,ne){if(pf(K)!=="object"||K===null)return K;var ue=K[Symbol.toPrimitive];if(ue!==void 0){var Ue=ue.call(K,ne||"default");if(pf(Ue)!=="object")return Ue;throw new TypeError("@@toPrimitive must return a primitive value.")}return(ne==="string"?String:Number)(K)}var Zc="larkmap-legend-category";function Lh(K){var ne=K.labels,ue=K.colors,Ue=K.geometryType,Ut=Ue===void 0?"circle":Ue,vr=K.isStrokeColor,Cr=K.style,Jr=K.className;function Mn(wa){return vr?{border:"2px solid ".concat(wa)}:{background:wa}}function kn(wa){return V.createElement("div",{className:ce()(Zc,Jr),style:Cr},ne.map(function(Os,Nu){return V.createElement("div",{className:"".concat(Zc,"__content"),key:Os},V.createElement("div",{className:ce()("".concat(Zc,"__content__shape"),ec({},"".concat(Zc,"__content__").concat(Ut),Ut)),style:Mn(wa[Nu])}),V.createElement("div",{className:"".concat(Zc,"labels")},Os))}))}function $i(){if(Array.isArray(ue))return kn(ue);var wa=Jf(ue.startColor,ue.endColor,ne.length);return kn(wa)}return V.createElement($i,null)}Lh.defaultProps={geometryType:"circle",isStrokeColor:!1};var sd=A(76374);function pa(K){var ne=(0,V.useRef)(0),ue=(0,si.CR)((0,V.useState)(K),2),Ue=ue[0],Ut=ue[1],vr=(0,V.useCallback)(function(Cr){cancelAnimationFrame(ne.current),ne.current=requestAnimationFrame(function(){Ut(Cr)})},[]);return(0,Vt.Z)(function(){cancelAnimationFrame(ne.current)}),[Ue,vr]}var gc=pa,Rc=A(7428),tc=!!(typeof window!="undefined"&&window.document&&window.document.createElement),oh=tc;function _(K,ne){if(oh){if(!K)return ne;var ue;return(0,Rc.mf)(K)?ue=K():"current"in K?ue=K.current:ue=K,ue}}function d(K,ne){if(K===ne)return!0;for(var ue=0;ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueK.length)&&(ne=K.length);for(var ue=0,Ue=new Array(ne);ueO.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge { return state.dataSource.find((item) => item.value === state.value)?.type })}}',domain:'{{ $form.getFieldState("fillColorField",state=> { return state.dataSource.find((item) => item.value === state.value)?.domain })}}',defaultColors:'{{ $form.getFieldState("fillColorRange",state=> { return state?.value?.colors })}}'},"x-decorator-props":{},"x-reactions":[{dependencies:["fillColorField"],fulfill:{state:{visible:"{{ $deps[0] !== undefined }}"}}}]},fillColor:{type:"string",title:"\u989C\u8272",default:"#F7664E","x-decorator":"FormItem","x-component":"ColorPicker","x-component-props":{placeholder:"\u989C\u8272"},"x-decorator-props":{},"x-reactions":[{dependencies:["fillColorField"],fulfill:{state:{visible:"{{ $deps[0] === undefined }}"}}}]},fillColorRange:{type:"object",title:"\u989C\u8272",default:{colors:["#ffffcc","#d9f0a3","#addd8e","#78c679","#31a354","#006837"],isReversed:!1},"x-decorator":"FormItem","x-component":"ColorRangeSelector","x-component-props":{options:De(Xt)},"x-decorator-props":{},"x-reactions":[{dependencies:["fillColorField","fillColorScale"],fulfill:{state:{visible:"{{ $deps[0] !== undefined && !$deps[1].isCustom }}"}}}]},fillColorOpacity:{type:"number",title:"\u900F\u660E\u5EA6",default:1,"x-decorator-props":{},"x-decorator":"FormItem","x-component":"Slider","x-component-props":{min:0,max:1,step:.1}}}}}}};function ut(O){return Ct(O)||gt(O)||Rt(O)||Xe()}function Xe(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Rt(O,N){if(O){if(typeof O=="string")return tt(O,N);var ge=Object.prototype.toString.call(O).slice(8,-1);if(ge==="Object"&&O.constructor&&(ge=O.constructor.name),ge==="Map"||ge==="Set")return Array.from(O);if(ge==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ge))return tt(O,N)}}function gt(O){if(typeof Symbol!="undefined"&&O[Symbol.iterator]!=null||O["@@iterator"]!=null)return Array.from(O)}function Ct(O){if(Array.isArray(O))return tt(O)}function tt(O,N){(N==null||N>O.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge0&&arguments[0]!==void 0?arguments[0]:{},N=O.collapseTitle,ge=N===void 0?"\u5176\u5B83\u5C5E\u6027":N;return{type:"void","x-component":"FormCollapse","x-component-props":{ghost:!0,destroyInactivePanel:!0,defaultActiveKey:[]},properties:{stackingPatterns:{type:"void","x-component":"FormCollapse.CollapsePanel","x-component-props":{header:ge},properties:{zoom:{type:"number",title:"\u53EF\u89C1\u5C42\u7EA7","x-decorator":"FormItem","x-component":"SliderRange","x-component-props":{dots:!1,range:!0,min:0,max:24},default:[0,24],"x-decorator-props":{}},blend:{type:"string",title:"\u6DF7\u5408\u6548\u679C","x-decorator":"FormItem","x-component":"Select","x-component-props":{placeholder:"\u8BF7\u9009\u62E9"},"x-decorator-props":{},default:"normal",enum:[{label:"\u6B63\u5E38",value:"normal"},{label:"\u53E0\u52A0\u6A21\u5F0F",value:"additive"},{label:"\u76F8\u51CF\u6A21\u5F0F",value:"subtractive"},{label:"\u6700\u5927\u503C",value:"max"},{label:"\u6700\u5C0F\u503C",value:"min"}]}}}}}};function et(O){return wt(O)||ft(O)||Ke(O)||pt()}function pt(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ke(O,N){if(O){if(typeof O=="string")return Se(O,N);var ge=Object.prototype.toString.call(O).slice(8,-1);if(ge==="Object"&&O.constructor&&(ge=O.constructor.name),ge==="Map"||ge==="Set")return Array.from(O);if(ge==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ge))return Se(O,N)}}function ft(O){if(typeof Symbol!="undefined"&&O[Symbol.iterator]!=null||O["@@iterator"]!=null)return Array.from(O)}function wt(O){if(Array.isArray(O))return Se(O)}function Se(O,N){(N==null||N>O.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge0&&arguments[0]!==void 0?arguments[0]:{};return{type:"object",properties:{collapseItem_fillColor:Ve(O),collapseItem_stroke:mt(),collapseItem_fillradius:Ft(O),collapseItem_labelstyle:Ne(O),collapseItem_other:bt(O)}}};function We(O){return dr(O)||Qe(O)||st(O)||Me()}function Me(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function st(O,N){if(O){if(typeof O=="string")return Kt(O,N);var ge=Object.prototype.toString.call(O).slice(8,-1);if(ge==="Object"&&O.constructor&&(ge=O.constructor.name),ge==="Map"||ge==="Set")return Array.from(O);if(ge==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ge))return Kt(O,N)}}function Qe(O){if(typeof Symbol!="undefined"&&O[Symbol.iterator]!=null||O["@@iterator"]!=null)return Array.from(O)}function dr(O){if(Array.isArray(O))return Kt(O)}function Kt(O,N){(N==null||N>O.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge0&&arguments[0]!==void 0?arguments[0]:{};return{type:"object",properties:{collapseItem_fillColor:Ve(O),collapseItem_stroke:mt(),collapseItem_labelstyle:Ne(O),collapseItem_other:bt(O)}}};function Hi(O){return it(O)||xt(O)||Fo(O)||Ki()}function Ki(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Fo(O,N){if(O){if(typeof O=="string")return kt(O,N);var ge=Object.prototype.toString.call(O).slice(8,-1);if(ge==="Object"&&O.constructor&&(ge=O.constructor.name),ge==="Map"||ge==="Set")return Array.from(O);if(ge==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ge))return kt(O,N)}}function xt(O){if(typeof Symbol!="undefined"&&O[Symbol.iterator]!=null||O["@@iterator"]!=null)return Array.from(O)}function it(O){if(Array.isArray(O))return kt(O)}function kt(O,N){(N==null||N>O.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);geO.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge0&&arguments[0]!==void 0?arguments[0]:{},N=O.fieldList,ge=N===void 0?[]:N,Fe=O.colorRanges,Xt=Fe===void 0?[]:Fe;return{type:"object",properties:{collapseItem_fillColor:{type:"void","x-component":"FormCollapse","x-component-props":{ghost:!0,destroyInactivePanel:!0,defaultActiveKey:[]},properties:{fillColor:{type:"void","x-component":"FormCollapse.CollapsePanel","x-component-props":{header:"\u989C\u8272"},properties:{fillColorField:{type:"string",title:"\u586B\u5145\u5B57\u6BB5","x-decorator":"FormItem","x-component":"FieldSelect","x-decorator-props":{tooltip:"\u9009\u4E2D\u4E00\u4E2A\u6570\u503C\u5B57\u6BB5\u4F5C\u4E3A\u989C\u8272\u586B\u5145\u5B57\u6BB5"},"x-component-props":{allowClear:!0,placeholder:"\u8BF7\u9009\u62E9\u5B57\u6BB5"},enum:zi(ge)},fillColorScale:{type:"string",title:"\u989C\u8272\u5212\u5206","x-decorator":"FormItem","x-component":"ScaleSelector","x-component-props":{placeholder:"\u8BF7\u9009\u62E9",dataType:'{{ $form.getFieldState("fillColorField",state=> { return state.dataSource.find((item) => item.value === state.value)?.type })}}',domain:'{{ $form.getFieldState("fillColorField",state=> { return state.dataSource.find((item) => item.value === state.value)?.domain })}}',defaultColors:'{{ $form.getFieldState("fillColorRange",state=> { return state?.value?.colors })}}'},"x-decorator-props":{},"x-reactions":[{dependencies:["fillColorField"],fulfill:{state:{visible:"{{ $deps[0] !== undefined }}"}}}]},sourceColor:{title:"\u8D77\u70B9\u989C\u8272",type:"string",default:"#F7664E","x-decorator":"FormItem","x-component":"ColorPicker","x-component-props":{placeholder:"\u989C\u8272"},"x-decorator-props":{},"x-reactions":[{dependencies:["fillColorField"],fulfill:{state:{visible:"{{ $deps[0] === undefined }}"}}}]},targetColor:{type:"string",title:"\u7EC8\u70B9\u989C\u8272",default:"#5B8FF9","x-decorator":"FormItem","x-component":"ColorPicker","x-reactions":[{dependencies:["fillColorField"],fulfill:{state:{visible:"{{ $deps[0] === undefined }}"}}}]},fillColorRange:{type:"object",title:"\u989C\u8272",default:{colors:["#ffffcc","#d9f0a3","#addd8e","#78c679","#31a354","#006837"],isReversed:!1},"x-decorator":"FormItem","x-component":"ColorRangeSelector","x-component-props":{options:zi(Xt)},"x-decorator-props":{},"x-reactions":[{dependencies:["fillColorField","fillColorScale"],fulfill:{state:{visible:"{{ $deps[0] !== undefined && !$deps[1].isCustom }}"}}}]},fillColorOpacity:{type:"number",title:"\u900F\u660E\u5EA6",default:1,"x-decorator-props":{},"x-decorator":"FormItem","x-component":"Slider","x-component-props":{min:0,max:1,step:.1}}}}}},collapseItem_fillSize:{type:"void","x-component":"FormCollapse","x-component-props":{ghost:!0,destroyInactivePanel:!0,defaultActiveKey:[]},properties:{fillSize:{type:"void","x-component":"FormCollapse.CollapsePanel","x-component-props":{header:"\u7EBF\u5BBD"},properties:{sizeField:{type:"string",title:"\u57FA\u4E8E\u5B57\u6BB5","x-decorator":"FormItem","x-component":"FieldSelect","x-decorator-props":{tooltip:"\u9009\u4E2D\u4E00\u4E2A\u6570\u503C\u5B57\u6BB5\u4F5C\u4E3A\u586B\u5145\u5927\u5C0F"},"x-component-props":{allowClear:!0,placeholder:"\u8BF7\u9009\u62E9\u5B57\u6BB5"},enum:zi(ge)},size:{type:"number",title:"\u5BBD\u5EA6","x-decorator":"FormItem","x-component":"Slider","x-component-props":{dots:!1,range:!1},"x-decorator-props":{},"x-reactions":[{dependencies:["sizeField"],fulfill:{state:{visible:"{{ $deps[0] === undefined }}"}}}]},sizeRange:{type:"number",title:"\u5BBD\u5EA6","x-decorator":"FormItem","x-component":"SliderRange","x-component-props":{dots:!1,range:!0},default:[0,20],"x-decorator-props":{},"x-reactions":[{dependencies:["sizeField"],fulfill:{state:{visible:"{{ $deps[0] !== undefined }}"}}}]}}}}},collapseItem_animate:di(),collapseItem_other:bt(O)}}},Ps=A(52853);function Nr(O){return ga(O)||Yi(O)||hi(O)||fo()}function fo(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function hi(O,N){if(O){if(typeof O=="string")return Xi(O,N);var ge=Object.prototype.toString.call(O).slice(8,-1);if(ge==="Object"&&O.constructor&&(ge=O.constructor.name),ge==="Map"||ge==="Set")return Array.from(O);if(ge==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ge))return Xi(O,N)}}function Yi(O){if(typeof Symbol!="undefined"&&O[Symbol.iterator]!=null||O["@@iterator"]!=null)return Array.from(O)}function ga(O){if(Array.isArray(O))return Xi(O)}function Xi(O,N){(N==null||N>O.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);geO.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);geO.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge0&&arguments[0]!==void 0?arguments[0]:{},N=O.fieldList,ge=N===void 0?[]:N,Fe=O.colorRanges,Xt=Fe===void 0?[]:Fe;return{type:"object",properties:{color:{type:"void","x-component":"FormCollapse","x-component-props":{ghost:!0,destroyInactivePanel:!0,defaultActiveKey:[]},properties:{color:{type:"void","x-component":"FormCollapse.CollapsePanel","x-component-props":{header:"\u70ED\u529B\u989C\u8272"},properties:{colorsRange:{type:"string",title:"\u989C\u8272",default:{colors:["#ffffcc","#ffeda0","#fed976","#feb24c","#fd8d3c","#fc4e2a","#e31a1c","#bd0026","#800026"].reverse(),isReversed:!0},"x-decorator":"FormItem","x-component":"ColorRangeSelector","x-decorator-props":{},"x-component-props":{options:bs(Xt)}},opacity:{type:"number",title:"\u900F\u660E\u5EA6",default:1,"x-decorator-props":{},"x-decorator":"FormItem","x-component":"Slider","x-component-props":{max:1,step:.1}}}}}},collapseItem_fillSize:{type:"void","x-component":"FormCollapse","x-component-props":{ghost:!0,destroyInactivePanel:!0,defaultActiveKey:[]},properties:{fillsize:{type:"void","x-component":"FormCollapse.CollapsePanel","x-component-props":{header:"\u70ED\u529B\u534A\u5F84"},properties:{radius:{type:"number",title:"\u70ED\u529B\u534A\u5F84",default:20,"x-decorator-props":{},"x-decorator":"FormItem","x-component":"Slider","x-component-props":{max:30,min:0,step:1}},sizeField:{type:"string",title:"\u6743\u91CD\u5B57\u6BB5","x-decorator":"FormItem","x-component":"FieldSelect","x-decorator-props":{tooltip:"\u9009\u4E2D\u4E00\u4E2A\u6570\u503C\u5B57\u6BB5\u4F5C\u4E3A\u70ED\u529B\u8BA1\u7B97"},"x-component-props":{allowClear:!0,placeholder:"\u8BF7\u9009\u62E9\u5B57\u6BB5"},enum:bs(ge)},intensity:{type:"number",title:"\u70ED\u529B\u5F3A\u5EA6",default:1,"x-decorator":"FormItem","x-component":"Slider","x-component-props":{dots:!1,range:!1,min:1,max:5},"x-decorator-props":{}}}}}},collapseItem_other:bt(O)}}};function wi(O){return na(O)||Uo(O)||io(O)||oo()}function oo(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function io(O,N){if(O){if(typeof O=="string")return $a(O,N);var ge=Object.prototype.toString.call(O).slice(8,-1);if(ge==="Object"&&O.constructor&&(ge=O.constructor.name),ge==="Map"||ge==="Set")return Array.from(O);if(ge==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ge))return $a(O,N)}}function Uo(O){if(typeof Symbol!="undefined"&&O[Symbol.iterator]!=null||O["@@iterator"]!=null)return Array.from(O)}function na(O){if(Array.isArray(O))return $a(O)}function $a(O,N){(N==null||N>O.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);geO.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge0&&arguments[0]!==void 0?arguments[0]:{};return{type:"object",properties:{collapseItem_fillColor:sf(O),collapseItem_fillSize:{type:"void","x-component":"FormCollapse","x-component-props":{ghost:!0,destroyInactivePanel:!0,defaultActiveKey:[]},properties:{fillSize:{type:"void","x-component":"FormCollapse.CollapsePanel","x-component-props":{header:"\u534A\u5F84"},properties:{aggregateSize:{type:"number",title:"\u7F51\u683C\u534A\u5F84",default:10,"x-decorator":"FormItem","x-component":"Slider","x-component-props":{dots:!1,range:!1,max:500,step:1,min:0},"x-decorator-props":{tooltip:"\u7F51\u683C\u534A\u5F84\u5355\u4F4D\u516C\u91CC"}},coverage:{type:"number",title:"\u8986\u76D6\u5EA6","x-decorator":"FormItem","x-component":"Slider","x-component-props":{dots:!1,range:!1,max:1,step:.1,min:0},"x-decorator-props":{}}}}}},collapseItem_other:bt(O)}}};function Ul(O){return _l(O)||Ol(O)||Fc(O)||Lf()}function Lf(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Fc(O,N){if(O){if(typeof O=="string")return cn(O,N);var ge=Object.prototype.toString.call(O).slice(8,-1);if(ge==="Object"&&O.constructor&&(ge=O.constructor.name),ge==="Map"||ge==="Set")return Array.from(O);if(ge==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ge))return cn(O,N)}}function Ol(O){if(typeof Symbol!="undefined"&&O[Symbol.iterator]!=null||O["@@iterator"]!=null)return Array.from(O)}function _l(O){if(Array.isArray(O))return cn(O)}function cn(O,N){(N==null||N>O.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge { + state.dataSource = $form.getFieldState("aggregateMethod", (state) => { + return state.value + ? [ + { value: "count", label: "count" }, + { label: state.value, value: state.value }, + ] + : [{ value: "count", label: "count" }]; + }); + }); + + $form.setFieldState("fillColorField", (state) => { + state.value = $form + .getFieldState("aggregateMethod", (state) => { + return [state.value, "count"]; + }) + .includes(state.value) + ? state.value + : undefined; + });`}},{dependencies:["aggregateField"],fulfill:{state:{visible:"{{ $deps[0] !== undefined }}"}}}]}}}}}}};function Xn(O){"@babel/helpers - typeof";return Xn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(N){return typeof N}:function(N){return N&&typeof Symbol=="function"&&N.constructor===Symbol&&N!==Symbol.prototype?"symbol":typeof N},Xn(O)}function vi(O,N){var ge=Object.keys(O);if(Object.getOwnPropertySymbols){var Fe=Object.getOwnPropertySymbols(O);N&&(Fe=Fe.filter(function(Xt){return Object.getOwnPropertyDescriptor(O,Xt).enumerable})),ge.push.apply(ge,Fe)}return ge}function to(O){for(var N=1;N0&&arguments[0]!==void 0?arguments[0]:{};return{type:"object",properties:{collapseItem_fillColor:sf(O),collapseItem_fillSize:{type:"void","x-component":"FormCollapse","x-component-props":{ghost:!0,destroyInactivePanel:!0,defaultActiveKey:[]},properties:{fillSize:{type:"void","x-component":"FormCollapse.CollapsePanel","x-component-props":{header:"\u534A\u5F84"},properties:{aggregateSize:{type:"number",title:"\u8702\u7A9D\u534A\u5F84","x-decorator":"FormItem","x-component":"Slider","x-component-props":{dots:!1,range:!1,max:500,step:1,min:0},"x-decorator-props":{tooltip:"\u8702\u7A9D\u534A\u5F84\u5355\u4F4D\u516C\u91CC"}},coverage:{type:"number",title:"\u8986\u76D6\u5EA6","x-decorator":"FormItem","x-component":"Slider","x-component-props":{dots:!1,range:!1,max:1,step:.1,min:0},"x-decorator-props":{}}}}}},collapseItem_other:bt(O)}}};function Df(O){return zf(O)||af(O)||Ic(O)||bu()}function bu(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ic(O,N){if(O){if(typeof O=="string")return tf(O,N);var ge=Object.prototype.toString.call(O).slice(8,-1);if(ge==="Object"&&O.constructor&&(ge=O.constructor.name),ge==="Map"||ge==="Set")return Array.from(O);if(ge==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ge))return tf(O,N)}}function af(O){if(typeof Symbol!="undefined"&&O[Symbol.iterator]!=null||O["@@iterator"]!=null)return Array.from(O)}function zf(O){if(Array.isArray(O))return tf(O)}function tf(O,N){(N==null||N>O.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge { + state.dataSource = $form.getFieldState("aggregateMethod", (state) => { + return state.value + ? [ + { value: "count", label: "count" }, + { label: state.value, value: state.value }, + ] + : [{ value: "count", label: "count" }]; + }); + }); + + $form.setFieldState("fillColorField", (state) => { + state.value = $form + .getFieldState("aggregateMethod", (state) => { + return [state.value, "count"]; + }) + .includes(state.value) + ? state.value + : undefined; + });`}},{dependencies:["aggregateField"],fulfill:{state:{visible:"{{ $deps[0] !== undefined }}"}}}]}}}}}}};function ff(O){"@babel/helpers - typeof";return ff=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(N){return typeof N}:function(N){return N&&typeof Symbol=="function"&&N.constructor===Symbol&&N!==Symbol.prototype?"symbol":typeof N},ff(O)}function vf(O,N){var ge=Object.keys(O);if(Object.getOwnPropertySymbols){var Fe=Object.getOwnPropertySymbols(O);N&&(Fe=Fe.filter(function(Xt){return Object.getOwnPropertyDescriptor(O,Xt).enumerable})),ge.push.apply(ge,Fe)}return ge}function wc(O){for(var N=1;N{ state.value = undefined })"}}]},iconImgScale:{type:"array",title:"\u56FE\u6807\u6620\u5C04","x-decorator":"FormItem","x-component":"IconScaleSelector","x-component-props":{domain:'{{ $form.getFieldState("iconField",state=> { return state.dataSource.find((item) => item.value === state.value)?.domain })}}'},"x-decorator-props":{tooltip:"\u70B9\u51FB\u53EF\u6DFB\u52A0\u67E5\u770B\u56FE\u6807"},"x-reactions":[{dependencies:["iconField"],fulfill:{state:{visible:"{{ $deps[0] !== undefined }}"}}}]},iconImg:{type:"string",title:"\u56FE\u6807\u5F62\u72B6",required:!0,"x-decorator":"FormItem","x-component":"IconSelector","x-decorator-props":{tooltip:"\u9009\u4E2D\u4E00\u4E2A\u56FE\u6807\u4F5C\u4E3A\u586B\u5145\u56FE\u6807",allowClear:!0},"x-component-props":{placeholder:"\u8BF7\u9009\u62E9\u56FE\u6807"},"x-reactions":[{dependencies:["iconField"],fulfill:{state:{visible:"{{ $deps[0] === undefined }}"}}}]},fillOpacity:{type:"number",title:"\u900F\u660E\u5EA6",default:1,"x-decorator-props":{},"x-decorator":"FormItem","x-component":"Slider","x-component-props":{min:0,max:1,step:.1}}}}}},collapseItem_fillRadius:Ft({fieldList:ge,collapseTitle:"\u56FE\u6807\u5927\u5C0F"}),collapseItem_fillLabel:Ne({fieldList:ge}),collapseItem_other:bt({})}}};function Al(O){return qo(O)||ea(O)||Ka(O)||Sc()}function Sc(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ka(O,N){if(O){if(typeof O=="string")return tu(O,N);var ge=Object.prototype.toString.call(O).slice(8,-1);if(ge==="Object"&&O.constructor&&(ge=O.constructor.name),ge==="Map"||ge==="Set")return Array.from(O);if(ge==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ge))return tu(O,N)}}function ea(O){if(typeof Symbol!="undefined"&&O[Symbol.iterator]!=null||O["@@iterator"]!=null)return Array.from(O)}function qo(O){if(Array.isArray(O))return tu(O)}function tu(O,N){(N==null||N>O.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge=O.length?{done:!0}:{done:!1,value:O[Fe++]}},e:function(vn){throw vn},f:Xt}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var fr=!0,Qr=!1,yn;return{s:function(){ge=ge.call(O)},n:function(){var vn=ge.next();return fr=vn.done,vn},e:function(vn){Qr=!0,yn=vn},f:function(){try{!fr&&ge.return!=null&&ge.return()}finally{if(Qr)throw yn}}}}function dt(O,N){if(O){if(typeof O=="string")return zt(O,N);var ge=Object.prototype.toString.call(O).slice(8,-1);if(ge==="Object"&&O.constructor&&(ge=O.constructor.name),ge==="Map"||ge==="Set")return Array.from(O);if(ge==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ge))return zt(O,N)}}function zt(O,N){(N==null||N>O.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge180?fr[0]-=360:Qr<-180&&(fr[0]+=360)}}catch(yn){Fe.e(yn)}finally{Fe.f()}}function cr(O,N,ge){var Fe=(0,me.rS)(O),Xt=S(Fe,2),fr=Xt[0],Qr=Xt[1],yn=N.length;Qt(N,Qr);for(var _n=N[0]===N[yn-1]?yn-1:yn,vn=0;vn<_n;vn++)N[vn][0]=Tt(Qr,N[vn][0],ge),N[vn][1]=Tt(fr,N[vn][1],ge)}function pr(O){var N=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,ge=(0,me.jf)(O,!0);return N!==1?cr(O,ge,N):Qt(ge),ge}var zr=function(N,ge){var Fe="".concat(ge,"_geometry"),Xt=N.filter(function(Qr){return Qr[ge]}).map(function(Qr){return w(w({},Qr),{},Wt({},Fe,{type:"Polygon",coordinates:[pr(Qr[ge])]}))}),fr={data:Xt,parser:{type:"json",geometry:Fe}};return fr};function jr(){return jr=Object.assign?Object.assign.bind():function(O){for(var N=1;NO.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge1&&arguments[1]!==void 0?arguments[1]:[];return Fs(Fs({},uo(O)),{},{collapseItem_fillColor:Ve({fieldList:O,colorRanges:N}),collapseItem_other:bt({})})};function ou(O){"@babel/helpers - typeof";return ou=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(N){return typeof N}:function(N){return N&&typeof Symbol=="function"&&N.constructor===Symbol&&N!==Symbol.prototype?"symbol":typeof N},ou(O)}var rl=function(N){var ge,Fe,Xt,fr,Qr,yn=N.sourceConfig,_n=N.visConfig,vn=_n.fillColor,Oi=_n.opacity,ki=_n.minZoom,Io=ki===void 0?0:ki,Fi=_n.maxZoom,Oo=Fi===void 0?24:Fi,Ko=_n.blend,_a=yn.parser,Ma=ou(vn)==="object"&&(vn==null||(ge=vn.scale)===null||ge===void 0?void 0:ge.domain)&&(vn==null||(Fe=vn.scale)===null||Fe===void 0?void 0:Fe.domain.length)!==0,go=ou(vn)==="object"?{type:vn==null||(Xt=vn.scale)===null||Xt===void 0?void 0:Xt.type,domain:vn==null||(fr=vn.scale)===null||fr===void 0?void 0:fr.domain,range:vn==null?void 0:vn.value,unknown:vn==null||(Qr=vn.scale)===null||Qr===void 0?void 0:Qr.unknown,isCustom:Ma}:void 0;return{hexagonId:_a==null?void 0:_a.hexagonId,fillColorField:ou(vn)==="object"?vn==null?void 0:vn.field:void 0,fillColorRange:ou(vn)==="object"?{colors:(vn==null?void 0:vn.value)||[],isReversed:(vn==null?void 0:vn.isReversed)||!1}:void 0,fillColorScale:go,fillColor:ou(vn)!=="object"?vn:void 0,fillColorOpacity:Oi,zoom:[Io,Oo],blend:Ko}},Nc=function(N){var ge,Fe,Xt,fr,Qr,yn={parser:{hexagonId:N.hexagonId}},_n=N.fillColorField?{field:N.fillColorField,value:N.fillColorScale.isCustom?N.fillColorScale.range:(ge=N.fillColorRange)===null||ge===void 0?void 0:ge.colors,scale:N.fillColorScale.isCustom?{type:N.fillColorScale.type,domain:N.fillColorScale.domain,unknown:N.fillColorScale.unknown}:{type:N.fillColorScale.type},isReversed:(Fe=(Xt=N.fillColorRange)===null||Xt===void 0?void 0:Xt.isReversed)!==null&&Fe!==void 0?Fe:!1}:N.fillColor;return{sourceConfig:yn,visConfig:{fillColor:_n,opacity:N.fillColorOpacity,lineWidth:0,minZoom:N==null||(fr=N.zoom)===null||fr===void 0?void 0:fr[0],maxZoom:N==null||(Qr=N.zoom)===null||Qr===void 0?void 0:Qr[1],blend:N.blend}}},Cc=function(O){var N=Bc(O.datasetFields);return{schema:N,toValues:rl,fromValues:Nc}},Gl=function(){return p.createElement("svg",{viewBox:"0 0 64 64",width:"1em",height:"1em",style:{fill:"currentcolor"}},p.createElement("path",{d:"M44.59,54.5H19.41L6.81,32.68,19.41,10.87H44.59L57.19,32.68Zm-23-3.83H42.38l10.38-18-10.38-18H21.62l-10.38,18Z"}),p.createElement("polygon",{points:"24.65 32.86 24.65 37.79 22.53 37.79 22.53 26.3 24.65 26.3 24.65 30.91 29.32 30.91 29.32 26.3 31.43 26.3 31.43 37.79 29.32 37.79 29.32 32.86 24.65 32.86"}),p.createElement("path",{d:"M33.79,37.05l.6-1.67a5.86,5.86,0,0,0,1.39.61,5.59,5.59,0,0,0,1.5.19A2.57,2.57,0,0,0,39,35.66a1.81,1.81,0,0,0,.61-1.46A1.29,1.29,0,0,0,38.94,33a4.55,4.55,0,0,0-2.05-.32H35.74V31h1.1A5.4,5.4,0,0,0,38,30.85a2.1,2.1,0,0,0,.77-.29,1.53,1.53,0,0,0,.51-.54,1.58,1.58,0,0,0,.15-.73,1.14,1.14,0,0,0-.51-1,2.67,2.67,0,0,0-1.5-.34,4.56,4.56,0,0,0-1.51.24,5,5,0,0,0-1.34.73l-.7-1.61a4.92,4.92,0,0,1,1.66-.83,6.91,6.91,0,0,1,2-.31,4.41,4.41,0,0,1,2.81.79,2.71,2.71,0,0,1,1,2.24,2.33,2.33,0,0,1-.54,1.62,3.45,3.45,0,0,1-1.46.93v0a3,3,0,0,1,1.67.81,2.3,2.3,0,0,1,.64,1.7A3.27,3.27,0,0,1,40.48,37a5,5,0,0,1-3.16.91A6.77,6.77,0,0,1,33.79,37.05Z"}))},Oc=(0,y.Fl)({version:"v0.1",metadata:{name:"H3HexagonLayer",displayName:"H3 \u56FE\u5C42",description:"\u7528\u4E8E H3 \u6570\u636E\u5C55\u793A",type:"Layer",icon:Gl,color:"turquoise"},defaultVisConfig:{visible:!0,fillColor:"rgb(90, 216, 166)",opacity:.8,state:{active:{strokeColor:"yellow",fillColor:!1},select:{fillColor:!1,strokeColor:"red"}},minZoom:0,maxZoom:24,blend:"normal"},component:Hr,registerForm:Cc}),bc=function(N){return p.createElement($.YY,N)},wu=bc,rf=function(){return{collapseItem_style:{type:"void","x-component":"FormCollapse","x-component-props":{ghost:!0,destroyInactivePanel:!0,defaultActiveKey:[]},properties:{style:{type:"void","x-component":"FormCollapse.CollapsePanel","x-component-props":{header:"\u6837\u5F0F"},properties:{opacity:{type:"number",title:"\u900F\u660E\u5EA6",default:1,"x-decorator-props":{},"x-decorator":"FormItem","x-component":"Slider","x-component-props":{min:0,max:1,step:.1}}}}}},collapseItem_other:bt()}},xf=function(N){var ge=N.sourceConfig,Fe=N.visConfig,Xt=ge.parser,fr=Fe.style,Qr=Fe.minZoom,yn=Qr===void 0?0:Qr,_n=Fe.maxZoom,vn=_n===void 0?24:_n,Oi=Fe.blend;return{opacity:fr==null?void 0:fr.opacity,zoom:[yn,vn],blend:Oi}},Kh=function(N){var ge,Fe,Xt={parser:{type:"rasterTile"}};return{sourceConfig:Xt,visConfig:{style:{opacity:N==null?void 0:N.opacity},minZoom:N==null||(ge=N.zoom)===null||ge===void 0?void 0:ge[0],maxZoom:N==null||(Fe=N.zoom)===null||Fe===void 0?void 0:Fe[1],blend:N.blend}}},Zf=function(O){var N=rf();return{schema:N,toValues:xf,fromValues:Kh}},sc=p.createElement("svg",{viewBox:"0 0 56 56",width:"1em",height:"1em",style:{fill:"currentcolor"}},p.createElement("path",{d:"m27.55,22.84L1.87,37.3l26.58,14.97,25.68-14.46-26.58-14.97Z",style:{opacity:.6}}),p.createElement("path",{d:"m27.55,14.32L1.87,28.78l26.58,14.97,25.68-14.46-26.58-14.97Z",style:{opacity:.6}}),p.createElement("path",{d:"m27.55,3.73L1.87,18.19l26.58,14.97,25.68-14.46L27.55,3.73Z",style:{opacity:.6}}),p.createElement("path",{d:"m11.06,24.01h8.74v2.3h-2.93v7.01h-2.88v-7.01h-2.93v-2.3Z",fill:"#c0c0c0"}),p.createElement("path",{d:"m22.44,24.01h3.78l1.46,5.66,1.45-5.66h3.78v9.31h-2.35v-7.1l-1.81,7.1h-2.13l-1.81-7.1v7.1h-2.35v-9.31Z",fill:"#c0c0c0"}),p.createElement("path",{d:"m35.6,30.24l2.74-.17c.06.44.18.78.36,1.02.3.38.72.56,1.27.56.41,0,.73-.1.95-.29.22-.19.33-.42.33-.67s-.11-.46-.32-.65c-.21-.19-.7-.37-1.47-.54-1.26-.28-2.16-.66-2.7-1.13-.54-.47-.81-1.07-.81-1.8,0-.48.14-.93.42-1.36.28-.42.69-.76,1.25-1,.56-.24,1.32-.36,2.29-.36,1.19,0,2.1.22,2.72.66.62.44,1,1.15,1.11,2.11l-2.71.16c-.07-.42-.22-.72-.45-.91s-.55-.29-.96-.29c-.33,0-.59.07-.76.21-.17.14-.25.31-.25.52,0,.15.07.28.21.4.14.12.46.24.96.34,1.26.27,2.16.54,2.7.82.54.28.94.62,1.19,1.03.25.41.37.87.37,1.38,0,.6-.16,1.15-.49,1.65-.33.5-.79.89-1.38,1.15-.59.26-1.34.39-2.24.39-1.58,0-2.68-.3-3.29-.91s-.95-1.38-1.03-2.32Z",fill:"#c0c0c0"})),Kf=function(){return p.createElement("svg",{viewBox:"0 0 56 56",width:"1em",height:"1em",style:{fill:"currentcolor"}},p.createElement("path",{d:"m27.55,22.84L1.87,37.3l26.58,14.97,25.68-14.46-26.58-14.97Z",style:{opacity:.6}}),p.createElement("path",{d:"m27.55,14.32L1.87,28.78l26.58,14.97,25.68-14.46-26.58-14.97Z",style:{opacity:.6}}),p.createElement("path",{d:"m27.55,3.73L1.87,18.19l26.58,14.97,25.68-14.46L27.55,3.73Z",style:{opacity:.6}}),p.createElement("path",{d:"m9.93,20.28h3.17l1.65,2.86,1.6-2.86h3.14l-2.9,4.51,3.17,4.8h-3.23l-1.84-2.99-1.84,2.99h-3.21l3.21-4.85-2.92-4.46Z",fill:"#c0c0c0"}),p.createElement("path",{d:"m21.1,20.28h3.19l1.88,3.14,1.88-3.14h3.18l-3.62,5.41v3.9h-2.88v-3.9l-3.62-5.41Z",fill:"#c0c0c0"}),p.createElement("path",{d:"m33.28,20.28h8.14v1.86l-5.22,5.45h5.41v2h-8.83v-1.93l5.17-5.39h-4.67v-1.99Z",fill:"#c0c0c0"}))},nh=(0,y.Fl)({version:"v0.1",metadata:{name:"TileLayer",displayName:"\u74E6\u7247\u56FE\u5C42",description:"\u7528\u4E8E\u6805\u683C\u74E6\u7247\u670D\u52A1\u5C55\u793A",type:"Layer",icon:Kf,color:"#5558db"},defaultVisConfig:{visible:!0,style:{opacity:1},minZoom:0,maxZoom:24,blend:"normal"},component:wu,registerForm:Zf}),Rh=A(60965),Ff=A(30678),kd=A(1469);function Ud(O,N){return(0,Ff.Z)(O,N,function(ge,Fe){return(0,kd.Z)(O,Fe)})}var Qh=Ud,jh=A(56621),xh=(0,jh.Z)(function(O,N){return O==null?{}:Qh(O,N)}),qf=xh;function hd(){return hd=Object.assign?Object.assign.bind():function(O){for(var N=1;NO.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge=0;--yc){var $c=this.tryEntries[yc],Ph=$c.completion;if($c.tryLoc==="root")return ku("end");if($c.tryLoc<=this.prev){var zh=Fe.call($c,"catchLoc"),rp=Fe.call($c,"finallyLoc");if(zh&&rp){if(this.prev<$c.catchLoc)return ku($c.catchLoc,!0);if(this.prev<$c.finallyLoc)return ku($c.finallyLoc)}else if(zh){if(this.prev<$c.catchLoc)return ku($c.catchLoc,!0)}else{if(!rp)throw new Error("try statement without catch or finally");if(this.prev<$c.finallyLoc)return ku($c.finallyLoc)}}}},abrupt:function(Xa,vs){for(var ku=this.tryEntries.length-1;ku>=0;--ku){var yc=this.tryEntries[ku];if(yc.tryLoc<=this.prev&&Fe.call(yc,"finallyLoc")&&this.prev=0;--vs){var ku=this.tryEntries[vs];if(ku.finallyLoc===Xa)return this.complete(ku.completion,ku.afterLoc),Nh(ku),_a}},catch:function(Xa){for(var vs=this.tryEntries.length-1;vs>=0;--vs){var ku=this.tryEntries[vs];if(ku.tryLoc===Xa){var yc=ku.completion;if(yc.type==="throw"){var $c=yc.arg;Nh(ku)}return $c}}throw new Error("illegal catch attempt")},delegateYield:function(Xa,vs,ku){return this.delegate={iterator:Xh(Xa),resultName:vs,nextLoc:ku},this.method==="next"&&(this.arg=O),_a}},N}function j0(O,N,ge,Fe,Xt,fr,Qr){try{var yn=O[fr](Qr),_n=yn.value}catch(vn){ge(vn);return}yn.done?N(_n):Promise.resolve(_n).then(Fe,Xt)}function Fp(O){return function(){var N=this,ge=arguments;return new Promise(function(Fe,Xt){var fr=O.apply(N,ge);function Qr(_n){j0(fr,Fe,Xt,Qr,yn,"next",_n)}function yn(_n){j0(fr,Fe,Xt,Qr,yn,"throw",_n)}Qr(void 0)})}}var P0=new Map,I0=function(){var O=Fp(dp().mark(function N(ge,Fe){var Xt,fr,Qr,yn;return dp().wrap(function(vn){for(;;)switch(vn.prev=vn.next){case 0:if(Xt=ge.data,fr=ge.filter,fr){vn.next=3;break}return vn.abrupt("return",Xt);case 3:return vn.prev=3,vn.next=6,(0,y.LY)(Xt,fr);case 6:Qr=vn.sent,vn.next=14;break;case 9:return vn.prev=9,vn.t0=vn.catch(3),yn=new Error("applyDatasetFilter is failure, filter data: '".concat(JSON.stringify(fr),"'.")),console.error(yn),vn.abrupt("return",Promise.reject(yn));case 14:if(!Fe.aborted){vn.next=16;break}return vn.abrupt("return",Promise.reject("Aborted the request"));case 16:return vn.abrupt("return",Qr);case 17:case"end":return vn.stop()}},N,null,[[3,9]])}));return function(ge,Fe){return O.apply(this,arguments)}}(),V0=function(N){var ge=N.properties,Fe=N.filter,Xt=N.signal,fr=JSON.stringify(ge),Qr={mode:"cors",cache:"default",signal:Xt},yn=Object.assign(Qr,{body:mm(ge.requestOptions.body)==="object"?JSON.stringify(ge.requestOptions.body):ge.requestOptions.body});if(P0.has(fr)){var _n=P0.get(fr);return I0({data:_n,filter:Fe},Xt)}var vn=ge.onComplete,Oi=ge.onError;return fetch(ge.url,yn).then(function(ki){return ki.ok?ki.json():Promise.reject(new Error("status ".concat(ki.status," ").concat(ki.statusText)))}).then(function(ki){if(vn&&(0,y.p5)(vn)){var Io=(0,y.dL)(vn.value);return Io?Io(ki):ki}return ki}).then(function(ki){if(Array.isArray(ki)&&ki.length===0||mm(ki[0])==="object"){var Io=(0,y.uQ)(ki);return P0.set(fr,Io),I0({data:Io,filter:Fe},Xt)}return Promise.reject(new Error("\u6570\u636E\u683C\u5F0F\u4E0D\u662F\u6570\u7EC4\u5BF9\u8C61, \u8BF7\u68C0\u67E5\u6570\u636E\u683C\u5F0F\u662F\u5426\u6B63\u786E\u3002"))}).catch(function(ki){if(ki.name=="AbortError")return[];var Io=Oi&&(0,y.p5)(Oi)?(0,y.dL)(Oi.value):void 0;if(Io){var Fi=Io(ki);throw Fi||ki}else throw ki})},d0=(0,y.$v)({version:"v0.1",metadata:{name:"GET_FETCH_DATA_LIST",displayName:"\u901A\u8FC7 fetch \u83B7\u53D6\u6570\u636E",type:"Dataset"},service:V0}),Q0=A(92310),Mc=A.n(Q0),R0="li-base-layout",w0=function(){return p.createElement("svg",{viewBox:"0 0 64 64",width:"1em",height:"1em",fill:"currentColor"},p.createElement("path",{fill:"currentColor",transform:"rotate(90 32,31.99999809265137)",d:"m4.229698,4.420779l0,55.158442l55.540603,0l0,-55.158442l-55.540603,0zm51.655308,51.400535l-47.642627,0l0,-35.604584l47.70632,0l-0.063693,35.604584zm0.063693,-39.680958l-47.642627,0l0,-7.961669l47.642627,0l0,7.961669z"}))},ad=A(68564),Yp=A(5022),E0,S0,gd,ip;function O0(O,N){return N||(N=O.slice(0)),Object.freeze(Object.defineProperties(O,{raw:{value:Object.freeze(N)}}))}var Bp=function(){var N=Yp.Z.useToken,ge=N(),Fe=ge.token,Xt=Fe.colorBgLayout;return{baseLayout:(0,ad.iv)(E0||(E0=O0([` + display: flex; + flex-direction: column; + width: 100%; + height: 100%; + `]))),baseContainer:(0,ad.iv)(S0||(S0=O0([` + display: flex; + flex: auto; + width: 100%; + height: 100%; + `]))),mapContainer:(0,ad.iv)(gd||(gd=O0([` + flex: auto; + `]))),sidePanel:(0,ad.iv)(ip||(ip=O0([` + width: 350px; + padding: 15px 10px; + overflow: hidden; + overflow-y: auto; + background-color: `,`; + + > :nth-child(n + 2) { + margin-top: 10px; + } + `])),Xt)}},$0=Bp,pd=function(N){var ge=N.showSidePanel,Fe=N.slotsElements,Xt=N.children,fr=$0(),Qr=(0,p.useMemo)(function(){return{content:Fe.content,controls:Fe.controls}},[Fe.content,Fe.controls]);return p.createElement("div",{className:Mc()(R0,fr.baseLayout)},p.createElement("div",{className:Mc()("".concat(R0,"__main"),fr.baseContainer)},p.createElement(y.h_,{className:Mc()(fr.mapContainer,"".concat(R0,"__map-container")),slotsElements:Qr},Xt),ge&&p.createElement("div",{className:Mc()(fr.sidePanel,"".concat(R0,"__side-panel"))},Fe.sidePanel?Fe.sidePanel({}):null)))},Kp=pd;function Mp(O){"@babel/helpers - typeof";return Mp=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(N){return typeof N}:function(N){return N&&typeof Symbol=="function"&&N.constructor===Symbol&&N!==Symbol.prototype?"symbol":typeof N},Mp(O)}function wp(O,N){var ge=Object.keys(O);if(Object.getOwnPropertySymbols){var Fe=Object.getOwnPropertySymbols(O);N&&(Fe=Fe.filter(function(Xt){return Object.getOwnPropertyDescriptor(O,Xt).enumerable})),ge.push.apply(ge,Fe)}return ge}function op(O){for(var N=1;N=72.004&&O<=137.8347&&N>=.8293&&N<=55.8271}function Td(O,N){var ge=-100+2*O+3*N+.2*N*N+.1*O*N+.2*Vh(B0(O));return ge+=(20*df(6*O*mp)+20*df(2*O*mp))*2/3,ge+=(20*df(N*mp)+40*df(N/3*mp))*2/3,ge+=(160*df(N/12*mp)+320*df(N*mp/30))*2/3,ge}function o0(O,N){var ge=300+O+2*N+.1*O*O+.1*O*N+.1*Vh(B0(O));return ge+=(20*df(6*O*mp)+20*df(2*O*mp))*2/3,ge+=(20*df(O*mp)+40*df(O/3*mp))*2/3,ge+=(150*df(O/12*mp)+300*df(O/30*mp))*2/3,ge}function m0(O,N){var ge=o0(O-105,N-35),Fe=Td(O-105,N-35),Xt=N/180*mp,fr=df(Xt);fr=1-G0*fr*fr;var Qr=Vh(fr);return ge=ge*180/(J0/Qr*um(Xt)*mp),Fe=Fe*180/(J0*(1-G0)/(fr*Qr)*mp),[ge,Fe]}function Vd(O){var N=O[0],ge=O[1];if(!W0(N,ge))return[N,ge];var Fe=m0(N,ge);return[N+Fe[0],ge+Fe[1]]}function _r(O){var N=O[0],ge=O[1];if(!W0(N,ge))return[N,ge];for(var Fe=[N,ge],Xt=Fe[0],fr=Fe[1],Qr=Vd([Xt,fr]),yn=Qr[0]-N,_n=Qr[1]-ge;B0(yn)>1e-6||B0(_n)>1e-6;)Xt-=yn,fr-=_n,Qr=Vd([Xt,fr]),yn=Qr[0]-N,_n=Qr[1]-ge;return[Xt,fr]}var Sn=Math.sin,mi=Math.cos,jo=Math.atan2,Ta=Math.sqrt,$o=Math.PI,Po=$o*3e3/180;function ds(O){var N=O[0],ge=O[1],Fe=N-.0065,Xt=ge-.006,fr=Ta(Fe*Fe+Xt*Xt)-2e-5*Sn(Xt*Po),Qr=jo(Xt,Fe)-3e-6*mi(Fe*Po),yn=fr*mi(Qr),_n=fr*Sn(Qr);return[yn,_n]}function Ja(O){var N=O[0],ge=O[1],Fe=N,Xt=ge,fr=Ta(Fe*Fe+Xt*Xt)+2e-5*Sn(Xt*Po),Qr=jo(Xt,Fe)+3e-6*mi(Fe*Po),yn=fr*mi(Qr)+.0065,_n=fr*Sn(Qr)+.006;return[yn,_n]}var au=180/Math.PI,Ds=Math.PI/180,Bs=6378137,ru=20037508342789244e-9;function xs(O){return[O[0]*au/Bs,(Math.PI*.5-2*Math.atan(Math.exp(-O[1]/Bs)))*au]}function nu(O){var N=Math.abs(O[0])<=180?O[0]:O[0]-(O[0]<0?-1:1)*360,ge=[Bs*N*Ds,Bs*Math.log(Math.tan(Math.PI*.25+.5*O[1]*Ds))];return ge[0]>ru&&(ge[0]=ru),ge[0]<-ru&&(ge[0]=-ru),ge[1]>ru&&(ge[1]=ru),ge[1]<-ru&&(ge[1]=-ru),ge}var co=Math.abs,aa=[1289059486e-2,836237787e-2,5591021,348198983e-2,167804312e-2,0],zs=[75,60,45,30,15,0],Ru=[[1410526172116255e-23,898305509648872e-20,-1.9939833816331,200.9824383106796,-187.2403703815547,91.6087516669843,-23.38765649603339,2.57121317296198,-.03801003308653,173379812e-1],[-7435856389565537e-24,8983055097726239e-21,-.78625201886289,96.32687599759846,-1.85204757529826,-59.36935905485877,47.40033549296737,-16.50741931063887,2.28786674699375,1026014486e-2],[-3030883460898826e-23,898305509983578e-20,.30071316287616,59.74293618442277,7.357984074871,-25.38371002664745,13.45380521110908,-3.29883767235584,.32710905363475,685681737e-2],[-1981981304930552e-23,8983055099779535e-21,.03278182852591,40.31678527705744,.65659298677277,-4.44255534477492,.85341911805263,.12923347998204,-.04625736007561,448277706e-2],[309191371068437e-23,8983055096812155e-21,6995724062e-14,23.10934304144901,-.00023663490511,-.6321817810242,-.00663494467273,.03430082397953,-.00466043876332,25551644e-1],[2890871144776878e-24,8983055095805407e-21,-3068298e-14,7.47137025468032,-353937994e-14,-.02145144861037,-1234426596e-14,.00010322952773,-323890364e-14,826088.5]],ls=[[-.0015702102444,111320.7020616939,0x60e374c3105a3,-0x24bb4115e2e164,0x5cc55543bb0ae8,-0x7ce070193f3784,0x5e7ca61ddf8150,-0x261a578d8b24d0,0x665d60f3742ca,82.5],[.0008277824516172526,111320.7020463578,6477955746671607e-7,-4082003173641316e-6,1077490566351142e-5,-1517187553151559e-5,1205306533862167e-5,-5124939663577472e-6,9133119359512032e-7,67.5],[.00337398766765,111320.7020202162,4481351045890365e-9,-2339375119931662e-8,7968221547186455e-8,-1159649932797253e-7,9723671115602145e-8,-4366194633752821e-8,8477230501135234e-9,52.5],[.00220636496208,111320.7020209128,51751.86112841131,3796837749470245e-9,992013.7397791013,-122195221711287e-8,1340652697009075e-9,-620943.6990984312,144416.9293806241,37.5],[-.0003441963504368392,111320.7020576856,278.2353980772752,2485758690035394e-9,6070.750963243378,54821.18345352118,9540.606633304236,-2710.55326746645,1405.483844121726,22.5],[-.0003218135878613132,111320.7020701615,.00369383431289,823725.6402795718,.46104986909093,2351.343141331292,1.58060784298199,8.77738589078284,.37238884252424,7.45]];function qu(O,N,ge){var Fe=co(N)/ge[9],Xt=ge[0]+ge[1]*co(O),fr=ge[2]+ge[3]*Fe+ge[4]*Math.pow(Fe,2)+ge[5]*Math.pow(Fe,3)+ge[6]*Math.pow(Fe,4)+ge[7]*Math.pow(Fe,5)+ge[8]*Math.pow(Fe,6);return Xt*=O<0?-1:1,fr*=N<0?-1:1,[Xt,fr]}function ms(O){for(var N=O[0],ge=O[1],Fe=[],Xt=0;Xtzs[Xt]){Fe=ls[Xt];break}return qu(N,ge,Fe)}function Ou(O){for(var N=O[0],ge=O[1],Fe=[],Xt=0;Xt=aa[Xt]){Fe=Ru[Xt];break}return qu(N,ge,Fe)}function Ba(O,N){if(!O)throw new Error(N)}function Lu(O){return!!O&&Object.prototype.toString.call(O)==="[object Array]"}function uc(O){return!isNaN(Number(O))&&O!==null&&!Lu(O)}function Pc(){for(var O=[],N=0;N=2,"Invalid input coordinate: "+O),Ba(uc(O[0])&&uc(O[1]),"Invalid input coordinate: "+O),O=O.map(Number),Qr=!0);var yn=Xt;return Qr?yn(O):(Mu(O,function(_n){var vn;vn=yn(_n),_n[0]=vn[0],_n[1]=vn[1]}),O)}var Ch=Sp(Sp({},jl),{CRSTypes:jl,transform:yd}),Tf=Ch,ed;function If(O,N){return N||(N=O.slice(0)),Object.freeze(Object.defineProperties(O,{raw:{value:Object.freeze(N)}}))}var $h=function(){var N=Yp.Z.useToken,ge=N(),Fe=ge.token,Xt=Fe.colorText,fr=Fe.colorTextDescription,Qr=Fe.colorBgContainer,yn=Fe.colorBorder,_n=Fe.borderRadius;return{geoLocation:(0,ad.iv)(ed||(ed=If([` + color: `,`; + background: `,` !important; + border-color: `,`; + border-radius: `,`px; + + svg { + fill: `,` !important; + } + + &:hover { + svg { + fill: `,` !important; + } + } + `])),fr,Qr,yn,_n,fr,Xt)}},nf=$h,Od=function(N){var ge=N.position,Fe=nf(),Xt=function(Qr){return Tf.transform(Qr,Tf.WGS84,Tf.GCJ02)};return p.createElement($.l_,{className:Mc()("li-geo-location-control",Fe.geoLocation),transform:Xt,position:ge})},Yc=Od,Qf=function(){var O={position:{title:"\u653E\u7F6E\u65B9\u4F4D",type:"string","x-decorator":"FormItem","x-component":"ControlPositionSelect",default:"bottomright"}};return{schema:O}},Pu=function(){return p.createElement("svg",{className:"l7-iconfont",fill:"currentColor","aria-hidden":"true",style:{width:"1em",height:"1em"}},p.createElement("use",{href:"#l7-icon-reposition"}))},hl=(0,y.mV)({version:"v0.1",metadata:{name:"GeoLocateControl",displayName:"GPS \u5B9A\u4F4D",description:"\u4F7F\u7528 GPS \u5B9A\u4F4D\u5230\u5730\u56FE\u4E0A",type:"Auto",category:"MapControl",icon:Pu},defaultProperties:{position:"bottomright"},component:Yc,registerForm:Qf}),Gs=A(49397),of=A(41522),Oh=A(11908),Vp=A(34591),ei=A(50555),Zo=A(43418),ao=A(81664),Iu=A(20906),Kc=A(66187),sa=A(47562),Rr=A(32095),sr=A(20573),ti=A(30462),_o=A(10409),bo=A(16380);function Pi(O){return!!(O&&O.then)}var Di=O=>{const{type:N,children:ge,prefixCls:Fe,buttonProps:Xt,close:fr,autoFocus:Qr,emitEvent:yn,isSilent:_n,quitOnNullishReturnValue:vn,actionFn:Oi}=O,ki=p.useRef(!1),Io=p.useRef(null),[Fi,Oo]=(0,ti.Z)(!1),Ko=function(){fr==null||fr.apply(void 0,arguments)};p.useEffect(()=>{let go=null;return Qr&&(go=setTimeout(()=>{var Ga;(Ga=Io.current)===null||Ga===void 0||Ga.focus()})),()=>{go&&clearTimeout(go)}},[]);const _a=go=>{Pi(go)&&(Oo(!0),go.then(function(){Oo(!1,!0),Ko.apply(void 0,arguments),ki.current=!1},Ga=>{if(Oo(!1,!0),ki.current=!1,!(_n!=null&&_n()))return Promise.reject(Ga)}))},Ma=go=>{if(ki.current)return;if(ki.current=!0,!Oi){Ko();return}let Ga;if(yn){if(Ga=Oi(go),vn&&!Pi(Ga)){ki.current=!1,Ko(go);return}}else if(Oi.length)Ga=Oi(fr),ki.current=!1;else if(Ga=Oi(),!Ga){Ko();return}_a(Ga)};return p.createElement(_o.ZP,Object.assign({},(0,bo.nx)(N),{onClick:Ma,loading:Fi,prefixCls:Fe},Xt,{ref:Io}),ge)};const jn=p.createContext({}),{Provider:D}=jn;var F=()=>{const{autoFocusButton:O,cancelButtonProps:N,cancelTextLocale:ge,isSilent:Fe,mergedOkCancel:Xt,rootPrefixCls:fr,close:Qr,onCancel:yn,onConfirm:_n}=(0,p.useContext)(jn);return Xt?p.createElement(Di,{isSilent:Fe,actionFn:yn,close:function(){Qr==null||Qr.apply(void 0,arguments),_n==null||_n(!1)},autoFocus:O==="cancel",buttonProps:N,prefixCls:`${fr}-btn`},ge):null},fe=()=>{const{autoFocusButton:O,close:N,isSilent:ge,okButtonProps:Fe,rootPrefixCls:Xt,okTextLocale:fr,okType:Qr,onConfirm:yn,onOk:_n}=(0,p.useContext)(jn);return p.createElement(Di,{isSilent:ge,type:Qr||"primary",actionFn:_n,close:function(){N==null||N.apply(void 0,arguments),yn==null||yn(!0)},autoFocus:O==="ok",buttonProps:Fe,prefixCls:`${Xt}-btn`},fr)},Ae=A(39694),Ie=A(79384),Ze=A(35372),Ot=A(526),rr=p.createContext({}),mr=A(54131),pn=A(99569),Jn=A(57901),ui=A(84821),ci=A(3286);function no(O,N,ge){var Fe=N;return!Fe&&ge&&(Fe="".concat(O,"-").concat(ge)),Fe}function Wa(O,N){var ge=O["page".concat(N?"Y":"X","Offset")],Fe="scroll".concat(N?"Top":"Left");if(typeof ge!="number"){var Xt=O.document;ge=Xt.documentElement[Fe],typeof ge!="number"&&(ge=Xt.body[Fe])}return ge}function ha(O){var N=O.getBoundingClientRect(),ge={left:N.left,top:N.top},Fe=O.ownerDocument,Xt=Fe.defaultView||Fe.parentWindow;return ge.left+=Wa(Xt),ge.top+=Wa(Xt,!0),ge}var Go=A(44516),Wo=A(88831),To=p.memo(function(O){var N=O.children;return N},function(O,N){var ge=N.shouldUpdate;return!ge}),El={width:0,height:0,overflow:"hidden",outline:"none"},gl=p.forwardRef(function(O,N){var ge=O.prefixCls,Fe=O.className,Xt=O.style,fr=O.title,Qr=O.ariaId,yn=O.footer,_n=O.closable,vn=O.closeIcon,Oi=O.onClose,ki=O.children,Io=O.bodyStyle,Fi=O.bodyProps,Oo=O.modalRender,Ko=O.onMouseDown,_a=O.onMouseUp,Ma=O.holderRef,go=O.visible,Ga=O.forceRender,uu=O.width,Ss=O.height,$u=O.classNames,il=O.styles,Pl=p.useContext(rr),Au=Pl.panel,Ll=(0,Wo.x1)(Ma,Au),Il=(0,p.useRef)(),Ah=(0,p.useRef)();p.useImperativeHandle(N,function(){return{focus:function(){var ku;(ku=Il.current)===null||ku===void 0||ku.focus()},changeActive:function(ku){var yc=document,$c=yc.activeElement;ku&&$c===Ah.current?Il.current.focus():!ku&&$c===Il.current&&Ah.current.focus()}}});var Nh={};uu!==void 0&&(Nh.width=uu),Ss!==void 0&&(Nh.height=Ss);var kh;yn&&(kh=p.createElement("div",{className:Mc()("".concat(ge,"-footer"),$u==null?void 0:$u.footer),style:(0,mr.Z)({},il==null?void 0:il.footer)},yn));var Xh;fr&&(Xh=p.createElement("div",{className:Mc()("".concat(ge,"-header"),$u==null?void 0:$u.header),style:(0,mr.Z)({},il==null?void 0:il.header)},p.createElement("div",{className:"".concat(ge,"-title"),id:Qr},fr)));var xu;_n&&(xu=p.createElement("button",{type:"button",onClick:Oi,"aria-label":"Close",className:"".concat(ge,"-close")},vn||p.createElement("span",{className:"".concat(ge,"-close-x")})));var Xa=p.createElement("div",{className:Mc()("".concat(ge,"-content"),$u==null?void 0:$u.content),style:il==null?void 0:il.content},xu,Xh,p.createElement("div",(0,Ie.Z)({className:Mc()("".concat(ge,"-body"),$u==null?void 0:$u.body),style:(0,mr.Z)((0,mr.Z)({},Io),il==null?void 0:il.body)},Fi),ki),kh);return p.createElement("div",{key:"dialog-element",role:"dialog","aria-labelledby":fr?Qr:null,"aria-modal":"true",ref:Ll,style:(0,mr.Z)((0,mr.Z)({},Xt),Nh),className:Mc()(ge,Fe),onMouseDown:Ko,onMouseUp:_a},p.createElement("div",{tabIndex:0,ref:Il,style:El,"aria-hidden":"true"}),p.createElement(To,{shouldUpdate:go||Ga},Oo?Oo(Xa):Xa),p.createElement("div",{tabIndex:0,ref:Ah,style:El,"aria-hidden":"true"}))}),du=gl,Qu=p.forwardRef(function(O,N){var ge=O.prefixCls,Fe=O.title,Xt=O.style,fr=O.className,Qr=O.visible,yn=O.forceRender,_n=O.destroyOnClose,vn=O.motionName,Oi=O.ariaId,ki=O.onVisibleChanged,Io=O.mousePosition,Fi=(0,p.useRef)(),Oo=p.useState(),Ko=(0,Ze.Z)(Oo,2),_a=Ko[0],Ma=Ko[1],go={};_a&&(go.transformOrigin=_a);function Ga(){var uu=ha(Fi.current);Ma(Io?"".concat(Io.x-uu.left,"px ").concat(Io.y-uu.top,"px"):"")}return p.createElement(Go.ZP,{visible:Qr,onVisibleChanged:ki,onAppearPrepare:Ga,onEnterPrepare:Ga,forceRender:yn,motionName:vn,removeOnLeave:_n,ref:Fi},function(uu,Ss){var $u=uu.className,il=uu.style;return p.createElement(du,(0,Ie.Z)({},O,{ref:N,title:Fe,ariaId:Oi,prefixCls:ge,holderRef:Ss,style:(0,mr.Z)((0,mr.Z)((0,mr.Z)({},il),Xt),go),className:Mc()(fr,$u)}))})});Qu.displayName="Content";var _h=Qu;function Th(O){var N=O.prefixCls,ge=O.style,Fe=O.visible,Xt=O.maskProps,fr=O.motionName,Qr=O.className;return p.createElement(Go.ZP,{key:"mask",visible:Fe,motionName:fr,leavedClassName:"".concat(N,"-mask-hidden")},function(yn,_n){var vn=yn.className,Oi=yn.style;return p.createElement("div",(0,Ie.Z)({ref:_n,style:(0,mr.Z)((0,mr.Z)({},Oi),ge),className:Mc()("".concat(N,"-mask"),vn,Qr)},Xt))})}var vh=A(36014);function $f(O){var N=O.prefixCls,ge=N===void 0?"rc-dialog":N,Fe=O.zIndex,Xt=O.visible,fr=Xt===void 0?!1:Xt,Qr=O.keyboard,yn=Qr===void 0?!0:Qr,_n=O.focusTriggerAfterClose,vn=_n===void 0?!0:_n,Oi=O.wrapStyle,ki=O.wrapClassName,Io=O.wrapProps,Fi=O.onClose,Oo=O.afterOpenChange,Ko=O.afterClose,_a=O.transitionName,Ma=O.animation,go=O.closable,Ga=go===void 0?!0:go,uu=O.mask,Ss=uu===void 0?!0:uu,$u=O.maskTransitionName,il=O.maskAnimation,Pl=O.maskClosable,Au=Pl===void 0?!0:Pl,Ll=O.maskStyle,Il=O.maskProps,Ah=O.rootClassName,Nh=O.classNames,kh=O.styles,Xh=(0,p.useRef)(),xu=(0,p.useRef)(),Xa=(0,p.useRef)(),vs=p.useState(fr),ku=(0,Ze.Z)(vs,2),yc=ku[0],$c=ku[1],Ph=(0,Jn.Z)();function zh(){(0,pn.Z)(xu.current,document.activeElement)||(Xh.current=document.activeElement)}function rp(){if(!(0,pn.Z)(xu.current,document.activeElement)){var cp;(cp=Xa.current)===null||cp===void 0||cp.focus()}}function td(cp){if(cp)rp();else{if($c(!1),Ss&&Xh.current&&vn){try{Xh.current.focus({preventScroll:!0})}catch(cm){}Xh.current=null}yc&&(Ko==null||Ko())}Oo==null||Oo(cp)}function md(cp){Fi==null||Fi(cp)}var fd=(0,p.useRef)(!1),Yd=(0,p.useRef)(),Nd=function(){clearTimeout(Yd.current),fd.current=!0},z0=function(){Yd.current=setTimeout(function(){fd.current=!1})},v0=null;Au&&(v0=function(cm){fd.current?fd.current=!1:xu.current===cm.target&&md(cm)});function T0(cp){if(yn&&cp.keyCode===ui.Z.ESC){cp.stopPropagation(),md(cp);return}fr&&cp.keyCode===ui.Z.TAB&&Xa.current.changeActive(!cp.shiftKey)}return(0,p.useEffect)(function(){fr&&($c(!0),zh())},[fr]),(0,p.useEffect)(function(){return function(){clearTimeout(Yd.current)}},[]),p.createElement("div",(0,Ie.Z)({className:Mc()("".concat(ge,"-root"),Ah)},(0,ci.Z)(O,{data:!0})),p.createElement(Th,{prefixCls:ge,visible:Ss&&fr,motionName:no(ge,$u,il),style:(0,mr.Z)((0,mr.Z)({zIndex:Fe},Ll),kh==null?void 0:kh.mask),maskProps:Il,className:Nh==null?void 0:Nh.mask}),p.createElement("div",(0,Ie.Z)({tabIndex:-1,onKeyDown:T0,className:Mc()("".concat(ge,"-wrap"),ki,Nh==null?void 0:Nh.wrapper),ref:xu,onClick:v0,style:(0,mr.Z)((0,mr.Z)((0,mr.Z)({zIndex:Fe},Oi),kh==null?void 0:kh.wrapper),{},{display:yc?null:"none"})},Io),p.createElement(_h,(0,Ie.Z)({},O,{onMouseDown:Nd,onMouseUp:z0,ref:Xa,closable:Ga,ariaId:Ph,prefixCls:ge,visible:fr&&yc,onClose:md,onVisibleChanged:td,motionName:no(ge,_a,Ma)}))))}var Nl=function(N){var ge=N.visible,Fe=N.getContainer,Xt=N.forceRender,fr=N.destroyOnClose,Qr=fr===void 0?!1:fr,yn=N.afterClose,_n=N.panelRef,vn=p.useState(ge),Oi=(0,Ze.Z)(vn,2),ki=Oi[0],Io=Oi[1],Fi=p.useMemo(function(){return{panel:_n}},[_n]);return p.useEffect(function(){ge&&Io(!0)},[ge]),!Xt&&Qr&&!ki?null:p.createElement(rr.Provider,{value:Fi},p.createElement(Ot.Z,{open:ge||Xt||ki,autoDestroy:!1,getContainer:Fe,autoLock:ge||ki},p.createElement($f,(0,Ie.Z)({},N,{destroyOnClose:Qr,afterClose:function(){yn==null||yn(),Io(!1)}}))))};Nl.displayName="Dialog";var vc=Nl,Hh=vc;function Af(O,N,ge){return typeof O=="boolean"?O:N===void 0?!!ge:N!==!1&&N!==null}function Fh(O,N,ge){let Fe=arguments.length>3&&arguments[3]!==void 0?arguments[3]:p.createElement(Ae.Z,null),Xt=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1;if(!Af(O,N,Xt))return[!1,null];const Qr=typeof N=="boolean"||N===void 0||N===null?Fe:N;return[!0,ge?ge(Qr):Qr]}var Mf=Fh,lm=A(42871);const bm=()=>(0,lm.Z)()&&window.document.documentElement;var xm=A(53843),Rp=A(76135),Om=A(53615),qd=A(53580),N0=A(33401);function ld(){}const Qp=p.createContext({add:ld,remove:ld});function Gh(O){const N=p.useContext(Qp),ge=p.useRef();return(0,N0.zX)(Xt=>{if(Xt){const fr=O?Xt.querySelector(O):Xt;N.add(fr),ge.current=fr}else N.remove(ge.current)})}var wd=null,Md=A(50138),Bd=()=>{const{cancelButtonProps:O,cancelTextLocale:N,onCancel:ge}=(0,p.useContext)(jn);return p.createElement(_o.ZP,Object.assign({onClick:ge},O),N)},Jd=()=>{const{confirmLoading:O,okButtonProps:N,okType:ge,okTextLocale:Fe,onOk:Xt}=(0,p.useContext)(jn);return p.createElement(_o.ZP,Object.assign({},(0,bo.nx)(ge),{loading:O,onClick:Xt},N),Fe)},Ed=A(51877);function _p(O,N){return p.createElement("span",{className:`${O}-close-x`},N||p.createElement(Ae.Z,{className:`${O}-close-icon`}))}const oe=O=>{const{okText:N,okType:ge="primary",cancelText:Fe,confirmLoading:Xt,onOk:fr,onCancel:Qr,okButtonProps:yn,cancelButtonProps:_n,footer:vn}=O,[Oi]=(0,Rr.Z)("Modal",(0,Ed.A)()),ki=N||(Oi==null?void 0:Oi.okText),Io=Fe||(Oi==null?void 0:Oi.cancelText),Fi={confirmLoading:Xt,okButtonProps:yn,cancelButtonProps:_n,okTextLocale:ki,cancelTextLocale:Io,okType:ge,onOk:fr,onCancel:Qr},Oo=p.useMemo(()=>Fi,(0,Gs.Z)(Object.values(Fi)));let Ko;return typeof vn=="function"||typeof vn=="undefined"?(Ko=p.createElement(p.Fragment,null,p.createElement(Bd,null),p.createElement(Jd,null)),typeof vn=="function"&&(Ko=vn(Ko,{OkBtn:Jd,CancelBtn:Bd})),Ko=p.createElement(D,{value:Oo},Ko)):Ko=vn,p.createElement(Md.n,{disabled:!1},Ko)};var o=A(75199),s=A(78600),l=A(8264);const g=new s.E4("antFadeIn",{"0%":{opacity:0},"100%":{opacity:1}}),M=new s.E4("antFadeOut",{"0%":{opacity:1},"100%":{opacity:0}}),j=function(O){let N=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;const{antCls:ge}=O,Fe=`${ge}-fade`,Xt=N?"&":"";return[(0,l.R)(Fe,g,M,O.motionDurationMid,N),{[` + ${Xt}${Fe}-enter, + ${Xt}${Fe}-appear + `]:{opacity:0,animationTimingFunction:"linear"},[`${Xt}${Fe}-leave`]:{animationTimingFunction:"linear"}}]},J=new s.E4("antZoomIn",{"0%":{transform:"scale(0.2)",opacity:0},"100%":{transform:"scale(1)",opacity:1}}),ve=new s.E4("antZoomOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0.2)",opacity:0}}),ze=new s.E4("antZoomBigIn",{"0%":{transform:"scale(0.8)",opacity:0},"100%":{transform:"scale(1)",opacity:1}}),lt=new s.E4("antZoomBigOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0.8)",opacity:0}}),Dt=new s.E4("antZoomUpIn",{"0%":{transform:"scale(0.8)",transformOrigin:"50% 0%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"50% 0%"}}),$t=new s.E4("antZoomUpOut",{"0%":{transform:"scale(1)",transformOrigin:"50% 0%"},"100%":{transform:"scale(0.8)",transformOrigin:"50% 0%",opacity:0}}),lr=new s.E4("antZoomLeftIn",{"0%":{transform:"scale(0.8)",transformOrigin:"0% 50%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"0% 50%"}}),wr=new s.E4("antZoomLeftOut",{"0%":{transform:"scale(1)",transformOrigin:"0% 50%"},"100%":{transform:"scale(0.8)",transformOrigin:"0% 50%",opacity:0}}),Vr=new s.E4("antZoomRightIn",{"0%":{transform:"scale(0.8)",transformOrigin:"100% 50%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"100% 50%"}}),$r=new s.E4("antZoomRightOut",{"0%":{transform:"scale(1)",transformOrigin:"100% 50%"},"100%":{transform:"scale(0.8)",transformOrigin:"100% 50%",opacity:0}}),Xr=new s.E4("antZoomDownIn",{"0%":{transform:"scale(0.8)",transformOrigin:"50% 100%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"50% 100%"}}),Gr=new s.E4("antZoomDownOut",{"0%":{transform:"scale(1)",transformOrigin:"50% 100%"},"100%":{transform:"scale(0.8)",transformOrigin:"50% 100%",opacity:0}}),Br={zoom:{inKeyframes:J,outKeyframes:ve},"zoom-big":{inKeyframes:ze,outKeyframes:lt},"zoom-big-fast":{inKeyframes:ze,outKeyframes:lt},"zoom-left":{inKeyframes:lr,outKeyframes:wr},"zoom-right":{inKeyframes:Vr,outKeyframes:$r},"zoom-up":{inKeyframes:Dt,outKeyframes:$t},"zoom-down":{inKeyframes:Xr,outKeyframes:Gr}},Tn=(O,N)=>{const{antCls:ge}=O,Fe=`${ge}-${N}`,{inKeyframes:Xt,outKeyframes:fr}=Br[N];return[(0,l.R)(Fe,Xt,fr,N==="zoom-big-fast"?O.motionDurationFast:O.motionDurationMid),{[` + ${Fe}-enter, + ${Fe}-appear + `]:{transform:"scale(0)",opacity:0,animationTimingFunction:O.motionEaseOutCirc,"&-prepare":{transform:"none"}},[`${Fe}-leave`]:{animationTimingFunction:O.motionEaseInOutCirc}}]};var Hn=A(12228),yi=A(93319);function vo(O){return{position:O,inset:0}}const Eo=O=>{const{componentCls:N,antCls:ge}=O;return[{[`${N}-root`]:{[`${N}${ge}-zoom-enter, ${N}${ge}-zoom-appear`]:{transform:"none",opacity:0,animationDuration:O.motionDurationSlow,userSelect:"none"},[`${N}${ge}-zoom-leave ${N}-content`]:{pointerEvents:"none"},[`${N}-mask`]:Object.assign(Object.assign({},vo("fixed")),{zIndex:O.zIndexPopupBase,height:"100%",backgroundColor:O.colorBgMask,pointerEvents:"none",[`${N}-hidden`]:{display:"none"}}),[`${N}-wrap`]:Object.assign(Object.assign({},vo("fixed")),{zIndex:O.zIndexPopupBase,overflow:"auto",outline:0,WebkitOverflowScrolling:"touch",[`&:has(${N}${ge}-zoom-enter), &:has(${N}${ge}-zoom-appear)`]:{pointerEvents:"none"}})}},{[`${N}-root`]:j(O)}]},Xo=O=>{const{componentCls:N}=O;return[{[`${N}-root`]:{[`${N}-wrap-rtl`]:{direction:"rtl"},[`${N}-centered`]:{textAlign:"center","&::before":{display:"inline-block",width:0,height:"100%",verticalAlign:"middle",content:'""'},[N]:{top:0,display:"inline-block",paddingBottom:0,textAlign:"start",verticalAlign:"middle"}},[`@media (max-width: ${O.screenSMMax}px)`]:{[N]:{maxWidth:"calc(100vw - 16px)",margin:`${(0,s.bf)(O.marginXS)} auto`},[`${N}-centered`]:{[N]:{flex:1}}}}},{[N]:Object.assign(Object.assign({},(0,o.Wf)(O)),{pointerEvents:"none",position:"relative",top:100,width:"auto",maxWidth:`calc(100vw - ${(0,s.bf)(O.calc(O.margin).mul(2).equal())})`,margin:"0 auto",paddingBottom:O.paddingLG,[`${N}-title`]:{margin:0,color:O.titleColor,fontWeight:O.fontWeightStrong,fontSize:O.titleFontSize,lineHeight:O.titleLineHeight,wordWrap:"break-word"},[`${N}-content`]:{position:"relative",backgroundColor:O.contentBg,backgroundClip:"padding-box",border:0,borderRadius:O.borderRadiusLG,boxShadow:O.boxShadow,pointerEvents:"auto",padding:O.contentPadding},[`${N}-close`]:Object.assign({position:"absolute",top:O.calc(O.modalHeaderHeight).sub(O.modalCloseBtnSize).div(2).equal(),insetInlineEnd:O.calc(O.modalHeaderHeight).sub(O.modalCloseBtnSize).div(2).equal(),zIndex:O.calc(O.zIndexPopupBase).add(10).equal(),padding:0,color:O.modalCloseIconColor,fontWeight:O.fontWeightStrong,lineHeight:1,textDecoration:"none",background:"transparent",borderRadius:O.borderRadiusSM,width:O.modalCloseBtnSize,height:O.modalCloseBtnSize,border:0,outline:0,cursor:"pointer",transition:`color ${O.motionDurationMid}, background-color ${O.motionDurationMid}`,"&-x":{display:"flex",fontSize:O.fontSizeLG,fontStyle:"normal",lineHeight:`${(0,s.bf)(O.modalCloseBtnSize)}`,justifyContent:"center",textTransform:"none",textRendering:"auto"},"&:hover":{color:O.modalIconHoverColor,backgroundColor:O.closeBtnHoverBg,textDecoration:"none"},"&:active":{backgroundColor:O.closeBtnActiveBg}},(0,o.Qy)(O)),[`${N}-header`]:{color:O.colorText,background:O.headerBg,borderRadius:`${(0,s.bf)(O.borderRadiusLG)} ${(0,s.bf)(O.borderRadiusLG)} 0 0`,marginBottom:O.headerMarginBottom,padding:O.headerPadding,borderBottom:O.headerBorderBottom},[`${N}-body`]:{fontSize:O.fontSize,lineHeight:O.lineHeight,wordWrap:"break-word",padding:O.bodyPadding},[`${N}-footer`]:{textAlign:"end",background:O.footerBg,marginTop:O.footerMarginTop,padding:O.footerPadding,borderTop:O.footerBorderTop,borderRadius:O.footerBorderRadius,[`> ${O.antCls}-btn + ${O.antCls}-btn`]:{marginInlineStart:O.marginXS}},[`${N}-open`]:{overflow:"hidden"}})},{[`${N}-pure-panel`]:{top:"auto",padding:0,display:"flex",flexDirection:"column",[`${N}-content, + ${N}-body, + ${N}-confirm-body-wrapper`]:{display:"flex",flexDirection:"column",flex:"auto"},[`${N}-confirm-body`]:{marginBottom:"auto"}}}]},ys=O=>{const{componentCls:N}=O;return{[`${N}-root`]:{[`${N}-wrap-rtl`]:{direction:"rtl",[`${N}-confirm-body`]:{direction:"rtl"}}}}},Yo=O=>{const N=O.padding,ge=O.fontSizeHeading5,Fe=O.lineHeightHeading5;return(0,Hn.TS)(O,{modalHeaderHeight:O.calc(O.calc(Fe).mul(ge).equal()).add(O.calc(N).mul(2).equal()).equal(),modalFooterBorderColorSplit:O.colorSplit,modalFooterBorderStyle:O.lineType,modalFooterBorderWidth:O.lineWidth,modalIconHoverColor:O.colorIconHover,modalCloseIconColor:O.colorIcon,modalCloseBtnSize:O.fontHeight,modalConfirmIconSize:O.fontHeight,modalTitleHeight:O.calc(O.titleFontSize).mul(O.titleLineHeight).equal()})},es=O=>({footerBg:"transparent",headerBg:O.colorBgElevated,titleLineHeight:O.lineHeightHeading5,titleFontSize:O.fontSizeHeading5,contentBg:O.colorBgElevated,titleColor:O.colorTextHeading,closeBtnHoverBg:O.wireframe?"transparent":O.colorFillContent,closeBtnActiveBg:O.wireframe?"transparent":O.colorFillContentHover,contentPadding:O.wireframe?0:`${(0,s.bf)(O.paddingMD)} ${(0,s.bf)(O.paddingContentHorizontalLG)}`,headerPadding:O.wireframe?`${(0,s.bf)(O.padding)} ${(0,s.bf)(O.paddingLG)}`:0,headerBorderBottom:O.wireframe?`${(0,s.bf)(O.lineWidth)} ${O.lineType} ${O.colorSplit}`:"none",headerMarginBottom:O.wireframe?0:O.marginXS,bodyPadding:O.wireframe?O.paddingLG:0,footerPadding:O.wireframe?`${(0,s.bf)(O.paddingXS)} ${(0,s.bf)(O.padding)}`:0,footerBorderTop:O.wireframe?`${(0,s.bf)(O.lineWidth)} ${O.lineType} ${O.colorSplit}`:"none",footerBorderRadius:O.wireframe?`0 0 ${(0,s.bf)(O.borderRadiusLG)} ${(0,s.bf)(O.borderRadiusLG)}`:0,footerMarginTop:O.wireframe?0:O.marginSM,confirmBodyPadding:O.wireframe?`${(0,s.bf)(O.padding*2)} ${(0,s.bf)(O.padding*2)} ${(0,s.bf)(O.paddingLG)}`:0,confirmIconMarginInlineEnd:O.wireframe?O.margin:O.marginSM,confirmBtnsMarginTop:O.wireframe?O.marginLG:O.marginSM});var qa=(0,yi.I$)("Modal",O=>{const N=Yo(O);return[Xo(N),ys(N),Eo(N),Tn(N,"zoom")]},es,{unitless:{titleLineHeight:!0}}),Ts=function(O,N){var ge={};for(var Fe in O)Object.prototype.hasOwnProperty.call(O,Fe)&&N.indexOf(Fe)<0&&(ge[Fe]=O[Fe]);if(O!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Xt=0,Fe=Object.getOwnPropertySymbols(O);Xt{is={x:O.pageX,y:O.pageY},setTimeout(()=>{is=null},100)};bm()&&document.documentElement.addEventListener("click",ts,!0);var pu=O=>{var N;const{getPopupContainer:ge,getPrefixCls:Fe,direction:Xt,modal:fr}=p.useContext(Oh.E_),Qr=Ph=>{const{onCancel:zh}=O;zh==null||zh(Ph)},yn=Ph=>{const{onOk:zh}=O;zh==null||zh(Ph)},{prefixCls:_n,className:vn,rootClassName:Oi,open:ki,wrapClassName:Io,centered:Fi,getContainer:Oo,closeIcon:Ko,closable:_a,focusTriggerAfterClose:Ma=!0,style:go,visible:Ga,width:uu=520,footer:Ss,classNames:$u,styles:il}=O,Pl=Ts(O,["prefixCls","className","rootClassName","open","wrapClassName","centered","getContainer","closeIcon","closable","focusTriggerAfterClose","style","visible","width","footer","classNames","styles"]),Au=Fe("modal",_n),Ll=Fe(),Il=(0,Rp.Z)(Au),[Ah,Nh,kh]=qa(Au,Il),Xh=Mc()(Io,{[`${Au}-centered`]:!!Fi,[`${Au}-wrap-rtl`]:Xt==="rtl"}),xu=Ss!==null&&p.createElement(oe,Object.assign({},O,{onOk:yn,onCancel:Qr})),[Xa,vs]=Mf(_a,typeof Ko!="undefined"?Ko:fr==null?void 0:fr.closeIcon,Ph=>_p(Au,Ph),p.createElement(Ae.Z,{className:`${Au}-close-icon`}),!0),ku=Gh(`.${Au}-content`),[yc,$c]=(0,Kc.Cn)("Modal",Pl.zIndex);return Ah(p.createElement(qd.BR,null,p.createElement(Om.Ux,{status:!0,override:!0},p.createElement(xm.Z.Provider,{value:$c},p.createElement(Hh,Object.assign({width:uu},Pl,{zIndex:yc,getContainer:Oo===void 0?ge:Oo,prefixCls:Au,rootClassName:Mc()(Nh,Oi,kh,Il),footer:xu,visible:ki!=null?ki:Ga,mousePosition:(N=Pl.mousePosition)!==null&&N!==void 0?N:is,onClose:Qr,closable:Xa,closeIcon:vs,focusTriggerAfterClose:Ma,transitionName:(0,sa.m)(Ll,"zoom",O.transitionName),maskTransitionName:(0,sa.m)(Ll,"fade",O.maskTransitionName),className:Mc()(Nh,vn,fr==null?void 0:fr.className),style:Object.assign(Object.assign({},fr==null?void 0:fr.style),go),classNames:Object.assign(Object.assign(Object.assign({},fr==null?void 0:fr.classNames),$u),{wrapper:Mc()(Xh,$u==null?void 0:$u.wrapper)}),styles:Object.assign(Object.assign({},fr==null?void 0:fr.styles),il),panelRef:ku}))))))};const nl=O=>{const{componentCls:N,titleFontSize:ge,titleLineHeight:Fe,modalConfirmIconSize:Xt,fontSize:fr,lineHeight:Qr,modalTitleHeight:yn,fontHeight:_n,confirmBodyPadding:vn}=O,Oi=`${N}-confirm`;return{[Oi]:{"&-rtl":{direction:"rtl"},[`${O.antCls}-modal-header`]:{display:"none"},[`${Oi}-body-wrapper`]:Object.assign({},(0,o.dF)()),[`&${N} ${N}-body`]:{padding:vn},[`${Oi}-body`]:{display:"flex",flexWrap:"nowrap",alignItems:"start",[`> ${O.iconCls}`]:{flex:"none",fontSize:Xt,marginInlineEnd:O.confirmIconMarginInlineEnd,marginTop:O.calc(O.calc(_n).sub(Xt).equal()).div(2).equal()},[`&-has-title > ${O.iconCls}`]:{marginTop:O.calc(O.calc(yn).sub(Xt).equal()).div(2).equal()}},[`${Oi}-paragraph`]:{display:"flex",flexDirection:"column",flex:"auto",rowGap:O.marginXS,maxWidth:`calc(100% - ${(0,s.bf)(O.calc(O.modalConfirmIconSize).add(O.marginSM).equal())})`},[`${Oi}-title`]:{color:O.colorTextHeading,fontWeight:O.fontWeightStrong,fontSize:ge,lineHeight:Fe},[`${Oi}-content`]:{color:O.colorText,fontSize:fr,lineHeight:Qr},[`${Oi}-btns`]:{textAlign:"end",marginTop:O.confirmBtnsMarginTop,[`${O.antCls}-btn + ${O.antCls}-btn`]:{marginBottom:0,marginInlineStart:O.marginXS}}},[`${Oi}-error ${Oi}-body > ${O.iconCls}`]:{color:O.colorError},[`${Oi}-warning ${Oi}-body > ${O.iconCls}, + ${Oi}-confirm ${Oi}-body > ${O.iconCls}`]:{color:O.colorWarning},[`${Oi}-info ${Oi}-body > ${O.iconCls}`]:{color:O.colorInfo},[`${Oi}-success ${Oi}-body > ${O.iconCls}`]:{color:O.colorSuccess}}};var la=(0,yi.bk)(["Modal","confirm"],O=>{const N=Yo(O);return[nl(N)]},es,{order:-1e3}),Es=function(O,N){var ge={};for(var Fe in O)Object.prototype.hasOwnProperty.call(O,Fe)&&N.indexOf(Fe)<0&&(ge[Fe]=O[Fe]);if(O!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Xt=0,Fe=Object.getOwnPropertySymbols(O);Xtgo,(0,Gs.Z)(Object.values(go))),uu=p.createElement(p.Fragment,null,p.createElement(F,null),p.createElement(fe,null)),Ss=O.title!==void 0&&O.title!==null,$u=`${fr}-body`;return p.createElement("div",{className:`${fr}-body-wrapper`},p.createElement("div",{className:Mc()($u,{[`${$u}-has-title`]:Ss})},ki,p.createElement("div",{className:`${fr}-paragraph`},Ss&&p.createElement("span",{className:`${fr}-title`},O.title),p.createElement("div",{className:`${fr}-content`},O.content))),_n===void 0||typeof _n=="function"?p.createElement(D,{value:Ga},p.createElement("div",{className:`${fr}-btns`},typeof _n=="function"?_n(uu,{OkBtn:fe,CancelBtn:F}):uu)):_n,p.createElement(la,{prefixCls:N}))}const Bf=O=>{const{close:N,zIndex:ge,afterClose:Fe,open:Xt,keyboard:fr,centered:Qr,getContainer:yn,maskStyle:_n,direction:vn,prefixCls:Oi,wrapClassName:ki,rootPrefixCls:Io,bodyStyle:Fi,closable:Oo=!1,closeIcon:Ko,modalRender:_a,focusTriggerAfterClose:Ma,onConfirm:go,styles:Ga}=O,uu=`${Oi}-confirm`,Ss=O.width||416,$u=O.style||{},il=O.mask===void 0?!0:O.mask,Pl=O.maskClosable===void 0?!1:O.maskClosable,Au=Mc()(uu,`${uu}-${O.type}`,{[`${uu}-rtl`]:vn==="rtl"},O.className),[,Ll]=(0,sr.ZP)(),Il=p.useMemo(()=>ge!==void 0?ge:Ll.zIndexPopupBase+Kc.u6,[ge,Ll]);return p.createElement(pu,{prefixCls:Oi,className:Au,wrapClassName:Mc()({[`${uu}-centered`]:!!O.centered},ki),onCancel:()=>{N==null||N({triggerCancel:!0}),go==null||go(!1)},open:Xt,title:"",footer:null,transitionName:(0,sa.m)(Io||"","zoom",O.transitionName),maskTransitionName:(0,sa.m)(Io||"","fade",O.maskTransitionName),mask:il,maskClosable:Pl,style:$u,styles:Object.assign({body:Fi,mask:_n},Ga),width:Ss,zIndex:Il,afterClose:Fe,keyboard:fr,centered:Qr,getContainer:yn,closable:Oo,closeIcon:Ko,modalRender:_a,focusTriggerAfterClose:Ma},p.createElement(sl,Object.assign({},O,{confirmPrefixCls:uu})))};var oc=O=>{const{rootPrefixCls:N,iconPrefixCls:ge,direction:Fe,theme:Xt}=O;return p.createElement(Vp.ZP,{prefixCls:N,iconPrefixCls:ge,direction:Fe,theme:Xt},p.createElement(Bf,Object.assign({},O)))},xc=[];let ih="";function wh(){return ih}const hh=O=>{var N,ge;const{prefixCls:Fe,getContainer:Xt,direction:fr}=O,Qr=(0,Ed.A)(),yn=(0,p.useContext)(Oh.E_),_n=wh()||yn.getPrefixCls(),vn=Fe||`${_n}-modal`;let Oi=Xt;return Oi===!1&&(Oi=void 0),p.createElement(oc,Object.assign({},O,{rootPrefixCls:_n,prefixCls:vn,iconPrefixCls:yn.iconPrefixCls,theme:yn.theme,direction:fr!=null?fr:yn.direction,locale:(ge=(N=yn.locale)===null||N===void 0?void 0:N.Modal)!==null&&ge!==void 0?ge:Qr,getContainer:Oi}))};function dh(O){const N=(0,Vp.w6)(),ge=document.createDocumentFragment();let Fe=Object.assign(Object.assign({},O),{close:yn,open:!0}),Xt;function fr(){for(var vn=arguments.length,Oi=new Array(vn),ki=0;kiFi&&Fi.triggerCancel);O.onCancel&&Io&&O.onCancel.apply(O,[()=>{}].concat((0,Gs.Z)(Oi.slice(1))));for(let Fi=0;Fi{const Oi=N.getPrefixCls(void 0,wh()),ki=N.getIconPrefixCls(),Io=N.getTheme(),Fi=p.createElement(hh,Object.assign({},vn));(0,of.s)(p.createElement(Vp.ZP,{prefixCls:Oi,iconPrefixCls:ki,theme:Io},N.holderRender?N.holderRender(Fi):Fi),ge)})}function yn(){for(var vn=arguments.length,Oi=new Array(vn),ki=0;ki{typeof O.afterClose=="function"&&O.afterClose(),fr.apply(this,Oi)}}),Fe.visible&&delete Fe.visible,Qr(Fe)}function _n(vn){typeof vn=="function"?Fe=vn(Fe):Fe=Object.assign(Object.assign({},Fe),vn),Qr(Fe)}return Qr(Fe),xc.push(yn),{destroy:yn,update:_n}}function Jf(O){return Object.assign(Object.assign({},O),{type:"warning"})}function pf(O){return Object.assign(Object.assign({},O),{type:"info"})}function ec(O){return Object.assign(Object.assign({},O),{type:"success"})}function Jc(O){return Object.assign(Object.assign({},O),{type:"error"})}function zl(O){return Object.assign(Object.assign({},O),{type:"confirm"})}function Zc(O){let{rootPrefixCls:N}=O;ih=N}var Lh=A(94379),sd=function(O,N){var ge={};for(var Fe in O)Object.prototype.hasOwnProperty.call(O,Fe)&&N.indexOf(Fe)<0&&(ge[Fe]=O[Fe]);if(O!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Xt=0,Fe=Object.getOwnPropertySymbols(O);Xt{const{prefixCls:N,className:ge,closeIcon:Fe,closable:Xt,type:fr,title:Qr,children:yn,footer:_n}=O,vn=sd(O,["prefixCls","className","closeIcon","closable","type","title","children","footer"]),{getPrefixCls:Oi}=p.useContext(Oh.E_),ki=Oi(),Io=N||Oi("modal"),Fi=(0,Rp.Z)(ki),[Oo,Ko,_a]=qa(Io,Fi),Ma=`${Io}-confirm`;let go={};return fr?go={closable:Xt!=null?Xt:!1,title:"",footer:"",children:p.createElement(sl,Object.assign({},O,{prefixCls:Io,confirmPrefixCls:Ma,rootPrefixCls:ki,content:yn}))}:go={closable:Xt!=null?Xt:!0,title:Qr,footer:_n!==null&&p.createElement(oe,Object.assign({},O)),children:yn},Oo(p.createElement(du,Object.assign({prefixCls:Io,className:Mc()(Ko,`${Io}-pure-panel`,fr&&Ma,fr&&`${Ma}-${fr}`,ge,_a,Fi)},vn,{closeIcon:_p(Io,Fe),closable:Xt},go)))};var gc=(0,Lh.i)(pa);function Rc(){const[O,N]=p.useState([]),ge=p.useCallback(Fe=>(N(Xt=>[].concat((0,Gs.Z)(Xt),[Fe])),()=>{N(Xt=>Xt.filter(fr=>fr!==Fe))}),[]);return[O,ge]}var tc=A(23244),oh=function(O,N){var ge={};for(var Fe in O)Object.prototype.hasOwnProperty.call(O,Fe)&&N.indexOf(Fe)<0&&(ge[Fe]=O[Fe]);if(O!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Xt=0,Fe=Object.getOwnPropertySymbols(O);Xt{var ge,{afterClose:Fe,config:Xt}=O,fr=oh(O,["afterClose","config"]);const[Qr,yn]=p.useState(!0),[_n,vn]=p.useState(Xt),{direction:Oi,getPrefixCls:ki}=p.useContext(Oh.E_),Io=ki("modal"),Fi=ki(),Oo=()=>{var go;Fe(),(go=_n.afterClose)===null||go===void 0||go.call(_n)},Ko=function(){yn(!1);for(var go=arguments.length,Ga=new Array(go),uu=0;uu$u&&$u.triggerCancel);_n.onCancel&&Ss&&_n.onCancel.apply(_n,[()=>{}].concat((0,Gs.Z)(Ga.slice(1))))};p.useImperativeHandle(N,()=>({destroy:Ko,update:go=>{vn(Ga=>Object.assign(Object.assign({},Ga),go))}}));const _a=(ge=_n.okCancel)!==null&&ge!==void 0?ge:_n.type==="confirm",[Ma]=(0,Rr.Z)("Modal",tc.Z.Modal);return p.createElement(oc,Object.assign({prefixCls:Io,rootPrefixCls:Fi},_n,{close:Ko,open:Qr,afterClose:Oo,okText:_n.okText||(_a?Ma==null?void 0:Ma.okText:Ma==null?void 0:Ma.justOkText),direction:_n.direction||Oi,cancelText:_n.cancelText||(Ma==null?void 0:Ma.cancelText)},fr))};var d=p.forwardRef(_);let C=0;const G=p.memo(p.forwardRef((O,N)=>{const[ge,Fe]=Rc();return p.useImperativeHandle(N,()=>({patchElement:Fe}),[]),p.createElement(p.Fragment,null,ge)}));function de(){const O=p.useRef(null),[N,ge]=p.useState([]);p.useEffect(()=>{N.length&&((0,Gs.Z)(N).forEach(Qr=>{Qr()}),ge([]))},[N]);const Fe=p.useCallback(fr=>function(yn){var _n;C+=1;const vn=p.createRef();let Oi;const ki=new Promise(_a=>{Oi=_a});let Io=!1,Fi;const Oo=p.createElement(d,{key:`modal-${C}`,config:fr(yn),ref:vn,afterClose:()=>{Fi==null||Fi()},isSilent:()=>Io,onConfirm:_a=>{Oi(_a)}});return Fi=(_n=O.current)===null||_n===void 0?void 0:_n.patchElement(Oo),Fi&&xc.push(Fi),{destroy:()=>{function _a(){var Ma;(Ma=vn.current)===null||Ma===void 0||Ma.destroy()}vn.current?_a():ge(Ma=>[].concat((0,Gs.Z)(Ma),[_a]))},update:_a=>{function Ma(){var go;(go=vn.current)===null||go===void 0||go.update(_a)}vn.current?Ma():ge(go=>[].concat((0,Gs.Z)(go),[Ma]))},then:_a=>(Io=!0,ki.then(_a))}},[]);return[p.useMemo(()=>({info:Fe(pf),success:Fe(ec),error:Fe(Jc),warning:Fe(Jf),confirm:Fe(zl)}),[]),p.createElement(G,{key:"modal-holder",ref:O})]}var Te=de;function Re(O){return dh(Jf(O))}const ht=pu;ht.useModal=Te,ht.info=function(N){return dh(pf(N))},ht.success=function(N){return dh(ec(N))},ht.error=function(N){return dh(Jc(N))},ht.warning=Re,ht.warn=Re,ht.confirm=function(N){return dh(zl(N))},ht.destroyAll=function(){for(;xc.length;){const N=xc.pop();N&&N()}},ht.config=Zc,ht._InternalPanelDoNotUseOrYouWillBeFired=gc;var Mt=ht,Yt={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z"}}]},name:"eye",theme:"outlined"},br=Yt,Ir=A(12213),Z=function(N,ge){return p.createElement(Ir.Z,(0,Ie.Z)({},N,{ref:ge,icon:br}))},z=p.forwardRef(Z),Q=A(16514),Pe=A(13255),Pt=A(56348),tr=/margin|padding|width|height|max|min|offset/,Sr={left:!0,top:!0},Dr={cssFloat:1,styleFloat:1,float:1};function Kr(O){return O.nodeType===1?O.ownerDocument.defaultView.getComputedStyle(O,null):{}}function Zn(O,N,ge){if(N=N.toLowerCase(),ge==="auto"){if(N==="height")return O.offsetHeight;if(N==="width")return O.offsetWidth}return N in Sr||(Sr[N]=tr.test(N)),Sr[N]?parseFloat(ge)||0:ge}function ai(O,N){var ge=arguments.length,Fe=Kr(O);return N=Dr[N]?"cssFloat"in O.style?"cssFloat":"styleFloat":N,ge===1?Fe:Zn(O,N,Fe[N]||O.style[N])}function Va(O,N,ge){var Fe=arguments.length;if(N=Dr[N]?"cssFloat"in O.style?"cssFloat":"styleFloat":N,Fe===3)return typeof ge=="number"&&tr.test(N)&&(ge="".concat(ge,"px")),O.style[N]=ge,ge;for(var Xt in N)N.hasOwnProperty(Xt)&&Va(O,Xt,N[Xt]);return Kr(O)}function za(O){return O===document.body?document.documentElement.clientWidth:O.offsetWidth}function ua(O){return O===document.body?window.innerHeight||document.documentElement.clientHeight:O.offsetHeight}function Za(){var O=Math.max(document.documentElement.scrollWidth,document.body.scrollWidth),N=Math.max(document.documentElement.scrollHeight,document.body.scrollHeight);return{width:O,height:N}}function rs(){var O=document.documentElement.clientWidth,N=window.innerHeight||document.documentElement.clientHeight;return{width:O,height:N}}function os(){return{scrollLeft:Math.max(document.documentElement.scrollLeft,document.body.scrollLeft),scrollTop:Math.max(document.documentElement.scrollTop,document.body.scrollTop)}}function Ua(O){var N=O.getBoundingClientRect(),ge=document.documentElement;return{left:N.left+(window.pageXOffset||ge.scrollLeft)-(ge.clientLeft||document.body.clientLeft||0),top:N.top+(window.pageYOffset||ge.scrollTop)-(ge.clientTop||document.body.clientTop||0)}}var us=A(84381),Xu=["crossOrigin","decoding","draggable","loading","referrerPolicy","sizes","srcSet","useMap","alt"],_u=p.createContext(null),Uc=0;function ah(O,N){var ge=p.useState(function(){return Uc+=1,String(Uc)}),Fe=(0,Ze.Z)(ge,1),Xt=Fe[0],fr=p.useContext(_u),Qr={data:N,canPreview:O};return p.useEffect(function(){if(fr)return fr.register(Xt,Qr)},[]),p.useEffect(function(){fr&&fr.register(Xt,Qr)},[O,N]),Xt}function gf(O){return new Promise(function(N){var ge=document.createElement("img");ge.onerror=function(){return N(!1)},ge.onload=function(){return N(!0)},ge.src=O})}function sh(O){var N=O.src,ge=O.isCustomPlaceholder,Fe=O.fallback,Xt=(0,p.useState)(ge?"loading":"normal"),fr=(0,Ze.Z)(Xt,2),Qr=fr[0],yn=fr[1],_n=(0,p.useRef)(!1),vn=Qr==="error";(0,p.useEffect)(function(){var Fi=!0;return gf(N).then(function(Oo){!Oo&&Fi&&yn("error")}),function(){Fi=!1}},[N]),(0,p.useEffect)(function(){ge&&!_n.current?yn("loading"):vn&&yn("normal")},[N]);var Oi=function(){yn("normal")},ki=function(Oo){_n.current=!1,Qr==="loading"&&Oo!==null&&Oo!==void 0&&Oo.complete&&(Oo.naturalWidth||Oo.naturalHeight)&&(_n.current=!0,Oi())},Io=vn&&Fe?{src:Fe}:{onLoad:Oi,src:N};return[ki,Io,Qr]}var sp=A(79161);function Ld(O,N,ge,Fe){var Xt=sp.unstable_batchedUpdates?function(Qr){sp.unstable_batchedUpdates(ge,Qr)}:ge;return O!=null&&O.addEventListener&&O.addEventListener(N,Xt,Fe),{remove:function(){O!=null&&O.removeEventListener&&O.removeEventListener(N,Xt,Fe)}}}var ep=A(70780),up=A(90571),Ap={x:0,y:0,rotate:0,scale:1,flipX:!1,flipY:!1};function a0(O,N,ge,Fe){var Xt=(0,p.useRef)(null),fr=(0,p.useRef)([]),Qr=(0,p.useState)(Ap),yn=(0,Ze.Z)(Qr,2),_n=yn[0],vn=yn[1],Oi=function(Oo){vn(Ap),Fe&&!(0,ep.Z)(Ap,_n)&&Fe({transform:Ap,action:Oo})},ki=function(Oo,Ko){Xt.current===null&&(fr.current=[],Xt.current=(0,up.Z)(function(){vn(function(_a){var Ma=_a;return fr.current.forEach(function(go){Ma=(0,mr.Z)((0,mr.Z)({},Ma),go)}),Xt.current=null,Fe==null||Fe({transform:Ma,action:Ko}),Ma})})),fr.current.push((0,mr.Z)((0,mr.Z)({},_n),Oo))},Io=function(Oo,Ko,_a,Ma,go){var Ga=O.current,uu=Ga.width,Ss=Ga.height,$u=Ga.offsetWidth,il=Ga.offsetHeight,Pl=Ga.offsetLeft,Au=Ga.offsetTop,Ll=Oo,Il=_n.scale*Oo;Il>ge?(Il=ge,Ll=ge/_n.scale):IlFe){if(N>0)return(0,Q.Z)({},O,fr);if(N<0&&XtFe)return(0,Q.Z)({},O,N<0?fr:-fr);return{}}function ju(O,N,ge,Fe){var Xt=rs(),fr=Xt.width,Qr=Xt.height,yn=null;return O<=fr&&N<=Qr?yn={x:0,y:0}:(O>fr||N>Qr)&&(yn=(0,mr.Z)((0,mr.Z)({},Mh("x",ge,O,fr)),Mh("y",Fe,N,Qr))),yn}var Ws=1,K=1;function ne(O,N,ge,Fe,Xt,fr,Qr){var yn=Xt.rotate,_n=Xt.scale,vn=Xt.x,Oi=Xt.y,ki=(0,p.useState)(!1),Io=(0,Ze.Z)(ki,2),Fi=Io[0],Oo=Io[1],Ko=(0,p.useRef)({diffX:0,diffY:0,transformX:0,transformY:0}),_a=function(Ss){!N||Ss.button!==0||(Ss.preventDefault(),Ss.stopPropagation(),Ko.current={diffX:Ss.pageX-vn,diffY:Ss.pageY-Oi,transformX:vn,transformY:Oi},Oo(!0))},Ma=function(Ss){ge&&Fi&&fr({x:Ss.pageX-Ko.current.diffX,y:Ss.pageY-Ko.current.diffY},"move")},go=function(){if(ge&&Fi){Oo(!1);var Ss=Ko.current,$u=Ss.transformX,il=Ss.transformY,Pl=vn!==$u&&Oi!==il;if(!Pl)return;var Au=O.current.offsetWidth*_n,Ll=O.current.offsetHeight*_n,Il=O.current.getBoundingClientRect(),Ah=Il.left,Nh=Il.top,kh=yn%180!==0,Xh=ju(kh?Ll:Au,kh?Au:Ll,Ah,Nh);Xh&&fr((0,mr.Z)({},Xh),"dragRebound")}},Ga=function(Ss){if(!(!ge||Ss.deltaY==0)){var $u=Math.abs(Ss.deltaY/100),il=Math.min($u,K),Pl=Ws+il*Fe;Ss.deltaY>0&&(Pl=Ws/Pl),Qr(Pl,"wheel",Ss.clientX,Ss.clientY)}};return(0,p.useEffect)(function(){var uu,Ss,$u,il;if(N){$u=Ld(window,"mouseup",go,!1),il=Ld(window,"mousemove",Ma,!1);try{window.top!==window.self&&(uu=Ld(window.top,"mouseup",go,!1),Ss=Ld(window.top,"mousemove",Ma,!1))}catch(Pl){(0,vh.Kp)(!1,"[rc-image] ".concat(Pl))}}return function(){var Pl,Au,Ll,Il;(Pl=$u)===null||Pl===void 0||Pl.remove(),(Au=il)===null||Au===void 0||Au.remove(),(Ll=uu)===null||Ll===void 0||Ll.remove(),(Il=Ss)===null||Il===void 0||Il.remove()}},[ge,Fi,vn,Oi,yn,N]),{isMoving:Fi,onMouseDown:_a,onMouseMove:Ma,onMouseUp:go,onWheel:Ga}}function ue(O,N){var ge=O.x-N.x,Fe=O.y-N.y;return Math.hypot(ge,Fe)}function Ue(O,N,ge,Fe){var Xt=ue(O,ge),fr=ue(N,Fe);if(Xt===0&&fr===0)return[O.x,O.y];var Qr=Xt/(Xt+fr),yn=O.x+Qr*(N.x-O.x),_n=O.y+Qr*(N.y-O.y);return[yn,_n]}function Ut(O,N,ge,Fe,Xt,fr,Qr){var yn=Xt.rotate,_n=Xt.scale,vn=Xt.x,Oi=Xt.y,ki=(0,p.useState)(!1),Io=(0,Ze.Z)(ki,2),Fi=Io[0],Oo=Io[1],Ko=(0,p.useRef)({point1:{x:0,y:0},point2:{x:0,y:0},eventType:"none"}),_a=function(Ss){Ko.current=(0,mr.Z)((0,mr.Z)({},Ko.current),Ss)},Ma=function(Ss){if(N){Ss.stopPropagation(),Oo(!0);var $u=Ss.touches,il=$u===void 0?[]:$u;il.length>1?_a({point1:{x:il[0].clientX,y:il[0].clientY},point2:{x:il[1].clientX,y:il[1].clientY},eventType:"touchZoom"}):_a({point1:{x:il[0].clientX-vn,y:il[0].clientY-Oi},eventType:"move"})}},go=function(Ss){var $u=Ss.touches,il=$u===void 0?[]:$u,Pl=Ko.current,Au=Pl.point1,Ll=Pl.point2,Il=Pl.eventType;if(il.length>1&&Il==="touchZoom"){var Ah={x:il[0].clientX,y:il[0].clientY},Nh={x:il[1].clientX,y:il[1].clientY},kh=Ue(Au,Ll,Ah,Nh),Xh=(0,Ze.Z)(kh,2),xu=Xh[0],Xa=Xh[1],vs=ue(Ah,Nh)/ue(Au,Ll);Qr(vs,"touchZoom",xu,Xa,!0),_a({point1:Ah,point2:Nh,eventType:"touchZoom"})}else Il==="move"&&(fr({x:il[0].clientX-Au.x,y:il[0].clientY-Au.y},"move"),_a({eventType:"move"}))},Ga=function(){if(ge){if(Fi&&Oo(!1),_a({eventType:"none"}),Fe>_n)return fr({x:0,y:0,scale:Fe},"touchZoom");var Ss=O.current.offsetWidth*_n,$u=O.current.offsetHeight*_n,il=O.current.getBoundingClientRect(),Pl=il.left,Au=il.top,Ll=yn%180!==0,Il=ju(Ll?$u:Ss,Ll?Ss:$u,Pl,Au);Il&&fr((0,mr.Z)({},Il),"dragRebound")}};return(0,p.useEffect)(function(){var uu;return ge&&N&&(uu=Ld(window,"touchmove",function(Ss){return Ss.preventDefault()},{passive:!1})),function(){var Ss;(Ss=uu)===null||Ss===void 0||Ss.remove()}},[ge,N]),{isTouching:Fi,onTouchStart:Ma,onTouchMove:go,onTouchEnd:Ga}}var vr=function(N){var ge=N.visible,Fe=N.maskTransitionName,Xt=N.getContainer,fr=N.prefixCls,Qr=N.rootClassName,yn=N.icons,_n=N.countRender,vn=N.showSwitch,Oi=N.showProgress,ki=N.current,Io=N.transform,Fi=N.count,Oo=N.scale,Ko=N.minScale,_a=N.maxScale,Ma=N.closeIcon,go=N.onSwitchLeft,Ga=N.onSwitchRight,uu=N.onClose,Ss=N.onZoomIn,$u=N.onZoomOut,il=N.onRotateRight,Pl=N.onRotateLeft,Au=N.onFlipX,Ll=N.onFlipY,Il=N.toolbarRender,Ah=N.zIndex,Nh=(0,p.useContext)(_u),kh=yn.rotateLeft,Xh=yn.rotateRight,xu=yn.zoomIn,Xa=yn.zoomOut,vs=yn.close,ku=yn.left,yc=yn.right,$c=yn.flipX,Ph=yn.flipY,zh="".concat(fr,"-operations-operation");p.useEffect(function(){var fd=function(Nd){Nd.keyCode===ui.Z.ESC&&uu()};return ge&&window.addEventListener("keydown",fd),function(){window.removeEventListener("keydown",fd)}},[ge]);var rp=[{icon:Ph,onClick:Ll,type:"flipY"},{icon:$c,onClick:Au,type:"flipX"},{icon:kh,onClick:Pl,type:"rotateLeft"},{icon:Xh,onClick:il,type:"rotateRight"},{icon:Xa,onClick:$u,type:"zoomOut",disabled:Oo<=Ko},{icon:xu,onClick:Ss,type:"zoomIn",disabled:Oo===_a}],td=rp.map(function(fd){var Yd,Nd=fd.icon,z0=fd.onClick,v0=fd.type,T0=fd.disabled;return p.createElement("div",{className:Mc()(zh,(Yd={},(0,Q.Z)(Yd,"".concat(fr,"-operations-operation-").concat(v0),!0),(0,Q.Z)(Yd,"".concat(fr,"-operations-operation-disabled"),!!T0),Yd)),onClick:z0,key:v0},Nd)}),md=p.createElement("div",{className:"".concat(fr,"-operations")},td);return p.createElement(Go.ZP,{visible:ge,motionName:Fe},function(fd){var Yd=fd.className,Nd=fd.style;return p.createElement(Ot.Z,{open:!0,getContainer:Xt!=null?Xt:document.body},p.createElement("div",{className:Mc()("".concat(fr,"-operations-wrapper"),Yd,Qr),style:(0,mr.Z)((0,mr.Z)({},Nd),{},{zIndex:Ah})},Ma===null?null:p.createElement("button",{className:"".concat(fr,"-close"),onClick:uu},Ma||vs),vn&&p.createElement(p.Fragment,null,p.createElement("div",{className:Mc()("".concat(fr,"-switch-left"),(0,Q.Z)({},"".concat(fr,"-switch-left-disabled"),ki===0)),onClick:go},ku),p.createElement("div",{className:Mc()("".concat(fr,"-switch-right"),(0,Q.Z)({},"".concat(fr,"-switch-right-disabled"),ki===Fi-1)),onClick:Ga},yc)),p.createElement("div",{className:"".concat(fr,"-footer")},Oi&&p.createElement("div",{className:"".concat(fr,"-progress")},_n?_n(ki+1,Fi):"".concat(ki+1," / ").concat(Fi)),Il?Il(md,(0,mr.Z)({icons:{flipYIcon:td[0],flipXIcon:td[1],rotateLeftIcon:td[2],rotateRightIcon:td[3],zoomOutIcon:td[4],zoomInIcon:td[5]},actions:{onFlipY:Ll,onFlipX:Au,onRotateLeft:Pl,onRotateRight:il,onZoomOut:$u,onZoomIn:Ss},transform:Io},Nh?{current:ki,total:Fi}:{})):md)))})},Cr=vr,Jr=["fallback","src","imgRef"],Mn=["prefixCls","src","alt","fallback","movable","onClose","visible","icons","rootClassName","closeIcon","getContainer","current","count","countRender","scaleStep","minScale","maxScale","transitionName","maskTransitionName","imageRender","imgCommonProps","toolbarRender","onTransform","onChange"],kn=function(N){var ge=N.fallback,Fe=N.src,Xt=N.imgRef,fr=(0,Pt.Z)(N,Jr),Qr=sh({src:Fe,fallback:ge}),yn=(0,Ze.Z)(Qr,2),_n=yn[0],vn=yn[1];return p.createElement("img",(0,Ie.Z)({ref:function(ki){Xt.current=ki,_n(ki)}},fr,vn))},$i=function(N){var ge=N.prefixCls,Fe=N.src,Xt=N.alt,fr=N.fallback,Qr=N.movable,yn=Qr===void 0?!0:Qr,_n=N.onClose,vn=N.visible,Oi=N.icons,ki=Oi===void 0?{}:Oi,Io=N.rootClassName,Fi=N.closeIcon,Oo=N.getContainer,Ko=N.current,_a=Ko===void 0?0:Ko,Ma=N.count,go=Ma===void 0?1:Ma,Ga=N.countRender,uu=N.scaleStep,Ss=uu===void 0?.5:uu,$u=N.minScale,il=$u===void 0?1:$u,Pl=N.maxScale,Au=Pl===void 0?50:Pl,Ll=N.transitionName,Il=Ll===void 0?"zoom":Ll,Ah=N.maskTransitionName,Nh=Ah===void 0?"fade":Ah,kh=N.imageRender,Xh=N.imgCommonProps,xu=N.toolbarRender,Xa=N.onTransform,vs=N.onChange,ku=(0,Pt.Z)(N,Mn),yc=(0,p.useRef)(),$c=(0,p.useContext)(_u),Ph=$c&&go>1,zh=$c&&go>=1,rp=(0,p.useState)(!0),td=(0,Ze.Z)(rp,2),md=td[0],fd=td[1],Yd=a0(yc,il,Au,Xa),Nd=Yd.transform,z0=Yd.resetTransform,v0=Yd.updateTransform,T0=Yd.dispatchZoomChange,cp=ne(yc,yn,vn,Ss,Nd,v0,T0),cm=cp.isMoving,rm=cp.onMouseDown,Bm=cp.onWheel,A0=Ut(yc,yn,vn,il,Nd,v0,T0),Nm=A0.isTouching,zm=A0.onTouchStart,nm=A0.onTouchMove,Pm=A0.onTouchEnd,Vm=Nd.rotate,gm=Nd.scale,Im=Mc()((0,Q.Z)({},"".concat(ge,"-moving"),cm));(0,p.useEffect)(function(){md||fd(!0)},[md]);var fv=function(){z0("close")},Iv=function(){T0(Ws+Ss,"zoomIn")},jv=function(){T0(Ws/(Ws+Ss),"zoomOut")},Qm=function(){v0({rotate:Vm+90},"rotateRight")},Rv=function(){v0({rotate:Vm-90},"rotateLeft")},ym=function(){v0({flipX:!Nd.flipX},"flipX")},ov=function(){v0({flipY:!Nd.flipY},"flipY")},og=function(Em){Em==null||Em.preventDefault(),Em==null||Em.stopPropagation(),_a>0&&(fd(!1),z0("prev"),vs==null||vs(_a-1,_a))},Rm=function(Em){Em==null||Em.preventDefault(),Em==null||Em.stopPropagation(),_a({position:O||"absolute",inset:0}),Qg=O=>{const{iconCls:N,motionDurationSlow:ge,paddingXXS:Fe,marginXXS:Xt,prefixCls:fr,colorTextLightSolid:Qr}=O;return{position:"absolute",inset:0,display:"flex",alignItems:"center",justifyContent:"center",color:Qr,background:new rv.C("#000").setAlpha(.5).toRgbString(),cursor:"pointer",opacity:0,transition:`opacity ${ge}`,[`.${fr}-mask-info`]:Object.assign(Object.assign({},o.vS),{padding:`0 ${(0,s.bf)(Fe)}`,[N]:{marginInlineEnd:Xt,svg:{verticalAlign:"baseline"}}})}},Ly=O=>{const{previewCls:N,modalMaskBg:ge,paddingSM:Fe,marginXL:Xt,margin:fr,paddingLG:Qr,previewOperationColorDisabled:yn,previewOperationHoverColor:_n,motionDurationSlow:vn,iconCls:Oi,colorTextLightSolid:ki}=O,Io=new rv.C(ge).setAlpha(.1),Fi=Io.clone().setAlpha(.2);return{[`${N}-footer`]:{position:"fixed",bottom:Xt,left:{_skip_check_:!0,value:0},width:"100%",display:"flex",flexDirection:"column",alignItems:"center",color:O.previewOperationColor},[`${N}-progress`]:{marginBottom:fr},[`${N}-close`]:{position:"fixed",top:Xt,right:{_skip_check_:!0,value:Xt},display:"flex",color:ki,backgroundColor:Io.toRgbString(),borderRadius:"50%",padding:Fe,outline:0,border:0,cursor:"pointer",transition:`all ${vn}`,"&:hover":{backgroundColor:Fi.toRgbString()},[`& > ${Oi}`]:{fontSize:O.previewOperationSize}},[`${N}-operations`]:{display:"flex",alignItems:"center",padding:`0 ${(0,s.bf)(Qr)}`,backgroundColor:Io.toRgbString(),borderRadius:100,"&-operation":{marginInlineStart:Fe,padding:Fe,cursor:"pointer",transition:`all ${vn}`,userSelect:"none",[`&:not(${N}-operations-operation-disabled):hover > ${Oi}`]:{color:_n},"&-disabled":{color:yn,cursor:"not-allowed"},"&:first-of-type":{marginInlineStart:0},[`& > ${Oi}`]:{fontSize:O.previewOperationSize}}}}},Ag=O=>{const{modalMaskBg:N,iconCls:ge,previewOperationColorDisabled:Fe,previewCls:Xt,zIndexPopup:fr,motionDurationSlow:Qr}=O,yn=new rv.C(N).setAlpha(.1),_n=yn.clone().setAlpha(.2);return{[`${Xt}-switch-left, ${Xt}-switch-right`]:{position:"fixed",insetBlockStart:"50%",zIndex:O.calc(fr).add(1).equal({unit:!1}),display:"flex",alignItems:"center",justifyContent:"center",width:O.imagePreviewSwitchSize,height:O.imagePreviewSwitchSize,marginTop:O.calc(O.imagePreviewSwitchSize).mul(-1).div(2).equal(),color:O.previewOperationColor,background:yn.toRgbString(),borderRadius:"50%",transform:"translateY(-50%)",cursor:"pointer",transition:`all ${Qr}`,userSelect:"none","&:hover":{background:_n.toRgbString()},["&-disabled"]:{"&, &:hover":{color:Fe,background:"transparent",cursor:"not-allowed",[`> ${ge}`]:{cursor:"not-allowed"}}},[`> ${ge}`]:{fontSize:O.previewOperationSize}},[`${Xt}-switch-left`]:{insetInlineStart:O.marginSM},[`${Xt}-switch-right`]:{insetInlineEnd:O.marginSM}}},Jg=O=>{const{motionEaseOut:N,previewCls:ge,motionDurationSlow:Fe,componentCls:Xt}=O;return[{[`${Xt}-preview-root`]:{[ge]:{height:"100%",textAlign:"center",pointerEvents:"none"},[`${ge}-body`]:Object.assign(Object.assign({},Tv()),{overflow:"hidden"}),[`${ge}-img`]:{maxWidth:"100%",maxHeight:"70%",verticalAlign:"middle",transform:"scale3d(1, 1, 1)",cursor:"grab",transition:`transform ${Fe} ${N} 0s`,userSelect:"none","&-wrapper":Object.assign(Object.assign({},Tv()),{transition:`transform ${Fe} ${N} 0s`,display:"flex",justifyContent:"center",alignItems:"center","& > *":{pointerEvents:"auto"},"&::before":{display:"inline-block",width:1,height:"50%",marginInlineEnd:-1,content:'""'}})},[`${ge}-moving`]:{[`${ge}-preview-img`]:{cursor:"grabbing","&-wrapper":{transitionDuration:"0s"}}}}},{[`${Xt}-preview-root`]:{[`${ge}-wrap`]:{zIndex:O.zIndexPopup}}},{[`${Xt}-preview-operations-wrapper`]:{position:"fixed",zIndex:O.calc(O.zIndexPopup).add(1).equal({unit:!1})},"&":[Ly(O),Ag(O)]}]},Dy=O=>{const{componentCls:N}=O;return{[N]:{position:"relative",display:"inline-block",[`${N}-img`]:{width:"100%",height:"auto",verticalAlign:"middle"},[`${N}-img-placeholder`]:{backgroundColor:O.colorBgContainerDisabled,backgroundImage:"url('data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iMTYiIHZpZXdCb3g9IjAgMCAxNiAxNiIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cGF0aCBkPSJNMTQuNSAyLjVoLTEzQS41LjUgMCAwIDAgMSAzdjEwYS41LjUgMCAwIDAgLjUuNWgxM2EuNS41IDAgMCAwIC41LS41VjNhLjUuNSAwIDAgMC0uNS0uNXpNNS4yODEgNC43NWExIDEgMCAwIDEgMCAyIDEgMSAwIDAgMSAwLTJ6bTguMDMgNi44M2EuMTI3LjEyNyAwIDAgMS0uMDgxLjAzSDIuNzY5YS4xMjUuMTI1IDAgMCAxLS4wOTYtLjIwN2wyLjY2MS0zLjE1NmEuMTI2LjEyNiAwIDAgMSAuMTc3LS4wMTZsLjAxNi4wMTZMNy4wOCAxMC4wOWwyLjQ3LTIuOTNhLjEyNi4xMjYgMCAwIDEgLjE3Ny0uMDE2bC4wMTUuMDE2IDMuNTg4IDQuMjQ0YS4xMjcuMTI3IDAgMCAxLS4wMi4xNzV6IiBmaWxsPSIjOEM4QzhDIiBmaWxsLXJ1bGU9Im5vbnplcm8iLz48L3N2Zz4=')",backgroundRepeat:"no-repeat",backgroundPosition:"center center",backgroundSize:"30%"},[`${N}-mask`]:Object.assign({},Qg(O)),[`${N}-mask:hover`]:{opacity:1},[`${N}-placeholder`]:Object.assign({},Tv())}}},Nv=O=>{const{previewCls:N}=O;return{[`${N}-root`]:Tn(O,"zoom"),["&"]:j(O,!0)}},ey=O=>({zIndexPopup:O.zIndexPopupBase+80,previewOperationColor:new rv.C(O.colorTextLightSolid).setAlpha(.65).toRgbString(),previewOperationHoverColor:new rv.C(O.colorTextLightSolid).setAlpha(.85).toRgbString(),previewOperationColorDisabled:new rv.C(O.colorTextLightSolid).setAlpha(.25).toRgbString(),previewOperationSize:O.fontSizeIcon*1.5});var bg=(0,yi.I$)("Image",O=>{const N=`${O.componentCls}-preview`,ge=(0,Hn.TS)(O,{previewCls:N,modalMaskBg:new rv.C("#000").setAlpha(.45).toRgbString(),imagePreviewSwitchSize:O.controlHeightLG});return[Dy(ge),Jg(ge),Eo((0,Hn.TS)(ge,{componentCls:N})),Nv(ge)]},ey),qm=function(O,N){var ge={};for(var Fe in O)Object.prototype.hasOwnProperty.call(O,Fe)&&N.indexOf(Fe)<0&&(ge[Fe]=O[Fe]);if(O!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Xt=0,Fe=Object.getOwnPropertySymbols(O);Xt{var{previewPrefixCls:N,preview:ge}=O,Fe=qm(O,["previewPrefixCls","preview"]);const{getPrefixCls:Xt}=p.useContext(Oh.E_),fr=Xt("image",N),Qr=`${fr}-preview`,yn=Xt(),_n=(0,Rp.Z)(fr),[vn,Oi,ki]=bg(fr,_n),[Io]=(0,Kc.Cn)("ImagePreview",typeof ge=="object"?ge.zIndex:void 0),Fi=p.useMemo(()=>{var Oo;if(ge===!1)return ge;const Ko=typeof ge=="object"?ge:{},_a=Mc()(Oi,ki,_n,(Oo=Ko.rootClassName)!==null&&Oo!==void 0?Oo:"");return Object.assign(Object.assign({},Ko),{transitionName:(0,sa.m)(yn,"zoom",Ko.transitionName),maskTransitionName:(0,sa.m)(yn,"fade",Ko.maskTransitionName),rootClassName:_a,zIndex:Io})},[ge]);return vn(p.createElement(Nf.PreviewGroup,Object.assign({preview:Fi,previewPrefixCls:Qr,icons:lv},Fe)))},xg=function(O,N){var ge={};for(var Fe in O)Object.prototype.hasOwnProperty.call(O,Fe)&&N.indexOf(Fe)<0&&(ge[Fe]=O[Fe]);if(O!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Xt=0,Fe=Object.getOwnPropertySymbols(O);Xt{var N;const{prefixCls:ge,preview:Fe,className:Xt,rootClassName:fr,style:Qr}=O,yn=xg(O,["prefixCls","preview","className","rootClassName","style"]),{getPrefixCls:_n,locale:vn=tc.Z,getPopupContainer:Oi,image:ki}=p.useContext(Oh.E_),Io=_n("image",ge),Fi=_n(),Oo=vn.Image||tc.Z.Image,Ko=(0,Rp.Z)(Io),[_a,Ma,go]=bg(Io,Ko),Ga=Mc()(fr,Ma,go,Ko),uu=Mc()(Xt,Ma,ki==null?void 0:ki.className),[Ss]=(0,Kc.Cn)("ImagePreview",typeof Fe=="object"?Fe.zIndex:void 0),$u=p.useMemo(()=>{var Pl;if(Fe===!1)return Fe;const Au=typeof Fe=="object"?Fe:{},{getContainer:Ll,closeIcon:Il}=Au,Ah=xg(Au,["getContainer","closeIcon"]);return Object.assign(Object.assign({mask:p.createElement("div",{className:`${Io}-mask-info`},p.createElement(z,null),Oo==null?void 0:Oo.preview),icons:lv},Ah),{getContainer:Ll!=null?Ll:Oi,transitionName:(0,sa.m)(Fi,"zoom",Au.transitionName),maskTransitionName:(0,sa.m)(Fi,"fade",Au.maskTransitionName),zIndex:Ss,closeIcon:Il!=null?Il:(Pl=ki==null?void 0:ki.preview)===null||Pl===void 0?void 0:Pl.closeIcon})},[Fe,Oo,(N=ki==null?void 0:ki.preview)===null||N===void 0?void 0:N.closeIcon]),il=Object.assign(Object.assign({},ki==null?void 0:ki.style),Qr);return _a(p.createElement(Nf,Object.assign({prefixCls:Io,preview:$u,rootClassName:Ga,className:uu,style:il},yn)))};v_.PreviewGroup=zv;var d1=v_,p1;function X0(O,N){return N||(N=O.slice(0)),Object.freeze(Object.defineProperties(O,{raw:{value:Object.freeze(N)}}))}var Er=function(){var N=Yp.Z.useToken,ge=N(),Fe=ge.token,Xt=Fe.colorText,fr=Fe.colorTextDescription,Qr=Fe.colorBgContainer,yn=Fe.colorBorder,_n=Fe.borderRadius;return{exportImageIcon:(0,ad.iv)(p1||(p1=X0([` + color: `,`; + background: `,` !important; + border-color: `,`; + border-radius: `,`px; + + .l7-iconfont { + fill: `,`; + } + + &:hover { + .l7-iconfont { + fill: `,`; + } + } + `])),fr,Qr,yn,_n,fr,Xt)}},wg=Er;function ky(O,N){return g_(O)||ty(O,N)||m1(O,N)||_A()}function _A(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function m1(O,N){if(O){if(typeof O=="string")return Eg(O,N);var ge=Object.prototype.toString.call(O).slice(8,-1);if(ge==="Object"&&O.constructor&&(ge=O.constructor.name),ge==="Map"||ge==="Set")return Array.from(O);if(ge==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ge))return Eg(O,N)}}function Eg(O,N){(N==null||N>O.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge3&&arguments[3]!==void 0?arguments[3]:"unit";if(typeof Ko=="number"){var go,Ga=Oo[_a],uu=Ga+Ko,Ss=[];Fe.forEach(function(Ll){Ss.push(Ll.value)}),Ss.push(O,N),Ss.push(yn(Ga));var $u=Ko>0?1:-1;Ma==="unit"?Ss.push(yn(Ga+$u*ge)):Ss.push(yn(uu)),Ss=Ss.filter(function(Ll){return Ll!==null}).filter(function(Ll){return Ko<0?Ll<=Ga:Ll>=Ga}),Ma==="unit"&&(Ss=Ss.filter(function(Ll){return Ll!==Ga}));var il=Ma==="unit"?Ga:uu;go=Ss[0];var Pl=Math.abs(go-il);if(Ss.forEach(function(Ll){var Il=Math.abs(Ll-il);Il1){var Au=(0,Gs.Z)(Oo);return Au[_a]=go,Fi(Au,Ko-$u,_a,Ma)}return go}else{if(Ko==="min")return O;if(Ko==="max")return N}},Oi=function(Oo,Ko,_a){var Ma=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"unit",go=Oo[_a],Ga=vn(Oo,Ko,_a,Ma);return{value:Ga,changed:Ga!==go}},ki=function(Oo){return fr===null&&Oo===0||typeof fr=="number"&&Oo3&&arguments[3]!==void 0?arguments[3]:"unit",go=Oo.map(_n),Ga=go[_a],uu=vn(go,Ko,_a,Ma);if(go[_a]=uu,Xt===!1){var Ss=fr||0;_a>0&&go[_a-1]!==Ga&&(go[_a]=Math.max(go[_a],go[_a-1]+Ss)),_a0;Au-=1)for(var Ll=!0;ki(go[Au]-go[Au-1])&⋘){var Il=Oi(go,-1,Au-1);go[Au-1]=Il.value,Ll=Il.changed}for(var Ah=go.length-1;Ah>0;Ah-=1)for(var Nh=!0;ki(go[Ah]-go[Ah-1])&&Nh;){var kh=Oi(go,-1,Ah-1);go[Ah-1]=kh.value,Nh=kh.changed}for(var Xh=0;Xh=0?Xa:!1},[Xa,Vm]),Im=p.useMemo(function(){var zd=Object.keys(Nd||{});return zd.map(function(ch){var _d=Nd[ch],Vu={value:Number(ch)};return _d&&(0,Pe.Z)(_d)==="object"&&!p.isValidElement(_d)&&("label"in _d||"style"in _d)?(Vu.style=_d.style,Vu.label=_d.label):Vu.label=_d,Vu}).filter(function(ch){var _d=ch.label;return _d||typeof _d=="number"}).sort(function(ch,_d){return ch.value-_d.value})},[Nd]),fv=S1(nm,Pm,Vm,Im,Xh,gm),Iv=(0,Ze.Z)(fv,2),jv=Iv[0],Qm=Iv[1],Rv=(0,us.Z)(il,{value:$u}),ym=(0,Ze.Z)(Rv,2),ov=ym[0],og=ym[1],Rm=p.useMemo(function(){var zd=ov==null?[]:Array.isArray(ov)?ov:[ov],ch=(0,Ze.Z)(zd,1),_d=ch[0],Vu=_d===void 0?nm:_d,e0=ov===null?[]:[Vu];if(Pl){if(e0=(0,Gs.Z)(zd),Au||ov===void 0){var Jm=Au>=0?Au+1:2;for(e0=e0.slice(0,Jm);e0.length=0&&A0.current.focus(zd)}ob(null)},[ib]);var xx=p.useMemo(function(){return vs&&Vm===null?!1:vs},[vs,Vm]),Ex=function(ch,_d){_x(ch,_d),Il==null||Il(ag(Rg.current))},ab=gx!==-1;p.useEffect(function(){if(!ab){var zd=Rm.lastIndexOf(yx);A0.current.focus(zd)}},[ab]);var fy=p.useMemo(function(){return(0,Gs.Z)(I_).sort(function(zd,ch){return zd-ch})},[I_]),Sx=p.useMemo(function(){return Pl?[fy[0],fy[fy.length-1]]:[nm,fy[0]]},[fy,Pl,nm]),Xy=(0,Ze.Z)(Sx,2),sb=Xy[0],Cx=Xy[1];p.useImperativeHandle(N,function(){return{focus:function(){A0.current.focus(0)},blur:function(){var ch=document,_d=ch.activeElement;Nm.current.contains(_d)&&(_d==null||_d.blur())}}}),p.useEffect(function(){Fi&&A0.current.focus(0)},[]);var sg=p.useMemo(function(){return{min:nm,max:Pm,direction:zm,disabled:Oi,keyboard:Io,step:Vm,included:Ph,includedStart:sb,includedEnd:Cx,range:Pl,tabIndex:cp,ariaLabelForHandle:cm,ariaLabelledByForHandle:rm,ariaValueTextFormatterForHandle:Bm,styles:_n||{},classNames:yn||{}}},[nm,Pm,zm,Oi,Io,Vm,Ph,sb,Cx,Pl,cp,cm,rm,Bm,_n,yn]);return p.createElement(_v.Provider,{value:sg},p.createElement("div",{ref:Nm,className:Mc()(Xt,fr,(ge={},(0,Q.Z)(ge,"".concat(Xt,"-disabled"),Oi),(0,Q.Z)(ge,"".concat(Xt,"-vertical"),yc),(0,Q.Z)(ge,"".concat(Xt,"-horizontal"),!yc),(0,Q.Z)(ge,"".concat(Xt,"-with-marks"),Im.length),ge)),style:Qr,onMouseDown:dE},p.createElement("div",{className:Mc()("".concat(Xt,"-rail"),yn==null?void 0:yn.rail),style:(0,mr.Z)((0,mr.Z)({},md),_n==null?void 0:_n.rail)}),p.createElement(he,{prefixCls:Xt,style:rp,values:fy,startPoint:zh,onStartMove:xx?Ex:null}),p.createElement(k,{prefixCls:Xt,marks:Im,dots:z0,style:fd,activeStyle:Yd}),p.createElement(Uy,{ref:A0,prefixCls:Xt,style:td,values:I_,draggingIndex:gx,onStartMove:Ex,onOffsetChange:pE,onFocus:Oo,onBlur:Ko,handleRender:v0,onChangeComplete:$m}),p.createElement(Z2,{prefixCls:Xt,marks:Im,onClick:Ax})))}),Le=be,Be=Le;function yt(O){var N=O.children,ge=O.prefixCls,Fe=O.id,Xt=O.overlayInnerStyle,fr=O.className,Qr=O.style;return p.createElement("div",{className:Mc()("".concat(ge,"-content"),fr),style:Qr},p.createElement("div",{className:"".concat(ge,"-inner"),id:Fe,role:"tooltip",style:Xt},typeof N=="function"?N():N))}var Et=A(35593),Je={shiftX:64,adjustY:1},Nt={adjustX:1,shiftY:!0},Zt=[0,0],nr={left:{points:["cr","cl"],overflow:Nt,offset:[-4,0],targetOffset:Zt},right:{points:["cl","cr"],overflow:Nt,offset:[4,0],targetOffset:Zt},top:{points:["bc","tc"],overflow:Je,offset:[0,-4],targetOffset:Zt},bottom:{points:["tc","bc"],overflow:Je,offset:[0,4],targetOffset:Zt},topLeft:{points:["bl","tl"],overflow:Je,offset:[0,-4],targetOffset:Zt},leftTop:{points:["tr","tl"],overflow:Nt,offset:[-4,0],targetOffset:Zt},topRight:{points:["br","tr"],overflow:Je,offset:[0,-4],targetOffset:Zt},rightTop:{points:["tl","tr"],overflow:Nt,offset:[4,0],targetOffset:Zt},bottomRight:{points:["tr","br"],overflow:Je,offset:[0,4],targetOffset:Zt},rightBottom:{points:["bl","br"],overflow:Nt,offset:[4,0],targetOffset:Zt},bottomLeft:{points:["tl","bl"],overflow:Je,offset:[0,4],targetOffset:Zt},leftBottom:{points:["br","bl"],overflow:Nt,offset:[-4,0],targetOffset:Zt}},ur=null,bi=["overlayClassName","trigger","mouseEnterDelay","mouseLeaveDelay","overlayStyle","prefixCls","children","onVisibleChange","afterVisibleChange","transitionName","animation","motion","placement","align","destroyTooltipOnHide","defaultVisible","getTooltipContainer","overlayInnerStyle","arrowContent","overlay","id","showArrow"],Gn=function(N,ge){var Fe=N.overlayClassName,Xt=N.trigger,fr=Xt===void 0?["hover"]:Xt,Qr=N.mouseEnterDelay,yn=Qr===void 0?0:Qr,_n=N.mouseLeaveDelay,vn=_n===void 0?.1:_n,Oi=N.overlayStyle,ki=N.prefixCls,Io=ki===void 0?"rc-tooltip":ki,Fi=N.children,Oo=N.onVisibleChange,Ko=N.afterVisibleChange,_a=N.transitionName,Ma=N.animation,go=N.motion,Ga=N.placement,uu=Ga===void 0?"right":Ga,Ss=N.align,$u=Ss===void 0?{}:Ss,il=N.destroyTooltipOnHide,Pl=il===void 0?!1:il,Au=N.defaultVisible,Ll=N.getTooltipContainer,Il=N.overlayInnerStyle,Ah=N.arrowContent,Nh=N.overlay,kh=N.id,Xh=N.showArrow,xu=Xh===void 0?!0:Xh,Xa=(0,Pt.Z)(N,bi),vs=(0,p.useRef)(null);(0,p.useImperativeHandle)(ge,function(){return vs.current});var ku=(0,mr.Z)({},Xa);"visible"in N&&(ku.popupVisible=N.visible);var yc=function(){return p.createElement(yt,{key:"content",prefixCls:Io,id:kh,overlayInnerStyle:Il},Nh)};return p.createElement(Et.Z,(0,Ie.Z)({popupClassName:Fe,prefixCls:Io,popup:yc,action:fr,builtinPlacements:nr,popupPlacement:uu,ref:vs,popupAlign:$u,getPopupContainer:Ll,onPopupVisibleChange:Oo,afterPopupVisibleChange:Ko,popupTransitionName:_a,popupAnimation:Ma,popupMotion:go,defaultPopupVisible:Au,autoDestroy:Pl,mouseLeaveDelay:vn,popupStyle:Oi,mouseEnterDelay:yn,arrow:xu},ku),Fi)},mo=(0,p.forwardRef)(Gn),xi=mo;function Bn(O){const{sizePopupArrow:N,borderRadiusXS:ge,borderRadiusOuter:Fe}=O,Xt=N/2,fr=0,Qr=Xt,yn=Fe*1/Math.sqrt(2),_n=Xt-Fe*(1-1/Math.sqrt(2)),vn=Xt-ge*(1/Math.sqrt(2)),Oi=Fe*(Math.sqrt(2)-1)+ge*(1/Math.sqrt(2)),ki=2*Xt-vn,Io=Oi,Fi=2*Xt-yn,Oo=_n,Ko=2*Xt-fr,_a=Qr,Ma=Xt*Math.sqrt(2)+Fe*(Math.sqrt(2)-2),go=Fe*(Math.sqrt(2)-1),Ga=`polygon(${go}px 100%, 50% ${go}px, ${2*Xt-go}px 100%, ${go}px 100%)`,uu=`path('M ${fr} ${Qr} A ${Fe} ${Fe} 0 0 0 ${yn} ${_n} L ${vn} ${Oi} A ${ge} ${ge} 0 0 1 ${ki} ${Io} L ${Fi} ${Oo} A ${Fe} ${Fe} 0 0 0 ${Ko} ${_a} Z')`;return{arrowShadowWidth:Ma,arrowPath:uu,arrowPolygon:Ga}}const fi=(O,N,ge)=>{const{sizePopupArrow:Fe,arrowPolygon:Xt,arrowPath:fr,arrowShadowWidth:Qr,borderRadiusXS:yn,calc:_n}=O;return{pointerEvents:"none",width:Fe,height:Fe,overflow:"hidden","&::before":{position:"absolute",bottom:0,insetInlineStart:0,width:Fe,height:_n(Fe).div(2).equal(),background:N,clipPath:{_multi_value_:!0,value:[Xt,fr]},content:'""'},"&::after":{content:'""',position:"absolute",width:Qr,height:Qr,bottom:0,insetInline:0,margin:"auto",borderRadius:{_skip_check_:!0,value:`0 0 ${(0,s.bf)(yn)} 0`},transform:"translateY(50%) rotate(-135deg)",boxShadow:ge,zIndex:0,background:"transparent"}}},Ro=8;function So(O){const{contentRadius:N,limitVerticalRadius:ge}=O,Fe=N>12?N+2:12;return{arrowOffsetHorizontal:Fe,arrowOffsetVertical:ge?Ro:Fe}}function ia(O,N){return O?N:{}}function Jo(O,N,ge){const{componentCls:Fe,boxShadowPopoverArrow:Xt,arrowOffsetVertical:fr,arrowOffsetHorizontal:Qr}=O,{arrowDistance:yn=0,arrowPlacement:_n={left:!0,right:!0,top:!0,bottom:!0}}=ge||{};return{[Fe]:Object.assign(Object.assign(Object.assign(Object.assign({[`${Fe}-arrow`]:[Object.assign(Object.assign({position:"absolute",zIndex:1,display:"block"},fi(O,N,Xt)),{"&:before":{background:N}})]},ia(!!_n.top,{[[`&-placement-top > ${Fe}-arrow`,`&-placement-topLeft > ${Fe}-arrow`,`&-placement-topRight > ${Fe}-arrow`].join(",")]:{bottom:yn,transform:"translateY(100%) rotate(180deg)"},[`&-placement-top > ${Fe}-arrow`]:{left:{_skip_check_:!0,value:"50%"},transform:"translateX(-50%) translateY(100%) rotate(180deg)"},[`&-placement-topLeft > ${Fe}-arrow`]:{left:{_skip_check_:!0,value:Qr}},[`&-placement-topRight > ${Fe}-arrow`]:{right:{_skip_check_:!0,value:Qr}}})),ia(!!_n.bottom,{[[`&-placement-bottom > ${Fe}-arrow`,`&-placement-bottomLeft > ${Fe}-arrow`,`&-placement-bottomRight > ${Fe}-arrow`].join(",")]:{top:yn,transform:"translateY(-100%)"},[`&-placement-bottom > ${Fe}-arrow`]:{left:{_skip_check_:!0,value:"50%"},transform:"translateX(-50%) translateY(-100%)"},[`&-placement-bottomLeft > ${Fe}-arrow`]:{left:{_skip_check_:!0,value:Qr}},[`&-placement-bottomRight > ${Fe}-arrow`]:{right:{_skip_check_:!0,value:Qr}}})),ia(!!_n.left,{[[`&-placement-left > ${Fe}-arrow`,`&-placement-leftTop > ${Fe}-arrow`,`&-placement-leftBottom > ${Fe}-arrow`].join(",")]:{right:{_skip_check_:!0,value:yn},transform:"translateX(100%) rotate(90deg)"},[`&-placement-left > ${Fe}-arrow`]:{top:{_skip_check_:!0,value:"50%"},transform:"translateY(-50%) translateX(100%) rotate(90deg)"},[`&-placement-leftTop > ${Fe}-arrow`]:{top:fr},[`&-placement-leftBottom > ${Fe}-arrow`]:{bottom:fr}})),ia(!!_n.right,{[[`&-placement-right > ${Fe}-arrow`,`&-placement-rightTop > ${Fe}-arrow`,`&-placement-rightBottom > ${Fe}-arrow`].join(",")]:{left:{_skip_check_:!0,value:yn},transform:"translateX(-100%) rotate(-90deg)"},[`&-placement-right > ${Fe}-arrow`]:{top:{_skip_check_:!0,value:"50%"},transform:"translateY(-50%) translateX(-100%) rotate(-90deg)"},[`&-placement-rightTop > ${Fe}-arrow`]:{top:fr},[`&-placement-rightBottom > ${Fe}-arrow`]:{bottom:fr}}))}}function ka(O,N,ge,Fe){if(Fe===!1)return{adjustX:!1,adjustY:!1};const Xt=Fe&&typeof Fe=="object"?Fe:{},fr={};switch(O){case"top":case"bottom":fr.shiftX=N.arrowOffsetHorizontal*2+ge,fr.shiftY=!0,fr.adjustY=!0;break;case"left":case"right":fr.shiftY=N.arrowOffsetVertical*2+ge,fr.shiftX=!0,fr.adjustX=!0;break}const Qr=Object.assign(Object.assign({},fr),Xt);return Qr.shiftX||(Qr.adjustX=!0),Qr.shiftY||(Qr.adjustY=!0),Qr}const Ui={left:{points:["cr","cl"]},right:{points:["cl","cr"]},top:{points:["bc","tc"]},bottom:{points:["tc","bc"]},topLeft:{points:["bl","tl"]},leftTop:{points:["tr","tl"]},topRight:{points:["br","tr"]},rightTop:{points:["tl","tr"]},bottomRight:{points:["tr","br"]},rightBottom:{points:["bl","br"]},bottomLeft:{points:["tl","bl"]},leftBottom:{points:["br","bl"]}},ph={topLeft:{points:["bl","tc"]},leftTop:{points:["tr","cl"]},topRight:{points:["br","tc"]},rightTop:{points:["tl","cr"]},bottomRight:{points:["tr","bc"]},rightBottom:{points:["bl","cr"]},bottomLeft:{points:["tl","bc"]},leftBottom:{points:["br","cl"]}},Zl=new Set(["topLeft","topRight","bottomLeft","bottomRight","leftTop","leftBottom","rightTop","rightBottom"]);function Bh(O){const{arrowWidth:N,autoAdjustOverflow:ge,arrowPointAtCenter:Fe,offset:Xt,borderRadius:fr,visibleFirst:Qr}=O,yn=N/2,_n={};return Object.keys(Ui).forEach(vn=>{const Oi=Fe&&ph[vn]||Ui[vn],ki=Object.assign(Object.assign({},Oi),{offset:[0,0],dynamicInset:!0});switch(_n[vn]=ki,Zl.has(vn)&&(ki.autoArrow=!1),vn){case"top":case"topLeft":case"topRight":ki.offset[1]=-yn-Xt;break;case"bottom":case"bottomLeft":case"bottomRight":ki.offset[1]=yn+Xt;break;case"left":case"leftTop":case"leftBottom":ki.offset[0]=-yn-Xt;break;case"right":case"rightTop":case"rightBottom":ki.offset[0]=yn+Xt;break}const Io=So({contentRadius:fr,limitVerticalRadius:!0});if(Fe)switch(vn){case"topLeft":case"bottomLeft":ki.offset[0]=-Io.arrowOffsetHorizontal-yn;break;case"topRight":case"bottomRight":ki.offset[0]=Io.arrowOffsetHorizontal+yn;break;case"leftTop":case"rightTop":ki.offset[1]=-Io.arrowOffsetHorizontal-yn;break;case"leftBottom":case"rightBottom":ki.offset[1]=Io.arrowOffsetHorizontal+yn;break}ki.overflow=ka(vn,Io,N,ge),Qr&&(ki.htmlRegion="visibleFirst")}),_n}var Wh=A(48894),Fl=A(58068);const Uf=["blue","purple","cyan","green","magenta","pink","red","orange","yellow","volcano","geekblue","lime","gold"];function wf(O,N){return Uf.reduce((ge,Fe)=>{const Xt=O[`${Fe}1`],fr=O[`${Fe}3`],Qr=O[`${Fe}6`],yn=O[`${Fe}7`];return Object.assign(Object.assign({},ge),N(Fe,{lightColor:Xt,lightBorderColor:fr,darkColor:Qr,textColor:yn}))},{})}const lp=O=>{const{componentCls:N,tooltipMaxWidth:ge,tooltipColor:Fe,tooltipBg:Xt,tooltipBorderRadius:fr,zIndexPopup:Qr,controlHeight:yn,boxShadowSecondary:_n,paddingSM:vn,paddingXS:Oi}=O;return[{[N]:Object.assign(Object.assign(Object.assign(Object.assign({},(0,o.Wf)(O)),{position:"absolute",zIndex:Qr,display:"block",width:"max-content",maxWidth:ge,visibility:"visible",transformOrigin:"var(--arrow-x, 50%) var(--arrow-y, 50%)","&-hidden":{display:"none"},"--antd-arrow-background-color":Xt,[`${N}-inner`]:{minWidth:yn,minHeight:yn,padding:`${(0,s.bf)(O.calc(vn).div(2).equal())} ${(0,s.bf)(Oi)}`,color:Fe,textAlign:"start",textDecoration:"none",wordWrap:"break-word",backgroundColor:Xt,borderRadius:fr,boxShadow:_n,boxSizing:"border-box"},[["&-placement-left","&-placement-leftTop","&-placement-leftBottom","&-placement-right","&-placement-rightTop","&-placement-rightBottom"].join(",")]:{[`${N}-inner`]:{borderRadius:O.min(fr,Ro)}},[`${N}-content`]:{position:"relative"}}),wf(O,(ki,Io)=>{let{darkColor:Fi}=Io;return{[`&${N}-${ki}`]:{[`${N}-inner`]:{backgroundColor:Fi},[`${N}-arrow`]:{"--antd-arrow-background-color":Fi}}}})),{"&-rtl":{direction:"rtl"}})},Jo(O,"var(--antd-arrow-background-color)"),{[`${N}-pure`]:{position:"relative",maxWidth:"none",margin:O.sizePopupArrow}}]},tp=O=>Object.assign(Object.assign({zIndexPopup:O.zIndexPopupBase+70},So({contentRadius:O.borderRadius,limitVerticalRadius:!0})),Bn((0,Hn.TS)(O,{borderRadiusOuter:Math.min(O.borderRadiusOuter,4)})));var cd=function(O){let N=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return(0,yi.I$)("Tooltip",Fe=>{const{borderRadius:Xt,colorTextLightSolid:fr,colorBgSpotlight:Qr}=Fe,yn=(0,Hn.TS)(Fe,{tooltipMaxWidth:250,tooltipColor:fr,tooltipBorderRadius:Xt,tooltipBg:Qr});return[lp(yn),Tn(Fe,"zoom-big-fast")]},tp,{resetStyle:!1,injectStyle:N})(O)};const Mm=Uf.map(O=>`${O}-inverse`),tm=null;function vm(O){return(arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0)?[].concat((0,Gs.Z)(Mm),(0,Gs.Z)(Uf)).includes(O):Uf.includes(O)}function Op(O){return tm.includes(O)}function Jp(O,N){const ge=vm(N),Fe=Mc()({[`${O}-${N}`]:N&&ge}),Xt={},fr={};return N&&!ge&&(Xt.background=N,fr["--antd-arrow-background-color"]=N),{className:Fe,overlayStyle:Xt,arrowStyle:fr}}var nv=O=>{const{prefixCls:N,className:ge,placement:Fe="top",title:Xt,color:fr,overlayInnerStyle:Qr}=O,{getPrefixCls:yn}=p.useContext(Oh.E_),_n=yn("tooltip",N),[vn,Oi,ki]=cd(_n),Io=Jp(_n,fr),Fi=Io.arrowStyle,Oo=Object.assign(Object.assign({},Qr),Io.overlayStyle),Ko=Mc()(Oi,ki,_n,`${_n}-pure`,`${_n}-placement-${Fe}`,ge,Io.className);return vn(p.createElement("div",{className:Ko,style:Fi},p.createElement("div",{className:`${_n}-arrow`}),p.createElement(yt,Object.assign({},O,{className:Oi,prefixCls:_n,overlayInnerStyle:Oo}),Xt)))},iv=function(O,N){var ge={};for(var Fe in O)Object.prototype.hasOwnProperty.call(O,Fe)&&N.indexOf(Fe)<0&&(ge[Fe]=O[Fe]);if(O!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Xt=0,Fe=Object.getOwnPropertySymbols(O);Xt{var ge,Fe;const{prefixCls:Xt,openClassName:fr,getTooltipContainer:Qr,overlayClassName:yn,color:_n,overlayInnerStyle:vn,children:Oi,afterOpenChange:ki,afterVisibleChange:Io,destroyTooltipOnHide:Fi,arrow:Oo=!0,title:Ko,overlay:_a,builtinPlacements:Ma,arrowPointAtCenter:go=!1,autoAdjustOverflow:Ga=!0}=O,uu=!!Oo,[,Ss]=(0,sr.ZP)(),{getPopupContainer:$u,getPrefixCls:il,direction:Pl}=p.useContext(Oh.E_),Au=(0,Fl.ln)("Tooltip"),Ll=p.useRef(null),Il=()=>{var gm;(gm=Ll.current)===null||gm===void 0||gm.forceAlign()};p.useImperativeHandle(N,()=>({forceAlign:Il,forcePopupAlign:()=>{Au.deprecated(!1,"forcePopupAlign","forceAlign"),Il()}}));const[Ah,Nh]=(0,us.Z)(!1,{value:(ge=O.open)!==null&&ge!==void 0?ge:O.visible,defaultValue:(Fe=O.defaultOpen)!==null&&Fe!==void 0?Fe:O.defaultVisible}),kh=!Ko&&!_a&&Ko!==0,Xh=gm=>{var Im,fv;Nh(kh?!1:gm),kh||((Im=O.onOpenChange)===null||Im===void 0||Im.call(O,gm),(fv=O.onVisibleChange)===null||fv===void 0||fv.call(O,gm))},xu=p.useMemo(()=>{var gm,Im;let fv=go;return typeof Oo=="object"&&(fv=(Im=(gm=Oo.pointAtCenter)!==null&&gm!==void 0?gm:Oo.arrowPointAtCenter)!==null&&Im!==void 0?Im:go),Ma||Bh({arrowPointAtCenter:fv,autoAdjustOverflow:Ga,arrowWidth:uu?Ss.sizePopupArrow:0,borderRadius:Ss.borderRadius,offset:Ss.marginXXS,visibleFirst:!0})},[go,Oo,Ma,Ss]),Xa=p.useMemo(()=>Ko===0?Ko:_a||Ko||"",[_a,Ko]),vs=p.createElement(qd.BR,null,typeof Xa=="function"?Xa():Xa),{getPopupContainer:ku,placement:yc="top",mouseEnterDelay:$c=.1,mouseLeaveDelay:Ph=.1,overlayStyle:zh,rootClassName:rp}=O,td=iv(O,["getPopupContainer","placement","mouseEnterDelay","mouseLeaveDelay","overlayStyle","rootClassName"]),md=il("tooltip",Xt),fd=il(),Yd=O["data-popover-inject"];let Nd=Ah;!("open"in O)&&!("visible"in O)&&kh&&(Nd=!1);const z0=(0,Wh.l$)(Oi)&&!(0,Wh.M2)(Oi)?Oi:p.createElement("span",null,Oi),v0=z0.props,T0=!v0.className||typeof v0.className=="string"?Mc()(v0.className,fr||`${md}-open`):v0.className,[cp,cm,rm]=cd(md,!Yd),Bm=Jp(md,_n),A0=Bm.arrowStyle,Nm=Object.assign(Object.assign({},vn),Bm.overlayStyle),zm=Mc()(yn,{[`${md}-rtl`]:Pl==="rtl"},Bm.className,rp,cm,rm),[nm,Pm]=(0,Kc.Cn)("Tooltip",td.zIndex),Vm=p.createElement(xi,Object.assign({},td,{zIndex:nm,showArrow:uu,placement:yc,mouseEnterDelay:$c,mouseLeaveDelay:Ph,prefixCls:md,overlayClassName:zm,overlayStyle:Object.assign(Object.assign({},A0),zh),getTooltipContainer:ku||Qr||$u,ref:Ll,builtinPlacements:xu,overlay:vs,visible:Nd,onVisibleChange:Xh,afterVisibleChange:ki!=null?ki:Io,overlayInnerStyle:Nm,arrowContent:p.createElement("span",{className:`${md}-arrow-content`}),motion:{motionName:(0,sa.m)(fd,"zoom-big-fast",O.transitionName),motionDeadline:1e3},destroyTooltipOnHide:!!Fi}),Nd?(0,Wh.Tm)(z0,{className:T0}):z0);return cp(p.createElement(xm.Z.Provider,{value:Pm},Vm))});uy._InternalPanelDoNotUseOrYouWillBeFired=nv;var Zv=uy,ly=p.forwardRef((O,N)=>{const{open:ge}=O,Fe=(0,p.useRef)(null),Xt=(0,p.useRef)(null);function fr(){up.Z.cancel(Xt.current),Xt.current=null}function Qr(){Xt.current=(0,up.Z)(()=>{var yn;(yn=Fe.current)===null||yn===void 0||yn.forceAlign(),Xt.current=null})}return p.useEffect(()=>(ge?Qr():fr(),fr),[ge,O.title]),p.createElement(Zv,Object.assign({ref:(0,Wo.sQ)(Fe,N)},O))});const C1=O=>{const{componentCls:N,antCls:ge,controlSize:Fe,dotSize:Xt,marginFull:fr,marginPart:Qr,colorFillContentHover:yn,handleColorDisabled:_n,calc:vn}=O;return{[N]:Object.assign(Object.assign({},(0,o.Wf)(O)),{position:"relative",height:Fe,margin:`${(0,s.bf)(Qr)} ${(0,s.bf)(fr)}`,padding:0,cursor:"pointer",touchAction:"none",["&-vertical"]:{margin:`${(0,s.bf)(fr)} ${(0,s.bf)(Qr)}`},[`${N}-rail`]:{position:"absolute",backgroundColor:O.railBg,borderRadius:O.borderRadiusXS,transition:`background-color ${O.motionDurationMid}`},[`${N}-track,${N}-tracks`]:{position:"absolute",transition:`background-color ${O.motionDurationMid}`},[`${N}-track`]:{backgroundColor:O.trackBg,borderRadius:O.borderRadiusXS},[`${N}-track-draggable`]:{boxSizing:"content-box",backgroundClip:"content-box",border:"solid rgba(0,0,0,0)"},"&:hover":{[`${N}-rail`]:{backgroundColor:O.railHoverBg},[`${N}-track`]:{backgroundColor:O.trackHoverBg},[`${N}-dot`]:{borderColor:yn},[`${N}-handle::after`]:{boxShadow:`0 0 0 ${(0,s.bf)(O.handleLineWidth)} ${O.colorPrimaryBorderHover}`},[`${N}-dot-active`]:{borderColor:O.dotActiveBorderColor}},[`${N}-handle`]:{position:"absolute",width:O.handleSize,height:O.handleSize,outline:"none","&::before":{content:'""',position:"absolute",insetInlineStart:vn(O.handleLineWidth).mul(-1).equal(),insetBlockStart:vn(O.handleLineWidth).mul(-1).equal(),width:vn(O.handleSize).add(vn(O.handleLineWidth).mul(2)).equal(),height:vn(O.handleSize).add(vn(O.handleLineWidth).mul(2)).equal(),backgroundColor:"transparent"},"&::after":{content:'""',position:"absolute",insetBlockStart:0,insetInlineStart:0,width:O.handleSize,height:O.handleSize,backgroundColor:O.colorBgElevated,boxShadow:`0 0 0 ${(0,s.bf)(O.handleLineWidth)} ${O.handleColor}`,borderRadius:"50%",cursor:"pointer",transition:` + inset-inline-start ${O.motionDurationMid}, + inset-block-start ${O.motionDurationMid}, + width ${O.motionDurationMid}, + height ${O.motionDurationMid}, + box-shadow ${O.motionDurationMid} + `},"&:hover, &:active, &:focus":{"&::before":{insetInlineStart:vn(O.handleSizeHover).sub(O.handleSize).div(2).add(O.handleLineWidthHover).mul(-1).equal(),insetBlockStart:vn(O.handleSizeHover).sub(O.handleSize).div(2).add(O.handleLineWidthHover).mul(-1).equal(),width:vn(O.handleSizeHover).add(vn(O.handleLineWidthHover).mul(2)).equal(),height:vn(O.handleSizeHover).add(vn(O.handleLineWidthHover).mul(2)).equal()},"&::after":{boxShadow:`0 0 0 ${(0,s.bf)(O.handleLineWidthHover)} ${O.handleActiveColor}`,width:O.handleSizeHover,height:O.handleSizeHover,insetInlineStart:O.calc(O.handleSize).sub(O.handleSizeHover).div(2).equal(),insetBlockStart:O.calc(O.handleSize).sub(O.handleSizeHover).div(2).equal()}}},[`${N}-mark`]:{position:"absolute",fontSize:O.fontSize},[`${N}-mark-text`]:{position:"absolute",display:"inline-block",color:O.colorTextDescription,textAlign:"center",wordBreak:"keep-all",cursor:"pointer",userSelect:"none","&-active":{color:O.colorText}},[`${N}-step`]:{position:"absolute",background:"transparent",pointerEvents:"none"},[`${N}-dot`]:{position:"absolute",width:Xt,height:Xt,backgroundColor:O.colorBgElevated,border:`${(0,s.bf)(O.handleLineWidth)} solid ${O.dotBorderColor}`,borderRadius:"50%",cursor:"pointer",transition:`border-color ${O.motionDurationSlow}`,pointerEvents:"auto","&-active":{borderColor:O.dotActiveBorderColor}},[`&${N}-disabled`]:{cursor:"not-allowed",[`${N}-rail`]:{backgroundColor:`${O.railBg} !important`},[`${N}-track`]:{backgroundColor:`${O.trackBgDisabled} !important`},[` + ${N}-dot + `]:{backgroundColor:O.colorBgElevated,borderColor:O.trackBgDisabled,boxShadow:"none",cursor:"not-allowed"},[`${N}-handle::after`]:{backgroundColor:O.colorBgElevated,cursor:"not-allowed",width:O.handleSize,height:O.handleSize,boxShadow:`0 0 0 ${(0,s.bf)(O.handleLineWidth)} ${_n}`,insetInlineStart:0,insetBlockStart:0},[` + ${N}-mark-text, + ${N}-dot + `]:{cursor:"not-allowed !important"}},[`&-tooltip ${ge}-tooltip-inner`]:{minWidth:"unset"}})}},Vy=(O,N)=>{const{componentCls:ge,railSize:Fe,handleSize:Xt,dotSize:fr,marginFull:Qr,calc:yn}=O,_n=N?"paddingBlock":"paddingInline",vn=N?"width":"height",Oi=N?"height":"width",ki=N?"insetBlockStart":"insetInlineStart",Io=N?"top":"insetInlineStart",Fi=yn(Fe).mul(3).sub(Xt).div(2).equal(),Oo=yn(Xt).sub(Fe).div(2).equal(),Ko=N?{borderWidth:`${(0,s.bf)(Oo)} 0`,transform:`translateY(${(0,s.bf)(yn(Oo).mul(-1).equal())})`}:{borderWidth:`0 ${(0,s.bf)(Oo)}`,transform:`translateX(${(0,s.bf)(O.calc(Oo).mul(-1).equal())})`};return{[_n]:Fe,[Oi]:yn(Fe).mul(3).equal(),[`${ge}-rail`]:{[vn]:"100%",[Oi]:Fe},[`${ge}-track,${ge}-tracks`]:{[Oi]:Fe},[`${ge}-track-draggable`]:Object.assign({},Ko),[`${ge}-handle`]:{[ki]:Fi},[`${ge}-mark`]:{insetInlineStart:0,top:0,[Io]:yn(Fe).mul(3).add(N?0:Qr).equal(),[vn]:"100%"},[`${ge}-step`]:{insetInlineStart:0,top:0,[Io]:Fe,[vn]:"100%",[Oi]:Fe},[`${ge}-dot`]:{position:"absolute",[ki]:yn(Fe).sub(fr).div(2).equal()}}},$y=O=>{const{componentCls:N,marginPartWithMark:ge}=O;return{[`${N}-horizontal`]:Object.assign(Object.assign({},Vy(O,!0)),{[`&${N}-with-marks`]:{marginBottom:ge}})}},Hy=O=>{const{componentCls:N}=O;return{[`${N}-vertical`]:Object.assign(Object.assign({},Vy(O,!1)),{height:"100%"})}},TA=O=>{const ge=O.controlHeightLG/4,Fe=O.controlHeightSM/2,Xt=O.lineWidth+1,fr=O.lineWidth+1*3;return{controlSize:ge,railSize:4,handleSize:ge,handleSizeHover:Fe,dotSize:8,handleLineWidth:Xt,handleLineWidthHover:fr,railBg:O.colorFillTertiary,railHoverBg:O.colorFillSecondary,trackBg:O.colorPrimaryBorder,trackHoverBg:O.colorPrimaryBorderHover,handleColor:O.colorPrimaryBorder,handleActiveColor:O.colorPrimary,handleColorDisabled:new rv.C(O.colorTextDisabled).onBackground(O.colorBgContainer).toHexShortString(),dotBorderColor:O.colorBorderSecondary,dotActiveBorderColor:O.colorPrimaryBorder,trackBgDisabled:O.colorBgContainerDisabled}};var MA=(0,yi.I$)("Slider",O=>{const N=(0,Hn.TS)(O,{marginPart:O.calc(O.controlHeight).sub(O.controlSize).div(2).equal(),marginFull:O.calc(O.controlSize).div(2).equal(),marginPartWithMark:O.calc(O.controlHeightLG).sub(O.controlSize).equal()});return[C1(N),$y(N),Hy(N)]},TA),U2=function(O,N){var ge={};for(var Fe in O)Object.prototype.hasOwnProperty.call(O,Fe)&&N.indexOf(Fe)<0&&(ge[Fe]=O[Fe]);if(O!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Xt=0,Fe=Object.getOwnPropertySymbols(O);Xttypeof ge=="number"?ge.toString():""}var A_=p.forwardRef((O,N)=>{const{prefixCls:ge,range:Fe,className:Xt,rootClassName:fr,style:Qr,disabled:yn,tooltipPrefixCls:_n,tipFormatter:vn,tooltipVisible:Oi,getTooltipPopupContainer:ki,tooltipPlacement:Io}=O,Fi=U2(O,["prefixCls","range","className","rootClassName","style","disabled","tooltipPrefixCls","tipFormatter","tooltipVisible","getTooltipPopupContainer","tooltipPlacement"]),{direction:Oo,slider:Ko,getPrefixCls:_a,getPopupContainer:Ma}=p.useContext(Oh.E_),go=p.useContext(Md.Z),Ga=yn!=null?yn:go,[uu,Ss]=p.useState({}),$u=(Xa,vs)=>{Ss(ku=>Object.assign(Object.assign({},ku),{[Xa]:vs}))},il=(Xa,vs)=>Xa||(vs?Oo==="rtl"?"left":"right":"top"),Pl=_a("slider",ge),[Au,Ll,Il]=MA(Pl),Ah=Mc()(Xt,Ko==null?void 0:Ko.className,fr,{[`${Pl}-rtl`]:Oo==="rtl"},Ll,Il);Oo==="rtl"&&!Fi.vertical&&(Fi.reverse=!Fi.reverse);const[Nh,kh]=p.useMemo(()=>Fe?typeof Fe=="object"?[!0,Fe.draggableTrack]:[!0,!1]:[!1],[Fe]),Xh=(Xa,vs)=>{var ku;const{index:yc,dragging:$c}=vs,{tooltip:Ph={},vertical:zh}=O,rp=Object.assign({},Ph),{open:td,placement:md,getPopupContainer:fd,prefixCls:Yd,formatter:Nd}=rp,z0=PA(Nd,vn),v0=z0?uu[yc]||$c:!1,T0=(ku=td!=null?td:Oi)!==null&&ku!==void 0?ku:td===void 0&&v0,cp=Object.assign(Object.assign({},Xa.props),{onMouseEnter:()=>$u(yc,!0),onMouseLeave:()=>$u(yc,!1),onFocus:cm=>{var rm;$u(yc,!0),(rm=Fi.onFocus)===null||rm===void 0||rm.call(Fi,cm)},onBlur:cm=>{var rm;$u(yc,!1),(rm=Fi.onBlur)===null||rm===void 0||rm.call(Fi,cm)}});return p.createElement(ly,Object.assign({},rp,{prefixCls:_a("tooltip",Yd!=null?Yd:_n),title:z0?z0(vs.value):"",open:T0,placement:il(md!=null?md:Io,zh),key:yc,overlayClassName:`${Pl}-tooltip`,getPopupContainer:fd||ki||Ma}),p.cloneElement(Xa,cp))},xu=Object.assign(Object.assign({},Ko==null?void 0:Ko.style),Qr);return Au(p.createElement(Be,Object.assign({},Fi,{step:Fi.step,range:Nh,draggableTrack:kh,className:Ah,style:xu,disabled:Ga,ref:N,prefixCls:Pl,handleRender:Xh})))});const Gy=O=>O?typeof O=="function"?O():O:null,j2=O=>{const{componentCls:N,popoverColor:ge,titleMinWidth:Fe,fontWeightStrong:Xt,innerPadding:fr,boxShadowSecondary:Qr,colorTextHeading:yn,borderRadiusLG:_n,zIndexPopup:vn,titleMarginBottom:Oi,colorBgElevated:ki,popoverBg:Io,titleBorderBottom:Fi,innerContentPadding:Oo,titlePadding:Ko}=O;return[{[N]:Object.assign(Object.assign({},(0,o.Wf)(O)),{position:"absolute",top:0,left:{_skip_check_:!0,value:0},zIndex:vn,fontWeight:"normal",whiteSpace:"normal",textAlign:"start",cursor:"auto",userSelect:"text",transformOrigin:"var(--arrow-x, 50%) var(--arrow-y, 50%)","--antd-arrow-background-color":ki,"&-rtl":{direction:"rtl"},"&-hidden":{display:"none"},[`${N}-content`]:{position:"relative"},[`${N}-inner`]:{backgroundColor:Io,backgroundClip:"padding-box",borderRadius:_n,boxShadow:Qr,padding:fr},[`${N}-title`]:{minWidth:Fe,marginBottom:Oi,color:yn,fontWeight:Xt,borderBottom:Fi,padding:Ko},[`${N}-inner-content`]:{color:ge,padding:Oo}})},Jo(O,"var(--antd-arrow-background-color)"),{[`${N}-pure`]:{position:"relative",maxWidth:"none",margin:O.sizePopupArrow,display:"inline-block",[`${N}-content`]:{display:"inline-block"}}}]},V2=O=>{const{componentCls:N}=O;return{[N]:Uf.map(ge=>{const Fe=O[`${ge}6`];return{[`&${N}-${ge}`]:{"--antd-arrow-background-color":Fe,[`${N}-inner`]:{backgroundColor:Fe},[`${N}-arrow`]:{background:"transparent"}}}})}},$2=O=>{const{lineWidth:N,controlHeight:ge,fontHeight:Fe,padding:Xt,wireframe:fr,zIndexPopupBase:Qr,borderRadiusLG:yn,marginXS:_n,lineType:vn,colorSplit:Oi,paddingSM:ki}=O,Io=ge-Fe,Fi=Io/2,Oo=Io/2-N,Ko=Xt;return Object.assign(Object.assign(Object.assign({titleMinWidth:177,zIndexPopup:Qr+30},Bn(O)),So({contentRadius:yn,limitVerticalRadius:!0})),{innerPadding:fr?0:12,titleMarginBottom:fr?0:_n,titlePadding:fr?`${Fi}px ${Ko}px ${Oo}px`:0,titleBorderBottom:fr?`${N}px ${vn} ${Oi}`:"none",innerContentPadding:fr?`${ki}px ${Ko}px`:0})};var IA=(0,yi.I$)("Popover",O=>{const{colorBgElevated:N,colorText:ge}=O,Fe=(0,Hn.TS)(O,{popoverBg:N,popoverColor:ge});return[j2(Fe),V2(Fe),Tn(Fe,"zoom-big")]},$2,{resetStyle:!1,deprecatedTokens:[["width","titleMinWidth"],["minWidth","titleMinWidth"]]}),H2=function(O,N){var ge={};for(var Fe in O)Object.prototype.hasOwnProperty.call(O,Fe)&&N.indexOf(Fe)<0&&(ge[Fe]=O[Fe]);if(O!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Xt=0,Fe=Object.getOwnPropertySymbols(O);Xt!N&&!ge?null:p.createElement(p.Fragment,null,N&&p.createElement("div",{className:`${O}-title`},Gy(N)),p.createElement("div",{className:`${O}-inner-content`},Gy(ge))),G2=O=>{const{hashId:N,prefixCls:ge,className:Fe,style:Xt,placement:fr="top",title:Qr,content:yn,children:_n}=O;return p.createElement("div",{className:Mc()(N,ge,`${ge}-pure`,`${ge}-placement-${fr}`,Fe),style:Xt},p.createElement("div",{className:`${ge}-arrow`}),p.createElement(yt,Object.assign({},O,{className:N,prefixCls:ge}),_n||RA(ge,Qr,yn)))};var OA=O=>{const{prefixCls:N,className:ge}=O,Fe=H2(O,["prefixCls","className"]),{getPrefixCls:Xt}=p.useContext(Oh.E_),fr=Xt("popover",N),[Qr,yn,_n]=IA(fr);return Qr(p.createElement(G2,Object.assign({},Fe,{prefixCls:fr,hashId:yn,className:Mc()(ge,_n)})))},LA=function(O,N){var ge={};for(var Fe in O)Object.prototype.hasOwnProperty.call(O,Fe)&&N.indexOf(Fe)<0&&(ge[Fe]=O[Fe]);if(O!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Xt=0,Fe=Object.getOwnPropertySymbols(O);Xt{let{title:N,content:ge,prefixCls:Fe}=O;return p.createElement(p.Fragment,null,N&&p.createElement("div",{className:`${Fe}-title`},Gy(N)),p.createElement("div",{className:`${Fe}-inner-content`},Gy(ge)))},DA=p.forwardRef((O,N)=>{const{prefixCls:ge,title:Fe,content:Xt,overlayClassName:fr,placement:Qr="top",trigger:yn="hover",mouseEnterDelay:_n=.1,mouseLeaveDelay:vn=.1,overlayStyle:Oi={}}=O,ki=LA(O,["prefixCls","title","content","overlayClassName","placement","trigger","mouseEnterDelay","mouseLeaveDelay","overlayStyle"]),{getPrefixCls:Io}=p.useContext(Oh.E_),Fi=Io("popover",ge),[Oo,Ko,_a]=IA(Fi),Ma=Io(),go=Mc()(fr,Ko,_a);return Oo(p.createElement(Zv,Object.assign({placement:Qr,trigger:yn,mouseEnterDelay:_n,mouseLeaveDelay:vn,overlayStyle:Oi},ki,{prefixCls:Fi,overlayClassName:go,ref:N,overlay:Fe||Xt?p.createElement(W2,{prefixCls:Fi,title:Fe,content:Xt}):null,transitionName:(0,sa.m)(Ma,"zoom-big",ki.transitionName),"data-popover-inject":!0})))});DA._InternalPanelDoNotUseOrYouWillBeFired=OA;var hE=DA,kA,FA,Sd;function Uv(O,N){return N||(N=O.slice(0)),Object.freeze(Object.defineProperties(O,{raw:{value:Object.freeze(N)}}))}var BA=function(){var N=Yp.Z.useToken,ge=N(),Fe=ge.token,Xt=Fe.colorText,fr=Fe.colorTextDescription,Qr=Fe.colorBgContainer,yn=Fe.borderRadius;return{settingContainer:(0,ad.iv)(kA||(kA=Uv([` + width: 200px; + `]))),settingBtn:(0,ad.iv)(FA||(FA=Uv([` + display: flex; + align-items: center; + justify-content: center; + width: 28px; + height: 28px; + background-color: `,`; + border-radius: `,`px; + cursor: pointer; + font-size: 16px; + + svg { + color: `,`; + } + + &:hover { + svg { + color: `,`; + } + } + `])),Qr,yn,fr,Xt),settingContainerItem:(0,ad.iv)(Sd||(Sd=Uv([` + display: flex; + justify-content: space-between; + `])))}},NA=BA,ng="li-map-view-setting-control",zA=new Map([["topleft","rightTop"],["topcenter","bottom"],["topright","leftTop"],["bottomleft","rightBottom"],["bottomcenter","top"],["bottomright","leftBottom"],["leftcenter","right"],["rightcenter","left"],[void 0,"rightBottom"]]),b_=function(){return p.createElement("svg",{viewBox:"0 0 64 64",width:"1em",height:"1em",fill:"currentcolor"},p.createElement("path",{fill:"currentcolor",d:"m52.98253,40.465802c-3.228081,0 -6.013093,2.120406 -6.64605,5.063657l-19.463432,0c0.221535,-1.898871 0,-3.797743 -0.632957,-5.285192c-0.632957,-1.487449 -1.708984,-2.753364 -3.228081,-3.797743l13.070565,-12.880678c0.854492,0.411422 1.708984,0.411422 2.563476,0.411422c3.861039,0 7.057472,-3.164786 7.057472,-6.962528c0.221535,-3.797743 -3.006546,-6.962528 -6.867585,-6.962528s-7.057472,3.164786 -7.057472,6.962528c0,0.854492 0.221535,1.898871 0.44307,2.531829l-14.779549,14.368127l-12.437608,12.247721c-0.632957,0.854492 -0.854492,1.487449 -0.854492,2.120406c0,0.411422 0,0.632957 0.221535,1.044379c0.44307,1.044379 1.487449,1.677336 2.563476,1.677336l40.477609,0c1.297562,1.677336 3.228081,2.943251 5.570023,2.943251c3.861039,0 6.867585,-2.943251 6.867585,-6.740994s-3.006546,-6.740994 -6.867585,-6.740994zm-35.129121,-0.854492c1.076027,0.632957 1.708984,1.487449 1.930519,2.310294c0.44307,0.854492 0.632957,1.898871 0.44307,2.943251l-7.722077,0l5.348488,-5.253544z"}))};function T1(O,N){return UA(O)||ZA(O,N)||Y2(O,N)||X2()}function X2(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Y2(O,N){if(O){if(typeof O=="string")return x_(O,N);var ge=Object.prototype.toString.call(O).slice(8,-1);if(ge==="Object"&&O.constructor&&(ge=O.constructor.name),ge==="Map"||ge==="Set")return Array.from(O);if(ge==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ge))return x_(O,N)}}function x_(O,N){(N==null||N>O.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge360?Math.round(Il-360):Math.round(360-Il));else{var Ah=Il===0?0:Il<0?Math.round(-Il):Math.round(360-Il);Oo(Ah)}};return Au(),fr==null||fr.on("moveend",Au),function(){fr==null||fr.off("moveend",Au)}}},[fr,Ga]);var il=(0,p.useMemo)(function(){return zA.get(ge)},[ge]),Pl=p.createElement("div",{className:Mc()("".concat(ng,"__setting-container"),_a.settingContainer)},p.createElement("div",{className:Mc()("".concat(ng,"__setting-container__item"),_a.settingContainerItem)},p.createElement("div",null,"\u5730\u56FE\u503E\u659C"),p.createElement("div",null,"".concat(vn,"\xB0"))),p.createElement(A_,{value:vn,min:0,max:Ko?90:60,onChange:Ss}),p.createElement("div",{className:Mc()("".concat(ng,"__setting-container__item"),_a.settingContainerItem)},p.createElement("div",null,"\u5730\u56FE\u65CB\u8F6C"),p.createElement("div",null,"".concat(Fi,"\xB0"))),p.createElement(A_,{value:Fi,min:0,max:360,onChange:$u}));return p.createElement($.br,{position:ge,className:ng},p.createElement(hE,{arrow:!1,placement:il,content:Pl,trigger:"click",open:Ga,onOpenChange:function(Ll){return uu(Ll)}},p.createElement(Zv,{placement:il,title:"\u5730\u56FE\u503E\u89D2"},p.createElement("div",{className:Mc()("".concat(ng,"__setting-btn"),_a.settingBtn)},p.createElement(SA,{component:b_})))))},jA=w_,K2=function(){var O={position:{title:"\u653E\u7F6E\u65B9\u4F4D",type:"string","x-decorator":"FormItem","x-component":"ControlPositionSelect",default:"bottomright"}};return{schema:O}},q2=(0,y.mV)({version:"v0.1",metadata:{name:"MapViewSettingControl",displayName:"\u503E\u89D2\u8C03\u6574",description:"\u8C03\u6574\u5730\u56FE\u89C6\u89D2",type:"Auto",category:"MapControl",icon:b_},defaultProperties:{position:"topright"},component:jA,registerForm:K2}),E_,VA,S_,C_,$A,HA,GA;function ig(O,N){return N||(N=O.slice(0)),Object.freeze(Object.defineProperties(O,{raw:{value:Object.freeze(N)}}))}var WA=function(){var N=Yp.Z.useToken,ge=N(),Fe=ge.token,Xt=Fe.colorText,fr=Fe.colorTextDescription,Qr=Fe.colorBgElevated,yn=Fe.zIndexBase,_n=Fe.zIndexPopupBase;return{layerPopup:(0,ad.iv)(E_||(E_=ig([` + width: 280px !important; + // \u56FE\u5C42\u4FE1\u606F\u6846\u663E\u793A\u5C42\u7EA7\u4F4D\u4E8E\u5C5E\u6027\u9762\u677F\uFF08zIndexPopupBase + 80\uFF09\u4E4B\u4E0A + z-index: `,`; + + .l7-popup-tip { + border-top-color: `,`; + border-bottom-color: `,`; + } + + .l7-popup-content { + padding: 12px; + color: `,`; + background: `,`; + + .l7-popup-close-button { + fill: `,`; + } + } + `])),_n+100,Qr,Qr,Xt,Qr,Xt),popupRow:(0,ad.iv)(VA||(VA=ig([` + display: flex; + width: 100%; + height: 28px; + color: `,`; + line-height: 28px; + `])),fr),popupRowImage:(0,ad.iv)(S_||(S_=ig([` + display: flex; + width: 100%; + height: 40px; + color: `,`; + line-height: 40px; + `])),fr),imagePreview:(0,ad.iv)(C_||(C_=ig([` + .ant-image-preview-wrap { + z-index: `,`; + } + `])),_n+101),rowItem:(0,ad.iv)($A||($A=ig([` + overflow: hidden; + font-weight: 500; + font-size: 12px; + white-space: nowrap; + text-overflow: ellipsis; + `]))),rowKey:(0,ad.iv)(HA||(HA=ig([` + max-width: 90%; + text-align: left; + `]))),rowValue:(0,ad.iv)(GA||(GA=ig([` + flex: 1; + min-width: 10%; + margin-left: 5px; + color: `,`; + text-align: right !important; + `])),Xt)}},XA=WA,T_=function(N){var ge=/^(https|http).*(jpeg|jpg|gif|png)/;return ge.test(N)};function M1(O){"@babel/helpers - typeof";return M1=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(N){return typeof N}:function(N){return N&&typeof Symbol=="function"&&N.constructor===Symbol&&N!==Symbol.prototype?"symbol":typeof N},M1(O)}var Ig="li-layer-popup",Q2=function(N){var ge=N.isOpen,Fe=ge===void 0?!0:ge,Xt=N.trigger,fr=N.items,Qr=fr===void 0?[]:fr,yn=XA(),_n=Xt==="click",vn=(0,p.useMemo)(function(){var Oi=Qr.map(function(ki){var Io=new Map,Fi=ki.layerId,Oo=ki.fields;Oo.forEach(function(_a){Io.has(_a.field)||Io.set(_a.field,_a)});var Ko=Array.from(Io.values());return{layer:Fi,fields:Ko,customContent:function(Ma){return p.createElement(p.Fragment,null,Ko.map(function(go,Ga){var uu=go.formatField?"".concat(go.formatField,":"):"".concat(go.field,":"),Ss=M1(Ma[go.field])==="object"?JSON.stringify(Ma[go.field]):Ma[go.field];return T_(Ss)?p.createElement("div",{className:Mc()("".concat(Ig,"__row_image"),yn.popupRowImage),key:Ga},p.createElement("div",{className:Mc()("".concat(Ig,"__row_key"),yn.rowItem,yn.rowKey)},uu),p.createElement("div",{className:Mc()("".concat(Ig,"__row_value"),yn.rowItem,yn.rowValue)},p.createElement(d1,{rootClassName:yn.imagePreview,referrerPolicy:"no-referrer",height:40,src:Ss}))):p.createElement("div",{className:Mc()("".concat(Ig,"__row_item"),yn.popupRow),key:Ga},p.createElement("div",{className:Mc()("".concat(Ig,"__row_key"),yn.rowItem,yn.rowKey)},uu),p.createElement("div",{className:Mc()("".concat(Ig,"__row_value"),yn.rowItem,yn.rowValue)},Ss))}))}}}).filter(function(ki){return ki&&ki.fields.length});return Oi},[Qr]);return p.createElement(p.Fragment,null,Fe&&p.createElement($.Kh,{className:Mc()(Ig,yn.layerPopup),closeButton:_n,anchor:"top-left",offsets:[10,-10],items:vn,trigger:Xt}))},J2=Q2;function Wy(O){"@babel/helpers - typeof";return Wy=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(N){return typeof N}:function(N){return N&&typeof Symbol=="function"&&N.constructor===Symbol&&N!==Symbol.prototype?"symbol":typeof N},Wy(O)}var Pv=["items"],YA=["items"];function KA(O,N){return M_(O)||rx(O,N)||tx(O,N)||ex()}function ex(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function tx(O,N){if(O){if(typeof O=="string")return qA(O,N);var ge=Object.prototype.toString.call(O).slice(8,-1);if(ge==="Object"&&O.constructor&&(ge=O.constructor.name),ge==="Map"||ge==="Set")return Array.from(O);if(ge==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ge))return qA(O,N)}}function qA(O,N){(N==null||N>O.length)&&(N=O.length);for(var ge=0,Fe=new Array(N);ge=0)&&Object.prototype.propertyIsEnumerable.call(O,Fe)&&(ge[Fe]=O[Fe])}return ge}function ox(O,N){if(O==null)return{};var ge={},Fe=Object.keys(O),Xt,fr;for(fr=0;fr=0)&&(ge[Xt]=O[Xt]);return ge}var ax=function(N){var ge=N.items,Fe=JA(N,Pv),Xt=ge.reduce(function(fr,Qr){var yn=Qr.layerId;return fr[yn]=Qr.fields.map(function(_n){return{field:_n.field,formatField:_n.formatField}}),fr},{});return cy(cy({},Fe),{},{items:Xt})},sx=function(N){var ge=N.items,Fe=JA(N,YA),Xt=Object.entries(ge).map(function(fr){var Qr=KA(fr,2),yn=Qr[0],_n=Qr[1];return{layerId:yn,fields:_n.map(function(vn){return{field:vn.field,formatField:vn.formatField!==""?vn.formatField:void 0}})}});return cy(cy({},Fe),{},{items:Xt})},eb=function(N){var ge=N.layers,Fe=N.datasets,Xt=ge.filter(function(Qr){return!["GridLayer","HexbinLayer","HeatmapLayer"].includes(Qr.type)}).map(function(Qr){var yn=Fe.find(function(Oi){return Oi.id===Qr.sourceConfig.datasetId});if(!(yn===void 0||!(0,y.mi)(yn))){var _n=(yn==null?void 0:yn.columns)||[],vn=_n.map(function(Oi){return{label:Oi.name,value:Oi.name}});return P_({},"items.".concat(Qr.id),{type:"array","x-component":"ArrayItems","x-component-props":{style:{width:"100%",marginTop:10}},"x-decorator":"FormItem","x-decorator-props":{labelWidth:"100%",wrapperWidth:"100%",layout:"vertical"},title:Qr.metadata.name,items:{type:"object",properties:{fields:{type:"void","x-component":"FormGrid","x-component-props":{colWrap:!1},properties:{field:{type:"string",enum:vn,"x-decorator":"FormItem",required:!0,"x-decorator-props":{gridSpan:7},"x-component":"Select","x-component-props":{placeholder:"\u9009\u62E9\u7C7B\u76EE\u6807\u7B7E"}},formatField:{type:"string","x-decorator":"FormItem","x-component":"Input","x-decorator-props":{gridSpan:6},"x-component-props":{placeholder:"\u8F93\u5165\u7C7B\u76EE\u522B\u540D"}},remove:{type:"void","x-decorator":"FormItem","x-component":"ArrayItems.Remove","x-component-props":{},"x-decorator-props":{gridSpan:1}}}}}},properties:{add:{type:"void",title:"\u6DFB\u52A0\u7C7B\u76EE","x-component":"ArrayItems.Addition","x-component-props":{block:!0}}}})}}).filter(function(Qr){return Qr!==void 0}),fr=Xt.reduce(function(Qr,yn){return Object.assign(Qr,yn)},{});return fr},tb=function(O){var N=cy({isOpen:{title:"\u5F00\u542F\u56FE\u5C42\u4FE1\u606F\u6846",type:"boolean","x-decorator":"FormItem","x-component":"Switch",default:!0,"x-decorator-props":{labelCol:9,wrapperCol:15}},trigger:{title:"\u6253\u5F00\u65B9\u5F0F",type:"string","x-decorator":"FormItem","x-component":"Select","x-component-props":{options:[{value:"click",label:"\u70B9\u51FB"},{value:"hover",label:"\u5212\u5165"}]},default:"hover"}},eb(O));return{schema:N,toValues:ax,fromValues:sx}},ux=function(){return p.createElement("svg",{viewBox:"0 0 64 64",width:"1em",height:"1em",fill:"currentColor"},p.createElement("path",{fill:"currentColor",transform:"rotate(180 31.999999999999996,32)",d:"m48.786114,21.23426l-33.572225,0l0,-5.382871l33.572225,0l0,5.382871m0,8.074306l-33.572225,0l0,-5.382871l33.572225,0l0,5.382871m0,8.074306l-33.572225,0l0,-5.382871l33.572225,0l0,5.382871m11.190742,-26.914353c0,-2.960579 -2.517917,-5.382871 -5.595371,-5.382871l-44.762966,0c-3.077454,0 -5.595371,2.422292 -5.595371,5.382871l0,32.297224c0,2.960579 2.517917,5.382871 5.595371,5.382871l39.167595,0l11.190742,10.765741l0,-48.445836z"}))},lx=(0,y.mV)({version:"v0.1",metadata:{name:"LayerPopup",displayName:"\u4FE1\u606F\u6846",description:"\u5F39\u7A97\u5F62\u5F0F\u5C55\u793A\u56FE\u5C42\u7684\u989D\u5916\u4FE1\u606F",type:"Auto",category:"LayerInteraction",icon:ux},defaultProperties:{isOpen:!0,trigger:"hover",items:[]},component:J2,registerForm:tb}),cx=function(N){var ge=N.position,Fe=N.url,Xt=N.href,fr=N.height,Qr=N.width;return p.createElement($.OB,{position:ge,img:Fe,href:Xt||"",style:{width:Qr,height:fr}})},fx=cx,hx=function(){var O={position:{title:"\u653E\u7F6E\u65B9\u4F4D",type:"string","x-decorator":"FormItem","x-component":"ControlPositionSelect",default:"bottomLeft"},url:{title:"\u56FE\u7247\u5730\u5740",type:"string","x-decorator":"FormItem","x-component":"Input",default:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*GRb1TKp4HcMAAAAAAAAAAAAAARQnAQ"},href:{title:"\u8DF3\u8F6C\u5730\u5740",type:"string","x-decorator":"FormItem","x-component":"Input"},width:{title:"\u56FE\u7247\u5BBD\u5EA6",type:"string","x-decorator":"FormItem","x-component":"NumberPicker","x-component-props":{addonAfter:"px",min:0,precision:0},default:89},height:{title:"\u56FE\u7247\u9AD8\u5EA6",type:"string","x-decorator":"FormItem","x-component":"NumberPicker","x-component-props":{addonAfter:"px",min:0,precision:0},default:16}};return{schema:O}},dx=function(){return p.createElement("svg",{viewBox:"0 0 64 64",width:"1em",height:"1em",fill:"currentColor"},p.createElement("path",{fill:"currentColor",d:"m7.552775,33.880555l-3.761111,0l0,-18.805557l3.761111,0l0,15.044446l7.522223,0l0,3.761111l-7.522223,0zm-3.761111,15.044446l56.416671,0l0,-3.761111l-56.416671,0l0,3.761111zm37.611114,-7.522223l-7.522223,0l0,-3.761111l7.522223,0l0,-3.761111l-7.522223,0l0,-11.283334l7.522223,0l3.761111,0l0,11.283334l0,3.761111l0,3.761111l-3.761111,0zm0,-11.283334l0,-3.761111l-3.761111,0l0,3.761111l3.761111,0zm18.805557,-7.522223l0,11.283334l-11.283334,0l0,-11.283334l11.283334,0zm-3.761111,3.761111l-3.761111,0l0,3.761111l3.761111,0l0,-3.761111zm-26.32778,7.522223l-11.283334,0l0,-11.283334l11.283334,0l0,11.283334zm-3.700934,-7.522223l-3.761111,0l0,3.761111l3.761111,0l0,-3.761111z"}))},rb=(0,y.mV)({version:"v0.1",metadata:{name:"LogoControl",displayName:"Logo",description:"\u81EA\u5B9A\u4E49 Logo \u56FE\u6807",type:"Auto",category:"MapControl",icon:dx},defaultProperties:{position:"leftbottom",url:"https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*GRb1TKp4HcMAAAAAAAAAAAAAARQnAQ",width:89,height:16},component:fx,registerForm:hx}),nb=[Mo,Bi,lu,Da,Uu,Bu,cu,te,Oc,nh,Tp],px=Object.values(V),mx=Object.values(R),vx={version:"v0.1",layers:nb,widgets:px,services:mx}},71720:function(Ye,ye,A){var Bd,Qd,Jd,Ed,_p,oe,o,s,l,g,M,j,J,ve,ze,lt,Dt,$t,lr,z2,Vr,qg,Xr,Gr,Br,Tn,Hn,yi,vo,Eo,Ry,ys,Yo,es,qa,Ts,is,ts,Rs,pu,nl,la,Es,sl,Bf,Vl,oc,zc,xc,ih,wh,hh,dh,Jf,pf,ec,Jc,zl,Zc,Lh,yA,pa,nE,Rc,iE,oh,oE,d,aE,G,sE,Te,uE,ht,lE,Yt,zM,Ir;"use strict";A.d(ye,{JX:function(){return To},h_:function(){return B},LY:function(){return Ks},d_:function(){return Vt},Fl:function(){return El},$v:function(){return rc},mV:function(){return pl},p5:function(){return wd},mi:function(){return Qn},dL:function(){return em},uQ:function(){return Hi},$r:function(){return nh}});var R=A(7292),V=A(92310),y=A.n(V),p=A(77617),$=A(8142),X=function(Z){return Z.ADD_DATASET="add:dataset",Z.REMOVE_DATASET="remove:dataset",Z.UPDATE_DATASET="update:dataset",Z.ADD_FILTER="add:filter",Z.UPDATE_FILTER="update:filter",Z.REMOVE_FILTER="remove:filter",Z.CLEAR_FILTER="clear:filter",Z}({}),se=function(Z){return Z.SET_SCENE="set-scene",Z.UPDATE_VIEWSTATE="update:view-state",Z}({}),ae=function(Z){return Z.ADD_LAYER="add:layer",Z.REMOVE_LAYER="remove:layer",Z.UPDATE_LAYER="update:layer",Z.SET_LAYERMANAGER="set:layer-manager",Z}({}),ce=function(Z){return Z.UPDATE_WIDGETSPROPS="update:widgets-props",Z}({}),le=function(Z){return Z.UPDATE_GLOBAL="update:global",Z}({}),De=p.createContext(null),we=function(){var z=p.useContext(De);if(z===void 0||Object.keys(z).length===0)throw new Error("useLIContext must be used within a LIContext.Provider");return z},Ee=function(){var z=we(),Q=z.stateManager;return Q};function qe(Z,z){return Xe(Z)||ut(Z,z)||ct(Z,z)||Ge()}function Ge(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ct(Z,z){if(Z){if(typeof Z=="string")return Ve(Z,z);var Q=Object.prototype.toString.call(Z).slice(8,-1);if(Q==="Object"&&Z.constructor&&(Q=Z.constructor.name),Q==="Map"||Q==="Set")return Array.from(Z);if(Q==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Q))return Ve(Z,z)}}function Ve(Z,z){(z==null||z>Z.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);QZ.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);Q2&&arguments[2]!==void 0?arguments[2]:50,Pt=z.length,tr=Math.max(Math.floor(Pt/Pe),1),Sr=0;SrZ.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);Q=Dr&&z<=Kr};return Tr(Q).some(Pe)};function bn(Z,z){var Q=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},Pe=ri(z,Q),Pt=Q.useRegExp?Z:Z.map(function(Sr){var Dr=dn(ri(Sr,Q));return Q.mustStart&&(Dr="^".concat(Dr)),Q.mustEnd&&(Dr="".concat(Dr,"$")),Dr}),tr=new RegExp(Pt.join("|"),Q.caseSensitive?"g":"gi");return!!Pe.match(tr)}var Bi=/[.*+?^${}()|[\]\\]/g,on=/(?:[\^`\xA8\xAF\xB4\xB7\xB8\u02B0-\u034E\u0350-\u0357\u035D-\u0362\u0374\u0375\u037A\u0384\u0385\u0483-\u0487\u0559\u0591-\u05A1\u05A3-\u05BD\u05BF\u05C1\u05C2\u05C4\u064B-\u0652\u0657\u0658\u06DF\u06E0\u06E5\u06E6\u06EA-\u06EC\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F5\u0818\u0819\u0898-\u089F\u08C9-\u08D2\u08E3-\u08FE\u093C\u094D\u0951-\u0954\u0971\u09BC\u09CD\u0A3C\u0A4D\u0ABC\u0ACD\u0AFD-\u0AFF\u0B3C\u0B4D\u0B55\u0BCD\u0C3C\u0C4D\u0CBC\u0CCD\u0D3B\u0D3C\u0D4D\u0DCA\u0E47-\u0E4C\u0E4E\u0EBA\u0EC8-\u0ECC\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F82-\u0F84\u0F86\u0F87\u0FC6\u1037\u1039\u103A\u1063\u1064\u1069-\u106D\u1087-\u108D\u108F\u109A\u109B\u135D-\u135F\u1714\u1715\u17C9-\u17D3\u17DD\u1939-\u193B\u1A75-\u1A7C\u1A7F\u1AB0-\u1ABE\u1AC1-\u1ACB\u1B34\u1B44\u1B6B-\u1B73\u1BAA\u1BAB\u1C36\u1C37\u1C78-\u1C7D\u1CD0-\u1CE8\u1CED\u1CF4\u1CF7-\u1CF9\u1D2C-\u1D6A\u1DC4-\u1DCF\u1DF5-\u1DFF\u1FBD\u1FBF-\u1FC1\u1FCD-\u1FCF\u1FDD-\u1FDF\u1FED-\u1FEF\u1FFD\u1FFE\u2CEF-\u2CF1\u2E2F\u302A-\u302F\u3099-\u309C\u30FC\uA66F\uA67C\uA67D\uA67F\uA69C\uA69D\uA6F0\uA6F1\uA700-\uA721\uA788-\uA78A\uA7F8\uA7F9\uA8C4\uA8E0-\uA8F1\uA92B-\uA92E\uA953\uA9B3\uA9C0\uA9E5\uAA7B-\uAA7D\uAABF-\uAAC2\uAAF6\uAB5B-\uAB5F\uAB69-\uAB6B\uABEC\uABED\uFB1E\uFE20-\uFE2F\uFF3E\uFF40\uFF70\uFF9E\uFF9F\uFFE3]|\uD800\uDEE0|\uD801[\uDF80-\uDF85\uDF87-\uDFB0\uDFB2-\uDFBA]|\uD802[\uDEE5\uDEE6]|\uD803[\uDD22-\uDD27\uDEFD-\uDEFF\uDF46-\uDF50\uDF82-\uDF85]|\uD804[\uDC46\uDC70\uDCB9\uDCBA\uDD33\uDD34\uDD73\uDDC0\uDDCA-\uDDCC\uDE35\uDE36\uDEE9\uDEEA\uDF3C\uDF4D\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC42\uDC46\uDCC2\uDCC3\uDDBF\uDDC0\uDE3F\uDEB6\uDEB7\uDF2B]|\uD806[\uDC39\uDC3A\uDD3D\uDD3E\uDD43\uDDE0\uDE34\uDE47\uDE99]|\uD807[\uDC3F\uDD42\uDD44\uDD45\uDD97]|\uD80D[\uDC47-\uDC55]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF8F-\uDF9F\uDFF0\uDFF1]|\uD82B[\uDFF0-\uDFF3\uDFF5-\uDFFB\uDFFD\uDFFE]|\uD833[\uDF00-\uDF2D\uDF30-\uDF46]|\uD834[\uDD67-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD]|\uD838[\uDC30-\uDC6D\uDD30-\uDD36\uDEAE\uDEEC-\uDEEF]|\uD83A[\uDCD0-\uDCD6\uDD44-\uDD46\uDD48-\uDD4A])/g;function dn(Z){return Z.replace(Bi,"\\$&")}function ri(Z,z){var Q=String(Z);return z.keepSpecialCharacters||(Q=Q.normalize("NFD").replace(on,"")),Q}var Wn=function(z,Q){return Q.includes(z)},Rn=function(z,Q){return!Q.includes(z)},di=function(z,Q){return bn([Q],z)},zi=function(z,Q){return!bn([Q],z)},Gi=function(z,Q){return z===Q},Lo=function(z,Q){return z>Q},eo=function(z,Q){return z>=Q},ba=function(z,Q){return zPt}else return!1},fo=function(z,Q){var Pe=new Date(z).getTime();if(isFinite(Pe)){var Pt=new Date(Q).getTime();return Pe":Lo,">=":eo,"<":ba,"<=":va,BETWEEN:Do},date:{BETWEEN:Ps,">":Nr,"<":fo}};function Yi(Z){"@babel/helpers - typeof";return Yi=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(z){return typeof z}:function(z){return z&&typeof Symbol=="function"&&z.constructor===Symbol&&z!==Symbol.prototype?"symbol":typeof z},Yi(Z)}function ga(Z,z){var Q=Object.keys(Z);if(Object.getOwnPropertySymbols){var Pe=Object.getOwnPropertySymbols(Z);z&&(Pe=Pe.filter(function(Pt){return Object.getOwnPropertyDescriptor(Z,Pt).enumerable})),Q.push.apply(Q,Pe)}return Q}function Xi(Z){for(var z=1;z1&&arguments[1]!==void 0?arguments[1]:"datasetId",Pe=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"\u5173\u8054\u7684\u6570\u636E\u6E90",Pt=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,tr=z.datasets.map(function(Sr){return{label:Sr.metadata.name,value:Sr.id,columns:gr(isLocalOrRemoteDataset(Sr)?Sr.columns:[])}});return Pn({},Q,{type:"string",title:Pe,required:Pt,enum:tr,"x-decorator":"FormItem","x-component":"Select","x-component-props":{placeholder:"\u8BF7\u9009\u62E9\u6570\u636E\u6E90"},"x-decorator-props":{tooltip:"\u8BF7\u9009\u62E9\u5173\u8054\u7684\u6570\u636E\u96C6\u4F5C\u4E3A\u6570\u636E\u6E90"}})},un=function(z){var Q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"serviceName",Pe=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"\u5173\u8054\u7684\u670D\u52A1",Pt=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,tr=arguments.length>4&&arguments[4]!==void 0?arguments[4]:[],Sr=z.services.filter(function(Dr){return Dr.metadata.type!=="Dataset"&&(isUndefined(Dr.metadata.category)||tr.length===0||tr.includes(Dr.metadata.category))}).map(function(Dr){return{label:Dr.metadata.displayName,value:Dr.metadata.name,metadata:Dr.metadata}});return Pn({},Q,{type:"string",title:Pe,required:Pt,enum:Sr,"x-decorator":"FormItem","x-component":"Select","x-component-props":{placeholder:"\u8BF7\u9009\u62E9\u670D\u52A1"},"x-decorator-props":{tooltip:"\u8BF7\u9009\u62E9\u5173\u8054\u7684\u670D\u52A1\u8D44\u4EA7"}})},Zi=typeof window=="undefined"||"Deno"in window;function ho(){}function Na(Z,z){return typeof Z=="function"?Z(z):Z}function mn(Z){return typeof Z=="number"&&Z>=0&&Z!==1/0}function Lr(Z,z){return Math.max(Z+(z||0)-Date.now(),0)}function yr(Z,z){const{type:Q="all",exact:Pe,fetchStatus:Pt,predicate:tr,queryKey:Sr,stale:Dr}=Z;if(Sr){if(Pe){if(z.queryHash!==Zr(Sr,z.options))return!1}else if(!In(z.queryKey,Sr))return!1}if(Q!=="all"){const Kr=z.isActive();if(Q==="active"&&!Kr||Q==="inactive"&&Kr)return!1}return!(typeof Dr=="boolean"&&z.isStale()!==Dr||typeof Pt!="undefined"&&Pt!==z.state.fetchStatus||tr&&!tr(z))}function Mr(Z,z){const{exact:Q,status:Pe,predicate:Pt,mutationKey:tr}=Z;if(tr){if(!z.options.mutationKey)return!1;if(Q){if(Vn(z.options.mutationKey)!==Vn(tr))return!1}else if(!In(z.options.mutationKey,tr))return!1}return!(Pe&&z.state.status!==Pe||Pt&&!Pt(z))}function Zr(Z,z){return((z==null?void 0:z.queryKeyHashFn)||Vn)(Z)}function Vn(Z){return JSON.stringify(Z,(z,Q)=>ro(Q)?Object.keys(Q).sort().reduce((Pe,Pt)=>(Pe[Pt]=Q[Pt],Pe),{}):Q)}function In(Z,z){return Z===z?!0:typeof Z!=typeof z?!1:Z&&z&&typeof Z=="object"&&typeof z=="object"?!Object.keys(z).some(Q=>!In(Z[Q],z[Q])):!1}function Kn(Z,z){if(Z===z)return Z;const Q=so(Z)&&so(z);if(Q||ro(Z)&&ro(z)){const Pe=Q?Z:Object.keys(Z),Pt=Pe.length,tr=Q?z:Object.keys(z),Sr=tr.length,Dr=Q?[]:{};let Kr=0;for(let Zn=0;Zn{setTimeout(z,Z)})}function gs(Z,z,Q){return typeof Q.structuralSharing=="function"?Q.structuralSharing(Z,z):Q.structuralSharing!==!1?Kn(Z,z):z}function lo(Z){return Z}function No(Z,z,Q=0){const Pe=[...Z,z];return Q&&Pe.length>Q?Pe.slice(1):Pe}function Da(Z,z,Q=0){const Pe=[z,...Z];return Q&&Pe.length>Q?Pe.slice(0,-1):Pe}function ta(){let Z=[],z=0,Q=za=>{za()},Pe=za=>{za()},Pt=za=>setTimeout(za,0);const tr=za=>{Pt=za},Sr=za=>{let ua;z++;try{ua=za()}finally{z--,z||Zn()}return ua},Dr=za=>{z?Z.push(za):Pt(()=>{Q(za)})},Kr=za=>(...ua)=>{Dr(()=>{za(...ua)})},Zn=()=>{const za=Z;Z=[],za.length&&Pt(()=>{Pe(()=>{za.forEach(ua=>{Q(ua)})})})};return{batch:Sr,batchCalls:Kr,schedule:Dr,setNotifyFunction:za=>{Q=za},setBatchNotifyFunction:za=>{Pe=za},setScheduler:tr}}var Ra=ta(),ns=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(Z){return this.listeners.add(Z),this.onSubscribe(),()=>{this.listeners.delete(Z),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Vo=(Ed=class extends ns{constructor(){super();Sh(this,Bd,void 0);Sh(this,Qd,void 0);Sh(this,Jd,void 0);Rf(this,Jd,z=>{if(!Zi&&window.addEventListener){const Q=()=>z();return window.addEventListener("visibilitychange",Q,!1),()=>{window.removeEventListener("visibilitychange",Q)}}})}onSubscribe(){ra(this,Qd)||this.setEventListener(ra(this,Jd))}onUnsubscribe(){var z;this.hasListeners()||((z=ra(this,Qd))==null||z.call(this),Rf(this,Qd,void 0))}setEventListener(z){var Q;Rf(this,Jd,z),(Q=ra(this,Qd))==null||Q.call(this),Rf(this,Qd,z(Pe=>{typeof Pe=="boolean"?this.setFocused(Pe):this.onFocus()}))}setFocused(z){ra(this,Bd)!==z&&(Rf(this,Bd,z),this.onFocus())}onFocus(){this.listeners.forEach(z=>{z()})}isFocused(){var z;return typeof ra(this,Bd)=="boolean"?ra(this,Bd):((z=globalThis.document)==null?void 0:z.visibilityState)!=="hidden"}},Bd=new WeakMap,Qd=new WeakMap,Jd=new WeakMap,Ed),bs=new Vo,Js=(s=class extends ns{constructor(){super();Sh(this,_p,!0);Sh(this,oe,void 0);Sh(this,o,void 0);Rf(this,o,z=>{if(!Zi&&window.addEventListener){const Q=()=>z(!0),Pe=()=>z(!1);return window.addEventListener("online",Q,!1),window.addEventListener("offline",Pe,!1),()=>{window.removeEventListener("online",Q),window.removeEventListener("offline",Pe)}}})}onSubscribe(){ra(this,oe)||this.setEventListener(ra(this,o))}onUnsubscribe(){var z;this.hasListeners()||((z=ra(this,oe))==null||z.call(this),Rf(this,oe,void 0))}setEventListener(z){var Q;Rf(this,o,z),(Q=ra(this,oe))==null||Q.call(this),Rf(this,oe,z(this.setOnline.bind(this)))}setOnline(z){ra(this,_p)!==z&&(Rf(this,_p,z),this.listeners.forEach(Pe=>{Pe(z)}))}isOnline(){return ra(this,_p)}},_p=new WeakMap,oe=new WeakMap,o=new WeakMap,s),Hu=new Js;function Of(Z){return Math.min(1e3*hm(2,Z),3e4)}function en(Z){return(Z!=null?Z:"online")==="online"?Hu.isOnline():!0}var xn=class{constructor(Z){this.revert=Z==null?void 0:Z.revert,this.silent=Z==null?void 0:Z.silent}};function Vi(Z){return Z instanceof xn}function wi(Z){let z=!1,Q=0,Pe=!1,Pt,tr,Sr;const Dr=new Promise((os,Ua)=>{tr=os,Sr=Ua}),Kr=os=>{var Ua;Pe||(ua(new xn(os)),(Ua=Z.abort)==null||Ua.call(Z))},Zn=()=>{z=!0},ai=()=>{z=!1},Va=()=>!bs.isFocused()||Z.networkMode!=="always"&&!Hu.isOnline(),za=os=>{var Ua;Pe||(Pe=!0,(Ua=Z.onSuccess)==null||Ua.call(Z,os),Pt==null||Pt(),tr(os))},ua=os=>{var Ua;Pe||(Pe=!0,(Ua=Z.onError)==null||Ua.call(Z,os),Pt==null||Pt(),Sr(os))},Za=()=>new Promise(os=>{var Ua;Pt=us=>{const Xu=Pe||!Va();return Xu&&os(us),Xu},(Ua=Z.onPause)==null||Ua.call(Z)}).then(()=>{var os;Pt=void 0,Pe||(os=Z.onContinue)==null||os.call(Z)}),rs=()=>{if(Pe)return;let os;try{os=Z.fn()}catch(Ua){os=Promise.reject(Ua)}Promise.resolve(os).then(za).catch(Ua=>{var ah,gf,sh;if(Pe)return;const us=(ah=Z.retry)!=null?ah:Zi?0:3,Xu=(gf=Z.retryDelay)!=null?gf:Of,_u=typeof Xu=="function"?Xu(Q,Ua):Xu,Uc=us===!0||typeof us=="number"&&Q{if(Va())return Za()}).then(()=>{z?ua(Ua):rs()})})};return en(Z.networkMode)?rs():Za().then(rs),{promise:Dr,cancel:Kr,continue:()=>(Pt==null?void 0:Pt())?Dr:Promise.resolve(),cancelRetry:Zn,continueRetry:ai}}var oo=(g=class{constructor(){Sh(this,l,void 0)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),mn(this.gcTime)&&Rf(this,l,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(Z){this.gcTime=Math.max(this.gcTime||0,Z!=null?Z:Zi?1/0:5*60*1e3)}clearGcTimeout(){ra(this,l)&&(clearTimeout(ra(this,l)),Rf(this,l,void 0))}},l=new WeakMap,g),io=(Xr=class extends oo{constructor(z){super();Sh(this,lr);Sh(this,Vr);Sh(this,M,void 0);Sh(this,j,void 0);Sh(this,J,void 0);Sh(this,ve,void 0);Sh(this,ze,void 0);Sh(this,lt,void 0);Sh(this,Dt,void 0);Sh(this,$t,void 0);Rf(this,$t,!1),Rf(this,Dt,z.defaultOptions),gp(this,lr,z2).call(this,z.options),Rf(this,lt,[]),Rf(this,J,z.cache),this.queryKey=z.queryKey,this.queryHash=z.queryHash,Rf(this,M,z.state||Uo(this.options)),this.state=ra(this,M),this.scheduleGc()}get meta(){return this.options.meta}optionalRemove(){!ra(this,lt).length&&this.state.fetchStatus==="idle"&&ra(this,J).remove(this)}setData(z,Q){const Pe=gs(this.state.data,z,this.options);return gp(this,Vr,qg).call(this,{data:Pe,type:"success",dataUpdatedAt:Q==null?void 0:Q.updatedAt,manual:Q==null?void 0:Q.manual}),Pe}setState(z,Q){gp(this,Vr,qg).call(this,{type:"setState",state:z,setStateOptions:Q})}cancel(z){var Pe;const Q=ra(this,ve);return(Pe=ra(this,ze))==null||Pe.cancel(z),Q?Q.then(ho).catch(ho):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(ra(this,M))}isActive(){return ra(this,lt).some(z=>z.options.enabled!==!1)}isDisabled(){return this.getObserversCount()>0&&!this.isActive()}isStale(){return this.state.isInvalidated||!this.state.dataUpdatedAt||ra(this,lt).some(z=>z.getCurrentResult().isStale)}isStaleByTime(z=0){return this.state.isInvalidated||!this.state.dataUpdatedAt||!Lr(this.state.dataUpdatedAt,z)}onFocus(){var Q;const z=ra(this,lt).find(Pe=>Pe.shouldFetchOnWindowFocus());z==null||z.refetch({cancelRefetch:!1}),(Q=ra(this,ze))==null||Q.continue()}onOnline(){var Q;const z=ra(this,lt).find(Pe=>Pe.shouldFetchOnReconnect());z==null||z.refetch({cancelRefetch:!1}),(Q=ra(this,ze))==null||Q.continue()}addObserver(z){ra(this,lt).includes(z)||(ra(this,lt).push(z),this.clearGcTimeout(),ra(this,J).notify({type:"observerAdded",query:this,observer:z}))}removeObserver(z){ra(this,lt).includes(z)&&(Rf(this,lt,ra(this,lt).filter(Q=>Q!==z)),ra(this,lt).length||(ra(this,ze)&&(ra(this,$t)?ra(this,ze).cancel({revert:!0}):ra(this,ze).cancelRetry()),this.scheduleGc()),ra(this,J).notify({type:"observerRemoved",query:this,observer:z}))}getObserversCount(){return ra(this,lt).length}invalidate(){this.state.isInvalidated||gp(this,Vr,qg).call(this,{type:"invalidate"})}fetch(z,Q){var Zn,ai,Va,za;if(this.state.fetchStatus!=="idle"){if(this.state.dataUpdatedAt&&(Q!=null&&Q.cancelRefetch))this.cancel({silent:!0});else if(ra(this,ve))return(Zn=ra(this,ze))==null||Zn.continueRetry(),ra(this,ve)}if(z&&gp(this,lr,z2).call(this,z),!this.options.queryFn){const ua=ra(this,lt).find(Za=>Za.options.queryFn);ua&&gp(this,lr,z2).call(this,ua.options)}const Pe=new AbortController,Pt={queryKey:this.queryKey,meta:this.meta},tr=ua=>{Object.defineProperty(ua,"signal",{enumerable:!0,get:()=>(Rf(this,$t,!0),Pe.signal)})};tr(Pt);const Sr=()=>this.options.queryFn?(Rf(this,$t,!1),this.options.persister?this.options.persister(this.options.queryFn,Pt,this):this.options.queryFn(Pt)):Promise.reject(new Error(`Missing queryFn: '${this.options.queryHash}'`)),Dr={fetchOptions:Q,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:Sr};tr(Dr),(ai=this.options.behavior)==null||ai.onFetch(Dr,this),Rf(this,j,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((Va=Dr.fetchOptions)==null?void 0:Va.meta))&&gp(this,Vr,qg).call(this,{type:"fetch",meta:(za=Dr.fetchOptions)==null?void 0:za.meta});const Kr=ua=>{var Za,rs,os,Ua;Vi(ua)&&ua.silent||gp(this,Vr,qg).call(this,{type:"error",error:ua}),Vi(ua)||((rs=(Za=ra(this,J).config).onError)==null||rs.call(Za,ua,this),(Ua=(os=ra(this,J).config).onSettled)==null||Ua.call(os,this.state.data,ua,this)),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1};return Rf(this,ze,wi({fn:Dr.fetchFn,abort:Pe.abort.bind(Pe),onSuccess:ua=>{var Za,rs,os,Ua;if(typeof ua=="undefined"){Kr(new Error(`${this.queryHash} data is undefined`));return}this.setData(ua),(rs=(Za=ra(this,J).config).onSuccess)==null||rs.call(Za,ua,this),(Ua=(os=ra(this,J).config).onSettled)==null||Ua.call(os,ua,this.state.error,this),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1},onError:Kr,onFail:(ua,Za)=>{gp(this,Vr,qg).call(this,{type:"failed",failureCount:ua,error:Za})},onPause:()=>{gp(this,Vr,qg).call(this,{type:"pause"})},onContinue:()=>{gp(this,Vr,qg).call(this,{type:"continue"})},retry:Dr.options.retry,retryDelay:Dr.options.retryDelay,networkMode:Dr.options.networkMode})),Rf(this,ve,ra(this,ze).promise),ra(this,ve)}},M=new WeakMap,j=new WeakMap,J=new WeakMap,ve=new WeakMap,ze=new WeakMap,lt=new WeakMap,Dt=new WeakMap,$t=new WeakMap,lr=new WeakSet,z2=function(z){this.options=bd(bd({},ra(this,Dt)),z),this.updateGcTime(this.options.gcTime)},Vr=new WeakSet,qg=function(z){const Q=Pe=>{var Pt,tr;switch(z.type){case"failed":return dm(bd({},Pe),{fetchFailureCount:z.failureCount,fetchFailureReason:z.error});case"pause":return dm(bd({},Pe),{fetchStatus:"paused"});case"continue":return dm(bd({},Pe),{fetchStatus:"fetching"});case"fetch":return bd(dm(bd({},Pe),{fetchFailureCount:0,fetchFailureReason:null,fetchMeta:(Pt=z.meta)!=null?Pt:null,fetchStatus:en(this.options.networkMode)?"fetching":"paused"}),!Pe.dataUpdatedAt&&{error:null,status:"pending"});case"success":return bd(dm(bd({},Pe),{data:z.data,dataUpdateCount:Pe.dataUpdateCount+1,dataUpdatedAt:(tr=z.dataUpdatedAt)!=null?tr:Date.now(),error:null,isInvalidated:!1,status:"success"}),!z.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null});case"error":const Sr=z.error;return Vi(Sr)&&Sr.revert&&ra(this,j)?dm(bd({},ra(this,j)),{fetchStatus:"idle"}):dm(bd({},Pe),{error:Sr,errorUpdateCount:Pe.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:Pe.fetchFailureCount+1,fetchFailureReason:Sr,fetchStatus:"idle",status:"error"});case"invalidate":return dm(bd({},Pe),{isInvalidated:!0});case"setState":return bd(bd({},Pe),z.state)}};this.state=Q(this.state),Ra.batch(()=>{ra(this,lt).forEach(Pe=>{Pe.onQueryUpdate()}),ra(this,J).notify({query:this,type:"updated",action:z})})},Xr);function Uo(Z){const z=typeof Z.initialData=="function"?Z.initialData():Z.initialData,Q=typeof z!="undefined",Pe=Q?typeof Z.initialDataUpdatedAt=="function"?Z.initialDataUpdatedAt():Z.initialDataUpdatedAt:0;return{data:z,dataUpdateCount:0,dataUpdatedAt:Q?Pe!=null?Pe:Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:Q?"success":"pending",fetchStatus:"idle"}}var na=(Br=class extends ns{constructor(z={}){super();Sh(this,Gr,void 0);this.config=z,Rf(this,Gr,new Map)}build(z,Q,Pe){var Dr;const Pt=Q.queryKey,tr=(Dr=Q.queryHash)!=null?Dr:Zr(Pt,Q);let Sr=this.get(tr);return Sr||(Sr=new io({cache:this,queryKey:Pt,queryHash:tr,options:z.defaultQueryOptions(Q),state:Pe,defaultOptions:z.getQueryDefaults(Pt)}),this.add(Sr)),Sr}add(z){ra(this,Gr).has(z.queryHash)||(ra(this,Gr).set(z.queryHash,z),this.notify({type:"added",query:z}))}remove(z){const Q=ra(this,Gr).get(z.queryHash);Q&&(z.destroy(),Q===z&&ra(this,Gr).delete(z.queryHash),this.notify({type:"removed",query:z}))}clear(){Ra.batch(()=>{this.getAll().forEach(z=>{this.remove(z)})})}get(z){return ra(this,Gr).get(z)}getAll(){return[...ra(this,Gr).values()]}find(z){const Q=bd({exact:!0},z);return this.getAll().find(Pe=>yr(Q,Pe))}findAll(z={}){const Q=this.getAll();return Object.keys(z).length>0?Q.filter(Pe=>yr(z,Pe)):Q}notify(z){Ra.batch(()=>{this.listeners.forEach(Q=>{Q(z)})})}onFocus(){Ra.batch(()=>{this.getAll().forEach(z=>{z.onFocus()})})}onOnline(){Ra.batch(()=>{this.getAll().forEach(z=>{z.onOnline()})})}},Gr=new WeakMap,Br),$a=(ys=class extends oo{constructor(z){super();Sh(this,Eo);Sh(this,Tn,void 0);Sh(this,Hn,void 0);Sh(this,yi,void 0);Sh(this,vo,void 0);this.mutationId=z.mutationId,Rf(this,Hn,z.defaultOptions),Rf(this,yi,z.mutationCache),Rf(this,Tn,[]),this.state=z.state||Co(),this.setOptions(z.options),this.scheduleGc()}setOptions(z){this.options=bd(bd({},ra(this,Hn)),z),this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(z){ra(this,Tn).includes(z)||(ra(this,Tn).push(z),this.clearGcTimeout(),ra(this,yi).notify({type:"observerAdded",mutation:this,observer:z}))}removeObserver(z){Rf(this,Tn,ra(this,Tn).filter(Q=>Q!==z)),this.scheduleGc(),ra(this,yi).notify({type:"observerRemoved",mutation:this,observer:z})}optionalRemove(){ra(this,Tn).length||(this.state.status==="pending"?this.scheduleGc():ra(this,yi).remove(this))}continue(){var z,Q;return(Q=(z=ra(this,vo))==null?void 0:z.continue())!=null?Q:this.execute(this.state.variables)}execute(z){return m_(this,null,function*(){var Pt,tr,Sr,Dr,Kr,Zn,ai,Va,za,ua,Za,rs,os,Ua,us,Xu,_u,Uc,ah,gf;const Q=()=>{var sh;return Rf(this,vo,wi({fn:()=>this.options.mutationFn?this.options.mutationFn(z):Promise.reject(new Error("No mutationFn found")),onFail:(sp,Ld)=>{gp(this,Eo,Ry).call(this,{type:"failed",failureCount:sp,error:Ld})},onPause:()=>{gp(this,Eo,Ry).call(this,{type:"pause"})},onContinue:()=>{gp(this,Eo,Ry).call(this,{type:"continue"})},retry:(sh=this.options.retry)!=null?sh:0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode})),ra(this,vo).promise},Pe=this.state.status==="pending";try{if(!Pe){gp(this,Eo,Ry).call(this,{type:"pending",variables:z}),yield(tr=(Pt=ra(this,yi).config).onMutate)==null?void 0:tr.call(Pt,z,this);const sp=yield(Dr=(Sr=this.options).onMutate)==null?void 0:Dr.call(Sr,z);sp!==this.state.context&&gp(this,Eo,Ry).call(this,{type:"pending",context:sp,variables:z})}const sh=yield Q();return yield(Zn=(Kr=ra(this,yi).config).onSuccess)==null?void 0:Zn.call(Kr,sh,z,this.state.context,this),yield(Va=(ai=this.options).onSuccess)==null?void 0:Va.call(ai,sh,z,this.state.context),yield(ua=(za=ra(this,yi).config).onSettled)==null?void 0:ua.call(za,sh,null,this.state.variables,this.state.context,this),yield(rs=(Za=this.options).onSettled)==null?void 0:rs.call(Za,sh,null,z,this.state.context),gp(this,Eo,Ry).call(this,{type:"success",data:sh}),sh}catch(sh){try{throw yield(Ua=(os=ra(this,yi).config).onError)==null?void 0:Ua.call(os,sh,z,this.state.context,this),yield(Xu=(us=this.options).onError)==null?void 0:Xu.call(us,sh,z,this.state.context),yield(Uc=(_u=ra(this,yi).config).onSettled)==null?void 0:Uc.call(_u,void 0,sh,this.state.variables,this.state.context,this),yield(gf=(ah=this.options).onSettled)==null?void 0:gf.call(ah,void 0,sh,z,this.state.context),sh}finally{gp(this,Eo,Ry).call(this,{type:"error",error:sh})}}})}},Tn=new WeakMap,Hn=new WeakMap,yi=new WeakMap,vo=new WeakMap,Eo=new WeakSet,Ry=function(z){const Q=Pe=>{switch(z.type){case"failed":return dm(bd({},Pe),{failureCount:z.failureCount,failureReason:z.error});case"pause":return dm(bd({},Pe),{isPaused:!0});case"continue":return dm(bd({},Pe),{isPaused:!1});case"pending":return dm(bd({},Pe),{context:z.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:!en(this.options.networkMode),status:"pending",variables:z.variables,submittedAt:Date.now()});case"success":return dm(bd({},Pe),{data:z.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1});case"error":return dm(bd({},Pe),{data:void 0,error:z.error,failureCount:Pe.failureCount+1,failureReason:z.error,isPaused:!1,status:"error"})}};this.state=Q(this.state),Ra.batch(()=>{ra(this,Tn).forEach(Pe=>{Pe.onMutationUpdate(z)}),ra(this,yi).notify({mutation:this,type:"updated",action:z})})},ys);function Co(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var wo=(Ts=class extends ns{constructor(z={}){super();Sh(this,Yo,void 0);Sh(this,es,void 0);Sh(this,qa,void 0);this.config=z,Rf(this,Yo,[]),Rf(this,es,0)}build(z,Q,Pe){const Pt=new $a({mutationCache:this,mutationId:++N2(this,es)._,options:z.defaultMutationOptions(Q),state:Pe});return this.add(Pt),Pt}add(z){ra(this,Yo).push(z),this.notify({type:"added",mutation:z})}remove(z){Rf(this,Yo,ra(this,Yo).filter(Q=>Q!==z)),this.notify({type:"removed",mutation:z})}clear(){Ra.batch(()=>{ra(this,Yo).forEach(z=>{this.remove(z)})})}getAll(){return ra(this,Yo)}find(z){const Q=bd({exact:!0},z);return ra(this,Yo).find(Pe=>Mr(Q,Pe))}findAll(z={}){return ra(this,Yo).filter(Q=>Mr(z,Q))}notify(z){Ra.batch(()=>{this.listeners.forEach(Q=>{Q(z)})})}resumePausedMutations(){var z;return Rf(this,qa,((z=ra(this,qa))!=null?z:Promise.resolve()).then(()=>{const Q=ra(this,Yo).filter(Pe=>Pe.state.isPaused);return Ra.batch(()=>Q.reduce((Pe,Pt)=>Pe.then(()=>Pt.continue().catch(ho)),Promise.resolve()))}).then(()=>{Rf(this,qa,void 0)})),ra(this,qa)}},Yo=new WeakMap,es=new WeakMap,qa=new WeakMap,Ts);function Pa(Z){return{onFetch:(z,Q)=>{const Pe=()=>m_(this,null,function*(){var Za,rs,os,Ua,us,Xu;const Pt=z.options,tr=(os=(rs=(Za=z.fetchOptions)==null?void 0:Za.meta)==null?void 0:rs.fetchMore)==null?void 0:os.direction,Sr=((Ua=z.state.data)==null?void 0:Ua.pages)||[],Dr=((us=z.state.data)==null?void 0:us.pageParams)||[],Kr={pages:[],pageParams:[]};let Zn=!1;const ai=_u=>{Object.defineProperty(_u,"signal",{enumerable:!0,get:()=>(z.signal.aborted?Zn=!0:z.signal.addEventListener("abort",()=>{Zn=!0}),z.signal)})},Va=z.options.queryFn||(()=>Promise.reject(new Error(`Missing queryFn: '${z.options.queryHash}'`))),za=(_u,Uc,ah)=>m_(this,null,function*(){if(Zn)return Promise.reject();if(Uc==null&&_u.pages.length)return Promise.resolve(_u);const gf={queryKey:z.queryKey,pageParam:Uc,direction:ah?"backward":"forward",meta:z.options.meta};ai(gf);const sh=yield Va(gf),{maxPages:sp}=z.options,Ld=ah?Da:No;return{pages:Ld(_u.pages,sh,sp),pageParams:Ld(_u.pageParams,Uc,sp)}});let ua;if(tr&&Sr.length){const _u=tr==="backward",Uc=_u?si:ss,ah={pages:Sr,pageParams:Dr},gf=Uc(Pt,ah);ua=yield za(ah,gf,_u)}else{ua=yield za(Kr,(Xu=Dr[0])!=null?Xu:Pt.initialPageParam);const _u=Z!=null?Z:Sr.length;for(let Uc=1;Uc<_u;Uc++){const ah=ss(Pt,ua);ua=yield za(ua,ah)}}return ua});z.options.persister?z.fetchFn=()=>{var Pt,tr;return(tr=(Pt=z.options).persister)==null?void 0:tr.call(Pt,Pe,{queryKey:z.queryKey,meta:z.options.meta,signal:z.signal},Q)}:z.fetchFn=Pe}}}function ss(Z,{pages:z,pageParams:Q}){const Pe=z.length-1;return Z.getNextPageParam(z[Pe],z,Q[Pe],Q)}function si(Z,{pages:z,pageParams:Q}){var Pe;return(Pe=Z.getPreviousPageParam)==null?void 0:Pe.call(Z,z[0],z,Q[0],Q)}function Ms(Z,z){return z?ss(Z,z)!=null:!1}function Ns(Z,z){return!z||!Z.getPreviousPageParam?!1:si(Z,z)!=null}var Aa=(Bf=class{constructor(Z={}){Sh(this,is,void 0);Sh(this,ts,void 0);Sh(this,Rs,void 0);Sh(this,pu,void 0);Sh(this,nl,void 0);Sh(this,la,void 0);Sh(this,Es,void 0);Sh(this,sl,void 0);Rf(this,is,Z.queryCache||new na),Rf(this,ts,Z.mutationCache||new wo),Rf(this,Rs,Z.defaultOptions||{}),Rf(this,pu,new Map),Rf(this,nl,new Map),Rf(this,la,0)}mount(){N2(this,la)._++,ra(this,la)===1&&(Rf(this,Es,bs.subscribe(()=>{bs.isFocused()&&(this.resumePausedMutations(),ra(this,is).onFocus())})),Rf(this,sl,Hu.subscribe(()=>{Hu.isOnline()&&(this.resumePausedMutations(),ra(this,is).onOnline())})))}unmount(){var Z,z;N2(this,la)._--,ra(this,la)===0&&((Z=ra(this,Es))==null||Z.call(this),Rf(this,Es,void 0),(z=ra(this,sl))==null||z.call(this),Rf(this,sl,void 0))}isFetching(Z){return ra(this,is).findAll(dm(bd({},Z),{fetchStatus:"fetching"})).length}isMutating(Z){return ra(this,ts).findAll(dm(bd({},Z),{status:"pending"})).length}getQueryData(Z){var z;return(z=ra(this,is).find({queryKey:Z}))==null?void 0:z.state.data}ensureQueryData(Z){const z=this.getQueryData(Z.queryKey);return z!==void 0?Promise.resolve(z):this.fetchQuery(Z)}getQueriesData(Z){return this.getQueryCache().findAll(Z).map(({queryKey:z,state:Q})=>{const Pe=Q.data;return[z,Pe]})}setQueryData(Z,z,Q){const Pe=ra(this,is).find({queryKey:Z}),Pt=Pe==null?void 0:Pe.state.data,tr=Na(z,Pt);if(typeof tr=="undefined")return;const Sr=this.defaultQueryOptions({queryKey:Z});return ra(this,is).build(this,Sr).setData(tr,dm(bd({},Q),{manual:!0}))}setQueriesData(Z,z,Q){return Ra.batch(()=>this.getQueryCache().findAll(Z).map(({queryKey:Pe})=>[Pe,this.setQueryData(Pe,z,Q)]))}getQueryState(Z){var z;return(z=ra(this,is).find({queryKey:Z}))==null?void 0:z.state}removeQueries(Z){const z=ra(this,is);Ra.batch(()=>{z.findAll(Z).forEach(Q=>{z.remove(Q)})})}resetQueries(Z,z){const Q=ra(this,is),Pe=bd({type:"active"},Z);return Ra.batch(()=>(Q.findAll(Z).forEach(Pt=>{Pt.reset()}),this.refetchQueries(Pe,z)))}cancelQueries(Z={},z={}){const Q=bd({revert:!0},z),Pe=Ra.batch(()=>ra(this,is).findAll(Z).map(Pt=>Pt.cancel(Q)));return Promise.all(Pe).then(ho).catch(ho)}invalidateQueries(Z={},z={}){return Ra.batch(()=>{var Pe,Pt;if(ra(this,is).findAll(Z).forEach(tr=>{tr.invalidate()}),Z.refetchType==="none")return Promise.resolve();const Q=dm(bd({},Z),{type:(Pt=(Pe=Z.refetchType)!=null?Pe:Z.type)!=null?Pt:"active"});return this.refetchQueries(Q,z)})}refetchQueries(Z={},z){var Pt;const Q=dm(bd({},z),{cancelRefetch:(Pt=z==null?void 0:z.cancelRefetch)!=null?Pt:!0}),Pe=Ra.batch(()=>ra(this,is).findAll(Z).filter(tr=>!tr.isDisabled()).map(tr=>{let Sr=tr.fetch(void 0,Q);return Q.throwOnError||(Sr=Sr.catch(ho)),tr.state.fetchStatus==="paused"?Promise.resolve():Sr}));return Promise.all(Pe).then(ho)}fetchQuery(Z){const z=this.defaultQueryOptions(Z);typeof z.retry=="undefined"&&(z.retry=!1);const Q=ra(this,is).build(this,z);return Q.isStaleByTime(z.staleTime)?Q.fetch(z):Promise.resolve(Q.state.data)}prefetchQuery(Z){return this.fetchQuery(Z).then(ho).catch(ho)}fetchInfiniteQuery(Z){return Z.behavior=Pa(Z.pages),this.fetchQuery(Z)}prefetchInfiniteQuery(Z){return this.fetchInfiniteQuery(Z).then(ho).catch(ho)}resumePausedMutations(){return ra(this,ts).resumePausedMutations()}getQueryCache(){return ra(this,is)}getMutationCache(){return ra(this,ts)}getDefaultOptions(){return ra(this,Rs)}setDefaultOptions(Z){Rf(this,Rs,Z)}setQueryDefaults(Z,z){ra(this,pu).set(Vn(Z),{queryKey:Z,defaultOptions:z})}getQueryDefaults(Z){const z=[...ra(this,pu).values()];let Q={};return z.forEach(Pe=>{In(Z,Pe.queryKey)&&(Q=bd(bd({},Q),Pe.defaultOptions))}),Q}setMutationDefaults(Z,z){ra(this,nl).set(Vn(Z),{mutationKey:Z,defaultOptions:z})}getMutationDefaults(Z){const z=[...ra(this,nl).values()];let Q={};return z.forEach(Pe=>{In(Z,Pe.mutationKey)&&(Q=bd(bd({},Q),Pe.defaultOptions))}),Q}defaultQueryOptions(Z){if(Z!=null&&Z._defaulted)return Z;const z=dm(bd(bd(bd({},ra(this,Rs).queries),(Z==null?void 0:Z.queryKey)&&this.getQueryDefaults(Z.queryKey)),Z),{_defaulted:!0});return z.queryHash||(z.queryHash=Zr(z.queryKey,z)),typeof z.refetchOnReconnect=="undefined"&&(z.refetchOnReconnect=z.networkMode!=="always"),typeof z.throwOnError=="undefined"&&(z.throwOnError=!!z.suspense),typeof z.networkMode=="undefined"&&z.persister&&(z.networkMode="offlineFirst"),z}defaultMutationOptions(Z){return Z!=null&&Z._defaulted?Z:dm(bd(bd(bd({},ra(this,Rs).mutations),(Z==null?void 0:Z.mutationKey)&&this.getMutationDefaults(Z.mutationKey)),Z),{_defaulted:!0})}clear(){ra(this,is).clear(),ra(this,ts).clear()}},is=new WeakMap,ts=new WeakMap,Rs=new WeakMap,pu=new WeakMap,nl=new WeakMap,la=new WeakMap,Es=new WeakMap,sl=new WeakMap,Bf);function qs(Z){"@babel/helpers - typeof";return qs=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(z){return typeof z}:function(z){return z&&typeof Symbol=="function"&&z.constructor===Symbol&&z!==Symbol.prototype?"symbol":typeof z},qs(Z)}function Eu(Z,z){if(!(Z instanceof z))throw new TypeError("Cannot call a class as a function")}function Cs(Z,z){for(var Q=0;Q=Z.length?{done:!0}:{done:!1,value:Z[Pe++]}},e:function(Zn){throw Zn},f:Pt}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var tr=!0,Sr=!1,Dr;return{s:function(){Q=Q.call(Z)},n:function(){var Zn=Q.next();return tr=Zn.done,Zn},e:function(Zn){Sr=!0,Dr=Zn},f:function(){try{!tr&&Q.return!=null&&Q.return()}finally{if(Sr)throw Dr}}}}function Zs(Z,z){if(Z){if(typeof Z=="string")return yu(Z,z);var Q=Object.prototype.toString.call(Z).slice(8,-1);if(Q==="Object"&&Z.constructor&&(Q=Z.constructor.name),Q==="Map"||Q==="Set")return Array.from(Z);if(Q==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Q))return yu(Z,z)}}function yu(Z,z){(z==null||z>Z.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);Q1&&arguments[1]!==void 0?arguments[1]:ln.Z,Pe=(0,p.useRef)(),Pt=z();return(!Pe.current||!Q(Pe.current,Pt))&&(Pe.current=Pt),Pe.current};function Qo(Z){"@babel/helpers - typeof";return Qo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(z){return typeof z}:function(z){return z&&typeof Symbol=="function"&&z.constructor===Symbol&&z!==Symbol.prototype?"symbol":typeof z},Qo(Z)}function ps(Z,z){var Q=Object.keys(Z);if(Object.getOwnPropertySymbols){var Pe=Object.getOwnPropertySymbols(Z);z&&(Pe=Pe.filter(function(Pt){return Object.getOwnPropertyDescriptor(Z,Pt).enumerable})),Q.push.apply(Q,Pe)}return Q}function xl(Z){for(var z=1;zZ.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);Q=0;--ue){var Ue=this.tryEntries[ue],Ut=Ue.completion;if(Ue.tryLoc==="root")return ne("end");if(Ue.tryLoc<=this.prev){var vr=Pe.call(Ue,"catchLoc"),Cr=Pe.call(Ue,"finallyLoc");if(vr&&Cr){if(this.prev=0;--ne){var ue=this.tryEntries[ne];if(ue.tryLoc<=this.prev&&Pe.call(ue,"finallyLoc")&&this.prev=0;--K){var ne=this.tryEntries[K];if(ne.finallyLoc===Ws)return this.complete(ne.completion,ne.afterLoc),Ap(ne),os}},catch:function(Ws){for(var K=this.tryEntries.length-1;K>=0;--K){var ne=this.tryEntries[K];if(ne.tryLoc===Ws){var ue=ne.completion;if(ue.type==="throw"){var Ue=ue.arg;Ap(ne)}return Ue}}throw new Error("illegal catch attempt")},delegateYield:function(Ws,K,ne){return this.delegate={iterator:Mh(Ws),resultName:K,nextLoc:ne},this.method==="next"&&(this.arg=Z),os}},z}function cn(Z,z,Q,Pe,Pt,tr,Sr){try{var Dr=Z[tr](Sr),Kr=Dr.value}catch(Zn){Q(Zn);return}Dr.done?z(Kr):Promise.resolve(Kr).then(Pe,Pt)}function an(Z){return function(){var z=this,Q=arguments;return new Promise(function(Pe,Pt){var tr=Z.apply(z,Q);function Sr(Kr){cn(tr,Pe,Pt,Sr,Dr,"next",Kr)}function Dr(Kr){cn(tr,Pe,Pt,Sr,Dr,"throw",Kr)}Sr(void 0)})}}var Xn=function(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],Q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return hn(z,Q,function(Pe,Pt){return!!(Pe.data===Pt.data&&(0,ln.Z)(Pe.filter,Pt.filter))})},vi={id:"noop",type:"local",data:[],columns:[],metadata:{name:"noop"}},to=function(){return Promise.resolve([])},zo=function(){var Z=an(_l().mark(function z(Q){var Pe,Pt,tr,Sr;return _l().wrap(function(Kr){for(;;)switch(Kr.prev=Kr.next){case 0:if(Pe=Q.data,Pt=Q.filter,Pt){Kr.next=3;break}return Kr.abrupt("return",Pe);case 3:return Kr.prev=3,Kr.next=6,Ks(Pe,Pt);case 6:tr=Kr.sent,Kr.next=14;break;case 9:return Kr.prev=9,Kr.t0=Kr.catch(3),Sr=new Error("applyDatasetFilter is failure, filter data: '".concat(JSON.stringify(Pt),"'.")),console.error(Sr),Kr.abrupt("return",Pe);case 14:return Kr.abrupt("return",tr);case 15:case"end":return Kr.stop()}},z,null,[[3,9]])}));return function(Q){return Z.apply(this,arguments)}}();function Ia(Z,z){var Q=(0,p.useMemo)(function(){var Za=Z.columns||[],rs=z||Z.filter;return(0,oi.Z)(rs)?rs:hs(rs,Za)},[Z.filter,z,Z.columns]),Pe=eu(function(){return{data:Z.data,filter:Q}},Xn),Pt=(0,p.useState)(Pe),tr=sf(Pt,2),Sr=tr[0],Dr=tr[1];dr(function(){return Dr(Pe)},[Pe],{wait:1e3});var Kr=(0,p.useState)(),Zn=sf(Kr,2),ai=Zn[0],Va=Zn[1],za=Z.id===vi.id?to:zo;(0,p.useEffect)(function(){var Za=!1;return za(Sr).then(function(rs){Za||Va(rs)}).catch(function(rs){console.error(rs)}),function(){Za=!0}},[Sr]);var ua=(0,p.useMemo)(function(){return xl(xl({},Z),{},{data:(0,Nn.Z)(ai)?ai:[]})},[Z,ai]);return ua}function Sa(Z,z){return Is(Z)||mu(Z,z)||cs(Z,z)||fa()}function fa(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function cs(Z,z){if(Z){if(typeof Z=="string")return Ys(Z,z);var Q=Object.prototype.toString.call(Z).slice(8,-1);if(Q==="Object"&&Z.constructor&&(Q=Z.constructor.name),Q==="Map"||Q==="Set")return Array.from(Z);if(Q==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Q))return Ys(Z,z)}}function Ys(Z,z){(z==null||z>Z.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);Q{Object.defineProperty(Q,Pe,{configurable:!1,enumerable:!0,get:()=>(ra(this,Zc).add(Pe),z[Pe])})}),Q}getCurrentQuery(){return ra(this,oc)}refetch(Q={}){var z=NM(Q,[]);return this.fetch(bd({},z))}fetchOptimistic(z){const Q=ra(this,Vl).defaultQueryOptions(z),Pe=ra(this,Vl).getQueryCache().build(ra(this,Vl),Q);return Pe.isFetchingOptimistic=!0,Pe.fetch().then(()=>this.createResult(Pe,Q))}fetch(z){var Q;return gp(this,Lh,yA).call(this,dm(bd({},z),{cancelRefetch:(Q=z.cancelRefetch)!=null?Q:!0})).then(()=>(this.updateResult(),ra(this,xc)))}createResult(z,Q){var ah;const Pe=ra(this,oc),Pt=this.options,tr=ra(this,xc),Sr=ra(this,ih),Dr=ra(this,wh),Zn=z!==Pe?z.state:ra(this,zc),{state:ai}=z;let{error:Va,errorUpdatedAt:za,fetchStatus:ua,status:Za}=ai,rs=!1,os;if(Q._optimisticResults){const gf=this.hasListeners(),sh=!gf&&ll(z,Q),sp=gf&&Bu(z,Pe,Q,Pt);(sh||sp)&&(ua=en(z.options.networkMode)?"fetching":"paused",ai.dataUpdatedAt||(Za="pending")),Q._optimisticResults==="isRestoring"&&(ua="idle")}if(Q.select&&typeof ai.data!="undefined")if(tr&&ai.data===(Sr==null?void 0:Sr.data)&&Q.select===ra(this,dh))os=ra(this,Jf);else try{Rf(this,dh,Q.select),os=Q.select(ai.data),os=gs(tr==null?void 0:tr.data,os,Q),Rf(this,Jf,os),Rf(this,hh,null)}catch(gf){Rf(this,hh,gf)}else os=ai.data;if(typeof Q.placeholderData!="undefined"&&typeof os=="undefined"&&Za==="pending"){let gf;if(tr!=null&&tr.isPlaceholderData&&Q.placeholderData===(Dr==null?void 0:Dr.placeholderData))gf=tr.data;else if(gf=typeof Q.placeholderData=="function"?Q.placeholderData((ah=ra(this,pf))==null?void 0:ah.state.data,ra(this,pf)):Q.placeholderData,Q.select&&typeof gf!="undefined")try{gf=Q.select(gf),Rf(this,hh,null)}catch(sh){Rf(this,hh,sh)}typeof gf!="undefined"&&(Za="success",os=gs(tr==null?void 0:tr.data,gf,Q),rs=!0)}ra(this,hh)&&(Va=ra(this,hh),os=ra(this,Jf),za=Date.now(),Za="error");const Ua=ua==="fetching",us=Za==="pending",Xu=Za==="error",_u=us&&Ua;return{status:Za,fetchStatus:ua,isPending:us,isSuccess:Za==="success",isError:Xu,isInitialLoading:_u,isLoading:_u,data:os,dataUpdatedAt:ai.dataUpdatedAt,error:Va,errorUpdatedAt:za,failureCount:ai.fetchFailureCount,failureReason:ai.fetchFailureReason,errorUpdateCount:ai.errorUpdateCount,isFetched:ai.dataUpdateCount>0||ai.errorUpdateCount>0,isFetchedAfterMount:ai.dataUpdateCount>Zn.dataUpdateCount||ai.errorUpdateCount>Zn.errorUpdateCount,isFetching:Ua,isRefetching:Ua&&!us,isLoadingError:Xu&&ai.dataUpdatedAt===0,isPaused:ua==="paused",isPlaceholderData:rs,isRefetchError:Xu&&ai.dataUpdatedAt!==0,isStale:al(z,Q),refetch:this.refetch}}updateResult(z){const Q=ra(this,xc),Pe=this.createResult(ra(this,oc),this.options);if(Rf(this,ih,ra(this,oc).state),Rf(this,wh,this.options),ra(this,ih).data!==void 0&&Rf(this,pf,ra(this,oc)),Mi(Pe,Q))return;Rf(this,xc,Pe);const Pt={},tr=()=>{if(!Q)return!0;const{notifyOnChangeProps:Sr}=this.options,Dr=typeof Sr=="function"?Sr():Sr;if(Dr==="all"||!Dr&&!ra(this,Zc).size)return!0;const Kr=new Set(Dr!=null?Dr:ra(this,Zc));return this.options.throwOnError&&Kr.add("error"),Object.keys(ra(this,xc)).some(Zn=>{const ai=Zn;return ra(this,xc)[ai]!==Q[ai]&&Kr.has(ai)})};(z==null?void 0:z.listeners)!==!1&&tr()&&(Pt.listeners=!0),gp(this,Yt,zM).call(this,bd(bd({},Pt),z))}onQueryUpdate(){this.updateResult(),this.hasListeners()&&gp(this,d,aE).call(this)}},Vl=new WeakMap,oc=new WeakMap,zc=new WeakMap,xc=new WeakMap,ih=new WeakMap,wh=new WeakMap,hh=new WeakMap,dh=new WeakMap,Jf=new WeakMap,pf=new WeakMap,ec=new WeakMap,Jc=new WeakMap,zl=new WeakMap,Zc=new WeakMap,Lh=new WeakSet,yA=function(z){gp(this,ht,lE).call(this);let Q=ra(this,oc).fetch(this.options,z);return z!=null&&z.throwOnError||(Q=Q.catch(ho)),Q},pa=new WeakSet,nE=function(){if(gp(this,G,sE).call(this),Zi||ra(this,xc).isStale||!mn(this.options.staleTime))return;const Q=Lr(ra(this,xc).dataUpdatedAt,this.options.staleTime)+1;Rf(this,ec,setTimeout(()=>{ra(this,xc).isStale||this.updateResult()},Q))},Rc=new WeakSet,iE=function(){var z;return(z=typeof this.options.refetchInterval=="function"?this.options.refetchInterval(ra(this,oc)):this.options.refetchInterval)!=null?z:!1},oh=new WeakSet,oE=function(z){gp(this,Te,uE).call(this),Rf(this,zl,z),!(Zi||this.options.enabled===!1||!mn(ra(this,zl))||ra(this,zl)===0)&&Rf(this,Jc,setInterval(()=>{(this.options.refetchIntervalInBackground||bs.isFocused())&&gp(this,Lh,yA).call(this)},ra(this,zl)))},d=new WeakSet,aE=function(){gp(this,pa,nE).call(this),gp(this,oh,oE).call(this,gp(this,Rc,iE).call(this))},G=new WeakSet,sE=function(){ra(this,ec)&&(clearTimeout(ra(this,ec)),Rf(this,ec,void 0))},Te=new WeakSet,uE=function(){ra(this,Jc)&&(clearInterval(ra(this,Jc)),Rf(this,Jc,void 0))},ht=new WeakSet,lE=function(){const z=ra(this,Vl).getQueryCache().build(ra(this,Vl),this.options);if(z===ra(this,oc))return;const Q=ra(this,oc);Rf(this,oc,z),Rf(this,zc,z.state),this.hasListeners()&&(Q==null||Q.removeObserver(this),z.addObserver(this))},Yt=new WeakSet,zM=function(z){Ra.batch(()=>{z.listeners&&this.listeners.forEach(Q=>{Q(ra(this,xc))}),ra(this,Vl).getQueryCache().notify({query:ra(this,oc),type:"observerResultsUpdated"})})},Ir);function ml(Z,z){return z.enabled!==!1&&!Z.state.dataUpdatedAt&&!(Z.state.status==="error"&&z.retryOnMount===!1)}function ll(Z,z){return ml(Z,z)||Z.state.dataUpdatedAt>0&&Fu(Z,z,z.refetchOnMount)}function Fu(Z,z,Q){if(z.enabled!==!1){const Pe=typeof Q=="function"?Q(Z):Q;return Pe==="always"||Pe!==!1&&al(Z,z)}return!1}function Bu(Z,z,Q,Pe){return Q.enabled!==!1&&(Z!==z||Pe.enabled===!1)&&(!Q.suspense||Z.state.status!=="error")&&al(Z,Q)}function al(Z,z){return Z.isStaleByTime(z.staleTime)}function Ac(Z,z){return!Mi(Z.getCurrentResult(),z)}function $l(){let Z=!1;return{clearReset:()=>{Z=!1},reset:()=>{Z=!0},isReset:()=>Z}}var Yu=p.createContext($l()),Gu=()=>p.useContext(Yu),Sf=({children:Z})=>{const[z]=React.useState(()=>$l());return React.createElement(Yu.Provider,{value:z},typeof Z=="function"?Z(z):Z)},Cl=p.createContext(void 0),Df=Z=>{const z=p.useContext(Cl);if(Z)return Z;if(!z)throw new Error("No QueryClient set, use QueryClientProvider to set one");return z},bu=({client:Z,children:z})=>(React.useEffect(()=>(Z.mount(),()=>{Z.unmount()}),[Z]),React.createElement(Cl.Provider,{value:Z},z)),Ic=p.createContext(!1),af=()=>p.useContext(Ic),zf=Ic.Provider;function tf(Z,z){return typeof Z=="function"?Z(...z):!!Z}var kf=(Z,z)=>{(Z.suspense||Z.throwOnError)&&(z.isReset()||(Z.retryOnMount=!1))},ff=Z=>{p.useEffect(()=>{Z.clearReset()},[Z])},vf=({result:Z,errorResetBoundary:z,throwOnError:Q,query:Pe})=>Z.isError&&!z.isReset()&&!Z.isFetching&&Pe&&tf(Q,[Z.error,Pe]),wc=(Z,z)=>typeof z.state.data=="undefined",ac=Z=>{Z.suspense&&typeof Z.staleTime!="number"&&(Z.staleTime=1e3)},cl=(Z,z)=>Z.isLoading&&Z.isFetching&&!z,Us=(Z,z)=>(Z==null?void 0:Z.suspense)&&z.isPending,vl=(Z,z,Q)=>z.fetchOptimistic(Z).catch(()=>{Q.clearReset()});function iu(Z,z,Q){const Pe=Df(Q),Pt=af(),tr=Gu(),Sr=Pe.defaultQueryOptions(Z);Sr._optimisticResults=Pt?"isRestoring":"optimistic",ac(Sr),kf(Sr,tr),ff(tr);const[Dr]=p.useState(()=>new z(Pe,Sr)),Kr=Dr.getOptimisticResult(Sr);if(p.useSyncExternalStore(p.useCallback(Zn=>{const ai=Pt?()=>{}:Dr.subscribe(Ra.batchCalls(Zn));return Dr.updateResult(),ai},[Dr,Pt]),()=>Dr.getCurrentResult(),()=>Dr.getCurrentResult()),p.useEffect(()=>{Dr.setOptions(Sr,{listeners:!1})},[Sr,Dr]),Us(Sr,Kr))throw vl(Sr,Dr,tr);if(vf({result:Kr,errorResetBoundary:tr,throwOnError:Sr.throwOnError,query:Pe.getQueryCache().get(Sr.queryHash)}))throw Kr.error;return Sr.notifyOnChangeProps?Kr:Dr.trackResult(Kr)}function Ca(Z,z){return iu(Z,vu,z)}function xa(Z){"@babel/helpers - typeof";return xa=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(z){return typeof z}:function(z){return z&&typeof Symbol=="function"&&z.constructor===Symbol&&z!==Symbol.prototype?"symbol":typeof z},xa(Z)}function Dl(Z,z){var Q=Object.keys(Z);if(Object.getOwnPropertySymbols){var Pe=Object.getOwnPropertySymbols(Z);z&&(Pe=Pe.filter(function(Pt){return Object.getOwnPropertyDescriptor(Z,Pt).enumerable})),Q.push.apply(Q,Pe)}return Q}function Gf(Z){for(var z=1;zZ.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);QZ.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);Q=0)&&Object.prototype.propertyIsEnumerable.call(Z,Pe)&&(Q[Pe]=Z[Pe])}return Q}function fh(Z,z){if(Z==null)return{};var Q={},Pe=Object.keys(Z),Pt,tr;for(tr=0;tr=0)&&(Q[Pt]=Z[Pt]);return Q}function uf(Z,z){return h(Z)||fp(Z,z)||rh(Z,z)||Yf()}function Yf(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function rh(Z,z){if(Z){if(typeof Z=="string")return ud(Z,z);var Q=Object.prototype.toString.call(Z).slice(8,-1);if(Q==="Object"&&Z.constructor&&(Q=Z.constructor.name),Q==="Map"||Q==="Set")return Array.from(Z);if(Q==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Q))return ud(Z,z)}}function ud(Z,z){(z==null||z>Z.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);QZ.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);QZ.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);QZ.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);QZ.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);QZ.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);QZ.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);QZ.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);QZ.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);Q=Z.length?{done:!0}:{done:!1,value:Z[Pe++]}},e:function(Zn){throw Zn},f:Pt}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var tr=!0,Sr=!1,Dr;return{s:function(){Q=Q.call(Z)},n:function(){var Zn=Q.next();return tr=Zn.done,Zn},e:function(Zn){Sr=!0,Dr=Zn},f:function(){try{!tr&&Q.return!=null&&Q.return()}finally{if(Sr)throw Dr}}}}function id(Z,z){if(Z){if(typeof Z=="string")return Hp(Z,z);var Q=Object.prototype.toString.call(Z).slice(8,-1);if(Q==="Object"&&Z.constructor&&(Q=Z.constructor.name),Q==="Map"||Q==="Set")return Array.from(Z);if(Q==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Q))return Hp(Z,z)}}function Hp(Z,z){(z==null||z>Z.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);Q0&&arguments[0]!==void 0?arguments[0]:[];mc(this,Z),lf(this,"widgets",new Map),lf(this,"layers",new Map),lf(this,"services",new Map),Q.forEach(function(Pe){return z.installAsset(Pe)})}return od(Z,[{key:"registerWidget",value:function(Q){this.widgets.has(Q.metadata.name)||this.widgets.set(Q.metadata.name,Q)}},{key:"registerLayer",value:function(Q){this.layers.has(Q.metadata.name)||this.layers.set(Q.metadata.name,Q)}},{key:"registerService",value:function(Q){this.services.has(Q.metadata.name)||this.services.set(Q.metadata.name,Q)}},{key:"getWidget",value:function(Q){var Pe=this.widgets.get(Q);if(!Pe){var Pt={component:function(){return"\u7EC4\u4EF6 ".concat(Q," \u672A\u6CE8\u518C\u6210\u529F.")},metadata:{},registerForm:{}};return console.error("[li-sdk]: \u7EC4\u4EF6 ".concat(Q," \u672A\u6CE8\u518C\u6210\u529F.")),Pt}return Pe}},{key:"getLayer",value:function(Q){var Pe=this.layers.get(Q);if(!Pe){var Pt={component:function(){return null},metadata:{},registerForm:{}};return console.error("[li-sdk]: \u56FE\u5C42 ".concat(Q," \u672A\u6CE8\u518C\u6210\u529F.")),Pt}return Pe}},{key:"getService",value:function(Q){var Pe=this.services.get(Q);if(!Pe){var Pt={service:function(){return Promise.resolve([])},metadata:{}};return console.error("[li-sdk]: \u670D\u52A1 ".concat(Q," \u672A\u6CE8\u518C\u6210\u529F.")),Pt}return Pe}},{key:"getAllWidgets",value:function(){var Q=[],Pe=nd(this.widgets.values()),Pt;try{for(Pe.s();!(Pt=Pe.n()).done;){var tr=Pt.value;Q.push(tr)}}catch(Sr){Pe.e(Sr)}finally{Pe.f()}return Q}},{key:"getAllLayers",value:function(){var Q=[],Pe=nd(this.layers.values()),Pt;try{for(Pe.s();!(Pt=Pe.n()).done;){var tr=Pt.value;Q.push(tr)}}catch(Sr){Pe.e(Sr)}finally{Pe.f()}return Q}},{key:"getAllServices",value:function(){var Q=[],Pe=nd(this.services.values()),Pt;try{for(Pe.s();!(Pt=Pe.n()).done;){var tr=Pt.value;Q.push(tr)}}catch(Sr){Pe.e(Sr)}finally{Pe.f()}return Q}},{key:"installAsset",value:function(Q){var Pe,Pt=this,tr,Sr;(Pe=Q.widgets)===null||Pe===void 0||Pe.forEach(function(Dr){return Pt.registerWidget(Dr)}),(tr=Q.layers)===null||tr===void 0||tr.forEach(function(Dr){return Pt.registerLayer(Dr)}),(Sr=Q.services)===null||Sr===void 0||Sr.forEach(function(Dr){return Pt.registerService(Dr)})}}]),Z}(),Zh=Vf,dd=A(21376),Jh=A(32312),g0=A(91284);function b0(Z,z,Q){(Q!==void 0&&!(0,g0.Z)(Z[z],Q)||Q===void 0&&!(z in Z))&&(0,Jh.Z)(Z,z,Q)}var Gp=b0,Wp=A(63928),xp=A(45785),U0=A(21246),x0=A(10214),t0=A(78163),np=A(18519),M0=A(83047),kp=A(21314);function r0(Z){return(0,kp.Z)(Z)&&(0,M0.Z)(Z)}var hp=r0,Xp=A(43156),pm=A(60240),Tp=A(9935),mm=A(77844),dp=A(58166);function j0(Z,z){if(!(z==="constructor"&&typeof Z[z]=="function")&&z!="__proto__")return Z[z]}var Fp=j0,P0=A(71554),I0=A(84975);function V0(Z){return(0,P0.Z)(Z,(0,I0.Z)(Z))}var d0=V0;function Q0(Z,z,Q,Pe,Pt,tr,Sr){var Dr=Fp(Z,Q),Kr=Fp(z,Q),Zn=Sr.get(Kr);if(Zn){Gp(Z,Q,Zn);return}var ai=tr?tr(Dr,Kr,Q+"",Z,z,Sr):void 0,Va=ai===void 0;if(Va){var za=(0,Nn.Z)(Kr),ua=!za&&(0,Xp.Z)(Kr),Za=!za&&!ua&&(0,dp.Z)(Kr);ai=Kr,za||ua||Za?(0,Nn.Z)(Dr)?ai=Dr:hp(Dr)?ai=(0,x0.Z)(Dr):ua?(Va=!1,ai=(0,xp.Z)(Kr,!0)):Za?(Va=!1,ai=(0,U0.Z)(Kr,!0)):ai=[]:(0,mm.Z)(Kr)||(0,np.Z)(Kr)?(ai=Dr,(0,np.Z)(Dr)?ai=d0(Dr):(!(0,Tp.Z)(Dr)||(0,pm.Z)(Dr))&&(ai=(0,t0.Z)(Kr))):Va=!1}Va&&(Sr.set(Kr,ai),Pt(ai,Kr,Pe,tr,Sr),Sr.delete(Kr)),Gp(Z,Q,ai)}var Mc=Q0;function R0(Z,z,Q,Pe,Pt){Z!==z&&(0,Wp.Z)(z,function(tr,Sr){if(Pt||(Pt=new dd.Z),(0,Tp.Z)(tr))Mc(Z,z,Sr,Q,R0,Pe,Pt);else{var Dr=Pe?Pe(Fp(Z,Sr),tr,Sr+"",Z,z,Pt):void 0;Dr===void 0&&(Dr=tr),Gp(Z,Sr,Dr)}},I0.Z)}var w0=R0,ad=A(64739),Yp=A(48301),E0=A(79524);function S0(Z,z){return(0,E0.Z)((0,Yp.Z)(Z,z,ad.Z),Z+"")}var gd=S0,ip=A(1773);function O0(Z,z,Q){if(!(0,Tp.Z)(Q))return!1;var Pe=typeof z;return(Pe=="number"?(0,M0.Z)(Q)&&(0,ip.Z)(z,Q.length):Pe=="string"&&z in Q)?(0,g0.Z)(Q[z],Z):!1}var Bp=O0;function $0(Z){return gd(function(z,Q){var Pe=-1,Pt=Q.length,tr=Pt>1?Q[Pt-1]:void 0,Sr=Pt>2?Q[2]:void 0;for(tr=Z.length>3&&typeof tr=="function"?(Pt--,tr):void 0,Sr&&Bp(Q[0],Q[1],Sr)&&(tr=Pt<3?void 0:tr,Pt=1),z=Object(z);++Pe0&&arguments[0]!==void 0?arguments[0]:{},ai=Dr.map(function(Va){return p.cloneElement(Va,Zn)});return ai}};for(var tr in z[Z])Pt();return Pe},[z,Z]);return Q}function bo(){return bo=Object.assign?Object.assign.bind():function(Z){for(var z=1;zZ.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);Q0&&arguments[0]!==void 0?arguments[0]:{assets:[]};Ot(this,Z),pn(this,"options",void 0),pn(this,"registryManager",void 0),pn(this,"stateManager",void 0),pn(this,"eventBus",new qf.Z),pn(this,"App",void 0);var Q=z.assets,Pe=z.initialGlobalState;this.options=z,this.registryManager=new Zh(Q),this.stateManager=new ti(Pe),this.App=(0,p.memo)(this.getApp()),this.installAssets(Q)}return mr(Z,[{key:"installAssets",value:function(Q){var Pe=this;Q.forEach(function(Pt){return Pe.registryManager.installAsset(Pt)})}},{key:"getApp",value:function(){var Q=this.eventBus,Pe=this.registryManager,Pt=this.stateManager;return function(Sr){var Dr=Sr.config,Kr=Dr.datasets,Zn=Dr.spec;Pt.initState(Sr.config);var ai=(0,p.useMemo)(function(){return{eventBus:Q,registryManager:Pe,stateManager:Pt}},[Kr,Zn]);return p.createElement(De.Provider,{value:ai},p.createElement(Ie,Sr))}}}]),Z}(),no=ci,Wa=["assets","initialGlobalState"];function ha(Z,z){if(Z==null)return{};var Q=Go(Z,z),Pe,Pt;if(Object.getOwnPropertySymbols){var tr=Object.getOwnPropertySymbols(Z);for(Pt=0;Pt=0)&&Object.prototype.propertyIsEnumerable.call(Z,Pe)&&(Q[Pe]=Z[Pe])}return Q}function Go(Z,z){if(Z==null)return{};var Q={},Pe=Object.keys(Z),Pt,tr;for(tr=0;tr=0)&&(Q[Pt]=Z[Pt]);return Q}var Wo=function(z){var Q=z.assets,Pe=z.initialGlobalState,Pt=ha(z,Wa),tr=(0,p.useMemo)(function(){return new no({assets:Q,initialGlobalState:Pe})},[]),Sr=tr.App;return p.createElement(Sr,Pt)},To=(0,p.memo)(Wo);function El(Z){var z,Q=(z=Z.registerForm)!==null&&z!==void 0?z:{schema:{}},Pe=Object.assign(Z,{registerForm:Q});return Pe}function gl(Z){"@babel/helpers - typeof";return gl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(z){return typeof z}:function(z){return z&&typeof Symbol=="function"&&z.constructor===Symbol&&z!==Symbol.prototype?"symbol":typeof z},gl(Z)}var du;function Qu(Z,z,Q){return z=_h(z),z in Z?Object.defineProperty(Z,z,{value:Q,enumerable:!0,configurable:!0,writable:!0}):Z[z]=Q,Z}function _h(Z){var z=Th(Z,"string");return gl(z)==="symbol"?z:String(z)}function Th(Z,z){if(gl(Z)!=="object"||Z===null)return Z;var Q=Z[Symbol.toPrimitive];if(Q!==void 0){var Pe=Q.call(Z,z||"default");if(gl(Pe)!=="object")return Pe;throw new TypeError("@@toPrimitive must return a primitive value.")}return(z==="string"?String:Number)(Z)}function vh(Z){return Hh(Z)||vc(Z)||Nl(Z)||$f()}function $f(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Nl(Z,z){if(Z){if(typeof Z=="string")return Af(Z,z);var Q=Object.prototype.toString.call(Z).slice(8,-1);if(Q==="Object"&&Z.constructor&&(Q=Z.constructor.name),Q==="Map"||Q==="Set")return Array.from(Z);if(Q==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Q))return Af(Z,z)}}function vc(Z){if(typeof Symbol!="undefined"&&Z[Symbol.iterator]!=null||Z["@@iterator"]!=null)return Array.from(Z)}function Hh(Z){if(Array.isArray(Z))return Af(Z)}function Af(Z,z){(z==null||z>Z.length)&&(z=Z.length);for(var Q=0,Pe=new Array(z);Q.5?tt/(2-ut-Xe):tt/(ut+Xe),ut){case Ge:Rt=(ct-Ve)/tt+(ct1&&(Ve-=1),Ve<1/6?Ge+(ct-Ge)*(6*Ve):Ve<1/2?ct:Ve<2/3?Ge+(ct-Ge)*(2/3-Ve)*6:Ge}function $(Ge,ct,Ve){var ut,Xe,Rt;if(Ge=(0,R.sh)(Ge,360),ct=(0,R.sh)(ct,100),Ve=(0,R.sh)(Ve,100),ct===0)Xe=Ve,Rt=Ve,ut=Ve;else{var gt=Ve<.5?Ve*(1+ct):Ve+ct-Ve*ct,Ct=2*Ve-gt;ut=p(Ct,gt,Ge+1/3),Xe=p(Ct,gt,Ge),Rt=p(Ct,gt,Ge-1/3)}return{r:ut*255,g:Xe*255,b:Rt*255}}function X(Ge,ct,Ve){Ge=(0,R.sh)(Ge,255),ct=(0,R.sh)(ct,255),Ve=(0,R.sh)(Ve,255);var ut=Math.max(Ge,ct,Ve),Xe=Math.min(Ge,ct,Ve),Rt=0,gt=ut,Ct=ut-Xe,tt=ut===0?0:Ct/ut;if(ut===Xe)Rt=0;else{switch(ut){case Ge:Rt=(ct-Ve)/Ct+(ct>16,g:(Ge&65280)>>8,b:Ge&255}}},93796:function(Ye,ye,A){"use strict";A.d(ye,{R:function(){return R}});var R={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",goldenrod:"#daa520",gold:"#ffd700",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavenderblush:"#fff0f5",lavender:"#e6e6fa",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"}},9915:function(Ye,ye,A){"use strict";A.d(ye,{uA:function(){return p}});var R=A(12722),V=A(93796),y=A(12187);function p(Ee){var qe={r:0,g:0,b:0},Ge=1,ct=null,Ve=null,ut=null,Xe=!1,Rt=!1;return typeof Ee=="string"&&(Ee=De(Ee)),typeof Ee=="object"&&(we(Ee.r)&&we(Ee.g)&&we(Ee.b)?(qe=(0,R.rW)(Ee.r,Ee.g,Ee.b),Xe=!0,Rt=String(Ee.r).substr(-1)==="%"?"prgb":"rgb"):we(Ee.h)&&we(Ee.s)&&we(Ee.v)?(ct=(0,y.JX)(Ee.s),Ve=(0,y.JX)(Ee.v),qe=(0,R.WE)(Ee.h,ct,Ve),Xe=!0,Rt="hsv"):we(Ee.h)&&we(Ee.s)&&we(Ee.l)&&(ct=(0,y.JX)(Ee.s),ut=(0,y.JX)(Ee.l),qe=(0,R.ve)(Ee.h,ct,ut),Xe=!0,Rt="hsl"),Object.prototype.hasOwnProperty.call(Ee,"a")&&(Ge=Ee.a)),Ge=(0,y.Yq)(Ge),{ok:Xe,format:Ee.format||Rt,r:Math.min(255,Math.max(qe.r,0)),g:Math.min(255,Math.max(qe.g,0)),b:Math.min(255,Math.max(qe.b,0)),a:Ge}}var $="[-\\+]?\\d+%?",X="[-\\+]?\\d*\\.\\d+%?",se="(?:".concat(X,")|(?:").concat($,")"),ae="[\\s|\\(]+(".concat(se,")[,|\\s]+(").concat(se,")[,|\\s]+(").concat(se,")\\s*\\)?"),ce="[\\s|\\(]+(".concat(se,")[,|\\s]+(").concat(se,")[,|\\s]+(").concat(se,")[,|\\s]+(").concat(se,")\\s*\\)?"),le={CSS_UNIT:new RegExp(se),rgb:new RegExp("rgb"+ae),rgba:new RegExp("rgba"+ce),hsl:new RegExp("hsl"+ae),hsla:new RegExp("hsla"+ce),hsv:new RegExp("hsv"+ae),hsva:new RegExp("hsva"+ce),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/};function De(Ee){if(Ee=Ee.trim().toLowerCase(),Ee.length===0)return!1;var qe=!1;if(V.R[Ee])Ee=V.R[Ee],qe=!0;else if(Ee==="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var Ge=le.rgb.exec(Ee);return Ge?{r:Ge[1],g:Ge[2],b:Ge[3]}:(Ge=le.rgba.exec(Ee),Ge?{r:Ge[1],g:Ge[2],b:Ge[3],a:Ge[4]}:(Ge=le.hsl.exec(Ee),Ge?{h:Ge[1],s:Ge[2],l:Ge[3]}:(Ge=le.hsla.exec(Ee),Ge?{h:Ge[1],s:Ge[2],l:Ge[3],a:Ge[4]}:(Ge=le.hsv.exec(Ee),Ge?{h:Ge[1],s:Ge[2],v:Ge[3]}:(Ge=le.hsva.exec(Ee),Ge?{h:Ge[1],s:Ge[2],v:Ge[3],a:Ge[4]}:(Ge=le.hex8.exec(Ee),Ge?{r:(0,R.VD)(Ge[1]),g:(0,R.VD)(Ge[2]),b:(0,R.VD)(Ge[3]),a:(0,R.T6)(Ge[4]),format:qe?"name":"hex8"}:(Ge=le.hex6.exec(Ee),Ge?{r:(0,R.VD)(Ge[1]),g:(0,R.VD)(Ge[2]),b:(0,R.VD)(Ge[3]),format:qe?"name":"hex"}:(Ge=le.hex4.exec(Ee),Ge?{r:(0,R.VD)(Ge[1]+Ge[1]),g:(0,R.VD)(Ge[2]+Ge[2]),b:(0,R.VD)(Ge[3]+Ge[3]),a:(0,R.T6)(Ge[4]+Ge[4]),format:qe?"name":"hex8"}:(Ge=le.hex3.exec(Ee),Ge?{r:(0,R.VD)(Ge[1]+Ge[1]),g:(0,R.VD)(Ge[2]+Ge[2]),b:(0,R.VD)(Ge[3]+Ge[3]),format:qe?"name":"hex"}:!1)))))))))}function we(Ee){return!!le.CSS_UNIT.exec(String(Ee))}},64993:function(Ye,ye,A){"use strict";A.d(ye,{C:function(){return $}});var R=A(12722),V=A(93796),y=A(9915),p=A(12187),$=function(){function se(ae,ce){ae===void 0&&(ae=""),ce===void 0&&(ce={});var le;if(ae instanceof se)return ae;typeof ae=="number"&&(ae=(0,R.Yt)(ae)),this.originalInput=ae;var De=(0,y.uA)(ae);this.originalInput=ae,this.r=De.r,this.g=De.g,this.b=De.b,this.a=De.a,this.roundA=Math.round(100*this.a)/100,this.format=(le=ce.format)!==null&&le!==void 0?le:De.format,this.gradientType=ce.gradientType,this.r<1&&(this.r=Math.round(this.r)),this.g<1&&(this.g=Math.round(this.g)),this.b<1&&(this.b=Math.round(this.b)),this.isValid=De.ok}return se.prototype.isDark=function(){return this.getBrightness()<128},se.prototype.isLight=function(){return!this.isDark()},se.prototype.getBrightness=function(){var ae=this.toRgb();return(ae.r*299+ae.g*587+ae.b*114)/1e3},se.prototype.getLuminance=function(){var ae=this.toRgb(),ce,le,De,we=ae.r/255,Ee=ae.g/255,qe=ae.b/255;return we<=.03928?ce=we/12.92:ce=Math.pow((we+.055)/1.055,2.4),Ee<=.03928?le=Ee/12.92:le=Math.pow((Ee+.055)/1.055,2.4),qe<=.03928?De=qe/12.92:De=Math.pow((qe+.055)/1.055,2.4),.2126*ce+.7152*le+.0722*De},se.prototype.getAlpha=function(){return this.a},se.prototype.setAlpha=function(ae){return this.a=(0,p.Yq)(ae),this.roundA=Math.round(100*this.a)/100,this},se.prototype.isMonochrome=function(){var ae=this.toHsl().s;return ae===0},se.prototype.toHsv=function(){var ae=(0,R.py)(this.r,this.g,this.b);return{h:ae.h*360,s:ae.s,v:ae.v,a:this.a}},se.prototype.toHsvString=function(){var ae=(0,R.py)(this.r,this.g,this.b),ce=Math.round(ae.h*360),le=Math.round(ae.s*100),De=Math.round(ae.v*100);return this.a===1?"hsv(".concat(ce,", ").concat(le,"%, ").concat(De,"%)"):"hsva(".concat(ce,", ").concat(le,"%, ").concat(De,"%, ").concat(this.roundA,")")},se.prototype.toHsl=function(){var ae=(0,R.lC)(this.r,this.g,this.b);return{h:ae.h*360,s:ae.s,l:ae.l,a:this.a}},se.prototype.toHslString=function(){var ae=(0,R.lC)(this.r,this.g,this.b),ce=Math.round(ae.h*360),le=Math.round(ae.s*100),De=Math.round(ae.l*100);return this.a===1?"hsl(".concat(ce,", ").concat(le,"%, ").concat(De,"%)"):"hsla(".concat(ce,", ").concat(le,"%, ").concat(De,"%, ").concat(this.roundA,")")},se.prototype.toHex=function(ae){return ae===void 0&&(ae=!1),(0,R.vq)(this.r,this.g,this.b,ae)},se.prototype.toHexString=function(ae){return ae===void 0&&(ae=!1),"#"+this.toHex(ae)},se.prototype.toHex8=function(ae){return ae===void 0&&(ae=!1),(0,R.s)(this.r,this.g,this.b,this.a,ae)},se.prototype.toHex8String=function(ae){return ae===void 0&&(ae=!1),"#"+this.toHex8(ae)},se.prototype.toHexShortString=function(ae){return ae===void 0&&(ae=!1),this.a===1?this.toHexString(ae):this.toHex8String(ae)},se.prototype.toRgb=function(){return{r:Math.round(this.r),g:Math.round(this.g),b:Math.round(this.b),a:this.a}},se.prototype.toRgbString=function(){var ae=Math.round(this.r),ce=Math.round(this.g),le=Math.round(this.b);return this.a===1?"rgb(".concat(ae,", ").concat(ce,", ").concat(le,")"):"rgba(".concat(ae,", ").concat(ce,", ").concat(le,", ").concat(this.roundA,")")},se.prototype.toPercentageRgb=function(){var ae=function(ce){return"".concat(Math.round((0,p.sh)(ce,255)*100),"%")};return{r:ae(this.r),g:ae(this.g),b:ae(this.b),a:this.a}},se.prototype.toPercentageRgbString=function(){var ae=function(ce){return Math.round((0,p.sh)(ce,255)*100)};return this.a===1?"rgb(".concat(ae(this.r),"%, ").concat(ae(this.g),"%, ").concat(ae(this.b),"%)"):"rgba(".concat(ae(this.r),"%, ").concat(ae(this.g),"%, ").concat(ae(this.b),"%, ").concat(this.roundA,")")},se.prototype.toName=function(){if(this.a===0)return"transparent";if(this.a<1)return!1;for(var ae="#"+(0,R.vq)(this.r,this.g,this.b,!1),ce=0,le=Object.entries(V.R);ce=0,we=!ce&&De&&(ae.startsWith("hex")||ae==="name");return we?ae==="name"&&this.a===0?this.toName():this.toRgbString():(ae==="rgb"&&(le=this.toRgbString()),ae==="prgb"&&(le=this.toPercentageRgbString()),(ae==="hex"||ae==="hex6")&&(le=this.toHexString()),ae==="hex3"&&(le=this.toHexString(!0)),ae==="hex4"&&(le=this.toHex8String(!0)),ae==="hex8"&&(le=this.toHex8String()),ae==="name"&&(le=this.toName()),ae==="hsl"&&(le=this.toHslString()),ae==="hsv"&&(le=this.toHsvString()),le||this.toHexString())},se.prototype.toNumber=function(){return(Math.round(this.r)<<16)+(Math.round(this.g)<<8)+Math.round(this.b)},se.prototype.clone=function(){return new se(this.toString())},se.prototype.lighten=function(ae){ae===void 0&&(ae=10);var ce=this.toHsl();return ce.l+=ae/100,ce.l=(0,p.V2)(ce.l),new se(ce)},se.prototype.brighten=function(ae){ae===void 0&&(ae=10);var ce=this.toRgb();return ce.r=Math.max(0,Math.min(255,ce.r-Math.round(255*-(ae/100)))),ce.g=Math.max(0,Math.min(255,ce.g-Math.round(255*-(ae/100)))),ce.b=Math.max(0,Math.min(255,ce.b-Math.round(255*-(ae/100)))),new se(ce)},se.prototype.darken=function(ae){ae===void 0&&(ae=10);var ce=this.toHsl();return ce.l-=ae/100,ce.l=(0,p.V2)(ce.l),new se(ce)},se.prototype.tint=function(ae){return ae===void 0&&(ae=10),this.mix("white",ae)},se.prototype.shade=function(ae){return ae===void 0&&(ae=10),this.mix("black",ae)},se.prototype.desaturate=function(ae){ae===void 0&&(ae=10);var ce=this.toHsl();return ce.s-=ae/100,ce.s=(0,p.V2)(ce.s),new se(ce)},se.prototype.saturate=function(ae){ae===void 0&&(ae=10);var ce=this.toHsl();return ce.s+=ae/100,ce.s=(0,p.V2)(ce.s),new se(ce)},se.prototype.greyscale=function(){return this.desaturate(100)},se.prototype.spin=function(ae){var ce=this.toHsl(),le=(ce.h+ae)%360;return ce.h=le<0?360+le:le,new se(ce)},se.prototype.mix=function(ae,ce){ce===void 0&&(ce=50);var le=this.toRgb(),De=new se(ae).toRgb(),we=ce/100,Ee={r:(De.r-le.r)*we+le.r,g:(De.g-le.g)*we+le.g,b:(De.b-le.b)*we+le.b,a:(De.a-le.a)*we+le.a};return new se(Ee)},se.prototype.analogous=function(ae,ce){ae===void 0&&(ae=6),ce===void 0&&(ce=30);var le=this.toHsl(),De=360/ce,we=[this];for(le.h=(le.h-(De*ae>>1)+720)%360;--ae;)le.h=(le.h+De)%360,we.push(new se(le));return we},se.prototype.complement=function(){var ae=this.toHsl();return ae.h=(ae.h+180)%360,new se(ae)},se.prototype.monochromatic=function(ae){ae===void 0&&(ae=6);for(var ce=this.toHsv(),le=ce.h,De=ce.s,we=ce.v,Ee=[],qe=1/ae;ae--;)Ee.push(new se({h:le,s:De,v:we})),we=(we+qe)%1;return Ee},se.prototype.splitcomplement=function(){var ae=this.toHsl(),ce=ae.h;return[this,new se({h:(ce+72)%360,s:ae.s,l:ae.l}),new se({h:(ce+216)%360,s:ae.s,l:ae.l})]},se.prototype.onBackground=function(ae){var ce=this.toRgb(),le=new se(ae).toRgb(),De=ce.a+le.a*(1-ce.a);return new se({r:(ce.r*ce.a+le.r*le.a*(1-ce.a))/De,g:(ce.g*ce.a+le.g*le.a*(1-ce.a))/De,b:(ce.b*ce.a+le.b*le.a*(1-ce.a))/De,a:De})},se.prototype.triad=function(){return this.polyad(3)},se.prototype.tetrad=function(){return this.polyad(4)},se.prototype.polyad=function(ae){for(var ce=this.toHsl(),le=ce.h,De=[this],we=360/ae,Ee=1;Ee1)&&(ae=1),ae}function X(ae){return ae<=1?"".concat(Number(ae)*100,"%"):ae}function se(ae){return ae.length===1?"0"+ae:String(ae)}},68564:function(Ye,ye,A){"use strict";A.d(ye,{iv:function(){return Pn}});function R(at){if(at.sheet)return at.sheet;for(var Vt=0;Vt0?we(tt,--gt):0,Xe--,Ct===10&&(Xe=1,ut--),Ct}function Ke(){return Ct=gt2||Ft(Ct)>3?"":" "}function Qe(at){for(;Ke();)switch(Ft(Ct)){case 0:append(hn(gt-1),at);break;case 2:append(We(Ct),at);break;default:append(from(Ct),at)}return at}function dr(at,Vt){for(;--Vt&&Ke()&&!(Ct<48||Ct>102||Ct>57&&Ct<65||Ct>70&&Ct<97););return Se(at,wt()+(Vt<6&&ft()==32&&Ke()==32))}function Kt(at){for(;Ke();)switch(Ct){case at:return gt;case 34:case 39:at!==34&&at!==39&&Kt(Ct);break;case 40:at===41&&Kt(at);break;case 92:Ke();break}return gt}function Yr(at,Vt){for(;Ke()&&at+Ct!==47+10;)if(at+Ct===42+42&&ft()===47)break;return"/*"+Se(Vt,gt-1)+"*"+$(at===47?at:Ke())}function hn(at){for(;!Ft(ft());)Ke();return Se(at,gt)}var ln="-ms-",oi="-moz-",Nn="-webkit-",$n="comm",_i="rule",Qn="decl",Ji="@page",ni="@media",Ei="@import",xo="@charset",sn="@viewport",li="@supports",En="@document",or="@namespace",qi="@keyframes",Bo="@font-face",Mo="@counter-style",Wi="@font-feature-values",Ii="@layer";function ko(at,Vt){for(var gr="",gn=Ge(at),un=0;un-1&&!at.return)switch(at.type){case DECLARATION:at.return=prefix(at.value,at.length,gr);return;case KEYFRAMES:return serialize([copy(at,{value:replace(at.value,"@","@"+WEBKIT)})],gn);case RULESET:if(at.length)return combine(at.props,function(un){switch(match(un,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return serialize([copy(at,{props:[replace(un,/:(read-\w+)/,":"+MOZ+"$1")]})],gn);case"::placeholder":return serialize([copy(at,{props:[replace(un,/:(plac\w+)/,":"+WEBKIT+"input-$1")]}),copy(at,{props:[replace(un,/:(plac\w+)/,":"+MOZ+"$1")]}),copy(at,{props:[replace(un,/:(plac\w+)/,MS+"input-$1")]})],gn)}return""})}}function Ki(at){switch(at.type){case RULESET:at.props=at.props.map(function(Vt){return combine(tokenize(Vt),function(gr,gn,un){switch(charat(gr,0)){case 12:return substr(gr,1,strlen(gr));case 0:case 40:case 43:case 62:case 126:return gr;case 58:un[++gn]==="global"&&(un[gn]="",un[++gn]="\f"+substr(un[gn],gn=1,-1));case 32:return gn===1?"":gr;default:switch(gn){case 0:return at=gr,sizeof(un)>1?"":gr;case(gn=sizeof(un)-1):case 2:return gn===2?gr+at+at:gr+at;default:return gr}}})})}}function Fo(at){return ot(xt("",null,null,null,[""],at=mt(at),0,[0],at))}function xt(at,Vt,gr,gn,un,Zi,ho,Na,mn){for(var Lr=0,yr=0,Mr=ho,Zr=0,Vn=0,In=0,Kn=1,Mi=1,so=1,ro=0,Ho="",ya=un,gs=Zi,lo=gn,No=Ho;Mi;)switch(In=ro,ro=Ke()){case 40:if(In!=108&&we(No,Mr-1)==58){De(No+=le(We(ro),"&","&\f"),"&\f")!=-1&&(so=-1);break}case 34:case 39:case 91:No+=We(ro);break;case 9:case 10:case 13:case 32:No+=st(In);break;case 92:No+=dr(wt()-1,7);continue;case 47:switch(ft()){case 42:case 47:ct(kt(Yr(Ke(),wt()),Vt,gr),mn);break;default:No+="/"}break;case 123*Kn:Na[Lr++]=qe(No)*so;case 125*Kn:case 59:case 0:switch(ro){case 0:case 125:Mi=0;case 59+yr:so==-1&&(No=le(No,/\f/g,"")),Vn>0&&qe(No)-Mr&&ct(Vn>32?ir(No+";",gn,gr,Mr-1):ir(le(No," ","")+";",gn,gr,Mr-2),mn);break;case 59:No+=";";default:if(ct(lo=it(No,Vt,gr,Lr,yr,un,Na,Ho,ya=[],gs=[],Mr),Zi),ro===123)if(yr===0)xt(No,Vt,lo,lo,ya,Zi,Mr,Na,gs);else switch(Zr===99&&we(No,3)===110?100:Zr){case 100:case 108:case 109:case 115:xt(at,lo,lo,gn&&ct(it(at,lo,lo,0,0,un,Na,Ho,un,ya=[],Mr),gs),un,gs,Mr,Na,gn?ya:gs);break;default:xt(No,lo,lo,lo,[""],gs,0,Na,gs)}}Lr=yr=Vn=0,Kn=so=1,Ho=No="",Mr=ho;break;case 58:Mr=1+qe(No),Vn=In;default:if(Kn<1){if(ro==123)--Kn;else if(ro==125&&Kn++==0&&pt()==125)continue}switch(No+=$(ro),ro*Kn){case 38:so=yr>0?1:(No+="\f",-1);break;case 44:Na[Lr++]=(qe(No)-1)*so,so=1;break;case 64:ft()===45&&(No+=We(Ke())),Zr=ft(),yr=Mr=qe(Ho=No+=hn(wt())),ro++;break;case 45:In===45&&qe(No)==2&&(Kn=0)}}return Zi}function it(at,Vt,gr,gn,un,Zi,ho,Na,mn,Lr,yr){for(var Mr=un-1,Zr=un===0?Zi:[""],Vn=Ge(Zr),In=0,Kn=0,Mi=0;In0?Zr[so]+" "+ro:le(ro,/&\f/g,Zr[so])))&&(mn[Mi++]=Ho);return Ne(at,Vt,gr,un===0?_i:Na,mn,Lr,yr)}function kt(at,Vt,gr){return Ne(at,Vt,gr,$n,$(et()),Ee(at,2,-2),0)}function ir(at,Vt,gr,gn){return Ne(at,Vt,gr,Qn,Ee(at,0,gn),Ee(at,gn+1,-1),gn)}var Pr=function(Vt,gr,gn){for(var un=0,Zi=0;un=Zi,Zi=ft(),un===38&&Zi===12&&(gr[gn]=1),!Ft(Zi);)Ke();return Se(Vt,gt)},kr=function(Vt,gr){var gn=-1,un=44;do switch(Ft(un)){case 0:un===38&&ft()===12&&(gr[gn]=1),Vt[gn]+=Pr(gt-1,gr,gn);break;case 2:Vt[gn]+=We(un);break;case 4:if(un===44){Vt[++gn]=ft()===58?"&\f":"",gr[gn]=Vt[gn].length;break}default:Vt[gn]+=$(un)}while(un=Ke());return Vt},An=function(Vt,gr){return ot(kr(mt(Vt),gr))},Dn=new WeakMap,Ht=function(Vt){if(!(Vt.type!=="rule"||!Vt.parent||Vt.length<1)){for(var gr=Vt.value,gn=Vt.parent,un=Vt.column===gn.column&&Vt.line===gn.line;gn.type!=="rule";)if(gn=gn.parent,!gn)return;if(!(Vt.props.length===1&&gr.charCodeAt(0)!==58&&!Dn.get(gn))&&!un){Dn.set(Vt,!0);for(var Zi=[],ho=An(gr,Zi),Na=gn.props,mn=0,Lr=0;mn-1},At=function(Vt){return function(gr,gn,un){if(!(gr.type!=="rule"||Vt.compat)){var Zi=gr.value.match(/(:first|:nth|:nth-last)-child/g);if(Zi){for(var ho=!!gr.parent,Na=ho?gr.parent.children:un,mn=Na.length-1;mn>=0;mn--){var Lr=Na[mn];if(Lr.line=0;gn--)if(!Bt(gr[gn]))return!0;return!1},ar=function(Vt){Vt.type="",Vt.value="",Vt.return="",Vt.children="",Vt.props=""},hr=function(Vt,gr,gn){Bt(Vt)&&(Vt.parent?(console.error("`@import` rules can't be nested inside other rules. Please move it to the top level and put it before regular rules. Keep in mind that they can only be used within global styles."),ar(Vt)):Jt(gr,gn)&&(console.error("`@import` rules can't be after other rules. Please put your `@import` rules before your other rules."),ar(Vt)))};function Gt(at,Vt){switch(se(at,Vt)){case 5103:return Nn+"print-"+at+at;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return Nn+at+at;case 5349:case 4246:case 4810:case 6968:case 2756:return Nn+at+oi+at+ln+at+at;case 6828:case 4268:return Nn+at+ln+at+at;case 6165:return Nn+at+ln+"flex-"+at+at;case 5187:return Nn+at+le(at,/(\w+).+(:[^]+)/,Nn+"box-$1$2"+ln+"flex-$1$2")+at;case 5443:return Nn+at+ln+"flex-item-"+le(at,/flex-|-self/,"")+at;case 4675:return Nn+at+ln+"flex-line-pack"+le(at,/align-content|flex-|-self/,"")+at;case 5548:return Nn+at+ln+le(at,"shrink","negative")+at;case 5292:return Nn+at+ln+le(at,"basis","preferred-size")+at;case 6060:return Nn+"box-"+le(at,"-grow","")+Nn+at+ln+le(at,"grow","positive")+at;case 4554:return Nn+le(at,/([^-])(transform)/g,"$1"+Nn+"$2")+at;case 6187:return le(le(le(at,/(zoom-|grab)/,Nn+"$1"),/(image-set)/,Nn+"$1"),at,"")+at;case 5495:case 3959:return le(at,/(image-set\([^]*)/,Nn+"$1$`$1");case 4968:return le(le(at,/(.+:)(flex-)?(.*)/,Nn+"box-pack:$3"+ln+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+Nn+at+at;case 4095:case 3583:case 4068:case 2532:return le(at,/(.+)-inline(.+)/,Nn+"$1$2")+at;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(qe(at)-1-Vt>6)switch(we(at,Vt+1)){case 109:if(we(at,Vt+4)!==45)break;case 102:return le(at,/(.+:)(.+)-([^]+)/,"$1"+Nn+"$2-$3$1"+oi+(we(at,Vt+3)==108?"$3":"$2-$3"))+at;case 115:return~De(at,"stretch")?Gt(le(at,"stretch","fill-available"),Vt)+at:at}break;case 4949:if(we(at,Vt+1)!==115)break;case 6444:switch(we(at,qe(at)-3-(~De(at,"!important")&&10))){case 107:return le(at,":",":"+Nn)+at;case 101:return le(at,/(.+:)([^;!]+)(;|!.+)?/,"$1"+Nn+(we(at,14)===45?"inline-":"")+"box$3$1"+Nn+"$2$3$1"+ln+"$2box$3")+at}break;case 5936:switch(we(at,Vt+11)){case 114:return Nn+at+ln+le(at,/[svh]\w+-[tblr]{2}/,"tb")+at;case 108:return Nn+at+ln+le(at,/[svh]\w+-[tblr]{2}/,"tb-rl")+at;case 45:return Nn+at+ln+le(at,/[svh]\w+-[tblr]{2}/,"lr")+at}return Nn+at+ln+at+at}return at}var Tr=function(Vt,gr,gn,un){if(Vt.length>-1&&!Vt.return)switch(Vt.type){case Qn:Vt.return=Gt(Vt.value,Vt.length);break;case qi:return ko([bt(Vt,{value:le(Vt.value,"@","@"+Nn)})],un);case _i:if(Vt.length)return Ve(Vt.props,function(Zi){switch(ce(Zi,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return ko([bt(Vt,{props:[le(Zi,/:(read-\w+)/,":"+oi+"$1")]})],un);case"::placeholder":return ko([bt(Vt,{props:[le(Zi,/:(plac\w+)/,":"+Nn+"input-$1")]}),bt(Vt,{props:[le(Zi,/:(plac\w+)/,":"+oi+"$1")]}),bt(Vt,{props:[le(Zi,/:(plac\w+)/,ln+"input-$1")]})],un)}return""})}},nn=[Tr],bn=function(Vt){var gr=Vt.key;if(gr==="css"){var gn=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(gn,function(Kn){var Mi=Kn.getAttribute("data-emotion");Mi.indexOf(" ")!==-1&&(document.head.appendChild(Kn),Kn.setAttribute("data-s",""))})}var un=Vt.stylisPlugins||nn,Zi={},ho,Na=[];ho=Vt.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+gr+' "]'),function(Kn){for(var Mi=Kn.getAttribute("data-emotion").split(" "),so=1;so=4;++gn,un-=4)gr=at.charCodeAt(gn)&255|(at.charCodeAt(++gn)&255)<<8|(at.charCodeAt(++gn)&255)<<16|(at.charCodeAt(++gn)&255)<<24,gr=(gr&65535)*1540483477+((gr>>>16)*59797<<16),gr^=gr>>>24,Vt=(gr&65535)*1540483477+((gr>>>16)*59797<<16)^(Vt&65535)*1540483477+((Vt>>>16)*59797<<16);switch(un){case 3:Vt^=(at.charCodeAt(gn+2)&255)<<16;case 2:Vt^=(at.charCodeAt(gn+1)&255)<<8;case 1:Vt^=at.charCodeAt(gn)&255,Vt=(Vt&65535)*1540483477+((Vt>>>16)*59797<<16)}return Vt^=Vt>>>13,Vt=(Vt&65535)*1540483477+((Vt>>>16)*59797<<16),((Vt^Vt>>>15)>>>0).toString(36)}var on={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function dn(at){var Vt=Object.create(null);return function(gr){return Vt[gr]===void 0&&(Vt[gr]=at(gr)),Vt[gr]}}var ri=`You have illegal escape sequence in your template literal, most likely inside content's property value. +Because you write your CSS inside a JavaScript string you actually have to do double escaping, so for example "content: '\\00d7';" should become "content: '\\\\00d7';". +You can read more about this here: +https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals#ES2018_revision_of_illegal_escape_sequences`,Wn="You have passed in falsy value as style object's key (can happen when in example you pass unexported component as computed key).",Rn=/[A-Z]|^ms/g,di=/_EMO_([^_]+?)_([^]*?)_EMO_/g,zi=function(Vt){return Vt.charCodeAt(1)===45},Gi=function(Vt){return Vt!=null&&typeof Vt!="boolean"},Lo=dn(function(at){return zi(at)?at:at.replace(Rn,"-$&").toLowerCase()}),eo=function(Vt,gr){switch(Vt){case"animation":case"animationName":if(typeof gr=="string")return gr.replace(di,function(gn,un,Zi){return gi={name:un,styles:Zi,next:gi},un})}return on[Vt]!==1&&!zi(Vt)&&typeof gr=="number"&&gr!==0?gr+"px":gr};if(!1)var ba,va,Do,Ps,Nr,fo;var hi=null;function Yi(at,Vt,gr){if(gr==null)return"";if(gr.__emotion_styles!==void 0)return gr;switch(typeof gr){case"boolean":return"";case"object":{if(gr.anim===1)return gi={name:gr.name,styles:gr.styles,next:gi},gr.name;if(gr.styles!==void 0){var gn=gr.next;if(gn!==void 0)for(;gn!==void 0;)gi={name:gn.name,styles:gn.styles,next:gi},gn=gn.next;var un=gr.styles+";";return un}return ga(at,Vt,gr)}case"function":{if(at!==void 0){var Zi=gi,ho=gr(at);return gi=Zi,Yi(at,Vt,ho)}break}case"string":if(!1)var Na,mn;break}if(Vt==null)return gr;var Lr=Vt[gr];return Lr!==void 0?Lr:gr}function ga(at,Vt,gr){var gn="";if(Array.isArray(gr))for(var un=0;un=Math.abs(ce)?p-le+ce:ce-le+p,p=le}p+$>=0!=!!y&&V.reverse()}},59263:function(Ye){"use strict";Ye.exports=ye;function ye(A,R){this.x=A,this.y=R}ye.prototype={clone:function(){return new ye(this.x,this.y)},add:function(A){return this.clone()._add(A)},sub:function(A){return this.clone()._sub(A)},multByPoint:function(A){return this.clone()._multByPoint(A)},divByPoint:function(A){return this.clone()._divByPoint(A)},mult:function(A){return this.clone()._mult(A)},div:function(A){return this.clone()._div(A)},rotate:function(A){return this.clone()._rotate(A)},rotateAround:function(A,R){return this.clone()._rotateAround(A,R)},matMult:function(A){return this.clone()._matMult(A)},unit:function(){return this.clone()._unit()},perp:function(){return this.clone()._perp()},round:function(){return this.clone()._round()},mag:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},equals:function(A){return this.x===A.x&&this.y===A.y},dist:function(A){return Math.sqrt(this.distSqr(A))},distSqr:function(A){var R=A.x-this.x,V=A.y-this.y;return R*R+V*V},angle:function(){return Math.atan2(this.y,this.x)},angleTo:function(A){return Math.atan2(this.y-A.y,this.x-A.x)},angleWith:function(A){return this.angleWithSep(A.x,A.y)},angleWithSep:function(A,R){return Math.atan2(this.x*R-this.y*A,this.x*A+this.y*R)},_matMult:function(A){var R=A[0]*this.x+A[1]*this.y,V=A[2]*this.x+A[3]*this.y;return this.x=R,this.y=V,this},_add:function(A){return this.x+=A.x,this.y+=A.y,this},_sub:function(A){return this.x-=A.x,this.y-=A.y,this},_mult:function(A){return this.x*=A,this.y*=A,this},_div:function(A){return this.x/=A,this.y/=A,this},_multByPoint:function(A){return this.x*=A.x,this.y*=A.y,this},_divByPoint:function(A){return this.x/=A.x,this.y/=A.y,this},_unit:function(){return this._div(this.mag()),this},_perp:function(){var A=this.y;return this.y=this.x,this.x=-A,this},_rotate:function(A){var R=Math.cos(A),V=Math.sin(A),y=R*this.x-V*this.y,p=V*this.x+R*this.y;return this.x=y,this.y=p,this},_rotateAround:function(A,R){var V=Math.cos(A),y=Math.sin(A),p=R.x+V*(this.x-R.x)-y*(this.y-R.y),$=R.y+y*(this.x-R.x)+V*(this.y-R.y);return this.x=p,this.y=$,this},_round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}},ye.convert=function(A){return A instanceof ye?A:Array.isArray(A)?new ye(A[0],A[1]):A}},52155:function(Ye){"use strict";Ye.exports=A,Ye.exports.default=A;var ye=1e20;function A($,X,se,ae,ce,le){this.fontSize=$||24,this.buffer=X===void 0?3:X,this.cutoff=ae||.25,this.fontFamily=ce||"sans-serif",this.fontWeight=le||"normal",this.radius=se||8;var De=this.size=this.fontSize+this.buffer*2,we=De+this.buffer*2;this.canvas=document.createElement("canvas"),this.canvas.width=this.canvas.height=De,this.ctx=this.canvas.getContext("2d"),this.ctx.font=this.fontWeight+" "+this.fontSize+"px "+this.fontFamily,this.ctx.textAlign="left",this.ctx.fillStyle="black",this.gridOuter=new Float64Array(we*we),this.gridInner=new Float64Array(we*we),this.f=new Float64Array(we),this.z=new Float64Array(we+1),this.v=new Uint16Array(we),this.useMetrics=this.ctx.measureText("A").actualBoundingBoxLeft!==void 0,this.middle=Math.round(De/2*(navigator.userAgent.indexOf("Gecko/")>=0?1.2:1))}function R($,X,se,ae,ce,le,De){le.fill(ye,0,X*se),De.fill(0,0,X*se);for(var we=(X-ae)/2,Ee=0;Ee-1);Ee++,le[Ee]=we,De[Ee]=qe,De[Ee+1]=ye}for(we=0,Ee=0;wey)return y;for(;V$?V=p:y=p,p=(y-V)*.5+V}return p},ye.prototype.solve=function(A,R){return this.sampleCurveY(this.solveCurveX(A,R))}},8332:function(Ye,ye,A){Ye.exports.VectorTile=A(29148),A(82442),A(37815)},29148:function(Ye,ye,A){"use strict";var R=A(37815);Ye.exports=V;function V(p,$){this.layers=p.readFields(y,{},$)}function y(p,$,X){if(p===3){var se=new R(X,X.readVarint()+X.pos);se.length&&($[se.name]=se)}}},82442:function(Ye,ye,A){"use strict";var R=A(59263);Ye.exports=V;function V(se,ae,ce,le,De){this.properties={},this.extent=ce,this.type=0,this._pbf=se,this._geometry=-1,this._keys=le,this._values=De,se.readFields(y,this,ae)}function y(se,ae,ce){se==1?ae.id=ce.readVarint():se==2?p(ce,ae):se==3?ae.type=ce.readVarint():se==4&&(ae._geometry=ce.pos)}function p(se,ae){for(var ce=se.readVarint()+se.pos;se.pos>3}if(le--,ce===1||ce===2)De+=se.readSVarint(),we+=se.readSVarint(),ce===1&&(qe&&Ee.push(qe),qe=[]),qe.push(new R(De,we));else if(ce===7)qe&&qe.push(qe[0].clone());else throw new Error("unknown command "+ce)}return qe&&Ee.push(qe),Ee},V.prototype.bbox=function(){var se=this._pbf;se.pos=this._geometry;for(var ae=se.readVarint()+se.pos,ce=1,le=0,De=0,we=0,Ee=1/0,qe=-1/0,Ge=1/0,ct=-1/0;se.pos>3}if(le--,ce===1||ce===2)De+=se.readSVarint(),we+=se.readSVarint(),Deqe&&(qe=De),wect&&(ct=we);else if(ce!==7)throw new Error("unknown command "+ce)}return[Ee,Ge,qe,ct]},V.prototype.toGeoJSON=function(se,ae,ce){var le=this.extent*Math.pow(2,ce),De=this.extent*se,we=this.extent*ae,Ee=this.loadGeometry(),qe=V.types[this.type],Ge,ct;function Ve(Rt){for(var gt=0;gt>3;X=ae===1?$.readString():ae===2?$.readFloat():ae===3?$.readDouble():ae===4?$.readVarint64():ae===5?$.readVarint():ae===6?$.readSVarint():ae===7?$.readBoolean():null}return X}V.prototype.feature=function($){if($<0||$>=this._features.length)throw new Error("feature index out of bounds");this._pbf.pos=this._features[$];var X=this._pbf.readVarint()+this._pbf.pos;return new R(this._pbf,X,this.extent,this._keys,this._values)}},526:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return pt}});var R=A(35372),V=A(77617),y=A(79161),p=A(42871),$=A(36014),X=A(88831),se=V.createContext(null),ae=se,ce=A(49397),le=A(70658),De=[];function we(Ke,ft){var wt=V.useState(function(){if(!(0,p.Z)())return null;var hn=document.createElement("div");return hn}),Se=(0,R.Z)(wt,1),Ft=Se[0],mt=V.useRef(!1),ot=V.useContext(ae),We=V.useState(De),Me=(0,R.Z)(We,2),st=Me[0],Qe=Me[1],dr=ot||(mt.current?void 0:function(hn){Qe(function(ln){var oi=[hn].concat((0,ce.Z)(ln));return oi})});function Kt(){Ft.parentElement||document.body.appendChild(Ft),mt.current=!0}function Yr(){var hn;(hn=Ft.parentElement)===null||hn===void 0||hn.removeChild(Ft),mt.current=!1}return(0,le.Z)(function(){return Ke?ot?ot(Kt):Kt():Yr(),Yr},[Ke]),(0,le.Z)(function(){st.length&&(st.forEach(function(hn){return hn()}),Qe(De))},[st]),[Ft,dr]}var Ee=A(75966),qe;function Ge(Ke){if(typeof document=="undefined")return 0;if(Ke||qe===void 0){var ft=document.createElement("div");ft.style.width="100%",ft.style.height="200px";var wt=document.createElement("div"),Se=wt.style;Se.position="absolute",Se.top="0",Se.left="0",Se.pointerEvents="none",Se.visibility="hidden",Se.width="200px",Se.height="150px",Se.overflow="hidden",wt.appendChild(ft),document.body.appendChild(wt);var Ft=ft.offsetWidth;wt.style.overflow="scroll";var mt=ft.offsetWidth;Ft===mt&&(mt=wt.clientWidth),document.body.removeChild(wt),qe=Ft-mt}return qe}function ct(Ke){var ft=Ke.match(/^(.*)px$/),wt=Number(ft==null?void 0:ft[1]);return Number.isNaN(wt)?Ge():wt}function Ve(Ke){if(typeof document=="undefined"||!Ke||!(Ke instanceof Element))return{width:0,height:0};var ft=getComputedStyle(Ke,"::-webkit-scrollbar"),wt=ft.width,Se=ft.height;return{width:ct(wt),height:ct(Se)}}function ut(){return document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight)&&window.innerWidth>document.body.offsetWidth}var Xe="rc-util-locker-".concat(Date.now()),Rt=0;function gt(Ke){var ft=!!Ke,wt=V.useState(function(){return Rt+=1,"".concat(Xe,"_").concat(Rt)}),Se=(0,R.Z)(wt,1),Ft=Se[0];(0,le.Z)(function(){if(ft){var mt=Ve(document.body).width,ot=ut();(0,Ee.hq)(` +html body { + overflow-y: hidden; + `.concat(ot?"width: calc(100% - ".concat(mt,"px);"):"",` +}`),Ft)}else(0,Ee.jL)(Ft);return function(){(0,Ee.jL)(Ft)}},[ft,Ft])}var Ct=!1;function tt(Ke){return typeof Ke=="boolean"&&(Ct=Ke),Ct}var Ne=function(ft){return ft===!1?!1:!(0,p.Z)()||!ft?null:typeof ft=="string"?document.querySelector(ft):typeof ft=="function"?ft():ft},bt=V.forwardRef(function(Ke,ft){var wt=Ke.open,Se=Ke.autoLock,Ft=Ke.getContainer,mt=Ke.debug,ot=Ke.autoDestroy,We=ot===void 0?!0:ot,Me=Ke.children,st=V.useState(wt),Qe=(0,R.Z)(st,2),dr=Qe[0],Kt=Qe[1],Yr=dr||wt;V.useEffect(function(){(We||wt)&&Kt(wt)},[wt,We]);var hn=V.useState(function(){return Ne(Ft)}),ln=(0,R.Z)(hn,2),oi=ln[0],Nn=ln[1];V.useEffect(function(){var or=Ne(Ft);Nn(or!=null?or:null)});var $n=we(Yr&&!oi,mt),_i=(0,R.Z)($n,2),Qn=_i[0],Ji=_i[1],ni=oi!=null?oi:Qn;gt(Se&&wt&&(0,p.Z)()&&(ni===Qn||ni===document.body));var Ei=null;if(Me&&(0,X.Yr)(Me)&&ft){var xo=Me;Ei=xo.ref}var sn=(0,X.x1)(Ei,ft);if(!Yr||!(0,p.Z)()||oi===void 0)return null;var li=ni===!1||tt(),En=Me;return ft&&(En=V.cloneElement(Me,{ref:sn})),V.createElement(ae.Provider,{value:Ji},li?En:(0,y.createPortal)(En,ni))}),et=bt,pt=et},35593:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return xo}});var R=A(54131),V=A(35372),y=A(56348),p=A(526),$=A(92310),X=A.n($),se=A(28647),ae=A(58035),ce=A(39057),le=A(60402),De=A(57901),we=A(70658),Ee=A(15639),qe=A(77617),Ge=A(79384),ct=A(44516),Ve=A(88831);function ut(sn){var li=sn.prefixCls,En=sn.align,or=sn.arrow,qi=sn.arrowPos,Bo=or||{},Mo=Bo.className,Wi=Bo.content,Ii=qi.x,ko=Ii===void 0?0:Ii,Fn=qi.y,zn=Fn===void 0?0:Fn,Un=qe.useRef();if(!En||!En.points)return null;var Hi={position:"absolute"};if(En.autoArrow!==!1){var Ki=En.points[0],Fo=En.points[1],xt=Ki[0],it=Ki[1],kt=Fo[0],ir=Fo[1];xt===kt||!["t","b"].includes(xt)?Hi.top=zn:xt==="t"?Hi.top=0:Hi.bottom=0,it===ir||!["l","r"].includes(it)?Hi.left=ko:it==="l"?Hi.left=0:Hi.right=0}return qe.createElement("div",{ref:Un,className:X()("".concat(li,"-arrow"),Mo),style:Hi},Wi)}function Xe(sn){var li=sn.prefixCls,En=sn.open,or=sn.zIndex,qi=sn.mask,Bo=sn.motion;return qi?qe.createElement(ct.ZP,(0,Ge.Z)({},Bo,{motionAppear:!0,visible:En,removeOnLeave:!0}),function(Mo){var Wi=Mo.className;return qe.createElement("div",{style:{zIndex:or},className:X()("".concat(li,"-mask"),Wi)})}):null}var Rt=qe.memo(function(sn){var li=sn.children;return li},function(sn,li){return li.cache}),gt=Rt,Ct=qe.forwardRef(function(sn,li){var En=sn.popup,or=sn.className,qi=sn.prefixCls,Bo=sn.style,Mo=sn.target,Wi=sn.onVisibleChanged,Ii=sn.open,ko=sn.keepDom,Fn=sn.fresh,zn=sn.onClick,Un=sn.mask,Hi=sn.arrow,Ki=sn.arrowPos,Fo=sn.align,xt=sn.motion,it=sn.maskMotion,kt=sn.forceRender,ir=sn.getPopupContainer,Pr=sn.autoDestroy,kr=sn.portal,An=sn.zIndex,Dn=sn.onMouseEnter,Ht=sn.onMouseLeave,Lt=sn.onPointerEnter,je=sn.ready,$e=sn.offsetX,At=sn.offsetY,Bt=sn.offsetR,Jt=sn.offsetB,ar=sn.onAlign,hr=sn.onPrepare,Gt=sn.stretch,Tr=sn.targetWidth,nn=sn.targetHeight,bn=typeof En=="function"?En():En,Bi=Ii||ko,on=(ir==null?void 0:ir.length)>0,dn=qe.useState(!ir||!on),ri=(0,V.Z)(dn,2),Wn=ri[0],Rn=ri[1];if((0,we.Z)(function(){!Wn&&on&&Mo&&Rn(!0)},[Wn,on,Mo]),!Wn)return null;var di="auto",zi={left:"-1000vw",top:"-1000vh",right:di,bottom:di};if(je||!Ii){var Gi,Lo=Fo.points,eo=Fo.dynamicInset||((Gi=Fo._experimental)===null||Gi===void 0?void 0:Gi.dynamicInset),ba=eo&&Lo[0][1]==="r",va=eo&&Lo[0][0]==="b";ba?(zi.right=Bt,zi.left=di):(zi.left=$e,zi.right=di),va?(zi.bottom=Jt,zi.top=di):(zi.top=At,zi.bottom=di)}var Do={};return Gt&&(Gt.includes("height")&&nn?Do.height=nn:Gt.includes("minHeight")&&nn&&(Do.minHeight=nn),Gt.includes("width")&&Tr?Do.width=Tr:Gt.includes("minWidth")&&Tr&&(Do.minWidth=Tr)),Ii||(Do.pointerEvents="none"),qe.createElement(kr,{open:kt||Bi,getContainer:ir&&function(){return ir(Mo)},autoDestroy:Pr},qe.createElement(Xe,{prefixCls:qi,open:Ii,zIndex:An,mask:Un,motion:it}),qe.createElement(se.Z,{onResize:ar,disabled:!Ii},function(Ps){return qe.createElement(ct.ZP,(0,Ge.Z)({motionAppear:!0,motionEnter:!0,motionLeave:!0,removeOnLeave:!1,forceRender:kt,leavedClassName:"".concat(qi,"-hidden")},xt,{onAppearPrepare:hr,onEnterPrepare:hr,visible:Ii,onVisibleChanged:function(fo){var hi;xt==null||(hi=xt.onVisibleChanged)===null||hi===void 0||hi.call(xt,fo),Wi(fo)}}),function(Nr,fo){var hi=Nr.className,Yi=Nr.style,ga=X()(qi,hi,or);return qe.createElement("div",{ref:(0,Ve.sQ)(Ps,li,fo),className:ga,style:(0,R.Z)((0,R.Z)((0,R.Z)((0,R.Z)({"--arrow-x":"".concat(Ki.x||0,"px"),"--arrow-y":"".concat(Ki.y||0,"px")},zi),Do),Yi),{},{boxSizing:"border-box",zIndex:An},Bo),onMouseEnter:Dn,onMouseLeave:Ht,onPointerEnter:Lt,onClick:zn},Hi&&qe.createElement(ut,{prefixCls:qi,arrow:Hi,arrowPos:Ki,align:Fo}),qe.createElement(gt,{cache:!Ii&&!Fn},bn))})}))}),tt=Ct,Ne=qe.forwardRef(function(sn,li){var En=sn.children,or=sn.getTriggerDOMNode,qi=(0,Ve.Yr)(En),Bo=qe.useCallback(function(Wi){(0,Ve.mH)(li,or?or(Wi):Wi)},[or]),Mo=(0,Ve.x1)(Bo,En.ref);return qi?qe.cloneElement(En,{ref:Mo}):En}),bt=Ne,et=qe.createContext(null),pt=et;function Ke(sn){return sn?Array.isArray(sn)?sn:[sn]:[]}function ft(sn,li,En,or){return qe.useMemo(function(){var qi=Ke(En!=null?En:li),Bo=Ke(or!=null?or:li),Mo=new Set(qi),Wi=new Set(Bo);return sn&&(Mo.has("hover")&&(Mo.delete("hover"),Mo.add("click")),Wi.has("hover")&&(Wi.delete("hover"),Wi.add("click"))),[Mo,Wi]},[sn,li,En,or])}var wt=A(95077);function Se(){var sn=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],li=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],En=arguments.length>2?arguments[2]:void 0;return En?sn[0]===li[0]:sn[0]===li[0]&&sn[1]===li[1]}function Ft(sn,li,En,or){for(var qi=En.points,Bo=Object.keys(sn),Mo=0;Mo1&&arguments[1]!==void 0?arguments[1]:1;return Number.isNaN(sn)?li:sn}function st(sn){return Me(parseFloat(sn),0)}function Qe(sn,li){var En=(0,R.Z)({},sn);return(li||[]).forEach(function(or){if(!(or instanceof HTMLBodyElement||or instanceof HTMLHtmlElement)){var qi=ot(or).getComputedStyle(or),Bo=qi.overflow,Mo=qi.overflowClipMargin,Wi=qi.borderTopWidth,Ii=qi.borderBottomWidth,ko=qi.borderLeftWidth,Fn=qi.borderRightWidth,zn=or.getBoundingClientRect(),Un=or.offsetHeight,Hi=or.clientHeight,Ki=or.offsetWidth,Fo=or.clientWidth,xt=st(Wi),it=st(Ii),kt=st(ko),ir=st(Fn),Pr=Me(Math.round(zn.width/Ki*1e3)/1e3),kr=Me(Math.round(zn.height/Un*1e3)/1e3),An=(Ki-Fo-kt-ir)*Pr,Dn=(Un-Hi-xt-it)*kr,Ht=xt*kr,Lt=it*kr,je=kt*Pr,$e=ir*Pr,At=0,Bt=0;if(Bo==="clip"){var Jt=st(Mo);At=Jt*Pr,Bt=Jt*kr}var ar=zn.x+je-At,hr=zn.y+Ht-Bt,Gt=ar+zn.width+2*At-je-$e-An,Tr=hr+zn.height+2*Bt-Ht-Lt-Dn;En.left=Math.max(En.left,ar),En.top=Math.max(En.top,hr),En.right=Math.min(En.right,Gt),En.bottom=Math.min(En.bottom,Tr)}}),En}function dr(sn){var li=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,En="".concat(li),or=En.match(/^(.*)\%$/);return or?sn*(parseFloat(or[1])/100):parseFloat(En)}function Kt(sn,li){var En=li||[],or=(0,V.Z)(En,2),qi=or[0],Bo=or[1];return[dr(sn.width,qi),dr(sn.height,Bo)]}function Yr(){var sn=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return[sn[0],sn[1]]}function hn(sn,li){var En=li[0],or=li[1],qi,Bo;return En==="t"?Bo=sn.y:En==="b"?Bo=sn.y+sn.height:Bo=sn.y+sn.height/2,or==="l"?qi=sn.x:or==="r"?qi=sn.x+sn.width:qi=sn.x+sn.width/2,{x:qi,y:Bo}}function ln(sn,li){var En={t:"b",b:"t",l:"r",r:"l"};return sn.map(function(or,qi){return qi===li?En[or]||"c":or}).join("")}function oi(sn,li,En,or,qi,Bo,Mo){var Wi=qe.useState({ready:!1,offsetX:0,offsetY:0,offsetR:0,offsetB:0,arrowX:0,arrowY:0,scaleX:1,scaleY:1,align:qi[or]||{}}),Ii=(0,V.Z)(Wi,2),ko=Ii[0],Fn=Ii[1],zn=qe.useRef(0),Un=qe.useMemo(function(){return li?We(li):[]},[li]),Hi=qe.useRef({}),Ki=function(){Hi.current={}};sn||Ki();var Fo=(0,le.Z)(function(){if(li&&En&&sn){let Vs=function(Xs,rc){var Ha=arguments.length>2&&arguments[2]!==void 0?arguments[2]:ga,Qs=bn.x+Xs,Uu=bn.y+rc,St=Qs+Gi,Zs=Uu+zi,yu=Math.max(Qs,Ha.left),pl=Math.max(Uu,Ha.top),Ku=Math.min(St,Ha.right),eu=Math.min(Zs,Ha.bottom);return Math.max(0,(Ku-yu)*(eu-pl))},tl=function(){In=bn.y+Vt,Kn=In+zi,Mi=bn.x+at,so=Mi+Gi};var kt,ir,Pr=li,kr=Pr.ownerDocument,An=ot(Pr),Dn=An.getComputedStyle(Pr),Ht=Dn.width,Lt=Dn.height,je=Dn.position,$e=Pr.style.left,At=Pr.style.top,Bt=Pr.style.right,Jt=Pr.style.bottom,ar=Pr.style.overflow,hr=(0,R.Z)((0,R.Z)({},qi[or]),Bo),Gt=kr.createElement("div");(kt=Pr.parentElement)===null||kt===void 0||kt.appendChild(Gt),Gt.style.left="".concat(Pr.offsetLeft,"px"),Gt.style.top="".concat(Pr.offsetTop,"px"),Gt.style.position=je,Gt.style.height="".concat(Pr.offsetHeight,"px"),Gt.style.width="".concat(Pr.offsetWidth,"px"),Pr.style.left="0",Pr.style.top="0",Pr.style.right="auto",Pr.style.bottom="auto",Pr.style.overflow="hidden";var Tr;if(Array.isArray(En))Tr={x:En[0],y:En[1],width:0,height:0};else{var nn=En.getBoundingClientRect();Tr={x:nn.x,y:nn.y,width:nn.width,height:nn.height}}var bn=Pr.getBoundingClientRect(),Bi=kr.documentElement,on=Bi.clientWidth,dn=Bi.clientHeight,ri=Bi.scrollWidth,Wn=Bi.scrollHeight,Rn=Bi.scrollTop,di=Bi.scrollLeft,zi=bn.height,Gi=bn.width,Lo=Tr.height,eo=Tr.width,ba={left:0,top:0,right:on,bottom:dn},va={left:-di,top:-Rn,right:ri-di,bottom:Wn-Rn},Do=hr.htmlRegion,Ps="visible",Nr="visibleFirst";Do!=="scroll"&&Do!==Nr&&(Do=Ps);var fo=Do===Nr,hi=Qe(va,Un),Yi=Qe(ba,Un),ga=Do===Ps?Yi:hi,Xi=fo?Yi:ga;Pr.style.left="auto",Pr.style.top="auto",Pr.style.right="0",Pr.style.bottom="0";var On=Pr.getBoundingClientRect();Pr.style.left=$e,Pr.style.top=At,Pr.style.right=Bt,Pr.style.bottom=Jt,Pr.style.overflow=ar,(ir=Pr.parentElement)===null||ir===void 0||ir.removeChild(Gt);var gi=Me(Math.round(Gi/parseFloat(Ht)*1e3)/1e3),ol=Me(Math.round(zi/parseFloat(Lt)*1e3)/1e3);if(gi===0||ol===0||(0,ae.S)(En)&&!(0,wt.Z)(En))return;var ks=hr.offset,as=hr.targetOffset,_s=Kt(bn,ks),Ks=(0,V.Z)(_s,2),Ea=Ks[0],hs=Ks[1],Ju=Kt(Tr,as),Fa=(0,V.Z)(Ju,2),dc=Fa[0],el=Fa[1];Tr.x-=dc,Tr.y-=el;var fl=hr.points||[],As=(0,V.Z)(fl,2),Rl=As[0],dl=As[1],_c=Yr(dl),lu=Yr(Rl),Pn=hn(Tr,_c),Wr=hn(bn,lu),Ci=(0,R.Z)({},hr),at=Pn.x-Wr.x+Ea,Vt=Pn.y-Wr.y+hs,gr=Vs(at,Vt),gn=Vs(at,Vt,Yi),un=hn(Tr,["t","l"]),Zi=hn(bn,["t","l"]),ho=hn(Tr,["b","r"]),Na=hn(bn,["b","r"]),mn=hr.overflow||{},Lr=mn.adjustX,yr=mn.adjustY,Mr=mn.shiftX,Zr=mn.shiftY,Vn=function(rc){return typeof rc=="boolean"?rc:rc>=0},In,Kn,Mi,so;tl();var ro=Vn(yr),Ho=lu[0]===_c[0];if(ro&&lu[0]==="t"&&(Kn>Xi.bottom||Hi.current.bt)){var ya=Vt;Ho?ya-=zi-Lo:ya=un.y-Na.y-hs;var gs=Vs(at,ya),lo=Vs(at,ya,Yi);gs>gr||gs===gr&&(!fo||lo>=gn)?(Hi.current.bt=!0,Vt=ya,hs=-hs,Ci.points=[ln(lu,0),ln(_c,0)]):Hi.current.bt=!1}if(ro&&lu[0]==="b"&&(Ingr||Da===gr&&(!fo||ta>=gn)?(Hi.current.tb=!0,Vt=No,hs=-hs,Ci.points=[ln(lu,0),ln(_c,0)]):Hi.current.tb=!1}var Ra=Vn(Lr),ns=lu[1]===_c[1];if(Ra&&lu[1]==="l"&&(so>Xi.right||Hi.current.rl)){var Vo=at;ns?Vo-=Gi-eo:Vo=un.x-Na.x-Ea;var bs=Vs(Vo,Vt),Js=Vs(Vo,Vt,Yi);bs>gr||bs===gr&&(!fo||Js>=gn)?(Hi.current.rl=!0,at=Vo,Ea=-Ea,Ci.points=[ln(lu,1),ln(_c,1)]):Hi.current.rl=!1}if(Ra&&lu[1]==="r"&&(Migr||Of===gr&&(!fo||en>=gn)?(Hi.current.lr=!0,at=Hu,Ea=-Ea,Ci.points=[ln(lu,1),ln(_c,1)]):Hi.current.lr=!1}tl();var xn=Mr===!0?0:Mr;typeof xn=="number"&&(MiYi.right&&(at-=so-Yi.right-Ea,Tr.x>Yi.right-xn&&(at+=Tr.x-Yi.right+xn)));var Vi=Zr===!0?0:Zr;typeof Vi=="number"&&(InYi.bottom&&(Vt-=Kn-Yi.bottom-hs,Tr.y>Yi.bottom-Vi&&(Vt+=Tr.y-Yi.bottom+Vi)));var wi=bn.x+at,oo=wi+Gi,io=bn.y+Vt,Uo=io+zi,na=Tr.x,$a=na+eo,Co=Tr.y,wo=Co+Lo,Pa=Math.max(wi,na),ss=Math.min(oo,$a),si=(Pa+ss)/2,Ms=si-wi,Ns=Math.max(io,Co),Aa=Math.min(Uo,wo),qs=(Ns+Aa)/2,Eu=qs-io;Mo==null||Mo(li,Ci);var Cs=On.right-bn.x-(at+bn.width),su=On.bottom-bn.y-(Vt+bn.height);Fn({ready:!0,offsetX:at/gi,offsetY:Vt/ol,offsetR:Cs/gi,offsetB:su/ol,arrowX:Ms/gi,arrowY:Eu/ol,scaleX:gi,scaleY:ol,align:Ci})}}),xt=function(){zn.current+=1;var ir=zn.current;Promise.resolve().then(function(){zn.current===ir&&Fo()})},it=function(){Fn(function(ir){return(0,R.Z)((0,R.Z)({},ir),{},{ready:!1})})};return(0,we.Z)(it,[or]),(0,we.Z)(function(){sn||it()},[sn]),[ko.ready,ko.offsetX,ko.offsetY,ko.offsetR,ko.offsetB,ko.arrowX,ko.arrowY,ko.scaleX,ko.scaleY,ko.align,xt]}var Nn=A(49397);function $n(sn,li,En,or,qi){(0,we.Z)(function(){if(sn&&li&&En){let zn=function(){or(),qi()};var Bo=li,Mo=En,Wi=We(Bo),Ii=We(Mo),ko=ot(Mo),Fn=new Set([ko].concat((0,Nn.Z)(Wi),(0,Nn.Z)(Ii)));return Fn.forEach(function(Un){Un.addEventListener("scroll",zn,{passive:!0})}),ko.addEventListener("resize",zn,{passive:!0}),or(),function(){Fn.forEach(function(Un){Un.removeEventListener("scroll",zn),ko.removeEventListener("resize",zn)})}}},[sn,li,En])}var _i=A(36014),Qn=A(90571);function Ji(sn,li,En,or,qi,Bo,Mo,Wi){var Ii=qe.useRef(sn),ko=qe.useRef(!1);Ii.current!==sn&&(ko.current=!0,Ii.current=sn),qe.useEffect(function(){var Fn=(0,Qn.Z)(function(){ko.current=!1});return function(){Qn.Z.cancel(Fn)}},[sn]),qe.useEffect(function(){if(li&&or&&(!qi||Bo)){var Fn=function(){var je=!1,$e=function(Jt){var ar=Jt.target;je=Mo(ar)},At=function(Jt){var ar=Jt.target;!ko.current&&Ii.current&&!je&&!Mo(ar)&&Wi(!1)};return[$e,At]},zn=Fn(),Un=(0,V.Z)(zn,2),Hi=Un[0],Ki=Un[1],Fo=Fn(),xt=(0,V.Z)(Fo,2),it=xt[0],kt=xt[1],ir=ot(or);ir.addEventListener("mousedown",Hi,!0),ir.addEventListener("click",Ki,!0),ir.addEventListener("contextmenu",Ki,!0);var Pr=(0,ce.A)(En);if(Pr&&(Pr.addEventListener("mousedown",it,!0),Pr.addEventListener("click",kt,!0),Pr.addEventListener("contextmenu",kt,!0)),!1)var kr,An,Dn,Ht;return function(){ir.removeEventListener("mousedown",Hi,!0),ir.removeEventListener("click",Ki,!0),ir.removeEventListener("contextmenu",Ki,!0),Pr&&(Pr.removeEventListener("mousedown",it,!0),Pr.removeEventListener("click",kt,!0),Pr.removeEventListener("contextmenu",kt,!0))}}},[li,En,or,qi,Bo])}var ni=["prefixCls","children","action","showAction","hideAction","popupVisible","defaultPopupVisible","onPopupVisibleChange","afterPopupVisibleChange","mouseEnterDelay","mouseLeaveDelay","focusDelay","blurDelay","mask","maskClosable","getPopupContainer","forceRender","autoDestroy","destroyPopupOnHide","popup","popupClassName","popupStyle","popupPlacement","builtinPlacements","popupAlign","zIndex","stretch","getPopupClassNameFromAlign","fresh","alignPoint","onPopupClick","onPopupAlign","arrow","popupMotion","maskMotion","popupTransitionName","popupAnimation","maskTransitionName","maskAnimation","className","getTriggerDOMNode"];function Ei(){var sn=arguments.length>0&&arguments[0]!==void 0?arguments[0]:p.Z,li=qe.forwardRef(function(En,or){var qi=En.prefixCls,Bo=qi===void 0?"rc-trigger-popup":qi,Mo=En.children,Wi=En.action,Ii=Wi===void 0?"hover":Wi,ko=En.showAction,Fn=En.hideAction,zn=En.popupVisible,Un=En.defaultPopupVisible,Hi=En.onPopupVisibleChange,Ki=En.afterPopupVisibleChange,Fo=En.mouseEnterDelay,xt=En.mouseLeaveDelay,it=xt===void 0?.1:xt,kt=En.focusDelay,ir=En.blurDelay,Pr=En.mask,kr=En.maskClosable,An=kr===void 0?!0:kr,Dn=En.getPopupContainer,Ht=En.forceRender,Lt=En.autoDestroy,je=En.destroyPopupOnHide,$e=En.popup,At=En.popupClassName,Bt=En.popupStyle,Jt=En.popupPlacement,ar=En.builtinPlacements,hr=ar===void 0?{}:ar,Gt=En.popupAlign,Tr=En.zIndex,nn=En.stretch,bn=En.getPopupClassNameFromAlign,Bi=En.fresh,on=En.alignPoint,dn=En.onPopupClick,ri=En.onPopupAlign,Wn=En.arrow,Rn=En.popupMotion,di=En.maskMotion,zi=En.popupTransitionName,Gi=En.popupAnimation,Lo=En.maskTransitionName,eo=En.maskAnimation,ba=En.className,va=En.getTriggerDOMNode,Do=(0,y.Z)(En,ni),Ps=Lt||je||!1,Nr=qe.useState(!1),fo=(0,V.Z)(Nr,2),hi=fo[0],Yi=fo[1];(0,we.Z)(function(){Yi((0,Ee.Z)())},[]);var ga=qe.useRef({}),Xi=qe.useContext(pt),On=qe.useMemo(function(){return{registerSubPopup:function(ps,xl){ga.current[ps]=xl,Xi==null||Xi.registerSubPopup(ps,xl)}}},[Xi]),gi=(0,De.Z)(),ol=qe.useState(null),ks=(0,V.Z)(ol,2),as=ks[0],_s=ks[1],Ks=(0,le.Z)(function(Qo){(0,ae.S)(Qo)&&as!==Qo&&_s(Qo),Xi==null||Xi.registerSubPopup(gi,Qo)}),Ea=qe.useState(null),hs=(0,V.Z)(Ea,2),Ju=hs[0],Fa=hs[1],dc=qe.useRef(null),el=(0,le.Z)(function(Qo){(0,ae.S)(Qo)&&Ju!==Qo&&(Fa(Qo),dc.current=Qo)}),fl=qe.Children.only(Mo),As=(fl==null?void 0:fl.props)||{},Rl={},dl=(0,le.Z)(function(Qo){var ps,xl,Yl=Ju;return(Yl==null?void 0:Yl.contains(Qo))||((ps=(0,ce.A)(Yl))===null||ps===void 0?void 0:ps.host)===Qo||Qo===Yl||(as==null?void 0:as.contains(Qo))||((xl=(0,ce.A)(as))===null||xl===void 0?void 0:xl.host)===Qo||Qo===as||Object.values(ga.current).some(function(ul){return(ul==null?void 0:ul.contains(Qo))||Qo===ul})}),_c=mt(Bo,Rn,Gi,zi),lu=mt(Bo,di,eo,Lo),Pn=qe.useState(Un||!1),Wr=(0,V.Z)(Pn,2),Ci=Wr[0],at=Wr[1],Vt=zn!=null?zn:Ci,gr=(0,le.Z)(function(Qo){zn===void 0&&at(Qo)});(0,we.Z)(function(){at(zn||!1)},[zn]);var gn=qe.useRef(Vt);gn.current=Vt;var un=qe.useRef([]);un.current=[];var Zi=(0,le.Z)(function(Qo){var ps;gr(Qo),((ps=un.current[un.current.length-1])!==null&&ps!==void 0?ps:Vt)!==Qo&&(un.current.push(Qo),Hi==null||Hi(Qo))}),ho=qe.useRef(),Na=function(){clearTimeout(ho.current)},mn=function(ps){var xl=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;Na(),xl===0?Zi(ps):ho.current=setTimeout(function(){Zi(ps)},xl*1e3)};qe.useEffect(function(){return Na},[]);var Lr=qe.useState(!1),yr=(0,V.Z)(Lr,2),Mr=yr[0],Zr=yr[1];(0,we.Z)(function(Qo){(!Qo||Vt)&&Zr(!0)},[Vt]);var Vn=qe.useState(null),In=(0,V.Z)(Vn,2),Kn=In[0],Mi=In[1],so=qe.useState([0,0]),ro=(0,V.Z)(so,2),Ho=ro[0],ya=ro[1],gs=function(ps){ya([ps.clientX,ps.clientY])},lo=oi(Vt,as,on?Ho:Ju,Jt,hr,Gt,ri),No=(0,V.Z)(lo,11),Da=No[0],ta=No[1],Ra=No[2],ns=No[3],Vo=No[4],bs=No[5],Js=No[6],Hu=No[7],Of=No[8],en=No[9],xn=No[10],Vi=ft(hi,Ii,ko,Fn),wi=(0,V.Z)(Vi,2),oo=wi[0],io=wi[1],Uo=oo.has("click"),na=io.has("click")||io.has("contextMenu"),$a=(0,le.Z)(function(){Mr||xn()}),Co=function(){gn.current&&on&&na&&mn(!1)};$n(Vt,Ju,as,$a,Co),(0,we.Z)(function(){$a()},[Ho,Jt]),(0,we.Z)(function(){Vt&&!(hr!=null&&hr[Jt])&&$a()},[JSON.stringify(Gt)]);var wo=qe.useMemo(function(){var Qo=Ft(hr,Bo,en,on);return X()(Qo,bn==null?void 0:bn(en))},[en,bn,hr,Bo,on]);qe.useImperativeHandle(or,function(){return{nativeElement:dc.current,forceAlign:$a}});var Pa=qe.useState(0),ss=(0,V.Z)(Pa,2),si=ss[0],Ms=ss[1],Ns=qe.useState(0),Aa=(0,V.Z)(Ns,2),qs=Aa[0],Eu=Aa[1],Cs=function(){if(nn&&Ju){var ps=Ju.getBoundingClientRect();Ms(ps.width),Eu(ps.height)}},su=function(){Cs(),$a()},Vs=function(ps){Zr(!1),xn(),Ki==null||Ki(ps)},tl=function(){return new Promise(function(ps){Cs(),Mi(function(){return ps})})};(0,we.Z)(function(){Kn&&(xn(),Kn(),Mi(null))},[Kn]);function Xs(Qo,ps,xl,Yl){Rl[Qo]=function(ul){var Ef;Yl==null||Yl(ul),mn(ps,xl);for(var sf=arguments.length,Hf=new Array(sf>1?sf-1:0),Ul=1;Ul1?xl-1:0),ul=1;ul1?xl-1:0),ul=1;ulX[0]&&($[0]=X[0]),$[1]>X[1]&&($[1]=X[1]),$[2]=0))throw new Error("precision must be a positive number");var Ke=Math.pow(10,pt||0);return Math.round(et*Ke)/Ke}ye.round=Ee;function qe(et,pt){pt===void 0&&(pt="kilometers");var Ke=ye.factors[pt];if(!Ke)throw new Error(pt+" units is invalid");return et*Ke}ye.radiansToLength=qe;function Ge(et,pt){pt===void 0&&(pt="kilometers");var Ke=ye.factors[pt];if(!Ke)throw new Error(pt+" units is invalid");return et/Ke}ye.lengthToRadians=Ge;function ct(et,pt){return ut(Ge(et,pt))}ye.lengthToDegrees=ct;function Ve(et){var pt=et%360;return pt<0&&(pt+=360),pt}ye.bearingToAzimuth=Ve;function ut(et){var pt=et%(2*Math.PI);return pt*180/Math.PI}ye.radiansToDegrees=ut;function Xe(et){var pt=et%360;return pt*Math.PI/180}ye.degreesToRadians=Xe;function Rt(et,pt,Ke){if(pt===void 0&&(pt="kilometers"),Ke===void 0&&(Ke="kilometers"),!(et>=0))throw new Error("length must be a positive number");return qe(Ge(et,pt),Ke)}ye.convertLength=Rt;function gt(et,pt,Ke){if(pt===void 0&&(pt="meters"),Ke===void 0&&(Ke="kilometers"),!(et>=0))throw new Error("area must be a positive number");var ft=ye.areaFactors[pt];if(!ft)throw new Error("invalid original units");var wt=ye.areaFactors[Ke];if(!wt)throw new Error("invalid final units");return et/ft*wt}ye.convertArea=gt;function Ct(et){return!isNaN(et)&&et!==null&&!Array.isArray(et)}ye.isNumber=Ct;function tt(et){return!!et&&et.constructor===Object}ye.isObject=tt;function Ne(et){if(!et)throw new Error("bbox is required");if(!Array.isArray(et))throw new Error("bbox must be an Array");if(et.length!==4&&et.length!==6)throw new Error("bbox must be an Array of 4 or 6 numbers");et.forEach(function(pt){if(!Ct(pt))throw new Error("bbox must only contain numbers")})}ye.validateBBox=Ne;function bt(et){if(!et)throw new Error("id is required");if(["string","number"].indexOf(typeof et)===-1)throw new Error("id must be a number or a string")}ye.validateId=bt},9750:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0});var R=A(78161);function V(Xe,Rt,gt){if(Xe!==null)for(var Ct,tt,Ne,bt,et,pt,Ke,ft=0,wt=0,Se,Ft=Xe.type,mt=Ft==="FeatureCollection",ot=Ft==="Feature",We=mt?Xe.features.length:1,Me=0;Mept||mt>Ke||ot>ft){et=wt,pt=Ct,Ke=mt,ft=ot,Ne=0;return}var We=R.lineString([et,wt],gt.properties);if(Rt(We,Ct,tt,ot,Ne)===!1)return!1;Ne++,et=wt})===!1)return!1}}})}function qe(Xe,Rt,gt){var Ct=gt,tt=!1;return Ee(Xe,function(Ne,bt,et,pt,Ke){tt===!1&>===void 0?Ct=Ne:Ct=Rt(Ct,Ne,bt,et,pt,Ke),tt=!0}),Ct}function Ge(Xe,Rt){if(!Xe)throw new Error("geojson is required");De(Xe,function(gt,Ct,tt){if(gt.geometry!==null){var Ne=gt.geometry.type,bt=gt.geometry.coordinates;switch(Ne){case"LineString":if(Rt(gt,Ct,tt,0,0)===!1)return!1;break;case"Polygon":for(var et=0;etR.createElement(y.ZP,{theme:{token:{motion:!1,zIndexPopupBase:0}}},R.createElement(se,Object.assign({},ae)))}const X=(se,ae,ce,le)=>$(we=>{const{prefixCls:Ee,style:qe}=we,Ge=R.useRef(null),[ct,Ve]=R.useState(0),[ut,Xe]=R.useState(0),[Rt,gt]=(0,V.Z)(!1,{value:we.open}),{getPrefixCls:Ct}=R.useContext(p.E_),tt=Ct(ae||"select",Ee);R.useEffect(()=>{if(gt(!0),typeof ResizeObserver!="undefined"){const et=new ResizeObserver(Ke=>{const ft=Ke[0].target;Ve(ft.offsetHeight+8),Xe(ft.offsetWidth)}),pt=setInterval(()=>{var Ke;const ft=ce?`.${ce(tt)}`:`.${tt}-dropdown`,wt=(Ke=Ge.current)===null||Ke===void 0?void 0:Ke.querySelector(ft);wt&&(clearInterval(pt),et.observe(wt))},10);return()=>{clearInterval(pt),et.disconnect()}}},[]);let Ne=Object.assign(Object.assign({},we),{style:Object.assign(Object.assign({},qe),{margin:0}),open:Rt,visible:Rt,getPopupContainer:()=>Ge.current});le&&(Ne=le(Ne));const bt={paddingBottom:ct,position:"relative",minWidth:ut};return R.createElement("div",{ref:Ge,style:bt},R.createElement(se,Object.assign({},Ne)))});ye.Z=X},66187:function(Ye,ye,A){"use strict";A.d(ye,{Cn:function(){return le},u6:function(){return X}});var R=A(77617),V=A(20573),y=A(53843);const p=100,X=p*10,se={Modal:p,Drawer:p,Popover:p,Popconfirm:p,Tooltip:p,Tour:p},ae={SelectLike:50,Dropdown:50,DatePicker:50,Menu:50,ImagePreview:1};function ce(De){return De in se}function le(De,we){const[,Ee]=(0,V.ZP)(),qe=R.useContext(y.Z),Ge=ce(De);if(we!==void 0)return[we,we];let ct=qe!=null?qe:0;return Ge?(ct+=(qe?0:Ee.zIndexPopupBase)+se[De],ct=Math.min(ct,Ee.zIndexPopupBase+X)):ct+=ae[De],[qe===void 0?we:ct,ct]}},47562:function(Ye,ye,A){"use strict";A.d(ye,{m:function(){return se}});const R=()=>({height:0,opacity:0}),V=ce=>{const{scrollHeight:le}=ce;return{height:le,opacity:1}},y=ce=>({height:ce?ce.offsetHeight:0}),p=(ce,le)=>(le==null?void 0:le.deadline)===!0||le.propertyName==="height",$=function(){return{motionName:`${arguments.length>0&&arguments[0]!==void 0?arguments[0]:"ant"}-motion-collapse`,onAppearStart:R,onEnterStart:R,onAppearActive:V,onEnterActive:V,onLeaveStart:y,onLeaveActive:R,onAppearEnd:p,onEnterEnd:p,onLeaveEnd:p,motionDeadline:500}},X=null,se=(ce,le,De)=>De!==void 0?De:`${ce}-${le}`;var ae=null},48894:function(Ye,ye,A){"use strict";var R;A.d(ye,{M2:function(){return p},Tm:function(){return X},l$:function(){return y}});var V=A(77617);const{isValidElement:y}=R||(R=A.t(V,2));function p(se){return se&&y(se)&&se.type===V.Fragment}function $(se,ae,ce){return y(se)?V.cloneElement(se,typeof ce=="function"?ce(se.props||{}):ce):ae}function X(se,ae){return $(se,se,ae)}},58068:function(Ye,ye,A){"use strict";A.d(ye,{G8:function(){return se},ln:function(){return ae}});var R=A(77617),V=A(36014);function y(){}let p=null;function $(){p=null,rcResetWarned()}let X=null;const se=R.createContext({}),ae=()=>{const le=()=>{};return le.deprecated=y,le};var ce=null},68306:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return et}});var R=A(92310),V=A.n(R),y=A(88831),p=A(95077),$=A(77617),X=A(11908),se=A(48894),ae=A(93319);const ce=pt=>{const{componentCls:Ke,colorPrimary:ft}=pt;return{[Ke]:{position:"absolute",background:"transparent",pointerEvents:"none",boxSizing:"border-box",color:`var(--wave-color, ${ft})`,boxShadow:"0 0 0 0 currentcolor",opacity:.2,"&.wave-motion-appear":{transition:[`box-shadow 0.4s ${pt.motionEaseOutCirc}`,`opacity 2s ${pt.motionEaseOutCirc}`].join(","),"&-active":{boxShadow:"0 0 0 6px currentcolor",opacity:0},"&.wave-quick":{transition:[`box-shadow 0.3s ${pt.motionEaseInOut}`,`opacity 0.35s ${pt.motionEaseInOut}`].join(",")}}}}};var le=(0,ae.ZP)("Wave",pt=>[ce(pt)]),De=A(33401),we=A(90571),Ee=A(44516),qe=A(41522);function Ge(pt){const Ke=(pt||"").match(/rgba?\((\d*), (\d*), (\d*)(, [\d.]*)?\)/);return Ke&&Ke[1]&&Ke[2]&&Ke[3]?!(Ke[1]===Ke[2]&&Ke[2]===Ke[3]):!0}function ct(pt){return pt&&pt!=="#fff"&&pt!=="#ffffff"&&pt!=="rgb(255, 255, 255)"&&pt!=="rgba(255, 255, 255, 1)"&&Ge(pt)&&!/rgba\((?:\d*, ){3}0\)/.test(pt)&&pt!=="transparent"}function Ve(pt){const{borderTopColor:Ke,borderColor:ft,backgroundColor:wt}=getComputedStyle(pt);return ct(Ke)?Ke:ct(ft)?ft:ct(wt)?wt:null}var ut=A(10946);function Xe(pt){return Number.isNaN(pt)?0:pt}const Rt=pt=>{const{className:Ke,target:ft,component:wt}=pt,Se=$.useRef(null),[Ft,mt]=$.useState(null),[ot,We]=$.useState([]),[Me,st]=$.useState(0),[Qe,dr]=$.useState(0),[Kt,Yr]=$.useState(0),[hn,ln]=$.useState(0),[oi,Nn]=$.useState(!1),$n={left:Me,top:Qe,width:Kt,height:hn,borderRadius:ot.map(Ji=>`${Ji}px`).join(" ")};Ft&&($n["--wave-color"]=Ft);function _i(){const Ji=getComputedStyle(ft);mt(Ve(ft));const ni=Ji.position==="static",{borderLeftWidth:Ei,borderTopWidth:xo}=Ji;st(ni?ft.offsetLeft:Xe(-parseFloat(Ei))),dr(ni?ft.offsetTop:Xe(-parseFloat(xo))),Yr(ft.offsetWidth),ln(ft.offsetHeight);const{borderTopLeftRadius:sn,borderTopRightRadius:li,borderBottomLeftRadius:En,borderBottomRightRadius:or}=Ji;We([sn,li,or,En].map(qi=>Xe(parseFloat(qi))))}if($.useEffect(()=>{if(ft){const Ji=(0,we.Z)(()=>{_i(),Nn(!0)});let ni;return typeof ResizeObserver!="undefined"&&(ni=new ResizeObserver(_i),ni.observe(ft)),()=>{we.Z.cancel(Ji),ni==null||ni.disconnect()}}},[]),!oi)return null;const Qn=(wt==="Checkbox"||wt==="Radio")&&(ft==null?void 0:ft.classList.contains(ut.A));return $.createElement(Ee.ZP,{visible:!0,motionAppear:!0,motionName:"wave-motion",motionDeadline:5e3,onAppearEnd:(Ji,ni)=>{var Ei;if(ni.deadline||ni.propertyName==="opacity"){const xo=(Ei=Se.current)===null||Ei===void 0?void 0:Ei.parentElement;(0,qe.v)(xo).then(()=>{xo==null||xo.remove()})}return!1}},Ji=>{let{className:ni}=Ji;return $.createElement("div",{ref:Se,className:V()(Ke,{"wave-quick":Qn},ni),style:$n})})};var Ct=(pt,Ke)=>{var ft;const{component:wt}=Ke;if(wt==="Checkbox"&&!(!((ft=pt.querySelector("input"))===null||ft===void 0)&&ft.checked))return;const Se=document.createElement("div");Se.style.position="absolute",Se.style.left="0px",Se.style.top="0px",pt==null||pt.insertBefore(Se,pt==null?void 0:pt.firstChild),(0,qe.s)($.createElement(Rt,Object.assign({},Ke,{target:pt})),Se)},tt=A(20573);function Ne(pt,Ke,ft){const{wave:wt}=$.useContext(X.E_),[,Se,Ft]=(0,tt.ZP)(),mt=(0,De.zX)(Me=>{const st=pt.current;if(wt!=null&&wt.disabled||!st)return;const Qe=st.querySelector(`.${ut.A}`)||st,{showEffect:dr}=wt||{};(dr||Ct)(Qe,{className:Ke,token:Se,component:ft,event:Me,hashId:Ft})}),ot=$.useRef();return Me=>{we.Z.cancel(ot.current),ot.current=(0,we.Z)(()=>{mt(Me)})}}var et=pt=>{const{children:Ke,disabled:ft,component:wt}=pt,{getPrefixCls:Se}=(0,$.useContext)(X.E_),Ft=(0,$.useRef)(null),mt=Se("wave"),[,ot]=le(mt),We=Ne(Ft,V()(mt,ot),wt);if($.useEffect(()=>{const st=Ft.current;if(!st||st.nodeType!==1||ft)return;const Qe=dr=>{!(0,p.Z)(dr.target)||!st.getAttribute||st.getAttribute("disabled")||st.disabled||st.className.includes("disabled")||st.className.includes("-leave")||We(dr)};return st.addEventListener("click",Qe,!0),()=>{st.removeEventListener("click",Qe,!0)}},[ft]),!$.isValidElement(Ke))return Ke!=null?Ke:null;const Me=(0,y.Yr)(Ke)?(0,y.sQ)(Ke.ref,Ft):Ft;return(0,se.Tm)(Ke,{ref:Me})}},10946:function(Ye,ye,A){"use strict";A.d(ye,{A:function(){return R}});const R="ant-wave-target"},53843:function(Ye,ye,A){"use strict";var R=A(77617);const V=R.createContext(void 0);ye.Z=V},16380:function(Ye,ye,A){"use strict";A.d(ye,{Te:function(){return se},aG:function(){return p},hU:function(){return ce},nx:function(){return $}});var R=A(77617),V=A(48894);const y=/^[\u4e00-\u9fa5]{2}$/,p=y.test.bind(y);function $(Ee){return Ee==="danger"?{danger:!0}:{type:Ee}}function X(Ee){return typeof Ee=="string"}function se(Ee){return Ee==="text"||Ee==="link"}function ae(Ee,qe){if(Ee==null)return;const Ge=qe?" ":"";return typeof Ee!="string"&&typeof Ee!="number"&&X(Ee.type)&&p(Ee.props.children)?(0,V.Tm)(Ee,{children:Ee.props.children.split("").join(Ge)}):X(Ee)?p(Ee)?R.createElement("span",null,Ee.split("").join(Ge)):R.createElement("span",null,Ee):(0,V.M2)(Ee)?R.createElement("span",null,Ee):Ee}function ce(Ee,qe){let Ge=!1;const ct=[];return R.Children.forEach(Ee,Ve=>{const ut=typeof Ve,Xe=ut==="string"||ut==="number";if(Ge&&Xe){const Rt=ct.length-1,gt=ct[Rt];ct[Rt]=`${gt}${Ve}`}else ct.push(Ve);Ge=Xe}),R.Children.map(ct,Ve=>ae(Ve,qe))}const le=null,De=null,we=null},10409:function(Ye,ye,A){"use strict";A.d(ye,{ZP:function(){return Fo}});var R=A(77617),V=A(92310),y=A.n(V),p=A(99468),$=A(88831),X=A(68306),se=A(11908),ae=A(50138),ce=A(15550),le=A(53580),De=A(20573),we=function(xt,it){var kt={};for(var ir in xt)Object.prototype.hasOwnProperty.call(xt,ir)&&it.indexOf(ir)<0&&(kt[ir]=xt[ir]);if(xt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Pr=0,ir=Object.getOwnPropertySymbols(xt);Pr{const{getPrefixCls:it,direction:kt}=R.useContext(se.E_),{prefixCls:ir,size:Pr,className:kr}=xt,An=we(xt,["prefixCls","size","className"]),Dn=it("btn-group",ir),[,,Ht]=(0,De.ZP)();let Lt="";switch(Pr){case"large":Lt="lg";break;case"small":Lt="sm";break;case"middle":default:}const je=y()(Dn,{[`${Dn}-${Lt}`]:Lt,[`${Dn}-rtl`]:kt==="rtl"},kr,Ht);return R.createElement(Ee.Provider,{value:Pr},R.createElement("div",Object.assign({},An,{className:je})))},ct=A(16380),ut=(0,R.forwardRef)((xt,it)=>{const{className:kt,style:ir,children:Pr,prefixCls:kr}=xt,An=y()(`${kr}-icon`,kt);return R.createElement("span",{ref:it,className:An,style:ir},Pr)}),Xe=A(20555),Rt=A(44516);const gt=(0,R.forwardRef)((xt,it)=>{let{prefixCls:kt,className:ir,style:Pr,iconClassName:kr}=xt;const An=y()(`${kt}-loading-icon`,ir);return R.createElement(ut,{prefixCls:kt,className:An,style:Pr,ref:it},R.createElement(Xe.Z,{className:kr}))}),Ct=()=>({width:0,opacity:0,transform:"scale(0)"}),tt=xt=>({width:xt.scrollWidth,opacity:1,transform:"scale(1)"});var bt=xt=>{const{prefixCls:it,loading:kt,existIcon:ir,className:Pr,style:kr}=xt,An=!!kt;return ir?R.createElement(gt,{prefixCls:it,className:Pr,style:kr}):R.createElement(Rt.ZP,{visible:An,motionName:`${it}-loading-icon-motion`,motionLeave:An,removeOnLeave:!0,onAppearStart:Ct,onAppearActive:tt,onEnterStart:Ct,onEnterActive:tt,onLeaveStart:tt,onLeaveActive:Ct},(Dn,Ht)=>{let{className:Lt,style:je}=Dn;return R.createElement(gt,{prefixCls:it,className:Pr,style:Object.assign(Object.assign({},kr),je),ref:Ht,iconClassName:Lt})})},et=A(78600),pt=A(75199),Ke=A(12228),ft=A(93319);const wt=(xt,it)=>({[`> span, > ${xt}`]:{"&:not(:last-child)":{[`&, & > ${xt}`]:{"&:not(:disabled)":{borderInlineEndColor:it}}},"&:not(:first-child)":{[`&, & > ${xt}`]:{"&:not(:disabled)":{borderInlineStartColor:it}}}}});var Ft=xt=>{const{componentCls:it,fontSize:kt,lineWidth:ir,groupBorderColor:Pr,colorErrorHover:kr}=xt;return{[`${it}-group`]:[{position:"relative",display:"inline-flex",[`> span, > ${it}`]:{"&:not(:last-child)":{[`&, & > ${it}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},"&:not(:first-child)":{marginInlineStart:xt.calc(ir).mul(-1).equal(),[`&, & > ${it}`]:{borderStartStartRadius:0,borderEndStartRadius:0}}},[it]:{position:"relative",zIndex:1,[`&:hover, + &:focus, + &:active`]:{zIndex:2},"&[disabled]":{zIndex:0}},[`${it}-icon-only`]:{fontSize:kt}},wt(`${it}-primary`,Pr),wt(`${it}-danger`,kr)]}},mt=A(10176);const ot=xt=>{const{paddingInline:it,onlyIconSize:kt,paddingBlock:ir}=xt;return(0,Ke.TS)(xt,{buttonPaddingHorizontal:it,buttonPaddingVertical:ir,buttonIconOnlyFontSize:kt})},We=xt=>{var it,kt,ir,Pr,kr,An;const Dn=(it=xt.contentFontSize)!==null&&it!==void 0?it:xt.fontSize,Ht=(kt=xt.contentFontSizeSM)!==null&&kt!==void 0?kt:xt.fontSize,Lt=(ir=xt.contentFontSizeLG)!==null&&ir!==void 0?ir:xt.fontSizeLG,je=(Pr=xt.contentLineHeight)!==null&&Pr!==void 0?Pr:(0,mt.D)(Dn),$e=(kr=xt.contentLineHeightSM)!==null&&kr!==void 0?kr:(0,mt.D)(Ht),At=(An=xt.contentLineHeightLG)!==null&&An!==void 0?An:(0,mt.D)(Lt);return{fontWeight:400,defaultShadow:`0 ${xt.controlOutlineWidth}px 0 ${xt.controlTmpOutline}`,primaryShadow:`0 ${xt.controlOutlineWidth}px 0 ${xt.controlOutline}`,dangerShadow:`0 ${xt.controlOutlineWidth}px 0 ${xt.colorErrorOutline}`,primaryColor:xt.colorTextLightSolid,dangerColor:xt.colorTextLightSolid,borderColorDisabled:xt.colorBorder,defaultGhostColor:xt.colorBgContainer,ghostBg:"transparent",defaultGhostBorderColor:xt.colorBgContainer,paddingInline:xt.paddingContentHorizontal-xt.lineWidth,paddingInlineLG:xt.paddingContentHorizontal-xt.lineWidth,paddingInlineSM:8-xt.lineWidth,onlyIconSize:xt.fontSizeLG,onlyIconSizeSM:xt.fontSizeLG-2,onlyIconSizeLG:xt.fontSizeLG+2,groupBorderColor:xt.colorPrimaryHover,linkHoverBg:"transparent",textHoverBg:xt.colorBgTextHover,defaultColor:xt.colorText,defaultBg:xt.colorBgContainer,defaultBorderColor:xt.colorBorder,defaultBorderColorDisabled:xt.colorBorder,defaultHoverBg:xt.colorBgContainer,defaultHoverColor:xt.colorPrimaryHover,defaultHoverBorderColor:xt.colorPrimaryHover,defaultActiveBg:xt.colorBgContainer,defaultActiveColor:xt.colorPrimaryActive,defaultActiveBorderColor:xt.colorPrimaryActive,contentFontSize:Dn,contentFontSizeSM:Ht,contentFontSizeLG:Lt,contentLineHeight:je,contentLineHeightSM:$e,contentLineHeightLG:At,paddingBlock:Math.max((xt.controlHeight-Dn*je)/2-xt.lineWidth,0),paddingBlockSM:Math.max((xt.controlHeightSM-Ht*$e)/2-xt.lineWidth,0),paddingBlockLG:Math.max((xt.controlHeightLG-Lt*At)/2-xt.lineWidth,0)}},Me=xt=>{const{componentCls:it,iconCls:kt,fontWeight:ir}=xt;return{[it]:{outline:"none",position:"relative",display:"inline-block",fontWeight:ir,whiteSpace:"nowrap",textAlign:"center",backgroundImage:"none",background:"transparent",border:`${(0,et.bf)(xt.lineWidth)} ${xt.lineType} transparent`,cursor:"pointer",transition:`all ${xt.motionDurationMid} ${xt.motionEaseInOut}`,userSelect:"none",touchAction:"manipulation",color:xt.colorText,"&:disabled > *":{pointerEvents:"none"},"> span":{display:"inline-block"},[`${it}-icon`]:{lineHeight:0},[`> ${kt} + span, > span + ${kt}`]:{marginInlineStart:xt.marginXS},[`&:not(${it}-icon-only) > ${it}-icon`]:{[`&${it}-loading-icon, &:not(:last-child)`]:{marginInlineEnd:xt.marginXS}},"> a":{color:"currentColor"},"&:not(:disabled)":Object.assign({},(0,pt.Qy)(xt)),[`&${it}-two-chinese-chars::first-letter`]:{letterSpacing:"0.34em"},[`&${it}-two-chinese-chars > *:not(${kt})`]:{marginInlineEnd:"-0.34em",letterSpacing:"0.34em"},[`&-icon-only${it}-compact-item`]:{flex:"none"}}}},st=(xt,it,kt)=>({[`&:not(:disabled):not(${xt}-disabled)`]:{"&:hover":it,"&:active":kt}}),Qe=xt=>({minWidth:xt.controlHeight,paddingInlineStart:0,paddingInlineEnd:0,borderRadius:"50%"}),dr=xt=>({borderRadius:xt.controlHeight,paddingInlineStart:xt.calc(xt.controlHeight).div(2).equal(),paddingInlineEnd:xt.calc(xt.controlHeight).div(2).equal()}),Kt=xt=>({cursor:"not-allowed",borderColor:xt.borderColorDisabled,color:xt.colorTextDisabled,background:xt.colorBgContainerDisabled,boxShadow:"none"}),Yr=(xt,it,kt,ir,Pr,kr,An,Dn)=>({[`&${xt}-background-ghost`]:Object.assign(Object.assign({color:kt||void 0,background:it,borderColor:ir||void 0,boxShadow:"none"},st(xt,Object.assign({background:it},An),Object.assign({background:it},Dn))),{"&:disabled":{cursor:"not-allowed",color:Pr||void 0,borderColor:kr||void 0}})}),hn=xt=>({[`&:disabled, &${xt.componentCls}-disabled`]:Object.assign({},Kt(xt))}),ln=xt=>Object.assign({},hn(xt)),oi=xt=>({[`&:disabled, &${xt.componentCls}-disabled`]:{cursor:"not-allowed",color:xt.colorTextDisabled}}),Nn=xt=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},ln(xt)),{background:xt.defaultBg,borderColor:xt.defaultBorderColor,color:xt.defaultColor,boxShadow:xt.defaultShadow}),st(xt.componentCls,{color:xt.defaultHoverColor,borderColor:xt.defaultHoverBorderColor,background:xt.defaultHoverBg},{color:xt.defaultActiveColor,borderColor:xt.defaultActiveBorderColor,background:xt.defaultActiveBg})),Yr(xt.componentCls,xt.ghostBg,xt.defaultGhostColor,xt.defaultGhostBorderColor,xt.colorTextDisabled,xt.colorBorder)),{[`&${xt.componentCls}-dangerous`]:Object.assign(Object.assign(Object.assign({color:xt.colorError,borderColor:xt.colorError},st(xt.componentCls,{color:xt.colorErrorHover,borderColor:xt.colorErrorBorderHover},{color:xt.colorErrorActive,borderColor:xt.colorErrorActive})),Yr(xt.componentCls,xt.ghostBg,xt.colorError,xt.colorError,xt.colorTextDisabled,xt.colorBorder)),hn(xt))}),$n=xt=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},ln(xt)),{color:xt.primaryColor,background:xt.colorPrimary,boxShadow:xt.primaryShadow}),st(xt.componentCls,{color:xt.colorTextLightSolid,background:xt.colorPrimaryHover},{color:xt.colorTextLightSolid,background:xt.colorPrimaryActive})),Yr(xt.componentCls,xt.ghostBg,xt.colorPrimary,xt.colorPrimary,xt.colorTextDisabled,xt.colorBorder,{color:xt.colorPrimaryHover,borderColor:xt.colorPrimaryHover},{color:xt.colorPrimaryActive,borderColor:xt.colorPrimaryActive})),{[`&${xt.componentCls}-dangerous`]:Object.assign(Object.assign(Object.assign({background:xt.colorError,boxShadow:xt.dangerShadow,color:xt.dangerColor},st(xt.componentCls,{background:xt.colorErrorHover},{background:xt.colorErrorActive})),Yr(xt.componentCls,xt.ghostBg,xt.colorError,xt.colorError,xt.colorTextDisabled,xt.colorBorder,{color:xt.colorErrorHover,borderColor:xt.colorErrorHover},{color:xt.colorErrorActive,borderColor:xt.colorErrorActive})),hn(xt))}),_i=xt=>Object.assign(Object.assign({},Nn(xt)),{borderStyle:"dashed"}),Qn=xt=>Object.assign(Object.assign(Object.assign({color:xt.colorLink},st(xt.componentCls,{color:xt.colorLinkHover,background:xt.linkHoverBg},{color:xt.colorLinkActive})),oi(xt)),{[`&${xt.componentCls}-dangerous`]:Object.assign(Object.assign({color:xt.colorError},st(xt.componentCls,{color:xt.colorErrorHover},{color:xt.colorErrorActive})),oi(xt))}),Ji=xt=>Object.assign(Object.assign(Object.assign({},st(xt.componentCls,{color:xt.colorText,background:xt.textHoverBg},{color:xt.colorText,background:xt.colorBgTextActive})),oi(xt)),{[`&${xt.componentCls}-dangerous`]:Object.assign(Object.assign({color:xt.colorError},oi(xt)),st(xt.componentCls,{color:xt.colorErrorHover,background:xt.colorErrorBg},{color:xt.colorErrorHover,background:xt.colorErrorBg}))}),ni=xt=>{const{componentCls:it}=xt;return{[`${it}-default`]:Nn(xt),[`${it}-primary`]:$n(xt),[`${it}-dashed`]:_i(xt),[`${it}-link`]:Qn(xt),[`${it}-text`]:Ji(xt),[`${it}-ghost`]:Yr(xt.componentCls,xt.ghostBg,xt.colorBgContainer,xt.colorBgContainer,xt.colorTextDisabled,xt.colorBorder)}},Ei=function(xt){let it=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";const{componentCls:kt,controlHeight:ir,fontSize:Pr,lineHeight:kr,borderRadius:An,buttonPaddingHorizontal:Dn,iconCls:Ht,buttonPaddingVertical:Lt}=xt,je=`${kt}-icon-only`;return[{[`${it}`]:{fontSize:Pr,lineHeight:kr,height:ir,padding:`${(0,et.bf)(Lt)} ${(0,et.bf)(Dn)}`,borderRadius:An,[`&${je}`]:{width:ir,paddingInlineStart:0,paddingInlineEnd:0,[`&${kt}-round`]:{width:"auto"},[Ht]:{fontSize:xt.buttonIconOnlyFontSize}},[`&${kt}-loading`]:{opacity:xt.opacityLoading,cursor:"default"},[`${kt}-loading-icon`]:{transition:`width ${xt.motionDurationSlow} ${xt.motionEaseInOut}, opacity ${xt.motionDurationSlow} ${xt.motionEaseInOut}`}}},{[`${kt}${kt}-circle${it}`]:Qe(xt)},{[`${kt}${kt}-round${it}`]:dr(xt)}]},xo=xt=>{const it=(0,Ke.TS)(xt,{fontSize:xt.contentFontSize,lineHeight:xt.contentLineHeight});return Ei(it,xt.componentCls)},sn=xt=>{const it=(0,Ke.TS)(xt,{controlHeight:xt.controlHeightSM,fontSize:xt.contentFontSizeSM,lineHeight:xt.contentLineHeightSM,padding:xt.paddingXS,buttonPaddingHorizontal:xt.paddingInlineSM,buttonPaddingVertical:xt.paddingBlockSM,borderRadius:xt.borderRadiusSM,buttonIconOnlyFontSize:xt.onlyIconSizeSM});return Ei(it,`${xt.componentCls}-sm`)},li=xt=>{const it=(0,Ke.TS)(xt,{controlHeight:xt.controlHeightLG,fontSize:xt.contentFontSizeLG,lineHeight:xt.contentLineHeightLG,buttonPaddingHorizontal:xt.paddingInlineLG,buttonPaddingVertical:xt.paddingBlockLG,borderRadius:xt.borderRadiusLG,buttonIconOnlyFontSize:xt.onlyIconSizeLG});return Ei(it,`${xt.componentCls}-lg`)},En=xt=>{const{componentCls:it}=xt;return{[it]:{[`&${it}-block`]:{width:"100%"}}}};var or=(0,ft.I$)("Button",xt=>{const it=ot(xt);return[Me(it),xo(it),sn(it),li(it),En(it),ni(it),Ft(it)]},We,{unitless:{fontWeight:!0,contentLineHeight:!0,contentLineHeightSM:!0,contentLineHeightLG:!0}}),qi=A(5283);function Bo(xt,it){return{[`&-item:not(${it}-last-item)`]:{marginBottom:xt.calc(xt.lineWidth).mul(-1).equal()},"&-item":{"&:hover,&:focus,&:active":{zIndex:2},"&[disabled]":{zIndex:0}}}}function Mo(xt,it){return{[`&-item:not(${it}-first-item):not(${it}-last-item)`]:{borderRadius:0},[`&-item${it}-first-item:not(${it}-last-item)`]:{[`&, &${xt}-sm, &${xt}-lg`]:{borderEndEndRadius:0,borderEndStartRadius:0}},[`&-item${it}-last-item:not(${it}-first-item)`]:{[`&, &${xt}-sm, &${xt}-lg`]:{borderStartStartRadius:0,borderStartEndRadius:0}}}}function Wi(xt){const it=`${xt.componentCls}-compact-vertical`;return{[it]:Object.assign(Object.assign({},Bo(xt,it)),Mo(xt.componentCls,it))}}const Ii=xt=>{const{componentCls:it,calc:kt}=xt;return{[it]:{[`&-compact-item${it}-primary`]:{[`&:not([disabled]) + ${it}-compact-item${it}-primary:not([disabled])`]:{position:"relative","&:before":{position:"absolute",top:kt(xt.lineWidth).mul(-1).equal(),insetInlineStart:kt(xt.lineWidth).mul(-1).equal(),display:"inline-block",width:xt.lineWidth,height:`calc(100% + ${(0,et.bf)(xt.lineWidth)} * 2)`,backgroundColor:xt.colorPrimaryHover,content:'""'}}},"&-compact-vertical-item":{[`&${it}-primary`]:{[`&:not([disabled]) + ${it}-compact-vertical-item${it}-primary:not([disabled])`]:{position:"relative","&:before":{position:"absolute",top:kt(xt.lineWidth).mul(-1).equal(),insetInlineStart:kt(xt.lineWidth).mul(-1).equal(),display:"inline-block",width:`calc(100% + ${(0,et.bf)(xt.lineWidth)} * 2)`,height:xt.lineWidth,backgroundColor:xt.colorPrimaryHover,content:'""'}}}}}}};var ko=(0,ft.bk)(["Button","compact"],xt=>{const it=ot(xt);return[(0,qi.c)(it),Wi(it),Ii(it)]},We),Fn=function(xt,it){var kt={};for(var ir in xt)Object.prototype.hasOwnProperty.call(xt,ir)&&it.indexOf(ir)<0&&(kt[ir]=xt[ir]);if(xt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Pr=0,ir=Object.getOwnPropertySymbols(xt);Pr{var kt,ir;const{loading:Pr=!1,prefixCls:kr,type:An="default",danger:Dn,shape:Ht="default",size:Lt,styles:je,disabled:$e,className:At,rootClassName:Bt,children:Jt,icon:ar,ghost:hr=!1,block:Gt=!1,htmlType:Tr="button",classNames:nn,style:bn={}}=xt,Bi=Fn(xt,["loading","prefixCls","type","danger","shape","size","styles","disabled","className","rootClassName","children","icon","ghost","block","htmlType","classNames","style"]),{getPrefixCls:on,autoInsertSpaceInButton:dn,direction:ri,button:Wn}=(0,R.useContext)(se.E_),Rn=on("btn",kr),[di,zi,Gi]=or(Rn),Lo=(0,R.useContext)(ae.Z),eo=$e!=null?$e:Lo,ba=(0,R.useContext)(Ee),va=(0,R.useMemo)(()=>zn(Pr),[Pr]),[Do,Ps]=(0,R.useState)(va.loading),[Nr,fo]=(0,R.useState)(!1),hi=(0,R.createRef)(),Yi=(0,$.sQ)(it,hi),ga=R.Children.count(Jt)===1&&!ar&&!(0,ct.Te)(An);(0,R.useEffect)(()=>{let Rl=null;va.delay>0?Rl=setTimeout(()=>{Rl=null,Ps(!0)},va.delay):Ps(va.loading);function dl(){Rl&&(clearTimeout(Rl),Rl=null)}return dl},[va]),(0,R.useEffect)(()=>{if(!Yi||!Yi.current||dn===!1)return;const Rl=Yi.current.textContent;ga&&(0,ct.aG)(Rl)?Nr||fo(!0):Nr&&fo(!1)},[Yi]);const Xi=Rl=>{const{onClick:dl}=xt;if(Do||eo){Rl.preventDefault();return}dl==null||dl(Rl)},On=dn!==!1,{compactSize:gi,compactItemClassnames:ol}=(0,le.ri)(Rn,ri),ks={large:"lg",small:"sm",middle:void 0},as=(0,ce.Z)(Rl=>{var dl,_c;return(_c=(dl=Lt!=null?Lt:gi)!==null&&dl!==void 0?dl:ba)!==null&&_c!==void 0?_c:Rl}),_s=as&&ks[as]||"",Ks=Do?"loading":ar,Ea=(0,p.Z)(Bi,["navigate"]),hs=y()(Rn,zi,Gi,{[`${Rn}-${Ht}`]:Ht!=="default"&&Ht,[`${Rn}-${An}`]:An,[`${Rn}-${_s}`]:_s,[`${Rn}-icon-only`]:!Jt&&Jt!==0&&!!Ks,[`${Rn}-background-ghost`]:hr&&!(0,ct.Te)(An),[`${Rn}-loading`]:Do,[`${Rn}-two-chinese-chars`]:Nr&&On&&!Do,[`${Rn}-block`]:Gt,[`${Rn}-dangerous`]:!!Dn,[`${Rn}-rtl`]:ri==="rtl"},ol,At,Bt,Wn==null?void 0:Wn.className),Ju=Object.assign(Object.assign({},Wn==null?void 0:Wn.style),bn),Fa=y()(nn==null?void 0:nn.icon,(kt=Wn==null?void 0:Wn.classNames)===null||kt===void 0?void 0:kt.icon),dc=Object.assign(Object.assign({},(je==null?void 0:je.icon)||{}),((ir=Wn==null?void 0:Wn.styles)===null||ir===void 0?void 0:ir.icon)||{}),el=ar&&!Do?R.createElement(ut,{prefixCls:Rn,className:Fa,style:dc},ar):R.createElement(bt,{existIcon:!!ar,prefixCls:Rn,loading:!!Do}),fl=Jt||Jt===0?(0,ct.hU)(Jt,ga&&On):null;if(Ea.href!==void 0)return di(R.createElement("a",Object.assign({},Ea,{className:y()(hs,{[`${Rn}-disabled`]:eo}),href:eo?void 0:Ea.href,style:Ju,onClick:Xi,ref:Yi,tabIndex:eo?-1:0}),el,fl));let As=R.createElement("button",Object.assign({},Bi,{type:Tr,className:hs,style:Ju,onClick:Xi,disabled:eo,ref:Yi}),el,fl,!!ol&&R.createElement(ko,{key:"compact",prefixCls:Rn}));return(0,ct.Te)(An)||(As=R.createElement(X.Z,{component:"Button",disabled:!!Do},As)),di(As)},Hi=(0,R.forwardRef)(Un);Hi.Group=Ge,Hi.__ANT_BUTTON=!0;var Ki=Hi,Fo=Ki},50138:function(Ye,ye,A){"use strict";A.d(ye,{n:function(){return y}});var R=A(77617);const V=R.createContext(!1),y=p=>{let{children:$,disabled:X}=p;const se=R.useContext(V);return R.createElement(V.Provider,{value:X!=null?X:se},$)};ye.Z=V},11621:function(Ye,ye,A){"use strict";A.d(ye,{q:function(){return y}});var R=A(77617);const V=R.createContext(void 0),y=p=>{let{children:$,size:X}=p;const se=R.useContext(V);return R.createElement(V.Provider,{value:X||se},$)};ye.Z=V},11908:function(Ye,ye,A){"use strict";A.d(ye,{E_:function(){return p},oR:function(){return V}});var R=A(77617);const V="anticon",y=(X,se)=>se||(X?`ant-${X}`:"ant"),p=R.createContext({getPrefixCls:y,iconPrefixCls:V}),{Consumer:$}=p},76135:function(Ye,ye,A){"use strict";var R=A(20573);const V=y=>{const[,,,,p]=(0,R.ZP)();return p?`${y}-css-var`:""};ye.Z=V},15550:function(Ye,ye,A){"use strict";var R=A(77617),V=A(11621);const y=p=>{const $=R.useContext(V.Z);return R.useMemo(()=>p?typeof p=="string"?p!=null?p:$:p instanceof Function?p($):$:$,[p,$])};ye.Z=y},34591:function(Ye,ye,A){"use strict";A.d(ye,{ZP:function(){return Mo},w6:function(){return or}});var R=A(77617),V=A.t(R,2),y=A(78600),p=A(48081),$=A(4065),X=A(19076),se=A(58068),ae=(0,R.createContext)(void 0),ce=A(51877),le=A(75851);const De="internalMark";var Ee=Wi=>{const{locale:Ii={},children:ko,_ANT_MARK__:Fn}=Wi;R.useEffect(()=>(0,ce.f)(Ii&&Ii.Modal),[Ii]);const zn=R.useMemo(()=>Object.assign(Object.assign({},Ii),{exist:!0}),[Ii]);return R.createElement(le.Z.Provider,{value:zn},ko)},qe=A(23244),Ge=A(47436),ct=A(19717),Ve=A(11908),ut=A(10129),Xe=A(64993),Rt=A(42871),gt=A(75966);const Ct=`-ant-${Date.now()}-${Math.random()}`;function tt(Wi,Ii){const ko={},Fn=(Hi,Ki)=>{let Fo=Hi.clone();return Fo=(Ki==null?void 0:Ki(Fo))||Fo,Fo.toRgbString()},zn=(Hi,Ki)=>{const Fo=new Xe.C(Hi),xt=(0,ut.R_)(Fo.toRgbString());ko[`${Ki}-color`]=Fn(Fo),ko[`${Ki}-color-disabled`]=xt[1],ko[`${Ki}-color-hover`]=xt[4],ko[`${Ki}-color-active`]=xt[6],ko[`${Ki}-color-outline`]=Fo.clone().setAlpha(.2).toRgbString(),ko[`${Ki}-color-deprecated-bg`]=xt[0],ko[`${Ki}-color-deprecated-border`]=xt[2]};if(Ii.primaryColor){zn(Ii.primaryColor,"primary");const Hi=new Xe.C(Ii.primaryColor),Ki=(0,ut.R_)(Hi.toRgbString());Ki.forEach((xt,it)=>{ko[`primary-${it+1}`]=xt}),ko["primary-color-deprecated-l-35"]=Fn(Hi,xt=>xt.lighten(35)),ko["primary-color-deprecated-l-20"]=Fn(Hi,xt=>xt.lighten(20)),ko["primary-color-deprecated-t-20"]=Fn(Hi,xt=>xt.tint(20)),ko["primary-color-deprecated-t-50"]=Fn(Hi,xt=>xt.tint(50)),ko["primary-color-deprecated-f-12"]=Fn(Hi,xt=>xt.setAlpha(xt.getAlpha()*.12));const Fo=new Xe.C(Ki[0]);ko["primary-color-active-deprecated-f-30"]=Fn(Fo,xt=>xt.setAlpha(xt.getAlpha()*.3)),ko["primary-color-active-deprecated-d-02"]=Fn(Fo,xt=>xt.darken(2))}return Ii.successColor&&zn(Ii.successColor,"success"),Ii.warningColor&&zn(Ii.warningColor,"warning"),Ii.errorColor&&zn(Ii.errorColor,"error"),Ii.infoColor&&zn(Ii.infoColor,"info"),` + :root { + ${Object.keys(ko).map(Hi=>`--${Wi}-${Hi}: ${ko[Hi]};`).join(` +`)} + } + `.trim()}function Ne(Wi,Ii){const ko=tt(Wi,Ii);(0,Rt.Z)()&&(0,gt.hq)(ko,`${Ct}-dynamic-theme`)}var bt=A(50138),et=A(11621);function pt(){const Wi=(0,R.useContext)(bt.Z),Ii=(0,R.useContext)(et.Z);return{componentDisabled:Wi,componentSize:Ii}}var Ke=pt,ft=A(70780);const wt=Object.assign({},V),{useId:Se}=wt;var ot=typeof Se=="undefined"?()=>"":Se;function We(Wi,Ii){var ko;const Fn=(0,se.ln)("ConfigProvider"),zn=Wi||{},Un=zn.inherit===!1||!Ii?Ge.u_:Ii,Hi=ot();return(0,$.Z)(()=>{var Ki,Fo;if(!Wi)return Ii;const xt=Object.assign({},Un.components);Object.keys(Wi.components||{}).forEach(ir=>{xt[ir]=Object.assign(Object.assign({},xt[ir]),Wi.components[ir])});const it=`css-var-${Hi.replace(/:/g,"")}`,kt=((Ki=zn.cssVar)!==null&&Ki!==void 0?Ki:Un.cssVar)&&Object.assign(Object.assign(Object.assign({prefix:"ant"},typeof Un.cssVar=="object"?Un.cssVar:{}),typeof zn.cssVar=="object"?zn.cssVar:{}),{key:typeof zn.cssVar=="object"&&((Fo=zn.cssVar)===null||Fo===void 0?void 0:Fo.key)||it});return Object.assign(Object.assign(Object.assign({},Un),zn),{token:Object.assign(Object.assign({},Un.token),zn.token),components:xt,cssVar:kt})},[zn,Un],(Ki,Fo)=>Ki.some((xt,it)=>{const kt=Fo[it];return!(0,ft.Z)(xt,kt,!0)}))}var Me=A(44516),st=A(20573);function Qe(Wi){const{children:Ii}=Wi,[,ko]=(0,st.ZP)(),{motion:Fn}=ko,zn=R.useRef(!1);return zn.current=zn.current||Fn===!1,zn.current?R.createElement(Me.zt,{motion:Fn},Ii):Ii}const dr=null;var Kt=()=>null,Yr=A(85034),hn=function(Wi,Ii){var ko={};for(var Fn in Wi)Object.prototype.hasOwnProperty.call(Wi,Fn)&&Ii.indexOf(Fn)<0&&(ko[Fn]=Wi[Fn]);if(Wi!=null&&typeof Object.getOwnPropertySymbols=="function")for(var zn=0,Fn=Object.getOwnPropertySymbols(Wi);znIi.endsWith("Color"))}const En=Wi=>{const{prefixCls:Ii,iconPrefixCls:ko,theme:Fn,holderRender:zn}=Wi;Ii!==void 0&&(Qn=Ii),ko!==void 0&&(Ji=ko),"holderRender"in Wi&&(Ei=zn),Fn&&(li(Fn)?Ne(xo(),Fn):ni=Fn)},or=()=>({getPrefixCls:(Wi,Ii)=>Ii||(Wi?`${xo()}-${Wi}`:xo()),getIconPrefixCls:sn,getRootPrefixCls:()=>Qn||xo(),getTheme:()=>ni,holderRender:Ei}),qi=Wi=>{const{children:Ii,csp:ko,autoInsertSpaceInButton:Fn,alert:zn,anchor:Un,form:Hi,locale:Ki,componentSize:Fo,direction:xt,space:it,virtual:kt,dropdownMatchSelectWidth:ir,popupMatchSelectWidth:Pr,popupOverflow:kr,legacyLocale:An,parentContext:Dn,iconPrefixCls:Ht,theme:Lt,componentDisabled:je,segmented:$e,statistic:At,spin:Bt,calendar:Jt,carousel:ar,cascader:hr,collapse:Gt,typography:Tr,checkbox:nn,descriptions:bn,divider:Bi,drawer:on,skeleton:dn,steps:ri,image:Wn,layout:Rn,list:di,mentions:zi,modal:Gi,progress:Lo,result:eo,slider:ba,breadcrumb:va,menu:Do,pagination:Ps,input:Nr,empty:fo,badge:hi,radio:Yi,rate:ga,switch:Xi,transfer:On,avatar:gi,message:ol,tag:ks,table:as,card:_s,tabs:Ks,timeline:Ea,timePicker:hs,upload:Ju,notification:Fa,tree:dc,colorPicker:el,datePicker:fl,rangePicker:As,flex:Rl,wave:dl,dropdown:_c,warning:lu,tour:Pn}=Wi,Wr=R.useCallback((Lr,yr)=>{const{prefixCls:Mr}=Wi;if(yr)return yr;const Zr=Mr||Dn.getPrefixCls("");return Lr?`${Zr}-${Lr}`:Zr},[Dn.getPrefixCls,Wi.prefixCls]),Ci=Ht||Dn.iconPrefixCls||Ve.oR,at=ko||Dn.csp;(0,Yr.Z)(Ci,at);const Vt=We(Lt,Dn.theme),gr={csp:at,autoInsertSpaceInButton:Fn,alert:zn,anchor:Un,locale:Ki||An,direction:xt,space:it,virtual:kt,popupMatchSelectWidth:Pr!=null?Pr:ir,popupOverflow:kr,getPrefixCls:Wr,iconPrefixCls:Ci,theme:Vt,segmented:$e,statistic:At,spin:Bt,calendar:Jt,carousel:ar,cascader:hr,collapse:Gt,typography:Tr,checkbox:nn,descriptions:bn,divider:Bi,drawer:on,skeleton:dn,steps:ri,image:Wn,input:Nr,layout:Rn,list:di,mentions:zi,modal:Gi,progress:Lo,result:eo,slider:ba,breadcrumb:va,menu:Do,pagination:Ps,empty:fo,badge:hi,radio:Yi,rate:ga,switch:Xi,transfer:On,avatar:gi,message:ol,tag:ks,table:as,card:_s,tabs:Ks,timeline:Ea,timePicker:hs,upload:Ju,notification:Fa,tree:dc,colorPicker:el,datePicker:fl,rangePicker:As,flex:Rl,wave:dl,dropdown:_c,warning:lu,tour:Pn},gn=Object.assign({},Dn);Object.keys(gr).forEach(Lr=>{gr[Lr]!==void 0&&(gn[Lr]=gr[Lr])}),$n.forEach(Lr=>{const yr=Wi[Lr];yr&&(gn[Lr]=yr)});const un=(0,$.Z)(()=>gn,gn,(Lr,yr)=>{const Mr=Object.keys(Lr),Zr=Object.keys(yr);return Mr.length!==Zr.length||Mr.some(Vn=>Lr[Vn]!==yr[Vn])}),Zi=R.useMemo(()=>({prefixCls:Ci,csp:at}),[Ci,at]);let ho=R.createElement(R.Fragment,null,R.createElement(Kt,{dropdownMatchSelectWidth:ir}),Ii);const Na=R.useMemo(()=>{var Lr,yr,Mr,Zr;return(0,X.T)(((Lr=qe.Z.Form)===null||Lr===void 0?void 0:Lr.defaultValidateMessages)||{},((Mr=(yr=un.locale)===null||yr===void 0?void 0:yr.Form)===null||Mr===void 0?void 0:Mr.defaultValidateMessages)||{},((Zr=un.form)===null||Zr===void 0?void 0:Zr.validateMessages)||{},(Hi==null?void 0:Hi.validateMessages)||{})},[un,Hi==null?void 0:Hi.validateMessages]);Object.keys(Na).length>0&&(ho=R.createElement(ae.Provider,{value:Na},ho)),Ki&&(ho=R.createElement(Ee,{locale:Ki,_ANT_MARK__:De},ho)),(Ci||at)&&(ho=R.createElement(p.Z.Provider,{value:Zi},ho)),Fo&&(ho=R.createElement(et.q,{size:Fo},ho)),ho=R.createElement(Qe,null,ho);const mn=R.useMemo(()=>{const Lr=Vt||{},{algorithm:yr,token:Mr,components:Zr,cssVar:Vn}=Lr,In=hn(Lr,["algorithm","token","components","cssVar"]),Kn=yr&&(!Array.isArray(yr)||yr.length>0)?(0,y.jG)(yr):Ge.uH,Mi={};Object.entries(Zr||{}).forEach(ro=>{let[Ho,ya]=ro;const gs=Object.assign({},ya);"algorithm"in gs&&(gs.algorithm===!0?gs.theme=Kn:(Array.isArray(gs.algorithm)||typeof gs.algorithm=="function")&&(gs.theme=(0,y.jG)(gs.algorithm)),delete gs.algorithm),Mi[Ho]=gs});const so=Object.assign(Object.assign({},ct.Z),Mr);return Object.assign(Object.assign({},In),{theme:Kn,token:so,components:Mi,override:Object.assign({override:so},Mi),cssVar:Vn})},[Vt]);return Lt&&(ho=R.createElement(Ge.Mj.Provider,{value:mn},ho)),un.warning&&(ho=R.createElement(se.G8.Provider,{value:un.warning},ho)),je!==void 0&&(ho=R.createElement(bt.n,{disabled:je},ho)),R.createElement(Ve.E_.Provider,{value:un},ho)},Bo=Wi=>{const Ii=R.useContext(Ve.E_),ko=R.useContext(le.Z);return R.createElement(qi,Object.assign({parentContext:Ii,legacyLocale:ko},Wi))};Bo.ConfigContext=Ve.E_,Bo.SizeContext=et.Z,Bo.config=En,Bo.useConfig=Ke,Object.defineProperty(Bo,"SizeContext",{get:()=>et.Z});var Mo=Bo},45402:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return Rt}});var R=A(92310),V=A.n(R),y=A(77617),p=A(11908),$=A(32095),X=A(64993),se=A(20573),ce=()=>{const[,gt]=(0,se.ZP)(),tt=new X.C(gt.colorBgBase).toHsl().l<.5?{opacity:.65}:{};return y.createElement("svg",{style:tt,width:"184",height:"152",viewBox:"0 0 184 152",xmlns:"http://www.w3.org/2000/svg"},y.createElement("g",{fill:"none",fillRule:"evenodd"},y.createElement("g",{transform:"translate(24 31.67)"},y.createElement("ellipse",{fillOpacity:".8",fill:"#F5F5F7",cx:"67.797",cy:"106.89",rx:"67.797",ry:"12.668"}),y.createElement("path",{d:"M122.034 69.674L98.109 40.229c-1.148-1.386-2.826-2.225-4.593-2.225h-51.44c-1.766 0-3.444.839-4.592 2.225L13.56 69.674v15.383h108.475V69.674z",fill:"#AEB8C2"}),y.createElement("path",{d:"M101.537 86.214L80.63 61.102c-1.001-1.207-2.507-1.867-4.048-1.867H31.724c-1.54 0-3.047.66-4.048 1.867L6.769 86.214v13.792h94.768V86.214z",fill:"url(#linearGradient-1)",transform:"translate(13.56)"}),y.createElement("path",{d:"M33.83 0h67.933a4 4 0 0 1 4 4v93.344a4 4 0 0 1-4 4H33.83a4 4 0 0 1-4-4V4a4 4 0 0 1 4-4z",fill:"#F5F5F7"}),y.createElement("path",{d:"M42.678 9.953h50.237a2 2 0 0 1 2 2V36.91a2 2 0 0 1-2 2H42.678a2 2 0 0 1-2-2V11.953a2 2 0 0 1 2-2zM42.94 49.767h49.713a2.262 2.262 0 1 1 0 4.524H42.94a2.262 2.262 0 0 1 0-4.524zM42.94 61.53h49.713a2.262 2.262 0 1 1 0 4.525H42.94a2.262 2.262 0 0 1 0-4.525zM121.813 105.032c-.775 3.071-3.497 5.36-6.735 5.36H20.515c-3.238 0-5.96-2.29-6.734-5.36a7.309 7.309 0 0 1-.222-1.79V69.675h26.318c2.907 0 5.25 2.448 5.25 5.42v.04c0 2.971 2.37 5.37 5.277 5.37h34.785c2.907 0 5.277-2.421 5.277-5.393V75.1c0-2.972 2.343-5.426 5.25-5.426h26.318v33.569c0 .617-.077 1.216-.221 1.789z",fill:"#DCE0E6"})),y.createElement("path",{d:"M149.121 33.292l-6.83 2.65a1 1 0 0 1-1.317-1.23l1.937-6.207c-2.589-2.944-4.109-6.534-4.109-10.408C138.802 8.102 148.92 0 161.402 0 173.881 0 184 8.102 184 18.097c0 9.995-10.118 18.097-22.599 18.097-4.528 0-8.744-1.066-12.28-2.902z",fill:"#DCE0E6"}),y.createElement("g",{transform:"translate(149.65 15.383)",fill:"#FFF"},y.createElement("ellipse",{cx:"20.654",cy:"3.167",rx:"2.849",ry:"2.815"}),y.createElement("path",{d:"M5.698 5.63H0L2.898.704zM9.259.704h4.985V5.63H9.259z"}))))},De=()=>{const[,gt]=(0,se.ZP)(),{colorFill:Ct,colorFillTertiary:tt,colorFillQuaternary:Ne,colorBgContainer:bt}=gt,{borderColor:et,shadowColor:pt,contentColor:Ke}=(0,y.useMemo)(()=>({borderColor:new X.C(Ct).onBackground(bt).toHexShortString(),shadowColor:new X.C(tt).onBackground(bt).toHexShortString(),contentColor:new X.C(Ne).onBackground(bt).toHexShortString()}),[Ct,tt,Ne,bt]);return y.createElement("svg",{width:"64",height:"41",viewBox:"0 0 64 41",xmlns:"http://www.w3.org/2000/svg"},y.createElement("g",{transform:"translate(0 1)",fill:"none",fillRule:"evenodd"},y.createElement("ellipse",{fill:pt,cx:"32",cy:"33",rx:"32",ry:"7"}),y.createElement("g",{fillRule:"nonzero",stroke:et},y.createElement("path",{d:"M55 12.76L44.854 1.258C44.367.474 43.656 0 42.907 0H21.093c-.749 0-1.46.474-1.947 1.257L9 12.761V22h46v-9.24z"}),y.createElement("path",{d:"M41.613 15.931c0-1.605.994-2.93 2.227-2.931H55v18.137C55 33.26 53.68 35 52.05 35h-40.1C10.32 35 9 33.259 9 31.137V13h11.16c1.233 0 2.227 1.323 2.227 2.928v.022c0 1.605 1.005 2.901 2.237 2.901h14.752c1.232 0 2.237-1.308 2.237-2.913v-.007z",fill:Ke}))))},we=A(93319),Ee=A(12228);const qe=gt=>{const{componentCls:Ct,margin:tt,marginXS:Ne,marginXL:bt,fontSize:et,lineHeight:pt}=gt;return{[Ct]:{marginInline:Ne,fontSize:et,lineHeight:pt,textAlign:"center",[`${Ct}-image`]:{height:gt.emptyImgHeight,marginBottom:Ne,opacity:gt.opacityImage,img:{height:"100%"},svg:{maxWidth:"100%",height:"100%",margin:"auto"}},[`${Ct}-description`]:{color:gt.colorText},[`${Ct}-footer`]:{marginTop:tt},"&-normal":{marginBlock:bt,color:gt.colorTextDisabled,[`${Ct}-description`]:{color:gt.colorTextDisabled},[`${Ct}-image`]:{height:gt.emptyImgHeightMD}},"&-small":{marginBlock:Ne,color:gt.colorTextDisabled,[`${Ct}-image`]:{height:gt.emptyImgHeightSM}}}}};var Ge=(0,we.I$)("Empty",gt=>{const{componentCls:Ct,controlHeightLG:tt,calc:Ne}=gt,bt=(0,Ee.TS)(gt,{emptyImgCls:`${Ct}-img`,emptyImgHeight:Ne(tt).mul(2.5).equal(),emptyImgHeightMD:tt,emptyImgHeightSM:Ne(tt).mul(.875).equal()});return[qe(bt)]}),ct=function(gt,Ct){var tt={};for(var Ne in gt)Object.prototype.hasOwnProperty.call(gt,Ne)&&Ct.indexOf(Ne)<0&&(tt[Ne]=gt[Ne]);if(gt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var bt=0,Ne=Object.getOwnPropertySymbols(gt);bt{var{className:Ct,rootClassName:tt,prefixCls:Ne,image:bt=Ve,description:et,children:pt,imageStyle:Ke,style:ft}=gt,wt=ct(gt,["className","rootClassName","prefixCls","image","description","children","imageStyle","style"]);const{getPrefixCls:Se,direction:Ft,empty:mt}=y.useContext(p.E_),ot=Se("empty",Ne),[We,Me,st]=Ge(ot),[Qe]=(0,$.Z)("Empty"),dr=typeof et!="undefined"?et:Qe==null?void 0:Qe.description,Kt=typeof dr=="string"?dr:"empty";let Yr=null;return typeof bt=="string"?Yr=y.createElement("img",{alt:Kt,src:bt}):Yr=bt,We(y.createElement("div",Object.assign({className:V()(Me,st,ot,mt==null?void 0:mt.className,{[`${ot}-normal`]:bt===ut,[`${ot}-rtl`]:Ft==="rtl"},Ct,tt),style:Object.assign(Object.assign({},mt==null?void 0:mt.style),ft)},wt),y.createElement("div",{className:`${ot}-image`,style:Ke},Yr),dr&&y.createElement("div",{className:`${ot}-description`},dr),pt&&y.createElement("div",{className:`${ot}-footer`},pt)))};Xe.PRESENTED_IMAGE_DEFAULT=Ve,Xe.PRESENTED_IMAGE_SIMPLE=ut;var Rt=Xe},99742:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return pt}});var R=A(77617),V=A(92310),y=A.n(V),p=A(99468);function $(Ke){return["small","middle","large"].includes(Ke)}function X(Ke){return Ke?typeof Ke=="number"&&!Number.isNaN(Ke):!1}var se=A(11908),ae=A(93319),ce=A(12228);const le=["wrap","nowrap","wrap-reverse"],De=["flex-start","flex-end","start","end","center","space-between","space-around","space-evenly","stretch","normal","left","right"],we=["center","start","end","flex-start","flex-end","self-start","self-end","baseline","normal","stretch"],Ee=(Ke,ft)=>{const wt={};return le.forEach(Se=>{wt[`${Ke}-wrap-${Se}`]=ft.wrap===Se}),wt},qe=(Ke,ft)=>{const wt={};return we.forEach(Se=>{wt[`${Ke}-align-${Se}`]=ft.align===Se}),wt[`${Ke}-align-stretch`]=!ft.align&&!!ft.vertical,wt},Ge=(Ke,ft)=>{const wt={};return De.forEach(Se=>{wt[`${Ke}-justify-${Se}`]=ft.justify===Se}),wt};function ct(Ke,ft){return y()(Object.assign(Object.assign(Object.assign({},Ee(Ke,ft)),qe(Ke,ft)),Ge(Ke,ft)))}var Ve=ct;const ut=Ke=>{const{componentCls:ft}=Ke;return{[ft]:{display:"flex","&-vertical":{flexDirection:"column"},"&-rtl":{direction:"rtl"},"&:empty":{display:"none"}}}},Xe=Ke=>{const{componentCls:ft}=Ke;return{[ft]:{"&-gap-small":{gap:Ke.flexGapSM},"&-gap-middle":{gap:Ke.flexGap},"&-gap-large":{gap:Ke.flexGapLG}}}},Rt=Ke=>{const{componentCls:ft}=Ke,wt={};return le.forEach(Se=>{wt[`${ft}-wrap-${Se}`]={flexWrap:Se}}),wt},gt=Ke=>{const{componentCls:ft}=Ke,wt={};return we.forEach(Se=>{wt[`${ft}-align-${Se}`]={alignItems:Se}}),wt},Ct=Ke=>{const{componentCls:ft}=Ke,wt={};return De.forEach(Se=>{wt[`${ft}-justify-${Se}`]={justifyContent:Se}}),wt},tt=()=>({});var Ne=(0,ae.I$)("Flex",Ke=>{const{paddingXS:ft,padding:wt,paddingLG:Se}=Ke,Ft=(0,ce.TS)(Ke,{flexGapSM:ft,flexGap:wt,flexGapLG:Se});return[ut(Ft),Xe(Ft),Rt(Ft),gt(Ft),Ct(Ft)]},tt,{resetStyle:!1}),bt=function(Ke,ft){var wt={};for(var Se in Ke)Object.prototype.hasOwnProperty.call(Ke,Se)&&ft.indexOf(Se)<0&&(wt[Se]=Ke[Se]);if(Ke!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Ft=0,Se=Object.getOwnPropertySymbols(Ke);Ft{const{prefixCls:wt,rootClassName:Se,className:Ft,style:mt,flex:ot,gap:We,children:Me,vertical:st=!1,component:Qe="div"}=Ke,dr=bt(Ke,["prefixCls","rootClassName","className","style","flex","gap","children","vertical","component"]),{flex:Kt,direction:Yr,getPrefixCls:hn}=R.useContext(se.E_),ln=hn("flex",wt),[oi,Nn,$n]=Ne(ln),_i=st!=null?st:Kt==null?void 0:Kt.vertical,Qn=y()(Ft,Se,Kt==null?void 0:Kt.className,ln,Nn,$n,Ve(ln,Ke),{[`${ln}-rtl`]:Yr==="rtl",[`${ln}-gap-${We}`]:$(We),[`${ln}-vertical`]:_i}),Ji=Object.assign(Object.assign({},Kt==null?void 0:Kt.style),mt);return ot&&(Ji.flex=ot),We&&!$(We)&&(Ji.gap=We),oi(R.createElement(Qe,Object.assign({ref:ft,className:Qn,style:Ji},(0,p.Z)(dr,["justify","wrap","align"])),Me))})},53615:function(Ye,ye,A){"use strict";A.d(ye,{aM:function(){return Zi},Ux:function(){return ho},pg:function(){return Na}});var R=A(77617),V=A(79384),y=A(56348),p=A(33202),$=A(90304),X=A(54131),se=A(49397),ae=A(61577),ce=A(22946),le=A(7963),De=A(3711),we=A(71038),Ee=A(16514),qe=A(45659),Ge=A(70780),ct=A(36014),Ve="RC_FORM_INTERNAL_HOOKS",ut=function(){(0,ct.ZP)(!1,"Can not find FormContext. Please make sure you wrap Field under Form.")},Xe=R.createContext({getFieldValue:ut,getFieldsValue:ut,getFieldError:ut,getFieldWarning:ut,getFieldsError:ut,isFieldsTouched:ut,isFieldTouched:ut,isFieldValidating:ut,isFieldsValidating:ut,resetFields:ut,setFields:ut,setFieldValue:ut,setFieldsValue:ut,validateFields:ut,submit:ut,getInternalHooks:function(){return ut(),{dispatch:ut,initEntityValue:ut,registerField:ut,useSubscribe:ut,setInitialValues:ut,destroyForm:ut,setCallbacks:ut,registerWatch:ut,getFields:ut,setValidateMessages:ut,setPreserve:ut,getInitialValue:ut}}}),Rt=Xe,gt=R.createContext(null),Ct=gt;function tt(mn){return mn==null?[]:Array.isArray(mn)?mn:[mn]}function Ne(mn){return mn&&!!mn._init}var bt=A(97671);function et(){return et=Object.assign?Object.assign.bind():function(mn){for(var Lr=1;Lr1?Lr-1:0),Mr=1;Mr=Vn)return Kn;switch(Kn){case"%s":return String(yr[Zr++]);case"%d":return Number(yr[Zr++]);case"%j":try{return JSON.stringify(yr[Zr++])}catch(Mi){return"[Circular]"}break;default:return Kn}});return In}return mn}function Qe(mn){return mn==="string"||mn==="url"||mn==="hex"||mn==="email"||mn==="date"||mn==="pattern"}function dr(mn,Lr){return!!(mn==null||Lr==="array"&&Array.isArray(mn)&&!mn.length||Qe(Lr)&&typeof mn=="string"&&!mn)}function Kt(mn,Lr,yr){var Mr=[],Zr=0,Vn=mn.length;function In(Kn){Mr.push.apply(Mr,Kn||[]),Zr++,Zr===Vn&&yr(Mr)}mn.forEach(function(Kn){Lr(Kn,In)})}function Yr(mn,Lr,yr){var Mr=0,Zr=mn.length;function Vn(In){if(In&&In.length){yr(In);return}var Kn=Mr;Mr=Mr+1,Kn()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+\.)+[a-zA-Z\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]{2,}))$/,hex:/^#?([a-f0-9]{6}|[a-f0-9]{3})$/i},li={integer:function(Lr){return li.number(Lr)&&parseInt(Lr,10)===Lr},float:function(Lr){return li.number(Lr)&&!li.integer(Lr)},array:function(Lr){return Array.isArray(Lr)},regexp:function(Lr){if(Lr instanceof RegExp)return!0;try{return!!new RegExp(Lr)}catch(yr){return!1}},date:function(Lr){return typeof Lr.getTime=="function"&&typeof Lr.getMonth=="function"&&typeof Lr.getYear=="function"&&!isNaN(Lr.getTime())},number:function(Lr){return isNaN(Lr)?!1:typeof Lr=="number"},object:function(Lr){return typeof Lr=="object"&&!li.array(Lr)},method:function(Lr){return typeof Lr=="function"},email:function(Lr){return typeof Lr=="string"&&Lr.length<=320&&!!Lr.match(sn.email)},url:function(Lr){return typeof Lr=="string"&&Lr.length<=2048&&!!Lr.match(xo())},hex:function(Lr){return typeof Lr=="string"&&!!Lr.match(sn.hex)}},En=function(Lr,yr,Mr,Zr,Vn){if(Lr.required&&yr===void 0){Ji(Lr,yr,Mr,Zr,Vn);return}var In=["integer","float","array","regexp","object","method","email","number","date","url","hex"],Kn=Lr.type;In.indexOf(Kn)>-1?li[Kn](yr)||Zr.push(st(Vn.messages.types[Kn],Lr.fullField,Lr.type)):Kn&&typeof yr!==Lr.type&&Zr.push(st(Vn.messages.types[Kn],Lr.fullField,Lr.type))},or=function(Lr,yr,Mr,Zr,Vn){var In=typeof Lr.len=="number",Kn=typeof Lr.min=="number",Mi=typeof Lr.max=="number",so=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,ro=yr,Ho=null,ya=typeof yr=="number",gs=typeof yr=="string",lo=Array.isArray(yr);if(ya?Ho="number":gs?Ho="string":lo&&(Ho="array"),!Ho)return!1;lo&&(ro=yr.length),gs&&(ro=yr.replace(so,"_").length),In?ro!==Lr.len&&Zr.push(st(Vn.messages[Ho].len,Lr.fullField,Lr.len)):Kn&&!Mi&&roLr.max?Zr.push(st(Vn.messages[Ho].max,Lr.fullField,Lr.max)):Kn&&Mi&&(roLr.max)&&Zr.push(st(Vn.messages[Ho].range,Lr.fullField,Lr.min,Lr.max))},qi="enum",Bo=function(Lr,yr,Mr,Zr,Vn){Lr[qi]=Array.isArray(Lr[qi])?Lr[qi]:[],Lr[qi].indexOf(yr)===-1&&Zr.push(st(Vn.messages[qi],Lr.fullField,Lr[qi].join(", ")))},Mo=function(Lr,yr,Mr,Zr,Vn){if(Lr.pattern){if(Lr.pattern instanceof RegExp)Lr.pattern.lastIndex=0,Lr.pattern.test(yr)||Zr.push(st(Vn.messages.pattern.mismatch,Lr.fullField,yr,Lr.pattern));else if(typeof Lr.pattern=="string"){var In=new RegExp(Lr.pattern);In.test(yr)||Zr.push(st(Vn.messages.pattern.mismatch,Lr.fullField,yr,Lr.pattern))}}},Wi={required:Ji,whitespace:ni,type:En,range:or,enum:Bo,pattern:Mo},Ii=function(Lr,yr,Mr,Zr,Vn){var In=[],Kn=Lr.required||!Lr.required&&Zr.hasOwnProperty(Lr.field);if(Kn){if(dr(yr,"string")&&!Lr.required)return Mr();Wi.required(Lr,yr,Zr,In,Vn,"string"),dr(yr,"string")||(Wi.type(Lr,yr,Zr,In,Vn),Wi.range(Lr,yr,Zr,In,Vn),Wi.pattern(Lr,yr,Zr,In,Vn),Lr.whitespace===!0&&Wi.whitespace(Lr,yr,Zr,In,Vn))}Mr(In)},ko=function(Lr,yr,Mr,Zr,Vn){var In=[],Kn=Lr.required||!Lr.required&&Zr.hasOwnProperty(Lr.field);if(Kn){if(dr(yr)&&!Lr.required)return Mr();Wi.required(Lr,yr,Zr,In,Vn),yr!==void 0&&Wi.type(Lr,yr,Zr,In,Vn)}Mr(In)},Fn=function(Lr,yr,Mr,Zr,Vn){var In=[],Kn=Lr.required||!Lr.required&&Zr.hasOwnProperty(Lr.field);if(Kn){if(yr===""&&(yr=void 0),dr(yr)&&!Lr.required)return Mr();Wi.required(Lr,yr,Zr,In,Vn),yr!==void 0&&(Wi.type(Lr,yr,Zr,In,Vn),Wi.range(Lr,yr,Zr,In,Vn))}Mr(In)},zn=function(Lr,yr,Mr,Zr,Vn){var In=[],Kn=Lr.required||!Lr.required&&Zr.hasOwnProperty(Lr.field);if(Kn){if(dr(yr)&&!Lr.required)return Mr();Wi.required(Lr,yr,Zr,In,Vn),yr!==void 0&&Wi.type(Lr,yr,Zr,In,Vn)}Mr(In)},Un=function(Lr,yr,Mr,Zr,Vn){var In=[],Kn=Lr.required||!Lr.required&&Zr.hasOwnProperty(Lr.field);if(Kn){if(dr(yr)&&!Lr.required)return Mr();Wi.required(Lr,yr,Zr,In,Vn),dr(yr)||Wi.type(Lr,yr,Zr,In,Vn)}Mr(In)},Hi=function(Lr,yr,Mr,Zr,Vn){var In=[],Kn=Lr.required||!Lr.required&&Zr.hasOwnProperty(Lr.field);if(Kn){if(dr(yr)&&!Lr.required)return Mr();Wi.required(Lr,yr,Zr,In,Vn),yr!==void 0&&(Wi.type(Lr,yr,Zr,In,Vn),Wi.range(Lr,yr,Zr,In,Vn))}Mr(In)},Ki=function(Lr,yr,Mr,Zr,Vn){var In=[],Kn=Lr.required||!Lr.required&&Zr.hasOwnProperty(Lr.field);if(Kn){if(dr(yr)&&!Lr.required)return Mr();Wi.required(Lr,yr,Zr,In,Vn),yr!==void 0&&(Wi.type(Lr,yr,Zr,In,Vn),Wi.range(Lr,yr,Zr,In,Vn))}Mr(In)},Fo=function(Lr,yr,Mr,Zr,Vn){var In=[],Kn=Lr.required||!Lr.required&&Zr.hasOwnProperty(Lr.field);if(Kn){if(yr==null&&!Lr.required)return Mr();Wi.required(Lr,yr,Zr,In,Vn,"array"),yr!=null&&(Wi.type(Lr,yr,Zr,In,Vn),Wi.range(Lr,yr,Zr,In,Vn))}Mr(In)},xt=function(Lr,yr,Mr,Zr,Vn){var In=[],Kn=Lr.required||!Lr.required&&Zr.hasOwnProperty(Lr.field);if(Kn){if(dr(yr)&&!Lr.required)return Mr();Wi.required(Lr,yr,Zr,In,Vn),yr!==void 0&&Wi.type(Lr,yr,Zr,In,Vn)}Mr(In)},it="enum",kt=function(Lr,yr,Mr,Zr,Vn){var In=[],Kn=Lr.required||!Lr.required&&Zr.hasOwnProperty(Lr.field);if(Kn){if(dr(yr)&&!Lr.required)return Mr();Wi.required(Lr,yr,Zr,In,Vn),yr!==void 0&&Wi[it](Lr,yr,Zr,In,Vn)}Mr(In)},ir=function(Lr,yr,Mr,Zr,Vn){var In=[],Kn=Lr.required||!Lr.required&&Zr.hasOwnProperty(Lr.field);if(Kn){if(dr(yr,"string")&&!Lr.required)return Mr();Wi.required(Lr,yr,Zr,In,Vn),dr(yr,"string")||Wi.pattern(Lr,yr,Zr,In,Vn)}Mr(In)},Pr=function(Lr,yr,Mr,Zr,Vn){var In=[],Kn=Lr.required||!Lr.required&&Zr.hasOwnProperty(Lr.field);if(Kn){if(dr(yr,"date")&&!Lr.required)return Mr();if(Wi.required(Lr,yr,Zr,In,Vn),!dr(yr,"date")){var Mi;yr instanceof Date?Mi=yr:Mi=new Date(yr),Wi.type(Lr,Mi,Zr,In,Vn),Mi&&Wi.range(Lr,Mi.getTime(),Zr,In,Vn)}}Mr(In)},kr=function(Lr,yr,Mr,Zr,Vn){var In=[],Kn=Array.isArray(yr)?"array":typeof yr;Wi.required(Lr,yr,Zr,In,Vn,Kn),Mr(In)},An=function(Lr,yr,Mr,Zr,Vn){var In=Lr.type,Kn=[],Mi=Lr.required||!Lr.required&&Zr.hasOwnProperty(Lr.field);if(Mi){if(dr(yr,In)&&!Lr.required)return Mr();Wi.required(Lr,yr,Zr,Kn,Vn,In),dr(yr,In)||Wi.type(Lr,yr,Zr,Kn,Vn)}Mr(Kn)},Dn=function(Lr,yr,Mr,Zr,Vn){var In=[],Kn=Lr.required||!Lr.required&&Zr.hasOwnProperty(Lr.field);if(Kn){if(dr(yr)&&!Lr.required)return Mr();Wi.required(Lr,yr,Zr,In,Vn)}Mr(In)},Ht={string:Ii,method:ko,number:Fn,boolean:zn,regexp:Un,integer:Hi,float:Ki,array:Fo,object:xt,enum:kt,pattern:ir,date:Pr,url:An,hex:An,email:An,required:kr,any:Dn};function Lt(){return{default:"Validation error on field %s",required:"%s is required",enum:"%s must be one of %s",whitespace:"%s cannot be empty",date:{format:"%s date %s is invalid for format %s",parse:"%s date could not be parsed, %s is invalid ",invalid:"%s date %s is invalid"},types:{string:"%s is not a %s",method:"%s is not a %s (function)",array:"%s is not an %s",object:"%s is not an %s",number:"%s is not a %s",date:"%s is not a %s",boolean:"%s is not a %s",integer:"%s is not an %s",float:"%s is not a %s",regexp:"%s is not a valid %s",email:"%s is not a valid %s",url:"%s is not a valid %s",hex:"%s is not a valid %s"},string:{len:"%s must be exactly %s characters",min:"%s must be at least %s characters",max:"%s cannot be longer than %s characters",range:"%s must be between %s and %s characters"},number:{len:"%s must equal %s",min:"%s cannot be less than %s",max:"%s cannot be greater than %s",range:"%s must be between %s and %s"},array:{len:"%s must be exactly %s in length",min:"%s cannot be less than %s in length",max:"%s cannot be greater than %s in length",range:"%s must be between %s and %s in length"},pattern:{mismatch:"%s value %s does not match pattern %s"},clone:function(){var Lr=JSON.parse(JSON.stringify(this));return Lr.clone=this.clone,Lr}}}var je=Lt(),$e=function(){function mn(yr){this.rules=null,this._messages=je,this.define(yr)}var Lr=mn.prototype;return Lr.define=function(Mr){var Zr=this;if(!Mr)throw new Error("Cannot configure a schema with no rules");if(typeof Mr!="object"||Array.isArray(Mr))throw new Error("Rules must be an object");this.rules={},Object.keys(Mr).forEach(function(Vn){var In=Mr[Vn];Zr.rules[Vn]=Array.isArray(In)?In:[In]})},Lr.messages=function(Mr){return Mr&&(this._messages=Qn(Lt(),Mr)),this._messages},Lr.validate=function(Mr,Zr,Vn){var In=this;Zr===void 0&&(Zr={}),Vn===void 0&&(Vn=function(){});var Kn=Mr,Mi=Zr,so=Vn;if(typeof Mi=="function"&&(so=Mi,Mi={}),!this.rules||Object.keys(this.rules).length===0)return so&&so(null,Kn),Promise.resolve(Kn);function ro(No){var Da=[],ta={};function Ra(Vo){if(Array.isArray(Vo)){var bs;Da=(bs=Da).concat.apply(bs,Vo)}else Da.push(Vo)}for(var ns=0;ns2&&arguments[2]!==void 0?arguments[2]:!1;return mn&&mn.some(function(Mr){return Lo(Lr,Mr,yr)})}function Lo(mn,Lr){var yr=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;return!mn||!Lr||!yr&&mn.length!==Lr.length?!1:Lr.every(function(Mr,Zr){return mn[Zr]===Mr})}function eo(mn,Lr){if(mn===Lr)return!0;if(!mn&&Lr||mn&&!Lr||!mn||!Lr||(0,Wn.Z)(mn)!=="object"||(0,Wn.Z)(Lr)!=="object")return!1;var yr=Object.keys(mn),Mr=Object.keys(Lr),Zr=new Set([].concat(yr,Mr));return(0,se.Z)(Zr).every(function(Vn){var In=mn[Vn],Kn=Lr[Vn];return typeof In=="function"&&typeof Kn=="function"?!0:In===Kn})}function ba(mn){var Lr=arguments.length<=1?void 0:arguments[1];return Lr&&Lr.target&&(0,Wn.Z)(Lr.target)==="object"&&mn in Lr.target?Lr.target[mn]:Lr}function va(mn,Lr,yr){var Mr=mn.length;if(Lr<0||Lr>=Mr||yr<0||yr>=Mr)return mn;var Zr=mn[Lr],Vn=Lr-yr;return Vn>0?[].concat((0,se.Z)(mn.slice(0,yr)),[Zr],(0,se.Z)(mn.slice(yr,Lr)),(0,se.Z)(mn.slice(Lr+1,Mr))):Vn<0?[].concat((0,se.Z)(mn.slice(0,Lr)),(0,se.Z)(mn.slice(Lr+1,yr+1)),[Zr],(0,se.Z)(mn.slice(yr+1,Mr))):mn}var Do=["name"],Ps=[];function Nr(mn,Lr,yr,Mr,Zr,Vn){return typeof mn=="function"?mn(Lr,yr,"source"in Vn?{source:Vn.source}:{}):Mr!==Zr}var fo=function(mn){(0,De.Z)(yr,mn);var Lr=(0,we.Z)(yr);function yr(Mr){var Zr;if((0,ae.Z)(this,yr),Zr=Lr.call(this,Mr),(0,Ee.Z)((0,le.Z)(Zr),"state",{resetCount:0}),(0,Ee.Z)((0,le.Z)(Zr),"cancelRegisterFunc",null),(0,Ee.Z)((0,le.Z)(Zr),"mounted",!1),(0,Ee.Z)((0,le.Z)(Zr),"touched",!1),(0,Ee.Z)((0,le.Z)(Zr),"dirty",!1),(0,Ee.Z)((0,le.Z)(Zr),"validatePromise",void 0),(0,Ee.Z)((0,le.Z)(Zr),"prevValidating",void 0),(0,Ee.Z)((0,le.Z)(Zr),"errors",Ps),(0,Ee.Z)((0,le.Z)(Zr),"warnings",Ps),(0,Ee.Z)((0,le.Z)(Zr),"cancelRegister",function(){var Mi=Zr.props,so=Mi.preserve,ro=Mi.isListField,Ho=Mi.name;Zr.cancelRegisterFunc&&Zr.cancelRegisterFunc(ro,so,di(Ho)),Zr.cancelRegisterFunc=null}),(0,Ee.Z)((0,le.Z)(Zr),"getNamePath",function(){var Mi=Zr.props,so=Mi.name,ro=Mi.fieldContext,Ho=ro.prefixName,ya=Ho===void 0?[]:Ho;return so!==void 0?[].concat((0,se.Z)(ya),(0,se.Z)(so)):[]}),(0,Ee.Z)((0,le.Z)(Zr),"getRules",function(){var Mi=Zr.props,so=Mi.rules,ro=so===void 0?[]:so,Ho=Mi.fieldContext;return ro.map(function(ya){return typeof ya=="function"?ya(Ho):ya})}),(0,Ee.Z)((0,le.Z)(Zr),"refresh",function(){Zr.mounted&&Zr.setState(function(Mi){var so=Mi.resetCount;return{resetCount:so+1}})}),(0,Ee.Z)((0,le.Z)(Zr),"metaCache",null),(0,Ee.Z)((0,le.Z)(Zr),"triggerMetaEvent",function(Mi){var so=Zr.props.onMetaChange;if(so){var ro=(0,X.Z)((0,X.Z)({},Zr.getMeta()),{},{destroy:Mi});(0,Ge.Z)(Zr.metaCache,ro)||so(ro),Zr.metaCache=ro}else Zr.metaCache=null}),(0,Ee.Z)((0,le.Z)(Zr),"onStoreChange",function(Mi,so,ro){var Ho=Zr.props,ya=Ho.shouldUpdate,gs=Ho.dependencies,lo=gs===void 0?[]:gs,No=Ho.onReset,Da=ro.store,ta=Zr.getNamePath(),Ra=Zr.getValue(Mi),ns=Zr.getValue(Da),Vo=so&&Gi(so,ta);switch(ro.type==="valueUpdate"&&ro.source==="external"&&Ra!==ns&&(Zr.touched=!0,Zr.dirty=!0,Zr.validatePromise=null,Zr.errors=Ps,Zr.warnings=Ps,Zr.triggerMetaEvent()),ro.type){case"reset":if(!so||Vo){Zr.touched=!1,Zr.dirty=!1,Zr.validatePromise=void 0,Zr.errors=Ps,Zr.warnings=Ps,Zr.triggerMetaEvent(),No==null||No(),Zr.refresh();return}break;case"remove":{if(ya){Zr.reRender();return}break}case"setField":{var bs=ro.data;if(Vo){"touched"in bs&&(Zr.touched=bs.touched),"validating"in bs&&!("originRCField"in bs)&&(Zr.validatePromise=bs.validating?Promise.resolve([]):null),"errors"in bs&&(Zr.errors=bs.errors||Ps),"warnings"in bs&&(Zr.warnings=bs.warnings||Ps),Zr.dirty=!0,Zr.triggerMetaEvent(),Zr.reRender();return}else if("value"in bs&&Gi(so,ta,!0)){Zr.reRender();return}if(ya&&!ta.length&&Nr(ya,Mi,Da,Ra,ns,ro)){Zr.reRender();return}break}case"dependenciesUpdate":{var Js=lo.map(di);if(Js.some(function(Hu){return Gi(ro.relatedFields,Hu)})){Zr.reRender();return}break}default:if(Vo||(!lo.length||ta.length||ya)&&Nr(ya,Mi,Da,Ra,ns,ro)){Zr.reRender();return}break}ya===!0&&Zr.reRender()}),(0,Ee.Z)((0,le.Z)(Zr),"validateRules",function(Mi){var so=Zr.getNamePath(),ro=Zr.getValue(),Ho=Mi||{},ya=Ho.triggerName,gs=Ho.validateOnly,lo=gs===void 0?!1:gs,No=Promise.resolve().then((0,$.Z)((0,p.Z)().mark(function Da(){var ta,Ra,ns,Vo,bs,Js,Hu;return(0,p.Z)().wrap(function(en){for(;;)switch(en.prev=en.next){case 0:if(Zr.mounted){en.next=2;break}return en.abrupt("return",[]);case 2:if(ta=Zr.props,Ra=ta.validateFirst,ns=Ra===void 0?!1:Ra,Vo=ta.messageVariables,bs=ta.validateDebounce,Js=Zr.getRules(),ya&&(Js=Js.filter(function(xn){return xn}).filter(function(xn){var Vi=xn.validateTrigger;if(!Vi)return!0;var wi=tt(Vi);return wi.includes(ya)})),!(bs&&ya)){en.next=10;break}return en.next=8,new Promise(function(xn){setTimeout(xn,bs)});case 8:if(Zr.validatePromise===No){en.next=10;break}return en.abrupt("return",[]);case 10:return Hu=bn(so,ro,Js,Mi,ns,Vo),Hu.catch(function(xn){return xn}).then(function(){var xn=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Ps;if(Zr.validatePromise===No){var Vi;Zr.validatePromise=null;var wi=[],oo=[];(Vi=xn.forEach)===null||Vi===void 0||Vi.call(xn,function(io){var Uo=io.rule.warningOnly,na=io.errors,$a=na===void 0?Ps:na;Uo?oo.push.apply(oo,(0,se.Z)($a)):wi.push.apply(wi,(0,se.Z)($a))}),Zr.errors=wi,Zr.warnings=oo,Zr.triggerMetaEvent(),Zr.reRender()}}),en.abrupt("return",Hu);case 13:case"end":return en.stop()}},Da)})));return lo||(Zr.validatePromise=No,Zr.dirty=!0,Zr.errors=Ps,Zr.warnings=Ps,Zr.triggerMetaEvent(),Zr.reRender()),No}),(0,Ee.Z)((0,le.Z)(Zr),"isFieldValidating",function(){return!!Zr.validatePromise}),(0,Ee.Z)((0,le.Z)(Zr),"isFieldTouched",function(){return Zr.touched}),(0,Ee.Z)((0,le.Z)(Zr),"isFieldDirty",function(){if(Zr.dirty||Zr.props.initialValue!==void 0)return!0;var Mi=Zr.props.fieldContext,so=Mi.getInternalHooks(Ve),ro=so.getInitialValue;return ro(Zr.getNamePath())!==void 0}),(0,Ee.Z)((0,le.Z)(Zr),"getErrors",function(){return Zr.errors}),(0,Ee.Z)((0,le.Z)(Zr),"getWarnings",function(){return Zr.warnings}),(0,Ee.Z)((0,le.Z)(Zr),"isListField",function(){return Zr.props.isListField}),(0,Ee.Z)((0,le.Z)(Zr),"isList",function(){return Zr.props.isList}),(0,Ee.Z)((0,le.Z)(Zr),"isPreserve",function(){return Zr.props.preserve}),(0,Ee.Z)((0,le.Z)(Zr),"getMeta",function(){Zr.prevValidating=Zr.isFieldValidating();var Mi={touched:Zr.isFieldTouched(),validating:Zr.prevValidating,errors:Zr.errors,warnings:Zr.warnings,name:Zr.getNamePath(),validated:Zr.validatePromise===null};return Mi}),(0,Ee.Z)((0,le.Z)(Zr),"getOnlyChild",function(Mi){if(typeof Mi=="function"){var so=Zr.getMeta();return(0,X.Z)((0,X.Z)({},Zr.getOnlyChild(Mi(Zr.getControlled(),so,Zr.props.fieldContext))),{},{isFunction:!0})}var ro=(0,qe.Z)(Mi);return ro.length!==1||!R.isValidElement(ro[0])?{child:ro,isFunction:!1}:{child:ro[0],isFunction:!1}}),(0,Ee.Z)((0,le.Z)(Zr),"getValue",function(Mi){var so=Zr.props.fieldContext.getFieldsValue,ro=Zr.getNamePath();return(0,Rn.Z)(Mi||so(!0),ro)}),(0,Ee.Z)((0,le.Z)(Zr),"getControlled",function(){var Mi=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},so=Zr.props,ro=so.trigger,Ho=so.validateTrigger,ya=so.getValueFromEvent,gs=so.normalize,lo=so.valuePropName,No=so.getValueProps,Da=so.fieldContext,ta=Ho!==void 0?Ho:Da.validateTrigger,Ra=Zr.getNamePath(),ns=Da.getInternalHooks,Vo=Da.getFieldsValue,bs=ns(Ve),Js=bs.dispatch,Hu=Zr.getValue(),Of=No||function(wi){return(0,Ee.Z)({},lo,wi)},en=Mi[ro],xn=(0,X.Z)((0,X.Z)({},Mi),Of(Hu));xn[ro]=function(){Zr.touched=!0,Zr.dirty=!0,Zr.triggerMetaEvent();for(var wi,oo=arguments.length,io=new Array(oo),Uo=0;Uo=0&&xn<=Vi.length?(ro.keys=[].concat((0,se.Z)(ro.keys.slice(0,xn)),[ro.id],(0,se.Z)(ro.keys.slice(xn))),ns([].concat((0,se.Z)(Vi.slice(0,xn)),[en],(0,se.Z)(Vi.slice(xn))))):(ro.keys=[].concat((0,se.Z)(ro.keys),[ro.id]),ns([].concat((0,se.Z)(Vi),[en]))),ro.id+=1},remove:function(en){var xn=bs(),Vi=new Set(Array.isArray(en)?en:[en]);Vi.size<=0||(ro.keys=ro.keys.filter(function(wi,oo){return!Vi.has(oo)}),ns(xn.filter(function(wi,oo){return!Vi.has(oo)})))},move:function(en,xn){if(en!==xn){var Vi=bs();en<0||en>=Vi.length||xn<0||xn>=Vi.length||(ro.keys=va(ro.keys,en,xn),ns(va(Vi,en,xn)))}}},Hu=Ra||[];return Array.isArray(Hu)||(Hu=[]),Mr(Hu.map(function(Of,en){var xn=ro.keys[en];return xn===void 0&&(ro.keys[en]=ro.id,xn=ro.keys[en],ro.id+=1),{name:en,key:xn,isListField:!0}}),Js,Da)})))}var Xi=ga,On=A(35372);function gi(mn){var Lr=!1,yr=mn.length,Mr=[];return mn.length?new Promise(function(Zr,Vn){mn.forEach(function(In,Kn){In.catch(function(Mi){return Lr=!0,Mi}).then(function(Mi){yr-=1,Mr[Kn]=Mi,!(yr>0)&&(Lr&&Vn(Mr),Zr(Mr))})})}):Promise.resolve([])}var ol="__@field_split__";function ks(mn){return mn.map(function(Lr){return"".concat((0,Wn.Z)(Lr),":").concat(Lr)}).join(ol)}var as=function(){function mn(){(0,ae.Z)(this,mn),(0,Ee.Z)(this,"kvs",new Map)}return(0,ce.Z)(mn,[{key:"set",value:function(yr,Mr){this.kvs.set(ks(yr),Mr)}},{key:"get",value:function(yr){return this.kvs.get(ks(yr))}},{key:"update",value:function(yr,Mr){var Zr=this.get(yr),Vn=Mr(Zr);Vn?this.set(yr,Vn):this.delete(yr)}},{key:"delete",value:function(yr){this.kvs.delete(ks(yr))}},{key:"map",value:function(yr){return(0,se.Z)(this.kvs.entries()).map(function(Mr){var Zr=(0,On.Z)(Mr,2),Vn=Zr[0],In=Zr[1],Kn=Vn.split(ol);return yr({key:Kn.map(function(Mi){var so=Mi.match(/^([^:]*):(.*)$/),ro=(0,On.Z)(so,3),Ho=ro[1],ya=ro[2];return Ho==="number"?Number(ya):ya}),value:In})})}},{key:"toJSON",value:function(){var yr={};return this.map(function(Mr){var Zr=Mr.key,Vn=Mr.value;return yr[Zr.join(".")]=Vn,null}),yr}}]),mn}(),_s=as,Ks=["name"],Ea=(0,ce.Z)(function mn(Lr){var yr=this;(0,ae.Z)(this,mn),(0,Ee.Z)(this,"formHooked",!1),(0,Ee.Z)(this,"forceRootUpdate",void 0),(0,Ee.Z)(this,"subscribable",!0),(0,Ee.Z)(this,"store",{}),(0,Ee.Z)(this,"fieldEntities",[]),(0,Ee.Z)(this,"initialValues",{}),(0,Ee.Z)(this,"callbacks",{}),(0,Ee.Z)(this,"validateMessages",null),(0,Ee.Z)(this,"preserve",null),(0,Ee.Z)(this,"lastValidatePromise",null),(0,Ee.Z)(this,"getForm",function(){return{getFieldValue:yr.getFieldValue,getFieldsValue:yr.getFieldsValue,getFieldError:yr.getFieldError,getFieldWarning:yr.getFieldWarning,getFieldsError:yr.getFieldsError,isFieldsTouched:yr.isFieldsTouched,isFieldTouched:yr.isFieldTouched,isFieldValidating:yr.isFieldValidating,isFieldsValidating:yr.isFieldsValidating,resetFields:yr.resetFields,setFields:yr.setFields,setFieldValue:yr.setFieldValue,setFieldsValue:yr.setFieldsValue,validateFields:yr.validateFields,submit:yr.submit,_init:!0,getInternalHooks:yr.getInternalHooks}}),(0,Ee.Z)(this,"getInternalHooks",function(Mr){return Mr===Ve?(yr.formHooked=!0,{dispatch:yr.dispatch,initEntityValue:yr.initEntityValue,registerField:yr.registerField,useSubscribe:yr.useSubscribe,setInitialValues:yr.setInitialValues,destroyForm:yr.destroyForm,setCallbacks:yr.setCallbacks,setValidateMessages:yr.setValidateMessages,getFields:yr.getFields,setPreserve:yr.setPreserve,getInitialValue:yr.getInitialValue,registerWatch:yr.registerWatch}):((0,ct.ZP)(!1,"`getInternalHooks` is internal usage. Should not call directly."),null)}),(0,Ee.Z)(this,"useSubscribe",function(Mr){yr.subscribable=Mr}),(0,Ee.Z)(this,"prevWithoutPreserves",null),(0,Ee.Z)(this,"setInitialValues",function(Mr,Zr){if(yr.initialValues=Mr||{},Zr){var Vn,In=(0,Jt.T)(Mr,yr.store);(Vn=yr.prevWithoutPreserves)===null||Vn===void 0||Vn.map(function(Kn){var Mi=Kn.key;In=(0,Jt.Z)(In,Mi,(0,Rn.Z)(Mr,Mi))}),yr.prevWithoutPreserves=null,yr.updateStore(In)}}),(0,Ee.Z)(this,"destroyForm",function(){var Mr=new _s;yr.getFieldEntities(!0).forEach(function(Zr){yr.isMergedPreserve(Zr.isPreserve())||Mr.set(Zr.getNamePath(),!0)}),yr.prevWithoutPreserves=Mr}),(0,Ee.Z)(this,"getInitialValue",function(Mr){var Zr=(0,Rn.Z)(yr.initialValues,Mr);return Mr.length?(0,Jt.T)(Zr):Zr}),(0,Ee.Z)(this,"setCallbacks",function(Mr){yr.callbacks=Mr}),(0,Ee.Z)(this,"setValidateMessages",function(Mr){yr.validateMessages=Mr}),(0,Ee.Z)(this,"setPreserve",function(Mr){yr.preserve=Mr}),(0,Ee.Z)(this,"watchList",[]),(0,Ee.Z)(this,"registerWatch",function(Mr){return yr.watchList.push(Mr),function(){yr.watchList=yr.watchList.filter(function(Zr){return Zr!==Mr})}}),(0,Ee.Z)(this,"notifyWatch",function(){var Mr=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];if(yr.watchList.length){var Zr=yr.getFieldsValue(),Vn=yr.getFieldsValue(!0);yr.watchList.forEach(function(In){In(Zr,Vn,Mr)})}}),(0,Ee.Z)(this,"timeoutId",null),(0,Ee.Z)(this,"warningUnhooked",function(){}),(0,Ee.Z)(this,"updateStore",function(Mr){yr.store=Mr}),(0,Ee.Z)(this,"getFieldEntities",function(){var Mr=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return Mr?yr.fieldEntities.filter(function(Zr){return Zr.getNamePath().length}):yr.fieldEntities}),(0,Ee.Z)(this,"getFieldsMap",function(){var Mr=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,Zr=new _s;return yr.getFieldEntities(Mr).forEach(function(Vn){var In=Vn.getNamePath();Zr.set(In,Vn)}),Zr}),(0,Ee.Z)(this,"getFieldEntitiesForNamePathList",function(Mr){if(!Mr)return yr.getFieldEntities(!0);var Zr=yr.getFieldsMap(!0);return Mr.map(function(Vn){var In=di(Vn);return Zr.get(In)||{INVALIDATE_NAME_PATH:di(Vn)}})}),(0,Ee.Z)(this,"getFieldsValue",function(Mr,Zr){yr.warningUnhooked();var Vn,In,Kn;if(Mr===!0||Array.isArray(Mr)?(Vn=Mr,In=Zr):Mr&&(0,Wn.Z)(Mr)==="object"&&(Kn=Mr.strict,In=Mr.filter),Vn===!0&&!In)return yr.store;var Mi=yr.getFieldEntitiesForNamePathList(Array.isArray(Vn)?Vn:null),so=[];return Mi.forEach(function(ro){var Ho,ya,gs="INVALIDATE_NAME_PATH"in ro?ro.INVALIDATE_NAME_PATH:ro.getNamePath();if(Kn){var lo,No;if((lo=(No=ro).isList)!==null&&lo!==void 0&&lo.call(No))return}else if(!Vn&&(Ho=(ya=ro).isListField)!==null&&Ho!==void 0&&Ho.call(ya))return;if(!In)so.push(gs);else{var Da="getMeta"in ro?ro.getMeta():null;In(Da)&&so.push(gs)}}),zi(yr.store,so.map(di))}),(0,Ee.Z)(this,"getFieldValue",function(Mr){yr.warningUnhooked();var Zr=di(Mr);return(0,Rn.Z)(yr.store,Zr)}),(0,Ee.Z)(this,"getFieldsError",function(Mr){yr.warningUnhooked();var Zr=yr.getFieldEntitiesForNamePathList(Mr);return Zr.map(function(Vn,In){return Vn&&!("INVALIDATE_NAME_PATH"in Vn)?{name:Vn.getNamePath(),errors:Vn.getErrors(),warnings:Vn.getWarnings()}:{name:di(Mr[In]),errors:[],warnings:[]}})}),(0,Ee.Z)(this,"getFieldError",function(Mr){yr.warningUnhooked();var Zr=di(Mr),Vn=yr.getFieldsError([Zr])[0];return Vn.errors}),(0,Ee.Z)(this,"getFieldWarning",function(Mr){yr.warningUnhooked();var Zr=di(Mr),Vn=yr.getFieldsError([Zr])[0];return Vn.warnings}),(0,Ee.Z)(this,"isFieldsTouched",function(){yr.warningUnhooked();for(var Mr=arguments.length,Zr=new Array(Mr),Vn=0;Vn0&&arguments[0]!==void 0?arguments[0]:{},Zr=new _s,Vn=yr.getFieldEntities(!0);Vn.forEach(function(Mi){var so=Mi.props.initialValue,ro=Mi.getNamePath();if(so!==void 0){var Ho=Zr.get(ro)||new Set;Ho.add({entity:Mi,value:so}),Zr.set(ro,Ho)}});var In=function(so){so.forEach(function(ro){var Ho=ro.props.initialValue;if(Ho!==void 0){var ya=ro.getNamePath(),gs=yr.getInitialValue(ya);if(gs!==void 0)(0,ct.ZP)(!1,"Form already set 'initialValues' with path '".concat(ya.join("."),"'. Field can not overwrite it."));else{var lo=Zr.get(ya);if(lo&&lo.size>1)(0,ct.ZP)(!1,"Multiple Field with path '".concat(ya.join("."),"' set 'initialValue'. Can not decide which one to pick."));else if(lo){var No=yr.getFieldValue(ya),Da=ro.isListField();!Da&&(!Mr.skipExist||No===void 0)&&yr.updateStore((0,Jt.Z)(yr.store,ya,(0,se.Z)(lo)[0].value))}}}})},Kn;Mr.entities?Kn=Mr.entities:Mr.namePathList?(Kn=[],Mr.namePathList.forEach(function(Mi){var so=Zr.get(Mi);if(so){var ro;(ro=Kn).push.apply(ro,(0,se.Z)((0,se.Z)(so).map(function(Ho){return Ho.entity})))}})):Kn=Vn,In(Kn)}),(0,Ee.Z)(this,"resetFields",function(Mr){yr.warningUnhooked();var Zr=yr.store;if(!Mr){yr.updateStore((0,Jt.T)(yr.initialValues)),yr.resetWithFieldInitialValue(),yr.notifyObservers(Zr,null,{type:"reset"}),yr.notifyWatch();return}var Vn=Mr.map(di);Vn.forEach(function(In){var Kn=yr.getInitialValue(In);yr.updateStore((0,Jt.Z)(yr.store,In,Kn))}),yr.resetWithFieldInitialValue({namePathList:Vn}),yr.notifyObservers(Zr,Vn,{type:"reset"}),yr.notifyWatch(Vn)}),(0,Ee.Z)(this,"setFields",function(Mr){yr.warningUnhooked();var Zr=yr.store,Vn=[];Mr.forEach(function(In){var Kn=In.name,Mi=(0,y.Z)(In,Ks),so=di(Kn);Vn.push(so),"value"in Mi&&yr.updateStore((0,Jt.Z)(yr.store,so,Mi.value)),yr.notifyObservers(Zr,[so],{type:"setField",data:In})}),yr.notifyWatch(Vn)}),(0,Ee.Z)(this,"getFields",function(){var Mr=yr.getFieldEntities(!0),Zr=Mr.map(function(Vn){var In=Vn.getNamePath(),Kn=Vn.getMeta(),Mi=(0,X.Z)((0,X.Z)({},Kn),{},{name:In,value:yr.getFieldValue(In)});return Object.defineProperty(Mi,"originRCField",{value:!0}),Mi});return Zr}),(0,Ee.Z)(this,"initEntityValue",function(Mr){var Zr=Mr.props.initialValue;if(Zr!==void 0){var Vn=Mr.getNamePath(),In=(0,Rn.Z)(yr.store,Vn);In===void 0&&yr.updateStore((0,Jt.Z)(yr.store,Vn,Zr))}}),(0,Ee.Z)(this,"isMergedPreserve",function(Mr){var Zr=Mr!==void 0?Mr:yr.preserve;return Zr!=null?Zr:!0}),(0,Ee.Z)(this,"registerField",function(Mr){yr.fieldEntities.push(Mr);var Zr=Mr.getNamePath();if(yr.notifyWatch([Zr]),Mr.props.initialValue!==void 0){var Vn=yr.store;yr.resetWithFieldInitialValue({entities:[Mr],skipExist:!0}),yr.notifyObservers(Vn,[Mr.getNamePath()],{type:"valueUpdate",source:"internal"})}return function(In,Kn){var Mi=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[];if(yr.fieldEntities=yr.fieldEntities.filter(function(Ho){return Ho!==Mr}),!yr.isMergedPreserve(Kn)&&(!In||Mi.length>1)){var so=In?void 0:yr.getInitialValue(Zr);if(Zr.length&&yr.getFieldValue(Zr)!==so&&yr.fieldEntities.every(function(Ho){return!Lo(Ho.getNamePath(),Zr)})){var ro=yr.store;yr.updateStore((0,Jt.Z)(ro,Zr,so,!0)),yr.notifyObservers(ro,[Zr],{type:"remove"}),yr.triggerDependenciesUpdate(ro,Zr)}}yr.notifyWatch([Zr])}}),(0,Ee.Z)(this,"dispatch",function(Mr){switch(Mr.type){case"updateValue":{var Zr=Mr.namePath,Vn=Mr.value;yr.updateValue(Zr,Vn);break}case"validateField":{var In=Mr.namePath,Kn=Mr.triggerName;yr.validateFields([In],{triggerName:Kn});break}default:}}),(0,Ee.Z)(this,"notifyObservers",function(Mr,Zr,Vn){if(yr.subscribable){var In=(0,X.Z)((0,X.Z)({},Vn),{},{store:yr.getFieldsValue(!0)});yr.getFieldEntities().forEach(function(Kn){var Mi=Kn.onStoreChange;Mi(Mr,Zr,In)})}else yr.forceRootUpdate()}),(0,Ee.Z)(this,"triggerDependenciesUpdate",function(Mr,Zr){var Vn=yr.getDependencyChildrenFields(Zr);return Vn.length&&yr.validateFields(Vn),yr.notifyObservers(Mr,Vn,{type:"dependenciesUpdate",relatedFields:[Zr].concat((0,se.Z)(Vn))}),Vn}),(0,Ee.Z)(this,"updateValue",function(Mr,Zr){var Vn=di(Mr),In=yr.store;yr.updateStore((0,Jt.Z)(yr.store,Vn,Zr)),yr.notifyObservers(In,[Vn],{type:"valueUpdate",source:"internal"}),yr.notifyWatch([Vn]);var Kn=yr.triggerDependenciesUpdate(In,Vn),Mi=yr.callbacks.onValuesChange;if(Mi){var so=zi(yr.store,[Vn]);Mi(so,yr.getFieldsValue())}yr.triggerOnFieldsChange([Vn].concat((0,se.Z)(Kn)))}),(0,Ee.Z)(this,"setFieldsValue",function(Mr){yr.warningUnhooked();var Zr=yr.store;if(Mr){var Vn=(0,Jt.T)(yr.store,Mr);yr.updateStore(Vn)}yr.notifyObservers(Zr,null,{type:"valueUpdate",source:"external"}),yr.notifyWatch()}),(0,Ee.Z)(this,"setFieldValue",function(Mr,Zr){yr.setFields([{name:Mr,value:Zr}])}),(0,Ee.Z)(this,"getDependencyChildrenFields",function(Mr){var Zr=new Set,Vn=[],In=new _s;yr.getFieldEntities().forEach(function(Mi){var so=Mi.props.dependencies;(so||[]).forEach(function(ro){var Ho=di(ro);In.update(Ho,function(){var ya=arguments.length>0&&arguments[0]!==void 0?arguments[0]:new Set;return ya.add(Mi),ya})})});var Kn=function Mi(so){var ro=In.get(so)||new Set;ro.forEach(function(Ho){if(!Zr.has(Ho)){Zr.add(Ho);var ya=Ho.getNamePath();Ho.isFieldDirty()&&ya.length&&(Vn.push(ya),Mi(ya))}})};return Kn(Mr),Vn}),(0,Ee.Z)(this,"triggerOnFieldsChange",function(Mr,Zr){var Vn=yr.callbacks.onFieldsChange;if(Vn){var In=yr.getFields();if(Zr){var Kn=new _s;Zr.forEach(function(so){var ro=so.name,Ho=so.errors;Kn.set(ro,Ho)}),In.forEach(function(so){so.errors=Kn.get(so.name)||so.errors})}var Mi=In.filter(function(so){var ro=so.name;return Gi(Mr,ro)});Mi.length&&Vn(Mi,In)}}),(0,Ee.Z)(this,"validateFields",function(Mr,Zr){yr.warningUnhooked();var Vn,In;Array.isArray(Mr)||typeof Mr=="string"||typeof Zr=="string"?(Vn=Mr,In=Zr):In=Mr;var Kn=!!Vn,Mi=Kn?Vn.map(di):[],so=[],ro=String(Date.now()),Ho=new Set,ya=In||{},gs=ya.recursive,lo=ya.dirty;yr.getFieldEntities(!0).forEach(function(Ra){if(Kn||Mi.push(Ra.getNamePath()),!(!Ra.props.rules||!Ra.props.rules.length)&&!(lo&&!Ra.isFieldDirty())){var ns=Ra.getNamePath();if(Ho.add(ns.join(ro)),!Kn||Gi(Mi,ns,gs)){var Vo=Ra.validateRules((0,X.Z)({validateMessages:(0,X.Z)((0,X.Z)({},Bt),yr.validateMessages)},In));so.push(Vo.then(function(){return{name:ns,errors:[],warnings:[]}}).catch(function(bs){var Js,Hu=[],Of=[];return(Js=bs.forEach)===null||Js===void 0||Js.call(bs,function(en){var xn=en.rule.warningOnly,Vi=en.errors;xn?Of.push.apply(Of,(0,se.Z)(Vi)):Hu.push.apply(Hu,(0,se.Z)(Vi))}),Hu.length?Promise.reject({name:ns,errors:Hu,warnings:Of}):{name:ns,errors:Hu,warnings:Of}}))}}});var No=gi(so);yr.lastValidatePromise=No,No.catch(function(Ra){return Ra}).then(function(Ra){var ns=Ra.map(function(Vo){var bs=Vo.name;return bs});yr.notifyObservers(yr.store,ns,{type:"validateFinish"}),yr.triggerOnFieldsChange(ns,Ra)});var Da=No.then(function(){return yr.lastValidatePromise===No?Promise.resolve(yr.getFieldsValue(Mi)):Promise.reject([])}).catch(function(Ra){var ns=Ra.filter(function(Vo){return Vo&&Vo.errors.length});return Promise.reject({values:yr.getFieldsValue(Mi),errorFields:ns,outOfDate:yr.lastValidatePromise!==No})});Da.catch(function(Ra){return Ra});var ta=Mi.filter(function(Ra){return Ho.has(Ra.join(ro))});return yr.triggerOnFieldsChange(ta),Da}),(0,Ee.Z)(this,"submit",function(){yr.warningUnhooked(),yr.validateFields().then(function(Mr){var Zr=yr.callbacks.onFinish;if(Zr)try{Zr(Mr)}catch(Vn){console.error(Vn)}}).catch(function(Mr){var Zr=yr.callbacks.onFinishFailed;Zr&&Zr(Mr)})}),this.forceRootUpdate=Lr});function hs(mn){var Lr=R.useRef(),yr=R.useState({}),Mr=(0,On.Z)(yr,2),Zr=Mr[1];if(!Lr.current)if(mn)Lr.current=mn;else{var Vn=function(){Zr({})},In=new Ea(Vn);Lr.current=In.getForm()}return[Lr.current]}var Ju=hs,Fa=R.createContext({triggerFormChange:function(){},triggerFormFinish:function(){},registerForm:function(){},unregisterForm:function(){}}),dc=function(Lr){var yr=Lr.validateMessages,Mr=Lr.onFormChange,Zr=Lr.onFormFinish,Vn=Lr.children,In=R.useContext(Fa),Kn=R.useRef({});return R.createElement(Fa.Provider,{value:(0,X.Z)((0,X.Z)({},In),{},{validateMessages:(0,X.Z)((0,X.Z)({},In.validateMessages),yr),triggerFormChange:function(so,ro){Mr&&Mr(so,{changedFields:ro,forms:Kn.current}),In.triggerFormChange(so,ro)},triggerFormFinish:function(so,ro){Zr&&Zr(so,{values:ro,forms:Kn.current}),In.triggerFormFinish(so,ro)},registerForm:function(so,ro){so&&(Kn.current=(0,X.Z)((0,X.Z)({},Kn.current),{},(0,Ee.Z)({},so,ro))),In.registerForm(so,ro)},unregisterForm:function(so){var ro=(0,X.Z)({},Kn.current);delete ro[so],Kn.current=ro,In.unregisterForm(so)}})},Vn)},el=Fa,fl=["name","initialValues","fields","form","preserve","children","component","validateMessages","validateTrigger","onValuesChange","onFieldsChange","onFinish","onFinishFailed"],As=function(Lr,yr){var Mr=Lr.name,Zr=Lr.initialValues,Vn=Lr.fields,In=Lr.form,Kn=Lr.preserve,Mi=Lr.children,so=Lr.component,ro=so===void 0?"form":so,Ho=Lr.validateMessages,ya=Lr.validateTrigger,gs=ya===void 0?"onChange":ya,lo=Lr.onValuesChange,No=Lr.onFieldsChange,Da=Lr.onFinish,ta=Lr.onFinishFailed,Ra=(0,y.Z)(Lr,fl),ns=R.useContext(el),Vo=Ju(In),bs=(0,On.Z)(Vo,1),Js=bs[0],Hu=Js.getInternalHooks(Ve),Of=Hu.useSubscribe,en=Hu.setInitialValues,xn=Hu.setCallbacks,Vi=Hu.setValidateMessages,wi=Hu.setPreserve,oo=Hu.destroyForm;R.useImperativeHandle(yr,function(){return Js}),R.useEffect(function(){return ns.registerForm(Mr,Js),function(){ns.unregisterForm(Mr)}},[ns,Js,Mr]),Vi((0,X.Z)((0,X.Z)({},ns.validateMessages),Ho)),xn({onValuesChange:lo,onFieldsChange:function(si){if(ns.triggerFormChange(Mr,si),No){for(var Ms=arguments.length,Ns=new Array(Ms>1?Ms-1:0),Aa=1;Aa{}}),gr=null,gn=mn=>{const Lr=omit(mn,["prefixCls"]);return React.createElement(RcFormProvider,Object.assign({},Lr))},un=R.createContext({prefixCls:""}),Zi=R.createContext({}),ho=mn=>{let{children:Lr,status:yr,override:Mr}=mn;const Zr=(0,R.useContext)(Zi),Vn=(0,R.useMemo)(()=>{const In=Object.assign({},Zr);return Mr&&delete In.isFormItemInput,yr&&(delete In.status,delete In.hasFeedback,delete In.feedbackIcon),In},[yr,Mr,Zr]);return R.createElement(Zi.Provider,{value:Vn},Lr)},Na=(0,R.createContext)(void 0)},75851:function(Ye,ye,A){"use strict";var R=A(77617);const V=(0,R.createContext)(void 0);ye.Z=V},23244:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return we}});var R={items_per_page:"/ page",jump_to:"Go to",jump_to_confirm:"confirm",page:"Page",prev_page:"Previous Page",next_page:"Next Page",prev_5:"Previous 5 Pages",next_5:"Next 5 Pages",prev_3:"Previous 3 Pages",next_3:"Next 3 Pages",page_size:"Page Size"},V=R,y={locale:"en_US",today:"Today",now:"Now",backToToday:"Back to today",ok:"OK",clear:"Clear",month:"Month",year:"Year",timeSelect:"select time",dateSelect:"select date",weekSelect:"Choose a week",monthSelect:"Choose a month",yearSelect:"Choose a year",decadeSelect:"Choose a decade",yearFormat:"YYYY",dateFormat:"M/D/YYYY",dayFormat:"D",dateTimeFormat:"M/D/YYYY HH:mm:ss",monthBeforeYear:!0,previousMonth:"Previous month (PageUp)",nextMonth:"Next month (PageDown)",previousYear:"Last year (Control + left)",nextYear:"Next year (Control + right)",previousDecade:"Last decade",nextDecade:"Next decade",previousCentury:"Last century",nextCentury:"Next century"},p=y,X={placeholder:"Select time",rangePlaceholder:["Start time","End time"]},ae={lang:Object.assign({placeholder:"Select date",yearPlaceholder:"Select year",quarterPlaceholder:"Select quarter",monthPlaceholder:"Select month",weekPlaceholder:"Select week",rangePlaceholder:["Start date","End date"],rangeYearPlaceholder:["Start year","End year"],rangeQuarterPlaceholder:["Start quarter","End quarter"],rangeMonthPlaceholder:["Start month","End month"],rangeWeekPlaceholder:["Start week","End week"]},p),timePickerLocale:Object.assign({},X)},ce=ae;const le="${label} is not a valid ${type}";var we={locale:"en",Pagination:V,DatePicker:ae,TimePicker:X,Calendar:ce,global:{placeholder:"Please select"},Table:{filterTitle:"Filter menu",filterConfirm:"OK",filterReset:"Reset",filterEmptyText:"No filters",filterCheckall:"Select all items",filterSearchPlaceholder:"Search in filters",emptyText:"No data",selectAll:"Select current page",selectInvert:"Invert current page",selectNone:"Clear all data",selectionAll:"Select all data",sortTitle:"Sort",expand:"Expand row",collapse:"Collapse row",triggerDesc:"Click to sort descending",triggerAsc:"Click to sort ascending",cancelSort:"Click to cancel sorting"},Tour:{Next:"Next",Previous:"Previous",Finish:"Finish"},Modal:{okText:"OK",cancelText:"Cancel",justOkText:"OK"},Popconfirm:{okText:"OK",cancelText:"Cancel"},Transfer:{titles:["",""],searchPlaceholder:"Search here",itemUnit:"item",itemsUnit:"items",remove:"Remove",selectCurrent:"Select current page",removeCurrent:"Remove current page",selectAll:"Select all data",removeAll:"Remove all data",selectInvert:"Invert current page"},Upload:{uploading:"Uploading...",removeFile:"Remove file",uploadError:"Upload error",previewFile:"Preview file",downloadFile:"Download file"},Empty:{description:"No data"},Icon:{icon:"icon"},Text:{edit:"Edit",copy:"Copy",copied:"Copied",expand:"Expand"},Form:{optional:"(optional)",defaultValidateMessages:{default:"Field validation error for ${label}",required:"Please enter ${label}",enum:"${label} must be one of [${enum}]",whitespace:"${label} cannot be a blank character",date:{format:"${label} date format is invalid",parse:"${label} cannot be converted to a date",invalid:"${label} is an invalid date"},types:{string:le,method:le,array:le,object:le,number:le,date:le,boolean:le,integer:le,float:le,regexp:le,email:le,url:le,hex:le},string:{len:"${label} must be ${len} characters",min:"${label} must be at least ${min} characters",max:"${label} must be up to ${max} characters",range:"${label} must be between ${min}-${max} characters"},number:{len:"${label} must be equal to ${len}",min:"${label} must be minimum ${min}",max:"${label} must be maximum ${max}",range:"${label} must be between ${min}-${max}"},array:{len:"Must be ${len} ${label}",min:"At least ${min} ${label}",max:"At most ${max} ${label}",range:"The amount of ${label} must be between ${min}-${max}"},pattern:{mismatch:"${label} does not match the pattern ${pattern}"}}},Image:{preview:"Preview"},QRCode:{expired:"QR code expired",refresh:"Refresh",scanned:"Scanned"},ColorPicker:{presetEmpty:"Empty"}}},32095:function(Ye,ye,A){"use strict";var R=A(77617),V=A(75851),y=A(23244);const p=($,X)=>{const se=R.useContext(V.Z),ae=R.useMemo(()=>{var le;const De=X||y.Z[$],we=(le=se==null?void 0:se[$])!==null&&le!==void 0?le:{};return Object.assign(Object.assign({},typeof De=="function"?De():De),we||{})},[$,X,se]),ce=R.useMemo(()=>{const le=se==null?void 0:se.locale;return se!=null&&se.exist&&!le?y.Z.locale:le},[se]);return[ae,ce]};ye.Z=p},36632:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return we}});var R={items_per_page:"\u6761/\u9875",jump_to:"\u8DF3\u81F3",jump_to_confirm:"\u786E\u5B9A",page:"\u9875",prev_page:"\u4E0A\u4E00\u9875",next_page:"\u4E0B\u4E00\u9875",prev_5:"\u5411\u524D 5 \u9875",next_5:"\u5411\u540E 5 \u9875",prev_3:"\u5411\u524D 3 \u9875",next_3:"\u5411\u540E 3 \u9875",page_size:"\u9875\u7801"},V=R,y={locale:"zh_CN",yearFormat:"YYYY\u5E74",cellDateFormat:"D",cellMeridiemFormat:"A",today:"\u4ECA\u5929",now:"\u6B64\u523B",backToToday:"\u8FD4\u56DE\u4ECA\u5929",ok:"\u786E\u5B9A",timeSelect:"\u9009\u62E9\u65F6\u95F4",dateSelect:"\u9009\u62E9\u65E5\u671F",weekSelect:"\u9009\u62E9\u5468",clear:"\u6E05\u9664",month:"\u6708",year:"\u5E74",previousMonth:"\u4E0A\u4E2A\u6708 (\u7FFB\u9875\u4E0A\u952E)",nextMonth:"\u4E0B\u4E2A\u6708 (\u7FFB\u9875\u4E0B\u952E)",monthSelect:"\u9009\u62E9\u6708\u4EFD",yearSelect:"\u9009\u62E9\u5E74\u4EFD",decadeSelect:"\u9009\u62E9\u5E74\u4EE3",previousYear:"\u4E0A\u4E00\u5E74 (Control\u952E\u52A0\u5DE6\u65B9\u5411\u952E)",nextYear:"\u4E0B\u4E00\u5E74 (Control\u952E\u52A0\u53F3\u65B9\u5411\u952E)",previousDecade:"\u4E0A\u4E00\u5E74\u4EE3",nextDecade:"\u4E0B\u4E00\u5E74\u4EE3",previousCentury:"\u4E0A\u4E00\u4E16\u7EAA",nextCentury:"\u4E0B\u4E00\u4E16\u7EAA"},p=y,X={placeholder:"\u8BF7\u9009\u62E9\u65F6\u95F4",rangePlaceholder:["\u5F00\u59CB\u65F6\u95F4","\u7ED3\u675F\u65F6\u95F4"]};const se={lang:Object.assign({placeholder:"\u8BF7\u9009\u62E9\u65E5\u671F",yearPlaceholder:"\u8BF7\u9009\u62E9\u5E74\u4EFD",quarterPlaceholder:"\u8BF7\u9009\u62E9\u5B63\u5EA6",monthPlaceholder:"\u8BF7\u9009\u62E9\u6708\u4EFD",weekPlaceholder:"\u8BF7\u9009\u62E9\u5468",rangePlaceholder:["\u5F00\u59CB\u65E5\u671F","\u7ED3\u675F\u65E5\u671F"],rangeYearPlaceholder:["\u5F00\u59CB\u5E74\u4EFD","\u7ED3\u675F\u5E74\u4EFD"],rangeMonthPlaceholder:["\u5F00\u59CB\u6708\u4EFD","\u7ED3\u675F\u6708\u4EFD"],rangeQuarterPlaceholder:["\u5F00\u59CB\u5B63\u5EA6","\u7ED3\u675F\u5B63\u5EA6"],rangeWeekPlaceholder:["\u5F00\u59CB\u5468","\u7ED3\u675F\u5468"]},p),timePickerLocale:Object.assign({},X)};se.lang.ok="\u786E\u5B9A";var ae=se,ce=ae;const le="${label}\u4E0D\u662F\u4E00\u4E2A\u6709\u6548\u7684${type}";var we={locale:"zh-cn",Pagination:V,DatePicker:ae,TimePicker:X,Calendar:ce,global:{placeholder:"\u8BF7\u9009\u62E9"},Table:{filterTitle:"\u7B5B\u9009",filterConfirm:"\u786E\u5B9A",filterReset:"\u91CD\u7F6E",filterEmptyText:"\u65E0\u7B5B\u9009\u9879",filterCheckall:"\u5168\u9009",filterSearchPlaceholder:"\u5728\u7B5B\u9009\u9879\u4E2D\u641C\u7D22",selectAll:"\u5168\u9009\u5F53\u9875",selectInvert:"\u53CD\u9009\u5F53\u9875",selectNone:"\u6E05\u7A7A\u6240\u6709",selectionAll:"\u5168\u9009\u6240\u6709",sortTitle:"\u6392\u5E8F",expand:"\u5C55\u5F00\u884C",collapse:"\u5173\u95ED\u884C",triggerDesc:"\u70B9\u51FB\u964D\u5E8F",triggerAsc:"\u70B9\u51FB\u5347\u5E8F",cancelSort:"\u53D6\u6D88\u6392\u5E8F"},Modal:{okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",justOkText:"\u77E5\u9053\u4E86"},Tour:{Next:"\u4E0B\u4E00\u6B65",Previous:"\u4E0A\u4E00\u6B65",Finish:"\u7ED3\u675F\u5BFC\u89C8"},Popconfirm:{cancelText:"\u53D6\u6D88",okText:"\u786E\u5B9A"},Transfer:{titles:["",""],searchPlaceholder:"\u8BF7\u8F93\u5165\u641C\u7D22\u5185\u5BB9",itemUnit:"\u9879",itemsUnit:"\u9879",remove:"\u5220\u9664",selectCurrent:"\u5168\u9009\u5F53\u9875",removeCurrent:"\u5220\u9664\u5F53\u9875",selectAll:"\u5168\u9009\u6240\u6709",removeAll:"\u5220\u9664\u5168\u90E8",selectInvert:"\u53CD\u9009\u5F53\u9875"},Upload:{uploading:"\u6587\u4EF6\u4E0A\u4F20\u4E2D",removeFile:"\u5220\u9664\u6587\u4EF6",uploadError:"\u4E0A\u4F20\u9519\u8BEF",previewFile:"\u9884\u89C8\u6587\u4EF6",downloadFile:"\u4E0B\u8F7D\u6587\u4EF6"},Empty:{description:"\u6682\u65E0\u6570\u636E"},Icon:{icon:"\u56FE\u6807"},Text:{edit:"\u7F16\u8F91",copy:"\u590D\u5236",copied:"\u590D\u5236\u6210\u529F",expand:"\u5C55\u5F00"},Form:{optional:"\uFF08\u53EF\u9009\uFF09",defaultValidateMessages:{default:"\u5B57\u6BB5\u9A8C\u8BC1\u9519\u8BEF${label}",required:"\u8BF7\u8F93\u5165${label}",enum:"${label}\u5FC5\u987B\u662F\u5176\u4E2D\u4E00\u4E2A[${enum}]",whitespace:"${label}\u4E0D\u80FD\u4E3A\u7A7A\u5B57\u7B26",date:{format:"${label}\u65E5\u671F\u683C\u5F0F\u65E0\u6548",parse:"${label}\u4E0D\u80FD\u8F6C\u6362\u4E3A\u65E5\u671F",invalid:"${label}\u662F\u4E00\u4E2A\u65E0\u6548\u65E5\u671F"},types:{string:le,method:le,array:le,object:le,number:le,date:le,boolean:le,integer:le,float:le,regexp:le,email:le,url:le,hex:le},string:{len:"${label}\u987B\u4E3A${len}\u4E2A\u5B57\u7B26",min:"${label}\u6700\u5C11${min}\u4E2A\u5B57\u7B26",max:"${label}\u6700\u591A${max}\u4E2A\u5B57\u7B26",range:"${label}\u987B\u5728${min}-${max}\u5B57\u7B26\u4E4B\u95F4"},number:{len:"${label}\u5FC5\u987B\u7B49\u4E8E${len}",min:"${label}\u6700\u5C0F\u503C\u4E3A${min}",max:"${label}\u6700\u5927\u503C\u4E3A${max}",range:"${label}\u987B\u5728${min}-${max}\u4E4B\u95F4"},array:{len:"\u987B\u4E3A${len}\u4E2A${label}",min:"\u6700\u5C11${min}\u4E2A${label}",max:"\u6700\u591A${max}\u4E2A${label}",range:"${label}\u6570\u91CF\u987B\u5728${min}-${max}\u4E4B\u95F4"},pattern:{mismatch:"${label}\u4E0E\u6A21\u5F0F\u4E0D\u5339\u914D${pattern}"}}},Image:{preview:"\u9884\u89C8"},QRCode:{expired:"\u4E8C\u7EF4\u7801\u8FC7\u671F",refresh:"\u70B9\u51FB\u5237\u65B0",scanned:"\u5DF2\u626B\u63CF"},ColorPicker:{presetEmpty:"\u6682\u65E0"}}},64451:function(Ye,ye,A){"use strict";A.d(ye,{ZP:function(){return Bi}});var R=A(49397),V=A(77617),y=A(41522);const p=V.createContext({}),$=V.createContext({message:{},notification:{},modal:{}});var X=null,se=A(11908),ae=A(34591),ce=A(50555),le=A(43418),De=A(81664),we=A(20906),Ee=A(20555),qe=A(92310),Ge=A.n(qe),ct=A(35372),Ve=A(56348),ut=A(54131),Xe=A(79161),Rt=A(79384),gt=A(16514),Ct=A(44516),tt=A(84821),Ne=V.forwardRef(function(on,dn){var ri=on.prefixCls,Wn=on.style,Rn=on.className,di=on.duration,zi=di===void 0?4.5:di,Gi=on.eventKey,Lo=on.content,eo=on.closable,ba=on.closeIcon,va=ba===void 0?"x":ba,Do=on.props,Ps=on.onClick,Nr=on.onNoticeClose,fo=on.times,hi=on.hovering,Yi=V.useState(!1),ga=(0,ct.Z)(Yi,2),Xi=ga[0],On=ga[1],gi=hi||Xi,ol=function(){Nr(Gi)},ks=function(Ks){(Ks.key==="Enter"||Ks.code==="Enter"||Ks.keyCode===tt.Z.ENTER)&&ol()};V.useEffect(function(){if(!gi&&zi>0){var _s=setTimeout(function(){ol()},zi*1e3);return function(){clearTimeout(_s)}}},[zi,gi,fo]);var as="".concat(ri,"-notice");return V.createElement("div",(0,Rt.Z)({},Do,{ref:dn,className:Ge()(as,Rn,(0,gt.Z)({},"".concat(as,"-closable"),eo)),style:Wn,onMouseEnter:function(Ks){var Ea;On(!0),Do==null||(Ea=Do.onMouseEnter)===null||Ea===void 0||Ea.call(Do,Ks)},onMouseLeave:function(Ks){var Ea;On(!1),Do==null||(Ea=Do.onMouseLeave)===null||Ea===void 0||Ea.call(Do,Ks)},onClick:Ps}),V.createElement("div",{className:"".concat(as,"-content")},Lo),eo&&V.createElement("a",{tabIndex:0,className:"".concat(as,"-close"),onKeyDown:ks,onClick:function(Ks){Ks.preventDefault(),Ks.stopPropagation(),ol()}},va))}),bt=Ne,et=V.createContext({}),pt=function(dn){var ri=dn.children,Wn=dn.classNames;return V.createElement(et.Provider,{value:{classNames:Wn}},ri)},Ke=pt,ft=A(13255),wt=8,Se=3,Ft=16,mt=function(dn){var ri={offset:wt,threshold:Se,gap:Ft};if(dn&&(0,ft.Z)(dn)==="object"){var Wn,Rn,di;ri.offset=(Wn=dn.offset)!==null&&Wn!==void 0?Wn:wt,ri.threshold=(Rn=dn.threshold)!==null&&Rn!==void 0?Rn:Se,ri.gap=(di=dn.gap)!==null&&di!==void 0?di:Ft}return[!!dn,ri]},ot=mt,We=["className","style","classNames","styles"],Me=function(dn){var ri,Wn=dn.configList,Rn=dn.placement,di=dn.prefixCls,zi=dn.className,Gi=dn.style,Lo=dn.motion,eo=dn.onAllNoticeRemoved,ba=dn.onNoticeClose,va=dn.stack,Do=(0,V.useContext)(et),Ps=Do.classNames,Nr=(0,V.useRef)({}),fo=(0,V.useState)(null),hi=(0,ct.Z)(fo,2),Yi=hi[0],ga=hi[1],Xi=(0,V.useState)([]),On=(0,ct.Z)(Xi,2),gi=On[0],ol=On[1],ks=Wn.map(function(fl){return{config:fl,key:String(fl.key)}}),as=ot(va),_s=(0,ct.Z)(as,2),Ks=_s[0],Ea=_s[1],hs=Ea.offset,Ju=Ea.threshold,Fa=Ea.gap,dc=Ks&&(gi.length>0||ks.length<=Ju),el=typeof Lo=="function"?Lo(Rn):Lo;return(0,V.useEffect)(function(){Ks&&gi.length>1&&ol(function(fl){return fl.filter(function(As){return ks.some(function(Rl){var dl=Rl.key;return As===dl})})})},[gi,ks,Ks]),(0,V.useEffect)(function(){var fl;if(Ks&&Nr.current[(fl=ks[ks.length-1])===null||fl===void 0?void 0:fl.key]){var As;ga(Nr.current[(As=ks[ks.length-1])===null||As===void 0?void 0:As.key])}},[ks,Ks]),V.createElement(Ct.V4,(0,Rt.Z)({key:Rn,className:Ge()(di,"".concat(di,"-").concat(Rn),Ps==null?void 0:Ps.list,zi,(ri={},(0,gt.Z)(ri,"".concat(di,"-stack"),!!Ks),(0,gt.Z)(ri,"".concat(di,"-stack-expanded"),dc),ri)),style:Gi,keys:ks,motionAppear:!0},el,{onAllRemoved:function(){eo(Rn)}}),function(fl,As){var Rl=fl.config,dl=fl.className,_c=fl.style,lu=fl.index,Pn=Rl,Wr=Pn.key,Ci=Pn.times,at=String(Wr),Vt=Rl,gr=Vt.className,gn=Vt.style,un=Vt.classNames,Zi=Vt.styles,ho=(0,Ve.Z)(Vt,We),Na=ks.findIndex(function(Ho){return Ho.key===at}),mn={};if(Ks){var Lr=ks.length-1-(Na>-1?Na:lu-1),yr=Rn==="top"||Rn==="bottom"?"-50%":"0";if(Lr>0){var Mr,Zr,Vn;mn.height=dc?(Mr=Nr.current[at])===null||Mr===void 0?void 0:Mr.offsetHeight:Yi==null?void 0:Yi.offsetHeight;for(var In=0,Kn=0;Kn-1?Nr.current[at]=ya:delete Nr.current[at]},prefixCls:di,classNames:un,styles:Zi,className:Ge()(gr,Ps==null?void 0:Ps.notice),style:gn,times:Ci,key:Wr,eventKey:Wr,onNoticeClose:ba,hovering:Ks&&gi.length>0})))})},st=Me,Qe=V.forwardRef(function(on,dn){var ri=on.prefixCls,Wn=ri===void 0?"rc-notification":ri,Rn=on.container,di=on.motion,zi=on.maxCount,Gi=on.className,Lo=on.style,eo=on.onAllRemoved,ba=on.stack,va=on.renderNotifications,Do=V.useState([]),Ps=(0,ct.Z)(Do,2),Nr=Ps[0],fo=Ps[1],hi=function(_s){var Ks,Ea=Nr.find(function(hs){return hs.key===_s});Ea==null||(Ks=Ea.onClose)===null||Ks===void 0||Ks.call(Ea),fo(function(hs){return hs.filter(function(Ju){return Ju.key!==_s})})};V.useImperativeHandle(dn,function(){return{open:function(_s){fo(function(Ks){var Ea=(0,R.Z)(Ks),hs=Ea.findIndex(function(dc){return dc.key===_s.key}),Ju=(0,ut.Z)({},_s);if(hs>=0){var Fa;Ju.times=(((Fa=Ks[hs])===null||Fa===void 0?void 0:Fa.times)||0)+1,Ea[hs]=Ju}else Ju.times=0,Ea.push(Ju);return zi>0&&Ea.length>zi&&(Ea=Ea.slice(-zi)),Ea})},close:function(_s){hi(_s)},destroy:function(){fo([])}}});var Yi=V.useState({}),ga=(0,ct.Z)(Yi,2),Xi=ga[0],On=ga[1];V.useEffect(function(){var as={};Nr.forEach(function(_s){var Ks=_s.placement,Ea=Ks===void 0?"topRight":Ks;Ea&&(as[Ea]=as[Ea]||[],as[Ea].push(_s))}),Object.keys(Xi).forEach(function(_s){as[_s]=as[_s]||[]}),On(as)},[Nr]);var gi=function(_s){On(function(Ks){var Ea=(0,ut.Z)({},Ks),hs=Ea[_s]||[];return hs.length||delete Ea[_s],Ea})},ol=V.useRef(!1);if(V.useEffect(function(){Object.keys(Xi).length>0?ol.current=!0:ol.current&&(eo==null||eo(),ol.current=!1)},[Xi]),!Rn)return null;var ks=Object.keys(Xi);return(0,Xe.createPortal)(V.createElement(V.Fragment,null,ks.map(function(as){var _s=Xi[as],Ks=V.createElement(st,{key:as,configList:_s,placement:as,prefixCls:Wn,className:Gi==null?void 0:Gi(as),style:Lo==null?void 0:Lo(as),motion:di,onNoticeClose:hi,onAllNoticeRemoved:gi,stack:ba});return va?va(Ks,{prefixCls:Wn,key:as}):Ks})),Rn)}),dr=Qe,Kt=["getContainer","motion","prefixCls","maxCount","className","style","onAllRemoved","stack","renderNotifications"],Yr=function(){return document.body},hn=0;function ln(){for(var on={},dn=arguments.length,ri=new Array(dn),Wn=0;Wn0&&arguments[0]!==void 0?arguments[0]:{},dn=on.getContainer,ri=dn===void 0?Yr:dn,Wn=on.motion,Rn=on.prefixCls,di=on.maxCount,zi=on.className,Gi=on.style,Lo=on.onAllRemoved,eo=on.stack,ba=on.renderNotifications,va=(0,Ve.Z)(on,Kt),Do=V.useState(),Ps=(0,ct.Z)(Do,2),Nr=Ps[0],fo=Ps[1],hi=V.useRef(),Yi=V.createElement(dr,{container:Nr,ref:hi,prefixCls:Rn,motion:Wn,maxCount:di,className:zi,style:Gi,onAllRemoved:Lo,stack:eo,renderNotifications:ba}),ga=V.useState([]),Xi=(0,ct.Z)(ga,2),On=Xi[0],gi=Xi[1],ol=V.useMemo(function(){return{open:function(as){var _s=ln(va,as);(_s.key===null||_s.key===void 0)&&(_s.key="rc-notification-".concat(hn),hn+=1),gi(function(Ks){return[].concat((0,R.Z)(Ks),[{type:"open",config:_s}])})},close:function(as){gi(function(_s){return[].concat((0,R.Z)(_s),[{type:"close",key:as}])})},destroy:function(){gi(function(as){return[].concat((0,R.Z)(as),[{type:"destroy"}])})}}},[]);return V.useEffect(function(){fo(ri())}),V.useEffect(function(){hi.current&&On.length&&(On.forEach(function(ks){switch(ks.type){case"open":hi.current.open(ks.config);break;case"close":hi.current.close(ks.key);break;case"destroy":hi.current.destroy();break}}),gi(function(ks){return ks.filter(function(as){return!On.includes(as)})}))},[On]),[ol,Yi]}var Nn=A(78600),$n=A(66187),_i=A(75199),Qn=A(93319),Ji=A(12228);const ni=on=>{const{componentCls:dn,iconCls:ri,boxShadow:Wn,colorText:Rn,colorSuccess:di,colorError:zi,colorWarning:Gi,colorInfo:Lo,fontSizeLG:eo,motionEaseInOutCirc:ba,motionDurationSlow:va,marginXS:Do,paddingXS:Ps,borderRadiusLG:Nr,zIndexPopup:fo,contentPadding:hi,contentBg:Yi}=on,ga=`${dn}-notice`,Xi=new Nn.E4("MessageMoveIn",{"0%":{padding:0,transform:"translateY(-100%)",opacity:0},"100%":{padding:Ps,transform:"translateY(0)",opacity:1}}),On=new Nn.E4("MessageMoveOut",{"0%":{maxHeight:on.height,padding:Ps,opacity:1},"100%":{maxHeight:0,padding:0,opacity:0}}),gi={padding:Ps,textAlign:"center",[`${dn}-custom-content > ${ri}`]:{verticalAlign:"text-bottom",marginInlineEnd:Do,fontSize:eo},[`${ga}-content`]:{display:"inline-block",padding:hi,background:Yi,borderRadius:Nr,boxShadow:Wn,pointerEvents:"all"},[`${dn}-success > ${ri}`]:{color:di},[`${dn}-error > ${ri}`]:{color:zi},[`${dn}-warning > ${ri}`]:{color:Gi},[`${dn}-info > ${ri}, + ${dn}-loading > ${ri}`]:{color:Lo}};return[{[dn]:Object.assign(Object.assign({},(0,_i.Wf)(on)),{color:Rn,position:"fixed",top:Do,width:"100%",pointerEvents:"none",zIndex:fo,[`${dn}-move-up`]:{animationFillMode:"forwards"},[` + ${dn}-move-up-appear, + ${dn}-move-up-enter + `]:{animationName:Xi,animationDuration:va,animationPlayState:"paused",animationTimingFunction:ba},[` + ${dn}-move-up-appear${dn}-move-up-appear-active, + ${dn}-move-up-enter${dn}-move-up-enter-active + `]:{animationPlayState:"running"},[`${dn}-move-up-leave`]:{animationName:On,animationDuration:va,animationPlayState:"paused",animationTimingFunction:ba},[`${dn}-move-up-leave${dn}-move-up-leave-active`]:{animationPlayState:"running"},"&-rtl":{direction:"rtl",span:{direction:"rtl"}}})},{[dn]:{[`${ga}-wrapper`]:Object.assign({},gi)}},{[`${dn}-notice-pure-panel`]:Object.assign(Object.assign({},gi),{padding:0,textAlign:"start"})}]},Ei=on=>({zIndexPopup:on.zIndexPopupBase+$n.u6+10,contentBg:on.colorBgElevated,contentPadding:`${(on.controlHeightLG-on.fontSize*on.lineHeight)/2}px ${on.paddingSM}px`});var xo=(0,Qn.I$)("Message",on=>{const dn=(0,Ji.TS)(on,{height:150});return[ni(dn)]},Ei),sn=A(76135),li=function(on,dn){var ri={};for(var Wn in on)Object.prototype.hasOwnProperty.call(on,Wn)&&dn.indexOf(Wn)<0&&(ri[Wn]=on[Wn]);if(on!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Rn=0,Wn=Object.getOwnPropertySymbols(on);Rn{let{prefixCls:dn,type:ri,icon:Wn,children:Rn}=on;return V.createElement("div",{className:Ge()(`${dn}-custom-content`,`${dn}-${ri}`)},Wn||En[ri],V.createElement("span",null,Rn))};var Bo=on=>{const{prefixCls:dn,className:ri,type:Wn,icon:Rn,content:di}=on,zi=li(on,["prefixCls","className","type","icon","content"]),{getPrefixCls:Gi}=V.useContext(se.E_),Lo=dn||Gi("message"),eo=(0,sn.Z)(Lo),[ba,va,Do]=xo(Lo,eo);return ba(V.createElement(bt,Object.assign({},zi,{prefixCls:Lo,className:Ge()(ri,va,`${Lo}-notice-pure-panel`,Do,eo),eventKey:"pure",duration:null,content:V.createElement(or,{prefixCls:Lo,type:Wn,icon:Rn},di)})))},Mo=A(39694),Wi=A(58068);function Ii(on,dn){return{motionName:dn!=null?dn:`${on}-move-up`}}function ko(on){let dn;const ri=new Promise(Rn=>{dn=on(()=>{Rn(!0)})}),Wn=()=>{dn==null||dn()};return Wn.then=(Rn,di)=>ri.then(Rn,di),Wn.promise=ri,Wn}var Fn=function(on,dn){var ri={};for(var Wn in on)Object.prototype.hasOwnProperty.call(on,Wn)&&dn.indexOf(Wn)<0&&(ri[Wn]=on[Wn]);if(on!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Rn=0,Wn=Object.getOwnPropertySymbols(on);Rn{let{children:dn,prefixCls:ri}=on;const Wn=(0,sn.Z)(ri),[Rn,di,zi]=xo(ri,Wn);return Rn(V.createElement(Ke,{classNames:{list:Ge()(di,zi,Wn)}},dn))},Ki=(on,dn)=>{let{prefixCls:ri,key:Wn}=dn;return V.createElement(Hi,{prefixCls:ri,key:Wn},on)},Fo=V.forwardRef((on,dn)=>{const{top:ri,prefixCls:Wn,getContainer:Rn,maxCount:di,duration:zi=Un,rtl:Gi,transitionName:Lo,onAllRemoved:eo}=on,{getPrefixCls:ba,getPopupContainer:va,message:Do,direction:Ps}=V.useContext(se.E_),Nr=Wn||ba("message"),fo=()=>({left:"50%",transform:"translateX(-50%)",top:ri!=null?ri:zn}),hi=()=>Ge()({[`${Nr}-rtl`]:Gi!=null?Gi:Ps==="rtl"}),Yi=()=>Ii(Nr,Lo),ga=V.createElement("span",{className:`${Nr}-close-x`},V.createElement(Mo.Z,{className:`${Nr}-close-icon`})),[Xi,On]=oi({prefixCls:Nr,style:fo,className:hi,motion:Yi,closable:!1,closeIcon:ga,duration:zi,getContainer:()=>(Rn==null?void 0:Rn())||(va==null?void 0:va())||document.body,maxCount:di,onAllRemoved:eo,renderNotifications:Ki});return V.useImperativeHandle(dn,()=>Object.assign(Object.assign({},Xi),{prefixCls:Nr,message:Do})),On});let xt=0;function it(on){const dn=V.useRef(null),ri=(0,Wi.ln)("Message");return[V.useMemo(()=>{const Rn=eo=>{var ba;(ba=dn.current)===null||ba===void 0||ba.close(eo)},di=eo=>{if(!dn.current){const ks=()=>{};return ks.then=()=>{},ks}const{open:ba,prefixCls:va,message:Do}=dn.current,Ps=`${va}-notice`,{content:Nr,icon:fo,type:hi,key:Yi,className:ga,style:Xi,onClose:On}=eo,gi=Fn(eo,["content","icon","type","key","className","style","onClose"]);let ol=Yi;return ol==null&&(xt+=1,ol=`antd-message-${xt}`),ko(ks=>(ba(Object.assign(Object.assign({},gi),{key:ol,content:V.createElement(or,{prefixCls:va,type:hi,icon:fo},Nr),placement:"top",className:Ge()(hi&&`${Ps}-${hi}`,ga,Do==null?void 0:Do.className),style:Object.assign(Object.assign({},Do==null?void 0:Do.style),Xi),onClose:()=>{On==null||On(),ks()}})),()=>{Rn(ol)}))},Gi={open:di,destroy:eo=>{var ba;eo!==void 0?Rn(eo):(ba=dn.current)===null||ba===void 0||ba.destroy()}};return["info","success","warning","error","loading"].forEach(eo=>{const ba=(va,Do,Ps)=>{let Nr;va&&typeof va=="object"&&"content"in va?Nr=va:Nr={content:va};let fo,hi;typeof Do=="function"?hi=Do:(fo=Do,hi=Ps);const Yi=Object.assign(Object.assign({onClose:hi,duration:fo},Nr),{type:eo});return di(Yi)};Gi[eo]=ba}),Gi},[]),V.createElement(Fo,Object.assign({key:"message-holder"},on,{ref:dn}))]}function kt(on){return it(on)}let ir=null,Pr=on=>on(),kr=[],An={};function Dn(){const{getContainer:on,duration:dn,rtl:ri,maxCount:Wn,top:Rn}=An,di=(on==null?void 0:on())||document.body;return{getContainer:()=>di,duration:dn,rtl:ri,maxCount:Wn,top:Rn}}const Ht=V.forwardRef((on,dn)=>{const{messageConfig:ri,sync:Wn}=on,{getPrefixCls:Rn}=(0,V.useContext)(se.E_),di=An.prefixCls||Rn("message"),zi=(0,V.useContext)(p),[Gi,Lo]=it(Object.assign(Object.assign(Object.assign({},ri),{prefixCls:di}),zi.message));return V.useImperativeHandle(dn,()=>{const eo=Object.assign({},Gi);return Object.keys(eo).forEach(ba=>{eo[ba]=function(){return Wn(),Gi[ba].apply(Gi,arguments)}}),{instance:eo,sync:Wn}}),Lo}),Lt=V.forwardRef((on,dn)=>{const[ri,Wn]=V.useState(Dn),Rn=()=>{Wn(Dn)};V.useEffect(Rn,[]);const di=(0,ae.w6)(),zi=di.getRootPrefixCls(),Gi=di.getIconPrefixCls(),Lo=di.getTheme(),eo=V.createElement(Ht,{ref:dn,sync:Rn,messageConfig:ri});return V.createElement(ae.ZP,{prefixCls:zi,iconPrefixCls:Gi,theme:Lo},di.holderRender?di.holderRender(eo):eo)});function je(){if(!ir){const on=document.createDocumentFragment(),dn={fragment:on};ir=dn,Pr(()=>{(0,y.s)(V.createElement(Lt,{ref:ri=>{const{instance:Wn,sync:Rn}=ri||{};Promise.resolve().then(()=>{!dn.instance&&Wn&&(dn.instance=Wn,dn.sync=Rn,je())})}}),on)});return}ir.instance&&(kr.forEach(on=>{const{type:dn,skipped:ri}=on;if(!ri)switch(dn){case"open":{Pr(()=>{const Wn=ir.instance.open(Object.assign(Object.assign({},An),on.config));Wn==null||Wn.then(on.resolve),on.setCloseFn(Wn)});break}case"destroy":Pr(()=>{ir==null||ir.instance.destroy(on.key)});break;default:Pr(()=>{var Wn;const Rn=(Wn=ir.instance)[dn].apply(Wn,(0,R.Z)(on.args));Rn==null||Rn.then(on.resolve),on.setCloseFn(Rn)})}}),kr=[])}function $e(on){An=Object.assign(Object.assign({},An),on),Pr(()=>{var dn;(dn=ir==null?void 0:ir.sync)===null||dn===void 0||dn.call(ir)})}function At(on){const dn=ko(ri=>{let Wn;const Rn={type:"open",config:on,resolve:ri,setCloseFn:di=>{Wn=di}};return kr.push(Rn),()=>{Wn?Pr(()=>{Wn()}):Rn.skipped=!0}});return je(),dn}function Bt(on,dn){const ri=(0,ae.w6)(),Wn=ko(Rn=>{let di;const zi={type:on,args:dn,resolve:Rn,setCloseFn:Gi=>{di=Gi}};return kr.push(zi),()=>{di?Pr(()=>{di()}):zi.skipped=!0}});return je(),Wn}function Jt(on){kr.push({type:"destroy",key:on}),je()}const ar=["success","info","warning","error","loading"],Gt={open:At,destroy:Jt,config:$e,useMessage:kt,_InternalPanelDoNotUseOrYouWillBeFired:Bo};ar.forEach(on=>{Gt[on]=function(){for(var dn=arguments.length,ri=new Array(dn),Wn=0;Wn{};let nn=null,bn=null;var Bi=Gt},51877:function(Ye,ye,A){"use strict";A.d(ye,{A:function(){return X},f:function(){return $}});var R=A(23244);let V=Object.assign({},R.Z.Modal),y=[];const p=()=>y.reduce((se,ae)=>Object.assign(Object.assign({},se),ae),R.Z.Modal);function $(se){if(se){const ae=Object.assign({},se);return y.push(ae),V=p(),()=>{y=y.filter(ce=>ce!==ae),V=p()}}V=Object.assign({},R.Z.Modal)}function X(){return V}},16138:function(Ye,ye,A){"use strict";A.d(ye,{ZP:function(){return $n}});var R=A(77617),V=A(92310),y=A.n(V),p=A(84381),$=A(3286),X=A(11908),se=A(15550);const ae=R.createContext(null),ce=ae.Provider;var le=ae;const De=R.createContext(null),we=De.Provider;var Ee=A(79384),qe=A(54131),Ge=A(16514),ct=A(35372),Ve=A(56348),ut=["prefixCls","className","style","checked","disabled","defaultChecked","type","title","onChange"],Xe=(0,R.forwardRef)(function(_i,Qn){var Ji,ni=_i.prefixCls,Ei=ni===void 0?"rc-checkbox":ni,xo=_i.className,sn=_i.style,li=_i.checked,En=_i.disabled,or=_i.defaultChecked,qi=or===void 0?!1:or,Bo=_i.type,Mo=Bo===void 0?"checkbox":Bo,Wi=_i.title,Ii=_i.onChange,ko=(0,Ve.Z)(_i,ut),Fn=(0,R.useRef)(null),zn=(0,p.Z)(qi,{value:li}),Un=(0,ct.Z)(zn,2),Hi=Un[0],Ki=Un[1];(0,R.useImperativeHandle)(Qn,function(){return{focus:function(){var kt;(kt=Fn.current)===null||kt===void 0||kt.focus()},blur:function(){var kt;(kt=Fn.current)===null||kt===void 0||kt.blur()},input:Fn.current}});var Fo=y()(Ei,xo,(Ji={},(0,Ge.Z)(Ji,"".concat(Ei,"-checked"),Hi),(0,Ge.Z)(Ji,"".concat(Ei,"-disabled"),En),Ji)),xt=function(kt){En||("checked"in _i||Ki(kt.target.checked),Ii==null||Ii({target:(0,qe.Z)((0,qe.Z)({},_i),{},{type:Mo,checked:kt.target.checked}),stopPropagation:function(){kt.stopPropagation()},preventDefault:function(){kt.preventDefault()},nativeEvent:kt.nativeEvent}))};return R.createElement("span",{className:Fo,title:Wi,style:sn},R.createElement("input",(0,Ee.Z)({},ko,{className:"".concat(Ei,"-input"),ref:Fn,onChange:xt,disabled:En,checked:!!Hi,type:Mo})),R.createElement("span",{className:"".concat(Ei,"-inner")}))}),Rt=Xe,gt=A(88831),Ct=A(68306),tt=A(10946),Ne=A(50138),bt=A(53615),et=A(78600),pt=A(75199),Ke=A(93319),ft=A(12228);const wt=_i=>{const{componentCls:Qn,antCls:Ji}=_i,ni=`${Qn}-group`;return{[ni]:Object.assign(Object.assign({},(0,pt.Wf)(_i)),{display:"inline-block",fontSize:0,[`&${ni}-rtl`]:{direction:"rtl"},[`${Ji}-badge ${Ji}-badge-count`]:{zIndex:1},[`> ${Ji}-badge:not(:first-child) > ${Ji}-button-wrapper`]:{borderInlineStart:"none"}})}},Se=_i=>{const{componentCls:Qn,wrapperMarginInlineEnd:Ji,colorPrimary:ni,radioSize:Ei,motionDurationSlow:xo,motionDurationMid:sn,motionEaseInOutCirc:li,colorBgContainer:En,colorBorder:or,lineWidth:qi,colorBgContainerDisabled:Bo,colorTextDisabled:Mo,paddingXS:Wi,dotColorDisabled:Ii,lineType:ko,radioColor:Fn,radioBgColor:zn,calc:Un}=_i,Hi=`${Qn}-inner`,Ki=4,Fo=Un(Ei).sub(Un(Ki).mul(2)),xt=Un(1).mul(Ei).equal();return{[`${Qn}-wrapper`]:Object.assign(Object.assign({},(0,pt.Wf)(_i)),{display:"inline-flex",alignItems:"baseline",marginInlineStart:0,marginInlineEnd:Ji,cursor:"pointer",[`&${Qn}-wrapper-rtl`]:{direction:"rtl"},"&-disabled":{cursor:"not-allowed",color:_i.colorTextDisabled},"&::after":{display:"inline-block",width:0,overflow:"hidden",content:'"\\a0"'},[`${Qn}-checked::after`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,width:"100%",height:"100%",border:`${(0,et.bf)(qi)} ${ko} ${ni}`,borderRadius:"50%",visibility:"hidden",content:'""'},[Qn]:Object.assign(Object.assign({},(0,pt.Wf)(_i)),{position:"relative",display:"inline-block",outline:"none",cursor:"pointer",alignSelf:"center",borderRadius:"50%"}),[`${Qn}-wrapper:hover &, + &:hover ${Hi}`]:{borderColor:ni},[`${Qn}-input:focus-visible + ${Hi}`]:Object.assign({},(0,pt.oN)(_i)),[`${Qn}:hover::after, ${Qn}-wrapper:hover &::after`]:{visibility:"visible"},[`${Qn}-inner`]:{"&::after":{boxSizing:"border-box",position:"absolute",insetBlockStart:"50%",insetInlineStart:"50%",display:"block",width:xt,height:xt,marginBlockStart:Un(1).mul(Ei).div(-2).equal(),marginInlineStart:Un(1).mul(Ei).div(-2).equal(),backgroundColor:Fn,borderBlockStart:0,borderInlineStart:0,borderRadius:xt,transform:"scale(0)",opacity:0,transition:`all ${xo} ${li}`,content:'""'},boxSizing:"border-box",position:"relative",insetBlockStart:0,insetInlineStart:0,display:"block",width:xt,height:xt,backgroundColor:En,borderColor:or,borderStyle:"solid",borderWidth:qi,borderRadius:"50%",transition:`all ${sn}`},[`${Qn}-input`]:{position:"absolute",inset:0,zIndex:1,cursor:"pointer",opacity:0},[`${Qn}-checked`]:{[Hi]:{borderColor:ni,backgroundColor:zn,"&::after":{transform:`scale(${_i.calc(_i.dotSize).div(Ei).equal()})`,opacity:1,transition:`all ${xo} ${li}`}}},[`${Qn}-disabled`]:{cursor:"not-allowed",[Hi]:{backgroundColor:Bo,borderColor:or,cursor:"not-allowed","&::after":{backgroundColor:Ii}},[`${Qn}-input`]:{cursor:"not-allowed"},[`${Qn}-disabled + span`]:{color:Mo,cursor:"not-allowed"},[`&${Qn}-checked`]:{[Hi]:{"&::after":{transform:`scale(${Un(Fo).div(Ei).equal({unit:!1})})`}}}},[`span${Qn} + *`]:{paddingInlineStart:Wi,paddingInlineEnd:Wi}})}},Ft=_i=>{const{buttonColor:Qn,controlHeight:Ji,componentCls:ni,lineWidth:Ei,lineType:xo,colorBorder:sn,motionDurationSlow:li,motionDurationMid:En,buttonPaddingInline:or,fontSize:qi,buttonBg:Bo,fontSizeLG:Mo,controlHeightLG:Wi,controlHeightSM:Ii,paddingXS:ko,borderRadius:Fn,borderRadiusSM:zn,borderRadiusLG:Un,buttonCheckedBg:Hi,buttonSolidCheckedColor:Ki,colorTextDisabled:Fo,colorBgContainerDisabled:xt,buttonCheckedBgDisabled:it,buttonCheckedColorDisabled:kt,colorPrimary:ir,colorPrimaryHover:Pr,colorPrimaryActive:kr,buttonSolidCheckedBg:An,buttonSolidCheckedHoverBg:Dn,buttonSolidCheckedActiveBg:Ht,calc:Lt}=_i;return{[`${ni}-button-wrapper`]:{position:"relative",display:"inline-block",height:Ji,margin:0,paddingInline:or,paddingBlock:0,color:Qn,fontSize:qi,lineHeight:(0,et.bf)(Lt(Ji).sub(Lt(Ei).mul(2)).equal()),background:Bo,border:`${(0,et.bf)(Ei)} ${xo} ${sn}`,borderBlockStartWidth:Lt(Ei).add(.02).equal(),borderInlineStartWidth:0,borderInlineEndWidth:Ei,cursor:"pointer",transition:[`color ${En}`,`background ${En}`,`box-shadow ${En}`].join(","),a:{color:Qn},[`> ${ni}-button`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,zIndex:-1,width:"100%",height:"100%"},"&:not(:first-child)":{"&::before":{position:"absolute",insetBlockStart:Lt(Ei).mul(-1).equal(),insetInlineStart:Lt(Ei).mul(-1).equal(),display:"block",boxSizing:"content-box",width:1,height:"100%",paddingBlock:Ei,paddingInline:0,backgroundColor:sn,transition:`background-color ${li}`,content:'""'}},"&:first-child":{borderInlineStart:`${(0,et.bf)(Ei)} ${xo} ${sn}`,borderStartStartRadius:Fn,borderEndStartRadius:Fn},"&:last-child":{borderStartEndRadius:Fn,borderEndEndRadius:Fn},"&:first-child:last-child":{borderRadius:Fn},[`${ni}-group-large &`]:{height:Wi,fontSize:Mo,lineHeight:(0,et.bf)(Lt(Wi).sub(Lt(Ei).mul(2)).equal()),"&:first-child":{borderStartStartRadius:Un,borderEndStartRadius:Un},"&:last-child":{borderStartEndRadius:Un,borderEndEndRadius:Un}},[`${ni}-group-small &`]:{height:Ii,paddingInline:Lt(ko).sub(Ei).equal(),paddingBlock:0,lineHeight:(0,et.bf)(Lt(Ii).sub(Lt(Ei).mul(2)).equal()),"&:first-child":{borderStartStartRadius:zn,borderEndStartRadius:zn},"&:last-child":{borderStartEndRadius:zn,borderEndEndRadius:zn}},"&:hover":{position:"relative",color:ir},"&:has(:focus-visible)":Object.assign({},(0,pt.oN)(_i)),[`${ni}-inner, input[type='checkbox'], input[type='radio']`]:{width:0,height:0,opacity:0,pointerEvents:"none"},[`&-checked:not(${ni}-button-wrapper-disabled)`]:{zIndex:1,color:ir,background:Hi,borderColor:ir,"&::before":{backgroundColor:ir},"&:first-child":{borderColor:ir},"&:hover":{color:Pr,borderColor:Pr,"&::before":{backgroundColor:Pr}},"&:active":{color:kr,borderColor:kr,"&::before":{backgroundColor:kr}}},[`${ni}-group-solid &-checked:not(${ni}-button-wrapper-disabled)`]:{color:Ki,background:An,borderColor:An,"&:hover":{color:Ki,background:Dn,borderColor:Dn},"&:active":{color:Ki,background:Ht,borderColor:Ht}},"&-disabled":{color:Fo,backgroundColor:xt,borderColor:sn,cursor:"not-allowed","&:first-child, &:hover":{color:Fo,backgroundColor:xt,borderColor:sn}},[`&-disabled${ni}-button-wrapper-checked`]:{color:kt,backgroundColor:it,borderColor:sn,boxShadow:"none"}}}},mt=_i=>{const{wireframe:Qn,padding:Ji,marginXS:ni,lineWidth:Ei,fontSizeLG:xo,colorText:sn,colorBgContainer:li,colorTextDisabled:En,controlItemBgActiveDisabled:or,colorTextLightSolid:qi,colorPrimary:Bo,colorPrimaryHover:Mo,colorPrimaryActive:Wi,colorWhite:Ii}=_i,ko=4,Fn=xo,zn=Qn?Fn-ko*2:Fn-(ko+Ei)*2;return{radioSize:Fn,dotSize:zn,dotColorDisabled:En,buttonSolidCheckedColor:qi,buttonSolidCheckedBg:Bo,buttonSolidCheckedHoverBg:Mo,buttonSolidCheckedActiveBg:Wi,buttonBg:li,buttonCheckedBg:li,buttonColor:sn,buttonCheckedBgDisabled:or,buttonCheckedColorDisabled:En,buttonPaddingInline:Ji-Ei,wrapperMarginInlineEnd:ni,radioColor:Qn?Bo:Ii,radioBgColor:Qn?li:Bo}};var ot=(0,Ke.I$)("Radio",_i=>{const{controlOutline:Qn,controlOutlineWidth:Ji}=_i,ni=`0 0 0 ${(0,et.bf)(Ji)} ${Qn}`,Ei=ni,xo=(0,ft.TS)(_i,{radioFocusShadow:ni,radioButtonFocusShadow:Ei});return[wt(xo),Se(xo),Ft(xo)]},mt,{unitless:{radioSize:!0,dotSize:!0}}),We=A(76135),Me=function(_i,Qn){var Ji={};for(var ni in _i)Object.prototype.hasOwnProperty.call(_i,ni)&&Qn.indexOf(ni)<0&&(Ji[ni]=_i[ni]);if(_i!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Ei=0,ni=Object.getOwnPropertySymbols(_i);Ei{var Ji,ni;const Ei=R.useContext(le),xo=R.useContext(De),{getPrefixCls:sn,direction:li,radio:En}=R.useContext(X.E_),or=R.useRef(null),qi=(0,gt.sQ)(Qn,or),{isFormItemInput:Bo}=R.useContext(bt.aM),Mo=Ht=>{var Lt,je;(Lt=_i.onChange)===null||Lt===void 0||Lt.call(_i,Ht),(je=Ei==null?void 0:Ei.onChange)===null||je===void 0||je.call(Ei,Ht)},{prefixCls:Wi,className:Ii,rootClassName:ko,children:Fn,style:zn,title:Un}=_i,Hi=Me(_i,["prefixCls","className","rootClassName","children","style","title"]),Ki=sn("radio",Wi),Fo=((Ei==null?void 0:Ei.optionType)||xo)==="button",xt=Fo?`${Ki}-button`:Ki,it=(0,We.Z)(Ki),[kt,ir,Pr]=ot(Ki,it),kr=Object.assign({},Hi),An=R.useContext(Ne.Z);Ei&&(kr.name=Ei.name,kr.onChange=Mo,kr.checked=_i.value===Ei.value,kr.disabled=(Ji=kr.disabled)!==null&&Ji!==void 0?Ji:Ei.disabled),kr.disabled=(ni=kr.disabled)!==null&&ni!==void 0?ni:An;const Dn=y()(`${xt}-wrapper`,{[`${xt}-wrapper-checked`]:kr.checked,[`${xt}-wrapper-disabled`]:kr.disabled,[`${xt}-wrapper-rtl`]:li==="rtl",[`${xt}-wrapper-in-form-item`]:Bo},En==null?void 0:En.className,Ii,ko,ir,Pr,it);return kt(R.createElement(Ct.Z,{component:"Radio",disabled:kr.disabled},R.createElement("label",{className:Dn,style:Object.assign(Object.assign({},En==null?void 0:En.style),zn),onMouseEnter:_i.onMouseEnter,onMouseLeave:_i.onMouseLeave,title:Un},R.createElement(Rt,Object.assign({},kr,{className:y()(kr.className,!Fo&&tt.A),type:"radio",prefixCls:xt,ref:qi})),Fn!==void 0?R.createElement("span",null,Fn):null)))};var dr=R.forwardRef(st);const Kt=R.forwardRef((_i,Qn)=>{const{getPrefixCls:Ji,direction:ni}=R.useContext(X.E_),[Ei,xo]=(0,p.Z)(_i.defaultValue,{value:_i.value}),sn=Ht=>{const Lt=Ei,je=Ht.target.value;"value"in _i||xo(je);const{onChange:$e}=_i;$e&&je!==Lt&&$e(Ht)},{prefixCls:li,className:En,rootClassName:or,options:qi,buttonStyle:Bo="outline",disabled:Mo,children:Wi,size:Ii,style:ko,id:Fn,onMouseEnter:zn,onMouseLeave:Un,onFocus:Hi,onBlur:Ki}=_i,Fo=Ji("radio",li),xt=`${Fo}-group`,it=(0,We.Z)(Fo),[kt,ir,Pr]=ot(Fo,it);let kr=Wi;qi&&qi.length>0&&(kr=qi.map(Ht=>typeof Ht=="string"||typeof Ht=="number"?R.createElement(dr,{key:Ht.toString(),prefixCls:Fo,disabled:Mo,value:Ht,checked:Ei===Ht},Ht):R.createElement(dr,{key:`radio-group-value-options-${Ht.value}`,prefixCls:Fo,disabled:Ht.disabled||Mo,value:Ht.value,checked:Ei===Ht.value,title:Ht.title,style:Ht.style,id:Ht.id,required:Ht.required},Ht.label)));const An=(0,se.Z)(Ii),Dn=y()(xt,`${xt}-${Bo}`,{[`${xt}-${An}`]:An,[`${xt}-rtl`]:ni==="rtl"},En,or,ir,Pr,it);return kt(R.createElement("div",Object.assign({},(0,$.Z)(_i,{aria:!0,data:!0}),{className:Dn,style:ko,onMouseEnter:zn,onMouseLeave:Un,onFocus:Hi,onBlur:Ki,id:Fn,ref:Qn}),R.createElement(ce,{value:{onChange:sn,value:Ei,disabled:_i.disabled,name:_i.name,optionType:_i.optionType}},kr)))});var Yr=R.memo(Kt),hn=function(_i,Qn){var Ji={};for(var ni in _i)Object.prototype.hasOwnProperty.call(_i,ni)&&Qn.indexOf(ni)<0&&(Ji[ni]=_i[ni]);if(_i!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Ei=0,ni=Object.getOwnPropertySymbols(_i);Ei{const{getPrefixCls:Ji}=R.useContext(X.E_),{prefixCls:ni}=_i,Ei=hn(_i,["prefixCls"]),xo=Ji("radio",ni);return R.createElement(we,{value:"button"},R.createElement(dr,Object.assign({prefixCls:xo},Ei,{type:"radio",ref:Qn})))};var oi=R.forwardRef(ln);const Nn=dr;Nn.Button=oi,Nn.Group=Yr,Nn.__ANT_RADIO=!0;var $n=Nn},90997:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return Ps}});var R=A(77617),V=A(92310),y=A.n(V),p=A(99207),$=A(99468),X=A(66187),se=A(47562),ae=A(94379);const ce=null;function le(Nr,fo,hi){return y()({[`${Nr}-status-success`]:fo==="success",[`${Nr}-status-warning`]:fo==="warning",[`${Nr}-status-error`]:fo==="error",[`${Nr}-status-validating`]:fo==="validating",[`${Nr}-has-feedback`]:hi})}const De=(Nr,fo)=>fo||Nr;var we=A(11908),Ee=A(45402),Ge=Nr=>{const{componentName:fo}=Nr,{getPrefixCls:hi}=(0,R.useContext)(we.E_),Yi=hi("empty");switch(fo){case"Table":case"List":return R.createElement(Ee.Z,{image:Ee.Z.PRESENTED_IMAGE_SIMPLE});case"Select":case"TreeSelect":case"Cascader":case"Transfer":case"Mentions":return R.createElement(Ee.Z,{image:Ee.Z.PRESENTED_IMAGE_SIMPLE,className:`${Yi}-small`});default:return R.createElement(Ee.Z,null)}},ct=A(50138),Ve=A(76135),ut=A(15550),Xe=A(53615);const Rt=["outlined","borderless","filled"];var Ct=function(Nr){let fo=arguments.length>1&&arguments[1]!==void 0?arguments[1]:void 0;const hi=(0,R.useContext)(Xe.pg);let Yi;typeof Nr!="undefined"?Yi=Nr:fo===!1?Yi="borderless":Yi=hi!=null?hi:"outlined";const ga=Rt.includes(Yi);return[Yi,ga]},tt=A(53580),Ne=A(20573);const bt=Nr=>{const hi={overflow:{adjustX:!0,adjustY:!0,shiftY:!0},htmlRegion:Nr==="scroll"?"scroll":"visible",dynamicInset:!0};return{bottomLeft:Object.assign(Object.assign({},hi),{points:["tl","bl"],offset:[0,4]}),bottomRight:Object.assign(Object.assign({},hi),{points:["tr","br"],offset:[0,4]}),topLeft:Object.assign(Object.assign({},hi),{points:["bl","tl"],offset:[0,-4]}),topRight:Object.assign(Object.assign({},hi),{points:["br","tr"],offset:[0,-4]})}};function et(Nr,fo){return Nr||bt(fo)}var pt=et,Ke=A(75199),ft=A(5283),wt=A(93319),Se=A(12228),Ft=A(78600),mt=A(8264);const ot=new Ft.E4("antSlideUpIn",{"0%":{transform:"scaleY(0.8)",transformOrigin:"0% 0%",opacity:0},"100%":{transform:"scaleY(1)",transformOrigin:"0% 0%",opacity:1}}),We=new Ft.E4("antSlideUpOut",{"0%":{transform:"scaleY(1)",transformOrigin:"0% 0%",opacity:1},"100%":{transform:"scaleY(0.8)",transformOrigin:"0% 0%",opacity:0}}),Me=new Ft.E4("antSlideDownIn",{"0%":{transform:"scaleY(0.8)",transformOrigin:"100% 100%",opacity:0},"100%":{transform:"scaleY(1)",transformOrigin:"100% 100%",opacity:1}}),st=new Ft.E4("antSlideDownOut",{"0%":{transform:"scaleY(1)",transformOrigin:"100% 100%",opacity:1},"100%":{transform:"scaleY(0.8)",transformOrigin:"100% 100%",opacity:0}}),Qe=new Ft.E4("antSlideLeftIn",{"0%":{transform:"scaleX(0.8)",transformOrigin:"0% 0%",opacity:0},"100%":{transform:"scaleX(1)",transformOrigin:"0% 0%",opacity:1}}),dr=new Ft.E4("antSlideLeftOut",{"0%":{transform:"scaleX(1)",transformOrigin:"0% 0%",opacity:1},"100%":{transform:"scaleX(0.8)",transformOrigin:"0% 0%",opacity:0}}),Kt=new Ft.E4("antSlideRightIn",{"0%":{transform:"scaleX(0.8)",transformOrigin:"100% 0%",opacity:0},"100%":{transform:"scaleX(1)",transformOrigin:"100% 0%",opacity:1}}),Yr=new Ft.E4("antSlideRightOut",{"0%":{transform:"scaleX(1)",transformOrigin:"100% 0%",opacity:1},"100%":{transform:"scaleX(0.8)",transformOrigin:"100% 0%",opacity:0}}),hn={"slide-up":{inKeyframes:ot,outKeyframes:We},"slide-down":{inKeyframes:Me,outKeyframes:st},"slide-left":{inKeyframes:Qe,outKeyframes:dr},"slide-right":{inKeyframes:Kt,outKeyframes:Yr}},ln=(Nr,fo)=>{const{antCls:hi}=Nr,Yi=`${hi}-${fo}`,{inKeyframes:ga,outKeyframes:Xi}=hn[fo];return[(0,mt.R)(Yi,ga,Xi,Nr.motionDurationMid),{[` + ${Yi}-enter, + ${Yi}-appear + `]:{transform:"scale(0)",transformOrigin:"0% 0%",opacity:0,animationTimingFunction:Nr.motionEaseOutQuint,["&-prepare"]:{transform:"scale(1)"}},[`${Yi}-leave`]:{animationTimingFunction:Nr.motionEaseInQuint}}]},oi=new Ft.E4("antMoveDownIn",{"0%":{transform:"translate3d(0, 100%, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),Nn=new Ft.E4("antMoveDownOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(0, 100%, 0)",transformOrigin:"0 0",opacity:0}}),$n=new Ft.E4("antMoveLeftIn",{"0%":{transform:"translate3d(-100%, 0, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),_i=new Ft.E4("antMoveLeftOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(-100%, 0, 0)",transformOrigin:"0 0",opacity:0}}),Qn=new Ft.E4("antMoveRightIn",{"0%":{transform:"translate3d(100%, 0, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),Ji=new Ft.E4("antMoveRightOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(100%, 0, 0)",transformOrigin:"0 0",opacity:0}}),ni=new Ft.E4("antMoveUpIn",{"0%":{transform:"translate3d(0, -100%, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),Ei=new Ft.E4("antMoveUpOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(0, -100%, 0)",transformOrigin:"0 0",opacity:0}}),xo={"move-up":{inKeyframes:ni,outKeyframes:Ei},"move-down":{inKeyframes:oi,outKeyframes:Nn},"move-left":{inKeyframes:$n,outKeyframes:_i},"move-right":{inKeyframes:Qn,outKeyframes:Ji}},sn=(Nr,fo)=>{const{antCls:hi}=Nr,Yi=`${hi}-${fo}`,{inKeyframes:ga,outKeyframes:Xi}=xo[fo];return[(0,mt.R)(Yi,ga,Xi,Nr.motionDurationMid),{[` + ${Yi}-enter, + ${Yi}-appear + `]:{opacity:0,animationTimingFunction:Nr.motionEaseOutCirc},[`${Yi}-leave`]:{animationTimingFunction:Nr.motionEaseInOutCirc}}]},li=Nr=>{const{optionHeight:fo,optionFontSize:hi,optionLineHeight:Yi,optionPadding:ga}=Nr;return{position:"relative",display:"block",minHeight:fo,padding:ga,color:Nr.colorText,fontWeight:"normal",fontSize:hi,lineHeight:Yi,boxSizing:"border-box"}};var or=Nr=>{const{antCls:fo,componentCls:hi}=Nr,Yi=`${hi}-item`,ga=`&${fo}-slide-up-enter${fo}-slide-up-enter-active`,Xi=`&${fo}-slide-up-appear${fo}-slide-up-appear-active`,On=`&${fo}-slide-up-leave${fo}-slide-up-leave-active`,gi=`${hi}-dropdown-placement-`;return[{[`${hi}-dropdown`]:Object.assign(Object.assign({},(0,Ke.Wf)(Nr)),{position:"absolute",top:-9999,zIndex:Nr.zIndexPopup,boxSizing:"border-box",padding:Nr.paddingXXS,overflow:"hidden",fontSize:Nr.fontSize,fontVariant:"initial",backgroundColor:Nr.colorBgElevated,borderRadius:Nr.borderRadiusLG,outline:"none",boxShadow:Nr.boxShadowSecondary,[` + ${ga}${gi}bottomLeft, + ${Xi}${gi}bottomLeft + `]:{animationName:ot},[` + ${ga}${gi}topLeft, + ${Xi}${gi}topLeft, + ${ga}${gi}topRight, + ${Xi}${gi}topRight + `]:{animationName:Me},[`${On}${gi}bottomLeft`]:{animationName:We},[` + ${On}${gi}topLeft, + ${On}${gi}topRight + `]:{animationName:st},"&-hidden":{display:"none"},[`${Yi}`]:Object.assign(Object.assign({},li(Nr)),{cursor:"pointer",transition:`background ${Nr.motionDurationSlow} ease`,borderRadius:Nr.borderRadiusSM,"&-group":{color:Nr.colorTextDescription,fontSize:Nr.fontSizeSM,cursor:"default"},"&-option":{display:"flex","&-content":Object.assign({flex:"auto"},Ke.vS),"&-state":{flex:"none",display:"flex",alignItems:"center"},[`&-active:not(${Yi}-option-disabled)`]:{backgroundColor:Nr.optionActiveBg},[`&-selected:not(${Yi}-option-disabled)`]:{color:Nr.optionSelectedColor,fontWeight:Nr.optionSelectedFontWeight,backgroundColor:Nr.optionSelectedBg,[`${Yi}-option-state`]:{color:Nr.colorPrimary},[`&:has(+ ${Yi}-option-selected:not(${Yi}-option-disabled))`]:{borderEndStartRadius:0,borderEndEndRadius:0,[`& + ${Yi}-option-selected:not(${Yi}-option-disabled)`]:{borderStartStartRadius:0,borderStartEndRadius:0}}},"&-disabled":{[`&${Yi}-option-selected`]:{backgroundColor:Nr.colorBgContainerDisabled},color:Nr.colorTextDisabled,cursor:"not-allowed"},"&-grouped":{paddingInlineStart:Nr.calc(Nr.controlPaddingHorizontal).mul(2).equal()}},"&-empty":Object.assign(Object.assign({},li(Nr)),{color:Nr.colorTextDisabled})}),"&-rtl":{direction:"rtl"}})},ln(Nr,"slide-up"),ln(Nr,"slide-down"),sn(Nr,"move-up"),sn(Nr,"move-down")]};const qi=2,Bo=Nr=>{const{multipleSelectItemHeight:fo,selectHeight:hi,lineWidth:Yi}=Nr;return Nr.calc(hi).sub(fo).div(2).sub(Yi).equal()},Mo=(Nr,fo)=>{const{componentCls:hi,iconCls:Yi}=Nr,ga=`${hi}-selection-overflow`,Xi=Nr.multipleSelectItemHeight,On=Bo(Nr),gi=fo?`${hi}-${fo}`:"";return{[`${hi}-multiple${gi}`]:{[ga]:{position:"relative",display:"flex",flex:"auto",flexWrap:"wrap",maxWidth:"100%","&-item":{flex:"none",alignSelf:"center",maxWidth:"100%",display:"inline-flex"}},[`${hi}-selector`]:{display:"flex",flexWrap:"wrap",alignItems:"center",height:"100%",paddingInline:Nr.calc(qi).mul(2).equal(),paddingBlock:Nr.calc(On).sub(qi).equal(),borderRadius:Nr.borderRadius,[`${hi}-disabled&`]:{background:Nr.multipleSelectorBgDisabled,cursor:"not-allowed"},"&:after":{display:"inline-block",width:0,margin:`${(0,Ft.bf)(qi)} 0`,lineHeight:(0,Ft.bf)(Xi),visibility:"hidden",content:'"\\a0"'}},[`${hi}-selection-item`]:{display:"flex",alignSelf:"center",flex:"none",boxSizing:"border-box",maxWidth:"100%",height:Xi,marginTop:qi,marginBottom:qi,lineHeight:(0,Ft.bf)(Nr.calc(Xi).sub(Nr.calc(Nr.lineWidth).mul(2)).equal()),borderRadius:Nr.borderRadiusSM,cursor:"default",transition:`font-size ${Nr.motionDurationSlow}, line-height ${Nr.motionDurationSlow}, height ${Nr.motionDurationSlow}`,marginInlineEnd:Nr.calc(qi).mul(2).equal(),paddingInlineStart:Nr.paddingXS,paddingInlineEnd:Nr.calc(Nr.paddingXS).div(2).equal(),[`${hi}-disabled&`]:{color:Nr.multipleItemColorDisabled,borderColor:Nr.multipleItemBorderColorDisabled,cursor:"not-allowed"},"&-content":{display:"inline-block",marginInlineEnd:Nr.calc(Nr.paddingXS).div(2).equal(),overflow:"hidden",whiteSpace:"pre",textOverflow:"ellipsis"},"&-remove":Object.assign(Object.assign({},(0,Ke.Ro)()),{display:"inline-flex",alignItems:"center",color:Nr.colorIcon,fontWeight:"bold",fontSize:10,lineHeight:"inherit",cursor:"pointer",[`> ${Yi}`]:{verticalAlign:"-0.2em"},"&:hover":{color:Nr.colorIconHover}})},[`${ga}-item + ${ga}-item`]:{[`${hi}-selection-search`]:{marginInlineStart:0}},[`${ga}-item-suffix`]:{height:"100%"},[`${hi}-selection-search`]:{display:"inline-flex",position:"relative",maxWidth:"100%",marginInlineStart:Nr.calc(Nr.inputPaddingHorizontalBase).sub(On).equal(),[` + &-input, + &-mirror + `]:{height:Xi,fontFamily:Nr.fontFamily,lineHeight:(0,Ft.bf)(Xi),transition:`all ${Nr.motionDurationSlow}`},"&-input":{width:"100%",minWidth:4.1},"&-mirror":{position:"absolute",top:0,insetInlineStart:0,insetInlineEnd:"auto",zIndex:999,whiteSpace:"pre",visibility:"hidden"}},[`${hi}-selection-placeholder`]:{position:"absolute",top:"50%",insetInlineStart:Nr.inputPaddingHorizontalBase,insetInlineEnd:Nr.inputPaddingHorizontalBase,transform:"translateY(-50%)",transition:`all ${Nr.motionDurationSlow}`}}}};function Wi(Nr,fo){const{componentCls:hi}=Nr,Yi=fo?`${hi}-${fo}`:"",ga={[`${hi}-multiple${Yi}`]:{fontSize:Nr.fontSize,[`${hi}-selector`]:{[`${hi}-show-search&`]:{cursor:"text"}},[` + &${hi}-show-arrow ${hi}-selector, + &${hi}-allow-clear ${hi}-selector + `]:{paddingInlineEnd:Nr.calc(Nr.fontSizeIcon).add(Nr.controlPaddingHorizontal).equal()}}};return[Mo(Nr,fo),ga]}var ko=Nr=>{const{componentCls:fo}=Nr,hi=(0,Se.TS)(Nr,{selectHeight:Nr.controlHeightSM,multipleSelectItemHeight:Nr.controlHeightXS,borderRadius:Nr.borderRadiusSM,borderRadiusSM:Nr.borderRadiusXS}),Yi=(0,Se.TS)(Nr,{fontSize:Nr.fontSizeLG,selectHeight:Nr.controlHeightLG,multipleSelectItemHeight:Nr.multipleItemHeightLG,borderRadius:Nr.borderRadiusLG,borderRadiusSM:Nr.borderRadius});return[Wi(Nr),Wi(hi,"sm"),{[`${fo}-multiple${fo}-sm`]:{[`${fo}-selection-placeholder`]:{insetInline:Nr.calc(Nr.controlPaddingHorizontalSM).sub(Nr.lineWidth).equal()},[`${fo}-selection-search`]:{marginInlineStart:2}}},Wi(Yi,"lg")]};function Fn(Nr,fo){const{componentCls:hi,inputPaddingHorizontalBase:Yi,borderRadius:ga}=Nr,Xi=Nr.calc(Nr.controlHeight).sub(Nr.calc(Nr.lineWidth).mul(2)).equal(),On=fo?`${hi}-${fo}`:"";return{[`${hi}-single${On}`]:{fontSize:Nr.fontSize,height:Nr.controlHeight,[`${hi}-selector`]:Object.assign(Object.assign({},(0,Ke.Wf)(Nr,!0)),{display:"flex",borderRadius:ga,[`${hi}-selection-search`]:{position:"absolute",top:0,insetInlineStart:Yi,insetInlineEnd:Yi,bottom:0,"&-input":{width:"100%",WebkitAppearance:"textfield"}},[` + ${hi}-selection-item, + ${hi}-selection-placeholder + `]:{padding:0,lineHeight:(0,Ft.bf)(Xi),transition:`all ${Nr.motionDurationSlow}, visibility 0s`,alignSelf:"center"},[`${hi}-selection-placeholder`]:{transition:"none",pointerEvents:"none"},[["&:after",`${hi}-selection-item:empty:after`,`${hi}-selection-placeholder:empty:after`].join(",")]:{display:"inline-block",width:0,visibility:"hidden",content:'"\\a0"'}}),[` + &${hi}-show-arrow ${hi}-selection-item, + &${hi}-show-arrow ${hi}-selection-placeholder + `]:{paddingInlineEnd:Nr.showArrowPaddingInlineEnd},[`&${hi}-open ${hi}-selection-item`]:{color:Nr.colorTextPlaceholder},[`&:not(${hi}-customize-input)`]:{[`${hi}-selector`]:{width:"100%",height:"100%",padding:`0 ${(0,Ft.bf)(Yi)}`,[`${hi}-selection-search-input`]:{height:Xi},"&:after":{lineHeight:(0,Ft.bf)(Xi)}}},[`&${hi}-customize-input`]:{[`${hi}-selector`]:{"&:after":{display:"none"},[`${hi}-selection-search`]:{position:"static",width:"100%"},[`${hi}-selection-placeholder`]:{position:"absolute",insetInlineStart:0,insetInlineEnd:0,padding:`0 ${(0,Ft.bf)(Yi)}`,"&:after":{display:"none"}}}}}}}function zn(Nr){const{componentCls:fo}=Nr,hi=Nr.calc(Nr.controlPaddingHorizontalSM).sub(Nr.lineWidth).equal();return[Fn(Nr),Fn((0,Se.TS)(Nr,{controlHeight:Nr.controlHeightSM,borderRadius:Nr.borderRadiusSM}),"sm"),{[`${fo}-single${fo}-sm`]:{[`&:not(${fo}-customize-input)`]:{[`${fo}-selection-search`]:{insetInlineStart:hi,insetInlineEnd:hi},[`${fo}-selector`]:{padding:`0 ${(0,Ft.bf)(hi)}`},[`&${fo}-show-arrow ${fo}-selection-search`]:{insetInlineEnd:Nr.calc(hi).add(Nr.calc(Nr.fontSize).mul(1.5)).equal()},[` + &${fo}-show-arrow ${fo}-selection-item, + &${fo}-show-arrow ${fo}-selection-placeholder + `]:{paddingInlineEnd:Nr.calc(Nr.fontSize).mul(1.5).equal()}}}},Fn((0,Se.TS)(Nr,{controlHeight:Nr.singleItemHeightLG,fontSize:Nr.fontSizeLG,borderRadius:Nr.borderRadiusLG}),"lg")]}const Un=Nr=>{const{fontSize:fo,lineHeight:hi,controlHeight:Yi,controlPaddingHorizontal:ga,zIndexPopupBase:Xi,colorText:On,fontWeightStrong:gi,controlItemBgActive:ol,controlItemBgHover:ks,colorBgContainer:as,colorFillSecondary:_s,controlHeightLG:Ks,controlHeightSM:Ea,colorBgContainerDisabled:hs,colorTextDisabled:Ju}=Nr;return{zIndexPopup:Xi+50,optionSelectedColor:On,optionSelectedFontWeight:gi,optionSelectedBg:ol,optionActiveBg:ks,optionPadding:`${(Yi-fo*hi)/2}px ${ga}px`,optionFontSize:fo,optionLineHeight:hi,optionHeight:Yi,selectorBg:as,clearBg:as,singleItemHeightLG:Ks,multipleItemBg:_s,multipleItemBorderColor:"transparent",multipleItemHeight:Ea,multipleItemHeightLG:Yi,multipleSelectorBgDisabled:hs,multipleItemColorDisabled:Ju,multipleItemBorderColorDisabled:"transparent",showArrowPaddingInlineEnd:Math.ceil(Nr.fontSize*1.25)}},Hi=(Nr,fo)=>{const{componentCls:hi,antCls:Yi,controlOutlineWidth:ga}=Nr;return{[`&:not(${hi}-customize-input) ${hi}-selector`]:{border:`${(0,Ft.bf)(Nr.lineWidth)} ${Nr.lineType} ${fo.borderColor}`,background:Nr.selectorBg},[`&:not(${hi}-disabled):not(${hi}-customize-input):not(${Yi}-pagination-size-changer)`]:{[`&:hover ${hi}-selector`]:{borderColor:fo.hoverBorderHover},[`${hi}-focused& ${hi}-selector`]:{borderColor:fo.activeBorderColor,boxShadow:`0 0 0 ${(0,Ft.bf)(ga)} ${fo.activeShadowColor}`,outline:0}}}},Ki=(Nr,fo)=>({[`&${Nr.componentCls}-status-${fo.status}`]:Object.assign({},Hi(Nr,fo))}),Fo=Nr=>({"&-outlined":Object.assign(Object.assign(Object.assign(Object.assign({},Hi(Nr,{borderColor:Nr.colorBorder,hoverBorderHover:Nr.colorPrimaryHover,activeBorderColor:Nr.colorPrimary,activeShadowColor:Nr.controlOutline})),Ki(Nr,{status:"error",borderColor:Nr.colorError,hoverBorderHover:Nr.colorErrorHover,activeBorderColor:Nr.colorError,activeShadowColor:Nr.colorErrorOutline})),Ki(Nr,{status:"warning",borderColor:Nr.colorWarning,hoverBorderHover:Nr.colorWarningHover,activeBorderColor:Nr.colorWarning,activeShadowColor:Nr.colorWarningOutline})),{[`&${Nr.componentCls}-disabled`]:{[`&:not(${Nr.componentCls}-customize-input) ${Nr.componentCls}-selector`]:{background:Nr.colorBgContainerDisabled,color:Nr.colorTextDisabled}},[`&${Nr.componentCls}-multiple ${Nr.componentCls}-selection-item`]:{background:Nr.multipleItemBg,border:`${(0,Ft.bf)(Nr.lineWidth)} ${Nr.lineType} ${Nr.multipleItemBorderColor}`}})}),xt=(Nr,fo)=>{const{componentCls:hi,antCls:Yi}=Nr;return{[`&:not(${hi}-customize-input) ${hi}-selector`]:{background:fo.bg,border:`${(0,Ft.bf)(Nr.lineWidth)} ${Nr.lineType} transparent`,color:fo.color},[`&:not(${hi}-disabled):not(${hi}-customize-input):not(${Yi}-pagination-size-changer)`]:{[`&:hover ${hi}-selector`]:{background:fo.hoverBg},[`${hi}-focused& ${hi}-selector`]:{background:Nr.selectorBg,borderColor:fo.activeBorderColor,outline:0}}}},it=(Nr,fo)=>({[`&${Nr.componentCls}-status-${fo.status}`]:Object.assign({},xt(Nr,fo))}),kt=Nr=>({"&-filled":Object.assign(Object.assign(Object.assign(Object.assign({},xt(Nr,{bg:Nr.colorFillTertiary,hoverBg:Nr.colorFillSecondary,activeBorderColor:Nr.colorPrimary,color:Nr.colorText})),it(Nr,{status:"error",bg:Nr.colorErrorBg,hoverBg:Nr.colorErrorBgHover,activeBorderColor:Nr.colorError,color:Nr.colorError})),it(Nr,{status:"warning",bg:Nr.colorWarningBg,hoverBg:Nr.colorWarningBgHover,activeBorderColor:Nr.colorWarning,color:Nr.colorWarning})),{[`&${Nr.componentCls}-disabled`]:{[`&:not(${Nr.componentCls}-customize-input) ${Nr.componentCls}-selector`]:{borderColor:Nr.colorBorder,background:Nr.colorBgContainerDisabled,color:Nr.colorTextDisabled}},[`&${Nr.componentCls}-multiple ${Nr.componentCls}-selection-item`]:{background:Nr.colorBgContainer,border:`${(0,Ft.bf)(Nr.lineWidth)} ${Nr.lineType} ${Nr.colorSplit}`}})}),ir=Nr=>({"&-borderless":{[`${Nr.componentCls}-selector`]:{background:"transparent",borderColor:"transparent"},[`&${Nr.componentCls}-disabled`]:{[`&:not(${Nr.componentCls}-customize-input) ${Nr.componentCls}-selector`]:{color:Nr.colorTextDisabled}},[`&${Nr.componentCls}-multiple ${Nr.componentCls}-selection-item`]:{background:Nr.multipleItemBg,border:`${(0,Ft.bf)(Nr.lineWidth)} ${Nr.lineType} ${Nr.multipleItemBorderColor}`}}});var kr=Nr=>({[Nr.componentCls]:Object.assign(Object.assign(Object.assign({},Fo(Nr)),kt(Nr)),ir(Nr))});const An=Nr=>{const{componentCls:fo}=Nr;return{position:"relative",transition:`all ${Nr.motionDurationMid} ${Nr.motionEaseInOut}`,input:{cursor:"pointer"},[`${fo}-show-search&`]:{cursor:"text",input:{cursor:"auto",color:"inherit",height:"100%"}},[`${fo}-disabled&`]:{cursor:"not-allowed",input:{cursor:"not-allowed"}}}},Dn=Nr=>{const{componentCls:fo}=Nr;return{[`${fo}-selection-search-input`]:{margin:0,padding:0,background:"transparent",border:"none",outline:"none",appearance:"none",fontFamily:"inherit","&::-webkit-search-cancel-button":{display:"none","-webkit-appearance":"none"}}}},Ht=Nr=>{const{antCls:fo,componentCls:hi,inputPaddingHorizontalBase:Yi,iconCls:ga}=Nr;return{[hi]:Object.assign(Object.assign({},(0,Ke.Wf)(Nr)),{position:"relative",display:"inline-block",cursor:"pointer",[`&:not(${hi}-customize-input) ${hi}-selector`]:Object.assign(Object.assign({},An(Nr)),Dn(Nr)),[`${hi}-selection-item`]:Object.assign(Object.assign({flex:1,fontWeight:"normal",position:"relative",userSelect:"none"},Ke.vS),{[`> ${fo}-typography`]:{display:"inline"}}),[`${hi}-selection-placeholder`]:Object.assign(Object.assign({},Ke.vS),{flex:1,color:Nr.colorTextPlaceholder,pointerEvents:"none"}),[`${hi}-arrow`]:Object.assign(Object.assign({},(0,Ke.Ro)()),{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:Yi,height:Nr.fontSizeIcon,marginTop:Nr.calc(Nr.fontSizeIcon).mul(-1).div(2).equal(),color:Nr.colorTextQuaternary,fontSize:Nr.fontSizeIcon,lineHeight:1,textAlign:"center",pointerEvents:"none",display:"flex",alignItems:"center",transition:`opacity ${Nr.motionDurationSlow} ease`,[ga]:{verticalAlign:"top",transition:`transform ${Nr.motionDurationSlow}`,"> svg":{verticalAlign:"top"},[`&:not(${hi}-suffix)`]:{pointerEvents:"auto"}},[`${hi}-disabled &`]:{cursor:"not-allowed"},"> *:not(:last-child)":{marginInlineEnd:8}}),[`${hi}-clear`]:{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:Yi,zIndex:1,display:"inline-block",width:Nr.fontSizeIcon,height:Nr.fontSizeIcon,marginTop:Nr.calc(Nr.fontSizeIcon).mul(-1).div(2).equal(),color:Nr.colorTextQuaternary,fontSize:Nr.fontSizeIcon,fontStyle:"normal",lineHeight:1,textAlign:"center",textTransform:"none",cursor:"pointer",opacity:0,transition:`color ${Nr.motionDurationMid} ease, opacity ${Nr.motionDurationSlow} ease`,textRendering:"auto","&:before":{display:"block"},"&:hover":{color:Nr.colorTextTertiary}},"&:hover":{[`${hi}-clear`]:{opacity:1},[`${hi}-arrow:not(:last-child)`]:{opacity:0}}}),[`${hi}-has-feedback`]:{[`${hi}-clear`]:{insetInlineEnd:Nr.calc(Yi).add(Nr.fontSize).add(Nr.paddingXS).equal()}}}},Lt=Nr=>{const{componentCls:fo}=Nr;return[{[fo]:{[`&${fo}-in-form-item`]:{width:"100%"}}},Ht(Nr),zn(Nr),ko(Nr),or(Nr),{[`${fo}-rtl`]:{direction:"rtl"}},(0,ft.c)(Nr,{borderElCls:`${fo}-selector`,focusElCls:`${fo}-focused`})]};var je=(0,wt.I$)("Select",(Nr,fo)=>{let{rootPrefixCls:hi}=fo;const Yi=(0,Se.TS)(Nr,{rootPrefixCls:hi,inputPaddingHorizontalBase:Nr.calc(Nr.paddingSM).sub(1).equal(),multipleSelectItemHeight:Nr.multipleItemHeight,selectHeight:Nr.controlHeight});return[Lt(Yi),kr(Yi)]},Un,{unitless:{optionLineHeight:!0,optionSelectedFontWeight:!0}}),$e=A(79384),At={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474a32 32 0 00-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.3 0l488.4-618.9c4.1-5.1.4-12.8-6.3-12.8z"}}]},name:"check",theme:"outlined"},Bt=At,Jt=A(12213),ar=function(fo,hi){return R.createElement(Jt.Z,(0,$e.Z)({},fo,{ref:hi,icon:Bt}))},hr=R.forwardRef(ar),Gt=A(43418),Tr=A(39694),nn={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"}}]},name:"down",theme:"outlined"},bn=nn,Bi=function(fo,hi){return R.createElement(Jt.Z,(0,$e.Z)({},fo,{ref:hi,icon:bn}))},on=R.forwardRef(Bi),dn=A(20555),ri={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0011.6 0l43.6-43.5a8.2 8.2 0 000-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z"}}]},name:"search",theme:"outlined"},Wn=ri,Rn=function(fo,hi){return R.createElement(Jt.Z,(0,$e.Z)({},fo,{ref:hi,icon:Wn}))},di=R.forwardRef(Rn);function zi(Nr){let{suffixIcon:fo,clearIcon:hi,menuItemSelectedIcon:Yi,removeIcon:ga,loading:Xi,multiple:On,hasFeedback:gi,prefixCls:ol,showSuffixIcon:ks,feedbackIcon:as,showArrow:_s,componentName:Ks}=Nr;const Ea=hi!=null?hi:R.createElement(Gt.Z,null),hs=el=>fo===null&&!gi&&!_s?null:R.createElement(R.Fragment,null,ks!==!1&&el,gi&&as);let Ju=null;if(fo!==void 0)Ju=hs(fo);else if(Xi)Ju=hs(R.createElement(dn.Z,{spin:!0}));else{const el=`${ol}-suffix`;Ju=fl=>{let{open:As,showSearch:Rl}=fl;return hs(As&&Rl?R.createElement(di,{className:el}):R.createElement(on,{className:el}))}}let Fa=null;Yi!==void 0?Fa=Yi:On?Fa=R.createElement(hr,null):Fa=null;let dc=null;return ga!==void 0?dc=ga:dc=R.createElement(Tr.Z,null),{clearIcon:Ea,suffixIcon:Ju,itemIcon:Fa,removeIcon:dc}}function Gi(Nr,fo){return fo!==void 0?fo:Nr!==null}var Lo=function(Nr,fo){var hi={};for(var Yi in Nr)Object.prototype.hasOwnProperty.call(Nr,Yi)&&fo.indexOf(Yi)<0&&(hi[Yi]=Nr[Yi]);if(Nr!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ga=0,Yi=Object.getOwnPropertySymbols(Nr);ga{var hi;const{prefixCls:Yi,bordered:ga,className:Xi,rootClassName:On,getPopupContainer:gi,popupClassName:ol,dropdownClassName:ks,listHeight:as=256,placement:_s,listItemHeight:Ks,size:Ea,disabled:hs,notFoundContent:Ju,status:Fa,builtinPlacements:dc,dropdownMatchSelectWidth:el,popupMatchSelectWidth:fl,direction:As,style:Rl,allowClear:dl,variant:_c,dropdownStyle:lu,transitionName:Pn,tagRender:Wr,maxCount:Ci}=Nr,at=Lo(Nr,["prefixCls","bordered","className","rootClassName","getPopupContainer","popupClassName","dropdownClassName","listHeight","placement","listItemHeight","size","disabled","notFoundContent","status","builtinPlacements","dropdownMatchSelectWidth","popupMatchSelectWidth","direction","style","allowClear","variant","dropdownStyle","transitionName","tagRender","maxCount"]),{getPopupContainer:Vt,getPrefixCls:gr,renderEmpty:gn,direction:un,virtual:Zi,popupMatchSelectWidth:ho,popupOverflow:Na,select:mn}=R.useContext(we.E_),[,Lr]=(0,Ne.ZP)(),yr=Ks!=null?Ks:Lr==null?void 0:Lr.controlHeight,Mr=gr("select",Yi),Zr=gr(),Vn=As!=null?As:un,{compactSize:In,compactItemClassnames:Kn}=(0,tt.ri)(Mr,Vn),[Mi,so]=Ct(_c,ga),ro=(0,Ve.Z)(Mr),[Ho,ya,gs]=je(Mr,ro),lo=R.useMemo(()=>{const{mode:ss}=Nr;if(ss!=="combobox")return ss===eo?"combobox":ss},[Nr.mode]),No=lo==="multiple"||lo==="tags",Da=Gi(Nr.suffixIcon,Nr.showArrow),ta=(hi=fl!=null?fl:el)!==null&&hi!==void 0?hi:ho,{status:Ra,hasFeedback:ns,isFormItemInput:Vo,feedbackIcon:bs}=R.useContext(Xe.aM),Js=De(Ra,Fa);let Hu;Ju!==void 0?Hu=Ju:lo==="combobox"?Hu=null:Hu=(gn==null?void 0:gn("Select"))||R.createElement(Ge,{componentName:"Select"});const{suffixIcon:Of,itemIcon:en,removeIcon:xn,clearIcon:Vi}=zi(Object.assign(Object.assign({},at),{multiple:No,hasFeedback:ns,feedbackIcon:bs,showSuffixIcon:Da,prefixCls:Mr,componentName:"Select"})),wi=dl===!0?{clearIcon:Vi}:dl,oo=(0,$.Z)(at,["suffixIcon","itemIcon"]),io=y()(ol||ks,{[`${Mr}-dropdown-${Vn}`]:Vn==="rtl"},On,gs,ro,ya),Uo=(0,ut.Z)(ss=>{var si;return(si=Ea!=null?Ea:In)!==null&&si!==void 0?si:ss}),na=R.useContext(ct.Z),$a=hs!=null?hs:na,Co=y()({[`${Mr}-lg`]:Uo==="large",[`${Mr}-sm`]:Uo==="small",[`${Mr}-rtl`]:Vn==="rtl",[`${Mr}-${Mi}`]:so,[`${Mr}-in-form-item`]:Vo},le(Mr,Js,ns),Kn,mn==null?void 0:mn.className,Xi,On,gs,ro,ya),wo=R.useMemo(()=>_s!==void 0?_s:Vn==="rtl"?"bottomRight":"bottomLeft",[_s,Vn]),[Pa]=(0,X.Cn)("SelectLike",lu==null?void 0:lu.zIndex);return Ho(R.createElement(p.ZP,Object.assign({ref:fo,virtual:Zi,showSearch:mn==null?void 0:mn.showSearch},oo,{style:Object.assign(Object.assign({},mn==null?void 0:mn.style),Rl),dropdownMatchSelectWidth:ta,transitionName:(0,se.m)(Zr,"slide-up",Pn),builtinPlacements:pt(dc,Na),listHeight:as,listItemHeight:yr,mode:lo,prefixCls:Mr,placement:wo,direction:Vn,suffixIcon:Of,menuItemSelectedIcon:en,removeIcon:xn,allowClear:wi,notFoundContent:Hu,className:Co,getPopupContainer:gi||Vt,dropdownClassName:io,disabled:$a,dropdownStyle:Object.assign(Object.assign({},lu),{zIndex:Pa}),maxCount:No?Ci:void 0,tagRender:No?Wr:void 0})))},va=R.forwardRef(ba),Do=(0,ae.Z)(va);va.SECRET_COMBOBOX_MODE_DO_NOT_USE=eo,va.Option=p.Wx,va.OptGroup=p.Xo,va._InternalPanelDoNotUseOrYouWillBeFired=Do;var Ps=va},53580:function(Ye,ye,A){"use strict";A.d(ye,{BR:function(){return ae},ri:function(){return se}});var R=A(92310),V=A.n(R),y=A(45659),p=A(77617),$=function(we,Ee){var qe={};for(var Ge in we)Object.prototype.hasOwnProperty.call(we,Ge)&&Ee.indexOf(Ge)<0&&(qe[Ge]=we[Ge]);if(we!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ct=0,Ge=Object.getOwnPropertySymbols(we);ct{const qe=p.useContext(X),Ge=p.useMemo(()=>{if(!qe)return"";const{compactDirection:ct,isFirstItem:Ve,isLastItem:ut}=qe,Xe=ct==="vertical"?"-vertical-":"-";return V()(`${we}-compact${Xe}item`,{[`${we}-compact${Xe}first-item`]:Ve,[`${we}-compact${Xe}last-item`]:ut,[`${we}-compact${Xe}item-rtl`]:Ee==="rtl"})},[we,Ee,qe]);return{compactSize:qe==null?void 0:qe.compactSize,compactDirection:qe==null?void 0:qe.compactDirection,compactItemClassnames:Ge}},ae=we=>{let{children:Ee}=we;return p.createElement(X.Provider,{value:null},Ee)},ce=we=>{var{children:Ee}=we,qe=$(we,["children"]);return React.createElement(X.Provider,{value:qe},Ee)},le=we=>{const{getPrefixCls:Ee,direction:qe}=React.useContext(ConfigContext),{size:Ge,direction:ct,block:Ve,prefixCls:ut,className:Xe,rootClassName:Rt,children:gt}=we,Ct=$(we,["size","direction","block","prefixCls","className","rootClassName","children"]),tt=useSize(Se=>Ge!=null?Ge:Se),Ne=Ee("space-compact",ut),[bt,et]=useStyle(Ne),pt=classNames(Ne,et,{[`${Ne}-rtl`]:qe==="rtl",[`${Ne}-block`]:Ve,[`${Ne}-vertical`]:ct==="vertical"},Xe,Rt),Ke=React.useContext(X),ft=toArray(gt),wt=React.useMemo(()=>ft.map((Se,Ft)=>{const mt=Se&&Se.key||`${Ne}-item-${Ft}`;return React.createElement(ce,{key:mt,compactSize:tt,compactDirection:ct,isFirstItem:Ft===0&&(!Ke||(Ke==null?void 0:Ke.isFirstItem)),isLastItem:Ft===ft.length-1&&(!Ke||(Ke==null?void 0:Ke.isLastItem))},Se)}),[Ge,ft,Ke]);return ft.length===0?null:bt(React.createElement("div",Object.assign({className:pt},Ct),wt))};var De=null},80658:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return Ne}});var R=A(77617),V=A(92310),y=A.n(V),p=A(99468);function $(bt,et,pt){var Ke=pt||{},ft=Ke.noTrailing,wt=ft===void 0?!1:ft,Se=Ke.noLeading,Ft=Se===void 0?!1:Se,mt=Ke.debounceMode,ot=mt===void 0?void 0:mt,We,Me=!1,st=0;function Qe(){We&&clearTimeout(We)}function dr(Yr){var hn=Yr||{},ln=hn.upcomingOnly,oi=ln===void 0?!1:ln;Qe(),Me=!oi}function Kt(){for(var Yr=arguments.length,hn=new Array(Yr),ln=0;lnbt?Ft?(st=Date.now(),wt||(We=setTimeout(ot?_i:$n,bt))):$n():wt!==!0&&(We=setTimeout(ot?_i:$n,ot===void 0?bt-Nn:bt))}return Kt.cancel=dr,Kt}function X(bt,et,pt){var Ke=pt||{},ft=Ke.atBegin,wt=ft===void 0?!1:ft;return $(bt,et,{debounceMode:wt!==!1})}var se=A(48894),ae=A(11908),ce=A(78600),le=A(75199),De=A(93319),we=A(12228);const Ee=new ce.E4("antSpinMove",{to:{opacity:1}}),qe=new ce.E4("antRotate",{to:{transform:"rotate(405deg)"}}),Ge=bt=>{const{componentCls:et,calc:pt}=bt;return{[`${et}`]:Object.assign(Object.assign({},(0,le.Wf)(bt)),{position:"absolute",display:"none",color:bt.colorPrimary,fontSize:0,textAlign:"center",verticalAlign:"middle",opacity:0,transition:`transform ${bt.motionDurationSlow} ${bt.motionEaseInOutCirc}`,"&-spinning":{position:"static",display:"inline-block",opacity:1},[`${et}-text`]:{fontSize:bt.fontSize,paddingTop:pt(pt(bt.dotSize).sub(bt.fontSize)).div(2).add(2).equal()},"&-fullscreen":{position:"fixed",width:"100vw",height:"100vh",backgroundColor:bt.colorBgMask,zIndex:bt.zIndexPopupBase,inset:0,display:"flex",alignItems:"center",flexDirection:"column",justifyContent:"center",opacity:0,visibility:"hidden",transition:`all ${bt.motionDurationMid}`,"&-show":{opacity:1,visibility:"visible"},[`${et}-dot ${et}-dot-item`]:{backgroundColor:bt.colorWhite},[`${et}-text`]:{color:bt.colorTextLightSolid}},"&-nested-loading":{position:"relative",[`> div > ${et}`]:{position:"absolute",top:0,insetInlineStart:0,zIndex:4,display:"block",width:"100%",height:"100%",maxHeight:bt.contentHeight,[`${et}-dot`]:{position:"absolute",top:"50%",insetInlineStart:"50%",margin:pt(bt.dotSize).mul(-1).div(2).equal()},[`${et}-text`]:{position:"absolute",top:"50%",width:"100%",textShadow:`0 1px 2px ${bt.colorBgContainer}`},[`&${et}-show-text ${et}-dot`]:{marginTop:pt(bt.dotSize).div(2).mul(-1).sub(10).equal()},"&-sm":{[`${et}-dot`]:{margin:pt(bt.dotSizeSM).mul(-1).div(2).equal()},[`${et}-text`]:{paddingTop:pt(pt(bt.dotSizeSM).sub(bt.fontSize)).div(2).add(2).equal()},[`&${et}-show-text ${et}-dot`]:{marginTop:pt(bt.dotSizeSM).div(2).mul(-1).sub(10).equal()}},"&-lg":{[`${et}-dot`]:{margin:pt(bt.dotSizeLG).mul(-1).div(2).equal()},[`${et}-text`]:{paddingTop:pt(pt(bt.dotSizeLG).sub(bt.fontSize)).div(2).add(2).equal()},[`&${et}-show-text ${et}-dot`]:{marginTop:pt(bt.dotSizeLG).div(2).mul(-1).sub(10).equal()}}},[`${et}-container`]:{position:"relative",transition:`opacity ${bt.motionDurationSlow}`,"&::after":{position:"absolute",top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,zIndex:10,width:"100%",height:"100%",background:bt.colorBgContainer,opacity:0,transition:`all ${bt.motionDurationSlow}`,content:'""',pointerEvents:"none"}},[`${et}-blur`]:{clear:"both",opacity:.5,userSelect:"none",pointerEvents:"none",["&::after"]:{opacity:.4,pointerEvents:"auto"}}},["&-tip"]:{color:bt.spinDotDefault},[`${et}-dot`]:{position:"relative",display:"inline-block",fontSize:bt.dotSize,width:"1em",height:"1em","&-item":{position:"absolute",display:"block",width:pt(bt.dotSize).sub(pt(bt.marginXXS).div(2)).div(2).equal(),height:pt(bt.dotSize).sub(pt(bt.marginXXS).div(2)).div(2).equal(),backgroundColor:bt.colorPrimary,borderRadius:"100%",transform:"scale(0.75)",transformOrigin:"50% 50%",opacity:.3,animationName:Ee,animationDuration:"1s",animationIterationCount:"infinite",animationTimingFunction:"linear",animationDirection:"alternate","&:nth-child(1)":{top:0,insetInlineStart:0,animationDelay:"0s"},"&:nth-child(2)":{top:0,insetInlineEnd:0,animationDelay:"0.4s"},"&:nth-child(3)":{insetInlineEnd:0,bottom:0,animationDelay:"0.8s"},"&:nth-child(4)":{bottom:0,insetInlineStart:0,animationDelay:"1.2s"}},"&-spin":{transform:"rotate(45deg)",animationName:qe,animationDuration:"1.2s",animationIterationCount:"infinite",animationTimingFunction:"linear"}},[`&-sm ${et}-dot`]:{fontSize:bt.dotSizeSM,i:{width:pt(pt(bt.dotSizeSM).sub(pt(bt.marginXXS).div(2))).div(2).equal(),height:pt(pt(bt.dotSizeSM).sub(pt(bt.marginXXS).div(2))).div(2).equal()}},[`&-lg ${et}-dot`]:{fontSize:bt.dotSizeLG,i:{width:pt(pt(bt.dotSizeLG).sub(bt.marginXXS)).div(2).equal(),height:pt(pt(bt.dotSizeLG).sub(bt.marginXXS)).div(2).equal()}},[`&${et}-show-text ${et}-text`]:{display:"block"}})}},ct=bt=>{const{controlHeightLG:et,controlHeight:pt}=bt;return{contentHeight:400,dotSize:et/2,dotSizeSM:et*.35,dotSizeLG:pt}};var Ve=(0,De.I$)("Spin",bt=>{const et=(0,we.TS)(bt,{spinDotDefault:bt.colorTextDescription});return[Ge(et)]},ct),ut=function(bt,et){var pt={};for(var Ke in bt)Object.prototype.hasOwnProperty.call(bt,Ke)&&et.indexOf(Ke)<0&&(pt[Ke]=bt[Ke]);if(bt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ft=0,Ke=Object.getOwnPropertySymbols(bt);ft{const{prefixCls:et,spinning:pt=!0,delay:Ke=0,className:ft,rootClassName:wt,size:Se="default",tip:Ft,wrapperClassName:mt,style:ot,children:We,fullscreen:Me=!1}=bt,st=ut(bt,["prefixCls","spinning","delay","className","rootClassName","size","tip","wrapperClassName","style","children","fullscreen"]),{getPrefixCls:Qe}=R.useContext(ae.E_),dr=Qe("spin",et),[Kt,Yr,hn]=Ve(dr),[ln,oi]=R.useState(()=>pt&&!Ct(pt,Ke));R.useEffect(()=>{if(pt){const sn=X(Ke,()=>{oi(!0)});return sn(),()=>{var li;(li=sn==null?void 0:sn.cancel)===null||li===void 0||li.call(sn)}}oi(!1)},[Ke,pt]);const Nn=R.useMemo(()=>typeof We!="undefined"&&!Me,[We,Me]),{direction:$n,spin:_i}=R.useContext(ae.E_),Qn=y()(dr,_i==null?void 0:_i.className,{[`${dr}-sm`]:Se==="small",[`${dr}-lg`]:Se==="large",[`${dr}-spinning`]:ln,[`${dr}-show-text`]:!!Ft,[`${dr}-fullscreen`]:Me,[`${dr}-fullscreen-show`]:Me&&ln,[`${dr}-rtl`]:$n==="rtl"},ft,wt,Yr,hn),Ji=y()(`${dr}-container`,{[`${dr}-blur`]:ln}),ni=(0,p.Z)(st,["indicator"]),Ei=Object.assign(Object.assign({},_i==null?void 0:_i.style),ot),xo=R.createElement("div",Object.assign({},ni,{style:Ei,className:Qn,"aria-live":"polite","aria-busy":ln}),gt(dr,bt),Ft&&(Nn||Me)?R.createElement("div",{className:`${dr}-text`},Ft):null);return Kt(Nn?R.createElement("div",Object.assign({},ni,{className:y()(`${dr}-nested-loading`,mt,Yr,hn)}),ln&&R.createElement("div",{key:"loading"},xo),R.createElement("div",{className:Ji,key:"container"},We)):xo)};tt.setDefaultIndicator=bt=>{Rt=bt};var Ne=tt},5283:function(Ye,ye,A){"use strict";A.d(ye,{c:function(){return y}});function R(p,$,X){const{focusElCls:se,focus:ae,borderElCls:ce}=X,le=ce?"> *":"",De=["hover",ae?"focus":null,"active"].filter(Boolean).map(we=>`&:${we} ${le}`).join(",");return{[`&-item:not(${$}-last-item)`]:{marginInlineEnd:p.calc(p.lineWidth).mul(-1).equal()},"&-item":Object.assign(Object.assign({[De]:{zIndex:2}},se?{[`&${se}`]:{zIndex:2}}:{}),{[`&[disabled] ${le}`]:{zIndex:0}})}}function V(p,$,X){const{borderElCls:se}=X,ae=se?`> ${se}`:"";return{[`&-item:not(${$}-first-item):not(${$}-last-item) ${ae}`]:{borderRadius:0},[`&-item:not(${$}-last-item)${$}-first-item`]:{[`& ${ae}, &${p}-sm ${ae}, &${p}-lg ${ae}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`&-item:not(${$}-first-item)${$}-last-item`]:{[`& ${ae}, &${p}-sm ${ae}, &${p}-lg ${ae}`]:{borderStartStartRadius:0,borderEndStartRadius:0}}}}function y(p){let $=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{focus:!0};const{componentCls:X}=p,se=`${X}-compact`;return{[se]:Object.assign(Object.assign({},R(p,se,$)),V(X,se,$))}}},75199:function(Ye,ye,A){"use strict";A.d(ye,{Lx:function(){return X},Qy:function(){return ce},Ro:function(){return p},Wf:function(){return y},dF:function(){return $},du:function(){return se},oN:function(){return ae},vS:function(){return V}});var R=A(78600);const V={overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},y=function(le){let De=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return{boxSizing:"border-box",margin:0,padding:0,color:le.colorText,fontSize:le.fontSize,lineHeight:le.lineHeight,listStyle:"none",fontFamily:De?"inherit":le.fontFamily}},p=()=>({display:"inline-flex",alignItems:"center",color:"inherit",fontStyle:"normal",lineHeight:0,textAlign:"center",textTransform:"none",verticalAlign:"-0.125em",textRendering:"optimizeLegibility","-webkit-font-smoothing":"antialiased","-moz-osx-font-smoothing":"grayscale","> *":{lineHeight:1},svg:{display:"inline-block"}}),$=()=>({"&::before":{display:"table",content:'""'},"&::after":{display:"table",clear:"both",content:'""'}}),X=le=>({a:{color:le.colorLink,textDecoration:le.linkDecoration,backgroundColor:"transparent",outline:"none",cursor:"pointer",transition:`color ${le.motionDurationSlow}`,"-webkit-text-decoration-skip":"objects","&:hover":{color:le.colorLinkHover},"&:active":{color:le.colorLinkActive},[`&:active, + &:hover`]:{textDecoration:le.linkHoverDecoration,outline:0},"&:focus":{textDecoration:le.linkFocusDecoration,outline:0},"&[disabled]":{color:le.colorTextDisabled,cursor:"not-allowed"}}}),se=(le,De,we)=>{const{fontFamily:Ee,fontSize:qe}=le,Ge=`[class^="${De}"], [class*=" ${De}"]`;return{[we?`.${we}`:Ge]:{fontFamily:Ee,fontSize:qe,boxSizing:"border-box","&::before, &::after":{boxSizing:"border-box"},[Ge]:{boxSizing:"border-box","&::before, &::after":{boxSizing:"border-box"}}}}},ae=le=>({outline:`${(0,R.bf)(le.lineWidthFocus)} solid ${le.colorPrimaryBorder}`,outlineOffset:1,transition:"outline-offset 0s, outline 0s"}),ce=le=>({"&:focus-visible":Object.assign({},ae(le))})},8264:function(Ye,ye,A){"use strict";A.d(ye,{R:function(){return y}});const R=p=>({animationDuration:p,animationFillMode:"both"}),V=p=>({animationDuration:p,animationFillMode:"both"}),y=function(p,$,X,se){const ce=(arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1)?"&":"";return{[` + ${ce}${p}-enter, + ${ce}${p}-appear + `]:Object.assign(Object.assign({},R(se)),{animationPlayState:"paused"}),[`${ce}${p}-leave`]:Object.assign(Object.assign({},V(se)),{animationPlayState:"paused"}),[` + ${ce}${p}-enter${p}-enter-active, + ${ce}${p}-appear${p}-appear-active + `]:{animationName:$,animationPlayState:"running"},[`${ce}${p}-leave${p}-leave-active`]:{animationName:X,animationPlayState:"running",pointerEvents:"none"}}}},85406:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return Ft}});var R=A(77617),V=A(20555),y=A(92310),p=A.n(y),$=A(79384),X=A(16514),se=A(35372),ae=A(56348),ce=A(84381),le=A(84821),De=["prefixCls","className","checked","defaultChecked","disabled","loadingIcon","checkedChildren","unCheckedChildren","onClick","onChange","onKeyDown"],we=R.forwardRef(function(mt,ot){var We,Me=mt.prefixCls,st=Me===void 0?"rc-switch":Me,Qe=mt.className,dr=mt.checked,Kt=mt.defaultChecked,Yr=mt.disabled,hn=mt.loadingIcon,ln=mt.checkedChildren,oi=mt.unCheckedChildren,Nn=mt.onClick,$n=mt.onChange,_i=mt.onKeyDown,Qn=(0,ae.Z)(mt,De),Ji=(0,ce.Z)(!1,{value:dr,defaultValue:Kt}),ni=(0,se.Z)(Ji,2),Ei=ni[0],xo=ni[1];function sn(qi,Bo){var Mo=Ei;return Yr||(Mo=qi,xo(Mo),$n==null||$n(Mo,Bo)),Mo}function li(qi){qi.which===le.Z.LEFT?sn(!1,qi):qi.which===le.Z.RIGHT&&sn(!0,qi),_i==null||_i(qi)}function En(qi){var Bo=sn(!Ei,qi);Nn==null||Nn(Bo,qi)}var or=p()(st,Qe,(We={},(0,X.Z)(We,"".concat(st,"-checked"),Ei),(0,X.Z)(We,"".concat(st,"-disabled"),Yr),We));return R.createElement("button",(0,$.Z)({},Qn,{type:"button",role:"switch","aria-checked":Ei,disabled:Yr,className:or,ref:ot,onKeyDown:li,onClick:En}),hn,R.createElement("span",{className:"".concat(st,"-inner")},R.createElement("span",{className:"".concat(st,"-inner-checked")},ln),R.createElement("span",{className:"".concat(st,"-inner-unchecked")},oi)))});we.displayName="Switch";var Ee=we,qe=A(68306),Ge=A(11908),ct=A(50138),Ve=A(15550),ut=A(78600),Xe=A(64993),Rt=A(75199),gt=A(93319),Ct=A(12228);const tt=mt=>{const{componentCls:ot,trackHeightSM:We,trackPadding:Me,trackMinWidthSM:st,innerMinMarginSM:Qe,innerMaxMarginSM:dr,handleSizeSM:Kt,calc:Yr}=mt,hn=`${ot}-inner`,ln=(0,ut.bf)(Yr(Kt).add(Yr(Me).mul(2)).equal()),oi=(0,ut.bf)(Yr(dr).mul(2).equal());return{[ot]:{[`&${ot}-small`]:{minWidth:st,height:We,lineHeight:(0,ut.bf)(We),[`${ot}-inner`]:{paddingInlineStart:dr,paddingInlineEnd:Qe,[`${hn}-checked`]:{marginInlineStart:`calc(-100% + ${ln} - ${oi})`,marginInlineEnd:`calc(100% - ${ln} + ${oi})`},[`${hn}-unchecked`]:{marginTop:Yr(We).mul(-1).equal(),marginInlineStart:0,marginInlineEnd:0}},[`${ot}-handle`]:{width:Kt,height:Kt},[`${ot}-loading-icon`]:{top:Yr(Yr(Kt).sub(mt.switchLoadingIconSize)).div(2).equal(),fontSize:mt.switchLoadingIconSize},[`&${ot}-checked`]:{[`${ot}-inner`]:{paddingInlineStart:Qe,paddingInlineEnd:dr,[`${hn}-checked`]:{marginInlineStart:0,marginInlineEnd:0},[`${hn}-unchecked`]:{marginInlineStart:`calc(100% - ${ln} + ${oi})`,marginInlineEnd:`calc(-100% + ${ln} - ${oi})`}},[`${ot}-handle`]:{insetInlineStart:`calc(100% - ${(0,ut.bf)(Yr(Kt).add(Me).equal())})`}},[`&:not(${ot}-disabled):active`]:{[`&:not(${ot}-checked) ${hn}`]:{[`${hn}-unchecked`]:{marginInlineStart:Yr(mt.marginXXS).div(2).equal(),marginInlineEnd:Yr(mt.marginXXS).mul(-1).div(2).equal()}},[`&${ot}-checked ${hn}`]:{[`${hn}-checked`]:{marginInlineStart:Yr(mt.marginXXS).mul(-1).div(2).equal(),marginInlineEnd:Yr(mt.marginXXS).div(2).equal()}}}}}}},Ne=mt=>{const{componentCls:ot,handleSize:We,calc:Me}=mt;return{[ot]:{[`${ot}-loading-icon${mt.iconCls}`]:{position:"relative",top:Me(Me(We).sub(mt.fontSize)).div(2).equal(),color:mt.switchLoadingIconColor,verticalAlign:"top"},[`&${ot}-checked ${ot}-loading-icon`]:{color:mt.switchColor}}}},bt=mt=>{const{componentCls:ot,trackPadding:We,handleBg:Me,handleShadow:st,handleSize:Qe,calc:dr}=mt,Kt=`${ot}-handle`;return{[ot]:{[Kt]:{position:"absolute",top:We,insetInlineStart:We,width:Qe,height:Qe,transition:`all ${mt.switchDuration} ease-in-out`,"&::before":{position:"absolute",top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,backgroundColor:Me,borderRadius:dr(Qe).div(2).equal(),boxShadow:st,transition:`all ${mt.switchDuration} ease-in-out`,content:'""'}},[`&${ot}-checked ${Kt}`]:{insetInlineStart:`calc(100% - ${(0,ut.bf)(dr(Qe).add(We).equal())})`},[`&:not(${ot}-disabled):active`]:{[`${Kt}::before`]:{insetInlineEnd:mt.switchHandleActiveInset,insetInlineStart:0},[`&${ot}-checked ${Kt}::before`]:{insetInlineEnd:0,insetInlineStart:mt.switchHandleActiveInset}}}}},et=mt=>{const{componentCls:ot,trackHeight:We,trackPadding:Me,innerMinMargin:st,innerMaxMargin:Qe,handleSize:dr,calc:Kt}=mt,Yr=`${ot}-inner`,hn=(0,ut.bf)(Kt(dr).add(Kt(Me).mul(2)).equal()),ln=(0,ut.bf)(Kt(Qe).mul(2).equal());return{[ot]:{[Yr]:{display:"block",overflow:"hidden",borderRadius:100,height:"100%",paddingInlineStart:Qe,paddingInlineEnd:st,transition:`padding-inline-start ${mt.switchDuration} ease-in-out, padding-inline-end ${mt.switchDuration} ease-in-out`,[`${Yr}-checked, ${Yr}-unchecked`]:{display:"block",color:mt.colorTextLightSolid,fontSize:mt.fontSizeSM,transition:`margin-inline-start ${mt.switchDuration} ease-in-out, margin-inline-end ${mt.switchDuration} ease-in-out`,pointerEvents:"none"},[`${Yr}-checked`]:{marginInlineStart:`calc(-100% + ${hn} - ${ln})`,marginInlineEnd:`calc(100% - ${hn} + ${ln})`},[`${Yr}-unchecked`]:{marginTop:Kt(We).mul(-1).equal(),marginInlineStart:0,marginInlineEnd:0}},[`&${ot}-checked ${Yr}`]:{paddingInlineStart:st,paddingInlineEnd:Qe,[`${Yr}-checked`]:{marginInlineStart:0,marginInlineEnd:0},[`${Yr}-unchecked`]:{marginInlineStart:`calc(100% - ${hn} + ${ln})`,marginInlineEnd:`calc(-100% + ${hn} - ${ln})`}},[`&:not(${ot}-disabled):active`]:{[`&:not(${ot}-checked) ${Yr}`]:{[`${Yr}-unchecked`]:{marginInlineStart:Kt(Me).mul(2).equal(),marginInlineEnd:Kt(Me).mul(-1).mul(2).equal()}},[`&${ot}-checked ${Yr}`]:{[`${Yr}-checked`]:{marginInlineStart:Kt(Me).mul(-1).mul(2).equal(),marginInlineEnd:Kt(Me).mul(2).equal()}}}}}},pt=mt=>{const{componentCls:ot,trackHeight:We,trackMinWidth:Me}=mt;return{[ot]:Object.assign(Object.assign(Object.assign(Object.assign({},(0,Rt.Wf)(mt)),{position:"relative",display:"inline-block",boxSizing:"border-box",minWidth:Me,height:We,lineHeight:`${(0,ut.bf)(We)}`,verticalAlign:"middle",background:mt.colorTextQuaternary,border:"0",borderRadius:100,cursor:"pointer",transition:`all ${mt.motionDurationMid}`,userSelect:"none",[`&:hover:not(${ot}-disabled)`]:{background:mt.colorTextTertiary}}),(0,Rt.Qy)(mt)),{[`&${ot}-checked`]:{background:mt.switchColor,[`&:hover:not(${ot}-disabled)`]:{background:mt.colorPrimaryHover}},[`&${ot}-loading, &${ot}-disabled`]:{cursor:"not-allowed",opacity:mt.switchDisabledOpacity,"*":{boxShadow:"none",cursor:"not-allowed"}},[`&${ot}-rtl`]:{direction:"rtl"}})}},Ke=mt=>{const{fontSize:ot,lineHeight:We,controlHeight:Me,colorWhite:st}=mt,Qe=ot*We,dr=Me/2,Kt=2,Yr=Qe-Kt*2,hn=dr-Kt*2;return{trackHeight:Qe,trackHeightSM:dr,trackMinWidth:Yr*2+Kt*4,trackMinWidthSM:hn*2+Kt*2,trackPadding:Kt,handleBg:st,handleSize:Yr,handleSizeSM:hn,handleShadow:`0 2px 4px 0 ${new Xe.C("#00230b").setAlpha(.2).toRgbString()}`,innerMinMargin:Yr/2,innerMaxMargin:Yr+Kt+Kt*2,innerMinMarginSM:hn/2,innerMaxMarginSM:hn+Kt+Kt*2}};var ft=(0,gt.I$)("Switch",mt=>{const ot=(0,Ct.TS)(mt,{switchDuration:mt.motionDurationMid,switchColor:mt.colorPrimary,switchDisabledOpacity:mt.opacityLoading,switchLoadingIconSize:mt.calc(mt.fontSizeIcon).mul(.75).equal(),switchLoadingIconColor:`rgba(0, 0, 0, ${mt.opacityLoading})`,switchHandleActiveInset:"-30%"});return[pt(ot),et(ot),bt(ot),Ne(ot),tt(ot)]},Ke),wt=function(mt,ot){var We={};for(var Me in mt)Object.prototype.hasOwnProperty.call(mt,Me)&&ot.indexOf(Me)<0&&(We[Me]=mt[Me]);if(mt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var st=0,Me=Object.getOwnPropertySymbols(mt);st{const{prefixCls:We,size:Me,disabled:st,loading:Qe,className:dr,rootClassName:Kt,style:Yr,checked:hn,value:ln,defaultChecked:oi,defaultValue:Nn,onChange:$n}=mt,_i=wt(mt,["prefixCls","size","disabled","loading","className","rootClassName","style","checked","value","defaultChecked","defaultValue","onChange"]),[Qn,Ji]=(0,ce.Z)(!1,{value:hn!=null?hn:ln,defaultValue:oi!=null?oi:Nn}),{getPrefixCls:ni,direction:Ei,switch:xo}=R.useContext(Ge.E_),sn=R.useContext(ct.Z),li=(st!=null?st:sn)||Qe,En=ni("switch",We),or=R.createElement("div",{className:`${En}-handle`},Qe&&R.createElement(V.Z,{className:`${En}-loading-icon`})),[qi,Bo,Mo]=ft(En),Wi=(0,Ve.Z)(Me),Ii=p()(xo==null?void 0:xo.className,{[`${En}-small`]:Wi==="small",[`${En}-loading`]:Qe,[`${En}-rtl`]:Ei==="rtl"},dr,Kt,Bo,Mo),ko=Object.assign(Object.assign({},xo==null?void 0:xo.style),Yr),Fn=function(){Ji(arguments.length<=0?void 0:arguments[0]),$n==null||$n.apply(void 0,arguments)};return qi(R.createElement(qe.Z,{component:"Switch"},R.createElement(Ee,Object.assign({},_i,{checked:Qn,onChange:Fn,prefixCls:En,className:Ii,style:ko,disabled:li,ref:ot,loadingIcon:or}))))});Se.__ANT_SWITCH=!0;var Ft=Se},47436:function(Ye,ye,A){"use strict";A.d(ye,{Mj:function(){return se},uH:function(){return $},u_:function(){return X}});var R=A(77617),V=A(78600),y=A(26152),p=A(19717);const $=(0,V.jG)(y.Z),X={token:p.Z,override:{override:p.Z},hashed:!0},se=R.createContext(X)},5022:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return Ne}});var R=A(78600),V=A(26152),y=A(19717),p=A(97239),X=bt=>{const et=bt!=null&&bt.algorithm?(0,R.jG)(bt.algorithm):(0,R.jG)(V.Z),pt=Object.assign(Object.assign({},y.Z),bt==null?void 0:bt.token);return(0,R.t2)(pt,{override:bt==null?void 0:bt.token},et,p.Z)},se=A(20573),ae=A(47436),ce=A(36670);function le(bt){const{sizeUnit:et,sizeStep:pt}=bt,Ke=pt-2;return{sizeXXL:et*(Ke+10),sizeXL:et*(Ke+6),sizeLG:et*(Ke+2),sizeMD:et*(Ke+2),sizeMS:et*(Ke+1),size:et*Ke,sizeSM:et*Ke,sizeXS:et*(Ke-1),sizeXXS:et*(Ke-1)}}var De=A(71564),Ee=(bt,et)=>{const pt=et!=null?et:(0,V.Z)(bt),Ke=pt.fontSizeSM,ft=pt.controlHeight-4;return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},pt),le(et!=null?et:bt)),(0,De.Z)(Ke)),{controlHeight:ft}),(0,ce.Z)(Object.assign(Object.assign({},pt),{controlHeight:ft})))},qe=A(10129),Ge=A(97900),ct=A(64993);const Ve=(bt,et)=>new ct.C(bt).setAlpha(et).toRgbString(),ut=(bt,et)=>new ct.C(bt).lighten(et).toHexString(),Xe=bt=>{const et=(0,qe.R_)(bt,{theme:"dark"});return{1:et[0],2:et[1],3:et[2],4:et[3],5:et[6],6:et[5],7:et[4],8:et[6],9:et[5],10:et[4]}},Rt=(bt,et)=>{const pt=bt||"#000",Ke=et||"#fff";return{colorBgBase:pt,colorTextBase:Ke,colorText:Ve(Ke,.85),colorTextSecondary:Ve(Ke,.65),colorTextTertiary:Ve(Ke,.45),colorTextQuaternary:Ve(Ke,.25),colorFill:Ve(Ke,.18),colorFillSecondary:Ve(Ke,.12),colorFillTertiary:Ve(Ke,.08),colorFillQuaternary:Ve(Ke,.04),colorBgElevated:ut(pt,12),colorBgContainer:ut(pt,8),colorBgLayout:ut(pt,0),colorBgSpotlight:ut(pt,26),colorBgBlur:Ve(Ke,.04),colorBorder:ut(pt,26),colorBorderSecondary:ut(pt,19)}};var Ct=(bt,et)=>{const pt=Object.keys(y.M).map(ft=>{const wt=(0,qe.R_)(bt[ft],{theme:"dark"});return new Array(10).fill(1).reduce((Se,Ft,mt)=>(Se[`${ft}-${mt+1}`]=wt[mt],Se[`${ft}${mt+1}`]=wt[mt],Se),{})}).reduce((ft,wt)=>(ft=Object.assign(Object.assign({},ft),wt),ft),{}),Ke=et!=null?et:(0,V.Z)(bt);return Object.assign(Object.assign(Object.assign({},Ke),pt),(0,Ge.Z)(bt,{generateColorPalettes:Xe,generateNeutralColorPalettes:Rt}))};function tt(){const[bt,et,pt]=(0,se.ZP)();return{theme:bt,token:et,hashId:pt}}var Ne={defaultConfig:ae.u_,defaultSeed:ae.u_.token,useToken:tt,defaultAlgorithm:V.Z,darkAlgorithm:Ct,compactAlgorithm:Ee,getDesignToken:X}},26152:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return Ge}});var R=A(10129),V=A(36670);function y(ct){const{sizeUnit:Ve,sizeStep:ut}=ct;return{sizeXXL:Ve*(ut+8),sizeXL:Ve*(ut+4),sizeLG:Ve*(ut+2),sizeMD:Ve*(ut+1),sizeMS:Ve*ut,size:Ve*ut,sizeSM:Ve*(ut-1),sizeXS:Ve*(ut-2),sizeXXS:Ve*(ut-3)}}var p=A(19717),$=A(97900),se=ct=>{let Ve=ct,ut=ct,Xe=ct,Rt=ct;return ct<6&&ct>=5?Ve=ct+1:ct<16&&ct>=6?Ve=ct+2:ct>=16&&(Ve=16),ct<7&&ct>=5?ut=4:ct<8&&ct>=7?ut=5:ct<14&&ct>=8?ut=6:ct<16&&ct>=14?ut=7:ct>=16&&(ut=8),ct<6&&ct>=2?Xe=1:ct>=6&&(Xe=2),ct>4&&ct<8?Rt=4:ct>=8&&(Rt=6),{borderRadius:ct,borderRadiusXS:Xe,borderRadiusSM:ut,borderRadiusLG:Ve,borderRadiusOuter:Rt}};function ae(ct){const{motionUnit:Ve,motionBase:ut,borderRadius:Xe,lineWidth:Rt}=ct;return Object.assign({motionDurationFast:`${(ut+Ve).toFixed(1)}s`,motionDurationMid:`${(ut+Ve*2).toFixed(1)}s`,motionDurationSlow:`${(ut+Ve*3).toFixed(1)}s`,lineWidthBold:Rt+1},se(Xe))}var ce=A(64993);const le=(ct,Ve)=>new ce.C(ct).setAlpha(Ve).toRgbString(),De=(ct,Ve)=>new ce.C(ct).darken(Ve).toHexString(),we=ct=>{const Ve=(0,R.R_)(ct);return{1:Ve[0],2:Ve[1],3:Ve[2],4:Ve[3],5:Ve[4],6:Ve[5],7:Ve[6],8:Ve[4],9:Ve[5],10:Ve[6]}},Ee=(ct,Ve)=>{const ut=ct||"#fff",Xe=Ve||"#000";return{colorBgBase:ut,colorTextBase:Xe,colorText:le(Xe,.88),colorTextSecondary:le(Xe,.65),colorTextTertiary:le(Xe,.45),colorTextQuaternary:le(Xe,.25),colorFill:le(Xe,.15),colorFillSecondary:le(Xe,.06),colorFillTertiary:le(Xe,.04),colorFillQuaternary:le(Xe,.02),colorBgLayout:De(ut,4),colorBgContainer:De(ut,0),colorBgElevated:De(ut,0),colorBgSpotlight:le(Xe,.85),colorBgBlur:"transparent",colorBorder:De(ut,15),colorBorderSecondary:De(ut,6)}};var qe=A(71564);function Ge(ct){const Ve=Object.keys(p.M).map(ut=>{const Xe=(0,R.R_)(ct[ut]);return new Array(10).fill(1).reduce((Rt,gt,Ct)=>(Rt[`${ut}-${Ct+1}`]=Xe[Ct],Rt[`${ut}${Ct+1}`]=Xe[Ct],Rt),{})}).reduce((ut,Xe)=>(ut=Object.assign(Object.assign({},ut),Xe),ut),{});return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},ct),Ve),(0,$.Z)(ct,{generateColorPalettes:we,generateNeutralColorPalettes:Ee})),(0,qe.Z)(ct.fontSize)),y(ct)),(0,V.Z)(ct)),ae(ct))}},19717:function(Ye,ye,A){"use strict";A.d(ye,{M:function(){return R}});const R={blue:"#1677ff",purple:"#722ED1",cyan:"#13C2C2",green:"#52C41A",magenta:"#EB2F96",pink:"#eb2f96",red:"#F5222D",orange:"#FA8C16",yellow:"#FADB14",volcano:"#FA541C",geekblue:"#2F54EB",gold:"#FAAD14",lime:"#A0D911"},V=Object.assign(Object.assign({},R),{colorPrimary:"#1677ff",colorSuccess:"#52c41a",colorWarning:"#faad14",colorError:"#ff4d4f",colorInfo:"#1677ff",colorLink:"",colorTextBase:"",colorBgBase:"",fontFamily:`-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, +'Noto Sans', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', +'Noto Color Emoji'`,fontFamilyCode:"'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, Courier, monospace",fontSize:14,lineWidth:1,lineType:"solid",motionUnit:.1,motionBase:0,motionEaseOutCirc:"cubic-bezier(0.08, 0.82, 0.17, 1)",motionEaseInOutCirc:"cubic-bezier(0.78, 0.14, 0.15, 0.86)",motionEaseOut:"cubic-bezier(0.215, 0.61, 0.355, 1)",motionEaseInOut:"cubic-bezier(0.645, 0.045, 0.355, 1)",motionEaseOutBack:"cubic-bezier(0.12, 0.4, 0.29, 1.46)",motionEaseInBack:"cubic-bezier(0.71, -0.46, 0.88, 0.6)",motionEaseInQuint:"cubic-bezier(0.755, 0.05, 0.855, 0.06)",motionEaseOutQuint:"cubic-bezier(0.23, 1, 0.32, 1)",borderRadius:6,sizeUnit:4,sizeStep:4,sizePopupArrow:16,controlHeight:32,zIndexBase:0,zIndexPopupBase:1e3,opacityImage:1,wireframe:!1,motion:!0});ye.Z=V},97900:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return V}});var R=A(64993);function V(y,p){let{generateColorPalettes:$,generateNeutralColorPalettes:X}=p;const{colorSuccess:se,colorWarning:ae,colorError:ce,colorInfo:le,colorPrimary:De,colorBgBase:we,colorTextBase:Ee}=y,qe=$(De),Ge=$(se),ct=$(ae),Ve=$(ce),ut=$(le),Xe=X(we,Ee),Rt=y.colorLink||y.colorInfo,gt=$(Rt);return Object.assign(Object.assign({},Xe),{colorPrimaryBg:qe[1],colorPrimaryBgHover:qe[2],colorPrimaryBorder:qe[3],colorPrimaryBorderHover:qe[4],colorPrimaryHover:qe[5],colorPrimary:qe[6],colorPrimaryActive:qe[7],colorPrimaryTextHover:qe[8],colorPrimaryText:qe[9],colorPrimaryTextActive:qe[10],colorSuccessBg:Ge[1],colorSuccessBgHover:Ge[2],colorSuccessBorder:Ge[3],colorSuccessBorderHover:Ge[4],colorSuccessHover:Ge[4],colorSuccess:Ge[6],colorSuccessActive:Ge[7],colorSuccessTextHover:Ge[8],colorSuccessText:Ge[9],colorSuccessTextActive:Ge[10],colorErrorBg:Ve[1],colorErrorBgHover:Ve[2],colorErrorBorder:Ve[3],colorErrorBorderHover:Ve[4],colorErrorHover:Ve[5],colorError:Ve[6],colorErrorActive:Ve[7],colorErrorTextHover:Ve[8],colorErrorText:Ve[9],colorErrorTextActive:Ve[10],colorWarningBg:ct[1],colorWarningBgHover:ct[2],colorWarningBorder:ct[3],colorWarningBorderHover:ct[4],colorWarningHover:ct[4],colorWarning:ct[6],colorWarningActive:ct[7],colorWarningTextHover:ct[8],colorWarningText:ct[9],colorWarningTextActive:ct[10],colorInfoBg:ut[1],colorInfoBgHover:ut[2],colorInfoBorder:ut[3],colorInfoBorderHover:ut[4],colorInfoHover:ut[4],colorInfo:ut[6],colorInfoActive:ut[7],colorInfoTextHover:ut[8],colorInfoText:ut[9],colorInfoTextActive:ut[10],colorLinkHover:gt[4],colorLink:gt[6],colorLinkActive:gt[7],colorBgMask:new R.C("#000").setAlpha(.45).toRgbString(),colorWhite:"#fff"})}},36670:function(Ye,ye){"use strict";const A=R=>{const{controlHeight:V}=R;return{controlHeightSM:V*.75,controlHeightXS:V*.5,controlHeightLG:V*1.25}};ye.Z=A},71564:function(Ye,ye,A){"use strict";var R=A(10176);const V=y=>{const p=(0,R.Z)(y),$=p.map(Ee=>Ee.size),X=p.map(Ee=>Ee.lineHeight),se=$[1],ae=$[0],ce=$[2],le=X[1],De=X[0],we=X[2];return{fontSizeSM:ae,fontSize:se,fontSizeLG:ce,fontSizeXL:$[3],fontSizeHeading1:$[6],fontSizeHeading2:$[5],fontSizeHeading3:$[4],fontSizeHeading4:$[3],fontSizeHeading5:$[2],lineHeight:le,lineHeightLG:we,lineHeightSM:De,fontHeight:Math.round(le*se),fontHeightLG:Math.round(we*ce),fontHeightSM:Math.round(De*ae),lineHeightHeading1:X[6],lineHeightHeading2:X[5],lineHeightHeading3:X[4],lineHeightHeading4:X[3],lineHeightHeading5:X[2]}};ye.Z=V},10176:function(Ye,ye,A){"use strict";A.d(ye,{D:function(){return R},Z:function(){return V}});function R(y){return(y+8)/y}function V(y){const p=new Array(10).fill(null).map(($,X)=>{const se=X-1,ae=y*Math.pow(2.71828,se/5),ce=X>1?Math.floor(ae):Math.ceil(ae);return Math.floor(ce/2)*2});return p[1]=y,p.map($=>({size:$,lineHeight:R($)}))}},20573:function(Ye,ye,A){"use strict";A.d(ye,{ZP:function(){return Ee},ID:function(){return le},NJ:function(){return ce}});var R=A(77617),V=A(78600),y="5.14.0",p=y,$=A(47436),X=A(19717),se=A(97239),ae=function(qe,Ge){var ct={};for(var Ve in qe)Object.prototype.hasOwnProperty.call(qe,Ve)&&Ge.indexOf(Ve)<0&&(ct[Ve]=qe[Ve]);if(qe!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ut=0,Ve=Object.getOwnPropertySymbols(qe);ut{const Ve=ct.getDerivativeToken(qe),{override:ut}=Ge,Xe=ae(Ge,["override"]);let Rt=Object.assign(Object.assign({},Ve),{override:ut});return Rt=(0,se.Z)(Rt),Xe&&Object.entries(Xe).forEach(gt=>{let[Ct,tt]=gt;const{theme:Ne}=tt,bt=ae(tt,["theme"]);let et=bt;Ne&&(et=we(Object.assign(Object.assign({},Rt),bt),{override:bt},Ne)),Rt[Ct]=et}),Rt};function Ee(){const{token:qe,hashed:Ge,theme:ct,override:Ve,cssVar:ut}=R.useContext($.Mj),Xe=`${p}-${Ge||""}`,Rt=ct||$.uH,[gt,Ct,tt]=(0,V.fp)(Rt,[X.Z,qe],{salt:Xe,override:Ve,getComputedToken:we,formatToken:se.Z,cssVar:ut&&{prefix:ut.prefix,key:ut.key,unitless:ce,ignore:le,preserve:De}});return[Rt,tt,Ge?Ct:"",gt,ut]}},97239:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return se}});var R=A(64993),V=A(19717);function y(ae){return ae>=0&&ae<=255}function p(ae,ce){const{r:le,g:De,b:we,a:Ee}=new R.C(ae).toRgb();if(Ee<1)return ae;const{r:qe,g:Ge,b:ct}=new R.C(ce).toRgb();for(let Ve=.01;Ve<=1;Ve+=.01){const ut=Math.round((le-qe*(1-Ve))/Ve),Xe=Math.round((De-Ge*(1-Ve))/Ve),Rt=Math.round((we-ct*(1-Ve))/Ve);if(y(ut)&&y(Xe)&&y(Rt))return new R.C({r:ut,g:Xe,b:Rt,a:Math.round(Ve*100)/100}).toRgbString()}return new R.C({r:le,g:De,b:we,a:1}).toRgbString()}var $=p,X=function(ae,ce){var le={};for(var De in ae)Object.prototype.hasOwnProperty.call(ae,De)&&ce.indexOf(De)<0&&(le[De]=ae[De]);if(ae!=null&&typeof Object.getOwnPropertySymbols=="function")for(var we=0,De=Object.getOwnPropertySymbols(ae);we{delete De[Rt]});const we=Object.assign(Object.assign({},le),De),Ee=480,qe=576,Ge=768,ct=992,Ve=1200,ut=1600;if(we.motion===!1){const Rt="0s";we.motionDurationFast=Rt,we.motionDurationMid=Rt,we.motionDurationSlow=Rt}return Object.assign(Object.assign(Object.assign({},we),{colorFillContent:we.colorFillSecondary,colorFillContentHover:we.colorFill,colorFillAlter:we.colorFillQuaternary,colorBgContainerDisabled:we.colorFillTertiary,colorBorderBg:we.colorBgContainer,colorSplit:$(we.colorBorderSecondary,we.colorBgContainer),colorTextPlaceholder:we.colorTextQuaternary,colorTextDisabled:we.colorTextQuaternary,colorTextHeading:we.colorText,colorTextLabel:we.colorTextSecondary,colorTextDescription:we.colorTextTertiary,colorTextLightSolid:we.colorWhite,colorHighlight:we.colorError,colorBgTextHover:we.colorFillSecondary,colorBgTextActive:we.colorFill,colorIcon:we.colorTextTertiary,colorIconHover:we.colorText,colorErrorOutline:$(we.colorErrorBg,we.colorBgContainer),colorWarningOutline:$(we.colorWarningBg,we.colorBgContainer),fontSizeIcon:we.fontSizeSM,lineWidthFocus:we.lineWidth*4,lineWidth:we.lineWidth,controlOutlineWidth:we.lineWidth*2,controlInteractiveSize:we.controlHeight/2,controlItemBgHover:we.colorFillTertiary,controlItemBgActive:we.colorPrimaryBg,controlItemBgActiveHover:we.colorPrimaryBgHover,controlItemBgActiveDisabled:we.colorFill,controlTmpOutline:we.colorFillQuaternary,controlOutline:$(we.colorPrimaryBg,we.colorBgContainer),lineType:we.lineType,borderRadius:we.borderRadius,borderRadiusXS:we.borderRadiusXS,borderRadiusSM:we.borderRadiusSM,borderRadiusLG:we.borderRadiusLG,fontWeightStrong:600,opacityLoading:.65,linkDecoration:"none",linkHoverDecoration:"none",linkFocusDecoration:"none",controlPaddingHorizontal:12,controlPaddingHorizontalSM:8,paddingXXS:we.sizeXXS,paddingXS:we.sizeXS,paddingSM:we.sizeSM,padding:we.size,paddingMD:we.sizeMD,paddingLG:we.sizeLG,paddingXL:we.sizeXL,paddingContentHorizontalLG:we.sizeLG,paddingContentVerticalLG:we.sizeMS,paddingContentHorizontal:we.sizeMS,paddingContentVertical:we.sizeSM,paddingContentHorizontalSM:we.size,paddingContentVerticalSM:we.sizeXS,marginXXS:we.sizeXXS,marginXS:we.sizeXS,marginSM:we.sizeSM,margin:we.size,marginMD:we.sizeMD,marginLG:we.sizeLG,marginXL:we.sizeXL,marginXXL:we.sizeXXL,boxShadow:` + 0 6px 16px 0 rgba(0, 0, 0, 0.08), + 0 3px 6px -4px rgba(0, 0, 0, 0.12), + 0 9px 28px 8px rgba(0, 0, 0, 0.05) + `,boxShadowSecondary:` + 0 6px 16px 0 rgba(0, 0, 0, 0.08), + 0 3px 6px -4px rgba(0, 0, 0, 0.12), + 0 9px 28px 8px rgba(0, 0, 0, 0.05) + `,boxShadowTertiary:` + 0 1px 2px 0 rgba(0, 0, 0, 0.03), + 0 1px 6px -1px rgba(0, 0, 0, 0.02), + 0 2px 4px 0 rgba(0, 0, 0, 0.02) + `,screenXS:Ee,screenXSMin:Ee,screenXSMax:qe-1,screenSM:qe,screenSMMin:qe,screenSMMax:Ge-1,screenMD:Ge,screenMDMin:Ge,screenMDMax:ct-1,screenLG:ct,screenLGMin:ct,screenLGMax:Ve-1,screenXL:Ve,screenXLMin:Ve,screenXLMax:ut-1,screenXXL:ut,screenXXLMin:ut,boxShadowPopoverArrow:"2px 2px 5px rgba(0, 0, 0, 0.05)",boxShadowCard:` + 0 1px 2px -2px ${new R.C("rgba(0, 0, 0, 0.16)").toRgbString()}, + 0 3px 6px 0 ${new R.C("rgba(0, 0, 0, 0.12)").toRgbString()}, + 0 5px 12px 4px ${new R.C("rgba(0, 0, 0, 0.09)").toRgbString()} + `,boxShadowDrawerRight:` + -6px 0 16px 0 rgba(0, 0, 0, 0.08), + -3px 0 6px -4px rgba(0, 0, 0, 0.12), + -9px 0 28px 8px rgba(0, 0, 0, 0.05) + `,boxShadowDrawerLeft:` + 6px 0 16px 0 rgba(0, 0, 0, 0.08), + 3px 0 6px -4px rgba(0, 0, 0, 0.12), + 9px 0 28px 8px rgba(0, 0, 0, 0.05) + `,boxShadowDrawerUp:` + 0 6px 16px 0 rgba(0, 0, 0, 0.08), + 0 3px 6px -4px rgba(0, 0, 0, 0.12), + 0 9px 28px 8px rgba(0, 0, 0, 0.05) + `,boxShadowDrawerDown:` + 0 -6px 16px 0 rgba(0, 0, 0, 0.08), + 0 -3px 6px -4px rgba(0, 0, 0, 0.12), + 0 -9px 28px 8px rgba(0, 0, 0, 0.05) + `,boxShadowTabsOverflowLeft:"inset 10px 0 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowRight:"inset -10px 0 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowTop:"inset 0 10px 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowBottom:"inset 0 -10px 8px -8px rgba(0, 0, 0, 0.08)"}),De)}},93319:function(Ye,ye,A){"use strict";A.d(ye,{ZP:function(){return ft},I$:function(){return Ft},bk:function(){return wt}});var R=A(77617),V=A(78600),y=A(33401),p=A(11908),$=A(75199),X=A(20573),se=A(61577),ae=A(22946),ce=A(16169),le=A(72597),De=A(26581),we=A(3711),qe=(0,ae.Z)(function mt(){(0,se.Z)(this,mt)});function Ge(mt,ot,We){return ot=(0,De.Z)(ot),(0,ce.Z)(mt,(0,le.Z)()?Reflect.construct(ot,We||[],(0,De.Z)(mt).constructor):ot.apply(mt,We))}let ct=function(mt){(0,we.Z)(ot,mt);function ot(We){var Me;return(0,se.Z)(this,ot),Me=Ge(this,ot),Me.result=0,We instanceof ot?Me.result=We.result:typeof We=="number"&&(Me.result=We),Me}return(0,ae.Z)(ot,[{key:"add",value:function(Me){return Me instanceof ot?this.result+=Me.result:typeof Me=="number"&&(this.result+=Me),this}},{key:"sub",value:function(Me){return Me instanceof ot?this.result-=Me.result:typeof Me=="number"&&(this.result-=Me),this}},{key:"mul",value:function(Me){return Me instanceof ot?this.result*=Me.result:typeof Me=="number"&&(this.result*=Me),this}},{key:"div",value:function(Me){return Me instanceof ot?this.result/=Me.result:typeof Me=="number"&&(this.result/=Me),this}},{key:"equal",value:function(){return this.result}}]),ot}(qe);function Ve(mt,ot,We){return ot=(0,De.Z)(ot),(0,ce.Z)(mt,(0,le.Z)()?Reflect.construct(ot,We||[],(0,De.Z)(mt).constructor):ot.apply(mt,We))}const ut="CALC_UNIT";function Xe(mt){return typeof mt=="number"?`${mt}${ut}`:mt}let Rt=function(mt){(0,we.Z)(ot,mt);function ot(We){var Me;return(0,se.Z)(this,ot),Me=Ve(this,ot),Me.result="",We instanceof ot?Me.result=`(${We.result})`:typeof We=="number"?Me.result=Xe(We):typeof We=="string"&&(Me.result=We),Me}return(0,ae.Z)(ot,[{key:"add",value:function(Me){return Me instanceof ot?this.result=`${this.result} + ${Me.getResult()}`:(typeof Me=="number"||typeof Me=="string")&&(this.result=`${this.result} + ${Xe(Me)}`),this.lowPriority=!0,this}},{key:"sub",value:function(Me){return Me instanceof ot?this.result=`${this.result} - ${Me.getResult()}`:(typeof Me=="number"||typeof Me=="string")&&(this.result=`${this.result} - ${Xe(Me)}`),this.lowPriority=!0,this}},{key:"mul",value:function(Me){return this.lowPriority&&(this.result=`(${this.result})`),Me instanceof ot?this.result=`${this.result} * ${Me.getResult(!0)}`:(typeof Me=="number"||typeof Me=="string")&&(this.result=`${this.result} * ${Me}`),this.lowPriority=!1,this}},{key:"div",value:function(Me){return this.lowPriority&&(this.result=`(${this.result})`),Me instanceof ot?this.result=`${this.result} / ${Me.getResult(!0)}`:(typeof Me=="number"||typeof Me=="string")&&(this.result=`${this.result} / ${Me}`),this.lowPriority=!1,this}},{key:"getResult",value:function(Me){return this.lowPriority||Me?`(${this.result})`:this.result}},{key:"equal",value:function(Me){const{unit:st=!0}=Me||{},Qe=new RegExp(`${ut}`,"g");return this.result=this.result.replace(Qe,st?"px":""),typeof this.lowPriority!="undefined"?`calc(${this.result})`:this.result}}]),ot}(qe);var Ct=mt=>{const ot=mt==="css"?Rt:ct;return We=>new ot(We)};function tt(mt){return mt==="js"?{max:Math.max,min:Math.min}:{max:function(){for(var ot=arguments.length,We=new Array(ot),Me=0;Me(0,V.bf)(st)).join(",")})`},min:function(){for(var ot=arguments.length,We=new Array(ot),Me=0;Me(0,V.bf)(st)).join(",")})`}}}var Ne=A(12228),bt=A(85034);const et=(mt,ot,We)=>{var Me;return typeof We=="function"?We((0,Ne.TS)(ot,(Me=ot[mt])!==null&&Me!==void 0?Me:{})):We!=null?We:{}},pt=(mt,ot,We,Me)=>{const st=Object.assign({},ot[mt]);if(Me!=null&&Me.deprecatedTokens){const{deprecatedTokens:dr}=Me;dr.forEach(Kt=>{let[Yr,hn]=Kt;var ln;(st!=null&&st[Yr]||st!=null&&st[hn])&&((ln=st[hn])!==null&&ln!==void 0||(st[hn]=st==null?void 0:st[Yr]))})}const Qe=Object.assign(Object.assign({},We),st);return Object.keys(Qe).forEach(dr=>{Qe[dr]===ot[dr]&&delete Qe[dr]}),Qe},Ke=(mt,ot)=>`${[ot,mt.replace(/([A-Z]+)([A-Z][a-z]+)/g,"$1-$2").replace(/([a-z])([A-Z])/g,"$1-$2")].filter(Boolean).join("-")}`;function ft(mt,ot,We){let Me=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};const st=Array.isArray(mt)?mt:[mt,mt],[Qe]=st,dr=st.join("-");return function(Kt){let Yr=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kt;const[hn,ln,oi,Nn,$n]=(0,X.ZP)(),{getPrefixCls:_i,iconPrefixCls:Qn,csp:Ji}=(0,R.useContext)(p.E_),ni=_i(),Ei=$n?"css":"js",xo=Ct(Ei),{max:sn,min:li}=tt(Ei),En={theme:hn,token:Nn,hashId:oi,nonce:()=>Ji==null?void 0:Ji.nonce,clientOnly:Me.clientOnly,order:Me.order||-999};return(0,V.xy)(Object.assign(Object.assign({},En),{clientOnly:!1,path:["Shared",ni]}),()=>[{"&":(0,$.Lx)(Nn)}]),(0,bt.Z)(Qn,Ji),[(0,V.xy)(Object.assign(Object.assign({},En),{path:[dr,Kt,Qn]}),()=>{if(Me.injectStyle===!1)return[];const{token:qi,flush:Bo}=(0,Ne.ZP)(Nn),Mo=et(Qe,ln,We),Wi=`.${Kt}`,Ii=pt(Qe,ln,Mo,{deprecatedTokens:Me.deprecatedTokens});$n&&Object.keys(Mo).forEach(zn=>{Mo[zn]=`var(${(0,V.ks)(zn,Ke(Qe,$n.prefix))})`});const ko=(0,Ne.TS)(qi,{componentCls:Wi,prefixCls:Kt,iconCls:`.${Qn}`,antCls:`.${ni}`,calc:xo,max:sn,min:li},$n?Mo:Ii),Fn=ot(ko,{hashId:oi,prefixCls:Kt,rootPrefixCls:ni,iconPrefixCls:Qn});return Bo(Qe,Ii),[Me.resetStyle===!1?null:(0,$.du)(ko,Kt,Yr),Fn]}),oi]}}const wt=(mt,ot,We,Me)=>{const st=ft(mt,ot,We,Object.assign({resetStyle:!1,order:-998},Me));return dr=>{let{prefixCls:Kt,rootCls:Yr=Kt}=dr;return st(Kt,Yr),null}},Se=(mt,ot,We)=>{function Me(hn){return`${mt}${hn.slice(0,1).toUpperCase()}${hn.slice(1)}`}const{unitless:st={},injectStyle:Qe=!0}=We!=null?We:{},dr={[Me("zIndexPopup")]:!0};Object.keys(st).forEach(hn=>{dr[Me(hn)]=st[hn]});const Kt=hn=>{let{rootCls:ln,cssVar:oi}=hn;const[,Nn]=(0,X.ZP)();return(0,V.CI)({path:[mt],prefix:oi.prefix,key:oi==null?void 0:oi.key,unitless:Object.assign(Object.assign({},X.NJ),dr),ignore:X.ID,token:Nn,scope:ln},()=>{const $n=et(mt,Nn,ot),_i=pt(mt,Nn,$n,{deprecatedTokens:We==null?void 0:We.deprecatedTokens});return Object.keys($n).forEach(Qn=>{_i[Me(Qn)]=_i[Qn],delete _i[Qn]}),_i}),null};return hn=>{const[,,,,ln]=(0,X.ZP)();return[oi=>Qe&&ln?R.createElement(R.Fragment,null,R.createElement(Kt,{rootCls:hn,cssVar:ln,component:mt}),oi):oi,ln==null?void 0:ln.key]}},Ft=(mt,ot,We,Me)=>{const st=ft(mt,ot,We,Me),Qe=Se(Array.isArray(mt)?mt[0]:mt,We,Me);return function(dr){let Kt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:dr;const[,Yr]=st(dr,Kt),[hn,ln]=Qe(Kt);return[hn,Yr,ln]}}},12228:function(Ye,ye,A){"use strict";A.d(ye,{TS:function(){return y}});const R=typeof CSSINJS_STATISTIC!="undefined";let V=!0;function y(){for(var ae=arguments.length,ce=new Array(ae),le=0;le{Object.keys(we).forEach(qe=>{Object.defineProperty(De,qe,{configurable:!0,enumerable:!0,get:()=>we[qe]})})}),V=!0,De}const p={},$={};function X(){}const se=ae=>{let ce,le=ae,De=X;return R&&typeof Proxy!="undefined"&&(ce=new Set,le=new Proxy(ae,{get(we,Ee){return V&&ce.add(Ee),we[Ee]}}),De=(we,Ee)=>{var qe;p[we]={global:Array.from(ce),component:Object.assign(Object.assign({},(qe=p[we])===null||qe===void 0?void 0:qe.component),Ee)}}),{token:le,keys:ce,flush:De}};ye.ZP=se},85034:function(Ye,ye,A){"use strict";var R=A(78600),V=A(75199),y=A(20573);const p=($,X)=>{const[se,ae]=(0,y.ZP)();return(0,R.xy)({theme:se,token:ae,hashId:"",path:["ant-design-icons",$],nonce:()=>X==null?void 0:X.nonce},()=>[{[`.${$}`]:Object.assign(Object.assign({},(0,V.Ro)()),{[`.${$} .${$}-icon`]:{display:"block"}})}])};ye.Z=p},71041:function(Ye,ye,A){"use strict";var R=A(28263);Ye.exports=function(p){p=p||{};var $=p.reporter,X=R.getOption(p,"async",!0),se=R.getOption(p,"auto",!0);se&&!X&&($&&$.warn("Invalid options combination. auto=true and async=false is invalid. Setting async=true."),X=!0);var ae=V(),ce,le=!1;function De(ut,Xe){!le&&se&&X&&ae.size()===0&&qe(),ae.add(ut,Xe)}function we(){for(le=!0;ae.size();){var ut=ae;ae=V(),ut.process()}le=!1}function Ee(ut){le||(ut===void 0&&(ut=X),ce&&(ct(ce),ce=null),ut?qe():we())}function qe(){ce=Ve(we)}function Ge(){ae={},batchSize=0,topLevel=0,bottomLevel=0}function ct(ut){var Xe=clearTimeout;return Xe(ut)}function Ve(ut){var Xe=function(Rt){return setTimeout(Rt,0)};return Xe(ut)}return{add:De,force:Ee}};function V(){var y={},p=0,$=0,X=0;function se(le,De){De||(De=le,le=0),le>$?$=le:le-1?V(se):se}},71262:function(Ye,ye,A){"use strict";var R=A(36723),V=A(64656),y=A(31099),p=V("%TypeError%"),$=V("%Function.prototype.apply%"),X=V("%Function.prototype.call%"),se=V("%Reflect.apply%",!0)||R.call(X,$),ae=V("%Object.defineProperty%",!0),ce=V("%Math.max%");if(ae)try{ae({},"a",{value:1})}catch(De){ae=null}Ye.exports=function(we){if(typeof we!="function")throw new p("a function is required");var Ee=se(R,X,arguments);return y(Ee,1+ce(0,we.length-(arguments.length-1)),!0)};var le=function(){return se(R,$,arguments)};ae?ae(Ye.exports,"apply",{value:le}):Ye.exports.apply=le},67751:function(Ye){var ye={utf8:{stringToBytes:function(A){return ye.bin.stringToBytes(unescape(encodeURIComponent(A)))},bytesToString:function(A){return decodeURIComponent(escape(ye.bin.bytesToString(A)))}},bin:{stringToBytes:function(A){for(var R=[],V=0;V1&&(ce-=1)),[ce*360,le*100,qe*100]},y.rgb.hwb=function($){const X=$[0],se=$[1];let ae=$[2];const ce=y.rgb.hsl($)[0],le=1/255*Math.min(X,Math.min(se,ae));return ae=1-1/255*Math.max(X,Math.max(se,ae)),[ce,le*100,ae*100]},y.rgb.cmyk=function($){const X=$[0]/255,se=$[1]/255,ae=$[2]/255,ce=Math.min(1-X,1-se,1-ae),le=(1-X-ce)/(1-ce)||0,De=(1-se-ce)/(1-ce)||0,we=(1-ae-ce)/(1-ce)||0;return[le*100,De*100,we*100,ce*100]};function p($,X){return hm($[0]-X[0],2)+hm($[1]-X[1],2)+hm($[2]-X[2],2)}y.rgb.keyword=function($){const X=V[$];if(X)return X;let se=1/0,ae;for(const ce of Object.keys(R)){const le=R[ce],De=p($,le);De.04045?hm((X+.055)/1.055,2.4):X/12.92,se=se>.04045?hm((se+.055)/1.055,2.4):se/12.92,ae=ae>.04045?hm((ae+.055)/1.055,2.4):ae/12.92;const ce=X*.4124+se*.3576+ae*.1805,le=X*.2126+se*.7152+ae*.0722,De=X*.0193+se*.1192+ae*.9505;return[ce*100,le*100,De*100]},y.rgb.lab=function($){const X=y.rgb.xyz($);let se=X[0],ae=X[1],ce=X[2];se/=95.047,ae/=100,ce/=108.883,se=se>.008856?hm(se,1/3):7.787*se+16/116,ae=ae>.008856?hm(ae,1/3):7.787*ae+16/116,ce=ce>.008856?hm(ce,1/3):7.787*ce+16/116;const le=116*ae-16,De=500*(se-ae),we=200*(ae-ce);return[le,De,we]},y.hsl.rgb=function($){const X=$[0]/360,se=$[1]/100,ae=$[2]/100;let ce,le,De;if(se===0)return De=ae*255,[De,De,De];ae<.5?ce=ae*(1+se):ce=ae+se-ae*se;const we=2*ae-ce,Ee=[0,0,0];for(let qe=0;qe<3;qe++)le=X+1/3*-(qe-1),le<0&&le++,le>1&&le--,6*le<1?De=we+(ce-we)*6*le:2*le<1?De=ce:3*le<2?De=we+(ce-we)*(2/3-le)*6:De=we,Ee[qe]=De*255;return Ee},y.hsl.hsv=function($){const X=$[0];let se=$[1]/100,ae=$[2]/100,ce=se;const le=Math.max(ae,.01);ae*=2,se*=ae<=1?ae:2-ae,ce*=le<=1?le:2-le;const De=(ae+se)/2,we=ae===0?2*ce/(le+ce):2*se/(ae+se);return[X,we*100,De*100]},y.hsv.rgb=function($){const X=$[0]/60,se=$[1]/100;let ae=$[2]/100;const ce=Math.floor(X)%6,le=X-Math.floor(X),De=255*ae*(1-se),we=255*ae*(1-se*le),Ee=255*ae*(1-se*(1-le));switch(ae*=255,ce){case 0:return[ae,Ee,De];case 1:return[we,ae,De];case 2:return[De,ae,Ee];case 3:return[De,we,ae];case 4:return[Ee,De,ae];case 5:return[ae,De,we]}},y.hsv.hsl=function($){const X=$[0],se=$[1]/100,ae=$[2]/100,ce=Math.max(ae,.01);let le,De;De=(2-se)*ae;const we=(2-se)*ce;return le=se*ce,le/=we<=1?we:2-we,le=le||0,De/=2,[X,le*100,De*100]},y.hwb.rgb=function($){const X=$[0]/360;let se=$[1]/100,ae=$[2]/100;const ce=se+ae;let le;ce>1&&(se/=ce,ae/=ce);const De=Math.floor(6*X),we=1-ae;le=6*X-De,De&1&&(le=1-le);const Ee=se+le*(we-se);let qe,Ge,ct;switch(De){default:case 6:case 0:qe=we,Ge=Ee,ct=se;break;case 1:qe=Ee,Ge=we,ct=se;break;case 2:qe=se,Ge=we,ct=Ee;break;case 3:qe=se,Ge=Ee,ct=we;break;case 4:qe=Ee,Ge=se,ct=we;break;case 5:qe=we,Ge=se,ct=Ee;break}return[qe*255,Ge*255,ct*255]},y.cmyk.rgb=function($){const X=$[0]/100,se=$[1]/100,ae=$[2]/100,ce=$[3]/100,le=1-Math.min(1,X*(1-ce)+ce),De=1-Math.min(1,se*(1-ce)+ce),we=1-Math.min(1,ae*(1-ce)+ce);return[le*255,De*255,we*255]},y.xyz.rgb=function($){const X=$[0]/100,se=$[1]/100,ae=$[2]/100;let ce,le,De;return ce=X*3.2406+se*-1.5372+ae*-.4986,le=X*-.9689+se*1.8758+ae*.0415,De=X*.0557+se*-.204+ae*1.057,ce=ce>.0031308?1.055*hm(ce,1/2.4)-.055:ce*12.92,le=le>.0031308?1.055*hm(le,1/2.4)-.055:le*12.92,De=De>.0031308?1.055*hm(De,1/2.4)-.055:De*12.92,ce=Math.min(Math.max(0,ce),1),le=Math.min(Math.max(0,le),1),De=Math.min(Math.max(0,De),1),[ce*255,le*255,De*255]},y.xyz.lab=function($){let X=$[0],se=$[1],ae=$[2];X/=95.047,se/=100,ae/=108.883,X=X>.008856?hm(X,1/3):7.787*X+16/116,se=se>.008856?hm(se,1/3):7.787*se+16/116,ae=ae>.008856?hm(ae,1/3):7.787*ae+16/116;const ce=116*se-16,le=500*(X-se),De=200*(se-ae);return[ce,le,De]},y.lab.xyz=function($){const X=$[0],se=$[1],ae=$[2];let ce,le,De;le=(X+16)/116,ce=se/500+le,De=le-ae/200;const we=hm(le,3),Ee=hm(ce,3),qe=hm(De,3);return le=we>.008856?we:(le-16/116)/7.787,ce=Ee>.008856?Ee:(ce-16/116)/7.787,De=qe>.008856?qe:(De-16/116)/7.787,ce*=95.047,le*=100,De*=108.883,[ce,le,De]},y.lab.lch=function($){const X=$[0],se=$[1],ae=$[2];let ce;ce=Math.atan2(ae,se)*360/2/Math.PI,ce<0&&(ce+=360);const De=Math.sqrt(se*se+ae*ae);return[X,De,ce]},y.lch.lab=function($){const X=$[0],se=$[1],ce=$[2]/360*2*Math.PI,le=se*Math.cos(ce),De=se*Math.sin(ce);return[X,le,De]},y.rgb.ansi16=function($,X=null){const[se,ae,ce]=$;let le=X===null?y.rgb.hsv($)[2]:X;if(le=Math.round(le/50),le===0)return 30;let De=30+(Math.round(ce/255)<<2|Math.round(ae/255)<<1|Math.round(se/255));return le===2&&(De+=60),De},y.hsv.ansi16=function($){return y.rgb.ansi16(y.hsv.rgb($),$[2])},y.rgb.ansi256=function($){const X=$[0],se=$[1],ae=$[2];return X===se&&se===ae?X<8?16:X>248?231:Math.round((X-8)/247*24)+232:16+36*Math.round(X/255*5)+6*Math.round(se/255*5)+Math.round(ae/255*5)},y.ansi16.rgb=function($){let X=$%10;if(X===0||X===7)return $>50&&(X+=3.5),X=X/10.5*255,[X,X,X];const se=(~~($>50)+1)*.5,ae=(X&1)*se*255,ce=(X>>1&1)*se*255,le=(X>>2&1)*se*255;return[ae,ce,le]},y.ansi256.rgb=function($){if($>=232){const le=($-232)*10+8;return[le,le,le]}$-=16;let X;const se=Math.floor($/36)/5*255,ae=Math.floor((X=$%36)/6)/5*255,ce=X%6/5*255;return[se,ae,ce]},y.rgb.hex=function($){const se=(((Math.round($[0])&255)<<16)+((Math.round($[1])&255)<<8)+(Math.round($[2])&255)).toString(16).toUpperCase();return"000000".substring(se.length)+se},y.hex.rgb=function($){const X=$.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!X)return[0,0,0];let se=X[0];X[0].length===3&&(se=se.split("").map(we=>we+we).join(""));const ae=parseInt(se,16),ce=ae>>16&255,le=ae>>8&255,De=ae&255;return[ce,le,De]},y.rgb.hcg=function($){const X=$[0]/255,se=$[1]/255,ae=$[2]/255,ce=Math.max(Math.max(X,se),ae),le=Math.min(Math.min(X,se),ae),De=ce-le;let we,Ee;return De<1?we=le/(1-De):we=0,De<=0?Ee=0:ce===X?Ee=(se-ae)/De%6:ce===se?Ee=2+(ae-X)/De:Ee=4+(X-se)/De,Ee/=6,Ee%=1,[Ee*360,De*100,we*100]},y.hsl.hcg=function($){const X=$[1]/100,se=$[2]/100,ae=se<.5?2*X*se:2*X*(1-se);let ce=0;return ae<1&&(ce=(se-.5*ae)/(1-ae)),[$[0],ae*100,ce*100]},y.hsv.hcg=function($){const X=$[1]/100,se=$[2]/100,ae=X*se;let ce=0;return ae<1&&(ce=(se-ae)/(1-ae)),[$[0],ae*100,ce*100]},y.hcg.rgb=function($){const X=$[0]/360,se=$[1]/100,ae=$[2]/100;if(se===0)return[ae*255,ae*255,ae*255];const ce=[0,0,0],le=X%1*6,De=le%1,we=1-De;let Ee=0;switch(Math.floor(le)){case 0:ce[0]=1,ce[1]=De,ce[2]=0;break;case 1:ce[0]=we,ce[1]=1,ce[2]=0;break;case 2:ce[0]=0,ce[1]=1,ce[2]=De;break;case 3:ce[0]=0,ce[1]=we,ce[2]=1;break;case 4:ce[0]=De,ce[1]=0,ce[2]=1;break;default:ce[0]=1,ce[1]=0,ce[2]=we}return Ee=(1-se)*ae,[(se*ce[0]+Ee)*255,(se*ce[1]+Ee)*255,(se*ce[2]+Ee)*255]},y.hcg.hsv=function($){const X=$[1]/100,se=$[2]/100,ae=X+se*(1-X);let ce=0;return ae>0&&(ce=X/ae),[$[0],ce*100,ae*100]},y.hcg.hsl=function($){const X=$[1]/100,ae=$[2]/100*(1-X)+.5*X;let ce=0;return ae>0&&ae<.5?ce=X/(2*ae):ae>=.5&&ae<1&&(ce=X/(2*(1-ae))),[$[0],ce*100,ae*100]},y.hcg.hwb=function($){const X=$[1]/100,se=$[2]/100,ae=X+se*(1-X);return[$[0],(ae-X)*100,(1-ae)*100]},y.hwb.hcg=function($){const X=$[1]/100,ae=1-$[2]/100,ce=ae-X;let le=0;return ce<1&&(le=(ae-ce)/(1-ce)),[$[0],ce*100,le*100]},y.apple.rgb=function($){return[$[0]/65535*255,$[1]/65535*255,$[2]/65535*255]},y.rgb.apple=function($){return[$[0]/255*65535,$[1]/255*65535,$[2]/255*65535]},y.gray.rgb=function($){return[$[0]/100*255,$[0]/100*255,$[0]/100*255]},y.gray.hsl=function($){return[0,0,$[0]]},y.gray.hsv=y.gray.hsl,y.gray.hwb=function($){return[0,100,$[0]]},y.gray.cmyk=function($){return[0,0,0,$[0]]},y.gray.lab=function($){return[$[0],0,0]},y.gray.hex=function($){const X=Math.round($[0]/100*255)&255,ae=((X<<16)+(X<<8)+X).toString(16).toUpperCase();return"000000".substring(ae.length)+ae},y.rgb.gray=function($){return[($[0]+$[1]+$[2])/3/255*100]}},41492:function(Ye,ye,A){const R=A(18135),V=A(40756),y={},p=Object.keys(R);function $(se){const ae=function(...ce){const le=ce[0];return le==null?le:(le.length>1&&(ce=le),se(ce))};return"conversion"in se&&(ae.conversion=se.conversion),ae}function X(se){const ae=function(...ce){const le=ce[0];if(le==null)return le;le.length>1&&(ce=le);const De=se(ce);if(typeof De=="object")for(let we=De.length,Ee=0;Ee{y[se]={},Object.defineProperty(y[se],"channels",{value:R[se].channels}),Object.defineProperty(y[se],"labels",{value:R[se].labels});const ae=V(se);Object.keys(ae).forEach(le=>{const De=ae[le];y[se][le]=X(De),y[se][le].raw=$(De)})}),Ye.exports=y},40756:function(Ye,ye,A){const R=A(18135);function V(){const X={},se=Object.keys(R);for(let ae=se.length,ce=0;ce=4&&ce[3]!==1&&(le=", "+ce[3]),"hwb("+ce[0]+", "+ce[1]+"%, "+ce[2]+"%"+le+")"},X.to.keyword=function(ce){return p[ce.slice(0,3)]};function se(ce,le,De){return Math.min(Math.max(le,ce),De)}function ae(ce){var le=Math.round(ce).toString(16).toUpperCase();return le.length<2?"0"+le:le}},28170:function(Ye,ye,A){const R=A(75196),V=A(41492),y=["keyword","gray","hex"],p={};for(const Ee of Object.keys(V))p[[...V[Ee].labels].sort().join("")]=Ee;const $={};function X(Ee,qe){if(!(this instanceof X))return new X(Ee,qe);if(qe&&qe in y&&(qe=null),qe&&!(qe in V))throw new Error("Unknown model: "+qe);let Ge,ct;if(Ee==null)this.model="rgb",this.color=[0,0,0],this.valpha=1;else if(Ee instanceof X)this.model=Ee.model,this.color=[...Ee.color],this.valpha=Ee.valpha;else if(typeof Ee=="string"){const Ve=R.get(Ee);if(Ve===null)throw new Error("Unable to parse color from string: "+Ee);this.model=Ve.model,ct=V[this.model].channels,this.color=Ve.value.slice(0,ct),this.valpha=typeof Ve.value[ct]=="number"?Ve.value[ct]:1}else if(Ee.length>0){this.model=qe||"rgb",ct=V[this.model].channels;const Ve=Array.prototype.slice.call(Ee,0,ct);this.color=we(Ve,ct),this.valpha=typeof Ee[ct]=="number"?Ee[ct]:1}else if(typeof Ee=="number")this.model="rgb",this.color=[Ee>>16&255,Ee>>8&255,Ee&255],this.valpha=1;else{this.valpha=1;const Ve=Object.keys(Ee);"alpha"in Ee&&(Ve.splice(Ve.indexOf("alpha"),1),this.valpha=typeof Ee.alpha=="number"?Ee.alpha:0);const ut=Ve.sort().join("");if(!(ut in p))throw new Error("Unable to parse color from object: "+JSON.stringify(Ee));this.model=p[ut];const{labels:Xe}=V[this.model],Rt=[];for(Ge=0;Ge(Ee%360+360)%360),saturationl:ce("hsl",1,le(100)),lightness:ce("hsl",2,le(100)),saturationv:ce("hsv",1,le(100)),value:ce("hsv",2,le(100)),chroma:ce("hcg",1,le(100)),gray:ce("hcg",2,le(100)),white:ce("hwb",1,le(100)),wblack:ce("hwb",2,le(100)),cyan:ce("cmyk",0,le(100)),magenta:ce("cmyk",1,le(100)),yellow:ce("cmyk",2,le(100)),black:ce("cmyk",3,le(100)),x:ce("xyz",0,le(95.047)),y:ce("xyz",1,le(100)),z:ce("xyz",2,le(108.833)),l:ce("lab",0,le(100)),a:ce("lab",1),b:ce("lab",2),keyword(Ee){return Ee!==void 0?new X(Ee):V[this.model].keyword(this.color)},hex(Ee){return Ee!==void 0?new X(Ee):R.to.hex(this.rgb().round().color)},hexa(Ee){if(Ee!==void 0)return new X(Ee);const qe=this.rgb().round().color;let Ge=Math.round(this.valpha*255).toString(16).toUpperCase();return Ge.length===1&&(Ge="0"+Ge),R.to.hex(qe)+Ge},rgbNumber(){const Ee=this.rgb().color;return(Ee[0]&255)<<16|(Ee[1]&255)<<8|Ee[2]&255},luminosity(){const Ee=this.rgb().color,qe=[];for(const[Ge,ct]of Ee.entries()){const Ve=ct/255;qe[Ge]=Ve<=.04045?Ve/12.92:hm((Ve+.055)/1.055,2.4)}return .2126*qe[0]+.7152*qe[1]+.0722*qe[2]},contrast(Ee){const qe=this.luminosity(),Ge=Ee.luminosity();return qe>Ge?(qe+.05)/(Ge+.05):(Ge+.05)/(qe+.05)},level(Ee){const qe=this.contrast(Ee);return qe>=7?"AAA":qe>=4.5?"AA":""},isDark(){const Ee=this.rgb().color;return(Ee[0]*2126+Ee[1]*7152+Ee[2]*722)/1e4<128},isLight(){return!this.isDark()},negate(){const Ee=this.rgb();for(let qe=0;qe<3;qe++)Ee.color[qe]=255-Ee.color[qe];return Ee},lighten(Ee){const qe=this.hsl();return qe.color[2]+=qe.color[2]*Ee,qe},darken(Ee){const qe=this.hsl();return qe.color[2]-=qe.color[2]*Ee,qe},saturate(Ee){const qe=this.hsl();return qe.color[1]+=qe.color[1]*Ee,qe},desaturate(Ee){const qe=this.hsl();return qe.color[1]-=qe.color[1]*Ee,qe},whiten(Ee){const qe=this.hwb();return qe.color[1]+=qe.color[1]*Ee,qe},blacken(Ee){const qe=this.hwb();return qe.color[2]+=qe.color[2]*Ee,qe},grayscale(){const Ee=this.rgb().color,qe=Ee[0]*.3+Ee[1]*.59+Ee[2]*.11;return X.rgb(qe,qe,qe)},fade(Ee){return this.alpha(this.valpha-this.valpha*Ee)},opaquer(Ee){return this.alpha(this.valpha+this.valpha*Ee)},rotate(Ee){const qe=this.hsl();let Ge=qe.color[0];return Ge=(Ge+Ee)%360,Ge=Ge<0?360+Ge:Ge,qe.color[0]=Ge,qe},mix(Ee,qe){if(!Ee||!Ee.rgb)throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof Ee);const Ge=Ee.rgb(),ct=this.rgb(),Ve=qe===void 0?.5:qe,ut=2*Ve-1,Xe=Ge.alpha()-ct.alpha(),Rt=((ut*Xe===-1?ut:(ut+Xe)/(1+ut*Xe))+1)/2,gt=1-Rt;return X.rgb(Rt*Ge.red()+gt*ct.red(),Rt*Ge.green()+gt*ct.green(),Rt*Ge.blue()+gt*ct.blue(),Ge.alpha()*Ve+ct.alpha()*(1-Ve))}};for(const Ee of Object.keys(V)){if(y.includes(Ee))continue;const{channels:qe}=V[Ee];X.prototype[Ee]=function(...Ge){return this.model===Ee?new X(this):Ge.length>0?new X(Ge,Ee):new X([...De(V[this.model][Ee].raw(this.color)),this.valpha],Ee)},X[Ee]=function(...Ge){let ct=Ge[0];return typeof ct=="number"&&(ct=we(Ge,qe)),new X(ct,Ee)}}function se(Ee,qe){return Number(Ee.toFixed(qe))}function ae(Ee){return function(qe){return se(qe,Ee)}}function ce(Ee,qe,Ge){Ee=Array.isArray(Ee)?Ee:[Ee];for(const ct of Ee)($[ct]||($[ct]=[]))[qe]=Ge;return Ee=Ee[0],function(ct){let Ve;return ct!==void 0?(Ge&&(ct=Ge(ct)),Ve=this[Ee](),Ve.color[qe]=ct,Ve):(Ve=this[Ee]().color[qe],Ge&&(Ve=Ge(Ve)),Ve)}}function le(Ee){return function(qe){return Math.max(0,Math.min(Ee,qe))}}function De(Ee){return Array.isArray(Ee)?Ee:[Ee]}function we(Ee,qe){for(let Ge=0;Geet||Ke.push({node:Se,dist:Ft})}for(;Ke.length&&!Ke.peek().node.children;){var mt=Ke.pop(),ot=mt.node,We=Ve(ot,Ct,tt),Me=Ve(ot,Ne,bt);if(mt.dist=Ct.minX&>[0]<=Ct.maxX&>[1]>=Ct.minY&>[1]<=Ct.maxY}function le(gt,Ct,tt){for(var Ne=Math.min(gt[0],Ct[0]),bt=Math.min(gt[1],Ct[1]),et=Math.max(gt[0],Ct[0]),pt=Math.max(gt[1],Ct[1]),Ke=tt.search({minX:Ne,minY:bt,maxX:et,maxY:pt}),ft=0;ft0!=De(gt,Ct,Ne)>0&&De(tt,Ne,gt)>0!=De(tt,Ne,Ct)>0}function Ee(gt){var Ct=gt.p,tt=gt.next.p;return gt.minX=Math.min(Ct[0],tt[0]),gt.minY=Math.min(Ct[1],tt[1]),gt.maxX=Math.max(Ct[0],tt[0]),gt.maxY=Math.max(Ct[1],tt[1]),gt}function qe(gt){for(var Ct=gt[0],tt=gt[0],Ne=gt[0],bt=gt[0],et=0;etNe[0]&&(Ne=pt),pt[1]bt[1]&&(bt=pt)}var Ke=[Ct,tt,Ne,bt],ft=Ke.slice();for(et=0;et1?(Ne=tt[0],bt=tt[1]):Ke>0&&(Ne+=et*Ke,bt+=pt*Ke)}return et=gt[0]-Ne,pt=gt[1]-bt,et*et+pt*pt}function ut(gt,Ct,tt,Ne,bt,et,pt,Ke){var ft=tt-gt,wt=Ne-Ct,Se=pt-bt,Ft=Ke-et,mt=gt-bt,ot=Ct-et,We=ft*ft+wt*wt,Me=ft*Se+wt*Ft,st=Se*Se+Ft*Ft,Qe=ft*mt+wt*ot,dr=Se*mt+Ft*ot,Kt=We*st-Me*Me,Yr,hn,ln,oi,Nn=Kt,$n=Kt;Kt===0?(hn=0,Nn=1,oi=dr,$n=st):(hn=Me*dr-st*Qe,oi=We*dr-Me*Qe,hn<0?(hn=0,oi=dr,$n=st):hn>Nn&&(hn=Nn,oi=dr+Me,$n=st)),oi<0?(oi=0,-Qe<0?hn=0:-Qe>We?hn=Nn:(hn=-Qe,Nn=We)):oi>$n&&(oi=$n,-Qe+Me<0?hn=0:-Qe+Me>We?hn=Nn:(hn=-Qe+Me,Nn=We)),Yr=hn===0?0:hn/Nn,ln=oi===0?0:oi/$n;var _i=(1-Yr)*gt+Yr*tt,Qn=(1-Yr)*Ct+Yr*Ne,Ji=(1-ln)*bt+ln*pt,ni=(1-ln)*et+ln*Ke,Ei=Ji-_i,xo=ni-Qn;return Ei*Ei+xo*xo}function Xe(gt,Ct){return gt[0]===Ct[0]?gt[1]-Ct[1]:gt[0]-Ct[0]}function Rt(gt){gt.sort(Xe);for(var Ct=[],tt=0;tt=2&&De(Ct[Ct.length-2],Ct[Ct.length-1],gt[tt])<=0;)Ct.pop();Ct.push(gt[tt])}for(var Ne=[],bt=gt.length-1;bt>=0;bt--){for(;Ne.length>=2&&De(Ne[Ne.length-2],Ne[Ne.length-1],gt[bt])<=0;)Ne.pop();Ne.push(gt[bt])}return Ne.pop(),Ct.pop(),Ct.concat(Ne)}},75041:function(Ye){(function(){var ye="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",A={rotl:function(R,V){return R<>>32-V},rotr:function(R,V){return R<<32-V|R>>>V},endian:function(R){if(R.constructor==Number)return A.rotl(R,8)&16711935|A.rotl(R,24)&4278255360;for(var V=0;V0;R--)V.push(Math.floor(Math.random()*256));return V},bytesToWords:function(R){for(var V=[],y=0,p=0;y>>5]|=R[y]<<24-p%32;return V},wordsToBytes:function(R){for(var V=[],y=0;y>>5]>>>24-y%32&255);return V},bytesToHex:function(R){for(var V=[],y=0;y>>4).toString(16)),V.push((R[y]&15).toString(16));return V.join("")},hexToBytes:function(R){for(var V=[],y=0;y>>6*(3-$)&63)):V.push("=");return V.join("")},base64ToBytes:function(R){R=R.replace(/[^A-Z0-9+\/]/ig,"");for(var V=[],y=0,p=0;y>>6-p*2);return V}};Ye.exports=A})()},57965:function(Ye,ye,A){"use strict";A.d(ye,{j2:function(){return R},b4:function(){return se},YF:function(){return V},We:function(){return ae},TS:function(){return Rt},VR:function(){return Ct},G9:function(){return ct},ly:function(){return Ve},sd:function(){return Ge}});function R(tt,Ne){return ttNe?1:tt>=Ne?0:NaN}function V(tt){return tt.length===1&&(tt=y(tt)),{left:function(Ne,bt,et,pt){for(et==null&&(et=0),pt==null&&(pt=Ne.length);et>>1;tt(Ne[Ke],bt)<0?et=Ke+1:pt=Ke}return et},right:function(Ne,bt,et,pt){for(et==null&&(et=0),pt==null&&(pt=Ne.length);et>>1;tt(Ne[Ke],bt)>0?pt=Ke:et=Ke+1}return et}}}function y(tt){return function(Ne,bt){return R(tt(Ne),bt)}}var p=V(R),$=p.right,X=p.left,se=$;function ae(tt,Ne){var bt=tt.length,et=-1,pt,Ke,ft;if(Ne==null){for(;++et=pt)for(Ke=ft=pt;++etpt&&(Ke=pt),ft=pt)for(Ke=ft=pt;++etpt&&(Ke=pt),ft0)return[tt];if((et=Ne0)for(tt=Math.ceil(tt/wt),Ne=Math.floor(Ne/wt),ft=new Array(Ke=Math.ceil(Ne-tt+1));++pt=0?(Ke>=we?10:Ke>=Ee?5:Ke>=qe?2:1)*Math.pow(10,pt):-Math.pow(10,-pt)/(Ke>=we?10:Ke>=Ee?5:Ke>=qe?2:1)}function Ve(tt,Ne,bt){var et=Math.abs(Ne-tt)/Math.max(0,bt),pt=Math.pow(10,Math.floor(Math.log(et)/Math.LN10)),Ke=et/pt;return Ke>=we?pt*=10:Ke>=Ee?pt*=5:Ke>=qe&&(pt*=2),Neot;)We.pop(),--Me;var st=new Array(Me+1),Qe;for(Ke=0;Ke<=Me;++Ke)Qe=st[Ke]=[],Qe.x0=Ke>0?We[Ke-1]:mt,Qe.x1=Ke=0;)for(ft=tt[Ne],bt=ft.length;--bt>=0;)Ke[--pt]=ft[bt];return Ke}function gt(tt){return tt===null?NaN:+tt}function Ct(tt,Ne,bt){if(bt==null&&(bt=gt),!!(et=tt.length)){if((Ne=+Ne)<=0||et<2)return+bt(tt[0],0,tt);if(Ne>=1)return+bt(tt[et-1],et-1,tt);var et,pt=(et-1)*Ne,Ke=Math.floor(pt),ft=+bt(tt[Ke],Ke,tt),wt=+bt(tt[Ke+1],Ke+1,tt);return ft+(wt-ft)*(pt-Ke)}}},9498:function(Ye){(function(ye,A){Ye.exports=A()})(this,function(){"use strict";var ye=1e3,A=6e4,R=36e5,V="millisecond",y="second",p="minute",$="hour",X="day",se="week",ae="month",ce="quarter",le="year",De="date",we="Invalid Date",Ee=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,qe=/\[([^\]]+)]|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,Ge={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(pt){var Ke=["th","st","nd","rd"],ft=pt%100;return"["+pt+(Ke[(ft-20)%10]||Ke[ft]||Ke[0])+"]"}},ct=function(pt,Ke,ft){var wt=String(pt);return!wt||wt.length>=Ke?pt:""+Array(Ke+1-wt.length).join(ft)+pt},Ve={s:ct,z:function(pt){var Ke=-pt.utcOffset(),ft=Math.abs(Ke),wt=Math.floor(ft/60),Se=ft%60;return(Ke<=0?"+":"-")+ct(wt,2,"0")+":"+ct(Se,2,"0")},m:function pt(Ke,ft){if(Ke.date()1)return pt(mt[0])}else{var ot=Ke.name;Xe[ot]=Ke,Se=ot}return!wt&&Se&&(ut=Se),Se||!wt&&ut},tt=function(pt,Ke){if(gt(pt))return pt.clone();var ft=typeof Ke=="object"?Ke:{};return ft.date=pt,ft.args=arguments,new bt(ft)},Ne=Ve;Ne.l=Ct,Ne.i=gt,Ne.w=function(pt,Ke){return tt(pt,{locale:Ke.$L,utc:Ke.$u,x:Ke.$x,$offset:Ke.$offset})};var bt=function(){function pt(ft){this.$L=Ct(ft.locale,null,!0),this.parse(ft),this.$x=this.$x||ft.x||{},this[Rt]=!0}var Ke=pt.prototype;return Ke.parse=function(ft){this.$d=function(wt){var Se=wt.date,Ft=wt.utc;if(Se===null)return new Date(NaN);if(Ne.u(Se))return new Date;if(Se instanceof Date)return new Date(Se);if(typeof Se=="string"&&!/Z$/i.test(Se)){var mt=Se.match(Ee);if(mt){var ot=mt[2]-1||0,We=(mt[7]||"0").substring(0,3);return Ft?new Date(Date.UTC(mt[1],ot,mt[3]||1,mt[4]||0,mt[5]||0,mt[6]||0,We)):new Date(mt[1],ot,mt[3]||1,mt[4]||0,mt[5]||0,mt[6]||0,We)}}return new Date(Se)}(ft),this.init()},Ke.init=function(){var ft=this.$d;this.$y=ft.getFullYear(),this.$M=ft.getMonth(),this.$D=ft.getDate(),this.$W=ft.getDay(),this.$H=ft.getHours(),this.$m=ft.getMinutes(),this.$s=ft.getSeconds(),this.$ms=ft.getMilliseconds()},Ke.$utils=function(){return Ne},Ke.isValid=function(){return this.$d.toString()!==we},Ke.isSame=function(ft,wt){var Se=tt(ft);return this.startOf(wt)<=Se&&Se<=this.endOf(wt)},Ke.isAfter=function(ft,wt){return tt(ft)68?1900:2e3)},X=function(we){return function(Ee){this[we]=+Ee}},se=[/[+-]\d\d:?(\d\d)?|Z/,function(we){(this.zone||(this.zone={})).offset=function(Ee){if(!Ee||Ee==="Z")return 0;var qe=Ee.match(/([+-]|\d\d)/g),Ge=60*qe[1]+(+qe[2]||0);return Ge===0?0:qe[0]==="+"?-Ge:Ge}(we)}],ae=function(we){var Ee=p[we];return Ee&&(Ee.indexOf?Ee:Ee.s.concat(Ee.f))},ce=function(we,Ee){var qe,Ge=p.meridiem;if(Ge){for(var ct=1;ct<=24;ct+=1)if(we.indexOf(Ge(ct,0,Ee))>-1){qe=ct>12;break}}else qe=we===(Ee?"pm":"PM");return qe},le={A:[y,function(we){this.afternoon=ce(we,!1)}],a:[y,function(we){this.afternoon=ce(we,!0)}],S:[/\d/,function(we){this.milliseconds=100*+we}],SS:[R,function(we){this.milliseconds=10*+we}],SSS:[/\d{3}/,function(we){this.milliseconds=+we}],s:[V,X("seconds")],ss:[V,X("seconds")],m:[V,X("minutes")],mm:[V,X("minutes")],H:[V,X("hours")],h:[V,X("hours")],HH:[V,X("hours")],hh:[V,X("hours")],D:[V,X("day")],DD:[R,X("day")],Do:[y,function(we){var Ee=p.ordinal,qe=we.match(/\d+/);if(this.day=qe[0],Ee)for(var Ge=1;Ge<=31;Ge+=1)Ee(Ge).replace(/\[|\]/g,"")===we&&(this.day=Ge)}],M:[V,X("month")],MM:[R,X("month")],MMM:[y,function(we){var Ee=ae("months"),qe=(ae("monthsShort")||Ee.map(function(Ge){return Ge.slice(0,3)})).indexOf(we)+1;if(qe<1)throw new Error;this.month=qe%12||qe}],MMMM:[y,function(we){var Ee=ae("months").indexOf(we)+1;if(Ee<1)throw new Error;this.month=Ee%12||Ee}],Y:[/[+-]?\d+/,X("year")],YY:[R,function(we){this.year=$(we)}],YYYY:[/\d{4}/,X("year")],Z:se,ZZ:se};function De(we){var Ee,qe;Ee=we,qe=p&&p.formats;for(var Ge=(we=Ee.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(Ct,tt,Ne){var bt=Ne&&Ne.toUpperCase();return tt||qe[Ne]||ye[Ne]||qe[bt].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(et,pt,Ke){return pt||Ke.slice(1)})})).match(A),ct=Ge.length,Ve=0;Ve-1)return new Date((wt==="X"?1e3:1)*ft);var Ft=De(wt)(ft),mt=Ft.year,ot=Ft.month,We=Ft.day,Me=Ft.hours,st=Ft.minutes,Qe=Ft.seconds,dr=Ft.milliseconds,Kt=Ft.zone,Yr=new Date,hn=We||(mt||ot?1:Yr.getDate()),ln=mt||Yr.getFullYear(),oi=0;mt&&!ot||(oi=ot>0?ot-1:Yr.getMonth());var Nn=Me||0,$n=st||0,_i=Qe||0,Qn=dr||0;return Kt?new Date(Date.UTC(ln,oi,hn,Nn,$n,_i,Qn+60*Kt.offset*1e3)):Se?new Date(Date.UTC(ln,oi,hn,Nn,$n,_i,Qn)):new Date(ln,oi,hn,Nn,$n,_i,Qn)}catch(Ji){return new Date("")}}(ut,gt,Xe),this.init(),bt&&bt!==!0&&(this.$L=this.locale(bt).$L),Ne&&ut!=this.format(gt)&&(this.$d=new Date("")),p={}}else if(gt instanceof Array)for(var et=gt.length,pt=1;pt<=et;pt+=1){Rt[1]=gt[pt-1];var Ke=qe.apply(this,Rt);if(Ke.isValid()){this.$d=Ke.$d,this.$L=Ke.$L,this.init();break}pt===et&&(this.$d=new Date(""))}else ct.call(this,Ve)}}})},19545:function(Ye,ye,A){var R=A(64253),V=A(76051),y=A(6392),p=A(11644),$=A(61245),X=A(5012),se=Date.prototype.getTime;function ae(we,Ee,qe){var Ge=qe||{};return(Ge.strict?y(we,Ee):we===Ee)?!0:!we||!Ee||typeof we!="object"&&typeof Ee!="object"?Ge.strict?y(we,Ee):we==Ee:De(we,Ee,Ge)}function ce(we){return we==null}function le(we){return!(!we||typeof we!="object"||typeof we.length!="number"||typeof we.copy!="function"||typeof we.slice!="function"||we.length>0&&typeof we[0]!="number")}function De(we,Ee,qe){var Ge,ct;if(typeof we!=typeof Ee||ce(we)||ce(Ee)||we.prototype!==Ee.prototype||V(we)!==V(Ee))return!1;var Ve=p(we),ut=p(Ee);if(Ve!==ut)return!1;if(Ve||ut)return we.source===Ee.source&&$(we)===$(Ee);if(X(we)&&X(Ee))return se.call(we)===se.call(Ee);var Xe=le(we),Rt=le(Ee);if(Xe!==Rt)return!1;if(Xe||Rt){if(we.length!==Ee.length)return!1;for(Ge=0;Ge=0;Ge--)if(gt[Ge]!=Ct[Ge])return!1;for(Ge=gt.length-1;Ge>=0;Ge--)if(ct=gt[Ge],!ae(we[ct],Ee[ct],qe))return!1;return!0}Ye.exports=ae},51494:function(Ye,ye,A){"use strict";var R=A(38262)(),V=A(64656),y=R&&V("%Object.defineProperty%",!0);if(y)try{y({},"a",{value:1})}catch(se){y=!1}var p=V("%SyntaxError%"),$=V("%TypeError%"),X=A(67747);Ye.exports=function(ae,ce,le){if(!ae||typeof ae!="object"&&typeof ae!="function")throw new $("`obj` must be an object or a function`");if(typeof ce!="string"&&typeof ce!="symbol")throw new $("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new $("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new $("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new $("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new $("`loose`, if provided, must be a boolean");var De=arguments.length>3?arguments[3]:null,we=arguments.length>4?arguments[4]:null,Ee=arguments.length>5?arguments[5]:null,qe=arguments.length>6?arguments[6]:!1,Ge=!!X&&X(ae,ce);if(y)y(ae,ce,{configurable:Ee===null&&Ge?Ge.configurable:!Ee,enumerable:De===null&&Ge?Ge.enumerable:!De,value:le,writable:we===null&&Ge?Ge.writable:!we});else if(qe||!De&&!we&&!Ee)ae[ce]=le;else throw new p("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")}},8263:function(Ye,ye,A){"use strict";var R=A(64253),V=typeof Symbol=="function"&&typeof Symbol("foo")=="symbol",y=Object.prototype.toString,p=Array.prototype.concat,$=A(51494),X=function(le){return typeof le=="function"&&y.call(le)==="[object Function]"},se=A(38262)(),ae=function(le,De,we,Ee){if(De in le){if(Ee===!0){if(le[De]===we)return}else if(!X(Ee)||!Ee())return}se?$(le,De,we,!0):$(le,De,we)},ce=function(le,De){var we=arguments.length>2?arguments[2]:{},Ee=R(De);V&&(Ee=p.call(Ee,Object.getOwnPropertySymbols(De)));for(var qe=0;qe=this.minPts&&(R=this._mergeArrays(R,p))}this._assigned[y]!==1&&this._addToCluster(y,A)}},ye.prototype._addToCluster=function(A,R){this.clusters[R].push(A),this._assigned[A]=1},ye.prototype._regionQuery=function(A){for(var R=[],V=0;V0){for(var ae=0;ae=0);return R},ye.prototype.assign=function(){for(var A=!1,R=this.dataset.length,V,y=0;y=this.minPts)return $}},V.prototype._regionQuery=function(y,p){p=p||this.epsilon;for(var $=[],X=0,se=this.dataset.length;Xp&&(V=y):R80*mt){Qe=Kt=Se[0],dr=Yr=Se[1];for(var Nn=mt;NnKt&&(Kt=hn),ln>Yr&&(Yr=ln);oi=Math.max(Kt-Qe,Yr-dr),oi=oi!==0?32767/oi:0}return V(Me,st,mt,Qe,dr,oi,0),st}function A(Se,Ft,mt,ot,We){var Me,st;if(We===wt(Se,Ft,mt,ot)>0)for(Me=Ft;Me=Ft;Me-=ot)st=pt(Me,Se[Me],Se[Me+1],st);return st&&Xe(st,st.next)&&(Ke(st),st=st.next),st}function R(Se,Ft){if(!Se)return Se;Ft||(Ft=Se);var mt=Se,ot;do if(ot=!1,!mt.steiner&&(Xe(mt,mt.next)||ut(mt.prev,mt,mt.next)===0)){if(Ke(mt),mt=Ft=mt.prev,mt===mt.next)break;ot=!0}else mt=mt.next;while(ot||mt!==Ft);return Ft}function V(Se,Ft,mt,ot,We,Me,st){if(Se){!st&&Me&&we(Se,ot,We,Me);for(var Qe=Se,dr,Kt;Se.prev!==Se.next;){if(dr=Se.prev,Kt=Se.next,Me?p(Se,ot,We,Me):y(Se)){Ft.push(dr.i/mt|0),Ft.push(Se.i/mt|0),Ft.push(Kt.i/mt|0),Ke(Se),Se=Kt.next,Qe=Kt.next;continue}if(Se=Kt,Se===Qe){st?st===1?(Se=$(R(Se),Ft,mt),V(Se,Ft,mt,ot,We,Me,2)):st===2&&X(Se,Ft,mt,ot,We,Me):V(R(Se),Ft,mt,ot,We,Me,1);break}}}}function y(Se){var Ft=Se.prev,mt=Se,ot=Se.next;if(ut(Ft,mt,ot)>=0)return!1;for(var We=Ft.x,Me=mt.x,st=ot.x,Qe=Ft.y,dr=mt.y,Kt=ot.y,Yr=WeMe?We>st?We:st:Me>st?Me:st,oi=Qe>dr?Qe>Kt?Qe:Kt:dr>Kt?dr:Kt,Nn=ot.next;Nn!==Ft;){if(Nn.x>=Yr&&Nn.x<=ln&&Nn.y>=hn&&Nn.y<=oi&&ct(We,Qe,Me,dr,st,Kt,Nn.x,Nn.y)&&ut(Nn.prev,Nn,Nn.next)>=0)return!1;Nn=Nn.next}return!0}function p(Se,Ft,mt,ot){var We=Se.prev,Me=Se,st=Se.next;if(ut(We,Me,st)>=0)return!1;for(var Qe=We.x,dr=Me.x,Kt=st.x,Yr=We.y,hn=Me.y,ln=st.y,oi=Qedr?Qe>Kt?Qe:Kt:dr>Kt?dr:Kt,_i=Yr>hn?Yr>ln?Yr:ln:hn>ln?hn:ln,Qn=qe(oi,Nn,Ft,mt,ot),Ji=qe($n,_i,Ft,mt,ot),ni=Se.prevZ,Ei=Se.nextZ;ni&&ni.z>=Qn&&Ei&&Ei.z<=Ji;){if(ni.x>=oi&&ni.x<=$n&&ni.y>=Nn&&ni.y<=_i&&ni!==We&&ni!==st&&ct(Qe,Yr,dr,hn,Kt,ln,ni.x,ni.y)&&ut(ni.prev,ni,ni.next)>=0||(ni=ni.prevZ,Ei.x>=oi&&Ei.x<=$n&&Ei.y>=Nn&&Ei.y<=_i&&Ei!==We&&Ei!==st&&ct(Qe,Yr,dr,hn,Kt,ln,Ei.x,Ei.y)&&ut(Ei.prev,Ei,Ei.next)>=0))return!1;Ei=Ei.nextZ}for(;ni&&ni.z>=Qn;){if(ni.x>=oi&&ni.x<=$n&&ni.y>=Nn&&ni.y<=_i&&ni!==We&&ni!==st&&ct(Qe,Yr,dr,hn,Kt,ln,ni.x,ni.y)&&ut(ni.prev,ni,ni.next)>=0)return!1;ni=ni.prevZ}for(;Ei&&Ei.z<=Ji;){if(Ei.x>=oi&&Ei.x<=$n&&Ei.y>=Nn&&Ei.y<=_i&&Ei!==We&&Ei!==st&&ct(Qe,Yr,dr,hn,Kt,ln,Ei.x,Ei.y)&&ut(Ei.prev,Ei,Ei.next)>=0)return!1;Ei=Ei.nextZ}return!0}function $(Se,Ft,mt){var ot=Se;do{var We=ot.prev,Me=ot.next.next;!Xe(We,Me)&&Rt(We,ot,ot.next,Me)&&Ne(We,Me)&&Ne(Me,We)&&(Ft.push(We.i/mt|0),Ft.push(ot.i/mt|0),Ft.push(Me.i/mt|0),Ke(ot),Ke(ot.next),ot=Se=Me),ot=ot.next}while(ot!==Se);return R(ot)}function X(Se,Ft,mt,ot,We,Me){var st=Se;do{for(var Qe=st.next.next;Qe!==st.prev;){if(st.i!==Qe.i&&Ve(st,Qe)){var dr=et(st,Qe);st=R(st,st.next),dr=R(dr,dr.next),V(st,Ft,mt,ot,We,Me,0),V(dr,Ft,mt,ot,We,Me,0);return}Qe=Qe.next}st=st.next}while(st!==Se)}function se(Se,Ft,mt,ot){var We=[],Me,st,Qe,dr,Kt;for(Me=0,st=Ft.length;Me=mt.next.y&&mt.next.y!==mt.y){var Qe=mt.x+(We-mt.y)*(mt.next.x-mt.x)/(mt.next.y-mt.y);if(Qe<=ot&&Qe>Me&&(Me=Qe,st=mt.x=mt.x&&mt.x>=Kt&&ot!==mt.x&&ct(West.x||mt.x===st.x&&De(st,mt)))&&(st=mt,hn=ln)),mt=mt.next;while(mt!==dr);return st}function De(Se,Ft){return ut(Se.prev,Se,Ft.prev)<0&&ut(Ft.next,Se,Se.next)<0}function we(Se,Ft,mt,ot){var We=Se;do We.z===0&&(We.z=qe(We.x,We.y,Ft,mt,ot)),We.prevZ=We.prev,We.nextZ=We.next,We=We.next;while(We!==Se);We.prevZ.nextZ=null,We.prevZ=null,Ee(We)}function Ee(Se){var Ft,mt,ot,We,Me,st,Qe,dr,Kt=1;do{for(mt=Se,Se=null,Me=null,st=0;mt;){for(st++,ot=mt,Qe=0,Ft=0;Ft0||dr>0&&ot;)Qe!==0&&(dr===0||!ot||mt.z<=ot.z)?(We=mt,mt=mt.nextZ,Qe--):(We=ot,ot=ot.nextZ,dr--),Me?Me.nextZ=We:Se=We,We.prevZ=Me,Me=We;mt=ot}Me.nextZ=null,Kt*=2}while(st>1);return Se}function qe(Se,Ft,mt,ot,We){return Se=(Se-mt)*We|0,Ft=(Ft-ot)*We|0,Se=(Se|Se<<8)&16711935,Se=(Se|Se<<4)&252645135,Se=(Se|Se<<2)&858993459,Se=(Se|Se<<1)&1431655765,Ft=(Ft|Ft<<8)&16711935,Ft=(Ft|Ft<<4)&252645135,Ft=(Ft|Ft<<2)&858993459,Ft=(Ft|Ft<<1)&1431655765,Se|Ft<<1}function Ge(Se){var Ft=Se,mt=Se;do(Ft.x=(Se-st)*(Me-Qe)&&(Se-st)*(ot-Qe)>=(mt-st)*(Ft-Qe)&&(mt-st)*(Me-Qe)>=(We-st)*(ot-Qe)}function Ve(Se,Ft){return Se.next.i!==Ft.i&&Se.prev.i!==Ft.i&&!tt(Se,Ft)&&(Ne(Se,Ft)&&Ne(Ft,Se)&&bt(Se,Ft)&&(ut(Se.prev,Se,Ft.prev)||ut(Se,Ft.prev,Ft))||Xe(Se,Ft)&&ut(Se.prev,Se,Se.next)>0&&ut(Ft.prev,Ft,Ft.next)>0)}function ut(Se,Ft,mt){return(Ft.y-Se.y)*(mt.x-Ft.x)-(Ft.x-Se.x)*(mt.y-Ft.y)}function Xe(Se,Ft){return Se.x===Ft.x&&Se.y===Ft.y}function Rt(Se,Ft,mt,ot){var We=Ct(ut(Se,Ft,mt)),Me=Ct(ut(Se,Ft,ot)),st=Ct(ut(mt,ot,Se)),Qe=Ct(ut(mt,ot,Ft));return!!(We!==Me&&st!==Qe||We===0&>(Se,mt,Ft)||Me===0&>(Se,ot,Ft)||st===0&>(mt,Se,ot)||Qe===0&>(mt,Ft,ot))}function gt(Se,Ft,mt){return Ft.x<=Math.max(Se.x,mt.x)&&Ft.x>=Math.min(Se.x,mt.x)&&Ft.y<=Math.max(Se.y,mt.y)&&Ft.y>=Math.min(Se.y,mt.y)}function Ct(Se){return Se>0?1:Se<0?-1:0}function tt(Se,Ft){var mt=Se;do{if(mt.i!==Se.i&&mt.next.i!==Se.i&&mt.i!==Ft.i&&mt.next.i!==Ft.i&&Rt(mt,mt.next,Se,Ft))return!0;mt=mt.next}while(mt!==Se);return!1}function Ne(Se,Ft){return ut(Se.prev,Se,Se.next)<0?ut(Se,Ft,Se.next)>=0&&ut(Se,Se.prev,Ft)>=0:ut(Se,Ft,Se.prev)<0||ut(Se,Se.next,Ft)<0}function bt(Se,Ft){var mt=Se,ot=!1,We=(Se.x+Ft.x)/2,Me=(Se.y+Ft.y)/2;do mt.y>Me!=mt.next.y>Me&&mt.next.y!==mt.y&&We<(mt.next.x-mt.x)*(Me-mt.y)/(mt.next.y-mt.y)+mt.x&&(ot=!ot),mt=mt.next;while(mt!==Se);return ot}function et(Se,Ft){var mt=new ft(Se.i,Se.x,Se.y),ot=new ft(Ft.i,Ft.x,Ft.y),We=Se.next,Me=Ft.prev;return Se.next=Ft,Ft.prev=Se,mt.next=We,We.prev=mt,ot.next=mt,mt.prev=ot,Me.next=ot,ot.prev=Me,ot}function pt(Se,Ft,mt,ot){var We=new ft(Se,Ft,mt);return ot?(We.next=ot.next,We.prev=ot,ot.next.prev=We,ot.next=We):(We.prev=We,We.next=We),We}function Ke(Se){Se.next.prev=Se.prev,Se.prev.next=Se.next,Se.prevZ&&(Se.prevZ.nextZ=Se.nextZ),Se.nextZ&&(Se.nextZ.prevZ=Se.prevZ)}function ft(Se,Ft,mt){this.i=Se,this.x=Ft,this.y=mt,this.prev=null,this.next=null,this.z=0,this.prevZ=null,this.nextZ=null,this.steiner=!1}ye.deviation=function(Se,Ft,mt,ot){var We=Ft&&Ft.length,Me=We?Ft[0]*mt:Se.length,st=Math.abs(wt(Se,0,Me,mt));if(We)for(var Qe=0,dr=Ft.length;Qe0&&(ot+=Se[We-1].length,mt.holes.push(ot))}return mt}},42676:function(Ye){"use strict";var ye=Ye.exports={};ye.isIE=function(A){function R(){var y=navigator.userAgent.toLowerCase();return y.indexOf("msie")!==-1||y.indexOf("trident")!==-1||y.indexOf(" edge/")!==-1}if(!R())return!1;if(!A)return!0;var V=function(){var y,p=3,$=document.createElement("div"),X=$.getElementsByTagName("i");do $.innerHTML="";while(X[0]);return p>4?p:y}();return A===V},ye.isLegacyOpera=function(){return!!window.opera}},55776:function(Ye){"use strict";var ye=Ye.exports={};ye.forEach=function(A,R){for(var V=0;V div::-webkit-scrollbar { "+we(["display: none"])+` } + +`,ft+="."+Ke+" { "+we(["-webkit-animation-duration: 0.1s","animation-duration: 0.1s","-webkit-animation-name: "+pt,"animation-name: "+pt])+` } +`,ft+="@-webkit-keyframes "+pt+` { 0% { opacity: 1; } 50% { opacity: 0; } 100% { opacity: 1; } } +`,ft+="@keyframes "+pt+" { 0% { opacity: 1; } 50% { opacity: 0; } 100% { opacity: 1; } }",et(ft)}}function Ge(tt){tt.className+=" "+le+"_animation_active"}function ct(tt,Ne,bt){if(tt.addEventListener)tt.addEventListener(Ne,bt);else if(tt.attachEvent)tt.attachEvent("on"+Ne,bt);else return y.error("[scroll] Don't know how to add event listeners.")}function Ve(tt,Ne,bt){if(tt.removeEventListener)tt.removeEventListener(Ne,bt);else if(tt.detachEvent)tt.detachEvent("on"+Ne,bt);else return y.error("[scroll] Don't know how to remove event listeners.")}function ut(tt){return $(tt).container.childNodes[0].childNodes[0].childNodes[0]}function Xe(tt){return $(tt).container.childNodes[0].childNodes[0].childNodes[1]}function Rt(tt,Ne){var bt=$(tt).listeners;if(!bt.push)throw new Error("Cannot add listener to an element that is not detectable.");$(tt).listeners.push(Ne)}function gt(tt,Ne,bt){bt||(bt=Ne,Ne=tt,tt=null),tt=tt||{};function et(){if(tt.debug){var Qn=Array.prototype.slice.call(arguments);if(Qn.unshift(se.get(Ne),"Scroll: "),y.log.apply)y.log.apply(null,Qn);else for(var Ji=0;Ji=0&&(ae=[].concat(X.slice(ce,X.length),X.slice(1,ce+1))),ae},V.prototype.comparePath=function(X,se){var ae=this;return X.every(function(ce,le){return ae.compareCoord(ce,this[le])},se)},V.prototype.comparePolygon=function(X,se){if(this.compareLine(X.coordinates[0],se.coordinates[0],1,!0)){var ae=X.coordinates.slice(1,X.coordinates.length),ce=se.coordinates.slice(1,se.coordinates.length),le=this;return ae.every(function(De){return this.some(function(we){return le.compareLine(De,we,1,!0)})},ce)}else return!1},V.prototype.compareFeature=function(X,se){return X.id!==se.id||!this.objectComparator(X.properties,se.properties)||!this.compareBBox(X,se)?!1:this.compare(X.geometry,se.geometry)},V.prototype.compareBBox=function(X,se){return!!(!X.bbox&&!se.bbox||X.bbox&&se.bbox&&this.compareCoord(X.bbox,se.bbox))},V.prototype.removePseudo=function(X){return X};function $(X,se){return R(X,se,{strict:!0})}Ye.exports=V},56898:function(Ye,ye,A){var R=A(79535),V=A(78161),y=A(9750),p=A(76314).Z,$=y.featureEach,X=y.coordEach,se=V.polygon,ae=V.featureCollection;function ce(le){var De=new R(le);return De.insert=function(we){if(we.type!=="Feature")throw new Error("invalid feature");return we.bbox=we.bbox?we.bbox:p(we),R.prototype.insert.call(this,we)},De.load=function(we){var Ee=[];return Array.isArray(we)?we.forEach(function(qe){if(qe.type!=="Feature")throw new Error("invalid features");qe.bbox=qe.bbox?qe.bbox:p(qe),Ee.push(qe)}):$(we,function(qe){if(qe.type!=="Feature")throw new Error("invalid features");qe.bbox=qe.bbox?qe.bbox:p(qe),Ee.push(qe)}),R.prototype.load.call(this,Ee)},De.remove=function(we,Ee){if(we.type!=="Feature")throw new Error("invalid feature");return we.bbox=we.bbox?we.bbox:p(we),R.prototype.remove.call(this,we,Ee)},De.clear=function(){return R.prototype.clear.call(this)},De.search=function(we){var Ee=R.prototype.search.call(this,this.toBBox(we));return ae(Ee)},De.collides=function(we){return R.prototype.collides.call(this,this.toBBox(we))},De.all=function(){var we=R.prototype.all.call(this);return ae(we)},De.toJSON=function(){return R.prototype.toJSON.call(this)},De.fromJSON=function(we){return R.prototype.fromJSON.call(this,we)},De.toBBox=function(we){var Ee;if(we.bbox)Ee=we.bbox;else if(Array.isArray(we)&&we.length===4)Ee=we;else if(Array.isArray(we)&&we.length===6)Ee=[we[0],we[1],we[3],we[4]];else if(we.type==="Feature")Ee=p(we);else if(we.type==="FeatureCollection")Ee=p(we);else throw new Error("invalid geojson");return{minX:Ee[0],minY:Ee[1],maxX:Ee[2],maxY:Ee[3]}},De}Ye.exports=ce,Ye.exports.default=ce},64656:function(Ye,ye,A){"use strict";var R,V=A(68772),y=A(40625),p=A(92947),$=Function,X=function(wt){try{return $('"use strict"; return ('+wt+").constructor;")()}catch(Se){}},se=Object.getOwnPropertyDescriptor;if(se)try{se({},"")}catch(wt){se=null}var ae=function(){throw new p},ce=se?function(){try{return arguments.callee,ae}catch(wt){try{return se(arguments,"callee").get}catch(Se){return ae}}}():ae,le=A(9997)(),De=A(77916)(),we=Object.getPrototypeOf||(De?function(wt){return wt.__proto__}:null),Ee={},qe=typeof Uint8Array=="undefined"||!we?R:we(Uint8Array),Ge={__proto__:null,"%AggregateError%":typeof AggregateError=="undefined"?R:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer=="undefined"?R:ArrayBuffer,"%ArrayIteratorPrototype%":le&&we?we([][Symbol.iterator]()):R,"%AsyncFromSyncIteratorPrototype%":R,"%AsyncFunction%":Ee,"%AsyncGenerator%":Ee,"%AsyncGeneratorFunction%":Ee,"%AsyncIteratorPrototype%":Ee,"%Atomics%":typeof Atomics=="undefined"?R:Atomics,"%BigInt%":typeof BigInt=="undefined"?R:BigInt,"%BigInt64Array%":typeof BigInt64Array=="undefined"?R:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array=="undefined"?R:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView=="undefined"?R:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":typeof Float32Array=="undefined"?R:Float32Array,"%Float64Array%":typeof Float64Array=="undefined"?R:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry=="undefined"?R:FinalizationRegistry,"%Function%":$,"%GeneratorFunction%":Ee,"%Int8Array%":typeof Int8Array=="undefined"?R:Int8Array,"%Int16Array%":typeof Int16Array=="undefined"?R:Int16Array,"%Int32Array%":typeof Int32Array=="undefined"?R:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":le&&we?we(we([][Symbol.iterator]())):R,"%JSON%":typeof JSON=="object"?JSON:R,"%Map%":typeof Map=="undefined"?R:Map,"%MapIteratorPrototype%":typeof Map=="undefined"||!le||!we?R:we(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise=="undefined"?R:Promise,"%Proxy%":typeof Proxy=="undefined"?R:Proxy,"%RangeError%":V,"%ReferenceError%":ReferenceError,"%Reflect%":typeof Reflect=="undefined"?R:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set=="undefined"?R:Set,"%SetIteratorPrototype%":typeof Set=="undefined"||!le||!we?R:we(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer=="undefined"?R:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":le&&we?we(""[Symbol.iterator]()):R,"%Symbol%":le?Symbol:R,"%SyntaxError%":y,"%ThrowTypeError%":ce,"%TypedArray%":qe,"%TypeError%":p,"%Uint8Array%":typeof Uint8Array=="undefined"?R:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray=="undefined"?R:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array=="undefined"?R:Uint16Array,"%Uint32Array%":typeof Uint32Array=="undefined"?R:Uint32Array,"%URIError%":URIError,"%WeakMap%":typeof WeakMap=="undefined"?R:WeakMap,"%WeakRef%":typeof WeakRef=="undefined"?R:WeakRef,"%WeakSet%":typeof WeakSet=="undefined"?R:WeakSet};if(we)try{null.error}catch(wt){var ct=we(we(wt));Ge["%Error.prototype%"]=ct}var Ve=function wt(Se){var Ft;if(Se==="%AsyncFunction%")Ft=X("async function () {}");else if(Se==="%GeneratorFunction%")Ft=X("function* () {}");else if(Se==="%AsyncGeneratorFunction%")Ft=X("async function* () {}");else if(Se==="%AsyncGenerator%"){var mt=wt("%AsyncGeneratorFunction%");mt&&(Ft=mt.prototype)}else if(Se==="%AsyncIteratorPrototype%"){var ot=wt("%AsyncGenerator%");ot&&we&&(Ft=we(ot.prototype))}return Ge[Se]=Ft,Ft},ut={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},Xe=A(36723),Rt=A(68854),gt=Xe.call(Function.call,Array.prototype.concat),Ct=Xe.call(Function.apply,Array.prototype.splice),tt=Xe.call(Function.call,String.prototype.replace),Ne=Xe.call(Function.call,String.prototype.slice),bt=Xe.call(Function.call,RegExp.prototype.exec),et=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,pt=/\\(\\)?/g,Ke=function(Se){var Ft=Ne(Se,0,1),mt=Ne(Se,-1);if(Ft==="%"&&mt!=="%")throw new y("invalid intrinsic syntax, expected closing `%`");if(mt==="%"&&Ft!=="%")throw new y("invalid intrinsic syntax, expected opening `%`");var ot=[];return tt(Se,et,function(We,Me,st,Qe){ot[ot.length]=st?tt(Qe,pt,"$1"):Me||We}),ot},ft=function(Se,Ft){var mt=Se,ot;if(Rt(ut,mt)&&(ot=ut[mt],mt="%"+ot[0]+"%"),Rt(Ge,mt)){var We=Ge[mt];if(We===Ee&&(We=Ve(mt)),typeof We=="undefined"&&!Ft)throw new p("intrinsic "+Se+" exists, but is not available. Please file an issue!");return{alias:ot,name:mt,value:We}}throw new y("intrinsic "+Se+" does not exist!")};Ye.exports=function(Se,Ft){if(typeof Se!="string"||Se.length===0)throw new p("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof Ft!="boolean")throw new p('"allowMissing" argument must be a boolean');if(bt(/^%?[^%]*%?$/,Se)===null)throw new y("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var mt=Ke(Se),ot=mt.length>0?mt[0]:"",We=ft("%"+ot+"%",Ft),Me=We.name,st=We.value,Qe=!1,dr=We.alias;dr&&(ot=dr[0],Ct(mt,gt([0,1],dr)));for(var Kt=1,Yr=!0;Kt=mt.length){var Nn=se(st,hn);Yr=!!Nn,Yr&&"get"in Nn&&!("originalValue"in Nn.get)?st=Nn.get:st=st[hn]}else Yr=Rt(st,hn),st=st[hn];Yr&&!Qe&&(Ge[Me]=st)}}return st}},67747:function(Ye,ye,A){"use strict";var R=A(64656),V=R("%Object.getOwnPropertyDescriptor%",!0);if(V)try{V([],"length")}catch(y){V=null}Ye.exports=V},51831:function(Ye,ye,A){"use strict";A.d(ye,{BT:function(){return At},jf:function(){return bn},rS:function(){return nn}});var R=function(Pn){Pn=Pn||{};var Wr=typeof Pn!="undefined"?Pn:{},Ci={},at;for(at in Wr)Wr.hasOwnProperty(at)&&(Ci[at]=Wr[at]);var Vt=[],gr="";function gn(te){return Wr.locateFile?Wr.locateFile(te,gr):gr+te}var un;typeof document!="undefined"&&document.currentScript&&(gr=document.currentScript.src),gr.indexOf("blob:")!==0?gr=gr.substr(0,gr.lastIndexOf("/")+1):gr="",un=function(me,He,nt){var w=new XMLHttpRequest;w.open("GET",me,!0),w.responseType="arraybuffer",w.onload=function(){if(w.status==200||w.status==0&&w.response){He(w.response);return}var b=Ol(me);if(b){He(b.buffer);return}nt()},w.onerror=nt,w.send(null)};var Zi=Wr.print||console.log.bind(console),ho=Wr.printErr||console.warn.bind(console);for(at in Ci)Ci.hasOwnProperty(at)&&(Wr[at]=Ci[at]);Ci=null,Wr.arguments&&(Vt=Wr.arguments);var Na=0,mn=function(te){Na=te},Lr=function(){return Na},yr=8;function Mr(te,me,He,nt){switch(He=He||"i8",He.charAt(He.length-1)==="*"&&(He="i32"),He){case"i1":ns[te>>0]=me;break;case"i8":ns[te>>0]=me;break;case"i16":bs[te>>1]=me;break;case"i32":Hu[te>>2]=me;break;case"i64":yu=[me>>>0,(Zs=me,+qs(Zs)>=1?Zs>0?(su(+Cs(Zs/4294967296),4294967295)|0)>>>0:~~+Eu((Zs-+(~~Zs>>>0))/4294967296)>>>0:0)],Hu[te>>2]=yu[0],Hu[te+4>>2]=yu[1];break;case"float":en[te>>2]=me;break;case"double":xn[te>>3]=me;break;default:ee("invalid type for setValue: "+He)}}function Zr(te,me,He){switch(me=me||"i8",me.charAt(me.length-1)==="*"&&(me="i32"),me){case"i1":return ns[te>>0];case"i8":return ns[te>>0];case"i16":return bs[te>>1];case"i32":return Hu[te>>2];case"i64":return Hu[te>>2];case"float":return en[te>>2];case"double":return xn[te>>3];default:ee("invalid type for getValue: "+me)}return null}var Vn=!1;function In(te,me){te||ee("Assertion failed: "+me)}function Kn(te){var me=Wr["_"+te];return In(me,"Cannot call unknown function "+te+", make sure it is exported"),me}function Mi(te,me,He,nt,w){var Wt={string:function(dt){var zt=0;if(dt!=null&&dt!==0){var Tt=(dt.length<<2)+1;zt=v(Tt),lo(dt,zt,Tt)}return zt},array:function(dt){var zt=v(dt.length);return Da(dt,zt),zt}};function b(dt){return me==="string"?ya(dt):me==="boolean"?!!dt:dt}var x=Kn(te),S=[],U=0;if(nt)for(var pe=0;pe=nt);)++w;if(w-me>16&&te.subarray&&ro)return ro.decode(te.subarray(me,w));for(var Wt="";me>10,56320|U&1023)}}return Wt}function ya(te,me){return te?Ho(Vo,te,me):""}function gs(te,me,He,nt){if(!(nt>0))return 0;for(var w=He,Wt=He+nt-1,b=0;b=55296&&x<=57343){var S=te.charCodeAt(++b);x=65536+((x&1023)<<10)|S&1023}if(x<=127){if(He>=Wt)break;me[He++]=x}else if(x<=2047){if(He+1>=Wt)break;me[He++]=192|x>>6,me[He++]=128|x&63}else if(x<=65535){if(He+2>=Wt)break;me[He++]=224|x>>12,me[He++]=128|x>>6&63,me[He++]=128|x&63}else{if(He+3>=Wt)break;me[He++]=240|x>>18,me[He++]=128|x>>12&63,me[He++]=128|x>>6&63,me[He++]=128|x&63}}return me[He]=0,He-w}function lo(te,me,He){return gs(te,Vo,me,He)}var No=typeof TextDecoder!="undefined"?new TextDecoder("utf-16le"):void 0;function Da(te,me){ns.set(te,me)}function ta(te,me){return te%me>0&&(te+=me-te%me),te}var Ra,ns,Vo,bs,Js,Hu,Of,en,xn;function Vi(te){Ra=te,Wr.HEAP8=ns=new Int8Array(te),Wr.HEAP16=bs=new Int16Array(te),Wr.HEAP32=Hu=new Int32Array(te),Wr.HEAPU8=Vo=new Uint8Array(te),Wr.HEAPU16=Js=new Uint16Array(te),Wr.HEAPU32=Of=new Uint32Array(te),Wr.HEAPF32=en=new Float32Array(te),Wr.HEAPF64=xn=new Float64Array(te)}var wi=5267040,oo=24128,io=Wr.TOTAL_MEMORY||33554432;Wr.buffer?Ra=Wr.buffer:Ra=new ArrayBuffer(io),io=Ra.byteLength,Vi(Ra),Hu[oo>>2]=wi;function Uo(te){for(;te.length>0;){var me=te.shift();if(typeof me=="function"){me();continue}var He=me.func;typeof He=="number"?me.arg===void 0?Wr.dynCall_v(He):Wr.dynCall_vi(He,me.arg):He(me.arg===void 0?null:me.arg)}}var na=[],$a=[],Co=[],wo=[];function Pa(){if(Wr.preRun)for(typeof Wr.preRun=="function"&&(Wr.preRun=[Wr.preRun]);Wr.preRun.length;)Ns(Wr.preRun.shift());Uo(na)}function ss(){Uo($a)}function si(){Uo(Co)}function Ms(){if(Wr.postRun)for(typeof Wr.postRun=="function"&&(Wr.postRun=[Wr.postRun]);Wr.postRun.length;)Aa(Wr.postRun.shift());Uo(wo)}function Ns(te){na.unshift(te)}function Aa(te){wo.unshift(te)}var qs=Math.abs,Eu=Math.ceil,Cs=Math.floor,su=Math.min,Vs=0,tl=null,Xs=null;function rc(te){Vs++,Wr.monitorRunDependencies&&Wr.monitorRunDependencies(Vs)}function Ha(te){if(Vs--,Wr.monitorRunDependencies&&Wr.monitorRunDependencies(Vs),Vs==0&&(tl!==null&&(clearInterval(tl),tl=null),Xs)){var me=Xs;Xs=null,me()}}Wr.preloadedImages={},Wr.preloadedAudios={};var Qs=null,Uu="data:application/octet-stream;base64,";function St(te){return String.prototype.startsWith?te.startsWith(Uu):te.indexOf(Uu)===0}var Zs,yu;Qs="data:application/octet-stream;base64,AAAAAAAAAAAAAAAAAQAAAAIAAAADAAAABAAAAAUAAAAGAAAAAQAAAAQAAAADAAAABgAAAAUAAAACAAAAAAAAAAIAAAADAAAAAQAAAAQAAAAGAAAAAAAAAAUAAAADAAAABgAAAAQAAAAFAAAAAAAAAAEAAAACAAAABAAAAAUAAAAGAAAAAAAAAAIAAAADAAAAAQAAAAUAAAACAAAAAAAAAAEAAAADAAAABgAAAAQAAAAGAAAAAAAAAAUAAAACAAAAAQAAAAQAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAEAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAIAAAADAAAAAAAAAAAAAAACAAAAAAAAAAEAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAABAAAAAYAAAAAAAAABQAAAAAAAAAAAAAABAAAAAUAAAAAAAAAAAAAAAAAAAACAAAAAAAAAAYAAAAAAAAABgAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAgAAAAMAAAAEAAAABQAAAAYAAAABAAAAAgAAAAMAAAAEAAAABQAAAAYAAAAAAAAAAgAAAAMAAAAEAAAABQAAAAYAAAAAAAAAAQAAAAMAAAAEAAAABQAAAAYAAAAAAAAAAQAAAAIAAAAEAAAABQAAAAYAAAAAAAAAAQAAAAIAAAADAAAABQAAAAYAAAAAAAAAAQAAAAIAAAADAAAABAAAAAYAAAAAAAAAAQAAAAIAAAADAAAABAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAwAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAgAAAAIAAAAAAAAAAAAAAAYAAAAAAAAAAwAAAAIAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAAFAAAABAAAAAAAAAABAAAAAAAAAAAAAAAFAAAABQAAAAAAAAAAAAAAAAAAAAYAAAAAAAAABAAAAAAAAAAGAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAFAAAAAgAAAAQAAAADAAAACAAAAAEAAAAHAAAABgAAAAkAAAAAAAAAAwAAAAIAAAACAAAABgAAAAoAAAALAAAAAAAAAAEAAAAFAAAAAwAAAA0AAAABAAAABwAAAAQAAAAMAAAAAAAAAAQAAAB/AAAADwAAAAgAAAADAAAAAAAAAAwAAAAFAAAAAgAAABIAAAAKAAAACAAAAAAAAAAQAAAABgAAAA4AAAALAAAAEQAAAAEAAAAJAAAAAgAAAAcAAAAVAAAACQAAABMAAAADAAAADQAAAAEAAAAIAAAABQAAABYAAAAQAAAABAAAAAAAAAAPAAAACQAAABMAAAAOAAAAFAAAAAEAAAAHAAAABgAAAAoAAAALAAAAGAAAABcAAAAFAAAAAgAAABIAAAALAAAAEQAAABcAAAAZAAAAAgAAAAYAAAAKAAAADAAAABwAAAANAAAAGgAAAAQAAAAPAAAAAwAAAA0AAAAaAAAAFQAAAB0AAAADAAAADAAAAAcAAAAOAAAAfwAAABEAAAAbAAAACQAAABQAAAAGAAAADwAAABYAAAAcAAAAHwAAAAQAAAAIAAAADAAAABAAAAASAAAAIQAAAB4AAAAIAAAABQAAABYAAAARAAAACwAAAA4AAAAGAAAAIwAAABkAAAAbAAAAEgAAABgAAAAeAAAAIAAAAAUAAAAKAAAAEAAAABMAAAAiAAAAFAAAACQAAAAHAAAAFQAAAAkAAAAUAAAADgAAABMAAAAJAAAAKAAAABsAAAAkAAAAFQAAACYAAAATAAAAIgAAAA0AAAAdAAAABwAAABYAAAAQAAAAKQAAACEAAAAPAAAACAAAAB8AAAAXAAAAGAAAAAsAAAAKAAAAJwAAACUAAAAZAAAAGAAAAH8AAAAgAAAAJQAAAAoAAAAXAAAAEgAAABkAAAAXAAAAEQAAAAsAAAAtAAAAJwAAACMAAAAaAAAAKgAAAB0AAAArAAAADAAAABwAAAANAAAAGwAAACgAAAAjAAAALgAAAA4AAAAUAAAAEQAAABwAAAAfAAAAKgAAACwAAAAMAAAADwAAABoAAAAdAAAAKwAAACYAAAAvAAAADQAAABoAAAAVAAAAHgAAACAAAAAwAAAAMgAAABAAAAASAAAAIQAAAB8AAAApAAAALAAAADUAAAAPAAAAFgAAABwAAAAgAAAAHgAAABgAAAASAAAANAAAADIAAAAlAAAAIQAAAB4AAAAxAAAAMAAAABYAAAAQAAAAKQAAACIAAAATAAAAJgAAABUAAAA2AAAAJAAAADMAAAAjAAAALgAAAC0AAAA4AAAAEQAAABsAAAAZAAAAJAAAABQAAAAiAAAAEwAAADcAAAAoAAAANgAAACUAAAAnAAAANAAAADkAAAAYAAAAFwAAACAAAAAmAAAAfwAAACIAAAAzAAAAHQAAAC8AAAAVAAAAJwAAACUAAAAZAAAAFwAAADsAAAA5AAAALQAAACgAAAAbAAAAJAAAABQAAAA8AAAALgAAADcAAAApAAAAMQAAADUAAAA9AAAAFgAAACEAAAAfAAAAKgAAADoAAAArAAAAPgAAABwAAAAsAAAAGgAAACsAAAA+AAAALwAAAEAAAAAaAAAAKgAAAB0AAAAsAAAANQAAADoAAABBAAAAHAAAAB8AAAAqAAAALQAAACcAAAAjAAAAGQAAAD8AAAA7AAAAOAAAAC4AAAA8AAAAOAAAAEQAAAAbAAAAKAAAACMAAAAvAAAAJgAAACsAAAAdAAAARQAAADMAAABAAAAAMAAAADEAAAAeAAAAIQAAAEMAAABCAAAAMgAAADEAAAB/AAAAPQAAAEIAAAAhAAAAMAAAACkAAAAyAAAAMAAAACAAAAAeAAAARgAAAEMAAAA0AAAAMwAAAEUAAAA2AAAARwAAACYAAAAvAAAAIgAAADQAAAA5AAAARgAAAEoAAAAgAAAAJQAAADIAAAA1AAAAPQAAAEEAAABLAAAAHwAAACkAAAAsAAAANgAAAEcAAAA3AAAASQAAACIAAAAzAAAAJAAAADcAAAAoAAAANgAAACQAAABIAAAAPAAAAEkAAAA4AAAARAAAAD8AAABNAAAAIwAAAC4AAAAtAAAAOQAAADsAAABKAAAATgAAACUAAAAnAAAANAAAADoAAAB/AAAAPgAAAEwAAAAsAAAAQQAAACoAAAA7AAAAPwAAAE4AAABPAAAAJwAAAC0AAAA5AAAAPAAAAEgAAABEAAAAUAAAACgAAAA3AAAALgAAAD0AAAA1AAAAMQAAACkAAABRAAAASwAAAEIAAAA+AAAAKwAAADoAAAAqAAAAUgAAAEAAAABMAAAAPwAAAH8AAAA4AAAALQAAAE8AAAA7AAAATQAAAEAAAAAvAAAAPgAAACsAAABUAAAARQAAAFIAAABBAAAAOgAAADUAAAAsAAAAVgAAAEwAAABLAAAAQgAAAEMAAABRAAAAVQAAADEAAAAwAAAAPQAAAEMAAABCAAAAMgAAADAAAABXAAAAVQAAAEYAAABEAAAAOAAAADwAAAAuAAAAWgAAAE0AAABQAAAARQAAADMAAABAAAAALwAAAFkAAABHAAAAVAAAAEYAAABDAAAANAAAADIAAABTAAAAVwAAAEoAAABHAAAAWQAAAEkAAABbAAAAMwAAAEUAAAA2AAAASAAAAH8AAABJAAAANwAAAFAAAAA8AAAAWAAAAEkAAABbAAAASAAAAFgAAAA2AAAARwAAADcAAABKAAAATgAAAFMAAABcAAAANAAAADkAAABGAAAASwAAAEEAAAA9AAAANQAAAF4AAABWAAAAUQAAAEwAAABWAAAAUgAAAGAAAAA6AAAAQQAAAD4AAABNAAAAPwAAAEQAAAA4AAAAXQAAAE8AAABaAAAATgAAAEoAAAA7AAAAOQAAAF8AAABcAAAATwAAAE8AAABOAAAAPwAAADsAAABdAAAAXwAAAE0AAABQAAAARAAAAEgAAAA8AAAAYwAAAFoAAABYAAAAUQAAAFUAAABeAAAAZQAAAD0AAABCAAAASwAAAFIAAABgAAAAVAAAAGIAAAA+AAAATAAAAEAAAABTAAAAfwAAAEoAAABGAAAAZAAAAFcAAABcAAAAVAAAAEUAAABSAAAAQAAAAGEAAABZAAAAYgAAAFUAAABXAAAAZQAAAGYAAABCAAAAQwAAAFEAAABWAAAATAAAAEsAAABBAAAAaAAAAGAAAABeAAAAVwAAAFMAAABmAAAAZAAAAEMAAABGAAAAVQAAAFgAAABIAAAAWwAAAEkAAABjAAAAUAAAAGkAAABZAAAAYQAAAFsAAABnAAAARQAAAFQAAABHAAAAWgAAAE0AAABQAAAARAAAAGoAAABdAAAAYwAAAFsAAABJAAAAWQAAAEcAAABpAAAAWAAAAGcAAABcAAAAUwAAAE4AAABKAAAAbAAAAGQAAABfAAAAXQAAAE8AAABaAAAATQAAAG0AAABfAAAAagAAAF4AAABWAAAAUQAAAEsAAABrAAAAaAAAAGUAAABfAAAAXAAAAE8AAABOAAAAbQAAAGwAAABdAAAAYAAAAGgAAABiAAAAbgAAAEwAAABWAAAAUgAAAGEAAAB/AAAAYgAAAFQAAABnAAAAWQAAAG8AAABiAAAAbgAAAGEAAABvAAAAUgAAAGAAAABUAAAAYwAAAFAAAABpAAAAWAAAAGoAAABaAAAAcQAAAGQAAABmAAAAUwAAAFcAAABsAAAAcgAAAFwAAABlAAAAZgAAAGsAAABwAAAAUQAAAFUAAABeAAAAZgAAAGUAAABXAAAAVQAAAHIAAABwAAAAZAAAAGcAAABbAAAAYQAAAFkAAAB0AAAAaQAAAG8AAABoAAAAawAAAG4AAABzAAAAVgAAAF4AAABgAAAAaQAAAFgAAABnAAAAWwAAAHEAAABjAAAAdAAAAGoAAABdAAAAYwAAAFoAAAB1AAAAbQAAAHEAAABrAAAAfwAAAGUAAABeAAAAcwAAAGgAAABwAAAAbAAAAGQAAABfAAAAXAAAAHYAAAByAAAAbQAAAG0AAABsAAAAXQAAAF8AAAB1AAAAdgAAAGoAAABuAAAAYgAAAGgAAABgAAAAdwAAAG8AAABzAAAAbwAAAGEAAABuAAAAYgAAAHQAAABnAAAAdwAAAHAAAABrAAAAZgAAAGUAAAB4AAAAcwAAAHIAAABxAAAAYwAAAHQAAABpAAAAdQAAAGoAAAB5AAAAcgAAAHAAAABkAAAAZgAAAHYAAAB4AAAAbAAAAHMAAABuAAAAawAAAGgAAAB4AAAAdwAAAHAAAAB0AAAAZwAAAHcAAABvAAAAcQAAAGkAAAB5AAAAdQAAAH8AAABtAAAAdgAAAHEAAAB5AAAAagAAAHYAAAB4AAAAbAAAAHIAAAB1AAAAeQAAAG0AAAB3AAAAbwAAAHMAAABuAAAAeQAAAHQAAAB4AAAAeAAAAHMAAAByAAAAcAAAAHkAAAB3AAAAdgAAAHkAAAB0AAAAeAAAAHcAAAB1AAAAcQAAAHYAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAABAAAABQAAAAEAAAAAAAAAAAAAAAEAAAAAAAAAAQAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAACAAAABQAAAAEAAAAAAAAA/////wEAAAAAAAAAAwAAAAQAAAACAAAAAAAAAAAAAAABAAAAAAAAAAEAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAMAAAAFAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAFAAAAAQAAAAAAAAAAAAAAAQAAAAMAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAEAAAADAAAAAAAAAAAAAAABAAAAAAAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAADAAAABQAAAAEAAAAAAAAAAAAAAAEAAAAAAAAAAQAAAAAAAAABAAAAAAAAAP////8DAAAAAAAAAAUAAAACAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAEAAAABQAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAMAAAADAAAAAwAAAAMAAAAAAAAAAwAAAAAAAAAAAAAAAAAAAAMAAAAFAAAABQAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAADAAAAAwAAAAAAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAFAAAABQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAQAAAAAAAAABAAAAAAAAAAMAAAADAAAAAwAAAAAAAAADAAAAAAAAAAAAAAD/////AwAAAAAAAAAFAAAAAgAAAAAAAAAAAAAAAAAAAAAAAAADAAAAAAAAAAAAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAADAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAAAAAAAAAAAAAEAAAAAAAAAAQAAAAAAAAABAAAAAAAAAAAAAAABAAAAAwAAAAAAAAAAAAAAAQAAAAAAAAADAAAAAwAAAAMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAMAAAADAAAAAwAAAAMAAAAAAAAAAwAAAAAAAAAAAAAAAQAAAAMAAAAAAAAAAAAAAAEAAAAAAAAAAwAAAAMAAAADAAAAAwAAAAAAAAADAAAAAAAAAAAAAAADAAAAAAAAAAMAAAAAAAAAAwAAAAAAAAAAAAAAAAAAAAMAAAAAAAAAAAAAAAMAAAAAAAAAAwAAAAAAAAAAAAAAAAAAAAMAAAADAAAAAAAAAP////8DAAAAAAAAAAUAAAACAAAAAAAAAAAAAAADAAAAAAAAAAAAAAADAAAAAwAAAAAAAAAAAAAAAwAAAAAAAAAAAAAAAwAAAAMAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAUAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAFAAAABQAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAwAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAwAAAAAAAAAAAAAAAwAAAAMAAAAAAAAAAAAAAAAAAAADAAAAAAAAAAMAAAAAAAAAAAAAAAMAAAADAAAAAwAAAAAAAAADAAAAAAAAAAAAAAADAAAAAwAAAAMAAAAAAAAAAwAAAAAAAAAAAAAA/////wMAAAAAAAAABQAAAAIAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAAAAAAAAAAAAwAAAAAAAAADAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAAAAAAAAAAAAAMAAAAAAAAAAwAAAAAAAAADAAAAAAAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAAAAAADAAAAAAAAAAMAAAAAAAAAAAAAAAMAAAAAAAAAAAAAAAMAAAADAAAAAAAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAwAAAAAAAAAAAAAAAAAAAAMAAAAAAAAAAwAAAAAAAAAAAAAA/////wMAAAAAAAAABQAAAAIAAAAAAAAAAAAAAAMAAAADAAAAAwAAAAMAAAADAAAAAAAAAAAAAAADAAAAAwAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAwAAAAAAAAADAAAAAAAAAAMAAAADAAAAAwAAAAMAAAAAAAAAAwAAAAAAAAD/////AwAAAAAAAAAFAAAAAgAAAAAAAAAAAAAAAAAAAAAAAAADAAAAAAAAAAAAAAADAAAAAAAAAAMAAAADAAAAAwAAAAAAAAADAAAAAAAAAAAAAAADAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAAAAAAAAwAAAAAAAAAAAAAAAwAAAAMAAAAAAAAAAAAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAADAAAAAAAAAAAAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAMAAAAAAAAAAAAAAAMAAAADAAAAAAAAAAAAAAAAAAAAAwAAAAAAAAADAAAAAAAAAAAAAAD/////AwAAAAAAAAAFAAAAAgAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAAAAAAAAAAADAAAAAAAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAwAAAAAAAAAAAAAAAAAAAAMAAAAAAAAAAAAAAAMAAAAAAAAAAwAAAAAAAAAAAAAAAAAAAAMAAAADAAAAAAAAAAAAAAAAAAAAAwAAAAAAAAAFAAAAAAAAAAAAAAADAAAAAwAAAAMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAADAAAAAQAAAAAAAAABAAAAAAAAAAAAAAABAAAAAwAAAAEAAAAAAAAAAQAAAAAAAAAAAAAAAwAAAAAAAAADAAAAAAAAAAMAAAAAAAAAAAAAAAMAAAAAAAAAAwAAAAAAAAADAAAAAAAAAP////8DAAAAAAAAAAUAAAACAAAAAAAAAAAAAAAAAAAAAwAAAAAAAAAAAAAAAwAAAAMAAAAAAAAAAAAAAAAAAAADAAAAAAAAAAMAAAAAAAAAAAAAAAMAAAAAAAAAAAAAAAMAAAADAAAAAAAAAAAAAAADAAAAAwAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAADAAAAAAAAAAUAAAAAAAAAAAAAAAMAAAADAAAAAwAAAAMAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAwAAAAMAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAAAAAAFAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAFAAAABQAAAAAAAAAAAAAAAAAAAAMAAAAAAAAAAAAAAAMAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAMAAAAAAAAAAwAAAAAAAAAAAAAA/////wMAAAAAAAAABQAAAAIAAAAAAAAAAAAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAwAAAAAAAAAFAAAAAAAAAAAAAAAFAAAABQAAAAAAAAAAAAAAAAAAAAEAAAADAAAAAQAAAAAAAAABAAAAAAAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAwAAAAAAAAADAAAAAwAAAAMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAADAAAAAQAAAAAAAAABAAAAAAAAAAMAAAADAAAAAwAAAAMAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAEAAAAAAAAAAwAAAAUAAAABAAAAAAAAAP////8DAAAAAAAAAAUAAAACAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAFAAAABQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAABAAAAAUAAAABAAAAAAAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAADAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAIAAAAFAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAEAAAADAAAAAQAAAAAAAAABAAAAAAAAAAUAAAAAAAAAAAAAAAUAAAAFAAAAAAAAAAAAAAD/////AQAAAAAAAAADAAAABAAAAAIAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAUAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAFAAAAAAAAAAAAAAAFAAAABQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAQAAAAUAAAABAAAAAAAAAAAAAAABAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAgAAAAEAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAIAAAAAAAAAAAAAAAEAAAD//////////wEAAAABAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAQAAAAEAAAAAAAAAAAAAAAAAAAADAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAEAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAsAAAACAAAAAAAAAAAAAAABAAAAAgAAAAYAAAAEAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAYAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAgAAAAAAAAABAAAAAQAAAAAAAAAAAAAAAAAAAAcAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAACAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAYAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAKAAAAAgAAAAAAAAAAAAAAAQAAAAEAAAAFAAAABgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAALAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAEAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAABAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAABwAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAsAAAABAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACgAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAACAAAAAAAAAAAAAAABAAAAAwAAAAcAAAAGAAAAAQAAAAAAAAABAAAAAAAAAAAAAAAAAAAABwAAAAEAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAADAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAwAAAAAAAAABAAAAAQAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAGAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAgAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAADgAAAAIAAAAAAAAAAAAAAAEAAAAAAAAACQAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACgAAAAEAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAQAAAAEAAAAAAAAAAAAAAAAAAAAMAAAAAQAAAAEAAAAAAAAAAAAAAAAAAAAAAAAABwAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAsAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAKAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADQAAAAIAAAAAAAAAAAAAAAEAAAAEAAAACAAAAAoAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAALAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAACQAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAgAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAGAAAAAgAAAAAAAAAAAAAAAQAAAAsAAAAPAAAACAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAkAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAOAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAEAAAAAAAAAAQAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAQAAAAEAAAAAAAAAAAAAAAAAAAAIAAAAAQAAAAAAAAABAAAAAAAAAAAAAAAAAAAABQAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAAAAgAAAAAAAAAAAAAAAQAAAAwAAAAQAAAADAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAoAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAJAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADQAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAPAAAAAAAAAAEAAAABAAAAAAAAAAAAAAAAAAAADwAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAQAAAAEAAAAAAAAAAAAAAAAAAAAAAAAADQAAAAEAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAACAAAAAAAAAAAAAAABAAAACgAAABMAAAAIAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAkAAAABAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAEQAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAwAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEQAAAAAAAAABAAAAAQAAAAAAAAAAAAAAAAAAAA8AAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAQAAAAAQAAAAAAAAABAAAAAAAAAAAAAAAAAAAACQAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAANAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACAAAAAIAAAAAAAAAAAAAAAEAAAANAAAAEQAAAA0AAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAARAAAAAQAAAAAAAAABAAAAAAAAAAAAAAAAAAAAEwAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAA4AAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAATAAAAAAAAAAEAAAABAAAAAAAAAAAAAAAAAAAAEQAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAA0AAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAARAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAkAAAACAAAAAAAAAAAAAAABAAAADgAAABIAAAAPAAAAAQAAAAAAAAABAAAAAAAAAAAAAAAAAAAADwAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABIAAAAAAAAAAQAAAAEAAAAAAAAAAAAAAAAAAAASAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAEwAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAABEAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAATAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEgAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAABIAAAABAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAATAAAAAgAAAAAAAAAAAAAAAQAAAP//////////EwAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAATAAAAAQAAAAAAAAABAAAAAAAAAAAAAAAAAAAAEgAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAASAAAAAAAAABgAAAAAAAAAIQAAAAAAAAAeAAAAAAAAACAAAAADAAAAMQAAAAEAAAAwAAAAAwAAADIAAAADAAAACAAAAAAAAAAFAAAABQAAAAoAAAAFAAAAFgAAAAAAAAAQAAAAAAAAABIAAAAAAAAAKQAAAAEAAAAhAAAAAAAAAB4AAAAAAAAABAAAAAAAAAAAAAAABQAAAAIAAAAFAAAADwAAAAEAAAAIAAAAAAAAAAUAAAAFAAAAHwAAAAEAAAAWAAAAAAAAABAAAAAAAAAAAgAAAAAAAAAGAAAAAAAAAA4AAAAAAAAACgAAAAAAAAALAAAAAAAAABEAAAADAAAAGAAAAAEAAAAXAAAAAwAAABkAAAADAAAAAAAAAAAAAAABAAAABQAAAAkAAAAFAAAABQAAAAAAAAACAAAAAAAAAAYAAAAAAAAAEgAAAAEAAAAKAAAAAAAAAAsAAAAAAAAABAAAAAEAAAADAAAABQAAAAcAAAAFAAAACAAAAAEAAAAAAAAAAAAAAAEAAAAFAAAAEAAAAAEAAAAFAAAAAAAAAAIAAAAAAAAABwAAAAAAAAAVAAAAAAAAACYAAAAAAAAACQAAAAAAAAATAAAAAAAAACIAAAADAAAADgAAAAEAAAAUAAAAAwAAACQAAAADAAAAAwAAAAAAAAANAAAABQAAAB0AAAAFAAAAAQAAAAAAAAAHAAAAAAAAABUAAAAAAAAABgAAAAEAAAAJAAAAAAAAABMAAAAAAAAABAAAAAIAAAAMAAAABQAAABoAAAAFAAAAAAAAAAEAAAADAAAAAAAAAA0AAAAFAAAAAgAAAAEAAAABAAAAAAAAAAcAAAAAAAAAGgAAAAAAAAAqAAAAAAAAADoAAAAAAAAAHQAAAAAAAAArAAAAAAAAAD4AAAADAAAAJgAAAAEAAAAvAAAAAwAAAEAAAAADAAAADAAAAAAAAAAcAAAABQAAACwAAAAFAAAADQAAAAAAAAAaAAAAAAAAACoAAAAAAAAAFQAAAAEAAAAdAAAAAAAAACsAAAAAAAAABAAAAAMAAAAPAAAABQAAAB8AAAAFAAAAAwAAAAEAAAAMAAAAAAAAABwAAAAFAAAABwAAAAEAAAANAAAAAAAAABoAAAAAAAAAHwAAAAAAAAApAAAAAAAAADEAAAAAAAAALAAAAAAAAAA1AAAAAAAAAD0AAAADAAAAOgAAAAEAAABBAAAAAwAAAEsAAAADAAAADwAAAAAAAAAWAAAABQAAACEAAAAFAAAAHAAAAAAAAAAfAAAAAAAAACkAAAAAAAAAKgAAAAEAAAAsAAAAAAAAADUAAAAAAAAABAAAAAQAAAAIAAAABQAAABAAAAAFAAAADAAAAAEAAAAPAAAAAAAAABYAAAAFAAAAGgAAAAEAAAAcAAAAAAAAAB8AAAAAAAAAMgAAAAAAAAAwAAAAAAAAADEAAAADAAAAIAAAAAAAAAAeAAAAAwAAACEAAAADAAAAGAAAAAMAAAASAAAAAwAAABAAAAADAAAARgAAAAAAAABDAAAAAAAAAEIAAAADAAAANAAAAAMAAAAyAAAAAAAAADAAAAAAAAAAJQAAAAMAAAAgAAAAAAAAAB4AAAADAAAAUwAAAAAAAABXAAAAAwAAAFUAAAADAAAASgAAAAMAAABGAAAAAAAAAEMAAAAAAAAAOQAAAAEAAAA0AAAAAwAAADIAAAAAAAAAGQAAAAAAAAAXAAAAAAAAABgAAAADAAAAEQAAAAAAAAALAAAAAwAAAAoAAAADAAAADgAAAAMAAAAGAAAAAwAAAAIAAAADAAAALQAAAAAAAAAnAAAAAAAAACUAAAADAAAAIwAAAAMAAAAZAAAAAAAAABcAAAAAAAAAGwAAAAMAAAARAAAAAAAAAAsAAAADAAAAPwAAAAAAAAA7AAAAAwAAADkAAAADAAAAOAAAAAMAAAAtAAAAAAAAACcAAAAAAAAALgAAAAMAAAAjAAAAAwAAABkAAAAAAAAAJAAAAAAAAAAUAAAAAAAAAA4AAAADAAAAIgAAAAAAAAATAAAAAwAAAAkAAAADAAAAJgAAAAMAAAAVAAAAAwAAAAcAAAADAAAANwAAAAAAAAAoAAAAAAAAABsAAAADAAAANgAAAAMAAAAkAAAAAAAAABQAAAAAAAAAMwAAAAMAAAAiAAAAAAAAABMAAAADAAAASAAAAAAAAAA8AAAAAwAAAC4AAAADAAAASQAAAAMAAAA3AAAAAAAAACgAAAAAAAAARwAAAAMAAAA2AAAAAwAAACQAAAAAAAAAQAAAAAAAAAAvAAAAAAAAACYAAAADAAAAPgAAAAAAAAArAAAAAwAAAB0AAAADAAAAOgAAAAMAAAAqAAAAAwAAABoAAAADAAAAVAAAAAAAAABFAAAAAAAAADMAAAADAAAAUgAAAAMAAABAAAAAAAAAAC8AAAAAAAAATAAAAAMAAAA+AAAAAAAAACsAAAADAAAAYQAAAAAAAABZAAAAAwAAAEcAAAADAAAAYgAAAAMAAABUAAAAAAAAAEUAAAAAAAAAYAAAAAMAAABSAAAAAwAAAEAAAAAAAAAASwAAAAAAAABBAAAAAAAAADoAAAADAAAAPQAAAAAAAAA1AAAAAwAAACwAAAADAAAAMQAAAAMAAAApAAAAAwAAAB8AAAADAAAAXgAAAAAAAABWAAAAAAAAAEwAAAADAAAAUQAAAAMAAABLAAAAAAAAAEEAAAAAAAAAQgAAAAMAAAA9AAAAAAAAADUAAAADAAAAawAAAAAAAABoAAAAAwAAAGAAAAADAAAAZQAAAAMAAABeAAAAAAAAAFYAAAAAAAAAVQAAAAMAAABRAAAAAwAAAEsAAAAAAAAAOQAAAAAAAAA7AAAAAAAAAD8AAAADAAAASgAAAAAAAABOAAAAAwAAAE8AAAADAAAAUwAAAAMAAABcAAAAAwAAAF8AAAADAAAAJQAAAAAAAAAnAAAAAwAAAC0AAAADAAAANAAAAAAAAAA5AAAAAAAAADsAAAAAAAAARgAAAAMAAABKAAAAAAAAAE4AAAADAAAAGAAAAAAAAAAXAAAAAwAAABkAAAADAAAAIAAAAAMAAAAlAAAAAAAAACcAAAADAAAAMgAAAAMAAAA0AAAAAAAAADkAAAAAAAAALgAAAAAAAAA8AAAAAAAAAEgAAAADAAAAOAAAAAAAAABEAAAAAwAAAFAAAAADAAAAPwAAAAMAAABNAAAAAwAAAFoAAAADAAAAGwAAAAAAAAAoAAAAAwAAADcAAAADAAAAIwAAAAAAAAAuAAAAAAAAADwAAAAAAAAALQAAAAMAAAA4AAAAAAAAAEQAAAADAAAADgAAAAAAAAAUAAAAAwAAACQAAAADAAAAEQAAAAMAAAAbAAAAAAAAACgAAAADAAAAGQAAAAMAAAAjAAAAAAAAAC4AAAAAAAAARwAAAAAAAABZAAAAAAAAAGEAAAADAAAASQAAAAAAAABbAAAAAwAAAGcAAAADAAAASAAAAAMAAABYAAAAAwAAAGkAAAADAAAAMwAAAAAAAABFAAAAAwAAAFQAAAADAAAANgAAAAAAAABHAAAAAAAAAFkAAAAAAAAANwAAAAMAAABJAAAAAAAAAFsAAAADAAAAJgAAAAAAAAAvAAAAAwAAAEAAAAADAAAAIgAAAAMAAAAzAAAAAAAAAEUAAAADAAAAJAAAAAMAAAA2AAAAAAAAAEcAAAAAAAAAYAAAAAAAAABoAAAAAAAAAGsAAAADAAAAYgAAAAAAAABuAAAAAwAAAHMAAAADAAAAYQAAAAMAAABvAAAAAwAAAHcAAAADAAAATAAAAAAAAABWAAAAAwAAAF4AAAADAAAAUgAAAAAAAABgAAAAAAAAAGgAAAAAAAAAVAAAAAMAAABiAAAAAAAAAG4AAAADAAAAOgAAAAAAAABBAAAAAwAAAEsAAAADAAAAPgAAAAMAAABMAAAAAAAAAFYAAAADAAAAQAAAAAMAAABSAAAAAAAAAGAAAAAAAAAAVQAAAAAAAABXAAAAAAAAAFMAAAADAAAAZQAAAAAAAABmAAAAAwAAAGQAAAADAAAAawAAAAMAAABwAAAAAwAAAHIAAAADAAAAQgAAAAAAAABDAAAAAwAAAEYAAAADAAAAUQAAAAAAAABVAAAAAAAAAFcAAAAAAAAAXgAAAAMAAABlAAAAAAAAAGYAAAADAAAAMQAAAAAAAAAwAAAAAwAAADIAAAADAAAAPQAAAAMAAABCAAAAAAAAAEMAAAADAAAASwAAAAMAAABRAAAAAAAAAFUAAAAAAAAAXwAAAAAAAABcAAAAAAAAAFMAAAAAAAAATwAAAAAAAABOAAAAAAAAAEoAAAADAAAAPwAAAAEAAAA7AAAAAwAAADkAAAADAAAAbQAAAAAAAABsAAAAAAAAAGQAAAAFAAAAXQAAAAEAAABfAAAAAAAAAFwAAAAAAAAATQAAAAEAAABPAAAAAAAAAE4AAAAAAAAAdQAAAAQAAAB2AAAABQAAAHIAAAAFAAAAagAAAAEAAABtAAAAAAAAAGwAAAAAAAAAWgAAAAEAAABdAAAAAQAAAF8AAAAAAAAAWgAAAAAAAABNAAAAAAAAAD8AAAAAAAAAUAAAAAAAAABEAAAAAAAAADgAAAADAAAASAAAAAEAAAA8AAAAAwAAAC4AAAADAAAAagAAAAAAAABdAAAAAAAAAE8AAAAFAAAAYwAAAAEAAABaAAAAAAAAAE0AAAAAAAAAWAAAAAEAAABQAAAAAAAAAEQAAAAAAAAAdQAAAAMAAABtAAAABQAAAF8AAAAFAAAAcQAAAAEAAABqAAAAAAAAAF0AAAAAAAAAaQAAAAEAAABjAAAAAQAAAFoAAAAAAAAAaQAAAAAAAABYAAAAAAAAAEgAAAAAAAAAZwAAAAAAAABbAAAAAAAAAEkAAAADAAAAYQAAAAEAAABZAAAAAwAAAEcAAAADAAAAcQAAAAAAAABjAAAAAAAAAFAAAAAFAAAAdAAAAAEAAABpAAAAAAAAAFgAAAAAAAAAbwAAAAEAAABnAAAAAAAAAFsAAAAAAAAAdQAAAAIAAABqAAAABQAAAFoAAAAFAAAAeQAAAAEAAABxAAAAAAAAAGMAAAAAAAAAdwAAAAEAAAB0AAAAAQAAAGkAAAAAAAAAdwAAAAAAAABvAAAAAAAAAGEAAAAAAAAAcwAAAAAAAABuAAAAAAAAAGIAAAADAAAAawAAAAEAAABoAAAAAwAAAGAAAAADAAAAeQAAAAAAAAB0AAAAAAAAAGcAAAAFAAAAeAAAAAEAAAB3AAAAAAAAAG8AAAAAAAAAcAAAAAEAAABzAAAAAAAAAG4AAAAAAAAAdQAAAAEAAABxAAAABQAAAGkAAAAFAAAAdgAAAAEAAAB5AAAAAAAAAHQAAAAAAAAAcgAAAAEAAAB4AAAAAQAAAHcAAAAAAAAAcgAAAAAAAABwAAAAAAAAAGsAAAAAAAAAZAAAAAAAAABmAAAAAAAAAGUAAAADAAAAUwAAAAEAAABXAAAAAwAAAFUAAAADAAAAdgAAAAAAAAB4AAAAAAAAAHMAAAAFAAAAbAAAAAEAAAByAAAAAAAAAHAAAAAAAAAAXAAAAAEAAABkAAAAAAAAAGYAAAAAAAAAdQAAAAAAAAB5AAAABQAAAHcAAAAFAAAAbQAAAAEAAAB2AAAAAAAAAHgAAAAAAAAAXwAAAAEAAABsAAAAAQAAAHIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAEAAAAAAAAAAAAAAAEAAAABAAAAAQAAAAAAAAAAAAAAAQAAAAAAAAABAAAAAQAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAGAAAAAgAAAAUAAAABAAAABAAAAAAAAAAAAAAABQAAAAMAAAABAAAABgAAAAQAAAACAAAAAAAAAH6iBfbytuk/Gq6akm/58z/Xrm0Liez0P5doSdOpSwRAWs602ULg8D/dT7Rcbo/1v1N1RQHFNOM/g9Snx7HW3L8HWsP8Q3jfP6VwOLosutk/9rjk1YQcxj+gnmKMsNn6P/HDeuPFY+M/YHwDjqKhB0Ci19/fCVrbP4UxKkDWOP6/pvljWa09tL9wi7wrQXjnv/Z6yLImkM2/3yTlOzY14D+m+WNZrT20PzwKVQnrQwNA9nrIsiaQzT/g40rFrRQFwPa45NWEHMa/kbslHEZq97/xw3rjxWPjv4cLC2SMBci/otff3wla27+rKF5oIAv0P1N1RQHFNOO/iDJPGyWHBUAHWsP8Q3jfvwQf/by16gXAfqIF9vK26b8XrO0Vh0r+v9eubQuJ7PS/BxLrA0ZZ479azrTZQuDwv1MK1EuItPw/yscgV9Z6FkAwHBR2WjQMQJNRzXsQ5vY/GlUHVJYKF0DONuFv2lMNQNCGZ28QJfk/0WUwoIL36D8ggDOMQuATQNqMOeAy/wZAWFYOYM+M2z/LWC4uH3oSQDE+LyTsMgRAkJzhRGWFGEDd4soovCQQQKqk0DJMEP8/rGmNdwOLBUAW2X/9xCbjP4hu3dcqJhNAzuYItRvdB0CgzW3zJW/sPxotm/Y2TxRAQAk9XmdDDEC1Kx9MKgT3P1M+NctcghZAFVqcLlb0C0Bgzd3sB2b2P77mZDPUWhZAFROHJpUGCEDAfma5CxXtPz1DWq/zYxRAmhYY5824F0DOuQKWSbAOQNCMqrvu3fs/L6DR22K2wT9nAAxPBU8RQGiN6mW43AFAZhu25b633D8c1YgmzowSQNM25BRKWARArGS08/lNxD+LFssHwmMRQLC5aNcxBgJABL9HT0WRF0CjCmJmOGEOQHsuaVzMP/s/TWJCaGGwBUCeu1PAPLzjP9nqN9DZOBNAKE4JcydbCkCGtbd1qjPzP8dgm9U8jhVAtPeKTkVwDkCeCLss5l37P401XMPLmBdAFd29VMVQDUBg0yA55h75Pz6odcYLCRdApBM4rBrkAkDyAVWgQxbRP4XDMnK20hFAymLlF7EmzD8GUgo9XBHlP3lbK7T9COc/k+OhPthhy7+YGEpnrOvCPzBFhLs15u4/epbqB6H4uz9IuuLF5svev6lzLKY31es/CaQ0envF5z8ZY0xlUADXv7zaz7HYEuI/CfbK1sn16T8uAQfWwxLWPzKn/YuFN94/5KdbC1AFu793fyCSnlfvPzK2y4doAMY/NRg5t1/X6b/shq4QJaHDP5yNIAKPOeI/vpn7BSE30r/X4YQrO6nrv78Ziv/Thto/DqJ1Y6+y5z9l51NaxFrlv8QlA65HOLS/86dxiEc96z+Hj0+LFjneP6LzBZ8LTc2/DaJ1Y6+y579l51NaxFrlP8QlA65HOLQ/8qdxiEc967+Jj0+LFjnev6LzBZ8LTc0/1qdbC1AFuz93fyCSnlfvvzK2y4doAMa/NRg5t1/X6T/vhq4QJaHDv5yNIAKPOeK/wJn7BSE30j/W4YQrO6nrP78Ziv/Thtq/CaQ0envF578XY0xlUADXP7zaz7HYEuK/CvbK1sn16b8rAQfWwxLWvzKn/YuFN96/zWLlF7EmzL8GUgo9XBHlv3lbK7T9COe/kOOhPthhyz+cGEpnrOvCvzBFhLs15u6/c5bqB6H4u79IuuLF5sveP6lzLKY31eu/AQAAAP////8HAAAA/////zEAAAD/////VwEAAP////9hCQAA/////6dBAAD/////kcsBAP/////3kAwA/////8H2VwAAAAAAAAAAAAAAAAACAAAA/////w4AAAD/////YgAAAP////+uAgAA/////8ISAAD/////ToMAAP////8ilwMA/////+4hGQD/////gu2vAAAAAAAAAAAAAAAAAAAAAAACAAAA//////////8BAAAAAwAAAP//////////////////////////////////////////////////////////////////////////AQAAAAAAAAACAAAA////////////////AwAAAP//////////////////////////////////////////////////////////////////////////AQAAAAAAAAACAAAA////////////////AwAAAP//////////////////////////////////////////////////////////////////////////AQAAAAAAAAACAAAA////////////////AwAAAP//////////////////////////////////////////////////////////AgAAAP//////////AQAAAAAAAAD/////////////////////AwAAAP////////////////////////////////////////////////////8DAAAA/////////////////////wAAAAD/////////////////////AQAAAP///////////////wIAAAD///////////////////////////////8DAAAA/////////////////////wAAAAD///////////////8CAAAAAQAAAP////////////////////////////////////////////////////8DAAAA/////////////////////wAAAAD///////////////8CAAAAAQAAAP////////////////////////////////////////////////////8DAAAA/////////////////////wAAAAD///////////////8CAAAAAQAAAP////////////////////////////////////////////////////8DAAAA/////////////////////wAAAAD///////////////8CAAAAAQAAAP////////////////////////////////////////////////////8BAAAAAgAAAP///////////////wAAAAD/////////////////////AwAAAP////////////////////////////////////////////////////8BAAAAAgAAAP///////////////wAAAAD/////////////////////AwAAAP////////////////////////////////////////////////////8BAAAAAgAAAP///////////////wAAAAD/////////////////////AwAAAP////////////////////////////////////////////////////8BAAAAAgAAAP///////////////wAAAAD/////////////////////AwAAAP///////////////////////////////wIAAAD///////////////8BAAAA/////////////////////wAAAAD/////////////////////AwAAAP////////////////////////////////////////////////////8DAAAA/////////////////////wAAAAABAAAA//////////8CAAAA//////////////////////////////////////////////////////////8DAAAA////////////////AgAAAAAAAAABAAAA//////////////////////////////////////////////////////////////////////////8DAAAA////////////////AgAAAAAAAAABAAAA//////////////////////////////////////////////////////////////////////////8DAAAA////////////////AgAAAAAAAAABAAAA//////////////////////////////////////////////////////////////////////////8DAAAAAQAAAP//////////AgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAACAAAAAAAAAAIAAAABAAAAAQAAAAIAAAACAAAAAAAAAAUAAAAFAAAAAAAAAAIAAAACAAAAAwAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAIAAAAAAAAAAgAAAAEAAAACAAAAAgAAAAIAAAAAAAAABQAAAAYAAAAAAAAAAgAAAAIAAAADAAAAAgAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAgAAAAAAAAACAAAAAQAAAAMAAAACAAAAAgAAAAAAAAAFAAAABwAAAAAAAAACAAAAAgAAAAMAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAIAAAACAAAAAAAAAAIAAAABAAAABAAAAAIAAAACAAAAAAAAAAUAAAAIAAAAAAAAAAIAAAACAAAAAwAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAIAAAAAAAAAAgAAAAEAAAAAAAAAAgAAAAIAAAAAAAAABQAAAAkAAAAAAAAAAgAAAAIAAAADAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAKAAAAAgAAAAIAAAAAAAAAAwAAAA4AAAACAAAAAAAAAAIAAAADAAAAAAAAAAAAAAACAAAAAgAAAAMAAAAGAAAAAAAAAAAAAAAAAAAAAAAAAAsAAAACAAAAAgAAAAAAAAADAAAACgAAAAIAAAAAAAAAAgAAAAMAAAABAAAAAAAAAAIAAAACAAAAAwAAAAcAAAAAAAAAAAAAAAAAAAAAAAAADAAAAAIAAAACAAAAAAAAAAMAAAALAAAAAgAAAAAAAAACAAAAAwAAAAIAAAAAAAAAAgAAAAIAAAADAAAACAAAAAAAAAAAAAAAAAAAAAAAAAANAAAAAgAAAAIAAAAAAAAAAwAAAAwAAAACAAAAAAAAAAIAAAADAAAAAwAAAAAAAAACAAAAAgAAAAMAAAAJAAAAAAAAAAAAAAAAAAAAAAAAAA4AAAACAAAAAgAAAAAAAAADAAAADQAAAAIAAAAAAAAAAgAAAAMAAAAEAAAAAAAAAAIAAAACAAAAAwAAAAoAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAIAAAACAAAAAAAAAAMAAAAGAAAAAgAAAAAAAAACAAAAAwAAAA8AAAAAAAAAAgAAAAIAAAADAAAACwAAAAAAAAAAAAAAAAAAAAAAAAAGAAAAAgAAAAIAAAAAAAAAAwAAAAcAAAACAAAAAAAAAAIAAAADAAAAEAAAAAAAAAACAAAAAgAAAAMAAAAMAAAAAAAAAAAAAAAAAAAAAAAAAAcAAAACAAAAAgAAAAAAAAADAAAACAAAAAIAAAAAAAAAAgAAAAMAAAARAAAAAAAAAAIAAAACAAAAAwAAAA0AAAAAAAAAAAAAAAAAAAAAAAAACAAAAAIAAAACAAAAAAAAAAMAAAAJAAAAAgAAAAAAAAACAAAAAwAAABIAAAAAAAAAAgAAAAIAAAADAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAJAAAAAgAAAAIAAAAAAAAAAwAAAAUAAAACAAAAAAAAAAIAAAADAAAAEwAAAAAAAAACAAAAAgAAAAMAAAAPAAAAAAAAAAAAAAAAAAAAAAAAABAAAAACAAAAAAAAAAIAAAABAAAAEwAAAAIAAAACAAAAAAAAAAUAAAAKAAAAAAAAAAIAAAACAAAAAwAAABAAAAAAAAAAAAAAAAAAAAAAAAAAEQAAAAIAAAAAAAAAAgAAAAEAAAAPAAAAAgAAAAIAAAAAAAAABQAAAAsAAAAAAAAAAgAAAAIAAAADAAAAEQAAAAAAAAAAAAAAAAAAAAAAAAASAAAAAgAAAAAAAAACAAAAAQAAABAAAAACAAAAAgAAAAAAAAAFAAAADAAAAAAAAAACAAAAAgAAAAMAAAASAAAAAAAAAAAAAAAAAAAAAAAAABMAAAACAAAAAAAAAAIAAAABAAAAEQAAAAIAAAACAAAAAAAAAAUAAAANAAAAAAAAAAIAAAACAAAAAwAAABMAAAAAAAAAAAAAAAAAAAAAAAAADwAAAAIAAAAAAAAAAgAAAAEAAAASAAAAAgAAAAIAAAAAAAAABQAAAA4AAAAAAAAAAgAAAAIAAAADAAAAAgAAAAEAAAAAAAAAAQAAAAIAAAAAAAAAAAAAAAIAAAABAAAAAAAAAAEAAAACAAAAAQAAAAAAAAACAAAAAAAAAAUAAAAEAAAAAAAAAAEAAAAFAAAAAAAAAAAAAAAFAAAABAAAAAAAAAABAAAABQAAAAQAAAAAAAAABQAAAAAAAAACAAAAAQAAAAAAAAABAAAAAgAAAAAAAAAAAAAAAgAAAAEAAAAAAAAAAQAAAAIAAAABAAAAAAAAAAIAAAACAAAAAAAAAAEAAAAAAAAAAAAAAAUAAAAEAAAAAAAAAAEAAAAFAAAAAAAAAAAAAAAFAAAABAAAAAAAAAABAAAABQAAAAQAAAAAAAAABQAAAAUAAAAAAAAAAQAAAAAAAAAAAAAAOgehWlKfUEEz1zLi+JsiQa2og3wcMfVAWCbHorc0yEDi+Yn/Y6mbQJ11/mfsnG9At6bnG4UQQkBvMCQWKqUUQJVmwwswmOc/3hVgVBL3uj//qqOEOdGOPw/WDN4gnGE/H3ANkCUgND+AA8btKgAHPwTXBqJVSdo+XfRQAqsKrj4fc+zLYbSPQklEmCZHv2FCUP+uDso1NEKYtPhwphUHQptxnyFXYdpB7CddZAMmrkGAt1AxSTqBQUibBVdTsFNBSuX3MV+AJkFocv82SLf5QAqmgj7AY81A23VDSEnLoEDGEJVSeDFzQDYrqvBk70VA8U157pcRGUBWfEF+ZKbsP7KBdLHZTpFAqKYk69AqekDbeGY41MdjQD8AZzHK501A1vcrrjubNkD5LnquvBYhQCbiRRD71QlAqt72EbOH8z8Eu+jL1YbdP4uaox/xUcY/abedg1XfsD+BsUdzJ4KZP5wE9YFySIM/rW1kAKMpbT+rZFthVRhWPy4PKlXIs0A/qMZLlwDnMEHByqEF0I0ZQQYSFD8lUQNBPpY+dFs07UAH8BZImBPWQN9RY0I0sMBA2T7kLfc6qUByFYvfhBKTQMq+0Mis1XxA0XQbeQXMZUBJJ5aEGXpQQP7/SY0a6ThAaMD92b/UIkAs8s8yqXoMQNIegOvCk/U/aOi7NZJP4D8AAAAA/////wAAAAAAAAAAAAAAAAAAAAAAAAAA/////////////////////////////////////wAAAAD/////AAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAA/////wAAAAAAAAAAAQAAAAEAAAAAAAAAAAAAAP////8AAAAABQAAAAAAAAAAAAAAAAAAAAAAAAD/////BQAAAAUAAAAAAAAAAAAAAAAAAAAAAAAA/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAP////////////////////////////////////8AAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAD/////////////////////////////////////AAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAABQAAAAEAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA/////////////////////////////////////wAAAAABAAAAAQAAAAEAAAABAAAAAQAAAAEAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAEAAAABAAAAAQAAAAAAAAABAAAAAAAAAAUAAAABAAAAAQAAAAAAAAAAAAAAAQAAAAEAAAAAAAAAAQAAAAEAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQEAAAAAAAEAAQAAAQEAAAAAAAEAAAABAAAAAQABAAAAAAAAAAAAAAAAAAAAAAcAAAAHAAAAAQAAAAIAAAAEAAAAAwAAAAAAAAAAAAAABwAAAAMAAAABAAAAAgAAAAUAAAAEAAAAAAAAAAAAAAAEAAAABAAAAAAAAAACAAAAAQAAAAMAAAAOAAAABgAAAAsAAAACAAAABwAAAAEAAAAYAAAABQAAAAoAAAABAAAABgAAAAAAAAAmAAAABwAAAAwAAAADAAAACAAAAAIAAAAxAAAACQAAAA4AAAAAAAAABQAAAAQAAAA6AAAACAAAAA0AAAAEAAAACQAAAAMAAAA/AAAACwAAAAYAAAAPAAAACgAAABAAAABIAAAADAAAAAcAAAAQAAAACwAAABEAAABTAAAACgAAAAUAAAATAAAADgAAAA8AAABhAAAADQAAAAgAAAARAAAADAAAABIAAABrAAAADgAAAAkAAAASAAAADQAAABMAAAB1AAAADwAAABMAAAARAAAAEgAAABAAAAAGAAAAAgAAAAMAAAAFAAAABAAAAAAAAAAAAAAAAAAAAAYAAAACAAAAAwAAAAEAAAAFAAAABAAAAAAAAAAAAAAABwAAAAUAAAADAAAABAAAAAEAAAAAAAAAAgAAAAAAAAACAAAAAwAAAAEAAAAFAAAABAAAAAYAAAAAAAAAAAAAAGFsZ29zLmMAaDNOZWlnaGJvclJvdGF0aW9ucwBjb29yZGlqay5jAF91cEFwN0NoZWNrZWQAX3VwQXA3ckNoZWNrZWQAZGlyZWN0ZWRFZGdlLmMAZGlyZWN0ZWRFZGdlVG9Cb3VuZGFyeQBhZGphY2VudEZhY2VEaXJbdG1wRmlqay5mYWNlXVtmaWprLmZhY2VdID09IEtJAGZhY2VpamsuYwBfZmFjZUlqa1BlbnRUb0NlbGxCb3VuZGFyeQBhZGphY2VudEZhY2VEaXJbY2VudGVySUpLLmZhY2VdW2ZhY2UyXSA9PSBLSQBfZmFjZUlqa1RvQ2VsbEJvdW5kYXJ5AGgzSW5kZXguYwBjb21wYWN0Q2VsbHMAbGF0TG5nVG9DZWxsAGNlbGxUb0NoaWxkUG9zAHZhbGlkYXRlQ2hpbGRQb3MAbGF0TG5nLmMAY2VsbEFyZWFSYWRzMgBwb2x5Z29uLT5uZXh0ID09IE5VTEwAbGlua2VkR2VvLmMAYWRkTmV3TGlua2VkUG9seWdvbgBuZXh0ICE9IE5VTEwAbG9vcCAhPSBOVUxMAGFkZE5ld0xpbmtlZExvb3AAcG9seWdvbi0+Zmlyc3QgPT0gTlVMTABhZGRMaW5rZWRMb29wAGNvb3JkICE9IE5VTEwAYWRkTGlua2VkQ29vcmQAbG9vcC0+Zmlyc3QgPT0gTlVMTABpbm5lckxvb3BzICE9IE5VTEwAbm9ybWFsaXplTXVsdGlQb2x5Z29uAGJib3hlcyAhPSBOVUxMAGNhbmRpZGF0ZXMgIT0gTlVMTABmaW5kUG9seWdvbkZvckhvbGUAY2FuZGlkYXRlQkJveGVzICE9IE5VTEwAcmV2RGlyICE9IElOVkFMSURfRElHSVQAbG9jYWxpai5jAGNlbGxUb0xvY2FsSWprAGJhc2VDZWxsICE9IG9yaWdpbkJhc2VDZWxsACEob3JpZ2luT25QZW50ICYmIGluZGV4T25QZW50KQBiYXNlQ2VsbCA9PSBvcmlnaW5CYXNlQ2VsbABiYXNlQ2VsbCAhPSBJTlZBTElEX0JBU0VfQ0VMTABsb2NhbElqa1RvQ2VsbAAhX2lzQmFzZUNlbGxQZW50YWdvbihiYXNlQ2VsbCkAYmFzZUNlbGxSb3RhdGlvbnMgPj0gMABncmlkUGF0aENlbGxzADAAdmVydGV4LmMAY2VsbFRvVmVydGV4AGdyYXBoLT5idWNrZXRzICE9IE5VTEwAdmVydGV4R3JhcGguYwBpbml0VmVydGV4R3JhcGgAbm9kZSAhPSBOVUxMAGFkZFZlcnRleE5vZGU=";var pl=24144;function Ku(te){return te}function eu(te){var me=/\b__Z[\w\d_]+/g;return te.replace(me,function(He){var nt=He;return He===nt?He:nt+" ["+He+"]"})}function Qo(){var te=new Error;if(!te.stack){try{throw new Error(0)}catch(me){te=me}if(!te.stack)return"(no stack trace available)"}return te.stack.toString()}function ps(){var te=Qo();return Wr.extraStackTrace&&(te+=` +`+Wr.extraStackTrace()),eu(te)}function xl(te,me,He,nt){ee("Assertion failed: "+ya(te)+", at: "+[me?ya(me):"unknown filename",He,nt?ya(nt):"unknown function"])}function Yl(){return ns.length}function ul(te,me,He){Vo.set(Vo.subarray(me,me+He),te)}function Ef(te){return Wr.___errno_location&&(Hu[Wr.___errno_location()>>2]=te),te}function sf(te){ee("OOM")}function Hf(te){try{var me=new ArrayBuffer(te);return me.byteLength!=te?void 0:(new Int8Array(me).set(ns),ff(me),Vi(me),1)}catch(He){}}function Ul(te){var me=Yl(),He=16777216,nt=2147483648-He;if(te>nt)return!1;for(var w=16777216,Wt=Math.max(me,w);Wt>4,w=(x&15)<<4|S>>2,Wt=(S&3)<<6|U,He=He+String.fromCharCode(nt),S!==64&&(He=He+String.fromCharCode(w)),U!==64&&(He=He+String.fromCharCode(Wt));while(pe13780509?(P=W0(15,P)|0,P|0):(F=((D|0)<0)<<31>>31,fe=ao(D|0,F|0,3,0)|0,q=xr()|0,F=Gs(D|0,F|0,1,0)|0,F=ao(fe|0,q|0,F|0,xr()|0)|0,F=Gs(F|0,xr()|0,1,0)|0,D=xr()|0,w[P>>2]=F,w[P+4>>2]=D,P=0,P|0)}function Gl(D,P,F,q){return D=D|0,P=P|0,F=F|0,q=q|0,Oc(D,P,F,q,0)|0}function Oc(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0,Ze=0,Ot=0,rr=0;if(Ot=qr,qr=qr+16|0,Ie=Ot,!(bc(D,P,F,q,fe)|0))return q=0,qr=Ot,q|0;do if((F|0)>=0){if((F|0)>13780509){if(Ae=W0(15,Ie)|0,Ae|0)break;Ze=Ie,Ie=w[Ze>>2]|0,Ze=w[Ze+4>>2]|0}else Ae=((F|0)<0)<<31>>31,rr=ao(F|0,Ae|0,3,0)|0,Ze=xr()|0,Ae=Gs(F|0,Ae|0,1,0)|0,Ae=ao(rr|0,Ze|0,Ae|0,xr()|0)|0,Ae=Gs(Ae|0,xr()|0,1,0)|0,Ze=xr()|0,w[Ie>>2]=Ae,w[Ie+4>>2]=Ze,Ie=Ae;if(ji(q|0,0,Ie<<3|0)|0,fe|0){ji(fe|0,0,Ie<<2|0)|0,Ae=wu(D,P,F,q,fe,Ie,Ze,0)|0;break}Ae=hl(Ie,4)|0,Ae?(rr=wu(D,P,F,q,Ae,Ie,Ze,0)|0,Pu(Ae),Ae=rr):Ae=13}else Ae=2;while(0);return rr=Ae,qr=Ot,rr|0}function bc(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0;if(no=qr,qr=qr+16|0,ui=no,ci=no+8|0,Jn=ui,w[Jn>>2]=D,w[Jn+4>>2]=P,(F|0)<0)return ci=2,qr=no,ci|0;if(Ae=q,w[Ae>>2]=D,w[Ae+4>>2]=P,Ae=(fe|0)!=0,Ae&&(w[fe>>2]=0),gh(D,P)|0)return ci=9,qr=no,ci|0;w[ci>>2]=0;e:do if((F|0)>=1)if(Ae)for(mr=1,rr=0,pn=0,Jn=1,Ae=D;;){if(!(rr|pn)){if(Ae=rf(Ae,P,4,ci,ui)|0,Ae|0)break e;if(P=ui,Ae=w[P>>2]|0,P=w[P+4>>2]|0,gh(Ae,P)|0){Ae=9;break e}}if(Ae=rf(Ae,P,w[22384+(pn<<2)>>2]|0,ci,ui)|0,Ae|0)break e;if(P=ui,Ae=w[P>>2]|0,P=w[P+4>>2]|0,D=q+(mr<<3)|0,w[D>>2]=Ae,w[D+4>>2]=P,w[fe+(mr<<2)>>2]=Jn,D=rr+1|0,Ie=(D|0)==(Jn|0),Ze=pn+1|0,Ot=(Ze|0)==6,gh(Ae,P)|0){Ae=9;break e}if(Jn=Jn+(Ot&Ie&1)|0,(Jn|0)>(F|0)){Ae=0;break}else mr=mr+1|0,rr=Ie?0:D,pn=Ie?Ot?0:Ze:pn}else for(mr=1,rr=0,pn=0,Jn=1,Ae=D;;){if(!(rr|pn)){if(Ae=rf(Ae,P,4,ci,ui)|0,Ae|0)break e;if(P=ui,Ae=w[P>>2]|0,P=w[P+4>>2]|0,gh(Ae,P)|0){Ae=9;break e}}if(Ae=rf(Ae,P,w[22384+(pn<<2)>>2]|0,ci,ui)|0,Ae|0)break e;if(P=ui,Ae=w[P>>2]|0,P=w[P+4>>2]|0,D=q+(mr<<3)|0,w[D>>2]=Ae,w[D+4>>2]=P,D=rr+1|0,Ie=(D|0)==(Jn|0),Ze=pn+1|0,Ot=(Ze|0)==6,gh(Ae,P)|0){Ae=9;break e}if(Jn=Jn+(Ot&Ie&1)|0,(Jn|0)>(F|0)){Ae=0;break}else mr=mr+1|0,rr=Ie?0:D,pn=Ie?Ot?0:Ze:pn}else Ae=0;while(0);return ci=Ae,qr=no,ci|0}function wu(D,P,F,q,fe,Ae,Ie,Ze){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0,Ae=Ae|0,Ie=Ie|0,Ze=Ze|0;var Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0;if(no=qr,qr=qr+16|0,ui=no+8|0,ci=no,Ot=Kc(D|0,P|0,Ae|0,Ie|0)|0,mr=xr()|0,pn=q+(Ot<<3)|0,Wa=pn,ha=w[Wa>>2]|0,Wa=w[Wa+4>>2]|0,rr=(ha|0)==(D|0)&(Wa|0)==(P|0),!((ha|0)==0&(Wa|0)==0|rr))do Ot=Gs(Ot|0,mr|0,1,0)|0,Ot=Iu(Ot|0,xr()|0,Ae|0,Ie|0)|0,mr=xr()|0,pn=q+(Ot<<3)|0,ha=pn,Wa=w[ha>>2]|0,ha=w[ha+4>>2]|0,rr=(Wa|0)==(D|0)&(ha|0)==(P|0);while(!((Wa|0)==0&(ha|0)==0|rr));if(Ot=fe+(Ot<<2)|0,rr&&(w[Ot>>2]|0)<=(Ze|0)||(ha=pn,w[ha>>2]=D,w[ha+4>>2]=P,w[Ot>>2]=Ze,(Ze|0)>=(F|0)))return ha=0,qr=no,ha|0;switch(rr=Ze+1|0,w[ui>>2]=0,Ot=rf(D,P,2,ui,ci)|0,Ot|0){case 9:{Jn=9;break}case 0:{Ot=ci,Ot=wu(w[Ot>>2]|0,w[Ot+4>>2]|0,F,q,fe,Ae,Ie,rr)|0,Ot||(Jn=9);break}default:}e:do if((Jn|0)==9){switch(w[ui>>2]=0,Ot=rf(D,P,3,ui,ci)|0,Ot|0){case 9:break;case 0:{if(Ot=ci,Ot=wu(w[Ot>>2]|0,w[Ot+4>>2]|0,F,q,fe,Ae,Ie,rr)|0,Ot|0)break e;break}default:break e}switch(w[ui>>2]=0,Ot=rf(D,P,1,ui,ci)|0,Ot|0){case 9:break;case 0:{if(Ot=ci,Ot=wu(w[Ot>>2]|0,w[Ot+4>>2]|0,F,q,fe,Ae,Ie,rr)|0,Ot|0)break e;break}default:break e}switch(w[ui>>2]=0,Ot=rf(D,P,5,ui,ci)|0,Ot|0){case 9:break;case 0:{if(Ot=ci,Ot=wu(w[Ot>>2]|0,w[Ot+4>>2]|0,F,q,fe,Ae,Ie,rr)|0,Ot|0)break e;break}default:break e}switch(w[ui>>2]=0,Ot=rf(D,P,4,ui,ci)|0,Ot|0){case 9:break;case 0:{if(Ot=ci,Ot=wu(w[Ot>>2]|0,w[Ot+4>>2]|0,F,q,fe,Ae,Ie,rr)|0,Ot|0)break e;break}default:break e}switch(w[ui>>2]=0,Ot=rf(D,P,6,ui,ci)|0,Ot|0){case 9:break;case 0:{if(Ot=ci,Ot=wu(w[Ot>>2]|0,w[Ot+4>>2]|0,F,q,fe,Ae,Ie,rr)|0,Ot|0)break e;break}default:break e}return ha=0,qr=no,ha|0}while(0);return ha=Ot,qr=no,ha|0}function rf(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0;if(F>>>0>6)return fe=1,fe|0;if(pn=(w[q>>2]|0)%6|0,w[q>>2]=pn,(pn|0)>0){Ae=0;do F=r0(F)|0,Ae=Ae+1|0;while((Ae|0)<(w[q>>2]|0))}if(pn=Rr(D|0,P|0,45)|0,xr()|0,mr=pn&127,mr>>>0>121)return fe=5,fe|0;Ot=Ep(D,P)|0,Ae=Rr(D|0,P|0,52)|0,xr()|0,Ae=Ae&15;e:do if(!Ae)rr=8;else{for(;;){if(Ie=(15-Ae|0)*3|0,Ze=Rr(D|0,P|0,Ie|0)|0,xr()|0,Ze=Ze&7,(Ze|0)==7){P=5;break}if(ci=(jd(Ae)|0)==0,Ae=Ae+-1|0,Jn=sr(7,0,Ie|0)|0,P=P&~(xr()|0),ui=sr(w[(ci?432:16)+(Ze*28|0)+(F<<2)>>2]|0,0,Ie|0)|0,Ie=xr()|0,F=w[(ci?640:224)+(Ze*28|0)+(F<<2)>>2]|0,D=ui|D&~Jn,P=Ie|P,!F){F=0;break e}if(!Ae){rr=8;break e}}return P|0}while(0);(rr|0)==8&&(ci=w[848+(mr*28|0)+(F<<2)>>2]|0,ui=sr(ci|0,0,45)|0,D=ui|D,P=xr()|0|P&-1040385,F=w[4272+(mr*28|0)+(F<<2)>>2]|0,(ci&127|0)==127&&(ci=sr(w[848+(mr*28|0)+20>>2]|0,0,45)|0,P=xr()|0|P&-1040385,F=w[4272+(mr*28|0)+20>>2]|0,D=Pp(ci|D,P)|0,P=xr()|0,w[q>>2]=(w[q>>2]|0)+1)),Ze=Rr(D|0,P|0,45)|0,xr()|0,Ze=Ze&127;e:do if(Ff(Ze)|0){t:do if((Ep(D,P)|0)==1){if((mr|0)!=(Ze|0))if(qf(Ze,w[7696+(mr*28|0)>>2]|0)|0){D=Zp(D,P)|0,Ie=1,P=xr()|0;break}else Ni(23313,22416,436,22424);switch(Ot|0){case 3:{D=Pp(D,P)|0,P=xr()|0,w[q>>2]=(w[q>>2]|0)+1,Ie=0;break t}case 5:{D=Zp(D,P)|0,P=xr()|0,w[q>>2]=(w[q>>2]|0)+5,Ie=0;break t}case 0:return ci=9,ci|0;default:return ci=1,ci|0}}else Ie=0;while(0);if((F|0)>0){Ae=0;do D=D0(D,P)|0,P=xr()|0,Ae=Ae+1|0;while((Ae|0)!=(F|0))}if((mr|0)!=(Ze|0)){if(!(kd(Ze)|0)){if((Ie|0)!=0|(Ep(D,P)|0)!=5)break;w[q>>2]=(w[q>>2]|0)+1;break}switch(pn&127){case 8:case 118:break e;default:}(Ep(D,P)|0)!=3&&(w[q>>2]=(w[q>>2]|0)+1)}}else if((F|0)>0){Ae=0;do D=Pp(D,P)|0,P=xr()|0,Ae=Ae+1|0;while((Ae|0)!=(F|0))}while(0);return w[q>>2]=((w[q>>2]|0)+F|0)%6|0,ci=fe,w[ci>>2]=D,w[ci+4>>2]=P,ci=0,ci|0}function xf(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0;for(Ze=qr,qr=qr+16|0,Ae=Ze,Ie=Ze+8|0,fe=(gh(D,P)|0)==0,fe=fe?1:2;;){if(w[Ie>>2]=0,rr=(rf(D,P,fe,Ie,Ae)|0)==0,Ot=Ae,rr&((w[Ot>>2]|0)==(F|0)?(w[Ot+4>>2]|0)==(q|0):0)){D=4;break}if(fe=fe+1|0,fe>>>0>=7){fe=7,D=4;break}}return(D|0)==4?(qr=Ze,fe|0):0}function Kh(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0;if(ci=qr,qr=qr+16|0,Jn=ci,ui=ci+8|0,pn=Jn,w[pn>>2]=D,w[pn+4>>2]=P,!F)return ui=q,w[ui>>2]=D,w[ui+4>>2]=P,ui=0,qr=ci,ui|0;w[ui>>2]=0;e:do if(gh(D,P)|0)D=9;else{if(Ae=(F|0)>0,Ae){fe=0,pn=D;do{if(D=rf(pn,P,4,ui,Jn)|0,D|0)break e;if(P=Jn,pn=w[P>>2]|0,P=w[P+4>>2]|0,fe=fe+1|0,gh(pn,P)|0){D=9;break e}}while((fe|0)<(F|0));if(mr=q,w[mr>>2]=pn,w[mr+4>>2]=P,mr=F+-1|0,Ae){rr=0,D=1;do{if(fe=22384+(rr<<2)|0,(rr|0)==5)for(Ie=w[fe>>2]|0,Ae=0,fe=D;;){if(D=Jn,D=rf(w[D>>2]|0,w[D+4>>2]|0,Ie,ui,Jn)|0,D|0)break e;if((Ae|0)!=(mr|0))if(Ot=Jn,Ze=w[Ot>>2]|0,Ot=w[Ot+4>>2]|0,D=q+(fe<<3)|0,w[D>>2]=Ze,w[D+4>>2]=Ot,!(gh(Ze,Ot)|0))D=fe+1|0;else{D=9;break e}else D=fe;if(Ae=Ae+1|0,(Ae|0)>=(F|0))break;fe=D}else for(Ie=Jn,Ot=w[fe>>2]|0,Ze=0,fe=D,Ae=w[Ie>>2]|0,Ie=w[Ie+4>>2]|0;;){if(D=rf(Ae,Ie,Ot,ui,Jn)|0,D|0)break e;if(Ie=Jn,Ae=w[Ie>>2]|0,Ie=w[Ie+4>>2]|0,D=q+(fe<<3)|0,w[D>>2]=Ae,w[D+4>>2]=Ie,D=fe+1|0,gh(Ae,Ie)|0){D=9;break e}if(Ze=Ze+1|0,(Ze|0)>=(F|0))break;fe=D}rr=rr+1|0}while(rr>>>0<6);D=Jn,Ie=pn,fe=w[D>>2]|0,Ae=P,D=w[D+4>>2]|0}else Ie=pn,fe=pn,Ae=P,D=P}else Ie=q,w[Ie>>2]=D,w[Ie+4>>2]=P,Ie=D,fe=D,Ae=P,D=P;D=(Ie|0)==(fe|0)&(Ae|0)==(D|0)?0:9}while(0);return ui=D,qr=ci,ui|0}function Zf(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0;if(Ze=qr,qr=qr+48|0,fe=Ze+16|0,Ae=Ze+8|0,Ie=Ze,F|0)return Ie=15,qr=Ze,Ie|0;if(rr=D,Ot=w[rr+4>>2]|0,F=Ae,w[F>>2]=w[rr>>2],w[F+4>>2]=Ot,zs(Ae,fe),P=od(fe,P,Ie)|0,!P){if(F=w[Ae>>2]|0,Ae=w[D+8>>2]|0,(Ae|0)>0){fe=w[D+12>>2]|0,P=0;do F=(w[fe+(P<<3)>>2]|0)+F|0,P=P+1|0;while((P|0)<(Ae|0))}P=Ie,fe=w[P>>2]|0,P=w[P+4>>2]|0,Ae=((F|0)<0)<<31>>31,(P|0)<(Ae|0)|(P|0)==(Ae|0)&fe>>>0>>0?(P=Ie,w[P>>2]=F,w[P+4>>2]=Ae,P=Ae):F=fe,Ot=Gs(F|0,P|0,12,0)|0,rr=xr()|0,P=Ie,w[P>>2]=Ot,w[P+4>>2]=rr,P=q,w[P>>2]=Ot,w[P+4>>2]=rr,P=0}return rr=P,qr=Ze,rr|0}function sc(D,P,F,q,fe,Ae,Ie){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0,Ae=Ae|0,Ie=Ie|0;var Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0,Go=0,Wo=0,To=0,El=0,gl=0,du=0,Qu=0,_h=0,Th=0,vh=0,$f=0,Nl=0,vc=0,Hh=0,Af=0,Fh=0,Mf=0,lm=0;if(Hh=qr,qr=qr+64|0,vh=Hh+48|0,$f=Hh+32|0,Nl=Hh+24|0,El=Hh+8|0,gl=Hh,Ot=w[D>>2]|0,(Ot|0)<=0)return vc=0,qr=Hh,vc|0;for(du=D+4|0,Qu=vh+8|0,_h=$f+8|0,Th=El+8|0,Ze=0,Wo=0;;){rr=w[du>>2]|0,Go=rr+(Wo<<4)|0,w[vh>>2]=w[Go>>2],w[vh+4>>2]=w[Go+4>>2],w[vh+8>>2]=w[Go+8>>2],w[vh+12>>2]=w[Go+12>>2],(Wo|0)==(Ot+-1|0)?(w[$f>>2]=w[rr>>2],w[$f+4>>2]=w[rr+4>>2],w[$f+8>>2]=w[rr+8>>2],w[$f+12>>2]=w[rr+12>>2]):(Go=rr+(Wo+1<<4)|0,w[$f>>2]=w[Go>>2],w[$f+4>>2]=w[Go+4>>2],w[$f+8>>2]=w[Go+8>>2],w[$f+12>>2]=w[Go+12>>2]),Ot=lf(vh,$f,q,Nl)|0;e:do if(Ot)rr=0,Ze=Ot;else if(rr=Nl,Ot=w[rr>>2]|0,rr=w[rr+4>>2]|0,(rr|0)>0|(rr|0)==0&Ot>>>0>0){ha=0,Go=0;t:for(;;){if(lm=+x[vh>>3],Wa=of(Ot|0,rr|0,ha|0,Go|0)|0,Mf=+(Wa>>>0)+4294967296*+(xr()|0),Af=+(Ot>>>0)+4294967296*+(rr|0),Fh=+(ha>>>0)+4294967296*+(Go|0),x[El>>3]=lm*Mf/Af+ +x[$f>>3]*Fh/Af,x[Th>>3]=+x[Qu>>3]*Mf/Af+ +x[_h>>3]*Fh/Af,Ot=qp(El,q,gl)|0,Ot|0){Ze=Ot;break}Wa=gl,no=w[Wa>>2]|0,Wa=w[Wa+4>>2]|0,Jn=Kc(no|0,Wa|0,P|0,F|0)|0,mr=xr()|0,Ot=Ie+(Jn<<3)|0,pn=Ot,rr=w[pn>>2]|0,pn=w[pn+4>>2]|0;r:do if((rr|0)==0&(pn|0)==0)To=Ot,vc=16;else for(ui=0,ci=0;;){if((ui|0)>(F|0)|(ui|0)==(F|0)&ci>>>0>P>>>0){Ze=1;break t}if((rr|0)==(no|0)&(pn|0)==(Wa|0))break r;if(Ot=Gs(Jn|0,mr|0,1,0)|0,Jn=Iu(Ot|0,xr()|0,P|0,F|0)|0,mr=xr()|0,ci=Gs(ci|0,ui|0,1,0)|0,ui=xr()|0,Ot=Ie+(Jn<<3)|0,pn=Ot,rr=w[pn>>2]|0,pn=w[pn+4>>2]|0,(rr|0)==0&(pn|0)==0){To=Ot,vc=16;break}}while(0);if((vc|0)==16&&(vc=0,!((no|0)==0&(Wa|0)==0))&&(ci=To,w[ci>>2]=no,w[ci+4>>2]=Wa,ci=Ae+(w[fe>>2]<<3)|0,w[ci>>2]=no,w[ci+4>>2]=Wa,ci=fe,ci=Gs(w[ci>>2]|0,w[ci+4>>2]|0,1,0)|0,no=xr()|0,Wa=fe,w[Wa>>2]=ci,w[Wa+4>>2]=no),ha=Gs(ha|0,Go|0,1,0)|0,Go=xr()|0,rr=Nl,Ot=w[rr>>2]|0,rr=w[rr+4>>2]|0,!((rr|0)>(Go|0)|(rr|0)==(Go|0)&Ot>>>0>ha>>>0)){rr=1;break e}}rr=0}else rr=1;while(0);if(Wo=Wo+1|0,!rr){vc=21;break}if(Ot=w[D>>2]|0,(Wo|0)>=(Ot|0)){Ze=0,vc=21;break}}return(vc|0)==21?(qr=Hh,Ze|0):0}function Kf(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0,Go=0,Wo=0,To=0,El=0,gl=0,du=0,Qu=0,_h=0,Th=0,vh=0,$f=0,Nl=0,vc=0,Hh=0,Af=0,Fh=0,Mf=0;if(Mf=qr,qr=qr+112|0,vc=Mf+80|0,Ot=Mf+72|0,Hh=Mf,Af=Mf+56|0,F|0)return Fh=15,qr=Mf,Fh|0;if(rr=D+8|0,Fh=Qf((w[rr>>2]<<5)+32|0)|0,!Fh)return Fh=13,qr=Mf,Fh|0;if(Ru(D,Fh),$f=D,Nl=w[$f+4>>2]|0,F=Ot,w[F>>2]=w[$f>>2],w[F+4>>2]=Nl,zs(Ot,vc),F=od(vc,P,Hh)|0,F)$f=0,Nl=0;else{if(F=w[Ot>>2]|0,Ae=w[rr>>2]|0,(Ae|0)>0){Ie=w[D+12>>2]|0,fe=0;do F=(w[Ie+(fe<<3)>>2]|0)+F|0,fe=fe+1|0;while((fe|0)!=(Ae|0));fe=F}else fe=F;F=Hh,Ae=w[F>>2]|0,F=w[F+4>>2]|0,Ie=((fe|0)<0)<<31>>31,(F|0)<(Ie|0)|(F|0)==(Ie|0)&Ae>>>0>>0?(F=Hh,w[F>>2]=fe,w[F+4>>2]=Ie,F=Ie):fe=Ae,$f=Gs(fe|0,F|0,12,0)|0,Nl=xr()|0,F=Hh,w[F>>2]=$f,w[F+4>>2]=Nl,F=0}if(F|0)return Pu(Fh),Fh=F,qr=Mf,Fh|0;if(fe=hl($f,8)|0,!fe)return Pu(Fh),Fh=13,qr=Mf,Fh|0;if(Ze=hl($f,8)|0,!Ze)return Pu(Fh),Pu(fe),Fh=13,qr=Mf,Fh|0;Th=vc,w[Th>>2]=0,w[Th+4>>2]=0,Th=D,vh=w[Th+4>>2]|0,F=Ot,w[F>>2]=w[Th>>2],w[F+4>>2]=vh,F=sc(Ot,$f,Nl,P,vc,fe,Ze)|0;e:do if(F)Pu(fe),Pu(Ze),Pu(Fh);else{t:do if((w[rr>>2]|0)>0){for(Ie=D+12|0,Ae=0;F=sc((w[Ie>>2]|0)+(Ae<<3)|0,$f,Nl,P,vc,fe,Ze)|0,Ae=Ae+1|0,!(F|0);)if((Ae|0)>=(w[rr>>2]|0))break t;Pu(fe),Pu(Ze),Pu(Fh);break e}while(0);(Nl|0)>0|(Nl|0)==0&$f>>>0>0&&ji(Ze|0,0,$f<<3|0)|0,vh=vc,Th=w[vh+4>>2]|0;t:do if((Th|0)>0|(Th|0)==0&(w[vh>>2]|0)>>>0>0){du=fe,Qu=Ze,_h=fe,Th=Ze,vh=fe,F=fe,To=fe,El=Ze,gl=Ze,fe=Ze;r:for(;;){for(Wa=0,ha=0,Go=0,Wo=0,Ae=0,Ie=0;;){Ze=Hh,Ot=Ze+56|0;do w[Ze>>2]=0,Ze=Ze+4|0;while((Ze|0)<(Ot|0));if(P=du+(Wa<<3)|0,rr=w[P>>2]|0,P=w[P+4>>2]|0,bc(rr,P,1,Hh,0)|0){Ze=Hh,Ot=Ze+56|0;do w[Ze>>2]=0,Ze=Ze+4|0;while((Ze|0)<(Ot|0));Ze=hl(7,4)|0,Ze|0&&(wu(rr,P,1,Hh,Ze,7,0,0)|0,Pu(Ze))}for(no=0;;){ci=Hh+(no<<3)|0,ui=w[ci>>2]|0,ci=w[ci+4>>2]|0;n:do if((ui|0)==0&(ci|0)==0)Ze=Ae,Ot=Ie;else{if(mr=Kc(ui|0,ci|0,$f|0,Nl|0)|0,rr=xr()|0,Ze=q+(mr<<3)|0,P=Ze,Ot=w[P>>2]|0,P=w[P+4>>2]|0,!((Ot|0)==0&(P|0)==0)){pn=0,Jn=0;do{if((pn|0)>(Nl|0)|(pn|0)==(Nl|0)&Jn>>>0>$f>>>0)break r;if((Ot|0)==(ui|0)&(P|0)==(ci|0)){Ze=Ae,Ot=Ie;break n}Ze=Gs(mr|0,rr|0,1,0)|0,mr=Iu(Ze|0,xr()|0,$f|0,Nl|0)|0,rr=xr()|0,Jn=Gs(Jn|0,pn|0,1,0)|0,pn=xr()|0,Ze=q+(mr<<3)|0,P=Ze,Ot=w[P>>2]|0,P=w[P+4>>2]|0}while(!((Ot|0)==0&(P|0)==0))}(ui|0)==0&(ci|0)==0?(Ze=Ae,Ot=Ie):(i0(ui,ci,Af)|0,ls(D,Fh,Af)|0&&(Jn=Gs(Ae|0,Ie|0,1,0)|0,Ie=xr()|0,pn=Ze,w[pn>>2]=ui,w[pn+4>>2]=ci,Ae=Qu+(Ae<<3)|0,w[Ae>>2]=ui,w[Ae+4>>2]=ci,Ae=Jn),Ze=Ae,Ot=Ie)}while(0);if(no=no+1|0,no>>>0>=7)break;Ae=Ze,Ie=Ot}if(Wa=Gs(Wa|0,ha|0,1,0)|0,ha=xr()|0,Go=Gs(Go|0,Wo|0,1,0)|0,Wo=xr()|0,Ie=vc,Ae=w[Ie>>2]|0,Ie=w[Ie+4>>2]|0,(Wo|0)<(Ie|0)|(Wo|0)==(Ie|0)&Go>>>0>>0)Ae=Ze,Ie=Ot;else break}if((Ie|0)>0|(Ie|0)==0&Ae>>>0>0){Ae=0,Ie=0;do Wo=du+(Ae<<3)|0,w[Wo>>2]=0,w[Wo+4>>2]=0,Ae=Gs(Ae|0,Ie|0,1,0)|0,Ie=xr()|0,Wo=vc,Go=w[Wo+4>>2]|0;while((Ie|0)<(Go|0)|((Ie|0)==(Go|0)?Ae>>>0<(w[Wo>>2]|0)>>>0:0))}if(Wo=vc,w[Wo>>2]=Ze,w[Wo+4>>2]=Ot,(Ot|0)>0|(Ot|0)==0&Ze>>>0>0)no=fe,Wa=gl,ha=vh,Go=El,Wo=Qu,fe=To,gl=F,El=_h,To=no,F=Wa,vh=Th,Th=ha,_h=Go,Qu=du,du=Wo;else break t}Pu(_h),Pu(Th),Pu(Fh),F=1;break e}else F=Ze;while(0);Pu(Fh),Pu(fe),Pu(F),F=0}while(0);return Fh=F,qr=Mf,Fh|0}function nh(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0;if(mr=qr,qr=qr+176|0,Ot=mr,(P|0)<1)return Cf(F,0,0),rr=0,qr=mr,rr|0;for(Ze=D,Ze=Rr(w[Ze>>2]|0,w[Ze+4>>2]|0,52)|0,xr()|0,Cf(F,(P|0)>6?P:6,Ze&15),Ze=0;q=D+(Ze<<3)|0,q=f0(w[q>>2]|0,w[q+4>>2]|0,Ot)|0,!(q|0);){if(q=w[Ot>>2]|0,(q|0)>0){Ie=0;do Ae=Ot+8+(Ie<<4)|0,Ie=Ie+1|0,q=Ot+8+(((Ie|0)%(q|0)|0)<<4)|0,fe=If(F,q,Ae)|0,fe?Tf(F,fe)|0:ed(F,Ae,q)|0,q=w[Ot>>2]|0;while((Ie|0)<(q|0))}if(Ze=Ze+1|0,(Ze|0)>=(P|0)){q=0,rr=13;break}}return(rr|0)==13?(qr=mr,q|0):(yd(F),rr=q,qr=mr,rr|0)}function Rh(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0;if(Ae=qr,qr=qr+32|0,q=Ae,fe=Ae+16|0,D=nh(D,P,fe)|0,D|0)return F=D,qr=Ae,F|0;if(w[F>>2]=0,w[F+4>>2]=0,w[F+8>>2]=0,D=Ch(fe)|0,D|0)do{P=jo(F)|0;do Ta(P,D)|0,Ie=D+16|0,w[q>>2]=w[Ie>>2],w[q+4>>2]=w[Ie+4>>2],w[q+8>>2]=w[Ie+8>>2],w[q+12>>2]=w[Ie+12>>2],Tf(fe,D)|0,D=$h(fe,q)|0;while(D|0);D=Ch(fe)|0}while(D|0);return yd(fe),D=Po(F)|0,D?($o(F),Ie=D,qr=Ae,Ie|0):(Ie=0,qr=Ae,Ie|0)}function Ff(D){return D=D|0,D>>>0>121?(D=0,D|0):(D=w[7696+(D*28|0)+16>>2]|0,D|0)}function kd(D){return D=D|0,(D|0)==4|(D|0)==117|0}function Ud(D){return D=D|0,w[11120+((w[D>>2]|0)*216|0)+((w[D+4>>2]|0)*72|0)+((w[D+8>>2]|0)*24|0)+(w[D+12>>2]<<3)>>2]|0}function Qh(D){return D=D|0,w[11120+((w[D>>2]|0)*216|0)+((w[D+4>>2]|0)*72|0)+((w[D+8>>2]|0)*24|0)+(w[D+12>>2]<<3)+4>>2]|0}function jh(D,P){D=D|0,P=P|0,D=7696+(D*28|0)|0,w[P>>2]=w[D>>2],w[P+4>>2]=w[D+4>>2],w[P+8>>2]=w[D+8>>2],w[P+12>>2]=w[D+12>>2]}function xh(D,P){D=D|0,P=P|0;var F=0,q=0;if(P>>>0>20)return P=-1,P|0;do if((w[11120+(P*216|0)>>2]|0)!=(D|0))if((w[11120+(P*216|0)+8>>2]|0)!=(D|0))if((w[11120+(P*216|0)+16>>2]|0)!=(D|0))if((w[11120+(P*216|0)+24>>2]|0)!=(D|0))if((w[11120+(P*216|0)+32>>2]|0)!=(D|0))if((w[11120+(P*216|0)+40>>2]|0)!=(D|0))if((w[11120+(P*216|0)+48>>2]|0)!=(D|0))if((w[11120+(P*216|0)+56>>2]|0)!=(D|0))if((w[11120+(P*216|0)+64>>2]|0)!=(D|0))if((w[11120+(P*216|0)+72>>2]|0)!=(D|0))if((w[11120+(P*216|0)+80>>2]|0)!=(D|0))if((w[11120+(P*216|0)+88>>2]|0)!=(D|0))if((w[11120+(P*216|0)+96>>2]|0)!=(D|0))if((w[11120+(P*216|0)+104>>2]|0)!=(D|0))if((w[11120+(P*216|0)+112>>2]|0)!=(D|0))if((w[11120+(P*216|0)+120>>2]|0)!=(D|0))if((w[11120+(P*216|0)+128>>2]|0)!=(D|0))if((w[11120+(P*216|0)+136>>2]|0)==(D|0))D=2,F=1,q=2;else{if((w[11120+(P*216|0)+144>>2]|0)==(D|0)){D=0,F=2,q=0;break}if((w[11120+(P*216|0)+152>>2]|0)==(D|0)){D=0,F=2,q=1;break}if((w[11120+(P*216|0)+160>>2]|0)==(D|0)){D=0,F=2,q=2;break}if((w[11120+(P*216|0)+168>>2]|0)==(D|0)){D=1,F=2,q=0;break}if((w[11120+(P*216|0)+176>>2]|0)==(D|0)){D=1,F=2,q=1;break}if((w[11120+(P*216|0)+184>>2]|0)==(D|0)){D=1,F=2,q=2;break}if((w[11120+(P*216|0)+192>>2]|0)==(D|0)){D=2,F=2,q=0;break}if((w[11120+(P*216|0)+200>>2]|0)==(D|0)){D=2,F=2,q=1;break}if((w[11120+(P*216|0)+208>>2]|0)==(D|0)){D=2,F=2,q=2;break}else D=-1;return D|0}else D=2,F=1,q=1;else D=2,F=1,q=0;else D=1,F=1,q=2;else D=1,F=1,q=1;else D=1,F=1,q=0;else D=0,F=1,q=2;else D=0,F=1,q=1;else D=0,F=1,q=0;else D=2,F=0,q=2;else D=2,F=0,q=1;else D=2,F=0,q=0;else D=1,F=0,q=2;else D=1,F=0,q=1;else D=1,F=0,q=0;else D=0,F=0,q=2;else D=0,F=0,q=1;else D=0,F=0,q=0;while(0);return P=w[11120+(P*216|0)+(F*72|0)+(D*24|0)+(q<<3)+4>>2]|0,P|0}function qf(D,P){return D=D|0,P=P|0,(w[7696+(D*28|0)+20>>2]|0)==(P|0)?(P=1,P|0):(P=(w[7696+(D*28|0)+24>>2]|0)==(P|0),P|0)}function hd(D,P){return D=D|0,P=P|0,w[848+(D*28|0)+(P<<2)>>2]|0}function nd(D,P){return D=D|0,P=P|0,(w[848+(D*28|0)>>2]|0)==(P|0)?(P=0,P|0):(w[848+(D*28|0)+4>>2]|0)==(P|0)?(P=1,P|0):(w[848+(D*28|0)+8>>2]|0)==(P|0)?(P=2,P|0):(w[848+(D*28|0)+12>>2]|0)==(P|0)?(P=3,P|0):(w[848+(D*28|0)+16>>2]|0)==(P|0)?(P=4,P|0):(w[848+(D*28|0)+20>>2]|0)==(P|0)?(P=5,P|0):((w[848+(D*28|0)+24>>2]|0)==(P|0)?6:7)|0}function id(){return 122}function Hp(D){D=D|0;var P=0,F=0,q=0;P=0;do sr(P|0,0,45)|0,q=xr()|0|134225919,F=D+(P<<3)|0,w[F>>2]=-1,w[F+4>>2]=q,P=P+1|0;while((P|0)!=122);return 0}function mc(D){return D=D|0,+x[D+16>>3]<+x[D+24>>3]|0}function Cd(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0;return F=+x[P>>3],!(F>=+x[D+8>>3])||!(F<=+x[D>>3])?(P=0,P|0):(q=+x[D+16>>3],F=+x[D+24>>3],fe=+x[P+8>>3],P=fe>=F,D=fe<=q&1,q>2]=0,Ze=Ze+4|0;while((Ze|0)<(Ot|0));return P=Rd(P,rr)|0,P|0?(ui=P,qr=ci,ui|0):(Ot=rr,rr=w[Ot>>2]|0,Ot=w[Ot+4>>2]|0,i0(rr,Ot,mr)|0,f0(rr,Ot,pn)|0,Ie=+Sp(mr,pn+8|0),x[mr>>3]=+x[D>>3],Ot=mr+8|0,x[Ot>>3]=+x[D+16>>3],x[pn>>3]=+x[D+8>>3],rr=pn+8|0,x[rr>>3]=+x[D+24>>3],fe=+Sp(mr,pn),Wa=+x[Ot>>3]-+x[rr>>3],Ae=+Ce(+Wa),no=+x[mr>>3]-+x[pn>>3],q=+Ce(+no),!(Wa==0|no==0)&&(Wa=+ti(+Ae,+q),Wa=+tn(+(fe*fe/+_o(+(Wa/+_o(+Ae,+q)),3)/(Ie*(Ie*2.59807621135)*.8))),x[S>>3]=Wa,Jn=~~Wa>>>0,ui=+Ce(Wa)>=1?Wa>0?~~+fn(+pe(Wa/4294967296),4294967295)>>>0:~~+tn((Wa-+(~~Wa>>>0))/4294967296)>>>0:0,(w[S+4>>2]&2146435072|0)!=2146435072)?(pn=(Jn|0)==0&(ui|0)==0,P=F,w[P>>2]=pn?1:Jn,w[P+4>>2]=pn?0:ui,P=0):P=1,ui=P,qr=ci,ui|0)}function lf(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0;rr=qr,qr=qr+288|0,Ie=rr+264|0,Ze=rr+96|0,Ot=rr,fe=Ot,Ae=fe+96|0;do w[fe>>2]=0,fe=fe+4|0;while((fe|0)<(Ae|0));return F=Rd(F,Ot)|0,F|0?(q=F,qr=rr,q|0):(F=Ot,fe=w[F>>2]|0,F=w[F+4>>2]|0,i0(fe,F,Ie)|0,f0(fe,F,Ze)|0,mr=+Sp(Ie,Ze+8|0),mr=+tn(+(+Sp(D,P)/(mr*2))),x[S>>3]=mr,F=~~mr>>>0,fe=+Ce(mr)>=1?mr>0?~~+fn(+pe(mr/4294967296),4294967295)>>>0:~~+tn((mr-+(~~mr>>>0))/4294967296)>>>0:0,(w[S+4>>2]&2146435072|0)==2146435072?(q=1,qr=rr,q|0):(Ot=(F|0)==0&(fe|0)==0,w[q>>2]=Ot?1:F,w[q+4>>2]=Ot?0:fe,q=0,qr=rr,q|0))}function Dp(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0,w[D>>2]=P,w[D+4>>2]=F,w[D+8>>2]=q}function Tc(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0;pn=P+8|0,w[pn>>2]=0,Ot=+x[D>>3],Ie=+Ce(+Ot),rr=+x[D+8>>3],Ze=+Ce(+rr)/.8660254037844386,Ie=Ie+Ze*.5,F=~~Ie,D=~~Ze,Ie=Ie-+(F|0),Ze=Ze-+(D|0);do if(Ie<.5)if(Ie<.3333333333333333)if(w[P>>2]=F,Ze<(Ie+1)*.5){w[P+4>>2]=D;break}else{D=D+1|0,w[P+4>>2]=D;break}else if(Jn=1-Ie,D=(!(Ze>2]=D,Jn<=Ze&Ze>2]=F;break}else{w[P>>2]=F;break}else{if(!(Ie<.6666666666666666))if(F=F+1|0,w[P>>2]=F,Ze>2]=D;break}else{D=D+1|0,w[P+4>>2]=D;break}if(Ze<1-Ie){if(w[P+4>>2]=D,Ie*2+-1>2]=F;break}}else D=D+1|0,w[P+4>>2]=D;F=F+1|0,w[P>>2]=F}while(0);do if(Ot<0)if(D&1){mr=(D+1|0)/2|0,mr=of(F|0,((F|0)<0)<<31>>31|0,mr|0,((mr|0)<0)<<31>>31|0)|0,F=~~(+(F|0)-((+(mr>>>0)+4294967296*+(xr()|0))*2+1)),w[P>>2]=F;break}else{mr=(D|0)/2|0,mr=of(F|0,((F|0)<0)<<31>>31|0,mr|0,((mr|0)<0)<<31>>31|0)|0,F=~~(+(F|0)-(+(mr>>>0)+4294967296*+(xr()|0))*2),w[P>>2]=F;break}while(0);mr=P+4|0,rr<0&&(F=F-((D<<1|1|0)/2|0)|0,w[P>>2]=F,D=0-D|0,w[mr>>2]=D),q=D-F|0,(F|0)<0?(fe=0-F|0,w[mr>>2]=q,w[pn>>2]=fe,w[P>>2]=0,D=q,F=0):fe=0,(D|0)<0&&(F=F-D|0,w[P>>2]=F,fe=fe-D|0,w[pn>>2]=fe,w[mr>>2]=0,D=0),Ae=F-fe|0,q=D-fe|0,(fe|0)<0&&(w[P>>2]=Ae,w[mr>>2]=q,w[pn>>2]=0,D=q,F=Ae,fe=0),q=(D|0)<(F|0)?D:F,q=(fe|0)<(q|0)?fe:q,!((q|0)<=0)&&(w[P>>2]=F-q,w[mr>>2]=D-q,w[pn>>2]=fe-q)}function Vf(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0;P=w[D>>2]|0,Ie=D+4|0,F=w[Ie>>2]|0,(P|0)<0&&(F=F-P|0,w[Ie>>2]=F,Ae=D+8|0,w[Ae>>2]=(w[Ae>>2]|0)-P,w[D>>2]=0,P=0),(F|0)<0?(P=P-F|0,w[D>>2]=P,Ae=D+8|0,fe=(w[Ae>>2]|0)-F|0,w[Ae>>2]=fe,w[Ie>>2]=0,F=0):(fe=D+8|0,Ae=fe,fe=w[fe>>2]|0),(fe|0)<0&&(P=P-fe|0,w[D>>2]=P,F=F-fe|0,w[Ie>>2]=F,w[Ae>>2]=0,fe=0),q=(F|0)<(P|0)?F:P,q=(fe|0)<(q|0)?fe:q,!((q|0)<=0)&&(w[D>>2]=P-q,w[Ie>>2]=F-q,w[Ae>>2]=fe-q)}function Zh(D,P){D=D|0,P=P|0;var F=0,q=0;q=w[D+8>>2]|0,F=+((w[D+4>>2]|0)-q|0),x[P>>3]=+((w[D>>2]|0)-q|0)-F*.5,x[P+8>>3]=F*.8660254037844386}function dd(D,P,F){D=D|0,P=P|0,F=F|0,w[F>>2]=(w[P>>2]|0)+(w[D>>2]|0),w[F+4>>2]=(w[P+4>>2]|0)+(w[D+4>>2]|0),w[F+8>>2]=(w[P+8>>2]|0)+(w[D+8>>2]|0)}function Jh(D,P,F){D=D|0,P=P|0,F=F|0,w[F>>2]=(w[D>>2]|0)-(w[P>>2]|0),w[F+4>>2]=(w[D+4>>2]|0)-(w[P+4>>2]|0),w[F+8>>2]=(w[D+8>>2]|0)-(w[P+8>>2]|0)}function g0(D,P){D=D|0,P=P|0;var F=0,q=0;F=Hr(w[D>>2]|0,P)|0,w[D>>2]=F,F=D+4|0,q=Hr(w[F>>2]|0,P)|0,w[F>>2]=q,D=D+8|0,P=Hr(w[D>>2]|0,P)|0,w[D>>2]=P}function b0(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;Ie=w[D>>2]|0,Ze=(Ie|0)<0,q=(w[D+4>>2]|0)-(Ze?Ie:0)|0,Ae=(q|0)<0,fe=(Ae?0-q|0:0)+((w[D+8>>2]|0)-(Ze?Ie:0))|0,F=(fe|0)<0,D=F?0:fe,P=(Ae?0:q)-(F?fe:0)|0,fe=(Ze?0:Ie)-(Ae?q:0)-(F?fe:0)|0,F=(P|0)<(fe|0)?P:fe,F=(D|0)<(F|0)?D:F,q=(F|0)>0,D=D-(q?F:0)|0,P=P-(q?F:0)|0;e:do switch(fe-(q?F:0)|0){case 0:switch(P|0){case 0:return Ze=D|0?(D|0)==1?1:7:0,Ze|0;case 1:return Ze=D|0?(D|0)==1?3:7:2,Ze|0;default:break e}case 1:switch(P|0){case 0:return Ze=D|0?(D|0)==1?5:7:4,Ze|0;case 1:{if(!D)D=6;else break e;return D|0}default:break e}default:}while(0);return Ze=7,Ze|0}function Gp(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;Ie=D+8|0,fe=w[Ie>>2]|0,Ae=(w[D>>2]|0)-fe|0,Ze=D+4|0,fe=(w[Ze>>2]|0)-fe|0;do if(Ae>>>0>715827881|fe>>>0>715827881){if(F=(Ae|0)>0,F){if((2147483647-Ae|0)<(Ae|0)||(2147483647-(Ae<<1)|0)<(Ae|0))return Ze=1,Ze|0}else if((-2147483648-Ae|0)>(Ae|0)||(-2147483648-(Ae<<1)|0)>(Ae|0))return Ze=1,Ze|0;if(P=Ae*3|0,(fe|0)>0){if((2147483647-fe|0)<(fe|0))return Ze=1,Ze|0}else if((-2147483648-fe|0)>(fe|0))return Ze=1,Ze|0;if(q=fe<<1,(Ae|0)>-1){if((P|-2147483648|0)>=(fe|0))return Ze=1,Ze|0}else if((P^-2147483648|0)<(fe|0))return Ze=1,Ze|0;if(F){if((2147483647-Ae|0)<(q|0))P=1;else{F=q;break}return P|0}else{if((-2147483648-Ae|0)>(q|0))P=1;else{F=q;break}return P|0}}else F=fe<<1,P=Ae*3|0;while(0);q=Yc(+(P-fe|0)/7)|0,w[D>>2]=q,fe=Yc(+(F+Ae|0)/7)|0,w[Ze>>2]=fe,w[Ie>>2]=0,F=(fe|0)<(q|0),P=F?q:fe,F=F?fe:q;do if((F|0)<0){if((P|0)>0){if((P|-2147483648|0)<(F|0)&((F|0)!=-2147483648&(2147483647-P|0)>=(F|0)))break;Ni(23313,22444,355,22455)}if((F|0)==-2147483648|(-2147483648-P|0)>(F|0)&&Ni(23313,22444,355,22455),(P|0)>-1){if((P|-2147483648|0)<(F|0))break;Ni(23313,22444,355,22455)}else{if((P^-2147483648|0)>=(F|0))break;Ni(23313,22444,355,22455)}}while(0);return P=fe-q|0,(q|0)<0?(F=0-q|0,w[Ze>>2]=P,w[Ie>>2]=F,w[D>>2]=0,q=0):(P=fe,F=0),(P|0)<0&&(q=q-P|0,w[D>>2]=q,F=F-P|0,w[Ie>>2]=F,w[Ze>>2]=0,P=0),Ae=q-F|0,fe=P-F|0,(F|0)<0?(w[D>>2]=Ae,w[Ze>>2]=fe,w[Ie>>2]=0,P=fe,fe=Ae,F=0):fe=q,q=(P|0)<(fe|0)?P:fe,q=(F|0)<(q|0)?F:q,(q|0)<=0?(Ze=0,Ze|0):(w[D>>2]=fe-q,w[Ze>>2]=P-q,w[Ie>>2]=F-q,Ze=0,Ze|0)}function Wp(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;Ie=D+8|0,fe=w[Ie>>2]|0,Ae=(w[D>>2]|0)-fe|0,Ze=D+4|0,fe=(w[Ze>>2]|0)-fe|0;do if(Ae>>>0>715827881|fe>>>0>715827881){if(F=(Ae|0)>0,F){if((2147483647-Ae|0)<(Ae|0))return Ze=1,Ze|0}else if((-2147483648-Ae|0)>(Ae|0))return Ze=1,Ze|0;if(P=Ae<<1,(fe|0)>0){if((2147483647-fe|0)<(fe|0)||(2147483647-(fe<<1)|0)<(fe|0))return Ze=1,Ze|0}else if((-2147483648-fe|0)>(fe|0)||(-2147483648-(fe<<1)|0)>(fe|0))return Ze=1,Ze|0;if(q=fe*3|0,F){if((2147483647-P|0)<(fe|0))return Ze=1,Ze|0}else if((-2147483648-P|0)>(fe|0))return Ze=1,Ze|0;if((fe|0)>-1){if((q|-2147483648|0)<(Ae|0)){F=q;break}else P=1;return P|0}else{if((q^-2147483648|0)<(Ae|0))P=1;else{F=q;break}return P|0}}else F=fe*3|0,P=Ae<<1;while(0);q=Yc(+(P+fe|0)/7)|0,w[D>>2]=q,fe=Yc(+(F-Ae|0)/7)|0,w[Ze>>2]=fe,w[Ie>>2]=0,F=(fe|0)<(q|0),P=F?q:fe,F=F?fe:q;do if((F|0)<0){if((P|0)>0){if((P|-2147483648|0)<(F|0)&((F|0)!=-2147483648&(2147483647-P|0)>=(F|0)))break;Ni(23313,22444,404,22469)}if((F|0)==-2147483648|(-2147483648-P|0)>(F|0)&&Ni(23313,22444,404,22469),(P|0)>-1){if((P|-2147483648|0)<(F|0))break;Ni(23313,22444,404,22469)}else{if((P^-2147483648|0)>=(F|0))break;Ni(23313,22444,404,22469)}}while(0);return P=fe-q|0,(q|0)<0?(F=0-q|0,w[Ze>>2]=P,w[Ie>>2]=F,w[D>>2]=0,q=0):(P=fe,F=0),(P|0)<0&&(q=q-P|0,w[D>>2]=q,F=F-P|0,w[Ie>>2]=F,w[Ze>>2]=0,P=0),Ae=q-F|0,fe=P-F|0,(F|0)<0?(w[D>>2]=Ae,w[Ze>>2]=fe,w[Ie>>2]=0,P=fe,fe=Ae,F=0):fe=q,q=(P|0)<(fe|0)?P:fe,q=(F|0)<(q|0)?F:q,(q|0)<=0?(Ze=0,Ze|0):(w[D>>2]=fe-q,w[Ze>>2]=P-q,w[Ie>>2]=F-q,Ze=0,Ze|0)}function xp(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;Ie=D+8|0,F=w[Ie>>2]|0,P=(w[D>>2]|0)-F|0,Ze=D+4|0,F=(w[Ze>>2]|0)-F|0,q=Yc(+((P*3|0)-F|0)/7)|0,w[D>>2]=q,P=Yc(+((F<<1)+P|0)/7)|0,w[Ze>>2]=P,w[Ie>>2]=0,F=P-q|0,(q|0)<0?(Ae=0-q|0,w[Ze>>2]=F,w[Ie>>2]=Ae,w[D>>2]=0,P=F,q=0,F=Ae):F=0,(P|0)<0&&(q=q-P|0,w[D>>2]=q,F=F-P|0,w[Ie>>2]=F,w[Ze>>2]=0,P=0),Ae=q-F|0,fe=P-F|0,(F|0)<0?(w[D>>2]=Ae,w[Ze>>2]=fe,w[Ie>>2]=0,P=fe,fe=Ae,F=0):fe=q,q=(P|0)<(fe|0)?P:fe,q=(F|0)<(q|0)?F:q,!((q|0)<=0)&&(w[D>>2]=fe-q,w[Ze>>2]=P-q,w[Ie>>2]=F-q)}function U0(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;Ie=D+8|0,F=w[Ie>>2]|0,P=(w[D>>2]|0)-F|0,Ze=D+4|0,F=(w[Ze>>2]|0)-F|0,q=Yc(+((P<<1)+F|0)/7)|0,w[D>>2]=q,P=Yc(+((F*3|0)-P|0)/7)|0,w[Ze>>2]=P,w[Ie>>2]=0,F=P-q|0,(q|0)<0?(Ae=0-q|0,w[Ze>>2]=F,w[Ie>>2]=Ae,w[D>>2]=0,P=F,q=0,F=Ae):F=0,(P|0)<0&&(q=q-P|0,w[D>>2]=q,F=F-P|0,w[Ie>>2]=F,w[Ze>>2]=0,P=0),Ae=q-F|0,fe=P-F|0,(F|0)<0?(w[D>>2]=Ae,w[Ze>>2]=fe,w[Ie>>2]=0,P=fe,fe=Ae,F=0):fe=q,q=(P|0)<(fe|0)?P:fe,q=(F|0)<(q|0)?F:q,!((q|0)<=0)&&(w[D>>2]=fe-q,w[Ze>>2]=P-q,w[Ie>>2]=F-q)}function x0(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;P=w[D>>2]|0,Ie=D+4|0,F=w[Ie>>2]|0,Ze=D+8|0,q=w[Ze>>2]|0,fe=F+(P*3|0)|0,w[D>>2]=fe,F=q+(F*3|0)|0,w[Ie>>2]=F,P=(q*3|0)+P|0,w[Ze>>2]=P,q=F-fe|0,(fe|0)<0?(P=P-fe|0,w[Ie>>2]=q,w[Ze>>2]=P,w[D>>2]=0,F=q,q=0):q=fe,(F|0)<0&&(q=q-F|0,w[D>>2]=q,P=P-F|0,w[Ze>>2]=P,w[Ie>>2]=0,F=0),Ae=q-P|0,fe=F-P|0,(P|0)<0?(w[D>>2]=Ae,w[Ie>>2]=fe,w[Ze>>2]=0,q=Ae,P=0):fe=F,F=(fe|0)<(q|0)?fe:q,F=(P|0)<(F|0)?P:F,!((F|0)<=0)&&(w[D>>2]=q-F,w[Ie>>2]=fe-F,w[Ze>>2]=P-F)}function t0(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;fe=w[D>>2]|0,Ie=D+4|0,P=w[Ie>>2]|0,Ze=D+8|0,F=w[Ze>>2]|0,q=(P*3|0)+fe|0,fe=F+(fe*3|0)|0,w[D>>2]=fe,w[Ie>>2]=q,P=(F*3|0)+P|0,w[Ze>>2]=P,F=q-fe|0,(fe|0)<0?(P=P-fe|0,w[Ie>>2]=F,w[Ze>>2]=P,w[D>>2]=0,fe=0):F=q,(F|0)<0&&(fe=fe-F|0,w[D>>2]=fe,P=P-F|0,w[Ze>>2]=P,w[Ie>>2]=0,F=0),Ae=fe-P|0,q=F-P|0,(P|0)<0?(w[D>>2]=Ae,w[Ie>>2]=q,w[Ze>>2]=0,fe=Ae,P=0):q=F,F=(q|0)<(fe|0)?q:fe,F=(P|0)<(F|0)?P:F,!((F|0)<=0)&&(w[D>>2]=fe-F,w[Ie>>2]=q-F,w[Ze>>2]=P-F)}function np(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;(P+-1|0)>>>0>=6||(fe=(w[15440+(P*12|0)>>2]|0)+(w[D>>2]|0)|0,w[D>>2]=fe,Ze=D+4|0,q=(w[15440+(P*12|0)+4>>2]|0)+(w[Ze>>2]|0)|0,w[Ze>>2]=q,Ie=D+8|0,P=(w[15440+(P*12|0)+8>>2]|0)+(w[Ie>>2]|0)|0,w[Ie>>2]=P,F=q-fe|0,(fe|0)<0?(P=P-fe|0,w[Ze>>2]=F,w[Ie>>2]=P,w[D>>2]=0,q=0):(F=q,q=fe),(F|0)<0&&(q=q-F|0,w[D>>2]=q,P=P-F|0,w[Ie>>2]=P,w[Ze>>2]=0,F=0),Ae=q-P|0,fe=F-P|0,(P|0)<0?(w[D>>2]=Ae,w[Ze>>2]=fe,w[Ie>>2]=0,q=Ae,P=0):fe=F,F=(fe|0)<(q|0)?fe:q,F=(P|0)<(F|0)?P:F,!((F|0)<=0)&&(w[D>>2]=q-F,w[Ze>>2]=fe-F,w[Ie>>2]=P-F))}function M0(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;fe=w[D>>2]|0,Ie=D+4|0,P=w[Ie>>2]|0,Ze=D+8|0,F=w[Ze>>2]|0,q=P+fe|0,fe=F+fe|0,w[D>>2]=fe,w[Ie>>2]=q,P=F+P|0,w[Ze>>2]=P,F=q-fe|0,(fe|0)<0?(P=P-fe|0,w[Ie>>2]=F,w[Ze>>2]=P,w[D>>2]=0,q=0):(F=q,q=fe),(F|0)<0&&(q=q-F|0,w[D>>2]=q,P=P-F|0,w[Ze>>2]=P,w[Ie>>2]=0,F=0),Ae=q-P|0,fe=F-P|0,(P|0)<0?(w[D>>2]=Ae,w[Ie>>2]=fe,w[Ze>>2]=0,q=Ae,P=0):fe=F,F=(fe|0)<(q|0)?fe:q,F=(P|0)<(F|0)?P:F,!((F|0)<=0)&&(w[D>>2]=q-F,w[Ie>>2]=fe-F,w[Ze>>2]=P-F)}function kp(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;P=w[D>>2]|0,Ie=D+4|0,q=w[Ie>>2]|0,Ze=D+8|0,F=w[Ze>>2]|0,fe=q+P|0,w[D>>2]=fe,q=F+q|0,w[Ie>>2]=q,P=F+P|0,w[Ze>>2]=P,F=q-fe|0,(fe|0)<0?(P=P-fe|0,w[Ie>>2]=F,w[Ze>>2]=P,w[D>>2]=0,q=0):(F=q,q=fe),(F|0)<0&&(q=q-F|0,w[D>>2]=q,P=P-F|0,w[Ze>>2]=P,w[Ie>>2]=0,F=0),Ae=q-P|0,fe=F-P|0,(P|0)<0?(w[D>>2]=Ae,w[Ie>>2]=fe,w[Ze>>2]=0,q=Ae,P=0):fe=F,F=(fe|0)<(q|0)?fe:q,F=(P|0)<(F|0)?P:F,!((F|0)<=0)&&(w[D>>2]=q-F,w[Ie>>2]=fe-F,w[Ze>>2]=P-F)}function r0(D){switch(D=D|0,D|0){case 1:{D=5;break}case 5:{D=4;break}case 4:{D=6;break}case 6:{D=2;break}case 2:{D=3;break}case 3:{D=1;break}default:}return D|0}function hp(D){switch(D=D|0,D|0){case 1:{D=3;break}case 3:{D=2;break}case 2:{D=6;break}case 6:{D=4;break}case 4:{D=5;break}case 5:{D=1;break}default:}return D|0}function Xp(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;P=w[D>>2]|0,Ie=D+4|0,F=w[Ie>>2]|0,Ze=D+8|0,q=w[Ze>>2]|0,fe=F+(P<<1)|0,w[D>>2]=fe,F=q+(F<<1)|0,w[Ie>>2]=F,P=(q<<1)+P|0,w[Ze>>2]=P,q=F-fe|0,(fe|0)<0?(P=P-fe|0,w[Ie>>2]=q,w[Ze>>2]=P,w[D>>2]=0,F=q,q=0):q=fe,(F|0)<0&&(q=q-F|0,w[D>>2]=q,P=P-F|0,w[Ze>>2]=P,w[Ie>>2]=0,F=0),Ae=q-P|0,fe=F-P|0,(P|0)<0?(w[D>>2]=Ae,w[Ie>>2]=fe,w[Ze>>2]=0,q=Ae,P=0):fe=F,F=(fe|0)<(q|0)?fe:q,F=(P|0)<(F|0)?P:F,!((F|0)<=0)&&(w[D>>2]=q-F,w[Ie>>2]=fe-F,w[Ze>>2]=P-F)}function pm(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;fe=w[D>>2]|0,Ie=D+4|0,P=w[Ie>>2]|0,Ze=D+8|0,F=w[Ze>>2]|0,q=(P<<1)+fe|0,fe=F+(fe<<1)|0,w[D>>2]=fe,w[Ie>>2]=q,P=(F<<1)+P|0,w[Ze>>2]=P,F=q-fe|0,(fe|0)<0?(P=P-fe|0,w[Ie>>2]=F,w[Ze>>2]=P,w[D>>2]=0,fe=0):F=q,(F|0)<0&&(fe=fe-F|0,w[D>>2]=fe,P=P-F|0,w[Ze>>2]=P,w[Ie>>2]=0,F=0),Ae=fe-P|0,q=F-P|0,(P|0)<0?(w[D>>2]=Ae,w[Ie>>2]=q,w[Ze>>2]=0,fe=Ae,P=0):q=F,F=(q|0)<(fe|0)?q:fe,F=(P|0)<(F|0)?P:F,!((F|0)<=0)&&(w[D>>2]=fe-F,w[Ie>>2]=q-F,w[Ze>>2]=P-F)}function Tp(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;return Ie=(w[D>>2]|0)-(w[P>>2]|0)|0,Ze=(Ie|0)<0,q=(w[D+4>>2]|0)-(w[P+4>>2]|0)-(Ze?Ie:0)|0,Ae=(q|0)<0,fe=(Ze?0-Ie|0:0)+(w[D+8>>2]|0)-(w[P+8>>2]|0)+(Ae?0-q|0:0)|0,D=(fe|0)<0,P=D?0:fe,F=(Ae?0:q)-(D?fe:0)|0,fe=(Ze?0:Ie)-(Ae?q:0)-(D?fe:0)|0,D=(F|0)<(fe|0)?F:fe,D=(P|0)<(D|0)?P:D,q=(D|0)>0,P=P-(q?D:0)|0,F=F-(q?D:0)|0,D=fe-(q?D:0)|0,D=(D|0)>-1?D:0-D|0,F=(F|0)>-1?F:0-F|0,P=(P|0)>-1?P:0-P|0,P=(F|0)>(P|0)?F:P,((D|0)>(P|0)?D:P)|0}function mm(D,P){D=D|0,P=P|0;var F=0;F=w[D+8>>2]|0,w[P>>2]=(w[D>>2]|0)-F,w[P+4>>2]=(w[D+4>>2]|0)-F}function dp(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;q=w[D>>2]|0,w[P>>2]=q,fe=w[D+4>>2]|0,Ie=P+4|0,w[Ie>>2]=fe,Ze=P+8|0,w[Ze>>2]=0,F=(fe|0)<(q|0),D=F?q:fe,F=F?fe:q;do if((F|0)<0){if((D|0)>0){if((D|-2147483648|0)<(F|0)&((F|0)!=-2147483648&(2147483647-D|0)>=(F|0)))break;return D=1,D|0}if((F|0)==-2147483648|(-2147483648-D|0)>(F|0))return P=1,P|0;if((D|0)>-1){if((D|-2147483648|0)<(F|0))break;return D=1,D|0}else{if((D^-2147483648|0)<(F|0))D=1;else break;return D|0}}while(0);return D=fe-q|0,(q|0)<0?(F=0-q|0,w[Ie>>2]=D,w[Ze>>2]=F,w[P>>2]=0,q=0):(D=fe,F=0),(D|0)<0&&(q=q-D|0,w[P>>2]=q,F=F-D|0,w[Ze>>2]=F,w[Ie>>2]=0,D=0),Ae=q-F|0,fe=D-F|0,(F|0)<0?(w[P>>2]=Ae,w[Ie>>2]=fe,w[Ze>>2]=0,D=fe,fe=Ae,F=0):fe=q,q=(D|0)<(fe|0)?D:fe,q=(F|0)<(q|0)?F:q,(q|0)<=0?(P=0,P|0):(w[P>>2]=fe-q,w[Ie>>2]=D-q,w[Ze>>2]=F-q,P=0,P|0)}function j0(D){D=D|0;var P=0,F=0,q=0,fe=0;P=D+8|0,fe=w[P>>2]|0,F=fe-(w[D>>2]|0)|0,w[D>>2]=F,q=D+4|0,D=(w[q>>2]|0)-fe|0,w[q>>2]=D,w[P>>2]=0-(D+F)}function Fp(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;F=w[D>>2]|0,P=0-F|0,w[D>>2]=P,Ie=D+8|0,w[Ie>>2]=0,Ze=D+4|0,q=w[Ze>>2]|0,fe=q+F|0,(F|0)>0?(w[Ze>>2]=fe,w[Ie>>2]=F,w[D>>2]=0,P=0,q=fe):F=0,(q|0)<0?(Ae=P-q|0,w[D>>2]=Ae,F=F-q|0,w[Ie>>2]=F,w[Ze>>2]=0,fe=Ae-F|0,P=0-F|0,(F|0)<0?(w[D>>2]=fe,w[Ze>>2]=P,w[Ie>>2]=0,q=P,F=0):(q=0,fe=Ae)):fe=P,P=(q|0)<(fe|0)?q:fe,P=(F|0)<(P|0)?F:P,!((P|0)<=0)&&(w[D>>2]=fe-P,w[Ze>>2]=q-P,w[Ie>>2]=F-P)}function P0(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0;if(pn=qr,qr=qr+64|0,mr=pn,Ze=pn+56|0,!(!0&(P&2013265920|0)==134217728&(!0&(q&2013265920|0)==134217728)))return fe=5,qr=pn,fe|0;if((D|0)==(F|0)&(P|0)==(q|0))return w[fe>>2]=0,fe=0,qr=pn,fe|0;if(Ie=Rr(D|0,P|0,52)|0,xr()|0,Ie=Ie&15,rr=Rr(F|0,q|0,52)|0,xr()|0,(Ie|0)!=(rr&15|0))return fe=12,qr=pn,fe|0;if(Ae=Ie+-1|0,Ie>>>0>1){pp(D,P,Ae,mr)|0,pp(F,q,Ae,Ze)|0,rr=mr,Ot=w[rr>>2]|0,rr=w[rr+4>>2]|0;e:do if((Ot|0)==(w[Ze>>2]|0)&&(rr|0)==(w[Ze+4>>2]|0)){Ie=(Ie^15)*3|0,Ae=Rr(D|0,P|0,Ie|0)|0,xr()|0,Ae=Ae&7,Ie=Rr(F|0,q|0,Ie|0)|0,xr()|0,Ie=Ie&7;do if((Ae|0)==0|(Ie|0)==0)w[fe>>2]=1,Ae=0;else if((Ae|0)==7)Ae=5;else{if((Ae|0)==1|(Ie|0)==1&&gh(Ot,rr)|0){Ae=5;break}if((w[15536+(Ae<<2)>>2]|0)!=(Ie|0)&&(w[15568+(Ae<<2)>>2]|0)!=(Ie|0))break e;w[fe>>2]=1,Ae=0}while(0);return fe=Ae,qr=pn,fe|0}while(0)}Ae=mr,Ie=Ae+56|0;do w[Ae>>2]=0,Ae=Ae+4|0;while((Ae|0)<(Ie|0));return Gl(D,P,1,mr)|0,P=mr,!((w[P>>2]|0)==(F|0)&&(w[P+4>>2]|0)==(q|0))&&(P=mr+8|0,!((w[P>>2]|0)==(F|0)&&(w[P+4>>2]|0)==(q|0)))&&(P=mr+16|0,!((w[P>>2]|0)==(F|0)&&(w[P+4>>2]|0)==(q|0)))&&(P=mr+24|0,!((w[P>>2]|0)==(F|0)&&(w[P+4>>2]|0)==(q|0)))&&(P=mr+32|0,!((w[P>>2]|0)==(F|0)&&(w[P+4>>2]|0)==(q|0)))&&(P=mr+40|0,!((w[P>>2]|0)==(F|0)&&(w[P+4>>2]|0)==(q|0)))?(Ae=mr+48|0,Ae=((w[Ae>>2]|0)==(F|0)?(w[Ae+4>>2]|0)==(q|0):0)&1):Ae=1,w[fe>>2]=Ae,fe=0,qr=pn,fe|0}function I0(D,P,F,q,fe){return D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0,F=xf(D,P,F,q)|0,(F|0)==7?(fe=11,fe|0):(q=sr(F|0,0,56)|0,P=P&-2130706433|(xr()|0)|268435456,w[fe>>2]=D|q,w[fe+4>>2]=P,fe=0,fe|0)}function V0(D,P,F){return D=D|0,P=P|0,F=F|0,!0&(P&2013265920|0)==268435456?(w[F>>2]=D,w[F+4>>2]=P&-2130706433|134217728,F=0,F|0):(F=6,F|0)}function d0(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0;return fe=qr,qr=qr+16|0,q=fe,w[q>>2]=0,!0&(P&2013265920|0)==268435456?(Ae=Rr(D|0,P|0,56)|0,xr()|0,q=rf(D,P&-2130706433|134217728,Ae&7,q,F)|0,qr=fe,q|0):(q=6,qr=fe,q|0)}function Q0(D,P){D=D|0,P=P|0;var F=0;switch(F=Rr(D|0,P|0,56)|0,xr()|0,F&7){case 0:case 7:return F=0,F|0;default:}return F=P&-2130706433|134217728,!(!0&(P&2013265920|0)==268435456)||!0&(P&117440512|0)==16777216&(gh(D,F)|0)!=0?(F=0,F|0):(F=op(D,F)|0,F|0)}function Mc(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0;return fe=qr,qr=qr+16|0,q=fe,!0&(P&2013265920|0)==268435456?(Ae=P&-2130706433|134217728,Ie=F,w[Ie>>2]=D,w[Ie+4>>2]=Ae,w[q>>2]=0,P=Rr(D|0,P|0,56)|0,xr()|0,q=rf(D,Ae,P&7,q,F+8|0)|0,qr=fe,q|0):(q=6,qr=fe,q|0)}function R0(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0;return fe=(gh(D,P)|0)==0,P=P&-2130706433,q=F,w[q>>2]=fe?D:0,w[q+4>>2]=fe?P|285212672:0,q=F+8|0,w[q>>2]=D,w[q+4>>2]=P|301989888,q=F+16|0,w[q>>2]=D,w[q+4>>2]=P|318767104,q=F+24|0,w[q>>2]=D,w[q+4>>2]=P|335544320,q=F+32|0,w[q>>2]=D,w[q+4>>2]=P|352321536,F=F+40|0,w[F>>2]=D,w[F+4>>2]=P|369098752,0}function w0(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0;return Ie=qr,qr=qr+16|0,fe=Ie,Ae=P&-2130706433|134217728,!0&(P&2013265920|0)==268435456?(q=Rr(D|0,P|0,56)|0,xr()|0,q=jl(D,Ae,q&7)|0,(q|0)==-1?(w[F>>2]=0,Ae=6,qr=Ie,Ae|0):(yp(D,Ae,fe)|0&&Ni(23313,22484,282,22499),P=Rr(D|0,P|0,52)|0,xr()|0,P=P&15,gh(D,Ae)|0?ip(fe,P,q,2,F):pd(fe,P,q,2,F),Ae=0,qr=Ie,Ae|0)):(Ae=6,qr=Ie,Ae|0)}function ad(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0;q=qr,qr=qr+16|0,fe=q,Yp(D,P,F,fe),Tc(fe,F+4|0),qr=q}function Yp(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0,Ot=0;if(Ze=qr,qr=qr+16|0,Ot=Ze,E0(D,F,Ot),Ae=+cr(+(1-+x[Ot>>3]*.5)),Ae<1e-16){w[q>>2]=0,w[q+4>>2]=0,w[q+8>>2]=0,w[q+12>>2]=0,qr=Ze;return}if(Ot=w[F>>2]|0,fe=+x[15920+(Ot*24|0)>>3],fe=+k0(fe-+k0(+um(15600+(Ot<<4)|0,D))),jd(P)|0?Ie=+k0(fe+-.3334731722518321):Ie=fe,fe=+Qt(+Ae)/.381966011250105,(P|0)>0){D=0;do fe=fe*2.6457513110645907,D=D+1|0;while((D|0)!=(P|0))}Ae=+zt(+Ie)*fe,x[q>>3]=Ae,Ie=+Tt(+Ie)*fe,x[q+8>>3]=Ie,qr=Ze}function E0(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0;if(Ae=qr,qr=qr+32|0,fe=Ae,zu(D,fe),w[P>>2]=0,x[F>>3]=5,q=+lc(16400,fe),q<+x[F>>3]&&(w[P>>2]=0,x[F>>3]=q),q=+lc(16424,fe),q<+x[F>>3]&&(w[P>>2]=1,x[F>>3]=q),q=+lc(16448,fe),q<+x[F>>3]&&(w[P>>2]=2,x[F>>3]=q),q=+lc(16472,fe),q<+x[F>>3]&&(w[P>>2]=3,x[F>>3]=q),q=+lc(16496,fe),q<+x[F>>3]&&(w[P>>2]=4,x[F>>3]=q),q=+lc(16520,fe),q<+x[F>>3]&&(w[P>>2]=5,x[F>>3]=q),q=+lc(16544,fe),q<+x[F>>3]&&(w[P>>2]=6,x[F>>3]=q),q=+lc(16568,fe),q<+x[F>>3]&&(w[P>>2]=7,x[F>>3]=q),q=+lc(16592,fe),q<+x[F>>3]&&(w[P>>2]=8,x[F>>3]=q),q=+lc(16616,fe),q<+x[F>>3]&&(w[P>>2]=9,x[F>>3]=q),q=+lc(16640,fe),q<+x[F>>3]&&(w[P>>2]=10,x[F>>3]=q),q=+lc(16664,fe),q<+x[F>>3]&&(w[P>>2]=11,x[F>>3]=q),q=+lc(16688,fe),q<+x[F>>3]&&(w[P>>2]=12,x[F>>3]=q),q=+lc(16712,fe),q<+x[F>>3]&&(w[P>>2]=13,x[F>>3]=q),q=+lc(16736,fe),q<+x[F>>3]&&(w[P>>2]=14,x[F>>3]=q),q=+lc(16760,fe),q<+x[F>>3]&&(w[P>>2]=15,x[F>>3]=q),q=+lc(16784,fe),q<+x[F>>3]&&(w[P>>2]=16,x[F>>3]=q),q=+lc(16808,fe),q<+x[F>>3]&&(w[P>>2]=17,x[F>>3]=q),q=+lc(16832,fe),q<+x[F>>3]&&(w[P>>2]=18,x[F>>3]=q),q=+lc(16856,fe),!(q<+x[F>>3])){qr=Ae;return}w[P>>2]=19,x[F>>3]=q,qr=Ae}function S0(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0;if(Ae=+ws(D),Ae<1e-16){P=15600+(P<<4)|0,w[fe>>2]=w[P>>2],w[fe+4>>2]=w[P+4>>2],w[fe+8>>2]=w[P+8>>2],w[fe+12>>2]=w[P+12>>2];return}if(Ie=+jr(+ +x[D+8>>3],+ +x[D>>3]),(F|0)>0){D=0;do Ae=Ae/2.6457513110645907,D=D+1|0;while((D|0)!=(F|0))}q?(Ae=Ae/3,F=(jd(F)|0)==0,Ae=+zr(+((F?Ae:Ae/2.6457513110645907)*.381966011250105))):(Ae=+zr(+(Ae*.381966011250105)),jd(F)|0&&(Ie=+k0(Ie+.3334731722518321))),Vh(15600+(P<<4)|0,+k0(+x[15920+(P*24|0)>>3]-Ie),Ae,fe)}function gd(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0;q=qr,qr=qr+16|0,fe=q,Zh(D+4|0,fe),S0(fe,w[D>>2]|0,P,0,F),qr=q}function ip(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0,Go=0,Wo=0,To=0,El=0,gl=0,du=0,Qu=0,_h=0,Th=0,vh=0,$f=0,Nl=0,vc=0,Hh=0,Af=0;if(vc=qr,qr=qr+272|0,Ae=vc+256|0,Go=vc+240|0,vh=vc,$f=vc+224|0,Nl=vc+208|0,Wo=vc+176|0,To=vc+160|0,El=vc+192|0,gl=vc+144|0,du=vc+128|0,Qu=vc+112|0,_h=vc+96|0,Th=vc+80|0,w[Ae>>2]=P,w[Go>>2]=w[D>>2],w[Go+4>>2]=w[D+4>>2],w[Go+8>>2]=w[D+8>>2],w[Go+12>>2]=w[D+12>>2],O0(Go,Ae,vh),w[fe>>2]=0,Go=q+F+((q|0)==5&1)|0,(Go|0)<=(F|0)){qr=vc;return}Ot=w[Ae>>2]|0,rr=$f+4|0,mr=Wo+4|0,pn=F+5|0,Jn=16880+(Ot<<2)|0,ui=16960+(Ot<<2)|0,ci=du+8|0,no=Qu+8|0,Wa=_h+8|0,ha=Nl+4|0,Ze=F;e:for(;;){Ie=vh+(((Ze|0)%5|0)<<4)|0,w[Nl>>2]=w[Ie>>2],w[Nl+4>>2]=w[Ie+4>>2],w[Nl+8>>2]=w[Ie+8>>2],w[Nl+12>>2]=w[Ie+12>>2];do;while((Bp(Nl,Ot,0,1)|0)==2);if((Ze|0)>(F|0)&(jd(P)|0)!=0){if(w[Wo>>2]=w[Nl>>2],w[Wo+4>>2]=w[Nl+4>>2],w[Wo+8>>2]=w[Nl+8>>2],w[Wo+12>>2]=w[Nl+12>>2],Zh(rr,To),q=w[Wo>>2]|0,Ae=w[17040+(q*80|0)+(w[$f>>2]<<2)>>2]|0,w[Wo>>2]=w[18640+(q*80|0)+(Ae*20|0)>>2],Ie=w[18640+(q*80|0)+(Ae*20|0)+16>>2]|0,(Ie|0)>0){D=0;do M0(mr),D=D+1|0;while((D|0)<(Ie|0))}switch(Ie=18640+(q*80|0)+(Ae*20|0)+4|0,w[El>>2]=w[Ie>>2],w[El+4>>2]=w[Ie+4>>2],w[El+8>>2]=w[Ie+8>>2],g0(El,(w[Jn>>2]|0)*3|0),dd(mr,El,mr),Vf(mr),Zh(mr,gl),Hh=+(w[ui>>2]|0),x[du>>3]=Hh*3,x[ci>>3]=0,Af=Hh*-1.5,x[Qu>>3]=Af,x[no>>3]=Hh*2.598076211353316,x[_h>>3]=Af,x[Wa>>3]=Hh*-2.598076211353316,w[17040+((w[Wo>>2]|0)*80|0)+(w[Nl>>2]<<2)>>2]|0){case 1:{D=Qu,q=du;break}case 3:{D=_h,q=Qu;break}case 2:{D=du,q=_h;break}default:{D=12;break e}}La(To,gl,q,D,Th),S0(Th,w[Wo>>2]|0,Ot,1,fe+8+(w[fe>>2]<<4)|0),w[fe>>2]=(w[fe>>2]|0)+1}if((Ze|0)<(pn|0)&&(Zh(ha,Wo),S0(Wo,w[Nl>>2]|0,Ot,1,fe+8+(w[fe>>2]<<4)|0),w[fe>>2]=(w[fe>>2]|0)+1),w[$f>>2]=w[Nl>>2],w[$f+4>>2]=w[Nl+4>>2],w[$f+8>>2]=w[Nl+8>>2],w[$f+12>>2]=w[Nl+12>>2],Ze=Ze+1|0,(Ze|0)>=(Go|0)){D=3;break}}if((D|0)==3){qr=vc;return}else(D|0)==12&&Ni(22522,22569,571,22579)}function O0(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0;Ot=qr,qr=qr+128|0,q=Ot+64|0,fe=Ot,Ae=q,Ie=20240,Ze=Ae+60|0;do w[Ae>>2]=w[Ie>>2],Ae=Ae+4|0,Ie=Ie+4|0;while((Ae|0)<(Ze|0));Ae=fe,Ie=20304,Ze=Ae+60|0;do w[Ae>>2]=w[Ie>>2],Ae=Ae+4|0,Ie=Ie+4|0;while((Ae|0)<(Ze|0));Ze=(jd(w[P>>2]|0)|0)==0,q=Ze?q:fe,fe=D+4|0,Xp(fe),pm(fe),jd(w[P>>2]|0)|0&&(t0(fe),w[P>>2]=(w[P>>2]|0)+1),w[F>>2]=w[D>>2],P=F+4|0,dd(fe,q,P),Vf(P),w[F+16>>2]=w[D>>2],P=F+20|0,dd(fe,q+12|0,P),Vf(P),w[F+32>>2]=w[D>>2],P=F+36|0,dd(fe,q+24|0,P),Vf(P),w[F+48>>2]=w[D>>2],P=F+52|0,dd(fe,q+36|0,P),Vf(P),w[F+64>>2]=w[D>>2],F=F+68|0,dd(fe,q+48|0,F),Vf(F),qr=Ot}function Bp(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0;if(ci=qr,qr=qr+32|0,Jn=ci+12|0,Ze=ci,ui=D+4|0,pn=w[16960+(P<<2)>>2]|0,mr=(q|0)!=0,pn=mr?pn*3|0:pn,fe=w[ui>>2]|0,rr=D+8|0,Ie=w[rr>>2]|0,mr){if(Ae=D+12|0,q=w[Ae>>2]|0,fe=Ie+fe+q|0,(fe|0)==(pn|0))return ui=1,qr=ci,ui|0;Ot=Ae}else Ot=D+12|0,q=w[Ot>>2]|0,fe=Ie+fe+q|0;if((fe|0)<=(pn|0))return ui=0,qr=ci,ui|0;do if((q|0)>0){if(q=w[D>>2]|0,(Ie|0)>0){Ae=18640+(q*80|0)+60|0,q=D;break}q=18640+(q*80|0)+40|0,F?(Dp(Jn,pn,0,0),Jh(ui,Jn,Ze),kp(Ze),dd(Ze,Jn,ui),Ae=q,q=D):(Ae=q,q=D)}else Ae=18640+((w[D>>2]|0)*80|0)+20|0,q=D;while(0);if(w[q>>2]=w[Ae>>2],fe=Ae+16|0,(w[fe>>2]|0)>0){q=0;do M0(ui),q=q+1|0;while((q|0)<(w[fe>>2]|0))}return D=Ae+4|0,w[Jn>>2]=w[D>>2],w[Jn+4>>2]=w[D+4>>2],w[Jn+8>>2]=w[D+8>>2],P=w[16880+(P<<2)>>2]|0,g0(Jn,mr?P*3|0:P),dd(ui,Jn,ui),Vf(ui),mr?q=((w[rr>>2]|0)+(w[ui>>2]|0)+(w[Ot>>2]|0)|0)==(pn|0)?1:2:q=2,ui=q,qr=ci,ui|0}function $0(D,P){D=D|0,P=P|0;var F=0;do F=Bp(D,P,0,1)|0;while((F|0)==2);return F|0}function pd(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0,Go=0,Wo=0,To=0,El=0,gl=0,du=0,Qu=0,_h=0,Th=0,vh=0;if(_h=qr,qr=qr+240|0,Ae=_h+224|0,El=_h+208|0,gl=_h,du=_h+192|0,Qu=_h+176|0,Wa=_h+160|0,ha=_h+144|0,Go=_h+128|0,Wo=_h+112|0,To=_h+96|0,w[Ae>>2]=P,w[El>>2]=w[D>>2],w[El+4>>2]=w[D+4>>2],w[El+8>>2]=w[D+8>>2],w[El+12>>2]=w[D+12>>2],Kp(El,Ae,gl),w[fe>>2]=0,no=q+F+((q|0)==6&1)|0,(no|0)<=(F|0)){qr=_h;return}Ot=w[Ae>>2]|0,rr=F+6|0,mr=16960+(Ot<<2)|0,pn=ha+8|0,Jn=Go+8|0,ui=Wo+8|0,ci=du+4|0,Ie=0,Ze=F,q=-1;e:for(;;){if(Ae=(Ze|0)%6|0,D=gl+(Ae<<4)|0,w[du>>2]=w[D>>2],w[du+4>>2]=w[D+4>>2],w[du+8>>2]=w[D+8>>2],w[du+12>>2]=w[D+12>>2],D=Ie,Ie=Bp(du,Ot,0,1)|0,(Ze|0)>(F|0)&(jd(P)|0)!=0&&(D|0)!=1&&(w[du>>2]|0)!=(q|0)){switch(Zh(gl+(((Ae+5|0)%6|0)<<4)+4|0,Qu),Zh(gl+(Ae<<4)+4|0,Wa),Th=+(w[mr>>2]|0),x[ha>>3]=Th*3,x[pn>>3]=0,vh=Th*-1.5,x[Go>>3]=vh,x[Jn>>3]=Th*2.598076211353316,x[Wo>>3]=vh,x[ui>>3]=Th*-2.598076211353316,Ae=w[El>>2]|0,w[17040+(Ae*80|0)+(((q|0)==(Ae|0)?w[du>>2]|0:q)<<2)>>2]|0){case 1:{D=Go,q=ha;break}case 3:{D=Wo,q=Go;break}case 2:{D=ha,q=Wo;break}default:{D=8;break e}}La(Qu,Wa,q,D,To),!(Ql(Qu,To)|0)&&!(Ql(Wa,To)|0)&&(S0(To,w[El>>2]|0,Ot,1,fe+8+(w[fe>>2]<<4)|0),w[fe>>2]=(w[fe>>2]|0)+1)}if((Ze|0)<(rr|0)&&(Zh(ci,Qu),S0(Qu,w[du>>2]|0,Ot,1,fe+8+(w[fe>>2]<<4)|0),w[fe>>2]=(w[fe>>2]|0)+1),Ze=Ze+1|0,(Ze|0)>=(no|0)){D=3;break}else q=w[du>>2]|0}if((D|0)==3){qr=_h;return}else(D|0)==8&&Ni(22606,22569,736,22651)}function Kp(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0;Ot=qr,qr=qr+160|0,q=Ot+80|0,fe=Ot,Ae=q,Ie=20368,Ze=Ae+72|0;do w[Ae>>2]=w[Ie>>2],Ae=Ae+4|0,Ie=Ie+4|0;while((Ae|0)<(Ze|0));Ae=fe,Ie=20448,Ze=Ae+72|0;do w[Ae>>2]=w[Ie>>2],Ae=Ae+4|0,Ie=Ie+4|0;while((Ae|0)<(Ze|0));Ze=(jd(w[P>>2]|0)|0)==0,q=Ze?q:fe,fe=D+4|0,Xp(fe),pm(fe),jd(w[P>>2]|0)|0&&(t0(fe),w[P>>2]=(w[P>>2]|0)+1),w[F>>2]=w[D>>2],P=F+4|0,dd(fe,q,P),Vf(P),w[F+16>>2]=w[D>>2],P=F+20|0,dd(fe,q+12|0,P),Vf(P),w[F+32>>2]=w[D>>2],P=F+36|0,dd(fe,q+24|0,P),Vf(P),w[F+48>>2]=w[D>>2],P=F+52|0,dd(fe,q+36|0,P),Vf(P),w[F+64>>2]=w[D>>2],P=F+68|0,dd(fe,q+48|0,P),Vf(P),w[F+80>>2]=w[D>>2],F=F+84|0,dd(fe,q+60|0,F),Vf(F),qr=Ot}function Mp(D,P){return D=D|0,P=P|0,P=Rr(D|0,P|0,52)|0,xr()|0,P&15|0}function wp(D,P){return D=D|0,P=P|0,P=Rr(D|0,P|0,45)|0,xr()|0,P&127|0}function op(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;if(!(!0&(P&-16777216|0)==134217728)||(Ie=Rr(D|0,P|0,45)|0,xr()|0,Ie=Ie&127,Ie>>>0>121))return P=0,P|0;F=Rr(D|0,P|0,52)|0,xr()|0,F=F&15;do if(F|0){for(fe=1,q=0;;){if(Ae=Rr(D|0,P|0,(15-fe|0)*3|0)|0,xr()|0,Ae=Ae&7,(Ae|0)!=0&(q^1))if((Ae|0)==1&(Ff(Ie)|0)!=0){Ze=0,q=13;break}else q=1;if((Ae|0)==7){Ze=0,q=13;break}if(fe>>>0>>0)fe=fe+1|0;else{q=9;break}}if((q|0)==9){if((F|0)==15)Ze=1;else break;return Ze|0}else if((q|0)==13)return Ze|0}while(0);for(;;){if(Ze=Rr(D|0,P|0,(14-F|0)*3|0)|0,xr()|0,!((Ze&7|0)==7&!0)){Ze=0,q=13;break}if(F>>>0<14)F=F+1|0;else{Ze=1,q=13;break}}return(q|0)==13?Ze|0:0}function pp(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0;if(Ae=Rr(D|0,P|0,52)|0,xr()|0,Ae=Ae&15,F>>>0>15)return q=4,q|0;if((Ae|0)<(F|0))return q=12,q|0;if((Ae|0)==(F|0))return w[q>>2]=D,w[q+4>>2]=P,q=0,q|0;if(fe=sr(F|0,0,52)|0,fe=fe|D,D=xr()|0|P&-15728641,(Ae|0)>(F|0))do P=sr(7,0,(14-F|0)*3|0)|0,F=F+1|0,fe=P|fe,D=xr()|0|D;while((F|0)<(Ae|0));return w[q>>2]=fe,w[q+4>>2]=D,q=0,q|0}function H0(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0;if(Ae=Rr(D|0,P|0,52)|0,xr()|0,Ae=Ae&15,!((F|0)<16&(Ae|0)<=(F|0)))return q=4,q|0;fe=F-Ae|0,F=Rr(D|0,P|0,45)|0,xr()|0;e:do if(!(Ff(F&127)|0))F=co(7,0,fe,((fe|0)<0)<<31>>31)|0,fe=xr()|0;else{t:do if(Ae|0){for(F=1;Ie=sr(7,0,(15-F|0)*3|0)|0,!!((Ie&D|0)==0&((xr()|0)&P|0)==0);)if(F>>>0>>0)F=F+1|0;else break t;F=co(7,0,fe,((fe|0)<0)<<31>>31)|0,fe=xr()|0;break e}while(0);F=co(7,0,fe,((fe|0)<0)<<31>>31)|0,F=ao(F|0,xr()|0,5,0)|0,F=Gs(F|0,xr()|0,-5,-1)|0,F=ei(F|0,xr()|0,6,0)|0,F=Gs(F|0,xr()|0,1,0)|0,fe=xr()|0}while(0);return Ie=q,w[Ie>>2]=F,w[Ie+4>>2]=fe,Ie=0,Ie|0}function gh(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0;if(fe=Rr(D|0,P|0,45)|0,xr()|0,!(Ff(fe&127)|0))return fe=0,fe|0;fe=Rr(D|0,P|0,52)|0,xr()|0,fe=fe&15;e:do if(!fe)F=0;else for(q=1;;){if(F=Rr(D|0,P|0,(15-q|0)*3|0)|0,xr()|0,F=F&7,F|0)break e;if(q>>>0>>0)q=q+1|0;else{F=0;break}}while(0);return fe=(F|0)==0&1,fe|0}function y0(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0;if(Ie=qr,qr=qr+16|0,Ae=Ie,Am(Ae,D,P,F),P=Ae,D=w[P>>2]|0,P=w[P+4>>2]|0,(D|0)==0&(P|0)==0)return qr=Ie,0;fe=0,F=0;do Ze=q+(fe<<3)|0,w[Ze>>2]=D,w[Ze+4>>2]=P,fe=Gs(fe|0,F|0,1,0)|0,F=xr()|0,_0(Ae),Ze=Ae,D=w[Ze>>2]|0,P=w[Ze+4>>2]|0;while(!((D|0)==0&(P|0)==0));return qr=Ie,0}function n0(D,P,F,q){return D=D|0,P=P|0,F=F|0,q=q|0,(q|0)<(F|0)?(F=P,q=D,Ai(F|0),q|0):(F=sr(-1,-1,((q-F|0)*3|0)+3|0)|0,q=sr(~F|0,~(xr()|0)|0,(15-q|0)*3|0)|0,F=~(xr()|0)&P,q=~q&D,Ai(F|0),q|0)}function Np(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0;return fe=Rr(D|0,P|0,52)|0,xr()|0,fe=fe&15,(F|0)<16&(fe|0)<=(F|0)?((fe|0)<(F|0)&&(fe=sr(-1,-1,((F+-1-fe|0)*3|0)+3|0)|0,fe=sr(~fe|0,~(xr()|0)|0,(15-F|0)*3|0)|0,P=~(xr()|0)&P,D=~fe&D),fe=sr(F|0,0,52)|0,F=P&-15728641|(xr()|0),w[q>>2]=D|fe,w[q+4>>2]=F,q=0,q|0):(q=4,q|0)}function L0(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0,Go=0,Wo=0,To=0,El=0,gl=0,du=0,Qu=0;if((F|0)==0&(q|0)==0)return du=0,du|0;if(fe=D,Ae=w[fe>>2]|0,fe=w[fe+4>>2]|0,!0&(fe&15728640|0)==0){if(!((q|0)>0|(q|0)==0&F>>>0>0)||(du=P,w[du>>2]=Ae,w[du+4>>2]=fe,(F|0)==1&(q|0)==0))return du=0,du|0;fe=1;do El=D+(fe<<3)|0,gl=w[El+4>>2]|0,du=P+(fe<<3)|0,w[du>>2]=w[El>>2],w[du+4>>2]=gl,fe=fe+1|0;while(0<(q|0)|(q|0)==0&fe>>>0>>0);return fe=0,fe|0}if(To=F<<3,gl=Qf(To)|0,!gl)return du=13,du|0;if(Pi(gl|0,D|0,To|0)|0,El=hl(F,8)|0,!El)return Pu(gl),du=13,du|0;e:do if(F|0){t:for(;;){fe=gl,ha=w[fe>>2]|0,fe=w[fe+4>>2]|0,Go=Rr(ha|0,fe|0,52)|0,xr()|0,Go=Go&15,Wo=Go+-1|0,Wa=(F|0)>0;r:do if((Go|0)!=0&Wa){if(ui=((F|0)<0)<<31>>31,ci=sr(Wo|0,0,52)|0,no=xr()|0,Wo>>>0>15){if(!((ha|0)==0&(fe|0)==0)){du=17;break t}for(Ae=0;;){if(Ae=Ae+1|0,(Ae|0)>=(F|0))break r;if(q=gl+(Ae<<3)|0,no=w[q>>2]|0,q=w[q+4>>2]|0,!((no|0)==0&(q|0)==0)){fe=q,du=17;break t}}}for(Ae=0,D=ha,q=fe;;){if(!((D|0)==0&(q|0)==0)){if(!(!0&(q&117440512|0)==0)){du=22;break t}if(Ze=Rr(D|0,q|0,52)|0,xr()|0,Ze=Ze&15,(Ze|0)<(Wo|0)){fe=12,du=28;break t}if((Ze|0)!=(Wo|0)&&(D=D|ci,q=q&-15728641|no,Ze>>>0>=Go>>>0)){Ie=Wo;do Jn=sr(7,0,(14-Ie|0)*3|0)|0,Ie=Ie+1|0,D=Jn|D,q=xr()|0|q;while(Ie>>>0>>0)}if(Ie=Kc(D|0,q|0,F|0,ui|0)|0,xr()|0,rr=El+(Ie<<3)|0,Ze=rr,Ot=w[Ze>>2]|0,Ze=w[Ze+4>>2]|0,(Ot|0)==0&(Ze|0)==0)Ie=rr;else for(Jn=0;;){if((Jn|0)>(F|0)){du=32;break t}if((Ot|0)==(D|0)&(Ze&-117440513|0)==(q|0)){mr=Rr(Ot|0,Ze|0,56)|0,xr()|0,mr=mr&7,pn=mr+1|0,Qu=Rr(Ot|0,Ze|0,45)|0,xr()|0;n:do if(!(Ff(Qu&127)|0))Ze=7;else{if(Ot=Rr(Ot|0,Ze|0,52)|0,xr()|0,Ot=Ot&15,!Ot){Ze=6;break}for(Ze=1;;){if(Qu=sr(7,0,(15-Ze|0)*3|0)|0,!((Qu&D|0)==0&((xr()|0)&q|0)==0)){Ze=7;break n}if(Ze>>>0>>0)Ze=Ze+1|0;else{Ze=6;break}}}while(0);if((mr+2|0)>>>0>Ze>>>0){du=42;break t}Qu=sr(pn|0,0,56)|0,q=xr()|0|q&-117440513,pn=rr,w[pn>>2]=0,w[pn+4>>2]=0,D=Qu|D}else Ie=(Ie+1|0)%(F|0)|0;if(rr=El+(Ie<<3)|0,Ze=rr,Ot=w[Ze>>2]|0,Ze=w[Ze+4>>2]|0,(Ot|0)==0&(Ze|0)==0){Ie=rr;break}else Jn=Jn+1|0}Qu=Ie,w[Qu>>2]=D,w[Qu+4>>2]=q}if(Ae=Ae+1|0,(Ae|0)>=(F|0))break r;q=gl+(Ae<<3)|0,D=w[q>>2]|0,q=w[q+4>>2]|0}}while(0);if((F+5|0)>>>0<11){du=85;break}if(no=hl((F|0)/6|0,8)|0,!no){du=49;break}r:do if(Wa){Jn=0,pn=0;do{if(Ze=El+(Jn<<3)|0,q=Ze,Ae=w[q>>2]|0,q=w[q+4>>2]|0,!((Ae|0)==0&(q|0)==0)){Ot=Rr(Ae|0,q|0,56)|0,xr()|0,Ot=Ot&7,D=Ot+1|0,rr=q&-117440513,Qu=Rr(Ae|0,q|0,45)|0,xr()|0;n:do if(Ff(Qu&127)|0){if(mr=Rr(Ae|0,q|0,52)|0,xr()|0,mr=mr&15,mr|0)for(Ie=1;;){if(Qu=sr(7,0,(15-Ie|0)*3|0)|0,!((Ae&Qu|0)==0&(rr&(xr()|0)|0)==0))break n;if(Ie>>>0>>0)Ie=Ie+1|0;else break}q=sr(D|0,0,56)|0,Ae=q|Ae,q=xr()|0|rr,D=Ze,w[D>>2]=Ae,w[D+4>>2]=q,D=Ot+2|0}while(0);(D|0)==7&&(Qu=no+(pn<<3)|0,w[Qu>>2]=Ae,w[Qu+4>>2]=q&-117440513,pn=pn+1|0)}Jn=Jn+1|0}while((Jn|0)!=(F|0));if(Wa){if(Jn=((F|0)<0)<<31>>31,ui=sr(Wo|0,0,52)|0,ci=xr()|0,Wo>>>0>15){if(!((ha|0)==0&(fe|0)==0)){fe=4,du=84;break t}for(fe=0;;){if(fe=fe+1|0,(fe|0)>=(F|0)){Ae=0,fe=pn;break r}if(Qu=gl+(fe<<3)|0,!((w[Qu>>2]|0)==0&(w[Qu+4>>2]|0)==0)){fe=4,du=84;break t}}}for(mr=0,Ae=0,rr=ha;;){do if(!((rr|0)==0&(fe|0)==0)){if(Ze=Rr(rr|0,fe|0,52)|0,xr()|0,Ze=Ze&15,(Ze|0)<(Wo|0)){fe=12,du=84;break t}do if((Ze|0)==(Wo|0))q=rr,Ze=fe;else{if(q=rr|ui,D=fe&-15728641|ci,Ze>>>0>>0){Ze=D;break}Ie=Wo;do Qu=sr(7,0,(14-Ie|0)*3|0)|0,Ie=Ie+1|0,q=Qu|q,D=xr()|0|D;while(Ie>>>0>>0);Ze=D}while(0);for(Ie=Kc(q|0,Ze|0,F|0,Jn|0)|0,xr()|0,D=0;;){if((D|0)>(F|0)){du=77;break t}if(Qu=El+(Ie<<3)|0,Ot=w[Qu+4>>2]|0,(Ot&-117440513|0)==(Ze|0)&&(w[Qu>>2]|0)==(q|0)){du=79;break}if(Ie=(Ie+1|0)%(F|0)|0,Qu=El+(Ie<<3)|0,(w[Qu>>2]|0)==(q|0)&&(w[Qu+4>>2]|0)==(Ze|0))break;D=D+1|0}if((du|0)==79&&(du=0,!0&(Ot&117440512|0)==100663296))break;Qu=P+(Ae<<3)|0,w[Qu>>2]=rr,w[Qu+4>>2]=fe,Ae=Ae+1|0}while(0);if(fe=mr+1|0,(fe|0)>=(F|0)){fe=pn;break r}Qu=gl+(fe<<3)|0,mr=fe,rr=w[Qu>>2]|0,fe=w[Qu+4>>2]|0}}else Ae=0,fe=pn}else Ae=0,fe=0;while(0);if(ji(El|0,0,To|0)|0,Pi(gl|0,no|0,fe<<3|0)|0,Pu(no),fe)P=P+(Ae<<3)|0,F=fe;else break e}if((du|0)==17)!0&(fe&117440512|0)==0?(fe=4,du=28):du=22;else if((du|0)==32)Ni(23313,22674,362,22684);else{if((du|0)==42)return Pu(gl),Pu(El),Qu=10,Qu|0;if((du|0)==49)return Pu(gl),Pu(El),Qu=13,Qu|0;if((du|0)==77)Ni(23313,22674,462,22684);else{if((du|0)==84)return Pu(no),Pu(gl),Pu(El),Qu=fe,Qu|0;if((du|0)==85){Pi(P|0,gl|0,F<<3|0)|0;break}}}if((du|0)==22)return Pu(gl),Pu(El),Qu=5,Qu|0;if((du|0)==28)return Pu(gl),Pu(El),Qu=fe,Qu|0}while(0);return Pu(gl),Pu(El),Qu=0,Qu|0}function _m(D,P,F,q,fe,Ae,Ie){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0,Ae=Ae|0,Ie=Ie|0;var Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0;if(no=qr,qr=qr+16|0,ci=no,!((F|0)>0|(F|0)==0&P>>>0>0))return ci=0,qr=no,ci|0;if((Ie|0)>=16)return ci=12,qr=no,ci|0;Jn=0,ui=0,pn=0,Ze=0;e:for(;;){if(rr=D+(Jn<<3)|0,Ot=w[rr>>2]|0,rr=w[rr+4>>2]|0,mr=Rr(Ot|0,rr|0,52)|0,xr()|0,(mr&15|0)>(Ie|0)){Ze=12,Ot=11;break}if(Am(ci,Ot,rr,Ie),mr=ci,rr=w[mr>>2]|0,mr=w[mr+4>>2]|0,(rr|0)==0&(mr|0)==0)Ot=pn;else{Ot=pn;do{if(!((Ze|0)<(Ae|0)|(Ze|0)==(Ae|0)&Ot>>>0>>0)){Ot=10;break e}pn=q+(Ot<<3)|0,w[pn>>2]=rr,w[pn+4>>2]=mr,Ot=Gs(Ot|0,Ze|0,1,0)|0,Ze=xr()|0,_0(ci),pn=ci,rr=w[pn>>2]|0,mr=w[pn+4>>2]|0}while(!((rr|0)==0&(mr|0)==0))}if(Jn=Gs(Jn|0,ui|0,1,0)|0,ui=xr()|0,(ui|0)<(F|0)|(ui|0)==(F|0)&Jn>>>0

>>0)pn=Ot;else{Ze=0,Ot=11;break}}return(Ot|0)==10?(ci=14,qr=no,ci|0):(Ot|0)==11?(qr=no,Ze|0):0}function zp(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0;Jn=qr,qr=qr+16|0,pn=Jn;e:do if((F|0)>0|(F|0)==0&P>>>0>0){for(rr=0,Ie=0,Ae=0,mr=0;;){if(Ot=D+(rr<<3)|0,Ze=w[Ot>>2]|0,Ot=w[Ot+4>>2]|0,!((Ze|0)==0&(Ot|0)==0)&&(Ot=(H0(Ze,Ot,q,pn)|0)==0,Ze=pn,Ie=Gs(w[Ze>>2]|0,w[Ze+4>>2]|0,Ie|0,Ae|0)|0,Ae=xr()|0,!Ot)){Ae=12;break}if(rr=Gs(rr|0,mr|0,1,0)|0,mr=xr()|0,!((mr|0)<(F|0)|(mr|0)==(F|0)&rr>>>0

>>0))break e}return qr=Jn,Ae|0}else Ie=0,Ae=0;while(0);return w[fe>>2]=Ie,w[fe+4>>2]=Ae,fe=0,qr=Jn,fe|0}function c0(D,P){return D=D|0,P=P|0,P=Rr(D|0,P|0,52)|0,xr()|0,P&1|0}function Ep(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0;if(fe=Rr(D|0,P|0,52)|0,xr()|0,fe=fe&15,!fe)return fe=0,fe|0;for(q=1;;){if(F=Rr(D|0,P|0,(15-q|0)*3|0)|0,xr()|0,F=F&7,F|0){q=5;break}if(q>>>0>>0)q=q+1|0;else{F=0,q=5;break}}return(q|0)==5?F|0:0}function D0(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0;if(Ot=Rr(D|0,P|0,52)|0,xr()|0,Ot=Ot&15,!Ot)return Ze=P,Ot=D,Ai(Ze|0),Ot|0;for(Ze=1,F=0;;){Ae=(15-Ze|0)*3|0,q=sr(7,0,Ae|0)|0,fe=xr()|0,Ie=Rr(D|0,P|0,Ae|0)|0,xr()|0,Ae=sr(r0(Ie&7)|0,0,Ae|0)|0,Ie=xr()|0,D=Ae|D&~q,P=Ie|P&~fe;e:do if(!F)if((Ae&q|0)==0&(Ie&fe|0)==0)F=0;else if(q=Rr(D|0,P|0,52)|0,xr()|0,q=q&15,!q)F=1;else{F=1;t:for(;;){switch(Ie=Rr(D|0,P|0,(15-F|0)*3|0)|0,xr()|0,Ie&7){case 1:break t;case 0:break;default:{F=1;break e}}if(F>>>0>>0)F=F+1|0;else{F=1;break e}}for(F=1;;)if(Ie=(15-F|0)*3|0,fe=Rr(D|0,P|0,Ie|0)|0,xr()|0,Ae=sr(7,0,Ie|0)|0,P=P&~(xr()|0),Ie=sr(r0(fe&7)|0,0,Ie|0)|0,D=D&~Ae|Ie,P=P|(xr()|0),F>>>0>>0)F=F+1|0;else{F=1;break}}while(0);if(Ze>>>0>>0)Ze=Ze+1|0;else break}return Ai(P|0),D|0}function Pp(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0,Ie=0;if(q=Rr(D|0,P|0,52)|0,xr()|0,q=q&15,!q)return F=P,q=D,Ai(F|0),q|0;for(F=1;Ae=(15-F|0)*3|0,Ie=Rr(D|0,P|0,Ae|0)|0,xr()|0,fe=sr(7,0,Ae|0)|0,P=P&~(xr()|0),Ae=sr(r0(Ie&7)|0,0,Ae|0)|0,D=Ae|D&~fe,P=xr()|0|P,F>>>0>>0;)F=F+1|0;return Ai(P|0),D|0}function ap(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0;if(Ot=Rr(D|0,P|0,52)|0,xr()|0,Ot=Ot&15,!Ot)return Ze=P,Ot=D,Ai(Ze|0),Ot|0;for(Ze=1,F=0;;){Ae=(15-Ze|0)*3|0,q=sr(7,0,Ae|0)|0,fe=xr()|0,Ie=Rr(D|0,P|0,Ae|0)|0,xr()|0,Ae=sr(hp(Ie&7)|0,0,Ae|0)|0,Ie=xr()|0,D=Ae|D&~q,P=Ie|P&~fe;e:do if(!F)if((Ae&q|0)==0&(Ie&fe|0)==0)F=0;else if(q=Rr(D|0,P|0,52)|0,xr()|0,q=q&15,!q)F=1;else{F=1;t:for(;;){switch(Ie=Rr(D|0,P|0,(15-F|0)*3|0)|0,xr()|0,Ie&7){case 1:break t;case 0:break;default:{F=1;break e}}if(F>>>0>>0)F=F+1|0;else{F=1;break e}}for(F=1;;)if(fe=(15-F|0)*3|0,Ae=sr(7,0,fe|0)|0,Ie=P&~(xr()|0),P=Rr(D|0,P|0,fe|0)|0,xr()|0,P=sr(hp(P&7)|0,0,fe|0)|0,D=D&~Ae|P,P=Ie|(xr()|0),F>>>0>>0)F=F+1|0;else{F=1;break}}while(0);if(Ze>>>0>>0)Ze=Ze+1|0;else break}return Ai(P|0),D|0}function Zp(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0,Ie=0;if(q=Rr(D|0,P|0,52)|0,xr()|0,q=q&15,!q)return F=P,q=D,Ai(F|0),q|0;for(F=1;Ie=(15-F|0)*3|0,Ae=sr(7,0,Ie|0)|0,fe=P&~(xr()|0),P=Rr(D|0,P|0,Ie|0)|0,xr()|0,P=sr(hp(P&7)|0,0,Ie|0)|0,D=P|D&~Ae,P=xr()|0|fe,F>>>0>>0;)F=F+1|0;return Ai(P|0),D|0}function xd(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0;if(Ot=qr,qr=qr+64|0,Ze=Ot+40|0,q=Ot+24|0,fe=Ot+12|0,Ae=Ot,sr(P|0,0,52)|0,F=xr()|0|134225919,!P)return(w[D+4>>2]|0)>2||(w[D+8>>2]|0)>2||(w[D+12>>2]|0)>2?(Ie=0,Ze=0,Ai(Ie|0),qr=Ot,Ze|0):(sr(Ud(D)|0,0,45)|0,Ie=xr()|0|F,Ze=-1,Ai(Ie|0),qr=Ot,Ze|0);if(w[Ze>>2]=w[D>>2],w[Ze+4>>2]=w[D+4>>2],w[Ze+8>>2]=w[D+8>>2],w[Ze+12>>2]=w[D+12>>2],Ie=Ze+4|0,(P|0)>0)for(D=-1;w[q>>2]=w[Ie>>2],w[q+4>>2]=w[Ie+4>>2],w[q+8>>2]=w[Ie+8>>2],P&1?(xp(Ie),w[fe>>2]=w[Ie>>2],w[fe+4>>2]=w[Ie+4>>2],w[fe+8>>2]=w[Ie+8>>2],x0(fe)):(U0(Ie),w[fe>>2]=w[Ie>>2],w[fe+4>>2]=w[Ie+4>>2],w[fe+8>>2]=w[Ie+8>>2],t0(fe)),Jh(q,fe,Ae),Vf(Ae),mr=(15-P|0)*3|0,rr=sr(7,0,mr|0)|0,F=F&~(xr()|0),mr=sr(b0(Ae)|0,0,mr|0)|0,D=mr|D&~rr,F=xr()|0|F,(P|0)>1;)P=P+-1|0;else D=-1;e:do if((w[Ie>>2]|0)<=2&&(w[Ze+8>>2]|0)<=2&&(w[Ze+12>>2]|0)<=2){if(q=Ud(Ze)|0,P=sr(q|0,0,45)|0,P=P|D,D=xr()|0|F&-1040385,Ae=Qh(Ze)|0,!(Ff(q)|0)){if((Ae|0)<=0)break;for(fe=0;;){if(q=Rr(P|0,D|0,52)|0,xr()|0,q=q&15,q)for(F=1;mr=(15-F|0)*3|0,Ze=Rr(P|0,D|0,mr|0)|0,xr()|0,rr=sr(7,0,mr|0)|0,D=D&~(xr()|0),mr=sr(r0(Ze&7)|0,0,mr|0)|0,P=P&~rr|mr,D=D|(xr()|0),F>>>0>>0;)F=F+1|0;if(fe=fe+1|0,(fe|0)==(Ae|0))break e}}fe=Rr(P|0,D|0,52)|0,xr()|0,fe=fe&15;t:do if(fe){F=1;r:for(;;){switch(mr=Rr(P|0,D|0,(15-F|0)*3|0)|0,xr()|0,mr&7){case 1:break r;case 0:break;default:break t}if(F>>>0>>0)F=F+1|0;else break t}if(qf(q,w[Ze>>2]|0)|0)for(F=1;Ze=(15-F|0)*3|0,rr=sr(7,0,Ze|0)|0,mr=D&~(xr()|0),D=Rr(P|0,D|0,Ze|0)|0,xr()|0,D=sr(hp(D&7)|0,0,Ze|0)|0,P=P&~rr|D,D=mr|(xr()|0),F>>>0>>0;)F=F+1|0;else for(F=1;mr=(15-F|0)*3|0,Ze=Rr(P|0,D|0,mr|0)|0,xr()|0,rr=sr(7,0,mr|0)|0,D=D&~(xr()|0),mr=sr(r0(Ze&7)|0,0,mr|0)|0,P=P&~rr|mr,D=D|(xr()|0),F>>>0>>0;)F=F+1|0}while(0);if((Ae|0)>0){F=0;do P=D0(P,D)|0,D=xr()|0,F=F+1|0;while((F|0)!=(Ae|0))}}else P=0,D=0;while(0);return rr=D,mr=P,Ai(rr|0),qr=Ot,mr|0}function jd(D){return D=D|0,(D|0)%2|0|0}function qp(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0;return fe=qr,qr=qr+16|0,q=fe,P>>>0>15?(q=4,qr=fe,q|0):(w[D+4>>2]&2146435072|0)==2146435072||(w[D+8+4>>2]&2146435072|0)==2146435072?(q=3,qr=fe,q|0):(ad(D,P,q),P=xd(q,P)|0,q=xr()|0,w[F>>2]=P,w[F+4>>2]=q,(P|0)==0&(q|0)==0&&Ni(23313,22674,786,22697),q=0,qr=fe,q|0)}function Ip(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0;if(fe=F+4|0,Ae=Rr(D|0,P|0,52)|0,xr()|0,Ae=Ae&15,Ie=Rr(D|0,P|0,45)|0,xr()|0,q=(Ae|0)==0,Ff(Ie&127)|0){if(q)return Ie=1,Ie|0;q=1}else{if(q)return Ie=0,Ie|0;!(w[fe>>2]|0)&&!(w[F+8>>2]|0)?q=(w[F+12>>2]|0)!=0&1:q=1}for(F=1;F&1?x0(fe):t0(fe),Ie=Rr(D|0,P|0,(15-F|0)*3|0)|0,xr()|0,np(fe,Ie&7),F>>>0>>0;)F=F+1|0;return q|0}function yp(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0;if(mr=qr,qr=qr+16|0,Ot=mr,rr=Rr(D|0,P|0,45)|0,xr()|0,rr=rr&127,rr>>>0>121)return w[F>>2]=0,w[F+4>>2]=0,w[F+8>>2]=0,w[F+12>>2]=0,rr=5,qr=mr,rr|0;e:do if(Ff(rr)|0&&(Ae=Rr(D|0,P|0,52)|0,xr()|0,Ae=Ae&15,(Ae|0)!=0)){q=1;t:for(;;){switch(Ze=Rr(D|0,P|0,(15-q|0)*3|0)|0,xr()|0,Ze&7){case 5:break t;case 0:break;default:{q=P;break e}}if(q>>>0>>0)q=q+1|0;else{q=P;break e}}for(fe=1,q=P;P=(15-fe|0)*3|0,Ie=sr(7,0,P|0)|0,Ze=q&~(xr()|0),q=Rr(D|0,q|0,P|0)|0,xr()|0,q=sr(hp(q&7)|0,0,P|0)|0,D=D&~Ie|q,q=Ze|(xr()|0),fe>>>0>>0;)fe=fe+1|0}else q=P;while(0);if(Ze=7696+(rr*28|0)|0,w[F>>2]=w[Ze>>2],w[F+4>>2]=w[Ze+4>>2],w[F+8>>2]=w[Ze+8>>2],w[F+12>>2]=w[Ze+12>>2],!(Ip(D,q,F)|0))return rr=0,qr=mr,rr|0;if(Ie=F+4|0,w[Ot>>2]=w[Ie>>2],w[Ot+4>>2]=w[Ie+4>>2],w[Ot+8>>2]=w[Ie+8>>2],Ae=Rr(D|0,q|0,52)|0,xr()|0,Ze=Ae&15,Ae&1?(t0(Ie),Ae=Ze+1|0):Ae=Ze,!(Ff(rr)|0))q=0;else{e:do if(!Ze)q=0;else for(P=1;;){if(fe=Rr(D|0,q|0,(15-P|0)*3|0)|0,xr()|0,fe=fe&7,fe|0){q=fe;break e}if(P>>>0>>0)P=P+1|0;else{q=0;break}}while(0);q=(q|0)==4&1}if(!(Bp(F,Ae,q,0)|0))(Ae|0)!=(Ze|0)&&(w[Ie>>2]=w[Ot>>2],w[Ie+4>>2]=w[Ot+4>>2],w[Ie+8>>2]=w[Ot+8>>2]);else{if(Ff(rr)|0)do;while(Bp(F,Ae,0,0)|0);(Ae|0)!=(Ze|0)&&U0(Ie)}return rr=0,qr=mr,rr|0}function i0(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0;return Ae=qr,qr=qr+16|0,q=Ae,fe=yp(D,P,q)|0,fe|0?(qr=Ae,fe|0):(fe=Rr(D|0,P|0,52)|0,xr()|0,gd(q,fe&15,F),fe=0,qr=Ae,fe|0)}function f0(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0;if(Ie=qr,qr=qr+16|0,Ae=Ie,q=yp(D,P,Ae)|0,q|0)return Ae=q,qr=Ie,Ae|0;q=Rr(D|0,P|0,45)|0,xr()|0,q=(Ff(q&127)|0)==0,fe=Rr(D|0,P|0,52)|0,xr()|0,fe=fe&15;e:do if(!q){if(fe|0)for(q=1;;){if(Ze=sr(7,0,(15-q|0)*3|0)|0,!((Ze&D|0)==0&((xr()|0)&P|0)==0))break e;if(q>>>0>>0)q=q+1|0;else break}return ip(Ae,fe,0,5,F),Ze=0,qr=Ie,Ze|0}while(0);return pd(Ae,fe,0,6,F),Ze=0,qr=Ie,Ze|0}function sm(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0;if(fe=Rr(D|0,P|0,45)|0,xr()|0,!(Ff(fe&127)|0))return fe=2,w[F>>2]=fe,0;if(fe=Rr(D|0,P|0,52)|0,xr()|0,fe=fe&15,!fe)return fe=5,w[F>>2]=fe,0;for(q=1;;){if(Ae=sr(7,0,(15-q|0)*3|0)|0,!((Ae&D|0)==0&((xr()|0)&P|0)==0)){q=2,D=6;break}if(q>>>0>>0)q=q+1|0;else{q=5,D=6;break}}return(D|0)==6&&(w[F>>2]=q),0}function p0(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0;pn=qr,qr=qr+128|0,rr=pn+112|0,Ae=pn+96|0,mr=pn,fe=Rr(D|0,P|0,52)|0,xr()|0,Ze=fe&15,w[rr>>2]=Ze,Ie=Rr(D|0,P|0,45)|0,xr()|0,Ie=Ie&127;e:do if(Ff(Ie)|0){if(Ze|0)for(q=1;;){if(Ot=sr(7,0,(15-q|0)*3|0)|0,!((Ot&D|0)==0&((xr()|0)&P|0)==0)){fe=0;break e}if(q>>>0>>0)q=q+1|0;else break}if(fe&1)fe=1;else return Ot=sr(Ze+1|0,0,52)|0,mr=xr()|0|P&-15728641,rr=sr(7,0,(14-Ze|0)*3|0)|0,mr=p0((Ot|D)&~rr,mr&~(xr()|0),F)|0,qr=pn,mr|0}else fe=0;while(0);if(q=yp(D,P,Ae)|0,!q){fe?(O0(Ae,rr,mr),Ot=5):(Kp(Ae,rr,mr),Ot=6);e:do if(Ff(Ie)|0)if(!Ze)D=5;else for(q=1;;){if(Ie=sr(7,0,(15-q|0)*3|0)|0,!((Ie&D|0)==0&((xr()|0)&P|0)==0)){D=2;break e}if(q>>>0>>0)q=q+1|0;else{D=5;break}}else D=2;while(0);ji(F|0,-1,D<<2|0)|0;e:do if(fe)for(Ae=0;;){if(Ie=mr+(Ae<<4)|0,$0(Ie,w[rr>>2]|0)|0,Ie=w[Ie>>2]|0,Ze=w[F>>2]|0,(Ze|0)==-1|(Ze|0)==(Ie|0))q=F;else{fe=0;do{if(fe=fe+1|0,fe>>>0>=D>>>0){q=1;break e}q=F+(fe<<2)|0,Ze=w[q>>2]|0}while(!((Ze|0)==-1|(Ze|0)==(Ie|0)))}if(w[q>>2]=Ie,Ae=Ae+1|0,Ae>>>0>=Ot>>>0){q=0;break}}else for(Ae=0;;){if(Ie=mr+(Ae<<4)|0,Bp(Ie,w[rr>>2]|0,0,1)|0,Ie=w[Ie>>2]|0,Ze=w[F>>2]|0,(Ze|0)==-1|(Ze|0)==(Ie|0))q=F;else{fe=0;do{if(fe=fe+1|0,fe>>>0>=D>>>0){q=1;break e}q=F+(fe<<2)|0,Ze=w[q>>2]|0}while(!((Ze|0)==-1|(Ze|0)==(Ie|0)))}if(w[q>>2]=Ie,Ae=Ae+1|0,Ae>>>0>=Ot>>>0){q=0;break}}while(0)}return mr=q,qr=pn,mr|0}function Id(){return 12}function Rd(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0;if(D>>>0>15)return Ze=4,Ze|0;if(sr(D|0,0,52)|0,Ze=xr()|0|134225919,!D){F=0,q=0;do Ff(q)|0&&(sr(q|0,0,45)|0,Ie=Ze|(xr()|0),D=P+(F<<3)|0,w[D>>2]=-1,w[D+4>>2]=Ie,F=F+1|0),q=q+1|0;while((q|0)!=122);return F=0,F|0}F=0,Ie=0;do{if(Ff(Ie)|0){for(sr(Ie|0,0,45)|0,q=1,fe=-1,Ae=Ze|(xr()|0);Ot=sr(7,0,(15-q|0)*3|0)|0,fe=fe&~Ot,Ae=Ae&~(xr()|0),(q|0)!=(D|0);)q=q+1|0;Ot=P+(F<<3)|0,w[Ot>>2]=fe,w[Ot+4>>2]=Ae,F=F+1|0}Ie=Ie+1|0}while((Ie|0)!=122);return F=0,F|0}function Fd(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0,Go=0;if(Go=qr,qr=qr+16|0,Wa=Go,ha=Rr(D|0,P|0,52)|0,xr()|0,ha=ha&15,F>>>0>15)return ha=4,qr=Go,ha|0;if((ha|0)<(F|0))return ha=12,qr=Go,ha|0;if((ha|0)!=(F|0))if(Ae=sr(F|0,0,52)|0,Ae=Ae|D,Ze=xr()|0|P&-15728641,(ha|0)>(F|0)){Ot=F;do no=sr(7,0,(14-Ot|0)*3|0)|0,Ot=Ot+1|0,Ae=no|Ae,Ze=xr()|0|Ze;while((Ot|0)<(ha|0));no=Ae}else no=Ae;else no=D,Ze=P;ci=Rr(no|0,Ze|0,45)|0,xr()|0;e:do if(Ff(ci&127)|0){if(Ot=Rr(no|0,Ze|0,52)|0,xr()|0,Ot=Ot&15,Ot|0)for(Ae=1;;){if(ci=sr(7,0,(15-Ae|0)*3|0)|0,!((ci&no|0)==0&((xr()|0)&Ze|0)==0)){rr=33;break e}if(Ae>>>0>>0)Ae=Ae+1|0;else break}if(ci=q,w[ci>>2]=0,w[ci+4>>2]=0,(ha|0)>(F|0)){for(ci=P&-15728641,ui=ha;;){if(Jn=ui,ui=ui+-1|0,ui>>>0>15|(ha|0)<(ui|0)){rr=19;break}if((ha|0)!=(ui|0))if(Ae=sr(ui|0,0,52)|0,Ae=Ae|D,Ot=xr()|0|ci,(ha|0)<(Jn|0))pn=Ae;else{rr=ui;do pn=sr(7,0,(14-rr|0)*3|0)|0,rr=rr+1|0,Ae=pn|Ae,Ot=xr()|0|Ot;while((rr|0)<(ha|0));pn=Ae}else pn=D,Ot=P;if(mr=Rr(pn|0,Ot|0,45)|0,xr()|0,!(Ff(mr&127)|0))Ae=0;else{mr=Rr(pn|0,Ot|0,52)|0,xr()|0,mr=mr&15;t:do if(!mr)Ae=0;else for(rr=1;;){if(Ae=Rr(pn|0,Ot|0,(15-rr|0)*3|0)|0,xr()|0,Ae=Ae&7,Ae|0)break t;if(rr>>>0>>0)rr=rr+1|0;else{Ae=0;break}}while(0);Ae=(Ae|0)==0&1}if(Ot=Rr(D|0,P|0,(15-Jn|0)*3|0)|0,xr()|0,Ot=Ot&7,(Ot|0)==7){fe=5,rr=42;break}if(Ae=(Ae|0)!=0,(Ot|0)==1&Ae){fe=5,rr=42;break}if(pn=Ot+(((Ot|0)!=0&Ae)<<31>>31)|0,pn|0&&(rr=ha-Jn|0,rr=co(7,0,rr,((rr|0)<0)<<31>>31)|0,mr=xr()|0,Ae?(Ae=ao(rr|0,mr|0,5,0)|0,Ae=Gs(Ae|0,xr()|0,-5,-1)|0,Ae=ei(Ae|0,xr()|0,6,0)|0,Ae=Gs(Ae|0,xr()|0,1,0)|0,Ot=xr()|0):(Ae=rr,Ot=mr),Jn=pn+-1|0,Jn=ao(rr|0,mr|0,Jn|0,((Jn|0)<0)<<31>>31|0)|0,Jn=Gs(Ae|0,Ot|0,Jn|0,xr()|0)|0,pn=xr()|0,mr=q,mr=Gs(Jn|0,pn|0,w[mr>>2]|0,w[mr+4>>2]|0)|0,pn=xr()|0,Jn=q,w[Jn>>2]=mr,w[Jn+4>>2]=pn),(ui|0)<=(F|0)){rr=37;break}}if((rr|0)==19)Ni(23313,22674,1099,22710);else if((rr|0)==37){Ie=q,fe=w[Ie+4>>2]|0,Ie=w[Ie>>2]|0;break}else if((rr|0)==42)return qr=Go,fe|0}else fe=0,Ie=0}else rr=33;while(0);e:do if((rr|0)==33)if(ci=q,w[ci>>2]=0,w[ci+4>>2]=0,(ha|0)>(F|0)){for(Ae=ha;;){if(fe=Rr(D|0,P|0,(15-Ae|0)*3|0)|0,xr()|0,fe=fe&7,(fe|0)==7){fe=5;break}if(Ie=ha-Ae|0,Ie=co(7,0,Ie,((Ie|0)<0)<<31>>31)|0,fe=ao(Ie|0,xr()|0,fe|0,0)|0,Ie=xr()|0,ci=q,Ie=Gs(w[ci>>2]|0,w[ci+4>>2]|0,fe|0,Ie|0)|0,fe=xr()|0,ci=q,w[ci>>2]=Ie,w[ci+4>>2]=fe,Ae=Ae+-1|0,(Ae|0)<=(F|0))break e}return qr=Go,fe|0}else fe=0,Ie=0;while(0);return H0(no,Ze,ha,Wa)|0&&Ni(23313,22674,1063,22725),ha=Wa,Wa=w[ha+4>>2]|0,((fe|0)>-1|(fe|0)==-1&Ie>>>0>4294967295)&((Wa|0)>(fe|0)|((Wa|0)==(fe|0)?(w[ha>>2]|0)>>>0>Ie>>>0:0))?(ha=0,qr=Go,ha|0):(Ni(23313,22674,1139,22710),0)}function Up(D,P,F,q,fe,Ae){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0,Ae=Ae|0;var Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0;if(pn=qr,qr=qr+16|0,Ie=pn,fe>>>0>15)return Ae=4,qr=pn,Ae|0;if(Ze=Rr(F|0,q|0,52)|0,xr()|0,Ze=Ze&15,(Ze|0)>(fe|0))return Ae=12,qr=pn,Ae|0;if(H0(F,q,fe,Ie)|0&&Ni(23313,22674,1063,22725),mr=Ie,rr=w[mr+4>>2]|0,!(((P|0)>-1|(P|0)==-1&D>>>0>4294967295)&((rr|0)>(P|0)|((rr|0)==(P|0)?(w[mr>>2]|0)>>>0>D>>>0:0))))return Ae=2,qr=pn,Ae|0;mr=fe-Ze|0,fe=sr(fe|0,0,52)|0,Ot=xr()|0|q&-15728641,rr=Ae,w[rr>>2]=fe|F,w[rr+4>>2]=Ot,rr=Rr(F|0,q|0,45)|0,xr()|0;e:do if(Ff(rr&127)|0){if(Ze|0)for(Ie=1;;){if(rr=sr(7,0,(15-Ie|0)*3|0)|0,!((rr&F|0)==0&((xr()|0)&q|0)==0))break e;if(Ie>>>0>>0)Ie=Ie+1|0;else break}if((mr|0)<1)return Ae=0,qr=pn,Ae|0;for(rr=Ze^15,q=-1,Ot=1,Ie=1;;){Ze=mr-Ot|0,Ze=co(7,0,Ze,((Ze|0)<0)<<31>>31)|0,F=xr()|0;do if(Ie)if(Ie=ao(Ze|0,F|0,5,0)|0,Ie=Gs(Ie|0,xr()|0,-5,-1)|0,Ie=ei(Ie|0,xr()|0,6,0)|0,fe=xr()|0,(P|0)>(fe|0)|(P|0)==(fe|0)&D>>>0>Ie>>>0){P=Gs(D|0,P|0,-1,-1)|0,P=of(P|0,xr()|0,Ie|0,fe|0)|0,Ie=xr()|0,Jn=Ae,ci=w[Jn>>2]|0,Jn=w[Jn+4>>2]|0,no=(rr+q|0)*3|0,ui=sr(7,0,no|0)|0,Jn=Jn&~(xr()|0),q=ei(P|0,Ie|0,Ze|0,F|0)|0,D=xr()|0,fe=Gs(q|0,D|0,2,0)|0,no=sr(fe|0,xr()|0,no|0)|0,Jn=xr()|0|Jn,fe=Ae,w[fe>>2]=no|ci&~ui,w[fe+4>>2]=Jn,D=ao(q|0,D|0,Ze|0,F|0)|0,D=of(P|0,Ie|0,D|0,xr()|0)|0,Ie=0,P=xr()|0;break}else{no=Ae,ui=w[no>>2]|0,no=w[no+4>>2]|0,ci=sr(7,0,(rr+q|0)*3|0)|0,no=no&~(xr()|0),Ie=Ae,w[Ie>>2]=ui&~ci,w[Ie+4>>2]=no,Ie=1;break}else ui=Ae,fe=w[ui>>2]|0,ui=w[ui+4>>2]|0,q=(rr+q|0)*3|0,Jn=sr(7,0,q|0)|0,ui=ui&~(xr()|0),no=ei(D|0,P|0,Ze|0,F|0)|0,Ie=xr()|0,q=sr(no|0,Ie|0,q|0)|0,ui=xr()|0|ui,ci=Ae,w[ci>>2]=q|fe&~Jn,w[ci+4>>2]=ui,Ie=ao(no|0,Ie|0,Ze|0,F|0)|0,D=of(D|0,P|0,Ie|0,xr()|0)|0,Ie=0,P=xr()|0;while(0);if((mr|0)>(Ot|0))q=~Ot,Ot=Ot+1|0;else{P=0;break}}return qr=pn,P|0}while(0);if((mr|0)<1)return no=0,qr=pn,no|0;for(fe=Ze^15,Ie=1;;)if(ci=mr-Ie|0,ci=co(7,0,ci,((ci|0)<0)<<31>>31)|0,no=xr()|0,Ot=Ae,F=w[Ot>>2]|0,Ot=w[Ot+4>>2]|0,Ze=(fe-Ie|0)*3|0,q=sr(7,0,Ze|0)|0,Ot=Ot&~(xr()|0),Jn=ei(D|0,P|0,ci|0,no|0)|0,ui=xr()|0,Ze=sr(Jn|0,ui|0,Ze|0)|0,Ot=xr()|0|Ot,rr=Ae,w[rr>>2]=Ze|F&~q,w[rr+4>>2]=Ot,no=ao(Jn|0,ui|0,ci|0,no|0)|0,D=of(D|0,P|0,no|0,xr()|0)|0,P=xr()|0,(mr|0)<=(Ie|0)){P=0;break}else Ie=Ie+1|0;return qr=pn,P|0}function Am(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0;fe=Rr(P|0,F|0,52)|0,xr()|0,fe=fe&15,(P|0)==0&(F|0)==0|((q|0)>15|(fe|0)>(q|0))?(q=-1,fe=-1,P=0,F=0):(Ae=n0(P,F,fe+1|0,q)|0,F=(xr()|0)&-15728641,P=sr(q|0,0,52)|0,P=Ae|P,F=F|(xr()|0),Ae=(gh(P,F)|0)==0,q=Ae?-1:q),Ae=D,w[Ae>>2]=P,w[Ae+4>>2]=F,w[D+8>>2]=fe,w[D+12>>2]=q}function _0(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0;if(F=D,P=w[F>>2]|0,F=w[F+4>>2]|0,!((P|0)==0&(F|0)==0)&&(q=Rr(P|0,F|0,52)|0,xr()|0,q=q&15,Ze=sr(1,0,(q^15)*3|0)|0,P=Gs(Ze|0,xr()|0,P|0,F|0)|0,F=xr()|0,Ze=D,w[Ze>>2]=P,w[Ze+4>>2]=F,Ze=D+8|0,Ie=w[Ze>>2]|0,!((q|0)<(Ie|0)))){for(Ot=D+12|0,Ae=q;;){if((Ae|0)==(Ie|0)){q=5;break}if(rr=(Ae|0)==(w[Ot>>2]|0),fe=(15-Ae|0)*3|0,q=Rr(P|0,F|0,fe|0)|0,xr()|0,q=q&7,rr&((q|0)==1&!0)){q=7;break}if(!((q|0)==7&!0)){q=10;break}if(rr=sr(1,0,fe|0)|0,P=Gs(P|0,F|0,rr|0,xr()|0)|0,F=xr()|0,rr=D,w[rr>>2]=P,w[rr+4>>2]=F,(Ae|0)>(Ie|0))Ae=Ae+-1|0;else{q=10;break}}if((q|0)==5){rr=D,w[rr>>2]=0,w[rr+4>>2]=0,w[Ze>>2]=-1,w[Ot>>2]=-1;return}else if((q|0)==7){Ie=sr(1,0,fe|0)|0,Ie=Gs(P|0,F|0,Ie|0,xr()|0)|0,Ze=xr()|0,rr=D,w[rr>>2]=Ie,w[rr+4>>2]=Ze,w[Ot>>2]=Ae+-1;return}else if((q|0)==10)return}}function k0(D){D=+D;var P=0;return P=D<0?D+6.283185307179586:D,+(D>=6.283185307179586?P+-6.283185307179586:P)}function jp(D,P){return D=D|0,P=P|0,+Ce(+(+x[D>>3]-+x[P>>3]))<17453292519943298e-27?(P=+Ce(+(+x[D+8>>3]-+x[P+8>>3]))<17453292519943298e-27,P|0):(P=0,P|0)}function F0(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0;return fe=+x[P>>3],q=+x[D>>3],Ae=+Tt(+((fe-q)*.5)),F=+Tt(+((+x[P+8>>3]-+x[D+8>>3])*.5)),F=Ae*Ae+F*(+zt(+fe)*+zt(+q)*F),+(+jr(+ +Oe(+F),+ +Oe(+(1-F)))*2)}function Sp(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0;return fe=+x[P>>3],q=+x[D>>3],Ae=+Tt(+((fe-q)*.5)),F=+Tt(+((+x[P+8>>3]-+x[D+8>>3])*.5)),F=Ae*Ae+F*(+zt(+fe)*+zt(+q)*F),+(+jr(+ +Oe(+F),+ +Oe(+(1-F)))*2*6371.007180918475)}function df(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0;return fe=+x[P>>3],q=+x[D>>3],Ae=+Tt(+((fe-q)*.5)),F=+Tt(+((+x[P+8>>3]-+x[D+8>>3])*.5)),F=Ae*Ae+F*(+zt(+fe)*+zt(+q)*F),+(+jr(+ +Oe(+F),+ +Oe(+(1-F)))*2*6371.007180918475*1e3)}function um(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0,Ie=0;return Ae=+x[P>>3],q=+zt(+Ae),fe=+x[P+8>>3]-+x[D+8>>3],Ie=q*+Tt(+fe),F=+x[D>>3],+ +jr(+Ie,+(+Tt(+Ae)*+zt(+F)-+zt(+fe)*(q*+Tt(+F))))}function Vh(D,P,F,q){D=D|0,P=+P,F=+F,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0;if(F<1e-16){w[q>>2]=w[D>>2],w[q+4>>2]=w[D+4>>2],w[q+8>>2]=w[D+8>>2],w[q+12>>2]=w[D+12>>2];return}Ae=P<0?P+6.283185307179586:P,Ae=P>=6.283185307179586?Ae+-6.283185307179586:Ae;do if(Ae<1e-16)P=+x[D>>3]+F,x[q>>3]=P,fe=q;else{if(fe=+Ce(+(Ae+-3.141592653589793))<1e-16,P=+x[D>>3],fe){P=P-F,x[q>>3]=P,fe=q;break}if(Ie=+zt(+F),F=+Tt(+F),P=Ie*+Tt(+P)+ +zt(+Ae)*(F*+zt(+P)),P=P>1?1:P,P=+pr(+(P<-1?-1:P)),x[q>>3]=P,+Ce(+(P+-1.5707963267948966))<1e-16){x[q>>3]=1.5707963267948966,x[q+8>>3]=0;return}if(+Ce(+(P+1.5707963267948966))<1e-16){x[q>>3]=-1.5707963267948966,x[q+8>>3]=0;return}if(Ze=+zt(+P),Ae=F*+Tt(+Ae)/Ze,F=+x[D>>3],P=(Ie-+Tt(+P)*+Tt(+F))/+zt(+F)/Ze,Ie=Ae>1?1:Ae,P=P>1?1:P,P=+x[D+8>>3]+ +jr(+(Ie<-1?-1:Ie),+(P<-1?-1:P)),P>3.141592653589793)do P=P+-6.283185307179586;while(P>3.141592653589793);if(P<-3.141592653589793)do P=P+6.283185307179586;while(P<-3.141592653589793);x[q+8>>3]=P;return}while(0);if(+Ce(+(P+-1.5707963267948966))<1e-16){x[fe>>3]=1.5707963267948966,x[q+8>>3]=0;return}if(+Ce(+(P+1.5707963267948966))<1e-16){x[fe>>3]=-1.5707963267948966,x[q+8>>3]=0;return}if(P=+x[D+8>>3],P>3.141592653589793)do P=P+-6.283185307179586;while(P>3.141592653589793);if(P<-3.141592653589793)do P=P+6.283185307179586;while(P<-3.141592653589793);x[q+8>>3]=P}function B0(D,P){return D=D|0,P=P|0,D>>>0>15?(P=4,P|0):(x[P>>3]=+x[20528+(D<<3)>>3],P=0,P|0)}function mp(D,P){return D=D|0,P=P|0,D>>>0>15?(P=4,P|0):(x[P>>3]=+x[20656+(D<<3)>>3],P=0,P|0)}function J0(D,P){return D=D|0,P=P|0,D>>>0>15?(P=4,P|0):(x[P>>3]=+x[20784+(D<<3)>>3],P=0,P|0)}function G0(D,P){return D=D|0,P=P|0,D>>>0>15?(P=4,P|0):(x[P>>3]=+x[20912+(D<<3)>>3],P=0,P|0)}function W0(D,P){D=D|0,P=P|0;var F=0;return D>>>0>15?(P=4,P|0):(F=co(7,0,D,((D|0)<0)<<31>>31)|0,F=ao(F|0,xr()|0,120,0)|0,D=xr()|0,w[P>>2]=F|2,w[P+4>>2]=D,P=0,P|0)}function Td(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0;return Jn=+x[P>>3],mr=+x[D>>3],Ot=+Tt(+((Jn-mr)*.5)),Ae=+x[P+8>>3],rr=+x[D+8>>3],Ie=+Tt(+((Ae-rr)*.5)),Ze=+zt(+mr),pn=+zt(+Jn),Ie=Ot*Ot+Ie*(pn*Ze*Ie),Ie=+jr(+ +Oe(+Ie),+ +Oe(+(1-Ie)))*2,Ot=+x[F>>3],Jn=+Tt(+((Ot-Jn)*.5)),q=+x[F+8>>3],Ae=+Tt(+((q-Ae)*.5)),fe=+zt(+Ot),Ae=Jn*Jn+Ae*(pn*fe*Ae),Ae=+jr(+ +Oe(+Ae),+ +Oe(+(1-Ae)))*2,Ot=+Tt(+((mr-Ot)*.5)),q=+Tt(+((rr-q)*.5)),q=Ot*Ot+q*(Ze*fe*q),q=+jr(+ +Oe(+q),+ +Oe(+(1-q)))*2,fe=(Ie+Ae+q)*.5,+(+zr(+ +Oe(+(+Qt(+(fe*.5))*+Qt(+((fe-Ie)*.5))*+Qt(+((fe-Ae)*.5))*+Qt(+((fe-q)*.5)))))*4)}function o0(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0;if(Ze=qr,qr=qr+192|0,Ae=Ze+168|0,Ie=Ze,fe=i0(D,P,Ae)|0,fe|0)return F=fe,qr=Ze,F|0;if(f0(D,P,Ie)|0&&Ni(23313,22742,386,22751),P=w[Ie>>2]|0,(P|0)>0){if(q=+Td(Ie+8|0,Ie+8+(((P|0)!=1&1)<<4)|0,Ae)+0,(P|0)!=1){D=1;do fe=D,D=D+1|0,q=q+ +Td(Ie+8+(fe<<4)|0,Ie+8+(((D|0)%(P|0)|0)<<4)|0,Ae);while((D|0)<(P|0))}}else q=0;return x[F>>3]=q,F=0,qr=Ze,F|0}function m0(D,P,F){return D=D|0,P=P|0,F=F|0,D=o0(D,P,F)|0,D|0||(x[F>>3]=+x[F>>3]*6371.007180918475*6371.007180918475),D|0}function Vd(D,P,F){return D=D|0,P=P|0,F=F|0,D=o0(D,P,F)|0,D|0||(x[F>>3]=+x[F>>3]*6371.007180918475*6371.007180918475*1e3*1e3),D|0}function _r(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0;if(Ze=qr,qr=qr+176|0,Ie=Ze,D=w0(D,P,Ie)|0,D|0)return Ie=D,qr=Ze,Ie|0;if(x[F>>3]=0,D=w[Ie>>2]|0,(D|0)<=1)return Ie=0,qr=Ze,Ie|0;P=D+-1|0,D=0,q=+x[Ie+8>>3],fe=+x[Ie+16>>3],Ae=0;do D=D+1|0,rr=q,q=+x[Ie+8+(D<<4)>>3],mr=+Tt(+((q-rr)*.5)),Ot=fe,fe=+x[Ie+8+(D<<4)+8>>3],Ot=+Tt(+((fe-Ot)*.5)),Ot=mr*mr+Ot*(+zt(+q)*+zt(+rr)*Ot),Ae=Ae+ +jr(+ +Oe(+Ot),+ +Oe(+(1-Ot)))*2;while((D|0)<(P|0));return x[F>>3]=Ae,Ie=0,qr=Ze,Ie|0}function Sn(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0;if(Ze=qr,qr=qr+176|0,Ie=Ze,D=w0(D,P,Ie)|0,D|0)return Ie=D,Ae=+x[F>>3],Ae=Ae*6371.007180918475,x[F>>3]=Ae,qr=Ze,Ie|0;if(x[F>>3]=0,D=w[Ie>>2]|0,(D|0)<=1)return Ie=0,Ae=0,Ae=Ae*6371.007180918475,x[F>>3]=Ae,qr=Ze,Ie|0;P=D+-1|0,D=0,q=+x[Ie+8>>3],fe=+x[Ie+16>>3],Ae=0;do D=D+1|0,rr=q,q=+x[Ie+8+(D<<4)>>3],mr=+Tt(+((q-rr)*.5)),Ot=fe,fe=+x[Ie+8+(D<<4)+8>>3],Ot=+Tt(+((fe-Ot)*.5)),Ot=mr*mr+Ot*(+zt(+rr)*+zt(+q)*Ot),Ae=Ae+ +jr(+ +Oe(+Ot),+ +Oe(+(1-Ot)))*2;while((D|0)!=(P|0));return x[F>>3]=Ae,Ie=0,mr=Ae,mr=mr*6371.007180918475,x[F>>3]=mr,qr=Ze,Ie|0}function mi(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0;if(Ze=qr,qr=qr+176|0,Ie=Ze,D=w0(D,P,Ie)|0,D|0)return Ie=D,Ae=+x[F>>3],Ae=Ae*6371.007180918475,Ae=Ae*1e3,x[F>>3]=Ae,qr=Ze,Ie|0;if(x[F>>3]=0,D=w[Ie>>2]|0,(D|0)<=1)return Ie=0,Ae=0,Ae=Ae*6371.007180918475,Ae=Ae*1e3,x[F>>3]=Ae,qr=Ze,Ie|0;P=D+-1|0,D=0,q=+x[Ie+8>>3],fe=+x[Ie+16>>3],Ae=0;do D=D+1|0,rr=q,q=+x[Ie+8+(D<<4)>>3],mr=+Tt(+((q-rr)*.5)),Ot=fe,fe=+x[Ie+8+(D<<4)+8>>3],Ot=+Tt(+((fe-Ot)*.5)),Ot=mr*mr+Ot*(+zt(+rr)*+zt(+q)*Ot),Ae=Ae+ +jr(+ +Oe(+Ot),+ +Oe(+(1-Ot)))*2;while((D|0)!=(P|0));return x[F>>3]=Ae,Ie=0,mr=Ae,mr=mr*6371.007180918475,mr=mr*1e3,x[F>>3]=mr,qr=Ze,Ie|0}function jo(D){D=D|0;var P=0,F=0,q=0;return P=hl(1,12)|0,P||Ni(22832,22787,49,22845),F=D+4|0,q=w[F>>2]|0,q|0?(q=q+8|0,w[q>>2]=P,w[F>>2]=P,P|0):(w[D>>2]|0&&Ni(22862,22787,61,22885),q=D,w[q>>2]=P,w[F>>2]=P,P|0)}function Ta(D,P){D=D|0,P=P|0;var F=0,q=0;return q=Qf(24)|0,q||Ni(22899,22787,78,22913),w[q>>2]=w[P>>2],w[q+4>>2]=w[P+4>>2],w[q+8>>2]=w[P+8>>2],w[q+12>>2]=w[P+12>>2],w[q+16>>2]=0,P=D+4|0,F=w[P>>2]|0,F|0?(w[F+16>>2]=q,w[P>>2]=q,q|0):(w[D>>2]|0&&Ni(22928,22787,82,22913),w[D>>2]=q,w[P>>2]=q,q|0)}function $o(D){D=D|0;var P=0,F=0,q=0,fe=0;if(D)for(q=1;;){if(P=w[D>>2]|0,P|0)do{if(F=w[P>>2]|0,F|0)do fe=F,F=w[F+16>>2]|0,Pu(fe);while(F|0);fe=P,P=w[P+8>>2]|0,Pu(fe)}while(P|0);if(P=D,D=w[D+8>>2]|0,q||Pu(P),D)q=0;else break}}function Po(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0,Go=0,Wo=0,To=0,El=0,gl=0,du=0,Qu=0,_h=0,Th=0,vh=0,$f=0,Nl=0,vc=0,Hh=0,Af=0;if(fe=D+8|0,w[fe>>2]|0)return Af=1,Af|0;if(q=w[D>>2]|0,!q)return Af=0,Af|0;P=q,F=0;do F=F+1|0,P=w[P+8>>2]|0;while(P|0);if(F>>>0<2)return Af=0,Af|0;vc=Qf(F<<2)|0,vc||Ni(22948,22787,317,22967),Nl=Qf(F<<5)|0,Nl||Ni(22989,22787,321,22967),w[D>>2]=0,gl=D+4|0,w[gl>>2]=0,w[fe>>2]=0,F=0,$f=0,El=0,pn=0;e:for(;;){if(mr=w[q>>2]|0,mr){Ae=0,Ie=mr;do{if(Ot=+x[Ie+8>>3],P=Ie,Ie=w[Ie+16>>2]|0,rr=(Ie|0)==0,fe=rr?mr:Ie,Ze=+x[fe+8>>3],+Ce(+(Ot-Ze))>3.141592653589793){Af=14;break}Ae=Ae+(Ze-Ot)*(+x[P>>3]+ +x[fe>>3])}while(!rr);if((Af|0)==14){Af=0,Ae=0,P=mr;do To=+x[P+8>>3],vh=P+16|0,Th=w[vh>>2]|0,Th=Th|0?Th:mr,Wo=+x[Th+8>>3],Ae=Ae+(+x[P>>3]+ +x[Th>>3])*((Wo<0?Wo+6.283185307179586:Wo)-(To<0?To+6.283185307179586:To)),P=w[(P|0?vh:q)>>2]|0;while(P|0)}Ae>0?(w[vc+($f<<2)>>2]=q,$f=$f+1|0,fe=El,P=pn):Af=19}else Af=19;if((Af|0)==19){Af=0;do if(F){if(P=F+8|0,w[P>>2]|0){Af=21;break e}if(F=hl(1,12)|0,!F){Af=23;break e}w[P>>2]=F,fe=F+4|0,Ie=F,P=pn}else if(pn){fe=gl,Ie=pn+8|0,P=q,F=D;break}else if(w[D>>2]|0){Af=27;break e}else{fe=gl,Ie=D,P=q,F=D;break}while(0);if(w[Ie>>2]=q,w[fe>>2]=q,Ie=Nl+(El<<5)|0,rr=w[q>>2]|0,rr){for(mr=Nl+(El<<5)+8|0,x[mr>>3]=17976931348623157e292,pn=Nl+(El<<5)+24|0,x[pn>>3]=17976931348623157e292,x[Ie>>3]=-17976931348623157e292,Jn=Nl+(El<<5)+16|0,x[Jn>>3]=-17976931348623157e292,ha=17976931348623157e292,Go=-17976931348623157e292,fe=0,ui=rr,Ot=17976931348623157e292,no=17976931348623157e292,Wa=-17976931348623157e292,Ze=-17976931348623157e292;Ae=+x[ui>>3],To=+x[ui+8>>3],ui=w[ui+16>>2]|0,ci=(ui|0)==0,Wo=+x[(ci?rr:ui)+8>>3],Ae>3]=Ae,Ot=Ae),To>3]=To,no=To),Ae>Wa?x[Ie>>3]=Ae:Ae=Wa,To>Ze&&(x[Jn>>3]=To,Ze=To),ha=To>0&ToGo?To:Go,fe=fe|+Ce(+(To-Wo))>3.141592653589793,!ci;)Wa=Ae;fe&&(x[Jn>>3]=Go,x[pn>>3]=ha)}else w[Ie>>2]=0,w[Ie+4>>2]=0,w[Ie+8>>2]=0,w[Ie+12>>2]=0,w[Ie+16>>2]=0,w[Ie+20>>2]=0,w[Ie+24>>2]=0,w[Ie+28>>2]=0;fe=El+1|0}if(vh=q+8|0,q=w[vh>>2]|0,w[vh>>2]=0,q)El=fe,pn=P;else{Af=45;break}}if((Af|0)==21)Ni(22765,22787,35,22799);else if((Af|0)==23)Ni(22819,22787,37,22799);else if((Af|0)==27)Ni(22862,22787,61,22885);else if((Af|0)==45){e:do if(($f|0)>0){for(vh=(fe|0)==0,_h=fe<<2,Th=(D|0)==0,Qu=0,P=0;;){if(du=w[vc+(Qu<<2)>>2]|0,vh)Af=73;else{if(El=Qf(_h)|0,!El){Af=50;break}if(gl=Qf(_h)|0,!gl){Af=52;break}t:do if(Th)F=0;else{for(fe=0,F=0,Ie=D;q=Nl+(fe<<5)|0,ds(w[Ie>>2]|0,q,w[du>>2]|0)|0?(w[El+(F<<2)>>2]=Ie,w[gl+(F<<2)>>2]=q,ci=F+1|0):ci=F,Ie=w[Ie+8>>2]|0,Ie;)fe=fe+1|0,F=ci;if((ci|0)>0)if(q=w[El>>2]|0,(ci|0)==1)F=q;else for(Jn=0,ui=-1,F=q,pn=q;;){for(rr=w[pn>>2]|0,q=0,Ie=0;fe=w[w[El+(Ie<<2)>>2]>>2]|0,(fe|0)==(rr|0)?mr=q:mr=q+((ds(fe,w[gl+(Ie<<2)>>2]|0,w[rr>>2]|0)|0)&1)|0,Ie=Ie+1|0,(Ie|0)!=(ci|0);)q=mr;if(fe=(mr|0)>(ui|0),F=fe?pn:F,q=Jn+1|0,(q|0)==(ci|0))break t;Jn=q,ui=fe?mr:ui,pn=w[El+(q<<2)>>2]|0}else F=0}while(0);if(Pu(El),Pu(gl),F){if(fe=F+4|0,q=w[fe>>2]|0,q)F=q+8|0;else if(w[F>>2]|0){Af=70;break}w[F>>2]=du,w[fe>>2]=du}else Af=73}if((Af|0)==73){if(Af=0,P=w[du>>2]|0,P|0)do gl=P,P=w[P+16>>2]|0,Pu(gl);while(P|0);Pu(du),P=1}if(Qu=Qu+1|0,(Qu|0)>=($f|0)){Hh=P;break e}}(Af|0)==50?Ni(23004,22787,249,23023):(Af|0)==52?Ni(23042,22787,252,23023):(Af|0)==70&&Ni(22862,22787,61,22885)}else Hh=0;while(0);return Pu(vc),Pu(Nl),Af=Hh,Af|0}return 0}function ds(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0;if(!(Cd(P,F)|0)||(P=mc(P)|0,q=+x[F>>3],fe=+x[F+8>>3],fe=P&fe<0?fe+6.283185307179586:fe,D=w[D>>2]|0,!D))return D=0,D|0;if(P){P=0,rr=fe,F=D;e:for(;;){for(;Ie=+x[F>>3],fe=+x[F+8>>3],F=F+16|0,mr=w[F>>2]|0,mr=mr|0?mr:D,Ae=+x[mr>>3],Ze=+x[mr+8>>3],Ie>Ae?(Ot=Ie,Ie=Ze):(Ot=Ae,Ae=Ie,Ie=fe,fe=Ze),q=q==Ae|q==Ot?q+2220446049250313e-31:q,!!(qOt);)if(F=w[F>>2]|0,!F){F=22;break e}if(Ze=Ie<0?Ie+6.283185307179586:Ie,Ie=fe<0?fe+6.283185307179586:fe,rr=Ze==rr|Ie==rr?rr+-2220446049250313e-31:rr,Ot=Ze+(Ie-Ze)*((q-Ae)/(Ot-Ae)),(Ot<0?Ot+6.283185307179586:Ot)>rr&&(P=P^1),F=w[F>>2]|0,!F){F=22;break}}if((F|0)==22)return P|0}else{P=0,rr=fe,F=D;e:for(;;){for(;Ie=+x[F>>3],fe=+x[F+8>>3],F=F+16|0,mr=w[F>>2]|0,mr=mr|0?mr:D,Ae=+x[mr>>3],Ze=+x[mr+8>>3],Ie>Ae?(Ot=Ie,Ie=Ze):(Ot=Ae,Ae=Ie,Ie=fe,fe=Ze),q=q==Ae|q==Ot?q+2220446049250313e-31:q,!!(qOt);)if(F=w[F>>2]|0,!F){F=22;break e}if(rr=Ie==rr|fe==rr?rr+-2220446049250313e-31:rr,Ie+(fe-Ie)*((q-Ae)/(Ot-Ae))>rr&&(P=P^1),F=w[F>>2]|0,!F){F=22;break}}if((F|0)==22)return P|0}return 0}function Ja(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0,Go=0;if(Go=qr,qr=qr+32|0,ha=Go+16|0,Wa=Go,Ae=Rr(D|0,P|0,52)|0,xr()|0,Ae=Ae&15,ui=Rr(F|0,q|0,52)|0,xr()|0,(Ae|0)!=(ui&15|0))return ha=12,qr=Go,ha|0;if(rr=Rr(D|0,P|0,45)|0,xr()|0,rr=rr&127,mr=Rr(F|0,q|0,45)|0,xr()|0,mr=mr&127,rr>>>0>121|mr>>>0>121)return ha=5,qr=Go,ha|0;if(ui=(rr|0)!=(mr|0),ui){if(Ze=nd(rr,mr)|0,(Ze|0)==7)return ha=1,qr=Go,ha|0;Ot=nd(mr,rr)|0,(Ot|0)==7?Ni(23066,23090,161,23100):(ci=Ze,Ie=Ot)}else ci=0,Ie=0;pn=Ff(rr)|0,Jn=Ff(mr)|0,w[ha>>2]=0,w[ha+4>>2]=0,w[ha+8>>2]=0,w[ha+12>>2]=0;do if(ci){if(mr=w[4272+(rr*28|0)+(ci<<2)>>2]|0,Ze=(mr|0)>0,Jn)if(Ze){rr=0,Ot=F,Ze=q;do Ot=ap(Ot,Ze)|0,Ze=xr()|0,Ie=hp(Ie)|0,(Ie|0)==1&&(Ie=hp(1)|0),rr=rr+1|0;while((rr|0)!=(mr|0));mr=Ie,rr=Ot,Ot=Ze}else mr=Ie,rr=F,Ot=q;else if(Ze){rr=0,Ot=F,Ze=q;do Ot=Zp(Ot,Ze)|0,Ze=xr()|0,Ie=hp(Ie)|0,rr=rr+1|0;while((rr|0)!=(mr|0));mr=Ie,rr=Ot,Ot=Ze}else mr=Ie,rr=F,Ot=q;if(Ip(rr,Ot,ha)|0,ui||Ni(23115,23090,191,23100),Ze=(pn|0)!=0,Ie=(Jn|0)!=0,Ze&Ie&&Ni(23142,23090,192,23100),Ze){if(Ie=Ep(D,P)|0,(Ie|0)==7){Ae=5;break}if(nt[21872+(Ie*7|0)+ci>>0]|0){Ae=1;break}Ot=w[21040+(Ie*28|0)+(ci<<2)>>2]|0,rr=Ot}else if(Ie){if(Ie=Ep(rr,Ot)|0,(Ie|0)==7){Ae=5;break}if(nt[21872+(Ie*7|0)+mr>>0]|0){Ae=1;break}rr=0,Ot=w[21040+(mr*28|0)+(Ie<<2)>>2]|0}else rr=0,Ot=0;if((rr|Ot|0)<0)Ae=5;else{if((Ot|0)>0){Ze=ha+4|0,Ie=0;do kp(Ze),Ie=Ie+1|0;while((Ie|0)!=(Ot|0))}if(w[Wa>>2]=0,w[Wa+4>>2]=0,w[Wa+8>>2]=0,np(Wa,ci),Ae|0)for(;jd(Ae)|0?x0(Wa):t0(Wa),(Ae|0)>1;)Ae=Ae+-1|0;if((rr|0)>0){Ae=0;do kp(Wa),Ae=Ae+1|0;while((Ae|0)!=(rr|0))}no=ha+4|0,dd(no,Wa,no),Vf(no),no=51}}else if(Ip(F,q,ha)|0,(pn|0)!=0&(Jn|0)!=0)if((mr|0)!=(rr|0)&&Ni(23173,23090,261,23100),Ie=Ep(D,P)|0,Ae=Ep(F,q)|0,(Ie|0)==7|(Ae|0)==7)Ae=5;else if(nt[21872+(Ie*7|0)+Ae>>0]|0)Ae=1;else if(Ie=w[21040+(Ie*28|0)+(Ae<<2)>>2]|0,(Ie|0)>0){Ze=ha+4|0,Ae=0;do kp(Ze),Ae=Ae+1|0;while((Ae|0)!=(Ie|0));no=51}else no=51;else no=51;while(0);return(no|0)==51&&(Ae=ha+4|0,w[fe>>2]=w[Ae>>2],w[fe+4>>2]=w[Ae+4>>2],w[fe+8>>2]=w[Ae+8>>2],Ae=0),ha=Ae,qr=Go,ha|0}function au(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0,Go=0,Wo=0;if(no=qr,qr=qr+48|0,rr=no+36|0,Ie=no+24|0,Ze=no+12|0,Ot=no,fe=Rr(D|0,P|0,52)|0,xr()|0,fe=fe&15,Jn=Rr(D|0,P|0,45)|0,xr()|0,Jn=Jn&127,Jn>>>0>121)return q=5,qr=no,q|0;if(mr=Ff(Jn)|0,sr(fe|0,0,52)|0,Wa=xr()|0|134225919,Ae=q,w[Ae>>2]=-1,w[Ae+4>>2]=Wa,!fe)return fe=b0(F)|0,(fe|0)==7||(fe=hd(Jn,fe)|0,(fe|0)==127)?(Wa=1,qr=no,Wa|0):(ui=sr(fe|0,0,45)|0,ci=xr()|0,Jn=q,ci=w[Jn+4>>2]&-1040385|ci,Wa=q,w[Wa>>2]=w[Jn>>2]|ui,w[Wa+4>>2]=ci,Wa=0,qr=no,Wa|0);for(w[rr>>2]=w[F>>2],w[rr+4>>2]=w[F+4>>2],w[rr+8>>2]=w[F+8>>2],F=fe;;){if(Ae=F,F=F+-1|0,w[Ie>>2]=w[rr>>2],w[Ie+4>>2]=w[rr+4>>2],w[Ie+8>>2]=w[rr+8>>2],jd(Ae)|0){if(fe=Gp(rr)|0,fe|0){F=13;break}w[Ze>>2]=w[rr>>2],w[Ze+4>>2]=w[rr+4>>2],w[Ze+8>>2]=w[rr+8>>2],x0(Ze)}else{if(fe=Wp(rr)|0,fe|0){F=13;break}w[Ze>>2]=w[rr>>2],w[Ze+4>>2]=w[rr+4>>2],w[Ze+8>>2]=w[rr+8>>2],t0(Ze)}if(Jh(Ie,Ze,Ot),Vf(Ot),fe=q,Go=w[fe>>2]|0,fe=w[fe+4>>2]|0,Wo=(15-Ae|0)*3|0,ha=sr(7,0,Wo|0)|0,fe=fe&~(xr()|0),Wo=sr(b0(Ot)|0,0,Wo|0)|0,fe=xr()|0|fe,Wa=q,w[Wa>>2]=Wo|Go&~ha,w[Wa+4>>2]=fe,(Ae|0)<=1){F=14;break}}e:do if((F|0)!=13&&(F|0)==14)if((w[rr>>2]|0)<=1&&(w[rr+4>>2]|0)<=1&&(w[rr+8>>2]|0)<=1){F=b0(rr)|0,fe=hd(Jn,F)|0,(fe|0)==127?Ot=0:Ot=Ff(fe)|0;t:do if(F){if(mr){if(fe=Ep(D,P)|0,(fe|0)==7){fe=5;break e}if(Ae=w[21248+(fe*28|0)+(F<<2)>>2]|0,(Ae|0)>0){fe=F,F=0;do fe=r0(fe)|0,F=F+1|0;while((F|0)!=(Ae|0))}else fe=F;if((fe|0)==1){fe=9;break e}F=hd(Jn,fe)|0,(F|0)==127&&Ni(23200,23090,411,23230),Ff(F)|0?Ni(23245,23090,412,23230):(ci=F,ui=Ae,pn=fe)}else ci=fe,ui=0,pn=F;if(Ze=w[4272+(Jn*28|0)+(pn<<2)>>2]|0,(Ze|0)<=-1&&Ni(23276,23090,419,23230),!Ot){if((ui|0)<0){fe=5;break e}if(ui|0){Ae=q,fe=0,F=w[Ae>>2]|0,Ae=w[Ae+4>>2]|0;do F=Pp(F,Ae)|0,Ae=xr()|0,Wo=q,w[Wo>>2]=F,w[Wo+4>>2]=Ae,fe=fe+1|0;while((fe|0)<(ui|0))}if((Ze|0)<=0){fe=ci,F=58;break}for(Ae=q,fe=0,F=w[Ae>>2]|0,Ae=w[Ae+4>>2]|0;;)if(F=Pp(F,Ae)|0,Ae=xr()|0,Wo=q,w[Wo>>2]=F,w[Wo+4>>2]=Ae,fe=fe+1|0,(fe|0)==(Ze|0)){fe=ci,F=58;break t}}if(Ie=nd(ci,Jn)|0,(Ie|0)==7&&Ni(23066,23090,428,23230),fe=q,F=w[fe>>2]|0,fe=w[fe+4>>2]|0,(Ze|0)>0){Ae=0;do F=Pp(F,fe)|0,fe=xr()|0,Wo=q,w[Wo>>2]=F,w[Wo+4>>2]=fe,Ae=Ae+1|0;while((Ae|0)!=(Ze|0))}if(fe=Ep(F,fe)|0,(fe|0)==7&&Ni(23313,23090,440,23230),F=kd(ci)|0,F=w[(F?21664:21456)+(Ie*28|0)+(fe<<2)>>2]|0,(F|0)<0&&Ni(23313,23090,454,23230),!F)fe=ci,F=58;else{Ie=q,fe=0,Ae=w[Ie>>2]|0,Ie=w[Ie+4>>2]|0;do Ae=D0(Ae,Ie)|0,Ie=xr()|0,Wo=q,w[Wo>>2]=Ae,w[Wo+4>>2]=Ie,fe=fe+1|0;while((fe|0)<(F|0));fe=ci,F=58}}else if((mr|0)!=0&(Ot|0)!=0){if(F=Ep(D,P)|0,Ae=q,Ae=Ep(w[Ae>>2]|0,w[Ae+4>>2]|0)|0,(F|0)==7|(Ae|0)==7){fe=5;break e}if(Ae=w[21248+(F*28|0)+(Ae<<2)>>2]|0,(Ae|0)<0){fe=5;break e}if(!Ae)F=59;else{Ze=q,F=0,Ie=w[Ze>>2]|0,Ze=w[Ze+4>>2]|0;do Ie=Pp(Ie,Ze)|0,Ze=xr()|0,Wo=q,w[Wo>>2]=Ie,w[Wo+4>>2]=Ze,F=F+1|0;while((F|0)<(Ae|0));F=58}}else F=58;while(0);if((F|0)==58&&Ot&&(F=59),(F|0)==59&&(Wo=q,(Ep(w[Wo>>2]|0,w[Wo+4>>2]|0)|0)==1)){fe=9;break}Wo=q,ha=w[Wo>>2]|0,Wo=w[Wo+4>>2]&-1040385,Go=sr(fe|0,0,45)|0,Wo=Wo|(xr()|0),fe=q,w[fe>>2]=ha|Go,w[fe+4>>2]=Wo,fe=0}else fe=1;while(0);return Wo=fe,qr=no,Wo|0}function Ds(D,P,F,q,fe,Ae){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0,Ae=Ae|0;var Ie=0,Ze=0;return Ze=qr,qr=qr+16|0,Ie=Ze,fe?D=15:(D=Ja(D,P,F,q,Ie)|0,D||(mm(Ie,Ae),D=0)),qr=Ze,D|0}function Bs(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0;return Ie=qr,qr=qr+16|0,Ae=Ie,q?F=15:(F=dp(F,Ae)|0,F||(F=au(D,P,Ae,fe)|0)),qr=Ie,F|0}function ru(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0,Ze=0,Ot=0;return Ot=qr,qr=qr+32|0,Ie=Ot+12|0,Ze=Ot,Ae=Ja(D,P,D,P,Ie)|0,Ae|0?(Ze=Ae,qr=Ot,Ze|0):(D=Ja(D,P,F,q,Ze)|0,D|0?(Ze=D,qr=Ot,Ze|0):(Ie=Tp(Ie,Ze)|0,Ze=fe,w[Ze>>2]=Ie,w[Ze+4>>2]=((Ie|0)<0)<<31>>31,Ze=0,qr=Ot,Ze|0))}function xs(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0,Ze=0,Ot=0;return Ot=qr,qr=qr+32|0,Ie=Ot+12|0,Ze=Ot,Ae=Ja(D,P,D,P,Ie)|0,!Ae&&(Ae=Ja(D,P,F,q,Ze)|0,!Ae)?(q=Tp(Ie,Ze)|0,q=Gs(q|0,((q|0)<0)<<31>>31|0,1,0)|0,Ie=xr()|0,Ze=fe,w[Ze>>2]=q,w[Ze+4>>2]=Ie,Ze=0,qr=Ot,Ze|0):(Ze=Ae,qr=Ot,Ze|0)}function nu(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0,Go=0,Wo=0,To=0,El=0,gl=0,du=0,Qu=0;if(du=qr,qr=qr+48|0,Ie=du+24|0,Ze=du+12|0,gl=du,Ae=Ja(D,P,D,P,Ie)|0,!Ae&&(Ae=Ja(D,P,F,q,Ze)|0,!Ae)){To=Tp(Ie,Ze)|0,El=((To|0)<0)<<31>>31,w[Ie>>2]=0,w[Ie+4>>2]=0,w[Ie+8>>2]=0,w[Ze>>2]=0,w[Ze+4>>2]=0,w[Ze+8>>2]=0,Ja(D,P,D,P,Ie)|0&&Ni(23313,23090,691,23299),Ja(D,P,F,q,Ze)|0&&Ni(23313,23090,696,23299),j0(Ie),j0(Ze),To?(pn=w[Ie>>2]|0,ci=+(To|0),ha=Ie+4|0,Jn=w[ha>>2]|0,Go=Ie+8|0,ui=w[Go>>2]|0,Wo=Ie,q=pn,Ae=Jn,F=ui,no=+((w[Ze>>2]|0)-pn|0)/ci,Wa=+((w[Ze+4>>2]|0)-Jn|0)/ci,ci=+((w[Ze+8>>2]|0)-ui|0)/ci):(Ae=Ie+4|0,F=Ie+8|0,ha=Ae,Go=F,Wo=Ie,q=w[Ie>>2]|0,Ae=w[Ae>>2]|0,F=w[F>>2]|0,no=0,Wa=0,ci=0),w[gl>>2]=q,ui=gl+4|0,w[ui>>2]=Ae,Jn=gl+8|0,w[Jn>>2]=F;e:do if((To|0)<0)Ae=0;else for(mr=0,pn=0,Ae=q;;){rr=+(pn>>>0)+4294967296*+(mr|0),Qu=no*rr+ +(Ae|0),Ot=Wa*rr+ +(w[ha>>2]|0),rr=ci*rr+ +(w[Go>>2]|0),F=~~+bo(+Qu),Ie=~~+bo(+Ot),Ae=~~+bo(+rr),Qu=+Ce(+(+(F|0)-Qu)),Ot=+Ce(+(+(Ie|0)-Ot)),rr=+Ce(+(+(Ae|0)-rr));do if(Qu>Ot&Qu>rr)F=0-(Ie+Ae)|0,q=Ie;else if(Ze=0-F|0,Ot>rr){q=Ze-Ae|0;break}else{q=Ie,Ae=Ze-Ie|0;break}while(0);if(w[gl>>2]=F,w[ui>>2]=q,w[Jn>>2]=Ae,Fp(gl),Ae=au(D,P,gl,fe+(pn<<3)|0)|0,Ae|0)break e;if(!((mr|0)<(El|0)|(mr|0)==(El|0)&pn>>>0>>0)){Ae=0;break e}Ae=Gs(pn|0,mr|0,1,0)|0,Ze=xr()|0,mr=Ze,pn=Ae,Ae=w[Wo>>2]|0}while(0);return gl=Ae,qr=du,gl|0}return gl=Ae,qr=du,gl|0}function co(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0;if((F|0)==0&(q|0)==0)return fe=0,Ae=1,Ai(fe|0),Ae|0;Ae=D,fe=P,D=1,P=0;do Ie=(F&1|0)==0&!0,D=ao((Ie?1:Ae)|0,(Ie?0:fe)|0,D|0,P|0)|0,P=xr()|0,F=sa(F|0,q|0,1)|0,q=xr()|0,Ae=ao(Ae|0,fe|0,Ae|0,fe|0)|0,fe=xr()|0;while(!((F|0)==0&(q|0)==0));return Ai(P|0),D|0}function aa(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0;if(!(Cd(P,F)|0)||(P=mc(P)|0,q=+x[F>>3],fe=+x[F+8>>3],fe=P&fe<0?fe+6.283185307179586:fe,Jn=w[D>>2]|0,(Jn|0)<=0))return Jn=0,Jn|0;if(pn=w[D+4>>2]|0,P){P=0,mr=fe,F=-1,D=0;e:for(;;){for(rr=D;Ie=+x[pn+(rr<<4)>>3],fe=+x[pn+(rr<<4)+8>>3],D=(F+2|0)%(Jn|0)|0,Ae=+x[pn+(D<<4)>>3],Ze=+x[pn+(D<<4)+8>>3],Ie>Ae?(Ot=Ie,Ie=Ze):(Ot=Ae,Ae=Ie,Ie=fe,fe=Ze),q=q==Ae|q==Ot?q+2220446049250313e-31:q,!!(qOt);)if(F=rr+1|0,(F|0)>=(Jn|0)){F=22;break e}else D=rr,rr=F,F=D;if(Ze=Ie<0?Ie+6.283185307179586:Ie,Ie=fe<0?fe+6.283185307179586:fe,mr=Ze==mr|Ie==mr?mr+-2220446049250313e-31:mr,Ot=Ze+(Ie-Ze)*((q-Ae)/(Ot-Ae)),(Ot<0?Ot+6.283185307179586:Ot)>mr&&(P=P^1),D=rr+1|0,(D|0)>=(Jn|0)){F=22;break}else F=rr}if((F|0)==22)return P|0}else{P=0,mr=fe,F=-1,D=0;e:for(;;){for(rr=D;Ie=+x[pn+(rr<<4)>>3],fe=+x[pn+(rr<<4)+8>>3],D=(F+2|0)%(Jn|0)|0,Ae=+x[pn+(D<<4)>>3],Ze=+x[pn+(D<<4)+8>>3],Ie>Ae?(Ot=Ie,Ie=Ze):(Ot=Ae,Ae=Ie,Ie=fe,fe=Ze),q=q==Ae|q==Ot?q+2220446049250313e-31:q,!!(qOt);)if(F=rr+1|0,(F|0)>=(Jn|0)){F=22;break e}else D=rr,rr=F,F=D;if(mr=Ie==mr|fe==mr?mr+-2220446049250313e-31:mr,Ie+(fe-Ie)*((q-Ae)/(Ot-Ae))>mr&&(P=P^1),D=rr+1|0,(D|0)>=(Jn|0)){F=22;break}else F=rr}if((F|0)==22)return P|0}return 0}function zs(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0,Go=0;if(ci=w[D>>2]|0,!ci){w[P>>2]=0,w[P+4>>2]=0,w[P+8>>2]=0,w[P+12>>2]=0,w[P+16>>2]=0,w[P+20>>2]=0,w[P+24>>2]=0,w[P+28>>2]=0;return}if(no=P+8|0,x[no>>3]=17976931348623157e292,Wa=P+24|0,x[Wa>>3]=17976931348623157e292,x[P>>3]=-17976931348623157e292,ha=P+16|0,x[ha>>3]=-17976931348623157e292,!((ci|0)<=0)){for(Jn=w[D+4>>2]|0,rr=17976931348623157e292,mr=-17976931348623157e292,pn=0,D=-1,Ae=17976931348623157e292,Ie=17976931348623157e292,Ot=-17976931348623157e292,q=-17976931348623157e292,ui=0;F=+x[Jn+(ui<<4)>>3],Ze=+x[Jn+(ui<<4)+8>>3],D=D+2|0,fe=+x[Jn+(((D|0)==(ci|0)?0:D)<<4)+8>>3],F>3]=F,Ae=F),Ze>3]=Ze,Ie=Ze),F>Ot?x[P>>3]=F:F=Ot,Ze>q&&(x[ha>>3]=Ze,q=Ze),rr=Ze>0&Zemr?Ze:mr,pn=pn|+Ce(+(Ze-fe))>3.141592653589793,D=ui+1|0,(D|0)!=(ci|0);)Go=ui,Ot=F,ui=D,D=Go;pn&&(x[ha>>3]=mr,x[Wa>>3]=rr)}}function Ru(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0,Go=0,Wo=0,To=0,El=0,gl=0,du=0;if(ci=w[D>>2]|0,ci){if(no=P+8|0,x[no>>3]=17976931348623157e292,Wa=P+24|0,x[Wa>>3]=17976931348623157e292,x[P>>3]=-17976931348623157e292,ha=P+16|0,x[ha>>3]=-17976931348623157e292,(ci|0)>0){for(fe=w[D+4>>2]|0,Jn=17976931348623157e292,ui=-17976931348623157e292,q=0,F=-1,Ot=17976931348623157e292,rr=17976931348623157e292,pn=-17976931348623157e292,Ie=-17976931348623157e292,Go=0;Ae=+x[fe+(Go<<4)>>3],mr=+x[fe+(Go<<4)+8>>3],gl=F+2|0,Ze=+x[fe+(((gl|0)==(ci|0)?0:gl)<<4)+8>>3],Ae>3]=Ae,Ot=Ae),mr>3]=mr,rr=mr),Ae>pn?x[P>>3]=Ae:Ae=pn,mr>Ie&&(x[ha>>3]=mr,Ie=mr),Jn=mr>0&mrui?mr:ui,q=q|+Ce(+(mr-Ze))>3.141592653589793,F=Go+1|0,(F|0)!=(ci|0);)gl=Go,pn=Ae,Go=F,F=gl;q&&(x[ha>>3]=ui,x[Wa>>3]=Jn)}}else w[P>>2]=0,w[P+4>>2]=0,w[P+8>>2]=0,w[P+12>>2]=0,w[P+16>>2]=0,w[P+20>>2]=0,w[P+24>>2]=0,w[P+28>>2]=0;if(gl=D+8|0,F=w[gl>>2]|0,!((F|0)<=0)){El=D+12|0,To=0;do if(fe=w[El>>2]|0,q=To,To=To+1|0,Wa=P+(To<<5)|0,ha=w[fe+(q<<3)>>2]|0,ha){if(Go=P+(To<<5)+8|0,x[Go>>3]=17976931348623157e292,D=P+(To<<5)+24|0,x[D>>3]=17976931348623157e292,x[Wa>>3]=-17976931348623157e292,Wo=P+(To<<5)+16|0,x[Wo>>3]=-17976931348623157e292,(ha|0)>0){for(ci=w[fe+(q<<3)+4>>2]|0,Jn=17976931348623157e292,ui=-17976931348623157e292,fe=0,q=-1,no=0,Ot=17976931348623157e292,rr=17976931348623157e292,mr=-17976931348623157e292,Ie=-17976931348623157e292;Ae=+x[ci+(no<<4)>>3],pn=+x[ci+(no<<4)+8>>3],q=q+2|0,Ze=+x[ci+(((q|0)==(ha|0)?0:q)<<4)+8>>3],Ae>3]=Ae,Ot=Ae),pn>3]=pn,rr=pn),Ae>mr?x[Wa>>3]=Ae:Ae=mr,pn>Ie&&(x[Wo>>3]=pn,Ie=pn),Jn=pn>0&pnui?pn:ui,fe=fe|+Ce(+(pn-Ze))>3.141592653589793,q=no+1|0,(q|0)!=(ha|0);)du=no,no=q,mr=Ae,q=du;fe&&(x[Wo>>3]=ui,x[D>>3]=Jn)}}else w[Wa>>2]=0,w[Wa+4>>2]=0,w[Wa+8>>2]=0,w[Wa+12>>2]=0,w[Wa+16>>2]=0,w[Wa+20>>2]=0,w[Wa+24>>2]=0,w[Wa+28>>2]=0,F=w[gl>>2]|0;while((To|0)<(F|0))}}function ls(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0;if(!(aa(D,P,F)|0))return fe=0,fe|0;if(fe=D+8|0,(w[fe>>2]|0)<=0)return fe=1,fe|0;for(q=D+12|0,D=0;;){if(Ae=D,D=D+1|0,aa((w[q>>2]|0)+(Ae<<3)|0,P+(D<<5)|0,F)|0){D=0,q=6;break}if((D|0)>=(w[fe>>2]|0)){D=1,q=6;break}}return(q|0)==6?D|0:0}function qu(){return 8}function ms(){return 16}function Ou(){return 168}function Ba(){return 8}function Lu(){return 16}function uc(){return 12}function Pc(){return 8}function Mu(D){return D=D|0,+(+((w[D>>2]|0)>>>0)+4294967296*+(w[D+4>>2]|0))}function ws(D){D=D|0;var P=0,F=0;return F=+x[D>>3],P=+x[D+8>>3],+ +Oe(+(F*F+P*P))}function La(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0;rr=+x[D>>3],Ot=+x[P>>3]-rr,Ze=+x[D+8>>3],Ie=+x[P+8>>3]-Ze,pn=+x[F>>3],Ae=+x[q>>3]-pn,Jn=+x[F+8>>3],mr=+x[q+8>>3]-Jn,Ae=(Ae*(Ze-Jn)-(rr-pn)*mr)/(Ot*mr-Ie*Ae),x[fe>>3]=rr+Ot*Ae,x[fe+8>>3]=Ze+Ie*Ae}function Ql(D,P){return D=D|0,P=P|0,+Ce(+(+x[D>>3]-+x[P>>3]))<11920928955078125e-23?(P=+Ce(+(+x[D+8>>3]-+x[P+8>>3]))<11920928955078125e-23,P|0):(P=0,P|0)}function lc(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0;return fe=+x[D>>3]-+x[P>>3],q=+x[D+8>>3]-+x[P+8>>3],F=+x[D+16>>3]-+x[P+16>>3],+(fe*fe+q*q+F*F)}function zu(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0;F=+x[D>>3],q=+zt(+F),F=+Tt(+F),x[P+16>>3]=F,F=+x[D+8>>3],fe=q*+zt(+F),x[P>>3]=fe,F=q*+Tt(+F),x[P+8>>3]=F}function jl(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0;if(Ae=qr,qr=qr+16|0,fe=Ae,q=gh(D,P)|0,(F+-1|0)>>>0>5||(q=(q|0)!=0,(F|0)==1&q))return fe=-1,qr=Ae,fe|0;do if(Dc(D,P,fe)|0)q=-1;else if(q){q=((w[21936+(F<<2)>>2]|0)+5-(w[fe>>2]|0)|0)%5|0;break}else{q=((w[21968+(F<<2)>>2]|0)+6-(w[fe>>2]|0)|0)%6|0;break}while(0);return fe=q,qr=Ae,fe|0}function Dc(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0;if(rr=qr,qr=qr+32|0,Ie=rr+16|0,Ze=rr,q=yp(D,P,Ie)|0,q|0)return F=q,qr=rr,F|0;Ae=wp(D,P)|0,Ot=Ep(D,P)|0,jh(Ae,Ze),q=xh(Ae,w[Ie>>2]|0)|0;e:do if(Ff(Ae)|0){do switch(Ae|0){case 4:{D=0;break}case 14:{D=1;break}case 24:{D=2;break}case 38:{D=3;break}case 49:{D=4;break}case 58:{D=5;break}case 63:{D=6;break}case 72:{D=7;break}case 83:{D=8;break}case 97:{D=9;break}case 107:{D=10;break}case 117:{D=11;break}default:{q=1;break e}}while(0);if(fe=w[22e3+(D*24|0)+8>>2]|0,P=w[22e3+(D*24|0)+16>>2]|0,D=w[Ie>>2]|0,(D|0)!=(w[Ze>>2]|0)&&(Ze=kd(Ae)|0,D=w[Ie>>2]|0,Ze|(D|0)==(P|0)&&(q=(q+1|0)%6|0)),(Ot|0)==3&(D|0)==(P|0)){q=(q+5|0)%6|0,fe=22;break}(Ot|0)==5&(D|0)==(fe|0)&&(q=(q+1|0)%6|0),fe=22}else fe=22;while(0);return(fe|0)==22&&(w[F>>2]=q,q=0),F=q,qr=rr,F|0}function Jl(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0,Go=0,Wo=0;if(Wo=qr,qr=qr+32|0,Go=Wo+24|0,Wa=Wo+20|0,ci=Wo+8|0,ui=Wo+16|0,Jn=Wo,Ot=(gh(D,P)|0)==0,Ot=Ot?6:5,mr=Rr(D|0,P|0,52)|0,xr()|0,mr=mr&15,Ot>>>0<=F>>>0)return q=2,qr=Wo,q|0;pn=(mr|0)==0,!pn&&(no=sr(7,0,(mr^15)*3|0)|0,(no&D|0)==0&((xr()|0)&P|0)==0)?fe=F:Ae=4;e:do if((Ae|0)==4){if(fe=(gh(D,P)|0)!=0,((fe?4:5)|0)<(F|0)||Dc(D,P,Go)|0||(Ae=(w[Go>>2]|0)+F|0,fe?fe=22288+(((Ae|0)%5|0)<<2)|0:fe=22320+(((Ae|0)%6|0)<<2)|0,no=w[fe>>2]|0,(no|0)==7))return q=1,qr=Wo,q|0;w[Wa>>2]=0,fe=rf(D,P,no,Wa,ci)|0;do if(!fe){if(Ze=ci,rr=w[Ze>>2]|0,Ze=w[Ze+4>>2]|0,Ie=Ze>>>0

>>0|(Ze|0)==(P|0)&rr>>>0>>0,Ae=Ie?rr:D,Ie=Ie?Ze:P,!pn&&(pn=sr(7,0,(mr^15)*3|0)|0,(rr&pn|0)==0&(Ze&(xr()|0)|0)==0))fe=F;else{if(Ze=(F+-1+Ot|0)%(Ot|0)|0,fe=gh(D,P)|0,(Ze|0)<0&&Ni(23313,23315,245,23324),Ot=(fe|0)!=0,((Ot?4:5)|0)<(Ze|0)&&Ni(23313,23315,245,23324),Dc(D,P,Go)|0&&Ni(23313,23315,245,23324),fe=(w[Go>>2]|0)+Ze|0,Ot?fe=22288+(((fe|0)%5|0)<<2)|0:fe=22320+(((fe|0)%6|0)<<2)|0,Ze=w[fe>>2]|0,(Ze|0)==7&&Ni(23313,23315,245,23324),w[ui>>2]=0,fe=rf(D,P,Ze,ui,Jn)|0,fe|0)break;rr=Jn,Ot=w[rr>>2]|0,rr=w[rr+4>>2]|0;do if(rr>>>0>>0|(rr|0)==(Ie|0)&Ot>>>0>>0){if(gh(Ot,rr)|0?Ae=xf(Ot,rr,D,P)|0:Ae=w[22384+((((w[ui>>2]|0)+(w[22352+(Ze<<2)>>2]|0)|0)%6|0)<<2)>>2]|0,fe=gh(Ot,rr)|0,(Ae+-1|0)>>>0>5){fe=-1,Ae=Ot,Ie=rr;break}if(fe=(fe|0)!=0,(Ae|0)==1&fe){fe=-1,Ae=Ot,Ie=rr;break}do if(Dc(Ot,rr,Go)|0)fe=-1;else if(fe){fe=((w[21936+(Ae<<2)>>2]|0)+5-(w[Go>>2]|0)|0)%5|0;break}else{fe=((w[21968+(Ae<<2)>>2]|0)+6-(w[Go>>2]|0)|0)%6|0;break}while(0);Ae=Ot,Ie=rr}else fe=F;while(0);Ze=ci,rr=w[Ze>>2]|0,Ze=w[Ze+4>>2]|0}if((Ae|0)==(rr|0)&(Ie|0)==(Ze|0)){if(Ot=(gh(rr,Ze)|0)!=0,Ot?D=xf(rr,Ze,D,P)|0:D=w[22384+((((w[Wa>>2]|0)+(w[22352+(no<<2)>>2]|0)|0)%6|0)<<2)>>2]|0,fe=gh(rr,Ze)|0,(D+-1|0)>>>0<=5&&(ha=(fe|0)!=0,!((D|0)==1&ha)))do if(Dc(rr,Ze,Go)|0)fe=-1;else if(ha){fe=((w[21936+(D<<2)>>2]|0)+5-(w[Go>>2]|0)|0)%5|0;break}else{fe=((w[21968+(D<<2)>>2]|0)+6-(w[Go>>2]|0)|0)%6|0;break}while(0);else fe=-1;fe=fe+1|0,fe=(fe|0)==6|Ot&(fe|0)==5?0:fe}P=Ie,D=Ae;break e}while(0);return q=fe,qr=Wo,q|0}while(0);return ha=sr(fe|0,0,56)|0,Go=xr()|0|P&-2130706433|536870912,w[q>>2]=ha|D,w[q+4>>2]=Go,q=0,qr=Wo,q|0}function yh(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0;return Ae=(gh(D,P)|0)==0,q=Jl(D,P,0,F)|0,fe=(q|0)==0,Ae?!fe||(q=Jl(D,P,1,F+8|0)|0,q|0)||(q=Jl(D,P,2,F+16|0)|0,q|0)||(q=Jl(D,P,3,F+24|0)|0,q|0)||(q=Jl(D,P,4,F+32|0)|0,q)?(Ae=q,Ae|0):Jl(D,P,5,F+40|0)|0:!fe||(q=Jl(D,P,1,F+8|0)|0,q|0)||(q=Jl(D,P,2,F+16|0)|0,q|0)||(q=Jl(D,P,3,F+24|0)|0,q|0)||(q=Jl(D,P,4,F+32|0)|0,q|0)?(Ae=q,Ae|0):(Ae=F+40|0,w[Ae>>2]=0,w[Ae+4>>2]=0,Ae=0,Ae|0)}function Gd(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0;return Ot=qr,qr=qr+192|0,fe=Ot,Ae=Ot+168|0,Ie=Rr(D|0,P|0,56)|0,xr()|0,Ie=Ie&7,Ze=P&-2130706433|134217728,q=yp(D,Ze,Ae)|0,q|0?(Ze=q,qr=Ot,Ze|0):(P=Rr(D|0,P|0,52)|0,xr()|0,P=P&15,gh(D,Ze)|0?ip(Ae,P,Ie,1,fe):pd(Ae,P,Ie,1,fe),Ze=fe+8|0,w[F>>2]=w[Ze>>2],w[F+4>>2]=w[Ze+4>>2],w[F+8>>2]=w[Ze+8>>2],w[F+12>>2]=w[Ze+12>>2],Ze=0,qr=Ot,Ze|0)}function Wd(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0;return fe=qr,qr=qr+16|0,F=fe,!(!0&(P&2013265920|0)==536870912)||(q=P&-2130706433|134217728,!(op(D,q)|0))?(q=0,qr=fe,q|0):(Ae=Rr(D|0,P|0,56)|0,xr()|0,Ae=(Jl(D,q,Ae&7,F)|0)==0,q=F,q=Ae&((w[q>>2]|0)==(D|0)?(w[q+4>>2]|0)==(P|0):0)&1,qr=fe,q|0)}function Cf(D,P,F){D=D|0,P=P|0,F=F|0;var q=0;(P|0)>0?(q=hl(P,4)|0,w[D>>2]=q,q||Ni(23337,23360,40,23374)):w[D>>2]=0,w[D+4>>2]=P,w[D+8>>2]=0,w[D+12>>2]=F}function yd(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0;fe=D+4|0,Ae=D+12|0,Ie=D+8|0;e:for(;;){for(F=w[fe>>2]|0,P=0;;){if((P|0)>=(F|0))break e;if(q=w[D>>2]|0,Ze=w[q+(P<<2)>>2]|0,!Ze)P=P+1|0;else break}P=q+(~~(+Ce(+(+dt(10,+ +(15-(w[Ae>>2]|0)|0))*(+x[Ze>>3]+ +x[Ze+8>>3])))%+(F|0))>>>0<<2)|0,F=w[P>>2]|0;t:do if(F|0){if(q=Ze+32|0,(F|0)==(Ze|0))w[P>>2]=w[q>>2];else{if(F=F+32|0,P=w[F>>2]|0,!P)break;for(;(P|0)!=(Ze|0);)if(F=P+32|0,P=w[F>>2]|0,!P)break t;w[F>>2]=w[q>>2]}Pu(Ze),w[Ie>>2]=(w[Ie>>2]|0)+-1}while(0)}Pu(w[D>>2]|0)}function Ch(D){D=D|0;var P=0,F=0,q=0;for(q=w[D+4>>2]|0,F=0;;){if((F|0)>=(q|0)){P=0,F=4;break}if(P=w[(w[D>>2]|0)+(F<<2)>>2]|0,!P)F=F+1|0;else{F=4;break}}return(F|0)==4?P|0:0}function Tf(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0;if(F=~~(+Ce(+(+dt(10,+ +(15-(w[D+12>>2]|0)|0))*(+x[P>>3]+ +x[P+8>>3])))%+(w[D+4>>2]|0))>>>0,F=(w[D>>2]|0)+(F<<2)|0,q=w[F>>2]|0,!q)return Ae=1,Ae|0;Ae=P+32|0;do if((q|0)!=(P|0)){if(F=w[q+32>>2]|0,!F)return Ae=1,Ae|0;for(fe=F;;){if((fe|0)==(P|0)){fe=8;break}if(F=w[fe+32>>2]|0,F)q=fe,fe=F;else{F=1,fe=10;break}}if((fe|0)==8){w[q+32>>2]=w[Ae>>2];break}else if((fe|0)==10)return F|0}else w[F>>2]=w[Ae>>2];while(0);return Pu(P),Ae=D+8|0,w[Ae>>2]=(w[Ae>>2]|0)+-1,Ae=0,Ae|0}function ed(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0;Ae=Qf(40)|0,Ae||Ni(23390,23360,98,23403),w[Ae>>2]=w[P>>2],w[Ae+4>>2]=w[P+4>>2],w[Ae+8>>2]=w[P+8>>2],w[Ae+12>>2]=w[P+12>>2],fe=Ae+16|0,w[fe>>2]=w[F>>2],w[fe+4>>2]=w[F+4>>2],w[fe+8>>2]=w[F+8>>2],w[fe+12>>2]=w[F+12>>2],w[Ae+32>>2]=0,fe=~~(+Ce(+(+dt(10,+ +(15-(w[D+12>>2]|0)|0))*(+x[P>>3]+ +x[P+8>>3])))%+(w[D+4>>2]|0))>>>0,fe=(w[D>>2]|0)+(fe<<2)|0,q=w[fe>>2]|0;do if(!q)w[fe>>2]=Ae;else{for(;!(jp(q,P)|0&&jp(q+16|0,F)|0);)if(fe=w[q+32>>2]|0,q=fe|0?fe:q,!(w[q+32>>2]|0)){Ie=10;break}if((Ie|0)==10){w[q+32>>2]=Ae;break}return Pu(Ae),Ie=q,Ie|0}while(0);return Ie=D+8|0,w[Ie>>2]=(w[Ie>>2]|0)+1,Ie=Ae,Ie|0}function If(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0;if(fe=~~(+Ce(+(+dt(10,+ +(15-(w[D+12>>2]|0)|0))*(+x[P>>3]+ +x[P+8>>3])))%+(w[D+4>>2]|0))>>>0,fe=w[(w[D>>2]|0)+(fe<<2)>>2]|0,!fe)return F=0,F|0;if(!F){for(D=fe;;){if(jp(D,P)|0){q=10;break}if(D=w[D+32>>2]|0,!D){D=0,q=10;break}}if((q|0)==10)return D|0}for(D=fe;;){if(jp(D,P)|0&&jp(D+16|0,F)|0){q=10;break}if(D=w[D+32>>2]|0,!D){D=0,q=10;break}}return(q|0)==10?D|0:0}function $h(D,P){D=D|0,P=P|0;var F=0;if(F=~~(+Ce(+(+dt(10,+ +(15-(w[D+12>>2]|0)|0))*(+x[P>>3]+ +x[P+8>>3])))%+(w[D+4>>2]|0))>>>0,D=w[(w[D>>2]|0)+(F<<2)>>2]|0,!D)return F=0,F|0;for(;;){if(jp(D,P)|0){P=5;break}if(D=w[D+32>>2]|0,!D){D=0,P=5;break}}return(P|0)==5?D|0:0}function nf(){return 23424}function Od(D){return D=+D,+ +Di(+D)}function Yc(D){return D=+D,~~+Od(D)|0}function Qf(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0,no=0,Wa=0,ha=0,Go=0,Wo=0,To=0,El=0;El=qr,qr=qr+16|0,Jn=El;do if(D>>>0<245){if(rr=D>>>0<11?16:D+11&-8,D=rr>>>3,pn=w[5857]|0,F=pn>>>D,F&3|0)return P=(F&1^1)+D|0,D=23468+(P<<1<<2)|0,F=D+8|0,q=w[F>>2]|0,fe=q+8|0,Ae=w[fe>>2]|0,(Ae|0)==(D|0)?w[5857]=pn&~(1<>2]=D,w[F>>2]=Ae),To=P<<3,w[q+4>>2]=To|3,To=q+To+4|0,w[To>>2]=w[To>>2]|1,To=fe,qr=El,To|0;if(mr=w[5859]|0,rr>>>0>mr>>>0){if(F|0)return P=2<>>12&16,P=P>>>Ze,F=P>>>5&8,P=P>>>F,Ae=P>>>2&4,P=P>>>Ae,D=P>>>1&2,P=P>>>D,q=P>>>1&1,q=(F|Ze|Ae|D|q)+(P>>>q)|0,P=23468+(q<<1<<2)|0,D=P+8|0,Ae=w[D>>2]|0,Ze=Ae+8|0,F=w[Ze>>2]|0,(F|0)==(P|0)?(D=pn&~(1<>2]=P,w[D>>2]=F,D=pn),To=q<<3,Ie=To-rr|0,w[Ae+4>>2]=rr|3,fe=Ae+rr|0,w[fe+4>>2]=Ie|1,w[Ae+To>>2]=Ie,mr|0&&(q=w[5862]|0,P=mr>>>3,F=23468+(P<<1<<2)|0,P=1<>2]|0):(w[5857]=D|P,P=F,D=F+8|0),w[D>>2]=q,w[P+12>>2]=q,w[q+8>>2]=P,w[q+12>>2]=F),w[5859]=Ie,w[5862]=fe,To=Ze,qr=El,To|0;if(Ae=w[5858]|0,Ae){for(F=(Ae&0-Ae)+-1|0,fe=F>>>12&16,F=F>>>fe,q=F>>>5&8,F=F>>>q,Ie=F>>>2&4,F=F>>>Ie,Ze=F>>>1&2,F=F>>>Ze,Ot=F>>>1&1,Ot=w[23732+((q|fe|Ie|Ze|Ot)+(F>>>Ot)<<2)>>2]|0,F=Ot,Ze=Ot,Ot=(w[Ot+4>>2]&-8)-rr|0;D=w[F+16>>2]|0,!(!D&&(D=w[F+20>>2]|0,!D));)Ie=(w[D+4>>2]&-8)-rr|0,fe=Ie>>>0>>0,F=D,Ze=fe?D:Ze,Ot=fe?Ie:Ot;if(Ie=Ze+rr|0,Ie>>>0>Ze>>>0){fe=w[Ze+24>>2]|0,P=w[Ze+12>>2]|0;do if((P|0)==(Ze|0)){if(D=Ze+20|0,P=w[D>>2]|0,!P&&(D=Ze+16|0,P=w[D>>2]|0,!P)){F=0;break}for(;;)if(q=P+20|0,F=w[q>>2]|0,F)P=F,D=q;else if(q=P+16|0,F=w[q>>2]|0,F)P=F,D=q;else break;w[D>>2]=0,F=P}else F=w[Ze+8>>2]|0,w[F+12>>2]=P,w[P+8>>2]=F,F=P;while(0);do if(fe|0){if(P=w[Ze+28>>2]|0,D=23732+(P<<2)|0,(Ze|0)==(w[D>>2]|0)){if(w[D>>2]=F,!F){w[5858]=Ae&~(1<>2]|0)==(Ze|0)?To:fe+20|0)>>2]=F,!F)break;w[F+24>>2]=fe,P=w[Ze+16>>2]|0,P|0&&(w[F+16>>2]=P,w[P+24>>2]=F),P=w[Ze+20>>2]|0,P|0&&(w[F+20>>2]=P,w[P+24>>2]=F)}while(0);return Ot>>>0<16?(To=Ot+rr|0,w[Ze+4>>2]=To|3,To=Ze+To+4|0,w[To>>2]=w[To>>2]|1):(w[Ze+4>>2]=rr|3,w[Ie+4>>2]=Ot|1,w[Ie+Ot>>2]=Ot,mr|0&&(q=w[5862]|0,P=mr>>>3,F=23468+(P<<1<<2)|0,P=1<>2]|0):(w[5857]=P|pn,P=F,D=F+8|0),w[D>>2]=q,w[P+12>>2]=q,w[q+8>>2]=P,w[q+12>>2]=F),w[5859]=Ot,w[5862]=Ie),To=Ze+8|0,qr=El,To|0}else pn=rr}else pn=rr}else pn=rr}else if(D>>>0<=4294967231)if(D=D+11|0,rr=D&-8,q=w[5858]|0,q){fe=0-rr|0,D=D>>>8,D?rr>>>0>16777215?Ot=31:(pn=(D+1048320|0)>>>16&8,no=D<>>16&4,no=no<>>16&2,Ot=14-(Ze|pn|Ot)+(no<>>15)|0,Ot=rr>>>(Ot+7|0)&1|Ot<<1):Ot=0,F=w[23732+(Ot<<2)>>2]|0;e:do if(!F)F=0,D=0,no=61;else for(D=0,Ze=rr<<((Ot|0)==31?0:25-(Ot>>>1)|0),Ae=0;;){if(Ie=(w[F+4>>2]&-8)-rr|0,Ie>>>0>>0)if(Ie)D=F,fe=Ie;else{D=F,fe=0,no=65;break e}if(no=w[F+20>>2]|0,F=w[F+16+(Ze>>>31<<2)>>2]|0,Ae=(no|0)==0|(no|0)==(F|0)?Ae:no,F)Ze=Ze<<1;else{F=Ae,no=61;break}}while(0);if((no|0)==61){if((F|0)==0&(D|0)==0){if(D=2<>>12&16,pn=pn>>>Ie,Ae=pn>>>5&8,pn=pn>>>Ae,Ze=pn>>>2&4,pn=pn>>>Ze,Ot=pn>>>1&2,pn=pn>>>Ot,F=pn>>>1&1,D=0,F=w[23732+((Ae|Ie|Ze|Ot|F)+(pn>>>F)<<2)>>2]|0}F?no=65:(Ze=D,Ie=fe)}if((no|0)==65)for(Ae=F;;)if(pn=(w[Ae+4>>2]&-8)-rr|0,F=pn>>>0>>0,fe=F?pn:fe,D=F?Ae:D,F=w[Ae+16>>2]|0,F||(F=w[Ae+20>>2]|0),F)Ae=F;else{Ze=D,Ie=fe;break}if(Ze|0&&Ie>>>0<((w[5859]|0)-rr|0)>>>0&&(mr=Ze+rr|0,mr>>>0>Ze>>>0)){Ae=w[Ze+24>>2]|0,P=w[Ze+12>>2]|0;do if((P|0)==(Ze|0)){if(D=Ze+20|0,P=w[D>>2]|0,!P&&(D=Ze+16|0,P=w[D>>2]|0,!P)){P=0;break}for(;;)if(fe=P+20|0,F=w[fe>>2]|0,F)P=F,D=fe;else if(fe=P+16|0,F=w[fe>>2]|0,F)P=F,D=fe;else break;w[D>>2]=0}else To=w[Ze+8>>2]|0,w[To+12>>2]=P,w[P+8>>2]=To;while(0);do if(Ae){if(D=w[Ze+28>>2]|0,F=23732+(D<<2)|0,(Ze|0)==(w[F>>2]|0)){if(w[F>>2]=P,!P){q=q&~(1<>2]|0)==(Ze|0)?To:Ae+20|0)>>2]=P,!P)break;w[P+24>>2]=Ae,D=w[Ze+16>>2]|0,D|0&&(w[P+16>>2]=D,w[D+24>>2]=P),D=w[Ze+20>>2]|0,D&&(w[P+20>>2]=D,w[D+24>>2]=P)}while(0);e:do if(Ie>>>0<16)To=Ie+rr|0,w[Ze+4>>2]=To|3,To=Ze+To+4|0,w[To>>2]=w[To>>2]|1;else{if(w[Ze+4>>2]=rr|3,w[mr+4>>2]=Ie|1,w[mr+Ie>>2]=Ie,P=Ie>>>3,Ie>>>0<256){F=23468+(P<<1<<2)|0,D=w[5857]|0,P=1<>2]|0):(w[5857]=D|P,P=F,D=F+8|0),w[D>>2]=mr,w[P+12>>2]=mr,w[mr+8>>2]=P,w[mr+12>>2]=F;break}if(P=Ie>>>8,P?Ie>>>0>16777215?F=31:(Wo=(P+1048320|0)>>>16&8,To=P<>>16&4,To=To<>>16&2,F=14-(Go|Wo|F)+(To<>>15)|0,F=Ie>>>(F+7|0)&1|F<<1):F=0,P=23732+(F<<2)|0,w[mr+28>>2]=F,D=mr+16|0,w[D+4>>2]=0,w[D>>2]=0,D=1<>2]=mr,w[mr+24>>2]=P,w[mr+12>>2]=mr,w[mr+8>>2]=mr;break}P=w[P>>2]|0;t:do if((w[P+4>>2]&-8|0)!=(Ie|0)){for(q=Ie<<((F|0)==31?0:25-(F>>>1)|0);F=P+16+(q>>>31<<2)|0,D=w[F>>2]|0,!!D;)if((w[D+4>>2]&-8|0)==(Ie|0)){P=D;break t}else q=q<<1,P=D;w[F>>2]=mr,w[mr+24>>2]=P,w[mr+12>>2]=mr,w[mr+8>>2]=mr;break e}while(0);Wo=P+8|0,To=w[Wo>>2]|0,w[To+12>>2]=mr,w[Wo>>2]=mr,w[mr+8>>2]=To,w[mr+12>>2]=P,w[mr+24>>2]=0}while(0);return To=Ze+8|0,qr=El,To|0}else pn=rr}else pn=rr;else pn=-1;while(0);if(F=w[5859]|0,F>>>0>=pn>>>0)return P=F-pn|0,D=w[5862]|0,P>>>0>15?(To=D+pn|0,w[5862]=To,w[5859]=P,w[To+4>>2]=P|1,w[D+F>>2]=P,w[D+4>>2]=pn|3):(w[5859]=0,w[5862]=0,w[D+4>>2]=F|3,To=D+F+4|0,w[To>>2]=w[To>>2]|1),To=D+8|0,qr=El,To|0;if(Ie=w[5860]|0,Ie>>>0>pn>>>0)return Go=Ie-pn|0,w[5860]=Go,To=w[5863]|0,Wo=To+pn|0,w[5863]=Wo,w[Wo+4>>2]=Go|1,w[To+4>>2]=pn|3,To=To+8|0,qr=El,To|0;if(w[5975]|0?D=w[5977]|0:(w[5977]=4096,w[5976]=4096,w[5978]=-1,w[5979]=-1,w[5980]=0,w[5968]=0,w[5975]=Jn&-16^1431655768,D=4096),Ze=pn+48|0,Ot=pn+47|0,Ae=D+Ot|0,fe=0-D|0,rr=Ae&fe,rr>>>0<=pn>>>0||(D=w[5967]|0,D|0&&(mr=w[5965]|0,Jn=mr+rr|0,Jn>>>0<=mr>>>0|Jn>>>0>D>>>0)))return To=0,qr=El,To|0;e:do if(w[5968]&4)P=0,no=143;else{F=w[5863]|0;t:do if(F){for(q=23876;Jn=w[q>>2]|0,!(Jn>>>0<=F>>>0&&(Jn+(w[q+4>>2]|0)|0)>>>0>F>>>0);)if(D=w[q+8>>2]|0,D)q=D;else{no=128;break t}if(P=Ae-Ie&fe,P>>>0<2147483647)if(D=jn(P|0)|0,(D|0)==((w[q>>2]|0)+(w[q+4>>2]|0)|0)){if((D|0)!=-1){Ie=P,Ae=D,no=145;break e}}else q=D,no=136;else P=0}else no=128;while(0);do if((no|0)==128)if(F=jn(0)|0,(F|0)!=-1&&(P=F,ui=w[5976]|0,ci=ui+-1|0,P=(ci&P|0?(ci+P&0-ui)-P|0:0)+rr|0,ui=w[5965]|0,ci=P+ui|0,P>>>0>pn>>>0&P>>>0<2147483647)){if(Jn=w[5967]|0,Jn|0&&ci>>>0<=ui>>>0|ci>>>0>Jn>>>0){P=0;break}if(D=jn(P|0)|0,(D|0)==(F|0)){Ie=P,Ae=F,no=145;break e}else q=D,no=136}else P=0;while(0);do if((no|0)==136){if(F=0-P|0,!(Ze>>>0>P>>>0&(P>>>0<2147483647&(q|0)!=-1)))if((q|0)==-1){P=0;break}else{Ie=P,Ae=q,no=145;break e}if(D=w[5977]|0,D=Ot-P+D&0-D,D>>>0>=2147483647){Ie=P,Ae=q,no=145;break e}if((jn(D|0)|0)==-1){jn(F|0)|0,P=0;break}else{Ie=D+P|0,Ae=q,no=145;break e}}while(0);w[5968]=w[5968]|4,no=143}while(0);if((no|0)==143&&rr>>>0<2147483647&&(Go=jn(rr|0)|0,ci=jn(0)|0,Wa=ci-Go|0,ha=Wa>>>0>(pn+40|0)>>>0,!((Go|0)==-1|ha^1|Go>>>0>>0&((Go|0)!=-1&(ci|0)!=-1)^1))&&(Ie=ha?Wa:P,Ae=Go,no=145),(no|0)==145){P=(w[5965]|0)+Ie|0,w[5965]=P,P>>>0>(w[5966]|0)>>>0&&(w[5966]=P),Ot=w[5863]|0;e:do if(Ot){for(P=23876;;){if(D=w[P>>2]|0,F=w[P+4>>2]|0,(Ae|0)==(D+F|0)){no=154;break}if(q=w[P+8>>2]|0,q)P=q;else break}if((no|0)==154&&(Wo=P+4|0,(w[P+12>>2]&8|0)==0)&&Ae>>>0>Ot>>>0&D>>>0<=Ot>>>0){w[Wo>>2]=F+Ie,To=(w[5860]|0)+Ie|0,Go=Ot+8|0,Go=Go&7|0?0-Go&7:0,Wo=Ot+Go|0,Go=To-Go|0,w[5863]=Wo,w[5860]=Go,w[Wo+4>>2]=Go|1,w[Ot+To+4>>2]=40,w[5864]=w[5979];break}for(Ae>>>0<(w[5861]|0)>>>0&&(w[5861]=Ae),F=Ae+Ie|0,P=23876;;){if((w[P>>2]|0)==(F|0)){no=162;break}if(D=w[P+8>>2]|0,D)P=D;else break}if((no|0)==162&&!(w[P+12>>2]&8|0)){w[P>>2]=Ae,mr=P+4|0,w[mr>>2]=(w[mr>>2]|0)+Ie,mr=Ae+8|0,mr=Ae+(mr&7|0?0-mr&7:0)|0,P=F+8|0,P=F+(P&7|0?0-P&7:0)|0,rr=mr+pn|0,Ze=P-mr-pn|0,w[mr+4>>2]=pn|3;t:do if((Ot|0)==(P|0))To=(w[5860]|0)+Ze|0,w[5860]=To,w[5863]=rr,w[rr+4>>2]=To|1;else{if((w[5862]|0)==(P|0)){To=(w[5859]|0)+Ze|0,w[5859]=To,w[5862]=rr,w[rr+4>>2]=To|1,w[rr+To>>2]=To;break}if(D=w[P+4>>2]|0,(D&3|0)==1){Ie=D&-8,q=D>>>3;r:do if(D>>>0<256)if(D=w[P+8>>2]|0,F=w[P+12>>2]|0,(F|0)==(D|0)){w[5857]=w[5857]&~(1<>2]=F,w[F+8>>2]=D;break}else{Ae=w[P+24>>2]|0,D=w[P+12>>2]|0;do if((D|0)==(P|0)){if(F=P+16|0,q=F+4|0,D=w[q>>2]|0,D)F=q;else if(D=w[F>>2]|0,!D){D=0;break}for(;;)if(fe=D+20|0,q=w[fe>>2]|0,q)D=q,F=fe;else if(fe=D+16|0,q=w[fe>>2]|0,q)D=q,F=fe;else break;w[F>>2]=0}else To=w[P+8>>2]|0,w[To+12>>2]=D,w[D+8>>2]=To;while(0);if(!Ae)break;F=w[P+28>>2]|0,q=23732+(F<<2)|0;do if((w[q>>2]|0)!=(P|0)){if(To=Ae+16|0,w[((w[To>>2]|0)==(P|0)?To:Ae+20|0)>>2]=D,!D)break r}else{if(w[q>>2]=D,D|0)break;w[5858]=w[5858]&~(1<>2]=Ae,F=P+16|0,q=w[F>>2]|0,q|0&&(w[D+16>>2]=q,w[q+24>>2]=D),F=w[F+4>>2]|0,!F)break;w[D+20>>2]=F,w[F+24>>2]=D}while(0);P=P+Ie|0,fe=Ie+Ze|0}else fe=Ze;if(P=P+4|0,w[P>>2]=w[P>>2]&-2,w[rr+4>>2]=fe|1,w[rr+fe>>2]=fe,P=fe>>>3,fe>>>0<256){F=23468+(P<<1<<2)|0,D=w[5857]|0,P=1<>2]|0):(w[5857]=D|P,P=F,D=F+8|0),w[D>>2]=rr,w[P+12>>2]=rr,w[rr+8>>2]=P,w[rr+12>>2]=F;break}P=fe>>>8;do if(!P)q=0;else{if(fe>>>0>16777215){q=31;break}Wo=(P+1048320|0)>>>16&8,To=P<>>16&4,To=To<>>16&2,q=14-(Go|Wo|q)+(To<>>15)|0,q=fe>>>(q+7|0)&1|q<<1}while(0);if(P=23732+(q<<2)|0,w[rr+28>>2]=q,D=rr+16|0,w[D+4>>2]=0,w[D>>2]=0,D=w[5858]|0,F=1<>2]=rr,w[rr+24>>2]=P,w[rr+12>>2]=rr,w[rr+8>>2]=rr;break}P=w[P>>2]|0;r:do if((w[P+4>>2]&-8|0)!=(fe|0)){for(q=fe<<((q|0)==31?0:25-(q>>>1)|0);F=P+16+(q>>>31<<2)|0,D=w[F>>2]|0,!!D;)if((w[D+4>>2]&-8|0)==(fe|0)){P=D;break r}else q=q<<1,P=D;w[F>>2]=rr,w[rr+24>>2]=P,w[rr+12>>2]=rr,w[rr+8>>2]=rr;break t}while(0);Wo=P+8|0,To=w[Wo>>2]|0,w[To+12>>2]=rr,w[Wo>>2]=rr,w[rr+8>>2]=To,w[rr+12>>2]=P,w[rr+24>>2]=0}while(0);return To=mr+8|0,qr=El,To|0}for(P=23876;D=w[P>>2]|0,!(D>>>0<=Ot>>>0&&(To=D+(w[P+4>>2]|0)|0,To>>>0>Ot>>>0));)P=w[P+8>>2]|0;fe=To+-47|0,D=fe+8|0,D=fe+(D&7|0?0-D&7:0)|0,fe=Ot+16|0,D=D>>>0>>0?Ot:D,P=D+8|0,F=Ie+-40|0,Go=Ae+8|0,Go=Go&7|0?0-Go&7:0,Wo=Ae+Go|0,Go=F-Go|0,w[5863]=Wo,w[5860]=Go,w[Wo+4>>2]=Go|1,w[Ae+F+4>>2]=40,w[5864]=w[5979],F=D+4|0,w[F>>2]=27,w[P>>2]=w[5969],w[P+4>>2]=w[5970],w[P+8>>2]=w[5971],w[P+12>>2]=w[5972],w[5969]=Ae,w[5970]=Ie,w[5972]=0,w[5971]=P,P=D+24|0;do Wo=P,P=P+4|0,w[P>>2]=7;while((Wo+8|0)>>>0>>0);if((D|0)!=(Ot|0)){if(Ae=D-Ot|0,w[F>>2]=w[F>>2]&-2,w[Ot+4>>2]=Ae|1,w[D>>2]=Ae,P=Ae>>>3,Ae>>>0<256){F=23468+(P<<1<<2)|0,D=w[5857]|0,P=1<>2]|0):(w[5857]=D|P,P=F,D=F+8|0),w[D>>2]=Ot,w[P+12>>2]=Ot,w[Ot+8>>2]=P,w[Ot+12>>2]=F;break}if(P=Ae>>>8,P?Ae>>>0>16777215?q=31:(Wo=(P+1048320|0)>>>16&8,To=P<>>16&4,To=To<>>16&2,q=14-(Go|Wo|q)+(To<>>15)|0,q=Ae>>>(q+7|0)&1|q<<1):q=0,F=23732+(q<<2)|0,w[Ot+28>>2]=q,w[Ot+20>>2]=0,w[fe>>2]=0,P=w[5858]|0,D=1<>2]=Ot,w[Ot+24>>2]=F,w[Ot+12>>2]=Ot,w[Ot+8>>2]=Ot;break}P=w[F>>2]|0;t:do if((w[P+4>>2]&-8|0)!=(Ae|0)){for(q=Ae<<((q|0)==31?0:25-(q>>>1)|0);F=P+16+(q>>>31<<2)|0,D=w[F>>2]|0,!!D;)if((w[D+4>>2]&-8|0)==(Ae|0)){P=D;break t}else q=q<<1,P=D;w[F>>2]=Ot,w[Ot+24>>2]=P,w[Ot+12>>2]=Ot,w[Ot+8>>2]=Ot;break e}while(0);Wo=P+8|0,To=w[Wo>>2]|0,w[To+12>>2]=Ot,w[Wo>>2]=Ot,w[Ot+8>>2]=To,w[Ot+12>>2]=P,w[Ot+24>>2]=0}}else To=w[5861]|0,(To|0)==0|Ae>>>0>>0&&(w[5861]=Ae),w[5969]=Ae,w[5970]=Ie,w[5972]=0,w[5866]=w[5975],w[5865]=-1,w[5870]=23468,w[5869]=23468,w[5872]=23476,w[5871]=23476,w[5874]=23484,w[5873]=23484,w[5876]=23492,w[5875]=23492,w[5878]=23500,w[5877]=23500,w[5880]=23508,w[5879]=23508,w[5882]=23516,w[5881]=23516,w[5884]=23524,w[5883]=23524,w[5886]=23532,w[5885]=23532,w[5888]=23540,w[5887]=23540,w[5890]=23548,w[5889]=23548,w[5892]=23556,w[5891]=23556,w[5894]=23564,w[5893]=23564,w[5896]=23572,w[5895]=23572,w[5898]=23580,w[5897]=23580,w[5900]=23588,w[5899]=23588,w[5902]=23596,w[5901]=23596,w[5904]=23604,w[5903]=23604,w[5906]=23612,w[5905]=23612,w[5908]=23620,w[5907]=23620,w[5910]=23628,w[5909]=23628,w[5912]=23636,w[5911]=23636,w[5914]=23644,w[5913]=23644,w[5916]=23652,w[5915]=23652,w[5918]=23660,w[5917]=23660,w[5920]=23668,w[5919]=23668,w[5922]=23676,w[5921]=23676,w[5924]=23684,w[5923]=23684,w[5926]=23692,w[5925]=23692,w[5928]=23700,w[5927]=23700,w[5930]=23708,w[5929]=23708,w[5932]=23716,w[5931]=23716,To=Ie+-40|0,Go=Ae+8|0,Go=Go&7|0?0-Go&7:0,Wo=Ae+Go|0,Go=To-Go|0,w[5863]=Wo,w[5860]=Go,w[Wo+4>>2]=Go|1,w[Ae+To+4>>2]=40,w[5864]=w[5979];while(0);if(P=w[5860]|0,P>>>0>pn>>>0)return Go=P-pn|0,w[5860]=Go,To=w[5863]|0,Wo=To+pn|0,w[5863]=Wo,w[Wo+4>>2]=Go|1,w[To+4>>2]=pn|3,To=To+8|0,qr=El,To|0}return To=nf()|0,w[To>>2]=12,To=0,qr=El,To|0}function Pu(D){D=D|0;var P=0,F=0,q=0,fe=0,Ae=0,Ie=0,Ze=0,Ot=0;if(D){F=D+-8|0,fe=w[5861]|0,D=w[D+-4>>2]|0,P=D&-8,Ot=F+P|0;do if(D&1)Ze=F,Ie=F;else{if(q=w[F>>2]|0,!(D&3)||(Ie=F+(0-q)|0,Ae=q+P|0,Ie>>>0>>0))return;if((w[5862]|0)==(Ie|0)){if(D=Ot+4|0,P=w[D>>2]|0,(P&3|0)!=3){Ze=Ie,P=Ae;break}w[5859]=Ae,w[D>>2]=P&-2,w[Ie+4>>2]=Ae|1,w[Ie+Ae>>2]=Ae;return}if(F=q>>>3,q>>>0<256)if(D=w[Ie+8>>2]|0,P=w[Ie+12>>2]|0,(P|0)==(D|0)){w[5857]=w[5857]&~(1<>2]=P,w[P+8>>2]=D,Ze=Ie,P=Ae;break}fe=w[Ie+24>>2]|0,D=w[Ie+12>>2]|0;do if((D|0)==(Ie|0)){if(P=Ie+16|0,F=P+4|0,D=w[F>>2]|0,D)P=F;else if(D=w[P>>2]|0,!D){D=0;break}for(;;)if(q=D+20|0,F=w[q>>2]|0,F)D=F,P=q;else if(q=D+16|0,F=w[q>>2]|0,F)D=F,P=q;else break;w[P>>2]=0}else Ze=w[Ie+8>>2]|0,w[Ze+12>>2]=D,w[D+8>>2]=Ze;while(0);if(fe){if(P=w[Ie+28>>2]|0,F=23732+(P<<2)|0,(w[F>>2]|0)==(Ie|0)){if(w[F>>2]=D,!D){w[5858]=w[5858]&~(1<>2]|0)==(Ie|0)?Ze:fe+20|0)>>2]=D,!D){Ze=Ie,P=Ae;break}w[D+24>>2]=fe,P=Ie+16|0,F=w[P>>2]|0,F|0&&(w[D+16>>2]=F,w[F+24>>2]=D),P=w[P+4>>2]|0,P?(w[D+20>>2]=P,w[P+24>>2]=D,Ze=Ie,P=Ae):(Ze=Ie,P=Ae)}else Ze=Ie,P=Ae}while(0);if(!(Ie>>>0>=Ot>>>0)&&(D=Ot+4|0,q=w[D>>2]|0,!!(q&1))){if(q&2)w[D>>2]=q&-2,w[Ze+4>>2]=P|1,w[Ie+P>>2]=P,fe=P;else{if((w[5863]|0)==(Ot|0)){if(Ot=(w[5860]|0)+P|0,w[5860]=Ot,w[5863]=Ze,w[Ze+4>>2]=Ot|1,(Ze|0)!=(w[5862]|0))return;w[5862]=0,w[5859]=0;return}if((w[5862]|0)==(Ot|0)){Ot=(w[5859]|0)+P|0,w[5859]=Ot,w[5862]=Ie,w[Ze+4>>2]=Ot|1,w[Ie+Ot>>2]=Ot;return}fe=(q&-8)+P|0,F=q>>>3;do if(q>>>0<256)if(P=w[Ot+8>>2]|0,D=w[Ot+12>>2]|0,(D|0)==(P|0)){w[5857]=w[5857]&~(1<>2]=D,w[D+8>>2]=P;break}else{Ae=w[Ot+24>>2]|0,D=w[Ot+12>>2]|0;do if((D|0)==(Ot|0)){if(P=Ot+16|0,F=P+4|0,D=w[F>>2]|0,D)P=F;else if(D=w[P>>2]|0,!D){F=0;break}for(;;)if(q=D+20|0,F=w[q>>2]|0,F)D=F,P=q;else if(q=D+16|0,F=w[q>>2]|0,F)D=F,P=q;else break;w[P>>2]=0,F=D}else F=w[Ot+8>>2]|0,w[F+12>>2]=D,w[D+8>>2]=F,F=D;while(0);if(Ae|0){if(D=w[Ot+28>>2]|0,P=23732+(D<<2)|0,(w[P>>2]|0)==(Ot|0)){if(w[P>>2]=F,!F){w[5858]=w[5858]&~(1<>2]|0)==(Ot|0)?q:Ae+20|0)>>2]=F,!F)break;w[F+24>>2]=Ae,D=Ot+16|0,P=w[D>>2]|0,P|0&&(w[F+16>>2]=P,w[P+24>>2]=F),D=w[D+4>>2]|0,D|0&&(w[F+20>>2]=D,w[D+24>>2]=F)}}while(0);if(w[Ze+4>>2]=fe|1,w[Ie+fe>>2]=fe,(Ze|0)==(w[5862]|0)){w[5859]=fe;return}}if(D=fe>>>3,fe>>>0<256){F=23468+(D<<1<<2)|0,P=w[5857]|0,D=1<>2]|0):(w[5857]=P|D,D=F,P=F+8|0),w[P>>2]=Ze,w[D+12>>2]=Ze,w[Ze+8>>2]=D,w[Ze+12>>2]=F;return}D=fe>>>8,D?fe>>>0>16777215?q=31:(Ie=(D+1048320|0)>>>16&8,Ot=D<>>16&4,Ot=Ot<>>16&2,q=14-(Ae|Ie|q)+(Ot<>>15)|0,q=fe>>>(q+7|0)&1|q<<1):q=0,D=23732+(q<<2)|0,w[Ze+28>>2]=q,w[Ze+20>>2]=0,w[Ze+16>>2]=0,P=w[5858]|0,F=1<>2]=Ze,w[Ze+24>>2]=D,w[Ze+12>>2]=Ze,w[Ze+8>>2]=Ze;else{D=w[D>>2]|0;t:do if((w[D+4>>2]&-8|0)!=(fe|0)){for(q=fe<<((q|0)==31?0:25-(q>>>1)|0);F=D+16+(q>>>31<<2)|0,P=w[F>>2]|0,!!P;)if((w[P+4>>2]&-8|0)==(fe|0)){D=P;break t}else q=q<<1,D=P;w[F>>2]=Ze,w[Ze+24>>2]=D,w[Ze+12>>2]=Ze,w[Ze+8>>2]=Ze;break e}while(0);Ie=D+8|0,Ot=w[Ie>>2]|0,w[Ot+12>>2]=Ze,w[Ie>>2]=Ze,w[Ze+8>>2]=Ot,w[Ze+12>>2]=D,w[Ze+24>>2]=0}while(0);if(Ot=(w[5865]|0)+-1|0,w[5865]=Ot,!(Ot|0)){for(D=23884;D=w[D>>2]|0,D;)D=D+8|0;w[5865]=-1}}}}function hl(D,P){D=D|0,P=P|0;var F=0;return D?(F=Hr(P,D)|0,(P|D)>>>0>65535&&(F=((F>>>0)/(D>>>0)|0|0)==(P|0)?F:-1)):F=0,D=Qf(F)|0,!D||!(w[D+-4>>2]&3)||ji(D|0,0,F|0)|0,D|0}function Gs(D,P,F,q){return D=D|0,P=P|0,F=F|0,q=q|0,F=D+F>>>0,Ai(P+q+(F>>>0>>0|0)>>>0|0),F|0|0}function of(D,P,F,q){return D=D|0,P=P|0,F=F|0,q=q|0,q=P-q-(F>>>0>D>>>0|0)>>>0,Ai(q|0),D-F>>>0|0|0}function Oh(D){return D=D|0,(D?31-(ii(D^D-1)|0)|0:32)|0}function Vp(D,P,F,q,fe){D=D|0,P=P|0,F=F|0,q=q|0,fe=fe|0;var Ae=0,Ie=0,Ze=0,Ot=0,rr=0,mr=0,pn=0,Jn=0,ui=0,ci=0;if(mr=D,Ot=P,rr=Ot,Ie=F,Jn=q,Ze=Jn,!rr)return Ae=(fe|0)!=0,Ze?Ae?(w[fe>>2]=D|0,w[fe+4>>2]=P&0,Jn=0,fe=0,Ai(Jn|0),fe|0):(Jn=0,fe=0,Ai(Jn|0),fe|0):(Ae&&(w[fe>>2]=(mr>>>0)%(Ie>>>0),w[fe+4>>2]=0),Jn=0,fe=(mr>>>0)/(Ie>>>0)>>>0,Ai(Jn|0),fe|0);Ae=(Ze|0)==0;do if(Ie){if(!Ae){if(Ae=(ii(Ze|0)|0)-(ii(rr|0)|0)|0,Ae>>>0<=31){pn=Ae+1|0,Ze=31-Ae|0,P=Ae-31>>31,Ie=pn,D=mr>>>(pn>>>0)&P|rr<>>(pn>>>0)&P,Ae=0,Ze=mr<>2]=D|0,w[fe+4>>2]=Ot|P&0,Jn=0,fe=0,Ai(Jn|0),fe|0):(Jn=0,fe=0,Ai(Jn|0),fe|0)}if(Ae=Ie-1|0,Ae&Ie|0){Ze=(ii(Ie|0)|0)+33-(ii(rr|0)|0)|0,ci=64-Ze|0,pn=32-Ze|0,Ot=pn>>31,ui=Ze-32|0,P=ui>>31,Ie=Ze,D=pn-1>>31&rr>>>(ui>>>0)|(rr<>>(Ze>>>0))&P,P=P&rr>>>(Ze>>>0),Ae=mr<>>(ui>>>0))&Ot|mr<>31;break}return fe|0&&(w[fe>>2]=Ae&mr,w[fe+4>>2]=0),(Ie|0)==1?(ui=Ot|P&0,ci=D|0|0,Ai(ui|0),ci|0):(ci=Oh(Ie|0)|0,ui=rr>>>(ci>>>0)|0,ci=rr<<32-ci|mr>>>(ci>>>0)|0,Ai(ui|0),ci|0)}else{if(Ae)return fe|0&&(w[fe>>2]=(rr>>>0)%(Ie>>>0),w[fe+4>>2]=0),ui=0,ci=(rr>>>0)/(Ie>>>0)>>>0,Ai(ui|0),ci|0;if(!mr)return fe|0&&(w[fe>>2]=0,w[fe+4>>2]=(rr>>>0)%(Ze>>>0)),ui=0,ci=(rr>>>0)/(Ze>>>0)>>>0,Ai(ui|0),ci|0;if(Ae=Ze-1|0,!(Ae&Ze))return fe|0&&(w[fe>>2]=D|0,w[fe+4>>2]=Ae&rr|P&0),ui=0,ci=rr>>>((Oh(Ze|0)|0)>>>0),Ai(ui|0),ci|0;if(Ae=(ii(Ze|0)|0)-(ii(rr|0)|0)|0,Ae>>>0<=30){P=Ae+1|0,Ze=31-Ae|0,Ie=P,D=rr<>>(P>>>0),P=rr>>>(P>>>0),Ae=0,Ze=mr<>2]=D|0,w[fe+4>>2]=Ot|P&0,ui=0,ci=0,Ai(ui|0),ci|0):(ui=0,ci=0,Ai(ui|0),ci|0)}while(0);if(!Ie)rr=Ze,Ot=0,Ze=0;else{pn=F|0|0,mr=Jn|q&0,rr=Gs(pn|0,mr|0,-1,-1)|0,F=xr()|0,Ot=Ze,Ze=0;do q=Ot,Ot=Ae>>>31|Ot<<1,Ae=Ze|Ae<<1,q=D<<1|q>>>31|0,Jn=D>>>31|P<<1|0,of(rr|0,F|0,q|0,Jn|0)|0,ci=xr()|0,ui=ci>>31|((ci|0)<0?-1:0)<<1,Ze=ui&1,D=of(q|0,Jn|0,ui&pn|0,(((ci|0)<0?-1:0)>>31|((ci|0)<0?-1:0)<<1)&mr|0)|0,P=xr()|0,Ie=Ie-1|0;while(Ie|0);rr=Ot,Ot=0}return Ie=0,fe|0&&(w[fe>>2]=D,w[fe+4>>2]=P),ui=(Ae|0)>>>31|(rr|Ie)<<1|(Ie<<1|Ae>>>31)&0|Ot,ci=(Ae<<1|0)&-2|Ze,Ai(ui|0),ci|0}function ei(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0;return rr=P>>31|((P|0)<0?-1:0)<<1,Ot=((P|0)<0?-1:0)>>31|((P|0)<0?-1:0)<<1,Ae=q>>31|((q|0)<0?-1:0)<<1,fe=((q|0)<0?-1:0)>>31|((q|0)<0?-1:0)<<1,Ze=of(rr^D|0,Ot^P|0,rr|0,Ot|0)|0,Ie=xr()|0,D=Ae^rr,P=fe^Ot,of((Vp(Ze,Ie,of(Ae^F|0,fe^q|0,Ae|0,fe|0)|0,xr()|0,0)|0)^D|0,(xr()|0)^P|0,D|0,P|0)|0}function Zo(D,P){D=D|0,P=P|0;var F=0,q=0,fe=0,Ae=0;return Ae=D&65535,fe=P&65535,F=Hr(fe,Ae)|0,q=D>>>16,D=(F>>>16)+(Hr(fe,q)|0)|0,fe=P>>>16,P=Hr(fe,Ae)|0,Ai((D>>>16)+(Hr(fe,q)|0)+(((D&65535)+P|0)>>>16)|0),D+P<<16|F&65535|0|0}function ao(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0;return fe=D,Ae=F,F=Zo(fe,Ae)|0,D=xr()|0,Ai((Hr(P,Ae)|0)+(Hr(q,fe)|0)+D|D&0|0),F|0|0|0}function Iu(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0,Ie=0,Ze=0,Ot=0,rr=0;return fe=qr,qr=qr+16|0,Ze=fe|0,Ie=P>>31|((P|0)<0?-1:0)<<1,Ae=((P|0)<0?-1:0)>>31|((P|0)<0?-1:0)<<1,rr=q>>31|((q|0)<0?-1:0)<<1,Ot=((q|0)<0?-1:0)>>31|((q|0)<0?-1:0)<<1,D=of(Ie^D|0,Ae^P|0,Ie|0,Ae|0)|0,P=xr()|0,Vp(D,P,of(rr^F|0,Ot^q|0,rr|0,Ot|0)|0,xr()|0,Ze)|0,q=of(w[Ze>>2]^Ie|0,w[Ze+4>>2]^Ae|0,Ie|0,Ae|0)|0,F=xr()|0,qr=fe,Ai(F|0),q|0}function Kc(D,P,F,q){D=D|0,P=P|0,F=F|0,q=q|0;var fe=0,Ae=0;return Ae=qr,qr=qr+16|0,fe=Ae|0,Vp(D,P,F,q,fe)|0,qr=Ae,Ai(w[fe+4>>2]|0),w[fe>>2]|0|0}function sa(D,P,F){return D=D|0,P=P|0,F=F|0,(F|0)<32?(Ai(P>>F|0),D>>>F|(P&(1<>F-32|0)}function Rr(D,P,F){return D=D|0,P=P|0,F=F|0,(F|0)<32?(Ai(P>>>F|0),D>>>F|(P&(1<>>F-32|0)}function sr(D,P,F){return D=D|0,P=P|0,F=F|0,(F|0)<32?(Ai(P<>>32-F|0),D<=0?+pe(D+.5):+tn(D-.5)}function Pi(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0;if((F|0)>=8192)return da(D|0,P|0,F|0)|0,D|0;if(Ae=D|0,fe=D+F|0,(D&3)==(P&3)){for(;D&3;){if(!F)return Ae|0;nt[D>>0]=nt[P>>0]|0,D=D+1|0,P=P+1|0,F=F-1|0}for(F=fe&-4|0,q=F-64|0;(D|0)<=(q|0);)w[D>>2]=w[P>>2],w[D+4>>2]=w[P+4>>2],w[D+8>>2]=w[P+8>>2],w[D+12>>2]=w[P+12>>2],w[D+16>>2]=w[P+16>>2],w[D+20>>2]=w[P+20>>2],w[D+24>>2]=w[P+24>>2],w[D+28>>2]=w[P+28>>2],w[D+32>>2]=w[P+32>>2],w[D+36>>2]=w[P+36>>2],w[D+40>>2]=w[P+40>>2],w[D+44>>2]=w[P+44>>2],w[D+48>>2]=w[P+48>>2],w[D+52>>2]=w[P+52>>2],w[D+56>>2]=w[P+56>>2],w[D+60>>2]=w[P+60>>2],D=D+64|0,P=P+64|0;for(;(D|0)<(F|0);)w[D>>2]=w[P>>2],D=D+4|0,P=P+4|0}else for(F=fe-4|0;(D|0)<(F|0);)nt[D>>0]=nt[P>>0]|0,nt[D+1>>0]=nt[P+1>>0]|0,nt[D+2>>0]=nt[P+2>>0]|0,nt[D+3>>0]=nt[P+3>>0]|0,D=D+4|0,P=P+4|0;for(;(D|0)<(fe|0);)nt[D>>0]=nt[P>>0]|0,D=D+1|0,P=P+1|0;return Ae|0}function ji(D,P,F){D=D|0,P=P|0,F=F|0;var q=0,fe=0,Ae=0,Ie=0;if(Ae=D+F|0,P=P&255,(F|0)>=67){for(;D&3;)nt[D>>0]=P,D=D+1|0;for(q=Ae&-4|0,Ie=P|P<<8|P<<16|P<<24,fe=q-64|0;(D|0)<=(fe|0);)w[D>>2]=Ie,w[D+4>>2]=Ie,w[D+8>>2]=Ie,w[D+12>>2]=Ie,w[D+16>>2]=Ie,w[D+20>>2]=Ie,w[D+24>>2]=Ie,w[D+28>>2]=Ie,w[D+32>>2]=Ie,w[D+36>>2]=Ie,w[D+40>>2]=Ie,w[D+44>>2]=Ie,w[D+48>>2]=Ie,w[D+52>>2]=Ie,w[D+56>>2]=Ie,w[D+60>>2]=Ie,D=D+64|0;for(;(D|0)<(q|0);)w[D>>2]=Ie,D=D+4|0}for(;(D|0)<(Ae|0);)nt[D>>0]=P,D=D+1|0;return Ae-F|0}function Di(D){return D=+D,D>=0?+pe(D+.5):+tn(D-.5)}function jn(D){D=D|0;var P=0,F=0,q=0;return q=oa()|0,F=w[U>>2]|0,P=F+D|0,(D|0)>0&(P|0)<(F|0)|(P|0)<0?(hu(P|0)|0,uo(12),-1):(P|0)>(q|0)&&!(Fs(P|0)|0)?(uo(12),-1):(w[U>>2]=P,F|0)}return{___divdi3:ei,___muldi3:ao,___remdi3:Iu,___uremdi3:Kc,_areNeighborCells:P0,_bitshift64Ashr:sa,_bitshift64Lshr:Rr,_bitshift64Shl:sr,_calloc:hl,_cellAreaKm2:m0,_cellAreaM2:Vd,_cellAreaRads2:o0,_cellToBoundary:f0,_cellToCenterChild:Np,_cellToChildPos:Fd,_cellToChildren:y0,_cellToChildrenSize:H0,_cellToLatLng:i0,_cellToLocalIj:Ds,_cellToParent:pp,_cellToVertex:Jl,_cellToVertexes:yh,_cellsToDirectedEdge:I0,_cellsToLinkedMultiPolygon:Rh,_childPosToCell:Up,_compactCells:L0,_destroyLinkedMultiPolygon:$o,_directedEdgeToBoundary:w0,_directedEdgeToCells:Mc,_edgeLengthKm:Sn,_edgeLengthM:mi,_edgeLengthRads:_r,_emscripten_replace_memory:Zu,_free:Pu,_getBaseCellNumber:wp,_getDirectedEdgeDestination:d0,_getDirectedEdgeOrigin:V0,_getHexagonAreaAvgKm2:B0,_getHexagonAreaAvgM2:mp,_getHexagonEdgeLengthAvgKm:J0,_getHexagonEdgeLengthAvgM:G0,_getIcosahedronFaces:p0,_getNumCells:W0,_getPentagons:Rd,_getRes0Cells:Hp,_getResolution:Mp,_greatCircleDistanceKm:Sp,_greatCircleDistanceM:df,_greatCircleDistanceRads:F0,_gridDisk:Gl,_gridDiskDistances:Oc,_gridDistance:ru,_gridPathCells:nu,_gridPathCellsSize:xs,_gridRingUnsafe:Kh,_i64Add:Gs,_i64Subtract:of,_isPentagon:gh,_isResClassIII:c0,_isValidCell:op,_isValidDirectedEdge:Q0,_isValidVertex:Wd,_latLngToCell:qp,_llvm_maxnum_f64:ti,_llvm_minnum_f64:_o,_llvm_round_f64:bo,_localIjToCell:Bs,_malloc:Qf,_maxFaceCount:sm,_maxGridDiskSize:Cc,_maxPolygonToCellsSize:Zf,_memcpy:Pi,_memset:ji,_originToDirectedEdges:R0,_pentagonCount:Id,_polygonToCells:Kf,_readInt64AsDoubleFromPointer:Mu,_res0CellCount:id,_round:Di,_sbrk:jn,_sizeOfCellBoundary:Ou,_sizeOfCoordIJ:Pc,_sizeOfGeoLoop:Ba,_sizeOfGeoPolygon:Lu,_sizeOfH3Index:qu,_sizeOfLatLng:ms,_sizeOfLinkedGeoPolygon:uc,_uncompactCells:_m,_uncompactCellsSize:zp,_vertexToLatLng:Gd,establishStackSpace:Nc,stackAlloc:Bc,stackRestore:rl,stackSave:ou}}(_l,cn,Ra),Xn=Wr.___divdi3=an.___divdi3,vi=Wr.___muldi3=an.___muldi3,to=Wr.___remdi3=an.___remdi3,zo=Wr.___uremdi3=an.___uremdi3,Ia=Wr._areNeighborCells=an._areNeighborCells,Sa=Wr._bitshift64Ashr=an._bitshift64Ashr,fa=Wr._bitshift64Lshr=an._bitshift64Lshr,cs=Wr._bitshift64Shl=an._bitshift64Shl,Ys=Wr._calloc=an._calloc,mu=Wr._cellAreaKm2=an._cellAreaKm2,Is=Wr._cellAreaM2=an._cellAreaM2,Sl=Wr._cellAreaRads2=an._cellAreaRads2,wl=Wr._cellToBoundary=an._cellToBoundary,vu=Wr._cellToCenterChild=an._cellToCenterChild,ml=Wr._cellToChildPos=an._cellToChildPos,ll=Wr._cellToChildren=an._cellToChildren,Fu=Wr._cellToChildrenSize=an._cellToChildrenSize,Bu=Wr._cellToLatLng=an._cellToLatLng,al=Wr._cellToLocalIj=an._cellToLocalIj,Ac=Wr._cellToParent=an._cellToParent,$l=Wr._cellToVertex=an._cellToVertex,Yu=Wr._cellToVertexes=an._cellToVertexes,Gu=Wr._cellsToDirectedEdge=an._cellsToDirectedEdge,Sf=Wr._cellsToLinkedMultiPolygon=an._cellsToLinkedMultiPolygon,Cl=Wr._childPosToCell=an._childPosToCell,Df=Wr._compactCells=an._compactCells,bu=Wr._destroyLinkedMultiPolygon=an._destroyLinkedMultiPolygon,Ic=Wr._directedEdgeToBoundary=an._directedEdgeToBoundary,af=Wr._directedEdgeToCells=an._directedEdgeToCells,zf=Wr._edgeLengthKm=an._edgeLengthKm,tf=Wr._edgeLengthM=an._edgeLengthM,kf=Wr._edgeLengthRads=an._edgeLengthRads,ff=Wr._emscripten_replace_memory=an._emscripten_replace_memory,vf=Wr._free=an._free,wc=Wr._getBaseCellNumber=an._getBaseCellNumber,ac=Wr._getDirectedEdgeDestination=an._getDirectedEdgeDestination,cl=Wr._getDirectedEdgeOrigin=an._getDirectedEdgeOrigin,Us=Wr._getHexagonAreaAvgKm2=an._getHexagonAreaAvgKm2,vl=Wr._getHexagonAreaAvgM2=an._getHexagonAreaAvgM2,iu=Wr._getHexagonEdgeLengthAvgKm=an._getHexagonEdgeLengthAvgKm,Ca=Wr._getHexagonEdgeLengthAvgM=an._getHexagonEdgeLengthAvgM,xa=Wr._getIcosahedronFaces=an._getIcosahedronFaces,Dl=Wr._getNumCells=an._getNumCells,Gf=Wr._getPentagons=an._getPentagons,Li=Wr._getRes0Cells=an._getRes0Cells,Fr=Wr._getResolution=an._getResolution,Hl=Wr._greatCircleDistanceKm=an._greatCircleDistanceKm,Ur=Wr._greatCircleDistanceM=an._greatCircleDistanceM,ja=Wr._greatCircleDistanceRads=an._greatCircleDistanceRads,cu=Wr._gridDisk=an._gridDisk,fu=Wr._gridDiskDistances=an._gridDiskDistances,nc=Wr._gridDistance=an._gridDistance,Su=Wr._gridPathCells=an._gridPathCells,Wu=Wr._gridPathCellsSize=an._gridPathCellsSize,Hc=Wr._gridRingUnsafe=an._gridRingUnsafe,Lc=Wr._i64Add=an._i64Add,Kl=Wr._i64Subtract=an._i64Subtract,Ec=Wr._isPentagon=an._isPentagon,bl=Wr._isResClassIII=an._isResClassIII,kl=Wr._isValidCell=an._isValidCell,Wc=Wr._isValidDirectedEdge=an._isValidDirectedEdge,Tl=Wr._isValidVertex=an._isValidVertex,ql=Wr._latLngToCell=an._latLngToCell,ic=Wr._llvm_maxnum_f64=an._llvm_maxnum_f64,Ls=Wr._llvm_minnum_f64=an._llvm_minnum_f64,cc=Wr._llvm_round_f64=an._llvm_round_f64,gu=Wr._localIjToCell=an._localIjToCell,Cu=Wr._malloc=an._malloc,Qc=Wr._maxFaceCount=an._maxFaceCount,hf=Wr._maxGridDiskSize=an._maxGridDiskSize,Xc=Wr._maxPolygonToCellsSize=an._maxPolygonToCellsSize,Al=Wr._memcpy=an._memcpy,Sc=Wr._memset=an._memset,Ka=Wr._originToDirectedEdges=an._originToDirectedEdges,ea=Wr._pentagonCount=an._pentagonCount,qo=Wr._polygonToCells=an._polygonToCells,tu=Wr._readInt64AsDoubleFromPointer=an._readInt64AsDoubleFromPointer,bh=Wr._res0CellCount=an._res0CellCount,pc=Wr._round=an._round,Wf=Wr._sbrk=an._sbrk,Tu=Wr._sizeOfCellBoundary=an._sizeOfCellBoundary,Ih=Wr._sizeOfCoordIJ=an._sizeOfCoordIJ,Bl=Wr._sizeOfGeoLoop=an._sizeOfGeoLoop,Xf=Wr._sizeOfGeoPolygon=an._sizeOfGeoPolygon,fh=Wr._sizeOfH3Index=an._sizeOfH3Index,uf=Wr._sizeOfLatLng=an._sizeOfLatLng,Yf=Wr._sizeOfLinkedGeoPolygon=an._sizeOfLinkedGeoPolygon,rh=Wr._uncompactCells=an._uncompactCells,ud=Wr._uncompactCellsSize=an._uncompactCellsSize,fp=Wr._vertexToLatLng=an._vertexToLatLng,h=Wr.establishStackSpace=an.establishStackSpace,v=Wr.stackAlloc=an.stackAlloc,B=Wr.stackRestore=an.stackRestore,W=Wr.stackSave=an.stackSave;if(Wr.asm=an,Wr.cwrap=so,Wr.setValue=Mr,Wr.getValue=Zr,Qs){St(Qs)||(Qs=gn(Qs));{rc("memory initializer");var _e=function(te){te.byteLength&&(te=new Uint8Array(te)),Vo.set(te,yr),Wr.memoryInitializerRequest&&delete Wr.memoryInitializerRequest.response,Ha("memory initializer")},_t=function(){un(Qs,_e,function(){throw"could not load memory initializer "+Qs})},jt=Ol(Qs);if(jt)_e(jt.buffer);else if(Wr.memoryInitializerRequest){var ie=function(){var te=Wr.memoryInitializerRequest,me=te.response;if(te.status!==200&&te.status!==0){var He=Ol(Wr.memoryInitializerRequestURL);if(He)me=He.buffer;else{console.warn("a problem seems to have happened with Module.memoryInitializerRequest, status: "+te.status+", retrying "+Qs),_t();return}}_e(me)};Wr.memoryInitializerRequest.response?setTimeout(ie,0):Wr.memoryInitializerRequest.addEventListener("load",ie)}else _t()}}var f;Xs=function te(){f||L(),f||(Xs=te)};function L(te){if(te=te||Vt,Vs>0||(Pa(),Vs>0))return;function me(){f||(f=!0,!Vn&&(ss(),si(),Wr.onRuntimeInitialized&&Wr.onRuntimeInitialized(),Ms()))}Wr.setStatus?(Wr.setStatus("Running..."),setTimeout(function(){setTimeout(function(){Wr.setStatus("")},1),me()},1)):me()}Wr.run=L;function ee(te){throw Wr.onAbort&&Wr.onAbort(te),te+="",Zi(te),ho(te),Vn=!0,"abort("+te+"). Build with -s ASSERTIONS=1 for more info."}if(Wr.abort=ee,Wr.preInit)for(typeof Wr.preInit=="function"&&(Wr.preInit=[Wr.preInit]);Wr.preInit.length>0;)Wr.preInit.pop()();return L(),Pn}(typeof R=="object"?R:{}),V="number",y=V,p=V,$=V,X=V,se=V,ae=V,ce=[["sizeOfH3Index",V],["sizeOfLatLng",V],["sizeOfCellBoundary",V],["sizeOfGeoLoop",V],["sizeOfGeoPolygon",V],["sizeOfLinkedGeoPolygon",V],["sizeOfCoordIJ",V],["readInt64AsDoubleFromPointer",V],["isValidCell",p,[$,X]],["latLngToCell",y,[V,V,se,ae]],["cellToLatLng",y,[$,X,ae]],["cellToBoundary",y,[$,X,ae]],["maxGridDiskSize",y,[V,ae]],["gridDisk",y,[$,X,V,ae]],["gridDiskDistances",y,[$,X,V,ae,ae]],["gridRingUnsafe",y,[$,X,V,ae]],["maxPolygonToCellsSize",y,[ae,se,V,ae]],["polygonToCells",y,[ae,se,V,ae]],["cellsToLinkedMultiPolygon",y,[ae,V,ae]],["destroyLinkedMultiPolygon",null,[ae]],["compactCells",y,[ae,ae,V,V]],["uncompactCells",y,[ae,V,V,ae,V,se]],["uncompactCellsSize",y,[ae,V,V,se,ae]],["isPentagon",p,[$,X]],["isResClassIII",p,[$,X]],["getBaseCellNumber",V,[$,X]],["getResolution",V,[$,X]],["maxFaceCount",y,[$,X,ae]],["getIcosahedronFaces",y,[$,X,ae]],["cellToParent",y,[$,X,se,ae]],["cellToChildren",y,[$,X,se,ae]],["cellToCenterChild",y,[$,X,se,ae]],["cellToChildrenSize",y,[$,X,se,ae]],["cellToChildPos",y,[$,X,se,ae]],["childPosToCell",y,[V,V,$,X,se,ae]],["areNeighborCells",y,[$,X,$,X,ae]],["cellsToDirectedEdge",y,[$,X,$,X,ae]],["getDirectedEdgeOrigin",y,[$,X,ae]],["getDirectedEdgeDestination",y,[$,X,ae]],["isValidDirectedEdge",p,[$,X]],["directedEdgeToCells",y,[$,X,ae]],["originToDirectedEdges",y,[$,X,ae]],["directedEdgeToBoundary",y,[$,X,ae]],["gridDistance",y,[$,X,$,X,ae]],["gridPathCells",y,[$,X,$,X,ae]],["gridPathCellsSize",y,[$,X,$,X,ae]],["cellToLocalIj",y,[$,X,$,X,V,ae]],["localIjToCell",y,[$,X,ae,V,ae]],["getHexagonAreaAvgM2",y,[se,ae]],["getHexagonAreaAvgKm2",y,[se,ae]],["getHexagonEdgeLengthAvgM",y,[se,ae]],["getHexagonEdgeLengthAvgKm",y,[se,ae]],["greatCircleDistanceM",V,[ae,ae]],["greatCircleDistanceKm",V,[ae,ae]],["greatCircleDistanceRads",V,[ae,ae]],["cellAreaM2",y,[$,X,ae]],["cellAreaKm2",y,[$,X,ae]],["cellAreaRads2",y,[$,X,ae]],["edgeLengthM",y,[$,X,ae]],["edgeLengthKm",y,[$,X,ae]],["edgeLengthRads",y,[$,X,ae]],["getNumCells",y,[se,ae]],["getRes0Cells",y,[ae]],["res0CellCount",V],["getPentagons",y,[V,ae]],["pentagonCount",V],["cellToVertex",y,[$,X,V,ae]],["cellToVertexes",y,[$,X,ae]],["vertexToLatLng",y,[$,X,ae]],["isValidVertex",p,[$,X]]],le=0,De=1,we=2,Ee=3,qe=4,Ge=5,ct=6,Ve=7,ut=8,Xe=9,Rt=10,gt=11,Ct=12,tt=13,Ne=14,bt=15,et={};et[le]="Success",et[De]="The operation failed but a more specific error is not available",et[we]="Argument was outside of acceptable range",et[Ee]="Latitude or longitude arguments were outside of acceptable range",et[qe]="Resolution argument was outside of acceptable range",et[Ge]="Cell argument was not valid",et[ct]="Directed edge argument was not valid",et[Ve]="Undirected edge argument was not valid",et[ut]="Vertex argument was not valid",et[Xe]="Pentagon distortion was encountered",et[Rt]="Duplicate input",et[gt]="Cell arguments were not neighbors",et[Ct]="Cell arguments had incompatible resolutions",et[tt]="Memory allocation failed",et[Ne]="Bounds of provided memory were insufficient",et[bt]="Mode or flags argument was not valid";var pt=1e3,Ke=1001,ft=1002,wt={};wt[pt]="Unknown unit",wt[Ke]="Array length out of bounds",wt[ft]="Got unexpected null value for H3 index";var Se="Unknown error";function Ft(Pn,Wr,Ci){var at=Ci&&"value"in Ci,Vt=new Error((Pn[Wr]||Se)+" (code: "+Wr+(at?", value: "+Ci.value:"")+")");return Vt.code=Wr,Vt}function mt(Pn,Wr){var Ci=arguments.length===2?{value:Wr}:{};return Ft(et,Pn,Ci)}function ot(Pn,Wr){var Ci=arguments.length===2?{value:Wr}:{};return Ft(wt,Pn,Ci)}function We(Pn){if(Pn!==0)throw mt(Pn)}var Me={};ce.forEach(function(Wr){Me[Wr[0]]=R.cwrap.apply(R,Wr)});var st=16,Qe=0,dr=4,Kt=4,Yr=8,hn=8,ln=Me.sizeOfH3Index(),oi=Me.sizeOfLatLng(),Nn=Me.sizeOfCellBoundary(),$n=Me.sizeOfGeoPolygon(),_i=Me.sizeOfGeoLoop(),Qn=Me.sizeOfLinkedGeoPolygon(),Ji=Me.sizeOfCoordIJ(),ni={m:"m",m2:"m2",km:"km",km2:"km2",rads:"rads",rads2:"rads2"};function Ei(Pn){if(typeof Pn!="number"||Pn<0||Pn>15||Math.floor(Pn)!==Pn)throw mt(qe,Pn);return Pn}function xo(Pn){if(!Pn)throw ot(ft);return Pn}var sn=Math.pow(2,32)-1;function li(Pn){if(Pn>sn)throw ot(Ke,Pn);return Pn}var En=/[^0-9a-fA-F]/;function or(Pn){if(Array.isArray(Pn)&&Pn.length===2&&Number.isInteger(Pn[0])&&Number.isInteger(Pn[1]))return Pn;if(typeof Pn!="string"||En.test(Pn))return[0,0];var Wr=parseInt(Pn.substring(0,Pn.length-8),st),Ci=parseInt(Pn.substring(Pn.length-8),st);return[Ci,Wr]}function qi(Pn){if(Pn>=0)return Pn.toString(st);Pn=Pn&2147483647;var Wr=Mo(8,Pn.toString(st)),Ci=(parseInt(Wr[0],st)+8).toString(st);return Wr=Ci+Wr.substring(1),Wr}function Bo(Pn,Wr){return qi(Wr)+Mo(8,qi(Pn))}function Mo(Pn,Wr){for(var Ci=Pn-Wr.length,at="",Vt=0;Vt0){un=R._calloc(Ci,_i);for(var Zi=0;Zi0){for(var gn=R.getValue(Pn+at,"i32"),un=0;un=0&&Ci.push(Vt)}return Ci}function At(Pn){var Wr=or(Pn),Ci=Wr[0],at=Wr[1];return!!Me.isValidCell(Ci,at)}function Bt(Pn){var Wr=or(Pn),Ci=Wr[0],at=Wr[1];return!!Me.isPentagon(Ci,at)}function Jt(Pn){var Wr=or(Pn),Ci=Wr[0],at=Wr[1];return!!Me.isResClassIII(Ci,at)}function ar(Pn){var Wr=or(Pn),Ci=Wr[0],at=Wr[1];return Me.getBaseCellNumber(Ci,at)}function hr(Pn){var Wr=or(Pn),Ci=Wr[0],at=Wr[1],Vt=R._malloc(dr);try{We(Me.maxFaceCount(Ci,at,Vt));var gr=R.getValue(Vt,"i32"),gn=R._malloc(dr*gr);try{return We(Me.getIcosahedronFaces(Ci,at,gn)),$e(gn,gr)}finally{R._free(gn)}}finally{R._free(Vt)}}function Gt(Pn){var Wr=or(Pn),Ci=Wr[0],at=Wr[1];return Me.isValidCell(Ci,at)?Me.getResolution(Ci,at):-1}function Tr(Pn,Wr,Ci){var at=R._malloc(oi);R.HEAPF64.set([Pn,Wr].map(_c),at/Yr);var Vt=R._malloc(ln);try{return We(Me.latLngToCell(at,Ci,Vt)),xo(Un(Vt))}finally{R._free(Vt),R._free(at)}}function nn(Pn){var Wr=R._malloc(oi),Ci=or(Pn),at=Ci[0],Vt=Ci[1];try{return We(Me.cellToLatLng(at,Vt,Wr)),kr(Wr)}finally{R._free(Wr)}}function bn(Pn,Wr){var Ci=R._malloc(Nn),at=or(Pn),Vt=at[0],gr=at[1];try{return We(Me.cellToBoundary(Vt,gr,Ci)),Dn(Ci,Wr,Wr)}finally{R._free(Ci)}}function Bi(Pn,Wr){var Ci=or(Pn),at=Ci[0],Vt=Ci[1],gr=R._malloc(ln);try{return We(Me.cellToParent(at,Vt,Wr,gr)),xo(Un(gr))}finally{R._free(gr)}}function on(Pn,Wr){if(!At(Pn))return[];var Ci=or(Pn),at=Ci[0],Vt=Ci[1],gr=li(dn(Pn,Wr)),gn=R._calloc(gr,ln);try{return We(Me.cellToChildren(at,Vt,Wr,gn)),it(gn,gr)}finally{R._free(gn)}}function dn(Pn,Wr){if(!At(Pn))throw mt(Ge);var Ci=or(Pn),at=Ci[0],Vt=Ci[1],gr=R._malloc(hn);try{return We(Me.cellToChildrenSize(at,Vt,Wr,gr)),Fo(gr)}finally{R._free(gr)}}function ri(Pn,Wr){var Ci=or(Pn),at=Ci[0],Vt=Ci[1],gr=R._malloc(ln);try{return We(Me.cellToCenterChild(at,Vt,Wr,gr)),xo(Un(gr))}finally{R._free(gr)}}function Wn(Pn,Wr){var Ci=or(Pn),at=Ci[0],Vt=Ci[1],gr=R._malloc(hn);try{return We(Me.cellToChildPos(at,Vt,Wr,gr)),Fo(gr)}finally{R._free(gr)}}function Rn(Pn,Wr,Ci){var at=Ii(Pn),Vt=at[0],gr=at[1],gn=or(Wr),un=gn[0],Zi=gn[1],ho=R._malloc(ln);try{return We(Me.childPosToCell(Vt,gr,un,Zi,Ci,ho)),xo(Un(ho))}finally{R._free(ho)}}function di(Pn,Wr){var Ci=or(Pn),at=Ci[0],Vt=Ci[1],gr=R._malloc(hn);try{We(Me.maxGridDiskSize(Wr,gr));var gn=li(Fo(gr)),un=R._calloc(gn,ln);try{return We(Me.gridDisk(at,Vt,Wr,un)),it(un,gn)}finally{R._free(un)}}finally{R._free(gr)}}function zi(Pn,Wr){var Ci=or(Pn),at=Ci[0],Vt=Ci[1],gr=R._malloc(hn);try{We(Me.maxGridDiskSize(Wr,gr));var gn=li(Fo(gr)),un=R._calloc(gn,ln),Zi=R._calloc(gn,dr);try{We(Me.gridDiskDistances(at,Vt,Wr,un,Zi));for(var ho=[],Na=0;Na\s*\(/gm,"{anonymous}()@"):"Unknown Stack Trace",ho=V.console&&(V.console.warn||V.console.log);return ho&&ho.call(V.console,gn,Zi),at.apply(this,arguments)}}var ct;typeof Object.assign!="function"?ct=function(Vt){if(Vt===$||Vt===null)throw new TypeError("Cannot convert undefined or null to object");for(var gr=Object(Vt),gn=1;gn-1}function pt(at){return at.trim().split(/\s+/g)}function Ke(at,Vt,gr){if(at.indexOf&&!gr)return at.indexOf(Vt);for(var gn=0;gnLr[Vt]}):gn=gn.sort()),gn}function Se(at,Vt){for(var gr,gn,un=Vt[0].toUpperCase()+Vt.slice(1),Zi=0;Zi1&&!gr.firstMultiple?gr.firstMultiple=zn(Vt):un===1&&(gr.firstMultiple=!1);var Zi=gr.firstInput,ho=gr.firstMultiple,Na=ho?ho.center:Zi.center,mn=Vt.center=Un(gn);Vt.timeStamp=De(),Vt.deltaTime=Vt.timeStamp-Zi.timeStamp,Vt.angle=xt(Na,mn),Vt.distance=Fo(Na,mn),ko(gr,Vt),Vt.offsetDirection=Ki(Vt.deltaX,Vt.deltaY);var Lr=Hi(Vt.deltaTime,Vt.deltaX,Vt.deltaY);Vt.overallVelocityX=Lr.x,Vt.overallVelocityY=Lr.y,Vt.overallVelocity=le(Lr.x)>le(Lr.y)?Lr.x:Lr.y,Vt.scale=ho?kt(ho.pointers,gn):1,Vt.rotation=ho?it(ho.pointers,gn):0,Vt.maxPointers=gr.prevInput?Vt.pointers.length>gr.prevInput.maxPointers?Vt.pointers.length:gr.prevInput.maxPointers:Vt.pointers.length,Fn(gr,Vt);var yr=at.element;bt(Vt.srcEvent.target,yr)&&(yr=Vt.srcEvent.target),Vt.target=yr}function ko(at,Vt){var gr=Vt.center,gn=at.offsetDelta||{},un=at.prevDelta||{},Zi=at.prevInput||{};(Vt.eventType===oi||Zi.eventType===$n)&&(un=at.prevDelta={x:Zi.deltaX||0,y:Zi.deltaY||0},gn=at.offsetDelta={x:gr.x,y:gr.y}),Vt.deltaX=un.x+(gr.x-gn.x),Vt.deltaY=un.y+(gr.y-gn.y)}function Fn(at,Vt){var gr=at.lastInterval||Vt,gn=Vt.timeStamp-gr.timeStamp,un,Zi,ho,Na;if(Vt.eventType!=_i&&(gn>ln||gr.velocity===$)){var mn=Vt.deltaX-gr.deltaX,Lr=Vt.deltaY-gr.deltaY,yr=Hi(gn,mn,Lr);Zi=yr.x,ho=yr.y,un=le(yr.x)>le(yr.y)?yr.x:yr.y,Na=Ki(mn,Lr),at.lastInterval=Vt}else un=gr.velocity,Zi=gr.velocityX,ho=gr.velocityY,Na=gr.direction;Vt.velocity=un,Vt.velocityX=Zi,Vt.velocityY=ho,Vt.direction=Na}function zn(at){for(var Vt=[],gr=0;gr=le(Vt)?at<0?Ji:ni:Vt<0?Ei:xo}function Fo(at,Vt,gr){gr||(gr=or);var gn=Vt[gr[0]]-at[gr[0]],un=Vt[gr[1]]-at[gr[1]];return Math.sqrt(gn*gn+un*un)}function xt(at,Vt,gr){gr||(gr=or);var gn=Vt[gr[0]]-at[gr[0]],un=Vt[gr[1]]-at[gr[1]];return Math.atan2(un,gn)*180/Math.PI}function it(at,Vt){return xt(Vt[1],Vt[0],qi)+xt(at[1],at[0],qi)}function kt(at,Vt){return Fo(Vt[0],Vt[1],qi)/Fo(at[0],at[1],qi)}var ir={mousedown:oi,mousemove:Nn,mouseup:$n},Pr="mousedown",kr="mousemove mouseup";function An(){this.evEl=Pr,this.evWin=kr,this.pressed=!1,Bo.apply(this,arguments)}Xe(An,Bo,{handler:function(Vt){var gr=ir[Vt.type];gr&oi&&Vt.button===0&&(this.pressed=!0),gr&Nn&&Vt.which!==1&&(gr=$n),this.pressed&&(gr&$n&&(this.pressed=!1),this.callback(this.manager,gr,{pointers:[Vt],changedPointers:[Vt],pointerType:Yr,srcEvent:Vt}))}});var Dn={pointerdown:oi,pointermove:Nn,pointerup:$n,pointercancel:_i,pointerout:_i},Ht={2:dr,3:Kt,4:Yr,5:hn},Lt="pointerdown",je="pointermove pointerup pointercancel";V.MSPointerEvent&&!V.PointerEvent&&(Lt="MSPointerDown",je="MSPointerMove MSPointerUp MSPointerCancel");function $e(){this.evEl=Lt,this.evWin=je,Bo.apply(this,arguments),this.store=this.manager.session.pointerEvents=[]}Xe($e,Bo,{handler:function(Vt){var gr=this.store,gn=!1,un=Vt.type.toLowerCase().replace("ms",""),Zi=Dn[un],ho=Ht[Vt.pointerType]||Vt.pointerType,Na=ho==dr,mn=Ke(gr,Vt.pointerId,"pointerId");Zi&oi&&(Vt.button===0||Na)?mn<0&&(gr.push(Vt),mn=gr.length-1):Zi&($n|_i)&&(gn=!0),!(mn<0)&&(gr[mn]=Vt,this.callback(this.manager,Zi,{pointers:gr,changedPointers:[Vt],pointerType:ho,srcEvent:Vt}),gn&&gr.splice(mn,1))}});var At={touchstart:oi,touchmove:Nn,touchend:$n,touchcancel:_i},Bt="touchstart",Jt="touchstart touchmove touchend touchcancel";function ar(){this.evTarget=Bt,this.evWin=Jt,this.started=!1,Bo.apply(this,arguments)}Xe(ar,Bo,{handler:function(Vt){var gr=At[Vt.type];if(gr===oi&&(this.started=!0),!!this.started){var gn=hr.call(this,Vt,gr);gr&($n|_i)&&gn[0].length-gn[1].length===0&&(this.started=!1),this.callback(this.manager,gr,{pointers:gn[0],changedPointers:gn[1],pointerType:dr,srcEvent:Vt})}}});function hr(at,Vt){var gr=ft(at.touches),gn=ft(at.changedTouches);return Vt&($n|_i)&&(gr=wt(gr.concat(gn),"identifier",!0)),[gr,gn]}var Gt={touchstart:oi,touchmove:Nn,touchend:$n,touchcancel:_i},Tr="touchstart touchmove touchend touchcancel";function nn(){this.evTarget=Tr,this.targetIds={},Bo.apply(this,arguments)}Xe(nn,Bo,{handler:function(Vt){var gr=Gt[Vt.type],gn=bn.call(this,Vt,gr);gn&&this.callback(this.manager,gr,{pointers:gn[0],changedPointers:gn[1],pointerType:dr,srcEvent:Vt})}});function bn(at,Vt){var gr=ft(at.touches),gn=this.targetIds;if(Vt&(oi|Nn)&&gr.length===1)return gn[gr[0].identifier]=!0,[gr,gr];var un,Zi,ho=ft(at.changedTouches),Na=[],mn=this.target;if(Zi=gr.filter(function(Lr){return bt(Lr.target,mn)}),Vt===oi)for(un=0;un-1&&gn.splice(Zi,1)};setTimeout(un,Bi)}}function Rn(at){for(var Vt=at.srcEvent.clientX,gr=at.srcEvent.clientY,gn=0;gn-1&&this.requireFail.splice(Vt,1),this},hasRequireFailures:function(){return this.requireFail.length>0},canRecognizeWith:function(at){return!!this.simultaneous[at.id]},emit:function(at){var Vt=this,gr=this.state;function gn(un){Vt.manager.emit(un,at)}gr=On&&gn(Vt.options.event+_s(gr))},tryEmit:function(at){if(this.canEmit())return this.emit(at);this.state=ks},canEmit:function(){for(var at=0;atVt.threshold&&un&Vt.direction},attrTest:function(at){return hs.prototype.attrTest.call(this,at)&&(this.state&ga||!(this.state&ga)&&this.directionTest(at))},emit:function(at){this.pX=at.deltaX,this.pY=at.deltaY;var Vt=Ks(at.direction);Vt&&(at.additionalEvent=this.options.event+Vt),this._super.emit.call(this,at)}});function Fa(){hs.apply(this,arguments)}Xe(Fa,hs,{defaults:{event:"pinch",threshold:0,pointers:2},getTouchAction:function(){return[ba]},attrTest:function(at){return this._super.attrTest.call(this,at)&&(Math.abs(at.scale-1)>this.options.threshold||this.state&ga)},emit:function(at){if(at.scale!==1){var Vt=at.scale<1?"in":"out";at.additionalEvent=this.options.event+Vt}this._super.emit.call(this,at)}});function dc(){as.apply(this,arguments),this._timer=null,this._input=null}Xe(dc,as,{defaults:{event:"press",pointers:1,time:251,threshold:9},getTouchAction:function(){return[Lo]},process:function(at){var Vt=this.options,gr=at.pointers.length===Vt.pointers,gn=at.distanceVt.time;if(this._input=at,!gn||!gr||at.eventType&($n|_i)&&!un)this.reset();else if(at.eventType&oi)this.reset(),this._timer=we(function(){this.state=gi,this.tryEmit()},Vt.time,this);else if(at.eventType&$n)return gi;return ks},reset:function(){clearTimeout(this._timer)},emit:function(at){this.state===gi&&(at&&at.eventType&$n?this.manager.emit(this.options.event+"up",at):(this._input.timeStamp=De(),this.manager.emit(this.options.event,this._input)))}});function el(){hs.apply(this,arguments)}Xe(el,hs,{defaults:{event:"rotate",threshold:0,pointers:2},getTouchAction:function(){return[ba]},attrTest:function(at){return this._super.attrTest.call(this,at)&&(Math.abs(at.rotation)>this.options.threshold||this.state&ga)}});function fl(){hs.apply(this,arguments)}Xe(fl,hs,{defaults:{event:"swipe",threshold:10,velocity:.3,direction:sn|li,pointers:1},getTouchAction:function(){return Ju.prototype.getTouchAction.call(this)},attrTest:function(at){var Vt=this.options.direction,gr;return Vt&(sn|li)?gr=at.overallVelocity:Vt&sn?gr=at.overallVelocityX:Vt&li&&(gr=at.overallVelocityY),this._super.attrTest.call(this,at)&&Vt&at.offsetDirection&&at.distance>this.options.threshold&&at.maxPointers==this.options.pointers&&le(gr)>this.options.velocity&&at.eventType&$n},emit:function(at){var Vt=Ks(at.offsetDirection);Vt&&this.manager.emit(this.options.event+Vt,at),this.manager.emit(this.options.event,at)}});function As(){as.apply(this,arguments),this.pTime=!1,this.pCenter=!1,this._timer=null,this._input=null,this.count=0}Xe(As,as,{defaults:{event:"tap",pointers:1,taps:1,interval:300,time:250,threshold:9,posThreshold:10},getTouchAction:function(){return[eo]},process:function(at){var Vt=this.options,gr=at.pointers.length===Vt.pointers,gn=at.distance>1,le=-7,De=V?p-1:0,we=V?-1:1,Ee=A[R+De];for(De+=we,$=Ee&(1<<-le)-1,Ee>>=-le,le+=se;le>0;$=$*256+A[R+De],De+=we,le-=8);for(X=$&(1<<-le)-1,$>>=-le,le+=y;le>0;X=X*256+A[R+De],De+=we,le-=8);if($===0)$=1-ce;else{if($===ae)return X?NaN:(Ee?-1:1)*(1/0);X=X+Math.pow(2,y),$=$-ce}return(Ee?-1:1)*X*Math.pow(2,$-y)},ye.write=function(A,R,V,y,p,$){var X,se,ae,ce=$*8-p-1,le=(1<>1,we=p===23?Math.pow(2,-24)-Math.pow(2,-77):0,Ee=y?0:$-1,qe=y?1:-1,Ge=R<0||R===0&&1/R<0?1:0;for(R=Math.abs(R),isNaN(R)||R===1/0?(se=isNaN(R)?1:0,X=le):(X=Math.floor(Math.log(R)/Math.LN2),R*(ae=Math.pow(2,-X))<1&&(X--,ae*=2),X+De>=1?R+=we/ae:R+=we*Math.pow(2,1-De),R*ae>=2&&(X++,ae/=2),X+De>=le?(se=0,X=le):X+De>=1?(se=(R*ae-1)*Math.pow(2,p),X=X+De):(se=R*Math.pow(2,De-1)*Math.pow(2,p),X=0));p>=8;A[V+Ee]=se&255,Ee+=qe,se/=256,p-=8);for(X=X<0;A[V+Ee]=X&255,Ee+=qe,X/=256,ce-=8);A[V+Ee-qe]|=Ge*128}},3039:function(Ye,ye){"use strict";Object.defineProperty(ye,"__esModule",{value:!0});var A=Symbol.for("INJECTION");function R(X,se,ae,ce){function le(){return ce&&!Reflect.hasMetadata(A,this,se)&&Reflect.defineMetadata(A,ae(),this,se),Reflect.hasMetadata(A,this,se)?Reflect.getMetadata(A,this,se):ae()}function De(we){Reflect.defineMetadata(A,we,this,se)}Object.defineProperty(X,se,{configurable:!0,enumerable:!0,get:le,set:De})}function V(X,se){return function(ae){return function(ce,le){var De=function(){return X.get(ae)};R(ce,le,De,se)}}}ye.makePropertyInjectDecorator=V;function y(X,se){return function(ae,ce){return function(le,De){var we=function(){return X.getNamed(ae,ce)};R(le,De,we,se)}}}ye.makePropertyInjectNamedDecorator=y;function p(X,se){return function(ae,ce,le){return function(De,we){var Ee=function(){return X.getTagged(ae,ce,le)};R(De,we,Ee,se)}}}ye.makePropertyInjectTaggedDecorator=p;function $(X,se){return function(ae){return function(ce,le){var De=function(){return X.getAll(ae)};R(ce,le,De,se)}}}ye.makePropertyMultiInjectDecorator=$},11922:function(Ye,ye,A){"use strict";var R;R={value:!0};var V=A(3039);function y(p,$){$===void 0&&($=!0);var X=V.makePropertyInjectDecorator(p,$),se=V.makePropertyInjectNamedDecorator(p,$),ae=V.makePropertyInjectTaggedDecorator(p,$),ce=V.makePropertyMultiInjectDecorator(p,$);return{lazyInject:X,lazyInjectNamed:se,lazyInjectTagged:ae,lazyMultiInject:ce}}ye.Z=y},80626:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.tagProperty=ye.tagParameter=ye.decorate=void 0;var R=A(36078),V=A(50295);function y(ce,le,De,we){var Ee=V.TAGGED;$(Ee,ce,le,we,De)}ye.tagParameter=y;function p(ce,le,De){var we=V.TAGGED_PROP;$(we,ce.constructor,le,De)}ye.tagProperty=p;function $(ce,le,De,we,Ee){var qe={},Ge=typeof Ee=="number",ct=Ee!==void 0&&Ge?Ee.toString():De;if(Ge&&De!==void 0)throw new Error(R.INVALID_DECORATOR_OPERATION);Reflect.hasOwnMetadata(ce,le)&&(qe=Reflect.getMetadata(ce,le));var Ve=qe[ct];if(!Array.isArray(Ve))Ve=[];else for(var ut=0,Xe=Ve;ut= than the number of constructor arguments of its base class.")};ye.ARGUMENTS_LENGTH_MISMATCH=R,ye.CONTAINER_OPTIONS_MUST_BE_AN_OBJECT="Invalid Container constructor argument. Container options must be an object.",ye.CONTAINER_OPTIONS_INVALID_DEFAULT_SCOPE="Invalid Container option. Default scope must be a string ('singleton' or 'transient').",ye.CONTAINER_OPTIONS_INVALID_AUTO_BIND_INJECTABLE="Invalid Container option. Auto bind injectable must be a boolean",ye.CONTAINER_OPTIONS_INVALID_SKIP_BASE_CHECK="Invalid Container option. Skip base check must be a boolean",ye.MULTIPLE_POST_CONSTRUCT_METHODS="Cannot apply @postConstruct decorator multiple times in the same class";var V=function(){for(var p=[],$=0;$0&&Ct[Ct.length-1])&&(et[0]===6||et[0]===2)){Xe=0;continue}if(et[0]===3&&(!Ct||et[1]>Ct[0]&&et[1]0?$._map.set(se,ae):$._map.delete(se)})},y.prototype.hasKey=function(p){if(p==null)throw new Error(R.NULL_ARGUMENT);return this._map.has(p)},y.prototype.clone=function(){var p=new y;return this._map.forEach(function($,X){$.forEach(function(se){return p.add(X,se.clone())})}),p},y.prototype.traverse=function(p){this._map.forEach(function($,X){p(X,$)})},y}();ye.Lookup=V},99311:function(Ye,ye,A){"use strict";var R;R={value:!0},R=R=R=R=R=R=ye.GW=R=R=ye.zY=R=R=R=R=R=ye.f3=R=R=ye.b2=R=R=R=R=R=ye.W2=R=void 0;var V=A(50295);R=V;var y=A(70596);Object.defineProperty(ye,"W2",{enumerable:!0,get:function(){return y.Container}});var p=A(77690);R={enumerable:!0,get:function(){return p.BindingScopeEnum}},R={enumerable:!0,get:function(){return p.BindingTypeEnum}},R={enumerable:!0,get:function(){return p.TargetTypeEnum}};var $=A(42913);R={enumerable:!0,get:function(){return $.AsyncContainerModule}},R={enumerable:!0,get:function(){return $.ContainerModule}};var X=A(91773);Object.defineProperty(ye,"b2",{enumerable:!0,get:function(){return X.injectable}});var se=A(79189);R={enumerable:!0,get:function(){return se.tagged}};var ae=A(79817);R={enumerable:!0,get:function(){return ae.named}};var ce=A(76213);Object.defineProperty(ye,"f3",{enumerable:!0,get:function(){return ce.inject}}),R={enumerable:!0,get:function(){return ce.LazyServiceIdentifer}};var le=A(71316);R={enumerable:!0,get:function(){return le.optional}};var De=A(19235);R={enumerable:!0,get:function(){return De.unmanaged}};var we=A(41528);R={enumerable:!0,get:function(){return we.multiInject}};var Ee=A(8245);R={enumerable:!0,get:function(){return Ee.targetName}};var qe=A(71971);Object.defineProperty(ye,"zY",{enumerable:!0,get:function(){return qe.postConstruct}});var Ge=A(43870);R={enumerable:!0,get:function(){return Ge.MetadataReader}};var ct=A(70023);R={enumerable:!0,get:function(){return ct.id}};var Ve=A(80626);Object.defineProperty(ye,"GW",{enumerable:!0,get:function(){return Ve.decorate}});var ut=A(83140);R={enumerable:!0,get:function(){return ut.traverseAncerstors}},R={enumerable:!0,get:function(){return ut.taggedConstraint}},R={enumerable:!0,get:function(){return ut.namedConstraint}},R={enumerable:!0,get:function(){return ut.typeConstraint}};var Xe=A(29552);R={enumerable:!0,get:function(){return Xe.getServiceIdentifierAsString}};var Rt=A(34384);R={enumerable:!0,get:function(){return Rt.multiBindToService}}},91519:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.Context=void 0;var R=A(70023),V=function(){function y(p){this.id=R.id(),this.container=p}return y.prototype.addPlan=function(p){this.plan=p},y.prototype.setCurrentRequest=function(p){this.currentRequest=p},y}();ye.Context=V},25092:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.Metadata=void 0;var R=A(50295),V=function(){function y(p,$){this.key=p,this.value=$}return y.prototype.toString=function(){return this.key===R.NAMED_TAG?"named: "+this.value.toString()+" ":"tagged: { key:"+this.key.toString()+", value: "+this.value+" }"},y}();ye.Metadata=V},43870:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.MetadataReader=void 0;var R=A(50295),V=function(){function y(){}return y.prototype.getConstructorMetadata=function(p){var $=Reflect.getMetadata(R.PARAM_TYPES,p),X=Reflect.getMetadata(R.TAGGED,p);return{compilerGeneratedMetadata:$,userGeneratedMetadata:X||{}}},y.prototype.getPropertiesMetadata=function(p){var $=Reflect.getMetadata(R.TAGGED_PROP,p)||[];return $},y}();ye.MetadataReader=V},6335:function(Ye,ye){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.Plan=void 0;var A=function(){function R(V,y){this.parentContext=V,this.rootRequest=y}return R}();ye.Plan=A},54142:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.getBindingDictionary=ye.createMockRequest=ye.plan=void 0;var R=A(13497),V=A(36078),y=A(77690),p=A(50295),$=A(92542),X=A(29552),se=A(91519),ae=A(25092),ce=A(6335),le=A(16664),De=A(14810),we=A(69660);function Ee(gt){return gt._bindingDictionary}ye.getBindingDictionary=Ee;function qe(gt,Ct,tt,Ne,bt,et){var pt=gt?p.MULTI_INJECT_TAG:p.INJECT_TAG,Ke=new ae.Metadata(pt,tt),ft=new we.Target(Ct,Ne,tt,Ke);if(bt!==void 0){var wt=new ae.Metadata(bt,et);ft.metadata.push(wt)}return ft}function Ge(gt,Ct,tt,Ne,bt){var et=ut(tt.container,bt.serviceIdentifier),pt=[];return et.length===R.BindingCount.NoBindingsAvailable&&tt.container.options.autoBindInjectable&&typeof bt.serviceIdentifier=="function"&>.getConstructorMetadata(bt.serviceIdentifier).compilerGeneratedMetadata&&(tt.container.bind(bt.serviceIdentifier).toSelf(),et=ut(tt.container,bt.serviceIdentifier)),Ct?pt=et:pt=et.filter(function(Ke){var ft=new De.Request(Ke.serviceIdentifier,tt,Ne,Ke,bt);return Ke.constraint(ft)}),ct(bt.serviceIdentifier,pt,bt,tt.container),pt}function ct(gt,Ct,tt,Ne){switch(Ct.length){case R.BindingCount.NoBindingsAvailable:if(tt.isOptional())return Ct;var bt=X.getServiceIdentifierAsString(gt),et=V.NOT_REGISTERED;throw et+=X.listMetadataForTarget(bt,tt),et+=X.listRegisteredBindingsForServiceIdentifier(Ne,bt,ut),new Error(et);case R.BindingCount.OnlyOneBindingAvailable:if(!tt.isArray())return Ct;case R.BindingCount.MultipleBindingsAvailable:default:if(tt.isArray())return Ct;var bt=X.getServiceIdentifierAsString(gt),et=V.AMBIGUOUS_MATCH+" "+bt;throw et+=X.listRegisteredBindingsForServiceIdentifier(Ne,bt,ut),new Error(et)}}function Ve(gt,Ct,tt,Ne,bt,et){var pt,Ke;if(bt===null){pt=Ge(gt,Ct,Ne,null,et),Ke=new De.Request(tt,Ne,null,pt,et);var ft=new ce.Plan(Ne,Ke);Ne.addPlan(ft)}else pt=Ge(gt,Ct,Ne,bt,et),Ke=bt.addChildRequest(et.serviceIdentifier,pt,et);pt.forEach(function(wt){var Se=null;if(et.isArray())Se=Ke.addChildRequest(wt.serviceIdentifier,wt,et);else{if(wt.cache)return;Se=Ke}if(wt.type===y.BindingTypeEnum.Instance&&wt.implementationType!==null){var Ft=le.getDependencies(gt,wt.implementationType);if(!Ne.container.options.skipBaseClassChecks){var mt=le.getBaseClassDependencyCount(gt,wt.implementationType);if(Ft.length0,bt=tt.length>Ve.length,et=Ne||bt?tt.length:Ve.length,pt=De(ut,ct,Rt,Ct,et),Ke=we(Ge,Ve),ft=R(R([],pt),Ke);return ft}function le(Ge,ct,Ve,ut,Xe){var Rt=Xe[Ge.toString()]||[],gt=qe(Rt),Ct=gt.unmanaged!==!0,tt=ut[Ge],Ne=gt.inject||gt.multiInject;if(tt=Ne||tt,tt instanceof V.LazyServiceIdentifer&&(tt=tt.unwrap()),Ct){var bt=tt===Object,et=tt===Function,pt=tt===void 0,Ke=bt||et||pt;if(!ct&&Ke){var ft=y.MISSING_INJECT_ANNOTATION+" argument "+Ge+" in class "+Ve+".";throw new Error(ft)}var wt=new se.Target(p.TargetTypeEnum.ConstructorArgument,gt.targetName,tt);return wt.metadata=Rt,wt}return null}function De(Ge,ct,Ve,ut,Xe){for(var Rt=[],gt=0;gt0?Ct:Ee(Ge,Ve)}else return 0}ye.getBaseClassDependencyCount=Ee;function qe(Ge){var ct={};return Ge.forEach(function(Ve){ct[Ve.key.toString()]=Ve.value}),{inject:ct[$.INJECT_TAG],multiInject:ct[$.MULTI_INJECT_TAG],targetName:ct[$.NAME_TAG],unmanaged:ct[$.UNMANAGED_TAG]}}},14810:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.Request=void 0;var R=A(70023),V=function(){function y(p,$,X,se,ae){this.id=R.id(),this.serviceIdentifier=p,this.parentContext=$,this.parentRequest=X,this.target=ae,this.childRequests=[],this.bindings=Array.isArray(se)?se:[se],this.requestScope=X===null?new Map:null}return y.prototype.addChildRequest=function(p,$,X){var se=new y(p,this.parentContext,this,$,X);return this.childRequests.push(se),se},y}();ye.Request=V},69660:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.Target=void 0;var R=A(50295),V=A(70023),y=A(25092),p=A(68634),$=function(){function X(se,ae,ce,le){this.id=V.id(),this.type=se,this.serviceIdentifier=ce,this.name=new p.QueryableString(ae||""),this.metadata=new Array;var De=null;typeof le=="string"?De=new y.Metadata(R.NAMED_TAG,le):le instanceof y.Metadata&&(De=le),De!==null&&this.metadata.push(De)}return X.prototype.hasTag=function(se){for(var ae=0,ce=this.metadata;ae0){var Ee=le.filter(function(Ge){return Ge.target!==null&&Ge.target.type===y.TargetTypeEnum.ConstructorArgument}),qe=Ee.map(De);we=X(ce,qe),we=$(we,le,De)}else we=new ce;return se(ce,we),we}ye.resolveInstance=ae},9386:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.resolve=void 0;var R=A(36078),V=A(77690),y=A(92542),p=A(29552),$=A(74962),X=function(ce,le,De){try{return De()}catch(we){throw y.isStackOverflowExeption(we)?new Error(R.CIRCULAR_DEPENDENCY_IN_FACTORY(ce,le.toString())):we}},se=function(ce){return function(le){le.parentContext.setCurrentRequest(le);var De=le.bindings,we=le.childRequests,Ee=le.target&&le.target.isArray(),qe=!le.parentRequest||!le.parentRequest.target||!le.target||!le.parentRequest.target.matchesArray(le.target.serviceIdentifier);if(Ee&&qe)return we.map(function(Rt){var gt=se(ce);return gt(Rt)});var Ge=null;if(le.target.isOptional()&&De.length===0)return;var ct=De[0],Ve=ct.scope===V.BindingScopeEnum.Singleton,ut=ct.scope===V.BindingScopeEnum.Request;if(Ve&&ct.activated)return ct.cache;if(ut&&ce!==null&&ce.has(ct.id))return ce.get(ct.id);if(ct.type===V.BindingTypeEnum.ConstantValue)Ge=ct.cache,ct.activated=!0;else if(ct.type===V.BindingTypeEnum.Function)Ge=ct.cache,ct.activated=!0;else if(ct.type===V.BindingTypeEnum.Constructor)Ge=ct.implementationType;else if(ct.type===V.BindingTypeEnum.DynamicValue&&ct.dynamicValue!==null)Ge=X("toDynamicValue",ct.serviceIdentifier,function(){return ct.dynamicValue(le.parentContext)});else if(ct.type===V.BindingTypeEnum.Factory&&ct.factory!==null)Ge=X("toFactory",ct.serviceIdentifier,function(){return ct.factory(le.parentContext)});else if(ct.type===V.BindingTypeEnum.Provider&&ct.provider!==null)Ge=X("toProvider",ct.serviceIdentifier,function(){return ct.provider(le.parentContext)});else if(ct.type===V.BindingTypeEnum.Instance&&ct.implementationType!==null)Ge=$.resolveInstance(ct.implementationType,we,se(ce));else{var Xe=p.getServiceIdentifierAsString(le.serviceIdentifier);throw new Error(R.INVALID_BINDING_TYPE+" "+Xe)}return typeof ct.onActivation=="function"&&(Ge=ct.onActivation(le.parentContext,Ge)),Ve&&(ct.cache=Ge,ct.activated=!0),ut&&ce!==null&&!ce.has(ct.id)&&ce.set(ct.id,Ge),Ge}};function ae(ce){var le=se(ce.plan.rootRequest.requestScope);return le(ce.plan.rootRequest)}ye.resolve=ae},91640:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.BindingInSyntax=void 0;var R=A(77690),V=A(46890),y=function(){function p($){this._binding=$}return p.prototype.inRequestScope=function(){return this._binding.scope=R.BindingScopeEnum.Request,new V.BindingWhenOnSyntax(this._binding)},p.prototype.inSingletonScope=function(){return this._binding.scope=R.BindingScopeEnum.Singleton,new V.BindingWhenOnSyntax(this._binding)},p.prototype.inTransientScope=function(){return this._binding.scope=R.BindingScopeEnum.Transient,new V.BindingWhenOnSyntax(this._binding)},p}();ye.BindingInSyntax=y},82386:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.BindingInWhenOnSyntax=void 0;var R=A(91640),V=A(8926),y=A(36890),p=function(){function $(X){this._binding=X,this._bindingWhenSyntax=new y.BindingWhenSyntax(this._binding),this._bindingOnSyntax=new V.BindingOnSyntax(this._binding),this._bindingInSyntax=new R.BindingInSyntax(X)}return $.prototype.inRequestScope=function(){return this._bindingInSyntax.inRequestScope()},$.prototype.inSingletonScope=function(){return this._bindingInSyntax.inSingletonScope()},$.prototype.inTransientScope=function(){return this._bindingInSyntax.inTransientScope()},$.prototype.when=function(X){return this._bindingWhenSyntax.when(X)},$.prototype.whenTargetNamed=function(X){return this._bindingWhenSyntax.whenTargetNamed(X)},$.prototype.whenTargetIsDefault=function(){return this._bindingWhenSyntax.whenTargetIsDefault()},$.prototype.whenTargetTagged=function(X,se){return this._bindingWhenSyntax.whenTargetTagged(X,se)},$.prototype.whenInjectedInto=function(X){return this._bindingWhenSyntax.whenInjectedInto(X)},$.prototype.whenParentNamed=function(X){return this._bindingWhenSyntax.whenParentNamed(X)},$.prototype.whenParentTagged=function(X,se){return this._bindingWhenSyntax.whenParentTagged(X,se)},$.prototype.whenAnyAncestorIs=function(X){return this._bindingWhenSyntax.whenAnyAncestorIs(X)},$.prototype.whenNoAncestorIs=function(X){return this._bindingWhenSyntax.whenNoAncestorIs(X)},$.prototype.whenAnyAncestorNamed=function(X){return this._bindingWhenSyntax.whenAnyAncestorNamed(X)},$.prototype.whenAnyAncestorTagged=function(X,se){return this._bindingWhenSyntax.whenAnyAncestorTagged(X,se)},$.prototype.whenNoAncestorNamed=function(X){return this._bindingWhenSyntax.whenNoAncestorNamed(X)},$.prototype.whenNoAncestorTagged=function(X,se){return this._bindingWhenSyntax.whenNoAncestorTagged(X,se)},$.prototype.whenAnyAncestorMatches=function(X){return this._bindingWhenSyntax.whenAnyAncestorMatches(X)},$.prototype.whenNoAncestorMatches=function(X){return this._bindingWhenSyntax.whenNoAncestorMatches(X)},$.prototype.onActivation=function(X){return this._bindingOnSyntax.onActivation(X)},$}();ye.BindingInWhenOnSyntax=p},8926:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.BindingOnSyntax=void 0;var R=A(36890),V=function(){function y(p){this._binding=p}return y.prototype.onActivation=function(p){return this._binding.onActivation=p,new R.BindingWhenSyntax(this._binding)},y}();ye.BindingOnSyntax=V},43313:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.BindingToSyntax=void 0;var R=A(36078),V=A(77690),y=A(82386),p=A(46890),$=function(){function X(se){this._binding=se}return X.prototype.to=function(se){return this._binding.type=V.BindingTypeEnum.Instance,this._binding.implementationType=se,new y.BindingInWhenOnSyntax(this._binding)},X.prototype.toSelf=function(){if(typeof this._binding.serviceIdentifier!="function")throw new Error(""+R.INVALID_TO_SELF_VALUE);var se=this._binding.serviceIdentifier;return this.to(se)},X.prototype.toConstantValue=function(se){return this._binding.type=V.BindingTypeEnum.ConstantValue,this._binding.cache=se,this._binding.dynamicValue=null,this._binding.implementationType=null,this._binding.scope=V.BindingScopeEnum.Singleton,new p.BindingWhenOnSyntax(this._binding)},X.prototype.toDynamicValue=function(se){return this._binding.type=V.BindingTypeEnum.DynamicValue,this._binding.cache=null,this._binding.dynamicValue=se,this._binding.implementationType=null,new y.BindingInWhenOnSyntax(this._binding)},X.prototype.toConstructor=function(se){return this._binding.type=V.BindingTypeEnum.Constructor,this._binding.implementationType=se,this._binding.scope=V.BindingScopeEnum.Singleton,new p.BindingWhenOnSyntax(this._binding)},X.prototype.toFactory=function(se){return this._binding.type=V.BindingTypeEnum.Factory,this._binding.factory=se,this._binding.scope=V.BindingScopeEnum.Singleton,new p.BindingWhenOnSyntax(this._binding)},X.prototype.toFunction=function(se){if(typeof se!="function")throw new Error(R.INVALID_FUNCTION_BINDING);var ae=this.toConstantValue(se);return this._binding.type=V.BindingTypeEnum.Function,this._binding.scope=V.BindingScopeEnum.Singleton,ae},X.prototype.toAutoFactory=function(se){return this._binding.type=V.BindingTypeEnum.Factory,this._binding.factory=function(ae){var ce=function(){return ae.container.get(se)};return ce},this._binding.scope=V.BindingScopeEnum.Singleton,new p.BindingWhenOnSyntax(this._binding)},X.prototype.toProvider=function(se){return this._binding.type=V.BindingTypeEnum.Provider,this._binding.provider=se,this._binding.scope=V.BindingScopeEnum.Singleton,new p.BindingWhenOnSyntax(this._binding)},X.prototype.toService=function(se){this.toDynamicValue(function(ae){return ae.container.get(se)})},X}();ye.BindingToSyntax=$},46890:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.BindingWhenOnSyntax=void 0;var R=A(8926),V=A(36890),y=function(){function p($){this._binding=$,this._bindingWhenSyntax=new V.BindingWhenSyntax(this._binding),this._bindingOnSyntax=new R.BindingOnSyntax(this._binding)}return p.prototype.when=function($){return this._bindingWhenSyntax.when($)},p.prototype.whenTargetNamed=function($){return this._bindingWhenSyntax.whenTargetNamed($)},p.prototype.whenTargetIsDefault=function(){return this._bindingWhenSyntax.whenTargetIsDefault()},p.prototype.whenTargetTagged=function($,X){return this._bindingWhenSyntax.whenTargetTagged($,X)},p.prototype.whenInjectedInto=function($){return this._bindingWhenSyntax.whenInjectedInto($)},p.prototype.whenParentNamed=function($){return this._bindingWhenSyntax.whenParentNamed($)},p.prototype.whenParentTagged=function($,X){return this._bindingWhenSyntax.whenParentTagged($,X)},p.prototype.whenAnyAncestorIs=function($){return this._bindingWhenSyntax.whenAnyAncestorIs($)},p.prototype.whenNoAncestorIs=function($){return this._bindingWhenSyntax.whenNoAncestorIs($)},p.prototype.whenAnyAncestorNamed=function($){return this._bindingWhenSyntax.whenAnyAncestorNamed($)},p.prototype.whenAnyAncestorTagged=function($,X){return this._bindingWhenSyntax.whenAnyAncestorTagged($,X)},p.prototype.whenNoAncestorNamed=function($){return this._bindingWhenSyntax.whenNoAncestorNamed($)},p.prototype.whenNoAncestorTagged=function($,X){return this._bindingWhenSyntax.whenNoAncestorTagged($,X)},p.prototype.whenAnyAncestorMatches=function($){return this._bindingWhenSyntax.whenAnyAncestorMatches($)},p.prototype.whenNoAncestorMatches=function($){return this._bindingWhenSyntax.whenNoAncestorMatches($)},p.prototype.onActivation=function($){return this._bindingOnSyntax.onActivation($)},p}();ye.BindingWhenOnSyntax=y},36890:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.BindingWhenSyntax=void 0;var R=A(8926),V=A(83140),y=function(){function p($){this._binding=$}return p.prototype.when=function($){return this._binding.constraint=$,new R.BindingOnSyntax(this._binding)},p.prototype.whenTargetNamed=function($){return this._binding.constraint=V.namedConstraint($),new R.BindingOnSyntax(this._binding)},p.prototype.whenTargetIsDefault=function(){return this._binding.constraint=function($){var X=$.target!==null&&!$.target.isNamed()&&!$.target.isTagged();return X},new R.BindingOnSyntax(this._binding)},p.prototype.whenTargetTagged=function($,X){return this._binding.constraint=V.taggedConstraint($)(X),new R.BindingOnSyntax(this._binding)},p.prototype.whenInjectedInto=function($){return this._binding.constraint=function(X){return V.typeConstraint($)(X.parentRequest)},new R.BindingOnSyntax(this._binding)},p.prototype.whenParentNamed=function($){return this._binding.constraint=function(X){return V.namedConstraint($)(X.parentRequest)},new R.BindingOnSyntax(this._binding)},p.prototype.whenParentTagged=function($,X){return this._binding.constraint=function(se){return V.taggedConstraint($)(X)(se.parentRequest)},new R.BindingOnSyntax(this._binding)},p.prototype.whenAnyAncestorIs=function($){return this._binding.constraint=function(X){return V.traverseAncerstors(X,V.typeConstraint($))},new R.BindingOnSyntax(this._binding)},p.prototype.whenNoAncestorIs=function($){return this._binding.constraint=function(X){return!V.traverseAncerstors(X,V.typeConstraint($))},new R.BindingOnSyntax(this._binding)},p.prototype.whenAnyAncestorNamed=function($){return this._binding.constraint=function(X){return V.traverseAncerstors(X,V.namedConstraint($))},new R.BindingOnSyntax(this._binding)},p.prototype.whenNoAncestorNamed=function($){return this._binding.constraint=function(X){return!V.traverseAncerstors(X,V.namedConstraint($))},new R.BindingOnSyntax(this._binding)},p.prototype.whenAnyAncestorTagged=function($,X){return this._binding.constraint=function(se){return V.traverseAncerstors(se,V.taggedConstraint($)(X))},new R.BindingOnSyntax(this._binding)},p.prototype.whenNoAncestorTagged=function($,X){return this._binding.constraint=function(se){return!V.traverseAncerstors(se,V.taggedConstraint($)(X))},new R.BindingOnSyntax(this._binding)},p.prototype.whenAnyAncestorMatches=function($){return this._binding.constraint=function(X){return V.traverseAncerstors(X,$)},new R.BindingOnSyntax(this._binding)},p.prototype.whenNoAncestorMatches=function($){return this._binding.constraint=function(X){return!V.traverseAncerstors(X,$)},new R.BindingOnSyntax(this._binding)},p}();ye.BindingWhenSyntax=y},83140:function(Ye,ye,A){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.typeConstraint=ye.namedConstraint=ye.taggedConstraint=ye.traverseAncerstors=void 0;var R=A(50295),V=A(25092),y=function(se,ae){var ce=se.parentRequest;return ce!==null?ae(ce)?!0:y(ce,ae):!1};ye.traverseAncerstors=y;var p=function(se){return function(ae){var ce=function(le){return le!==null&&le.target!==null&&le.target.matchesTag(se)(ae)};return ce.metaData=new V.Metadata(se,ae),ce}};ye.taggedConstraint=p;var $=p(R.NAMED_TAG);ye.namedConstraint=$;var X=function(se){return function(ae){var ce=null;if(ae!==null)if(ce=ae.bindings[0],typeof se=="string"){var le=ce.serviceIdentifier;return le===se}else{var De=ae.bindings[0].implementationType;return se===De}return!1}};ye.typeConstraint=X},34384:function(Ye,ye){"use strict";Object.defineProperty(ye,"__esModule",{value:!0}),ye.multiBindToService=void 0;var A=function(R){return function(V){return function(){for(var y=[],p=0;p ")}function X(ce){ce.childRequests.forEach(function(le){if(p(le,le.serviceIdentifier)){var De=$(le);throw new Error(R.CIRCULAR_DEPENDENCY+" "+De)}else X(le)})}ye.circularDependencyToException=X;function se(ce,le){if(le.isTagged()||le.isNamed()){var De="",we=le.getNamedTag(),Ee=le.getCustomTags();return we!==null&&(De+=we.toString()+` +`),Ee!==null&&Ee.forEach(function(qe){De+=qe.toString()+` +`})," "+ce+` + `+ce+" - "+De}else return" "+ce}ye.listMetadataForTarget=se;function ae(ce){if(ce.name)return ce.name;var le=ce.toString(),De=le.match(/^function\s*([^\s(]+)/);return De?De[1]:"Anonymous function: "+le}ye.getFunctionName=ae},76051:function(Ye,ye,A){"use strict";var R=A(80758)(),V=A(97683),y=V("Object.prototype.toString"),p=function(ae){return R&&ae&&typeof ae=="object"&&Symbol.toStringTag in ae?!1:y(ae)==="[object Arguments]"},$=function(ae){return p(ae)?!0:ae!==null&&typeof ae=="object"&&typeof ae.length=="number"&&ae.length>=0&&y(ae)!=="[object Array]"&&y(ae.callee)==="[object Function]"},X=function(){return p(arguments)}();p.isLegacyArguments=$,Ye.exports=X?p:$},22948:function(Ye){Ye.exports=function(A){return!A||typeof A=="string"?!1:A instanceof Array||Array.isArray(A)||A.length>=0&&(A.splice instanceof Function||Object.getOwnPropertyDescriptor(A,A.length-1)&&A.constructor.name!=="String")}},78034:function(Ye){Ye.exports=function(R){return R!=null&&(ye(R)||A(R)||!!R._isBuffer)};function ye(R){return!!R.constructor&&typeof R.constructor.isBuffer=="function"&&R.constructor.isBuffer(R)}function A(R){return typeof R.readFloatLE=="function"&&typeof R.slice=="function"&&ye(R.slice(0,0))}},5012:function(Ye,ye,A){"use strict";var R=Date.prototype.getDay,V=function(se){try{return R.call(se),!0}catch(ae){return!1}},y=Object.prototype.toString,p="[object Date]",$=A(80758)();Ye.exports=function(se){return typeof se!="object"||se===null?!1:$?V(se):y.call(se)===p}},11644:function(Ye,ye,A){"use strict";var R=A(97683),V=A(80758)(),y,p,$,X;if(V){y=R("Object.prototype.hasOwnProperty"),p=R("RegExp.prototype.exec"),$={};var se=function(){throw $};X={toString:se,valueOf:se},typeof Symbol.toPrimitive=="symbol"&&(X[Symbol.toPrimitive]=se)}var ae=R("Object.prototype.toString"),ce=Object.getOwnPropertyDescriptor,le="[object RegExp]";Ye.exports=V?function(we){if(!we||typeof we!="object")return!1;var Ee=ce(we,"lastIndex"),qe=Ee&&y(Ee,"value");if(!qe)return!1;try{p(we,X)}catch(Ge){return Ge===$}}:function(we){return!we||typeof we!="object"&&typeof we!="function"?!1:ae(we)===le}},15584:function(Ye,ye,A){var R=A(73893),V=A(33152),y=R(V,"DataView");Ye.exports=y},76414:function(Ye,ye,A){var R=A(64696),V=A(16824),y=A(23476),p=A(63122),$=A(37279);function X(se){var ae=-1,ce=se==null?0:se.length;for(this.clear();++ae-1}Ye.exports=V},94874:function(Ye){function ye(A,R,V){for(var y=-1,p=A==null?0:A.length;++y=R?A:R)),A}Ye.exports=ye},99045:function(Ye,ye,A){var R=A(91866),V=A(74809),y=A(60348),p=A(91937),$=A(26680),X=A(32315),se=A(47760),ae=A(15168),ce=A(71678),le=A(12076),De=A(22675),we=A(66139),Ee=A(79264),qe=A(97541),Ge=A(4084),ct=A(80744),Ve=A(57835),ut=A(41626),Xe=A(20816),Rt=A(65226),gt=A(55451),Ct=A(56730),tt=1,Ne=2,bt=4,et="[object Arguments]",pt="[object Array]",Ke="[object Boolean]",ft="[object Date]",wt="[object Error]",Se="[object Function]",Ft="[object GeneratorFunction]",mt="[object Map]",ot="[object Number]",We="[object Object]",Me="[object RegExp]",st="[object Set]",Qe="[object String]",dr="[object Symbol]",Kt="[object WeakMap]",Yr="[object ArrayBuffer]",hn="[object DataView]",ln="[object Float32Array]",oi="[object Float64Array]",Nn="[object Int8Array]",$n="[object Int16Array]",_i="[object Int32Array]",Qn="[object Uint8Array]",Ji="[object Uint8ClampedArray]",ni="[object Uint16Array]",Ei="[object Uint32Array]",xo={};xo[et]=xo[pt]=xo[Yr]=xo[hn]=xo[Ke]=xo[ft]=xo[ln]=xo[oi]=xo[Nn]=xo[$n]=xo[_i]=xo[mt]=xo[ot]=xo[We]=xo[Me]=xo[st]=xo[Qe]=xo[dr]=xo[Qn]=xo[Ji]=xo[ni]=xo[Ei]=!0,xo[wt]=xo[Se]=xo[Kt]=!1;function sn(li,En,or,qi,Bo,Mo){var Wi,Ii=En&tt,ko=En&Ne,Fn=En&bt;if(or&&(Wi=Bo?or(li,qi,Bo,Mo):or(li)),Wi!==void 0)return Wi;if(!Xe(li))return li;var zn=ct(li);if(zn){if(Wi=Ee(li),!Ii)return se(li,Wi)}else{var Un=we(li),Hi=Un==Se||Un==Ft;if(Ve(li))return X(li,Ii);if(Un==We||Un==et||Hi&&!Bo){if(Wi=ko||Hi?{}:Ge(li),!Ii)return ko?ce(li,$(Wi,li)):ae(li,p(Wi,li))}else{if(!xo[Un])return Bo?li:{};Wi=qe(li,Un,Ii)}}Mo||(Mo=new R);var Ki=Mo.get(li);if(Ki)return Ki;Mo.set(li,Wi),Rt(li)?li.forEach(function(it){Wi.add(sn(it,En,or,it,li,Mo))}):ut(li)&&li.forEach(function(it,kt){Wi.set(kt,sn(it,En,or,kt,li,Mo))});var Fo=Fn?ko?De:le:ko?Ct:gt,xt=zn?void 0:Fo(li);return V(xt||li,function(it,kt){xt&&(kt=it,it=li[kt]),y(Wi,kt,sn(it,En,or,kt,li,Mo))}),Wi}Ye.exports=sn},35024:function(Ye,ye,A){var R=A(20816),V=Object.create,y=function(){function p(){}return function($){if(!R($))return{};if(V)return V($);p.prototype=$;var X=new p;return p.prototype=void 0,X}}();Ye.exports=y},51533:function(Ye){function ye(A,R,V,y){for(var p=A.length,$=V+(y?1:-1);y?$--:++$-1;)ct!==ce&&se.call(ct,Ve,1),se.call(ce,Ve,1);return ce}Ye.exports=ae},92918:function(Ye,ye,A){var R=A(46962),V=A(19652),y=A(71152);function p($,X){return y(V($,X,R),$+"")}Ye.exports=p},63989:function(Ye,ye,A){var R=A(13503),V=A(35234),y=A(46962),p=V?function($,X){return V($,"toString",{configurable:!0,enumerable:!1,value:R(X),writable:!0})}:y;Ye.exports=p},75760:function(Ye){function ye(A,R,V){var y=-1,p=A.length;R<0&&(R=-R>p?0:p+R),V=V>p?p:V,V<0&&(V+=p),p=R>V?0:V-R>>>0,R>>>=0;for(var $=Array(p);++y=se){var ut=le?null:$(ce);if(ut)return X(ut);Ge=!1,Ee=p,Ve=new R}else Ve=le?[]:ct;e:for(;++we=X?y:R(y,p,$)}Ye.exports=V},20188:function(Ye,ye,A){var R=A(77945);function V(y){var p=new y.constructor(y.byteLength);return new R(p).set(new R(y)),p}Ye.exports=V},32315:function(Ye,ye,A){Ye=A.nmd(Ye);var R=A(33152),V=ye&&!ye.nodeType&&ye,y=V&&!0&&Ye&&!Ye.nodeType&&Ye,p=y&&y.exports===V,$=p?R.Buffer:void 0,X=$?$.allocUnsafe:void 0;function se(ae,ce){if(ce)return ae.slice();var le=ae.length,De=X?X(le):new ae.constructor(le);return ae.copy(De),De}Ye.exports=se},27984:function(Ye,ye,A){var R=A(20188);function V(y,p){var $=p?R(y.buffer):y.buffer;return new y.constructor($,y.byteOffset,y.byteLength)}Ye.exports=V},78583:function(Ye){var ye=/\w*$/;function A(R){var V=new R.constructor(R.source,ye.exec(R));return V.lastIndex=R.lastIndex,V}Ye.exports=A},28757:function(Ye,ye,A){var R=A(91869),V=R?R.prototype:void 0,y=V?V.valueOf:void 0;function p($){return y?Object(y.call($)):{}}Ye.exports=p},78358:function(Ye,ye,A){var R=A(20188);function V(y,p){var $=p?R(y.buffer):y.buffer;return new y.constructor($,y.byteOffset,y.length)}Ye.exports=V},47760:function(Ye){function ye(A,R){var V=-1,y=A.length;for(R||(R=Array(y));++V1?X[ae-1]:void 0,le=ae>2?X[2]:void 0;for(ce=p.length>3&&typeof ce=="function"?(ae--,ce):void 0,le&&V(X[0],X[1],le)&&(ce=ae<3?void 0:ce,ae=1),$=Object($);++seqe))return!1;var ct=we.get(se),Ve=we.get(ae);if(ct&&Ve)return ct==ae&&Ve==se;var ut=-1,Xe=!0,Rt=ce&$?new R:void 0;for(we.set(se,ae),we.set(ae,se);++ut-1&&V%1==0&&V-1}Ye.exports=V},54238:function(Ye,ye,A){var R=A(67971);function V(y,p){var $=this.__data__,X=R($,y);return X<0?(++this.size,$.push([y,p])):$[X][1]=p,this}Ye.exports=V},35365:function(Ye,ye,A){var R=A(76414),V=A(99746),y=A(40164);function p(){this.size=0,this.__data__={hash:new R,map:new(y||V),string:new R}}Ye.exports=p},63765:function(Ye,ye,A){var R=A(89819);function V(y){var p=R(this,y).delete(y);return this.size-=p?1:0,p}Ye.exports=V},12608:function(Ye,ye,A){var R=A(89819);function V(y){return R(this,y).get(y)}Ye.exports=V},10203:function(Ye,ye,A){var R=A(89819);function V(y){return R(this,y).has(y)}Ye.exports=V},11298:function(Ye,ye,A){var R=A(89819);function V(y,p){var $=R(this,y),X=$.size;return $.set(y,p),this.size+=$.size==X?0:1,this}Ye.exports=V},83383:function(Ye){function ye(A){var R=-1,V=Array(A.size);return A.forEach(function(y,p){V[++R]=[p,y]}),V}Ye.exports=ye},26332:function(Ye,ye,A){var R=A(52858),V=500;function y(p){var $=R(p,function(se){return X.size===V&&X.clear(),se}),X=$.cache;return $}Ye.exports=y},65294:function(Ye,ye,A){var R=A(73893),V=R(Object,"create");Ye.exports=V},23730:function(Ye,ye,A){var R=A(31030),V=R(Object.keys,Object);Ye.exports=V},97817:function(Ye){function ye(A){var R=[];if(A!=null)for(var V in Object(A))R.push(V);return R}Ye.exports=ye},52495:function(Ye,ye,A){Ye=A.nmd(Ye);var R=A(37675),V=ye&&!ye.nodeType&&ye,y=V&&!0&&Ye&&!Ye.nodeType&&Ye,p=y&&y.exports===V,$=p&&R.process,X=function(){try{var se=y&&y.require&&y.require("util").types;return se||$&&$.binding&&$.binding("util")}catch(ae){}}();Ye.exports=X},74702:function(Ye){var ye=Object.prototype,A=ye.toString;function R(V){return A.call(V)}Ye.exports=R},31030:function(Ye){function ye(A,R){return function(V){return A(R(V))}}Ye.exports=ye},19652:function(Ye,ye,A){var R=A(79628),V=Math.max;function y(p,$,X){return $=V($===void 0?p.length-1:$,0),function(){for(var se=arguments,ae=-1,ce=V(se.length-$,0),le=Array(ce);++ae0){if(++p>=ye)return arguments[0]}else p=0;return y.apply(void 0,arguments)}}Ye.exports=V},31119:function(Ye,ye,A){var R=A(99746);function V(){this.__data__=new R,this.size=0}Ye.exports=V},64399:function(Ye){function ye(A){var R=this.__data__,V=R.delete(A);return this.size=R.size,V}Ye.exports=ye},81897:function(Ye){function ye(A){return this.__data__.get(A)}Ye.exports=ye},90558:function(Ye){function ye(A){return this.__data__.has(A)}Ye.exports=ye},64841:function(Ye,ye,A){var R=A(99746),V=A(40164),y=A(52166),p=200;function $(X,se){var ae=this.__data__;if(ae instanceof R){var ce=ae.__data__;if(!V||ce.length=ce||Se<0||Xe&&Ft>=Ee}function bt(){var wt=V();if(Ne(wt))return et(wt);Ge=setTimeout(bt,tt(wt))}function et(wt){return Ge=void 0,Rt&&De?gt(wt):(De=we=void 0,qe)}function pt(){Ge!==void 0&&clearTimeout(Ge),Ve=0,De=ct=we=Ge=void 0}function Ke(){return Ge===void 0?qe:et(V())}function ft(){var wt=V(),Se=Ne(wt);if(De=arguments,we=this,ct=wt,Se){if(Ge===void 0)return Ct(ct);if(Xe)return clearTimeout(Ge),Ge=setTimeout(bt,ce),gt(ct)}return Ge===void 0&&(Ge=setTimeout(bt,ce)),qe}return ft.cancel=pt,ft.flush=Ke,ft}Ye.exports=se},31876:function(Ye,ye,A){var R=A(70668),V=A(44140),y=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,p="\\u0300-\\u036f",$="\\ufe20-\\ufe2f",X="\\u20d0-\\u20ff",se=p+$+X,ae="["+se+"]",ce=RegExp(ae,"g");function le(De){return De=V(De),De&&De.replace(y,R).replace(ce,"")}Ye.exports=le},43607:function(Ye){function ye(A,R){return A===R||A!==A&&R!==R}Ye.exports=ye},44231:function(Ye,ye,A){var R=A(89147);function V(y,p,$){var X=y==null?void 0:R(y,p);return X===void 0?$:X}Ye.exports=V},46962:function(Ye){function ye(A){return A}Ye.exports=ye},13053:function(Ye,ye,A){var R=A(4977),V=A(93913),y=Object.prototype,p=y.hasOwnProperty,$=y.propertyIsEnumerable,X=R(function(){return arguments}())?R:function(se){return V(se)&&p.call(se,"callee")&&!$.call(se,"callee")};Ye.exports=X},80744:function(Ye){var ye=Array.isArray;Ye.exports=ye},24665:function(Ye,ye,A){var R=A(9363),V=A(11156);function y(p){return p!=null&&V(p.length)&&!R(p)}Ye.exports=y},41590:function(Ye,ye,A){var R=A(24665),V=A(93913);function y(p){return V(p)&&R(p)}Ye.exports=y},26561:function(Ye,ye,A){var R=A(86756),V=A(93913),y="[object Boolean]";function p($){return $===!0||$===!1||V($)&&R($)==y}Ye.exports=p},57835:function(Ye,ye,A){Ye=A.nmd(Ye);var R=A(33152),V=A(55950),y=ye&&!ye.nodeType&&ye,p=y&&!0&&Ye&&!Ye.nodeType&&Ye,$=p&&p.exports===y,X=$?R.Buffer:void 0,se=X?X.isBuffer:void 0,ae=se||V;Ye.exports=ae},98621:function(Ye,ye,A){var R=A(77295);function V(y,p){return R(y,p)}Ye.exports=V},9363:function(Ye,ye,A){var R=A(86756),V=A(20816),y="[object AsyncFunction]",p="[object Function]",$="[object GeneratorFunction]",X="[object Proxy]";function se(ae){if(!V(ae))return!1;var ce=R(ae);return ce==p||ce==$||ce==y||ce==X}Ye.exports=se},11156:function(Ye){var ye=9007199254740991;function A(R){return typeof R=="number"&&R>-1&&R%1==0&&R<=ye}Ye.exports=A},41626:function(Ye,ye,A){var R=A(55005),V=A(38342),y=A(52495),p=y&&y.isMap,$=p?V(p):R;Ye.exports=$},93544:function(Ye){function ye(A){return A==null}Ye.exports=ye},68868:function(Ye,ye,A){var R=A(86756),V=A(93913),y="[object Number]";function p($){return typeof $=="number"||V($)&&R($)==y}Ye.exports=p},20816:function(Ye){function ye(A){var R=typeof A;return A!=null&&(R=="object"||R=="function")}Ye.exports=ye},93913:function(Ye){function ye(A){return A!=null&&typeof A=="object"}Ye.exports=ye},19308:function(Ye,ye,A){var R=A(86756),V=A(49217),y=A(93913),p="[object Object]",$=Function.prototype,X=Object.prototype,se=$.toString,ae=X.hasOwnProperty,ce=se.call(Object);function le(De){if(!y(De)||R(De)!=p)return!1;var we=V(De);if(we===null)return!0;var Ee=ae.call(we,"constructor")&&we.constructor;return typeof Ee=="function"&&Ee instanceof Ee&&se.call(Ee)==ce}Ye.exports=le},65226:function(Ye,ye,A){var R=A(38652),V=A(38342),y=A(52495),p=y&&y.isSet,$=p?V(p):R;Ye.exports=$},7941:function(Ye,ye,A){var R=A(86756),V=A(80744),y=A(93913),p="[object String]";function $(X){return typeof X=="string"||!V(X)&&y(X)&&R(X)==p}Ye.exports=$},45029:function(Ye,ye,A){var R=A(86756),V=A(93913),y="[object Symbol]";function p($){return typeof $=="symbol"||V($)&&R($)==y}Ye.exports=p},18397:function(Ye,ye,A){var R=A(10766),V=A(38342),y=A(52495),p=y&&y.isTypedArray,$=p?V(p):R;Ye.exports=$},16513:function(Ye){function ye(A){return A===void 0}Ye.exports=ye},55451:function(Ye,ye,A){var R=A(63333),V=A(6019),y=A(24665);function p($){return y($)?R($):V($)}Ye.exports=p},56730:function(Ye,ye,A){var R=A(63333),V=A(33988),y=A(24665);function p($){return y($)?R($,!0):V($)}Ye.exports=p},52858:function(Ye,ye,A){var R=A(52166),V="Expected a function";function y(p,$){if(typeof p!="function"||$!=null&&typeof $!="function")throw new TypeError(V);var X=function(){var se=arguments,ae=$?$.apply(this,se):se[0],ce=X.cache;if(ce.has(ae))return ce.get(ae);var le=p.apply(this,se);return X.cache=ce.set(ae,le)||ce,le};return X.cache=new(y.Cache||R),X}y.Cache=R,Ye.exports=y},28440:function(Ye,ye,A){var R=A(50097),V=A(63323),y=V(function(p,$,X){R(p,$,X)});Ye.exports=y},24602:function(Ye,ye,A){var R=A(50097),V=A(63323),y=V(function(p,$,X,se){R(p,$,X,se)});Ye.exports=y},9958:function(Ye){function ye(){}Ye.exports=ye},5795:function(Ye,ye,A){var R=A(33152),V=function(){return R.Date.now()};Ye.exports=V},63536:function(Ye,ye,A){var R=A(92918),V=A(14989),y=R(V);Ye.exports=y},14989:function(Ye,ye,A){var R=A(23442);function V(y,p){return y&&y.length&&p&&p.length?R(y,p):y}Ye.exports=V},4134:function(Ye){function ye(){return[]}Ye.exports=ye},55950:function(Ye){function ye(){return!1}Ye.exports=ye},46700:function(Ye,ye,A){var R=A(41571),V=A(20816),y="Expected a function";function p($,X,se){var ae=!0,ce=!0;if(typeof $!="function")throw new TypeError(y);return V(se)&&(ae="leading"in se?!!se.leading:ae,ce="trailing"in se?!!se.trailing:ce),R($,X,{leading:ae,maxWait:X,trailing:ce})}Ye.exports=p},20168:function(Ye,ye,A){var R=A(13927),V=A(20816),y=A(45029),p=0/0,$=/^[-+]0x[0-9a-f]+$/i,X=/^0b[01]+$/i,se=/^0o[0-7]+$/i,ae=parseInt;function ce(le){if(typeof le=="number")return le;if(y(le))return p;if(V(le)){var De=typeof le.valueOf=="function"?le.valueOf():le;le=V(De)?De+"":De}if(typeof le!="string")return le===0?le:+le;le=R(le);var we=X.test(le);return we||se.test(le)?ae(le.slice(2),we?2:8):$.test(le)?p:+le}Ye.exports=ce},20480:function(Ye,ye,A){var R=A(95378),V=A(56730);function y(p){return R(p,V(p))}Ye.exports=y},44140:function(Ye,ye,A){var R=A(50230);function V(y){return y==null?"":R(y)}Ye.exports=V},21691:function(Ye,ye,A){var R=A(29098);function V(y){return y&&y.length?R(y):[]}Ye.exports=V},53592:function(Ye,ye,A){var R=A(44412),V=R("toUpperCase");Ye.exports=V},61503:function(Ye,ye,A){var R=A(34130),V=A(62840),y=A(44140),p=A(97681);function $(X,se,ae){return X=y(X),se=ae?void 0:se,se===void 0?V(X)?p(X):R(X):X.match(se)||[]}Ye.exports=$},17369:function(Ye){(function(ye,A){Ye.exports=A()})(this,function(){"use strict";var ye,A,R;function V(y,p){if(!ye)ye=p;else if(!A)A=p;else{var $="var sharedChunk = {}; ("+ye+")(sharedChunk); ("+A+")(sharedChunk);",X={};ye(X),R=p(X),typeof window!="undefined"&&(R.workerUrl=window.URL.createObjectURL(new Blob([$],{type:"text/javascript"})))}}return V(["exports"],function(y){"use strict";function p(o,s){return o(s={exports:{}},s.exports),s.exports}var $=X;function X(o,s,l,g){this.cx=3*o,this.bx=3*(l-o)-this.cx,this.ax=1-this.cx-this.bx,this.cy=3*s,this.by=3*(g-s)-this.cy,this.ay=1-this.cy-this.by,this.p1x=o,this.p1y=g,this.p2x=l,this.p2y=g}X.prototype.sampleCurveX=function(o){return((this.ax*o+this.bx)*o+this.cx)*o},X.prototype.sampleCurveY=function(o){return((this.ay*o+this.by)*o+this.cy)*o},X.prototype.sampleCurveDerivativeX=function(o){return(3*this.ax*o+2*this.bx)*o+this.cx},X.prototype.solveCurveX=function(o,s){var l,g,M,j,J;for(s===void 0&&(s=1e-6),M=o,J=0;J<8;J++){if(j=this.sampleCurveX(M)-o,Math.abs(j)(g=1))return g;for(;lj?l=M:g=M,M=.5*(g-l)+l}return M},X.prototype.solve=function(o,s){return this.sampleCurveY(this.solveCurveX(o,s))};var se=ae;function ae(o,s){this.x=o,this.y=s}ae.prototype={clone:function(){return new ae(this.x,this.y)},add:function(o){return this.clone()._add(o)},sub:function(o){return this.clone()._sub(o)},multByPoint:function(o){return this.clone()._multByPoint(o)},divByPoint:function(o){return this.clone()._divByPoint(o)},mult:function(o){return this.clone()._mult(o)},div:function(o){return this.clone()._div(o)},rotate:function(o){return this.clone()._rotate(o)},rotateAround:function(o,s){return this.clone()._rotateAround(o,s)},matMult:function(o){return this.clone()._matMult(o)},unit:function(){return this.clone()._unit()},perp:function(){return this.clone()._perp()},round:function(){return this.clone()._round()},mag:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},equals:function(o){return this.x===o.x&&this.y===o.y},dist:function(o){return Math.sqrt(this.distSqr(o))},distSqr:function(o){var s=o.x-this.x,l=o.y-this.y;return s*s+l*l},angle:function(){return Math.atan2(this.y,this.x)},angleTo:function(o){return Math.atan2(this.y-o.y,this.x-o.x)},angleWith:function(o){return this.angleWithSep(o.x,o.y)},angleWithSep:function(o,s){return Math.atan2(this.x*s-this.y*o,this.x*o+this.y*s)},_matMult:function(o){var s=o[2]*this.x+o[3]*this.y;return this.x=o[0]*this.x+o[1]*this.y,this.y=s,this},_add:function(o){return this.x+=o.x,this.y+=o.y,this},_sub:function(o){return this.x-=o.x,this.y-=o.y,this},_mult:function(o){return this.x*=o,this.y*=o,this},_div:function(o){return this.x/=o,this.y/=o,this},_multByPoint:function(o){return this.x*=o.x,this.y*=o.y,this},_divByPoint:function(o){return this.x/=o.x,this.y/=o.y,this},_unit:function(){return this._div(this.mag()),this},_perp:function(){var o=this.y;return this.y=this.x,this.x=-o,this},_rotate:function(o){var s=Math.cos(o),l=Math.sin(o),g=l*this.x+s*this.y;return this.x=s*this.x-l*this.y,this.y=g,this},_rotateAround:function(o,s){var l=Math.cos(o),g=Math.sin(o),M=s.y+g*(this.x-s.x)+l*(this.y-s.y);return this.x=s.x+l*(this.x-s.x)-g*(this.y-s.y),this.y=M,this},_round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}},ae.convert=function(o){return o instanceof ae?o:Array.isArray(o)?new ae(o[0],o[1]):o};var ce=typeof self!="undefined"?self:{},le=Math.pow(2,53)-1;function De(o,s,l,g){var M=new $(o,s,l,g);return function(j){return M.solve(j)}}var we=De(.25,.1,.25,1);function Ee(o,s,l){return Math.min(l,Math.max(s,o))}function qe(o,s,l){var g=l-s,M=((o-s)%g+g)%g+s;return M===s?l:M}function Ge(o){for(var s=[],l=arguments.length-1;l-- >0;)s[l]=arguments[l+1];for(var g=0,M=s;g>s/4).toString(16):([1e7]+-[1e3]+-4e3+-8e3+-1e11).replace(/[018]/g,o)}()}function Xe(o){return!!o&&/^[0-9a-f]{8}-[0-9a-f]{4}-[4][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(o)}function Rt(o,s){o.forEach(function(l){s[l]&&(s[l]=s[l].bind(s))})}function gt(o,s){return o.indexOf(s,o.length-s.length)!==-1}function Ct(o,s,l){var g={};for(var M in o)g[M]=s.call(l||this,o[M],M,o);return g}function tt(o,s,l){var g={};for(var M in o)s.call(l||this,o[M],M,o)&&(g[M]=o[M]);return g}function Ne(o){return Array.isArray(o)?o.map(Ne):typeof o=="object"&&o?Ct(o,Ne):o}var bt={};function et(o){bt[o]||(typeof console!="undefined"&&console.warn(o),bt[o]=!0)}function pt(o,s,l){return(l.y-o.y)*(s.x-o.x)>(s.y-o.y)*(l.x-o.x)}function Ke(o){for(var s=0,l=0,g=o.length,M=g-1,j=void 0,J=void 0;l@\,;\:\\"\/\[\]\?\=\{\}\x7F]+)(?:\=(?:([^\x00-\x20\(\)<>@\,;\:\\"\/\[\]\?\=\{\}\x7F]+)|(?:\"((?:[^"\\]|\\.)*)\")))?/g,function(g,M,j,J){var ve=j||J;return s[M]=!ve||ve.toLowerCase(),""}),s["max-age"]){var l=parseInt(s["max-age"],10);isNaN(l)?delete s["max-age"]:s["max-age"]=l}return s}var Se=null;function Ft(o){if(Se==null){var s=o.navigator?o.navigator.userAgent:null;Se=!!o.safari||!(!s||!(/\b(iPad|iPhone|iPod)\b/.test(s)||s.match("Safari")&&!s.match("Chrome")))}return Se}function mt(o){try{var s=ce[o];return s.setItem("_mapbox_test_",1),s.removeItem("_mapbox_test_"),!0}catch(l){return!1}}var ot,We,Me,st,Qe=ce.performance&&ce.performance.now?ce.performance.now.bind(ce.performance):Date.now.bind(Date),dr=ce.requestAnimationFrame||ce.mozRequestAnimationFrame||ce.webkitRequestAnimationFrame||ce.msRequestAnimationFrame,Kt=ce.cancelAnimationFrame||ce.mozCancelAnimationFrame||ce.webkitCancelAnimationFrame||ce.msCancelAnimationFrame,Yr={now:Qe,frame:function(o){var s=dr(o);return{cancel:function(){return Kt(s)}}},getImageData:function(o,s){s===void 0&&(s=0);var l=ce.document.createElement("canvas"),g=l.getContext("2d");if(!g)throw new Error("failed to create canvas 2d context");return l.width=o.width,l.height=o.height,g.drawImage(o,0,0,o.width,o.height),g.getImageData(-s,-s,o.width+2*s,o.height+2*s)},resolveURL:function(o){return ot||(ot=ce.document.createElement("a")),ot.href=o,ot.href},hardwareConcurrency:ce.navigator&&ce.navigator.hardwareConcurrency||4,get devicePixelRatio(){return ce.devicePixelRatio},get prefersReducedMotion(){return!!ce.matchMedia&&(We==null&&(We=ce.matchMedia("(prefers-reduced-motion: reduce)")),We.matches)}},hn={API_URL:"https://api.mapbox.com",get EVENTS_URL(){return this.API_URL?this.API_URL.indexOf("https://api.mapbox.cn")===0?"https://events.mapbox.cn/events/v2":this.API_URL.indexOf("https://api.mapbox.com")===0?"https://events.mapbox.com/events/v2":null:null},FEEDBACK_URL:"https://apps.mapbox.com/feedback",REQUIRE_ACCESS_TOKEN:!0,ACCESS_TOKEN:null,MAX_PARALLEL_IMAGE_REQUESTS:16},ln={supported:!1,testSupport:function(o){!oi&&st&&(Nn?$n(o):Me=o)}},oi=!1,Nn=!1;function $n(o){var s=o.createTexture();o.bindTexture(o.TEXTURE_2D,s);try{if(o.texImage2D(o.TEXTURE_2D,0,o.RGBA,o.RGBA,o.UNSIGNED_BYTE,st),o.isContextLost())return;ln.supported=!0}catch(l){}o.deleteTexture(s),oi=!0}ce.document&&((st=ce.document.createElement("img")).onload=function(){Me&&$n(Me),Me=null,Nn=!0},st.onerror=function(){oi=!0,Me=null},st.src="data:image/webp;base64,UklGRh4AAABXRUJQVlA4TBEAAAAvAQAAAAfQ//73v/+BiOh/AAA=");var _i="01",Qn=function(o,s){this._transformRequestFn=o,this._customAccessToken=s,this._createSkuToken()};function Ji(o){return o.indexOf("mapbox:")===0}Qn.prototype._createSkuToken=function(){var o=function(){for(var s="",l=0;l<10;l++)s+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[Math.floor(62*Math.random())];return{token:["1",_i,s].join(""),tokenExpiresAt:Date.now()+432e5}}();this._skuToken=o.token,this._skuTokenExpiresAt=o.tokenExpiresAt},Qn.prototype._isSkuTokenExpired=function(){return Date.now()>this._skuTokenExpiresAt},Qn.prototype.transformRequest=function(o,s){return this._transformRequestFn&&this._transformRequestFn(o,s)||{url:o}},Qn.prototype.normalizeStyleURL=function(o,s){if(!Ji(o))return o;var l=sn(o);return l.path="/styles/v1"+l.path,this._makeAPIURL(l,this._customAccessToken||s)},Qn.prototype.normalizeGlyphsURL=function(o,s){if(!Ji(o))return o;var l=sn(o);return l.path="/fonts/v1"+l.path,this._makeAPIURL(l,this._customAccessToken||s)},Qn.prototype.normalizeSourceURL=function(o,s){if(!Ji(o))return o;var l=sn(o);return l.path="/v4/"+l.authority+".json",l.params.push("secure"),this._makeAPIURL(l,this._customAccessToken||s)},Qn.prototype.normalizeSpriteURL=function(o,s,l,g){var M=sn(o);return Ji(o)?(M.path="/styles/v1"+M.path+"/sprite"+s+l,this._makeAPIURL(M,this._customAccessToken||g)):(M.path+=""+s+l,li(M))},Qn.prototype.normalizeTileURL=function(o,s){if(this._isSkuTokenExpired()&&this._createSkuToken(),o&&!Ji(o))return o;var l=sn(o);l.path=l.path.replace(/(\.(png|jpg)\d*)(?=$)/,(Yr.devicePixelRatio>=2||s===512?"@2x":"")+(ln.supported?".webp":"$1")),l.path=l.path.replace(/^.+\/v4\//,"/"),l.path="/v4"+l.path;var g=this._customAccessToken||function(M){for(var j=0,J=M;j=0&&o.params.splice(M,1)}if(g.path!=="/"&&(o.path=""+g.path+o.path),!hn.REQUIRE_ACCESS_TOKEN)return li(o);if(!(s=s||hn.ACCESS_TOKEN))throw new Error("An API access token is required to use Mapbox GL. "+l);if(s[0]==="s")throw new Error("Use a public access token (pk.*) with Mapbox GL, not a secret access token (sk.*). "+l);return o.params=o.params.filter(function(j){return j.indexOf("access_token")===-1}),o.params.push("access_token="+s),li(o)};var ni=/^((https?:)?\/\/)?([^\/]+\.)?mapbox\.c(n|om)(\/|\?|$)/i;function Ei(o){return ni.test(o)}var xo=/^(\w+):\/\/([^/?]*)(\/[^?]+)?\??(.+)?/;function sn(o){var s=o.match(xo);if(!s)throw new Error("Unable to parse URL object");return{protocol:s[1],authority:s[2],path:s[3]||"/",params:s[4]?s[4].split("&"):[]}}function li(o){var s=o.params.length?"?"+o.params.join("&"):"";return o.protocol+"://"+o.authority+o.path+s}function En(o){if(!o)return null;var s=o.split(".");if(!s||s.length!==3)return null;try{return JSON.parse(decodeURIComponent(ce.atob(s[1]).split("").map(function(l){return"%"+("00"+l.charCodeAt(0).toString(16)).slice(-2)}).join("")))}catch(l){return null}}var or=function(o){this.type=o,this.anonId=null,this.eventData={},this.queue=[],this.pendingRequest=null};or.prototype.getStorageKey=function(o){var s,l=En(hn.ACCESS_TOKEN);return s=l&&l.u?ce.btoa(encodeURIComponent(l.u).replace(/%([0-9A-F]{2})/g,function(g,M){return String.fromCharCode(+("0x"+M))})):hn.ACCESS_TOKEN||"",o?"mapbox.eventData."+o+":"+s:"mapbox.eventData:"+s},or.prototype.fetchEventData=function(){var o=mt("localStorage"),s=this.getStorageKey(),l=this.getStorageKey("uuid");if(o)try{var g=ce.localStorage.getItem(s);g&&(this.eventData=JSON.parse(g));var M=ce.localStorage.getItem(l);M&&(this.anonId=M)}catch(j){et("Unable to read from LocalStorage")}},or.prototype.saveEventData=function(){var o=mt("localStorage"),s=this.getStorageKey(),l=this.getStorageKey("uuid");if(o)try{ce.localStorage.setItem(l,this.anonId),Object.keys(this.eventData).length>=1&&ce.localStorage.setItem(s,JSON.stringify(this.eventData))}catch(g){et("Unable to write to LocalStorage")}},or.prototype.processRequests=function(o){},or.prototype.postEvent=function(o,s,l,g){var M=this;if(hn.EVENTS_URL){var j=sn(hn.EVENTS_URL);j.params.push("access_token="+(g||hn.ACCESS_TOKEN||""));var J={event:this.type,created:new Date(o).toISOString(),sdkIdentifier:"mapbox-gl-js",sdkVersion:"1.13.3",skuId:_i,userId:this.anonId},ve=s?Ge(J,s):J,ze={url:li(j),headers:{"Content-Type":"text/plain"},body:JSON.stringify([ve])};this.pendingRequest=Lt(ze,function(lt){M.pendingRequest=null,l(lt),M.saveEventData(),M.processRequests(g)})}},or.prototype.queueRequest=function(o,s){this.queue.push(o),this.processRequests(s)};var qi,Bo,Mo=function(o){function s(){o.call(this,"map.load"),this.success={},this.skuToken=""}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype.postMapLoadEvent=function(l,g,M,j){this.skuToken=M;var J=!(!j&&!hn.ACCESS_TOKEN),ve=Array.isArray(l)&&l.some(function(ze){return Ji(ze)||Ei(ze)});hn.EVENTS_URL&&J&&ve&&this.queueRequest({id:g,timestamp:Date.now()},j)},s.prototype.processRequests=function(l){var g=this;if(!this.pendingRequest&&this.queue.length!==0){var M=this.queue.shift(),j=M.id,J=M.timestamp;j&&this.success[j]||(this.anonId||this.fetchEventData(),Xe(this.anonId)||(this.anonId=ut()),this.postEvent(J,{skuToken:this.skuToken},function(ve){ve||j&&(g.success[j]=!0)},l))}},s}(or),Wi=new(function(o){function s(l){o.call(this,"appUserTurnstile"),this._customAccessToken=l}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype.postTurnstileEvent=function(l,g){hn.EVENTS_URL&&hn.ACCESS_TOKEN&&Array.isArray(l)&&l.some(function(M){return Ji(M)||Ei(M)})&&this.queueRequest(Date.now(),g)},s.prototype.processRequests=function(l){var g=this;if(!this.pendingRequest&&this.queue.length!==0){this.anonId&&this.eventData.lastSuccess&&this.eventData.tokenU||this.fetchEventData();var M=En(hn.ACCESS_TOKEN),j=M?M.u:hn.ACCESS_TOKEN,J=j!==this.eventData.tokenU;Xe(this.anonId)||(this.anonId=ut(),J=!0);var ve=this.queue.shift();if(this.eventData.lastSuccess){var ze=new Date(this.eventData.lastSuccess),lt=new Date(ve),Dt=(ve-this.eventData.lastSuccess)/864e5;J=J||Dt>=1||Dt<-1||ze.getDate()!==lt.getDate()}else J=!0;if(!J)return this.processRequests();this.postEvent(ve,{"enabled.telemetry":!1},function($t){$t||(g.eventData.lastSuccess=ve,g.eventData.tokenU=j)},l)}},s}(or)),Ii=Wi.postTurnstileEvent.bind(Wi),ko=new Mo,Fn=ko.postMapLoadEvent.bind(ko),zn=500,Un=50;function Hi(){ce.caches&&!qi&&(qi=ce.caches.open("mapbox-tiles"))}function Ki(o){var s=o.indexOf("?");return s<0?o:o.slice(0,s)}var Fo,xt=1/0;function it(){return Fo==null&&(Fo=ce.OffscreenCanvas&&new ce.OffscreenCanvas(1,1).getContext("2d")&&typeof ce.createImageBitmap=="function"),Fo}var kt={Unknown:"Unknown",Style:"Style",Source:"Source",Tile:"Tile",Glyphs:"Glyphs",SpriteImage:"SpriteImage",SpriteJSON:"SpriteJSON",Image:"Image"};typeof Object.freeze=="function"&&Object.freeze(kt);var ir=function(o){function s(l,g,M){g===401&&Ei(M)&&(l+=": you may have provided an invalid Mapbox access token. See https://www.mapbox.com/api-documentation/#access-tokens-and-token-scopes"),o.call(this,l),this.status=g,this.url=M,this.name=this.constructor.name,this.message=l}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype.toString=function(){return this.name+": "+this.message+" ("+this.status+"): "+this.url},s}(Error),Pr=ft()?function(){return self.worker&&self.worker.referrer}:function(){return(ce.location.protocol==="blob:"?ce.parent:ce).location.href},kr,An,Dn=function(o,s){if(!(/^file:/.test(l=o.url)||/^file:/.test(Pr())&&!/^\w+:/.test(l))){if(ce.fetch&&ce.Request&&ce.AbortController&&ce.Request.prototype.hasOwnProperty("signal"))return function(g,M){var j,J=new ce.AbortController,ve=new ce.Request(g.url,{method:g.method||"GET",body:g.body,credentials:g.credentials,headers:g.headers,referrer:Pr(),signal:J.signal}),ze=!1,lt=!1,Dt=(j=ve.url).indexOf("sku=")>0&&Ei(j);g.type==="json"&&ve.headers.set("Accept","application/json");var $t=function(wr,Vr,$r){if(!lt){if(wr&&wr.message!=="SecurityError"&&et(wr),Vr&&$r)return lr(Vr);var Xr=Date.now();ce.fetch(ve).then(function(Gr){if(Gr.ok){var Br=Dt?Gr.clone():null;return lr(Gr,Br,Xr)}return M(new ir(Gr.statusText,Gr.status,g.url))}).catch(function(Gr){Gr.code!==20&&M(new Error(Gr.message))})}},lr=function(wr,Vr,$r){(g.type==="arrayBuffer"?wr.arrayBuffer():g.type==="json"?wr.json():wr.text()).then(function(Xr){lt||(Vr&&$r&&function(Gr,Br,Tn){if(Hi(),qi){var Hn={status:Br.status,statusText:Br.statusText,headers:new ce.Headers};Br.headers.forEach(function(vo,Eo){return Hn.headers.set(Eo,vo)});var yi=wt(Br.headers.get("Cache-Control")||"");yi["no-store"]||(yi["max-age"]&&Hn.headers.set("Expires",new Date(Tn+1e3*yi["max-age"]).toUTCString()),new Date(Hn.headers.get("Expires")).getTime()-Tn<42e4||function(vo,Eo){if(Bo===void 0)try{new Response(new ReadableStream),Bo=!0}catch(Xo){Bo=!1}Bo?Eo(vo.body):vo.blob().then(Eo)}(Br,function(vo){var Eo=new ce.Response(vo,Hn);Hi(),qi&&qi.then(function(Xo){return Xo.put(Ki(Gr.url),Eo)}).catch(function(Xo){return et(Xo.message)})}))}}(ve,Vr,$r),ze=!0,M(null,Xr,wr.headers.get("Cache-Control"),wr.headers.get("Expires")))}).catch(function(Xr){lt||M(new Error(Xr.message))})};return Dt?function(wr,Vr){if(Hi(),!qi)return Vr(null);var $r=Ki(wr.url);qi.then(function(Xr){Xr.match($r).then(function(Gr){var Br=function(Tn){if(!Tn)return!1;var Hn=new Date(Tn.headers.get("Expires")||0),yi=wt(Tn.headers.get("Cache-Control")||"");return Hn>Date.now()&&!yi["no-cache"]}(Gr);Xr.delete($r),Br&&Xr.put($r,Gr.clone()),Vr(null,Gr,Br)}).catch(Vr)}).catch(Vr)}(ve,$t):$t(null,null),{cancel:function(){lt=!0,ze||J.abort()}}}(o,s);if(ft()&&self.worker&&self.worker.actor)return self.worker.actor.send("getResource",o,s,void 0,!0)}var l;return function(g,M){var j=new ce.XMLHttpRequest;for(var J in j.open(g.method||"GET",g.url,!0),g.type==="arrayBuffer"&&(j.responseType="arraybuffer"),g.headers)j.setRequestHeader(J,g.headers[J]);return g.type==="json"&&(j.responseType="text",j.setRequestHeader("Accept","application/json")),j.withCredentials=g.credentials==="include",j.onerror=function(){M(new Error(j.statusText))},j.onload=function(){if((j.status>=200&&j.status<300||j.status===0)&&j.response!==null){var ve=j.response;if(g.type==="json")try{ve=JSON.parse(j.response)}catch(ze){return M(ze)}M(null,ve,j.getResponseHeader("Cache-Control"),j.getResponseHeader("Expires"))}else M(new ir(j.statusText,j.status,g.url))},j.send(g.body),{cancel:function(){return j.abort()}}}(o,s)},Ht=function(o,s){return Dn(Ge(o,{type:"arrayBuffer"}),s)},Lt=function(o,s){return Dn(Ge(o,{method:"POST"}),s)},je="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAC0lEQVQYV2NgAAIAAAUAAarVyFEAAAAASUVORK5CYII=";kr=[],An=0;var $e=function(o,s){if(ln.supported&&(o.headers||(o.headers={}),o.headers.accept="image/webp,*/*"),An>=hn.MAX_PARALLEL_IMAGE_REQUESTS){var l={requestParameters:o,callback:s,cancelled:!1,cancel:function(){this.cancelled=!0}};return kr.push(l),l}An++;var g=!1,M=function(){if(!g)for(g=!0,An--;kr.length&&An0||this._oneTimeListeners&&this._oneTimeListeners[o]&&this._oneTimeListeners[o].length>0||this._eventedParent&&this._eventedParent.listens(o)},hr.prototype.setEventedParent=function(o,s){return this._eventedParent=o,this._eventedParentData=s,this};var Gt={$version:8,$root:{version:{required:!0,type:"enum",values:[8]},name:{type:"string"},metadata:{type:"*"},center:{type:"array",value:"number"},zoom:{type:"number"},bearing:{type:"number",default:0,period:360,units:"degrees"},pitch:{type:"number",default:0,units:"degrees"},light:{type:"light"},sources:{required:!0,type:"sources"},sprite:{type:"string"},glyphs:{type:"string"},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},"*":{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:{}},default:"mapbox"},volatile:{type:"boolean",default:!1},"*":{type:"*"}},source_geojson:{type:{required:!0,type:"enum",values:{geojson:{}}},data:{type:"*"},maxzoom:{type:"number",default:18},attribution:{type:"string"},buffer:{type:"number",default:128,maximum:512,minimum:0},filter:{type:"*"},tolerance:{type:"number",default:.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:{},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_background"],layout_background:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"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","property-type":"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","property-type":"constant"}},layout_heatmap:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},"layout_fill-extrusion":{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_line:{"line-cap":{type:"enum",values:{butt:{},round:{},square:{}},default:"butt",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"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"]},"property-type":"data-constant"},"line-round-limit":{type:"number",default:1.05,requires:[{"line-join":"round"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_symbol:{"symbol-placement":{type:"enum",values:{point:{},line:{},"line-center":{}},default:"point",expression:{interpolated:!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"],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:"number",default:2,minimum:0,units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"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:{},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-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"],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"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_raster:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_hillshade:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},filter:{type:"array",value:"*"},filter_operator:{type:"enum",values:{"==":{},"!=":{},">":{},">=":{},"<":{},"<=":{},in:{},"!in":{},all:{},any:{},none:{},has:{},"!has":{},within:{}}},geometry_type:{type:"enum",values:{Point:{},LineString:{},Polygon:{}}},function:{expression:{type:"expression"},stops:{type:"array",value:"function_stop"},base:{type:"number",default:1,minimum:0},property:{type:"string",default:"$zoom"},type:{type:"enum",values:{identity:{},exponential:{},interval:{},categorical:{}},default:"exponential"},colorSpace:{type:"enum",values:{rgb:{},lab:{},hcl:{}},default:"rgb"},default:{type:"*",required:!1}},function_stop:{type:"array",minimum:0,maximum:24,value:["number","color"],length:2},expression:{type:"array",value:"*",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}},paint:["paint_fill","paint_line","paint_circle","paint_heatmap","paint_fill-extrusion","paint_symbol","paint_raster","paint_hillshade","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-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"fill-pattern"}],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-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"]},"property-type":"cross-faded"},"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"},"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:"number",default:335,minimum:0,maximum:359,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:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-highlight-color":{type:"color",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"}},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"}}},Tr=function(o,s,l,g){this.message=(o?o+": ":"")+l,g&&(this.identifier=g),s!=null&&s.__line__&&(this.line=s.__line__)};function nn(o){var s=o.value;return s?[new Tr(o.key,s,"constants have been deprecated as of v8")]:[]}function bn(o){for(var s=[],l=arguments.length-1;l-- >0;)s[l]=arguments[l+1];for(var g=0,M=s;g":o.itemType.kind==="value"?"array":"array<"+s+">"}return o.kind}var fo=[Wn,Rn,di,zi,Gi,va,Lo,Ps(eo),Do];function hi(o,s){if(s.kind==="error")return null;if(o.kind==="array"){if(s.kind==="array"&&(s.N===0&&s.itemType.kind==="value"||!hi(o.itemType,s.itemType))&&(typeof o.N!="number"||o.N===s.N))return null}else{if(o.kind===s.kind)return null;if(o.kind==="value"){for(var l=0,g=fo;l255?255:ve}function M(ve){return g(ve[ve.length-1]==="%"?parseFloat(ve)/100*255:parseInt(ve))}function j(ve){return(ze=ve[ve.length-1]==="%"?parseFloat(ve)/100:parseFloat(ve))<0?0:ze>1?1:ze;var ze}function J(ve,ze,lt){return lt<0?lt+=1:lt>1&&(lt-=1),6*lt<1?ve+(ze-ve)*lt*6:2*lt<1?ze:3*lt<2?ve+(ze-ve)*(2/3-lt)*6:ve}try{s.parseCSSColor=function(ve){var ze,lt=ve.replace(/ /g,"").toLowerCase();if(lt in l)return l[lt].slice();if(lt[0]==="#")return lt.length===4?(ze=parseInt(lt.substr(1),16))>=0&&ze<=4095?[(3840&ze)>>4|(3840&ze)>>8,240&ze|(240&ze)>>4,15&ze|(15&ze)<<4,1]:null:lt.length===7&&(ze=parseInt(lt.substr(1),16))>=0&&ze<=16777215?[(16711680&ze)>>16,(65280&ze)>>8,255&ze,1]:null;var Dt=lt.indexOf("("),$t=lt.indexOf(")");if(Dt!==-1&&$t+1===lt.length){var lr=lt.substr(0,Dt),wr=lt.substr(Dt+1,$t-(Dt+1)).split(","),Vr=1;switch(lr){case"rgba":if(wr.length!==4)return null;Vr=j(wr.pop());case"rgb":return wr.length!==3?null:[M(wr[0]),M(wr[1]),M(wr[2]),Vr];case"hsla":if(wr.length!==4)return null;Vr=j(wr.pop());case"hsl":if(wr.length!==3)return null;var $r=(parseFloat(wr[0])%360+360)%360/360,Xr=j(wr[1]),Gr=j(wr[2]),Br=Gr<=.5?Gr*(Xr+1):Gr+Xr-Gr*Xr,Tn=2*Gr-Br;return[g(255*J(Tn,Br,$r+1/3)),g(255*J(Tn,Br,$r)),g(255*J(Tn,Br,$r-1/3)),Vr];default:return null}}return null}}catch(ve){}}).parseCSSColor,On=function(o,s,l,g){g===void 0&&(g=1),this.r=o,this.g=s,this.b=l,this.a=g};On.parse=function(o){if(o){if(o instanceof On)return o;if(typeof o=="string"){var s=Xi(o);if(s)return new On(s[0]/255*s[3],s[1]/255*s[3],s[2]/255*s[3],s[3])}}},On.prototype.toString=function(){var o=this.toArray(),s=o[1],l=o[2],g=o[3];return"rgba("+Math.round(o[0])+","+Math.round(s)+","+Math.round(l)+","+g+")"},On.prototype.toArray=function(){var o=this.a;return o===0?[0,0,0,0]:[255*this.r/o,255*this.g/o,255*this.b/o,o]},On.black=new On(0,0,0,1),On.white=new On(1,1,1,1),On.transparent=new On(0,0,0,0),On.red=new On(1,0,0,1);var gi=function(o,s,l){this.sensitivity=o?s?"variant":"case":s?"accent":"base",this.locale=l,this.collator=new Intl.Collator(this.locale?this.locale:[],{sensitivity:this.sensitivity,usage:"search"})};gi.prototype.compare=function(o,s){return this.collator.compare(o,s)},gi.prototype.resolvedLocale=function(){return new Intl.Collator(this.locale?this.locale:[]).resolvedOptions().locale};var ol=function(o,s,l,g,M){this.text=o,this.image=s,this.scale=l,this.fontStack=g,this.textColor=M},ks=function(o){this.sections=o};ks.fromString=function(o){return new ks([new ol(o,null,null,null,null)])},ks.prototype.isEmpty=function(){return this.sections.length===0||!this.sections.some(function(o){return o.text.length!==0||o.image&&o.image.name.length!==0})},ks.factory=function(o){return o instanceof ks?o:ks.fromString(o)},ks.prototype.toString=function(){return this.sections.length===0?"":this.sections.map(function(o){return o.text}).join("")},ks.prototype.serialize=function(){for(var o=["format"],s=0,l=this.sections;s=0&&o<=255&&typeof s=="number"&&s>=0&&s<=255&&typeof l=="number"&&l>=0&&l<=255?g===void 0||typeof g=="number"&&g>=0&&g<=1?null:"Invalid rgba value ["+[o,s,l,g].join(", ")+"]: 'a' must be between 0 and 1.":"Invalid rgba value ["+(typeof g=="number"?[o,s,l,g]:[o,s,l]).join(", ")+"]: 'r', 'g', and 'b' must be between 0 and 255."}function Ks(o){if(o===null||typeof o=="string"||typeof o=="boolean"||typeof o=="number"||o instanceof On||o instanceof gi||o instanceof ks||o instanceof as)return!0;if(Array.isArray(o)){for(var s=0,l=o;s2){var ve=o[1];if(typeof ve!="string"||!(ve in dc)||ve==="object")return s.error('The item type argument of "array" must be one of string, number, boolean',1);j=dc[ve],g++}else j=eo;if(o.length>3){if(o[2]!==null&&(typeof o[2]!="number"||o[2]<0||o[2]!==Math.floor(o[2])))return s.error('The length argument to "array" must be a positive integer literal',2);J=o[2],g++}l=Ps(j,J)}else l=dc[M];for(var ze=[];g1)&&s.push(g)}}return s.concat(this.args.map(function(M){return M.serialize()}))};var fl=function(o){this.type=va,this.sections=o};fl.parse=function(o,s){if(o.length<2)return s.error("Expected at least one argument.");var l=o[1];if(!Array.isArray(l)&&typeof l=="object")return s.error("First argument must be an image or text section.");for(var g=[],M=!1,j=1;j<=o.length-1;++j){var J=o[j];if(M&&typeof J=="object"&&!Array.isArray(J)){M=!1;var ve=null;if(J["font-scale"]&&!(ve=s.parse(J["font-scale"],1,Rn)))return null;var ze=null;if(J["text-font"]&&!(ze=s.parse(J["text-font"],1,Ps(di))))return null;var lt=null;if(J["text-color"]&&!(lt=s.parse(J["text-color"],1,Gi)))return null;var Dt=g[g.length-1];Dt.scale=ve,Dt.font=ze,Dt.textColor=lt}else{var $t=s.parse(o[j],1,eo);if(!$t)return null;var lr=$t.type.kind;if(lr!=="string"&&lr!=="value"&&lr!=="null"&&lr!=="resolvedImage")return s.error("Formatted text type must be 'string', 'value', 'image' or 'null'.");M=!0,g.push({content:$t,scale:null,font:null,textColor:null})}}return new fl(g)},fl.prototype.evaluate=function(o){return new ks(this.sections.map(function(s){var l=s.content.evaluate(o);return Ea(l)===Do?new ol("",l,null,null,null):new ol(hs(l),null,s.scale?s.scale.evaluate(o):null,s.font?s.font.evaluate(o).join(","):null,s.textColor?s.textColor.evaluate(o):null)}))},fl.prototype.eachChild=function(o){for(var s=0,l=this.sections;s-1),l},As.prototype.eachChild=function(o){o(this.input)},As.prototype.outputDefined=function(){return!1},As.prototype.serialize=function(){return["image",this.input.serialize()]};var Rl={"to-boolean":zi,"to-color":Gi,"to-number":Rn,"to-string":di},dl=function(o,s){this.type=o,this.args=s};dl.parse=function(o,s){if(o.length<2)return s.error("Expected at least one argument.");var l=o[0];if((l==="to-boolean"||l==="to-string")&&o.length!==2)return s.error("Expected one argument.");for(var g=Rl[l],M=[],j=1;j4?"Invalid rbga value "+JSON.stringify(s)+": expected an array containing either three or four numeric values.":_s(s[0],s[1],s[2],s[3])))return new On(s[0]/255,s[1]/255,s[2]/255,s[3])}throw new Fa(l||"Could not parse color from value '"+(typeof s=="string"?s:String(JSON.stringify(s)))+"'")}if(this.type.kind==="number"){for(var J=null,ve=0,ze=this.args;ve=s[2]||o[1]<=s[1]||o[3]>=s[3])}function Vt(o,s){var l=(180+o[0])/360,g=(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+o[1]*Math.PI/360)))/360,M=Math.pow(2,s.z);return[Math.round(l*M*8192),Math.round(g*M*8192)]}function gr(o,s,l){return s[1]>o[1]!=l[1]>o[1]&&o[0]<(l[0]-s[0])*(o[1]-s[1])/(l[1]-s[1])+s[0]}function gn(o,s){for(var l,g,M,j,J,ve,ze,lt=!1,Dt=0,$t=s.length;Dt<$t;Dt++)for(var lr=s[Dt],wr=0,Vr=lr.length;wr0&&ve<0||J<0&&ve>0}function ho(o,s,l){for(var g=0,M=l;gl[2]){var M=.5*g,j=o[0]-l[0]>M?-g:l[0]-o[0]>M?g:0;j===0&&(j=o[0]-l[2]>M?-g:l[2]-o[0]>M?g:0),o[0]+=j}Ci(s,o)}function Zr(o,s,l,g){for(var M=8192*Math.pow(2,g.z),j=[8192*g.x,8192*g.y],J=[],ve=0,ze=o;ve=0)return!1;var l=!0;return o.eachChild(function(g){l&&!so(g,s)&&(l=!1)}),l}In.parse=function(o,s){if(o.length!==2)return s.error("'within' expression requires exactly one argument, but found "+(o.length-1)+" instead.");if(Ks(o[1])){var l=o[1];if(l.type==="FeatureCollection")for(var g=0;gs))throw new Fa("Input is not a number.");j=J-1}return 0}Ho.prototype.parse=function(o,s,l,g,M){return M===void 0&&(M={}),s?this.concat(s,l,g)._parse(o,M):this._parse(o,M)},Ho.prototype._parse=function(o,s){function l(lt,Dt,$t){return $t==="assert"?new el(Dt,[lt]):$t==="coerce"?new dl(Dt,[lt]):lt}if(o!==null&&typeof o!="string"&&typeof o!="boolean"&&typeof o!="number"||(o=["literal",o]),Array.isArray(o)){if(o.length===0)return this.error('Expected an array with at least one element. If you wanted a literal array, use ["literal", []].');var g=o[0];if(typeof g!="string")return this.error("Expression name must be a string, but found "+typeof g+' instead. If you wanted a literal array, use ["literal", [...]].',0),null;var M=this.registry[g];if(M){var j=M.parse(o,this);if(!j)return null;if(this.expectedType){var J=this.expectedType,ve=j.type;if(J.kind!=="string"&&J.kind!=="number"&&J.kind!=="boolean"&&J.kind!=="object"&&J.kind!=="array"||ve.kind!=="value")if(J.kind!=="color"&&J.kind!=="formatted"&&J.kind!=="resolvedImage"||ve.kind!=="value"&&ve.kind!=="string"){if(this.checkSubtype(J,ve))return null}else j=l(j,J,s.typeAnnotation||"coerce");else j=l(j,J,s.typeAnnotation||"assert")}if(!(j instanceof Ju)&&j.type.kind!=="resolvedImage"&&function lt(Dt){if(Dt instanceof ro)return lt(Dt.boundExpression);if(Dt instanceof Pn&&Dt.name==="error"||Dt instanceof Wr||Dt instanceof In)return!1;var $t=Dt instanceof dl||Dt instanceof el,lr=!0;return Dt.eachChild(function(wr){lr=$t?lr&<(wr):lr&&wr instanceof Ju}),!!lr&&Kn(Dt)&&so(Dt,["zoom","heatmap-density","line-progress","accumulated","is-supported-script"])}(j)){var ze=new lu;try{j=new Ju(j.type,j.evaluate(ze))}catch(lt){return this.error(lt.message),null}}return j}return this.error('Unknown expression "'+g+'". If you wanted a literal array, use ["literal", [...]].',0)}return this.error(o===void 0?"'undefined' value invalid. Use null instead.":typeof o=="object"?'Bare objects invalid. Use ["literal", {...}] instead.':"Expected an array, but found "+typeof o+" instead.")},Ho.prototype.concat=function(o,s,l){var g=typeof o=="number"?this.path.concat(o):this.path,M=l?this.scope.concat(l):this.scope;return new Ho(this.registry,g,s||null,M,this.errors)},Ho.prototype.error=function(o){for(var s=[],l=arguments.length-1;l-- >0;)s[l]=arguments[l+1];var g=""+this.key+s.map(function(M){return"["+M+"]"}).join("");this.errors.push(new dn(g,o))},Ho.prototype.checkSubtype=function(o,s){var l=hi(o,s);return l&&this.error(l),l};var gs=function(o,s,l){this.type=o,this.input=s,this.labels=[],this.outputs=[];for(var g=0,M=l;g=J)return s.error('Input/output pairs for "step" expressions must be arranged with input values in strictly ascending order.',ze);var Dt=s.parse(ve,lt,M);if(!Dt)return null;M=M||Dt.type,g.push([J,Dt])}return new gs(M,l,g)},gs.prototype.evaluate=function(o){var s=this.labels,l=this.outputs;if(s.length===1)return l[0].evaluate(o);var g=this.input.evaluate(o);if(g<=s[0])return l[0].evaluate(o);var M=s.length;return g>=s[M-1]?l[M-1].evaluate(o):l[ya(s,g)].evaluate(o)},gs.prototype.eachChild=function(o){o(this.input);for(var s=0,l=this.outputs;s0&&o.push(this.labels[s]),o.push(this.outputs[s].serialize());return o};var No=Object.freeze({__proto__:null,number:lo,color:function(o,s,l){return new On(lo(o.r,s.r,l),lo(o.g,s.g,l),lo(o.b,s.b,l),lo(o.a,s.a,l))},array:function(o,s,l){return o.map(function(g,M){return lo(g,s[M],l)})}}),Da=6/29*3*(6/29),ta=Math.PI/180,Ra=180/Math.PI;function ns(o){return o>.008856451679035631?Math.pow(o,1/3):o/Da+4/29}function Vo(o){return o>6/29?o*o*o:Da*(o-4/29)}function bs(o){return 255*(o<=.0031308?12.92*o:1.055*Math.pow(o,1/2.4)-.055)}function Js(o){return(o/=255)<=.04045?o/12.92:Math.pow((o+.055)/1.055,2.4)}function Hu(o){var s=Js(o.r),l=Js(o.g),g=Js(o.b),M=ns((.4124564*s+.3575761*l+.1804375*g)/.95047),j=ns((.2126729*s+.7151522*l+.072175*g)/1);return{l:116*j-16,a:500*(M-j),b:200*(j-ns((.0193339*s+.119192*l+.9503041*g)/1.08883)),alpha:o.a}}function Of(o){var s=(o.l+16)/116,l=isNaN(o.a)?s:s+o.a/500,g=isNaN(o.b)?s:s-o.b/200;return s=1*Vo(s),l=.95047*Vo(l),g=1.08883*Vo(g),new On(bs(3.2404542*l-1.5371385*s-.4985314*g),bs(-.969266*l+1.8760108*s+.041556*g),bs(.0556434*l-.2040259*s+1.0572252*g),o.alpha)}function en(o,s,l){var g=s-o;return o+l*(g>180||g<-180?g-360*Math.round(g/360):g)}var xn={forward:Hu,reverse:Of,interpolate:function(o,s,l){return{l:lo(o.l,s.l,l),a:lo(o.a,s.a,l),b:lo(o.b,s.b,l),alpha:lo(o.alpha,s.alpha,l)}}},Vi={forward:function(o){var s=Hu(o),l=s.l,g=s.a,M=s.b,j=Math.atan2(M,g)*Ra;return{h:j<0?j+360:j,c:Math.sqrt(g*g+M*M),l,alpha:o.a}},reverse:function(o){var s=o.h*ta,l=o.c;return Of({l:o.l,a:Math.cos(s)*l,b:Math.sin(s)*l,alpha:o.alpha})},interpolate:function(o,s,l){return{h:en(o.h,s.h,l),c:lo(o.c,s.c,l),l:lo(o.l,s.l,l),alpha:lo(o.alpha,s.alpha,l)}}},wi=Object.freeze({__proto__:null,lab:xn,hcl:Vi}),oo=function(o,s,l,g,M){this.type=o,this.operator=s,this.interpolation=l,this.input=g,this.labels=[],this.outputs=[];for(var j=0,J=M;j1}))return s.error("Cubic bezier interpolation requires four numeric arguments with values between 0 and 1.",1);g={name:"cubic-bezier",controlPoints:ve}}if(o.length-1<4)return s.error("Expected at least 4 arguments, but found only "+(o.length-1)+".");if((o.length-1)%2!=0)return s.error("Expected an even number of arguments.");if(!(M=s.parse(M,2,Rn)))return null;var ze=[],lt=null;l==="interpolate-hcl"||l==="interpolate-lab"?lt=Gi:s.expectedType&&s.expectedType.kind!=="value"&&(lt=s.expectedType);for(var Dt=0;Dt=$t)return s.error('Input/output pairs for "interpolate" expressions must be arranged with input values in strictly ascending order.',wr);var $r=s.parse(lr,Vr,lt);if(!$r)return null;lt=lt||$r.type,ze.push([$t,$r])}return lt.kind==="number"||lt.kind==="color"||lt.kind==="array"&<.itemType.kind==="number"&&typeof lt.N=="number"?new oo(lt,l,g,M,ze):s.error("Type "+Nr(lt)+" is not interpolatable.")},oo.prototype.evaluate=function(o){var s=this.labels,l=this.outputs;if(s.length===1)return l[0].evaluate(o);var g=this.input.evaluate(o);if(g<=s[0])return l[0].evaluate(o);var M=s.length;if(g>=s[M-1])return l[M-1].evaluate(o);var j=ya(s,g),J=oo.interpolationFactor(this.interpolation,g,s[j],s[j+1]),ve=l[j].evaluate(o),ze=l[j+1].evaluate(o);return this.operator==="interpolate"?No[this.type.kind.toLowerCase()](ve,ze,J):this.operator==="interpolate-hcl"?Vi.reverse(Vi.interpolate(Vi.forward(ve),Vi.forward(ze),J)):xn.reverse(xn.interpolate(xn.forward(ve),xn.forward(ze),J))},oo.prototype.eachChild=function(o){o(this.input);for(var s=0,l=this.outputs;s=l.length)throw new Fa("Array index out of bounds: "+s+" > "+(l.length-1)+".");if(s!==Math.floor(s))throw new Fa("Array index must be an integer, but found "+s+" instead.");return l[s]},$a.prototype.eachChild=function(o){o(this.index),o(this.input)},$a.prototype.outputDefined=function(){return!1},$a.prototype.serialize=function(){return["at",this.index.serialize(),this.input.serialize()]};var Co=function(o,s){this.type=zi,this.needle=o,this.haystack=s};Co.parse=function(o,s){if(o.length!==3)return s.error("Expected 2 arguments, but found "+(o.length-1)+" instead.");var l=s.parse(o[1],1,eo),g=s.parse(o[2],2,eo);return l&&g?Yi(l.type,[zi,di,Rn,Wn,eo])?new Co(l,g):s.error("Expected first argument to be of type boolean, string, number or null, but found "+Nr(l.type)+" instead"):null},Co.prototype.evaluate=function(o){var s=this.needle.evaluate(o),l=this.haystack.evaluate(o);if(!l)return!1;if(!ga(s,["boolean","string","number","null"]))throw new Fa("Expected first argument to be of type boolean, string, number or null, but found "+Nr(Ea(s))+" instead.");if(!ga(l,["string","array"]))throw new Fa("Expected second argument to be of type array or string, but found "+Nr(Ea(l))+" instead.");return l.indexOf(s)>=0},Co.prototype.eachChild=function(o){o(this.needle),o(this.haystack)},Co.prototype.outputDefined=function(){return!0},Co.prototype.serialize=function(){return["in",this.needle.serialize(),this.haystack.serialize()]};var wo=function(o,s,l){this.type=Rn,this.needle=o,this.haystack=s,this.fromIndex=l};wo.parse=function(o,s){if(o.length<=2||o.length>=5)return s.error("Expected 3 or 4 arguments, but found "+(o.length-1)+" instead.");var l=s.parse(o[1],1,eo),g=s.parse(o[2],2,eo);if(!l||!g)return null;if(!Yi(l.type,[zi,di,Rn,Wn,eo]))return s.error("Expected first argument to be of type boolean, string, number or null, but found "+Nr(l.type)+" instead");if(o.length===4){var M=s.parse(o[3],3,Rn);return M?new wo(l,g,M):null}return new wo(l,g)},wo.prototype.evaluate=function(o){var s=this.needle.evaluate(o),l=this.haystack.evaluate(o);if(!ga(s,["boolean","string","number","null"]))throw new Fa("Expected first argument to be of type boolean, string, number or null, but found "+Nr(Ea(s))+" instead.");if(!ga(l,["string","array"]))throw new Fa("Expected second argument to be of type array or string, but found "+Nr(Ea(l))+" instead.");if(this.fromIndex){var g=this.fromIndex.evaluate(o);return l.indexOf(s,g)}return l.indexOf(s)},wo.prototype.eachChild=function(o){o(this.needle),o(this.haystack),this.fromIndex&&o(this.fromIndex)},wo.prototype.outputDefined=function(){return!1},wo.prototype.serialize=function(){if(this.fromIndex!=null&&this.fromIndex!==void 0){var o=this.fromIndex.serialize();return["index-of",this.needle.serialize(),this.haystack.serialize(),o]}return["index-of",this.needle.serialize(),this.haystack.serialize()]};var Pa=function(o,s,l,g,M,j){this.inputType=o,this.type=s,this.input=l,this.cases=g,this.outputs=M,this.otherwise=j};Pa.parse=function(o,s){if(o.length<5)return s.error("Expected at least 4 arguments, but found only "+(o.length-1)+".");if(o.length%2!=1)return s.error("Expected an even number of arguments.");var l,g;s.expectedType&&s.expectedType.kind!=="value"&&(g=s.expectedType);for(var M={},j=[],J=2;JNumber.MAX_SAFE_INTEGER)return lt.error("Branch labels must be integers no larger than "+Number.MAX_SAFE_INTEGER+".");if(typeof lr=="number"&&Math.floor(lr)!==lr)return lt.error("Numeric branch labels must be integer values.");if(l){if(lt.checkSubtype(l,Ea(lr)))return null}else l=Ea(lr);if(M[String(lr)]!==void 0)return lt.error("Branch labels must be unique.");M[String(lr)]=j.length}var wr=s.parse(ze,J,g);if(!wr)return null;g=g||wr.type,j.push(wr)}var Vr=s.parse(o[1],1,eo);if(!Vr)return null;var $r=s.parse(o[o.length-1],o.length-1,g);return $r?Vr.type.kind!=="value"&&s.concat(1).checkSubtype(l,Vr.type)?null:new Pa(l,g,Vr,M,j,$r):null},Pa.prototype.evaluate=function(o){var s=this.input.evaluate(o);return(Ea(s)===this.inputType&&this.outputs[this.cases[s]]||this.otherwise).evaluate(o)},Pa.prototype.eachChild=function(o){o(this.input),this.outputs.forEach(o),o(this.otherwise)},Pa.prototype.outputDefined=function(){return this.outputs.every(function(o){return o.outputDefined()})&&this.otherwise.outputDefined()},Pa.prototype.serialize=function(){for(var o=this,s=["match",this.input.serialize()],l=[],g={},M=0,j=Object.keys(this.cases).sort();M=5)return s.error("Expected 3 or 4 arguments, but found "+(o.length-1)+" instead.");var l=s.parse(o[1],1,eo),g=s.parse(o[2],2,Rn);if(!l||!g)return null;if(!Yi(l.type,[Ps(eo),di,eo]))return s.error("Expected first argument to be of type array or string, but found "+Nr(l.type)+" instead");if(o.length===4){var M=s.parse(o[3],3,Rn);return M?new si(l.type,l,g,M):null}return new si(l.type,l,g)},si.prototype.evaluate=function(o){var s=this.input.evaluate(o),l=this.beginIndex.evaluate(o);if(!ga(s,["string","array"]))throw new Fa("Expected first argument to be of type array or string, but found "+Nr(Ea(s))+" instead.");if(this.endIndex){var g=this.endIndex.evaluate(o);return s.slice(l,g)}return s.slice(l)},si.prototype.eachChild=function(o){o(this.input),o(this.beginIndex),this.endIndex&&o(this.endIndex)},si.prototype.outputDefined=function(){return!1},si.prototype.serialize=function(){if(this.endIndex!=null&&this.endIndex!==void 0){var o=this.endIndex.serialize();return["slice",this.input.serialize(),this.beginIndex.serialize(),o]}return["slice",this.input.serialize(),this.beginIndex.serialize()]};var qs=Aa("==",function(o,s,l){return s===l},Ns),Eu=Aa("!=",function(o,s,l){return s!==l},function(o,s,l,g){return!Ns(0,s,l,g)}),Cs=Aa("<",function(o,s,l){return s",function(o,s,l){return s>l},function(o,s,l,g){return g.compare(s,l)>0}),Vs=Aa("<=",function(o,s,l){return s<=l},function(o,s,l,g){return g.compare(s,l)<=0}),tl=Aa(">=",function(o,s,l){return s>=l},function(o,s,l,g){return g.compare(s,l)>=0}),Xs=function(o,s,l,g,M){this.type=di,this.number=o,this.locale=s,this.currency=l,this.minFractionDigits=g,this.maxFractionDigits=M};Xs.parse=function(o,s){if(o.length!==3)return s.error("Expected two arguments.");var l=s.parse(o[1],1,Rn);if(!l)return null;var g=o[2];if(typeof g!="object"||Array.isArray(g))return s.error("NumberFormat options argument must be an object.");var M=null;if(g.locale&&!(M=s.parse(g.locale,1,di)))return null;var j=null;if(g.currency&&!(j=s.parse(g.currency,1,di)))return null;var J=null;if(g["min-fraction-digits"]&&!(J=s.parse(g["min-fraction-digits"],1,Rn)))return null;var ve=null;return g["max-fraction-digits"]&&!(ve=s.parse(g["max-fraction-digits"],1,Rn))?null:new Xs(l,M,j,J,ve)},Xs.prototype.evaluate=function(o){return new Intl.NumberFormat(this.locale?this.locale.evaluate(o):[],{style:this.currency?"currency":"decimal",currency:this.currency?this.currency.evaluate(o):void 0,minimumFractionDigits:this.minFractionDigits?this.minFractionDigits.evaluate(o):void 0,maximumFractionDigits:this.maxFractionDigits?this.maxFractionDigits.evaluate(o):void 0}).format(this.number.evaluate(o))},Xs.prototype.eachChild=function(o){o(this.number),this.locale&&o(this.locale),this.currency&&o(this.currency),this.minFractionDigits&&o(this.minFractionDigits),this.maxFractionDigits&&o(this.maxFractionDigits)},Xs.prototype.outputDefined=function(){return!1},Xs.prototype.serialize=function(){var o={};return this.locale&&(o.locale=this.locale.serialize()),this.currency&&(o.currency=this.currency.serialize()),this.minFractionDigits&&(o["min-fraction-digits"]=this.minFractionDigits.serialize()),this.maxFractionDigits&&(o["max-fraction-digits"]=this.maxFractionDigits.serialize()),["number-format",this.number.serialize(),o]};var rc=function(o){this.type=Rn,this.input=o};rc.parse=function(o,s){if(o.length!==2)return s.error("Expected 1 argument, but found "+(o.length-1)+" instead.");var l=s.parse(o[1],1);return l?l.type.kind!=="array"&&l.type.kind!=="string"&&l.type.kind!=="value"?s.error("Expected argument of type string or array, but found "+Nr(l.type)+" instead."):new rc(l):null},rc.prototype.evaluate=function(o){var s=this.input.evaluate(o);if(typeof s=="string"||Array.isArray(s))return s.length;throw new Fa("Expected value to be of type string or array, but found "+Nr(Ea(s))+" instead.")},rc.prototype.eachChild=function(o){o(this.input)},rc.prototype.outputDefined=function(){return!1},rc.prototype.serialize=function(){var o=["length"];return this.eachChild(function(s){o.push(s.serialize())}),o};var Ha={"==":qs,"!=":Eu,">":su,"<":Cs,">=":tl,"<=":Vs,array:el,at:$a,boolean:el,case:ss,coalesce:Uo,collator:Wr,format:fl,image:As,in:Co,"index-of":wo,interpolate:oo,"interpolate-hcl":oo,"interpolate-lab":oo,length:rc,let:na,literal:Ju,match:Pa,number:el,"number-format":Xs,object:el,slice:si,step:gs,string:el,"to-boolean":dl,"to-color":dl,"to-number":dl,"to-string":dl,var:ro,within:In};function Qs(o,s){var l=s[0],g=s[1],M=s[2],j=s[3];l=l.evaluate(o),g=g.evaluate(o),M=M.evaluate(o);var J=j?j.evaluate(o):1,ve=_s(l,g,M,J);if(ve)throw new Fa(ve);return new On(l/255*J,g/255*J,M/255*J,J)}function Uu(o,s){return o in s}function St(o,s){var l=s[o];return l===void 0?null:l}function Zs(o){return{type:o}}function yu(o){return{result:"success",value:o}}function pl(o){return{result:"error",value:o}}function Ku(o){return o["property-type"]==="data-driven"||o["property-type"]==="cross-faded-data-driven"}function eu(o){return!!o.expression&&o.expression.parameters.indexOf("zoom")>-1}function Qo(o){return!!o.expression&&o.expression.interpolated}function ps(o){return o instanceof Number?"number":o instanceof String?"string":o instanceof Boolean?"boolean":Array.isArray(o)?"array":o===null?"null":typeof o}function xl(o){return typeof o=="object"&&o!==null&&!Array.isArray(o)}function Yl(o){return o}function ul(o,s,l){return o!==void 0?o:s!==void 0?s:l!==void 0?l:void 0}function Ef(o,s,l,g,M){return ul(typeof l===M?g[l]:void 0,o.default,s.default)}function sf(o,s,l){if(ps(l)!=="number")return ul(o.default,s.default);var g=o.stops.length;if(g===1||l<=o.stops[0][0])return o.stops[0][1];if(l>=o.stops[g-1][0])return o.stops[g-1][1];var M=ya(o.stops.map(function(j){return j[0]}),l);return o.stops[M][1]}function Hf(o,s,l){var g=o.base!==void 0?o.base:1;if(ps(l)!=="number")return ul(o.default,s.default);var M=o.stops.length;if(M===1||l<=o.stops[0][0])return o.stops[0][1];if(l>=o.stops[M-1][0])return o.stops[M-1][1];var j=ya(o.stops.map(function($t){return $t[0]}),l),J=function($t,lr,wr,Vr){var $r=Vr-wr,Xr=$t-wr;return $r===0?0:lr===1?Xr/$r:(Math.pow(lr,Xr)-1)/(Math.pow(lr,$r)-1)}(l,g,o.stops[j][0],o.stops[j+1][0]),ve=o.stops[j][1],ze=o.stops[j+1][1],lt=No[s.type]||Yl;if(o.colorSpace&&o.colorSpace!=="rgb"){var Dt=wi[o.colorSpace];lt=function($t,lr){return Dt.reverse(Dt.interpolate(Dt.forward($t),Dt.forward(lr),J))}}return typeof ve.evaluate=="function"?{evaluate:function(){for(var $t=[],lr=arguments.length;lr--;)$t[lr]=arguments[lr];var wr=ve.evaluate.apply(void 0,$t),Vr=ze.evaluate.apply(void 0,$t);if(wr!==void 0&&Vr!==void 0)return lt(wr,Vr,J)}}:lt(ve,ze,J)}function Ul(o,s,l){return s.type==="color"?l=On.parse(l):s.type==="formatted"?l=ks.fromString(l.toString()):s.type==="resolvedImage"?l=as.fromString(l.toString()):ps(l)===s.type||s.type==="enum"&&s.values[l]||(l=void 0),ul(l,o.default,s.default)}Pn.register(Ha,{error:[{kind:"error"},[di],function(o,s){throw new Fa(s[0].evaluate(o))}],typeof:[di,[eo],function(o,s){return Nr(Ea(s[0].evaluate(o)))}],"to-rgba":[Ps(Rn,4),[Gi],function(o,s){return s[0].evaluate(o).toArray()}],rgb:[Gi,[Rn,Rn,Rn],Qs],rgba:[Gi,[Rn,Rn,Rn,Rn],Qs],has:{type:zi,overloads:[[[di],function(o,s){return Uu(s[0].evaluate(o),o.properties())}],[[di,Lo],function(o,s){var l=s[1];return Uu(s[0].evaluate(o),l.evaluate(o))}]]},get:{type:eo,overloads:[[[di],function(o,s){return St(s[0].evaluate(o),o.properties())}],[[di,Lo],function(o,s){var l=s[1];return St(s[0].evaluate(o),l.evaluate(o))}]]},"feature-state":[eo,[di],function(o,s){return St(s[0].evaluate(o),o.featureState||{})}],properties:[Lo,[],function(o){return o.properties()}],"geometry-type":[di,[],function(o){return o.geometryType()}],id:[eo,[],function(o){return o.id()}],zoom:[Rn,[],function(o){return o.globals.zoom}],"heatmap-density":[Rn,[],function(o){return o.globals.heatmapDensity||0}],"line-progress":[Rn,[],function(o){return o.globals.lineProgress||0}],accumulated:[eo,[],function(o){return o.globals.accumulated===void 0?null:o.globals.accumulated}],"+":[Rn,Zs(Rn),function(o,s){for(var l=0,g=0,M=s;g":[zi,[di,eo],function(o,s){var l=s[0],g=s[1],M=o.properties()[l.value],j=g.value;return typeof M==typeof j&&M>j}],"filter-id->":[zi,[eo],function(o,s){var l=s[0],g=o.id(),M=l.value;return typeof g==typeof M&&g>M}],"filter-<=":[zi,[di,eo],function(o,s){var l=s[0],g=s[1],M=o.properties()[l.value],j=g.value;return typeof M==typeof j&&M<=j}],"filter-id-<=":[zi,[eo],function(o,s){var l=s[0],g=o.id(),M=l.value;return typeof g==typeof M&&g<=M}],"filter->=":[zi,[di,eo],function(o,s){var l=s[0],g=s[1],M=o.properties()[l.value],j=g.value;return typeof M==typeof j&&M>=j}],"filter-id->=":[zi,[eo],function(o,s){var l=s[0],g=o.id(),M=l.value;return typeof g==typeof M&&g>=M}],"filter-has":[zi,[eo],function(o,s){return s[0].value in o.properties()}],"filter-has-id":[zi,[],function(o){return o.id()!==null&&o.id()!==void 0}],"filter-type-in":[zi,[Ps(di)],function(o,s){return s[0].value.indexOf(o.geometryType())>=0}],"filter-id-in":[zi,[Ps(eo)],function(o,s){return s[0].value.indexOf(o.id())>=0}],"filter-in-small":[zi,[di,Ps(eo)],function(o,s){var l=s[0];return s[1].value.indexOf(o.properties()[l.value])>=0}],"filter-in-large":[zi,[di,Ps(eo)],function(o,s){var l=s[0],g=s[1];return function(M,j,J,ve){for(;J<=ve;){var ze=J+ve>>1;if(j[ze]===M)return!0;j[ze]>M?ve=ze-1:J=ze+1}return!1}(o.properties()[l.value],g.value,0,g.value.length-1)}],all:{type:zi,overloads:[[[zi,zi],function(o,s){var l=s[1];return s[0].evaluate(o)&&l.evaluate(o)}],[Zs(zi),function(o,s){for(var l=0,g=s;l0&&typeof o[0]=="string"&&o[0]in Ha}function Ol(o,s){var l=new Ho(Ha,[],s?function(M){var j={color:Gi,string:di,number:Rn,enum:di,boolean:zi,formatted:va,resolvedImage:Do};return M.type==="array"?Ps(j[M.value]||eo,M.length):j[M.type]}(s):void 0),g=l.parse(o,void 0,void 0,void 0,s&&s.type==="string"?{typeAnnotation:"coerce"}:void 0);return g?yu(new Lf(g,s)):pl(l.errors)}Lf.prototype.evaluateWithoutErrorHandling=function(o,s,l,g,M,j){return this._evaluator.globals=o,this._evaluator.feature=s,this._evaluator.featureState=l,this._evaluator.canonical=g,this._evaluator.availableImages=M||null,this._evaluator.formattedSection=j,this.expression.evaluate(this._evaluator)},Lf.prototype.evaluate=function(o,s,l,g,M,j){this._evaluator.globals=o,this._evaluator.feature=s||null,this._evaluator.featureState=l||null,this._evaluator.canonical=g,this._evaluator.availableImages=M||null,this._evaluator.formattedSection=j||null;try{var J=this.expression.evaluate(this._evaluator);if(J==null||typeof J=="number"&&J!=J)return this._defaultValue;if(this._enumValues&&!(J in this._enumValues))throw new Fa("Expected value to be one of "+Object.keys(this._enumValues).map(function(ve){return JSON.stringify(ve)}).join(", ")+", but found "+JSON.stringify(J)+" instead.");return J}catch(ve){return this._warningHistory[ve.message]||(this._warningHistory[ve.message]=!0,typeof console!="undefined"&&console.warn(ve.message)),this._defaultValue}};var _l=function(o,s){this.kind=o,this._styleExpression=s,this.isStateDependent=o!=="constant"&&!Mi(s.expression)};_l.prototype.evaluateWithoutErrorHandling=function(o,s,l,g,M,j){return this._styleExpression.evaluateWithoutErrorHandling(o,s,l,g,M,j)},_l.prototype.evaluate=function(o,s,l,g,M,j){return this._styleExpression.evaluate(o,s,l,g,M,j)};var cn=function(o,s,l,g){this.kind=o,this.zoomStops=l,this._styleExpression=s,this.isStateDependent=o!=="camera"&&!Mi(s.expression),this.interpolationType=g};function an(o,s){if((o=Ol(o,s)).result==="error")return o;var l=o.value.expression,g=Kn(l);if(!g&&!Ku(s))return pl([new dn("","data expressions not supported")]);var M=so(l,["zoom"]);if(!M&&!eu(s))return pl([new dn("","zoom expressions not supported")]);var j=function J(ve){var ze=null;if(ve instanceof na)ze=J(ve.result);else if(ve instanceof Uo)for(var lt=0,Dt=ve.args;ltg.maximum?[new Tr(s,l,l+" is greater than the maximum value "+g.maximum)]:[]}function Ia(o){var s,l,g,M=o.valueSpec,j=Bi(o.value.type),J={},ve=j!=="categorical"&&o.value.property===void 0,ze=!ve,lt=ps(o.value.stops)==="array"&&ps(o.value.stops[0])==="array"&&ps(o.value.stops[0][0])==="object",Dt=vi({key:o.key,value:o.value,valueSpec:o.styleSpec.function,style:o.style,styleSpec:o.styleSpec,objectElementValidators:{stops:function(wr){if(j==="identity")return[new Tr(wr.key,wr.value,'identity function may not have a "stops" property')];var Vr=[],$r=wr.value;return Vr=Vr.concat(to({key:wr.key,value:$r,valueSpec:wr.valueSpec,style:wr.style,styleSpec:wr.styleSpec,arrayElementValidator:$t})),ps($r)==="array"&&$r.length===0&&Vr.push(new Tr(wr.key,$r,"array must have at least one stop")),Vr},default:function(wr){return bu({key:wr.key,value:wr.value,valueSpec:M,style:wr.style,styleSpec:wr.styleSpec})}}});return j==="identity"&&ve&&Dt.push(new Tr(o.key,o.value,'missing required property "property"')),j==="identity"||o.value.stops||Dt.push(new Tr(o.key,o.value,'missing required property "stops"')),j==="exponential"&&o.valueSpec.expression&&!Qo(o.valueSpec)&&Dt.push(new Tr(o.key,o.value,"exponential functions not supported")),o.styleSpec.$version>=8&&(ze&&!Ku(o.valueSpec)?Dt.push(new Tr(o.key,o.value,"property functions not supported")):ve&&!eu(o.valueSpec)&&Dt.push(new Tr(o.key,o.value,"zoom functions not supported"))),j!=="categorical"&&!lt||o.value.property!==void 0||Dt.push(new Tr(o.key,o.value,'"property" property is required')),Dt;function $t(wr){var Vr=[],$r=wr.value,Xr=wr.key;if(ps($r)!=="array")return[new Tr(Xr,$r,"array expected, "+ps($r)+" found")];if($r.length!==2)return[new Tr(Xr,$r,"array length 2 expected, length "+$r.length+" found")];if(lt){if(ps($r[0])!=="object")return[new Tr(Xr,$r,"object expected, "+ps($r[0])+" found")];if($r[0].zoom===void 0)return[new Tr(Xr,$r,"object stop key must have zoom")];if($r[0].value===void 0)return[new Tr(Xr,$r,"object stop key must have value")];if(g&&g>Bi($r[0].zoom))return[new Tr(Xr,$r[0].zoom,"stop zoom values must appear in ascending order")];Bi($r[0].zoom)!==g&&(g=Bi($r[0].zoom),l=void 0,J={}),Vr=Vr.concat(vi({key:Xr+"[0]",value:$r[0],valueSpec:{zoom:{}},style:wr.style,styleSpec:wr.styleSpec,objectElementValidators:{zoom:zo,value:lr}}))}else Vr=Vr.concat(lr({key:Xr+"[0]",value:$r[0],valueSpec:{},style:wr.style,styleSpec:wr.styleSpec},$r));return Fc(on($r[1]))?Vr.concat([new Tr(Xr+"[1]",$r[1],"expressions are not allowed in function stops.")]):Vr.concat(bu({key:Xr+"[1]",value:$r[1],valueSpec:M,style:wr.style,styleSpec:wr.styleSpec}))}function lr(wr,Vr){var $r=ps(wr.value),Xr=Bi(wr.value),Gr=wr.value!==null?wr.value:Vr;if(s){if($r!==s)return[new Tr(wr.key,Gr,$r+" stop domain type must match previous stop domain type "+s)]}else s=$r;if($r!=="number"&&$r!=="string"&&$r!=="boolean")return[new Tr(wr.key,Gr,"stop domain value must be a number, string, or boolean")];if($r!=="number"&&j!=="categorical"){var Br="number expected, "+$r+" found";return Ku(M)&&j===void 0&&(Br+='\nIf you intended to use a categorical function, specify `"type": "categorical"`.'),[new Tr(wr.key,Gr,Br)]}return j!=="categorical"||$r!=="number"||isFinite(Xr)&&Math.floor(Xr)===Xr?j!=="categorical"&&$r==="number"&&l!==void 0&&Xr=2&&o[1]!=="$id"&&o[1]!=="$type";case"in":return o.length>=3&&(typeof o[1]!="string"||Array.isArray(o[2]));case"!in":case"!has":case"none":return!1;case"==":case"!=":case">":case">=":case"<":case"<=":return o.length!==3||Array.isArray(o[1])||Array.isArray(o[2]);case"any":case"all":for(var s=0,l=o.slice(1);ss?1:0}function Sl(o){if(!o)return!0;var s,l=o[0];return o.length<=1?l!=="any":l==="=="?wl(o[1],o[2],"=="):l==="!="?ll(wl(o[1],o[2],"==")):l==="<"||l===">"||l==="<="||l===">="?wl(o[1],o[2],l):l==="any"?(s=o.slice(1),["any"].concat(s.map(Sl))):l==="all"?["all"].concat(o.slice(1).map(Sl)):l==="none"?["all"].concat(o.slice(1).map(Sl).map(ll)):l==="in"?vu(o[1],o.slice(2)):l==="!in"?ll(vu(o[1],o.slice(2))):l==="has"?ml(o[1]):l==="!has"?ll(ml(o[1])):l!=="within"||o}function wl(o,s,l){switch(o){case"$type":return["filter-type-"+l,s];case"$id":return["filter-id-"+l,s];default:return["filter-"+l,o,s]}}function vu(o,s){if(s.length===0)return!1;switch(o){case"$type":return["filter-type-in",["literal",s]];case"$id":return["filter-id-in",["literal",s]];default:return s.length>200&&!s.some(function(l){return typeof l!=typeof s[0]})?["filter-in-large",o,["literal",s.sort(Is)]]:["filter-in-small",o,["literal",s]]}}function ml(o){switch(o){case"$type":return!0;case"$id":return["filter-has-id"];default:return["filter-has",o]}}function ll(o){return["!",o]}function Fu(o){return cs(on(o.value))?Sa(bn({},o,{expressionContext:"filter",valueSpec:{value:"boolean"}})):function s(l){var g=l.value,M=l.key;if(ps(g)!=="array")return[new Tr(M,g,"array expected, "+ps(g)+" found")];var j,J=l.styleSpec,ve=[];if(g.length<1)return[new Tr(M,g,"filter array must have at least 1 element")];switch(ve=ve.concat(fa({key:M+"[0]",value:g[0],valueSpec:J.filter_operator,style:l.style,styleSpec:l.styleSpec})),Bi(g[0])){case"<":case"<=":case">":case">=":g.length>=2&&Bi(g[1])==="$type"&&ve.push(new Tr(M,g,'"$type" cannot be use with operator "'+g[0]+'"'));case"==":case"!=":g.length!==3&&ve.push(new Tr(M,g,'filter array for operator "'+g[0]+'" must have 3 elements'));case"in":case"!in":g.length>=2&&(j=ps(g[1]))!=="string"&&ve.push(new Tr(M+"[1]",g[1],"string expected, "+j+" found"));for(var ze=2;ze=Dt[wr+0]&&g>=Dt[wr+1])?(J[lr]=!0,j.push(lt[lr])):J[lr]=!1}}},Us.prototype._forEachCell=function(o,s,l,g,M,j,J,ve){for(var ze=this._convertToCellCoord(o),lt=this._convertToCellCoord(s),Dt=this._convertToCellCoord(l),$t=this._convertToCellCoord(g),lr=ze;lr<=Dt;lr++)for(var wr=lt;wr<=$t;wr++){var Vr=this.d*wr+lr;if((!ve||ve(this._convertFromCellCoord(lr),this._convertFromCellCoord(wr),this._convertFromCellCoord(lr+1),this._convertFromCellCoord(wr+1)))&&M.call(this,o,s,l,g,Vr,j,J,ve))return}},Us.prototype._convertFromCellCoord=function(o){return(o-this.padding)/this.scale},Us.prototype._convertToCellCoord=function(o){return Math.max(0,Math.min(this.d-1,Math.floor(o*this.scale)+this.padding))},Us.prototype.toArrayBuffer=function(){if(this.arrayBuffer)return this.arrayBuffer;for(var o=this.cells,s=3+this.cells.length+1+1,l=0,g=0;g=0)){var Dt=o[lt];ze[lt]=Ca[ve].shallow.indexOf(lt)>=0?Dt:Fr(Dt,s)}o instanceof Error&&(ze.message=o.message)}if(ze.$name)throw new Error("$name property is reserved for worker serialization logic.");return ve!=="Object"&&(ze.$name=ve),ze}throw new Error("can't serialize object of type "+typeof o)}function Hl(o){if(o==null||typeof o=="boolean"||typeof o=="number"||typeof o=="string"||o instanceof Boolean||o instanceof Number||o instanceof String||o instanceof Date||o instanceof RegExp||Gf(o)||Li(o)||ArrayBuffer.isView(o)||o instanceof vl)return o;if(Array.isArray(o))return o.map(Hl);if(typeof o=="object"){var s=o.$name||"Object",l=Ca[s].klass;if(!l)throw new Error("can't deserialize unregistered class "+s);if(l.deserialize)return l.deserialize(o);for(var g=Object.create(l.prototype),M=0,j=Object.keys(o);M=0?ve:Hl(ve)}}return g}throw new Error("can't deserialize object of type "+typeof o)}var Ur=function(){this.first=!0};Ur.prototype.update=function(o,s){var l=Math.floor(o);return this.first?(this.first=!1,this.lastIntegerZoom=l,this.lastIntegerZoomTime=0,this.lastZoom=o,this.lastFloorZoom=l,!0):(this.lastFloorZoom>l?(this.lastIntegerZoom=l+1,this.lastIntegerZoomTime=s):this.lastFloorZoom=128&&o<=255},Arabic:function(o){return o>=1536&&o<=1791},"Arabic Supplement":function(o){return o>=1872&&o<=1919},"Arabic Extended-A":function(o){return o>=2208&&o<=2303},"Hangul Jamo":function(o){return o>=4352&&o<=4607},"Unified Canadian Aboriginal Syllabics":function(o){return o>=5120&&o<=5759},Khmer:function(o){return o>=6016&&o<=6143},"Unified Canadian Aboriginal Syllabics Extended":function(o){return o>=6320&&o<=6399},"General Punctuation":function(o){return o>=8192&&o<=8303},"Letterlike Symbols":function(o){return o>=8448&&o<=8527},"Number Forms":function(o){return o>=8528&&o<=8591},"Miscellaneous Technical":function(o){return o>=8960&&o<=9215},"Control Pictures":function(o){return o>=9216&&o<=9279},"Optical Character Recognition":function(o){return o>=9280&&o<=9311},"Enclosed Alphanumerics":function(o){return o>=9312&&o<=9471},"Geometric Shapes":function(o){return o>=9632&&o<=9727},"Miscellaneous Symbols":function(o){return o>=9728&&o<=9983},"Miscellaneous Symbols and Arrows":function(o){return o>=11008&&o<=11263},"CJK Radicals Supplement":function(o){return o>=11904&&o<=12031},"Kangxi Radicals":function(o){return o>=12032&&o<=12255},"Ideographic Description Characters":function(o){return o>=12272&&o<=12287},"CJK Symbols and Punctuation":function(o){return o>=12288&&o<=12351},Hiragana:function(o){return o>=12352&&o<=12447},Katakana:function(o){return o>=12448&&o<=12543},Bopomofo:function(o){return o>=12544&&o<=12591},"Hangul Compatibility Jamo":function(o){return o>=12592&&o<=12687},Kanbun:function(o){return o>=12688&&o<=12703},"Bopomofo Extended":function(o){return o>=12704&&o<=12735},"CJK Strokes":function(o){return o>=12736&&o<=12783},"Katakana Phonetic Extensions":function(o){return o>=12784&&o<=12799},"Enclosed CJK Letters and Months":function(o){return o>=12800&&o<=13055},"CJK Compatibility":function(o){return o>=13056&&o<=13311},"CJK Unified Ideographs Extension A":function(o){return o>=13312&&o<=19903},"Yijing Hexagram Symbols":function(o){return o>=19904&&o<=19967},"CJK Unified Ideographs":function(o){return o>=19968&&o<=40959},"Yi Syllables":function(o){return o>=40960&&o<=42127},"Yi Radicals":function(o){return o>=42128&&o<=42191},"Hangul Jamo Extended-A":function(o){return o>=43360&&o<=43391},"Hangul Syllables":function(o){return o>=44032&&o<=55215},"Hangul Jamo Extended-B":function(o){return o>=55216&&o<=55295},"Private Use Area":function(o){return o>=57344&&o<=63743},"CJK Compatibility Ideographs":function(o){return o>=63744&&o<=64255},"Arabic Presentation Forms-A":function(o){return o>=64336&&o<=65023},"Vertical Forms":function(o){return o>=65040&&o<=65055},"CJK Compatibility Forms":function(o){return o>=65072&&o<=65103},"Small Form Variants":function(o){return o>=65104&&o<=65135},"Arabic Presentation Forms-B":function(o){return o>=65136&&o<=65279},"Halfwidth and Fullwidth Forms":function(o){return o>=65280&&o<=65519}};function cu(o){for(var s=0,l=o;s=65097&&o<=65103)||ja["CJK Compatibility Ideographs"](o)||ja["CJK Compatibility"](o)||ja["CJK Radicals Supplement"](o)||ja["CJK Strokes"](o)||!(!ja["CJK Symbols and Punctuation"](o)||o>=12296&&o<=12305||o>=12308&&o<=12319||o===12336)||ja["CJK Unified Ideographs Extension A"](o)||ja["CJK Unified Ideographs"](o)||ja["Enclosed CJK Letters and Months"](o)||ja["Hangul Compatibility Jamo"](o)||ja["Hangul Jamo Extended-A"](o)||ja["Hangul Jamo Extended-B"](o)||ja["Hangul Jamo"](o)||ja["Hangul Syllables"](o)||ja.Hiragana(o)||ja["Ideographic Description Characters"](o)||ja.Kanbun(o)||ja["Kangxi Radicals"](o)||ja["Katakana Phonetic Extensions"](o)||ja.Katakana(o)&&o!==12540||!(!ja["Halfwidth and Fullwidth Forms"](o)||o===65288||o===65289||o===65293||o>=65306&&o<=65310||o===65339||o===65341||o===65343||o>=65371&&o<=65503||o===65507||o>=65512&&o<=65519)||!(!ja["Small Form Variants"](o)||o>=65112&&o<=65118||o>=65123&&o<=65126)||ja["Unified Canadian Aboriginal Syllabics"](o)||ja["Unified Canadian Aboriginal Syllabics Extended"](o)||ja["Vertical Forms"](o)||ja["Yijing Hexagram Symbols"](o)||ja["Yi Syllables"](o)||ja["Yi Radicals"](o))))}function nc(o){return!(fu(o)||function(s){return!!(ja["Latin-1 Supplement"](s)&&(s===167||s===169||s===174||s===177||s===188||s===189||s===190||s===215||s===247)||ja["General Punctuation"](s)&&(s===8214||s===8224||s===8225||s===8240||s===8241||s===8251||s===8252||s===8258||s===8263||s===8264||s===8265||s===8273)||ja["Letterlike Symbols"](s)||ja["Number Forms"](s)||ja["Miscellaneous Technical"](s)&&(s>=8960&&s<=8967||s>=8972&&s<=8991||s>=8996&&s<=9e3||s===9003||s>=9085&&s<=9114||s>=9150&&s<=9165||s===9167||s>=9169&&s<=9179||s>=9186&&s<=9215)||ja["Control Pictures"](s)&&s!==9251||ja["Optical Character Recognition"](s)||ja["Enclosed Alphanumerics"](s)||ja["Geometric Shapes"](s)||ja["Miscellaneous Symbols"](s)&&!(s>=9754&&s<=9759)||ja["Miscellaneous Symbols and Arrows"](s)&&(s>=11026&&s<=11055||s>=11088&&s<=11097||s>=11192&&s<=11243)||ja["CJK Symbols and Punctuation"](s)||ja.Katakana(s)||ja["Private Use Area"](s)||ja["CJK Compatibility Forms"](s)||ja["Small Form Variants"](s)||ja["Halfwidth and Fullwidth Forms"](s)||s===8734||s===8756||s===8757||s>=9984&&s<=10087||s>=10102&&s<=10131||s===65532||s===65533)}(o))}function Su(o){return o>=1424&&o<=2303||ja["Arabic Presentation Forms-A"](o)||ja["Arabic Presentation Forms-B"](o)}function Wu(o,s){return!(!s&&Su(o)||o>=2304&&o<=3583||o>=3840&&o<=4255||ja.Khmer(o))}function Hc(o){for(var s=0,l=o;s-1&&(Kl="error"),Lc&&Lc(o)};function kl(){Wc.fire(new Jt("pluginStateChange",{pluginStatus:Kl,pluginURL:Ec}))}var Wc=new hr,Tl=function(){return Kl},ql=function(){if(Kl!=="deferred"||!Ec)throw new Error("rtl-text-plugin cannot be downloaded unless a pluginURL is specified");Kl="loading",kl(),Ec&&Ht({url:Ec},function(o){o?bl(o):(Kl="loaded",kl())})},ic={applyArabicShaping:null,processBidirectionalText:null,processStyledBidirectionalText:null,isLoaded:function(){return Kl==="loaded"||ic.applyArabicShaping!=null},isLoading:function(){return Kl==="loading"},setState:function(o){Kl=o.pluginStatus,Ec=o.pluginURL},isParsed:function(){return ic.applyArabicShaping!=null&&ic.processBidirectionalText!=null&&ic.processStyledBidirectionalText!=null},getPluginURL:function(){return Ec}},Ls=function(o,s){this.zoom=o,s?(this.now=s.now,this.fadeDuration=s.fadeDuration,this.zoomHistory=s.zoomHistory,this.transition=s.transition):(this.now=0,this.fadeDuration=0,this.zoomHistory=new Ur,this.transition={})};Ls.prototype.isSupportedScript=function(o){return function(s,l){for(var g=0,M=s;gthis.zoomHistory.lastIntegerZoom?{fromScale:2,toScale:1,t:s+(1-s)*l}:{fromScale:.5,toScale:1,t:1-(1-l)*s}};var cc=function(o,s){this.property=o,this.value=s,this.expression=function(l,g){if(xl(l))return new Xn(l,g);if(Fc(l)){var M=an(l,g);if(M.result==="error")throw new Error(M.value.map(function(J){return J.key+": "+J.message}).join(", "));return M.value}var j=l;return typeof l=="string"&&g.type==="color"&&(j=On.parse(l)),{kind:"constant",evaluate:function(){return j}}}(s===void 0?o.specification.default:s,o.specification)};cc.prototype.isDataDriven=function(){return this.expression.kind==="source"||this.expression.kind==="composite"},cc.prototype.possiblyEvaluate=function(o,s,l){return this.property.possiblyEvaluate(this,o,s,l)};var gu=function(o){this.property=o,this.value=new cc(o,void 0)};gu.prototype.transitioned=function(o,s){return new Qc(this.property,this.value,s,Ge({},o.transition,this.transition),o.now)},gu.prototype.untransitioned=function(){return new Qc(this.property,this.value,null,{},0)};var Cu=function(o){this._properties=o,this._values=Object.create(o.defaultTransitionablePropertyValues)};Cu.prototype.getValue=function(o){return Ne(this._values[o].value.value)},Cu.prototype.setValue=function(o,s){this._values.hasOwnProperty(o)||(this._values[o]=new gu(this._values[o].property)),this._values[o].value=new cc(this._values[o].property,s===null?void 0:Ne(s))},Cu.prototype.getTransition=function(o){return Ne(this._values[o].transition)},Cu.prototype.setTransition=function(o,s){this._values.hasOwnProperty(o)||(this._values[o]=new gu(this._values[o].property)),this._values[o].transition=Ne(s)||void 0},Cu.prototype.serialize=function(){for(var o={},s=0,l=Object.keys(this._values);sthis.end)return this.prior=null,M;if(this.value.isDataDriven())return this.prior=null,M;if(g=1)return 1;var ze=ve*ve,lt=ze*ve;return 4*(ve<.5?lt:3*(ve-ze)+lt-.75)}(J))}return M};var hf=function(o){this._properties=o,this._values=Object.create(o.defaultTransitioningPropertyValues)};hf.prototype.possiblyEvaluate=function(o,s,l){for(var g=new Sc(this._properties),M=0,j=Object.keys(this._values);Mj.zoomHistory.lastIntegerZoom?{from:l,to:g}:{from:M,to:g}},s.prototype.interpolate=function(l){return l},s}(ea),tu=function(o){this.specification=o};tu.prototype.possiblyEvaluate=function(o,s,l,g){if(o.value!==void 0){if(o.expression.kind==="constant"){var M=o.expression.evaluate(s,null,{},l,g);return this._calculate(M,M,M,s)}return this._calculate(o.expression.evaluate(new Ls(Math.floor(s.zoom-1),s)),o.expression.evaluate(new Ls(Math.floor(s.zoom),s)),o.expression.evaluate(new Ls(Math.floor(s.zoom+1),s)),s)}},tu.prototype._calculate=function(o,s,l,g){return g.zoom>g.zoomHistory.lastIntegerZoom?{from:o,to:s}:{from:l,to:s}},tu.prototype.interpolate=function(o){return o};var bh=function(o){this.specification=o};bh.prototype.possiblyEvaluate=function(o,s,l,g){return!!o.expression.evaluate(s,null,{},l,g)},bh.prototype.interpolate=function(){return!1};var pc=function(o){for(var s in this.properties=o,this.defaultPropertyValues={},this.defaultTransitionablePropertyValues={},this.defaultTransitioningPropertyValues={},this.defaultPossiblyEvaluatedValues={},this.overridableProperties=[],o){var l=o[s];l.specification.overridable&&this.overridableProperties.push(s);var g=this.defaultPropertyValues[s]=new cc(l,void 0),M=this.defaultTransitionablePropertyValues[s]=new gu(l);this.defaultTransitioningPropertyValues[s]=M.untransitioned(),this.defaultPossiblyEvaluatedValues[s]=g.possiblyEvaluate({})}};xa("DataDrivenProperty",ea),xa("DataConstantProperty",Ka),xa("CrossFadedDataDrivenProperty",qo),xa("CrossFadedProperty",tu),xa("ColorRampProperty",bh);var Wf=function(o){function s(l,g){if(o.call(this),this.id=l.id,this.type=l.type,this._featureFilter={filter:function(){return!0},needGeometry:!1},l.type!=="custom"&&(this.metadata=(l=l).metadata,this.minzoom=l.minzoom,this.maxzoom=l.maxzoom,l.type!=="background"&&(this.source=l.source,this.sourceLayer=l["source-layer"],this.filter=l.filter),g.layout&&(this._unevaluatedLayout=new Xc(g.layout)),g.paint)){for(var M in this._transitionablePaint=new Cu(g.paint),l.paint)this.setPaintProperty(M,l.paint[M],{validate:!1});for(var j in l.layout)this.setLayoutProperty(j,l.layout[j],{validate:!1});this._transitioningPaint=this._transitionablePaint.untransitioned(),this.paint=new Sc(g.paint)}}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype.getCrossfadeParameters=function(){return this._crossfadeParameters},s.prototype.getLayoutProperty=function(l){return l==="visibility"?this.visibility:this._unevaluatedLayout.getValue(l)},s.prototype.setLayoutProperty=function(l,g,M){M===void 0&&(M={}),g!=null&&this._validate(wc,"layers."+this.id+".layout."+l,l,g,M)||(l!=="visibility"?this._unevaluatedLayout.setValue(l,g):this.visibility=g)},s.prototype.getPaintProperty=function(l){return gt(l,"-transition")?this._transitionablePaint.getTransition(l.slice(0,-11)):this._transitionablePaint.getValue(l)},s.prototype.setPaintProperty=function(l,g,M){if(M===void 0&&(M={}),g!=null&&this._validate(vf,"layers."+this.id+".paint."+l,l,g,M))return!1;if(gt(l,"-transition"))return this._transitionablePaint.setTransition(l.slice(0,-11),g||void 0),!1;var j=this._transitionablePaint._values[l],J=j.property.specification["property-type"]==="cross-faded-data-driven",ve=j.value.isDataDriven(),ze=j.value;this._transitionablePaint.setValue(l,g),this._handleSpecialPaintPropertyUpdate(l);var lt=this._transitionablePaint._values[l].value;return lt.isDataDriven()||ve||J||this._handleOverridablePaintPropertyUpdate(l,ze,lt)},s.prototype._handleSpecialPaintPropertyUpdate=function(l){},s.prototype._handleOverridablePaintPropertyUpdate=function(l,g,M){return!1},s.prototype.isHidden=function(l){return!!(this.minzoom&&l=this.maxzoom)||this.visibility==="none"},s.prototype.updateTransitions=function(l){this._transitioningPaint=this._transitionablePaint.transitioned(l,this._transitioningPaint)},s.prototype.hasTransition=function(){return this._transitioningPaint.hasTransition()},s.prototype.recalculate=function(l,g){l.getCrossfadeParameters&&(this._crossfadeParameters=l.getCrossfadeParameters()),this._unevaluatedLayout&&(this.layout=this._unevaluatedLayout.possiblyEvaluate(l,void 0,g)),this.paint=this._transitioningPaint.possiblyEvaluate(l,void 0,g)},s.prototype.serialize=function(){var l={id:this.id,type:this.type,source:this.source,"source-layer":this.sourceLayer,metadata:this.metadata,minzoom:this.minzoom,maxzoom:this.maxzoom,filter:this.filter,layout:this._unevaluatedLayout&&this._unevaluatedLayout.serialize(),paint:this._transitionablePaint&&this._transitionablePaint.serialize()};return this.visibility&&(l.layout=l.layout||{},l.layout.visibility=this.visibility),tt(l,function(g,M){return!(g===void 0||M==="layout"&&!Object.keys(g).length||M==="paint"&&!Object.keys(g).length)})},s.prototype._validate=function(l,g,M,j,J){return J===void 0&&(J={}),(!J||J.validate!==!1)&&ac(this,l.call(kf,{key:g,layerType:this.type,objectKey:M,value:j,styleSpec:Gt,style:{glyphs:!0,sprite:!0}}))},s.prototype.is3D=function(){return!1},s.prototype.isTileClipped=function(){return!1},s.prototype.hasOffscreenPass=function(){return!1},s.prototype.resize=function(){},s.prototype.isStateDependent=function(){for(var l in this.paint._values){var g=this.paint.get(l);if(g instanceof Al&&Ku(g.property.specification)&&(g.value.kind==="source"||g.value.kind==="composite")&&g.value.isStateDependent)return!0}return!1},s}(hr),Tu={Int8:Int8Array,Uint8:Uint8Array,Int16:Int16Array,Uint16:Uint16Array,Int32:Int32Array,Uint32:Uint32Array,Float32:Float32Array},Ih=function(o,s){this._structArray=o,this._pos1=s*this.size,this._pos2=this._pos1/2,this._pos4=this._pos1/4,this._pos8=this._pos1/8},Bl=function(){this.isTransferred=!1,this.capacity=-1,this.resize(0)};function Xf(o,s){s===void 0&&(s=1);var l=0,g=0;return{members:o.map(function(M){var j=Tu[M.type].BYTES_PER_ELEMENT,J=l=fh(l,Math.max(s,j)),ve=M.components||1;return g=Math.max(g,j),l+=j*ve,{name:M.name,type:M.type,components:ve,offset:J}}),size:fh(l,Math.max(g,s)),alignment:s}}function fh(o,s){return Math.ceil(o/s)*s}Bl.serialize=function(o,s){return o._trim(),s&&(o.isTransferred=!0,s.push(o.arrayBuffer)),{length:o.length,arrayBuffer:o.arrayBuffer}},Bl.deserialize=function(o){var s=Object.create(this.prototype);return s.arrayBuffer=o.arrayBuffer,s.length=o.length,s.capacity=o.arrayBuffer.byteLength/s.bytesPerElement,s._refreshViews(),s},Bl.prototype._trim=function(){this.length!==this.capacity&&(this.capacity=this.length,this.arrayBuffer=this.arrayBuffer.slice(0,this.length*this.bytesPerElement),this._refreshViews())},Bl.prototype.clear=function(){this.length=0},Bl.prototype.resize=function(o){this.reserve(o),this.length=o},Bl.prototype.reserve=function(o){if(o>this.capacity){this.capacity=Math.max(o,Math.floor(5*this.capacity),128),this.arrayBuffer=new ArrayBuffer(this.capacity*this.bytesPerElement);var s=this.uint8;this._refreshViews(),s&&this.uint8.set(s)}},Bl.prototype._refreshViews=function(){throw new Error("_refreshViews() must be implemented by each concrete StructArray layout")};var uf=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g){var M=this.length;return this.resize(M+1),this.emplace(M,l,g)},s.prototype.emplace=function(l,g,M){var j=2*l;return this.int16[j+0]=g,this.int16[j+1]=M,l},s}(Bl);uf.prototype.bytesPerElement=4,xa("StructArrayLayout2i4",uf);var Yf=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g,M,j){var J=this.length;return this.resize(J+1),this.emplace(J,l,g,M,j)},s.prototype.emplace=function(l,g,M,j,J){var ve=4*l;return this.int16[ve+0]=g,this.int16[ve+1]=M,this.int16[ve+2]=j,this.int16[ve+3]=J,l},s}(Bl);Yf.prototype.bytesPerElement=8,xa("StructArrayLayout4i8",Yf);var rh=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g,M,j,J,ve){var ze=this.length;return this.resize(ze+1),this.emplace(ze,l,g,M,j,J,ve)},s.prototype.emplace=function(l,g,M,j,J,ve,ze){var lt=6*l;return this.int16[lt+0]=g,this.int16[lt+1]=M,this.int16[lt+2]=j,this.int16[lt+3]=J,this.int16[lt+4]=ve,this.int16[lt+5]=ze,l},s}(Bl);rh.prototype.bytesPerElement=12,xa("StructArrayLayout2i4i12",rh);var ud=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g,M,j,J,ve){var ze=this.length;return this.resize(ze+1),this.emplace(ze,l,g,M,j,J,ve)},s.prototype.emplace=function(l,g,M,j,J,ve,ze){var lt=4*l,Dt=8*l;return this.int16[lt+0]=g,this.int16[lt+1]=M,this.uint8[Dt+4]=j,this.uint8[Dt+5]=J,this.uint8[Dt+6]=ve,this.uint8[Dt+7]=ze,l},s}(Bl);ud.prototype.bytesPerElement=8,xa("StructArrayLayout2i4ub8",ud);var fp=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g){var M=this.length;return this.resize(M+1),this.emplace(M,l,g)},s.prototype.emplace=function(l,g,M){var j=2*l;return this.float32[j+0]=g,this.float32[j+1]=M,l},s}(Bl);fp.prototype.bytesPerElement=8,xa("StructArrayLayout2f8",fp);var h=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g,M,j,J,ve,ze,lt,Dt,$t){var lr=this.length;return this.resize(lr+1),this.emplace(lr,l,g,M,j,J,ve,ze,lt,Dt,$t)},s.prototype.emplace=function(l,g,M,j,J,ve,ze,lt,Dt,$t,lr){var wr=10*l;return this.uint16[wr+0]=g,this.uint16[wr+1]=M,this.uint16[wr+2]=j,this.uint16[wr+3]=J,this.uint16[wr+4]=ve,this.uint16[wr+5]=ze,this.uint16[wr+6]=lt,this.uint16[wr+7]=Dt,this.uint16[wr+8]=$t,this.uint16[wr+9]=lr,l},s}(Bl);h.prototype.bytesPerElement=20,xa("StructArrayLayout10ui20",h);var v=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g,M,j,J,ve,ze,lt,Dt,$t,lr,wr){var Vr=this.length;return this.resize(Vr+1),this.emplace(Vr,l,g,M,j,J,ve,ze,lt,Dt,$t,lr,wr)},s.prototype.emplace=function(l,g,M,j,J,ve,ze,lt,Dt,$t,lr,wr,Vr){var $r=12*l;return this.int16[$r+0]=g,this.int16[$r+1]=M,this.int16[$r+2]=j,this.int16[$r+3]=J,this.uint16[$r+4]=ve,this.uint16[$r+5]=ze,this.uint16[$r+6]=lt,this.uint16[$r+7]=Dt,this.int16[$r+8]=$t,this.int16[$r+9]=lr,this.int16[$r+10]=wr,this.int16[$r+11]=Vr,l},s}(Bl);v.prototype.bytesPerElement=24,xa("StructArrayLayout4i4ui4i24",v);var B=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g,M){var j=this.length;return this.resize(j+1),this.emplace(j,l,g,M)},s.prototype.emplace=function(l,g,M,j){var J=3*l;return this.float32[J+0]=g,this.float32[J+1]=M,this.float32[J+2]=j,l},s}(Bl);B.prototype.bytesPerElement=12,xa("StructArrayLayout3f12",B);var W=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l){var g=this.length;return this.resize(g+1),this.emplace(g,l)},s.prototype.emplace=function(l,g){return this.uint32[1*l+0]=g,l},s}(Bl);W.prototype.bytesPerElement=4,xa("StructArrayLayout1ul4",W);var _e=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g,M,j,J,ve,ze,lt,Dt){var $t=this.length;return this.resize($t+1),this.emplace($t,l,g,M,j,J,ve,ze,lt,Dt)},s.prototype.emplace=function(l,g,M,j,J,ve,ze,lt,Dt,$t){var lr=10*l,wr=5*l;return this.int16[lr+0]=g,this.int16[lr+1]=M,this.int16[lr+2]=j,this.int16[lr+3]=J,this.int16[lr+4]=ve,this.int16[lr+5]=ze,this.uint32[wr+3]=lt,this.uint16[lr+8]=Dt,this.uint16[lr+9]=$t,l},s}(Bl);_e.prototype.bytesPerElement=20,xa("StructArrayLayout6i1ul2ui20",_e);var _t=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g,M,j,J,ve){var ze=this.length;return this.resize(ze+1),this.emplace(ze,l,g,M,j,J,ve)},s.prototype.emplace=function(l,g,M,j,J,ve,ze){var lt=6*l;return this.int16[lt+0]=g,this.int16[lt+1]=M,this.int16[lt+2]=j,this.int16[lt+3]=J,this.int16[lt+4]=ve,this.int16[lt+5]=ze,l},s}(Bl);_t.prototype.bytesPerElement=12,xa("StructArrayLayout2i2i2i12",_t);var jt=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g,M,j,J){var ve=this.length;return this.resize(ve+1),this.emplace(ve,l,g,M,j,J)},s.prototype.emplace=function(l,g,M,j,J,ve){var ze=4*l,lt=8*l;return this.float32[ze+0]=g,this.float32[ze+1]=M,this.float32[ze+2]=j,this.int16[lt+6]=J,this.int16[lt+7]=ve,l},s}(Bl);jt.prototype.bytesPerElement=16,xa("StructArrayLayout2f1f2i16",jt);var ie=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g,M,j){var J=this.length;return this.resize(J+1),this.emplace(J,l,g,M,j)},s.prototype.emplace=function(l,g,M,j,J){var ve=12*l,ze=3*l;return this.uint8[ve+0]=g,this.uint8[ve+1]=M,this.float32[ze+1]=j,this.float32[ze+2]=J,l},s}(Bl);ie.prototype.bytesPerElement=12,xa("StructArrayLayout2ub2f12",ie);var f=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g,M){var j=this.length;return this.resize(j+1),this.emplace(j,l,g,M)},s.prototype.emplace=function(l,g,M,j){var J=3*l;return this.uint16[J+0]=g,this.uint16[J+1]=M,this.uint16[J+2]=j,l},s}(Bl);f.prototype.bytesPerElement=6,xa("StructArrayLayout3ui6",f);var L=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){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)},s.prototype.emplaceBack=function(l,g,M,j,J,ve,ze,lt,Dt,$t,lr,wr,Vr,$r,Xr,Gr,Br){var Tn=this.length;return this.resize(Tn+1),this.emplace(Tn,l,g,M,j,J,ve,ze,lt,Dt,$t,lr,wr,Vr,$r,Xr,Gr,Br)},s.prototype.emplace=function(l,g,M,j,J,ve,ze,lt,Dt,$t,lr,wr,Vr,$r,Xr,Gr,Br,Tn){var Hn=24*l,yi=12*l,vo=48*l;return this.int16[Hn+0]=g,this.int16[Hn+1]=M,this.uint16[Hn+2]=j,this.uint16[Hn+3]=J,this.uint32[yi+2]=ve,this.uint32[yi+3]=ze,this.uint32[yi+4]=lt,this.uint16[Hn+10]=Dt,this.uint16[Hn+11]=$t,this.uint16[Hn+12]=lr,this.float32[yi+7]=wr,this.float32[yi+8]=Vr,this.uint8[vo+36]=$r,this.uint8[vo+37]=Xr,this.uint8[vo+38]=Gr,this.uint32[yi+10]=Br,this.int16[Hn+22]=Tn,l},s}(Bl);L.prototype.bytesPerElement=48,xa("StructArrayLayout2i2ui3ul3ui2f3ub1ul1i48",L);var ee=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){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)},s.prototype.emplaceBack=function(l,g,M,j,J,ve,ze,lt,Dt,$t,lr,wr,Vr,$r,Xr,Gr,Br,Tn,Hn,yi,vo,Eo,Xo,ys,Yo,es,qa,Ts){var is=this.length;return this.resize(is+1),this.emplace(is,l,g,M,j,J,ve,ze,lt,Dt,$t,lr,wr,Vr,$r,Xr,Gr,Br,Tn,Hn,yi,vo,Eo,Xo,ys,Yo,es,qa,Ts)},s.prototype.emplace=function(l,g,M,j,J,ve,ze,lt,Dt,$t,lr,wr,Vr,$r,Xr,Gr,Br,Tn,Hn,yi,vo,Eo,Xo,ys,Yo,es,qa,Ts,is){var ts=34*l,Rs=17*l;return this.int16[ts+0]=g,this.int16[ts+1]=M,this.int16[ts+2]=j,this.int16[ts+3]=J,this.int16[ts+4]=ve,this.int16[ts+5]=ze,this.int16[ts+6]=lt,this.int16[ts+7]=Dt,this.uint16[ts+8]=$t,this.uint16[ts+9]=lr,this.uint16[ts+10]=wr,this.uint16[ts+11]=Vr,this.uint16[ts+12]=$r,this.uint16[ts+13]=Xr,this.uint16[ts+14]=Gr,this.uint16[ts+15]=Br,this.uint16[ts+16]=Tn,this.uint16[ts+17]=Hn,this.uint16[ts+18]=yi,this.uint16[ts+19]=vo,this.uint16[ts+20]=Eo,this.uint16[ts+21]=Xo,this.uint16[ts+22]=ys,this.uint32[Rs+12]=Yo,this.float32[Rs+13]=es,this.float32[Rs+14]=qa,this.float32[Rs+15]=Ts,this.float32[Rs+16]=is,l},s}(Bl);ee.prototype.bytesPerElement=68,xa("StructArrayLayout8i15ui1ul4f68",ee);var te=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l){var g=this.length;return this.resize(g+1),this.emplace(g,l)},s.prototype.emplace=function(l,g){return this.float32[1*l+0]=g,l},s}(Bl);te.prototype.bytesPerElement=4,xa("StructArrayLayout1f4",te);var me=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g,M){var j=this.length;return this.resize(j+1),this.emplace(j,l,g,M)},s.prototype.emplace=function(l,g,M,j){var J=3*l;return this.int16[J+0]=g,this.int16[J+1]=M,this.int16[J+2]=j,l},s}(Bl);me.prototype.bytesPerElement=6,xa("StructArrayLayout3i6",me);var He=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g,M){var j=this.length;return this.resize(j+1),this.emplace(j,l,g,M)},s.prototype.emplace=function(l,g,M,j){var J=4*l;return this.uint32[2*l+0]=g,this.uint16[J+2]=M,this.uint16[J+3]=j,l},s}(Bl);He.prototype.bytesPerElement=8,xa("StructArrayLayout1ul2ui8",He);var nt=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g){var M=this.length;return this.resize(M+1),this.emplace(M,l,g)},s.prototype.emplace=function(l,g,M){var j=2*l;return this.uint16[j+0]=g,this.uint16[j+1]=M,l},s}(Bl);nt.prototype.bytesPerElement=4,xa("StructArrayLayout2ui4",nt);var w=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l){var g=this.length;return this.resize(g+1),this.emplace(g,l)},s.prototype.emplace=function(l,g){return this.uint16[1*l+0]=g,l},s}(Bl);w.prototype.bytesPerElement=2,xa("StructArrayLayout1ui2",w);var Wt=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)},s.prototype.emplaceBack=function(l,g,M,j){var J=this.length;return this.resize(J+1),this.emplace(J,l,g,M,j)},s.prototype.emplace=function(l,g,M,j,J){var ve=4*l;return this.float32[ve+0]=g,this.float32[ve+1]=M,this.float32[ve+2]=j,this.float32[ve+3]=J,l},s}(Bl);Wt.prototype.bytesPerElement=16,xa("StructArrayLayout4f16",Wt);var b=function(o){function s(){o.apply(this,arguments)}o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s;var l={anchorPointX:{configurable:!0},anchorPointY:{configurable:!0},x1:{configurable:!0},y1:{configurable:!0},x2:{configurable:!0},y2:{configurable:!0},featureIndex:{configurable:!0},sourceLayerIndex:{configurable:!0},bucketIndex:{configurable:!0},anchorPoint:{configurable:!0}};return l.anchorPointX.get=function(){return this._structArray.int16[this._pos2+0]},l.anchorPointY.get=function(){return this._structArray.int16[this._pos2+1]},l.x1.get=function(){return this._structArray.int16[this._pos2+2]},l.y1.get=function(){return this._structArray.int16[this._pos2+3]},l.x2.get=function(){return this._structArray.int16[this._pos2+4]},l.y2.get=function(){return this._structArray.int16[this._pos2+5]},l.featureIndex.get=function(){return this._structArray.uint32[this._pos4+3]},l.sourceLayerIndex.get=function(){return this._structArray.uint16[this._pos2+8]},l.bucketIndex.get=function(){return this._structArray.uint16[this._pos2+9]},l.anchorPoint.get=function(){return new se(this.anchorPointX,this.anchorPointY)},Object.defineProperties(s.prototype,l),s}(Ih);b.prototype.size=20;var x=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype.get=function(l){return new b(this,l)},s}(_e);xa("CollisionBoxArray",x);var S=function(o){function s(){o.apply(this,arguments)}o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s;var l={anchorX:{configurable:!0},anchorY:{configurable:!0},glyphStartIndex:{configurable:!0},numGlyphs:{configurable:!0},vertexStartIndex:{configurable:!0},lineStartIndex:{configurable:!0},lineLength:{configurable:!0},segment:{configurable:!0},lowerSize:{configurable:!0},upperSize:{configurable:!0},lineOffsetX:{configurable:!0},lineOffsetY:{configurable:!0},writingMode:{configurable:!0},placedOrientation:{configurable:!0},hidden:{configurable:!0},crossTileID:{configurable:!0},associatedIconIndex:{configurable:!0}};return l.anchorX.get=function(){return this._structArray.int16[this._pos2+0]},l.anchorY.get=function(){return this._structArray.int16[this._pos2+1]},l.glyphStartIndex.get=function(){return this._structArray.uint16[this._pos2+2]},l.numGlyphs.get=function(){return this._structArray.uint16[this._pos2+3]},l.vertexStartIndex.get=function(){return this._structArray.uint32[this._pos4+2]},l.lineStartIndex.get=function(){return this._structArray.uint32[this._pos4+3]},l.lineLength.get=function(){return this._structArray.uint32[this._pos4+4]},l.segment.get=function(){return this._structArray.uint16[this._pos2+10]},l.lowerSize.get=function(){return this._structArray.uint16[this._pos2+11]},l.upperSize.get=function(){return this._structArray.uint16[this._pos2+12]},l.lineOffsetX.get=function(){return this._structArray.float32[this._pos4+7]},l.lineOffsetY.get=function(){return this._structArray.float32[this._pos4+8]},l.writingMode.get=function(){return this._structArray.uint8[this._pos1+36]},l.placedOrientation.get=function(){return this._structArray.uint8[this._pos1+37]},l.placedOrientation.set=function(g){this._structArray.uint8[this._pos1+37]=g},l.hidden.get=function(){return this._structArray.uint8[this._pos1+38]},l.hidden.set=function(g){this._structArray.uint8[this._pos1+38]=g},l.crossTileID.get=function(){return this._structArray.uint32[this._pos4+10]},l.crossTileID.set=function(g){this._structArray.uint32[this._pos4+10]=g},l.associatedIconIndex.get=function(){return this._structArray.int16[this._pos2+22]},Object.defineProperties(s.prototype,l),s}(Ih);S.prototype.size=48;var U=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype.get=function(l){return new S(this,l)},s}(L);xa("PlacedSymbolArray",U);var pe=function(o){function s(){o.apply(this,arguments)}o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s;var l={anchorX:{configurable:!0},anchorY:{configurable:!0},rightJustifiedTextSymbolIndex:{configurable:!0},centerJustifiedTextSymbolIndex:{configurable:!0},leftJustifiedTextSymbolIndex:{configurable:!0},verticalPlacedTextSymbolIndex:{configurable:!0},placedIconSymbolIndex:{configurable:!0},verticalPlacedIconSymbolIndex:{configurable:!0},key:{configurable:!0},textBoxStartIndex:{configurable:!0},textBoxEndIndex:{configurable:!0},verticalTextBoxStartIndex:{configurable:!0},verticalTextBoxEndIndex:{configurable:!0},iconBoxStartIndex:{configurable:!0},iconBoxEndIndex:{configurable:!0},verticalIconBoxStartIndex:{configurable:!0},verticalIconBoxEndIndex:{configurable:!0},featureIndex:{configurable:!0},numHorizontalGlyphVertices:{configurable:!0},numVerticalGlyphVertices:{configurable:!0},numIconVertices:{configurable:!0},numVerticalIconVertices:{configurable:!0},useRuntimeCollisionCircles:{configurable:!0},crossTileID:{configurable:!0},textBoxScale:{configurable:!0},textOffset0:{configurable:!0},textOffset1:{configurable:!0},collisionCircleDiameter:{configurable:!0}};return l.anchorX.get=function(){return this._structArray.int16[this._pos2+0]},l.anchorY.get=function(){return this._structArray.int16[this._pos2+1]},l.rightJustifiedTextSymbolIndex.get=function(){return this._structArray.int16[this._pos2+2]},l.centerJustifiedTextSymbolIndex.get=function(){return this._structArray.int16[this._pos2+3]},l.leftJustifiedTextSymbolIndex.get=function(){return this._structArray.int16[this._pos2+4]},l.verticalPlacedTextSymbolIndex.get=function(){return this._structArray.int16[this._pos2+5]},l.placedIconSymbolIndex.get=function(){return this._structArray.int16[this._pos2+6]},l.verticalPlacedIconSymbolIndex.get=function(){return this._structArray.int16[this._pos2+7]},l.key.get=function(){return this._structArray.uint16[this._pos2+8]},l.textBoxStartIndex.get=function(){return this._structArray.uint16[this._pos2+9]},l.textBoxEndIndex.get=function(){return this._structArray.uint16[this._pos2+10]},l.verticalTextBoxStartIndex.get=function(){return this._structArray.uint16[this._pos2+11]},l.verticalTextBoxEndIndex.get=function(){return this._structArray.uint16[this._pos2+12]},l.iconBoxStartIndex.get=function(){return this._structArray.uint16[this._pos2+13]},l.iconBoxEndIndex.get=function(){return this._structArray.uint16[this._pos2+14]},l.verticalIconBoxStartIndex.get=function(){return this._structArray.uint16[this._pos2+15]},l.verticalIconBoxEndIndex.get=function(){return this._structArray.uint16[this._pos2+16]},l.featureIndex.get=function(){return this._structArray.uint16[this._pos2+17]},l.numHorizontalGlyphVertices.get=function(){return this._structArray.uint16[this._pos2+18]},l.numVerticalGlyphVertices.get=function(){return this._structArray.uint16[this._pos2+19]},l.numIconVertices.get=function(){return this._structArray.uint16[this._pos2+20]},l.numVerticalIconVertices.get=function(){return this._structArray.uint16[this._pos2+21]},l.useRuntimeCollisionCircles.get=function(){return this._structArray.uint16[this._pos2+22]},l.crossTileID.get=function(){return this._structArray.uint32[this._pos4+12]},l.crossTileID.set=function(g){this._structArray.uint32[this._pos4+12]=g},l.textBoxScale.get=function(){return this._structArray.float32[this._pos4+13]},l.textOffset0.get=function(){return this._structArray.float32[this._pos4+14]},l.textOffset1.get=function(){return this._structArray.float32[this._pos4+15]},l.collisionCircleDiameter.get=function(){return this._structArray.float32[this._pos4+16]},Object.defineProperties(s.prototype,l),s}(Ih);pe.prototype.size=68;var Ce=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype.get=function(l){return new pe(this,l)},s}(ee);xa("SymbolInstanceArray",Ce);var Oe=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype.getoffsetX=function(l){return this.float32[1*l+0]},s}(te);xa("GlyphOffsetArray",Oe);var dt=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype.getx=function(l){return this.int16[3*l+0]},s.prototype.gety=function(l){return this.int16[3*l+1]},s.prototype.gettileUnitDistanceFromAnchor=function(l){return this.int16[3*l+2]},s}(me);xa("SymbolLineVertexArray",dt);var zt=function(o){function s(){o.apply(this,arguments)}o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s;var l={featureIndex:{configurable:!0},sourceLayerIndex:{configurable:!0},bucketIndex:{configurable:!0}};return l.featureIndex.get=function(){return this._structArray.uint32[this._pos4+0]},l.sourceLayerIndex.get=function(){return this._structArray.uint16[this._pos2+2]},l.bucketIndex.get=function(){return this._structArray.uint16[this._pos2+3]},Object.defineProperties(s.prototype,l),s}(Ih);zt.prototype.size=8;var Tt=function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype.get=function(l){return new zt(this,l)},s}(He);xa("FeatureIndexArray",Tt);var Qt=Xf([{name:"a_pos",components:2,type:"Int16"}],4).members,cr=function(o){o===void 0&&(o=[]),this.segments=o};function pr(o,s){return 256*(o=Ee(Math.floor(o),0,255))+Ee(Math.floor(s),0,255)}cr.prototype.prepareSegment=function(o,s,l,g){var M=this.segments[this.segments.length-1];return o>cr.MAX_VERTEX_ARRAY_LENGTH&&et("Max vertices per segment is "+cr.MAX_VERTEX_ARRAY_LENGTH+": bucket requested "+o),(!M||M.vertexLength+o>cr.MAX_VERTEX_ARRAY_LENGTH||M.sortKey!==g)&&(M={vertexOffset:s.length,primitiveOffset:l.length,vertexLength:0,primitiveLength:0},g!==void 0&&(M.sortKey=g),this.segments.push(M)),M},cr.prototype.get=function(){return this.segments},cr.prototype.destroy=function(){for(var o=0,s=this.segments;o>>16)*ve&65535)<<16)&4294967295)<<15|lt>>>17))*ze+(((lt>>>16)*ze&65535)<<16)&4294967295)<<13|j>>>19))+((5*(j>>>16)&65535)<<16)&4294967295))+((58964+(J>>>16)&65535)<<16);switch(lt=0,g){case 3:lt^=(255&s.charCodeAt(Dt+2))<<16;case 2:lt^=(255&s.charCodeAt(Dt+1))<<8;case 1:j^=lt=(65535&(lt=(lt=(65535&(lt^=255&s.charCodeAt(Dt)))*ve+(((lt>>>16)*ve&65535)<<16)&4294967295)<<15|lt>>>17))*ze+(((lt>>>16)*ze&65535)<<16)&4294967295}return j^=s.length,j=2246822507*(65535&(j^=j>>>16))+((2246822507*(j>>>16)&65535)<<16)&4294967295,j=3266489909*(65535&(j^=j>>>13))+((3266489909*(j>>>16)&65535)<<16)&4294967295,(j^=j>>>16)>>>0}}),tn=p(function(o){o.exports=function(s,l){for(var g,M=s.length,j=l^M,J=0;M>=4;)g=1540483477*(65535&(g=255&s.charCodeAt(J)|(255&s.charCodeAt(++J))<<8|(255&s.charCodeAt(++J))<<16|(255&s.charCodeAt(++J))<<24))+((1540483477*(g>>>16)&65535)<<16),j=1540483477*(65535&j)+((1540483477*(j>>>16)&65535)<<16)^(g=1540483477*(65535&(g^=g>>>24))+((1540483477*(g>>>16)&65535)<<16)),M-=4,++J;switch(M){case 3:j^=(255&s.charCodeAt(J+2))<<16;case 2:j^=(255&s.charCodeAt(J+1))<<8;case 1:j=1540483477*(65535&(j^=255&s.charCodeAt(J)))+((1540483477*(j>>>16)&65535)<<16)}return j=1540483477*(65535&(j^=j>>>13))+((1540483477*(j>>>16)&65535)<<16),(j^=j>>>15)>>>0}}),Hr=jr,fn=tn;Hr.murmur3=jr,Hr.murmur2=fn;var qt=function(){this.ids=[],this.positions=[],this.indexed=!1};qt.prototype.add=function(o,s,l,g){this.ids.push(Ai(o)),this.positions.push(s,l,g)},qt.prototype.getPositions=function(o){for(var s=Ai(o),l=0,g=this.ids.length-1;l>1;this.ids[M]>=s?g=M:l=M+1}for(var j=[];this.ids[l]===s;)j.push({index:this.positions[3*l],start:this.positions[3*l+1],end:this.positions[3*l+2]}),l++;return j},qt.serialize=function(o,s){var l=new Float64Array(o.ids),g=new Uint32Array(o.positions);return function M(j,J,ve,ze){for(;ve>1],Dt=ve-1,$t=ze+1;;){do Dt++;while(j[Dt]lt);if(Dt>=$t)break;xr(j,Dt,$t),xr(J,3*Dt,3*$t),xr(J,3*Dt+1,3*$t+1),xr(J,3*Dt+2,3*$t+2)}$t-veJ.x+1||zeJ.y+1)&&et("Geometry exceeds allowed extent, reduce your vector tile buffer size")}return l}function Kf(o,s){return{type:o.type,id:o.id,properties:o.properties,geometry:s?sc(o):[]}}function nh(o,s,l,g,M){o.emplaceBack(2*s+(g+1)/2,2*l+(M+1)/2)}var Rh=function(o){this.zoom=o.zoom,this.overscaling=o.overscaling,this.layers=o.layers,this.layerIds=this.layers.map(function(s){return s.id}),this.index=o.index,this.hasPattern=!1,this.layoutVertexArray=new uf,this.indexArray=new f,this.segments=new cr,this.programConfigurations=new wu(o.layers,o.zoom),this.stateDependentLayerIds=this.layers.filter(function(s){return s.isStateDependent()}).map(function(s){return s.id})};function Ff(o,s){for(var l=0;l1){if(jh(o,s))return!0;for(var g=0;g1?l:l.sub(s)._mult(M)._add(s))}function nd(o,s){for(var l,g,M,j=!1,J=0;Js.y!=(M=l[ze]).y>s.y&&s.x<(M.x-g.x)*(s.y-g.y)/(M.y-g.y)+g.x&&(j=!j);return j}function id(o,s){for(var l=!1,g=0,M=o.length-1;gs.y!=J.y>s.y&&s.x<(J.x-j.x)*(s.y-j.y)/(J.y-j.y)+j.x&&(l=!l)}return l}function Hp(o,s,l){var g=l[0],M=l[2];if(o.xM.x&&s.x>M.x||o.yM.y&&s.y>M.y)return!1;var j=pt(o,s,l[0]);return j!==pt(o,s,l[1])||j!==pt(o,s,l[2])||j!==pt(o,s,l[3])}function mc(o,s,l){var g=s.paint.get(o).value;return g.kind==="constant"?g.value:l.programConfigurations.get(s.id).getMaxValue(o)}function Cd(o){return Math.sqrt(o[0]*o[0]+o[1]*o[1])}function od(o,s,l,g,M){if(!s[0]&&!s[1])return o;var j=se.convert(s)._mult(M);l==="viewport"&&j._rotate(-g);for(var J=[],ve=0;ve=8192||Dt<0||Dt>=8192)){var $t=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray,o.sortKey),lr=$t.vertexLength;nh(this.layoutVertexArray,lt,Dt,-1,-1),nh(this.layoutVertexArray,lt,Dt,1,-1),nh(this.layoutVertexArray,lt,Dt,1,1),nh(this.layoutVertexArray,lt,Dt,-1,1),this.indexArray.emplaceBack(lr,lr+1,lr+2),this.indexArray.emplaceBack(lr,lr+3,lr+2),$t.vertexLength+=4,$t.primitiveLength+=2}}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,o,l,{},g)},xa("CircleBucket",Rh,{omit:["layers"]});var lf=new pc({"circle-sort-key":new ea(Gt.layout_circle["circle-sort-key"])}),Dp={paint:new pc({"circle-radius":new ea(Gt.paint_circle["circle-radius"]),"circle-color":new ea(Gt.paint_circle["circle-color"]),"circle-blur":new ea(Gt.paint_circle["circle-blur"]),"circle-opacity":new ea(Gt.paint_circle["circle-opacity"]),"circle-translate":new Ka(Gt.paint_circle["circle-translate"]),"circle-translate-anchor":new Ka(Gt.paint_circle["circle-translate-anchor"]),"circle-pitch-scale":new Ka(Gt.paint_circle["circle-pitch-scale"]),"circle-pitch-alignment":new Ka(Gt.paint_circle["circle-pitch-alignment"]),"circle-stroke-width":new ea(Gt.paint_circle["circle-stroke-width"]),"circle-stroke-color":new ea(Gt.paint_circle["circle-stroke-color"]),"circle-stroke-opacity":new ea(Gt.paint_circle["circle-stroke-opacity"])}),layout:lf},Tc=typeof Float32Array!="undefined"?Float32Array:Array;function Vf(o){return o[0]=1,o[1]=0,o[2]=0,o[3]=0,o[4]=0,o[5]=1,o[6]=0,o[7]=0,o[8]=0,o[9]=0,o[10]=1,o[11]=0,o[12]=0,o[13]=0,o[14]=0,o[15]=1,o}function Zh(o,s,l){var g=s[0],M=s[1],j=s[2],J=s[3],ve=s[4],ze=s[5],lt=s[6],Dt=s[7],$t=s[8],lr=s[9],wr=s[10],Vr=s[11],$r=s[12],Xr=s[13],Gr=s[14],Br=s[15],Tn=l[0],Hn=l[1],yi=l[2],vo=l[3];return o[0]=Tn*g+Hn*ve+yi*$t+vo*$r,o[1]=Tn*M+Hn*ze+yi*lr+vo*Xr,o[2]=Tn*j+Hn*lt+yi*wr+vo*Gr,o[3]=Tn*J+Hn*Dt+yi*Vr+vo*Br,o[4]=(Tn=l[4])*g+(Hn=l[5])*ve+(yi=l[6])*$t+(vo=l[7])*$r,o[5]=Tn*M+Hn*ze+yi*lr+vo*Xr,o[6]=Tn*j+Hn*lt+yi*wr+vo*Gr,o[7]=Tn*J+Hn*Dt+yi*Vr+vo*Br,o[8]=(Tn=l[8])*g+(Hn=l[9])*ve+(yi=l[10])*$t+(vo=l[11])*$r,o[9]=Tn*M+Hn*ze+yi*lr+vo*Xr,o[10]=Tn*j+Hn*lt+yi*wr+vo*Gr,o[11]=Tn*J+Hn*Dt+yi*Vr+vo*Br,o[12]=(Tn=l[12])*g+(Hn=l[13])*ve+(yi=l[14])*$t+(vo=l[15])*$r,o[13]=Tn*M+Hn*ze+yi*lr+vo*Xr,o[14]=Tn*j+Hn*lt+yi*wr+vo*Gr,o[15]=Tn*J+Hn*Dt+yi*Vr+vo*Br,o}Math.hypot||(Math.hypot=function(){for(var o=arguments,s=0,l=arguments.length;l--;)s+=o[l]*o[l];return Math.sqrt(s)});var dd,Jh=Zh;function g0(o,s,l){var g=s[0],M=s[1],j=s[2],J=s[3];return o[0]=l[0]*g+l[4]*M+l[8]*j+l[12]*J,o[1]=l[1]*g+l[5]*M+l[9]*j+l[13]*J,o[2]=l[2]*g+l[6]*M+l[10]*j+l[14]*J,o[3]=l[3]*g+l[7]*M+l[11]*j+l[15]*J,o}dd=new Tc(3),Tc!=Float32Array&&(dd[0]=0,dd[1]=0,dd[2]=0),function(){var o=new Tc(4);Tc!=Float32Array&&(o[0]=0,o[1]=0,o[2]=0,o[3]=0)}();var b0=(function(){var o=new Tc(2);Tc!=Float32Array&&(o[0]=0,o[1]=0)}(),function(o){function s(l){o.call(this,l,Dp)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype.createBucket=function(l){return new Rh(l)},s.prototype.queryRadius=function(l){var g=l;return mc("circle-radius",this,g)+mc("circle-stroke-width",this,g)+Cd(this.paint.get("circle-translate"))},s.prototype.queryIntersectsFeature=function(l,g,M,j,J,ve,ze,lt){for(var Dt=od(l,this.paint.get("circle-translate"),this.paint.get("circle-translate-anchor"),ve.angle,ze),$t=this.paint.get("circle-radius").evaluate(g,M)+this.paint.get("circle-stroke-width").evaluate(g,M),lr=this.paint.get("circle-pitch-alignment")==="map",wr=lr?Dt:function(Eo,Xo){return Eo.map(function(ys){return Gp(ys,Xo)})}(Dt,lt),Vr=lr?$t*ze:$t,$r=0,Xr=j;$ro.width||M.height>o.height||l.x>o.width-M.width||l.y>o.height-M.height)throw new RangeError("out of range source coordinates for image copy");if(M.width>s.width||M.height>s.height||g.x>s.width-M.width||g.y>s.height-M.height)throw new RangeError("out of range destination coordinates for image copy");for(var J=o.data,ve=s.data,ze=0;ze80*l){g=j=o[0],M=J=o[1];for(var Vr=l;Vr<$t;Vr+=l)(ve=o[Vr])j&&(j=ve),ze>J&&(J=ze);lt=(lt=Math.max(j-g,J-M))!==0?1/lt:0}return P0(lr,wr,l,g,M,lt),wr}function j0(o,s,l,g,M){var j,J;if(M===pp(o,s,l,g)>0)for(j=s;j=s;j-=g)J=Mp(j,o[j],o[j+1],J);return J&&ip(J,J.next)&&(wp(J),J=J.next),J}function Fp(o,s){if(!o)return o;s||(s=o);var l,g=o;do if(l=!1,g.steiner||!ip(g,g.next)&&gd(g.prev,g,g.next)!==0)g=g.next;else{if(wp(g),(g=s=g.prev)===g.next)break;l=!0}while(l||g!==s);return s}function P0(o,s,l,g,M,j,J){if(o){!J&&j&&function(Dt,$t,lr,wr){var Vr=Dt;do Vr.z===null&&(Vr.z=ad(Vr.x,Vr.y,$t,lr,wr)),Vr.prevZ=Vr.prev,Vr.nextZ=Vr.next,Vr=Vr.next;while(Vr!==Dt);Vr.prevZ.nextZ=null,Vr.prevZ=null,function($r){var Xr,Gr,Br,Tn,Hn,yi,vo,Eo,Xo=1;do{for(Gr=$r,$r=null,Hn=null,yi=0;Gr;){for(yi++,Br=Gr,vo=0,Xr=0;Xr0||Eo>0&&Br;)vo!==0&&(Eo===0||!Br||Gr.z<=Br.z)?(Tn=Gr,Gr=Gr.nextZ,vo--):(Tn=Br,Br=Br.nextZ,Eo--),Hn?Hn.nextZ=Tn:$r=Tn,Tn.prevZ=Hn,Hn=Tn;Gr=Br}Hn.nextZ=null,Xo*=2}while(yi>1)}(Vr)}(o,g,M,j);for(var ve,ze,lt=o;o.prev!==o.next;)if(ve=o.prev,ze=o.next,j?V0(o,g,M,j):I0(o))s.push(ve.i/l),s.push(o.i/l),s.push(ze.i/l),wp(o),o=ze.next,lt=ze.next;else if((o=ze)===lt){J?J===1?P0(o=d0(Fp(o),s,l),s,l,g,M,j,2):J===2&&Q0(o,s,l,g,M,j):P0(Fp(o),s,l,g,M,j,1);break}}}function I0(o){var s=o.prev,l=o,g=o.next;if(gd(s,l,g)>=0)return!1;for(var M=o.next.next;M!==o.prev;){if(E0(s.x,s.y,l.x,l.y,g.x,g.y,M.x,M.y)&&gd(M.prev,M,M.next)>=0)return!1;M=M.next}return!0}function V0(o,s,l,g){var M=o.prev,j=o,J=o.next;if(gd(M,j,J)>=0)return!1;for(var ve=M.x>j.x?M.x>J.x?M.x:J.x:j.x>J.x?j.x:J.x,ze=M.y>j.y?M.y>J.y?M.y:J.y:j.y>J.y?j.y:J.y,lt=ad(M.x=lt&&lr&&lr.z<=Dt;){if($t!==o.prev&&$t!==o.next&&E0(M.x,M.y,j.x,j.y,J.x,J.y,$t.x,$t.y)&&gd($t.prev,$t,$t.next)>=0||($t=$t.prevZ,lr!==o.prev&&lr!==o.next&&E0(M.x,M.y,j.x,j.y,J.x,J.y,lr.x,lr.y)&&gd(lr.prev,lr,lr.next)>=0))return!1;lr=lr.nextZ}for(;$t&&$t.z>=lt;){if($t!==o.prev&&$t!==o.next&&E0(M.x,M.y,j.x,j.y,J.x,J.y,$t.x,$t.y)&&gd($t.prev,$t,$t.next)>=0)return!1;$t=$t.prevZ}for(;lr&&lr.z<=Dt;){if(lr!==o.prev&&lr!==o.next&&E0(M.x,M.y,j.x,j.y,J.x,J.y,lr.x,lr.y)&&gd(lr.prev,lr,lr.next)>=0)return!1;lr=lr.nextZ}return!0}function d0(o,s,l){var g=o;do{var M=g.prev,j=g.next.next;!ip(M,j)&&O0(M,g,g.next,j)&&pd(M,j)&&pd(j,M)&&(s.push(M.i/l),s.push(g.i/l),s.push(j.i/l),wp(g),wp(g.next),g=o=j),g=g.next}while(g!==o);return Fp(g)}function Q0(o,s,l,g,M,j){var J=o;do{for(var ve=J.next.next;ve!==J.prev;){if(J.i!==ve.i&&S0(J,ve)){var ze=Kp(J,ve);return J=Fp(J,J.next),ze=Fp(ze,ze.next),P0(J,s,l,g,M,j),void P0(ze,s,l,g,M,j)}ve=ve.next}J=J.next}while(J!==o)}function Mc(o,s){return o.x-s.x}function R0(o,s){if(s=function(g,M){var j,J=M,ve=g.x,ze=g.y,lt=-1/0;do{if(ze<=J.y&&ze>=J.next.y&&J.next.y!==J.y){var Dt=J.x+(ze-J.y)*(J.next.x-J.x)/(J.next.y-J.y);if(Dt<=ve&&Dt>lt){if(lt=Dt,Dt===ve){if(ze===J.y)return J;if(ze===J.next.y)return J.next}j=J.x=J.x&&J.x>=wr&&ve!==J.x&&E0(zej.x||J.x===j.x&&w0(j,J)))&&(j=J,$r=$t)),J=J.next;while(J!==lr);return j}(o,s)){var l=Kp(s,o);Fp(s,s.next),Fp(l,l.next)}}function w0(o,s){return gd(o.prev,o,s.prev)<0&&gd(s.next,o,o.next)<0}function ad(o,s,l,g,M){return(o=1431655765&((o=858993459&((o=252645135&((o=16711935&((o=32767*(o-l)*M)|o<<8))|o<<4))|o<<2))|o<<1))|(s=1431655765&((s=858993459&((s=252645135&((s=16711935&((s=32767*(s-g)*M)|s<<8))|s<<4))|s<<2))|s<<1))<<1}function Yp(o){var s=o,l=o;do(s.x=0&&(o-J)*(g-ve)-(l-J)*(s-ve)>=0&&(l-J)*(j-ve)-(M-J)*(g-ve)>=0}function S0(o,s){return o.next.i!==s.i&&o.prev.i!==s.i&&!function(l,g){var M=l;do{if(M.i!==l.i&&M.next.i!==l.i&&M.i!==g.i&&M.next.i!==g.i&&O0(M,M.next,l,g))return!0;M=M.next}while(M!==l);return!1}(o,s)&&(pd(o,s)&&pd(s,o)&&function(l,g){var M=l,j=!1,J=(l.x+g.x)/2,ve=(l.y+g.y)/2;do M.y>ve!=M.next.y>ve&&M.next.y!==M.y&&J<(M.next.x-M.x)*(ve-M.y)/(M.next.y-M.y)+M.x&&(j=!j),M=M.next;while(M!==l);return j}(o,s)&&(gd(o.prev,o,s.prev)||gd(o,s.prev,s))||ip(o,s)&&gd(o.prev,o,o.next)>0&&gd(s.prev,s,s.next)>0)}function gd(o,s,l){return(s.y-o.y)*(l.x-s.x)-(s.x-o.x)*(l.y-s.y)}function ip(o,s){return o.x===s.x&&o.y===s.y}function O0(o,s,l,g){var M=$0(gd(o,s,l)),j=$0(gd(o,s,g)),J=$0(gd(l,g,o)),ve=$0(gd(l,g,s));return M!==j&&J!==ve||!(M!==0||!Bp(o,l,s))||!(j!==0||!Bp(o,g,s))||!(J!==0||!Bp(l,o,g))||!(ve!==0||!Bp(l,s,g))}function Bp(o,s,l){return s.x<=Math.max(o.x,l.x)&&s.x>=Math.min(o.x,l.x)&&s.y<=Math.max(o.y,l.y)&&s.y>=Math.min(o.y,l.y)}function $0(o){return o>0?1:o<0?-1:0}function pd(o,s){return gd(o.prev,o,o.next)<0?gd(o,s,o.next)>=0&&gd(o,o.prev,s)>=0:gd(o,s,o.prev)<0||gd(o,o.next,s)<0}function Kp(o,s){var l=new op(o.i,o.x,o.y),g=new op(s.i,s.x,s.y),M=o.next,j=s.prev;return o.next=s,s.prev=o,l.next=M,M.prev=l,g.next=l,l.prev=g,j.next=g,g.prev=j,g}function Mp(o,s,l,g){var M=new op(o,s,l);return g?(M.next=g.next,M.prev=g,g.next.prev=M,g.next=M):(M.prev=M,M.next=M),M}function wp(o){o.next.prev=o.prev,o.prev.next=o.next,o.prevZ&&(o.prevZ.nextZ=o.nextZ),o.nextZ&&(o.nextZ.prevZ=o.prevZ)}function op(o,s,l){this.i=o,this.x=s,this.y=l,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function pp(o,s,l,g){for(var M=0,j=s,J=l-g;jze;){if(lt-ze>600){var $t=lt-ze+1,lr=ve-ze+1,wr=Math.log($t),Vr=.5*Math.exp(2*wr/3),$r=.5*Math.sqrt(wr*Vr*($t-Vr)/$t)*(lr-$t/2<0?-1:1);j(J,ve,Math.max(ze,Math.floor(ve-lr*Vr/$t+$r)),Math.min(lt,Math.floor(ve+($t-lr)*Vr/$t+$r)),Dt)}var Xr=J[ve],Gr=ze,Br=lt;for(gh(J,ze,ve),Dt(J[lt],Xr)>0&&gh(J,ze,lt);Gr0;)Br--}Dt(J[ze],Xr)===0?gh(J,ze,Br):gh(J,++Br,lt),Br<=ve&&(ze=Br+1),ve<=Br&&(lt=Br-1)}})(o,s,l||0,g||o.length-1,M||y0)}function gh(o,s,l){var g=o[s];o[s]=o[l],o[l]=g}function y0(o,s){return os?1:0}function n0(o,s){var l=o.length;if(l<=1)return[o];for(var g,M,j=[],J=0;J1)for(var ze=0;ze0&&l.holes.push(g+=o[M-1].length)}return l},Tp.default=mm;var zp=function(o){this.zoom=o.zoom,this.overscaling=o.overscaling,this.layers=o.layers,this.layerIds=this.layers.map(function(s){return s.id}),this.index=o.index,this.hasPattern=!1,this.patternFeatures=[],this.layoutVertexArray=new uf,this.indexArray=new f,this.indexArray2=new nt,this.programConfigurations=new wu(o.layers,o.zoom),this.segments=new cr,this.segments2=new cr,this.stateDependentLayerIds=this.layers.filter(function(s){return s.isStateDependent()}).map(function(s){return s.id})};zp.prototype.populate=function(o,s,l){this.hasPattern=L0("fill",this.layers,s);for(var g=this.layers[0].layout.get("fill-sort-key"),M=[],j=0,J=o;j>3}if(M--,g===1||g===2)j+=o.readSVarint(),J+=o.readSVarint(),g===1&&(s&&ve.push(s),s=[]),s.push(new se(j,J));else{if(g!==7)throw new Error("unknown command "+g);s&&s.push(s[0].clone())}}return s&&ve.push(s),ve},Zp.prototype.bbox=function(){var o=this._pbf;o.pos=this._geometry;for(var s=o.readVarint()+o.pos,l=1,g=0,M=0,j=0,J=1/0,ve=-1/0,ze=1/0,lt=-1/0;o.pos>3}if(g--,l===1||l===2)(M+=o.readSVarint())ve&&(ve=M),(j+=o.readSVarint())lt&&(lt=j);else if(l!==7)throw new Error("unknown command "+l)}return[J,ze,ve,lt]},Zp.prototype.toGeoJSON=function(o,s,l){var g,M,j=this.extent*Math.pow(2,l),J=this.extent*o,ve=this.extent*s,ze=this.loadGeometry(),lt=Zp.types[this.type];function Dt(wr){for(var Vr=0;Vr>3;M=J===1?g.readString():J===2?g.readFloat():J===3?g.readDouble():J===4?g.readVarint64():J===5?g.readVarint():J===6?g.readSVarint():J===7?g.readBoolean():null}return M}(l))}function i0(o,s,l){if(o===3){var g=new qp(l,l.readVarint()+l.pos);g.length&&(s[g.name]=g)}}Ip.prototype.feature=function(o){if(o<0||o>=this._features.length)throw new Error("feature index out of bounds");this._pbf.pos=this._features[o];var s=this._pbf.readVarint()+this._pbf.pos;return new ap(this._pbf,s,this.extent,this._keys,this._values)};var f0={VectorTile:function(o,s){this.layers=o.readFields(i0,{},s)},VectorTileFeature:ap,VectorTileLayer:qp},sm=f0.VectorTileFeature.types,p0=Math.pow(2,13);function Id(o,s,l,g,M,j,J,ve){o.emplaceBack(s,l,2*Math.floor(g*p0)+J,M*p0*2,j*p0*2,Math.round(ve))}var Rd=function(o){this.zoom=o.zoom,this.overscaling=o.overscaling,this.layers=o.layers,this.layerIds=this.layers.map(function(s){return s.id}),this.index=o.index,this.hasPattern=!1,this.layoutVertexArray=new rh,this.indexArray=new f,this.programConfigurations=new wu(o.layers,o.zoom),this.segments=new cr,this.stateDependentLayerIds=this.layers.filter(function(s){return s.isStateDependent()}).map(function(s){return s.id})};function Fd(o,s){return o.x===s.x&&(o.x<0||o.x>8192)||o.y===s.y&&(o.y<0||o.y>8192)}Rd.prototype.populate=function(o,s,l){this.features=[],this.hasPattern=L0("fill-extrusion",this.layers,s);for(var g=0,M=o;g8192})||Rs.every(function(pu){return pu.y<0})||Rs.every(function(pu){return pu.y>8192})))for(var $r=0,Xr=0;Xr=1){var Br=Vr[Xr-1];if(!Fd(Gr,Br)){$t.vertexLength+4>cr.MAX_VERTEX_ARRAY_LENGTH&&($t=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray));var Tn=Gr.sub(Br)._perp()._unit(),Hn=Br.dist(Gr);$r+Hn>32768&&($r=0),Id(this.layoutVertexArray,Gr.x,Gr.y,Tn.x,Tn.y,0,0,$r),Id(this.layoutVertexArray,Gr.x,Gr.y,Tn.x,Tn.y,0,1,$r),Id(this.layoutVertexArray,Br.x,Br.y,Tn.x,Tn.y,0,0,$r+=Hn),Id(this.layoutVertexArray,Br.x,Br.y,Tn.x,Tn.y,0,1,$r);var yi=$t.vertexLength;this.indexArray.emplaceBack(yi,yi+2,yi+1),this.indexArray.emplaceBack(yi+1,yi+2,yi+3),$t.vertexLength+=4,$t.primitiveLength+=2}}}}if($t.vertexLength+ze>cr.MAX_VERTEX_ARRAY_LENGTH&&($t=this.segments.prepareSegment(ze,this.layoutVertexArray,this.indexArray)),sm[o.type]==="Polygon"){for(var vo=[],Eo=[],Xo=$t.vertexLength,ys=0,Yo=ve;ys=2&&o[ze-1].equals(o[ze-2]);)ze--;for(var lt=0;lt0;if(Eo&&Gr>lt){var ys=Dt.dist(wr);if(ys>2*$t){var Yo=Dt.sub(Dt.sub(wr)._mult($t/ys)._round());this.updateDistance(wr,Yo),this.addCurrentVertex(Yo,$r,0,0,lr),wr=Yo}}var es=wr&&Vr,qa=es?l:ve?"butt":g;if(es&&qa==="round"&&(yiM&&(qa="bevel"),qa==="bevel"&&(yi>2&&(qa="flipbevel"),yi100)Br=Xr.mult(-1);else{var Ts=yi*$r.add(Xr).mag()/$r.sub(Xr).mag();Br._perp()._mult(Ts*(Xo?-1:1))}this.addCurrentVertex(Dt,Br,0,0,lr),this.addCurrentVertex(Dt,Br.mult(-1),0,0,lr)}else if(qa==="bevel"||qa==="fakeround"){var is=-Math.sqrt(yi*yi-1),ts=Xo?is:0,Rs=Xo?0:is;if(wr&&this.addCurrentVertex(Dt,$r,ts,Rs,lr),qa==="fakeround")for(var pu=Math.round(180*vo/Math.PI/20),nl=1;nl2*$t){var oc=Dt.add(Vr.sub(Dt)._mult($t/Vl)._round());this.updateDistance(Dt,oc),this.addCurrentVertex(oc,Xr,0,0,lr),Dt=oc}}}}},Vh.prototype.addCurrentVertex=function(o,s,l,g,M,j){j===void 0&&(j=!1);var J=s.y*g-s.x,ve=-s.y-s.x*g;this.addHalfVertex(o,s.x+s.y*l,s.y-s.x*l,j,!1,l,M),this.addHalfVertex(o,J,ve,j,!0,-g,M),this.distance>um/2&&this.totalDistance===0&&(this.distance=0,this.addCurrentVertex(o,s,l,g,M,j))},Vh.prototype.addHalfVertex=function(o,s,l,g,M,j,J){var ve=.5*(this.lineClips?this.scaledDistance*(um-1):this.scaledDistance);this.layoutVertexArray.emplaceBack((o.x<<1)+(g?1:0),(o.y<<1)+(M?1:0),Math.round(63*s)+128,Math.round(63*l)+128,1+(j===0?0:j<0?-1:1)|(63&ve)<<2,ve>>6),this.lineClips&&this.layoutVertexArray2.emplaceBack((this.scaledDistance-this.lineClips.start)/(this.lineClips.end-this.lineClips.start),this.lineClipsArray.length);var ze=J.vertexLength++;this.e1>=0&&this.e2>=0&&(this.indexArray.emplaceBack(this.e1,this.e2,ze),J.primitiveLength++),M?this.e2=ze:this.e1=ze},Vh.prototype.updateScaledDistance=function(){this.scaledDistance=this.lineClips?this.lineClips.start+(this.lineClips.end-this.lineClips.start)*this.distance/this.totalDistance:this.distance},Vh.prototype.updateDistance=function(o,s){this.distance+=o.dist(s),this.updateScaledDistance()},xa("LineBucket",Vh,{omit:["layers","patternFeatures"]});var B0=new pc({"line-cap":new Ka(Gt.layout_line["line-cap"]),"line-join":new ea(Gt.layout_line["line-join"]),"line-miter-limit":new Ka(Gt.layout_line["line-miter-limit"]),"line-round-limit":new Ka(Gt.layout_line["line-round-limit"]),"line-sort-key":new ea(Gt.layout_line["line-sort-key"])}),mp={paint:new pc({"line-opacity":new ea(Gt.paint_line["line-opacity"]),"line-color":new ea(Gt.paint_line["line-color"]),"line-translate":new Ka(Gt.paint_line["line-translate"]),"line-translate-anchor":new Ka(Gt.paint_line["line-translate-anchor"]),"line-width":new ea(Gt.paint_line["line-width"]),"line-gap-width":new ea(Gt.paint_line["line-gap-width"]),"line-offset":new ea(Gt.paint_line["line-offset"]),"line-blur":new ea(Gt.paint_line["line-blur"]),"line-dasharray":new tu(Gt.paint_line["line-dasharray"]),"line-pattern":new qo(Gt.paint_line["line-pattern"]),"line-gradient":new bh(Gt.paint_line["line-gradient"])}),layout:B0},J0=new(function(o){function s(){o.apply(this,arguments)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype.possiblyEvaluate=function(l,g){return g=new Ls(Math.floor(g.zoom),{now:g.now,fadeDuration:g.fadeDuration,zoomHistory:g.zoomHistory,transition:g.transition}),o.prototype.possiblyEvaluate.call(this,l,g)},s.prototype.evaluate=function(l,g,M,j){return g=Ge({},g,{zoom:Math.floor(g.zoom)}),o.prototype.evaluate.call(this,l,g,M,j)},s}(ea))(mp.paint.properties["line-width"].specification);J0.useIntegerZoom=!0;var G0=function(o){function s(l){o.call(this,l,mp),this.gradientVersion=0}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype._handleSpecialPaintPropertyUpdate=function(l){l==="line-gradient"&&(this.stepInterpolant=this._transitionablePaint._values["line-gradient"].value.expression._styleExpression.expression instanceof gs,this.gradientVersion=(this.gradientVersion+1)%le)},s.prototype.gradientExpression=function(){return this._transitionablePaint._values["line-gradient"].value.expression},s.prototype.recalculate=function(l,g){o.prototype.recalculate.call(this,l,g),this.paint._values["line-floorwidth"]=J0.possiblyEvaluate(this._transitioningPaint._values["line-width"].value,l)},s.prototype.createBucket=function(l){return new Vh(l)},s.prototype.queryRadius=function(l){var g=l,M=W0(mc("line-width",this,g),mc("line-gap-width",this,g)),j=mc("line-offset",this,g);return M/2+Math.abs(j)+Cd(this.paint.get("line-translate"))},s.prototype.queryIntersectsFeature=function(l,g,M,j,J,ve,ze){var lt=od(l,this.paint.get("line-translate"),this.paint.get("line-translate-anchor"),ve.angle,ze),Dt=ze/2*W0(this.paint.get("line-width").evaluate(g,M),this.paint.get("line-gap-width").evaluate(g,M)),$t=this.paint.get("line-offset").evaluate(g,M);return $t&&(j=function(lr,wr){for(var Vr=[],$r=new se(0,0),Xr=0;Xr=3){for(var Gr=0;Gr0?s+2*o:o}var Td=Xf([{name:"a_pos_offset",components:4,type:"Int16"},{name:"a_data",components:4,type:"Uint16"},{name:"a_pixeloffset",components:4,type:"Int16"}],4),o0=Xf([{name:"a_projected_pos",components:3,type:"Float32"}],4),m0=(Xf([{name:"a_fade_opacity",components:1,type:"Uint32"}],4),Xf([{name:"a_placed",components:2,type:"Uint8"},{name:"a_shift",components:2,type:"Float32"}])),Vd=(Xf([{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"}]),Xf([{name:"a_pos",components:2,type:"Int16"},{name:"a_anchor_pos",components:2,type:"Int16"},{name:"a_extrude",components:2,type:"Int16"}],4)),_r=Xf([{name:"a_pos",components:2,type:"Float32"},{name:"a_radius",components:1,type:"Float32"},{name:"a_flags",components:2,type:"Int16"}],4);function Sn(o,s,l){return o.sections.forEach(function(g){g.text=function(M,j,J){var ve=j.layout.get("text-transform").evaluate(J,{});return ve==="uppercase"?M=M.toLocaleUpperCase():ve==="lowercase"&&(M=M.toLocaleLowerCase()),ic.applyArabicShaping&&(M=ic.applyArabicShaping(M)),M}(g.text,s,l)}),o}Xf([{name:"triangle",components:3,type:"Uint16"}]),Xf([{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"}]),Xf([{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",components:2,name:"textOffset"},{type:"Float32",name:"collisionCircleDiameter"}]),Xf([{type:"Float32",name:"offsetX"}]),Xf([{type:"Int16",name:"x"},{type:"Int16",name:"y"},{type:"Int16",name:"tileUnitDistanceFromAnchor"}]);var mi={"!":"\uFE15","#":"\uFF03",$:"\uFF04","%":"\uFF05","&":"\uFF06","(":"\uFE35",")":"\uFE36","*":"\uFF0A","+":"\uFF0B",",":"\uFE10","-":"\uFE32",".":"\u30FB","/":"\uFF0F",":":"\uFE13",";":"\uFE14","<":"\uFE3F","=":"\uFF1D",">":"\uFE40","?":"\uFE16","@":"\uFF20","[":"\uFE47","\\":"\uFF3C","]":"\uFE48","^":"\uFF3E",_:"\uFE33","`":"\uFF40","{":"\uFE37","|":"\u2015","}":"\uFE38","~":"\uFF5E","\xA2":"\uFFE0","\xA3":"\uFFE1","\xA5":"\uFFE5","\xA6":"\uFFE4","\xAC":"\uFFE2","\xAF":"\uFFE3","\u2013":"\uFE32","\u2014":"\uFE31","\u2018":"\uFE43","\u2019":"\uFE44","\u201C":"\uFE41","\u201D":"\uFE42","\u2026":"\uFE19","\u2027":"\u30FB","\u20A9":"\uFFE6","\u3001":"\uFE11","\u3002":"\uFE12","\u3008":"\uFE3F","\u3009":"\uFE40","\u300A":"\uFE3D","\u300B":"\uFE3E","\u300C":"\uFE41","\u300D":"\uFE42","\u300E":"\uFE43","\u300F":"\uFE44","\u3010":"\uFE3B","\u3011":"\uFE3C","\u3014":"\uFE39","\u3015":"\uFE3A","\u3016":"\uFE17","\u3017":"\uFE18","\uFF01":"\uFE15","\uFF08":"\uFE35","\uFF09":"\uFE36","\uFF0C":"\uFE10","\uFF0D":"\uFE32","\uFF0E":"\u30FB","\uFF1A":"\uFE13","\uFF1B":"\uFE14","\uFF1C":"\uFE3F","\uFF1E":"\uFE40","\uFF1F":"\uFE16","\uFF3B":"\uFE47","\uFF3D":"\uFE48","\uFF3F":"\uFE33","\uFF5B":"\uFE37","\uFF5C":"\u2015","\uFF5D":"\uFE38","\uFF5F":"\uFE35","\uFF60":"\uFE36","\uFF61":"\uFE12","\uFF62":"\uFE41","\uFF63":"\uFE42"},jo=function(o,s,l,g,M){var j,J,ve=8*M-g-1,ze=(1<>1,Dt=-7,$t=l?M-1:0,lr=l?-1:1,wr=o[s+$t];for($t+=lr,j=wr&(1<<-Dt)-1,wr>>=-Dt,Dt+=ve;Dt>0;j=256*j+o[s+$t],$t+=lr,Dt-=8);for(J=j&(1<<-Dt)-1,j>>=-Dt,Dt+=g;Dt>0;J=256*J+o[s+$t],$t+=lr,Dt-=8);if(j===0)j=1-lt;else{if(j===ze)return J?NaN:1/0*(wr?-1:1);J+=Math.pow(2,g),j-=lt}return(wr?-1:1)*J*Math.pow(2,j-g)},Ta=function(o,s,l,g,M,j){var J,ve,ze,lt=8*j-M-1,Dt=(1<>1,lr=M===23?Math.pow(2,-24)-Math.pow(2,-77):0,wr=g?0:j-1,Vr=g?1:-1,$r=s<0||s===0&&1/s<0?1:0;for(s=Math.abs(s),isNaN(s)||s===1/0?(ve=isNaN(s)?1:0,J=Dt):(J=Math.floor(Math.log(s)/Math.LN2),s*(ze=Math.pow(2,-J))<1&&(J--,ze*=2),(s+=J+$t>=1?lr/ze:lr*Math.pow(2,1-$t))*ze>=2&&(J++,ze/=2),J+$t>=Dt?(ve=0,J=Dt):J+$t>=1?(ve=(s*ze-1)*Math.pow(2,M),J+=$t):(ve=s*Math.pow(2,$t-1)*Math.pow(2,M),J=0));M>=8;o[l+wr]=255&ve,wr+=Vr,ve/=256,M-=8);for(J=J<0;o[l+wr]=255&J,wr+=Vr,J/=256,lt-=8);o[l+wr-Vr]|=128*$r},$o=Po;function Po(o){this.buf=ArrayBuffer.isView&&ArrayBuffer.isView(o)?o:new Uint8Array(o||0),this.pos=0,this.type=0,this.length=this.buf.length}Po.Varint=0,Po.Fixed64=1,Po.Bytes=2,Po.Fixed32=5;var ds=typeof TextDecoder=="undefined"?null:new TextDecoder("utf8");function Ja(o){return o.type===Po.Bytes?o.readVarint()+o.pos:o.pos+1}function au(o,s,l){return l?4294967296*s+(o>>>0):4294967296*(s>>>0)+(o>>>0)}function Ds(o,s,l){var g=s<=16383?1:s<=2097151?2:s<=268435455?3:Math.floor(Math.log(s)/(7*Math.LN2));l.realloc(g);for(var M=l.pos-1;M>=o;M--)l.buf[M+g]=l.buf[M]}function Bs(o,s){for(var l=0;l>>8,o[l+2]=s>>>16,o[l+3]=s>>>24}function Ou(o,s){return(o[s]|o[s+1]<<8|o[s+2]<<16)+(o[s+3]<<24)}function Ba(o,s,l){o===1&&l.readMessage(Lu,s)}function Lu(o,s,l){if(o===3){var g=l.readMessage(uc,{}),M=g.width,j=g.height,J=g.left,ve=g.top,ze=g.advance;s.push({id:g.id,bitmap:new t0({width:M+6,height:j+6},g.bitmap),metrics:{width:M,height:j,left:J,top:ve,advance:ze}})}}function uc(o,s,l){o===1?s.id=l.readVarint():o===2?s.bitmap=l.readBytes():o===3?s.width=l.readVarint():o===4?s.height=l.readVarint():o===5?s.left=l.readSVarint():o===6?s.top=l.readSVarint():o===7&&(s.advance=l.readVarint())}function Pc(o){for(var s=0,l=0,g=0,M=o;g=0;lr--){var wr=J[lr];if(!($t.w>wr.w||$t.h>wr.h)){if($t.x=wr.x,$t.y=wr.y,ze=Math.max(ze,$t.y+$t.h),ve=Math.max(ve,$t.x+$t.w),$t.w===wr.w&&$t.h===wr.h){var Vr=J.pop();lr>3,j=this.pos;this.type=7&g,o(M,s,this),this.pos===j&&this.skip(g)}return s},readMessage:function(o,s){return this.readFields(o,s,this.readVarint()+this.pos)},readFixed32:function(){var o=qu(this.buf,this.pos);return this.pos+=4,o},readSFixed32:function(){var o=Ou(this.buf,this.pos);return this.pos+=4,o},readFixed64:function(){var o=qu(this.buf,this.pos)+4294967296*qu(this.buf,this.pos+4);return this.pos+=8,o},readSFixed64:function(){var o=qu(this.buf,this.pos)+4294967296*Ou(this.buf,this.pos+4);return this.pos+=8,o},readFloat:function(){var o=jo(this.buf,this.pos,!0,23,4);return this.pos+=4,o},readDouble:function(){var o=jo(this.buf,this.pos,!0,52,8);return this.pos+=8,o},readVarint:function(o){var s,l,g=this.buf;return s=127&(l=g[this.pos++]),l<128?s:(s|=(127&(l=g[this.pos++]))<<7,l<128?s:(s|=(127&(l=g[this.pos++]))<<14,l<128?s:(s|=(127&(l=g[this.pos++]))<<21,l<128?s:function(M,j,J){var ve,ze,lt=J.buf;if(ve=(112&(ze=lt[J.pos++]))>>4,ze<128||(ve|=(127&(ze=lt[J.pos++]))<<3,ze<128)||(ve|=(127&(ze=lt[J.pos++]))<<10,ze<128)||(ve|=(127&(ze=lt[J.pos++]))<<17,ze<128)||(ve|=(127&(ze=lt[J.pos++]))<<24,ze<128)||(ve|=(1&(ze=lt[J.pos++]))<<31,ze<128))return au(M,ve,j);throw new Error("Expected varint not more than 10 bytes")}(s|=(15&(l=g[this.pos]))<<28,o,this))))},readVarint64:function(){return this.readVarint(!0)},readSVarint:function(){var o=this.readVarint();return o%2==1?(o+1)/-2:o/2},readBoolean:function(){return!!this.readVarint()},readString:function(){var o=this.readVarint()+this.pos,s=this.pos;return this.pos=o,o-s>=12&&ds?function(l,g,M){return ds.decode(l.subarray(g,M))}(this.buf,s,o):function(l,g,M){for(var j="",J=g;J239?4:Dt>223?3:Dt>191?2:1;if(J+lr>M)break;lr===1?Dt<128&&($t=Dt):lr===2?(192&(ve=l[J+1]))==128&&($t=(31&Dt)<<6|63&ve)<=127&&($t=null):lr===3?(ze=l[J+2],(192&(ve=l[J+1]))==128&&(192&ze)==128&&(($t=(15&Dt)<<12|(63&ve)<<6|63&ze)<=2047||$t>=55296&&$t<=57343)&&($t=null)):lr===4&&(ze=l[J+2],lt=l[J+3],(192&(ve=l[J+1]))==128&&(192&ze)==128&&(192<)==128&&(($t=(15&Dt)<<18|(63&ve)<<12|(63&ze)<<6|63<)<=65535||$t>=1114112)&&($t=null)),$t===null?($t=65533,lr=1):$t>65535&&($t-=65536,j+=String.fromCharCode($t>>>10&1023|55296),$t=56320|1023&$t),j+=String.fromCharCode($t),J+=lr}return j}(this.buf,s,o)},readBytes:function(){var o=this.readVarint()+this.pos,s=this.buf.subarray(this.pos,o);return this.pos=o,s},readPackedVarint:function(o,s){if(this.type!==Po.Bytes)return o.push(this.readVarint(s));var l=Ja(this);for(o=o||[];this.pos127;);else if(s===Po.Bytes)this.pos=this.readVarint()+this.pos;else if(s===Po.Fixed32)this.pos+=4;else{if(s!==Po.Fixed64)throw new Error("Unimplemented type: "+s);this.pos+=8}},writeTag:function(o,s){this.writeVarint(o<<3|s)},realloc:function(o){for(var s=this.length||16;s268435455||o<0?function(s,l){var g,M;if(s>=0?(g=s%4294967296|0,M=s/4294967296|0):(M=~(-s/4294967296),4294967295^(g=~(-s%4294967296))?g=g+1|0:(g=0,M=M+1|0)),s>=18446744073709552e3||s<-18446744073709552e3)throw new Error("Given varint doesn't fit into 10 bytes");l.realloc(10),function(j,J,ve){ve.buf[ve.pos++]=127&j|128,j>>>=7,ve.buf[ve.pos++]=127&j|128,j>>>=7,ve.buf[ve.pos++]=127&j|128,j>>>=7,ve.buf[ve.pos++]=127&j|128,ve.buf[ve.pos]=127&(j>>>=7)}(g,0,l),function(j,J){var ve=(7&j)<<4;J.buf[J.pos++]|=ve|((j>>>=3)?128:0),j&&(J.buf[J.pos++]=127&j|((j>>>=7)?128:0),j&&(J.buf[J.pos++]=127&j|((j>>>=7)?128:0),j&&(J.buf[J.pos++]=127&j|((j>>>=7)?128:0),j&&(J.buf[J.pos++]=127&j|((j>>>=7)?128:0),j&&(J.buf[J.pos++]=127&j)))))}(M,l)}(o,this):(this.realloc(4),this.buf[this.pos++]=127&o|(o>127?128:0),o<=127||(this.buf[this.pos++]=127&(o>>>=7)|(o>127?128:0),o<=127||(this.buf[this.pos++]=127&(o>>>=7)|(o>127?128:0),o<=127||(this.buf[this.pos++]=o>>>7&127))))},writeSVarint:function(o){this.writeVarint(o<0?2*-o-1:2*o)},writeBoolean:function(o){this.writeVarint(!!o)},writeString:function(o){o=String(o),this.realloc(4*o.length),this.pos++;var s=this.pos;this.pos=function(g,M,j){for(var J,ve,ze=0;ze55295&&J<57344){if(!ve){J>56319||ze+1===M.length?(g[j++]=239,g[j++]=191,g[j++]=189):ve=J;continue}if(J<56320){g[j++]=239,g[j++]=191,g[j++]=189,ve=J;continue}J=ve-55296<<10|J-56320|65536,ve=null}else ve&&(g[j++]=239,g[j++]=191,g[j++]=189,ve=null);J<128?g[j++]=J:(J<2048?g[j++]=J>>6|192:(J<65536?g[j++]=J>>12|224:(g[j++]=J>>18|240,g[j++]=J>>12&63|128),g[j++]=J>>6&63|128),g[j++]=63&J|128)}return j}(this.buf,o,this.pos);var l=this.pos-s;l>=128&&Ds(s,l,this),this.pos=s-1,this.writeVarint(l),this.pos+=l},writeFloat:function(o){this.realloc(4),Ta(this.buf,o,this.pos,!0,23,4),this.pos+=4},writeDouble:function(o){this.realloc(8),Ta(this.buf,o,this.pos,!0,52,8),this.pos+=8},writeBytes:function(o){var s=o.length;this.writeVarint(s),this.realloc(s);for(var l=0;l=128&&Ds(l,g,this),this.pos=l-1,this.writeVarint(g),this.pos+=g},writeMessage:function(o,s,l){this.writeTag(o,Po.Bytes),this.writeRawMessage(s,l)},writePackedVarint:function(o,s){s.length&&this.writeMessage(o,Bs,s)},writePackedSVarint:function(o,s){s.length&&this.writeMessage(o,ru,s)},writePackedBoolean:function(o,s){s.length&&this.writeMessage(o,co,s)},writePackedFloat:function(o,s){s.length&&this.writeMessage(o,xs,s)},writePackedDouble:function(o,s){s.length&&this.writeMessage(o,nu,s)},writePackedFixed32:function(o,s){s.length&&this.writeMessage(o,aa,s)},writePackedSFixed32:function(o,s){s.length&&this.writeMessage(o,zs,s)},writePackedFixed64:function(o,s){s.length&&this.writeMessage(o,Ru,s)},writePackedSFixed64:function(o,s){s.length&&this.writeMessage(o,ls,s)},writeBytesField:function(o,s){this.writeTag(o,Po.Bytes),this.writeBytes(s)},writeFixed32Field:function(o,s){this.writeTag(o,Po.Fixed32),this.writeFixed32(s)},writeSFixed32Field:function(o,s){this.writeTag(o,Po.Fixed32),this.writeSFixed32(s)},writeFixed64Field:function(o,s){this.writeTag(o,Po.Fixed64),this.writeFixed64(s)},writeSFixed64Field:function(o,s){this.writeTag(o,Po.Fixed64),this.writeSFixed64(s)},writeVarintField:function(o,s){this.writeTag(o,Po.Varint),this.writeVarint(s)},writeSVarintField:function(o,s){this.writeTag(o,Po.Varint),this.writeSVarint(s)},writeStringField:function(o,s){this.writeTag(o,Po.Bytes),this.writeString(s)},writeFloatField:function(o,s){this.writeTag(o,Po.Fixed32),this.writeFloat(s)},writeDoubleField:function(o,s){this.writeTag(o,Po.Fixed64),this.writeDouble(s)},writeBooleanField:function(o,s){this.writeVarintField(o,!!s)}};var Mu=function(o,s){var l=s.pixelRatio,g=s.version,M=s.stretchX,j=s.stretchY,J=s.content;this.paddedRect=o,this.pixelRatio=l,this.stretchX=M,this.stretchY=j,this.content=J,this.version=g},ws={tl:{configurable:!0},br:{configurable:!0},tlbr:{configurable:!0},displaySize:{configurable:!0}};ws.tl.get=function(){return[this.paddedRect.x+1,this.paddedRect.y+1]},ws.br.get=function(){return[this.paddedRect.x+this.paddedRect.w-1,this.paddedRect.y+this.paddedRect.h-1]},ws.tlbr.get=function(){return this.tl.concat(this.br)},ws.displaySize.get=function(){return[(this.paddedRect.w-2)/this.pixelRatio,(this.paddedRect.h-2)/this.pixelRatio]},Object.defineProperties(Mu.prototype,ws);var La=function(o,s){var l={},g={};this.haveRenderCallbacks=[];var M=[];this.addImages(o,l,M),this.addImages(s,g,M);var j=Pc(M),J=new np({width:j.w||1,height:j.h||1});for(var ve in o){var ze=o[ve],lt=l[ve].paddedRect;np.copy(ze.data,J,{x:0,y:0},{x:lt.x+1,y:lt.y+1},ze.data)}for(var Dt in s){var $t=s[Dt],lr=g[Dt].paddedRect,wr=lr.x+1,Vr=lr.y+1,$r=$t.data.width,Xr=$t.data.height;np.copy($t.data,J,{x:0,y:0},{x:wr,y:Vr},$t.data),np.copy($t.data,J,{x:0,y:Xr-1},{x:wr,y:Vr-1},{width:$r,height:1}),np.copy($t.data,J,{x:0,y:0},{x:wr,y:Vr+Xr},{width:$r,height:1}),np.copy($t.data,J,{x:$r-1,y:0},{x:wr-1,y:Vr},{width:1,height:Xr}),np.copy($t.data,J,{x:0,y:0},{x:wr+$r,y:Vr},{width:1,height:Xr})}this.image=J,this.iconPositions=l,this.patternPositions=g};La.prototype.addImages=function(o,s,l){for(var g in o){var M=o[g],j={x:0,y:0,w:M.data.width+2,h:M.data.height+2};l.push(j),s[g]=new Mu(j,M),M.hasRenderCallback&&this.haveRenderCallbacks.push(g)}},La.prototype.patchUpdatedImages=function(o,s){for(var l in o.dispatchRenderCallbacks(this.haveRenderCallbacks),o.updatedImages)this.patchUpdatedImage(this.iconPositions[l],o.getImage(l),s),this.patchUpdatedImage(this.patternPositions[l],o.getImage(l),s)},La.prototype.patchUpdatedImage=function(o,s,l){if(o&&s&&o.version!==s.version){o.version=s.version;var g=o.tl;l.update(s.data,void 0,{x:g[0],y:g[1]})}},xa("ImagePosition",Mu),xa("ImageAtlas",La);var Ql={horizontal:1,vertical:2,horizontalOnly:3},lc=function(){this.scale=1,this.fontStack="",this.imageName=null};lc.forText=function(o,s){var l=new lc;return l.scale=o||1,l.fontStack=s,l},lc.forImage=function(o){var s=new lc;return s.imageName=o,s};var zu=function(){this.text="",this.sectionIndex=[],this.sections=[],this.imageSectionID=null};function jl(o,s,l,g,M,j,J,ve,ze,lt,Dt,$t,lr,wr,Vr,$r){var Xr,Gr=zu.fromFeature(o,M);$t===Ql.vertical&&Gr.verticalizePunctuation();var Br=ic.processBidirectionalText,Tn=ic.processStyledBidirectionalText;if(Br&&Gr.sections.length===1){Xr=[];for(var Hn=0,yi=Br(Gr.toString(),yd(Gr,lt,j,s,g,wr,Vr));Hn0&&Yt>gc&&(gc=Yt)}else{var br=pu[tc.fontStack],Ir=br&&br[_];if(Ir&&Ir.rect)G=Ir.rect,C=Ir.metrics;else{var Z=Rs[tc.fontStack],z=Z&&Z[_];if(!z)continue;C=z.metrics}d=24*(Zc-tc.scale)}Re?(ts.verticalizable=!0,pa.push({glyph:_,imageName:de,x:ih,y:wh+d,vertical:Re,scale:tc.scale,fontStack:tc.fontStack,sectionIndex:oh,metrics:C,rect:G}),ih+=Te*tc.scale+oc):(pa.push({glyph:_,imageName:de,x:ih,y:wh+d,vertical:Re,scale:tc.scale,fontStack:tc.fontStack,sectionIndex:oh,metrics:C,rect:G}),ih+=C.advance*tc.scale+oc)}pa.length!==0&&(hh=Math.max(ih-oc,hh),Tf(pa,0,pa.length-1,Jf,gc)),ih=0;var Q=Es*Zc+gc;sd.lineOffset=Math.max(gc,Lh),wh+=Q,dh=Math.max(Q,dh),++pf}else wh+=Es,++pf}var Pe,Pt=wh- -17,tr=Ch(sl),Sr=tr.horizontalAlign,Dr=tr.verticalAlign;(function(Kr,Zn,ai,Va,za,ua,Za,rs,os){var Ua,us=(Zn-ai)*za;Ua=ua!==Za?-rs*Va- -17:(-Va*os+.5)*Za;for(var Xu=0,_u=Kr;Xu<_u.length;Xu+=1)for(var Uc=0,ah=_u[Xu].positionedGlyphs;Uc=0&&g>=o&&Dc[this.text.charCodeAt(g)];g--)l--;this.text=this.text.substring(o,l),this.sectionIndex=this.sectionIndex.slice(o,l)},zu.prototype.substring=function(o,s){var l=new zu;return l.text=this.text.substring(o,s),l.sectionIndex=this.sectionIndex.slice(o,s),l.sections=this.sections,l},zu.prototype.toString=function(){return this.text},zu.prototype.getMaxScale=function(){var o=this;return this.sectionIndex.reduce(function(s,l){return Math.max(s,o.sections[l].scale)},0)},zu.prototype.addTextSection=function(o,s){this.text+=o.text,this.sections.push(lc.forText(o.scale,o.fontStack||s));for(var l=this.sections.length-1,g=0;g=63743?null:++this.imageSectionID:(this.imageSectionID=57344,this.imageSectionID)};var Dc={9:!0,10:!0,11:!0,12:!0,13:!0,32:!0},Jl={};function yh(o,s,l,g,M,j){if(s.imageName){var J=g[s.imageName];return J?J.displaySize[0]*s.scale*24/j+M:0}var ve=l[s.fontStack],ze=ve&&ve[o];return ze?ze.metrics.advance*s.scale+M:0}function Gd(o,s,l,g){var M=Math.pow(o-s,2);return g?o=0,$t=0,lr=0;lr-l/2;){if(--J<0)return!1;ve-=o[J].dist(j),j=o[J]}ve+=o[J].dist(o[J+1]),J++;for(var ze=[],lt=0;veg;)lt-=ze.shift().angleDelta;if(lt>M)return!1;J++,ve+=Dt.dist($t)}return!0}function Pu(o){for(var s=0,l=0;llt){var Vr=(lt-ze)/wr,$r=lo($t.x,lr.x,Vr),Xr=lo($t.y,lr.y,Vr),Gr=new If($r,Xr,lr.angleTo($t),Dt);return Gr._round(),!J||Qf(o,Gr,ve,J,s)?Gr:void 0}ze+=wr}}function Oh(o,s,l,g,M,j,J,ve,ze){var lt=hl(g,j,J),Dt=Gs(g,M),$t=Dt*J,lr=o[0].x===0||o[0].x===ze||o[0].y===0||o[0].y===ze;return s-$t=0&&nl=0&&la=0&&Yo+Eo<=Xo){var Es=new If(nl,la,Rs,qa);Es._round(),Gr&&!Qf(Vr,Es,Tn,Gr,Br)||es.push(Es)}}ys+=ts}return yi||es.length||Hn||(es=wr(Vr,ys/2,Xr,Gr,Br,Tn,Hn,!0,vo)),es}(o,lr?s/2*ve%s:(Dt/2+2*j)*J*ve%s,s,lt,l,$t,lr,!1,ze)}function Vp(o,s,l,g,M){for(var j=[],J=0;J=g&&$t.x>=g||(Dt.x>=g?Dt=new se(g,Dt.y+(g-Dt.x)/($t.x-Dt.x)*($t.y-Dt.y))._round():$t.x>=g&&($t=new se(g,Dt.y+(g-Dt.x)/($t.x-Dt.x)*($t.y-Dt.y))._round()),Dt.y>=M&&$t.y>=M||(Dt.y>=M?Dt=new se(Dt.x+(M-Dt.y)/($t.y-Dt.y)*($t.x-Dt.x),M)._round():$t.y>=M&&($t=new se(Dt.x+(M-Dt.y)/($t.y-Dt.y)*($t.x-Dt.x),M)._round()),ze&&Dt.equals(ze[ze.length-1])||j.push(ze=[Dt]),ze.push($t)))))}return j}function ei(o,s,l,g){var M=[],j=o.image,J=j.pixelRatio,ve=j.paddedRect.w-2,ze=j.paddedRect.h-2,lt=o.right-o.left,Dt=o.bottom-o.top,$t=j.stretchX||[[0,ve]],lr=j.stretchY||[[0,ze]],wr=function(nl,la){return nl+la[1]-la[0]},Vr=$t.reduce(wr,0),$r=lr.reduce(wr,0),Xr=ve-Vr,Gr=ze-$r,Br=0,Tn=Vr,Hn=0,yi=$r,vo=0,Eo=Xr,Xo=0,ys=Gr;if(j.content&&g){var Yo=j.content;Br=Zo($t,0,Yo[0]),Hn=Zo(lr,0,Yo[1]),Tn=Zo($t,Yo[0],Yo[2]),yi=Zo(lr,Yo[1],Yo[3]),vo=Yo[0]-Br,Xo=Yo[1]-Hn,Eo=Yo[2]-Yo[0]-Tn,ys=Yo[3]-Yo[1]-yi}var es=function(nl,la,Es,sl){var Bf=Iu(nl.stretch-Br,Tn,lt,o.left),Vl=Kc(nl.fixed-vo,Eo,nl.stretch,Vr),oc=Iu(la.stretch-Hn,yi,Dt,o.top),zc=Kc(la.fixed-Xo,ys,la.stretch,$r),xc=Iu(Es.stretch-Br,Tn,lt,o.left),ih=Kc(Es.fixed-vo,Eo,Es.stretch,Vr),wh=Iu(sl.stretch-Hn,yi,Dt,o.top),hh=Kc(sl.fixed-Xo,ys,sl.stretch,$r),dh=new se(Bf,oc),Jf=new se(xc,oc),pf=new se(xc,wh),ec=new se(Bf,wh),Jc=new se(Vl/J,zc/J),zl=new se(ih/J,hh/J),Zc=s*Math.PI/180;if(Zc){var Lh=Math.sin(Zc),sd=Math.cos(Zc),pa=[sd,-Lh,Lh,sd];dh._matMult(pa),Jf._matMult(pa),ec._matMult(pa),pf._matMult(pa)}var gc=nl.stretch+nl.fixed,Rc=la.stretch+la.fixed;return{tl:dh,tr:Jf,bl:ec,br:pf,tex:{x:j.paddedRect.x+1+gc,y:j.paddedRect.y+1+Rc,w:Es.stretch+Es.fixed-gc,h:sl.stretch+sl.fixed-Rc},writingMode:void 0,glyphOffset:[0,0],sectionIndex:0,pixelOffsetTL:Jc,pixelOffsetBR:zl,minFontScaleX:Eo/J/lt,minFontScaleY:ys/J/Dt,isSDF:l}};if(g&&(j.stretchX||j.stretchY))for(var qa=ao($t,Xr,Vr),Ts=ao(lr,Gr,$r),is=0;is0&&(wr=Math.max(10,wr),this.circleDiameter=wr)}else{var Vr=j.top*J-ve,$r=j.bottom*J+ve,Xr=j.left*J-ve,Gr=j.right*J+ve,Br=j.collisionPadding;if(Br&&(Xr-=Br[0]*J,Vr-=Br[1]*J,Gr+=Br[2]*J,$r+=Br[3]*J),lt){var Tn=new se(Xr,Vr),Hn=new se(Gr,Vr),yi=new se(Xr,$r),vo=new se(Gr,$r),Eo=lt*Math.PI/180;Tn._rotate(Eo),Hn._rotate(Eo),yi._rotate(Eo),vo._rotate(Eo),Xr=Math.min(Tn.x,Hn.x,yi.x,vo.x),Gr=Math.max(Tn.x,Hn.x,yi.x,vo.x),Vr=Math.min(Tn.y,Hn.y,yi.y,vo.y),$r=Math.max(Tn.y,Hn.y,yi.y,vo.y)}o.emplaceBack(s.x,s.y,Xr,Vr,Gr,$r,l,g,M)}this.boxEndIndex=o.length},Rr=function(o,s){if(o===void 0&&(o=[]),s===void 0&&(s=sr),this.data=o,this.length=this.data.length,this.compare=s,this.length>0)for(var l=(this.length>>1)-1;l>=0;l--)this._down(l)};function sr(o,s){return os?1:0}function ti(o,s,l){s===void 0&&(s=1),l===void 0&&(l=!1);for(var g=1/0,M=1/0,j=-1/0,J=-1/0,ve=o[0],ze=0;zej)&&(j=lt.x),(!ze||lt.y>J)&&(J=lt.y)}var Dt=Math.min(j-g,J-M),$t=Dt/2,lr=new Rr([],_o);if(Dt===0)return new se(g,M);for(var wr=g;wr$r.d||!$r.d)&&($r=Gr,l&&console.log("found best %d after %d probes",Math.round(1e4*Gr.d)/1e4,Xr)),Gr.max-$r.d<=s||(lr.push(new bo(Gr.p.x-($t=Gr.h/2),Gr.p.y-$t,$t,o)),lr.push(new bo(Gr.p.x+$t,Gr.p.y-$t,$t,o)),lr.push(new bo(Gr.p.x-$t,Gr.p.y+$t,$t,o)),lr.push(new bo(Gr.p.x+$t,Gr.p.y+$t,$t,o)),Xr+=4)}return l&&(console.log("num probes: "+Xr),console.log("best distance: "+$r.d)),$r.p}function _o(o,s){return s.max-o.max}function bo(o,s,l,g){this.p=new se(o,s),this.h=l,this.d=function(M,j){for(var J=!1,ve=1/0,ze=0;zeM.y!=Vr.y>M.y&&M.x<(Vr.x-wr.x)*(M.y-wr.y)/(Vr.y-wr.y)+wr.x&&(J=!J),ve=Math.min(ve,hd(M,wr,Vr))}return(J?1:-1)*Math.sqrt(ve)}(this.p,g),this.max=this.d+this.h*Math.SQRT2}Rr.prototype.push=function(o){this.data.push(o),this.length++,this._up(this.length-1)},Rr.prototype.pop=function(){if(this.length!==0){var o=this.data[0],s=this.data.pop();return this.length--,this.length>0&&(this.data[0]=s,this._down(0)),o}},Rr.prototype.peek=function(){return this.data[0]},Rr.prototype._up=function(o){for(var s=this.data,l=this.compare,g=s[o];o>0;){var M=o-1>>1,j=s[M];if(l(g,j)>=0)break;s[o]=j,o=M}s[o]=g},Rr.prototype._down=function(o){for(var s=this.data,l=this.compare,g=this.length>>1,M=s[o];o=0)break;s[o]=J,o=j}s[o]=M};var Pi=Number.POSITIVE_INFINITY;function ji(o,s){return s[1]!==Pi?function(l,g,M){var j=0,J=0;switch(g=Math.abs(g),M=Math.abs(M),l){case"top-right":case"top-left":case"top":J=M-7;break;case"bottom-right":case"bottom-left":case"bottom":J=7-M}switch(l){case"top-right":case"bottom-right":case"right":j=-g;break;case"top-left":case"bottom-left":case"left":j=g}return[j,J]}(o,s[0],s[1]):function(l,g){var M=0,j=0;g<0&&(g=0);var J=g/Math.sqrt(2);switch(l){case"top-right":case"top-left":j=J-7;break;case"bottom-right":case"bottom-left":j=7-J;break;case"bottom":j=7-g;break;case"top":j=g-7}switch(l){case"top-right":case"bottom-right":M=-J;break;case"top-left":case"bottom-left":M=J;break;case"left":M=g;break;case"right":M=-g}return[M,j]}(o,s[0])}function Di(o){switch(o){case"right":case"top-right":case"bottom-right":return"right";case"left":case"top-left":case"bottom-left":return"left"}return"center"}function jn(o,s,l,g,M,j,J,ve,ze,lt,Dt,$t,lr,wr,Vr){var $r=function(Hn,yi,vo,Eo,Xo,ys,Yo,es){for(var qa=Eo.layout.get("text-rotate").evaluate(ys,{})*Math.PI/180,Ts=[],is=0,ts=yi.positionedLines;is32640&&et(o.layerIds[0]+': Value for "text-size" is >= 255. Reduce your "text-size".'):Xr.kind==="composite"&&((Gr=[128*wr.compositeTextSizes[0].evaluate(J,{},Vr),128*wr.compositeTextSizes[1].evaluate(J,{},Vr)])[0]>32640||Gr[1]>32640)&&et(o.layerIds[0]+': Value for "text-size" is >= 255. Reduce your "text-size".'),o.addSymbols(o.text,$r,Gr,ve,j,J,lt,s,ze.lineStartIndex,ze.lineLength,lr,Vr);for(var Br=0,Tn=Dt;Br=0;J--)if(g.dist(j[J])0)&&(j.value.kind!=="constant"||j.value.value.length>0),lt=ve.value.kind!=="constant"||!!ve.value.value||Object.keys(ve.parameters).length>0,Dt=M.get("symbol-sort-key");if(this.features=[],ze||lt){for(var $t=s.iconDependencies,lr=s.glyphDependencies,wr=s.availableImages,Vr=new Ls(this.zoom),$r=0,Xr=o;$r=0;for(var Rs=0,pu=Xo.sections;Rs=0;ve--)j[ve]={x:s[ve].x,y:s[ve].y,tileUnitDistanceFromAnchor:M},ve>0&&(M+=s[ve-1].dist(s[ve]));for(var ze=0;ze0},rr.prototype.hasIconData=function(){return this.icon.segments.get().length>0},rr.prototype.hasDebugData=function(){return this.textCollisionBox&&this.iconCollisionBox},rr.prototype.hasTextCollisionBoxData=function(){return this.hasDebugData()&&this.textCollisionBox.segments.get().length>0},rr.prototype.hasIconCollisionBoxData=function(){return this.hasDebugData()&&this.iconCollisionBox.segments.get().length>0},rr.prototype.addIndicesForPlacedSymbol=function(o,s){for(var l=o.placedSymbolArray.get(s),g=l.vertexStartIndex+4*l.numGlyphs,M=l.vertexStartIndex;M1||this.icon.segments.get().length>1)){this.symbolInstanceIndexes=this.getSortedSymbolIndexes(o),this.sortedAngle=o,this.text.indexArray.clear(),this.icon.indexArray.clear(),this.featureSortOrder=[];for(var l=0,g=this.symbolInstanceIndexes;l=0&&ve.indexOf(j)===J&&s.addIndicesForPlacedSymbol(s.text,j)}),M.verticalPlacedTextSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.text,M.verticalPlacedTextSymbolIndex),M.placedIconSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.icon,M.placedIconSymbolIndex),M.verticalPlacedIconSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.icon,M.verticalPlacedIconSymbolIndex)}this.text.indexBuffer&&this.text.indexBuffer.updateData(this.text.indexArray),this.icon.indexBuffer&&this.icon.indexBuffer.updateData(this.icon.indexArray)}},xa("SymbolBucket",rr,{omit:["layers","collisionBoxArray","features","compareText"]}),rr.MAX_GLYPHS=65535,rr.addDynamicAttributes=Ae;var mr=new pc({"symbol-placement":new Ka(Gt.layout_symbol["symbol-placement"]),"symbol-spacing":new Ka(Gt.layout_symbol["symbol-spacing"]),"symbol-avoid-edges":new Ka(Gt.layout_symbol["symbol-avoid-edges"]),"symbol-sort-key":new ea(Gt.layout_symbol["symbol-sort-key"]),"symbol-z-order":new Ka(Gt.layout_symbol["symbol-z-order"]),"icon-allow-overlap":new Ka(Gt.layout_symbol["icon-allow-overlap"]),"icon-ignore-placement":new Ka(Gt.layout_symbol["icon-ignore-placement"]),"icon-optional":new Ka(Gt.layout_symbol["icon-optional"]),"icon-rotation-alignment":new Ka(Gt.layout_symbol["icon-rotation-alignment"]),"icon-size":new ea(Gt.layout_symbol["icon-size"]),"icon-text-fit":new Ka(Gt.layout_symbol["icon-text-fit"]),"icon-text-fit-padding":new Ka(Gt.layout_symbol["icon-text-fit-padding"]),"icon-image":new ea(Gt.layout_symbol["icon-image"]),"icon-rotate":new ea(Gt.layout_symbol["icon-rotate"]),"icon-padding":new Ka(Gt.layout_symbol["icon-padding"]),"icon-keep-upright":new Ka(Gt.layout_symbol["icon-keep-upright"]),"icon-offset":new ea(Gt.layout_symbol["icon-offset"]),"icon-anchor":new ea(Gt.layout_symbol["icon-anchor"]),"icon-pitch-alignment":new Ka(Gt.layout_symbol["icon-pitch-alignment"]),"text-pitch-alignment":new Ka(Gt.layout_symbol["text-pitch-alignment"]),"text-rotation-alignment":new Ka(Gt.layout_symbol["text-rotation-alignment"]),"text-field":new ea(Gt.layout_symbol["text-field"]),"text-font":new ea(Gt.layout_symbol["text-font"]),"text-size":new ea(Gt.layout_symbol["text-size"]),"text-max-width":new ea(Gt.layout_symbol["text-max-width"]),"text-line-height":new Ka(Gt.layout_symbol["text-line-height"]),"text-letter-spacing":new ea(Gt.layout_symbol["text-letter-spacing"]),"text-justify":new ea(Gt.layout_symbol["text-justify"]),"text-radial-offset":new ea(Gt.layout_symbol["text-radial-offset"]),"text-variable-anchor":new Ka(Gt.layout_symbol["text-variable-anchor"]),"text-anchor":new ea(Gt.layout_symbol["text-anchor"]),"text-max-angle":new Ka(Gt.layout_symbol["text-max-angle"]),"text-writing-mode":new Ka(Gt.layout_symbol["text-writing-mode"]),"text-rotate":new ea(Gt.layout_symbol["text-rotate"]),"text-padding":new Ka(Gt.layout_symbol["text-padding"]),"text-keep-upright":new Ka(Gt.layout_symbol["text-keep-upright"]),"text-transform":new ea(Gt.layout_symbol["text-transform"]),"text-offset":new ea(Gt.layout_symbol["text-offset"]),"text-allow-overlap":new Ka(Gt.layout_symbol["text-allow-overlap"]),"text-ignore-placement":new Ka(Gt.layout_symbol["text-ignore-placement"]),"text-optional":new Ka(Gt.layout_symbol["text-optional"])}),pn={paint:new pc({"icon-opacity":new ea(Gt.paint_symbol["icon-opacity"]),"icon-color":new ea(Gt.paint_symbol["icon-color"]),"icon-halo-color":new ea(Gt.paint_symbol["icon-halo-color"]),"icon-halo-width":new ea(Gt.paint_symbol["icon-halo-width"]),"icon-halo-blur":new ea(Gt.paint_symbol["icon-halo-blur"]),"icon-translate":new Ka(Gt.paint_symbol["icon-translate"]),"icon-translate-anchor":new Ka(Gt.paint_symbol["icon-translate-anchor"]),"text-opacity":new ea(Gt.paint_symbol["text-opacity"]),"text-color":new ea(Gt.paint_symbol["text-color"],{runtimeType:Gi,getOverride:function(o){return o.textColor},hasOverride:function(o){return!!o.textColor}}),"text-halo-color":new ea(Gt.paint_symbol["text-halo-color"]),"text-halo-width":new ea(Gt.paint_symbol["text-halo-width"]),"text-halo-blur":new ea(Gt.paint_symbol["text-halo-blur"]),"text-translate":new Ka(Gt.paint_symbol["text-translate"]),"text-translate-anchor":new Ka(Gt.paint_symbol["text-translate-anchor"])}),layout:mr},Jn=function(o){this.type=o.property.overrides?o.property.overrides.runtimeType:Wn,this.defaultValue=o};Jn.prototype.evaluate=function(o){if(o.formattedSection){var s=this.defaultValue.property.overrides;if(s&&s.hasOverride(o.formattedSection))return s.getOverride(o.formattedSection)}return o.feature&&o.featureState?this.defaultValue.evaluate(o.feature,o.featureState):this.defaultValue.property.specification.default},Jn.prototype.eachChild=function(o){this.defaultValue.isConstant()||o(this.defaultValue.value._styleExpression.expression)},Jn.prototype.outputDefined=function(){return!1},Jn.prototype.serialize=function(){return null},xa("FormatSectionOverride",Jn,{omit:["defaultValue"]});var ui=function(o){function s(l){o.call(this,l,pn)}return o&&(s.__proto__=o),(s.prototype=Object.create(o&&o.prototype)).constructor=s,s.prototype.recalculate=function(l,g){if(o.prototype.recalculate.call(this,l,g),this.layout.get("icon-rotation-alignment")==="auto"&&(this.layout._values["icon-rotation-alignment"]=this.layout.get("symbol-placement")!=="point"?"map":"viewport"),this.layout.get("text-rotation-alignment")==="auto"&&(this.layout._values["text-rotation-alignment"]=this.layout.get("symbol-placement")!=="point"?"map":"viewport"),this.layout.get("text-pitch-alignment")==="auto"&&(this.layout._values["text-pitch-alignment"]=this.layout.get("text-rotation-alignment")),this.layout.get("icon-pitch-alignment")==="auto"&&(this.layout._values["icon-pitch-alignment"]=this.layout.get("icon-rotation-alignment")),this.layout.get("symbol-placement")==="point"){var M=this.layout.get("text-writing-mode");if(M){for(var j=[],J=0,ve=M;J",targetMapId:g,sourceMapId:j.mapId})}}},vh.prototype.receive=function(o){var s=o.data,l=s.id;if(l&&(!s.targetMapId||this.mapId===s.targetMapId))if(s.type===""){delete this.tasks[l];var g=this.cancelCallbacks[l];delete this.cancelCallbacks[l],g&&g()}else ft()||s.mustQueue?(this.tasks[l]=s,this.taskQueue.push(l),this.invoker.trigger()):this.processTask(l,s)},vh.prototype.process=function(){if(this.taskQueue.length){var o=this.taskQueue.shift(),s=this.tasks[o];delete this.tasks[o],this.taskQueue.length&&this.invoker.trigger(),s&&this.processTask(o,s)}},vh.prototype.processTask=function(o,s){var l=this;if(s.type===""){var g=this.callbacks[o];delete this.callbacks[o],g&&(s.error?g(Hl(s.error)):g(null,Hl(s.data)))}else{var M=!1,j=Ft(this.globalScope)?void 0:[],J=s.hasCallback?function(Dt,$t){M=!0,delete l.cancelCallbacks[o],l.target.postMessage({id:o,type:"",sourceMapId:l.mapId,error:Dt?Fr(Dt):null,data:Fr($t,j)},j)}:function(Dt){M=!0},ve=null,ze=Hl(s.data);if(this.parent[s.type])ve=this.parent[s.type](s.sourceMapId,ze,J);else if(this.parent.getWorkerSource){var lt=s.type.split(".");ve=this.parent.getWorkerSource(s.sourceMapId,lt[0],ze.source)[lt[1]](ze,J)}else J(new Error("Could not find function "+s.type));!M&&ve&&ve.cancel&&(this.cancelCallbacks[o]=ve.cancel)}},vh.prototype.remove=function(){this.invoker.remove(),this.target.removeEventListener("message",this.receive,!1)};var Nl=function(o,s){o&&(s?this.setSouthWest(o).setNorthEast(s):o.length===4?this.setSouthWest([o[0],o[1]]).setNorthEast([o[2],o[3]]):this.setSouthWest(o[0]).setNorthEast(o[1]))};Nl.prototype.setNorthEast=function(o){return this._ne=o instanceof vc?new vc(o.lng,o.lat):vc.convert(o),this},Nl.prototype.setSouthWest=function(o){return this._sw=o instanceof vc?new vc(o.lng,o.lat):vc.convert(o),this},Nl.prototype.extend=function(o){var s,l,g=this._sw,M=this._ne;if(o instanceof vc)s=o,l=o;else{if(!(o instanceof Nl))return Array.isArray(o)?o.length===4||o.every(Array.isArray)?this.extend(Nl.convert(o)):this.extend(vc.convert(o)):this;if(l=o._ne,!(s=o._sw)||!l)return this}return g||M?(g.lng=Math.min(s.lng,g.lng),g.lat=Math.min(s.lat,g.lat),M.lng=Math.max(l.lng,M.lng),M.lat=Math.max(l.lat,M.lat)):(this._sw=new vc(s.lng,s.lat),this._ne=new vc(l.lng,l.lat)),this},Nl.prototype.getCenter=function(){return new vc((this._sw.lng+this._ne.lng)/2,(this._sw.lat+this._ne.lat)/2)},Nl.prototype.getSouthWest=function(){return this._sw},Nl.prototype.getNorthEast=function(){return this._ne},Nl.prototype.getNorthWest=function(){return new vc(this.getWest(),this.getNorth())},Nl.prototype.getSouthEast=function(){return new vc(this.getEast(),this.getSouth())},Nl.prototype.getWest=function(){return this._sw.lng},Nl.prototype.getSouth=function(){return this._sw.lat},Nl.prototype.getEast=function(){return this._ne.lng},Nl.prototype.getNorth=function(){return this._ne.lat},Nl.prototype.toArray=function(){return[this._sw.toArray(),this._ne.toArray()]},Nl.prototype.toString=function(){return"LngLatBounds("+this._sw.toString()+", "+this._ne.toString()+")"},Nl.prototype.isEmpty=function(){return!(this._sw&&this._ne)},Nl.prototype.contains=function(o){var s=vc.convert(o),l=s.lng,g=s.lat,M=this._sw.lng<=l&&l<=this._ne.lng;return this._sw.lng>this._ne.lng&&(M=this._sw.lng>=l&&l>=this._ne.lng),this._sw.lat<=g&&g<=this._ne.lat&&M},Nl.convert=function(o){return!o||o instanceof Nl?o:new Nl(o)};var vc=function(o,s){if(isNaN(o)||isNaN(s))throw new Error("Invalid LngLat object: ("+o+", "+s+")");if(this.lng=+o,this.lat=+s,this.lat>90||this.lat<-90)throw new Error("Invalid LngLat latitude value: must be between -90 and 90")};vc.prototype.wrap=function(){return new vc(qe(this.lng,-180,180),this.lat)},vc.prototype.toArray=function(){return[this.lng,this.lat]},vc.prototype.toString=function(){return"LngLat("+this.lng+", "+this.lat+")"},vc.prototype.distanceTo=function(o){var s=Math.PI/180,l=this.lat*s,g=o.lat*s,M=Math.sin(l)*Math.sin(g)+Math.cos(l)*Math.cos(g)*Math.cos((o.lng-this.lng)*s);return 63710088e-1*Math.acos(Math.min(M,1))},vc.prototype.toBounds=function(o){o===void 0&&(o=0);var s=360*o/40075017,l=s/Math.cos(Math.PI/180*this.lat);return new Nl(new vc(this.lng-l,this.lat-s),new vc(this.lng+l,this.lat+s))},vc.convert=function(o){if(o instanceof vc)return o;if(Array.isArray(o)&&(o.length===2||o.length===3))return new vc(Number(o[0]),Number(o[1]));if(!Array.isArray(o)&&typeof o=="object"&&o!==null)return new vc(Number("lng"in o?o.lng:o.lon),Number(o.lat));throw new Error("`LngLatLike` argument must be specified as a LngLat instance, an object {lng: , lat: }, an object {lon: , lat: }, or an array of [, ]")};var Hh=2*Math.PI*63710088e-1;function Af(o){return Hh*Math.cos(o*Math.PI/180)}function Fh(o){return(180+o)/360}function Mf(o){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+o*Math.PI/360)))/360}function lm(o,s){return o/Af(s)}function bm(o){return 360/Math.PI*Math.atan(Math.exp((180-360*o)*Math.PI/180))-90}var xm=function(o,s,l){l===void 0&&(l=0),this.x=+o,this.y=+s,this.z=+l};xm.fromLngLat=function(o,s){s===void 0&&(s=0);var l=vc.convert(o);return new xm(Fh(l.lng),Mf(l.lat),lm(s,l.lat))},xm.prototype.toLngLat=function(){return new vc(360*this.x-180,bm(this.y))},xm.prototype.toAltitude=function(){return this.z*Af(bm(this.y))},xm.prototype.meterInMercatorCoordinateUnits=function(){return 1/Hh*(o=bm(this.y),1/Math.cos(o*Math.PI/180));var o};var Rp=function(o,s,l){this.z=o,this.x=s,this.y=l,this.key=N0(0,o,o,s,l)};Rp.prototype.equals=function(o){return this.z===o.z&&this.x===o.x&&this.y===o.y},Rp.prototype.url=function(o,s){var l,g,M,j,J,ve=(g=this.y,M=this.z,j=$f(256*(l=this.x),256*(g=Math.pow(2,M)-g-1),M),J=$f(256*(l+1),256*(g+1),M),j[0]+","+j[1]+","+J[0]+","+J[1]),ze=function(lt,Dt,$t){for(var lr,wr="",Vr=lt;Vr>0;Vr--)wr+=(Dt&(lr=1<this.canonical.z?new qd(o,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y):new qd(o,this.wrap,o,this.canonical.x>>s,this.canonical.y>>s)},qd.prototype.calculateScaledKey=function(o,s){var l=this.canonical.z-o;return o>this.canonical.z?N0(this.wrap*+s,o,this.canonical.z,this.canonical.x,this.canonical.y):N0(this.wrap*+s,o,o,this.canonical.x>>l,this.canonical.y>>l)},qd.prototype.isChildOf=function(o){if(o.wrap!==this.wrap)return!1;var s=this.canonical.z-o.canonical.z;return o.overscaledZ===0||o.overscaledZ>s&&o.canonical.y===this.canonical.y>>s},qd.prototype.children=function(o){if(this.overscaledZ>=o)return[new qd(this.overscaledZ+1,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y)];var s=this.canonical.z+1,l=2*this.canonical.x,g=2*this.canonical.y;return[new qd(s,this.wrap,s,l,g),new qd(s,this.wrap,s,l+1,g),new qd(s,this.wrap,s,l,g+1),new qd(s,this.wrap,s,l+1,g+1)]},qd.prototype.isLessThan=function(o){return this.wrapo.wrap)&&(this.overscaledZo.overscaledZ)&&(this.canonical.xo.canonical.x)&&this.canonical.y=this.dim+1||s<-1||s>=this.dim+1)throw new RangeError("out of range source coordinates for DEM data");return(s+1)*this.stride+(o+1)},ld.prototype._unpackMapbox=function(o,s,l){return(256*o*256+256*s+l)/10-1e4},ld.prototype._unpackTerrarium=function(o,s,l){return 256*o+s+l/256-32768},ld.prototype.getPixels=function(){return new np({width:this.stride,height:this.stride},new Uint8Array(this.data.buffer))},ld.prototype.backfillBorder=function(o,s,l){if(this.dim!==o.dim)throw new Error("dem dimension mismatch");var g=s*this.dim,M=s*this.dim+this.dim,j=l*this.dim,J=l*this.dim+this.dim;switch(s){case-1:g=M-1;break;case 1:M=g+1}switch(l){case-1:j=J-1;break;case 1:J=j+1}for(var ve=-s*this.dim,ze=-l*this.dim,lt=j;lt=0&&Dt[3]>=0&&ve.insert(J,Dt[0],Dt[1],Dt[2],Dt[3])}},em.prototype.loadVTLayers=function(){return this.vtLayers||(this.vtLayers=new f0.VectorTile(new $o(this.rawTileData)).layers,this.sourceLayerCoder=new Qp(this.vtLayers?Object.keys(this.vtLayers).sort():["_geojsonTileLayer"])),this.vtLayers},em.prototype.query=function(o,s,l,g){var M=this;this.loadVTLayers();for(var j=o.params||{},J=8192/o.tileSize/o.scale,ve=mu(j.filter),ze=o.queryGeometry,lt=o.queryPadding*J,Dt=Qd(ze),$t=this.grid.query(Dt.minX-lt,Dt.minY-lt,Dt.maxX+lt,Dt.maxY+lt),lr=Qd(o.cameraQueryGeometry),wr=this.grid3D.query(lr.minX-lt,lr.minY-lt,lr.maxX+lt,lr.maxY+lt,function(Hn,yi,vo,Eo){return function(Xo,ys,Yo,es,qa){for(var Ts=0,is=Xo;Ts=ts.x&&qa>=ts.y)return!0}var Rs=[new se(ys,Yo),new se(ys,qa),new se(es,qa),new se(es,Yo)];if(Xo.length>2){for(var pu=0,nl=Rs;pu=0)return!0;return!1}(j,$t)){var lr=this.sourceLayerCoder.decode(l),wr=this.vtLayers[lr].feature(g);if(M.needGeometry){var Vr=Kf(wr,!0);if(!M.filter(new Ls(this.tileID.overscaledZ),Vr,this.tileID.canonical))return}else if(!M.filter(new Ls(this.tileID.overscaledZ),wr))return;for(var $r=this.getId(wr,lr),Xr=0;Xr<$t.length;Xr++){var Gr=$t[Xr];if(!(j&&j.indexOf(Gr)<0)){var Br=ve[Gr];if(Br){var Tn={};$r!==void 0&<&&(Tn=lt.getState(Br.sourceLayer||"_geojsonTileLayer",$r));var Hn=Ge({},ze[Gr]);Hn.paint=Bd(Hn.paint,Br.paint,wr,Tn,J),Hn.layout=Bd(Hn.layout,Br.layout,wr,Tn,J);var yi=!Dt||Dt(wr,Br,Tn);if(yi){var vo=new Gh(wr,this.z,this.x,this.y,$r);vo.layer=Hn;var Eo=o[Gr];Eo===void 0&&(Eo=o[Gr]=[]),Eo.push({featureIndex:g,feature:vo,intersectionZ:yi})}}}}}},em.prototype.lookupSymbolFeatures=function(o,s,l,g,M,j,J,ve){var ze={};this.loadVTLayers();for(var lt=mu(M),Dt=0,$t=o;Dt<$t.length;Dt+=1)this.loadMatchingFeature(ze,l,g,$t[Dt],lt,j,J,ve,s);return ze},em.prototype.hasLayer=function(o){for(var s=0,l=this.bucketLayerIDs;sg)M=!1;else if(s)if(this.expirationTimeUn&&(o.getActor().send("enforceCacheSizeLimit",zn),xt=0)},y.clamp=Ee,y.clearTileCache=function(o){var s=ce.caches.delete("mapbox-tiles");o&&s.catch(o).then(function(){return o()})},y.clipLine=Vp,y.clone=function(o){var s=new Tc(16);return s[0]=o[0],s[1]=o[1],s[2]=o[2],s[3]=o[3],s[4]=o[4],s[5]=o[5],s[6]=o[6],s[7]=o[7],s[8]=o[8],s[9]=o[9],s[10]=o[10],s[11]=o[11],s[12]=o[12],s[13]=o[13],s[14]=o[14],s[15]=o[15],s},y.clone$1=Ne,y.clone$2=function(o){var s=new Tc(3);return s[0]=o[0],s[1]=o[1],s[2]=o[2],s},y.collisionCircleLayout=_r,y.config=hn,y.create=function(){var o=new Tc(16);return Tc!=Float32Array&&(o[1]=0,o[2]=0,o[3]=0,o[4]=0,o[6]=0,o[7]=0,o[8]=0,o[9]=0,o[11]=0,o[12]=0,o[13]=0,o[14]=0),o[0]=1,o[5]=1,o[10]=1,o[15]=1,o},y.create$1=function(){var o=new Tc(9);return Tc!=Float32Array&&(o[1]=0,o[2]=0,o[3]=0,o[5]=0,o[6]=0,o[7]=0),o[0]=1,o[4]=1,o[8]=1,o},y.create$2=function(){var o=new Tc(4);return Tc!=Float32Array&&(o[1]=0,o[2]=0),o[0]=1,o[3]=1,o},y.createCommonjsModule=p,y.createExpression=Ol,y.createLayout=Xf,y.createStyleLayer=function(o){return o.type==="custom"?new Go(o):new Wo[o.type](o)},y.cross=function(o,s,l){var g=s[0],M=s[1],j=s[2],J=l[0],ve=l[1],ze=l[2];return o[0]=M*ze-j*ve,o[1]=j*J-g*ze,o[2]=g*ve-M*J,o},y.deepEqual=function o(s,l){if(Array.isArray(s)){if(!Array.isArray(l)||s.length!==l.length)return!1;for(var g=0;g0&&(j=1/Math.sqrt(j)),o[0]=s[0]*j,o[1]=s[1]*j,o[2]=s[2]*j,o},y.number=lo,y.offscreenCanvasSupported=it,y.ortho=function(o,s,l,g,M,j,J){var ve=1/(s-l),ze=1/(g-M),lt=1/(j-J);return o[0]=-2*ve,o[1]=0,o[2]=0,o[3]=0,o[4]=0,o[5]=-2*ze,o[6]=0,o[7]=0,o[8]=0,o[9]=0,o[10]=2*lt,o[11]=0,o[12]=(s+l)*ve,o[13]=(M+g)*ze,o[14]=(J+j)*lt,o[15]=1,o},y.parseGlyphPBF=function(o){return new $o(o).readFields(Ba,[])},y.pbf=$o,y.performSymbolLayout=function(o,s,l,g,M,j,J){o.createArrays(),o.tilePixelRatio=8192/(512*o.overscaling),o.compareText={},o.iconsNeedLinear=!1;var ve=o.layers[0].layout,ze=o.layers[0]._unevaluatedLayout._values,lt={};if(o.textSizeData.kind==="composite"){var Dt=o.textSizeData,$t=Dt.maxZoom;lt.compositeTextSizes=[ze["text-size"].possiblyEvaluate(new Ls(Dt.minZoom),J),ze["text-size"].possiblyEvaluate(new Ls($t),J)]}if(o.iconSizeData.kind==="composite"){var lr=o.iconSizeData,wr=lr.maxZoom;lt.compositeIconSizes=[ze["icon-size"].possiblyEvaluate(new Ls(lr.minZoom),J),ze["icon-size"].possiblyEvaluate(new Ls(wr),J)]}lt.layoutTextSize=ze["text-size"].possiblyEvaluate(new Ls(o.zoom+1),J),lt.layoutIconSize=ze["icon-size"].possiblyEvaluate(new Ls(o.zoom+1),J),lt.textMaxSize=ze["text-size"].possiblyEvaluate(new Ls(18));for(var Vr=24*ve.get("text-line-height"),$r=ve.get("text-rotation-alignment")==="map"&&ve.get("symbol-placement")!=="point",Xr=ve.get("text-keep-upright"),Gr=ve.get("text-size"),Br=function(){var yi=Hn[Tn],vo=ve.get("text-font").evaluate(yi,{},J).join(","),Eo=Gr.evaluate(yi,{},J),Xo=lt.layoutTextSize.evaluate(yi,{},J),ys=lt.layoutIconSize.evaluate(yi,{},J),Yo={horizontal:{},vertical:void 0},es=yi.text,qa=[0,0];if(es){var Ts=es.toString(),is=24*ve.get("text-letter-spacing").evaluate(yi,{},J),ts=function(ec){for(var Jc=0,zl=ec;Jc=8192||a0.y<0||a0.y>=8192||function(Mh,ju,Ws,K,ne,ue,Ue,Ut,vr,Cr,Jr,Mn,kn,$i,wa,Os,Nu,yl,js,$s,Du,Ml,Wl,yf,Nf){var cf,jc,eh,uh,qc,mf=Mh.addToLineVertexArray(ju,Ws),Dh=0,lh=0,Eh=0,Uh=0,Qi=-1,Yn=-1,Ti={},ca=Hr(""),Qa=0,Oa=0;if(Ut._unevaluatedLayout.getValue("text-radial-offset")===void 0?(Qa=(cf=Ut.layout.get("text-offset").evaluate(Du,{},yf).map(function(zv){return 24*zv}))[0],Oa=cf[1]):(Qa=24*Ut.layout.get("text-radial-offset").evaluate(Du,{},yf),Oa=Pi),Mh.allowVerticalPlacement&&K.vertical){var Xl=Ut.layout.get("text-rotate").evaluate(Du,{},yf)+90;uh=new sa(vr,ju,Cr,Jr,Mn,K.vertical,kn,$i,wa,Xl),Ue&&(qc=new sa(vr,ju,Cr,Jr,Mn,Ue,Nu,yl,wa,Xl))}if(ne){var Vc=Ut.layout.get("icon-rotate").evaluate(Du,{}),Pf=Ut.layout.get("icon-text-fit")!=="none",$d=ei(ne,Vc,Wl,Pf),qh=Ue?ei(Ue,Vc,Wl,Pf):void 0;eh=new sa(vr,ju,Cr,Jr,Mn,ne,Nu,yl,!1,Vc),Dh=4*$d.length;var Xd=Mh.iconSizeData,wm=null;Xd.kind==="source"?(wm=[128*Ut.layout.get("icon-size").evaluate(Du,{})])[0]>32640&&et(Mh.layerIds[0]+': Value for "icon-size" is >= 255. Reduce your "icon-size".'):Xd.kind==="composite"&&((wm=[128*Ml.compositeIconSizes[0].evaluate(Du,{},yf),128*Ml.compositeIconSizes[1].evaluate(Du,{},yf)])[0]>32640||wm[1]>32640)&&et(Mh.layerIds[0]+': Value for "icon-size" is >= 255. Reduce your "icon-size".'),Mh.addSymbols(Mh.icon,$d,wm,$s,js,Du,!1,ju,mf.lineStartIndex,mf.lineLength,-1,yf),Qi=Mh.icon.placedSymbolArray.length-1,qh&&(lh=4*qh.length,Mh.addSymbols(Mh.icon,qh,wm,$s,js,Du,Ql.vertical,ju,mf.lineStartIndex,mf.lineLength,-1,yf),Yn=Mh.icon.placedSymbolArray.length-1)}for(var Oy in K.horizontal){var qv=K.horizontal[Oy];if(!jc){ca=Hr(qv.text);var rv=Ut.layout.get("text-rotate").evaluate(Du,{},yf);jc=new sa(vr,ju,Cr,Jr,Mn,qv,kn,$i,wa,rv)}var Tv=qv.positionedLines.length===1;if(Eh+=jn(Mh,ju,qv,ue,Ut,wa,Du,Os,mf,K.vertical?Ql.horizontal:Ql.horizontalOnly,Tv?Object.keys(K.horizontal):[Oy],Ti,Qi,Ml,yf),Tv)break}K.vertical&&(Uh+=jn(Mh,ju,K.vertical,ue,Ut,wa,Du,Os,mf,Ql.vertical,["vertical"],Ti,Yn,Ml,yf));var Qg=jc?jc.boxStartIndex:Mh.collisionBoxArray.length,Ly=jc?jc.boxEndIndex:Mh.collisionBoxArray.length,Ag=uh?uh.boxStartIndex:Mh.collisionBoxArray.length,Jg=uh?uh.boxEndIndex:Mh.collisionBoxArray.length,Dy=eh?eh.boxStartIndex:Mh.collisionBoxArray.length,Nv=eh?eh.boxEndIndex:Mh.collisionBoxArray.length,ey=qc?qc.boxStartIndex:Mh.collisionBoxArray.length,bg=qc?qc.boxEndIndex:Mh.collisionBoxArray.length,qm=-1,lv=function(zv,xg){return zv&&zv.circleDiameter?Math.max(zv.circleDiameter,xg):xg};qm=lv(jc,qm),qm=lv(uh,qm),qm=lv(eh,qm);var h1=(qm=lv(qc,qm))>-1?1:0;h1&&(qm*=Nf/24),Mh.glyphOffsetArray.length>=rr.MAX_GLYPHS&&et("Too many glyphs being rendered in a tile. See https://github.com/mapbox/mapbox-gl-js/issues/2907"),Du.sortKey!==void 0&&Mh.addToSortKeyRanges(Mh.symbolInstances.length,Du.sortKey),Mh.symbolInstances.emplaceBack(ju.x,ju.y,Ti.right>=0?Ti.right:-1,Ti.center>=0?Ti.center:-1,Ti.left>=0?Ti.left:-1,Ti.vertical||-1,Qi,Yn,ca,Qg,Ly,Ag,Jg,Dy,Nv,ey,bg,Cr,Eh,Uh,Dh,lh,h1,0,kn,Qa,Oa,qm)}(ec,a0,Ap,zl,Zc,Lh,d,ec.layers[0],ec.collisionBoxArray,Jc.index,Jc.sourceLayerIndex,ec.index,Re,br,z,Rc,Mt,Ir,Q,G,Jc,sd,tc,oh,pa)};if(Pe==="line")for(var Dr=0,Kr=Vp(Jc.geometry,0,0,8192,8192);Dr1){var os=of(rs,Z,zl.vertical||de,Zc,24,ht);os&&Sr(rs,os)}}else if(Jc.type==="Polygon")for(var Ua=0,us=n0(Jc.geometry,0);Ua=Ps.maxzoom||Ps.visibility!=="none"&&(ce(Do,this.zoom,At),(on[Ps.id]=Ps.createBucket({index:Gt.bucketLayerIDs.length,layers:Do,zoom:this.zoom,pixelRatio:this.pixelRatio,overscaling:this.overscaling,collisionBoxArray:this.collisionBoxArray,sourceLayerIndex:di,sourceID:this.source})).populate(zi,dn,this.tileID.canonical),Gt.bucketLayerIDs.push(Do.map(function(ga){return ga.id})))}}}var Nr=y.mapObject(dn.glyphDependencies,function(ga){return Object.keys(ga).map(Number)});Object.keys(Nr).length?Bt.send("getGlyphs",{uid:this.uid,stacks:Nr},function(ga,Xi){Tr||(Tr=ga,nn=Xi,Yi.call(ar))}):nn={};var fo=Object.keys(dn.iconDependencies);fo.length?Bt.send("getImages",{icons:fo,source:this.source,tileID:this.tileID,type:"icons"},function(ga,Xi){Tr||(Tr=ga,bn=Xi,Yi.call(ar))}):bn={};var hi=Object.keys(dn.patternDependencies);function Yi(){if(Tr)return Jt(Tr);if(nn&&bn&&Bi){var ga=new se(nn),Xi=new y.ImageAtlas(bn,Bi);for(var On in on){var gi=on[On];gi instanceof y.SymbolBucket?(ce(gi.layers,this.zoom,At),y.performSymbolLayout(gi,nn,ga.positions,bn,Xi.iconPositions,this.showCollisionBoxes,this.tileID.canonical)):gi.hasPattern&&(gi instanceof y.LineBucket||gi instanceof y.FillBucket||gi instanceof y.FillExtrusionBucket)&&(ce(gi.layers,this.zoom,At),gi.addFeatures(dn,this.tileID.canonical,Xi.patternPositions))}this.status="done",Jt(null,{buckets:y.values(on).filter(function(ol){return!ol.isEmpty()}),featureIndex:Gt,collisionBoxArray:this.collisionBoxArray,glyphAtlasImage:ga.image,imageAtlas:Xi,glyphMap:this.returnDependencies?nn:null,iconMap:this.returnDependencies?bn:null,glyphPositions:this.returnDependencies?ga.positions:null})}}hi.length?Bt.send("getImages",{icons:hi,source:this.source,tileID:this.tileID,type:"patterns"},function(ga,Xi){Tr||(Tr=ga,Bi=Xi,Yi.call(ar))}):Bi={},Yi.call(this)};var De=function(je,$e,At,Bt){this.actor=je,this.layerIndex=$e,this.availableImages=At,this.loadVectorData=Bt||le,this.loading={},this.loaded={}};De.prototype.loadTile=function(je,$e){var At=this,Bt=je.uid;this.loading||(this.loading={});var Jt=!!(je&&je.request&&je.request.collectResourceTiming)&&new y.RequestPerformance(je.request),ar=this.loading[Bt]=new ae(je);ar.abort=this.loadVectorData(je,function(hr,Gt){if(delete At.loading[Bt],hr||!Gt)return ar.status="done",At.loaded[Bt]=ar,$e(hr);var Tr=Gt.rawData,nn={};Gt.expires&&(nn.expires=Gt.expires),Gt.cacheControl&&(nn.cacheControl=Gt.cacheControl);var bn={};if(Jt){var Bi=Jt.finish();Bi&&(bn.resourceTiming=JSON.parse(JSON.stringify(Bi)))}ar.vectorTile=Gt.vectorTile,ar.parse(Gt.vectorTile,At.layerIndex,At.availableImages,At.actor,function(on,dn){if(on||!dn)return $e(on);$e(null,y.extend({rawTileData:Tr.slice(0)},dn,nn,bn))}),At.loaded=At.loaded||{},At.loaded[Bt]=ar})},De.prototype.reloadTile=function(je,$e){var At=this,Bt=this.loaded,Jt=je.uid,ar=this;if(Bt&&Bt[Jt]){var hr=Bt[Jt];hr.showCollisionBoxes=je.showCollisionBoxes;var Gt=function(Tr,nn){var bn=hr.reloadCallback;bn&&(delete hr.reloadCallback,hr.parse(hr.vectorTile,ar.layerIndex,At.availableImages,ar.actor,bn)),$e(Tr,nn)};hr.status==="parsing"?hr.reloadCallback=Gt:hr.status==="done"&&(hr.vectorTile?hr.parse(hr.vectorTile,this.layerIndex,this.availableImages,this.actor,Gt):Gt())}},De.prototype.abortTile=function(je,$e){var At=this.loading,Bt=je.uid;At&&At[Bt]&&At[Bt].abort&&(At[Bt].abort(),delete At[Bt]),$e()},De.prototype.removeTile=function(je,$e){var At=this.loaded,Bt=je.uid;At&&At[Bt]&&delete At[Bt],$e()};var we=y.window.ImageBitmap,Ee=function(){this.loaded={}};function qe(je,$e){if(je.length!==0){Ge(je[0],$e);for(var At=1;At=Math.abs(Gt)?At-Tr+Gt:Gt-Tr+At,At=Tr}At+Bt>=0!=!!$e&&je.reverse()}Ee.prototype.loadTile=function(je,$e){var At=je.uid,Bt=je.encoding,Jt=je.rawImageData,ar=we&&Jt instanceof we?this.getImageData(Jt):Jt,hr=new y.DEMData(At,ar,Bt);this.loaded=this.loaded||{},this.loaded[At]=hr,$e(null,hr)},Ee.prototype.getImageData=function(je){this.offscreenCanvas&&this.offscreenCanvasContext||(this.offscreenCanvas=new OffscreenCanvas(je.width,je.height),this.offscreenCanvasContext=this.offscreenCanvas.getContext("2d")),this.offscreenCanvas.width=je.width,this.offscreenCanvas.height=je.height,this.offscreenCanvasContext.drawImage(je,0,0,je.width,je.height);var $e=this.offscreenCanvasContext.getImageData(-1,-1,je.width+2,je.height+2);return this.offscreenCanvasContext.clearRect(0,0,this.offscreenCanvas.width,this.offscreenCanvas.height),new y.RGBAImage({width:$e.width,height:$e.height},$e.data)},Ee.prototype.removeTile=function(je){var $e=this.loaded,At=je.uid;$e&&$e[At]&&delete $e[At]};var ct=y.vectorTile.VectorTileFeature.prototype.toGeoJSON,Ve=function(je){this._feature=je,this.extent=y.EXTENT,this.type=je.type,this.properties=je.tags,"id"in je&&!isNaN(je.id)&&(this.id=parseInt(je.id,10))};Ve.prototype.loadGeometry=function(){if(this._feature.type===1){for(var je=[],$e=0,At=this._feature.geometry;$e>31}function Se(je,$e){for(var At=je.loadGeometry(),Bt=je.type,Jt=0,ar=0,hr=At.length,Gt=0;Gt>1;(function di(zi,Gi,Lo,eo,ba,va){for(;ba>eo;){if(ba-eo>600){var Do=ba-eo+1,Ps=Lo-eo+1,Nr=Math.log(Do),fo=.5*Math.exp(2*Nr/3),hi=.5*Math.sqrt(Nr*fo*(Do-fo)/Do)*(Ps-Do/2<0?-1:1);di(zi,Gi,Lo,Math.max(eo,Math.floor(Lo-Ps*fo/Do+hi)),Math.min(ba,Math.floor(Lo+(Do-Ps)*fo/Do+hi)),va)}var Yi=Gi[2*Lo+va],ga=eo,Xi=ba;for(mt(zi,Gi,eo,Lo),Gi[2*ba+va]>Yi&&mt(zi,Gi,eo,ba);gaYi;)Xi--}Gi[2*eo+va]===Yi?mt(zi,Gi,eo,Xi):mt(zi,Gi,++Xi,ba),Xi<=Lo&&(eo=Xi+1),Lo<=Xi&&(ba=Xi-1)}})(bn,Bi,Rn,dn,ri,Wn%2),nn(bn,Bi,on,dn,Rn-1,Wn+1),nn(bn,Bi,on,Rn+1,ri,Wn+1)}})(hr,Gt,Bt,0,hr.length-1,0)};Qe.prototype.range=function(je,$e,At,Bt){return function(Jt,ar,hr,Gt,Tr,nn,bn){for(var Bi,on,dn=[0,Jt.length-1,0],ri=[];dn.length;){var Wn=dn.pop(),Rn=dn.pop(),di=dn.pop();if(Rn-di<=bn)for(var zi=di;zi<=Rn;zi++)on=ar[2*zi+1],(Bi=ar[2*zi])>=hr&&Bi<=Tr&&on>=Gt&&on<=nn&&ri.push(Jt[zi]);else{var Gi=Math.floor((di+Rn)/2);on=ar[2*Gi+1],(Bi=ar[2*Gi])>=hr&&Bi<=Tr&&on>=Gt&&on<=nn&&ri.push(Jt[Gi]);var Lo=(Wn+1)%2;(Wn===0?hr<=Bi:Gt<=on)&&(dn.push(di),dn.push(Gi-1),dn.push(Lo)),(Wn===0?Tr>=Bi:nn>=on)&&(dn.push(Gi+1),dn.push(Rn),dn.push(Lo))}}return ri}(this.ids,this.coords,je,$e,At,Bt,this.nodeSize)},Qe.prototype.within=function(je,$e,At){return function(Bt,Jt,ar,hr,Gt,Tr){for(var nn=[0,Bt.length-1,0],bn=[],Bi=Gt*Gt;nn.length;){var on=nn.pop(),dn=nn.pop(),ri=nn.pop();if(dn-ri<=Tr)for(var Wn=ri;Wn<=dn;Wn++)We(Jt[2*Wn],Jt[2*Wn+1],ar,hr)<=Bi&&bn.push(Bt[Wn]);else{var Rn=Math.floor((ri+dn)/2),di=Jt[2*Rn],zi=Jt[2*Rn+1];We(di,zi,ar,hr)<=Bi&&bn.push(Bt[Rn]);var Gi=(on+1)%2;(on===0?ar-Gt<=di:hr-Gt<=zi)&&(nn.push(ri),nn.push(Rn-1),nn.push(Gi)),(on===0?ar+Gt>=di:hr+Gt>=zi)&&(nn.push(Rn+1),nn.push(dn),nn.push(Gi))}}return bn}(this.ids,this.coords,je,$e,At,this.nodeSize)};var dr={minZoom:0,maxZoom:16,minPoints:2,radius:40,extent:512,nodeSize:64,log:!1,generateId:!1,reduce:null,map:function(je){return je}},Kt=function(je){this.options=_i(Object.create(dr),je),this.trees=new Array(this.options.maxZoom+1)};function Yr(je,$e,At,Bt,Jt){return{x:je,y:$e,zoom:1/0,id:At,parentId:-1,numPoints:Bt,properties:Jt}}function hn(je,$e){var At=je.geometry.coordinates,Bt=At[1];return{x:Nn(At[0]),y:$n(Bt),zoom:1/0,index:$e,parentId:-1}}function ln(je){return{type:"Feature",id:je.id,properties:oi(je),geometry:{type:"Point",coordinates:[(Bt=je.x,360*(Bt-.5)),($e=je.y,At=(180-360*$e)*Math.PI/180,360*Math.atan(Math.exp(At))/Math.PI-90)]}};var $e,At,Bt}function oi(je){var $e=je.numPoints,At=$e>=1e4?Math.round($e/1e3)+"k":$e>=1e3?Math.round($e/100)/10+"k":$e;return _i(_i({},je.properties),{cluster:!0,cluster_id:je.id,point_count:$e,point_count_abbreviated:At})}function Nn(je){return je/360+.5}function $n(je){var $e=Math.sin(je*Math.PI/180),At=.5-.25*Math.log((1+$e)/(1-$e))/Math.PI;return At<0?0:At>1?1:At}function _i(je,$e){for(var At in $e)je[At]=$e[At];return je}function Qn(je){return je.x}function Ji(je){return je.y}function ni(je,$e,At,Bt,Jt,ar){var hr=Jt-At,Gt=ar-Bt;if(hr!==0||Gt!==0){var Tr=((je-At)*hr+($e-Bt)*Gt)/(hr*hr+Gt*Gt);Tr>1?(At=Jt,Bt=ar):Tr>0&&(At+=hr*Tr,Bt+=Gt*Tr)}return(hr=je-At)*hr+(Gt=$e-Bt)*Gt}function Ei(je,$e,At,Bt){var Jt={id:je===void 0?null:je,type:$e,geometry:At,tags:Bt,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0};return function(ar){var hr=ar.geometry,Gt=ar.type;if(Gt==="Point"||Gt==="MultiPoint"||Gt==="LineString")xo(ar,hr);else if(Gt==="Polygon"||Gt==="MultiLineString")for(var Tr=0;Tr0&&(hr+=Bt?(Jt*nn-Tr*ar)/2:Math.sqrt(Math.pow(Tr-Jt,2)+Math.pow(nn-ar,2))),Jt=Tr,ar=nn}var bn=$e.length-3;$e[2]=1,function Bi(on,dn,ri,Wn){for(var Rn,di=Wn,zi=ri-dn>>1,Gi=ri-dn,Lo=on[dn],eo=on[dn+1],ba=on[ri],va=on[ri+1],Do=dn+3;Dodi)Rn=Do,di=Ps;else if(Ps===di){var Nr=Math.abs(Do-zi);NrWn&&(Rn-dn>3&&Bi(on,dn,Rn,Wn),on[Rn+2]=di,ri-Rn>3&&Bi(on,Rn,ri,Wn))}($e,0,bn,At),$e[bn+2]=1,$e.size=Math.abs(hr),$e.start=0,$e.end=$e.size}function or(je,$e,At,Bt){for(var Jt=0;Jt1?1:At}function Mo(je,$e,At,Bt,Jt,ar,hr,Gt){if(Bt/=$e,ar>=(At/=$e)&&hr=Bt)return null;for(var Tr=[],nn=0;nn=At&&ri=Bt)){var Wn=[];if(on==="Point"||on==="MultiPoint")Wi(Bi,Wn,At,Bt,Jt);else if(on==="LineString")Ii(Bi,Wn,At,Bt,Jt,!1,Gt.lineMetrics);else if(on==="MultiLineString")Fn(Bi,Wn,At,Bt,Jt,!1);else if(on==="Polygon")Fn(Bi,Wn,At,Bt,Jt,!0);else if(on==="MultiPolygon")for(var Rn=0;Rn=At&&hr<=Bt&&($e.push(je[ar]),$e.push(je[ar+1]),$e.push(je[ar+2]))}}function Ii(je,$e,At,Bt,Jt,ar,hr){for(var Gt,Tr,nn=ko(je),bn=Jt===0?Un:Hi,Bi=je.start,on=0;onAt&&(Tr=bn(nn,dn,ri,Rn,di,At),hr&&(nn.start=Bi+Gt*Tr)):zi>Bt?Gi=At&&(Tr=bn(nn,dn,ri,Rn,di,At),Lo=!0),Gi>Bt&&zi<=Bt&&(Tr=bn(nn,dn,ri,Rn,di,Bt),Lo=!0),!ar&&Lo&&(hr&&(nn.end=Bi+Gt*Tr),$e.push(nn),nn=ko(je)),hr&&(Bi+=Gt)}var eo=je.length-3;dn=je[eo],ri=je[eo+1],Wn=je[eo+2],(zi=Jt===0?dn:ri)>=At&&zi<=Bt&&zn(nn,dn,ri,Wn),eo=nn.length-3,ar&&eo>=3&&(nn[eo]!==nn[0]||nn[eo+1]!==nn[1])&&zn(nn,nn[0],nn[1],nn[2]),nn.length&&$e.push(nn)}function ko(je){var $e=[];return $e.size=je.size,$e.start=je.start,$e.end=je.end,$e}function Fn(je,$e,At,Bt,Jt,ar){for(var hr=0;hrhr.maxX&&(hr.maxX=bn),Bi>hr.maxY&&(hr.maxY=Bi)}return hr}function ir(je,$e,At,Bt){var Jt=$e.geometry,ar=$e.type,hr=[];if(ar==="Point"||ar==="MultiPoint")for(var Gt=0;Gt0&&$e.size<(Jt?hr:Bt))At.numPoints+=$e.length/3;else{for(var Gt=[],Tr=0;Tr<$e.length;Tr+=3)(Bt===0||$e[Tr+2]>hr)&&(At.numSimplified++,Gt.push($e[Tr]),Gt.push($e[Tr+1])),At.numPoints++;Jt&&function(nn,bn){for(var Bi=0,on=0,dn=nn.length,ri=dn-2;on0===bn)for(on=0,dn=nn.length;on24)throw new Error("maxZoom should be in the 0-24 range");if($e.promoteId&&$e.generateId)throw new Error("promoteId and generateId cannot be used together.");var Bt=function(Jt,ar){var hr=[];if(Jt.type==="FeatureCollection")for(var Gt=0;Gt=Bt;nn--){var bn=+Date.now();Gt=this._cluster(Gt,nn),this.trees[nn]=new Qe(Gt,Qn,Ji,ar,Float32Array),At&&console.log("z%d: %d clusters in %dms",nn,Gt.length,+Date.now()-bn)}return At&&console.timeEnd("total time"),this},Kt.prototype.getClusters=function(je,$e){var At=((je[0]+180)%360+360)%360-180,Bt=Math.max(-90,Math.min(90,je[1])),Jt=je[2]===180?180:((je[2]+180)%360+360)%360-180,ar=Math.max(-90,Math.min(90,je[3]));if(je[2]-je[0]>=360)At=-180,Jt=180;else if(At>Jt){var hr=this.getClusters([At,Bt,180,ar],$e),Gt=this.getClusters([-180,Bt,Jt,ar],$e);return hr.concat(Gt)}for(var Tr=this.trees[this._limitZoom($e)],nn=[],bn=0,Bi=Tr.range(Nn(At),$n(ar),Nn(Jt),$n(Bt));bn$e&&(on+=Wn.numPoints||1)}if(on>=ar){for(var Rn=Tr.x*Bi,di=Tr.y*Bi,zi=Jt&&Bi>1?this._map(Tr,!0):null,Gi=(Gt<<5)+($e+1)+this.points.length,Lo=0,eo=bn;Lo1)for(var Do=0,Ps=bn;Do>5},Kt.prototype._getOriginZoom=function(je){return(je-this.points.length)%32},Kt.prototype._map=function(je,$e){if(je.numPoints)return $e?_i({},je.properties):je.properties;var At=this.points[je.index].properties,Bt=this.options.map(At);return $e&&Bt===At?_i({},Bt):Bt},kr.prototype.options={maxZoom:14,indexMaxZoom:5,indexMaxPoints:1e5,tolerance:3,extent:4096,buffer:64,lineMetrics:!1,promoteId:null,generateId:!1,debug:0},kr.prototype.splitTile=function(je,$e,At,Bt,Jt,ar,hr){for(var Gt=[je,$e,At,Bt],Tr=this.options,nn=Tr.debug;Gt.length;){Bt=Gt.pop(),At=Gt.pop(),$e=Gt.pop(),je=Gt.pop();var bn=1<<$e,Bi=An($e,At,Bt),on=this.tiles[Bi];if(!on&&(nn>1&&console.time("creation"),on=this.tiles[Bi]=kt(je,$e,At,Bt,Tr),this.tileCoords.push({z:$e,x:At,y:Bt}),nn)){nn>1&&(console.log("tile z%d-%d-%d (features: %d, points: %d, simplified: %d)",$e,At,Bt,on.numFeatures,on.numPoints,on.numSimplified),console.timeEnd("creation"));var dn="z"+$e;this.stats[dn]=(this.stats[dn]||0)+1,this.total++}if(on.source=je,Jt){if($e===Tr.maxZoom||$e===Jt)continue;var ri=1<1&&console.time("clipping");var Wn,Rn,di,zi,Gi,Lo,eo=.5*Tr.buffer/Tr.extent,ba=.5-eo,va=.5+eo,Do=1+eo;Wn=Rn=di=zi=null,Gi=Mo(je,bn,At-eo,At+va,0,on.minX,on.maxX,Tr),Lo=Mo(je,bn,At+ba,At+Do,0,on.minX,on.maxX,Tr),je=null,Gi&&(Wn=Mo(Gi,bn,Bt-eo,Bt+va,1,on.minY,on.maxY,Tr),Rn=Mo(Gi,bn,Bt+ba,Bt+Do,1,on.minY,on.maxY,Tr),Gi=null),Lo&&(di=Mo(Lo,bn,Bt-eo,Bt+va,1,on.minY,on.maxY,Tr),zi=Mo(Lo,bn,Bt+ba,Bt+Do,1,on.minY,on.maxY,Tr),Lo=null),nn>1&&console.timeEnd("clipping"),Gt.push(Wn||[],$e+1,2*At,2*Bt),Gt.push(Rn||[],$e+1,2*At,2*Bt+1),Gt.push(di||[],$e+1,2*At+1,2*Bt),Gt.push(zi||[],$e+1,2*At+1,2*Bt+1)}}},kr.prototype.getTile=function(je,$e,At){var Bt=this.options,Jt=Bt.extent,ar=Bt.debug;if(je<0||je>24)return null;var hr=1<1&&console.log("drilling down to z%d-%d-%d",je,$e,At);for(var Tr,nn=je,bn=$e,Bi=At;!Tr&&nn>0;)nn--,bn=Math.floor(bn/2),Bi=Math.floor(Bi/2),Tr=this.tiles[An(nn,bn,Bi)];return Tr&&Tr.source?(ar>1&&console.log("found parent tile z%d-%d-%d",nn,bn,Bi),ar>1&&console.time("drilling down"),this.splitTile(Tr.source,nn,bn,Bi,je,$e,At),ar>1&&console.timeEnd("drilling down"),this.tiles[Gt]?xt(this.tiles[Gt],Jt):null):null};var Ht=function(je){function $e(At,Bt,Jt,ar){je.call(this,At,Bt,Jt,Dn),ar&&(this.loadGeoJSON=ar)}return je&&($e.__proto__=je),($e.prototype=Object.create(je&&je.prototype)).constructor=$e,$e.prototype.loadData=function(At,Bt){this._pendingCallback&&this._pendingCallback(null,{abandoned:!0}),this._pendingCallback=Bt,this._pendingLoadDataParams=At,this._state&&this._state!=="Idle"?this._state="NeedsLoadData":(this._state="Coalescing",this._loadData())},$e.prototype._loadData=function(){var At=this;if(this._pendingCallback&&this._pendingLoadDataParams){var Bt=this._pendingCallback,Jt=this._pendingLoadDataParams;delete this._pendingCallback,delete this._pendingLoadDataParams;var ar=!!(Jt&&Jt.request&&Jt.request.collectResourceTiming)&&new y.RequestPerformance(Jt.request);this.loadGeoJSON(Jt,function(hr,Gt){if(hr||!Gt)return Bt(hr);if(typeof Gt!="object")return Bt(new Error("Input data given to '"+Jt.source+"' is not a valid GeoJSON object."));(function on(dn,ri){var Wn,Rn=dn&&dn.type;if(Rn==="FeatureCollection")for(Wn=0;Wn=0?0:b.button},$.remove=function(b){b.parentNode&&b.parentNode.removeChild(b)};var Ge=function(b){function x(){b.call(this),this.images={},this.updatedImages={},this.callbackDispatchedThisFrame={},this.loaded=!1,this.requestors=[],this.patterns={},this.atlasImage=new y.RGBAImage({width:1,height:1}),this.dirty=!0}return b&&(x.__proto__=b),(x.prototype=Object.create(b&&b.prototype)).constructor=x,x.prototype.isLoaded=function(){return this.loaded},x.prototype.setLoaded=function(S){if(this.loaded!==S&&(this.loaded=S,S)){for(var U=0,pe=this.requestors;U=0?1.2:1))}function Rt(b,x,S,U,pe,Ce,Oe){for(var dt=0;dt65535)zt(new Error("glyphs > 65535 not supported"));else if(cr.ranges[zr])zt(null,{stack:Tt,id:Qt,glyph:pr});else{var jr=cr.requests[zr];jr||(jr=cr.requests[zr]=[],Ct.loadGlyphRange(Tt,zr,S.url,S.requestManager,function(tn,Hr){if(Hr){for(var fn in Hr)S._doesCharSupportLocalGlyph(+fn)||(cr.glyphs[+fn]=Hr[+fn]);cr.ranges[zr]=!0}for(var qt=0,ii=jr;qt1&&(dt=b[++Oe]);var Tt=Math.abs(zt-dt.left),Qt=Math.abs(zt-dt.right),cr=Math.min(Tt,Qt),pr=void 0,zr=pe/S*(U+1);if(dt.isDash){var jr=U-Math.abs(zr);pr=Math.sqrt(cr*cr+jr*jr)}else pr=U-Math.sqrt(cr*cr+zr*zr);this.data[Ce+zt]=Math.max(0,Math.min(255,pr+128))}},et.prototype.addRegularDash=function(b){for(var x=b.length-1;x>=0;--x){var S=b[x],U=b[x+1];S.zeroLength?b.splice(x,1):U&&U.isDash===S.isDash&&(U.left=S.left,b.splice(x,1))}var pe=b[0],Ce=b[b.length-1];pe.isDash===Ce.isDash&&(pe.left=Ce.left-this.width,Ce.right=pe.right+this.width);for(var Oe=this.width*this.nextRow,dt=0,zt=b[dt],Tt=0;Tt1&&(zt=b[++dt]);var Qt=Math.abs(Tt-zt.left),cr=Math.abs(Tt-zt.right),pr=Math.min(Qt,cr);this.data[Oe+Tt]=Math.max(0,Math.min(255,(zt.isDash?pr:-pr)+128))}},et.prototype.addDash=function(b,x){var S=x?7:0,U=2*S+1;if(this.nextRow+U>this.height)return y.warnOnce("LineAtlas out of space"),null;for(var pe=0,Ce=0;Ce=S&&b.x=U&&b.y0&&(Tt[new y.OverscaledTileID(S.overscaledZ,Oe,U.z,Ce,U.y-1).key]={backfilled:!1},Tt[new y.OverscaledTileID(S.overscaledZ,S.wrap,U.z,U.x,U.y-1).key]={backfilled:!1},Tt[new y.OverscaledTileID(S.overscaledZ,zt,U.z,dt,U.y-1).key]={backfilled:!1}),U.y+10&&(pe.resourceTiming=S._resourceTiming,S._resourceTiming=[]),S.fire(new y.Event("data",pe))}})},x.prototype.onAdd=function(S){this.map=S,this.load()},x.prototype.setData=function(S){var U=this;return this._data=S,this.fire(new y.Event("dataloading",{dataType:"source"})),this._updateWorkerData(function(pe){if(pe)U.fire(new y.ErrorEvent(pe));else{var Ce={dataType:"source",sourceDataType:"content"};U._collectResourceTiming&&U._resourceTiming&&U._resourceTiming.length>0&&(Ce.resourceTiming=U._resourceTiming,U._resourceTiming=[]),U.fire(new y.Event("data",Ce))}}),this},x.prototype.getClusterExpansionZoom=function(S,U){return this.actor.send("geojson.getClusterExpansionZoom",{clusterId:S,source:this.id},U),this},x.prototype.getClusterChildren=function(S,U){return this.actor.send("geojson.getClusterChildren",{clusterId:S,source:this.id},U),this},x.prototype.getClusterLeaves=function(S,U,pe,Ce){return this.actor.send("geojson.getClusterLeaves",{source:this.id,clusterId:S,limit:U,offset:pe},Ce),this},x.prototype._updateWorkerData=function(S){var U=this;this._loaded=!1;var pe=y.extend({},this.workerOptions),Ce=this._data;typeof Ce=="string"?(pe.request=this.map._requestManager.transformRequest(y.browser.resolveURL(Ce),y.ResourceType.Source),pe.request.collectResourceTiming=this._collectResourceTiming):pe.data=JSON.stringify(Ce),this.actor.send(this.type+".loadData",pe,function(Oe,dt){U._removed||dt&&dt.abandoned||(U._loaded=!0,dt&&dt.resourceTiming&&dt.resourceTiming[U.id]&&(U._resourceTiming=dt.resourceTiming[U.id].slice(0)),U.actor.send(U.type+".coalesce",{source:pe.source},null),S(Oe))})},x.prototype.loaded=function(){return this._loaded},x.prototype.loadTile=function(S,U){var pe=this,Ce=S.actor?"reloadTile":"loadTile";S.actor=this.actor,S.request=this.actor.send(Ce,{type:this.type,uid:S.uid,tileID:S.tileID,zoom:S.tileID.overscaledZ,maxZoom:this.maxzoom,tileSize:this.tileSize,source:this.id,pixelRatio:y.browser.devicePixelRatio,showCollisionBoxes:this.map.showCollisionBoxes,promoteId:this.promoteId},function(Oe,dt){return delete S.request,S.unloadVectorData(),S.aborted?U(null):Oe?U(Oe):(S.loadVectorData(dt,pe.map.painter,Ce==="reloadTile"),U(null))})},x.prototype.abortTile=function(S){S.request&&(S.request.cancel(),delete S.request),S.aborted=!0},x.prototype.unloadTile=function(S){S.unloadVectorData(),this.actor.send("removeTile",{uid:S.uid,type:this.type,source:this.id})},x.prototype.onRemove=function(){this._removed=!0,this.actor.send("removeSource",{type:this.type,source:this.id})},x.prototype.serialize=function(){return y.extend({},this._options,{type:this.type,data:this._data})},x.prototype.hasTransition=function(){return!1},x}(y.Evented),ot=y.createLayout([{name:"a_pos",type:"Int16",components:2},{name:"a_texture_pos",type:"Int16",components:2}]),We=function(b){function x(S,U,pe,Ce){b.call(this),this.id=S,this.dispatcher=pe,this.coordinates=U.coordinates,this.type="image",this.minzoom=0,this.maxzoom=22,this.tileSize=512,this.tiles={},this._loaded=!1,this.setEventedParent(Ce),this.options=U}return b&&(x.__proto__=b),(x.prototype=Object.create(b&&b.prototype)).constructor=x,x.prototype.load=function(S,U){var pe=this;this._loaded=!1,this.fire(new y.Event("dataloading",{dataType:"source"})),this.url=this.options.url,y.getImage(this.map._requestManager.transformRequest(this.url,y.ResourceType.Image),function(Ce,Oe){pe._loaded=!0,Ce?pe.fire(new y.ErrorEvent(Ce)):Oe&&(pe.image=Oe,S&&(pe.coordinates=S),U&&U(),pe._finishLoading())})},x.prototype.loaded=function(){return this._loaded},x.prototype.updateImage=function(S){var U=this;return this.image&&S.url?(this.options.url=S.url,this.load(S.coordinates,function(){U.texture=null}),this):this},x.prototype._finishLoading=function(){this.map&&(this.setCoordinates(this.coordinates),this.fire(new y.Event("data",{dataType:"source",sourceDataType:"metadata"})))},x.prototype.onAdd=function(S){this.map=S,this.load()},x.prototype.setCoordinates=function(S){var U=this;this.coordinates=S;var pe=S.map(y.MercatorCoordinate.fromLngLat);this.tileID=function(Oe){for(var dt=1/0,zt=1/0,Tt=-1/0,Qt=-1/0,cr=0,pr=Oe;crU.end(0)?this.fire(new y.ErrorEvent(new y.ValidationError("sources."+this.id,null,"Playback for this video can be set only between the "+U.start(0)+" and "+U.end(0)+"-second mark."))):this.video.currentTime=S}},x.prototype.getVideo=function(){return this.video},x.prototype.onAdd=function(S){this.map||(this.map=S,this.load(),this.video&&(this.video.play(),this.setCoordinates(this.coordinates)))},x.prototype.prepare=function(){if(!(Object.keys(this.tiles).length===0||this.video.readyState<2)){var S=this.map.painter.context,U=S.gl;for(var pe in this.boundsBuffer||(this.boundsBuffer=S.createVertexBuffer(this._boundsArray,ot.members)),this.boundsSegments||(this.boundsSegments=y.SegmentVector.simpleSegment(0,0,4,2)),this.texture?this.video.paused||(this.texture.bind(U.LINEAR,U.CLAMP_TO_EDGE),U.texSubImage2D(U.TEXTURE_2D,0,0,0,U.RGBA,U.UNSIGNED_BYTE,this.video)):(this.texture=new y.Texture(S,this.video,U.RGBA),this.texture.bind(U.LINEAR,U.CLAMP_TO_EDGE)),this.tiles){var Ce=this.tiles[pe];Ce.state!=="loaded"&&(Ce.state="loaded",Ce.texture=this.texture)}}},x.prototype.serialize=function(){return{type:"video",urls:this.urls,coordinates:this.coordinates}},x.prototype.hasTransition=function(){return this.video&&!this.video.paused},x}(We),st=function(b){function x(S,U,pe,Ce){b.call(this,S,U,pe,Ce),U.coordinates?Array.isArray(U.coordinates)&&U.coordinates.length===4&&!U.coordinates.some(function(Oe){return!Array.isArray(Oe)||Oe.length!==2||Oe.some(function(dt){return typeof dt!="number"})})||this.fire(new y.ErrorEvent(new y.ValidationError("sources."+S,null,'"coordinates" property must be an array of 4 longitude/latitude array pairs'))):this.fire(new y.ErrorEvent(new y.ValidationError("sources."+S,null,'missing required property "coordinates"'))),U.animate&&typeof U.animate!="boolean"&&this.fire(new y.ErrorEvent(new y.ValidationError("sources."+S,null,'optional "animate" property must be a boolean value'))),U.canvas?typeof U.canvas=="string"||U.canvas instanceof y.window.HTMLCanvasElement||this.fire(new y.ErrorEvent(new y.ValidationError("sources."+S,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 y.ErrorEvent(new y.ValidationError("sources."+S,null,'missing required property "canvas"'))),this.options=U,this.animate=U.animate===void 0||U.animate}return b&&(x.__proto__=b),(x.prototype=Object.create(b&&b.prototype)).constructor=x,x.prototype.load=function(){this._loaded=!0,this.canvas||(this.canvas=this.options.canvas instanceof y.window.HTMLCanvasElement?this.options.canvas:y.window.document.getElementById(this.options.canvas)),this.width=this.canvas.width,this.height=this.canvas.height,this._hasInvalidDimensions()?this.fire(new y.ErrorEvent(new Error("Canvas dimensions cannot be less than or equal to zero."))):(this.play=function(){this._playing=!0,this.map.triggerRepaint()},this.pause=function(){this._playing&&(this.prepare(),this._playing=!1)},this._finishLoading())},x.prototype.getCanvas=function(){return this.canvas},x.prototype.onAdd=function(S){this.map=S,this.load(),this.canvas&&this.animate&&this.play()},x.prototype.onRemove=function(){this.pause()},x.prototype.prepare=function(){var S=!1;if(this.canvas.width!==this.width&&(this.width=this.canvas.width,S=!0),this.canvas.height!==this.height&&(this.height=this.canvas.height,S=!0),!this._hasInvalidDimensions()&&Object.keys(this.tiles).length!==0){var U=this.map.painter.context,pe=U.gl;for(var Ce in this.boundsBuffer||(this.boundsBuffer=U.createVertexBuffer(this._boundsArray,ot.members)),this.boundsSegments||(this.boundsSegments=y.SegmentVector.simpleSegment(0,0,4,2)),this.texture?(S||this._playing)&&this.texture.update(this.canvas,{premultiply:!0}):this.texture=new y.Texture(U,this.canvas,pe.RGBA,{premultiply:!0}),this.tiles){var Oe=this.tiles[Ce];Oe.state!=="loaded"&&(Oe.state="loaded",Oe.texture=this.texture)}}},x.prototype.serialize=function(){return{type:"canvas",coordinates:this.coordinates}},x.prototype.hasTransition=function(){return this._playing},x.prototype._hasInvalidDimensions=function(){for(var S=0,U=[this.canvas.width,this.canvas.height];Sthis.max){var Oe=this._getAndRemoveByKey(this.order[0]);Oe&&this.onRemove(Oe)}return this},hn.prototype.has=function(b){return b.wrapped().key in this.data},hn.prototype.getAndRemove=function(b){return this.has(b)?this._getAndRemoveByKey(b.wrapped().key):null},hn.prototype._getAndRemoveByKey=function(b){var x=this.data[b].shift();return x.timeout&&clearTimeout(x.timeout),this.data[b].length===0&&delete this.data[b],this.order.splice(this.order.indexOf(b),1),x.value},hn.prototype.getByKey=function(b){var x=this.data[b];return x?x[0].value:null},hn.prototype.get=function(b){return this.has(b)?this.data[b.wrapped().key][0].value:null},hn.prototype.remove=function(b,x){if(!this.has(b))return this;var S=b.wrapped().key,U=x===void 0?0:this.data[S].indexOf(x),pe=this.data[S][U];return this.data[S].splice(U,1),pe.timeout&&clearTimeout(pe.timeout),this.data[S].length===0&&delete this.data[S],this.onRemove(pe.value),this.order.splice(this.order.indexOf(S),1),this},hn.prototype.setMaxSize=function(b){for(this.max=b;this.order.length>this.max;){var x=this._getAndRemoveByKey(this.order[0]);x&&this.onRemove(x)}return this},hn.prototype.filter=function(b){var x=[];for(var S in this.data)for(var U=0,pe=this.data[S];U1||(Math.abs(Qt)>1&&(Math.abs(Qt+pr)===1?Qt+=pr:Math.abs(Qt-pr)===1&&(Qt-=pr)),Tt.dem&&zt.dem&&(zt.dem.backfillBorder(Tt.dem,Qt,cr),zt.neighboringTiles&&zt.neighboringTiles[zr]&&(zt.neighboringTiles[zr].backfilled=!0)))}},x.prototype.getTile=function(S){return this.getTileByID(S.key)},x.prototype.getTileByID=function(S){return this._tiles[S]},x.prototype._retainLoadedChildren=function(S,U,pe,Ce){for(var Oe in this._tiles){var dt=this._tiles[Oe];if(!(Ce[Oe]||!dt.hasData()||dt.tileID.overscaledZ<=U||dt.tileID.overscaledZ>pe)){for(var zt=dt.tileID;dt&&dt.tileID.overscaledZ>U+1;){var Tt=dt.tileID.scaledTo(dt.tileID.overscaledZ-1);(dt=this._tiles[Tt.key])&&dt.hasData()&&(zt=Tt)}for(var Qt=zt;Qt.overscaledZ>U;)if(S[(Qt=Qt.scaledTo(Qt.overscaledZ-1)).key]){Ce[zt.key]=zt;break}}}},x.prototype.findLoadedParent=function(S,U){if(S.key in this._loadedParentTiles){var pe=this._loadedParentTiles[S.key];return pe&&pe.tileID.overscaledZ>=U?pe:null}for(var Ce=S.overscaledZ-1;Ce>=U;Ce--){var Oe=S.scaledTo(Ce),dt=this._getLoadedTile(Oe);if(dt)return dt}},x.prototype._getLoadedTile=function(S){var U=this._tiles[S.key];return U&&U.hasData()?U:this._cache.getByKey(S.wrapped().key)},x.prototype.updateCacheSize=function(S){var U=Math.ceil(S.width/this._source.tileSize)+1,pe=Math.ceil(S.height/this._source.tileSize)+1,Ce=Math.floor(U*pe*5),Oe=typeof this._maxTileCacheSize=="number"?Math.min(this._maxTileCacheSize,Ce):Ce;this._cache.setMaxSize(Oe)},x.prototype.handleWrapJump=function(S){var U=Math.round((S-(this._prevLng===void 0?S:this._prevLng))/360);if(this._prevLng=S,U){var pe={};for(var Ce in this._tiles){var Oe=this._tiles[Ce];Oe.tileID=Oe.tileID.unwrapTo(Oe.tileID.wrap+U),pe[Oe.tileID.key]=Oe}for(var dt in this._tiles=pe,this._timers)clearTimeout(this._timers[dt]),delete this._timers[dt];for(var zt in this._tiles)this._setTileReloadTimer(zt,this._tiles[zt])}},x.prototype.update=function(S){var U=this;if(this.transform=S,this._sourceLoaded&&!this._paused){var pe;this.updateCacheSize(S),this.handleWrapJump(this.transform.center.lng),this._coveredTiles={},this.used?this._source.tileID?pe=S.getVisibleUnwrappedCoordinates(this._source.tileID).map(function(uo){return new y.OverscaledTileID(uo.canonical.z,uo.wrap,uo.canonical.z,uo.canonical.x,uo.canonical.y)}):(pe=S.coveringTiles({tileSize:this._source.tileSize,minzoom:this._source.minzoom,maxzoom:this._source.maxzoom,roundZoom:this._source.roundZoom,reparseOverscaled:this._source.reparseOverscaled}),this._source.hasTile&&(pe=pe.filter(function(uo){return U._source.hasTile(uo)}))):pe=[];var Ce=S.coveringZoomLevel(this._source),Oe=Math.max(Ce-x.maxOverzooming,this._source.minzoom),dt=Math.max(Ce+x.maxUnderzooming,this._source.minzoom),zt=this._updateRetainedTiles(pe,Ce);if(bn(this._source.type)){for(var Tt={},Qt={},cr=0,pr=Object.keys(zt);crthis._source.maxzoom){var fn=tn.children(this._source.maxzoom)[0],qt=this.getTile(fn);if(qt&&qt.hasData()){pe[fn.key]=fn;continue}}else{var ii=tn.children(this._source.maxzoom);if(pe[ii[0].key]&&pe[ii[1].key]&&pe[ii[2].key]&&pe[ii[3].key])continue}for(var Ai=Hr.wasRequested(),xr=tn.overscaledZ-1;xr>=Oe;--xr){var Ni=tn.scaledTo(xr);if(Ce[Ni.key]||(Ce[Ni.key]=!0,!(Hr=this.getTile(Ni))&&Ai&&(Hr=this._addTile(Ni)),Hr&&(pe[Ni.key]=Ni,Ai=Hr.wasRequested(),Hr.hasData())))break}}}return pe},x.prototype._updateLoadedParentTileCache=function(){for(var S in this._loadedParentTiles={},this._tiles){for(var U=[],pe=void 0,Ce=this._tiles[S].tileID;Ce.overscaledZ>0;){if(Ce.key in this._loadedParentTiles){pe=this._loadedParentTiles[Ce.key];break}U.push(Ce.key);var Oe=Ce.scaledTo(Ce.overscaledZ-1);if(pe=this._getLoadedTile(Oe))break;Ce=Oe}for(var dt=0,zt=U;dt0||(U.hasData()&&U.state!=="reloading"?this._cache.add(U.tileID,U,U.getExpiryTimeout()):(U.aborted=!0,this._abortTile(U),this._unloadTile(U))))},x.prototype.clearTiles=function(){for(var S in this._shouldReloadOnResume=!1,this._paused=!1,this._tiles)this._removeTile(S);this._cache.reset()},x.prototype.tilesIn=function(S,U,pe){var Ce=this,Oe=[],dt=this.transform;if(!dt)return Oe;for(var zt=pe?dt.getCameraQueryGeometry(S):S,Tt=S.map(function(xr){return dt.pointCoordinate(xr)}),Qt=zt.map(function(xr){return dt.pointCoordinate(xr)}),cr=this.getIds(),pr=1/0,zr=1/0,jr=-1/0,tn=-1/0,Hr=0,fn=Qt;Hr=0&&Fs[1].y+da>=0){var hu=Tt.map(function(Zu){return uo.getTilePoint(Zu)}),qr=Qt.map(function(Zu){return uo.getTilePoint(Zu)});Oe.push({tile:Ni,tileID:uo,queryGeometry:hu,cameraQueryGeometry:qr,scale:oa})}}},Ai=0;Ai=y.browser.now())return!0}return!1},x.prototype.setFeatureState=function(S,U,pe){this._state.updateState(S=S||"_geojsonTileLayer",U,pe)},x.prototype.removeFeatureState=function(S,U,pe){this._state.removeFeatureState(S=S||"_geojsonTileLayer",U,pe)},x.prototype.getFeatureState=function(S,U){return this._state.getState(S=S||"_geojsonTileLayer",U)},x.prototype.setDependencies=function(S,U,pe){var Ce=this._tiles[S];Ce&&Ce.setDependencies(U,pe)},x.prototype.reloadTilesForDependencies=function(S,U){for(var pe in this._tiles)this._tiles[pe].hasDependency(S,U)&&this._reloadTile(pe,"reloading");this._cache.filter(function(Ce){return!Ce.hasDependency(S,U)})},x}(y.Evented);function nn(b,x){var S=Math.abs(2*b.wrap)-+(b.wrap<0),U=Math.abs(2*x.wrap)-+(x.wrap<0);return b.overscaledZ-x.overscaledZ||U-S||x.canonical.y-b.canonical.y||x.canonical.x-b.canonical.x}function bn(b){return b==="raster"||b==="image"||b==="video"}function Bi(){return new y.window.Worker(Wt.workerUrl)}Tr.maxOverzooming=10,Tr.maxUnderzooming=3;var on="mapboxgl_preloaded_worker_pool",dn=function(){this.active={}};dn.prototype.acquire=function(b){if(!this.workers)for(this.workers=[];this.workers.length0?(U-Ce)/Oe:0;return this.points[pe].mult(1-dt).add(this.points[x].mult(dt))};var hi=function(b,x,S){var U=this.boxCells=[],pe=this.circleCells=[];this.xCellCount=Math.ceil(b/S),this.yCellCount=Math.ceil(x/S);for(var Ce=0;Ce=-x[0]&&S<=x[0]&&U>=-x[1]&&U<=x[1]}function ol(b,x,S,U,pe,Ce,Oe,dt){var zt=U?b.textSizeData:b.iconSizeData,Tt=y.evaluateSizeForZoom(zt,S.transform.zoom),Qt=[256/S.width*2+1,256/S.height*2+1],cr=U?b.text.dynamicLayoutVertexArray:b.icon.dynamicLayoutVertexArray;cr.clear();for(var pr=b.lineVertexArray,zr=U?b.text.placedSymbolArray:b.icon.placedSymbolArray,jr=S.transform.width/S.transform.height,tn=!1,Hr=0;HrMath.abs(S.x-x.x)*U?{useVertical:!0}:(b===y.WritingMode.vertical?x.yS.x)?{needsFlipping:!0}:null}function _s(b,x,S,U,pe,Ce,Oe,dt,zt,Tt,Qt,cr,pr,zr){var jr,tn=x/24,Hr=b.lineOffsetX*tn,fn=b.lineOffsetY*tn;if(b.numGlyphs>1){var qt=b.glyphStartIndex+b.numGlyphs,ii=b.lineStartIndex,Ai=b.lineStartIndex+b.lineLength,xr=ks(tn,dt,Hr,fn,S,Qt,cr,b,zt,Ce,pr);if(!xr)return{notEnoughRoom:!0};var Ni=Xi(xr.first.point,Oe).point,uo=Xi(xr.last.point,Oe).point;if(U&&!S){var oa=as(b.writingMode,Ni,uo,zr);if(oa)return oa}jr=[xr.first];for(var da=b.glyphStartIndex+1;da0?Zu.point:Ks(cr,qr,Fs,1,pe),ou=as(b.writingMode,Fs,Bc,zr);if(ou)return ou}var rl=Ea(tn*dt.getoffsetX(b.glyphStartIndex),Hr,fn,S,Qt,cr,b.segment,b.lineStartIndex,b.lineStartIndex+b.lineLength,zt,Ce,pr);if(!rl)return{notEnoughRoom:!0};jr=[rl]}for(var Nc=0,Cc=jr;Nc0?1:-1,jr=0;U&&(zr*=-1,jr=Math.PI),zr<0&&(jr+=Math.PI);for(var tn=zr>0?dt+Oe:dt+Oe+1,Hr=pe,fn=pe,qt=0,ii=0,Ai=Math.abs(pr),xr=[];qt+ii<=Ai;){if((tn+=zr)=zt)return null;if(fn=Hr,xr.push(Hr),(Hr=cr[tn])===void 0){var Ni=new y.Point(Tt.getx(tn),Tt.gety(tn)),uo=Xi(Ni,Qt);if(uo.signedDistanceFromCamera>0)Hr=cr[tn]=uo.point;else{var oa=tn-zr;Hr=Ks(qt===0?Ce:new y.Point(Tt.getx(oa),Tt.gety(oa)),Ni,fn,Ai-qt+1,Qt)}}qt+=ii,ii=fn.dist(Hr)}var da=(Ai-qt)/ii,Fs=Hr.sub(fn),hu=Fs.mult(da)._add(fn);hu._add(Fs._unit()._perp()._mult(S*zr));var qr=jr+Math.atan2(Hr.y-fn.y,Hr.x-fn.x);return xr.push(hu),{point:hu,angle:qr,path:xr}}hi.prototype.keysLength=function(){return this.boxKeys.length+this.circleKeys.length},hi.prototype.insert=function(b,x,S,U,pe){this._forEachCell(x,S,U,pe,this._insertBoxCell,this.boxUid++),this.boxKeys.push(b),this.bboxes.push(x),this.bboxes.push(S),this.bboxes.push(U),this.bboxes.push(pe)},hi.prototype.insertCircle=function(b,x,S,U){this._forEachCell(x-U,S-U,x+U,S+U,this._insertCircleCell,this.circleUid++),this.circleKeys.push(b),this.circles.push(x),this.circles.push(S),this.circles.push(U)},hi.prototype._insertBoxCell=function(b,x,S,U,pe,Ce){this.boxCells[pe].push(Ce)},hi.prototype._insertCircleCell=function(b,x,S,U,pe,Ce){this.circleCells[pe].push(Ce)},hi.prototype._query=function(b,x,S,U,pe,Ce){if(S<0||b>this.width||U<0||x>this.height)return!pe&&[];var Oe=[];if(b<=0&&x<=0&&this.width<=S&&this.height<=U){if(pe)return!0;for(var dt=0;dt0:Oe},hi.prototype._queryCircle=function(b,x,S,U,pe){var Ce=b-S,Oe=b+S,dt=x-S,zt=x+S;if(Oe<0||Ce>this.width||zt<0||dt>this.height)return!U&&[];var Tt=[];return this._forEachCell(Ce,dt,Oe,zt,this._queryCellCircle,Tt,{hitTest:U,circle:{x:b,y:x,radius:S},seenUids:{box:{},circle:{}}},pe),U?Tt.length>0:Tt},hi.prototype.query=function(b,x,S,U,pe){return this._query(b,x,S,U,!1,pe)},hi.prototype.hitTest=function(b,x,S,U,pe){return this._query(b,x,S,U,!0,pe)},hi.prototype.hitTestCircle=function(b,x,S,U){return this._queryCircle(b,x,S,!0,U)},hi.prototype._queryCell=function(b,x,S,U,pe,Ce,Oe,dt){var zt=Oe.seenUids,Tt=this.boxCells[pe];if(Tt!==null)for(var Qt=this.bboxes,cr=0,pr=Tt;cr=Qt[jr+0]&&U>=Qt[jr+1]&&(!dt||dt(this.boxKeys[zr]))){if(Oe.hitTest)return Ce.push(!0),!0;Ce.push({key:this.boxKeys[zr],x1:Qt[jr],y1:Qt[jr+1],x2:Qt[jr+2],y2:Qt[jr+3]})}}}var tn=this.circleCells[pe];if(tn!==null)for(var Hr=this.circles,fn=0,qt=tn;fnOe*Oe+dt*dt},hi.prototype._circleAndRectCollide=function(b,x,S,U,pe,Ce,Oe){var dt=(Ce-U)/2,zt=Math.abs(b-(U+dt));if(zt>dt+S)return!1;var Tt=(Oe-pe)/2,Qt=Math.abs(x-(pe+Tt));if(Qt>Tt+S)return!1;if(zt<=dt||Qt<=Tt)return!0;var cr=zt-dt,pr=Qt-Tt;return cr*cr+pr*pr<=S*S};var hs=new Float32Array([-1/0,-1/0,0,-1/0,-1/0,0,-1/0,-1/0,0,-1/0,-1/0,0]);function Ju(b,x){for(var S=0;S=1;Bc--)Zu.push(hu.path[Bc]);for(var ou=1;ou0){for(var Gl=Zu[0].clone(),Oc=Zu[0].clone(),bc=1;bc=oa.x&&Oc.x<=da.x&&Gl.y>=oa.y&&Oc.y<=da.y?[Zu]:Oc.xda.x||Oc.yda.y?[]:y.clipLine([Zu],oa.x,oa.y,da.x,da.y)}for(var wu=0,rf=Cc;wu=this.screenRightBoundary||U<100||x>this.screenBottomBoundary},dc.prototype.isInsideGrid=function(b,x,S,U){return S>=0&&b=0&&x0?(this.prevPlacement&&this.prevPlacement.variableOffsets[cr.crossTileID]&&this.prevPlacement.placements[cr.crossTileID]&&this.prevPlacement.placements[cr.crossTileID].text&&(tn=this.prevPlacement.variableOffsets[cr.crossTileID].anchor),this.variableOffsets[cr.crossTileID]={textOffset:Hr,width:S,height:U,anchor:b,textBoxScale:pe,prevAnchor:tn},this.markUsedJustification(pr,b,cr,zr),pr.allowVerticalPlacement&&(this.markUsedOrientation(pr,zr,cr),this.placedOrientations[cr.crossTileID]=zr),{shift:fn,placedGlyphBoxes:qt}):void 0},Ci.prototype.placeLayerBucketPart=function(b,x,S){var U=this,pe=b.parameters,Ce=pe.bucket,Oe=pe.layout,dt=pe.posMatrix,zt=pe.textLabelPlaneMatrix,Tt=pe.labelToScreenMatrix,Qt=pe.textPixelRatio,cr=pe.holdingForFade,pr=pe.collisionBoxArray,zr=pe.partiallyEvaluatedTextSize,jr=pe.collisionGroup,tn=Oe.get("text-optional"),Hr=Oe.get("icon-optional"),fn=Oe.get("text-allow-overlap"),qt=Oe.get("icon-allow-overlap"),ii=Oe.get("text-rotation-alignment")==="map",Ai=Oe.get("text-pitch-alignment")==="map",xr=Oe.get("icon-text-fit")!=="none",Ni=Oe.get("symbol-z-order")==="viewport-y",uo=fn&&(qt||!Ce.hasIconData()||Hr),oa=qt&&(fn||!Ce.hasTextData()||tn);!Ce.collisionArrays&&pr&&Ce.deserializeCollisionBoxes(pr);var da=function(ou,rl){if(!x[ou.crossTileID])if(cr)U.placements[ou.crossTileID]=new Rl(!1,!1,!1);else{var Nc,Cc=!1,Gl=!1,Oc=!0,bc=null,wu={box:null,offscreen:null},rf={box:null,offscreen:null},xf=null,Kh=null,Zf=0,sc=0,Kf=0;rl.textFeatureIndex?Zf=rl.textFeatureIndex:ou.useRuntimeCollisionCircles&&(Zf=ou.featureIndex),rl.verticalTextFeatureIndex&&(sc=rl.verticalTextFeatureIndex);var nh=rl.textBox;if(nh){var Rh=function(Tc){var Vf=y.WritingMode.horizontal;if(Ce.allowVerticalPlacement&&!Tc&&U.prevPlacement){var Zh=U.prevPlacement.placedOrientations[ou.crossTileID];Zh&&(U.placedOrientations[ou.crossTileID]=Zh,U.markUsedOrientation(Ce,Vf=Zh,ou))}return Vf},Ff=function(Tc,Vf){if(Ce.allowVerticalPlacement&&ou.numVerticalGlyphVertices>0&&rl.verticalTextBox)for(var Zh=0,dd=Ce.writingModes;Zh0&&(kd=kd.filter(function(Tc){return Tc!==Ud.anchor})).unshift(Ud.anchor)}var Qh=function(Tc,Vf,Zh){for(var dd=Tc.x2-Tc.x1,Jh=Tc.y2-Tc.y1,g0=ou.textBoxScale,b0=xr&&!qt?Vf:null,Gp={box:[],offscreen:!1},Wp=fn?2*kd.length:kd.length,xp=0;xp=kd.length,ou,Ce,Zh,b0);if(U0&&(Gp=U0.placedGlyphBoxes)&&Gp.box&&Gp.box.length){Cc=!0,bc=U0.shift;break}}return Gp};Ff(function(){return Qh(nh,rl.iconBox,y.WritingMode.horizontal)},function(){var Tc=rl.verticalTextBox;return Ce.allowVerticalPlacement&&!(wu&&wu.box&&wu.box.length)&&ou.numVerticalGlyphVertices>0&&Tc?Qh(Tc,rl.verticalIconBox,y.WritingMode.vertical):{box:null,offscreen:null}}),wu&&(Cc=wu.box,Oc=wu.offscreen);var jh=Rh(wu&&wu.box);if(!Cc&&U.prevPlacement){var xh=U.prevPlacement.variableOffsets[ou.crossTileID];xh&&(U.variableOffsets[ou.crossTileID]=xh,U.markUsedJustification(Ce,xh.anchor,ou,jh))}}else{var qf=function(Tc,Vf){var Zh=U.collisionIndex.placeCollisionBox(Tc,fn,Qt,dt,jr.predicate);return Zh&&Zh.box&&Zh.box.length&&(U.markUsedOrientation(Ce,Vf,ou),U.placedOrientations[ou.crossTileID]=Vf),Zh};Ff(function(){return qf(nh,y.WritingMode.horizontal)},function(){var Tc=rl.verticalTextBox;return Ce.allowVerticalPlacement&&ou.numVerticalGlyphVertices>0&&Tc?qf(Tc,y.WritingMode.vertical):{box:null,offscreen:null}}),Rh(wu&&wu.box&&wu.box.length)}}if(Cc=(Nc=wu)&&Nc.box&&Nc.box.length>0,Oc=Nc&&Nc.offscreen,ou.useRuntimeCollisionCircles){var hd=Ce.text.placedSymbolArray.get(ou.centerJustifiedTextSymbolIndex),nd=y.evaluateSizeForFeature(Ce.textSizeData,zr,hd),id=Oe.get("text-padding");xf=U.collisionIndex.placeCollisionCircles(fn,hd,Ce.lineVertexArray,Ce.glyphOffsetArray,nd,dt,zt,Tt,S,Ai,jr.predicate,ou.collisionCircleDiameter,id),Cc=fn||xf.circles.length>0&&!xf.collisionDetected,Oc=Oc&&xf.offscreen}if(rl.iconFeatureIndex&&(Kf=rl.iconFeatureIndex),rl.iconBox){var Hp=function(Tc){var Vf=xr&&bc?Wr(Tc,bc.x,bc.y,ii,Ai,U.transform.angle):Tc;return U.collisionIndex.placeCollisionBox(Vf,qt,Qt,dt,jr.predicate)};Gl=rf&&rf.box&&rf.box.length&&rl.verticalIconBox?(Kh=Hp(rl.verticalIconBox)).box.length>0:(Kh=Hp(rl.iconBox)).box.length>0,Oc=Oc&&Kh.offscreen}var mc=tn||ou.numHorizontalGlyphVertices===0&&ou.numVerticalGlyphVertices===0,Cd=Hr||ou.numIconVertices===0;if(mc||Cd?Cd?mc||(Gl=Gl&&Cc):Cc=Gl&&Cc:Gl=Cc=Gl&&Cc,Cc&&Nc&&Nc.box&&U.collisionIndex.insertCollisionBox(Nc.box,Oe.get("text-ignore-placement"),Ce.bucketInstanceId,rf&&rf.box&&sc?sc:Zf,jr.ID),Gl&&Kh&&U.collisionIndex.insertCollisionBox(Kh.box,Oe.get("icon-ignore-placement"),Ce.bucketInstanceId,Kf,jr.ID),xf&&(Cc&&U.collisionIndex.insertCollisionCircles(xf.circles,Oe.get("text-ignore-placement"),Ce.bucketInstanceId,Zf,jr.ID),S)){var od=Ce.bucketInstanceId,lf=U.collisionCircleArrays[od];lf===void 0&&(lf=U.collisionCircleArrays[od]=new dl);for(var Dp=0;Dp=0;--hu){var qr=Fs[hu];da(Ce.symbolInstances.get(qr),Ce.collisionArrays[qr])}else for(var Zu=b.symbolInstanceStart;Zu=0&&(b.text.placedSymbolArray.get(dt).crossTileID=pe>=0&&dt!==pe?0:S.crossTileID)}},Ci.prototype.markUsedOrientation=function(b,x,S){for(var U=x===y.WritingMode.horizontal||x===y.WritingMode.horizontalOnly?x:0,pe=x===y.WritingMode.vertical?x:0,Ce=0,Oe=[S.leftJustifiedTextSymbolIndex,S.centerJustifiedTextSymbolIndex,S.rightJustifiedTextSymbolIndex];Ce0,oa=U.placedOrientations[qt.crossTileID],da=oa===y.WritingMode.vertical,Fs=oa===y.WritingMode.horizontal||oa===y.WritingMode.horizontalOnly;if(ii>0||Ai>0){var hu=mn(Ni.text);zr(b.text,ii,da?Lr:hu),zr(b.text,Ai,Fs?Lr:hu);var qr=Ni.text.isHidden();[qt.rightJustifiedTextSymbolIndex,qt.centerJustifiedTextSymbolIndex,qt.leftJustifiedTextSymbolIndex].forEach(function(wu){wu>=0&&(b.text.placedSymbolArray.get(wu).hidden=qr||da?1:0)}),qt.verticalPlacedTextSymbolIndex>=0&&(b.text.placedSymbolArray.get(qt.verticalPlacedTextSymbolIndex).hidden=qr||Fs?1:0);var Zu=U.variableOffsets[qt.crossTileID];Zu&&U.markUsedJustification(b,Zu.anchor,qt,oa);var Bc=U.placedOrientations[qt.crossTileID];Bc&&(U.markUsedJustification(b,"left",qt,Bc),U.markUsedOrientation(b,Bc,qt))}if(uo){var ou=mn(Ni.icon),rl=!(cr&&qt.verticalPlacedIconSymbolIndex&&da);qt.placedIconSymbolIndex>=0&&(zr(b.icon,qt.numIconVertices,rl?ou:Lr),b.icon.placedSymbolArray.get(qt.placedIconSymbolIndex).hidden=Ni.icon.isHidden()),qt.verticalPlacedIconSymbolIndex>=0&&(zr(b.icon,qt.numVerticalIconVertices,rl?Lr:ou),b.icon.placedSymbolArray.get(qt.verticalPlacedIconSymbolIndex).hidden=Ni.icon.isHidden())}if(b.hasIconCollisionBoxData()||b.hasTextCollisionBoxData()){var Nc=b.collisionArrays[fn];if(Nc){var Cc=new y.Point(0,0);if(Nc.textBox||Nc.verticalTextBox){var Gl=!0;if(zt){var Oc=U.variableOffsets[xr];Oc?(Cc=Pn(Oc.anchor,Oc.width,Oc.height,Oc.textOffset,Oc.textBoxScale),Tt&&Cc._rotate(Qt?U.transform.angle:-U.transform.angle)):Gl=!1}Nc.textBox&&at(b.textCollisionBox.collisionVertexArray,Ni.text.placed,!Gl||da,Cc.x,Cc.y),Nc.verticalTextBox&&at(b.textCollisionBox.collisionVertexArray,Ni.text.placed,!Gl||Fs,Cc.x,Cc.y)}var bc=!!(!Fs&&Nc.verticalIconBox);Nc.iconBox&&at(b.iconCollisionBox.collisionVertexArray,Ni.icon.placed,bc,cr?Cc.x:0,cr?Cc.y:0),Nc.verticalIconBox&&at(b.iconCollisionBox.collisionVertexArray,Ni.icon.placed,!bc,cr?Cc.x:0,cr?Cc.y:0)}}},tn=0;tnb},Ci.prototype.setStale=function(){this.stale=!0};var Vt=Math.pow(2,25),gr=Math.pow(2,24),gn=Math.pow(2,17),un=Math.pow(2,16),Zi=Math.pow(2,9),ho=Math.pow(2,8),Na=Math.pow(2,1);function mn(b){if(b.opacity===0&&!b.placed)return 0;if(b.opacity===1&&b.placed)return 4294967295;var x=b.placed?1:0,S=Math.floor(127*b.opacity);return S*Vt+x*gr+S*gn+x*un+S*Zi+x*ho+S*Na+x}var Lr=0,yr=function(b){this._sortAcrossTiles=b.layout.get("symbol-z-order")!=="viewport-y"&&b.layout.get("symbol-sort-key").constantOr(1)!==void 0,this._currentTileIndex=0,this._currentPartIndex=0,this._seenCrossTileIDs={},this._bucketParts=[]};yr.prototype.continuePlacement=function(b,x,S,U,pe){for(var Ce=this._bucketParts;this._currentTileIndex2};this._currentPlacementIndex>=0;){var Oe=x[b[this._currentPlacementIndex]],dt=this.placement.collisionIndex.transform.zoom;if(Oe.type==="symbol"&&(!Oe.minzoom||Oe.minzoom<=dt)&&(!Oe.maxzoom||Oe.maxzoom>dt)){if(this._inProgressLayer||(this._inProgressLayer=new yr(Oe)),this._inProgressLayer.continuePlacement(S[Oe.source],this.placement,this._showCollisionBoxes,Oe,Ce))return;delete this._inProgressLayer}this._currentPlacementIndex--}this._done=!0},Mr.prototype.commit=function(b){return this.placement.commit(b),this.placement};var Zr=512/y.EXTENT/2,Vn=function(b,x,S){this.tileID=b,this.indexedSymbolInstances={},this.bucketInstanceId=S;for(var U=0;Ub.overscaledZ)for(var dt in Oe){var zt=Oe[dt];zt.tileID.isChildOf(b)&&zt.findMatches(x.symbolInstances,b,pe)}else{var Tt=Oe[b.scaledTo(Number(Ce)).key];Tt&&Tt.findMatches(x.symbolInstances,b,pe)}}for(var Qt=0;Qt1?"@2x":"",cr=y.getJSON(Ce.transformRequest(Ce.normalizeSpriteURL(pe,Qt,".json"),y.ResourceType.SpriteJSON),function(jr,tn){cr=null,Tt||(Tt=jr,dt=tn,zr())}),pr=y.getImage(Ce.transformRequest(Ce.normalizeSpriteURL(pe,Qt,".png"),y.ResourceType.SpriteImage),function(jr,tn){pr=null,Tt||(Tt=jr,zt=tn,zr())});function zr(){if(Tt)Oe(Tt);else if(dt&&zt){var jr=y.browser.getImageData(zt),tn={};for(var Hr in dt){var fn=dt[Hr],qt=fn.width,ii=fn.height,Ai=fn.x,xr=fn.y,Ni=fn.sdf,uo=fn.pixelRatio,oa=fn.stretchX,da=fn.stretchY,Fs=fn.content,hu=new y.RGBAImage({width:qt,height:ii});y.RGBAImage.copy(jr,hu,{x:Ai,y:xr},{x:0,y:0},{width:qt,height:ii}),tn[Hr]={data:hu,pixelRatio:uo,sdf:Ni,stretchX:oa,stretchY:da,content:Fs}}Oe(null,tn)}}return{cancel:function(){cr&&(cr.cancel(),cr=null),pr&&(pr.cancel(),pr=null)}}}(S,this.map._requestManager,function(pe,Ce){if(U._spriteRequest=null,pe)U.fire(new y.ErrorEvent(pe));else if(Ce)for(var Oe in Ce)U.imageManager.addImage(Oe,Ce[Oe]);U.imageManager.setLoaded(!0),U._availableImages=U.imageManager.listImages(),U.dispatcher.broadcast("setImages",U._availableImages),U.fire(new y.Event("data",{dataType:"style"}))})},x.prototype._validateLayer=function(S){var U=this.sourceCaches[S.source];if(U){var pe=S.sourceLayer;if(pe){var Ce=U.getSource();(Ce.type==="geojson"||Ce.vectorLayerIds&&Ce.vectorLayerIds.indexOf(pe)===-1)&&this.fire(new y.ErrorEvent(new Error('Source layer "'+pe+'" does not exist on source "'+Ce.id+'" as specified by style layer "'+S.id+'"')))}}},x.prototype.loaded=function(){if(!this._loaded||Object.keys(this._updatedSources).length)return!1;for(var S in this.sourceCaches)if(!this.sourceCaches[S].loaded())return!1;return!!this.imageManager.isLoaded()},x.prototype._serializeLayers=function(S){for(var U=[],pe=0,Ce=S;pe0)throw new Error("Unimplemented: "+Ce.map(function(Oe){return Oe.command}).join(", ")+".");return pe.forEach(function(Oe){Oe.command!=="setTransition"&&U[Oe.command].apply(U,Oe.args)}),this.stylesheet=S,!0},x.prototype.addImage=function(S,U){if(this.getImage(S))return this.fire(new y.ErrorEvent(new Error("An image with this name already exists.")));this.imageManager.addImage(S,U),this._afterImageUpdated(S)},x.prototype.updateImage=function(S,U){this.imageManager.updateImage(S,U)},x.prototype.getImage=function(S){return this.imageManager.getImage(S)},x.prototype.removeImage=function(S){if(!this.getImage(S))return this.fire(new y.ErrorEvent(new Error("No image with this name exists.")));this.imageManager.removeImage(S),this._afterImageUpdated(S)},x.prototype._afterImageUpdated=function(S){this._availableImages=this.imageManager.listImages(),this._changedImages[S]=!0,this._changed=!0,this.dispatcher.broadcast("setImages",this._availableImages),this.fire(new y.Event("data",{dataType:"style"}))},x.prototype.listImages=function(){return this._checkLoaded(),this.imageManager.listImages()},x.prototype.addSource=function(S,U,pe){var Ce=this;if(pe===void 0&&(pe={}),this._checkLoaded(),this.sourceCaches[S]!==void 0)throw new Error("There is already a source with this ID");if(!U.type)throw new Error("The type property must be defined, but only the following properties were given: "+Object.keys(U).join(", ")+".");if(!(["vector","raster","geojson","video","image"].indexOf(U.type)>=0&&this._validate(y.validateStyle.source,"sources."+S,U,null,pe))){this.map&&this.map._collectResourceTiming&&(U.collectResourceTiming=!0);var Oe=this.sourceCaches[S]=new Tr(S,U,this.dispatcher);Oe.style=this,Oe.setEventedParent(this,function(){return{isSourceLoaded:Ce.loaded(),source:Oe.serialize(),sourceId:S}}),Oe.onAdd(this.map),this._changed=!0}},x.prototype.removeSource=function(S){if(this._checkLoaded(),this.sourceCaches[S]===void 0)throw new Error("There is no source with this ID");for(var U in this._layers)if(this._layers[U].source===S)return this.fire(new y.ErrorEvent(new Error('Source "'+S+'" cannot be removed while layer "'+U+'" is using it.')));var pe=this.sourceCaches[S];delete this.sourceCaches[S],delete this._updatedSources[S],pe.fire(new y.Event("data",{sourceDataType:"metadata",dataType:"source",sourceId:S})),pe.setEventedParent(null),pe.clearTiles(),pe.onRemove&&pe.onRemove(this.map),this._changed=!0},x.prototype.setGeoJSONSourceData=function(S,U){this._checkLoaded(),this.sourceCaches[S].getSource().setData(U),this._changed=!0},x.prototype.getSource=function(S){return this.sourceCaches[S]&&this.sourceCaches[S].getSource()},x.prototype.addLayer=function(S,U,pe){pe===void 0&&(pe={}),this._checkLoaded();var Ce=S.id;if(this.getLayer(Ce))this.fire(new y.ErrorEvent(new Error('Layer with id "'+Ce+'" already exists on this map')));else{var Oe;if(S.type==="custom"){if(so(this,y.validateCustomStyleLayer(S)))return;Oe=y.createStyleLayer(S)}else{if(typeof S.source=="object"&&(this.addSource(Ce,S.source),S=y.clone$1(S),S=y.extend(S,{source:Ce})),this._validate(y.validateStyle.layer,"layers."+Ce,S,{arrayIndex:-1},pe))return;Oe=y.createStyleLayer(S),this._validateLayer(Oe),Oe.setEventedParent(this,{layer:{id:Ce}}),this._serializedLayers[Oe.id]=Oe.serialize()}var dt=U?this._order.indexOf(U):this._order.length;if(U&&dt===-1)this.fire(new y.ErrorEvent(new Error('Layer with id "'+U+'" does not exist on this map.')));else{if(this._order.splice(dt,0,Ce),this._layerOrderChanged=!0,this._layers[Ce]=Oe,this._removedLayers[Ce]&&Oe.source&&Oe.type!=="custom"){var zt=this._removedLayers[Ce];delete this._removedLayers[Ce],zt.type!==Oe.type?this._updatedSources[Oe.source]="clear":(this._updatedSources[Oe.source]="reload",this.sourceCaches[Oe.source].pause())}this._updateLayer(Oe),Oe.onAdd&&Oe.onAdd(this.map)}}},x.prototype.moveLayer=function(S,U){if(this._checkLoaded(),this._changed=!0,this._layers[S]){if(S!==U){var pe=this._order.indexOf(S);this._order.splice(pe,1);var Ce=U?this._order.indexOf(U):this._order.length;U&&Ce===-1?this.fire(new y.ErrorEvent(new Error('Layer with id "'+U+'" does not exist on this map.'))):(this._order.splice(Ce,0,S),this._layerOrderChanged=!0)}}else this.fire(new y.ErrorEvent(new Error("The layer '"+S+"' does not exist in the map's style and cannot be moved.")))},x.prototype.removeLayer=function(S){this._checkLoaded();var U=this._layers[S];if(U){U.setEventedParent(null);var pe=this._order.indexOf(S);this._order.splice(pe,1),this._layerOrderChanged=!0,this._changed=!0,this._removedLayers[S]=U,delete this._layers[S],delete this._serializedLayers[S],delete this._updatedLayers[S],delete this._updatedPaintProps[S],U.onRemove&&U.onRemove(this.map)}else this.fire(new y.ErrorEvent(new Error("The layer '"+S+"' does not exist in the map's style and cannot be removed.")))},x.prototype.getLayer=function(S){return this._layers[S]},x.prototype.hasLayer=function(S){return S in this._layers},x.prototype.setLayerZoomRange=function(S,U,pe){this._checkLoaded();var Ce=this.getLayer(S);Ce?Ce.minzoom===U&&Ce.maxzoom===pe||(U!=null&&(Ce.minzoom=U),pe!=null&&(Ce.maxzoom=pe),this._updateLayer(Ce)):this.fire(new y.ErrorEvent(new Error("The layer '"+S+"' does not exist in the map's style and cannot have zoom extent.")))},x.prototype.setFilter=function(S,U,pe){pe===void 0&&(pe={}),this._checkLoaded();var Ce=this.getLayer(S);if(Ce){if(!y.deepEqual(Ce.filter,U))return U==null?(Ce.filter=void 0,void this._updateLayer(Ce)):void(this._validate(y.validateStyle.filter,"layers."+Ce.id+".filter",U,null,pe)||(Ce.filter=y.clone$1(U),this._updateLayer(Ce)))}else this.fire(new y.ErrorEvent(new Error("The layer '"+S+"' does not exist in the map's style and cannot be filtered.")))},x.prototype.getFilter=function(S){return y.clone$1(this.getLayer(S).filter)},x.prototype.setLayoutProperty=function(S,U,pe,Ce){Ce===void 0&&(Ce={}),this._checkLoaded();var Oe=this.getLayer(S);Oe?y.deepEqual(Oe.getLayoutProperty(U),pe)||(Oe.setLayoutProperty(U,pe,Ce),this._updateLayer(Oe)):this.fire(new y.ErrorEvent(new Error("The layer '"+S+"' does not exist in the map's style and cannot be styled.")))},x.prototype.getLayoutProperty=function(S,U){var pe=this.getLayer(S);if(pe)return pe.getLayoutProperty(U);this.fire(new y.ErrorEvent(new Error("The layer '"+S+"' does not exist in the map's style.")))},x.prototype.setPaintProperty=function(S,U,pe,Ce){Ce===void 0&&(Ce={}),this._checkLoaded();var Oe=this.getLayer(S);Oe?y.deepEqual(Oe.getPaintProperty(U),pe)||(Oe.setPaintProperty(U,pe,Ce)&&this._updateLayer(Oe),this._changed=!0,this._updatedPaintProps[S]=!0):this.fire(new y.ErrorEvent(new Error("The layer '"+S+"' does not exist in the map's style and cannot be styled.")))},x.prototype.getPaintProperty=function(S,U){return this.getLayer(S).getPaintProperty(U)},x.prototype.setFeatureState=function(S,U){this._checkLoaded();var pe=S.source,Ce=S.sourceLayer,Oe=this.sourceCaches[pe];if(Oe!==void 0){var dt=Oe.getSource().type;dt==="geojson"&&Ce?this.fire(new y.ErrorEvent(new Error("GeoJSON sources cannot have a sourceLayer parameter."))):dt!=="vector"||Ce?(S.id===void 0&&this.fire(new y.ErrorEvent(new Error("The feature id parameter must be provided."))),Oe.setFeatureState(Ce,S.id,U)):this.fire(new y.ErrorEvent(new Error("The sourceLayer parameter must be provided for vector source types.")))}else this.fire(new y.ErrorEvent(new Error("The source '"+pe+"' does not exist in the map's style.")))},x.prototype.removeFeatureState=function(S,U){this._checkLoaded();var pe=S.source,Ce=this.sourceCaches[pe];if(Ce!==void 0){var Oe=Ce.getSource().type,dt=Oe==="vector"?S.sourceLayer:void 0;Oe!=="vector"||dt?U&&typeof S.id!="string"&&typeof S.id!="number"?this.fire(new y.ErrorEvent(new Error("A feature id is required to remove its specific state property."))):Ce.removeFeatureState(dt,S.id,U):this.fire(new y.ErrorEvent(new Error("The sourceLayer parameter must be provided for vector source types.")))}else this.fire(new y.ErrorEvent(new Error("The source '"+pe+"' does not exist in the map's style.")))},x.prototype.getFeatureState=function(S){this._checkLoaded();var U=S.source,pe=S.sourceLayer,Ce=this.sourceCaches[U];if(Ce!==void 0){if(Ce.getSource().type!=="vector"||pe)return S.id===void 0&&this.fire(new y.ErrorEvent(new Error("The feature id parameter must be provided."))),Ce.getFeatureState(pe,S.id);this.fire(new y.ErrorEvent(new Error("The sourceLayer parameter must be provided for vector source types.")))}else this.fire(new y.ErrorEvent(new Error("The source '"+U+"' does not exist in the map's style.")))},x.prototype.getTransition=function(){return y.extend({duration:300,delay:0},this.stylesheet&&this.stylesheet.transition)},x.prototype.serialize=function(){return y.filterObject({version:this.stylesheet.version,name:this.stylesheet.name,metadata:this.stylesheet.metadata,light:this.stylesheet.light,center:this.stylesheet.center,zoom:this.stylesheet.zoom,bearing:this.stylesheet.bearing,pitch:this.stylesheet.pitch,sprite:this.stylesheet.sprite,glyphs:this.stylesheet.glyphs,transition:this.stylesheet.transition,sources:y.mapObject(this.sourceCaches,function(S){return S.serialize()}),layers:this._serializeLayers(this._order)},function(S){return S!==void 0})},x.prototype._updateLayer=function(S){this._updatedLayers[S.id]=!0,S.source&&!this._updatedSources[S.source]&&this.sourceCaches[S.source].getSource().type!=="raster"&&(this._updatedSources[S.source]="reload",this.sourceCaches[S.source].pause()),this._changed=!0},x.prototype._flattenAndSortRenderedFeatures=function(S){for(var U=this,pe=function(oa){return U._layers[oa].type==="fill-extrusion"},Ce={},Oe=[],dt=this._order.length-1;dt>=0;dt--){var zt=this._order[dt];if(pe(zt)){Ce[zt]=dt;for(var Tt=0,Qt=S;Tt=0;tn--){var Hr=this._order[tn];if(pe(Hr))for(var fn=Oe.length-1;fn>=0;fn--){var qt=Oe[fn].feature;if(Ce[qt.layer.id] 0.5) {gl_FragColor=vec4(0.0,0.0,1.0,0.5)*alpha;}if (v_notUsed > 0.5) {gl_FragColor*=.1;}}","attribute vec2 a_pos;attribute vec2 a_anchor_pos;attribute vec2 a_extrude;attribute vec2 a_placed;attribute vec2 a_shift;uniform mat4 u_matrix;uniform vec2 u_extrude_scale;uniform float u_camera_to_center_distance;varying float v_placed;varying float v_notUsed;void main() {vec4 projectedPoint=u_matrix*vec4(a_anchor_pos,0,1);highp float camera_to_anchor_distance=projectedPoint.w;highp float collision_perspective_ratio=clamp(0.5+0.5*(u_camera_to_center_distance/camera_to_anchor_distance),0.0,4.0);gl_Position=u_matrix*vec4(a_pos,0.0,1.0);gl_Position.xy+=(a_extrude+a_shift)*u_extrude_scale*gl_Position.w*collision_perspective_ratio;v_placed=a_placed.x;v_notUsed=a_placed.y;}"),Hu=Aa("varying float v_radius;varying vec2 v_extrude;varying float v_perspective_ratio;varying float v_collision;void main() {float alpha=0.5*min(v_perspective_ratio,1.0);float stroke_radius=0.9*max(v_perspective_ratio,1.0);float distance_to_center=length(v_extrude);float distance_to_edge=abs(distance_to_center-v_radius);float opacity_t=smoothstep(-stroke_radius,0.0,-distance_to_edge);vec4 color=mix(vec4(0.0,0.0,1.0,0.5),vec4(1.0,0.0,0.0,1.0),v_collision);gl_FragColor=color*alpha*opacity_t;}","attribute vec2 a_pos;attribute float a_radius;attribute vec2 a_flags;uniform mat4 u_matrix;uniform mat4 u_inv_matrix;uniform vec2 u_viewport_size;uniform float u_camera_to_center_distance;varying float v_radius;varying vec2 v_extrude;varying float v_perspective_ratio;varying float v_collision;vec3 toTilePosition(vec2 screenPos) {vec4 rayStart=u_inv_matrix*vec4(screenPos,-1.0,1.0);vec4 rayEnd =u_inv_matrix*vec4(screenPos, 1.0,1.0);rayStart.xyz/=rayStart.w;rayEnd.xyz /=rayEnd.w;highp float t=(0.0-rayStart.z)/(rayEnd.z-rayStart.z);return mix(rayStart.xyz,rayEnd.xyz,t);}void main() {vec2 quadCenterPos=a_pos;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;vec3 tilePos=toTilePosition(quadCenterPos);vec4 clipPos=u_matrix*vec4(tilePos,1.0);highp float camera_to_anchor_distance=clipPos.w;highp float collision_perspective_ratio=clamp(0.5+0.5*(u_camera_to_center_distance/camera_to_anchor_distance),0.0,4.0);float padding_factor=1.2;v_radius=radius;v_extrude=quadVertexExtent*padding_factor;v_perspective_ratio=collision_perspective_ratio;v_collision=collision;gl_Position=vec4(clipPos.xyz/clipPos.w,1.0)+vec4(quadVertexExtent*padding_factor/u_viewport_size*2.0,0.0,0.0);}"),Of=Aa("uniform highp vec4 u_color;uniform sampler2D u_overlay;varying vec2 v_uv;void main() {vec4 overlay_color=texture2D(u_overlay,v_uv);gl_FragColor=mix(u_color,overlay_color,overlay_color.a);}","attribute vec2 a_pos;varying vec2 v_uv;uniform mat4 u_matrix;uniform float u_overlay_scale;void main() {v_uv=a_pos/8192.0;gl_Position=u_matrix*vec4(a_pos*u_overlay_scale,0,1);}"),en=Aa(`#pragma mapbox: define highp vec4 color +#pragma mapbox: define lowp float opacity +void main() { +#pragma mapbox: initialize highp vec4 color +#pragma mapbox: initialize lowp float opacity +gl_FragColor=color*opacity; +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,`attribute vec2 a_pos;uniform mat4 u_matrix; +#pragma mapbox: define highp vec4 color +#pragma mapbox: define lowp float opacity +void main() { +#pragma mapbox: initialize highp vec4 color +#pragma mapbox: initialize lowp float opacity +gl_Position=u_matrix*vec4(a_pos,0,1);}`),xn=Aa(`varying vec2 v_pos; +#pragma mapbox: define highp vec4 outline_color +#pragma mapbox: define lowp float opacity +void main() { +#pragma mapbox: initialize highp vec4 outline_color +#pragma mapbox: initialize lowp float opacity +float dist=length(v_pos-gl_FragCoord.xy);float alpha=1.0-smoothstep(0.0,1.0,dist);gl_FragColor=outline_color*(alpha*opacity); +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,`attribute vec2 a_pos;uniform mat4 u_matrix;uniform vec2 u_world;varying vec2 v_pos; +#pragma mapbox: define highp vec4 outline_color +#pragma mapbox: define lowp float opacity +void main() { +#pragma mapbox: initialize highp vec4 outline_color +#pragma mapbox: initialize lowp float opacity +gl_Position=u_matrix*vec4(a_pos,0,1);v_pos=(gl_Position.xy/gl_Position.w+1.0)/2.0*u_world;}`),Vi=Aa(`uniform vec2 u_texsize;uniform sampler2D u_image;uniform float u_fade;varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec2 v_pos; +#pragma mapbox: define lowp float opacity +#pragma mapbox: define lowp vec4 pattern_from +#pragma mapbox: define lowp vec4 pattern_to +void main() { +#pragma mapbox: initialize lowp float opacity +#pragma mapbox: initialize mediump vec4 pattern_from +#pragma mapbox: initialize mediump vec4 pattern_to +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;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(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=texture2D(u_image,pos2);float dist=length(v_pos-gl_FragCoord.xy);float alpha=1.0-smoothstep(0.0,1.0,dist);gl_FragColor=mix(color1,color2,u_fade)*alpha*opacity; +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,`uniform mat4 u_matrix;uniform vec2 u_world;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform vec3 u_scale;attribute vec2 a_pos;varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec2 v_pos; +#pragma mapbox: define lowp float opacity +#pragma mapbox: define lowp vec4 pattern_from +#pragma mapbox: define lowp vec4 pattern_to +#pragma mapbox: define lowp float pixel_ratio_from +#pragma mapbox: define lowp float pixel_ratio_to +void main() { +#pragma mapbox: initialize lowp float opacity +#pragma mapbox: initialize mediump vec4 pattern_from +#pragma mapbox: initialize mediump vec4 pattern_to +#pragma mapbox: initialize lowp float pixel_ratio_from +#pragma mapbox: initialize lowp float pixel_ratio_to +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=u_matrix*vec4(a_pos,0,1);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;}`),wi=Aa(`uniform vec2 u_texsize;uniform float u_fade;uniform sampler2D u_image;varying vec2 v_pos_a;varying vec2 v_pos_b; +#pragma mapbox: define lowp float opacity +#pragma mapbox: define lowp vec4 pattern_from +#pragma mapbox: define lowp vec4 pattern_to +void main() { +#pragma mapbox: initialize lowp float opacity +#pragma mapbox: initialize mediump vec4 pattern_from +#pragma mapbox: initialize mediump vec4 pattern_to +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;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(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=texture2D(u_image,pos2);gl_FragColor=mix(color1,color2,u_fade)*opacity; +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,`uniform mat4 u_matrix;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform vec3 u_scale;attribute vec2 a_pos;varying vec2 v_pos_a;varying vec2 v_pos_b; +#pragma mapbox: define lowp float opacity +#pragma mapbox: define lowp vec4 pattern_from +#pragma mapbox: define lowp vec4 pattern_to +#pragma mapbox: define lowp float pixel_ratio_from +#pragma mapbox: define lowp float pixel_ratio_to +void main() { +#pragma mapbox: initialize lowp float opacity +#pragma mapbox: initialize mediump vec4 pattern_from +#pragma mapbox: initialize mediump vec4 pattern_to +#pragma mapbox: initialize lowp float pixel_ratio_from +#pragma mapbox: initialize lowp float pixel_ratio_to +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=u_matrix*vec4(a_pos,0,1);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);}`),oo=Aa(`varying vec4 v_color;void main() {gl_FragColor=v_color; +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,`uniform mat4 u_matrix;uniform vec3 u_lightcolor;uniform lowp vec3 u_lightpos;uniform lowp float u_lightintensity;uniform float u_vertical_gradient;uniform lowp float u_opacity;attribute vec2 a_pos;attribute vec4 a_normal_ed;varying vec4 v_color; +#pragma mapbox: define highp float base +#pragma mapbox: define highp float height +#pragma mapbox: define highp vec4 color +void main() { +#pragma mapbox: initialize highp float base +#pragma mapbox: initialize highp float height +#pragma mapbox: initialize highp vec4 color +vec3 normal=a_normal_ed.xyz;base=max(0.0,base);height=max(0.0,height);float t=mod(normal.x,2.0);gl_Position=u_matrix*vec4(a_pos,t > 0.0 ? height : base,1);float 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;float directional=clamp(dot(normal/16384.0,u_lightpos),0.0,1.0);directional=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;}`),io=Aa(`uniform vec2 u_texsize;uniform float u_fade;uniform sampler2D u_image;varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec4 v_lighting; +#pragma mapbox: define lowp float base +#pragma mapbox: define lowp float height +#pragma mapbox: define lowp vec4 pattern_from +#pragma mapbox: define lowp vec4 pattern_to +#pragma mapbox: define lowp float pixel_ratio_from +#pragma mapbox: define lowp float pixel_ratio_to +void main() { +#pragma mapbox: initialize lowp float base +#pragma mapbox: initialize lowp float height +#pragma mapbox: initialize mediump vec4 pattern_from +#pragma mapbox: initialize mediump vec4 pattern_to +#pragma mapbox: initialize lowp float pixel_ratio_from +#pragma mapbox: initialize lowp float pixel_ratio_to +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;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(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=texture2D(u_image,pos2);vec4 mixedColor=mix(color1,color2,u_fade);gl_FragColor=mixedColor*v_lighting; +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,`uniform mat4 u_matrix;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 vec3 u_lightcolor;uniform lowp vec3 u_lightpos;uniform lowp float u_lightintensity;attribute vec2 a_pos;attribute vec4 a_normal_ed;varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec4 v_lighting; +#pragma mapbox: define lowp float base +#pragma mapbox: define lowp float height +#pragma mapbox: define lowp vec4 pattern_from +#pragma mapbox: define lowp vec4 pattern_to +#pragma mapbox: define lowp float pixel_ratio_from +#pragma mapbox: define lowp float pixel_ratio_to +void main() { +#pragma mapbox: initialize lowp float base +#pragma mapbox: initialize lowp float height +#pragma mapbox: initialize mediump vec4 pattern_from +#pragma mapbox: initialize mediump vec4 pattern_to +#pragma mapbox: initialize lowp float pixel_ratio_from +#pragma mapbox: initialize lowp float pixel_ratio_to +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;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;base=max(0.0,base);height=max(0.0,height);float t=mod(normal.x,2.0);float z=t > 0.0 ? height : base;gl_Position=u_matrix*vec4(a_pos,z,1);vec2 pos=normal.x==1.0 && normal.y==0.0 && normal.z==16384.0 +? a_pos +: vec2(edgedistance,z*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;}`),Uo=Aa(`#ifdef GL_ES +precision highp float; +#endif +uniform sampler2D u_image;varying vec2 v_pos;uniform vec2 u_dimension;uniform float u_zoom;uniform vec4 u_unpack;float getElevation(vec2 coord,float bias) {vec4 data=texture2D(u_image,coord)*255.0;data.a=-1.0;return dot(data,u_unpack)/4.0;}void main() {vec2 epsilon=1.0/u_dimension;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))/pow(2.0,exaggeration+(19.2562-u_zoom));gl_FragColor=clamp(vec4(deriv.x/2.0+0.5,deriv.y/2.0+0.5,1.0,1.0),0.0,1.0); +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,"uniform mat4 u_matrix;uniform vec2 u_dimension;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);highp vec2 epsilon=1.0/u_dimension;float scale=(u_dimension.x-2.0)/u_dimension.x;v_pos=(a_texture_pos/8192.0)*scale+epsilon;}"),na=Aa(`uniform sampler2D u_image;varying vec2 v_pos;uniform vec2 u_latrange;uniform vec2 u_light;uniform vec4 u_shadow;uniform vec4 u_highlight;uniform vec4 u_accent; +#define PI 3.141592653589793 +void main() {vec4 pixel=texture2D(u_image,v_pos);vec2 deriv=((pixel.rg*2.0)-1.0);float scaleFactor=cos(radians((u_latrange[0]-u_latrange[1])*(1.0-v_pos.y)+u_latrange[1]));float slope=atan(1.25*length(deriv)/scaleFactor);float aspect=deriv.x !=0.0 ? atan(deriv.y,-deriv.x) : PI/2.0*(deriv.y > 0.0 ? 1.0 :-1.0);float intensity=u_light.x;float azimuth=u_light.y+PI;float base=1.875-intensity*1.75;float maxValue=0.5*PI;float scaledSlope=intensity !=0.5 ? ((pow(base,slope)-1.0)/(pow(base,maxValue)-1.0))*maxValue : slope;float accent=cos(scaledSlope);vec4 accent_color=(1.0-accent)*u_accent*clamp(intensity*2.0,0.0,1.0);float shade=abs(mod((aspect+azimuth)/PI+0.5,2.0)-1.0);vec4 shade_color=mix(u_shadow,u_highlight,shade)*sin(scaledSlope)*clamp(intensity*2.0,0.0,1.0);gl_FragColor=accent_color*(1.0-shade_color.a)+shade_color; +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,"uniform mat4 u_matrix;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);v_pos=a_texture_pos/8192.0;}"),$a=Aa(`uniform lowp float u_device_pixel_ratio;varying vec2 v_width2;varying vec2 v_normal;varying float v_gamma_scale; +#pragma mapbox: define highp vec4 color +#pragma mapbox: define lowp float blur +#pragma mapbox: define lowp float opacity +void main() { +#pragma mapbox: initialize highp vec4 color +#pragma mapbox: initialize lowp float blur +#pragma mapbox: initialize lowp float opacity +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);gl_FragColor=color*(alpha*opacity); +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,` +#define scale 0.015873016 +attribute vec2 a_pos_normal;attribute vec4 a_data;uniform mat4 u_matrix;uniform mediump float u_ratio;uniform vec2 u_units_to_pixels;uniform lowp float u_device_pixel_ratio;varying vec2 v_normal;varying vec2 v_width2;varying float v_gamma_scale;varying highp float v_linesofar; +#pragma mapbox: define highp vec4 color +#pragma mapbox: define lowp float blur +#pragma mapbox: define lowp float opacity +#pragma mapbox: define mediump float gapwidth +#pragma mapbox: define lowp float offset +#pragma mapbox: define mediump float width +void main() { +#pragma mapbox: initialize highp vec4 color +#pragma mapbox: initialize lowp float blur +#pragma mapbox: initialize lowp float opacity +#pragma mapbox: initialize mediump float gapwidth +#pragma mapbox: initialize lowp float offset +#pragma mapbox: initialize mediump float width +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);vec4 projected_extrude=u_matrix*vec4(dist/u_ratio,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2/u_ratio,0.0,1.0)+projected_extrude;float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;v_width2=vec2(outset,inset);}`),Co=Aa(`uniform lowp float u_device_pixel_ratio;uniform sampler2D u_image;varying vec2 v_width2;varying vec2 v_normal;varying float v_gamma_scale;varying highp vec2 v_uv; +#pragma mapbox: define lowp float blur +#pragma mapbox: define lowp float opacity +void main() { +#pragma mapbox: initialize lowp float blur +#pragma mapbox: initialize lowp float opacity +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=texture2D(u_image,v_uv);gl_FragColor=color*(alpha*opacity); +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,` +#define scale 0.015873016 +attribute vec2 a_pos_normal;attribute vec4 a_data;attribute float a_uv_x;attribute float a_split_index;uniform mat4 u_matrix;uniform mediump float u_ratio;uniform lowp float u_device_pixel_ratio;uniform vec2 u_units_to_pixels;uniform float u_image_height;varying vec2 v_normal;varying vec2 v_width2;varying float v_gamma_scale;varying highp vec2 v_uv; +#pragma mapbox: define lowp float blur +#pragma mapbox: define lowp float opacity +#pragma mapbox: define mediump float gapwidth +#pragma mapbox: define lowp float offset +#pragma mapbox: define mediump float width +void main() { +#pragma mapbox: initialize lowp float blur +#pragma mapbox: initialize lowp float opacity +#pragma mapbox: initialize mediump float gapwidth +#pragma mapbox: initialize lowp float offset +#pragma mapbox: initialize mediump float width +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);vec4 projected_extrude=u_matrix*vec4(dist/u_ratio,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2/u_ratio,0.0,1.0)+projected_extrude;float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;v_width2=vec2(outset,inset);}`),wo=Aa(`uniform lowp float u_device_pixel_ratio;uniform vec2 u_texsize;uniform float u_fade;uniform mediump vec3 u_scale;uniform sampler2D u_image;varying vec2 v_normal;varying vec2 v_width2;varying float v_linesofar;varying float v_gamma_scale;varying float v_width; +#pragma mapbox: define lowp vec4 pattern_from +#pragma mapbox: define lowp vec4 pattern_to +#pragma mapbox: define lowp float pixel_ratio_from +#pragma mapbox: define lowp float pixel_ratio_to +#pragma mapbox: define lowp float blur +#pragma mapbox: define lowp float opacity +void main() { +#pragma mapbox: initialize mediump vec4 pattern_from +#pragma mapbox: initialize mediump vec4 pattern_to +#pragma mapbox: initialize lowp float pixel_ratio_from +#pragma mapbox: initialize lowp float pixel_ratio_to +#pragma mapbox: initialize lowp float blur +#pragma mapbox: initialize lowp float opacity +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(texture2D(u_image,pos_a),texture2D(u_image,pos_b),u_fade);gl_FragColor=color*alpha*opacity; +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,` +#define scale 0.015873016 +#define LINE_DISTANCE_SCALE 2.0 +attribute vec2 a_pos_normal;attribute vec4 a_data;uniform mat4 u_matrix;uniform vec2 u_units_to_pixels;uniform mediump float u_ratio;uniform lowp float u_device_pixel_ratio;varying vec2 v_normal;varying vec2 v_width2;varying float v_linesofar;varying float v_gamma_scale;varying float v_width; +#pragma mapbox: define lowp float blur +#pragma mapbox: define lowp float opacity +#pragma mapbox: define lowp float offset +#pragma mapbox: define mediump float gapwidth +#pragma mapbox: define mediump float width +#pragma mapbox: define lowp float floorwidth +#pragma mapbox: define lowp vec4 pattern_from +#pragma mapbox: define lowp vec4 pattern_to +#pragma mapbox: define lowp float pixel_ratio_from +#pragma mapbox: define lowp float pixel_ratio_to +void main() { +#pragma mapbox: initialize lowp float blur +#pragma mapbox: initialize lowp float opacity +#pragma mapbox: initialize lowp float offset +#pragma mapbox: initialize mediump float gapwidth +#pragma mapbox: initialize mediump float width +#pragma mapbox: initialize lowp float floorwidth +#pragma mapbox: initialize mediump vec4 pattern_from +#pragma mapbox: initialize mediump vec4 pattern_to +#pragma mapbox: initialize lowp float pixel_ratio_from +#pragma mapbox: initialize lowp float pixel_ratio_to +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);vec4 projected_extrude=u_matrix*vec4(dist/u_ratio,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2/u_ratio,0.0,1.0)+projected_extrude;float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;v_linesofar=a_linesofar;v_width2=vec2(outset,inset);v_width=floorwidth;}`),Pa=Aa(`uniform lowp float u_device_pixel_ratio;uniform sampler2D u_image;uniform float u_sdfgamma;uniform float u_mix;varying vec2 v_normal;varying vec2 v_width2;varying vec2 v_tex_a;varying vec2 v_tex_b;varying float v_gamma_scale; +#pragma mapbox: define highp vec4 color +#pragma mapbox: define lowp float blur +#pragma mapbox: define lowp float opacity +#pragma mapbox: define mediump float width +#pragma mapbox: define lowp float floorwidth +void main() { +#pragma mapbox: initialize highp vec4 color +#pragma mapbox: initialize lowp float blur +#pragma mapbox: initialize lowp float opacity +#pragma mapbox: initialize mediump float width +#pragma mapbox: initialize lowp float floorwidth +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=texture2D(u_image,v_tex_a).a;float sdfdist_b=texture2D(u_image,v_tex_b).a;float sdfdist=mix(sdfdist_a,sdfdist_b,u_mix);alpha*=smoothstep(0.5-u_sdfgamma/floorwidth,0.5+u_sdfgamma/floorwidth,sdfdist);gl_FragColor=color*(alpha*opacity); +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,` +#define scale 0.015873016 +#define LINE_DISTANCE_SCALE 2.0 +attribute vec2 a_pos_normal;attribute vec4 a_data;uniform mat4 u_matrix;uniform mediump float u_ratio;uniform lowp float u_device_pixel_ratio;uniform vec2 u_patternscale_a;uniform float u_tex_y_a;uniform vec2 u_patternscale_b;uniform float u_tex_y_b;uniform vec2 u_units_to_pixels;varying vec2 v_normal;varying vec2 v_width2;varying vec2 v_tex_a;varying vec2 v_tex_b;varying float v_gamma_scale; +#pragma mapbox: define highp vec4 color +#pragma mapbox: define lowp float blur +#pragma mapbox: define lowp float opacity +#pragma mapbox: define mediump float gapwidth +#pragma mapbox: define lowp float offset +#pragma mapbox: define mediump float width +#pragma mapbox: define lowp float floorwidth +void main() { +#pragma mapbox: initialize highp vec4 color +#pragma mapbox: initialize lowp float blur +#pragma mapbox: initialize lowp float opacity +#pragma mapbox: initialize mediump float gapwidth +#pragma mapbox: initialize lowp float offset +#pragma mapbox: initialize mediump float width +#pragma mapbox: initialize lowp float floorwidth +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);vec4 projected_extrude=u_matrix*vec4(dist/u_ratio,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2/u_ratio,0.0,1.0)+projected_extrude;float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;v_tex_a=vec2(a_linesofar*u_patternscale_a.x/floorwidth,normal.y*u_patternscale_a.y+u_tex_y_a);v_tex_b=vec2(a_linesofar*u_patternscale_b.x/floorwidth,normal.y*u_patternscale_b.y+u_tex_y_b);v_width2=vec2(outset,inset);}`),ss=Aa(`uniform float u_fade_t;uniform float u_opacity;uniform sampler2D u_image0;uniform sampler2D u_image1;varying vec2 v_pos0;varying vec2 v_pos1;uniform float u_brightness_low;uniform float u_brightness_high;uniform float u_saturation_factor;uniform float u_contrast_factor;uniform vec3 u_spin_weights;void main() {vec4 color0=texture2D(u_image0,v_pos0);vec4 color1=texture2D(u_image1,v_pos1);if (color0.a > 0.0) {color0.rgb=color0.rgb/color0.a;}if (color1.a > 0.0) {color1.rgb=color1.rgb/color1.a;}vec4 color=mix(color0,color1,u_fade_t);color.a*=u_opacity;vec3 rgb=color.rgb;rgb=vec3(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);gl_FragColor=vec4(mix(u_high_vec,u_low_vec,rgb)*color.a,color.a); +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,"uniform mat4 u_matrix;uniform vec2 u_tl_parent;uniform float u_scale_parent;uniform float u_buffer_scale;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos0;varying vec2 v_pos1;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);v_pos0=(((a_texture_pos/8192.0)-0.5)/u_buffer_scale )+0.5;v_pos1=(v_pos0*u_scale_parent)+u_tl_parent;}"),si=Aa(`uniform sampler2D u_texture;varying vec2 v_tex;varying float v_fade_opacity; +#pragma mapbox: define lowp float opacity +void main() { +#pragma mapbox: initialize lowp float opacity +lowp float alpha=opacity*v_fade_opacity;gl_FragColor=texture2D(u_texture,v_tex)*alpha; +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,`const float PI=3.141592653589793;attribute vec4 a_pos_offset;attribute vec4 a_data;attribute vec4 a_pixeloffset;attribute vec3 a_projected_pos;attribute 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_matrix;uniform mat4 u_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform vec2 u_texsize;varying vec2 v_tex;varying float v_fade_opacity; +#pragma mapbox: define lowp float opacity +void main() { +#pragma mapbox: initialize lowp float opacity +vec2 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;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;}vec4 projectedPoint=u_matrix*vec4(a_pos,0,1);highp float camera_to_anchor_distance=projectedPoint.w;highp float distance_ratio=u_pitch_with_map ? +camera_to_anchor_distance/u_camera_to_center_distance : +u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(0.5+0.5*distance_ratio,0.0,4.0);size*=perspective_ratio;float fontScale=u_is_text ? size/24.0 : size;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetProjectedPoint=u_matrix*vec4(a_pos+vec2(1,0),0,1);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=u_label_plane_matrix*vec4(a_projected_pos.xy,0.0,1.0);gl_Position=u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+rotation_matrix*(a_offset/32.0*max(a_minFontScale,fontScale)+a_pxoffset/16.0),0.0,1.0);v_tex=a_tex/u_texsize;vec2 fade_opacity=unpack_opacity(a_fade_opacity);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;v_fade_opacity=max(0.0,min(1.0,fade_opacity[0]+fade_change));}`),Ms=Aa(`#define SDF_PX 8.0 +uniform bool u_is_halo;uniform sampler2D u_texture;uniform highp float u_gamma_scale;uniform lowp float u_device_pixel_ratio;uniform bool u_is_text;varying vec2 v_data0;varying vec3 v_data1; +#pragma mapbox: define highp vec4 fill_color +#pragma mapbox: define highp vec4 halo_color +#pragma mapbox: define lowp float opacity +#pragma mapbox: define lowp float halo_width +#pragma mapbox: define lowp float halo_blur +void main() { +#pragma mapbox: initialize highp vec4 fill_color +#pragma mapbox: initialize highp vec4 halo_color +#pragma mapbox: initialize lowp float opacity +#pragma mapbox: initialize lowp float halo_width +#pragma mapbox: initialize lowp float halo_blur +float EDGE_GAMMA=0.105/u_device_pixel_ratio;vec2 tex=v_data0.xy;float gamma_scale=v_data1.x;float size=v_data1.y;float fade_opacity=v_data1[2];float fontScale=u_is_text ? size/24.0 : size;lowp vec4 color=fill_color;highp float gamma=EDGE_GAMMA/(fontScale*u_gamma_scale);lowp float buff=(256.0-64.0)/256.0;if (u_is_halo) {color=halo_color;gamma=(halo_blur*1.19/SDF_PX+EDGE_GAMMA)/(fontScale*u_gamma_scale);buff=(6.0-halo_width/fontScale)/SDF_PX;}lowp float dist=texture2D(u_texture,tex).a;highp float gamma_scaled=gamma*gamma_scale;highp float alpha=smoothstep(buff-gamma_scaled,buff+gamma_scaled,dist);gl_FragColor=color*(alpha*opacity*fade_opacity); +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,`const float PI=3.141592653589793;attribute vec4 a_pos_offset;attribute vec4 a_data;attribute vec4 a_pixeloffset;attribute vec3 a_projected_pos;attribute 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_matrix;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;varying vec2 v_data0;varying vec3 v_data1; +#pragma mapbox: define highp vec4 fill_color +#pragma mapbox: define highp vec4 halo_color +#pragma mapbox: define lowp float opacity +#pragma mapbox: define lowp float halo_width +#pragma mapbox: define lowp float halo_blur +void main() { +#pragma mapbox: initialize highp vec4 fill_color +#pragma mapbox: initialize highp vec4 halo_color +#pragma mapbox: initialize lowp float opacity +#pragma mapbox: initialize lowp float halo_width +#pragma mapbox: initialize lowp float halo_blur +vec2 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;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;}vec4 projectedPoint=u_matrix*vec4(a_pos,0,1);highp float camera_to_anchor_distance=projectedPoint.w;highp float distance_ratio=u_pitch_with_map ? +camera_to_anchor_distance/u_camera_to_center_distance : +u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(0.5+0.5*distance_ratio,0.0,4.0);size*=perspective_ratio;float fontScale=u_is_text ? size/24.0 : size;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetProjectedPoint=u_matrix*vec4(a_pos+vec2(1,0),0,1);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=u_label_plane_matrix*vec4(a_projected_pos.xy,0.0,1.0);gl_Position=u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+rotation_matrix*(a_offset/32.0*fontScale+a_pxoffset),0.0,1.0);float gamma_scale=gl_Position.w;vec2 fade_opacity=unpack_opacity(a_fade_opacity);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;float interpolated_fade_opacity=max(0.0,min(1.0,fade_opacity[0]+fade_change));v_data0=a_tex/u_texsize;v_data1=vec3(gamma_scale,size,interpolated_fade_opacity);}`),Ns=Aa(`#define SDF_PX 8.0 +#define SDF 1.0 +#define ICON 0.0 +uniform bool u_is_halo;uniform sampler2D u_texture;uniform sampler2D u_texture_icon;uniform highp float u_gamma_scale;uniform lowp float u_device_pixel_ratio;varying vec4 v_data0;varying vec4 v_data1; +#pragma mapbox: define highp vec4 fill_color +#pragma mapbox: define highp vec4 halo_color +#pragma mapbox: define lowp float opacity +#pragma mapbox: define lowp float halo_width +#pragma mapbox: define lowp float halo_blur +void main() { +#pragma mapbox: initialize highp vec4 fill_color +#pragma mapbox: initialize highp vec4 halo_color +#pragma mapbox: initialize lowp float opacity +#pragma mapbox: initialize lowp float halo_width +#pragma mapbox: initialize lowp float halo_blur +float fade_opacity=v_data1[2];if (v_data1.w==ICON) {vec2 tex_icon=v_data0.zw;lowp float alpha=opacity*fade_opacity;gl_FragColor=texture2D(u_texture_icon,tex_icon)*alpha; +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +return;}vec2 tex=v_data0.xy;float EDGE_GAMMA=0.105/u_device_pixel_ratio;float gamma_scale=v_data1.x;float size=v_data1.y;float fontScale=size/24.0;lowp vec4 color=fill_color;highp float gamma=EDGE_GAMMA/(fontScale*u_gamma_scale);lowp float buff=(256.0-64.0)/256.0;if (u_is_halo) {color=halo_color;gamma=(halo_blur*1.19/SDF_PX+EDGE_GAMMA)/(fontScale*u_gamma_scale);buff=(6.0-halo_width/fontScale)/SDF_PX;}lowp float dist=texture2D(u_texture,tex).a;highp float gamma_scaled=gamma*gamma_scale;highp float alpha=smoothstep(buff-gamma_scaled,buff+gamma_scaled,dist);gl_FragColor=color*(alpha*opacity*fade_opacity); +#ifdef OVERDRAW_INSPECTOR +gl_FragColor=vec4(1.0); +#endif +}`,`const float PI=3.141592653589793;attribute vec4 a_pos_offset;attribute vec4 a_data;attribute vec3 a_projected_pos;attribute 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_matrix;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;varying vec4 v_data0;varying vec4 v_data1; +#pragma mapbox: define highp vec4 fill_color +#pragma mapbox: define highp vec4 halo_color +#pragma mapbox: define lowp float opacity +#pragma mapbox: define lowp float halo_width +#pragma mapbox: define lowp float halo_blur +void main() { +#pragma mapbox: initialize highp vec4 fill_color +#pragma mapbox: initialize highp vec4 halo_color +#pragma mapbox: initialize lowp float opacity +#pragma mapbox: initialize lowp float halo_width +#pragma mapbox: initialize lowp float halo_blur +vec2 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;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;}vec4 projectedPoint=u_matrix*vec4(a_pos,0,1);highp float camera_to_anchor_distance=projectedPoint.w;highp float distance_ratio=u_pitch_with_map ? +camera_to_anchor_distance/u_camera_to_center_distance : +u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(0.5+0.5*distance_ratio,0.0,4.0);size*=perspective_ratio;float fontScale=size/24.0;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetProjectedPoint=u_matrix*vec4(a_pos+vec2(1,0),0,1);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=u_label_plane_matrix*vec4(a_projected_pos.xy,0.0,1.0);gl_Position=u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+rotation_matrix*(a_offset/32.0*fontScale),0.0,1.0);float gamma_scale=gl_Position.w;vec2 fade_opacity=unpack_opacity(a_fade_opacity);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;float interpolated_fade_opacity=max(0.0,min(1.0,fade_opacity[0]+fade_change));v_data0.xy=a_tex/u_texsize;v_data0.zw=a_tex/u_texsize_icon;v_data1=vec4(gamma_scale,size,interpolated_fade_opacity,is_sdf);}`);function Aa(b,x){var S=/#pragma mapbox: ([\w]+) ([\w]+) ([\w]+) ([\w]+)/g,U=x.match(/attribute ([\w]+) ([\w]+)/g),pe=b.match(/uniform ([\w]+) ([\w]+)([\s]*)([\w]*)/g),Ce=x.match(/uniform ([\w]+) ([\w]+)([\s]*)([\w]*)/g),Oe=Ce?Ce.concat(pe):pe,dt={};return{fragmentSource:b=b.replace(S,function(zt,Tt,Qt,cr,pr){return dt[pr]=!0,Tt==="define"?` +#ifndef HAS_UNIFORM_u_`+pr+` +varying `+Qt+" "+cr+" "+pr+`; +#else +uniform `+Qt+" "+cr+" u_"+pr+`; +#endif +`:` +#ifdef HAS_UNIFORM_u_`+pr+` + `+Qt+" "+cr+" "+pr+" = u_"+pr+`; +#endif +`}),vertexSource:x=x.replace(S,function(zt,Tt,Qt,cr,pr){var zr=cr==="float"?"vec2":"vec4",jr=pr.match(/color/)?"color":zr;return dt[pr]?Tt==="define"?` +#ifndef HAS_UNIFORM_u_`+pr+` +uniform lowp float u_`+pr+`_t; +attribute `+Qt+" "+zr+" a_"+pr+`; +varying `+Qt+" "+cr+" "+pr+`; +#else +uniform `+Qt+" "+cr+" u_"+pr+`; +#endif +`:jr==="vec4"?` +#ifndef HAS_UNIFORM_u_`+pr+` + `+pr+" = a_"+pr+`; +#else + `+Qt+" "+cr+" "+pr+" = u_"+pr+`; +#endif +`:` +#ifndef HAS_UNIFORM_u_`+pr+` + `+pr+" = unpack_mix_"+jr+"(a_"+pr+", u_"+pr+`_t); +#else + `+Qt+" "+cr+" "+pr+" = u_"+pr+`; +#endif +`:Tt==="define"?` +#ifndef HAS_UNIFORM_u_`+pr+` +uniform lowp float u_`+pr+`_t; +attribute `+Qt+" "+zr+" a_"+pr+`; +#else +uniform `+Qt+" "+cr+" u_"+pr+`; +#endif +`:jr==="vec4"?` +#ifndef HAS_UNIFORM_u_`+pr+` + `+Qt+" "+cr+" "+pr+" = a_"+pr+`; +#else + `+Qt+" "+cr+" "+pr+" = u_"+pr+`; +#endif +`:` +#ifndef HAS_UNIFORM_u_`+pr+` + `+Qt+" "+cr+" "+pr+" = unpack_mix_"+jr+"(a_"+pr+", u_"+pr+`_t); +#else + `+Qt+" "+cr+" "+pr+" = u_"+pr+`; +#endif +`}),staticAttributes:U,staticUniforms:Oe}}var qs=Object.freeze({__proto__:null,prelude:No,background:Da,backgroundPattern:ta,circle:Ra,clippingMask:ns,heatmap:Vo,heatmapTexture:bs,collisionBox:Js,collisionCircle:Hu,debug:Of,fill:en,fillOutline:xn,fillOutlinePattern:Vi,fillPattern:wi,fillExtrusion:oo,fillExtrusionPattern:io,hillshadePrepare:Uo,hillshade:na,line:$a,lineGradient:Co,linePattern:wo,lineSDF:Pa,raster:ss,symbolIcon:si,symbolSDF:Ms,symbolTextAndIcon:Ns}),Eu=function(){this.boundProgram=null,this.boundLayoutVertexBuffer=null,this.boundPaintVertexBuffers=[],this.boundIndexBuffer=null,this.boundVertexOffset=null,this.boundDynamicVertexBuffer=null,this.vao=null};function Cs(b){for(var x=[],S=0;S>16,dt>>16],u_pixel_coord_lower:[65535&Oe,65535&dt]}}su.prototype.draw=function(b,x,S,U,pe,Ce,Oe,dt,zt,Tt,Qt,cr,pr,zr,jr,tn){var Hr,fn=b.gl;if(!this.failedToCreate){for(var qt in b.program.set(this.program),b.setDepthMode(S),b.setStencilMode(U),b.setColorMode(pe),b.setCullFace(Ce),this.fixedUniforms)this.fixedUniforms[qt].set(Oe[qt]);zr&&zr.setUniforms(b,this.binderUniforms,cr,{zoom:pr});for(var ii=(Hr={},Hr[fn.LINES]=2,Hr[fn.TRIANGLES]=3,Hr[fn.LINE_STRIP]=1,Hr)[x],Ai=0,xr=Qt.get();Ai0?1-1/(1.001-Oe):-Oe),u_contrast_factor:(Ce=pe.paint.get("raster-contrast"),Ce>0?1/(1-Ce):1+Ce),u_spin_weights:Hf(pe.paint.get("raster-hue-rotate"))};var Ce,Oe};function Hf(b){b*=Math.PI/180;var x=Math.sin(b),S=Math.cos(b);return[(2*S+1)/3,(-Math.sqrt(3)*x-S+1)/3,(Math.sqrt(3)*x-S+1)/3]}var Ul,Lf=function(b,x,S,U,pe,Ce,Oe,dt,zt,Tt){var Qt=pe.transform;return{u_is_size_zoom_constant:+(b==="constant"||b==="source"),u_is_size_feature_constant:+(b==="constant"||b==="camera"),u_size_t:x?x.uSizeT:0,u_size:x?x.uSize:0,u_camera_to_center_distance:Qt.cameraToCenterDistance,u_pitch:Qt.pitch/360*2*Math.PI,u_rotate_symbol:+S,u_aspect_ratio:Qt.width/Qt.height,u_fade_change:pe.options.fadeDuration?pe.symbolFadeChange:1,u_matrix:Ce,u_label_plane_matrix:Oe,u_coord_matrix:dt,u_is_text:+zt,u_pitch_with_map:+U,u_texsize:Tt,u_texture:0}},Fc=function(b,x,S,U,pe,Ce,Oe,dt,zt,Tt,Qt){var cr=pe.transform;return y.extend(Lf(b,x,S,U,pe,Ce,Oe,dt,zt,Tt),{u_gamma_scale:U?Math.cos(cr._pitch)*cr.cameraToCenterDistance:1,u_device_pixel_ratio:y.browser.devicePixelRatio,u_is_halo:+Qt})},Ol=function(b,x,S,U,pe,Ce,Oe,dt,zt,Tt){return y.extend(Fc(b,x,S,U,pe,Ce,Oe,dt,!0,zt,!0),{u_texsize_icon:Tt,u_texture_icon:1})},_l=function(b,x,S){return{u_matrix:b,u_opacity:x,u_color:S}},cn=function(b,x,S,U,pe,Ce){return y.extend(function(Oe,dt,zt,Tt){var Qt=zt.imageManager.getPattern(Oe.from.toString()),cr=zt.imageManager.getPattern(Oe.to.toString()),pr=zt.imageManager.getPixelSize(),zr=pr.width,jr=pr.height,tn=Math.pow(2,Tt.tileID.overscaledZ),Hr=Tt.tileSize*Math.pow(2,zt.transform.tileZoom)/tn,fn=Hr*(Tt.tileID.canonical.x+Tt.tileID.wrap*tn),qt=Hr*Tt.tileID.canonical.y;return{u_image:0,u_pattern_tl_a:Qt.tl,u_pattern_br_a:Qt.br,u_pattern_tl_b:cr.tl,u_pattern_br_b:cr.br,u_texsize:[zr,jr],u_mix:dt.t,u_pattern_size_a:Qt.displaySize,u_pattern_size_b:cr.displaySize,u_scale_a:dt.fromScale,u_scale_b:dt.toScale,u_tile_units_to_pixels:1/el(Tt,1,zt.transform.tileZoom),u_pixel_coord_upper:[fn>>16,qt>>16],u_pixel_coord_lower:[65535&fn,65535&qt]}}(U,Ce,S,pe),{u_matrix:b,u_opacity:x})},an={fillExtrusion:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_lightpos:new y.Uniform3f(b,x.u_lightpos),u_lightintensity:new y.Uniform1f(b,x.u_lightintensity),u_lightcolor:new y.Uniform3f(b,x.u_lightcolor),u_vertical_gradient:new y.Uniform1f(b,x.u_vertical_gradient),u_opacity:new y.Uniform1f(b,x.u_opacity)}},fillExtrusionPattern:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_lightpos:new y.Uniform3f(b,x.u_lightpos),u_lightintensity:new y.Uniform1f(b,x.u_lightintensity),u_lightcolor:new y.Uniform3f(b,x.u_lightcolor),u_vertical_gradient:new y.Uniform1f(b,x.u_vertical_gradient),u_height_factor:new y.Uniform1f(b,x.u_height_factor),u_image:new y.Uniform1i(b,x.u_image),u_texsize:new y.Uniform2f(b,x.u_texsize),u_pixel_coord_upper:new y.Uniform2f(b,x.u_pixel_coord_upper),u_pixel_coord_lower:new y.Uniform2f(b,x.u_pixel_coord_lower),u_scale:new y.Uniform3f(b,x.u_scale),u_fade:new y.Uniform1f(b,x.u_fade),u_opacity:new y.Uniform1f(b,x.u_opacity)}},fill:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix)}},fillPattern:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_image:new y.Uniform1i(b,x.u_image),u_texsize:new y.Uniform2f(b,x.u_texsize),u_pixel_coord_upper:new y.Uniform2f(b,x.u_pixel_coord_upper),u_pixel_coord_lower:new y.Uniform2f(b,x.u_pixel_coord_lower),u_scale:new y.Uniform3f(b,x.u_scale),u_fade:new y.Uniform1f(b,x.u_fade)}},fillOutline:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_world:new y.Uniform2f(b,x.u_world)}},fillOutlinePattern:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_world:new y.Uniform2f(b,x.u_world),u_image:new y.Uniform1i(b,x.u_image),u_texsize:new y.Uniform2f(b,x.u_texsize),u_pixel_coord_upper:new y.Uniform2f(b,x.u_pixel_coord_upper),u_pixel_coord_lower:new y.Uniform2f(b,x.u_pixel_coord_lower),u_scale:new y.Uniform3f(b,x.u_scale),u_fade:new y.Uniform1f(b,x.u_fade)}},circle:function(b,x){return{u_camera_to_center_distance:new y.Uniform1f(b,x.u_camera_to_center_distance),u_scale_with_map:new y.Uniform1i(b,x.u_scale_with_map),u_pitch_with_map:new y.Uniform1i(b,x.u_pitch_with_map),u_extrude_scale:new y.Uniform2f(b,x.u_extrude_scale),u_device_pixel_ratio:new y.Uniform1f(b,x.u_device_pixel_ratio),u_matrix:new y.UniformMatrix4f(b,x.u_matrix)}},collisionBox:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_camera_to_center_distance:new y.Uniform1f(b,x.u_camera_to_center_distance),u_pixels_to_tile_units:new y.Uniform1f(b,x.u_pixels_to_tile_units),u_extrude_scale:new y.Uniform2f(b,x.u_extrude_scale),u_overscale_factor:new y.Uniform1f(b,x.u_overscale_factor)}},collisionCircle:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_inv_matrix:new y.UniformMatrix4f(b,x.u_inv_matrix),u_camera_to_center_distance:new y.Uniform1f(b,x.u_camera_to_center_distance),u_viewport_size:new y.Uniform2f(b,x.u_viewport_size)}},debug:function(b,x){return{u_color:new y.UniformColor(b,x.u_color),u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_overlay:new y.Uniform1i(b,x.u_overlay),u_overlay_scale:new y.Uniform1f(b,x.u_overlay_scale)}},clippingMask:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix)}},heatmap:function(b,x){return{u_extrude_scale:new y.Uniform1f(b,x.u_extrude_scale),u_intensity:new y.Uniform1f(b,x.u_intensity),u_matrix:new y.UniformMatrix4f(b,x.u_matrix)}},heatmapTexture:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_world:new y.Uniform2f(b,x.u_world),u_image:new y.Uniform1i(b,x.u_image),u_color_ramp:new y.Uniform1i(b,x.u_color_ramp),u_opacity:new y.Uniform1f(b,x.u_opacity)}},hillshade:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_image:new y.Uniform1i(b,x.u_image),u_latrange:new y.Uniform2f(b,x.u_latrange),u_light:new y.Uniform2f(b,x.u_light),u_shadow:new y.UniformColor(b,x.u_shadow),u_highlight:new y.UniformColor(b,x.u_highlight),u_accent:new y.UniformColor(b,x.u_accent)}},hillshadePrepare:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_image:new y.Uniform1i(b,x.u_image),u_dimension:new y.Uniform2f(b,x.u_dimension),u_zoom:new y.Uniform1f(b,x.u_zoom),u_unpack:new y.Uniform4f(b,x.u_unpack)}},line:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_ratio:new y.Uniform1f(b,x.u_ratio),u_device_pixel_ratio:new y.Uniform1f(b,x.u_device_pixel_ratio),u_units_to_pixels:new y.Uniform2f(b,x.u_units_to_pixels)}},lineGradient:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_ratio:new y.Uniform1f(b,x.u_ratio),u_device_pixel_ratio:new y.Uniform1f(b,x.u_device_pixel_ratio),u_units_to_pixels:new y.Uniform2f(b,x.u_units_to_pixels),u_image:new y.Uniform1i(b,x.u_image),u_image_height:new y.Uniform1f(b,x.u_image_height)}},linePattern:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_texsize:new y.Uniform2f(b,x.u_texsize),u_ratio:new y.Uniform1f(b,x.u_ratio),u_device_pixel_ratio:new y.Uniform1f(b,x.u_device_pixel_ratio),u_image:new y.Uniform1i(b,x.u_image),u_units_to_pixels:new y.Uniform2f(b,x.u_units_to_pixels),u_scale:new y.Uniform3f(b,x.u_scale),u_fade:new y.Uniform1f(b,x.u_fade)}},lineSDF:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_ratio:new y.Uniform1f(b,x.u_ratio),u_device_pixel_ratio:new y.Uniform1f(b,x.u_device_pixel_ratio),u_units_to_pixels:new y.Uniform2f(b,x.u_units_to_pixels),u_patternscale_a:new y.Uniform2f(b,x.u_patternscale_a),u_patternscale_b:new y.Uniform2f(b,x.u_patternscale_b),u_sdfgamma:new y.Uniform1f(b,x.u_sdfgamma),u_image:new y.Uniform1i(b,x.u_image),u_tex_y_a:new y.Uniform1f(b,x.u_tex_y_a),u_tex_y_b:new y.Uniform1f(b,x.u_tex_y_b),u_mix:new y.Uniform1f(b,x.u_mix)}},raster:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_tl_parent:new y.Uniform2f(b,x.u_tl_parent),u_scale_parent:new y.Uniform1f(b,x.u_scale_parent),u_buffer_scale:new y.Uniform1f(b,x.u_buffer_scale),u_fade_t:new y.Uniform1f(b,x.u_fade_t),u_opacity:new y.Uniform1f(b,x.u_opacity),u_image0:new y.Uniform1i(b,x.u_image0),u_image1:new y.Uniform1i(b,x.u_image1),u_brightness_low:new y.Uniform1f(b,x.u_brightness_low),u_brightness_high:new y.Uniform1f(b,x.u_brightness_high),u_saturation_factor:new y.Uniform1f(b,x.u_saturation_factor),u_contrast_factor:new y.Uniform1f(b,x.u_contrast_factor),u_spin_weights:new y.Uniform3f(b,x.u_spin_weights)}},symbolIcon:function(b,x){return{u_is_size_zoom_constant:new y.Uniform1i(b,x.u_is_size_zoom_constant),u_is_size_feature_constant:new y.Uniform1i(b,x.u_is_size_feature_constant),u_size_t:new y.Uniform1f(b,x.u_size_t),u_size:new y.Uniform1f(b,x.u_size),u_camera_to_center_distance:new y.Uniform1f(b,x.u_camera_to_center_distance),u_pitch:new y.Uniform1f(b,x.u_pitch),u_rotate_symbol:new y.Uniform1i(b,x.u_rotate_symbol),u_aspect_ratio:new y.Uniform1f(b,x.u_aspect_ratio),u_fade_change:new y.Uniform1f(b,x.u_fade_change),u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_label_plane_matrix:new y.UniformMatrix4f(b,x.u_label_plane_matrix),u_coord_matrix:new y.UniformMatrix4f(b,x.u_coord_matrix),u_is_text:new y.Uniform1i(b,x.u_is_text),u_pitch_with_map:new y.Uniform1i(b,x.u_pitch_with_map),u_texsize:new y.Uniform2f(b,x.u_texsize),u_texture:new y.Uniform1i(b,x.u_texture)}},symbolSDF:function(b,x){return{u_is_size_zoom_constant:new y.Uniform1i(b,x.u_is_size_zoom_constant),u_is_size_feature_constant:new y.Uniform1i(b,x.u_is_size_feature_constant),u_size_t:new y.Uniform1f(b,x.u_size_t),u_size:new y.Uniform1f(b,x.u_size),u_camera_to_center_distance:new y.Uniform1f(b,x.u_camera_to_center_distance),u_pitch:new y.Uniform1f(b,x.u_pitch),u_rotate_symbol:new y.Uniform1i(b,x.u_rotate_symbol),u_aspect_ratio:new y.Uniform1f(b,x.u_aspect_ratio),u_fade_change:new y.Uniform1f(b,x.u_fade_change),u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_label_plane_matrix:new y.UniformMatrix4f(b,x.u_label_plane_matrix),u_coord_matrix:new y.UniformMatrix4f(b,x.u_coord_matrix),u_is_text:new y.Uniform1i(b,x.u_is_text),u_pitch_with_map:new y.Uniform1i(b,x.u_pitch_with_map),u_texsize:new y.Uniform2f(b,x.u_texsize),u_texture:new y.Uniform1i(b,x.u_texture),u_gamma_scale:new y.Uniform1f(b,x.u_gamma_scale),u_device_pixel_ratio:new y.Uniform1f(b,x.u_device_pixel_ratio),u_is_halo:new y.Uniform1i(b,x.u_is_halo)}},symbolTextAndIcon:function(b,x){return{u_is_size_zoom_constant:new y.Uniform1i(b,x.u_is_size_zoom_constant),u_is_size_feature_constant:new y.Uniform1i(b,x.u_is_size_feature_constant),u_size_t:new y.Uniform1f(b,x.u_size_t),u_size:new y.Uniform1f(b,x.u_size),u_camera_to_center_distance:new y.Uniform1f(b,x.u_camera_to_center_distance),u_pitch:new y.Uniform1f(b,x.u_pitch),u_rotate_symbol:new y.Uniform1i(b,x.u_rotate_symbol),u_aspect_ratio:new y.Uniform1f(b,x.u_aspect_ratio),u_fade_change:new y.Uniform1f(b,x.u_fade_change),u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_label_plane_matrix:new y.UniformMatrix4f(b,x.u_label_plane_matrix),u_coord_matrix:new y.UniformMatrix4f(b,x.u_coord_matrix),u_is_text:new y.Uniform1i(b,x.u_is_text),u_pitch_with_map:new y.Uniform1i(b,x.u_pitch_with_map),u_texsize:new y.Uniform2f(b,x.u_texsize),u_texsize_icon:new y.Uniform2f(b,x.u_texsize_icon),u_texture:new y.Uniform1i(b,x.u_texture),u_texture_icon:new y.Uniform1i(b,x.u_texture_icon),u_gamma_scale:new y.Uniform1f(b,x.u_gamma_scale),u_device_pixel_ratio:new y.Uniform1f(b,x.u_device_pixel_ratio),u_is_halo:new y.Uniform1i(b,x.u_is_halo)}},background:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_opacity:new y.Uniform1f(b,x.u_opacity),u_color:new y.UniformColor(b,x.u_color)}},backgroundPattern:function(b,x){return{u_matrix:new y.UniformMatrix4f(b,x.u_matrix),u_opacity:new y.Uniform1f(b,x.u_opacity),u_image:new y.Uniform1i(b,x.u_image),u_pattern_tl_a:new y.Uniform2f(b,x.u_pattern_tl_a),u_pattern_br_a:new y.Uniform2f(b,x.u_pattern_br_a),u_pattern_tl_b:new y.Uniform2f(b,x.u_pattern_tl_b),u_pattern_br_b:new y.Uniform2f(b,x.u_pattern_br_b),u_texsize:new y.Uniform2f(b,x.u_texsize),u_mix:new y.Uniform1f(b,x.u_mix),u_pattern_size_a:new y.Uniform2f(b,x.u_pattern_size_a),u_pattern_size_b:new y.Uniform2f(b,x.u_pattern_size_b),u_scale_a:new y.Uniform1f(b,x.u_scale_a),u_scale_b:new y.Uniform1f(b,x.u_scale_b),u_pixel_coord_upper:new y.Uniform2f(b,x.u_pixel_coord_upper),u_pixel_coord_lower:new y.Uniform2f(b,x.u_pixel_coord_lower),u_tile_units_to_pixels:new y.Uniform1f(b,x.u_tile_units_to_pixels)}}};function Xn(b,x,S,U,pe,Ce,Oe){for(var dt=b.context,zt=dt.gl,Tt=b.useProgram("collisionBox"),Qt=[],cr=0,pr=0,zr=0;zr0){var Ai=y.create(),xr=fn;y.mul(Ai,Hr.placementInvProjMatrix,b.transform.glCoordMatrix),y.mul(Ai,Ai,Hr.placementViewportMatrix),Qt.push({circleArray:ii,circleOffset:pr,transform:xr,invTransform:Ai}),pr=cr+=ii.length/4}qt&&Tt.draw(dt,zt.LINES,Bt.disabled,Jt.disabled,b.colorModeForRenderPass(),hr.disabled,Zs(fn,b.transform,tn),S.id,qt.layoutVertexBuffer,qt.indexBuffer,qt.segments,null,b.transform.zoom,null,null,qt.collisionVertexBuffer)}}if(Oe&&Qt.length){var Ni=b.useProgram("collisionCircle"),uo=new y.StructArrayLayout2f1f2i16;uo.resize(4*cr),uo._trim();for(var oa=0,da=0,Fs=Qt;da=0&&(jr[Hr.associatedIconIndex]={shiftedAnchor:uo,angle:oa})}else Ju(Hr.numGlyphs,pr)}if(Qt){zr.clear();for(var Fs=b.icon.placedSymbolArray,hu=0;hu0){var Oe=y.browser.now(),dt=(Oe-b.timeAdded)/Ce,zt=x?(Oe-x.timeAdded)/Ce:-1,Tt=S.getSource(),Qt=pe.coveringZoomLevel({tileSize:Tt.tileSize,roundZoom:Tt.roundZoom}),cr=!x||Math.abs(x.tileID.overscaledZ-Qt)>Math.abs(b.tileID.overscaledZ-Qt),pr=cr&&b.refreshedUponExpiration?1:y.clamp(cr?dt:1-zt,0,1);return b.refreshedUponExpiration&&dt>=1&&(b.refreshedUponExpiration=!1),x?{opacity:1,mix:1-pr}:{opacity:pr,mix:0}}return{opacity:1,mix:0}}var wl=new y.Color(1,0,0,1),vu=new y.Color(0,1,0,1),ml=new y.Color(0,0,1,1),ll=new y.Color(1,0,1,1),Fu=new y.Color(0,1,1,1);function Bu(b,x,S,U){Ac(b,0,x+S/2,b.transform.width,S,U)}function al(b,x,S,U){Ac(b,x-S/2,0,S,b.transform.height,U)}function Ac(b,x,S,U,pe,Ce){var Oe=b.context,dt=Oe.gl;dt.enable(dt.SCISSOR_TEST),dt.scissor(x*y.browser.devicePixelRatio,S*y.browser.devicePixelRatio,U*y.browser.devicePixelRatio,pe*y.browser.devicePixelRatio),Oe.clear({color:Ce}),dt.disable(dt.SCISSOR_TEST)}function $l(b,x,S){var U=b.context,pe=U.gl,Ce=S.posMatrix,Oe=b.useProgram("debug"),dt=Bt.disabled,zt=Jt.disabled,Tt=b.colorModeForRenderPass();U.activeTexture.set(pe.TEXTURE0),b.emptyTexture.bind(pe.LINEAR,pe.CLAMP_TO_EDGE),Oe.draw(U,pe.LINE_STRIP,dt,zt,Tt,hr.disabled,pl(Ce,y.Color.red),"$debug",b.debugBuffer,b.tileBorderIndexBuffer,b.debugSegments);var Qt=x.getTileByID(S.key).latestRawTileData,cr=Math.floor((Qt&&Qt.byteLength||0)/1024),pr=x.getTile(S).tileSize,zr=512/Math.min(pr,512)*(S.overscaledZ/b.transform.zoom)*.5,jr=S.canonical.toString();S.overscaledZ!==S.canonical.z&&(jr+=" => "+S.overscaledZ),function(tn,Hr){tn.initDebugOverlayCanvas();var fn=tn.debugOverlayCanvas,qt=tn.context.gl,ii=tn.debugOverlayCanvas.getContext("2d");ii.clearRect(0,0,fn.width,fn.height),ii.shadowColor="white",ii.shadowBlur=2,ii.lineWidth=1.5,ii.strokeStyle="white",ii.textBaseline="top",ii.font="bold 36px Open Sans, sans-serif",ii.fillText(Hr,5,5),ii.strokeText(Hr,5,5),tn.debugOverlayTexture.update(fn),tn.debugOverlayTexture.bind(qt.LINEAR,qt.CLAMP_TO_EDGE)}(b,jr+" "+cr+"kb"),Oe.draw(U,pe.TRIANGLES,dt,zt,ar.alphaBlended,hr.disabled,pl(Ce,y.Color.transparent,zr),"$debug",b.debugBuffer,b.quadTriangleIndexBuffer,b.debugSegments)}var Yu={symbol:function(b,x,S,U,pe){if(b.renderPass==="translucent"){var Ce=Jt.disabled,Oe=b.colorModeForRenderPass();S.layout.get("text-variable-anchor")&&function(dt,zt,Tt,Qt,cr,pr,zr){for(var jr=zt.transform,tn=cr==="map",Hr=pr==="map",fn=0,qt=dt;fn256&&this.clearStencil(),S.setColorMode(ar.disabled),S.setDepthMode(Bt.disabled);var pe=this.useProgram("clippingMask");this._tileClippingMaskIDs={};for(var Ce=0,Oe=x;Ce256&&this.clearStencil();var b=this.nextStencilID++,x=this.context.gl;return new Jt({func:x.NOTEQUAL,mask:255},b,255,x.KEEP,x.KEEP,x.REPLACE)},Gu.prototype.stencilModeForClipping=function(b){var x=this.context.gl;return new Jt({func:x.EQUAL,mask:255},this._tileClippingMaskIDs[b.key],0,x.KEEP,x.KEEP,x.REPLACE)},Gu.prototype.stencilConfigForOverlap=function(b){var x,S=this.context.gl,U=b.sort(function(zt,Tt){return Tt.overscaledZ-zt.overscaledZ}),pe=U[U.length-1].overscaledZ,Ce=U[0].overscaledZ-pe+1;if(Ce>1){this.currentStencilSource=void 0,this.nextStencilID+Ce>256&&this.clearStencil();for(var Oe={},dt=0;dt=0;this.currentLayer--){var ii=this.style._layers[U[this.currentLayer]],Ai=pe[ii.source],xr=Tt[ii.source];this._renderTileClippingMasks(ii,xr),this.renderLayer(this,Ai,ii,xr)}for(this.renderPass="translucent",this.currentLayer=0;this.currentLayer0?x.pop():null},Gu.prototype.isPatternMissing=function(b){if(!b)return!1;if(!b.from||!b.to)return!0;var x=this.imageManager.getPattern(b.from.toString()),S=this.imageManager.getPattern(b.to.toString());return!x||!S},Gu.prototype.useProgram=function(b,x){this.cache=this.cache||{};var S=""+b+(x?x.cacheKey:"")+(this._showOverdrawInspector?"/overdraw":"");return this.cache[S]||(this.cache[S]=new su(this.context,b,qs[b],x,an[b],this._showOverdrawInspector)),this.cache[S]},Gu.prototype.setCustomLayerDefaults=function(){this.context.unbindVAO(),this.context.cullFace.setDefault(),this.context.activeTexture.setDefault(),this.context.pixelStoreUnpack.setDefault(),this.context.pixelStoreUnpackPremultiplyAlpha.setDefault(),this.context.pixelStoreUnpackFlipY.setDefault()},Gu.prototype.setBaseState=function(){var b=this.context.gl;this.context.cullFace.set(!1),this.context.viewport.set([0,0,this.width,this.height]),this.context.blendEquation.set(b.FUNC_ADD)},Gu.prototype.initDebugOverlayCanvas=function(){this.debugOverlayCanvas==null&&(this.debugOverlayCanvas=y.window.document.createElement("canvas"),this.debugOverlayCanvas.width=512,this.debugOverlayCanvas.height=512,this.debugOverlayTexture=new y.Texture(this.context,this.debugOverlayCanvas,this.context.gl.RGBA))},Gu.prototype.destroy=function(){this.emptyTexture.destroy(),this.debugOverlayTexture&&this.debugOverlayTexture.destroy()};var Sf=function(b,x){this.points=b,this.planes=x};Sf.fromInvProjectionMatrix=function(b,x,S){var U=Math.pow(2,S),pe=[[-1,1,-1,1],[1,1,-1,1],[1,-1,-1,1],[-1,-1,-1,1],[-1,1,1,1],[1,1,1,1],[1,-1,1,1],[-1,-1,1,1]].map(function(Oe){return y.transformMat4([],Oe,b)}).map(function(Oe){return y.scale$1([],Oe,1/Oe[3]/x*U)}),Ce=[[0,1,2],[6,5,4],[0,3,7],[2,1,5],[3,2,6],[0,4,5]].map(function(Oe){var dt=y.sub([],pe[Oe[0]],pe[Oe[1]]),zt=y.sub([],pe[Oe[2]],pe[Oe[1]]),Tt=y.normalize([],y.cross([],dt,zt)),Qt=-y.dot(Tt,pe[Oe[1]]);return Tt.concat(Qt)});return new Sf(pe,Ce)};var Cl=function(b,x){this.min=b,this.max=x,this.center=y.scale$2([],y.add([],this.min,this.max),.5)};Cl.prototype.quadrant=function(b){for(var x=[b%2==0,b<2],S=y.clone$2(this.min),U=y.clone$2(this.max),pe=0;pe=0;if(Ce===0)return 0;Ce!==x.length&&(S=!1)}if(S)return 2;for(var dt=0;dt<3;dt++){for(var zt=Number.MAX_VALUE,Tt=-Number.MAX_VALUE,Qt=0;Qtthis.max[dt]-this.min[dt])return 0}return 1};var Df=function(b,x,S,U){if(b===void 0&&(b=0),x===void 0&&(x=0),S===void 0&&(S=0),U===void 0&&(U=0),isNaN(b)||b<0||isNaN(x)||x<0||isNaN(S)||S<0||isNaN(U)||U<0)throw new Error("Invalid value for edge-insets, top, bottom, left and right must all be numbers");this.top=b,this.bottom=x,this.left=S,this.right=U};Df.prototype.interpolate=function(b,x,S){return x.top!=null&&b.top!=null&&(this.top=y.number(b.top,x.top,S)),x.bottom!=null&&b.bottom!=null&&(this.bottom=y.number(b.bottom,x.bottom,S)),x.left!=null&&b.left!=null&&(this.left=y.number(b.left,x.left,S)),x.right!=null&&b.right!=null&&(this.right=y.number(b.right,x.right,S)),this},Df.prototype.getCenter=function(b,x){var S=y.clamp((this.left+b-this.right)/2,0,b),U=y.clamp((this.top+x-this.bottom)/2,0,x);return new y.Point(S,U)},Df.prototype.equals=function(b){return this.top===b.top&&this.bottom===b.bottom&&this.left===b.left&&this.right===b.right},Df.prototype.clone=function(){return new Df(this.top,this.bottom,this.left,this.right)},Df.prototype.toJSON=function(){return{top:this.top,bottom:this.bottom,left:this.left,right:this.right}};var bu=function(b,x,S,U,pe){this.tileSize=512,this.maxValidLatitude=85.051129,this._renderWorldCopies=pe===void 0||pe,this._minZoom=b||0,this._maxZoom=x||22,this._minPitch=S==null?0:S,this._maxPitch=U==null?60:U,this.setMaxBounds(),this.width=0,this.height=0,this._center=new y.LngLat(0,0),this.zoom=0,this.angle=0,this._fov=.6435011087932844,this._pitch=0,this._unmodified=!0,this._edgeInsets=new Df,this._posMatrixCache={},this._alignedPosMatrixCache={}},Ic={minZoom:{configurable:!0},maxZoom:{configurable:!0},minPitch:{configurable:!0},maxPitch:{configurable:!0},renderWorldCopies:{configurable:!0},worldSize:{configurable:!0},centerOffset:{configurable:!0},size:{configurable:!0},bearing:{configurable:!0},pitch:{configurable:!0},fov:{configurable:!0},zoom:{configurable:!0},center:{configurable:!0},padding:{configurable:!0},centerPoint:{configurable:!0},unmodified:{configurable:!0},point:{configurable:!0}};bu.prototype.clone=function(){var b=new bu(this._minZoom,this._maxZoom,this._minPitch,this.maxPitch,this._renderWorldCopies);return b.tileSize=this.tileSize,b.latRange=this.latRange,b.width=this.width,b.height=this.height,b._center=this._center,b.zoom=this.zoom,b.angle=this.angle,b._fov=this._fov,b._pitch=this._pitch,b._unmodified=this._unmodified,b._edgeInsets=this._edgeInsets.clone(),b._calcMatrices(),b},Ic.minZoom.get=function(){return this._minZoom},Ic.minZoom.set=function(b){this._minZoom!==b&&(this._minZoom=b,this.zoom=Math.max(this.zoom,b))},Ic.maxZoom.get=function(){return this._maxZoom},Ic.maxZoom.set=function(b){this._maxZoom!==b&&(this._maxZoom=b,this.zoom=Math.min(this.zoom,b))},Ic.minPitch.get=function(){return this._minPitch},Ic.minPitch.set=function(b){this._minPitch!==b&&(this._minPitch=b,this.pitch=Math.max(this.pitch,b))},Ic.maxPitch.get=function(){return this._maxPitch},Ic.maxPitch.set=function(b){this._maxPitch!==b&&(this._maxPitch=b,this.pitch=Math.min(this.pitch,b))},Ic.renderWorldCopies.get=function(){return this._renderWorldCopies},Ic.renderWorldCopies.set=function(b){b===void 0?b=!0:b===null&&(b=!1),this._renderWorldCopies=b},Ic.worldSize.get=function(){return this.tileSize*this.scale},Ic.centerOffset.get=function(){return this.centerPoint._sub(this.size._div(2))},Ic.size.get=function(){return new y.Point(this.width,this.height)},Ic.bearing.get=function(){return-this.angle/Math.PI*180},Ic.bearing.set=function(b){var x=-y.wrap(b,-180,180)*Math.PI/180;this.angle!==x&&(this._unmodified=!1,this.angle=x,this._calcMatrices(),this.rotationMatrix=y.create$2(),y.rotate(this.rotationMatrix,this.rotationMatrix,this.angle))},Ic.pitch.get=function(){return this._pitch/Math.PI*180},Ic.pitch.set=function(b){var x=y.clamp(b,this.minPitch,this.maxPitch)/180*Math.PI;this._pitch!==x&&(this._unmodified=!1,this._pitch=x,this._calcMatrices())},Ic.fov.get=function(){return this._fov/Math.PI*180},Ic.fov.set=function(b){b=Math.max(.01,Math.min(60,b)),this._fov!==b&&(this._unmodified=!1,this._fov=b/180*Math.PI,this._calcMatrices())},Ic.zoom.get=function(){return this._zoom},Ic.zoom.set=function(b){var x=Math.min(Math.max(b,this.minZoom),this.maxZoom);this._zoom!==x&&(this._unmodified=!1,this._zoom=x,this.scale=this.zoomScale(x),this.tileZoom=Math.floor(x),this.zoomFraction=x-this.tileZoom,this._constrain(),this._calcMatrices())},Ic.center.get=function(){return this._center},Ic.center.set=function(b){b.lat===this._center.lat&&b.lng===this._center.lng||(this._unmodified=!1,this._center=b,this._constrain(),this._calcMatrices())},Ic.padding.get=function(){return this._edgeInsets.toJSON()},Ic.padding.set=function(b){this._edgeInsets.equals(b)||(this._unmodified=!1,this._edgeInsets.interpolate(this._edgeInsets,b,1),this._calcMatrices())},Ic.centerPoint.get=function(){return this._edgeInsets.getCenter(this.width,this.height)},bu.prototype.isPaddingEqual=function(b){return this._edgeInsets.equals(b)},bu.prototype.interpolatePadding=function(b,x,S){this._unmodified=!1,this._edgeInsets.interpolate(b,x,S),this._constrain(),this._calcMatrices()},bu.prototype.coveringZoomLevel=function(b){var x=(b.roundZoom?Math.round:Math.floor)(this.zoom+this.scaleZoom(this.tileSize/b.tileSize));return Math.max(0,x)},bu.prototype.getVisibleUnwrappedCoordinates=function(b){var x=[new y.UnwrappedTileID(0,b)];if(this._renderWorldCopies)for(var S=this.pointCoordinate(new y.Point(0,0)),U=this.pointCoordinate(new y.Point(this.width,0)),pe=this.pointCoordinate(new y.Point(this.width,this.height)),Ce=this.pointCoordinate(new y.Point(0,this.height)),Oe=Math.floor(Math.min(S.x,U.x,pe.x,Ce.x)),dt=Math.floor(Math.max(S.x,U.x,pe.x,Ce.x)),zt=Oe-1;zt<=dt+1;zt++)zt!==0&&x.push(new y.UnwrappedTileID(zt,b));return x},bu.prototype.coveringTiles=function(b){var x=this.coveringZoomLevel(b),S=x;if(b.minzoom!==void 0&&xb.maxzoom&&(x=b.maxzoom);var U=y.MercatorCoordinate.fromLngLat(this.center),pe=Math.pow(2,x),Ce=[pe*U.x,pe*U.y,0],Oe=Sf.fromInvProjectionMatrix(this.invProjMatrix,this.worldSize,x),dt=b.minzoom||0;this.pitch<=60&&this._edgeInsets.top<.1&&(dt=x);var zt=function(da){return{aabb:new Cl([da*pe,0,0],[(da+1)*pe,pe,0]),zoom:0,x:0,y:0,wrap:da,fullyVisible:!1}},Tt=[],Qt=[],cr=x,pr=b.reparseOverscaled?S:x;if(this._renderWorldCopies)for(var zr=1;zr<=3;zr++)Tt.push(zt(-zr)),Tt.push(zt(zr));for(Tt.push(zt(0));Tt.length>0;){var jr=Tt.pop(),tn=jr.x,Hr=jr.y,fn=jr.fullyVisible;if(!fn){var qt=jr.aabb.intersects(Oe);if(qt===0)continue;fn=qt===2}var ii=jr.aabb.distanceX(Ce),Ai=jr.aabb.distanceY(Ce),xr=Math.max(Math.abs(ii),Math.abs(Ai));if(jr.zoom===cr||xr>3+(1<=dt)Qt.push({tileID:new y.OverscaledTileID(jr.zoom===cr?pr:jr.zoom,jr.wrap,jr.zoom,tn,Hr),distanceSq:y.sqrLen([Ce[0]-.5-tn,Ce[1]-.5-Hr])});else for(var Ni=0;Ni<4;Ni++){var uo=(tn<<1)+Ni%2,oa=(Hr<<1)+(Ni>>1);Tt.push({aabb:jr.aabb.quadrant(Ni),zoom:jr.zoom+1,x:uo,y:oa,wrap:jr.wrap,fullyVisible:fn})}}return Qt.sort(function(da,Fs){return da.distanceSq-Fs.distanceSq}).map(function(da){return da.tileID})},bu.prototype.resize=function(b,x){this.width=b,this.height=x,this.pixelsToGLUnits=[2/b,-2/x],this._constrain(),this._calcMatrices()},Ic.unmodified.get=function(){return this._unmodified},bu.prototype.zoomScale=function(b){return Math.pow(2,b)},bu.prototype.scaleZoom=function(b){return Math.log(b)/Math.LN2},bu.prototype.project=function(b){var x=y.clamp(b.lat,-this.maxValidLatitude,this.maxValidLatitude);return new y.Point(y.mercatorXfromLng(b.lng)*this.worldSize,y.mercatorYfromLat(x)*this.worldSize)},bu.prototype.unproject=function(b){return new y.MercatorCoordinate(b.x/this.worldSize,b.y/this.worldSize).toLngLat()},Ic.point.get=function(){return this.project(this.center)},bu.prototype.setLocationAtPoint=function(b,x){var S=this.pointCoordinate(x),U=this.pointCoordinate(this.centerPoint),pe=this.locationCoordinate(b),Ce=new y.MercatorCoordinate(pe.x-(S.x-U.x),pe.y-(S.y-U.y));this.center=this.coordinateLocation(Ce),this._renderWorldCopies&&(this.center=this.center.wrap())},bu.prototype.locationPoint=function(b){return this.coordinatePoint(this.locationCoordinate(b))},bu.prototype.pointLocation=function(b){return this.coordinateLocation(this.pointCoordinate(b))},bu.prototype.locationCoordinate=function(b){return y.MercatorCoordinate.fromLngLat(b)},bu.prototype.coordinateLocation=function(b){return b.toLngLat()},bu.prototype.pointCoordinate=function(b){var x=[b.x,b.y,0,1],S=[b.x,b.y,1,1];y.transformMat4(x,x,this.pixelMatrixInverse),y.transformMat4(S,S,this.pixelMatrixInverse);var U=x[3],pe=S[3],Ce=x[1]/U,Oe=S[1]/pe,dt=x[2]/U,zt=S[2]/pe,Tt=dt===zt?0:(0-dt)/(zt-dt);return new y.MercatorCoordinate(y.number(x[0]/U,S[0]/pe,Tt)/this.worldSize,y.number(Ce,Oe,Tt)/this.worldSize)},bu.prototype.coordinatePoint=function(b){var x=[b.x*this.worldSize,b.y*this.worldSize,0,1];return y.transformMat4(x,x,this.pixelMatrix),new y.Point(x[0]/x[3],x[1]/x[3])},bu.prototype.getBounds=function(){return new y.LngLatBounds().extend(this.pointLocation(new y.Point(0,0))).extend(this.pointLocation(new y.Point(this.width,0))).extend(this.pointLocation(new y.Point(this.width,this.height))).extend(this.pointLocation(new y.Point(0,this.height)))},bu.prototype.getMaxBounds=function(){return this.latRange&&this.latRange.length===2&&this.lngRange&&this.lngRange.length===2?new y.LngLatBounds([this.lngRange[0],this.latRange[0]],[this.lngRange[1],this.latRange[1]]):null},bu.prototype.setMaxBounds=function(b){b?(this.lngRange=[b.getWest(),b.getEast()],this.latRange=[b.getSouth(),b.getNorth()],this._constrain()):(this.lngRange=null,this.latRange=[-this.maxValidLatitude,this.maxValidLatitude])},bu.prototype.calculatePosMatrix=function(b,x){x===void 0&&(x=!1);var S=b.key,U=x?this._alignedPosMatrixCache:this._posMatrixCache;if(U[S])return U[S];var pe=b.canonical,Ce=this.worldSize/this.zoomScale(pe.z),Oe=pe.x+Math.pow(2,pe.z)*b.wrap,dt=y.identity(new Float64Array(16));return y.translate(dt,dt,[Oe*Ce,pe.y*Ce,0]),y.scale(dt,dt,[Ce/y.EXTENT,Ce/y.EXTENT,1]),y.multiply(dt,x?this.alignedProjMatrix:this.projMatrix,dt),U[S]=new Float32Array(dt),U[S]},bu.prototype.customLayerMatrix=function(){return this.mercatorMatrix.slice()},bu.prototype._constrain=function(){if(this.center&&this.width&&this.height&&!this._constraining){this._constraining=!0;var b,x,S,U,pe=-90,Ce=90,Oe=-180,dt=180,zt=this.size,Tt=this._unmodified;if(this.latRange){var Qt=this.latRange;pe=y.mercatorYfromLat(Qt[1])*this.worldSize,b=(Ce=y.mercatorYfromLat(Qt[0])*this.worldSize)-peCe&&(U=Ce-tn)}if(this.lngRange){var Hr=pr.x,fn=zt.x/2;Hr-fndt&&(S=dt-fn)}S===void 0&&U===void 0||(this.center=this.unproject(new y.Point(S!==void 0?S:pr.x,U!==void 0?U:pr.y))),this._unmodified=Tt,this._constraining=!1}},bu.prototype._calcMatrices=function(){if(this.height){var b=this.centerOffset;this.cameraToCenterDistance=.5/Math.tan(this._fov/2)*this.height;var x=Math.PI/2+this._pitch,S=this._fov*(.5+b.y/this.height),U=Math.sin(S)*this.cameraToCenterDistance/Math.sin(y.clamp(Math.PI-x-S,.01,Math.PI-.01)),pe=this.point,Ce=pe.x,Oe=pe.y,dt=1.01*(Math.cos(Math.PI/2-this._pitch)*U+this.cameraToCenterDistance),zt=this.height/50,Tt=new Float64Array(16);y.perspective(Tt,this._fov,this.width/this.height,zt,dt),Tt[8]=2*-b.x/this.width,Tt[9]=2*b.y/this.height,y.scale(Tt,Tt,[1,-1,1]),y.translate(Tt,Tt,[0,0,-this.cameraToCenterDistance]),y.rotateX(Tt,Tt,this._pitch),y.rotateZ(Tt,Tt,this.angle),y.translate(Tt,Tt,[-Ce,-Oe,0]),this.mercatorMatrix=y.scale([],Tt,[this.worldSize,this.worldSize,this.worldSize]),y.scale(Tt,Tt,[1,1,y.mercatorZfromAltitude(1,this.center.lat)*this.worldSize,1]),this.projMatrix=Tt,this.invProjMatrix=y.invert([],this.projMatrix);var Qt=this.width%2/2,cr=this.height%2/2,pr=Math.cos(this.angle),zr=Math.sin(this.angle),jr=Ce-Math.round(Ce)+pr*Qt+zr*cr,tn=Oe-Math.round(Oe)+pr*cr+zr*Qt,Hr=new Float64Array(Tt);if(y.translate(Hr,Hr,[jr>.5?jr-1:jr,tn>.5?tn-1:tn,0]),this.alignedProjMatrix=Hr,Tt=y.create(),y.scale(Tt,Tt,[this.width/2,-this.height/2,1]),y.translate(Tt,Tt,[1,-1,0]),this.labelPlaneMatrix=Tt,Tt=y.create(),y.scale(Tt,Tt,[1,-1,1]),y.translate(Tt,Tt,[-1,-1,0]),y.scale(Tt,Tt,[2/this.width,2/this.height,1]),this.glCoordMatrix=Tt,this.pixelMatrix=y.multiply(new Float64Array(16),this.labelPlaneMatrix,this.projMatrix),!(Tt=y.invert(new Float64Array(16),this.pixelMatrix)))throw new Error("failed to invert matrix");this.pixelMatrixInverse=Tt,this._posMatrixCache={},this._alignedPosMatrixCache={}}},bu.prototype.maxPitchScaleFactor=function(){if(!this.pixelMatrixInverse)return 1;var b=this.pointCoordinate(new y.Point(0,0)),x=[b.x*this.worldSize,b.y*this.worldSize,0,1];return y.transformMat4(x,x,this.pixelMatrix)[3]/this.cameraToCenterDistance},bu.prototype.getCameraPoint=function(){var b=Math.tan(this._pitch)*(this.cameraToCenterDistance||1);return this.centerPoint.add(new y.Point(0,b))},bu.prototype.getCameraQueryGeometry=function(b){var x=this.getCameraPoint();if(b.length===1)return[b[0],x];for(var S=x.x,U=x.y,pe=x.x,Ce=x.y,Oe=0,dt=b;Oe=3&&!b.some(function(S){return isNaN(S)})){var x=this._map.dragRotate.isEnabled()&&this._map.touchZoomRotate.isEnabled()?+(b[3]||0):this._map.getBearing();return this._map.jumpTo({center:[+b[2],+b[1]],zoom:+b[0],bearing:x,pitch:+(b[4]||0)}),!0}return!1},af.prototype._updateHashUnthrottled=function(){var b=y.window.location.href.replace(/(#.+)?$/,this.getHashString());try{y.window.history.replaceState(y.window.history.state,null,b)}catch(x){}};var zf={linearity:.3,easing:y.bezier(0,0,.3,1)},tf=y.extend({deceleration:2500,maxSpeed:1400},zf),kf=y.extend({deceleration:20,maxSpeed:1400},zf),ff=y.extend({deceleration:1e3,maxSpeed:360},zf),vf=y.extend({deceleration:1e3,maxSpeed:90},zf),wc=function(b){this._map=b,this.clear()};function ac(b,x){(!b.duration||b.duration0&&x-b[0].time>160;)b.shift()},wc.prototype._onMoveEnd=function(b){if(this._drainInertiaBuffer(),!(this._inertiaBuffer.length<2)){for(var x={zoom:0,bearing:0,pitch:0,pan:new y.Point(0,0),pinchAround:void 0,around:void 0},S=0,U=this._inertiaBuffer;S=this._clickTolerance||this._map.fire(new Us(b.type,this._map,b))},Ca.prototype.dblclick=function(b){return this._firePreventable(new Us(b.type,this._map,b))},Ca.prototype.mouseover=function(b){this._map.fire(new Us(b.type,this._map,b))},Ca.prototype.mouseout=function(b){this._map.fire(new Us(b.type,this._map,b))},Ca.prototype.touchstart=function(b){return this._firePreventable(new vl(b.type,this._map,b))},Ca.prototype.touchmove=function(b){this._map.fire(new vl(b.type,this._map,b))},Ca.prototype.touchend=function(b){this._map.fire(new vl(b.type,this._map,b))},Ca.prototype.touchcancel=function(b){this._map.fire(new vl(b.type,this._map,b))},Ca.prototype._firePreventable=function(b){if(this._map.fire(b),b.defaultPrevented)return{}},Ca.prototype.isEnabled=function(){return!0},Ca.prototype.isActive=function(){return!1},Ca.prototype.enable=function(){},Ca.prototype.disable=function(){};var xa=function(b){this._map=b};xa.prototype.reset=function(){this._delayContextMenu=!1,delete this._contextMenuEvent},xa.prototype.mousemove=function(b){this._map.fire(new Us(b.type,this._map,b))},xa.prototype.mousedown=function(){this._delayContextMenu=!0},xa.prototype.mouseup=function(){this._delayContextMenu=!1,this._contextMenuEvent&&(this._map.fire(new Us("contextmenu",this._map,this._contextMenuEvent)),delete this._contextMenuEvent)},xa.prototype.contextmenu=function(b){this._delayContextMenu?this._contextMenuEvent=b:this._map.fire(new Us(b.type,this._map,b)),this._map.listens("contextmenu")&&b.preventDefault()},xa.prototype.isEnabled=function(){return!0},xa.prototype.isActive=function(){return!1},xa.prototype.enable=function(){},xa.prototype.disable=function(){};var Dl=function(b,x){this._map=b,this._el=b.getCanvasContainer(),this._container=b.getContainer(),this._clickTolerance=x.clickTolerance||1};function Gf(b,x){for(var S={},U=0;Uthis.numTouches)&&(this.aborted=!0),this.aborted||(this.startTime===void 0&&(this.startTime=b.timeStamp),S.length===this.numTouches&&(this.centroid=function(U){for(var pe=new y.Point(0,0),Ce=0,Oe=U;Ce30)&&(this.aborted=!0)}}},Li.prototype.touchend=function(b,x,S){if((!this.centroid||b.timeStamp-this.startTime>500)&&(this.aborted=!0),S.length===0){var U=!this.aborted&&this.centroid;if(this.reset(),U)return U}};var Fr=function(b){this.singleTap=new Li(b),this.numTaps=b.numTaps,this.reset()};Fr.prototype.reset=function(){this.lastTime=1/0,delete this.lastTap,this.count=0,this.singleTap.reset()},Fr.prototype.touchstart=function(b,x,S){this.singleTap.touchstart(b,x,S)},Fr.prototype.touchmove=function(b,x,S){this.singleTap.touchmove(b,x,S)},Fr.prototype.touchend=function(b,x,S){var U=this.singleTap.touchend(b,x,S);if(U){var pe=b.timeStamp-this.lastTime<500,Ce=!this.lastTap||this.lastTap.dist(U)<30;if(pe&&Ce||this.reset(),this.count++,this.lastTime=b.timeStamp,this.lastTap=U,this.count===this.numTaps)return this.reset(),U}};var Hl=function(){this._zoomIn=new Fr({numTouches:1,numTaps:2}),this._zoomOut=new Fr({numTouches:2,numTaps:1}),this.reset()};Hl.prototype.reset=function(){this._active=!1,this._zoomIn.reset(),this._zoomOut.reset()},Hl.prototype.touchstart=function(b,x,S){this._zoomIn.touchstart(b,x,S),this._zoomOut.touchstart(b,x,S)},Hl.prototype.touchmove=function(b,x,S){this._zoomIn.touchmove(b,x,S),this._zoomOut.touchmove(b,x,S)},Hl.prototype.touchend=function(b,x,S){var U=this,pe=this._zoomIn.touchend(b,x,S),Ce=this._zoomOut.touchend(b,x,S);return pe?(this._active=!0,b.preventDefault(),setTimeout(function(){return U.reset()},0),{cameraAnimation:function(Oe){return Oe.easeTo({duration:300,zoom:Oe.getZoom()+1,around:Oe.unproject(pe)},{originalEvent:b})}}):Ce?(this._active=!0,b.preventDefault(),setTimeout(function(){return U.reset()},0),{cameraAnimation:function(Oe){return Oe.easeTo({duration:300,zoom:Oe.getZoom()-1,around:Oe.unproject(Ce)},{originalEvent:b})}}):void 0},Hl.prototype.touchcancel=function(){this.reset()},Hl.prototype.enable=function(){this._enabled=!0},Hl.prototype.disable=function(){this._enabled=!1,this.reset()},Hl.prototype.isEnabled=function(){return this._enabled},Hl.prototype.isActive=function(){return this._active};var Ur={0:1,2:2},ja=function(b){this.reset(),this._clickTolerance=b.clickTolerance||1};ja.prototype.blur=function(){this.reset()},ja.prototype.reset=function(){this._active=!1,this._moved=!1,delete this._lastPoint,delete this._eventButton},ja.prototype._correctButton=function(b,x){return!1},ja.prototype._move=function(b,x){return{}},ja.prototype.mousedown=function(b,x){if(!this._lastPoint){var S=$.mouseButton(b);this._correctButton(b,S)&&(this._lastPoint=x,this._eventButton=S)}},ja.prototype.mousemoveWindow=function(b,x){var S=this._lastPoint;if(S){if(b.preventDefault(),function(U,pe){var Ce=Ur[pe];return U.buttons===void 0||(U.buttons&Ce)!==Ce}(b,this._eventButton))this.reset();else if(this._moved||!(x.dist(S)0&&(this._active=!0);var U=Gf(S,x),pe=new y.Point(0,0),Ce=new y.Point(0,0),Oe=0;for(var dt in U){var zt=U[dt],Tt=this._touches[dt];Tt&&(pe._add(zt),Ce._add(zt.sub(Tt)),Oe++,U[dt]=zt)}if(this._touches=U,!(OeMath.abs(b.x)}var Wc=function(b){function x(){b.apply(this,arguments)}return b&&(x.__proto__=b),(x.prototype=Object.create(b&&b.prototype)).constructor=x,x.prototype.reset=function(){b.prototype.reset.call(this),this._valid=void 0,delete this._firstMove,delete this._lastPoints},x.prototype._start=function(S){this._lastPoints=S,kl(S[0].sub(S[1]))&&(this._valid=!1)},x.prototype._move=function(S,U,pe){var Ce=S[0].sub(this._lastPoints[0]),Oe=S[1].sub(this._lastPoints[1]);if(this._valid=this.gestureBeginsVertically(Ce,Oe,pe.timeStamp),this._valid)return this._lastPoints=S,this._active=!0,{pitchDelta:(Ce.y+Oe.y)/2*-.5}},x.prototype.gestureBeginsVertically=function(S,U,pe){if(this._valid!==void 0)return this._valid;var Ce=S.mag()>=2,Oe=U.mag()>=2;if(Ce||Oe){if(!Ce||!Oe)return this._firstMove===void 0&&(this._firstMove=pe),pe-this._firstMove<100&&void 0;var dt=S.y>0==U.y>0;return kl(S)&&kl(U)&&dt}},x}(Wu),Tl={panStep:100,bearingStep:15,pitchStep:10},ql=function(){var b=Tl;this._panStep=b.panStep,this._bearingStep=b.bearingStep,this._pitchStep=b.pitchStep,this._rotationDisabled=!1};function ic(b){return b*(2-b)}ql.prototype.blur=function(){this.reset()},ql.prototype.reset=function(){this._active=!1},ql.prototype.keydown=function(b){var x=this;if(!(b.altKey||b.ctrlKey||b.metaKey)){var S=0,U=0,pe=0,Ce=0,Oe=0;switch(b.keyCode){case 61:case 107:case 171:case 187:S=1;break;case 189:case 109:case 173:S=-1;break;case 37:b.shiftKey?U=-1:(b.preventDefault(),Ce=-1);break;case 39:b.shiftKey?U=1:(b.preventDefault(),Ce=1);break;case 38:b.shiftKey?pe=1:(b.preventDefault(),Oe=-1);break;case 40:b.shiftKey?pe=-1:(b.preventDefault(),Oe=1);break;default:return}return this._rotationDisabled&&(U=0,pe=0),{cameraAnimation:function(dt){var zt=dt.getZoom();dt.easeTo({duration:300,easeId:"keyboardHandler",easing:ic,zoom:S?Math.round(zt)+S*(b.shiftKey?2:1):zt,bearing:dt.getBearing()+U*x._bearingStep,pitch:dt.getPitch()+pe*x._pitchStep,offset:[-Ce*x._panStep,-Oe*x._panStep],center:dt.getCenter()},{originalEvent:b})}}}},ql.prototype.enable=function(){this._enabled=!0},ql.prototype.disable=function(){this._enabled=!1,this.reset()},ql.prototype.isEnabled=function(){return this._enabled},ql.prototype.isActive=function(){return this._active},ql.prototype.disableRotation=function(){this._rotationDisabled=!0},ql.prototype.enableRotation=function(){this._rotationDisabled=!1};var Ls=function(b,x){this._map=b,this._el=b.getCanvasContainer(),this._handler=x,this._delta=0,this._defaultZoomRate=.01,this._wheelZoomRate=1/450,y.bindAll(["_onTimeout"],this)};Ls.prototype.setZoomRate=function(b){this._defaultZoomRate=b},Ls.prototype.setWheelZoomRate=function(b){this._wheelZoomRate=b},Ls.prototype.isEnabled=function(){return!!this._enabled},Ls.prototype.isActive=function(){return!!this._active||this._finishTimeout!==void 0},Ls.prototype.isZooming=function(){return!!this._zooming},Ls.prototype.enable=function(b){this.isEnabled()||(this._enabled=!0,this._aroundCenter=b&&b.around==="center")},Ls.prototype.disable=function(){this.isEnabled()&&(this._enabled=!1)},Ls.prototype.wheel=function(b){if(this.isEnabled()){var x=b.deltaMode===y.window.WheelEvent.DOM_DELTA_LINE?40*b.deltaY:b.deltaY,S=y.browser.now(),U=S-(this._lastWheelEventTime||0);this._lastWheelEventTime=S,x!==0&&x%4.000244140625==0?this._type="wheel":x!==0&&Math.abs(x)<4?this._type="trackpad":U>400?(this._type=null,this._lastValue=x,this._timeout=setTimeout(this._onTimeout,40,b)):this._type||(this._type=Math.abs(U*x)<200?"trackpad":"wheel",this._timeout&&(clearTimeout(this._timeout),this._timeout=null,x+=this._lastValue)),b.shiftKey&&x&&(x/=4),this._type&&(this._lastWheelEvent=b,this._delta-=x,this._active||this._start(b)),b.preventDefault()}},Ls.prototype._onTimeout=function(b){this._type="wheel",this._delta-=this._lastValue,this._active||this._start(b)},Ls.prototype._start=function(b){if(this._delta){this._frameId&&(this._frameId=null),this._active=!0,this.isZooming()||(this._zooming=!0),this._finishTimeout&&(clearTimeout(this._finishTimeout),delete this._finishTimeout);var x=$.mousePos(this._el,b);this._around=y.LngLat.convert(this._aroundCenter?this._map.getCenter():this._map.unproject(x)),this._aroundPoint=this._map.transform.locationPoint(this._around),this._frameId||(this._frameId=!0,this._handler._triggerRenderFrame())}},Ls.prototype.renderFrame=function(){var b=this;if(this._frameId&&(this._frameId=null,this.isActive())){var x=this._map.transform;if(this._delta!==0){var S=this._type==="wheel"&&Math.abs(this._delta)>4.000244140625?this._wheelZoomRate:this._defaultZoomRate,U=2/(1+Math.exp(-Math.abs(this._delta*S)));this._delta<0&&U!==0&&(U=1/U);var pe=typeof this._targetZoom=="number"?x.zoomScale(this._targetZoom):x.scale;this._targetZoom=Math.min(x.maxZoom,Math.max(x.minZoom,x.scaleZoom(pe*U))),this._type==="wheel"&&(this._startZoom=x.zoom,this._easing=this._smoothOutEasing(200)),this._delta=0}var Ce,Oe=typeof this._targetZoom=="number"?this._targetZoom:x.zoom,dt=this._startZoom,zt=this._easing,Tt=!1;if(this._type==="wheel"&&dt&&zt){var Qt=Math.min((y.browser.now()-this._lastWheelEventTime)/200,1),cr=zt(Qt);Ce=y.number(dt,Oe,cr),Qt<1?this._frameId||(this._frameId=!0):Tt=!0}else Ce=Oe,Tt=!0;return this._active=!0,Tt&&(this._active=!1,this._finishTimeout=setTimeout(function(){b._zooming=!1,b._handler._triggerRenderFrame(),delete b._targetZoom,delete b._finishTimeout},200)),{noInertia:!0,needsRenderFrame:!Tt,zoomDelta:Ce-x.zoom,around:this._aroundPoint,originalEvent:this._lastWheelEvent}}},Ls.prototype._smoothOutEasing=function(b){var x=y.ease;if(this._prevEase){var S=this._prevEase,U=(y.browser.now()-S.start)/S.duration,pe=S.easing(U+.01)-S.easing(U),Ce=.27/Math.sqrt(pe*pe+1e-4)*.01,Oe=Math.sqrt(.0729-Ce*Ce);x=y.bezier(Ce,Oe,.25,1)}return this._prevEase={start:y.browser.now(),duration:b,easing:x},x},Ls.prototype.blur=function(){this.reset()},Ls.prototype.reset=function(){this._active=!1};var cc=function(b,x){this._clickZoom=b,this._tapZoom=x};cc.prototype.enable=function(){this._clickZoom.enable(),this._tapZoom.enable()},cc.prototype.disable=function(){this._clickZoom.disable(),this._tapZoom.disable()},cc.prototype.isEnabled=function(){return this._clickZoom.isEnabled()&&this._tapZoom.isEnabled()},cc.prototype.isActive=function(){return this._clickZoom.isActive()||this._tapZoom.isActive()};var gu=function(){this.reset()};gu.prototype.reset=function(){this._active=!1},gu.prototype.blur=function(){this.reset()},gu.prototype.dblclick=function(b,x){return b.preventDefault(),{cameraAnimation:function(S){S.easeTo({duration:300,zoom:S.getZoom()+(b.shiftKey?-1:1),around:S.unproject(x)},{originalEvent:b})}}},gu.prototype.enable=function(){this._enabled=!0},gu.prototype.disable=function(){this._enabled=!1,this.reset()},gu.prototype.isEnabled=function(){return this._enabled},gu.prototype.isActive=function(){return this._active};var Cu=function(){this._tap=new Fr({numTouches:1,numTaps:1}),this.reset()};Cu.prototype.reset=function(){this._active=!1,delete this._swipePoint,delete this._swipeTouch,delete this._tapTime,this._tap.reset()},Cu.prototype.touchstart=function(b,x,S){this._swipePoint||(this._tapTime&&b.timeStamp-this._tapTime>500&&this.reset(),this._tapTime?S.length>0&&(this._swipePoint=x[0],this._swipeTouch=S[0].identifier):this._tap.touchstart(b,x,S))},Cu.prototype.touchmove=function(b,x,S){if(this._tapTime){if(this._swipePoint){if(S[0].identifier!==this._swipeTouch)return;var U=x[0],pe=U.y-this._swipePoint.y;return this._swipePoint=U,b.preventDefault(),this._active=!0,{zoomDelta:pe/128}}}else this._tap.touchmove(b,x,S)},Cu.prototype.touchend=function(b,x,S){this._tapTime?this._swipePoint&&S.length===0&&this.reset():this._tap.touchend(b,x,S)&&(this._tapTime=b.timeStamp)},Cu.prototype.touchcancel=function(){this.reset()},Cu.prototype.enable=function(){this._enabled=!0},Cu.prototype.disable=function(){this._enabled=!1,this.reset()},Cu.prototype.isEnabled=function(){return this._enabled},Cu.prototype.isActive=function(){return this._active};var Qc=function(b,x,S){this._el=b,this._mousePan=x,this._touchPan=S};Qc.prototype.enable=function(b){this._inertiaOptions=b||{},this._mousePan.enable(),this._touchPan.enable(),this._el.classList.add("mapboxgl-touch-drag-pan")},Qc.prototype.disable=function(){this._mousePan.disable(),this._touchPan.disable(),this._el.classList.remove("mapboxgl-touch-drag-pan")},Qc.prototype.isEnabled=function(){return this._mousePan.isEnabled()&&this._touchPan.isEnabled()},Qc.prototype.isActive=function(){return this._mousePan.isActive()||this._touchPan.isActive()};var hf=function(b,x,S){this._pitchWithRotate=b.pitchWithRotate,this._mouseRotate=x,this._mousePitch=S};hf.prototype.enable=function(){this._mouseRotate.enable(),this._pitchWithRotate&&this._mousePitch.enable()},hf.prototype.disable=function(){this._mouseRotate.disable(),this._mousePitch.disable()},hf.prototype.isEnabled=function(){return this._mouseRotate.isEnabled()&&(!this._pitchWithRotate||this._mousePitch.isEnabled())},hf.prototype.isActive=function(){return this._mouseRotate.isActive()||this._mousePitch.isActive()};var Xc=function(b,x,S,U){this._el=b,this._touchZoom=x,this._touchRotate=S,this._tapDragZoom=U,this._rotationDisabled=!1,this._enabled=!0};Xc.prototype.enable=function(b){this._touchZoom.enable(b),this._rotationDisabled||this._touchRotate.enable(b),this._tapDragZoom.enable(),this._el.classList.add("mapboxgl-touch-zoom-rotate")},Xc.prototype.disable=function(){this._touchZoom.disable(),this._touchRotate.disable(),this._tapDragZoom.disable(),this._el.classList.remove("mapboxgl-touch-zoom-rotate")},Xc.prototype.isEnabled=function(){return this._touchZoom.isEnabled()&&(this._rotationDisabled||this._touchRotate.isEnabled())&&this._tapDragZoom.isEnabled()},Xc.prototype.isActive=function(){return this._touchZoom.isActive()||this._touchRotate.isActive()||this._tapDragZoom.isActive()},Xc.prototype.disableRotation=function(){this._rotationDisabled=!0,this._touchRotate.disable()},Xc.prototype.enableRotation=function(){this._rotationDisabled=!1,this._touchZoom.isEnabled()&&this._touchRotate.enable()};var Al=function(b){return b.zoom||b.drag||b.pitch||b.rotate},Sc=function(b){function x(){b.apply(this,arguments)}return b&&(x.__proto__=b),(x.prototype=Object.create(b&&b.prototype)).constructor=x,x}(y.Event);function Ka(b){return b.panDelta&&b.panDelta.mag()||b.zoomDelta||b.bearingDelta||b.pitchDelta}var ea=function(b,x){this._map=b,this._el=this._map.getCanvasContainer(),this._handlers=[],this._handlersById={},this._changes=[],this._inertia=new wc(b),this._bearingSnap=x.bearingSnap,this._previousActiveHandlers={},this._eventsInProgress={},this._addDefaultHandlers(x),y.bindAll(["handleEvent","handleWindowEvent"],this);var S=this._el;this._listeners=[[S,"touchstart",{passive:!0}],[S,"touchmove",{passive:!1}],[S,"touchend",void 0],[S,"touchcancel",void 0],[S,"mousedown",void 0],[S,"mousemove",void 0],[S,"mouseup",void 0],[y.window.document,"mousemove",{capture:!0}],[y.window.document,"mouseup",void 0],[S,"mouseover",void 0],[S,"mouseout",void 0],[S,"dblclick",void 0],[S,"click",void 0],[S,"keydown",{capture:!1}],[S,"keyup",void 0],[S,"wheel",{passive:!1}],[S,"contextmenu",void 0],[y.window,"blur",void 0]];for(var U=0,pe=this._listeners;UOe?Math.min(2,Ni):Math.max(.5,Ni),hu=Math.pow(Fs,1-oa),qr=Ce.unproject(Ai.add(xr.mult(oa*hu)).mult(da));Ce.setLocationAtPoint(Ce.renderWorldCopies?qr.wrap():qr,tn)}pe._fireMoveEvents(U)},function(oa){pe._afterEase(U,oa)},S),this},x.prototype._prepareEase=function(S,U,pe){pe===void 0&&(pe={}),this._moving=!0,U||pe.moving||this.fire(new y.Event("movestart",S)),this._zooming&&!pe.zooming&&this.fire(new y.Event("zoomstart",S)),this._rotating&&!pe.rotating&&this.fire(new y.Event("rotatestart",S)),this._pitching&&!pe.pitching&&this.fire(new y.Event("pitchstart",S))},x.prototype._fireMoveEvents=function(S){this.fire(new y.Event("move",S)),this._zooming&&this.fire(new y.Event("zoom",S)),this._rotating&&this.fire(new y.Event("rotate",S)),this._pitching&&this.fire(new y.Event("pitch",S))},x.prototype._afterEase=function(S,U){if(!this._easeId||!U||this._easeId!==U){delete this._easeId;var pe=this._zooming,Ce=this._rotating,Oe=this._pitching;this._moving=!1,this._zooming=!1,this._rotating=!1,this._pitching=!1,this._padding=!1,pe&&this.fire(new y.Event("zoomend",S)),Ce&&this.fire(new y.Event("rotateend",S)),Oe&&this.fire(new y.Event("pitchend",S)),this.fire(new y.Event("moveend",S))}},x.prototype.flyTo=function(S,U){var pe=this;if(!S.essential&&y.browser.prefersReducedMotion){var Ce=y.pick(S,["center","zoom","bearing","pitch","around"]);return this.jumpTo(Ce,U)}this.stop(),S=y.extend({offset:[0,0],speed:1.2,curve:1.42,easing:y.ease},S);var Oe=this.transform,dt=this.getZoom(),zt=this.getBearing(),Tt=this.getPitch(),Qt=this.getPadding(),cr="zoom"in S?y.clamp(+S.zoom,Oe.minZoom,Oe.maxZoom):dt,pr="bearing"in S?this._normalizeBearing(S.bearing,zt):zt,zr="pitch"in S?+S.pitch:Tt,jr="padding"in S?S.padding:Oe.padding,tn=Oe.zoomScale(cr-dt),Hr=y.Point.convert(S.offset),fn=Oe.centerPoint.add(Hr),qt=Oe.pointLocation(fn),ii=y.LngLat.convert(S.center||qt);this._normalizeCenter(ii);var Ai=Oe.project(qt),xr=Oe.project(ii).sub(Ai),Ni=S.curve,uo=Math.max(Oe.width,Oe.height),oa=uo/tn,da=xr.mag();if("minZoom"in S){var Fs=y.clamp(Math.min(S.minZoom,dt,cr),Oe.minZoom,Oe.maxZoom),hu=uo/Oe.zoomScale(Fs-dt);Ni=Math.sqrt(hu/da*2)}var qr=Ni*Ni;function Zu(bc){var wu=(oa*oa-uo*uo+(bc?-1:1)*qr*qr*da*da)/(2*(bc?oa:uo)*qr*da);return Math.log(Math.sqrt(wu*wu+1)-wu)}function Bc(bc){return(Math.exp(bc)-Math.exp(-bc))/2}function ou(bc){return(Math.exp(bc)+Math.exp(-bc))/2}var rl=Zu(0),Nc=function(bc){return ou(rl)/ou(rl+Ni*bc)},Cc=function(bc){return uo*((ou(rl)*(Bc(wu=rl+Ni*bc)/ou(wu))-Bc(rl))/qr)/da;var wu},Gl=(Zu(1)-rl)/Ni;if(Math.abs(da)<1e-6||!isFinite(Gl)){if(Math.abs(uo-oa)<1e-6)return this.easeTo(S,U);var Oc=oaS.maxDuration&&(S.duration=0),this._zooming=!0,this._rotating=zt!==pr,this._pitching=zr!==Tt,this._padding=!Oe.isPaddingEqual(jr),this._prepareEase(U,!1),this._ease(function(bc){var wu=bc*Gl,rf=1/Nc(wu);Oe.zoom=bc===1?cr:dt+Oe.scaleZoom(rf),pe._rotating&&(Oe.bearing=y.number(zt,pr,bc)),pe._pitching&&(Oe.pitch=y.number(Tt,zr,bc)),pe._padding&&(Oe.interpolatePadding(Qt,jr,bc),fn=Oe.centerPoint.add(Hr));var xf=bc===1?ii:Oe.unproject(Ai.add(xr.mult(Cc(wu))).mult(rf));Oe.setLocationAtPoint(Oe.renderWorldCopies?xf.wrap():xf,fn),pe._fireMoveEvents(U)},function(){return pe._afterEase(U)},S),this},x.prototype.isEasing=function(){return!!this._easeFrameId},x.prototype.stop=function(){return this._stop()},x.prototype._stop=function(S,U){if(this._easeFrameId&&(this._cancelRenderFrame(this._easeFrameId),delete this._easeFrameId,delete this._onEaseFrame),this._onEaseEnd){var pe=this._onEaseEnd;delete this._onEaseEnd,pe.call(this,U)}if(!S){var Ce=this.handlers;Ce&&Ce.stop(!1)}return this},x.prototype._ease=function(S,U,pe){pe.animate===!1||pe.duration===0?(S(1),U()):(this._easeStart=y.browser.now(),this._easeOptions=pe,this._onEaseFrame=S,this._onEaseEnd=U,this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback))},x.prototype._renderFrameCallback=function(){var S=Math.min((y.browser.now()-this._easeStart)/this._easeOptions.duration,1);this._onEaseFrame(this._easeOptions.easing(S)),S<1?this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback):this.stop()},x.prototype._normalizeBearing=function(S,U){S=y.wrap(S,-180,180);var pe=Math.abs(S-U);return Math.abs(S-360-U)180?-360:pe<-180?360:0}},x}(y.Evented),tu=function(b){b===void 0&&(b={}),this.options=b,y.bindAll(["_toggleAttribution","_updateEditLink","_updateData","_updateCompact"],this)};tu.prototype.getDefaultPosition=function(){return"bottom-right"},tu.prototype.onAdd=function(b){var x=this.options&&this.options.compact;return this._map=b,this._container=$.create("div","mapboxgl-ctrl mapboxgl-ctrl-attrib"),this._compactButton=$.create("button","mapboxgl-ctrl-attrib-button",this._container),this._compactButton.addEventListener("click",this._toggleAttribution),this._setElementTitle(this._compactButton,"ToggleAttribution"),this._innerContainer=$.create("div","mapboxgl-ctrl-attrib-inner",this._container),this._innerContainer.setAttribute("role","list"),x&&this._container.classList.add("mapboxgl-compact"),this._updateAttributions(),this._updateEditLink(),this._map.on("styledata",this._updateData),this._map.on("sourcedata",this._updateData),this._map.on("moveend",this._updateEditLink),x===void 0&&(this._map.on("resize",this._updateCompact),this._updateCompact()),this._container},tu.prototype.onRemove=function(){$.remove(this._container),this._map.off("styledata",this._updateData),this._map.off("sourcedata",this._updateData),this._map.off("moveend",this._updateEditLink),this._map.off("resize",this._updateCompact),this._map=void 0,this._attribHTML=void 0},tu.prototype._setElementTitle=function(b,x){var S=this._map._getUIString("AttributionControl."+x);b.title=S,b.setAttribute("aria-label",S)},tu.prototype._toggleAttribution=function(){this._container.classList.contains("mapboxgl-compact-show")?(this._container.classList.remove("mapboxgl-compact-show"),this._compactButton.setAttribute("aria-pressed","false")):(this._container.classList.add("mapboxgl-compact-show"),this._compactButton.setAttribute("aria-pressed","true"))},tu.prototype._updateEditLink=function(){var b=this._editLink;b||(b=this._editLink=this._container.querySelector(".mapbox-improve-map"));var x=[{key:"owner",value:this.styleOwner},{key:"id",value:this.styleId},{key:"access_token",value:this._map._requestManager._customAccessToken||y.config.ACCESS_TOKEN}];if(b){var S=x.reduce(function(U,pe,Ce){return pe.value&&(U+=pe.key+"="+pe.value+(Ce=0)return!1;return!0})).join(" | ");Oe!==this._attribHTML&&(this._attribHTML=Oe,b.length?(this._innerContainer.innerHTML=Oe,this._container.classList.remove("mapboxgl-attrib-empty")):this._container.classList.add("mapboxgl-attrib-empty"),this._editLink=null)}},tu.prototype._updateCompact=function(){this._map.getCanvasContainer().offsetWidth<=640?this._container.classList.add("mapboxgl-compact"):this._container.classList.remove("mapboxgl-compact","mapboxgl-compact-show")};var bh=function(){y.bindAll(["_updateLogo"],this),y.bindAll(["_updateCompact"],this)};bh.prototype.onAdd=function(b){this._map=b,this._container=$.create("div","mapboxgl-ctrl");var x=$.create("a","mapboxgl-ctrl-logo");return x.target="_blank",x.rel="noopener nofollow",x.href="https://www.mapbox.com/",x.setAttribute("aria-label",this._map._getUIString("LogoControl.Title")),x.setAttribute("rel","noopener nofollow"),this._container.appendChild(x),this._container.style.display="none",this._map.on("sourcedata",this._updateLogo),this._updateLogo(),this._map.on("resize",this._updateCompact),this._updateCompact(),this._container},bh.prototype.onRemove=function(){$.remove(this._container),this._map.off("sourcedata",this._updateLogo),this._map.off("resize",this._updateCompact)},bh.prototype.getDefaultPosition=function(){return"bottom-left"},bh.prototype._updateLogo=function(b){b&&b.sourceDataType!=="metadata"||(this._container.style.display=this._logoRequired()?"block":"none")},bh.prototype._logoRequired=function(){if(this._map.style){var b=this._map.style.sourceCaches;for(var x in b)if(b[x].getSource().mapbox_logo)return!0;return!1}},bh.prototype._updateCompact=function(){var b=this._container.children;if(b.length){var x=b[0];this._map.getCanvasContainer().offsetWidth<250?x.classList.add("mapboxgl-compact"):x.classList.remove("mapboxgl-compact")}};var pc=function(){this._queue=[],this._id=0,this._cleared=!1,this._currentlyRunning=!1};pc.prototype.add=function(b){var x=++this._id;return this._queue.push({callback:b,id:x,cancelled:!1}),x},pc.prototype.remove=function(b){for(var x=this._currentlyRunning,S=0,U=x?this._queue.concat(x):this._queue;SU.maxZoom)throw new Error("maxZoom must be greater than or equal to minZoom");if(U.minPitch!=null&&U.maxPitch!=null&&U.minPitch>U.maxPitch)throw new Error("maxPitch must be greater than or equal to minPitch");if(U.minPitch!=null&&U.minPitch<0)throw new Error("minPitch must be greater than or equal to 0");if(U.maxPitch!=null&&U.maxPitch>60)throw new Error("maxPitch must be less than or equal to 60");var Ce=new bu(U.minZoom,U.maxZoom,U.minPitch,U.maxPitch,U.renderWorldCopies);if(b.call(this,Ce,U),this._interactive=U.interactive,this._maxTileCacheSize=U.maxTileCacheSize,this._failIfMajorPerformanceCaveat=U.failIfMajorPerformanceCaveat,this._preserveDrawingBuffer=U.preserveDrawingBuffer,this._antialias=U.antialias,this._trackResize=U.trackResize,this._bearingSnap=U.bearingSnap,this._refreshExpiredTiles=U.refreshExpiredTiles,this._fadeDuration=U.fadeDuration,this._crossSourceCollisions=U.crossSourceCollisions,this._crossFadingFactor=1,this._collectResourceTiming=U.collectResourceTiming,this._renderTaskQueue=new pc,this._controls=[],this._mapId=y.uniqueId(),this._locale=y.extend({},Wf,U.locale),this._clickTolerance=U.clickTolerance,this._requestManager=new y.RequestManager(U.transformRequest,U.accessToken),typeof U.container=="string"){if(this._container=y.window.document.getElementById(U.container),!this._container)throw new Error("Container '"+U.container+"' not found.")}else{if(!(U.container instanceof Ih))throw new Error("Invalid type: 'container' must be a String or HTMLElement.");this._container=U.container}if(U.maxBounds&&this.setMaxBounds(U.maxBounds),y.bindAll(["_onWindowOnline","_onWindowResize","_onMapScroll","_contextLost","_contextRestored"],this),this._setupContainer(),this._setupPainter(),this.painter===void 0)throw new Error("Failed to initialize WebGL.");this.on("move",function(){return pe._update(!1)}),this.on("moveend",function(){return pe._update(!1)}),this.on("zoom",function(){return pe._update(!0)}),y.window!==void 0&&(y.window.addEventListener("online",this._onWindowOnline,!1),y.window.addEventListener("resize",this._onWindowResize,!1),y.window.addEventListener("orientationchange",this._onWindowResize,!1)),this.handlers=new ea(this,U),this._hash=U.hash&&new af(typeof U.hash=="string"&&U.hash||void 0).addTo(this),this._hash&&this._hash._onHashChange()||(this.jumpTo({center:U.center,zoom:U.zoom,bearing:U.bearing,pitch:U.pitch}),U.bounds&&(this.resize(),this.fitBounds(U.bounds,y.extend({},U.fitBoundsOptions,{duration:0})))),this.resize(),this._localIdeographFontFamily=U.localIdeographFontFamily,U.style&&this.setStyle(U.style,{localIdeographFontFamily:U.localIdeographFontFamily}),U.attributionControl&&this.addControl(new tu({customAttribution:U.customAttribution})),this.addControl(new bh,U.logoPosition),this.on("style.load",function(){pe.transform.unmodified&&pe.jumpTo(pe.style.stylesheet)}),this.on("data",function(Oe){pe._update(Oe.dataType==="style"),pe.fire(new y.Event(Oe.dataType+"data",Oe))}),this.on("dataloading",function(Oe){pe.fire(new y.Event(Oe.dataType+"dataloading",Oe))})}b&&(x.__proto__=b),(x.prototype=Object.create(b&&b.prototype)).constructor=x;var S={showTileBoundaries:{configurable:!0},showPadding:{configurable:!0},showCollisionBoxes:{configurable:!0},showOverdrawInspector:{configurable:!0},repaint:{configurable:!0},vertices:{configurable:!0},version:{configurable:!0}};return x.prototype._getMapId=function(){return this._mapId},x.prototype.addControl=function(U,pe){if(pe===void 0&&(pe=U.getDefaultPosition?U.getDefaultPosition():"top-right"),!U||!U.onAdd)return this.fire(new y.ErrorEvent(new Error("Invalid argument to map.addControl(). Argument must be a control with onAdd and onRemove methods.")));var Ce=U.onAdd(this);this._controls.push(U);var Oe=this._controlPositions[pe];return pe.indexOf("bottom")!==-1?Oe.insertBefore(Ce,Oe.firstChild):Oe.appendChild(Ce),this},x.prototype.removeControl=function(U){if(!U||!U.onRemove)return this.fire(new y.ErrorEvent(new Error("Invalid argument to map.removeControl(). Argument must be a control with onAdd and onRemove methods.")));var pe=this._controls.indexOf(U);return pe>-1&&this._controls.splice(pe,1),U.onRemove(this),this},x.prototype.hasControl=function(U){return this._controls.indexOf(U)>-1},x.prototype.resize=function(U){var pe=this._containerDimensions(),Ce=pe[0],Oe=pe[1];if(Ce===this.transform.width&&Oe===this.transform.height)return this;this._resizeCanvas(Ce,Oe),this.transform.resize(Ce,Oe),this.painter.resize(Ce,Oe);var dt=!this._moving;return dt&&this.fire(new y.Event("movestart",U)).fire(new y.Event("move",U)),this.fire(new y.Event("resize",U)),dt&&this.fire(new y.Event("moveend",U)),this},x.prototype.getBounds=function(){return this.transform.getBounds()},x.prototype.getMaxBounds=function(){return this.transform.getMaxBounds()},x.prototype.setMaxBounds=function(U){return this.transform.setMaxBounds(y.LngLatBounds.convert(U)),this._update()},x.prototype.setMinZoom=function(U){if((U=U==null?-2:U)>=-2&&U<=this.transform.maxZoom)return this.transform.minZoom=U,this._update(),this.getZoom()=this.transform.minZoom)return this.transform.maxZoom=U,this._update(),this.getZoom()>U&&this.setZoom(U),this;throw new Error("maxZoom must be greater than the current minZoom")},x.prototype.getMaxZoom=function(){return this.transform.maxZoom},x.prototype.setMinPitch=function(U){if((U=U==null?0:U)<0)throw new Error("minPitch must be greater than or equal to 0");if(U>=0&&U<=this.transform.maxPitch)return this.transform.minPitch=U,this._update(),this.getPitch()60)throw new Error("maxPitch must be less than or equal to 60");if(U>=this.transform.minPitch)return this.transform.maxPitch=U,this._update(),this.getPitch()>U&&this.setPitch(U),this;throw new Error("maxPitch must be greater than the current minPitch")},x.prototype.getMaxPitch=function(){return this.transform.maxPitch},x.prototype.getRenderWorldCopies=function(){return this.transform.renderWorldCopies},x.prototype.setRenderWorldCopies=function(U){return this.transform.renderWorldCopies=U,this._update()},x.prototype.project=function(U){return this.transform.locationPoint(y.LngLat.convert(U))},x.prototype.unproject=function(U){return this.transform.pointLocation(y.Point.convert(U))},x.prototype.isMoving=function(){return this._moving||this.handlers.isMoving()},x.prototype.isZooming=function(){return this._zooming||this.handlers.isZooming()},x.prototype.isRotating=function(){return this._rotating||this.handlers.isRotating()},x.prototype._createDelegatedListener=function(U,pe,Ce){var Oe,dt=this;if(U==="mouseenter"||U==="mouseover"){var zt=!1;return{layer:pe,listener:Ce,delegates:{mousemove:function(Qt){var cr=dt.getLayer(pe)?dt.queryRenderedFeatures(Qt.point,{layers:[pe]}):[];cr.length?zt||(zt=!0,Ce.call(dt,new Us(U,dt,Qt.originalEvent,{features:cr}))):zt=!1},mouseout:function(){zt=!1}}}}if(U==="mouseleave"||U==="mouseout"){var Tt=!1;return{layer:pe,listener:Ce,delegates:{mousemove:function(Qt){(dt.getLayer(pe)?dt.queryRenderedFeatures(Qt.point,{layers:[pe]}):[]).length?Tt=!0:Tt&&(Tt=!1,Ce.call(dt,new Us(U,dt,Qt.originalEvent)))},mouseout:function(Qt){Tt&&(Tt=!1,Ce.call(dt,new Us(U,dt,Qt.originalEvent)))}}}}return{layer:pe,listener:Ce,delegates:(Oe={},Oe[U]=function(Qt){var cr=dt.getLayer(pe)?dt.queryRenderedFeatures(Qt.point,{layers:[pe]}):[];cr.length&&(Qt.features=cr,Ce.call(dt,Qt),delete Qt.features)},Oe)}},x.prototype.on=function(U,pe,Ce){if(Ce===void 0)return b.prototype.on.call(this,U,pe);var Oe=this._createDelegatedListener(U,pe,Ce);for(var dt in this._delegatedListeners=this._delegatedListeners||{},this._delegatedListeners[U]=this._delegatedListeners[U]||[],this._delegatedListeners[U].push(Oe),Oe.delegates)this.on(dt,Oe.delegates[dt]);return this},x.prototype.once=function(U,pe,Ce){if(Ce===void 0)return b.prototype.once.call(this,U,pe);var Oe=this._createDelegatedListener(U,pe,Ce);for(var dt in Oe.delegates)this.once(dt,Oe.delegates[dt]);return this},x.prototype.off=function(U,pe,Ce){var Oe=this;return Ce===void 0?b.prototype.off.call(this,U,pe):(this._delegatedListeners&&this._delegatedListeners[U]&&function(dt){for(var zt=dt[U],Tt=0;Tt180;){var Oe=S.locationPoint(b);if(Oe.x>=0&&Oe.y>=0&&Oe.x<=S.width&&Oe.y<=S.height)break;b.lng>S.center.lng?b.lng-=360:b.lng+=360}return b}ud.prototype.down=function(b,x){this.mouseRotate.mousedown(b,x),this.mousePitch&&this.mousePitch.mousedown(b,x),$.disableDrag()},ud.prototype.move=function(b,x){var S=this.map,U=this.mouseRotate.mousemoveWindow(b,x);if(U&&U.bearingDelta&&S.setBearing(S.getBearing()+U.bearingDelta),this.mousePitch){var pe=this.mousePitch.mousemoveWindow(b,x);pe&&pe.pitchDelta&&S.setPitch(S.getPitch()+pe.pitchDelta)}},ud.prototype.off=function(){var b=this.element;$.removeEventListener(b,"mousedown",this.mousedown),$.removeEventListener(b,"touchstart",this.touchstart,{passive:!1}),$.removeEventListener(b,"touchmove",this.touchmove),$.removeEventListener(b,"touchend",this.touchend),$.removeEventListener(b,"touchcancel",this.reset),this.offTemp()},ud.prototype.offTemp=function(){$.enableDrag(),$.removeEventListener(y.window,"mousemove",this.mousemove),$.removeEventListener(y.window,"mouseup",this.mouseup)},ud.prototype.mousedown=function(b){this.down(y.extend({},b,{ctrlKey:!0,preventDefault:function(){return b.preventDefault()}}),$.mousePos(this.element,b)),$.addEventListener(y.window,"mousemove",this.mousemove),$.addEventListener(y.window,"mouseup",this.mouseup)},ud.prototype.mousemove=function(b){this.move(b,$.mousePos(this.element,b))},ud.prototype.mouseup=function(b){this.mouseRotate.mouseupWindow(b),this.mousePitch&&this.mousePitch.mouseupWindow(b),this.offTemp()},ud.prototype.touchstart=function(b){b.targetTouches.length!==1?this.reset():(this._startPos=this._lastPos=$.touchPos(this.element,b.targetTouches)[0],this.down({type:"mousedown",button:0,ctrlKey:!0,preventDefault:function(){return b.preventDefault()}},this._startPos))},ud.prototype.touchmove=function(b){b.targetTouches.length!==1?this.reset():(this._lastPos=$.touchPos(this.element,b.targetTouches)[0],this.move({preventDefault:function(){return b.preventDefault()}},this._lastPos))},ud.prototype.touchend=function(b){b.targetTouches.length===0&&this._startPos&&this._lastPos&&this._startPos.dist(this._lastPos)=U}this._isDragging&&(this._pos=S.point.sub(this._positionDelta),this._lngLat=this._map.unproject(this._pos),this.setLngLat(this._lngLat),this._element.style.pointerEvents="none",this._state==="pending"&&(this._state="active",this.fire(new y.Event("dragstart"))),this.fire(new y.Event("drag")))},x.prototype._onUp=function(){this._element.style.pointerEvents="auto",this._positionDelta=null,this._pointerdownPos=null,this._isDragging=!1,this._map.off("mousemove",this._onMove),this._map.off("touchmove",this._onMove),this._state==="active"&&this.fire(new y.Event("dragend")),this._state="inactive"},x.prototype._addDragHandler=function(S){this._element.contains(S.originalEvent.target)&&(S.preventDefault(),this._positionDelta=S.point.sub(this._pos).add(this._offset),this._pointerdownPos=S.point,this._state="pending",this._map.on("mousemove",this._onMove),this._map.on("touchmove",this._onMove),this._map.once("mouseup",this._onUp),this._map.once("touchend",this._onUp))},x.prototype.setDraggable=function(S){return this._draggable=!!S,this._map&&(S?(this._map.on("mousedown",this._addDragHandler),this._map.on("touchstart",this._addDragHandler)):(this._map.off("mousedown",this._addDragHandler),this._map.off("touchstart",this._addDragHandler))),this},x.prototype.isDraggable=function(){return this._draggable},x.prototype.setRotation=function(S){return this._rotation=S||0,this._update(),this},x.prototype.getRotation=function(){return this._rotation},x.prototype.setRotationAlignment=function(S){return this._rotationAlignment=S||"auto",this._update(),this},x.prototype.getRotationAlignment=function(){return this._rotationAlignment},x.prototype.setPitchAlignment=function(S){return this._pitchAlignment=S&&S!=="auto"?S:this._rotationAlignment,this._update(),this},x.prototype.getPitchAlignment=function(){return this._pitchAlignment},x}(y.Evented),_e={positionOptions:{enableHighAccuracy:!1,maximumAge:0,timeout:6e3},fitBoundsOptions:{maxZoom:15},trackUserLocation:!1,showAccuracyCircle:!0,showUserLocation:!0},_t=0,jt=!1,ie=function(b){function x(S){b.call(this),this.options=y.extend({},_e,S),y.bindAll(["_onSuccess","_onError","_onZoom","_finish","_setupUI","_updateCamera","_updateMarker"],this)}return b&&(x.__proto__=b),(x.prototype=Object.create(b&&b.prototype)).constructor=x,x.prototype.onAdd=function(S){var U;return this._map=S,this._container=$.create("div","mapboxgl-ctrl mapboxgl-ctrl-group"),U=this._setupUI,B!==void 0?U(B):y.window.navigator.permissions!==void 0?y.window.navigator.permissions.query({name:"geolocation"}).then(function(pe){U(B=pe.state!=="denied")}):U(B=!!y.window.navigator.geolocation),this._container},x.prototype.onRemove=function(){this._geolocationWatchID!==void 0&&(y.window.navigator.geolocation.clearWatch(this._geolocationWatchID),this._geolocationWatchID=void 0),this.options.showUserLocation&&this._userLocationDotMarker&&this._userLocationDotMarker.remove(),this.options.showAccuracyCircle&&this._accuracyCircleMarker&&this._accuracyCircleMarker.remove(),$.remove(this._container),this._map.off("zoom",this._onZoom),this._map=void 0,_t=0,jt=!1},x.prototype._isOutOfMapMaxBounds=function(S){var U=this._map.getMaxBounds(),pe=S.coords;return U&&(pe.longitudeU.getEast()||pe.latitudeU.getNorth())},x.prototype._setErrorState=function(){switch(this._watchState){case"WAITING_ACTIVE":this._watchState="ACTIVE_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error");break;case"ACTIVE_LOCK":this._watchState="ACTIVE_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting");break;case"BACKGROUND":this._watchState="BACKGROUND_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting")}},x.prototype._onSuccess=function(S){if(this._map){if(this._isOutOfMapMaxBounds(S))return this._setErrorState(),this.fire(new y.Event("outofmaxbounds",S)),this._updateMarker(),void this._finish();if(this.options.trackUserLocation)switch(this._lastKnownPosition=S,this._watchState){case"WAITING_ACTIVE":case"ACTIVE_LOCK":case"ACTIVE_ERROR":this._watchState="ACTIVE_LOCK",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"BACKGROUND":case"BACKGROUND_ERROR":this._watchState="BACKGROUND",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background")}this.options.showUserLocation&&this._watchState!=="OFF"&&this._updateMarker(S),this.options.trackUserLocation&&this._watchState!=="ACTIVE_LOCK"||this._updateCamera(S),this.options.showUserLocation&&this._dotElement.classList.remove("mapboxgl-user-location-dot-stale"),this.fire(new y.Event("geolocate",S)),this._finish()}},x.prototype._updateCamera=function(S){var U=new y.LngLat(S.coords.longitude,S.coords.latitude),pe=S.coords.accuracy,Ce=this._map.getBearing(),Oe=y.extend({bearing:Ce},this.options.fitBoundsOptions);this._map.fitBounds(U.toBounds(pe),Oe,{geolocateSource:!0})},x.prototype._updateMarker=function(S){if(S){var U=new y.LngLat(S.coords.longitude,S.coords.latitude);this._accuracyCircleMarker.setLngLat(U).addTo(this._map),this._userLocationDotMarker.setLngLat(U).addTo(this._map),this._accuracy=S.coords.accuracy,this.options.showUserLocation&&this.options.showAccuracyCircle&&this._updateCircleRadius()}else this._userLocationDotMarker.remove(),this._accuracyCircleMarker.remove()},x.prototype._updateCircleRadius=function(){var S=this._map._container.clientHeight/2,U=this._map.unproject([0,S]),pe=this._map.unproject([1,S]),Ce=U.distanceTo(pe),Oe=Math.ceil(2*this._accuracy/Ce);this._circleElement.style.width=Oe+"px",this._circleElement.style.height=Oe+"px"},x.prototype._onZoom=function(){this.options.showUserLocation&&this.options.showAccuracyCircle&&this._updateCircleRadius()},x.prototype._onError=function(S){if(this._map){if(this.options.trackUserLocation)if(S.code===1){this._watchState="OFF",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.disabled=!0;var U=this._map._getUIString("GeolocateControl.LocationNotAvailable");this._geolocateButton.title=U,this._geolocateButton.setAttribute("aria-label",U),this._geolocationWatchID!==void 0&&this._clearWatch()}else{if(S.code===3&&jt)return;this._setErrorState()}this._watchState!=="OFF"&&this.options.showUserLocation&&this._dotElement.classList.add("mapboxgl-user-location-dot-stale"),this.fire(new y.Event("error",S)),this._finish()}},x.prototype._finish=function(){this._timeoutId&&clearTimeout(this._timeoutId),this._timeoutId=void 0},x.prototype._setupUI=function(S){var U=this;if(this._container.addEventListener("contextmenu",function(Oe){return Oe.preventDefault()}),this._geolocateButton=$.create("button","mapboxgl-ctrl-geolocate",this._container),$.create("span","mapboxgl-ctrl-icon",this._geolocateButton).setAttribute("aria-hidden",!0),this._geolocateButton.type="button",S===!1){y.warnOnce("Geolocation support is not available so the GeolocateControl will be disabled.");var pe=this._map._getUIString("GeolocateControl.LocationNotAvailable");this._geolocateButton.disabled=!0,this._geolocateButton.title=pe,this._geolocateButton.setAttribute("aria-label",pe)}else{var Ce=this._map._getUIString("GeolocateControl.FindMyLocation");this._geolocateButton.title=Ce,this._geolocateButton.setAttribute("aria-label",Ce)}this.options.trackUserLocation&&(this._geolocateButton.setAttribute("aria-pressed","false"),this._watchState="OFF"),this.options.showUserLocation&&(this._dotElement=$.create("div","mapboxgl-user-location-dot"),this._userLocationDotMarker=new W(this._dotElement),this._circleElement=$.create("div","mapboxgl-user-location-accuracy-circle"),this._accuracyCircleMarker=new W({element:this._circleElement,pitchAlignment:"map"}),this.options.trackUserLocation&&(this._watchState="OFF"),this._map.on("zoom",this._onZoom)),this._geolocateButton.addEventListener("click",this.trigger.bind(this)),this._setup=!0,this.options.trackUserLocation&&this._map.on("movestart",function(Oe){Oe.geolocateSource||U._watchState!=="ACTIVE_LOCK"||Oe.originalEvent&&Oe.originalEvent.type==="resize"||(U._watchState="BACKGROUND",U._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background"),U._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),U.fire(new y.Event("trackuserlocationend")))})},x.prototype.trigger=function(){if(!this._setup)return y.warnOnce("Geolocate control triggered before added to a map"),!1;if(this.options.trackUserLocation){switch(this._watchState){case"OFF":this._watchState="WAITING_ACTIVE",this.fire(new y.Event("trackuserlocationstart"));break;case"WAITING_ACTIVE":case"ACTIVE_LOCK":case"ACTIVE_ERROR":case"BACKGROUND_ERROR":_t--,jt=!1,this._watchState="OFF",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this.fire(new y.Event("trackuserlocationend"));break;case"BACKGROUND":this._watchState="ACTIVE_LOCK",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._lastKnownPosition&&this._updateCamera(this._lastKnownPosition),this.fire(new y.Event("trackuserlocationstart"))}switch(this._watchState){case"WAITING_ACTIVE":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"ACTIVE_LOCK":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"ACTIVE_ERROR":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error");break;case"BACKGROUND":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background");break;case"BACKGROUND_ERROR":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background-error")}if(this._watchState==="OFF"&&this._geolocationWatchID!==void 0)this._clearWatch();else if(this._geolocationWatchID===void 0){var S;this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.setAttribute("aria-pressed","true"),++_t>1?(S={maximumAge:6e5,timeout:0},jt=!0):(S=this.options.positionOptions,jt=!1),this._geolocationWatchID=y.window.navigator.geolocation.watchPosition(this._onSuccess,this._onError,S)}}else y.window.navigator.geolocation.getCurrentPosition(this._onSuccess,this._onError,this.options.positionOptions),this._timeoutId=setTimeout(this._finish,1e4);return!0},x.prototype._clearWatch=function(){y.window.navigator.geolocation.clearWatch(this._geolocationWatchID),this._geolocationWatchID=void 0,this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.setAttribute("aria-pressed","false"),this.options.showUserLocation&&this._updateMarker(null)},x}(y.Evented),f={maxWidth:100,unit:"metric"},L=function(b){this.options=y.extend({},f,b),y.bindAll(["_onMove","setUnit"],this)};function ee(b,x,S){var U=S&&S.maxWidth||100,pe=b._container.clientHeight/2,Ce=b.unproject([0,pe]),Oe=b.unproject([U,pe]),dt=Ce.distanceTo(Oe);if(S&&S.unit==="imperial"){var zt=3.2808*dt;zt>5280?te(x,U,zt/5280,b._getUIString("ScaleControl.Miles")):te(x,U,zt,b._getUIString("ScaleControl.Feet"))}else S&&S.unit==="nautical"?te(x,U,dt/1852,b._getUIString("ScaleControl.NauticalMiles")):dt>=1e3?te(x,U,dt/1e3,b._getUIString("ScaleControl.Kilometers")):te(x,U,dt,b._getUIString("ScaleControl.Meters"))}function te(b,x,S,U){var pe,Ce,Oe,dt=(pe=S,(Ce=Math.pow(10,(""+Math.floor(pe)).length-1))*(Oe=(Oe=pe/Ce)>=10?10:Oe>=5?5:Oe>=3?3:Oe>=2?2:Oe>=1?1:function(zt){var Tt=Math.pow(10,Math.ceil(-Math.log(zt)/Math.LN10));return Math.round(zt*Tt)/Tt}(Oe)));b.style.width=x*(dt/S)+"px",b.innerHTML=dt+" "+U}L.prototype.getDefaultPosition=function(){return"bottom-left"},L.prototype._onMove=function(){ee(this._map,this._container,this.options)},L.prototype.onAdd=function(b){return this._map=b,this._container=$.create("div","mapboxgl-ctrl mapboxgl-ctrl-scale",b.getContainer()),this._map.on("move",this._onMove),this._onMove(),this._container},L.prototype.onRemove=function(){$.remove(this._container),this._map.off("move",this._onMove),this._map=void 0},L.prototype.setUnit=function(b){this.options.unit=b,ee(this._map,this._container,this.options)};var me=function(b){this._fullscreen=!1,b&&b.container&&(b.container instanceof y.window.HTMLElement?this._container=b.container:y.warnOnce("Full screen control 'container' must be a DOM element.")),y.bindAll(["_onClickFullscreen","_changeIcon"],this),"onfullscreenchange"in y.window.document?this._fullscreenchange="fullscreenchange":"onmozfullscreenchange"in y.window.document?this._fullscreenchange="mozfullscreenchange":"onwebkitfullscreenchange"in y.window.document?this._fullscreenchange="webkitfullscreenchange":"onmsfullscreenchange"in y.window.document&&(this._fullscreenchange="MSFullscreenChange")};me.prototype.onAdd=function(b){return this._map=b,this._container||(this._container=this._map.getContainer()),this._controlContainer=$.create("div","mapboxgl-ctrl mapboxgl-ctrl-group"),this._checkFullscreenSupport()?this._setupUI():(this._controlContainer.style.display="none",y.warnOnce("This device does not support fullscreen mode.")),this._controlContainer},me.prototype.onRemove=function(){$.remove(this._controlContainer),this._map=null,y.window.document.removeEventListener(this._fullscreenchange,this._changeIcon)},me.prototype._checkFullscreenSupport=function(){return!!(y.window.document.fullscreenEnabled||y.window.document.mozFullScreenEnabled||y.window.document.msFullscreenEnabled||y.window.document.webkitFullscreenEnabled)},me.prototype._setupUI=function(){var b=this._fullscreenButton=$.create("button","mapboxgl-ctrl-fullscreen",this._controlContainer);$.create("span","mapboxgl-ctrl-icon",b).setAttribute("aria-hidden",!0),b.type="button",this._updateTitle(),this._fullscreenButton.addEventListener("click",this._onClickFullscreen),y.window.document.addEventListener(this._fullscreenchange,this._changeIcon)},me.prototype._updateTitle=function(){var b=this._getTitle();this._fullscreenButton.setAttribute("aria-label",b),this._fullscreenButton.title=b},me.prototype._getTitle=function(){return this._map._getUIString(this._isFullscreen()?"FullscreenControl.Exit":"FullscreenControl.Enter")},me.prototype._isFullscreen=function(){return this._fullscreen},me.prototype._changeIcon=function(){(y.window.document.fullscreenElement||y.window.document.mozFullScreenElement||y.window.document.webkitFullscreenElement||y.window.document.msFullscreenElement)===this._container!==this._fullscreen&&(this._fullscreen=!this._fullscreen,this._fullscreenButton.classList.toggle("mapboxgl-ctrl-shrink"),this._fullscreenButton.classList.toggle("mapboxgl-ctrl-fullscreen"),this._updateTitle())},me.prototype._onClickFullscreen=function(){this._isFullscreen()?y.window.document.exitFullscreen?y.window.document.exitFullscreen():y.window.document.mozCancelFullScreen?y.window.document.mozCancelFullScreen():y.window.document.msExitFullscreen?y.window.document.msExitFullscreen():y.window.document.webkitCancelFullScreen&&y.window.document.webkitCancelFullScreen():this._container.requestFullscreen?this._container.requestFullscreen():this._container.mozRequestFullScreen?this._container.mozRequestFullScreen():this._container.msRequestFullscreen?this._container.msRequestFullscreen():this._container.webkitRequestFullscreen&&this._container.webkitRequestFullscreen()};var He={closeButton:!0,closeOnClick:!0,focusAfterOpen:!0,className:"",maxWidth:"240px"},nt=["a[href]","[tabindex]:not([tabindex='-1'])","[contenteditable]:not([contenteditable='false'])","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].join(", "),w=function(b){function x(S){b.call(this),this.options=y.extend(Object.create(He),S),y.bindAll(["_update","_onClose","remove","_onMouseMove","_onMouseUp","_onDrag"],this)}return b&&(x.__proto__=b),(x.prototype=Object.create(b&&b.prototype)).constructor=x,x.prototype.addTo=function(S){return this._map&&this.remove(),this._map=S,this.options.closeOnClick&&this._map.on("click",this._onClose),this.options.closeOnMove&&this._map.on("move",this._onClose),this._map.on("remove",this.remove),this._update(),this._focusFirstElement(),this._trackPointer?(this._map.on("mousemove",this._onMouseMove),this._map.on("mouseup",this._onMouseUp),this._container&&this._container.classList.add("mapboxgl-popup-track-pointer"),this._map._canvasContainer.classList.add("mapboxgl-track-pointer")):this._map.on("move",this._update),this.fire(new y.Event("open")),this},x.prototype.isOpen=function(){return!!this._map},x.prototype.remove=function(){return this._content&&$.remove(this._content),this._container&&($.remove(this._container),delete this._container),this._map&&(this._map.off("move",this._update),this._map.off("move",this._onClose),this._map.off("click",this._onClose),this._map.off("remove",this.remove),this._map.off("mousemove",this._onMouseMove),this._map.off("mouseup",this._onMouseUp),this._map.off("drag",this._onDrag),delete this._map),this.fire(new y.Event("close")),this},x.prototype.getLngLat=function(){return this._lngLat},x.prototype.setLngLat=function(S){return this._lngLat=y.LngLat.convert(S),this._pos=null,this._trackPointer=!1,this._update(),this._map&&(this._map.on("move",this._update),this._map.off("mousemove",this._onMouseMove),this._container&&this._container.classList.remove("mapboxgl-popup-track-pointer"),this._map._canvasContainer.classList.remove("mapboxgl-track-pointer")),this},x.prototype.trackPointer=function(){return this._trackPointer=!0,this._pos=null,this._update(),this._map&&(this._map.off("move",this._update),this._map.on("mousemove",this._onMouseMove),this._map.on("drag",this._onDrag),this._container&&this._container.classList.add("mapboxgl-popup-track-pointer"),this._map._canvasContainer.classList.add("mapboxgl-track-pointer")),this},x.prototype.getElement=function(){return this._container},x.prototype.setText=function(S){return this.setDOMContent(y.window.document.createTextNode(S))},x.prototype.setHTML=function(S){var U,pe=y.window.document.createDocumentFragment(),Ce=y.window.document.createElement("body");for(Ce.innerHTML=S;U=Ce.firstChild;)pe.appendChild(U);return this.setDOMContent(pe)},x.prototype.getMaxWidth=function(){return this._container&&this._container.style.maxWidth},x.prototype.setMaxWidth=function(S){return this.options.maxWidth=S,this._update(),this},x.prototype.setDOMContent=function(S){if(this._content)for(;this._content.hasChildNodes();)this._content.firstChild&&this._content.removeChild(this._content.firstChild);else this._content=$.create("div","mapboxgl-popup-content",this._container);return this._content.appendChild(S),this._createCloseButton(),this._update(),this._focusFirstElement(),this},x.prototype.addClassName=function(S){this._container&&this._container.classList.add(S)},x.prototype.removeClassName=function(S){this._container&&this._container.classList.remove(S)},x.prototype.setOffset=function(S){return this.options.offset=S,this._update(),this},x.prototype.toggleClassName=function(S){if(this._container)return this._container.classList.toggle(S)},x.prototype._createCloseButton=function(){this.options.closeButton&&(this._closeButton=$.create("button","mapboxgl-popup-close-button",this._content),this._closeButton.type="button",this._closeButton.setAttribute("aria-label","Close popup"),this._closeButton.innerHTML="×",this._closeButton.addEventListener("click",this._onClose))},x.prototype._onMouseUp=function(S){this._update(S.point)},x.prototype._onMouseMove=function(S){this._update(S.point)},x.prototype._onDrag=function(S){this._update(S.point)},x.prototype._update=function(S){var U=this;if(this._map&&(this._lngLat||this._trackPointer)&&this._content&&(this._container||(this._container=$.create("div","mapboxgl-popup",this._map.getContainer()),this._tip=$.create("div","mapboxgl-popup-tip",this._container),this._container.appendChild(this._content),this.options.className&&this.options.className.split(" ").forEach(function(cr){return U._container.classList.add(cr)}),this._trackPointer&&this._container.classList.add("mapboxgl-popup-track-pointer")),this.options.maxWidth&&this._container.style.maxWidth!==this.options.maxWidth&&(this._container.style.maxWidth=this.options.maxWidth),this._map.transform.renderWorldCopies&&!this._trackPointer&&(this._lngLat=fp(this._lngLat,this._pos,this._map.transform)),!this._trackPointer||S)){var pe=this._pos=this._trackPointer&&S?S:this._map.project(this._lngLat),Ce=this.options.anchor,Oe=function cr(pr){if(pr){if(typeof pr=="number"){var zr=Math.round(Math.sqrt(.5*Math.pow(pr,2)));return{center:new y.Point(0,0),top:new y.Point(0,pr),"top-left":new y.Point(zr,zr),"top-right":new y.Point(-zr,zr),bottom:new y.Point(0,-pr),"bottom-left":new y.Point(zr,-zr),"bottom-right":new y.Point(-zr,-zr),left:new y.Point(pr,0),right:new y.Point(-pr,0)}}if(pr instanceof y.Point||Array.isArray(pr)){var jr=y.Point.convert(pr);return{center:jr,top:jr,"top-left":jr,"top-right":jr,bottom:jr,"bottom-left":jr,"bottom-right":jr,left:jr,right:jr}}return{center:y.Point.convert(pr.center||[0,0]),top:y.Point.convert(pr.top||[0,0]),"top-left":y.Point.convert(pr["top-left"]||[0,0]),"top-right":y.Point.convert(pr["top-right"]||[0,0]),bottom:y.Point.convert(pr.bottom||[0,0]),"bottom-left":y.Point.convert(pr["bottom-left"]||[0,0]),"bottom-right":y.Point.convert(pr["bottom-right"]||[0,0]),left:y.Point.convert(pr.left||[0,0]),right:y.Point.convert(pr.right||[0,0])}}return cr(new y.Point(0,0))}(this.options.offset);if(!Ce){var dt,zt=this._container.offsetWidth,Tt=this._container.offsetHeight;dt=pe.y+Oe.bottom.ythis._map.transform.height-Tt?["bottom"]:[],pe.xthis._map.transform.width-zt/2&&dt.push("right"),Ce=dt.length===0?"bottom":dt.join("-")}var Qt=pe.add(Oe[Ce]).round();$.setTransform(this._container,h[Ce]+" translate("+Qt.x+"px,"+Qt.y+"px)"),v(this._container,Ce,"popup")}},x.prototype._focusFirstElement=function(){if(this.options.focusAfterOpen&&this._container){var S=this._container.querySelector(nt);S&&S.focus()}},x.prototype._onClose=function(){this.remove()},x}(y.Evented),Wt={version:y.version,supported:p,setRTLTextPlugin:y.setRTLTextPlugin,getRTLTextPluginStatus:y.getRTLTextPluginStatus,Map:fh,NavigationControl:rh,GeolocateControl:ie,AttributionControl:tu,ScaleControl:L,FullscreenControl:me,Popup:w,Marker:W,Style:gs,LngLat:y.LngLat,LngLatBounds:y.LngLatBounds,Point:y.Point,MercatorCoordinate:y.MercatorCoordinate,Evented:y.Evented,config:y.config,prewarm:function(){Rn().acquire(on)},clearPrewarmedResources:function(){var b=ri;b&&(b.isPreloaded()&&b.numActive()===1?(b.release(on),ri=null):console.warn("Could not clear WebWorkers since there are active Map instances that still reference it. The pre-warmed WebWorker pool can only be cleared when all map instances have been removed with map.remove()"))},get accessToken(){return y.config.ACCESS_TOKEN},set accessToken(b){y.config.ACCESS_TOKEN=b},get baseApiUrl(){return y.config.API_URL},set baseApiUrl(b){y.config.API_URL=b},get workerCount(){return dn.workerCount},set workerCount(b){dn.workerCount=b},get maxParallelImageRequests(){return y.config.MAX_PARALLEL_IMAGE_REQUESTS},set maxParallelImageRequests(b){y.config.MAX_PARALLEL_IMAGE_REQUESTS=b},clearStorage:function(b){y.clearTileCache(b)},workerUrl:""};return Wt}),R})},93735:function(Ye,ye,A){(function(){var R=A(75041),V=A(67751).utf8,y=A(78034),p=A(67751).bin,$=function(X,se){X.constructor==String?se&&se.encoding==="binary"?X=p.stringToBytes(X):X=V.stringToBytes(X):y(X)?X=Array.prototype.slice.call(X,0):!Array.isArray(X)&&X.constructor!==Uint8Array&&(X=X.toString());for(var ae=R.bytesToWords(X),ce=X.length*8,le=1732584193,De=-271733879,we=-1732584194,Ee=271733878,qe=0;qe>>24)&16711935|(ae[qe]<<24|ae[qe]>>>8)&4278255360;ae[ce>>>5]|=128<>>9<<4)+14]=ce;for(var Ge=$._ff,ct=$._gg,Ve=$._hh,ut=$._ii,qe=0;qe>>0,De=De+Rt>>>0,we=we+gt>>>0,Ee=Ee+Ct>>>0}return R.endian([le,De,we,Ee])};$._ff=function(X,se,ae,ce,le,De,we){var Ee=X+(se&ae|~se&ce)+(le>>>0)+we;return(Ee<>>32-De)+se},$._gg=function(X,se,ae,ce,le,De,we){var Ee=X+(se&ce|ae&~ce)+(le>>>0)+we;return(Ee<>>32-De)+se},$._hh=function(X,se,ae,ce,le,De,we){var Ee=X+(se^ae^ce)+(le>>>0)+we;return(Ee<>>32-De)+se},$._ii=function(X,se,ae,ce,le,De,we){var Ee=X+(ae^(se|~ce))+(le>>>0)+we;return(Ee<>>32-De)+se},$._blocksize=16,$._digestsize=16,Ye.exports=function(X,se){if(X==null)throw new Error("Illegal argument "+X);var ae=R.wordsToBytes($(X,se));return se&&se.asBytes?ae:se&&se.asString?p.bytesToString(ae):R.bytesToHex(ae)}})()},84126:function(Ye){"use strict";var ye=Object.getOwnPropertySymbols,A=Object.prototype.hasOwnProperty,R=Object.prototype.propertyIsEnumerable;function V(p){if(p==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(p)}function y(){try{if(!Object.assign)return!1;var p=new String("abc");if(p[5]="de",Object.getOwnPropertyNames(p)[0]==="5")return!1;for(var $={},X=0;X<10;X++)$["_"+String.fromCharCode(X)]=X;var se=Object.getOwnPropertyNames($).map(function(ce){return $[ce]});if(se.join("")!=="0123456789")return!1;var ae={};return"abcdefghijklmnopqrst".split("").forEach(function(ce){ae[ce]=ce}),Object.keys(Object.assign({},ae)).join("")==="abcdefghijklmnopqrst"}catch(ce){return!1}}Ye.exports=y()?Object.assign:function(p,$){for(var X,se=V(p),ae,ce=1;ce0&&!V.call(qe,0))for(var gt=0;gt0)for(var Ct=0;Ct=0&&ye.call(R.callee)==="[object Function]"),y}},88959:function(Ye,ye,A){"use strict";Ye.exports=V;var R=A(67467);function V(ft){this.buf=ArrayBuffer.isView&&ArrayBuffer.isView(ft)?ft:new Uint8Array(ft||0),this.pos=0,this.type=0,this.length=this.buf.length}V.Varint=0,V.Fixed64=1,V.Bytes=2,V.Fixed32=5;var y=65536*65536,p=1/y,$=12,X=typeof TextDecoder=="undefined"?null:new TextDecoder("utf8");V.prototype={destroy:function(){this.buf=null},readFields:function(ft,wt,Se){for(Se=Se||this.length;this.pos>3,ot=this.pos;this.type=Ft&7,ft(mt,wt,this),this.pos===ot&&this.skip(Ft)}return wt},readMessage:function(ft,wt){return this.readFields(ft,wt,this.readVarint()+this.pos)},readFixed32:function(){var ft=tt(this.buf,this.pos);return this.pos+=4,ft},readSFixed32:function(){var ft=bt(this.buf,this.pos);return this.pos+=4,ft},readFixed64:function(){var ft=tt(this.buf,this.pos)+tt(this.buf,this.pos+4)*y;return this.pos+=8,ft},readSFixed64:function(){var ft=tt(this.buf,this.pos)+bt(this.buf,this.pos+4)*y;return this.pos+=8,ft},readFloat:function(){var ft=R.read(this.buf,this.pos,!0,23,4);return this.pos+=4,ft},readDouble:function(){var ft=R.read(this.buf,this.pos,!0,52,8);return this.pos+=8,ft},readVarint:function(ft){var wt=this.buf,Se,Ft;return Ft=wt[this.pos++],Se=Ft&127,Ft<128||(Ft=wt[this.pos++],Se|=(Ft&127)<<7,Ft<128)||(Ft=wt[this.pos++],Se|=(Ft&127)<<14,Ft<128)||(Ft=wt[this.pos++],Se|=(Ft&127)<<21,Ft<128)?Se:(Ft=wt[this.pos],Se|=(Ft&15)<<28,se(Se,ft,this))},readVarint64:function(){return this.readVarint(!0)},readSVarint:function(){var ft=this.readVarint();return ft%2===1?(ft+1)/-2:ft/2},readBoolean:function(){return!!this.readVarint()},readString:function(){var ft=this.readVarint()+this.pos,wt=this.pos;return this.pos=ft,ft-wt>=$&&X?pt(this.buf,wt,ft):et(this.buf,wt,ft)},readBytes:function(){var ft=this.readVarint()+this.pos,wt=this.buf.subarray(this.pos,ft);return this.pos=ft,wt},readPackedVarint:function(ft,wt){if(this.type!==V.Bytes)return ft.push(this.readVarint(wt));var Se=ae(this);for(ft=ft||[];this.pos127;);else if(wt===V.Bytes)this.pos=this.readVarint()+this.pos;else if(wt===V.Fixed32)this.pos+=4;else if(wt===V.Fixed64)this.pos+=8;else throw new Error("Unimplemented type: "+wt)},writeTag:function(ft,wt){this.writeVarint(ft<<3|wt)},realloc:function(ft){for(var wt=this.length||16;wt268435455||ft<0){le(ft,this);return}this.realloc(4),this.buf[this.pos++]=ft&127|(ft>127?128:0),!(ft<=127)&&(this.buf[this.pos++]=(ft>>>=7)&127|(ft>127?128:0),!(ft<=127)&&(this.buf[this.pos++]=(ft>>>=7)&127|(ft>127?128:0),!(ft<=127)&&(this.buf[this.pos++]=ft>>>7&127)))},writeSVarint:function(ft){this.writeVarint(ft<0?-ft*2-1:ft*2)},writeBoolean:function(ft){this.writeVarint(!!ft)},writeString:function(ft){ft=String(ft),this.realloc(ft.length*4),this.pos++;var wt=this.pos;this.pos=Ke(this.buf,ft,this.pos);var Se=this.pos-wt;Se>=128&&Ee(wt,Se,this),this.pos=wt-1,this.writeVarint(Se),this.pos+=Se},writeFloat:function(ft){this.realloc(4),R.write(this.buf,ft,this.pos,!0,23,4),this.pos+=4},writeDouble:function(ft){this.realloc(8),R.write(this.buf,ft,this.pos,!0,52,8),this.pos+=8},writeBytes:function(ft){var wt=ft.length;this.writeVarint(wt),this.realloc(wt);for(var Se=0;Se=128&&Ee(Se,Ft,this),this.pos=Se-1,this.writeVarint(Ft),this.pos+=Ft},writeMessage:function(ft,wt,Se){this.writeTag(ft,V.Bytes),this.writeRawMessage(wt,Se)},writePackedVarint:function(ft,wt){wt.length&&this.writeMessage(ft,qe,wt)},writePackedSVarint:function(ft,wt){wt.length&&this.writeMessage(ft,Ge,wt)},writePackedBoolean:function(ft,wt){wt.length&&this.writeMessage(ft,ut,wt)},writePackedFloat:function(ft,wt){wt.length&&this.writeMessage(ft,ct,wt)},writePackedDouble:function(ft,wt){wt.length&&this.writeMessage(ft,Ve,wt)},writePackedFixed32:function(ft,wt){wt.length&&this.writeMessage(ft,Xe,wt)},writePackedSFixed32:function(ft,wt){wt.length&&this.writeMessage(ft,Rt,wt)},writePackedFixed64:function(ft,wt){wt.length&&this.writeMessage(ft,gt,wt)},writePackedSFixed64:function(ft,wt){wt.length&&this.writeMessage(ft,Ct,wt)},writeBytesField:function(ft,wt){this.writeTag(ft,V.Bytes),this.writeBytes(wt)},writeFixed32Field:function(ft,wt){this.writeTag(ft,V.Fixed32),this.writeFixed32(wt)},writeSFixed32Field:function(ft,wt){this.writeTag(ft,V.Fixed32),this.writeSFixed32(wt)},writeFixed64Field:function(ft,wt){this.writeTag(ft,V.Fixed64),this.writeFixed64(wt)},writeSFixed64Field:function(ft,wt){this.writeTag(ft,V.Fixed64),this.writeSFixed64(wt)},writeVarintField:function(ft,wt){this.writeTag(ft,V.Varint),this.writeVarint(wt)},writeSVarintField:function(ft,wt){this.writeTag(ft,V.Varint),this.writeSVarint(wt)},writeStringField:function(ft,wt){this.writeTag(ft,V.Bytes),this.writeString(wt)},writeFloatField:function(ft,wt){this.writeTag(ft,V.Fixed32),this.writeFloat(wt)},writeDoubleField:function(ft,wt){this.writeTag(ft,V.Fixed64),this.writeDouble(wt)},writeBooleanField:function(ft,wt){this.writeVarintField(ft,!!wt)}};function se(ft,wt,Se){var Ft=Se.buf,mt,ot;if(ot=Ft[Se.pos++],mt=(ot&112)>>4,ot<128||(ot=Ft[Se.pos++],mt|=(ot&127)<<3,ot<128)||(ot=Ft[Se.pos++],mt|=(ot&127)<<10,ot<128)||(ot=Ft[Se.pos++],mt|=(ot&127)<<17,ot<128)||(ot=Ft[Se.pos++],mt|=(ot&127)<<24,ot<128)||(ot=Ft[Se.pos++],mt|=(ot&1)<<31,ot<128))return ce(ft,mt,wt);throw new Error("Expected varint not more than 10 bytes")}function ae(ft){return ft.type===V.Bytes?ft.readVarint()+ft.pos:ft.pos+1}function ce(ft,wt,Se){return Se?wt*4294967296+(ft>>>0):(wt>>>0)*4294967296+(ft>>>0)}function le(ft,wt){var Se,Ft;if(ft>=0?(Se=ft%4294967296|0,Ft=ft/4294967296|0):(Se=~(-ft%4294967296),Ft=~(-ft/4294967296),Se^4294967295?Se=Se+1|0:(Se=0,Ft=Ft+1|0)),ft>=18446744073709552e3||ft<-18446744073709552e3)throw new Error("Given varint doesn't fit into 10 bytes");wt.realloc(10),De(Se,Ft,wt),we(Ft,wt)}function De(ft,wt,Se){Se.buf[Se.pos++]=ft&127|128,ft>>>=7,Se.buf[Se.pos++]=ft&127|128,ft>>>=7,Se.buf[Se.pos++]=ft&127|128,ft>>>=7,Se.buf[Se.pos++]=ft&127|128,ft>>>=7,Se.buf[Se.pos]=ft&127}function we(ft,wt){var Se=(ft&7)<<4;wt.buf[wt.pos++]|=Se|((ft>>>=3)?128:0),ft&&(wt.buf[wt.pos++]=ft&127|((ft>>>=7)?128:0),ft&&(wt.buf[wt.pos++]=ft&127|((ft>>>=7)?128:0),ft&&(wt.buf[wt.pos++]=ft&127|((ft>>>=7)?128:0),ft&&(wt.buf[wt.pos++]=ft&127|((ft>>>=7)?128:0),ft&&(wt.buf[wt.pos++]=ft&127)))))}function Ee(ft,wt,Se){var Ft=wt<=16383?1:wt<=2097151?2:wt<=268435455?3:Math.floor(Math.log(wt)/(Math.LN2*7));Se.realloc(Ft);for(var mt=Se.pos-1;mt>=ft;mt--)Se.buf[mt+Ft]=Se.buf[mt]}function qe(ft,wt){for(var Se=0;Se>>8,ft[Se+2]=wt>>>16,ft[Se+3]=wt>>>24}function bt(ft,wt){return(ft[wt]|ft[wt+1]<<8|ft[wt+2]<<16)+(ft[wt+3]<<24)}function et(ft,wt,Se){for(var Ft="",mt=wt;mt239?4:ot>223?3:ot>191?2:1;if(mt+Me>Se)break;var st,Qe,dr;Me===1?ot<128&&(We=ot):Me===2?(st=ft[mt+1],(st&192)===128&&(We=(ot&31)<<6|st&63,We<=127&&(We=null))):Me===3?(st=ft[mt+1],Qe=ft[mt+2],(st&192)===128&&(Qe&192)===128&&(We=(ot&15)<<12|(st&63)<<6|Qe&63,(We<=2047||We>=55296&&We<=57343)&&(We=null))):Me===4&&(st=ft[mt+1],Qe=ft[mt+2],dr=ft[mt+3],(st&192)===128&&(Qe&192)===128&&(dr&192)===128&&(We=(ot&15)<<18|(st&63)<<12|(Qe&63)<<6|dr&63,(We<=65535||We>=1114112)&&(We=null))),We===null?(We=65533,Me=1):We>65535&&(We-=65536,Ft+=String.fromCharCode(We>>>10&1023|55296),We=56320|We&1023),Ft+=String.fromCharCode(We),mt+=Me}return Ft}function pt(ft,wt,Se){return X.decode(ft.subarray(wt,Se))}function Ke(ft,wt,Se){for(var Ft=0,mt,ot;Ft55295&&mt<57344)if(ot)if(mt<56320){ft[Se++]=239,ft[Se++]=191,ft[Se++]=189,ot=mt;continue}else mt=ot-55296<<10|mt-56320|65536,ot=null;else{mt>56319||Ft+1===wt.length?(ft[Se++]=239,ft[Se++]=191,ft[Se++]=189):ot=mt;continue}else ot&&(ft[Se++]=239,ft[Se++]=191,ft[Se++]=189,ot=null);mt<128?ft[Se++]=mt:(mt<2048?ft[Se++]=mt>>6|192:(mt<65536?ft[Se++]=mt>>12|224:(ft[Se++]=mt>>18|240,ft[Se++]=mt>>12&63|128),ft[Se++]=mt>>6&63|128),ft[Se++]=mt&63|128)}return Se}},35447:function(Ye){Ye.exports=function(A,R,V,y){var p=A[0],$=A[1],X=!1;V===void 0&&(V=0),y===void 0&&(y=R.length);for(var se=(y-V)/2,ae=0,ce=se-1;ae$!=Ee>$&&p<(we-le)*($-De)/(Ee-De)+le;qe&&(X=!X)}return X}},76469:function(Ye,ye,A){var R=A(35447),V=A(47176);Ye.exports=function(p,$,X,se){return $.length>0&&Array.isArray($[0])?V(p,$,X,se):R(p,$,X,se)},Ye.exports.nested=V,Ye.exports.flat=R},47176:function(Ye){Ye.exports=function(A,R,V,y){var p=A[0],$=A[1],X=!1;V===void 0&&(V=0),y===void 0&&(y=R.length);for(var se=y-V,ae=0,ce=se-1;ae$!=Ee>$&&p<(we-le)*($-De)/(Ee-De)+le;qe&&(X=!X)}return X}},58767:function(Ye,ye,A){var R=A(97671);(function(V,y){Ye.exports=y()})(this,function(){"use strict";function V(xt,it){var kt={label:0,sent:function(){if(kr[0]&1)throw kr[1];return kr[1]},trys:[],ops:[]},ir,Pr,kr,An;return An={next:Dn(0),throw:Dn(1),return:Dn(2)},typeof Symbol=="function"&&(An[Symbol.iterator]=function(){return this}),An;function Dn(Lt){return function(je){return Ht([Lt,je])}}function Ht(Lt){if(ir)throw new TypeError("Generator is already executing.");for(;kt;)try{if(ir=1,Pr&&(kr=Lt[0]&2?Pr.return:Lt[0]?Pr.throw||((kr=Pr.return)&&kr.call(Pr),0):Pr.next)&&!(kr=kr.call(Pr,Lt[1])).done)return kr;switch(Pr=0,kr&&(Lt=[Lt[0]&2,kr.value]),Lt[0]){case 0:case 1:kr=Lt;break;case 4:return kt.label++,{value:Lt[1],done:!1};case 5:kt.label++,Pr=Lt[1],Lt=[0];continue;case 7:Lt=kt.ops.pop(),kt.trys.pop();continue;default:if(kr=kt.trys,!(kr=kr.length>0&&kr[kr.length-1])&&(Lt[0]===6||Lt[0]===2)){kt=0;continue}if(Lt[0]===3&&(!kr||Lt[1]>kr[0]&&Lt[1]it?1:xt0){if(it.right===null)break;if(kt(xt,it.right.key)>0){var Dn=it.right;if(it.right=Dn.left,Dn.left=it,it=Dn,it.right===null)break}Pr.right=it,Pr=it,it=it.right}else break}return Pr.right=it.left,kr.left=it.right,it.left=ir.right,it.right=ir.left,it}function X(xt,it,kt,ir){var Pr=new y(xt,it);if(kt===null)return Pr.left=Pr.right=null,Pr;kt=$(xt,kt,ir);var kr=ir(xt,kt.key);return kr<0?(Pr.left=kt.left,Pr.right=kt,kt.left=null):kr>=0&&(Pr.right=kt.right,Pr.left=kt,kt.right=null),Pr}function se(xt,it,kt){var ir=null,Pr=null;if(it){it=$(xt,it,kt);var kr=kt(it.key,xt);kr===0?(ir=it.left,Pr=it.right):kr<0?(Pr=it.right,it.right=null,ir=it):(ir=it.left,it.left=null,Pr=it)}return{left:ir,right:Pr}}function ae(xt,it,kt){return it===null?xt:(xt===null||(it=$(xt.key,it,kt),it.left=xt),it)}function ce(xt,it,kt,ir,Pr){if(xt){ir(""+it+(kt?"\u2514\u2500\u2500 ":"\u251C\u2500\u2500 ")+Pr(xt)+` +`);var kr=it+(kt?" ":"\u2502 ");xt.left&&ce(xt.left,kr,!1,ir,Pr),xt.right&&ce(xt.right,kr,!0,ir,Pr)}}var le=function(){function xt(it){it===void 0&&(it=p),this._root=null,this._size=0,this._comparator=it}return xt.prototype.insert=function(it,kt){return this._size++,this._root=X(it,kt,this._root,this._comparator)},xt.prototype.add=function(it,kt){var ir=new y(it,kt);this._root===null&&(ir.left=ir.right=null,this._size++,this._root=ir);var Pr=this._comparator,kr=$(it,this._root,Pr),An=Pr(it,kr.key);return An===0?this._root=kr:(An<0?(ir.left=kr.left,ir.right=kr,kr.left=null):An>0&&(ir.right=kr.right,ir.left=kr,kr.right=null),this._size++,this._root=ir),this._root},xt.prototype.remove=function(it){this._root=this._remove(it,this._root,this._comparator)},xt.prototype._remove=function(it,kt,ir){var Pr;if(kt===null)return null;kt=$(it,kt,ir);var kr=ir(it,kt.key);return kr===0?(kt.left===null?Pr=kt.right:(Pr=$(it,kt.left,ir),Pr.right=kt.right),this._size--,Pr):kt},xt.prototype.pop=function(){var it=this._root;if(it){for(;it.left;)it=it.left;return this._root=$(it.key,this._root,this._comparator),this._root=this._remove(it.key,this._root,this._comparator),{key:it.key,data:it.data}}return null},xt.prototype.findStatic=function(it){for(var kt=this._root,ir=this._comparator;kt;){var Pr=ir(it,kt.key);if(Pr===0)return kt;Pr<0?kt=kt.left:kt=kt.right}return null},xt.prototype.find=function(it){return this._root&&(this._root=$(it,this._root,this._comparator),this._comparator(it,this._root.key)!==0)?null:this._root},xt.prototype.contains=function(it){for(var kt=this._root,ir=this._comparator;kt;){var Pr=ir(it,kt.key);if(Pr===0)return!0;Pr<0?kt=kt.left:kt=kt.right}return!1},xt.prototype.forEach=function(it,kt){for(var ir=this._root,Pr=[],kr=!1;!kr;)ir!==null?(Pr.push(ir),ir=ir.left):Pr.length!==0?(ir=Pr.pop(),it.call(kt,ir),ir=ir.right):kr=!0;return this},xt.prototype.range=function(it,kt,ir,Pr){for(var kr=[],An=this._comparator,Dn=this._root,Ht;kr.length!==0||Dn;)if(Dn)kr.push(Dn),Dn=Dn.left;else{if(Dn=kr.pop(),Ht=An(Dn.key,kt),Ht>0)break;if(An(Dn.key,it)>=0&&ir.call(Pr,Dn))return this;Dn=Dn.right}return this},xt.prototype.keys=function(){var it=[];return this.forEach(function(kt){var ir=kt.key;return it.push(ir)}),it},xt.prototype.values=function(){var it=[];return this.forEach(function(kt){var ir=kt.data;return it.push(ir)}),it},xt.prototype.min=function(){return this._root?this.minNode(this._root).key:null},xt.prototype.max=function(){return this._root?this.maxNode(this._root).key:null},xt.prototype.minNode=function(it){if(it===void 0&&(it=this._root),it)for(;it.left;)it=it.left;return it},xt.prototype.maxNode=function(it){if(it===void 0&&(it=this._root),it)for(;it.right;)it=it.right;return it},xt.prototype.at=function(it){for(var kt=this._root,ir=!1,Pr=0,kr=[];!ir;)if(kt)kr.push(kt),kt=kt.left;else if(kr.length>0){if(kt=kr.pop(),Pr===it)return kt;Pr++,kt=kt.right}else ir=!0;return null},xt.prototype.next=function(it){var kt=this._root,ir=null;if(it.right){for(ir=it.right;ir.left;)ir=ir.left;return ir}for(var Pr=this._comparator;kt;){var kr=Pr(it.key,kt.key);if(kr===0)break;kr<0?(ir=kt,kt=kt.left):kt=kt.right}return ir},xt.prototype.prev=function(it){var kt=this._root,ir=null;if(it.left!==null){for(ir=it.left;ir.right;)ir=ir.right;return ir}for(var Pr=this._comparator;kt;){var kr=Pr(it.key,kt.key);if(kr===0)break;kr<0?kt=kt.left:(ir=kt,kt=kt.right)}return ir},xt.prototype.clear=function(){return this._root=null,this._size=0,this},xt.prototype.toList=function(){return Ee(this._root)},xt.prototype.load=function(it,kt,ir){kt===void 0&&(kt=[]),ir===void 0&&(ir=!1);var Pr=it.length,kr=this._comparator;if(ir&&ct(it,kt,0,Pr-1,kr),this._root===null)this._root=De(it,kt,0,Pr),this._size=Pr;else{var An=Ge(this.toList(),we(it,kt),kr);Pr=this._size+Pr,this._root=qe({head:An},0,Pr)}return this},xt.prototype.isEmpty=function(){return this._root===null},Object.defineProperty(xt.prototype,"size",{get:function(){return this._size},enumerable:!0,configurable:!0}),Object.defineProperty(xt.prototype,"root",{get:function(){return this._root},enumerable:!0,configurable:!0}),xt.prototype.toString=function(it){it===void 0&&(it=function(ir){return String(ir.key)});var kt=[];return ce(this._root,"",!0,function(ir){return kt.push(ir)},it),kt.join("")},xt.prototype.update=function(it,kt,ir){var Pr=this._comparator,kr=se(it,this._root,Pr),An=kr.left,Dn=kr.right;Pr(it,kt)<0?Dn=X(kt,ir,Dn,Pr):An=X(kt,ir,An,Pr),this._root=ae(An,Dn,Pr)},xt.prototype.split=function(it){return se(it,this._root,this._comparator)},xt.prototype[Symbol.iterator]=function(){var it,kt,ir;return V(this,function(Pr){switch(Pr.label){case 0:it=this._root,kt=[],ir=!1,Pr.label=1;case 1:return ir?[3,6]:it===null?[3,2]:(kt.push(it),it=it.left,[3,5]);case 2:return kt.length===0?[3,4]:(it=kt.pop(),[4,it]);case 3:return Pr.sent(),it=it.right,[3,5];case 4:ir=!0,Pr.label=5;case 5:return[3,1];case 6:return[2]}})},xt}();function De(xt,it,kt,ir){var Pr=ir-kt;if(Pr>0){var kr=kt+Math.floor(Pr/2),An=xt[kr],Dn=it[kr],Ht=new y(An,Dn);return Ht.left=De(xt,it,kt,kr),Ht.right=De(xt,it,kr+1,ir),Ht}return null}function we(xt,it){for(var kt=new y(null,null),ir=kt,Pr=0;Pr0?(it=kr=kr.next=kt.pop(),it=it.right):ir=!0;return kr.next=null,Pr.next}function qe(xt,it,kt){var ir=kt-it;if(ir>0){var Pr=it+Math.floor(ir/2),kr=qe(xt,it,Pr),An=xt.head;return An.left=kr,xt.head=xt.head.next,An.right=qe(xt,Pr+1,kt),An}return null}function Ge(xt,it,kt){for(var ir=new y(null,null),Pr=ir,kr=xt,An=it;kr!==null&&An!==null;)kt(kr.key,An.key)<0?(Pr.next=kr,kr=kr.next):(Pr.next=An,An=An.next),Pr=Pr.next;return kr!==null?Pr.next=kr:An!==null&&(Pr.next=An),ir.next}function ct(xt,it,kt,ir,Pr){if(!(kt>=ir)){for(var kr=xt[kt+ir>>1],An=kt-1,Dn=ir+1;;){do An++;while(Pr(xt[An],kr)<0);do Dn--;while(Pr(xt[Dn],kr)>0);if(An>=Dn)break;var Ht=xt[An];xt[An]=xt[Dn],xt[Dn]=Ht,Ht=it[An],it[An]=it[Dn],it[Dn]=Ht}ct(xt,it,kt,Dn,Pr),ct(xt,it,Dn+1,ir,Pr)}}const Ve=(xt,it)=>xt.ll.x<=it.x&&it.x<=xt.ur.x&&xt.ll.y<=it.y&&it.y<=xt.ur.y,ut=(xt,it)=>{if(it.ur.x{if(-XeLt==je>-Lt?(kr=Lt,Lt=it[++$e]):(kr=je,je=ir[++At]);let Bt=0;if($eLt==je>-Lt?(An=Lt+kr,Dn=kr-(An-Lt),Lt=it[++$e]):(An=je+kr,Dn=kr-(An-je),je=ir[++At]),kr=An,Dn!==0&&(Pr[Bt++]=Dn);$eLt==je>-Lt?(An=kr+Lt,Ht=An-kr,Dn=kr-(An-Ht)+(Lt-Ht),Lt=it[++$e]):(An=kr+je,Ht=An-kr,Dn=kr-(An-Ht)+(je-Ht),je=ir[++At]),kr=An,Dn!==0&&(Pr[Bt++]=Dn);for(;$e=Lo||-Gi>=Lo||($e=xt-Wn,Dn=xt-(Wn+$e)+($e-Pr),$e=kt-Rn,Lt=kt-(Rn+$e)+($e-Pr),$e=it-di,Ht=it-(di+$e)+($e-kr),$e=ir-zi,je=ir-(zi+$e)+($e-kr),Dn===0&&Ht===0&&Lt===0&&je===0)||(Lo=mt*An+pt*Math.abs(Gi),Gi+=Wn*je+zi*Dn-(di*Lt+Rn*Ht),Gi>=Lo||-Gi>=Lo))return Gi;bn=Dn*zi,At=et*Dn,Bt=At-(At-Dn),Jt=Dn-Bt,At=et*zi,ar=At-(At-zi),hr=zi-ar,Bi=Jt*hr-(bn-Bt*ar-Jt*ar-Bt*hr),on=Ht*Rn,At=et*Ht,Bt=At-(At-Ht),Jt=Ht-Bt,At=et*Rn,ar=At-(At-Rn),hr=Rn-ar,dn=Jt*hr-(on-Bt*ar-Jt*ar-Bt*hr),Gt=Bi-dn,$e=Bi-Gt,Qe[0]=Bi-(Gt+$e)+($e-dn),Tr=bn+Gt,$e=Tr-bn,nn=bn-(Tr-$e)+(Gt-$e),Gt=nn-on,$e=nn-Gt,Qe[1]=nn-(Gt+$e)+($e-on),ri=Tr+Gt,$e=ri-Tr,Qe[2]=Tr-(ri-$e)+(Gt-$e),Qe[3]=ri;const eo=Ke(4,ot,4,Qe,We);bn=Wn*je,At=et*Wn,Bt=At-(At-Wn),Jt=Wn-Bt,At=et*je,ar=At-(At-je),hr=je-ar,Bi=Jt*hr-(bn-Bt*ar-Jt*ar-Bt*hr),on=di*Lt,At=et*di,Bt=At-(At-di),Jt=di-Bt,At=et*Lt,ar=At-(At-Lt),hr=Lt-ar,dn=Jt*hr-(on-Bt*ar-Jt*ar-Bt*hr),Gt=Bi-dn,$e=Bi-Gt,Qe[0]=Bi-(Gt+$e)+($e-dn),Tr=bn+Gt,$e=Tr-bn,nn=bn-(Tr-$e)+(Gt-$e),Gt=nn-on,$e=nn-Gt,Qe[1]=nn-(Gt+$e)+($e-on),ri=Tr+Gt,$e=ri-Tr,Qe[2]=Tr-(ri-$e)+(Gt-$e),Qe[3]=ri;const ba=Ke(eo,We,4,Qe,Me);bn=Dn*je,At=et*Dn,Bt=At-(At-Dn),Jt=Dn-Bt,At=et*je,ar=At-(At-je),hr=je-ar,Bi=Jt*hr-(bn-Bt*ar-Jt*ar-Bt*hr),on=Ht*Lt,At=et*Ht,Bt=At-(At-Ht),Jt=Ht-Bt,At=et*Lt,ar=At-(At-Lt),hr=Lt-ar,dn=Jt*hr-(on-Bt*ar-Jt*ar-Bt*hr),Gt=Bi-dn,$e=Bi-Gt,Qe[0]=Bi-(Gt+$e)+($e-dn),Tr=bn+Gt,$e=Tr-bn,nn=bn-(Tr-$e)+(Gt-$e),Gt=nn-on,$e=nn-Gt,Qe[1]=nn-(Gt+$e)+($e-on),ri=Tr+Gt,$e=ri-Tr,Qe[2]=Tr-(ri-$e)+(Gt-$e),Qe[3]=ri;const va=Ke(ba,Me,4,Qe,st);return st[va-1]}function Kt(xt,it,kt,ir,Pr,kr){const An=(it-kr)*(kt-Pr),Dn=(xt-Pr)*(ir-kr),Ht=An-Dn,Lt=Math.abs(An+Dn);return Math.abs(Ht)>=Se*Lt?Ht:-dr(xt,it,kt,ir,Pr,kr,Lt)}const Yr=(xt,it)=>xt.x*it.y-xt.y*it.x,hn=(xt,it)=>xt.x*it.x+xt.y*it.y,ln=(xt,it,kt)=>{const ir=Kt(xt.x,xt.y,it.x,it.y,kt.x,kt.y);return ir>0?-1:ir<0?1:0},oi=xt=>Math.sqrt(hn(xt,xt)),Nn=(xt,it,kt)=>{const ir={x:it.x-xt.x,y:it.y-xt.y},Pr={x:kt.x-xt.x,y:kt.y-xt.y};return Yr(Pr,ir)/oi(Pr)/oi(ir)},$n=(xt,it,kt)=>{const ir={x:it.x-xt.x,y:it.y-xt.y},Pr={x:kt.x-xt.x,y:kt.y-xt.y};return hn(Pr,ir)/oi(Pr)/oi(ir)},_i=(xt,it,kt)=>it.y===0?null:{x:xt.x+it.x/it.y*(kt-xt.y),y:kt},Qn=(xt,it,kt)=>it.x===0?null:{x:kt,y:xt.y+it.y/it.x*(kt-xt.x)},Ji=(xt,it,kt,ir)=>{if(it.x===0)return Qn(kt,ir,xt.x);if(ir.x===0)return Qn(xt,it,kt.x);if(it.y===0)return _i(kt,ir,xt.y);if(ir.y===0)return _i(xt,it,kt.y);const Pr=Yr(it,ir);if(Pr==0)return null;const kr={x:kt.x-xt.x,y:kt.y-xt.y},An=Yr(kr,it)/Pr,Dn=Yr(kr,ir)/Pr,Ht=xt.x+Dn*it.x,Lt=kt.x+An*ir.x,je=xt.y+Dn*it.y,$e=kt.y+An*ir.y,At=(Ht+Lt)/2,Bt=(je+$e)/2;return{x:At,y:Bt}};class ni{static compare(it,kt){const ir=ni.comparePoints(it.point,kt.point);return ir!==0?ir:(it.point!==kt.point&&it.link(kt),it.isLeft!==kt.isLeft?it.isLeft?1:-1:xo.compare(it.segment,kt.segment))}static comparePoints(it,kt){return it.xkt.x?1:it.ykt.y?1:0}constructor(it,kt){it.events===void 0?it.events=[this]:it.events.push(this),this.point=it,this.isLeft=kt}link(it){if(it.point===this.point)throw new Error("Tried to link already linked events");const kt=it.point.events;for(let ir=0,Pr=kt.length;ir{const kr=Pr.otherSE;kt.set(Pr,{sine:Nn(this.point,it.point,kr.point),cosine:$n(this.point,it.point,kr.point)})};return(Pr,kr)=>{kt.has(Pr)||ir(Pr),kt.has(kr)||ir(kr);const{sine:An,cosine:Dn}=kt.get(Pr),{sine:Ht,cosine:Lt}=kt.get(kr);return An>=0&&Ht>=0?DnLt?-1:0:An<0&&Ht<0?DnLt?1:0:HtAn?1:0}}}let Ei=0;class xo{static compare(it,kt){const ir=it.leftSE.point.x,Pr=kt.leftSE.point.x,kr=it.rightSE.point.x,An=kt.rightSE.point.x;if(AnDn&&Ht>Lt)return-1;const $e=it.comparePoint(kt.leftSE.point);if($e<0)return 1;if($e>0)return-1;const At=kt.comparePoint(it.rightSE.point);return At!==0?At:-1}if(ir>Pr){if(DnHt&&Dn>je)return 1;const $e=kt.comparePoint(it.leftSE.point);if($e!==0)return $e;const At=it.comparePoint(kt.rightSE.point);return At<0?1:At>0?-1:1}if(DnHt)return 1;if(krAn){const $e=it.comparePoint(kt.rightSE.point);if($e<0)return 1;if($e>0)return-1}if(kr!==An){const $e=Lt-Dn,At=kr-ir,Bt=je-Ht,Jt=An-Pr;if($e>At&&BtJt)return-1}return kr>An?1:krje?1:it.idkt.id?1:0}constructor(it,kt,ir,Pr){this.id=++Ei,this.leftSE=it,it.segment=this,it.otherSE=kt,this.rightSE=kt,kt.segment=this,kt.otherSE=it,this.rings=ir,this.windings=Pr}static fromRing(it,kt,ir){let Pr,kr,An;const Dn=ni.comparePoints(it,kt);if(Dn<0)Pr=it,kr=kt,An=1;else if(Dn>0)Pr=kt,kr=it,An=-1;else throw new Error(`Tried to create degenerate segment at [${it.x}, ${it.y}]`);const Ht=new ni(Pr,!0),Lt=new ni(kr,!1);return new xo(Ht,Lt,[ir],[An])}replaceRightSE(it){this.rightSE=it,this.rightSE.segment=this,this.rightSE.otherSE=this.leftSE,this.leftSE.otherSE=this.rightSE}bbox(){const it=this.leftSE.point.y,kt=this.rightSE.point.y;return{ll:{x:this.leftSE.point.x,y:itkt?it:kt}}}vector(){return{x:this.rightSE.point.x-this.leftSE.point.x,y:this.rightSE.point.y-this.leftSE.point.y}}isAnEndpoint(it){return it.x===this.leftSE.point.x&&it.y===this.leftSE.point.y||it.x===this.rightSE.point.x&&it.y===this.rightSE.point.y}comparePoint(it){if(this.isAnEndpoint(it))return 0;const kt=this.leftSE.point,ir=this.rightSE.point,Pr=this.vector();if(kt.x===ir.x)return it.x===kt.x?0:it.x0&&Dn.swapEvents(),ni.comparePoints(this.leftSE.point,this.rightSE.point)>0&&this.swapEvents(),ir&&(Pr.checkForConsuming(),kr.checkForConsuming()),kt}swapEvents(){const it=this.rightSE;this.rightSE=this.leftSE,this.leftSE=it,this.leftSE.isLeft=!0,this.rightSE.isLeft=!1;for(let kt=0,ir=this.windings.length;kt0){const kr=kt;kt=ir,ir=kr}if(kt.prev===ir){const kr=kt;kt=ir,ir=kr}for(let kr=0,An=ir.rings.length;krPr.length===1&&Pr[0].isSubject;this._isInResult=ir(it)!==ir(kt);break}default:throw new Error(`Unrecognized operation type found ${Fn.type}`)}return this._isInResult}}class sn{constructor(it,kt,ir){if(!Array.isArray(it)||it.length===0)throw new Error("Input geometry is not a valid Polygon or MultiPolygon");if(this.poly=kt,this.isExterior=ir,this.segments=[],typeof it[0][0]!="number"||typeof it[0][1]!="number")throw new Error("Input geometry is not a valid Polygon or MultiPolygon");const Pr=Ne.round(it[0][0],it[0][1]);this.bbox={ll:{x:Pr.x,y:Pr.y},ur:{x:Pr.x,y:Pr.y}};let kr=Pr;for(let An=1,Dn=it.length;Anthis.bbox.ur.x&&(this.bbox.ur.x=Ht.x),Ht.y>this.bbox.ur.y&&(this.bbox.ur.y=Ht.y),kr=Ht)}(Pr.x!==kr.x||Pr.y!==kr.y)&&this.segments.push(xo.fromRing(kr,Pr,this))}getSweepEvents(){const it=[];for(let kt=0,ir=this.segments.length;ktthis.bbox.ur.x&&(this.bbox.ur.x=kr.bbox.ur.x),kr.bbox.ur.y>this.bbox.ur.y&&(this.bbox.ur.y=kr.bbox.ur.y),this.interiorRings.push(kr)}this.multiPoly=kt}getSweepEvents(){const it=this.exteriorRing.getSweepEvents();for(let kt=0,ir=this.interiorRings.length;ktthis.bbox.ur.x&&(this.bbox.ur.x=kr.bbox.ur.x),kr.bbox.ur.y>this.bbox.ur.y&&(this.bbox.ur.y=kr.bbox.ur.y),this.polys.push(kr)}this.isSubject=kt}getSweepEvents(){const it=[];for(let kt=0,ir=this.polys.length;kt0&&(it=An)}let kt=it.segment.prevInResult(),ir=kt?kt.prevInResult():null;for(;;){if(!kt)return null;if(!ir)return kt.ringOut;if(ir.ringOut!==kt.ringOut)return ir.ringOut.enclosingRing()!==kt.ringOut?kt.ringOut:kt.ringOut.enclosingRing();kt=ir.prevInResult(),ir=kt?kt.prevInResult():null}}}class qi{constructor(it){this.exteriorRing=it,it.poly=this,this.interiorRings=[]}addInterior(it){this.interiorRings.push(it),it.poly=this}getGeom(){const it=[this.exteriorRing.getGeom()];if(it[0]===null)return null;for(let kt=0,ir=this.interiorRings.length;kt1&&arguments[1]!==void 0?arguments[1]:xo.compare;this.queue=it,this.tree=new le(kt),this.segments=[]}process(it){const kt=it.segment,ir=[];if(it.consumedBy)return it.isLeft?this.queue.remove(it.otherSE):this.tree.remove(kt),ir;const Pr=it.isLeft?this.tree.add(kt):this.tree.find(kt);if(!Pr)throw new Error(`Unable to find segment #${kt.id} [${kt.leftSE.point.x}, ${kt.leftSE.point.y}] -> [${kt.rightSE.point.x}, ${kt.rightSE.point.y}] in SweepLine tree.`);let kr=Pr,An=Pr,Dn,Ht;for(;Dn===void 0;)kr=this.tree.prev(kr),kr===null?Dn=null:kr.key.consumedBy===void 0&&(Dn=kr.key);for(;Ht===void 0;)An=this.tree.next(An),An===null?Ht=null:An.key.consumedBy===void 0&&(Ht=An.key);if(it.isLeft){let Lt=null;if(Dn){const $e=Dn.getIntersection(kt);if($e!==null&&(kt.isAnEndpoint($e)||(Lt=$e),!Dn.isAnEndpoint($e))){const At=this._splitSafely(Dn,$e);for(let Bt=0,Jt=At.length;Bt0?(this.tree.remove(kt),ir.push(it)):(this.segments.push(kt),kt.prev=Dn)}else{if(Dn&&Ht){const Lt=Dn.getIntersection(Ht);if(Lt!==null){if(!Dn.isAnEndpoint(Lt)){const je=this._splitSafely(Dn,Lt);for(let $e=0,At=je.length;$eWi)throw new Error("Infinite loop when putting segment endpoints in a priority queue (queue size too big).")}const An=new Mo(kr);let Dn=kr.size,Ht=kr.pop();for(;Ht;){const $e=Ht.key;if(kr.size===Dn){const Bt=$e.segment;throw new Error(`Unable to pop() ${$e.isLeft?"left":"right"} SweepEvent [${$e.point.x}, ${$e.point.y}] from segment #${Bt.id} [${Bt.leftSE.point.x}, ${Bt.leftSE.point.y}] -> [${Bt.rightSE.point.x}, ${Bt.rightSE.point.y}] from queue.`)}if(kr.size>Wi)throw new Error("Infinite loop when passing sweep line over endpoints (queue size too big).");if(An.segments.length>Ii)throw new Error("Infinite loop when passing sweep line over endpoints (too many sweep line segments).");const At=An.process($e);for(let Bt=0,Jt=At.length;Bt1?it-1:0),ir=1;ir1?it-1:0),ir=1;ir1?it-1:0),ir=1;ir1?it-1:0),ir=1;ir1)for(var ct=1;ct$;){if(X-$>600){var ae=X-$+1,ce=p-$+1,le=Math.log(ae),De=.5*Math.exp(2*le/3),we=.5*Math.sqrt(le*De*(ae-De)/ae)*(ce-ae/2<0?-1:1),Ee=Math.max($,Math.floor(p-ce*De/ae+we)),qe=Math.min(X,Math.floor(p+(ae-ce)*De/ae+we));A(y,p,Ee,qe,se)}var Ge=y[p],ct=$,Ve=X;for(R(y,$,p),se(y[X],Ge)>0&&R(y,$,X);ct0;)Ve--}se(y[$],Ge)===0?R(y,$,Ve):(Ve++,R(y,Ve,X)),Ve<=p&&($=Ve+1),p<=Ve&&(X=Ve-1)}}function R(y,p,$){var X=y[p];y[p]=y[$],y[$]=X}function V(y,p){return yp?1:0}return ye})},85475:function(Ye,ye,A){"use strict";Ye.exports=V,Ye.exports.default=V;var R=A(13664);function V(Ve,ut){if(!(this instanceof V))return new V(Ve,ut);this._maxEntries=Math.max(4,Ve||9),this._minEntries=Math.max(2,Math.ceil(this._maxEntries*.4)),ut&&this._initFormat(ut),this.clear()}V.prototype={all:function(){return this._all(this.data,[])},search:function(Ve){var ut=this.data,Xe=[],Rt=this.toBBox;if(!qe(Ve,ut))return Xe;for(var gt=[],Ct,tt,Ne,bt;ut;){for(Ct=0,tt=ut.children.length;Ct=0&&Ct[ut].children.length>this._maxEntries;)this._split(Ct,ut),ut--;this._adjustParentBBoxes(gt,Ct,ut)},_split:function(Ve,ut){var Xe=Ve[ut],Rt=Xe.children.length,gt=this._minEntries;this._chooseSplitAxis(Xe,gt,Rt);var Ct=this._chooseSplitIndex(Xe,gt,Rt),tt=Ge(Xe.children.splice(Ct,Xe.children.length-Ct));tt.height=Xe.height,tt.leaf=Xe.leaf,p(Xe,this.toBBox),p(tt,this.toBBox),ut?Ve[ut-1].children.push(tt):this._splitRoot(Xe,tt)},_splitRoot:function(Ve,ut){this.data=Ge([Ve,ut]),this.data.height=Ve.height+1,this.data.leaf=!1,p(this.data,this.toBBox)},_chooseSplitIndex:function(Ve,ut,Xe){var Rt,gt,Ct,tt,Ne,bt,et,pt;for(bt=et=1/0,Rt=ut;Rt<=Xe-ut;Rt++)gt=$(Ve,0,Rt,this.toBBox),Ct=$(Ve,Rt,Xe,this.toBBox),tt=we(gt,Ct),Ne=ce(gt)+ce(Ct),tt=ut;bt--)et=Ve.children[bt],X(tt,Ve.leaf?gt(et):et),Ne+=le(tt);return Ne},_adjustParentBBoxes:function(Ve,ut,Xe){for(var Rt=Xe;Rt>=0;Rt--)X(ut[Rt],Ve)},_condense:function(Ve){for(var ut=Ve.length-1,Xe;ut>=0;ut--)Ve[ut].children.length===0?ut>0?(Xe=Ve[ut-1].children,Xe.splice(Xe.indexOf(Ve[ut]),1)):this.clear():p(Ve[ut],this.toBBox)},_initFormat:function(Ve){var ut=["return a"," - b",";"];this.compareMinX=new Function("a","b",ut.join(Ve[0])),this.compareMinY=new Function("a","b",ut.join(Ve[1])),this.toBBox=new Function("a","return {minX: a"+Ve[0]+", minY: a"+Ve[1]+", maxX: a"+Ve[2]+", maxY: a"+Ve[3]+"};")}};function y(Ve,ut,Xe){if(!Xe)return ut.indexOf(Ve);for(var Rt=0;Rt=Ve.minX&&ut.maxY>=Ve.minY}function Ge(Ve){return{children:Ve,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function ct(Ve,ut,Xe,Rt,gt){for(var Ct=[ut,Xe],tt;Ct.length;)Xe=Ct.pop(),ut=Ct.pop(),!(Xe-ut<=Rt)&&(tt=ut+Math.ceil((Xe-ut)/Rt/2)*Rt,R(Ve,tt,ut,Xe,gt),Ct.push(ut,tt,tt,Xe))}},79535:function(Ye){(function(ye,A){Ye.exports=A()})(this,function(){"use strict";function ye(Ge,ct,Ve,ut,Xe){(function Rt(gt,Ct,tt,Ne,bt){for(;Ne>tt;){if(Ne-tt>600){var et=Ne-tt+1,pt=Ct-tt+1,Ke=Math.log(et),ft=.5*Math.exp(2*Ke/3),wt=.5*Math.sqrt(Ke*ft*(et-ft)/et)*(pt-et/2<0?-1:1),Se=Math.max(tt,Math.floor(Ct-pt*ft/et+wt)),Ft=Math.min(Ne,Math.floor(Ct+(et-pt)*ft/et+wt));Rt(gt,Ct,Se,Ft,bt)}var mt=gt[Ct],ot=tt,We=Ne;for(A(gt,tt,Ct),bt(gt[Ne],mt)>0&&A(gt,tt,Ne);ot0;)We--}bt(gt[tt],mt)===0?A(gt,tt,We):A(gt,++We,Ne),We<=Ct&&(tt=We+1),Ct<=We&&(Ne=We-1)}})(Ge,ct,Ve||0,ut||Ge.length-1,Xe||R)}function A(Ge,ct,Ve){var ut=Ge[ct];Ge[ct]=Ge[Ve],Ge[Ve]=ut}function R(Ge,ct){return Gect?1:0}var V=function(Ge){Ge===void 0&&(Ge=9),this._maxEntries=Math.max(4,Ge),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),this.clear()};function y(Ge,ct,Ve){if(!Ve)return ct.indexOf(Ge);for(var ut=0;ut=Ge.minX&&ct.maxY>=Ge.minY}function Ee(Ge){return{children:Ge,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function qe(Ge,ct,Ve,ut,Xe){for(var Rt=[ct,Ve];Rt.length;)if(!((Ve=Rt.pop())-(ct=Rt.pop())<=ut)){var gt=ct+Math.ceil((Ve-ct)/ut/2)*ut;ye(Ge,gt,ct,Ve,Xe),Rt.push(ct,gt,gt,Ve)}}return V.prototype.all=function(){return this._all(this.data,[])},V.prototype.search=function(Ge){var ct=this.data,Ve=[];if(!we(Ge,ct))return Ve;for(var ut=this.toBBox,Xe=[];ct;){for(var Rt=0;Rt=0&&Xe[ct].children.length>this._maxEntries;)this._split(Xe,ct),ct--;this._adjustParentBBoxes(ut,Xe,ct)},V.prototype._split=function(Ge,ct){var Ve=Ge[ct],ut=Ve.children.length,Xe=this._minEntries;this._chooseSplitAxis(Ve,Xe,ut);var Rt=this._chooseSplitIndex(Ve,Xe,ut),gt=Ee(Ve.children.splice(Rt,Ve.children.length-Rt));gt.height=Ve.height,gt.leaf=Ve.leaf,p(Ve,this.toBBox),p(gt,this.toBBox),ct?Ge[ct-1].children.push(gt):this._splitRoot(Ve,gt)},V.prototype._splitRoot=function(Ge,ct){this.data=Ee([Ge,ct]),this.data.height=Ge.height+1,this.data.leaf=!1,p(this.data,this.toBBox)},V.prototype._chooseSplitIndex=function(Ge,ct,Ve){for(var ut,Xe,Rt,gt,Ct,tt,Ne,bt=1/0,et=1/0,pt=ct;pt<=Ve-ct;pt++){var Ke=$(Ge,0,pt,this.toBBox),ft=$(Ge,pt,Ve,this.toBBox),wt=(Xe=Ke,Rt=ft,gt=void 0,Ct=void 0,tt=void 0,Ne=void 0,gt=Math.max(Xe.minX,Rt.minX),Ct=Math.max(Xe.minY,Rt.minY),tt=Math.min(Xe.maxX,Rt.maxX),Ne=Math.min(Xe.maxY,Rt.maxY),Math.max(0,tt-gt)*Math.max(0,Ne-Ct)),Se=ce(Ke)+ce(ft);wt=ct;bt--){var et=Ge.children[bt];X(gt,Ge.leaf?Xe(et):et),Ct+=le(gt)}return Ct},V.prototype._adjustParentBBoxes=function(Ge,ct,Ve){for(var ut=Ve;ut>=0;ut--)X(ct[ut],Ge)},V.prototype._condense=function(Ge){for(var ct=Ge.length-1,Ve=void 0;ct>=0;ct--)Ge[ct].children.length===0?ct>0?(Ve=Ge[ct-1].children).splice(Ve.indexOf(Ge[ct]),1):this.clear():p(Ge[ct],this.toBBox)},V})},44516:function(Ye,ye,A){"use strict";A.d(ye,{V4:function(){return ir},zt:function(){return Ee},ZP:function(){return Pr}});var R=A(16514),V=A(54131),y=A(35372),p=A(13255),$=A(92310),X=A.n($),se=A(58035),ae=A(88831),ce=A(77617),le=A(56348),De=["children"],we=ce.createContext({});function Ee(kr){var An=kr.children,Dn=(0,le.Z)(kr,De);return ce.createElement(we.Provider,{value:Dn},An)}var qe=A(61577),Ge=A(22946),ct=A(3711),Ve=A(71038),ut=function(kr){(0,ct.Z)(Dn,kr);var An=(0,Ve.Z)(Dn);function Dn(){return(0,qe.Z)(this,Dn),An.apply(this,arguments)}return(0,Ge.Z)(Dn,[{key:"render",value:function(){return this.props.children}}]),Dn}(ce.Component),Xe=ut,Rt=A(30462),gt="none",Ct="appear",tt="enter",Ne="leave",bt="none",et="prepare",pt="start",Ke="active",ft="end",wt="prepared",Se=A(42871);function Ft(kr,An){var Dn={};return Dn[kr.toLowerCase()]=An.toLowerCase(),Dn["Webkit".concat(kr)]="webkit".concat(An),Dn["Moz".concat(kr)]="moz".concat(An),Dn["ms".concat(kr)]="MS".concat(An),Dn["O".concat(kr)]="o".concat(An.toLowerCase()),Dn}function mt(kr,An){var Dn={animationend:Ft("Animation","AnimationEnd"),transitionend:Ft("Transition","TransitionEnd")};return kr&&("AnimationEvent"in An||delete Dn.animationend.animation,"TransitionEvent"in An||delete Dn.transitionend.transition),Dn}var ot=mt((0,Se.Z)(),typeof window!="undefined"?window:{}),We={};if((0,Se.Z)()){var Me=document.createElement("div");We=Me.style}var st={};function Qe(kr){if(st[kr])return st[kr];var An=ot[kr];if(An)for(var Dn=Object.keys(An),Ht=Dn.length,Lt=0;Lt1&&arguments[1]!==void 0?arguments[1]:2;An();var je=(0,Qn.Z)(function(){Lt<=1?Ht({isCanceled:function(){return je!==kr.current}}):Dn(Ht,Lt-1)});kr.current=je}return ce.useEffect(function(){return function(){An()}},[]),[Dn,An]},ni=[et,pt,Ke,ft],Ei=[et,wt],xo=!1,sn=!0;function li(kr){return kr===Ke||kr===ft}var En=function(kr,An,Dn){var Ht=(0,Rt.Z)(bt),Lt=(0,y.Z)(Ht,2),je=Lt[0],$e=Lt[1],At=Ji(),Bt=(0,y.Z)(At,2),Jt=Bt[0],ar=Bt[1];function hr(){$e(et,!0)}var Gt=An?Ei:ni;return _i(function(){if(je!==bt&&je!==ft){var Tr=Gt.indexOf(je),nn=Gt[Tr+1],bn=Dn(je);bn===xo?$e(nn,!0):nn&&Jt(function(Bi){function on(){Bi.isCanceled()||$e(nn,!0)}bn===!0?on():Promise.resolve(bn).then(on)})}},[kr,je]),ce.useEffect(function(){return function(){ar()}},[]),[hr,je]};function or(kr,An,Dn,Ht){var Lt=Ht.motionEnter,je=Lt===void 0?!0:Lt,$e=Ht.motionAppear,At=$e===void 0?!0:$e,Bt=Ht.motionLeave,Jt=Bt===void 0?!0:Bt,ar=Ht.motionDeadline,hr=Ht.motionLeaveImmediately,Gt=Ht.onAppearPrepare,Tr=Ht.onEnterPrepare,nn=Ht.onLeavePrepare,bn=Ht.onAppearStart,Bi=Ht.onEnterStart,on=Ht.onLeaveStart,dn=Ht.onAppearActive,ri=Ht.onEnterActive,Wn=Ht.onLeaveActive,Rn=Ht.onAppearEnd,di=Ht.onEnterEnd,zi=Ht.onLeaveEnd,Gi=Ht.onVisibleChanged,Lo=(0,Rt.Z)(),eo=(0,y.Z)(Lo,2),ba=eo[0],va=eo[1],Do=(0,Rt.Z)(gt),Ps=(0,y.Z)(Do,2),Nr=Ps[0],fo=Ps[1],hi=(0,Rt.Z)(null),Yi=(0,y.Z)(hi,2),ga=Yi[0],Xi=Yi[1],On=(0,ce.useRef)(!1),gi=(0,ce.useRef)(null);function ol(){return Dn()}var ks=(0,ce.useRef)(!1);function as(){fo(gt,!0),Xi(null,!0)}function _s(lu){var Pn=ol();if(!(lu&&!lu.deadline&&lu.target!==Pn)){var Wr=ks.current,Ci;Nr===Ct&&Wr?Ci=Rn==null?void 0:Rn(Pn,lu):Nr===tt&&Wr?Ci=di==null?void 0:di(Pn,lu):Nr===Ne&&Wr&&(Ci=zi==null?void 0:zi(Pn,lu)),Nr!==gt&&Wr&&Ci!==!1&&as()}}var Ks=Nn(_s),Ea=(0,y.Z)(Ks,1),hs=Ea[0],Ju=function(Pn){var Wr,Ci,at;switch(Pn){case Ct:return Wr={},(0,R.Z)(Wr,et,Gt),(0,R.Z)(Wr,pt,bn),(0,R.Z)(Wr,Ke,dn),Wr;case tt:return Ci={},(0,R.Z)(Ci,et,Tr),(0,R.Z)(Ci,pt,Bi),(0,R.Z)(Ci,Ke,ri),Ci;case Ne:return at={},(0,R.Z)(at,et,nn),(0,R.Z)(at,pt,on),(0,R.Z)(at,Ke,Wn),at;default:return{}}},Fa=ce.useMemo(function(){return Ju(Nr)},[Nr]),dc=En(Nr,!kr,function(lu){if(lu===et){var Pn=Fa[et];return Pn?Pn(ol()):xo}if(As in Fa){var Wr;Xi(((Wr=Fa[As])===null||Wr===void 0?void 0:Wr.call(Fa,ol(),null))||null)}return As===Ke&&(hs(ol()),ar>0&&(clearTimeout(gi.current),gi.current=setTimeout(function(){_s({deadline:!0})},ar))),As===wt&&as(),sn}),el=(0,y.Z)(dc,2),fl=el[0],As=el[1],Rl=li(As);ks.current=Rl,_i(function(){va(An);var lu=On.current;On.current=!0;var Pn;!lu&&An&&At&&(Pn=Ct),lu&&An&&je&&(Pn=tt),(lu&&!An&&Jt||!lu&&hr&&!An&&Jt)&&(Pn=Ne);var Wr=Ju(Pn);Pn&&(kr||Wr[et])?(fo(Pn),fl()):fo(gt)},[An]),(0,ce.useEffect)(function(){(Nr===Ct&&!At||Nr===tt&&!je||Nr===Ne&&!Jt)&&fo(gt)},[At,je,Jt]),(0,ce.useEffect)(function(){return function(){On.current=!1,clearTimeout(gi.current)}},[]);var dl=ce.useRef(!1);(0,ce.useEffect)(function(){ba&&(dl.current=!0),ba!==void 0&&Nr===gt&&((dl.current||ba)&&(Gi==null||Gi(ba)),dl.current=!0)},[ba,Nr]);var _c=ga;return Fa[et]&&As===pt&&(_c=(0,V.Z)({transition:"none"},_c)),[Nr,As,_c,ba!=null?ba:An]}function qi(kr){var An=kr;(0,p.Z)(kr)==="object"&&(An=kr.transitionSupport);function Dn(Lt,je){return!!(Lt.motionName&&An&&je!==!1)}var Ht=ce.forwardRef(function(Lt,je){var $e=Lt.visible,At=$e===void 0?!0:$e,Bt=Lt.removeOnLeave,Jt=Bt===void 0?!0:Bt,ar=Lt.forceRender,hr=Lt.children,Gt=Lt.motionName,Tr=Lt.leavedClassName,nn=Lt.eventProps,bn=ce.useContext(we),Bi=bn.motion,on=Dn(Lt,Bi),dn=(0,ce.useRef)(),ri=(0,ce.useRef)();function Wn(){try{return dn.current instanceof HTMLElement?dn.current:(0,se.Z)(ri.current)}catch(Xi){return null}}var Rn=or(on,At,Wn,Lt),di=(0,y.Z)(Rn,4),zi=di[0],Gi=di[1],Lo=di[2],eo=di[3],ba=ce.useRef(eo);eo&&(ba.current=!0);var va=ce.useCallback(function(Xi){dn.current=Xi,(0,ae.mH)(je,Xi)},[je]),Do,Ps=(0,V.Z)((0,V.Z)({},nn),{},{visible:At});if(!hr)Do=null;else if(zi===gt)eo?Do=hr((0,V.Z)({},Ps),va):!Jt&&ba.current&&Tr?Do=hr((0,V.Z)((0,V.Z)({},Ps),{},{className:Tr}),va):ar||!Jt&&!Tr?Do=hr((0,V.Z)((0,V.Z)({},Ps),{},{style:{display:"none"}}),va):Do=null;else{var Nr,fo;Gi===et?fo="prepare":li(Gi)?fo="active":Gi===pt&&(fo="start");var hi=oi(Gt,"".concat(zi,"-").concat(fo));Do=hr((0,V.Z)((0,V.Z)({},Ps),{},{className:X()(oi(Gt,zi),(Nr={},(0,R.Z)(Nr,hi,hi&&fo),(0,R.Z)(Nr,Gt,typeof Gt=="string"),Nr)),style:Lo}),va)}if(ce.isValidElement(Do)&&(0,ae.Yr)(Do)){var Yi=Do,ga=Yi.ref;ga||(Do=ce.cloneElement(Do,{ref:va}))}return ce.createElement(Xe,{ref:ri},Do)});return Ht.displayName="CSSMotion",Ht}var Bo=qi(Yr),Mo=A(79384),Wi=A(7963),Ii="add",ko="keep",Fn="remove",zn="removed";function Un(kr){var An;return kr&&(0,p.Z)(kr)==="object"&&"key"in kr?An=kr:An={key:kr},(0,V.Z)((0,V.Z)({},An),{},{key:String(An.key)})}function Hi(){var kr=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return kr.map(Un)}function Ki(){var kr=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],An=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],Dn=[],Ht=0,Lt=An.length,je=Hi(kr),$e=Hi(An);je.forEach(function(Jt){for(var ar=!1,hr=Ht;hr1});return Bt.forEach(function(Jt){Dn=Dn.filter(function(ar){var hr=ar.key,Gt=ar.status;return hr!==Jt||Gt!==Fn}),Dn.forEach(function(ar){ar.key===Jt&&(ar.status=ko)})}),Dn}var Fo=["component","children","onVisibleChanged","onAllRemoved"],xt=["status"],it=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearPrepare","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];function kt(kr){var An=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Bo,Dn=function(Ht){(0,ct.Z)(je,Ht);var Lt=(0,Ve.Z)(je);function je(){var $e;(0,qe.Z)(this,je);for(var At=arguments.length,Bt=new Array(At),Jt=0;Jt5&&arguments[5]!==void 0?arguments[5]:!1,na=arguments.length>6?arguments[6]:void 0,$a=arguments.length>7?arguments[7]:void 0,Co=le.useMemo(function(){if((0,se.Z)(oo)==="object")return oo.clearIcon;if(io)return io},[oo,io]),wo=le.useMemo(function(){return!!(!Uo&&oo&&(wi.length||na)&&!($a==="combobox"&&na===""))},[oo,Uo,wi.length,na,$a]);return{allowClear:wo,clearIcon:le.createElement(ut,{className:"".concat(xn,"-clear"),onMouseDown:Vi,customizeIcon:Co},"\xD7")}},Rt=le.createContext(null);function gt(){return le.useContext(Rt)}function Ct(){var en=arguments.length>0&&arguments[0]!==void 0?arguments[0]:10,xn=le.useState(!1),Vi=(0,$.Z)(xn,2),wi=Vi[0],oo=Vi[1],io=le.useRef(null),Uo=function(){window.clearTimeout(io.current)};le.useEffect(function(){return Uo},[]);var na=function(Co,wo){Uo(),io.current=window.setTimeout(function(){oo(Co),wo&&wo()},en)};return[wi,na,Uo]}function tt(){var en=arguments.length>0&&arguments[0]!==void 0?arguments[0]:250,xn=le.useRef(null),Vi=le.useRef(null);le.useEffect(function(){return function(){window.clearTimeout(Vi.current)}},[]);function wi(oo){(oo||xn.current===null)&&(xn.current=oo),window.clearTimeout(Vi.current),Vi.current=window.setTimeout(function(){xn.current=null},en)}return[function(){return xn.current},wi]}function Ne(en,xn,Vi,wi){var oo=le.useRef(null);oo.current={open:xn,triggerOpen:Vi,customizedTrigger:wi},le.useEffect(function(){function io(Uo){var na;if(!((na=oo.current)!==null&&na!==void 0&&na.customizedTrigger)){var $a=Uo.target;$a.shadowRoot&&Uo.composed&&($a=Uo.composedPath()[0]||$a),oo.current.open&&en().filter(function(Co){return Co}).every(function(Co){return!Co.contains($a)&&Co!==$a})&&oo.current.triggerOpen(!1)}}return window.addEventListener("mousedown",io),function(){return window.removeEventListener("mousedown",io)}},[])}var bt=A(3286),et=A(28647),pt=["prefixCls","invalidate","item","renderItem","responsive","responsiveDisabled","registerSize","itemKey","className","style","children","display","order","component"],Ke=void 0;function ft(en,xn){var Vi=en.prefixCls,wi=en.invalidate,oo=en.item,io=en.renderItem,Uo=en.responsive,na=en.responsiveDisabled,$a=en.registerSize,Co=en.itemKey,wo=en.className,Pa=en.style,ss=en.children,si=en.display,Ms=en.order,Ns=en.component,Aa=Ns===void 0?"div":Ns,qs=(0,X.Z)(en,pt),Eu=Uo&&!si;function Cs(rc){$a(Co,rc)}le.useEffect(function(){return function(){Cs(null)}},[]);var su=io&&oo!==Ke?io(oo):ss,Vs;wi||(Vs={opacity:Eu?0:1,height:Eu?0:Ke,overflowY:Eu?"hidden":Ke,order:Uo?Ms:Ke,pointerEvents:Eu?"none":Ke,position:Eu?"absolute":Ke});var tl={};Eu&&(tl["aria-hidden"]=!0);var Xs=le.createElement(Aa,(0,R.Z)({className:we()(!wi&&Vi,wo),style:(0,p.Z)((0,p.Z)({},Vs),Pa)},tl,qs,{ref:xn}),su);return Uo&&(Xs=le.createElement(et.Z,{onResize:function(Ha){var Qs=Ha.offsetWidth;Cs(Qs)},disabled:na},Xs)),Xs}var wt=le.forwardRef(ft);wt.displayName="Item";var Se=wt,Ft=A(60402),mt=A(79161),ot=A(90571);function We(en){if(typeof MessageChannel=="undefined")(0,ot.Z)(en);else{var xn=new MessageChannel;xn.port1.onmessage=function(){return en()},xn.port2.postMessage(void 0)}}function Me(){var en=le.useRef(null),xn=function(wi){en.current||(en.current=[],We(function(){(0,mt.unstable_batchedUpdates)(function(){en.current.forEach(function(oo){oo()}),en.current=null})})),en.current.push(wi)};return xn}function st(en,xn){var Vi=le.useState(xn),wi=(0,$.Z)(Vi,2),oo=wi[0],io=wi[1],Uo=(0,Ft.Z)(function(na){en(function(){io(na)})});return[oo,Uo]}var Qe=le.createContext(null),dr=["component"],Kt=["className"],Yr=["className"],hn=function(xn,Vi){var wi=le.useContext(Qe);if(!wi){var oo=xn.component,io=oo===void 0?"div":oo,Uo=(0,X.Z)(xn,dr);return le.createElement(io,(0,R.Z)({},Uo,{ref:Vi}))}var na=wi.className,$a=(0,X.Z)(wi,Kt),Co=xn.className,wo=(0,X.Z)(xn,Yr);return le.createElement(Qe.Provider,{value:null},le.createElement(Se,(0,R.Z)({ref:Vi,className:we()(na,Co)},$a,wo)))},ln=le.forwardRef(hn);ln.displayName="RawItem";var oi=ln,Nn=["prefixCls","data","renderItem","renderRawItem","itemKey","itemWidth","ssr","style","className","maxCount","renderRest","renderRawRest","suffix","component","itemComponent","onVisibleChange"],$n="responsive",_i="invalidate";function Qn(en){return"+ ".concat(en.length," ...")}function Ji(en,xn){var Vi=en.prefixCls,wi=Vi===void 0?"rc-overflow":Vi,oo=en.data,io=oo===void 0?[]:oo,Uo=en.renderItem,na=en.renderRawItem,$a=en.itemKey,Co=en.itemWidth,wo=Co===void 0?10:Co,Pa=en.ssr,ss=en.style,si=en.className,Ms=en.maxCount,Ns=en.renderRest,Aa=en.renderRawRest,qs=en.suffix,Eu=en.component,Cs=Eu===void 0?"div":Eu,su=en.itemComponent,Vs=en.onVisibleChange,tl=(0,X.Z)(en,Nn),Xs=Pa==="full",rc=Me(),Ha=st(rc,null),Qs=(0,$.Z)(Ha,2),Uu=Qs[0],St=Qs[1],Zs=Uu||0,yu=st(rc,new Map),pl=(0,$.Z)(yu,2),Ku=pl[0],eu=pl[1],Qo=st(rc,0),ps=(0,$.Z)(Qo,2),xl=ps[0],Yl=ps[1],ul=st(rc,0),Ef=(0,$.Z)(ul,2),sf=Ef[0],Hf=Ef[1],Ul=st(rc,0),Lf=(0,$.Z)(Ul,2),Fc=Lf[0],Ol=Lf[1],_l=(0,le.useState)(null),cn=(0,$.Z)(_l,2),an=cn[0],Xn=cn[1],vi=(0,le.useState)(null),to=(0,$.Z)(vi,2),zo=to[0],Ia=to[1],Sa=le.useMemo(function(){return zo===null&&Xs?Number.MAX_SAFE_INTEGER:zo||0},[zo,Uu]),fa=(0,le.useState)(!1),cs=(0,$.Z)(fa,2),Ys=cs[0],mu=cs[1],Is="".concat(wi,"-item"),Sl=Math.max(xl,sf),wl=Ms===$n,vu=io.length&&wl,ml=Ms===_i,ll=vu||typeof Ms=="number"&&io.length>Ms,Fu=(0,le.useMemo)(function(){var wc=io;return vu?Uu===null&&Xs?wc=io:wc=io.slice(0,Math.min(io.length,Zs/wo)):typeof Ms=="number"&&(wc=io.slice(0,Ms)),wc},[io,wo,Uu,Ms,vu]),Bu=(0,le.useMemo)(function(){return vu?io.slice(Sa+1):io.slice(Fu.length)},[io,Fu,vu,Sa]),al=(0,le.useCallback)(function(wc,ac){var cl;return typeof $a=="function"?$a(wc):(cl=$a&&(wc==null?void 0:wc[$a]))!==null&&cl!==void 0?cl:ac},[$a]),Ac=(0,le.useCallback)(Uo||function(wc){return wc},[Uo]);function $l(wc,ac,cl){zo===wc&&(ac===void 0||ac===an)||(Ia(wc),cl||(mu(wcZs){$l(Us-1,wc-vl-Fc+sf);break}}qs&&Df(0)+Fc>Zs&&Xn(null)}},[Zs,Ku,sf,Fc,al,Fu]);var bu=Ys&&!!Bu.length,Ic={};an!==null&&vu&&(Ic={position:"absolute",left:an,top:0});var af={prefixCls:Is,responsive:vu,component:su,invalidate:ml},zf=na?function(wc,ac){var cl=al(wc,ac);return le.createElement(Qe.Provider,{key:cl,value:(0,p.Z)((0,p.Z)({},af),{},{order:ac,item:wc,itemKey:cl,registerSize:Gu,display:ac<=Sa})},na(wc,ac))}:function(wc,ac){var cl=al(wc,ac);return le.createElement(Se,(0,R.Z)({},af,{order:ac,key:cl,item:wc,renderItem:Ac,itemKey:cl,registerSize:Gu,display:ac<=Sa}))},tf,kf={order:bu?Sa:Number.MAX_SAFE_INTEGER,className:"".concat(Is,"-rest"),registerSize:Sf,display:bu};if(Aa)Aa&&(tf=le.createElement(Qe.Provider,{value:(0,p.Z)((0,p.Z)({},af),kf)},Aa(Bu)));else{var ff=Ns||Qn;tf=le.createElement(Se,(0,R.Z)({},af,kf),typeof ff=="function"?ff(Bu):ff)}var vf=le.createElement(Cs,(0,R.Z)({className:we()(!ml&&wi,si),style:ss,ref:xn},tl),Fu.map(zf),ll?tf:null,qs&&le.createElement(Se,(0,R.Z)({},af,{responsive:wl,responsiveDisabled:!vu,order:Sa,className:"".concat(Is,"-suffix"),registerSize:Cl,display:!0,style:Ic}),qs));return wl&&(vf=le.createElement(et.Z,{onResize:Yu,disabled:!vu},vf)),vf}var ni=le.forwardRef(Ji);ni.displayName="Overflow",ni.Item=oi,ni.RESPONSIVE=$n,ni.INVALIDATE=_i;var Ei=ni,xo=Ei,sn=function(xn,Vi){var wi,oo=xn.prefixCls,io=xn.id,Uo=xn.inputElement,na=xn.disabled,$a=xn.tabIndex,Co=xn.autoFocus,wo=xn.autoComplete,Pa=xn.editable,ss=xn.activeDescendantId,si=xn.value,Ms=xn.maxLength,Ns=xn.onKeyDown,Aa=xn.onMouseDown,qs=xn.onChange,Eu=xn.onPaste,Cs=xn.onCompositionStart,su=xn.onCompositionEnd,Vs=xn.open,tl=xn.attrs,Xs=Uo||le.createElement("input",null),rc=Xs,Ha=rc.ref,Qs=rc.props,Uu=Qs.onKeyDown,St=Qs.onChange,Zs=Qs.onMouseDown,yu=Qs.onCompositionStart,pl=Qs.onCompositionEnd,Ku=Qs.style;return(0,ce.Kp)(!("maxLength"in Xs.props),"Passing 'maxLength' to input element directly may not work because input in BaseSelect is controlled."),Xs=le.cloneElement(Xs,(0,p.Z)((0,p.Z)((0,p.Z)({type:"search"},Qs),{},{id:io,ref:(0,ct.sQ)(Vi,Ha),disabled:na,tabIndex:$a,autoComplete:wo||"off",autoFocus:Co,className:we()("".concat(oo,"-selection-search-input"),(wi=Xs)===null||wi===void 0||(wi=wi.props)===null||wi===void 0?void 0:wi.className),role:"combobox","aria-expanded":Vs||!1,"aria-haspopup":"listbox","aria-owns":"".concat(io,"_list"),"aria-autocomplete":"list","aria-controls":"".concat(io,"_list"),"aria-activedescendant":Vs?ss:void 0},tl),{},{value:Pa?si:"",maxLength:Ms,readOnly:!Pa,unselectable:Pa?null:"on",style:(0,p.Z)((0,p.Z)({},Ku),{},{opacity:Pa?null:0}),onKeyDown:function(Qo){Ns(Qo),Uu&&Uu(Qo)},onMouseDown:function(Qo){Aa(Qo),Zs&&Zs(Qo)},onChange:function(Qo){qs(Qo),St&&St(Qo)},onCompositionStart:function(Qo){Cs(Qo),yu&&yu(Qo)},onCompositionEnd:function(Qo){su(Qo),pl&&pl(Qo)},onPaste:Eu})),Xs},li=le.forwardRef(sn),En=li;function or(en){return Array.isArray(en)?en:en!==void 0?[en]:[]}var qi=typeof window!="undefined"&&window.document&&window.document.documentElement,Bo=qi;function Mo(en){return en!=null}function Wi(en){return!en&&en!==0}function Ii(en){return["string","number"].includes((0,se.Z)(en))}function ko(en){var xn=void 0;return en&&(Ii(en.title)?xn=en.title.toString():Ii(en.label)&&(xn=en.label.toString())),xn}function Fn(en,xn){Bo?le.useLayoutEffect(en,xn):le.useEffect(en,xn)}function zn(en){var xn;return(xn=en.key)!==null&&xn!==void 0?xn:en.value}var Un=function(xn){xn.preventDefault(),xn.stopPropagation()},Hi=function(xn){var Vi=xn.id,wi=xn.prefixCls,oo=xn.values,io=xn.open,Uo=xn.searchValue,na=xn.autoClearSearchValue,$a=xn.inputRef,Co=xn.placeholder,wo=xn.disabled,Pa=xn.mode,ss=xn.showSearch,si=xn.autoFocus,Ms=xn.autoComplete,Ns=xn.activeDescendantId,Aa=xn.tabIndex,qs=xn.removeIcon,Eu=xn.maxTagCount,Cs=xn.maxTagTextLength,su=xn.maxTagPlaceholder,Vs=su===void 0?function(Xn){return"+ ".concat(Xn.length," ...")}:su,tl=xn.tagRender,Xs=xn.onToggleOpen,rc=xn.onRemove,Ha=xn.onInputChange,Qs=xn.onInputPaste,Uu=xn.onInputKeyDown,St=xn.onInputMouseDown,Zs=xn.onInputCompositionStart,yu=xn.onInputCompositionEnd,pl=le.useRef(null),Ku=(0,le.useState)(0),eu=(0,$.Z)(Ku,2),Qo=eu[0],ps=eu[1],xl=(0,le.useState)(!1),Yl=(0,$.Z)(xl,2),ul=Yl[0],Ef=Yl[1],sf="".concat(wi,"-selection"),Hf=io||Pa==="multiple"&&na===!1||Pa==="tags"?Uo:"",Ul=Pa==="tags"||Pa==="multiple"&&na===!1||ss&&(io||ul);Fn(function(){ps(pl.current.scrollWidth)},[Hf]);var Lf=function(vi,to,zo,Ia,Sa){return le.createElement("span",{title:ko(vi),className:we()("".concat(sf,"-item"),(0,y.Z)({},"".concat(sf,"-item-disabled"),zo))},le.createElement("span",{className:"".concat(sf,"-item-content")},to),Ia&&le.createElement(ut,{className:"".concat(sf,"-item-remove"),onMouseDown:Un,onClick:Sa,customizeIcon:qs},"\xD7"))},Fc=function(vi,to,zo,Ia,Sa){var fa=function(Ys){Un(Ys),Xs(!io)};return le.createElement("span",{onMouseDown:fa},tl({label:to,value:vi,disabled:zo,closable:Ia,onClose:Sa}))},Ol=function(vi){var to=vi.disabled,zo=vi.label,Ia=vi.value,Sa=!wo&&!to,fa=zo;if(typeof Cs=="number"&&(typeof zo=="string"||typeof zo=="number")){var cs=String(fa);cs.length>Cs&&(fa="".concat(cs.slice(0,Cs),"..."))}var Ys=function(Is){Is&&Is.stopPropagation(),rc(vi)};return typeof tl=="function"?Fc(Ia,fa,to,Sa,Ys):Lf(vi,fa,to,Sa,Ys)},_l=function(vi){var to=typeof Vs=="function"?Vs(vi):Vs;return Lf({title:to},to,!1)},cn=le.createElement("div",{className:"".concat(sf,"-search"),style:{width:Qo},onFocus:function(){Ef(!0)},onBlur:function(){Ef(!1)}},le.createElement(En,{ref:$a,open:io,prefixCls:wi,id:Vi,inputElement:null,disabled:wo,autoFocus:si,autoComplete:Ms,editable:Ul,activeDescendantId:Ns,value:Hf,onKeyDown:Uu,onMouseDown:St,onChange:Ha,onPaste:Qs,onCompositionStart:Zs,onCompositionEnd:yu,tabIndex:Aa,attrs:(0,bt.Z)(xn,!0)}),le.createElement("span",{ref:pl,className:"".concat(sf,"-search-mirror"),"aria-hidden":!0},Hf,"\xA0")),an=le.createElement(xo,{prefixCls:"".concat(sf,"-overflow"),data:oo,renderItem:Ol,renderRest:_l,suffix:cn,itemKey:zn,maxCount:Eu});return le.createElement(le.Fragment,null,an,!oo.length&&!Hf&&le.createElement("span",{className:"".concat(sf,"-placeholder")},Co))},Ki=Hi,Fo=function(xn){var Vi=xn.inputElement,wi=xn.prefixCls,oo=xn.id,io=xn.inputRef,Uo=xn.disabled,na=xn.autoFocus,$a=xn.autoComplete,Co=xn.activeDescendantId,wo=xn.mode,Pa=xn.open,ss=xn.values,si=xn.placeholder,Ms=xn.tabIndex,Ns=xn.showSearch,Aa=xn.searchValue,qs=xn.activeValue,Eu=xn.maxLength,Cs=xn.onInputKeyDown,su=xn.onInputMouseDown,Vs=xn.onInputChange,tl=xn.onInputPaste,Xs=xn.onInputCompositionStart,rc=xn.onInputCompositionEnd,Ha=xn.title,Qs=le.useState(!1),Uu=(0,$.Z)(Qs,2),St=Uu[0],Zs=Uu[1],yu=wo==="combobox",pl=yu||Ns,Ku=ss[0],eu=Aa||"";yu&&qs&&!St&&(eu=qs),le.useEffect(function(){yu&&Zs(!1)},[yu,qs]);var Qo=wo!=="combobox"&&!Pa&&!Ns?!1:!!eu,ps=Ha===void 0?ko(Ku):Ha,xl=le.useMemo(function(){return Ku?null:le.createElement("span",{className:"".concat(wi,"-selection-placeholder"),style:Qo?{visibility:"hidden"}:void 0},si)},[Ku,Qo,si,wi]);return le.createElement(le.Fragment,null,le.createElement("span",{className:"".concat(wi,"-selection-search")},le.createElement(En,{ref:io,prefixCls:wi,id:oo,open:Pa,inputElement:Vi,disabled:Uo,autoFocus:na,autoComplete:$a,editable:pl,activeDescendantId:Co,value:eu,onKeyDown:Cs,onMouseDown:su,onChange:function(ul){Zs(!0),Vs(ul)},onPaste:tl,onCompositionStart:Xs,onCompositionEnd:rc,tabIndex:Ms,attrs:(0,bt.Z)(xn,!0),maxLength:yu?Eu:void 0})),!yu&&Ku?le.createElement("span",{className:"".concat(wi,"-selection-item"),title:ps,style:Qo?{visibility:"hidden"}:void 0},Ku.label):null,xl)},xt=Fo;function it(en){return![Ge.Z.ESC,Ge.Z.SHIFT,Ge.Z.BACKSPACE,Ge.Z.TAB,Ge.Z.WIN_KEY,Ge.Z.ALT,Ge.Z.META,Ge.Z.WIN_KEY_RIGHT,Ge.Z.CTRL,Ge.Z.SEMICOLON,Ge.Z.EQUALS,Ge.Z.CAPS_LOCK,Ge.Z.CONTEXT_MENU,Ge.Z.F1,Ge.Z.F2,Ge.Z.F3,Ge.Z.F4,Ge.Z.F5,Ge.Z.F6,Ge.Z.F7,Ge.Z.F8,Ge.Z.F9,Ge.Z.F10,Ge.Z.F11,Ge.Z.F12].includes(en)}var kt=function(xn,Vi){var wi=(0,le.useRef)(null),oo=(0,le.useRef)(!1),io=xn.prefixCls,Uo=xn.open,na=xn.mode,$a=xn.showSearch,Co=xn.tokenWithEnter,wo=xn.autoClearSearchValue,Pa=xn.onSearch,ss=xn.onSearchSubmit,si=xn.onToggleOpen,Ms=xn.onInputKeyDown,Ns=xn.domRef;le.useImperativeHandle(Vi,function(){return{focus:function(){wi.current.focus()},blur:function(){wi.current.blur()}}});var Aa=tt(0),qs=(0,$.Z)(Aa,2),Eu=qs[0],Cs=qs[1],su=function(eu){var Qo=eu.which;(Qo===Ge.Z.UP||Qo===Ge.Z.DOWN)&&eu.preventDefault(),Ms&&Ms(eu),Qo===Ge.Z.ENTER&&na==="tags"&&!oo.current&&!Uo&&(ss==null||ss(eu.target.value)),it(Qo)&&si(!0)},Vs=function(){Cs(!0)},tl=(0,le.useRef)(null),Xs=function(eu){Pa(eu,!0,oo.current)!==!1&&si(!0)},rc=function(){oo.current=!0},Ha=function(eu){oo.current=!1,na!=="combobox"&&Xs(eu.target.value)},Qs=function(eu){var Qo=eu.target.value;if(Co&&tl.current&&/[\r\n]/.test(tl.current)){var ps=tl.current.replace(/[\r\n]+$/,"").replace(/\r\n/g," ").replace(/[\r\n]/g," ");Qo=Qo.replace(ps,tl.current)}tl.current=null,Xs(Qo)},Uu=function(eu){var Qo=eu.clipboardData,ps=Qo==null?void 0:Qo.getData("text");tl.current=ps||""},St=function(eu){var Qo=eu.target;if(Qo!==wi.current){var ps=document.body.style.msTouchAction!==void 0;ps?setTimeout(function(){wi.current.focus()}):wi.current.focus()}},Zs=function(eu){var Qo=Eu();eu.target!==wi.current&&!Qo&&na!=="combobox"&&eu.preventDefault(),(na!=="combobox"&&(!$a||!Qo)||!Uo)&&(Uo&&wo!==!1&&Pa("",!0,!1),si())},yu={inputRef:wi,onInputKeyDown:su,onInputMouseDown:Vs,onInputChange:Qs,onInputPaste:Uu,onInputCompositionStart:rc,onInputCompositionEnd:Ha},pl=na==="multiple"||na==="tags"?le.createElement(Ki,(0,R.Z)({},xn,yu)):le.createElement(xt,(0,R.Z)({},xn,yu));return le.createElement("div",{ref:Ns,className:"".concat(io,"-selector"),onClick:St,onMouseDown:Zs},pl)},ir=le.forwardRef(kt),Pr=ir,kr=A(35593),An=["prefixCls","disabled","visible","children","popupElement","animation","transitionName","dropdownStyle","dropdownClassName","direction","placement","builtinPlacements","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","getPopupContainer","empty","getTriggerDOMNode","onPopupVisibleChange","onPopupMouseEnter"],Dn=function(xn){var Vi=xn===!0?0:1;return{bottomLeft:{points:["tl","bl"],offset:[0,4],overflow:{adjustX:Vi,adjustY:1},htmlRegion:"scroll"},bottomRight:{points:["tr","br"],offset:[0,4],overflow:{adjustX:Vi,adjustY:1},htmlRegion:"scroll"},topLeft:{points:["bl","tl"],offset:[0,-4],overflow:{adjustX:Vi,adjustY:1},htmlRegion:"scroll"},topRight:{points:["br","tr"],offset:[0,-4],overflow:{adjustX:Vi,adjustY:1},htmlRegion:"scroll"}}},Ht=function(xn,Vi){var wi=xn.prefixCls,oo=xn.disabled,io=xn.visible,Uo=xn.children,na=xn.popupElement,$a=xn.animation,Co=xn.transitionName,wo=xn.dropdownStyle,Pa=xn.dropdownClassName,ss=xn.direction,si=ss===void 0?"ltr":ss,Ms=xn.placement,Ns=xn.builtinPlacements,Aa=xn.dropdownMatchSelectWidth,qs=xn.dropdownRender,Eu=xn.dropdownAlign,Cs=xn.getPopupContainer,su=xn.empty,Vs=xn.getTriggerDOMNode,tl=xn.onPopupVisibleChange,Xs=xn.onPopupMouseEnter,rc=(0,X.Z)(xn,An),Ha="".concat(wi,"-dropdown"),Qs=na;qs&&(Qs=qs(na));var Uu=le.useMemo(function(){return Ns||Dn(Aa)},[Ns,Aa]),St=$a?"".concat(Ha,"-").concat($a):Co,Zs=typeof Aa=="number",yu=le.useMemo(function(){return Zs?null:Aa===!1?"minWidth":"width"},[Aa,Zs]),pl=wo;Zs&&(pl=(0,p.Z)((0,p.Z)({},pl),{},{width:Aa}));var Ku=le.useRef(null);return le.useImperativeHandle(Vi,function(){return{getPopupElement:function(){return Ku.current}}}),le.createElement(kr.Z,(0,R.Z)({},rc,{showAction:tl?["click"]:[],hideAction:tl?["click"]:[],popupPlacement:Ms||(si==="rtl"?"bottomRight":"bottomLeft"),builtinPlacements:Uu,prefixCls:Ha,popupTransitionName:St,popup:le.createElement("div",{ref:Ku,onMouseEnter:Xs},Qs),stretch:yu,popupAlign:Eu,popupVisible:io,getPopupContainer:Cs,popupClassName:we()(Pa,(0,y.Z)({},"".concat(Ha,"-empty"),su)),popupStyle:pl,getTriggerDOMNode:Vs,onPopupVisibleChange:tl}),Uo)},Lt=le.forwardRef(Ht),je=Lt,$e=A(89514);function At(en,xn){var Vi=en.key,wi;return"value"in en&&(wi=en.value),Vi!=null?Vi:wi!==void 0?wi:"rc-index-key-".concat(xn)}function Bt(en,xn){var Vi=en||{},wi=Vi.label,oo=Vi.value,io=Vi.options,Uo=Vi.groupLabel,na=wi||(xn?"children":"label");return{label:na,value:oo||"value",options:io||"options",groupLabel:Uo||na}}function Jt(en){var xn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Vi=xn.fieldNames,wi=xn.childrenAsData,oo=[],io=Bt(Vi,!1),Uo=io.label,na=io.value,$a=io.options,Co=io.groupLabel;function wo(Pa,ss){Array.isArray(Pa)&&Pa.forEach(function(si){if(ss||!($a in si)){var Ms=si[na];oo.push({key:At(si,oo.length),groupOption:ss,data:si,label:si[Uo],value:Ms})}else{var Ns=si[Co];Ns===void 0&&wi&&(Ns=si.label),oo.push({key:At(si,oo.length),group:!0,data:si,label:Ns}),wo(si[$a],!0)}})}return wo(en,!1),oo}function ar(en){var xn=(0,p.Z)({},en);return"props"in xn||Object.defineProperty(xn,"props",{get:function(){return(0,ce.ZP)(!1,"Return type is option instead of Option instance. Please read value directly instead of reading from `props`."),xn}}),xn}var hr=function(xn,Vi,wi){if(!Vi||!Vi.length)return null;var oo=!1,io=function na($a,Co){var wo=(0,$e.Z)(Co),Pa=wo[0],ss=wo.slice(1);if(!Pa)return[$a];var si=$a.split(Pa);return oo=oo||si.length>1,si.reduce(function(Ms,Ns){return[].concat((0,V.Z)(Ms),(0,V.Z)(na(Ns,ss)))},[]).filter(Boolean)},Uo=io(xn,Vi);return oo?typeof wi!="undefined"?Uo.slice(0,wi):Uo:null},Gt=le.createContext(null),Tr=Gt,nn=["id","prefixCls","className","showSearch","tagRender","direction","omitDomProps","displayValues","onDisplayValuesChange","emptyOptions","notFoundContent","onClear","mode","disabled","loading","getInputElement","getRawInputElement","open","defaultOpen","onDropdownVisibleChange","activeValue","onActiveValueChange","activeDescendantId","searchValue","autoClearSearchValue","onSearch","onSearchSplit","tokenSeparators","allowClear","suffixIcon","clearIcon","OptionList","animation","transitionName","dropdownStyle","dropdownClassName","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","placement","builtinPlacements","getPopupContainer","showAction","onFocus","onBlur","onKeyUp","onKeyDown","onMouseDown"],bn=["value","onChange","removeIcon","placeholder","autoFocus","maxTagCount","maxTagTextLength","maxTagPlaceholder","choiceTransitionName","onInputKeyDown","onPopupScroll","tabIndex"],Bi=function(xn){return xn==="tags"||xn==="multiple"},on=le.forwardRef(function(en,xn){var Vi,wi,oo=en.id,io=en.prefixCls,Uo=en.className,na=en.showSearch,$a=en.tagRender,Co=en.direction,wo=en.omitDomProps,Pa=en.displayValues,ss=en.onDisplayValuesChange,si=en.emptyOptions,Ms=en.notFoundContent,Ns=Ms===void 0?"Not Found":Ms,Aa=en.onClear,qs=en.mode,Eu=en.disabled,Cs=en.loading,su=en.getInputElement,Vs=en.getRawInputElement,tl=en.open,Xs=en.defaultOpen,rc=en.onDropdownVisibleChange,Ha=en.activeValue,Qs=en.onActiveValueChange,Uu=en.activeDescendantId,St=en.searchValue,Zs=en.autoClearSearchValue,yu=en.onSearch,pl=en.onSearchSplit,Ku=en.tokenSeparators,eu=en.allowClear,Qo=en.suffixIcon,ps=en.clearIcon,xl=en.OptionList,Yl=en.animation,ul=en.transitionName,Ef=en.dropdownStyle,sf=en.dropdownClassName,Hf=en.dropdownMatchSelectWidth,Ul=en.dropdownRender,Lf=en.dropdownAlign,Fc=en.placement,Ol=en.builtinPlacements,_l=en.getPopupContainer,cn=en.showAction,an=cn===void 0?[]:cn,Xn=en.onFocus,vi=en.onBlur,to=en.onKeyUp,zo=en.onKeyDown,Ia=en.onMouseDown,Sa=(0,X.Z)(en,nn),fa=Bi(qs),cs=(na!==void 0?na:fa)||qs==="combobox",Ys=(0,p.Z)({},Sa);bn.forEach(function(ea){delete Ys[ea]}),wo==null||wo.forEach(function(ea){delete Ys[ea]});var mu=le.useState(!1),Is=(0,$.Z)(mu,2),Sl=Is[0],wl=Is[1];le.useEffect(function(){wl((0,qe.Z)())},[]);var vu=le.useRef(null),ml=le.useRef(null),ll=le.useRef(null),Fu=le.useRef(null),Bu=le.useRef(null),al=le.useRef(!1),Ac=Ct(),$l=(0,$.Z)(Ac,3),Yu=$l[0],Gu=$l[1],Sf=$l[2];le.useImperativeHandle(xn,function(){var ea,qo;return{focus:(ea=Fu.current)===null||ea===void 0?void 0:ea.focus,blur:(qo=Fu.current)===null||qo===void 0?void 0:qo.blur,scrollTo:function(bh){var pc;return(pc=Bu.current)===null||pc===void 0?void 0:pc.scrollTo(bh)}}});var Cl=le.useMemo(function(){var ea;if(qs!=="combobox")return St;var qo=(ea=Pa[0])===null||ea===void 0?void 0:ea.value;return typeof qo=="string"||typeof qo=="number"?String(qo):""},[St,qs,Pa]),Df=qs==="combobox"&&typeof su=="function"&&su()||null,bu=typeof Vs=="function"&&Vs(),Ic=(0,ct.x1)(ml,bu==null||(Vi=bu.props)===null||Vi===void 0?void 0:Vi.ref),af=le.useState(!1),zf=(0,$.Z)(af,2),tf=zf[0],kf=zf[1];(0,Ee.Z)(function(){kf(!0)},[]);var ff=(0,ae.Z)(!1,{defaultValue:Xs,value:tl}),vf=(0,$.Z)(ff,2),wc=vf[0],ac=vf[1],cl=tf?wc:!1,Us=!Ns&&si;(Eu||Us&&cl&&qs==="combobox")&&(cl=!1);var vl=Us?!1:cl,iu=le.useCallback(function(ea){var qo=ea!==void 0?ea:!cl;Eu||(ac(qo),cl!==qo&&(rc==null||rc(qo)))},[Eu,cl,ac,rc]),Ca=le.useMemo(function(){return(Ku||[]).some(function(ea){return[` +`,`\r +`].includes(ea)})},[Ku]),xa=le.useContext(Tr)||{},Dl=xa.maxCount,Gf=xa.rawValues,Li=function(qo,tu,bh){if(!((Gf==null?void 0:Gf.size)>=Dl)){var pc=!0,Wf=qo;Qs==null||Qs(null);var Tu=hr(qo,Ku,Dl&&Dl-Gf.size),Ih=bh?null:Tu;return qs!=="combobox"&&Ih&&(Wf="",pl==null||pl(Ih),iu(!1),pc=!1),yu&&Cl!==Wf&&yu(Wf,{source:tu?"typing":"effect"}),pc}},Fr=function(qo){!qo||!qo.trim()||yu(qo,{source:"submit"})};le.useEffect(function(){!cl&&!fa&&qs!=="combobox"&&Li("",!1,!1)},[cl]),le.useEffect(function(){wc&&Eu&&ac(!1),Eu&&!al.current&&Gu(!1)},[Eu]);var Hl=tt(),Ur=(0,$.Z)(Hl,2),ja=Ur[0],cu=Ur[1],fu=function(qo){var tu=ja(),bh=qo.which;if(bh===Ge.Z.ENTER&&(qs!=="combobox"&&qo.preventDefault(),cl||iu(!0)),cu(!!Cl),bh===Ge.Z.BACKSPACE&&!tu&&fa&&!Cl&&Pa.length){for(var pc=(0,V.Z)(Pa),Wf=null,Tu=pc.length-1;Tu>=0;Tu-=1){var Ih=pc[Tu];if(!Ih.disabled){pc.splice(Tu,1),Wf=Ih;break}}Wf&&ss(pc,{type:"remove",values:[Wf]})}for(var Bl=arguments.length,Xf=new Array(Bl>1?Bl-1:0),fh=1;fh1?tu-1:0),pc=1;pc1?Tu-1:0),Bl=1;Bl0&&arguments[0]!==void 0?arguments[0]:!1;wo();var Ms=function(){na.current.forEach(function(Aa,qs){if(Aa&&Aa.offsetParent){var Eu=(0,fo.Z)(Aa),Cs=Eu.offsetHeight;$a.current.get(qs)!==Cs&&$a.current.set(qs,Eu.offsetHeight)}}),Uo(function(Aa){return Aa+1})};si?Ms():Co.current=(0,ot.Z)(Ms)}function ss(si,Ms){var Ns=en(si),Aa=na.current.get(Ns);Ms?(na.current.set(Ns,Ms),Pa()):na.current.delete(Ns),!Aa!=!Ms&&(Ms?xn==null||xn(si):Vi==null||Vi(si))}return(0,le.useEffect)(function(){return wo},[]),[ss,Pa,$a.current,io]}var gi=A(33401),ol=10;function ks(en,xn,Vi,wi,oo,io,Uo,na){var $a=le.useRef(),Co=le.useState(null),wo=(0,$.Z)(Co,2),Pa=wo[0],ss=wo[1];return(0,Ee.Z)(function(){if(Pa&&Pa.times=0;yu-=1){var pl=oo(xn[yu]),Ku=Vi.get(pl);if(Ku===void 0){Eu=!0;break}if(Zs-=Ku,Zs<=0)break}switch(Vs){case"top":su=Xs-Aa;break;case"bottom":su=rc-qs+Aa;break;default:{var eu=en.current.scrollTop,Qo=eu+qs;XsQo&&(Cs="bottom")}}su!==null&&Uo(su),su!==Pa.lastTop&&(Eu=!0)}Eu&&ss((0,p.Z)((0,p.Z)({},Pa),{},{times:Pa.times+1,targetAlign:Cs,lastTop:su}))}},[Pa,en.current]),function(si){if(si==null){na();return}if(ot.Z.cancel($a.current),typeof si=="number")Uo(si);else if(si&&(0,se.Z)(si)==="object"){var Ms,Ns=si.align;"index"in si?Ms=si.index:Ms=xn.findIndex(function(Eu){return oo(Eu)===si.key});var Aa=si.offset,qs=Aa===void 0?0:Aa;ss({times:0,index:Ms,offset:qs,originAlign:Ns})}}}function as(en,xn,Vi,wi){var oo=Vi-en,io=xn-Vi,Uo=Math.min(oo,io)*2;if(wi<=Uo){var na=Math.floor(wi/2);return wi%2?Vi+na+1:Vi-na}return oo>io?Vi-(wi-io):Vi+(wi-oo)}function _s(en,xn,Vi){var wi=en.length,oo=xn.length,io,Uo;if(wi===0&&oo===0)return null;wi1&&arguments[1]!==void 0?arguments[1]:!1,$a=Uo<0&&io.current.top||Uo>0&&io.current.bottom;return na&&$a?(clearTimeout(wi.current),Vi.current=!1):(!$a||Vi.current)&&oo(),!Vi.current&&$a}};function Fa(en,xn,Vi,wi,oo){var io=(0,le.useRef)(0),Uo=(0,le.useRef)(null),na=(0,le.useRef)(null),$a=(0,le.useRef)(!1),Co=Ju(xn,Vi);function wo(Aa,qs){ot.Z.cancel(Uo.current),io.current+=qs,na.current=qs,!Co(qs)&&(hs||Aa.preventDefault(),Uo.current=(0,ot.Z)(function(){var Eu=$a.current?10:1;oo(io.current*Eu),io.current=0}))}function Pa(Aa,qs){oo(qs,!0),hs||Aa.preventDefault()}var ss=(0,le.useRef)(null),si=(0,le.useRef)(null);function Ms(Aa){if(en){ot.Z.cancel(si.current),si.current=(0,ot.Z)(function(){ss.current=null},2);var qs=Aa.deltaX,Eu=Aa.deltaY,Cs=Aa.shiftKey,su=qs,Vs=Eu;(ss.current==="sx"||!ss.current&&Cs&&Eu&&!qs)&&(su=Eu,Vs=0,ss.current="sx");var tl=Math.abs(su),Xs=Math.abs(Vs);ss.current===null&&(ss.current=wi&&tl>Xs?"x":"y"),ss.current==="y"?wo(Aa,Vs):Pa(Aa,su)}}function Ns(Aa){en&&($a.current=Aa.detail===na.current)}return[Ms,Ns]}var dc=14/15;function el(en,xn,Vi){var wi=(0,le.useRef)(!1),oo=(0,le.useRef)(0),io=(0,le.useRef)(null),Uo=(0,le.useRef)(null),na,$a=function(ss){if(wi.current){var si=Math.ceil(ss.touches[0].pageY),Ms=oo.current-si;oo.current=si,Vi(Ms)&&ss.preventDefault(),clearInterval(Uo.current),Uo.current=setInterval(function(){Ms*=dc,(!Vi(Ms,!0)||Math.abs(Ms)<=.1)&&clearInterval(Uo.current)},16)}},Co=function(){wi.current=!1,na()},wo=function(ss){na(),ss.touches.length===1&&!wi.current&&(wi.current=!0,oo.current=Math.ceil(ss.touches[0].pageY),io.current=ss.target,io.current.addEventListener("touchmove",$a),io.current.addEventListener("touchend",Co))};na=function(){io.current&&(io.current.removeEventListener("touchmove",$a),io.current.removeEventListener("touchend",Co))},(0,Ee.Z)(function(){return en&&xn.current.addEventListener("touchstart",wo),function(){var Pa;(Pa=xn.current)===null||Pa===void 0||Pa.removeEventListener("touchstart",wo),na(),clearInterval(Uo.current)}},[en])}var fl=20;function As(){var en=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,xn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,Vi=en/xn*en;return isNaN(Vi)&&(Vi=0),Vi=Math.max(Vi,fl),Math.floor(Vi)}function Rl(en,xn,Vi,wi){var oo=le.useMemo(function(){return[new Map,[]]},[en,Vi.id,wi]),io=(0,$.Z)(oo,2),Uo=io[0],na=io[1],$a=function(wo){var Pa=arguments.length>1&&arguments[1]!==void 0?arguments[1]:wo,ss=Uo.get(wo),si=Uo.get(Pa);if(ss===void 0||si===void 0)for(var Ms=en.length,Ns=na.length;Nsio||!!Ns),Uu=Ms==="rtl",St=we()(wi,(0,y.Z)({},"".concat(wi,"-rtl"),Uu),oo),Zs=wo||_c,yu=(0,le.useRef)(),pl=(0,le.useRef)(),Ku=(0,le.useState)(0),eu=(0,$.Z)(Ku,2),Qo=eu[0],ps=eu[1],xl=(0,le.useState)(0),Yl=(0,$.Z)(xl,2),ul=Yl[0],Ef=Yl[1],sf=(0,le.useState)(!1),Hf=(0,$.Z)(sf,2),Ul=Hf[0],Lf=Hf[1],Fc=function(){Lf(!0)},Ol=function(){Lf(!1)},_l=le.useCallback(function(cu){return typeof ss=="function"?ss(cu):cu==null?void 0:cu[ss]},[ss]),cn={getKey:_l};function an(cu){ps(function(fu){var nc;typeof cu=="function"?nc=cu(fu):nc=cu;var Su=Ic(nc);return yu.current.scrollTop=Su,Su})}var Xn=(0,le.useRef)({start:0,end:Zs.length}),vi=(0,le.useRef)(),to=Ks(Zs,_l),zo=(0,$.Z)(to,1),Ia=zo[0];vi.current=Ia;var Sa=On(_l,null,null),fa=(0,$.Z)(Sa,4),cs=fa[0],Ys=fa[1],mu=fa[2],Is=fa[3],Sl=le.useMemo(function(){if(!Ha)return{scrollHeight:void 0,start:0,end:Zs.length-1,offset:void 0};if(!Qs){var cu;return{scrollHeight:((cu=pl.current)===null||cu===void 0?void 0:cu.offsetHeight)||0,start:0,end:Zs.length-1,offset:void 0}}for(var fu=0,nc,Su,Wu,Hc=Zs.length,Lc=0;Lc=Qo&&nc===void 0&&(nc=Lc,Su=fu),kl>Qo+io&&Wu===void 0&&(Wu=Lc),fu=kl}return nc===void 0&&(nc=0,Su=0,Wu=Math.ceil(io/Uo)),Wu===void 0&&(Wu=Zs.length-1),Wu=Math.min(Wu+1,Zs.length-1),{scrollHeight:fu,start:nc,end:Wu,offset:Su}},[Qs,Ha,Qo,Zs,Is,io]),wl=Sl.scrollHeight,vu=Sl.start,ml=Sl.end,ll=Sl.offset;Xn.current.start=vu,Xn.current.end=ml;var Fu=le.useState({width:0,height:io}),Bu=(0,$.Z)(Fu,2),al=Bu[0],Ac=Bu[1],$l=function(fu){Ac({width:fu.width||fu.offsetWidth,height:fu.height||fu.offsetHeight})},Yu=(0,le.useRef)(),Gu=(0,le.useRef)(),Sf=le.useMemo(function(){return As(al.width,Ns)},[al.width,Ns]),Cl=le.useMemo(function(){return As(al.height,wl)},[al.height,wl]),Df=wl-io,bu=(0,le.useRef)(Df);bu.current=Df;function Ic(cu){var fu=cu;return Number.isNaN(bu.current)||(fu=Math.min(fu,bu.current)),fu=Math.max(fu,0),fu}var af=Qo<=0,zf=Qo>=Df,tf=Ju(af,zf),kf=function(){return{x:Uu?-ul:ul,y:Qo}},ff=(0,le.useRef)(kf()),vf=(0,gi.zX)(function(){if(Cs){var cu=kf();(ff.current.x!==cu.x||ff.current.y!==cu.y)&&(Cs(cu),ff.current=cu)}});function wc(cu,fu){var nc=cu;fu?((0,mt.flushSync)(function(){Ef(nc)}),vf()):an(nc)}function ac(cu){var fu=cu.currentTarget.scrollTop;fu!==Qo&&an(fu),Eu==null||Eu(cu),vf()}var cl=function(fu){var nc=fu,Su=Ns-al.width;return nc=Math.max(nc,0),nc=Math.min(nc,Su),nc},Us=(0,gi.zX)(function(cu,fu){fu?((0,mt.flushSync)(function(){Ef(function(nc){var Su=nc+(Uu?-cu:cu);return cl(Su)})}),vf()):an(function(nc){var Su=nc+cu;return Su})}),vl=Fa(Ha,af,zf,!!Ns,Us),iu=(0,$.Z)(vl,2),Ca=iu[0],xa=iu[1];el(Ha,yu,function(cu,fu){return tf(cu,fu)?!1:(Ca({preventDefault:function(){},deltaY:cu}),!0)}),(0,Ee.Z)(function(){function cu(nc){Ha&&nc.preventDefault()}var fu=yu.current;return fu.addEventListener("wheel",Ca),fu.addEventListener("DOMMouseScroll",xa),fu.addEventListener("MozMousePixelScroll",cu),function(){fu.removeEventListener("wheel",Ca),fu.removeEventListener("DOMMouseScroll",xa),fu.removeEventListener("MozMousePixelScroll",cu)}},[Ha]),(0,Ee.Z)(function(){Ns&&Ef(function(cu){return cl(cu)})},[al.width,Ns]);var Dl=function(){var fu,nc;(fu=Yu.current)===null||fu===void 0||fu.delayHidden(),(nc=Gu.current)===null||nc===void 0||nc.delayHidden()},Gf=ks(yu,Zs,mu,Uo,_l,function(){return Ys(!0)},an,Dl);le.useImperativeHandle(xn,function(){return{getScrollInfo:kf,scrollTo:function(fu){function nc(Su){return Su&&(0,se.Z)(Su)==="object"&&("left"in Su||"top"in Su)}nc(fu)?(fu.left!==void 0&&Ef(cl(fu.left)),Gf(fu.top)):Gf(fu)}}}),(0,Ee.Z)(function(){if(su){var cu=Zs.slice(vu,ml+1);su(cu,Zs)}},[vu,ml,Zs]);var Li=Rl(Zs,_l,mu,Uo),Fr=tl==null?void 0:tl({start:vu,end:ml,virtual:Qs,offsetX:ul,offsetY:ll,rtl:Uu,getSize:Li}),Hl=Nr(Zs,vu,ml,Ns,cs,Pa,cn),Ur=null;io&&(Ur=(0,p.Z)((0,y.Z)({},$a?"height":"maxHeight",io),lu),Ha&&(Ur.overflowY="hidden",Ns&&(Ur.overflowX="hidden"),Ul&&(Ur.pointerEvents="none")));var ja={};return Uu&&(ja.dir="rtl"),le.createElement("div",(0,R.Z)({style:(0,p.Z)((0,p.Z)({},Co),{},{position:"relative"}),className:St},ja,rc),le.createElement(et.Z,{onResize:$l},le.createElement(qs,{className:"".concat(wi,"-holder"),style:Ur,ref:yu,onScroll:ac,onMouseEnter:Dl},le.createElement(eo,{prefixCls:wi,height:wl,offsetX:ul,offsetY:ll,scrollWidth:Ns,onInnerResize:Ys,ref:pl,innerProps:Vs,rtl:Uu,extra:Fr},Hl))),Qs&&wl>io&&le.createElement(Do,{ref:Yu,prefixCls:wi,scrollOffset:Qo,scrollRange:wl,rtl:Uu,onScroll:wc,onStartMove:Fc,onStopMove:Ol,spinSize:Cl,containerSize:al.height,style:Xs==null?void 0:Xs.verticalScrollBar,thumbStyle:Xs==null?void 0:Xs.verticalScrollBarThumb}),Qs&&Ns>al.width&&le.createElement(Do,{ref:Gu,prefixCls:wi,scrollOffset:ul,scrollRange:Ns,rtl:Uu,onScroll:wc,onStartMove:Fc,onStopMove:Ol,spinSize:Sf,containerSize:al.width,horizontal:!0,style:Xs==null?void 0:Xs.horizontalScrollBar,thumbStyle:Xs==null?void 0:Xs.horizontalScrollBarThumb}))}var Wr=le.forwardRef(Pn);Wr.displayName="List";var Ci=Wr,at=Ci;function Vt(){return/(mac\sos|macintosh)/i.test(navigator.appVersion)}var gr=["disabled","title","children","style","className"];function gn(en){return typeof en=="string"||typeof en=="number"}var un=function(xn,Vi){var wi=gt(),oo=wi.prefixCls,io=wi.id,Uo=wi.open,na=wi.multiple,$a=wi.mode,Co=wi.searchValue,wo=wi.toggleOpen,Pa=wi.notFoundContent,ss=wi.onPopupScroll,si=le.useContext(Tr),Ms=si.maxCount,Ns=si.flattenOptions,Aa=si.onActiveValue,qs=si.defaultActiveFirstOption,Eu=si.onSelect,Cs=si.menuItemSelectedIcon,su=si.rawValues,Vs=si.fieldNames,tl=si.virtual,Xs=si.direction,rc=si.listHeight,Ha=si.listItemHeight,Qs=si.optionRender,Uu="".concat(oo,"-item"),St=(0,zi.Z)(function(){return Ns},[Uo,Ns],function(_l,cn){return cn[0]&&_l[1]!==cn[1]}),Zs=le.useRef(null),yu=le.useMemo(function(){return na&&typeof Ms!="undefined"&&(su==null?void 0:su.size)>=Ms},[na,Ms,su==null?void 0:su.size]),pl=function(cn){cn.preventDefault()},Ku=function(cn){var an;(an=Zs.current)===null||an===void 0||an.scrollTo(typeof cn=="number"?{index:cn}:cn)},eu=function(cn){for(var an=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,Xn=St.length,vi=0;vi1&&arguments[1]!==void 0?arguments[1]:!1;Yl(cn);var Xn={source:an?"keyboard":"mouse"},vi=St[cn];if(!vi){Aa(null,-1,Xn);return}Aa(vi.value,cn,Xn)};(0,le.useEffect)(function(){ul(qs!==!1?eu(0):-1)},[St.length,Co]);var Ef=le.useCallback(function(_l){return su.has(_l)&&$a!=="combobox"},[$a,(0,V.Z)(su).toString(),su.size]);(0,le.useEffect)(function(){var _l=setTimeout(function(){if(!na&&Uo&&su.size===1){var an=Array.from(su)[0],Xn=St.findIndex(function(vi){var to=vi.data;return to.value===an});Xn!==-1&&(ul(Xn),Ku(Xn))}});if(Uo){var cn;(cn=Zs.current)===null||cn===void 0||cn.scrollTo(void 0)}return function(){return clearTimeout(_l)}},[Uo,Co]);var sf=function(cn){cn!==void 0&&Eu(cn,{selected:!su.has(cn)}),na||wo(!1)};if(le.useImperativeHandle(Vi,function(){return{onKeyDown:function(cn){var an=cn.which,Xn=cn.ctrlKey;switch(an){case Ge.Z.N:case Ge.Z.P:case Ge.Z.UP:case Ge.Z.DOWN:{var vi=0;if(an===Ge.Z.UP?vi=-1:an===Ge.Z.DOWN?vi=1:Vt()&&Xn&&(an===Ge.Z.N?vi=1:an===Ge.Z.P&&(vi=-1)),vi!==0){var to=eu(xl+vi,vi);Ku(to),ul(to,!0)}break}case Ge.Z.ENTER:{var zo,Ia=St[xl];Ia&&!(Ia!=null&&(zo=Ia.data)!==null&&zo!==void 0&&zo.disabled)&&!yu?sf(Ia.value):sf(void 0),Uo&&cn.preventDefault();break}case Ge.Z.ESC:wo(!1),Uo&&cn.stopPropagation()}},onKeyUp:function(){},scrollTo:function(cn){Ku(cn)}}}),St.length===0)return le.createElement("div",{role:"listbox",id:"".concat(io,"_list"),className:"".concat(Uu,"-empty"),onMouseDown:pl},Pa);var Hf=Object.keys(Vs).map(function(_l){return Vs[_l]}),Ul=function(cn){return cn.label};function Lf(_l,cn){var an=_l.group;return{role:an?"presentation":"option",id:"".concat(io,"_list_").concat(cn)}}var Fc=function(cn){var an=St[cn];if(!an)return null;var Xn=an.data||{},vi=Xn.value,to=an.group,zo=(0,bt.Z)(Xn,!0),Ia=Ul(an);return an?le.createElement("div",(0,R.Z)({"aria-label":typeof Ia=="string"&&!to?Ia:null},zo,{key:cn},Lf(an,cn),{"aria-selected":Ef(vi)}),vi):null},Ol={role:"listbox",id:"".concat(io,"_list")};return le.createElement(le.Fragment,null,tl&&le.createElement("div",(0,R.Z)({},Ol,{style:{height:0,width:0,overflow:"hidden"}}),Fc(xl-1),Fc(xl),Fc(xl+1)),le.createElement(at,{itemKey:"key",ref:Zs,data:St,height:rc,itemHeight:Ha,fullHeight:!1,onMouseDown:pl,onScroll:ss,virtual:tl,direction:Xs,innerProps:tl?null:Ol},function(_l,cn){var an,Xn=_l.group,vi=_l.groupOption,to=_l.data,zo=_l.label,Ia=_l.value,Sa=to.key;if(Xn){var fa,cs=(fa=to.title)!==null&&fa!==void 0?fa:gn(zo)?zo.toString():void 0;return le.createElement("div",{className:we()(Uu,"".concat(Uu,"-group")),title:cs},zo!==void 0?zo:Sa)}var Ys=to.disabled,mu=to.title,Is=to.children,Sl=to.style,wl=to.className,vu=(0,X.Z)(to,gr),ml=(0,Gi.Z)(vu,Hf),ll=Ef(Ia),Fu=Ys||!ll&&yu,Bu="".concat(Uu,"-option"),al=we()(Uu,Bu,wl,(an={},(0,y.Z)(an,"".concat(Bu,"-grouped"),vi),(0,y.Z)(an,"".concat(Bu,"-active"),xl===cn&&!Fu),(0,y.Z)(an,"".concat(Bu,"-disabled"),Fu),(0,y.Z)(an,"".concat(Bu,"-selected"),ll),an)),Ac=Ul(_l),$l=!Cs||typeof Cs=="function"||ll,Yu=typeof Ac=="number"?Ac:Ac||Ia,Gu=gn(Yu)?Yu.toString():void 0;return mu!==void 0&&(Gu=mu),le.createElement("div",(0,R.Z)({},(0,bt.Z)(ml),tl?{}:Lf(_l,cn),{"aria-selected":ll,className:al,title:Gu,onMouseMove:function(){xl===cn||Fu||ul(cn)},onClick:function(){Fu||sf(Ia)},style:Sl}),le.createElement("div",{className:"".concat(Bu,"-content")},typeof Qs=="function"?Qs(_l,{index:cn}):Yu),le.isValidElement(Cs)||ll,$l&&le.createElement(ut,{className:"".concat(Uu,"-option-state"),customizeIcon:Cs,customizeIconProps:{value:Ia,disabled:Fu,isSelected:ll}},ll?"\u2713":null))}))},Zi=le.forwardRef(un),ho=Zi,Na=function(en,xn){var Vi=le.useRef({values:new Map,options:new Map}),wi=le.useMemo(function(){var io=Vi.current,Uo=io.values,na=io.options,$a=en.map(function(Pa){if(Pa.label===void 0){var ss;return(0,p.Z)((0,p.Z)({},Pa),{},{label:(ss=Uo.get(Pa.value))===null||ss===void 0?void 0:ss.label})}return Pa}),Co=new Map,wo=new Map;return $a.forEach(function(Pa){Co.set(Pa.value,Pa),wo.set(Pa.value,xn.get(Pa.value)||na.get(Pa.value))}),Vi.current.values=Co,Vi.current.options=wo,$a},[en,xn]),oo=le.useCallback(function(io){return xn.get(io)||Vi.current.options.get(io)},[xn]);return[wi,oo]};function mn(en,xn){return or(en).join("").toUpperCase().includes(xn)}var Lr=function(en,xn,Vi,wi,oo){return le.useMemo(function(){if(!Vi||wi===!1)return en;var io=xn.options,Uo=xn.label,na=xn.value,$a=[],Co=typeof wi=="function",wo=Vi.toUpperCase(),Pa=Co?wi:function(si,Ms){return oo?mn(Ms[oo],wo):Ms[io]?mn(Ms[Uo!=="children"?Uo:"label"],wo):mn(Ms[na],wo)},ss=Co?function(si){return ar(si)}:function(si){return si};return en.forEach(function(si){if(si[io]){var Ms=Pa(Vi,ss(si));if(Ms)$a.push(si);else{var Ns=si[io].filter(function(Aa){return Pa(Vi,ss(Aa))});Ns.length&&$a.push((0,p.Z)((0,p.Z)({},si),{},(0,y.Z)({},io,Ns)))}return}Pa(Vi,ss(si))&&$a.push(si)}),$a},[en,wi,oo,Vi,xn])},yr=A(42871),Mr=0,Zr=(0,yr.Z)();function Vn(){var en;return Zr?(en=Mr,Mr+=1):en="TEST_OR_SSR",en}function In(en){var xn=le.useState(),Vi=(0,$.Z)(xn,2),wi=Vi[0],oo=Vi[1];return le.useEffect(function(){oo("rc_select_".concat(Vn()))},[]),en||wi}var Kn=A(45659),Mi=["children","value"],so=["children"];function ro(en){var xn=en,Vi=xn.key,wi=xn.props,oo=wi.children,io=wi.value,Uo=(0,X.Z)(wi,Mi);return(0,p.Z)({key:Vi,value:io!==void 0?io:Vi,children:oo},Uo)}function Ho(en){var xn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return(0,Kn.Z)(en).map(function(Vi,wi){if(!le.isValidElement(Vi)||!Vi.type)return null;var oo=Vi,io=oo.type.isSelectOptGroup,Uo=oo.key,na=oo.props,$a=na.children,Co=(0,X.Z)(na,so);return xn||!io?ro(Vi):(0,p.Z)((0,p.Z)({key:"__RC_SELECT_GRP__".concat(Uo===null?wi:Uo,"__"),label:Uo},Co),{},{options:Ho($a)})}).filter(function(Vi){return Vi})}var ya=function(xn,Vi,wi,oo,io){return le.useMemo(function(){var Uo=xn,na=!xn;na&&(Uo=Ho(Vi));var $a=new Map,Co=new Map,wo=function(si,Ms,Ns){Ns&&typeof Ns=="string"&&si.set(Ms[Ns],Ms)},Pa=function ss(si){for(var Ms=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,Ns=0;Ns1&&arguments[1]!==void 0?arguments[1]:!1,Uo=0;Uo2&&arguments[2]!==void 0?arguments[2]:{},Ca=iu.source,xa=Ca===void 0?"keyboard":Ca;af(vl),Uo&&wi==="combobox"&&Us!==null&&xa==="keyboard"&&Cl(String(Us))},[Uo,wi]),kf=function(vl,iu,Ca){var xa=function(){var nc,Su=Sl(vl);return[Qo?{label:Su==null?void 0:Su[Ul.label],value:vl,key:(nc=Su==null?void 0:Su.key)!==null&&nc!==void 0?nc:vl}:vl,ar(Su)]};if(iu&&si){var Dl=xa(),Gf=(0,$.Z)(Dl,2),Li=Gf[0],Fr=Gf[1];si(Li,Fr)}else if(!iu&&Ms&&Ca!=="clear"){var Hl=xa(),Ur=(0,$.Z)(Hl,2),ja=Ur[0],cu=Ur[1];Ms(ja,cu)}},ff=lo(function(Us,vl){var iu,Ca=Ef?vl.selected:!0;Ca?iu=Ef?[].concat((0,V.Z)(Is),[Us]):[Us]:iu=Is.filter(function(xa){return xa.value!==Us}),$l(iu),kf(Us,Ca),wi==="combobox"?Cl(""):(!Bi||ss)&&(_l(""),Cl(""))}),vf=function(vl,iu){$l(vl);var Ca=iu.type,xa=iu.values;(Ca==="remove"||Ca==="clear")&&xa.forEach(function(Dl){kf(Dl.value,!1,Ca)})},wc=function(vl,iu){if(_l(vl),Cl(null),iu.source==="submit"){var Ca=(vl||"").trim();if(Ca){var xa=Array.from(new Set([].concat((0,V.Z)(vu),[Ca])));$l(xa),kf(Ca,!0),_l("")}return}iu.source!=="blur"&&(wi==="combobox"&&$l(vl),wo==null||wo(vl))},ac=function(vl){var iu=vl;wi!=="tags"&&(iu=vl.map(function(xa){var Dl=Xn.get(xa);return Dl==null?void 0:Dl.value}).filter(function(xa){return xa!==void 0}));var Ca=Array.from(new Set([].concat((0,V.Z)(vu),(0,V.Z)(iu))));$l(Ca),Ca.forEach(function(xa){kf(xa,!0)})},cl=le.useMemo(function(){var Us=Qs!==!1&&Aa!==!1;return(0,p.Z)((0,p.Z)({},cn),{},{flattenOptions:Ac,onActiveValue:tf,defaultActiveFirstOption:zf,onSelect:ff,menuItemSelectedIcon:Ha,rawValues:vu,fieldNames:Ul,virtual:Us,direction:Uu,listHeight:Zs,listItemHeight:pl,childrenAsData:sf,maxCount:xl,optionRender:tl})},[xl,cn,Ac,tf,zf,ff,Ha,vu,Ul,Qs,Aa,Uu,Zs,pl,sf,tl]);return le.createElement(Tr.Provider,{value:cl},le.createElement(dn,(0,R.Z)({},Yl,{id:ul,prefixCls:io,ref:xn,omitDomProps:ns,mode:wi,displayValues:wl,onDisplayValuesChange:vf,direction:Uu,searchValue:Ol,onSearch:wc,autoClearSearchValue:ss,onSearchSplit:ac,dropdownMatchSelectWidth:Aa,OptionList:ho,emptyOptions:!Ac.length,activeValue:Sf,activeDescendantId:"".concat(ul,"_list_").concat(Ic)})))}),Js=bs;Js.Option=di,Js.OptGroup=Wn;var Hu=Js,Of=Hu},45659:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return y}});var R=A(77617),V=A(92888);function y(p){var $=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},X=[];return R.Children.forEach(p,function(se){se==null&&!$.keepEmpty||(Array.isArray(se)?X=X.concat(y(se)):(0,V.isFragment)(se)&&se.props?X=X.concat(y(se.props.children,$)):X.push(se))}),X}},42871:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return R}});function R(){return!!(typeof window!="undefined"&&window.document&&window.document.createElement)}},99569:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return R}});function R(V,y){if(!V)return!1;if(V.contains)return V.contains(y);for(var p=y;p;){if(p===V)return!0;p=p.parentNode}return!1}},75966:function(Ye,ye,A){"use strict";A.d(ye,{hq:function(){return ct},jL:function(){return Ee}});var R=A(42871),V=A(99569),y="data-rc-order",p="data-rc-priority",$="rc-util-key",X=new Map;function se(){var Ve=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},ut=Ve.mark;return ut?ut.startsWith("data-")?ut:"data-".concat(ut):$}function ae(Ve){if(Ve.attachTo)return Ve.attachTo;var ut=document.querySelector("head");return ut||document.body}function ce(Ve){return Ve==="queue"?"prependQueue":Ve?"prepend":"append"}function le(Ve){return Array.from((X.get(Ve)||Ve).children).filter(function(ut){return ut.tagName==="STYLE"})}function De(Ve){var ut=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!(0,R.Z)())return null;var Xe=ut.csp,Rt=ut.prepend,gt=ut.priority,Ct=gt===void 0?0:gt,tt=ce(Rt),Ne=tt==="prependQueue",bt=document.createElement("style");bt.setAttribute(y,tt),Ne&&Ct&&bt.setAttribute(p,"".concat(Ct)),Xe!=null&&Xe.nonce&&(bt.nonce=Xe==null?void 0:Xe.nonce),bt.innerHTML=Ve;var et=ae(ut),pt=et.firstChild;if(Rt){if(Ne){var Ke=le(et).filter(function(ft){if(!["prepend","prependQueue"].includes(ft.getAttribute(y)))return!1;var wt=Number(ft.getAttribute(p)||0);return Ct>=wt});if(Ke.length)return et.insertBefore(bt,Ke[Ke.length-1].nextSibling),bt}et.insertBefore(bt,pt)}else et.appendChild(bt);return bt}function we(Ve){var ut=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Xe=ae(ut);return le(Xe).find(function(Rt){return Rt.getAttribute(se(ut))===Ve})}function Ee(Ve){var ut=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Xe=we(Ve,ut);if(Xe){var Rt=ae(ut);Rt.removeChild(Xe)}}function qe(Ve,ut){var Xe=X.get(Ve);if(!Xe||!(0,V.Z)(document,Xe)){var Rt=De("",ut),gt=Rt.parentNode;X.set(Ve,gt),Ve.removeChild(Rt)}}function Ge(){X.clear()}function ct(Ve,ut){var Xe=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},Rt=ae(Xe);qe(Rt,Xe);var gt=we(ut,Xe);if(gt){var Ct,tt;if((Ct=Xe.csp)!==null&&Ct!==void 0&&Ct.nonce&>.nonce!==((tt=Xe.csp)===null||tt===void 0?void 0:tt.nonce)){var Ne;gt.nonce=(Ne=Xe.csp)===null||Ne===void 0?void 0:Ne.nonce}return gt.innerHTML!==Ve&&(gt.innerHTML=Ve),gt}var bt=De(Ve,Xe);return bt.setAttribute(se(Xe),ut),bt}},58035:function(Ye,ye,A){"use strict";A.d(ye,{S:function(){return y},Z:function(){return p}});var R=A(77617),V=A(79161);function y($){return $ instanceof HTMLElement||$ instanceof SVGElement}function p($){return y($)?$:$ instanceof R.Component?V.findDOMNode($):null}},95077:function(Ye,ye){"use strict";ye.Z=function(A){if(!A)return!1;if(A instanceof Element){if(A.offsetParent)return!0;if(A.getBBox){var R=A.getBBox(),V=R.width,y=R.height;if(V||y)return!0}if(A.getBoundingClientRect){var p=A.getBoundingClientRect(),$=p.width,X=p.height;if($||X)return!0}}return!1}},39057:function(Ye,ye,A){"use strict";A.d(ye,{A:function(){return y}});function R(p){var $;return p==null||($=p.getRootNode)===null||$===void 0?void 0:$.call(p)}function V(p){return R(p)instanceof ShadowRoot}function y(p){return V(p)?R(p):null}},84821:function(Ye,ye){"use strict";var A={MAC_ENTER:3,BACKSPACE:8,TAB:9,NUM_CENTER:12,ENTER:13,SHIFT:16,CTRL:17,ALT:18,PAUSE:19,CAPS_LOCK:20,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,PRINT_SCREEN:44,INSERT:45,DELETE:46,ZERO:48,ONE:49,TWO:50,THREE:51,FOUR:52,FIVE:53,SIX:54,SEVEN:55,EIGHT:56,NINE:57,QUESTION_MARK:63,A:65,B:66,C:67,D:68,E:69,F:70,G:71,H:72,I:73,J:74,K:75,L:76,M:77,N:78,O:79,P:80,Q:81,R:82,S:83,T:84,U:85,V:86,W:87,X:88,Y:89,Z:90,META:91,WIN_KEY_RIGHT:92,CONTEXT_MENU:93,NUM_ZERO:96,NUM_ONE:97,NUM_TWO:98,NUM_THREE:99,NUM_FOUR:100,NUM_FIVE:101,NUM_SIX:102,NUM_SEVEN:103,NUM_EIGHT:104,NUM_NINE:105,NUM_MULTIPLY:106,NUM_PLUS:107,NUM_MINUS:109,NUM_PERIOD:110,NUM_DIVISION:111,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,NUMLOCK:144,SEMICOLON:186,DASH:189,EQUALS:187,COMMA:188,PERIOD:190,SLASH:191,APOSTROPHE:192,SINGLE_QUOTE:222,OPEN_SQUARE_BRACKET:219,BACKSLASH:220,CLOSE_SQUARE_BRACKET:221,WIN_KEY:224,MAC_FF_META:224,WIN_IME:229,isTextModifyingKeyEvent:function(V){var y=V.keyCode;if(V.altKey&&!V.ctrlKey||V.metaKey||y>=A.F1&&y<=A.F12)return!1;switch(y){case A.ALT:case A.CAPS_LOCK:case A.CONTEXT_MENU:case A.CTRL:case A.DOWN:case A.END:case A.ESC:case A.HOME:case A.INSERT:case A.LEFT:case A.MAC_FF_META:case A.META:case A.NUMLOCK:case A.NUM_CENTER:case A.PAGE_DOWN:case A.PAGE_UP:case A.PAUSE:case A.PRINT_SCREEN:case A.RIGHT:case A.SHIFT:case A.UP:case A.WIN_KEY:case A.WIN_KEY_RIGHT:return!1;default:return!0}},isCharacterKey:function(V){if(V>=A.ZERO&&V<=A.NINE||V>=A.NUM_ZERO&&V<=A.NUM_MULTIPLY||V>=A.A&&V<=A.Z||window.navigator.userAgent.indexOf("WebKit")!==-1&&V===0)return!0;switch(V){case A.SPACE:case A.QUESTION_MARK:case A.NUM_PLUS:case A.NUM_MINUS:case A.NUM_PERIOD:case A.NUM_DIVISION:case A.SEMICOLON:case A.DASH:case A.EQUALS:case A.COMMA:case A.PERIOD:case A.SLASH:case A.APOSTROPHE:case A.SINGLE_QUOTE:case A.OPEN_SQUARE_BRACKET:case A.BACKSLASH:case A.CLOSE_SQUARE_BRACKET:return!0;default:return!1}}};ye.Z=A},41522:function(Ye,ye,A){"use strict";var R;A.d(ye,{s:function(){return ut},v:function(){return tt}});var V=A(33202),y=A(90304),p=A(13255),$=A(54131),X=A(79161),se=(0,$.Z)({},R||(R=A.t(X,2))),ae=se.version,ce=se.render,le=se.unmountComponentAtNode,De;try{var we=Number((ae||"").split(".")[0]);we>=18&&(De=se.createRoot)}catch(bt){}function Ee(bt){var et=se.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;et&&(0,p.Z)(et)==="object"&&(et.usingClientEntryPoint=bt)}var qe="__rc_react_root__";function Ge(bt,et){Ee(!0);var pt=et[qe]||De(et);Ee(!1),pt.render(bt),et[qe]=pt}function ct(bt,et){ce(bt,et)}function Ve(bt,et){}function ut(bt,et){if(De){Ge(bt,et);return}ct(bt,et)}function Xe(bt){return Rt.apply(this,arguments)}function Rt(){return Rt=(0,y.Z)((0,V.Z)().mark(function bt(et){return(0,V.Z)().wrap(function(Ke){for(;;)switch(Ke.prev=Ke.next){case 0:return Ke.abrupt("return",Promise.resolve().then(function(){var ft;(ft=et[qe])===null||ft===void 0||ft.unmount(),delete et[qe]}));case 1:case"end":return Ke.stop()}},bt)})),Rt.apply(this,arguments)}function gt(bt){le(bt)}function Ct(bt){}function tt(bt){return Ne.apply(this,arguments)}function Ne(){return Ne=(0,y.Z)((0,V.Z)().mark(function bt(et){return(0,V.Z)().wrap(function(Ke){for(;;)switch(Ke.prev=Ke.next){case 0:if(De===void 0){Ke.next=2;break}return Ke.abrupt("return",Xe(et));case 2:gt(et);case 3:case"end":return Ke.stop()}},bt)})),Ne.apply(this,arguments)}},60402:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return V}});var R=A(77617);function V(y){var p=R.useRef();p.current=y;var $=R.useCallback(function(){for(var X,se=arguments.length,ae=new Array(se),ce=0;ce2&&arguments[2]!==void 0?arguments[2]:!1,se=new Set;function ae(ce,le){var De=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,we=se.has(ce);if((0,V.ZP)(!we,"Warning: There may be circular references"),we)return!1;if(ce===le)return!0;if(X&&De>1)return!1;se.add(ce);var Ee=De+1;if(Array.isArray(ce)){if(!Array.isArray(le)||ce.length!==le.length)return!1;for(var qe=0;qe

${ie}
+
${typeof this._cooperativeGestures!="boolean"&&this._cooperativeGestures.mobileHelpText?this._cooperativeGestures.mobileHelpText:"Use two fingers to move the map"}
+ `,this._cooperativeGesturesScreen.setAttribute("aria-hidden","true"),this._canvasContainer.addEventListener("wheel",this._cooperativeGesturesOnWheel,!1),this._canvasContainer.classList.add("maplibregl-cooperative-gestures")}_destroyCooperativeGestures(){X.remove(this._cooperativeGesturesScreen),this._canvasContainer.removeEventListener("wheel",this._cooperativeGesturesOnWheel,!1),this._canvasContainer.classList.remove("maplibregl-cooperative-gestures")}_resizeCanvas(ie,f,L){this._canvas.width=Math.floor(L*ie),this._canvas.height=Math.floor(L*f),this._canvas.style.width=`${ie}px`,this._canvas.style.height=`${f}px`}_setupPainter(){const ie={alpha:!0,stencil:!0,depth:!0,failIfMajorPerformanceCaveat:this._failIfMajorPerformanceCaveat,preserveDrawingBuffer:this._preserveDrawingBuffer,antialias:this._antialias||!1};let f=null;this._canvas.addEventListener("webglcontextcreationerror",ee=>{f={requestedAttributes:ie},ee&&(f.statusMessage=ee.statusMessage,f.type=ee.type)},{once:!0});const L=this._canvas.getContext("webgl2",ie)||this._canvas.getContext("webgl",ie);if(!L){const ee="Failed to initialize WebGL";throw f?(f.message=ee,new Error(JSON.stringify(f))):new Error(ee)}this.painter=new cs(L,this.transform),se.testSupport(L)}_onCooperativeGesture(ie,f,L){return!f&&L<2&&(this._cooperativeGesturesScreen.classList.add("maplibregl-show"),setTimeout(()=>{this._cooperativeGesturesScreen.classList.remove("maplibregl-show")},100)),!1}loaded(){return!this._styleDirty&&!this._sourcesDirty&&!!this.style&&this.style.loaded()}_update(ie){return this.style&&this.style._loaded?(this._styleDirty=this._styleDirty||ie,this._sourcesDirty=!0,this.triggerRepaint(),this):this}_requestRenderFrame(ie){return this._update(),this._renderTaskQueue.add(ie)}_cancelRenderFrame(ie){this._renderTaskQueue.remove(ie)}_render(ie){const f=this._idleTriggered?this._fadeDuration:0;if(this.painter.context.setDirty(),this.painter.setBaseState(),this._renderTaskQueue.run(ie),this._removed)return;let L=!1;if(this.style&&this._styleDirty){this._styleDirty=!1;const te=this.transform.zoom,me=p.h.now();this.style.zoomHistory.update(te,me);const He=new p.a8(te,{now:me,fadeDuration:f,zoomHistory:this.style.zoomHistory,transition:this.style.getTransition()}),nt=He.crossFadingFactor();nt===1&&nt===this._crossFadingFactor||(L=!0,this._crossFadingFactor=nt),this.style.update(He)}this.style&&this._sourcesDirty&&(this._sourcesDirty=!1,this.style._updateSources(this.transform)),this.terrain?(this.terrain.sourceCache.update(this.transform,this.terrain),this.transform._minEleveationForCurrentTile=this.terrain.getMinTileElevationForLngLatZoom(this.transform.center,this.transform.tileZoom),this._elevationFreeze||(this.transform.elevation=this.terrain.getElevationForLngLatZoom(this.transform.center,this.transform.tileZoom))):(this.transform._minEleveationForCurrentTile=0,this.transform.elevation=0),this._placementDirty=this.style&&this.style._updatePlacement(this.painter.transform,this.showCollisionBoxes,f,this._crossSourceCollisions),this.painter.render(this.style,{showTileBoundaries:this.showTileBoundaries,showOverdrawInspector:this._showOverdrawInspector,rotating:this.isRotating(),zooming:this.isZooming(),moving:this.isMoving(),fadeDuration:f,showPadding:this.showPadding}),this.fire(new p.k("render")),this.loaded()&&!this._loaded&&(this._loaded=!0,p.bg.mark(p.bh.load),this.fire(new p.k("load"))),this.style&&(this.style.hasTransitions()||L)&&(this._styleDirty=!0),this.style&&!this._placementDirty&&this.style._releaseSymbolFadeTiles();const ee=this._sourcesDirty||this._styleDirty||this._placementDirty;return ee||this._repaint?this.triggerRepaint():!this.isMoving()&&this.loaded()&&this.fire(new p.k("idle")),!this._loaded||this._fullyLoaded||ee||(this._fullyLoaded=!0,p.bg.mark(p.bh.fullLoad)),this}redraw(){return this.style&&(this._frame&&(this._frame.cancel(),this._frame=null),this._render(0)),this}remove(){var ie;this._hash&&this._hash.remove();for(const L of this._controls)L.onRemove(this);this._controls=[],this._frame&&(this._frame.cancel(),this._frame=null),this._renderTaskQueue.clear(),this.painter.destroy(),this.handlers.destroy(),delete this.handlers,this.setStyle(null),typeof window!="undefined"&&removeEventListener("online",this._onWindowOnline,!1),Ee.removeThrottleControl(this._imageQueueHandle),(ie=this._resizeObserver)===null||ie===void 0||ie.disconnect();const f=this.painter.context.gl.getExtension("WEBGL_lose_context");f&&f.loseContext(),this._canvas.removeEventListener("webglcontextrestored",this._contextRestored,!1),this._canvas.removeEventListener("webglcontextlost",this._contextLost,!1),X.remove(this._canvasContainer),X.remove(this._controlContainer),this._cooperativeGestures&&this._destroyCooperativeGestures(),this._container.classList.remove("maplibregl-map"),p.bg.clearMetrics(),this._removed=!0,this.fire(new p.k("remove"))}triggerRepaint(){this.style&&!this._frame&&(this._frame=p.h.frame(ie=>{p.bg.frame(ie),this._frame=null,this._render(ie)}))}get showTileBoundaries(){return!!this._showTileBoundaries}set showTileBoundaries(ie){this._showTileBoundaries!==ie&&(this._showTileBoundaries=ie,this._update())}get showPadding(){return!!this._showPadding}set showPadding(ie){this._showPadding!==ie&&(this._showPadding=ie,this._update())}get showCollisionBoxes(){return!!this._showCollisionBoxes}set showCollisionBoxes(ie){this._showCollisionBoxes!==ie&&(this._showCollisionBoxes=ie,ie?this.style._generateCollisionBoxes():this._update())}get showOverdrawInspector(){return!!this._showOverdrawInspector}set showOverdrawInspector(ie){this._showOverdrawInspector!==ie&&(this._showOverdrawInspector=ie,this._update())}get repaint(){return!!this._repaint}set repaint(ie){this._repaint!==ie&&(this._repaint=ie,this.triggerRepaint())}get vertices(){return!!this._vertices}set vertices(ie){this._vertices=ie,this._update()}get version(){return qo}getCameraTargetElevation(){return this.transform.elevation}},jt.NavigationControl=class{constructor(ie){this._updateZoomButtons=()=>{const f=this._map.getZoom(),L=f===this._map.getMaxZoom(),ee=f===this._map.getMinZoom();this._zoomInButton.disabled=L,this._zoomOutButton.disabled=ee,this._zoomInButton.setAttribute("aria-disabled",L.toString()),this._zoomOutButton.setAttribute("aria-disabled",ee.toString())},this._rotateCompassArrow=()=>{const f=this.options.visualizePitch?`scale(${1/Math.pow(Math.cos(this._map.transform.pitch*(Math.PI/180)),.5)}) rotateX(${this._map.transform.pitch}deg) rotateZ(${this._map.transform.angle*(180/Math.PI)}deg)`:`rotate(${this._map.transform.angle*(180/Math.PI)}deg)`;this._compassIcon.style.transform=f},this._setButtonTitle=(f,L)=>{const ee=this._map._getUIString(`NavigationControl.${L}`);f.title=ee,f.setAttribute("aria-label",ee)},this.options=p.e({},pc,ie),this._container=X.create("div","maplibregl-ctrl maplibregl-ctrl-group"),this._container.addEventListener("contextmenu",f=>f.preventDefault()),this.options.showZoom&&(this._zoomInButton=this._createButton("maplibregl-ctrl-zoom-in",f=>this._map.zoomIn({},{originalEvent:f})),X.create("span","maplibregl-ctrl-icon",this._zoomInButton).setAttribute("aria-hidden","true"),this._zoomOutButton=this._createButton("maplibregl-ctrl-zoom-out",f=>this._map.zoomOut({},{originalEvent:f})),X.create("span","maplibregl-ctrl-icon",this._zoomOutButton).setAttribute("aria-hidden","true")),this.options.showCompass&&(this._compass=this._createButton("maplibregl-ctrl-compass",f=>{this.options.visualizePitch?this._map.resetNorthPitch({},{originalEvent:f}):this._map.resetNorth({},{originalEvent:f})}),this._compassIcon=X.create("span","maplibregl-ctrl-icon",this._compass),this._compassIcon.setAttribute("aria-hidden","true"))}onAdd(ie){return this._map=ie,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._map.on("rotate",this._rotateCompassArrow),this._rotateCompassArrow(),this._handler=new Wf(this._map,this._compass,this.options.visualizePitch)),this._container}onRemove(){X.remove(this._container),this.options.showZoom&&this._map.off("zoom",this._updateZoomButtons),this.options.showCompass&&(this.options.visualizePitch&&this._map.off("pitch",this._rotateCompassArrow),this._map.off("rotate",this._rotateCompassArrow),this._handler.off(),delete this._handler),delete this._map}_createButton(ie,f){const L=X.create("button",ie,this._container);return L.type="button",L.addEventListener("click",f),L}},jt.GeolocateControl=class extends p.E{constructor(ie){super(),this._onSuccess=f=>{if(this._map){if(this._isOutOfMapMaxBounds(f))return this._setErrorState(),this.fire(new p.k("outofmaxbounds",f)),this._updateMarker(),void this._finish();if(this.options.trackUserLocation)switch(this._lastKnownPosition=f,this._watchState){case"WAITING_ACTIVE":case"ACTIVE_LOCK":case"ACTIVE_ERROR":this._watchState="ACTIVE_LOCK",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active-error"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-active");break;case"BACKGROUND":case"BACKGROUND_ERROR":this._watchState="BACKGROUND",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-background-error"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-background");break;default:throw new Error(`Unexpected watchState ${this._watchState}`)}this.options.showUserLocation&&this._watchState!=="OFF"&&this._updateMarker(f),this.options.trackUserLocation&&this._watchState!=="ACTIVE_LOCK"||this._updateCamera(f),this.options.showUserLocation&&this._dotElement.classList.remove("maplibregl-user-location-dot-stale"),this.fire(new p.k("geolocate",f)),this._finish()}},this._updateCamera=f=>{const L=new p.L(f.coords.longitude,f.coords.latitude),ee=f.coords.accuracy,te=this._map.getBearing(),me=p.e({bearing:te},this.options.fitBoundsOptions),He=Me.fromLngLat(L,ee);this._map.fitBounds(He,me,{geolocateSource:!0})},this._updateMarker=f=>{if(f){const L=new p.L(f.coords.longitude,f.coords.latitude);this._accuracyCircleMarker.setLngLat(L).addTo(this._map),this._userLocationDotMarker.setLngLat(L).addTo(this._map),this._accuracy=f.coords.accuracy,this.options.showUserLocation&&this.options.showAccuracyCircle&&this._updateCircleRadius()}else this._userLocationDotMarker.remove(),this._accuracyCircleMarker.remove()},this._onZoom=()=>{this.options.showUserLocation&&this.options.showAccuracyCircle&&this._updateCircleRadius()},this._onError=f=>{if(this._map){if(this.options.trackUserLocation)if(f.code===1){this._watchState="OFF",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active-error"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-background-error"),this._geolocateButton.disabled=!0;const L=this._map._getUIString("GeolocateControl.LocationNotAvailable");this._geolocateButton.title=L,this._geolocateButton.setAttribute("aria-label",L),this._geolocationWatchID!==void 0&&this._clearWatch()}else{if(f.code===3&&rh)return;this._setErrorState()}this._watchState!=="OFF"&&this.options.showUserLocation&&this._dotElement.classList.add("maplibregl-user-location-dot-stale"),this.fire(new p.k("error",f)),this._finish()}},this._finish=()=>{this._timeoutId&&clearTimeout(this._timeoutId),this._timeoutId=void 0},this._setupUI=f=>{if(this._map){if(this._container.addEventListener("contextmenu",L=>L.preventDefault()),this._geolocateButton=X.create("button","maplibregl-ctrl-geolocate",this._container),X.create("span","maplibregl-ctrl-icon",this._geolocateButton).setAttribute("aria-hidden","true"),this._geolocateButton.type="button",f===!1){p.w("Geolocation support is not available so the GeolocateControl will be disabled.");const L=this._map._getUIString("GeolocateControl.LocationNotAvailable");this._geolocateButton.disabled=!0,this._geolocateButton.title=L,this._geolocateButton.setAttribute("aria-label",L)}else{const L=this._map._getUIString("GeolocateControl.FindMyLocation");this._geolocateButton.title=L,this._geolocateButton.setAttribute("aria-label",L)}this.options.trackUserLocation&&(this._geolocateButton.setAttribute("aria-pressed","false"),this._watchState="OFF"),this.options.showUserLocation&&(this._dotElement=X.create("div","maplibregl-user-location-dot"),this._userLocationDotMarker=new fh({element:this._dotElement}),this._circleElement=X.create("div","maplibregl-user-location-accuracy-circle"),this._accuracyCircleMarker=new fh({element:this._circleElement,pitchAlignment:"map"}),this.options.trackUserLocation&&(this._watchState="OFF"),this._map.on("zoom",this._onZoom)),this._geolocateButton.addEventListener("click",this.trigger.bind(this)),this._setup=!0,this.options.trackUserLocation&&this._map.on("movestart",L=>{L.geolocateSource||this._watchState!=="ACTIVE_LOCK"||L.originalEvent&&L.originalEvent.type==="resize"||(this._watchState="BACKGROUND",this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active"),this.fire(new p.k("trackuserlocationend")))})}},this.options=p.e({},uf,ie)}onAdd(ie){return this._map=ie,this._container=X.create("div","maplibregl-ctrl maplibregl-ctrl-group"),function(f,L=!1){Tu===void 0||L?window.navigator.permissions!==void 0?window.navigator.permissions.query({name:"geolocation"}).then(ee=>{Tu=ee.state!=="denied",f(Tu)}).catch(()=>{Tu=!!window.navigator.geolocation,f(Tu)}):(Tu=!!window.navigator.geolocation,f(Tu)):f(Tu)}(this._setupUI),this._container}onRemove(){this._geolocationWatchID!==void 0&&(window.navigator.geolocation.clearWatch(this._geolocationWatchID),this._geolocationWatchID=void 0),this.options.showUserLocation&&this._userLocationDotMarker&&this._userLocationDotMarker.remove(),this.options.showAccuracyCircle&&this._accuracyCircleMarker&&this._accuracyCircleMarker.remove(),X.remove(this._container),this._map.off("zoom",this._onZoom),this._map=void 0,Yf=0,rh=!1}_isOutOfMapMaxBounds(ie){const f=this._map.getMaxBounds(),L=ie.coords;return f&&(L.longitudef.getEast()||L.latitudef.getNorth())}_setErrorState(){switch(this._watchState){case"WAITING_ACTIVE":this._watchState="ACTIVE_ERROR",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-active-error");break;case"ACTIVE_LOCK":this._watchState="ACTIVE_ERROR",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-active-error"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-waiting");break;case"BACKGROUND":this._watchState="BACKGROUND_ERROR",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-background"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-background-error"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-waiting");break;case"ACTIVE_ERROR":break;default:throw new Error(`Unexpected watchState ${this._watchState}`)}}_updateCircleRadius(){const ie=this._map.getBounds(),f=ie.getSouthEast(),L=ie.getNorthEast(),ee=f.distanceTo(L),te=Math.ceil(this._accuracy/(ee/this._map._container.clientHeight)*2);this._circleElement.style.width=`${te}px`,this._circleElement.style.height=`${te}px`}trigger(){if(!this._setup)return p.w("Geolocate control triggered before added to a map"),!1;if(this.options.trackUserLocation){switch(this._watchState){case"OFF":this._watchState="WAITING_ACTIVE",this.fire(new p.k("trackuserlocationstart"));break;case"WAITING_ACTIVE":case"ACTIVE_LOCK":case"ACTIVE_ERROR":case"BACKGROUND_ERROR":Yf--,rh=!1,this._watchState="OFF",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active-error"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-background-error"),this.fire(new p.k("trackuserlocationend"));break;case"BACKGROUND":this._watchState="ACTIVE_LOCK",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-background"),this._lastKnownPosition&&this._updateCamera(this._lastKnownPosition),this.fire(new p.k("trackuserlocationstart"));break;default:throw new Error(`Unexpected watchState ${this._watchState}`)}switch(this._watchState){case"WAITING_ACTIVE":this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-active");break;case"ACTIVE_LOCK":this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-active");break;case"OFF":break;default:throw new Error(`Unexpected watchState ${this._watchState}`)}if(this._watchState==="OFF"&&this._geolocationWatchID!==void 0)this._clearWatch();else if(this._geolocationWatchID===void 0){let ie;this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-waiting"),this._geolocateButton.setAttribute("aria-pressed","true"),Yf++,Yf>1?(ie={maximumAge:6e5,timeout:0},rh=!0):(ie=this.options.positionOptions,rh=!1),this._geolocationWatchID=window.navigator.geolocation.watchPosition(this._onSuccess,this._onError,ie)}}else window.navigator.geolocation.getCurrentPosition(this._onSuccess,this._onError,this.options.positionOptions),this._timeoutId=setTimeout(this._finish,1e4);return!0}_clearWatch(){window.navigator.geolocation.clearWatch(this._geolocationWatchID),this._geolocationWatchID=void 0,this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-waiting"),this._geolocateButton.setAttribute("aria-pressed","false"),this.options.showUserLocation&&this._updateMarker(null)}},jt.AttributionControl=cc,jt.LogoControl=gu,jt.ScaleControl=class{constructor(ie){this._onMove=()=>{fp(this._map,this._container,this.options)},this.setUnit=f=>{this.options.unit=f,fp(this._map,this._container,this.options)},this.options=p.e({},ud,ie)}getDefaultPosition(){return"bottom-left"}onAdd(ie){return this._map=ie,this._container=X.create("div","maplibregl-ctrl maplibregl-ctrl-scale",ie.getContainer()),this._map.on("move",this._onMove),this._onMove(),this._container}onRemove(){X.remove(this._container),this._map.off("move",this._onMove),this._map=void 0}},jt.FullscreenControl=class extends p.E{constructor(ie={}){super(),this._onFullscreenChange=()=>{(window.document.fullscreenElement||window.document.mozFullScreenElement||window.document.webkitFullscreenElement||window.document.msFullscreenElement)===this._container!==this._fullscreen&&this._handleFullscreenChange()},this._onClickFullscreen=()=>{this._isFullscreen()?this._exitFullscreen():this._requestFullscreen()},this._fullscreen=!1,ie&&ie.container&&(ie.container instanceof HTMLElement?this._container=ie.container:p.w("Full screen control 'container' must be a DOM element.")),"onfullscreenchange"in document?this._fullscreenchange="fullscreenchange":"onmozfullscreenchange"in document?this._fullscreenchange="mozfullscreenchange":"onwebkitfullscreenchange"in document?this._fullscreenchange="webkitfullscreenchange":"onmsfullscreenchange"in document&&(this._fullscreenchange="MSFullscreenChange")}onAdd(ie){return this._map=ie,this._container||(this._container=this._map.getContainer()),this._controlContainer=X.create("div","maplibregl-ctrl maplibregl-ctrl-group"),this._setupUI(),this._controlContainer}onRemove(){X.remove(this._controlContainer),this._map=null,window.document.removeEventListener(this._fullscreenchange,this._onFullscreenChange)}_setupUI(){const ie=this._fullscreenButton=X.create("button","maplibregl-ctrl-fullscreen",this._controlContainer);X.create("span","maplibregl-ctrl-icon",ie).setAttribute("aria-hidden","true"),ie.type="button",this._updateTitle(),this._fullscreenButton.addEventListener("click",this._onClickFullscreen),window.document.addEventListener(this._fullscreenchange,this._onFullscreenChange)}_updateTitle(){const ie=this._getTitle();this._fullscreenButton.setAttribute("aria-label",ie),this._fullscreenButton.title=ie}_getTitle(){return this._map._getUIString(this._isFullscreen()?"FullscreenControl.Exit":"FullscreenControl.Enter")}_isFullscreen(){return this._fullscreen}_handleFullscreenChange(){this._fullscreen=!this._fullscreen,this._fullscreenButton.classList.toggle("maplibregl-ctrl-shrink"),this._fullscreenButton.classList.toggle("maplibregl-ctrl-fullscreen"),this._updateTitle(),this._fullscreen?(this.fire(new p.k("fullscreenstart")),this._map._cooperativeGestures&&(this._prevCooperativeGestures=this._map._cooperativeGestures,this._map.setCooperativeGestures())):(this.fire(new p.k("fullscreenend")),this._prevCooperativeGestures&&(this._map.setCooperativeGestures(this._prevCooperativeGestures),delete this._prevCooperativeGestures))}_exitFullscreen(){window.document.exitFullscreen?window.document.exitFullscreen():window.document.mozCancelFullScreen?window.document.mozCancelFullScreen():window.document.msExitFullscreen?window.document.msExitFullscreen():window.document.webkitCancelFullScreen?window.document.webkitCancelFullScreen():this._togglePseudoFullScreen()}_requestFullscreen(){this._container.requestFullscreen?this._container.requestFullscreen():this._container.mozRequestFullScreen?this._container.mozRequestFullScreen():this._container.msRequestFullscreen?this._container.msRequestFullscreen():this._container.webkitRequestFullscreen?this._container.webkitRequestFullscreen():this._togglePseudoFullScreen()}_togglePseudoFullScreen(){this._container.classList.toggle("maplibregl-pseudo-fullscreen"),this._handleFullscreenChange(),this._map.resize()}},jt.TerrainControl=class{constructor(ie){this._toggleTerrain=()=>{this._map.getTerrain()?this._map.setTerrain(null):this._map.setTerrain(this.options),this._updateTerrainIcon()},this._updateTerrainIcon=()=>{this._terrainButton.classList.remove("maplibregl-ctrl-terrain"),this._terrainButton.classList.remove("maplibregl-ctrl-terrain-enabled"),this._map.terrain?(this._terrainButton.classList.add("maplibregl-ctrl-terrain-enabled"),this._terrainButton.title=this._map._getUIString("TerrainControl.disableTerrain")):(this._terrainButton.classList.add("maplibregl-ctrl-terrain"),this._terrainButton.title=this._map._getUIString("TerrainControl.enableTerrain"))},this.options=ie}onAdd(ie){return this._map=ie,this._container=X.create("div","maplibregl-ctrl maplibregl-ctrl-group"),this._terrainButton=X.create("button","maplibregl-ctrl-terrain",this._container),X.create("span","maplibregl-ctrl-icon",this._terrainButton).setAttribute("aria-hidden","true"),this._terrainButton.type="button",this._terrainButton.addEventListener("click",this._toggleTerrain),this._updateTerrainIcon(),this._map.on("terrain",this._updateTerrainIcon),this._container}onRemove(){X.remove(this._container),this._map.off("terrain",this._updateTerrainIcon),this._map=void 0}},jt.Popup=class extends p.E{constructor(ie){super(),this.remove=()=>(this._content&&X.remove(this._content),this._container&&(X.remove(this._container),delete this._container),this._map&&(this._map.off("move",this._update),this._map.off("move",this._onClose),this._map.off("click",this._onClose),this._map.off("remove",this.remove),this._map.off("mousemove",this._onMouseMove),this._map.off("mouseup",this._onMouseUp),this._map.off("drag",this._onDrag),delete this._map),this.fire(new p.k("close")),this),this._onMouseUp=f=>{this._update(f.point)},this._onMouseMove=f=>{this._update(f.point)},this._onDrag=f=>{this._update(f.point)},this._update=f=>{if(!this._map||!this._lngLat&&!this._trackPointer||!this._content)return;if(!this._container){if(this._container=X.create("div","maplibregl-popup",this._map.getContainer()),this._tip=X.create("div","maplibregl-popup-tip",this._container),this._container.appendChild(this._content),this.options.className)for(const He of this.options.className.split(" "))this._container.classList.add(He);this._trackPointer&&this._container.classList.add("maplibregl-popup-track-pointer")}if(this.options.maxWidth&&this._container.style.maxWidth!==this.options.maxWidth&&(this._container.style.maxWidth=this.options.maxWidth),this._map.transform.renderWorldCopies&&!this._trackPointer&&(this._lngLat=Ih(this._lngLat,this._pos,this._map.transform)),this._trackPointer&&!f)return;const L=this._pos=this._trackPointer&&f?f:this._map.project(this._lngLat);let ee=this.options.anchor;const te=W(this.options.offset);if(!ee){const He=this._container.offsetWidth,nt=this._container.offsetHeight;let w;w=L.y+te.bottom.ythis._map.transform.height-nt?["bottom"]:[],L.xthis._map.transform.width-He/2&&w.push("right"),ee=w.length===0?"bottom":w.join("-")}const me=L.add(te[ee]).round();X.setTransform(this._container,`${Bl[ee]} translate(${me.x}px,${me.y}px)`),Xf(this._container,ee,"popup")},this._onClose=()=>{this.remove()},this.options=p.e(Object.create(v),ie)}addTo(ie){return this._map&&this.remove(),this._map=ie,this.options.closeOnClick&&this._map.on("click",this._onClose),this.options.closeOnMove&&this._map.on("move",this._onClose),this._map.on("remove",this.remove),this._update(),this._focusFirstElement(),this._trackPointer?(this._map.on("mousemove",this._onMouseMove),this._map.on("mouseup",this._onMouseUp),this._container&&this._container.classList.add("maplibregl-popup-track-pointer"),this._map._canvasContainer.classList.add("maplibregl-track-pointer")):this._map.on("move",this._update),this.fire(new p.k("open")),this}isOpen(){return!!this._map}getLngLat(){return this._lngLat}setLngLat(ie){return this._lngLat=p.L.convert(ie),this._pos=null,this._trackPointer=!1,this._update(),this._map&&(this._map.on("move",this._update),this._map.off("mousemove",this._onMouseMove),this._container&&this._container.classList.remove("maplibregl-popup-track-pointer"),this._map._canvasContainer.classList.remove("maplibregl-track-pointer")),this}trackPointer(){return this._trackPointer=!0,this._pos=null,this._update(),this._map&&(this._map.off("move",this._update),this._map.on("mousemove",this._onMouseMove),this._map.on("drag",this._onDrag),this._container&&this._container.classList.add("maplibregl-popup-track-pointer"),this._map._canvasContainer.classList.add("maplibregl-track-pointer")),this}getElement(){return this._container}setText(ie){return this.setDOMContent(document.createTextNode(ie))}setHTML(ie){const f=document.createDocumentFragment(),L=document.createElement("body");let ee;for(L.innerHTML=ie;ee=L.firstChild,ee;)f.appendChild(ee);return this.setDOMContent(f)}getMaxWidth(){var ie;return(ie=this._container)===null||ie===void 0?void 0:ie.style.maxWidth}setMaxWidth(ie){return this.options.maxWidth=ie,this._update(),this}setDOMContent(ie){if(this._content)for(;this._content.hasChildNodes();)this._content.firstChild&&this._content.removeChild(this._content.firstChild);else this._content=X.create("div","maplibregl-popup-content",this._container);return this._content.appendChild(ie),this._createCloseButton(),this._update(),this._focusFirstElement(),this}addClassName(ie){this._container&&this._container.classList.add(ie)}removeClassName(ie){this._container&&this._container.classList.remove(ie)}setOffset(ie){return this.options.offset=ie,this._update(),this}toggleClassName(ie){if(this._container)return this._container.classList.toggle(ie)}_createCloseButton(){this.options.closeButton&&(this._closeButton=X.create("button","maplibregl-popup-close-button",this._content),this._closeButton.type="button",this._closeButton.setAttribute("aria-label","Close popup"),this._closeButton.innerHTML="×",this._closeButton.addEventListener("click",this._onClose))}_focusFirstElement(){if(!this.options.focusAfterOpen||!this._container)return;const ie=this._container.querySelector(B);ie&&ie.focus()}},jt.Marker=fh,jt.Style=as,jt.LngLat=p.L,jt.LngLatBounds=Me,jt.Point=p.P,jt.MercatorCoordinate=p.U,jt.Evented=p.E,jt.AJAXError=p.bi,jt.config=p.c,jt.CanvasSource=Nn,jt.GeoJSONSource=Yr,jt.ImageSource=ln,jt.RasterDEMTileSource=Kt,jt.RasterTileSource=dr,jt.VectorTileSource=Qe,jt.VideoSource=oi,jt.setRTLTextPlugin=p.bj,jt.getRTLTextPluginStatus=p.bk,jt.prewarm=function(){Ii().acquire(qi)},jt.clearPrewarmedResources=function(){const ie=Wi;ie&&(ie.isPreloaded()&&ie.numActive()===1?(ie.release(qi),Wi=null):console.warn("Could not clear WebWorkers since there are active Map instances that still reference it. The pre-warmed WebWorker pool can only be cleared when all map instances have been removed with map.remove()"))},_e.extend(jt,{isSafari:p.ac,getPerformanceMetrics:p.bg.getPerformanceMetrics}),jt});var y=R;return y})},54098:function(Ye,ye,A){var R;(function(V){(function(y){var p=typeof globalThis=="object"?globalThis:typeof A.g=="object"?A.g:typeof self=="object"?self:typeof this=="object"?this:ce(),$=X(V);typeof p.Reflect!="undefined"&&($=X(p.Reflect,$)),y($,p),typeof p.Reflect=="undefined"&&(p.Reflect=V);function X(le,De){return function(we,Ee){Object.defineProperty(le,we,{configurable:!0,writable:!0,value:Ee}),De&&De(we,Ee)}}function se(){try{return Function("return this;")()}catch(le){}}function ae(){try{return(0,eval)("(function() { return this; })()")}catch(le){}}function ce(){return se()||ae()}})(function(y,p){var $=Object.prototype.hasOwnProperty,X=typeof Symbol=="function",se=X&&typeof Symbol.toPrimitive!="undefined"?Symbol.toPrimitive:"@@toPrimitive",ae=X&&typeof Symbol.iterator!="undefined"?Symbol.iterator:"@@iterator",ce=typeof Object.create=="function",le={__proto__:[]}instanceof Array,De=!ce&&!le,we={create:ce?function(){return Fo(Object.create(null))}:le?function(){return Fo({__proto__:null})}:function(){return Fo({})},has:De?function(xt,it){return $.call(xt,it)}:function(xt,it){return it in xt},get:De?function(xt,it){return $.call(xt,it)?xt[it]:void 0}:function(xt,it){return xt[it]}},Ee=Object.getPrototypeOf(Function),qe=typeof Map=="function"&&typeof Map.prototype.entries=="function"?Map:Un(),Ge=typeof Set=="function"&&typeof Set.prototype.entries=="function"?Set:Hi(),ct=typeof WeakMap=="function"?WeakMap:Ki(),Ve=X?Symbol.for("@reflect-metadata:registry"):void 0,ut=Ii(),Xe=ko(ut);function Rt(xt,it,kt,ir){if(Kt(kt)){if(!Ji(xt))throw new TypeError;if(!Ei(it))throw new TypeError;return wt(xt,it)}else{if(!Ji(xt))throw new TypeError;if(!ln(it))throw new TypeError;if(!ln(ir)&&!Kt(ir)&&!Yr(ir))throw new TypeError;return Yr(ir)&&(ir=void 0),kt=Qn(kt),Se(xt,it,kt,ir)}}y("decorate",Rt);function gt(xt,it){function kt(ir,Pr){if(!ln(ir))throw new TypeError;if(!Kt(Pr)&&!xo(Pr))throw new TypeError;Me(xt,it,ir,Pr)}return kt}y("metadata",gt);function Ct(xt,it,kt,ir){if(!ln(kt))throw new TypeError;return Kt(ir)||(ir=Qn(ir)),Me(xt,it,kt,ir)}y("defineMetadata",Ct);function tt(xt,it,kt){if(!ln(it))throw new TypeError;return Kt(kt)||(kt=Qn(kt)),Ft(xt,it,kt)}y("hasMetadata",tt);function Ne(xt,it,kt){if(!ln(it))throw new TypeError;return Kt(kt)||(kt=Qn(kt)),mt(xt,it,kt)}y("hasOwnMetadata",Ne);function bt(xt,it,kt){if(!ln(it))throw new TypeError;return Kt(kt)||(kt=Qn(kt)),ot(xt,it,kt)}y("getMetadata",bt);function et(xt,it,kt){if(!ln(it))throw new TypeError;return Kt(kt)||(kt=Qn(kt)),We(xt,it,kt)}y("getOwnMetadata",et);function pt(xt,it){if(!ln(xt))throw new TypeError;return Kt(it)||(it=Qn(it)),st(xt,it)}y("getMetadataKeys",pt);function Ke(xt,it){if(!ln(xt))throw new TypeError;return Kt(it)||(it=Qn(it)),Qe(xt,it)}y("getOwnMetadataKeys",Ke);function ft(xt,it,kt){if(!ln(it))throw new TypeError;if(Kt(kt)||(kt=Qn(kt)),!ln(it))throw new TypeError;Kt(kt)||(kt=Qn(kt));var ir=zn(it,kt,!1);return Kt(ir)?!1:ir.OrdinaryDeleteMetadata(xt,it,kt)}y("deleteMetadata",ft);function wt(xt,it){for(var kt=xt.length-1;kt>=0;--kt){var ir=xt[kt],Pr=ir(it);if(!Kt(Pr)&&!Yr(Pr)){if(!Ei(Pr))throw new TypeError;it=Pr}}return it}function Se(xt,it,kt,ir){for(var Pr=xt.length-1;Pr>=0;--Pr){var kr=xt[Pr],An=kr(it,kt,ir);if(!Kt(An)&&!Yr(An)){if(!ln(An))throw new TypeError;ir=An}}return ir}function Ft(xt,it,kt){var ir=mt(xt,it,kt);if(ir)return!0;var Pr=Mo(it);return Yr(Pr)?!1:Ft(xt,Pr,kt)}function mt(xt,it,kt){var ir=zn(it,kt,!1);return Kt(ir)?!1:$n(ir.OrdinaryHasOwnMetadata(xt,it,kt))}function ot(xt,it,kt){var ir=mt(xt,it,kt);if(ir)return We(xt,it,kt);var Pr=Mo(it);if(!Yr(Pr))return ot(xt,Pr,kt)}function We(xt,it,kt){var ir=zn(it,kt,!1);if(!Kt(ir))return ir.OrdinaryGetOwnMetadata(xt,it,kt)}function Me(xt,it,kt,ir){var Pr=zn(kt,ir,!0);Pr.OrdinaryDefineOwnMetadata(xt,it,kt,ir)}function st(xt,it){var kt=Qe(xt,it),ir=Mo(xt);if(ir===null)return kt;var Pr=st(ir,it);if(Pr.length<=0)return kt;if(kt.length<=0)return Pr;for(var kr=new Ge,An=[],Dn=0,Ht=kt;Dn=0&&Ht=this._keys.length?(this._index=-1,this._keys=it,this._values=it):this._index++,{value:Lt,done:!1}}return{value:void 0,done:!0}},Dn.prototype.throw=function(Ht){throw this._index>=0&&(this._index=-1,this._keys=it,this._values=it),Ht},Dn.prototype.return=function(Ht){return this._index>=0&&(this._index=-1,this._keys=it,this._values=it),{value:Ht,done:!0}},Dn}(),ir=function(){function Dn(){this._keys=[],this._values=[],this._cacheKey=xt,this._cacheIndex=-2}return Object.defineProperty(Dn.prototype,"size",{get:function(){return this._keys.length},enumerable:!0,configurable:!0}),Dn.prototype.has=function(Ht){return this._find(Ht,!1)>=0},Dn.prototype.get=function(Ht){var Lt=this._find(Ht,!1);return Lt>=0?this._values[Lt]:void 0},Dn.prototype.set=function(Ht,Lt){var je=this._find(Ht,!0);return this._values[je]=Lt,this},Dn.prototype.delete=function(Ht){var Lt=this._find(Ht,!1);if(Lt>=0){for(var je=this._keys.length,$e=Lt+1;$eV.length)&&(y=V.length);for(var p=0,$=new Array(y);p=0)&&($[se]=y[se]);return $}function V(y,p){if(y==null)return{};var $=R(y,p),X,se;if(Object.getOwnPropertySymbols){var ae=Object.getOwnPropertySymbols(y);for(se=0;se=0)&&Object.prototype.propertyIsEnumerable.call(y,X)&&($[X]=y[X])}return $}},16169:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return y}});var R=A(13255),V=A(7963);function y(p,$){if($&&((0,R.Z)($)==="object"||typeof $=="function"))return $;if($!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return(0,V.Z)(p)}},33202:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return V}});var R=A(13255);function V(){"use strict";V=function(){return p};var y,p={},$=Object.prototype,X=$.hasOwnProperty,se=Object.defineProperty||function(We,Me,st){We[Me]=st.value},ae=typeof Symbol=="function"?Symbol:{},ce=ae.iterator||"@@iterator",le=ae.asyncIterator||"@@asyncIterator",De=ae.toStringTag||"@@toStringTag";function we(We,Me,st){return Object.defineProperty(We,Me,{value:st,enumerable:!0,configurable:!0,writable:!0}),We[Me]}try{we({},"")}catch(We){we=function(st,Qe,dr){return st[Qe]=dr}}function Ee(We,Me,st,Qe){var dr=Me&&Me.prototype instanceof Rt?Me:Rt,Kt=Object.create(dr.prototype),Yr=new mt(Qe||[]);return se(Kt,"_invoke",{value:ft(We,st,Yr)}),Kt}function qe(We,Me,st){try{return{type:"normal",arg:We.call(Me,st)}}catch(Qe){return{type:"throw",arg:Qe}}}p.wrap=Ee;var Ge="suspendedStart",ct="suspendedYield",Ve="executing",ut="completed",Xe={};function Rt(){}function gt(){}function Ct(){}var tt={};we(tt,ce,function(){return this});var Ne=Object.getPrototypeOf,bt=Ne&&Ne(Ne(ot([])));bt&&bt!==$&&X.call(bt,ce)&&(tt=bt);var et=Ct.prototype=Rt.prototype=Object.create(tt);function pt(We){["next","throw","return"].forEach(function(Me){we(We,Me,function(st){return this._invoke(Me,st)})})}function Ke(We,Me){function st(dr,Kt,Yr,hn){var ln=qe(We[dr],We,Kt);if(ln.type!=="throw"){var oi=ln.arg,Nn=oi.value;return Nn&&(0,R.Z)(Nn)=="object"&&X.call(Nn,"__await")?Me.resolve(Nn.__await).then(function($n){st("next",$n,Yr,hn)},function($n){st("throw",$n,Yr,hn)}):Me.resolve(Nn).then(function($n){oi.value=$n,Yr(oi)},function($n){return st("throw",$n,Yr,hn)})}hn(ln.arg)}var Qe;se(this,"_invoke",{value:function(Kt,Yr){function hn(){return new Me(function(ln,oi){st(Kt,Yr,ln,oi)})}return Qe=Qe?Qe.then(hn,hn):hn()}})}function ft(We,Me,st){var Qe=Ge;return function(dr,Kt){if(Qe===Ve)throw new Error("Generator is already running");if(Qe===ut){if(dr==="throw")throw Kt;return{value:y,done:!0}}for(st.method=dr,st.arg=Kt;;){var Yr=st.delegate;if(Yr){var hn=wt(Yr,st);if(hn){if(hn===Xe)continue;return hn}}if(st.method==="next")st.sent=st._sent=st.arg;else if(st.method==="throw"){if(Qe===Ge)throw Qe=ut,st.arg;st.dispatchException(st.arg)}else st.method==="return"&&st.abrupt("return",st.arg);Qe=Ve;var ln=qe(We,Me,st);if(ln.type==="normal"){if(Qe=st.done?ut:ct,ln.arg===Xe)continue;return{value:ln.arg,done:st.done}}ln.type==="throw"&&(Qe=ut,st.method="throw",st.arg=ln.arg)}}}function wt(We,Me){var st=Me.method,Qe=We.iterator[st];if(Qe===y)return Me.delegate=null,st==="throw"&&We.iterator.return&&(Me.method="return",Me.arg=y,wt(We,Me),Me.method==="throw")||st!=="return"&&(Me.method="throw",Me.arg=new TypeError("The iterator does not provide a '"+st+"' method")),Xe;var dr=qe(Qe,We.iterator,Me.arg);if(dr.type==="throw")return Me.method="throw",Me.arg=dr.arg,Me.delegate=null,Xe;var Kt=dr.arg;return Kt?Kt.done?(Me[We.resultName]=Kt.value,Me.next=We.nextLoc,Me.method!=="return"&&(Me.method="next",Me.arg=y),Me.delegate=null,Xe):Kt:(Me.method="throw",Me.arg=new TypeError("iterator result is not an object"),Me.delegate=null,Xe)}function Se(We){var Me={tryLoc:We[0]};1 in We&&(Me.catchLoc=We[1]),2 in We&&(Me.finallyLoc=We[2],Me.afterLoc=We[3]),this.tryEntries.push(Me)}function Ft(We){var Me=We.completion||{};Me.type="normal",delete Me.arg,We.completion=Me}function mt(We){this.tryEntries=[{tryLoc:"root"}],We.forEach(Se,this),this.reset(!0)}function ot(We){if(We||We===""){var Me=We[ce];if(Me)return Me.call(We);if(typeof We.next=="function")return We;if(!isNaN(We.length)){var st=-1,Qe=function dr(){for(;++st=0;--dr){var Kt=this.tryEntries[dr],Yr=Kt.completion;if(Kt.tryLoc==="root")return Qe("end");if(Kt.tryLoc<=this.prev){var hn=X.call(Kt,"catchLoc"),ln=X.call(Kt,"finallyLoc");if(hn&&ln){if(this.prev=0;--Qe){var dr=this.tryEntries[Qe];if(dr.tryLoc<=this.prev&&X.call(dr,"finallyLoc")&&this.prev=0;--st){var Qe=this.tryEntries[st];if(Qe.finallyLoc===Me)return this.complete(Qe.completion,Qe.afterLoc),Ft(Qe),Xe}},catch:function(Me){for(var st=this.tryEntries.length-1;st>=0;--st){var Qe=this.tryEntries[st];if(Qe.tryLoc===Me){var dr=Qe.completion;if(dr.type==="throw"){var Kt=dr.arg;Ft(Qe)}return Kt}}throw new Error("illegal catch attempt")},delegateYield:function(Me,st,Qe){return this.delegate={iterator:ot(Me),resultName:st,nextLoc:Qe},this.method==="next"&&(this.arg=y),Xe}},p}},28913:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return R}});function R(V,y){return R=Object.setPrototypeOf?Object.setPrototypeOf.bind():function($,X){return $.__proto__=X,$},R(V,y)}},35372:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return $}});var R=A(45442);function V(X,se){var ae=X==null?null:typeof Symbol!="undefined"&&X[Symbol.iterator]||X["@@iterator"];if(ae!=null){var ce,le,De,we,Ee=[],qe=!0,Ge=!1;try{if(De=(ae=ae.call(X)).next,se===0){if(Object(ae)!==ae)return;qe=!1}else for(;!(qe=(ce=De.call(ae)).done)&&(Ee.push(ce.value),Ee.length!==se);qe=!0);}catch(ct){Ge=!0,le=ct}finally{try{if(!qe&&ae.return!=null&&(we=ae.return(),Object(we)!==we))return}finally{if(Ge)throw le}}return Ee}}var y=A(658),p=A(97883);function $(X,se){return(0,R.Z)(X)||V(X,se)||(0,y.Z)(X,se)||(0,p.Z)()}},89514:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return $}});var R=A(45442),V=A(36831),y=A(658),p=A(97883);function $(X){return(0,R.Z)(X)||(0,V.Z)(X)||(0,y.Z)(X)||(0,p.Z)()}},49397:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return X}});var R=A(66646);function V(se){if(Array.isArray(se))return(0,R.Z)(se)}var y=A(36831),p=A(658);function $(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function X(se){return V(se)||(0,y.Z)(se)||(0,p.Z)(se)||$()}},35391:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return y}});var R=A(13255);function V(p,$){if((0,R.Z)(p)!="object"||!p)return p;var X=p[Symbol.toPrimitive];if(X!==void 0){var se=X.call(p,$||"default");if((0,R.Z)(se)!="object")return se;throw new TypeError("@@toPrimitive must return a primitive value.")}return($==="string"?String:Number)(p)}function y(p){var $=V(p,"string");return(0,R.Z)($)=="symbol"?$:String($)}},13255:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return R}});function R(V){"@babel/helpers - typeof";return R=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(y){return typeof y}:function(y){return y&&typeof Symbol=="function"&&y.constructor===Symbol&&y!==Symbol.prototype?"symbol":typeof y},R(V)}},658:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return V}});var R=A(66646);function V(y,p){if(y){if(typeof y=="string")return(0,R.Z)(y,p);var $=Object.prototype.toString.call(y).slice(8,-1);if($==="Object"&&y.constructor&&($=y.constructor.name),$==="Map"||$==="Set")return Array.from(y);if($==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test($))return(0,R.Z)(y,p)}}},39511:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return V}});var R=A(8822);function V(y,p){p===void 0&&(p={});var $=Number(y[0]),X=Number(y[1]),se=Number(y[2]),ae=Number(y[3]);if(y.length===6)throw new Error("@turf/bbox-polygon does not support BBox with 6 positions");var ce=[$,X],le=[$,ae],De=[se,ae],we=[se,X];return(0,R.yu)([[ce,we,De,le,ce]],p.properties,{bbox:y,id:p.id})}},86461:function(Ye,ye,A){"use strict";var R=A(94169);function V(y){var p=[1/0,1/0,-1/0,-1/0];return(0,R.pZ)(y,function($){p[0]>$[0]&&(p[0]=$[0]),p[1]>$[1]&&(p[1]=$[1]),p[2]<$[0]&&(p[2]=$[0]),p[3]<$[1]&&(p[3]=$[1])}),p}V.default=V,ye.Z=V},8822:function(Ye,ye,A){"use strict";A.d(ye,{DL:function(){return Xe},Ht:function(){return Ne},Tu:function(){return De},ot:function(){return Ge},tw:function(){return ct},uf:function(){return Ee},vi:function(){return tt},xm:function(){return se},yu:function(){return ce},zL:function(){return $}});var R=63710088e-1,V={centimeters:R*100,centimetres:R*100,degrees:R/111325,feet:R*3.28084,inches:R*39.37,kilometers:R/1e3,kilometres:R/1e3,meters:R,metres:R,miles:R/1609.344,millimeters:R*1e3,millimetres:R*1e3,nauticalmiles:R/1852,radians:1,yards:R*1.0936},y={centimeters:100,centimetres:100,degrees:1/111325,feet:3.28084,inches:39.37,kilometers:1/1e3,kilometres:1/1e3,meters:1,metres:1,miles:1/1609.344,millimeters:1e3,millimetres:1e3,nauticalmiles:1/1852,radians:1/R,yards:1.0936133},p={acres:247105e-9,centimeters:1e4,centimetres:1e4,feet:10.763910417,hectares:1e-4,inches:1550.003100006,kilometers:1e-6,kilometres:1e-6,meters:1,metres:1,miles:386e-9,millimeters:1e6,millimetres:1e6,yards:1.195990046};function $(Se,Ft,mt){mt===void 0&&(mt={});var ot={type:"Feature"};return(mt.id===0||mt.id)&&(ot.id=mt.id),mt.bbox&&(ot.bbox=mt.bbox),ot.properties=Ft||{},ot.geometry=Se,ot}function X(Se,Ft,mt){switch(mt===void 0&&(mt={}),Se){case"Point":return se(Ft).geometry;case"LineString":return De(Ft).geometry;case"Polygon":return ce(Ft).geometry;case"MultiPoint":return Ge(Ft).geometry;case"MultiLineString":return qe(Ft).geometry;case"MultiPolygon":return ct(Ft).geometry;default:throw new Error(Se+" is invalid")}}function se(Se,Ft,mt){if(mt===void 0&&(mt={}),!Se)throw new Error("coordinates is required");if(!Array.isArray(Se))throw new Error("coordinates must be an Array");if(Se.length<2)throw new Error("coordinates must be at least 2 numbers long");if(!pt(Se[0])||!pt(Se[1]))throw new Error("coordinates must contain numbers");var ot={type:"Point",coordinates:Se};return $(ot,Ft,mt)}function ae(Se,Ft,mt){return mt===void 0&&(mt={}),Ee(Se.map(function(ot){return se(ot,Ft)}),mt)}function ce(Se,Ft,mt){mt===void 0&&(mt={});for(var ot=0,We=Se;ot=0))throw new Error("precision must be a positive number");var mt=Math.pow(10,Ft||0);return Math.round(Se*mt)/mt}function Xe(Se,Ft){Ft===void 0&&(Ft="kilometers");var mt=V[Ft];if(!mt)throw new Error(Ft+" units is invalid");return Se*mt}function Rt(Se,Ft){Ft===void 0&&(Ft="kilometers");var mt=V[Ft];if(!mt)throw new Error(Ft+" units is invalid");return Se/mt}function gt(Se,Ft){return tt(Rt(Se,Ft))}function Ct(Se){var Ft=Se%360;return Ft<0&&(Ft+=360),Ft}function tt(Se){var Ft=Se%(2*Math.PI);return Ft*180/Math.PI}function Ne(Se){var Ft=Se%360;return Ft*Math.PI/180}function bt(Se,Ft,mt){if(Ft===void 0&&(Ft="kilometers"),mt===void 0&&(mt="kilometers"),!(Se>=0))throw new Error("length must be a positive number");return Xe(Rt(Se,Ft),mt)}function et(Se,Ft,mt){if(Ft===void 0&&(Ft="meters"),mt===void 0&&(mt="kilometers"),!(Se>=0))throw new Error("area must be a positive number");var ot=p[Ft];if(!ot)throw new Error("invalid original units");var We=p[mt];if(!We)throw new Error("invalid final units");return Se/ot*We}function pt(Se){return!isNaN(Se)&&Se!==null&&!Array.isArray(Se)}function Ke(Se){return!!Se&&Se.constructor===Object}function ft(Se){if(!Se)throw new Error("bbox is required");if(!Array.isArray(Se))throw new Error("bbox must be an Array");if(Se.length!==4&&Se.length!==6)throw new Error("bbox must be an Array of 4 or 6 numbers");Se.forEach(function(Ft){if(!pt(Ft))throw new Error("bbox must only contain numbers")})}function wt(Se){if(!Se)throw new Error("id is required");if(["string","number"].indexOf(typeof Se)===-1)throw new Error("id must be a number or a string")}},8014:function(Ye,ye,A){"use strict";A.d(ye,{c9:function(){return V},nK:function(){return X},r7:function(){return y},wA:function(){return ae}});var R=A(8822);function V(le){if(!le)throw new Error("coord is required");if(!Array.isArray(le)){if(le.type==="Feature"&&le.geometry!==null&&le.geometry.type==="Point")return le.geometry.coordinates;if(le.type==="Point")return le.coordinates}if(Array.isArray(le)&&le.length>=2&&!Array.isArray(le[0])&&!Array.isArray(le[1]))return le;throw new Error("coord must be GeoJSON Point or an Array of numbers")}function y(le){if(Array.isArray(le))return le;if(le.type==="Feature"){if(le.geometry!==null)return le.geometry.coordinates}else if(le.coordinates)return le.coordinates;throw new Error("coords must be GeoJSON Feature, Geometry Object or an Array")}function p(le){if(le.length>1&&isNumber(le[0])&&isNumber(le[1]))return!0;if(Array.isArray(le[0])&&le[0].length)return p(le[0]);throw new Error("coordinates must only contain numbers")}function $(le,De,we){if(!De||!we)throw new Error("type and name required");if(!le||le.type!==De)throw new Error("Invalid input to "+we+": must be a "+De+", given "+le.type)}function X(le,De,we){if(!le)throw new Error("No feature passed");if(!we)throw new Error(".featureOf() requires a name");if(!le||le.type!=="Feature"||!le.geometry)throw new Error("Invalid input to "+we+", Feature with geometry required");if(!le.geometry||le.geometry.type!==De)throw new Error("Invalid input to "+we+": must be a "+De+", given "+le.geometry.type)}function se(le,De,we){if(!le)throw new Error("No featureCollection passed");if(!we)throw new Error(".collectionOf() requires a name");if(!le||le.type!=="FeatureCollection")throw new Error("Invalid input to "+we+", FeatureCollection required");for(var Ee=0,qe=le.features;Eept||mt>Ke||ot>ft){et=wt,pt=Ct,Ke=mt,ft=ot,Ne=0;return}var We=lineString([et,wt],gt.properties);if(Rt(We,Ct,tt,ot,Ne)===!1)return!1;Ne++,et=wt})===!1)return!1}}})}function qe(Xe,Rt,gt){var Ct=gt,tt=!1;return Ee(Xe,function(Ne,bt,et,pt,Ke){tt===!1&>===void 0?Ct=Ne:Ct=Rt(Ct,Ne,bt,et,pt,Ke),tt=!0}),Ct}function Ge(Xe,Rt){if(!Xe)throw new Error("geojson is required");De(Xe,function(gt,Ct,tt){if(gt.geometry!==null){var Ne=gt.geometry.type,bt=gt.geometry.coordinates;switch(Ne){case"LineString":if(Rt(gt,Ct,tt,0,0)===!1)return!1;break;case"Polygon":for(var et=0;et=k?8:0,yt|=Je>=k?4:0,yt|=Nt>=k?2:0,yt|=Zt>=k?1:0;var nr=!1;if(yt===5||yt===10){var ur=(Et+Je+Nt+Zt)/4;yt===5&&ur=0;nr--)if(Math.abs(k[nr][0][0]-Nt)<=he&&Math.abs(k[nr][0][1]-Zt)<=he){for(var ur=Et.path.length-2;ur>=0;--ur)k[nr].unshift(Et.path[ur]);Je=!0;break}}Je||(k[Y++]=Et.path)}})}),k}function ct(I,k,Y){var he=I.length,be=[],Le=[0,0,1,1,0,0,0,0,-1,0,1,1,-1,0,-1,0],Be=[0,-1,0,0,1,1,1,1,0,-1,0,0,0,-1,0,0],yt,Et,Je=["none","left","bottom","left","right","none","bottom","left","top","top","none","top","right","right","bottom","none"],Nt=["none","bottom","right","right","top","top","top","top","left","bottom","right","right","left","bottom","left","none"],ur,Zt=I[k][Y],nr=Zt.cval,ur=Je[nr],bi=qe(Zt,ur);be.push([Y+bi[0],k+bi[1]]),ur=Nt[nr],bi=qe(Zt,ur),be.push([Y+bi[0],k+bi[1]]),Ee(Zt);for(var Gn=Y+Le[nr],mo=k+Be[nr],xi=nr;Gn>=0&&mo>=0&&mo3?polygon([he]):null}function bt(I,k,Y){if(Y===void 0&&(Y={}),!I)throw new Error("point is required");if(!k)throw new Error("polygon is required");var he=(0,y.c9)(I),be=(0,y.wA)(k),Le=be.type,Be=k.bbox,yt=be.coordinates;if(Be&&pt(he,Be)===!1)return!1;Le==="Polygon"&&(yt=[yt]);for(var Et=!1,Je=0;JeI[1]!=Je>I[1]&&I[0]<(Et-Be)*(I[1]-yt)/(Je-yt)+Be;Zt&&(he=!he)}return he}function pt(I,k){return k[0]<=I[0]&&k[1]<=I[1]&&k[2]>=I[0]&&k[3]>=I[1]}function Ke(I,k){var Y=[];return featureEach(I,function(he){var be=!1;if(he.geometry.type==="Point")geomEach(k,function(Be){pointInPolygon(he,Be)&&(be=!0)}),be&&Y.push(he);else if(he.geometry.type==="MultiPoint"){var Le=[];geomEach(k,function(Be){coordEach(he,function(yt){pointInPolygon(yt,Be)&&(be=!0,Le.push(yt))})}),be&&Y.push(multiPoint(Le))}else throw new Error("Input geometry must be a Point or MultiPoint")}),featureCollection(Y)}var ft=null;function wt(I,k,Y){Y===void 0&&(Y={});var he=getCoord(I),be=getCoord(k),Le=degreesToRadians(be[1]-he[1]),Be=degreesToRadians(be[0]-he[0]),yt=degreesToRadians(he[1]),Et=degreesToRadians(be[1]),Je=Math.pow(Math.sin(Le/2),2)+Math.pow(Math.sin(Be/2),2)*Math.cos(yt)*Math.cos(Et);return radiansToLength(2*Math.atan2(Math.sqrt(Je),Math.sqrt(1-Je)),Y.units)}var Se=null;function Ft(I,k){var Y=!1;return featureCollection(Me(I.features.map(function(he){var be={x:he.geometry.coordinates[0],y:he.geometry.coordinates[1]};return k?be.z=he.properties[k]:he.geometry.coordinates.length===3&&(Y=!0,be.z=he.geometry.coordinates[2]),be})).map(function(he){var be=[he.a.x,he.a.y],Le=[he.b.x,he.b.y],Be=[he.c.x,he.c.y],yt={};return Y?(be.push(he.a.z),Le.push(he.b.z),Be.push(he.c.z)):yt={a:he.a.z,b:he.b.z,c:he.c.z},polygon([[be,Le,Be,be]],yt)}))}var mt=function(){function I(k,Y,he){this.a=k,this.b=Y,this.c=he;var be=Y.x-k.x,Le=Y.y-k.y,Be=he.x-k.x,yt=he.y-k.y,Et=be*(k.x+Y.x)+Le*(k.y+Y.y),Je=Be*(k.x+he.x)+yt*(k.y+he.y),Nt=2*(be*(he.y-Y.y)-Le*(he.x-Y.x)),Zt,nr;this.x=(yt*Et-Le*Je)/Nt,this.y=(be*Je-Be*Et)/Nt,Zt=this.x-k.x,nr=this.y-k.y,this.r=Zt*Zt+nr*nr}return I}();function ot(I,k){return k.x-I.x}function We(I){var k=I.length,Y,he,be,Le,Be;e:for(;k;)for(he=I[--k],Y=I[--k],be=k;be;)if(Be=I[--be],Le=I[--be],Y===Le&&he===Be||Y===Be&&he===Le){I.splice(k,2),I.splice(be,2),k-=2;continue e}}function Me(I){if(I.length<3)return[];I.sort(ot);for(var k=I.length-1,Y=I[k].x,he=I[0].x,be=I[k].y,Le=be,Be=1e-12,yt,Et,Je,Nt,Zt,nr;k--;)I[k].yLe&&(Le=I[k].y);var ur=he-Y,bi=Le-be,Gn=ur>bi?ur:bi,mo=(he+Y)*.5,xi=(Le+be)*.5,Bn=[new mt({__sentinel:!0,x:mo-20*Gn,y:xi-Gn},{__sentinel:!0,x:mo,y:xi+20*Gn},{__sentinel:!0,x:mo+20*Gn,y:xi-Gn})],fi=[],Ro=[],So;for(k=I.length;k--;){for(Ro.length=0,So=Bn.length;So--;){if(ur=I[k].x-Bn[So].x,ur>0&&ur*ur>Bn[So].r){fi.push(Bn[So]),Bn.splice(So,1);continue}bi=I[k].y-Bn[So].y,!(ur*ur+bi*bi>Bn[So].r)&&(Ro.push(Bn[So].a,Bn[So].b,Bn[So].b,Bn[So].c,Bn[So].c,Bn[So].a),Bn.splice(So,1))}for(We(Ro),So=Ro.length;So;)Et=Ro[--So],yt=Ro[--So],Je=I[k],Nt=Et.x-yt.x,Zt=Et.y-yt.y,nr=2*(Nt*(Je.y-Et.y)-Zt*(Je.x-Et.x)),Math.abs(nr)>Be&&Bn.push(new mt(yt,Et,Je))}for(Array.prototype.push.apply(fi,Bn),k=fi.length;k--;)(fi[k].a.__sentinel||fi[k].b.__sentinel||fi[k].c.__sentinel)&&fi.splice(k,1);return fi}function st(I,k){if(k===void 0&&(k={}),k=k||{},!isObject(k))throw new Error("options is invalid");var Y=k.mutate;if(getType(I)!=="FeatureCollection")throw new Error("geojson must be a FeatureCollection");if(!I.features.length)throw new Error("geojson is empty");(Y===!1||Y===void 0)&&(I=clone(I));var he=[],be=lineReduce(I,function(Le,Be){var yt=dr(Le,Be);return yt||(he.push(Le),Be)});return be&&he.push(be),he.length?he.length===1?he[0]:multiLineString(he.map(function(Le){return Le.coordinates})):null}function Qe(I){return I[0].toString()+","+I[1].toString()}function dr(I,k){var Y=I.geometry.coordinates,he=k.geometry.coordinates,be=Qe(Y[0]),Le=Qe(Y[Y.length-1]),Be=Qe(he[0]),yt=Qe(he[he.length-1]),Et;if(be===yt)Et=he.concat(Y.slice(1));else if(Be===Le)Et=Y.concat(he.slice(1));else if(be===Be)Et=Y.slice(1).reverse().concat(he);else if(Le===yt)Et=Y.concat(he.reverse().slice(1));else return null;return lineString(Et)}var Kt=null,Yr=Object.prototype.hasOwnProperty;function hn(I){var k=1/0,Y=1/0,he=-1/0,be=-1/0;function Le(Zt){Zt!=null&&hasOwnProperty.call(Be,Zt.type)&&Be[Zt.type](Zt)}var Be={GeometryCollection:function(Zt){Zt.geometries.forEach(Le)},Point:function(Zt){yt(Zt.coordinates)},MultiPoint:function(Zt){Zt.coordinates.forEach(yt)},LineString:function(Zt){Et(Zt.arcs)},MultiLineString:function(Zt){Zt.arcs.forEach(Et)},Polygon:function(Zt){Zt.arcs.forEach(Et)},MultiPolygon:function(Zt){Zt.arcs.forEach(Je)}};function yt(Zt){var nr=Zt[0],ur=Zt[1];nrhe&&(he=nr),urbe&&(be=ur)}function Et(Zt){Zt.forEach(yt)}function Je(Zt){Zt.forEach(Et)}for(var Nt in I)Le(I[Nt]);return he>=k&&be>=Y?[k,Y,he,be]:void 0}var ln=new ArrayBuffer(16),oi=new Float64Array(ln),Nn=new Uint32Array(ln);function $n(I){oi[0]=I[0],oi[1]=I[1];var k=Nn[0]^Nn[1];return k=k<<5^k>>7^Nn[2]^Nn[3],k&2147483647}function _i(I){var k=I.coordinates,Y=I.lines,he=I.rings,be=ia(),Le=new Int32Array(k.length),Be=new Int32Array(k.length),yt=new Int32Array(k.length),Et=new Int8Array(k.length),Je=0,Nt,Zt,nr,ur,bi;for(Nt=0,Zt=k.length;Nt=0){var wf=yt[Wh];(Uf!==Bh||wf!==Fl)&&(Uf!==Fl||wf!==Bh)&&(++Je,Et[Wh]=1)}else Be[Wh]=Bh,yt[Wh]=Fl}}function ia(){for(var Zl=hashmap(k.length*1.4,Jo,ka,Int32Array,-1,Int32Array),Bh=new Int32Array(k.length),Wh=0,Fl=k.length;Wh>1),be;k0&&Y&&prequantize(I,Y,k),be=dedup(cut(extract(I))),Le=be.coordinates,Be=hashmap(be.arcs.length*1.4,En,or);I=be.objects,be.bbox=Y,be.arcs=be.arcs.map(function(nr,ur){return Be.set(nr,ur),Le.slice(nr[0],nr[1]+1)}),delete be.coordinates,Le=null;function yt(nr){nr&&hasOwnProperty.call(Et,nr.type)&&Et[nr.type](nr)}var Et={GeometryCollection:function(nr){nr.geometries.forEach(yt)},LineString:function(nr){nr.arcs=Je(nr.arcs)},MultiLineString:function(nr){nr.arcs=nr.arcs.map(Je)},Polygon:function(nr){nr.arcs=nr.arcs.map(Je)},MultiPolygon:function(nr){nr.arcs=nr.arcs.map(Nt)}};function Je(nr){var ur=[];do{var bi=Be.get(nr);ur.push(nr[0]2&&ir(Y[be-3],Y[be-1],Y[be-2])&&Y.splice(Y.length-2,1))}if(Y.push(k[k.length-1]),be=Y.length,kt(k[0],k[k.length-1])&&be<4)throw new Error("invalid polygon");return ir(Y[be-3],Y[be-1],Y[be-2])&&Y.splice(Y.length-2,1),Y}function kt(I,k){return I[0]===k[0]&&I[1]===k[1]}function ir(I,k,Y){var he=Y[0],be=Y[1],Le=I[0],Be=I[1],yt=k[0],Et=k[1],Je=he-Le,Nt=be-Be,Zt=yt-Le,nr=Et-Be,ur=Je*nr-Nt*Zt;return ur!==0?!1:Math.abs(Zt)>=Math.abs(nr)?Zt>0?Le<=he&&he<=yt:yt<=he&&he<=Le:nr>0?Be<=be&&be<=Et:Et<=be&&be<=Be}var Pr=null;function kr(I,k){var Y=I.x-k.x,he=I.y-k.y;return Y*Y+he*he}function An(I,k,Y){var he=k.x,be=k.y,Le=Y.x-he,Be=Y.y-be;if(Le!==0||Be!==0){var yt=((I.x-he)*Le+(I.y-be)*Be)/(Le*Le+Be*Be);yt>1?(he=Y.x,be=Y.y):yt>0&&(he+=Le*yt,be+=Be*yt)}return Le=I.x-he,Be=I.y-be,Le*Le+Be*Be}function Dn(I,k){for(var Y=I[0],he=[Y],be,Le=1,Be=I.length;Lek&&(he.push(be),Y=be);return Y!==be&&he.push(be),he}function Ht(I,k,Y,he,be){for(var Le=he,Be,yt=k+1;ytLe&&(Be=yt,Le=Et)}Le>he&&(Be-k>1&&Ht(I,k,Be,he,be),be.push(I[Be]),Y-Be>1&&Ht(I,Be,Y,he,be))}function Lt(I,k){var Y=I.length-1,he=[I[0]];return Ht(I,0,Y,k,he),he.push(I[Y]),he}function je(I,k,Y){if(I.length<=2)return I;var he=k!==void 0?k*k:1;return I=Y?I:Dn(I,he),I=Lt(I,he),I}function $e(I,k){if(k=k||{},!isObject(k))throw new Error("options is invalid");var Y=k.tolerance!==void 0?k.tolerance:1,he=k.highQuality||!1,be=k.mutate||!1;if(!I)throw new Error("geojson is required");if(Y&&Y<0)throw new Error("invalid tolerance");return be!==!0&&(I=clone(I)),geomEach(I,function(Le){At(Le,Y,he)}),I}function At(I,k,Y){var he=I.type;if(he==="Point"||he==="MultiPoint")return I;cleanCoords(I,!0);var be=I.coordinates;switch(he){case"LineString":I.coordinates=Bt(be,k,Y);break;case"MultiLineString":I.coordinates=be.map(function(Le){return Bt(Le,k,Y)});break;case"Polygon":I.coordinates=Jt(be,k,Y);break;case"MultiPolygon":I.coordinates=be.map(function(Le){return Jt(Le,k,Y)})}return I}function Bt(I,k,Y){return je(I.map(function(he){return{x:he[0],y:he[1],z:he[2]}}),k,Y).map(function(he){return he.z?[he.x,he.y,he.z]:[he.x,he.y]})}function Jt(I,k,Y){return I.map(function(he){var be=he.map(function(Be){return{x:Be[0],y:Be[1]}});if(be.length<4)throw new Error("invalid polygon");for(var Le=je(be,k,Y).map(function(Be){return[Be.x,Be.y]});!ar(Le);)k-=k*.01,Le=je(be,k,Y).map(function(Be){return[Be.x,Be.y]});return(Le[Le.length-1][0]!==Le[0][0]||Le[Le.length-1][1]!==Le[0][1])&&Le.push(Le[0]),Le})}function ar(I){return I.length<3?!1:!(I.length===3&&I[2][0]===I[0][0]&&I[2][1]===I[0][1])}var hr=null,Gt=function(){function I(k){this.points=k.points||[],this.duration=k.duration||1e4,this.sharpness=k.sharpness||.85,this.centers=[],this.controls=[],this.stepLength=k.stepLength||60,this.length=this.points.length,this.delay=0;for(var Y=0;Yk&&(Y.push(be),he=Le)}return Y},I.prototype.vector=function(k){var Y=this.pos(k+10),he=this.pos(k-10);return{angle:180*Math.atan2(Y.y-he.y,Y.x-he.x)/3.14,speed:Math.sqrt((he.x-Y.x)*(he.x-Y.x)+(he.y-Y.y)*(he.y-Y.y)+(he.z-Y.z)*(he.z-Y.z))}},I.prototype.pos=function(k){var Y=k-this.delay;Y<0&&(Y=0),Y>this.duration&&(Y=this.duration-1);var he=Y/this.duration;if(he>=1)return this.points[this.length-1];var be=Math.floor((this.points.length-1)*he),Le=(this.length-1)*he-be;return nn(Le,this.points[be],this.controls[be][1],this.controls[be+1][0],this.points[be+1])},I}(),Tr=null;function nn(I,k,Y,he,be){var Le=bn(I),Be={x:be.x*Le[0]+he.x*Le[1]+Y.x*Le[2]+k.x*Le[3],y:be.y*Le[0]+he.y*Le[1]+Y.y*Le[2]+k.y*Le[3],z:be.z*Le[0]+he.z*Le[1]+Y.z*Le[2]+k.z*Le[3]};return Be}function bn(I){var k=I*I,Y=k*I;return[Y,3*k*(1-I),3*I*(1-I)*(1-I),(1-I)*(1-I)*(1-I)]}function Bi(I,k){k===void 0&&(k={});for(var Y=k.resolution||1e4,he=k.sharpness||.85,be=[],Le=getGeom(I).coordinates.map(function(Je){return{x:Je[0],y:Je[1]}}),Be=new Spline({duration:Y,points:Le,sharpness:he}),yt=function(Je){var Nt=Be.pos(Je);Math.floor(Je/100)%2===0&&be.push([Nt.x,Nt.y])},Et=0;Etbe;)Be=Math.floor((he+1)*Math.random()),Le=Y[Be],Y[Be]=Y[he],Y[he]=Le;return Y.slice(be)}var di=null,zi=A(39511);function Gi(I){return(0,zi.Z)((0,R.Z)(I))}var Lo=Gi;function eo(I){var k=I[0],Y=I[1],he=I[2],be=I[3],Le=distance(I.slice(0,2),[he,Y]),Be=distance(I.slice(0,2),[k,be]);if(Le>=Be){var yt=(Y+be)/2;return[k,yt-(he-k)/2,he,yt+(he-k)/2]}else{var Et=(k+he)/2;return[Et-(be-Y)/2,Y,Et+(be-Y)/2,be]}}var ba=null;function va(I,k,Y,he){he===void 0&&(he={});var be=getCoord(I),Le=degreesToRadians(be[0]),Be=degreesToRadians(be[1]),yt=degreesToRadians(Y),Et=lengthToRadians(k,he.units),Je=Math.asin(Math.sin(Be)*Math.cos(Et)+Math.cos(Be)*Math.sin(Et)*Math.cos(yt)),Nt=Le+Math.atan2(Math.sin(yt)*Math.sin(Et)*Math.cos(Be),Math.cos(Et)-Math.sin(Be)*Math.sin(Je)),Zt=radiansToDegrees(Nt),nr=radiansToDegrees(Je);return point([Zt,nr],he.properties)}function Do(I,k,Y){Y===void 0&&(Y={});for(var he=Y.steps||64,be=Y.properties?Y.properties:!Array.isArray(I)&&I.type==="Feature"&&I.properties?I.properties:{},Le=[],Be=0;Be0&&(he+=I[be-1].length,Y.holes.push(he))}return Y}var el=null;function fl(I,k){if(!I)throw new Error("targetPoint is required");if(!k)throw new Error("points is required");var Y,he=1/0,be=0;return featureEach(k,function(Le,Be){var yt=distance(I,Le);ytbe?Y:be,Je=he>Le?he:Le;return[Be,yt,Et,Je]}var Pn=null,Wr=A(56898);function Ci(I,k){var Y={},he=[];if(I.type==="LineString"&&(I=feature(I)),k.type==="LineString"&&(k=feature(k)),I.type==="Feature"&&k.type==="Feature"&&I.geometry!==null&&k.geometry!==null&&I.geometry.type==="LineString"&&k.geometry.type==="LineString"&&I.geometry.coordinates.length===2&&k.geometry.coordinates.length===2){var be=at(I,k);return be&&he.push(be),featureCollection(he)}var Le=rbush();return Le.load(lineSegment(k)),featureEach(lineSegment(I),function(Be){featureEach(Le.search(Be),function(yt){var Et=at(Be,yt);if(Et){var Je=getCoords(Et).join(",");Y[Je]||(Y[Je]=!0,he.push(Et))}})}),featureCollection(he)}function at(I,k){var Y=getCoords(I),he=getCoords(k);if(Y.length!==2)throw new Error(" line1 must only contain 2 coordinates");if(he.length!==2)throw new Error(" line2 must only contain 2 coordinates");var be=Y[0][0],Le=Y[0][1],Be=Y[1][0],yt=Y[1][1],Et=he[0][0],Je=he[0][1],Nt=he[1][0],Zt=he[1][1],nr=(Zt-Je)*(Be-be)-(Nt-Et)*(yt-Le),ur=(Nt-Et)*(Le-Je)-(Zt-Je)*(be-Et),bi=(Be-be)*(Le-Je)-(yt-Le)*(be-Et);if(nr===0)return null;var Gn=ur/nr,mo=bi/nr;if(Gn>=0&&Gn<=1&&mo>=0&&mo<=1){var xi=be+Gn*(Be-be),Bn=Le+Gn*(yt-Le);return point([xi,Bn])}return null}var Vt=null;function gr(I,k,Y){Y===void 0&&(Y={});var he=point([1/0,1/0],{dist:1/0}),be=0;return flattenEach(I,function(Le){for(var Be=getCoords(Le),yt=0;yt0&&(mo=Gn.features[0],mo.properties.dist=distance(k,mo,Y),mo.properties.location=be+distance(Et,mo,Y)),Et.properties.dist180?-360:he[0]-be[0]>180?360:0;var Le=Zi(he,be),Be=convertLength(Le,"meters",Y.units);return Be}function Zi(I,k,Y){Y=Y===void 0?earthRadius:Number(Y);var he=Y,be=I[1]*Math.PI/180,Le=k[1]*Math.PI/180,Be=Le-be,yt=Math.abs(k[0]-I[0])*Math.PI/180;yt>Math.PI&&(yt-=2*Math.PI);var Et=Math.log(Math.tan(Le/2+Math.PI/4)/Math.tan(be/2+Math.PI/4)),Je=Math.abs(Et)>1e-11?Be/Et:Math.cos(be),Nt=Math.sqrt(Be*Be+Je*Je*yt*yt),Zt=Nt*he;return Zt}var ho=null;function Na(I,k,Y){if(Y===void 0&&(Y={}),Y.method||(Y.method="geodesic"),Y.units||(Y.units="kilometers"),!I)throw new Error("pt is required");if(Array.isArray(I)?I=point(I):I.type==="Point"?I=feature(I):featureOf(I,"Point","point"),!k)throw new Error("line is required");Array.isArray(k)?k=lineString(k):k.type==="LineString"?k=feature(k):featureOf(k,"LineString","line");var he=1/0,be=I.geometry.coordinates;return segmentEach(k,function(Le){var Be=Le.geometry.coordinates[0],yt=Le.geometry.coordinates[1],Et=mn(be,Be,yt,Y);Et=0&&Je<=1&&(ur.onLine1=!0),Nt>=0&&Nt<=1&&(ur.onLine2=!0),ur.onLine1&&ur.onLine2?[ur.x,ur.y]:!1)}function Ho(I){for(var k=ya(I),Y=centroid(k),he=!1,be=0;!he&&be0){k+=Math.abs(ns(I[0]));for(var Y=1;Y2){for(yt=0;yt=Le&&Be===be.length-1);Be++)if(Le>=k){var yt=k-Le;if(yt){var Et=bearing(be[Be],be[Be-1])-180,Je=destination(be[Be],yt,Et,Y);return Je}else return point(be[Be])}else Le+=measureDistance(be[Be],be[Be+1],Y);return point(be[be.length-1])}function Js(I,k){return k===void 0&&(k={}),segmentReduce(I,function(Y,he){var be=he.geometry.coordinates;return Y+distance(be[0],be[1],k)},0)}function Hu(I,k,Y){var he=getCoords(Y);if(getType(Y)!=="LineString")throw new Error("line must be a LineString");var be=nearestPointOnLine(Y,I),Le=nearestPointOnLine(Y,k),Be;be.properties.index<=Le.properties.index?Be=[be,Le]:Be=[Le,be];for(var yt=[Be[0].geometry.coordinates],Et=Be[0].properties.index+1;Et=yt&&Zt===be.length-1);Zt++){if(yt>k&&Le.length===0){if(Et=k-yt,!Et)return Le.push(be[Zt]),lineString(Le);Je=bearing(be[Zt],be[Zt-1])-180,Nt=destination(be[Zt],Et,Je,he),Le.push(Nt.geometry.coordinates)}if(yt>=Y)return Et=Y-yt,Et?(Je=bearing(be[Zt],be[Zt-1])-180,Nt=destination(be[Zt],Et,Je,he),Le.push(Nt.geometry.coordinates),lineString(Le)):(Le.push(be[Zt]),lineString(Le));if(yt>=k&&Le.push(be[Zt]),Zt===be.length-1)return lineString(Le);yt+=distance(be[Zt],be[Zt+1],he)}if(ytbe)return!1}else if(Gn!==0)return!1;if(he){if(he==="start")return Math.abs(ur)>=Math.abs(bi)?ur>0?yt0?Et=Math.abs(bi)?ur>0?yt<=Le&&Le0?Et<=Be&&Be=Math.abs(bi)?ur>0?yt0?Et=Math.abs(bi)?ur>0?yt<=Le&&Le<=Je:Je<=Le&&Le<=yt:bi>0?Et<=Be&&Be<=Nt:Nt<=Be&&Be<=Et;return!1}var oo=null;function io(I,k){var Y=getGeom(I),he=getGeom(k),be=Y.type,Le=he.type;switch(be){case"Point":switch(Le){case"MultiPoint":return Uo(Y,he);case"LineString":return booleanPointOnLine(Y,he,{ignoreEndVertices:!0});case"Polygon":case"MultiPolygon":return booleanPointInPolygon(Y,he,{ignoreBoundary:!0});default:throw new Error("feature2 "+Le+" geometry not supported")}case"MultiPoint":switch(Le){case"MultiPoint":return na(Y,he);case"LineString":return $a(Y,he);case"Polygon":case"MultiPolygon":return Co(Y,he);default:throw new Error("feature2 "+Le+" geometry not supported")}case"LineString":switch(Le){case"LineString":return wo(Y,he);case"Polygon":case"MultiPolygon":return Pa(Y,he);default:throw new Error("feature2 "+Le+" geometry not supported")}case"Polygon":switch(Le){case"Polygon":case"MultiPolygon":return ss(Y,he);default:throw new Error("feature2 "+Le+" geometry not supported")}default:throw new Error("feature1 "+be+" geometry not supported")}}function Uo(I,k){var Y,he=!1;for(Y=0;Yk[0]||I[2]k[1]||I[3] is required");if(typeof Y!="number")throw new Error(" must be a number");if(typeof he!="number")throw new Error(" must be a number");(be===!1||be===void 0)&&(I=JSON.parse(JSON.stringify(I)));var Le=Math.pow(10,Y);return coordEach(I,function(Be){su(Be,Le,he)}),I}function su(I,k,Y){I.length>Y&&I.splice(Y,I.length);for(var he=0;he=1||ph<=0||Zl>=1||Zl<=0)){var Bh=Ui,Wh=!Le[Bh];Wh&&(Le[Bh]=!0),k?be.push(k(Ui,xi,Bn,So,ia,ph,fi,Ro,Jo,ka,Zl,Wh)):be.push(Ui)}}}function mo(xi,Bn){var fi=he[xi][Bn],Ro=he[xi][Bn+1],So,ia,Jo,ka;return fi[0]Et[Jp.isect].coord?-1:1});for(var Jo=[];xi.length>0;){var ka=xi.pop(),Ui=ka.isect,ph=ka.parent,Zl=ka.winding,Bh=Jo.length,Wh=[Et[Ui].coord],Fl=Ui;if(Et[Ui].ringAndEdge1Walkable)var Uf=Et[Ui].ringAndEdge1,wf=Et[Ui].nxtIsectAlongRingAndEdge1;else var Uf=Et[Ui].ringAndEdge2,wf=Et[Ui].nxtIsectAlongRingAndEdge2;for(;!ps(Et[Ui].coord,Et[wf].coord);){Wh.push(Et[wf].coord);for(var lp=void 0,Bn=0;Bn1)for(var Jp=0;Jp=0==k}function Qo(I){for(var k=0,Y=0;Ynr&&(Gn>Nt&&biNt&&GnEt&&(Et=mo)}var xi=[];if(yt&&Et0&&Math.abs(Ro-Y[fi-1][0])>nr){var So=parseFloat(Y[fi-1][0]),ia=parseFloat(Y[fi-1][1]),Jo=parseFloat(Y[fi][0]),ka=parseFloat(Y[fi][1]);if(So>-180&&So-180&&Y[fi-1][0]Nt&&So<180&&Jo===-180&&fi+1Nt&&Y[fi-1][0]<180){Bn.push([180,Y[fi][1]]),fi++,Bn.push([Y[fi][0],Y[fi][1]]);continue}if(SoNt){var Ui=So;So=Jo,Jo=Ui;var ph=ia;ia=ka,ka=ph}if(So>Nt&&Jo=180&&SoNt?180:-180,Bh]),Bn=[],Bn.push([Y[fi-1][0]>Nt?-180:180,Bh]),xi.push(Bn)}else Bn=[],xi.push(Bn);Bn.push([Ro,Y[fi][1]])}else Bn.push([Y[fi][0],Y[fi][1]])}}else{var Wh=[];xi.push(Wh);for(var Fl=0;Fl1&&Y.push(lineString(Nt)),featureCollection(Y)}function to(I,k){if(!k.features.length)throw new Error("lines must contain features");if(k.features.length===1)return k.features[0];var Y,he=1/0;return featureEach(k,function(be){var Le=nearestPointOnLine(be,I),Be=Le.properties.dist;BeNt&&nr.push(destination(I,k,Nt,be).geometry.coordinates),lineString(nr,Et)}function fa(I){var k=I%360;return k<0&&(k+=360),k}function cs(I,k){k===void 0&&(k={});var Y=getGeom(I);switch(!k.properties&&I.type==="Feature"&&(k.properties=I.properties),Y.type){case"Polygon":return Ys(Y,k);case"MultiPolygon":return mu(Y,k);default:throw new Error("invalid poly")}}function Ys(I,k){k===void 0&&(k={});var Y=getGeom(I),he=Y.coordinates,be=k.properties?k.properties:I.type==="Feature"?I.properties:{};return Is(he,be)}function mu(I,k){k===void 0&&(k={});var Y=getGeom(I),he=Y.coordinates,be=k.properties?k.properties:I.type==="Feature"?I.properties:{},Le=[];return he.forEach(function(Be){Le.push(Is(Be,be))}),featureCollection(Le)}function Is(I,k){return I.length>1?multiLineString(I,k):lineString(I[0],k)}function Sl(I,k){k===void 0&&(k={});var Y,he,be,Le=k.properties,Be=(Y=k.autoComplete)!==null&&Y!==void 0?Y:!0,yt=(he=k.orderCoords)!==null&&he!==void 0?he:!0,Et=(be=k.mutate)!==null&&be!==void 0?be:!1;switch(Et||(I=clone(I)),I.type){case"FeatureCollection":var Je=[];return I.features.forEach(function(Nt){Je.push(getCoords(wl(Nt,{},Be,yt)))}),multiPolygon(Je,Le);default:return wl(I,Le,Be,yt)}}function wl(I,k,Y,he){k=k||(I.type==="Feature"?I.properties:{});var be=getGeom(I),Le=be.coordinates,Be=be.type;if(!Le.length)throw new Error("line must contain coordinates");switch(Be){case"LineString":return Y&&(Le=vu(Le)),polygon([Le],k);case"MultiLineString":var yt=[],Et=0;return Le.forEach(function(Je){if(Y&&(Je=vu(Je)),he){var Nt=ml(turfBBox(lineString(Je)));Nt>Et?(yt.unshift(Je),Et=Nt):yt.push(Je)}else yt.push(Je)}),polygon(yt,k);default:throw new Error("geometry type "+Be+" is not supported")}}function vu(I){var k=I[0],Y=k[0],he=k[1],be=I[I.length-1],Le=be[0],Be=be[1];return(Y!==Le||he!==Be)&&I.push(k),I}function ml(I){var k=I[0],Y=I[1],he=I[2],be=I[3];return Math.abs(k-he)*Math.abs(Y-be)}var ll=null;function Fu(I,k){var Y=getGeom(I),he=Y.type,be=I.type==="Feature"?I.properties:{},Le=Y.coordinates;switch(he){case"LineString":case"MultiLineString":{var Be=[];return he==="LineString"&&(Le=[Le]),Le.forEach(function(yt){lineclip(yt,k,Be)}),Be.length===1?lineString(Be[0],be):multiLineString(Be,be)}case"Polygon":return polygon(Bu(Le,k),be);case"MultiPolygon":return multiPolygon(Le.map(function(yt){return Bu(yt,k)}),be);default:throw new Error("geometry "+he+" not supported")}}function Bu(I,k){for(var Y=[],he=0,be=I;he0&&((Be[0][0]!==Be[Be.length-1][0]||Be[0][1]!==Be[Be.length-1][1])&&Be.push(Be[0]),Be.length>=4&&Y.push(Be))}return Y}var al=A(19545);function Ac(I,k,Y){if(Y===void 0&&(Y={}),Y=Y||{},!isObject(Y))throw new Error("options is invalid");var he=Y.tolerance||0,be=[],Le=rbush(),Be=lineSegment(I);Le.load(Be);var yt;return segmentEach(k,function(Et){var Je=!1;Et&&(featureEach(Le.search(Et),function(Nt){if(Je===!1){var Zt=getCoords(Et).sort(),nr=getCoords(Nt).sort();equal(Zt,nr)||(he===0?booleanPointOnLine(Zt[0],Nt)&&booleanPointOnLine(Zt[1],Nt):nearestPointOnLine(Nt,Zt[0]).properties.dist<=he&&nearestPointOnLine(Nt,Zt[1]).properties.dist<=he)?(Je=!0,yt?yt=$l(yt,Et):yt=Et):(he===0?booleanPointOnLine(nr[0],Et)&&booleanPointOnLine(nr[1],Et):nearestPointOnLine(Et,nr[0]).properties.dist<=he&&nearestPointOnLine(Et,nr[1]).properties.dist<=he)&&(yt?yt=$l(yt,Nt):yt=Nt)}}),Je===!1&&yt&&(be.push(yt),yt=void 0))}),yt&&be.push(yt),featureCollection(be)}function $l(I,k){var Y=getCoords(k),he=getCoords(I),be=he[0],Le=he[he.length-1],Be=I.geometry.coordinates;return equal(Y[0],be)?Be.unshift(Y[1]):equal(Y[0],Le)?Be.push(Y[1]):equal(Y[1],be)?Be.unshift(Y[0]):equal(Y[1],Le)&&Be.push(Y[0]),I}var Yu=null;function Gu(I,k,Y,he,be){if(be=be||{},!isObject(be))throw new Error("options is invalid");var Le=be.properties;if(!I)throw new Error("center is required");if(Y==null)throw new Error("bearing1 is required");if(he==null)throw new Error("bearing2 is required");if(!k)throw new Error("radius is required");if(typeof be!="object")throw new Error("options must be an object");if(Sf(Y)===Sf(he))return circle(I,k,be);var Be=getCoords(I),yt=lineArc(I,k,Y,he,be),Et=[[Be]];return coordEach(yt,function(Je){Et[0].push(Je)}),Et[0].push(Be),polygon(Et,Le)}function Sf(I){var k=I%360;return k<0&&(k+=360),k}var Cl=null;function Df(I,k,Y){Y===void 0&&(Y={});var he;Y.final?he=bu(getCoord(k),getCoord(I)):he=bu(getCoord(I),getCoord(k));var be=he>180?-(360-he):he;return be}function bu(I,k){var Y=degreesToRadians(I[1]),he=degreesToRadians(k[1]),be=degreesToRadians(k[0]-I[0]);be>Math.PI&&(be-=2*Math.PI),be<-Math.PI&&(be+=2*Math.PI);var Le=Math.log(Math.tan(he/2+Math.PI/4)/Math.tan(Y/2+Math.PI/4)),Be=Math.atan2(be,Le);return(radiansToDegrees(Be)+360)%360}var Ic=null;function af(I,k,Y,he){he===void 0&&(he={});var be=k<0,Le=convertLength(Math.abs(k),he.units,"meters");be&&(Le=-Math.abs(Le));var Be=getCoord(I),yt=zf(Be,Le,Y);return yt[0]+=yt[0]-Be[0]>180?-360:Be[0]-yt[0]>180?360:0,point(yt,he.properties)}function zf(I,k,Y,he){he=he===void 0?earthRadius:Number(he);var be=k/he,Le=I[0]*Math.PI/180,Be=degreesToRadians(I[1]),yt=degreesToRadians(Y),Et=be*Math.cos(yt),Je=Be+Et;Math.abs(Je)>Math.PI/2&&(Je=Je>0?Math.PI-Je:-Math.PI-Je);var Nt=Math.log(Math.tan(Je/2+Math.PI/4)/Math.tan(Be/2+Math.PI/4)),Zt=Math.abs(Nt)>1e-11?Et/Nt:Math.cos(Be),nr=be*Math.sin(yt)/Zt,ur=Le+nr;return[(ur*180/Math.PI+540)%360-180,Je*180/Math.PI]}var tf=null;function kf(I,k){var Y=getCoords(I),he=getCoords(k),be,Le,Be,yt,Et=calcBbox(k),Je=0,Nt=null;Y[0]>Et[0]&&Y[0]Et[1]&&Y[1]0?wc(k,yt,be)||(be=yt):Y>0&&he<=0&&(vf(k,yt,Le)||(Le=yt)),Y=he}return[be,Le]}function vf(I,k,Y){return ac(I,k,Y)>0}function wc(I,k,Y){return ac(I,k,Y)<0}function ac(I,k,Y){return(k[0]-I[0])*(Y[1]-I[1])-(Y[0]-I[0])*(k[1]-I[1])}var cl=null;function Us(I){for(var k=getCoords(I),Y=0,he=1,be,Le;he0}function vl(I,k){if(k=k||{},!isObject(k))throw new Error("options is invalid");var Y=k.reverse||!1,he=k.mutate||!1;if(!I)throw new Error(" is required");if(typeof Y!="boolean")throw new Error(" must be a boolean");if(typeof he!="boolean")throw new Error(" must be a boolean");he===!1&&(I=clone(I));var be=[];switch(I.type){case"GeometryCollection":return geomEach(I,function(Le){iu(Le,Y)}),I;case"FeatureCollection":return featureEach(I,function(Le){featureEach(iu(Le,Y),function(Be){be.push(Be)})}),featureCollection(be)}return iu(I,Y)}function iu(I,k){var Y=I.type==="Feature"?I.geometry.type:I.type;switch(Y){case"GeometryCollection":return geomEach(I,function(he){iu(he,k)}),I;case"LineString":return Ca(getCoords(I),k),I;case"Polygon":return xa(getCoords(I),k),I;case"MultiLineString":return getCoords(I).forEach(function(he){Ca(he,k)}),I;case"MultiPolygon":return getCoords(I).forEach(function(he){xa(he,k)}),I;case"Point":case"MultiPoint":return I}}function Ca(I,k){booleanClockwise(I)===k&&I.reverse()}function xa(I,k){booleanClockwise(I[0])!==k&&I[0].reverse();for(var Y=1;Y-1}function Ai(I,k,Y){for(var he=I.length-1,be=I[0].length-1,Le={rows:he,cols:be,cells:[]},Be=k+Math.abs(Y),yt=0;ytBe?128:64,Je|=ZtBe?32:16,Je|=nrBe?8:4,Je|=urBe?2:1;var bi=+Je,Gn=0;if(Je===17||Je===18||Je===33||Je===34||Je===38||Je===68||Je===72||Je===98||Je===102||Je===132||Je===136||Je===137||Je===152||Je===153){var mo=(Nt+Zt+nr+ur)/4;Gn=mo>Be?2:mo0?(Je=156,Gn=4):Je=152:Je===33?Gn>0?(Je=139,Gn=4):Je=137:Je===72?Gn>0?(Je=99,Gn=4):Je=98:Je===132&&(Gn>0?(Je=39,Gn=4):Je=38)}if(Je!=0&&Je!=170){var xi,Bn,fi,Ro,So,ia,Jo,ka;xi=Bn=fi=Ro=So=ia=Jo=ka=.5;var Ui=[];Je===1?(fi=1-qt(k,nr,ur),ka=1-qt(k,Nt,ur),Ui.push(pr[Je])):Je===169?(fi=qt(Be,ur,nr),ka=qt(Be,ur,Nt),Ui.push(pr[Je])):Je===4?(ia=1-qt(k,Zt,nr),Ro=qt(k,ur,nr),Ui.push(Qt[Je])):Je===166?(ia=qt(Be,nr,Zt),Ro=1-qt(Be,nr,ur),Ui.push(Qt[Je])):Je===16?(So=qt(k,nr,Zt),Bn=qt(k,Nt,Zt),Ui.push(Tt[Je])):Je===154?(So=1-qt(Be,Zt,nr),Bn=1-qt(Be,Zt,Nt),Ui.push(Tt[Je])):Je===64?(Jo=qt(k,ur,Nt),xi=1-qt(k,Zt,Nt),Ui.push(jr[Je])):Je===106?(Jo=1-qt(Be,Nt,ur),xi=qt(Be,Nt,Zt),Ui.push(jr[Je])):Je===168?(Ro=qt(Be,ur,nr),fi=qt(k,ur,nr),ka=qt(k,ur,Nt),Jo=qt(Be,ur,Nt),Ui.push(cr[Je]),Ui.push(pr[Je])):Je===2?(Ro=1-qt(k,nr,ur),fi=1-qt(Be,nr,ur),ka=1-qt(Be,Nt,ur),Jo=1-qt(k,Nt,ur),Ui.push(cr[Je]),Ui.push(pr[Je])):Je===162?(So=qt(Be,nr,Zt),ia=qt(k,nr,Zt),Ro=1-qt(k,nr,ur),fi=1-qt(Be,nr,ur),Ui.push(cr[Je]),Ui.push(pr[Je])):Je===8?(So=1-qt(k,Zt,nr),ia=1-qt(Be,Zt,nr),Ro=qt(Be,ur,nr),fi=qt(k,ur,nr),Ui.push(Tt[Je]),Ui.push(Qt[Je])):Je===138?(So=1-qt(k,Zt,nr),ia=1-qt(Be,Zt,nr),xi=1-qt(Be,Zt,Nt),Bn=1-qt(k,Zt,Nt),Ui.push(Tt[Je]),Ui.push(Qt[Je])):Je===32?(So=qt(Be,nr,Zt),ia=qt(k,nr,Zt),xi=qt(k,Nt,Zt),Bn=qt(Be,Nt,Zt),Ui.push(Tt[Je]),Ui.push(Qt[Je])):Je===42?(ka=1-qt(Be,Nt,ur),Jo=1-qt(k,Nt,ur),xi=qt(k,Nt,Zt),Bn=qt(Be,Nt,Zt),Ui.push(zr[Je]),Ui.push(jr[Je])):Je===128&&(ka=qt(k,ur,Nt),Jo=qt(Be,ur,Nt),xi=1-qt(Be,Zt,Nt),Bn=1-qt(k,Zt,Nt),Ui.push(zr[Je]),Ui.push(jr[Je])),Je===5?(ia=1-qt(k,Zt,nr),ka=1-qt(k,Nt,ur),Ui.push(Qt[Je])):Je===165?(ia=qt(Be,nr,Zt),ka=qt(Be,ur,Nt),Ui.push(Qt[Je])):Je===20?(Ro=qt(k,ur,nr),Bn=qt(k,Nt,Zt),Ui.push(cr[Je])):Je===150?(Ro=1-qt(Be,nr,ur),Bn=1-qt(Be,Zt,Nt),Ui.push(cr[Je])):Je===80?(So=qt(k,nr,Zt),Jo=qt(k,ur,Nt),Ui.push(Tt[Je])):Je===90?(So=1-qt(Be,Zt,nr),Jo=1-qt(Be,Nt,ur),Ui.push(Tt[Je])):Je===65?(fi=1-qt(k,nr,ur),xi=1-qt(k,Zt,Nt),Ui.push(pr[Je])):Je===105?(fi=qt(Be,ur,nr),xi=qt(Be,Nt,Zt),Ui.push(pr[Je])):Je===160?(So=qt(Be,nr,Zt),ia=qt(k,nr,Zt),ka=qt(k,ur,Nt),Jo=qt(Be,ur,Nt),Ui.push(Tt[Je]),Ui.push(Qt[Je])):Je===10?(So=1-qt(k,Zt,nr),ia=1-qt(Be,Zt,nr),ka=1-qt(Be,Nt,ur),Jo=1-qt(k,Nt,ur),Ui.push(Tt[Je]),Ui.push(Qt[Je])):Je===130?(Ro=1-qt(k,nr,ur),fi=1-qt(Be,nr,ur),xi=1-qt(Be,Zt,Nt),Bn=1-qt(k,Zt,Nt),Ui.push(cr[Je]),Ui.push(pr[Je])):Je===40?(Ro=qt(Be,ur,nr),fi=qt(k,ur,nr),xi=qt(k,Nt,Zt),Bn=qt(Be,Nt,Zt),Ui.push(cr[Je]),Ui.push(pr[Je])):Je===101?(ia=qt(Be,nr,Zt),xi=qt(Be,Nt,Zt),Ui.push(Qt[Je])):Je===69?(ia=1-qt(k,Zt,nr),xi=1-qt(k,Zt,Nt),Ui.push(Qt[Je])):Je===149?(ka=qt(Be,ur,Nt),Bn=1-qt(Be,Zt,Nt),Ui.push(zr[Je])):Je===21?(ka=1-qt(k,Nt,ur),Bn=qt(k,Nt,Zt),Ui.push(zr[Je])):Je===86?(Ro=1-qt(Be,nr,ur),Jo=1-qt(Be,Nt,ur),Ui.push(cr[Je])):Je===84?(Ro=qt(k,ur,nr),Jo=qt(k,ur,Nt),Ui.push(cr[Je])):Je===89?(So=1-qt(Be,Zt,nr),fi=qt(Be,ur,nr),Ui.push(pr[Je])):Je===81?(So=qt(k,nr,Zt),fi=1-qt(k,nr,ur),Ui.push(pr[Je])):Je===96?(So=qt(Be,nr,Zt),ia=qt(k,nr,Zt),Jo=qt(k,ur,Nt),xi=qt(Be,Nt,Zt),Ui.push(Tt[Je]),Ui.push(Qt[Je])):Je===74?(So=1-qt(k,Zt,nr),ia=1-qt(Be,Zt,nr),Jo=1-qt(Be,Nt,ur),xi=1-qt(k,Zt,Nt),Ui.push(Tt[Je]),Ui.push(Qt[Je])):Je===24?(So=1-qt(Be,Zt,nr),Ro=qt(Be,ur,nr),fi=qt(k,ur,nr),Bn=qt(k,Nt,Zt),Ui.push(Tt[Je]),Ui.push(pr[Je])):Je===146?(So=qt(k,nr,Zt),Ro=1-qt(k,nr,ur),fi=1-qt(Be,nr,ur),Bn=1-qt(Be,Zt,Nt),Ui.push(Tt[Je]),Ui.push(pr[Je])):Je===6?(ia=1-qt(k,Zt,nr),Ro=1-qt(Be,nr,ur),ka=1-qt(Be,Nt,ur),Jo=1-qt(k,Nt,ur),Ui.push(Qt[Je]),Ui.push(cr[Je])):Je===164?(ia=qt(Be,nr,Zt),Ro=qt(k,ur,nr),ka=qt(k,ur,Nt),Jo=qt(Be,ur,Nt),Ui.push(Qt[Je]),Ui.push(cr[Je])):Je===129?(fi=1-qt(k,nr,ur),ka=qt(Be,ur,Nt),xi=1-qt(Be,Zt,Nt),Bn=1-qt(k,Zt,Nt),Ui.push(pr[Je]),Ui.push(zr[Je])):Je===41?(fi=qt(Be,ur,nr),ka=1-qt(k,Nt,ur),xi=qt(k,Nt,Zt),Bn=qt(Be,Nt,Zt),Ui.push(pr[Je]),Ui.push(zr[Je])):Je===66?(Ro=1-qt(k,nr,ur),fi=1-qt(Be,nr,ur),Jo=1-qt(Be,Nt,ur),xi=1-qt(k,Zt,Nt),Ui.push(cr[Je]),Ui.push(pr[Je])):Je===104?(Ro=qt(Be,ur,nr),fi=qt(k,ur,nr),Jo=qt(k,ur,Nt),xi=qt(Be,Nt,Zt),Ui.push(pr[Je]),Ui.push(tn[Je])):Je===144?(So=qt(k,nr,Zt),ka=qt(k,ur,Nt),Jo=qt(Be,ur,Nt),Bn=1-qt(Be,Zt,Nt),Ui.push(Tt[Je]),Ui.push(jr[Je])):Je===26?(So=1-qt(Be,Zt,nr),ka=1-qt(Be,Nt,ur),Jo=1-qt(k,Nt,ur),Bn=qt(k,Nt,Zt),Ui.push(Tt[Je]),Ui.push(jr[Je])):Je===36?(ia=qt(Be,nr,Zt),Ro=qt(k,ur,nr),xi=qt(k,Nt,Zt),Bn=qt(Be,Nt,Zt),Ui.push(Qt[Je]),Ui.push(cr[Je])):Je===134?(ia=1-qt(k,Zt,nr),Ro=1-qt(Be,nr,ur),xi=1-qt(Be,Zt,Nt),Bn=1-qt(k,Zt,Nt),Ui.push(Qt[Je]),Ui.push(cr[Je])):Je===9?(So=1-qt(k,Zt,nr),ia=1-qt(Be,Zt,nr),fi=qt(Be,ur,nr),ka=1-qt(k,Nt,ur),Ui.push(Tt[Je]),Ui.push(Qt[Je])):Je===161?(So=qt(Be,nr,Zt),ia=qt(k,nr,Zt),fi=1-qt(k,nr,ur),ka=qt(Be,ur,Nt),Ui.push(Tt[Je]),Ui.push(Qt[Je])):Je===37?(ia=qt(Be,nr,Zt),ka=1-qt(k,Nt,ur),xi=qt(k,Nt,Zt),Bn=qt(Be,Nt,Zt),Ui.push(Qt[Je]),Ui.push(zr[Je])):Je===133?(ia=1-qt(k,Zt,nr),ka=qt(Be,ur,Nt),xi=1-qt(Be,Zt,Nt),Bn=1-qt(k,Zt,Nt),Ui.push(Qt[Je]),Ui.push(zr[Je])):Je===148?(Ro=qt(k,ur,nr),ka=qt(k,ur,Nt),Jo=qt(Be,ur,Nt),Bn=1-qt(Be,Zt,Nt),Ui.push(cr[Je]),Ui.push(jr[Je])):Je===22?(Ro=1-qt(Be,nr,ur),ka=1-qt(Be,Nt,ur),Jo=1-qt(k,Nt,ur),Bn=qt(k,Nt,Zt),Ui.push(cr[Je]),Ui.push(jr[Je])):Je===82?(So=qt(k,nr,Zt),Ro=1-qt(k,nr,ur),fi=1-qt(Be,nr,ur),Jo=1-qt(Be,Nt,ur),Ui.push(Tt[Je]),Ui.push(pr[Je])):Je===88?(So=1-qt(Be,Zt,nr),Ro=qt(Be,ur,nr),fi=qt(k,ur,nr),Jo=qt(k,ur,Nt),Ui.push(Tt[Je]),Ui.push(pr[Je])):Je===73?(So=1-qt(k,Zt,nr),ia=1-qt(Be,Zt,nr),fi=qt(Be,ur,nr),xi=1-qt(k,Zt,Nt),Ui.push(Tt[Je]),Ui.push(Qt[Je])):Je===97?(So=qt(Be,nr,Zt),ia=qt(k,nr,Zt),fi=1-qt(k,nr,ur),xi=qt(Be,Nt,Zt),Ui.push(Tt[Je]),Ui.push(Qt[Je])):Je===145?(So=qt(k,nr,Zt),fi=1-qt(k,nr,ur),ka=qt(Be,ur,Nt),Bn=1-qt(Be,Zt,Nt),Ui.push(Tt[Je]),Ui.push(zr[Je])):Je===25?(So=1-qt(Be,Zt,nr),fi=qt(Be,ur,nr),ka=1-qt(k,Nt,ur),Bn=qt(k,Nt,Zt),Ui.push(Tt[Je]),Ui.push(zr[Je])):Je===70?(ia=1-qt(k,Zt,nr),Ro=1-qt(Be,nr,ur),Jo=1-qt(Be,Nt,ur),xi=1-qt(k,Zt,Nt),Ui.push(Qt[Je]),Ui.push(cr[Je])):Je===100?(ia=qt(Be,nr,Zt),Ro=qt(k,ur,nr),Jo=qt(k,ur,Nt),xi=qt(Be,Nt,Zt),Ui.push(Qt[Je]),Ui.push(cr[Je])):Je===34?(Gn===0?(So=1-qt(k,Zt,nr),ia=1-qt(Be,Zt,nr),Ro=qt(Be,ur,nr),fi=qt(k,ur,nr),ka=qt(k,ur,Nt),Jo=qt(Be,ur,Nt),xi=1-qt(Be,Zt,Nt),Bn=1-qt(k,Zt,Nt)):(So=qt(Be,nr,Zt),ia=qt(k,nr,Zt),Ro=1-qt(k,nr,ur),fi=1-qt(Be,nr,ur),ka=1-qt(Be,Nt,ur),Jo=1-qt(k,Nt,ur),xi=qt(k,Nt,Zt),Bn=qt(Be,Nt,Zt)),Ui.push(Tt[Je]),Ui.push(Qt[Je]),Ui.push(zr[Je]),Ui.push(jr[Je])):Je===35?(Gn===4?(So=1-qt(k,Zt,nr),ia=1-qt(Be,Zt,nr),Ro=qt(Be,ur,nr),fi=qt(k,ur,nr),ka=qt(k,ur,Nt),Jo=qt(Be,ur,Nt),xi=1-qt(Be,Zt,Nt),Bn=1-qt(k,Zt,Nt)):(So=qt(Be,nr,Zt),ia=qt(k,nr,Zt),Ro=1-qt(k,nr,ur),fi=1-qt(Be,nr,ur),ka=1-qt(Be,Nt,ur),Jo=1-qt(k,Nt,ur),xi=qt(k,Nt,Zt),Bn=qt(Be,Nt,Zt)),Ui.push(Tt[Je]),Ui.push(Qt[Je]),Ui.push(pr[Je]),Ui.push(jr[Je])):Je===136?(Gn===0?(So=qt(Be,nr,Zt),ia=qt(k,nr,Zt),Ro=1-qt(k,nr,ur),fi=1-qt(Be,nr,ur),ka=1-qt(Be,Nt,ur),Jo=1-qt(k,Nt,ur),xi=qt(k,Nt,Zt),Bn=qt(Be,Nt,Zt)):(So=1-qt(k,Zt,nr),ia=1-qt(Be,Zt,nr),Ro=qt(Be,ur,nr),fi=qt(k,ur,nr),ka=qt(k,ur,Nt),Jo=qt(Be,ur,Nt),xi=1-qt(Be,Zt,Nt),Bn=1-qt(k,Zt,Nt)),Ui.push(Tt[Je]),Ui.push(Qt[Je]),Ui.push(zr[Je]),Ui.push(jr[Je])):Je===153?(Gn===0?(So=qt(k,nr,Zt),fi=1-qt(k,nr,ur),ka=1-qt(k,Nt,ur),Bn=qt(k,Nt,Zt)):(So=1-qt(Be,Zt,nr),fi=qt(Be,ur,nr),ka=qt(Be,ur,Nt),Bn=1-qt(Be,Zt,Nt)),Ui.push(Tt[Je]),Ui.push(pr[Je])):Je===102?(Gn===0?(ia=1-qt(k,Zt,nr),Ro=qt(k,ur,nr),Jo=qt(k,ur,Nt),xi=1-qt(k,Zt,Nt)):(ia=qt(Be,nr,Zt),Ro=1-qt(Be,nr,ur),Jo=1-qt(Be,Nt,ur),xi=qt(Be,Nt,Zt)),Ui.push(Qt[Je]),Ui.push(jr[Je])):Je===155?(Gn===4?(So=qt(k,nr,Zt),fi=1-qt(k,nr,ur),ka=1-qt(k,Nt,ur),Bn=qt(k,Nt,Zt)):(So=1-qt(Be,Zt,nr),fi=qt(Be,ur,nr),ka=qt(Be,ur,Nt),Bn=1-qt(Be,Zt,Nt)),Ui.push(Tt[Je]),Ui.push(zr[Je])):Je===103?(Gn===4?(ia=1-qt(k,Zt,nr),Ro=qt(k,ur,nr),Jo=qt(k,ur,Nt),xi=1-qt(k,Zt,Nt)):(ia=qt(Be,nr,Zt),Ro=1-qt(Be,nr,ur),Jo=1-qt(Be,Nt,ur),xi=qt(Be,Nt,Zt)),Ui.push(Qt[Je]),Ui.push(cr[Je])):Je===152?(Gn===0?(So=qt(k,nr,Zt),Ro=1-qt(k,nr,ur),fi=1-qt(Be,nr,ur),ka=1-qt(Be,Nt,ur),Jo=1-qt(k,Nt,ur),Bn=qt(k,Nt,Zt)):(So=1-qt(Be,Zt,nr),Ro=qt(Be,ur,nr),fi=qt(k,ur,nr),ka=qt(k,ur,Nt),Jo=qt(Be,ur,Nt),Bn=1-qt(Be,Zt,Nt)),Ui.push(Tt[Je]),Ui.push(cr[Je]),Ui.push(pr[Je])):Je===156?(Gn===4?(So=qt(k,nr,Zt),Ro=1-qt(k,nr,ur),fi=1-qt(Be,nr,ur),ka=1-qt(Be,Nt,ur),Jo=1-qt(k,Nt,ur),Bn=qt(k,Nt,Zt)):(So=1-qt(Be,Zt,nr),Ro=qt(Be,ur,nr),fi=qt(k,ur,nr),ka=qt(k,ur,Nt),Jo=qt(Be,ur,Nt),Bn=1-qt(Be,Zt,Nt)),Ui.push(Tt[Je]),Ui.push(pr[Je]),Ui.push(jr[Je])):Je===137?(Gn===0?(So=qt(Be,nr,Zt),ia=qt(k,nr,Zt),fi=1-qt(k,nr,ur),ka=1-qt(k,Nt,ur),xi=qt(k,Nt,Zt),Bn=qt(Be,Nt,Zt)):(So=1-qt(k,Zt,nr),ia=1-qt(Be,Zt,nr),fi=qt(Be,ur,nr),ka=qt(Be,ur,Nt),xi=1-qt(Be,Zt,Nt),Bn=1-qt(k,Zt,Nt)),Ui.push(Tt[Je]),Ui.push(Qt[Je]),Ui.push(pr[Je])):Je===139?(Gn===4?(So=qt(Be,nr,Zt),ia=qt(k,nr,Zt),fi=1-qt(k,nr,ur),ka=1-qt(k,Nt,ur),xi=qt(k,Nt,Zt),Bn=qt(Be,Nt,Zt)):(So=1-qt(k,Zt,nr),ia=1-qt(Be,Zt,nr),fi=qt(Be,ur,nr),ka=qt(Be,ur,Nt),xi=1-qt(Be,Zt,Nt),Bn=1-qt(k,Zt,Nt)),Ui.push(Tt[Je]),Ui.push(Qt[Je]),Ui.push(zr[Je])):Je===98?(Gn===0?(So=1-qt(k,Zt,nr),ia=1-qt(Be,Zt,nr),Ro=qt(Be,ur,nr),fi=qt(k,ur,nr),Jo=qt(k,ur,Nt),xi=1-qt(k,Zt,Nt)):(So=qt(Be,nr,Zt),ia=qt(k,nr,Zt),Ro=1-qt(k,nr,ur),fi=1-qt(Be,nr,ur),Jo=1-qt(Be,Nt,ur),xi=qt(Be,Nt,Zt)),Ui.push(Tt[Je]),Ui.push(Qt[Je]),Ui.push(jr[Je])):Je===99?(Gn===4?(So=1-qt(k,Zt,nr),ia=1-qt(Be,Zt,nr),Ro=qt(Be,ur,nr),fi=qt(k,ur,nr),Jo=qt(k,ur,Nt),xi=1-qt(k,Zt,Nt)):(So=qt(Be,nr,Zt),ia=qt(k,nr,Zt),Ro=1-qt(k,nr,ur),fi=1-qt(Be,nr,ur),Jo=1-qt(Be,Nt,ur),xi=qt(Be,Nt,Zt)),Ui.push(Tt[Je]),Ui.push(Qt[Je]),Ui.push(pr[Je])):Je===38?(Gn===0?(ia=1-qt(k,Zt,nr),Ro=qt(k,ur,nr),ka=qt(k,ur,Nt),Jo=qt(Be,ur,Nt),xi=1-qt(Be,Zt,Nt),Bn=1-qt(k,Zt,Nt)):(ia=qt(Be,nr,Zt),Ro=1-qt(Be,nr,ur),ka=1-qt(Be,Nt,ur),Jo=1-qt(k,Nt,ur),xi=qt(k,Nt,Zt),Bn=qt(Be,Nt,Zt)),Ui.push(Qt[Je]),Ui.push(zr[Je]),Ui.push(jr[Je])):Je===39?(Gn===4?(ia=1-qt(k,Zt,nr),Ro=qt(k,ur,nr),ka=qt(k,ur,Nt),Jo=qt(Be,ur,Nt),xi=1-qt(Be,Zt,Nt),Bn=1-qt(k,Zt,Nt)):(ia=qt(Be,nr,Zt),Ro=1-qt(Be,nr,ur),ka=1-qt(Be,Nt,ur),Jo=1-qt(k,Nt,ur),xi=qt(k,Nt,Zt),Bn=qt(Be,Nt,Zt)),Ui.push(Qt[Je]),Ui.push(cr[Je]),Ui.push(jr[Je])):Je===85&&(So=1,ia=0,Ro=1,fi=0,ka=0,Jo=1,xi=0,Bn=1),(xi<0||xi>1||Bn<0||Bn>1||So<0||So>1||Ro<0||Ro>1||ka<0||ka>1||Jo<0||Jo>1)&&console.log("MarchingSquaresJS-isoBands: "+Je+" "+bi+" "+Nt+","+Zt+","+nr+","+ur+" "+Gn+" "+xi+" "+Bn+" "+So+" "+ia+" "+Ro+" "+fi+" "+ka+" "+Jo),Le.cells[yt][Et]={cval:Je,cval_real:bi,flipped:Gn,topleft:xi,topright:Bn,righttop:So,rightbottom:ia,bottomright:Ro,bottomleft:fi,leftbottom:ka,lefttop:Jo,edges:Ui}}}}}return Le}function xr(I){for(var k=[],Y=I.rows,he=I.cols,be=[],Le=0;Le0){var yt=I.cells[Le][Be],Et=oa(yt),Je=null,Nt=Be,Zt=Le;Et!==null&&be.push([Et.p[0]+Nt,Et.p[1]+Zt]);do{if(Je=da(I.cells[Zt][Nt],Et.x,Et.y,Et.o),Je!==null)be.push([Je.p[0]+Nt,Je.p[1]+Zt]),Nt+=Je.x,Zt+=Je.y,Et=Je;else break;if(Zt<0||Zt>=Y||Nt<0||Nt>=he||typeof I.cells[Zt][Nt]=="undefined"){Nt-=Je.x,Zt-=Je.y;var nr=Ni(I,Nt,Zt,Je.x,Je.y,Je.o);if(nr!==null)nr.path.forEach(function(ur){be.push(ur)}),Nt=nr.i,Zt=nr.j,Et=nr;else break}}while(typeof I.cells[Zt][Nt]!="undefined"&&I.cells[Zt][Nt].edges.length>0);k.push(be),be=[],I.cells[Le][Be].edges.length>0&&Be--}return k}function Ni(I,k,Y,he,be,Le){for(var Be=I.cells[Y][k],yt=Be.cval_real,Et=k+he,Je=Y+be,Nt=[],Zt=!1;!Zt;){if(typeof I.cells[Je]=="undefined"||typeof I.cells[Je][Et]=="undefined")if(Je-=be,Et-=he,Be=I.cells[Je][Et],yt=Be.cval_real,be===-1)if(Le===0)if(yt&nc)Nt.push([Et,Je]),he=-1,be=0,Le=0;else if(yt&fu)Nt.push([Et+1,Je]),he=1,be=0,Le=0;else{Nt.push([Et+Be.bottomright,Je]),he=0,be=1,Le=1,Zt=!0;break}else if(yt&nc)Nt.push([Et,Je]),he=-1,be=0,Le=0;else if(yt&fu){Nt.push([Et+Be.bottomright,Je]),he=0,be=1,Le=1,Zt=!0;break}else{Nt.push([Et+Be.bottomleft,Je]),he=0,be=1,Le=0,Zt=!0;break}else if(be===1)if(Le===0)if(yt&cu)Nt.push([Et+1,Je+1]),he=1,be=0,Le=1;else if(yt&ja){Nt.push([Et+Be.topleft,Je+1]),he=0,be=-1,Le=0,Zt=!0;break}else{Nt.push([Et+Be.topright,Je+1]),he=0,be=-1,Le=1,Zt=!0;break}else yt&cu?(Nt.push([Et+1,Je+1]),he=1,be=0,Le=1):(Nt.push([Et+1,Je+1]),he=1,be=0,Le=1);else if(he===-1)if(Le===0)if(yt&ja)Nt.push([Et,Je+1]),he=0,be=1,Le=0;else if(yt&nc){Nt.push([Et,Je+Be.leftbottom]),he=1,be=0,Le=0,Zt=!0;break}else{Nt.push([Et,Je+Be.lefttop]),he=1,be=0,Le=1,Zt=!0;break}else if(yt&ja)Nt.push([Et,Je+1]),he=0,be=1,Le=0;else{console.log("MarchingSquaresJS-isoBands: wtf");break}else if(he===1)if(Le===0)if(yt&fu)Nt.push([Et+1,Je]),he=0,be=-1,Le=1;else{Nt.push([Et+1,Je+Be.rightbottom]),he=-1,be=0,Le=0,Zt=!0;break}else if(yt&fu)Nt.push([Et+1,Je]),he=0,be=-1,Le=1;else if(yt&cu){Nt.push([Et+1,Je+Be.righttop]),he=-1,be=0,Le=1;break}else{Nt.push([Et+1,Je+Be.rightbottom]),he=-1,be=0,Le=0,Zt=!0;break}else{console.log("MarchingSquaresJS-isoBands: we came from nowhere!");break}else if(Be=I.cells[Je][Et],yt=Be.cval_real,he===-1)if(Le===0)if(typeof I.cells[Je-1]!="undefined"&&typeof I.cells[Je-1][Et]!="undefined")he=0,be=-1,Le=1;else if(yt&nc)Nt.push([Et,Je]);else{Nt.push([Et+Be.bottomright,Je]),he=0,be=1,Le=1,Zt=!0;break}else if(yt&ja)console.log("MarchingSquaresJS-isoBands: proceeding in x-direction!");else{console.log("MarchingSquaresJS-isoBands: found entry from top at "+Et+","+Je);break}else if(he===1)if(Le===0){console.log("MarchingSquaresJS-isoBands: wtf");break}else if(typeof I.cells[Je+1]!="undefined"&&typeof I.cells[Je+1][Et]!="undefined")he=0,be=1,Le=0;else if(yt&cu)Nt.push([Et+1,Je+1]),he=1,be=0,Le=1;else{Nt.push([Et+Be.topleft,Je+1]),he=0,be=-1,Le=0,Zt=!0;break}else if(be===-1)if(Le===1)if(typeof I.cells[Je][Et+1]!="undefined")he=1,be=0,Le=1;else if(yt&fu)Nt.push([Et+1,Je]),he=0,be=-1,Le=1;else{Nt.push([Et+1,Je+Be.righttop]),he=-1,be=0,Le=1,Zt=!0;break}else{console.log("MarchingSquaresJS-isoBands: wtf");break}else if(be===1)if(Le===0)if(typeof I.cells[Je][Et-1]!="undefined")he=-1,be=0,Le=0;else if(yt&ja)Nt.push([Et,Je+1]),he=0,be=1,Le=0;else{Nt.push([Et,Je+Be.leftbottom]),he=1,be=0,Le=0,Zt=!0;break}else{console.log("MarchingSquaresJS-isoBands: wtf");break}else{console.log("MarchingSquaresJS-isoBands: where did we came from???");break}if(Et+=he,Je+=be,Et===k&&Je===Y)break}return{path:Nt,i:Et,j:Je,x:he,y:be,o:Le}}function uo(I,k){delete I.edges[k];for(var Y=k+1;Y0){var k=I.edges[I.edges.length-1],Y=I.cval_real;switch(k){case 0:return Y&cu?{p:[1,I.righttop],x:-1,y:0,o:1}:{p:[I.topleft,1],x:0,y:-1,o:0};case 1:return Y&fu?{p:[I.topleft,1],x:0,y:-1,o:0}:{p:[1,I.rightbottom],x:-1,y:0,o:0};case 2:return Y&fu?{p:[I.bottomright,0],x:0,y:1,o:1}:{p:[I.topleft,1],x:0,y:-1,o:0};case 3:return Y&nc?{p:[I.topleft,1],x:0,y:-1,o:0}:{p:[I.bottomleft,0],x:0,y:1,o:0};case 4:return Y&cu?{p:[1,I.righttop],x:-1,y:0,o:1}:{p:[I.topright,1],x:0,y:-1,o:1};case 5:return Y&fu?{p:[I.topright,1],x:0,y:-1,o:1}:{p:[1,I.rightbottom],x:-1,y:0,o:0};case 6:return Y&fu?{p:[I.bottomright,0],x:0,y:1,o:1}:{p:[I.topright,1],x:0,y:-1,o:1};case 7:return Y&nc?{p:[I.topright,1],x:0,y:-1,o:1}:{p:[I.bottomleft,0],x:0,y:1,o:0};case 8:return Y&fu?{p:[I.bottomright,0],x:0,y:1,o:1}:{p:[1,I.righttop],x:-1,y:0,o:1};case 9:return Y&nc?{p:[1,I.righttop],x:-1,y:0,o:1}:{p:[I.bottomleft,0],x:0,y:1,o:0};case 10:return Y&nc?{p:[0,I.leftbottom],x:1,y:0,o:0}:{p:[1,I.righttop],x:-1,y:0,o:1};case 11:return Y&ja?{p:[1,I.righttop],x:-1,y:0,o:1}:{p:[0,I.lefttop],x:1,y:0,o:1};case 12:return Y&fu?{p:[I.bottomright,0],x:0,y:1,o:1}:{p:[1,I.rightbottom],x:-1,y:0,o:0};case 13:return Y&nc?{p:[1,I.rightbottom],x:-1,y:0,o:0}:{p:[I.bottomleft,0],x:0,y:1,o:0};case 14:return Y&nc?{p:[0,I.leftbottom],x:1,y:0,o:0}:{p:[1,I.rightbottom],x:-1,y:0,o:0};case 15:return Y&ja?{p:[1,I.rightbottom],x:-1,y:0,o:0}:{p:[0,I.lefttop],x:1,y:0,o:1};case 16:return Y&fu?{p:[I.bottomright,0],x:0,y:1,o:1}:{p:[0,I.leftbottom],x:1,y:0,o:0};case 17:return Y&ja?{p:[I.bottomright,0],x:0,y:1,o:1}:{p:[0,I.lefttop],x:1,y:0,o:1};case 18:return Y&nc?{p:[0,I.leftbottom],x:1,y:0,o:0}:{p:[I.bottomleft,0],x:0,y:1,o:0};case 19:return Y&ja?{p:[I.bottomleft,0],x:0,y:1,o:0}:{p:[0,I.lefttop],x:1,y:0,o:1};case 20:return Y&ja?{p:[I.topleft,1],x:0,y:-1,o:0}:{p:[0,I.leftbottom],x:1,y:0,o:0};case 21:return Y&cu?{p:[0,I.leftbottom],x:1,y:0,o:0}:{p:[I.topright,1],x:0,y:-1,o:1};case 22:return Y&ja?{p:[I.topleft,1],x:0,y:-1,o:0}:{p:[0,I.lefttop],x:1,y:0,o:1};case 23:return Y&cu?{p:[0,I.lefttop],x:1,y:0,o:1}:{p:[I.topright,1],x:0,y:-1,o:1};default:console.log("MarchingSquaresJS-isoBands: edge index out of range!"),console.log(I);break}}return null}function da(I,k,Y,he){var be,Le,Be,yt,Et=I.cval,Je;switch(k){case-1:switch(he){case 0:be=Qt[Et],Be=Tl[Et],yt=ql[Et],Je=ic[Et];break;default:be=Tt[Et],Be=bl[Et],yt=kl[Et],Je=Wc[Et];break}break;case 1:switch(he){case 0:be=zr[Et],Be=Ka[Et],yt=ea[Et],Je=qo[Et];break;default:be=jr[Et],Be=Xc[Et],yt=Al[Et],Je=Sc[Et];break}break;default:switch(Y){case-1:switch(he){case 0:be=tn[Et],Be=Su[Et],yt=Wu[Et],Je=Hc[Et];break;default:be=Hr[Et],Be=Lc[Et],yt=Kl[Et],Je=Ec[Et];break}break;case 1:switch(he){case 0:be=pr[Et],Be=Ls[Et],yt=cc[Et],Je=gu[Et];break;default:be=cr[Et],Be=Cu[Et],yt=Qc[Et],Je=hf[Et];break}break}break}if(Le=I.edges.indexOf(be),typeof I.edges[Le]!="undefined")uo(I,Le);else return null;switch(Et=I.cval_real,be){case 0:Et&cu?(k=I.topleft,Y=1):(k=1,Y=I.righttop);break;case 1:Et&fu?(k=1,Y=I.rightbottom):(k=I.topleft,Y=1);break;case 2:Et&fu?(k=I.topleft,Y=1):(k=I.bottomright,Y=0);break;case 3:Et&nc?(k=I.bottomleft,Y=0):(k=I.topleft,Y=1);break;case 4:Et&cu?(k=I.topright,Y=1):(k=1,Y=I.righttop);break;case 5:Et&fu?(k=1,Y=I.rightbottom):(k=I.topright,Y=1);break;case 6:Et&fu?(k=I.topright,Y=1):(k=I.bottomright,Y=0);break;case 7:Et&nc?(k=I.bottomleft,Y=0):(k=I.topright,Y=1);break;case 8:Et&fu?(k=1,Y=I.righttop):(k=I.bottomright,Y=0);break;case 9:Et&nc?(k=I.bottomleft,Y=0):(k=1,Y=I.righttop);break;case 10:Et&nc?(k=1,Y=I.righttop):(k=0,Y=I.leftbottom);break;case 11:Et&ja?(k=0,Y=I.lefttop):(k=1,Y=I.righttop);break;case 12:Et&fu?(k=1,Y=I.rightbottom):(k=I.bottomright,Y=0);break;case 13:Et&nc?(k=I.bottomleft,Y=0):(k=1,Y=I.rightbottom);break;case 14:Et&nc?(k=1,Y=I.rightbottom):(k=0,Y=I.leftbottom);break;case 15:Et&ja?(k=0,Y=I.lefttop):(k=1,Y=I.rightbottom);break;case 16:Et&fu?(k=0,Y=I.leftbottom):(k=I.bottomright,Y=0);break;case 17:Et&ja?(k=0,Y=I.lefttop):(k=I.bottomright,Y=0);break;case 18:Et&nc?(k=I.bottomleft,Y=0):(k=0,Y=I.leftbottom);break;case 19:Et&ja?(k=0,Y=I.lefttop):(k=I.bottomleft,Y=0);break;case 20:Et&ja?(k=0,Y=I.leftbottom):(k=I.topleft,Y=1);break;case 21:Et&cu?(k=I.topright,Y=1):(k=0,Y=I.leftbottom);break;case 22:Et&ja?(k=0,Y=I.lefttop):(k=I.topleft,Y=1);break;case 23:Et&cu?(k=I.topright,Y=1):(k=0,Y=I.lefttop);break;default:return console.log("MarchingSquaresJS-isoBands: edge index out of range!"),console.log(I),null}return(typeof k=="undefined"||typeof Y=="undefined"||typeof Be=="undefined"||typeof yt=="undefined"||typeof Je=="undefined")&&(console.log("MarchingSquaresJS-isoBands: undefined value!"),console.log(I),console.log(k+" "+Y+" "+Be+" "+yt+" "+Je)),{p:[k,Y],x:Be,y:yt,o:Je}}function Fs(I){var k=[],Y=0;return I.cells.forEach(function(he,be){he.forEach(function(Le,Be){if(typeof Le!="undefined"){var yt=fn[Le.cval](Le);typeof yt=="object"&&ii(yt)?typeof yt[0]=="object"&&ii(yt[0])?typeof yt[0][0]=="object"&&ii(yt[0][0])?yt.forEach(function(Et){Et.forEach(function(Je){Je[0]+=Be,Je[1]+=be}),k[Y++]=Et}):(yt.forEach(function(Et){Et[0]+=Be,Et[1]+=be}),k[Y++]=yt):console.log("MarchingSquaresJS-isoBands: bandcell polygon with malformed coordinates"):console.log("MarchingSquaresJS-isoBands: bandcell polygon with null coordinates")}})}),k}function hu(I,k,Y){if(Y=Y||{},!isObject(Y))throw new Error("options is invalid");var he=Y.zProperty||"elevation",be=Y.commonProperties||{},Le=Y.breaksProperties||[];if(collectionOf(I,"Point","Input must contain Points"),!k)throw new Error("breaks is required");if(!Array.isArray(k))throw new Error("breaks is not an Array");if(!isObject(be))throw new Error("commonProperties is not an Object");if(!Array.isArray(Le))throw new Error("breaksProperties is not an Array");var Be=Gf(I,{zProperty:he,flip:!0}),yt=qr(Be,k,he);yt=Zu(yt,Be,I);var Et=yt.map(function(Je,Nt){if(Le[Nt]&&!isObject(Le[Nt]))throw new Error("Each mappedProperty is required to be an Object");var Zt=objectAssign({},be,Le[Nt]);Zt[he]=Je[he];var nr=multiPolygon(Je.groupedRings,Zt);return nr});return featureCollection(Et)}function qr(I,k,Y){for(var he=[],be=1;be0){var Nt=he[Et-1],Zt=Qh(Je,Nt);Zt!==!1&&(Nt[1]=Zt,Je[0]=Zt),Be.push(Nt[0]),Et===Le.length-2&&(Be.push(Je[0]),Be.push(Je[1]))}Le.length===2&&(Be.push(Je[0]),Be.push(Je[1]))}}),lineString(Be,I.properties)}function qf(I,k,Y){var he=Math.sqrt((I[0]-k[0])*(I[0]-k[0])+(I[1]-k[1])*(I[1]-k[1])),be=I[0]+Y*(k[1]-I[1])/he,Le=k[0]+Y*(k[1]-I[1])/he,Be=I[1]+Y*(I[0]-k[0])/he,yt=k[1]+Y*(I[0]-k[0])/he;return[[be,Be],[Le,yt]]}var hd=null;function nd(I){return(I>0)-(I<0)||+I}function id(I,k,Y){var he=k[0]-I[0],be=k[1]-I[1],Le=Y[0]-k[0],Be=Y[1]-k[1];return nd(he*Be-Le*be)}function Hp(I,k){var Y=I.geometry.coordinates[0].map(function(Be){return Be[0]}),he=I.geometry.coordinates[0].map(function(Be){return Be[1]}),be=k.geometry.coordinates[0].map(function(Be){return Be[0]}),Le=k.geometry.coordinates[0].map(function(Be){return Be[1]});return Math.max.apply(null,Y)===Math.max.apply(null,be)&&Math.max.apply(null,he)===Math.max.apply(null,Le)&&Math.min.apply(null,Y)===Math.min.apply(null,be)&&Math.min.apply(null,he)===Math.min.apply(null,Le)}function mc(I,k){return k.geometry.coordinates[0].every(function(Y){return bt((0,p.xm)(Y),I)})}function Cd(I,k){return I[0]===k[0]&&I[1]===k[1]}var od=function(){function I(k){this.id=I.buildId(k),this.coordinates=k,this.innerEdges=[],this.outerEdges=[],this.outerEdgesSorted=!1}return I.buildId=function(k){return k.join(",")},I.prototype.removeInnerEdge=function(k){this.innerEdges=this.innerEdges.filter(function(Y){return Y.from.id!==k.from.id})},I.prototype.removeOuterEdge=function(k){this.outerEdges=this.outerEdges.filter(function(Y){return Y.to.id!==k.to.id})},I.prototype.addOuterEdge=function(k){this.outerEdges.push(k),this.outerEdgesSorted=!1},I.prototype.sortOuterEdges=function(){var k=this;this.outerEdgesSorted||(this.outerEdges.sort(function(Y,he){var be=Y.to,Le=he.to;if(be.coordinates[0]-k.coordinates[0]>=0&&Le.coordinates[0]-k.coordinates[0]<0)return 1;if(be.coordinates[0]-k.coordinates[0]<0&&Le.coordinates[0]-k.coordinates[0]>=0)return-1;if(be.coordinates[0]-k.coordinates[0]===0&&Le.coordinates[0]-k.coordinates[0]===0)return be.coordinates[1]-k.coordinates[1]>=0||Le.coordinates[1]-k.coordinates[1]>=0?be.coordinates[1]-Le.coordinates[1]:Le.coordinates[1]-be.coordinates[1];var Be=id(k.coordinates,be.coordinates,Le.coordinates);if(Be<0)return 1;if(Be>0)return-1;var yt=Math.pow(be.coordinates[0]-k.coordinates[0],2)+Math.pow(be.coordinates[1]-k.coordinates[1],2),Et=Math.pow(Le.coordinates[0]-k.coordinates[0],2)+Math.pow(Le.coordinates[1]-k.coordinates[1],2);return yt-Et}),this.outerEdgesSorted=!0)},I.prototype.getOuterEdges=function(){return this.sortOuterEdges(),this.outerEdges},I.prototype.getOuterEdge=function(k){return this.sortOuterEdges(),this.outerEdges[k]},I.prototype.addInnerEdge=function(k){this.innerEdges.push(k)},I}(),lf=od,Dp=function(){function I(k,Y){this.from=k,this.to=Y,this.next=void 0,this.label=void 0,this.symetric=void 0,this.ring=void 0,this.from.addOuterEdge(this),this.to.addInnerEdge(this)}return I.prototype.getSymetric=function(){return this.symetric||(this.symetric=new I(this.to,this.from),this.symetric.symetric=this),this.symetric},I.prototype.deleteEdge=function(){this.from.removeOuterEdge(this),this.to.removeInnerEdge(this)},I.prototype.isEqual=function(k){return this.from.id===k.from.id&&this.to.id===k.to.id},I.prototype.toString=function(){return"Edge { "+this.from.id+" -> "+this.to.id+" }"},I.prototype.toLineString=function(){return(0,p.Tu)([this.from.coordinates,this.to.coordinates])},I.prototype.compareTo=function(k){return id(k.from.coordinates,k.to.coordinates,this.to.coordinates)},I}(),Tc=Dp,Vf=function(){function I(){this.edges=[],this.polygon=void 0,this.envelope=void 0}return I.prototype.push=function(k){this.edges.push(k),this.polygon=this.envelope=void 0},I.prototype.get=function(k){return this.edges[k]},Object.defineProperty(I.prototype,"length",{get:function(){return this.edges.length},enumerable:!0,configurable:!0}),I.prototype.forEach=function(k){this.edges.forEach(k)},I.prototype.map=function(k){return this.edges.map(k)},I.prototype.some=function(k){return this.edges.some(k)},I.prototype.isValid=function(){return!0},I.prototype.isHole=function(){var k=this,Y=this.edges.reduce(function(Be,yt,Et){return yt.from.coordinates[1]>k.edges[Be].from.coordinates[1]&&(Be=Et),Be},0),he=(Y===0?this.length:Y)-1,be=(Y+1)%this.length,Le=id(this.edges[he].from.coordinates,this.edges[Y].from.coordinates,this.edges[be].from.coordinates);return Le===0?this.edges[he].from.coordinates[0]>this.edges[be].from.coordinates[0]:Le>0},I.prototype.toMultiPoint=function(){return(0,p.ot)(this.edges.map(function(k){return k.from.coordinates}))},I.prototype.toPolygon=function(){if(this.polygon)return this.polygon;var k=this.edges.map(function(Y){return Y.from.coordinates});return k.push(this.edges[0].from.coordinates),this.polygon=(0,p.yu)([k])},I.prototype.getEnvelope=function(){return this.envelope?this.envelope:this.envelope=Lo(this.toPolygon())},I.findEdgeRingContaining=function(k,Y){var he=k.getEnvelope(),be,Le;return Y.forEach(function(Be){var yt=Be.getEnvelope();if(Le&&(be=Le.getEnvelope()),!Hp(yt,he)&&mc(yt,he)){for(var Et=k.map(function(bi){return bi.from.coordinates}),Je=void 0,Nt=function(bi){Be.some(function(Gn){return Cd(bi,Gn.from.coordinates)})||(Je=bi)},Zt=0,nr=Et;Zt=0;--Be){var yt=he[Be],Et=yt.symetric,Je=void 0,Nt=void 0;yt.label===Y&&(Je=yt),Et.label===Y&&(Nt=Et),!(!Je||!Nt)&&(Nt&&(Le=Nt),Je&&(Le&&(Le.next=Je,Le=void 0),be||(be=Je)))}Le&&(Le.next=be)},I.prototype._findLabeledEdgeRings=function(){var k=[],Y=0;return this.edges.forEach(function(he){if(!(he.label>=0)){k.push(he);var be=he;do be.label=Y,be=be.next;while(!he.isEqual(be));Y++}}),k},I.prototype.getEdgeRings=function(){var k=this;this._computeNextCWEdges(),this.edges.forEach(function(he){he.label=void 0}),this._findLabeledEdgeRings().forEach(function(he){k._findIntersectionNodes(he).forEach(function(be){k._computeNextCCWEdges(be,he.label)})});var Y=[];return this.edges.forEach(function(he){he.ring||Y.push(k._findEdgeRing(he))}),Y},I.prototype._findIntersectionNodes=function(k){var Y=[],he=k,be=function(){var Le=0;he.from.getOuterEdges().forEach(function(Be){Be.label===k.label&&++Le}),Le>1&&Y.push(he.from),he=he.next};do be();while(!k.isEqual(he));return Y},I.prototype._findEdgeRing=function(k){var Y=k,he=new Zh;do he.push(Y),Y.ring=he,Y=Y.next;while(!k.isEqual(Y));return he},I.prototype.removeNode=function(k){var Y=this;k.getOuterEdges().forEach(function(he){return Y.removeEdge(he)}),k.innerEdges.forEach(function(he){return Y.removeEdge(he)}),delete this.nodes[k.id]},I.prototype.removeEdge=function(k){this.edges=this.edges.filter(function(Y){return!Y.isEqual(k)}),k.deleteEdge()},I}(),g0=null;function b0(I){var k=Graph.fromGeoJson(I);k.deleteDangles(),k.deleteCutEdges();var Y=[],he=[];return k.getEdgeRings().filter(function(be){return be.isValid()}).forEach(function(be){be.isHole()?Y.push(be):he.push(be)}),Y.forEach(function(be){EdgeRing.findEdgeRingContaining(be,he)&&he.push(be)}),featureCollection(he.map(function(be){return be.toPolygon()}))}function Gp(I,k){var Y=!0;return flattenEach(I,function(he){flattenEach(k,function(be){if(Y===!1)return!1;Y=Wp(he.geometry,be.geometry)})}),Y}function Wp(I,k){switch(I.type){case"Point":switch(k.type){case"Point":return!M0(I.coordinates,k.coordinates);case"LineString":return!xp(k,I);case"Polygon":return!booleanPointInPolygon(I,k)}break;case"LineString":switch(k.type){case"Point":return!xp(I,k);case"LineString":return!U0(I,k);case"Polygon":return!x0(k,I)}break;case"Polygon":switch(k.type){case"Point":return!booleanPointInPolygon(k,I);case"LineString":return!x0(I,k);case"Polygon":return!t0(k,I)}}return!1}function xp(I,k){for(var Y=0;Y0}function x0(I,k){for(var Y=0,he=k.coordinates;Y0}function t0(I,k){for(var Y=0,he=I.coordinates[0];Y0}function np(I,k,Y){var he=Y[0]-I[0],be=Y[1]-I[1],Le=k[0]-I[0],Be=k[1]-I[1],yt=he*Be-be*Le;return yt!==0?!1:Math.abs(Le)>=Math.abs(Be)?Le>0?I[0]<=Y[0]&&Y[0]<=k[0]:k[0]<=Y[0]&&Y[0]<=I[0]:Be>0?I[1]<=Y[1]&&Y[1]<=k[1]:k[1]<=Y[1]&&Y[1]<=I[1]}function M0(I,k){return I[0]===k[0]&&I[1]===k[1]}var kp=null;function r0(I,k){var Y=getGeom(I),he=getGeom(k),be=Y.type,Le=he.type,Be=Y.coordinates,yt=he.coordinates;switch(be){case"Point":switch(Le){case"Point":return P0(Be,yt);default:throw new Error("feature2 "+Le+" geometry not supported")}case"MultiPoint":switch(Le){case"Point":return hp(Y,he);case"MultiPoint":return Xp(Y,he);default:throw new Error("feature2 "+Le+" geometry not supported")}case"LineString":switch(Le){case"Point":return isPointOnLine(he,Y,{ignoreEndVertices:!0});case"LineString":return mm(Y,he);case"MultiPoint":return pm(Y,he);default:throw new Error("feature2 "+Le+" geometry not supported")}case"Polygon":switch(Le){case"Point":return booleanPointInPolygon(he,Y,{ignoreBoundary:!0});case"LineString":return dp(Y,he);case"Polygon":return j0(Y,he);case"MultiPoint":return Tp(Y,he);default:throw new Error("feature2 "+Le+" geometry not supported")}default:throw new Error("feature1 "+be+" geometry not supported")}}function hp(I,k){var Y,he=!1;for(Y=0;Yk[0]||I[2]k[1]||I[3]0)for(var he=0;he0}function R0(I,k){for(var Y=!1,he=!1,be=I.coordinates.length,Le=0;Le=Math.abs(yt)?Be>0?I[0]<=Y[0]&&Y[0]<=k[0]:k[0]<=Y[0]&&Y[0]<=I[0]:yt>0?I[1]<=Y[1]&&Y[1]<=k[1]:k[1]<=Y[1]&&Y[1]<=I[1]:Math.abs(Be)>=Math.abs(yt)?Be>0?I[0]0?I[1]0}function S0(I,k){var Y=getGeom(I).type,he=getGeom(k).type;if(Y!==he)return!1;var be=new GeojsonEquality({precision:6});return be.compare(cleanCoords(I),cleanCoords(k))}var gd=null;function ip(I,k){var Y=!1;return flattenEach(I,function(he){flattenEach(k,function(be){if(Y===!0)return!0;Y=!booleanDisjoint(he.geometry,be.geometry)})}),Y}var O0=A(70298);function Bp(I,k,Y){Y===void 0&&(Y={}),Y.mutate!==!0&&(I=clone(I)),Y.minPoints=Y.minPoints||3;var he=new clustering.DBSCAN,be=he.run(coordAll(I),convertLength(k,Y.units),Y.minPoints,distance),Le=-1;return be.forEach(function(Be){Le++,Be.forEach(function(yt){var Et=I.features[yt];Et.properties||(Et.properties={}),Et.properties.cluster=Le,Et.properties.dbscan="core"})}),he.noise.forEach(function(Be){var yt=I.features[Be];yt.properties||(yt.properties={}),yt.properties.cluster?yt.properties.dbscan="edge":yt.properties.dbscan="noise"}),I}var $0=null,pd=A(89345);function Kp(I,k){k===void 0&&(k={});var Y=I.features.length;k.numberOfClusters=k.numberOfClusters||Math.round(Math.sqrt(Y/2)),k.numberOfClusters>Y&&(k.numberOfClusters=Y),k.mutate!==!0&&(I=clone(I));var he=coordAll(I),be=he.slice(0,k.numberOfClusters),Le=skmeans(he,k.numberOfClusters,be),Be={};return Le.centroids.forEach(function(yt,Et){Be[Et]=yt}),featureEach(I,function(yt,Et){var Je=Le.idxs[Et];yt.properties.cluster=Je,yt.properties.centroid=Be[Je]}),I}var Mp=null;function wp(I,k){if(!I)throw new Error("line1 is required");if(!k)throw new Error("line2 is required");var Y=pp(I,"line1");if(Y!=="LineString")throw new Error("line1 must be a LineString");var he=pp(k,"line2");if(he!=="LineString")throw new Error("line2 must be a LineString");for(var be=lineSegment(cleanCoords(I)).features,Le=lineSegment(cleanCoords(k)).features,Be=0;Be0;){var Et=Be.pop();if(Et===Y)return gh(Et);Et.closed=!0;for(var Je=I.neighbors(Et),Nt=0,Zt=Je.length;Nt0&&(this.content[0]=k,this.bubbleUp(0)),I},remove:function(I){var k=this.content.indexOf(I),Y=this.content.pop();k!==this.content.length-1&&(this.content[k]=Y,this.scoreFunction(Y)0;){var Y=(I+1>>1)-1,he=this.content[Y];if(this.scoreFunction(k)=nr;){for(var lp=[],tp=[],cd=Zt+Jo,Mm=0;cd<=ur;){var tm=point([cd,Uf]),vm=c0(tm,Le);lp.push(vm?0:1),tp.push(cd+"|"+Uf);var Op=distance(tm,I);!vm&&Op0)){if(Gn/=ur,ur<0){if(Gn0){if(Gn>nr)return;Gn>Zt&&(Zt=Gn)}if(Gn=he-yt,!(!ur&&Gn<0)){if(Gn/=ur,ur<0){if(Gn>nr)return;Gn>Zt&&(Zt=Gn)}else if(ur>0){if(Gn0)){if(Gn/=bi,bi<0){if(Gn0){if(Gn>nr)return;Gn>Zt&&(Zt=Gn)}if(Gn=be-Et,!(!bi&&Gn<0)){if(Gn/=bi,bi<0){if(Gn>nr)return;Gn>Zt&&(Zt=Gn)}else if(bi>0){if(Gn0)&&!(nr<1)||(Zt>0&&(I[0]=[yt+Zt*ur,Et+Zt*bi]),nr<1&&(I[1]=[yt+nr*ur,Et+nr*bi])),!0}}}}}function f0(I,k,Y,he,be){var Le=I[1];if(Le)return!0;var Be=I[0],yt=I.left,Et=I.right,Je=yt[0],Nt=yt[1],Zt=Et[0],nr=Et[1],ur=(Je+Zt)/2,bi=(Nt+nr)/2,Gn,mo;if(nr===Nt){if(ur=he)return;if(Je>Zt){if(!Be)Be=[ur,Y];else if(Be[1]>=be)return;Le=[ur,be]}else{if(!Be)Be=[ur,be];else if(Be[1]1)if(Je>Zt){if(!Be)Be=[(Y-mo)/Gn,Y];else if(Be[1]>=be)return;Le=[(be-mo)/Gn,be]}else{if(!Be)Be=[(be-mo)/Gn,be];else if(Be[1]=he)return;Le=[he,Gn*he+mo]}else{if(!Be)Be=[he,Gn*he+mo];else if(Be[0]Td||Math.abs(Le[0][1]-Le[1][1])>Td))&&delete Sn[be]}function p0(I){return Vd[I.index]={site:I,halfedges:[]}}function Id(I,k){var Y=I.site,he=k.left,be=k.right;return Y===be&&(be=he,he=Y),be?Math.atan2(be[1]-he[1],be[0]-he[0]):(Y===he?(he=k[1],be=k[0]):(he=k[0],be=k[1]),Math.atan2(he[0]-be[0],be[1]-he[1]))}function Rd(I,k){return k[+(k.left!==I.site)]}function Fd(I,k){return k[+(k.left===I.site)]}function Up(){for(var I=0,k=Vd.length,Y,he,be,Le;ITd||Math.abs(mo-ur)>Td)&&(Je.splice(Et,0,Sn.push(Ip(yt,bi,Math.abs(Gn-I)Td?[I,Math.abs(nr-I)Td?[Math.abs(ur-he)Td?[Y,Math.abs(nr-Y)Td?[Math.abs(ur-k)=-o0)){var ur=Et*Et+Je*Je,bi=Nt*Nt+Zt*Zt,Gn=(Zt*ur-Je*bi)/nr,mo=(Et*bi-Nt*ur)/nr,xi=_0.pop()||new jp;xi.arc=I,xi.site=be,xi.x=Gn+Be,xi.y=(xi.cy=mo+yt)+Math.sqrt(Gn*Gn+mo*mo),I.circle=xi;for(var Bn=null,fi=_r._;fi;)if(xi.yTd)yt=yt.L;else if(Be=k-W0(yt,Y),Be>Td){if(!yt.R){he=yt;break}yt=yt.R}else{Le>-Td?(he=yt.P,be=yt):Be>-Td?(he=yt,be=yt.N):he=be=yt;break}p0(I);var Et=Vh(I);if(m0.insert(he,Et),!(!he&&!be)){if(he===be){Sp(he),be=Vh(he.site),m0.insert(Et,be),Et.edge=be.edge=qp(he.site,Et.site),F0(he),F0(be);return}if(!be){Et.edge=qp(he.site,Et.site);return}Sp(he),Sp(be);var Je=he.site,Nt=Je[0],Zt=Je[1],nr=I[0]-Nt,ur=I[1]-Zt,bi=be.site,Gn=bi[0]-Nt,mo=bi[1]-Zt,xi=2*(nr*mo-ur*Gn),Bn=nr*nr+ur*ur,fi=Gn*Gn+mo*mo,Ro=[(mo*Bn-ur*fi)/xi+Nt,(nr*fi-Gn*Bn)/xi+Zt];yp(be.edge,Je,bi,Ro),Et.edge=qp(Je,I,null,Ro),be.edge=qp(I,bi,null,Ro),F0(he),F0(be)}}function G0(I,k){var Y=I.site,he=Y[0],be=Y[1],Le=be-k;if(!Le)return he;var Be=I.P;if(!Be)return-1/0;Y=Be.site;var yt=Y[0],Et=Y[1],Je=Et-k;if(!Je)return yt;var Nt=yt-he,Zt=1/Le-1/Je,nr=Nt/Je;return Zt?(-nr+Math.sqrt(nr*nr-2*Zt*(Nt*Nt/(-2*Je)-Et+Je/2+be-Le/2)))/Zt+he:(he+yt)/2}function W0(I,k){var Y=I.N;if(Y)return G0(Y,k);var he=I.site;return he[1]===k?he[0]:1/0}var Td=1e-6,o0=1e-12,m0,Vd,_r,Sn;function mi(I,k,Y){return(I[0]-Y[0])*(k[1]-I[1])-(I[0]-k[0])*(Y[1]-I[1])}function jo(I,k){return k[1]-I[1]||k[0]-I[0]}function Ta(I,k){var Y=I.sort(jo).pop(),he,be,Le;for(Sn=[],Vd=new Array(I.length),m0=new jd,_r=new jd;;)if(Le=k0,Y&&(!Le||Y[1]=Be)return null;var Et=I-yt.site[0],Je=k-yt.site[1],Nt=Et*Et+Je*Je;do yt=he.cells[be=Le],Le=null,yt.halfedges.forEach(function(Zt){var nr=he.edges[Zt],ur=nr.left;if(!((ur===yt.site||!ur)&&!(ur=nr.right))){var bi=I-ur[0],Gn=k-ur[1],mo=bi*bi+Gn*Gn;mo=-270&&(bi=-bi),ur<-180&&ur>=-360&&(Gn=-Gn),Le==="degrees"){var mo=bi*Math.cos(Nt)+Gn*Math.sin(Nt),xi=Gn*Math.cos(Nt)-bi*Math.sin(Nt);bi=mo,Gn=xi}Zt.push([bi+Je[0],Gn+Je[1]])}return Zt.push(Zt[0]),Le==="degrees"?polygon([Zt],Et):transformRotate(polygon([Zt],Et),Be,{pivot:yt})}function Ds(I){var k=I*Math.PI/180;return Math.tan(k)}var Bs=null;function ru(I,k){k===void 0&&(k={});var Y=0,he=0,be=0;return geomEach(I,function(Le,Be,yt){var Et=k.weight?yt==null?void 0:yt[k.weight]:void 0;if(Et=Et==null?1:Et,!isNumber(Et))throw new Error("weight value must be a number for feature index "+Be);Et=Number(Et),Et>0&&coordEach(Le,function(Je){Y+=Je[0]*Et,he+=Je[1]*Et,be+=Et})}),point([Y/be,he/be],k.properties,k)}var xs=null;function nu(I,k){if(k===void 0&&(k={}),k=k||{},!isObject(k))throw new Error("options is invalid");var Y=k.counter||10;if(!isNumber(Y))throw new Error("counter must be a number");var he=k.weight,be=centerMean(I,{weight:k.weight}),Le=featureCollection([]);featureEach(I,function(yt){var Et;Le.features.push(centroid(yt,{properties:{weight:(Et=yt.properties)===null||Et===void 0?void 0:Et[he]}}))});var Be={tolerance:k.tolerance,medianCandidates:[]};return co(be.geometry.coordinates,[0,0],Le,Be,Y)}function co(I,k,Y,he,be){var Le=he.tolerance||.001,Be=0,yt=0,Et=0,Je=0;if(featureEach(Y,function(nr){var ur,bi=(ur=nr.properties)===null||ur===void 0?void 0:ur.weight,Gn=bi==null?1:bi;if(Gn=Number(Gn),!isNumber(Gn))throw new Error("weight value must be a number");if(Gn>0){Je+=1;var mo=Gn*distance(nr,I);mo===0&&(mo=1);var xi=Gn/mo;Be+=nr.geometry.coordinates[0]*xi,yt+=nr.geometry.coordinates[1]*xi,Et+=xi}}),Je<1)throw new Error("no features to measure");var Nt=Be/Et,Zt=yt/Et;return Je===1||be===0||Math.abs(Nt-k[0])0&&(Et=polygon(yt).geometry),Ba(Et,Je),yt=Je.slice(0);Y.push(polygon(yt,Be));break;case"MultiPolygon":yt=[[[]]];for(var Zt=0;Zt0&&(Et=multiPolygon(yt).geometry),Lu(Et,Je),yt=Je.slice(0);Y.push(multiPolygon(yt,Be));break;default:throw new Error("geometry is invalid, must be Polygon or MultiPolygon")}}),featureCollection(Y)}function Ba(I,k){var Y=0,he=0;coordEach(I,function(be,Le,Be,yt,Et){Et>Y&&(Y=Et,he=Le,k.push([]));var Je=Le-he,Nt=I.coordinates[Et][Je+1],Zt=be[0],nr=be[1],ur=Nt[0],bi=Nt[1];k[Et].push([.75*Zt+.25*ur,.75*nr+.25*bi]),k[Et].push([.25*Zt+.75*ur,.25*nr+.75*bi])},!0),k.forEach(function(be){be.push(be[0])})}function Lu(I,k){var Y=0,he=0,be=0;coordEach(I,function(Le,Be,yt,Et,Je){Et>be&&(be=Et,he=Be,k.push([[]])),Je>Y&&(Y=Je,he=Be,k[Et].push([]));var Nt=Be-he,Zt=I.coordinates[Et][Je][Nt+1],nr=Le[0],ur=Le[1],bi=Zt[0],Gn=Zt[1];k[Et][Je].push([.75*nr+.25*bi,.75*ur+.25*Gn]),k[Et][Je].push([.25*nr+.75*bi,.25*ur+.75*Gn])},!0),k.forEach(function(Le){Le.forEach(function(Be){Be.push(Be[0])})})}var uc=null;function Pc(I,k,Y){Y===void 0&&(Y=2);var he=getCoord(I),be=getCoord(k),Le=he[0]-be[0],Be=he[1]-be[1];return Y===1?Math.abs(Le)+Math.abs(Be):Math.pow(Math.pow(Le,Y)+Math.pow(Be,Y),1/Y)}function Mu(I,k){k=k||{};var Y=k.threshold||1e4,he=k.p||2,be=k.binary||!1,Le=k.alpha||-1,Be=k.standardization||!1,yt=[];featureEach(I,function(ur){yt.push(centroid(ur))});for(var Et=[],Je=0;Jehe&&(Le[0]=he),Le[0]<-he&&(Le[0]=-he),Le[1]>he&&(Le[1]=he),Le[1]<-he&&(Le[1]=-he),Le}function Jl(I){var k=180/Math.PI,Y=6378137;return[I[0]*k/Y,(Math.PI*.5-2*Math.atan(Math.exp(-I[1]/Y)))*k]}function yh(I){return I<0?-1:I>0?1:0}var Gd=function(){for(var I=0,k=0,Y=arguments.length;k0?Et+Nt[Je-1]:Et}),yt.forEach(function(Et){Et=Et*2*Math.PI/yt[yt.length-1];var Je=Math.random();Be.push([Je*(k.max_radial_length||10)*Math.sin(Et),Je*(k.max_radial_length||10)*Math.cos(Et)])}),Be[Be.length-1]=Be[0],Be=Be.map(Tf(Wd(k.bbox))),Y.push(polygon([Be]))},be=0;be0?1:I<0?-1:0},mr=Math.sqrt,pn=Math.tan;function Jn(I){return I>1?0:I<-1?ti:Math.acos(I)}function ui(I){return I>1?_o:I<-1?-_o:Math.asin(I)}function ci(I){return(I=Ot(I/2))*I}function no(){}function Wa(I,k){I&&Go.hasOwnProperty(I.type)&&Go[I.type](I,k)}var ha={Feature:function(I,k){Wa(I.geometry,k)},FeatureCollection:function(I,k){for(var Y=I.features,he=-1,be=Y.length;++he=0?1:-1,be=he*Y,Le=F(k),Be=Ot(k),yt=$f*Be,Et=vh*Le+yt*F(be),Je=yt*he*Ot(be);gl.add(P(Je,Et)),Th=I,vh=Le,$f=Be}function Mf(I){return du.reset(),stream(I,Nl),du*2}function lm(I){return[P(I[1],I[0]),ui(I[2])]}function bm(I){var k=I[0],Y=I[1],he=F(Y);return[he*F(k),he*Ot(k),Ot(Y)]}function xm(I,k){return I[0]*k[0]+I[1]*k[1]+I[2]*k[2]}function Rp(I,k){return[I[1]*k[2]-I[2]*k[1],I[2]*k[0]-I[0]*k[2],I[0]*k[1]-I[1]*k[0]]}function Om(I,k){I[0]+=k[0],I[1]+=k[1],I[2]+=k[2]}function qd(I,k){return[I[0]*k,I[1]*k,I[2]*k]}function N0(I){var k=mr(I[0]*I[0]+I[1]*I[1]+I[2]*I[2]);I[0]/=k,I[1]/=k,I[2]/=k}var ld,Qp,Gh,wd,Md,em,Bd,Qd,Jd=ao(),Ed,_p,oe={point:o,lineStart:l,lineEnd:g,polygonStart:function(){oe.point=M,oe.lineStart=j,oe.lineEnd=J,Jd.reset(),Nl.polygonStart()},polygonEnd:function(){Nl.polygonEnd(),oe.point=o,oe.lineStart=l,oe.lineEnd=g,gl<0?(ld=-(Gh=180),Qp=-(wd=90)):Jd>Rr?wd=90:Jd<-Rr&&(Qp=-90),_p[0]=ld,_p[1]=Gh}};function o(I,k){Ed.push(_p=[ld=I,Gh=I]),kwd&&(wd=k)}function s(I,k){var Y=bm([I*Di,k*Di]);if(Qd){var he=Rp(Qd,Y),be=[he[1],-he[0],0],Le=Rp(be,he);N0(Le),Le=lm(Le);var Be=I-Md,yt=Be>0?1:-1,Et=Le[0]*ji*yt,Je,Nt=jn(Be)>180;Nt^(yt*Mdwd&&(wd=Je)):(Et=(Et+360)%360-180,Nt^(yt*Mdwd&&(wd=k))),Nt?Ive(ld,Gh)&&(Gh=I):ve(I,Gh)>ve(ld,Gh)&&(ld=I):Gh>=ld?(IGh&&(Gh=I)):I>Md?ve(ld,I)>ve(ld,Gh)&&(Gh=I):ve(I,Gh)>ve(ld,Gh)&&(ld=I)}else Ed.push(_p=[ld=I,Gh=I]);kwd&&(wd=k),Qd=Y,Md=I}function l(){oe.point=s}function g(){_p[0]=ld,_p[1]=Gh,oe.point=o,Qd=null}function M(I,k){if(Qd){var Y=I-Md;Jd.add(jn(Y)>180?Y+(Y>0?360:-360):Y)}else em=I,Bd=k;Nl.point(I,k),s(I,k)}function j(){Nl.lineStart()}function J(){M(em,Bd),Nl.lineEnd(),jn(Jd)>Rr&&(ld=-(Gh=180)),_p[0]=ld,_p[1]=Gh,Qd=null}function ve(I,k){return(k-=I)<0?k+360:k}function ze(I,k){return I[0]-k[0]}function lt(I,k){return I[0]<=I[1]?I[0]<=k&&k<=I[1]:kve(he[0],he[1])&&(he[1]=be[1]),ve(be[0],he[1])>ve(he[0],he[1])&&(he[0]=be[0])):Le.push(he=be);for(Be=-1/0,Y=Le.length-1,k=0,he=Le[Y];k<=Y;he=be,++k)be=Le[k],(yt=ve(he[1],be[0]))>Be&&(Be=yt,ld=be[0],Gh=he[1])}return Ed=_p=null,ld===1/0||Qp===1/0?[[NaN,NaN],[NaN,NaN]]:[[ld,Qp],[Gh,wd]]}var $t,lr,wr,Vr,$r,Xr,Gr,Br,Tn,Hn,yi,vo,Eo,Xo,ys,Yo,es={sphere:no,point:qa,lineStart:is,lineEnd:pu,polygonStart:function(){es.lineStart=nl,es.lineEnd=la},polygonEnd:function(){es.lineStart=is,es.lineEnd=pu}};function qa(I,k){I*=Di,k*=Di;var Y=F(k);Ts(Y*F(I),Y*Ot(I),Ot(k))}function Ts(I,k,Y){++$t,wr+=(I-wr)/$t,Vr+=(k-Vr)/$t,$r+=(Y-$r)/$t}function is(){es.point=ts}function ts(I,k){I*=Di,k*=Di;var Y=F(k);Xo=Y*F(I),ys=Y*Ot(I),Yo=Ot(k),es.point=Rs,Ts(Xo,ys,Yo)}function Rs(I,k){I*=Di,k*=Di;var Y=F(k),he=Y*F(I),be=Y*Ot(I),Le=Ot(k),Be=P(mr((Be=ys*Le-Yo*be)*Be+(Be=Yo*he-Xo*Le)*Be+(Be=Xo*be-ys*he)*Be),Xo*he+ys*be+Yo*Le);lr+=Be,Xr+=Be*(Xo+(Xo=he)),Gr+=Be*(ys+(ys=be)),Br+=Be*(Yo+(Yo=Le)),Ts(Xo,ys,Yo)}function pu(){es.point=qa}function nl(){es.point=Es}function la(){sl(vo,Eo),es.point=qa}function Es(I,k){vo=I,Eo=k,I*=Di,k*=Di,es.point=sl;var Y=F(k);Xo=Y*F(I),ys=Y*Ot(I),Yo=Ot(k),Ts(Xo,ys,Yo)}function sl(I,k){I*=Di,k*=Di;var Y=F(k),he=Y*F(I),be=Y*Ot(I),Le=Ot(k),Be=ys*Le-Yo*be,yt=Yo*he-Xo*Le,Et=Xo*be-ys*he,Je=mr(Be*Be+yt*yt+Et*Et),Nt=ui(Je),Zt=Je&&-Nt/Je;Tn+=Zt*Be,Hn+=Zt*yt,yi+=Zt*Et,lr+=Nt,Xr+=Nt*(Xo+(Xo=he)),Gr+=Nt*(ys+(ys=be)),Br+=Nt*(Yo+(Yo=Le)),Ts(Xo,ys,Yo)}function Bf(I){$t=lr=wr=Vr=$r=Xr=Gr=Br=Tn=Hn=yi=0,stream(I,es);var k=Tn,Y=Hn,he=yi,be=k*k+Y*Y+he*he;return beti?I-Pi:I<-ti?I+Pi:I,k]}Vl.invert=Vl;function oc(I,k,Y){return(I%=tau)?k||Y?compose(xc(I),ih(k,Y)):xc(I):k||Y?ih(k,Y):Vl}function zc(I){return function(k,Y){return k+=I,[k>pi?k-tau:k<-pi?k+tau:k,Y]}}function xc(I){var k=zc(I);return k.invert=zc(-I),k}function ih(I,k){var Y=cos(I),he=sin(I),be=cos(k),Le=sin(k);function Be(yt,Et){var Je=cos(Et),Nt=cos(yt)*Je,Zt=sin(yt)*Je,nr=sin(Et),ur=nr*Y+Nt*he;return[atan2(Zt*be-ur*Le,Nt*Y-nr*he),asin(ur*be+Zt*Le)]}return Be.invert=function(yt,Et){var Je=cos(Et),Nt=cos(yt)*Je,Zt=sin(yt)*Je,nr=sin(Et),ur=nr*be-Zt*Le;return[atan2(Zt*be+nr*Le,Nt*Y+ur*he),asin(ur*Y-Nt*he)]},Be}function wh(I){I=oc(I[0]*radians,I[1]*radians,I.length>2?I[2]*radians:0);function k(Y){return Y=I(Y[0]*radians,Y[1]*radians),Y[0]*=degrees,Y[1]*=degrees,Y}return k.invert=function(Y){return Y=I.invert(Y[0]*radians,Y[1]*radians),Y[0]*=degrees,Y[1]*=degrees,Y},k}function hh(I,k,Y,he,be,Le){if(Y){var Be=cos(k),yt=sin(k),Et=he*Y;be==null?(be=k+he*tau,Le=k-Et/2):(be=dh(Be,be),Le=dh(Be,Le),(he>0?beLe)&&(be+=he*tau));for(var Je,Nt=be;he>0?Nt>Le:Nt=0;--yt)be.point((Zt=Nt[yt])[0],Zt[1]);else he(nr.x,nr.p.x,-1,be);nr=nr.p}nr=nr.o,Nt=nr.z,ur=!ur}while(!nr.v);be.lineEnd()}}}function zl(I){if(k=I.length){for(var k,Y=0,he=I[0],be;++Y0)do nr.point(ur===0||ur===3?I:Y,ur>1?he:k);while((ur=(ur+Zt+4)%4)!==bi);else nr.point(Nt[0],Nt[1])}function Be(Je,Nt){return abs(Je[0]-I)0?0:3:abs(Je[0]-Y)0?2:1:abs(Je[1]-k)0?1:0:Nt>0?3:2}function yt(Je,Nt){return Et(Je.x,Nt.x)}function Et(Je,Nt){var Zt=Be(Je,1),nr=Be(Nt,1);return Zt!==nr?Zt-nr:Zt===0?Nt[1]-Je[1]:Zt===1?Je[0]-Nt[0]:Zt===2?Je[1]-Nt[1]:Nt[0]-Je[0]}return function(Je){var Nt=Je,Zt=clipBuffer(),nr,ur,bi,Gn,mo,xi,Bn,fi,Ro,So,ia,Jo={point:ka,lineStart:Bh,lineEnd:Wh,polygonStart:ph,polygonEnd:Zl};function ka(Uf,wf){be(Uf,wf)&&Nt.point(Uf,wf)}function Ui(){for(var Uf=0,wf=0,lp=ur.length;wfhe&&(Jp-vm)*(he-Op)>(C0-Op)*(I-vm)&&++Uf:C0<=he&&(Jp-vm)*(he-Op)<(C0-Op)*(I-vm)&&--Uf;return Uf}function ph(){Nt=Zt,nr=[],ur=[],ia=!0}function Zl(){var Uf=Ui(),wf=ia&&Uf,lp=(nr=merge(nr)).length;(wf||lp)&&(Je.polygonStart(),wf&&(Je.lineStart(),Le(null,null,1,Je),Je.lineEnd()),lp&&clipPolygon(nr,yt,Uf,Le,Je),Je.polygonEnd()),Nt=Je,nr=ur=bi=null}function Bh(){Jo.point=Fl,ur&&ur.push(bi=[]),So=!0,Ro=!1,Bn=fi=NaN}function Wh(){nr&&(Fl(Gn,mo),xi&&Ro&&Zt.rejoin(),nr.push(Zt.result())),Jo.point=ka,Ro&&Nt.lineEnd()}function Fl(Uf,wf){var lp=be(Uf,wf);if(ur&&bi.push([Uf,wf]),So)Gn=Uf,mo=wf,xi=lp,So=!1,lp&&(Nt.lineStart(),Nt.point(Uf,wf));else if(lp&&Ro)Nt.point(Uf,wf);else{var tp=[Bn=Math.max(sd,Math.min(Lh,Bn)),fi=Math.max(sd,Math.min(Lh,fi))],cd=[Uf=Math.max(sd,Math.min(Lh,Uf)),wf=Math.max(sd,Math.min(Lh,wf))];clipLine(tp,cd,I,k,Y,he)?(Ro||(Nt.lineStart(),Nt.point(tp[0],tp[1])),Nt.point(cd[0],cd[1]),lp||Nt.lineEnd(),ia=!1):lp&&(Nt.lineStart(),Nt.point(Uf,wf),ia=!1)}Bn=Uf,fi=wf,Ro=lp}return Jo}}function gc(){var I=0,k=0,Y=960,he=500,be,Le,Be;return Be={stream:function(yt){return be&&Le===yt?be:be=pa(I,k,Y,he)(Le=yt)},extent:function(yt){return arguments.length?(I=+yt[0][0],k=+yt[0][1],Y=+yt[1][0],he=+yt[1][1],be=Le=null,Be):[[I,k],[Y,he]]}}}var Rc=ao();function tc(I,k){var Y=k[0],he=k[1],be=[Ot(Y),-F(Y),0],Le=0,Be=0;Rc.reset();for(var yt=0,Et=I.length;yt=0?1:-1,ka=Jo*ia,Ui=ka>ti,ph=bi*Ro;if(Rc.add(P(ph*Jo*Ot(ka),Gn*So+ph*F(ka))),Le+=Ui?ia+Jo*Pi:ia,Ui^nr>=Y^Bn>=Y){var Zl=Rp(bm(Zt),bm(xi));N0(Zl);var Bh=Rp(be,Zl);N0(Bh);var Wh=(Ui^ia>=0?-1:1)*ui(Bh[2]);(he>Wh||he===Wh&&(Zl[0]||Zl[1]))&&(Be+=Ui^ia>=0?1:-1)}}return(Le<-Rr||Leepsilon}).map(nr)).concat(range(ceil(Le/Je)*Je,be,Je).filter(function(fi){return abs(fi%Zt)>epsilon}).map(ur))}return xi.lines=function(){return Bn().map(function(fi){return{type:"LineString",coordinates:fi}})},xi.outline=function(){return{type:"Polygon",coordinates:[bi(he).concat(Gn(Be).slice(1),bi(Y).reverse().slice(1),Gn(yt).reverse().slice(1))]}},xi.extent=function(fi){return arguments.length?xi.extentMajor(fi).extentMinor(fi):xi.extentMinor()},xi.extentMajor=function(fi){return arguments.length?(he=+fi[0][0],Y=+fi[1][0],yt=+fi[0][1],Be=+fi[1][1],he>Y&&(fi=he,he=Y,Y=fi),yt>Be&&(fi=yt,yt=Be,Be=fi),xi.precision(mo)):[[he,yt],[Y,Be]]},xi.extentMinor=function(fi){return arguments.length?(k=+fi[0][0],I=+fi[1][0],Le=+fi[0][1],be=+fi[1][1],k>I&&(fi=k,k=I,I=fi),Le>be&&(fi=Le,Le=be,be=fi),xi.precision(mo)):[[k,Le],[I,be]]},xi.step=function(fi){return arguments.length?xi.stepMajor(fi).stepMinor(fi):xi.stepMinor()},xi.stepMajor=function(fi){return arguments.length?(Nt=+fi[0],Zt=+fi[1],xi):[Nt,Zt]},xi.stepMinor=function(fi){return arguments.length?(Et=+fi[0],Je=+fi[1],xi):[Et,Je]},xi.precision=function(fi){return arguments.length?(mo=+fi,nr=Zn(Le,be,90),ur=ai(k,I,mo),bi=Zn(yt,Be,90),Gn=ai(he,Y,mo),xi):mo},xi.extentMajor([[-180,-90+epsilon],[180,90-epsilon]]).extentMinor([[-180,-80-epsilon],[180,80+epsilon]])}function za(){return Va()()}function ua(I,k){var Y=I[0]*radians,he=I[1]*radians,be=k[0]*radians,Le=k[1]*radians,Be=cos(he),yt=sin(he),Et=cos(Le),Je=sin(Le),Nt=Be*cos(Y),Zt=Be*sin(Y),nr=Et*cos(be),ur=Et*sin(be),bi=2*asin(sqrt(haversin(Le-he)+Be*Et*haversin(be-Y))),Gn=sin(bi),mo=bi?function(xi){var Bn=sin(xi*=bi)/Gn,fi=sin(bi-xi)/Gn,Ro=fi*Nt+Bn*nr,So=fi*Zt+Bn*ur,ia=fi*yt+Bn*Je;return[atan2(So,Ro)*degrees,atan2(ia,sqrt(Ro*Ro+So*So))*degrees]}:function(){return[Y*degrees,he*degrees]};return mo.distance=bi,mo}var Za=ao(),rs=ao(),os,Ua,us,Xu,_u={point:no,lineStart:no,lineEnd:no,polygonStart:function(){_u.lineStart=Uc,_u.lineEnd=sh},polygonEnd:function(){_u.lineStart=_u.lineEnd=_u.point=no,Za.add(jn(rs)),rs.reset()},result:function(){var I=Za/2;return Za.reset(),I}};function Uc(){_u.point=ah}function ah(I,k){_u.point=gf,os=us=I,Ua=Xu=k}function gf(I,k){rs.add(Xu*I-us*k),us=I,Xu=k}function sh(){gf(os,Ua)}var sp=null,Ld=1/0,ep=Ld,up=-Ld,Ap=up,a0={point:Mh,lineStart:no,lineEnd:no,polygonStart:no,polygonEnd:no,result:function(){var I=[[Ld,ep],[up,Ap]];return up=Ap=-(ep=Ld=1/0),I}};function Mh(I,k){Iup&&(up=I),kAp&&(Ap=k)}var ju=null,Ws=0,K=0,ne=0,ue=0,Ue=0,Ut=0,vr=0,Cr=0,Jr=0,Mn,kn,$i,wa,Os={point:Nu,lineStart:yl,lineEnd:Du,polygonStart:function(){Os.lineStart=Ml,Os.lineEnd=Wl},polygonEnd:function(){Os.point=Nu,Os.lineStart=yl,Os.lineEnd=Du},result:function(){var I=Jr?[vr/Jr,Cr/Jr]:Ut?[ue/Ut,Ue/Ut]:ne?[Ws/ne,K/ne]:[NaN,NaN];return Ws=K=ne=ue=Ue=Ut=vr=Cr=Jr=0,I}};function Nu(I,k){Ws+=I,K+=k,++ne}function yl(){Os.point=js}function js(I,k){Os.point=$s,Nu($i=I,wa=k)}function $s(I,k){var Y=I-$i,he=k-wa,be=mr(Y*Y+he*he);ue+=be*($i+I)/2,Ue+=be*(wa+k)/2,Ut+=be,Nu($i=I,wa=k)}function Du(){Os.point=Nu}function Ml(){Os.point=yf}function Wl(){Nf(Mn,kn)}function yf(I,k){Os.point=Nf,Nu(Mn=$i=I,kn=wa=k)}function Nf(I,k){var Y=I-$i,he=k-wa,be=mr(Y*Y+he*he);ue+=be*($i+I)/2,Ue+=be*(wa+k)/2,Ut+=be,be=wa*I-$i*k,vr+=be*($i+I),Cr+=be*(wa+k),Jr+=be*3,Nu($i=I,wa=k)}var cf=null;function jc(I){this._context=I}jc.prototype={_radius:4.5,pointRadius:function(I){return this._radius=I,this},polygonStart:function(){this._line=0},polygonEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){this._line===0&&this._context.closePath(),this._point=NaN},point:function(I,k){switch(this._point){case 0:{this._context.moveTo(I,k),this._point=1;break}case 1:{this._context.lineTo(I,k);break}default:{this._context.moveTo(I+this._radius,k),this._context.arc(I,k,this._radius,0,Pi);break}}},result:no};var eh=ao(),uh,qc,mf,Dh,lh,Eh={point:no,lineStart:function(){Eh.point=Uh},lineEnd:function(){uh&&Qi(qc,mf),Eh.point=no},polygonStart:function(){uh=!0},polygonEnd:function(){uh=null},result:function(){var I=+eh;return eh.reset(),I}};function Uh(I,k){Eh.point=Qi,qc=Dh=I,mf=lh=k}function Qi(I,k){Dh-=I,lh-=k,eh.add(mr(Dh*Dh+lh*lh)),Dh=I,lh=k}var Yn=null;function Ti(){this._string=[]}Ti.prototype={_radius:4.5,_circle:ca(4.5),pointRadius:function(I){return(I=+I)!==this._radius&&(this._radius=I,this._circle=null),this},polygonStart:function(){this._line=0},polygonEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){this._line===0&&this._string.push("Z"),this._point=NaN},point:function(I,k){switch(this._point){case 0:{this._string.push("M",I,",",k),this._point=1;break}case 1:{this._string.push("L",I,",",k);break}default:{this._circle==null&&(this._circle=ca(this._radius)),this._string.push("M",I,",",k,this._circle);break}}},result:function(){if(this._string.length){var I=this._string.join("");return this._string=[],I}else return null}};function ca(I){return"m0,"+I+"a"+I+","+I+" 0 1,1 0,"+-2*I+"a"+I+","+I+" 0 1,1 0,"+2*I+"z"}function Qa(I,k){var Y=4.5,he,be;function Le(Be){return Be&&(typeof Y=="function"&&be.pointRadius(+Y.apply(this,arguments)),stream(Be,he(be))),be.result()}return Le.area=function(Be){return stream(Be,he(pathArea)),pathArea.result()},Le.measure=function(Be){return stream(Be,he(pathMeasure)),pathMeasure.result()},Le.bounds=function(Be){return stream(Be,he(pathBounds)),pathBounds.result()},Le.centroid=function(Be){return stream(Be,he(pathCentroid)),pathCentroid.result()},Le.projection=function(Be){return arguments.length?(he=Be==null?(I=null,identity):(I=Be).stream,Le):I},Le.context=function(Be){return arguments.length?(be=Be==null?(k=null,new PathString):new PathContext(k=Be),typeof Y!="function"&&be.pointRadius(Y),Le):k},Le.pointRadius=function(Be){return arguments.length?(Y=typeof Be=="function"?Be:(be.pointRadius(+Be),+Be),Le):Y},Le.projection(I).context(k)}function Oa(){var I=[],k;return{point:function(Y,he){k.push([Y,he])},lineStart:function(){I.push(k=[])},lineEnd:no,rejoin:function(){I.length>1&&I.push(I.pop().concat(I.shift()))},result:function(){var Y=I;return I=[],k=null,Y}}}function Xl(I,k,Y,he){return function(be,Le){var Be=k(Le),yt=be.invert(he[0],he[1]),Et=Oa(),Je=k(Et),Nt=!1,Zt,nr,ur,bi={point:Gn,lineStart:xi,lineEnd:Bn,polygonStart:function(){bi.point=fi,bi.lineStart=Ro,bi.lineEnd=So,nr=[],Zt=[]},polygonEnd:function(){bi.point=Gn,bi.lineStart=xi,bi.lineEnd=Bn,nr=(0,Zc.TS)(nr);var ia=tc(Zt,yt);nr.length?(Nt||(Le.polygonStart(),Nt=!0),Jc(nr,Pf,ia,Y,Le)):ia&&(Nt||(Le.polygonStart(),Nt=!0),Le.lineStart(),Y(null,null,1,Le),Le.lineEnd()),Nt&&(Le.polygonEnd(),Nt=!1),nr=Zt=null},sphere:function(){Le.polygonStart(),Le.lineStart(),Y(null,null,1,Le),Le.lineEnd(),Le.polygonEnd()}};function Gn(ia,Jo){var ka=be(ia,Jo);I(ia=ka[0],Jo=ka[1])&&Le.point(ia,Jo)}function mo(ia,Jo){var ka=be(ia,Jo);Be.point(ka[0],ka[1])}function xi(){bi.point=mo,Be.lineStart()}function Bn(){bi.point=Gn,Be.lineEnd()}function fi(ia,Jo){ur.push([ia,Jo]);var ka=be(ia,Jo);Je.point(ka[0],ka[1])}function Ro(){Je.lineStart(),ur=[]}function So(){fi(ur[0][0],ur[0][1]),Je.lineEnd();var ia=Je.clean(),Jo=Et.result(),ka,Ui=Jo.length,ph,Zl,Bh;if(ur.pop(),Zt.push(ur),ur=null,!!Ui){if(ia&1){if(Zl=Jo[0],(ph=Zl.length-1)>0){for(Nt||(Le.polygonStart(),Nt=!0),Le.lineStart(),ka=0;ka1&&ia&2&&Jo.push(Jo.pop().concat(Jo.shift())),nr.push(Jo.filter(Vc))}}return bi}}function Vc(I){return I.length>1}function Pf(I,k){return((I=I.x)[0]<0?I[1]-_o-Rr:_o-I[1])-((k=k.x)[0]<0?k[1]-_o-Rr:_o-k[1])}var $d=Xl(function(){return!0},qh,wm,[-ti,-_o]);function qh(I){var k=NaN,Y=NaN,he=NaN,be;return{lineStart:function(){I.lineStart(),be=1},point:function(Le,Be){var yt=Le>0?ti:-ti,Et=jn(Le-k);jn(Et-ti)0?_o:-_o),I.point(he,Y),I.lineEnd(),I.lineStart(),I.point(yt,Y),I.point(Le,Y),be=0):he!==yt&&Et>=ti&&(jn(k-he)Rr?D((Ot(k)*(Le=F(he))*Ot(Y)-Ot(he)*(be=F(k))*Ot(I))/(be*Le*Be)):(k+he)/2}function wm(I,k,Y,he){var be;if(I==null)be=Y*_o,he.point(-ti,be),he.point(0,be),he.point(ti,be),he.point(ti,0),he.point(ti,-be),he.point(0,-be),he.point(-ti,-be),he.point(-ti,0),he.point(-ti,be);else if(jn(I[0]-k[0])>Rr){var Le=I[0]0,be=abs(Y)>epsilon;function Le(Nt,Zt,nr,ur){circleStream(ur,I,k,nr,Nt,Zt)}function Be(Nt,Zt){return cos(Nt)*cos(Zt)>Y}function yt(Nt){var Zt,nr,ur,bi,Gn;return{lineStart:function(){bi=ur=!1,Gn=1},point:function(mo,xi){var Bn=[mo,xi],fi,Ro=Be(mo,xi),So=he?Ro?0:Je(mo,xi):Ro?Je(mo+(mo<0?pi:-pi),xi):0;if(!Zt&&(bi=ur=Ro)&&Nt.lineStart(),Ro!==ur&&(fi=Et(Zt,Bn),(!fi||pointEqual(Zt,fi)||pointEqual(Bn,fi))&&(Bn[0]+=epsilon,Bn[1]+=epsilon,Ro=Be(Bn[0],Bn[1]))),Ro!==ur)Gn=0,Ro?(Nt.lineStart(),fi=Et(Bn,Zt),Nt.point(fi[0],fi[1])):(fi=Et(Zt,Bn),Nt.point(fi[0],fi[1]),Nt.lineEnd()),Zt=fi;else if(be&&Zt&&he^Ro){var ia;!(So&nr)&&(ia=Et(Bn,Zt,!0))&&(Gn=0,he?(Nt.lineStart(),Nt.point(ia[0][0],ia[0][1]),Nt.point(ia[1][0],ia[1][1]),Nt.lineEnd()):(Nt.point(ia[1][0],ia[1][1]),Nt.lineEnd(),Nt.lineStart(),Nt.point(ia[0][0],ia[0][1])))}Ro&&(!Zt||!pointEqual(Zt,Bn))&&Nt.point(Bn[0],Bn[1]),Zt=Bn,ur=Ro,nr=So},lineEnd:function(){ur&&Nt.lineEnd(),Zt=null},clean:function(){return Gn|(bi&&ur)<<1}}}function Et(Nt,Zt,nr){var ur=cartesian(Nt),bi=cartesian(Zt),Gn=[1,0,0],mo=cartesianCross(ur,bi),xi=cartesianDot(mo,mo),Bn=mo[0],fi=xi-Bn*Bn;if(!fi)return!nr&&Nt;var Ro=Y*xi/fi,So=-Y*Bn/fi,ia=cartesianCross(Gn,mo),Jo=cartesianScale(Gn,Ro),ka=cartesianScale(mo,So);cartesianAddInPlace(Jo,ka);var Ui=ia,ph=cartesianDot(Jo,Ui),Zl=cartesianDot(Ui,Ui),Bh=ph*ph-Zl*(cartesianDot(Jo,Jo)-1);if(!(Bh<0)){var Wh=sqrt(Bh),Fl=cartesianScale(Ui,(-ph-Wh)/Zl);if(cartesianAddInPlace(Fl,Jo),Fl=spherical(Fl),!nr)return Fl;var Uf=Nt[0],wf=Zt[0],lp=Nt[1],tp=Zt[1],cd;wf0^Fl[1]<(abs(Fl[0]-Uf)pi^(Uf<=Fl[0]&&Fl[0]<=wf)){var Op=cartesianScale(Ui,(-ph+Wh)/Zl);return cartesianAddInPlace(Op,Jo),[Fl,spherical(Op)]}}}function Je(Nt,Zt){var nr=he?I:pi-I,ur=0;return Nt<-nr?ur|=1:Nt>nr&&(ur|=2),Zt<-nr?ur|=4:Zt>nr&&(ur|=8),ur}return clip(Be,yt,Le,he?[0,-I]:[-pi,I-pi])}function qv(I){return{stream:rv(I)}}function rv(I){return function(k){var Y=new Tv;for(var he in I)Y[he]=I[he];return Y.stream=k,Y}}function Tv(){}Tv.prototype={constructor:Tv,point:function(I,k){this.stream.point(I,k)},sphere:function(){this.stream.sphere()},lineStart:function(){this.stream.lineStart()},lineEnd:function(){this.stream.lineEnd()},polygonStart:function(){this.stream.polygonStart()},polygonEnd:function(){this.stream.polygonEnd()}};function Qg(I,k,Y){var he=k[1][0]-k[0][0],be=k[1][1]-k[0][1],Le=I.clipExtent&&I.clipExtent();I.scale(150).translate([0,0]),Le!=null&&I.clipExtent(null),geoStream(Y,I.stream(boundsStream));var Be=boundsStream.result(),yt=Math.min(he/(Be[1][0]-Be[0][0]),be/(Be[1][1]-Be[0][1])),Et=+k[0][0]+(he-yt*(Be[1][0]+Be[0][0]))/2,Je=+k[0][1]+(be-yt*(Be[1][1]+Be[0][1]))/2;return Le!=null&&I.clipExtent(Le),I.scale(yt*150).translate([Et,Je])}function Ly(I,k,Y){return Qg(I,[[0,0],k],Y)}var Ag=16,Jg=F(30*Di);function Dy(I,k){return+k?ey(I,k):Nv(I)}function Nv(I){return transformer({point:function(k,Y){k=I(k,Y),this.stream.point(k[0],k[1])}})}function ey(I,k){function Y(he,be,Le,Be,yt,Et,Je,Nt,Zt,nr,ur,bi,Gn,mo){var xi=Je-he,Bn=Nt-be,fi=xi*xi+Bn*Bn;if(fi>4*k&&Gn--){var Ro=Be+nr,So=yt+ur,ia=Et+bi,Jo=sqrt(Ro*Ro+So*So+ia*ia),ka=asin(ia/=Jo),Ui=abs(abs(ia)-1)k||abs((xi*Wh+Bn*Fl)/fi-.5)>.3||Be*nr+yt*ur+Et*bi2?Fl[2]%360*radians:0,Bh()):[Je*degrees,Nt*degrees,Zt*degrees]},Ui.precision=function(Fl){return arguments.length?(ia=resample(Zl,So=Fl*Fl),Wh()):sqrt(So)},Ui.fitExtent=function(Fl,Uf){return fitExtent(Ui,Fl,Uf)},Ui.fitSize=function(Fl,Uf){return fitSize(Ui,Fl,Uf)};function Bh(){ur=compose(nr=rotateRadians(Je,Nt,Zt),k);var Fl=k(yt,Et);return Le=he-Fl[0]*Y,Be=be+Fl[1]*Y,Wh()}function Wh(){return Jo=ka=null,Ui}return function(){return k=I.apply(this,arguments),Ui.invert=k.invert&&ph,Bh()}}function h1(I){var k=0,Y=pi/3,he=projectionMutator(I),be=he(k,Y);return be.parallels=function(Le){return arguments.length?he(k=Le[0]*radians,Y=Le[1]*radians):[k*degrees,Y*degrees]},be}function zv(I){var k=cos(I);function Y(he,be){return[he*k,sin(be)/k]}return Y.invert=function(he,be){return[he/k,asin(be*k)]},Y}function xg(I,k){var Y=sin(I),he=(Y+sin(k))/2;if(abs(he)=.12&&mo<.234&&Gn>=-.425&&Gn<-.214?be:mo>=.166&&mo<.234&&Gn>=-.214&&Gn<-.115?Be:Y).invert(nr)},Nt.stream=function(nr){return I&&k===nr?I:I=p1([Y.stream(k=nr),be.stream(nr),Be.stream(nr)])},Nt.precision=function(nr){return arguments.length?(Y.precision(nr),be.precision(nr),Be.precision(nr),Zt()):Y.precision()},Nt.scale=function(nr){return arguments.length?(Y.scale(nr),be.scale(nr*.35),Be.scale(nr),Nt.translate(Y.translate())):Y.scale()},Nt.translate=function(nr){if(!arguments.length)return Y.translate();var ur=Y.scale(),bi=+nr[0],Gn=+nr[1];return he=Y.translate(nr).clipExtent([[bi-.455*ur,Gn-.238*ur],[bi+.455*ur,Gn+.238*ur]]).stream(Je),Le=be.translate([bi-.307*ur,Gn+.201*ur]).clipExtent([[bi-.425*ur+epsilon,Gn+.12*ur+epsilon],[bi-.214*ur-epsilon,Gn+.234*ur-epsilon]]).stream(Je),yt=Be.translate([bi-.205*ur,Gn+.212*ur]).clipExtent([[bi-.214*ur+epsilon,Gn+.166*ur+epsilon],[bi-.115*ur-epsilon,Gn+.234*ur-epsilon]]).stream(Je),Zt()},Nt.fitExtent=function(nr,ur){return fitExtent(Nt,nr,ur)},Nt.fitSize=function(nr,ur){return fitSize(Nt,nr,ur)};function Zt(){return I=k=null,Nt}return Nt.scale(1070)}function Er(I){return function(k,Y){var he=F(k),be=F(Y),Le=I(he*be);return[Le*be*Ot(k),Le*Ot(Y)]}}function wg(I){return function(k,Y){var he=mr(k*k+Y*Y),be=I(he),Le=Ot(be),Be=F(be);return[P(k*Le,he*Be),ui(he&&Y*Le/he)]}}var ky=Er(function(I){return mr(2/(1+I))});ky.invert=wg(function(I){return 2*ui(I/2)});function _A(){return projection(ky).scale(124.75).clipAngle(180-.001)}var m1=Er(function(I){return(I=Jn(I))&&I/Ot(I)});m1.invert=wg(function(I){return I});function Eg(){return projection(m1).scale(79.4188).clipAngle(180-.001)}function ty(I,k){return[I,Ie(pn((_o+k)/2))]}ty.invert=function(I,k){return[I,2*D(fe(k))-_o]};function g_(){return v1(ty).scale(961/tau)}function v1(I){var k=projection(I),Y=k.center,he=k.scale,be=k.translate,Le=k.clipExtent,Be=null,yt,Et,Je;k.scale=function(Zt){return arguments.length?(he(Zt),Nt()):he()},k.translate=function(Zt){return arguments.length?(be(Zt),Nt()):be()},k.center=function(Zt){return arguments.length?(Y(Zt),Nt()):Y()},k.clipExtent=function(Zt){return arguments.length?(Zt==null?Be=yt=Et=Je=null:(Be=+Zt[0][0],yt=+Zt[0][1],Et=+Zt[1][0],Je=+Zt[1][1]),Nt()):Be==null?null:[[Be,yt],[Et,Je]]};function Nt(){var Zt=pi*he(),nr=k(rotation(k.rotate()).invert([0,0]));return Le(Be==null?[[nr[0]-Zt,nr[1]-Zt],[nr[0]+Zt,nr[1]+Zt]]:I===ty?[[Math.max(nr[0]-Zt,Be),yt],[Math.min(nr[0]+Zt,Et),Je]]:[[Be,Math.max(nr[1]-Zt,yt)],[Et,Math.min(nr[1]+Zt,Je)]])}return Nt()}function Qv(I){return tan((halfPi+I)/2)}function g1(I,k){var Y=cos(I),he=I===k?sin(I):log(Y/cos(k))/log(Qv(k)/Qv(I)),be=Y*pow(Qv(I),he)/he;if(!he)return mercatorRaw;function Le(Be,yt){be>0?yt<-halfPi+epsilon&&(yt=-halfPi+epsilon):yt>halfPi-epsilon&&(yt=halfPi-epsilon);var Et=be/pow(Qv(yt),he);return[Et*sin(he*Be),be-Et*cos(he*Be)]}return Le.invert=function(Be,yt){var Et=be-yt,Je=sign(he)*sqrt(Be*Be+Et*Et);return[atan2(Be,abs(Et))/he*sign(Et),2*atan(pow(be/Je,1/he))-halfPi]},Le}function AA(){return conicProjection(g1).scale(109.5).parallels([30,30])}function Fy(I,k){return[I,k]}Fy.invert=Fy;function y1(){return projection(Fy).scale(152.63)}function ry(I,k){var Y=cos(I),he=I===k?sin(I):(Y-cos(k))/(k-I),be=Y/he+I;if(abs(he)Rr&&--he>0);return[I/(.8707+(Le=Y*Y)*(-.131979+Le*(-.013791+Le*Le*Le*(.003971-.001529*Le)))),Y]};function ny(){return projection(Cg).scale(175.295)}function Fm(I,k){return[F(k)*Ot(I),Ot(k)]}Fm.invert=wg(ui);function Ny(){return projection(Fm).scale(249.5).clipAngle(90+epsilon)}function Tg(I,k){var Y=F(k),he=1+F(I)*Y;return[Y*Ot(I)/he,Ot(k)/he]}Tg.invert=wg(function(I){return 2*D(I)});function Mv(){return projection(Tg).scale(250).clipAngle(142)}function b1(I,k){return[Ie(pn((_o+k)/2)),-I]}b1.invert=function(I,k){return[-k,2*D(fe(I))-_o]};function bA(){var I=mercatorProjection(b1),k=I.center,Y=I.rotate;return I.center=function(he){return arguments.length?k([-he[1],he[0]]):(he=k(),[he[1],-he[0]])},I.rotate=function(he){return arguments.length?Y([he[0],he[1],he.length>2?he[2]+90:90]):(he=Y(),[he[0],he[1],he[2]-90])},Y([0,0,90]).scale(159.155)}function xA(I,k,Y){Y=Y||{};var he=Y.units||"kilometers",be=Y.steps||8;if(!I)throw new Error("geojson is required");if(typeof Y!="object")throw new Error("options must be an object");if(typeof be!="number")throw new Error("steps must be an number");if(k===void 0)throw new Error("radius is required");if(be<=0)throw new Error("steps must be greater than 0");var Le=[];switch(I.type){case"GeometryCollection":return geomEach(I,function(Be){var yt=Mg(Be,k,he,be);yt&&Le.push(yt)}),featureCollection(Le);case"FeatureCollection":return featureEach(I,function(Be){var yt=Mg(Be,k,he,be);yt&&featureEach(yt,function(Et){Et&&Le.push(Et)})}),featureCollection(Le)}return Mg(I,k,he,be)}function Mg(I,k,Y,he){var be=I.properties||{},Le=I.type==="Feature"?I.geometry:I;if(Le.type==="GeometryCollection"){var Be=[];return geomEach(I,function(Gn){var mo=Mg(Gn,k,Y,he);mo&&Be.push(mo)}),featureCollection(Be)}var yt=y_(Le),Et={type:Le.type,coordinates:eg(Le.coordinates,yt)},Je=new GeoJSONReader,Nt=Je.read(Et),Zt=radiansToLength(lengthToRadians(k,Y),"meters"),nr=BufferOp.bufferOp(Nt,Zt,he),ur=new GeoJSONWriter;if(nr=ur.write(nr),!zy(nr.coordinates)){var bi={type:nr.type,coordinates:x1(nr.coordinates,yt)};return feature(bi,be)}}function zy(I){return Array.isArray(I[0])?zy(I[0]):isNaN(I[0])}function eg(I,k){return typeof I[0]!="object"?k(I):I.map(function(Y){return eg(Y,k)})}function x1(I,k){return typeof I[0]!="object"?k.invert(I):I.map(function(Y){return x1(Y,k)})}function y_(I){var k=center(I).geometry.coordinates,Y=[-k[0],-k[1]];return geoAzimuthalEquidistant().rotate(Y).scale(earthRadius)}var wA=null,iy=A(35486);function EA(I,k,Y){Y===void 0&&(Y={});var he=getGeom(I),be=getGeom(k),Le=polygonClipping.intersection(he.coordinates,be.coordinates);return Le.length===0?null:Le.length===1?polygon(Le[0],Y.properties):multiPolygon(Le,Y.properties)}function __(I,k){if(k=k||{},!isObject(k))throw new Error("options is invalid");var Y=k.propertyName;collectionOf(I,"Polygon","dissolve");var he=[];if(k.propertyName){var be={};featureEach(I,function(Et){Object.prototype.hasOwnProperty.call(be,Et.properties[Y])||(be[Et.properties[Y]]=[]),be[Et.properties[Y]].push(Et)});for(var Le=Object.keys(be),Be=0;Bemo/2;ph&&(Ui-=mo/4);for(var Zl=[],Bh=[],Wh=0;Wh<6;Wh++){var Fl=2*Math.PI/6*Wh;Zl.push(Math.cos(Fl)),Bh.push(Math.sin(Fl))}for(var Uf=[],wf=0;wf<=ia;wf++)for(var lp=0;lp<=ka;lp++){var tp=wf%2===1;if(!(lp===0&&tp)&&!(lp===0&&ph)){var cd=wf*fi+be-Jo,Mm=lp*Ro+Le+Ui;if(tp&&(Mm-=mo/2),Y.triangles===!0)rg([cd,Mm],Zt/2,ur/2,JSON.parse(he),Zl,Bh).forEach(function(vm){Y.mask?intersect(Y.mask,vm)&&Uf.push(vm):Uf.push(vm)});else{var tm=_v([cd,Mm],Zt/2,ur/2,JSON.parse(he),Zl,Bh);Y.mask?intersect(Y.mask,tm)&&Uf.push(tm):Uf.push(tm)}}}return featureCollection(Uf)}function _v(I,k,Y,he,be,Le){for(var Be=[],yt=0;yt<6;yt++){var Et=I[0]+k*be[yt],Je=I[1]+Y*Le[yt];Be.push([Et,Je])}return Be.push(Be[0].slice()),polygon([Be],he)}function rg(I,k,Y,he,be,Le){for(var Be=[],yt=0;yt<6;yt++){var Et=[];Et.push(I),Et.push([I[0]+k*be[yt],I[1]+Y*Le[yt]]),Et.push([I[0]+k*be[(yt+1)%6],I[1]+Y*Le[(yt+1)%6]]),Et.push(I),Be.push(polygon([Et],he))}return Be}var oy=null;function Av(I,k){var Y=Pg(k),he=null;return I.type==="FeatureCollection"?he=Zy(I):he=ay(polygonClipping.union(I.geometry.coordinates)),he.geometry.coordinates.forEach(function(be){Y.geometry.coordinates.push(be[0])}),Y}function Zy(I){var k=I.features.length===2?polygonClipping.union(I.features[0].geometry.coordinates,I.features[1].geometry.coordinates):polygonClipping.union.apply(polygonClipping,I.features.map(function(Y){return Y.geometry.coordinates}));return ay(k)}function ay(I){return multiPolygon(I)}function Pg(I){var k=[[[180,90],[-180,90],[-180,-90],[180,-90],[180,90]]],Y=I&&I.geometry.coordinates||k;return polygon(Y)}var w1=null;function sy(I,k,Y,he){he===void 0&&(he={});for(var be=[],Le=I[0],Be=I[1],yt=I[2],Et=I[3],Je=k/distance([Le,Be],[yt,Be],he),Nt=Je*(yt-Le),Zt=Y/distance([Le,Be],[Le,Et],he),nr=Zt*(Et-Be),ur=yt-Le,bi=Et-Be,Gn=Math.floor(ur/Nt),mo=Math.floor(bi/nr),xi=(ur-Gn*Nt)/2,Bn=(bi-mo*nr)/2,fi=Le+xi,Ro=0;Ro-1}var Ee=we;function qe(ut,Xe){var Rt=this.__data__,gt=$(Rt,ut);return gt<0?(++this.size,Rt.push([ut,Xe])):Rt[gt][1]=Xe,this}var Ge=qe;function ct(ut){var Xe=-1,Rt=ut==null?0:ut.length;for(this.clear();++XeIi))return!1;var Fn=Mo.get(li),zn=Mo.get(En);if(Fn&&zn)return Fn==En&&zn==li;var Un=-1,Hi=!0,Ki=or&se?new V.Z:void 0;for(Mo.set(li,En),Mo.set(En,li);++Un-1&&y%1==0&&y0){if(++Ge>=se)return arguments[0]}else Ge=0;return qe.apply(void 0,arguments)}}var De=le,we=De(X),Ee=we},87625:function(Ye,ye,A){"use strict";var R=A(84079),V=1/0;function y(p){if(typeof p=="string"||(0,R.Z)(p))return p;var $=p+"";return $=="0"&&1/p==-V?"-0":$}ye.Z=y},22279:function(Ye,ye){"use strict";var A=Function.prototype,R=A.toString;function V(y){if(y!=null){try{return R.call(y)}catch(p){}try{return y+""}catch(p){}}return""}ye.Z=V},91284:function(Ye,ye){"use strict";function A(R,V){return R===V||R!==R&&V!==V}ye.Z=A},93091:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return De}});var R=A(42623),V=A(39586),y=A(18519),p=A(3315),$=V.Z?V.Z.isConcatSpreadable:void 0;function X(we){return(0,p.Z)(we)||(0,y.Z)(we)||!!($&&we&&we[$])}var se=X;function ae(we,Ee,qe,Ge,ct){var Ve=-1,ut=we.length;for(qe||(qe=se),ct||(ct=[]);++Ve0&&qe(Xe)?Ee>1?ae(Xe,Ee-1,qe,Ge,ct):(0,R.Z)(ct,Xe):Ge||(ct[ct.length]=Xe)}return ct}var ce=ae;function le(we){var Ee=we==null?0:we.length;return Ee?ce(we,1):[]}var De=le},1469:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return we}});function R(Ee,qe){return Ee!=null&&qe in Object(Ee)}var V=R,y=A(54041),p=A(18519),$=A(3315),X=A(1773),se=A(66523),ae=A(87625);function ce(Ee,qe,Ge){qe=(0,y.Z)(qe,Ee);for(var ct=-1,Ve=qe.length,ut=!1;++ct-1&&V%1==0&&V<=A}ye.Z=R},9935:function(Ye,ye){"use strict";function A(R){var V=typeof R;return R!=null&&(V=="object"||V=="function")}ye.Z=A},21314:function(Ye,ye){"use strict";function A(R){return R!=null&&typeof R=="object"}ye.Z=A},77844:function(Ye,ye,A){"use strict";var R=A(59657),V=A(38794),y=A(21314),p="[object Object]",$=Function.prototype,X=Object.prototype,se=$.toString,ae=X.hasOwnProperty,ce=se.call(Object);function le(De){if(!(0,y.Z)(De)||(0,R.Z)(De)!=p)return!1;var we=(0,V.Z)(De);if(we===null)return!0;var Ee=ae.call(we,"constructor")&&we.constructor;return typeof Ee=="function"&&Ee instanceof Ee&&se.call(Ee)==ce}ye.Z=le},84079:function(Ye,ye,A){"use strict";var R=A(59657),V=A(21314),y="[object Symbol]";function p($){return typeof $=="symbol"||(0,V.Z)($)&&(0,R.Z)($)==y}ye.Z=p},58166:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return We}});var R=A(59657),V=A(66523),y=A(21314),p="[object Arguments]",$="[object Array]",X="[object Boolean]",se="[object Date]",ae="[object Error]",ce="[object Function]",le="[object Map]",De="[object Number]",we="[object Object]",Ee="[object RegExp]",qe="[object Set]",Ge="[object String]",ct="[object WeakMap]",Ve="[object ArrayBuffer]",ut="[object DataView]",Xe="[object Float32Array]",Rt="[object Float64Array]",gt="[object Int8Array]",Ct="[object Int16Array]",tt="[object Int32Array]",Ne="[object Uint8Array]",bt="[object Uint8ClampedArray]",et="[object Uint16Array]",pt="[object Uint32Array]",Ke={};Ke[Xe]=Ke[Rt]=Ke[gt]=Ke[Ct]=Ke[tt]=Ke[Ne]=Ke[bt]=Ke[et]=Ke[pt]=!0,Ke[p]=Ke[$]=Ke[Ve]=Ke[X]=Ke[ut]=Ke[se]=Ke[ae]=Ke[ce]=Ke[le]=Ke[De]=Ke[we]=Ke[Ee]=Ke[qe]=Ke[Ge]=Ke[ct]=!1;function ft(Me){return(0,y.Z)(Me)&&(0,V.Z)(Me.length)&&!!Ke[(0,R.Z)(Me)]}var wt=ft,Se=A(66729),Ft=A(16029),mt=Ft.Z&&Ft.Z.isTypedArray,ot=mt?(0,Se.Z)(mt):wt,We=ot},63364:function(Ye,ye){"use strict";function A(R){return R===void 0}ye.Z=A},59744:function(Ye,ye,A){"use strict";var R=A(99082),V=A(50130),y=A(83047);function p($){return(0,y.Z)($)?(0,R.Z)($):(0,V.Z)($)}ye.Z=p},84975:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return we}});var R=A(99082),V=A(9935),y=A(33866);function p(Ee){var qe=[];if(Ee!=null)for(var Ge in Object(Ee))qe.push(Ge);return qe}var $=p,X=Object.prototype,se=X.hasOwnProperty;function ae(Ee){if(!(0,V.Z)(Ee))return $(Ee);var qe=(0,y.Z)(Ee),Ge=[];for(var ct in Ee)ct=="constructor"&&(qe||!se.call(Ee,ct))||Ge.push(ct);return Ge}var ce=ae,le=A(83047);function De(Ee){return(0,le.Z)(Ee)?(0,R.Z)(Ee,!0):ce(Ee)}var we=De},52853:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return Ne}});var R=A(68603),V=A(52600),y=A(54041);function p(bt){var et=bt==null?0:bt.length;return et?bt[et-1]:void 0}var $=p,X=A(73872);function se(bt,et,pt){var Ke=-1,ft=bt.length;et<0&&(et=-et>ft?0:ft+et),pt=pt>ft?ft:pt,pt<0&&(pt+=ft),ft=et>pt?0:pt-et>>>0,et>>>=0;for(var wt=Array(ft);++Ke1),wt}),(0,qe.Z)(bt,(0,Xe.Z)(bt),pt),Ke&&(pt=(0,V.Z)(pt,Rt|gt|Ct,Ve));for(var ft=et.length;ft--;)Ee(pt,et[ft]);return pt}),Ne=tt},66018:function(Ye,ye){"use strict";function A(){return[]}ye.Z=A},16926:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return De}});var R=A(39586),V=A(68603),y=A(3315),p=A(84079),$=1/0,X=R.Z?R.Z.prototype:void 0,se=X?X.toString:void 0;function ae(we){if(typeof we=="string")return we;if((0,y.Z)(we))return(0,V.Z)(we,ae)+"";if((0,p.Z)(we))return se?se.call(we):"";var Ee=we+"";return Ee=="0"&&1/we==-$?"-0":Ee}var ce=ae;function le(we){return we==null?"":ce(we)}var De=le},79382:function(Ye,ye,A){"use strict";A.d(ye,{Z:function(){return pt}});var R=A(66908),V=A(66438);function y(Ke,ft,wt,Se){for(var Ft=Ke.length,mt=wt+(Se?1:-1);Se?mt--:++mt-1}var we=De;function Ee(Ke,ft,wt){for(var Se=-1,Ft=Ke==null?0:Ke.length;++Se=tt){var st=ft?null:Ct(Ke);if(st)return(0,Xe.Z)(st);ot=!1,Ft=Ge.Z,Me=new V.Z}else Me=ft?[]:We;e:for(;++Se=0;ln--)(hn=Me[ln])&&(Yr=(Kt<3?hn(Yr):Kt>3?hn(st,Qe,Yr):hn(st,Qe))||Yr);return Kt>3&&Yr&&Object.defineProperty(st,Qe,Yr),Yr}function X(Me,st){return function(Qe,dr){st(Qe,dr,Me)}}function se(Me,st,Qe,dr,Kt,Yr){function hn(sn){if(sn!==void 0&&typeof sn!="function")throw new TypeError("Function expected");return sn}for(var ln=dr.kind,oi=ln==="getter"?"get":ln==="setter"?"set":"value",Nn=!st&&Me?dr.static?Me:Me.prototype:null,$n=st||(Nn?Object.getOwnPropertyDescriptor(Nn,dr.name):{}),_i,Qn=!1,Ji=Qe.length-1;Ji>=0;Ji--){var ni={};for(var Ei in dr)ni[Ei]=Ei==="access"?{}:dr[Ei];for(var Ei in dr.access)ni.access[Ei]=dr.access[Ei];ni.addInitializer=function(sn){if(Qn)throw new TypeError("Cannot add initializers after decoration has completed");Yr.push(hn(sn||null))};var xo=(0,Qe[Ji])(ln==="accessor"?{get:$n.get,set:$n.set}:$n[oi],ni);if(ln==="accessor"){if(xo===void 0)continue;if(xo===null||typeof xo!="object")throw new TypeError("Object expected");(_i=hn(xo.get))&&($n.get=_i),(_i=hn(xo.set))&&($n.set=_i),(_i=hn(xo.init))&&Kt.unshift(_i)}else(_i=hn(xo))&&(ln==="field"?Kt.unshift(_i):$n[oi]=_i)}Nn&&Object.defineProperty(Nn,dr.name,$n),Qn=!0}function ae(Me,st,Qe){for(var dr=arguments.length>2,Kt=0;Kt0&&Yr[Yr.length-1])&&(Nn[0]===6||Nn[0]===2)){Qe=0;continue}if(Nn[0]===3&&(!Yr||Nn[1]>Yr[0]&&Nn[1]=Me.length&&(Me=void 0),{value:Me&&Me[dr++],done:!Me}}};throw new TypeError(st?"Object is not iterable.":"Symbol.iterator is not defined.")}function Ve(Me,st){var Qe=typeof Symbol=="function"&&Me[Symbol.iterator];if(!Qe)return Me;var dr=Qe.call(Me),Kt,Yr=[],hn;try{for(;(st===void 0||st-- >0)&&!(Kt=dr.next()).done;)Yr.push(Kt.value)}catch(ln){hn={error:ln}}finally{try{Kt&&!Kt.done&&(Qe=dr.return)&&Qe.call(dr)}finally{if(hn)throw hn.error}}return Yr}function ut(){for(var Me=[],st=0;st1||ln(Qn,Ji)})})}function ln(Qn,Ji){try{oi(dr[Qn](Ji))}catch(ni){_i(Yr[0][3],ni)}}function oi(Qn){Qn.value instanceof gt?Promise.resolve(Qn.value.v).then(Nn,$n):_i(Yr[0][2],Qn)}function Nn(Qn){ln("next",Qn)}function $n(Qn){ln("throw",Qn)}function _i(Qn,Ji){Qn(Ji),Yr.shift(),Yr.length&&ln(Yr[0][0],Yr[0][1])}}function tt(Me){var st,Qe;return st={},dr("next"),dr("throw",function(Kt){throw Kt}),dr("return"),st[Symbol.iterator]=function(){return this},st;function dr(Kt,Yr){st[Kt]=Me[Kt]?function(hn){return(Qe=!Qe)?{value:gt(Me[Kt](hn)),done:!1}:Yr?Yr(hn):hn}:Yr}}function Ne(Me){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var st=Me[Symbol.asyncIterator],Qe;return st?st.call(Me):(Me=typeof ct=="function"?ct(Me):Me[Symbol.iterator](),Qe={},dr("next"),dr("throw"),dr("return"),Qe[Symbol.asyncIterator]=function(){return this},Qe);function dr(Yr){Qe[Yr]=Me[Yr]&&function(hn){return new Promise(function(ln,oi){hn=Me[Yr](hn),Kt(ln,oi,hn.done,hn.value)})}}function Kt(Yr,hn,ln,oi){Promise.resolve(oi).then(function(Nn){Yr({value:Nn,done:ln})},hn)}}function bt(Me,st){return Object.defineProperty?Object.defineProperty(Me,"raw",{value:st}):Me.raw=st,Me}var et=Object.create?function(Me,st){Object.defineProperty(Me,"default",{enumerable:!0,value:st})}:function(Me,st){Me.default=st};function pt(Me){if(Me&&Me.__esModule)return Me;var st={};if(Me!=null)for(var Qe in Me)Qe!=="default"&&Object.prototype.hasOwnProperty.call(Me,Qe)&&qe(st,Me,Qe);return et(st,Me),st}function Ke(Me){return Me&&Me.__esModule?Me:{default:Me}}function ft(Me,st,Qe,dr){if(Qe==="a"&&!dr)throw new TypeError("Private accessor was defined without a getter");if(typeof st=="function"?Me!==st||!dr:!st.has(Me))throw new TypeError("Cannot read private member from an object whose class did not declare it");return Qe==="m"?dr:Qe==="a"?dr.call(Me):dr?dr.value:st.get(Me)}function wt(Me,st,Qe,dr,Kt){if(dr==="m")throw new TypeError("Private method is not writable");if(dr==="a"&&!Kt)throw new TypeError("Private accessor was defined without a setter");if(typeof st=="function"?Me!==st||!Kt:!st.has(Me))throw new TypeError("Cannot write private member to an object whose class did not declare it");return dr==="a"?Kt.call(Me,Qe):Kt?Kt.value=Qe:st.set(Me,Qe),Qe}function Se(Me,st){if(st===null||typeof st!="object"&&typeof st!="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof Me=="function"?st===Me:Me.has(st)}function Ft(Me,st,Qe){if(st!=null){if(typeof st!="object"&&typeof st!="function")throw new TypeError("Object expected.");var dr;if(Qe){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");dr=st[Symbol.asyncDispose]}if(dr===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");dr=st[Symbol.dispose]}if(typeof dr!="function")throw new TypeError("Object not disposable.");Me.stack.push({value:st,dispose:dr,async:Qe})}else Qe&&Me.stack.push({async:!0});return st}var mt=typeof SuppressedError=="function"?SuppressedError:function(Me,st,Qe){var dr=new Error(Qe);return dr.name="SuppressedError",dr.error=Me,dr.suppressed=st,dr};function ot(Me){function st(dr){Me.error=Me.hasError?new mt(dr,Me.error,"An error was suppressed during disposal."):dr,Me.hasError=!0}function Qe(){for(;Me.stack.length;){var dr=Me.stack.pop();try{var Kt=dr.dispose&&dr.dispose.call(dr.value);if(dr.async)return Promise.resolve(Kt).then(Qe,function(Yr){return st(Yr),Qe()})}catch(Yr){st(Yr)}}if(Me.hasError)throw Me.error}return Qe()}var We={__extends:V,__assign:y,__rest:p,__decorate:$,__param:X,__metadata:De,__awaiter:we,__generator:Ee,__createBinding:qe,__exportStar:Ge,__values:ct,__read:Ve,__spread:ut,__spreadArrays:Xe,__spreadArray:Rt,__await:gt,__asyncGenerator:Ct,__asyncDelegator:tt,__asyncValues:Ne,__makeTemplateObject:bt,__importStar:pt,__importDefault:Ke,__classPrivateFieldGet:ft,__classPrivateFieldSet:wt,__classPrivateFieldIn:Se,__addDisposableResource:Ft,__disposeResources:ot}}}]); diff --git a/packages/site/public/weather/index.html b/packages/site/public/weather/index.html new file mode 100644 index 0000000000..20b6d4aad0 --- /dev/null +++ b/packages/site/public/weather/index.html @@ -0,0 +1,19 @@ + + + + + +春运路线天气地图 + + + +
+ + + \ No newline at end of file diff --git a/packages/site/public/weather/layouts__index.393ff4f4.chunk.css b/packages/site/public/weather/layouts__index.393ff4f4.chunk.css new file mode 100644 index 0000000000..18237ee419 --- /dev/null +++ b/packages/site/public/weather/layouts__index.393ff4f4.chunk.css @@ -0,0 +1 @@ +html,body,.layout___Ps7xZ{margin:0;padding:0} diff --git a/packages/site/public/weather/layouts__index.94e5c9cc.async.js b/packages/site/public/weather/layouts__index.94e5c9cc.async.js new file mode 100644 index 0000000000..287e2192f0 --- /dev/null +++ b/packages/site/public/weather/layouts__index.94e5c9cc.async.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[717],{54309:function(l,t,n){n.r(t),n.d(t,{default:function(){return i}});var f=n(49504),d={layout:"layout___Ps7xZ"},o=n(32648);function i(){return(0,o.jsx)("div",{className:d.layout,children:(0,o.jsx)(f.j3,{})})}},5759:function(l,t,n){var f=n(77617),d=Symbol.for("react.element"),o=Symbol.for("react.fragment"),i=Object.prototype.hasOwnProperty,p=f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,m={key:!0,ref:!0,__self:!0,__source:!0};function a(u,e,c){var r,s={},y=null,_=null;c!==void 0&&(y=""+c),e.key!==void 0&&(y=""+e.key),e.ref!==void 0&&(_=e.ref);for(r in e)i.call(e,r)&&!m.hasOwnProperty(r)&&(s[r]=e[r]);if(u&&u.defaultProps)for(r in e=u.defaultProps,e)s[r]===void 0&&(s[r]=e[r]);return{$$typeof:d,type:u,key:y,ref:_,props:s,_owner:p.current}}t.Fragment=o,t.jsx=a,t.jsxs=a},32648:function(l,t,n){l.exports=n(5759)}}]); diff --git a/packages/site/public/weather/p__index.0bf7347e.async.js b/packages/site/public/weather/p__index.0bf7347e.async.js new file mode 100644 index 0000000000..fcdb260065 --- /dev/null +++ b/packages/site/public/weather/p__index.0bf7347e.async.js @@ -0,0 +1,92 @@ +"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[866],{64591:function(xa,et,a){a.r(et),a.d(et,{default:function(){return ga}});var Dt={version:"v0.1",metadata:{name:"\u9ED8\u8BA4\u914D\u7F6E\u5E94\u7528",creatTime:"2023-12-11 15:40:56"},datasets:[],spec:{map:{basemap:"Gaode",config:{zoom:5,center:[112.46641,40.91574],pitch:0,bearing:0,rotation:0,style:"normal",token:"f0230f884bbd54e2913c890cdf45aa7e",viewMode:"2D",dragRotate:!0,pitchWithRotate:!0,WebGLParams:{preserveDrawingBuffer:!0}}},layers:[],widgets:[{id:"BaseLayout_c0ca0c86-01ea-4476-988e-d3ba43d67ba0",type:"BaseLayout",metadata:{name:"\u57FA\u7840\u5E03\u5C40"},properties:{showSidePanel:!1}},{id:"ZoomControl_4b3f291a-cd06-4179-9c3a-deb5dfaa9637",type:"ZoomControl",metadata:{name:"\u7F29\u653E\u5668"},properties:{position:"bottomright",showZoom:!0},container:{id:"BaseLayout_c0ca0c86-01ea-4476-988e-d3ba43d67ba0",slot:"controls"}},{id:"ChoosePlace_afc9fe1a-36eb-4cef-9058-87bfa211dfad",type:"ChoosePlace",metadata:{name:"\u4E24\u5730\u70B9\u9009\u62E9"},properties:{position:"topleft"},container:{id:"BaseLayout_c0ca0c86-01ea-4476-988e-d3ba43d67ba0",slot:"controls"}}]}},kt=Dt,Qt=a(82242),b=a.n(Qt),nt=a(5022),it={algorithm:nt.Z.darkAlgorithm,token:{colorTextBase:"rgba(255,255,255,0.85)",colorBgBase:"#0f0f13",borderRadius:6}},St=b()(b()({},it),{},{token:b()(b()({},it.token),{},{colorBgBase:"#1d1e25"})}),zt=a(36686),At=a(71720),wt=a(34591),Tt=a(36632),ja=a(46789),Pt=a(7557),N=a.n(Pt),Ct=a(41498),B=a.n(Ct),Lt=a(79800),R=a.n(Lt),Da=a(85573),Rt=a(39647),q=a.n(Rt),Ot=a(37205),I=a.n(Ot),Et=a(9498),_=a.n(Et),Zt=a(79382),Nt=a(2505),Mt=["\u672A\u77E5","\u7F13\u884C","\u62E5\u5835","\u4E25\u91CD\u62E5\u5835"],V=_()(new Date().toLocaleDateString()).format("YYYY-MM-DD"),ka="98d10f05a2da96697313a2ce35ebf1a2",Qa="https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*7EZSSYpUeWwAAAAAAAAAAAAADpatAQ/original",rt="https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*lXMHRblTVFQAAAAAAAAAAAAADpatAQ/original",ot="https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*yeZ9R7WShEEAAAAAAAAAAAAADpatAQ/original",Ft={\u6674:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*hWmEQLDwGJkAAAAAAAAAAAAADpatAQ/original",\u5C11\u4E91:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*G_fUSY6oaw8AAAAAAAAAAAAADpatAQ/original",\u6674\u95F4\u591A\u4E91:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*nkHNTJ5h_ykAAAAAAAAAAAAADpatAQ/original",\u591A\u4E91:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*SB96R7Br7gEAAAAAAAAAAAAADpatAQ/original",\u9634:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*G_fUSY6oaw8AAAAAAAAAAAAADpatAQ/original",\u6709\u98CE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*l-QpTLXOV1UAAAAAAAAAAAAADpatAQ/original",\u5E73\u9759:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*l-QpTLXOV1UAAAAAAAAAAAAADpatAQ/original",\u5FAE\u98CE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*l-QpTLXOV1UAAAAAAAAAAAAADpatAQ/original",\u548C\u98CE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*l-QpTLXOV1UAAAAAAAAAAAAADpatAQ/original",\u6E05\u98CE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*l-QpTLXOV1UAAAAAAAAAAAAADpatAQ/original","\u5F3A\u98CE/\u52B2\u98CE":"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*l-QpTLXOV1UAAAAAAAAAAAAADpatAQ/original",\u75BE\u98CE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*l-QpTLXOV1UAAAAAAAAAAAAADpatAQ/original",\u5927\u98CE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*l-QpTLXOV1UAAAAAAAAAAAAADpatAQ/original",\u70C8\u98CE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*l-QpTLXOV1UAAAAAAAAAAAAADpatAQ/original",\u98CE\u66B4:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*l-QpTLXOV1UAAAAAAAAAAAAADpatAQ/original",\u72C2\u7206\u98CE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*l-QpTLXOV1UAAAAAAAAAAAAADpatAQ/original",\u98D3\u98CE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*l-QpTLXOV1UAAAAAAAAAAAAADpatAQ/original",\u70ED\u5E26\u98CE\u66B4:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*l-QpTLXOV1UAAAAAAAAAAAAADpatAQ/original",\u973E:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*-VVyTILygJkAAAAAAAAAAAAADpatAQ/original",\u4E2D\u5EA6\u973E:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*NdCQQJH9_m8AAAAAAAAAAAAADpatAQ/original",\u91CD\u5EA6\u973E:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*PqDLQrtkRfMAAAAAAAAAAAAADpatAQ/original",\u4E25\u91CD\u973E:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*PqDLQrtkRfMAAAAAAAAAAAAADpatAQ/original",\u9635\u96E8:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*yHmiR6A9twQAAAAAAAAAAAAADpatAQ/original",\u96F7\u9635\u96E8:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*3ReZSLkqr_kAAAAAAAAAAAAADpatAQ/original",\u96F7\u9635\u96E8\u5E76\u4F34\u6709\u51B0\u96F9:"",\u5C0F\u96E8:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*yHmiR6A9twQAAAAAAAAAAAAADpatAQ/original",\u4E2D\u96E8:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*yHmiR6A9twQAAAAAAAAAAAAADpatAQ/original",\u5927\u96E8:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*yHmiR6A9twQAAAAAAAAAAAAADpatAQ/original",\u66B4\u96E8:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*D_U5TK-m4X8AAAAAAAAAAAAADpatAQ/original",\u5927\u66B4\u96E8:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*D_U5TK-m4X8AAAAAAAAAAAAADpatAQ/original",\u7279\u5927\u66B4\u96E8:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*D_U5TK-m4X8AAAAAAAAAAAAADpatAQ/original",\u5F3A\u9635\u96E8:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*yHmiR6A9twQAAAAAAAAAAAAADpatAQ/original",\u5F3A\u96F7\u9635\u96E8:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*3ReZSLkqr_kAAAAAAAAAAAAADpatAQ/original",\u6781\u7AEF\u964D\u96E8:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*3qWESpEucFMAAAAAAAAAAAAADpatAQ/original","\u6BDB\u6BDB\u96E8/\u7EC6\u96E8":"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*yHmiR6A9twQAAAAAAAAAAAAADpatAQ/original",\u96E8:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*yHmiR6A9twQAAAAAAAAAAAAADpatAQ/original","\u5C0F\u96E8-\u4E2D\u96E8":"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*yHmiR6A9twQAAAAAAAAAAAAADpatAQ/original","\u4E2D\u96E8-\u5927\u96E8":"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*yHmiR6A9twQAAAAAAAAAAAAADpatAQ/original","\u5927\u96E8-\u66B4\u96E8":"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*yHmiR6A9twQAAAAAAAAAAAAADpatAQ/original","\u66B4\u96E8-\u5927\u66B4\u96E8":"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*3qWESpEucFMAAAAAAAAAAAAADpatAQ/original","\u5927\u66B4\u96E8-\u7279\u5927\u66B4\u96E8":"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*3qWESpEucFMAAAAAAAAAAAAADpatAQ/original",\u96E8\u96EA\u5929\u6C14:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*zJU-SYgmOCkAAAAAAAAAAAAADpatAQ/original",\u96E8\u5939\u96EA:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*zJU-SYgmOCkAAAAAAAAAAAAADpatAQ/original",\u9635\u96E8\u5939\u96EA:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*zJU-SYgmOCkAAAAAAAAAAAAADpatAQ/original",\u51BB\u96E8:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*tPitRI60EEwAAAAAAAAAAAAADpatAQ/original",\u96EA:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*6usDRK5hwosAAAAAAAAAAAAADpatAQ/original",\u9635\u96EA:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*6usDRK5hwosAAAAAAAAAAAAADpatAQ/original",\u5C0F\u96EA:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*6usDRK5hwosAAAAAAAAAAAAADpatAQ/original",\u4E2D\u96EA:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*ra5GRp3U688AAAAAAAAAAAAADpatAQ/original",\u5927\u96EA:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*ra5GRp3U688AAAAAAAAAAAAADpatAQ/original",\u66B4\u96EA:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*ra5GRp3U688AAAAAAAAAAAAADpatAQ/original","\u5C0F\u96EA-\u4E2D\u96EA":"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*ra5GRp3U688AAAAAAAAAAAAADpatAQ/original","\u4E2D\u96EA-\u5927\u96EA":"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*ra5GRp3U688AAAAAAAAAAAAADpatAQ/original","\u5927\u96EA-\u66B4\u96EA":"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*ra5GRp3U688AAAAAAAAAAAAADpatAQ/original",\u6D6E\u5C18:"",\u626C\u6C99:"",\u6C99\u5C18\u66B4:"",\u5F3A\u6C99\u5C18\u66B4:"",\u9F99\u5377\u98CE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*0b3hTq-reJ4AAAAAAAAAAAAADpatAQ/original",\u96FE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*E1YGT70TJDcAAAAAAAAAAAAADpatAQ/original",\u6D53\u96FE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*E1YGT70TJDcAAAAAAAAAAAAADpatAQ/original",\u5F3A\u6D53\u96FE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*E1YGT70TJDcAAAAAAAAAAAAADpatAQ/original",\u8F7B\u96FE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*E1YGT70TJDcAAAAAAAAAAAAADpatAQ/original",\u5927\u96FE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*E1YGT70TJDcAAAAAAAAAAAAADpatAQ/original",\u7279\u5F3A\u6D53\u96FE:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*E1YGT70TJDcAAAAAAAAAAAAADpatAQ/original",\u70ED:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*i6nKTpdxNIQAAAAAAAAAAAAADpatAQ/original",\u51B7:"https://mdn.alipayobjects.com/huamei_5vkpxz/afts/img/A*yAxYQofRH0sAAAAAAAAAAAAADpatAQ/original"},Yt={id:"B0HGCLIRF3",name:"\u8682\u8681A\u7A7A\u95F4(\u4E1C\u95E8)",district:"\u6D59\u6C5F\u7701\u676D\u5DDE\u5E02\u897F\u6E56\u533A",location:"120.104785,30.262946",address:"\u897F\u6EAA\u8DEF569\u53F7\u8682\u8681\u96C6\u56E2A\u7A7A\u95F4",longitude:120.104785,latitude:30.262946},J={start:{},end:{id:"B000A83C36",name:"\u5317\u4EAC\u7AD9",district:"\u5317\u4EAC\u5E02\u4E1C\u57CE\u533A",location:"116.427354,39.902830",address:"\u6BDB\u5BB6\u6E7E\u80E1\u540C\u753213\u53F7",longitude:116.427354,latitude:39.90283}},Ut={autoFit:!0,shape:"line",size:5,zIndex:4,color:{field:"status",value:function(t){var e=t.status;return e==="\u7F13\u884C"?"#FFFF00":e==="\u62E5\u5835"?"#FFA500'":e==="\u4E25\u91CD\u62E5\u5835"?"#FF0000":"#5AC475"}},style:{strokeWidth:.3,stroke:"#2B6246"}},Sa=[{title:"\u6E29\u5EA6",interval:[-35,-20,-10,-5,0,5,10,15,20,40],color:["#b2182b","#d6604d","#f4a582","#fddbc7","#f7f7f7","#d1e5f0","#92c5de","#4393c3","#2166ac"].reverse(),unit:"\u2103"},{title:"\u6E7F\u5EA6",interval:[0,10,20,30,40,50,60,70,80,100],color:["#b35806","#e08214","#fdb863","#fee0b6","#f7f7f7","#d8daeb","#b2abd2","#8073ac"],unit:"%"},{title:"\u7A7A\u6C14\u8D28\u91CF(AQI)",interval:[0,300],color:["#d7191c","#fdae61","#ffffbf","#a6d96a"].reverse(),unit:""}],Gt=["cities","polyline","tmcs"];function tt(x,t){return"".concat(x,"?").concat(Object.entries(t).map(function(e){var m=R()(e,2),c=m[0],g=m[1];return"".concat(c,"=").concat(window.encodeURIComponent(String(g)))}).join("&"))}var W=function(t){var e="b93400c020206bd6865a075036e7f423",m="20a5ed5ecb2756a0361e83e794b4aa0a",c="fdd01f9a9dd6846239b9523d7923339b",g="053b838db2f7b6a871b6ec5dbf62ab62";if(t==="input"){var A=[e,c];return A[Math.floor(Math.random()*A.length)]}if(t==="ip"){var s=[e,c,m];return s[Math.floor(Math.random()*s.length)]}if(t==="weather"||t==="driving"){var i=[e,m,c,g];return i[Math.floor(Math.random()*i.length)]}},Ht=function(){var x=B()(N()().mark(function t(e){var m,c,g,A,s,i,h,k,r,p;return N()().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:if(e){f.next=2;break}return f.abrupt("return");case 2:if(m=e||{paths:[]},c=m.destination,g=m.origin,A=m.paths,s={start:{points:c},end:{points:g},paths:[],districts:[],chargingPileInfo:[]},f.prev=4,i=function(D){return D.split(";").map(function(T){return T.split(",").map(function(Q){return+Q}).filter(function(Q){return!Number.isNaN(Q)})})},h=function(D,T){return{type:"Feature",geometry:{type:"LineString",coordinates:i(D)},properties:T}},k=[],A.forEach(function(l,D){var T=l.distance,Q=l.steps,M="",Y=[],d=[];Q.forEach(function(o){var y=o.cities,j=o.polyline,P=o.tmcs,O=q()(o,Gt);M+=j,Y.push(O);var z=[];y.forEach(function(L,u){var S=i(j),F=u*(S.length/y.length),G=F+S.length/y.length,H=S.slice(F,G),$=R()(H[H.length-1],2),ya=$[0],ba=$[1];z.push(b()(b()({},L),{},{lngLat:{lng:ya,lat:ba}}))});var v=P.filter(function(L){return Mt.includes(L.tmc_status)});d.push.apply(d,I()(v)),k.push.apply(k,z)}),s.paths.push({polyline:h(M,{status:"\u7545\u901A",index:D}),distance:T}),s.tmcs=d.map(function(o){return h(o.tmc_polyline,{status:o.tmc_status,index:D})})}),s.districts=(0,Zt.Z)(k,"adcode"),(0,Nt.Z)(s.districts)){f.next=16;break}return r=s.districts,f.next=14,Promise.all(r.map(function(l){return st(l.adcode,"base")}));case 14:p=f.sent,s.districts=r.map(function(l){var D=p.find(function(T){return T.lives[0].adcode===l.adcode});return b()(b()({},l),{},{weatherInfoFeature:D.lives})});case 16:f.next=20;break;case 18:f.prev=18,f.t0=f.catch(4);case 20:return f.abrupt("return",s);case 21:case"end":return f.stop()}},t,null,[[4,18]])}));return function(e){return x.apply(this,arguments)}}(),Bt=function(t){var e={backgroundColor:"rgb(0, 123, 255, 90%)"};return t&&(t.indexOf("\u6674")>=0?e={backgroundColor:"rgba(255,255,255, .8)",color:"#007cff"}:t.indexOf("\u4E2D\u96E8")>=0?e={backgroundColor:"rgb(234 12 12 / 88%)"}:t.indexOf("\u5927\u96E8")>=0?e={backgroundColor:"rgb(0 0 0 / 77%)"}:t.indexOf("\u96EA")>=0?e={backgroundColor:"rgb(0 0 0 / 77%)"}:t.indexOf("\u96E8")>=0&&(e={backgroundColor:"rgb(255 128 51 / 90%)"})),e},Wt=function(t){for(var e=t.from,m=e===void 0?_()():e,c=t.count,g=[],A=0;A*{line-height:1}.larkmap-select-multiple .larkmap-select-selection-item-remove svg{display:inline-block}.larkmap-select-multiple .larkmap-select-selection-item-remove:before{display:none}.larkmap-select-multiple .larkmap-select-selection-item-remove .larkmap-select-multiple .larkmap-select-selection-item-remove-icon{display:block}.larkmap-select-multiple .larkmap-select-selection-item-remove>.larkmapicon{vertical-align:middle}.larkmap-select-multiple .larkmap-select-selection-item-remove:hover{color:#000000bf}.larkmap-select-multiple .larkmap-select-selection-overflow-item+.larkmap-select-selection-overflow-item .larkmap-select-selection-search{margin-inline-start:0}.larkmap-select-multiple .larkmap-select-selection-search{position:relative;max-width:100%;margin-inline-start:7px}.larkmap-select-multiple .larkmap-select-selection-search-input,.larkmap-select-multiple .larkmap-select-selection-search-mirror{height:24px;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";line-height:24px;transition:all .3s}.larkmap-select-multiple .larkmap-select-selection-search-input{width:100%;min-width:4.1px}.larkmap-select-multiple .larkmap-select-selection-search-mirror{position:absolute;top:0;left:0;z-index:999;white-space:pre;visibility:hidden}.larkmap-select-multiple .larkmap-select-selection-placeholder{position:absolute;top:50%;right:11px;left:11px;transform:translateY(-50%);transition:all .3s}.larkmap-select-disabled .larkmap-select-selection-item-remove{display:none}.larkmap-select{box-sizing:border-box;margin:0;padding:0;color:#000000d9;font-size:14px;font-variant:tabular-nums;line-height:1.5715;list-style:none;font-feature-settings:"tnum","tnum";position:relative;display:inline-block;cursor:pointer}.larkmap-select:not(.larkmap-select-customize-input) .larkmap-select-selector{position:relative;background-color:#fff;border:1px solid #d9d9d9;border-radius:2px;transition:all .3s cubic-bezier(.645,.045,.355,1)}.larkmap-select:not(.larkmap-select-customize-input) .larkmap-select-selector input{cursor:pointer}.larkmap-select-show-search.larkmap-select:not(.larkmap-select-customize-input) .larkmap-select-selector{cursor:text}.larkmap-select-show-search.larkmap-select:not(.larkmap-select-customize-input) .larkmap-select-selector input{cursor:auto}.larkmap-select-focused:not(.larkmap-select-disabled).larkmap-select:not(.larkmap-select-customize-input) .larkmap-select-selector{border-color:#40a9ff;box-shadow:0 0 0 2px #1890ff33;border-right-width:1px;outline:0}.larkmap-select-disabled.larkmap-select:not(.larkmap-select-customize-input) .larkmap-select-selector{color:#00000040;background:#f5f5f5;cursor:not-allowed}.larkmap-select-multiple.larkmap-select-disabled.larkmap-select:not(.larkmap-select-customize-input) .larkmap-select-selector{background:#f5f5f5}.larkmap-select-disabled.larkmap-select:not(.larkmap-select-customize-input) .larkmap-select-selector input{cursor:not-allowed}.larkmap-select:not(.larkmap-select-customize-input) .larkmap-select-selector .larkmap-select-selection-search-input{margin:0;padding:0;background:transparent;border:none;outline:none;-webkit-appearance:none;appearance:none}.larkmap-select:not(.larkmap-select-customize-input) .larkmap-select-selector .larkmap-select-selection-search-input::-webkit-search-cancel-button{display:none;-webkit-appearance:none}.larkmap-select:not(.larkmap-select-disabled):hover .larkmap-select-selector{border-color:#40a9ff;border-right-width:1px}.larkmap-select-selection-item{flex:1 1;overflow:hidden;font-weight:400;white-space:nowrap;text-overflow:ellipsis}@media all and (-ms-high-contrast: none){.larkmap-select-selection-item *::-ms-backdrop,.larkmap-select-selection-item{flex:auto}}.larkmap-select-selection-placeholder{flex:1 1;overflow:hidden;color:#bfbfbf;white-space:nowrap;text-overflow:ellipsis;pointer-events:none}@media all and (-ms-high-contrast: none){.larkmap-select-selection-placeholder *::-ms-backdrop,.larkmap-select-selection-placeholder{flex:auto}}.larkmap-select-arrow{font-style:normal;text-transform:none;text-rendering:optimizelegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;position:absolute;top:50%;right:11px;display:flex;align-items:center;height:12px;margin-top:-6px;color:#00000040;font-size:12px;line-height:1;text-align:center;pointer-events:none}.larkmap-select-arrow>*{line-height:1}.larkmap-select-arrow svg{display:inline-block}.larkmap-select-arrow:before{display:none}.larkmap-select-arrow .larkmap-select-arrow-icon{display:block}.larkmap-select-arrow .larkmapicon{vertical-align:top;transition:transform .3s}.larkmap-select-arrow .larkmapicon>svg{vertical-align:top}.larkmap-select-arrow .larkmapicon:not(.larkmap-select-suffix){pointer-events:auto}.larkmap-select-disabled .larkmap-select-arrow{cursor:not-allowed}.larkmap-select-arrow>*:not(:last-child){margin-inline-end:8px}.larkmap-select-clear{position:absolute;top:50%;right:11px;z-index:1;display:inline-block;width:12px;height:12px;margin-top:-6px;color:#00000040;font-size:12px;font-style:normal;line-height:1;text-align:center;text-transform:none;background:#fff;cursor:pointer;opacity:0;transition:color .3s ease,opacity .15s ease;text-rendering:auto}.larkmap-select-clear:before{display:block}.larkmap-select-clear:hover{color:#00000073}.larkmap-select:hover .larkmap-select-clear{opacity:1}.larkmap-select-dropdown{margin:0;color:#000000d9;line-height:1.5715;list-style:none;font-feature-settings:"tnum",;position:absolute;top:-9999px;left:-9999px;z-index:1050;box-sizing:border-box;padding:4px 0;overflow:hidden;font-size:14px;font-variant:initial;background-color:#fff;border-radius:2px;outline:none;box-shadow:0 3px 6px -4px #0000001f,0 6px 16px #00000014,0 9px 28px 8px #0000000d}.larkmap-select-dropdown.larkmap-slide-up-enter.larkmap-slide-up-enter-active.larkmap-select-dropdown-placement-bottomLeft,.larkmap-select-dropdown.larkmap-slide-up-appear.larkmap-slide-up-appear-active.larkmap-select-dropdown-placement-bottomLeft{animation-name:antSlideUpIn}.larkmap-select-dropdown.larkmap-slide-up-enter.larkmap-slide-up-enter-active.larkmap-select-dropdown-placement-topLeft,.larkmap-select-dropdown.larkmap-slide-up-appear.larkmap-slide-up-appear-active.larkmap-select-dropdown-placement-topLeft{animation-name:antSlideDownIn}.larkmap-select-dropdown.larkmap-slide-up-leave.larkmap-slide-up-leave-active.larkmap-select-dropdown-placement-bottomLeft{animation-name:antSlideUpOut}.larkmap-select-dropdown.larkmap-slide-up-leave.larkmap-slide-up-leave-active.larkmap-select-dropdown-placement-topLeft{animation-name:antSlideDownOut}.larkmap-select-dropdown-hidden{display:none}.larkmap-select-dropdown-empty{color:#00000040}.larkmap-select-item-empty{position:relative;display:block;min-height:32px;padding:5px 12px;font-weight:400;font-size:14px;line-height:22px;color:#00000040}.larkmap-select-item{position:relative;display:block;min-height:32px;padding:5px 12px;color:#000000d9;font-weight:400;font-size:14px;line-height:22px;cursor:pointer;transition:background .3s ease}.larkmap-select-item-group{color:#00000073;font-size:12px;cursor:default}.larkmap-select-item-option{display:flex}.larkmap-select-item-option-content{flex:auto;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.larkmap-select-item-option-state{flex:none}.larkmap-select-item-option-active:not(.larkmap-select-item-option-disabled){background-color:#f5f5f5}.larkmap-select-item-option-selected:not(.larkmap-select-item-option-disabled){color:#000000d9;font-weight:600;background-color:#e6f7ff}.larkmap-select-item-option-selected:not(.larkmap-select-item-option-disabled) .larkmap-select-item-option-state{color:#1890ff}.larkmap-select-item-option-disabled{color:#00000040;cursor:not-allowed}.larkmap-select-item-option-disabled.larkmap-select-item-option-selected{background-color:#f5f5f5}.larkmap-select-item-option-grouped{padding-left:24px}.larkmap-select-lg{font-size:16px}.larkmap-select-borderless .larkmap-select-selector{background-color:transparent!important;border-color:transparent!important;box-shadow:none!important}.larkmap-select.larkmap-select-in-form-item{width:100%}.larkmap-administrative-location{background-color:#fff;padding:4px}.larkmap-legend-icon__content{display:flex;align-items:center;line-height:2}.larkmap-legend-icon__content__icon{width:16px;height:16px;margin-right:10px}.larkmap-legend-proportion{display:flex;align-items:flex-end}.larkmap-legend-proportion__circlebox{position:relative;display:flex;justify-content:flex-end;align-items:flex-end;margin-right:10px}.larkmap-legend-proportion__circlebox__item{border-radius:50%;position:absolute;border:1px solid #e1e3e4}.larkmap-legend-proportion__labelitem{font-size:14px}.larkmap-legend-category__content{display:flex;align-items:center;margin-bottom:5px}.larkmap-legend-category__content__labels{letter-spacing:2;text-transform:uppercase;font-family:PingFangSC;line-height:2}.larkmap-legend-category__content__shape{margin-right:15px}.larkmap-legend-category__content__square{width:32px;height:15px}.larkmap-legend-category__content__circle{width:14px;height:14px;border-radius:50%}.larkmap-legend-ramp,.larkmap-legend-ramp__dis-continuous{width:100%}.larkmap-legend-ramp__dis-continuous__colors{display:flex;align-items:center;padding:4px 0}.larkmap-legend-ramp__dis-continuous__color{height:10px}.larkmap-legend-ramp__dis-continuous__color:first-child{border-radius:5px 0 0 5px}.larkmap-legend-ramp__dis-continuous__color:last-child{border-radius:0 5px 5px 0}.larkmap-legend-ramp__dis-continuous__labels{display:flex;align-items:center;width:100%}.larkmap-legend-ramp__dis-continuous__label{flex-basis:0;flex-grow:1;max-width:100%;font-size:12px;text-align:center}.larkmap-legend-ramp__continuous{height:10px;margin:4px 0;border-radius:5px}.larkmap-legend-ramp__continuous-labelbar{display:flex;align-items:center;justify-content:space-between;font-size:12px}.li-map-container{position:relative}.iconPlace___lj9tm{width:30px;height:30px}.bubble___kYwVb{position:relative;border-radius:6px;padding:5px;color:#fff;font-family:Arial,sans-serif;display:flex;align-items:center;font-size:11px;box-shadow:0 0 3px #0000001a}.weatherTool___ZeItW{display:flex;align-items:center} diff --git a/packages/site/public/weather/umi.4c6db688.js b/packages/site/public/weather/umi.4c6db688.js new file mode 100644 index 0000000000..10be3172f3 --- /dev/null +++ b/packages/site/public/weather/umi.4c6db688.js @@ -0,0 +1,17 @@ +(function(){var vi={45906:function(c,h,t){"use strict";t.d(h,{f:function(){return v}});var o=t(31468),u=t.n(o),a=t(82242),s=t.n(a),l=t(19340),d,f="/";function v(g){var S;return g.type==="hash"?S=(0,l.q_)():g.type==="memory"?S=(0,l.PP)(g):S=(0,l.lX)(),g.basename&&(f=g.basename),d=s()(s()({},S),{},{push:function(I,w){S.push(y(I,S),w)},replace:function(I,w){S.replace(y(I,S),w)},get location(){return S.location},get action(){return S.action}}),S}function y(g,S){if(typeof g=="string")return"".concat(m(f)).concat(g);if(u()(g)==="object"){var E=S.location.pathname;return s()(s()({},g),{},{pathname:g.pathname?"".concat(m(f)).concat(g.pathname):E})}else throw new Error("Unexpected to: ".concat(g))}function m(g){return g.slice(-1)==="/"?g.slice(0,-1):g}},49504:function(c,h,t){"use strict";t.d(h,{Ac:function(){return C},j3:function(){return o.j3},Q$:function(){return D}});var o=t(35338),u=t(8616);function a(){"use strict";a=function(){return j};var N,j={},O=Object.prototype,T=O.hasOwnProperty,Y=Object.defineProperty||function(Ie,V,le){Ie[V]=le.value},oe=typeof Symbol=="function"?Symbol:{},k=oe.iterator||"@@iterator",z=oe.asyncIterator||"@@asyncIterator",H=oe.toStringTag||"@@toStringTag";function re(Ie,V,le){return Object.defineProperty(Ie,V,{value:le,enumerable:!0,configurable:!0,writable:!0}),Ie[V]}try{re({},"")}catch(Ie){re=function(le,Ee,Pe){return le[Ee]=Pe}}function ve(Ie,V,le,Ee){var Pe=V&&V.prototype instanceof xt?V:xt,Re=Object.create(Pe.prototype),we=new Ue(Ee||[]);return Y(Re,"_invoke",{value:Me(Ie,le,we)}),Re}function pe(Ie,V,le){try{return{type:"normal",arg:Ie.call(V,le)}}catch(Ee){return{type:"throw",arg:Ee}}}j.wrap=ve;var Ce="suspendedStart",Le="suspendedYield",qe="executing",$e="completed",Ye={};function xt(){}function Ct(){}function ct(){}var Nt={};re(Nt,k,function(){return this});var Jt=Object.getPrototypeOf,Xt=Jt&&Jt(Jt(at([])));Xt&&Xt!==O&&T.call(Xt,k)&&(Nt=Xt);var de=ct.prototype=xt.prototype=Object.create(Nt);function ge(Ie){["next","throw","return"].forEach(function(V){re(Ie,V,function(le){return this._invoke(V,le)})})}function xe(Ie,V){function le(Pe,Re,we,Ze){var et=pe(Ie[Pe],Ie,Re);if(et.type!=="throw"){var dt=et.arg,it=dt.value;return it&&(0,u.Z)(it)=="object"&&T.call(it,"__await")?V.resolve(it.__await).then(function(ht){le("next",ht,we,Ze)},function(ht){le("throw",ht,we,Ze)}):V.resolve(it).then(function(ht){dt.value=ht,we(dt)},function(ht){return le("throw",ht,we,Ze)})}Ze(et.arg)}var Ee;Y(this,"_invoke",{value:function(Re,we){function Ze(){return new V(function(et,dt){le(Re,we,et,dt)})}return Ee=Ee?Ee.then(Ze,Ze):Ze()}})}function Me(Ie,V,le){var Ee=Ce;return function(Pe,Re){if(Ee===qe)throw new Error("Generator is already running");if(Ee===$e){if(Pe==="throw")throw Re;return{value:N,done:!0}}for(le.method=Pe,le.arg=Re;;){var we=le.delegate;if(we){var Ze=je(we,le);if(Ze){if(Ze===Ye)continue;return Ze}}if(le.method==="next")le.sent=le._sent=le.arg;else if(le.method==="throw"){if(Ee===Ce)throw Ee=$e,le.arg;le.dispatchException(le.arg)}else le.method==="return"&&le.abrupt("return",le.arg);Ee=qe;var et=pe(Ie,V,le);if(et.type==="normal"){if(Ee=le.done?$e:Le,et.arg===Ye)continue;return{value:et.arg,done:le.done}}et.type==="throw"&&(Ee=$e,le.method="throw",le.arg=et.arg)}}}function je(Ie,V){var le=V.method,Ee=Ie.iterator[le];if(Ee===N)return V.delegate=null,le==="throw"&&Ie.iterator.return&&(V.method="return",V.arg=N,je(Ie,V),V.method==="throw")||le!=="return"&&(V.method="throw",V.arg=new TypeError("The iterator does not provide a '"+le+"' method")),Ye;var Pe=pe(Ee,Ie.iterator,V.arg);if(Pe.type==="throw")return V.method="throw",V.arg=Pe.arg,V.delegate=null,Ye;var Re=Pe.arg;return Re?Re.done?(V[Ie.resultName]=Re.value,V.next=Ie.nextLoc,V.method!=="return"&&(V.method="next",V.arg=N),V.delegate=null,Ye):Re:(V.method="throw",V.arg=new TypeError("iterator result is not an object"),V.delegate=null,Ye)}function Je(Ie){var V={tryLoc:Ie[0]};1 in Ie&&(V.catchLoc=Ie[1]),2 in Ie&&(V.finallyLoc=Ie[2],V.afterLoc=Ie[3]),this.tryEntries.push(V)}function ke(Ie){var V=Ie.completion||{};V.type="normal",delete V.arg,Ie.completion=V}function Ue(Ie){this.tryEntries=[{tryLoc:"root"}],Ie.forEach(Je,this),this.reset(!0)}function at(Ie){if(Ie||Ie===""){var V=Ie[k];if(V)return V.call(Ie);if(typeof Ie.next=="function")return Ie;if(!isNaN(Ie.length)){var le=-1,Ee=function Pe(){for(;++le=0;--Pe){var Re=this.tryEntries[Pe],we=Re.completion;if(Re.tryLoc==="root")return Ee("end");if(Re.tryLoc<=this.prev){var Ze=T.call(Re,"catchLoc"),et=T.call(Re,"finallyLoc");if(Ze&&et){if(this.prev=0;--Ee){var Pe=this.tryEntries[Ee];if(Pe.tryLoc<=this.prev&&T.call(Pe,"finallyLoc")&&this.prev=0;--le){var Ee=this.tryEntries[le];if(Ee.finallyLoc===V)return this.complete(Ee.completion,Ee.afterLoc),ke(Ee),Ye}},catch:function(V){for(var le=this.tryEntries.length-1;le>=0;--le){var Ee=this.tryEntries[le];if(Ee.tryLoc===V){var Pe=Ee.completion;if(Pe.type==="throw"){var Re=Pe.arg;ke(Ee)}return Re}}throw new Error("illegal catch attempt")},delegateYield:function(V,le,Ee){return this.delegate={iterator:at(V),resultName:le,nextLoc:Ee},this.method==="next"&&(this.arg=N),Ye}},j}var s=t(63579);function l(N,j,O,T,Y,oe,k){try{var z=N[oe](k),H=z.value}catch(re){O(re);return}z.done?j(H):Promise.resolve(H).then(T,Y)}function d(N){return function(){var j=this,O=arguments;return new Promise(function(T,Y){var oe=N.apply(j,O);function k(H){l(oe,T,Y,k,z,"next",H)}function z(H){l(oe,T,Y,k,z,"throw",H)}k(void 0)})}}var f=t(99227);function v(N,j){var O=typeof Symbol!="undefined"&&N[Symbol.iterator]||N["@@iterator"];if(!O){if(Array.isArray(N)||(O=(0,f.Z)(N))||j&&N&&typeof N.length=="number"){O&&(N=O);var T=0,Y=function(){};return{s:Y,n:function(){return T>=N.length?{done:!0}:{done:!1,value:N[T++]}},e:function(re){throw re},f:Y}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var oe=!0,k=!1,z;return{s:function(){O=O.call(N)},n:function(){var re=O.next();return oe=re.done,re},e:function(re){k=!0,z=re},f:function(){try{!oe&&O.return!=null&&O.return()}finally{if(k)throw z}}}}var y=t(73825);function m(N){if(typeof Symbol!="undefined"&&N[Symbol.iterator]!=null||N["@@iterator"]!=null)return Array.from(N)}var g=t(66160);function S(N){return(0,y.Z)(N)||m(N)||(0,f.Z)(N)||(0,g.Z)()}function E(N,j){if(!(N instanceof j))throw new TypeError("Cannot call a class as a function")}var I=t(89878);function w(N,j){for(var O=0;O-1,"register failed, invalid key ".concat(Y," ").concat(O.path?"from plugin ".concat(O.path):"",".")),T.hooks[Y]=(T.hooks[Y]||[]).concat(O.apply[Y])})}},{key:"getHooks",value:function(O){var T=O.split("."),Y=S(T),oe=Y[0],k=Y.slice(1),z=this.hooks[oe]||[];return k.length&&(z=z.map(function(H){try{var re=H,ve=v(k),pe;try{for(ve.s();!(pe=ve.n()).done;){var Ce=pe.value;re=re[Ce]}}catch(Le){ve.e(Le)}finally{ve.f()}return re}catch(Le){return null}}).filter(Boolean)),z}},{key:"applyPlugins",value:function(O){var T=O.key,Y=O.type,oe=O.initialValue,k=O.args,z=O.async,H=this.getHooks(T)||[];switch(k&&M((0,u.Z)(k)==="object","applyPlugins failed, args must be plain object."),z&&M(Y===C.modify||Y===C.event,"async only works with modify and event type."),Y){case C.modify:return z?H.reduce(function(){var re=d(a().mark(function ve(pe,Ce){var Le;return a().wrap(function($e){for(;;)switch($e.prev=$e.next){case 0:if(M(typeof Ce=="function"||(0,u.Z)(Ce)==="object"||F(Ce),"applyPlugins failed, all hooks for key ".concat(T," must be function, plain object or Promise.")),!F(pe)){$e.next=5;break}return $e.next=4,pe;case 4:pe=$e.sent;case 5:if(typeof Ce!="function"){$e.next=16;break}if(Le=Ce(pe,k),!F(Le)){$e.next=13;break}return $e.next=10,Le;case 10:return $e.abrupt("return",$e.sent);case 13:return $e.abrupt("return",Le);case 14:$e.next=21;break;case 16:if(!F(Ce)){$e.next=20;break}return $e.next=19,Ce;case 19:Ce=$e.sent;case 20:return $e.abrupt("return",(0,s.Z)((0,s.Z)({},pe),Ce));case 21:case"end":return $e.stop()}},ve)}));return function(ve,pe){return re.apply(this,arguments)}}(),F(oe)?oe:Promise.resolve(oe)):H.reduce(function(re,ve){return M(typeof ve=="function"||(0,u.Z)(ve)==="object","applyPlugins failed, all hooks for key ".concat(T," must be function or plain object.")),typeof ve=="function"?ve(re,k):(0,s.Z)((0,s.Z)({},re),ve)},oe);case C.event:return d(a().mark(function re(){var ve,pe,Ce,Le;return a().wrap(function($e){for(;;)switch($e.prev=$e.next){case 0:ve=v(H),$e.prev=1,ve.s();case 3:if((pe=ve.n()).done){$e.next=12;break}if(Ce=pe.value,M(typeof Ce=="function","applyPlugins failed, all hooks for key ".concat(T," must be function.")),Le=Ce(k),!(z&&F(Le))){$e.next=10;break}return $e.next=10,Le;case 10:$e.next=3;break;case 12:$e.next=17;break;case 14:$e.prev=14,$e.t0=$e.catch(1),ve.e($e.t0);case 17:return $e.prev=17,ve.f(),$e.finish(17);case 20:case"end":return $e.stop()}},re,null,[[1,14,17,20]])}))();case C.compose:return function(){return L({fns:H.concat(oe),args:k})()}}}}],[{key:"create",value:function(O){var T=new N({validKeys:O.validKeys});return O.plugins.forEach(function(Y){T.register(Y)}),T}}]),N}(),U=t(45906),J=t(31468),W=t.n(J),Z=0,K=0;function ee(N,j){if(!1)var O}function ne(N){return JSON.stringify(N,null,2)}function ie(N){var j=N.length>1?N.map(se).join(" "):N[0];return W()(j)==="object"?"".concat(ne(j)):j.toString()}function se(N){return W()(N)==="object"?"".concat(JSON.stringify(N)):N.toString()}var te={log:function(){for(var j=arguments.length,O=new Array(j),T=0;T=0&&(M.hash=A.substr(L),A=A.substr(0,L));var F=A.indexOf("?");F>=0&&(M.search=A.substr(F),A=A.substr(0,F)),A&&(M.pathname=A)}return M}},44520:function(c){"use strict";var h=function(t,o,u,a,s,l,d,f){if(!t){var v;if(o===void 0)v=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var y=[u,a,s,l,d,f],m=0;v=new Error(o.replace(/%s/g,function(){return y[m++]})),v.name="Invariant Violation"}throw v.framesToPop=1,v}};c.exports=h},79442:function(c,h,t){"use strict";var o=t(97825);function u(){}function a(){}a.resetWarningCache=u,c.exports=function(){function s(f,v,y,m,g,S){if(S!==o){var E=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw E.name="Invariant Violation",E}}s.isRequired=s;function l(){return s}var d={array:s,bigint:s,bool:s,func:s,number:s,object:s,string:s,symbol:s,any:s,arrayOf:l,element:s,elementType:s,instanceOf:l,node:s,objectOf:l,oneOf:l,oneOfType:l,shape:l,exact:l,checkPropTypes:a,resetWarningCache:u};return d.PropTypes=d,d}},12708:function(c,h,t){if(!1)var o,u;else c.exports=t(79442)()},97825:function(c){"use strict";var h="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";c.exports=h},13490:function(c,h,t){"use strict";var o=t(77617),u=t(79727);function a(e){for(var r="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;nr}return!1}function P(e,r,n,i,p,x,R){this.acceptsBooleans=r===2||r===3||r===4,this.attributeName=i,this.attributeNamespace=p,this.mustUseProperty=n,this.propertyName=e,this.type=r,this.sanitizeURL=x,this.removeEmptyString=R}var A={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){A[e]=new P(e,0,!1,e,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var r=e[0];A[r]=new P(r,1,!1,e[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(e){A[e]=new P(e,2,!1,e.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){A[e]=new P(e,2,!1,e,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){A[e]=new P(e,3,!1,e.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(e){A[e]=new P(e,3,!0,e,null,!1,!1)}),["capture","download"].forEach(function(e){A[e]=new P(e,4,!1,e,null,!1,!1)}),["cols","rows","size","span"].forEach(function(e){A[e]=new P(e,6,!1,e,null,!1,!1)}),["rowSpan","start"].forEach(function(e){A[e]=new P(e,5,!1,e.toLowerCase(),null,!1,!1)});var M=/[\-:]([a-z])/g;function L(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var r=e.replace(M,L);A[r]=new P(r,1,!1,e,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var r=e.replace(M,L);A[r]=new P(r,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(e){var r=e.replace(M,L);A[r]=new P(r,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(e){A[e]=new P(e,1,!1,e.toLowerCase(),null,!1,!1)}),A.xlinkHref=new P("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(e){A[e]=new P(e,1,!1,e.toLowerCase(),null,!0,!0)});function F(e,r,n,i){var p=A.hasOwnProperty(r)?A[r]:null;(p!==null?p.type!==0:i||!(2b||p[R]!==x[b]){var Q=` +`+p[R].replace(" at new "," at ");return e.displayName&&Q.includes("")&&(Q=Q.replace("",e.displayName)),Q}while(1<=R&&0<=b);break}}}finally{k=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?oe(e):""}function H(e){switch(e.tag){case 5:return oe(e.type);case 16:return oe("Lazy");case 13:return oe("Suspense");case 19:return oe("SuspenseList");case 0:case 2:case 15:return e=z(e.type,!1),e;case 11:return e=z(e.type.render,!1),e;case 1:return e=z(e.type,!0),e;default:return""}}function re(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case J:return"Fragment";case U:return"Portal";case Z:return"Profiler";case W:return"StrictMode";case ie:return"Suspense";case se:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case ee:return(e.displayName||"Context")+".Consumer";case K:return(e._context.displayName||"Context")+".Provider";case ne:var r=e.render;return e=e.displayName,e||(e=r.displayName||r.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case te:return r=e.displayName||null,r!==null?r:re(e.type)||"Memo";case $:r=e._payload,e=e._init;try{return re(e(r))}catch(n){}}return null}function ve(e){var r=e.type;switch(e.tag){case 24:return"Cache";case 9:return(r.displayName||"Context")+".Consumer";case 10:return(r._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=r.render,e=e.displayName||e.name||"",r.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return r;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return re(r);case 8:return r===W?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof r=="function")return r.displayName||r.name||null;if(typeof r=="string")return r}return null}function pe(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Ce(e){var r=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(r==="checkbox"||r==="radio")}function Le(e){var r=Ce(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,r),i=""+e[r];if(!e.hasOwnProperty(r)&&typeof n!="undefined"&&typeof n.get=="function"&&typeof n.set=="function"){var p=n.get,x=n.set;return Object.defineProperty(e,r,{configurable:!0,get:function(){return p.call(this)},set:function(R){i=""+R,x.call(this,R)}}),Object.defineProperty(e,r,{enumerable:n.enumerable}),{getValue:function(){return i},setValue:function(R){i=""+R},stopTracking:function(){e._valueTracker=null,delete e[r]}}}}function qe(e){e._valueTracker||(e._valueTracker=Le(e))}function $e(e){if(!e)return!1;var r=e._valueTracker;if(!r)return!0;var n=r.getValue(),i="";return e&&(i=Ce(e)?e.checked?"true":"false":e.value),e=i,e!==n?(r.setValue(e),!0):!1}function Ye(e){if(e=e||(typeof document!="undefined"?document:void 0),typeof e=="undefined")return null;try{return e.activeElement||e.body}catch(r){return e.body}}function xt(e,r){var n=r.checked;return T({},r,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n!=null?n:e._wrapperState.initialChecked})}function Ct(e,r){var n=r.defaultValue==null?"":r.defaultValue,i=r.checked!=null?r.checked:r.defaultChecked;n=pe(r.value!=null?r.value:n),e._wrapperState={initialChecked:i,initialValue:n,controlled:r.type==="checkbox"||r.type==="radio"?r.checked!=null:r.value!=null}}function ct(e,r){r=r.checked,r!=null&&F(e,"checked",r,!1)}function Nt(e,r){ct(e,r);var n=pe(r.value),i=r.type;if(n!=null)i==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(i==="submit"||i==="reset"){e.removeAttribute("value");return}r.hasOwnProperty("value")?Xt(e,r.type,n):r.hasOwnProperty("defaultValue")&&Xt(e,r.type,pe(r.defaultValue)),r.checked==null&&r.defaultChecked!=null&&(e.defaultChecked=!!r.defaultChecked)}function Jt(e,r,n){if(r.hasOwnProperty("value")||r.hasOwnProperty("defaultValue")){var i=r.type;if(!(i!=="submit"&&i!=="reset"||r.value!==void 0&&r.value!==null))return;r=""+e._wrapperState.initialValue,n||r===e.value||(e.value=r),e.defaultValue=r}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function Xt(e,r,n){(r!=="number"||Ye(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var de=Array.isArray;function ge(e,r,n,i){if(e=e.options,r){r={};for(var p=0;p"+r.valueOf().toString()+"",r=at.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;r.firstChild;)e.appendChild(r.firstChild)}});function V(e,r){if(r){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=r;return}}e.textContent=r}var le={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Ee=["Webkit","ms","Moz","O"];Object.keys(le).forEach(function(e){Ee.forEach(function(r){r=r+e.charAt(0).toUpperCase()+e.substring(1),le[r]=le[e]})});function Pe(e,r,n){return r==null||typeof r=="boolean"||r===""?"":n||typeof r!="number"||r===0||le.hasOwnProperty(e)&&le[e]?(""+r).trim():r+"px"}function Re(e,r){e=e.style;for(var n in r)if(r.hasOwnProperty(n)){var i=n.indexOf("--")===0,p=Pe(n,r[n],i);n==="float"&&(n="cssFloat"),i?e.setProperty(n,p):e[n]=p}}var we=T({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Ze(e,r){if(r){if(we[e]&&(r.children!=null||r.dangerouslySetInnerHTML!=null))throw Error(a(137,e));if(r.dangerouslySetInnerHTML!=null){if(r.children!=null)throw Error(a(60));if(typeof r.dangerouslySetInnerHTML!="object"||!("__html"in r.dangerouslySetInnerHTML))throw Error(a(61))}if(r.style!=null&&typeof r.style!="object")throw Error(a(62))}}function et(e,r){if(e.indexOf("-")===-1)return typeof r.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var dt=null;function it(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var ht=null,yt=null,sr=null;function ju(e){if(e=Fn(e)){if(typeof ht!="function")throw Error(a(280));var r=e.stateNode;r&&(r=un(r),ht(e.stateNode,e.type,r))}}function Du(e){yt?sr?sr.push(e):sr=[e]:yt=e}function $u(){if(yt){var e=yt,r=sr;if(sr=yt=null,ju(e),r)for(e=0;e>>=0,e===0?32:31-(wi(e)/Ai|0)|0}var Da=64,$a=4194304;function Jn(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function Fa(e,r){var n=e.pendingLanes;if(n===0)return 0;var i=0,p=e.suspendedLanes,x=e.pingedLanes,R=n&268435455;if(R!==0){var b=R&~p;b!==0?i=Jn(b):(x&=R,x!==0&&(i=Jn(x)))}else R=n&~p,R!==0?i=Jn(R):x!==0&&(i=Jn(x));if(i===0)return 0;if(r!==0&&r!==i&&!(r&p)&&(p=i&-i,x=r&-r,p>=x||p===16&&(x&4194240)!==0))return r;if(i&4&&(i|=n&16),r=e.entangledLanes,r!==0)for(e=e.entanglements,r&=i;0n;n++)r.push(e);return r}function Xn(e,r,n){e.pendingLanes|=r,r!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,r=31-dr(r),e[r]=n}function Mi(e,r){var n=e.pendingLanes&~r;e.pendingLanes=r,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=r,e.mutableReadLanes&=r,e.entangledLanes&=r,r=e.entanglements;var i=e.eventTimes;for(e=e.expirationTimes;0=oa),ls=String.fromCharCode(32),cs=!1;function fs(e,r){switch(e){case"keyup":return al.indexOf(r.keyCode)!==-1;case"keydown":return r.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function ds(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var On=!1;function ul(e,r){switch(e){case"compositionend":return ds(r);case"keypress":return r.which!==32?null:(cs=!0,ls);case"textInput":return e=r.data,e===ls&&cs?null:e;default:return null}}function sl(e,r){if(On)return e==="compositionend"||!Wo&&fs(e,r)?(e=ns(),ka=Fo=Wr=null,On=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(r.ctrlKey||r.altKey||r.metaKey)||r.ctrlKey&&r.altKey){if(r.char&&1=r)return{node:n,offset:r-e};e=i}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=ua(n)}}function Ko(e,r){return e&&r?e===r?!0:e&&e.nodeType===3?!1:r&&r.nodeType===3?Ko(e,r.parentNode):"contains"in e?e.contains(r):e.compareDocumentPosition?!!(e.compareDocumentPosition(r)&16):!1:!1}function Go(){for(var e=window,r=Ye();r instanceof e.HTMLIFrameElement;){try{var n=typeof r.contentWindow.location.href=="string"}catch(i){n=!1}if(n)e=r.contentWindow;else break;r=Ye(e.document)}return r}function sa(e){var r=e&&e.nodeName&&e.nodeName.toLowerCase();return r&&(r==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||r==="textarea"||e.contentEditable==="true")}function ys(e){var r=Go(),n=e.focusedElem,i=e.selectionRange;if(r!==n&&n&&n.ownerDocument&&Ko(n.ownerDocument.documentElement,n)){if(i!==null&&sa(n)){if(r=i.start,e=i.end,e===void 0&&(e=r),"selectionStart"in n)n.selectionStart=r,n.selectionEnd=Math.min(e,n.value.length);else if(e=(r=n.ownerDocument||document)&&r.defaultView||window,e.getSelection){e=e.getSelection();var p=n.textContent.length,x=Math.min(i.start,p);i=i.end===void 0?x:Math.min(i.end,p),!e.extend&&x>i&&(p=i,i=x,x=p),p=Qa(n,x);var R=Qa(n,i);p&&R&&(e.rangeCount!==1||e.anchorNode!==p.node||e.anchorOffset!==p.offset||e.focusNode!==R.node||e.focusOffset!==R.offset)&&(r=r.createRange(),r.setStart(p.node,p.offset),e.removeAllRanges(),x>i?(e.addRange(r),e.extend(R.node,R.offset)):(r.setEnd(R.node,R.offset),e.addRange(r)))}}for(r=[],e=n;e=e.parentNode;)e.nodeType===1&&r.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,qr=null,Za=null,Cn=null,Rn=!1;function ms(e,r,n){var i=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Rn||qr==null||qr!==Ye(i)||(i=qr,"selectionStart"in i&&sa(i)?i={start:i.selectionStart,end:i.selectionEnd}:(i=(i.ownerDocument&&i.ownerDocument.defaultView||window).getSelection(),i={anchorNode:i.anchorNode,anchorOffset:i.anchorOffset,focusNode:i.focusNode,focusOffset:i.focusOffset}),Cn&&An(Cn,i)||(Cn=i,i=va(Za,"onSelect"),0sn||(e.current=oo[sn],oo[sn]=null,sn--)}function lt(e,r){sn++,oo[sn]=e.current,e.current=r}var jr={},Rt=rr(jr),Ht=rr(!1),ln=jr;function cn(e,r){var n=e.type.contextTypes;if(!n)return jr;var i=e.stateNode;if(i&&i.__reactInternalMemoizedUnmaskedChildContext===r)return i.__reactInternalMemoizedMaskedChildContext;var p={},x;for(x in n)p[x]=r[x];return i&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=r,e.__reactInternalMemoizedMaskedChildContext=p),p}function Vt(e){return e=e.childContextTypes,e!=null}function ga(){vt(Ht),vt(Rt)}function tu(e,r,n){if(Rt.current!==jr)throw Error(a(168));lt(Rt,r),lt(Ht,n)}function ma(e,r,n){var i=e.stateNode;if(r=r.childContextTypes,typeof i.getChildContext!="function")return n;i=i.getChildContext();for(var p in i)if(!(p in r))throw Error(a(108,ve(e)||"Unknown",p));return T({},n,i)}function G(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||jr,ln=Rt.current,lt(Rt,e),lt(Ht,Ht.current),!0}function q(e,r,n){var i=e.stateNode;if(!i)throw Error(a(169));n?(e=ma(e,r,ln),i.__reactInternalMemoizedMergedChildContext=e,vt(Ht),vt(Rt),lt(Rt,e)):vt(Ht),lt(Ht,n)}var ae=null,_=!1,he=!1;function Se(e){ae===null?ae=[e]:ae.push(e)}function Te(e){_=!0,Se(e)}function Oe(){if(!he&&ae!==null){he=!0;var e=0,r=st;try{var n=ae;for(st=1;e>=R,p-=R,Kr=1<<32-dr(r)+p|n<Qe?(zt=Ke,Ke=null):zt=Ke.sibling;var ut=ye(ue,Ke,ce[Qe],Ae);if(ut===null){Ke===null&&(Ke=zt);break}e&&Ke&&ut.alternate===null&&r(ue,Ke),X=x(ut,X,Qe),Ve===null?be=ut:Ve.sibling=ut,Ve=ut,Ke=zt}if(Qe===ce.length)return n(ue,Ke),mt&&zn(ue,Qe),be;if(Ke===null){for(;QeQe?(zt=Ke,Ke=null):zt=Ke.sibling;var xn=ye(ue,Ke,ut.value,Ae);if(xn===null){Ke===null&&(Ke=zt);break}e&&Ke&&xn.alternate===null&&r(ue,Ke),X=x(xn,X,Qe),Ve===null?be=xn:Ve.sibling=xn,Ve=xn,Ke=zt}if(ut.done)return n(ue,Ke),mt&&zn(ue,Qe),be;if(Ke===null){for(;!ut.done;Qe++,ut=ce.next())ut=De(ue,ut.value,Ae),ut!==null&&(X=x(ut,X,Qe),Ve===null?be=ut:Ve.sibling=ut,Ve=ut);return mt&&zn(ue,Qe),be}for(Ke=i(ue,Ke);!ut.done;Qe++,ut=ce.next())ut=Fe(Ke,ue,Qe,ut.value,Ae),ut!==null&&(e&&ut.alternate!==null&&Ke.delete(ut.key===null?Qe:ut.key),X=x(ut,X,Qe),Ve===null?be=ut:Ve.sibling=ut,Ve=ut);return e&&Ke.forEach(function(vf){return r(ue,vf)}),mt&&zn(ue,Qe),be}function At(ue,X,ce,Ae){if(typeof ce=="object"&&ce!==null&&ce.type===J&&ce.key===null&&(ce=ce.props.children),typeof ce=="object"&&ce!==null){switch(ce.$$typeof){case D:e:{for(var be=ce.key,Ve=X;Ve!==null;){if(Ve.key===be){if(be=ce.type,be===J){if(Ve.tag===7){n(ue,Ve.sibling),X=p(Ve,ce.props.children),X.return=ue,ue=X;break e}}else if(Ve.elementType===be||typeof be=="object"&&be!==null&&be.$$typeof===$&&hl(be)===Ve.type){n(ue,Ve.sibling),X=p(Ve,ce.props),X.ref=co(ue,Ve,ce),X.return=ue,ue=X;break e}n(ue,Ve);break}else r(ue,Ve);Ve=Ve.sibling}ce.type===J?(X=Gn(ce.props.children,ue.mode,Ae,ce.key),X.return=ue,ue=X):(Ae=wu(ce.type,ce.key,ce.props,null,ue.mode,Ae),Ae.ref=co(ue,X,ce),Ae.return=ue,ue=Ae)}return R(ue);case U:e:{for(Ve=ce.key;X!==null;){if(X.key===Ve)if(X.tag===4&&X.stateNode.containerInfo===ce.containerInfo&&X.stateNode.implementation===ce.implementation){n(ue,X.sibling),X=p(X,ce.children||[]),X.return=ue,ue=X;break e}else{n(ue,X);break}else r(ue,X);X=X.sibling}X=ii(ce,ue.mode,Ae),X.return=ue,ue=X}return R(ue);case $:return Ve=ce._init,At(ue,X,Ve(ce._payload),Ae)}if(de(ce))return Ne(ue,X,ce,Ae);if(O(ce))return Xe(ue,X,ce,Ae);au(ue,ce)}return typeof ce=="string"&&ce!==""||typeof ce=="number"?(ce=""+ce,X!==null&&X.tag===6?(n(ue,X.sibling),X=p(X,ce),X.return=ue,ue=X):(n(ue,X),X=si(ce,ue.mode,Ae),X.return=ue,ue=X),R(ue)):n(ue,X)}return At}var Ta=yl(!0),gl=yl(!1),fo={},$r=rr(fo),vo=rr(fo),po=rr(fo);function bn(e){if(e===fo)throw Error(a(174));return e}function Cs(e,r){switch(lt(po,r),lt(vo,e),lt($r,fo),e=r.nodeType,e){case 9:case 11:r=(r=r.documentElement)?r.namespaceURI:Ue(null,"");break;default:e=e===8?r.parentNode:r,r=e.namespaceURI||null,e=e.tagName,r=Ue(r,e)}vt($r),lt($r,r)}function wa(){vt($r),vt(vo),vt(po)}function ml(e){bn(po.current);var r=bn($r.current),n=Ue(r,e.type);r!==n&&(lt(vo,e),lt($r,n))}function Rs(e){vo.current===e&&(vt($r),vt(vo))}var Et=rr(0);function ou(e){for(var r=e;r!==null;){if(r.tag===13){var n=r.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return r}else if(r.tag===19&&r.memoizedProps.revealOrder!==void 0){if(r.flags&128)return r}else if(r.child!==null){r.child.return=r,r=r.child;continue}if(r===e)break;for(;r.sibling===null;){if(r.return===null||r.return===e)return null;r=r.return}r.sibling.return=r.return,r=r.sibling}return null}var Ps=[];function Ms(){for(var e=0;en?n:4,e(!0);var i=Ns.transition;Ns.transition={};try{e(!1),r()}finally{st=n,Ns.transition=i}}function $l(){return Er().memoizedState}function Bc(e,r,n){var i=yn(e);n={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null},Fl(e)?Bl(r,n):(Ul(e,r,n),n=_t(),e=Ir(e,i,n),e!==null&&zl(e,r,i))}function Uc(e,r,n){var i=yn(e),p={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null};if(Fl(e))Bl(r,p);else{Ul(e,r,p);var x=e.alternate;if(e.lanes===0&&(x===null||x.lanes===0)&&(x=r.lastRenderedReducer,x!==null))try{var R=r.lastRenderedState,b=x(R,n);if(p.hasEagerState=!0,p.eagerState=b,ir(b,R))return}catch(Q){}finally{}n=_t(),e=Ir(e,i,n),e!==null&&zl(e,r,i)}}function Fl(e){var r=e.alternate;return e===Ot||r!==null&&r===Ot}function Bl(e,r){ho=su=!0;var n=e.pending;n===null?r.next=r:(r.next=n.next,n.next=r),e.pending=r}function Ul(e,r,n){xc(e)?(e=r.interleaved,e===null?(n.next=n,Lt===null?Lt=[r]:Lt.push(r)):(n.next=e.next,e.next=n),r.interleaved=n):(e=r.pending,e===null?n.next=n:(n.next=e.next,e.next=n),r.pending=n)}function zl(e,r,n){if(n&4194240){var i=r.lanes;i&=e.pendingLanes,n|=i,r.lanes=n,No(e,n)}}var cu={readContext:Pt,useCallback:Yt,useContext:Yt,useEffect:Yt,useImperativeHandle:Yt,useInsertionEffect:Yt,useLayoutEffect:Yt,useMemo:Yt,useReducer:Yt,useRef:Yt,useState:Yt,useDebugValue:Yt,useDeferredValue:Yt,useTransition:Yt,useMutableSource:Yt,useSyncExternalStore:Yt,useId:Yt,unstable_isNewReconciler:!1},zc={readContext:Pt,useCallback:function(e,r){return Fr().memoizedState=[e,r===void 0?null:r],e},useContext:Pt,useEffect:Cl,useImperativeHandle:function(e,r,n){return n=n!=null?n.concat([e]):null,iu(4194308,4,Ml.bind(null,r,e),n)},useLayoutEffect:function(e,r){return iu(4194308,4,e,r)},useInsertionEffect:function(e,r){return iu(4,2,e,r)},useMemo:function(e,r){var n=Fr();return r=r===void 0?null:r,e=e(),n.memoizedState=[e,r],e},useReducer:function(e,r,n){var i=Fr();return r=n!==void 0?n(r):r,i.memoizedState=i.baseState=r,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:r},i.queue=e,e=e.dispatch=Bc.bind(null,Ot,e),[i.memoizedState,e]},useRef:function(e){var r=Fr();return e={current:e},r.memoizedState=e},useState:wl,useDebugValue:Us,useDeferredValue:function(e){return Fr().memoizedState=e},useTransition:function(){var e=wl(!1),r=e[0];return e=Fc.bind(null,e[1]),Fr().memoizedState=e,[r,e]},useMutableSource:function(){},useSyncExternalStore:function(e,r,n){var i=Ot,p=Fr();if(mt){if(n===void 0)throw Error(a(407));n=n()}else{if(n=r(),Dt===null)throw Error(a(349));kn&30||El(i,r,n)}p.memoizedState=n;var x={value:n,getSnapshot:r};return p.queue=x,Cl(Il.bind(null,i,x,e),[e]),i.flags|=2048,mo(9,Ol.bind(null,i,x,n,r),void 0,null),n},useId:function(){var e=Fr(),r=Dt.identifierPrefix;if(mt){var n=Gr,i=Kr;n=(i&~(1<<32-dr(i)-1)).toString(32)+n,r=":"+r+"R"+n,n=yo++,0<\/script>",e=e.removeChild(e.firstChild)):typeof i.is=="string"?e=R.createElement(n,{is:i.is}):(e=R.createElement(n),n==="select"&&(R=e,i.multiple?R.multiple=!0:i.size&&(R.size=i.size))):e=R.createElementNS(e,n),e[hr]=r,e[yr]=i,Kl(e,r,!1,!1),r.stateNode=e;e:{switch(R=et(n,i),n){case"dialog":ft("cancel",e),ft("close",e),p=i;break;case"iframe":case"object":case"embed":ft("load",e),p=i;break;case"video":case"audio":for(p=0;pRa&&(r.flags|=128,i=!0,xo(x,!1),r.lanes=4194304)}else{if(!i)if(e=ou(R),e!==null){if(r.flags|=128,i=!0,n=e.updateQueue,n!==null&&(r.updateQueue=n,r.flags|=4),xo(x,!0),x.tail===null&&x.tailMode==="hidden"&&!R.alternate&&!mt)return Qt(r),null}else 2*It()-x.renderingStartTime>Ra&&n!==1073741824&&(r.flags|=128,i=!0,xo(x,!1),r.lanes=4194304);x.isBackwards?(R.sibling=r.child,r.child=R):(n=x.last,n!==null?n.sibling=R:r.child=R,x.last=R)}return x.tail!==null?(r=x.tail,x.rendering=r,x.tail=r.sibling,x.renderingStartTime=It(),r.sibling=null,n=Et.current,lt(Et,i?n&1|2:n&1),r):(Qt(r),null);case 22:case 23:return ai(),i=r.memoizedState!==null,e!==null&&e.memoizedState!==null!==i&&(r.flags|=8192),i&&r.mode&1?fr&1073741824&&(Qt(r),r.subtreeFlags&6&&(r.flags|=8192)):Qt(r),null;case 24:return null;case 25:return null}throw Error(a(156,r.tag))}var Vc=C.ReactCurrentOwner,ar=!1;function qt(e,r,n,i){r.child=e===null?gl(r,null,n,i):Ta(r,e.child,n,i)}function Ql(e,r,n,i,p){n=n.render;var x=r.ref;return Kt(r,p),i=js(e,r,n,i,x,p),n=Ds(),e!==null&&!ar?(r.updateQueue=e.updateQueue,r.flags&=-2053,e.lanes&=~p,Yr(e,r,p)):(mt&&n&&Os(r),r.flags|=1,qt(e,r,i,p),r.child)}function Zl(e,r,n,i,p){if(e===null){var x=n.type;return typeof x=="function"&&!ui(x)&&x.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(r.tag=15,r.type=x,Jl(e,r,x,i,p)):(e=wu(n.type,null,i,r,r.mode,p),e.ref=r.ref,e.return=r,r.child=e)}if(x=e.child,!(e.lanes&p)){var R=x.memoizedProps;if(n=n.compare,n=n!==null?n:An,n(R,i)&&e.ref===r.ref)return Yr(e,r,p)}return r.flags|=1,e=mn(x,i),e.ref=r.ref,e.return=r,r.child=e}function Jl(e,r,n,i,p){if(e!==null){var x=e.memoizedProps;if(An(x,i)&&e.ref===r.ref)if(ar=!1,r.pendingProps=i=x,(e.lanes&p)!==0)e.flags&131072&&(ar=!0);else return r.lanes=e.lanes,Yr(e,r,p)}return Ws(e,r,n,i,p)}function Xl(e,r,n){var i=r.pendingProps,p=i.children,x=e!==null?e.memoizedState:null;if(i.mode==="hidden")if(!(r.mode&1))r.memoizedState={baseLanes:0,cachePool:null,transitions:null},lt(Ca,fr),fr|=n;else if(n&1073741824)r.memoizedState={baseLanes:0,cachePool:null,transitions:null},i=x!==null?x.baseLanes:n,lt(Ca,fr),fr|=i;else return e=x!==null?x.baseLanes|n:n,r.lanes=r.childLanes=1073741824,r.memoizedState={baseLanes:e,cachePool:null,transitions:null},r.updateQueue=null,lt(Ca,fr),fr|=e,null;else x!==null?(i=x.baseLanes|n,r.memoizedState=null):i=n,lt(Ca,fr),fr|=i;return qt(e,r,p,n),r.child}function ql(e,r){var n=r.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(r.flags|=512,r.flags|=2097152)}function Ws(e,r,n,i,p){var x=Vt(n)?ln:Rt.current;return x=cn(r,x),Kt(r,p),n=js(e,r,n,i,x,p),i=Ds(),e!==null&&!ar?(r.updateQueue=e.updateQueue,r.flags&=-2053,e.lanes&=~p,Yr(e,r,p)):(mt&&i&&Os(r),r.flags|=1,qt(e,r,n,p),r.child)}function _l(e,r,n,i,p){if(Vt(n)){var x=!0;G(r)}else x=!1;if(Kt(r,p),r.stateNode===null)e!==null&&(e.alternate=null,r.alternate=null,r.flags|=2),Dr(r,n,i),Es(r,n,i,p),i=!0;else if(e===null){var R=r.stateNode,b=r.memoizedProps;R.props=b;var Q=R.context,fe=n.contextType;typeof fe=="object"&&fe!==null?fe=Pt(fe):(fe=Vt(n)?ln:Rt.current,fe=cn(r,fe));var me=n.getDerivedStateFromProps,De=typeof me=="function"||typeof R.getSnapshotBeforeUpdate=="function";De||typeof R.UNSAFE_componentWillReceiveProps!="function"&&typeof R.componentWillReceiveProps!="function"||(b!==i||Q!==fe)&&Rr(r,R,i,fe),Gt=!1;var ye=r.memoizedState;R.state=ye,dn(r,i,R,p),Q=r.memoizedState,b!==i||ye!==Q||Ht.current||Gt?(typeof me=="function"&&(io(r,n,me,i),Q=r.memoizedState),(b=Gt||mr(r,n,b,i,ye,Q,fe))?(De||typeof R.UNSAFE_componentWillMount!="function"&&typeof R.componentWillMount!="function"||(typeof R.componentWillMount=="function"&&R.componentWillMount(),typeof R.UNSAFE_componentWillMount=="function"&&R.UNSAFE_componentWillMount()),typeof R.componentDidMount=="function"&&(r.flags|=4194308)):(typeof R.componentDidMount=="function"&&(r.flags|=4194308),r.memoizedProps=i,r.memoizedState=Q),R.props=i,R.state=Q,R.context=fe,i=b):(typeof R.componentDidMount=="function"&&(r.flags|=4194308),i=!1)}else{R=r.stateNode,xa(e,r),b=r.memoizedProps,fe=r.type===r.elementType?b:We(r.type,b),R.props=fe,De=r.pendingProps,ye=R.context,Q=n.contextType,typeof Q=="object"&&Q!==null?Q=Pt(Q):(Q=Vt(n)?ln:Rt.current,Q=cn(r,Q));var Fe=n.getDerivedStateFromProps;(me=typeof Fe=="function"||typeof R.getSnapshotBeforeUpdate=="function")||typeof R.UNSAFE_componentWillReceiveProps!="function"&&typeof R.componentWillReceiveProps!="function"||(b!==De||ye!==Q)&&Rr(r,R,i,Q),Gt=!1,ye=r.memoizedState,R.state=ye,dn(r,i,R,p);var Ne=r.memoizedState;b!==De||ye!==Ne||Ht.current||Gt?(typeof Fe=="function"&&(io(r,n,Fe,i),Ne=r.memoizedState),(fe=Gt||mr(r,n,fe,i,ye,Ne,Q)||!1)?(me||typeof R.UNSAFE_componentWillUpdate!="function"&&typeof R.componentWillUpdate!="function"||(typeof R.componentWillUpdate=="function"&&R.componentWillUpdate(i,Ne,Q),typeof R.UNSAFE_componentWillUpdate=="function"&&R.UNSAFE_componentWillUpdate(i,Ne,Q)),typeof R.componentDidUpdate=="function"&&(r.flags|=4),typeof R.getSnapshotBeforeUpdate=="function"&&(r.flags|=1024)):(typeof R.componentDidUpdate!="function"||b===e.memoizedProps&&ye===e.memoizedState||(r.flags|=4),typeof R.getSnapshotBeforeUpdate!="function"||b===e.memoizedProps&&ye===e.memoizedState||(r.flags|=1024),r.memoizedProps=i,r.memoizedState=Ne),R.props=i,R.state=Ne,R.context=Q,i=fe):(typeof R.componentDidUpdate!="function"||b===e.memoizedProps&&ye===e.memoizedState||(r.flags|=4),typeof R.getSnapshotBeforeUpdate!="function"||b===e.memoizedProps&&ye===e.memoizedState||(r.flags|=1024),i=!1)}return Hs(e,r,n,i,x,p)}function Hs(e,r,n,i,p,x){ql(e,r);var R=(r.flags&128)!==0;if(!i&&!R)return p&&q(r,n,!1),Yr(e,r,x);i=r.stateNode,Vc.current=r;var b=R&&typeof n.getDerivedStateFromError!="function"?null:i.render();return r.flags|=1,e!==null&&R?(r.child=Ta(r,e.child,null,x),r.child=Ta(r,null,b,x)):qt(e,r,b,x),r.memoizedState=i.state,p&&q(r,n,!0),r.child}function ec(e){var r=e.stateNode;r.pendingContext?tu(e,r.pendingContext,r.pendingContext!==r.context):r.context&&tu(e,r.context,!1),Cs(e,r.containerInfo)}function tc(e,r,n,i,p){return Ia(),As(p),r.flags|=256,qt(e,r,n,i),r.child}var fu={dehydrated:null,treeContext:null,retryLane:0};function du(e){return{baseLanes:e,cachePool:null,transitions:null}}function rc(e,r){return{baseLanes:e.baseLanes|r,cachePool:null,transitions:e.transitions}}function nc(e,r,n){var i=r.pendingProps,p=Et.current,x=!1,R=(r.flags&128)!==0,b;if((b=R)||(b=e!==null&&e.memoizedState===null?!1:(p&2)!==0),b?(x=!0,r.flags&=-129):(e===null||e.memoizedState!==null)&&(p|=1),lt(Et,p&1),e===null)return ws(r),e=r.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(r.mode&1?e.data==="$!"?r.lanes=8:r.lanes=1073741824:r.lanes=1,null):(p=i.children,e=i.fallback,x?(i=r.mode,x=r.child,p={mode:"hidden",children:p},!(i&1)&&x!==null?(x.childLanes=0,x.pendingProps=p):x=Au(p,i,0,null),e=Gn(e,i,n,null),x.return=r,e.return=r,x.sibling=e,r.child=x,r.child.memoizedState=du(n),r.memoizedState=fu,e):Vs(r,p));if(p=e.memoizedState,p!==null){if(b=p.dehydrated,b!==null){if(R)return r.flags&256?(r.flags&=-257,vu(e,r,n,Error(a(422)))):r.memoizedState!==null?(r.child=e.child,r.flags|=128,null):(x=i.fallback,p=r.mode,i=Au({mode:"visible",children:i.children},p,0,null),x=Gn(x,p,n,null),x.flags|=2,i.return=r,x.return=r,i.sibling=x,r.child=i,r.mode&1&&Ta(r,e.child,null,n),r.child.memoizedState=du(n),r.memoizedState=fu,x);if(!(r.mode&1))r=vu(e,r,n,null);else if(b.data==="$!")r=vu(e,r,n,Error(a(419)));else if(i=(n&e.childLanes)!==0,ar||i){if(i=Dt,i!==null){switch(n&-n){case 4:x=2;break;case 16:x=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:x=32;break;case 536870912:x=268435456;break;default:x=0}i=x&(i.suspendedLanes|n)?0:x,i!==0&&i!==p.retryLane&&(p.retryLane=i,Ir(e,i,-1))}oi(),r=vu(e,r,n,Error(a(421)))}else b.data==="$?"?(r.flags|=128,r.child=e.child,r=rf.bind(null,e),b._reactRetry=r,r=null):(n=p.treeContext,nr=lr(b.nextSibling),cr=r,mt=!0,Pr=null,n!==null&&(xr[Sr++]=Kr,xr[Sr++]=Gr,xr[Sr++]=Un,Kr=n.id,Gr=n.overflow,Un=r),r=Vs(r,r.pendingProps.children),r.flags|=4096);return r}return x?(i=oc(e,r,i.children,i.fallback,n),x=r.child,p=e.child.memoizedState,x.memoizedState=p===null?du(n):rc(p,n),x.childLanes=e.childLanes&~n,r.memoizedState=fu,i):(n=ac(e,r,i.children,n),r.memoizedState=null,n)}return x?(i=oc(e,r,i.children,i.fallback,n),x=r.child,p=e.child.memoizedState,x.memoizedState=p===null?du(n):rc(p,n),x.childLanes=e.childLanes&~n,r.memoizedState=fu,i):(n=ac(e,r,i.children,n),r.memoizedState=null,n)}function Vs(e,r){return r=Au({mode:"visible",children:r},e.mode,0,null),r.return=e,e.child=r}function ac(e,r,n,i){var p=e.child;return e=p.sibling,n=mn(p,{mode:"visible",children:n}),!(r.mode&1)&&(n.lanes=i),n.return=r,n.sibling=null,e!==null&&(i=r.deletions,i===null?(r.deletions=[e],r.flags|=16):i.push(e)),r.child=n}function oc(e,r,n,i,p){var x=r.mode;e=e.child;var R=e.sibling,b={mode:"hidden",children:n};return!(x&1)&&r.child!==e?(n=r.child,n.childLanes=0,n.pendingProps=b,r.deletions=null):(n=mn(e,b),n.subtreeFlags=e.subtreeFlags&14680064),R!==null?i=mn(R,i):(i=Gn(i,x,p,null),i.flags|=2),i.return=r,n.return=r,n.sibling=i,r.child=n,i}function vu(e,r,n,i){return i!==null&&As(i),Ta(r,e.child,null,n),e=Vs(r,r.pendingProps.children),e.flags|=2,r.memoizedState=null,e}function uc(e,r,n){e.lanes|=r;var i=e.alternate;i!==null&&(i.lanes|=r),Ft(e.return,r,n)}function Ks(e,r,n,i,p){var x=e.memoizedState;x===null?e.memoizedState={isBackwards:r,rendering:null,renderingStartTime:0,last:i,tail:n,tailMode:p}:(x.isBackwards=r,x.rendering=null,x.renderingStartTime=0,x.last=i,x.tail=n,x.tailMode=p)}function sc(e,r,n){var i=r.pendingProps,p=i.revealOrder,x=i.tail;if(qt(e,r,i.children,n),i=Et.current,i&2)i=i&1|2,r.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=r.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&uc(e,n,r);else if(e.tag===19)uc(e,n,r);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===r)break e;for(;e.sibling===null;){if(e.return===null||e.return===r)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}i&=1}if(lt(Et,i),!(r.mode&1))r.memoizedState=null;else switch(p){case"forwards":for(n=r.child,p=null;n!==null;)e=n.alternate,e!==null&&ou(e)===null&&(p=n),n=n.sibling;n=p,n===null?(p=r.child,r.child=null):(p=n.sibling,n.sibling=null),Ks(r,!1,p,n,x);break;case"backwards":for(n=null,p=r.child,r.child=null;p!==null;){if(e=p.alternate,e!==null&&ou(e)===null){r.child=p;break}e=p.sibling,p.sibling=n,n=p,p=e}Ks(r,!0,n,null,x);break;case"together":Ks(r,!1,null,null,void 0);break;default:r.memoizedState=null}return r.child}function Yr(e,r,n){if(e!==null&&(r.dependencies=e.dependencies),Wn|=r.lanes,!(n&r.childLanes))return null;if(e!==null&&r.child!==e.child)throw Error(a(153));if(r.child!==null){for(e=r.child,n=mn(e,e.pendingProps),r.child=n,n.return=r;e.sibling!==null;)e=e.sibling,n=n.sibling=mn(e,e.pendingProps),n.return=r;n.sibling=null}return r.child}function Kc(e,r,n){switch(r.tag){case 3:ec(r),Ia();break;case 5:ml(r);break;case 1:Vt(r.type)&&G(r);break;case 4:Cs(r,r.stateNode.containerInfo);break;case 10:var i=r.type._context,p=r.memoizedProps.value;lt(tt,i._currentValue),i._currentValue=p;break;case 13:if(i=r.memoizedState,i!==null)return i.dehydrated!==null?(lt(Et,Et.current&1),r.flags|=128,null):n&r.child.childLanes?nc(e,r,n):(lt(Et,Et.current&1),e=Yr(e,r,n),e!==null?e.sibling:null);lt(Et,Et.current&1);break;case 19:if(i=(n&r.childLanes)!==0,e.flags&128){if(i)return sc(e,r,n);r.flags|=128}if(p=r.memoizedState,p!==null&&(p.rendering=null,p.tail=null,p.lastEffect=null),lt(Et,Et.current),i)break;return null;case 22:case 23:return r.lanes=0,Xl(e,r,n)}return Yr(e,r,n)}function Gc(e,r){switch(Is(r),r.tag){case 1:return Vt(r.type)&&ga(),e=r.flags,e&65536?(r.flags=e&-65537|128,r):null;case 3:return wa(),vt(Ht),vt(Rt),Ms(),e=r.flags,e&65536&&!(e&128)?(r.flags=e&-65537|128,r):null;case 5:return Rs(r),null;case 13:if(vt(Et),e=r.memoizedState,e!==null&&e.dehydrated!==null){if(r.alternate===null)throw Error(a(340));Ia()}return e=r.flags,e&65536?(r.flags=e&-65537|128,r):null;case 19:return vt(Et),null;case 4:return wa(),null;case 10:return pt(r.type._context),null;case 22:case 23:return ai(),null;case 24:return null;default:return null}}var pu=!1,Zt=!1,Yc=typeof WeakSet=="function"?WeakSet:Set,Be=null;function Aa(e,r){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(i){Tt(e,r,i)}else n.current=null}function Gs(e,r,n){try{n()}catch(i){Tt(e,r,i)}}var ic=!1;function Qc(e,r){if(ha=za,e=Go(),sa(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var i=n.getSelection&&n.getSelection();if(i&&i.rangeCount!==0){n=i.anchorNode;var p=i.anchorOffset,x=i.focusNode;i=i.focusOffset;try{n.nodeType,x.nodeType}catch(be){n=null;break e}var R=0,b=-1,Q=-1,fe=0,me=0,De=e,ye=null;t:for(;;){for(var Fe;De!==n||p!==0&&De.nodeType!==3||(b=R+p),De!==x||i!==0&&De.nodeType!==3||(Q=R+i),De.nodeType===3&&(R+=De.nodeValue.length),(Fe=De.firstChild)!==null;)ye=De,De=Fe;for(;;){if(De===e)break t;if(ye===n&&++fe===p&&(b=R),ye===x&&++me===i&&(Q=R),(Fe=De.nextSibling)!==null)break;De=ye,ye=De.parentNode}De=Fe}n=b===-1||Q===-1?null:{start:b,end:Q}}else n=null}n=n||{start:0,end:0}}else n=null;for(ro={focusedElem:e,selectionRange:n},za=!1,Be=r;Be!==null;)if(r=Be,e=r.child,(r.subtreeFlags&1028)!==0&&e!==null)e.return=r,Be=e;else for(;Be!==null;){r=Be;try{var Ne=r.alternate;if(r.flags&1024)switch(r.tag){case 0:case 11:case 15:break;case 1:if(Ne!==null){var Xe=Ne.memoizedProps,At=Ne.memoizedState,ue=r.stateNode,X=ue.getSnapshotBeforeUpdate(r.elementType===r.type?Xe:We(r.type,Xe),At);ue.__reactInternalSnapshotBeforeUpdate=X}break;case 3:var ce=r.stateNode.containerInfo;if(ce.nodeType===1)ce.textContent="";else if(ce.nodeType===9){var Ae=ce.body;Ae!=null&&(Ae.textContent="")}break;case 5:case 6:case 4:case 17:break;default:throw Error(a(163))}}catch(be){Tt(r,r.return,be)}if(e=r.sibling,e!==null){e.return=r.return,Be=e;break}Be=r.return}return Ne=ic,ic=!1,Ne}function So(e,r,n){var i=r.updateQueue;if(i=i!==null?i.lastEffect:null,i!==null){var p=i=i.next;do{if((p.tag&e)===e){var x=p.destroy;p.destroy=void 0,x!==void 0&&Gs(r,n,x)}p=p.next}while(p!==i)}}function hu(e,r){if(r=r.updateQueue,r=r!==null?r.lastEffect:null,r!==null){var n=r=r.next;do{if((n.tag&e)===e){var i=n.create;n.destroy=i()}n=n.next}while(n!==r)}}function Ys(e){var r=e.ref;if(r!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof r=="function"?r(e):r.current=e}}function lc(e){var r=e.alternate;r!==null&&(e.alternate=null,lc(r)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(r=e.stateNode,r!==null&&(delete r[hr],delete r[yr],delete r[Dn],delete r[eu],delete r[$n])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function cc(e){return e.tag===5||e.tag===3||e.tag===4}function fc(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||cc(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Qs(e,r,n){var i=e.tag;if(i===5||i===6)e=e.stateNode,r?n.nodeType===8?n.parentNode.insertBefore(e,r):n.insertBefore(e,r):(n.nodeType===8?(r=n.parentNode,r.insertBefore(e,n)):(r=n,r.appendChild(e)),n=n._reactRootContainer,n!=null||r.onclick!==null||(r.onclick=rn));else if(i!==4&&(e=e.child,e!==null))for(Qs(e,r,n),e=e.sibling;e!==null;)Qs(e,r,n),e=e.sibling}function Zs(e,r,n){var i=e.tag;if(i===5||i===6)e=e.stateNode,r?n.insertBefore(e,r):n.appendChild(e);else if(i!==4&&(e=e.child,e!==null))for(Zs(e,r,n),e=e.sibling;e!==null;)Zs(e,r,n),e=e.sibling}var bt=null,Mr=!1;function vn(e,r,n){for(n=n.child;n!==null;)dc(e,r,n),n=n.sibling}function dc(e,r,n){if(wr&&typeof wr.onCommitFiberUnmount=="function")try{wr.onCommitFiberUnmount(ja,n)}catch(b){}switch(n.tag){case 5:Zt||Aa(n,r);case 6:var i=bt,p=Mr;bt=null,vn(e,r,n),bt=i,Mr=p,bt!==null&&(Mr?(e=bt,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):bt.removeChild(n.stateNode));break;case 18:bt!==null&&(Mr?(e=bt,n=n.stateNode,e.nodeType===8?nn(e.parentNode,n):e.nodeType===1&&nn(e,n),ra(e)):nn(bt,n.stateNode));break;case 4:i=bt,p=Mr,bt=n.stateNode.containerInfo,Mr=!0,vn(e,r,n),bt=i,Mr=p;break;case 0:case 11:case 14:case 15:if(!Zt&&(i=n.updateQueue,i!==null&&(i=i.lastEffect,i!==null))){p=i=i.next;do{var x=p,R=x.destroy;x=x.tag,R!==void 0&&(x&2||x&4)&&Gs(n,r,R),p=p.next}while(p!==i)}vn(e,r,n);break;case 1:if(!Zt&&(Aa(n,r),i=n.stateNode,typeof i.componentWillUnmount=="function"))try{i.props=n.memoizedProps,i.state=n.memoizedState,i.componentWillUnmount()}catch(b){Tt(n,r,b)}vn(e,r,n);break;case 21:vn(e,r,n);break;case 22:n.mode&1?(Zt=(i=Zt)||n.memoizedState!==null,vn(e,r,n),Zt=i):vn(e,r,n);break;default:vn(e,r,n)}}function vc(e){var r=e.updateQueue;if(r!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new Yc),r.forEach(function(i){var p=nf.bind(null,e,i);n.has(i)||(n.add(i),i.then(p,p))})}}function Nr(e,r){var n=r.deletions;if(n!==null)for(var i=0;ip&&(p=R),i&=~x}if(i=p,i=It()-i,i=(120>i?120:480>i?480:1080>i?1080:1920>i?1920:3e3>i?3e3:4320>i?4320:1960*Jc(i/1960))-i,10e?16:e,hn===null)var i=!1;else{if(e=hn,hn=null,Su=0,ot&6)throw Error(a(331));var p=ot;for(ot|=4,Be=e.current;Be!==null;){var x=Be,R=x.child;if(Be.flags&16){var b=x.deletions;if(b!==null){for(var Q=0;QIt()-qs?Vn(e,0):Xs|=n),ur(e,r)}function Cc(e,r){r===0&&(e.mode&1?(r=$a,$a<<=1,!($a&130023424)&&($a=4194304)):r=1);var n=_t();e=Iu(e,r),e!==null&&(Xn(e,r,n),ur(e,n))}function rf(e){var r=e.memoizedState,n=0;r!==null&&(n=r.retryLane),Cc(e,n)}function nf(e,r){var n=0;switch(e.tag){case 13:var i=e.stateNode,p=e.memoizedState;p!==null&&(n=p.retryLane);break;case 19:i=e.stateNode;break;default:throw Error(a(314))}i!==null&&i.delete(r),Cc(e,n)}var Rc;Rc=function(e,r,n){if(e!==null)if(e.memoizedProps!==r.pendingProps||Ht.current)ar=!0;else{if(!(e.lanes&n)&&!(r.flags&128))return ar=!1,Kc(e,r,n);ar=!!(e.flags&131072)}else ar=!1,mt&&r.flags&1048576&&fl(r,nu,r.index);switch(r.lanes=0,r.tag){case 2:var i=r.type;e!==null&&(e.alternate=null,r.alternate=null,r.flags|=2),e=r.pendingProps;var p=cn(r,Rt.current);Kt(r,n),p=js(null,r,i,e,p,n);var x=Ds();return r.flags|=1,typeof p=="object"&&p!==null&&typeof p.render=="function"&&p.$$typeof===void 0?(r.tag=1,r.memoizedState=null,r.updateQueue=null,Vt(i)?(x=!0,G(r)):x=!1,r.memoizedState=p.state!==null&&p.state!==void 0?p.state:null,Vr(r),p.updater=Bn,r.stateNode=p,p._reactInternals=r,Es(r,i,e,n),r=Hs(null,r,i,!0,x,n)):(r.tag=0,mt&&x&&Os(r),qt(null,r,p,n),r=r.child),r;case 16:i=r.elementType;e:{switch(e!==null&&(e.alternate=null,r.alternate=null,r.flags|=2),e=r.pendingProps,p=i._init,i=p(i._payload),r.type=i,p=r.tag=of(i),e=We(i,e),p){case 0:r=Ws(null,r,i,e,n);break e;case 1:r=_l(null,r,i,e,n);break e;case 11:r=Ql(null,r,i,e,n);break e;case 14:r=Zl(null,r,i,We(i.type,e),n);break e}throw Error(a(306,i,""))}return r;case 0:return i=r.type,p=r.pendingProps,p=r.elementType===i?p:We(i,p),Ws(e,r,i,p,n);case 1:return i=r.type,p=r.pendingProps,p=r.elementType===i?p:We(i,p),_l(e,r,i,p,n);case 3:e:{if(ec(r),e===null)throw Error(a(387));i=r.pendingProps,x=r.memoizedState,p=x.element,xa(e,r),dn(r,i,null,n);var R=r.memoizedState;if(i=R.element,x.isDehydrated)if(x={element:i,isDehydrated:!1,cache:R.cache,pendingSuspenseBoundaries:R.pendingSuspenseBoundaries,transitions:R.transitions},r.updateQueue.baseState=x,r.memoizedState=x,r.flags&256){p=Error(a(423)),r=tc(e,r,i,n,p);break e}else if(i!==p){p=Error(a(424)),r=tc(e,r,i,n,p);break e}else for(nr=lr(r.stateNode.containerInfo.firstChild),cr=r,mt=!0,Pr=null,n=gl(r,null,i,n),r.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Ia(),i===p){r=Yr(e,r,n);break e}qt(e,r,i,n)}r=r.child}return r;case 5:return ml(r),e===null&&ws(r),i=r.type,p=r.pendingProps,x=e!==null?e.memoizedProps:null,R=p.children,Ln(i,p)?R=null:x!==null&&Ln(i,x)&&(r.flags|=32),ql(e,r),qt(e,r,R,n),r.child;case 6:return e===null&&ws(r),null;case 13:return nc(e,r,n);case 4:return Cs(r,r.stateNode.containerInfo),i=r.pendingProps,e===null?r.child=Ta(r,null,i,n):qt(e,r,i,n),r.child;case 11:return i=r.type,p=r.pendingProps,p=r.elementType===i?p:We(i,p),Ql(e,r,i,p,n);case 7:return qt(e,r,r.pendingProps,n),r.child;case 8:return qt(e,r,r.pendingProps.children,n),r.child;case 12:return qt(e,r,r.pendingProps.children,n),r.child;case 10:e:{if(i=r.type._context,p=r.pendingProps,x=r.memoizedProps,R=p.value,lt(tt,i._currentValue),i._currentValue=R,x!==null)if(ir(x.value,R)){if(x.children===p.children&&!Ht.current){r=Yr(e,r,n);break e}}else for(x=r.child,x!==null&&(x.return=r);x!==null;){var b=x.dependencies;if(b!==null){R=x.child;for(var Q=b.firstContext;Q!==null;){if(Q.context===i){if(x.tag===1){Q=Cr(-1,n&-n),Q.tag=2;var fe=x.updateQueue;if(fe!==null){fe=fe.shared;var me=fe.pending;me===null?Q.next=Q:(Q.next=me.next,me.next=Q),fe.pending=Q}}x.lanes|=n,Q=x.alternate,Q!==null&&(Q.lanes|=n),Ft(x.return,n,r),b.lanes|=n;break}Q=Q.next}}else if(x.tag===10)R=x.type===r.type?null:x.child;else if(x.tag===18){if(R=x.return,R===null)throw Error(a(341));R.lanes|=n,b=R.alternate,b!==null&&(b.lanes|=n),Ft(R,n,r),R=x.sibling}else R=x.child;if(R!==null)R.return=x;else for(R=x;R!==null;){if(R===r){R=null;break}if(x=R.sibling,x!==null){x.return=R.return,R=x;break}R=R.return}x=R}qt(e,r,p.children,n),r=r.child}return r;case 9:return p=r.type,i=r.pendingProps.children,Kt(r,n),p=Pt(p),i=i(p),r.flags|=1,qt(e,r,i,n),r.child;case 14:return i=r.type,p=We(i,r.pendingProps),p=We(i.type,p),Zl(e,r,i,p,n);case 15:return Jl(e,r,r.type,r.pendingProps,n);case 17:return i=r.type,p=r.pendingProps,p=r.elementType===i?p:We(i,p),e!==null&&(e.alternate=null,r.alternate=null,r.flags|=2),r.tag=1,Vt(i)?(e=!0,G(r)):e=!1,Kt(r,n),Dr(r,i,p),Es(r,i,p,n),Hs(null,r,i,!0,e,n);case 19:return sc(e,r,n);case 22:return Xl(e,r,n)}throw Error(a(156,r.tag))};function Pc(e,r){return Hu(e,r)}function af(e,r,n,i){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=r,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=i,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Tr(e,r,n,i){return new af(e,r,n,i)}function ui(e){return e=e.prototype,!(!e||!e.isReactComponent)}function of(e){if(typeof e=="function")return ui(e)?1:0;if(e!=null){if(e=e.$$typeof,e===ne)return 11;if(e===te)return 14}return 2}function mn(e,r){var n=e.alternate;return n===null?(n=Tr(e.tag,r,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=r,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,r=e.dependencies,n.dependencies=r===null?null:{lanes:r.lanes,firstContext:r.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function wu(e,r,n,i,p,x){var R=2;if(i=e,typeof e=="function")ui(e)&&(R=1);else if(typeof e=="string")R=5;else e:switch(e){case J:return Gn(n.children,p,x,r);case W:R=8,p|=8;break;case Z:return e=Tr(12,n,r,p|2),e.elementType=Z,e.lanes=x,e;case ie:return e=Tr(13,n,r,p),e.elementType=ie,e.lanes=x,e;case se:return e=Tr(19,n,r,p),e.elementType=se,e.lanes=x,e;case N:return Au(n,p,x,r);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case K:R=10;break e;case ee:R=9;break e;case ne:R=11;break e;case te:R=14;break e;case $:R=16,i=null;break e}throw Error(a(130,e==null?e:typeof e,""))}return r=Tr(R,n,r,p),r.elementType=e,r.type=i,r.lanes=x,r}function Gn(e,r,n,i){return e=Tr(7,e,i,r),e.lanes=n,e}function Au(e,r,n,i){return e=Tr(22,e,i,r),e.elementType=N,e.lanes=n,e.stateNode={},e}function si(e,r,n){return e=Tr(6,e,null,r),e.lanes=n,e}function ii(e,r,n){return r=Tr(4,e.children!==null?e.children:[],e.key,r),r.lanes=n,r.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},r}function uf(e,r,n,i,p){this.tag=r,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Mo(0),this.expirationTimes=Mo(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Mo(0),this.identifierPrefix=i,this.onRecoverableError=p,this.mutableSourceEagerHydrationData=null}function li(e,r,n,i,p,x,R,b,Q){return e=new uf(e,r,n,b,Q),r===1?(r=1,x===!0&&(r|=8)):r=0,x=Tr(3,null,null,r),e.current=x,x.stateNode=e,x.memoizedState={element:i,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Vr(x),e}function sf(e,r,n){var i=3(ge[Me]==null&&d(!1),ge[Me])).replace(/\/*\*$/,xe=>ge["*"]==null?"":ge["*"].replace(/^\/*/,"/"))}function g(de,ge,xe){xe===void 0&&(xe="/");let Me=typeof ge=="string"?(0,o.cP)(ge):ge,je=se(Me.pathname||"/",xe);if(je==null)return null;let Je=S(de);E(Je);let ke=null;for(let Ue=0;ke==null&&Ue{let ke={relativePath:je.path||"",caseSensitive:je.caseSensitive===!0,childrenIndex:Je,route:je};ke.relativePath.startsWith("/")&&(ke.relativePath.startsWith(Me)||d(!1),ke.relativePath=ke.relativePath.slice(Me.length));let Ue=te([Me,ke.relativePath]),at=xe.concat(ke);je.children&&je.children.length>0&&(je.index===!0&&d(!1),S(je.children,ge,at,Ue)),!(je.path==null&&!je.index)&&ge.push({path:Ue,score:C(Ue,je.index),routesMeta:at})}),ge}function E(de){de.sort((ge,xe)=>ge.score!==xe.score?xe.score-ge.score:D(ge.routesMeta.map(Me=>Me.childrenIndex),xe.routesMeta.map(Me=>Me.childrenIndex)))}const I=/^:\w+$/,w=3,P=2,A=1,M=10,L=-2,F=de=>de==="*";function C(de,ge){let xe=de.split("/"),Me=xe.length;return xe.some(F)&&(Me+=L),ge&&(Me+=P),xe.filter(je=>!F(je)).reduce((je,Je)=>je+(I.test(Je)?w:Je===""?A:M),Me)}function D(de,ge){return de.length===ge.length&&de.slice(0,-1).every((Me,je)=>Me===ge[je])?de[de.length-1]-ge[ge.length-1]:0}function U(de,ge){let{routesMeta:xe}=de,Me={},je="/",Je=[];for(let ke=0;ke{if(V==="*"){let Ee=Ue[le]||"";ke=Je.slice(0,Je.length-Ee.length).replace(/(.)\/+$/,"$1")}return Ie[V]=Z(Ue[le]||"",V),Ie},{}),pathname:Je,pathnameBase:ke,pattern:de}}function W(de,ge,xe){ge===void 0&&(ge=!1),xe===void 0&&(xe=!0);let Me=[],je="^"+de.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^$?{}|()[\]]/g,"\\$&").replace(/:(\w+)/g,(ke,Ue)=>(Me.push(Ue),"([^\\/]+)"));return de.endsWith("*")?(Me.push("*"),je+=de==="*"||de==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):je+=xe?"\\/*$":"(?:(?=[.~-]|%[0-9A-F]{2})|\\b|\\/|$)",[new RegExp(je,ge?void 0:"i"),Me]}function Z(de,ge){try{return decodeURIComponent(de)}catch(xe){return de}}function K(de,ge){ge===void 0&&(ge="/");let{pathname:xe,search:Me="",hash:je=""}=typeof de=="string"?(0,o.cP)(de):de;return{pathname:xe?xe.startsWith("/")?xe:ee(xe,ge):ge,search:N(Me),hash:j(je)}}function ee(de,ge){let xe=ge.replace(/\/+$/,"").split("/");return de.split("/").forEach(je=>{je===".."?xe.length>1&&xe.pop():je!=="."&&xe.push(je)}),xe.length>1?xe.join("/"):"/"}function ne(de,ge,xe){let Me=typeof de=="string"?(0,o.cP)(de):de,je=de===""||Me.pathname===""?"/":Me.pathname,Je;if(je==null)Je=xe;else{let Ue=ge.length-1;if(je.startsWith("..")){let at=je.split("/");for(;at[0]==="..";)at.shift(),Ue-=1;Me.pathname=at.join("/")}Je=Ue>=0?ge[Ue]:"/"}let ke=K(Me,Je);return je&&je!=="/"&&je.endsWith("/")&&!ke.pathname.endsWith("/")&&(ke.pathname+="/"),ke}function ie(de){return de===""||de.pathname===""?"/":typeof de=="string"?parsePath(de).pathname:de.pathname}function se(de,ge){if(ge==="/")return de;if(!de.toLowerCase().startsWith(ge.toLowerCase()))return null;let xe=de.charAt(ge.length);return xe&&xe!=="/"?null:de.slice(ge.length)||"/"}const te=de=>de.join("/").replace(/\/\/+/g,"/"),$=de=>de.replace(/\/+$/,"").replace(/^\/*/,"/"),N=de=>!de||de==="?"?"":de.startsWith("?")?de:"?"+de,j=de=>!de||de==="#"?"":de.startsWith("#")?de:"#"+de;function O(de){T()||d(!1);let{basename:ge,navigator:xe}=useContext(a),{hash:Me,pathname:je,search:Je}=Ce(de),ke=je;if(ge!=="/"){let Ue=ie(de),at=Ue!=null&&Ue.endsWith("/");ke=je==="/"?ge+(at?"/":""):te([ge,je])}return xe.createHref({pathname:ke,search:Je,hash:Me})}function T(){return(0,u.useContext)(s)!=null}function Y(){return T()||d(!1),(0,u.useContext)(s).location}function oe(){return useContext(s).navigationType}function k(de){T()||d(!1);let{pathname:ge}=Y();return useMemo(()=>J(de,ge),[ge,de])}function z(){T()||d(!1);let{basename:de,navigator:ge}=(0,u.useContext)(a),{matches:xe}=(0,u.useContext)(l),{pathname:Me}=Y(),je=JSON.stringify(xe.map(Ue=>Ue.pathnameBase)),Je=(0,u.useRef)(!1);return(0,u.useEffect)(()=>{Je.current=!0}),(0,u.useCallback)(function(Ue,at){if(at===void 0&&(at={}),!Je.current)return;if(typeof Ue=="number"){ge.go(Ue);return}let Ie=ne(Ue,JSON.parse(je),Me);de!=="/"&&(Ie.pathname=te([de,Ie.pathname])),(at.replace?ge.replace:ge.push)(Ie,at.state)},[de,ge,je,Me])}const H=(0,u.createContext)(null);function re(){return useContext(H)}function ve(de){let ge=(0,u.useContext)(l).outlet;return ge&&(0,u.createElement)(H.Provider,{value:de},ge)}function pe(){let{matches:de}=(0,u.useContext)(l),ge=de[de.length-1];return ge?ge.params:{}}function Ce(de){let{matches:ge}=useContext(l),{pathname:xe}=Y(),Me=JSON.stringify(ge.map(je=>je.pathnameBase));return useMemo(()=>ne(de,JSON.parse(Me),xe),[de,Me,xe])}function Le(de,ge){T()||d(!1);let{matches:xe}=(0,u.useContext)(l),Me=xe[xe.length-1],je=Me?Me.params:{},Je=Me?Me.pathname:"/",ke=Me?Me.pathnameBase:"/",Ue=Me&&Me.route,at=Y(),Ie;if(ge){var V;let Re=typeof ge=="string"?(0,o.cP)(ge):ge;ke==="/"||(V=Re.pathname)!=null&&V.startsWith(ke)||d(!1),Ie=Re}else Ie=at;let le=Ie.pathname||"/",Ee=ke==="/"?le:le.slice(ke.length)||"/",Pe=g(de,{pathname:Ee});return qe(Pe&&Pe.map(Re=>Object.assign({},Re,{params:Object.assign({},je,Re.params),pathname:te([ke,Re.pathname]),pathnameBase:Re.pathnameBase==="/"?ke:te([ke,Re.pathnameBase])})),xe)}function qe(de,ge){return ge===void 0&&(ge=[]),de==null?null:de.reduceRight((xe,Me,je)=>(0,u.createElement)(l.Provider,{children:Me.route.element!==void 0?Me.route.element:xe,value:{outlet:xe,matches:ge.concat(de.slice(0,je+1))}}),null)}function $e(de){let{basename:ge,children:xe,initialEntries:Me,initialIndex:je}=de,Je=useRef();Je.current==null&&(Je.current=createMemoryHistory({initialEntries:Me,initialIndex:je}));let ke=Je.current,[Ue,at]=useState({action:ke.action,location:ke.location});return useLayoutEffect(()=>ke.listen(at),[ke]),createElement(ct,{basename:ge,children:xe,location:Ue.location,navigationType:Ue.action,navigator:ke})}function Ye(de){let{to:ge,replace:xe,state:Me}=de;T()||d(!1);let je=z();return(0,u.useEffect)(()=>{je(ge,{replace:xe,state:Me})}),null}function xt(de){return ve(de.context)}function Ct(de){d(!1)}function ct(de){let{basename:ge="/",children:xe=null,location:Me,navigationType:je=o.aU.Pop,navigator:Je,static:ke=!1}=de;T()&&d(!1);let Ue=$(ge),at=(0,u.useMemo)(()=>({basename:Ue,navigator:Je,static:ke}),[Ue,Je,ke]);typeof Me=="string"&&(Me=(0,o.cP)(Me));let{pathname:Ie="/",search:V="",hash:le="",state:Ee=null,key:Pe="default"}=Me,Re=(0,u.useMemo)(()=>{let we=se(Ie,Ue);return we==null?null:{pathname:we,search:V,hash:le,state:Ee,key:Pe}},[Ue,Ie,V,le,Ee,Pe]);return Re==null?null:(0,u.createElement)(a.Provider,{value:at},(0,u.createElement)(s.Provider,{children:xe,value:{location:Re,navigationType:je}}))}function Nt(de){let{children:ge,location:xe}=de;return Le(Jt(ge),xe)}function Jt(de){let ge=[];return Children.forEach(de,xe=>{if(!isValidElement(xe))return;if(xe.type===Fragment){ge.push.apply(ge,Jt(xe.props.children));return}xe.type!==Ct&&d(!1);let Me={caseSensitive:xe.props.caseSensitive,element:xe.props.element,index:xe.props.index,path:xe.props.path};xe.props.children&&(Me.children=Jt(xe.props.children)),ge.push(Me)}),ge}function Xt(de){return qe(de)}},56392:function(c,h){"use strict";var t=Symbol.for("react.element"),o=Symbol.for("react.portal"),u=Symbol.for("react.fragment"),a=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),l=Symbol.for("react.provider"),d=Symbol.for("react.context"),f=Symbol.for("react.forward_ref"),v=Symbol.for("react.suspense"),y=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),g=Symbol.iterator;function S(O){return O===null||typeof O!="object"?null:(O=g&&O[g]||O["@@iterator"],typeof O=="function"?O:null)}var E={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},I=Object.assign,w={};function P(O,T,Y){this.props=O,this.context=T,this.refs=w,this.updater=Y||E}P.prototype.isReactComponent={},P.prototype.setState=function(O,T){if(typeof O!="object"&&typeof O!="function"&&O!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,O,T,"setState")},P.prototype.forceUpdate=function(O){this.updater.enqueueForceUpdate(this,O,"forceUpdate")};function A(){}A.prototype=P.prototype;function M(O,T,Y){this.props=O,this.context=T,this.refs=w,this.updater=Y||E}var L=M.prototype=new A;L.constructor=M,I(L,P.prototype),L.isPureReactComponent=!0;var F=Array.isArray,C=Object.prototype.hasOwnProperty,D={current:null},U={key:!0,ref:!0,__self:!0,__source:!0};function J(O,T,Y){var oe,k={},z=null,H=null;if(T!=null)for(oe in T.ref!==void 0&&(H=T.ref),T.key!==void 0&&(z=""+T.key),T)C.call(T,oe)&&!U.hasOwnProperty(oe)&&(k[oe]=T[oe]);var re=arguments.length-2;if(re===1)k.children=Y;else if(1=0;--O){var T=this.tryEntries[O],Y=T.completion;if(T.tryLoc==="root")return j("end");if(T.tryLoc<=this.prev){var oe=u.call(T,"catchLoc"),k=u.call(T,"finallyLoc");if(oe&&k){if(this.prev=0;--j){var O=this.tryEntries[j];if(O.tryLoc<=this.prev&&u.call(O,"finallyLoc")&&this.prev=0;--N){var j=this.tryEntries[N];if(j.finallyLoc===$)return this.complete(j.completion,j.afterLoc),ne(j),P}},catch:function($){for(var N=this.tryEntries.length-1;N>=0;--N){var j=this.tryEntries[N];if(j.tryLoc===$){var O=j.completion;if(O.type==="throw"){var T=O.arg;ne(j)}return T}}throw new Error("illegal catch attempt")},delegateYield:function($,N,j){return this.delegate={iterator:se($),resultName:N,nextLoc:j},this.method==="next"&&(this.arg=s),P}},t}(c.exports);try{regeneratorRuntime=h}catch(t){typeof globalThis=="object"?globalThis.regeneratorRuntime=h:Function("r","regeneratorRuntime = r")(h)}},6466:function(c,h){"use strict";function t($,N){var j=$.length;$.push(N);e:for(;0>>1,T=$[O];if(0>>1;Oa(k,j))za(H,k)?($[O]=H,$[z]=j,O=z):($[O]=k,$[oe]=j,O=oe);else if(za(H,j))$[O]=H,$[z]=j,O=z;else break e}}return N}function a($,N){var j=$.sortIndex-N.sortIndex;return j!==0?j:$.id-N.id}if(typeof performance=="object"&&typeof performance.now=="function"){var s=performance;h.unstable_now=function(){return s.now()}}else{var l=Date,d=l.now();h.unstable_now=function(){return l.now()-d}}var f=[],v=[],y=1,m=null,g=3,S=!1,E=!1,I=!1,w=typeof setTimeout=="function"?setTimeout:null,P=typeof clearTimeout=="function"?clearTimeout:null,A=typeof setImmediate!="undefined"?setImmediate:null;typeof navigator!="undefined"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function M($){for(var N=o(v);N!==null;){if(N.callback===null)u(v);else if(N.startTime<=$)u(v),N.sortIndex=N.expirationTime,t(f,N);else break;N=o(v)}}function L($){if(I=!1,M($),!E)if(o(f)!==null)E=!0,se(F);else{var N=o(v);N!==null&&te(L,N.startTime-$)}}function F($,N){E=!1,I&&(I=!1,P(U),U=-1),S=!0;var j=g;try{for(M(N),m=o(f);m!==null&&(!(m.expirationTime>N)||$&&!Z());){var O=m.callback;if(typeof O=="function"){m.callback=null,g=m.priorityLevel;var T=O(m.expirationTime<=N);N=h.unstable_now(),typeof T=="function"?m.callback=T:m===o(f)&&u(f),M(N)}else u(f);m=o(f)}if(m!==null)var Y=!0;else{var oe=o(v);oe!==null&&te(L,oe.startTime-N),Y=!1}return Y}finally{m=null,g=j,S=!1}}var C=!1,D=null,U=-1,J=5,W=-1;function Z(){return!(h.unstable_now()-W$||125<$?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):J=0<$?Math.floor(1e3/$):5},h.unstable_getCurrentPriorityLevel=function(){return g},h.unstable_getFirstCallbackNode=function(){return o(f)},h.unstable_next=function($){switch(g){case 1:case 2:case 3:var N=3;break;default:N=g}var j=g;g=N;try{return $()}finally{g=j}},h.unstable_pauseExecution=function(){},h.unstable_requestPaint=function(){},h.unstable_runWithPriority=function($,N){switch($){case 1:case 2:case 3:case 4:case 5:break;default:$=3}var j=g;g=$;try{return N()}finally{g=j}},h.unstable_scheduleCallback=function($,N,j){var O=h.unstable_now();switch(typeof j=="object"&&j!==null?(j=j.delay,j=typeof j=="number"&&0O?($.sortIndex=j,t(v,$),o(f)===null&&$===o(v)&&(I?(P(U),U=-1):I=!0,te(L,j-O))):($.sortIndex=T,t(f,$),E||S||(E=!0,se(F))),$},h.unstable_shouldYield=Z,h.unstable_wrapCallback=function($){var N=g;return function(){var j=g;g=N;try{return $.apply(this,arguments)}finally{g=j}}}},79727:function(c,h,t){"use strict";c.exports=t(6466)},19747:function(c){c.exports=function(t,o,u,a){var s=u?u.call(a,t,o):void 0;if(s!==void 0)return!!s;if(t===o)return!0;if(typeof t!="object"||!t||typeof o!="object"||!o)return!1;var l=Object.keys(t),d=Object.keys(o);if(l.length!==d.length)return!1;for(var f=Object.prototype.hasOwnProperty.bind(o),v=0;v=0;--oe){var k=this.tryEntries[oe],z=k.completion;if(k.tryLoc==="root")return Y("end");if(k.tryLoc<=this.prev){var H=d.call(k,"catchLoc"),re=d.call(k,"finallyLoc");if(H&&re){if(this.prev=0;--Y){var oe=this.tryEntries[Y];if(oe.tryLoc<=this.prev&&d.call(oe,"finallyLoc")&&this.prev=0;--T){var Y=this.tryEntries[T];if(Y.finallyLoc===O)return this.complete(Y.completion,Y.afterLoc),te(Y),L}},catch:function(O){for(var T=this.tryEntries.length-1;T>=0;--T){var Y=this.tryEntries[T];if(Y.tryLoc===O){var oe=Y.completion;if(oe.type==="throw"){var k=oe.arg;te(Y)}return k}}throw new Error("illegal catch attempt")},delegateYield:function(O,T,Y){return this.delegate={iterator:N(O),resultName:T,nextLoc:Y},this.method==="next"&&(this.arg=a),L}},s}c.exports=u,c.exports.__esModule=!0,c.exports.default=c.exports},41819:function(c,h,t){var o=t(31468).default;function u(a,s){if(o(a)!="object"||!a)return a;var l=a[Symbol.toPrimitive];if(l!==void 0){var d=l.call(a,s||"default");if(o(d)!="object")return d;throw new TypeError("@@toPrimitive must return a primitive value.")}return(s==="string"?String:Number)(a)}c.exports=u,c.exports.__esModule=!0,c.exports.default=c.exports},83411:function(c,h,t){var o=t(31468).default,u=t(41819);function a(s){var l=u(s,"string");return o(l)=="symbol"?l:String(l)}c.exports=a,c.exports.__esModule=!0,c.exports.default=c.exports},31468:function(c){function h(t){"@babel/helpers - typeof";return c.exports=h=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(o){return typeof o}:function(o){return o&&typeof Symbol=="function"&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o},c.exports.__esModule=!0,c.exports.default=c.exports,h(t)}c.exports=h,c.exports.__esModule=!0,c.exports.default=c.exports},63335:function(c,h,t){"use strict";var o=t(55327),u=t(40593),a=TypeError;c.exports=function(s){if(o(s))return s;throw new a(u(s)+" is not a function")}},6086:function(c,h,t){"use strict";var o=t(39812),u=t(40593),a=TypeError;c.exports=function(s){if(o(s))return s;throw new a(u(s)+" is not a constructor")}},42683:function(c,h,t){"use strict";var o=t(2786).has;c.exports=function(u){return o(u),u}},557:function(c,h,t){"use strict";var o=t(55327),u=String,a=TypeError;c.exports=function(s){if(typeof s=="object"||o(s))return s;throw new a("Can't set "+u(s)+" as a prototype")}},17442:function(c,h,t){"use strict";var o=t(19691).has;c.exports=function(u){return o(u),u}},79606:function(c){"use strict";var h=TypeError;c.exports=function(t){if(typeof t=="string")return t;throw new h("Argument is not a string")}},63619:function(c,h,t){"use strict";var o=t(42530).has;c.exports=function(u){return o(u),u}},18888:function(c,h,t){"use strict";var o=t(91385).has;c.exports=function(u){return o(u),u}},5978:function(c,h,t){"use strict";var o=t(89945),u=t(94237),a=t(80666),s=t(80449),l=t(63335),d=t(4112),f=t(53776),v=t(59893),y=v("asyncDispose"),m=v("dispose"),g=u([].push),S=function(I,w){if(w==="async-dispose"){var P=f(I,y);return P!==void 0?P:(P=f(I,m),function(){o(P,this)})}return f(I,m)},E=function(I,w,P){return arguments.length<3&&!d(I)&&(P=l(S(s(I),w))),P===void 0?function(){}:a(P,I)};c.exports=function(I,w,P,A){var M;if(arguments.length<4){if(d(w)&&P==="sync-dispose")return;M=E(w,P)}else M=E(void 0,P,A);g(I.stack,M)}},81181:function(c,h,t){"use strict";var o=t(59893),u=t(20132),a=t(37691).f,s=o("unscopables"),l=Array.prototype;l[s]===void 0&&a(l,s,{configurable:!0,value:u(null)}),c.exports=function(d){l[s][d]=!0}},56472:function(c,h,t){"use strict";var o=t(16332),u=TypeError;c.exports=function(a,s){if(o(s,a))return a;throw new u("Incorrect invocation")}},1674:function(c,h,t){"use strict";var o=t(31946),u=String,a=TypeError;c.exports=function(s){if(s===void 0||o(s))return s;throw new a(u(s)+" is not an object or undefined")}},80449:function(c,h,t){"use strict";var o=t(31946),u=String,a=TypeError;c.exports=function(s){if(o(s))return s;throw new a(u(s)+" is not an object")}},27270:function(c,h,t){"use strict";var o=t(97607),u=TypeError;c.exports=function(a){if(o(a)==="Uint8Array")return a;throw new u("Argument is not an Uint8Array")}},3737:function(c){"use strict";c.exports=typeof ArrayBuffer!="undefined"&&typeof DataView!="undefined"},78244:function(c,h,t){"use strict";var o=t(37758),u=t(29076),a=TypeError;c.exports=o(ArrayBuffer.prototype,"byteLength","get")||function(s){if(u(s)!=="ArrayBuffer")throw new a("ArrayBuffer expected");return s.byteLength}},93683:function(c,h,t){"use strict";var o=t(94237),u=t(78244),a=o(ArrayBuffer.prototype.slice);c.exports=function(s){if(u(s)!==0)return!1;try{return a(s,0,0),!1}catch(l){return!0}}},51424:function(c,h,t){"use strict";var o=t(3338);c.exports=o(function(){if(typeof ArrayBuffer=="function"){var u=new ArrayBuffer(8);Object.isExtensible(u)&&Object.defineProperty(u,"a",{value:8})}})},39760:function(c,h,t){"use strict";var o=t(92916),u=t(94237),a=t(37758),s=t(24225),l=t(93683),d=t(78244),f=t(39311),v=t(80426),y=o.structuredClone,m=o.ArrayBuffer,g=o.DataView,S=o.TypeError,E=Math.min,I=m.prototype,w=g.prototype,P=u(I.slice),A=a(I,"resizable","get"),M=a(I,"maxByteLength","get"),L=u(w.getInt8),F=u(w.setInt8);c.exports=(v||f)&&function(C,D,U){var J=d(C),W=D===void 0?J:s(D),Z=!A||!A(C),K;if(l(C))throw new S("ArrayBuffer is detached");if(v&&(C=y(C,{transfer:[C]}),J===W&&(U||Z)))return C;if(J>=W&&(!U||Z))K=P(C,0,W);else{var ee=U&&!Z&&M?{maxByteLength:M(C)}:void 0;K=new m(W,ee);for(var ne=new g(C),ie=new g(K),se=E(W,J),te=0;te1?arguments[1]:void 0,W=U>2?arguments[2]:void 0;return new(m("Promise"))(function(Z){var K=a(C);J!==void 0&&(J=o(J,W));var ee=y(K,w),ne=ee?void 0:v(K)||M,ie=s(D)?new D:[],se=ee?l(K,ee):new E(f(d(K,ne)));Z(I(se,J,ie))})}},69478:function(c,h,t){"use strict";var o=t(82762);c.exports=function(u,a,s){for(var l=0,d=arguments.length>2?s:o(a),f=new u(d);d>l;)f[l]=a[l++];return f}},33940:function(c,h,t){"use strict";var o=t(80666),u=t(94237),a=t(1835),s=t(94029),l=t(82762),d=t(2786),f=d.Map,v=d.get,y=d.has,m=d.set,g=u([].push);c.exports=function(E){for(var I=s(this),w=a(I),P=o(E,arguments.length>1?arguments[1]:void 0),A=new f,M=l(w),L=0,F,C;M>L;L++)C=w[L],F=P(C,L,I),y(A,F)?g(v(A,F),C):m(A,F,[C]);return A}},36444:function(c,h,t){"use strict";var o=t(80666),u=t(94237),a=t(1835),s=t(94029),l=t(17818),d=t(82762),f=t(20132),v=t(69478),y=Array,m=u([].push);c.exports=function(g,S,E,I){for(var w=s(g),P=a(w),A=o(S,E),M=f(null),L=d(P),F=0,C,D,U;L>F;F++)U=P[F],D=l(A(U,F,w)),D in M?m(M[D],U):M[D]=[U];if(I&&(C=I(w),C!==y))for(D in M)M[D]=v(C,M[D]);return M}},22999:function(c,h,t){"use strict";var o=t(80524),u=t(51981),a=t(82762),s=function(l){return function(d,f,v){var y=o(d),m=a(y),g=u(v,m),S;if(l&&f!==f){for(;m>g;)if(S=y[g++],S!==S)return!0}else for(;m>g;g++)if((l||g in y)&&y[g]===f)return l||g||0;return!l&&-1}};c.exports={includes:s(!0),indexOf:s(!1)}},53279:function(c,h,t){"use strict";var o=t(80666),u=t(1835),a=t(94029),s=t(82762),l=function(d){var f=d===1;return function(v,y,m){for(var g=a(v),S=u(g),E=s(S),I=o(y,m),w,P;E-- >0;)if(w=S[E],P=I(w,E,g),P)switch(d){case 0:return w;case 1:return E}return f?-1:void 0}};c.exports={findLast:l(0),findLastIndex:l(1)}},90560:function(c,h,t){"use strict";var o=t(80666),u=t(94237),a=t(1835),s=t(94029),l=t(82762),d=t(81427),f=u([].push),v=function(y){var m=y===1,g=y===2,S=y===3,E=y===4,I=y===6,w=y===7,P=y===5||I;return function(A,M,L,F){for(var C=s(A),D=a(C),U=l(D),J=o(M,L),W=0,Z=F||d,K=m?Z(A,U):g||w?Z(A,0):void 0,ee,ne;U>W;W++)if((P||W in D)&&(ee=D[W],ne=J(ee,W,C),y))if(m)K[W]=ne;else if(ne)switch(y){case 3:return!0;case 5:return ee;case 6:return W;case 2:f(K,ee)}else switch(y){case 4:return!1;case 7:f(K,ee)}return I?-1:S||E?E:K}};c.exports={forEach:v(0),map:v(1),filter:v(2),some:v(3),every:v(4),find:v(5),findIndex:v(6),filterReject:v(7)}},45601:function(c,h,t){"use strict";var o=t(3338);c.exports=function(u,a){var s=[][u];return!!s&&o(function(){s.call(null,a||function(){return 1},1)})}},16370:function(c,h,t){"use strict";var o=t(63335),u=t(94029),a=t(1835),s=t(82762),l=TypeError,d=function(f){return function(v,y,m,g){var S=u(v),E=a(S),I=s(S);o(y);var w=f?I-1:0,P=f?-1:1;if(m<2)for(;;){if(w in E){g=E[w],w+=P;break}if(w+=P,f?w<0:I<=w)throw new l("Reduce of empty array with no initial value")}for(;f?w>=0:I>w;w+=P)w in E&&(g=y(g,E[w],w,S));return g}};c.exports={left:d(!1),right:d(!0)}},39428:function(c,h,t){"use strict";var o=t(35454),u=t(18589),a=TypeError,s=Object.getOwnPropertyDescriptor,l=o&&!function(){if(this!==void 0)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(d){return d instanceof TypeError}}();c.exports=l?function(d,f){if(u(d)&&!s(d,"length").writable)throw new a("Cannot set read only .length");return d.length=f}:function(d,f){return d.length=f}},71698:function(c,h,t){"use strict";var o=t(51981),u=t(82762),a=t(69392),s=Array,l=Math.max;c.exports=function(d,f,v){for(var y=u(d),m=o(f,y),g=o(v===void 0?y:v,y),S=s(l(g-m,0)),E=0;m=v||m<0)throw new a("Incorrect index");for(var g=new l(v),S=0;S1?arguments[1]:void 0,S,E,I,w;return s(this),S=g!==void 0,S&&a(g),l(y)?new this:(E=[],S?(I=0,w=o(g,m>2?arguments[2]:void 0),d(y,function(P){u(f,E,w(P,I++))})):d(y,f,{that:E}),new this(E))}},48800:function(c,h,t){"use strict";var o=t(30867);c.exports=function(){return new this(o(arguments))}},40942:function(c,h,t){"use strict";var o=t(20132),u=t(64110),a=t(66477),s=t(80666),l=t(56472),d=t(4112),f=t(62003),v=t(24019),y=t(25587),m=t(51996),g=t(35454),S=t(2074).fastKey,E=t(94844),I=E.set,w=E.getterFor;c.exports={getConstructor:function(P,A,M,L){var F=P(function(W,Z){l(W,C),I(W,{type:A,index:o(null),first:void 0,last:void 0,size:0}),g||(W.size=0),d(Z)||f(Z,W[L],{that:W,AS_ENTRIES:M})}),C=F.prototype,D=w(A),U=function(W,Z,K){var ee=D(W),ne=J(W,Z),ie,se;return ne?ne.value=K:(ee.last=ne={index:se=S(Z,!0),key:Z,value:K,previous:ie=ee.last,next:void 0,removed:!1},ee.first||(ee.first=ne),ie&&(ie.next=ne),g?ee.size++:W.size++,se!=="F"&&(ee.index[se]=ne)),W},J=function(W,Z){var K=D(W),ee=S(Z),ne;if(ee!=="F")return K.index[ee];for(ne=K.first;ne;ne=ne.next)if(ne.key===Z)return ne};return a(C,{clear:function(){for(var Z=this,K=D(Z),ee=K.index,ne=K.first;ne;)ne.removed=!0,ne.previous&&(ne.previous=ne.previous.next=void 0),delete ee[ne.index],ne=ne.next;K.first=K.last=void 0,g?K.size=0:Z.size=0},delete:function(W){var Z=this,K=D(Z),ee=J(Z,W);if(ee){var ne=ee.next,ie=ee.previous;delete K.index[ee.index],ee.removed=!0,ie&&(ie.next=ne),ne&&(ne.previous=ie),K.first===ee&&(K.first=ne),K.last===ee&&(K.last=ie),g?K.size--:Z.size--}return!!ee},forEach:function(Z){for(var K=D(this),ee=s(Z,arguments.length>1?arguments[1]:void 0),ne;ne=ne?ne.next:K.first;)for(ee(ne.value,ne.key,this);ne&&ne.removed;)ne=ne.previous},has:function(Z){return!!J(this,Z)}}),a(C,M?{get:function(Z){var K=J(this,Z);return K&&K.value},set:function(Z,K){return U(this,Z===0?0:Z,K)}}:{add:function(Z){return U(this,Z=Z===0?0:Z,Z)}}),g&&u(C,"size",{configurable:!0,get:function(){return D(this).size}}),F},setStrong:function(P,A,M){var L=A+" Iterator",F=w(A),C=w(L);v(P,A,function(D,U){I(this,{type:L,target:D,state:F(D),kind:U,last:void 0})},function(){for(var D=C(this),U=D.kind,J=D.last;J&&J.removed;)J=J.previous;return!D.target||!(D.last=J=J?J.next:D.state.first)?(D.target=void 0,y(void 0,!0)):y(U==="keys"?J.key:U==="values"?J.value:[J.key,J.value],!1)},M?"entries":"values",!M,!0),m(A)}}},39656:function(c,h,t){"use strict";var o=t(94237),u=t(66477),a=t(2074).getWeakData,s=t(56472),l=t(80449),d=t(4112),f=t(31946),v=t(62003),y=t(90560),m=t(32621),g=t(94844),S=g.set,E=g.getterFor,I=y.find,w=y.findIndex,P=o([].splice),A=0,M=function(C){return C.frozen||(C.frozen=new L)},L=function(){this.entries=[]},F=function(C,D){return I(C.entries,function(U){return U[0]===D})};L.prototype={get:function(C){var D=F(this,C);if(D)return D[1]},has:function(C){return!!F(this,C)},set:function(C,D){var U=F(this,C);U?U[1]=D:this.entries.push([C,D])},delete:function(C){var D=w(this.entries,function(U){return U[0]===C});return~D&&P(this.entries,D,1),!!~D}},c.exports={getConstructor:function(C,D,U,J){var W=C(function(ne,ie){s(ne,Z),S(ne,{type:D,id:A++,frozen:void 0}),d(ie)||v(ie,ne[J],{that:ne,AS_ENTRIES:U})}),Z=W.prototype,K=E(D),ee=function(ne,ie,se){var te=K(ne),$=a(l(ie),!0);return $===!0?M(te).set(ie,se):$[te.id]=se,ne};return u(Z,{delete:function(ne){var ie=K(this);if(!f(ne))return!1;var se=a(ne);return se===!0?M(ie).delete(ne):se&&m(se,ie.id)&&delete se[ie.id]},has:function(ie){var se=K(this);if(!f(ie))return!1;var te=a(ie);return te===!0?M(se).has(ie):te&&m(te,se.id)}}),u(Z,U?{get:function(ie){var se=K(this);if(f(ie)){var te=a(ie);return te===!0?M(se).get(ie):te?te[se.id]:void 0}},set:function(ie,se){return ee(this,ie,se)}}:{add:function(ie){return ee(this,ie,!0)}}),W}}},48059:function(c,h,t){"use strict";var o=t(94488),u=t(92916),a=t(94237),s=t(20865),l=t(2291),d=t(2074),f=t(62003),v=t(56472),y=t(55327),m=t(4112),g=t(31946),S=t(3338),E=t(35221),I=t(94573),w=t(25576);c.exports=function(P,A,M){var L=P.indexOf("Map")!==-1,F=P.indexOf("Weak")!==-1,C=L?"set":"add",D=u[P],U=D&&D.prototype,J=D,W={},Z=function($){var N=a(U[$]);l(U,$,$==="add"?function(O){return N(this,O===0?0:O),this}:$==="delete"?function(j){return F&&!g(j)?!1:N(this,j===0?0:j)}:$==="get"?function(O){return F&&!g(O)?void 0:N(this,O===0?0:O)}:$==="has"?function(O){return F&&!g(O)?!1:N(this,O===0?0:O)}:function(O,T){return N(this,O===0?0:O,T),this})},K=s(P,!y(D)||!(F||U.forEach&&!S(function(){new D().entries().next()})));if(K)J=M.getConstructor(A,P,L,C),d.enable();else if(s(P,!0)){var ee=new J,ne=ee[C](F?{}:-0,1)!==ee,ie=S(function(){ee.has(1)}),se=E(function($){new D($)}),te=!F&&S(function(){for(var $=new D,N=5;N--;)$[C](N,N);return!$.has(-0)});se||(J=A(function($,N){v($,U);var j=w(new D,$,J);return m(N)||f(N,j[C],{that:j,AS_ENTRIES:L}),j}),J.prototype=U,U.constructor=J),(ie||te)&&(Z("delete"),Z("has"),L&&Z("get")),(te||ne)&&Z(C),F&&U.clear&&delete U.clear}return W[P]=J,o({global:!0,constructor:!0,forced:J!==D},W),I(J,P),F||M.setStrong(J,P,L),J}},32754:function(c,h,t){"use strict";t(34941),t(55410);var o=t(65911),u=t(20132),a=t(31946),s=Object,l=TypeError,d=o("Map"),f=o("WeakMap"),v=function(){this.object=null,this.symbol=null,this.primitives=null,this.objectsByIndex=u(null)};v.prototype.get=function(m,g){return this[m]||(this[m]=g())},v.prototype.next=function(m,g,S){var E=S?this.objectsByIndex[m]||(this.objectsByIndex[m]=new f):this.primitives||(this.primitives=new d),I=E.get(g);return I||E.set(g,I=new v),I};var y=new v;c.exports=function(){var m=y,g=arguments.length,S,E;for(S=0;St)throw h("Maximum allowed index exceeded");return o}},52109:function(c){"use strict";c.exports={IndexSizeError:{s:"INDEX_SIZE_ERR",c:1,m:1},DOMStringSizeError:{s:"DOMSTRING_SIZE_ERR",c:2,m:0},HierarchyRequestError:{s:"HIERARCHY_REQUEST_ERR",c:3,m:1},WrongDocumentError:{s:"WRONG_DOCUMENT_ERR",c:4,m:1},InvalidCharacterError:{s:"INVALID_CHARACTER_ERR",c:5,m:1},NoDataAllowedError:{s:"NO_DATA_ALLOWED_ERR",c:6,m:0},NoModificationAllowedError:{s:"NO_MODIFICATION_ALLOWED_ERR",c:7,m:1},NotFoundError:{s:"NOT_FOUND_ERR",c:8,m:1},NotSupportedError:{s:"NOT_SUPPORTED_ERR",c:9,m:1},InUseAttributeError:{s:"INUSE_ATTRIBUTE_ERR",c:10,m:1},InvalidStateError:{s:"INVALID_STATE_ERR",c:11,m:1},SyntaxError:{s:"SYNTAX_ERR",c:12,m:1},InvalidModificationError:{s:"INVALID_MODIFICATION_ERR",c:13,m:1},NamespaceError:{s:"NAMESPACE_ERR",c:14,m:1},InvalidAccessError:{s:"INVALID_ACCESS_ERR",c:15,m:1},ValidationError:{s:"VALIDATION_ERR",c:16,m:0},TypeMismatchError:{s:"TYPE_MISMATCH_ERR",c:17,m:1},SecurityError:{s:"SECURITY_ERR",c:18,m:1},NetworkError:{s:"NETWORK_ERR",c:19,m:1},AbortError:{s:"ABORT_ERR",c:20,m:1},URLMismatchError:{s:"URL_MISMATCH_ERR",c:21,m:1},QuotaExceededError:{s:"QUOTA_EXCEEDED_ERR",c:22,m:1},TimeoutError:{s:"TIMEOUT_ERR",c:23,m:1},InvalidNodeTypeError:{s:"INVALID_NODE_TYPE_ERR",c:24,m:1},DataCloneError:{s:"DATA_CLONE_ERR",c:25,m:1}}},66994:function(c,h,t){"use strict";var o=t(91821),u=t(90946);c.exports=!o&&!u&&typeof window=="object"&&typeof document=="object"},90843:function(c){"use strict";c.exports=typeof Bun=="function"&&Bun&&typeof Bun.version=="string"},91821:function(c){"use strict";c.exports=typeof Deno=="object"&&Deno&&typeof Deno.version=="object"},70695:function(c,h,t){"use strict";var o=t(66011);c.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(o)},90946:function(c,h,t){"use strict";var o=t(92916),u=t(29076);c.exports=u(o.process)==="process"},66011:function(c){"use strict";c.exports=typeof navigator!="undefined"&&String(navigator.userAgent)||""},46573:function(c,h,t){"use strict";var o=t(92916),u=t(66011),a=o.process,s=o.Deno,l=a&&a.versions||s&&s.version,d=l&&l.v8,f,v;d&&(f=d.split("."),v=f[0]>0&&f[0]<4?1:+(f[0]+f[1])),!v&&u&&(f=u.match(/Edge\/(\d+)/),(!f||f[1]>=74)&&(f=u.match(/Chrome\/(\d+)/),f&&(v=+f[1]))),c.exports=v},46678:function(c){"use strict";c.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},80739:function(c,h,t){"use strict";var o=t(94237),u=Error,a=o("".replace),s=function(f){return String(new u(f).stack)}("zxcasd"),l=/\n\s*at [^:]*:[^\n]*/,d=l.test(s);c.exports=function(f,v){if(d&&typeof f=="string"&&!u.prepareStackTrace)for(;v--;)f=a(f,l,"");return f}},61888:function(c,h,t){"use strict";var o=t(68151),u=t(80739),a=t(25406),s=Error.captureStackTrace;c.exports=function(l,d,f,v){a&&(s?s(l,d):o(l,"stack",u(f,v)))}},25406:function(c,h,t){"use strict";var o=t(3338),u=t(35012);c.exports=!o(function(){var a=new Error("a");return"stack"in a?(Object.defineProperty(a,"stack",u(1,7)),a.stack!==7):!0})},94488:function(c,h,t){"use strict";var o=t(92916),u=t(71256).f,a=t(68151),s=t(2291),l=t(29539),d=t(24538),f=t(20865);c.exports=function(v,y){var m=v.target,g=v.global,S=v.stat,E,I,w,P,A,M;if(g?I=o:S?I=o[m]||l(m,{}):I=(o[m]||{}).prototype,I)for(w in y){if(A=y[w],v.dontCallGetSet?(M=u(I,w),P=M&&M.value):P=I[w],E=f(g?w:m+(S?".":"#")+w,v.forced),!E&&P!==void 0){if(typeof A==typeof P)continue;d(A,P)}(v.sham||P&&P.sham)&&a(A,"sham",!0),s(I,w,A,v)}}},3338:function(c){"use strict";c.exports=function(h){try{return!!h()}catch(t){return!0}}},13247:function(c,h,t){"use strict";var o=t(3338);c.exports=!o(function(){return Object.isExtensible(Object.preventExtensions({}))})},13743:function(c,h,t){"use strict";var o=t(40486),u=Function.prototype,a=u.apply,s=u.call;c.exports=typeof Reflect=="object"&&Reflect.apply||(o?s.bind(a):function(){return s.apply(a,arguments)})},80666:function(c,h,t){"use strict";var o=t(34114),u=t(63335),a=t(40486),s=o(o.bind);c.exports=function(l,d){return u(l),d===void 0?l:a?s(l,d):function(){return l.apply(d,arguments)}}},40486:function(c,h,t){"use strict";var o=t(3338);c.exports=!o(function(){var u=function(){}.bind();return typeof u!="function"||u.hasOwnProperty("prototype")})},89945:function(c,h,t){"use strict";var o=t(40486),u=Function.prototype.call;c.exports=o?u.bind(u):function(){return u.apply(u,arguments)}},47739:function(c,h,t){"use strict";var o=t(94237),u=t(63335);c.exports=function(){return o(u(this))}},8090:function(c,h,t){"use strict";var o=t(35454),u=t(32621),a=Function.prototype,s=o&&Object.getOwnPropertyDescriptor,l=u(a,"name"),d=l&&function(){}.name==="something",f=l&&(!o||o&&s(a,"name").configurable);c.exports={EXISTS:l,PROPER:d,CONFIGURABLE:f}},37758:function(c,h,t){"use strict";var o=t(94237),u=t(63335);c.exports=function(a,s,l){try{return o(u(Object.getOwnPropertyDescriptor(a,s)[l]))}catch(d){}}},34114:function(c,h,t){"use strict";var o=t(29076),u=t(94237);c.exports=function(a){if(o(a)==="Function")return u(a)}},94237:function(c,h,t){"use strict";var o=t(40486),u=Function.prototype,a=u.call,s=o&&u.bind.bind(a,a);c.exports=o?s:function(l){return function(){return a.apply(l,arguments)}}},81750:function(c){"use strict";var h=TypeError;c.exports=function(t){var o=t&&t.alphabet;if(o===void 0||o==="base64"||o==="base64url")return o||"base64";throw new h("Incorrect `alphabet` option")}},38116:function(c,h,t){"use strict";var o=t(89945),u=t(55327),a=t(80449),s=t(10731),l=t(26006),d=t(53776),f=t(59893),v=t(57975),y=f("asyncIterator");c.exports=function(m){var g=a(m),S=!0,E=d(g,y),I;return u(E)||(E=l(g),S=!1),E!==void 0?I=o(E,g):(I=g,S=!0),a(I),s(S?I:new v(s(I)))}},69034:function(c,h,t){"use strict";var o=t(89945),u=t(57975),a=t(80449),s=t(85428),l=t(10731),d=t(53776),f=t(59893),v=f("asyncIterator");c.exports=function(y,m){var g=arguments.length<2?d(y,v):m;return g?a(o(g,y)):new u(l(s(y)))}},55174:function(c,h,t){"use strict";var o=t(92916);c.exports=function(u,a){var s=o[u],l=s&&s.prototype;return l&&l[a]}},65911:function(c,h,t){"use strict";var o=t(92916),u=t(55327),a=function(s){return u(s)?s:void 0};c.exports=function(s,l){return arguments.length<2?a(o[s]):o[s]&&o[s][l]}},10731:function(c){"use strict";c.exports=function(h){return{iterator:h,next:h.next,done:!1}}},7157:function(c,h,t){"use strict";var o=t(89945),u=t(80449),a=t(10731),s=t(26006);c.exports=function(l,d){(!d||typeof l!="string")&&u(l);var f=s(l);return a(u(f!==void 0?o(f,l):l))}},26006:function(c,h,t){"use strict";var o=t(97607),u=t(53776),a=t(4112),s=t(48074),l=t(59893),d=l("iterator");c.exports=function(f){if(!a(f))return u(f,d)||u(f,"@@iterator")||s[o(f)]}},85428:function(c,h,t){"use strict";var o=t(89945),u=t(63335),a=t(80449),s=t(40593),l=t(26006),d=TypeError;c.exports=function(f,v){var y=arguments.length<2?l(f):v;if(u(y))return a(o(y,f));throw new d(s(f)+" is not iterable")}},65451:function(c,h,t){"use strict";var o=t(94237),u=t(18589),a=t(55327),s=t(29076),l=t(69905),d=o([].push);c.exports=function(f){if(a(f))return f;if(u(f)){for(var v=f.length,y=[],m=0;m]*>)/g,v=/\$([$&'`]|\d{1,2})/g;c.exports=function(y,m,g,S,E,I){var w=g+y.length,P=S.length,A=v;return E!==void 0&&(E=u(E),A=f),l(I,A,function(M,L){var F;switch(s(L,0)){case"$":return"$";case"&":return y;case"`":return d(m,0,g);case"'":return d(m,w);case"<":F=E[d(L,1,-1)];break;default:var C=+L;if(C===0)return M;if(C>P){var D=a(C/10);return D===0?M:D<=P?S[D-1]===void 0?s(L,1):S[D-1]+s(L,1):M}F=S[C-1]}return F===void 0?"":F})}},92916:function(c,h,t){"use strict";var o=function(u){return u&&u.Math===Math&&u};c.exports=o(typeof globalThis=="object"&&globalThis)||o(typeof window=="object"&&window)||o(typeof self=="object"&&self)||o(typeof t.g=="object"&&t.g)||o(typeof this=="object"&&this)||function(){return this}()||Function("return this")()},32621:function(c,h,t){"use strict";var o=t(94237),u=t(94029),a=o({}.hasOwnProperty);c.exports=Object.hasOwn||function(l,d){return a(u(l),d)}},54406:function(c){"use strict";c.exports={}},61810:function(c){"use strict";c.exports=function(h,t){try{arguments.length===1?console.error(h):console.error(h,t)}catch(o){}}},75171:function(c,h,t){"use strict";var o=t(65911);c.exports=o("document","documentElement")},46796:function(c,h,t){"use strict";var o=t(35454),u=t(3338),a=t(86060);c.exports=!o&&!u(function(){return Object.defineProperty(a("div"),"a",{get:function(){return 7}}).a!==7})},61618:function(c){"use strict";var h=Array,t=Math.abs,o=Math.pow,u=Math.floor,a=Math.log,s=Math.LN2,l=function(f,v,y){var m=h(y),g=y*8-v-1,S=(1<>1,I=v===23?o(2,-24)-o(2,-77):0,w=f<0||f===0&&1/f<0?1:0,P=0,A,M,L;for(f=t(f),f!==f||f===1/0?(M=f!==f?1:0,A=S):(A=u(a(f)/s),L=o(2,-A),f*L<1&&(A--,L*=2),A+E>=1?f+=I/L:f+=I*o(2,1-E),f*L>=2&&(A++,L/=2),A+E>=S?(M=0,A=S):A+E>=1?(M=(f*L-1)*o(2,v),A+=E):(M=f*o(2,E-1)*o(2,v),A=0));v>=8;)m[P++]=M&255,M/=256,v-=8;for(A=A<0;)m[P++]=A&255,A/=256,g-=8;return m[--P]|=w*128,m},d=function(f,v){var y=f.length,m=y*8-v-1,g=(1<>1,E=m-7,I=y-1,w=f[I--],P=w&127,A;for(w>>=7;E>0;)P=P*256+f[I--],E-=8;for(A=P&(1<<-E)-1,P>>=-E,E+=v;E>0;)A=A*256+f[I--],E-=8;if(P===0)P=1-S;else{if(P===g)return A?NaN:w?-1/0:1/0;A+=o(2,v),P-=S}return(w?-1:1)*A*o(2,P-v)};c.exports={pack:l,unpack:d}},1835:function(c,h,t){"use strict";var o=t(94237),u=t(3338),a=t(29076),s=Object,l=o("".split);c.exports=u(function(){return!s("z").propertyIsEnumerable(0)})?function(d){return a(d)==="String"?l(d,""):s(d)}:s},25576:function(c,h,t){"use strict";var o=t(55327),u=t(31946),a=t(58218);c.exports=function(s,l,d){var f,v;return a&&o(f=l.constructor)&&f!==d&&u(v=f.prototype)&&v!==d.prototype&&a(s,v),s}},15212:function(c,h,t){"use strict";var o=t(94237),u=t(55327),a=t(77398),s=o(Function.toString);u(a.inspectSource)||(a.inspectSource=function(l){return s(l)}),c.exports=a.inspectSource},73068:function(c,h,t){"use strict";var o=t(31946),u=t(68151);c.exports=function(a,s){o(s)&&"cause"in s&&u(a,"cause",s.cause)}},2074:function(c,h,t){"use strict";var o=t(94488),u=t(94237),a=t(54406),s=t(31946),l=t(32621),d=t(37691).f,f=t(80689),v=t(53393),y=t(12477),m=t(6145),g=t(13247),S=!1,E=m("meta"),I=0,w=function(C){d(C,E,{value:{objectID:"O"+I++,weakData:{}}})},P=function(C,D){if(!s(C))return typeof C=="symbol"?C:(typeof C=="string"?"S":"P")+C;if(!l(C,E)){if(!y(C))return"F";if(!D)return"E";w(C)}return C[E].objectID},A=function(C,D){if(!l(C,E)){if(!y(C))return!0;if(!D)return!1;w(C)}return C[E].weakData},M=function(C){return g&&S&&y(C)&&!l(C,E)&&w(C),C},L=function(){F.enable=function(){},S=!0;var C=f.f,D=u([].splice),U={};U[E]=1,C(U).length&&(f.f=function(J){for(var W=C(J),Z=0,K=W.length;ZW;W++)if(K=se(I[W]),K&&f(E,K))return K;return new S(!1)}U=v(I,J)}for(ee=L?I.next:U.next;!(ne=u(ee,U)).done;){try{K=se(ne.value)}catch(te){m(U,"throw",te)}if(typeof K=="object"&&K&&f(E,K))return K}return new S(!1)}},67996:function(c,h,t){"use strict";var o=t(89945),u=t(80449),a=t(53776);c.exports=function(s,l,d){var f,v;u(s);try{if(f=a(s,"return"),!f){if(l==="throw")throw d;return d}f=o(f,s)}catch(y){v=!0,f=y}if(l==="throw")throw d;if(v)throw f;return u(f),d}},83126:function(c,h,t){"use strict";var o=t(46571).IteratorPrototype,u=t(20132),a=t(35012),s=t(94573),l=t(48074),d=function(){return this};c.exports=function(f,v,y,m){var g=v+" Iterator";return f.prototype=u(o,{next:a(+!m,y)}),s(f,g,!1,!0),l[g]=d,f}},20547:function(c,h,t){"use strict";var o=t(89945),u=t(20132),a=t(68151),s=t(66477),l=t(59893),d=t(94844),f=t(53776),v=t(46571).IteratorPrototype,y=t(25587),m=t(67996),g=l("toStringTag"),S="IteratorHelper",E="WrapForValidIterator",I=d.set,w=function(M){var L=d.getterFor(M?E:S);return s(u(v),{next:function(){var C=L(this);if(M)return C.nextHandler();try{var D=C.done?void 0:C.nextHandler();return y(D,C.done)}catch(U){throw C.done=!0,U}},return:function(){var F=L(this),C=F.iterator;if(F.done=!0,M){var D=f(C,"return");return D?o(D,C):y(void 0,!0)}if(F.inner)try{m(F.inner.iterator,"normal")}catch(U){return m(C,"throw",U)}return m(C,"normal"),y(void 0,!0)}})},P=w(!0),A=w(!1);a(A,g,"Iterator Helper"),c.exports=function(M,L){var F=function(D,U){U?(U.iterator=D.iterator,U.next=D.next):U=D,U.type=L?E:S,U.nextHandler=M,U.counter=0,U.done=!1,I(this,U)};return F.prototype=L?P:A,F}},24019:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(16697),s=t(8090),l=t(55327),d=t(83126),f=t(53456),v=t(58218),y=t(94573),m=t(68151),g=t(2291),S=t(59893),E=t(48074),I=t(46571),w=s.PROPER,P=s.CONFIGURABLE,A=I.IteratorPrototype,M=I.BUGGY_SAFARI_ITERATORS,L=S("iterator"),F="keys",C="values",D="entries",U=function(){return this};c.exports=function(J,W,Z,K,ee,ne,ie){d(Z,W,K);var se=function(z){if(z===ee&&O)return O;if(!M&&z&&z in N)return N[z];switch(z){case F:return function(){return new Z(this,z)};case C:return function(){return new Z(this,z)};case D:return function(){return new Z(this,z)}}return function(){return new Z(this)}},te=W+" Iterator",$=!1,N=J.prototype,j=N[L]||N["@@iterator"]||ee&&N[ee],O=!M&&j||se(ee),T=W==="Array"&&N.entries||j,Y,oe,k;if(T&&(Y=f(T.call(new J)),Y!==Object.prototype&&Y.next&&(!a&&f(Y)!==A&&(v?v(Y,A):l(Y[L])||g(Y,L,U)),y(Y,te,!0,!0),a&&(E[te]=U))),w&&ee===C&&j&&j.name!==C&&(!a&&P?m(N,"name",C):($=!0,O=function(){return u(j,this)})),ee)if(oe={values:se(C),keys:ne?O:se(F),entries:se(D)},ie)for(k in oe)(M||$||!(k in N))&&g(N,k,oe[k]);else o({target:W,proto:!0,forced:M||$},oe);return(!a||ie)&&N[L]!==O&&g(N,L,O,{name:ee}),E[W]=O,oe}},24771:function(c,h,t){"use strict";var o=t(89945),u=t(2155),a=function(s,l){return[l,s]};c.exports=function(){return o(u,this,a)}},2155:function(c,h,t){"use strict";var o=t(89945),u=t(63335),a=t(80449),s=t(10731),l=t(20547),d=t(46319),f=l(function(){var v=this.iterator,y=a(o(this.next,v)),m=this.done=!!y.done;if(!m)return d(v,this.mapper,[y.value,this.counter++],!0)});c.exports=function(y){return a(this),u(y),new f(s(this),{mapper:y})}},46571:function(c,h,t){"use strict";var o=t(3338),u=t(55327),a=t(31946),s=t(20132),l=t(53456),d=t(2291),f=t(59893),v=t(16697),y=f("iterator"),m=!1,g,S,E;[].keys&&(E=[].keys(),"next"in E?(S=l(l(E)),S!==Object.prototype&&(g=S)):m=!0);var I=!a(g)||o(function(){var w={};return g[y].call(w)!==w});I?g={}:v&&(g=s(g)),u(g[y])||d(g,y,function(){return this}),c.exports={IteratorPrototype:g,BUGGY_SAFARI_ITERATORS:m}},48074:function(c){"use strict";c.exports={}},82762:function(c,h,t){"use strict";var o=t(61578);c.exports=function(u){return o(u.length)}},86528:function(c,h,t){"use strict";var o=t(94237),u=t(3338),a=t(55327),s=t(32621),l=t(35454),d=t(8090).CONFIGURABLE,f=t(15212),v=t(94844),y=v.enforce,m=v.get,g=String,S=Object.defineProperty,E=o("".slice),I=o("".replace),w=o([].join),P=l&&!u(function(){return S(function(){},"length",{value:8}).length!==8}),A=String(String).split("String"),M=c.exports=function(L,F,C){E(g(F),0,7)==="Symbol("&&(F="["+I(g(F),/^Symbol\(([^)]*)\)/,"$1")+"]"),C&&C.getter&&(F="get "+F),C&&C.setter&&(F="set "+F),(!s(L,"name")||d&&L.name!==F)&&(l?S(L,"name",{value:F,configurable:!0}):L.name=F),P&&C&&s(C,"arity")&&L.length!==C.arity&&S(L,"length",{value:C.arity});try{C&&s(C,"constructor")&&C.constructor?l&&S(L,"prototype",{writable:!1}):L.prototype&&(L.prototype=void 0)}catch(U){}var D=y(L);return s(D,"source")||(D.source=w(A,typeof F=="string"?F:"")),L};Function.prototype.toString=M(function(){return a(this)&&m(this).source||f(this)},"toString")},2786:function(c,h,t){"use strict";var o=t(94237),u=Map.prototype;c.exports={Map,set:o(u.set),get:o(u.get),has:o(u.has),remove:o(u.delete),proto:u}},95037:function(c,h,t){"use strict";var o=t(94237),u=t(43545),a=t(2786),s=a.Map,l=a.proto,d=o(l.forEach),f=o(l.entries),v=f(new s).next;c.exports=function(y,m,g){return g?u({iterator:f(y),next:v},function(S){return m(S[1],S[0])}):d(y,m)}},14615:function(c,h,t){"use strict";var o=t(89945),u=t(63335),a=t(55327),s=t(80449),l=TypeError;c.exports=function(f,v){var y=s(this),m=u(y.get),g=u(y.has),S=u(y.set),E=arguments.length>2?arguments[2]:void 0,I;if(!a(v)&&!a(E))throw new l("At least one callback required");return o(g,y,f)?(I=o(m,y,f),a(v)&&(I=v(I),o(S,y,f,I))):a(E)&&(I=E(),o(S,y,f,I)),I}},35175:function(c,h,t){"use strict";var o=t(77056),u=.0009765625,a=65504,s=6103515625e-14;c.exports=Math.f16round||function(d){return o(d,u,a,s)}},77056:function(c,h,t){"use strict";var o=t(37666),u=Math.abs,a=2220446049250313e-31,s=1/a,l=function(d){return d+s-s};c.exports=function(d,f,v,y){var m=+d,g=u(m),S=o(m);if(gv||I!==I?S*(1/0):S*I}},14894:function(c,h,t){"use strict";var o=t(77056),u=11920928955078125e-23,a=34028234663852886e22,s=11754943508222875e-54;c.exports=Math.fround||function(d){return o(d,u,a,s)}},24619:function(c){"use strict";c.exports=Math.scale||function(t,o,u,a,s){var l=+t,d=+o,f=+u,v=+a,y=+s;return l!==l||d!==d||f!==f||v!==v||y!==y?NaN:l===1/0||l===-1/0?l:(l-d)*(y-v)/(f-d)+v}},37666:function(c){"use strict";c.exports=Math.sign||function(t){var o=+t;return o===0||o!==o?o:o<0?-1:1}},3312:function(c){"use strict";var h=Math.ceil,t=Math.floor;c.exports=Math.trunc||function(u){var a=+u;return(a>0?t:h)(a)}},82778:function(c,h,t){"use strict";var o=t(3338);c.exports=!o(function(){var u="9007199254740993",a=JSON.rawJSON(u);return!JSON.isRawJSON(a)||JSON.stringify(a)!==u})},73446:function(c,h,t){"use strict";var o=t(63335),u=TypeError,a=function(s){var l,d;this.promise=new s(function(f,v){if(l!==void 0||d!==void 0)throw new u("Bad Promise constructor");l=f,d=v}),this.resolve=o(l),this.reject=o(d)};c.exports.f=function(s){return new a(s)}},7825:function(c,h,t){"use strict";var o=t(69905);c.exports=function(u,a){return u===void 0?arguments.length<2?"":a:o(u)}},2279:function(c){"use strict";var h=RangeError;c.exports=function(t){if(t===t)return t;throw new h("NaN is not allowed")}},1222:function(c,h,t){"use strict";var o=t(92916),u=o.isFinite;c.exports=Number.isFinite||function(s){return typeof s=="number"&&u(s)}},17243:function(c,h,t){"use strict";var o=t(94844),u=t(83126),a=t(25587),s=t(4112),l=t(31946),d=t(64110),f=t(35454),v="Incorrect Iterator.range arguments",y="NumericRangeIterator",m=o.set,g=o.getterFor(y),S=RangeError,E=TypeError,I=u(function(A,M,L,F,C,D){if(typeof A!=F||M!==1/0&&M!==-1/0&&typeof M!=F)throw new E(v);if(A===1/0||A===-1/0)throw new S(v);var U=M>A,J=!1,W;if(L===void 0)W=void 0;else if(l(L))W=L.step,J=!!L.inclusive;else if(typeof L==F)W=L;else throw new E(v);if(s(W)&&(W=U?D:-D),typeof W!=F)throw new E(v);if(W===1/0||W===-1/0||W===C&&A!==M)throw new S(v);var Z=A!==A||M!==M||W!==W||M>A!=W>C;m(this,{type:y,start:A,end:M,step:W,inclusive:J,hitsEnd:Z,currentCount:C,zero:C}),f||(this.start=A,this.end=M,this.step=W,this.inclusive=J)},y,function(){var A=g(this);if(A.hitsEnd)return a(void 0,!0);var M=A.start,L=A.end,F=A.step,C=M+F*A.currentCount++;C===L&&(A.hitsEnd=!0);var D=A.inclusive,U;return L>M?U=D?C>L:C>=L:U=D?L>C:L>=C,U?(A.hitsEnd=!0,a(void 0,!0)):a(C,!1)}),w=function(P){d(I.prototype,P,{get:function(){return g(this)[P]},set:function(){},configurable:!0,enumerable:!1})};f&&(w("start"),w("end"),w("inclusive"),w("step")),c.exports=I},20132:function(c,h,t){"use strict";var o=t(80449),u=t(55666),a=t(46678),s=t(54406),l=t(75171),d=t(86060),f=t(11898),v=">",y="<",m="prototype",g="script",S=f("IE_PROTO"),E=function(){},I=function(L){return y+g+v+L+y+"/"+g+v},w=function(L){L.write(I("")),L.close();var F=L.parentWindow.Object;return L=null,F},P=function(){var L=d("iframe"),F="java"+g+":",C;return L.style.display="none",l.appendChild(L),L.src=String(F),C=L.contentWindow.document,C.open(),C.write(I("document.F=Object")),C.close(),C.F},A,M=function(){try{A=new ActiveXObject("htmlfile")}catch(F){}M=typeof document!="undefined"?document.domain&&A?w(A):P():w(A);for(var L=a.length;L--;)delete M[m][a[L]];return M()};s[S]=!0,c.exports=Object.create||function(F,C){var D;return F!==null?(E[m]=o(F),D=new E,E[m]=null,D[S]=F):D=M(),C===void 0?D:u.f(D,C)}},55666:function(c,h,t){"use strict";var o=t(35454),u=t(93199),a=t(37691),s=t(80449),l=t(80524),d=t(7733);h.f=o&&!u?Object.defineProperties:function(v,y){s(v);for(var m=l(y),g=d(y),S=g.length,E=0,I;S>E;)a.f(v,I=g[E++],m[I]);return v}},37691:function(c,h,t){"use strict";var o=t(35454),u=t(46796),a=t(93199),s=t(80449),l=t(17818),d=TypeError,f=Object.defineProperty,v=Object.getOwnPropertyDescriptor,y="enumerable",m="configurable",g="writable";h.f=o?a?function(E,I,w){if(s(E),I=l(I),s(w),typeof E=="function"&&I==="prototype"&&"value"in w&&g in w&&!w[g]){var P=v(E,I);P&&P[g]&&(E[I]=w.value,w={configurable:m in w?w[m]:P[m],enumerable:y in w?w[y]:P[y],writable:!1})}return f(E,I,w)}:f:function(E,I,w){if(s(E),I=l(I),s(w),u)try{return f(E,I,w)}catch(P){}if("get"in w||"set"in w)throw new d("Accessors not supported");return"value"in w&&(E[I]=w.value),E}},71256:function(c,h,t){"use strict";var o=t(35454),u=t(89945),a=t(27597),s=t(35012),l=t(80524),d=t(17818),f=t(32621),v=t(46796),y=Object.getOwnPropertyDescriptor;h.f=o?y:function(g,S){if(g=l(g),S=d(S),v)try{return y(g,S)}catch(E){}if(f(g,S))return s(!u(a.f,g,S),g[S])}},53393:function(c,h,t){"use strict";var o=t(29076),u=t(80524),a=t(80689).f,s=t(71698),l=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],d=function(f){try{return a(f)}catch(v){return s(l)}};c.exports.f=function(v){return l&&o(v)==="Window"?d(v):a(u(v))}},80689:function(c,h,t){"use strict";var o=t(97486),u=t(46678),a=u.concat("length","prototype");h.f=Object.getOwnPropertyNames||function(l){return o(l,a)}},92635:function(c,h){"use strict";h.f=Object.getOwnPropertySymbols},53456:function(c,h,t){"use strict";var o=t(32621),u=t(55327),a=t(94029),s=t(11898),l=t(4870),d=s("IE_PROTO"),f=Object,v=f.prototype;c.exports=l?f.getPrototypeOf:function(y){var m=a(y);if(o(m,d))return m[d];var g=m.constructor;return u(g)&&m instanceof g?g.prototype:m instanceof f?v:null}},12477:function(c,h,t){"use strict";var o=t(3338),u=t(31946),a=t(29076),s=t(51424),l=Object.isExtensible,d=o(function(){l(1)});c.exports=d||s?function(v){return!u(v)||s&&a(v)==="ArrayBuffer"?!1:l?l(v):!0}:l},16332:function(c,h,t){"use strict";var o=t(94237);c.exports=o({}.isPrototypeOf)},20574:function(c,h,t){"use strict";var o=t(94844),u=t(83126),a=t(25587),s=t(32621),l=t(7733),d=t(94029),f="Object Iterator",v=o.set,y=o.getterFor(f);c.exports=u(function(g,S){var E=d(g);v(this,{type:f,mode:S,object:E,keys:l(E),index:0})},"Object",function(){for(var g=y(this),S=g.keys;;){if(S===null||g.index>=S.length)return g.object=g.keys=null,a(void 0,!0);var E=S[g.index++],I=g.object;if(s(I,E)){switch(g.mode){case"keys":return a(E,!1);case"values":return a(I[E],!1)}return a([E,I[E]],!1)}}})},97486:function(c,h,t){"use strict";var o=t(94237),u=t(32621),a=t(80524),s=t(22999).indexOf,l=t(54406),d=o([].push);c.exports=function(f,v){var y=a(f),m=0,g=[],S;for(S in y)!u(l,S)&&u(y,S)&&d(g,S);for(;v.length>m;)u(y,S=v[m++])&&(~s(g,S)||d(g,S));return g}},7733:function(c,h,t){"use strict";var o=t(97486),u=t(46678);c.exports=Object.keys||function(s){return o(s,u)}},27597:function(c,h){"use strict";var t={}.propertyIsEnumerable,o=Object.getOwnPropertyDescriptor,u=o&&!t.call({1:2},1);h.f=u?function(s){var l=o(this,s);return!!l&&l.enumerable}:t},58218:function(c,h,t){"use strict";var o=t(37758),u=t(80449),a=t(557);c.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var s=!1,l={},d;try{d=o(Object.prototype,"__proto__","set"),d(l,[]),s=l instanceof Array}catch(f){}return function(v,y){return u(v),a(y),s?d(v,y):v.__proto__=y,v}}():void 0)},44759:function(c,h,t){"use strict";var o=t(89945),u=t(55327),a=t(31946),s=TypeError;c.exports=function(l,d){var f,v;if(d==="string"&&u(f=l.toString)&&!a(v=o(f,l))||u(f=l.valueOf)&&!a(v=o(f,l))||d!=="string"&&u(f=l.toString)&&!a(v=o(f,l)))return v;throw new s("Can't convert object to primitive value")}},48662:function(c,h,t){"use strict";var o=t(65911),u=t(94237),a=t(80689),s=t(92635),l=t(80449),d=u([].concat);c.exports=o("Reflect","ownKeys")||function(v){var y=a.f(l(v)),m=s.f;return m?d(y,m(v)):y}},70913:function(c,h,t){"use strict";var o=t(94237),u=t(32621),a=SyntaxError,s=parseInt,l=String.fromCharCode,d=o("".charAt),f=o("".slice),v=o(/./.exec),y={'\\"':'"',"\\\\":"\\","\\/":"/","\\b":"\b","\\f":"\f","\\n":` +`,"\\r":"\r","\\t":" "},m=/^[\da-f]{4}$/i,g=/^[\u0000-\u001F]$/;c.exports=function(S,E){for(var I=!0,w="";ES,P=a(E)?E:v(E),A=w?d(arguments,S):[],M=w?function(){u(P,this,A)}:P;return g?m(M,I):m(M)}:m}},61838:function(c,h,t){"use strict";var o=t(19691),u=t(57002),a=o.Set,s=o.add;c.exports=function(l){var d=new a;return u(l,function(f){s(d,f)}),d}},10038:function(c,h,t){"use strict";var o=t(17442),u=t(19691),a=t(61838),s=t(108),l=t(88203),d=t(57002),f=t(43545),v=u.has,y=u.remove;c.exports=function(g){var S=o(this),E=l(g),I=a(S);return s(S)<=E.size?d(S,function(w){E.includes(w)&&y(I,w)}):f(E.getIterator(),function(w){v(S,w)&&y(I,w)}),I}},19691:function(c,h,t){"use strict";var o=t(94237),u=Set.prototype;c.exports={Set,add:o(u.add),has:o(u.has),remove:o(u.delete),proto:u}},16049:function(c,h,t){"use strict";var o=t(17442),u=t(19691),a=t(108),s=t(88203),l=t(57002),d=t(43545),f=u.Set,v=u.add,y=u.has;c.exports=function(g){var S=o(this),E=s(g),I=new f;return a(S)>E.size?d(E.getIterator(),function(w){y(S,w)&&v(I,w)}):l(S,function(w){E.includes(w)&&v(I,w)}),I}},17616:function(c,h,t){"use strict";var o=t(17442),u=t(19691).has,a=t(108),s=t(88203),l=t(57002),d=t(43545),f=t(67996);c.exports=function(y){var m=o(this),g=s(y);if(a(m)<=g.size)return l(m,function(E){if(g.includes(E))return!1},!0)!==!1;var S=g.getIterator();return d(S,function(E){if(u(m,E))return f(S,"normal",!1)})!==!1}},84833:function(c,h,t){"use strict";var o=t(17442),u=t(108),a=t(57002),s=t(88203);c.exports=function(d){var f=o(this),v=s(d);return u(f)>v.size?!1:a(f,function(y){if(!v.includes(y))return!1},!0)!==!1}},51135:function(c,h,t){"use strict";var o=t(17442),u=t(19691).has,a=t(108),s=t(88203),l=t(43545),d=t(67996);c.exports=function(v){var y=o(this),m=s(v);if(a(y)=I?y?"":void 0:(w=d(S,E),w<55296||w>56319||E+1===I||(P=d(S,E+1))<56320||P>57343?y?l(S,E):w:y?f(S,E,E+2):(w-55296<<10)+(P-56320)+65536)}};c.exports={codeAt:v(!1),charAt:v(!0)}},79204:function(c,h,t){"use strict";var o=t(65911),u=t(94237),a=String.fromCharCode,s=o("String","fromCodePoint"),l=u("".charAt),d=u("".charCodeAt),f=u("".indexOf),v=u("".slice),y=48,m=57,g=97,S=102,E=65,I=70,w=function(M,L){var F=d(M,L);return F>=y&&F<=m},P=function(M,L,F){if(F>=M.length)return-1;for(var C=0;L=y&&M<=m?M-y:M>=g&&M<=S?M-g+10:M>=E&&M<=I?M-E+10:-1};c.exports=function(M){for(var L="",F=0,C=0,D;(C=f(M,"\\",C))>-1;){if(L+=v(M,F,C),++C===M.length)return;var U=l(M,C++);switch(U){case"b":L+="\b";break;case"t":L+=" ";break;case"n":L+=` +`;break;case"v":L+="\v";break;case"f":L+="\f";break;case"r":L+="\r";break;case"\r":C1114111)return;L+=s(D);break;default:if(w(U,0))return;L+=U}F=C}return L+v(M,F)}},80426:function(c,h,t){"use strict";var o=t(92916),u=t(3338),a=t(46573),s=t(66994),l=t(91821),d=t(90946),f=o.structuredClone;c.exports=!!f&&!u(function(){if(l&&a>92||d&&a>94||s&&a>97)return!1;var v=new ArrayBuffer(8),y=f(v,{transfer:[v]});return v.byteLength!==0||y.byteLength!==8})},42820:function(c,h,t){"use strict";var o=t(46573),u=t(3338),a=t(92916),s=a.String;c.exports=!!Object.getOwnPropertySymbols&&!u(function(){var l=Symbol("symbol detection");return!s(l)||!(Object(l)instanceof Symbol)||!Symbol.sham&&o&&o<41})},69077:function(c,h,t){"use strict";var o=t(65911),u=t(94237),a=o("Symbol"),s=a.keyFor,l=u(a.prototype.valueOf);c.exports=a.isRegisteredSymbol||function(f){try{return s(l(f))!==void 0}catch(v){return!1}}},40443:function(c,h,t){"use strict";for(var o=t(77898),u=t(65911),a=t(94237),s=t(18446),l=t(59893),d=u("Symbol"),f=d.isWellKnownSymbol,v=u("Object","getOwnPropertyNames"),y=a(d.prototype.valueOf),m=o("wks"),g=0,S=v(d),E=S.length;g0?u(o(a),9007199254740991):0}},94029:function(c,h,t){"use strict";var o=t(95955),u=Object;c.exports=function(a){return u(o(a))}},64135:function(c,h,t){"use strict";var o=t(51358),u=RangeError;c.exports=function(a,s){var l=o(a);if(l%s)throw new u("Wrong offset");return l}},51358:function(c,h,t){"use strict";var o=t(56902),u=RangeError;c.exports=function(a){var s=o(a);if(s<0)throw new u("The argument can't be less than 0");return s}},97954:function(c,h,t){"use strict";var o=t(89945),u=t(31946),a=t(18446),s=t(53776),l=t(44759),d=t(59893),f=TypeError,v=d("toPrimitive");c.exports=function(y,m){if(!u(y)||a(y))return y;var g=s(y,v),S;if(g){if(m===void 0&&(m="default"),S=o(g,y,m),!u(S)||a(S))return S;throw new f("Can't convert object to primitive value")}return m===void 0&&(m="number"),l(y,m)}},17818:function(c,h,t){"use strict";var o=t(97954),u=t(18446);c.exports=function(a){var s=o(a,"string");return u(s)?s:s+""}},77999:function(c,h,t){"use strict";var o=t(65911),u=t(55327),a=t(30360),s=t(31946),l=o("Set"),d=function(f){return s(f)&&typeof f.size=="number"&&u(f.has)&&u(f.keys)};c.exports=function(f){return d(f)?f:a(f)?new l(f):f}},68527:function(c,h,t){"use strict";var o=t(59893),u=o("toStringTag"),a={};a[u]="z",c.exports=String(a)==="[object z]"},69905:function(c,h,t){"use strict";var o=t(97607),u=String;c.exports=function(a){if(o(a)==="Symbol")throw new TypeError("Cannot convert a Symbol value to a string");return u(a)}},86350:function(c){"use strict";var h=Math.round;c.exports=function(t){var o=h(t);return o<0?0:o>255?255:o&255}},11270:function(c,h,t){"use strict";var o=t(90946);c.exports=function(u){try{if(o)return Function('return require("'+u+'")')()}catch(a){}}},40593:function(c){"use strict";var h=String;c.exports=function(t){try{return h(t)}catch(o){return"Object"}}},27607:function(c,h,t){"use strict";var o=t(69478),u=t(31384);c.exports=function(a,s){return o(u(a),s)}},31384:function(c,h,t){"use strict";var o=t(58261),u=t(60473),a=o.aTypedArrayConstructor,s=o.getTypedArrayConstructor;c.exports=function(l){return a(u(l,s(l)))}},6145:function(c,h,t){"use strict";var o=t(94237),u=0,a=Math.random(),s=o(1 .toString);c.exports=function(l){return"Symbol("+(l===void 0?"":l)+")_"+s(++u+a,36)}},3299:function(c,h,t){"use strict";var o=t(3338),u=t(59893),a=t(35454),s=t(16697),l=u("iterator");c.exports=!o(function(){var d=new URL("b?a=1&b=2&c=3","http://a"),f=d.searchParams,v=new URLSearchParams("a=1&a=2&b=3"),y="";return d.pathname="c%20d",f.forEach(function(m,g){f.delete("b"),y+=g+m}),v.delete("a",2),v.delete("b",void 0),s&&(!d.toJSON||!v.has("a",1)||v.has("a",2)||!v.has("a",void 0)||v.has("b"))||!f.size&&(s||!a)||!f.sort||d.href!=="http://a/c%20d?a=1&c=3"||f.get("c")!=="3"||String(new URLSearchParams("?a=1"))!=="a=1"||!f[l]||new URL("https://a@b").username!=="a"||new URLSearchParams(new URLSearchParams("a=b")).get("a")!=="b"||new URL("http://\u0442\u0435\u0441\u0442").host!=="xn--e1aybc"||new URL("http://a#\u0431").hash!=="#%D0%B1"||y!=="a1c3"||new URL("http://x",void 0).host!=="x"})},14417:function(c,h,t){"use strict";var o=t(42820);c.exports=o&&!Symbol.sham&&typeof Symbol.iterator=="symbol"},93199:function(c,h,t){"use strict";var o=t(35454),u=t(3338);c.exports=o&&u(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42})},57106:function(c){"use strict";var h=TypeError;c.exports=function(t,o){if(tL&&m(ne,arguments[L]),ne});if(W.prototype=U,C!=="Error"?l?l(W,J):d(W,J,{name:!0}):S&&M in D&&(f(W,D,M),f(W,D,"prepareStackTrace")),d(W,D),!E)try{U.name!==C&&a(U,"name",C),U.constructor=W}catch(Z){}return W}}},93074:function(c,h,t){"use strict";var o=t(94488),u=t(65911),a=t(13743),s=t(3338),l=t(78540),d="AggregateError",f=u(d),v=!s(function(){return f([1]).errors[0]!==1})&&s(function(){return f([1],d,{cause:7}).cause!==7});o({global:!0,constructor:!0,arity:2,forced:v},{AggregateError:l(d,function(y){return function(g,S){return a(y,this,arguments)}},v,!0)})},6555:function(c,h,t){"use strict";var o=t(94488),u=t(16332),a=t(53456),s=t(58218),l=t(24538),d=t(20132),f=t(68151),v=t(35012),y=t(73068),m=t(61888),g=t(62003),S=t(7825),E=t(59893),I=E("toStringTag"),w=Error,P=[].push,A=function(F,C){var D=u(M,this),U;s?U=s(new w,D?a(this):M):(U=D?this:d(M),f(U,I,"Error")),C!==void 0&&f(U,"message",S(C)),m(U,A,U.stack,1),arguments.length>2&&y(U,arguments[2]);var J=[];return g(F,P,{that:J}),f(U,"errors",J),U};s?s(A,w):l(A,w,{name:!0});var M=A.prototype=d(w.prototype,{constructor:v(1,A),message:v(1,""),name:v(1,"AggregateError")});o({global:!0,constructor:!0,arity:2},{AggregateError:A})},86357:function(c,h,t){"use strict";t(6555)},96331:function(c,h,t){"use strict";var o=t(94488),u=t(94029),a=t(82762),s=t(56902),l=t(81181);o({target:"Array",proto:!0},{at:function(f){var v=u(this),y=a(v),m=s(f),g=m>=0?m:y+m;return g<0||g>=y?void 0:v[g]}}),l("at")},17482:function(c,h,t){"use strict";var o=t(94488),u=t(53279).findLastIndex,a=t(81181);o({target:"Array",proto:!0},{findLastIndex:function(l){return u(this,l,arguments.length>1?arguments[1]:void 0)}}),a("findLastIndex")},33717:function(c,h,t){"use strict";var o=t(94488),u=t(53279).findLast,a=t(81181);o({target:"Array",proto:!0},{findLast:function(l){return u(this,l,arguments.length>1?arguments[1]:void 0)}}),a("findLast")},7154:function(c,h,t){"use strict";var o=t(94488),u=t(94029),a=t(82762),s=t(39428),l=t(66434),d=t(3338),f=d(function(){return[].push.call({length:4294967296},1)!==4294967297}),v=function(){try{Object.defineProperty([],"length",{writable:!1}).push()}catch(m){return m instanceof TypeError}},y=f||!v();o({target:"Array",proto:!0,arity:1,forced:y},{push:function(g){var S=u(this),E=a(S),I=arguments.length;l(E+I);for(var w=0;w79&&s<83,f=d||!a("reduceRight");o({target:"Array",proto:!0,forced:f},{reduceRight:function(y){return u(this,y,arguments.length,arguments.length>1?arguments[1]:void 0)}})},67788:function(c,h,t){"use strict";var o=t(94488),u=t(16370).left,a=t(45601),s=t(46573),l=t(90946),d=!l&&s>79&&s<83,f=d||!a("reduce");o({target:"Array",proto:!0,forced:f},{reduce:function(y){var m=arguments.length;return u(this,y,m,m>1?arguments[1]:void 0)}})},1148:function(c,h,t){"use strict";var o=t(94488),u=t(85903),a=t(80524),s=t(81181),l=Array;o({target:"Array",proto:!0},{toReversed:function(){return u(a(this),l)}}),s("toReversed")},82445:function(c,h,t){"use strict";var o=t(94488),u=t(94237),a=t(63335),s=t(80524),l=t(69478),d=t(55174),f=t(81181),v=Array,y=u(d("Array","sort"));o({target:"Array",proto:!0},{toSorted:function(g){g!==void 0&&a(g);var S=s(this),E=l(v,S);return y(E,g)}}),f("toSorted")},27267:function(c,h,t){"use strict";var o=t(94488),u=t(81181),a=t(66434),s=t(82762),l=t(51981),d=t(80524),f=t(56902),v=Array,y=Math.max,m=Math.min;o({target:"Array",proto:!0},{toSpliced:function(S,E){var I=d(this),w=s(I),P=l(S,w),A=arguments.length,M=0,L,F,C,D;for(A===0?L=F=0:A===1?(L=0,F=w-P):(L=A-2,F=m(y(f(E),0),w-P)),C=a(w+L-F),D=v(C);M=0?E:S+E;return I<0||I>=S?void 0:f(g,I)}})},32493:function(c,h,t){"use strict";var o=t(94488),u=t(94237),a=t(95955),s=t(69905),l=u("".charCodeAt);o({target:"String",proto:!0},{isWellFormed:function(){for(var f=s(a(this)),v=f.length,y=0;y=56320||++y>=v||(l(f,y)&64512)!==56320))return!1}return!0}})},55629:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(94237),s=t(95955),l=t(55327),d=t(4112),f=t(44639),v=t(69905),y=t(53776),m=t(81644),g=t(23011),S=t(59893),E=t(16697),I=S("replace"),w=TypeError,P=a("".indexOf),A=a("".replace),M=a("".slice),L=Math.max,F=function(C,D,U){return U>C.length?-1:D===""?U:P(C,D,U)};o({target:"String",proto:!0},{replaceAll:function(D,U){var J=s(this),W,Z,K,ee,ne,ie,se,te,$,N=0,j=0,O="";if(!d(D)){if(W=f(D),W&&(Z=v(s(m(D))),!~P(Z,"g")))throw new w("`.replaceAll` does not allow non-global regexes");if(K=y(D,I),K)return u(K,D,J,U);if(E&&W)return A(v(J),D,U)}for(ee=v(J),ne=v(D),ie=l(U),ie||(U=v(U)),se=ne.length,te=L(1,se),N=F(ee,ne,0);N!==-1;)$=ie?v(U(ne,N,ee)):g(ne,ee,N,[],void 0,U),O+=M(ee,j,N)+$,j=N+se,N=F(ee,ne,N+te);return j=56320||M+1>=P||(y(w,M+1)&64512)!==56320?A[M]=S:(A[M]=v(w,M),A[++M]=v(w,M))}return m(A,"")}})},35246:function(c,h,t){"use strict";var o=t(58261),u=t(82762),a=t(56902),s=o.aTypedArray,l=o.exportTypedArrayMethod;l("at",function(f){var v=s(this),y=u(v),m=a(f),g=m>=0?m:y+m;return g<0||g>=y?void 0:v[g]})},64344:function(c,h,t){"use strict";var o=t(58261),u=t(53279).findLastIndex,a=o.aTypedArray,s=o.exportTypedArrayMethod;s("findLastIndex",function(d){return u(a(this),d,arguments.length>1?arguments[1]:void 0)})},59419:function(c,h,t){"use strict";var o=t(58261),u=t(53279).findLast,a=o.aTypedArray,s=o.exportTypedArrayMethod;s("findLast",function(d){return u(a(this),d,arguments.length>1?arguments[1]:void 0)})},89466:function(c,h,t){"use strict";var o=t(92916),u=t(89945),a=t(58261),s=t(82762),l=t(64135),d=t(94029),f=t(3338),v=o.RangeError,y=o.Int8Array,m=y&&y.prototype,g=m&&m.set,S=a.aTypedArray,E=a.exportTypedArrayMethod,I=!f(function(){var P=new Uint8ClampedArray(2);return u(g,P,{length:1,0:3},1),P[1]!==3}),w=I&&a.NATIVE_ARRAY_BUFFER_VIEWS&&f(function(){var P=new y(2);return P.set(1),P.set("2",1),P[0]!==0||P[1]!==2});E("set",function(A){S(this);var M=l(arguments.length>1?arguments[1]:void 0,1),L=d(A);if(I)return u(g,this,L,M);var F=this.length,C=s(L),D=0;if(C+M>F)throw new v("Wrong length");for(;D1?arguments[1]:void 0)}}),a("filterOut")},55885:function(c,h,t){"use strict";var o=t(94488),u=t(90560).filterReject,a=t(81181);o({target:"Array",proto:!0,forced:!0},{filterReject:function(l){return u(this,l,arguments.length>1?arguments[1]:void 0)}}),a("filterReject")},91130:function(c,h,t){"use strict";var o=t(94488),u=t(32278);o({target:"Array",stat:!0},{fromAsync:u})},64963:function(c,h,t){"use strict";var o=t(94488),u=t(45601),a=t(81181),s=t(33940),l=t(16697);o({target:"Array",proto:!0,name:"groupToMap",forced:l||!u("groupByToMap")},{groupByToMap:s}),a("groupByToMap")},8604:function(c,h,t){"use strict";var o=t(94488),u=t(36444),a=t(45601),s=t(81181);o({target:"Array",proto:!0,forced:!a("groupBy")},{groupBy:function(d){var f=arguments.length>1?arguments[1]:void 0;return u(this,d,f)}}),s("groupBy")},25178:function(c,h,t){"use strict";var o=t(94488),u=t(81181),a=t(33940),s=t(16697);o({target:"Array",proto:!0,forced:s},{groupToMap:a}),u("groupToMap")},39034:function(c,h,t){"use strict";var o=t(94488),u=t(36444),a=t(81181);o({target:"Array",proto:!0},{group:function(l){var d=arguments.length>1?arguments[1]:void 0;return u(this,l,d)}}),a("group")},1905:function(c,h,t){"use strict";var o=t(94488),u=t(18589),a=Object.isFrozen,s=function(l,d){if(!a||!u(l)||!a(l))return!1;for(var f=0,v=l.length,y;f1?arguments[1]:!1);return a([f&255,f>>8&255],10)}})},93236:function(c,h,t){"use strict";var o=t(94488),u=t(94237),a=u(DataView.prototype.getUint8);o({target:"DataView",proto:!0,forced:!0},{getUint8Clamped:function(l){return a(this,l)}})},42212:function(c,h,t){"use strict";var o=t(94488),u=t(94237),a=t(97607),s=t(24225),l=t(61618).pack,d=t(35175),f=TypeError,v=u(DataView.prototype.setUint16);o({target:"DataView",proto:!0},{setFloat16:function(m,g){if(a(this)!=="DataView")throw new f("Incorrect receiver");var S=s(m),E=l(d(g),10,2);return v(this,S,E[1]<<8|E[0],arguments.length>2?arguments[2]:!1)}})},63923:function(c,h,t){"use strict";var o=t(94488),u=t(94237),a=t(97607),s=t(24225),l=t(86350),d=TypeError,f=u(DataView.prototype.setUint8);o({target:"DataView",proto:!0,forced:!0},{setUint8Clamped:function(y,m){if(a(this)!=="DataView")throw new d("Incorrect receiver");var g=s(y);return f(this,g,l(m))}})},2278:function(c,h,t){"use strict";var o=t(94488),u=t(35454),a=t(65911),s=t(63335),l=t(56472),d=t(2291),f=t(66477),v=t(64110),y=t(59893),m=t(94844),g=t(5978),S=a("SuppressedError"),E=ReferenceError,I=y("dispose"),w=y("toStringTag"),P="DisposableStack",A=m.set,M=m.getterFor(P),L="sync-dispose",F="disposed",C="pending",D=function(W){var Z=M(W);if(Z.state===F)throw new E(P+" already disposed");return Z},U=function(){A(l(this,J),{type:P,state:C,stack:[]}),u||(this.disposed=!1)},J=U.prototype;f(J,{dispose:function(){var Z=M(this);if(Z.state!==F){Z.state=F,u||(this.disposed=!0);for(var K=Z.stack,ee=K.length,ne=!1,ie;ee;){var se=K[--ee];K[ee]=null;try{se()}catch(te){ne?ie=new S(te,ie):(ne=!0,ie=te)}}if(Z.stack=null,ne)throw ie}},use:function(Z){return g(D(this),Z,L),Z},adopt:function(Z,K){var ee=D(this);return s(K),g(ee,void 0,L,function(){K(Z)}),Z},defer:function(Z){var K=D(this);s(Z),g(K,void 0,L,Z)},move:function(){var Z=D(this),K=new U;return M(K).stack=Z.stack,Z.stack=[],Z.state=F,u||(this.disposed=!0),K}}),u&&v(J,"disposed",{configurable:!0,get:function(){return M(this).state===F}}),d(J,I,J.dispose,{name:"dispose"}),d(J,w,P,{nonWritable:!0}),o({global:!0,constructor:!0},{DisposableStack:U})},36955:function(c,h,t){"use strict";var o=t(94488),u=t(47739);o({target:"Function",proto:!0,forced:!0},{demethodize:u})},77326:function(c,h,t){"use strict";var o=t(94488),u=t(94237),a=t(55327),s=t(15212),l=t(32621),d=t(35454),f=Object.getOwnPropertyDescriptor,v=/^\s*class\b/,y=u(v.exec),m=function(g){try{if(!d||!y(v,s(g)))return!1}catch(E){}var S=f(g,"prototype");return!!S&&l(S,"writable")&&!S.writable};o({target:"Function",stat:!0,sham:!0,forced:!0},{isCallable:function(S){return a(S)&&!m(S)}})},53571:function(c,h,t){"use strict";var o=t(94488),u=t(39812);o({target:"Function",stat:!0,forced:!0},{isConstructor:u})},28670:function(c,h,t){"use strict";var o=t(59893),u=t(37691).f,a=o("metadata"),s=Function.prototype;s[a]===void 0&&u(s,a,{value:null})},31050:function(c,h,t){"use strict";var o=t(94488),u=t(47739);o({target:"Function",proto:!0,forced:!0,name:"demethodize"},{unThis:u})},96364:function(c,h,t){"use strict";var o=t(94488),u=t(24771);o({target:"Iterator",name:"indexed",proto:!0,real:!0,forced:!0},{asIndexedPairs:u})},25321:function(c,h,t){"use strict";var o=t(94488),u=t(92916),a=t(56472),s=t(80449),l=t(55327),d=t(53456),f=t(64110),v=t(69392),y=t(3338),m=t(32621),g=t(59893),S=t(46571).IteratorPrototype,E=t(35454),I=t(16697),w="constructor",P="Iterator",A=g("toStringTag"),M=TypeError,L=u[P],F=I||!l(L)||L.prototype!==S||!y(function(){L({})}),C=function(){if(a(this,S),d(this)===S)throw new M("Abstract class Iterator not directly constructable")},D=function(U,J){E?f(S,U,{configurable:!0,get:function(){return J},set:function(W){if(s(this),this===S)throw new M("You can't redefine this property");m(this,U)?this[U]=W:v(this,U,W)}}):S[U]=J};m(S,A)||D(A,P),(F||!m(S,w)||S[w]===Object)&&D(w,C),C.prototype=S,o({global:!0,constructor:!0,forced:F},{Iterator:C})},46304:function(c,h,t){"use strict";var o=t(89945),u=t(2291),a=t(53776),s=t(32621),l=t(59893),d=t(46571).IteratorPrototype,f=l("dispose");s(d,f)||u(d,f,function(){var v=a(this,"return");v&&o(v,this)})},55163:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(80449),s=t(10731),l=t(2279),d=t(51358),f=t(20547),v=t(16697),y=f(function(){for(var m=this.iterator,g=this.next,S,E;this.remaining;)if(this.remaining--,S=a(u(g,m)),E=this.done=!!S.done,E)return;if(S=a(u(g,m)),E=this.done=!!S.done,!E)return S.value});o({target:"Iterator",proto:!0,real:!0,forced:v},{drop:function(g){a(this);var S=d(l(+g));return new y(s(this),{remaining:S})}})},78722:function(c,h,t){"use strict";var o=t(94488),u=t(62003),a=t(63335),s=t(80449),l=t(10731);o({target:"Iterator",proto:!0,real:!0},{every:function(f){s(this),a(f);var v=l(this),y=0;return!u(v,function(m,g){if(!f(m,y++))return g()},{IS_RECORD:!0,INTERRUPTED:!0}).stopped}})},35977:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(63335),s=t(80449),l=t(10731),d=t(20547),f=t(46319),v=t(16697),y=d(function(){for(var m=this.iterator,g=this.predicate,S=this.next,E,I,w;;){if(E=s(u(S,m)),I=this.done=!!E.done,I)return;if(w=E.value,f(m,g,[w,this.counter++],!0))return w}});o({target:"Iterator",proto:!0,real:!0,forced:v},{filter:function(g){return s(this),a(g),new y(l(this),{predicate:g})}})},81848:function(c,h,t){"use strict";var o=t(94488),u=t(62003),a=t(63335),s=t(80449),l=t(10731);o({target:"Iterator",proto:!0,real:!0},{find:function(f){s(this),a(f);var v=l(this),y=0;return u(v,function(m,g){if(f(m,y++))return g(m)},{IS_RECORD:!0,INTERRUPTED:!0}).result}})},52867:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(63335),s=t(80449),l=t(10731),d=t(7157),f=t(20547),v=t(67996),y=t(16697),m=f(function(){for(var g=this.iterator,S=this.mapper,E,I;;){if(I=this.inner)try{if(E=s(u(I.next,I.iterator)),!E.done)return E.value;this.inner=null}catch(w){v(g,"throw",w)}if(E=s(u(this.next,g)),this.done=!!E.done)return;try{this.inner=d(S(E.value,this.counter++),!1)}catch(w){v(g,"throw",w)}}});o({target:"Iterator",proto:!0,real:!0,forced:y},{flatMap:function(S){return s(this),a(S),new m(l(this),{mapper:S,inner:null})}})},72211:function(c,h,t){"use strict";var o=t(94488),u=t(62003),a=t(63335),s=t(80449),l=t(10731);o({target:"Iterator",proto:!0,real:!0},{forEach:function(f){s(this),a(f);var v=l(this),y=0;u(v,function(m){f(m,y++)},{IS_RECORD:!0})}})},84862:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(94029),s=t(16332),l=t(46571).IteratorPrototype,d=t(20547),f=t(7157),v=t(16697),y=d(function(){return u(this.next,this.iterator)},!0);o({target:"Iterator",stat:!0,forced:v},{from:function(g){var S=f(typeof g=="string"?a(g):g,!0);return s(l,S.iterator)?S.iterator:new y(S)}})},92381:function(c,h,t){"use strict";var o=t(94488),u=t(24771);o({target:"Iterator",proto:!0,real:!0,forced:!0},{indexed:u})},19517:function(c,h,t){"use strict";var o=t(94488),u=t(2155),a=t(16697);o({target:"Iterator",proto:!0,real:!0,forced:a},{map:u})},69667:function(c,h,t){"use strict";var o=t(94488),u=t(17243),a=TypeError;o({target:"Iterator",stat:!0,forced:!0},{range:function(l,d,f){if(typeof l=="number")return new u(l,d,f,"number",0,1);if(typeof l=="bigint")return new u(l,d,f,"bigint",BigInt(0),BigInt(1));throw new a("Incorrect Iterator.range arguments")}})},80820:function(c,h,t){"use strict";var o=t(94488),u=t(62003),a=t(63335),s=t(80449),l=t(10731),d=TypeError;o({target:"Iterator",proto:!0,real:!0},{reduce:function(v){s(this),a(v);var y=l(this),m=arguments.length<2,g=m?void 0:arguments[1],S=0;if(u(y,function(E){m?(m=!1,g=E):g=v(g,E,S),S++},{IS_RECORD:!0}),m)throw new d("Reduce of empty iterator with no initial value");return g}})},87873:function(c,h,t){"use strict";var o=t(94488),u=t(62003),a=t(63335),s=t(80449),l=t(10731);o({target:"Iterator",proto:!0,real:!0},{some:function(f){s(this),a(f);var v=l(this),y=0;return u(v,function(m,g){if(f(m,y++))return g()},{IS_RECORD:!0,INTERRUPTED:!0}).stopped}})},54609:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(80449),s=t(10731),l=t(2279),d=t(51358),f=t(20547),v=t(67996),y=t(16697),m=f(function(){var g=this.iterator;if(!this.remaining--)return this.done=!0,v(g,"normal",void 0);var S=a(u(this.next,g)),E=this.done=!!S.done;if(!E)return S.value});o({target:"Iterator",proto:!0,real:!0,forced:y},{take:function(S){a(this);var E=d(l(+S));return new m(s(this),{remaining:E})}})},28566:function(c,h,t){"use strict";var o=t(94488),u=t(80449),a=t(62003),s=t(10731),l=[].push;o({target:"Iterator",proto:!0,real:!0},{toArray:function(){var f=[];return a(s(u(this)),l,{that:f,IS_RECORD:!0}),f}})},51697:function(c,h,t){"use strict";var o=t(94488),u=t(80449),a=t(57975),s=t(80025),l=t(10731),d=t(16697);o({target:"Iterator",proto:!0,real:!0,forced:d},{toAsync:function(){return new s(l(new a(l(u(this)))))}})},61872:function(c,h,t){"use strict";var o=t(94488),u=t(82778),a=t(83502);o({target:"JSON",stat:!0,forced:!u},{isRawJSON:a})},76077:function(c,h,t){"use strict";var o=t(94488),u=t(35454),a=t(92916),s=t(65911),l=t(94237),d=t(89945),f=t(55327),v=t(31946),y=t(18589),m=t(32621),g=t(69905),S=t(82762),E=t(69392),I=t(3338),w=t(70913),P=t(42820),A=a.JSON,M=a.Number,L=a.SyntaxError,F=A&&A.parse,C=s("Object","keys"),D=Object.getOwnPropertyDescriptor,U=l("".charAt),J=l("".slice),W=l(/./.exec),Z=l([].push),K=/^\d$/,ee=/^[1-9]$/,ne=/^(?:-|\d)$/,ie=/^[\t\n\r ]$/,se=0,te=1,$=function(k,z){k=g(k);var H=new T(k,0,""),re=H.parse(),ve=re.value,pe=H.skip(ie,re.end);if(pe1?arguments[1]:void 0);return s(f,function(y,m){if(!v(y,m,f))return!1},!0)!==!1}})},28220:function(c,h,t){"use strict";var o=t(94488),u=t(80666),a=t(42683),s=t(2786),l=t(95037),d=s.Map,f=s.set;o({target:"Map",proto:!0,real:!0,forced:!0},{filter:function(y){var m=a(this),g=u(y,arguments.length>1?arguments[1]:void 0),S=new d;return l(m,function(E,I){g(E,I,m)&&f(S,I,E)}),S}})},49350:function(c,h,t){"use strict";var o=t(94488),u=t(80666),a=t(42683),s=t(95037);o({target:"Map",proto:!0,real:!0,forced:!0},{findKey:function(d){var f=a(this),v=u(d,arguments.length>1?arguments[1]:void 0),y=s(f,function(m,g){if(v(m,g,f))return{key:g}},!0);return y&&y.key}})},62060:function(c,h,t){"use strict";var o=t(94488),u=t(80666),a=t(42683),s=t(95037);o({target:"Map",proto:!0,real:!0,forced:!0},{find:function(d){var f=a(this),v=u(d,arguments.length>1?arguments[1]:void 0),y=s(f,function(m,g){if(v(m,g,f))return{value:m}},!0);return y&&y.value}})},20126:function(c,h,t){"use strict";var o=t(94488),u=t(5370);o({target:"Map",stat:!0,forced:!0},{from:u})},18090:function(c,h,t){"use strict";var o=t(94488),u=t(88134),a=t(42683),s=t(95037);o({target:"Map",proto:!0,real:!0,forced:!0},{includes:function(d){return s(a(this),function(f){if(u(f,d))return!0},!0)===!0}})},14309:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(62003),s=t(55327),l=t(63335),d=t(2786).Map;o({target:"Map",stat:!0,forced:!0},{keyBy:function(v,y){var m=s(this)?this:d,g=new m;l(y);var S=l(g.set);return a(v,function(E){u(S,g,y(E),E)}),g}})},17822:function(c,h,t){"use strict";var o=t(94488),u=t(42683),a=t(95037);o({target:"Map",proto:!0,real:!0,forced:!0},{keyOf:function(l){var d=a(u(this),function(f,v){if(f===l)return{key:v}},!0);return d&&d.key}})},83543:function(c,h,t){"use strict";var o=t(94488),u=t(80666),a=t(42683),s=t(2786),l=t(95037),d=s.Map,f=s.set;o({target:"Map",proto:!0,real:!0,forced:!0},{mapKeys:function(y){var m=a(this),g=u(y,arguments.length>1?arguments[1]:void 0),S=new d;return l(m,function(E,I){f(S,g(E,I,m),E)}),S}})},13853:function(c,h,t){"use strict";var o=t(94488),u=t(80666),a=t(42683),s=t(2786),l=t(95037),d=s.Map,f=s.set;o({target:"Map",proto:!0,real:!0,forced:!0},{mapValues:function(y){var m=a(this),g=u(y,arguments.length>1?arguments[1]:void 0),S=new d;return l(m,function(E,I){f(S,I,g(E,I,m))}),S}})},25188:function(c,h,t){"use strict";var o=t(94488),u=t(42683),a=t(62003),s=t(2786).set;o({target:"Map",proto:!0,real:!0,arity:1,forced:!0},{merge:function(d){for(var f=u(this),v=arguments.length,y=0;y1?arguments[1]:void 0);return s(f,function(y,m){if(v(y,m,f))return!0},!0)===!0}})},8774:function(c,h,t){"use strict";var o=t(94488),u=t(14615);o({target:"Map",proto:!0,real:!0,name:"upsert",forced:!0},{updateOrInsert:u})},6736:function(c,h,t){"use strict";var o=t(94488),u=t(63335),a=t(42683),s=t(2786),l=TypeError,d=s.get,f=s.has,v=s.set;o({target:"Map",proto:!0,real:!0,forced:!0},{update:function(m,g){var S=a(this),E=arguments.length;u(g);var I=f(S,m);if(!I&&E<3)throw new l("Updating absent value");var w=I?d(S,m):u(E>2?arguments[2]:void 0)(m,S);return v(S,m,g(w,m,S)),S}})},94065:function(c,h,t){"use strict";var o=t(94488),u=t(14615);o({target:"Map",proto:!0,real:!0,forced:!0},{upsert:u})},93036:function(c,h,t){"use strict";var o=t(94488),u=Math.min,a=Math.max;o({target:"Math",stat:!0,forced:!0},{clamp:function(l,d,f){return u(f,a(d,l))}})},75708:function(c,h,t){"use strict";var o=t(94488);o({target:"Math",stat:!0,nonConfigurable:!0,nonWritable:!0},{DEG_PER_RAD:Math.PI/180})},84624:function(c,h,t){"use strict";var o=t(94488),u=180/Math.PI;o({target:"Math",stat:!0,forced:!0},{degrees:function(s){return s*u}})},43710:function(c,h,t){"use strict";var o=t(94488),u=t(35175);o({target:"Math",stat:!0},{f16round:u})},66233:function(c,h,t){"use strict";var o=t(94488),u=t(24619),a=t(14894);o({target:"Math",stat:!0,forced:!0},{fscale:function(l,d,f,v,y){return a(u(l,d,f,v,y))}})},92762:function(c,h,t){"use strict";var o=t(94488);o({target:"Math",stat:!0,forced:!0},{iaddh:function(a,s,l,d){var f=a>>>0,v=s>>>0,y=l>>>0;return v+(d>>>0)+((f&y|(f|y)&~(f+y>>>0))>>>31)|0}})},24467:function(c,h,t){"use strict";var o=t(94488);o({target:"Math",stat:!0,forced:!0},{imulh:function(a,s){var l=65535,d=+a,f=+s,v=d&l,y=f&l,m=d>>16,g=f>>16,S=(m*y>>>0)+(v*y>>>16);return m*g+(S>>16)+((v*g>>>0)+(S&l)>>16)}})},68465:function(c,h,t){"use strict";var o=t(94488);o({target:"Math",stat:!0,forced:!0},{isubh:function(a,s,l,d){var f=a>>>0,v=s>>>0,y=l>>>0;return v-(d>>>0)-((~f&y|~(f^y)&f-y>>>0)>>>31)|0}})},77004:function(c,h,t){"use strict";var o=t(94488);o({target:"Math",stat:!0,nonConfigurable:!0,nonWritable:!0},{RAD_PER_DEG:180/Math.PI})},83925:function(c,h,t){"use strict";var o=t(94488),u=Math.PI/180;o({target:"Math",stat:!0,forced:!0},{radians:function(s){return s*u}})},51117:function(c,h,t){"use strict";var o=t(94488),u=t(24619);o({target:"Math",stat:!0,forced:!0},{scale:u})},87236:function(c,h,t){"use strict";var o=t(94488),u=t(80449),a=t(1222),s=t(83126),l=t(25587),d=t(94844),f="Seeded Random",v=f+" Generator",y='Math.seededPRNG() argument should have a "seed" field with a finite value.',m=d.set,g=d.getterFor(v),S=TypeError,E=s(function(w){m(this,{type:v,seed:w%2147483647})},f,function(){var w=g(this),P=w.seed=(w.seed*1103515245+12345)%2147483647;return l((P&1073741823)/1073741823,!1)});o({target:"Math",stat:!0,forced:!0},{seededPRNG:function(w){var P=u(w).seed;if(!a(P))throw new S(y);return new E(P)}})},83733:function(c,h,t){"use strict";var o=t(94488);o({target:"Math",stat:!0,forced:!0},{signbit:function(a){var s=+a;return s===s&&s===0?1/s===-1/0:s<0}})},92044:function(c,h,t){"use strict";var o=t(94488);o({target:"Math",stat:!0,forced:!0},{umulh:function(a,s){var l=65535,d=+a,f=+s,v=d&l,y=f&l,m=d>>>16,g=f>>>16,S=(m*y>>>0)+(v*y>>>16);return m*g+(S>>>16)+((v*g>>>0)+(S&l)>>>16)}})},29190:function(c,h,t){"use strict";var o=t(94488),u=t(94237),a=t(56902),s="Invalid number representation",l="Invalid radix",d=RangeError,f=SyntaxError,v=TypeError,y=parseInt,m=Math.pow,g=/^[\d.a-z]+$/,S=u("".charAt),E=u(g.exec),I=u(1 .toString),w=u("".slice),P=u("".split);o({target:"Number",stat:!0,forced:!0},{fromString:function(M,L){var F=1;if(typeof M!="string")throw new v(s);if(!M.length)throw new f(s);if(S(M,0)==="-"&&(F=-1,M=w(M,1),!M.length))throw new f(s);var C=L===void 0?10:a(L);if(C<2||C>36)throw new d(l);if(!E(g,M))throw new f(s);var D=P(M,"."),U=y(D[0],C);if(D.length>1&&(U+=y(D[1],C)/m(C,D[1].length)),C===10&&I(U,C)!==M)throw new f(s);return F*U}})},10775:function(c,h,t){"use strict";var o=t(94488),u=t(17243);o({target:"Number",stat:!0,forced:!0},{range:function(s,l,d){return new u(s,l,d,"number",0,1)}})},19593:function(c,h,t){"use strict";var o=t(94488),u=t(20574);o({target:"Object",stat:!0,forced:!0},{iterateEntries:function(s){return new u(s,"entries")}})},26502:function(c,h,t){"use strict";var o=t(94488),u=t(20574);o({target:"Object",stat:!0,forced:!0},{iterateKeys:function(s){return new u(s,"keys")}})},10174:function(c,h,t){"use strict";var o=t(94488),u=t(20574);o({target:"Object",stat:!0,forced:!0},{iterateValues:function(s){return new u(s,"values")}})},76867:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(35454),s=t(51996),l=t(63335),d=t(80449),f=t(56472),v=t(55327),y=t(4112),m=t(31946),g=t(53776),S=t(2291),E=t(66477),I=t(64110),w=t(61810),P=t(59893),A=t(94844),M=P("observable"),L="Observable",F="Subscription",C="SubscriptionObserver",D=A.getterFor,U=A.set,J=D(L),W=D(F),Z=D(C),K=function(te){this.observer=d(te),this.cleanup=void 0,this.subscriptionObserver=void 0};K.prototype={type:F,clean:function(){var te=this.cleanup;if(te){this.cleanup=void 0;try{te()}catch($){w($)}}},close:function(){if(!a){var te=this.facade,$=this.subscriptionObserver;te.closed=!0,$&&($.closed=!0)}this.observer=void 0},isClosed:function(){return this.observer===void 0}};var ee=function(te,$){var N=U(this,new K(te)),j;a||(this.closed=!1);try{(j=g(te,"start"))&&u(j,te,this)}catch(oe){w(oe)}if(!N.isClosed()){var O=N.subscriptionObserver=new ne(N);try{var T=$(O),Y=T;y(T)||(N.cleanup=v(T.unsubscribe)?function(){Y.unsubscribe()}:l(T))}catch(oe){O.error(oe);return}N.isClosed()&&N.clean()}};ee.prototype=E({},{unsubscribe:function(){var $=W(this);$.isClosed()||($.close(),$.clean())}}),a&&I(ee.prototype,"closed",{configurable:!0,get:function(){return W(this).isClosed()}});var ne=function(te){U(this,{type:C,subscriptionState:te}),a||(this.closed=!1)};ne.prototype=E({},{next:function($){var N=Z(this).subscriptionState;if(!N.isClosed()){var j=N.observer;try{var O=g(j,"next");O&&u(O,j,$)}catch(T){w(T)}}},error:function($){var N=Z(this).subscriptionState;if(!N.isClosed()){var j=N.observer;N.close();try{var O=g(j,"error");O?u(O,j,$):w($)}catch(T){w(T)}N.clean()}},complete:function(){var $=Z(this).subscriptionState;if(!$.isClosed()){var N=$.observer;$.close();try{var j=g(N,"complete");j&&u(j,N)}catch(O){w(O)}$.clean()}}}),a&&I(ne.prototype,"closed",{configurable:!0,get:function(){return Z(this).subscriptionState.isClosed()}});var ie=function($){f(this,se),U(this,{type:L,subscriber:l($)})},se=ie.prototype;E(se,{subscribe:function($){var N=arguments.length;return new ee(v($)?{next:$,error:N>1?arguments[1]:void 0,complete:N>2?arguments[2]:void 0}:m($)?$:{},J(this).subscriber)}}),S(se,M,function(){return this}),o({global:!0,constructor:!0,forced:!0},{Observable:ie}),s(L)},14548:function(c,h,t){"use strict";var o=t(94488),u=t(65911),a=t(89945),s=t(80449),l=t(39812),d=t(85428),f=t(53776),v=t(62003),y=t(59893),m=y("observable");o({target:"Observable",stat:!0,forced:!0},{from:function(S){var E=l(this)?this:u("Observable"),I=f(s(S),m);if(I){var w=s(a(I,S));return w.constructor===E?w:new E(function(A){return w.subscribe(A)})}var P=d(S);return new E(function(A){v(P,function(M,L){if(A.next(M),A.closed)return L()},{IS_ITERATOR:!0,INTERRUPTED:!0}),A.complete()})}})},96378:function(c,h,t){"use strict";t(76867),t(14548),t(6053)},6053:function(c,h,t){"use strict";var o=t(94488),u=t(65911),a=t(39812),s=u("Array");o({target:"Observable",stat:!0,forced:!0},{of:function(){for(var d=a(this)?this:u("Observable"),f=arguments.length,v=s(f),y=0;y?@[\\\\\\]^`{|}~"+s+"]","g");o({target:"RegExp",stat:!0,forced:!0},{escape:function(y){var m=a(y),g=l(m,0);return(g>47&&g<58?"\\x3":"")+d(m,f,"\\$&")}})},1220:function(c,h,t){"use strict";var o=t(94488),u=t(17442),a=t(19691).add;o({target:"Set",proto:!0,real:!0,forced:!0},{addAll:function(){for(var l=u(this),d=0,f=arguments.length;d1?arguments[1]:void 0);return s(f,function(y){if(!v(y,y,f))return!1},!0)!==!1}})},38487:function(c,h,t){"use strict";var o=t(94488),u=t(80666),a=t(17442),s=t(19691),l=t(57002),d=s.Set,f=s.add;o({target:"Set",proto:!0,real:!0,forced:!0},{filter:function(y){var m=a(this),g=u(y,arguments.length>1?arguments[1]:void 0),S=new d;return l(m,function(E){g(E,E,m)&&f(S,E)}),S}})},29916:function(c,h,t){"use strict";var o=t(94488),u=t(80666),a=t(17442),s=t(57002);o({target:"Set",proto:!0,real:!0,forced:!0},{find:function(d){var f=a(this),v=u(d,arguments.length>1?arguments[1]:void 0),y=s(f,function(m){if(v(m,m,f))return{value:m}},!0);return y&&y.value}})},25541:function(c,h,t){"use strict";var o=t(94488),u=t(5370);o({target:"Set",stat:!0,forced:!0},{from:u})},34926:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(77999),s=t(16049);o({target:"Set",proto:!0,real:!0,forced:!0},{intersection:function(d){return u(s,this,a(d))}})},45612:function(c,h,t){"use strict";var o=t(94488),u=t(3338),a=t(16049),s=t(22627),l=!s("intersection")||u(function(){return Array.from(new Set([1,2,3]).intersection(new Set([3,2])))!=="3,2"});o({target:"Set",proto:!0,real:!0,forced:l},{intersection:a})},68255:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(77999),s=t(17616);o({target:"Set",proto:!0,real:!0,forced:!0},{isDisjointFrom:function(d){return u(s,this,a(d))}})},98080:function(c,h,t){"use strict";var o=t(94488),u=t(17616),a=t(22627);o({target:"Set",proto:!0,real:!0,forced:!a("isDisjointFrom")},{isDisjointFrom:u})},16450:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(77999),s=t(84833);o({target:"Set",proto:!0,real:!0,forced:!0},{isSubsetOf:function(d){return u(s,this,a(d))}})},96351:function(c,h,t){"use strict";var o=t(94488),u=t(84833),a=t(22627);o({target:"Set",proto:!0,real:!0,forced:!a("isSubsetOf")},{isSubsetOf:u})},86921:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(77999),s=t(51135);o({target:"Set",proto:!0,real:!0,forced:!0},{isSupersetOf:function(d){return u(s,this,a(d))}})},60244:function(c,h,t){"use strict";var o=t(94488),u=t(51135),a=t(22627);o({target:"Set",proto:!0,real:!0,forced:!a("isSupersetOf")},{isSupersetOf:u})},82928:function(c,h,t){"use strict";var o=t(94488),u=t(94237),a=t(17442),s=t(57002),l=t(69905),d=u([].join),f=u([].push);o({target:"Set",proto:!0,real:!0,forced:!0},{join:function(y){var m=a(this),g=y===void 0?",":l(y),S=[];return s(m,function(E){f(S,E)}),d(S,g)}})},42947:function(c,h,t){"use strict";var o=t(94488),u=t(80666),a=t(17442),s=t(19691),l=t(57002),d=s.Set,f=s.add;o({target:"Set",proto:!0,real:!0,forced:!0},{map:function(y){var m=a(this),g=u(y,arguments.length>1?arguments[1]:void 0),S=new d;return l(m,function(E){f(S,g(E,E,m))}),S}})},71568:function(c,h,t){"use strict";var o=t(94488),u=t(48800);o({target:"Set",stat:!0,forced:!0},{of:u})},94194:function(c,h,t){"use strict";var o=t(94488),u=t(63335),a=t(17442),s=t(57002),l=TypeError;o({target:"Set",proto:!0,real:!0,forced:!0},{reduce:function(f){var v=a(this),y=arguments.length<2,m=y?void 0:arguments[1];if(u(f),s(v,function(g){y?(y=!1,m=g):m=f(m,g,g,v)}),y)throw new l("Reduce of empty set with no initial value");return m}})},30556:function(c,h,t){"use strict";var o=t(94488),u=t(80666),a=t(17442),s=t(57002);o({target:"Set",proto:!0,real:!0,forced:!0},{some:function(d){var f=a(this),v=u(d,arguments.length>1?arguments[1]:void 0);return s(f,function(y){if(v(y,y,f))return!0},!0)===!0}})},93102:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(77999),s=t(36312);o({target:"Set",proto:!0,real:!0,forced:!0},{symmetricDifference:function(d){return u(s,this,a(d))}})},32100:function(c,h,t){"use strict";var o=t(94488),u=t(36312),a=t(22627);o({target:"Set",proto:!0,real:!0,forced:!a("symmetricDifference")},{symmetricDifference:u})},82074:function(c,h,t){"use strict";var o=t(94488),u=t(89945),a=t(77999),s=t(24667);o({target:"Set",proto:!0,real:!0,forced:!0},{union:function(d){return u(s,this,a(d))}})},1821:function(c,h,t){"use strict";var o=t(94488),u=t(24667),a=t(22627);o({target:"Set",proto:!0,real:!0,forced:!a("union")},{union:u})},13578:function(c,h,t){"use strict";var o=t(94488),u=t(13764).charAt,a=t(95955),s=t(56902),l=t(69905);o({target:"String",proto:!0,forced:!0},{at:function(f){var v=l(a(this)),y=v.length,m=s(f),g=m>=0?m:y+m;return g<0||g>=y?void 0:u(v,g)}})},62882:function(c,h,t){"use strict";var o=t(94488),u=t(83126),a=t(25587),s=t(95955),l=t(69905),d=t(94844),f=t(13764),v=f.codeAt,y=f.charAt,m="String Iterator",g=d.set,S=d.getterFor(m),E=u(function(w){g(this,{type:m,string:w,index:0})},"String",function(){var w=S(this),P=w.string,A=w.index,M;return A>=P.length?a(void 0,!0):(M=y(P,A),w.index+=M.length,a({codePoint:v(M,0),position:A},!1))});o({target:"String",proto:!0,forced:!0},{codePoints:function(){return new E(l(s(this)))}})},59348:function(c,h,t){"use strict";var o=t(94488),u=t(67410);o({target:"String",stat:!0,forced:!0},{cooked:u})},37457:function(c,h,t){"use strict";var o=t(13247),u=t(94488),a=t(86528),s=t(94237),l=t(13743),d=t(80449),f=t(94029),v=t(55327),y=t(82762),m=t(37691).f,g=t(71698),S=t(42530),E=t(67410),I=t(79204),w=t(19268),P=new S.WeakMap,A=S.get,M=S.has,L=S.set,F=Array,C=TypeError,D=Object.freeze||Object,U=Object.isFrozen,J=Math.min,W=s("".charAt),Z=s("".slice),K=s("".split),ee=s(/./.exec),ne=/([\n\u2028\u2029]|\r\n?)/g,ie=RegExp("^["+w+"]*"),se=RegExp("[^"+w+"]"),te="Invalid tag",$="Invalid opening line",N="Invalid closing line",j=function(z){var H=z.raw;if(o&&!U(H))throw new C("Raw template should be frozen");if(M(P,H))return A(P,H);var re=O(H),ve=Y(re);return m(ve,"raw",{value:D(re)}),D(ve),L(P,H,ve),ve},O=function(z){var H=f(z),re=y(H),ve=F(re),pe=F(re),Ce=0,Le,qe,$e,Ye;if(!re)throw new C(te);for(;Ce0)throw new C($);Le[1]=""}if(Ct){if(Le.length===1||ee(se,Le[Le.length-1]))throw new C(N);Le[Le.length-2]="",Le[Le.length-1]=""}for(var ct=2;ct1?arguments[1]:void 0);return a(this,v)},!0)},16315:function(c,h,t){"use strict";var o=t(58261),u=t(90560).filterReject,a=t(27607),s=o.aTypedArray,l=o.exportTypedArrayMethod;l("filterReject",function(f){var v=u(s(this),f,arguments.length>1?arguments[1]:void 0);return a(this,v)},!0)},56966:function(c,h,t){"use strict";var o=t(65911),u=t(6086),a=t(32278),s=t(58261),l=t(69478),d=s.aTypedArrayConstructor,f=s.exportTypedArrayStaticMethod;f("fromAsync",function(y){var m=this,g=arguments.length,S=g>1?arguments[1]:void 0,E=g>2?arguments[2]:void 0;return new(o("Promise"))(function(I){u(m),I(a(y,S,E))}).then(function(I){return l(d(m),I)})},!0)},60239:function(c,h,t){"use strict";var o=t(58261),u=t(36444),a=t(31384),s=o.aTypedArray,l=o.exportTypedArrayMethod;l("groupBy",function(f){var v=arguments.length>1?arguments[1]:void 0;return u(s(this),f,v,a)},!0)},49381:function(c,h,t){"use strict";var o=t(58261),u=t(82762),a=t(75406),s=t(51981),l=t(93303),d=t(56902),f=t(3338),v=o.aTypedArray,y=o.getTypedArrayConstructor,m=o.exportTypedArrayMethod,g=Math.max,S=Math.min,E=!f(function(){var I=new Int8Array([1]),w=I.toSpliced(1,0,{valueOf:function(){return I[0]=2,3}});return w[0]!==2||w[1]!==3});m("toSpliced",function(w,P){var A=v(this),M=y(A),L=u(A),F=s(w,L),C=arguments.length,D=0,U,J,W,Z,K,ee,ne;if(C===0)U=J=0;else if(C===1)U=0,J=L-F;else if(J=S(g(d(P),0),L-F),U=C-2,U){Z=new M(U),W=a(Z);for(var ie=2;ie1?s(arguments[1]):void 0,U=y(D)==="base64"?m:g,J=D?!!D.strict:!1,W=J?C:w(C,M,"");if(W.length%4===0)P(W,-2)==="=="?W=P(W,0,-2):P(W,-1)==="="&&(W=P(W,0,-1));else if(J)throw new E("Input is not correctly padded");var Z=W.length%4;switch(Z){case 1:throw new E("Bad input length");case 2:W+="AA";break;case 3:W+="A"}for(var K=[],ee=0,ne=W.length,ie=function($){var N=I(W,ee+$);if(!d(U,N))throw new E('Bad char in input: "'+N+'"');return U[N]<<18-6*$};ee>16&255,se>>8&255,se&255)}var te=K.length;if(Z===2){if(J&&K[te-2]!==0)throw new E(L);te-=2}else if(Z===3){if(J&&K[te-1]!==0)throw new E(L);te--}return f(S,K,te)}})},57151:function(c,h,t){"use strict";var o=t(94488),u=t(92916),a=t(94237),s=t(79606),l=u.Uint8Array,d=u.SyntaxError,f=u.parseInt,v=/[^\da-f]/i,y=a(v.exec),m=a("".slice);l&&o({target:"Uint8Array",stat:!0,forced:!0},{fromHex:function(S){s(S);var E=S.length;if(E%2)throw new d("String should have an even number of characters");if(y(v,S))throw new d("String should only contain hex characters");for(var I=new l(E/2),w=0;w>6*C&63)};A+21&&!m(arguments[1])?I(arguments[1]):void 0,Pe=Ee?Ee.transfer:void 0,Re,we;Pe!==void 0&&(Re=new j,we=at(Pe,Re));var Ze=Ue(le,Re);return we&&Ie(we),Ze}})},4890:function(c,h,t){"use strict";var o=t(2291),u=t(94237),a=t(69905),s=t(57106),l=URLSearchParams,d=l.prototype,f=u(d.append),v=u(d.delete),y=u(d.forEach),m=u([].push),g=new l("a=1&a=2&b=3");g.delete("a",1),g.delete("b",void 0),g+""!="a=2"&&o(d,"delete",function(S){var E=arguments.length,I=E<2?void 0:arguments[1];if(E&&I===void 0)return v(this,S);var w=[];y(this,function(U,J){m(w,{key:J,value:U})}),s(E,1);for(var P=a(S),A=a(I),M=0,L=0,F=!1,C=w.length,D;Ma.length)&&(s=a.length);for(var l=0,d=new Array(s);l0&&arguments[0]!==void 0?arguments[0]:"";return G.endsWith("/")?G:"".concat(G,"/")}function ir(G,q){if(G==null)return{};var ae={},_=Object.keys(G),he,Se;for(Se=0;Se<_.length;Se++)he=_[Se],!(q.indexOf(he)>=0)&&(ae[he]=G[he]);return ae}function An(G,q){if(G==null)return{};var ae=ir(G,q),_,he;if(Object.getOwnPropertySymbols){var Se=Object.getOwnPropertySymbols(G);for(he=0;he=0)&&Object.prototype.propertyIsEnumerable.call(G,_)&&(ae[_]=G[_])}return ae}function ua(){return ua=Object.assign?Object.assign.bind():function(G){for(var q=1;q0})),Te=sa({routesById:q,routeComponents:_,parentId:Se.id,loadingComponent:G.loadingComponent,reactRouter5Compat:G.reactRouter5Compat});return Te.length>0&&(Se.children=Te,Se.routes=Te),Se})}function ys(G){var q=(0,vr.UO)(),ae=(0,Ar.Z)((0,Ar.Z)({},G),{},{to:(0,vr.Gn)(G.to,q)});return Ge.createElement(vr.Fg,ua({replace:!0},ae))}function gs(G){var q=G.route,ae=q.redirect,_=An(q,Go),he=G.reactRouter5Compat?Za:Cn;return(0,Ar.Z)({element:ae?Ge.createElement(ys,{to:ae}):Ge.createElement(Qa.Provider,{value:{route:G.route}},Ge.createElement(he,{loader:Ge.memo(G.routeComponent),loadingComponent:G.loadingComponent||qr,hasChildren:G.hasChildren}))},_)}function qr(){return Ge.createElement("div",null)}function Za(G){var q=Ko(),ae=q.route,_=Xr(),he=_.history,Se=_.clientRoutes,Te=(0,vr.UO)(),Oe={params:Te,isExact:!0,path:ae.path,url:he.location.pathname},ze=G.loader;return Ge.createElement(Ge.Suspense,{fallback:Ge.createElement(G.loadingComponent,null)},Ge.createElement(ze,{location:he.location,match:Oe,history:he,params:Te,route:ae,routes:Se},G.hasChildren&&Ge.createElement(vr.j3,null)))}function Cn(G){var q=G.loader;return Ge.createElement(Ge.Suspense,{fallback:Ge.createElement(G.loadingComponent,null)},Ge.createElement(q,null))}var Rn=null;function ms(){return Rn}function ia(G){var q=G.history,ae=Ge.useState({action:q.action,location:q.location}),_=Jr(ae,2),he=_[0],Se=_[1];return(0,Ge.useLayoutEffect)(function(){return q.listen(Se)},[q]),(0,Ge.useLayoutEffect)(function(){function Te(Oe){G.pluginManager.applyPlugins({key:"onRouteChange",type:"event",args:{routes:G.routes,clientRoutes:G.clientRoutes,location:Oe.location,action:Oe.action,basename:G.basename,isFirst:!!Oe.isFirst}})}return Te({location:he.location,action:he.action,isFirst:!0}),q.listen(Te)},[q,G.routes,G.clientRoutes]),Ge.createElement(vr.F0,{navigator:q,location:he.location,basename:G.basename},G.children)}function _r(){var G=Xr(),q=G.clientRoutes;return(0,vr.V$)(q)}var Ja=["innerProvider","i18nProvider","accessProvider","dataflowProvider","outerProvider","rootContainer"],Yo=function(q,ae){var _=q.basename||"/",he=sa({routesById:q.routes,routeComponents:q.routeComponents,loadingComponent:q.loadingComponent,reactRouter5Compat:q.reactRouter5Compat});q.pluginManager.applyPlugins({key:"patchClientRoutes",type:"event",args:{routes:he}});for(var Se=Ge.createElement(ia,{basename:_,pluginManager:q.pluginManager,routes:q.routes,clientRoutes:he,history:q.history},ae),Te=0,Oe=Ja;Te=0||(he[ae]=G[ae]);return he}var He={BASE:"base",BODY:"body",HEAD:"head",HTML:"html",LINK:"link",META:"meta",NOSCRIPT:"noscript",SCRIPT:"script",STYLE:"style",TITLE:"title",FRAGMENT:"Symbol(react.fragment)"},ft={rel:["amphtml","canonical","alternate"]},eo={type:["application/ld+json"]},da={charset:"",name:["robots","description"],property:["og:type","og:title","og:url","og:image","og:image:alt","og:description","twitter:url","twitter:title","twitter:description","twitter:image","twitter:image:alt","twitter:card","twitter:site"]},en=Object.keys(He).map(function(G){return He[G]}),Pn={accesskey:"accessKey",charset:"charSet",class:"className",contenteditable:"contentEditable",contextmenu:"contextMenu","http-equiv":"httpEquiv",itemprop:"itemProp",tabindex:"tabIndex"},to=Object.keys(Pn).reduce(function(G,q){return G[Pn[q]]=q,G},{}),pr=function(G,q){for(var ae=G.length-1;ae>=0;ae-=1){var _=G[ae];if(Object.prototype.hasOwnProperty.call(_,q))return _[q]}return null},va=function(G){var q=pr(G,He.TITLE),ae=pr(G,"titleTemplate");if(Array.isArray(q)&&(q=q.join("")),ae&&q)return ae.replace(/%s/g,function(){return q});var _=pr(G,"defaultTitle");return q||_||void 0},tn=function(G){return pr(G,"onChangeClientState")||function(){}},pa=function(G,q){return q.filter(function(ae){return ae[G]!==void 0}).map(function(ae){return ae[G]}).reduce(function(ae,_){return St({},ae,_)},{})},Ss=function(G,q){return q.filter(function(ae){return ae[He.BASE]!==void 0}).map(function(ae){return ae[He.BASE]}).reverse().reduce(function(ae,_){if(!ae.length)for(var he=Object.keys(_),Se=0;Se/g,">").replace(/"/g,""").replace(/'/g,"'")},ya=function(G){return Object.keys(G).reduce(function(q,ae){var _=G[ae]!==void 0?ae+'="'+G[ae]+'"':""+ae;return q?q+" "+_:_},"")},_o=function(G,q){return q===void 0&&(q={}),Object.keys(G).reduce(function(ae,_){return ae[Pn[_]||_]=G[_],ae},q)},jn=function(G,q){return q.map(function(ae,_){var he,Se=((he={key:_})["data-rh"]=!0,he);return Object.keys(ae).forEach(function(Te){var Oe=Pn[Te]||Te;Oe==="innerHTML"||Oe==="cssText"?Se.dangerouslySetInnerHTML={__html:ae.innerHTML||ae.cssText}:Se[Oe]=ae[Te]}),Ge.createElement(G,Se)})},tr=function(G,q,ae){switch(G){case He.TITLE:return{toComponent:function(){return he=q.titleAttributes,(Se={key:_=q.title})["data-rh"]=!0,Te=_o(he,Se),[Ge.createElement(He.TITLE,Te,_)];var _,he,Se,Te},toString:function(){return function(_,he,Se,Te){var Oe=ya(Se),ze=Nn(he);return Oe?"<"+_+' data-rh="true" '+Oe+">"+Ln(ze,Te)+"":"<"+_+' data-rh="true">'+Ln(ze,Te)+""}(G,q.title,q.titleAttributes,ae)}};case"bodyAttributes":case"htmlAttributes":return{toComponent:function(){return _o(q)},toString:function(){return ya(q)}};default:return{toComponent:function(){return jn(G,q)},toString:function(){return function(_,he,Se){return he.reduce(function(Te,Oe){var ze=Object.keys(Oe).filter(function(nt){return!(nt==="innerHTML"||nt==="cssText")}).reduce(function(nt,_e){var gt=Oe[_e]===void 0?_e:_e+'="'+Ln(Oe[_e],Se)+'"';return nt?nt+" "+gt:gt},""),We=Oe.innerHTML||Oe.cssText||"",tt=ro.indexOf(_)===-1;return Te+"<"+_+' data-rh="true" '+ze+(tt?"/>":">"+We+"")},"")}(G,q,ae)}}}},no=function(G){var q=G.baseTag,ae=G.bodyAttributes,_=G.encode,he=G.htmlAttributes,Se=G.noscriptTags,Te=G.styleTags,Oe=G.title,ze=Oe===void 0?"":Oe,We=G.titleAttributes,tt=G.linkTags,nt=G.metaTags,_e=G.scriptTags,gt={toComponent:function(){},toString:function(){return""}};if(G.prioritizeSeoTags){var wt=function(pt){var Ft=pt.linkTags,Kt=pt.scriptTags,Pt=pt.encode,Lt=rn(pt.metaTags,da),Gt=rn(Ft,ft),Vr=rn(Kt,eo);return{priorityMethods:{toComponent:function(){return[].concat(jn(He.META,Lt.priority),jn(He.LINK,Gt.priority),jn(He.SCRIPT,Vr.priority))},toString:function(){return tr(He.META,Lt.priority,Pt)+" "+tr(He.LINK,Gt.priority,Pt)+" "+tr(He.SCRIPT,Vr.priority,Pt)}},metaTags:Lt.default,linkTags:Gt.default,scriptTags:Vr.default}}(G);gt=wt.priorityMethods,tt=wt.linkTags,nt=wt.metaTags,_e=wt.scriptTags}return{priority:gt,base:tr(He.BASE,q,_),bodyAttributes:tr("bodyAttributes",ae,_),htmlAttributes:tr("htmlAttributes",he,_),link:tr(He.LINK,tt,_),meta:tr(He.META,nt,_),noscript:tr(He.NOSCRIPT,Se,_),script:tr(He.SCRIPT,_e,_),style:tr(He.STYLE,Te,_),title:tr(He.TITLE,{title:ze,titleAttributes:We},_)}},nn=[],lr=function(G,q){var ae=this;q===void 0&&(q=typeof document!="undefined"),this.instances=[],this.value={setHelmet:function(_){ae.context.helmet=_},helmetInstances:{get:function(){return ae.canUseDOM?nn:ae.instances},add:function(_){(ae.canUseDOM?nn:ae.instances).push(_)},remove:function(_){var he=(ae.canUseDOM?nn:ae.instances).indexOf(_);(ae.canUseDOM?nn:ae.instances).splice(he,1)}}},this.context=G,this.canUseDOM=q,q||(G.helmet=no({baseTag:[],bodyAttributes:{},encodeSpecialCharacters:!0,htmlAttributes:{},linkTags:[],metaTags:[],noscriptTags:[],scriptTags:[],styleTags:[],title:"",titleAttributes:{}}))},ao=Ge.createContext({}),an=rt().shape({setHelmet:rt().func,helmetInstances:rt().shape({get:rt().func,add:rt().func,remove:rt().func})}),hr=typeof document!="undefined",yr=function(G){function q(ae){var _;return(_=G.call(this,ae)||this).helmetData=new lr(_.props.context,q.canUseDOM),_}return Hr(q,G),q.prototype.render=function(){return Ge.createElement(ao.Provider,{value:this.helmetData.value},this.props.children)},q}(Ge.Component);yr.canUseDOM=hr,yr.propTypes={context:rt().shape({helmet:rt().shape()}),children:rt().node.isRequired},yr.defaultProps={context:{}},yr.displayName="HelmetProvider";var Wt=function(G,q){var ae,_=document.head||document.querySelector(He.HEAD),he=_.querySelectorAll(G+"[data-rh]"),Se=[].slice.call(he),Te=[];return q&&q.length&&q.forEach(function(Oe){var ze=document.createElement(G);for(var We in Oe)Object.prototype.hasOwnProperty.call(Oe,We)&&(We==="innerHTML"?ze.innerHTML=Oe.innerHTML:We==="cssText"?ze.styleSheet?ze.styleSheet.cssText=Oe.cssText:ze.appendChild(document.createTextNode(Oe.cssText)):ze.setAttribute(We,Oe[We]===void 0?"":Oe[We]));ze.setAttribute("data-rh","true"),Se.some(function(tt,nt){return ae=nt,ze.isEqualNode(tt)})?Se.splice(ae,1):Te.push(ze)}),Se.forEach(function(Oe){return Oe.parentNode.removeChild(Oe)}),Te.forEach(function(Oe){return _.appendChild(Oe)}),{oldTags:Se,newTags:Te}},Dn=function(G,q){var ae=document.getElementsByTagName(G)[0];if(ae){for(var _=ae.getAttribute("data-rh"),he=_?_.split(","):[],Se=[].concat(he),Te=Object.keys(q),Oe=0;Oe=0;nt-=1)ae.removeAttribute(Se[nt]);he.length===Se.length?ae.removeAttribute("data-rh"):ae.getAttribute("data-rh")!==Te.join(",")&&ae.setAttribute("data-rh",Te.join(","))}},eu=function(G,q){var ae=G.baseTag,_=G.htmlAttributes,he=G.linkTags,Se=G.metaTags,Te=G.noscriptTags,Oe=G.onChangeClientState,ze=G.scriptTags,We=G.styleTags,tt=G.title,nt=G.titleAttributes;Dn(He.BODY,G.bodyAttributes),Dn(He.HTML,_),function(pt,Ft){pt!==void 0&&document.title!==pt&&(document.title=Nn(pt)),Dn(He.TITLE,Ft)}(tt,nt);var _e={baseTag:Wt(He.BASE,ae),linkTags:Wt(He.LINK,he),metaTags:Wt(He.META,Se),noscriptTags:Wt(He.NOSCRIPT,Te),scriptTags:Wt(He.SCRIPT,ze),styleTags:Wt(He.STYLE,We)},gt={},wt={};Object.keys(_e).forEach(function(pt){var Ft=_e[pt],Kt=Ft.newTags,Pt=Ft.oldTags;Kt.length&&(gt[pt]=Kt),Pt.length&&(wt[pt]=_e[pt].oldTags)}),q&&q(),Oe(G,gt,wt)},$n=null,gr=function(G){function q(){for(var _,he=arguments.length,Se=new Array(he),Te=0;Te elements are self-closing and can not contain children. Refer to our API for more information.")}},ae.flattenArrayTypeChildren=function(_){var he,Se=_.child,Te=_.arrayTypeChildren;return St({},Te,((he={})[Se.type]=[].concat(Te[Se.type]||[],[St({},_.newChildProps,this.mapNestedChildrenToProps(Se,_.nestedChildren))]),he))},ae.mapObjectTypeChildren=function(_){var he,Se,Te=_.child,Oe=_.newProps,ze=_.newChildProps,We=_.nestedChildren;switch(Te.type){case He.TITLE:return St({},Oe,((he={})[Te.type]=We,he.titleAttributes=St({},ze),he));case He.BODY:return St({},Oe,{bodyAttributes:St({},ze)});case He.HTML:return St({},Oe,{htmlAttributes:St({},ze)});default:return St({},Oe,((Se={})[Te.type]=St({},ze),Se))}},ae.mapArrayTypeChildrenToProps=function(_,he){var Se=St({},he);return Object.keys(_).forEach(function(Te){var Oe;Se=St({},Se,((Oe={})[Te]=_[Te],Oe))}),Se},ae.warnOnInvalidChildren=function(_,he){return fa()(en.some(function(Se){return _.type===Se}),typeof _.type=="function"?"You may be attempting to nest components within each other, which is not allowed. Refer to our API for more information.":"Only elements types "+en.join(", ")+" are allowed. Helmet does not support rendering <"+_.type+"> elements. Refer to our API for more information."),fa()(!he||typeof he=="string"||Array.isArray(he)&&!he.some(function(Se){return typeof Se!="string"}),"Helmet expects a string as a child of <"+_.type+">. Did you forget to wrap your children in braces? ( <"+_.type+">{``} ) Refer to our API for more information."),!0},ae.mapChildrenToProps=function(_,he){var Se=this,Te={};return Ge.Children.forEach(_,function(Oe){if(Oe&&Oe.props){var ze=Oe.props,We=ze.children,tt=_a(ze,Fn),nt=Object.keys(tt).reduce(function(gt,wt){return gt[to[wt]||wt]=tt[wt],gt},{}),_e=Oe.type;switch(typeof _e=="symbol"?_e=_e.toString():Se.warnOnInvalidChildren(Oe,We),_e){case He.FRAGMENT:he=Se.mapChildrenToProps(We,he);break;case He.LINK:case He.META:case He.NOSCRIPT:case He.SCRIPT:case He.STYLE:Te=Se.flattenArrayTypeChildren({child:Oe,arrayTypeChildren:Te,newChildProps:nt,nestedChildren:We});break;default:he=Se.mapObjectTypeChildren({child:Oe,newProps:he,newChildProps:nt,nestedChildren:We})}}}),this.mapArrayTypeChildrenToProps(Te,he)},ae.render=function(){var _=this.props,he=_.children,Se=_a(_,on),Te=St({},Se),Oe=Se.helmetData;return he&&(Te=this.mapChildrenToProps(he,Te)),!Oe||Oe instanceof lr||(Oe=new lr(Oe.context,Oe.instances)),Oe?Ge.createElement(gr,St({},Te,{context:Oe.value,helmetData:void 0})):Ge.createElement(ao.Consumer,null,function(ze){return Ge.createElement(gr,St({},Te,{context:ze}))})},q}(Ge.Component);un.propTypes={base:rt().object,bodyAttributes:rt().object,children:rt().oneOfType([rt().arrayOf(rt().node),rt().node]),defaultTitle:rt().string,defer:rt().bool,encodeSpecialCharacters:rt().bool,htmlAttributes:rt().object,link:rt().arrayOf(rt().object),meta:rt().arrayOf(rt().object),noscript:rt().arrayOf(rt().object),onChangeClientState:rt().func,script:rt().arrayOf(rt().object),style:rt().arrayOf(rt().object),title:rt().string,titleAttributes:rt().object,titleTemplate:rt().string,prioritizeSeoTags:rt().bool,helmetData:rt().object},un.defaultProps={defer:!0,encodeSpecialCharacters:!0,prioritizeSeoTags:!1},un.displayName="Helmet";var oo={},sn=function(q){return Ge.createElement(yr,{context:oo},q)},rr=B(49504);function vt(G){return G.default?typeof G.default=="function"?G.default():G.default:G}function lt(){return[{apply:c,path:void 0}]}function jr(){return["patchRoutes","patchClientRoutes","modifyContextOpts","modifyClientRenderOpts","rootContainer","innerProvider","i18nProvider","accessProvider","dataflowProvider","outerProvider","render","onRouteChange"]}var Rt=null;function Ht(){return Rt=rr.Q$.create({plugins:lt(),validKeys:jr()}),Rt}function ln(){return Rt}var cn=B(45906),Vt="/weather/",ga=!1;function tu(){return ma.apply(this,arguments)}function ma(){return ma=s()(t()().mark(function G(){var q,ae,_,he,Se,Te,Oe,ze;return t()().wrap(function(tt){for(;;)switch(tt.prev=tt.next){case 0:return q=Ht(),tt.next=3,Qo(q);case 3:return ae=tt.sent,_=ae.routes,he=ae.routeComponents,tt.next=8,q.applyPlugins({key:"patchRoutes",type:rr.Ac.event,args:{routes:_,routeComponents:he}});case 8:return Se=q.applyPlugins({key:"modifyContextOpts",type:rr.Ac.modify,initialValue:{}}),Te=Se.basename||"/weather",Oe=Se.historyType||"browser",ze=(0,cn.f)(u()({type:Oe,basename:Te},Se.historyOpts)),tt.abrupt("return",q.applyPlugins({key:"render",type:rr.Ac.compose,initialValue:function(){var _e={routes:_,routeComponents:he,pluginManager:q,rootElement:Se.rootElement||document.getElementById("root"),publicPath:Vt,runtimePublicPath:ga,history:ze,historyType:Oe,basename:Te,callback:Se.callback},gt=q.applyPlugins({key:"modifyClientRenderOpts",type:rr.Ac.modify,initialValue:_e});return la(gt)}})());case 13:case"end":return tt.stop()}},G)})),ma.apply(this,arguments)}tu(),window.g_umi={version:"4.1.1"}})()})();