rk-web-core 0.7.83 → 0.7.85

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/rk-web-core.js CHANGED
@@ -1,4 +1,4 @@
1
- !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define("rk-web-core",[],e):"object"==typeof exports?exports["rk-web-core"]=e():t["rk-web-core"]=e()}(window,(function(){return function(t){function e(e){for(var n,r,i=e[0],o=e[1],a=0,s=[];a<i.length;a++)r=i[a],Object.prototype.hasOwnProperty.call(O,r)&&O[r]&&s.push(O[r][0]),O[r]=0;for(n in o)Object.prototype.hasOwnProperty.call(o,n)&&(t[n]=o[n]);for(j&&j(e);s.length;)s.shift()()}var n=window.webpackHotUpdaterk_web_core;window.webpackHotUpdaterk_web_core=function(t,e){!function(t,e){if(!w[t]||!b[t])return;for(var n in b[t]=!1,e)Object.prototype.hasOwnProperty.call(e,n)&&(m[n]=e[n]);0==--y&&0===_&&E()}(t,e),n&&n(t,e)};var r,i=!0,o="9fef31e2cdbbe2f28cb8",a={},s=[],u=[];function c(t){var e=L[t];if(!e)return R;var n=function(n){return e.hot.active?(L[n]?-1===L[n].parents.indexOf(t)&&L[n].parents.push(t):(s=[t],r=n),-1===e.children.indexOf(n)&&e.children.push(n)):(console.warn("[HMR] unexpected require("+n+") from disposed module "+t),s=[]),R(n)},i=function(t){return{configurable:!0,enumerable:!0,get:function(){return R[t]},set:function(e){R[t]=e}}};for(var o in R)Object.prototype.hasOwnProperty.call(R,o)&&"e"!==o&&"t"!==o&&Object.defineProperty(n,o,i(o));return n.e=function(t){return"ready"===f&&d("prepare"),_++,R.e(t).then(e,(function(t){throw e(),t}));function e(){_--,"prepare"===f&&(x[t]||T(t),0===_&&0===y&&E())}},n.t=function(t,e){return 1&e&&(t=n(t)),R.t(t,-2&e)},n}function l(e){var n={_acceptedDependencies:{},_declinedDependencies:{},_selfAccepted:!1,_selfDeclined:!1,_selfInvalidated:!1,_disposeHandlers:[],_main:r!==e,active:!0,accept:function(t,e){if(void 0===t)n._selfAccepted=!0;else if("function"==typeof t)n._selfAccepted=t;else if("object"==typeof t)for(var r=0;r<t.length;r++)n._acceptedDependencies[t[r]]=e||function(){};else n._acceptedDependencies[t]=e||function(){}},decline:function(t){if(void 0===t)n._selfDeclined=!0;else if("object"==typeof t)for(var e=0;e<t.length;e++)n._declinedDependencies[t[e]]=!0;else n._declinedDependencies[t]=!0},dispose:function(t){n._disposeHandlers.push(t)},addDisposeHandler:function(t){n._disposeHandlers.push(t)},removeDisposeHandler:function(t){var e=n._disposeHandlers.indexOf(t);e>=0&&n._disposeHandlers.splice(e,1)},invalidate:function(){switch(this._selfInvalidated=!0,f){case"idle":(m={})[e]=t[e],d("ready");break;case"ready":P(e);break;case"prepare":case"check":case"dispose":case"apply":(v=v||[]).push(e)}},check:S,apply:A,status:function(t){if(!t)return f;h.push(t)},addStatusHandler:function(t){h.push(t)},removeStatusHandler:function(t){var e=h.indexOf(t);e>=0&&h.splice(e,1)},data:a[e]};return r=void 0,n}var h=[],f="idle";function d(t){f=t;for(var e=0;e<h.length;e++)h[e].call(null,t)}var p,m,g,v,y=0,_=0,x={},b={},w={};function M(t){return+t+""===t?+t:t}function S(t){if("idle"!==f)throw new Error("check() is only allowed in idle status");return i=t,d("check"),(e=1e4,e=e||1e4,new Promise((function(t,n){if("undefined"==typeof XMLHttpRequest)return n(new Error("No browser support"));try{var r=new XMLHttpRequest,i=R.p+""+o+".hot-update.json";r.open("GET",i,!0),r.timeout=e,r.send(null)}catch(t){return n(t)}r.onreadystatechange=function(){if(4===r.readyState)if(0===r.status)n(new Error("Manifest request to "+i+" timed out."));else if(404===r.status)t();else if(200!==r.status&&304!==r.status)n(new Error("Manifest request to "+i+" failed."));else{try{var e=JSON.parse(r.responseText)}catch(t){return void n(t)}t(e)}}}))).then((function(t){if(!t)return d(C()?"ready":"idle"),null;b={},x={},w=t.c,g=t.h,d("prepare");var e=new Promise((function(t,e){p={resolve:t,reject:e}}));for(var n in m={},O)T(n);return"prepare"===f&&0===_&&0===y&&E(),e}));var e}function T(t){w[t]?(b[t]=!0,y++,function(t){var e=document.createElement("script");e.charset="utf-8",e.src=R.p+""+t+"."+o+".hot-update.js",e.crossOrigin="anonymous",document.head.appendChild(e)}(t)):x[t]=!0}function E(){d("ready");var t=p;if(p=null,t)if(i)Promise.resolve().then((function(){return A(i)})).then((function(e){t.resolve(e)}),(function(e){t.reject(e)}));else{var e=[];for(var n in m)Object.prototype.hasOwnProperty.call(m,n)&&e.push(M(n));t.resolve(e)}}function A(e){if("ready"!==f)throw new Error("apply() is only allowed in ready status");return function e(n){var i,u,c,l,h;function f(t){for(var e=[t],n={},r=e.map((function(t){return{chain:[t],id:t}}));r.length>0;){var i=r.pop(),o=i.id,a=i.chain;if((l=L[o])&&(!l.hot._selfAccepted||l.hot._selfInvalidated)){if(l.hot._selfDeclined)return{type:"self-declined",chain:a,moduleId:o};if(l.hot._main)return{type:"unaccepted",chain:a,moduleId:o};for(var s=0;s<l.parents.length;s++){var u=l.parents[s],c=L[u];if(c){if(c.hot._declinedDependencies[o])return{type:"declined",chain:a.concat([u]),moduleId:o,parentId:u};-1===e.indexOf(u)&&(c.hot._acceptedDependencies[o]?(n[u]||(n[u]=[]),p(n[u],[o])):(delete n[u],e.push(u),r.push({chain:a.concat([u]),id:u})))}}}}return{type:"accepted",moduleId:t,outdatedModules:e,outdatedDependencies:n}}function p(t,e){for(var n=0;n<e.length;n++){var r=e[n];-1===t.indexOf(r)&&t.push(r)}}C();var y={},_=[],x={},b=function(){console.warn("[HMR] unexpected require("+T.moduleId+") to disposed module")};for(var S in m)if(Object.prototype.hasOwnProperty.call(m,S)){var T;h=M(S),T=m[S]?f(h):{type:"disposed",moduleId:S};var E=!1,A=!1,P=!1,k="";switch(T.chain&&(k="\nUpdate propagation: "+T.chain.join(" -> ")),T.type){case"self-declined":n.onDeclined&&n.onDeclined(T),n.ignoreDeclined||(E=new Error("Aborted because of self decline: "+T.moduleId+k));break;case"declined":n.onDeclined&&n.onDeclined(T),n.ignoreDeclined||(E=new Error("Aborted because of declined dependency: "+T.moduleId+" in "+T.parentId+k));break;case"unaccepted":n.onUnaccepted&&n.onUnaccepted(T),n.ignoreUnaccepted||(E=new Error("Aborted because "+h+" is not accepted"+k));break;case"accepted":n.onAccepted&&n.onAccepted(T),A=!0;break;case"disposed":n.onDisposed&&n.onDisposed(T),P=!0;break;default:throw new Error("Unexception type "+T.type)}if(E)return d("abort"),Promise.reject(E);if(A)for(h in x[h]=m[h],p(_,T.outdatedModules),T.outdatedDependencies)Object.prototype.hasOwnProperty.call(T.outdatedDependencies,h)&&(y[h]||(y[h]=[]),p(y[h],T.outdatedDependencies[h]));P&&(p(_,[T.moduleId]),x[h]=b)}var I,D=[];for(u=0;u<_.length;u++)h=_[u],L[h]&&L[h].hot._selfAccepted&&x[h]!==b&&!L[h].hot._selfInvalidated&&D.push({module:h,parents:L[h].parents.slice(),errorHandler:L[h].hot._selfAccepted});d("dispose"),Object.keys(w).forEach((function(t){!1===w[t]&&function(t){delete O[t]}(t)}));var j,z,N=_.slice();for(;N.length>0;)if(h=N.pop(),l=L[h]){var F={},B=l.hot._disposeHandlers;for(c=0;c<B.length;c++)(i=B[c])(F);for(a[h]=F,l.hot.active=!1,delete L[h],delete y[h],c=0;c<l.children.length;c++){var H=L[l.children[c]];H&&((I=H.parents.indexOf(h))>=0&&H.parents.splice(I,1))}}for(h in y)if(Object.prototype.hasOwnProperty.call(y,h)&&(l=L[h]))for(z=y[h],c=0;c<z.length;c++)j=z[c],(I=l.children.indexOf(j))>=0&&l.children.splice(I,1);d("apply"),void 0!==g&&(o=g,g=void 0);for(h in m=void 0,x)Object.prototype.hasOwnProperty.call(x,h)&&(t[h]=x[h]);var G=null;for(h in y)if(Object.prototype.hasOwnProperty.call(y,h)&&(l=L[h])){z=y[h];var U=[];for(u=0;u<z.length;u++)if(j=z[u],i=l.hot._acceptedDependencies[j]){if(-1!==U.indexOf(i))continue;U.push(i)}for(u=0;u<U.length;u++){i=U[u];try{i(z)}catch(t){n.onErrored&&n.onErrored({type:"accept-errored",moduleId:h,dependencyId:z[u],error:t}),n.ignoreErrored||G||(G=t)}}}for(u=0;u<D.length;u++){var W=D[u];h=W.module,s=W.parents,r=h;try{R(h)}catch(t){if("function"==typeof W.errorHandler)try{W.errorHandler(t)}catch(e){n.onErrored&&n.onErrored({type:"self-accept-error-handler-errored",moduleId:h,error:e,originalError:t}),n.ignoreErrored||G||(G=e),G||(G=t)}else n.onErrored&&n.onErrored({type:"self-accept-errored",moduleId:h,error:t}),n.ignoreErrored||G||(G=t)}}if(G)return d("fail"),Promise.reject(G);if(v)return e(n).then((function(t){return _.forEach((function(e){t.indexOf(e)<0&&t.push(e)})),t}));return d("idle"),new Promise((function(t){t(_)}))}(e=e||{})}function C(){if(v)return m||(m={}),v.forEach(P),v=void 0,!0}function P(e){Object.prototype.hasOwnProperty.call(m,e)||(m[e]=t[e])}var L={},O={0:0};function R(e){if(L[e])return L[e].exports;var n=L[e]={i:e,l:!1,exports:{},hot:l(e),parents:(u=s,s=[],u),children:[]};return t[e].call(n.exports,n,n.exports,c(e)),n.l=!0,n.exports}R.e=function(t){var e=[],n=O[t];if(0!==n)if(n)e.push(n[2]);else{var r=new Promise((function(e,r){n=O[t]=[e,r]}));e.push(n[2]=r);var i,a=document.createElement("script");a.charset="utf-8",a.timeout=120,R.nc&&a.setAttribute("nonce",R.nc),a.src=function(t){return R.p+""+t+"."+o+".js"}(t),0!==a.src.indexOf(window.location.origin+"/")&&(a.crossOrigin="anonymous");var s=new Error;i=function(e){a.onerror=a.onload=null,clearTimeout(u);var n=O[t];if(0!==n){if(n){var r=e&&("load"===e.type?"missing":e.type),i=e&&e.target&&e.target.src;s.message="Loading chunk "+t+" failed.\n("+r+": "+i+")",s.name="ChunkLoadError",s.type=r,s.request=i,n[1](s)}O[t]=void 0}};var u=setTimeout((function(){i({type:"timeout",target:a})}),12e4);a.onerror=a.onload=i,document.head.appendChild(a)}return Promise.all(e)},R.m=t,R.c=L,R.d=function(t,e,n){R.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},R.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},R.t=function(t,e){if(1&e&&(t=R(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(R.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)R.d(n,r,function(e){return t[e]}.bind(null,r));return n},R.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return R.d(e,"a",e),e},R.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},R.p="./",R.oe=function(t){throw console.error(t),t},R.h=function(){return o};var k=window.webpackJsonprk_web_core=window.webpackJsonprk_web_core||[],I=k.push.bind(k);k.push=e,k=k.slice();for(var D=0;D<k.length;D++)e(k[D]);var j=I;return c(164)(R.s=164)}([function(t,e,n){t.exports=n(335)},function(t,e){var n=t.exports={version:"2.6.12"};"number"==typeof __e&&(__e=n)},function(t,e,n){"use strict";(function(t){n.d(e,"a",(function(){return p})),n.d(e,"b",(function(){return l})),n.d(e,"c",(function(){return Et})),n.d(e,"d",(function(){return St})),n.d(e,"e",(function(){return wt})),n.d(e,"f",(function(){return G})),n.d(e,"g",(function(){return it})),n.d(e,"h",(function(){return Tt})),n.d(e,"i",(function(){return h})),n.d(e,"j",(function(){return Ft}));var r=Object.freeze({__proto__:null,get start(){return Ft},get ensureJQuerySupport(){return dt},get setBootstrapMaxTime(){return q},get setMountMaxTime(){return Y},get setUnmountMaxTime(){return J},get setUnloadMaxTime(){return X},get registerApplication(){return Tt},get unregisterApplication(){return At},get getMountedApps(){return wt},get getAppStatus(){return St},get unloadApplication(){return Ct},get checkActivityFunctions(){return Et},get getAppNames(){return Mt},get pathToActiveWhen(){return Ot},get navigateToUrl(){return it},get triggerAppChange(){return Dt},get addErrorHandler(){return l},get removeErrorHandler(){return h},get mountRootParcel(){return G},get NOT_LOADED(){return p},get LOADING_SOURCE_CODE(){return m},get NOT_BOOTSTRAPPED(){return g},get BOOTSTRAPPING(){return v},get NOT_MOUNTED(){return y},get MOUNTING(){return _},get UPDATING(){return b},get LOAD_ERROR(){return M},get MOUNTED(){return x},get UNMOUNTING(){return w},get SKIP_BECAUSE_BROKEN(){return S}});function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var a=("undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==t?t:"undefined"!=typeof self?self:{}).CustomEvent,s=function(){try{var t=new a("cat",{detail:{foo:"bar"}});return"cat"===t.type&&"bar"===t.detail.foo}catch(t){}return!1}()?a:"undefined"!=typeof document&&"function"==typeof document.createEvent?function(t,e){var n=document.createEvent("CustomEvent");return e?n.initCustomEvent(t,e.bubbles,e.cancelable,e.detail):n.initCustomEvent(t,!1,!1,void 0),n}:function(t,e){var n=document.createEventObject();return n.type=t,e?(n.bubbles=Boolean(e.bubbles),n.cancelable=Boolean(e.cancelable),n.detail=e.detail):(n.bubbles=!1,n.cancelable=!1,n.detail=void 0),n},u=[];function c(t,e,n){var r=d(t,e,n);u.length?u.forEach((function(t){return t(r)})):setTimeout((function(){throw r}))}function l(t){if("function"!=typeof t)throw Error(f(28,!1));u.push(t)}function h(t){if("function"!=typeof t)throw Error(f(29,!1));var e=!1;return u=u.filter((function(n){var r=n===t;return e=e||r,!r})),e}function f(t,e){for(var n=arguments.length,r=new Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return"single-spa minified message #".concat(t,": ").concat(e?e+" ":"","See https://single-spa.js.org/error/?code=").concat(t).concat(r.length?"&arg=".concat(r.join("&arg=")):"")}function d(t,e,n){var r,i="".concat(P(e)," '").concat(A(e),"' died in status ").concat(e.status,": ");if(t instanceof Error){try{t.message=i+t.message}catch(t){}r=t}else{console.warn(f(30,!1,e.status,A(e)));try{r=Error(i+JSON.stringify(t))}catch(e){r=t}}return r.appOrParcelName=A(e),e.status=n,r}var p="NOT_LOADED",m="LOADING_SOURCE_CODE",g="NOT_BOOTSTRAPPED",v="BOOTSTRAPPING",y="NOT_MOUNTED",_="MOUNTING",x="MOUNTED",b="UPDATING",w="UNMOUNTING",M="LOAD_ERROR",S="SKIP_BECAUSE_BROKEN";function T(t){return t.status===x}function E(t){try{return t.activeWhen(window.location)}catch(e){return c(e,t,S),!1}}function A(t){return t.name}function C(t){return Boolean(t.unmountThisParcel)}function P(t){return C(t)?"parcel":"application"}function L(){for(var t=arguments.length-1;t>0;t--)for(var e in arguments[t])"__proto__"!==e&&(arguments[t-1][e]=arguments[t][e]);return arguments[0]}function O(t,e){for(var n=0;n<t.length;n++)if(e(t[n]))return t[n];return null}function R(t){return t&&("function"==typeof t||(e=t,Array.isArray(e)&&!O(e,(function(t){return"function"!=typeof t}))));var e}function k(t,e){var n=t[e]||[];0===(n=Array.isArray(n)?n:[n]).length&&(n=[function(){return Promise.resolve()}]);var r=P(t),i=A(t);return function(t){return n.reduce((function(n,o,a){return n.then((function(){var n=o(t);return I(n)?n:Promise.reject(f(15,!1,r,i,e,a))}))}),Promise.resolve())}}function I(t){return t&&"function"==typeof t.then&&"function"==typeof t.catch}function D(t,e){return Promise.resolve().then((function(){return t.status!==g?t:(t.status=v,t.bootstrap?$(t,"bootstrap").then(n).catch((function(n){if(e)throw d(n,t,S);return c(n,t,S),t})):Promise.resolve().then(n))}));function n(){return t.status=y,t}}function j(t,e){return Promise.resolve().then((function(){if(t.status!==x)return t;t.status=w;var n=Object.keys(t.parcels).map((function(e){return t.parcels[e].unmountThisParcel()}));return Promise.all(n).then(r,(function(n){return r().then((function(){var r=Error(n.message);if(e)throw d(r,t,S);c(r,t,S)}))})).then((function(){return t}));function r(){return $(t,"unmount").then((function(){t.status=y})).catch((function(n){if(e)throw d(n,t,S);c(n,t,S)}))}}))}var z=!1,N=!1;function F(t,e){return Promise.resolve().then((function(){return t.status!==y?t:(z||(window.dispatchEvent(new s("single-spa:before-first-mount")),z=!0),$(t,"mount").then((function(){return t.status=x,N||(window.dispatchEvent(new s("single-spa:first-mount")),N=!0),t})).catch((function(n){return t.status=x,j(t,!0).then(r,r);function r(){if(e)throw d(n,t,S);return c(n,t,S),t}})))}))}var B=0,H={parcels:{}};function G(){return U.apply(H,arguments)}function U(t,e){var n=this;if(!t||"object"!==i(t)&&"function"!=typeof t)throw Error(f(2,!1));if(t.name&&"string"!=typeof t.name)throw Error(f(3,!1,i(t.name)));if("object"!==i(e))throw Error(f(4,!1,name,i(e)));if(!e.domElement)throw Error(f(5,!1,name));var r,o=B++,a="function"==typeof t,s=a?t:function(){return Promise.resolve(t)},u={id:o,parcels:{},status:a?m:g,customProps:e,parentName:A(n),unmountThisParcel:function(){return v.then((function(){if(u.status!==x)throw Error(f(6,!1,name,u.status));return j(u,!0)})).then((function(t){return u.parentName&&delete n.parcels[u.id],t})).then((function(t){return l(t),t})).catch((function(t){throw u.status=S,h(t),t}))}};n.parcels[o]=u;var c=s();if(!c||"function"!=typeof c.then)throw Error(f(7,!1));var l,h,p=(c=c.then((function(t){if(!t)throw Error(f(8,!1));var e=t.name||"parcel-".concat(o);if(Object.prototype.hasOwnProperty.call(t,"bootstrap")&&!R(t.bootstrap))throw Error(f(9,!1,e));if(!R(t.mount))throw Error(f(10,!1,e));if(!R(t.unmount))throw Error(f(11,!1,e));if(t.update&&!R(t.update))throw Error(f(12,!1,e));var n=k(t,"bootstrap"),i=k(t,"mount"),a=k(t,"unmount");u.status=g,u.name=e,u.bootstrap=n,u.mount=i,u.unmount=a,u.timeouts=Q(t.timeouts),t.update&&(u.update=k(t,"update"),r.update=function(t){return u.customProps=t,W(function(t){return Promise.resolve().then((function(){if(t.status!==x)throw Error(f(32,!1,A(t)));return t.status=b,$(t,"update").then((function(){return t.status=x,t})).catch((function(e){throw d(e,t,S)}))}))}(u))})}))).then((function(){return D(u,!0)})),v=p.then((function(){return F(u,!0)})),_=new Promise((function(t,e){l=t,h=e}));return r={mount:function(){return W(Promise.resolve().then((function(){if(u.status!==y)throw Error(f(13,!1,name,u.status));return n.parcels[o]=u,F(u)})))},unmount:function(){return W(u.unmountThisParcel())},getStatus:function(){return u.status},loadPromise:W(c),bootstrapPromise:W(p),mountPromise:W(v),unmountPromise:W(_)}}function W(t){return t.then((function(){return null}))}function V(t){var e=A(t),n="function"==typeof t.customProps?t.customProps(e,window.location):t.customProps;("object"!==i(n)||null===n||Array.isArray(n))&&(n={},console.warn(f(40,!1),e,n));var o=L({},n,{name:e,mountParcel:U.bind(t),singleSpa:r});return C(t)&&(o.unmountSelf=t.unmountThisParcel),o}var Z={bootstrap:{millis:4e3,dieOnTimeout:!1,warningMillis:1e3},mount:{millis:3e3,dieOnTimeout:!1,warningMillis:1e3},unmount:{millis:3e3,dieOnTimeout:!1,warningMillis:1e3},unload:{millis:3e3,dieOnTimeout:!1,warningMillis:1e3},update:{millis:3e3,dieOnTimeout:!1,warningMillis:1e3}};function q(t,e,n){if("number"!=typeof t||t<=0)throw Error(f(16,!1));Z.bootstrap={millis:t,dieOnTimeout:e,warningMillis:n||1e3}}function Y(t,e,n){if("number"!=typeof t||t<=0)throw Error(f(17,!1));Z.mount={millis:t,dieOnTimeout:e,warningMillis:n||1e3}}function J(t,e,n){if("number"!=typeof t||t<=0)throw Error(f(18,!1));Z.unmount={millis:t,dieOnTimeout:e,warningMillis:n||1e3}}function X(t,e,n){if("number"!=typeof t||t<=0)throw Error(f(19,!1));Z.unload={millis:t,dieOnTimeout:e,warningMillis:n||1e3}}function $(t,e){var n=t.timeouts[e],r=n.warningMillis,i=P(t);return new Promise((function(o,a){var s=!1,u=!1;t[e](V(t)).then((function(t){s=!0,o(t)})).catch((function(t){s=!0,a(t)})),setTimeout((function(){return l(1)}),r),setTimeout((function(){return l(!0)}),n.millis);var c=f(31,!1,e,i,A(t),n.millis);function l(t){if(!s)if(!0===t)u=!0,n.dieOnTimeout?a(Error(c)):console.error(c);else if(!u){var e=t,i=e*r;console.warn(c),i+r<n.millis&&setTimeout((function(){return l(e+1)}),r)}}}))}function Q(t){var e={};for(var n in Z)e[n]=L({},Z[n],t&&t[n]||{});return e}function K(t){return Promise.resolve().then((function(){return t.loadPromise?t.loadPromise:t.status!==p&&t.status!==M?t:(t.status=m,t.loadPromise=Promise.resolve().then((function(){var r=t.loadApp(V(t));if(!I(r))throw n=!0,Error(f(33,!1,A(t)));return r.then((function(n){var r;t.loadErrorTime=null,"object"!==i(e=n)&&(r=34),Object.prototype.hasOwnProperty.call(e,"bootstrap")&&!R(e.bootstrap)&&(r=35),R(e.mount)||(r=36),R(e.unmount)||(r=37);var o=P(e);if(r){var a;try{a=JSON.stringify(e)}catch(t){}return console.error(f(r,!1,o,A(t),a),e),c(void 0,t,S),t}return e.devtools&&e.devtools.overlays&&(t.devtools.overlays=L({},t.devtools.overlays,e.devtools.overlays)),t.status=g,t.bootstrap=k(e,"bootstrap"),t.mount=k(e,"mount"),t.unmount=k(e,"unmount"),t.unload=k(e,"unload"),t.timeouts=Q(e.timeouts),delete t.loadPromise,t}))})).catch((function(e){var r;return delete t.loadPromise,n?r=S:(r=M,t.loadErrorTime=(new Date).getTime()),c(e,t,r),t})));var e,n}))}var tt,et="undefined"!=typeof window,nt={hashchange:[],popstate:[]},rt=["hashchange","popstate"];function it(t){var e;if("string"==typeof t)e=t;else if(this&&this.href)e=this.href;else{if(!(t&&t.currentTarget&&t.currentTarget.href&&t.preventDefault))throw Error(f(14,!1));e=t.currentTarget.href,t.preventDefault()}var n=ht(window.location.href),r=ht(e);0===e.indexOf("#")?window.location.hash=r.hash:n.host!==r.host&&r.host?window.location.href=e:r.pathname===n.pathname&&r.search===n.search?window.location.hash=r.hash:window.history.pushState(null,null,e)}function ot(t){var e=this;if(t){var n=t[0].type;rt.indexOf(n)>=0&&nt[n].forEach((function(n){try{n.apply(e,t)}catch(t){setTimeout((function(){throw t}))}}))}}function at(){jt([],arguments)}function st(t,e){return function(){var n=window.location.href,r=t.apply(this,arguments),i=window.location.href;return tt&&n===i||(Bt()?window.dispatchEvent(ut(window.history.state,e)):jt([])),r}}function ut(t,e){var n;try{n=new PopStateEvent("popstate",{state:t})}catch(e){(n=document.createEvent("PopStateEvent")).initPopStateEvent("popstate",!1,!1,t)}return n.singleSpa=!0,n.singleSpaTrigger=e,n}if(et){window.addEventListener("hashchange",at),window.addEventListener("popstate",at);var ct=window.addEventListener,lt=window.removeEventListener;window.addEventListener=function(t,e){if(!("function"==typeof e&&rt.indexOf(t)>=0)||O(nt[t],(function(t){return t===e})))return ct.apply(this,arguments);nt[t].push(e)},window.removeEventListener=function(t,e){if(!("function"==typeof e&&rt.indexOf(t)>=0))return lt.apply(this,arguments);nt[t]=nt[t].filter((function(t){return t!==e}))},window.history.pushState=st(window.history.pushState,"pushState"),window.history.replaceState=st(window.history.replaceState,"replaceState"),window.singleSpaNavigate?console.warn(f(41,!1)):window.singleSpaNavigate=it}function ht(t){var e=document.createElement("a");return e.href=t,e}var ft=!1;function dt(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:window.jQuery;if(t||window.$&&window.$.fn&&window.$.fn.jquery&&(t=window.$),t&&!ft){var e=t.fn.on,n=t.fn.off;t.fn.on=function(t,n){return pt.call(this,e,window.addEventListener,t,n,arguments)},t.fn.off=function(t,e){return pt.call(this,n,window.removeEventListener,t,e,arguments)},ft=!0}}function pt(t,e,n,r,i){return"string"!=typeof n?t.apply(this,i):(n.split(/\s+/).forEach((function(t){rt.indexOf(t)>=0&&(e(t,r),n=n.replace(t,""))})),""===n.trim()?this:t.apply(this,i))}var mt={};function gt(t){return Promise.resolve().then((function(){var e=mt[A(t)];if(!e)return t;if(t.status===p)return vt(t,e),t;if("UNLOADING"===t.status)return e.promise.then((function(){return t}));if(t.status!==y&&t.status!==M)return t;var n=t.status===M?Promise.resolve():$(t,"unload");return t.status="UNLOADING",n.then((function(){return vt(t,e),t})).catch((function(n){return function(t,e,n){delete mt[A(t)],delete t.bootstrap,delete t.mount,delete t.unmount,delete t.unload,c(n,t,S),e.reject(n)}(t,e,n),t}))}))}function vt(t,e){delete mt[A(t)],delete t.bootstrap,delete t.mount,delete t.unmount,delete t.unload,t.status=p,e.resolve()}function yt(t,e,n,r){mt[A(t)]={app:t,resolve:n,reject:r},Object.defineProperty(mt[A(t)],"promise",{get:e})}function _t(t){return mt[t]}var xt=[];function bt(){var t=[],e=[],n=[],r=[],i=(new Date).getTime();return xt.forEach((function(o){var a=o.status!==S&&E(o);switch(o.status){case M:a&&i-o.loadErrorTime>=200&&n.push(o);break;case p:case m:a&&n.push(o);break;case g:case y:!a&&_t(A(o))?t.push(o):a&&r.push(o);break;case x:a||e.push(o)}})),{appsToUnload:t,appsToUnmount:e,appsToLoad:n,appsToMount:r}}function wt(){return xt.filter(T).map(A)}function Mt(){return xt.map(A)}function St(t){var e=O(xt,(function(e){return A(e)===t}));return e?e.status:null}function Tt(t,e,n,r){var o=function(t,e,n,r){var o,a={name:null,loadApp:null,activeWhen:null,customProps:null};return"object"===i(t)?(function(t){if(Array.isArray(t)||null===t)throw Error(f(39,!1));var e=["name","app","activeWhen","customProps"],n=Object.keys(t).reduce((function(t,n){return e.indexOf(n)>=0?t:t.concat(n)}),[]);if(0!==n.length)throw Error(f(38,!1,e.join(", "),n.join(", ")));if("string"!=typeof t.name||0===t.name.length)throw Error(f(20,!1));if("object"!==i(t.app)&&"function"!=typeof t.app)throw Error(f(20,!1));var r=function(t){return"string"==typeof t||"function"==typeof t};if(!(r(t.activeWhen)||Array.isArray(t.activeWhen)&&t.activeWhen.every(r)))throw Error(f(24,!1));if(!Lt(t.customProps))throw Error(f(22,!1))}(t),a.name=t.name,a.loadApp=t.app,a.activeWhen=t.activeWhen,a.customProps=t.customProps):(function(t,e,n,r){if("string"!=typeof t||0===t.length)throw Error(f(20,!1));if(!e)throw Error(f(23,!1));if("function"!=typeof n)throw Error(f(24,!1));if(!Lt(r))throw Error(f(22,!1))}(t,e,n,r),a.name=t,a.loadApp=e,a.activeWhen=n,a.customProps=r),a.loadApp="function"!=typeof(o=a.loadApp)?function(){return Promise.resolve(o)}:o,a.customProps=function(t){return t||{}}(a.customProps),a.activeWhen=function(t){var e=Array.isArray(t)?t:[t];return e=e.map((function(t){return"function"==typeof t?t:Ot(t)})),function(t){return e.some((function(e){return e(t)}))}}(a.activeWhen),a}(t,e,n,r);if(-1!==Mt().indexOf(o.name))throw Error(f(21,!1,o.name));xt.push(L({loadErrorTime:null,status:p,parcels:{},devtools:{overlays:{options:{},selectors:[]}}},o)),et&&(dt(),jt())}function Et(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:window.location;return xt.filter((function(e){return e.activeWhen(t)})).map(A)}function At(t){if(0===xt.filter((function(e){return A(e)===t})).length)throw Error(f(25,!1,t));return Ct(t).then((function(){var e=xt.map(A).indexOf(t);xt.splice(e,1)}))}function Ct(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{waitForUnmount:!1};if("string"!=typeof t)throw Error(f(26,!1));var n=O(xt,(function(e){return A(e)===t}));if(!n)throw Error(f(27,!1,t));var r,i=_t(A(n));if(e&&e.waitForUnmount){if(i)return i.promise;var o=new Promise((function(t,e){yt(n,(function(){return o}),t,e)}));return o}return i?(r=i.promise,Pt(n,i.resolve,i.reject)):r=new Promise((function(t,e){yt(n,(function(){return r}),t,e),Pt(n,t,e)})),r}function Pt(t,e,n){j(t).then(gt).then((function(){e(),setTimeout((function(){jt()}))})).catch(n)}function Lt(t){return!t||"function"==typeof t||"object"===i(t)&&null!==t&&!Array.isArray(t)}function Ot(t,e){var n=function(t,e){var n=0,r=!1,i="^";"/"!==t[0]&&(t="/"+t);for(var o=0;o<t.length;o++){var a=t[o];(!r&&":"===a||r&&"/"===a)&&s(o)}return s(t.length),new RegExp(i,"i");function s(o){var a=t.slice(n,o).replace(/[|\\{}()[\]^$+*?.]/g,"\\$&");if(i+=r?"[^/]+/?":a,o===t.length)if(r)e&&(i+="$");else{var s=e?"":".*";i="/"===i.charAt(i.length-1)?"".concat(i).concat(s,"$"):"".concat(i,"(/").concat(s,")?(#.*)?$")}r=!r,n=o}}(t,e);return function(t){var e=t.origin;e||(e="".concat(t.protocol,"//").concat(t.host));var r=t.href.replace(e,"").replace(t.search,"").split("?")[0];return n.test(r)}}var Rt=!1,kt=[],It=et&&window.location.href;function Dt(){return jt()}function jt(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],e=arguments.length>1?arguments[1]:void 0;if(Rt)return new Promise((function(t,n){kt.push({resolve:t,reject:n,eventArguments:e})}));var n,r=bt(),i=r.appsToUnload,a=r.appsToUnmount,u=r.appsToLoad,c=r.appsToMount,l=!1,h=It,f=It=window.location.href;return Bt()?(Rt=!0,n=i.concat(u,a,c),g()):(n=u,m());function d(){l=!0}function m(){return Promise.resolve().then((function(){var t=u.map(K);return Promise.all(t).then(_).then((function(){return[]})).catch((function(t){throw _(),t}))}))}function g(){return Promise.resolve().then((function(){if(window.dispatchEvent(new s(0===n.length?"single-spa:before-no-app-change":"single-spa:before-app-change",b(!0))),window.dispatchEvent(new s("single-spa:before-routing-event",b(!0,{cancelNavigation:d}))),l)return window.dispatchEvent(new s("single-spa:before-mount-routing-event",b(!0))),v(),void it(h);var e=i.map(gt),r=a.map(j).map((function(t){return t.then(gt)})).concat(e),o=Promise.all(r);o.then((function(){window.dispatchEvent(new s("single-spa:before-mount-routing-event",b(!0)))}));var f=u.map((function(t){return K(t).then((function(t){return zt(t,o)}))})),p=c.filter((function(t){return u.indexOf(t)<0})).map((function(t){return zt(t,o)}));return o.catch((function(t){throw _(),t})).then((function(){return _(),Promise.all(f.concat(p)).catch((function(e){throw t.forEach((function(t){return t.reject(e)})),e})).then(v)}))}))}function v(){var e=wt();t.forEach((function(t){return t.resolve(e)}));try{var r=0===n.length?"single-spa:no-app-change":"single-spa:app-change";window.dispatchEvent(new s(r,b())),window.dispatchEvent(new s("single-spa:routing-event",b()))}catch(t){setTimeout((function(){throw t}))}if(Rt=!1,kt.length>0){var i=kt;kt=[],jt(i)}return e}function _(){t.forEach((function(t){ot(t.eventArguments)})),ot(e)}function b(){var t,r=arguments.length>0&&void 0!==arguments[0]&&arguments[0],s=arguments.length>1?arguments[1]:void 0,d={},m=(o(t={},x,[]),o(t,y,[]),o(t,p,[]),o(t,S,[]),t);r?(u.concat(c).forEach((function(t,e){v(t,x)})),i.forEach((function(t){v(t,p)})),a.forEach((function(t){v(t,y)}))):n.forEach((function(t){v(t)}));var g={detail:{newAppStatuses:d,appsByNewStatus:m,totalAppChanges:n.length,originalEvent:null==e?void 0:e[0],oldUrl:h,newUrl:f,navigationIsCanceled:l}};return s&&L(g.detail,s),g;function v(t,e){var n=A(t);e=e||St(n),d[n]=e,(m[e]=m[e]||[]).push(n)}}}function zt(t,e){return E(t)?D(t).then((function(t){return e.then((function(){return E(t)?F(t):t}))})):e.then((function(){return t}))}var Nt=!1;function Ft(t){var e;Nt=!0,t&&t.urlRerouteOnly&&(e=t.urlRerouteOnly,tt=e),et&&jt()}function Bt(){return Nt}et&&setTimeout((function(){Nt||console.warn(f(1,!1))}),5e3);var Ht={getRawAppData:function(){return[].concat(xt)},reroute:jt,NOT_LOADED:p,toLoadPromise:K,toBootstrapPromise:D,unregisterApplication:At};et&&window.__SINGLE_SPA_DEVTOOLS__&&(window.__SINGLE_SPA_DEVTOOLS__.exposedMethods=Ht)}).call(this,n(20))},function(t,e,n){var r=n(28),i=n(12);t.exports=function(t){if(!i(t))return!1;var e=r(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}},function(t,e,n){"use strict";var r=n(122),i=Object.prototype.toString;function o(t){return"[object Array]"===i.call(t)}function a(t){return void 0===t}function s(t){return null!==t&&"object"==typeof t}function u(t){if("[object Object]"!==i.call(t))return!1;var e=Object.getPrototypeOf(t);return null===e||e===Object.prototype}function c(t){return"[object Function]"===i.call(t)}function l(t,e){if(null!=t)if("object"!=typeof t&&(t=[t]),o(t))for(var n=0,r=t.length;n<r;n++)e.call(null,t[n],n,t);else for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&e.call(null,t[i],i,t)}t.exports={isArray:o,isArrayBuffer:function(t){return"[object ArrayBuffer]"===i.call(t)},isBuffer:function(t){return null!==t&&!a(t)&&null!==t.constructor&&!a(t.constructor)&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t)},isFormData:function(t){return"undefined"!=typeof FormData&&t instanceof FormData},isArrayBufferView:function(t){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(t):t&&t.buffer&&t.buffer instanceof ArrayBuffer},isString:function(t){return"string"==typeof t},isNumber:function(t){return"number"==typeof t},isObject:s,isPlainObject:u,isUndefined:a,isDate:function(t){return"[object Date]"===i.call(t)},isFile:function(t){return"[object File]"===i.call(t)},isBlob:function(t){return"[object Blob]"===i.call(t)},isFunction:c,isStream:function(t){return s(t)&&c(t.pipe)},isURLSearchParams:function(t){return"undefined"!=typeof URLSearchParams&&t instanceof URLSearchParams},isStandardBrowserEnv:function(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&("undefined"!=typeof window&&"undefined"!=typeof document)},forEach:l,merge:function t(){var e={};function n(n,r){u(e[r])&&u(n)?e[r]=t(e[r],n):u(n)?e[r]=t({},n):o(n)?e[r]=n.slice():e[r]=n}for(var r=0,i=arguments.length;r<i;r++)l(arguments[r],n);return e},extend:function(t,e,n){return l(e,(function(e,i){t[i]=n&&"function"==typeof e?r(e,n):e})),t},trim:function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")},stripBOM:function(t){return 65279===t.charCodeAt(0)&&(t=t.slice(1)),t}}},function(t,e){var n=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(t,e,n){var r=n(102)("wks"),i=n(103),o=n(5).Symbol,a="function"==typeof o;(t.exports=function(t){return r[t]||(r[t]=a&&o[t]||(a?o:i)("Symbol."+t))}).store=r},function(t,e,n){var r=n(5),i=n(1),o=n(29),a=n(23),s=n(37),u=function(t,e,n){var c,l,h,f=t&u.F,d=t&u.G,p=t&u.S,m=t&u.P,g=t&u.B,v=t&u.W,y=d?i:i[e]||(i[e]={}),_=y.prototype,x=d?r:p?r[e]:(r[e]||{}).prototype;for(c in d&&(n=e),n)(l=!f&&x&&void 0!==x[c])&&s(y,c)||(h=l?x[c]:n[c],y[c]=d&&"function"!=typeof x[c]?n[c]:g&&l?o(h,r):v&&x[c]==h?function(t){var e=function(e,n,r){if(this instanceof t){switch(arguments.length){case 0:return new t;case 1:return new t(e);case 2:return new t(e,n)}return new t(e,n,r)}return t.apply(this,arguments)};return e.prototype=t.prototype,e}(h):m&&"function"==typeof h?o(Function.call,h):h,m&&((y.virtual||(y.virtual={}))[c]=h,t&u.R&&_&&!_[c]&&a(_,c,h)))};u.F=1,u.G=2,u.S=4,u.P=8,u.B=16,u.W=32,u.U=64,u.R=128,t.exports=u},function(t,e,n){(function(t,r){var i;
1
+ !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define("rk-web-core",[],e):"object"==typeof exports?exports["rk-web-core"]=e():t["rk-web-core"]=e()}(window,(function(){return function(t){function e(e){for(var n,r,i=e[0],o=e[1],a=0,s=[];a<i.length;a++)r=i[a],Object.prototype.hasOwnProperty.call(O,r)&&O[r]&&s.push(O[r][0]),O[r]=0;for(n in o)Object.prototype.hasOwnProperty.call(o,n)&&(t[n]=o[n]);for(j&&j(e);s.length;)s.shift()()}var n=window.webpackHotUpdaterk_web_core;window.webpackHotUpdaterk_web_core=function(t,e){!function(t,e){if(!w[t]||!b[t])return;for(var n in b[t]=!1,e)Object.prototype.hasOwnProperty.call(e,n)&&(m[n]=e[n]);0==--y&&0===_&&E()}(t,e),n&&n(t,e)};var r,i=!0,o="72ab53f2c2daacf8c3db",a={},s=[],u=[];function c(t){var e=L[t];if(!e)return R;var n=function(n){return e.hot.active?(L[n]?-1===L[n].parents.indexOf(t)&&L[n].parents.push(t):(s=[t],r=n),-1===e.children.indexOf(n)&&e.children.push(n)):(console.warn("[HMR] unexpected require("+n+") from disposed module "+t),s=[]),R(n)},i=function(t){return{configurable:!0,enumerable:!0,get:function(){return R[t]},set:function(e){R[t]=e}}};for(var o in R)Object.prototype.hasOwnProperty.call(R,o)&&"e"!==o&&"t"!==o&&Object.defineProperty(n,o,i(o));return n.e=function(t){return"ready"===f&&d("prepare"),_++,R.e(t).then(e,(function(t){throw e(),t}));function e(){_--,"prepare"===f&&(x[t]||T(t),0===_&&0===y&&E())}},n.t=function(t,e){return 1&e&&(t=n(t)),R.t(t,-2&e)},n}function l(e){var n={_acceptedDependencies:{},_declinedDependencies:{},_selfAccepted:!1,_selfDeclined:!1,_selfInvalidated:!1,_disposeHandlers:[],_main:r!==e,active:!0,accept:function(t,e){if(void 0===t)n._selfAccepted=!0;else if("function"==typeof t)n._selfAccepted=t;else if("object"==typeof t)for(var r=0;r<t.length;r++)n._acceptedDependencies[t[r]]=e||function(){};else n._acceptedDependencies[t]=e||function(){}},decline:function(t){if(void 0===t)n._selfDeclined=!0;else if("object"==typeof t)for(var e=0;e<t.length;e++)n._declinedDependencies[t[e]]=!0;else n._declinedDependencies[t]=!0},dispose:function(t){n._disposeHandlers.push(t)},addDisposeHandler:function(t){n._disposeHandlers.push(t)},removeDisposeHandler:function(t){var e=n._disposeHandlers.indexOf(t);e>=0&&n._disposeHandlers.splice(e,1)},invalidate:function(){switch(this._selfInvalidated=!0,f){case"idle":(m={})[e]=t[e],d("ready");break;case"ready":P(e);break;case"prepare":case"check":case"dispose":case"apply":(v=v||[]).push(e)}},check:S,apply:A,status:function(t){if(!t)return f;h.push(t)},addStatusHandler:function(t){h.push(t)},removeStatusHandler:function(t){var e=h.indexOf(t);e>=0&&h.splice(e,1)},data:a[e]};return r=void 0,n}var h=[],f="idle";function d(t){f=t;for(var e=0;e<h.length;e++)h[e].call(null,t)}var p,m,g,v,y=0,_=0,x={},b={},w={};function M(t){return+t+""===t?+t:t}function S(t){if("idle"!==f)throw new Error("check() is only allowed in idle status");return i=t,d("check"),(e=1e4,e=e||1e4,new Promise((function(t,n){if("undefined"==typeof XMLHttpRequest)return n(new Error("No browser support"));try{var r=new XMLHttpRequest,i=R.p+""+o+".hot-update.json";r.open("GET",i,!0),r.timeout=e,r.send(null)}catch(t){return n(t)}r.onreadystatechange=function(){if(4===r.readyState)if(0===r.status)n(new Error("Manifest request to "+i+" timed out."));else if(404===r.status)t();else if(200!==r.status&&304!==r.status)n(new Error("Manifest request to "+i+" failed."));else{try{var e=JSON.parse(r.responseText)}catch(t){return void n(t)}t(e)}}}))).then((function(t){if(!t)return d(C()?"ready":"idle"),null;b={},x={},w=t.c,g=t.h,d("prepare");var e=new Promise((function(t,e){p={resolve:t,reject:e}}));for(var n in m={},O)T(n);return"prepare"===f&&0===_&&0===y&&E(),e}));var e}function T(t){w[t]?(b[t]=!0,y++,function(t){var e=document.createElement("script");e.charset="utf-8",e.src=R.p+""+t+"."+o+".hot-update.js",e.crossOrigin="anonymous",document.head.appendChild(e)}(t)):x[t]=!0}function E(){d("ready");var t=p;if(p=null,t)if(i)Promise.resolve().then((function(){return A(i)})).then((function(e){t.resolve(e)}),(function(e){t.reject(e)}));else{var e=[];for(var n in m)Object.prototype.hasOwnProperty.call(m,n)&&e.push(M(n));t.resolve(e)}}function A(e){if("ready"!==f)throw new Error("apply() is only allowed in ready status");return function e(n){var i,u,c,l,h;function f(t){for(var e=[t],n={},r=e.map((function(t){return{chain:[t],id:t}}));r.length>0;){var i=r.pop(),o=i.id,a=i.chain;if((l=L[o])&&(!l.hot._selfAccepted||l.hot._selfInvalidated)){if(l.hot._selfDeclined)return{type:"self-declined",chain:a,moduleId:o};if(l.hot._main)return{type:"unaccepted",chain:a,moduleId:o};for(var s=0;s<l.parents.length;s++){var u=l.parents[s],c=L[u];if(c){if(c.hot._declinedDependencies[o])return{type:"declined",chain:a.concat([u]),moduleId:o,parentId:u};-1===e.indexOf(u)&&(c.hot._acceptedDependencies[o]?(n[u]||(n[u]=[]),p(n[u],[o])):(delete n[u],e.push(u),r.push({chain:a.concat([u]),id:u})))}}}}return{type:"accepted",moduleId:t,outdatedModules:e,outdatedDependencies:n}}function p(t,e){for(var n=0;n<e.length;n++){var r=e[n];-1===t.indexOf(r)&&t.push(r)}}C();var y={},_=[],x={},b=function(){console.warn("[HMR] unexpected require("+T.moduleId+") to disposed module")};for(var S in m)if(Object.prototype.hasOwnProperty.call(m,S)){var T;h=M(S),T=m[S]?f(h):{type:"disposed",moduleId:S};var E=!1,A=!1,P=!1,k="";switch(T.chain&&(k="\nUpdate propagation: "+T.chain.join(" -> ")),T.type){case"self-declined":n.onDeclined&&n.onDeclined(T),n.ignoreDeclined||(E=new Error("Aborted because of self decline: "+T.moduleId+k));break;case"declined":n.onDeclined&&n.onDeclined(T),n.ignoreDeclined||(E=new Error("Aborted because of declined dependency: "+T.moduleId+" in "+T.parentId+k));break;case"unaccepted":n.onUnaccepted&&n.onUnaccepted(T),n.ignoreUnaccepted||(E=new Error("Aborted because "+h+" is not accepted"+k));break;case"accepted":n.onAccepted&&n.onAccepted(T),A=!0;break;case"disposed":n.onDisposed&&n.onDisposed(T),P=!0;break;default:throw new Error("Unexception type "+T.type)}if(E)return d("abort"),Promise.reject(E);if(A)for(h in x[h]=m[h],p(_,T.outdatedModules),T.outdatedDependencies)Object.prototype.hasOwnProperty.call(T.outdatedDependencies,h)&&(y[h]||(y[h]=[]),p(y[h],T.outdatedDependencies[h]));P&&(p(_,[T.moduleId]),x[h]=b)}var I,D=[];for(u=0;u<_.length;u++)h=_[u],L[h]&&L[h].hot._selfAccepted&&x[h]!==b&&!L[h].hot._selfInvalidated&&D.push({module:h,parents:L[h].parents.slice(),errorHandler:L[h].hot._selfAccepted});d("dispose"),Object.keys(w).forEach((function(t){!1===w[t]&&function(t){delete O[t]}(t)}));var j,z,N=_.slice();for(;N.length>0;)if(h=N.pop(),l=L[h]){var F={},B=l.hot._disposeHandlers;for(c=0;c<B.length;c++)(i=B[c])(F);for(a[h]=F,l.hot.active=!1,delete L[h],delete y[h],c=0;c<l.children.length;c++){var H=L[l.children[c]];H&&((I=H.parents.indexOf(h))>=0&&H.parents.splice(I,1))}}for(h in y)if(Object.prototype.hasOwnProperty.call(y,h)&&(l=L[h]))for(z=y[h],c=0;c<z.length;c++)j=z[c],(I=l.children.indexOf(j))>=0&&l.children.splice(I,1);d("apply"),void 0!==g&&(o=g,g=void 0);for(h in m=void 0,x)Object.prototype.hasOwnProperty.call(x,h)&&(t[h]=x[h]);var G=null;for(h in y)if(Object.prototype.hasOwnProperty.call(y,h)&&(l=L[h])){z=y[h];var U=[];for(u=0;u<z.length;u++)if(j=z[u],i=l.hot._acceptedDependencies[j]){if(-1!==U.indexOf(i))continue;U.push(i)}for(u=0;u<U.length;u++){i=U[u];try{i(z)}catch(t){n.onErrored&&n.onErrored({type:"accept-errored",moduleId:h,dependencyId:z[u],error:t}),n.ignoreErrored||G||(G=t)}}}for(u=0;u<D.length;u++){var W=D[u];h=W.module,s=W.parents,r=h;try{R(h)}catch(t){if("function"==typeof W.errorHandler)try{W.errorHandler(t)}catch(e){n.onErrored&&n.onErrored({type:"self-accept-error-handler-errored",moduleId:h,error:e,originalError:t}),n.ignoreErrored||G||(G=e),G||(G=t)}else n.onErrored&&n.onErrored({type:"self-accept-errored",moduleId:h,error:t}),n.ignoreErrored||G||(G=t)}}if(G)return d("fail"),Promise.reject(G);if(v)return e(n).then((function(t){return _.forEach((function(e){t.indexOf(e)<0&&t.push(e)})),t}));return d("idle"),new Promise((function(t){t(_)}))}(e=e||{})}function C(){if(v)return m||(m={}),v.forEach(P),v=void 0,!0}function P(e){Object.prototype.hasOwnProperty.call(m,e)||(m[e]=t[e])}var L={},O={0:0};function R(e){if(L[e])return L[e].exports;var n=L[e]={i:e,l:!1,exports:{},hot:l(e),parents:(u=s,s=[],u),children:[]};return t[e].call(n.exports,n,n.exports,c(e)),n.l=!0,n.exports}R.e=function(t){var e=[],n=O[t];if(0!==n)if(n)e.push(n[2]);else{var r=new Promise((function(e,r){n=O[t]=[e,r]}));e.push(n[2]=r);var i,a=document.createElement("script");a.charset="utf-8",a.timeout=120,R.nc&&a.setAttribute("nonce",R.nc),a.src=function(t){return R.p+""+t+"."+o+".js"}(t),0!==a.src.indexOf(window.location.origin+"/")&&(a.crossOrigin="anonymous");var s=new Error;i=function(e){a.onerror=a.onload=null,clearTimeout(u);var n=O[t];if(0!==n){if(n){var r=e&&("load"===e.type?"missing":e.type),i=e&&e.target&&e.target.src;s.message="Loading chunk "+t+" failed.\n("+r+": "+i+")",s.name="ChunkLoadError",s.type=r,s.request=i,n[1](s)}O[t]=void 0}};var u=setTimeout((function(){i({type:"timeout",target:a})}),12e4);a.onerror=a.onload=i,document.head.appendChild(a)}return Promise.all(e)},R.m=t,R.c=L,R.d=function(t,e,n){R.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},R.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},R.t=function(t,e){if(1&e&&(t=R(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(R.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)R.d(n,r,function(e){return t[e]}.bind(null,r));return n},R.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return R.d(e,"a",e),e},R.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},R.p="./",R.oe=function(t){throw console.error(t),t},R.h=function(){return o};var k=window.webpackJsonprk_web_core=window.webpackJsonprk_web_core||[],I=k.push.bind(k);k.push=e,k=k.slice();for(var D=0;D<k.length;D++)e(k[D]);var j=I;return c(164)(R.s=164)}([function(t,e,n){t.exports=n(335)},function(t,e){var n=t.exports={version:"2.6.12"};"number"==typeof __e&&(__e=n)},function(t,e,n){"use strict";(function(t){n.d(e,"a",(function(){return p})),n.d(e,"b",(function(){return l})),n.d(e,"c",(function(){return Et})),n.d(e,"d",(function(){return St})),n.d(e,"e",(function(){return wt})),n.d(e,"f",(function(){return G})),n.d(e,"g",(function(){return it})),n.d(e,"h",(function(){return Tt})),n.d(e,"i",(function(){return h})),n.d(e,"j",(function(){return Ft}));var r=Object.freeze({__proto__:null,get start(){return Ft},get ensureJQuerySupport(){return dt},get setBootstrapMaxTime(){return q},get setMountMaxTime(){return Y},get setUnmountMaxTime(){return J},get setUnloadMaxTime(){return X},get registerApplication(){return Tt},get unregisterApplication(){return At},get getMountedApps(){return wt},get getAppStatus(){return St},get unloadApplication(){return Ct},get checkActivityFunctions(){return Et},get getAppNames(){return Mt},get pathToActiveWhen(){return Ot},get navigateToUrl(){return it},get triggerAppChange(){return Dt},get addErrorHandler(){return l},get removeErrorHandler(){return h},get mountRootParcel(){return G},get NOT_LOADED(){return p},get LOADING_SOURCE_CODE(){return m},get NOT_BOOTSTRAPPED(){return g},get BOOTSTRAPPING(){return v},get NOT_MOUNTED(){return y},get MOUNTING(){return _},get UPDATING(){return b},get LOAD_ERROR(){return M},get MOUNTED(){return x},get UNMOUNTING(){return w},get SKIP_BECAUSE_BROKEN(){return S}});function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var a=("undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==t?t:"undefined"!=typeof self?self:{}).CustomEvent,s=function(){try{var t=new a("cat",{detail:{foo:"bar"}});return"cat"===t.type&&"bar"===t.detail.foo}catch(t){}return!1}()?a:"undefined"!=typeof document&&"function"==typeof document.createEvent?function(t,e){var n=document.createEvent("CustomEvent");return e?n.initCustomEvent(t,e.bubbles,e.cancelable,e.detail):n.initCustomEvent(t,!1,!1,void 0),n}:function(t,e){var n=document.createEventObject();return n.type=t,e?(n.bubbles=Boolean(e.bubbles),n.cancelable=Boolean(e.cancelable),n.detail=e.detail):(n.bubbles=!1,n.cancelable=!1,n.detail=void 0),n},u=[];function c(t,e,n){var r=d(t,e,n);u.length?u.forEach((function(t){return t(r)})):setTimeout((function(){throw r}))}function l(t){if("function"!=typeof t)throw Error(f(28,!1));u.push(t)}function h(t){if("function"!=typeof t)throw Error(f(29,!1));var e=!1;return u=u.filter((function(n){var r=n===t;return e=e||r,!r})),e}function f(t,e){for(var n=arguments.length,r=new Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return"single-spa minified message #".concat(t,": ").concat(e?e+" ":"","See https://single-spa.js.org/error/?code=").concat(t).concat(r.length?"&arg=".concat(r.join("&arg=")):"")}function d(t,e,n){var r,i="".concat(P(e)," '").concat(A(e),"' died in status ").concat(e.status,": ");if(t instanceof Error){try{t.message=i+t.message}catch(t){}r=t}else{console.warn(f(30,!1,e.status,A(e)));try{r=Error(i+JSON.stringify(t))}catch(e){r=t}}return r.appOrParcelName=A(e),e.status=n,r}var p="NOT_LOADED",m="LOADING_SOURCE_CODE",g="NOT_BOOTSTRAPPED",v="BOOTSTRAPPING",y="NOT_MOUNTED",_="MOUNTING",x="MOUNTED",b="UPDATING",w="UNMOUNTING",M="LOAD_ERROR",S="SKIP_BECAUSE_BROKEN";function T(t){return t.status===x}function E(t){try{return t.activeWhen(window.location)}catch(e){return c(e,t,S),!1}}function A(t){return t.name}function C(t){return Boolean(t.unmountThisParcel)}function P(t){return C(t)?"parcel":"application"}function L(){for(var t=arguments.length-1;t>0;t--)for(var e in arguments[t])"__proto__"!==e&&(arguments[t-1][e]=arguments[t][e]);return arguments[0]}function O(t,e){for(var n=0;n<t.length;n++)if(e(t[n]))return t[n];return null}function R(t){return t&&("function"==typeof t||(e=t,Array.isArray(e)&&!O(e,(function(t){return"function"!=typeof t}))));var e}function k(t,e){var n=t[e]||[];0===(n=Array.isArray(n)?n:[n]).length&&(n=[function(){return Promise.resolve()}]);var r=P(t),i=A(t);return function(t){return n.reduce((function(n,o,a){return n.then((function(){var n=o(t);return I(n)?n:Promise.reject(f(15,!1,r,i,e,a))}))}),Promise.resolve())}}function I(t){return t&&"function"==typeof t.then&&"function"==typeof t.catch}function D(t,e){return Promise.resolve().then((function(){return t.status!==g?t:(t.status=v,t.bootstrap?$(t,"bootstrap").then(n).catch((function(n){if(e)throw d(n,t,S);return c(n,t,S),t})):Promise.resolve().then(n))}));function n(){return t.status=y,t}}function j(t,e){return Promise.resolve().then((function(){if(t.status!==x)return t;t.status=w;var n=Object.keys(t.parcels).map((function(e){return t.parcels[e].unmountThisParcel()}));return Promise.all(n).then(r,(function(n){return r().then((function(){var r=Error(n.message);if(e)throw d(r,t,S);c(r,t,S)}))})).then((function(){return t}));function r(){return $(t,"unmount").then((function(){t.status=y})).catch((function(n){if(e)throw d(n,t,S);c(n,t,S)}))}}))}var z=!1,N=!1;function F(t,e){return Promise.resolve().then((function(){return t.status!==y?t:(z||(window.dispatchEvent(new s("single-spa:before-first-mount")),z=!0),$(t,"mount").then((function(){return t.status=x,N||(window.dispatchEvent(new s("single-spa:first-mount")),N=!0),t})).catch((function(n){return t.status=x,j(t,!0).then(r,r);function r(){if(e)throw d(n,t,S);return c(n,t,S),t}})))}))}var B=0,H={parcels:{}};function G(){return U.apply(H,arguments)}function U(t,e){var n=this;if(!t||"object"!==i(t)&&"function"!=typeof t)throw Error(f(2,!1));if(t.name&&"string"!=typeof t.name)throw Error(f(3,!1,i(t.name)));if("object"!==i(e))throw Error(f(4,!1,name,i(e)));if(!e.domElement)throw Error(f(5,!1,name));var r,o=B++,a="function"==typeof t,s=a?t:function(){return Promise.resolve(t)},u={id:o,parcels:{},status:a?m:g,customProps:e,parentName:A(n),unmountThisParcel:function(){return v.then((function(){if(u.status!==x)throw Error(f(6,!1,name,u.status));return j(u,!0)})).then((function(t){return u.parentName&&delete n.parcels[u.id],t})).then((function(t){return l(t),t})).catch((function(t){throw u.status=S,h(t),t}))}};n.parcels[o]=u;var c=s();if(!c||"function"!=typeof c.then)throw Error(f(7,!1));var l,h,p=(c=c.then((function(t){if(!t)throw Error(f(8,!1));var e=t.name||"parcel-".concat(o);if(Object.prototype.hasOwnProperty.call(t,"bootstrap")&&!R(t.bootstrap))throw Error(f(9,!1,e));if(!R(t.mount))throw Error(f(10,!1,e));if(!R(t.unmount))throw Error(f(11,!1,e));if(t.update&&!R(t.update))throw Error(f(12,!1,e));var n=k(t,"bootstrap"),i=k(t,"mount"),a=k(t,"unmount");u.status=g,u.name=e,u.bootstrap=n,u.mount=i,u.unmount=a,u.timeouts=Q(t.timeouts),t.update&&(u.update=k(t,"update"),r.update=function(t){return u.customProps=t,W(function(t){return Promise.resolve().then((function(){if(t.status!==x)throw Error(f(32,!1,A(t)));return t.status=b,$(t,"update").then((function(){return t.status=x,t})).catch((function(e){throw d(e,t,S)}))}))}(u))})}))).then((function(){return D(u,!0)})),v=p.then((function(){return F(u,!0)})),_=new Promise((function(t,e){l=t,h=e}));return r={mount:function(){return W(Promise.resolve().then((function(){if(u.status!==y)throw Error(f(13,!1,name,u.status));return n.parcels[o]=u,F(u)})))},unmount:function(){return W(u.unmountThisParcel())},getStatus:function(){return u.status},loadPromise:W(c),bootstrapPromise:W(p),mountPromise:W(v),unmountPromise:W(_)}}function W(t){return t.then((function(){return null}))}function V(t){var e=A(t),n="function"==typeof t.customProps?t.customProps(e,window.location):t.customProps;("object"!==i(n)||null===n||Array.isArray(n))&&(n={},console.warn(f(40,!1),e,n));var o=L({},n,{name:e,mountParcel:U.bind(t),singleSpa:r});return C(t)&&(o.unmountSelf=t.unmountThisParcel),o}var Z={bootstrap:{millis:4e3,dieOnTimeout:!1,warningMillis:1e3},mount:{millis:3e3,dieOnTimeout:!1,warningMillis:1e3},unmount:{millis:3e3,dieOnTimeout:!1,warningMillis:1e3},unload:{millis:3e3,dieOnTimeout:!1,warningMillis:1e3},update:{millis:3e3,dieOnTimeout:!1,warningMillis:1e3}};function q(t,e,n){if("number"!=typeof t||t<=0)throw Error(f(16,!1));Z.bootstrap={millis:t,dieOnTimeout:e,warningMillis:n||1e3}}function Y(t,e,n){if("number"!=typeof t||t<=0)throw Error(f(17,!1));Z.mount={millis:t,dieOnTimeout:e,warningMillis:n||1e3}}function J(t,e,n){if("number"!=typeof t||t<=0)throw Error(f(18,!1));Z.unmount={millis:t,dieOnTimeout:e,warningMillis:n||1e3}}function X(t,e,n){if("number"!=typeof t||t<=0)throw Error(f(19,!1));Z.unload={millis:t,dieOnTimeout:e,warningMillis:n||1e3}}function $(t,e){var n=t.timeouts[e],r=n.warningMillis,i=P(t);return new Promise((function(o,a){var s=!1,u=!1;t[e](V(t)).then((function(t){s=!0,o(t)})).catch((function(t){s=!0,a(t)})),setTimeout((function(){return l(1)}),r),setTimeout((function(){return l(!0)}),n.millis);var c=f(31,!1,e,i,A(t),n.millis);function l(t){if(!s)if(!0===t)u=!0,n.dieOnTimeout?a(Error(c)):console.error(c);else if(!u){var e=t,i=e*r;console.warn(c),i+r<n.millis&&setTimeout((function(){return l(e+1)}),r)}}}))}function Q(t){var e={};for(var n in Z)e[n]=L({},Z[n],t&&t[n]||{});return e}function K(t){return Promise.resolve().then((function(){return t.loadPromise?t.loadPromise:t.status!==p&&t.status!==M?t:(t.status=m,t.loadPromise=Promise.resolve().then((function(){var r=t.loadApp(V(t));if(!I(r))throw n=!0,Error(f(33,!1,A(t)));return r.then((function(n){var r;t.loadErrorTime=null,"object"!==i(e=n)&&(r=34),Object.prototype.hasOwnProperty.call(e,"bootstrap")&&!R(e.bootstrap)&&(r=35),R(e.mount)||(r=36),R(e.unmount)||(r=37);var o=P(e);if(r){var a;try{a=JSON.stringify(e)}catch(t){}return console.error(f(r,!1,o,A(t),a),e),c(void 0,t,S),t}return e.devtools&&e.devtools.overlays&&(t.devtools.overlays=L({},t.devtools.overlays,e.devtools.overlays)),t.status=g,t.bootstrap=k(e,"bootstrap"),t.mount=k(e,"mount"),t.unmount=k(e,"unmount"),t.unload=k(e,"unload"),t.timeouts=Q(e.timeouts),delete t.loadPromise,t}))})).catch((function(e){var r;return delete t.loadPromise,n?r=S:(r=M,t.loadErrorTime=(new Date).getTime()),c(e,t,r),t})));var e,n}))}var tt,et="undefined"!=typeof window,nt={hashchange:[],popstate:[]},rt=["hashchange","popstate"];function it(t){var e;if("string"==typeof t)e=t;else if(this&&this.href)e=this.href;else{if(!(t&&t.currentTarget&&t.currentTarget.href&&t.preventDefault))throw Error(f(14,!1));e=t.currentTarget.href,t.preventDefault()}var n=ht(window.location.href),r=ht(e);0===e.indexOf("#")?window.location.hash=r.hash:n.host!==r.host&&r.host?window.location.href=e:r.pathname===n.pathname&&r.search===n.search?window.location.hash=r.hash:window.history.pushState(null,null,e)}function ot(t){var e=this;if(t){var n=t[0].type;rt.indexOf(n)>=0&&nt[n].forEach((function(n){try{n.apply(e,t)}catch(t){setTimeout((function(){throw t}))}}))}}function at(){jt([],arguments)}function st(t,e){return function(){var n=window.location.href,r=t.apply(this,arguments),i=window.location.href;return tt&&n===i||(Bt()?window.dispatchEvent(ut(window.history.state,e)):jt([])),r}}function ut(t,e){var n;try{n=new PopStateEvent("popstate",{state:t})}catch(e){(n=document.createEvent("PopStateEvent")).initPopStateEvent("popstate",!1,!1,t)}return n.singleSpa=!0,n.singleSpaTrigger=e,n}if(et){window.addEventListener("hashchange",at),window.addEventListener("popstate",at);var ct=window.addEventListener,lt=window.removeEventListener;window.addEventListener=function(t,e){if(!("function"==typeof e&&rt.indexOf(t)>=0)||O(nt[t],(function(t){return t===e})))return ct.apply(this,arguments);nt[t].push(e)},window.removeEventListener=function(t,e){if(!("function"==typeof e&&rt.indexOf(t)>=0))return lt.apply(this,arguments);nt[t]=nt[t].filter((function(t){return t!==e}))},window.history.pushState=st(window.history.pushState,"pushState"),window.history.replaceState=st(window.history.replaceState,"replaceState"),window.singleSpaNavigate?console.warn(f(41,!1)):window.singleSpaNavigate=it}function ht(t){var e=document.createElement("a");return e.href=t,e}var ft=!1;function dt(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:window.jQuery;if(t||window.$&&window.$.fn&&window.$.fn.jquery&&(t=window.$),t&&!ft){var e=t.fn.on,n=t.fn.off;t.fn.on=function(t,n){return pt.call(this,e,window.addEventListener,t,n,arguments)},t.fn.off=function(t,e){return pt.call(this,n,window.removeEventListener,t,e,arguments)},ft=!0}}function pt(t,e,n,r,i){return"string"!=typeof n?t.apply(this,i):(n.split(/\s+/).forEach((function(t){rt.indexOf(t)>=0&&(e(t,r),n=n.replace(t,""))})),""===n.trim()?this:t.apply(this,i))}var mt={};function gt(t){return Promise.resolve().then((function(){var e=mt[A(t)];if(!e)return t;if(t.status===p)return vt(t,e),t;if("UNLOADING"===t.status)return e.promise.then((function(){return t}));if(t.status!==y&&t.status!==M)return t;var n=t.status===M?Promise.resolve():$(t,"unload");return t.status="UNLOADING",n.then((function(){return vt(t,e),t})).catch((function(n){return function(t,e,n){delete mt[A(t)],delete t.bootstrap,delete t.mount,delete t.unmount,delete t.unload,c(n,t,S),e.reject(n)}(t,e,n),t}))}))}function vt(t,e){delete mt[A(t)],delete t.bootstrap,delete t.mount,delete t.unmount,delete t.unload,t.status=p,e.resolve()}function yt(t,e,n,r){mt[A(t)]={app:t,resolve:n,reject:r},Object.defineProperty(mt[A(t)],"promise",{get:e})}function _t(t){return mt[t]}var xt=[];function bt(){var t=[],e=[],n=[],r=[],i=(new Date).getTime();return xt.forEach((function(o){var a=o.status!==S&&E(o);switch(o.status){case M:a&&i-o.loadErrorTime>=200&&n.push(o);break;case p:case m:a&&n.push(o);break;case g:case y:!a&&_t(A(o))?t.push(o):a&&r.push(o);break;case x:a||e.push(o)}})),{appsToUnload:t,appsToUnmount:e,appsToLoad:n,appsToMount:r}}function wt(){return xt.filter(T).map(A)}function Mt(){return xt.map(A)}function St(t){var e=O(xt,(function(e){return A(e)===t}));return e?e.status:null}function Tt(t,e,n,r){var o=function(t,e,n,r){var o,a={name:null,loadApp:null,activeWhen:null,customProps:null};return"object"===i(t)?(function(t){if(Array.isArray(t)||null===t)throw Error(f(39,!1));var e=["name","app","activeWhen","customProps"],n=Object.keys(t).reduce((function(t,n){return e.indexOf(n)>=0?t:t.concat(n)}),[]);if(0!==n.length)throw Error(f(38,!1,e.join(", "),n.join(", ")));if("string"!=typeof t.name||0===t.name.length)throw Error(f(20,!1));if("object"!==i(t.app)&&"function"!=typeof t.app)throw Error(f(20,!1));var r=function(t){return"string"==typeof t||"function"==typeof t};if(!(r(t.activeWhen)||Array.isArray(t.activeWhen)&&t.activeWhen.every(r)))throw Error(f(24,!1));if(!Lt(t.customProps))throw Error(f(22,!1))}(t),a.name=t.name,a.loadApp=t.app,a.activeWhen=t.activeWhen,a.customProps=t.customProps):(function(t,e,n,r){if("string"!=typeof t||0===t.length)throw Error(f(20,!1));if(!e)throw Error(f(23,!1));if("function"!=typeof n)throw Error(f(24,!1));if(!Lt(r))throw Error(f(22,!1))}(t,e,n,r),a.name=t,a.loadApp=e,a.activeWhen=n,a.customProps=r),a.loadApp="function"!=typeof(o=a.loadApp)?function(){return Promise.resolve(o)}:o,a.customProps=function(t){return t||{}}(a.customProps),a.activeWhen=function(t){var e=Array.isArray(t)?t:[t];return e=e.map((function(t){return"function"==typeof t?t:Ot(t)})),function(t){return e.some((function(e){return e(t)}))}}(a.activeWhen),a}(t,e,n,r);if(-1!==Mt().indexOf(o.name))throw Error(f(21,!1,o.name));xt.push(L({loadErrorTime:null,status:p,parcels:{},devtools:{overlays:{options:{},selectors:[]}}},o)),et&&(dt(),jt())}function Et(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:window.location;return xt.filter((function(e){return e.activeWhen(t)})).map(A)}function At(t){if(0===xt.filter((function(e){return A(e)===t})).length)throw Error(f(25,!1,t));return Ct(t).then((function(){var e=xt.map(A).indexOf(t);xt.splice(e,1)}))}function Ct(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{waitForUnmount:!1};if("string"!=typeof t)throw Error(f(26,!1));var n=O(xt,(function(e){return A(e)===t}));if(!n)throw Error(f(27,!1,t));var r,i=_t(A(n));if(e&&e.waitForUnmount){if(i)return i.promise;var o=new Promise((function(t,e){yt(n,(function(){return o}),t,e)}));return o}return i?(r=i.promise,Pt(n,i.resolve,i.reject)):r=new Promise((function(t,e){yt(n,(function(){return r}),t,e),Pt(n,t,e)})),r}function Pt(t,e,n){j(t).then(gt).then((function(){e(),setTimeout((function(){jt()}))})).catch(n)}function Lt(t){return!t||"function"==typeof t||"object"===i(t)&&null!==t&&!Array.isArray(t)}function Ot(t,e){var n=function(t,e){var n=0,r=!1,i="^";"/"!==t[0]&&(t="/"+t);for(var o=0;o<t.length;o++){var a=t[o];(!r&&":"===a||r&&"/"===a)&&s(o)}return s(t.length),new RegExp(i,"i");function s(o){var a=t.slice(n,o).replace(/[|\\{}()[\]^$+*?.]/g,"\\$&");if(i+=r?"[^/]+/?":a,o===t.length)if(r)e&&(i+="$");else{var s=e?"":".*";i="/"===i.charAt(i.length-1)?"".concat(i).concat(s,"$"):"".concat(i,"(/").concat(s,")?(#.*)?$")}r=!r,n=o}}(t,e);return function(t){var e=t.origin;e||(e="".concat(t.protocol,"//").concat(t.host));var r=t.href.replace(e,"").replace(t.search,"").split("?")[0];return n.test(r)}}var Rt=!1,kt=[],It=et&&window.location.href;function Dt(){return jt()}function jt(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],e=arguments.length>1?arguments[1]:void 0;if(Rt)return new Promise((function(t,n){kt.push({resolve:t,reject:n,eventArguments:e})}));var n,r=bt(),i=r.appsToUnload,a=r.appsToUnmount,u=r.appsToLoad,c=r.appsToMount,l=!1,h=It,f=It=window.location.href;return Bt()?(Rt=!0,n=i.concat(u,a,c),g()):(n=u,m());function d(){l=!0}function m(){return Promise.resolve().then((function(){var t=u.map(K);return Promise.all(t).then(_).then((function(){return[]})).catch((function(t){throw _(),t}))}))}function g(){return Promise.resolve().then((function(){if(window.dispatchEvent(new s(0===n.length?"single-spa:before-no-app-change":"single-spa:before-app-change",b(!0))),window.dispatchEvent(new s("single-spa:before-routing-event",b(!0,{cancelNavigation:d}))),l)return window.dispatchEvent(new s("single-spa:before-mount-routing-event",b(!0))),v(),void it(h);var e=i.map(gt),r=a.map(j).map((function(t){return t.then(gt)})).concat(e),o=Promise.all(r);o.then((function(){window.dispatchEvent(new s("single-spa:before-mount-routing-event",b(!0)))}));var f=u.map((function(t){return K(t).then((function(t){return zt(t,o)}))})),p=c.filter((function(t){return u.indexOf(t)<0})).map((function(t){return zt(t,o)}));return o.catch((function(t){throw _(),t})).then((function(){return _(),Promise.all(f.concat(p)).catch((function(e){throw t.forEach((function(t){return t.reject(e)})),e})).then(v)}))}))}function v(){var e=wt();t.forEach((function(t){return t.resolve(e)}));try{var r=0===n.length?"single-spa:no-app-change":"single-spa:app-change";window.dispatchEvent(new s(r,b())),window.dispatchEvent(new s("single-spa:routing-event",b()))}catch(t){setTimeout((function(){throw t}))}if(Rt=!1,kt.length>0){var i=kt;kt=[],jt(i)}return e}function _(){t.forEach((function(t){ot(t.eventArguments)})),ot(e)}function b(){var t,r=arguments.length>0&&void 0!==arguments[0]&&arguments[0],s=arguments.length>1?arguments[1]:void 0,d={},m=(o(t={},x,[]),o(t,y,[]),o(t,p,[]),o(t,S,[]),t);r?(u.concat(c).forEach((function(t,e){v(t,x)})),i.forEach((function(t){v(t,p)})),a.forEach((function(t){v(t,y)}))):n.forEach((function(t){v(t)}));var g={detail:{newAppStatuses:d,appsByNewStatus:m,totalAppChanges:n.length,originalEvent:null==e?void 0:e[0],oldUrl:h,newUrl:f,navigationIsCanceled:l}};return s&&L(g.detail,s),g;function v(t,e){var n=A(t);e=e||St(n),d[n]=e,(m[e]=m[e]||[]).push(n)}}}function zt(t,e){return E(t)?D(t).then((function(t){return e.then((function(){return E(t)?F(t):t}))})):e.then((function(){return t}))}var Nt=!1;function Ft(t){var e;Nt=!0,t&&t.urlRerouteOnly&&(e=t.urlRerouteOnly,tt=e),et&&jt()}function Bt(){return Nt}et&&setTimeout((function(){Nt||console.warn(f(1,!1))}),5e3);var Ht={getRawAppData:function(){return[].concat(xt)},reroute:jt,NOT_LOADED:p,toLoadPromise:K,toBootstrapPromise:D,unregisterApplication:At};et&&window.__SINGLE_SPA_DEVTOOLS__&&(window.__SINGLE_SPA_DEVTOOLS__.exposedMethods=Ht)}).call(this,n(20))},function(t,e,n){var r=n(28),i=n(12);t.exports=function(t){if(!i(t))return!1;var e=r(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}},function(t,e,n){"use strict";var r=n(122),i=Object.prototype.toString;function o(t){return"[object Array]"===i.call(t)}function a(t){return void 0===t}function s(t){return null!==t&&"object"==typeof t}function u(t){if("[object Object]"!==i.call(t))return!1;var e=Object.getPrototypeOf(t);return null===e||e===Object.prototype}function c(t){return"[object Function]"===i.call(t)}function l(t,e){if(null!=t)if("object"!=typeof t&&(t=[t]),o(t))for(var n=0,r=t.length;n<r;n++)e.call(null,t[n],n,t);else for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&e.call(null,t[i],i,t)}t.exports={isArray:o,isArrayBuffer:function(t){return"[object ArrayBuffer]"===i.call(t)},isBuffer:function(t){return null!==t&&!a(t)&&null!==t.constructor&&!a(t.constructor)&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t)},isFormData:function(t){return"undefined"!=typeof FormData&&t instanceof FormData},isArrayBufferView:function(t){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(t):t&&t.buffer&&t.buffer instanceof ArrayBuffer},isString:function(t){return"string"==typeof t},isNumber:function(t){return"number"==typeof t},isObject:s,isPlainObject:u,isUndefined:a,isDate:function(t){return"[object Date]"===i.call(t)},isFile:function(t){return"[object File]"===i.call(t)},isBlob:function(t){return"[object Blob]"===i.call(t)},isFunction:c,isStream:function(t){return s(t)&&c(t.pipe)},isURLSearchParams:function(t){return"undefined"!=typeof URLSearchParams&&t instanceof URLSearchParams},isStandardBrowserEnv:function(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&("undefined"!=typeof window&&"undefined"!=typeof document)},forEach:l,merge:function t(){var e={};function n(n,r){u(e[r])&&u(n)?e[r]=t(e[r],n):u(n)?e[r]=t({},n):o(n)?e[r]=n.slice():e[r]=n}for(var r=0,i=arguments.length;r<i;r++)l(arguments[r],n);return e},extend:function(t,e,n){return l(e,(function(e,i){t[i]=n&&"function"==typeof e?r(e,n):e})),t},trim:function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")},stripBOM:function(t){return 65279===t.charCodeAt(0)&&(t=t.slice(1)),t}}},function(t,e){var n=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(t,e,n){var r=n(102)("wks"),i=n(103),o=n(5).Symbol,a="function"==typeof o;(t.exports=function(t){return r[t]||(r[t]=a&&o[t]||(a?o:i)("Symbol."+t))}).store=r},function(t,e,n){var r=n(5),i=n(1),o=n(29),a=n(23),s=n(37),u=function(t,e,n){var c,l,h,f=t&u.F,d=t&u.G,p=t&u.S,m=t&u.P,g=t&u.B,v=t&u.W,y=d?i:i[e]||(i[e]={}),_=y.prototype,x=d?r:p?r[e]:(r[e]||{}).prototype;for(c in d&&(n=e),n)(l=!f&&x&&void 0!==x[c])&&s(y,c)||(h=l?x[c]:n[c],y[c]=d&&"function"!=typeof x[c]?n[c]:g&&l?o(h,r):v&&x[c]==h?function(t){var e=function(e,n,r){if(this instanceof t){switch(arguments.length){case 0:return new t;case 1:return new t(e);case 2:return new t(e,n)}return new t(e,n,r)}return t.apply(this,arguments)};return e.prototype=t.prototype,e}(h):m&&"function"==typeof h?o(Function.call,h):h,m&&((y.virtual||(y.virtual={}))[c]=h,t&u.R&&_&&!_[c]&&a(_,c,h)))};u.F=1,u.G=2,u.S=4,u.P=8,u.B=16,u.W=32,u.U=64,u.R=128,t.exports=u},function(t,e,n){(function(t,r){var i;
2
2
  /**
3
3
  * @license
4
4
  * Lodash <https://lodash.com/>
@@ -11,7 +11,7 @@
11
11
  Copyright (c) 2018 Jed Watson.
12
12
  Licensed under the MIT License (MIT), see
13
13
  http://jedwatson.github.io/classnames
14
- */!function(){"use strict";var n={}.hasOwnProperty;function i(){for(var t=[],e=0;e<arguments.length;e++){var r=arguments[e];if(r){var o=typeof r;if("string"===o||"number"===o)t.push(r);else if(Array.isArray(r)){if(r.length){var a=i.apply(null,r);a&&t.push(a)}}else if("object"===o)if(r.toString===Object.prototype.toString)for(var s in r)n.call(r,s)&&r[s]&&t.push(s);else t.push(r.toString())}}return t.join(" ")}t.exports?(i.default=i,t.exports=i):void 0===(r=function(){return i}.apply(e,[]))||(t.exports=r)}()},function(t,e,n){var r=n(382);t.exports=function(t){return r(t,5)}},function(t,e){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(t){"object"==typeof window&&(n=window)}t.exports=n},function(t,e,n){"use strict";e.__esModule=!0;var r,i=n(179),o=(r=i)&&r.__esModule?r:{default:r};e.default=o.default||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t}},function(t,e,n){var r=n(291),i=n(294);t.exports=function(t,e){var n=i(t,e);return r(n)?n:void 0}},function(t,e,n){var r=n(24),i=n(71);t.exports=n(16)?function(t,e,n){return r.f(t,e,i(1,n))}:function(t,e,n){return t[e]=n,t}},function(t,e,n){var r=n(15),i=n(171),o=n(172),a=Object.defineProperty;e.f=n(16)?Object.defineProperty:function(t,e,n){if(r(t),e=o(e,!0),r(n),i)try{return a(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(t[e]=n.value),t}},function(t,e){t.exports={}},function(t,e,n){(function(e){var n=Object.assign?Object.assign:function(t,e,n,r){for(var i=1;i<arguments.length;i++)s(Object(arguments[i]),(function(e,n){t[n]=e}));return t},r=function(){if(Object.create)return function(t,e,r,i){var o=a(arguments,1);return n.apply(this,[Object.create(t)].concat(o))};{function t(){}return function(e,r,i,o){var s=a(arguments,1);return t.prototype=e,n.apply(this,[new t].concat(s))}}}(),i=String.prototype.trim?function(t){return String.prototype.trim.call(t)}:function(t){return t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")},o="undefined"!=typeof window?window:e;function a(t,e){return Array.prototype.slice.call(t,e||0)}function s(t,e){u(t,(function(t,n){return e(t,n),!1}))}function u(t,e){if(c(t)){for(var n=0;n<t.length;n++)if(e(t[n],n))return t[n]}else for(var r in t)if(t.hasOwnProperty(r)&&e(t[r],r))return t[r]}function c(t){return null!=t&&"function"!=typeof t&&"number"==typeof t.length}t.exports={assign:n,create:r,trim:i,bind:function(t,e){return function(){return e.apply(t,Array.prototype.slice.call(arguments,0))}},slice:a,each:s,map:function(t,e){var n=c(t)?[]:{};return u(t,(function(t,r){return n[r]=e(t,r),!1})),n},pluck:u,isList:c,isFunction:function(t){return t&&"[object Function]"==={}.toString.call(t)},isObject:function(t){return t&&"[object Object]"==={}.toString.call(t)},Global:o}}).call(this,n(20))},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getBelongList=e.getRegionDataInfo=e.postConsumer=e.getByCuser=e.getUserInfo=e.refreshToken=e.getToken=void 0;var r=a(n(120)),i=n(13),o=a(n(234));function a(t){return t&&t.__esModule?t:{default:t}}var s="/iam/v1/sys/refresh/token",u="/iam/v1/sys/oauth/token",c="/iam/v1/sys/user/info",l="/iam/v1/sys/system/getByCuser",h="/iam/v1/sys/user/exchange/consumer",f="https://gateway-bmg-out.rockontrol.com/bmg/v1/apply/weather/{areaCode}",d="/iam/v1/sys/consumer/belongBySysList";e.getToken=function(t){return r.default.post(""+i.sessionStore.get("IAM_BASE_URL")+u,t)},e.refreshToken=function(t){return r.default.post(""+i.sessionStore.get("IAM_BASE_URL")+s,o.default.stringify(t),{"Content-Type":"application/x-www-form-urlencoded"})},e.getUserInfo=function(t,e){return r.default.get(""+i.sessionStore.get("IAM_BASE_URL")+c,t,e)},e.getByCuser=function(t){return r.default.get(""+sessionStorage.getItem("IAM_BASE_URL")+l,t)},e.postConsumer=function(t){return r.default.post(""+sessionStorage.getItem("IAM_BASE_URL")+h+"/"+t)},e.getRegionDataInfo=function(t){return r.default.get(f,t)},e.getBelongList=function(t){return r.default.get(""+sessionStorage.getItem("IAM_BASE_URL")+d,t)}},function(t,e,n){var r=n(31),i=n(251),o=n(252),a=r?r.toStringTag:void 0;t.exports=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":a&&a in Object(t)?i(t):o(t)}},function(t,e,n){var r=n(40);t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,i){return t.call(e,n,r,i)}}return function(){return t.apply(e,arguments)}}},function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,e,n){var r=n(11).Symbol;t.exports=r},function(t,e,n){var r=n(3),i=n(90);t.exports=function(t){return null!=t&&i(t.length)&&!r(t)}},function(t,e,n){var r=n(88),i=n(89);t.exports=function(t,e,n,o){var a=!n;n||(n={});for(var s=-1,u=e.length;++s<u;){var c=e[s],l=o?o(n[c],t[c],c,n,t):void 0;void 0===l&&(l=t[c]),a?i(n,c,l):r(n,c,l)}return n}},function(t,e,n){var r=n(155),i=n(366),o=n(32);t.exports=function(t){return o(t)?r(t,!0):i(t)}},function(t,e,n){var r=n(65);t.exports=function(t){return Object(r(t))}},function(t,e,n){var r=n(167),i=n(104);t.exports=Object.keys||function(t){return r(t,i)}},function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},function(t,e,n){var r=n(101),i=n(65);t.exports=function(t){return r(i(t))}},function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},function(t,e){t.exports=function(t){try{return!!t()}catch(t){return!0}}},function(t,e,n){"use strict";e.__esModule=!0,e.default=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}},function(t,e,n){"use strict";e.__esModule=!0;var r,i=n(173),o=(r=i)&&r.__esModule?r:{default:r};e.default=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),(0,o.default)(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}()},function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),t.webpackPolyfill=1),t}},function(t,e,n){t.exports={default:n(188),__esModule:!0}},function(t,e,n){"use strict";var r=n(190)(!0);n(106)(String,"String",(function(t){this._t=String(t),this._i=0}),(function(){var t,e=this._t,n=this._i;return n>=e.length?{value:void 0,done:!0}:(t=r(e,n),this._i+=t.length,{value:t,done:!1})}))},function(t,e,n){t.exports={default:n(242),__esModule:!0}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isFunction=e.notFoundRouter=e.loadView=e.getUrlParam=e.hasOwn=void 0;var r=u(n(21)),i=u(n(244)),o=u(n(47)),a=u(n(247));e.mergeProps=function(){var t=[].slice.call(arguments,0),e={};return t.forEach((function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=!0,u=!1,c=void 0;try{for(var l,h=(0,o.default)((0,i.default)(t));!(n=(l=h.next()).done);n=!0){var f=l.value,d=(0,a.default)(f,2),p=d[0],m=d[1];e[p]=e[p]||{},(0,s.default)(m)?(0,r.default)(e[p],m):e[p]=m}}catch(t){u=!0,c=t}finally{try{!n&&h.return&&h.return()}finally{if(u)throw c}}})),e};var s=u(n(134));function u(t){return t&&t.__esModule?t:{default:t}}var c=Object.prototype,l=c.toString;e.hasOwn=c.hasOwnProperty,e.getUrlParam=function(t){var e=new RegExp("(^|&)"+t+"=([^&]*)(&|$)"),n=window.location.search.split("?")[1]?window.location.search.split("?")[1].match(e):null;return null!=n?decodeURI(n[2]):null},e.loadView=function(t,e,r){return function(r){n.e(1).then(function(){var i=[n(403)("./"+e+t+".vue")];r.apply(null,i)}.bind(this)).catch(n.oe)}},e.notFoundRouter={path:"*",redirect:"/404",hidden:!0};e.isFunction=function(t){return"[object Function]"===l.call(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={name:"BlankLayout",render:function(){var t=arguments[0];return t("router-view")}}},function(t,e,n){var r=n(10),i=n(284),o=n(285),a=n(86);t.exports=function(t,e){return r(t)?t:i(t,e)?[t]:o(a(t))}},function(t,e,n){var r=n(28),i=n(17);t.exports=function(t){return"symbol"==typeof t||i(t)&&"[object Symbol]"==r(t)}},function(t,e,n){var r=n(22)(Object,"create");t.exports=r},function(t,e,n){var r=n(299),i=n(300),o=n(301),a=n(302),s=n(303);function u(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=i,u.prototype.get=o,u.prototype.has=a,u.prototype.set=s,t.exports=u},function(t,e,n){var r=n(55);t.exports=function(t,e){for(var n=t.length;n--;)if(r(t[n][0],e))return n;return-1}},function(t,e){t.exports=function(t,e){return t===e||t!=t&&e!=e}},function(t,e,n){var r=n(305);t.exports=function(t,e){var n=t.__data__;return r(e)?n["string"==typeof e?"string":"hash"]:n.map}},function(t,e){var n=/^(?:0|[1-9]\d*)$/;t.exports=function(t,e){var r=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==r||"symbol"!=r&&n.test(t))&&t>-1&&t%1==0&&t<e}},function(t,e,n){var r=n(315),i=n(17),o=Object.prototype,a=o.hasOwnProperty,s=o.propertyIsEnumerable,u=r(function(){return arguments}())?r:function(t){return i(t)&&a.call(t,"callee")&&!s.call(t,"callee")};t.exports=u},function(t,e){t.exports=function(t,e){for(var n=-1,r=e.length,i=t.length;++n<r;)t[i+n]=e[n];return t}},function(t,e,n){var r=n(155),i=n(373),o=n(32);t.exports=function(t){return o(t)?r(t):i(t)}},function(t,e,n){var r=n(59),i=n(144),o=n(92),a=n(10);t.exports=function(){var t=arguments.length;if(!t)return[];for(var e=Array(t-1),n=arguments[0],s=t;s--;)e[s-1]=arguments[s];return r(a(n)?o(n):[n],i(e,1))}},function(t,e,n){var r=n(351),i=n(368)((function(t,e,n,i){r(t,e,n,i)}));t.exports=i},function(t,e){function n(e){return t.exports=n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.__esModule=!0,t.exports.default=t.exports,n(e)}t.exports=n,t.exports.__esModule=!0,t.exports.default=t.exports},function(t,e,n){var r=n(377),i=n(378),o=n(379),a=n(381);t.exports=function(t,e){return r(t)||i(t,e)||o(t,e)||a()},t.exports.__esModule=!0,t.exports.default=t.exports},function(t,e){t.exports=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t}},function(t,e,n){var r=n(67),i=Math.min;t.exports=function(t){return t>0?i(r(t),9007199254740991):0}},function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?r:n)(t)}},function(t,e,n){var r=n(102)("keys"),i=n(103);t.exports=function(t){return r[t]||(r[t]=i(t))}},function(t,e){t.exports=!0},function(t,e,n){var r=n(30),i=n(5).document,o=r(i)&&r(i.createElement);t.exports=function(t){return o?i.createElement(t):{}}},function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},function(t,e,n){t.exports=n(186)},function(t,e,n){"use strict";e.__esModule=!0;var r,i=n(45),o=(r=i)&&r.__esModule?r:{default:r};e.default=function(t){return function(){var e=t.apply(this,arguments);return new o.default((function(t,n){return function r(i,a){try{var s=e[i](a),u=s.value}catch(t){return void n(t)}if(!s.done)return o.default.resolve(u).then((function(t){r("next",t)}),(function(t){r("throw",t)}));t(u)}("next")}))}}},function(t,e,n){var r=n(24).f,i=n(37),o=n(6)("toStringTag");t.exports=function(t,e,n){t&&!i(t=n?t:t.prototype,o)&&r(t,o,{configurable:!0,value:e})}},function(t,e,n){n(196);for(var r=n(5),i=n(23),o=n(25),a=n(6)("toStringTag"),s="CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,MediaList,MimeTypeArray,NamedNodeMap,NodeList,PaintRequestList,Plugin,PluginArray,SVGLengthList,SVGNumberList,SVGPathSegList,SVGPointList,SVGStringList,SVGTransformList,SourceBufferList,StyleSheetList,TextTrackCueList,TextTrackList,TouchList".split(","),u=0;u<s.length;u++){var c=s[u],l=r[c],h=l&&l.prototype;h&&!h[a]&&i(h,a,c),o[c]=o.Array}},function(t,e,n){var r=n(39),i=n(6)("toStringTag"),o="Arguments"==r(function(){return arguments}());t.exports=function(t){var e,n,a;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=function(t,e){try{return t[e]}catch(t){}}(e=Object(t),i))?n:o?r(e):"Object"==(a=r(e))&&"function"==typeof e.callee?"Arguments":a}},function(t,e,n){var r=n(76),i=n(6)("iterator"),o=n(25);t.exports=n(1).getIteratorMethod=function(t){if(null!=t)return t[i]||t["@@iterator"]||o[r(t)]}},function(t,e,n){"use strict";var r=n(40);function i(t){var e,n;this.promise=new t((function(t,r){if(void 0!==e||void 0!==n)throw TypeError("Bad Promise constructor");e=t,n=r})),this.resolve=r(e),this.reject=r(n)}t.exports.f=function(t){return new i(t)}},function(t,e,n){"use strict";(function(e){var r=n(4),i=n(221),o=n(125),a={"Content-Type":"application/x-www-form-urlencoded"};function s(t,e){!r.isUndefined(t)&&r.isUndefined(t["Content-Type"])&&(t["Content-Type"]=e)}var u,c={transitional:{silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},adapter:(("undefined"!=typeof XMLHttpRequest||void 0!==e&&"[object process]"===Object.prototype.toString.call(e))&&(u=n(126)),u),transformRequest:[function(t,e){return i(e,"Accept"),i(e,"Content-Type"),r.isFormData(t)||r.isArrayBuffer(t)||r.isBuffer(t)||r.isStream(t)||r.isFile(t)||r.isBlob(t)?t:r.isArrayBufferView(t)?t.buffer:r.isURLSearchParams(t)?(s(e,"application/x-www-form-urlencoded;charset=utf-8"),t.toString()):r.isObject(t)||e&&"application/json"===e["Content-Type"]?(s(e,"application/json"),function(t,e,n){if(r.isString(t))try{return(e||JSON.parse)(t),r.trim(t)}catch(t){if("SyntaxError"!==t.name)throw t}return(n||JSON.stringify)(t)}(t)):t}],transformResponse:[function(t){var e=this.transitional,n=e&&e.silentJSONParsing,i=e&&e.forcedJSONParsing,a=!n&&"json"===this.responseType;if(a||i&&r.isString(t)&&t.length)try{return JSON.parse(t)}catch(t){if(a){if("SyntaxError"===t.name)throw o(t,this,"E_JSON_PARSE");throw t}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(t){return t>=200&&t<300}};c.headers={common:{Accept:"application/json, text/plain, */*"}},r.forEach(["delete","get","head"],(function(t){c.headers[t]={}})),r.forEach(["post","put","patch"],(function(t){c.headers[t]=r.merge(a)})),t.exports=c}).call(this,n(124))},function(t,e,n){var r=n(136)(Object.getPrototypeOf,Object);t.exports=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(13),i=n(9),o=n(27),a=n(8);e.default={name:"AppLogo",inject:["slotsList"],props:{prefix:{type:String,default:"basic"},theme:{type:String,default:"light"}},computed:{currentConsumer:function(){return r.localStore.get("consumer")}},data:function(){return{currentInfo:{icon:void 0,name:void 0}}},mounted:function(){this.getByCuserInfo()},methods:{getByCuserInfo:function(){var t=this,e=r.sessionStore.get("CLIENT_ID");(0,o.getByCuser)().then((function(n){var i=(0,a.filter)(n.data,(function(t){return t.code===e}));i&&!(0,a.isEmpty)(i)&&(t.currentInfo=i[0],i&&i[0]&&i[0].name&&r.sessionStore.set("SYS_PROJECT_NAME",i[0].name))}))}},render:function(){var t=arguments[0],e=this.prefix,n=this.theme,r=i.prefixCls+"-logo";return t("div",{class:[r,r+"-"+e]},[t("div",{class:[r+"-"+e+"-inner",r+"-inner",r+"-"+n+"-inner"]},[t("img",{attrs:{src:this.currentInfo.icon?this.currentInfo.icon:"https://daqilianfangliankong.obs.cn-north-4.myhuaweicloud.com/IAM/1437955217135501312.png"}}),t("span",{class:[r+"-"+e+"-title",r+"-title"]},[this.currentInfo.name])]),this.slotsList.logoMark?t("div",{class:r+"-mark-inner"},[this.slotsList.logoMark]):null])}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(264),o=(r=i)&&r.__esModule?r:{default:r};e.default=new o.default},function(module,exports,__webpack_require__){(function(setImmediate){var e;e=function(){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=0)}({0:function(t,e,n){t.exports=n("c7b2")},"002b":function(t,e,n){"use strict";var r,i,o,a=n("f869"),s=n("6446"),u=n("ca14"),c=n("081e"),l=n("9a02"),h=n("c7e7"),f=n("1262"),d=n("82b8"),p=n("d3a9"),m=n("7219"),g=n("6c01").f,v=n("afdf"),y=n("f97a"),_=n("7464"),x=n("519f"),b=n("0b61"),w=u.Int8Array,M=w&&w.prototype,S=u.Uint8ClampedArray,T=S&&S.prototype,E=w&&y(w),A=M&&y(M),C=Object.prototype,P=u.TypeError,L=x("toStringTag"),O=b("TYPED_ARRAY_TAG"),R=b("TYPED_ARRAY_CONSTRUCTOR"),k=a&&!!_&&"Opera"!==f(u.opera),I=!1,D={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},j={BigInt64Array:8,BigUint64Array:8},z=function(t){if(!l(t))return!1;var e=f(t);return h(D,e)||h(j,e)};for(r in D)(o=(i=u[r])&&i.prototype)?p(o,R,i):k=!1;for(r in j)(o=(i=u[r])&&i.prototype)&&p(o,R,i);if((!k||!c(E)||E===Function.prototype)&&(E=function(){throw P("Incorrect invocation")},k))for(r in D)u[r]&&_(u[r],E);if((!k||!A||A===C)&&(A=E.prototype,k))for(r in D)u[r]&&_(u[r].prototype,A);if(k&&y(T)!==A&&_(T,A),s&&!h(A,L))for(r in I=!0,g(A,L,{get:function(){return l(this)?this[O]:void 0}}),D)u[r]&&p(u[r],O,r);t.exports={NATIVE_ARRAY_BUFFER_VIEWS:k,TYPED_ARRAY_CONSTRUCTOR:R,TYPED_ARRAY_TAG:I&&O,aTypedArray:function(t){if(z(t))return t;throw P("Target is not a typed array")},aTypedArrayConstructor:function(t){if(c(t)&&(!_||v(E,t)))return t;throw P(d(t)+" is not a typed array constructor")},exportTypedArrayMethod:function(t,e,n){if(s){if(n)for(var r in D){var i=u[r];if(i&&h(i.prototype,t))try{delete i.prototype[t]}catch(t){}}A[t]&&!n||m(A,t,n?e:k&&M[t]||e)}},exportTypedArrayStaticMethod:function(t,e,n){var r,i;if(s){if(_){if(n)for(r in D)if((i=u[r])&&h(i,t))try{delete i[t]}catch(t){}if(E[t]&&!n)return;try{return m(E,t,n?e:k&&E[t]||e)}catch(t){}}for(r in D)!(i=u[r])||i[t]&&!n||m(i,t,e)}},isView:function(t){if(!l(t))return!1;var e=f(t);return"DataView"===e||h(D,e)||h(j,e)},isTypedArray:z,TypedArray:E,TypedArrayPrototype:A}},"0074":function(t,e,n){"use strict";var r=n("3e94"),i=n("6c01"),o=n("7e3c");t.exports=function(t,e,n){var a=r(e);a in t?i.f(t,a,o(0,n)):t[a]=n}},"03c2":function(t,e,n){var r=n("d45e");t.exports=r("document","documentElement")},"064b":function(t,e,n){var r=n("6446"),i=n("cbac"),o=n("c829"),a=n("7e3c"),s=n("097d"),u=n("3e94"),c=n("c7e7"),l=n("62ea"),h=Object.getOwnPropertyDescriptor;e.f=r?h:function(t,e){if(t=s(t),e=u(e),l)try{return h(t,e)}catch(t){}if(c(t,e))return a(!i(o.f,t,e),t[e])}},"071d":function(t,e,n){"use strict";var r=n("002b"),i=n("d796").some,o=r.aTypedArray;(0,r.exportTypedArrayMethod)("some",(function(t){return i(o(this),t,arguments.length>1?arguments[1]:void 0)}))},"081e":function(t,e){t.exports=function(t){return"function"==typeof t}},"097a":function(t,e,n){"use strict";var r=n("41a4"),i=n("a10c"),o=n("28dc");t.exports=function(t){for(var e=r(this),n=o(e),a=arguments.length,s=i(a>1?arguments[1]:void 0,n),u=a>2?arguments[2]:void 0,c=void 0===u?n:i(u,n);c>s;)e[s++]=t;return e}},"097d":function(t,e,n){var r=n("96a5"),i=n("c39c");t.exports=function(t){return r(i(t))}},"0a7d":function(t,e,n){(e=n("a1a8")(!1)).push([t.i,'.sk-chase-box[data-v-c8c2036e]{width:100%;height:100%;position:relative}.sk-chase-core[data-v-c8c2036e]{position:absolute;left:0;top:0;right:0;bottom:0;z-index:1;display:flex;justify-content:center;align-items:center}.sk-chase[data-v-c8c2036e]{width:40px;height:40px;position:relative;-webkit-animation:sk-chase-data-v-c8c2036e 2.5s linear infinite both;animation:sk-chase-data-v-c8c2036e 2.5s linear infinite both}.sk-chase-dot[data-v-c8c2036e]{width:100%;height:100%;position:absolute;left:0;top:0;-webkit-animation:sk-chase-dot-data-v-c8c2036e 2s ease-in-out infinite both;animation:sk-chase-dot-data-v-c8c2036e 2s ease-in-out infinite both}.sk-chase-dot[data-v-c8c2036e]:before{content:"";display:block;width:25%;height:25%;background-color:#0f82ff;border-radius:100%;-webkit-animation:sk-chase-dot-before-data-v-c8c2036e 2s ease-in-out infinite both;animation:sk-chase-dot-before-data-v-c8c2036e 2s ease-in-out infinite both}.sk-chase-dot[data-v-c8c2036e]:first-child{-webkit-animation-delay:-1.1s;animation-delay:-1.1s}.sk-chase-dot[data-v-c8c2036e]:nth-child(2){-webkit-animation-delay:-1s;animation-delay:-1s}.sk-chase-dot[data-v-c8c2036e]:nth-child(3){-webkit-animation-delay:-.9s;animation-delay:-.9s}.sk-chase-dot[data-v-c8c2036e]:nth-child(4){-webkit-animation-delay:-.8s;animation-delay:-.8s}.sk-chase-dot[data-v-c8c2036e]:nth-child(5){-webkit-animation-delay:-.7s;animation-delay:-.7s}.sk-chase-dot[data-v-c8c2036e]:nth-child(6){-webkit-animation-delay:-.6s;animation-delay:-.6s}.sk-chase-dot[data-v-c8c2036e]:first-child:before{-webkit-animation-delay:-1.1s;animation-delay:-1.1s}.sk-chase-dot[data-v-c8c2036e]:nth-child(2):before{-webkit-animation-delay:-1s;animation-delay:-1s}.sk-chase-dot[data-v-c8c2036e]:nth-child(3):before{-webkit-animation-delay:-.9s;animation-delay:-.9s}.sk-chase-dot[data-v-c8c2036e]:nth-child(4):before{-webkit-animation-delay:-.8s;animation-delay:-.8s}.sk-chase-dot[data-v-c8c2036e]:nth-child(5):before{-webkit-animation-delay:-.7s;animation-delay:-.7s}.sk-chase-dot[data-v-c8c2036e]:nth-child(6):before{-webkit-animation-delay:-.6s;animation-delay:-.6s}@-webkit-keyframes sk-chase-data-v-c8c2036e{to{transform:rotate(340deg)}}@keyframes sk-chase-data-v-c8c2036e{to{transform:rotate(340deg)}}@-webkit-keyframes sk-chase-dot-data-v-c8c2036e{80%,to{transform:rotate(340deg)}}@keyframes sk-chase-dot-data-v-c8c2036e{80%,to{transform:rotate(340deg)}}@-webkit-keyframes sk-chase-dot-before-data-v-c8c2036e{50%{transform:scale(.4)}0%,to{transform:scale(1)}}@keyframes sk-chase-dot-before-data-v-c8c2036e{50%{transform:scale(.4)}0%,to{transform:scale(1)}}',""]),t.exports=e},"0b57":function(t,e){t.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},"0b61":function(t,e,n){var r=n("c252"),i=0,o=Math.random(),a=r(1..toString);t.exports=function(t){return"Symbol("+(void 0===t?"":t)+")_"+a(++i+o,36)}},"0d84":function(t,e,n){n("50cc")("Float32",(function(t){return function(e,n,r){return t(this,e,n,r)}}))},"0ec0":function(t,e,n){"use strict";var r=n("ca14"),i=n("c252"),o=n("6446"),a=n("f869"),s=n("265d"),u=n("d3a9"),c=n("f0f8"),l=n("c814"),h=n("c3f4"),f=n("4799"),d=n("f4b1"),p=n("532a"),m=n("b6b1"),g=n("f97a"),v=n("7464"),y=n("9cd9").f,_=n("6c01").f,x=n("097a"),b=n("9a1e"),w=n("9207"),M=n("e13b"),S=s.PROPER,T=s.CONFIGURABLE,E=M.get,A=M.set,C="ArrayBuffer",P="DataView",L="prototype",O="Wrong index",R=r[C],k=R,I=k&&k[L],D=r[P],j=D&&D[L],z=Object.prototype,N=r.Array,F=r.RangeError,B=i(x),H=i([].reverse),G=m.pack,U=m.unpack,W=function(t){return[255&t]},V=function(t){return[255&t,t>>8&255]},Z=function(t){return[255&t,t>>8&255,t>>16&255,t>>24&255]},q=function(t){return t[3]<<24|t[2]<<16|t[1]<<8|t[0]},Y=function(t){return G(t,23,4)},J=function(t){return G(t,52,8)},X=function(t,e){_(t[L],e,{get:function(){return E(this)[e]}})},$=function(t,e,n,r){var i=p(n),o=E(t);if(i+e>o.byteLength)throw F(O);var a=E(o.buffer).bytes,s=i+o.byteOffset,u=b(a,s,s+e);return r?u:H(u)},Q=function(t,e,n,r,i,o){var a=p(n),s=E(t);if(a+e>s.byteLength)throw F(O);for(var u=E(s.buffer).bytes,c=a+s.byteOffset,l=r(+i),h=0;h<e;h++)u[c+h]=l[o?h:e-h-1]};if(a){var K=S&&R.name!==C;if(l((function(){R(1)}))&&l((function(){new R(-1)}))&&!l((function(){return new R,new R(1.5),new R(NaN),K&&!T})))K&&T&&u(R,"name",C);else{(k=function(t){return h(this,I),new R(p(t))})[L]=I;for(var tt,et=y(R),nt=0;et.length>nt;)(tt=et[nt++])in k||u(k,tt,R[tt]);I.constructor=k}v&&g(j)!==z&&v(j,z);var rt=new D(new k(2)),it=i(j.setInt8);rt.setInt8(0,2147483648),rt.setInt8(1,2147483649),!rt.getInt8(0)&&rt.getInt8(1)||c(j,{setInt8:function(t,e){it(this,t,e<<24>>24)},setUint8:function(t,e){it(this,t,e<<24>>24)}},{unsafe:!0})}else I=(k=function(t){h(this,I);var e=p(t);A(this,{bytes:B(N(e),0),byteLength:e}),o||(this.byteLength=e)})[L],j=(D=function(t,e,n){h(this,j),h(t,I);var r=E(t).byteLength,i=f(e);if(i<0||i>r)throw F("Wrong offset");if(i+(n=void 0===n?r-i:d(n))>r)throw F("Wrong length");A(this,{buffer:t,byteLength:n,byteOffset:i}),o||(this.buffer=t,this.byteLength=n,this.byteOffset=i)})[L],o&&(X(k,"byteLength"),X(D,"buffer"),X(D,"byteLength"),X(D,"byteOffset")),c(j,{getInt8:function(t){return $(this,1,t)[0]<<24>>24},getUint8:function(t){return $(this,1,t)[0]},getInt16:function(t){var e=$(this,2,t,arguments.length>1?arguments[1]:void 0);return(e[1]<<8|e[0])<<16>>16},getUint16:function(t){var e=$(this,2,t,arguments.length>1?arguments[1]:void 0);return e[1]<<8|e[0]},getInt32:function(t){return q($(this,4,t,arguments.length>1?arguments[1]:void 0))},getUint32:function(t){return q($(this,4,t,arguments.length>1?arguments[1]:void 0))>>>0},getFloat32:function(t){return U($(this,4,t,arguments.length>1?arguments[1]:void 0),23)},getFloat64:function(t){return U($(this,8,t,arguments.length>1?arguments[1]:void 0),52)},setInt8:function(t,e){Q(this,1,t,W,e)},setUint8:function(t,e){Q(this,1,t,W,e)},setInt16:function(t,e){Q(this,2,t,V,e,arguments.length>2?arguments[2]:void 0)},setUint16:function(t,e){Q(this,2,t,V,e,arguments.length>2?arguments[2]:void 0)},setInt32:function(t,e){Q(this,4,t,Z,e,arguments.length>2?arguments[2]:void 0)},setUint32:function(t,e){Q(this,4,t,Z,e,arguments.length>2?arguments[2]:void 0)},setFloat32:function(t,e){Q(this,4,t,Y,e,arguments.length>2?arguments[2]:void 0)},setFloat64:function(t,e){Q(this,8,t,J,e,arguments.length>2?arguments[2]:void 0)}});w(k,C),w(D,P),t.exports={ArrayBuffer:k,DataView:D}},"0ffc":function(t,e,n){var r=n("081e"),i=n("9a02"),o=n("7464");t.exports=function(t,e,n){var a,s;return o&&r(a=e.constructor)&&a!==n&&i(s=a.prototype)&&s!==n.prototype&&o(t,s),t}},"119b":function(t,e,n){var r=n("4748").match(/AppleWebKit\/(\d+)\./);t.exports=!!r&&+r[1]},1262:function(t,e,n){var r=n("ca14"),i=n("3fa4"),o=n("081e"),a=n("cc43"),s=n("519f")("toStringTag"),u=r.Object,c="Arguments"==a(function(){return arguments}());t.exports=i?a:function(t){var e,n,r;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=function(t,e){try{return t[e]}catch(t){}}(e=u(t),s))?n:c?a(e):"Object"==(r=a(e))&&o(e.callee)?"Arguments":r}},"13eb":function(t,e,n){var r=n("c252");t.exports=r([].slice)},1576:function(t,e,n){var r=n("3fa4"),i=n("7219"),o=n("cdf3");r||i(Object.prototype,"toString",o,{unsafe:!0})},1579:function(t,e,n){"use strict";var r=n("e1ca").forEach,i=n("1ccf"),o=n("4762"),a=n("8e6f"),s=n("4263"),u=n("b243"),c=n("de5a"),l=n("b0d6"),h=n("4bd3"),f=n("2986"),d=n("cae7");function p(t){return Array.isArray(t)||void 0!==t.length}function m(t){if(Array.isArray(t))return t;var e=[];return r(t,(function(t){e.push(t)})),e}function g(t){return t&&1===t.nodeType}function v(t,e,n){var r=t[e];return null!=r||void 0===n?r:n}t.exports=function(t){var e;if((t=t||{}).idHandler)e={get:function(e){return t.idHandler.get(e,!0)},set:t.idHandler.set};else{var n=a(),y=s({idGenerator:n,stateHandler:h});e=y}var _=t.reporter;_||(_=u(!1===_));var x=v(t,"batchProcessor",l({reporter:_})),b={};b.callOnAdd=!!v(t,"callOnAdd",!0),b.debug=!!v(t,"debug",!1);var w,M=o(e),S=i({stateHandler:h}),T=v(t,"strategy","object"),E=v(t,"important",!1),A={reporter:_,batchProcessor:x,stateHandler:h,idHandler:e,important:E};if("scroll"===T&&(c.isLegacyOpera()?(_.warn("Scroll strategy is not supported on legacy Opera. Changing to object strategy."),T="object"):c.isIE(9)&&(_.warn("Scroll strategy is not supported on IE9. Changing to object strategy."),T="object")),"scroll"===T)w=d(A);else{if("object"!==T)throw new Error("Invalid strategy name: "+T);w=f(A)}var C={};return{listenTo:function(t,n,i){function o(t){var e=M.get(t);r(e,(function(e){e(t)}))}function a(t,e,n){M.add(e,n),t&&n(e)}if(i||(i=n,n=t,t={}),!n)throw new Error("At least one element required.");if(!i)throw new Error("Listener required.");if(g(n))n=[n];else{if(!p(n))return _.error("Invalid arguments. Must be a DOM element or a collection of DOM elements.");n=m(n)}var s=0,u=v(t,"callOnAdd",b.callOnAdd),c=v(t,"onReady",(function(){})),l=v(t,"debug",b.debug);r(n,(function(t){h.getState(t)||(h.initState(t),e.set(t));var f=e.get(t);if(l&&_.log("Attaching listener to element",f,t),!S.isDetectable(t))return l&&_.log(f,"Not detectable."),S.isBusy(t)?(l&&_.log(f,"System busy making it detectable"),a(u,t,i),C[f]=C[f]||[],void C[f].push((function(){++s===n.length&&c()}))):(l&&_.log(f,"Making detectable..."),S.markBusy(t,!0),w.makeDetectable({debug:l,important:E},t,(function(t){if(l&&_.log(f,"onElementDetectable"),h.getState(t)){S.markAsDetectable(t),S.markBusy(t,!1),w.addListener(t,o),a(u,t,i);var e=h.getState(t);if(e&&e.startSize){var d=t.offsetWidth,p=t.offsetHeight;e.startSize.width===d&&e.startSize.height===p||o(t)}C[f]&&r(C[f],(function(t){t()}))}else l&&_.log(f,"Element uninstalled before being detectable.");delete C[f],++s===n.length&&c()})));l&&_.log(f,"Already detecable, adding listener."),a(u,t,i),s++})),s===n.length&&c()},removeListener:M.removeListener,removeAllListeners:M.removeAllListeners,uninstall:function(t){if(!t)return _.error("At least one element is required.");if(g(t))t=[t];else{if(!p(t))return _.error("Invalid arguments. Must be a DOM element or a collection of DOM elements.");t=m(t)}r(t,(function(t){M.removeAllListeners(t),w.uninstall(t),h.cleanState(t)}))},initDocument:function(t){w.initDocument&&w.initDocument(t)}}}},"15fd":function(t,e,n){"use strict";var r=n("41a4"),i=n("a10c"),o=n("28dc"),a=Math.min;t.exports=[].copyWithin||function(t,e){var n=r(this),s=o(n),u=i(t,s),c=i(e,s),l=arguments.length>2?arguments[2]:void 0,h=a((void 0===l?s:i(l,s))-c,s-u),f=1;for(c<u&&u<c+h&&(f=-1,c+=h-1,u+=h-1);h-- >0;)c in n?n[u]=n[c]:delete n[u],u+=f,c+=f;return n}},1671:function(t,e,n){var r=n("93b0");r.__esModule&&(r=r.default),"string"==typeof r&&(r=[[t.i,r,""]]),r.locals&&(t.exports=r.locals),(0,n("5925").default)("dcc90e9e",r,!0,{sourceMap:!1,shadowMode:!1})},1772:function(t,e,n){var r=n("ca14"),i=n("b0c4"),o=n("41a4"),a=n("96a5"),s=n("28dc"),u=r.TypeError,c=function(t){return function(e,n,r,c){i(n);var l=o(e),h=a(l),f=s(l),d=t?f-1:0,p=t?-1:1;if(r<2)for(;;){if(d in h){c=h[d],d+=p;break}if(d+=p,t?d<0:f<=d)throw u("Reduce of empty array with no initial value")}for(;t?d>=0:f>d;d+=p)d in h&&(c=n(c,h[d],d,l));return c}};t.exports={left:c(!1),right:c(!0)}},"18aa":function(t,e,n){var r=n("ca14"),i=n("cbac"),o=n("081e"),a=n("9a02"),s=r.TypeError;t.exports=function(t,e){var n,r;if("string"===e&&o(n=t.toString)&&!a(r=i(n,t)))return r;if(o(n=t.valueOf)&&!a(r=i(n,t)))return r;if("string"!==e&&o(n=t.toString)&&!a(r=i(n,t)))return r;throw s("Can't convert object to primitive value")}},"18fd":function(t,e,n){var r=n("445a"),i=n("c7e7"),o=n("d42b"),a=n("6c01").f;t.exports=function(t){var e=r.Symbol||(r.Symbol={});i(e,t)||a(e,t,{value:o.f(t)})}},"190b":function(t,e,n){var r=n("1262"),i=n("1ffe"),o=n("db7f"),a=n("519f")("iterator");t.exports=function(t){if(null!=t)return i(t,a)||i(t,"@@iterator")||o[r(t)]}},"1a1d":function(t,e,n){"use strict";var r=n("961e"),i=n("ca14"),o=n("8e04"),a=n("6d9b"),s=n("9a02"),u=n("a10c"),c=n("28dc"),l=n("097d"),h=n("0074"),f=n("519f"),d=n("7ba8"),p=n("13eb"),m=d("slice"),g=f("species"),v=i.Array,y=Math.max;r({target:"Array",proto:!0,forced:!m},{slice:function(t,e){var n,r,i,f=l(this),d=c(f),m=u(t,d),_=u(void 0===e?d:e,d);if(o(f)&&(n=f.constructor,(a(n)&&(n===v||o(n.prototype))||s(n)&&null===(n=n[g]))&&(n=void 0),n===v||void 0===n))return p(f,m,_);for(r=new(void 0===n?v:n)(y(_-m,0)),i=0;m<_;m++,i++)m in f&&h(r,i,f[m]);return r.length=i,r}})},"1b49":function(t,e,n){var r=n("961e"),i=n("c814"),o=n("41a4"),a=n("f97a"),s=n("c813");r({target:"Object",stat:!0,forced:i((function(){a(1)})),sham:!s},{getPrototypeOf:function(t){return a(o(t))}})},"1cba":function(t,e,n){(function(e){var n="object"==typeof e&&e&&e.Object===Object&&e;t.exports=n}).call(this,n("2409"))},"1ccf":function(t,e,n){"use strict";t.exports=function(t){var e=t.stateHandler.getState;return{isDetectable:function(t){var n=e(t);return n&&!!n.isDetectable},markAsDetectable:function(t){e(t).isDetectable=!0},isBusy:function(t){return!!e(t).busy},markBusy:function(t,n){e(t).busy=!!n}}}},"1e0a":function(t,e,n){"use strict";(t.exports={}).getOption=function(t,e,n){var r=t[e];return null!=r||void 0===n?r:n}},"1ffe":function(t,e,n){var r=n("b0c4");t.exports=function(t,e){var n=t[e];return null==n?void 0:r(n)}},"204a":function(t,e,n){var r=n("961e"),i=n("41a4"),o=n("5c75");r({target:"Object",stat:!0,forced:n("c814")((function(){o(1)}))},{keys:function(t){return o(i(t))}})},"21c5":function(t,e,n){"use strict";var r=n("cbac"),i=n("3b2d"),o=n("97d8"),a=n("f4b1"),s=n("54ab"),u=n("c39c"),c=n("1ffe"),l=n("bc8b"),h=n("a7fb");i("match",(function(t,e,n){return[function(e){var n=u(this),i=null==e?void 0:c(e,t);return i?r(i,e,n):new RegExp(e)[t](s(n))},function(t){var r=o(this),i=s(t),u=n(e,r,i);if(u.done)return u.value;if(!r.global)return h(r,i);var c=r.unicode;r.lastIndex=0;for(var f,d=[],p=0;null!==(f=h(r,i));){var m=s(f[0]);d[p]=m,""===m&&(r.lastIndex=l(i,a(r.lastIndex),c)),p++}return 0===p?null:d}]}))},"22a3":function(t,e,n){"use strict";var r=n("c252"),i=n("002b"),o=r(n("15fd")),a=i.aTypedArray;(0,i.exportTypedArrayMethod)("copyWithin",(function(t,e){return o(a(this),t,e,arguments.length>2?arguments[2]:void 0)}))},"23a5":function(t,e,n){var r=n("ca14"),i=n("4799"),o=r.RangeError;t.exports=function(t){var e=i(t);if(e<0)throw o("The argument can't be less than 0");return e}},2409:function(t,e){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(t){"object"==typeof window&&(n=window)}t.exports=n},"253d":function(t,e,n){"use strict";var r=n("002b"),i=n("d796").forEach,o=r.aTypedArray;(0,r.exportTypedArrayMethod)("forEach",(function(t){i(o(this),t,arguments.length>1?arguments[1]:void 0)}))},"265d":function(t,e,n){var r=n("6446"),i=n("c7e7"),o=Function.prototype,a=r&&Object.getOwnPropertyDescriptor,s=i(o,"name"),u=s&&"something"===function(){}.name,c=s&&(!r||r&&a(o,"name").configurable);t.exports={EXISTS:s,PROPER:u,CONFIGURABLE:c}},2721:function(t,e){t.exports=function(t,e){return function(n){return t(e(n))}}},"27d1":function(t,e,n){"use strict";function r(t,e,n){n=n||2;var r,o,s,u,c,l,f,d=e&&e.length,p=d?e[0]*n:t.length,m=i(t,0,p,n,!0),g=[];if(!m||m.next===m.prev)return g;if(d&&(m=h(t,e,m,n)),t.length>80*n){r=s=t[0],o=u=t[1];for(var v=n;v<p;v+=n)(c=t[v])<r&&(r=c),(l=t[v+1])<o&&(o=l),c>s&&(s=c),l>u&&(u=l);f=0!==(f=Math.max(s-r,u-o))?1/f:0}return a(m,g,n,r,o,f),g}function i(t,e,n,r,i){var o,a;if(i===P(t,e,n,r)>0)for(o=e;o<n;o+=r)a=E(o,t[o],t[o+1],a);else for(o=n-r;o>=e;o-=r)a=E(o,t[o],t[o+1],a);return a&&x(a,a.next)&&(A(a),a=a.next),a}function o(t,e){if(!t)return t;e||(e=t);var n,r=t;do{if(n=!1,r.steiner||!x(r,r.next)&&0!==_(r.prev,r,r.next))r=r.next;else{if(A(r),(r=e=r.prev)===r.next)break;n=!0}}while(n||r!==e);return e}function a(t,e,n,r,i,h,f){if(t){!f&&h&&function(t,e,n,r){var i=t;do{null===i.z&&(i.z=m(i.x,i.y,e,n,r)),i.prevZ=i.prev,i.nextZ=i.next,i=i.next}while(i!==t);i.prevZ.nextZ=null,i.prevZ=null,function(t){var e,n,r,i,o,a,s,u,c=1;do{for(n=t,t=null,o=null,a=0;n;){for(a++,r=n,s=0,e=0;e<c&&(s++,r=r.nextZ);e++);for(u=c;s>0||u>0&&r;)0!==s&&(0===u||!r||n.z<=r.z)?(i=n,n=n.nextZ,s--):(i=r,r=r.nextZ,u--),o?o.nextZ=i:t=i,i.prevZ=o,o=i;n=r}o.nextZ=null,c*=2}while(a>1)}(i)}(t,r,i,h);for(var d,p,g=t;t.prev!==t.next;)if(d=t.prev,p=t.next,h?u(t,r,i,h):s(t))e.push(d.i/n),e.push(t.i/n),e.push(p.i/n),A(t),t=p.next,g=p.next;else if((t=p)===g){f?1===f?a(t=c(o(t),e,n),e,n,r,i,h,2):2===f&&l(t,e,n,r,i,h):a(o(t),e,n,r,i,h,1);break}}}function s(t){var e=t.prev,n=t,r=t.next;if(_(e,n,r)>=0)return!1;for(var i=t.next.next;i!==t.prev;){if(v(e.x,e.y,n.x,n.y,r.x,r.y,i.x,i.y)&&_(i.prev,i,i.next)>=0)return!1;i=i.next}return!0}function u(t,e,n,r){var i=t.prev,o=t,a=t.next;if(_(i,o,a)>=0)return!1;for(var s=i.x<o.x?i.x<a.x?i.x:a.x:o.x<a.x?o.x:a.x,u=i.y<o.y?i.y<a.y?i.y:a.y:o.y<a.y?o.y:a.y,c=i.x>o.x?i.x>a.x?i.x:a.x:o.x>a.x?o.x:a.x,l=i.y>o.y?i.y>a.y?i.y:a.y:o.y>a.y?o.y:a.y,h=m(s,u,e,n,r),f=m(c,l,e,n,r),d=t.prevZ,p=t.nextZ;d&&d.z>=h&&p&&p.z<=f;){if(d!==t.prev&&d!==t.next&&v(i.x,i.y,o.x,o.y,a.x,a.y,d.x,d.y)&&_(d.prev,d,d.next)>=0)return!1;if(d=d.prevZ,p!==t.prev&&p!==t.next&&v(i.x,i.y,o.x,o.y,a.x,a.y,p.x,p.y)&&_(p.prev,p,p.next)>=0)return!1;p=p.nextZ}for(;d&&d.z>=h;){if(d!==t.prev&&d!==t.next&&v(i.x,i.y,o.x,o.y,a.x,a.y,d.x,d.y)&&_(d.prev,d,d.next)>=0)return!1;d=d.prevZ}for(;p&&p.z<=f;){if(p!==t.prev&&p!==t.next&&v(i.x,i.y,o.x,o.y,a.x,a.y,p.x,p.y)&&_(p.prev,p,p.next)>=0)return!1;p=p.nextZ}return!0}function c(t,e,n){var r=t;do{var i=r.prev,a=r.next.next;!x(i,a)&&b(i,r,r.next,a)&&S(i,a)&&S(a,i)&&(e.push(i.i/n),e.push(r.i/n),e.push(a.i/n),A(r),A(r.next),r=t=a),r=r.next}while(r!==t);return o(r)}function l(t,e,n,r,i,s){var u=t;do{for(var c=u.next.next;c!==u.prev;){if(u.i!==c.i&&y(u,c)){var l=T(u,c);return u=o(u,u.next),l=o(l,l.next),a(u,e,n,r,i,s),void a(l,e,n,r,i,s)}c=c.next}u=u.next}while(u!==t)}function h(t,e,n,r){var a,s,u,c=[];for(a=0,s=e.length;a<s;a++)(u=i(t,e[a]*r,a<s-1?e[a+1]*r:t.length,r,!1))===u.next&&(u.steiner=!0),c.push(g(u));for(c.sort(f),a=0;a<c.length;a++)n=o(n=d(c[a],n),n.next);return n}function f(t,e){return t.x-e.x}function d(t,e){var n=function(t,e){var n,r=e,i=t.x,o=t.y,a=-1/0;do{if(o<=r.y&&o>=r.next.y&&r.next.y!==r.y){var s=r.x+(o-r.y)*(r.next.x-r.x)/(r.next.y-r.y);if(s<=i&&s>a){if(a=s,s===i){if(o===r.y)return r;if(o===r.next.y)return r.next}n=r.x<r.next.x?r:r.next}}r=r.next}while(r!==e);if(!n)return null;if(i===a)return n;var u,c=n,l=n.x,h=n.y,f=1/0;r=n;do{i>=r.x&&r.x>=l&&i!==r.x&&v(o<h?i:a,o,l,h,o<h?a:i,o,r.x,r.y)&&(u=Math.abs(o-r.y)/(i-r.x),S(r,t)&&(u<f||u===f&&(r.x>n.x||r.x===n.x&&p(n,r)))&&(n=r,f=u)),r=r.next}while(r!==c);return n}(t,e);if(!n)return e;var r=T(n,t),i=o(n,n.next);return o(r,r.next),e===n?i:e}function p(t,e){return _(t.prev,t,e.prev)<0&&_(e.next,t,t.next)<0}function m(t,e,n,r,i){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=32767*(t-n)*i)|t<<8))|t<<4))|t<<2))|t<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=32767*(e-r)*i)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function g(t){var e=t,n=t;do{(e.x<n.x||e.x===n.x&&e.y<n.y)&&(n=e),e=e.next}while(e!==t);return n}function v(t,e,n,r,i,o,a,s){return(i-a)*(e-s)-(t-a)*(o-s)>=0&&(t-a)*(r-s)-(n-a)*(e-s)>=0&&(n-a)*(o-s)-(i-a)*(r-s)>=0}function y(t,e){return t.next.i!==e.i&&t.prev.i!==e.i&&!function(t,e){var n=t;do{if(n.i!==t.i&&n.next.i!==t.i&&n.i!==e.i&&n.next.i!==e.i&&b(n,n.next,t,e))return!0;n=n.next}while(n!==t);return!1}(t,e)&&(S(t,e)&&S(e,t)&&function(t,e){var n=t,r=!1,i=(t.x+e.x)/2,o=(t.y+e.y)/2;do{n.y>o!=n.next.y>o&&n.next.y!==n.y&&i<(n.next.x-n.x)*(o-n.y)/(n.next.y-n.y)+n.x&&(r=!r),n=n.next}while(n!==t);return r}(t,e)&&(_(t.prev,t,e.prev)||_(t,e.prev,e))||x(t,e)&&_(t.prev,t,t.next)>0&&_(e.prev,e,e.next)>0)}function _(t,e,n){return(e.y-t.y)*(n.x-e.x)-(e.x-t.x)*(n.y-e.y)}function x(t,e){return t.x===e.x&&t.y===e.y}function b(t,e,n,r){var i=M(_(t,e,n)),o=M(_(t,e,r)),a=M(_(n,r,t)),s=M(_(n,r,e));return i!==o&&a!==s||!(0!==i||!w(t,n,e))||!(0!==o||!w(t,r,e))||!(0!==a||!w(n,t,r))||!(0!==s||!w(n,e,r))}function w(t,e,n){return e.x<=Math.max(t.x,n.x)&&e.x>=Math.min(t.x,n.x)&&e.y<=Math.max(t.y,n.y)&&e.y>=Math.min(t.y,n.y)}function M(t){return t>0?1:t<0?-1:0}function S(t,e){return _(t.prev,t,t.next)<0?_(t,e,t.next)>=0&&_(t,t.prev,e)>=0:_(t,e,t.prev)<0||_(t,t.next,e)<0}function T(t,e){var n=new C(t.i,t.x,t.y),r=new C(e.i,e.x,e.y),i=t.next,o=e.prev;return t.next=e,e.prev=t,n.next=i,i.prev=n,r.next=n,n.prev=r,o.next=r,r.prev=o,r}function E(t,e,n,r){var i=new C(t,e,n);return r?(i.next=r.next,i.prev=r,r.next.prev=i,r.next=i):(i.prev=i,i.next=i),i}function A(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function C(t,e,n){this.i=t,this.x=e,this.y=n,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function P(t,e,n,r){for(var i=0,o=e,a=n-r;o<n;o+=r)i+=(t[a]-t[o])*(t[o+1]+t[a+1]),a=o;return i}t.exports=r,t.exports.default=r,r.deviation=function(t,e,n,r){var i=e&&e.length,o=i?e[0]*n:t.length,a=Math.abs(P(t,0,o,n));if(i)for(var s=0,u=e.length;s<u;s++){var c=e[s]*n,l=s<u-1?e[s+1]*n:t.length;a-=Math.abs(P(t,c,l,n))}var h=0;for(s=0;s<r.length;s+=3){var f=r[s]*n,d=r[s+1]*n,p=r[s+2]*n;h+=Math.abs((t[f]-t[p])*(t[d+1]-t[f+1])-(t[f]-t[d])*(t[p+1]-t[f+1]))}return 0===a&&0===h?0:Math.abs((h-a)/a)},r.flatten=function(t){for(var e=t[0][0].length,n={vertices:[],holes:[],dimensions:e},r=0,i=0;i<t.length;i++){for(var o=0;o<t[i].length;o++)for(var a=0;a<e;a++)n.vertices.push(t[i][o][a]);i>0&&(r+=t[i-1].length,n.holes.push(r))}return n}},"28dc":function(t,e,n){var r=n("f4b1");t.exports=function(t){return r(t.length)}},2946:function(t,e,n){var r=n("ca14"),i=n("081e"),o=r.String,a=r.TypeError;t.exports=function(t){if("object"==typeof t||i(t))return t;throw a("Can't set "+o(t)+" as a prototype")}},2985:function(t,e,n){"use strict";var r=n("002b"),i=n("61a6"),o=n("f5d8"),a=r.aTypedArray;(0,r.exportTypedArrayMethod)("lastIndexOf",(function(t){var e=arguments.length;return i(o,a(this),e>1?[t,arguments[1]]:[t])}))},2986:function(t,e,n){"use strict";var r=n("de5a");t.exports=function(t){var e=(t=t||{}).reporter,n=t.batchProcessor,i=t.stateHandler.getState;if(!e)throw new Error("Missing required dependency: reporter.");function o(e){var n=t.important?" !important; ":"; ";return(e.join(n)+n).trim()}function a(t){return i(t).object}return{makeDetectable:function(t,a,s){s||(s=a,a=t,t=null),(t=t||{}).debug,r.isIE(8)?s(a):function(a,s){var u=o(["display: block","position: absolute","top: 0","left: 0","width: 100%","height: 100%","border: none","padding: 0","margin: 0","opacity: 0","z-index: -1000","pointer-events: none"]),c=!1,l=window.getComputedStyle(a),h=a.offsetWidth,f=a.offsetHeight;function d(){function n(){if("static"===l.position){a.style.setProperty("position","relative",t.important?"important":"");var n=function(e,n,r,i){var o=r[i];"auto"!==o&&"0"!==function(t){return t.replace(/[^-\d\.]/g,"")}(o)&&(e.warn("An element that is positioned static has style."+i+"="+o+" which is ignored due to the static positioning. The element will need to be positioned relative, so the style."+i+" will be set to 0. Element: ",n),n.style.setProperty(i,"0",t.important?"important":""))};n(e,a,l,"top"),n(e,a,l,"right"),n(e,a,l,"bottom"),n(e,a,l,"left")}}""!==l.position&&(n(),c=!0);var o=document.createElement("object");o.style.cssText=u,o.tabIndex=-1,o.type="text/html",o.setAttribute("aria-hidden","true"),o.onload=function(){c||n(),function t(e,n){if(!e.contentDocument){var r=i(e);return r.checkForObjectDocumentTimeoutId&&window.clearTimeout(r.checkForObjectDocumentTimeoutId),void(r.checkForObjectDocumentTimeoutId=setTimeout((function(){r.checkForObjectDocumentTimeoutId=0,t(e,n)}),100))}n(e.contentDocument)}(this,(function(t){s(a)}))},r.isIE()||(o.data="about:blank"),i(a)&&(a.appendChild(o),i(a).object=o,r.isIE()&&(o.data="about:blank"))}i(a).startSize={width:h,height:f},n?n.add(d):d()}(a,s)},addListener:function(t,e){function n(){e(t)}if(r.isIE(8))i(t).object={proxy:n},t.attachEvent("onresize",n);else{var o=a(t);if(!o)throw new Error("Element is not detectable by this strategy.");o.contentDocument.defaultView.addEventListener("resize",n)}},uninstall:function(t){if(i(t)){var e=a(t);e&&(r.isIE(8)?t.detachEvent("onresize",e.proxy):t.removeChild(e),i(t).checkForObjectDocumentTimeoutId&&window.clearTimeout(i(t).checkForObjectDocumentTimeoutId),delete i(t).object)}}}}},"29f7":function(t,e,n){var r=n("961e"),i=n("c814"),o=n("097d"),a=n("064b").f,s=n("6446"),u=i((function(){a(1)}));r({target:"Object",stat:!0,forced:!s||u,sham:!s},{getOwnPropertyDescriptor:function(t,e){return a(o(t),e)}})},"29fd":function(t,e,n){var r=n("961e"),i=n("d45e"),o=n("61a6"),a=n("bd0a"),s=n("d7ed"),u=n("97d8"),c=n("9a02"),l=n("a30f"),h=n("c814"),f=i("Reflect","construct"),d=Object.prototype,p=[].push,m=h((function(){function t(){}return!(f((function(){}),[],t)instanceof t)})),g=!h((function(){f((function(){}))})),v=m||g;r({target:"Reflect",stat:!0,forced:v,sham:v},{construct:function(t,e){s(t),u(e);var n=arguments.length<3?t:s(arguments[2]);if(g&&!m)return f(t,e,n);if(t==n){switch(e.length){case 0:return new t;case 1:return new t(e[0]);case 2:return new t(e[0],e[1]);case 3:return new t(e[0],e[1],e[2]);case 4:return new t(e[0],e[1],e[2],e[3])}var r=[null];return o(p,r,e),new(o(a,t,r))}var i=n.prototype,h=l(c(i)?i:d),v=o(t,h,e);return c(v)?v:h}})},"2a67":function(t,e,n){var r=n("4748");t.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(r)},"2a97":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAKCAYAAABSfLWiAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA3ZpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDE0IDc5LjE1MTQ4MSwgMjAxMy8wMy8xMy0xMjowOToxNSAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDoxY2VjNGU4ZS1iOGY2LTliNGQtOTI4Ny00NDllN2M2NDNlOTQiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6MkI4MDFBOTY3RTk2MTFFODhENTE4NERCOTYxNjg4MjUiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6MkI4MDFBOTU3RTk2MTFFODhENTE4NERCOTYxNjg4MjUiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTQgKFdpbmRvd3MpIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6MWNlYzRlOGUtYjhmNi05YjRkLTkyODctNDQ5ZTdjNjQzZTk0IiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOjFjZWM0ZThlLWI4ZjYtOWI0ZC05Mjg3LTQ0OWU3YzY0M2U5NCIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PmUmXhQAAADFSURBVHjaYshKSpK/fOnS1/9kgNOnTr1KT0+XZgCBmsrKsJcvX5JkwJUrV/7k5OTYMiCDCRMm9P/48YMoA27duvWvuLjYmwELYFy0aNERQgY8evTof111dSQDLhASEsK5a+fO57gMePHixf/6+voMBkIgLS1N7tKlSz/RDXj37t3/zvb2KgZiQWNjozvIVhj49OnT/97u7m4GUsH0qVPrvn///h+EJ0+YMJeBXLBkyZItM6dNW8tACbC3t2cBxRohdQABBgAt8yx0KlQQZgAAAABJRU5ErkJggg=="},"2aa5":function(t,e,n){var r=n("c252"),i=n("4799"),o=n("54ab"),a=n("c39c"),s=r("".charAt),u=r("".charCodeAt),c=r("".slice),l=function(t){return function(e,n){var r,l,h=o(a(e)),f=i(n),d=h.length;return f<0||f>=d?t?"":void 0:(r=u(h,f))<55296||r>56319||f+1===d||(l=u(h,f+1))<56320||l>57343?t?s(h,f):r:t?c(h,f,f+2):l-56320+(r-55296<<10)+65536}};t.exports={codeAt:l(!1),charAt:l(!0)}},"2b26":function(t,e,n){var r=n("519f")("match");t.exports=function(t){var e=/./;try{"/./"[t](e)}catch(n){try{return e[r]=!1,"/./"[t](e)}catch(t){}}return!1}},"2ccb":function(t,e,n){var r=n("c4ae")("span").classList,i=r&&r.constructor&&r.constructor.prototype;t.exports=i===Object.prototype?void 0:i},"2cdc":function(t,e,n){"use strict";var r=n("002b"),i=n("d796").find,o=r.aTypedArray;(0,r.exportTypedArrayMethod)("find",(function(t){return i(o(this),t,arguments.length>1?arguments[1]:void 0)}))},"2d18":function(t,e,n){var r=n("9a1e"),i=Math.floor,o=function(t,e){var n=t.length,u=i(n/2);return n<8?a(t,e):s(t,o(r(t,0,u),e),o(r(t,u),e),e)},a=function(t,e){for(var n,r,i=t.length,o=1;o<i;){for(r=o,n=t[o];r&&e(t[r-1],n)>0;)t[r]=t[--r];r!==o++&&(t[r]=n)}return t},s=function(t,e,n,r){for(var i=e.length,o=n.length,a=0,s=0;a<i||s<o;)t[a+s]=a<i&&s<o?r(e[a],n[s])<=0?e[a++]:n[s++]:a<i?e[a++]:n[s++];return t};t.exports=o},"2ed2":function(t,e,n){var r=n("dc9b"),i=n("f227"),o=n("d92c"),a=Function.prototype,s=Object.prototype,u=a.toString,c=s.hasOwnProperty,l=u.call(Object);t.exports=function(t){if(!o(t)||"[object Object]"!=r(t))return!1;var e=i(t);if(null===e)return!0;var n=c.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&u.call(n)==l}},"2f36":function(t,e,n){"use strict";var r=n("ca14"),i=n("002b"),o=n("28dc"),a=n("7958"),s=n("41a4"),u=n("c814"),c=r.RangeError,l=i.aTypedArray;(0,i.exportTypedArrayMethod)("set",(function(t){l(this);var e=a(arguments.length>1?arguments[1]:void 0,1),n=this.length,r=s(t),i=o(r),u=0;if(i+e>n)throw c("Wrong length");for(;u<i;)this[e+u]=r[u++]}),u((function(){new Int8Array(1).set({})})))},3223:function(t,e,n){var r=n("9a02"),i=Math.floor;t.exports=Number.isInteger||function(t){return!r(t)&&isFinite(t)&&i(t)===t}},3355:function(t,e,n){"use strict";var r=n("002b"),i=n("ee4f").indexOf,o=r.aTypedArray;(0,r.exportTypedArrayMethod)("indexOf",(function(t){return i(o(this),t,arguments.length>1?arguments[1]:void 0)}))},3471:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAKCAYAAABSfLWiAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA3ZpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDE0IDc5LjE1MTQ4MSwgMjAxMy8wMy8xMy0xMjowOToxNSAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDo0NTE4ZWRhOC03NjQ5LTNjNGUtYjYxZi0xNjVhZmQzNmJmMzciIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6MUJCN0UxQjY3RTk2MTFFOEFCNzVFRTYzMkFGMUE2MUIiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6MUJCN0UxQjU3RTk2MTFFOEFCNzVFRTYzMkFGMUE2MUIiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTQgKFdpbmRvd3MpIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6NDUxOGVkYTgtNzY0OS0zYzRlLWI2MWYtMTY1YWZkMzZiZjM3IiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOjQ1MThlZGE4LTc2NDktM2M0ZS1iNjFmLTE2NWFmZDM2YmYzNyIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/Pvm07Z8AAADSSURBVHjaYvj//z8DPswIBI6Ojiz41LAwEAAzpk1bw83Lyw5k+uBUhM+GyRMnzv3+/ft/EJ4+dWodLnU4Dejr6en+9OnTfxh48eLF/6amJneiDelsb6969+7df3Rw+fLln+np6XIEDWloaMgA2YoL7N6163lYWBgnTkPqa2oiHz169J8QWLx48RFQrGEYUlpa6n379u1//4kAP378+D9xwoR+FEPy8vJsr1y58uc/CeDly5f/66qrw8CGZGZmSp85ffrVfzLA5UuXvuakpMgDBBgAQbLv2dsvRWYAAAAASUVORK5CYII="},3477:function(t,e,n){"use strict";var r=n("002b"),i=n("d796").filter,o=n("e2c0"),a=r.aTypedArray;(0,r.exportTypedArrayMethod)("filter",(function(t){var e=i(a(this),t,arguments.length>1?arguments[1]:void 0);return o(this,e)}))},3492:function(t,e,n){var r=n("4748").match(/firefox\/(\d+)/i);t.exports=!!r&&+r[1]},"34bc":function(t,e,n){var r=n("9153"),i=n("efd9");(t.exports=function(t,e){return i[t]||(i[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.19.2",mode:r?"pure":"global",copyright:"© 2021 Denis Pushkarev (zloirock.ru)"})},"350f":function(t,e,n){var r=n("ca14");t.exports=function(t,e){var n=r.console;n&&n.error&&(1==arguments.length?n.error(t):n.error(t,e))}},3552:function(t,e){t.exports={name:"memoryStorage",read:function(t){return n[t]},write:function(t,e){n[t]=e},each:function(t){for(var e in n)n.hasOwnProperty(e)&&t(n[e],e)},remove:function(t){delete n[t]},clearAll:function(t){n={}}};var n={}},3708:function(t,e,n){var r=n("c814"),i=n("ca14").RegExp;t.exports=r((function(){var t=i(".","s");return!(t.dotAll&&t.exec("\n")&&"s"===t.flags)}))},"39ec":function(t,e,n){"use strict";var r=n("002b"),i=n("f4b1"),o=n("a10c"),a=n("d9c2"),s=r.aTypedArray;(0,r.exportTypedArrayMethod)("subarray",(function(t,e){var n=s(this),r=n.length,u=o(t,r);return new(a(n))(n.buffer,n.byteOffset+u*n.BYTES_PER_ELEMENT,i((void 0===e?r:o(e,r))-u))}))},"3a40":function(t,e,n){(function(e){var n=Object.assign?Object.assign:function(t,e,n,r){for(var i=1;i<arguments.length;i++)s(Object(arguments[i]),(function(e,n){t[n]=e}));return t},r=function(){if(Object.create)return function(t,e,r,i){var o=a(arguments,1);return n.apply(this,[Object.create(t)].concat(o))};{function t(){}return function(e,r,i,o){var s=a(arguments,1);return t.prototype=e,n.apply(this,[new t].concat(s))}}}(),i=String.prototype.trim?function(t){return String.prototype.trim.call(t)}:function(t){return t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")},o="undefined"!=typeof window?window:e;function a(t,e){return Array.prototype.slice.call(t,e||0)}function s(t,e){u(t,(function(t,n){return e(t,n),!1}))}function u(t,e){if(c(t)){for(var n=0;n<t.length;n++)if(e(t[n],n))return t[n]}else for(var r in t)if(t.hasOwnProperty(r)&&e(t[r],r))return t[r]}function c(t){return null!=t&&"function"!=typeof t&&"number"==typeof t.length}t.exports={assign:n,create:r,trim:i,bind:function(t,e){return function(){return e.apply(t,Array.prototype.slice.call(arguments,0))}},slice:a,each:s,map:function(t,e){var n=c(t)?[]:{};return u(t,(function(t,r){return n[r]=e(t,r),!1})),n},pluck:u,isList:c,isFunction:function(t){return t&&"[object Function]"==={}.toString.call(t)},isObject:function(t){return t&&"[object Object]"==={}.toString.call(t)},Global:o}}).call(this,n("2409"))},"3ac5":function(t,e,n){var r=n("3a40").Global;t.exports={name:"oldIE-userDataStorage",write:function(t,e){if(!s){var n=c(t);a((function(t){t.setAttribute(n,e),t.save(i)}))}},read:function(t){if(!s){var e=c(t),n=null;return a((function(t){n=t.getAttribute(e)})),n}},each:function(t){a((function(e){for(var n=e.XMLDocument.documentElement.attributes,r=n.length-1;r>=0;r--){var i=n[r];t(e.getAttribute(i.name),i.name)}}))},remove:function(t){var e=c(t);a((function(t){t.removeAttribute(e),t.save(i)}))},clearAll:function(){a((function(t){var e=t.XMLDocument.documentElement.attributes;t.load(i);for(var n=e.length-1;n>=0;n--)t.removeAttribute(e[n].name);t.save(i)}))}};var i="storejs",o=r.document,a=function(){if(!o||!o.documentElement||!o.documentElement.addBehavior)return null;var t,e,n;try{(e=new ActiveXObject("htmlfile")).open(),e.write('<script>document.w=window<\/script><iframe src="/favicon.ico"></iframe>'),e.close(),t=e.w.frames[0].document,n=t.createElement("div")}catch(e){n=o.createElement("div"),t=o.body}return function(e){var r=[].slice.call(arguments,0);r.unshift(n),t.appendChild(n),n.addBehavior("#default#userData"),n.load(i),e.apply(this,r),t.removeChild(n)}}(),s=(r.navigator?r.navigator.userAgent:"").match(/ (MSIE 8|MSIE 9|MSIE 10)\./),u=new RegExp("[!\"#$%&'()*+,/\\\\:;<=>?@[\\]^`{|}~]","g");function c(t){return t.replace(/^\d/,"___$&").replace(u,"___")}},"3b2d":function(t,e,n){"use strict";n("bb4d");var r=n("c252"),i=n("7219"),o=n("466a"),a=n("c814"),s=n("519f"),u=n("d3a9"),c=s("species"),l=RegExp.prototype;t.exports=function(t,e,n,h){var f=s(t),d=!a((function(){var e={};return e[f]=function(){return 7},7!=""[t](e)})),p=d&&!a((function(){var e=!1,n=/a/;return"split"===t&&((n={}).constructor={},n.constructor[c]=function(){return n},n.flags="",n[f]=/./[f]),n.exec=function(){return e=!0,null},n[f](""),!e}));if(!d||!p||n){var m=r(/./[f]),g=e(f,""[t],(function(t,e,n,i,a){var s=r(t),u=e.exec;return u===o||u===l.exec?d&&!a?{done:!0,value:m(e,n,i)}:{done:!0,value:s(n,e,i)}:{done:!1}}));i(String.prototype,t,g[0]),i(l,f,g[1])}h&&u(l[f],"sham",!0)}},"3e94":function(t,e,n){var r=n("a434"),i=n("62b4");t.exports=function(t){var e=r(t,"string");return i(e)?e:e+""}},"3fa4":function(t,e,n){var r={};r[n("519f")("toStringTag")]="z",t.exports="[object z]"===String(r)},"412f":function(t,e,n){"use strict";var r,i,o,a,s=n("961e"),u=n("9153"),c=n("ca14"),l=n("d45e"),h=n("cbac"),f=n("6326"),d=n("7219"),p=n("f0f8"),m=n("7464"),g=n("9207"),v=n("c60e"),y=n("b0c4"),_=n("081e"),x=n("9a02"),b=n("c3f4"),w=n("4f29"),M=n("44a8"),S=n("6566"),T=n("baf4"),E=n("675d").set,A=n("ebba"),C=n("5b0d"),P=n("350f"),L=n("8088"),O=n("f1d5"),R=n("e13b"),k=n("a3e2"),I=n("519f"),D=n("57c6"),j=n("801d"),z=n("a0a0"),N=I("species"),F="Promise",B=R.get,H=R.set,G=R.getterFor(F),U=f&&f.prototype,W=f,V=U,Z=c.TypeError,q=c.document,Y=c.process,J=L.f,X=J,$=!!(q&&q.createEvent&&c.dispatchEvent),Q=_(c.PromiseRejectionEvent),K="unhandledrejection",tt=!1,et=k(F,(function(){var t=w(W),e=t!==String(W);if(!e&&66===z)return!0;if(u&&!V.finally)return!0;if(z>=51&&/native code/.test(t))return!1;var n=new W((function(t){t(1)})),r=function(t){t((function(){}),(function(){}))};return(n.constructor={})[N]=r,!(tt=n.then((function(){}))instanceof r)||!e&&D&&!Q})),nt=et||!S((function(t){W.all(t).catch((function(){}))})),rt=function(t){var e;return!(!x(t)||!_(e=t.then))&&e},it=function(t,e){if(!t.notified){t.notified=!0;var n=t.reactions;A((function(){for(var r=t.value,i=1==t.state,o=0;n.length>o;){var a,s,u,c=n[o++],l=i?c.ok:c.fail,f=c.resolve,d=c.reject,p=c.domain;try{l?(i||(2===t.rejection&&ut(t),t.rejection=1),!0===l?a=r:(p&&p.enter(),a=l(r),p&&(p.exit(),u=!0)),a===c.promise?d(Z("Promise-chain cycle")):(s=rt(a))?h(s,a,f,d):f(a)):d(r)}catch(t){p&&!u&&p.exit(),d(t)}}t.reactions=[],t.notified=!1,e&&!t.rejection&&at(t)}))}},ot=function(t,e,n){var r,i;$?((r=q.createEvent("Event")).promise=e,r.reason=n,r.initEvent(t,!1,!0),c.dispatchEvent(r)):r={promise:e,reason:n},!Q&&(i=c["on"+t])?i(r):t===K&&P("Unhandled promise rejection",n)},at=function(t){h(E,c,(function(){var e,n=t.facade,r=t.value;if(st(t)&&(e=O((function(){j?Y.emit("unhandledRejection",r,n):ot(K,n,r)})),t.rejection=j||st(t)?2:1,e.error))throw e.value}))},st=function(t){return 1!==t.rejection&&!t.parent},ut=function(t){h(E,c,(function(){var e=t.facade;j?Y.emit("rejectionHandled",e):ot("rejectionhandled",e,t.value)}))},ct=function(t,e,n){return function(r){t(e,r,n)}},lt=function(t,e,n){t.done||(t.done=!0,n&&(t=n),t.value=e,t.state=2,it(t,!0))},ht=function(t,e,n){if(!t.done){t.done=!0,n&&(t=n);try{if(t.facade===e)throw Z("Promise can't be resolved itself");var r=rt(e);r?A((function(){var n={done:!1};try{h(r,e,ct(ht,n,t),ct(lt,n,t))}catch(e){lt(n,e,t)}})):(t.value=e,t.state=1,it(t,!1))}catch(e){lt({done:!1},e,t)}}};if(et&&(V=(W=function(t){b(this,V),y(t),h(r,this);var e=B(this);try{t(ct(ht,e),ct(lt,e))}catch(t){lt(e,t)}}).prototype,(r=function(t){H(this,{type:F,done:!1,notified:!1,parent:!1,reactions:[],rejection:!1,state:0,value:void 0})}).prototype=p(V,{then:function(t,e){var n=G(this),r=n.reactions,i=J(T(this,W));return i.ok=!_(t)||t,i.fail=_(e)&&e,i.domain=j?Y.domain:void 0,n.parent=!0,r[r.length]=i,0!=n.state&&it(n,!1),i.promise},catch:function(t){return this.then(void 0,t)}}),i=function(){var t=new r,e=B(t);this.promise=t,this.resolve=ct(ht,e),this.reject=ct(lt,e)},L.f=J=function(t){return t===W||t===o?new i(t):X(t)},!u&&_(f)&&U!==Object.prototype)){a=U.then,tt||(d(U,"then",(function(t,e){var n=this;return new W((function(t,e){h(a,n,t,e)})).then(t,e)}),{unsafe:!0}),d(U,"catch",V.catch,{unsafe:!0}));try{delete U.constructor}catch(t){}m&&m(U,V)}s({global:!0,wrap:!0,forced:et},{Promise:W}),g(W,F,!1,!0),v(F),o=l(F),s({target:F,stat:!0,forced:et},{reject:function(t){var e=J(this);return h(e.reject,void 0,t),e.promise}}),s({target:F,stat:!0,forced:u||et},{resolve:function(t){return C(u&&this===o?W:this,t)}}),s({target:F,stat:!0,forced:nt},{all:function(t){var e=this,n=J(e),r=n.resolve,i=n.reject,o=O((function(){var n=y(e.resolve),o=[],a=0,s=1;M(t,(function(t){var u=a++,c=!1;s++,h(n,e,t).then((function(t){c||(c=!0,o[u]=t,--s||r(o))}),i)})),--s||r(o)}));return o.error&&i(o.value),n.promise},race:function(t){var e=this,n=J(e),r=n.reject,i=O((function(){var i=y(e.resolve);M(t,(function(t){h(i,e,t).then(n.resolve,r)}))}));return i.error&&r(i.value),n.promise}})},"41a4":function(t,e,n){var r=n("ca14"),i=n("c39c"),o=r.Object;t.exports=function(t){return o(i(t))}},4263:function(t,e,n){"use strict";t.exports=function(t){var e=t.idGenerator,n=t.stateHandler.getState;return{get:function(t){var e=n(t);return e&&void 0!==e.id?e.id:null},set:function(t){var r=n(t);if(!r)throw new Error("setId required the element to have a resize detection state.");var i=e.generate();return r.id=i,i}}}},"433e":function(t,e,n){var r=n("dbce");t.exports=function(t,e){return new(r(t))(0===e?0:e)}},"445a":function(t,e,n){var r=n("ca14");t.exports=r},"44a8":function(t,e,n){var r=n("ca14"),i=n("ad0f"),o=n("cbac"),a=n("97d8"),s=n("82b8"),u=n("bfea"),c=n("28dc"),l=n("afdf"),h=n("a42a"),f=n("190b"),d=n("47fa"),p=r.TypeError,m=function(t,e){this.stopped=t,this.result=e},g=m.prototype;t.exports=function(t,e,n){var r,v,y,_,x,b,w,M=n&&n.that,S=!(!n||!n.AS_ENTRIES),T=!(!n||!n.IS_ITERATOR),E=!(!n||!n.INTERRUPTED),A=i(e,M),C=function(t){return r&&d(r,"normal",t),new m(!0,t)},P=function(t){return S?(a(t),E?A(t[0],t[1],C):A(t[0],t[1])):E?A(t,C):A(t)};if(T)r=t;else{if(!(v=f(t)))throw p(s(t)+" is not iterable");if(u(v)){for(y=0,_=c(t);_>y;y++)if((x=P(t[y]))&&l(g,x))return x;return new m(!1)}r=h(t,v)}for(b=r.next;!(w=o(b,r)).done;){try{x=P(w.value)}catch(t){d(r,"throw",t)}if("object"==typeof x&&x&&l(g,x))return x}return new m(!1)}},"466a":function(t,e,n){"use strict";var r=n("cbac"),i=n("c252"),o=n("54ab"),a=n("ab58"),s=n("54b9"),u=n("34bc"),c=n("a30f"),l=n("e13b").get,h=n("3708"),f=n("6346"),d=u("native-string-replace",String.prototype.replace),p=RegExp.prototype.exec,m=p,g=i("".charAt),v=i("".indexOf),y=i("".replace),_=i("".slice),x=function(){var t=/a/,e=/b*/g;return r(p,t,"a"),r(p,e,"a"),0!==t.lastIndex||0!==e.lastIndex}(),b=s.BROKEN_CARET,w=void 0!==/()??/.exec("")[1];(x||w||b||h||f)&&(m=function(t){var e,n,i,s,u,h,f,M=this,S=l(M),T=o(t),E=S.raw;if(E)return E.lastIndex=M.lastIndex,e=r(m,E,T),M.lastIndex=E.lastIndex,e;var A=S.groups,C=b&&M.sticky,P=r(a,M),L=M.source,O=0,R=T;if(C&&(P=y(P,"y",""),-1===v(P,"g")&&(P+="g"),R=_(T,M.lastIndex),M.lastIndex>0&&(!M.multiline||M.multiline&&"\n"!==g(T,M.lastIndex-1))&&(L="(?: "+L+")",R=" "+R,O++),n=new RegExp("^(?:"+L+")",P)),w&&(n=new RegExp("^"+L+"$(?!\\s)",P)),x&&(i=M.lastIndex),s=r(p,C?n:M,R),C?s?(s.input=_(s.input,O),s[0]=_(s[0],O),s.index=M.lastIndex,M.lastIndex+=s[0].length):M.lastIndex=0:x&&s&&(M.lastIndex=M.global?s.index+s[0].length:i),w&&s&&s.length>1&&r(d,s[0],n,(function(){for(u=1;u<arguments.length-2;u++)void 0===arguments[u]&&(s[u]=void 0)})),s&&A)for(s.groups=h=c(null),u=0;u<A.length;u++)h[(f=A[u])[0]]=s[f[1]];return s}),t.exports=m},4704:function(t,e,n){var r=n("c252"),i=n("c7e7"),o=n("097d"),a=n("ee4f").indexOf,s=n("f448"),u=r([].push);t.exports=function(t,e){var n,r=o(t),c=0,l=[];for(n in r)!i(s,n)&&i(r,n)&&u(l,n);for(;e.length>c;)i(r,n=e[c++])&&(~a(l,n)||u(l,n));return l}},4748:function(t,e,n){var r=n("d45e");t.exports=r("navigator","userAgent")||""},4762:function(t,e,n){"use strict";t.exports=function(t){var e={};function n(n){var r=t.get(n);return void 0===r?[]:e[r]||[]}return{get:n,add:function(n,r){var i=t.get(n);e[i]||(e[i]=[]),e[i].push(r)},removeListener:function(t,e){for(var r=n(t),i=0,o=r.length;i<o;++i)if(r[i]===e){r.splice(i,1);break}},removeAllListeners:function(t){var e=n(t);e&&(e.length=0)}}}},4799:function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){var e=+t;return e!=e||0===e?0:(e>0?r:n)(e)}},"47fa":function(t,e,n){var r=n("cbac"),i=n("97d8"),o=n("1ffe");t.exports=function(t,e,n){var a,s;i(t);try{if(!(a=o(t,"return"))){if("throw"===e)throw n;return n}a=r(a,t)}catch(t){s=!0,a=t}if("throw"===e)throw n;if(s)throw a;return i(a),n}},"4b1a":function(t,e,n){var r=n("d45e"),i=n("c252"),o=n("9cd9"),a=n("b2e9"),s=n("97d8"),u=i([].concat);t.exports=r("Reflect","ownKeys")||function(t){var e=o.f(s(t)),n=a.f;return n?u(e,n(t)):e}},"4bd3":function(t,e,n){"use strict";var r="_erd";function i(t){return t[r]}t.exports={initState:function(t){return t[r]={},i(t)},getState:i,cleanState:function(t){delete t[r]}}},"4ecc":function(t,e,n){"use strict";var r=n("961e"),i=n("d796").filter;r({target:"Array",proto:!0,forced:!n("7ba8")("filter")},{filter:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}})},"4f29":function(t,e,n){var r=n("c252"),i=n("081e"),o=n("efd9"),a=r(Function.toString);i(o.inspectSource)||(o.inspectSource=function(t){return a(t)}),t.exports=o.inspectSource},"4f80":function(t,e,n){"use strict";var r=n("002b"),i=r.aTypedArray,o=r.exportTypedArrayMethod,a=Math.floor;o("reverse",(function(){for(var t,e=this,n=i(e).length,r=a(n/2),o=0;o<r;)t=e[o],e[o++]=e[--n],e[n]=t;return e}))},"4fdb":function(t,e,n){var r=n("961e"),i=n("ca14"),o=n("9207");r({global:!0},{Reflect:{}}),o(i.Reflect,"Reflect",!0)},"50cc":function(t,e,n){"use strict";var r=n("961e"),i=n("ca14"),o=n("cbac"),a=n("6446"),s=n("c1b3"),u=n("002b"),c=n("0ec0"),l=n("c3f4"),h=n("7e3c"),f=n("d3a9"),d=n("3223"),p=n("f4b1"),m=n("532a"),g=n("7958"),v=n("3e94"),y=n("c7e7"),_=n("1262"),x=n("9a02"),b=n("62b4"),w=n("a30f"),M=n("afdf"),S=n("7464"),T=n("9cd9").f,E=n("d770"),A=n("d796").forEach,C=n("c60e"),P=n("6c01"),L=n("064b"),O=n("e13b"),R=n("0ffc"),k=O.get,I=O.set,D=P.f,j=L.f,z=Math.round,N=i.RangeError,F=c.ArrayBuffer,B=F.prototype,H=c.DataView,G=u.NATIVE_ARRAY_BUFFER_VIEWS,U=u.TYPED_ARRAY_CONSTRUCTOR,W=u.TYPED_ARRAY_TAG,V=u.TypedArray,Z=u.TypedArrayPrototype,q=u.aTypedArrayConstructor,Y=u.isTypedArray,J="BYTES_PER_ELEMENT",X="Wrong length",$=function(t,e){q(t);for(var n=0,r=e.length,i=new t(r);r>n;)i[n]=e[n++];return i},Q=function(t,e){D(t,e,{get:function(){return k(this)[e]}})},K=function(t){var e;return M(B,t)||"ArrayBuffer"==(e=_(t))||"SharedArrayBuffer"==e},tt=function(t,e){return Y(t)&&!b(e)&&e in t&&d(+e)&&e>=0},et=function(t,e){return e=v(e),tt(t,e)?h(2,t[e]):j(t,e)},nt=function(t,e,n){return e=v(e),!(tt(t,e)&&x(n)&&y(n,"value"))||y(n,"get")||y(n,"set")||n.configurable||y(n,"writable")&&!n.writable||y(n,"enumerable")&&!n.enumerable?D(t,e,n):(t[e]=n.value,t)};a?(G||(L.f=et,P.f=nt,Q(Z,"buffer"),Q(Z,"byteOffset"),Q(Z,"byteLength"),Q(Z,"length")),r({target:"Object",stat:!0,forced:!G},{getOwnPropertyDescriptor:et,defineProperty:nt}),t.exports=function(t,e,n){var a=t.match(/\d+$/)[0]/8,u=t+(n?"Clamped":"")+"Array",c="get"+t,h="set"+t,d=i[u],v=d,y=v&&v.prototype,_={},b=function(t,e){D(t,e,{get:function(){return function(t,e){var n=k(t);return n.view[c](e*a+n.byteOffset,!0)}(this,e)},set:function(t){return function(t,e,r){var i=k(t);n&&(r=(r=z(r))<0?0:r>255?255:255&r),i.view[h](e*a+i.byteOffset,r,!0)}(this,e,t)},enumerable:!0})};G?s&&(v=e((function(t,e,n,r){return l(t,y),R(x(e)?K(e)?void 0!==r?new d(e,g(n,a),r):void 0!==n?new d(e,g(n,a)):new d(e):Y(e)?$(v,e):o(E,v,e):new d(m(e)),t,v)})),S&&S(v,V),A(T(d),(function(t){t in v||f(v,t,d[t])})),v.prototype=y):(v=e((function(t,e,n,r){l(t,y);var i,s,u,c=0,h=0;if(x(e)){if(!K(e))return Y(e)?$(v,e):o(E,v,e);i=e,h=g(n,a);var f=e.byteLength;if(void 0===r){if(f%a)throw N(X);if((s=f-h)<0)throw N(X)}else if((s=p(r)*a)+h>f)throw N(X);u=s/a}else u=m(e),i=new F(s=u*a);for(I(t,{buffer:i,byteOffset:h,byteLength:s,length:u,view:new H(i)});c<u;)b(t,c++)})),S&&S(v,V),y=v.prototype=w(Z)),y.constructor!==v&&f(y,"constructor",v),f(y,U,v),W&&f(y,W,u),_[u]=v,r({global:!0,forced:v!=d,sham:!G},_),J in v||f(v,J,a),J in y||f(y,J,a),C(u)}):t.exports=function(){}},"519f":function(t,e,n){var r=n("ca14"),i=n("34bc"),o=n("c7e7"),a=n("0b61"),s=n("5ce1"),u=n("7b76"),c=i("wks"),l=r.Symbol,h=l&&l.for,f=u?l:l&&l.withoutSetter||a;t.exports=function(t){if(!o(c,t)||!s&&"string"!=typeof c[t]){var e="Symbol."+t;s&&o(l,t)?c[t]=l[t]:c[t]=u&&h?h(e):f(e)}return c[t]}},"532a":function(t,e,n){var r=n("ca14"),i=n("4799"),o=n("f4b1"),a=r.RangeError;t.exports=function(t){if(void 0===t)return 0;var e=i(t),n=o(e);if(e!==n)throw a("Wrong length or index");return n}},"53b8":function(t,e,n){var r=n("34bc"),i=n("0b61"),o=r("keys");t.exports=function(t){return o[t]||(o[t]=i(t))}},5408:function(t,e,n){"use strict";var r=n("961e"),i=n("d796").map;r({target:"Array",proto:!0,forced:!n("7ba8")("map")},{map:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}})},"54ab":function(t,e,n){var r=n("ca14"),i=n("1262"),o=r.String;t.exports=function(t){if("Symbol"===i(t))throw TypeError("Cannot convert a Symbol value to a string");return o(t)}},"54b9":function(t,e,n){var r=n("c814"),i=n("ca14").RegExp,o=r((function(){var t=i("a","y");return t.lastIndex=2,null!=t.exec("abcd")})),a=o||r((function(){return!i("a","y").sticky})),s=o||r((function(){var t=i("^r","gy");return t.lastIndex=2,null!=t.exec("str")}));t.exports={BROKEN_CARET:s,MISSED_STICKY:a,UNSUPPORTED_Y:o}},"55c9":function(t,e,n){"use strict";var r=n("961e"),i=n("b6de");r({target:"String",proto:!0,forced:n("9db9")("sub")},{sub:function(){return i(this,"sub","","")}})},"570c":function(t,e,n){"use strict";var r=n("961e"),i=n("c252"),o=n("96c7"),a=n("c39c"),s=n("54ab"),u=n("2b26"),c=i("".indexOf);r({target:"String",proto:!0,forced:!u("includes")},{includes:function(t){return!!~c(s(a(this)),s(o(t)),arguments.length>1?arguments[1]:void 0)}})},"57c6":function(t,e){t.exports="object"==typeof window},5810:function(t,e,n){var r=n("0a7d");r.__esModule&&(r=r.default),"string"==typeof r&&(r=[[t.i,r,""]]),r.locals&&(t.exports=r.locals),(0,n("5925").default)("d79e9d8e",r,!0,{sourceMap:!1,shadowMode:!1})},5925:function(t,e,n){"use strict";function r(t,e){for(var n=[],r={},i=0;i<e.length;i++){var o=e[i],a=o[0],s={id:t+":"+i,css:o[1],media:o[2],sourceMap:o[3]};r[a]?r[a].parts.push(s):n.push(r[a]={id:a,parts:[s]})}return n}n.r(e),n.d(e,"default",(function(){return p}));var i="undefined"!=typeof document;if("undefined"!=typeof DEBUG&&DEBUG&&!i)throw new Error("vue-style-loader cannot be used in a non-browser environment. Use { target: 'node' } in your Webpack config to indicate a server-rendering environment.");var o={},a=i&&(document.head||document.getElementsByTagName("head")[0]),s=null,u=0,c=!1,l=function(){},h=null,f="data-vue-ssr-id",d="undefined"!=typeof navigator&&/msie [6-9]\b/.test(navigator.userAgent.toLowerCase());function p(t,e,n,i){c=n,h=i||{};var a=r(t,e);return m(a),function(e){for(var n=[],i=0;i<a.length;i++){var s=a[i],u=o[s.id];u.refs--,n.push(u)}for(e?m(a=r(t,e)):a=[],i=0;i<n.length;i++)if(0===(u=n[i]).refs){for(var c=0;c<u.parts.length;c++)u.parts[c]();delete o[u.id]}}}function m(t){for(var e=0;e<t.length;e++){var n=t[e],r=o[n.id];if(r){r.refs++;for(var i=0;i<r.parts.length;i++)r.parts[i](n.parts[i]);for(;i<n.parts.length;i++)r.parts.push(v(n.parts[i]));r.parts.length>n.parts.length&&(r.parts.length=n.parts.length)}else{var a=[];for(i=0;i<n.parts.length;i++)a.push(v(n.parts[i]));o[n.id]={id:n.id,refs:1,parts:a}}}}function g(){var t=document.createElement("style");return t.type="text/css",a.appendChild(t),t}function v(t){var e,n,r=document.querySelector("style["+f+'~="'+t.id+'"]');if(r){if(c)return l;r.parentNode.removeChild(r)}if(d){var i=u++;r=s||(s=g()),e=_.bind(null,r,i,!1),n=_.bind(null,r,i,!0)}else r=g(),e=x.bind(null,r),n=function(){r.parentNode.removeChild(r)};return e(t),function(r){if(r){if(r.css===t.css&&r.media===t.media&&r.sourceMap===t.sourceMap)return;e(t=r)}else n()}}var y=function(){var t=[];return function(e,n){return t[e]=n,t.filter(Boolean).join("\n")}}();function _(t,e,n,r){var i=n?"":r.css;if(t.styleSheet)t.styleSheet.cssText=y(e,i);else{var o=document.createTextNode(i),a=t.childNodes;a[e]&&t.removeChild(a[e]),a.length?t.insertBefore(o,a[e]):t.appendChild(o)}}function x(t,e){var n=e.css,r=e.media,i=e.sourceMap;if(r&&t.setAttribute("media",r),h.ssrId&&t.setAttribute(f,e.id),i&&(n+="\n/*# sourceURL="+i.sources[0]+" */",n+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(i))))+" */"),t.styleSheet)t.styleSheet.cssText=n;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(n))}}},"5b0d":function(t,e,n){var r=n("97d8"),i=n("9a02"),o=n("8088");t.exports=function(t,e){if(r(t),i(e)&&e.constructor===t)return e;var n=o.f(t);return(0,n.resolve)(e),n.promise}},"5c75":function(t,e,n){var r=n("4704"),i=n("988d");t.exports=Object.keys||function(t){return r(t,i)}},"5cb9":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA8AAAAPCAYAAAA71pVKAAAKN2lDQ1BzUkdCIElFQzYxOTY2LTIuMQAAeJydlndUU9kWh8+9N71QkhCKlNBraFICSA29SJEuKjEJEErAkAAiNkRUcERRkaYIMijggKNDkbEiioUBUbHrBBlE1HFwFBuWSWStGd+8ee/Nm98f935rn73P3Wfvfda6AJD8gwXCTFgJgAyhWBTh58WIjYtnYAcBDPAAA2wA4HCzs0IW+EYCmQJ82IxsmRP4F726DiD5+yrTP4zBAP+flLlZIjEAUJiM5/L42VwZF8k4PVecJbdPyZi2NE3OMErOIlmCMlaTc/IsW3z2mWUPOfMyhDwZy3PO4mXw5Nwn4405Er6MkWAZF+cI+LkyviZjg3RJhkDGb+SxGXxONgAoktwu5nNTZGwtY5IoMoIt43kA4EjJX/DSL1jMzxPLD8XOzFouEiSniBkmXFOGjZMTi+HPz03ni8XMMA43jSPiMdiZGVkc4XIAZs/8WRR5bRmyIjvYODk4MG0tbb4o1H9d/JuS93aWXoR/7hlEH/jD9ld+mQ0AsKZltdn6h21pFQBd6wFQu/2HzWAvAIqyvnUOfXEeunxeUsTiLGcrq9zcXEsBn2spL+jv+p8Of0NffM9Svt3v5WF485M4knQxQ143bmZ6pkTEyM7icPkM5p+H+B8H/nUeFhH8JL6IL5RFRMumTCBMlrVbyBOIBZlChkD4n5r4D8P+pNm5lona+BHQllgCpSEaQH4eACgqESAJe2Qr0O99C8ZHA/nNi9GZmJ37z4L+fVe4TP7IFiR/jmNHRDK4ElHO7Jr8WgI0IABFQAPqQBvoAxPABLbAEbgAD+ADAkEoiARxYDHgghSQAUQgFxSAtaAYlIKtYCeoBnWgETSDNnAYdIFj4DQ4By6By2AE3AFSMA6egCnwCsxAEISFyBAVUod0IEPIHLKFWJAb5AMFQxFQHJQIJUNCSAIVQOugUqgcqobqoWboW+godBq6AA1Dt6BRaBL6FXoHIzAJpsFasBFsBbNgTzgIjoQXwcnwMjgfLoK3wJVwA3wQ7oRPw5fgEVgKP4GnEYAQETqiizARFsJGQpF4JAkRIauQEqQCaUDakB6kH7mKSJGnyFsUBkVFMVBMlAvKHxWF4qKWoVahNqOqUQdQnag+1FXUKGoK9RFNRmuizdHO6AB0LDoZnYsuRlegm9Ad6LPoEfQ4+hUGg6FjjDGOGH9MHCYVswKzGbMb0445hRnGjGGmsVisOtYc64oNxXKwYmwxtgp7EHsSewU7jn2DI+J0cLY4X1w8TogrxFXgWnAncFdwE7gZvBLeEO+MD8Xz8MvxZfhGfA9+CD+OnyEoE4wJroRIQiphLaGS0EY4S7hLeEEkEvWITsRwooC4hlhJPEQ8TxwlviVRSGYkNimBJCFtIe0nnSLdIr0gk8lGZA9yPFlM3kJuJp8h3ye/UaAqWCoEKPAUVivUKHQqXFF4pohXNFT0VFysmK9YoXhEcUjxqRJeyUiJrcRRWqVUo3RU6YbStDJV2UY5VDlDebNyi/IF5UcULMWI4kPhUYoo+yhnKGNUhKpPZVO51HXURupZ6jgNQzOmBdBSaaW0b2iDtCkVioqdSrRKnkqNynEVKR2hG9ED6On0Mvph+nX6O1UtVU9Vvuom1TbVK6qv1eaoeajx1UrU2tVG1N6pM9R91NPUt6l3qd/TQGmYaYRr5Grs0Tir8XQObY7LHO6ckjmH59zWhDXNNCM0V2ju0xzQnNbS1vLTytKq0jqj9VSbru2hnaq9Q/uE9qQOVcdNR6CzQ+ekzmOGCsOTkc6oZPQxpnQ1df11Jbr1uoO6M3rGelF6hXrtevf0Cfos/ST9Hfq9+lMGOgYhBgUGrQa3DfGGLMMUw12G/YavjYyNYow2GHUZPTJWMw4wzjduNb5rQjZxN1lm0mByzRRjyjJNM91tetkMNrM3SzGrMRsyh80dzAXmu82HLdAWThZCiwaLG0wS05OZw2xljlrSLYMtCy27LJ9ZGVjFW22z6rf6aG1vnW7daH3HhmITaFNo02Pzq62ZLde2xvbaXPJc37mr53bPfW5nbse322N3055qH2K/wb7X/oODo4PIoc1h0tHAMdGx1vEGi8YKY21mnXdCO3k5rXY65vTW2cFZ7HzY+RcXpkuaS4vLo3nG8/jzGueNueq5clzrXaVuDLdEt71uUnddd457g/sDD30PnkeTx4SnqWeq50HPZ17WXiKvDq/XbGf2SvYpb8Tbz7vEe9CH4hPlU+1z31fPN9m31XfKz95vhd8pf7R/kP82/xsBWgHcgOaAqUDHwJWBfUGkoAVB1UEPgs2CRcE9IXBIYMj2kLvzDecL53eFgtCA0O2h98KMw5aFfR+OCQ8Lrwl/GGETURDRv4C6YMmClgWvIr0iyyLvRJlESaJ6oxWjE6Kbo1/HeMeUx0hjrWJXxl6K04gTxHXHY+Oj45vipxf6LNy5cDzBPqE44foi40V5iy4s1licvvj4EsUlnCVHEtGJMYktie85oZwGzvTSgKW1S6e4bO4u7hOeB28Hb5Lvyi/nTyS5JpUnPUp2Td6ePJninlKR8lTAFlQLnqf6p9alvk4LTduf9ik9Jr09A5eRmHFUSBGmCfsytTPzMoezzLOKs6TLnJftXDYlChI1ZUPZi7K7xTTZz9SAxESyXjKa45ZTk/MmNzr3SJ5ynjBvYLnZ8k3LJ/J9879egVrBXdFboFuwtmB0pefK+lXQqqWrelfrry5aPb7Gb82BtYS1aWt/KLQuLC98uS5mXU+RVtGaorH1futbixWKRcU3NrhsqNuI2ijYOLhp7qaqTR9LeCUXS61LK0rfb+ZuvviVzVeVX33akrRlsMyhbM9WzFbh1uvb3LcdKFcuzy8f2x6yvXMHY0fJjpc7l+y8UGFXUbeLsEuyS1oZXNldZVC1tep9dUr1SI1XTXutZu2m2te7ebuv7PHY01anVVda926vYO/Ner/6zgajhop9mH05+x42Rjf2f836urlJo6m06cN+4X7pgYgDfc2Ozc0tmi1lrXCrpHXyYMLBy994f9Pdxmyrb6e3lx4ChySHHn+b+O31w0GHe4+wjrR9Z/hdbQe1o6QT6lzeOdWV0iXtjusePhp4tLfHpafje8vv9x/TPVZzXOV42QnCiaITn07mn5w+lXXq6enk02O9S3rvnIk9c60vvG/wbNDZ8+d8z53p9+w/ed71/LELzheOXmRd7LrkcKlzwH6g4wf7HzoGHQY7hxyHui87Xe4Znjd84or7ldNXva+euxZw7dLI/JHh61HXb95IuCG9ybv56Fb6ree3c27P3FlzF3235J7SvYr7mvcbfjT9sV3qID0+6j068GDBgztj3LEnP2X/9H686CH5YcWEzkTzI9tHxyZ9Jy8/Xvh4/EnWk5mnxT8r/1z7zOTZd794/DIwFTs1/lz0/NOvm1+ov9j/0u5l73TY9P1XGa9mXpe8UX9z4C3rbf+7mHcTM7nvse8rP5h+6PkY9PHup4xPn34D94Tz+49wZioAAAAJcEhZcwAACxIAAAsSAdLdfvwAAALeSURBVHicVZPNaxNBGMbfnZ3srmuakCZpGpNSWjDZYgqW3LzYgkir1kDBHPwHBA96UHrUkwdBT56KFPFv6KEWpBUMtBFaanuoVULSpMQkzUeTNNtssh/OmxrBuQ0zz/PM+76/oZZlAa7JSSIYhiKyvSgBDFiEuIhlOUyOa3CmWWsDNDmO03j+h7a/b3ZQQ/tCXQ87ZJ64QNdljudlKghuSZbdeqdTb6uqKBuGA3heVfVwjd1voAHtCy/xvM/kDJ8oi+6Z23PvBUGwsySLJ8Q6b7fr28nNV6WT4h67J5zrYQxsUHwqJqLw5vStR3fuzce7eheOsllo1Ovg9XpBURRPLBZ782F5+W1yK7Em83zn3FA0ijXiU5VI5MazxcUHkiRBOpOGcrkMzUYD7HY7DA0NwejoKO/xep8/efzod+HouGJxnEixOVhjbGHhRSAQ4Cy4aGClXOkZ+P1+CAaDgH11uVxk9u791x+XlqYl0xyg2FWv3389rCh8tVoFTB4cHISpqSnIHecgEolAu92GWq0GrVYLxsbGiNPtvlqpVDSK47CJ4khLVUkqlYKLxQEhHESuRSD5LQl6V4f+SJkRL0pSgOmyFOfITtRMJsPOLU5VVWg2z3rieDwOiUQCsrkcCDYbsAmAYRiWZZqnqKMIQPP0dDudTuuiKNq63W7vUig0AU6nE6LRKHQ6HSgWi6BpGk7AaDWbv1BHkZxGtZrP53J7V0ZGosyg193h4WHGBA9ejxfGx8fBNE3AnhTy+WSrXj9pc1yTInJIztbm18WZy7MrysSE7PF4YMDhAHYGoiSCz+eDs7MzODw4KO5sJ18SSlWWrFFkFZFDcjY+f5onAO/cbndIFIQeuoQQKJVKnS/r6z/XVleeMuaKqmHUKD3UKDKKqCFySM7G6urD/d3dkD8YnGMmAVbrQa1S2Slks98x8a/wgm10/2fAkENySoVCo1gqpf77VazG3lNZYv9X/QEJM4cEk5QMqQAAAABJRU5ErkJggg=="},"5ce1":function(t,e,n){var r=n("a0a0"),i=n("c814");t.exports=!!Object.getOwnPropertySymbols&&!i((function(){var t=Symbol();return!String(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&r&&r<41}))},"5eb3":function(t,e,n){var r=n("3a40").Global;function i(){return r.localStorage}function o(t){return i().getItem(t)}t.exports={name:"localStorage",read:o,write:function(t,e){return i().setItem(t,e)},each:function(t){for(var e=i().length-1;e>=0;e--){var n=i().key(e);t(o(n),n)}},remove:function(t){return i().removeItem(t)},clearAll:function(){return i().clear()}}},"5ffc":function(t,e,n){n("961e")({target:"Reflect",stat:!0},{ownKeys:n("4b1a")})},"61a6":function(t,e){var n=Function.prototype,r=n.apply,i=n.bind,o=n.call;t.exports="object"==typeof Reflect&&Reflect.apply||(i?o.bind(r):function(){return o.apply(r,arguments)})},"622a":function(t,e,n){var r=n("961e"),i=n("ea06").entries;r({target:"Object",stat:!0},{entries:function(t){return i(t)}})},6266:function(t,e,n){(function(t){function n(t,e){for(var n=0,r=t.length-1;r>=0;r--){var i=t[r];"."===i?t.splice(r,1):".."===i?(t.splice(r,1),n++):n&&(t.splice(r,1),n--)}if(e)for(;n--;n)t.unshift("..");return t}function r(t,e){if(t.filter)return t.filter(e);for(var n=[],r=0;r<t.length;r++)e(t[r],r,t)&&n.push(t[r]);return n}e.resolve=function(){for(var e="",i=!1,o=arguments.length-1;o>=-1&&!i;o--){var a=o>=0?arguments[o]:t.cwd();if("string"!=typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(e=a+"/"+e,i="/"===a.charAt(0))}return(i?"/":"")+(e=n(r(e.split("/"),(function(t){return!!t})),!i).join("/"))||"."},e.normalize=function(t){var o=e.isAbsolute(t),a="/"===i(t,-1);return(t=n(r(t.split("/"),(function(t){return!!t})),!o).join("/"))||o||(t="."),t&&a&&(t+="/"),(o?"/":"")+t},e.isAbsolute=function(t){return"/"===t.charAt(0)},e.join=function(){var t=Array.prototype.slice.call(arguments,0);return e.normalize(r(t,(function(t,e){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t})).join("/"))},e.relative=function(t,n){function r(t){for(var e=0;e<t.length&&""===t[e];e++);for(var n=t.length-1;n>=0&&""===t[n];n--);return e>n?[]:t.slice(e,n-e+1)}t=e.resolve(t).substr(1),n=e.resolve(n).substr(1);for(var i=r(t.split("/")),o=r(n.split("/")),a=Math.min(i.length,o.length),s=a,u=0;u<a;u++)if(i[u]!==o[u]){s=u;break}var c=[];for(u=s;u<i.length;u++)c.push("..");return(c=c.concat(o.slice(s))).join("/")},e.sep="/",e.delimiter=":",e.dirname=function(t){if("string"!=typeof t&&(t+=""),0===t.length)return".";for(var e=t.charCodeAt(0),n=47===e,r=-1,i=!0,o=t.length-1;o>=1;--o)if(47===(e=t.charCodeAt(o))){if(!i){r=o;break}}else i=!1;return-1===r?n?"/":".":n&&1===r?"/":t.slice(0,r)},e.basename=function(t,e){var n=function(t){"string"!=typeof t&&(t+="");var e,n=0,r=-1,i=!0;for(e=t.length-1;e>=0;--e)if(47===t.charCodeAt(e)){if(!i){n=e+1;break}}else-1===r&&(i=!1,r=e+1);return-1===r?"":t.slice(n,r)}(t);return e&&n.substr(-1*e.length)===e&&(n=n.substr(0,n.length-e.length)),n},e.extname=function(t){"string"!=typeof t&&(t+="");for(var e=-1,n=0,r=-1,i=!0,o=0,a=t.length-1;a>=0;--a){var s=t.charCodeAt(a);if(47!==s)-1===r&&(i=!1,r=a+1),46===s?-1===e?e=a:1!==o&&(o=1):-1!==e&&(o=-1);else if(!i){n=a+1;break}}return-1===e||-1===r||0===o||1===o&&e===r-1&&e===n+1?"":t.slice(e,r)};var i="b"==="ab".substr(-1)?function(t,e,n){return t.substr(e,n)}:function(t,e,n){return e<0&&(e=t.length+e),t.substr(e,n)}}).call(this,n("eef6"))},"62b4":function(t,e,n){var r=n("ca14"),i=n("d45e"),o=n("081e"),a=n("afdf"),s=n("7b76"),u=r.Object;t.exports=s?function(t){return"symbol"==typeof t}:function(t){var e=i("Symbol");return o(e)&&a(e.prototype,u(t))}},"62ea":function(t,e,n){var r=n("6446"),i=n("c814"),o=n("c4ae");t.exports=!r&&!i((function(){return 7!=Object.defineProperty(o("div"),"a",{get:function(){return 7}}).a}))},6326:function(t,e,n){var r=n("ca14");t.exports=r.Promise},6346:function(t,e,n){var r=n("c814"),i=n("ca14").RegExp;t.exports=r((function(){var t=i("(?<a>b)","g");return"b"!==t.exec("b").groups.a||"bc"!=="b".replace(t,"$<a>c")}))},6446:function(t,e,n){var r=n("c814");t.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},6566:function(t,e,n){var r=n("519f")("iterator"),i=!1;try{var o=0,a={next:function(){return{done:!!o++}},return:function(){i=!0}};a[r]=function(){return this},Array.from(a,(function(){throw 2}))}catch(t){}t.exports=function(t,e){if(!e&&!i)return!1;var n=!1;try{var o={};o[r]=function(){return{next:function(){return{done:n=!0}}}},t(o)}catch(t){}return n}},6599:function(t,e,n){var r=n("97d8"),i=n("47fa");t.exports=function(t,e,n,o){try{return o?e(r(n)[0],n[1]):e(n)}catch(e){i(t,"throw",e)}}},"66da":function(t,e){var n="expire_mixin";t.exports=function(){var t=this.createStore(this.storage,null,this._namespacePrefix+n);return{set:function(e,r,i,o){return this.hasNamespace(n)||t.set(r,o),e()},get:function(t,r){return this.hasNamespace(n)||e.call(this,r),t()},remove:function(e,r){return this.hasNamespace(n)||t.remove(r),e()},getExpiration:function(e,n){return t.get(n)},removeExpiredKeys:function(t){var n=[];this.each((function(t,e){n.push(e)}));for(var r=0;r<n.length;r++)e.call(this,n[r])}};function e(e){t.get(e,Number.MAX_VALUE)<=(new Date).getTime()&&(this.raw.remove(e),t.remove(e))}}},"675d":function(t,e,n){var r,i,o,a,s=n("ca14"),u=n("61a6"),c=n("ad0f"),l=n("081e"),h=n("c7e7"),f=n("c814"),d=n("03c2"),p=n("13eb"),m=n("c4ae"),g=n("2a67"),v=n("801d"),y=s.setImmediate,_=s.clearImmediate,x=s.process,b=s.Dispatch,w=s.Function,M=s.MessageChannel,S=s.String,T=0,E={},A="onreadystatechange";try{r=s.location}catch(t){}var C=function(t){if(h(E,t)){var e=E[t];delete E[t],e()}},P=function(t){return function(){C(t)}},L=function(t){C(t.data)},O=function(t){s.postMessage(S(t),r.protocol+"//"+r.host)};y&&_||(y=function(t){var e=p(arguments,1);return E[++T]=function(){u(l(t)?t:w(t),void 0,e)},i(T),T},_=function(t){delete E[t]},v?i=function(t){x.nextTick(P(t))}:b&&b.now?i=function(t){b.now(P(t))}:M&&!g?(a=(o=new M).port2,o.port1.onmessage=L,i=c(a.postMessage,a)):s.addEventListener&&l(s.postMessage)&&!s.importScripts&&r&&"file:"!==r.protocol&&!f(O)?(i=O,s.addEventListener("message",L,!1)):i=A in m("script")?function(t){d.appendChild(m("script"))[A]=function(){d.removeChild(this),C(t)}}:function(t){setTimeout(P(t),0)}),t.exports={set:y,clear:_}},"6c01":function(t,e,n){var r=n("ca14"),i=n("6446"),o=n("62ea"),a=n("97d8"),s=n("3e94"),u=r.TypeError,c=Object.defineProperty;e.f=i?c:function(t,e,n){if(a(t),e=s(e),a(n),o)try{return c(t,e,n)}catch(t){}if("get"in n||"set"in n)throw u("Accessors not supported");return"value"in n&&(t[e]=n.value),t}},"6ca2":function(t,e,n){"use strict";var r=n("002b"),i=n("d796").every,o=r.aTypedArray;(0,r.exportTypedArrayMethod)("every",(function(t){return i(o(this),t,arguments.length>1?arguments[1]:void 0)}))},"6d31":function(t,e,n){"use strict";var r=n("ca14"),i=n("c252"),o=n("c814"),a=n("b0c4"),s=n("2d18"),u=n("002b"),c=n("3492"),l=n("cf94"),h=n("a0a0"),f=n("119b"),d=r.Array,p=u.aTypedArray,m=u.exportTypedArrayMethod,g=r.Uint16Array,v=g&&i(g.prototype.sort),y=!(!v||o((function(){v(new g(2),null)}))&&o((function(){v(new g(2),{})}))),_=!!v&&!o((function(){if(h)return h<74;if(c)return c<67;if(l)return!0;if(f)return f<602;var t,e,n=new g(516),r=d(516);for(t=0;t<516;t++)e=t%4,n[t]=515-t,r[t]=t-2*e+3;for(v(n,(function(t,e){return(t/4|0)-(e/4|0)})),t=0;t<516;t++)if(n[t]!==r[t])return!0}));m("sort",(function(t){return void 0!==t&&a(t),_?v(this,t):s(p(this),function(t){return function(e,n){return void 0!==t?+t(e,n)||0:n!=n?-1:e!=e?1:0===e&&0===n?1/e>0&&1/n<0?1:-1:e>n}}(t))}),!_||y)},"6d9b":function(t,e,n){var r=n("c252"),i=n("c814"),o=n("081e"),a=n("1262"),s=n("d45e"),u=n("4f29"),c=function(){},l=[],h=s("Reflect","construct"),f=/^\s*(?:class|function)\b/,d=r(f.exec),p=!f.exec(c),m=function(t){if(!o(t))return!1;try{return h(c,l,t),!0}catch(t){return!1}};t.exports=!h||i((function(){var t;return m(m.call)||!m(Object)||!m((function(){t=!0}))||t}))?function(t){if(!o(t))return!1;switch(a(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}return p||!!d(f,u(t))}:m},"6e68":function(t,e,n){"use strict";var r=n("097d"),i=n("9acd"),o=n("db7f"),a=n("e13b"),s=n("b45e"),u="Array Iterator",c=a.set,l=a.getterFor(u);t.exports=s(Array,"Array",(function(t,e){c(this,{type:u,target:r(t),index:0,kind:e})}),(function(){var t=l(this),e=t.target,n=t.kind,r=t.index++;return!e||r>=e.length?(t.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:r,done:!1}:"values"==n?{value:e[r],done:!1}:{value:[r,e[r]],done:!1}}),"values"),o.Arguments=o.Array,i("keys"),i("values"),i("entries")},"716d":function(t,e,n){var r=n("4748");t.exports=/web0s(?!.*chrome)/i.test(r)},7203:function(t,e,n){t.exports=n.p+"img/kedu.2adfe059.png"},7219:function(t,e,n){var r=n("ca14"),i=n("081e"),o=n("c7e7"),a=n("d3a9"),s=n("a2c2"),u=n("4f29"),c=n("e13b"),l=n("265d").CONFIGURABLE,h=c.get,f=c.enforce,d=String(String).split("String");(t.exports=function(t,e,n,u){var c,h=!!u&&!!u.unsafe,p=!!u&&!!u.enumerable,m=!!u&&!!u.noTargetGet,g=u&&void 0!==u.name?u.name:e;i(n)&&("Symbol("===String(g).slice(0,7)&&(g="["+String(g).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),(!o(n,"name")||l&&n.name!==g)&&a(n,"name",g),(c=f(n)).source||(c.source=d.join("string"==typeof g?g:""))),t!==r?(h?!m&&t[e]&&(p=!0):delete t[e],p?t[e]=n:a(t,e,n)):p?t[e]=n:s(e,n)})(Function.prototype,"toString",(function(){return i(this)&&h(this).source||u(this)}))},"72ae":function(t,e,n){n("18fd")("iterator")},7464:function(t,e,n){var r=n("c252"),i=n("97d8"),o=n("2946");t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{(t=r(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(n,[]),e=n instanceof Array}catch(t){}return function(n,r){return i(n),o(r),e?t(n,r):n.__proto__=r,n}}():void 0)},"75a1":function(t,e,n){"use strict";var r=n("6446"),i=n("c252"),o=n("cbac"),a=n("c814"),s=n("5c75"),u=n("b2e9"),c=n("c829"),l=n("41a4"),h=n("96a5"),f=Object.assign,d=Object.defineProperty,p=i([].concat);t.exports=!f||a((function(){if(r&&1!==f({b:1},f(d({},"a",{enumerable:!0,get:function(){d(this,"b",{value:3,enumerable:!1})}}),{b:2})).b)return!0;var t={},e={},n=Symbol(),i="abcdefghijklmnopqrst";return t[n]=7,i.split("").forEach((function(t){e[t]=t})),7!=f({},t)[n]||s(f({},e)).join("")!=i}))?function(t,e){for(var n=l(t),i=arguments.length,a=1,f=u.f,d=c.f;i>a;)for(var m,g=h(arguments[a++]),v=f?p(s(g),f(g)):s(g),y=v.length,_=0;y>_;)m=v[_++],r&&!o(d,g,m)||(n[m]=g[m]);return n}:f},7958:function(t,e,n){var r=n("ca14"),i=n("23a5"),o=r.RangeError;t.exports=function(t,e){var n=i(t);if(n%e)throw o("Wrong offset");return n}},"79b5":function(t,e,n){var r=n("ca14"),i=n("081e"),o=n("4f29"),a=r.WeakMap;t.exports=i(a)&&/native code/.test(o(a))},"7a02":function(t,e,n){var r=n("9a02"),i=n("cc43"),o=n("519f")("match");t.exports=function(t){var e;return r(t)&&(void 0!==(e=t[o])?!!e:"RegExp"==i(t))}},"7b76":function(t,e,n){var r=n("5ce1");t.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},"7ba8":function(t,e,n){var r=n("c814"),i=n("519f"),o=n("a0a0"),a=i("species");t.exports=function(t){return o>=51||!r((function(){var e=[];return(e.constructor={})[a]=function(){return{foo:1}},1!==e[t](Boolean).foo}))}},"7c98":function(t,e,n){(function(t,r){var i;
14
+ */!function(){"use strict";var n={}.hasOwnProperty;function i(){for(var t=[],e=0;e<arguments.length;e++){var r=arguments[e];if(r){var o=typeof r;if("string"===o||"number"===o)t.push(r);else if(Array.isArray(r)){if(r.length){var a=i.apply(null,r);a&&t.push(a)}}else if("object"===o)if(r.toString===Object.prototype.toString)for(var s in r)n.call(r,s)&&r[s]&&t.push(s);else t.push(r.toString())}}return t.join(" ")}t.exports?(i.default=i,t.exports=i):void 0===(r=function(){return i}.apply(e,[]))||(t.exports=r)}()},function(t,e,n){var r=n(382);t.exports=function(t){return r(t,5)}},function(t,e){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(t){"object"==typeof window&&(n=window)}t.exports=n},function(t,e,n){"use strict";e.__esModule=!0;var r,i=n(179),o=(r=i)&&r.__esModule?r:{default:r};e.default=o.default||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t}},function(t,e,n){var r=n(291),i=n(294);t.exports=function(t,e){var n=i(t,e);return r(n)?n:void 0}},function(t,e,n){var r=n(24),i=n(71);t.exports=n(16)?function(t,e,n){return r.f(t,e,i(1,n))}:function(t,e,n){return t[e]=n,t}},function(t,e,n){var r=n(15),i=n(171),o=n(172),a=Object.defineProperty;e.f=n(16)?Object.defineProperty:function(t,e,n){if(r(t),e=o(e,!0),r(n),i)try{return a(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(t[e]=n.value),t}},function(t,e){t.exports={}},function(t,e,n){(function(e){var n=Object.assign?Object.assign:function(t,e,n,r){for(var i=1;i<arguments.length;i++)s(Object(arguments[i]),(function(e,n){t[n]=e}));return t},r=function(){if(Object.create)return function(t,e,r,i){var o=a(arguments,1);return n.apply(this,[Object.create(t)].concat(o))};{function t(){}return function(e,r,i,o){var s=a(arguments,1);return t.prototype=e,n.apply(this,[new t].concat(s))}}}(),i=String.prototype.trim?function(t){return String.prototype.trim.call(t)}:function(t){return t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")},o="undefined"!=typeof window?window:e;function a(t,e){return Array.prototype.slice.call(t,e||0)}function s(t,e){u(t,(function(t,n){return e(t,n),!1}))}function u(t,e){if(c(t)){for(var n=0;n<t.length;n++)if(e(t[n],n))return t[n]}else for(var r in t)if(t.hasOwnProperty(r)&&e(t[r],r))return t[r]}function c(t){return null!=t&&"function"!=typeof t&&"number"==typeof t.length}t.exports={assign:n,create:r,trim:i,bind:function(t,e){return function(){return e.apply(t,Array.prototype.slice.call(arguments,0))}},slice:a,each:s,map:function(t,e){var n=c(t)?[]:{};return u(t,(function(t,r){return n[r]=e(t,r),!1})),n},pluck:u,isList:c,isFunction:function(t){return t&&"[object Function]"==={}.toString.call(t)},isObject:function(t){return t&&"[object Object]"==={}.toString.call(t)},Global:o}}).call(this,n(20))},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getBelongList=e.getRegionDataInfo=e.postConsumer=e.getByCuser=e.getUserInfo=e.refreshToken=e.getToken=void 0;var r=a(n(120)),i=n(13),o=a(n(234));function a(t){return t&&t.__esModule?t:{default:t}}var s="/iam/v1/sys/refresh/token",u="/iam/v1/sys/oauth/token",c="/iam/v1/sys/user/info",l="/iam/v1/sys/system/getByCuser",h="/iam/v1/sys/user/exchange/consumer",f="https://gateway-bmg-out.rockontrol.com/bmg/v1/apply/weather/{areaCode}",d="/iam/v1/sys/consumer/belongBySysList";e.getToken=function(t){return r.default.post(""+i.sessionStore.get("IAM_BASE_URL")+u,t)},e.refreshToken=function(t){return r.default.post(""+i.sessionStore.get("IAM_BASE_URL")+s,o.default.stringify(t),{"Content-Type":"application/x-www-form-urlencoded"})},e.getUserInfo=function(t,e){return r.default.get(""+i.sessionStore.get("IAM_BASE_URL")+c,t,e)},e.getByCuser=function(t){return r.default.get(""+sessionStorage.getItem("IAM_BASE_URL")+l,t)},e.postConsumer=function(t){return r.default.post(""+sessionStorage.getItem("IAM_BASE_URL")+h+"/"+t)},e.getRegionDataInfo=function(t){return r.default.get(f,t)},e.getBelongList=function(t){return r.default.get(""+sessionStorage.getItem("IAM_BASE_URL")+d,t)}},function(t,e,n){var r=n(31),i=n(251),o=n(252),a=r?r.toStringTag:void 0;t.exports=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":a&&a in Object(t)?i(t):o(t)}},function(t,e,n){var r=n(40);t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,i){return t.call(e,n,r,i)}}return function(){return t.apply(e,arguments)}}},function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,e,n){var r=n(11).Symbol;t.exports=r},function(t,e,n){var r=n(3),i=n(90);t.exports=function(t){return null!=t&&i(t.length)&&!r(t)}},function(t,e,n){var r=n(88),i=n(89);t.exports=function(t,e,n,o){var a=!n;n||(n={});for(var s=-1,u=e.length;++s<u;){var c=e[s],l=o?o(n[c],t[c],c,n,t):void 0;void 0===l&&(l=t[c]),a?i(n,c,l):r(n,c,l)}return n}},function(t,e,n){var r=n(155),i=n(366),o=n(32);t.exports=function(t){return o(t)?r(t,!0):i(t)}},function(t,e,n){var r=n(65);t.exports=function(t){return Object(r(t))}},function(t,e,n){var r=n(167),i=n(104);t.exports=Object.keys||function(t){return r(t,i)}},function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},function(t,e,n){var r=n(101),i=n(65);t.exports=function(t){return r(i(t))}},function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},function(t,e){t.exports=function(t){try{return!!t()}catch(t){return!0}}},function(t,e,n){"use strict";e.__esModule=!0,e.default=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}},function(t,e,n){"use strict";e.__esModule=!0;var r,i=n(173),o=(r=i)&&r.__esModule?r:{default:r};e.default=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),(0,o.default)(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}()},function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),t.webpackPolyfill=1),t}},function(t,e,n){t.exports={default:n(188),__esModule:!0}},function(t,e,n){"use strict";var r=n(190)(!0);n(106)(String,"String",(function(t){this._t=String(t),this._i=0}),(function(){var t,e=this._t,n=this._i;return n>=e.length?{value:void 0,done:!0}:(t=r(e,n),this._i+=t.length,{value:t,done:!1})}))},function(t,e,n){t.exports={default:n(242),__esModule:!0}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isFunction=e.notFoundRouter=e.loadView=e.getUrlParam=e.hasOwn=void 0;var r=u(n(21)),i=u(n(244)),o=u(n(47)),a=u(n(247));e.mergeProps=function(){var t=[].slice.call(arguments,0),e={};return t.forEach((function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=!0,u=!1,c=void 0;try{for(var l,h=(0,o.default)((0,i.default)(t));!(n=(l=h.next()).done);n=!0){var f=l.value,d=(0,a.default)(f,2),p=d[0],m=d[1];e[p]=e[p]||{},(0,s.default)(m)?(0,r.default)(e[p],m):e[p]=m}}catch(t){u=!0,c=t}finally{try{!n&&h.return&&h.return()}finally{if(u)throw c}}})),e};var s=u(n(134));function u(t){return t&&t.__esModule?t:{default:t}}var c=Object.prototype,l=c.toString;e.hasOwn=c.hasOwnProperty,e.getUrlParam=function(t){var e=new RegExp("(^|&)"+t+"=([^&]*)(&|$)"),n=window.location.search.split("?")[1]?window.location.search.split("?")[1].match(e):null;return null!=n?decodeURI(n[2]):null},e.loadView=function(t,e,r){return function(r){n.e(1).then(function(){var i=[n(403)("./"+e+t+".vue")];r.apply(null,i)}.bind(this)).catch(n.oe)}},e.notFoundRouter={path:"*",redirect:"/404",hidden:!0};e.isFunction=function(t){return"[object Function]"===l.call(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={name:"BlankLayout",render:function(){var t=arguments[0];return t("router-view")}}},function(t,e,n){var r=n(10),i=n(284),o=n(285),a=n(86);t.exports=function(t,e){return r(t)?t:i(t,e)?[t]:o(a(t))}},function(t,e,n){var r=n(28),i=n(17);t.exports=function(t){return"symbol"==typeof t||i(t)&&"[object Symbol]"==r(t)}},function(t,e,n){var r=n(22)(Object,"create");t.exports=r},function(t,e,n){var r=n(299),i=n(300),o=n(301),a=n(302),s=n(303);function u(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=i,u.prototype.get=o,u.prototype.has=a,u.prototype.set=s,t.exports=u},function(t,e,n){var r=n(55);t.exports=function(t,e){for(var n=t.length;n--;)if(r(t[n][0],e))return n;return-1}},function(t,e){t.exports=function(t,e){return t===e||t!=t&&e!=e}},function(t,e,n){var r=n(305);t.exports=function(t,e){var n=t.__data__;return r(e)?n["string"==typeof e?"string":"hash"]:n.map}},function(t,e){var n=/^(?:0|[1-9]\d*)$/;t.exports=function(t,e){var r=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==r||"symbol"!=r&&n.test(t))&&t>-1&&t%1==0&&t<e}},function(t,e,n){var r=n(315),i=n(17),o=Object.prototype,a=o.hasOwnProperty,s=o.propertyIsEnumerable,u=r(function(){return arguments}())?r:function(t){return i(t)&&a.call(t,"callee")&&!s.call(t,"callee")};t.exports=u},function(t,e){t.exports=function(t,e){for(var n=-1,r=e.length,i=t.length;++n<r;)t[i+n]=e[n];return t}},function(t,e,n){var r=n(155),i=n(373),o=n(32);t.exports=function(t){return o(t)?r(t):i(t)}},function(t,e,n){var r=n(59),i=n(144),o=n(92),a=n(10);t.exports=function(){var t=arguments.length;if(!t)return[];for(var e=Array(t-1),n=arguments[0],s=t;s--;)e[s-1]=arguments[s];return r(a(n)?o(n):[n],i(e,1))}},function(t,e,n){var r=n(351),i=n(368)((function(t,e,n,i){r(t,e,n,i)}));t.exports=i},function(t,e){function n(e){return t.exports=n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.__esModule=!0,t.exports.default=t.exports,n(e)}t.exports=n,t.exports.__esModule=!0,t.exports.default=t.exports},function(t,e,n){var r=n(377),i=n(378),o=n(379),a=n(381);t.exports=function(t,e){return r(t)||i(t,e)||o(t,e)||a()},t.exports.__esModule=!0,t.exports.default=t.exports},function(t,e){t.exports=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t}},function(t,e,n){var r=n(67),i=Math.min;t.exports=function(t){return t>0?i(r(t),9007199254740991):0}},function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?r:n)(t)}},function(t,e,n){var r=n(102)("keys"),i=n(103);t.exports=function(t){return r[t]||(r[t]=i(t))}},function(t,e){t.exports=!0},function(t,e,n){var r=n(30),i=n(5).document,o=r(i)&&r(i.createElement);t.exports=function(t){return o?i.createElement(t):{}}},function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},function(t,e,n){t.exports=n(186)},function(t,e,n){"use strict";e.__esModule=!0;var r,i=n(45),o=(r=i)&&r.__esModule?r:{default:r};e.default=function(t){return function(){var e=t.apply(this,arguments);return new o.default((function(t,n){return function r(i,a){try{var s=e[i](a),u=s.value}catch(t){return void n(t)}if(!s.done)return o.default.resolve(u).then((function(t){r("next",t)}),(function(t){r("throw",t)}));t(u)}("next")}))}}},function(t,e,n){var r=n(24).f,i=n(37),o=n(6)("toStringTag");t.exports=function(t,e,n){t&&!i(t=n?t:t.prototype,o)&&r(t,o,{configurable:!0,value:e})}},function(t,e,n){n(196);for(var r=n(5),i=n(23),o=n(25),a=n(6)("toStringTag"),s="CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,MediaList,MimeTypeArray,NamedNodeMap,NodeList,PaintRequestList,Plugin,PluginArray,SVGLengthList,SVGNumberList,SVGPathSegList,SVGPointList,SVGStringList,SVGTransformList,SourceBufferList,StyleSheetList,TextTrackCueList,TextTrackList,TouchList".split(","),u=0;u<s.length;u++){var c=s[u],l=r[c],h=l&&l.prototype;h&&!h[a]&&i(h,a,c),o[c]=o.Array}},function(t,e,n){var r=n(39),i=n(6)("toStringTag"),o="Arguments"==r(function(){return arguments}());t.exports=function(t){var e,n,a;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=function(t,e){try{return t[e]}catch(t){}}(e=Object(t),i))?n:o?r(e):"Object"==(a=r(e))&&"function"==typeof e.callee?"Arguments":a}},function(t,e,n){var r=n(76),i=n(6)("iterator"),o=n(25);t.exports=n(1).getIteratorMethod=function(t){if(null!=t)return t[i]||t["@@iterator"]||o[r(t)]}},function(t,e,n){"use strict";var r=n(40);function i(t){var e,n;this.promise=new t((function(t,r){if(void 0!==e||void 0!==n)throw TypeError("Bad Promise constructor");e=t,n=r})),this.resolve=r(e),this.reject=r(n)}t.exports.f=function(t){return new i(t)}},function(t,e,n){"use strict";(function(e){var r=n(4),i=n(221),o=n(125),a={"Content-Type":"application/x-www-form-urlencoded"};function s(t,e){!r.isUndefined(t)&&r.isUndefined(t["Content-Type"])&&(t["Content-Type"]=e)}var u,c={transitional:{silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},adapter:(("undefined"!=typeof XMLHttpRequest||void 0!==e&&"[object process]"===Object.prototype.toString.call(e))&&(u=n(126)),u),transformRequest:[function(t,e){return i(e,"Accept"),i(e,"Content-Type"),r.isFormData(t)||r.isArrayBuffer(t)||r.isBuffer(t)||r.isStream(t)||r.isFile(t)||r.isBlob(t)?t:r.isArrayBufferView(t)?t.buffer:r.isURLSearchParams(t)?(s(e,"application/x-www-form-urlencoded;charset=utf-8"),t.toString()):r.isObject(t)||e&&"application/json"===e["Content-Type"]?(s(e,"application/json"),function(t,e,n){if(r.isString(t))try{return(e||JSON.parse)(t),r.trim(t)}catch(t){if("SyntaxError"!==t.name)throw t}return(n||JSON.stringify)(t)}(t)):t}],transformResponse:[function(t){var e=this.transitional,n=e&&e.silentJSONParsing,i=e&&e.forcedJSONParsing,a=!n&&"json"===this.responseType;if(a||i&&r.isString(t)&&t.length)try{return JSON.parse(t)}catch(t){if(a){if("SyntaxError"===t.name)throw o(t,this,"E_JSON_PARSE");throw t}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(t){return t>=200&&t<300}};c.headers={common:{Accept:"application/json, text/plain, */*"}},r.forEach(["delete","get","head"],(function(t){c.headers[t]={}})),r.forEach(["post","put","patch"],(function(t){c.headers[t]=r.merge(a)})),t.exports=c}).call(this,n(124))},function(t,e,n){var r=n(136)(Object.getPrototypeOf,Object);t.exports=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(13),i=n(9),o=n(27),a=n(8);e.default={name:"AppLogo",inject:["slotsList"],props:{prefix:{type:String,default:"basic"},theme:{type:String,default:"light"}},computed:{currentConsumer:function(){return r.localStore.get("consumer")}},data:function(){return{currentInfo:{icon:void 0,name:void 0}}},mounted:function(){this.getByCuserInfo()},methods:{getByCuserInfo:function(){var t=this,e=r.sessionStore.get("CLIENT_ID");(0,o.getByCuser)().then((function(n){var i=(0,a.filter)(n.data,(function(t){return t.code===e}));i&&!(0,a.isEmpty)(i)&&(t.currentInfo=i[0],i&&i[0]&&i[0].name&&r.sessionStore.set("SYS_PROJECT_NAME",i[0].name))}))}},render:function(){var t=arguments[0],e=this.prefix,n=this.theme,r=i.prefixCls+"-logo";return t("div",{class:[r,r+"-"+e]},[t("div",{class:[r+"-"+e+"-inner",r+"-inner",r+"-"+n+"-inner"]},[t("img",{attrs:{src:this.currentInfo.icon?this.currentInfo.icon:"https://daqilianfangliankong.obs.cn-north-4.myhuaweicloud.com/IAM/1437955217135501312.png"}}),t("span",{class:[r+"-"+e+"-title",r+"-title"]},[this.currentInfo.name])]),this.slotsList.mark?t("div",{class:r+"-mark-inner"},[this.slotsList.mark]):null])}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(264),o=(r=i)&&r.__esModule?r:{default:r};e.default=new o.default},function(module,exports,__webpack_require__){(function(setImmediate){var e;e=function(){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=0)}({0:function(t,e,n){t.exports=n("c7b2")},"002b":function(t,e,n){"use strict";var r,i,o,a=n("f869"),s=n("6446"),u=n("ca14"),c=n("081e"),l=n("9a02"),h=n("c7e7"),f=n("1262"),d=n("82b8"),p=n("d3a9"),m=n("7219"),g=n("6c01").f,v=n("afdf"),y=n("f97a"),_=n("7464"),x=n("519f"),b=n("0b61"),w=u.Int8Array,M=w&&w.prototype,S=u.Uint8ClampedArray,T=S&&S.prototype,E=w&&y(w),A=M&&y(M),C=Object.prototype,P=u.TypeError,L=x("toStringTag"),O=b("TYPED_ARRAY_TAG"),R=b("TYPED_ARRAY_CONSTRUCTOR"),k=a&&!!_&&"Opera"!==f(u.opera),I=!1,D={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},j={BigInt64Array:8,BigUint64Array:8},z=function(t){if(!l(t))return!1;var e=f(t);return h(D,e)||h(j,e)};for(r in D)(o=(i=u[r])&&i.prototype)?p(o,R,i):k=!1;for(r in j)(o=(i=u[r])&&i.prototype)&&p(o,R,i);if((!k||!c(E)||E===Function.prototype)&&(E=function(){throw P("Incorrect invocation")},k))for(r in D)u[r]&&_(u[r],E);if((!k||!A||A===C)&&(A=E.prototype,k))for(r in D)u[r]&&_(u[r].prototype,A);if(k&&y(T)!==A&&_(T,A),s&&!h(A,L))for(r in I=!0,g(A,L,{get:function(){return l(this)?this[O]:void 0}}),D)u[r]&&p(u[r],O,r);t.exports={NATIVE_ARRAY_BUFFER_VIEWS:k,TYPED_ARRAY_CONSTRUCTOR:R,TYPED_ARRAY_TAG:I&&O,aTypedArray:function(t){if(z(t))return t;throw P("Target is not a typed array")},aTypedArrayConstructor:function(t){if(c(t)&&(!_||v(E,t)))return t;throw P(d(t)+" is not a typed array constructor")},exportTypedArrayMethod:function(t,e,n){if(s){if(n)for(var r in D){var i=u[r];if(i&&h(i.prototype,t))try{delete i.prototype[t]}catch(t){}}A[t]&&!n||m(A,t,n?e:k&&M[t]||e)}},exportTypedArrayStaticMethod:function(t,e,n){var r,i;if(s){if(_){if(n)for(r in D)if((i=u[r])&&h(i,t))try{delete i[t]}catch(t){}if(E[t]&&!n)return;try{return m(E,t,n?e:k&&E[t]||e)}catch(t){}}for(r in D)!(i=u[r])||i[t]&&!n||m(i,t,e)}},isView:function(t){if(!l(t))return!1;var e=f(t);return"DataView"===e||h(D,e)||h(j,e)},isTypedArray:z,TypedArray:E,TypedArrayPrototype:A}},"0074":function(t,e,n){"use strict";var r=n("3e94"),i=n("6c01"),o=n("7e3c");t.exports=function(t,e,n){var a=r(e);a in t?i.f(t,a,o(0,n)):t[a]=n}},"03c2":function(t,e,n){var r=n("d45e");t.exports=r("document","documentElement")},"064b":function(t,e,n){var r=n("6446"),i=n("cbac"),o=n("c829"),a=n("7e3c"),s=n("097d"),u=n("3e94"),c=n("c7e7"),l=n("62ea"),h=Object.getOwnPropertyDescriptor;e.f=r?h:function(t,e){if(t=s(t),e=u(e),l)try{return h(t,e)}catch(t){}if(c(t,e))return a(!i(o.f,t,e),t[e])}},"071d":function(t,e,n){"use strict";var r=n("002b"),i=n("d796").some,o=r.aTypedArray;(0,r.exportTypedArrayMethod)("some",(function(t){return i(o(this),t,arguments.length>1?arguments[1]:void 0)}))},"081e":function(t,e){t.exports=function(t){return"function"==typeof t}},"097a":function(t,e,n){"use strict";var r=n("41a4"),i=n("a10c"),o=n("28dc");t.exports=function(t){for(var e=r(this),n=o(e),a=arguments.length,s=i(a>1?arguments[1]:void 0,n),u=a>2?arguments[2]:void 0,c=void 0===u?n:i(u,n);c>s;)e[s++]=t;return e}},"097d":function(t,e,n){var r=n("96a5"),i=n("c39c");t.exports=function(t){return r(i(t))}},"0a7d":function(t,e,n){(e=n("a1a8")(!1)).push([t.i,'.sk-chase-box[data-v-c8c2036e]{width:100%;height:100%;position:relative}.sk-chase-core[data-v-c8c2036e]{position:absolute;left:0;top:0;right:0;bottom:0;z-index:1;display:flex;justify-content:center;align-items:center}.sk-chase[data-v-c8c2036e]{width:40px;height:40px;position:relative;-webkit-animation:sk-chase-data-v-c8c2036e 2.5s linear infinite both;animation:sk-chase-data-v-c8c2036e 2.5s linear infinite both}.sk-chase-dot[data-v-c8c2036e]{width:100%;height:100%;position:absolute;left:0;top:0;-webkit-animation:sk-chase-dot-data-v-c8c2036e 2s ease-in-out infinite both;animation:sk-chase-dot-data-v-c8c2036e 2s ease-in-out infinite both}.sk-chase-dot[data-v-c8c2036e]:before{content:"";display:block;width:25%;height:25%;background-color:#0f82ff;border-radius:100%;-webkit-animation:sk-chase-dot-before-data-v-c8c2036e 2s ease-in-out infinite both;animation:sk-chase-dot-before-data-v-c8c2036e 2s ease-in-out infinite both}.sk-chase-dot[data-v-c8c2036e]:first-child{-webkit-animation-delay:-1.1s;animation-delay:-1.1s}.sk-chase-dot[data-v-c8c2036e]:nth-child(2){-webkit-animation-delay:-1s;animation-delay:-1s}.sk-chase-dot[data-v-c8c2036e]:nth-child(3){-webkit-animation-delay:-.9s;animation-delay:-.9s}.sk-chase-dot[data-v-c8c2036e]:nth-child(4){-webkit-animation-delay:-.8s;animation-delay:-.8s}.sk-chase-dot[data-v-c8c2036e]:nth-child(5){-webkit-animation-delay:-.7s;animation-delay:-.7s}.sk-chase-dot[data-v-c8c2036e]:nth-child(6){-webkit-animation-delay:-.6s;animation-delay:-.6s}.sk-chase-dot[data-v-c8c2036e]:first-child:before{-webkit-animation-delay:-1.1s;animation-delay:-1.1s}.sk-chase-dot[data-v-c8c2036e]:nth-child(2):before{-webkit-animation-delay:-1s;animation-delay:-1s}.sk-chase-dot[data-v-c8c2036e]:nth-child(3):before{-webkit-animation-delay:-.9s;animation-delay:-.9s}.sk-chase-dot[data-v-c8c2036e]:nth-child(4):before{-webkit-animation-delay:-.8s;animation-delay:-.8s}.sk-chase-dot[data-v-c8c2036e]:nth-child(5):before{-webkit-animation-delay:-.7s;animation-delay:-.7s}.sk-chase-dot[data-v-c8c2036e]:nth-child(6):before{-webkit-animation-delay:-.6s;animation-delay:-.6s}@-webkit-keyframes sk-chase-data-v-c8c2036e{to{transform:rotate(340deg)}}@keyframes sk-chase-data-v-c8c2036e{to{transform:rotate(340deg)}}@-webkit-keyframes sk-chase-dot-data-v-c8c2036e{80%,to{transform:rotate(340deg)}}@keyframes sk-chase-dot-data-v-c8c2036e{80%,to{transform:rotate(340deg)}}@-webkit-keyframes sk-chase-dot-before-data-v-c8c2036e{50%{transform:scale(.4)}0%,to{transform:scale(1)}}@keyframes sk-chase-dot-before-data-v-c8c2036e{50%{transform:scale(.4)}0%,to{transform:scale(1)}}',""]),t.exports=e},"0b57":function(t,e){t.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},"0b61":function(t,e,n){var r=n("c252"),i=0,o=Math.random(),a=r(1..toString);t.exports=function(t){return"Symbol("+(void 0===t?"":t)+")_"+a(++i+o,36)}},"0d84":function(t,e,n){n("50cc")("Float32",(function(t){return function(e,n,r){return t(this,e,n,r)}}))},"0ec0":function(t,e,n){"use strict";var r=n("ca14"),i=n("c252"),o=n("6446"),a=n("f869"),s=n("265d"),u=n("d3a9"),c=n("f0f8"),l=n("c814"),h=n("c3f4"),f=n("4799"),d=n("f4b1"),p=n("532a"),m=n("b6b1"),g=n("f97a"),v=n("7464"),y=n("9cd9").f,_=n("6c01").f,x=n("097a"),b=n("9a1e"),w=n("9207"),M=n("e13b"),S=s.PROPER,T=s.CONFIGURABLE,E=M.get,A=M.set,C="ArrayBuffer",P="DataView",L="prototype",O="Wrong index",R=r[C],k=R,I=k&&k[L],D=r[P],j=D&&D[L],z=Object.prototype,N=r.Array,F=r.RangeError,B=i(x),H=i([].reverse),G=m.pack,U=m.unpack,W=function(t){return[255&t]},V=function(t){return[255&t,t>>8&255]},Z=function(t){return[255&t,t>>8&255,t>>16&255,t>>24&255]},q=function(t){return t[3]<<24|t[2]<<16|t[1]<<8|t[0]},Y=function(t){return G(t,23,4)},J=function(t){return G(t,52,8)},X=function(t,e){_(t[L],e,{get:function(){return E(this)[e]}})},$=function(t,e,n,r){var i=p(n),o=E(t);if(i+e>o.byteLength)throw F(O);var a=E(o.buffer).bytes,s=i+o.byteOffset,u=b(a,s,s+e);return r?u:H(u)},Q=function(t,e,n,r,i,o){var a=p(n),s=E(t);if(a+e>s.byteLength)throw F(O);for(var u=E(s.buffer).bytes,c=a+s.byteOffset,l=r(+i),h=0;h<e;h++)u[c+h]=l[o?h:e-h-1]};if(a){var K=S&&R.name!==C;if(l((function(){R(1)}))&&l((function(){new R(-1)}))&&!l((function(){return new R,new R(1.5),new R(NaN),K&&!T})))K&&T&&u(R,"name",C);else{(k=function(t){return h(this,I),new R(p(t))})[L]=I;for(var tt,et=y(R),nt=0;et.length>nt;)(tt=et[nt++])in k||u(k,tt,R[tt]);I.constructor=k}v&&g(j)!==z&&v(j,z);var rt=new D(new k(2)),it=i(j.setInt8);rt.setInt8(0,2147483648),rt.setInt8(1,2147483649),!rt.getInt8(0)&&rt.getInt8(1)||c(j,{setInt8:function(t,e){it(this,t,e<<24>>24)},setUint8:function(t,e){it(this,t,e<<24>>24)}},{unsafe:!0})}else I=(k=function(t){h(this,I);var e=p(t);A(this,{bytes:B(N(e),0),byteLength:e}),o||(this.byteLength=e)})[L],j=(D=function(t,e,n){h(this,j),h(t,I);var r=E(t).byteLength,i=f(e);if(i<0||i>r)throw F("Wrong offset");if(i+(n=void 0===n?r-i:d(n))>r)throw F("Wrong length");A(this,{buffer:t,byteLength:n,byteOffset:i}),o||(this.buffer=t,this.byteLength=n,this.byteOffset=i)})[L],o&&(X(k,"byteLength"),X(D,"buffer"),X(D,"byteLength"),X(D,"byteOffset")),c(j,{getInt8:function(t){return $(this,1,t)[0]<<24>>24},getUint8:function(t){return $(this,1,t)[0]},getInt16:function(t){var e=$(this,2,t,arguments.length>1?arguments[1]:void 0);return(e[1]<<8|e[0])<<16>>16},getUint16:function(t){var e=$(this,2,t,arguments.length>1?arguments[1]:void 0);return e[1]<<8|e[0]},getInt32:function(t){return q($(this,4,t,arguments.length>1?arguments[1]:void 0))},getUint32:function(t){return q($(this,4,t,arguments.length>1?arguments[1]:void 0))>>>0},getFloat32:function(t){return U($(this,4,t,arguments.length>1?arguments[1]:void 0),23)},getFloat64:function(t){return U($(this,8,t,arguments.length>1?arguments[1]:void 0),52)},setInt8:function(t,e){Q(this,1,t,W,e)},setUint8:function(t,e){Q(this,1,t,W,e)},setInt16:function(t,e){Q(this,2,t,V,e,arguments.length>2?arguments[2]:void 0)},setUint16:function(t,e){Q(this,2,t,V,e,arguments.length>2?arguments[2]:void 0)},setInt32:function(t,e){Q(this,4,t,Z,e,arguments.length>2?arguments[2]:void 0)},setUint32:function(t,e){Q(this,4,t,Z,e,arguments.length>2?arguments[2]:void 0)},setFloat32:function(t,e){Q(this,4,t,Y,e,arguments.length>2?arguments[2]:void 0)},setFloat64:function(t,e){Q(this,8,t,J,e,arguments.length>2?arguments[2]:void 0)}});w(k,C),w(D,P),t.exports={ArrayBuffer:k,DataView:D}},"0ffc":function(t,e,n){var r=n("081e"),i=n("9a02"),o=n("7464");t.exports=function(t,e,n){var a,s;return o&&r(a=e.constructor)&&a!==n&&i(s=a.prototype)&&s!==n.prototype&&o(t,s),t}},"119b":function(t,e,n){var r=n("4748").match(/AppleWebKit\/(\d+)\./);t.exports=!!r&&+r[1]},1262:function(t,e,n){var r=n("ca14"),i=n("3fa4"),o=n("081e"),a=n("cc43"),s=n("519f")("toStringTag"),u=r.Object,c="Arguments"==a(function(){return arguments}());t.exports=i?a:function(t){var e,n,r;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=function(t,e){try{return t[e]}catch(t){}}(e=u(t),s))?n:c?a(e):"Object"==(r=a(e))&&o(e.callee)?"Arguments":r}},"13eb":function(t,e,n){var r=n("c252");t.exports=r([].slice)},1576:function(t,e,n){var r=n("3fa4"),i=n("7219"),o=n("cdf3");r||i(Object.prototype,"toString",o,{unsafe:!0})},1579:function(t,e,n){"use strict";var r=n("e1ca").forEach,i=n("1ccf"),o=n("4762"),a=n("8e6f"),s=n("4263"),u=n("b243"),c=n("de5a"),l=n("b0d6"),h=n("4bd3"),f=n("2986"),d=n("cae7");function p(t){return Array.isArray(t)||void 0!==t.length}function m(t){if(Array.isArray(t))return t;var e=[];return r(t,(function(t){e.push(t)})),e}function g(t){return t&&1===t.nodeType}function v(t,e,n){var r=t[e];return null!=r||void 0===n?r:n}t.exports=function(t){var e;if((t=t||{}).idHandler)e={get:function(e){return t.idHandler.get(e,!0)},set:t.idHandler.set};else{var n=a(),y=s({idGenerator:n,stateHandler:h});e=y}var _=t.reporter;_||(_=u(!1===_));var x=v(t,"batchProcessor",l({reporter:_})),b={};b.callOnAdd=!!v(t,"callOnAdd",!0),b.debug=!!v(t,"debug",!1);var w,M=o(e),S=i({stateHandler:h}),T=v(t,"strategy","object"),E=v(t,"important",!1),A={reporter:_,batchProcessor:x,stateHandler:h,idHandler:e,important:E};if("scroll"===T&&(c.isLegacyOpera()?(_.warn("Scroll strategy is not supported on legacy Opera. Changing to object strategy."),T="object"):c.isIE(9)&&(_.warn("Scroll strategy is not supported on IE9. Changing to object strategy."),T="object")),"scroll"===T)w=d(A);else{if("object"!==T)throw new Error("Invalid strategy name: "+T);w=f(A)}var C={};return{listenTo:function(t,n,i){function o(t){var e=M.get(t);r(e,(function(e){e(t)}))}function a(t,e,n){M.add(e,n),t&&n(e)}if(i||(i=n,n=t,t={}),!n)throw new Error("At least one element required.");if(!i)throw new Error("Listener required.");if(g(n))n=[n];else{if(!p(n))return _.error("Invalid arguments. Must be a DOM element or a collection of DOM elements.");n=m(n)}var s=0,u=v(t,"callOnAdd",b.callOnAdd),c=v(t,"onReady",(function(){})),l=v(t,"debug",b.debug);r(n,(function(t){h.getState(t)||(h.initState(t),e.set(t));var f=e.get(t);if(l&&_.log("Attaching listener to element",f,t),!S.isDetectable(t))return l&&_.log(f,"Not detectable."),S.isBusy(t)?(l&&_.log(f,"System busy making it detectable"),a(u,t,i),C[f]=C[f]||[],void C[f].push((function(){++s===n.length&&c()}))):(l&&_.log(f,"Making detectable..."),S.markBusy(t,!0),w.makeDetectable({debug:l,important:E},t,(function(t){if(l&&_.log(f,"onElementDetectable"),h.getState(t)){S.markAsDetectable(t),S.markBusy(t,!1),w.addListener(t,o),a(u,t,i);var e=h.getState(t);if(e&&e.startSize){var d=t.offsetWidth,p=t.offsetHeight;e.startSize.width===d&&e.startSize.height===p||o(t)}C[f]&&r(C[f],(function(t){t()}))}else l&&_.log(f,"Element uninstalled before being detectable.");delete C[f],++s===n.length&&c()})));l&&_.log(f,"Already detecable, adding listener."),a(u,t,i),s++})),s===n.length&&c()},removeListener:M.removeListener,removeAllListeners:M.removeAllListeners,uninstall:function(t){if(!t)return _.error("At least one element is required.");if(g(t))t=[t];else{if(!p(t))return _.error("Invalid arguments. Must be a DOM element or a collection of DOM elements.");t=m(t)}r(t,(function(t){M.removeAllListeners(t),w.uninstall(t),h.cleanState(t)}))},initDocument:function(t){w.initDocument&&w.initDocument(t)}}}},"15fd":function(t,e,n){"use strict";var r=n("41a4"),i=n("a10c"),o=n("28dc"),a=Math.min;t.exports=[].copyWithin||function(t,e){var n=r(this),s=o(n),u=i(t,s),c=i(e,s),l=arguments.length>2?arguments[2]:void 0,h=a((void 0===l?s:i(l,s))-c,s-u),f=1;for(c<u&&u<c+h&&(f=-1,c+=h-1,u+=h-1);h-- >0;)c in n?n[u]=n[c]:delete n[u],u+=f,c+=f;return n}},1671:function(t,e,n){var r=n("93b0");r.__esModule&&(r=r.default),"string"==typeof r&&(r=[[t.i,r,""]]),r.locals&&(t.exports=r.locals),(0,n("5925").default)("dcc90e9e",r,!0,{sourceMap:!1,shadowMode:!1})},1772:function(t,e,n){var r=n("ca14"),i=n("b0c4"),o=n("41a4"),a=n("96a5"),s=n("28dc"),u=r.TypeError,c=function(t){return function(e,n,r,c){i(n);var l=o(e),h=a(l),f=s(l),d=t?f-1:0,p=t?-1:1;if(r<2)for(;;){if(d in h){c=h[d],d+=p;break}if(d+=p,t?d<0:f<=d)throw u("Reduce of empty array with no initial value")}for(;t?d>=0:f>d;d+=p)d in h&&(c=n(c,h[d],d,l));return c}};t.exports={left:c(!1),right:c(!0)}},"18aa":function(t,e,n){var r=n("ca14"),i=n("cbac"),o=n("081e"),a=n("9a02"),s=r.TypeError;t.exports=function(t,e){var n,r;if("string"===e&&o(n=t.toString)&&!a(r=i(n,t)))return r;if(o(n=t.valueOf)&&!a(r=i(n,t)))return r;if("string"!==e&&o(n=t.toString)&&!a(r=i(n,t)))return r;throw s("Can't convert object to primitive value")}},"18fd":function(t,e,n){var r=n("445a"),i=n("c7e7"),o=n("d42b"),a=n("6c01").f;t.exports=function(t){var e=r.Symbol||(r.Symbol={});i(e,t)||a(e,t,{value:o.f(t)})}},"190b":function(t,e,n){var r=n("1262"),i=n("1ffe"),o=n("db7f"),a=n("519f")("iterator");t.exports=function(t){if(null!=t)return i(t,a)||i(t,"@@iterator")||o[r(t)]}},"1a1d":function(t,e,n){"use strict";var r=n("961e"),i=n("ca14"),o=n("8e04"),a=n("6d9b"),s=n("9a02"),u=n("a10c"),c=n("28dc"),l=n("097d"),h=n("0074"),f=n("519f"),d=n("7ba8"),p=n("13eb"),m=d("slice"),g=f("species"),v=i.Array,y=Math.max;r({target:"Array",proto:!0,forced:!m},{slice:function(t,e){var n,r,i,f=l(this),d=c(f),m=u(t,d),_=u(void 0===e?d:e,d);if(o(f)&&(n=f.constructor,(a(n)&&(n===v||o(n.prototype))||s(n)&&null===(n=n[g]))&&(n=void 0),n===v||void 0===n))return p(f,m,_);for(r=new(void 0===n?v:n)(y(_-m,0)),i=0;m<_;m++,i++)m in f&&h(r,i,f[m]);return r.length=i,r}})},"1b49":function(t,e,n){var r=n("961e"),i=n("c814"),o=n("41a4"),a=n("f97a"),s=n("c813");r({target:"Object",stat:!0,forced:i((function(){a(1)})),sham:!s},{getPrototypeOf:function(t){return a(o(t))}})},"1cba":function(t,e,n){(function(e){var n="object"==typeof e&&e&&e.Object===Object&&e;t.exports=n}).call(this,n("2409"))},"1ccf":function(t,e,n){"use strict";t.exports=function(t){var e=t.stateHandler.getState;return{isDetectable:function(t){var n=e(t);return n&&!!n.isDetectable},markAsDetectable:function(t){e(t).isDetectable=!0},isBusy:function(t){return!!e(t).busy},markBusy:function(t,n){e(t).busy=!!n}}}},"1e0a":function(t,e,n){"use strict";(t.exports={}).getOption=function(t,e,n){var r=t[e];return null!=r||void 0===n?r:n}},"1ffe":function(t,e,n){var r=n("b0c4");t.exports=function(t,e){var n=t[e];return null==n?void 0:r(n)}},"204a":function(t,e,n){var r=n("961e"),i=n("41a4"),o=n("5c75");r({target:"Object",stat:!0,forced:n("c814")((function(){o(1)}))},{keys:function(t){return o(i(t))}})},"21c5":function(t,e,n){"use strict";var r=n("cbac"),i=n("3b2d"),o=n("97d8"),a=n("f4b1"),s=n("54ab"),u=n("c39c"),c=n("1ffe"),l=n("bc8b"),h=n("a7fb");i("match",(function(t,e,n){return[function(e){var n=u(this),i=null==e?void 0:c(e,t);return i?r(i,e,n):new RegExp(e)[t](s(n))},function(t){var r=o(this),i=s(t),u=n(e,r,i);if(u.done)return u.value;if(!r.global)return h(r,i);var c=r.unicode;r.lastIndex=0;for(var f,d=[],p=0;null!==(f=h(r,i));){var m=s(f[0]);d[p]=m,""===m&&(r.lastIndex=l(i,a(r.lastIndex),c)),p++}return 0===p?null:d}]}))},"22a3":function(t,e,n){"use strict";var r=n("c252"),i=n("002b"),o=r(n("15fd")),a=i.aTypedArray;(0,i.exportTypedArrayMethod)("copyWithin",(function(t,e){return o(a(this),t,e,arguments.length>2?arguments[2]:void 0)}))},"23a5":function(t,e,n){var r=n("ca14"),i=n("4799"),o=r.RangeError;t.exports=function(t){var e=i(t);if(e<0)throw o("The argument can't be less than 0");return e}},2409:function(t,e){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(t){"object"==typeof window&&(n=window)}t.exports=n},"253d":function(t,e,n){"use strict";var r=n("002b"),i=n("d796").forEach,o=r.aTypedArray;(0,r.exportTypedArrayMethod)("forEach",(function(t){i(o(this),t,arguments.length>1?arguments[1]:void 0)}))},"265d":function(t,e,n){var r=n("6446"),i=n("c7e7"),o=Function.prototype,a=r&&Object.getOwnPropertyDescriptor,s=i(o,"name"),u=s&&"something"===function(){}.name,c=s&&(!r||r&&a(o,"name").configurable);t.exports={EXISTS:s,PROPER:u,CONFIGURABLE:c}},2721:function(t,e){t.exports=function(t,e){return function(n){return t(e(n))}}},"27d1":function(t,e,n){"use strict";function r(t,e,n){n=n||2;var r,o,s,u,c,l,f,d=e&&e.length,p=d?e[0]*n:t.length,m=i(t,0,p,n,!0),g=[];if(!m||m.next===m.prev)return g;if(d&&(m=h(t,e,m,n)),t.length>80*n){r=s=t[0],o=u=t[1];for(var v=n;v<p;v+=n)(c=t[v])<r&&(r=c),(l=t[v+1])<o&&(o=l),c>s&&(s=c),l>u&&(u=l);f=0!==(f=Math.max(s-r,u-o))?1/f:0}return a(m,g,n,r,o,f),g}function i(t,e,n,r,i){var o,a;if(i===P(t,e,n,r)>0)for(o=e;o<n;o+=r)a=E(o,t[o],t[o+1],a);else for(o=n-r;o>=e;o-=r)a=E(o,t[o],t[o+1],a);return a&&x(a,a.next)&&(A(a),a=a.next),a}function o(t,e){if(!t)return t;e||(e=t);var n,r=t;do{if(n=!1,r.steiner||!x(r,r.next)&&0!==_(r.prev,r,r.next))r=r.next;else{if(A(r),(r=e=r.prev)===r.next)break;n=!0}}while(n||r!==e);return e}function a(t,e,n,r,i,h,f){if(t){!f&&h&&function(t,e,n,r){var i=t;do{null===i.z&&(i.z=m(i.x,i.y,e,n,r)),i.prevZ=i.prev,i.nextZ=i.next,i=i.next}while(i!==t);i.prevZ.nextZ=null,i.prevZ=null,function(t){var e,n,r,i,o,a,s,u,c=1;do{for(n=t,t=null,o=null,a=0;n;){for(a++,r=n,s=0,e=0;e<c&&(s++,r=r.nextZ);e++);for(u=c;s>0||u>0&&r;)0!==s&&(0===u||!r||n.z<=r.z)?(i=n,n=n.nextZ,s--):(i=r,r=r.nextZ,u--),o?o.nextZ=i:t=i,i.prevZ=o,o=i;n=r}o.nextZ=null,c*=2}while(a>1)}(i)}(t,r,i,h);for(var d,p,g=t;t.prev!==t.next;)if(d=t.prev,p=t.next,h?u(t,r,i,h):s(t))e.push(d.i/n),e.push(t.i/n),e.push(p.i/n),A(t),t=p.next,g=p.next;else if((t=p)===g){f?1===f?a(t=c(o(t),e,n),e,n,r,i,h,2):2===f&&l(t,e,n,r,i,h):a(o(t),e,n,r,i,h,1);break}}}function s(t){var e=t.prev,n=t,r=t.next;if(_(e,n,r)>=0)return!1;for(var i=t.next.next;i!==t.prev;){if(v(e.x,e.y,n.x,n.y,r.x,r.y,i.x,i.y)&&_(i.prev,i,i.next)>=0)return!1;i=i.next}return!0}function u(t,e,n,r){var i=t.prev,o=t,a=t.next;if(_(i,o,a)>=0)return!1;for(var s=i.x<o.x?i.x<a.x?i.x:a.x:o.x<a.x?o.x:a.x,u=i.y<o.y?i.y<a.y?i.y:a.y:o.y<a.y?o.y:a.y,c=i.x>o.x?i.x>a.x?i.x:a.x:o.x>a.x?o.x:a.x,l=i.y>o.y?i.y>a.y?i.y:a.y:o.y>a.y?o.y:a.y,h=m(s,u,e,n,r),f=m(c,l,e,n,r),d=t.prevZ,p=t.nextZ;d&&d.z>=h&&p&&p.z<=f;){if(d!==t.prev&&d!==t.next&&v(i.x,i.y,o.x,o.y,a.x,a.y,d.x,d.y)&&_(d.prev,d,d.next)>=0)return!1;if(d=d.prevZ,p!==t.prev&&p!==t.next&&v(i.x,i.y,o.x,o.y,a.x,a.y,p.x,p.y)&&_(p.prev,p,p.next)>=0)return!1;p=p.nextZ}for(;d&&d.z>=h;){if(d!==t.prev&&d!==t.next&&v(i.x,i.y,o.x,o.y,a.x,a.y,d.x,d.y)&&_(d.prev,d,d.next)>=0)return!1;d=d.prevZ}for(;p&&p.z<=f;){if(p!==t.prev&&p!==t.next&&v(i.x,i.y,o.x,o.y,a.x,a.y,p.x,p.y)&&_(p.prev,p,p.next)>=0)return!1;p=p.nextZ}return!0}function c(t,e,n){var r=t;do{var i=r.prev,a=r.next.next;!x(i,a)&&b(i,r,r.next,a)&&S(i,a)&&S(a,i)&&(e.push(i.i/n),e.push(r.i/n),e.push(a.i/n),A(r),A(r.next),r=t=a),r=r.next}while(r!==t);return o(r)}function l(t,e,n,r,i,s){var u=t;do{for(var c=u.next.next;c!==u.prev;){if(u.i!==c.i&&y(u,c)){var l=T(u,c);return u=o(u,u.next),l=o(l,l.next),a(u,e,n,r,i,s),void a(l,e,n,r,i,s)}c=c.next}u=u.next}while(u!==t)}function h(t,e,n,r){var a,s,u,c=[];for(a=0,s=e.length;a<s;a++)(u=i(t,e[a]*r,a<s-1?e[a+1]*r:t.length,r,!1))===u.next&&(u.steiner=!0),c.push(g(u));for(c.sort(f),a=0;a<c.length;a++)n=o(n=d(c[a],n),n.next);return n}function f(t,e){return t.x-e.x}function d(t,e){var n=function(t,e){var n,r=e,i=t.x,o=t.y,a=-1/0;do{if(o<=r.y&&o>=r.next.y&&r.next.y!==r.y){var s=r.x+(o-r.y)*(r.next.x-r.x)/(r.next.y-r.y);if(s<=i&&s>a){if(a=s,s===i){if(o===r.y)return r;if(o===r.next.y)return r.next}n=r.x<r.next.x?r:r.next}}r=r.next}while(r!==e);if(!n)return null;if(i===a)return n;var u,c=n,l=n.x,h=n.y,f=1/0;r=n;do{i>=r.x&&r.x>=l&&i!==r.x&&v(o<h?i:a,o,l,h,o<h?a:i,o,r.x,r.y)&&(u=Math.abs(o-r.y)/(i-r.x),S(r,t)&&(u<f||u===f&&(r.x>n.x||r.x===n.x&&p(n,r)))&&(n=r,f=u)),r=r.next}while(r!==c);return n}(t,e);if(!n)return e;var r=T(n,t),i=o(n,n.next);return o(r,r.next),e===n?i:e}function p(t,e){return _(t.prev,t,e.prev)<0&&_(e.next,t,t.next)<0}function m(t,e,n,r,i){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=32767*(t-n)*i)|t<<8))|t<<4))|t<<2))|t<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=32767*(e-r)*i)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function g(t){var e=t,n=t;do{(e.x<n.x||e.x===n.x&&e.y<n.y)&&(n=e),e=e.next}while(e!==t);return n}function v(t,e,n,r,i,o,a,s){return(i-a)*(e-s)-(t-a)*(o-s)>=0&&(t-a)*(r-s)-(n-a)*(e-s)>=0&&(n-a)*(o-s)-(i-a)*(r-s)>=0}function y(t,e){return t.next.i!==e.i&&t.prev.i!==e.i&&!function(t,e){var n=t;do{if(n.i!==t.i&&n.next.i!==t.i&&n.i!==e.i&&n.next.i!==e.i&&b(n,n.next,t,e))return!0;n=n.next}while(n!==t);return!1}(t,e)&&(S(t,e)&&S(e,t)&&function(t,e){var n=t,r=!1,i=(t.x+e.x)/2,o=(t.y+e.y)/2;do{n.y>o!=n.next.y>o&&n.next.y!==n.y&&i<(n.next.x-n.x)*(o-n.y)/(n.next.y-n.y)+n.x&&(r=!r),n=n.next}while(n!==t);return r}(t,e)&&(_(t.prev,t,e.prev)||_(t,e.prev,e))||x(t,e)&&_(t.prev,t,t.next)>0&&_(e.prev,e,e.next)>0)}function _(t,e,n){return(e.y-t.y)*(n.x-e.x)-(e.x-t.x)*(n.y-e.y)}function x(t,e){return t.x===e.x&&t.y===e.y}function b(t,e,n,r){var i=M(_(t,e,n)),o=M(_(t,e,r)),a=M(_(n,r,t)),s=M(_(n,r,e));return i!==o&&a!==s||!(0!==i||!w(t,n,e))||!(0!==o||!w(t,r,e))||!(0!==a||!w(n,t,r))||!(0!==s||!w(n,e,r))}function w(t,e,n){return e.x<=Math.max(t.x,n.x)&&e.x>=Math.min(t.x,n.x)&&e.y<=Math.max(t.y,n.y)&&e.y>=Math.min(t.y,n.y)}function M(t){return t>0?1:t<0?-1:0}function S(t,e){return _(t.prev,t,t.next)<0?_(t,e,t.next)>=0&&_(t,t.prev,e)>=0:_(t,e,t.prev)<0||_(t,t.next,e)<0}function T(t,e){var n=new C(t.i,t.x,t.y),r=new C(e.i,e.x,e.y),i=t.next,o=e.prev;return t.next=e,e.prev=t,n.next=i,i.prev=n,r.next=n,n.prev=r,o.next=r,r.prev=o,r}function E(t,e,n,r){var i=new C(t,e,n);return r?(i.next=r.next,i.prev=r,r.next.prev=i,r.next=i):(i.prev=i,i.next=i),i}function A(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function C(t,e,n){this.i=t,this.x=e,this.y=n,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function P(t,e,n,r){for(var i=0,o=e,a=n-r;o<n;o+=r)i+=(t[a]-t[o])*(t[o+1]+t[a+1]),a=o;return i}t.exports=r,t.exports.default=r,r.deviation=function(t,e,n,r){var i=e&&e.length,o=i?e[0]*n:t.length,a=Math.abs(P(t,0,o,n));if(i)for(var s=0,u=e.length;s<u;s++){var c=e[s]*n,l=s<u-1?e[s+1]*n:t.length;a-=Math.abs(P(t,c,l,n))}var h=0;for(s=0;s<r.length;s+=3){var f=r[s]*n,d=r[s+1]*n,p=r[s+2]*n;h+=Math.abs((t[f]-t[p])*(t[d+1]-t[f+1])-(t[f]-t[d])*(t[p+1]-t[f+1]))}return 0===a&&0===h?0:Math.abs((h-a)/a)},r.flatten=function(t){for(var e=t[0][0].length,n={vertices:[],holes:[],dimensions:e},r=0,i=0;i<t.length;i++){for(var o=0;o<t[i].length;o++)for(var a=0;a<e;a++)n.vertices.push(t[i][o][a]);i>0&&(r+=t[i-1].length,n.holes.push(r))}return n}},"28dc":function(t,e,n){var r=n("f4b1");t.exports=function(t){return r(t.length)}},2946:function(t,e,n){var r=n("ca14"),i=n("081e"),o=r.String,a=r.TypeError;t.exports=function(t){if("object"==typeof t||i(t))return t;throw a("Can't set "+o(t)+" as a prototype")}},2985:function(t,e,n){"use strict";var r=n("002b"),i=n("61a6"),o=n("f5d8"),a=r.aTypedArray;(0,r.exportTypedArrayMethod)("lastIndexOf",(function(t){var e=arguments.length;return i(o,a(this),e>1?[t,arguments[1]]:[t])}))},2986:function(t,e,n){"use strict";var r=n("de5a");t.exports=function(t){var e=(t=t||{}).reporter,n=t.batchProcessor,i=t.stateHandler.getState;if(!e)throw new Error("Missing required dependency: reporter.");function o(e){var n=t.important?" !important; ":"; ";return(e.join(n)+n).trim()}function a(t){return i(t).object}return{makeDetectable:function(t,a,s){s||(s=a,a=t,t=null),(t=t||{}).debug,r.isIE(8)?s(a):function(a,s){var u=o(["display: block","position: absolute","top: 0","left: 0","width: 100%","height: 100%","border: none","padding: 0","margin: 0","opacity: 0","z-index: -1000","pointer-events: none"]),c=!1,l=window.getComputedStyle(a),h=a.offsetWidth,f=a.offsetHeight;function d(){function n(){if("static"===l.position){a.style.setProperty("position","relative",t.important?"important":"");var n=function(e,n,r,i){var o=r[i];"auto"!==o&&"0"!==function(t){return t.replace(/[^-\d\.]/g,"")}(o)&&(e.warn("An element that is positioned static has style."+i+"="+o+" which is ignored due to the static positioning. The element will need to be positioned relative, so the style."+i+" will be set to 0. Element: ",n),n.style.setProperty(i,"0",t.important?"important":""))};n(e,a,l,"top"),n(e,a,l,"right"),n(e,a,l,"bottom"),n(e,a,l,"left")}}""!==l.position&&(n(),c=!0);var o=document.createElement("object");o.style.cssText=u,o.tabIndex=-1,o.type="text/html",o.setAttribute("aria-hidden","true"),o.onload=function(){c||n(),function t(e,n){if(!e.contentDocument){var r=i(e);return r.checkForObjectDocumentTimeoutId&&window.clearTimeout(r.checkForObjectDocumentTimeoutId),void(r.checkForObjectDocumentTimeoutId=setTimeout((function(){r.checkForObjectDocumentTimeoutId=0,t(e,n)}),100))}n(e.contentDocument)}(this,(function(t){s(a)}))},r.isIE()||(o.data="about:blank"),i(a)&&(a.appendChild(o),i(a).object=o,r.isIE()&&(o.data="about:blank"))}i(a).startSize={width:h,height:f},n?n.add(d):d()}(a,s)},addListener:function(t,e){function n(){e(t)}if(r.isIE(8))i(t).object={proxy:n},t.attachEvent("onresize",n);else{var o=a(t);if(!o)throw new Error("Element is not detectable by this strategy.");o.contentDocument.defaultView.addEventListener("resize",n)}},uninstall:function(t){if(i(t)){var e=a(t);e&&(r.isIE(8)?t.detachEvent("onresize",e.proxy):t.removeChild(e),i(t).checkForObjectDocumentTimeoutId&&window.clearTimeout(i(t).checkForObjectDocumentTimeoutId),delete i(t).object)}}}}},"29f7":function(t,e,n){var r=n("961e"),i=n("c814"),o=n("097d"),a=n("064b").f,s=n("6446"),u=i((function(){a(1)}));r({target:"Object",stat:!0,forced:!s||u,sham:!s},{getOwnPropertyDescriptor:function(t,e){return a(o(t),e)}})},"29fd":function(t,e,n){var r=n("961e"),i=n("d45e"),o=n("61a6"),a=n("bd0a"),s=n("d7ed"),u=n("97d8"),c=n("9a02"),l=n("a30f"),h=n("c814"),f=i("Reflect","construct"),d=Object.prototype,p=[].push,m=h((function(){function t(){}return!(f((function(){}),[],t)instanceof t)})),g=!h((function(){f((function(){}))})),v=m||g;r({target:"Reflect",stat:!0,forced:v,sham:v},{construct:function(t,e){s(t),u(e);var n=arguments.length<3?t:s(arguments[2]);if(g&&!m)return f(t,e,n);if(t==n){switch(e.length){case 0:return new t;case 1:return new t(e[0]);case 2:return new t(e[0],e[1]);case 3:return new t(e[0],e[1],e[2]);case 4:return new t(e[0],e[1],e[2],e[3])}var r=[null];return o(p,r,e),new(o(a,t,r))}var i=n.prototype,h=l(c(i)?i:d),v=o(t,h,e);return c(v)?v:h}})},"2a67":function(t,e,n){var r=n("4748");t.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(r)},"2a97":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAKCAYAAABSfLWiAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA3ZpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDE0IDc5LjE1MTQ4MSwgMjAxMy8wMy8xMy0xMjowOToxNSAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDoxY2VjNGU4ZS1iOGY2LTliNGQtOTI4Ny00NDllN2M2NDNlOTQiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6MkI4MDFBOTY3RTk2MTFFODhENTE4NERCOTYxNjg4MjUiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6MkI4MDFBOTU3RTk2MTFFODhENTE4NERCOTYxNjg4MjUiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTQgKFdpbmRvd3MpIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6MWNlYzRlOGUtYjhmNi05YjRkLTkyODctNDQ5ZTdjNjQzZTk0IiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOjFjZWM0ZThlLWI4ZjYtOWI0ZC05Mjg3LTQ0OWU3YzY0M2U5NCIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PmUmXhQAAADFSURBVHjaYshKSpK/fOnS1/9kgNOnTr1KT0+XZgCBmsrKsJcvX5JkwJUrV/7k5OTYMiCDCRMm9P/48YMoA27duvWvuLjYmwELYFy0aNERQgY8evTof111dSQDLhASEsK5a+fO57gMePHixf/6+voMBkIgLS1N7tKlSz/RDXj37t3/zvb2KgZiQWNjozvIVhj49OnT/97u7m4GUsH0qVPrvn///h+EJ0+YMJeBXLBkyZItM6dNW8tACbC3t2cBxRohdQABBgAt8yx0KlQQZgAAAABJRU5ErkJggg=="},"2aa5":function(t,e,n){var r=n("c252"),i=n("4799"),o=n("54ab"),a=n("c39c"),s=r("".charAt),u=r("".charCodeAt),c=r("".slice),l=function(t){return function(e,n){var r,l,h=o(a(e)),f=i(n),d=h.length;return f<0||f>=d?t?"":void 0:(r=u(h,f))<55296||r>56319||f+1===d||(l=u(h,f+1))<56320||l>57343?t?s(h,f):r:t?c(h,f,f+2):l-56320+(r-55296<<10)+65536}};t.exports={codeAt:l(!1),charAt:l(!0)}},"2b26":function(t,e,n){var r=n("519f")("match");t.exports=function(t){var e=/./;try{"/./"[t](e)}catch(n){try{return e[r]=!1,"/./"[t](e)}catch(t){}}return!1}},"2ccb":function(t,e,n){var r=n("c4ae")("span").classList,i=r&&r.constructor&&r.constructor.prototype;t.exports=i===Object.prototype?void 0:i},"2cdc":function(t,e,n){"use strict";var r=n("002b"),i=n("d796").find,o=r.aTypedArray;(0,r.exportTypedArrayMethod)("find",(function(t){return i(o(this),t,arguments.length>1?arguments[1]:void 0)}))},"2d18":function(t,e,n){var r=n("9a1e"),i=Math.floor,o=function(t,e){var n=t.length,u=i(n/2);return n<8?a(t,e):s(t,o(r(t,0,u),e),o(r(t,u),e),e)},a=function(t,e){for(var n,r,i=t.length,o=1;o<i;){for(r=o,n=t[o];r&&e(t[r-1],n)>0;)t[r]=t[--r];r!==o++&&(t[r]=n)}return t},s=function(t,e,n,r){for(var i=e.length,o=n.length,a=0,s=0;a<i||s<o;)t[a+s]=a<i&&s<o?r(e[a],n[s])<=0?e[a++]:n[s++]:a<i?e[a++]:n[s++];return t};t.exports=o},"2ed2":function(t,e,n){var r=n("dc9b"),i=n("f227"),o=n("d92c"),a=Function.prototype,s=Object.prototype,u=a.toString,c=s.hasOwnProperty,l=u.call(Object);t.exports=function(t){if(!o(t)||"[object Object]"!=r(t))return!1;var e=i(t);if(null===e)return!0;var n=c.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&u.call(n)==l}},"2f36":function(t,e,n){"use strict";var r=n("ca14"),i=n("002b"),o=n("28dc"),a=n("7958"),s=n("41a4"),u=n("c814"),c=r.RangeError,l=i.aTypedArray;(0,i.exportTypedArrayMethod)("set",(function(t){l(this);var e=a(arguments.length>1?arguments[1]:void 0,1),n=this.length,r=s(t),i=o(r),u=0;if(i+e>n)throw c("Wrong length");for(;u<i;)this[e+u]=r[u++]}),u((function(){new Int8Array(1).set({})})))},3223:function(t,e,n){var r=n("9a02"),i=Math.floor;t.exports=Number.isInteger||function(t){return!r(t)&&isFinite(t)&&i(t)===t}},3355:function(t,e,n){"use strict";var r=n("002b"),i=n("ee4f").indexOf,o=r.aTypedArray;(0,r.exportTypedArrayMethod)("indexOf",(function(t){return i(o(this),t,arguments.length>1?arguments[1]:void 0)}))},3471:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAKCAYAAABSfLWiAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA3ZpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDE0IDc5LjE1MTQ4MSwgMjAxMy8wMy8xMy0xMjowOToxNSAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDo0NTE4ZWRhOC03NjQ5LTNjNGUtYjYxZi0xNjVhZmQzNmJmMzciIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6MUJCN0UxQjY3RTk2MTFFOEFCNzVFRTYzMkFGMUE2MUIiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6MUJCN0UxQjU3RTk2MTFFOEFCNzVFRTYzMkFGMUE2MUIiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTQgKFdpbmRvd3MpIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6NDUxOGVkYTgtNzY0OS0zYzRlLWI2MWYtMTY1YWZkMzZiZjM3IiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOjQ1MThlZGE4LTc2NDktM2M0ZS1iNjFmLTE2NWFmZDM2YmYzNyIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/Pvm07Z8AAADSSURBVHjaYvj//z8DPswIBI6Ojiz41LAwEAAzpk1bw83Lyw5k+uBUhM+GyRMnzv3+/ft/EJ4+dWodLnU4Dejr6en+9OnTfxh48eLF/6amJneiDelsb6969+7df3Rw+fLln+np6XIEDWloaMgA2YoL7N6163lYWBgnTkPqa2oiHz169J8QWLx48RFQrGEYUlpa6n379u1//4kAP378+D9xwoR+FEPy8vJsr1y58uc/CeDly5f/66qrw8CGZGZmSp85ffrVfzLA5UuXvuakpMgDBBgAQbLv2dsvRWYAAAAASUVORK5CYII="},3477:function(t,e,n){"use strict";var r=n("002b"),i=n("d796").filter,o=n("e2c0"),a=r.aTypedArray;(0,r.exportTypedArrayMethod)("filter",(function(t){var e=i(a(this),t,arguments.length>1?arguments[1]:void 0);return o(this,e)}))},3492:function(t,e,n){var r=n("4748").match(/firefox\/(\d+)/i);t.exports=!!r&&+r[1]},"34bc":function(t,e,n){var r=n("9153"),i=n("efd9");(t.exports=function(t,e){return i[t]||(i[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.19.2",mode:r?"pure":"global",copyright:"© 2021 Denis Pushkarev (zloirock.ru)"})},"350f":function(t,e,n){var r=n("ca14");t.exports=function(t,e){var n=r.console;n&&n.error&&(1==arguments.length?n.error(t):n.error(t,e))}},3552:function(t,e){t.exports={name:"memoryStorage",read:function(t){return n[t]},write:function(t,e){n[t]=e},each:function(t){for(var e in n)n.hasOwnProperty(e)&&t(n[e],e)},remove:function(t){delete n[t]},clearAll:function(t){n={}}};var n={}},3708:function(t,e,n){var r=n("c814"),i=n("ca14").RegExp;t.exports=r((function(){var t=i(".","s");return!(t.dotAll&&t.exec("\n")&&"s"===t.flags)}))},"39ec":function(t,e,n){"use strict";var r=n("002b"),i=n("f4b1"),o=n("a10c"),a=n("d9c2"),s=r.aTypedArray;(0,r.exportTypedArrayMethod)("subarray",(function(t,e){var n=s(this),r=n.length,u=o(t,r);return new(a(n))(n.buffer,n.byteOffset+u*n.BYTES_PER_ELEMENT,i((void 0===e?r:o(e,r))-u))}))},"3a40":function(t,e,n){(function(e){var n=Object.assign?Object.assign:function(t,e,n,r){for(var i=1;i<arguments.length;i++)s(Object(arguments[i]),(function(e,n){t[n]=e}));return t},r=function(){if(Object.create)return function(t,e,r,i){var o=a(arguments,1);return n.apply(this,[Object.create(t)].concat(o))};{function t(){}return function(e,r,i,o){var s=a(arguments,1);return t.prototype=e,n.apply(this,[new t].concat(s))}}}(),i=String.prototype.trim?function(t){return String.prototype.trim.call(t)}:function(t){return t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")},o="undefined"!=typeof window?window:e;function a(t,e){return Array.prototype.slice.call(t,e||0)}function s(t,e){u(t,(function(t,n){return e(t,n),!1}))}function u(t,e){if(c(t)){for(var n=0;n<t.length;n++)if(e(t[n],n))return t[n]}else for(var r in t)if(t.hasOwnProperty(r)&&e(t[r],r))return t[r]}function c(t){return null!=t&&"function"!=typeof t&&"number"==typeof t.length}t.exports={assign:n,create:r,trim:i,bind:function(t,e){return function(){return e.apply(t,Array.prototype.slice.call(arguments,0))}},slice:a,each:s,map:function(t,e){var n=c(t)?[]:{};return u(t,(function(t,r){return n[r]=e(t,r),!1})),n},pluck:u,isList:c,isFunction:function(t){return t&&"[object Function]"==={}.toString.call(t)},isObject:function(t){return t&&"[object Object]"==={}.toString.call(t)},Global:o}}).call(this,n("2409"))},"3ac5":function(t,e,n){var r=n("3a40").Global;t.exports={name:"oldIE-userDataStorage",write:function(t,e){if(!s){var n=c(t);a((function(t){t.setAttribute(n,e),t.save(i)}))}},read:function(t){if(!s){var e=c(t),n=null;return a((function(t){n=t.getAttribute(e)})),n}},each:function(t){a((function(e){for(var n=e.XMLDocument.documentElement.attributes,r=n.length-1;r>=0;r--){var i=n[r];t(e.getAttribute(i.name),i.name)}}))},remove:function(t){var e=c(t);a((function(t){t.removeAttribute(e),t.save(i)}))},clearAll:function(){a((function(t){var e=t.XMLDocument.documentElement.attributes;t.load(i);for(var n=e.length-1;n>=0;n--)t.removeAttribute(e[n].name);t.save(i)}))}};var i="storejs",o=r.document,a=function(){if(!o||!o.documentElement||!o.documentElement.addBehavior)return null;var t,e,n;try{(e=new ActiveXObject("htmlfile")).open(),e.write('<script>document.w=window<\/script><iframe src="/favicon.ico"></iframe>'),e.close(),t=e.w.frames[0].document,n=t.createElement("div")}catch(e){n=o.createElement("div"),t=o.body}return function(e){var r=[].slice.call(arguments,0);r.unshift(n),t.appendChild(n),n.addBehavior("#default#userData"),n.load(i),e.apply(this,r),t.removeChild(n)}}(),s=(r.navigator?r.navigator.userAgent:"").match(/ (MSIE 8|MSIE 9|MSIE 10)\./),u=new RegExp("[!\"#$%&'()*+,/\\\\:;<=>?@[\\]^`{|}~]","g");function c(t){return t.replace(/^\d/,"___$&").replace(u,"___")}},"3b2d":function(t,e,n){"use strict";n("bb4d");var r=n("c252"),i=n("7219"),o=n("466a"),a=n("c814"),s=n("519f"),u=n("d3a9"),c=s("species"),l=RegExp.prototype;t.exports=function(t,e,n,h){var f=s(t),d=!a((function(){var e={};return e[f]=function(){return 7},7!=""[t](e)})),p=d&&!a((function(){var e=!1,n=/a/;return"split"===t&&((n={}).constructor={},n.constructor[c]=function(){return n},n.flags="",n[f]=/./[f]),n.exec=function(){return e=!0,null},n[f](""),!e}));if(!d||!p||n){var m=r(/./[f]),g=e(f,""[t],(function(t,e,n,i,a){var s=r(t),u=e.exec;return u===o||u===l.exec?d&&!a?{done:!0,value:m(e,n,i)}:{done:!0,value:s(n,e,i)}:{done:!1}}));i(String.prototype,t,g[0]),i(l,f,g[1])}h&&u(l[f],"sham",!0)}},"3e94":function(t,e,n){var r=n("a434"),i=n("62b4");t.exports=function(t){var e=r(t,"string");return i(e)?e:e+""}},"3fa4":function(t,e,n){var r={};r[n("519f")("toStringTag")]="z",t.exports="[object z]"===String(r)},"412f":function(t,e,n){"use strict";var r,i,o,a,s=n("961e"),u=n("9153"),c=n("ca14"),l=n("d45e"),h=n("cbac"),f=n("6326"),d=n("7219"),p=n("f0f8"),m=n("7464"),g=n("9207"),v=n("c60e"),y=n("b0c4"),_=n("081e"),x=n("9a02"),b=n("c3f4"),w=n("4f29"),M=n("44a8"),S=n("6566"),T=n("baf4"),E=n("675d").set,A=n("ebba"),C=n("5b0d"),P=n("350f"),L=n("8088"),O=n("f1d5"),R=n("e13b"),k=n("a3e2"),I=n("519f"),D=n("57c6"),j=n("801d"),z=n("a0a0"),N=I("species"),F="Promise",B=R.get,H=R.set,G=R.getterFor(F),U=f&&f.prototype,W=f,V=U,Z=c.TypeError,q=c.document,Y=c.process,J=L.f,X=J,$=!!(q&&q.createEvent&&c.dispatchEvent),Q=_(c.PromiseRejectionEvent),K="unhandledrejection",tt=!1,et=k(F,(function(){var t=w(W),e=t!==String(W);if(!e&&66===z)return!0;if(u&&!V.finally)return!0;if(z>=51&&/native code/.test(t))return!1;var n=new W((function(t){t(1)})),r=function(t){t((function(){}),(function(){}))};return(n.constructor={})[N]=r,!(tt=n.then((function(){}))instanceof r)||!e&&D&&!Q})),nt=et||!S((function(t){W.all(t).catch((function(){}))})),rt=function(t){var e;return!(!x(t)||!_(e=t.then))&&e},it=function(t,e){if(!t.notified){t.notified=!0;var n=t.reactions;A((function(){for(var r=t.value,i=1==t.state,o=0;n.length>o;){var a,s,u,c=n[o++],l=i?c.ok:c.fail,f=c.resolve,d=c.reject,p=c.domain;try{l?(i||(2===t.rejection&&ut(t),t.rejection=1),!0===l?a=r:(p&&p.enter(),a=l(r),p&&(p.exit(),u=!0)),a===c.promise?d(Z("Promise-chain cycle")):(s=rt(a))?h(s,a,f,d):f(a)):d(r)}catch(t){p&&!u&&p.exit(),d(t)}}t.reactions=[],t.notified=!1,e&&!t.rejection&&at(t)}))}},ot=function(t,e,n){var r,i;$?((r=q.createEvent("Event")).promise=e,r.reason=n,r.initEvent(t,!1,!0),c.dispatchEvent(r)):r={promise:e,reason:n},!Q&&(i=c["on"+t])?i(r):t===K&&P("Unhandled promise rejection",n)},at=function(t){h(E,c,(function(){var e,n=t.facade,r=t.value;if(st(t)&&(e=O((function(){j?Y.emit("unhandledRejection",r,n):ot(K,n,r)})),t.rejection=j||st(t)?2:1,e.error))throw e.value}))},st=function(t){return 1!==t.rejection&&!t.parent},ut=function(t){h(E,c,(function(){var e=t.facade;j?Y.emit("rejectionHandled",e):ot("rejectionhandled",e,t.value)}))},ct=function(t,e,n){return function(r){t(e,r,n)}},lt=function(t,e,n){t.done||(t.done=!0,n&&(t=n),t.value=e,t.state=2,it(t,!0))},ht=function(t,e,n){if(!t.done){t.done=!0,n&&(t=n);try{if(t.facade===e)throw Z("Promise can't be resolved itself");var r=rt(e);r?A((function(){var n={done:!1};try{h(r,e,ct(ht,n,t),ct(lt,n,t))}catch(e){lt(n,e,t)}})):(t.value=e,t.state=1,it(t,!1))}catch(e){lt({done:!1},e,t)}}};if(et&&(V=(W=function(t){b(this,V),y(t),h(r,this);var e=B(this);try{t(ct(ht,e),ct(lt,e))}catch(t){lt(e,t)}}).prototype,(r=function(t){H(this,{type:F,done:!1,notified:!1,parent:!1,reactions:[],rejection:!1,state:0,value:void 0})}).prototype=p(V,{then:function(t,e){var n=G(this),r=n.reactions,i=J(T(this,W));return i.ok=!_(t)||t,i.fail=_(e)&&e,i.domain=j?Y.domain:void 0,n.parent=!0,r[r.length]=i,0!=n.state&&it(n,!1),i.promise},catch:function(t){return this.then(void 0,t)}}),i=function(){var t=new r,e=B(t);this.promise=t,this.resolve=ct(ht,e),this.reject=ct(lt,e)},L.f=J=function(t){return t===W||t===o?new i(t):X(t)},!u&&_(f)&&U!==Object.prototype)){a=U.then,tt||(d(U,"then",(function(t,e){var n=this;return new W((function(t,e){h(a,n,t,e)})).then(t,e)}),{unsafe:!0}),d(U,"catch",V.catch,{unsafe:!0}));try{delete U.constructor}catch(t){}m&&m(U,V)}s({global:!0,wrap:!0,forced:et},{Promise:W}),g(W,F,!1,!0),v(F),o=l(F),s({target:F,stat:!0,forced:et},{reject:function(t){var e=J(this);return h(e.reject,void 0,t),e.promise}}),s({target:F,stat:!0,forced:u||et},{resolve:function(t){return C(u&&this===o?W:this,t)}}),s({target:F,stat:!0,forced:nt},{all:function(t){var e=this,n=J(e),r=n.resolve,i=n.reject,o=O((function(){var n=y(e.resolve),o=[],a=0,s=1;M(t,(function(t){var u=a++,c=!1;s++,h(n,e,t).then((function(t){c||(c=!0,o[u]=t,--s||r(o))}),i)})),--s||r(o)}));return o.error&&i(o.value),n.promise},race:function(t){var e=this,n=J(e),r=n.reject,i=O((function(){var i=y(e.resolve);M(t,(function(t){h(i,e,t).then(n.resolve,r)}))}));return i.error&&r(i.value),n.promise}})},"41a4":function(t,e,n){var r=n("ca14"),i=n("c39c"),o=r.Object;t.exports=function(t){return o(i(t))}},4263:function(t,e,n){"use strict";t.exports=function(t){var e=t.idGenerator,n=t.stateHandler.getState;return{get:function(t){var e=n(t);return e&&void 0!==e.id?e.id:null},set:function(t){var r=n(t);if(!r)throw new Error("setId required the element to have a resize detection state.");var i=e.generate();return r.id=i,i}}}},"433e":function(t,e,n){var r=n("dbce");t.exports=function(t,e){return new(r(t))(0===e?0:e)}},"445a":function(t,e,n){var r=n("ca14");t.exports=r},"44a8":function(t,e,n){var r=n("ca14"),i=n("ad0f"),o=n("cbac"),a=n("97d8"),s=n("82b8"),u=n("bfea"),c=n("28dc"),l=n("afdf"),h=n("a42a"),f=n("190b"),d=n("47fa"),p=r.TypeError,m=function(t,e){this.stopped=t,this.result=e},g=m.prototype;t.exports=function(t,e,n){var r,v,y,_,x,b,w,M=n&&n.that,S=!(!n||!n.AS_ENTRIES),T=!(!n||!n.IS_ITERATOR),E=!(!n||!n.INTERRUPTED),A=i(e,M),C=function(t){return r&&d(r,"normal",t),new m(!0,t)},P=function(t){return S?(a(t),E?A(t[0],t[1],C):A(t[0],t[1])):E?A(t,C):A(t)};if(T)r=t;else{if(!(v=f(t)))throw p(s(t)+" is not iterable");if(u(v)){for(y=0,_=c(t);_>y;y++)if((x=P(t[y]))&&l(g,x))return x;return new m(!1)}r=h(t,v)}for(b=r.next;!(w=o(b,r)).done;){try{x=P(w.value)}catch(t){d(r,"throw",t)}if("object"==typeof x&&x&&l(g,x))return x}return new m(!1)}},"466a":function(t,e,n){"use strict";var r=n("cbac"),i=n("c252"),o=n("54ab"),a=n("ab58"),s=n("54b9"),u=n("34bc"),c=n("a30f"),l=n("e13b").get,h=n("3708"),f=n("6346"),d=u("native-string-replace",String.prototype.replace),p=RegExp.prototype.exec,m=p,g=i("".charAt),v=i("".indexOf),y=i("".replace),_=i("".slice),x=function(){var t=/a/,e=/b*/g;return r(p,t,"a"),r(p,e,"a"),0!==t.lastIndex||0!==e.lastIndex}(),b=s.BROKEN_CARET,w=void 0!==/()??/.exec("")[1];(x||w||b||h||f)&&(m=function(t){var e,n,i,s,u,h,f,M=this,S=l(M),T=o(t),E=S.raw;if(E)return E.lastIndex=M.lastIndex,e=r(m,E,T),M.lastIndex=E.lastIndex,e;var A=S.groups,C=b&&M.sticky,P=r(a,M),L=M.source,O=0,R=T;if(C&&(P=y(P,"y",""),-1===v(P,"g")&&(P+="g"),R=_(T,M.lastIndex),M.lastIndex>0&&(!M.multiline||M.multiline&&"\n"!==g(T,M.lastIndex-1))&&(L="(?: "+L+")",R=" "+R,O++),n=new RegExp("^(?:"+L+")",P)),w&&(n=new RegExp("^"+L+"$(?!\\s)",P)),x&&(i=M.lastIndex),s=r(p,C?n:M,R),C?s?(s.input=_(s.input,O),s[0]=_(s[0],O),s.index=M.lastIndex,M.lastIndex+=s[0].length):M.lastIndex=0:x&&s&&(M.lastIndex=M.global?s.index+s[0].length:i),w&&s&&s.length>1&&r(d,s[0],n,(function(){for(u=1;u<arguments.length-2;u++)void 0===arguments[u]&&(s[u]=void 0)})),s&&A)for(s.groups=h=c(null),u=0;u<A.length;u++)h[(f=A[u])[0]]=s[f[1]];return s}),t.exports=m},4704:function(t,e,n){var r=n("c252"),i=n("c7e7"),o=n("097d"),a=n("ee4f").indexOf,s=n("f448"),u=r([].push);t.exports=function(t,e){var n,r=o(t),c=0,l=[];for(n in r)!i(s,n)&&i(r,n)&&u(l,n);for(;e.length>c;)i(r,n=e[c++])&&(~a(l,n)||u(l,n));return l}},4748:function(t,e,n){var r=n("d45e");t.exports=r("navigator","userAgent")||""},4762:function(t,e,n){"use strict";t.exports=function(t){var e={};function n(n){var r=t.get(n);return void 0===r?[]:e[r]||[]}return{get:n,add:function(n,r){var i=t.get(n);e[i]||(e[i]=[]),e[i].push(r)},removeListener:function(t,e){for(var r=n(t),i=0,o=r.length;i<o;++i)if(r[i]===e){r.splice(i,1);break}},removeAllListeners:function(t){var e=n(t);e&&(e.length=0)}}}},4799:function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){var e=+t;return e!=e||0===e?0:(e>0?r:n)(e)}},"47fa":function(t,e,n){var r=n("cbac"),i=n("97d8"),o=n("1ffe");t.exports=function(t,e,n){var a,s;i(t);try{if(!(a=o(t,"return"))){if("throw"===e)throw n;return n}a=r(a,t)}catch(t){s=!0,a=t}if("throw"===e)throw n;if(s)throw a;return i(a),n}},"4b1a":function(t,e,n){var r=n("d45e"),i=n("c252"),o=n("9cd9"),a=n("b2e9"),s=n("97d8"),u=i([].concat);t.exports=r("Reflect","ownKeys")||function(t){var e=o.f(s(t)),n=a.f;return n?u(e,n(t)):e}},"4bd3":function(t,e,n){"use strict";var r="_erd";function i(t){return t[r]}t.exports={initState:function(t){return t[r]={},i(t)},getState:i,cleanState:function(t){delete t[r]}}},"4ecc":function(t,e,n){"use strict";var r=n("961e"),i=n("d796").filter;r({target:"Array",proto:!0,forced:!n("7ba8")("filter")},{filter:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}})},"4f29":function(t,e,n){var r=n("c252"),i=n("081e"),o=n("efd9"),a=r(Function.toString);i(o.inspectSource)||(o.inspectSource=function(t){return a(t)}),t.exports=o.inspectSource},"4f80":function(t,e,n){"use strict";var r=n("002b"),i=r.aTypedArray,o=r.exportTypedArrayMethod,a=Math.floor;o("reverse",(function(){for(var t,e=this,n=i(e).length,r=a(n/2),o=0;o<r;)t=e[o],e[o++]=e[--n],e[n]=t;return e}))},"4fdb":function(t,e,n){var r=n("961e"),i=n("ca14"),o=n("9207");r({global:!0},{Reflect:{}}),o(i.Reflect,"Reflect",!0)},"50cc":function(t,e,n){"use strict";var r=n("961e"),i=n("ca14"),o=n("cbac"),a=n("6446"),s=n("c1b3"),u=n("002b"),c=n("0ec0"),l=n("c3f4"),h=n("7e3c"),f=n("d3a9"),d=n("3223"),p=n("f4b1"),m=n("532a"),g=n("7958"),v=n("3e94"),y=n("c7e7"),_=n("1262"),x=n("9a02"),b=n("62b4"),w=n("a30f"),M=n("afdf"),S=n("7464"),T=n("9cd9").f,E=n("d770"),A=n("d796").forEach,C=n("c60e"),P=n("6c01"),L=n("064b"),O=n("e13b"),R=n("0ffc"),k=O.get,I=O.set,D=P.f,j=L.f,z=Math.round,N=i.RangeError,F=c.ArrayBuffer,B=F.prototype,H=c.DataView,G=u.NATIVE_ARRAY_BUFFER_VIEWS,U=u.TYPED_ARRAY_CONSTRUCTOR,W=u.TYPED_ARRAY_TAG,V=u.TypedArray,Z=u.TypedArrayPrototype,q=u.aTypedArrayConstructor,Y=u.isTypedArray,J="BYTES_PER_ELEMENT",X="Wrong length",$=function(t,e){q(t);for(var n=0,r=e.length,i=new t(r);r>n;)i[n]=e[n++];return i},Q=function(t,e){D(t,e,{get:function(){return k(this)[e]}})},K=function(t){var e;return M(B,t)||"ArrayBuffer"==(e=_(t))||"SharedArrayBuffer"==e},tt=function(t,e){return Y(t)&&!b(e)&&e in t&&d(+e)&&e>=0},et=function(t,e){return e=v(e),tt(t,e)?h(2,t[e]):j(t,e)},nt=function(t,e,n){return e=v(e),!(tt(t,e)&&x(n)&&y(n,"value"))||y(n,"get")||y(n,"set")||n.configurable||y(n,"writable")&&!n.writable||y(n,"enumerable")&&!n.enumerable?D(t,e,n):(t[e]=n.value,t)};a?(G||(L.f=et,P.f=nt,Q(Z,"buffer"),Q(Z,"byteOffset"),Q(Z,"byteLength"),Q(Z,"length")),r({target:"Object",stat:!0,forced:!G},{getOwnPropertyDescriptor:et,defineProperty:nt}),t.exports=function(t,e,n){var a=t.match(/\d+$/)[0]/8,u=t+(n?"Clamped":"")+"Array",c="get"+t,h="set"+t,d=i[u],v=d,y=v&&v.prototype,_={},b=function(t,e){D(t,e,{get:function(){return function(t,e){var n=k(t);return n.view[c](e*a+n.byteOffset,!0)}(this,e)},set:function(t){return function(t,e,r){var i=k(t);n&&(r=(r=z(r))<0?0:r>255?255:255&r),i.view[h](e*a+i.byteOffset,r,!0)}(this,e,t)},enumerable:!0})};G?s&&(v=e((function(t,e,n,r){return l(t,y),R(x(e)?K(e)?void 0!==r?new d(e,g(n,a),r):void 0!==n?new d(e,g(n,a)):new d(e):Y(e)?$(v,e):o(E,v,e):new d(m(e)),t,v)})),S&&S(v,V),A(T(d),(function(t){t in v||f(v,t,d[t])})),v.prototype=y):(v=e((function(t,e,n,r){l(t,y);var i,s,u,c=0,h=0;if(x(e)){if(!K(e))return Y(e)?$(v,e):o(E,v,e);i=e,h=g(n,a);var f=e.byteLength;if(void 0===r){if(f%a)throw N(X);if((s=f-h)<0)throw N(X)}else if((s=p(r)*a)+h>f)throw N(X);u=s/a}else u=m(e),i=new F(s=u*a);for(I(t,{buffer:i,byteOffset:h,byteLength:s,length:u,view:new H(i)});c<u;)b(t,c++)})),S&&S(v,V),y=v.prototype=w(Z)),y.constructor!==v&&f(y,"constructor",v),f(y,U,v),W&&f(y,W,u),_[u]=v,r({global:!0,forced:v!=d,sham:!G},_),J in v||f(v,J,a),J in y||f(y,J,a),C(u)}):t.exports=function(){}},"519f":function(t,e,n){var r=n("ca14"),i=n("34bc"),o=n("c7e7"),a=n("0b61"),s=n("5ce1"),u=n("7b76"),c=i("wks"),l=r.Symbol,h=l&&l.for,f=u?l:l&&l.withoutSetter||a;t.exports=function(t){if(!o(c,t)||!s&&"string"!=typeof c[t]){var e="Symbol."+t;s&&o(l,t)?c[t]=l[t]:c[t]=u&&h?h(e):f(e)}return c[t]}},"532a":function(t,e,n){var r=n("ca14"),i=n("4799"),o=n("f4b1"),a=r.RangeError;t.exports=function(t){if(void 0===t)return 0;var e=i(t),n=o(e);if(e!==n)throw a("Wrong length or index");return n}},"53b8":function(t,e,n){var r=n("34bc"),i=n("0b61"),o=r("keys");t.exports=function(t){return o[t]||(o[t]=i(t))}},5408:function(t,e,n){"use strict";var r=n("961e"),i=n("d796").map;r({target:"Array",proto:!0,forced:!n("7ba8")("map")},{map:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}})},"54ab":function(t,e,n){var r=n("ca14"),i=n("1262"),o=r.String;t.exports=function(t){if("Symbol"===i(t))throw TypeError("Cannot convert a Symbol value to a string");return o(t)}},"54b9":function(t,e,n){var r=n("c814"),i=n("ca14").RegExp,o=r((function(){var t=i("a","y");return t.lastIndex=2,null!=t.exec("abcd")})),a=o||r((function(){return!i("a","y").sticky})),s=o||r((function(){var t=i("^r","gy");return t.lastIndex=2,null!=t.exec("str")}));t.exports={BROKEN_CARET:s,MISSED_STICKY:a,UNSUPPORTED_Y:o}},"55c9":function(t,e,n){"use strict";var r=n("961e"),i=n("b6de");r({target:"String",proto:!0,forced:n("9db9")("sub")},{sub:function(){return i(this,"sub","","")}})},"570c":function(t,e,n){"use strict";var r=n("961e"),i=n("c252"),o=n("96c7"),a=n("c39c"),s=n("54ab"),u=n("2b26"),c=i("".indexOf);r({target:"String",proto:!0,forced:!u("includes")},{includes:function(t){return!!~c(s(a(this)),s(o(t)),arguments.length>1?arguments[1]:void 0)}})},"57c6":function(t,e){t.exports="object"==typeof window},5810:function(t,e,n){var r=n("0a7d");r.__esModule&&(r=r.default),"string"==typeof r&&(r=[[t.i,r,""]]),r.locals&&(t.exports=r.locals),(0,n("5925").default)("d79e9d8e",r,!0,{sourceMap:!1,shadowMode:!1})},5925:function(t,e,n){"use strict";function r(t,e){for(var n=[],r={},i=0;i<e.length;i++){var o=e[i],a=o[0],s={id:t+":"+i,css:o[1],media:o[2],sourceMap:o[3]};r[a]?r[a].parts.push(s):n.push(r[a]={id:a,parts:[s]})}return n}n.r(e),n.d(e,"default",(function(){return p}));var i="undefined"!=typeof document;if("undefined"!=typeof DEBUG&&DEBUG&&!i)throw new Error("vue-style-loader cannot be used in a non-browser environment. Use { target: 'node' } in your Webpack config to indicate a server-rendering environment.");var o={},a=i&&(document.head||document.getElementsByTagName("head")[0]),s=null,u=0,c=!1,l=function(){},h=null,f="data-vue-ssr-id",d="undefined"!=typeof navigator&&/msie [6-9]\b/.test(navigator.userAgent.toLowerCase());function p(t,e,n,i){c=n,h=i||{};var a=r(t,e);return m(a),function(e){for(var n=[],i=0;i<a.length;i++){var s=a[i],u=o[s.id];u.refs--,n.push(u)}for(e?m(a=r(t,e)):a=[],i=0;i<n.length;i++)if(0===(u=n[i]).refs){for(var c=0;c<u.parts.length;c++)u.parts[c]();delete o[u.id]}}}function m(t){for(var e=0;e<t.length;e++){var n=t[e],r=o[n.id];if(r){r.refs++;for(var i=0;i<r.parts.length;i++)r.parts[i](n.parts[i]);for(;i<n.parts.length;i++)r.parts.push(v(n.parts[i]));r.parts.length>n.parts.length&&(r.parts.length=n.parts.length)}else{var a=[];for(i=0;i<n.parts.length;i++)a.push(v(n.parts[i]));o[n.id]={id:n.id,refs:1,parts:a}}}}function g(){var t=document.createElement("style");return t.type="text/css",a.appendChild(t),t}function v(t){var e,n,r=document.querySelector("style["+f+'~="'+t.id+'"]');if(r){if(c)return l;r.parentNode.removeChild(r)}if(d){var i=u++;r=s||(s=g()),e=_.bind(null,r,i,!1),n=_.bind(null,r,i,!0)}else r=g(),e=x.bind(null,r),n=function(){r.parentNode.removeChild(r)};return e(t),function(r){if(r){if(r.css===t.css&&r.media===t.media&&r.sourceMap===t.sourceMap)return;e(t=r)}else n()}}var y=function(){var t=[];return function(e,n){return t[e]=n,t.filter(Boolean).join("\n")}}();function _(t,e,n,r){var i=n?"":r.css;if(t.styleSheet)t.styleSheet.cssText=y(e,i);else{var o=document.createTextNode(i),a=t.childNodes;a[e]&&t.removeChild(a[e]),a.length?t.insertBefore(o,a[e]):t.appendChild(o)}}function x(t,e){var n=e.css,r=e.media,i=e.sourceMap;if(r&&t.setAttribute("media",r),h.ssrId&&t.setAttribute(f,e.id),i&&(n+="\n/*# sourceURL="+i.sources[0]+" */",n+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(i))))+" */"),t.styleSheet)t.styleSheet.cssText=n;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(n))}}},"5b0d":function(t,e,n){var r=n("97d8"),i=n("9a02"),o=n("8088");t.exports=function(t,e){if(r(t),i(e)&&e.constructor===t)return e;var n=o.f(t);return(0,n.resolve)(e),n.promise}},"5c75":function(t,e,n){var r=n("4704"),i=n("988d");t.exports=Object.keys||function(t){return r(t,i)}},"5cb9":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA8AAAAPCAYAAAA71pVKAAAKN2lDQ1BzUkdCIElFQzYxOTY2LTIuMQAAeJydlndUU9kWh8+9N71QkhCKlNBraFICSA29SJEuKjEJEErAkAAiNkRUcERRkaYIMijggKNDkbEiioUBUbHrBBlE1HFwFBuWSWStGd+8ee/Nm98f935rn73P3Wfvfda6AJD8gwXCTFgJgAyhWBTh58WIjYtnYAcBDPAAA2wA4HCzs0IW+EYCmQJ82IxsmRP4F726DiD5+yrTP4zBAP+flLlZIjEAUJiM5/L42VwZF8k4PVecJbdPyZi2NE3OMErOIlmCMlaTc/IsW3z2mWUPOfMyhDwZy3PO4mXw5Nwn4405Er6MkWAZF+cI+LkyviZjg3RJhkDGb+SxGXxONgAoktwu5nNTZGwtY5IoMoIt43kA4EjJX/DSL1jMzxPLD8XOzFouEiSniBkmXFOGjZMTi+HPz03ni8XMMA43jSPiMdiZGVkc4XIAZs/8WRR5bRmyIjvYODk4MG0tbb4o1H9d/JuS93aWXoR/7hlEH/jD9ld+mQ0AsKZltdn6h21pFQBd6wFQu/2HzWAvAIqyvnUOfXEeunxeUsTiLGcrq9zcXEsBn2spL+jv+p8Of0NffM9Svt3v5WF485M4knQxQ143bmZ6pkTEyM7icPkM5p+H+B8H/nUeFhH8JL6IL5RFRMumTCBMlrVbyBOIBZlChkD4n5r4D8P+pNm5lona+BHQllgCpSEaQH4eACgqESAJe2Qr0O99C8ZHA/nNi9GZmJ37z4L+fVe4TP7IFiR/jmNHRDK4ElHO7Jr8WgI0IABFQAPqQBvoAxPABLbAEbgAD+ADAkEoiARxYDHgghSQAUQgFxSAtaAYlIKtYCeoBnWgETSDNnAYdIFj4DQ4By6By2AE3AFSMA6egCnwCsxAEISFyBAVUod0IEPIHLKFWJAb5AMFQxFQHJQIJUNCSAIVQOugUqgcqobqoWboW+godBq6AA1Dt6BRaBL6FXoHIzAJpsFasBFsBbNgTzgIjoQXwcnwMjgfLoK3wJVwA3wQ7oRPw5fgEVgKP4GnEYAQETqiizARFsJGQpF4JAkRIauQEqQCaUDakB6kH7mKSJGnyFsUBkVFMVBMlAvKHxWF4qKWoVahNqOqUQdQnag+1FXUKGoK9RFNRmuizdHO6AB0LDoZnYsuRlegm9Ad6LPoEfQ4+hUGg6FjjDGOGH9MHCYVswKzGbMb0445hRnGjGGmsVisOtYc64oNxXKwYmwxtgp7EHsSewU7jn2DI+J0cLY4X1w8TogrxFXgWnAncFdwE7gZvBLeEO+MD8Xz8MvxZfhGfA9+CD+OnyEoE4wJroRIQiphLaGS0EY4S7hLeEEkEvWITsRwooC4hlhJPEQ8TxwlviVRSGYkNimBJCFtIe0nnSLdIr0gk8lGZA9yPFlM3kJuJp8h3ye/UaAqWCoEKPAUVivUKHQqXFF4pohXNFT0VFysmK9YoXhEcUjxqRJeyUiJrcRRWqVUo3RU6YbStDJV2UY5VDlDebNyi/IF5UcULMWI4kPhUYoo+yhnKGNUhKpPZVO51HXURupZ6jgNQzOmBdBSaaW0b2iDtCkVioqdSrRKnkqNynEVKR2hG9ED6On0Mvph+nX6O1UtVU9Vvuom1TbVK6qv1eaoeajx1UrU2tVG1N6pM9R91NPUt6l3qd/TQGmYaYRr5Grs0Tir8XQObY7LHO6ckjmH59zWhDXNNCM0V2ju0xzQnNbS1vLTytKq0jqj9VSbru2hnaq9Q/uE9qQOVcdNR6CzQ+ekzmOGCsOTkc6oZPQxpnQ1df11Jbr1uoO6M3rGelF6hXrtevf0Cfos/ST9Hfq9+lMGOgYhBgUGrQa3DfGGLMMUw12G/YavjYyNYow2GHUZPTJWMw4wzjduNb5rQjZxN1lm0mByzRRjyjJNM91tetkMNrM3SzGrMRsyh80dzAXmu82HLdAWThZCiwaLG0wS05OZw2xljlrSLYMtCy27LJ9ZGVjFW22z6rf6aG1vnW7daH3HhmITaFNo02Pzq62ZLde2xvbaXPJc37mr53bPfW5nbse322N3055qH2K/wb7X/oODo4PIoc1h0tHAMdGx1vEGi8YKY21mnXdCO3k5rXY65vTW2cFZ7HzY+RcXpkuaS4vLo3nG8/jzGueNueq5clzrXaVuDLdEt71uUnddd457g/sDD30PnkeTx4SnqWeq50HPZ17WXiKvDq/XbGf2SvYpb8Tbz7vEe9CH4hPlU+1z31fPN9m31XfKz95vhd8pf7R/kP82/xsBWgHcgOaAqUDHwJWBfUGkoAVB1UEPgs2CRcE9IXBIYMj2kLvzDecL53eFgtCA0O2h98KMw5aFfR+OCQ8Lrwl/GGETURDRv4C6YMmClgWvIr0iyyLvRJlESaJ6oxWjE6Kbo1/HeMeUx0hjrWJXxl6K04gTxHXHY+Oj45vipxf6LNy5cDzBPqE44foi40V5iy4s1licvvj4EsUlnCVHEtGJMYktie85oZwGzvTSgKW1S6e4bO4u7hOeB28Hb5Lvyi/nTyS5JpUnPUp2Td6ePJninlKR8lTAFlQLnqf6p9alvk4LTduf9ik9Jr09A5eRmHFUSBGmCfsytTPzMoezzLOKs6TLnJftXDYlChI1ZUPZi7K7xTTZz9SAxESyXjKa45ZTk/MmNzr3SJ5ynjBvYLnZ8k3LJ/J9879egVrBXdFboFuwtmB0pefK+lXQqqWrelfrry5aPb7Gb82BtYS1aWt/KLQuLC98uS5mXU+RVtGaorH1futbixWKRcU3NrhsqNuI2ijYOLhp7qaqTR9LeCUXS61LK0rfb+ZuvviVzVeVX33akrRlsMyhbM9WzFbh1uvb3LcdKFcuzy8f2x6yvXMHY0fJjpc7l+y8UGFXUbeLsEuyS1oZXNldZVC1tep9dUr1SI1XTXutZu2m2te7ebuv7PHY01anVVda926vYO/Ner/6zgajhop9mH05+x42Rjf2f836urlJo6m06cN+4X7pgYgDfc2Ozc0tmi1lrXCrpHXyYMLBy994f9Pdxmyrb6e3lx4ChySHHn+b+O31w0GHe4+wjrR9Z/hdbQe1o6QT6lzeOdWV0iXtjusePhp4tLfHpafje8vv9x/TPVZzXOV42QnCiaITn07mn5w+lXXq6enk02O9S3rvnIk9c60vvG/wbNDZ8+d8z53p9+w/ed71/LELzheOXmRd7LrkcKlzwH6g4wf7HzoGHQY7hxyHui87Xe4Znjd84or7ldNXva+euxZw7dLI/JHh61HXb95IuCG9ybv56Fb6ree3c27P3FlzF3235J7SvYr7mvcbfjT9sV3qID0+6j068GDBgztj3LEnP2X/9H686CH5YcWEzkTzI9tHxyZ9Jy8/Xvh4/EnWk5mnxT8r/1z7zOTZd794/DIwFTs1/lz0/NOvm1+ov9j/0u5l73TY9P1XGa9mXpe8UX9z4C3rbf+7mHcTM7nvse8rP5h+6PkY9PHup4xPn34D94Tz+49wZioAAAAJcEhZcwAACxIAAAsSAdLdfvwAAALeSURBVHicVZPNaxNBGMbfnZ3srmuakCZpGpNSWjDZYgqW3LzYgkir1kDBHPwHBA96UHrUkwdBT56KFPFv6KEWpBUMtBFaanuoVULSpMQkzUeTNNtssh/OmxrBuQ0zz/PM+76/oZZlAa7JSSIYhiKyvSgBDFiEuIhlOUyOa3CmWWsDNDmO03j+h7a/b3ZQQ/tCXQ87ZJ64QNdljudlKghuSZbdeqdTb6uqKBuGA3heVfVwjd1voAHtCy/xvM/kDJ8oi+6Z23PvBUGwsySLJ8Q6b7fr28nNV6WT4h67J5zrYQxsUHwqJqLw5vStR3fuzce7eheOsllo1Ovg9XpBURRPLBZ782F5+W1yK7Em83zn3FA0ijXiU5VI5MazxcUHkiRBOpOGcrkMzUYD7HY7DA0NwejoKO/xep8/efzod+HouGJxnEixOVhjbGHhRSAQ4Cy4aGClXOkZ+P1+CAaDgH11uVxk9u791x+XlqYl0xyg2FWv3389rCh8tVoFTB4cHISpqSnIHecgEolAu92GWq0GrVYLxsbGiNPtvlqpVDSK47CJ4khLVUkqlYKLxQEhHESuRSD5LQl6V4f+SJkRL0pSgOmyFOfITtRMJsPOLU5VVWg2z3rieDwOiUQCsrkcCDYbsAmAYRiWZZqnqKMIQPP0dDudTuuiKNq63W7vUig0AU6nE6LRKHQ6HSgWi6BpGk7AaDWbv1BHkZxGtZrP53J7V0ZGosyg193h4WHGBA9ejxfGx8fBNE3AnhTy+WSrXj9pc1yTInJIztbm18WZy7MrysSE7PF4YMDhAHYGoiSCz+eDs7MzODw4KO5sJ18SSlWWrFFkFZFDcjY+f5onAO/cbndIFIQeuoQQKJVKnS/r6z/XVleeMuaKqmHUKD3UKDKKqCFySM7G6urD/d3dkD8YnGMmAVbrQa1S2Slks98x8a/wgm10/2fAkENySoVCo1gqpf77VazG3lNZYv9X/QEJM4cEk5QMqQAAAABJRU5ErkJggg=="},"5ce1":function(t,e,n){var r=n("a0a0"),i=n("c814");t.exports=!!Object.getOwnPropertySymbols&&!i((function(){var t=Symbol();return!String(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&r&&r<41}))},"5eb3":function(t,e,n){var r=n("3a40").Global;function i(){return r.localStorage}function o(t){return i().getItem(t)}t.exports={name:"localStorage",read:o,write:function(t,e){return i().setItem(t,e)},each:function(t){for(var e=i().length-1;e>=0;e--){var n=i().key(e);t(o(n),n)}},remove:function(t){return i().removeItem(t)},clearAll:function(){return i().clear()}}},"5ffc":function(t,e,n){n("961e")({target:"Reflect",stat:!0},{ownKeys:n("4b1a")})},"61a6":function(t,e){var n=Function.prototype,r=n.apply,i=n.bind,o=n.call;t.exports="object"==typeof Reflect&&Reflect.apply||(i?o.bind(r):function(){return o.apply(r,arguments)})},"622a":function(t,e,n){var r=n("961e"),i=n("ea06").entries;r({target:"Object",stat:!0},{entries:function(t){return i(t)}})},6266:function(t,e,n){(function(t){function n(t,e){for(var n=0,r=t.length-1;r>=0;r--){var i=t[r];"."===i?t.splice(r,1):".."===i?(t.splice(r,1),n++):n&&(t.splice(r,1),n--)}if(e)for(;n--;n)t.unshift("..");return t}function r(t,e){if(t.filter)return t.filter(e);for(var n=[],r=0;r<t.length;r++)e(t[r],r,t)&&n.push(t[r]);return n}e.resolve=function(){for(var e="",i=!1,o=arguments.length-1;o>=-1&&!i;o--){var a=o>=0?arguments[o]:t.cwd();if("string"!=typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(e=a+"/"+e,i="/"===a.charAt(0))}return(i?"/":"")+(e=n(r(e.split("/"),(function(t){return!!t})),!i).join("/"))||"."},e.normalize=function(t){var o=e.isAbsolute(t),a="/"===i(t,-1);return(t=n(r(t.split("/"),(function(t){return!!t})),!o).join("/"))||o||(t="."),t&&a&&(t+="/"),(o?"/":"")+t},e.isAbsolute=function(t){return"/"===t.charAt(0)},e.join=function(){var t=Array.prototype.slice.call(arguments,0);return e.normalize(r(t,(function(t,e){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t})).join("/"))},e.relative=function(t,n){function r(t){for(var e=0;e<t.length&&""===t[e];e++);for(var n=t.length-1;n>=0&&""===t[n];n--);return e>n?[]:t.slice(e,n-e+1)}t=e.resolve(t).substr(1),n=e.resolve(n).substr(1);for(var i=r(t.split("/")),o=r(n.split("/")),a=Math.min(i.length,o.length),s=a,u=0;u<a;u++)if(i[u]!==o[u]){s=u;break}var c=[];for(u=s;u<i.length;u++)c.push("..");return(c=c.concat(o.slice(s))).join("/")},e.sep="/",e.delimiter=":",e.dirname=function(t){if("string"!=typeof t&&(t+=""),0===t.length)return".";for(var e=t.charCodeAt(0),n=47===e,r=-1,i=!0,o=t.length-1;o>=1;--o)if(47===(e=t.charCodeAt(o))){if(!i){r=o;break}}else i=!1;return-1===r?n?"/":".":n&&1===r?"/":t.slice(0,r)},e.basename=function(t,e){var n=function(t){"string"!=typeof t&&(t+="");var e,n=0,r=-1,i=!0;for(e=t.length-1;e>=0;--e)if(47===t.charCodeAt(e)){if(!i){n=e+1;break}}else-1===r&&(i=!1,r=e+1);return-1===r?"":t.slice(n,r)}(t);return e&&n.substr(-1*e.length)===e&&(n=n.substr(0,n.length-e.length)),n},e.extname=function(t){"string"!=typeof t&&(t+="");for(var e=-1,n=0,r=-1,i=!0,o=0,a=t.length-1;a>=0;--a){var s=t.charCodeAt(a);if(47!==s)-1===r&&(i=!1,r=a+1),46===s?-1===e?e=a:1!==o&&(o=1):-1!==e&&(o=-1);else if(!i){n=a+1;break}}return-1===e||-1===r||0===o||1===o&&e===r-1&&e===n+1?"":t.slice(e,r)};var i="b"==="ab".substr(-1)?function(t,e,n){return t.substr(e,n)}:function(t,e,n){return e<0&&(e=t.length+e),t.substr(e,n)}}).call(this,n("eef6"))},"62b4":function(t,e,n){var r=n("ca14"),i=n("d45e"),o=n("081e"),a=n("afdf"),s=n("7b76"),u=r.Object;t.exports=s?function(t){return"symbol"==typeof t}:function(t){var e=i("Symbol");return o(e)&&a(e.prototype,u(t))}},"62ea":function(t,e,n){var r=n("6446"),i=n("c814"),o=n("c4ae");t.exports=!r&&!i((function(){return 7!=Object.defineProperty(o("div"),"a",{get:function(){return 7}}).a}))},6326:function(t,e,n){var r=n("ca14");t.exports=r.Promise},6346:function(t,e,n){var r=n("c814"),i=n("ca14").RegExp;t.exports=r((function(){var t=i("(?<a>b)","g");return"b"!==t.exec("b").groups.a||"bc"!=="b".replace(t,"$<a>c")}))},6446:function(t,e,n){var r=n("c814");t.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},6566:function(t,e,n){var r=n("519f")("iterator"),i=!1;try{var o=0,a={next:function(){return{done:!!o++}},return:function(){i=!0}};a[r]=function(){return this},Array.from(a,(function(){throw 2}))}catch(t){}t.exports=function(t,e){if(!e&&!i)return!1;var n=!1;try{var o={};o[r]=function(){return{next:function(){return{done:n=!0}}}},t(o)}catch(t){}return n}},6599:function(t,e,n){var r=n("97d8"),i=n("47fa");t.exports=function(t,e,n,o){try{return o?e(r(n)[0],n[1]):e(n)}catch(e){i(t,"throw",e)}}},"66da":function(t,e){var n="expire_mixin";t.exports=function(){var t=this.createStore(this.storage,null,this._namespacePrefix+n);return{set:function(e,r,i,o){return this.hasNamespace(n)||t.set(r,o),e()},get:function(t,r){return this.hasNamespace(n)||e.call(this,r),t()},remove:function(e,r){return this.hasNamespace(n)||t.remove(r),e()},getExpiration:function(e,n){return t.get(n)},removeExpiredKeys:function(t){var n=[];this.each((function(t,e){n.push(e)}));for(var r=0;r<n.length;r++)e.call(this,n[r])}};function e(e){t.get(e,Number.MAX_VALUE)<=(new Date).getTime()&&(this.raw.remove(e),t.remove(e))}}},"675d":function(t,e,n){var r,i,o,a,s=n("ca14"),u=n("61a6"),c=n("ad0f"),l=n("081e"),h=n("c7e7"),f=n("c814"),d=n("03c2"),p=n("13eb"),m=n("c4ae"),g=n("2a67"),v=n("801d"),y=s.setImmediate,_=s.clearImmediate,x=s.process,b=s.Dispatch,w=s.Function,M=s.MessageChannel,S=s.String,T=0,E={},A="onreadystatechange";try{r=s.location}catch(t){}var C=function(t){if(h(E,t)){var e=E[t];delete E[t],e()}},P=function(t){return function(){C(t)}},L=function(t){C(t.data)},O=function(t){s.postMessage(S(t),r.protocol+"//"+r.host)};y&&_||(y=function(t){var e=p(arguments,1);return E[++T]=function(){u(l(t)?t:w(t),void 0,e)},i(T),T},_=function(t){delete E[t]},v?i=function(t){x.nextTick(P(t))}:b&&b.now?i=function(t){b.now(P(t))}:M&&!g?(a=(o=new M).port2,o.port1.onmessage=L,i=c(a.postMessage,a)):s.addEventListener&&l(s.postMessage)&&!s.importScripts&&r&&"file:"!==r.protocol&&!f(O)?(i=O,s.addEventListener("message",L,!1)):i=A in m("script")?function(t){d.appendChild(m("script"))[A]=function(){d.removeChild(this),C(t)}}:function(t){setTimeout(P(t),0)}),t.exports={set:y,clear:_}},"6c01":function(t,e,n){var r=n("ca14"),i=n("6446"),o=n("62ea"),a=n("97d8"),s=n("3e94"),u=r.TypeError,c=Object.defineProperty;e.f=i?c:function(t,e,n){if(a(t),e=s(e),a(n),o)try{return c(t,e,n)}catch(t){}if("get"in n||"set"in n)throw u("Accessors not supported");return"value"in n&&(t[e]=n.value),t}},"6ca2":function(t,e,n){"use strict";var r=n("002b"),i=n("d796").every,o=r.aTypedArray;(0,r.exportTypedArrayMethod)("every",(function(t){return i(o(this),t,arguments.length>1?arguments[1]:void 0)}))},"6d31":function(t,e,n){"use strict";var r=n("ca14"),i=n("c252"),o=n("c814"),a=n("b0c4"),s=n("2d18"),u=n("002b"),c=n("3492"),l=n("cf94"),h=n("a0a0"),f=n("119b"),d=r.Array,p=u.aTypedArray,m=u.exportTypedArrayMethod,g=r.Uint16Array,v=g&&i(g.prototype.sort),y=!(!v||o((function(){v(new g(2),null)}))&&o((function(){v(new g(2),{})}))),_=!!v&&!o((function(){if(h)return h<74;if(c)return c<67;if(l)return!0;if(f)return f<602;var t,e,n=new g(516),r=d(516);for(t=0;t<516;t++)e=t%4,n[t]=515-t,r[t]=t-2*e+3;for(v(n,(function(t,e){return(t/4|0)-(e/4|0)})),t=0;t<516;t++)if(n[t]!==r[t])return!0}));m("sort",(function(t){return void 0!==t&&a(t),_?v(this,t):s(p(this),function(t){return function(e,n){return void 0!==t?+t(e,n)||0:n!=n?-1:e!=e?1:0===e&&0===n?1/e>0&&1/n<0?1:-1:e>n}}(t))}),!_||y)},"6d9b":function(t,e,n){var r=n("c252"),i=n("c814"),o=n("081e"),a=n("1262"),s=n("d45e"),u=n("4f29"),c=function(){},l=[],h=s("Reflect","construct"),f=/^\s*(?:class|function)\b/,d=r(f.exec),p=!f.exec(c),m=function(t){if(!o(t))return!1;try{return h(c,l,t),!0}catch(t){return!1}};t.exports=!h||i((function(){var t;return m(m.call)||!m(Object)||!m((function(){t=!0}))||t}))?function(t){if(!o(t))return!1;switch(a(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}return p||!!d(f,u(t))}:m},"6e68":function(t,e,n){"use strict";var r=n("097d"),i=n("9acd"),o=n("db7f"),a=n("e13b"),s=n("b45e"),u="Array Iterator",c=a.set,l=a.getterFor(u);t.exports=s(Array,"Array",(function(t,e){c(this,{type:u,target:r(t),index:0,kind:e})}),(function(){var t=l(this),e=t.target,n=t.kind,r=t.index++;return!e||r>=e.length?(t.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:r,done:!1}:"values"==n?{value:e[r],done:!1}:{value:[r,e[r]],done:!1}}),"values"),o.Arguments=o.Array,i("keys"),i("values"),i("entries")},"716d":function(t,e,n){var r=n("4748");t.exports=/web0s(?!.*chrome)/i.test(r)},7203:function(t,e,n){t.exports=n.p+"img/kedu.2adfe059.png"},7219:function(t,e,n){var r=n("ca14"),i=n("081e"),o=n("c7e7"),a=n("d3a9"),s=n("a2c2"),u=n("4f29"),c=n("e13b"),l=n("265d").CONFIGURABLE,h=c.get,f=c.enforce,d=String(String).split("String");(t.exports=function(t,e,n,u){var c,h=!!u&&!!u.unsafe,p=!!u&&!!u.enumerable,m=!!u&&!!u.noTargetGet,g=u&&void 0!==u.name?u.name:e;i(n)&&("Symbol("===String(g).slice(0,7)&&(g="["+String(g).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),(!o(n,"name")||l&&n.name!==g)&&a(n,"name",g),(c=f(n)).source||(c.source=d.join("string"==typeof g?g:""))),t!==r?(h?!m&&t[e]&&(p=!0):delete t[e],p?t[e]=n:a(t,e,n)):p?t[e]=n:s(e,n)})(Function.prototype,"toString",(function(){return i(this)&&h(this).source||u(this)}))},"72ae":function(t,e,n){n("18fd")("iterator")},7464:function(t,e,n){var r=n("c252"),i=n("97d8"),o=n("2946");t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{(t=r(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(n,[]),e=n instanceof Array}catch(t){}return function(n,r){return i(n),o(r),e?t(n,r):n.__proto__=r,n}}():void 0)},"75a1":function(t,e,n){"use strict";var r=n("6446"),i=n("c252"),o=n("cbac"),a=n("c814"),s=n("5c75"),u=n("b2e9"),c=n("c829"),l=n("41a4"),h=n("96a5"),f=Object.assign,d=Object.defineProperty,p=i([].concat);t.exports=!f||a((function(){if(r&&1!==f({b:1},f(d({},"a",{enumerable:!0,get:function(){d(this,"b",{value:3,enumerable:!1})}}),{b:2})).b)return!0;var t={},e={},n=Symbol(),i="abcdefghijklmnopqrst";return t[n]=7,i.split("").forEach((function(t){e[t]=t})),7!=f({},t)[n]||s(f({},e)).join("")!=i}))?function(t,e){for(var n=l(t),i=arguments.length,a=1,f=u.f,d=c.f;i>a;)for(var m,g=h(arguments[a++]),v=f?p(s(g),f(g)):s(g),y=v.length,_=0;y>_;)m=v[_++],r&&!o(d,g,m)||(n[m]=g[m]);return n}:f},7958:function(t,e,n){var r=n("ca14"),i=n("23a5"),o=r.RangeError;t.exports=function(t,e){var n=i(t);if(n%e)throw o("Wrong offset");return n}},"79b5":function(t,e,n){var r=n("ca14"),i=n("081e"),o=n("4f29"),a=r.WeakMap;t.exports=i(a)&&/native code/.test(o(a))},"7a02":function(t,e,n){var r=n("9a02"),i=n("cc43"),o=n("519f")("match");t.exports=function(t){var e;return r(t)&&(void 0!==(e=t[o])?!!e:"RegExp"==i(t))}},"7b76":function(t,e,n){var r=n("5ce1");t.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},"7ba8":function(t,e,n){var r=n("c814"),i=n("519f"),o=n("a0a0"),a=i("species");t.exports=function(t){return o>=51||!r((function(){var e=[];return(e.constructor={})[a]=function(){return{foo:1}},1!==e[t](Boolean).foo}))}},"7c98":function(t,e,n){(function(t,r){var i;
15
15
  /**
16
16
  * @license
17
17
  * Lodash <https://lodash.com/>
@@ -48,7 +48,7 @@ const h="127",f={LEFT:0,MIDDLE:1,RIGHT:2,ROTATE:0,DOLLY:1,PAN:2},d={ROTATE:0,PAN
48
48
  * LICENSE : BSD-3-Clause
49
49
  * (c) 2016-2021 maptalks.org
50
50
  */
51
- var i="_maptalks__internal_layer_",o=["MultiPoint","MultiLineString","MultiPolygon","GeometryCollection"],a=["FeatureCollection","Feature","Point","LineString","Polygon"].concat(o),s=["markerFile","polygonPatternFile","linePatternFile","markerFillPatternFile","markerLinePatternFile"],u=[["markerWidth","markerHeight"],[],[null,"lineWidth"],[],[null,"markerLineWidth"]],c={lineWidth:1,lineOpacity:1,lineDx:1,lineDy:1,polygonOpacity:1,markerWidth:1,markerHeight:1,markerDx:1,markerDy:1,markerOpacity:1,markerFillOpacity:1,markerLineWidth:1,markerLineOpacity:1,textSize:1,textOpacity:1,textHaloRadius:1,textWrapWidth:1,textLineSpacing:1,textDx:1,textDy:1},l=["lineColor","polygonFill","markerFill","markerLineColor","textFill"],h=14;function f(){return Date.now()}function d(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)t[r]=n[r]}return t}function p(t){return null==t}function m(t){return"number"==typeof t&&!isNaN(t)}function g(t){return(0|t)===t}function v(t){return"object"==typeof t&&!!t}function y(t){return!p(t)&&("string"==typeof t||null!==t.constructor&&t.constructor===String)}function _(t){return!p(t)&&("function"==typeof t||null!==t.constructor&&t.constructor===Function)}var x=Object.prototype.hasOwnProperty;function b(t,e){return x.call(t,e)}var w=Math.PI/180;function M(t){return t*w}function S(t){return t/w}var T,E,A="[object process]"===Object.prototype.toString.call(void 0!==t?t:0)&&!t.versions.electron&&!t.versions.nw&&!t.versions["node-webkit"];function C(t){var e="data:image/svg+xml";return t.length>4&&".svg"===t.slice(-4)?1:t.slice(0,e.length)===e?2:0}function P(t,e){A&&P.node?P.node(t,e):t.src=e[0]}!function(){if(A)return T=function(t){return setTimeout(t,16)},void(E=clearTimeout);var t,e;function n(t){return setTimeout(t,1e3/30)}function r(t){return window["webkit"+t]||window["moz"+t]||window["ms"+t]}"undefined"!=typeof window?(t=window.requestAnimationFrame||r("RequestAnimationFrame")||n,e=window.cancelAnimationFrame||r("CancelAnimationFrame")||r("CancelRequestAnimationFrame")||function(t){window.clearTimeout(t)}):(t=n,e=clearTimeout),T=function(e){return t(e)},E=function(t){t&&e(t)}}();var L=0;function O(){return L++}var R=O;function k(t){return t&&y(t)?JSON.parse(t):t}function I(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];if(n)for(var r=0,i=n.length;r<i;r++)t.push(n[r])}return t.length}function D(t,e){var n=e.indexOf(t);n>-1&&e.splice(n,1)}function j(t,e,n){if(!Array.isArray(t))return n?e.call(n,t):e(t);for(var r,i,o=[],a=0,s=t.length;a<s;a++)p(r=t[a])?o.push(null):Array.isArray(r)?o.push(j(r,e,n)):(i=n?e.call(n,r):e(r),o.push(i));return o}function z(t,e){return void 0===t?e:t}function N(t){return Math.sign?Math.sign(t):0==(t=+t)||isNaN(t)?Number(t):t>0?1:-1}function F(t){if(Math.log2)return Math.log2(t);var e=Math.log(t)*Math.LOG2E,n=Math.round(e);return Math.abs(n-e)<1e-14?n:e}function B(t,e,n){return t*(1-n)+e*n}function H(t,e,n){if(t===n||t===e)return t;var r=n-e;return((t-e)%r+r)%r+e}function G(t,e,n){return Math.min(n,Math.max(e,t))}function U(t){return Array.isArray(t)&&t.length>0}var W=/^([a-z][a-z\d+\-.]*:)?\/\//i,V=/^url\((['"])(.+)\1\)$/i,Z=/^url\(([^'"].*[^'"])\)$/i;function q(t){return y(t)?Z.test(t)?1:V.test(t)?2:3:0}function Y(t){var e=q(t);return 3===e?t:1===e?Z.exec(t)[1]:2===e?V.exec(t)[2]:t}function J(t){if("undefined"!=typeof window&&window.btoa)return window.btoa(t);for(var e,n,r=String(t),i="",o=0,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";r.charAt(0|o)||(a="=",o%1);i+=a.charAt(63&e>>8-o%1*8)){if((n=r.charCodeAt(o+=3/4))>255)throw new Error("'btoa' failed: The string to be encoded contains characters outside of the Latin1 range.");e=e<<8|n}return i}function X(t,e){for(var n=atob(t),r=new ArrayBuffer(n.length),i=new Uint8Array(r),o=0;o<n.length;o++)i[o]=255&n.charCodeAt(o);return new Blob([r],{type:e})}function $(t,e,n,r){var i=n-t,o=r-e;return Math.atan2(o,i)}var Q="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7";function K(t,e){if(!t&&!e)return!0;if(!t||!e)return!1;for(var n in t)if("center"===n){if(!e[n]||!tt(t[n][0],e[n][0])||!tt(t[n][1],e[n][1]))return!1}else if(t[n]!==e[n])return!1;return!0}function tt(t,e,n){return null==n&&(n=1e-6),t>=e-n&&t<=e+n}function et(t,e,n,r){t||(t=100),e||(e=4);var i=this;return e*=2,this._flashTimeout&&clearTimeout(this._flashTimeout),this._flashTimeout=setTimeout((function o(){if(0===e)return i.show(),void(n&&(r?n.call(r):n()));e%2==0?i.hide():i.show(),e--,i._flashTimeout=setTimeout(o,t)}),t),this}var nt=["Unknown","Point","LineString","Polygon","MultiPoint","MultiLineString","MultiPolygon","GeometryCollection"];function rt(t){return new Function("f","var p = (f && f.properties || {}); return "+it(t))}function it(t){if(!t)return"true";var e=t[0];return t.length<=1?"any"===e?"false":"true":"("+("=="===e?at(t[1],t[2],"===",!1):"!="===e?at(t[1],t[2],"!==",!1):"<"===e||">"===e||"<="===e||">="===e?at(t[1],t[2],e,!0):"any"===e?st(t.slice(1),"||"):"all"===e?st(t.slice(1),"&&"):"none"===e?lt(st(t.slice(1),"||")):"in"===e?ut(t[1],t.slice(2)):"!in"===e?lt(ut(t[1],t.slice(2))):"has"===e?ct(t[1]):"!has"===e?lt(ct(t[1])):"true")+")"}function ot(t){return"$"===t[0]?"f."+t.substring(1):"p["+JSON.stringify(t)+"]"}function at(t,e,n,r){var i=ot(t),o="$type"===t?nt.indexOf(e):JSON.stringify(e);return(r?"typeof "+i+"=== typeof "+o+"&&":"")+i+n+o}function st(t,e){return t.map(it).join(e)}function ut(t,e){"$type"===t&&(e=e.map((function(t){return nt.indexOf(t)})));var n=JSON.stringify(e.sort(ht)),r=ot(t);return e.length<=200?n+".indexOf("+r+") !== -1":"function(v, a, i, j) {\n while (i <= j) { var m = (i + j) >> 1;\n if (a[m] === v) return true; if (a[m] > v) j = m - 1; else i = m + 1;\n }\n return false; }("+r+", "+n+",0,"+(e.length-1)+")"}function ct(t){return"$id"===t?'"id" in f':JSON.stringify(t)+" in p"}function lt(t){return"!("+t+")"}function ht(t,e){return t<e?-1:t>e?1:0}function ft(t){var e=t._toJSON(),n=e.feature;return n.type=nt.indexOf(n.geometry.type),n.subType=e.subType,n}function dt(t){if(!Array.isArray(t))return dt([t]);for(var e=[],n=0;n<t.length;n++){var r;r=!0===t[n].filter?function(){return!0}:rt(t[n].filter),e.push(pt({},t[n],{filter:r}))}return e}function pt(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)t[r]=n[r]}return t}function mt(t,e){for(var n=0;n<t.stops.length;n++)if(e===t.stops[n][0])return t.stops[n][1];return t.default}function gt(t,e){for(var n=0;n<t.stops.length&&!(e<t.stops[n][0]);n++);return t.stops[Math.max(n-1,0)][1]}function vt(t,e){for(var n=void 0!==t.base?t.base:1,r=0;!(r>=t.stops.length||e<=t.stops[r][0]);)r++;return 0===r?t.stops[r][1]:r===t.stops.length?t.stops[r-1][1]:function t(e,n,r,i,o,a){return"function"==typeof o?function(){var s=o.apply(void 0,arguments),u=a.apply(void 0,arguments);return t(e,n,r,i,s,u)}:o.length?function(t,e,n,r,i,o){for(var a=[],s=0;s<i.length;s++)a[s]=_t(t,e,n,r,i[s],o[s]);return a}(e,n,r,i,o,a):_t(e,n,r,i,o,a)}(e,n,t.stops[r-1][0],t.stops[r][0],t.stops[r-1][1],t.stops[r][1])}function yt(t,e){return function(t,e,n){return void 0!==t?t:void 0!==e?e:void 0!==n?n:null}(e,t.default)}function _t(t,e,n,r,i,o){var a,s=r-n,u=t-n;return i*(1-(a=1===e?u/s:(Math.pow(e,u)-1)/(Math.pow(e,s)-1)))+o*a}function xt(t){return t&&"object"==typeof t&&(t.stops||t.property&&"identity"===t.type)}function bt(t){for(var e in t)if(xt(t[e]))return!0;return!1}function wt(t){return Tt(t,"exponential")}function Mt(t,e){if(!t)return null;var n=!1;if(Array.isArray(t)){for(var r,i=[],o=0;o<t.length;o++)(r=Mt(t[o],e))?(i.push(r),n=!0):i.push(t[o]);return n?i:t}var a,s={__fn_types_loaded:!0},u=[];for(a in t)t.hasOwnProperty(a)&&u.push(a);for(var c=function(t){Object.defineProperty(s,t,{get:function(){return this["__fn_"+t]||(this["__fn_"+t]=wt(this["_"+t])),this["__fn_"+t].apply(this,e())},set:function(e){this["_"+t]=e},configurable:!0,enumerable:!0})},l=0,h=u.length;l<h;l++)xt(t[a=u[l]])?(n=!0,s["_"+a]=t[a],c(a)):s[a]=t[a];return n?s:t}function St(t){if(!t||!t.stops)return[];for(var e=[],n=0,r=t.stops.length;n<r;n++)e.push(t.stops[n][1]);return e}function Tt(t,e){if(!xt(t))return function(){return t};var n=!0,r=!0,i=(t=JSON.parse(JSON.stringify(t))).stops;if(i)for(var o=0;o<i.length;o++)if(xt(i[o][1])){var a=Tt(i[o][1],e);n=n&&a.isZoomConstant,r=r&&a.isFeatureConstant,i[o]=[i[o][0],a]}var s=function t(e,n){var r,i,o;if(xt(e)){var a,s=e.stops&&"object"==typeof e.stops[0][0],u=s||void 0!==e.property,c=s||!u,l=e.type||n||"exponential";if("exponential"===l)a=vt;else if("interval"===l)a=gt;else if("categorical"===l)a=mt;else{if("identity"!==l)throw new Error('Unknown function type "'+l+'"');a=yt}if(s){for(var h={},f=[],d=0;d<e.stops.length;d++){var p=e.stops[d];void 0===h[p[0].zoom]&&(h[p[0].zoom]={zoom:p[0].zoom,type:e.type,property:e.property,default:e.default,stops:[]}),h[p[0].zoom].stops.push([p[0].value,p[1]])}for(var m in h)f.push([h[m].zoom,t(h[m])]);r=function(t,n){var r=vt({stops:f,base:e.base},t)(t,n);return"function"==typeof r?r(t,n):r},i=!1,o=!1}else c?(r=function(t){var n=a(e,t);return"function"==typeof n?n(t):n},i=!0,o=!1):(r=function(t,n){var r=a(e,n?n[e.property]:null);return"function"==typeof r?r(t,n):r},i=!1,o=!0)}else r=function(){return e},i=!0,o=!0;return r.isZoomConstant=o,r.isFeatureConstant=i,r}(t,e);return s.isZoomConstant=n&&s.isZoomConstant,s.isFeatureConstant=r&&s.isFeatureConstant,s}var Et=Object.freeze({createFilter:rt,getFilterFeature:ft,compileStyle:dt,isFunctionDefinition:xt,hasFunctionDefinition:bt,interpolated:wt,piecewiseConstant:function(t){return Tt(t,"interval")},loadFunctionTypes:Mt,getFunctionTypeResources:St});function At(t){var e={stroke:{stroke:t.markerLineColor,"stroke-width":t.markerLineWidth,"stroke-opacity":t.markerLineOpacity,"stroke-dasharray":null,"stroke-linecap":"butt","stroke-linejoin":"round"},fill:{fill:t.markerFill,"fill-opacity":t.markerFillOpacity}};return 0===e.stroke["stroke-width"]&&(e.stroke["stroke-opacity"]=0),e}function Ct(t,e,n){if(!t.markerPath)return null;var r=1,i=At(t);m(t.markerOpacity)&&(r=t.markerOpacity),m(t.opacity)&&(r*=t.opacity);var o={};if(i){for(var a in i.stroke)i.stroke.hasOwnProperty(a)&&(p(i.stroke[a])||(o[a]=i.stroke[a]));for(var s in i.fill)i.fill.hasOwnProperty(s)&&(p(i.fill[s])||(o[s]=i.fill[s]))}for(var u,c=Array.isArray(t.markerPath)?t.markerPath:[t.markerPath],l=[],h=0;h<c.length;h++)(u=d({},u=y(c[h])?{path:c[h]}:c[h],o)).d=u.path,delete u.path,l.push(u);var f=['<svg version="1.1"','xmlns="http://www.w3.org/2000/svg"'];r<1&&f.push('opacity="'+r+'"'),t.markerPathWidth&&t.markerPathHeight&&f.push('viewBox="0 0 '+t.markerPathWidth+" "+t.markerPathHeight+'"'),f.push('preserveAspectRatio="none"'),e&&f.push('width="'+e+'"'),n&&f.push('height="'+n+'"'),f.push("><defs></defs>");for(var g=0;g<l.length;g++){var v="<path ";for(var _ in l[g])l[g].hasOwnProperty(_)&&(v+=" "+_+'="'+l[g][_]+'"');v+="></path>",f.push(v)}return f.push("</svg>"),"data:image/svg+xml;base64,"+J(f.join(" "))}function Pt(t,e){if(!t)return[];var n=t;Array.isArray(t)||(n=[t]);for(var r,i,o,a,c=[],l=s,h=n.length-1;h>=0;h--)if(t=n[h]){e&&(t=Lt(t));for(var f=0;f<l.length;f++)if(xt(r=t[l[f]])&&(r=St(r)),r){Array.isArray(r)||(r=[r]);for(var d=0;d<r.length;d++)"url("===r[d].slice(0,4)&&(r[d]=Y(r[d])),i=u[f],c.push([r[d],t[i[0]],t[i[1]]])}if("path"===t.markerType&&t.markerPath)if(o=xt(t.markerWidth)?200:t.markerWidth,a=xt(t.markerHeight)?200:t.markerHeight,xt(t.markerPath)){r=St(t.markerPath);for(var p=t.markerPath,m=0;m<r.length;m++)t.markerPath=r[m],c.push([Ct(t),o,a]);t.markerPath=p}else c.push([Ct(t),o,a])}return c}function Lt(t){if(!t)return null;var e=t;if(A)return e;for(var n,r=s,i=0,o=r.length;i<o;i++)(n=e[r[i]])&&(e[r[i]]=Ot(n));return e}function Ot(t){if(xt(t)){for(var e=t.stops,n=0;n<e.length;n++)e[n][1]=Ot(e[n][1]);return t}return"url("===t.slice(0,4)&&(t=Y(t)),t}function Rt(t){return t&&t.colorStops}function kt(t){var e=[t.type];if(t.places&&e.push(t.places.join()),t.colorStops){for(var n=[],r=t.colorStops.length-1;r>=0;r--)n.push(t.colorStops[r].join());e.push(n.join(","))}return e.join("_")}function It(t,e){function n(t,e){p(t.opacity)?t.opacity=e:t.opacity*=e}var r;if(Array.isArray(t)){r=[];for(var i=0;i<t.length;i++){var o=d({},t[i]);n(o,e),r.push(o)}}else n(r=d({},t),e);return r}function Dt(t){var e=Array.prototype.slice.call(arguments,1);if(e&&e.length||(e=[{}]),Array.isArray(t)){for(var n,r,i=[],o=0,a=t.length;o<a;o++){n=t[o],r={};for(var s=0,u=e.length;s<u;s++)Array.isArray(e[s])?p(e[s][o])?d(r,n||{}):d(r,n,e[s][o]):d(r,n,e[s]?e[s]:{});i.push(r)}return i}var c=[{},t];return c.push.apply(c,e),d.apply(this,c)}function jt(t){if(t.symbol&&(t=[t]),Array.isArray(t))return t;var e=t.$root,n=t.$iconset;return t=t.style,(e||n)&&(e&&"/"===e[e.length-1]&&(e=e.substring(0,e.length-1)),n&&"/"===n[n.length-1]&&(n=n.substring(0,n.length-1)),t=zt(t,(function(t){return"{$root}"===t?e:"{$iconset}"===t?n:null}))),t}function zt(t,e){for(var n=0;n<t.length;n++){var r=t[n].symbol;r&&Ft(r,e)}}var Nt=/(\{\$root\}|\{\$iconset\})/g;function Ft(t,e){for(var n in t)t.hasOwnProperty(n)&&"textName"!==n&&(y(t[n])&&t[n].length>2?t[n]=t[n].replace(Nt,e):xt(t[n])?t[n]=Bt(t[n],e):v(t[n])&&Ft(t[n],e))}function Bt(t,e){var n=t.default;y(n)&&(t.default=n.replace(Nt,e));for(var r=t.stops,i=0;i<r.length;i++)Array.isArray(r[i])&&(y(r[i][1])?r[i][1]=r[i][1].replace(Nt,e):xt(r[i][1])&&(r[i][1]=Bt(r[i][1],e)));return t}var Ht=Object.freeze({now:f,extend:d,isNil:p,isNumber:m,isInteger:g,isObject:v,isString:y,isFunction:_,hasOwn:b,join:function(t,e){return t.join?t.join(e||","):Array.prototype.join.call(t,e||",")},isEmpty:function(t){var e;for(e in t)return!1;return!e},toRadian:M,toDegree:S,IS_NODE:A,get requestAnimFrame(){return T},get cancelAnimFrame(){return E},isSVG:C,loadImage:P,UID:O,GUID:R,parseJSON:k,pushIn:I,removeFromArray:D,forEachCoord:j,getValueOrDefault:z,sign:N,log2:F,interpolate:B,wrap:H,clamp:G,isArrayHasData:U,isURL:function(t){return W.test(t)},isCssUrl:q,extractCssUrl:Y,btoa:J,b64toBlob:X,computeDegree:$,emptyImageUrl:Q,equalMapView:K,flash:et,_defaults:function(t,e){for(var n=Object.getOwnPropertyNames(e),r=0;r<n.length;r++){var i=n[r],o=Object.getOwnPropertyDescriptor(e,i);o&&o.configurable&&void 0===t[i]&&Object.defineProperty(t,i,o)}return t},translateToSVGStyles:At,getMarkerPathBase64:Ct,getExternalResources:Pt,convertResourceUrl:Lt,isGradient:Rt,getGradientStamp:kt,getSymbolStamp:function t(e){var n=[];if(Array.isArray(e)){for(var r=0;r<e.length;r++)n.push(t(e[r]));return"[ "+n.join(" , ")+" ]"}for(var i in e)b(e,i)&&(_(e[i])||(Rt(e[i])?n.push(i+"="+kt(e[i])):n.push(i+"="+e[i])));return n.join(";")},lowerSymbolOpacity:It,extendSymbol:Dt,parseStyleRootPath:jt,convertStylePath:zt}),Gt={};if(!A){var Ut=navigator.userAgent.toLowerCase(),Wt=document.documentElement,Vt="ActiveXObject"in window,Zt=-1!==Ut.indexOf("webkit"),qt=-1!==Ut.indexOf("phantom"),Yt=-1!==Ut.search("android [23]"),Jt=-1!==Ut.indexOf("chrome"),Xt=-1!==Ut.indexOf("gecko")&&!Zt&&!window.opera&&!Vt,$t="undefined"!=typeof orientation||-1!==Ut.indexOf("mobile"),Qt=!window.PointerEvent&&window.MSPointerEvent,Kt=window.PointerEvent&&navigator.pointerEnabled||Qt,te=Vt&&"transition"in Wt.style,ee="WebKitCSSMatrix"in window&&"m11"in new window.WebKitCSSMatrix&&!Yt,ne="MozPerspective"in Wt.style,re="OTransition"in Wt.style,ie=(te||ee||ne)&&!re&&!qt,oe=0;Jt&&(oe=Ut.match(/chrome\/([\d.]+)/)[1]);var ae,se=!qt&&(Kt||"ontouchstart"in window||window.DocumentTouch&&document instanceof window.DocumentTouch);try{var ue=document.createElement("canvas"),ce=ue.getContext("webgl")||ue.getContext("experimental-webgl");ae=ce&&ce instanceof WebGLRenderingContext}catch(t){ae=!1}var le=window.devicePixelRatio||window.screen.deviceXDPI/window.screen.logicalXDPI;Gt={ie:Vt,ielt9:Vt&&!document.addEventListener,edge:"msLaunchUri"in navigator&&!("documentMode"in document),webkit:Zt,gecko:Xt,android:-1!==Ut.indexOf("android"),android23:Yt,chrome:Jt,chromeVersion:oe,safari:!Jt&&-1!==Ut.indexOf("safari"),phantomjs:qt,ie3d:te,webkit3d:ee,gecko3d:ne,opera12:re,any3d:ie,mobile:$t,mobileWebkit:$t&&Zt,mobileWebkit3d:$t&&ee,mobileOpera:$t&&window.opera,mobileGecko:$t&&Xt,touch:!!se,msPointer:!!Qt,pointer:!!Kt,retina:le>1,devicePixelRatio:le,language:navigator.browserLanguage?navigator.browserLanguage:navigator.language,ie9:Vt&&9===document.documentMode,ie10:Vt&&10===document.documentMode,webgl:ae}}var he=Gt;function fe(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}function de(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}var pe=function(){function t(t,e){if(p(t)||p(e)?p(t.x)||p(t.y)?Array.isArray(t)&&(this.x=+t[0],this.y=+t[1]):(this.x=+t.x,this.y=+t.y):(this.x=+t,this.y=+e),this._isNaN())throw new Error("Position is NaN")}var e=t.prototype;return e.set=function(t,e){return this.x=t,this.y=e,this},e.abs=function(){return new this.constructor(Math.abs(this.x),Math.abs(this.y))},e._abs=function(){return this.x=Math.abs(this.x),this.y=Math.abs(this.y),this},e._round=function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this},e.round=function(){return new this.constructor(Math.round(this.x),Math.round(this.y))},e._ceil=function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this},e.ceil=function(){return new this.constructor(Math.ceil(this.x),Math.ceil(this.y))},e.distanceTo=function(t){var e=t.x-this.x,n=t.y-this.y;return Math.sqrt(e*e+n*n)},e._floor=function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this},e.floor=function(){return new this.constructor(Math.floor(this.x),Math.floor(this.y))},e.copy=function(){return new this.constructor(this.x,this.y)},e._add=function(t,e){return p(t.x)?p(t[0])?(this.x+=t,this.y+=e):(this.x+=t[0],this.y+=t[1]):(this.x+=t.x,this.y+=t.y),this},e.add=function(t,e){var n,r;return p(t.x)?p(t[0])?(n=this.x+t,r=this.y+e):(n=this.x+t[0],r=this.y+t[1]):(n=this.x+t.x,r=this.y+t.y),new this.constructor(n,r)},e._sub=function(t,e){return p(t.x)?p(t[0])?(this.x-=t,this.y-=e):(this.x-=t[0],this.y-=t[1]):(this.x-=t.x,this.y-=t.y),this},e._substract=function(){return this._sub.apply(this,arguments)},e.sub=function(t,e){var n,r;return p(t.x)?p(t[0])?(n=this.x-t,r=this.y-e):(n=this.x-t[0],r=this.y-t[1]):(n=this.x-t.x,r=this.y-t.y),new this.constructor(n,r)},e.substract=function(){return this.sub.apply(this,arguments)},e.multi=function(t){return new this.constructor(this.x*t,this.y*t)},e._multi=function(t){return this.x*=t,this.y*=t,this},e.div=function(t){return this.multi(1/t)},e._div=function(t){return this._multi(1/t)},e.equals=function(t){return t instanceof this.constructor&&this.x===t.x&&this.y===t.y},e._isNaN=function(){return isNaN(this.x)||isNaN(this.y)},e.isZero=function(){return 0===this.x&&0===this.y},e.toArray=function(){return[this.x,this.y]},e.toFixed=function(t){return new this.constructor(this.x.toFixed(t),this.y.toFixed(t))},e.toJSON=function(){return{x:this.x,y:this.y}},t}(),me=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.closeTo=function(t,e){return e||(e=0),this.x>=t.x-e&&this.x<=t.x+e&&this.y>=t.y-e&&this.y<=t.y+e},n.mag=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},n.unit=function(){return this.copy()._unit()},n._unit=function(){return this._div(this.mag()),this},n.perp=function(){return this.copy()._perp()},n._perp=function(){var t=this.y;return this.y=this.x,this.x=-t,this},n.angleWith=function(t){return this.angleWithSep(t.x,t.y)},n.angleWithSep=function(t,e){return Math.atan2(this.x*e-this.y*t,this.x*t+this.y*e)},n._rotate=function(t){var e=Math.cos(t),n=Math.sin(t),r=e*this.x-n*this.y,i=n*this.x+e*this.y;return this.x=r,this.y=i,this},n.rotate=function(t){return this.copy()._rotate(t)},e}(pe),ge=function(){function t(t,e){m(t)&&m(e)?(this.width=t,this.height=e):m(t.width)?(this.width=t.width,this.height=t.height):Array.isArray(t)&&(this.width=t[0],this.height=t[1])}var e=t.prototype;return e.copy=function(){return new t(this.width,this.height)},e.add=function(e,n){var r,i;return e instanceof t?(r=this.width+e.width,i=this.height+e.height):(r=this.width+e,i=this.height+n),new t(r,i)},e.equals=function(t){return this.width===t.width&&this.height===t.height},e.multi=function(e){return new t(this.width*e,this.height*e)},e._multi=function(t){return this.width*=t,this.height*=t,this},e._round=function(){return this.width=Math.round(this.width),this.height=Math.round(this.height),this},e.toPoint=function(){return new me(this.width,this.height)},e.toArray=function(){return[this.width,this.height]},e.toJSON=function(){return{width:this.width,height:this.height}},t}();function ve(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}var ye=/[\b\t\r\v\f]/gim;function _e(t){return y(t)?t.replace(ye,""):t}function xe(t){return ve(t).split(/\s+/)}var be="undefined"!=typeof document?document.createElement("canvas").getContext("2d"):null;function we(t,e){return we.node?we.node(t,e):(be.font=e,be.measureText(t).width)}function Me(t,e,n){var r=we(t,e);return new ge(r,n||h)}function Se(t,e,n,r){if(!t||0===t.length)return[{text:"",width:0}];var i=p(r)?we(t,e):r,o=i/t.length,a=Math.floor(n/o/2);if(o>=n||a<=0)return[{text:"",width:n}];if(i<=n)return[{text:t,width:i}];for(var s=[],u=t.substring(0,a),c=o*a,l=a,h=t.length;l<h;l++){var f=t[l],d=we(u+f);d>=n?(s.push({text:u,width:c}),u=t.substring(l,a+l),l+=a-1,c=o*a):(u+=f,c=d),l>=h-1&&(c=we(u),s.push({text:u,width:c}))}return s}var Te=/\{([\w_]+)\}/g;function Ee(t,e){return y(t)?t.replace(Te,(function(t,n){if(!e)return"";var r=e[n];return p(r)?"":Array.isArray(r)?r.join():r})):t}function Ae(t,e,n){var r=t.width,i=t.height;return new me("left"===e?-r:"right"===e?0:-r/2,"top"===n?-i:"bottom"===n?0:-i/2)}function Ce(t){return t.textFont?t.textFont:(t.textStyle&&"normal"!==t.textStyle?t.textStyle+" ":"")+(t.textWeight&&"normal"!==t.textWeight?t.textWeight+" ":"")+t.textSize+"px "+(t.textFaceName?'"'===t.textFaceName[0]?t.textFaceName:'"'+t.textFaceName+'"':"monospace")}function Pe(t,e){var n=Ce(e),r=e.textLineSpacing||0,i=Me(t,n,e.textSize),o=i.width,a=i.height,s=e.textWrapCharacter,u=[],c=e.textWrapWidth;(!c||c>o)&&(c=o),y(t)||(t+="");var l=0;if(s&&t.indexOf(s)>=0)for(var h=t.split(s),f=0,d=h.length;f<d;f++){var p=h[f],m=we(p,n);if(m>c)for(var g=Se(p,n,c,m),v=0,_=g.length;v<_;v++){var x=g[v].width;x>l&&(l=x),u.push({text:g[v].text,size:new ge(x,a)})}else m>l&&(l=m),u.push({text:p,size:new ge(m,a)})}else if(o>c)for(var b=Se(t,n,c,o),w=0;w<b.length;w++){var M=b[w].width;M>l&&(l=M),u.push({text:b[w].text,size:new ge(M,a)})}else o>l&&(l=o),u.push({text:t,size:i});var S=u.length;return{total:S,size:new ge(l,a*S+r*(S-1)),rows:u,rawSize:i}}var Le=Object.freeze({trim:ve,escapeSpecialChars:_e,splitWords:xe,stringWidth:we,stringLength:Me,getFontHeight:function(t){var e=nn("span");"_default_"!==t&&(e.style.font=t),e.innerHTML="秦";var n=e.clientHeight;return Ne(e),n},splitContent:Se,replaceVariable:Ee,getAlignPoint:Ae,getFont:Ce,splitTextToRow:Pe}),Oe=A?function(t){return t[0]}:function(t){for(var e=document.documentElement.style,n=0;n<t.length;n++)if(t[n]in e)return t[n];return!1},Re=Oe(["transform","WebkitTransform","OTransform","MozTransform","msTransform"]),ke=Oe(["transformOrigin","WebkitTransformOrigin","OTransformOrigin","MozTransformOrigin","msTransformOrigin"]),Ie=Oe(["transition","WebkitTransition","OTransition","MozTransition","msTransition"]),De=Oe(["filter","WebkitFilter","OFilter","MozFilter","msFilter"]);function je(t,e){var n=document.createElement(t);return e&&$e(n,e),n}function ze(t,e,n){var r=je(t);return e&&Ye(r,e),n&&n.appendChild(r),r}function Ne(t){if(!t)return this;if(he.ielt9||he.ie9){var e=je("div");e.appendChild(t),e.innerHTML="",e=null}else t.parentNode&&t.parentNode.removeChild(t);return this}function Fe(t,e,n,r){if(!(t&&t.addEventListener&&e&&n))return this;for(var i=function(e){e||(e=window.event),n.call(r||t,e)},o=e.split(" "),a=o.length-1;a>=0;a--){var s=o[a];s&&(t["Z__"+s]||(t["Z__"+s]=[]),He(t,s,n)>=0&&Be(t,s,n),t["Z__"+s].push({callback:i,src:n}),he.ie?t.addEventListener(s,i,!1):t.addEventListener(s,i,{capture:!1,passive:!1}))}return this}function Be(t,e,n){function r(e,n){"mousewheel"===e&&he.gecko&&(e="DOMMouseScroll"),t.removeEventListener(e,n,!1)}if(!t||!t.removeEventListener||!e)return this;for(var i=e.split(" "),o=i.length-1;o>=0;o--){var a=i[o];if(a){if(!n&&t["Z__"+a]){for(var s=t["Z__"+a],u=0,c=s.length;u<c;u++)r(s[u].callback);return delete t["Z__"+a],this}var l=He(t,a,n);if(l<0)return this;r(a,t["Z__"+a][l].callback),t["Z__"+a].splice(l,1)}}return this}function He(t,e,n){if(!t||!t["Z__"+e]||!n)return-1;for(var r=t["Z__"+e],i=0,o=r.length;i<o;i++)if(r[i].src===n)return i;return-1}function Ge(t){return t.preventDefault?t.preventDefault():t.returnValue=!1,this}function Ue(t){return t.stopPropagation?t.stopPropagation():t.cancelBubble=!0,this}function We(t){return t.onselectstart=function(){return!1},t.ondragstart=function(){return!1},t.setAttribute("unselectable","on"),this}function Ve(t,e){return t?(he.any3d?Ke(t,e):(t.style.left=e.x+"px",t.style.top=e.y+"px"),e):null}function Ze(t){var e=window.getComputedStyle(t),n=[parseInt(e["padding-left"]),parseInt(e["padding-top"])],r=t.getBoundingClientRect(),i=t.offsetWidth,o=t.offsetHeight,a=i?r.width/i:1,s=o?r.height/o:1;return t.__position=[r.left+n[0],r.top+n[1],a,s],t.__position}function qe(t,e){t||(t=window.event);var n=e.__position;return n||(n=Ze(e)),new me((t.clientX-n[0]-e.clientLeft)/n[2],(t.clientY-n[1]-e.clientTop)/n[3])}function Ye(t,e){var n=t.style.cssText;return function(t,e){var n=t.length-e.length;return n>=0&&t.indexOf(e,n)===n}(n,";")||(n+=";"),t.style.cssText=n+e,this}function Je(t,e){if(void 0!==t.classList)return t.classList.contains(e);var n=Qe(t);return n.length>0&&new RegExp("(^|\\s)"+e+"(\\s|$)").test(n)}function Xe(t,e){if(void 0===t.classList||Je(t,e)){var n=Qe(t);$e(t,(n?n+" ":"")+e)}else for(var r=xe(e),i=0,o=r.length;i<o;i++)t.classList.add(r[i]);return this}function $e(t,e){return p(t.className.baseVal)?t.className=e:t.className.baseVal=e,this}function Qe(t){return p(t.className.baseVal)?t.className:t.className.baseVal}function Ke(t,e){var n=e||new me(0,0);return t.style[Re]=he.any3d?"translate3d("+n.x+"px,"+n.y+"px,0px)":"translate("+n.x+"px,"+n.y+"px)",this}function tn(t){return/<[a-z\][\s\S]*>/i.test(t)}function en(t,e){var n=nn(t);y(e)?n.innerHTML=e:n.appendChild(e);var r=new ge(n.clientWidth,n.clientHeight);return Ne(n),r}function nn(t){var e=document.createElement(t);return e.style.cssText="position:absolute;left:-10000px;top:-10000px;",document.body.appendChild(e),e}var rn=Fe,on=Be,an=Object.freeze({TRANSFORM:Re,TRANSFORMORIGIN:ke,TRANSITION:Ie,CSSFILTER:De,createEl:je,createElOn:ze,removeDomNode:Ne,addDomEvent:Fe,removeDomEvent:Be,listensDomEvent:He,preventDefault:Ge,stopPropagation:Ue,preventSelection:We,offsetDom:Ve,computeDomPosition:Ze,getEventContainerPoint:qe,setStyle:Ye,hasClass:Je,addClass:Xe,setClass:$e,getClass:Qe,setOpacity:function(t,e){return t.style.opacity=e,this},setTransform:Ke,setTransformMatrix:function(t,e){var n="matrix("+(y(e)?e:e.join())+")";return t.style[Re]!==n&&(t.style[Re]=n),this},removeTransform:function(t){return t.style[Re]&&(t.style[Re]=""),this},isHTML:tn,measureDom:en,getDomRuler:nn,on:rn,off:on}),sn={jsonp:function(t,e){var n="_maptalks_jsonp_"+O();t.match(/\?/)?t+="&callback="+n:t+="?callback="+n;var r=document.createElement("script");return r.type="text/javascript",r.src=t,window[n]=function(t){e(null,t),document.getElementsByTagName("head")[0].removeChild(r),r=null,delete window[n]},document.getElementsByTagName("head")[0].appendChild(r),this},get:function(t,e,n){if(_(e)){var r=n;n=e,e=r}if(A&&sn.get.node)return sn.get.node(t,n,e);var i=sn._getClient(n);if(i.open("GET",t,!0),e){for(var o in e.headers)i.setRequestHeader(o,e.headers[o]);i.withCredentials="include"===e.credentials,e.responseType&&(i.responseType=e.responseType)}return i.send(null),i},post:function(t,e,n){var r;if(y(t)){if(_(e)){var i=n;n=e,e=i}r=(e=e||{}).postData}else{var o=n;r=e,t=(e=t).url,n=o}if(A&&sn.post.node)return e.url=t,sn.post.node(e,r,n);var a=sn._getClient(n);if(a.open("POST",e.url,!0),e.headers||(e.headers={}),e.headers["Content-Type"]||(e.headers["Content-Type"]="application/x-www-form-urlencoded"),"setRequestHeader"in a)for(var s in e.headers)e.headers.hasOwnProperty(s)&&a.setRequestHeader(s,e.headers[s]);return y(r)||(r=JSON.stringify(r)),a.send(r),a},_wrapCallback:function(t,e){return function(){4===t.readyState&&(200===t.status?"arraybuffer"===t.responseType?0===t.response.byteLength?e(new Error("http status 200 returned without content.")):e(null,{data:t.response,cacheControl:t.getResponseHeader("Cache-Control"),expires:t.getResponseHeader("Expires"),contentType:t.getResponseHeader("Content-Type")}):e(null,t.responseText):e(new Error(t.statusText+","+t.status)))}},_getClient:function(t){var e;try{e=new XMLHttpRequest}catch(t){try{e=new ActiveXObject("Msxml2.XMLHTTP")}catch(t){try{e=new ActiveXObject("Microsoft.XMLHTTP")}catch(t){}}}return e.onreadystatechange=sn._wrapCallback(e,t),e},getArrayBuffer:function(t,e,n){if(_(e)){var r=n;n=e,e=r}return e||(e={}),e.responseType="arraybuffer",sn.get(t,e,n)},getImage:function(t,e,n){return sn.getArrayBuffer(e,n,(function(e,n){if(e)t.onerror&&t.onerror(e);else if(n){var r=window.URL||window.webkitURL,i=t.onload;t.onload=function(){i&&i(),r.revokeObjectURL(t.src)};var o=new Blob([new Uint8Array(n.data)],{type:n.contentType});t.cacheControl=n.cacheControl,t.expires=n.expires,t.src=n.data.byteLength?r.createObjectURL(o):Q}}))},getJSON:function(t,e,n){if(_(e)){var r=n;n=e,e=r}var i=function(t,e){var r=e?k(e):null;n(t,r)};return e&&e.jsonp?sn.jsonp(t,i):sn.get(t,e,i)}},un=!1,cn=null,ln=Math.PI/180,hn={setHitTesting:function(t){un=t},createCanvas:function(t,e,n){var r;return A?r=new n(t,e):((r=je("canvas")).width=t,r.height=e),r},prepareCanvasFont:function(t,e){t.textBaseline="top",t.font=Ce(e);var n=e.textFill;n||(n="#000"),t.fillStyle=hn.getRgba(n,e.textOpacity)},prepareCanvas:function(t,e,n,r){if(e){var i=e.lineWidth;p(i)||t.lineWidth===i||(t.lineWidth=i);var o=e.linePatternFile,a=e.lineColor||"#000";if(r)t.strokeStyle="#000";else if(o&&n){var s;(e.linePatternDx||e.linePatternDy)&&(s=[e.linePatternDx,e.linePatternDy]),hn._setStrokePattern(t,o,i,s,n),e.lineDasharray=[]}else Rt(a)?e.lineGradientExtent?t.strokeStyle=hn._createGradient(t,a,e.lineGradientExtent):t.strokeStyle="#000":t.strokeStyle=a;e.lineJoin&&(t.lineJoin=e.lineJoin),e.lineCap&&(t.lineCap=e.lineCap),t.setLineDash&&U(e.lineDasharray)&&t.setLineDash(e.lineDasharray);var u=e.polygonPatternFile,c=e.polygonFill||"rgba(255,255,255,0)";if(r)t.fillStyle="#000";else if(u&&n){var l=pn(u),h=n.getImage([l,null,null]);if(h||(h=n.getImage([l+"-texture",null,i])),C(l)&&h instanceof Image&&(he.edge||he.ie)){var f=h.width||20,d=h.height||20,m=hn.createCanvas(f,d);hn.image(m.getContext("2d"),h,0,0,f,d),h=m}h?(t.fillStyle=t.createPattern(h,"repeat"),(e.polygonPatternDx||e.polygonPatternDy)&&(t.fillStyle.polygonPatternOffset=[e.polygonPatternDx,e.polygonPatternDy])):"undefined"!=typeof console&&console.warn("img not found for",l)}else Rt(c)?e.polygonGradientExtent?t.fillStyle=hn._createGradient(t,c,e.polygonGradientExtent):t.fillStyle="rgba(255,255,255,0)":t.fillStyle=c}},_createGradient:function(t,e,n){var r=null,i=e.places,o=n.getMin(),a=n.getMax(),s=n.getWidth(),u=n.getHeight();if(e.type&&"linear"!==e.type){if("radial"===e.type){if(i){if(6!==i.length)throw new Error("A radial gradient's places should have 6 numbers.");i=[o.x+i[0]*s,o.y+i[1]*u,s*i[2],o.x+i[3]*s,o.y+i[4]*u,s*i[5]]}else{var c=n.getCenter()._round();i=[c.x,c.y,Math.abs(c.x-o.x),c.x,c.y,0]}r=t.createRadialGradient.apply(t,i)}}else{if(i){if(4!==i.length)throw new Error("A linear gradient's places should have 4 numbers.");i=[o.x+i[0]*s,o.y+i[1]*u,o.x+i[2]*s,o.y+i[3]*u]}else i=[o.x,o.y,a.x,o.y];r=t.createLinearGradient.apply(t,i)}return e.colorStops.forEach((function(t){r.addColorStop.apply(r,t)})),r},_setStrokePattern:function(t,e,n,r,i){var o,a=pn(e);if(A)o=i.getImage([a,null,n]);else{var s=a+"-texture-"+n;if(!(o=i.getImage(s))){var u=i.getImage([a,null,null]);if(u){var c;c=u.width&&u.height?Math.round(u.width*n/u.height):n;var l=hn.createCanvas(c,n,t.canvas.constructor);hn.image(l.getContext("2d"),u,0,0,c,n),i.addResource([s,null,n],l),o=l}}}o?(t.strokeStyle=t.createPattern(o,"repeat"),t.strokeStyle.linePatternOffset=r):"undefined"!=typeof console&&console.warn("img not found for",a)},clearRect:function(t,e,n,r,i){t.canvas._drawn=!1,t.clearRect(e,n,r,i)},fillCanvas:function(t,e,n,r){if(un&&(e=1),t.canvas._drawn=!0,0!==e){var i,o=hn._isPattern(t.fillStyle),a=t.fillStyle&&t.fillStyle.polygonPatternOffset,s=a?a[0]:0,u=a?a[1]:0;p(e)&&(e=1),e<1&&(i=t.globalAlpha,t.globalAlpha*=e),o&&(n=n||0,r=r||0,t.translate(n+s,r+u)),t.fill(),o&&t.translate(-n-s,-r-u),e<1&&(t.globalAlpha=i)}},getRgba:function(t,e){return p(e)&&(e=1),"#"!==t[0]?t:(7===t.length?(n=parseInt(t.substring(1,3),16),r=parseInt(t.substring(3,5),16),i=parseInt(t.substring(5,7),16)):(n=17*parseInt(t.substring(1,2),16),r=17*parseInt(t.substring(2,3),16),i=17*parseInt(t.substring(3,4),16)),"rgba("+n+","+r+","+i+","+e+")");var n,r,i},image:function(t,e,n,r,i,o){t.canvas._drawn=!0;try{m(i)&&m(o)?t.drawImage(e,n,r,i,o):t.drawImage(e,n,r)}catch(t){console&&(console.warn("error when drawing image on canvas:",t),console.warn(e))}},text:function(t,e,n,r,i){hn._textOnMultiRow(t,i.rows,r,n,i.size,i.rawSize)},_textOnMultiRow:function(t,e,n,r,i,o){for(var a,s,u=Ae(i,n.textHorizontalAlignment,n.textVerticalAlignment),c=o.height+n.textLineSpacing,l=r.add(0,u.y),h=n.textMaxHeight,f=0,d=0,p=e.length;d<p&&(a=e[d].text,s=Ae(e[d].size,n.textHorizontalAlignment,n.textVerticalAlignment),hn._textOnLine(t,a,l.add(s.x,d*c),n.textHaloRadius,n.textHaloFill,n.textHaloOpacity),!(h>0&&(f+=c,f+o.height>=h)));d++);},_textOnLine:function(t,e,n,r,i,o){un&&(o=1);var a,s,u=0!==o&&0!==r;t.textBaseline="top";var c=t.shadowBlur,l=t.shadowOffsetX,h=t.shadowOffsetY;if(u){var f=t.globalAlpha;t.globalAlpha*=o,t.miterLimit=2,t.lineJoin="round",t.lineCap="round",t.lineWidth=2*r,t.strokeStyle=i,t.strokeText(e,n.x,n.y+1),t.miterLimit=10,t.globalAlpha=f,a=t.globalCompositeOperation,t.globalCompositeOperation="destination-out",s=t.fillStyle,t.fillStyle="#000"}c&&u&&(t.shadowBlur=t.shadowOffsetX=t.shadowOffsetY=0),hn.fillText(t,e,n),a&&(t.globalCompositeOperation=a,hn.fillText(t,e,n,s),c&&(t.shadowBlur=c,t.shadowOffsetX=l,t.shadowOffsetY=h))},fillText:function(t,e,n,r){t.canvas._drawn=!0,r&&(t.fillStyle=r),t.fillText(e,n.x,n.y+1)},_stroke:function(t,e,n,r){if(un&&(e=1),t.canvas._drawn=!0,0!==e){var i,o=t.strokeStyle&&t.strokeStyle.linePatternOffset,a=o?o[0]:0,s=o?o[1]:0,u=hn._isPattern(t.strokeStyle)&&(!p(n)&&!p(r)||!p(a)&&!p(s));p(e)&&(e=1),e<1&&(i=t.globalAlpha,t.globalAlpha*=e),u&&(n=n||0,r=r||0,t.translate(n+a,r+s)),t.stroke(),u&&t.translate(-n-a,-r-s),e<1&&(t.globalAlpha=i)}},_path:function(t,e,n,r,i){if(U(e))for(var o,a,s=U(n),u=!0!==i&&hn._isPattern(t.strokeStyle),c=0,l=e.length;c<l;c++)if(o=e[c],!s||t.setLineDash)t.lineTo(o.x,o.y),u&&c>0&&(h(e[c-1],o),t.beginPath(),t.moveTo(o.x,o.y));else if(s){if(c===l-1)break;a=e[c+1],fn(t,o,a,n)}function h(e,n){var i=$(e.x,e.y,n.x,n.y);t.save();var o=Math.cos(i);Math.abs(o)<1e-7?t.translate(e.x-t.lineWidth/2,e.y):t.translate(e.x,e.y-t.lineWidth/2/o),t.rotate(i),hn._stroke(t,r),t.restore()}},path:function(t,e,n,r,i){U(e)&&(t.beginPath(),t.moveTo(e[0].x,e[0].y),hn._path(t,e,i,n),hn._stroke(t,n))},_multiClip:function(t,e){if(e&&0!==e.length)for(var n=0,r=(e=e[0]).length;n<r;n++){var i=e[n],o=i.x,a=i.y;0===n?t.moveTo(o,a):t.lineTo(o,a),n===r-1&&(o=e[0].x,a=e[0].y,t.lineTo(o,a))}},polygon:function(t,e,n,r,i,o){if(t.isMultiClip)hn._multiClip(t,e);else if(U(e)){var a=hn._isPattern(t.strokeStyle),s=U(i)&&!t.setLineDash||a&&!o;U(e[0])||(e=[e]);var u,c,l,h=t;if(e.length>1&&!A&&(cn||(cn=hn.createCanvas(1,1)),t.canvas._drawn=!1,cn.width=t.canvas.width,cn.height=t.canvas.height,mn(t=cn.getContext("2d"),h)),s){for(t.save(),c=0,l=e.length;c<l;c++)U(e[c])&&(hn._ring(t,e[c],null,0,!0),u=r,c>0&&(t.globalCompositeOperation="destination-out",u=1),hn.fillCanvas(t,u,e[c][0].x,e[c][0].y),c>0?t.globalCompositeOperation="source-over":l>1&&(t.fillStyle="#fff"),hn._stroke(t,0));t.restore()}for(c=0,l=e.length;c<l;c++)U(e[c])&&(o?(hn.paintSmoothLine(t,e[c],n,o,!0),t.closePath()):hn._ring(t,e[c],i,n),s||(u=r,c>0&&(t.globalCompositeOperation="destination-out",u=1),hn.fillCanvas(t,u,e[c][0].x,e[c][0].y),c>0?t.globalCompositeOperation="source-over":l>1&&(t.fillStyle="#fff")),hn._stroke(t,n));e.length>1&&!A&&(h.drawImage(cn,0,0),h.canvas._drawn=t.canvas._drawn,mn(h,t))}},_ring:function(t,e,n,r,i){var o=hn._isPattern(t.strokeStyle);i||!o||e[0].equals(e[e.length-1])||(e=e.concat([e[0]])),t.beginPath(),t.moveTo(e[0].x,e[0].y),hn._path(t,e,n,r,i),o||t.closePath()},paintSmoothLine:function(t,e,n,r,i,o,a){if(e)if(e.length<=2||!r)hn.path(t,e,n);else{var s,u=e.length,c=i?u:u-1;t.beginPath(),t.moveTo(e[0].x,e[0].y),void 0!==a&&(c-=Math.max(c-o-1,0));for(var l=0;l<c;l++){var h=e[l].x,f=e[l].y,d=void 0,p=void 0,m=void 0,g=void 0,v=void 0,y=void 0;l-1<0?i?(d=e[c-1].x,p=e[c-1].y):(d=e[l+1].x,p=e[l+1].y):(d=e[l-1].x,p=e[l-1].y),l+1<u?(m=e[l+1].x,g=e[l+1].y):(m=e[l+1-u].x,g=e[l+1-u].y),l+2<u?(v=e[l+2].x,y=e[l+2].y):i?(v=e[l+2-u].x,y=e[l+2-u].y):(v=e[l].x,y=e[l].y);var _=b(d,p,h,f,m,g,v,y,r,l===c-1?a:1);if(l===c-1&&a>=0&&a<1){t.bezierCurveTo(_[0],_[1],_[2],_[3],_[4],_[5]),e.splice(c-1,u-(c-1)-1);var x=new me(_[4],_[5]);x.prevCtrlPoint=new me(_[2],_[3]),e.push(x),u=e.length}else t.bezierCurveTo(_[0],_[1],_[2],_[3],m,g);e[l].nextCtrlPoint=_.slice(0,2),e[l].prevCtrlPoint=s?s.slice(2):null,s=_}!i&&e[1].prevCtrlPoint&&(e[0].nextCtrlPoint=e[1].prevCtrlPoint,delete e[0].prevCtrlPoint),e[u-1].prevCtrlPoint||(e[u-1].prevCtrlPoint=e[u-2].nextCtrlPoint),hn._stroke(t,n)}function b(t,e,n,r,i,o,a,s,u,c){var l=(t+n)/2,h=(e+r)/2,f=(n+i)/2,d=(r+o)/2,p=(i+a)/2,m=(o+s)/2,g=Math.sqrt((n-t)*(n-t)+(r-e)*(r-e)),v=Math.sqrt((i-n)*(i-n)+(o-r)*(o-r)),y=g/(g+v),_=v/(v+Math.sqrt((a-i)*(a-i)+(s-o)*(s-o))),x=l+(f-l)*y,b=h+(d-h)*y,w=f+(p-f)*_,M=d+(m-d)*_,S=x+(f-x)*u+n-x,T=b+(d-b)*u+r-b,E=w+(f-w)*u+i-w,A=M+(d-M)*u+o-M,C=[S,T,E,A];return c<1?function(t,e,n,r,i,o,a,s,u,c){var l=1-t,h=1-e,f=n*h*h+2*i*e*h+a*e*e,d=i*h*h+2*a*e*h+u*e*e,p=r*h*h+2*o*e*h+s*e*e,m=o*h*h+2*s*e*h+c*e*e;return[(n*l*l+2*i*t*l+a*t*t)*h+(i*l*l+2*a*t*l+u*t*t)*e,(r*l*l+2*o*t*l+s*t*t)*h+(o*l*l+2*s*t*l+c*t*t)*e,f*l+d*t,p*l+m*t,f*h+d*e,p*h+m*e]}(0,c,n,r,S,T,E,A,i,o):C}},_arcBetween:function(t,e,n,r){var i=r,o=e.distanceTo(n),a=o/2/Math.sin(i/2),s=Math.asin((n.y-e.y)/o);e.x>n.x&&(s=Math.PI-s);var u=s-(90*ln-i/2),c=Math.cos(u)*a,l=Math.sin(u)*a,h=e.x+c,f=e.y+l,d=Math.asin((n.y-f)/a);h>n.x&&(d=Math.PI-d);var p=d+i;return t.beginPath(),t.arc(h,f,a,d,p),[h,f]},_lineTo:function(t,e){t.lineTo(e.x,e.y)},bezierCurveAndFill:function(t,e,n,r){t.beginPath();var i=e[0];t.moveTo(i.x,i.y);var o=[t];o.push.apply(o,e.splice(1)),hn._bezierCurveTo.apply(hn,o),hn.fillCanvas(t,r),hn._stroke(t,n)},_bezierCurveTo:function(t,e,n,r){t.bezierCurveTo(e.x,e.y,n.x,n.y,r.x,r.y)},ellipse:function(t,e,n,r,i,o,a){t.beginPath(),n===r&&n===i?t.arc(e.x,e.y,n,0,2*Math.PI):t.ellipse?r!==i?(t.ellipse(e.x,e.y,n,r,0,180*ln,360*ln,!1),t.ellipse(e.x,e.y,n,i,0,0,180*ln,!1)):t.ellipse(e.x,e.y,n,r,0,0,360*ln,!1):function(e,n,r,i,o){var a=.5522848,s=r*a,u=i*a,c=o*a;t.moveTo(e-r,n),t.bezierCurveTo(e-r,n-u,e-s,n-i,e,n-i),t.bezierCurveTo(e+s,n-i,e+r,n-u,e+r,n),t.bezierCurveTo(e+r,n+c,e+s,n+o,e,n+o),t.bezierCurveTo(e-s,n+o,e-r,n+c,e-r,n),t.closePath()}(e.x,e.y,n,r,i),hn.fillCanvas(t,a,e.x-n,e.y-r),hn._stroke(t,o,e.x-n,e.y-r)},rectangle:function(t,e,n,r,i){var o=e.x,a=e.y;t.beginPath(),t.rect(o,a,n.width,n.height),hn.fillCanvas(t,i,o,a),hn._stroke(t,r,o,a)},sector:function(t,e,n,r,i,o){var a=ln,s=r[0],u=r[1];!function(t,e,n,r,s,u){var c=a*-u,l=a*-s;t.beginPath(),t.moveTo(e,n),t.arc(e,n,r,c,l),t.lineTo(e,n),hn.fillCanvas(t,o,e-r,n-r),hn._stroke(t,i,e-r,n-r)}(t,e.x,e.y,n,s,u)},_isPattern:function(t){return!y(t)&&!("addColorStop"in t)},drawCross:function(t,e,n,r,i){t.canvas._drawn=!0,t.strokeStyle=i,t.lineWidth=r,t.beginPath(),t.moveTo(e-5,n),t.lineTo(e+5,n),t.moveTo(e,n-5),t.lineTo(e,n+5),t.stroke()},copy:function(t,e){var n=e||je("canvas");return n.width=t.width,n.height=t.height,n.getContext("2d").drawImage(t,0,0),n}};function fn(t,e,n,r){var i=e.x,o=e.y,a=n.x,s=n.y,u=r,c=function(t,e){return t<=e},l=function(t,e){return t>=e},h=function(t,e){return Math.min(t,e)},f=function(t,e){return Math.max(t,e)},d={thereYet:l,cap:h},p={thereYet:l,cap:h};o-s>0&&(p.thereYet=c,p.cap=f),i-a>0&&(d.thereYet=c,d.cap=f),t.moveTo(i,o);for(var m,g,v=i,y=o,_=0,x=!0;!d.thereYet(v,a)||!p.thereYet(y,s);)m=Math.atan2(s-o,a-i),g=u[_],v=d.cap(a,v+Math.cos(m)*g),y=p.cap(s,y+Math.sin(m)*g),x?t.lineTo(v,y):t.moveTo(v,y),_=(_+1)%u.length,x=!x}var dn="data:image/";function pn(t){return t.substring(0,dn.length)===dn?t:Y(t)}function mn(t,e){t.filter=e.filter,t.fillStyle=e.fillStyle,t.globalAlpha=e.globalAlpha,t.lineCap=e.lineCap,t.lineDashOffset=e.lineDashOffset,t.lineJoin=e.lineJoin,t.lineWidth=e.lineWidth,t.shadowBlur=e.shadowBlur,t.shadowColor=e.shadowColor,t.shadowOffsetX=e.shadowOffsetX,t.shadowOffsetY=e.shadowOffsetY,t.strokeStyle=e.strokeStyle}var gn="undefined"!=typeof window?window:void 0!==r?r:"undefined"!=typeof self?self:{};function vn(t,e){return t(e={exports:{}},e.exports),e.exports}var yn=vn((function(t){!function(e){function n(t){if(t){var e=this;t((function(t){e.resolve(t)}),(function(t){e.reject(t)}))}}function r(t,e){if("function"==typeof t.y)try{var n=t.y.call(a,e);t.p.resolve(n)}catch(e){t.p.reject(e)}else t.p.resolve(e)}function i(t,e){if("function"==typeof t.n)try{var n=t.n.call(a,e);t.p.resolve(n)}catch(e){t.p.reject(e)}else t.p.reject(e)}var o,a,s="fulfilled",u="undefined",c=function(){function t(){for(;n.length-r;){try{n[r]()}catch(t){e.console&&e.console.error(t)}n[r++]=a,r==i&&(n.splice(0,i),r=0)}}var n=[],r=0,i=1024,o=function(){if(typeof MutationObserver!==u){var e=document.createElement("div");return new MutationObserver(t).observe(e,{attributes:!0}),function(){e.setAttribute("a",0)}}return typeof setImmediate!==u?function(){setImmediate(t)}:function(){setTimeout(t,0)}}();return function(t){n.push(t),n.length-r==1&&o()}}();n.prototype={resolve:function(t){if(this.state===o){if(t===this)return this.reject(new TypeError("Attempt to resolve promise with self"));var e=this;if(t&&("function"==typeof t||"object"==typeof t))try{var n=!0,i=t.then;if("function"==typeof i)return void i.call(t,(function(t){n&&(n=!1,e.resolve(t))}),(function(t){n&&(n=!1,e.reject(t))}))}catch(t){return void(n&&this.reject(t))}this.state=s,this.v=t,e.c&&c((function(){for(var n=0,i=e.c.length;i>n;n++)r(e.c[n],t)}))}},reject:function(t){if(this.state===o){this.state="rejected",this.v=t;var r=this.c;r?c((function(){for(var e=0,n=r.length;n>e;e++)i(r[e],t)})):!n.suppressUncaughtRejectionError&&e.console&&e.console.log("You upset Zousan. Please catch rejections: ",t,t?t.stack:null)}},then:function(t,e){var a=new n,u={y:t,n:e,p:a};if(this.state===o)this.c?this.c.push(u):this.c=[u];else{var l=this.state,h=this.v;c((function(){l===s?r(u,h):i(u,h)}))}return a},catch:function(t){return this.then(null,t)},finally:function(t){return this.then(t,t)},timeout:function(t,e){e=e||"Timeout";var r=this;return new n((function(n,i){setTimeout((function(){i(Error(e))}),t),r.then((function(t){n(t)}),(function(t){i(t)}))}))}},n.resolve=function(t){var e=new n;return e.resolve(t),e},n.reject=function(t){var e=new n;return e.reject(t),e},n.all=function(t){function e(e,a){e&&"function"==typeof e.then||(e=n.resolve(e)),e.then((function(e){r[a]=e,++i==t.length&&o.resolve(r)}),(function(t){o.reject(t)}))}for(var r=[],i=0,o=new n,a=0;a<t.length;a++)e(t[a],a);return t.length||o.resolve(r),o},t.exports&&(t.exports=n),e.define&&e.define.amd&&e.define([],(function(){return n})),e.Zousan=n,n.soon=c}(gn)})),_n="undefined"!=typeof Promise?Promise:yn,xn=function(t){return function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.on=function(t,e,n){if(!t)return this;if(!y(t))return this._switch("on",t,e);if(!e)return this;this._eventMap||(this._eventMap={});var r,i,o=t.toLowerCase().split(" ");n||(n=this);for(var a=0,s=o.length;a<s;a++){r=o[a],(i=this._eventMap[r])||(i=[],this._eventMap[r]=i);var u=i.length;if(u>0)for(var c=0;c<u;c++)if(e===i[c].handler&&i[c].context===n)return this;i.push({handler:e,context:n})}return this},n.addEventListener=function(){return this.on.apply(this,arguments)},n.once=function(t,e,n){if(!y(t)){var r={};for(var i in t)t.hasOwnProperty(i)&&(r[i]=this._wrapOnceHandler(i,t[i],n));return this._switch("on",r)}for(var o=t.split(" "),a=0,s=o.length;a<s;a++)this.on(o[a],this._wrapOnceHandler(o[a],e,n));return this},n.off=function(t,e,n){if(!this._eventMap||!t)return this;if(!y(t))return this._switch("off",t,e);if(!e)return this;var r,i,o,a=t.split(" ");n||(n=this);for(var s=0,u=a.length;s<u;s++){if(o="Z__"+(r=a[s].toLowerCase()),!(i=this._eventMap[r]))return this;for(var c=i.length-1;c>=0;c--){var l=i[c];e!==l.handler&&e!==l.handler[o]||l.context!==n||(delete l.handler[o],i.splice(c,1))}i.length||delete this._eventMap[r]}return this},n.removeEventListener=function(){return this.off.apply(this,arguments)},n.listens=function(t,e,n){if(!this._eventMap||!y(t))return 0;var r=this._eventMap[t.toLowerCase()];if(!r||!r.length)return 0;if(!e)return r.length;for(var i=0,o=r.length;i<o;i++)if(e===r[i].handler&&(p(n)||r[i].context===n))return 1;return 0},n.getListeningEvents=function(){return this._eventMap?Object.keys(this._eventMap):[]},n.copyEventListeners=function(t){var e,n=t._eventMap;if(!n)return this;for(var r in n)for(var i=0,o=(e=n[r]).length;i<o;i++)this.on(r,e[i].handler,e[i].context);return this},n.fire=function(){return this._eventParent?this._eventParent.fire.apply(this._eventParent,arguments):this._fire.apply(this,arguments)},n._wrapOnceHandler=function(t,e,n){var r=this,i="Z__"+t,o=!1,a=function s(){o||(delete a[i],o=!0,n?e.apply(n,arguments):e.apply(this,arguments),r.off(t,s,this))};return a[i]=e,a},n._switch=function(t,e,n){for(var r in e)e.hasOwnProperty(r)&&this[t](r,e[r],n);return this},n._clearListeners=function(t){this._eventMap&&y(t)&&this._eventMap[t.toLowerCase()]&&(this._eventMap[t]=null)},n._clearAllListeners=function(){this._eventMap=null},n._setEventParent=function(t){return this._eventParent=t,this},n._setEventTarget=function(t){return this._eventTarget=t,this},n._fire=function(t,e){if(!this._eventMap)return this;var n=this._eventMap[t.toLowerCase()];if(!n)return this;e||(e={}),e.type=t,e.target=this._eventTarget||this;for(var r,i,o=n.slice(0),a=0,s=o.length;a<s;a++)o[a]&&(r=o[a].context,i=d({},e),!1===(r?o[a].handler.call(r,i):o[a].handler(i))&&e.domEvent&&Ue(e.domEvent));return this},e}(t)},bn=function(){function t(t){this.target=t}var e=t.prototype;return e.enable=function(){return this._enabled||(this._enabled=!0,this.addHooks()),this},e.disable=function(){return this._enabled?(this._enabled=!1,this.removeHooks(),this):this},e.enabled=function(){return!!this._enabled},e.remove=function(){this.disable(),delete this.target,delete this.dom},t}(),wn=xn(bn),Mn=function(){function t(t){if(!this||!this.setOptions)throw new Error('Class instance is being created without "new" operator.');this.setOptions(t),this.callInitHooks()}var e=t.prototype;return e.callInitHooks=function(){var t=Object.getPrototypeOf(this);return this._visitInitHooks(t),this},e.setOptions=function(t){if(this.hasOwnProperty("options")||(this.options=this.options?Object.create(this.options):{}),!t)return this;for(var e in t)this.options[e]=t[e];return this},e.config=function(t){if(!t){var e={};for(var n in this.options)this.options.hasOwnProperty(n)&&(e[n]=this.options[n]);return e}if(2===arguments.length){var r={};r[t]=arguments[1],t=r}for(var i in t)this.options[i]=t[i],this[i]&&this[i]instanceof wn&&(t[i]?this[i].enable():this[i].disable());return this.onConfig(t),this},e.onConfig=function(){},e._visitInitHooks=function(t){if(!this._initHooksCalled){var e=Object.getPrototypeOf(t);e._visitInitHooks&&e._visitInitHooks.call(this,e),this._initHooksCalled=!0;var n=t._initHooks;if(n&&n!==e._initHooks)for(var r=0;r<n.length;r++)n[r].call(this)}},t.addInitHook=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];var i="function"==typeof t?t:function(){this[t].apply(this,n)},o=this.prototype,a=Object.getPrototypeOf(o);return o._initHooks&&o._initHooks!==a._initHooks||(o._initHooks=[]),o._initHooks.push(i),this},t.include=function(){for(var t=0;t<arguments.length;t++)d(this.prototype,t<0||arguments.length<=t?void 0:arguments[t]);return this},t.mergeOptions=function(t){var e=this.prototype,n=Object.getPrototypeOf(e);return e.options&&e.options!==n.options||(e.options=e.options?Object.create(e.options):{}),d(e.options,t),this},t}(),Sn={},Tn=function(t){return function(t){function e(){return t.apply(this,arguments)||this}return fe(e,t),e.registerJSONType=function(t){return t?(Sn[t]=this,this):this},e.getJSONClass=function(t){return t?Sn[t]:null},e.prototype.getJSONType=function(){if(void 0===this._jsonType){var t=Object.getPrototypeOf(this).constructor;for(var e in Sn)if(Sn[e]===t){this._jsonType=e;break}}if(!this._jsonType)throw new Error("Found an unregistered geometry class!");return this._jsonType},e}(t)};function En(t){return function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.addHandler=function(t,e){if(!e)return this;if(this._handlers||(this._handlers=[]),this[t])return this[t].enable(),this;var n=this[t]=new e(this);return this._handlers.push(n),this.options[t]&&n.enable(),this},n.removeHandler=function(t){if(!t)return this;var e=this[t];if(e){var n=this._handlers.indexOf(e);n>=0&&this._handlers.splice(n,1),this[t].remove(),delete this[t]}return this},n._clearHandlers=function(){for(var t=0,e=this._handlers.length;t<e;t++)this._handlers[t].remove();this._handlers=[]},e}(t)}var An="touchstart mousedown",Cn={mousedown:"mousemove",touchstart:"touchmove",pointerdown:"touchmove",MSPointerDown:"touchmove"},Pn={mousedown:"mouseup",touchstart:"touchend",pointerdown:"touchend",MSPointerDown:"touchend"},Ln=function(t){function e(e,n){var r;return void 0===n&&(n={}),(r=t.call(this,null)||this).dom=e,r.options=n,r}fe(e,t);var n=e.prototype;return n.enable=function(){return this.dom?(this._onMouseDown=function(t){return this.onMouseDown(t)},rn(this.dom,An,this._onMouseDown,this),this):this},n.disable=function(){return this.dom?(this._offEvents(),on(this.dom,An,this._onMouseDown),delete this._onMouseDown,this):this},n.onMouseDown=function(t){if((this.options.rightclick||2!==t.button)&&!(t.touches&&t.touches.length>1)&&(!this.options.cancelOn||!0!==this.options.cancelOn(t))){var e=this.dom;e.setCapture?e.setCapture():window.captureEvents&&window.captureEvents(window.Event.MOUSEMOVE|window.Event.MOUSEUP),e.ondragstart=function(){return!1},delete this.moved;var n=t.touches?t.touches[0]:t;this.startPos=new me(n.clientX,n.clientY),rn(document,Cn[t.type],this.onMouseMove,this),rn(document,Pn[t.type],this.onMouseUp,this),this.options.ignoreMouseleave||rn(this.dom,"mouseleave",this.onMouseUp,this),this.fire("mousedown",{domEvent:t,mousePos:new me(n.clientX,n.clientY)})}},n.onMouseMove=function(t){if(t.touches&&t.touches.length>1)this.moved&&(this.interupted=!0,this.onMouseUp(t));else{var e=t.touches?t.touches[0]:t,n=new me(e.clientX,e.clientY).sub(this.startPos);(n.x||n.y)&&(this.moved?this.fire("dragging",{domEvent:t,mousePos:new me(e.clientX,e.clientY)}):(this.fire("dragstart",{domEvent:t,mousePos:this.startPos.copy()}),this.moved=!0))}},n.onMouseUp=function(t){var e=t.changedTouches?t.changedTouches[0]:t;this._offEvents();var n={domEvent:t};m(e.clientX)&&(n.mousePos=new me(parseInt(e.clientX,0),parseInt(e.clientY,0))),this.moved&&(n.interupted=this.interupted,this.fire("dragend",n),delete this.interupted,delete this.moved),this.fire("mouseup",n)},n._offEvents=function(){var t=this.dom;if(on(t,"mouseleave",this.onMouseUp,this),"undefined"!=typeof document&&"undefined"!=typeof window){for(var e in Cn)on(document,Cn[e],this.onMouseMove,this),on(document,Pn[e],this.onMouseUp,this);t.releaseCapture?t.releaseCapture():window.captureEvents&&window.captureEvents(window.Event.MOUSEMOVE|window.Event.MOUSEUP)}},e}(wn),On=function(t){function e(){return t.apply(this,arguments)||this}return fe(e,t),e.toNumberArrays=function(t){return Array.isArray(t)?j(t,(function(t){return[t.x,t.y]})):[t.x,t.y]},e.toCoordinates=function(t){if(m(t[0])&&m(t[1]))return new e(t);for(var n=[],r=0,i=t.length;r<i;r++){var o=t[r];Array.isArray(o)?m(o[0])?n.push(new e(o)):n.push(e.toCoordinates(o)):n.push(new e(o))}return n},e}(pe),Rn=function(){function t(t,e){this.type=t,this.properties=e}return t.createProj4=function(e){return new t("proj4",{proj:e})},t.fromProjectionCode=function(e){return e&&t[e=e.toUpperCase().replace(":","")]||null},t}();Rn.WGS84=Rn.createProj4("+proj=longlat +datum=WGS84 +no_defs"),Rn.EPSG4326=Rn.WGS84,Rn.EPSG3857=Rn.createProj4("+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +wktext +no_defs"),Rn.IDENTITY=Rn.createProj4("+proj=identity +no_defs"),Rn.CGCS2000=Rn.createProj4("+proj=longlat +datum=CGCS2000"),Rn.EPSG4490=Rn.CGCS2000,Rn.BD09LL=Rn.createProj4("+proj=longlat +datum=BD09"),Rn.GCJ02=Rn.createProj4("+proj=longlat +datum=GCJ02");var kn,In=new me(0,0),Dn=new On(0,0),jn=new On(0,0),zn=new On(0,0),Nn=new On(0,0),Fn=new On(0,0),Bn=new On(0,0),Hn=new On(0,0),Gn=new On(0,0),Un=[],Wn=[],Vn=function(){function t(t,e,n,r){this._clazz=On;var i=arguments.length,o=i>0?arguments[i-1]:null;o&&o.unproject&&(this.projection=arguments[i-1]),this._dirty=!0,this._initialize(t,e,n,r)}var e=t.prototype;return e._initialize=function(t,e,n,r){if(this.xmin=null,this.xmax=null,this.ymin=null,this.ymax=null,!p(t)){var i=this.projection;m(t)&&m(e)&&m(n)&&m(r)?i?this.set(t,e,n,r):this.set(Math.min(t,n),Math.min(e,r),Math.max(t,n),Math.max(e,r)):Array.isArray(t)?i?this.set(t[0],t[1],t[2],t[3]):this.set(Math.min(t[0],t[2]),Math.min(t[1],t[3]),Math.max(t[0],t[2]),Math.max(t[1],t[3])):m(t.x)&&m(e.x)&&m(t.y)&&m(e.y)?i?this.set(t.x,t.y,e.x,e.y):(t.x>e.x?(this.xmin=e.x,this.xmax=t.x):(this.xmin=t.x,this.xmax=e.x),t.y>e.y?(this.ymin=e.y,this.ymax=t.y):(this.ymin=t.y,this.ymax=e.y)):m(t.xmin)&&m(t.xmax)&&m(t.ymin)&&m(t.ymax)&&this.set(t.xmin,t.ymin,t.xmax,t.ymax)}},e._add=function(t){return this._dirty=!0,p(t.x)?p(t.xmin)?p(t[0])||(this.xmin+=t[0],this.ymin+=t[1],this.xmax+=t[0],this.ymax+=t[1]):(this.xmin+=t.xmin,this.ymin+=t.ymin,this.xmax+=t.xmax,this.ymax+=t.ymax):(this.xmin+=t.x,this.ymin+=t.y,this.xmax+=t.x,this.ymax+=t.y),this},e.add=function(){var t=new this.constructor(this.xmin,this.ymin,this.xmax,this.ymax,this.projection);return t._add.apply(t,arguments)},e._scale=function(t){return this._dirty=!0,this.xmin*=t,this.ymin*=t,this.xmax*=t,this.ymax*=t,this},e._sub=function(t){return this._dirty=!0,p(t.x)?p(t.xmin)?p(t[0])||(this.xmin-=t[0],this.ymin-=t[1],this.xmax-=t[0],this.ymax-=t[1]):(this.xmin-=t.xmin,this.ymin-=t.ymin,this.xmax-=t.xmax,this.ymax-=t.ymax):(this.xmin-=t.x,this.ymin-=t.y,this.xmax-=t.x,this.ymax-=t.y),this},e._substract=function(){return this._sub.apply(this,arguments)},e.sub=function(){var t=new this.constructor(this.xmin,this.ymin,this.xmax,this.ymax,this.projection);return t._sub.apply(t,arguments)},e.substract=function(){return this.sub.apply(this,arguments)},e.round=function(){return new this.constructor(Math.round(this.xmin),Math.round(this.ymin),Math.round(this.xmax),Math.round(this.ymax),this.projection)},e._round=function(){return this._dirty=!0,this.xmin=Math.round(this.xmin),this.ymin=Math.round(this.ymin),this.xmax=Math.round(this.xmax),this.ymax=Math.round(this.ymax),this},e.getMin=function(t){return t?(t.set(this.xmin,this.ymin),t):new this._clazz(this.xmin,this.ymin)},e.getMax=function(t){return t?(t.set(this.xmax,this.ymax),t):new this._clazz(this.xmax,this.ymax)},e.getCenter=function(t){var e=(this.xmin+this.xmax)/2,n=(this.ymin+this.ymax)/2;return t?(t.set(e,n),t):new this._clazz(e,n)},e.isValid=function(){return!(p(this.xmin)||p(this.ymin)||p(this.xmax)||p(this.ymax))},e.equals=function(t){return this.xmin===t.xmin&&this.xmax===t.xmax&&this.ymin===t.ymin&&this.ymax===t.ymax},e.intersects=function(t){this._project(this),this._project(t);var e=Math.max(this.pxmin,t.pxmin),n=Math.max(this.pymin,t.pymin),r=Math.min(this.pxmax,t.pxmax),i=Math.min(this.pymax,t.pymax);return!(e>r||n>i)},e.within=function(t){return this._project(this),this._project(t),this.pxmin>=t.pxmin&&this.pxmax<=t.pxmax&&this.pymin>=t.pymin&&this.pymax<=t.pymax},e.contains=function(t){if(!t)return!1;this._project(this);var e=this.projection;if(e)if(void 0!==t.x){var n=Dn;Array.isArray(t)?(n.x=t[0],n.y=t[1]):(n.x=t.x,n.y=t.y),t=e.project(n,n)}else void 0!==t.xmin&&this._project(t);return(t.x||t.pxmin||0)>=this.pxmin&&(t.x||t.pxmax||0)<=this.pxmax&&(t.y||t.pymin||0)>=this.pymin&&(t.y||t.pymax||0)<=this.pymax},e.getWidth=function(){return Math.abs(this.xmax-this.xmin)},e.getHeight=function(){return Math.abs(this.ymax-this.ymin)},e.getSize=function(){return new ge(this.getWidth(),this.getHeight())},e.set=function(t,e,n,r){return this.xmin=t,this.ymin=e,this.xmax=n,this.ymax=r,this._dirty=!0,this},e.__combine=function(t){var e,n,r,i;void 0!==t.x&&(kn.xmin=kn.xmax=t.x,kn.ymin=kn.ymax=t.y,t=kn),this._project(t),this._project(this),m(this.pxmin)?(e=Math.min(this.pxmin,t.pxmin),n=Math.min(this.pymin,t.pymin),r=Math.max(this.pxmax,t.pxmax),i=Math.max(this.pymax,t.pymax)):(e=t.pxmin,n=t.pymin,r=t.pxmax,i=t.pymax);var o=this.projection;if(o){jn.set(e,n),zn.set(r,i);var a=o.unproject(jn,jn),s=o.unproject(zn,zn);e=a.x,n=a.y,r=s.x,i=s.y}return Wn[0]=e,Wn[1]=n,Wn[2]=r,Wn[3]=i,Wn},e._combine=function(t){if(!t||t.isValid&&!t.isValid())return this;var e=this.__combine(t);return this.set(e[0],e[1],e[2],e[3]),this._dirty=!0,this},e.combine=function(t){if(!t||t.isValid&&!t.isValid())return this;var e=this.__combine(t);return new this.constructor(e[0],e[1],e[2],e[3],this.projection)},e.intersection=function(t){if(!this.intersects(t))return null;Nn.x=Math.max(this.pxmin,t.pxmin),Nn.y=Math.max(this.pymin,t.pymin),Fn.x=Math.min(this.pxmax,t.pxmax),Fn.y=Math.min(this.pymax,t.pymax);var e=Nn,n=Fn,r=this.projection;return r&&(e=r.unproject(e,e),n=r.unproject(n,n)),new this.constructor(e,n,r)},e.expand=function(t){var e,n;return m(t)?e=n=t:(e=t.width||t.x||t[0]||0,n=t.height||t.y||t[1]||0),new this.constructor(this.xmin-e,this.ymin-n,this.xmax+e,this.ymax+n,this.projection)},e._expand=function(t){var e,n;return m(t)?e=n=t:(e=t.width||t.x||t[0]||0,n=t.height||t.y||t[1]||0),this.xmin-=e,this.ymin-=n,this.xmax+=e,this.ymax+=n,this._dirty=!0,this},e.toJSON=function(){return{xmin:this.xmin,ymin:this.ymin,xmax:this.xmax,ymax:this.ymax}},e.toArray=function(){var t=this.xmin,e=this.ymin,n=this.xmax,r=this.ymax;return[new this._clazz([t,r]),new this._clazz([n,r]),new this._clazz([n,e]),new this._clazz([t,e]),new this._clazz([t,r])]},e.toString=function(){return this.xmin+","+this.ymin+","+this.xmax+","+this.ymax},e.copy=function(){return new this.constructor(this.xmin,this.ymin,this.xmax,this.ymax,this.projection)},e.convertTo=function(t,e){if(!this.isValid())return null;var n,r=e||new this.constructor;return e&&r.set(null,null,null,null),this._clazz===On?n=Bn:this._clazz===me&&(n=In),n.x=this.xmin,n.y=this.ymax,r._combine(t(n)),n.x=this.xmax,r._combine(t(n)),n.y=this.ymin,r._combine(t(n)),n.x=this.xmin,r._combine(t(n)),r},e._project=function(t){if(t&&t.isValid()){var e=this.projection;if(e){if(t._dirty){Hn.set(t.xmax,t.ymin),Gn.set(t.xmin,t.ymax),Un[0]=Hn,Un[1]=Gn;var n=e.projectCoords(Un),r=n[0],i=n[1];t.pxmin=Math.min(r.x,i.x),t.pymin=Math.min(r.y,i.y),t.pxmax=Math.max(r.x,i.x),t.pymax=Math.max(r.y,i.y)}delete t._dirty}else t.pxmin=t.xmin,t.pxmax=t.xmax,t.pymin=t.ymin,t.pymax=t.ymax}else t&&(t.pxmin=t.pxmax=t.pymin=t.pymax=null)},t}();kn=new Vn(0,0,0,0);var Zn=function(t){function e(e,n,r,i){var o;return(o=t.call(this,e,n,r,i)||this)._clazz=me,o}return fe(e,t),e}(Vn),qn=function(){function t(t){this.matrix=t}var e=t.prototype;return e.transform=function(t,e,n){var r=this.matrix[0]*(t.x-this.matrix[2])/e,i=-this.matrix[1]*(t.y-this.matrix[3])/e;return n?(n.x=r,n.y=i,n):new me(r,i)},e.untransform=function(t,e,n){var r=t.x*e/this.matrix[0]+this.matrix[2],i=t.y*e/-this.matrix[1]+this.matrix[3];return n?(n.x=r,n.y=i,n):new On(r,i)},t}(),Yn={project:function(){},unproject:function(){},projectCoords:function(t){var e=this;if(!t)return[];if(!Array.isArray(t))return this.project(t);if(0===t.length)return[];if(!this.isSphere())return j(t,this.project,this);if(Array.isArray(t[0]))return t.map((function(t){return e.projectCoords(t)}));for(var n,r,i,o,a,s,u=this.getCircum(),c=this.getSphereExtent(),l=c.sx,h=c.sy,f=t[0],d=[this.project(f)],p=1,m=t.length;p<m;p++)o=(i=t[p]).x-f.x,a=i.y-f.y,s=this.project(i),Math.abs(o)>180&&(void 0===n&&(n=i.x>f.x),n&&(s._add(-u.x*N(o)*l,0),i._add(-360*N(o),0))),Math.abs(a)>90&&(void 0===r&&(r=i.y<f.y),r&&(s._add(0,-u.y*N(a)*h),i._add(0,-180*N(a)))),f=i,d.push(s);return d},unprojectCoords:function(t){return t?Array.isArray(t)?j(t,this.unproject,this):this.unproject(t):[]},isSphere:function(){return!!this.sphere},isOutSphere:function(t){return!!this.isSphere()&&!this.getSphereExtent().contains(t)},wrapCoord:function(t){if(!this.isSphere())return t;var e=this.getSphereExtent(),n=new On(t);return e.contains(n)||(n.x=H(t.x,e.xmin,e.xmax),n.y=H(t.y,e.ymin,e.ymax)),n},getCircum:function(){if(!this.circum&&this.isSphere()){var t=this.getSphereExtent();this.circum={x:t.getWidth(),y:t.getHeight()}}return this.circum},getSphereExtent:function(){if(!this.extent&&this.isSphere()){var t=this.project(new On(180,90)),e=this.project(new On(-180,-90));this.extent=new Vn(e,t,this),this.extent.sx=t.x>e.x?1:-1,this.extent.sy=t.y>e.y?1:-1}return this.extent}},Jn={measureLength:function(t,e){if(!Array.isArray(t))return this.measureLenBetween(t,e);for(var n=0,r=0,i=t.length;r<i-1;r++)n+=this.measureLenBetween(t[r],t[r+1]);return n}},Xn=d({measure:"IDENTITY",measureLenBetween:function(t,e){if(!t||!e)return 0;try{return Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))}catch(t){return 0}},measureArea:function(t){if(!Array.isArray(t))return 0;for(var e=0,n=0,r=t.length;n<r;n++){var i,o=t[n];i=n===r-1?t[0]:t[n+1],e+=o.x*i.y-o.y*i.x}return Math.abs(e/2)},locate:function(t,e,n){return t=new On(t.x,t.y),this._locate(t,e,n)},_locate:function(t,e,n){return t?(e||(e=0),n||(n=0),e||n?(t.x=t.x+e,t.y=t.y+n,t):t):null},rotate:function(t,e,n){return t=new On(t.x,t.y),this._rotate(t,e,n)},_rotate:function(){var t=new me(0,0);return function(e,n,r){return t.x=e.x-n.x,t.y=e.y-n.y,t._rotate(r*Math.PI/180),e.x=n.x+t.x,e.y=n.y+t.y,e}}()},Jn),$n=function(){function t(t){this.radius=t}var e=t.prototype;return e.measureLenBetween=function(t,e){if(!t||!e)return 0;var n=M(t.y),r=M(e.y),i=n-r,o=M(t.x)-M(e.x);return n=2*Math.asin(Math.sqrt(Math.pow(Math.sin(i/2),2)+Math.cos(n)*Math.cos(r)*Math.pow(Math.sin(o/2),2))),n*=this.radius,Math.round(1e5*n)/1e5},e.measureArea=function(t){var e,n=M(this.radius),r=0,i=t,o=i.length;if(o<3)return 0;for(e=0;e<o-1;e++){var a=i[e],s=i[e+1];r+=a.x*n*Math.cos(M(a.y))*s.y*n-s.x*n*Math.cos(M(s.y))*a.y*n}return o=i[e],i=i[0],r+=o.x*n*Math.cos(M(o.y))*i.y*n-i.x*n*Math.cos(M(i.y))*o.y*n,.5*Math.abs(r)},e.locate=function(t,e,n){return t=new On(t.x,t.y),this._locate(t,e,n)},e._locate=function(t,e,n){if(!t)return null;if(e||(e=0),n||(n=0),!e&&!n)return t;var r,i,o=M(t.y);if(0!==n){var a=Math.abs(n);i=H(180*(o+=2*Math.sin(a/(2*this.radius))*(n>0?1:-1))/Math.PI,-90,90)}else i=t.y;if(0!==e){var s=Math.abs(e),u=M(t.x);r=H(180*(u+=2*Math.sqrt(Math.pow(Math.sin(s/(2*this.radius)),2)/Math.pow(Math.cos(o),2))*(e>0?1:-1))/Math.PI,-180,180)}else r=t.x;return t.x=r,t.y=i,t},e.rotate=function(t,e,n){return t=new On(t),this._rotate(t,e,n)},e._rotate=function(t,e,n){var r=function(t,e,n){var r;return void 0===n&&(n={}),(r=n.final?Qn(e,t):Qn(t,e))>180?-(360-r):r}(e,t)-n,i=this.measureLenBetween(e,t);return t.x=e.x,t.y=e.y,function(t,e,n,r){var i=e/r,o=t.x*Math.PI/180,a=M(t.y),s=M(n),u=i*Math.cos(s),c=a+u;Math.abs(c)>Math.PI/2&&(c=c>0?Math.PI-c:-Math.PI-c);var l=Math.log(Math.tan(c/2+Math.PI/4)/Math.tan(a/2+Math.PI/4)),h=Math.abs(l)>1e-11?u/l:Math.cos(a),f=i*Math.sin(s)/h,d=o+f;return t.x=(180*d/Math.PI+540)%360-180,t.y=180*c/Math.PI,t}(t,i,r,this.radius)},t}();function Qn(t,e){var n=M(t.y),r=M(e.y),i=M(e.x-t.x);i>Math.PI&&(i-=2*Math.PI),i<-Math.PI&&(i+=2*Math.PI);var o=Math.log(Math.tan(r/2+Math.PI/4)/Math.tan(n/2+Math.PI/4));return(S(Math.atan2(i,o))+360)%360}var Kn=d({measure:"EPSG:4326",sphere:new $n(6378137),measureLenBetween:function(){return this.sphere.measureLenBetween.apply(this.sphere,arguments)},measureArea:function(){return this.sphere.measureArea.apply(this.sphere,arguments)},_locate:function(){return this.sphere._locate.apply(this.sphere,arguments)},locate:function(){return this.sphere.locate.apply(this.sphere,arguments)},_rotate:function(){return this.sphere._rotate.apply(this.sphere,arguments)},rotate:function(){return this.sphere.rotate.apply(this.sphere,arguments)}},Jn),tr=d({measure:"BAIDU",sphere:new $n(6370996.81),measureLenBetween:function(){return this.sphere.measureLenBetween.apply(this.sphere,arguments)},measureArea:function(){return this.sphere.measureArea.apply(this.sphere,arguments)},_locate:function(){return this.sphere._locate.apply(this.sphere,arguments)},locate:function(){return this.sphere.locate.apply(this.sphere,arguments)},_rotate:function(){return this.sphere._rotate.apply(this.sphere,arguments)},rotate:function(){return this.sphere.rotate.apply(this.sphere,arguments)}},Jn),er=Kn,nr={};function rr(t){nr[t.measure]=t}rr(Xn),rr(Kn),rr(tr);var ir,or={getInstance:function(t){if(!t)return er;for(var e in nr)if(b(nr,e)){var n=nr[e].measure;if(!n)continue;if(t.toLowerCase()===n.toLowerCase())return nr[e]}return null}},ar=Object.freeze({Identity:Xn,DEFAULT:er,Measurer:or,WGS84Sphere:Kn,BaiduSphere:tr}),sr=d({},Yn,{code:"EPSG:3857",rad:Math.PI/180,metersPerDegree:6378137*Math.PI/180,maxLatitude:85.0511287798,project:function(t,e){var n=this.rad,r=this.metersPerDegree,i=this.maxLatitude,o=t.x,a=Math.max(Math.min(i,t.y),-i),s=o*r,u=(0===a?0:Math.log(Math.tan((90+a)*n/2))/n)*r;return e?(e.x=s,e.y=u,e):new On(s,u)},unproject:function(t,e){var n,r=this.rad,i=this.metersPerDegree,o=t.x/i,a=t.y;0===a?n=0:(n=a/i,n=(2*Math.atan(Math.exp(n*r))-Math.PI/2)/r),Math.abs(Math.abs(o)-180)<1e-7&&(o=180*N(o)),Math.abs(Math.abs(n)-this.maxLatitude)<1e-7&&(n=N(n)*this.maxLatitude);var s=H(o,-180,180),u=H(n,-this.maxLatitude,this.maxLatitude);return e?(e.x=s,e.y=u,e):new On(s,u)}},Kn),ur=d({},Yn,{code:"EPSG:4326",project:function(t,e){return e?(e.x=t.x,e.y=t.y,e):new On(t)},unproject:function(t,e){return e?(e.x=t.x,e.y=t.y,e):new On(t)}},Kn),cr=d({},ur,{code:"EPSG:4490"}),lr=d({},Yn,{code:"BAIDU",project:function(t,e){return this.convertLL2MC(t,e)},unproject:function(t,e){return this.convertMC2LL(t,e)}},tr,{EARTHRADIUS:6370996.81,MCBAND:[12890594.86,8362377.87,5591021,3481989.83,1678043.12,0],LLBAND:[75,60,45,30,15,0],MC2LL:[[1.410526172116255e-8,898305509648872e-20,-1.9939833816331,200.9824383106796,-187.2403703815547,91.6087516669843,-23.38765649603339,2.57121317296198,-.03801003308653,17337981.2],[-7.435856389565537e-9,8983055097726239e-21,-.78625201886289,96.32687599759846,-1.85204757529826,-59.36935905485877,47.40033549296737,-16.50741931063887,2.28786674699375,10260144.86],[-3.030883460898826e-8,898305509983578e-20,.30071316287616,59.74293618442277,7.357984074871,-25.38371002664745,13.45380521110908,-3.29883767235584,.32710905363475,6856817.37],[-1.981981304930552e-8,8983055099779535e-21,.03278182852591,40.31678527705744,.65659298677277,-4.44255534477492,.85341911805263,.12923347998204,-.04625736007561,4482777.06],[3.09191371068437e-9,8983055096812155e-21,6995724062e-14,23.10934304144901,-.00023663490511,-.6321817810242,-.00663494467273,.03430082397953,-.00466043876332,2555164.4],[2.890871144776878e-9,8983055095805407e-21,-3.068298e-8,7.47137025468032,-353937994e-14,-.02145144861037,-1234426596e-14,.00010322952773,-323890364e-14,826088.5]],LL2MC:[[-.0015702102444,111320.7020616939,0x60e374c3105a3,-0x24bb4115e2e164,0x5cc55543bb0ae8,-0x7ce070193f3784,0x5e7ca61ddf8150,-0x261a578d8b24d0,0x665d60f3742ca,82.5],[.0008277824516172526,111320.7020463578,647795574.6671607,-4082003173.641316,10774905663.51142,-15171875531.51559,12053065338.62167,-5124939663.577472,913311935.9512032,67.5],[.00337398766765,111320.7020202162,4481351.045890365,-23393751.19931662,79682215.47186455,-115964993.2797253,97236711.15602145,-43661946.33752821,8477230.501135234,52.5],[.00220636496208,111320.7020209128,51751.86112841131,3796837.749470245,992013.7397791013,-1221952.21711287,1340652.697009075,-620943.6990984312,144416.9293806241,37.5],[-.0003441963504368392,111320.7020576856,278.2353980772752,2485758.690035394,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]],convertMC2LL:function(t,e){for(var n,r=0,i=this.MCBAND.length;r<i;r++)if(Math.abs(t.y)>=this.MCBAND[r]){n=this.MC2LL[r];break}return this.convertor(t,n,e)},convertLL2MC:function(t,e){var n,r,i;t.x=this.getLoop(t.x,-180,180),t.y=this.getRange(t.y,-74,74);var o=new On(t.x,t.y);for(r=0,i=this.LLBAND.length;r<i;r++)if(o.y>=this.LLBAND[r]){n=this.LL2MC[r];break}if(!n)for(r=this.LLBAND.length-1;r>=0;r--)if(o.y<=-this.LLBAND[r]){n=this.LL2MC[r];break}return this.convertor(t,n,e)},convertor:function(t,e,n){if(!t||!e)return null;var r=e[0]+e[1]*Math.abs(t.x),i=Math.abs(t.y)/e[9],o=e[2]+e[3]*i+e[4]*i*i+e[5]*i*i*i+e[6]*i*i*i*i+e[7]*i*i*i*i*i+e[8]*i*i*i*i*i*i;return r*=t.x<0?-1:1,o*=t.y<0?-1:1,n?(n.x=r,n.y=o,n):new On(r,o)},toRadians:function(t){return Math.PI*t/180},toDegrees:function(t){return 180*t/Math.PI},getRange:function(t,e,n){return null!=e&&(t=Math.max(t,e)),null!=n&&(t=Math.min(t,n)),t},getLoop:function(t,e,n){if(t===1/0)return n;if(t===-1/0)return e;for(;t>n;)t-=n-e;for(;t<e;)t+=n-e;return t}}),hr=d({},Yn,{code:"IDENTITY",project:function(t,e){return e?(e.x=t.x,e.y=t.y,e):t.copy()},unproject:function(t,e){return e?(e.x=t.x,e.y=t.y,e):t.copy()}},Xn),fr=sr,dr=Object.freeze({EPSG3857:sr,DEFAULT:fr,EPSG4326:ur,EPSG4490:cr,BAIDU:lr,IDENTITY:hr,Common:Yn}),pr=function(t){return function(t){function e(){return t.apply(this,arguments)||this}return fe(e,t),e.registerRenderer=function(t,e){var n=this.prototype,r=Object.getPrototypeOf(n);return n._rendererClasses&&n._rendererClasses!==r._rendererClasses||(n._rendererClasses=n._rendererClasses?Object.create(n._rendererClasses):{}),n._rendererClasses[t.toLowerCase()]=e,this},e.getRendererClass=function(t){var e=this.prototype;return e._rendererClasses?e._rendererClasses[t.toLowerCase()]:null},e}(t)},mr=function(t){function e(e){var n;return(n=t.call(this)||this).layer=e,n._painted=!1,n._drawTime=0,n.setToRedraw(),n}fe(e,t);var n=e.prototype;return n.render=function(t){this.prepareRender(),this.getMap()&&this.layer.isVisible()&&(this.resources||(this.resources=new gr),this.checkAndDraw(this._tryToDraw,t))},n.checkAndDraw=function(t){for(var e=this,n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];if(this.checkResources){var o=this.checkResources();o.length>0?(this._loadingResource=!0,this.loadResources(o).then((function(){e._loadingResource=!1,e.layer&&(e.layer.fire("resourceload"),e.setToRedraw())}))):t.call.apply(t,[this].concat(r))}else t.call.apply(t,[this].concat(r))},n.testIfNeedRedraw=function(){var t=this.getMap();return!(this._loadingResource||!this._toRedraw&&(t.isInteracting()&&!this.drawOnInteracting||!this.needToRedraw()))},n.needToRedraw=function(){var t=this.getMap();return!(!t.isInteracting()&&!t.getRenderer().isViewChanged()||!t.getPitch()&&t.isMoving()&&!t.isZooming()&&!t.isRotating()&&!this.layer.options.forceRenderOnMoving)},n.onSkipDrawOnInteracting=function(){},n.isLoadingResource=function(){return this._loadingResource},n.isRenderComplete=function(){return!!this._renderComplete},n.mustRenderOnInteracting=function(){return!this._painted},n.setToRedraw=function(){return this._toRedraw=!0,this},n.setCanvasUpdated=function(){return this._canvasUpdated=!0,this},n.isCanvasUpdated=function(){return!!this._canvasUpdated},n.remove=function(){this.onRemove(),delete this._loadingResource,delete this.southWest,delete this.canvas,delete this.context,delete this.canvasExtent2D,delete this._extent2D,delete this.resources,delete this.layer},n.onRemove=function(){},n.onAdd=function(){},n.getMap=function(){return this.layer?this.layer.getMap():null},n.getCanvasImage=function(){var t=this.getMap();if(this._canvasUpdated=!1,this._renderZoom!==t.getZoom()||!this.canvas||!this._extent2D)return null;if(this.isBlank())return null;if(this.layer.isEmpty&&this.layer.isEmpty())return null;var e=t._pointToContainerPoint(this.southWest)._add(0,-t.height);return{image:this.canvas,layer:this.layer,point:e}},n.clear=function(){this.clearCanvas()},n.isBlank=function(){return!this._painted},n.show=function(){this.setToRedraw()},n.hide=function(){this.clear(),this.setToRedraw()},n.setZIndex=function(){this.setToRedraw()},n.hitDetect=function(t){if(!this.context||this.layer.isEmpty&&this.layer.isEmpty()||this.isBlank()||this._errorThrown)return!1;var e=this.getMap(),n=e.getDevicePixelRatio(),r=e.getSize();if(t.x<0||t.x>r.width*n||t.y<0||t.y>r.height*n)return!1;try{if(this.context.getImageData(n*t.x,n*t.y,1,1).data[3]>0)return!0}catch(t){return this._errorThrown||(console&&console.warn("hit detect failed with tainted canvas, some geometries have external resources in another domain:\n",t),this._errorThrown=!0),!1}return!1},n.loadResources=function(t){this.resources||(this.resources=new gr);var e=this.resources,n=[];if(U(t))for(var r={},i=t.length-1;i>=0;i--){var o=t[i];o&&o.length&&!r[o.join("-")]&&(r[o.join("-")]=1,e.isResourceLoaded(o,!0)||n.push(new _n(this._promiseResource(o))))}return _n.all(n)},n.prepareRender=function(){delete this._renderComplete;var t=this.getMap();this._renderZoom=t.getZoom(),this.canvasExtent2D=this._extent2D=t._get2DExtent(),this.southWest=t._containerPointToPoint(new me(0,t.height))},n.createCanvas=function(){if(!this.canvas){var t=this.getMap(),e=t.getSize(),n=t.getDevicePixelRatio(),r=n*e.width,i=n*e.height;if(this.layer._canvas){var o=this.layer._canvas;o.width=r,o.height=i,o.style&&(o.style.width=e.width+"px",o.style.height=e.height+"px"),this.canvas=this.layer._canvas}else this.canvas=hn.createCanvas(r,i,t.CanvasClass);this.onCanvasCreate()}},n.onCanvasCreate=function(){},n.createContext=function(){if(!(this.gl&&this.gl.canvas===this.canvas||this.context)&&(this.context=this.canvas.getContext("2d"),this.context)){this.layer.options.globalCompositeOperation&&(this.context.globalCompositeOperation=this.layer.options.globalCompositeOperation);var t=this.getMap().getDevicePixelRatio();1!==t&&this.context.scale(t,t)}},n.resetCanvasTransform=function(){if(this.context){var t=this.getMap().getDevicePixelRatio();this.context.setTransform(t,0,0,t,0,0)}},n.resizeCanvas=function(t){var e=this.canvas;if(e){var n=t||this.getMap().getSize(),r=this.getMap().getDevicePixelRatio();e.width===r*n.width&&e.height===r*n.height||(e.height=r*n.height,e.width=r*n.width,1!==r&&this.context&&this.context.scale(r,r),this.layer._canvas&&e.style&&(e.style.width=n.width+"px",e.style.height=n.height+"px"))}},n.clearCanvas=function(){this.context&&hn.clearRect(this.context,0,0,this.canvas.width,this.canvas.height)},n.prepareCanvas=function(){this.canvas?(this.resetCanvasTransform(),this.clearCanvas(),this.resizeCanvas()):(this.createCanvas(),this.createContext(),this.layer.onCanvasCreate(),this.layer.fire("canvascreate",{context:this.context,gl:this.gl})),delete this._maskExtent;var t=this.layer.getMask();if(!t)return this.layer.fire("renderstart",{context:this.context,gl:this.gl}),null;var e=this._maskExtent=t._getMaskPainter().get2DExtent();return e.intersects(this._extent2D),this.layer.fire("renderstart",{context:this.context,gl:this.gl}),e},n.clipCanvas=function(t){var e=this.layer.getMask();if(!e)return!1;var n=this.southWest,r=this.getMap();this.southWest=r._containerPointToPoint(new me(0,r.height)),t.save();var i=r.getDevicePixelRatio();if(1!==i&&(t.save(),t.scale(i,i)),e.getGeometries){t.isMultiClip=!0;var o=e.getGeometries()||[];t.beginPath(),o.forEach((function(e){e._getMaskPainter().paint(null,t)})),t.stroke(),delete t.isMultiClip}else e._getMaskPainter().paint(null,t);return 1!==i&&t.restore(),t.clip(),this.southWest=n,!0},n.getViewExtent=function(){return{extent:this._extent2D,maskExtent:this._maskExtent,zoom:this._renderZoom,southWest:this.southWest}},n.completeRender=function(){this.getMap()&&(this._renderComplete=!0,this.layer.fire("renderend",{context:this.context,gl:this.gl}),this.setCanvasUpdated())},n.getEvents=function(){return{_zoomstart:this.onZoomStart,_zooming:this.onZooming,_zoomend:this.onZoomEnd,_resize:this.onResize,_movestart:this.onMoveStart,_moving:this.onMoving,_moveend:this.onMoveEnd,_dragrotatestart:this.onDragRotateStart,_dragrotating:this.onDragRotating,_dragrotateend:this.onDragRotateEnd,_spatialreferencechange:this.onSpatialReferenceChange}},n.onZoomStart=function(){},n.onZoomEnd=function(){this.setToRedraw()},n.onZooming=function(){},n.onMoveStart=function(){},n.onMoving=function(){},n.onMoveEnd=function(){this.setToRedraw()},n.onResize=function(){delete this._extent2D,this.resizeCanvas(),this.setToRedraw()},n.onDragRotateStart=function(){},n.onDragRotating=function(){},n.onDragRotateEnd=function(){this.setToRedraw()},n.onSpatialReferenceChange=function(){},n.getDrawTime=function(){return this._drawTime},n._tryToDraw=function(t){this._toRedraw=!1,!this.canvas&&this.layer.isEmpty&&this.layer.isEmpty()?this._renderComplete=!0:this._drawAndRecord(t)},n._drawAndRecord=function(t){if(this.getMap()){var e=this._painted;this._painted=!0;var n=f();this.draw(t),n=f()-n,this._drawTime=e?n:n/2,e&&this.layer&&this.layer.options.logDrawTime&&console.log(this.layer.getId(),"frameTimeStamp:",t,"drawTime:",this._drawTime)}},n._promiseResource=function(t){var e=this,n=this.resources,r=this.layer.options.crossOrigin;return function(i){if(n.isResourceLoaded(t,!0))i(t);else{var o=new Image;p(r)||(o.crossOrigin=r),C(t[0])&&!A&&(t[1]&&(t[1]*=2),t[2]&&(t[2]*=2)),o.onload=function(){e._cacheResource(t,o),i(t)},o.onabort=function(e){console&&console.warn("image loading aborted: "+t[0]),e&&console&&console.warn(e),i(t)},o.onerror=function(e){e&&"undefined"!=typeof console&&console.warn(e),n.markErrorResource(t),i(t)},P(o,t)}}},n._cacheResource=function(t,e){if(this.layer&&this.resources){var n=t[1],r=t[2];if(this.layer.options.cacheSvgOnCanvas&&1===C(t[0])&&(he.edge||he.ie)){p(n)&&(n=e.width||this.layer.options.defaultIconSize[0]),p(r)&&(r=e.height||this.layer.options.defaultIconSize[1]);var i=hn.createCanvas(n,r);hn.image(i.getContext("2d"),e,0,0,n,r),e=i}this.resources.addResource(t,e)}},e}(Mn),gr=function(){function t(){this.resources={},this._errors={}}var e=t.prototype;return e.addResource=function(t,e){this.resources[t[0]]={image:e,width:+t[1],height:+t[2]}},e.isResourceLoaded=function(t,e){if(!t)return!1;var n=this._getImgUrl(t);if(this._errors[n])return!0;var r=this.resources[n];return!(!r||e&&C(t[0])&&(+t[1]>r.width||+t[2]>r.height))},e.getImage=function(t){var e=this._getImgUrl(t);return!this.isResourceLoaded(t)||this._errors[e]?null:this.resources[e].image},e.markErrorResource=function(t){this._errors[this._getImgUrl(t)]=1},e.merge=function(t){if(!t)return this;for(var e in t.resources){var n=t.resources[e];this.addResource([e,n.width,n.height],n.image)}return this},e.forEach=function(t){if(!this.resources)return this;for(var e in this.resources)b(this.resources,e)&&t(e,this.resources[e]);return this},e._getImgUrl=function(t){return Array.isArray(t)?t[0]:t},t}();function vr(t,e,n,r){for(var i,o=[],a=0,s=0,u=t.length;s<u-1;s++)(i=yr(t[s],t[s+1],e,s,n,r))&&(o[a]=o[a]||[],o[a].push({point:i[0],index:s}),i[1]===t[s+1]&&s!==u-2||(o[a].push({point:i[1],index:s+1}),a++));return o}function yr(t,e,n,r,i,o){var a,s,u,c=r?ir:br(t,n),l=br(e,n);for(ir=l;;){if(!(c|l))return[t,e];if(c&l)return!1;if(o)return[t,e];u=br(s=xr(t,e,a=c||l,n,i),n),a===c?(t=s,c=u):(e=s,l=u)}}function _r(t,e,n){var r,i,o,a,s,u,c,l,h,f=[1,4,2,8];for(i=0,c=t.length;i<c;i++)t[i]._code=br(t[i],e);for(a=0;a<4;a++){for(l=f[a],r=[],i=0,o=(c=t.length)-1;i<c;o=i++)s=t[i],u=t[o],s._code&l?u._code&l||((h=xr(u,s,l,e,n))._code=br(h,e),r.push(h)):(u._code&l&&((h=xr(u,s,l,e,n))._code=br(h,e),r.push(h)),r.push(s));t=r}return t}function xr(t,e,n,r,i){var o,a,s=e.x-t.x,u=e.y-t.y,c=r.getMin(),l=r.getMax();8&n?(o=t.x+s*(l.y-t.y)/u,a=l.y):4&n?(o=t.x+s*(c.y-t.y)/u,a=c.y):2&n?(o=l.x,a=t.y+u*(l.x-t.x)/s):1&n&&(o=c.x,a=t.y+u*(c.x-t.x)/s);var h=new me(o,a);return i&&h._round(),h}function br(t,e){var n=0;return t.x<e.getMin().x?n|=1:t.x>e.getMax().x&&(n|=2),t.y<e.getMin().y?n|=4:t.y>e.getMax().y&&(n|=8),n}function wr(t,e,n,r){t=new me(t);var i,o,a,s=Math.abs(n.x-e.x),u=Math.abs(n.y-e.y),c=Math.sqrt(Math.abs(s*s-u*u));return s>=u?(i=new me(e.x-c,e.y),o=new me(e.x+c,e.y),a=2*s):(i=new me(e.x,e.y-c),o=new me(e.x,e.y+c),a=2*u),t.distanceTo(i)+t.distanceTo(o)<=a+2*r}var Mr=function(){function t(){}var e=t.prototype;return e.getMap=function(){return this.geometry.getMap()},e.getPainter=function(){return this.painter},e.isDynamicSize=function(){return!1},t.testColor=function(t){return!(!t||!y(t))&&l.indexOf(t)>=0},t}(),Sr=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n._prepareContext=function(t){m(this.symbol.opacity)?t.globalAlpha!==this.symbol.opacity&&(t.globalAlpha=this.symbol.opacity):1!==t.globalAlpha&&(t.globalAlpha=1)},n.prepareCanvas=function(t,e,n){hn.prepareCanvas(t,e,n,this.getPainter().isHitTesting())},n.remove=function(){},n.setZIndex=function(){},n.show=function(){},n.hide=function(){},n._defineStyle=function(t){return function(){var e=this,n=[],r={};return Mt(t,(function(){var t=e.getMap();return function(t,e,n){return t[0]=e,t[1]=n,t}(n,t.getZoom(),d({},e.geometry.getProperties(),function(t,e,n,r){return t["{bearing}"]=e,t["{pitch}"]=n,t["{zoom}"]=r,t}(r,t.getBearing(),t.getPitch(),t.getZoom())))}))}.bind(this)()},e}(Mr),Tr=new me(0,0),Er=new me(0,0),Ar=function(t){function e(e,n,r){var i;return(i=t.call(this)||this).symbol=e,i.geometry=n,i.painter=r,i}fe(e,t);var n=e.prototype;return n.get2DExtent=function(){for(var t=this.getMap(),e=t.getGLZoom(),n=new Zn,r=this._getRenderPoints()[0],i=r.length-1;i>=0;i--)r[i]&&n._combine(t._pointToPoint(r[i],e));return n},n.isDynamicSize=function(){var t=this.symbol;return xt(t.markerWidth)||xt(t.markerHeight)||xt(t.textSize)},n._rotateExtent=function(t,e){return t.convertTo((function(t){return t._rotate(e)}))},n._getRenderPoints=function(){var t=this.getPainter().isSpriting()?"center":this.getPlacement();return this.getPainter().getRenderPoints(t)},n._getRenderContainerPoints=function(t){var e=this.getPainter(),n=this._getRenderPoints()[0];if(e.isSpriting())return n;var r=this.getDxDy(),i=this.painter._pointContainerPoints(n,r.x,r.y,t,!0,this.getPlacement());if(!i||!Array.isArray(i[0]))return i;for(var o=[],a=0,s=i.length;a<s;a++)for(var u=0,c=i[a].length;u<c;u++)o.push(i[a][u]);return o},n._getRotationAt=function(t){var e=this.getRotation();e||(e=0);var n=this._getRenderPoints()[1];if(!n||!n[t])return e;var r=this.getMap(),i=n[t][0],o=n[t][1];if(r.isTransforming()){var a=r.getGLZoom();return i=r._pointToContainerPoint(n[t][0],a,0,Tr),o=r._pointToContainerPoint(n[t][1],a,0,Er),e+$(i.x,i.y,o.x,o.y)}return e+-$(i.x,i.y,o.x,o.y)},n._rotate=function(t,e,n){if(n){var r=this.getDxDy(),i=e.sub(r);return t.save(),t.translate(i.x,i.y),t.rotate(n),this.getDxDy()}return null},e}(Sr),Cr=function(t){function e(n,r,i){var o;(o=t.call(this,n,r,i)||this)._dynamic=bt(n),o.style=o._defineStyle(o.translate()),o.strokeAndFill=o._defineStyle(e.translateLineAndFill(o.style));var a=o.strokeAndFill.lineWidth;return o.padding=a%2==0?2:1.5,o}fe(e,t),e.test=function(t){return!!t&&!(!p(t.markerFile)||p(t.markerType)||"path"===t.markerType)};var n=e.prototype;return n.symbolize=function(t,e){var n=this.style;if(this.painter.isHitTesting()||0!==n.markerWidth&&0!==n.markerHeight&&(0!==n.polygonOpacity||0!==n.lineOpacity)){var r=this._getRenderContainerPoints();U(r)&&(this._prepareContext(t),this.getPainter().isSpriting()||this.geometry.getLayer().getMask()===this.geometry||this._dynamic||!1===this.geometry.getLayer().options.cacheVectorOnCanvas?this._drawMarkers(t,r,e):this._drawMarkersWithCache(t,r,e))}},n.getDxDy=function(){var t=this.style,e=t.markerDx,n=t.markerDy;return new me(e,n)},n._drawMarkers=function(t,e,n){var r=this.strokeAndFill;Rt(r.lineColor)||Rt(r.polygonFill)||this.prepareCanvas(t,r,n);for(var i=e.length-1;i>=0;i--){var o=e[i],a=this._rotate(t,o,this._getRotationAt(i));a&&(o=a),this._drawVectorMarker(t,o,n),a&&t.restore()}},n._drawMarkersWithCache=function(t,e,n){var r=this._stampSymbol(),i=n.getImage(r);i||(i=this._createMarkerImage(t,n),n.addResource([r,i.width,i.height],i));for(var o=this._getAnchor(i.width,i.height),a=e.length-1;a>=0;a--){var s=e[a],u=this._rotate(t,s,this._getRotationAt(a));u&&(s=u),hn.image(t,i,s.x+o.x,s.y+o.y),u&&t.restore()}},n._calMarkerSize=function(){if(!this._size){var t=this.strokeAndFill.lineWidth,e=2*(this.symbol.shadowBlur||0),n=Math.round(this.style.markerWidth+t+2*e+2*this.padding),r=Math.round(this.style.markerHeight+t+2*e+2*this.padding);if(xt(this.symbol.markerWidth)||xt(this.symbol.markerHeight))return[n,r];this._size=[n,r]}return this._size},n._createMarkerImage=function(t,e){var n=t.canvas.constructor,r=this._calMarkerSize(),i=hn.createCanvas(r[0],r[1],n),o=this._getCacheImageAnchor(r[0],r[1]),a=i.getContext("2d");return Rt(this.strokeAndFill.lineColor)||Rt(this.strokeAndFill.polygonFill)||this.prepareCanvas(a,this.strokeAndFill,e),this._drawVectorMarker(a,o,e),i},n._stampSymbol=function(){return this._stamp||(this._stamp=[this.style.markerType,Rt(this.style.markerFill)?kt(this.style.markerFill):this.style.markerFill,this.style.markerFillOpacity,this.style.markerFillPatternFile,Rt(this.style.markerLineColor)?kt(this.style.markerLineColor):this.style.markerLineColor,this.style.markerLineWidth,this.style.markerLineOpacity,this.style.markerLineDasharray?this.style.markerLineDasharray.join(","):"",this.style.markerLinePatternFile,this.style.markerWidth,this.style.markerHeight,this.style.markerHorizontalAlignment,this.style.markerVerticalAlignment].join("_")),this._stamp},n._getAnchor=function(t,e){var n=2*(this.symbol.shadowBlur||0)+this.padding,r=Ae(new ge(t,e),this.style.markerHorizontalAlignment,this.style.markerVerticalAlignment);return r.x!==-t/2&&(r.x-=N(r.x+t/2)*n),r.y!==-e/2&&(r.y-=N(r.y+e/2)*n),r},n._getCacheImageAnchor=function(t,e){var n=2*(this.symbol.shadowBlur||0)+this.padding,r=this.style.markerType;return"bar"===r||"pie"===r||"pin"===r?new me(t/2,e-n):"rectangle"===r?new me(n,n):new me(t/2,e/2)},n._getGraidentExtent=function(t){var e=new Zn,n=this.getDxDy(),r=this.getFixedExtent();if(Array.isArray(t))for(var i=t.length-1;i>=0;i--)e._combine(t[i]);else e._combine(t);return e.xmin+=r.xmin-n.x,e.ymin+=r.ymin-n.y,e.xmax+=r.xmax-n.x,e.ymax+=r.ymax-n.y,e},n._drawVectorMarker=function(t,n,r){var i,o=this.style,a=this.strokeAndFill,s=o.markerType.toLowerCase(),u=e._getVectorPoints(s,o.markerWidth,o.markerHeight),c=a.lineOpacity,l=a.polygonOpacity;(Rt(a.lineColor)||Rt(a.polygonFill))&&(Rt(a.lineColor)&&(i=this._getGraidentExtent(n),a.lineGradientExtent=i.expand(a.lineWidth)),Rt(a.polygonFill)&&(i||(i=this._getGraidentExtent(n)),a.polygonGradientExtent=i),this.prepareCanvas(t,a,r));var h=o.markerWidth,f=o.markerHeight,d=o.markerLineWidth/2;if("ellipse"===s)hn.ellipse(t,n,h/2,f/2,f/2,c,l);else if("cross"===s||"x"===s){for(var p=u.length-1;p>=0;p--)u[p]._add(n);hn.path(t,u.slice(0,2),c),hn.path(t,u.slice(2,4),c)}else if("diamond"===s||"bar"===s||"square"===s||"rectangle"===s||"triangle"===s){"bar"===s?n=n.add(0,-d):"rectangle"===s&&(n=n.add(d,d));for(var m=u.length-1;m>=0;m--)u[m]._add(n);hn.polygon(t,u,c,l)}else if("pin"===s){n=n.add(0,-d);for(var g=u.length-1;g>=0;g--)u[g]._add(n);var v=t.lineCap;t.lineCap="round",hn.bezierCurveAndFill(t,u,c,l),t.lineCap=v}else{if("pie"!==s)throw new Error("unsupported markerType: "+s);n=n.add(0,d);var y=180*Math.atan(h/2/f)/Math.PI,_=t.lineCap;t.lineCap="round",hn.sector(t,n,f,[90-y,90+y],c,l),t.lineCap=_}},n.getPlacement=function(){return this.symbol.markerPlacement},n.getRotation=function(){var t=this.style.markerRotation;return m(t)?-t*Math.PI/180:null},n.getFixedExtent=function(){var t=this.getDxDy(),e=2*this.padding,n=this._calMarkerSize().map((function(t){return t-e})),r=this._getAnchor(n[0],n[1]),i=new Zn(t.add(0,0),t.add(n[0],n[1]));i._add(r);var o=this.getRotation();return o&&(i=this._rotateExtent(i,o)),i},n.translate=function(){var t,e,n=this.symbol,r={markerType:z(n.markerType,"ellipse"),markerFill:z(n.markerFill,"#00f"),markerFillOpacity:z(n.markerFillOpacity,1),markerFillPatternFile:z(n.markerFillPatternFile,null),markerLineColor:z(n.markerLineColor,"#000"),markerLineWidth:z(n.markerLineWidth,1),markerLineOpacity:z(n.markerLineOpacity,1),markerLineDasharray:z(n.markerLineDasharray,[]),markerLinePatternFile:z(n.markerLinePatternFile,null),markerDx:z(n.markerDx,0),markerDy:z(n.markerDy,0),markerWidth:z(n.markerWidth,10),markerHeight:z(n.markerHeight,10),markerRotation:z(n.markerRotation,0)},i=r.markerType;return"bar"===i||"pie"===i||"pin"===i?(t="middle",e="top"):"rectangle"===i?(t="right",e="bottom"):(t="middle",e="middle"),r.markerHorizontalAlignment=z(n.markerHorizontalAlignment,t),r.markerVerticalAlignment=z(n.markerVerticalAlignment,e),m(n.markerOpacity)&&(m(n.markerFillOpacity)&&(r.markerFillOpacity*=n.markerOpacity),m(n.markerLineOpacity)&&(r.markerLineOpacity*=n.markerOpacity)),r},e.translateLineAndFill=function(t){var e={lineColor:t.markerLineColor,linePatternFile:t.markerLinePatternFile,lineWidth:t.markerLineWidth,lineOpacity:t.markerLineOpacity,lineDasharray:t.markerLineDasharray,lineCap:"butt",lineJoin:"round",polygonFill:t.markerFill,polygonPatternFile:t.markerFillPatternFile,polygonOpacity:t.markerFillOpacity};return 0===e.lineWidth&&(e.lineOpacity=0),e},e._getVectorPoints=function(t,e,n){var r,i,o,a,s=n/2,u=e/2;if("triangle"===t)return[r=new me(0,0-s),i=new me(0-u,0+s),o=new me(0+u,0+s)];if("cross"===t)return[r=new me(0-u,0),i=new me(0+u,0),o=new me(0,0-s),a=new me(0,0+s)];if("diamond"===t)return[r=new me(0-u,0),i=new me(0,0-s),o=new me(0+u,0),a=new me(0,0+s)];if("square"===t)return[r=new me(0-u,0+s),i=new me(0+u,0+s),o=new me(0+u,0-s),a=new me(0-u,0-s)];if("rectangle"===t)return i=(r=new me(0,0)).add(e,0),o=r.add(e,n),a=r.add(0,n),[r,i,o,a];if("x"===t)return[r=new me(0-u,0+s),i=new me(0+u,0-s),o=new me(0+u,0+s),a=new me(0-u,0-s)];if("bar"===t)return[r=new me(0-u,0-n),i=new me(0+u,0-n),o=new me(0+u,0),a=new me(0-u,0)];if("pin"===t){var c=n*Math.atan(u/s);return[r=new me(0,0),i=new me(0-c,0-n),o=new me(0+c,0-n),a=new me(0,0)]}return[]},e}(Ar),Pr=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.getPlacement=function(){return"point"},n.getDxDy=function(){return new me(0,0)},n.symbolize=function(t){var e=this.geometry,n=e.getLayer();if(e.options.debug||!n||n.options.debug){var r=this.getMap();if(r&&!r.isZooming()){var i=n.options.debugOutline;t.strokeStyle=i,t.fillStyle=i;var o=this.getPainter().getContainerExtent().toArray();hn.polygon(t,[o],1,0);for(var a=this._getRenderContainerPoints(),s=this.geometry.getId(),u=Cr._getVectorPoints("cross",10,10),c=0;c<a.length;c++){var l=a[c];p(s)||hn.fillText(t,s,l.add(8,-4),i);for(var h=[],f=0;f<u.length;f++)h.push(u[f].add(l));hn.path(t,h.slice(0,2),1),hn.path(t,h.slice(2,4),1)}}}},e}(Ar),Lr=function(t){function e(e,n,r){var i;return(i=t.call(this,e,n,r)||this).style=i._defineStyle(i.translate()),i}fe(e,t),e.test=function(t){return!!t&&!p(t.markerFile)};var n=e.prototype;return n.symbolize=function(t,e){var n=this.style;if(this.painter.isHitTesting()||0!==n.markerWidth&&0!==n.markerHeight&&0!==n.markerOpacity){var r=this._getRenderContainerPoints();if(U(r)){var i=this._getImage(e);if(i){this._prepareContext(t);var o,a=n.markerWidth,s=n.markerHeight;if(!m(a)||!m(s)){a=i.width,s=i.height,n.markerWidth=a,n.markerHeight=s;var u=[n.markerFile,n.markerWidth,n.markerHeight];e.isResourceLoaded(u)||e.addResource(u,i);var c=this.getPainter();c.isSpriting()||c.removeCache()}"path"!==this.symbol.markerType&&m(n.markerOpacity)&&n.markerOpacity<1&&(o=t.globalAlpha,t.globalAlpha*=n.markerOpacity);for(var l=Ae(new ge(a,s),n.markerHorizontalAlignment,n.markerVerticalAlignment),h=0,f=r.length;h<f;h++){var d=r[h],p=this._rotate(t,d,this._getRotationAt(h));p&&(d=p),hn.image(t,i,d.x+l.x,d.y+l.y,a,s),p&&t.restore()}void 0!==o&&(t.globalAlpha=o)}else"undefined"!=typeof console&&console.warn("no img found for "+(this.style.markerFile||this._url[0]))}}},n._getImage=function(t){return t?t.getImage([this.style.markerFile,this.style.markerWidth,this.style.markerHeight]):null},n.getPlacement=function(){return this.symbol.markerPlacement},n.getRotation=function(){var t=this.style.markerRotation;return m(t)?-t*Math.PI/180:null},n.getDxDy=function(){var t=this.style,e=t.markerDx,n=t.markerDy;return new me(e,n)},n.getFixedExtent=function(t){var e=this.style,n=e.markerFile,r=t?t.getImage(n):null,i=e.markerWidth||(r?r.width:0),o=e.markerHeight||(r?r.height:0),a=this.getDxDy(),s=Ae(new ge(i,o),e.markerHorizontalAlignment,e.markerVerticalAlignment),u=new Zn(a.add(0,0),a.add(i,o));u._add(s);var c=this.getRotation();return c&&(u=this._rotateExtent(u,c)),u},n.translate=function(){var t=this.symbol;return{markerFile:t.markerFile,markerOpacity:z(t.markerOpacity,1),markerWidth:z(t.markerWidth,null),markerHeight:z(t.markerHeight,null),markerRotation:z(t.markerRotation,0),markerDx:z(t.markerDx,0),markerDy:z(t.markerDy,0),markerHorizontalAlignment:z(t.markerHorizontalAlignment,"middle"),markerVerticalAlignment:z(t.markerVerticalAlignment,"top")}},e}(Ar),Or=new On(0,0),Rr=new On(0,0),kr=function(t){function e(e,n,r){var i;return(i=t.call(this)||this).symbol=e,i.geometry=n,i.painter=r,"Point"===n.type?de(i):(i.style=i._defineStyle(i.translate()),i)}fe(e,t),e.test=function(t,e){if(!t)return!1;if(e&&"Point"===e.type)return!1;for(var n in t){var r=n.slice(0,4);if("line"===r||"poly"===r)return!0}return!1};var n=e.prototype;return n.symbolize=function(t,e){var n=this.style;if(0!==n.polygonOpacity||0!==n.lineOpacity||this.painter.isHitTesting()){var r=this._getPaintParams();if(r){this._prepareContext(t);var i=Rt(n.lineColor),o="Polygon"===this.geometry.getJSONType()||"LineString"===this.geometry.type;!i||!n.lineColor.places&&o||(n.lineGradientExtent=this.getPainter().getContainerExtent()._expand(n.lineWidth)),Rt(n.polygonFill)&&(n.polygonGradientExtent=this.getPainter().getContainerExtent());var a=r[0];if("Polygon"===this.geometry.getJSONType()&&a.length>0&&Array.isArray(a[0][0])||"LineString"===this.geometry.type&&a.length>0&&Array.isArray(a[0]))for(var s=0;s<a.length;s++){this.prepareCanvas(t,n,e),i&&o&&!n.lineColor.places&&this._createGradient(t,a[s],n.lineColor);var u=[t,a[s]];r.length>1&&u.push.apply(u,r.slice(1)),u.push(n.lineOpacity,n.polygonOpacity,n.lineDasharray),this.geometry._paintOn.apply(this.geometry,u)}else{this.prepareCanvas(t,n,e),i&&o&&!n.lineColor.places&&this._createGradient(t,a,n.lineColor);var c=[t];c.push.apply(c,r),c.push(n.lineOpacity,n.polygonOpacity,n.lineDasharray),this.geometry._paintOn.apply(this.geometry,c)}t.setLineDash&&Array.isArray(n.lineDasharray)&&t.setLineDash([])}}},n.get2DExtent=function(){var t=this.getMap(),e=this.geometry._getPrjExtent();if(!e)return null;this._extMin&&this._extMax||(this._extMin=new On(0,0),this._extMax=new On(0,0)),this._extMin.x=e.xmin,this._extMin.y=e.ymin,this._extMax.x=e.xmax,this._extMax.y=e.ymax;var n=t._prjToPoint(this._extMin,void 0,Or),r=t._prjToPoint(this._extMax,void 0,Rr);return this._pxExtent?this._pxExtent.set(Math.min(n.x,r.x),Math.min(n.y,r.y),Math.max(n.x,r.x),Math.max(n.y,r.y)):this._pxExtent=new Zn(n,r),this._pxExtent},n.getFixedExtent=function(){var t=this.style.lineWidth/2;return new Zn(-t,-t,t,t)},n._getPaintParams=function(){return this.getPainter().getPaintParams(this.style.lineDx,this.style.lineDy)},n.translate=function(){var t=this.symbol,e={lineColor:z(t.lineColor,"#000"),lineWidth:z(t.lineWidth,2),lineOpacity:z(t.lineOpacity,1),lineDasharray:z(t.lineDasharray,[]),lineCap:z(t.lineCap,"butt"),lineJoin:z(t.lineJoin,"miter"),linePatternFile:z(t.linePatternFile,null),lineDx:z(t.lineDx,0),lineDy:z(t.lineDy,0),polygonFill:z(t.polygonFill,null),polygonOpacity:z(t.polygonOpacity,1),polygonPatternFile:z(t.polygonPatternFile,null),polygonPatternDx:z(t.polygonPatternDx,0),polygonPatternDy:z(t.polygonPatternDy,0),linePatternDx:z(t.linePatternDx,0),linePatternDy:z(t.linePatternDy,0)};return 0===e.lineWidth&&(e.lineOpacity=0),"LineString"!==this.geometry.type||e.polygonFill||(e.polygonFill=e.lineColor),e},n._createGradient=function(t,e,n){if(Array.isArray(e)&&e.length){var r=e.length,i=t.createLinearGradient(e[0].x,e[0].y,e[r-1].x,e[r-1].y);n.colorStops.forEach((function(t){i.addColorStop.apply(i,t)})),t.strokeStyle=i}},e}(Sr),Ir="___text_symbol_cache",Dr=function(t){function e(e,n,r){var i;if((i=t.call(this,e,n,r)||this)._dynamic=bt(e),i.style=i._defineStyle(i.translate()),0===i.style.textWrapWidth)return de(i);i.strokeAndFill=i._defineStyle(i.translateLineAndFill(i.style));var o=Ee(i.style.textName,i.geometry.getProperties());return i._dynamic||(i._cacheKey=function(t,e){var n=[t];for(var r in e)e.hasOwnProperty(r)&&r.length>4&&"text"===r.substring(0,4)&&n.push(r+"="+e[r]);return n.join("-")}(o,i.style)),i._descText(o),i}fe(e,t),e.test=function(t){return!!t&&!p(t.textName)};var n=e.prototype;return n.symbolize=function(t,e){if(this.painter.isHitTesting()||0!==this.style.textSize&&(this.style.textOpacity||this.style.textHaloRadius&&this.style.textHaloOpacity)&&0!==this.style.textWrapWidth){var n=this._getRenderContainerPoints();if(U(n)){var r=this.style,i=this.strokeAndFill,o=Ee(this.style.textName,this.geometry.getProperties());this._descText(o),this._prepareContext(t),this.prepareCanvas(t,i,e),hn.prepareCanvasFont(t,r);for(var a=0,s=n.length;a<s;a++){var u=n[a],c=this._rotate(t,u,this._getRotationAt(a));c&&(u=c),hn.text(t,o,u,r,this.textDesc),c&&t.restore()}}}},n.getPlacement=function(){return this.symbol.textPlacement},n.getRotation=function(){var t=this.style.textRotation;return m(t)?-t*Math.PI/180:null},n.getDxDy=function(){var t=this.style;return new me(t.textDx,t.textDy)},n.getFixedExtent=function(){var t=this.getDxDy(),e=this.style,n=this.textDesc.size,r=Ae(n,e.textHorizontalAlignment,e.textVerticalAlignment),i=r.x,o=r.y;if(e.textHaloRadius){var a=e.textHaloRadius;n=n.add(2*a,2*a)}var s=new Zn(t.add(i,o),t.add(i+n.width,o+n.height)),u=this.getRotation();return u&&(s=this._rotateExtent(s,u)),s},n.translate=function(){var t=this.symbol,e={textName:t.textName,textFaceName:z(t.textFaceName,"monospace"),textWeight:z(t.textWeight,"normal"),textStyle:z(t.textStyle,"normal"),textSize:z(t.textSize,h),textFont:z(t.textFont,null),textFill:z(t.textFill,"#000"),textOpacity:z(t.textOpacity,1),textHaloFill:z(t.textHaloFill,"#ffffff"),textHaloRadius:z(t.textHaloRadius,0),textHaloOpacity:z(t.textHaloOpacity,1),textWrapWidth:z(t.textWrapWidth,null),textWrapCharacter:z(t.textWrapCharacter,"\n"),textLineSpacing:z(t.textLineSpacing,0),textDx:z(t.textDx,0),textDy:z(t.textDy,0),textHorizontalAlignment:z(t.textHorizontalAlignment,"middle"),textVerticalAlignment:z(t.textVerticalAlignment,"middle"),textAlign:z(t.textAlign,"center"),textRotation:z(t.textRotation,0),textMaxWidth:z(t.textMaxWidth,0),textMaxHeight:z(t.textMaxHeight,0)};return e.textMaxWidth>0&&(!e.textWrapWidth||e.textWrapWidth>e.textMaxWidth)&&(e.textWrapWidth||(e.textMaxHeight=1),e.textWrapWidth=e.textMaxWidth),e},n.translateLineAndFill=function(t){return{lineColor:t.textHaloRadius?t.textHaloFill:t.textFill,lineWidth:t.textHaloRadius,lineOpacity:t.textOpacity,lineDasharray:null,lineCap:"butt",lineJoin:"round",polygonFill:t.textFill,polygonOpacity:t.textOpacity}},n._descText=function(t){this._dynamic?this.textDesc=this._measureText(t):(this.textDesc=this._loadFromCache(),this.textDesc||(this.textDesc=this._measureText(t),this._storeToCache(this.textDesc)))},n._measureText=function(t){var e=this.style.textMaxHeight,n=Pe(t,this.style);return e&&e<n.size.height&&(n.size.height=e),n},n._storeToCache=function(t){A||(this.geometry[Ir]||(this.geometry[Ir]={}),this.geometry[Ir][this._cacheKey]={desc:t,active:!0})},n._loadFromCache=function(){if(!this.geometry[Ir])return null;var t=this.geometry[Ir][this._cacheKey];return t?(t.active=!0,t.desc):null},e}(Ar);Dr.CACHE_KEY=Ir;var jr,zr=function(t){function e(e,n,r){var i;p(e.markerWidth)&&(e.markerWidth=80),p(e.markerHeight)&&(e.markerHeight=80),e=d(e,(i=t.call(this,e,n,r)||this).translate());var o=i.style=i._defineStyle(e);return he.gecko?i._url=[Ct(o,o.markerWidth,o.markerHeight),o.markerWidth,o.markerHeight]:i._url=[Ct(o),o.markerWidth,o.markerHeight],i}fe(e,t),e.test=function(t){return!!t&&!(!p(t.markerFile)||"path"!==t.markerType)};var n=e.prototype;return n._prepareContext=function(){},n._getImage=function(t){var e=this;if(t&&t.isResourceLoaded(this._url))return t.getImage(this._url);var n=this.painter,r=new Image;return r.onload=function(){var t=n.getLayer()&&n.getLayer().getRenderer();t&&t.setToRedraw()},r.onerror=function(n){n&&"undefined"!=typeof console&&console.warn(n),t.markErrorResource(e._url)},r.src=this._url[0],t&&t.addResource(this._url,r),r},e}(Lr),Nr={lineWidth:1,polygonFill:"#fff",polygonOpacity:.5},Fr=function(t){function e(e,n,r){var i;return(i=t.call(this,e,n,r)||this).style=n.getLayer().options.drawAltitude,i.style&&v(i.style)||(i.style={lineWidth:2}),i.style.lineWidth||(i.style.lineWidth=0),i.dxdy=i._defineStyle({dx:e.textDx||e.markerDx,dy:e.textDy||e.markerDy}),i}fe(e,t),e.test=function(t,e){if(!e.getLayer())return!1;var n=e.getJSONType();return"Marker"===n||"LineString"===n};var n=e.prototype;return n.symbolize=function(t){var e=this.geometry.getLayer();if(e.options.drawAltitude){var n=this.geometry.getProperties();if(n&&n[e.options.altitudeProperty]){var r=this._getStyle();if(this._prepareContext(t),"LineString"===this.geometry.type){var i=this._getPaintParams(r.lineDx,r.lineDy);if(!i)return;var o=this.getPainter().getPaintParams(r.lineDx,r.lineDy,!0)[0];this._drawLineAltitude(t,i[0],o)}else{var a=this._getRenderContainerPoints(),s=this._getRenderContainerPoints(!0);if(!a||0===a.length)return;this._drawMarkerAltitude(t,a[0],s[0])}}}},n.getDxDy=function(){var t=this.dxdy;return new me(t.dx||0,t.dy||0)},n.get2DExtent=function(){return"LineString"===this.geometry.type?kr.prototype.get2DExtent.apply(this):t.prototype.get2DExtent.call(this)},n.getPlacement=function(){return"point"},n._getPaintParams=function(t,e){return this.getPainter().getPaintParams(t||0,e||0)},n._drawMarkerAltitude=function(t,e,n){var r=this._getStyle();this.prepareCanvas(t,r),hn.path(t,[e,n],r.lineOpacity,null,r.lineDasharray)},n._drawLineAltitude=function(t,e,n){var r=this._getStyle();if(e.length>0&&Array.isArray(e[0]))for(var i=0;i<e.length;i++)this._drawLine(t,e[i],n[i]);else this._drawLine(t,e,n);t.setLineDash&&Array.isArray(r.lineDasharray)&&t.setLineDash([])},n._drawLine=function(t,e,n){var r=this._getStyle();this.prepareCanvas(t,r);for(var i=0,o=e.length-1;i<o;i++)hn.polygon(t,[e[i],e[i+1],n[i+1],n[i]],r.lineOpacity,r.polygonOpacity,r.lineDasharray)},n._getStyle=function(){var t=this.geometry.getLayer().options.drawAltitude;return v(t)||(t=Nr),t.lineWidth||(t.lineWidth=0,t.lineOpacity=0),t},e}(Ar),Br=Object.freeze({Symbolizer:Mr,CanvasSymbolizer:Sr,DebugSymbolizer:Pr,ImageMarkerSymbolizer:Lr,PointSymbolizer:Ar,StrokeAndFillSymbolizer:kr,TextMarkerSymbolizer:Dr,VectorMarkerSymbolizer:Cr,VectorPathMarkerSymbolizer:zr,DrawAltitudeSymbolizer:Fr}),Hr=[Fr,kr,Lr,zr,Cr,Dr],Gr=new me(0,0),Ur=new Zn,Wr=new Zn,Vr=new Zn,Zr=new Zn,qr=new Zn,Yr=function(t){function e(e){var n;return(n=t.call(this)||this).geometry=e,n.symbolizers=n._createSymbolizers(),n._altAtGLZoom=n._getGeometryAltitude(),n}fe(e,t);var n=e.prototype;return n.getMap=function(){return this.geometry.getMap()},n.getLayer=function(){return this.geometry.getLayer()},n._createSymbolizers=function(){var t=this.getSymbol(),e=[],n=Hr,r=t;Array.isArray(t)||(r=[t]);for(var i=r.length-1;i>=0;i--)for(var o=r[i],a=n.length-1;a>=0;a--)if(n[a].test(o,this.geometry)){var s=new n[a](o,this.geometry,this);e.push(s),s instanceof Ar&&(this._hasPoint=!0)}if(!e.length&&console){var u=this.geometry.getId();console.warn("invalid symbol for geometry("+(this.geometry?this.geometry.getType()+(u?":"+u:""):"")+") to draw : "+JSON.stringify(t))}return this._debugSymbolizer=new Pr(t,this.geometry,this),e},n.hasPoint=function(){return!!this._hasPoint},n.getRenderPoints=function(t){return this._renderPoints||(this._renderPoints={}),t||(t="center"),this._renderPoints[t]||(this._renderPoints[t]=this.geometry._getRenderPoints(t)),this._renderPoints[t]},n.getPaintParams=function(t,e,n){var r=this.getMap(),i=this.geometry,o=r.getResolution(),a=0!==r.getPitch(),s=0!==r.getBearing(),u=this._cachedParams,c=i._paintAsPath&&i._paintAsPath();if(c&&this._unsimpledParams&&o<=this._unsimpledParams._res)u=this._unsimpledParams;else if(!u||u._res!==r.getResolution()||this._pitched!==a&&i._redrawWhenPitch()||this._rotated!==s&&i._redrawWhenRotate()){if(!(u=i._getPaintParams()))return null;u._res=o,!i._simplified&&c&&(this._unsimpledParams||(this._unsimpledParams=u),o>this._unsimpledParams._res&&(this._unsimpledParams._res=o)),this._cachedParams=u}if(!u)return null;this._pitched=a,this._rotated=s;var l=r.getGLScale(),h=[],f=u[0],d=r.getContainerExtent(),p=this._pointContainerPoints(f,t,e,n,this._hitPoint&&!d.contains(this._hitPoint));if(!p)return null;h.push(p);for(var g=1,v=u.length;g<v;g++)m(u[g])||u[g]instanceof ge?m(u[g])?h.push(u[g]/l):h.push(u[g].multi(1/l)):h.push(u[g]);return h},n._pointContainerPoints=function(t,e,n,r,i,o){if(this._aboveCamera())return null;var a,s=this.getMap(),u=s.getGLZoom(),c=this.containerOffset;function l(t,r){var i=s._pointToContainerPoint(t,u,r)._sub(c);return(e||n)&&i._add(e||0,n||0),i}var h=this.getAltitude();if(Array.isArray(t)){var f,d=this.geometry,p=(f=!i&&d.options.enableClip?this._clip(t,h):{points:t,altitude:h}).points;h=f.altitude,r&&(h=0);var m=h;a=[];for(var g=0,v=p.length;g<v;g++){var y=p[g];if(Array.isArray(y)){for(var _=[],x=0,b=y.length;x<b;x++){var w=y[x];Array.isArray(h)&&(m=h[g]?h[g][x]:0),_.push(l(w,m))}a.push(_)}else Array.isArray(h)&&(m="vertex-last"===o?h[h.length-1-g]:"line"===o?(h[g]+h[g+1])/2:h[g]),a.push(l(y,m))}}else t instanceof me&&(r&&(h=0),a=s._pointToContainerPoint(t,u,h)._sub(c),(e||n)&&a._add(e,n));return a},n._clip=function(t,e){var n=this.getMap(),r=this.geometry,i=this.getSymbol().lineWidth;m(i)||(i=4);var o=n._get2DExtent(void 0,Zr)._expand(i);if(n.getPitch()>0&&e){var a=n.cameraLookAt,s=n.cameraPosition;Gr.set(s.x,s.y),o=o._combine(Gr._add(N(a[0]-s[0]),N(a[1]-s[1])))}var u=t;if(this.get2DExtent(null,qr).within(o))return{points:u,altitude:e};var c=n._get2DExtent(n.getGLZoom(),Zr)._expand(i*n._glScale),l=r.options.smoothness;if(r.getShell&&this.geometry.getHoles&&!l)if(Array.isArray(t[0])){u=[];for(var h=0;h<t.length;h++){var f=_r(t[h],c);f.length&&u.push(f)}}else u=_r(t,c);else if("LineString"===r.getJSONType()&&!l){if(Array.isArray(t[0])){u=[];for(var d=0;d<t.length;d++)I(u,vr(t[d],c,!1,!!l))}else u=vr(t,c,!1,!!l);return this._interpolateSegAlt(u,t,e)}return{points:u,altitude:e}},n._interpolateSegAlt=function(t,e,n){if(!Array.isArray(n)){var r=function(t){return t.point};return{points:t.map((function(t){return Array.isArray(t)?t.map(r):t.point})),altitude:n}}var i=function t(e,n,r){if(!Array.isArray(r))return e;for(var i=[],o=0,a=e.length;o<a;o++)if(Array.isArray(e[o]))i.push(t(e[o],n,r));else{var s=e[o];if(s.point.equals(n[s.index]))s.altitude=r[s.index],i.push(s);else{var u=void 0,c=void 0;0===s.index?(u=s.index,c=s.index+1):(u=s.index-1,c=s.index);var l=s.point.distanceTo(n[c]),h=l/(l+n[u].distanceTo(s.point)),f=B(r[u],r[c],1-h);s.altitude=f,i.push(s)}}return i}(t,e,n);return n=[],{points:i.map((function(t){if(Array.isArray(t)){var e=[],r=t.map((function(t){return e.push(t.altitude),t.point}));return n.push(e),r}return n.push(t.altitude),t.point})),altitude:n}},n.getSymbol=function(){return this.geometry._getInternalSymbol()},n.paint=function(t,e,n){if(this.symbolizers){var r=this.getLayer()._getRenderer();if(r&&(r.context||e)&&(!t||t.intersects(this.get2DExtent(r.resources,Ur)))){var i=this.getMap(),o=this.getMinAltitude(),a=i.getFrustumAltitude();if(!(o&&a&&a<o)){this.containerOffset=n||i._pointToContainerPoint(r.southWest)._add(0,-i.height),this._beforePaint();for(var s=e||r.context,u=[s,r.resources],c=this.symbolizers.length-1;c>=0;c--)this._prepareShadow(s,this.symbolizers[c].symbol),this.symbolizers[c].symbolize.apply(this.symbolizers[c],u);this._afterPaint(),this._painted=!0,this._debugSymbolizer.symbolize.apply(this._debugSymbolizer,u)}}}},n.getSprite=function(t,e){if("Point"!==this.geometry.type)return null;if(this._spriting=!0,!this._sprite&&this.symbolizers.length>0){var n=new Zn;this.symbolizers.forEach((function(e){var r=e.getFixedExtent(t);n._combine(r)}));var r,i=n.getMin().multi(-1),o=e||(this.getMap()?this.getMap().CanvasClass:null),a=hn.createCanvas(n.getWidth(),n.getHeight(),o);this._renderPoints&&(r=this._renderPoints);for(var s=a.getContext("2d"),u=[s,t],c=this.symbolizers.length-1;c>=0;c--){var l=this.symbolizers[c].getDxDy();this._renderPoints={center:[[i.add(l)]]},this._prepareShadow(s,this.symbolizers[c].symbol),this.symbolizers[c].symbolize.apply(this.symbolizers[c],u)}r&&(this._renderPoints=r),this._sprite={canvas:a,offset:n.getCenter()}}return this._spriting=!1,this._sprite},n.isSpriting=function(){return!!this._spriting},n.hitTest=function(t,e){(!e||e<.5)&&(e=.5),jr||(jr=hn.createCanvas(1,1)),hn.setHitTesting(!0),jr.width=jr.height=2*e;var n=jr.getContext("2d");this._hitPoint=t.sub(e,e);try{this.paint(null,n,this._hitPoint)}catch(t){throw t}finally{hn.setHitTesting(!1)}delete this._hitPoint;for(var r=n.getImageData(0,0,jr.width,jr.height).data,i=3,o=r.length;i<o;i+=4)if(r[i]>0)return!0;return!1},n.isHitTesting=function(){return!!this._hitPoint},n._prepareShadow=function(t,e){e.shadowBlur?(t.shadowBlur=this.isHitTesting()?0:e.shadowBlur,t.shadowColor=e.shadowColor||"#000",t.shadowOffsetX=e.shadowOffsetX||0,t.shadowOffsetY=e.shadowOffsetY||0):t.shadowBlur&&(t.shadowBlur=null,t.shadowColor=null,t.shadowOffsetX=null,t.shadowOffsetY=null)},n._eachSymbolizer=function(t,e){if(this.symbolizers){e||(e=this);for(var n=this.symbolizers.length-1;n>=0;n--)t.apply(e,[this.symbolizers[n]])}},n.get2DExtent=function(t,e){this._verifyProjection();var n=this.getMap();t=t||this.getLayer()._getRenderer().resources;var r=n.getZoom(),i=this._isDynamicSize();if(this._extent2D&&this._extent2D._zoom===r&&this._fixedExtent||(this._extent2D&&this._extent2D._zoom!==r&&delete this._extent2D,this.symbolizers&&(this._extent2D||(this._extent2D=this._computeExtent2D(new Zn),this._extent2D._zoom=r),this._fixedExtent||(this._fixedExtent=this._computeFixedExtent(t,new Zn)))),!this._extent2D)return i&&delete this._fixedExtent,null;var o=this._fixedExtent,a=o.xmin,s=o.ymin,u=o.xmax,c=o.ymax;return i&&delete this._fixedExtent,Vr.set(a,-c,u,-s),e?(e.set(this._extent2D.xmin,this._extent2D.ymin,this._extent2D.xmax,this._extent2D.ymax),e._add(Vr),e):this._extent2D.add(Vr)},n._computeExtent2D=function(t){for(var e=this.symbolizers.length-1;e>=0;e--){var n=this.symbolizers[e];t._combine(n.get2DExtent())}return t},n._computeFixedExtent=function(t,e){for(var n=this.symbolizers.length-1;n>=0;n--){var r=this.symbolizers[n];r.getFixedExtent&&e._combine(r.getFixedExtent(t))}return e},n._isDynamicSize=function(){for(var t=this.symbolizers.length-1;t>=0;t--)if(this.symbolizers[t].isDynamicSize())return!0;return!1},n.getContainerExtent=function(t){if(this._aboveCamera())return null;this._verifyProjection();var e=this.getMap(),n=e.getZoom(),r=e._glScale;this._extent2D&&this._extent2D._zoom===n||this.get2DExtent(null,Wr);var i=this.getMinAltitude(),o=this._extent2D.convertTo((function(t){return e._pointToContainerPoint(t,n,i/r,Gr)}),t),a=this.getMaxAltitude();if(a!==i){var s=this._extent2D.convertTo((function(t){return e._pointToContainerPoint(t,n,a/r,Gr)}),Wr);o._combine(s)}var u=this.geometry.getLayer();if("LineString"===this.geometry.type&&a&&u.options.drawAltitude){var c=this._extent2D.convertTo((function(t){return e._pointToContainerPoint(t,n,0,Gr)}),Wr);o._combine(c)}return o&&o._add(this._fixedExtent||this._computeFixedExtent(null,new Zn)),this.geometry.options.smoothness&&o._expand(.15*o.getWidth()),o},n._aboveCamera=function(){var t=this.getMinAltitude(),e=this.getMap().getFrustumAltitude();return t&&e&&e<t},n.getFixedExtent=function(){var t=this.getMap().getZoom();return this._isDynamicSize()?this._computeFixedExtent(null,new Zn):(this._extent2D&&this._extent2D._zoom===t||this.get2DExtent(null,Vr),this._fixedExtent)},n.setZIndex=function(t){this._eachSymbolizer((function(e){e.setZIndex(t)}))},n.show=function(){this._painted?(this.removeCache(),this._eachSymbolizer((function(t){t.show()}))):this.getLayer().isCanvasRender()||this.paint()},n.hide=function(){this._eachSymbolizer((function(t){t.hide()}))},n.repaint=function(){this._altAtGLZoom=this._getGeometryAltitude(),this.removeCache();var t=this.getLayer();if(t){var e=t.getRenderer();e&&e.setToRedraw()&&e.setToRedraw()}},n.refreshSymbol=function(){this.removeCache(),this._removeSymbolizers(),this.symbolizers=this._createSymbolizers()},n.remove=function(){this.removeCache(),this._removeSymbolizers()},n._removeSymbolizers=function(){this._eachSymbolizer((function(t){delete t.painter,t.remove()})),delete this.symbolizers},n.removeCache=function(){delete this._renderPoints,delete this._paintParams,delete this._sprite,delete this._extent2D,delete this._fixedExtent,delete this._cachedParams,delete this._unsimpledParams,this.geometry&&delete this.geometry[Dr.CACHE_KEY]},n.getAltitude=function(){return this.geometry.getAltitude()!==this._propAlt&&(this._altAtGLZoom=this._getGeometryAltitude()),this._altAtGLZoom?this._altAtGLZoom:0},n.getMinAltitude=function(){return this.minAltitude?this.minAltitude:0},n.getMaxAltitude=function(){return this.maxAltitude?this.maxAltitude:0},n._getGeometryAltitude=function(){var t=this;if(!this.getMap())return 0;var e=this.geometry.getAltitude();if(this._propAlt=e,!e)return this.minAltitude=this.maxAltitude=0,0;var n=this.geometry.getCenter();return n?Array.isArray(e)?(this.minAltitude=Number.MAX_VALUE,this.maxAltitude=Number.MIN_VALUE,e.map((function(e){var r=t._meterToPoint(n,e);return r<t.minAltitude&&(t.minAltitude=r),r>t.maxAltitude&&(t.maxAltitude=r),r}))):(this.minAltitude=this.maxAltitude=this._meterToPoint(n,e),this.minAltitude):0},n._meterToPoint=function(t,e){var n=this.getMap(),r=n.getGLZoom();return n.distanceToPoint(e,0,r,t).x*N(e)},n._verifyProjection=function(){var t=this.geometry._getProjection();this._projCode&&this._projCode!==t.code&&this.removeCache(),this._projCode=t.code},n._beforePaint=function(){var t=this.geometry[Dr.CACHE_KEY];if(t)for(var e in t)b(t,e)&&(t[e].active=!1)},n._afterPaint=function(){var t=this.geometry[Dr.CACHE_KEY];if(t)for(var e in t)b(t,e)&&(t[e].active||delete t[e])},e}(Mn),Jr=new Zn,Xr=function(t){function e(e,n){var r;return(r=t.call(this)||this).geometry=e,r.isMask=n,r}fe(e,t);var n=e.prototype;return n._eachPainter=function(t){for(var e,n=this.geometry.getGeometries(),r=0,i=n.length;r<i&&(!(e=this.isMask?n[r]._getMaskPainter():n[r]._getPainter())||!e||!1!==t.call(this,e));r++);},n.paint=function(t){this.geometry&&this._eachPainter((function(e){e.paint(t)}))},n.get2DExtent=function(t,e){e&&e.set(null,null,null,null);var n=e||new Zn;return this._eachPainter((function(e){n=n._combine(e.get2DExtent(t,Jr))})),n},n.getContainerExtent=function(){var t=new Zn;return this._eachPainter((function(e){t=t.combine(e.getContainerExtent())})),t},n.remove=function(){var t=arguments;this._eachPainter((function(e){e.remove.apply(e,t)}))},n.setZIndex=function(){var t=arguments;this._eachPainter((function(e){e.setZIndex.apply(e,t)}))},n.show=function(){var t=arguments;this._eachPainter((function(e){e.show.apply(e,t)}))},n.hide=function(){var t=arguments;this._eachPainter((function(e){e.hide.apply(e,t)}))},n.repaint=function(){var t=arguments;this._eachPainter((function(e){e.repaint.apply(e,t)}))},n.refreshSymbol=function(){var t=arguments;this._eachPainter((function(e){e.refreshSymbol.apply(e,t)}))},n.hasPoint=function(){var t=!1;return this._eachPainter((function(e){return!e.hasPoint()||(t=!0,!1)})),t},n.getMinAltitude=function(){var t=!0,e=0;return this._eachPainter((function(n){var r=n.getMinAltitude();(t||r<e)&&(t=!1,e=r)})),e},n.getMaxAltitude=function(){var t=0;return this._eachPainter((function(e){var n=e.getMaxAltitude();n>t&&(t=n)})),t},e}(Mn),$r={"EPSG:3857":{resolutions:function(){for(var t=[],e=12756274*Math.PI,n=0;n<21;n++)t[n]=e/(256*Math.pow(2,n));return t}(),fullExtent:{top:6378137*Math.PI,left:-6378137*Math.PI,bottom:-6378137*Math.PI,right:6378137*Math.PI}},"EPSG:4326":{fullExtent:{top:90,left:-180,bottom:-90,right:180},resolutions:function(){for(var t=[],e=0;e<20;e++)t[e]=180/(128*Math.pow(2,e));return t}()},BAIDU:{resolutions:function(){for(var t=Math.pow(2,18),e=[],n=0;n<20;n++)e[n]=t,t*=.5;return e}(),fullExtent:{top:33554432,left:-33554432,bottom:-33554432,right:33554432}},IDENTITY:{resolutions:function(){for(var t=Math.pow(2,8),e=[],n=0;n<18;n++)e[n]=t,t*=.5;return e}(),fullExtent:{top:2e5,left:-2e5,bottom:-2e5,right:2e5}}};$r["EPSG:4490"]=$r["EPSG:4326"];var Qr=function(){function t(t){void 0===t&&(t={}),this.options=t,this._initSpatialRef()}t.getProjectionInstance=function(t){if(!t)return null;if(v(t))return t;for(var e in t=(t+"").toLowerCase(),dr)if(b(dr,e)){var n=dr[e].code;if(n&&n.toLowerCase()===t)return dr[e]}return null},t.equals=function(t,e){if(!t&&!e)return!0;if(!t||!e)return!1;if(t.projection!==e.projection)return!1;var n=t.fullExtent,r=e.fullExtent;if(n&&!r||!n&&r)return!1;if(n&&r&&(n.top!==r.top||n.bottom!==r.bottom||n.left!==r.left||n.right!==r.right))return!1;var i=t.resolutions,o=e.resolutions;if(i&&o){if(i.length!==o.length)return!1;for(var a=0;a<i.length;a++)if(i[a]!==o[a])return!1}return!0};var e=t.prototype;return e._initSpatialRef=function(){var e=this.options.projection;if(!(e=e?t.getProjectionInstance(e):fr))throw new Error("must provide a valid projection in map's spatial reference.");(e=d({},Yn,e)).measureLength||d(e,or.DEFAULT),this._projection=e;var n,r=this.options.resolutions;if(!r&&(e.code&&(n=$r[e.code])&&(r=n.resolutions,this.isEPSG="IDENTITY"!==e.code),!r))throw new Error("must provide valid resolutions in map's spatial reference.");this._resolutions=r;var i=this.options.fullExtent;if(!i&&(e.code&&(n=$r[e.code])&&(i=n.fullExtent),!i))throw new Error("must provide a valid fullExtent in map's spatial reference.");if(p(i.left)?(this._fullExtent=new Vn(i),i.left=i.xmin,i.right=i.xmax,i.top=i.ymax,i.bottom=i.ymin):this._fullExtent=new Vn(new On(i.left,i.top),new On(i.right,i.bottom)),p(i.top)||p(i.bottom)||p(i.left)||p(i.right))throw new Error("must provide valid top/bottom/left/right in fullExtent.");d(this._fullExtent,i),this._projection.fullExtent=i;var o=i.right>=i.left?1:-1,a=i.top>=i.bottom?-1:1;this._transformation=new qn([o,a,0,0])},e.getResolutions=function(){return this._resolutions||[]},e.getResolution=function(t){var e=0|t;e<0?e=0:e>this._resolutions.length-1&&(e=this._resolutions.length-1);var n=this._resolutions[e];return e!==t&&t>0&&e<this._resolutions.length-1?n+(this._resolutions[e+1]-n)*(t-e):n},e.getProjection=function(){return this._projection},e.getFullExtent=function(){return this._fullExtent},e.getTransformation=function(){return this._transformation},e.getMinZoom=function(){for(var t=0;t<this._resolutions.length;t++)if(!p(this._resolutions[t]))return t;return 0},e.getMaxZoom=function(){for(var t=this._resolutions.length-1;t>=0;t--)if(!p(this._resolutions[t]))return t;return this._resolutions.length-1},e.getZoomDirection=function(){return N(this._resolutions[this.getMinZoom()]-this._resolutions[this.getMaxZoom()])},e.toJSON=function(){return this.json||(this.json={resolutions:this._resolutions,fullExtent:{top:this._fullExtent.top,left:this._fullExtent.left,bottom:this._fullExtent.bottom,right:this._fullExtent.right},projection:this._projection.code}),this.json},t}(),Kr=function(t){function e(e){var n,r=d({},e),i=r.symbol,o=r.properties,a=r.id;return delete r.symbol,delete r.id,delete r.properties,n=t.call(this,r)||this,i&&n.setSymbol(i),o&&n.setProperties(o),p(a)||n.setId(a),n}fe(e,t);var n=e.prototype;return n.getFirstCoordinate=function(){if("GeometryCollection"===this.type){var t=this.getGeometries();return t.length?t[0].getFirstCoordinate():null}var e=this.getCoordinates();if(!Array.isArray(e))return e;do{e=e[0]}while(Array.isArray(e)&&e.length>0);return e},n.getLastCoordinate=function(){if("GeometryCollection"===this.type){var t=this.getGeometries();return t.length?t[t.length-1].getLastCoordinate():null}var e=this.getCoordinates();if(!Array.isArray(e))return e;do{e=e[e.length-1]}while(Array.isArray(e)&&e.length>0);return e},n.addTo=function(t,e){return t.addGeometry(this,e),this},n.getLayer=function(){return this._layer?this._layer:null},n.getMap=function(){return this._layer?this._layer.getMap():null},n.getId=function(){return this._id},n.setId=function(t){var e=this.getId();return this._id=t,this._fireEvent("idchange",{old:e,new:t}),this},n.getProperties=function(){return this.properties?this.properties:this._getParent()?this._getParent().getProperties():null},n.setProperties=function(t){var e=this.properties;return this.properties=v(t)?d({},t):t,this._repaint(),this._fireEvent("propertieschange",{old:e,new:t}),this},n.getType=function(){return this.type},n.getSymbol=function(){var t=this._symbol;return t?Array.isArray(t)?Dt(t):d({},t):null},n.setSymbol=function(t){return this._symbol=this._prepareSymbol(t),this.onSymbolChanged(),this},n.updateSymbol=function(t){if(!t)return this;var e=this._getSymbol();return e=Dt(e||this._getInternalSymbol(),t),this._eventSymbolProperties=t,this.setSymbol(e)},n.getCenter=function(){return this._computeCenter(this._getMeasurer())},n.getExtent=function(){var t=this._getPrjExtent(),e=this._getProjection();if(t&&e){var n=e.unproject(new On(t.xmin,t.ymin)),r=e.unproject(new On(t.xmax,t.ymax));return new Vn(n,r,e)}return this._computeExtent(this._getMeasurer())},n.getContainerExtent=function(t){var e=this._getPainter();return e?e.getContainerExtent(t):null},n.getSize=function(){var t=this.getContainerExtent();return t?t.getSize():null},n.containsPoint=function(t,e){if(!this.getMap())throw new Error('The geometry is required to be added on a map to perform "containsPoint".');return t instanceof On&&(t=this.getMap().coordToContainerPoint(t)),this._containsPoint(t,e)},n._containsPoint=function(t,e){var n=this._getPainter();return!!n&&(p(e)&&this._hitTestTolerance&&(e=this._hitTestTolerance()),n.hitTest(t,e))},n.show=function(){if(this.options.visible=!0,this.getMap()){var t=this._getPainter();t&&t.show(),this._fireEvent("show")}return this},n.hide=function(){if(this.options.visible=!1,this.getMap()){this.onHide();var t=this._getPainter();t&&t.hide(),this._fireEvent("hide")}return this},n.isVisible=function(){if(!this.options.visible)return!1;var t=this._getInternalSymbol();if(!t)return!0;if(Array.isArray(t)){if(!t.length)return!0;for(var e=0,n=t.length;e<n;e++)if(p(t[e].opacity)||t[e].opacity>0)return!0;return!1}return p(t.opacity)||m(t.opacity)&&t.opacity>0},n.getZIndex=function(){return this.options.zIndex||0},n.setZIndex=function(t){var e=this.options.zIndex;return this.options.zIndex=t,this._fireEvent("zindexchange",{old:e,new:t}),this},n.setZIndexSilently=function(t){return this.options.zIndex=t,this},n.bringToFront=function(){var t=this.getLayer();if(!t||!t.getGeoMaxZIndex)return this;var e=t.getGeoMaxZIndex();return this.setZIndex(e+1),this},n.bringToBack=function(){var t=this.getLayer();if(!t||!t.getGeoMinZIndex)return this;var e=t.getGeoMinZIndex();return this.setZIndex(e-1),this},n.translate=function(t,e){if(p(t))return this;var n=new On(t,e);if(0===n.x&&0===n.y)return this;var r=this.getCoordinates();if(r)if(Array.isArray(r)){var i=j(r,(function(t){return t.add(n)}));this.setCoordinates(i)}else this.setCoordinates(r.add(n));return this},n.flash=function(t,e,n,r){return et.call(this,t,e,n,r)},n.copy=function(){var t=this.toJSON(),n=e.fromJSON(t);return n.options.visible=!0,n},n.remove=function(){return this.getLayer()?(this._fireEvent("removestart"),this._unbind(),this._fireEvent("removeend"),this._fireEvent("remove"),this):this},n.toGeoJSONGeometry=function(){return this._exportGeoJSONGeometry()},n.toGeoJSON=function(t){t||(t={});var e={type:"Feature",geometry:null};if(p(t.geometry)||t.geometry){var n=this._exportGeoJSONGeometry();e.geometry=n}var r,i=this.getId();return p(i)||(e.id=i),(p(t.properties)||t.properties)&&(r=this._exportProperties()),e.properties=r,e},n.toJSON=function(t){t||(t={});var e=this._toJSON(t);return d(e,this._exportGraphicOptions(t)),e},n.getLength=function(){return this._computeGeodesicLength(this._getMeasurer())},n.getArea=function(){return this._computeGeodesicArea(this._getMeasurer())},n.rotate=function(t,e){if("GeometryCollection"===this.type)return this.getGeometries().forEach((function(n){return n.rotate(t,e)})),this;e=e?new On(e):this.getCenter();var n=this._getMeasurer(),r=this.getCoordinates();if(!Array.isArray(r)){if(e.x!==r.x||e.y!==r.y){var i=n._rotate(r,e,t);this.setCoordinates(i)}return this}return j(r,(function(r){return n._rotate(r,e,t)})),this.setCoordinates(r),this},n._getConnectPoints=function(){return[this.getCenter()]},n._initOptions=function(t){var e=d({},t),n=e.symbol,r=e.properties,i=e.id;delete e.symbol,delete e.id,delete e.properties,this.setOptions(e),n&&this.setSymbol(n),r&&this.setProperties(r),p(i)||this.setId(i)},n._bindLayer=function(t){if(this.getLayer())throw new Error("Geometry cannot be added to two or more layers at the same time.");this._layer=t,this._clearCache()},n._prepareSymbol=function(t){if(Array.isArray(t)){for(var e=[],n=0;n<t.length;n++)e.push(Lt(this._checkAndCopySymbol(t[n])));return e}return t?Lt(t=this._checkAndCopySymbol(t)):null},n._checkAndCopySymbol=function(t){var e={};for(var n in t)c[n]&&y(t[n])?e[n]=+t[n]:e[n]=t[n];return e},n._getSymbol=function(){return this._symbol},n._setExternSymbol=function(t){return this._eventSymbolProperties=t,this._externSymbol=this._prepareSymbol(t),this.onSymbolChanged(),this},n._getInternalSymbol=function(){return this._symbol?this._symbol:this._externSymbol?this._externSymbol:this.options.symbol?this.options.symbol:null},n._getPrjExtent=function(){var t=this._getProjection();return this._verifyProjection(),!this._extent&&t&&(this._extent=this._computePrjExtent(t)),this._extent},n._unbind=function(){var t=this.getLayer();t&&(this._animPlayer&&this._animPlayer.finish(),this._clearHandlers(),this._unbindMenu(),this._unbindInfoWindow(),this.isEditing()&&this.endEdit(),this._removePainter(),this.onRemove&&this.onRemove(),t.onRemoveGeometry&&t.onRemoveGeometry(this),delete this._layer,delete this._internalId,delete this._extent)},n._getInternalId=function(){return this._internalId},n._setInternalId=function(t){this._internalId=t},n._getMeasurer=function(){return this._getProjection()?this._getProjection():Qr.getProjectionInstance(this.options.defaultProjection)},n._getProjection=function(){var t=this.getMap();return t?t.getProjection():null},n._verifyProjection=function(){var t=this._getProjection();this._projCode&&t&&this._projCode!==t.code&&this._clearProjection(),this._projCode=t?t.code:this._projCode},n._getExternalResources=function(){return Pt(this._getInternalSymbol())},n._getPainter=function(){var t=this.getLayer();if(!this._painter&&t)if(-1!==o.indexOf(this.type)){if(t.constructor.getCollectionPainterClass){var e=t.constructor.getCollectionPainterClass();this._painter=new e(this)}}else if(t.constructor.getPainterClass){var n=t.constructor.getPainterClass();this._painter=new n(this)}return this._painter},n._getMaskPainter=function(){return this._maskPainter||(this._maskPainter=this.getGeometries&&this.getGeometries()?new Xr(this,!0):new Yr(this)),this._maskPainter},n._removePainter=function(){this._painter&&this._painter.remove(),delete this._painter},n._paint=function(t){this._painter&&this._painter.paint(t)},n._clearCache=function(){delete this._extent},n._clearProjection=function(){delete this._extent},n._repaint=function(){this._painter&&this._painter.repaint()},n.onHide=function(){this.closeMenu(),this.closeInfoWindow()},n.onShapeChanged=function(){this._clearCache(),this._repaint(),this._fireEvent("shapechange")},n.onPositionChanged=function(){this._clearCache(),this._repaint(),this._fireEvent("positionchange")},n.onSymbolChanged=function(){this._painter&&this._painter.refreshSymbol();var t={};this._eventSymbolProperties&&(t.properties=d({},this._eventSymbolProperties),delete this._eventSymbolProperties),this._fireEvent("symbolchange",t)},n.onConfig=function(t){var e;t.properties&&(e=t.properties,delete t.properties);var n=!1;for(var r in t)if(t.hasOwnProperty(r)){var i=r.slice(0,5);if("arrow"===i||"smoot"===i){n=!0;break}}e?(this.setProperties(e),this._repaint()):n&&this._repaint()},n._setParent=function(t){t&&(this._parent=t)},n._getParent=function(){return this._parent},n._fireEvent=function(t,e){this.getLayer()&&this.getLayer()._onGeometryEvent&&(e||(e={}),e.type=t,e.target=this,this.getLayer()._onGeometryEvent(e)),this.fire(t,e)},n._toJSON=function(t){return{feature:this.toGeoJSON(t)}},n._exportGraphicOptions=function(t){var e={};return(p(t.options)||t.options)&&(e.options=this.config()),(p(t.symbol)||t.symbol)&&(e.symbol=this.getSymbol()),(p(t.infoWindow)||t.infoWindow)&&this._infoWinOptions&&(e.infoWindow=this._infoWinOptions),e},n._exportGeoJSONGeometry=function(){var t=this.getCoordinates(),e=On.toNumberArrays(t);return{type:this.getType(),coordinates:e}},n._exportProperties=function(){var t=null,e=this.getProperties();return p(e)||(t=v(e)?d({},e):e),t},n.getAltitude=function(){var t=this.getLayer();if(!t)return 0;var e=t.options,n=this.getProperties(),r=e.enableAltitude&&n?n[e.altitudeProperty]:0,i=t.getAltitude?t.getAltitude():0;return Array.isArray(r)?r.map((function(t){return t+i})):r+i},e}(Tn(xn(En(Mn))));Kr.mergeOptions({id:null,visible:!0,interactive:!0,editable:!0,cursor:null,defaultProjection:"EPSG:4326"});var ti={attribution:null,minZoom:null,maxZoom:null,visible:!0,opacity:1,globalCompositeOperation:null,renderer:"canvas",debugOutline:"#0f0",cssFilter:null,forceRenderOnMoving:!1,forceRenderOnZooming:!1,forceRenderOnRotating:!1,hitDetect:!he.mobile},ei=function(t){function e(e,n){var r,i;return n&&(i=n.canvas,delete n.canvas),(r=t.call(this,n)||this)._canvas=i,r.setId(e),n&&(r.setZIndex(n.zIndex),n.mask&&r.setMask(Kr.fromJSON(n.mask))),r}fe(e,t);var n=e.prototype;return n.load=function(){if(!this.getMap())return this;if(this.onLoad()){this._initRenderer();var t=this.getZIndex();p(t)||(this._renderer.setZIndex(t),this.isCanvasRender()||this._renderer.render()),this.onLoadEnd()}return this},n.getId=function(){return this._id},n.setId=function(t){var e=this._id;return p(t)||(t+=""),this._id=t,this.fire("idchange",{old:e,new:t}),this},n.addTo=function(t){return t.addLayer(this),this},n.setZIndex=function(t){return this._zIndex=t,p(t)?delete this.options.zIndex:this.options.zIndex=t,this.map&&this.map._sortLayersByZIndex(),this._renderer&&this._renderer.setZIndex(t),this},n.getZIndex=function(){return this._zIndex||0},n.getMinZoom=function(){var t=this.getMap(),e=this.options.minZoom;return t?Math.max(t.getMinZoom(),e||0):e},n.getMaxZoom=function(){var t=this.getMap(),e=this.options.maxZoom;return t?Math.min(t.getMaxZoom(),p(e)?1/0:e):e},n.getOpacity=function(){return this.options.opacity},n.setOpacity=function(t){return this.config("opacity",t),this},n.isCanvasRender=function(){var t=this._getRenderer();return t&&t instanceof mr},n.getMap=function(){return this.map?this.map:null},n.getProjection=function(){var t=this.getMap();return t?t.getProjection():null},n.bringToFront=function(){var t=this._getLayerList();if(!t.length)return this;var e=t[t.length-1];if(1===t.length||e===this)return this;var n=e.getZIndex();return this.setZIndex(n+1),this},n.bringToBack=function(){var t=this._getLayerList();if(!t.length)return this;var e=t[0];if(1===t.length||e===this)return this;var n=e.getZIndex();return this.setZIndex(n-1),this},n.show=function(){var t=this;if(!this.options.visible){this.options.visible=!0;var e=this.getRenderer();e&&e.show();var n=this.getMap();e&&n?n.once("renderend",(function(){t.fire("show")})):this.fire("show")}return this},n.hide=function(){var t=this;if(this.options.visible){this.options.visible=!1;var e=this.getRenderer();e&&e.hide();var n=this.getMap();e&&n?n.once("renderend",(function(){t.fire("hide")})):this.fire("hide")}return this},n.isVisible=function(){if(m(this.options.opacity)&&this.options.opacity<=0)return!1;var t=this.getMap();if(t){var e=t.getZoom();if(!p(this.options.maxZoom)&&this.options.maxZoom<e||!p(this.options.minZoom)&&this.options.minZoom>e)return!1}return p(this.options.visible)&&(this.options.visible=!0),this.options.visible},n.remove=function(){return this.map&&this.map.removeLayer(this),this},n.getMask=function(){return this._mask},n.setMask=function(t){if(!("Point"===t.type&&t._isVectorMarker()||"Polygon"===t.type||"MultiPolygon"===t.type))throw new Error("Mask for a layer must be a marker with vector marker symbol or a Polygon(MultiPolygon).");if(t._bindLayer(this),"Point"===t.type?t.updateSymbol({markerLineColor:"rgba(0, 0, 0, 0)",markerFillOpacity:0}):t.setSymbol({lineColor:"rgba(0, 0, 0, 0)",polygonOpacity:0}),this._mask=t,this.options.mask=t.toJSON(),!this.getMap()||this.getMap().isZooming())return this;var e=this._getRenderer();return e&&e.setToRedraw&&this._getRenderer().setToRedraw(),this},n.removeMask=function(){if(delete this._mask,delete this.options.mask,!this.getMap()||this.getMap().isZooming())return this;var t=this._getRenderer();return t&&t.setToRedraw&&this._getRenderer().setToRedraw(),this},n.onLoad=function(){return!0},n.onLoadEnd=function(){},n.isLoaded=function(){return!!this._loaded},n.getRenderer=function(){return this._getRenderer()},n.onConfig=function(t){if(m(t.opacity)||t.cssFilter){var e=this.getRenderer();e&&e.setToRedraw()}},n.onAdd=function(){},n.onRendererCreate=function(){},n.onCanvasCreate=function(){},n.onRemove=function(){},n._bindMap=function(t,e){t&&(this.map=t,p(e)||this.setZIndex(e),this._switchEvents("on",this),this.onAdd(),this.fire("add"))},n._initRenderer=function(){var t=this.options.renderer;if(this.constructor.getRendererClass){var e=this.constructor.getRendererClass(t);if(!e)throw new Error("Invalid renderer for Layer("+this.getId()+"):"+t);this._renderer=new e(this),this._renderer.layer=this,this._renderer.setZIndex(this.getZIndex()),this._switchEvents("on",this._renderer),this._renderer.onAdd&&this._renderer.onAdd(),this.onRendererCreate(),this.fire("renderercreate",{renderer:this._renderer})}},n._doRemove=function(){this._loaded=!1,this.onRemove(),this._switchEvents("off",this),this._renderer&&(this._switchEvents("off",this._renderer),this._renderer.remove(),delete this._renderer),delete this.map},n._switchEvents=function(t,e){e&&e.getEvents&&this.getMap()[t](e.getEvents(),e)},n._getRenderer=function(){return this._renderer},n._getLayerList=function(){return this.map?this.map._layers:[]},n._getMask2DExtent=function(){if(!this._mask||!this.getMap())return null;var t=this._mask._getMaskPainter();return t?t.get2DExtent():null},e}(Tn(xn(pr(Mn))));ei.mergeOptions(ti);var ni=ei.prototype.fire;ei.prototype.fire=function(t,e){return"layerload"===t&&(this._loaded=!0),this.map&&(e||(e={}),e.type=t,e.target=this,this.map._onLayerEvent(e)),ni.apply(this,arguments)};var ri={maxVisualPitch:70,maxPitch:80,centerCross:!1,zoomInCenter:!1,zoomOrigin:null,zoomAnimation:!A,zoomAnimationDuration:330,panAnimation:!A,panAnimationDuration:600,zoomable:!0,enableInfoWindow:!0,hitDetect:!he.mobile,hitDetectLimit:5,fpsOnInteracting:25,layerCanvasLimitOnInteracting:-1,maxZoom:null,minZoom:null,maxExtent:null,fixCenterOnResize:!0,checkSize:!0,checkSizeInterval:1e3,renderer:"canvas",cascadePitches:[10,60]},ii=function(t){function e(n,r){var i;if(!r)throw new Error("Invalid options when creating map.");if(!r.center)throw new Error("Invalid center when creating map.");var o=d({},r),a=o.zoom;delete o.zoom;var s=new On(o.center);delete o.center;var u=o.baseLayer;delete o.baseLayer;var c=o.layers;return delete o.layers,(i=t.call(this,o)||this).VERSION=e.VERSION,Object.defineProperty(de(de(i)),"id",{value:O(),writable:!1}),i._loaded=!1,i._initContainer(n),i._panels={},i._baseLayer=null,i._layers=[],i._zoomLevel=a,i._center=s,i.setSpatialReference(o.spatialReference||o.view),i.setMaxExtent(o.maxExtent),i._mapViewPoint=new me(0,0),i._initRenderer(),i._updateMapSize(i._getContainerDomSize()),u&&i.setBaseLayer(u),c&&i.addLayer(c),i._Load(),i}fe(e,t),e.addOnLoadHook=function(t){var e=Array.prototype.slice.call(arguments,1),n="function"==typeof t?t:function(){this[t].apply(this,e)};return this.prototype._onLoadHooks=this.prototype._onLoadHooks||[],this.prototype._onLoadHooks.push(n),this};var n=e.prototype;return n.isLoaded=function(){return!!this._loaded},n.getContainer=function(){return this._containerDOM},n.getSpatialReference=function(){return this._spatialReference},n.setSpatialReference=function(t){var e=this.options.spatialReference;return this._loaded&&Qr.equals(e,t)||this._updateSpatialReference(t,e),this},n._updateSpatialReference=function(t,e){if(t=d({},t),this._center=this.getCenter(),this.options.spatialReference=t,this._spatialReference=new Qr(t),this.options.spatialReference&&_(this.options.spatialReference.projection)){var n=this._spatialReference.getProjection();this.options.spatialReference.projection=n.code}return this._resetMapStatus(),this._fireEvent("spatialreferencechange",{old:e,new:d({},this.options.spatialReference)}),this},n.onConfig=function(t){var e=t.spatialReference||t.view;return p(e)||this._updateSpatialReference(e,null),this},n.getProjection=function(){return this._spatialReference?this._spatialReference.getProjection():null},n.getFullExtent=function(){return this._spatialReference?this._spatialReference.getFullExtent():null},n.setCursor=function(t){return delete this._cursor,this._trySetCursor(t),this._cursor=t,this},n.resetCursor=function(){return this.setCursor(null)},n.getCenter=function(){return this._loaded&&this._prjCenter?this.getProjection().unproject(this._prjCenter):this._center},n.setCenter=function(t){if(!t)return this;t=new On(t);var e=this.getProjection().project(t);return this._verifyExtent(e)?this._loaded?(this.onMoveStart(),this._setPrjCenter(e),this.onMoveEnd(this._parseEventFromCoord(this.getCenter())),this):(this._center=t,this):this},n.getSize=function(){return p(this.width)||p(this.height)?this._getContainerDomSize():new ge(this.width,this.height)},n.getContainerExtent=function(){var t=this.height,e=this.getPitch(),n=this.options.maxVisualPitch;return n&&e>n&&(t=this._getVisualHeight(n)),new Zn(0,this.height-t,this.width,this.height)},n._getVisualHeight=function(t){t=t||.01;var e=(90-this.getPitch())*Math.PI/180,n=this.getFov()*Math.PI/180;t*=Math.PI/180;var r=this.cameraCenterDistance/this.getGLScale(),i=Math.tan(n/2),o=r*i/(1/Math.tan(t)-i)/Math.sin(t),a=r*(Math.sin(e)*o/(r+Math.cos(e)*o));return this.height/2+a},n.getExtent=function(){return this._pointToExtent(this._get2DExtent())},n.getProjExtent=function(){var t=this._get2DExtent();return new Vn(this._pointToPrj(t.getMin()),this._pointToPrj(t.getMax()))},n.getPrjExtent=function(){return this.getProjExtent()},n.getMaxExtent=function(){return this.options.maxExtent?new Vn(this.options.maxExtent,this.getProjection()):null},n.setMaxExtent=function(t){if(t){var e=new Vn(t,this.getProjection());this.options.maxExtent=e,this._verifyExtent(this._getPrjCenter())||this._panTo(this._prjMaxExtent().getCenter());var n=this.getProjection();this._prjMaxExtent=e.convertTo((function(t){return n.project(t)}))}else delete this.options.maxExtent,delete this._prjMaxExtent;return this},n.getZoom=function(){return this._zoomLevel},n.getZoomForScale=function(t,e,n){var r=this.getZoom();if(p(e)&&(e=r),1===t&&e===r)return r;var i=this._getResolution(e)/t,o=this.getZoomFromRes(i);if(n)return o;var a=1e-6;return this.getSpatialReference().getZoomDirection()<0?Math.ceil(o-a):Math.floor(o+a)},n.getZoomFromRes=function(t){var e=this._getResolutions(),n=this._getResolution(this.getMinZoom()),r=this._getResolution(this.getMaxZoom());if(n<=r){if(t<=n)return this.getMinZoom();if(t>=r)return this.getMaxZoom()}else{if(t>=n)return this.getMinZoom();if(t<=r)return this.getMaxZoom()}for(var i=e.length,o=0;o<i-1;o++)if(e[o]){var a=e[o+1]-e[o],s=t-e[o];if(N(a)===N(s)&&Math.abs(a)>=Math.abs(s))return o+s/a}return i-1},n.setZoom=function(t,e){return void 0===e&&(e={animation:!0}),isNaN(t)||p(t)||(t=+t,this._loaded&&this.options.zoomAnimation&&e.animation?this._zoomAnimation(t):this._zoom(t)),this},n.getMaxZoom=function(){return p(this.options.maxZoom)?this.getMaxNativeZoom():this.options.maxZoom},n.setMaxZoom=function(t){var e=this.getMaxNativeZoom();return t>e&&(t=e),null!==t&&t<this._zoomLevel&&(this.setZoom(t),t=+t),this.options.maxZoom=t,this},n.getMinZoom=function(){return p(this.options.minZoom)?this._spatialReference.getMinZoom():this.options.minZoom},n.setMinZoom=function(t){if(null!==t){t=+t;var e=this._spatialReference.getMinZoom();t<e&&(t=e),t>this._zoomLevel&&this.setZoom(t)}return this.options.minZoom=t,this},n.getMaxNativeZoom=function(){var t=this.getSpatialReference();return t?t.getMaxZoom():null},n.getGLZoom=function(){return this.getMaxNativeZoom()/2},n.getGLScale=function(t){return p(t)&&(t=this.getZoom()),this._getResolution(t)/this._getResolution(this.getGLZoom())},n.zoomIn=function(){return this.setZoom(this.getZoom()+1)},n.zoomOut=function(){return this.setZoom(this.getZoom()-1)},n.isZooming=function(){return!!this._zooming},n.isInteracting=function(){return this.isZooming()||this.isMoving()||this.isRotating()},n.setCenterAndZoom=function(t,e){return p(e)||this._zoomLevel===e?this.setCenter(t):(this.setCenter(t),this.setZoom(e,{animation:!1})),this},n.getFitZoom=function(t,e){var n=this;if(!(t&&t instanceof Vn))return this._zoomLevel;if(t.xmin===t.xmax&&t.ymin===t.ymax)return this.getMaxZoom();var r=this.getSize(),i=t.convertTo((function(t){return n.coordToContainerPoint(t)})),o=i.getWidth(),a=i.getHeight(),s=r.width/o,u=r.height/a,c=this.getSpatialReference().getZoomDirection()<0?Math.max(s,u):Math.min(s,u);return this.getZoomForScale(c,null,e)},n.getView=function(){return{center:this.getCenter().toArray(),zoom:this.getZoom(),pitch:this.getPitch(),bearing:this.getBearing()}},n.setView=function(t){return t?(t.center&&this.setCenter(t.center),null===t.zoom||isNaN(+t.zoom)||this.setZoom(+t.zoom,{animation:!1}),null===t.pitch||isNaN(+t.pitch)||this.setPitch(+t.pitch),null===t.pitch||isNaN(+t.bearing)||this.setBearing(+t.bearing),this):this},n.getResolution=function(t){return this._getResolution(t)},n.getScale=function(t){var e=p(t)?this.getZoom():t,n=this._getResolution(this.getMaxNativeZoom());return this._getResolution(e)/n},n.fitExtent=function(t,e,n,r){if(void 0===n&&(n={}),!t)return this;t=new Vn(t,this.getProjection());var i=this.getFitZoom(t)+(e||0),o=t.getCenter();return void 0===n.animation||n.animation?this._animateTo({center:o,zoom:i},{duration:n.duration||this.options.zoomAnimationDuration,easing:n.easing||"out"},r):this.setCenterAndZoom(o,i)},n.getBaseLayer=function(){return this._baseLayer},n.setBaseLayer=function(t){var e=!1;return this._baseLayer&&(e=!0,this._fireEvent("baselayerchangestart"),this._baseLayer.remove()),t?(this._baseLayer=t,t._bindMap(this,-1),this._baseLayer.on("layerload",(function(){this._fireEvent("baselayerload"),e&&(e=!1,this._fireEvent("baselayerchangeend"))}),this),this._loaded&&this._baseLayer.load(),this._fireEvent("setbaselayer"),this):(delete this._baseLayer,this._fireEvent("baselayerchangeend"),this._fireEvent("setbaselayer"),this)},n.removeBaseLayer=function(){return this._baseLayer&&(this._baseLayer.remove(),delete this._baseLayer,this._fireEvent("baselayerremove")),this},n.getLayers=function(t){return this._getLayers((function(e){return!(e===this._baseLayer||e.getId().indexOf(i)>=0)&&(!t||t(e))}))},n.getLayer=function(t){if(!t)return null;var e=this._layerCache?this._layerCache[t]:null;if(e)return e;var n=this.getBaseLayer();return n&&n.getId()===t?n:null},n.addLayer=function(t){if(!t)return this;if(!Array.isArray(t))return t=Array.prototype.slice.call(arguments,0),this.addLayer(t);this._layerCache||(this._layerCache={});for(var e=this._layers,n=0,r=t.length;n<r;n++){var i=t[n],o=i.getId();if(p(o))throw new Error("Invalid id for the layer: "+o);if(i.getMap()!==this){if(this._layerCache[o])throw new Error("Duplicate layer id in the map: "+o);this._layerCache[o]=i,i._bindMap(this),e.push(i),this._loaded&&i.load()}}return this._sortLayersByZIndex(),this._fireEvent("addlayer",{layers:t}),this},n.removeLayer=function(t){if(!t)return this;if(!Array.isArray(t))return this.removeLayer([t]);for(var e=[],n=0,r=t.length;n<r;n++){var i=t[n];if(i instanceof ei||(i=this.getLayer(i)),i){var o=i.getMap();if(o&&o===this){e.push(i),this._removeLayer(i,this._layers),this._loaded&&i._doRemove();var a=i.getId();this._layerCache&&delete this._layerCache[a]}}}if(e.length>0){var s=this.getRenderer();s&&s.setLayerCanvasUpdated(),this.once("frameend",(function(){e.forEach((function(t){t.fire("remove")}))}))}return this._fireEvent("removelayer",{layers:t}),this},n.sortLayers=function(t){if(!t||!Array.isArray(t))return this;for(var e=[],n=Number.MAX_VALUE,r=0,i=t.length;r<i;r++){var o=t[r];if(y(t[r])&&(o=this.getLayer(o)),!(o instanceof ei&&o.getMap()&&o.getMap()===this))throw new Error("It must be a layer added to this map to order.");o.getZIndex()<n&&(n=o.getZIndex()),e.push(o)}for(var a=0,s=e.length;a<s;a++)e[a].setZIndex(n+a);return this},n.toDataURL=function(t){t||(t={});var e=t.mimeType;e||(e="image/png");var n=t.save,r=this._getRenderer();if(r&&r.toDataURL){var i=t.fileName;i||(i="export");var o=r.toDataURL(e);if(n&&o){var a;if("undefined"!=typeof Blob&&"undefined"!=typeof atob){var s=X(o.replace(/^data:image\/(png|jpeg|jpg);base64,/,""),e);a=URL.createObjectURL(s)}else a=o;var u=document.createElement("a");u.download=i,u.href=a,document.body.appendChild(u),u.click(),document.body.removeChild(u)}return o}return null},n.coordToPoint=function(t,e,n){return this.coordinateToPoint(t,e,n)},n.pointToCoord=function(t,e,n){return this.pointToCoordinate(t,e,n)},n.coordToViewPoint=function(t,e,n){return this.coordinateToViewPoint(t,e,n)},n.viewPointToCoord=function(t,e){return this.viewPointToCoordinate(t,e)},n.coordToContainerPoint=function(t,e,n){return this.coordinateToContainerPoint(t,e,n)},n.containerPointToCoord=function(t,e){return this.containerPointToCoordinate(t,e)},n.containerPointToViewPoint=function(t,e){return e?e.set(t.x,t.y):e=t.copy(),e._sub(this.getViewPoint())},n.viewPointToContainerPoint=function(t,e){return e?e.set(t.x,t.y):e=t.copy(),e._add(this.getViewPoint())},n.checkSize=function(){var t=f()-this._initTime<1500&&0===this.width||0===this.height,e=this._getContainerDomSize(),n=this.height,r=this.width;if(e.width===r&&e.height===n)return this;var i=this.getCenter();if(this.options.fixCenterOnResize)this._updateMapSize(e);else{var o=this._getVisualHeight(this.getPitch()),a=new me(0,this.height-o),s=this._containerPointToPrj(a);this._updateMapSize(e);var u=this._getVisualHeight(this.getPitch()),c=new me(0,this.height-u);this._setPrjCoordAtContainerPoint(s,c),this._mapViewCoord=this._getPrjCenter()}var l=0===e.width||0===e.height||0===r||0===n;return(t||l)&&(this._eventSilence=!0,this.setCenter(i),delete this._eventSilence),this._fireEvent("resize"),this},n.locate=function(t,e,n){return this.getProjection()._locate(new On(t),e,n)},n.getMainPanel=function(){return this._getRenderer().getMainPanel()},n.getPanels=function(){return this._panels},n.remove=function(){var t=this;if(this.isRemoved())return this;this._fireEvent("removestart"),this._removeDomEvents(),this._clearHandlers(),this.removeBaseLayer();for(var e=this.getLayers(),n=0;n<e.length;n++)e[n].remove();return this._getRenderer()&&this._getRenderer().remove(),this._containerDOM.childNodes&&this._containerDOM.childNodes.length>0&&Array.prototype.slice.call(this._containerDOM.childNodes,0).filter((function(t){return"maptalks-wrapper"===t.className})).forEach((function(e){return t._containerDOM.removeChild(e)})),delete this._panels,delete this._containerDOM,delete this.renderer,this._fireEvent("removeend"),this._clearAllListeners(),this},n.isRemoved=function(){return!this._containerDOM},n.isMoving=function(){return!!this._moving},n.onMoveStart=function(t){var e=this._getPrjCenter();this._originCenter&&!this._verifyExtent(e)||(this._originCenter=e),this._moving=!0,this._trySetCursor("move"),this._fireEvent("movestart",this._parseEvent(t?t.domEvent:null,"movestart"))},n.onMoving=function(t){this._fireEvent("moving",this._parseEvent(t?t.domEvent:null,"moving"))},n.onMoveEnd=function(t){if(this._moving=!1,this._trySetCursor("default"),this._fireEvent("moveend",t&&t.domEvent?this._parseEvent(t.domEvent,"moveend"):t),!this._verifyExtent(this._getPrjCenter())&&this._originCenter){var e=this._originCenter;this._panTo(e)}},n.onDragRotateStart=function(t){this._dragRotating=!0,this._fireEvent("dragrotatestart",this._parseEvent(t?t.domEvent:null,"dragrotatestart"))},n.onDragRotating=function(t){this._fireEvent("dragrotating",this._parseEvent(t?t.domEvent:null,"dragrotating"))},n.onDragRotateEnd=function(t){this._dragRotating=!1,this._fireEvent("dragrotateend",this._parseEvent(t?t.domEvent:null,"dragrotateend"))},n.isDragRotating=function(){return!!this._dragRotating},n.getRenderer=function(){return this._getRenderer()},n.getDevicePixelRatio=function(){return this.options.devicePixelRatio||he.devicePixelRatio||1},n._initContainer=function(t){if(y(t)){if(this._containerDOM=document.getElementById(t),!this._containerDOM)throw new Error("Invalid container when creating map: '"+t+"'")}else this._containerDOM=t,A&&(this.CanvasClass=this._containerDOM.constructor);if(this._containerDOM.childNodes&&this._containerDOM.childNodes.length>0&&"maptalks-wrapper"===this._containerDOM.childNodes[0].className)throw new Error("Container is already loaded with another map instance, use map.remove() to clear it.")},n._trySetCursor=function(t){return this._cursor||this._priorityCursor||(t||(t="default"),this._setCursorToPanel(t)),this},n._setPriorityCursor=function(t){if(t)this._priorityCursor=t,this._setCursorToPanel(t);else{var e=!1;this._priorityCursor&&(e=!0),delete this._priorityCursor,e&&this.setCursor(this._cursor)}return this},n._setCursorToPanel=function(t){var e=this.getMainPanel();e&&e.style&&e.style.cursor!==t&&(e.style.cursor=t)},n._removeLayer=function(t,e){if(t&&e){var n=e.indexOf(t);n>-1&&e.splice(n,1)}},n._sortLayersByZIndex=function(){if(this._layers){for(var t=0,e=this._layers.length;t<e;t++)this._layers[t]._order=t;this._layers.sort((function(t,e){var n=t.getZIndex()-e.getZIndex();return 0===n?t._order-e._order:n}))}},n._fireEvent=function(t,e){this._eventSilence||(this.fire("_"+t,e),this.fire(t,e))},n._Load=function(){this._resetMapStatus(),this.options.pitch&&(this.setPitch(this.options.pitch),delete this.options.pitch),this.options.bearing&&(this.setBearing(this.options.bearing),delete this.options.bearing),this._loadAllLayers(),this._getRenderer().onLoad(),this._loaded=!0,this._callOnLoadHooks(),this._initTime=f()},n._initRenderer=function(){var t=this.options.renderer,n=e.getRendererClass(t);this._renderer=new n(this),this._renderer.load()},n._getRenderer=function(){return this._renderer},n._loadAllLayers=function(){this._baseLayer&&this._baseLayer.load(),this._eachLayer((function(t){t&&t.load()}),this.getLayers())},n._getLayers=function(t){for(var e=this._baseLayer?[this._baseLayer].concat(this._layers):this._layers,n=[],r=0;r<e.length;r++)t&&!t.call(this,e[r])||n.push(e[r]);return n},n._eachLayer=function(t){if(!(arguments.length<2)){var e=Array.prototype.slice.call(arguments,1);e&&!Array.isArray(e)&&(e=[e]);for(var n=[],r=0,i=e.length;r<i;r++)n=n.concat(e[r]);for(var o=0,a=n.length;o<a;o++)t.call(t,n[o])}},n._onLayerEvent=function(t){t&&"idchange"===t.type&&(delete this._layerCache[t.old],this._layerCache[t.new]=t.target)},n._resetMapStatus=function(){var t=this.getMaxZoom(),e=this.getMinZoom(),n=this._spatialReference.getMaxZoom(),r=this._spatialReference.getMinZoom();(p(t)||-1===t||t>n)&&this.setMaxZoom(n),(p(e)||-1===e||e<r)&&this.setMinZoom(r),(t=this.getMaxZoom())<(e=this.getMinZoom())&&this.setMaxZoom(e),(p(this._zoomLevel)||this._zoomLevel>t)&&(this._zoomLevel=t),this._zoomLevel<e&&(this._zoomLevel=e),delete this._prjCenter;var i=this.getProjection();this._prjCenter=i.project(this._center),this._calcMatrices();var o=this._getRenderer();o&&o.resetContainer()},n._getContainerDomSize=function(){if(!this._containerDOM)return null;var t,e,n=this._containerDOM;if(p(n.width)||p(n.height)){if(p(n.clientWidth)||p(n.clientHeight))throw new Error("can not get size of container");t=parseInt(n.clientWidth,0),e=parseInt(n.clientHeight,0)}else{t=n.width,e=n.height;var r=this.getDevicePixelRatio();1!==r&&n.layer&&(t/=r,e/=r)}return new ge(t,e)},n._updateMapSize=function(t){return this.width=t.width,this.height=t.height,this._getRenderer().updateMapSize(t),this._calcMatrices(),this},n._getPrjCenter=function(){return this._prjCenter},n._setPrjCenter=function(t){this._prjCenter=t,this.isInteracting()&&!this.isMoving()&&(this._mapViewCoord=t),this._calcMatrices()},n._setPrjCoordAtContainerPoint=function(t,e){if(e.x===this.width/2&&e.y===this.height/2)return this;var n=this._containerPointToPoint(e)._sub(this._prjToPoint(this._getPrjCenter())),r=this._pointToPrj(this._prjToPoint(t).sub(n));return this._setPrjCenter(r),this},n._verifyExtent=function(t){if(!t)return!1;var e=this._prjMaxExtent;return!e||e.contains(t)},n._offsetCenterByPixel=function(t){var e=new me(this.width/2-t.x,this.height/2-t.y),n=this._containerPointToPrj(e);return this._setPrjCenter(n),n},n.offsetPlatform=function(t){return t?(this._getRenderer().offsetPlatform(t),this._mapViewCoord=this._getPrjCenter(),this._mapViewPoint=this._mapViewPoint.add(t),this):this._mapViewPoint},n.getViewPoint=function(){var t=this._getViewPointFrameOffset(),e=this.offsetPlatform();return t&&(e=e.add(t)),e},n._resetMapViewPoint=function(){this._mapViewPoint=new me(0,0),this._mapViewCoord=this._getPrjCenter()},n._getResolution=function(t){return void 0!==t&&t!==this._zoomLevel||void 0===this._mapRes?t===this.getGLZoom()&&void 0!==this._mapGlRes?this._mapGlRes:(p(t)&&(t=this._zoomLevel),this._spatialReference.getResolution(t)):this._mapRes},n._getResolutions=function(){return this._spatialReference.getResolutions()},n._prjToPoint=function(t,e,n){return e=p(e)?this.getZoom():e,this._spatialReference.getTransformation().transform(t,this._getResolution(e),n)},n._pointToPrj=function(t,e,n){return e=p(e)?this.getZoom():e,this._spatialReference.getTransformation().untransform(t,this._getResolution(e),n)},n._pointToPoint=function(t,e,n){return n?(n.x=t.x,n.y=t.y):n=t.copy(),p(e)?n:n._multi(this._getResolution(e)/this._getResolution())},n._pointToPointAtZoom=function(t,e,n){return n?(n.x=t.x,n.y=t.y):n=t.copy(),p(e)?n:n._multi(this._getResolution()/this._getResolution(e))},n._containerPointToPrj=function(t,e){return this._pointToPrj(this._containerPointToPoint(t,void 0,e),void 0,e)},n._callOnLoadHooks=function(){var t=e.prototype;if(t._onLoadHooks)for(var n=0,r=t._onLoadHooks.length;n<r;n++)t._onLoadHooks[n].call(this)},e}(En(xn(pr(Mn))));ii.include({coordinateToPoint:function(){var t=new On(0,0);return function(e,n,r){var i=this.getProjection().project(e,t);return this._prjToPoint(i,n,r)}}(),pointToCoordinate:function(){var t=new On(0,0);return function(e,n,r){var i=this._pointToPrj(e,n,t);return this.getProjection().unproject(i,r)}}(),coordinateToViewPoint:function(){var t=new On(0,0);return function(e,n,r){return this._prjToViewPoint(this.getProjection().project(e,t),n,r)}}(),viewPointToCoordinate:function(){var t=new On(0,0);return function(e,n){return this.getProjection().unproject(this._viewPointToPrj(e,t),n)}}(),coordinateToContainerPoint:function(){var t=new On(0,0);return function(e,n,r){var i=this.getProjection().project(e,t);return this._prjToContainerPoint(i,n,r)}}(),containerPointToCoordinate:function(){var t=new On(0,0);return function(e,n){var r=this._containerPointToPrj(e,t);return this.getProjection().unproject(r,n)}}(),containerToExtent:function(){var t=new me(0,0),e=new me(0,0);return function(n){var r=new Zn(this._containerPointToPoint(n.getMin(t),void 0,t),this._containerPointToPoint(n.getMax(e),void 0,e));return this._pointToExtent(r)}}(),distanceToPixel:function(){var t=new me(0,0),e=new me(0,0);return function(n,r,i){var o=this.getProjection();if(!o)return null;var a=this.getScale()/this.getScale(i),s=this.getCenter(),u=o.locate(s,n,r),c=this.coordToContainerPoint(s,void 0,t),l=this.coordToContainerPoint(u,void 0,e);return l._sub(c)._multi(a)._abs(),new ge(l.x,l.y)}}(),distanceToPoint:function(){var t=new me(0,0);return function(e,n,r,i){var o=this.getProjection();if(!o)return null;var a=i||this.getCenter(),s=o.locate(a,e,n),u=this.coordToPoint(a,r,t),c=this.coordToPoint(s,r);return c._sub(u)._abs(),c}}(),pixelToDistance:function(){var t=new On(0,0),e=new On(0,0);return function(n,r){var i=this.getProjection();if(!i)return null;var o=this.getFullExtent(),a=o.top>o.bottom?-1:1,s=t.set(this.width/2+n,this.height/2+a*r),u=this.containerPointToCoord(s,e);return i.measureLength(this.getCenter(),u)}}(),pointToDistance:function(){var t=new me(0,0),e=new On(0,0);return function(n,r,i){var o=this.getProjection();if(!o)return null;var a=this._prjToPoint(this._getPrjCenter(),i,t);a._add(n,r);var s=this.pointToCoord(a,i,e);return o.measureLength(this.getCenter(),s)}}(),locateByPoint:function(){var t=new me(0,0);return function(e,n,r){var i=this.coordToContainerPoint(e,void 0,t);return this.containerPointToCoord(i._add(n,r))}}(),_get2DExtent:function(){var t=new me(0,0);return function(e,n){var r,i=this;return void 0!==e&&e!==this._zoomLevel||!this._mapExtent2D?e===this.getGLZoom()&&this._mapGlExtent2D&&(r=this._mapGlExtent2D):r=this._mapExtent2D,r?n?(n.set(r.xmin,r.ymin,r.xmax,r.ymax),n):r.copy():this.getContainerExtent().convertTo((function(n){return i._containerPointToPoint(n,e,t)}),n)}}(),_pointToExtent:function(){var t=new On(0,0),e=new On(0,0);return function(n){var r=n.getMin(),i=n.getMax(),o=this.getFullExtent(),a=!o||o.left<=o.right?[r.x,i.x]:[i.x,r.x],s=a[0],u=a[1],c=!o||o.top>o.bottom?[i.y,r.y]:[r.y,i.y],l=c[0],h=c[1],f=r.set(s,h),d=i.set(u,l);return new Vn(this.pointToCoord(f,void 0,t),this.pointToCoord(d,void 0,e),this.getProjection())}}(),_getViewPointFrameOffset:function(){var t=new me(0,0);return function(){if(this.isZooming())return null;var e=this._getPrjCenter();return this._mapViewCoord&&!this._mapViewCoord.equals(e)?this._prjToContainerPoint(this._mapViewCoord)._sub(this._prjToContainerPoint(e,void 0,t)):null}}(),_viewPointToPrj:function(){var t=new me(0,0);return function(e,n){return this._containerPointToPrj(this.viewPointToContainerPoint(e,t),n)}}(),_prjToContainerPoint:function(){var t=new me(0,0);return function(e,n,r,i){return this._pointToContainerPoint(this._prjToPoint(e,n,t),n,i||0,r)}}(),_prjToViewPoint:function(){var t=new me(0,0);return function(e,n,r){var i=this._prjToContainerPoint(e,void 0,t,r);return this.containerPointToViewPoint(i,n)}}(),_viewPointToPoint:function(){var t=new me(0,0);return function(e,n,r){return this._containerPointToPoint(this.viewPointToContainerPoint(e,t),n,r)}}(),_pointToViewPoint:function(){var t=new On(0,0);return function(e,n,r){return this._prjToViewPoint(this._pointToPrj(e,n,t),r)}}()}),ii.mergeOptions(ri);var oi=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.addHooks=function(){this.target&&this.target.on("_dblclick",this._onDoubleClick,this)},n.removeHooks=function(){this.target&&this.target.off("_dblclick",this._onDoubleClick,this)},n._onDoubleClick=function(t){var e=this.target;if(e.options.doubleClickZoom){var n=e.getZoom(),r=t.domEvent.shiftKey?Math.ceil(n)-1:Math.floor(n)+1;e._zoomAnimation(r,t.containerPoint)}},e}(wn);ii.mergeOptions({doubleClickZoom:!0}),ii.addOnLoadHook("addHandler","doubleClickZoom",oi);var ai=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.addHooks=function(){var t=this.target;if(t){var e=t._panels.mapWrapper||t._containerDOM;this._dragHandler=new Ln(e,{cancelOn:this._cancelOn.bind(this),rightclick:!0}),this._dragHandler.on("mousedown",this._onMouseDown,this).on("dragstart",this._onDragStart,this).on("dragging",this._onDragging,this).on("dragend",this._onDragEnd,this).enable()}},n.removeHooks=function(){this._dragHandler.off("mousedown",this._onMouseDown,this).off("dragstart",this._onDragStart,this).off("dragging",this._onDragging,this).off("dragend",this._onDragEnd,this),this._dragHandler.remove(),delete this._dragHandler},n._cancelOn=function(t){return!(!this.target.isZooming()&&!this._ignore(t))},n._ignore=function(t){return!!t&&(t.domEvent&&(t=t.domEvent),this.target._ignoreEvent(t))},n._onMouseDown=function(t){delete this.startDragTime,delete this._mode,2===t.domEvent.button||t.domEvent.ctrlKey?(this.target.options.dragRotate||this.target.options.dragPitch)&&(this._mode="rotatePitch"):this.target.options.dragPan&&(this._mode="move"),this.target._stopAnim(this.target._mapAnimPlayer),Ge(t.domEvent)},n._onDragStart=function(t){this.startDragTime=f(),"move"===this._mode?this._moveStart(t):"rotatePitch"===this._mode&&this._rotateStart(t)},n._onDragging=function(t){this.target._isEventOutMap(t.domEvent)||("move"===this._mode?this._moving(t):"rotatePitch"===this._mode&&this._rotating(t))},n._onDragEnd=function(t){"move"===this._mode?this._moveEnd(t):"rotatePitch"===this._mode&&this._rotateEnd(t),delete this.startDragTime,delete this.startBearing},n._start=function(t){this.preX=t.mousePos.x,this.preY=t.mousePos.y,this.startX=this.preX,this.startY=this.preY},n._moveStart=function(t){this._start(t);var e=this.target;e.onMoveStart(t);var n=qe(e._getActualEvent(t.domEvent),e.getContainer());this.startPrjCoord=e._containerPointToPrj(n)},n._moving=function(t){if(this.startDragTime){var e=this.target,n=qe(e._getActualEvent(t.domEvent),e.getContainer());e._setPrjCoordAtContainerPoint(this.startPrjCoord,n),e.onMoving(t)}},n._moveEnd=function(t){if(this.startDragTime){var e=this.target,n=f()-this.startDragTime,r=t.mousePos.x,i=t.mousePos.y,o=r-this.startX,a=i-this.startY;this._clear(),e.options.panAnimation&&!t.interupted&&e._verifyExtent(e._getPrjCenter())&&n<280&&Math.abs(a)+Math.abs(o)>5?(n=5*n*(Math.abs(o)+Math.abs(a))/500,e.panBy(new me(o,a),{duration:n})):e.onMoveEnd(t)}},n._rotateStart=function(t){this._start(t),delete this._rotateMode,this.startBearing=this.target.getBearing(),this.target.onDragRotateStart(t),this._db=0},n._rotating=function(t){var e=this.target,n=t.mousePos.x,r=t.mousePos.y,i=e.getPitch(),o=e.getBearing(),a=Math.abs(n-this.preX),s=Math.abs(r-this.preY);if(this._rotateMode||(e.options.dragRotatePitch?this._rotateMode="rotate_pitch":this._rotateMode=a>s?"rotate":a<s?"pitch":"rotate"),!("pitch"===this._rotateMode&&0===i&&s<10)){if(this._rotateMode.indexOf("rotate")>=0&&e.options.dragRotate){var u;u=e.options.dragPitch||a>s?-.6*(this.preX-n):n>e.width/2?.6*(this.preY-r):-.6*(this.preY-r);var c=e.getBearing()+u;this._db=this._db||0,this._db+=u,e.setBearing(c)}this._rotateMode.indexOf("pitch")>=0&&e.options.dragPitch&&e.setPitch(e.getPitch()+.4*(this.preY-r)),this.preX=n,this.preY=r,e.getBearing()===o&&e.getPitch()===i||e.onDragRotating(t)}},n._rotateEnd=function(t){var e=this.target,n=e.getBearing();this._clear();var r=f()-this.startDragTime;if(e.onDragRotateEnd(t),Math.abs(n-this.startBearing)>20&&("rotate"===this._rotateMode||"rotate_pitch"===this._rotateMode)&&!t.interupted&&r<400){var i=e.getBearing();e._animateTo({bearing:i+this._db/2},{easing:"out",duration:800})}},n._clear=function(){delete this.startPrjCoord,delete this.preX,delete this.preY,delete this.startX,delete this.startY},e}(wn);ii.mergeOptions({draggable:!0,dragPan:!0,dragRotatePitch:!0,dragRotate:!0,dragPitch:!0}),ii.addOnLoadHook("addHandler","draggable",ai);var si="mousedown mouseup mousemove click dblclick contextmenu touchstart touchmove touchend",ui=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.addHooks=function(){var t=this.target,e=t._panels.allLayers||t._containerDOM;rn(e,si,this._identifyGeometryEvents,this)},n.removeHooks=function(){var t=this.target,e=t._panels.allLayers||t._containerDOM;on(e,si,this._identifyGeometryEvents,this)},n._identifyGeometryEvents=function(t,e){var n=this.target;if(!n.isInteracting()&&!n._ignoreEvent(t)){var r=n._getLayers((function(t){return!(!t.identify||!t.options.geometryEvents)}));if(r.length){var i=null,o=e||t.type;if("mousedown"===o||"touchstart"===o&&1===t.touches.length)this._mouseDownTime=f();else if(("click"===o||"touchend"===o)&&this._mouseDownTime){var a=this._mouseDownTime;if(delete this._mouseDownTime,f()-a>300){if("click"===o)return}else"touchend"===o&&(i="click")}var s=t.touches&&t.touches.length>0?t.touches[0]:t.changedTouches&&t.changedTouches.length>0?t.changedTouches[0]:t;if(s){var u=qe(s,n._containerDOM),c=n.containerPointToCoordinate(u);"touchstart"===o&&Ge(t);var l=null,h={includeInternals:!0,filter:function(e){if(!(e instanceof Kr))return!1;var n=e._getEventTypeToFire(t);if("mousemove"===o){if(!l&&e.options.cursor&&(l=e.options.cursor),!e.listens("mousemove")&&!e.listens("mouseover")&&!e.listens("mouseenter"))return!1}else if(!e.listens(n)&&!e.listens(i))return!1;return!0},count:1,coordinate:c,onlyVisible:n.options.onlyVisibleGeometryEvents,layers:r},d=function(e){var r=!0;if("mousemove"===o){var a={};if(e.length>0)for(var s=e.length-1;s>=0;s--){var u=e[s];if(u instanceof Kr){var c=u._getInternalId();a[c]=u,u._onEvent(t),this._prevOverGeos&&this._prevOverGeos.geomap[c]||u._onEvent(t,"mouseenter"),r=u._onEvent(t,"mouseover")}}n._setPriorityCursor(l);var h=this._prevOverGeos&&this._prevOverGeos.geos;if(this._prevOverGeos={geos:e,geomap:a},h&&h.length>0)for(var f=h.length-1;f>=0;f--){var d=h[f];if(d instanceof Kr){var p=h[f]._getInternalId();a[p]||(r=d._onEvent(t,"mouseout"))}}}else{if(!e||!e.length)return;for(var m=e.length-1;m>=0;m--)if(e[m]instanceof Kr){r=e[m]._onEvent(t),i&&e[m]._onEvent(t,i);break}}!1===r&&Ue(t)}.bind(this);"mousemove"===o||"touchmove"===o?this._queryIdentifyTimeout=n.getRenderer().callInNextFrame((function(){n.isInteracting()||n.identify(h,d)})):n.identify(h,d)}}}},e}(wn);ii.mergeOptions({geometryEvents:!0,onlyVisibleGeometryEvents:!0}),ii.addOnLoadHook("addHandler","geometryEvents",ui);var ci=4.000244140625,li=function(t){function e(e){var n;return(n=t.call(this,e)||this)._thisScrollZoom=n._scrollZoom.bind(de(de(n))),n._wheelZoomRate=1/450,n._defaultZoomRate=.01,n._delta=0,n}fe(e,t);var n=e.prototype;return n.addHooks=function(){Fe(this.target._containerDOM,"wheel",this._onWheelScroll,this)},n.removeHooks=function(){Be(this.target._containerDOM,"wheel",this._onWheelScroll)},n._onWheelScroll=function(t){Ge(t),Ue(t);var e=this.target;if(e._ignoreEvent(t)||!e.options.zoomable)return!1;var n=e._containerDOM,r=e._checkZoomOrigin(qe(t,n));return e.options.seamlessZoom?(this._zooming||(this._trackPadSuspect=0,this._ensureTrackpad=!1),this._seamless(t,r)):this._interval(t,r)},n._seamless=function(t,e){var n=t.deltaMode===window.WheelEvent.DOM_DELTA_LINE?60*t.deltaY:t.deltaY;if(n%ci!=0&&(this._ensureTrackpad||(Math.abs(n)<60?this._trackPadSuspect++:this._trackPadSuspect=0,this._trackPadSuspect>=2&&(this._ensureTrackpad=!0)),this._ensureTrackpad&&(n*=14)),t.shiftKey&&n&&(n/=4),this._lastWheelEvent=t,this._delta-=n,!this._zooming&&this._delta){var r=this.target;this._zoomOrigin=e,r.onZoomStart(null,e)}this._start()},n._start=function(){if(this._delta){this._zooming=!0;var t=this.target;this._active||(t.getRenderer().callInNextFrame(this._thisScrollZoom),this._active=!0)}},n._scrollZoom=function(){var t=this;if(this._active=!1,this._delta){var e=Math.abs(this._delta)>ci?this._wheelZoomRate:this._defaultZoomRate,n=2/(1+Math.exp(-Math.abs(this._delta*e)));this._delta<0&&0!==n&&(n=1/n);var r=this.target,i=r.getZoom(),o=r.getZoomForScale(n,i,!0);this._delta=0,r.onZooming(o,this._zoomOrigin),this._timeout&&clearTimeout(this._timeout),this._timeout=setTimeout((function(){t._zooming=!1,delete t._timeout,r.onZoomEnd(r.getZoom(),t._zoomOrigin)}),210)}},n._interval=function(t,e){var n=this,r=this.target;if(this._zooming)return this._requesting++,!1;this._requesting=0;var i=(t.deltaY?-1*t.deltaY:t.wheelDelta?t.wheelDelta:t.detail)>0?1:-1;t.detail&&(i*=-1);var o=r.getZoom(),a=o+i;return(a=r._checkZoom(i>0?Math.ceil(a):Math.floor(a)))===o||(this._zooming=!0,this._delta||(r.onZoomStart(null,e),this._origin=e,this._delta=i,this._startZoom=r.getZoom()),r._animateTo({zoom:a-1*this._delta/2,around:this._origin},{continueOnViewChanged:!0,easing:"linear",duration:90,wheelZoom:!0},(function(e){"finished"===e.state.playState?n._requesting<1||Math.abs(a-n._startZoom)>2||a===r.getMaxZoom()||a===r.getMinZoom()?(r._animateTo({zoom:a,around:n._origin},{continueOnViewChanged:!0,duration:100},(function(t){"running"!==t.state.playState&&(delete n._zooming,delete n._requesting)})),delete n._startZoom,delete n._origin,delete n._delta,n._requesting=0):p(n._requesting)||(delete n._zooming,n._onWheelScroll(t)):"running"!==e.state.playState&&(delete n._zooming,delete n._requesting)}))),!1},e}(wn);ii.mergeOptions({scrollWheelZoom:!0,seamlessZoom:!1}),ii.addOnLoadHook("addHandler","scrollWheelZoom",li);var hi=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.addHooks=function(){Fe(this.target.getContainer(),"touchstart",this._onTouchStart,this)},n.removeHooks=function(){Be(this.target.getContainer(),"touchstart",this._onTouchStart)},n._onTouchStart=function(t){var e=this.target;if(t.touches&&!(t.touches.length<2)){var n=e.getContainer(),r=qe(t.touches[0],n),i=qe(t.touches[1],n);this.preY=r.y,this._startP1=r,this._startP2=i,this._startDist=r.distanceTo(i),this._startVector=r.sub(i),this._startZoom=e.getZoom(),this._startBearing=e.getBearing(),on(document,"touchmove",this._onTouchMove,this),on(document,"touchend",this._onTouchEnd,this),Fe(document,"touchmove",this._onTouchMove,this),Fe(document,"touchend",this._onTouchEnd,this),Ge(t),e._fireEvent("touchactstart")}},n._onTouchMove=function(t){var e=this.target;if(t.touches&&!(t.touches.length<2)){var n=e.getContainer(),r=qe(t.touches[0],n),i=qe(t.touches[1],n),o=r.sub(this._startP1),a=i.sub(this._startP2),s=r.sub(i),u=r.distanceTo(i)/this._startDist,c=180*s.angleWith(this._startVector)/Math.PI,l=.4*((this.preY||r.y)-r.y);this.preY=r.y;var h={domEvent:t,mousePos:[r,i]};if(this.mode||(e.options.touchRotate&&Math.abs(c)>8?this.mode=e.options.touchZoomRotate?"rotate_zoom":"rotate":e.options.touchPitch&&o.y*a.y>0&&Math.abs(o.y)>10&&Math.abs(a.y)>10?this.mode="pitch":e.options.zoomable&&e.options.touchZoom&&Math.abs(1-u)>.15&&(this.mode=e.options.touchZoomRotate&&e.options.touchRotate?"rotate_zoom":"zoom"),this._startTouching(h)),"zoom"===this.mode||"rotate_zoom"===this.mode){this._scale=u;var f=e._getResolution(this._startZoom)/u,d=e.getZoomFromRes(f);e.onZooming(d,this._Origin)}"rotate"===this.mode||"rotate_zoom"===this.mode?(e.setBearing(this._startBearing+c),e.onDragRotating(h)):"pitch"===this.mode&&(e.setPitch(e.getPitch()+l),e.onDragRotating(h)),e._fireEvent("touchactinging")}},n._startTouching=function(t){var e=this.target;if("zoom"===this.mode||"rotate_zoom"===this.mode){var n=e.getSize();this._Origin=new me(n.width/2,n.height/2),e.onZoomStart(null,this._Origin)}"rotate"!==this.mode&&"pitch"!==this.mode&&"rotate_zoom"!==this.mode||e.onDragRotateStart(t)},n._onTouchEnd=function(t){delete this.preY;var e=this.target;if(on(document,"touchmove",this._onTouchMove,this),on(document,"touchend",this._onTouchEnd,this),"zoom"===this.mode||"rotate_zoom"===this.mode){var n=this._scale,r=e._getResolution(this._startZoom)/n,i=e.getZoomFromRes(r);e.onZoomEnd(i,this._Origin)}"pitch"!==this.mode&&"rotate"!==this.mode&&"rotate_zoom"!==this.mode||e.onDragRotateEnd({domEvent:t}),delete this.mode,e._fireEvent("touchactend")},e}(wn);ii.mergeOptions({touchGesture:!0,touchZoom:!0,touchPitch:!0,touchRotate:!0,touchZoomRotate:!1}),ii.addOnLoadHook("addHandler","touchGesture",hi);var fi="__anim_player",di={in:function(t){return Math.pow(t,2)},out:function(t){return 1-di.in(1-t)},inAndOut:function(t){return 3*t*t-2*t*t*t},linear:function(t){return t},upAndDown:function(t){return t<.5?di.inAndOut(2*t):1-di.inAndOut(2*(t-.5))}},pi=function(t,e){this.state=t,this.styles=e},mi=function(t,e,n,r){this._animation=t,this.options=e,this._onFrame=n,this.playState="idle",this.ready=!0,this.finished=!1,this.target=r},gi={speed:{slow:2e3,normal:1e3,fast:500},_resolveStyles:function(t){if(!t)return null;function e(t){if(!Array.isArray(t))return gi._resolveStyles(t);for(var e=[],n=[],r=[],i=0;i<t.length;i++){var o=gi._resolveStyles(t[i]);o&&(e.push(o[0]),n.push(o[1]),r.push(o[2]))}return e.length?[e,n,r]:null}function n(t){var e,n=t;Array.isArray(t)||(n=m(t)?[0,t]:t instanceof me||t instanceof On?[new(e=t.constructor)(0,0),t]:[t,t]);var r=n[0],i=n[1];return m(r)&&m(i)?r===i?null:[r,i-r,i]:Array.isArray(r)&&m(r[0])||r instanceof On||r instanceof me?(Array.isArray(r)?(r=new On(r),i=new On(i)):(r=new(e=r.constructor)(r),i=new e(i)),r.equals(i)?null:[r,i.sub(r),i]):[r,i,i]}function r(t){return!Array.isArray(t)&&t.constructor===Object||!(!Array.isArray(t)||t[0].constructor!==Object)}var i={},o={},a={};for(var s in t)if(t.hasOwnProperty(s)){var u,c=t[s];if(!c)continue;if(Array.isArray(c)&&(p(c[0])||p(c[1])))continue;(u=r(c)?e(c):n(c))&&(o[s]=u[0],i[s]=u[1],a[s]=u[2])}return[o,i,a]},framing:function(t,e){e||(e={});var n,r,i,o=e.easing?di[e.easing]:di.linear;return o||(o=di.linear),(t=gi._resolveStyles(t))&&(r=t[0],n=t[1],i=t[2]),function(t,e){var a,s;if(t<0)a={playState:"idle",delta:0},s=r;else if(t<e){var u=o(t/e);a={playState:"running",delta:u},s=function t(e,n,r){if(!n||!r)return null;var o={};for(var a in r)if(r.hasOwnProperty(a)){if(n[a]===i[a]){o[a]=n[a];continue}var s=n[a],u=r[a];if(m(u))o[a]=s+e*u;else if(Array.isArray(u)){for(var c=[],l=0;l<u.length;l++)c.push(t(e,s[l],u[l]));o[a]=c}else{var h=u.constructor;o[a]=h===Object?t(e,s,u):s instanceof me||s instanceof On?s.add(u.multi(e)):u}}return o}(u,r,n)}else a={playState:"finished",delta:1},s=i;return a.startStyles=r,a.destStyles=i,a.progress=t,a.remainingMs=e-t,new pi(a,s)}},_requestAnimFrame:function(t){this._frameQueue||(this._frameQueue=[]),this._frameQueue.push(t),this._a()},_a:function(){this._animationFrameId||(this._animationFrameId=T(gi._frameFn))},_run:function(){if(this._frameQueue.length){var t=this._frameQueue;this._frameQueue=[];for(var e=0,n=t.length;e<n;e++)t[e]();this._frameQueue.length?this._animationFrameId=T(gi._frameFn):delete this._animationFrameId}},animate:function(t,e,n,r){e||(e={});var i=gi.framing(t,e);return new mi(i,e,n,r)}};gi._frameFn=gi._run.bind(gi),d(mi.prototype,{_prepare:function(){var t=this.options,e=t.speed||t.duration;y(e)&&((e=gi.speed[e])||(e=+e)),e||(e=gi.speed.normal),this.duration=e,this._framer=t.framer||gi._requestAnimFrame.bind(gi)},play:function(){if("idle"!==this.playState&&"paused"!==this.playState||this.target&&this.target[fi])return this;this.target&&(this.target[fi]=1),"idle"===this.playState&&(this.currentTime=0,this._prepare());var t=f();if(!this.startTime){var e=this.options;this.startTime=e.startTime?e.startTime:t}return this._playStartTime=Math.max(t,this.startTime),"paused"===this.playState&&(this._playStartTime-=this.currentTime),this.playState="running",this._run(),this},pause:function(){return"paused"===this.playState||(this.playState="paused",this._run()),this},cancel:function(){return"idle"===this.playState||(this.playState="idle",this.finished=!1,this._run()),this},finish:function(){return"finished"===this.playState||(this.playState="finished",this.finished=!0,this._run()),this},reverse:function(){},_run:function(){var t=this,e=this._onFrame,n=f(),r=n-this._playStartTime;if(this.options.repeat&&r>=this.duration&&(this._playStartTime=n,r=0),"running"===this.playState){var i=this._animation(r,this.duration);this.playState=i.state.playState,"running"!==this.playState&&this.target&&delete this.target[fi],"idle"===this.playState?this.startTime>n&&setTimeout(this._run.bind(this),this.startTime-n):"running"===this.playState?this._framer((function(){"running"===t.playState&&(t.currentTime=r,e&&e(i),t._run())})):"finished"===this.playState&&(this.finished=!0,e&&e(i))}else if(this.target&&delete this.target[fi],e){"finished"===this.playState?r=this.duration:"idle"===this.playState&&(r=0);var o=this._animation(r,this.duration);o.state.playState=this.playState,e(o)}}});var vi=Object.freeze({Animation:gi,Easing:di,Player:mi,Frame:pi}),yi=vn((function(t){!function(){function e(t,e){var n=t.x-e.x,r=t.y-e.y;return n*n+r*r}function n(t,e,n){var r=e.x,i=e.y,o=n.x-r,a=n.y-i;if(0!==o||0!==a){var s=((t.x-r)*o+(t.y-i)*a)/(o*o+a*a);s>1?(r=n.x,i=n.y):s>0&&(r+=o*s,i+=a*s)}return(o=t.x-r)*o+(a=t.y-i)*a}function r(t,n){for(var r,i=t[0],o=[i],a=1,s=t.length;a<s;a++)e(r=t[a],i)>n&&(o.push(r),i=r);return i!==r&&o.push(r),o}function i(t,e,r,o,a){for(var s,u=o,c=e+1;c<r;c++){var l=n(t[c],t[e],t[r]);l>u&&(s=c,u=l)}u>o&&(s-e>1&&i(t,e,s,o,a),a.push(t[s]),r-s>1&&i(t,s,r,o,a))}function o(t,e){var n=t.length-1,r=[t[0]];return i(t,0,n,e,r),r.push(t[n]),r}function a(t,e,n){if(t.length<=2)return t;var i=void 0!==e?e*e:1;return t=o(t=n?t:r(t,i),i)}t.exports=a,t.exports.default=a}()})),_i=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.getOutline=function(){if(!this._getPainter())return null;var t=this.getExtent();return new bi(t.toArray(),{symbol:{lineWidth:1,lineColor:"6b707b"}})},n.animateShow=function(t,e){var n=this;void 0===t&&(t={}),this._showPlayer&&this._showPlayer.finish(),_(t)&&(e=t={});var r=this.getCoordinates();if(0===r.length)return this;this._animIdx=0,this._animLenSoFar=0,this.show();var i=this.getShell?this.getShell().concat(this.getShell()[0]):this.getCoordinates(),o=this._getProjection(),a=o.projectCoords(i);this._prjAniShowCenter=this._getPrjExtent().getCenter(),this._aniShowCenter=o.unproject(this._prjAniShowCenter);var s=t.duration||1e3,u=t.easing||"out";this.setCoordinates([]);for(var c=0,l=1;l<a.length;l++)c+=a[l].distanceTo(a[l-1]);var h=this._showPlayer=gi.animate({t:s},{duration:s,easing:u},(function(t){if(n.getMap()){var o=n._drawAnimShowFrame(t.styles.t,s,c,i,a);"finished"===t.state.playState&&(delete n._showPlayer,delete n._aniShowCenter,delete n._prjAniShowCenter,delete n._animIdx,delete n._animLenSoFar,delete n._animTailRatio,n.setCoordinates(r)),e&&e(t,o)}else if("finished"!==h.playState&&(h.finish(),e)){var u=n.getCoordinates();e(t,u[u.length-1])}}),this);return h.play(),h},n._drawAnimShowFrame=function(t,e,n,r,i){if(0===t)return r[0];var o,a,s=this._getProjection(),u=t/e*n,c=0;for(o=this._animIdx,a=i.length;o<a-1&&(c=i[o].distanceTo(i[o+1]),!(this._animLenSoFar+c>u));o++)this._animLenSoFar+=c;if(this._animIdx=o,this._animIdx>=a-1)return this.setCoordinates(r),r[r.length-1];var l=this._animIdx,h=i[l],f=i[l+1],d=(u-this._animLenSoFar)/c;this._animTailRatio=d;var p=h.x+(f.x-h.x)*d,m=h.y+(f.y-h.y)*d,g=new On(p,m),v=s.unproject(g),y=!!this.getShell;if(!y&&this.options.smoothness>0){var _=r.slice(0,this._animIdx+3);this.setCoordinates(_);var x=i.slice(0,this._animIdx+3);this._setPrjCoordinates(x)}else{var b=r.slice(0,this._animIdx+1);b.push(v);var w=i.slice(0,this._animIdx+1);w.push(g),y?(this.setCoordinates([this._aniShowCenter].concat(b)),this._setPrjCoordinates([this._prjAniShowCenter].concat(w))):(this.setCoordinates(b),this._setPrjCoordinates(w))}return v},n._getCenterInExtent=function(t,e,n){var r=this.getExtent();if(!t.intersects(r))return null;var i=n(e,t);if(0===i.length)return null;var o=0,a=0,s=0;i.forEach((function(t){Array.isArray(t)?t.forEach((function(t){t.point&&(t=t.point),o+=t.x,a+=t.y,s++})):(t.point&&(t=t.point),o+=t.x,a+=t.y,s++)}));var u=new On(o,a)._multi(1/s);return u.count=s,u},n._getPath2DPoints=function(t,e,n){if(!U(t))return[];var r=this.getMap(),i=!e&&this._shouldSimplify(),o=this.options.simplifyTolerance*r._getResolution(),a=Array.isArray(t[0]);if(delete this._simplified,i&&!a){var s=t.length;t=yi(t,o,!1),this._simplified=t.length<s}return p(n)&&(n=r.getZoom()),j(t,(function(t){return r._prjToPoint(t,n)}))},n._shouldSimplify=function(){var t=this.getLayer(),e=this.getProperties(),n=e&&t.options.enableAltitude&&!p(e[t.options.altitudeProperty]);return t&&t.options.enableSimplify&&!n&&this.options.enableSimplify&&!this._showPlayer},n._setPrjCoordinates=function(t){this._prjCoords=t,this.onShapeChanged()},n._getPrjCoordinates=function(){return this._verifyProjection(),!this._prjCoords&&this._getProjection()&&(this._prjCoords=this._projectCoords(this._coordinates)),this._prjCoords},n._updateCache=function(){this._clearCache(),this._getProjection()&&this._prjCoords&&(this._coordinates=this._unprojectCoords(this._getPrjCoordinates()))},n._clearProjection=function(){this._prjCoords=null,t.prototype._clearProjection.call(this)},n._projectCoords=function(t){var e=this._getProjection();return e?e.projectCoords(t):[]},n._unprojectCoords=function(t){var e=this._getProjection();return e?e.unprojectCoords(t):[]},n._computeCenter=function(){var t=this._coordinates;if(!U(t))return null;for(var e=0,n=0,r=0,i=t.length,o=0;o<i;o++)t[o]&&m(t[o].x)&&m(t[o].y)&&(e+=t[o].x,n+=t[o].y,r++);return new On(e/r,n/r)},n._computeExtent=function(){var t=this._coordinates;if(!U(t))return null;var e=[t];return this.hasHoles&&this.hasHoles()&&e.push.apply(e,this.getHoles()),this._coords2Extent(e,this._getProjection())},n._computePrjExtent=function(){var t=[this._getPrjCoordinates()];return this.hasHoles&&this.hasHoles()&&t.push.apply(t,this._getPrjHoles()),this._coords2Extent(t)},n._get2DLength=function(){for(var t=this._getPath2DPoints(this._getPrjCoordinates(),!0),e=0,n=1,r=t.length;n<r;n++)e+=t[n].distanceTo(t[n-1]);return e},n._hitTestTolerance=function(){var t,e=this._getInternalSymbol();if(Array.isArray(e)){t=0;for(var n=0;n<e.length;n++)m(e[n].lineWidth)&&e[n].lineWidth>t&&(t=e[n].lineWidth)}else t=e.lineWidth;return m(t)?t/2:1.5},n._coords2Extent=function(t,e){for(var n=new Vn(e),r=0,i=t.length;r<i;r++)for(var o=0,a=t[r].length;o<a;o++)n._combine(t[r][o]);return n},e}(Kr);_i.mergeOptions({smoothness:0,enableClip:!0,enableSimplify:!0,simplifyTolerance:2,symbol:{lineColor:"#000",lineWidth:2,lineOpacity:1,polygonFill:"#fff",polygonOpacity:1,opacity:1}});var xi="Polygon",bi=function(t){function e(e,n){var r;return(r=t.call(this,n)||this).type="Polygon",e&&r.setCoordinates(e),r}fe(e,t);var n=e.prototype;return n.setCoordinates=function(t){if(!t)return this._coordinates=null,this._holes=null,this._projectRings(),this;var e=On.toCoordinates(t),n=e.length;if(Array.isArray(e[0])){if(this._coordinates=this._trimRing(e[0]),n>1){for(var r=[],i=1;i<n;i++)e[i]&&r.push(this._trimRing(e[i]));this._holes=r}}else this._coordinates=this._trimRing(e);return this._projectRings(),this},n.getCoordinates=function(){if(!this._coordinates)return[];for(var t=this.getHoles(),e=[this._copyAndCloseRing(this._coordinates)],n=0,r=t.length;n<r;n++)e.push(this._copyAndCloseRing(t[n]));return e},n.getCenterInExtent=function(t){return this._getCenterInExtent(t,this.getShell(),_r)},n.getShell=function(){return this._coordinates||[]},n.getHoles=function(){return this._holes||[]},n.hasHoles=function(){return this.getHoles().length>0},n._projectRings=function(){this.getMap()?(this._prjCoords=this._projectCoords(this._coordinates),this._prjHoles=this._projectCoords(this._holes),this.onShapeChanged()):this.onShapeChanged()},n._setPrjCoordinates=function(t){this._prjCoords=t,this.onShapeChanged()},n._cleanRing=function(t){for(var e=t.length-1;e>=0;e--)t[e]||t.splice(e,1)},n._checkRing=function(t){if(this._cleanRing(t),!t||!U(t))return!1;var e=t[t.length-1],n=!0;return t[0].x===e.x&&t[0].y===e.y||(n=!1),n},n._trimRing=function(t){var e=this._checkRing(t);return U(t)&&e&&t.splice(t.length-1,1),t},n._copyAndCloseRing=function(t){t=t.slice(0);var e=this._checkRing(t);return U(t)&&!e?(t.push(t[0].copy()),t):t},n._getPrjShell=function(){return this.getJSONType()===xi?this._getPrjCoordinates():(this._verifyProjection(),this._getProjection()&&!this._prjShell&&(this._prjShell=this._projectCoords(this.getShell())),this._prjShell)},n._getPrjHoles=function(){var t=this._getProjection();return this._verifyProjection(),t&&!this._prjHoles&&(this._prjHoles=this._projectCoords(this.getHoles())),this._prjHoles},n._computeGeodesicLength=function(t){var e=this.getCoordinates();if(!U(e))return 0;for(var n=0,r=0,i=e.length;r<i;r++)n+=t.measureLength(e[r]);return n},n._computeGeodesicArea=function(t){var e=this.getCoordinates();if(!U(e))return 0;for(var n=t.measureArea(e[0]),r=1,i=e.length;r<i;r++)n-=t.measureArea(e[r]);return n},n._updateCache=function(){t.prototype._updateCache.call(this),this._prjHoles&&(this._holes=this._unprojectCoords(this._getPrjHoles()))},n._clearCache=function(){return delete this._prjShell,t.prototype._clearCache.call(this)},n._clearProjection=function(){this._prjHoles&&(this._prjHoles=null),this._prjShell&&(this._prjShell=null),t.prototype._clearProjection.call(this)},e}(_i);function wi(t){return function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.getCoordinates=function(){return this._coordinates},n.setCoordinates=function(t){var e=t instanceof On?t:new On(t);if(e.equals(this._coordinates))return this;if(this._coordinates=e,!this.getMap())return this.onPositionChanged(),this;var n=this._getProjection();return this._setPrjCoordinates(n.project(this._coordinates)),this},n._getCenter2DPoint=function(t){var e=this.getMap();if(!e)return null;var n=p(t)?e.getZoom():e.getGLZoom(),r=this._getPrjCoordinates();return r?e._prjToPoint(r,n):null},n._getPrjCoordinates=function(){var t=this._getProjection();return this._verifyProjection(),!this._pcenter&&t&&this._coordinates&&(this._pcenter=t.project(this._coordinates)),this._pcenter},n._setPrjCoordinates=function(t){this._pcenter=t,this.onPositionChanged()},n._updateCache=function(){this._clearCache();var t=this._getProjection();this._pcenter&&t&&(this._coordinates=t.unproject(this._pcenter))},n._clearProjection=function(){this._pcenter=null,t.prototype._clearProjection.call(this)},n._computeCenter=function(){return this._coordinates?this._coordinates.copy():null},e}(t)}bi.registerJSONType(xi);var Mi=function(t){function e(e,n){var r;return(r=t.call(this,n)||this).type="Point",e&&r.setCoordinates(e),r}fe(e,t);var n=e.prototype;return n.getOutline=function(){var t=this._getPainter();if(!t)return null;var n=this.getCoordinates(),r=t.getContainerExtent(),i=this.getMap().coordToContainerPoint(n);return new e(n,{symbol:{markerType:"square",markerWidth:r.getWidth(),markerHeight:r.getHeight(),markerLineWidth:1,markerLineColor:"6b707b",markerFill:"rgba(0, 0, 0, 0)",markerDx:r.xmin-(i.x-r.getWidth()/2),markerDy:r.ymin-(i.y-r.getHeight()/2)}})},n._isVectorMarker=function(){var t=this._getInternalSymbol();return!Array.isArray(t)&&Cr.test(t)},n._canEdit=function(){var t=this._getInternalSymbol();return!Array.isArray(t)&&(Cr.test(t)||zr.test(t)||Lr.test(t))},n._containsPoint=function(e,n){var r=this.getContainerExtent();return n&&(r=r.expand(n)),!!r.contains(e)&&(!this.options.hitTestForEvent||t.prototype._containsPoint.call(this,e,n))},n._computeExtent=function(){return Si.call(this,"getCenter")},n._computePrjExtent=function(){return Si.call(this,"_getPrjCoordinates")},n._computeGeodesicLength=function(){return 0},n._computeGeodesicArea=function(){return 0},n._getSprite=function(t,e){return this._getPainter()?this._getPainter().getSprite(t,e):new Yr(this).getSprite(t,e)},e}(wi(Kr));function Si(t){var e=this[t]();return e?new Vn(e,e,this._getProjection()):null}Mi.mergeOptions({symbol:{markerType:"path",markerPath:[{path:"M8 23l0 0 0 0 0 0 0 0 0 0c-4,-5 -8,-10 -8,-14 0,-5 4,-9 8,-9l0 0 0 0c4,0 8,4 8,9 0,4 -4,9 -8,14z M3,9 a5,5 0,1,0,0,-0.9Z",fill:"#DE3333"}],markerPathWidth:16,markerPathHeight:23,markerWidth:24,markerHeight:34},hitTestForEvent:!1}),Mi.registerJSONType("Marker");var Ti=function(t){function e(e,n){var r;return(r=t.call(this,n)||this).type="LineString",e&&r.setCoordinates(e),r}fe(e,t);var n=e.prototype;return n.setCoordinates=function(t){return t?(this._coordinates=On.toCoordinates(t),this.getMap()?this._setPrjCoordinates(this._projectCoords(this._coordinates)):this.onShapeChanged(),this):(this._coordinates=null,this._setPrjCoordinates(null),this)},n.getCoordinates=function(){return this._coordinates||[]},n.getCenterInExtent=function(t){return this._getCenterInExtent(t,this.getCoordinates(),vr)},n._computeGeodesicLength=function(t){return t.measureLength(this.getCoordinates())},n._computeGeodesicArea=function(){return 0},e}(_i);Ti.mergeOptions({arrowStyle:null,arrowPlacement:"vertex-last"}),Ti.registerJSONType("LineString");var Ei=function(t){function e(e,n){var r;return(r=t.call(this,n)||this).type="GeometryCollection",r.setGeometries(e),r}fe(e,t);var n=e.prototype;return n.setGeometries=function(t){for(var e=this._checkGeometries(t||[]),n=this._getSymbol(),r=this.config(),i=e.length-1;i>=0;i--)e[i]._initOptions(r),e[i]._setParent(this),e[i]._setEventParent(this),n&&e[i].setSymbol(n);return this._geometries=e,this.getLayer()&&(this._bindGeometriesToLayer(),this.onShapeChanged()),this},n.getGeometries=function(){return this._geometries||[]},n.forEach=function(t,e){for(var n=this.getGeometries(),r=0,i=n.length;r<i;r++)n[r]&&(e?t.call(e,n[r],r):t(n[r],r));return this},n.filter=function(t,n){if(!t)return new e;var r=[],i=_(t),o=i?t:rt(t);return this.forEach((function(t){var e=i?t:ft(t);(n?o.call(n,e):o(e))&&r.push(t)}),this),new e(r)},n.translate=function(t){if(!t)return this;if(this.isEmpty())return this;var e=arguments;return this.forEach((function(t){t&&t.translate&&t.translate.apply(t,e)})),this},n.isEmpty=function(){return!U(this.getGeometries())},n.remove=function(){return this.forEach((function(t){t._unbind()})),Kr.prototype.remove.apply(this,arguments)},n.show=function(){return this.options.visible=!0,this.forEach((function(t){t.show()})),this},n.hide=function(){return this.options.visible=!1,this.forEach((function(t){t.hide()})),this},n.onConfig=function(t){this.forEach((function(e){e.config(t)}))},n.getSymbol=function(){var e=t.prototype.getSymbol.call(this);if(!e){var n=[],r=!1;this.forEach((function(t){t.getSymbol()&&!r&&(r=!0),n.push(t.getSymbol())})),r&&(e={children:n})}return e},n.setSymbol=function(t){if(t&&t.children)this._symbol=null,this.forEach((function(e,n){e.setSymbol(t.children[n])}));else{var e=this._prepareSymbol(t);this._symbol=e,this.forEach((function(t){t.setSymbol(e)}))}return this.onSymbolChanged(),this},n._setExternSymbol=function(t){return t=this._prepareSymbol(t),this._externSymbol=t,this.forEach((function(e){e._setExternSymbol(t)})),this.onSymbolChanged(),this},n._bindLayer=function(){t.prototype._bindLayer.apply(this,arguments),this._bindGeometriesToLayer()},n._bindGeometriesToLayer=function(){var t=this.getLayer();this.forEach((function(e){e._bindLayer(t)}))},n._checkGeometries=function(t){var e="The geometry added to collection is invalid.";if(t&&!Array.isArray(t)){if(t instanceof Kr)return[t];throw new Error(e)}for(var n=0,r=t.length;n<r;n++)if(!this._checkGeo(t[n]))throw new Error(e+" Index: "+n);return t},n._checkGeo=function(t){return t instanceof Kr},n._updateCache=function(){this._clearCache(),this.isEmpty()||this.forEach((function(t){t&&t._updateCache&&t._updateCache()}))},n._removePainter=function(){this._painter&&this._painter.remove(),delete this._painter,this.forEach((function(t){t._removePainter()}))},n._computeCenter=function(t){if(!t||this.isEmpty())return null;for(var e=0,n=0,r=0,i=this.getGeometries(),o=0,a=i.length;o<a;o++)if(i[o]){var s=i[o]._computeCenter(t);s&&(e+=s.x,n+=s.y,r++)}return 0===r?null:new On(e/r,n/r)},n._containsPoint=function(t,e){if(this.isEmpty())return!1;for(var n=this.getGeometries(),r=0,i=n.length;r<i;r++)if(n[r]._containsPoint(t,e))return!0;return!1},n._computeExtent=function(t){return Ai.call(this,t,"_computeExtent")},n._computePrjExtent=function(t){return Ai.call(this,t,"_computePrjExtent")},n._computeGeodesicLength=function(t){if(!t||this.isEmpty())return 0;for(var e=this.getGeometries(),n=0,r=0,i=e.length;r<i;r++)e[r]&&(n+=e[r]._computeGeodesicLength(t));return n},n._computeGeodesicArea=function(t){if(!t||this.isEmpty())return 0;for(var e=this.getGeometries(),n=0,r=0,i=e.length;r<i;r++)e[r]&&(n+=e[r]._computeGeodesicArea(t));return n},n._exportGeoJSONGeometry=function(){var t=[];if(!this.isEmpty())for(var e=this.getGeometries(),n=0,r=e.length;n<r;n++)e[n]&&t.push(e[n]._exportGeoJSONGeometry());return{type:"GeometryCollection",geometries:t}},n._clearProjection=function(){if(!this.isEmpty())for(var t=this.getGeometries(),e=0,n=t.length;e<n;e++)t[e]&&t[e]._clearProjection()},n._getConnectPoints=function(){var t=this.getExtent();return[new On(t.xmin,t.ymax),new On(t.xmax,t.ymin),new On(t.xmin,t.ymin),new On(t.xmax,t.ymax)]},n._getExternalResources=function(){if(this.isEmpty())return[];for(var t,e,n=this.getGeometries(),r=[],i={},o=0,a=n.length;o<a;o++)if(n[o])for(var s=0,u=(t=Pt(n[o]._getInternalSymbol())).length;s<u;s++)i[e=t[s].join()]||(r.push(t[s]),i[e]=1);return r},n.startEdit=function(t){var e=this;if(this.isEmpty())return this;t||(t={}),t.symbol&&(this._originalSymbol=this.getSymbol(),this.setSymbol(t.symbol)),this._draggbleBeforeEdit=this.options.draggable,this.config("draggable",!1);for(var n=this.getGeometries(),r=0,i=n.length;r<i;r++)n[r].startEdit(t);return this._editing=!0,this.hide(),setTimeout((function(){e.fire("editstart")}),1),this},n.endEdit=function(){if(this.isEmpty())return this;for(var t=this.getGeometries(),e=0,n=t.length;e<n;e++)t[e].endEdit();return this._originalSymbol&&(this.setSymbol(this._originalSymbol),delete this._originalSymbol),this._editing=!1,this.show(),this.config("draggable",this._draggbleBeforeEdit),this.fire("editend"),this},n.isEditing=function(){return!!this._editing},e}(Kr);function Ai(t,e){if(this.isEmpty())return null;for(var n=this.getGeometries(),r=null,i=0,o=n.length;i<o;i++){var a=n[i];if(a){var s=a[e](t);s&&(r=s.combine(r))}}return r}Ei.registerJSONType("GeometryCollection");var Ci=function(t){function e(e,n,r,i){var o;return(o=t.call(this,null,i)||this).GeometryType=e,o.type=n,o._initData(r),o}fe(e,t);var n=e.prototype;return n.getCoordinates=function(){for(var t=[],e=this.getGeometries(),n=0,r=e.length;n<r;n++){var i=e[n];t.push(i.getShell&&"Polygon"!==i.getJSONType()?[i.getShell()]:i.getCoordinates())}return t},n.setCoordinates=function(t){for(var e=[],n=0,r=(t=t||[]).length;n<r;n++){var i=new this.GeometryType(t[n],this.config());e.push(i)}return this.setGeometries(e),this},n._initData=function(t){(t=t||[]).length&&(t[0]instanceof this.GeometryType?this.setGeometries(t):this.setCoordinates(t))},n._checkGeo=function(t){return t instanceof this.GeometryType},n._exportGeoJSONGeometry=function(){var t=this.getCoordinates(),e=On.toNumberArrays(t);return{type:this.getType(),coordinates:e}},e}(Ei),Pi=function(t){function e(e,n){return t.call(this,Mi,"MultiPoint",e,n)||this}return fe(e,t),e.prototype.findClosest=function(t){if(!t)return null;var e=this.getCoordinates(),n=null,r=1/0;return e.forEach((function(e){var i=function(t,e){var n=e.x-t.x,r=e.y-t.y;return Math.sqrt(n*n+r*r)}(e,t);i<r&&(n=e,r=i)})),n},e}(Ci);Pi.registerJSONType("MultiPoint");var Li=function(t){function e(){return t.apply(this,arguments)||this}return fe(e,t),e.prototype.getCenterInExtent=function(t){var e=this.getGeometries(),n=0,r=0,i=0;return e.forEach((function(e){var o=e.getCenterInExtent(t);o&&(n+=o.x*o.count,r+=o.y*o.count,i+=o.count)})),0===i?null:new On(n,r)._multi(1/i)},e}(Ci),Oi=function(t){function e(e,n){return t.call(this,Ti,"MultiLineString",e,n)||this}return fe(e,t),e}(Li);Oi.registerJSONType("MultiLineString");var Ri=function(t){function e(e,n){return t.call(this,bi,"MultiPolygon",e,n)||this}return fe(e,t),e}(Li);Ri.registerJSONType("MultiPolygon");var ki={Marker:Mi,LineString:Ti,Polygon:bi,MultiPoint:Pi,MultiLineString:Oi,MultiPolygon:Ri},Ii={toGeometry:function(t,e){if(y(t)&&(t=k(t)),Array.isArray(t)){for(var n=[],r=0,i=t.length;r<i;r++){var o=Ii._convert(t[r],e);Array.isArray(o)?I(n,o):n.push(o)}return n}return Ii._convert(t,e)},_convert:function(t,e){if(!t||p(t.type))return null;var n=t.type;if("Feature"===n){var r=t.geometry,i=Ii._convert(r);return i?(i.setId(t.id),i.setProperties(t.properties),e&&e(i),i):null}if("FeatureCollection"===n){var o=t.features;return o?Ii.toGeometry(o,e):null}if(["Point","LineString","Polygon","MultiPoint","MultiLineString","MultiPolygon"].indexOf(n)>=0){var a=new ki["Point"===n?"Marker":n](t.coordinates);return e&&e(a),a}if("GeometryCollection"===n){var s=t.geometries;if(!U(s)){var u=new Ei;return e&&e(u),u}for(var c=[],l=s.length,h=0;h<l;h++)c.push(Ii._convert(s[h]));var f=new Ei(c);return e&&e(f),f}return null}},Di=function(t){function e(e,n,r){var i;return i=t.call(this,null,r)||this,e&&i.setCoordinates(e),i._radius=n,i}fe(e,t),e.fromJSON=function(t){var n=t.feature,r=new e(t.coordinates,t.radius,t.options);return r.setProperties(n.properties),r};var n=e.prototype;return n.getRadius=function(){return this._radius},n.setRadius=function(t){return this._radius=t,this.onShapeChanged(),this},n.getShell=function(){for(var t,e,n,r=this._getMeasurer(),i=this.getCoordinates(),o=this.options.numberOfShellPoints,a=this.getRadius(),s=[],u=0,c=o-1;u<c;u++){t=360*u/c*Math.PI/180,e=a*Math.cos(t),n=a*Math.sin(t);var l=r.locate(i,e,n);s.push(l)}return s.push(s[0]),s},n.getHoles=function(){return[]},n.animateShow=function(){return this.show()},n._containsPoint=function(e,n){var r=this.getMap();if(r.getPitch())return t.prototype._containsPoint.call(this,e,n);var i=r._pointToContainerPoint(this._getCenter2DPoint()),o=this.getSize(),a=p(n)?this._hitTestTolerance():n,s=i.add(o.width/2,o.height/2);return wr(e,i,s,a)},n._computePrjExtent=function(t){var e=this._getMinMax(t);if(!e)return null;var n=this._getPrjCoordinates(),r=e.map((function(e){return t.project(e)})),i=r[0].x-n.x,o=r[1].x-n.x,a=r[2].y-n.y,s=r[3].y-n.y;return new Vn(n.add(i,a),n.add(o,s))},n._computeExtent=function(t){var e=this._getMinMax(t);return e?new Vn(e[0].x,e[2].y,e[1].x,e[3].y,this._getProjection()):null},n._getMinMax=function(t){if(!t||!this._coordinates||p(this._radius))return null;var e=this._radius;return[t.locate(this._coordinates,-e,0),t.locate(this._coordinates,e,0),t.locate(this._coordinates,0,e),t.locate(this._coordinates,0,-e)]},n._computeGeodesicLength=function(){return p(this._radius)?0:2*Math.PI*this._radius},n._computeGeodesicArea=function(){return p(this._radius)?0:Math.PI*Math.pow(this._radius,2)},n._exportGeoJSONGeometry=function(){return{type:"Polygon",coordinates:On.toNumberArrays([this.getShell()])}},n._toJSON=function(t){var e=this.getCenter(),n=d({},t);n.geometry=!1;var r=this.toGeoJSON(n);return r.geometry={type:"Polygon"},{feature:r,subType:"Circle",coordinates:[e.x,e.y],radius:this.getRadius()}},e}(wi(bi));Di.mergeOptions({numberOfShellPoints:60}),Di.registerJSONType("Circle");var ji=function(t){function e(e,n,r,i){var o;return o=t.call(this,null,i)||this,e&&o.setCoordinates(e),o.width=n,o.height=r,o}fe(e,t),e.fromJSON=function(t){var n=t.feature,r=new e(t.coordinates,t.width,t.height,t.options);return r.setProperties(n.properties),r};var n=e.prototype;return n.getWidth=function(){return this.width},n.setWidth=function(t){return this.width=t,this.onShapeChanged(),this},n.getHeight=function(){return this.height},n.setHeight=function(t){return this.height=t,this.onShapeChanged(),this},n.getShell=function(){for(var t,e,n,r,i=this._getMeasurer(),o=this.getCoordinates(),a=this.options.numberOfShellPoints,s=this.getWidth(),u=this.getHeight(),c=[],l=Math.pow(s/2,2)*Math.pow(u/2,2),h=Math.pow(s/2,2),f=Math.pow(u/2,2),d=0;d<a;d++){e=(t=360*d/a)*Math.PI/180,n=Math.sqrt(l/(h*Math.pow(Math.tan(e),2)+f)),r=Math.sqrt(l/(f*Math.pow(1/Math.tan(e),2)+h)),t>90&&t<270&&(n*=-1),t>180&&t<360&&(r*=-1);var p=i.locate(o,n,r);c.push(p)}return c},n.getHoles=function(){return[]},n.animateShow=function(){return this.show()},n._containsPoint=function(e,n){var r=this.getMap();if(r.isTransforming())return t.prototype._containsPoint.call(this,e,n);var i=r.getProjection(),o=p(n)?this._hitTestTolerance():n,a=i.projectCoords([this._coordinates,r.locate(this._coordinates,this.getWidth()/2,this.getHeight()/2)]);return wr(e,r._prjToContainerPoint(a[0]),r._prjToContainerPoint(a[1]),o)},n._computePrjExtent=function(){return Di.prototype._computePrjExtent.apply(this,arguments)},n._computeExtent=function(){return Di.prototype._computeExtent.apply(this,arguments)},n._getMinMax=function(t){if(!t||!this._coordinates||p(this.width)||p(this.height))return null;var e=this.getWidth(),n=this.getHeight();return[t.locate(this._coordinates,-e/2,0),t.locate(this._coordinates,e/2,0),t.locate(this._coordinates,0,-n/2),t.locate(this._coordinates,0,n/2)]},n._computeGeodesicLength=function(){if(p(this.width)||p(this.height))return 0;var t=this.width>this.height?this.width:this.height;return 2*Math.PI*t/2-4*Math.abs(this.width-this.height)},n._computeGeodesicArea=function(){return p(this.width)||p(this.height)?0:Math.PI*this.width*this.height/4},n._exportGeoJSONGeometry=function(){return{type:"Polygon",coordinates:On.toNumberArrays([this.getShell()])}},n._toJSON=function(t){var e=d({},t),n=this.getCenter();e.geometry=!1;var r=this.toGeoJSON(e);return r.geometry={type:"Polygon"},{feature:r,subType:"Ellipse",coordinates:[n.x,n.y],width:this.getWidth(),height:this.getHeight()}},e}(wi(bi));ji.mergeOptions({numberOfShellPoints:80}),ji.registerJSONType("Ellipse");var zi=function(t){function e(e,n,r,i){var o;return o=t.call(this,null,i)||this,e&&o.setCoordinates(e),o._width=n,o._height=r,o}fe(e,t),e.fromJSON=function(t){var n=t.feature,r=new e(t.coordinates,t.width,t.height,t.options);return r.setProperties(n.properties),r};var n=e.prototype;return n.getCoordinates=function(){return this._coordinates},n.setCoordinates=function(t){if(this._coordinates=t instanceof On?t:new On(t),!this._coordinates||!this.getMap())return this.onPositionChanged(),this;var e=this._getProjection();return this._setPrjCoordinates(e.project(this._coordinates)),this},n.getWidth=function(){return this._width},n.setWidth=function(t){return this._width=t,this.onShapeChanged(),this},n.getHeight=function(){return this._height},n.setHeight=function(t){return this._height=t,this.onShapeChanged(),this},n.getShell=function(){var t=this._getMeasurer(),e=this._coordinates,n=this.getMap(),r=1,i=-1;if(n){var o=n.getFullExtent();o.left>o.right&&(r=-1),o.bottom>o.top&&(i=1)}var a=[];return a.push(e),a.push(t.locate(e,r*this._width,0)),a.push(t.locate(e,r*this._width,i*this._height)),a.push(t.locate(e,0,i*this._height)),a.push(e),a},n.getHoles=function(){return[]},n.animateShow=function(){return this.show()},n._getPrjCoordinates=function(){var t=this._getProjection();return this._verifyProjection(),!this._pnw&&t&&this._coordinates&&(this._pnw=t.project(this._coordinates)),this._pnw},n._setPrjCoordinates=function(t){this._pnw=t,this.onPositionChanged()},n._getPrjShell=function(){var e=t.prototype._getPrjShell.call(this),n=this._getProjection();if(!n.isSphere())return e;for(var r=n.getSphereExtent(),i=r.sx,o=r.sy,a=this._getProjection().getCircum(),s=e[0],u=1,c=e.length;u<c;u++){var l=e[u],h=0,f=0;i*(s.x-l.x)>0&&(h=a.x*i),o*(s.y-l.y)<0&&(f=a.y*o),e[u]._add(h,f)}return e},n._updateCache=function(){this._clearCache();var t=this._getProjection();this._pnw&&t&&(this._coordinates=t.unproject(this._pnw))},n._clearProjection=function(){this._pnw=null,t.prototype._clearProjection.call(this)},n._computeCenter=function(t){return t.locate(this._coordinates,this._width/2,-this._height/2)},n._containsPoint=function(e,n){var r=this.getMap();if(r.isTransforming())return t.prototype._containsPoint.call(this,e,n);var i=p(n)?this._hitTestTolerance():n,o=r._getResolution()*i,a=this._getPrjExtent().expand(o),s=r._containerPointToPrj(e);return a.contains(s)},n._computePrjExtent=function(t){var e=this._getSouthEast(t);if(!e)return null;var n=t.projectCoords([new On(this._coordinates.x,e.y),new On(e.x,this._coordinates.y)]);return new Vn(n[0],n[1])},n._computeExtent=function(t){var e=this._getSouthEast(t);return e?new Vn(this._coordinates,e,this._getProjection()):null},n._getSouthEast=function(t){if(!t||!this._coordinates||p(this._width)||p(this._height))return null;var e=this.getWidth(),n=-this.getHeight();if(t.fullExtent){var r=t.fullExtent;e*=r.right>r.left?1:-1,n*=r.top>r.bottom?1:-1}return t.locate(this._coordinates,e,n)},n._computeGeodesicLength=function(){return p(this._width)||p(this._height)?0:2*(this._width+this._height)},n._computeGeodesicArea=function(){return p(this._width)||p(this._height)?0:this._width*this._height},n._exportGeoJSONGeometry=function(){return{type:"Polygon",coordinates:On.toNumberArrays([this.getShell()])}},n._toJSON=function(t){var e=d({},t),n=this.getCoordinates();e.geometry=!1;var r=this.toGeoJSON(e);return r.geometry={type:"Polygon"},{feature:r,subType:"Rectangle",coordinates:[n.x,n.y],width:this.getWidth(),height:this.getHeight()}},e}(bi);zi.registerJSONType("Rectangle");var Ni=function(t){function e(e,n,r,i,o){var a;return(a=t.call(this,e,n,o)||this).startAngle=r,a.endAngle=i,a}fe(e,t),e.fromJSON=function(t){var n=t.feature,r=new e(t.coordinates,t.radius,t.startAngle,t.endAngle,t.options);return r.setProperties(n.properties),r};var n=e.prototype;return n.getStartAngle=function(){return this.startAngle},n.setStartAngle=function(t){return this.startAngle=t,this.onShapeChanged(),this},n.getEndAngle=function(){return this.endAngle},n.setEndAngle=function(t){return this.endAngle=t,this.onShapeChanged(),this},n.getShell=function(){for(var t,e,n,r=this._getMeasurer(),i=this.getCoordinates(),o=this.options.numberOfShellPoints-2,a=this.getRadius(),s=[i.copy()],u=this.getStartAngle(),c=this.getEndAngle()-u,l=0;l<o;l++){t=(c*l/(o-1)+u)*Math.PI/180,e=a*Math.cos(t),n=a*Math.sin(t);var h=r.locate(i,e,n);s.push(h)}return s.push(i.copy()),s},n._containsPoint=function(e,n){var r=this.getMap();if(r.isTransforming())return t.prototype._containsPoint.call(this,e,n);var i,o=r._pointToContainerPoint(this._getCenter2DPoint()),a=p(n)?this._hitTestTolerance():n,s=this.getSize(),u=o,c=e,l=c.x-u.x,h=u.y-c.y,f=Math.atan2(h,l),d=f<0?360*(f+2*Math.PI)/(2*Math.PI):360*f/(2*Math.PI),m=this.startAngle%360,g=this.endAngle%360;return i=m>g?!(d>g&&d<m):d>=m&&d<=g,c.distanceTo(u)<=s.width/2+a&&i},n._computeGeodesicLength=function(){return p(this._radius)?0:2*Math.PI*this._radius*Math.abs(this.startAngle-this.endAngle)/360+2*this._radius},n._computeGeodesicArea=function(){return p(this._radius)?0:Math.PI*Math.pow(this._radius,2)*Math.abs(this.startAngle-this.endAngle)/360},n._toJSON=function(t){var e=d({},t),n=this.getCenter();e.geometry=!1;var r=this.toGeoJSON(e);return r.geometry={type:"Polygon"},{feature:r,subType:"Sector",coordinates:[n.x,n.y],radius:this.getRadius(),startAngle:this.getStartAngle(),endAngle:this.getEndAngle()}},e}(Di);Ni.mergeOptions({numberOfShellPoints:60}),Ni.registerJSONType("Sector");var Fi=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n._arc=function(t,e,n){for(var r=this.options.arcDegree*Math.PI/180,i=1,o=e.length;i<o;i++){var a=hn._arcBetween(t,e[i-1],e[i],r),s=[e[i-1].x+e[i].x-a[0],e[i-1].y+e[i].y-a[1]];e[i-1].nextCtrlPoint=s,e[i].prevCtrlPoint=s,hn._stroke(t,n)}},n._quadraticCurve=function(t,e){if(e.length<=2)hn._path(t,e);else{var n,r;for(n=2,r=e.length;n<r;n+=2)t.quadraticCurveTo(e[n-1].x,e[n-1].y,e[n].x,e[n].y);if((n-=1)<r)for(;n<r;n++)t.lineTo(e[n].x,e[n].y)}},n._bezierCurve=function(t,e){if(e.length<=3)hn._path(t,e);else{var n,r;for(n=1,r=e.length;n+2<r;n+=3)t.bezierCurveTo(e[n].x,e[n].y,e[n+1].x,e[n+1].y,e[n+2].x,e[n+2].y);if(n<r)for(;n<r;n++)t.lineTo(e[n].x,e[n].y)}},n._getCurveArrowPoints=function(t,e,n,r,i,o){var a,s=e.length;for(a=o;a<s;a+=o){var u=this._getArrowShape(e[a-1],e[a],n,r,i);u&&t.push(u)}if((a-=o)<s-1)for(a+=1;a<s;a++){var c=this._getArrowShape(e[a-1],e[a],n,r,i);c&&t.push(c)}},e}(Ti);Fi.mergeOptions({enableSimplify:!1,enableClip:!1});var Bi=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n._toJSON=function(t){return{feature:this.toGeoJSON(t),subType:"ArcCurve"}},n._paintOn=function(t,e,n){t.beginPath(),this._arc(t,e,n),hn._stroke(t,n),this._paintArrow(t,e,n)},e.fromJSON=function(t){var n=t.feature,r=new e(n.geometry.coordinates,t.options);return r.setProperties(n.properties),r},e}(Fi);Bi.registerJSONType("ArcCurve"),Bi.mergeOptions({arcDegree:90});var Hi=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t),e.fromJSON=function(t){var n=t.feature,r=new e(n.geometry.coordinates,t.options);return r.setProperties(n.properties),r};var n=e.prototype;return n._toJSON=function(t){return{feature:this.toGeoJSON(t),subType:"CubicBezierCurve"}},n._paintOn=function(t,e,n){t.beginPath(),t.moveTo(e[0].x,e[0].y),this._bezierCurve(t,e),hn._stroke(t,n),this._paintArrow(t,e,n)},n._getArrowPoints=function(t,e,n,r,i){return this._getCurveArrowPoints(t,e,n,r,i,3)},e}(Fi);Hi.registerJSONType("CubicBezierCurve");var Gi=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t),e.fromJSON=function(t){var n=t.feature,r=new e(n.geometry.coordinates,t.options);return r.setProperties(n.properties),r};var n=e.prototype;return n._toJSON=function(t){return{feature:this.toGeoJSON(t),subType:"QuadBezierCurve"}},n._paintOn=function(t,e,n){t.beginPath(),t.moveTo(e[0].x,e[0].y),this._quadraticCurve(t,e,n),hn._stroke(t,n),this._paintArrow(t,e,n)},n._getArrowPoints=function(t,e,n,r,i){return this._getCurveArrowPoints(t,e,n,r,i,2)},e}(Fi);Gi.registerJSONType("QuadBezierCurve");var Ui={textFaceName:"monospace",textSize:12,textLineSpacing:8,textWrapCharacter:"\n",textHorizontalAlignment:"middle",textVerticalAlignment:"middle"},Wi={markerType:"square",markerLineColor:"#000",markerLineWidth:2,markerLineOpacity:1,markerFill:"#fff",markerOpacity:1},Vi=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.getContent=function(){return this._content},n.setContent=function(t){var e=this._content;return this._content=_e(t),this._refresh(),this._fireEvent("contentchange",{old:e,new:t}),this},n.onAdd=function(){this._refresh()},n.toJSON=function(){var e=t.prototype.toJSON.call(this);return delete e.symbol,e},n.setSymbol=function(e){if(this._refreshing||!e)return t.prototype.setSymbol.call(this,e);var n=this._parseSymbol(e);if(this.setTextStyle){var r=this.getTextStyle()||{};r.symbol=n[0],this.setTextStyle(r)}else this.setTextSymbol&&this.setTextSymbol(n[0]);if(this.setBoxStyle){var i=this.getBoxStyle()||{};i.symbol=n[1],this.setBoxStyle(i)}else this.setBoxSymbol&&this.setBoxSymbol(n[1]);return this},n._parseSymbol=function(t){var e={},n={};for(var r in t)b(t,r)&&(0===r.indexOf("text")?e[r]=t[r]:n[r]=t[r]);return[e,n]},n._getTextSize=function(t){return Pe(this._content,t).size},n._getInternalSymbol=function(){return this._symbol},n._getDefaultTextSymbol=function(){return d({},Ui)},n._getDefaultBoxSymbol=function(){return d({},Wi)},n._getDefaultPadding=function(){return[12,8]},e}(Mi),Zi=function(t){function e(e,n,r,i,o){var a;return void 0===o&&(o={}),(a=t.call(this,n,o)||this)._content=_e(e),a._width=p(r)?100:r,a._height=p(i)?40:i,o.boxSymbol&&a.setBoxSymbol(o.boxSymbol),o.textStyle&&a.setTextStyle(o.textStyle),a._refresh(),a}fe(e,t);var n=e.prototype;return n.getWidth=function(){return this._width},n.setWidth=function(t){return this._width=t,this._refresh(),this},n.getHeight=function(){return this._height},n.setHeight=function(t){return this._height=t,this._refresh(),this},n.getBoxSymbol=function(){return d({},this.options.boxSymbol)},n.setBoxSymbol=function(t){return this.options.boxSymbol=t?d({},t):t,this.getSymbol()&&this._refresh(),this},n.getTextStyle=function(){return this.options.textStyle?d({},this.options.textStyle):null},n.setTextStyle=function(t){return this.options.textStyle=t?d({},t):t,this.getSymbol()&&this._refresh(),this},e.fromJSON=function(t){var n=t.feature,r=new e(t.content,n.geometry.coordinates,t.width,t.height,t.options);return r.setProperties(n.properties),r.setId(n.id),t.symbol&&r.setSymbol(t.symbol),r},n._toJSON=function(t){return{feature:this.toGeoJSON(t),width:this.getWidth(),height:this.getHeight(),subType:"TextBox",content:this._content}},n._refresh=function(){var t=this.getTextStyle()||{},e=t.padding||[12,8],n=this._width-2*e[0],r=this._height-2*e[1],i=d({},t.symbol||this._getDefaultTextSymbol(),this.options.boxSymbol||this._getDefaultBoxSymbol(),{textName:this._content,markerWidth:this._width,markerHeight:this._height,textHorizontalAlignment:"middle",textVerticalAlignment:"middle",textMaxWidth:n,textMaxHeight:r});t.wrap&&!i.textWrapWidth&&(i.textWrapWidth=n);var o=t.horizontalAlignment;i.textDx=i.markerDx||0;var a=i.markerWidth/2-e[0];"left"===o?(i.textHorizontalAlignment="right",i.textDx=i.textDx-a):"right"===o&&(i.textHorizontalAlignment="left",i.textDx=i.textDx+a);var s=t.verticalAlignment;i.textDy=i.markerDy||0;var u=i.markerHeight/2-e[1];"top"===s?(i.textVerticalAlignment="bottom",i.textDy-=u):"bottom"===s&&(i.textVerticalAlignment="top",i.textDy+=u),this._refreshing=!0,this.updateSymbol(i),delete this._refreshing},e}(Vi);Zi.mergeOptions({textStyle:{wrap:!0,padding:[12,8],verticalAlignment:"middle",horizontalAlignment:"middle"},boxSymbol:null}),Zi.registerJSONType("TextBox");var qi=function(t){function e(e,n,r){var i;return void 0===r&&(r={}),i=t.call(this,n,r)||this,r.textSymbol&&i.setTextSymbol(r.textSymbol),r.boxStyle&&i.setBoxStyle(r.boxStyle),i._content=_e(e),i._refresh(),i}fe(e,t);var n=e.prototype;return n.getBoxStyle=function(){return this.options.boxStyle?d({},this.options.boxStyle):null},n.setBoxStyle=function(t){return this.options.boxStyle=t?d({},t):t,this._refresh(),this},n.getTextSymbol=function(){return d({},this._getDefaultTextSymbol(),this.options.textSymbol)},n.setTextSymbol=function(t){return this.options.textSymbol=t?d({},t):t,this._refresh(),this},e.fromJSON=function(t){var n=t.feature,r=new e(t.content,n.geometry.coordinates,t.options);return r.setProperties(n.properties),r.setId(n.id),t.symbol&&r.setSymbol(t.symbol),r},n._canEdit=function(){return!1},n._toJSON=function(t){return{feature:this.toGeoJSON(t),subType:"Label",content:this._content}},n._refresh=function(){var t=d({},this.getTextSymbol(),{textName:this._content}),e=this.getBoxStyle();if(e){d(t,e.symbol);var n=this._getBoxSize(t),r=n[1],i=e.padding||this._getDefaultPadding(),o=n[0];t.markerWidth=o.width,t.markerHeight=o.height;var a=t.textDx||0,s=t.textDy||0,u=Ae(r,t.textHorizontalAlignment,t.textVerticalAlignment)._add(a,s),c=e.horizontalAlignment||"middle";t.markerDx=u.x,"left"===c?t.markerDx+=t.markerWidth/2-i[0]:"right"===c?t.markerDx-=t.markerWidth/2-r.width-i[0]:t.markerDx+=r.width/2;var l=e.verticalAlignment||"middle";t.markerDy=u.y,"top"===l?t.markerDy+=t.markerHeight/2-i[1]:"bottom"===l?t.markerDy-=t.markerHeight/2-r.height-i[1]:t.markerDy+=r.height/2}this._refreshing=!0,this.updateSymbol(t),delete this._refreshing},n._getBoxSize=function(t){t.markerType||(t.markerType="square");var e,n,r=this.getBoxStyle(),i=this._getTextSize(t),o=r.padding||this._getDefaultPadding();return e=i.width+2*o[0],n=i.height+2*o[1],r.minWidth&&(!e||e<r.minWidth)&&(e=r.minWidth),r.minHeight&&(!n||n<r.minHeight)&&(n=r.minHeight),[new ge(e,n),i]},e}(Vi);qi.mergeOptions({boxStyle:null,textSymbol:null}),qi.registerJSONType("Label");var Yi=function(t){return function(t){function e(){return t.apply(this,arguments)||this}fe(e,t),e._hasConnectors=function(t){return!p(t.__connectors)&&t.__connectors.length>0},e._getConnectors=function(t){return t.__connectors};var n=e.prototype;return n.getConnectSource=function(){return this._connSource},n.setConnectSource=function(t){var e=this._connTarget;return this.onRemove(),this._connSource=t,this._connTarget=e,this.onAdd(),this},n.getConnectTarget=function(){return this._connTarget},n.setConnectTarget=function(t){var e=this._connSource;return this.onRemove(),this._connSource=e,this._connTarget=t,this._updateCoordinates(),this._registerEvents(),this},n._updateCoordinates=function(){var t=this.getMap();if(!t&&this._connSource&&(t=this._connSource.getMap()),!t&&this._connTarget&&(t=this._connTarget.getMap()),t&&this._connSource&&this._connTarget){for(var e,n,r=this._connSource._getConnectPoints(),i=this._connTarget._getConnectPoints(),o=0,a=this.getCoordinates(),s=0,u=r.length;s<u;s++)for(var c=r[s],l=0,h=i.length;l<h;l++){var f=i[l],d=t.computeLength(c,f);0===s&&0===l?(e=c,n=f,o=d):d<o&&(e=c,n=f)}U(a)&&a[0].equals(e)&&a[1].equals(n)||this.setCoordinates([e,n])}},n.onAdd=function(){this._registerEvents(),this._updateCoordinates()},n.onRemove=function(){if(this._connSource&&(this._connSource.__connectors&&D(this,this._connSource.__connectors),this._connSource.off("dragging positionchange",this._updateCoordinates,this).off("remove",this.onRemove,this),this._connSource.off("dragstart mousedown mouseover",this._showConnect,this),this._connSource.off("dragend mouseup mouseout",this.hide,this),this._connSource.off("show",this._showConnect,this).off("hide",this.hide,this),delete this._connSource),this._connTarget&&(D(this,this._connTarget.__connectors),this._connTarget.off("dragging positionchange",this._updateCoordinates,this).off("remove",this.onRemove,this),this._connTarget.off("show",this._showConnect,this).off("hide",this.hide,this),delete this._connTarget),!(this._connSource instanceof Kr&&this._connTarget instanceof Kr)){var t=this.getMap();t&&t.off("movestart moving moveend zoomstart zooming zoomend rotate pitch fovchange spatialreferencechange",this._updateCoordinates,this)}},n._showConnect=function(){this._connSource&&this._connTarget&&this._connSource.isVisible()&&this._connTarget.isVisible()&&(this._updateCoordinates(),this.show())},n._registerEvents=function(){if(this._connSource&&this._connTarget){this._connSource.__connectors||(this._connSource.__connectors=[]),this._connTarget.__connectors||(this._connTarget.__connectors=[]),this._connSource.__connectors.push(this),this._connTarget.__connectors.push(this),this._connSource.on("dragging positionchange",this._updateCoordinates,this).on("remove",this.remove,this),this._connTarget.on("dragging positionchange",this._updateCoordinates,this).on("remove",this.remove,this),this._connSource.on("show",this._showConnect,this).on("hide",this.hide,this),this._connTarget.on("show",this._showConnect,this).on("hide",this.hide,this);var t=this.options.showOn;if(this.hide(),"moving"===t?(this._connSource.on("dragstart",this._showConnect,this).on("dragend",this.hide,this),this._connTarget.on("dragstart",this._showConnect,this).on("dragend",this.hide,this)):"click"===t?(this._connSource.on("mousedown",this._showConnect,this).on("mouseup",this.hide,this),this._connTarget.on("mousedown",this._showConnect,this).on("mouseup",this.hide,this)):"mouseover"===t?(this._connSource.on("mouseover",this._showConnect,this).on("mouseout",this.hide,this),this._connTarget.on("mouseover",this._showConnect,this).on("mouseout",this.hide,this)):this._showConnect(),!(this._connSource instanceof Kr&&this._connTarget instanceof Kr)){var e=this.getMap();e&&e.on("movestart moving moveend zoomstart zooming zoomend rotate pitch fovchange spatialreferencechange",this._updateCoordinates,this)}}},e}(t)},Ji={showOn:"always"},Xi=function(t){function e(e,n,r){var i;return i=t.call(this,null,r)||this,1===arguments.length&&(r=e,e=null,n=null),i._connSource=e,i._connTarget=n,i}return fe(e,t),e}(Yi(Ti));Xi.mergeOptions(Ji),Xi.registerJSONType("ConnectorLine");var $i=function(t){function e(e,n,r){var i;return i=t.call(this,null,r)||this,1===arguments.length&&(r=e,e=null,n=null),i._connSource=e,i._connTarget=n,i}return fe(e,t),e}(Yi(Bi));$i.mergeOptions(Ji),$i.registerJSONType("ArcConnectorLine");var Qi=function(t){function e(e,n,r){var i;n&&!(n instanceof Kr)&&!Array.isArray(n)&&a.indexOf(n.type)<0&&(r=n,n=null),(i=t.call(this,e,r)||this)._maxZIndex=0,i._minZIndex=0,i._initCache(),n&&i.addGeometry(n);var o=i.options.style;return o&&i.setStyle(o),i}fe(e,t);var n=e.prototype;return n.getGeometryById=function(t){return p(t)||""===t?null:this._geoMap[t]?this._geoMap[t]:null},n.getGeometries=function(t,e){if(!t)return this._geoList.slice(0);for(var n,r=[],i=0,o=this._geoList.length;i<o;i++)n=this._geoList[i],(e?t.call(e,n):t(n))&&r.push(n);return r},n.getFirstGeometry=function(){return this._geoList.length?this._geoList[0]:null},n.getLastGeometry=function(){var t=this._geoList.length;return 0===t?null:this._geoList[t-1]},n.getCount=function(){return this._geoList.length},n.getExtent=function(){if(0===this.getCount())return null;var t=new Vn(this.getProjection());return this.forEach((function(e){t._combine(e.getExtent())})),t},n.forEach=function(t,e){for(var n=this._geoList.slice(0),r=0,i=n.length;r<i;r++)e?t.call(e,n[r],r):t(n[r],r);return this},n.filter=function(t,e){var n=[],r=_(t),i=r?t:rt(t);return this.forEach((function(t){var o=r?t:ft(t);(e?i.call(e,o):i(o))&&n.push(t)}),this),n},n.isEmpty=function(){return!this._geoList.length},n.addGeometry=function(t,e){if(!t)return this;if("FeatureCollection"===t.type)return this.addGeometry(Ii.toGeometry(t),e);if(!Array.isArray(t)){var n=arguments.length,r=arguments[n-1];return t=Array.prototype.slice.call(arguments,0,n-1),e=r,r&&v(r)&&("type"in r||r instanceof Kr)&&(t.push(r),e=!1),this.addGeometry(t,e)}if(0===t.length)return this;var i;this._initCache(),e&&(i=new Vn),this._toSort=this._maxZIndex>0;for(var o=[],a=0,s=t.length;a<s;a++){var u=t[a];if(!u)throw new Error("Invalid geometry to add to layer("+this.getId()+") at index:"+a);if(!(u instanceof Kr)&&(u=Kr.fromJSON(u),Array.isArray(u)))for(var c=0,l=u.length;c<l;c++)this._add(u[c],i,a),o.push(u[c]);Array.isArray(u)||(this._add(u,i,a),o.push(u))}var h=this.getMap();if(h&&(this._getRenderer().onGeometryAdd(o),i&&!p(i.xmin))){var f=i.getCenter(),m=h.getFitZoom(i);if(v(e)){var g=_(e.step)?e.step:function(){};h.animateTo({center:f,zoom:m},d({duration:h.options.zoomAnimationDuration,easing:"out"},e),g)}else!0===e&&h.setCenterAndZoom(f,m)}return this.fire("addgeo",{geometries:t}),this},n.getGeoMinZIndex=function(){return this._minZIndex},n.getGeoMaxZIndex=function(){return this._maxZIndex},n._add=function(t,e,n){this._toSort||(this._toSort=0!==t.getZIndex()),this._updateZIndex(t.getZIndex());var r=t.getId();if(!p(r)){if(!p(this._geoMap[r]))throw new Error("Duplicate geometry id in layer("+this.getId()+"):"+r+", at index:"+n);this._geoMap[r]=t}var i=O();t._setInternalId(i),this._geoList.push(t),this.onAddGeometry(t),t._bindLayer(this),t.onAdd&&t.onAdd(),e&&e._combine(t.getExtent()),t._fireEvent("add",{layer:this}),this._cookedStyles&&this._styleGeometry(t)},n.removeGeometry=function(t){if(!Array.isArray(t))return this.removeGeometry([t]);for(var e=t.length-1;e>=0;e--)t[e]instanceof Kr||(t[e]=this.getGeometryById(t[e])),t[e]&&this===t[e].getLayer()&&t[e].remove();return this.fire("removegeo",{geometries:t}),this},n.clear=function(){this._clearing=!0,this.forEach((function(t){t.remove()})),this._geoMap={};var t=this._geoList;return this._geoList=[],this._getRenderer()&&this._getRenderer().onGeometryRemove(t),this._clearing=!1,this.fire("clear"),this},n.onRemoveGeometry=function(t){if(t&&!this._clearing&&this===t.getLayer()&&!p(t._getInternalId())){var e=t.getId();p(e)||delete this._geoMap[e];var n=this._findInList(t);n>=0&&this._geoList.splice(n,1),this._getRenderer()&&this._getRenderer().onGeometryRemove([t])}},n.getStyle=function(){return this.options.style?this.options.style:null},n.setStyle=function(t){return this.options.style=t,t=jt(t),this._cookedStyles=dt(t),this.forEach((function(t){this._styleGeometry(t)}),this),this.fire("setstyle",{style:t}),this},n._styleGeometry=function(t){if(!this._cookedStyles)return!1;for(var e=ft(t),n=0,r=this._cookedStyles.length;n<r;n++)if(!0===this._cookedStyles[n].filter(e))return t._setExternSymbol(this._cookedStyles[n].symbol),!0;return!1},n.removeStyle=function(){return this.options.style?(delete this.options.style,delete this._cookedStyles,this.forEach((function(t){t._setExternSymbol(null)}),this),this.fire("removestyle"),this):this},n.onAddGeometry=function(t){this.getStyle()&&this._styleGeometry(t)},n.hide=function(){for(var t=0,e=this._geoList.length;t<e;t++)this._geoList[t].onHide();return ei.prototype.hide.call(this)},n._initCache=function(){this._geoList||(this._geoList=[],this._geoMap={})},n._updateZIndex=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];this._maxZIndex=Math.max(this._maxZIndex,Math.max.apply(Math,e)),this._minZIndex=Math.min(this._minZIndex,Math.min.apply(Math,e))},n._sortGeometries=function(){var t=this;this._toSort&&(this._maxZIndex=0,this._minZIndex=0,this._geoList.sort((function(e,n){return t._updateZIndex(e.getZIndex(),n.getZIndex()),t._compare(e,n)})),this._toSort=!1)},n._compare=function(t,e){return t.getZIndex()===e.getZIndex()?t._getInternalId()-e._getInternalId():t.getZIndex()-e.getZIndex()},n._findInList=function(t){var e=this._geoList.length;if(0===e)return-1;this._sortGeometries();for(var n,r=0,i=e-1;r<=i;){if(n=Math.floor((r+i)/2),this._geoList[n]===t)return n;this._compare(this._geoList[n],t)>0?i=n-1:r=n+1}return-1},n._onGeometryEvent=function(t){if(t&&t.target){var e=t.type;"idchange"===e?this._onGeometryIdChange(t):"zindexchange"===e?this._onGeometryZIndexChange(t):"positionchange"===e?this._onGeometryPositionChange(t):"shapechange"===e?this._onGeometryShapeChange(t):"symbolchange"===e?this._onGeometrySymbolChange(t):"show"===e?this._onGeometryShow(t):"hide"===e?this._onGeometryHide(t):"propertieschange"===e&&this._onGeometryPropertiesChange(t)}},n._onGeometryIdChange=function(t){if(t.new!==t.old||!this._geoMap[t.old]||this._geoMap[t.old]!==t.target){if(!p(t.new)){if(this._geoMap[t.new])throw new Error("Duplicate geometry id in layer("+this.getId()+"):"+t.new);this._geoMap[t.new]=t.target}p(t.old)||t.new===t.old||delete this._geoMap[t.old]}},n._onGeometryZIndexChange=function(t){t.old!==t.new&&(this._updateZIndex(t.new),this._toSort=!0,this._getRenderer()&&this._getRenderer().onGeometryZIndexChange(t))},n._onGeometryPositionChange=function(t){this._getRenderer()&&this._getRenderer().onGeometryPositionChange(t)},n._onGeometryShapeChange=function(t){this._getRenderer()&&this._getRenderer().onGeometryShapeChange(t)},n._onGeometrySymbolChange=function(t){this._getRenderer()&&this._getRenderer().onGeometrySymbolChange(t)},n._onGeometryShow=function(t){this._getRenderer()&&this._getRenderer().onGeometryShow(t)},n._onGeometryHide=function(t){this._getRenderer()&&this._getRenderer().onGeometryHide(t)},n._onGeometryPropertiesChange=function(t){this._getRenderer()&&this._getRenderer().onGeometryPropertiesChange(t)},e}(ei);Qi.mergeOptions({drawImmediate:!1});var Ki=new Zn,to={debug:!1,enableSimplify:!0,geometryEvents:!0,defaultIconSize:[20,20],cacheVectorOnCanvas:!0,cacheSvgOnCanvas:he.gecko,enableAltitude:!1,altitudeProperty:"altitude",drawAltitude:!1,altitude:0},eo=function(t){function e(e,n,r){return t.call(this,e,n,r)||this}fe(e,t);var n=e.prototype;return n.onConfig=function(e){if(t.prototype.onConfig.call(this,e),e.enableAltitude||e.drawAltitude||e.altitudeProperty){var n=this.getRenderer();n&&n.setToRedraw&&n.setToRedraw()}},n.identify=function(t,e){void 0===e&&(e={});var n=this.getRenderer();return e.onlyVisible&&n&&n.identify?n.identify(t,e):(t instanceof On||(t=new On(t)),this._hitGeos(this._geoList,t,e))},n._hitGeos=function(t,e,n){void 0===n&&(n={});for(var r=n.filter,i=n.tolerance,o=[],a=this.getMap(),s=a.coordToPoint(e),u=a._pointToContainerPoint(s,void 0,0,s),c=t.length-1;c>=0;c--){var l=t[c];if(l&&l.isVisible()&&l._getPainter()&&l.options.interactive){if(!(l instanceof Ti&&(l._getArrowStyle()||l instanceof Fi))){var h=l.getContainerExtent(Ki);if(i&&(h=h._expand(i)),!h||!h.contains(u))continue}if(l._containsPoint(u,i)&&(!r||r(l))&&(o.push(l),n.count&&o.length>=n.count))break}}return o},n.getAltitude=function(){return this.options.altitude||0},n.toJSON=function(t){t||(t={});var e={type:this.getJSONType(),id:this.getId(),options:this.config()};if(p(t.geometries)||t.geometries){var n;if(t.clipExtent){var r=this.getMap(),i=r?r.getProjection():null;n=new Vn(t.clipExtent,i)}for(var o=[],a=this.getGeometries(),s=0,u=a.length;s<u;s++){var c=a[s],l=c.getExtent();if(l&&(!n||n.intersects(l))){var h=c.toJSON(t.geometries);o.push(h)}}e.geometries=o}return e},e.fromJSON=function(t){if(!t||"VectorLayer"!==t.type)return null;for(var n=new e(t.id,t.options),r=t.geometries,i=[],o=0;o<r.length;o++){var a=Kr.fromJSON(r[o]);a&&i.push(a)}return n.addGeometry(i),n},e.getPainterClass=function(){return Yr},e.getCollectionPainterClass=function(){return Xr},e}(Qi);eo.mergeOptions(to),eo.registerJSONType("VectorLayer");var no="_map_tool",ro=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.addTo=function(t){return t?(this._map=t,t[no]&&t[no].disable(),this.onAdd&&this.onAdd(),this.enable(),t[no]=this,this._fireEvent("add"),this):this},n.getMap=function(){return this._map},n.enable=function(){return!this._map||this._enabled||(this._enabled=!0,this._switchEvents("off"),this._registerEvents(),this.onEnable&&this.onEnable(),this._fireEvent("enable")),this},n.disable=function(){return this._enabled&&this._map?(this._enabled=!1,this._switchEvents("off"),this.onDisable&&this.onDisable(),this._fireEvent("disable"),this):this},n.isEnabled=function(){return!!this._enabled},n.remove=function(){return this._map?(this.disable(),this._map&&(delete this._map[no],delete this._map),this._fireEvent("remove"),this):this},n._registerEvents=function(){this._switchEvents("on")},n._switchEvents=function(t){var e=this.getEvents();e&&this._map[t](e,this)},n._fireEvent=function(t,e){e||(e={}),this.fire(t,e)},e}(xn(Mn)),io={},oo=function(t){function e(e){var n;return(n=t.call(this,e)||this)._checkMode(),n._events={click:n._clickHandler,mousemove:n._mouseMoveHandler,dblclick:n._doubleClickHandler,mousedown:n._mouseDownHandler,mouseup:n._mouseUpHandler},n}fe(e,t),e.registerMode=function(t,e){io[t.toLowerCase()]=e},e.getRegisterMode=function(t){return io[t.toLowerCase()]};var n=e.prototype;return n.getMode=function(){return this.options.mode?this.options.mode.toLowerCase():null},n.setMode=function(t){return this._geometry&&(this._geometry.remove(),delete this._geometry),this._clearStage(),this._switchEvents("off"),this.options.mode=t,this._checkMode(),this.isEnabled()&&(this._switchEvents("on"),this._restoreMapCfg(),this._saveMapCfg()),this},n.getSymbol=function(){return Dt(this.options.symbol||this.options.symbol)},n.setSymbol=function(t){return t?(this.options.symbol=t,this._geometry&&this._geometry.setSymbol(t),this):this},n.getCurrentGeometry=function(){return this._geometry},n.onAdd=function(){this._checkMode()},n.onEnable=function(){if(this._saveMapCfg(),this._drawToolLayer=this._getDrawLayer(),this._clearStage(),this._loadResources(),this.options.autoPanAtEdge){var t=this.getMap();this._mapAutoPanAtEdge=t.options.autoPanAtEdge,this._mapAutoPanAtEdge||t.config({autoPanAtEdge:!0})}return this},n.onDisable=function(){var t=this.getMap();return this._restoreMapCfg(),this.endDraw(),this._map&&(t.removeLayer(this._getDrawLayer()),this.options.autoPanAtEdge&&(this._mapAutoPanAtEdge||t.config({autoPanAtEdge:!1}))),this},n.undo=function(){var t=this._getRegisterMode(),e=t.action;if(!this._shouldRecordHistory(e)||!this._historyPointer)return this;var n=this._clickCoords.slice(0,--this._historyPointer);return t.update(this.getMap().getProjection(),n,this._geometry),this},n.redo=function(){var t=this._getRegisterMode(),e=t.action;if(!this._shouldRecordHistory(e)||p(this._historyPointer)||this._historyPointer===this._clickCoords.length)return this;var n=this._clickCoords.slice(0,++this._historyPointer);return t.update(this.getMap().getProjection(),n,this._geometry),this},n._shouldRecordHistory=function(t){return Array.isArray(t)&&"click"===t[0]&&"mousemove"===t[1]&&"dblclick"===t[2]},n._checkMode=function(){this._getRegisterMode()},n._saveMapCfg=function(){var t=this.getMap();if(this._mapDoubleClickZoom=t.options.doubleClickZoom,t.config({doubleClickZoom:this.options.doubleClickZoom}),this._getRegisterMode().action.indexOf("mousedown")>-1){var e=this.getMap();this._mapDraggable=e.options.draggable,e.config({draggable:!1})}},n._restoreMapCfg=function(){var t=this.getMap();t.config({doubleClickZoom:this._mapDoubleClickZoom}),p(this._mapDraggable)||t.config("draggable",this._mapDraggable),delete this._mapDraggable,delete this._mapDoubleClickZoom},n._loadResources=function(){var t=Pt(this.getSymbol());t.length>0&&this._drawToolLayer._getRenderer().loadResources(t)},n._getProjection=function(){return this._map.getProjection()},n._getRegisterMode=function(){var t=this.getMode(),n=e.getRegisterMode(t);if(!n)throw new Error(t+" is not a valid mode of DrawTool.");return n},n.getEvents=function(){var t=this._getRegisterMode().action,e={};if(Array.isArray(t)){for(var n=0;n<t.length;n++)e[t[n]]=this._events[t[n]];return e}return null},n._mouseDownHandler=function(t){this._createGeometry(t)},n._mouseUpHandler=function(t){this.endDraw(t)},n._clickHandler=function(t){var e=this._getRegisterMode();if(this._geometry){var n=this.getMap()._pointToPrj(t.point2d);p(this._historyPointer)||(this._clickCoords=this._clickCoords.slice(0,this._historyPointer)),this._clickCoords.push(n),this._historyPointer=this._clickCoords.length,t.drawTool=this,e.update(this.getMap().getProjection(),this._clickCoords,this._geometry,t),this._fireEvent("drawvertex",t),e.clickLimit&&e.clickLimit===this._historyPointer&&this.endDraw(t)}else this._createGeometry(t)},n._createGeometry=function(t){var e=this.getMode(),n=this._getRegisterMode(),r=this.getMap()._pointToPrj(t.point2d),i=this.getSymbol();this._geometry||(this._clickCoords=[r],t.drawTool=this,this._geometry=n.create(this.getMap().getProjection(),this._clickCoords,t),i&&"point"!==e?this._geometry.setSymbol(i):this.options.hasOwnProperty("symbol")&&this._geometry.setSymbol(this.options.symbol),this._addGeometryToStage(this._geometry),this._fireEvent("drawstart",t)),"point"===e&&this.endDraw(t)},n._mouseMoveHandler=function(t){var e=this.getMap();if(this._geometry&&e&&!e.isInteracting()){var n=this._getMouseContainerPoint(t);if(this._isValidContainerPoint(n)){var r=this.getMap()._pointToPrj(t.point2d),i=e.getProjection();t.drawTool=this;var o=this._getRegisterMode();if(this._shouldRecordHistory(o.action)){var a=this._clickCoords.slice(0,this._historyPointer);if(a&&a.length>0&&r.equals(a[a.length-1]))return;o.update(i,a.concat([r]),this._geometry,t)}else o.update(i,r,this._geometry,t);this._fireEvent("mousemove",t)}}},n._doubleClickHandler=function(t){if(this._geometry){var e=this._getMouseContainerPoint(t);if(this._isValidContainerPoint(e)){var n=this._getRegisterMode(),r=this._clickCoords;if(!(r.length<2)){for(var i=this.getMap().getProjection(),o=[r[0]],a=1,s=r.length;a<s;a++)r[a].x===r[a-1].x&&r[a].y===r[a-1].y||o.push(r[a]);o.length<2||this._geometry&&this._geometry instanceof bi&&o.length<3||(t.drawTool=this,n.update(i,o,this._geometry,t),this.endDraw(t))}}}},n._addGeometryToStage=function(t){this._getDrawLayer().addGeometry(t)},n.endDraw=function(t){if(!this._geometry||this._ending)return this;this._ending=!0;var e=this._geometry;return this._clearStage(),t=t||{},this._geometry=e,this._fireEvent("drawend",t),delete this._geometry,this.options.once&&this.disable(),delete this._ending,delete this._historyPointer,this},n._clearStage=function(){this._getDrawLayer().clear(),delete this._geometry,delete this._clickCoords},n._getMouseContainerPoint=function(t){return"mousedown"===this._getRegisterMode().action&&Ue(t.domEvent),t.containerPoint},n._isValidContainerPoint=function(t){var e=this._map.getSize(),n=e.width,r=e.height;return!(t.x<0||t.y<0||t.x>n||t.y>r)},n._getDrawLayer=function(){var t=i+"drawtool",e=this._map.getLayer(t);return e||(e=new eo(t,{enableSimplify:!1}),this._map.addLayer(e)),e},n._fireEvent=function(t,e){e||(e={}),this._geometry&&(e.geometry=this._getRegisterMode().generate(this._geometry,{drawTool:this})),ro.prototype._fireEvent.call(this,t,e)},e}(ro);oo.mergeOptions({symbol:{lineColor:"#000",lineWidth:2,lineOpacity:1,polygonFill:"#fff",polygonOpacity:.3},doubleClickZoom:!1,mode:null,once:!1,autoPanAtEdge:!1,ignoreMouseleave:!0});var ao=function(t){function e(e){var n;return(n=t.call(this,e)||this).drawTool=new oo({mode:"boxZoom",ignoreMouseleave:!1}),n}fe(e,t);var n=e.prototype;return n.addHooks=function(){this.target.on("_mousedown",this._onMouseDown,this)},n.removeHooks=function(){this.target.off("_mousedown",this._onMouseDown,this),this.drawTool.isEnabled()&&this.drawTool.remove()},n._onMouseDown=function(t){this.target.options.boxZoom&&t.domEvent.shiftKey&&this.drawTool.setSymbol(this.target.options.boxZoomSymbol).on("drawend",this._boxZoom,this).addTo(this.target)},n._boxZoom=function(t){var e=this.target;this.drawTool.remove();var n=t.geometry,r=n.getCenter(),i=n.getSymbol(),o=i.markerWidth,a=i.markerHeight,s=new Vn(r,e.locateByPoint(r,o,a),e.getProjection()),u=e.getFitZoom(s);e._animateTo({center:s.getCenter(),zoom:u})},e}(wn);ii.mergeOptions({boxZoom:!0,boxZoomSymbol:{markerType:"rectangle",markerLineWidth:3,markerLineColor:"#1bbc9b",markerLineDasharray:[10,5],markerFillOpacity:.1,markerFill:"#1bbc9b",markerWidth:1,markerHeight:1}}),ii.addOnLoadHook("addHandler","boxZoom",ao);var so=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.addHooks=function(){this.target&&this.target.on("_mousemove",this._onMouseMove,this)},n.removeHooks=function(){this.target&&this.target.off("_mousemove",this._onMouseMove,this)},n._onMouseMove=function(t){var e=this.target;if(e.options.autoPanAtEdge){var n=t.containerPoint,r=e.getContainerExtent();if(r){var i,o=n.x,a=n.y,s=r.xmax,u=r.ymax;o<30&&(i=[Math.abs(o-30),0]),a<30&&(i=[0,Math.abs(a-30)]),o+30>s&&(i=[-Math.abs(o+30-s),0]),a+30>u&&(i=[0,-Math.abs(a+30-u)]),i&&e.panBy(i,{duration:1})}}},e}(wn);ii.mergeOptions({autoPanAtEdge:!1}),ii.addOnLoadHook("addHandler","autoPanAtEdge",so),ii.include({animateTo:function(t,e,n){var r=this;void 0===e&&(e={}),_(e)&&(n=e,e={});var i=this.getProjection(),o=this.getView(),a={},s=!0;for(var u in t)if(b(t,u)&&!p(t[u])&&("prjCenter"===u||!p(o[u])))if(s=!1,"center"===u){var c=new On(o[u]).toFixed(7),l=new On(t[u]).toFixed(7);c.equals(l)||(a.center=[c,l])}else if("prjCenter"===u){var h=new On(this._getPrjCenter()),f=new On(t[u]);h.equals(f)||(a.prjCenter=[h,f])}else o[u]!==t[u]&&"around"!==u&&(a[u]=[o[u],t[u]]);if(s)return null;this._animPlayer&&(this._isInternalAnimation?"running"===this._animPlayer.playState&&(this._animPlayer.pause(),this._prevAnimPlayer=this._animPlayer):(delete this._prevAnimPlayer,this._stopAnim(this._animPlayer)));var d=t.around||new me(this.width/2,this.height/2),m=this._getRenderer(),g=this._animPlayer=gi.animate(a,{easing:e.easing||"out",duration:e.duration||this.options.zoomAnimationDuration,framer:function(t){m.callInNextFrame(t)}},(function(t){if(r.isRemoved())g.finish();else{if("running"===g.playState){if(t.styles.center){var o=t.styles.center;r._setPrjCenter(i.project(o)),r.onMoving(r._parseEventFromCoord(r.getCenter()))}else if(t.styles.prjCenter){var s=t.styles.prjCenter;r._setPrjCenter(s),r.onMoving(r._parseEventFromCoord(r.getCenter()))}p(t.styles.zoom)||r.onZooming(t.styles.zoom,d),p(t.styles.pitch)||r.setPitch(t.styles.pitch),p(t.styles.bearing)||r.setBearing(t.styles.bearing),r._fireEvent("animating")}else"paused"===g.playState&&g!==r._mapAnimPlayer||(g._interupted||(a.center?r._setPrjCenter(i.project(a.center[1])):a.prjCenter&&r._setPrjCenter(a.prjCenter[1]),p(a.pitch)||r.setPitch(a.pitch[1]),p(a.bearing)||r.setBearing(a.bearing[1])),r._endAnim(g,a,d,e));n&&n(t)}}),this);return this._startAnim(a,d),g},_animateTo:function(t,e,n){return void 0===e&&(e={}),this._mapAnimPlayer&&this._stopAnim(this._mapAnimPlayer),this._isInternalAnimation=!0,this._mapAnimPlayer=this.animateTo(t,e,n),delete this._isInternalAnimation,this._mapAnimPlayer},isAnimating:function(){return!!this._animPlayer},isRotating:function(){return this.isDragRotating()||!!this._animRotating},_endAnim:function(t,e,n,r){delete this._animRotating;var i,o=t._interupted?"animateinterrupted":"animateend";if(t===this._animPlayer&&delete this._animPlayer,t===this._mapAnimPlayer&&delete this._mapAnimPlayer,e.center)i=t._interupted?this.getCenter():e.center[1],this.onMoveEnd(this._parseEventFromCoord(i));else if(e.prjCenter){var a;a=t._interupted?this._getPrjCenter():e.prjCenter[1];var s=this._parseEventFromCoord(this.getProjection().unproject(a));s.point2d=this._prjToPoint(a),this.onMoveEnd(s)}p(e.zoom)||(t._interupted?this.onZoomEnd(this.getZoom(),n):r.wheelZoom?this.onZooming(e.zoom[1],n):this.onZoomEnd(e.zoom[1],n)),o&&this._fireEvent(o),p(e.pitch)||this.getPitch()||this.getRenderer().setToRedraw(),this._resumePrev(t)},_startAnim:function(t,e){this._animPlayer&&(t.center&&this.onMoveStart(),t.zoom&&!this.isZooming()&&this.onZoomStart(t.zoom[1],e),(t.pitch||t.bearing)&&(this._animRotating=!0),this._fireEvent("animatestart"),this._animPlayer.play())},_stopAnim:function(t){t&&(delete this._animRotating,"finished"!==t.playState&&(t._interupted=!0,t.cancel()),t===this._animPlayer&&delete this._animPlayer,t===this._mapAnimPlayer&&delete this._mapAnimPlayer)},_resumePrev:function(t){if(this._prevAnimPlayer){var e=this._prevAnimPlayer;"paused"!==e.playState&&delete this._prevAnimPlayer,t!==e&&(this._animPlayer=e,e.play())}}});var uo="mousedown mouseup mouseover mouseout mouseenter mouseleave mousemove click dblclick contextmenu keypress touchstart touchmove touchend ";function co(t,e,n,r,i){var o=1/Math.tan(e/2),a=1/(r-i);return t[0]=o/n,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=o,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=(i+r)*a,t[11]=-1,t[12]=0,t[13]=0,t[14]=2*i*r*a,t[15]=0,t}function lo(t,e,n){var r,i,o,a,s,u,c,l,h,f,d,p,m=n[0],g=n[1],v=n[2];return e===t?(t[12]=e[0]*m+e[4]*g+e[8]*v+e[12],t[13]=e[1]*m+e[5]*g+e[9]*v+e[13],t[14]=e[2]*m+e[6]*g+e[10]*v+e[14],t[15]=e[3]*m+e[7]*g+e[11]*v+e[15]):(r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],c=e[6],l=e[7],h=e[8],f=e[9],d=e[10],p=e[11],t[0]=r,t[1]=i,t[2]=o,t[3]=a,t[4]=s,t[5]=u,t[6]=c,t[7]=l,t[8]=h,t[9]=f,t[10]=d,t[11]=p,t[12]=r*m+s*g+h*v+e[12],t[13]=i*m+u*g+f*v+e[13],t[14]=o*m+c*g+d*v+e[14],t[15]=a*m+l*g+p*v+e[15]),t}function ho(t,e,n){var r=n[0],i=n[1],o=n[2];return t[0]=e[0]*r,t[1]=e[1]*r,t[2]=e[2]*r,t[3]=e[3]*r,t[4]=e[4]*i,t[5]=e[5]*i,t[6]=e[6]*i,t[7]=e[7]*i,t[8]=e[8]*o,t[9]=e[9]*o,t[10]=e[10]*o,t[11]=e[11]*o,t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}function fo(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],c=e[6],l=e[7],h=e[8],f=e[9],d=e[10],p=e[11],m=e[12],g=e[13],v=e[14],y=e[15],_=n[0],x=n[1],b=n[2],w=n[3];return t[0]=_*r+x*s+b*h+w*m,t[1]=_*i+x*u+b*f+w*g,t[2]=_*o+x*c+b*d+w*v,t[3]=_*a+x*l+b*p+w*y,_=n[4],x=n[5],b=n[6],w=n[7],t[4]=_*r+x*s+b*h+w*m,t[5]=_*i+x*u+b*f+w*g,t[6]=_*o+x*c+b*d+w*v,t[7]=_*a+x*l+b*p+w*y,_=n[8],x=n[9],b=n[10],w=n[11],t[8]=_*r+x*s+b*h+w*m,t[9]=_*i+x*u+b*f+w*g,t[10]=_*o+x*c+b*d+w*v,t[11]=_*a+x*l+b*p+w*y,_=n[12],x=n[13],b=n[14],w=n[15],t[12]=_*r+x*s+b*h+w*m,t[13]=_*i+x*u+b*f+w*g,t[14]=_*o+x*c+b*d+w*v,t[15]=_*a+x*l+b*p+w*y,t}function po(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],c=e[7],l=e[8],h=e[9],f=e[10],d=e[11],p=e[12],m=e[13],g=e[14],v=e[15],y=n*s-r*a,_=n*u-i*a,x=n*c-o*a,b=r*u-i*s,w=r*c-o*s,M=i*c-o*u,S=l*m-h*p,T=l*g-f*p,E=l*v-d*p,A=h*g-f*m,C=h*v-d*m,P=f*v-d*g,L=y*P-_*C+x*A+b*E-w*T+M*S;return L?(L=1/L,t[0]=(s*P-u*C+c*A)*L,t[1]=(i*C-r*P-o*A)*L,t[2]=(m*M-g*w+v*b)*L,t[3]=(f*w-h*M-d*b)*L,t[4]=(u*E-a*P-c*T)*L,t[5]=(n*P-i*E+o*T)*L,t[6]=(g*x-p*M-v*_)*L,t[7]=(l*M-f*x+d*_)*L,t[8]=(a*C-s*E+c*S)*L,t[9]=(r*E-n*C-o*S)*L,t[10]=(p*w-m*x+v*y)*L,t[11]=(h*x-l*w-d*y)*L,t[12]=(s*T-a*A-u*S)*L,t[13]=(n*A-r*T+i*S)*L,t[14]=(m*_-p*b-g*y)*L,t[15]=(l*b-h*_+f*y)*L,t):null}function mo(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function go(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}function vo(t,e,n,r){return t[0]=e,t[1]=n,t[2]=r,t}function yo(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t}function _o(t){var e=t[0],n=t[1],r=t[2];return Math.sqrt(e*e+n*n+r*r)}function xo(t,e){var n=e[0],r=e[1],i=e[2],o=n*n+r*r+i*i;return o>0&&(o=1/Math.sqrt(o),t[0]=e[0]*o,t[1]=e[1]*o,t[2]=e[2]*o),t}function bo(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[0],s=n[1],u=n[2];return t[0]=i*u-o*s,t[1]=o*a-r*u,t[2]=r*s-i*a,t}function wo(t,e){var n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2];return Math.hypot?Math.hypot(n,r,i):function(){for(var t=0,e=arguments.length;e--;)t+=arguments[e]*arguments[e];return Math.sqrt(t)}(n,r,i)}function Mo(t,e,n){var r=e[0],i=e[1],o=e[2],a=1/(n[3]*r+n[7]*i+n[11]*o+n[15]);return t[0]=(n[0]*r+n[4]*i+n[8]*o+n[12])*a,t[1]=(n[1]*r+n[5]*i+n[9]*o+n[13])*a,t[2]=(n[2]*r+n[6]*i+n[10]*o+n[14])*a,t}ii.include({_registerDomEvents:function(){Fe(this._panels.mapWrapper||this._containerDOM,uo,this._handleDOMEvent,this)},_removeDomEvents:function(){Be(this._panels.mapWrapper||this._containerDOM,uo,this._handleDOMEvent)},_handleDOMEvent:function(t){var e=t.type;if("contextmenu"===e&&Ge(t),!this._ignoreEvent(t)){var n=!1;if("mousedown"===e||"touchstart"===e&&1===t.touches.length)this._mouseDownTime=f();else if("click"===e||"touchend"===e||"contextmenu"===e){if(!this._mouseDownTime)return;var r=this._mouseDownTime;if(delete this._mouseDownTime,f()-r>300){if("click"===e||"contextmenu"===e)return}else"touchend"===e&&(n=!0)}this._fireDOMEvent(this,t,e),n&&(this._clickTime&&f()-this._clickTime<=300?(delete this._clickTime,this._fireDOMEvent(this,t,"dblclick")):(this._clickTime=f(),this._fireDOMEvent(this,t,"click")))}},_ignoreEvent:function(t){if(!t||!this._panels.control)return!1;if(this._isEventOutMap(t))return!0;var e,n=t.srcElement||t.target;if(n)for(;n&&n!==this._containerDOM;){if(n.className&&n.className.indexOf&&(n.className.indexOf("maptalks-control")>=0||n.className.indexOf("maptalks-ui")>=0&&!e.eventsPropagation))return!0;e=n,n=n.parentNode}return!1},_isEventOutMap:function(t){if(this.getPitch()>this.options.maxVisualPitch){var e=qe(this._getActualEvent(t),this._containerDOM);if(!this.getContainerExtent().contains(e))return!0}return!1},_parseEvent:function(t,e){if(!t)return null;var n={domEvent:t};if("keypress"!==e){var r=this._getActualEvent(t);if(r){var i=qe(r,this._containerDOM);n=d(n,{coordinate:this.containerPointToCoord(i),containerPoint:i,viewPoint:this.containerPointToViewPoint(i),point2d:this._containerPointToPoint(i)})}}return n},_parseEventFromCoord:function(t){var e=this.coordToContainerPoint(t);return{coordinate:t,containerPoint:e,viewPoint:this.containerPointToViewPoint(e),point2d:this.coordToPoint(t)}},_getActualEvent:function(t){return t.touches&&t.touches.length>0?t.touches[0]:t.changedTouches&&t.changedTouches.length>0?t.changedTouches[0]:t},_fireDOMEvent:function(t,e,n){if(!this.isRemoved()){var r=this._parseEvent(e,n);this._fireEvent(n,r)}}}),ii.addOnLoadHook("_registerDomEvents"),ii.include({isFullScreen:function(){return!!(document.webkitIsFullScreen||document.mozFullScreen||document.msFullscreenElement||document.fullscreenElement)},requestFullScreen:function(t){return this._fireEvent("fullscreenstart"),this._requestFullScreen(t||this._containerDOM),this._fireEvent("fullscreenend"),this},cancelFullScreen:function(){return this._cancelFullScreen(),this._fireEvent("cancelfullscreen"),this},_requestFullScreen:function(t){if(t.requestFullscreen)t.requestFullscreen();else if(t.mozRequestFullScreen)t.mozRequestFullScreen();else if(t.webkitRequestFullScreen)t.webkitRequestFullScreen();else if(t.msRequestFullScreen)t.msRequestFullScreen();else{var e="fullscreen=1,status=no,resizable=yes,top=0,left=0,scrollbars=no,titlebar=no,menubar=no,location=no,toolbar=no,z-look=yes,width="+(screen.availWidth-8)+",height="+(screen.availHeight-45);null!==window.open(location.href,"_blank",e)&&(window.opener=null,window.close())}},_cancelFullScreen:function(){document.exitFullscreen?document.exitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitCancelFullScreen?document.webkitCancelFullScreen():null!==window.open(location.href,"_blank","fullscreen=no,status=yes,resizable=yes,scrollbars=no,titlebar=no,menubar=yes,location=yes,toolbar=yes,z-look=yes")&&(window.opener=null,window.close())}}),ii.include({panTo:function(t,e,n){if(void 0===e&&(e={}),!t)return this;if(_(e)&&(n=e,e={}),t=new On(t),void 0===e.animation||e.animation){var r=this.getProjection().project(t);return this._panAnimation(r,e.duration,n)}return this.setCenter(t),this},_panTo:function(t,e){return void 0===e&&(e={}),void 0===e.animation||e.animation?this._panAnimation(t,e.duration):(this.onMoveStart(),this._setPrjCenter(t),this.onMoveEnd(this._parseEventFromCoord(this.getCenter())),this)},panBy:function(t,e,n){if(void 0===e&&(e={}),!t)return this;if(_(e)&&(n=e,e={}),t=new me(t),this.getContainerExtent().ymin>0&&t.y>30){var r=t.y;t.y=30,t.x=30*t.x/r,console.warn("offset is limited to panBy when pitch is above maxPitch")}if(this.onMoveStart(),void 0===e.animation||e.animation){t=t.multi(-1);var i=this._containerPointToPrj(new me(this.width/2+t.x,this.height/2+t.y));this._panAnimation(i,e.duration,n)}else this._offsetCenterByPixel(t),this.onMoveEnd(this._parseEventFromCoord(this.getCenter()));return this},_panAnimation:function(t,e,n){return this._animateTo({prjCenter:t},{duration:e||this.options.panAnimationDuration},n)}}),Kr.fromJSON=function(t){if(Array.isArray(t)){for(var e=[],n=0,r=t.length;n<r;n++){var i=Kr.fromJSON(t[n]);Array.isArray(t)?e=e.concat(i):e.push(i)}return e}return t&&!t.feature?Ii.toGeometry(t):(t.subType?(o=Kr.getJSONClass(t.subType).fromJSON(t),p(t.feature.id)||o.setId(t.feature.id)):(o=Ii.toGeometry(t.feature),t.options&&o.config(t.options)),t.symbol&&o.setSymbol(t.symbol),t.infoWindow&&o.setInfoWindow(t.infoWindow),o);var o},ei.fromJSON=function(t){if(!t)return null;var e=t.type,n=ei.getJSONClass(e);if(!n||!n.fromJSON)throw new Error("unsupported layer type:"+e);return n.fromJSON(t)},ii.include({JSON_VERSION:"1.0",toJSON:function(t){t||(t={});var e={jsonVersion:this.JSON_VERSION,version:this.VERSION,extent:this.getExtent().toJSON()};e.options=this.config(),e.options.center=this.getCenter(),e.options.zoom=this.getZoom(),e.options.bearing=this.getBearing(),e.options.pitch=this.getPitch();var n=this.getBaseLayer();(p(t.baseLayer)||t.baseLayer)&&n&&(e.baseLayer=n.toJSON(t.baseLayer));var r={};t.clipExtent&&(!0===t.clipExtent?r.clipExtent=this.getExtent():r.clipExtent=t.clipExtent);var i=[];if(p(t.layers)||t.layers&&!Array.isArray(t.layers)){for(var o=this.getLayers(),a=0,s=o.length;a<s;a++)if(o[a].toJSON){var u=d({},v(t.layers)?t.layers:{},r);i.push(o[a].toJSON(u))}e.layers=i}else if(U(t.layers)){for(var c=t.layers,l=0;l<c.length;l++){var h=c[l],f=this.getLayer(h.id);if(f.toJSON){var m=d({},h.options,r);i.push(f.toJSON(m))}}e.layers=i}else e.layers=[];return e}}),ii.fromJSON=function(t,e,n){if(!t||!e)return null;n||(n={});var r=new ii(t,e.options);if(p(n.baseLayer)||n.baseLayer){var i=ei.fromJSON(e.baseLayer);i&&r.setBaseLayer(i)}if(p(n.layers)||n.layers){for(var o=[],a=e.layers,s=0;s<a.length;s++){var u=ei.fromJSON(a[s]);o.push(u)}r.addLayer(o)}return r},ii.include({computeLength:function(t,e){if(!this.getProjection())return null;var n=new On(t),r=new On(e);return n.equals(r)?0:this.getProjection().measureLength(n,r)},computeGeometryLength:function(t){return t._computeGeodesicLength(this.getProjection())},computeGeometryArea:function(t){return t._computeGeodesicArea(this.getProjection())},identify:function(t,e){if(!t)return this;var n=t.layers;if(!U(n))return this;for(var r=[],o=0,a=n.length;o<a;o++)y(n[o])?r.push(this.getLayer(n[o])):r.push(n[o]);for(var s=new On(t.coordinate),u=d({},t),c=[],l=r.length-1;l>=0&&!(t.count&&c.length>=t.count);l--){var h=r[l];if(h&&h.getMap()&&(t.includeInvisible||h.isVisible())&&(t.includeInternals||!(h.getId().indexOf(i)>=0))){var f=h.identify(s,u);f&&(Array.isArray(f)?I(c,f):c.push(f))}}return e.call(this,c),this}}),ii.include({_zoom:function(t,e){this.options.zoomable&&!this.isZooming()&&(e=this._checkZoomOrigin(e),t=this._checkZoom(t),this.onZoomStart(t,e),this._frameZoom=this.getZoom(),this.onZoomEnd(t,e))},_zoomAnimation:function(t,e,n){this.options.zoomable&&!this.isZooming()&&(t=this._checkZoom(t),this.getZoom()!==t&&(e=this._checkZoomOrigin(e),this._startZoomAnim(t,e,n)))},_checkZoomOrigin:function(t){return t&&!this.options.zoomInCenter||(t=new me(this.width/2,this.height/2)),this.options.zoomOrigin&&(t=new me(this.options.zoomOrigin)),t},_startZoomAnim:function(t,e,n){p(n)&&(n=1);var r=this._getResolution(this._startZoomVal)/this._getResolution(t),i=this.options.zoomAnimationDuration*Math.abs(r-n)/Math.abs(r-1);this._frameZoom=this._startZoomVal,this._animateTo({zoom:t,around:e},{continueOnViewChanged:!0,duration:i})},onZoomStart:function(t,e){this.options.zoomable&&!this.isZooming()&&(this._mapAnimPlayer&&this._stopAnim(this._mapAnimPlayer),this._zooming=!0,this._startZoomVal=this.getZoom(),this._startZoomCoord=this._containerPointToPrj(e),this._fireEvent("zoomstart",{from:this._startZoomVal,to:t}))},onZooming:function(t,e,n){if(this.options.zoomable&&this._frameZoom!==t){p(n)&&(n=1),this._zoomTo(t,e);var r=this.getResolution(t),i=this.getResolution(this._startZoomVal)/r/n,o=this._prjToContainerPoint(this._startZoomCoord,this._startZoomVal),a=this.getViewPoint();if(!this.isRotating()&&!o.equals(e)&&1!==i){var s=this.getPitch(),u=o._sub(e)._multi(1/(1-i));s&&(u.y/=Math.cos(s*Math.PI/180)),e=e.add(u)}var c={view:[i,0,0,i,(e.x-a.x)*(1-i),(e.y-a.y)*(1-i)]},l=this.getDevicePixelRatio();1!==l&&(e=e.multi(l)),c.container=[i,0,0,i,e.x*(1-i),e.y*(1-i)],this._fireEvent("zooming",{from:this._startZoomVal,to:t,origin:e,matrix:c}),this._frameZoom=t}},onZoomEnd:function(t,e){if(this.options.zoomable){var n=this._startZoomVal;this._zoomTo(t,e),this._zooming=!1,this._getRenderer().onZoomEnd(),this._fireEvent("zoomend",{from:n,to:t}),this._verifyExtent(this._getPrjCenter())||this._panTo(this._prjMaxExtent.getCenter())}},_zoomTo:function(t,e){this._zoomLevel=t,this._calcMatrices(),e&&this._setPrjCoordAtContainerPoint(this._startZoomCoord,e)},_checkZoom:function(t){var e=this.getMaxZoom(),n=this.getMinZoom();return t<n&&(t=n),t>e&&(t=e),t}});var So=Math.PI/180,To=new On(0,0);function Eo(){return mo(new Array(16))}ii.include({getFov:function(){return this._fov||(this._fov=.6435011087932844),this._fov/So},setFov:function(t){if(this.isZooming())return this;if(t=Math.max(.01,Math.min(60,t)),this._fov===t)return this;var e=this.getFov();return this._fov=t*So,this._calcMatrices(),this._renderLayers(),this._fireEvent("fovchange",{from:e,to:this.getFov()}),this},getBearing:function(){return this._angle?-this._angle/So:0},setBearing:function(t){if(he.ie9)throw new Error("map can't rotate in IE9.");var e=-H(t,-180,180)*So;if(this._angle===e)return this;var n=this.getBearing();return this._fireEvent("rotatestart",{from:n,to:e}),this._angle=e,this._calcMatrices(),this._renderLayers(),this._fireEvent("rotate",{from:n,to:e}),this._fireEvent("rotateend",{from:n,to:e}),this},getPitch:function(){return this._pitch?this._pitch/Math.PI*180:0},setPitch:function(t){if(he.ie9)throw new Error("map can't tilt in IE9.");var e=G(t,0,this.options.maxPitch)*So;if(this._pitch===e)return this;var n=this.getPitch();return this._fireEvent("pitchstart",{from:n,to:e}),this._pitch=e,this._calcMatrices(),this._renderLayers(),this._fireEvent("pitch",{from:n,to:e}),this._fireEvent("pitchend",{from:n,to:e}),this},isTransforming:function(){return!(!this._pitch&&!this._angle)},getFrustumAltitude:function(){return this._frustumAltitude},_calcFrustumAltitude:function(){var t=90-this.getPitch(),e=this.getFov()/2,n=this.cameraPosition?this.cameraPosition[2]:0;if(e<=t)return n;e=Math.PI*e/180;var r=new me(this.cameraPosition).distanceTo(new me(this.cameraLookAt)),i=n*Math.tan(2*e);return n+Math.tan(e)*(r+i)},_pointToContainerPoint:function(){var t=[0,0,0];return function(e,n,r,i){if(void 0===r&&(r=0),e=this._pointToPoint(e,n,i),this.isTransforming()||r){r*=this._getResolution(n)/this._getResolution();var o=this._glScale;vo(t,e.x*o,e.y*o,r*o);var a=this._projIfBehindCamera(t,this.cameraPosition,this.cameraForward);Mo(a,a,this.projViewMatrix);var s=this.width/2,u=this.height/2;return a[0]=a[0]*s+s,a[1]=-a[1]*u+u,i?(i.x=a[0],i.y=a[1],i):new me(a[0],a[1])}var c=this._prjToPoint(this._getPrjCenter(),void 0,To);return i?(i.x=e.x,i.y=e.y):i=e,i._sub(c.x,c.y),i.set(i.x,-i.y),i._add(this.width/2,this.height/2)}}(),_projIfBehindCamera:function(){var t=new Array(3),e=new Array(3),n=new Array(3);return function(r,i,o){yo(t,r,i);var a=function(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}(o,t);return a<=0&&(function(t,e,n){t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n}(e,o,1.01*a),function(t,e,n){t[0]=e[0]+n[0],t[1]=e[1]+n[1],t[2]=e[2]+n[2]}(r,i,yo(n,t,e))),r}}(),_containerPointToPoint:function(){var t=[0,0,0],e=[0,0,0,1],n=[0,0,0,1];return function(r,i,o){if(this.isTransforming()){var a=this.width/2||1,s=this.height/2||1;vo(t,(r.x-a)/a,(s-r.y)/s,0),vo(e,t[0],t[1],0),vo(n,t[0],t[1],1),e[3]=n[3]=1,Mo(e,e,this.projViewMatrixInverse),Mo(n,n,this.projViewMatrixInverse);var u=e[0],c=n[0],l=e[1],h=n[1],f=e[2],d=n[2],p=f===d?0:(0-f)/(d-f),m=B(u,c,p),g=B(l,h,p);return o?(o.x=m,o.y=g):o=new me(m,g),o._multi(1/this._glScale),void 0===i||this.getZoom()===i?o:this._pointToPointAtZoom(o,i,o)}var v=this._prjToPoint(this._getPrjCenter(),i,o),y=void 0!==i?this._getResolution()/this._getResolution(i):1,_=y*(r.x-this.width/2),x=y*(r.y-this.height/2);return v._add(_,-x)}}(),_calcMatrices:function(){var t=Eo();return function(){delete this._mapRes,delete this._mapGlRes,delete this._mapExtent2D,delete this._mapGlExtent2D;var e=this.getSize(),n=e.width||1,r=e.height||1;this._glScale=this.getGLScale();var i=this.getPitch()*Math.PI/180,o=this._getCameraWorldMatrix(),a=this.getFov()*Math.PI/180,s=this._getCameraFar(a,this.getPitch());this.cameraFar=s,this.cameraNear=Math.max(this._glScale*this.getResolution(this.getGLZoom())*Math.cos(i),.1);var u=this.projMatrix||Eo();co(u,a,n/r,this.cameraNear,s),this.projMatrix=u,this.viewMatrix=po(this.viewMatrix||Eo(),o),this.projViewMatrix=fo(this.projViewMatrix||Eo(),u,this.viewMatrix),this._calcCascadeMatrixes(),this.projViewMatrixInverse=fo(this.projViewMatrixInverse||Eo(),o,po(t,u)),this.domCssMatrix=this._calcDomMatrix(),this._frustumAltitude=this._calcFrustumAltitude(),this._mapRes=this._getResolution(),this._mapGlRes=this._getResolution(this.getGLZoom()),this._mapExtent2D=this._get2DExtent(),this._mapGlExtent2D=this._get2DExtent(this.getGLZoom())}}(),_getCameraFar:function(t,e){var n=this.cameraCenterDistance=wo(this.cameraPosition,this.cameraLookAt),r=n;if(e>0){var i;if(e=e*Math.PI/180,2/Math.PI-e<=t/2)i=4*n;else{var o=Math.tan(t/2);i=n*o/(1/Math.tan(e)-o)}r+=i}return r+1},_calcCascadeMatrixes:function(){var t=Eo();function e(e,n,r){var i=this.width,o=this.height,a=this.getFov()*Math.PI/180,s=this._getCameraFar(a,n),u=this.cameraCenterDistance;s=u+(s-u)/Math.cos((90-n)*Math.PI/180)*Math.cos((90-e)*Math.PI/180),co(t,a,i/o,.1,s);var c=this.viewMatrix;return fo(r,t,c)}return function(){var t=this.getPitch(),n=this.options.cascadePitches[0],r=this.options.cascadePitches[1],i=this.cascadeFrustumMatrix0=this.cascadeFrustumMatrix0||Eo(),o=this.cascadeFrustumMatrix1=this.cascadeFrustumMatrix1||Eo();t>n?e.call(this,t,n,i):go(this.cascadeFrustumMatrix0,this.projViewMatrix),t>r?e.call(this,t,r,o):go(this.cascadeFrustumMatrix1,this.cascadeFrustumMatrix0)}}(),_calcDomMatrix:function(){var t=Eo(),e=Eo(),n=[1,-1,1],r=[0,0,0];return function(){var i=this.width||1,o=this.height||1,a=.5/Math.tan(this._fov/2)*o;return ho(t,this.projMatrix,n),lo(t,t,vo(r,0,0,-a)),this._pitch&&function(t,e,n){var r=Math.sin(n),i=Math.cos(n),o=e[4],a=e[5],s=e[6],u=e[7],c=e[8],l=e[9],h=e[10],f=e[11];e!==t&&(t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[4]=o*i+c*r,t[5]=a*i+l*r,t[6]=s*i+h*r,t[7]=u*i+f*r,t[8]=c*i-o*r,t[9]=l*i-a*r,t[10]=h*i-s*r,t[11]=f*i-u*r}(t,t,this._pitch),this._angle&&function(t,e,n){var r=Math.sin(n),i=Math.cos(n),o=e[0],a=e[1],s=e[2],u=e[3],c=e[4],l=e[5],h=e[6],f=e[7];e!==t&&(t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[0]=o*i+c*r,t[1]=a*i+l*r,t[2]=s*i+h*r,t[3]=u*i+f*r,t[4]=c*i-o*r,t[5]=l*i-a*r,t[6]=h*i-s*r,t[7]=f*i-u*r}(t,t,this._angle),mo(e),ho(e,e,vo(r,i/2,-o/2,1)),fo(this.domCssMatrix||Eo(),e,t)}}(),_getCameraWorldMatrix:function(){var t={};return function(){var e=this.getGLZoom(),n=this.getSize(),r=this.getGLScale(),i=this._prjToPoint(this._prjCenter,e);this.cameraLookAt=vo(this.cameraLookAt||[0,0,0],i.x,i.y,0);var o=this.getPitch()*So,a=this.getBearing()*So,s=this._getFovRatio(),u=r*(n.height||1)/2/s,c=u*Math.cos(o),l=Math.sin(o)*u,h=i.x-l*Math.sin(a),f=i.y-l*Math.cos(a);this.cameraPosition=vo(this.cameraPosition||[0,0,0],h,f,c);var d=l||1,p=this.cameraUp=vo(this.cameraUp||[0,0,0],Math.sin(a)*d,Math.cos(a)*d,0),m=this.cameraWorldMatrix=this.cameraWorldMatrix||Eo();!function(t,e,n,r){var i=[0,0,0],o=[0,0,0],a=[0,0,0];yo(a,e,n),0===_o(a)&&(a[2]=1),xo(a,a),bo(i,r,a),0===_o(a)&&(1===Math.abs(r[2])?a[0]+=1e-4:a[2]+=1e-4,xo(a,a),bo(i,r,a)),xo(i,i),bo(o,a,i),t[0]=i[0],t[4]=o[0],t[8]=a[0],t[1]=i[1],t[5]=o[1],t[9]=a[1],t[2]=i[2],t[6]=o[2],t[10]=a[2]}(m,this.cameraPosition,this.cameraLookAt,p);var g=this.cameraForward||[0,0,0];return yo(g,this.cameraLookAt,this.cameraPosition),this.cameraForward=xo(g,g),function(t,e){var n,r=e[0],i=e[4],o=e[8],a=e[1],s=e[5],u=e[9],c=e[2],l=e[6],h=e[10],f=r+s+h;f>0?(n=.5/Math.sqrt(f+1),t.w=.25/n,t.x=(l-u)*n,t.y=(o-c)*n,t.z=(a-i)*n):r>s&&r>h?(n=2*Math.sqrt(1+r-s-h),t.w=(l-u)/n,t.x=.25*n,t.y=(i+a)/n,t.z=(o+c)/n):s>h?(n=2*Math.sqrt(1+s-r-h),t.w=(o-c)/n,t.x=(i+a)/n,t.y=.25*n,t.z=(u+l)/n):(n=2*Math.sqrt(1+h-r-s),t.w=(a-i)/n,t.x=(o+c)/n,t.y=(u+l)/n,t.z=.25*n)}(t,m),function(t,e){var n=t,r=e.x,i=e.y,o=e.z,a=e.w,s=r+r,u=i+i,c=o+o,l=r*s,h=r*u,f=r*c,d=i*u,p=i*c,m=o*c,g=a*s,v=a*u,y=a*c;n[0]=1-(d+m),n[4]=h-y,n[8]=f+v,n[1]=h+y,n[5]=1-(l+m),n[9]=p-g,n[2]=f-v,n[6]=p+g,n[10]=1-(l+d),n[3]=0,n[7]=0,n[11]=0,n[12]=0,n[13]=0,n[14]=0,n[15]=1}(m,t),function(t,e){var n=t;n[12]=e[0],n[13]=e[1],n[14]=e[2]}(m,this.cameraPosition),m}}(),_getFovRatio:function(){var t=this.getFov();return Math.tan(t/2*So)},_renderLayers:function(){this.isInteracting()||this._getLayers().forEach((function(t){if(t){var e=t._getRenderer();e&&e.setToRedraw&&e.setToRedraw()}}))}}),ii.include({_onViewChange:function(t){this._viewHistory||(this._viewHistory=[],this._viewHistoryPointer=0);for(var e=this._getCurrentView(),n=this._viewHistory.length-1;n>=0;n--)if(K(t,this._viewHistory[n]))return this._viewHistoryPointer=n,void this._fireViewChange(e,t);this._viewHistoryPointer<this._viewHistory.length-1&&this._viewHistory.splice(this._viewHistoryPointer+1),this._viewHistory.push(t);var r=this.options.viewHistoryCount;r>0&&this._viewHistory.length>r&&this._viewHistory.splice(0,this._viewHistory.length-r),this._viewHistoryPointer=this._viewHistory.length-1,this._fireViewChange(e,t)},zoomToPreviousView:function(t){if(void 0===t&&(t={}),!this.hasPreviousView())return null;var e=this._viewHistory[--this._viewHistoryPointer];return this._zoomToView(e,t),e},hasPreviousView:function(){return!(!this._viewHistory||0===this._viewHistoryPointer)},zoomToNextView:function(t){if(void 0===t&&(t={}),!this.hasNextView())return null;var e=this._viewHistory[++this._viewHistoryPointer];return this._zoomToView(e,t),e},hasNextView:function(){return!(!this._viewHistory||this._viewHistoryPointer===this._viewHistory.length-1)},_zoomToView:function(t,e){var n=this,r=this.getView();e.animation?this._animateTo(t,{duration:e.duration},(function(e){"finished"===e.state.playState&&n._fireViewChange(r,t)})):(this.setView(t),this._fireViewChange(r,t))},getViewHistory:function(){return this._viewHistory},_fireViewChange:function(t,e){this._fireEvent("viewchange",{old:t,new:e})},_getCurrentView:function(){return this._viewHistory?this._viewHistory[this._viewHistoryPointer]:null}}),ii.mergeOptions({viewHistory:!0,viewHistoryCount:10});var Ao=function(t){function e(e){var n;return(n=t.call(this,e)||this).on("enable",n._afterEnable,de(de(n))).on("disable",n._afterDisable,de(de(n))),n._measureLayers=[],n}fe(e,t);var n=e.prototype;return n.clear=function(){if(U(this._measureLayers))for(var t=0;t<this._measureLayers.length;t++)this._measureLayers[t].remove();return delete this._lastMeasure,delete this._lastVertex,this._measureLayers=[],this},n.getMeasureLayers=function(){return this._measureLayers},n.getLastMeasure=function(){return this._lastMeasure?this._lastMeasure:0},n.undo=function(){t.prototype.undo.call(this);var e=this._historyPointer;if(e!==this._vertexes.length)for(var n=e;n<this._vertexes.length;n++)this._vertexes[n].label&&this._vertexes[n].label.remove(),this._vertexes[n].marker.remove();return this},n.redo=function(){t.prototype.redo.call(this);var e=this._historyPointer-1;return this._vertexes[e]&&(this._vertexes[e].marker.getLayer()||(this._vertexes[e].label&&this._vertexes[e].label.addTo(this._measureMarkerLayer),this._vertexes[e].marker.addTo(this._measureMarkerLayer))),this},n._measure=function(t){var e,n,r=this.getMap();t instanceof Kr?e=r.computeGeometryLength(t):Array.isArray(t)&&(e=r.getProjection().measureLength(t)),this._lastMeasure=e,n="zh-CN"===this.options.language?[" 米"," 公里"," 英尺"," 英里"]:[" m"," km"," feet"," mile"];var i="";return this.options.metric&&(i+=e<1e3?e.toFixed(0)+n[0]:(e/1e3).toFixed(2)+n[1]),this.options.imperial&&(e*=3.2808399,i.length>0&&(i+="\n"),i+=e<5280?e.toFixed(0)+n[2]:(e/5280).toFixed(2)+n[3]),i},n._registerMeasureEvents=function(){this.on("drawstart",this._msOnDrawStart,this).on("drawvertex",this._msOnDrawVertex,this).on("mousemove",this._msOnMouseMove,this).on("drawend",this._msOnDrawEnd,this)},n._afterEnable=function(){this._registerMeasureEvents()},n._afterDisable=function(){this.off("drawstart",this._msOnDrawStart,this).off("drawvertex",this._msOnDrawVertex,this).off("mousemove",this._msOnMouseMove,this).off("drawend",this._msOnDrawEnd,this)},n._msOnDrawStart=function(t){var e=this.getMap(),n=e._pointToPrj(t.point2d),r=O(),i="distancetool_"+r,o="distancetool_markers_"+r;e.getLayer(i)?(this._measureLineLayer=e.getLayer(i),this._measureMarkerLayer=e.getLayer(o)):(this._measureLineLayer=new eo(i).addTo(e),this._measureMarkerLayer=new eo(o).addTo(e)),this._measureLayers.push(this._measureLineLayer),this._measureLayers.push(this._measureMarkerLayer);var a=new Mi(t.coordinate,{symbol:this.options.vertexSymbol});a._setPrjCoordinates(n);var s="zh-CN"===this.options.language?"起点":"start",u=new qi(s,t.coordinate,this.options.labelOptions);u._setPrjCoordinates(n),this._lastVertex=u,this._addVertexMarker(a,u)},n._msOnMouseMove=function(t){var e=this._measure(this._msGetCoordsToMeasure(t));if(!this._tailMarker){var n=Dt(this.options.vertexSymbol);n.markerWidth/=2,n.markerHeight/=2,this._tailMarker=new Mi(t.coordinate,{symbol:n}).addTo(this._measureMarkerLayer),this._tailLabel=new qi(e,t.coordinate,this.options.labelOptions).addTo(this._measureMarkerLayer)}var r=this._geometry._getPrjCoordinates(),i=r[r.length-1];this._tailMarker.setCoordinates(t.coordinate),this._tailMarker._setPrjCoordinates(i),this._tailLabel.setContent(e),this._tailLabel.setCoordinates(t.coordinate),this._tailLabel._setPrjCoordinates(i)},n._msGetCoordsToMeasure=function(t){return t.geometry.getCoordinates().concat([t.coordinate])},n._msOnDrawVertex=function(t){var e=this._geometry._getPrjCoordinates(),n=e[e.length-1],r=t.geometry,i=new Mi(t.coordinate,{symbol:this.options.vertexSymbol}),o=this._measure(r),a=new qi(o,t.coordinate,this.options.labelOptions);this._addVertexMarker(i,a),a._setPrjCoordinates(n),i._setPrjCoordinates(n),this._lastVertex=a},n._addVertexMarker=function(t,e){this._vertexes||(this._vertexes=[]),this._vertexes.push({label:e,marker:t}),void 0!==this._historyPointer&&(this._vertexes.length=this._historyPointer),this._measureMarkerLayer.addGeometry(t),e&&this._measureMarkerLayer.addGeometry(e)},n._msOnDrawEnd=function(t){this._clearTailMarker();var e=this._lastVertex.getSize();e||(e=new ge(10,10)),this._addClearMarker(this._lastVertex.getCoordinates(),this._lastVertex._getPrjCoordinates(),e.width);var n=t.geometry.copy();n._setPrjCoordinates(t.geometry._getPrjCoordinates()),n.addTo(this._measureLineLayer),this._lastMeasure=n.getLength()},n._addClearMarker=function(t,e,n){var r=this.options.clearButtonSymbol,i={markerDx:(r.markerDx||0)+n,textDx:(r.textDx||0)+n};Array.isArray(r)&&(i=r.map((function(t){return t?{markerDx:(t.markerDx||0)+n,textDx:(t.textDx||0)+n}:null}))),r=Dt(r,i);var o=new Mi(t,{symbol:r}),a=this._measureLineLayer,s=this._measureMarkerLayer;o.on("click",(function(){return a.remove(),s.remove(),!1}),this),o.addTo(this._measureMarkerLayer),o._setPrjCoordinates(e)},n._clearTailMarker=function(){this._tailMarker&&(this._tailMarker.remove(),delete this._tailMarker),this._tailLabel&&(this._tailLabel.remove(),delete this._tailLabel)},e}(oo);Ao.mergeOptions({mode:"LineString",language:"zh-CN",metric:!0,imperial:!1,symbol:{lineColor:"#000",lineWidth:3,lineOpacity:1},vertexSymbol:{markerType:"ellipse",markerFill:"#fff",markerLineColor:"#000",markerLineWidth:3,markerWidth:11,markerHeight:11},labelOptions:{textSymbol:{textFaceName:"monospace",textLineSpacing:1,textHorizontalAlignment:"right",textDx:15},boxStyle:{padding:[6,2],symbol:{markerType:"square",markerFill:"#fff",markerFillOpacity:.9,markerLineColor:"#b4b3b3"}}},clearButtonSymbol:[{markerType:"square",markerFill:"#fff",markerLineColor:"#b4b3b3",markerLineWidth:2,markerWidth:15,markerHeight:15,markerDx:20},{markerType:"x",markerWidth:10,markerHeight:10,markerDx:20}]});var Co=function(t){function e(e){var n;return(n=t.call(this,e)||this).on("enable",n._afterEnable,de(de(n))).on("disable",n._afterDisable,de(de(n))),n._measureLayers=[],n}fe(e,t);var n=e.prototype;return n._measure=function(t){var e,n,r=this.getMap();t instanceof Kr?e=r.computeGeometryArea(t):Array.isArray(t)&&(e=r.getProjection().measureArea(t)),this._lastMeasure=e,n="zh-CN"===this.options.language?[" 平方米"," 平方公里"," 平方英尺"," 平方英里"]:[" sq.m"," sq.km"," sq.ft"," sq.mi"];var i="";if(this.options.metric&&(i+=e<1e6?e.toFixed(0)+n[0]:(e/1e6).toFixed(2)+n[1]),this.options.imperial){e*=3.2808399,i.length>0&&(i+="\n");var o=27878400;i+=e<o?e.toFixed(0)+n[2]:(e/o).toFixed(2)+n[3]}return i},n._msGetCoordsToMeasure=function(t){return t.geometry.getShell().concat([t.coordinate])},n._msOnDrawVertex=function(t){var e=this.getMap()._pointToPrj(t.point2d),n=new Mi(t.coordinate,{symbol:this.options.vertexSymbol});n._setPrjCoordinates(e),this._measure(t.geometry),this._lastVertex=n,this._addVertexMarker(n)},n._msOnDrawEnd=function(t){this._clearTailMarker();var e=this.getMap()._pointToPrj(t.point2d),n=this._measure(t.geometry),r=new qi(n,t.coordinate,this.options.labelOptions).addTo(this._measureMarkerLayer);r._setPrjCoordinates(e);var i=r.getSize();i||(i=new ge(10,10)),this._addClearMarker(t.coordinate,e,i.width);var o=t.geometry.copy();o._setPrjCoordinates(t.geometry._getPrjCoordinates()),o.addTo(this._measureLineLayer),this._lastMeasure=o.getArea()},e}(Ao);Co.mergeOptions({mode:"Polygon",symbol:{lineColor:"#000000",lineWidth:2,lineOpacity:1,lineDasharray:"",polygonFill:"#ffffff",polygonOpacity:.5}});var Po={create:function(t,e){var n=t.unproject(e[0]),r=new Di(n,0);return r._setPrjCoordinates(e[0]),r},update:function(t,e,n){var r=n.getMap(),i=Array.isArray(e)?e[e.length-1]:e,o=t.unproject(i),a=r.computeLength(n.getCenter(),o);n.setRadius(a)},generate:function(t){return t}};oo.registerMode("circle",d({clickLimit:2,action:["click","mousemove","click"]},Po)),oo.registerMode("freeHandCircle",d({action:["mousedown","mousemove","mouseup"]},Po));var Lo={create:function(t,e){var n=t.unproject(e[0]),r=new ji(n,0,0);return r._setPrjCoordinates(e[0]),r},update:function(t,e,n){var r=n.getMap(),i=n.getCenter(),o=Array.isArray(e)?e[e.length-1]:e,a=t.unproject(o),s=r.computeLength(i,new On({x:a.x,y:i.y})),u=r.computeLength(i,new On({x:i.x,y:a.y}));n.setWidth(2*s),n.setHeight(2*u)},generate:function(t){return t}};oo.registerMode("ellipse",d({clickLimit:2,action:["click","mousemove","click"]},Lo)),oo.registerMode("freeHandEllipse",d({action:["mousedown","mousemove","mouseup"]},Lo));var Oo={create:function(t,e){var n=new bi([]);return n._firstClick=e[0],n},update:function(t,e,n,r){var i=n.getMap(),o=r.containerPoint,a=i._prjToContainerPoint(n._firstClick),s=[[a.x,a.y],[o.x,a.y],[o.x,o.y],[a.x,o.y]];n.setCoordinates(s.map((function(t){return i.containerPointToCoord(new me(t))}))),n._setPrjCoordinates(s.map((function(t){return i._containerPointToPrj(new me(t))})))},generate:function(t){return t}};oo.registerMode("rectangle",d({clickLimit:2,action:["click","mousemove","click"]},Oo)),oo.registerMode("freeHandRectangle",d({action:["mousedown","mousemove","mouseup"]},Oo)),oo.registerMode("point",{clickLimit:1,action:["click"],create:function(t,e){var n=t.unproject(e[0]),r=new Mi(n);return r._setPrjCoordinates(e[0]),r},generate:function(t){return t}});var Ro={create:function(t,e){var n=e.map((function(e){return t.unproject(e)})),r=new Ti(n);return r._setPrjCoordinates(e),r},update:function(t,e,n){var r,i=n.getSymbol();Array.isArray(e)?r=e:(r=n._getPrjCoordinates()).push(e);var o=r.map((function(e){return t.unproject(e)}));n.setCoordinates(o),n._setPrjCoordinates(r);var a=n.getLayer();if(a){var s=a.getGeometryById("polygon");if(!s&&r.length>=3){if(s=new bi([o],{id:"polygon"}),i){var u=Dt(i,{lineOpacity:0});s.setSymbol(u)}s.addTo(a)}s&&s._setPrjCoordinates(r)}},generate:function(t){var e=new bi(t.getCoordinates(),{symbol:t.getSymbol()});return e._setPrjCoordinates(t._getPrjCoordinates()),e._projCode=t._projCode,e}};oo.registerMode("polygon",d({action:["click","mousemove","dblclick"]},Ro)),oo.registerMode("freeHandPolygon",d({action:["mousedown","mousemove","mouseup"]},Ro));var ko={create:function(t,e){var n=e.map((function(e){return t.unproject(e)})),r=new Ti(n);return r._setPrjCoordinates(e),r},update:function(t,e,n){var r;Array.isArray(e)?r=e:(r=n._getPrjCoordinates()).push(e);var i=r.map((function(e){return t.unproject(e)}));n.setCoordinates(i),n._setPrjCoordinates(r)},generate:function(t){return t}};function Io(t){for(var e=t.tileInfo,n=[e.cols,e.rows],r=[],i=e.lods,o=0,a=i.length;o<a;o++)r.push(i[o].resolution);var s=t.fullExtent,u=e.origin,c=[1,-1,u.x,u.y];return delete s.spatialReference,{spatialReference:{resolutions:r,fullExtent:s},tileSystem:c,tileSize:n}}function Do(t,e){return void 0===e&&(e=[]),e.forEach((function(e){var n=e[0],r=e[1];t=t.replace(n,r)})),t}function jo(t,e,n){void 0===n&&(n={});var r,i,o=t[e],a=o.getElementsByTagName("TileMatrix"),s=[],u=[],c=[];if(!r){var l=o.getElementsByTagName("ows:SupportedCRS")[0];if(l){for(r=(r=l.textContent).split("EPSG")[1];r.indexOf(":")>-1;)r=r.replace(":","");r=function(t){var e=t.indexOf("EPSG")>-1?t:"EPSG:"+t;return e=Do(e,[["4490","4326"],["102100","3857"],["900913","3857"]])}(r)}}i||(i=o.getElementsByTagName("ows:Identifier")[0])&&(i=i.textContent);var h=.0002645833333333333;n.isArcgis&&(h=28e-5),r&&r.indexOf("4326")>-1&&(h=2.3767925226029154e-9,n.isArcgis&&(h=2.518101729011901e-9));for(var f=1/0,d=0;d<a.length;d++){var p=a[d],m=p.getElementsByTagName("ows:Identifier")[0].textContent;m=parseInt(m),f=Math.min(f,m);var g=p.getElementsByTagName("ScaleDenominator")[0].textContent,v=p.getElementsByTagName("TopLeftCorner")[0].textContent,y=p.getElementsByTagName("TileWidth")[0].textContent,_=p.getElementsByTagName("TileHeight")[0].textContent;if(0===c.length&&c.push(parseInt(y),parseInt(_)),0===u.length){var x=v.split(" ").filter((function(t){return""!==t})).map((function(t){return parseFloat(t)})),b=x[0],w=x[1];b>0?u.push(1,-1,w,b):u.push(1,-1,b,w)}var M=parseFloat(g)*h;s.push(M)}if(f>0)for(var S=s[0],T=f-1;T>=0;T--)S*=2,s.splice(0,0,S);return{resolutions:s,tileSize:c,tileSystem:u,projection:r,TileMatrixSet:i}}oo.registerMode("linestring",d({action:["click","mousemove","dblclick"]},ko)),oo.registerMode("freeHandLinestring",d({action:["mousedown","mousemove","mouseup"]},ko)),oo.registerMode("arccurve",{action:["click","mousemove","dblclick"],create:function(t,e){var n=e.map((function(e){return t.unproject(e)})),r=new Bi(n);return r._setPrjCoordinates(e),r},update:ko.update,generate:function(t){return t}}),oo.registerMode("quadbeziercurve",{action:["click","mousemove","dblclick"],create:function(t,e){var n=e.map((function(e){return t.unproject(e)})),r=new Gi(n);return r._setPrjCoordinates(e),r},update:ko.update,generate:function(t){return t}}),oo.registerMode("cubicbeziercurve",{action:["click","mousemove","dblclick"],create:function(t,e){var n=e.map((function(e){return t.unproject(e)})),r=new Hi(n);return r._setPrjCoordinates(e),r},update:ko.update,generate:function(t){return t}}),oo.registerMode("boxZoom",{action:["mousedown","mousemove","mouseup"],create:function(t,e){e=e[0];var n=t.unproject(e),r=new Mi(n);return r._firstClick=e,r},update:function(t,e,n,r){var i=n.getMap(),o=i._prjToContainerPoint(n._firstClick),a=r.containerPoint;e=i._containerPointToPrj(new On(Math.min(o.x,a.x),Math.min(o.y,a.y)));var s=t.unproject(e);n.setCoordinates(s)._setPrjCoordinates(e),n.updateSymbol({markerWidth:Math.abs(o.x-a.x),markerHeight:Math.abs(o.y-a.y)})},generate:function(t){return t}}),Qr.loadArcgis=function(t,e,n){if(void 0===n&&(n={jsonp:!0}),y(t)&&"{"!==t.substring(0,1))sn.getJSON(t,(function(t,n){if(t)e(t);else{var r=Io(n);e(null,r)}}),n);else{y(t)&&(t=k(t));var r=Io(t);e(null,r)}return this},Qr.loadWMTS=function(t,e,n){return void 0===n&&(n={jsonp:!0}),y(t)&&sn.get(t,(function(r,i){if(r)e(r);else{var o=function(t,e,n){var r=(new DOMParser).parseFromString(t,"text/xml").querySelectorAll("Contents")[0];if(!r)return[];var i=r.getElementsByTagName("Layer");if(!i.length)return[];for(var o=[],a=0,s=r.childNodes.length;a<s;a++)"TileMatrixSet"===r.childNodes[a].nodeName&&o.push(r.childNodes[a]);if(!o.length)return[];for(var u=[],c=0,l=i.length;c<l;c++){var h=i[c],f=h.querySelectorAll("Style")[0];f&&(f=f.getElementsByTagName("ows:Identifier")[0])&&(f=f.textContent);var d=h.getElementsByTagName("ows:Identifier")[0];d&&(d=d.textContent);var p=h.querySelectorAll("ResourceURL")[0],m="";p&&(m=p.attributes.template.value);var g=jo(o,c,n),v=g.resolutions,y=g.tileSize,_=g.tileSystem,x=g.projection,b=g.TileMatrixSet;m.length||(m=e.substr(0,e.lastIndexOf("?")),m+="?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER={LAYER}&STYLE={Style}&TILEMATRIXSET={TileMatrixSet}&FORMAT=tiles&TILEMATRIX={TileMatrix}&TILEROW={TileRow}&TILECOL={TileCol}");var w=Do(m,[["{LAYER}",d],["{Layer}",d],["{layer}",d],["{STYLE}",f],["{Style}",f],["{style}",f],["{TileMatrixSet}",b],["{TileMatrix}","{z}"],["{TileRow}","{y}"],["{TileCol}","{x}"]]);u.push({tileSize:y,tileSystem:_,spatialReference:{resolutions:v,projection:x},urlTemplate:w,info:{layerName:d,TileMatrixSet:b,style:f,tileSize:y,tileSystem:_,resolutions:v,projection:x,urlTemplate:w}})}return u}(i,t,n);e(null,o)}}),n),this};var zo=function(t){function e(e){return t.call(this,e)||this}fe(e,t);var n=e.prototype;return n.addTo=function(t){return this._owner=t,this._switchEvents("on"),this.onAdd&&this.onAdd(),this.fire("add"),this},n.getMap=function(){return this._owner?this._owner.getBaseLayer?this._owner:this._owner.getMap():null},n.show=function(t){var e=this.getMap();if(!e)return this;this._mapEventsOn||this._switchMapEvents("on"),t=t||this._coordinate||this._owner.getCenter();var n=this.isVisible();this.fire("showstart");var r=this._getUIContainer();this._coordinate=t,this._removePrevDOM();var i=this.__uiDOM=this.buildOn(e);if(i.eventsPropagation=this.options.eventsPropagation,!i)return this.fire("showend"),this;this._measureSize(i),this._singleton()&&(e[this._uiDomKey()]=i),this._setPosition(),i.style[Ie]=null,r.appendChild(i);var o=this._getAnimation();if(n&&(o.ok=!1),o.ok&&(o.fade&&(i.style.opacity=0),o.scale)){if(this.getTransformOrigin){var a=this.getTransformOrigin();i.style[ke]=a}i.style[Re]=this._toCSSTranslate(this._pos)+" scale(0)"}i.style.display="",this.options.eventsToStop&&rn(i,this.options.eventsToStop,Ue),this.options.autoPan&&this._autoPan();var s=o.transition;return o.ok&&s&&(i.offsetHeight,s&&(i.style[Ie]=s),o.fade&&(i.style.opacity=1),o.scale&&(i.style[Re]=this._toCSSTranslate(this._pos)+" scale(1)")),this.fire("showend"),this},n.hide=function(){var t=this;if(!this.getDOM()||!this.getMap())return this;var e=this._getAnimation(),n=this.getDOM();return this.options.animationOnHide||(e.ok=!1),e.ok?(n.offsetHeight,n.style[Ie]=e.transition,setTimeout((function(){n.style.display="none",t.fire("hide")}),this.options.animationDuration)):(n.style.display="none",this.fire("hide")),e.fade&&(n.style.opacity=0),e.scale&&(n.style[Re]=this._toCSSTranslate(this._pos)+" scale(0)"),this},n.isVisible=function(){var t=this.getDOM();return this.getMap()&&t&&t.parentNode&&"none"!==t.style.display},n.remove=function(){return delete this._mapEventsOn,this._owner?(this.hide(),this._switchEvents("off"),this.onRemove&&this.onRemove(),!this._singleton()&&this.__uiDOM&&this._removePrevDOM(),delete this._owner,this.fire("remove"),this):this},n.getSize=function(){return this._size?this._size.copy():null},n.getOwner=function(){return this._owner},n.getDOM=function(){return this.__uiDOM},n.getPosition=function(){if(!this.getMap())return null;var t=this._getViewPoint()._round();if(this.getOffset){var e=this.getOffset()._round();e&&t._add(e)}return t},n._getAnimation=function(){for(var t={fade:!1,scale:!1},e=this.options.animation?this.options.animation.split(","):[],n=0;n<e.length;n++){var r=ve(e[n]);"fade"===r?t.fade=!0:"scale"===r&&(t.scale=!0)}var i=null;return t.fade&&(i="opacity "+this.options.animationDuration+"ms"),t.scale&&(i=i?i+",":"",i+=Re+" "+this.options.animationDuration+"ms"),t.transition=i,t.ok=null!==i,t},n._getViewPoint=function(){var t=0;if(this._owner&&this._owner.getAltitude){var e=this._owner.getAltitude();e>0&&(t=this._meterToPoint(this._coordinate,e))}return this.getMap().coordToViewPoint(this._coordinate,void 0,t)._add(this.options.dx,this.options.dy)},n._meterToPoint=function(t,e){return this.getMap().distanceToPoint(e,0,void 0,t).x*N(e)},n._autoPan=function(){var t=this.getMap(),e=this.getDOM();if(!t.isMoving()){var n=this._pos,r=t.getSize(),i=r.width,o=r.height,a=t.viewPointToContainerPoint(n),s=parseInt(e.clientWidth),u=parseInt(e.clientHeight),c=0,l=0;a.x<0?c=-(a.x-s/2):a.x+s-35>i&&(c=i-(a.x+3*s/2)),a.y-u<0?l=50-(a.y-u):a.y>o&&(l=o-a.y-u-30),0===l&&0===c||t.panBy(new me(c,l),{duration:this.options.autoPanDuration})}},n._measureSize=function(t){var e=this._getUIContainer();t.style.position="absolute",t.style.left="-99999px";var n=t.style.bottom?"bottom":"top";return t.style[n]="-99999px",t.style.display="",e.appendChild(t),this._size=new ge(t.clientWidth,t.clientHeight),t.style.display="none",t.style.left="0px",t.style[n]="0px",this._size},n._removePrevDOM=function(){this.onDomRemove&&this.onDomRemove();var t=this.options.eventsToStop;if(this._singleton()){var e=this.getMap(),n=this._uiDomKey();e[n]&&(t&&on(e[n],t,Ue),Ne(e[n]),delete e[n]),delete this.__uiDOM}else this.__uiDOM&&(t&&on(this.__uiDOM,t,Ue),Ne(this.__uiDOM),delete this.__uiDOM)},n._uiDomKey=function(){return"__ui_"+this._getClassName()},n._singleton=function(){return this.options.single},n._getUIContainer=function(){return this.getMap()._panels.ui},n._getClassName=function(){return"UIComponent"},n._switchMapEvents=function(t){var e=this.getMap();if(e){this._mapEventsOn="on"===t;var n=this._getDefaultEvents();if(this.getEvents&&d(n,this.getEvents()),n)for(var r in n)n.hasOwnProperty(r)&&e[t](r,n[r],this)}},n._switchEvents=function(t){this._switchMapEvents(t);var e=this._getOwnerEvents();if(this._owner)for(var n in e)e.hasOwnProperty(n)&&this._owner[t](n,e[n],this)},n._getDefaultEvents=function(){return{"zooming rotate pitch":this.onEvent,zoomend:this.onZoomEnd,moving:this.onMoving,resize:this.onResize}},n._getOwnerEvents=function(){var t={};return this._owner&&this._owner instanceof Kr&&(t.positionchange=this.onGeometryPositionChange),this.getOwnerEvents&&d(t,this.getOwnerEvents()),t},n.onGeometryPositionChange=function(t){this._owner&&this.isVisible()&&this.show(t.target.getCenter())},n.onMoving=function(){this.isVisible()&&this.getMap().isTransforming()&&this._updatePosition()},n.onEvent=function(){this.isVisible()&&this._updatePosition()},n.onZoomEnd=function(){this.isVisible()&&this._setPosition()},n.onResize=function(){this.isVisible()&&this._setPosition()},n._updatePosition=function(){this.getMap()._getRenderer().callInNextFrame(this._setPosition.bind(this))},n._setPosition=function(){var t=this.getDOM();if(t){t.style[Ie]=null;var e=this.getPosition();this._pos=e,t.style[Re]=this._toCSSTranslate(e)+" scale(1)"}},n._toCSSTranslate=function(t){if(!t)return"";if(he.any3d){var e=this.getMap(),n=e?e.getBearing():0,r=e?e.getPitch():0,i="";return this.options.pitchWithMap&&r&&(i+=" rotateX("+Math.round(r)+"deg)"),this.options.rotateWithMap&&n&&(i+=" rotateZ("+Math.round(-n)+"deg)"),"translate3d("+t.x+"px,"+t.y+"px, 0px)"+i}return"translate("+t.x+"px,"+t.y+"px)"},e.isSupport=function(t){return!!(t&&_(t.on)&&_(t.off)&&_(t.getCenter))},e}(xn(Mn));zo.mergeOptions({eventsPropagation:!1,eventsToStop:null,dx:0,dy:0,autoPan:!1,autoPanDuration:600,single:!0,animation:"scale",animationOnHide:!0,animationDuration:500,pitchWithMap:!1,rotateWithMap:!1});var No="mousedown mouseup mouseenter mouseover mouseout mousemove click dblclick contextmenu keypress touchstart touchmove touchend",Fo=function(t){function e(e,n){var r;return(r=t.call(this,n)||this)._markerCoord=new On(e),r}fe(e,t);var n=e.prototype;return n._getClassName=function(){return"UIMarker"},n.setCoordinates=function(t){return this._markerCoord=t,this.fire("positionchange"),this.isVisible()&&(this._coordinate=this._markerCoord,this._setPosition()),this},n.getCoordinates=function(){return this._markerCoord},n.setContent=function(t){var e=this.options.content;return this.options.content=t,this.fire("contentchange",{old:e,new:t}),this.isVisible()&&this.show(),this},n.getContent=function(){return this.options.content},n.onAdd=function(){this.show()},n.show=function(){return t.prototype.show.call(this,this._markerCoord)},n.flash=function(t,e,n,r){return et.call(this,t,e,n,r)},n.buildOn=function(){var t;return y(this.options.content)?(t=je("div")).innerHTML=this.options.content:t=this.options.content,this.options.containerClass&&(t.className=this.options.containerClass),this._registerDOMEvents(t),t},n.getOffset=function(){var t=this.getSize();return new me(-t.width/2,-t.height/2)},n.getTransformOrigin=function(){return"center center"},n.onDomRemove=function(){var t=this.getDOM();this._removeDOMEvents(t)},n.isDragging=function(){return!!this.draggable&&this.draggable.isDragging()},n._registerDOMEvents=function(t){rn(t,No,this._onDomEvents,this)},n._onDomEvents=function(t){var e=this.getMap()._parseEvent(t,t.type);this.fire(t.type,e)},n._removeDOMEvents=function(t){on(t,No,this._onDomEvents,this)},n._getConnectPoints=function(){var t=this.getMap(),e=t.coordToContainerPoint(this.getCoordinates()),n=this.getSize(),r=n.width,i=n.height;return[t.containerPointToCoordinate(e.add(-r/2,0)),t.containerPointToCoordinate(e.add(r/2,0)),t.containerPointToCoordinate(e.add(0,i/2)),t.containerPointToCoordinate(e.add(0,-i/2))]},e}(En(zo));Fo.mergeOptions({containerClass:null,eventsPropagation:!0,draggable:!1,single:!1,content:null});var Bo=he.touch?"touchstart mousedown":"mousedown",Ho=function(t){function e(e){return t.call(this,e)||this}fe(e,t);var n=e.prototype;return n.addHooks=function(){this.target.on(Bo,this._startDrag,this)},n.removeHooks=function(){this.target.off(Bo,this._startDrag,this)},n._startDrag=function(t){var e=t.domEvent;e.touches&&e.touches.length>1||2===e.button||this.isDragging()||(this.target.on("click",this._endDrag,this),this._lastCoord=t.coordinate,this._lastPoint=t.containerPoint,this._prepareDragHandler(),this._dragHandler.onMouseDown(t.domEvent),this.target.fire("dragstart",t))},n._prepareDragHandler=function(){this._dragHandler=new Ln(this.target.getDOM(),{cancelOn:this._cancelOn.bind(this),ignoreMouseleave:!0}),this._dragHandler.on("mousedown",this._onMouseDown,this),this._dragHandler.on("dragging",this._dragging,this),this._dragHandler.on("mouseup",this._endDrag,this),this._dragHandler.enable()},n._cancelOn=function(t){var e=(t.srcElement||t.target).tagName.toLowerCase();return"button"===e||"input"===e||"select"===e||"option"===e||"textarea"===e},n._onMouseDown=function(t){Ue(t.domEvent)},n._dragging=function(t){var e=this.target,n=e.getMap()._parseEvent(t.domEvent),r=n.domEvent;if(!(r.touches&&r.touches.length>1))if(this._isDragging){var i=n.coordinate,o=n.containerPoint;this._lastCoord||(this._lastCoord=i),this._lastPoint||(this._lastPoint=o);var a=i.sub(this._lastCoord),s=o.sub(this._lastPoint);this._lastCoord=i,this._lastPoint=o,this.target.setCoordinates(this.target.getCoordinates().add(a)),n.coordOffset=a,n.pointOffset=s,e.fire("dragging",n)}else this._isDragging=!0},n._endDrag=function(t){var e=this.target,n=e.getMap();if(this._dragHandler&&(e.off("click",this._endDrag,this),this._dragHandler.disable(),delete this._dragHandler),delete this._lastCoord,delete this._lastPoint,this._isDragging=!1,n){var r=n._parseEvent(t.domEvent);e.fire("dragend",r)}},n.isDragging=function(){return!!this._isDragging},e}(wn);Fo.addInitHook("addHandler","draggable",Ho);var Go=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n._getClassName=function(){return"InfoWindow"},n.addTo=function(e){return e instanceof Kr&&(e.getInfoWindow()&&e.getInfoWindow()!==this&&e.removeInfoWindow(),e._infoWindow=this),t.prototype.addTo.call(this,e)},n.setContent=function(t){var e=this.options.content;return this.options.content=t,this.fire("contentchange",{old:e,new:t}),this.isVisible()&&this.show(this._coordinate),this},n.getContent=function(){return this.options.content},n.setTitle=function(t){var e=t;return this.options.title=t,this.fire("contentchange",{old:e,new:t}),this.isVisible()&&this.show(this._coordinate),this},n.getTitle=function(){return this.options.title},n.buildOn=function(){if(this.options.custom){if(y(this.options.content)){var t=je("div");return t.innerHTML=this.options.content,t}return this.options.content}var e=je("div");this.options.containerClass&&(e.className=this.options.containerClass),e.style.width=this._getWindowWidth()+"px",e.style.bottom="0px";var n='<em class="maptalks-ico"></em>';this.options.title&&(n+="<h2>"+this.options.title+"</h2>"),n+='<a href="javascript:void(0);" class="maptalks-close"></a><div class="maptalks-msgContent"></div>',e.innerHTML=n;var r=e.querySelector(".maptalks-msgContent");return y(this.options.content)?r.innerHTML=this.options.content:r.appendChild(this.options.content),this._onCloseBtnClick=this.hide.bind(this),Fe(e.querySelector(".maptalks-close"),"click touchend",this._onCloseBtnClick),e},n.getTransformOrigin=function(){return this.getSize().width/2+"px bottom"},n.getOffset=function(){var t=this.getSize(),e=new me(-t.width/2,0);this.options.custom?e._sub(0,t.height):e._sub(4,12);var n=this.getOwner();if(n instanceof Mi||n instanceof Pi){var r,i;if(n instanceof Mi)r=n._getPainter(),i=n.getSize();else{var o=n.getGeometries();if(!o||!o.length)return e;r=o[0]._getPainter(),i=o[0].getSize()}if(r){var a=r.getFixedExtent();e._add(a.xmax-i.width/2,a.ymin)}else e._add(0,-i.height)}return e},n.show=function(e){return this.getMap()&&this.getMap().options.enableInfoWindow?t.prototype.show.call(this,e):this},n.getEvents=function(){if(!this.options.autoCloseOn)return null;var t={};return t[this.options.autoCloseOn]=this.hide,t},n.getOwnerEvents=function(){var t=this.getOwner();if(!this.options.autoOpenOn||!t)return null;var e={};return e[this.options.autoOpenOn]=this._onAutoOpen,e},n.onRemove=function(){this.onDomRemove()},n.onDomRemove=function(){this._onCloseBtnClick&&(Be(this.getDOM().childNodes[2],"click touchend",this._onCloseBtnClick),delete this._onCloseBtnClick)},n._onAutoOpen=function(t){var e=this,n=this.getOwner();setTimeout((function(){n instanceof Mi||n instanceof zo?e.show(n.getCoordinates()):n instanceof Pi?e.show(n.findClosest(t.coordinate)):n instanceof Ti||n instanceof Oi?(e.getMap().getScale()>=8&&(t.coordinate=e._rectifyMouseCoordinte(n,t.coordinate)),e.show(t.coordinate)):e.show(t.coordinate)}),1)},n._rectifyMouseCoordinte=function(t,e){var n=this;return t instanceof Ti?this._rectifyLineStringMouseCoordinate(t,e).coordinate:t instanceof Oi?t.getGeometries().map((function(t){return n._rectifyLineStringMouseCoordinate(t,e)})).sort((function(t,e){return t.dis-e.dis}))[0].coordinate:e},n._rectifyLineStringMouseCoordinate=function(t,e){for(var n=this,r=t.getCoordinates().map((function(t){return n.getMap().coordToContainerPoint(t)})),i=this.getMap().coordToContainerPoint(e),o=1/0,a=-1,s=0,u=r.length;s<u;s++){var c=r[s],l=i.distanceTo(c);l<o&&(o=l,a=s)}var h=[];0===a?h.push(r[0],r[1]):a===r.length-1?h.push(r[a-1],r[a]):h.push(r[a-1],r[a],r[a+1]);for(var f=[],d=this.getMap().getSize(),p=d.width,m=d.height,g=0,v=h.length-1;g<v;g++){var y=h[g],_=h[g+1];if(y.x===_.x)for(var x=Math.max(0,Math.min(y.y,_.y)),b=Math.min(m,Math.max(y.y,_.y)),w=x;w<=b;w++)f.push(new me(y.x,w));else for(var M=(_.y-y.y)/(_.x-y.x),S=Math.max(0,Math.min(y.x,_.x)),T=Math.min(p,Math.max(y.x,_.x)),E=S;E<=T;E++){var A=M*(E-y.x)+y.y;f.push(new me(E,A))}}for(var C=1/0,P=-1,L=0,O=f.length;L<O;L++){var R=f[L],k=i.distanceTo(R);k<C&&(C=k,P=L)}return{dis:C,coordinate:P<0?e:this.getMap().containerPointToCoord(f[P])}},n._getWindowWidth=function(){var t=this.options.width;return t||(t=300),t},e}(zo);Go.mergeOptions({containerClass:"maptalks-msgBox",autoPan:!0,autoCloseOn:null,autoOpenOn:"click",width:300,minHeight:120,custom:!1,title:null,content:null});var Uo=function(t){fe(n,t);var e=n.prototype;function n(e,n){var r;return void 0===n&&(n={}),(r=t.call(this,n)||this)._content=e,r}return e._getClassName=function(){return"ToolTip"},e.addTo=function(e){if(n.isSupport(e))return e.on("mousemove",this.onMouseMove,this),e.on("mouseout",this.onMouseOut,this),t.prototype.addTo.call(this,e);throw new Error("Invalid geometry or UIMarker the tooltip is added to.")},e.setStyle=function(t){return this.options.containerClass=t,this},e.getStyle=function(){return this.options.containerClass},e.getContent=function(){return this._content},e.buildOn=function(){var t=je("div"),e=this.options||{};e.height&&(t.style.height=e.height+"px"),e.width&&(t.style.width=e.width+"px");var n=e.containerClass||e.cssName;return!n&&e.height&&(t.style.lineHeight=e.height+"px"),t.innerHTML='<div class="'+n+'">'+this._content+"</div>",t},e.onMouseOut=function(){clearTimeout(this._timeout),this.isVisible()&&this._removePrevDOM()},e.onMouseMove=function(t){var e=this;clearTimeout(this._timeout);var n=this.getMap();if(n){var r=n.locateByPoint(t.coordinate,-5,25);0===this.options.showTimeout?this.show(r):this._timeout=setTimeout((function(){n&&e.show(r)}),this.options.showTimeout)}},e.onRemove=function(){clearTimeout(this._timeout),this._owner&&(this._owner.off("mouseover",this.onMouseOver,this),this._owner.off("mouseout",this.onMouseOut,this))},e._getViewPoint=function(){return this.getMap().coordToViewPoint(this._coordinate,void 0,0)._add(this.options.dx,this.options.dy)},n}(zo);Uo.mergeOptions({width:0,height:0,animation:"fade",containerClass:"maptalks-tooltip",showTimeout:400});var Wo=function(t){function e(e){return t.call(this,e)||this}fe(e,t);var n=e.prototype;return n._getClassName=function(){return"Menu"},n.addTo=function(t){return t._menu&&t._menu!==this&&t.removeMenu(),t._menu=this,zo.prototype.addTo.apply(this,arguments)},n.setItems=function(t){return this.options.items=t,this},n.getItems=function(){return this.options.items||[]},n.buildOn=function(){if(this.options.custom){if(y(this.options.items)){var t=je("div");return t.innerHTML=this.options.items,t}return this.options.items}var e=je("div");this.options.containerClass&&Xe(e,this.options.containerClass),e.style.width=this._getMenuWidth()+"px";var n=this._createMenuItemDom();return e.appendChild(n),rn(e,"contextmenu",Ge),e},n.getOffset=function(){if(!this.getMap())return null;var t=this.getMap().getSize(),e=this.getMap().viewPointToContainerPoint(this._getViewPoint()),n=this.getSize(),r=0,i=0;return e.x+n.width>t.width&&(r=-n.width),e.y+n.height>t.height&&(i=-n.height),new me(r,i)},n.getTransformOrigin=function(){var t=this.getOffset()._multi(-1);return t.x+"px "+t.y+"px"},n.getEvents=function(){return{"_zoomstart _zoomend _movestart _dblclick _click":this._removePrevDOM}},n._createMenuItemDom=function(){var t=this,e=this.getMap(),n=je("ul");Xe(n,"maptalks-menu-items");var r,i,o=this.getItems();function a(n){return function(r){var i=e._parseEvent(r,"click");i.target=t,i.owner=t._owner,i.index=n,!1!==this._callback(i)&&t.hide()}}for(var s=0,u=o.length;s<u;s++){if("-"===(r=o[s])||"_"===r)Xe(i=je("li"),"maptalks-menu-splitter");else{i=je("li");var c=r.item;_(c)&&(c=c({owner:this._owner,index:s})),i.innerHTML=c,i._callback=r.click,rn(i,"click",a(s))}n.appendChild(i)}var l=this.options.maxHeight||0;return l>0&&Ye(n,"max-height: "+l+"px; overflow-y: auto;"),n},n._getMenuWidth=function(){return this.options.width||160},e}(zo);Wo.mergeOptions({containerClass:"maptalks-menu",animation:null,animationDelay:10,animationOnHide:!1,autoPan:!1,width:160,maxHeight:0,custom:!1,items:[]});var Vo={setMenu:function(t){return this._menuOptions=t,this._menu?this._menu.setOptions(t):this.on("contextmenu",this._defaultOpenMenu,this),this},openMenu:function(t){var e=this instanceof ii?this:this.getMap();return t||(t=this.getCenter()),this._menu?this._menu.show(t):this._menuOptions&&e&&(this._bindMenu(this._menuOptions),this._menu.show(t)),this},setMenuItems:function(t){return this._menuOptions||(this._menuOptions={}),Array.isArray(t)&&(this._menuOptions.custom=!1),this._menuOptions.items=t,this.setMenu(this._menuOptions),this},getMenuItems:function(){return this._menu?this._menu.getItems():this._menuOptions&&this._menuOptions.items||[]},closeMenu:function(){return this._menu&&this._menu.hide(),this},removeMenu:function(){return this.off("contextmenu",this._defaultOpenMenu,this),this._unbindMenu(),delete this._menuOptions,this},_bindMenu:function(t){return this._menu=new Wo(t),this._menu.addTo(this),this},_unbindMenu:function(){return this._menu&&(this.closeMenu(),this._menu.remove(),delete this._menu),this},_defaultOpenMenu:function(t){return this.listens("contextmenu")>1||(this.openMenu(t.coordinate),!1)}};ii.include(Vo),Kr.include(Vo);var Zo=Object.freeze({UIComponent:zo,UIMarker:Fo,InfoWindow:Go,ToolTip:Uo,Menuable:Vo,Menu:Wo}),qo=function(t){function e(e){return e&&e.position&&!y(e.position)&&(e.position=d({},e.position)),t.call(this,e)||this}fe(e,t);var n=e.prototype;return n.addTo=function(t){if(this.remove(),!t.options.control)return this;this._map=t;var e=t._panels.control;return this.__ctrlContainer=je("div"),Ye(this.__ctrlContainer,"position:absolute;overflow:visible;"),this.update(),e.appendChild(this.__ctrlContainer),this.onAdd&&this.onAdd(),this.fire("add",{dom:e}),this},n.update=function(){return this.__ctrlContainer.innerHTML="",this._controlDom=this.buildOn(this.getMap()),this._controlDom&&(this._updatePosition(),this.__ctrlContainer.appendChild(this._controlDom)),this},n.getMap=function(){return this._map},n.getPosition=function(){return d({},this._parse(this.options.position))},n.setPosition=function(t){return y(t)?this.options.position=t:this.options.position=d({},t),this._updatePosition(),this},n.getContainerPoint=function(){var t,e,n=this.getPosition(),r=this.getMap().getSize();return p(n.left)?p(n.right)||(t=r.width-parseInt(n.right)):t=parseInt(n.left),p(n.top)?p(n.bottom)||(e=r.height-parseInt(n.bottom)):e=parseInt(n.top),new me(t,e)},n.getContainer=function(){return this.__ctrlContainer},n.getDOM=function(){return this._controlDom},n.show=function(){return this.__ctrlContainer.style.display="",this},n.hide=function(){return this.__ctrlContainer.style.display="none",this},n.isVisible=function(){return this.__ctrlContainer&&""===this.__ctrlContainer.style.display},n.remove=function(){return this._map?(Ne(this.__ctrlContainer),this.onRemove&&this.onRemove(),delete this._map,delete this.__ctrlContainer,delete this._controlDom,this.fire("remove"),this):this},n._parse=function(t){var n=t;return y(t)&&(n=e.positions[n]),n},n._updatePosition=function(){var t=this.getPosition();for(var e in t||(t={top:20,left:20}),t)t.hasOwnProperty(e)&&(t[e]=parseInt(t[e]),this.__ctrlContainer.style[e]=t[e]+"px");this.fire("positionchange",{position:d({},t)})},e}(xn(Mn));qo.positions={"top-left":{top:20,left:20},"top-right":{top:20,right:20},"bottom-left":{bottom:20,left:20},"bottom-right":{bottom:20,right:20}},ii.mergeOptions({control:!0}),ii.include({addControl:function(t){return this._containerDOM.getContext||t.addTo(this),this},removeControl:function(t){return t&&t.getMap()===this?(t.remove(),this):this}});var Yo="addlayer removelayer setbaselayer baselayerremove",Jo=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.buildOn=function(){return this._attributionContainer=je("div"),this._attributionContainer.className="maptalks-attribution",this._update(),this._attributionContainer},n.onAdd=function(){this.getMap().on(Yo,this._update,this)},n.onRemove=function(){this.getMap().off(Yo,this._update,this)},n._update=function(){var t=this.getMap();if(t){var e=t._getLayers((function(t){return t.options.attribution})).reverse().map((function(t){return t.options.attribution})),n=this.options.content+(e.length>0?" - "+e.join(", "):"");this._attributionContainer.innerHTML='<span style="padding:0px 4px">'+n+"</span>"}},e}(qo);Jo.mergeOptions({position:{bottom:0,left:0},content:'<a href="http://maptalks.org" target="_blank">maptalks</a>'}),ii.mergeOptions({attribution:!0}),ii.addOnLoadHook((function(){var t=this.options.attribution||this.options.attributionControl;t&&(this.attributionControl=new Jo(t),this.addControl(this.attributionControl))}));var Xo=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.buildOn=function(){var t=this.container=je("div",this.options.containerClass),e=this.panel=je("div","panel"),n=this.button=je("button");return t.appendChild(n),t.appendChild(e),t},n.onAdd=function(){rn(this.button,"mouseover",this._show,this),rn(this.panel,"mouseleave",this._hide,this),rn(this.getMap(),"click",this._hide,this)},n.onRemove=function(){this.panel&&(on(this.button,"mouseover",this._show,this),on(this.panel,"mouseleave",this._hide,this),on(this.getMap(),"click",this._hide,this),Ne(this.panel),Ne(this.button),delete this.panel,delete this.button,delete this.container)},n._show=function(){Je(this.container,"shown")||(Xe(this.container,"shown"),this._createPanel())},n._hide=function(t){this.panel.contains(t.toElement||t.relatedTarget)||$e(this.container,this.options.containerClass)},n._createPanel=function(){this.panel.innerHTML="";var t=je("ul");this.panel.appendChild(t),this._renderLayers(this.getMap(),t)},n._renderLayers=function(t,e){var n=t.getBaseLayer(),r=t.getLayers(),i=r.length;if(n){var o=n.layers||[n],a=je("li","group"),s=je("ul"),u=je("label");u.innerHTML=this.options.baseTitle,a.appendChild(u);for(var c=0,l=o.length;c<l;c++){var h=o[c];this._isExcluded(h)&&(s.appendChild(this._renderLayer(o[c],!0)),a.appendChild(s),e.appendChild(a))}}if(i){var f=je("li","group"),d=je("ul"),p=je("label");p.innerHTML=this.options.overlayTitle,f.appendChild(p);for(var m=0;m<i;m++){var g=r[m];this._isExcluded(g)&&d.appendChild(this._renderLayer(g))}f.appendChild(d),e.appendChild(f)}},n._isExcluded=function(t){var e=t.getId(),n=this.options.excludeLayers;return!(n.length&&n.indexOf(e)>=0)},n._renderLayer=function(t,e){var n=this,r=je("li","layer"),i=je("label"),o=je("input"),a=this.getMap(),s=t.options.visible;t.options.visible=!0;var u=t.isVisible();return t.options.visible=s,r.className="layer",e?(o.type="radio",o.name="base"):o.type="checkbox",o.checked=s&&u,u||o.setAttribute("disabled","disabled"),o.onchange=function(e){if("radio"===e.target.type){var r=a.getBaseLayer(),i=r.layers;if(i)for(var o=0,s=i.length;o<s;o++){var u=i[o];u[u===t?"show":"hide"]()}else r.isVisible()||r.show();a._fireEvent("setbaselayer")}else t[e.target.checked?"show":"hide"]();n.fire("layerchange",{target:t})},r.appendChild(o),i.innerHTML=t.getId(),r.appendChild(i),r},e}(qo);Xo.mergeOptions({position:"top-right",baseTitle:"Base Layers",overlayTitle:"Layers",excludeLayers:[],containerClass:"maptalks-layer-switcher"}),ii.mergeOptions({layerSwitcherControl:!1}),ii.addOnLoadHook((function(){this.options.layerSwitcherControl&&(this.layerSwitcherControl=new Xo(this.options.layerSwitcherControl),this.addControl(this.layerSwitcherControl))}));var $o=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.buildOn=function(){var t=this.options.size;this.options.maximize||(t=[0,0]);var e=je("div"),n=this.mapContainer=je("div");n.style.width=t[0]+"px",n.style.height=t[1]+"px",n.className=this.options.containerClass;var r=this.button=je("div");return r.className=this.options.buttonClass,e.appendChild(n),e.appendChild(r),e},n.onAdd=function(){this.options.maximize&&this._createOverview(),this.getMap().on("resize moving zooming rotate dragrotating viewchange",this._update,this).on("setbaselayer",this._updateBaseLayer,this).on("spatialreferencechange",this._updateSpatialReference,this),rn(this.button,"click",this._onButtonClick,this),this._updateButtonText()},n.onRemove=function(){this.getMap().off("resize moving zooming rotate dragrotating viewchange",this._update,this).off("setbaselayer",this._updateBaseLayer,this).off("spatialreferencechange",this._updateSpatialReference,this),this._overview&&(this._overview.remove(),delete this._overview,delete this._perspective),on(this.button,"click",this._onButtonClick,this)},n.maxmize=function(){var t=this.options.size,e=this.mapContainer;return e.style.width=t[0]+"px",e.style.height=t[1]+"px",this._createOverview(),this},n.minimize=function(){this._overview&&this._overview.remove(),delete this._overview,delete this._perspective;var t=this.mapContainer;return t.style.width="0px",t.style.height="0px",this},n.getOverviewMap=function(){return this._overview},n._onButtonClick=function(){this._overview?this.minimize():this.maxmize(),this._updateButtonText()},n._updateButtonText=function(){this._overview?this.button.innerHTML="-":this.button.innerHTML="+"},n._createOverview=function(){var t=this.getMap(),e=this.mapContainer,n=t.config();d(n,{center:t.getCenter(),zoom:this._getOverviewZoom(),zoomAnimationDuration:150,pitch:0,bearing:0,scrollWheelZoom:!1,checkSize:!1,doubleClickZoom:!1,touchZoom:!1,control:!1,draggable:!1,maxExtent:null}),this._overview=new ii(e,n),this._updateBaseLayer(),this._perspective=new bi(this._getPerspectiveCoords(),{draggable:!0,cursor:"move",symbol:this.options.symbol}).on("dragend",this._onDragEnd,this),new eo("perspective_layer",this._perspective).addTo(this._overview),this.fire("load")},n._getOverviewZoom=function(){var t=this.getMap(),e=t.getZoom(),n=t.getMinZoom(),r=this.options.level;if(r>0){for(var i=r;i>0;i--)if(e-i>=n)return e-i}else for(var o=r;o<0;o++)if(e-o>=n)return e-o;return e},n._onDragEnd=function(){var t=this._perspective.getCenter();this._overview.setCenter(t),this.getMap().panTo(t)},n._getPerspectiveCoords=function(){var t=this.getMap();return t.getContainerExtent().toArray().map((function(e){return t.containerPointToCoordinate(e)}))},n._update=function(){if(this._overview){Ze(this._overview._containerDOM);var t=this._getPerspectiveCoords();this._perspective.setCoordinates(t),this._overview.setCenterAndZoom(this.getMap().getCenter(),this._getOverviewZoom())}},n._updateSpatialReference=function(){if(this._overview){var t=this.getMap().options.spatialReference;this._overview.setSpatialReference(t)}},n._updateBaseLayer=function(){if(this._overview){var t=this.getMap().getBaseLayer();if(t){var e=t.layers,n=0;if(e)for(var r=0,i=e.length;r<i;r++)if(e[r].isVisible()){n=r;break}var o=t.toJSON(),a=null;e?(a=o.layers[n].options).visible=!0:a=o.options,this._overview.setMinZoom(a.minZoom||null).setMaxZoom(a.maxZoom||null),delete a.minZoom,delete a.maxZoom,delete o.options.canvas,o.options.visible=!0,o.options.renderer="canvas";var s=ei.fromJSON(o);for(var u in t)_(t[u])&&t.hasOwnProperty(u)&&t[u]!==t.constructor.prototype[u]&&(s[u]=t[u]);this._overview.setBaseLayer(s)}else this._overview.setBaseLayer(null)}},e}(qo);$o.mergeOptions({level:4,position:{right:1,bottom:1},size:[300,200],maximize:!0,symbol:{lineWidth:3,lineColor:"#1bbc9b",polygonFill:"#1bbc9b",polygonOpacity:.4},containerClass:"maptalks-overview",buttonClass:"maptalks-overview-button"}),ii.mergeOptions({overviewControl:!1}),ii.addOnLoadHook((function(){this.options.overviewControl&&(this.overviewControl=new $o(this.options.overviewControl),this.addControl(this.overviewControl))}));var Qo=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.buildOn=function(){var t;if(this.options.custom)y(this.options.content)?(t=je("div")).innerHTML=this.options.content:t=this.options.content;else{if(t=je("div","maptalks-panel"),this.options.closeButton){var e=je("a","maptalks-close");e.href="javascript:;",e.onclick=function(){t.style.display="none"},t.appendChild(e)}var n=je("div","maptalks-panel-content");n.innerHTML=this.options.content,t.appendChild(n)}return this.draggable=new Ln(t,{cancelOn:this._cancelOn.bind(this),ignoreMouseleave:!0}),this.draggable.on("dragstart",this._onDragStart,this).on("dragging",this._onDragging,this).on("dragend",this._onDragEnd,this),this.options.draggable&&this.draggable.enable(),t},n.update=function(){return this.draggable&&(this.draggable.disable(),delete this.draggable),qo.prototype.update.call(this)},n.setContent=function(t){var e=this.options.content;return this.options.content=t,this.fire("contentchange",{old:e,new:t}),this.isVisible()&&this.update(),this},n.getContent=function(){return this.options.content},n._cancelOn=function(t){var e=(t.srcElement||t.target).tagName.toLowerCase();return"button"===e||"input"===e||"select"===e||"option"===e||"textarea"===e},n._onDragStart=function(t){this._startPos=t.mousePos,this._startPosition=d({},this.getPosition()),this.fire("dragstart",t)},n._onDragging=function(t){var e=t.mousePos.sub(this._startPos),n=this._startPosition,r=this.getPosition();p(r.top)||(r.top=parseInt(n.top)+e.y),p(r.bottom)||(r.bottom=parseInt(n.bottom)-e.y),p(r.left)||(r.left=parseInt(n.left)+e.x),p(r.right)||(r.right=parseInt(n.right)-e.x),this.setPosition(r),this.fire("dragging",t)},n._onDragEnd=function(t){delete this._startPos,delete this._startPosition,this.fire("dragend",t)},n._getConnectPoints=function(){var t=this.getMap(),e=this.getContainerPoint(),n=this.getDOM(),r=parseInt(n.clientWidth),i=parseInt(n.clientHeight);return[t.containerPointToCoordinate(e.add(r/2,0)),t.containerPointToCoordinate(e.add(r,i/2)),t.containerPointToCoordinate(e.add(r/2,i)),t.containerPointToCoordinate(e.add(0,i/2))]},e}(qo);Qo.mergeOptions({position:"top-right",draggable:!0,custom:!1,content:"",closeButton:!0});var Ko=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.buildOn=function(t){return this._map=t,this._scaleContainer=je("div",this.options.containerClass),this._addScales(),t.on("zoomend",this._update,this),this._map._loaded&&this._update(),this._scaleContainer},n.onRemove=function(){this.getMap().off("zoomend",this._update,this)},n._addScales=function(){var t="border: 2px solid #000000;border-top: none;line-height: 1.1;padding: 0px;color: #000000;font-size: 11px;text-align:center;white-space: nowrap;overflow: hidden;-moz-box-sizing: content-box;box-sizing: content-box;background: #fff; background: rgba(255, 255, 255, 0);";this.options.metric&&(this._mScale=ze("div",this.options.containerClass?null:t,this._scaleContainer)),this.options.imperial&&(this._iScale=ze("div",this.options.containerClass?null:t,this._scaleContainer))},n._update=function(){var t=this._map.pixelToDistance(this.options.maxWidth,0);this._updateScales(t)},n._updateScales=function(t){this.options.metric&&t&&this._updateMetric(t),this.options.imperial&&t&&this._updateImperial(t)},n._updateMetric=function(t){var e=this._getRoundNum(t),n=e<1e3?e+" m":e/1e3+" km";this._updateScale(this._mScale,n,e/t)},n._updateImperial=function(t){var e,n,r,i=3.2808399*t;i>5280?(e=i/5280,n=this._getRoundNum(e),this._updateScale(this._iScale,n+" mile",n/e)):(r=this._getRoundNum(i),this._updateScale(this._iScale,r+" feet",r/i))},n._updateScale=function(t,e,n){t.style.width=Math.round(this.options.maxWidth*n)+"px",t.innerHTML=e},n._getRoundNum=function(t){var e=Math.pow(10,(Math.floor(t)+"").length-1),n=t/e;return e*(n=n>=10?10:n>=5?5:n>=3?3:n>=2?2:1)},e}(qo);Ko.mergeOptions({position:"bottom-left",maxWidth:100,metric:!0,imperial:!1,containerClass:null}),ii.mergeOptions({scaleControl:!1}),ii.addOnLoadHook((function(){this.options.scaleControl&&(this.scaleControl=new Ko(this.options.scaleControl),this.addControl(this.scaleControl))}));var ta=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.buildOn=function(t){this._map=t;var e=je("div"),n=je("ul","maptalks-toolbar-hx");e.appendChild(n),this.options.vertical?Xe(e,"maptalks-toolbar-vertical"):Xe(e,"maptalks-toolbar-horizonal");var r=this;function i(t,e,n,i){var o=r._getItems()[e];return function(r){return Ue(r),t({target:o,index:e,childIndex:n,dom:i})}}var o=this.options.items;if(U(o))for(var a=0,s=o.length;a<s;a++){var u=o[a],c=je("li");if(28!==this.options.height&&(c.style.lineHeight=this.options.height+"px"),c.style.height=this.options.height+"px",c.style.cursor="pointer",tn(u.item)){c.style.textAlign="center";var l=en("div",u.item);c.innerHTML='<div style="margin-top:'+(this.options.height-l.height)/2+'px;">'+u.item+"</div>"}else c.innerHTML=u.item;if(u.click&&rn(c,"click",i(u.click,a,null,c)),U(u.children)){var h=this._createDropMenu(a);c.appendChild(h),c._menu=h,rn(c,"mouseover",(function(){this._menu.style.display=""})),rn(c,"mouseout",(function(){this._menu.style.display="none"}))}n.appendChild(c)}return e},n._createDropMenu=function(t){var e=this;function n(t,n,r){var i=e._getItems()[n].children[r];return function(e){return Ue(e),t({target:i,index:n,childIndex:r})}}var r=je("div","maptalks-dropMenu"),i=this._getItems(),o=i.length,a=je("ul"),s=i[t].children;t===o-1&&s&&(r.style.cssText="right: 0px;",a.style.cssText="right: 0px;position: absolute;",this.options.reverseMenu&&(a.style.bottom=0)),r.appendChild(je("em","maptalks-ico"));for(var u=0,c=0,l=s.length;c<l;c++){var h=Me(s[c].item,"12px");h.width>u&&(u=h.width)}for(var f=0,d=s.length;f<d;f++){var p=s[f],m=je("li");m.innerHTML='<a href="javascript:;">'+p.item+"</a>",m.style.cursor="pointer",m.style.width=u+24+"px",rn(m.childNodes[0],"click",n(p.click,t,f)),a.appendChild(m)}if(this.options.vertical){var g=u<95?95:u;this.options.reverseMenu?r.style.right=-(g+20)+"px":r.style.left=-(g+20)+"px"}else this.options.reverseMenu?r.style.bottom="28px":r.style.top="28px";return r.appendChild(a),r.style.display="none",r},n._getItems=function(){return this.options.items||[]},e}(qo);ta.mergeOptions({height:28,vertical:!1,position:"top-right",reverseMenu:!1,items:{}});var ea=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.buildOn=function(t){var e=this.options,n=je("div","maptalks-zoom");if(e.zoomLevel){var r=je("span","maptalks-zoom-zoomlevel");n.appendChild(r),this._levelDOM=r}var i=je("div","maptalks-zoom-slider"),o=je("a","maptalks-zoom-zoomin");if(o.href="javascript:;",o.innerHTML="+",i.appendChild(o),this._zoomInButton=o,e.slider){var a=je("div","maptalks-zoom-slider-box"),s=je("div","maptalks-zoom-slider-ruler"),u=je("span","maptalks-zoom-slider-reading"),c=je("span","maptalks-zoom-slider-dot");s.appendChild(u),a.appendChild(s),a.appendChild(c),i.appendChild(a),this._sliderBox=a,this._sliderRuler=s,this._sliderReading=u,this._sliderDot=c}var l=je("a","maptalks-zoom-zoomout");return l.href="javascript:;",l.innerHTML="-",i.appendChild(l),this._zoomOutButton=l,n.appendChild(i),t.on("_zoomend _zooming _zoomstart _spatialreferencechange",this._update,this),this._update(),this._registerDomEvents(),n},n.onRemove=function(){this.getMap().off("_zoomend _zooming _zoomstart _spatialreferencechange",this._update,this),this._zoomInButton&&on(this._zoomInButton,"click",this._onZoomInClick,this),this._zoomOutButton&&on(this._zoomOutButton,"click",this._onZoomOutClick,this),this._sliderRuler&&(on(this._sliderRuler,"click",this._onClickRuler,this),this.dotDragger.disable(),delete this.dotDragger)},n._update=function(){var t=this.getMap();if(this._sliderBox){var e=10*(t.getMaxZoom()-t.getMinZoom());this._sliderBox.style.height=e+16+"px",this._sliderRuler.style.height=e+8+"px",this._sliderRuler.style.cursor="pointer";var n=10*(t.getMaxZoom()-t.getZoom());this._sliderReading.style.height=10*(t.getZoom()-t.getMinZoom()+1)+"px",this._sliderDot.style.top=n+"px"}this._updateText()},n._updateText=function(){if(this._levelDOM){var t=this.getMap().getZoom();g(t)||(t=Math.floor(10*t)/10),this._levelDOM.innerHTML=t}},n._registerDomEvents=function(){this._zoomInButton&&rn(this._zoomInButton,"click",this._onZoomInClick,this),this._zoomOutButton&&rn(this._zoomOutButton,"click",this._onZoomOutClick,this),this._sliderRuler&&(rn(this._sliderRuler,"click",this._onClickRuler,this),this.dotDragger=new Ln(this._sliderDot,{ignoreMouseleave:!0}),this.dotDragger.on("dragstart",this._onDotDragstart,this).on("dragging dragend",this._onDotDrag,this).enable())},n._onZoomInClick=function(t){Ge(t),this.getMap().zoomIn()},n._onZoomOutClick=function(t){Ge(t),this.getMap().zoomOut()},n._onClickRuler=function(t){Ge(t);var e=this.getMap(),n=qe(t,this._sliderRuler).y,r=e.getMaxZoom(),i=Math.floor(r-n/10);e.setZoom(i)},n._onDotDragstart=function(t){Ge(t.domEvent);var e=this.getMap(),n=e.getSize().toPoint()._multi(.5);e.onZoomStart(e.getZoom(),n)},n._onDotDrag=function(t){Ge(t.domEvent);var e=this.getMap(),n=e.getSize().toPoint()._multi(.5),r=qe(t.domEvent,this._sliderRuler),i=e.getMaxZoom(),o=e.getMinZoom(),a=r.y,s=i-a/10;i<s?(s=i,a=0):o>s&&(s=o,a=10*(i-o)),"dragging"===t.type?e.onZooming(s,n,1):"dragend"===t.type&&(this.options.seamless?e.onZoomEnd(s,n):e.onZoomEnd(Math.round(s),n)),this._sliderDot.style.top=a+"px",this._sliderReading.style.height=10*(e.getZoom()-o+1)+"px",this._updateText()},e}(qo);ea.mergeOptions({position:"top-left",slider:!0,zoomLevel:!0,seamless:!1}),ii.mergeOptions({zoomControl:!1}),ii.addOnLoadHook((function(){this.options.zoomControl&&(this.zoomControl=new ea(this.options.zoomControl),this.addControl(this.zoomControl))}));var na=Object.freeze({Control:qo,Attribution:Jo,LayerSwitcher:Xo,Overview:$o,Panel:Qo,Scale:Ko,Toolbar:ta,Zoom:ea}),ra=function(){function t(t,e,n,r){Array.isArray(t)?(this.scale={x:t[0],y:t[1]},this.origin={x:t[2],y:t[3]}):(this.scale={x:t,y:e},this.origin={x:n,y:r})}return t.getDefault=function(t){return"baidu"===t.code.toLowerCase()?"baidu":t.code.toLowerCase()==="EPSG:4326".toLowerCase()?"tms-global-geodetic":"identity"===t.code.toLowerCase()?[1,-1,0,0]:"web-mercator"},t}(),ia=6378137*Math.PI;d(ra,{"web-mercator":new ra([1,-1,-ia,ia]),"tms-global-mercator":new ra([1,1,-ia,-ia]),"tms-global-geodetic":new ra([1,1,-180,-90]),baidu:new ra([1,1,0,0])});for(var oa=function(){function t(t,e,n,r){this.map=t,this.tileSize=r,this.fullExtent=n,this.prepareTileInfo(e,n),this._xScale=n.right>=n.left?1:-1,this._yScale=n.top>=n.bottom?1:-1,this._pointOrigin=t._prjToPoint(new me(this.tileSystem.origin),t.getGLZoom()),this._glRes=t.getResolution(t.getGLZoom())}var e=t.prototype;return e.prepareTileInfo=function(t,e){if(y(t)?t=ra[t.toLowerCase()]:Array.isArray(t)&&(t=new ra(t)),!t)throw new Error("Invalid TileSystem");this.tileSystem=t;var n=e.right>e.left?1:-1,r=e.top>e.bottom?-1:1,i=t.origin.x,o=t.origin.y;this.transformation=new qn([n,r,i,o])},e._getTileNum=function(t,e){var n=this.tileSystem,r=this.tileSize,i=Math.floor(1e-7*n.scale.x+t.x/(r.width*e)),o=Math.ceil(1e-7*n.scale.y+t.y/(r.height*e));return{x:n.scale.x*i,y:n.scale.y*o}},e.getTileIndex=function(t,e,n){var r=this.tileSystem,i=this.transformation.transform(t,1),o=this._getTileNum(i,e);return r.scale.x<0&&(o.x-=1),r.scale.y>0&&(o.y-=1),this.getNeighorTileIndex(o.x,o.y,0,0,e,n)},e.getNeighorTileIndex=function(t,e,n,r,i,o){var a=this.tileSystem,s=t+a.scale.x*n,u=e-a.scale.y*r,c=!1,l=s,h=u,f=this._getTileFullIndex(i);return o&&(!0!==o&&"x"!==o||(f.xmax===f.xmin?s=f.xmin:s<f.xmin?(s=f.xmax-(f.xmin-s)%(f.xmax-f.xmin))===f.xmax&&(s=f.xmin):s>=f.xmax&&(s=f.xmin+(s-f.xmin)%(f.xmax-f.xmin))),!0!==o&&"y"!==o||(f.ymax===f.ymin?u=f.ymin:u>=f.ymax?u=f.ymin+(u-f.ymin)%(f.ymax-f.ymin):u<f.ymin&&(u=f.ymax-(f.ymin-u)%(f.ymax-f.ymin))===f.ymax&&(u=f.ymin))),(s<f.xmin||s>f.xmax||u>f.ymax||u<f.ymin)&&(c=!0),{x:s,y:u,idx:l,idy:h,out:c}},e._getTileFullIndex=function(t){if(this._tileFullIndex||(this._tileFullIndex={}),this._tileFullIndex[t])return this._tileFullIndex[t];var e=this.fullExtent,n=this.transformation,r=this._getTileNum(n.transform(new On(e.left,e.top),1),t),i=this._getTileNum(n.transform(new On(e.right,e.bottom),1),t),o=this.tileSystem;return o.scale.x<0&&(r.x-=1,i.x-=1),o.scale.y>0&&(r.y-=1,i.y-=1),this._tileFullIndex[t]=new Vn(r,i),this._tileFullIndex[t]},e.getTilePrjNW=function(t,e,n){var r=this.tileSystem,i=this.tileSize,o=r.origin.y+this._yScale*r.scale.y*(e+(1===r.scale.y?1:0))*n*i.height,a=r.origin.x+this._xScale*r.scale.x*(t+(1===r.scale.x?0:1))*n*i.width;return new On(a,o)},e.getTilePointNW=function(t,e,n){var r=this._glRes/n,i=this.tileSystem,o=this.tileSize,a=this._pointOrigin.y*r+this._yScale*i.scale.y*(e+(1===i.scale.y?1:0))*o.height,s=this._pointOrigin.x*r+this._xScale*i.scale.x*(t+(1===i.scale.x?0:1))*o.width;return new me(s,a)},e.getTilePrjSE=function(t,e,n){var r=this.tileSystem,i=this.tileSize,o=r.origin.y+this._yScale*r.scale.y*(e+(1===r.scale.y?0:1))*n*i.height,a=r.origin.x+this._xScale*r.scale.x*(t+(1===r.scale.x?1:0))*n*i.width;return new On(a,o)},e.getTilePointSE=function(t,e,n){var r=this._glRes/n,i=this.tileSystem,o=this.tileSize,a=this._pointOrigin.y*r+this._yScale*i.scale.y*(e+(1===i.scale.y?0:1))*o.height,s=this._pointOrigin.x*r+this._xScale*i.scale.x*(t+(1===i.scale.x?1:0))*o.width;return new me(s,a)},e.getTilePrjExtent=function(t,e,n){var r=this.getTilePrjNW(t,e,n),i=this.getTilePrjSE(t,e,n);return new Vn(r,i)},t}(),aa=[],sa=0;sa<6;sa++)aa[sa]=[];var ua=[];function ca(t,e,n){!function(t){var e=t,n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],c=e[7],l=e[8],h=e[9],f=e[10],d=e[11],p=e[12],m=e[13],g=e[14],v=e[15];la(aa[0],o-n,c-a,d-l,v-p),la(aa[1],o+n,c+a,d+l,v+p),la(aa[2],o+r,c+s,d+h,v+m),la(aa[3],o-r,c-s,d-h,v-m),la(aa[4],o-i,c-u,d-f,v-g),la(aa[5],o+i,c+u,d+f,v+g)}(t);for(var r=0;r<6;r++)if(!n||"0"!==n.charAt(r)){var i=aa[r];if(ua[0]=i[0]>0?e[1][0]:e[0][0],ua[1]=i[1]>0?e[1][1]:e[0][1],ua[2]=i[2]>0?e[1][2]:e[0][2],ha(i,ua)<0)return!1}return!0}function la(t,e,n,r,i){return t[0]=e*(1/6),t[1]=n*(1/6),t[2]=r*(1/6),t[3]=i*(1/6),t}function ha(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]+t[3]}var fa="undefined"!=typeof Set,da=function(){function t(){this._table=fa?new Set:{}}var e=t.prototype;return e.add=function(t){fa?this._table.add(t):this._table[t]=!0},e.has=function(t){return fa?this._table.has(t):this._table[t]},e.reset=function(){fa?this._table.clear():this._table={}},t}(),pa={urlTemplate:null,subdomains:null,errorUrl:null,repeatWorld:!0,background:!0,backgroundZoomDiff:6,loadingLimitOnInteracting:3,tileRetryCount:0,placeholder:!1,crossOrigin:null,tileSize:[256,256],offset:[0,0],tileSystem:null,fadeAnimation:!A,debug:!1,spatialReference:null,maxCacheSize:256,renderer:he.webgl?"gl":"canvas",clipByPitch:!0,maxAvailableZoom:null,cascadeTiles:!0,zoomOffset:0},ma=/\{ *([\w_]+) *\}/g,ga=new me(0,0),va=new me(0,0),ya=new me(0,0),_a=new me(0,0),xa=new me(0,0),ba=new me(0,0),wa=new me(0,0),Ma=[[0,0,0],[0,0,0]],Sa=[],Ta=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t),e.fromJSON=function(t){return t&&"TileLayer"===t.type?new e(t.id,t.options):null};var n=e.prototype;return n.getTileSize=function(){if(this._tileSize)return this._tileSize;var t=this.options.tileSize;return m(t)&&(t=[t,t]),this._tileSize=new ge(t),this._tileSize},n.getTiles=function(t,e){var n=this.getMap(),r=n.getPitch(),i=e&&e.getRenderer(),o=n.getContainerExtent(),a=[],s=0,u=this.getMinZoom(),c=n.options.cascadePitches[0],l=n.options.cascadePitches[1],h=Math.floor(n._getVisualHeight(l)),f=p(t)?this._getTileZoom(n.getZoom()):t;if(this._visitedTiles=new da,this._coordCache={},!p(t)||!this.options.cascadeTiles||r<=c||!p(u)&&f<=u){var d=r<=l?o:new Zn(0,n.height-h,n.width,n.height),m=this._getTiles(f,d,2,i);return m&&(s+=m.tiles.length,a.push(m)),{tileGrids:a,count:s}}var g=Math.floor(n._getVisualHeight(c)),v=new Zn(0,n.height-g,n.width,n.height),y=this._getTiles(f,v,0,i);s+=y?y.tiles.length:0,a.push(y);var _,x,b=v.ymin,w=n.getSpatialReference().getZoomDirection(),M=w;if(r>l){f-M<=u&&(M=0);var S=new Zn(0,n.height-h,n.width,b);s+=(_=this._getTiles(f-M,S,1,i))?_.tiles.length:0,b=S.ymin,M+=4*w}if(f-M>=u){var T=new Zn(0,o.ymin,n.width,b);s+=(x=this._getTiles(f-M,T,2,i))?x.tiles.length:0,a.push(x)}return _&&x&&(a[1]=x,a[2]=_),{tileGrids:a,count:s}},n.getTileUrl=function(t,e,n){var r=this.options.urlTemplate,i="";if(this.options.subdomains){var o=this.options.subdomains;if(U(o)){var a=(t+e)%o.length;a<0&&(a=0),i=o[a]}}if(_(r))return r(t,e,n,i);var s={x:t,y:e,z:n,s:i};return r.replace(ma,(function(t,e){var n=s[e];if(void 0===n)throw new Error("No value provided for variable "+t);return"function"==typeof n&&(n=n(s)),n}))},n.clear=function(){return this._renderer&&this._renderer.clear(),this.fire("clear"),this},n.toJSON=function(){return{type:this.getJSONType(),id:this.getId(),options:this.config()}},n.getSpatialReference=function(){var t=this.getMap();return!t||this.options.spatialReference&&!Qr.equals(this.options.spatialReference,t.options.spatialReference)?(this._sr=this._sr||new Qr(this.options.spatialReference),void 0===this._srMinZoom&&(this._srMinZoom=this._sr.getMinZoom(),this._srMaxZoom=this._sr.getMaxZoom()),this._sr):t.getSpatialReference()},n.getMinZoom=function(){return this.getSpatialReference()!==this.getMap().getSpatialReference()?Math.max(t.prototype.getMinZoom.call(this),this._srMinZoom):t.prototype.getMinZoom.call(this)},n.getMaxZoom=function(){return this.getSpatialReference()!==this.getMap().getSpatialReference()?Math.min(t.prototype.getMaxZoom.call(this),this._srMaxZoom):t.prototype.getMaxZoom.call(this)},n._getTileZoom=function(t){g(t)||(t=Math.round(t));var e=this.options.maxAvailableZoom;return!p(e)&&t>e&&(t=e),t},n._getTiles=function(t,e,n,r){var i=this,o=this.getMap(),a=t,s=o.projViewMatrix;n<2&&(0===n&&(a-=1),s=0===n?o.cascadeFrustumMatrix0:1===n?o.cascadeFrustumMatrix1:o.projViewMatrix);var u=a+this.options.zoomOffset,c=this._getTileOffset(u),l=c[0]||c[1],h={zoom:a,extent:null,offset:c,tiles:[]};if(u<0)return h;var f=this.getMinZoom(),d=this.getMaxZoom();if(!(o&&this.isVisible()&&o.width&&o.height))return h;if(!p(f)&&a<f||!p(d)&&a>d)return h;var m=this._getTileConfig();if(!m)return h;var g={zoom:c},v=this.getSpatialReference(),y=o.getSpatialReference(),_=v.getResolution(u),x=o.getGLScale(a),b=v===y&&this.options.repeatWorld,w=e.convertTo((function(t){if(t.y>0&&t.y<o.height){var e=(0===t.x?0:1)+t.y;i._coordCache[e]||(i._coordCache[e]=o._containerPointToPoint(t)),i._coordCache[e]}return o._containerPointToPoint(t,void 0,ga)})),M=this._getMask2DExtent();if(M){var S=M.intersection(w);if(!S)return h;e=S.convertTo((function(t){return o._pointToContainerPoint(t,void 0,0,ga)}))}var T,E=o._containerPointToPrj(e.getCenter(),va),A=o._prjToPoint(E,u,ya);T=l?this._project(o._pointToPrj(A._add(c),u,ya),ya):this._project(E,ya);var C=o.getGLScale()/o.getGLScale(u);_a.x=w.xmin*C,_a.y=w.ymax*C,xa.x=w.xmax*C,xa.y=w.ymin*C;for(var P=this._project(o._pointToPrj(_a._add(c),u,_a),_a),L=this._project(o._pointToPrj(xa._add(c),u,xa),xa),O=m.getTileIndex(T,_,b),R=m.getTileIndex(P,_,b),k=m.getTileIndex(L,_,b),I=Math.ceil(Math.abs(O.idy-R.idy)),D=Math.ceil(Math.abs(O.idx-R.idx)),j=Math.ceil(Math.abs(O.idy-k.idy)),z=Math.ceil(Math.abs(O.idx-k.idx)),N=(I+j+1)*(D+z+1),F=this.getTileSize(),B=this.getRenderer()||r,H=this._getTileConfig().tileSystem.scale,G=[],U=new Zn,W=new me(0,0),V=-I;V<=j;V++)for(var Z=-D,q=-1/0,Y=!1;Z>=q&&Z<=z;){var J=m.getNeighorTileIndex(O.idx,O.idy,Z,V,_,b);q===-1/0?Z++:Z--;var X=this._getTileId(J.idx,J.idy,a);if(!(J.out||this._visitedTiles&&this._visitedTiles.has(X))){var $=B&&B.isTileCachedOrLoading(X);$&&($=$.info);var Q=void 0;if($){var K=$.extent2d;W.set(K.xmin,K.ymax),Q=W}else if(this._hasOwnSR){var tt=m.getTilePrjNW(J.x,J.y,_);Q=o._prjToPoint(this._unproject(tt,xa),a)}else Q=m.getTilePointNW(J.x,J.y,_);var et=void 0,nt=void 0;if(v===y)et=F.width,nt=F.height;else{var rt=void 0;if(this._hasOwnSR){var it=m.getTilePrjSE(J.x,J.y,_);rt=o._prjToPoint(this._unproject(it,xa),a,xa)}else rt=m.getTilePointSE(J.x,J.y,_);et=Math.ceil(Math.abs(rt.x-Q.x)),nt=Math.ceil(Math.abs(rt.y-Q.y))}var ot=H.x*(J.idx-J.x)*et,at=H.y*(J.idy-J.y)*nt;$||!ot&&!at||Q._add(ot,at);var st=$&&$.extent2d||new Zn(Q.x,Q.y-nt,Q.x+et,Q.y);(N<=4||Y||this._isTileInExtent(s,st,c,x))&&(this._visitedTiles&&0===n&&this._visitedTiles.add(X),0===n?(this._splitTiles(s,G,B,J,a+1,st,ot,at,g,r),U._combine(st)):($?($.offset[0]=c[0],$.offset[1]=c[1]):($={z:a,x:J.x,y:J.y,extent2d:st,offset:c,id:X,url:this.getTileUrl(J.x,J.y,a)},r&&($.layer=this.getId())),G.push($),U._combine(st)),q===-1/0?(q=Z,Z=z):Y||(Y=!0))}}if(G.length){var ut=o._containerPointToPoint(e.getCenter(),a,ga)._add(c),ct=new me(0,0),lt=new me(0,0);G.sort((function(t,e){return ct.set((t.extent2d.xmin+t.extent2d.xmax)/2,(t.extent2d.ymin+t.extent2d.ymax)/2),lt.set((e.extent2d.xmin+e.extent2d.xmax)/2,(e.extent2d.ymin+e.extent2d.ymax)/2),ct.distanceTo(ut)-lt.distanceTo(ut)}))}return{offset:c,zoom:t,extent:U,tiles:G}},n._splitTiles=function(t,e,n,r,i,o,a,s,u,c){var l=this._getTileConfig().tileSystem.scale.y,h=this.getMap().getGLScale(i),f=ba.set(2*o.xmin,l<0?2*o.ymax:2*o.ymin),d=o.getWidth(),p=o.getHeight(),m=2*r.idx,g=2*r.idy,v=2*r.x,y=2*r.y,_=this._checkAndAddTile(t,n,m,g,v,y,i,0,0,d,p,f,h,u,c);_&&e.push(_),(_=this._checkAndAddTile(t,n,m,g,v,y,i,0,1,d,p,f,h,u,c))&&e.push(_),(_=this._checkAndAddTile(t,n,m,g,v,y,i,1,0,d,p,f,h,u,c))&&e.push(_),(_=this._checkAndAddTile(t,n,m,g,v,y,i,1,1,d,p,f,h,u,c))&&e.push(_)},n._checkAndAddTile=function(t,e,n,r,i,o,a,s,u,c,l,h,f,d,p){var m=this._getTileId(n+s,r+u,a);if(this._visitedTiles&&this._visitedTiles.has(m))return null;var g=d[a];g||(g=d[a]=this._getTileOffset(a));var v=this._getTileConfig().tileSystem.scale.y,y=new Zn(h.x+s*c,h.y+v*u*l,h.x+(s+1)*c,h.y+v*(u+1)*l);if(!this._isSplittedTileInExtent(t,y,g,f))return null;var _=e&&e.isTileCachedOrLoading(m);return _?_=_.info:(_={z:a,x:i+s,y:o+u,extent2d:y,id:m,offset:g,url:this.getTileUrl(i+s,o+u,a+this.options.zoomOffset)},p&&(_.layer=this.getId())),_},n._getTileOffset=function(t){var e=this.options.offset;return _(e)&&(e=e(t)),e},n._getTileId=function(t,e,n,r){return(r||this.getId())+"_"+e+"_"+t+"_"+n},n._project=function(t,e){if(this._hasOwnSR){var n=this.getMap().getProjection();return this.getSpatialReference().getProjection().project(n.unproject(t,e),e)}return t},n._unproject=function(t,e){if(this._hasOwnSR){var n=this.getMap(),r=this.getSpatialReference(),i=n.getProjection(),o=r.getProjection();return i.project(o.unproject(t,e),e)}return t},n._initTileConfig=function(){var t=this.getMap(),e=this.getTileSize(),n=this.getSpatialReference(),r=n.getProjection(),i=n.getFullExtent();this._defaultTileConfig=new oa(t,ra.getDefault(r),i,e),this.options.tileSystem&&(this._tileConfig=new oa(t,this.options.tileSystem,i,e)),this._hasOwnSR=n!==t.getSpatialReference()},n._getTileConfig=function(){return this._defaultTileConfig||this._initTileConfig(),this._tileConfig||this._defaultTileConfig},n._bindMap=function(e){var n=e.getBaseLayer();return n===this&&(n.options.hasOwnProperty("forceRenderOnMoving")||this.config({forceRenderOnMoving:!0})),t.prototype._bindMap.apply(this,arguments)},n._isTileInExtent=function(t,e,n,r){var i,o=this.getMap();if(t!==o.projViewMatrix){var a=e.getCenter(wa)._sub(n[0],n[1])._multi(r);vo(Sa,a.x,a.y,0),i=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[3]*r+n[7]*i+n[11]*o+n[15];return a=a||1,t[0]=(n[0]*r+n[4]*i+n[8]*o+n[12])/a,t[1]=(n[1]*r+n[5]*i+n[9]*o+n[13])/a,t[2]=(n[2]*r+n[6]*i+n[10]*o+n[14])/a,t}(Sa,Sa,o.projViewMatrix)[1]<0?o.projViewMatrix:t}else i=o.projViewMatrix;return Ma[0][0]=(e.xmin-n[0])*r,Ma[0][1]=(e.ymin-n[1])*r,Ma[1][0]=(e.xmax-n[0])*r,Ma[1][1]=(e.ymax-n[1])*r,ca(i,Ma)},n._isSplittedTileInExtent=function(t,e,n,r){var i=this.getMap();return Ma[0][0]=(e.xmin-n[0])*r,Ma[0][1]=(e.ymin-n[1])*r,Ma[1][0]=(e.xmax-n[0])*r,Ma[1][1]=(e.ymax-n[1])*r,ca(i.projViewMatrix,Ma)},n.getEvents=function(){return{spatialreferencechange:this._onSpatialReferenceChange}},n._onSpatialReferenceChange=function(){delete this._tileConfig,delete this._defaultTileConfig,delete this._sr;var t=this.getRenderer();t&&t.clear()},e}(ei);Ta.registerJSONType("TileLayer"),Ta.mergeOptions(pa);var Ea=function(t){function e(e,n,r){var i;return(i=t.call(this,e,r)||this).layers=n||[],i._checkChildren(),i.layerMap={},i._groupChildren=[],i}fe(e,t),e.fromJSON=function(t){if(!t||"GroupTileLayer"!==t.type)return null;var n=t.layers.map((function(t){return ei.fromJSON(t)}));return new e(t.id,n,t.options)};var n=e.prototype;return n.getLayers=function(){return this.layers},n.toJSON=function(){return{type:this.getJSONType(),id:this.getId(),layers:this.layers.map((function(t){return t.toJSON()})),options:this.config()}},n.getTiles=function(t){for(var e=this.layers,n=[],r=0,i=0,o=e.length;i<o;i++){var a=e[i];if(a.options.visible){var s=a.getTiles(t,this);s&&0!==s.count&&(r+=s.count,I(n,s.tileGrids))}}return{count:r,tileGrids:n}},n.onAdd=function(){var e=this,n=this.getMap();this.layers.forEach((function(t){e.layerMap[t.getId()]=t,t.getChildLayer&&e._groupChildren.push(t),t._bindMap(n),t.on("show hide",e._onLayerShowHide,e)})),t.prototype.onAdd.call(this)},n.onRemove=function(){var e=this;this.layers.forEach((function(t){t._doRemove(),t.off("show hide",e._onLayerShowHide,e)})),this.layerMap={},this._groupChildren=[],t.prototype.onRemove.call(this)},n.getChildLayer=function(t){var e=this.layerMap[t];if(e)return e;for(var n=0;n<this._groupChildren.length;n++){var r=this._groupChildren[n].getChildLayer(t);if(r)return r}return null},n._onLayerShowHide=function(){var t=this.getRenderer();t&&t.setToRedraw()},n.isVisible=function(){if(!t.prototype.isVisible.call(this))return!1;for(var e=this.layers,n=0,r=e.length;n<r;n++)if(e[n].isVisible())return!0;return!1},n._checkChildren=function(){var t=this,e={};this.layers.forEach((function(n){var r=n.getId();if(e[r])throw new Error("Duplicate child layer id ("+r+") in the GroupTileLayer ("+t.getId()+")");e[r]=1}))},e}(Ta);Ea.registerJSONType("GroupTileLayer");var Aa={crs:null,uppercase:!1,detectRetina:!1},Ca={service:"WMS",request:"GetMap",layers:"",styles:"",format:"image/jpeg",transparent:!1,version:"1.1.1"},Pa=function(t){function e(e,n){var r;r=t.call(this,e)||this;var i=d({},Ca);for(var o in n)o in r.options||(i[o]=n[o]);r.setOptions(n),r.setZIndex(n.zIndex);var a=r.getTileSize();return i.width=a.width,i.height=a.height,r.wmsParams=i,r._wmsVersion=parseFloat(i.version),r}fe(e,t);var n=e.prototype;return n.onAdd=function(){var e=this.getMap().getDevicePixelRatio(),n=Aa.detectRetina?e:1;this.wmsParams.width*=n,this.wmsParams.height*=n;var r=this.options.crs||this.getMap().getProjection().code,i=this._wmsVersion>=1.3?"crs":"srs";this.wmsParams[i]=r,t.prototype.onAdd.call(this)},n.getTileUrl=function(e,n,r){var i=this.getSpatialReference().getResolution(r),o=this._getTileConfig().getTilePrjExtent(e,n,i),a=o.getMax(),s=o.getMin(),u=(this._wmsVersion>=1.3&&"EPSG:4326"===this.wmsParams.crs?[s.y,s.x,a.y,a.x]:[s.x,s.y,a.x,a.y]).join(","),c=t.prototype.getTileUrl.call(this,e,n,r);return c+function(t,e,n){var r=[];for(var i in t)r.push(encodeURIComponent(n?i.toUpperCase():i)+"="+encodeURIComponent(t[i]));return(e&&-1!==e.indexOf("?")?"&":"?")+r.join("&")}(this.wmsParams,c,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+u},n.toJSON=function(){return{type:"WMSTileLayer",id:this.getId(),options:this.config()}},e.fromJSON=function(t){return t&&"WMSTileLayer"===t.type?new e(t.id,t.options):null},e}(Ta);Pa.registerJSONType("WMSTileLayer"),Pa.mergeOptions(Aa);var La=function(t){function e(e,n){var r;return(r=t.call(this,e,n)||this).options.hasOwnProperty("forceRenderOnMoving")||(r.options.forceRenderOnMoving=!1),r}fe(e,t);var n=e.prototype;return n.drawTile=function(){},n.toJSON=function(){return{type:"CanvasTileLayer",id:this.getId(),options:this.config()}},e.fromJSON=function(t){return t&&"CanvasTileLayer"===t.type?new e(t.id,t.options):null},e}(Ta);function Oa(t,e,n){var r=t.createShader(e);if(t.shaderSource(r,n),t.compileShader(r),!t.getShaderParameter(r,t.COMPILE_STATUS)){var i=t.getShaderInfoLog(r);throw t.deleteShader(r),new Error("Failed to compile shader: "+i)}return r}La.registerJSONType("CanvasTileLayer");var Ra="\n attribute vec2 a_position;\n\n attribute vec2 a_texCoord;\n\n uniform mat4 u_matrix;\n\n varying vec2 v_texCoord;\n\n void main() {\n gl_Position = u_matrix * vec4(a_position, 0., 1.);\n\n v_texCoord = a_texCoord;\n }\n ",ka="\n precision mediump float;\n\n uniform sampler2D u_image;\n\n uniform float u_opacity;\n uniform float u_debug_line;\n\n varying vec2 v_texCoord;\n\n void main() {\n if (u_debug_line == 1.) {\n gl_FragColor = vec4(0., 1., 0., 1.);\n } else {\n gl_FragColor = texture2D(u_image, v_texCoord) * u_opacity;\n }\n }\n ",Ia=[0,0],Da=[0,0,0],ja=new Array(16),za=new me(20,20),Na=function(t){var e=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.drawGLImage=function(t,e,n,r,i,o,a,s){this.gl.program!==this.program&&this.useProgram(this.program);var u=this.gl;this.loadTexture(t),Da[0]=e||0,Da[1]=n||0;var c=mo(ja);lo(c,c,Da),ho(c,c,[o,o,1]),fo(c,this.getMap().projViewMatrix,c),u.uniformMatrix4fv(this.program.u_matrix,!1,c),u.uniform1f(this.program.u_opacity,a),u.uniform1f(this.program.u_debug_line,0);var l=t.glBuffer;!l||l.width===r&&l.height===i||(this.saveImageBuffer(l),delete t.glBuffer),t.glBuffer?u.bindBuffer(u.ARRAY_BUFFER,l):t.glBuffer=this.bufferTileData(0,0,r,i),Ia[0]="a_position",Ia[1]=2,Ia[2]=t.glBuffer.type,this.enableVertexAttrib(Ia),u.drawArrays(u.TRIANGLE_STRIP,0,4),s&&this.drawDebug(c,Ia,0,0,r,i,s)},n.drawDebug=function(t,e,n,r,i,o,a){var s=this.gl;s.bindBuffer(s.ARRAY_BUFFER,this._debugBuffer),this.enableVertexAttrib(["a_position",2,"FLOAT"]),s.bufferData(s.ARRAY_BUFFER,new Float32Array([n,r,n+i,r,n+i,r-o,n,r-o,n,r]),s.DYNAMIC_DRAW),s.uniformMatrix4fv(this.program.u_matrix,!1,t),s.uniform1f(this.program.u_debug_line,1),s.drawArrays(s.LINE_STRIP,0,5);var u=this._debugInfoCanvas;if(!u){var c=this.getMap().getDevicePixelRatio()>1?2:1;(u=this._debugInfoCanvas=document.createElement("canvas")).width=256*c,u.height=32*c;var l=u.getContext("2d");l.font="20px monospace",l.scale(c,c)}var h=u.getContext("2d");h.clearRect(0,0,u.width,u.height);var f=this.layer.options.debugOutline;hn.fillText(h,a,za,f),this.loadTexture(u),s.texImage2D(s.TEXTURE_2D,0,s.RGBA,s.RGBA,s.UNSIGNED_BYTE,u);var d=n,p=n+(i=256),m=r,g=r-(o=32);s.bufferData(s.ARRAY_BUFFER,this.set8(d,m,d,g,p,m,p,g),s.DYNAMIC_DRAW),s.uniform1f(this.program.u_debug_line,0),s.drawArrays(s.TRIANGLE_STRIP,0,4)},n.bufferTileData=function(t,e,n,r,i){var o,a=t,s=t+n,u=e,c=e-r;o=g(a)&&g(s)&&g(u)&&g(c)?this.set8Int(a,u,a,c,s,u,s,c):this.set8(a,u,a,c,s,u,s,c);var l=this.loadImageBuffer(o,i);return l.width=n,l.height=r,l.type=o instanceof Int16Array?"SHORT":"FLOAT",l},n.drawTinImage=function(t,e,n,r,i){var o=this.gl;this.loadTexture(t),o.uniformMatrix4fv(this.program.u_matrix,!1,this.getMap().projViewMatrix),o.uniform1f(this.program.u_opacity,i),o.bindBuffer(o.ARRAY_BUFFER,this.posBuffer),this.enableVertexAttrib(["a_position",3]),o.bufferData(o.ARRAY_BUFFER,new Float32Array(e),o.DYNAMIC_DRAW),o.bindBuffer(o.ARRAY_BUFFER,this.texBuffer),this.enableVertexAttrib(["a_texCoord",2]),o.bufferData(o.ARRAY_BUFFER,new Float32Array(n),o.DYNAMIC_DRAW),o.bufferData(o.ELEMENT_ARRAY_BUFFER,new Uint16Array(r),o.DYNAMIC_DRAW),o.drawElements(o.TRIANGLES,r.length,o.UNSIGNED_SHORT,0)},n.createCanvas2=function(){this.canvas2=hn.createCanvas(this.canvas.width,this.canvas.height)},n.createGLContext=function(){this.canvas.gl&&this.canvas.gl.wrap?this.gl=this.canvas.gl.wrap():this.gl=function(t,e){for(var n={alpha:!0,stencil:!0,preserveDrawingBuffer:!0,antialias:!1},r=["webgl","experimental-webgl"],i=null,o=0;o<r.length;++o){try{i=t.getContext(r[o],e||n)}catch(t){}if(i)break}return i}(this.canvas2||this.canvas,this.layer.options.glOptions);var t=this.gl;t.clearColor(0,0,0,0),t.disable(t.DEPTH_TEST),t.enable(t.STENCIL_TEST),t.enable(t.BLEND),t.blendFunc(t.ONE,t.ONE_MINUS_SRC_ALPHA),this.program=this.createProgram(Ra,this.layer.options.fragmentShader||ka,["u_matrix","u_image","u_opacity","u_debug_line"]),this._debugBuffer=this.createBuffer(),this.useProgram(this.program),this.texBuffer=this.createBuffer(),t.bindBuffer(t.ARRAY_BUFFER,this.texBuffer),this.enableVertexAttrib(["a_texCoord",2,"UNSIGNED_BYTE"]),t.bufferData(t.ARRAY_BUFFER,new Uint8Array([0,0,0,1,1,0,1,1]),t.STATIC_DRAW),this.enableSampler("u_image"),t.activeTexture(t.TEXTURE0),t.pixelStorei(t.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0)},n.resizeGLCanvas=function(){this.gl&&this.gl.viewport(0,0,this.canvas.width,this.canvas.height),this.canvas2&&(this.canvas2.width===this.canvas.width&&this.canvas2.height===this.canvas.height||(this.canvas2.width=this.canvas.width,this.canvas2.height=this.canvas.height))},n.clearGLCanvas=function(){this.gl&&this.gl.clear(this.gl.COLOR_BUFFER_BIT|this.gl.STENCIL_BUFFER_BIT)},n.disposeImage=function(t){t&&(t.texture&&this.saveTexture(t.texture),t.glBuffer&&this.saveImageBuffer(t.glBuffer),delete t.texture,delete t.glBuffer)},n._createTexture=function(t){var e=this.gl,n=this.getTexture()||e.createTexture();return e.bindTexture(e.TEXTURE_2D,n),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE),e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,e.UNSIGNED_BYTE,t),g(F(t.width))&&g(F(t.width))&&e.generateMipmap(e.TEXTURE_2D),n},n.getTexture=function(){this._textures||(this._textures=[]);var t=this._textures;return t&&t.length>0?t.pop():null},n.saveTexture=function(t){this._textures.push(t)},n.loadTexture=function(t){var e=this.gl,n=t.texture;return n||(n=this._createTexture(t),t.texture=n),e.bindTexture(e.TEXTURE_2D,n),n},n.getImageBuffer=function(){this._imageBuffers||(this._imageBuffers=[]);var t=this._imageBuffers;return t&&t.length>0?t.pop():null},n.saveImageBuffer=function(t){this._imageBuffers.push(t)},n.loadImageBuffer=function(t,e){var n=this.gl,r=e||this.createImageBuffer();return n.bindBuffer(n.ARRAY_BUFFER,r),n.bufferData(n.ARRAY_BUFFER,t,n.STATIC_DRAW),r},n.createImageBuffer=function(){return this.getImageBuffer()||this.createBuffer()},n.removeGLCanvas=function(){var t=this.gl;if(t){if(this._debugBuffer&&(t.deleteBuffer(this._debugBuffer),delete this._debugBuffer),this._buffers&&(this._buffers.forEach((function(e){t.deleteBuffer(e)})),delete this._buffers),this._textures&&(this._textures.forEach((function(e){return t.deleteTexture(e)})),delete this._textures),this._debugInfoCanvas){var e=this._debugInfoCanvas.texture;e&&t.deleteTexture(e),delete this._debugInfoCanvas.texture,delete this._debugInfoCanvas}var n=t.program;t.deleteShader(n.fragmentShader),t.deleteShader(n.vertexShader),t.deleteProgram(n),delete this.gl,delete this.canvas2}},n.createBuffer=function(){var t=this.gl.createBuffer();if(!t)throw new Error("Failed to create the buffer object");return this._buffers||(this._buffers=[]),this._buffers.push(t),t},n.enableVertexAttrib=function(t){!function(t,e,n){if(Array.isArray(n[0])){for(var r=Float32Array.BYTES_PER_ELEMENT,i=0,o=0;o<n.length;o++)i+=n[o][1]||0;for(var a=0,s=0;s<n.length;s++){var u=t.getAttribLocation(e,n[s][0]);if(u<0)throw new Error("Failed to get the storage location of "+n[s][0]);t.vertexAttribPointer(u,n[s][1],t[n[s][2]||"FLOAT"],!1,r*i,r*a),a+=n[s][1]||0,t.enableVertexAttribArray(u)}}else{var c=t.getAttribLocation(e,n[0]);t.vertexAttribPointer(c,n[1],t[n[2]||"FLOAT"],!1,0,0),t.enableVertexAttribArray(c)}}(this.gl,this.gl.program,t)},n.createProgram=function(t,e,n){var r=function(t,e,n){var r=Oa(t,t.VERTEX_SHADER,e),i=Oa(t,t.FRAGMENT_SHADER,n);if(!r||!i)return null;var o=t.createProgram();return o?(t.attachShader(o,r),t.attachShader(o,i),t.linkProgram(o),{program:o,vertexShader:r,fragmentShader:i}):null}(this.gl,t,e),i=r.program,o=r.vertexShader,a=r.fragmentShader;return i.vertexShader=o,i.fragmentShader=a,this._initUniforms(i,n),i},n.useProgram=function(t){var e=this.gl;return e.useProgram(t),e.program=t,this},n.enableSampler=function(t,e){var n=this.gl,r=this._getUniform(n.program,t);return e||(e=0),n.uniform1i(r,e),r},n._initUniforms=function(t,e){for(var n=0;n<e.length;n++){var r=e[n],i=e[n],o=r.indexOf("[");o>=0&&(r=r.substring(0,o),A||(i=i.substring(0,o))),t[r]=this._getUniform(t,i)}},n._getUniform=function(t,e){var n=this.gl.getUniformLocation(t,e);if(!n)throw new Error("Failed to get the storage location of "+e);return n},e}(t);return d(e.prototype,{set8:function(){var t=he.ie9?null:new Float32Array(8);return function(e,n,r,i,o,a,s,u){return t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=o,t[5]=a,t[6]=s,t[7]=u,t}}(),set8Int:function(){var t=he.ie9?null:new Int16Array(8);return function(e,n,r,i,o,a,s,u){return t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=o,t[5]=a,t[6]=s,t[7]=u,t}}()}),e},Fa={renderer:he.webgl?"gl":"canvas",crossOrigin:null},Ba=new me(0,0),Ha=function(t){function e(e,n,r){var i;return!n||Array.isArray(n)||n.url||(r=n,n=null),(i=t.call(this,e,r)||this)._images=n,i}fe(e,t);var n=e.prototype;return n.onAdd=function(){this._prepareImages(this._images)},n.setImages=function(t){return this._images=t,this._prepareImages(t),this},n.getImages=function(){return this._images},n._prepareImages=function(t){t=t||[],Array.isArray(t)||(t=[t]);var e=this.getMap();this._imageData=t.map((function(t){var n=new Vn(t.extent);return d({},t,{extent:n,extent2d:n.convertTo((function(t){return e.coordToPoint(t,e.getGLZoom())}))})})),this._images=t;var n=this.getRenderer();n&&n.refreshImages()},e}(ei);Ha.mergeOptions(Fa);var Ga=[],Ua=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.isDrawable=function(){return!this.getMap().getPitch()||(console&&console.warn("ImageLayer with canvas renderer can't be pitched, use gl renderer ('renderer' : 'gl') instead."),!1)},n.checkResources=function(){var t=this;if(this._imageLoaded)return Ga;var e=this.layer._imageData.map((function(t){return[t.url,null,null]}));if(this.resources){var n=[],r=new gr;e.forEach((function(e){if(t.resources.isResourceLoaded(e)){var i=t.resources.getImage(e);r.addResource(e,i)}else n.push(e)})),this.resources.forEach((function(e,n){r.isResourceLoaded(e)||t.retireImage(n.image)})),this.resources=r,e=n}return this._imageLoaded=!0,e},n.retireImage=function(){},n.refreshImages=function(){this._imageLoaded=!1,this.setToRedraw()},n.needToRedraw=function(){var e=this.getMap();return!(e.isZooming()&&!e.getPitch())&&t.prototype.needToRedraw.call(this)},n.draw=function(){this.isDrawable()&&(this.prepareCanvas(),this._painted=!1,this._drawImages(),this.completeRender())},n._drawImages=function(){var t=this.layer._imageData,e=this.getMap(),n=e._get2DExtent(e.getGLZoom());if(t&&t.length)for(var r=0;r<t.length;r++){var i=t[r].extent2d,o=this.resources&&this.resources.getImage(t[r].url);o&&n.intersects(i)&&(this._painted=!0,this._drawImage(o,i,t[r].opacity||1))}},n._drawImage=function(t,e,n){var r=0,i=this.context;n<1&&(r=i.globalAlpha,i.globalAlpha=n);var o=this.getMap(),a=Ba.set(e.xmin,e.ymax),s=o._pointToContainerPoint(a,o.getGLZoom()),u=s.x,c=s.y,l=o.getBearing();l&&(i.save(),i.translate(u,c),l&&i.rotate(-l*Math.PI/180),u=c=0);var h=o.getGLScale();i.drawImage(t,u,c,e.getWidth()/h,e.getHeight()/h),l&&i.restore(),r&&(i.globalAlpha=r)},n.drawOnInteracting=function(){this.draw()},e}(mr),Wa=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.isDrawable=function(){return!0},n._drawImage=function(t,e,n){this.drawGLImage(t,e.xmin,e.ymax,e.getWidth(),e.getHeight(),1,n)},n.createContext=function(){this.createGLContext()},n.resizeCanvas=function(e){this.canvas&&(t.prototype.resizeCanvas.call(this,e),this.resizeGLCanvas())},n.clearCanvas=function(){this.canvas&&(t.prototype.clearCanvas.call(this),this.clearGLCanvas())},n.retireImage=function(t){this.disposeImage(t)},n.onRemove=function(){this.removeGLCanvas(),t.prototype.onRemove.call(this)},e}(Na(Ua));Ha.registerRenderer("canvas",Ua),Ha.registerRenderer("gl",Wa);var Va=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.getPrepareParams=function(){return[]},n.getDrawParams=function(){return[]},n.onCanvasCreate=function(){this.canvas&&this.layer.options.doubleBuffer&&(this.buffer=hn.createCanvas(this.canvas.width,this.canvas.height,this.getMap().CanvasClass))},n.needToRedraw=function(){return!!this.layer.options.animation||!(this.getMap().isInteracting()&&!this.layer.drawOnInteracting)&&t.prototype.needToRedraw.call(this)},n.draw=function(){this.prepareCanvas(),this.prepareDrawContext(),this._drawLayer()},n.drawOnInteracting=function(){this._drawLayerOnInteracting()},n.getCanvasImage=function(){var e=t.prototype.getCanvasImage.call(this);if(e&&e.image&&this.layer.options.doubleBuffer){var n=e.image;this.buffer.width===n.width&&this.buffer.height===n.height||(this.buffer.width=n.width,this.buffer.height=n.height);var r=this.buffer.getContext("2d"),i=this.layer.doubleBuffer(r,this.context);(void 0===i||i)&&(hn.image(r,n,0,0),e.image=this.buffer)}return e},n.remove=function(){return delete this._drawContext,t.prototype.remove.call(this)},n.onZoomStart=function(e){this.layer.onZoomStart(e),t.prototype.onZoomStart.call(this,e)},n.onZooming=function(e){this.layer.onZooming(e),t.prototype.onZooming.call(this,e)},n.onZoomEnd=function(e){this.layer.onZoomEnd(e),t.prototype.onZoomEnd.call(this,e)},n.onMoveStart=function(e){this.layer.onMoveStart(e),t.prototype.onMoveStart.call(this,e)},n.onMoving=function(e){this.layer.onMoving(e),t.prototype.onMoving.call(this,e)},n.onMoveEnd=function(e){this.layer.onMoveEnd(e),t.prototype.onMoveEnd.call(this,e)},n.onResize=function(e){this.layer.onResize(e),t.prototype.onResize.call(this,e)},n.prepareDrawContext=function(){if(!this._predrawed){var t=Za(this.getPrepareParams());this._drawContext=this.layer.prepareToDraw.apply(this.layer,[this.context].concat(t)),this._drawContext||(this._drawContext=[]),Array.isArray(this._drawContext)||(this._drawContext=[this._drawContext]),this._predrawed=!0}},n._prepareDrawParams=function(){if(!this.getMap())return null;var t=this.getViewExtent();if(t.maskExtent&&!t.extent.intersects(t.maskExtent))return this.completeRender(),null;var e=[this.context,t],n=Za(this.getDrawParams());return e.push.apply(e,n),e.push.apply(e,this._drawContext),e},n._drawLayer=function(){var t=this._prepareDrawParams();t&&(this.layer.draw.apply(this.layer,t),this.completeRender())},n._drawLayerOnInteracting=function(){if(this.layer.drawOnInteracting){var t=this._prepareDrawParams();t&&(this.layer.drawOnInteracting.apply(this.layer,t),this.completeRender())}},e}(mr);function Za(t){return t||(t=[]),Array.isArray(t)||(t=[t]),t}var qa=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.isCanvasRender=function(){return!0},n.prepareToDraw=function(){},n.draw=function(){},n.redraw=function(){return this._getRenderer()&&this._getRenderer().setToRedraw(),this},n.play=function(){return this.config("animation",!0),this},n.pause=function(){return this.config("animation",!1),this},n.isPlaying=function(){return this.options.animation},n.clearCanvas=function(){return this._getRenderer()&&this._getRenderer().clearCanvas(),this},n.requestMapToRender=function(){return this._getRenderer()&&this._getRenderer().requestMapToRender(),this},n.completeRender=function(){return this._getRenderer()&&this._getRenderer().completeRender(),this},n.onCanvasCreate=function(){return this},n.onZoomStart=function(){},n.onZooming=function(){},n.onZoomEnd=function(){},n.onMoveStart=function(){},n.onMoving=function(){},n.onMoveEnd=function(){},n.onResize=function(){},n.doubleBuffer=function(t){return t.clearRect(0,0,t.canvas.width,t.canvas.height),this},e}(ei);qa.mergeOptions({doubleBuffer:!1,animation:!1}),qa.registerRenderer("canvas",Va);var Ya=new me(0,0),Ja=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.getParticles=function(){},n.draw=function(t,e){var n=this.getParticles(f());if(n&&0!==n.length){var r=this.getMap(),i=e.extent;e.maskExtent&&(i=e.extent.intersection(e.maskExtent)),i=i.convertTo((function(t){return r._pointToContainerPoint(t,void 0,0,Ya)}));for(var o=2*Math.PI,a=0,s=n.length;a<s;a++){var u=n[a].point;if(i.contains(u)){var c=n[a].color||this.options.lineColor||"#fff",l=n[a].r;t.fillStyle!==c&&(t.fillStyle=c),l<=2?t.fillRect(u.x-l/2,u.y-l/2,l,l):(t.beginPath(),t.arc(u.x,u.y,l/2,0,o),t.fill())}}this._fillCanvas(t)}else this._getRenderer()&&(this._getRenderer()._shouldClear=!0)},n._fillCanvas=function(t){var e=t.globalCompositeOperation;t.globalCompositeOperation="destination-out";var n=this.options.trail||30;t.fillStyle="rgba(0, 0, 0, "+1/n+")",t.fillRect(0,0,t.canvas.width,t.canvas.height),t.globalCompositeOperation=e},e}(qa);Ja.mergeOptions({animation:!0}),Ja.registerRenderer("canvas",function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.draw=function(){this.canvas&&this.layer.options.animation&&!this._shouldClear||(this.prepareCanvas(),this._shouldClear=!1),this.prepareDrawContext(),this._drawLayer()},n.drawOnInteracting=function(){this.draw(),this._shouldClear=!1},n.onSkipDrawOnInteracting=function(){this._shouldClear=!0},e}(Va));var Xa=i+"_edit_stage_";function $a(t,e){return{markerType:t,markerFill:"#fff",markerLineColor:"#000",markerLineWidth:2,markerWidth:10,markerHeight:10,opacity:e}}var Qa={fixAspectRatio:!1,symbol:null,removeVertexOn:"contextmenu",centerHandleSymbol:$a("ellipse",1),vertexHandleSymbol:$a("square",1),newVertexHandleSymbol:$a("square",.4)},Ka=function(t){function e(e,n){var r;return(r=t.call(this,n)||this)._geometry=e,r._geometry?r:de(r)}fe(e,t);var n=e.prototype;return n.getMap=function(){return this._geometry.getMap()},n.prepare=function(){this.getMap()&&(this.options.symbol&&(this._originalSymbol=this._geometry.getSymbol(),this._geometry.setSymbol(this.options.symbol)),this._prepareEditStageLayer())},n._prepareEditStageLayer=function(){var t=this.getMap(),e=O(),n=Xa+e,r=Xa+e+"_shadow";this._editStageLayer=t.getLayer(n),this._shadowLayer=t.getLayer(r),this._editStageLayer||(this._editStageLayer=new eo(n),t.addLayer(this._editStageLayer)),this._shadowLayer||(this._shadowLayer=new eo(r),t.addLayer(this._shadowLayer))},n.start=function(){var t=this;if(this._geometry&&this._geometry.getMap()&&!this._geometry.editing){var e=this.getMap();this.editing=!0;var n=this._geometry;this._geometryDraggble=n.options.draggable,n.config("draggable",!1),this.prepare();var r=n.copy();r.setSymbol(n._getInternalSymbol()),r.copyEventListeners(n),n._getParent()&&r.copyEventListeners(n._getParent()),r._setEventTarget(n),r.setId(null).config({draggable:!1}),this._shadow=r,this._switchGeometryEvents("on"),n.hide(),(n instanceof Mi||n instanceof Di||n instanceof zi||n instanceof ji)&&this._createOrRefreshOutline(),this._shadowLayer.bringToFront().addGeometry(r),this._editStageLayer.bringToFront(),this._addListener([e,"zoomstart",function(){t._editStageLayer.hide()}]),this._addListener([e,"zoomend",function(){t._editStageLayer.show()}]),n instanceof Mi?(r.config("draggable",!0),r.on("dragend",this._onMarkerDragEnd,this)):this._createCenterHandle(),n instanceof Mi?this.createMarkerEditor():n instanceof Di?this.createCircleEditor():n instanceof zi||n instanceof ji?this.createEllipseOrRectEditor():n instanceof Ni||(n instanceof bi||n instanceof Ti)&&this.createPolygonEditor()}},n.stop=function(){delete this._history,delete this._historyPointer,delete this._editOutline,this._switchGeometryEvents("off"),this.getMap()&&(delete this._shadow,this._geometry.config("draggable",this._geometryDraggble),delete this._geometryDraggble,this._geometry.show(),this._editStageLayer.remove(),this._shadowLayer.remove(),this._clearAllListeners(),this._refreshHooks=[],this.options.symbol&&(this._geometry.setSymbol(this._originalSymbol),delete this._originalSymbol),this.editing=!1)},n.isEditing=function(){return!p(this.editing)&&this.editing},n._getGeometryEvents=function(){return{symbolchange:this._onGeoSymbolChange,"positionchange shapechange":this._exeAndReset}},n._switchGeometryEvents=function(t){if(this._geometry){var e=this._getGeometryEvents();for(var n in e)this._geometry[t](n,e[n],this)}},n._onGeoSymbolChange=function(t){this._shadow&&this._shadow.setSymbol(t.target._getInternalSymbol())},n._onMarkerDragEnd=function(){this._update("setCoordinates",this._shadow.getCoordinates().toArray()),this._refresh()},n._createOrRefreshOutline=function(){var t=this._geometry,e=this._editOutline;return e?(e.remove(),this._editOutline=e=t.getOutline(),this._editStageLayer.addGeometry(e)):(e=t.getOutline(),this._editStageLayer.addGeometry(e),this._editOutline=e,this._addRefreshHook(this._createOrRefreshOutline)),e},n._createCenterHandle=function(){var t,e=this,n=this._shadow.getCenter(),r=this.options.centerHandleSymbol,i=this.createHandle(n,{symbol:r,cursor:"move",onDown:function(){var n=It((t=e._shadow.copy())._getInternalSymbol(),.5);t.setSymbol(n).addTo(e._editStageLayer)},onMove:function(e,n){var r=n.coordOffset;t.translate(r)},onUp:function(){e._update("setCoordinates",On.toNumberArrays(t.getCoordinates())),t.remove(),e._refresh()}});this._addRefreshHook((function(){var t=e._shadow.getCenter();i.setCoordinates(t)}))},n._createHandleInstance=function(t,e){var n=e.symbol;return new Mi(t,{draggable:!0,dragShadow:!1,dragOnAxis:e.axis,cursor:e.cursor,symbol:n})},n.createHandle=function(t,e){e||(e={});var n=this.getMap(),r=this._createHandleInstance(t,e),i=this;function o(t){return e.onDown&&(this._geometry.fire("handledragstart"),e.onDown.call(i,t.viewPoint,t)),!1}function a(t){i._hideContext();var o=n._prjToViewPoint(r._getPrjCoordinates());return e.onMove&&(this._geometry.fire("handledragging"),e.onMove.call(i,o,t)),!1}function s(t){return e.onUp&&(this._geometry.fire("handledragend"),e.onUp.call(i,t)),!1}return r.on("dragstart",o,this),r.on("dragging",a,this),r.on("dragend",s,this),r.on("removestart",(function t(){r.config("draggable",!1),r.off("dragstart",o,i),r.off("dragging",a,i),r.off("dragend",s,i),r.off("removestart",t,i),delete r["maptalks--editor-refresh-fn"]}),this),e.onRefresh&&(r["maptalks--editor-refresh-fn"]=e.onRefresh),this._editStageLayer.addGeometry(r),r},n._createResizeHandles=function(t,e,n){var r=this,i=["nw-resize","n-resize","ne-resize","w-resize","e-resize","sw-resize","s-resize","se-resize"],o=[null,"y",null,"x","x",null,"y",null],a=this._geometry;t||(t=[]);var s=this,u=[],c={},l=this.getMap(),h=this.options.vertexHandleSymbol,f=function(){for(var f=function(t){return[new me(t.xmin,t.ymax),new me((t.xmax+t.xmin)/2,t.ymax),new me(t.xmax,t.ymax),new me(t.xmin,(t.ymax+t.ymin)/2),new me(t.xmax,(t.ymax+t.ymin)/2),new me(t.xmin,t.ymin),new me((t.xmax+t.xmin)/2,t.ymin),new me(t.xmax,t.ymin)]}(a._getPainter().get2DExtent()),d=function(d){if(Array.isArray(t)&&t.some((function(t){return t===d})))return"continue";var p=f[d],m=l.pointToCoordinate(p);if(u.length<f.length-t.length){var g=r.createHandle(m,{symbol:h,cursor:i[d],axis:o[d],onMove:function(t){return function(n){s._updating=!0,e(n,t),a.fire("resizing")}}(d),onUp:function(){s._updating=!1,n(),r._refresh()}});g.setId(d),c[d]=u.length,u.push(g)}else u[c[d]].setCoordinates(m)},p=0;p<f.length;p++)d(p)};return f(),this._addRefreshHook(f),u},n.createMarkerEditor=function(){var t=this,e=this._geometry,n=this._shadow,r=this.getMap();if(n._canEdit()){this._history||this._recordHistory(h());var i=n._getInternalSymbol(),o=new me(0,0);m(i.markerDx)&&(o.x=i.markerDx),m(i.markerDy)&&(o.y=i.markerDy);var a=null;Cr.test(i)?"pin"!==i.markerType&&"pie"!==i.markerType&&"bar"!==i.markerType||(a=[5,6,7]):(Lr.test(i)||zr.test(i))&&(a=[5,6,7]);var s,u=[2,1,2,0,0,2,1,2];if(this.options.fixAspectRatio){var c=n.getSize();s=c.width/c.height}var l=this._createResizeHandles(null,(function(i,c){if(a&&a.indexOf(c)>=0){var h=r.viewPointToCoordinate(i.sub(o)),f=n.getCoordinates();h.x=f.x,n.setCoordinates(h),t._updateCoordFromShadow(!0);var d=l[l.length-1-c];i=r.coordToViewPoint(d.getCoordinates())}var p=r._pointToViewPoint(n._getCenter2DPoint()).add(o),m=n._getInternalSymbol(),g=i.sub(p);a&&i.y>p.y&&(g.y=0);var v=a?1:2,y=2*Math.abs(g.x),_=Math.abs(g.y)*v;s&&(_=(y=Math.max(y,_*s))/s);var x=u[c];n instanceof Zi?((s||0===x||2===x)&&(n.setWidth(y),e.setWidth(y)),(s||1===x||2===x)&&(n.setHeight(_),e.setHeight(_))):((s||0===x||2===x)&&(m.markerWidth=y),(s||1===x||2===x)&&(m.markerHeight=_),n.setSymbol(m),e.setSymbol(m))}),(function(){t._update(h())}));this._addListener([r,"zoomend",function(){this._refresh()}])}else console&&console.warn("A marker can't be resized with symbol:",n.getSymbol());function h(){var t=[["setCoordinates",n.getCoordinates().toArray()]];return n instanceof Zi?(t.push(["setWidth",n.getWidth()]),t.push(["setHeight",n.getHeight()])):t.push(["setSymbol",n.getSymbol()]),t}},n.createCircleEditor=function(){var t=this,e=this._geometry,n=this._shadow,r=this.getMap();this._history||this._recordHistory([["setCoordinates",n.getCoordinates().toArray()],["setRadius",n.getRadius()]]),this._createResizeHandles(null,(function(t){var i=e.getCenter(),o=r.viewPointToCoordinate(t),a=new Ti([[i.x,i.y],[o.x,i.y]]),s=new Ti([[i.x,i.y],[i.x,o.y]]),u=Math.max(r.computeGeometryLength(a),r.computeGeometryLength(s));n.setRadius(u),e.setRadius(u)}),(function(){t._update("setRadius",n.getRadius())}))},n.createEllipseOrRectEditor=function(){var t=this,e=[2,1,2,0,0,2,1,2],n=this._geometry,r=this._shadow;this._history||this._recordHistory(u());var i,o=this.getMap(),a=this._geometry instanceof zi;this.options.fixAspectRatio&&(i=n.getWidth()/n.getHeight());var s=this._createResizeHandles(null,(function(u,c){var l,h,f,d=a?1:2,p=u,m=e[c];if(a){var g=s[7-c],v=o.coordToViewPoint(g.getCoordinates()),y=(l=p.sub(v)).abs();h=o.pixelToDistance(y.x,0),f=o.pixelToDistance(0,y.y);var _=n.getSize(),x=s[0].getCoordinates(),b=o.viewPointToCoordinate(u),w=g.getCoordinates(),M=new Ti([[w.x,w.y],[b.x,w.y]]),S=new Ti([[w.x,w.y],[w.x,b.y]]);h=o.computeGeometryLength(M),f=o.computeGeometryLength(S),0===m?(i&&(y.y=y.x/i,_.height=Math.abs(y.y),f=h/i),p.y=v.y-_.height/2,b.y=x.y,b.x=4===c?Math.min(b.x,x.x):Math.min(b.x,w.x)):1===m?(i&&(y.x=y.y*i,_.width=Math.abs(y.x),h=f*i),p.x=v.x-_.width/2,b.x=x.x,b.y=Math.max(b.y,w.y)):(i&&(h>f*i?(f=h/i,p.y=v.y+y.x*N(l.y)/i):(h=f*i,p.x=v.x+y.y*N(l.x)*i)),b.x=Math.min(b.x,w.x),b.y=Math.max(b.y,w.y)),r.setCoordinates(b),t._updateCoordFromShadow(!0)}else{var T=n.getCenter(),E=o.viewPointToCoordinate(p),A=new Ti([[T.x,T.y],[E.x,T.y]]),C=new Ti([[T.x,T.y],[T.x,E.y]]);h=o.computeGeometryLength(A),f=o.computeGeometryLength(C),i&&(f=(h=Math.max(h,f*i))/i)}(i||0===m||2===m)&&(r.setWidth(h*d),n.setWidth(h*d)),(i||1===m||2===m)&&(r.setHeight(f*d),n.setHeight(f*d))}),(function(){t._update(u())}));function u(){return[["setCoordinates",r.getCoordinates().toArray()],["setWidth",r.getWidth()],["setHeight",r.getHeight()]]}},n.createPolygonEditor=function(){var t=this.getMap(),e=this._shadow,n=this,r=t.getProjection();this._history||this._recordHistory("setCoordinates",On.toNumberArrays(e.getCoordinates()));var i=e instanceof bi?3:2,o="maptalks--editor-refresh-fn",a="maptalks--editor-vertex-index",s={0:[]},u={0:[]};function c(t){if(void 0===t&&(t=0),e instanceof bi){var n=e.getCoordinates()[t]||[];return n.slice(0,n.length-1)}return e.getCoordinates()}function l(t){return void 0===t&&(t=0),0===t?e._getPrjCoordinates():e._getPrjHoles()[t-1]}function h(){for(var t in s){for(var e=s[t].length-1;e>=0;e--)s[t][e][a]=e;for(var r=u[t].length-1;r>=0;r--)u[t][r][a]=r}n._updateCoordFromShadow()}function f(t){var r,o=t.target,c=o[a],f=m(o._ringIndex)?o._ringIndex:0,d=l(f);d.length<=i||(d.splice(c,1),f>0?e._prjHoles[f-1]=d:e._setPrjCoordinates(d),e._updateCache(),s[f].splice(c,1)[0].remove(),c<u[f].length&&u[f].splice(c,1)[0].remove(),r=0===c?u[f].length-1:c-1,u[f].splice(r,1)[0].remove(),u[f].splice(r,0,g.call(n,r,f)),h(),n._refresh())}function d(r,i,a){void 0===a&&(a=0);var s,c=l(a),h=t._viewPointToPrj(r),f=c[i];f.x=h.x,f.y=h.y,e._updateCache(),e.onShapeChanged(),n._updateCoordFromShadow(!0),s=0===i?u[a].length-1:i-1,u[a][i]&&u[a][i][o](),u[a][s]&&u[a][s][o]()}function p(t,e){void 0===e&&(e=0);var r=c(e)[t],i=n.createHandle(r,{symbol:n.options.vertexHandleSymbol,cursor:"pointer",axis:null,onMove:function(t){d(t,i[a],e)},onRefresh:function(){r=c(e)[i[a]],i.setCoordinates(r)},onUp:function(){n._refresh(),n._updateCoordFromShadow()},onDown:function(t,e){!e||!e.domEvent||e.domEvent.button}});return i[a]=t,i._ringIndex=e,i.on(n.options.removeVertexOn,f),i}function g(t,i){void 0===i&&(i=0);var o,f=c(i);o=t+1>=f.length?f[0]:f[t+1];var m=f[t].add(o).multi(.5),v=n.createHandle(m,{symbol:n.options.newVertexHandleSymbol,cursor:"pointer",axis:null,onDown:function(t,o){if(!o||!o.domEvent||2!==o.domEvent.button){var s=l(i),c=v[a],h=r.project(v.getCoordinates());s.splice(c+1,0,h),i>0?e._prjHoles[i-1]=s:e._setPrjCoordinates(s),e._updateCache();var f=v.getSymbol();delete f.opacity,v.setSymbol(f),u[i].splice(c,0,g.call(n,c,i),g.call(n,c+1,i))}},onMove:function(t){d(t,v[a]+1,i)},onUp:function(t){if(!t||!t.domEvent||2!==t.domEvent.button){var e=v[a];D(v,u[i]),v.remove(),s[i].splice(e+1,0,p.call(n,e+1,i)),h(),n._updateCoordFromShadow(),n._refresh()}},onRefresh:function(){f=c(i);var t,e=v[a];t=e===f.length-1?0:e+1;var n=f[e].add(f[t]).multi(.5);v.setCoordinates(n)}});return v[a]=t,v}if(e instanceof bi)for(var v=e.getHoles().length+1,y=0;y<v;y++){s[y]=[],u[y]=[];for(var _=c(y),x=0,b=_.length;x<b;x++)s[y].push(p.call(this,x,y)),x<b-1&&u[y].push(g.call(this,x,y));u[y].push(g.call(this,_.length-1,y))}else for(var w=0,M=c(0).length;w<M;w++)s[0].push(p.call(this,w,0)),w<M-1&&u[0].push(g.call(this,w,0));this._addRefreshHook((function(){for(var t in u)for(var e=u[t].length-1;e>=0;e--)u[t][e][o](t);for(var n in s)for(var r=s[n].length-1;r>=0;r--)s[n][r][o](n)}))},n._refresh=function(){if(this._refreshHooks)for(var t=this._refreshHooks.length-1;t>=0;t--)this._refreshHooks[t].call(this)},n._hideContext=function(){this._geometry&&(this._geometry.closeMenu(),this._geometry.closeInfoWindow())},n._addListener=function(t){this._eventListeners||(this._eventListeners=[]),this._eventListeners.push(t),t[0].on(t[1],t[2],this)},n._clearAllListeners=function(){if(this._eventListeners&&this._eventListeners.length>0){for(var t=this._eventListeners.length-1;t>=0;t--){var e=this._eventListeners[t];e[0].off(e[1],e[2],this)}this._eventListeners=[]}},n._addRefreshHook=function(t){t&&(this._refreshHooks||(this._refreshHooks=[]),this._refreshHooks.push(t))},n._update=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];this._exeHistory([t,n]),this._recordHistory.apply(this,[t].concat(n))},n._updateCoordFromShadow=function(t){if(this._shadow){var e=this._shadow.getCoordinates(),n=this._geometry,r=this._updating;this._updating=!0,n.setCoordinates(e),t||this._recordHistory("setCoordinates",On.toNumberArrays(n.getCoordinates())),this._updating=r}},n._recordHistory=function(t){this._history||(this._history=[],this._historyPointer=0);for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];if(this._history.length){var i=this._history[this._history.length-1];if(i[0]===t&&JSON.stringify(i[1])===JSON.stringify(n))return}this._historyPointer<this._history.length-1&&this._history.splice(this._historyPointer+1),this._history.push([t,n]),this._historyPointer=this._history.length-1,this._geometry.fire("editrecord")},n.cancel=function(){if(!this._history||0===this._historyPointer)return this;this._historyPointer=0;var t=this._history[0];return this._exeAndReset(t),this},n.undo=function(){if(!this._history||0===this._historyPointer)return this;var t=this._history[--this._historyPointer];return this._exeAndReset(t),this},n.redo=function(){if(!this._history||this._historyPointer===this._history.length-1)return this;var t=this._history[++this._historyPointer];return this._exeAndReset(t),this},n._exeAndReset=function(t){if(!this._updating){this._exeHistory(t);var e=this._history,n=this._historyPointer;this.stop(),this._history=e,this._historyPointer=n,this.start()}},n._exeHistory=function(t){var e=this;if(Array.isArray(t)){var n=this._updating;this._updating=!0;var r=this._geometry;Array.isArray(t[0])?t[0].forEach((function(t){var n=t[0],i=t.slice(1);e._shadow[n].apply(e._shadow,i),r[n].apply(r,i)})):(this._shadow[t[0]].apply(this._shadow,t[1]),r[t[0]].apply(r,t[1])),this._updating=n}},e}(xn(Mn));Ka.mergeOptions(Qa);var ts={startEditText:function(){return this.getMap()?(this.hide(),this.endEditText(),this._prepareEditor(),this._fireEvent("edittextstart"),this):this},endEditText:function(){if(this._textEditor){var t=this._textEditor.innerHTML;t=t.replace(/<p>/gi,"").replace(/<\/p>/gi,"<br/>"),this._textEditor.innerHTML=t;var e=this._textEditor.innerText.replace(/[\r\n]+$/gi,"");this.setContent(e),on(this._textEditor,"mousedown dblclick",Ue),this.getMap().off("mousedown",this.endEditText,this),this._editUIMarker.remove(),delete this._editUIMarker,this._textEditor.onkeyup=null,delete this._textEditor,this.show(),this._fireEvent("edittextend")}return this},isEditingText:function(){return!!this._textEditor},getTextEditor:function(){return this._editUIMarker},_prepareEditor:function(){var t=this.getMap(),e=this._createEditor();this._textEditor=e,t.on("mousedown",this.endEditText,this);var n=this._getEditorOffset();this._editUIMarker=new Fo(this.getCoordinates(),{animation:null,content:e,dx:n.dx,dy:n.dy}).addTo(t),this._setCursorToLast(this._textEditor)},_getEditorOffset:function(){var t=this._getInternalSymbol()||{},e=0,n=0,r=t.textHorizontalAlignment;return"middle"===r||p(r)?(e=(t.textDx||0)-2,n=(t.textDy||0)-2):(e=(t.markerDx||0)-2,n=(t.markerDy||0)-2),{dx:e,dy:n}},_createEditor:function(){var t=this.getContent(),e=this.getSize(),n=this._getInternalSymbol()||{},r=e.width,i=n.textFill||"#000000",o=n.textSize||12,a=e.height,s=n.markerLineColor||"#000",u=n.markerFill||"#3398CC",c=n.textLineSpacing||0,l=je("div");return l.contentEditable=!0,l.style.cssText="background:"+u+"; border:1px solid "+s+";\n color:"+i+";font-size:"+o+"px;width:"+(r-2)+"px;height:"+(a-2)+"px;margin: auto;\n line-height:"+(o+c)+"px;outline: 0; padding:0; margin:0;word-wrap: break-word;\n overflow: hidden;-webkit-user-modify: read-write-plaintext-only;",l.innerText=t,rn(l,"mousedown dblclick",Ue),l.onkeyup=function(t){var e=l.style.height||0;13===t.keyCode&&(l.style.height=parseInt(e)+o/2+"px")},l},_setCursorToLast:function(t){var e;window.getSelection?(t.focus(),(e=window.getSelection()).selectAllChildren(t),e.collapseToEnd()):document.selection&&((e=document.selection.createRange()).moveToElementText(t),e.collapse(!1),e.select())}};Vi.include(ts),Kr.include({animate:function(t,e,n){var r=this;this._animPlayer&&this._animPlayer.finish(),_(e)&&(n=e),e||(e={});var i,o=this.getMap(),a=this._getProjection(),s=this.getSymbol()||{},u=this._prepareAnimationStyles(t),c=e.focus;if(delete this._animationStarted,o){var l=o._getRenderer();e.framer=function(t){l.callInNextFrame(t)}}var h=gi.animate(u,e,(function(t){if(o&&o.isRemoved())h.finish();else{o&&!r._animationStarted&&c&&o.onMoveStart();var e=t.styles;for(var u in e)if("symbol"!==u&&"translate"!==u&&e.hasOwnProperty(u)){var l="set"+u[0].toUpperCase()+u.slice(1);r[l](e[u])}var f=e.translate;if(f){var d=f;i&&(d=f.sub(i)),i=f,r.translate(d)}var p=e.symbol;if(p&&r.setSymbol(Dt(s,p)),o&&c){var m=a.project(r.getCenter());o._setPrjCenter(m);var g=o._parseEventFromCoord(a.unproject(m));"running"!==h.playState?o.onMoveEnd(g):o.onMoving(g)}r._fireAnimateEvent(h.playState),n&&n(t)}}),this);return this._animPlayer=h,this._animPlayer.play()},_prepareAnimationStyles:function(t){var e=this._getInternalSymbol(),n={};for(var r in t)if(t.hasOwnProperty(r)){var i=t[r];if("translate"!==r&&"symbol"!==r){var o=this["get"+r[0].toUpperCase()+r.substring(1)]();n[r]=[o,i]}else if("symbol"===r){var a=void 0;if(Array.isArray(t.symbol)){if(!Array.isArray(e))throw new Error("geometry'symbol isn't a composite symbol, while the symbol in styles is.");a=[];for(var s=t.symbol,u=0;u<s.length;u++)if(s[u]){var c={};for(var l in s[u])s[u].hasOwnProperty(l)&&(c[l]=[e[u][l],s[u][l]]);a.push(c)}else a.push(null)}else{if(Array.isArray(e))throw new Error("geometry'symbol is a composite symbol, while the symbol in styles isn't.");for(var h in a={},i)i.hasOwnProperty(h)&&(a[h]=[e[h],i[h]])}n.symbol=a}else"translate"===r&&(n.translate=new On(i))}return n},_fireAnimateEvent:function(t){"finished"===t?(delete this._animationStarted,this._fireEvent("animateend")):"running"===t&&(this._animationStarted?this._fireEvent("animating"):(this._fireEvent("animatestart"),this._animationStarted=!0))}});var es=i+"_drag_stage",ns=he.touch?"touchstart mousedown":"mousedown",rs=function(t){function e(e){return t.call(this,e)||this}fe(e,t);var n=e.prototype;return n.addHooks=function(){this.target.on(ns,this._startDrag,this)},n.removeHooks=function(){this._endDrag(),this.target.off(ns,this._startDrag,this),delete this.container},n._prepareDragHandler=function(){this._dragHandler=new Ln(this.container),this._dragHandler.on("dragging",this._dragging,this).on("mouseup",this._endDrag,this).enable()},n._prepareShadow=function(){var t=this,e=this.target;this._prepareDragStageLayer(),this._shadow&&this._shadow.remove();var n=this._shadow=e.copy();if(n.getGeometries){var r=n.getGeometries(),i=e.getGeometries();r.forEach((function(e,n){t._updateShadowSymbol(e,i[n])}))}else this._updateShadowSymbol(n,e);n.setId(null),this._prepareShadowConnectors()},n._updateShadowSymbol=function(t,e){if(t.setSymbol(e._getInternalSymbol()),e.options.dragShadow){var n=It(t._getInternalSymbol(),.5);t.setSymbol(n)}},n._prepareShadowConnectors=function(){var t=this.target,e=this._shadow,n=this._dragStageLayer._getRenderer().resources,r=[];if(Xi._hasConnectors(t))for(var i=Xi._getConnectors(t),o=0,a=i.length;o<a;o++){var s,u=i[o],c=u.config(),l=u._getInternalSymbol();c.symbol=It(l,.5),s=u.getConnectSource()===t?new u.constructor(e,u.getConnectTarget(),c):new u.constructor(u.getConnectSource(),e,c),r.push(s),u.getLayer()&&u.getLayer()._getRenderer()&&n.merge(u.getLayer()._getRenderer().resources)}this._shadowConnectors=r,r.push(e),this._dragStageLayer.bringToFront().addGeometry(r)},n._onTargetUpdated=function(){this._shadow&&this._shadow.setSymbol(this.target._getSymbol())},n._prepareDragStageLayer=function(){var t=this.target.getMap(),e=this.target.getLayer();this._dragStageLayer=t.getLayer(es),this._dragStageLayer||(this._dragStageLayer=new eo(es,{enableAltitude:e.options.enableAltitude,altitudeProperty:e.options.altitudeProperty}),t.addLayer(this._dragStageLayer));var n=new gr;n.merge(e._getRenderer().resources),this._dragStageLayer._getRenderer().resources=n},n._startDrag=function(t){var e=this.target.getMap();if(e&&!this.target._getParent()&&!this.isDragging()){var n=t.domEvent;n.touches&&n.touches.length>1||2===n.button||(this.container=e._panels.mapWrapper||e._containerDOM,this.target.on("click",this._endDrag,this),this._lastCoord=this._correctCoord(t.coordinate),this._lastPoint=t.containerPoint,this._prepareDragHandler(),this._dragHandler.onMouseDown(t.domEvent),rn(this.container,"mouseleave",this._endDrag,this),this._startParam=t,this._moved=!1)}},n._dragging=function(t){var e=this.target,n=e.getMap()._parseEvent(t.domEvent),r=n.domEvent;if(!(r.touches&&r.touches.length>1)){if(!this._moved)return this._moved=!0,e.on("symbolchange",this._onTargetUpdated,this),this._isDragging=!0,this._prepareShadow(),e.options.dragShadow||e.hide(),this._shadow._fireEvent("dragstart",n),this.target._fireEvent("dragstart",this._startParam||n),void delete this._startParam;if(this._shadow){var i=this._shadow.options.dragOnAxis,o=this._correctCoord(n.coordinate),a=n.containerPoint;this._lastPoint=this._lastPoint||a,this._lastCoord=this._lastCoord||o;var s=a.sub(this._lastPoint),u=o.sub(this._lastCoord);"x"===i?s.y=u.y=0:"y"===i&&(s.x=u.x=0),this._lastPoint=a,this._lastCoord=o,this._shadow.translate(u),e.options.dragShadow||e.translate(u),n.coordOffset=u,n.pointOffset=s,this._shadow._fireEvent("dragging",n),e._fireEvent("dragging",n)}}},n._endDrag=function(t){if(this._dragHandler&&(this._dragHandler.disable(),delete this._dragHandler),this.container&&on(this.container,"mouseleave",this._endDrag,this),this.target){var e=this.target;e.off("click",this._endDrag,this),e.off("symbolchange",this._onTargetUpdated,this),delete this._lastCoord,delete this._lastPoint,this._isDragging=!1;var n=e.getMap();if(this.enabled()&&n){var r=n._parseEvent(t?t.domEvent:null);this._updateTargetAndRemoveShadow(r),this._moved&&e._fireEvent("dragend",r)}}},n.isDragging=function(){return!!this._isDragging},n._updateTargetAndRemoveShadow=function(t){var e=this.target,n=e.getMap();e.options.dragShadow||e.show();var r=this._shadow;if(r){if(e.options.dragShadow)if(e.getGeometries){var i=r.getGeometries(),o=e.getGeometries();i.forEach((function(t,e){o[e].setCoordinates(i[e].getCoordinates())}))}else e.setCoordinates(r.getCoordinates());r._fireEvent("dragend",t),r.remove(),delete this._shadow}this._shadowConnectors&&(n.getLayer(es).removeGeometry(this._shadowConnectors),delete this._shadowConnectors),this._dragStageLayer&&this._dragStageLayer.remove()},n._correctCoord=function(t){var e=this.target.getMap();if(!e.getPitch())return t;var n=this.target._getPainter();if(!n.getMinAltitude())return t;var r=(n.getMinAltitude()+n.getMaxAltitude())/2;return e.locateByPoint(t,0,-r)},e}(wn);Kr.mergeOptions({draggable:!1,dragShadow:!0,dragOnAxis:null}),Kr.addInitHook("addHandler","draggable",rs),Kr.include({isDragging:function(){return this._getParent()?this._getParent().isDragging():!!this.draggable&&this.draggable.isDragging()}}),Kr.include({startEdit:function(t){return this.getMap()&&this.options.editable?(this.endEdit(),this._editor=new Ka(this,t),this._editor.start(),this.fire("editstart"),this):this},endEdit:function(){return this._editor&&(this._editor.stop(),delete this._editor,this.fire("editend")),this},redoEdit:function(){return this.isEditing()?(this._editor.redo(),this.fire("redoedit"),this):this},undoEdit:function(){return this.isEditing()?(this._editor.undo(),this.fire("undoedit"),this):this},cancelEdit:function(){return this.isEditing()?(this._editor.cancel(),this.fire("canceledit"),this):this},isEditing:function(){return!!this._editor&&this._editor.isEditing()}}),Kr.include({_onEvent:function(t,e){if(this.getMap()){var n=e||this._getEventTypeToFire(t);"contextmenu"===n&&this.listens("contextmenu")&&(Ue(t),Ge(t));var r=this._getEventParams(t);this._fireEvent(n,r)}},_getEventTypeToFire:function(t){return t.type},_getEventParams:function(t){var e=this.getMap(),n={domEvent:t},r=t.touches&&t.touches.length>0?t.touches[0]:t.changedTouches&&t.changedTouches.length>0?t.changedTouches[0]:t;if(r){var i=qe(r,e._containerDOM);n.coordinate=e.containerPointToCoordinate(i),n.containerPoint=i,n.viewPoint=e.containerPointToViewPoint(i),n.pont2d=e._containerPointToPoint(i)}return n}}),Kr.include({setInfoWindow:function(t){return this.removeInfoWindow(),t instanceof Go?(this._infoWindow=t,this._infoWinOptions=d({},this._infoWindow.options),this._infoWindow.addTo(this),this):(this._infoWinOptions=d({},t),this._infoWindow?this._infoWindow.setOptions(t):this.getMap()&&this._bindInfoWindow(this._infoWinOptions),this)},getInfoWindow:function(){return this._infoWindow?this._infoWindow:null},openInfoWindow:function(t){return this.getMap()?(t||(t=this.getCenter()),this._infoWindow?this._infoWindow.show(t):this._infoWinOptions&&this.getMap()&&(this._bindInfoWindow(this._infoWinOptions),this._infoWindow.show(t)),this):this},closeInfoWindow:function(){return this._infoWindow&&this._infoWindow.hide(),this},removeInfoWindow:function(){return this._unbindInfoWindow(),delete this._infoWinOptions,delete this._infoWindow,this},_bindInfoWindow:function(t){return this._infoWindow=new Go(t),this._infoWindow.addTo(this),this},_unbindInfoWindow:function(){return this._infoWindow&&(this.closeInfoWindow(),this._infoWindow.remove(),delete this._infoWindow),this}});var is=function(){function t(t,e){this.max=t,this.onRemove=e,this.reset()}var e=t.prototype;return e.reset=function(){for(var t in this.data)this.onRemove(this.data[t]);return this.data={},this.order=[],this},e.clear=function(){this.reset(),delete this.onRemove},e.add=function(t,e){if(this.has(t))this.order.splice(this.order.indexOf(t),1),this.data[t]=e,this.order.push(t);else if(this.data[t]=e,this.order.push(t),this.order.length>this.max){var n=this.getAndRemove(this.order[0]);n&&this.onRemove(n)}return this},e.has=function(t){return t in this.data},e.keys=function(){return this.order},e.getAndRemove=function(t){if(!this.has(t))return null;var e=this.data[t];return delete this.data[t],this.order.splice(this.order.indexOf(t),1),e},e.get=function(t){return this.has(t)?this.data[t]:null},e.remove=function(t){if(!this.has(t))return this;var e=this.data[t];return delete this.data[t],this.onRemove(e),this.order.splice(this.order.indexOf(t),1),this},e.setMaxSize=function(t){for(this.max=t;this.order.length>this.max;){var e=this.getAndRemove(this.order[0]);e&&this.onRemove(e)}return this},t}(),os=new me(0,0),as=new me(0,0),ss=new me(0,0),us=new me(0,0),cs=function(t){function e(e){var n;return(n=t.call(this,e)||this).tilesInView={},n.tilesLoading={},n._parentTiles=[],n._childTiles=[],n.tileCache=new is(e.options.maxCacheSize,n.deleteTile.bind(de(de(n)))),n}fe(e,t);var n=e.prototype;return n.getCurrentTileZoom=function(){return this._tileZoom},n.draw=function(){var t=this.getMap();if(this.isDrawable()){var e=this.prepareCanvas();if(!e||e.intersects(this.canvasExtent2D)){var n=this.layer.getTiles().tileGrids;if(n&&n.length){var r=0,i=!1,o={},a=[],s=[],u={},c=[],l={},h=[],f={},d={},p=this._markTiles(),m=this._getLoadLimit(),g=n.length;this._tileZoom=n[0].zoom;for(var v=0;v<g;v++)for(var y=n[v],_=y.tiles,x=this._generatePlaceHolder(y.zoom),b=0,w=_.length;b<w;b++){var M=_[b],S=M.id,T=!1;if(this._isLoadingTile(S))T=i=!0,this.tilesLoading[S].current=!0;else{var E=this._getCachedTile(S);E?(E.image&&this.getTileOpacity(E.image)<1&&(T=i=!0),a.push(E)):(T=i=!0,m&&r+p[0]>m||t.isInteracting()&&!t.isMoving()&&!t.isRotating()||(r++,d[S]=M))}if(T&&!o[S]){o[S]=1,x&&!f[S]&&(M.cache=!1,h.push({image:x,info:M}),f[S]=1);var A=this._findParentTile(M);if(A){var C=A.info.id;void 0===u[C]&&(u[C]=s.length,s.push(A))}else if(!s.length){var P=this._findChildTiles(M);P.length&&P.forEach((function(t){l[t.info.id]||(c.push(t),l[t.info.id]=1)}))}}}s.length&&(c.length=0,this._childTiles.length=0),this._drawTiles(a,s,c,h),r?this.loadTileQueue(d):i||(t.isAnimating()||!this._parentTiles.length&&!this._childTiles.length||(this._parentTiles=[],this._childTiles=[],this.setToRedraw()),this.completeRender()),this._retireTiles()}else this.completeRender()}else this.completeRender()}},n.isTileCachedOrLoading=function(t){return this.tilesLoading[t]||this.tilesInView[t]||this.tileCache.get(t)},n._drawTiles=function(t,e,n,r){var i=this;e.length&&(e.sort((function(t,e){return Math.abs(e.info.z-i._tileZoom)-Math.abs(t.info.z-i._tileZoom)})),this._parentTiles=e),n.length&&(this._childTiles=n);var o={tiles:t,parentTiles:this._parentTiles,childTiles:this._childTiles};this.onDrawTileStart(o),this._parentTiles.forEach((function(t){return i._drawTileAndCache(t)})),this._childTiles.forEach((function(t){return i._drawTile(t.info,t.image)})),r.forEach((function(t){return i._drawTile(t.info,t.image)}));var a=this.layer,s=this.getMap();if(!a.options.cascadeTiles||s.getPitch()<=s.options.cascadePitches[0])t.forEach((function(t){return i._drawTileAndCache(t)}));else{this.writeZoomStencil();for(var u=!1,c=0,l=t.length;c<l;c++)t[c].info.z!==this._tileZoom?u?this.resumeZoomStencilTest():(this.startZoomStencilTest(),u=!0):u&&this.pauseZoomStencilTest(),this._drawTileAndCache(t[c]);this.endZoomStencilTest()}this.onDrawTileEnd(o)},n.writeZoomStencil=function(){},n.startZoomStencilTest=function(){},n.endZoomStencilTest=function(){},n.pauseZoomStencilTest=function(){},n.resumeZoomStencilTest=function(){},n.onDrawTileStart=function(){},n.onDrawTileEnd=function(){},n._drawTile=function(t,e){e&&this.drawTile(t,e)},n._drawTileAndCache=function(t){t.current=!0,this.tilesInView[t.info.id]=t,this._drawTile(t.info,t.image),this.tileCache.add(t.info.id,t)},n.drawOnInteracting=function(){this.draw()},n.needToRedraw=function(){var e=this.getMap();return e.getPitch()?t.prototype.needToRedraw.call(this):!(!e.isRotating()&&!e.isZooming())||(e.isMoving()?!!this.layer.options.forceRenderOnMoving:t.prototype.needToRedraw.call(this))},n.hitDetect=function(){return!1},n._getLoadLimit=function(){return this.getMap().isInteracting()?this.layer.options.loadingLimitOnInteracting:0},n.isDrawable=function(){return!this.getMap().getPitch()||(console&&console.warn("TileLayer with canvas renderer can't be pitched, use gl renderer ('renderer' : 'gl') instead."),this.clear(),!1)},n.clear=function(){this._retireTiles(!0),this.tileCache.reset(),this.tilesInView={},this.tilesLoading={},this._parentTiles=[],this._childTiles=[],t.prototype.clear.call(this)},n._isLoadingTile=function(t){return!!this.tilesLoading[t]},n.clipCanvas=function(e){return t.prototype.clipCanvas.call(this,e)},n._clipByPitch=function(t){var e=this.getMap();if(e.getPitch()<=e.options.maxVisualPitch)return!1;if(!this.layer.options.clipByPitch)return!1;var n=e.getContainerExtent(),r=e.getDevicePixelRatio();return t.save(),t.strokeStyle="rgba(0, 0, 0, 0)",t.beginPath(),t.rect(0,Math.ceil(n.ymin)*r,Math.ceil(n.getWidth())*r,Math.ceil(n.getHeight())*r),t.stroke(),t.clip(),!0},n.loadTileQueue=function(t){for(var e in t)if(t.hasOwnProperty(e)){var n=t[e],r=this.loadTile(n);void 0===r.loadTime&&(this.tilesLoading[n.id]={image:r,current:!0,info:n})}},n.loadTile=function(t){var e=this.layer.getTileSize(),n=new Image;return n.width=e.width,n.height=e.height,n.onload=this.onTileLoad.bind(this,n,t),n.onerror=this.onTileError.bind(this,n,t),this.loadTileImage(n,t.url),n},n.loadTileImage=function(t,e){var n=this.layer.options.crossOrigin;return p(n)||(t.crossOrigin=n),P(t,[e])},n.abortTileLoading=function(t){t&&(t.onload=ls,t.onerror=ls,t.src=Q)},n.onTileLoad=function(t,e){if(this.layer){var n=e.id;if(this.tilesInView){var r={tile:e,tileImage:t};this.layer.fire("tileload",r),(t=r.tileImage).loadTime=f(),delete this.tilesLoading[n],this._addTileToCache(e,t),this.setToRedraw()}}},n.onTileError=function(t,e){if(this.layer){if(t.onerrorTick=t.onerrorTick||0,this.layer.options.tileRetryCount>t.onerrorTick)return t.onerrorTick++,void(t.src=e.url);if(t instanceof Image){var n=this.layer.options.errorUrl;if(n&&t.src!==n)return void(t.src=n);this.abortTileLoading(t,e)}t.loadTime=0,delete this.tilesLoading[e.id],this._addTileToCache(e,t),this.setToRedraw(),this.layer.fire("tileerror",{tile:e})}},n.drawTile=function(t,e){if(e&&this.getMap()){var n=t.extent2d,r=t.offset,i=os.set(n.xmin-r[0],n.ymax-r[1]),o=t.z,a=t.id,s=this.getMap(),u=this.layer.getTileSize(),c=s.getZoom(),l=this.context,h=s._pointToContainerPoint(i,o,0,as),f=s.getBearing(),d=f||c!==o,p=this.getTileOpacity(e),m=l.globalAlpha;p<1&&(l.globalAlpha=p,this.setToRedraw()),d||h._round();var g=h.x,v=h.y,y=u.width,_=u.height;if(d){if(l.save(),l.translate(g,v),f&&(l.rotate(-f*Math.PI/180),y+=.1,_+=.1),c!==o){var x=s._getResolution(o)/s._getResolution();l.scale(x,x)}g=v=0}if(hn.image(l,e,g,v,y,_),this.layer.options.debug){var b=this.layer.options.debugOutline;l.save(),l.strokeStyle=b,l.fillStyle=b,l.strokeWidth=10,l.font="20px monospace";var w=new me(g,v);hn.rectangle(l,w,{width:y,height:_},1,0),hn.fillText(l,this.getDebugInfo(a),w._add(10,20),b),hn.drawCross(l,g+y/2,v+_/2,2,b),l.restore()}d&&l.restore(),l.globalAlpha!==m&&(l.globalAlpha=m),this.setCanvasUpdated()}},n.getDebugInfo=function(t){var e=t.split("_"),n=e.length;return"x:"+e[n-2]+", y:"+e[n-3]+", z:"+e[n-1]},n._findChildTiles=function(t){var e=this._getLayerOfTile(t.layer);if(!e.options.background)return[];for(var n=this.getMap(),r=[],i=t.extent2d.getMin(),o=t.extent2d.getMax(),a=t.offset,s=e._project(n._pointToPrj(i,t.z,ss),ss),u=e._project(n._pointToPrj(o,t.z,us),us),c=1;c<2;c++)this._findChildTilesAt(r,s,u,e,t.z+c,a);return r},n._findChildTilesAt=function(t,e,n,r,i,o){var a=r.options.zoomOffset,s=r.getId(),u=r.getSpatialReference().getResolution(i+a);if(u)for(var c,l,h=r._getTileConfig().getTileIndex(e,u,o),f=r._getTileConfig().getTileIndex(n,u,o),d=Math.min(h.idx,f.idx),p=Math.max(h.idx,f.idx),m=Math.min(h.idy,f.idy),g=Math.max(h.idy,f.idy),v=d;v<p;v++)for(var y=m;y<g;y++)c=r._getTileId(v,y,i+a,s),this.tileCache.has(c)&&(l=this.tileCache.getAndRemove(c),t.push(l),this.tileCache.add(c,l))},n._findParentTile=function(t){var e=this.getMap(),n=this._getLayerOfTile(t.layer);if(!n.options.background)return null;for(var r=n.getSpatialReference(),i=r.getZoomDirection(),o=n.options.zoomOffset,a=n.options.backgroundZoomDiff,s=t.extent2d.getCenter(),u=t.offset,c=n._project(e._pointToPrj(s,t.z)),l=1;l<=a;l++){var h=t.z-i*l,f=r.getResolution(h+o);if(f){var d=n._getTileConfig().getTileIndex(c,f,u),p=n._getTileId(d.x,d.y,h+o,t.layer);if(this.tileCache.has(p)){var m=this.tileCache.getAndRemove(p);return this.tileCache.add(p,m),m}}}return null},n._getLayerOfTile=function(t){return this.layer.getChildLayer?this.layer.getChildLayer(t):this.layer},n._getCachedTile=function(t){var e=this.tilesInView,n=this.tileCache.getAndRemove(t);if(n){e[t]=n;var r=this.tilesLoading;if(r&&r[t]){r[t].current=!1;var i=r[t],o=i.image,a=i.info;this.abortTileLoading(o,a),delete r[t]}}else n=e[t];return n},n._addTileToCache=function(t,e){this.tilesInView[t.id]={image:e,current:!0,info:t}},n.getTileOpacity=function(t){return this.layer.options.fadeAnimation&&t.loadTime?Math.min(1,(f()-t.loadTime)/(1e3/60*10)):1},n.onRemove=function(){this.clear(),delete this.tileCache,delete this._tilePlaceHolder,t.prototype.onRemove.call(this)},n._markTiles=function(){var t=0,e=0;if(this.tilesLoading)for(var n in this.tilesLoading)this.tilesLoading[n].current=!1,t++;if(this.tilesInView)for(var r in this.tilesInView)this.tilesInView[r].current=!1,e++;return[t,e]},n._retireTiles=function(t){for(var e in this.tilesLoading){var n=this.tilesLoading[e];!t&&n.current||(n.image&&this.abortTileLoading(n.image,n.info),this.deleteTile(n),delete this.tilesLoading[e])}for(var r in this.tilesInView){var i=this.tilesInView[r];i.current||(delete this.tilesInView[r],this.tileCache.has(r)||this.deleteTile(i))}},n.deleteTile=function(t){t&&t.image&&(t.image.onload=null,t.image.onerror=null)},n._generatePlaceHolder=function(t){var e=this.getMap(),n=this.layer.options.placeholder;if(!n||e.getPitch())return null;var r=this.layer.getTileSize(),i=e._getResolution(t)/e._getResolution(),o=this._tilePlaceHolder=this._tilePlaceHolder||hn.createCanvas(1,1,e.CanvasClass);return o.width=r.width*i,o.height=r.height*i,_(n)?n(o):function(t){var e=t.getContext("2d"),n=t.width,r=t.height,i=n/16,o=r/16;e.beginPath();for(var a=0;a<16;a++)e.moveTo(0,a*o),e.lineTo(n,a*o),e.moveTo(a*i,0),e.lineTo(a*i,r);e.strokeStyle="rgba(180, 180, 180, 0.1)",e.lineWidth=1,e.stroke(),e.beginPath();for(var s=[[0,0],[n,0],[0,r],[n,r],[0,0],[0,r],[n,0],[n,r],[0,r/2],[n,r/2],[n/2,0],[n/2,r]],u=1;u<s.length;u+=2)e.moveTo(s[u-1][0],s[u-1][1]),e.lineTo(s[u][0],s[u][1]);e.lineWidth=4,e.stroke()}(o),o},e}(mr);function ls(){return!1}Ta.registerRenderer("canvas",cs);var hs=new me(0,0),fs=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.isDrawable=function(){return!0},n.needToRedraw=function(){var e=this.getMap();return!(!this._gl()||e.getPitch()||!e.isZooming()||e.isMoving()||e.isRotating())||t.prototype.needToRedraw.call(this)},n.drawTile=function(e,n){var r=this.getMap();if(e&&r&&n){var i=e._glScale=e._glScale||r.getGLScale(e.z),o=this.layer.getTileSize(),a=o.width,s=o.height;if(!1!==e.cache&&this._bindGLBuffer(n,a,s),this._gl()){var u=e.extent2d,c=e.offset,l=hs.set(u.xmin-c[0],e.extent2d.ymax-c[1]),h=l.x*i,f=l.y*i,d=this.getTileOpacity(n),p=null;this.layer.options.debug&&(p=this.getDebugInfo(e.id)),this.drawGLImage(n,h,f,a,s,i,d,p),d<1?this.setToRedraw():this.setCanvasUpdated()}else t.prototype.drawTile.call(this,e,n)}},n.writeZoomStencil=function(){var t=this.gl;t.stencilFunc(t.ALWAYS,1,255),t.stencilOp(t.KEEP,t.KEEP,t.REPLACE)},n.startZoomStencilTest=function(){var t=this.gl;t.stencilOp(t.KEEP,t.KEEP,t.KEEP),t.stencilFunc(t.EQUAL,0,255)},n.endZoomStencilTest=function(){this.pauseZoomStencilTest()},n.pauseZoomStencilTest=function(){var t=this.gl;t.stencilFunc(t.ALWAYS,1,255)},n.resumeZoomStencilTest=function(){var t=this.gl;t.stencilFunc(t.EQUAL,0,255)},n._bindGLBuffer=function(t,e,n){t.glBuffer||(t.glBuffer=this.bufferTileData(0,0,e,n))},n.loadTileImage=function(t,e){var n=this.layer.options.crossOrigin;t.crossOrigin=null!==n?n:"",t.src=e},n.onCanvasCreate=function(){this.canvas.gl&&this.canvas.gl.wrap||this.createCanvas2()},n.createContext=function(){t.prototype.createContext.call(this),this.createGLContext()},n.resizeCanvas=function(e){this.canvas&&(t.prototype.resizeCanvas.call(this,e),this.resizeGLCanvas())},n.clearCanvas=function(){this.canvas&&(t.prototype.clearCanvas.call(this),this.clearGLCanvas())},n.getCanvasImage=function(){if(!this._gl()||!this.canvas2)return t.prototype.getCanvasImage.call(this);var e=t.prototype.getCanvasImage.call(this);return e&&(e.image=this.canvas2),e},n._gl=function(){if(this.canvas.gl&&this.canvas.gl.wrap)return!0;var t=this.getMap();return t&&(t.getPitch()||t.getBearing())||this.layer&&!!this.layer.options.fragmentShader},n.deleteTile=function(e){t.prototype.deleteTile.call(this,e),e&&e.image&&this.disposeImage(e.image),delete e.image},n.onRemove=function(){t.prototype.onRemove.call(this),this.removeGLCanvas()},e}(Na(cs));function ds(t){var e=this.layer.getTileSize(),n=this.canvas.constructor,r=this.getMap(),i=r.getDevicePixelRatio(),o=hn.createCanvas(e.width*i,e.height*i,n);o.layer=this.layer;var a=this,s=new me(t.extent2d.xmin,t.extent2d.ymax),u=new Vn(r.pointToCoordinate(s),r.pointToCoordinate(s.add(e.width,e.height)),r.getProjection());return this.layer.drawTile(o,{url:t.url,point:s,center:r.pointToCoordinate(s.add(e.width/2,e.height/2)),extent:u,z:t.z,x:t.x,y:t.y},(function(e){e?a.onTileError(o,t):a.onTileLoad(o,t)})),o}Ta.registerRenderer("gl",fs);var ps=function(t){function e(){return t.apply(this,arguments)||this}return fe(e,t),e.prototype.loadTile=function(){return ds.apply(this,arguments)},e}(cs),ms=function(t){function e(){return t.apply(this,arguments)||this}return fe(e,t),e.prototype.loadTile=function(){return ds.apply(this,arguments)},e}(fs);La.registerRenderer("canvas",ps),La.registerRenderer("gl",ms);var gs=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.checkResources=function(){var t=this._geosToCheck;if(this._resourceChecked||t||(t=this.layer._geoList),!U(t))return[];for(var e=[],n={},r=t.length-1;r>=0;r--){var i=t[r]._getExternalResources();if(i.length)if(this.resources)for(var o=0;o<i.length;o++){var a=i[o][0];this.resources.isResourceLoaded(i[o])||n[a]||(e.push(i[o]),n[a]=1)}else e.push.apply(e,i)}return this._resourceChecked=!0,delete this._geosToCheck,e},n.render=function(){return this.layer._sortGeometries(),t.prototype.render.apply(this,arguments)},n._addGeoToCheckRes=function(t){t&&(Array.isArray(t)||(t=[t]),this._geosToCheck||(this._geosToCheck=[]),I(this._geosToCheck,t))},n.onGeometryAdd=function(t){this._addGeoToCheckRes(t),vs(this)},n.onGeometryRemove=function(){vs(this)},n.onGeometrySymbolChange=function(t){this._addGeoToCheckRes(t.target),vs(this)},n.onGeometryShapeChange=function(){vs(this)},n.onGeometryPositionChange=function(){vs(this)},n.onGeometryZIndexChange=function(){vs(this)},n.onGeometryShow=function(){vs(this)},n.onGeometryHide=function(){vs(this)},n.onGeometryPropertiesChange=function(){vs(this)},e}(mr);function vs(t){t.layer.options.drawImmediate&&t.render(),t.setToRedraw()}var ys=new Zn,_s=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.checkResources=function(){var e=this,n=t.prototype.checkResources.apply(this,arguments),r=this.layer.getStyle();return r&&(Array.isArray(r)||(r=[r]),r.forEach((function(t){for(var r=Pt(t.symbol,!0),i=0,o=r.length;i<o;i++)e.resources.isResourceLoaded(r[i])||n.push(r[i])}))),n},n.needToRedraw=function(){var e=this.getMap();return!(!e.isInteracting()||!this.layer.options.enableAltitude)||!(e.isZooming()&&!e.isRotating()&&!e.getPitch()&&!this._hasPoint&&this.layer.constructor===eo)&&t.prototype.needToRedraw.call(this)},n.draw=function(){if(this.getMap()){if(!this.layer.isVisible()||this.layer.isEmpty())return this.clearCanvas(),void this.completeRender();this.prepareCanvas(),this.drawGeos(),this.completeRender()}},n.isBlank=function(){return!!this.context&&!this.context.canvas._drawn},n.drawOnInteracting=function(){if(this._geosToDraw){this._updateDisplayExtent();var t=this.getMap(),e=this.layer.getCount(),n=this.getMap().getResolution();(t.isZooming()&&t.options.seamlessZoom&&void 0!==this._drawnRes&&n>1.5*this._drawnRes&&this._geosToDraw.length<e||t.isMoving()||t.isInteracting())&&(this.prepareToDraw(),this.forEachGeo(this.checkGeo,this),this._drawnRes=n);for(var r=0,i=this._geosToDraw.length;r<i;r++){var o=this._geosToDraw[r];o.isVisible()&&o._paint(this._displayExtent)}}},n.show=function(){this.layer.forEach((function(t){t._repaint()})),t.prototype.show.apply(this,arguments)},n.forEachGeo=function(t,e){this.layer.forEach(t,e)},n.drawGeos=function(){this._drawnRes=this.getMap().getResolution(),this._updateDisplayExtent(),this.prepareToDraw(),this.forEachGeo(this.checkGeo,this);for(var t=0,e=this._geosToDraw.length;t<e;t++)this._geosToDraw[t]._paint()},n.prepareToDraw=function(){this._hasPoint=!1,this._geosToDraw=[]},n.checkGeo=function(t){if(t&&t.isVisible()&&t.getMap()&&t.getLayer()&&t.getLayer().isCanvasRender()){var e=t._getPainter(),n=e.get2DExtent(this.resources,ys);n&&n.intersects(this._displayExtent)&&(e.hasPoint()&&(this._hasPoint=!0),this._geosToDraw.push(t))}},n.onZoomEnd=function(){delete this.canvasExtent2D,t.prototype.onZoomEnd.apply(this,arguments)},n.onRemove=function(){this.forEachGeo((function(t){t.onHide()})),delete this._geosToDraw},n.onGeometryPropertiesChange=function(e){e&&this.layer._styleGeometry(e.target),t.prototype.onGeometryPropertiesChange.call(this,e)},n._updateDisplayExtent=function(){var t=this.canvasExtent2D;if(this._maskExtent){if(!this._maskExtent.intersects(t))return void this.completeRender();t=t.intersection(this._maskExtent)}this._displayExtent=t},n.identify=function(t,e){void 0===e&&(e={});var n=this._geosToDraw;return n?this.layer._hitGeos(n,t,e):[]},e}(gs);eo.registerRenderer("canvas",_s);var xs=function(t){function e(e){var n;return(n=t.call(this)||this).map=e,n._handlerQueue={},n}fe(e,t);var n=e.prototype;return n.callInNextFrame=function(t){this._handlerQueue.push(t)},n.executeFrameCallbacks=function(){var t=this._handlerQueue;this._handlerQueue=[];for(var e=0,n=t.length;e<n;e++)t[e]()},n.offsetPlatform=function(t,e){if(!this.map._panels.front)return this;if(!e&&0===t.x&&0===t.y)return this;var n=this.map._panels,r=this._frontCount=n.back.layerDOM.childElementCount,i=this._backCount=n.front.layerDOM.childElementCount,o=this._uiCount=n.front.uiDOM.childElementCount;if(r||i||o){var a=this.map.offsetPlatform();a=t?a.add(t)._round():a.round(),i&&Ve(n.back,a),(r||o)&&Ve(n.front,a)}return this},n.domChanged=function(){var t=this.map._panels;if(!t.front)return!1;var e=t.back.layerDOM.childElementCount;if(void 0===this._frontCount||this._frontCount!==e)return!0;var n=t.front.layerDOM.childElementCount;if(void 0===this._backCount||this._backCount!==n)return!0;var r=t.front.uiDOM.childElementCount;return void 0===this._uiCount||this._uiCount!==r},n.resetContainer=function(){if(this.map&&(this.map._resetMapViewPoint(),this.map._panels.front)){var t=new me(0,0);Ve(this.map._panels.back,t),Ve(this.map._panels.front,t)}},n.onZoomEnd=function(){this.resetContainer()},n.onLoad=function(){this._frameLoop()},e}(Mn),bs=function(t){function e(e){var n;return(n=t.call(this,e)||this)._containerIsCanvas=!!e._containerDOM.getContext,n._thisVisibilitychange=n._onVisibilitychange.bind(de(de(n))),n._registerEvents(),n._loopTime=0,n}fe(e,t);var n=e.prototype;return n.load=function(){this.initContainer()},n.renderFrame=function(t){if(!this.map)return!1;delete this._isViewChanged;var e=this.map;e._fireEvent("framestart"),this.updateMapDOM();var n=this._getAllLayerToRender();return this.drawLayers(n,t),this.drawLayerCanvas(n)&&this._drawCenterCross(),e._fireEvent("frameend"),this._recordView(),this._mapview=this._getMapView(),delete this._spatialRefChanged,this._fireLayerLoadEvents(),this.executeFrameCallbacks(),this._canvasUpdated=!1,!0},n.updateMapDOM=function(){var t=this.map;if(!t.isZooming()){var e=t._getViewPointFrameOffset();e?t.offsetPlatform(e):this.domChanged()&&this.offsetPlatform(null,!0)}},n.drawLayers=function(t,e){for(var n=this.map,r=n.isInteracting(),i=[],o=[],a=n.options.fpsOnInteracting||0,s=0===a?0:1e3/a,u=this.map.options.layerCanvasLimitOnInteracting,c=t.length,l=n.getBaseLayer(),h=0,f=0;f<c;f++){var d=t[f];if(d.isVisible()){var p=d.isCanvasRender();p&&i.push(d.getId());var m=d._getRenderer();if(m){var g=this._checkLayerRedraw(d);p&&m.isCanvasUpdated()&&(g||o.push(d.getId()),this.setLayerCanvasUpdated());var v=m.__zoomTransformMatrix;if(delete m.__zoomTransformMatrix,g){if(r&&p){if(u>0&&c-1-f>u&&d!==l){d._getRenderer().clearCanvas();continue}h+=this._drawCanvasLayerOnInteracting(d,h,s,e)}else r&&m.drawOnInteracting?(m.prepareRender&&m.prepareRender(),m.checkAndDraw?m.checkAndDraw(m.drawOnInteracting,this._eventParam,e):m.drawOnInteracting(this._eventParam,e)):(m.render(e),p&&v&&m.isLoadingResource()&&(m.__zoomTransformMatrix=v));p&&(o.push(d.getId()),this.setLayerCanvasUpdated())}else p&&r&&(n.isZooming()&&!n.getPitch()?(m.prepareRender(),m.__zoomTransformMatrix=this._zoomMatrix):(n.getPitch()||n.isRotating())&&m.clearCanvas())}}}var y=this._canvasIds||[],_=this._updatedIds||[];if(this._canvasIds=i,this._updatedIds=o,!this.isLayerCanvasUpdated()){var x="---";y.join(x)===i.join(x)&&_.join(x)===o.join(x)||this.setLayerCanvasUpdated()}},n._checkLayerRedraw=function(t){if(this.isSpatialReferenceChanged())return!0;var e=this.map,n=t._getRenderer();return t.isCanvasRender()?n.testIfNeedRedraw():!(!n.needToRedraw||!n.needToRedraw())||e.isInteracting()||this.isViewChanged()},n._drawCanvasLayerOnInteracting=function(t,e,n,r){var i=this.map,o=t._getRenderer(),a=o.getDrawTime(),s=0===n||n>0&&e+a<=n;if(o.mustRenderOnInteracting&&o.mustRenderOnInteracting())o.render(r);else{if(o.drawOnInteracting&&(t===i.getBaseLayer()||s||i.isZooming()&&t.options.forceRenderOnZooming||i.isMoving()&&t.options.forceRenderOnMoving||i.isRotating()&&t.options.forceRenderOnRotating))return o.prepareRender(),o.prepareCanvas(),o.checkAndDraw?o.checkAndDraw(o.drawOnInteracting,this._eventParam,r):o.drawOnInteracting(this._eventParam,r),a;!i.isZooming()||i.getPitch()||i.isRotating()?(i.getPitch()||i.isRotating())&&o.clearCanvas():(o.prepareRender(),o.__zoomTransformMatrix=this._zoomMatrix)}return o.drawOnInteracting&&!s&&o.onSkipDrawOnInteracting(this._eventParam,r),0},n._fireLayerLoadEvents=function(){if(this._updatedIds&&this._updatedIds.length>0){var t=this.map;this._updatedIds.reverse().forEach((function(e){var n=t.getLayer(e);if(n){var r=n._getRenderer();r&&r.isRenderComplete()&&n.fire("layerload")}}))}},n.isLayerCanvasUpdated=function(){return this._canvasUpdated},n.setLayerCanvasUpdated=function(){this._canvasUpdated=!0},n.drawLayerCanvas=function(t){var e=this.map;if(!e)return!1;if(!this.isLayerCanvasUpdated()&&!this.isViewChanged())return!1;this.canvas||this.createCanvas(),e._fireEvent("renderstart",{context:this.context}),this._updateCanvasSize()||this.clearCanvas();for(var n,r=e.isInteracting(),i=e.options.layerCanvasLimitOnInteracting,o=t.length,a=[],s=0;s<o;s++)if(t[s].isVisible()&&t[s].isCanvasRender()&&t[s]._getRenderer()){var u=this._getLayerImage(t[s]);u&&u.image&&(t[s]===e.getBaseLayer()?n=[t[s],u]:a.push([t[s],u]))}n&&(this._drawLayerCanvasImage(n[0],n[1]),this._drawFog()),o=a.length;for(var c=r&&i>=0&&o>i?o-i:0;c<o;c++)this._drawLayerCanvasImage(a[c][0],a[c][1]);return e._fireEvent("renderend",{context:this.context}),!0},n.setToRedraw=function(){for(var t=this._getAllLayerToRender(),e=0,n=t.length;e<n;e++){var r=t[e].getRenderer();r&&r.canvas&&r.setToRedraw&&r.setToRedraw()}},n.updateMapSize=function(t){if(t&&!this._containerIsCanvas){var e=t.width+"px",n=t.height+"px",r=this.map._panels;r.mapWrapper.style.width=e,r.mapWrapper.style.height=n,this._updateCanvasSize()}},n.getMainPanel=function(){return this.map?this._containerIsCanvas?this.map._containerDOM:this.map._panels?this.map._panels.mapWrapper:null:null},n.toDataURL=function(t){return this.canvas?this.canvas.toDataURL(t):null},n.remove=function(){he.webgl&&"undefined"!=typeof document&&Be(document,"visibilitychange",this._thisVisibilitychange),this._resizeInterval&&clearInterval(this._resizeInterval),delete this.context,delete this.canvas,delete this.map,delete this._spatialRefChanged,this._cancelFrameLoop()},n.hitDetect=function(t){var e=this.map;if(e&&e.options.hitDetect&&!e.isInteracting()){for(var n=e._getLayers(),r="default",i=e.options.hitDetectLimit||0,o=0,a=n.length-1;a>=0;a--){var s=n[a];if(!(!s.options.hitDetect||s.isEmpty&&s.isEmpty())){var u=s._getRenderer();if(u&&u.hitDetect&&(!u.isBlank||!u.isBlank())){if("default"!==s.options.cursor&&u.hitDetect(t)){r=s.options.cursor||"pointer";break}if(o++,i>0&&o>i)break}}}e._trySetCursor(r)}},n._getLayerImage=function(t){var e=t._getRenderer();return e.getCanvasImage?e.getCanvasImage():null},n.initContainer=function(){var t=this.map._panels;function e(e,n,r,i){var o=je("div",n);return r&&(o.style.cssText=r),t[e]=o,i||We(o),o}var n=this.map._containerDOM;if(!this._containerIsCanvas){n.innerHTML="";var r="position:absolute;top:0px;left:0px;",i=e("mapWrapper","maptalks-wrapper","position:absolute;overflow:hidden;",!0),o=e("allLayers","maptalks-all-layers",r+"padding:0px;margin:0px;z-index:0;overflow:visible;",!0),a=e("backStatic","maptalks-back-static",r+"z-index:0;",!0),s=e("back","maptalks-back",r+"z-index:1;"),u=e("backLayer","maptalks-back-layer",r),c=e("canvasContainer","maptalks-canvas-layer",r+"border:none;z-index:2;"),l=e("frontStatic","maptalks-front-static",r+"z-index:3;",!0),h=e("front","maptalks-front",r+"z-index:4;",!0),f=e("frontLayer","maptalks-front-layer",r+"z-index:0;"),d=e("ui","maptalks-ui",r+"border:none;z-index:1;",!0),p=e("control","maptalks-control","z-index:1",!0);n.appendChild(i),o.appendChild(a),s.appendChild(u),s.layerDOM=u,o.appendChild(s),o.appendChild(c),h.appendChild(f),h.layerDOM=f,h.uiDOM=d,o.appendChild(l),o.appendChild(h),h.appendChild(d),i.appendChild(o),i.appendChild(p),this.createCanvas(),this.resetContainer();var m=this.map._getContainerDomSize();this.updateMapSize(m)}},n.isViewChanged=function(){if(void 0!==this._isViewChanged)return this._isViewChanged;var t=this._mapview,e=this._getMapView();return this._isViewChanged=!t||!K(t,e),this._isViewChanged},n._recordView=function(){var t=this.map;!t._onViewChange||t.isInteracting()||t.isAnimating()||K(t.getView(),t._getCurrentView())||t._onViewChange(t.getView())},n.isSpatialReferenceChanged=function(){return this._spatialRefChanged},n._getMapView=function(){var t=this.map,e=t._getPrjCenter();return{x:e.x,y:e.y,zoom:t.getZoom(),pitch:t.getPitch(),bearing:t.getBearing(),width:t.width,height:t.height}},n._frameLoop=function(t){var e=this;this.map?(this.renderFrame(t),this._animationFrame=T((function(t){e._frameLoop(t)}))):this._cancelFrameLoop()},n._cancelFrameLoop=function(){this._animationFrame&&E(this._animationFrame)},n._drawLayerCanvasImage=function(t,e){var n=this.context,r=e.point.round(),i=this.map.getDevicePixelRatio();1!==i&&r._multi(i);var o=e.image,a=o.width,s=o.height;if(!(r.x+a<=0||r.y+s<=0)){var u=t.options.opacity;if(m(u)||(u=1),!(u<=0)){var c=e.opacity;if(m(c)||(c=1),!(c<=0)){var l=n.globalAlpha;u<1&&(n.globalAlpha*=u),c<1&&(n.globalAlpha*=c),t.options.cssFilter&&(n.filter=t.options.cssFilter);var h=t.getRenderer(),f=h.__zoomTransformMatrix,d=h.clipCanvas(this.context);f&&(n.save(),n.setTransform.apply(n,f)),n.drawImage(o,0,0,a,s,r.x,r.y,a,s),f&&n.restore(),d&&n.restore(),"none"!==n.filter&&(n.filter="none"),n.globalAlpha=l}}}},n._drawCenterCross=function(){var t=this.map.options.centerCross;if(t){var e=this.context,n=new me(this.canvas.width/2,this.canvas.height/2);_(t)?t(e,n):hn.drawCross(this.context,n.x,n.y,2,"#f00")}},n._drawContainerExtent=function(){var t=this.map.options.cascadePitches,e=this.map.height-this.map._getVisualHeight(t[0]),n=this.map.height-this.map._getVisualHeight(t[1]),r=this.map.getContainerExtent(),i=this.context;i.beginPath(),i.moveTo(0,r.ymin),i.lineTo(r.xmax,r.ymin),i.stroke(),i.beginPath(),i.moveTo(0,e),i.lineTo(r.xmax,e),i.stroke(),i.beginPath(),i.moveTo(0,n),i.lineTo(r.xmax,n),i.stroke()},n._drawFog=function(){var t=this.map;if(!(t.getPitch()<=t.options.maxVisualPitch)&&t.options.fog){var e=t.getDevicePixelRatio(),n=this.context,r=t.getContainerExtent(),i=(t.height-t._getVisualHeight(75))*e;i<0&&(i=0);var o=r.ymin*e,a=Math.ceil(o-i),s=t.options.fogColor.join(),u=n.createLinearGradient(0,i,0,o+30),c=1-30/(a+30);u.addColorStop(0,"rgba("+s+", 0)"),u.addColorStop(.3,"rgba("+s+", 0.3)"),u.addColorStop(c,"rgba("+s+", 1)"),u.addColorStop(1,"rgba("+s+", 0)"),n.beginPath(),n.fillStyle=u,n.fillRect(0,i,Math.ceil(r.getWidth())*e,Math.ceil(a+30))}},n._getAllLayerToRender=function(){return this.map._getLayers()},n.clearCanvas=function(){this.canvas&&hn.clearRect(this.context,0,0,this.canvas.width,this.canvas.height)},n._updateCanvasSize=function(){if(!this.canvas||this._containerIsCanvas)return!1;var t=this.map,e=t.getSize(),n=this.canvas,r=t.getDevicePixelRatio();return(e.width*r!==n.width||e.height*r!==n.height)&&(n.height=r*e.height,n.width=r*e.width,n.style&&(n.style.width=e.width+"px",n.style.height=e.height+"px"),!0)},n.createCanvas=function(){this._containerIsCanvas?this.canvas=this.map._containerDOM:(this.canvas=je("canvas"),this._updateCanvasSize(),this.map._panels.canvasContainer.appendChild(this.canvas)),this.context=this.canvas.getContext("2d")},n._checkSize=function(){this.map&&!this.map.isInteracting()&&(Ze(this.map._containerDOM),this.map.checkSize())},n._setCheckSizeInterval=function(t){var e=this;clearInterval(this._resizeInterval),this._checkSizeInterval=t,this._resizeInterval=setInterval((function(){!e.map||e.map.isRemoved()?clearInterval(e._resizeInterval):e._checkSize()}),this._checkSizeInterval)},n._registerEvents=function(){var t=this,e=this.map;e.options.checkSize&&!A&&"undefined"!=typeof window&&this._setCheckSizeInterval(e.options.checkSizeInterval),he.mobile||e.on("_mousemove",this._onMapMouseMove,this),e.on("_dragrotatestart _dragrotating _dragrotateend _movestart _moving _moveend _zoomstart",(function(e){t._eventParam=e})),e.on("_zooming",(function(n){e.getPitch()||(t._zoomMatrix=n.matrix.container),t._eventParam=n})),e.on("_zoomend",(function(e){t._eventParam=e,delete t._zoomMatrix})),e.on("_spatialreferencechange",(function(){t._spatialRefChanged=!0})),he.webgl&&"undefined"!=typeof document&&Fe(document,"visibilitychange",this._thisVisibilitychange,this)},n._onMapMouseMove=function(t){var e=this,n=this.map;!n.isInteracting()&&n.options.hitDetect&&(this._hitDetectFrame&&E(this._hitDetectFrame),this._hitDetectFrame=T((function(){e.hitDetect(t.containerPoint)})))},n._getCanvasLayers=function(){return this.map._getLayers((function(t){return t.isCanvasRender()}))},n._onVisibilitychange=function(){"visible"===document.visibilityState&&this.setToRedraw()},e}(xs);ii.registerRenderer("canvas",bs),ii.mergeOptions({fog:!1,fogColor:[233,233,233]});var ws=Object.freeze({ResourceCache:gr,CanvasRenderer:mr,ImageGLRenderable:Na,MapRenderer:xs,MapCanvasRenderer:bs,Renderable:pr,ImageLayerCanvasRenderer:Ua,ImageLayerGLRenderer:Wa,TileLayerCanvasRenderer:cs,TileLayerGLRenderer:fs,CanvasTileLayerCanvasRenderer:ps,CanvasTileLayerGLRenderer:ms,OverlayLayerCanvasRenderer:gs,VectorLayerCanvasRenderer:_s,CanvasLayerRenderer:Va}),Ms={_getRenderPoints:function(){return[[this._getCenter2DPoint(this.getMap().getGLZoom())],null]}};Mi.include(Ms),ji.include(Ms),Di.include(Ms),Ni.include(Ms),zi.include({_getRenderPoints:function(t){var e=this.getMap();if("vertex"===t){for(var n=this._trimRing(this.getShell()),r=[],i=0,o=n.length;i<o;i++)r.push(e.coordToPoint(n[i],e.getGLZoom()));return[r,null]}return[[e.coordToPoint(this.getCenter(),e.getGLZoom())],null]}});var Ss={_getRenderPoints:function(t){var e,n=this.getMap(),r=n.getGLZoom(),i=null;if("point"===t)(e=this._getPath2DPoints(this._getPrjCoordinates(),!1,r))&&e.length>0&&Array.isArray(e[0])&&(e=e[0].concat(e[1]));else if("vertex"===t)if(i=[],(e=this._getPath2DPoints(this._getPrjCoordinates(),!1,r))&&e.length>0&&Array.isArray(e[0])){for(var o=0,a=e.length;o<a;o++)for(var s=0,u=e[o].length;s<u;s++)0===s?i.push([e[o][s],e[o][s+1]]):i.push([e[o][s-1],e[o][s]]);e=e[0].concat(e[1])}else for(var c=0,l=e.length;c<l;c++)0===c?i.push([e[c],e[c+1]]):i.push([e[c-1],e[c]]);else if("line"===t){e=[],i=[];var h=this._getPath2DPoints(this._getPrjCoordinates(),!1,r);if(h.length>0&&Array.isArray(h[0]))for(var f,d=1,p=h.length;d<p;d++){f=h[d],this instanceof bi&&f.length>0&&!f[0].equals(f[f.length-1])&&f.push(f[0]);for(var m=1,g=f.length;m<g;m++)e.push(f[m].add(f[m-1])._multi(.5)),i.push([f[m-1],f[m]])}else{this instanceof bi&&h.length>0&&!h[0].equals(h[h.length-1])&&h.push(h[0]);for(var v=1,y=h.length;v<y;v++)e.push(h[v].add(h[v-1])._multi(.5)),i.push([h[v-1],h[v]])}}else if("vertex-first"===t){var _=this._getPrjCoordinates();e=_.length?[n._prjToPoint(_[0],r)]:[],i=_.length?[[n._prjToPoint(_[0],r),n._prjToPoint(_[1],r)]]:[]}else if("vertex-last"===t){var x=this._getPrjCoordinates(),b=x.length;e=b?[n._prjToPoint(x[b-1],r)]:[];var w=b-1,M=b>1?b-2:b-1;i=b?[[n._prjToPoint(x[M],r),n._prjToPoint(x[w],r)]]:[]}else{var S=this._getProjection().project(this.getCenter());e=[n._prjToPoint(S,r)]}return[e,i]}};Ti.include(Ss),bi.include(Ss),Kr.include({_redrawWhenPitch:function(){return!1},_redrawWhenRotate:function(){return!1}});var Ts={_redrawWhenPitch:function(){return!0},_redrawWhenRotate:function(){return this instanceof ji||this instanceof Ni},_paintAsPath:function(){var t=this.getMap();return this.getAltitude()>0||t.getPitch()||this instanceof ji&&t.getBearing()},_getPaintParams:function(){var t=this.getMap();if(this._paintAsPath())return bi.prototype._getPaintParams.call(this,!0);var e=this._getPrjCoordinates(),n=t._prjToPoint(e,t.getGLZoom()),r=this._getRenderSize(n);return[n].concat(r)},_paintOn:function(){return this._paintAsPath()?hn.polygon.apply(hn,arguments):hn.ellipse.apply(hn,arguments)},_getRenderSize:function(t){var e=this.getMap(),n=e.getGLZoom(),r=this._getPrjExtent(),i=e._prjToPoint(r.getMin(),n),o=e._prjToPoint(r.getMax(),n);return[Math.abs(o.x-i.x)/2,Math.abs(o.y-t.y),Math.abs(t.y-i.y)]}};ji.include(Ts),Di.include(Ts),zi.include({_getPaintParams:function(){var t=this.getMap().getGLZoom(),e=this._getPrjShell();return[this._getPath2DPoints(e,!1,t)]},_paintOn:hn.polygon}),Ni.include(Ts,{_redrawWhenPitch:function(){return!0},_getPaintParams:function(){if(this._paintAsPath())return bi.prototype._getPaintParams.call(this,!0);var t=this.getMap(),e=t._prjToPoint(this._getPrjCoordinates(),t.getGLZoom());return[e,this._getRenderSize(e)[0],[this.getStartAngle(),this.getEndAngle()]]},_paintOn:function(){if(this._paintAsPath())return hn.polygon.apply(hn,arguments);var t=this.getMap().getBearing(),e=arguments;return t&&(e[3]=e[3].slice(0),e[3][0]+=t,e[3][1]+=t),hn.sector.apply(hn,e)}}),_i.include({_paintAsPath:function(){return!0}}),Ti.include({arrowStyles:{classic:[3,4]},_getArrowShape:function(t,e,n,r,i){if(!t||!e||t.equals(e))return null;i||(i=0);var o,a=n*r[0],s=n*r[1]+i,u=a/2+i;(o=e.nextCtrlPoint||e.prevCtrlPoint?e.prevCtrlPoint?e.sub(new me(e.prevCtrlPoint)):e.sub(new me(e.nextCtrlPoint)):e.sub(t))._unit();var c=e.sub(o.multi(s));o._perp();var l=c.add(o.multi(u));return o._multi(-1),[l,e,c.add(o.multi(u)),l]},_getPaintParams:function(){var t=this._getPrjCoordinates();return[this._getPath2DPoints(t,!1,this.getMap().getGLZoom())]},_paintOn:function(t,e,n,r,i){this.options.smoothness?hn.paintSmoothLine(t,e,n,this.options.smoothness,!1,this._animIdx,this._animTailRatio):hn.path(t,e,n,null,i),this._paintArrow(t,e,n)},_getArrowPlacement:function(){return this.options.arrowPlacement},_getArrowStyle:function(){var t=this.options.arrowStyle;return t?Array.isArray(t)?t:this.arrowStyles[t]:null},_getArrows:function(t,e,n){var r=this._getArrowStyle();if(!r||t.length<2)return[];for(var i=t.length>0&&Array.isArray(t[0])?t:[t],o=this._getArrowPlacement(),a=[],s=this.getMap(),u=s.coordToContainerPoint(this.getFirstCoordinate()),c=s.coordToContainerPoint(this.getLastCoordinate()),l=i.length-1;l>=0;l--){if("vertex-first"===o||"vertex-firstlast"===o&&i[l][0].closeTo(u,.01)){var h=this._getArrowShape(i[l][1],i[l][0],e,r,n);h&&a.push(h)}if("vertex-last"===o||"vertex-firstlast"===o&&i[l][i[l].length-1].closeTo(c,.01)){var f=this._getArrowShape(i[l][i[l].length-2],i[l][i[l].length-1],e,r,n);f&&a.push(f)}else"point"===o&&this._getArrowPoints(a,i[l],e,r,n)}return a},_getArrowPoints:function(t,e,n,r,i){for(var o=0,a=e.length-1;o<a;o++){var s=this._getArrowShape(e[o],e[o+1],n,r,i);s&&t.push(s)}},_paintArrow:function(t,e,n){var r=this._getInternalSymbol().lineWidth;(!m(r)||r<3)&&(r=3);var i=this._getArrows(e,r);if(i.length){t.setLineDash&&t.setLineDash([]);for(var o=i.length-1;o>=0;o--)t.fillStyle=t.strokeStyle,hn.polygon(t,i[o],n,n)}}}),bi.include({_getPaintParams:function(t){var e=this.getMap().getGLZoom(),n=this._getPrjShell(),r=this._getPath2DPoints(n,t,e),i=r.length>0&&Array.isArray(r[0]);i&&(r=[[r[0]],[r[1]]]);var o=this._getPrjHoles(),a=[];if(o&&o.length>0){for(var s=this._simplified,u=0;u<o.length;u++){var c=this._getPath2DPoints(o[u],t,e);Array.isArray(c)&&i?Array.isArray(c[0])?(r[0].push(c[0]),r[1].push(c[1])):r[0].push(c):a.push(c)}s&&(this._simplified=s)}return i||I(r=[r],a),[r]},_paintOn:function(t,e,n,r,i){hn.polygon(t,e,n,r,i,this.options.smoothness)}}),ii.VERSION="0.49.4"}.call(this,n("eef6"),n("2409"))},f869:function(t,e){t.exports="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView},f97a:function(t,e,n){var r=n("ca14"),i=n("c7e7"),o=n("081e"),a=n("41a4"),s=n("53b8"),u=n("c813"),c=s("IE_PROTO"),l=r.Object,h=l.prototype;t.exports=u?l.getPrototypeOf:function(t){var e=a(t);if(i(e,c))return e[c];var n=e.constructor;return o(n)&&e instanceof n?n.prototype:e instanceof l?h:null}},fc50:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAYAAAAHCAIAAACk8qu6AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA0ppVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDIxIDc5LjE1NTc3MiwgMjAxNC8wMS8xMy0xOTo0NDowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6RTM3RTZFNDFBOTZDMTFFNUE2QTA4M0M3MDI4QUVDMTQiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6RTM3RTZFNDBBOTZDMTFFNUE2QTA4M0M3MDI4QUVDMTQiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTQgKFdpbmRvd3MpIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9ImFkb2JlOmRvY2lkOnBob3Rvc2hvcDo3ZmI2MGZkMi1hOTZjLTExZTUtYWU4Yi1kYzQ2ODQxNzA1ZmIiIHN0UmVmOmRvY3VtZW50SUQ9ImFkb2JlOmRvY2lkOnBob3Rvc2hvcDo3ZmI2MGZkMi1hOTZjLTExZTUtYWU4Yi1kYzQ2ODQxNzA1ZmIiLz4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz6Qths+AAAAgElEQVR42iSNMQ4EERiFrd3KKHEBKkeYYziAxAXVCiq9SkPpDMQ0s9k/s694yZd8eQ/NOccY3yettfu+31LKnLMQopQSQsAYv2qt3ntQEELHcVhrsdZaKYWenOfJOf/EGHvvhJDrulJKjDG81qKUOueMMSACIljZe/8fgaF/AgwARJdHBal88EIAAAAASUVORK5CYII="},fdf1:function(t,e,n){var r=n("c252"),i=n("41a4"),o=Math.floor,a=r("".charAt),s=r("".replace),u=r("".slice),c=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,l=/\$([$&'`]|\d{1,2})/g;t.exports=function(t,e,n,r,h,f){var d=n+t.length,p=r.length,m=l;return void 0!==h&&(h=i(h),m=c),s(f,m,(function(i,s){var c;switch(a(s,0)){case"$":return"$";case"&":return t;case"`":return u(e,0,n);case"'":return u(e,d);case"<":c=h[u(s,1,-1)];break;default:var l=+s;if(0===l)return i;if(l>p){var f=o(l/10);return 0===f?i:f<=p?void 0===r[f-1]?a(s,1):r[f-1]+a(s,1):i}c=r[l-1]}return void 0===c?"":c}))}},fe2f:function(t,e,n){"use strict";var r=n("d582").IteratorPrototype,i=n("a30f"),o=n("7e3c"),a=n("9207"),s=n("db7f"),u=function(){return this};t.exports=function(t,e,n){var c=e+" Iterator";return t.prototype=i(r,{next:o(1,n)}),a(t,c,!1,!0),s[c]=u,t}},fec6:function(t,e,n){var r=n("cc43"),i=n("097d"),o=n("9cd9").f,a=n("9a1e"),s="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];t.exports.f=function(t){return s&&"Window"==r(t)?function(t){try{return o(t)}catch(t){return a(s)}}(t):o(i(t))}}})},module.exports=e()}).call(this,__webpack_require__(140).setImmediate)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(9),i=n(8),o=s(n(18)),a=s(n(270));function s(t){return t&&t.__esModule?t:{default:t}}e.default={name:"Sidebar",computed:{nav:function(){return this.$store.state.user.addRouters}},props:{theme:{type:String,default:"light"},sidebarList:{type:Array,default:function(){return[]}}},data:function(){return{currentSelect:[],openKeys:[],currentOpen:[],isOpenSideBar:!0}},mounted:function(){var t=this;this.$watch("$route",(function(e){e.path&&t.highMenu(e)}),{immediate:!0,deep:!0})},methods:{findParent:function(t,e){var n=[];return function e(r,i){for(var o=0;o<r.length;o++){var a=r[o];if(a.name===i){n.push(a),e(t,a.meta.parentId);break}a.children&&e(a.children,i)}}(t,e),n},highMenu:function(t){var e=this.findParent(this.nav[0].children,t.name),n=(0,i.find)(e,{type:1});if(this.currentSelect=[n.name],(0,i.isEmpty)(t.meta.subType))this.isOpenSideBar=!0;else{var r=JSON.parse(t.meta.subType);r&&"1"===r.fullPage?this.isOpenSideBar=!1:this.isOpenSideBar=!0}},findCurrentNodes:function(t,e,n){var r=this;return t.forEach((function(t){t.name===e?n.push(t):t.children&&r.findCurrentNodes(t.children,e,n)})),n},handleNav:function(t){t.item;var e=t.key;t.keyPath;if(!e)return!1;var n=[];if(this.findCurrentNodes(this.nav[0].children,e,n),!(0,i.isEmpty)(n))if(1===n[0].meta.chainType){var r=e.indexOf("http")>-1?e:"http://"+e;window.open(r)}else this.currentSelect=[e],this.$router.push({name:e}).then((function(t){}))},renderIcon:function(t){var e=this.$createElement;return t?e("i",{class:(0,o.default)(["icon","iconfont",t])}):e(a.default)},getChildrenType1:function(t){return t.children.every((function(t){return 3===t.type}))}},render:function(){var t=this,e=arguments[0],n=function n(r){if(r){if(t.getChildrenType1(r))return e("a-menu-item",{key:r.name},[t.renderIcon(r.meta.icon),e("span",[r.meta.title])]);var i=r.children.map((function(r){return r.children?n(r):1===r.type?e("a-menu-item",{key:r.name},[t.renderIcon(r.meta.icon),e("span",[r.meta.title])]):null}));return e("a-sub-menu",{key:r.name},[e("span",{slot:"title"},[t.renderIcon(r.meta.icon),e("span",[r.meta.title])]),i])}return[]},o=this.sidebarList&&!(0,i.isEmpty)(this.sidebarList)?this.sidebarList.map((function(r){return r.meta&&r.meta.subType?null:!r.children||t.getChildrenType1(r)?e("a-menu-item",{key:r.name},[t.renderIcon(r.meta.icon),e("span",[r.meta.title])]):n(r)})):null,a=o&&o.length?e("a-menu",{attrs:{mode:"inline",theme:this.theme,inlineCollapsed:!0,selectedKeys:this.currentSelect},on:{click:this.handleNav}},[o]):null;return e("a-layout-sider",{class:r.prefixCls+"-slider",attrs:{width:this.isOpenSideBar?250:0}},[a])}}},function(t,e,n){var r=n(22)(n(11),"Map");t.exports=r},function(t,e,n){var r=n(309);t.exports=function(t){return null==t?"":r(t)}},function(t,e,n){var r=n(51);t.exports=function(t){if("string"==typeof t||r(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}},function(t,e,n){var r=n(89),i=n(55),o=Object.prototype.hasOwnProperty;t.exports=function(t,e,n){var a=t[e];o.call(t,e)&&i(a,n)&&(void 0!==n||e in t)||r(t,e,n)}},function(t,e,n){var r=n(143);t.exports=function(t,e,n){"__proto__"==e&&r?r(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}},function(t,e){t.exports=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}},function(t,e){t.exports=function(t){return t}},function(t,e){t.exports=function(t,e){var n=-1,r=t.length;for(e||(e=Array(r));++n<r;)e[n]=t[n];return e}},function(t,e,n){var r=n(359);t.exports=function(t){var e=new t.constructor(t.byteLength);return new r(e).set(new r(t)),e}},function(t,e){var n=Object.prototype;t.exports=function(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||n)}},function(t,e,n){(function(t){var r=n(11),i=n(362),o=e&&!e.nodeType&&e,a=o&&"object"==typeof t&&t&&!t.nodeType&&t,s=a&&a.exports===o?r.Buffer:void 0,u=(s?s.isBuffer:void 0)||i;t.exports=u}).call(this,n(44)(t))},function(t,e){t.exports=function(t){return function(e){return t(e)}}},function(t,e,n){(function(t){var r=n(135),i=e&&!e.nodeType&&e,o=i&&"object"==typeof t&&t&&!t.nodeType&&t,a=o&&o.exports===i&&r.process,s=function(){try{var t=o&&o.require&&o.require("util").types;return t||a&&a.binding&&a.binding("util")}catch(t){}}();t.exports=s}).call(this,n(44)(t))},function(t,e,n){var r=n(386),i=n(157),o=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols,s=a?function(t){return null==t?[]:(t=Object(t),r(a(t),(function(e){return o.call(t,e)})))}:i;t.exports=s},function(t,e,n){var r=n(390),i=n(85),o=n(391),a=n(392),s=n(393),u=n(28),c=n(142),l=c(r),h=c(i),f=c(o),d=c(a),p=c(s),m=u;(r&&"[object DataView]"!=m(new r(new ArrayBuffer(1)))||i&&"[object Map]"!=m(new i)||o&&"[object Promise]"!=m(o.resolve())||a&&"[object Set]"!=m(new a)||s&&"[object WeakMap]"!=m(new s))&&(m=function(t){var e=u(t),n="[object Object]"==e?t.constructor:void 0,r=n?c(n):"";if(r)switch(r){case l:return"[object DataView]";case h:return"[object Map]";case f:return"[object Promise]";case d:return"[object Set]";case p:return"[object WeakMap]"}return e}),t.exports=m},function(t,e,n){t.exports={default:n(165),__esModule:!0}},function(t,e,n){var r=n(39);t.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==r(t)?t.split(""):Object(t)}},function(t,e,n){var r=n(1),i=n(5),o=i["__core-js_shared__"]||(i["__core-js_shared__"]={});(t.exports=function(t,e){return o[t]||(o[t]=void 0!==e?e:{})})("versions",[]).push({version:r.version,mode:n(69)?"pure":"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})},function(t,e){var n=0,r=Math.random();t.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++n+r).toString(36))}},function(t,e){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(t,e){e.f={}.propertyIsEnumerable},function(t,e,n){"use strict";var r=n(69),i=n(7),o=n(191),a=n(23),s=n(25),u=n(192),c=n(74),l=n(195),h=n(6)("iterator"),f=!([].keys&&"next"in[].keys()),d=function(){return this};t.exports=function(t,e,n,p,m,g,v){u(n,e,p);var y,_,x,b=function(t){if(!f&&t in T)return T[t];switch(t){case"keys":case"values":return function(){return new n(this,t)}}return function(){return new n(this,t)}},w=e+" Iterator",M="values"==m,S=!1,T=t.prototype,E=T[h]||T["@@iterator"]||m&&T[m],A=E||b(m),C=m?M?b("entries"):A:void 0,P="Array"==e&&T.entries||E;if(P&&(x=l(P.call(new t)))!==Object.prototype&&x.next&&(c(x,w,!0),r||"function"==typeof x[h]||a(x,h,d)),M&&E&&"values"!==E.name&&(S=!0,A=function(){return E.call(this)}),r&&!v||!f&&!S&&T[h]||a(T,h,A),s[e]=A,s[w]=d,m)if(y={values:M?A:b("values"),keys:g?A:b("keys"),entries:C},v)for(_ in y)_ in T||o(T,_,y[_]);else i(i.P+i.F*(f||S),e,y);return y}},function(t,e,n){var r=n(5).document;t.exports=r&&r.documentElement},function(t,e,n){var r=n(15);t.exports=function(t,e,n,i){try{return i?e(r(n)[0],n[1]):e(n)}catch(e){var o=t.return;throw void 0!==o&&r(o.call(t)),e}}},function(t,e,n){var r=n(25),i=n(6)("iterator"),o=Array.prototype;t.exports=function(t){return void 0!==t&&(r.Array===t||o[i]===t)}},function(t,e,n){var r=n(15),i=n(40),o=n(6)("species");t.exports=function(t,e){var n,a=r(t).constructor;return void 0===a||null==(n=r(a)[o])?e:i(n)}},function(t,e,n){var r,i,o,a=n(29),s=n(202),u=n(107),c=n(70),l=n(5),h=l.process,f=l.setImmediate,d=l.clearImmediate,p=l.MessageChannel,m=l.Dispatch,g=0,v={},y=function(){var t=+this;if(v.hasOwnProperty(t)){var e=v[t];delete v[t],e()}},_=function(t){y.call(t.data)};f&&d||(f=function(t){for(var e=[],n=1;arguments.length>n;)e.push(arguments[n++]);return v[++g]=function(){s("function"==typeof t?t:Function(t),e)},r(g),g},d=function(t){delete v[t]},"process"==n(39)(h)?r=function(t){h.nextTick(a(y,t,1))}:m&&m.now?r=function(t){m.now(a(y,t,1))}:p?(o=(i=new p).port2,i.port1.onmessage=_,r=a(o.postMessage,o,1)):l.addEventListener&&"function"==typeof postMessage&&!l.importScripts?(r=function(t){l.postMessage(t+"","*")},l.addEventListener("message",_,!1)):r="onreadystatechange"in c("script")?function(t){u.appendChild(c("script")).onreadystatechange=function(){u.removeChild(this),y.call(t)}}:function(t){setTimeout(a(y,t,1),0)}),t.exports={set:f,clear:d}},function(t,e){t.exports=function(t){try{return{e:!1,v:t()}}catch(t){return{e:!0,v:t}}}},function(t,e,n){var r=n(15),i=n(30),o=n(78);t.exports=function(t,e){if(r(t),i(e)&&e.constructor===t)return e;var n=o.f(t);return(0,n.resolve)(e),n.promise}},function(t,e,n){var r=n(6)("iterator"),i=!1;try{var o=[7][r]();o.return=function(){i=!0},Array.from(o,(function(){throw 2}))}catch(t){}t.exports=function(t,e){if(!e&&!i)return!1;var n=!1;try{var o=[7],a=o[r]();a.next=function(){return{done:n=!0}},o[r]=function(){return a},t(o)}catch(t){}return n}},function(t,e,n){var r=n(26),i=r.slice,o=r.pluck,a=r.each,s=r.bind,u=r.create,c=r.isList,l=r.isFunction,h=r.isObject;t.exports={createStore:d};var f={version:"2.0.12",enabled:!1,get:function(t,e){var n=this.storage.read(this._namespacePrefix+t);return this._deserialize(n,e)},set:function(t,e){return void 0===e?this.remove(t):(this.storage.write(this._namespacePrefix+t,this._serialize(e)),e)},remove:function(t){this.storage.remove(this._namespacePrefix+t)},each:function(t){var e=this;this.storage.each((function(n,r){t.call(e,e._deserialize(n),(r||"").replace(e._namespaceRegexp,""))}))},clearAll:function(){this.storage.clearAll()},hasNamespace:function(t){return this._namespacePrefix=="__storejs_"+t+"_"},createStore:function(){return d.apply(this,arguments)},addPlugin:function(t){this._addPlugin(t)},namespace:function(t){return d(this.storage,this.plugins,t)}};function d(t,e,n){n||(n=""),t&&!c(t)&&(t=[t]),e&&!c(e)&&(e=[e]);var r=n?"__storejs_"+n+"_":"",d=n?new RegExp("^"+r):null;if(!/^[a-zA-Z0-9_\-]*$/.test(n))throw new Error("store.js namespaces can only have alphanumerics + underscores and dashes");var p=u({_namespacePrefix:r,_namespaceRegexp:d,_testStorage:function(t){try{var e="__storejs__test__";t.write(e,e);var n=t.read(e)===e;return t.remove(e),n}catch(t){return!1}},_assignPluginFnProp:function(t,e){var n=this[e];this[e]=function(){var e=i(arguments,0),r=this;function o(){if(n)return a(arguments,(function(t,n){e[n]=t})),n.apply(r,e)}var s=[o].concat(e);return t.apply(r,s)}},_serialize:function(t){return JSON.stringify(t)},_deserialize:function(t,e){if(!t)return e;var n="";try{n=JSON.parse(t)}catch(e){n=t}return void 0!==n?n:e},_addStorage:function(t){this.enabled||this._testStorage(t)&&(this.storage=t,this.enabled=!0)},_addPlugin:function(t){var e=this;if(c(t))a(t,(function(t){e._addPlugin(t)}));else if(!o(this.plugins,(function(e){return t===e}))){if(this.plugins.push(t),!l(t))throw new Error("Plugins must be function values that return objects");var n=t.call(this);if(!h(n))throw new Error("Plugins must return an object of function properties");a(n,(function(n,r){if(!l(n))throw new Error("Bad plugin property: "+r+" from plugin "+t.name+". Plugins should only return functions.");e._assignPluginFnProp(n,r)}))}},addStorage:function(t){!function(){var t="undefined"==typeof console?null:console;if(t){var e=t.warn?t.warn:t.log;e.apply(t,arguments)}}("store.addStorage(storage) is deprecated. Use createStore([storages])"),this._addStorage(t)}},f,{plugins:[]});return p.raw={},a(p,(function(t,e){l(t)&&(p.raw[e]=s(p,t))})),a(t,(function(t){p._addStorage(t)})),a(e,(function(t){p._addPlugin(t)})),p}},function(t,e,n){var r=n(115),i=n(209),o=[n(213)];t.exports=r.createStore(i,o)},function(t,e,n){var r=n(26).Global;function i(){return r.localStorage}function o(t){return i().getItem(t)}t.exports={name:"localStorage",read:o,write:function(t,e){return i().setItem(t,e)},each:function(t){for(var e=i().length-1;e>=0;e--){var n=i().key(e);t(o(n),n)}},remove:function(t){return i().removeItem(t)},clearAll:function(){return i().clear()}}},function(t,e,n){var r=n(26),i=r.Global,o=r.trim;t.exports={name:"cookieStorage",read:function(t){if(!t||!c(t))return null;var e="(?:^|.*;\\s*)"+escape(t).replace(/[\-\.\+\*]/g,"\\$&")+"\\s*\\=\\s*((?:[^;](?!;))*[^;]?).*";return unescape(a.cookie.replace(new RegExp(e),"$1"))},write:function(t,e){if(!t)return;a.cookie=escape(t)+"="+escape(e)+"; expires=Tue, 19 Jan 2038 03:14:07 GMT; path=/"},each:s,remove:u,clearAll:function(){s((function(t,e){u(e)}))}};var a=i.document;function s(t){for(var e=a.cookie.split(/; ?/g),n=e.length-1;n>=0;n--)if(o(e[n])){var r=e[n].split("="),i=unescape(r[0]);t(unescape(r[1]),i)}}function u(t){t&&c(t)&&(a.cookie=escape(t)+"=; expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/")}function c(t){return new RegExp("(?:^|;\\s*)"+escape(t).replace(/[\-\.\+\*]/g,"\\$&")+"\\s*\\=").test(a.cookie)}},function(t,e,n){var r=n(26).Global;function i(){return r.sessionStorage}function o(t){return i().getItem(t)}t.exports={name:"sessionStorage",read:o,write:function(t,e){return i().setItem(t,e)},each:function(t){for(var e=i().length-1;e>=0;e--){var n=i().key(e);t(o(n),n)}},remove:function(t){return i().removeItem(t)},clearAll:function(){return i().clear()}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=u(n(21)),i=u(n(45)),o=u(n(121)),a=n(27),s=n(13);function u(t){return t&&t.__esModule?t:{default:t}}var c=!1,l=[],h=o.default.create({timeout:6e4,withCredentials:!0});function f(t){if(!t)return{};if(t instanceof FormData)return t;var e=new FormData,n=function(n){var r=t[n];Array.isArray(t[n])?t[n].forEach((function(t){e.append(n,t)})):e.append(n,r)};for(var r in t)n(r);return e}h.interceptors.request.use((function(t){return t.headers["Authorization-sys"]||(t.headers["Authorization-sys"]="Bearer "+s.localStore.get("access_token")),t.url=t.url.replace(/{\w+}/g,(function(e){var n=e.substring(1,e.length-1),r=t.params[n];return["delete","get"].includes(t.method)&&delete t.params[n],r})),t.baseURL=s.sessionStore.get("BASE_URL"),t}),(function(t){return i.default.reject(t)})),h.interceptors.response.use((function(t){return t.data}),(function(t){if(t&&t.response&&(401===t.response.status||400===t.response.status)){var e=s.sessionStore.get("IAM_BASE_URL")+"/iam/v1/oauth/logout?redirect_uri="+window.origin;return(t.response.config.url.includes("refresh/token")||t.response.config.url.includes("oauth/token"))&&(s.storage.clearAll(),window.open(e,"_self")),c?new i.default((function(e){l.push((function(n){t.config.headers["Authorization-sys"]="Bearer "+n,e(h(t.config))}))})):(c=!0,(0,a.refreshToken)({refreshToken:"Bearer "+s.localStore.get("refresh_token")}).then((function(e){var n=e.data,r=n.access_token,i=n.refresh_token;return s.localStore.set("access_token",r),s.localStore.set("refresh_token",i),t.config.headers["Authorization-sys"]="Bearer "+r,l.forEach((function(t){return t(r)})),l=[],h(t.config)})).catch((function(t){s.storage.clearAll(),window.open(e,"_self")})).finally((function(){c=!1})))}return i.default.reject(t)})),e.default={service:h,get:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h.get(t,{params:e,headers:(0,r.default)({},n)})},post:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h.post(t,e,{headers:n})},postQuery:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h.post(t,{},{headers:n,params:e})},put:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h.put(t,e,{headers:n})},file:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h.post(t,f(e),{headers:(0,r.default)({"Content-Type":"multipart/form-data"},n)})},download:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h.get(t,{params:e,responseType:"blob",headers:(0,r.default)({},n)})},delete:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h.delete(t,{params:e,headers:(0,r.default)({"Content-Type":"multipart/form-data"},n)})}}},function(t,e,n){t.exports=n(216)},function(t,e,n){"use strict";t.exports=function(t,e){return function(){for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];return t.apply(e,n)}}},function(t,e,n){"use strict";var r=n(4);function i(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}t.exports=function(t,e,n){if(!e)return t;var o;if(n)o=n(e);else if(r.isURLSearchParams(e))o=e.toString();else{var a=[];r.forEach(e,(function(t,e){null!=t&&(r.isArray(t)?e+="[]":t=[t],r.forEach(t,(function(t){r.isDate(t)?t=t.toISOString():r.isObject(t)&&(t=JSON.stringify(t)),a.push(i(e)+"="+i(t))})))})),o=a.join("&")}if(o){var s=t.indexOf("#");-1!==s&&(t=t.slice(0,s)),t+=(-1===t.indexOf("?")?"?":"&")+o}return t}},function(t,e){var n,r,i=t.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(t){if(n===setTimeout)return setTimeout(t,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:o}catch(t){n=o}try{r="function"==typeof clearTimeout?clearTimeout:a}catch(t){r=a}}();var u,c=[],l=!1,h=-1;function f(){l&&u&&(l=!1,u.length?c=u.concat(c):h=-1,c.length&&d())}function d(){if(!l){var t=s(f);l=!0;for(var e=c.length;e;){for(u=c,c=[];++h<e;)u&&u[h].run();h=-1,e=c.length}u=null,l=!1,function(t){if(r===clearTimeout)return clearTimeout(t);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(t);try{r(t)}catch(e){try{return r.call(null,t)}catch(e){return r.call(this,t)}}}(t)}}function p(t,e){this.fun=t,this.array=e}function m(){}i.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];c.push(new p(t,e)),1!==c.length||l||s(d)},p.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=m,i.addListener=m,i.once=m,i.off=m,i.removeListener=m,i.removeAllListeners=m,i.emit=m,i.prependListener=m,i.prependOnceListener=m,i.listeners=function(t){return[]},i.binding=function(t){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(t){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},function(t,e,n){"use strict";t.exports=function(t,e,n,r,i){return t.config=e,n&&(t.code=n),t.request=r,t.response=i,t.isAxiosError=!0,t.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code}},t}},function(t,e,n){"use strict";var r=n(4),i=n(222),o=n(223),a=n(123),s=n(224),u=n(227),c=n(228),l=n(127);t.exports=function(t){return new Promise((function(e,n){var h=t.data,f=t.headers,d=t.responseType;r.isFormData(h)&&delete f["Content-Type"];var p=new XMLHttpRequest;if(t.auth){var m=t.auth.username||"",g=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";f.Authorization="Basic "+btoa(m+":"+g)}var v=s(t.baseURL,t.url);function y(){if(p){var r="getAllResponseHeaders"in p?u(p.getAllResponseHeaders()):null,o={data:d&&"text"!==d&&"json"!==d?p.response:p.responseText,status:p.status,statusText:p.statusText,headers:r,config:t,request:p};i(e,n,o),p=null}}if(p.open(t.method.toUpperCase(),a(v,t.params,t.paramsSerializer),!0),p.timeout=t.timeout,"onloadend"in p?p.onloadend=y:p.onreadystatechange=function(){p&&4===p.readyState&&(0!==p.status||p.responseURL&&0===p.responseURL.indexOf("file:"))&&setTimeout(y)},p.onabort=function(){p&&(n(l("Request aborted",t,"ECONNABORTED",p)),p=null)},p.onerror=function(){n(l("Network Error",t,null,p)),p=null},p.ontimeout=function(){var e="timeout of "+t.timeout+"ms exceeded";t.timeoutErrorMessage&&(e=t.timeoutErrorMessage),n(l(e,t,t.transitional&&t.transitional.clarifyTimeoutError?"ETIMEDOUT":"ECONNABORTED",p)),p=null},r.isStandardBrowserEnv()){var _=(t.withCredentials||c(v))&&t.xsrfCookieName?o.read(t.xsrfCookieName):void 0;_&&(f[t.xsrfHeaderName]=_)}"setRequestHeader"in p&&r.forEach(f,(function(t,e){void 0===h&&"content-type"===e.toLowerCase()?delete f[e]:p.setRequestHeader(e,t)})),r.isUndefined(t.withCredentials)||(p.withCredentials=!!t.withCredentials),d&&"json"!==d&&(p.responseType=t.responseType),"function"==typeof t.onDownloadProgress&&p.addEventListener("progress",t.onDownloadProgress),"function"==typeof t.onUploadProgress&&p.upload&&p.upload.addEventListener("progress",t.onUploadProgress),t.cancelToken&&t.cancelToken.promise.then((function(t){p&&(p.abort(),n(t),p=null)})),h||(h=null),p.send(h)}))}},function(t,e,n){"use strict";var r=n(125);t.exports=function(t,e,n,i,o){var a=new Error(t);return r(a,e,n,i,o)}},function(t,e,n){"use strict";t.exports=function(t){return!(!t||!t.__CANCEL__)}},function(t,e,n){"use strict";var r=n(4);t.exports=function(t,e){e=e||{};var n={},i=["url","method","data"],o=["headers","auth","proxy","params"],a=["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","timeoutMessage","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","decompress","maxContentLength","maxBodyLength","maxRedirects","transport","httpAgent","httpsAgent","cancelToken","socketPath","responseEncoding"],s=["validateStatus"];function u(t,e){return r.isPlainObject(t)&&r.isPlainObject(e)?r.merge(t,e):r.isPlainObject(e)?r.merge({},e):r.isArray(e)?e.slice():e}function c(i){r.isUndefined(e[i])?r.isUndefined(t[i])||(n[i]=u(void 0,t[i])):n[i]=u(t[i],e[i])}r.forEach(i,(function(t){r.isUndefined(e[t])||(n[t]=u(void 0,e[t]))})),r.forEach(o,c),r.forEach(a,(function(i){r.isUndefined(e[i])?r.isUndefined(t[i])||(n[i]=u(void 0,t[i])):n[i]=u(void 0,e[i])})),r.forEach(s,(function(r){r in e?n[r]=u(t[r],e[r]):r in t&&(n[r]=u(void 0,t[r]))}));var l=i.concat(o).concat(a).concat(s),h=Object.keys(t).concat(Object.keys(e)).filter((function(t){return-1===l.indexOf(t)}));return r.forEach(h,c),n}},function(t,e,n){"use strict";function r(t){this.message=t}r.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},r.prototype.__CANCEL__=!0,t.exports=r},function(t,e,n){"use strict";var r=Object.prototype.hasOwnProperty,i=Array.isArray,o=function(){for(var t=[],e=0;e<256;++e)t.push("%"+((e<16?"0":"")+e.toString(16)).toUpperCase());return t}(),a=function(t,e){for(var n=e&&e.plainObjects?Object.create(null):{},r=0;r<t.length;++r)void 0!==t[r]&&(n[r]=t[r]);return n};t.exports={arrayToObject:a,assign:function(t,e){return Object.keys(e).reduce((function(t,n){return t[n]=e[n],t}),t)},combine:function(t,e){return[].concat(t,e)},compact:function(t){for(var e=[{obj:{o:t},prop:"o"}],n=[],r=0;r<e.length;++r)for(var o=e[r],a=o.obj[o.prop],s=Object.keys(a),u=0;u<s.length;++u){var c=s[u],l=a[c];"object"==typeof l&&null!==l&&-1===n.indexOf(l)&&(e.push({obj:a,prop:c}),n.push(l))}return function(t){for(;t.length>1;){var e=t.pop(),n=e.obj[e.prop];if(i(n)){for(var r=[],o=0;o<n.length;++o)void 0!==n[o]&&r.push(n[o]);e.obj[e.prop]=r}}}(e),t},decode:function(t,e,n){var r=t.replace(/\+/g," ");if("iso-8859-1"===n)return r.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(r)}catch(t){return r}},encode:function(t,e,n){if(0===t.length)return t;var r="string"==typeof t?t:String(t);if("iso-8859-1"===n)return escape(r).replace(/%u[0-9a-f]{4}/gi,(function(t){return"%26%23"+parseInt(t.slice(2),16)+"%3B"}));for(var i="",a=0;a<r.length;++a){var s=r.charCodeAt(a);45===s||46===s||95===s||126===s||s>=48&&s<=57||s>=65&&s<=90||s>=97&&s<=122?i+=r.charAt(a):s<128?i+=o[s]:s<2048?i+=o[192|s>>6]+o[128|63&s]:s<55296||s>=57344?i+=o[224|s>>12]+o[128|s>>6&63]+o[128|63&s]:(a+=1,s=65536+((1023&s)<<10|1023&r.charCodeAt(a)),i+=o[240|s>>18]+o[128|s>>12&63]+o[128|s>>6&63]+o[128|63&s])}return i},isBuffer:function(t){return!(!t||"object"!=typeof t)&&!!(t.constructor&&t.constructor.isBuffer&&t.constructor.isBuffer(t))},isRegExp:function(t){return"[object RegExp]"===Object.prototype.toString.call(t)},merge:function t(e,n,o){if(!n)return e;if("object"!=typeof n){if(i(e))e.push(n);else{if(!e||"object"!=typeof e)return[e,n];(o&&(o.plainObjects||o.allowPrototypes)||!r.call(Object.prototype,n))&&(e[n]=!0)}return e}if(!e||"object"!=typeof e)return[e].concat(n);var s=e;return i(e)&&!i(n)&&(s=a(e,o)),i(e)&&i(n)?(n.forEach((function(n,i){if(r.call(e,i)){var a=e[i];a&&"object"==typeof a&&n&&"object"==typeof n?e[i]=t(a,n,o):e.push(n)}else e[i]=n})),e):Object.keys(n).reduce((function(e,i){var a=n[i];return r.call(e,i)?e[i]=t(e[i],a,o):e[i]=a,e}),s)}}},function(t,e,n){"use strict";var r=String.prototype.replace,i=/%20/g;t.exports={default:"RFC3986",formatters:{RFC1738:function(t){return r.call(t,i,"+")},RFC3986:function(t){return t}},RFC1738:"RFC1738",RFC3986:"RFC3986"}},function(t,e,n){var r=n(16),i=n(36),o=n(38),a=n(105).f;t.exports=function(t){return function(e){for(var n,s=o(e),u=i(s),c=u.length,l=0,h=[];c>l;)n=u[l++],r&&!a.call(s,n)||h.push(t?[n,s[n]]:s[n]);return h}}},function(t,e,n){var r=n(28),i=n(80),o=n(17),a=Function.prototype,s=Object.prototype,u=a.toString,c=s.hasOwnProperty,l=u.call(Object);t.exports=function(t){if(!o(t)||"[object Object]"!=r(t))return!1;var e=i(t);if(null===e)return!0;var n=c.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&u.call(n)==l}},function(t,e,n){(function(e){var n="object"==typeof e&&e&&e.Object===Object&&e;t.exports=n}).call(this,n(20))},function(t,e){t.exports=function(t,e){return function(n){return t(e(n))}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=l(n(18)),i=n(9),o=l(n(81)),a=n(8),s=l(n(138)),u=l(n(139)),c=l(n(259));function l(t){return t&&t.__esModule?t:{default:t}}e.default={name:"MapAndBasicHeader",inject:["slotsList","propsList"],props:{theme:{type:String,default:"light"},fixed:{type:Boolean,default:!1},navList:{type:Array,default:function(){return[]}}},data:function(){return{currentPath:void 0,currentIndex:0}},mounted:function(){var t=this;this.$watch("$route",(function(e){var n=e.matched;if(t.navList&&!(0,a.isEmpty)(t.navList)){var r=(0,i.treeFindPath)(t.navList,(function(t){return t.meta.id===n[n.length-1].meta.id}));t.currentPath=r[0].path;var o=t.navList.findIndex((function(e){return e.path===t.currentPath}));t.currentIndex=-1!==o?o:0,t.propsList.nav&&c.default._toggle(t.currentIndex)}}),{immediate:!0}),this.propsList.nav&&this.$nextTick((function(){c.default.drawNav({index:t.currentIndex,canvas:document.getElementById("navCanvas"),navItem:document.querySelector(".rk-web-core-header-right-nav-item"),navCount:t.navList.length})}))},methods:{renderNav:function(){var t=this,e=this.$createElement;return this.navList&&!(0,a.isEmpty)(this.navList)?this.navList.filter((function(t){return 1===t.type})).map((function(n,o){var a="dark"!==t.theme?(0,r.default)([i.prefixCls+"-header-right-nav-item",n.path===t.currentPath?i.prefixCls+"-header-right-nav-active":""]):(0,r.default)([i.prefixCls+"-header-right-nav-item",i.prefixCls+"-header-dark-nav-item",n.path===t.currentPath?i.prefixCls+"-header-dark-nav-active":""]);return e("div",{class:a,ref:"navItem",on:{click:function(){return t.handleTap(n,o)}}},[n.meta.title])})):null},handleTap:function(t,e){if(1===t.meta.chainType){var n=t.path.indexOf("http")>-1?t.path:"http://"+t.path;window.open(n)}else this.propsList.nav&&c.default._toggle(e),this.currentPath=t.path,this.$store.commit("user/SET_NAV_INDEX",e),this.$router.push(t.path).then((function(t){})),this.$emit("change",t)},setNavIndex:function(t){c.default._toggle(t)}},render:function(){var t=arguments[0],e=this.theme,n=this.fixed,a=this.slotsList,c=this.propsList,l=(0,r.default)([i.prefixCls+"-header",i.prefixCls+"-header-"+e,n?i.prefixCls+"-header-fixed":""]);return t("a-layout-header",{class:l},[t("div",{class:[i.prefixCls+"-header-"+e+"-inner",i.prefixCls+"-header-inner"]},[a.logo?a.logo:t(o.default,{attrs:{prefix:"basic",theme:e}}),a.prefix,t("div",{class:i.prefixCls+"-header-right"},[c.nav?t("div",{class:[i.prefixCls+"-header-right-nav","dark"===e?i.prefixCls+"-header-dark":""]},[t("canvas",{attrs:{id:"navCanvas"},style:"position: absolute; z-index: -1"}),this.renderNav()]):null,c.right?t("div",{class:i.prefixCls+"-header-right-extra"},[a.header,t(s.default,{attrs:{theme:e}}),a.nameSuffix,t(u.default,{attrs:{theme:e}})]):null]),a.suffix])])}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=d(n(72)),o=d(n(73)),a=d(n(21)),s=n(9),u=n(13),c=d(n(116)),l=n(27),h=n(8),f=d(n(18));function d(t){return t&&t.__esModule?t:{default:t}}e.default={name:"AppExternal",props:{theme:{type:String,default:"light"}},computed:{currentUser:function(){return u.localStore.get("userName")},currentProject:function(){return u.localStore.get("currentProject")}},data:function(){return{projectList:[],currentProjectInfo:void 0}},mounted:function(){this.getAllProject()},methods:{getAllProject:function(){var t=this;(0,l.getBelongList)().then((function(e){u.sessionStore.get("CLIENT_ID");t.projectList=e.data.map((function(e){return(0,a.default)({},e,{check:e.id===t.currentProject.id})}));var n=(0,h.find)(t.projectList,["id",t.currentProject.id]);(0,h.isEmpty)(n)||(t.currentProjectInfo=n.name)}))},changeBtn:(r=(0,o.default)(i.default.mark((function t(e,n){var r,o;return i.default.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(1!==e){t.next=14;break}return localStorage.removeItem("menuList"),localStorage.removeItem("consumer"),localStorage.removeItem("currentProject"),localStorage.removeItem("consumerExtList"),localStorage.removeItem("userMessage"),u.localStore.set("currentProject",n),t.next=9,(0,l.postConsumer)(n.id);case 9:r=t.sent,o=r.data,!(0,h.isEmpty)(o)&&o.access_token&&(localStorage.removeItem("access_token"),localStorage.setItem("access_token",o.access_token),this.$nextTick((function(){window.location.reload()}))),t.next=16;break;case 14:c.default.clearAll(),window.open(sessionStorage.getItem("IAM_BASE_URL")+"/iam/v1/oauth/logout?redirect_uri="+window.origin,"_self");case 16:case"end":return t.stop()}}),t,this)}))),function(t,e){return r.apply(this,arguments)})},render:function(){var t=this,e=arguments[0],n=this.projectList.map((function(n){var r=(0,f.default)([s.prefixCls+"-app-external-cell",n.check?s.prefixCls+"-app-external-active":""]);return e("div",{class:r,on:{click:function(){return t.changeBtn(1,n)}}},[n.name])}));return e("a-dropdown",{attrs:{trigger:["click"]}},[e("span",{class:[s.prefixCls+"-app-external-link",s.prefixCls+"-app-external-link-"+this.theme]},[e("span",{class:s.prefixCls+"-app-external-link-title"},[this.currentUser]),this.currentProject?e("span",{class:s.prefixCls+"-app-external-link-sub"},["【",this.currentProjectInfo,"】"]):null,e("a-icon",{attrs:{type:"caret-down"}})]),e("div",{slot:"overlay",class:s.prefixCls+"-app-external-wrapper"},[(0,h.isEmpty)(this.projectList)?null:e("div",{class:s.prefixCls+"-app-external-list"},[n]),e("div",{class:s.prefixCls+"-app-external-btn",on:{click:function(){return t.changeBtn(2)}}},[e("span",["退出登录"])])])])}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=c(n(100)),i=c(n(255)),o=n(9),a=n(27),s=c(n(258)),u=n(13);function c(t){return t&&t.__esModule?t:{default:t}}var l={"东北⻛":[22.5,67.5],"东⻛":[67.5,112.5],"东南⻛":[112.5,157.5],"南⻛":[157.5,202.5],"⻄南⻛":[202.5,247.5],"⻄⻛":[247.5,292.5],"⻄北⻛":[292.5,337.5]},h={"0级":[0,.2],"1级":[.2,1.5],"2级":[1.5,3.3],"3级":[3.3,5.4],"4级":[5.4,7.9],"5级":[7.9,10.7],"6级":[10.7,13.8],"7级":[13.8,17.1],"8级":[17.1,20.7],"9级":[20.7,24.4],"10级":[24.4,28.4],"11级":[28.4,32.6]};e.default={name:"HeaderInfoGroup",inject:["propsList"],props:{theme:{type:String,default:"light"}},data:function(){return{ymd:"00-00-00",hms:"--:--:--",regionDataInfo:{temperature:0,time:void 0,url:void 0,value:0,windDirection:0,windSpeed:0,iconDay:void 0,iconNight:void 0,weather:"晴",windDegrees:180,windLevel:2},isDay:!0}},mounted:function(){var t=this;this.timer=setInterval((function(){t.initDateTime()}),1e3),this.getRealDate()},methods:{calcWindDirection:function(t){return{transform:"rotateZ("+t+"deg)"}},calcWind:function(t){var e=(0,i.default)(l).findIndex((function(e){return t>e[0]&&t<=e[1]}));return""+((0,r.default)(l)[e]||"北风")},calcWindLevel:function(t){if(0===t)return"0级";var e=(0,i.default)(h).findIndex((function(e){return t>e[0]&&t<=e[1]}));return""+((0,r.default)(h)[e]||"12级")},initDateTime:function(){var t=new Date,e=t.getFullYear(),n=t.getMonth()+1,r=t.getDate(),i=(new Date).getHours(),o=(new Date).getMinutes(),a=(new Date).getSeconds();this.ymd=e+"-"+this.addZero(n)+"-"+this.addZero(r),this.isDay=i>6&&i<=18,this.hms=this.addZero(i)+":"+this.addZero(o)+":"+this.addZero(a)},addZero:function(t){return t<10?"0"+t:t},getRealDate:function(){var t=this,e=u.localStore.get("consumer").regionId;(0,a.getRegionDataInfo)({areaCode:e}).then((function(e){t.regionDataInfo=e.data.live}))}},beforeDestroy:function(){this.timer&&clearInterval(this.timer)},render:function(){var t=arguments[0];return t("div",{class:[o.prefixCls+"-header-info-group",o.prefixCls+"-header-info-group-"+this.theme]},[this.propsList.datetime?t("div",{class:[o.prefixCls+"-header-info-group-time",o.prefixCls+"-header-info-group-item"]},[t("span",[this.hms]),t("small",[this.ymd])]):null,this.propsList.weather?t("div",{class:[o.prefixCls+"-header-info-group-weather",o.prefixCls+"-header-info-group-item"]},[t("img",{attrs:{src:this.regionDataInfo.icon,alt:""}}),t("span",[this.regionDataInfo.temperature,"℃"])]):null,this.propsList.wind?t("div",{class:[o.prefixCls+"-header-info-group-wind",o.prefixCls+"-header-info-group-item"]},[t("div",{class:o.prefixCls+"-header-info-group-wind-img"},[t(s.default,{style:this.calcWindDirection(this.regionDataInfo.windDegrees)})]),t("div",{class:o.prefixCls+"-header-info-group-wind-info"},[t("span",[this.regionDataInfo.windLevel,"级"]),t("span",[this.regionDataInfo.windDirection])])]):null])}}},function(t,e,n){(function(t){var r=void 0!==t&&t||"undefined"!=typeof self&&self||window,i=Function.prototype.apply;function o(t,e){this._id=t,this._clearFn=e}e.setTimeout=function(){return new o(i.call(setTimeout,r,arguments),clearTimeout)},e.setInterval=function(){return new o(i.call(setInterval,r,arguments),clearInterval)},e.clearTimeout=e.clearInterval=function(t){t&&t.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(r,this._id)},e.enroll=function(t,e){clearTimeout(t._idleTimeoutId),t._idleTimeout=e},e.unenroll=function(t){clearTimeout(t._idleTimeoutId),t._idleTimeout=-1},e._unrefActive=e.active=function(t){clearTimeout(t._idleTimeoutId);var e=t._idleTimeout;e>=0&&(t._idleTimeoutId=setTimeout((function(){t._onTimeout&&t._onTimeout()}),e))},n(265),e.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==t&&t.setImmediate||this&&this.setImmediate,e.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==t&&t.clearImmediate||this&&this.clearImmediate}).call(this,n(20))},function(t,e,n){var r=n(288),i=n(304),o=n(306),a=n(307),s=n(308);function u(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=i,u.prototype.get=o,u.prototype.has=a,u.prototype.set=s,t.exports=u},function(t,e){var n=Function.prototype.toString;t.exports=function(t){if(null!=t){try{return n.call(t)}catch(t){}try{return t+""}catch(t){}}return""}},function(t,e,n){var r=n(22),i=function(){try{var t=r(Object,"defineProperty");return t({},"",{}),t}catch(t){}}();t.exports=i},function(t,e,n){var r=n(59),i=n(318);t.exports=function t(e,n,o,a,s){var u=-1,c=e.length;for(o||(o=i),s||(s=[]);++u<c;){var l=e[u];n>0&&o(l)?n>1?t(l,n-1,o,a,s):r(s,l):a||(s[s.length]=l)}return s}},function(t,e,n){var r=n(319),i=Math.max;t.exports=function(t,e,n){return e=i(void 0===e?t.length-1:e,0),function(){for(var o=arguments,a=-1,s=i(o.length-e,0),u=Array(s);++a<s;)u[a]=o[e+a];a=-1;for(var c=Array(e+1);++a<e;)c[a]=o[a];return c[e]=n(u),r(t,this,c)}}},function(t,e,n){var r=n(320),i=n(322)(r);t.exports=i},function(t,e,n){var r=n(53),i=n(352),o=n(353),a=n(354),s=n(355),u=n(356);function c(t){var e=this.__data__=new r(t);this.size=e.size}c.prototype.clear=i,c.prototype.delete=o,c.prototype.get=a,c.prototype.has=s,c.prototype.set=u,t.exports=c},function(t,e,n){var r=n(89),i=n(55);t.exports=function(t,e,n){(void 0!==n&&!i(t[e],n)||void 0===n&&!(e in t))&&r(t,e,n)}},function(t,e,n){var r=n(357)();t.exports=r},function(t,e,n){(function(t){var r=n(11),i=e&&!e.nodeType&&e,o=i&&"object"==typeof t&&t&&!t.nodeType&&t,a=o&&o.exports===i?r.Buffer:void 0,s=a?a.allocUnsafe:void 0;t.exports=function(t,e){if(e)return t.slice();var n=t.length,r=s?s(n):new t.constructor(n);return t.copy(r),r}}).call(this,n(44)(t))},function(t,e,n){var r=n(93);t.exports=function(t,e){var n=e?r(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}},function(t,e,n){var r=n(360),i=n(80),o=n(94);t.exports=function(t){return"function"!=typeof t.constructor||o(t)?{}:r(i(t))}},function(t,e,n){var r=n(363),i=n(96),o=n(97),a=o&&o.isTypedArray,s=a?i(a):r;t.exports=s},function(t,e){t.exports=function(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}},function(t,e,n){var r=n(365),i=n(58),o=n(10),a=n(95),s=n(57),u=n(153),c=Object.prototype.hasOwnProperty;t.exports=function(t,e){var n=o(t),l=!n&&i(t),h=!n&&!l&&a(t),f=!n&&!l&&!h&&u(t),d=n||l||h||f,p=d?r(t.length,String):[],m=p.length;for(var g in t)!e&&!c.call(t,g)||d&&("length"==g||h&&("offset"==g||"parent"==g)||f&&("buffer"==g||"byteLength"==g||"byteOffset"==g)||s(g,m))||p.push(g);return p}},function(t,e){t.exports=function(t,e){for(var n=-1,r=null==t?0:t.length;++n<r&&!1!==e(t[n],n,t););return t}},function(t,e){t.exports=function(){return[]}},function(t,e,n){var r=n(59),i=n(80),o=n(98),a=n(157),s=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)r(e,o(t)),t=i(t);return e}:a;t.exports=s},function(t,e,n){var r=n(59),i=n(10);t.exports=function(t,e,n){var o=e(t);return i(t)?o:r(o,n(t))}},function(t,e,n){"use strict";n.r(e),n.d(e,"loadMicroApp",(function(){return Wn})),n.d(e,"registerMicroApps",(function(){return Hn})),n.d(e,"start",(function(){return Vn})),n.d(e,"initGlobalState",(function(){return Ft})),n.d(e,"__internalGetCurrentRunningApp",(function(){return Ge})),n.d(e,"addErrorHandler",(function(){return g.b})),n.d(e,"removeErrorHandler",(function(){return g.i})),n.d(e,"addGlobalUncaughtErrorHandler",(function(){return Zn})),n.d(e,"removeGlobalUncaughtErrorHandler",(function(){return qn})),n.d(e,"setDefaultMountApp",(function(){return Yn})),n.d(e,"runDefaultMountEffects",(function(){return Jn})),n.d(e,"runAfterFirstMounted",(function(){return Xn})),n.d(e,"SandBoxType",(function(){return Rt})),n.d(e,"prefetchApps",(function(){return In}));var r={};n.r(r),n.d(r,"ScopedCSS",(function(){return Zt})),n.d(r,"QiankunCSSRewriteAttr",(function(){return qt})),n.d(r,"process",(function(){return Yt}));var i=n(0),o=n.n(i),a=n(14),s=n.n(a);function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function c(t){return function(t){if(Array.isArray(t))return u(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return u(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?u(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function l(t){return(l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}
51
+ var i="_maptalks__internal_layer_",o=["MultiPoint","MultiLineString","MultiPolygon","GeometryCollection"],a=["FeatureCollection","Feature","Point","LineString","Polygon"].concat(o),s=["markerFile","polygonPatternFile","linePatternFile","markerFillPatternFile","markerLinePatternFile"],u=[["markerWidth","markerHeight"],[],[null,"lineWidth"],[],[null,"markerLineWidth"]],c={lineWidth:1,lineOpacity:1,lineDx:1,lineDy:1,polygonOpacity:1,markerWidth:1,markerHeight:1,markerDx:1,markerDy:1,markerOpacity:1,markerFillOpacity:1,markerLineWidth:1,markerLineOpacity:1,textSize:1,textOpacity:1,textHaloRadius:1,textWrapWidth:1,textLineSpacing:1,textDx:1,textDy:1},l=["lineColor","polygonFill","markerFill","markerLineColor","textFill"],h=14;function f(){return Date.now()}function d(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)t[r]=n[r]}return t}function p(t){return null==t}function m(t){return"number"==typeof t&&!isNaN(t)}function g(t){return(0|t)===t}function v(t){return"object"==typeof t&&!!t}function y(t){return!p(t)&&("string"==typeof t||null!==t.constructor&&t.constructor===String)}function _(t){return!p(t)&&("function"==typeof t||null!==t.constructor&&t.constructor===Function)}var x=Object.prototype.hasOwnProperty;function b(t,e){return x.call(t,e)}var w=Math.PI/180;function M(t){return t*w}function S(t){return t/w}var T,E,A="[object process]"===Object.prototype.toString.call(void 0!==t?t:0)&&!t.versions.electron&&!t.versions.nw&&!t.versions["node-webkit"];function C(t){var e="data:image/svg+xml";return t.length>4&&".svg"===t.slice(-4)?1:t.slice(0,e.length)===e?2:0}function P(t,e){A&&P.node?P.node(t,e):t.src=e[0]}!function(){if(A)return T=function(t){return setTimeout(t,16)},void(E=clearTimeout);var t,e;function n(t){return setTimeout(t,1e3/30)}function r(t){return window["webkit"+t]||window["moz"+t]||window["ms"+t]}"undefined"!=typeof window?(t=window.requestAnimationFrame||r("RequestAnimationFrame")||n,e=window.cancelAnimationFrame||r("CancelAnimationFrame")||r("CancelRequestAnimationFrame")||function(t){window.clearTimeout(t)}):(t=n,e=clearTimeout),T=function(e){return t(e)},E=function(t){t&&e(t)}}();var L=0;function O(){return L++}var R=O;function k(t){return t&&y(t)?JSON.parse(t):t}function I(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];if(n)for(var r=0,i=n.length;r<i;r++)t.push(n[r])}return t.length}function D(t,e){var n=e.indexOf(t);n>-1&&e.splice(n,1)}function j(t,e,n){if(!Array.isArray(t))return n?e.call(n,t):e(t);for(var r,i,o=[],a=0,s=t.length;a<s;a++)p(r=t[a])?o.push(null):Array.isArray(r)?o.push(j(r,e,n)):(i=n?e.call(n,r):e(r),o.push(i));return o}function z(t,e){return void 0===t?e:t}function N(t){return Math.sign?Math.sign(t):0==(t=+t)||isNaN(t)?Number(t):t>0?1:-1}function F(t){if(Math.log2)return Math.log2(t);var e=Math.log(t)*Math.LOG2E,n=Math.round(e);return Math.abs(n-e)<1e-14?n:e}function B(t,e,n){return t*(1-n)+e*n}function H(t,e,n){if(t===n||t===e)return t;var r=n-e;return((t-e)%r+r)%r+e}function G(t,e,n){return Math.min(n,Math.max(e,t))}function U(t){return Array.isArray(t)&&t.length>0}var W=/^([a-z][a-z\d+\-.]*:)?\/\//i,V=/^url\((['"])(.+)\1\)$/i,Z=/^url\(([^'"].*[^'"])\)$/i;function q(t){return y(t)?Z.test(t)?1:V.test(t)?2:3:0}function Y(t){var e=q(t);return 3===e?t:1===e?Z.exec(t)[1]:2===e?V.exec(t)[2]:t}function J(t){if("undefined"!=typeof window&&window.btoa)return window.btoa(t);for(var e,n,r=String(t),i="",o=0,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";r.charAt(0|o)||(a="=",o%1);i+=a.charAt(63&e>>8-o%1*8)){if((n=r.charCodeAt(o+=3/4))>255)throw new Error("'btoa' failed: The string to be encoded contains characters outside of the Latin1 range.");e=e<<8|n}return i}function X(t,e){for(var n=atob(t),r=new ArrayBuffer(n.length),i=new Uint8Array(r),o=0;o<n.length;o++)i[o]=255&n.charCodeAt(o);return new Blob([r],{type:e})}function $(t,e,n,r){var i=n-t,o=r-e;return Math.atan2(o,i)}var Q="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7";function K(t,e){if(!t&&!e)return!0;if(!t||!e)return!1;for(var n in t)if("center"===n){if(!e[n]||!tt(t[n][0],e[n][0])||!tt(t[n][1],e[n][1]))return!1}else if(t[n]!==e[n])return!1;return!0}function tt(t,e,n){return null==n&&(n=1e-6),t>=e-n&&t<=e+n}function et(t,e,n,r){t||(t=100),e||(e=4);var i=this;return e*=2,this._flashTimeout&&clearTimeout(this._flashTimeout),this._flashTimeout=setTimeout((function o(){if(0===e)return i.show(),void(n&&(r?n.call(r):n()));e%2==0?i.hide():i.show(),e--,i._flashTimeout=setTimeout(o,t)}),t),this}var nt=["Unknown","Point","LineString","Polygon","MultiPoint","MultiLineString","MultiPolygon","GeometryCollection"];function rt(t){return new Function("f","var p = (f && f.properties || {}); return "+it(t))}function it(t){if(!t)return"true";var e=t[0];return t.length<=1?"any"===e?"false":"true":"("+("=="===e?at(t[1],t[2],"===",!1):"!="===e?at(t[1],t[2],"!==",!1):"<"===e||">"===e||"<="===e||">="===e?at(t[1],t[2],e,!0):"any"===e?st(t.slice(1),"||"):"all"===e?st(t.slice(1),"&&"):"none"===e?lt(st(t.slice(1),"||")):"in"===e?ut(t[1],t.slice(2)):"!in"===e?lt(ut(t[1],t.slice(2))):"has"===e?ct(t[1]):"!has"===e?lt(ct(t[1])):"true")+")"}function ot(t){return"$"===t[0]?"f."+t.substring(1):"p["+JSON.stringify(t)+"]"}function at(t,e,n,r){var i=ot(t),o="$type"===t?nt.indexOf(e):JSON.stringify(e);return(r?"typeof "+i+"=== typeof "+o+"&&":"")+i+n+o}function st(t,e){return t.map(it).join(e)}function ut(t,e){"$type"===t&&(e=e.map((function(t){return nt.indexOf(t)})));var n=JSON.stringify(e.sort(ht)),r=ot(t);return e.length<=200?n+".indexOf("+r+") !== -1":"function(v, a, i, j) {\n while (i <= j) { var m = (i + j) >> 1;\n if (a[m] === v) return true; if (a[m] > v) j = m - 1; else i = m + 1;\n }\n return false; }("+r+", "+n+",0,"+(e.length-1)+")"}function ct(t){return"$id"===t?'"id" in f':JSON.stringify(t)+" in p"}function lt(t){return"!("+t+")"}function ht(t,e){return t<e?-1:t>e?1:0}function ft(t){var e=t._toJSON(),n=e.feature;return n.type=nt.indexOf(n.geometry.type),n.subType=e.subType,n}function dt(t){if(!Array.isArray(t))return dt([t]);for(var e=[],n=0;n<t.length;n++){var r;r=!0===t[n].filter?function(){return!0}:rt(t[n].filter),e.push(pt({},t[n],{filter:r}))}return e}function pt(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)t[r]=n[r]}return t}function mt(t,e){for(var n=0;n<t.stops.length;n++)if(e===t.stops[n][0])return t.stops[n][1];return t.default}function gt(t,e){for(var n=0;n<t.stops.length&&!(e<t.stops[n][0]);n++);return t.stops[Math.max(n-1,0)][1]}function vt(t,e){for(var n=void 0!==t.base?t.base:1,r=0;!(r>=t.stops.length||e<=t.stops[r][0]);)r++;return 0===r?t.stops[r][1]:r===t.stops.length?t.stops[r-1][1]:function t(e,n,r,i,o,a){return"function"==typeof o?function(){var s=o.apply(void 0,arguments),u=a.apply(void 0,arguments);return t(e,n,r,i,s,u)}:o.length?function(t,e,n,r,i,o){for(var a=[],s=0;s<i.length;s++)a[s]=_t(t,e,n,r,i[s],o[s]);return a}(e,n,r,i,o,a):_t(e,n,r,i,o,a)}(e,n,t.stops[r-1][0],t.stops[r][0],t.stops[r-1][1],t.stops[r][1])}function yt(t,e){return function(t,e,n){return void 0!==t?t:void 0!==e?e:void 0!==n?n:null}(e,t.default)}function _t(t,e,n,r,i,o){var a,s=r-n,u=t-n;return i*(1-(a=1===e?u/s:(Math.pow(e,u)-1)/(Math.pow(e,s)-1)))+o*a}function xt(t){return t&&"object"==typeof t&&(t.stops||t.property&&"identity"===t.type)}function bt(t){for(var e in t)if(xt(t[e]))return!0;return!1}function wt(t){return Tt(t,"exponential")}function Mt(t,e){if(!t)return null;var n=!1;if(Array.isArray(t)){for(var r,i=[],o=0;o<t.length;o++)(r=Mt(t[o],e))?(i.push(r),n=!0):i.push(t[o]);return n?i:t}var a,s={__fn_types_loaded:!0},u=[];for(a in t)t.hasOwnProperty(a)&&u.push(a);for(var c=function(t){Object.defineProperty(s,t,{get:function(){return this["__fn_"+t]||(this["__fn_"+t]=wt(this["_"+t])),this["__fn_"+t].apply(this,e())},set:function(e){this["_"+t]=e},configurable:!0,enumerable:!0})},l=0,h=u.length;l<h;l++)xt(t[a=u[l]])?(n=!0,s["_"+a]=t[a],c(a)):s[a]=t[a];return n?s:t}function St(t){if(!t||!t.stops)return[];for(var e=[],n=0,r=t.stops.length;n<r;n++)e.push(t.stops[n][1]);return e}function Tt(t,e){if(!xt(t))return function(){return t};var n=!0,r=!0,i=(t=JSON.parse(JSON.stringify(t))).stops;if(i)for(var o=0;o<i.length;o++)if(xt(i[o][1])){var a=Tt(i[o][1],e);n=n&&a.isZoomConstant,r=r&&a.isFeatureConstant,i[o]=[i[o][0],a]}var s=function t(e,n){var r,i,o;if(xt(e)){var a,s=e.stops&&"object"==typeof e.stops[0][0],u=s||void 0!==e.property,c=s||!u,l=e.type||n||"exponential";if("exponential"===l)a=vt;else if("interval"===l)a=gt;else if("categorical"===l)a=mt;else{if("identity"!==l)throw new Error('Unknown function type "'+l+'"');a=yt}if(s){for(var h={},f=[],d=0;d<e.stops.length;d++){var p=e.stops[d];void 0===h[p[0].zoom]&&(h[p[0].zoom]={zoom:p[0].zoom,type:e.type,property:e.property,default:e.default,stops:[]}),h[p[0].zoom].stops.push([p[0].value,p[1]])}for(var m in h)f.push([h[m].zoom,t(h[m])]);r=function(t,n){var r=vt({stops:f,base:e.base},t)(t,n);return"function"==typeof r?r(t,n):r},i=!1,o=!1}else c?(r=function(t){var n=a(e,t);return"function"==typeof n?n(t):n},i=!0,o=!1):(r=function(t,n){var r=a(e,n?n[e.property]:null);return"function"==typeof r?r(t,n):r},i=!1,o=!0)}else r=function(){return e},i=!0,o=!0;return r.isZoomConstant=o,r.isFeatureConstant=i,r}(t,e);return s.isZoomConstant=n&&s.isZoomConstant,s.isFeatureConstant=r&&s.isFeatureConstant,s}var Et=Object.freeze({createFilter:rt,getFilterFeature:ft,compileStyle:dt,isFunctionDefinition:xt,hasFunctionDefinition:bt,interpolated:wt,piecewiseConstant:function(t){return Tt(t,"interval")},loadFunctionTypes:Mt,getFunctionTypeResources:St});function At(t){var e={stroke:{stroke:t.markerLineColor,"stroke-width":t.markerLineWidth,"stroke-opacity":t.markerLineOpacity,"stroke-dasharray":null,"stroke-linecap":"butt","stroke-linejoin":"round"},fill:{fill:t.markerFill,"fill-opacity":t.markerFillOpacity}};return 0===e.stroke["stroke-width"]&&(e.stroke["stroke-opacity"]=0),e}function Ct(t,e,n){if(!t.markerPath)return null;var r=1,i=At(t);m(t.markerOpacity)&&(r=t.markerOpacity),m(t.opacity)&&(r*=t.opacity);var o={};if(i){for(var a in i.stroke)i.stroke.hasOwnProperty(a)&&(p(i.stroke[a])||(o[a]=i.stroke[a]));for(var s in i.fill)i.fill.hasOwnProperty(s)&&(p(i.fill[s])||(o[s]=i.fill[s]))}for(var u,c=Array.isArray(t.markerPath)?t.markerPath:[t.markerPath],l=[],h=0;h<c.length;h++)(u=d({},u=y(c[h])?{path:c[h]}:c[h],o)).d=u.path,delete u.path,l.push(u);var f=['<svg version="1.1"','xmlns="http://www.w3.org/2000/svg"'];r<1&&f.push('opacity="'+r+'"'),t.markerPathWidth&&t.markerPathHeight&&f.push('viewBox="0 0 '+t.markerPathWidth+" "+t.markerPathHeight+'"'),f.push('preserveAspectRatio="none"'),e&&f.push('width="'+e+'"'),n&&f.push('height="'+n+'"'),f.push("><defs></defs>");for(var g=0;g<l.length;g++){var v="<path ";for(var _ in l[g])l[g].hasOwnProperty(_)&&(v+=" "+_+'="'+l[g][_]+'"');v+="></path>",f.push(v)}return f.push("</svg>"),"data:image/svg+xml;base64,"+J(f.join(" "))}function Pt(t,e){if(!t)return[];var n=t;Array.isArray(t)||(n=[t]);for(var r,i,o,a,c=[],l=s,h=n.length-1;h>=0;h--)if(t=n[h]){e&&(t=Lt(t));for(var f=0;f<l.length;f++)if(xt(r=t[l[f]])&&(r=St(r)),r){Array.isArray(r)||(r=[r]);for(var d=0;d<r.length;d++)"url("===r[d].slice(0,4)&&(r[d]=Y(r[d])),i=u[f],c.push([r[d],t[i[0]],t[i[1]]])}if("path"===t.markerType&&t.markerPath)if(o=xt(t.markerWidth)?200:t.markerWidth,a=xt(t.markerHeight)?200:t.markerHeight,xt(t.markerPath)){r=St(t.markerPath);for(var p=t.markerPath,m=0;m<r.length;m++)t.markerPath=r[m],c.push([Ct(t),o,a]);t.markerPath=p}else c.push([Ct(t),o,a])}return c}function Lt(t){if(!t)return null;var e=t;if(A)return e;for(var n,r=s,i=0,o=r.length;i<o;i++)(n=e[r[i]])&&(e[r[i]]=Ot(n));return e}function Ot(t){if(xt(t)){for(var e=t.stops,n=0;n<e.length;n++)e[n][1]=Ot(e[n][1]);return t}return"url("===t.slice(0,4)&&(t=Y(t)),t}function Rt(t){return t&&t.colorStops}function kt(t){var e=[t.type];if(t.places&&e.push(t.places.join()),t.colorStops){for(var n=[],r=t.colorStops.length-1;r>=0;r--)n.push(t.colorStops[r].join());e.push(n.join(","))}return e.join("_")}function It(t,e){function n(t,e){p(t.opacity)?t.opacity=e:t.opacity*=e}var r;if(Array.isArray(t)){r=[];for(var i=0;i<t.length;i++){var o=d({},t[i]);n(o,e),r.push(o)}}else n(r=d({},t),e);return r}function Dt(t){var e=Array.prototype.slice.call(arguments,1);if(e&&e.length||(e=[{}]),Array.isArray(t)){for(var n,r,i=[],o=0,a=t.length;o<a;o++){n=t[o],r={};for(var s=0,u=e.length;s<u;s++)Array.isArray(e[s])?p(e[s][o])?d(r,n||{}):d(r,n,e[s][o]):d(r,n,e[s]?e[s]:{});i.push(r)}return i}var c=[{},t];return c.push.apply(c,e),d.apply(this,c)}function jt(t){if(t.symbol&&(t=[t]),Array.isArray(t))return t;var e=t.$root,n=t.$iconset;return t=t.style,(e||n)&&(e&&"/"===e[e.length-1]&&(e=e.substring(0,e.length-1)),n&&"/"===n[n.length-1]&&(n=n.substring(0,n.length-1)),t=zt(t,(function(t){return"{$root}"===t?e:"{$iconset}"===t?n:null}))),t}function zt(t,e){for(var n=0;n<t.length;n++){var r=t[n].symbol;r&&Ft(r,e)}}var Nt=/(\{\$root\}|\{\$iconset\})/g;function Ft(t,e){for(var n in t)t.hasOwnProperty(n)&&"textName"!==n&&(y(t[n])&&t[n].length>2?t[n]=t[n].replace(Nt,e):xt(t[n])?t[n]=Bt(t[n],e):v(t[n])&&Ft(t[n],e))}function Bt(t,e){var n=t.default;y(n)&&(t.default=n.replace(Nt,e));for(var r=t.stops,i=0;i<r.length;i++)Array.isArray(r[i])&&(y(r[i][1])?r[i][1]=r[i][1].replace(Nt,e):xt(r[i][1])&&(r[i][1]=Bt(r[i][1],e)));return t}var Ht=Object.freeze({now:f,extend:d,isNil:p,isNumber:m,isInteger:g,isObject:v,isString:y,isFunction:_,hasOwn:b,join:function(t,e){return t.join?t.join(e||","):Array.prototype.join.call(t,e||",")},isEmpty:function(t){var e;for(e in t)return!1;return!e},toRadian:M,toDegree:S,IS_NODE:A,get requestAnimFrame(){return T},get cancelAnimFrame(){return E},isSVG:C,loadImage:P,UID:O,GUID:R,parseJSON:k,pushIn:I,removeFromArray:D,forEachCoord:j,getValueOrDefault:z,sign:N,log2:F,interpolate:B,wrap:H,clamp:G,isArrayHasData:U,isURL:function(t){return W.test(t)},isCssUrl:q,extractCssUrl:Y,btoa:J,b64toBlob:X,computeDegree:$,emptyImageUrl:Q,equalMapView:K,flash:et,_defaults:function(t,e){for(var n=Object.getOwnPropertyNames(e),r=0;r<n.length;r++){var i=n[r],o=Object.getOwnPropertyDescriptor(e,i);o&&o.configurable&&void 0===t[i]&&Object.defineProperty(t,i,o)}return t},translateToSVGStyles:At,getMarkerPathBase64:Ct,getExternalResources:Pt,convertResourceUrl:Lt,isGradient:Rt,getGradientStamp:kt,getSymbolStamp:function t(e){var n=[];if(Array.isArray(e)){for(var r=0;r<e.length;r++)n.push(t(e[r]));return"[ "+n.join(" , ")+" ]"}for(var i in e)b(e,i)&&(_(e[i])||(Rt(e[i])?n.push(i+"="+kt(e[i])):n.push(i+"="+e[i])));return n.join(";")},lowerSymbolOpacity:It,extendSymbol:Dt,parseStyleRootPath:jt,convertStylePath:zt}),Gt={};if(!A){var Ut=navigator.userAgent.toLowerCase(),Wt=document.documentElement,Vt="ActiveXObject"in window,Zt=-1!==Ut.indexOf("webkit"),qt=-1!==Ut.indexOf("phantom"),Yt=-1!==Ut.search("android [23]"),Jt=-1!==Ut.indexOf("chrome"),Xt=-1!==Ut.indexOf("gecko")&&!Zt&&!window.opera&&!Vt,$t="undefined"!=typeof orientation||-1!==Ut.indexOf("mobile"),Qt=!window.PointerEvent&&window.MSPointerEvent,Kt=window.PointerEvent&&navigator.pointerEnabled||Qt,te=Vt&&"transition"in Wt.style,ee="WebKitCSSMatrix"in window&&"m11"in new window.WebKitCSSMatrix&&!Yt,ne="MozPerspective"in Wt.style,re="OTransition"in Wt.style,ie=(te||ee||ne)&&!re&&!qt,oe=0;Jt&&(oe=Ut.match(/chrome\/([\d.]+)/)[1]);var ae,se=!qt&&(Kt||"ontouchstart"in window||window.DocumentTouch&&document instanceof window.DocumentTouch);try{var ue=document.createElement("canvas"),ce=ue.getContext("webgl")||ue.getContext("experimental-webgl");ae=ce&&ce instanceof WebGLRenderingContext}catch(t){ae=!1}var le=window.devicePixelRatio||window.screen.deviceXDPI/window.screen.logicalXDPI;Gt={ie:Vt,ielt9:Vt&&!document.addEventListener,edge:"msLaunchUri"in navigator&&!("documentMode"in document),webkit:Zt,gecko:Xt,android:-1!==Ut.indexOf("android"),android23:Yt,chrome:Jt,chromeVersion:oe,safari:!Jt&&-1!==Ut.indexOf("safari"),phantomjs:qt,ie3d:te,webkit3d:ee,gecko3d:ne,opera12:re,any3d:ie,mobile:$t,mobileWebkit:$t&&Zt,mobileWebkit3d:$t&&ee,mobileOpera:$t&&window.opera,mobileGecko:$t&&Xt,touch:!!se,msPointer:!!Qt,pointer:!!Kt,retina:le>1,devicePixelRatio:le,language:navigator.browserLanguage?navigator.browserLanguage:navigator.language,ie9:Vt&&9===document.documentMode,ie10:Vt&&10===document.documentMode,webgl:ae}}var he=Gt;function fe(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}function de(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}var pe=function(){function t(t,e){if(p(t)||p(e)?p(t.x)||p(t.y)?Array.isArray(t)&&(this.x=+t[0],this.y=+t[1]):(this.x=+t.x,this.y=+t.y):(this.x=+t,this.y=+e),this._isNaN())throw new Error("Position is NaN")}var e=t.prototype;return e.set=function(t,e){return this.x=t,this.y=e,this},e.abs=function(){return new this.constructor(Math.abs(this.x),Math.abs(this.y))},e._abs=function(){return this.x=Math.abs(this.x),this.y=Math.abs(this.y),this},e._round=function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this},e.round=function(){return new this.constructor(Math.round(this.x),Math.round(this.y))},e._ceil=function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this},e.ceil=function(){return new this.constructor(Math.ceil(this.x),Math.ceil(this.y))},e.distanceTo=function(t){var e=t.x-this.x,n=t.y-this.y;return Math.sqrt(e*e+n*n)},e._floor=function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this},e.floor=function(){return new this.constructor(Math.floor(this.x),Math.floor(this.y))},e.copy=function(){return new this.constructor(this.x,this.y)},e._add=function(t,e){return p(t.x)?p(t[0])?(this.x+=t,this.y+=e):(this.x+=t[0],this.y+=t[1]):(this.x+=t.x,this.y+=t.y),this},e.add=function(t,e){var n,r;return p(t.x)?p(t[0])?(n=this.x+t,r=this.y+e):(n=this.x+t[0],r=this.y+t[1]):(n=this.x+t.x,r=this.y+t.y),new this.constructor(n,r)},e._sub=function(t,e){return p(t.x)?p(t[0])?(this.x-=t,this.y-=e):(this.x-=t[0],this.y-=t[1]):(this.x-=t.x,this.y-=t.y),this},e._substract=function(){return this._sub.apply(this,arguments)},e.sub=function(t,e){var n,r;return p(t.x)?p(t[0])?(n=this.x-t,r=this.y-e):(n=this.x-t[0],r=this.y-t[1]):(n=this.x-t.x,r=this.y-t.y),new this.constructor(n,r)},e.substract=function(){return this.sub.apply(this,arguments)},e.multi=function(t){return new this.constructor(this.x*t,this.y*t)},e._multi=function(t){return this.x*=t,this.y*=t,this},e.div=function(t){return this.multi(1/t)},e._div=function(t){return this._multi(1/t)},e.equals=function(t){return t instanceof this.constructor&&this.x===t.x&&this.y===t.y},e._isNaN=function(){return isNaN(this.x)||isNaN(this.y)},e.isZero=function(){return 0===this.x&&0===this.y},e.toArray=function(){return[this.x,this.y]},e.toFixed=function(t){return new this.constructor(this.x.toFixed(t),this.y.toFixed(t))},e.toJSON=function(){return{x:this.x,y:this.y}},t}(),me=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.closeTo=function(t,e){return e||(e=0),this.x>=t.x-e&&this.x<=t.x+e&&this.y>=t.y-e&&this.y<=t.y+e},n.mag=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},n.unit=function(){return this.copy()._unit()},n._unit=function(){return this._div(this.mag()),this},n.perp=function(){return this.copy()._perp()},n._perp=function(){var t=this.y;return this.y=this.x,this.x=-t,this},n.angleWith=function(t){return this.angleWithSep(t.x,t.y)},n.angleWithSep=function(t,e){return Math.atan2(this.x*e-this.y*t,this.x*t+this.y*e)},n._rotate=function(t){var e=Math.cos(t),n=Math.sin(t),r=e*this.x-n*this.y,i=n*this.x+e*this.y;return this.x=r,this.y=i,this},n.rotate=function(t){return this.copy()._rotate(t)},e}(pe),ge=function(){function t(t,e){m(t)&&m(e)?(this.width=t,this.height=e):m(t.width)?(this.width=t.width,this.height=t.height):Array.isArray(t)&&(this.width=t[0],this.height=t[1])}var e=t.prototype;return e.copy=function(){return new t(this.width,this.height)},e.add=function(e,n){var r,i;return e instanceof t?(r=this.width+e.width,i=this.height+e.height):(r=this.width+e,i=this.height+n),new t(r,i)},e.equals=function(t){return this.width===t.width&&this.height===t.height},e.multi=function(e){return new t(this.width*e,this.height*e)},e._multi=function(t){return this.width*=t,this.height*=t,this},e._round=function(){return this.width=Math.round(this.width),this.height=Math.round(this.height),this},e.toPoint=function(){return new me(this.width,this.height)},e.toArray=function(){return[this.width,this.height]},e.toJSON=function(){return{width:this.width,height:this.height}},t}();function ve(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}var ye=/[\b\t\r\v\f]/gim;function _e(t){return y(t)?t.replace(ye,""):t}function xe(t){return ve(t).split(/\s+/)}var be="undefined"!=typeof document?document.createElement("canvas").getContext("2d"):null;function we(t,e){return we.node?we.node(t,e):(be.font=e,be.measureText(t).width)}function Me(t,e,n){var r=we(t,e);return new ge(r,n||h)}function Se(t,e,n,r){if(!t||0===t.length)return[{text:"",width:0}];var i=p(r)?we(t,e):r,o=i/t.length,a=Math.floor(n/o/2);if(o>=n||a<=0)return[{text:"",width:n}];if(i<=n)return[{text:t,width:i}];for(var s=[],u=t.substring(0,a),c=o*a,l=a,h=t.length;l<h;l++){var f=t[l],d=we(u+f);d>=n?(s.push({text:u,width:c}),u=t.substring(l,a+l),l+=a-1,c=o*a):(u+=f,c=d),l>=h-1&&(c=we(u),s.push({text:u,width:c}))}return s}var Te=/\{([\w_]+)\}/g;function Ee(t,e){return y(t)?t.replace(Te,(function(t,n){if(!e)return"";var r=e[n];return p(r)?"":Array.isArray(r)?r.join():r})):t}function Ae(t,e,n){var r=t.width,i=t.height;return new me("left"===e?-r:"right"===e?0:-r/2,"top"===n?-i:"bottom"===n?0:-i/2)}function Ce(t){return t.textFont?t.textFont:(t.textStyle&&"normal"!==t.textStyle?t.textStyle+" ":"")+(t.textWeight&&"normal"!==t.textWeight?t.textWeight+" ":"")+t.textSize+"px "+(t.textFaceName?'"'===t.textFaceName[0]?t.textFaceName:'"'+t.textFaceName+'"':"monospace")}function Pe(t,e){var n=Ce(e),r=e.textLineSpacing||0,i=Me(t,n,e.textSize),o=i.width,a=i.height,s=e.textWrapCharacter,u=[],c=e.textWrapWidth;(!c||c>o)&&(c=o),y(t)||(t+="");var l=0;if(s&&t.indexOf(s)>=0)for(var h=t.split(s),f=0,d=h.length;f<d;f++){var p=h[f],m=we(p,n);if(m>c)for(var g=Se(p,n,c,m),v=0,_=g.length;v<_;v++){var x=g[v].width;x>l&&(l=x),u.push({text:g[v].text,size:new ge(x,a)})}else m>l&&(l=m),u.push({text:p,size:new ge(m,a)})}else if(o>c)for(var b=Se(t,n,c,o),w=0;w<b.length;w++){var M=b[w].width;M>l&&(l=M),u.push({text:b[w].text,size:new ge(M,a)})}else o>l&&(l=o),u.push({text:t,size:i});var S=u.length;return{total:S,size:new ge(l,a*S+r*(S-1)),rows:u,rawSize:i}}var Le=Object.freeze({trim:ve,escapeSpecialChars:_e,splitWords:xe,stringWidth:we,stringLength:Me,getFontHeight:function(t){var e=nn("span");"_default_"!==t&&(e.style.font=t),e.innerHTML="秦";var n=e.clientHeight;return Ne(e),n},splitContent:Se,replaceVariable:Ee,getAlignPoint:Ae,getFont:Ce,splitTextToRow:Pe}),Oe=A?function(t){return t[0]}:function(t){for(var e=document.documentElement.style,n=0;n<t.length;n++)if(t[n]in e)return t[n];return!1},Re=Oe(["transform","WebkitTransform","OTransform","MozTransform","msTransform"]),ke=Oe(["transformOrigin","WebkitTransformOrigin","OTransformOrigin","MozTransformOrigin","msTransformOrigin"]),Ie=Oe(["transition","WebkitTransition","OTransition","MozTransition","msTransition"]),De=Oe(["filter","WebkitFilter","OFilter","MozFilter","msFilter"]);function je(t,e){var n=document.createElement(t);return e&&$e(n,e),n}function ze(t,e,n){var r=je(t);return e&&Ye(r,e),n&&n.appendChild(r),r}function Ne(t){if(!t)return this;if(he.ielt9||he.ie9){var e=je("div");e.appendChild(t),e.innerHTML="",e=null}else t.parentNode&&t.parentNode.removeChild(t);return this}function Fe(t,e,n,r){if(!(t&&t.addEventListener&&e&&n))return this;for(var i=function(e){e||(e=window.event),n.call(r||t,e)},o=e.split(" "),a=o.length-1;a>=0;a--){var s=o[a];s&&(t["Z__"+s]||(t["Z__"+s]=[]),He(t,s,n)>=0&&Be(t,s,n),t["Z__"+s].push({callback:i,src:n}),he.ie?t.addEventListener(s,i,!1):t.addEventListener(s,i,{capture:!1,passive:!1}))}return this}function Be(t,e,n){function r(e,n){"mousewheel"===e&&he.gecko&&(e="DOMMouseScroll"),t.removeEventListener(e,n,!1)}if(!t||!t.removeEventListener||!e)return this;for(var i=e.split(" "),o=i.length-1;o>=0;o--){var a=i[o];if(a){if(!n&&t["Z__"+a]){for(var s=t["Z__"+a],u=0,c=s.length;u<c;u++)r(s[u].callback);return delete t["Z__"+a],this}var l=He(t,a,n);if(l<0)return this;r(a,t["Z__"+a][l].callback),t["Z__"+a].splice(l,1)}}return this}function He(t,e,n){if(!t||!t["Z__"+e]||!n)return-1;for(var r=t["Z__"+e],i=0,o=r.length;i<o;i++)if(r[i].src===n)return i;return-1}function Ge(t){return t.preventDefault?t.preventDefault():t.returnValue=!1,this}function Ue(t){return t.stopPropagation?t.stopPropagation():t.cancelBubble=!0,this}function We(t){return t.onselectstart=function(){return!1},t.ondragstart=function(){return!1},t.setAttribute("unselectable","on"),this}function Ve(t,e){return t?(he.any3d?Ke(t,e):(t.style.left=e.x+"px",t.style.top=e.y+"px"),e):null}function Ze(t){var e=window.getComputedStyle(t),n=[parseInt(e["padding-left"]),parseInt(e["padding-top"])],r=t.getBoundingClientRect(),i=t.offsetWidth,o=t.offsetHeight,a=i?r.width/i:1,s=o?r.height/o:1;return t.__position=[r.left+n[0],r.top+n[1],a,s],t.__position}function qe(t,e){t||(t=window.event);var n=e.__position;return n||(n=Ze(e)),new me((t.clientX-n[0]-e.clientLeft)/n[2],(t.clientY-n[1]-e.clientTop)/n[3])}function Ye(t,e){var n=t.style.cssText;return function(t,e){var n=t.length-e.length;return n>=0&&t.indexOf(e,n)===n}(n,";")||(n+=";"),t.style.cssText=n+e,this}function Je(t,e){if(void 0!==t.classList)return t.classList.contains(e);var n=Qe(t);return n.length>0&&new RegExp("(^|\\s)"+e+"(\\s|$)").test(n)}function Xe(t,e){if(void 0===t.classList||Je(t,e)){var n=Qe(t);$e(t,(n?n+" ":"")+e)}else for(var r=xe(e),i=0,o=r.length;i<o;i++)t.classList.add(r[i]);return this}function $e(t,e){return p(t.className.baseVal)?t.className=e:t.className.baseVal=e,this}function Qe(t){return p(t.className.baseVal)?t.className:t.className.baseVal}function Ke(t,e){var n=e||new me(0,0);return t.style[Re]=he.any3d?"translate3d("+n.x+"px,"+n.y+"px,0px)":"translate("+n.x+"px,"+n.y+"px)",this}function tn(t){return/<[a-z\][\s\S]*>/i.test(t)}function en(t,e){var n=nn(t);y(e)?n.innerHTML=e:n.appendChild(e);var r=new ge(n.clientWidth,n.clientHeight);return Ne(n),r}function nn(t){var e=document.createElement(t);return e.style.cssText="position:absolute;left:-10000px;top:-10000px;",document.body.appendChild(e),e}var rn=Fe,on=Be,an=Object.freeze({TRANSFORM:Re,TRANSFORMORIGIN:ke,TRANSITION:Ie,CSSFILTER:De,createEl:je,createElOn:ze,removeDomNode:Ne,addDomEvent:Fe,removeDomEvent:Be,listensDomEvent:He,preventDefault:Ge,stopPropagation:Ue,preventSelection:We,offsetDom:Ve,computeDomPosition:Ze,getEventContainerPoint:qe,setStyle:Ye,hasClass:Je,addClass:Xe,setClass:$e,getClass:Qe,setOpacity:function(t,e){return t.style.opacity=e,this},setTransform:Ke,setTransformMatrix:function(t,e){var n="matrix("+(y(e)?e:e.join())+")";return t.style[Re]!==n&&(t.style[Re]=n),this},removeTransform:function(t){return t.style[Re]&&(t.style[Re]=""),this},isHTML:tn,measureDom:en,getDomRuler:nn,on:rn,off:on}),sn={jsonp:function(t,e){var n="_maptalks_jsonp_"+O();t.match(/\?/)?t+="&callback="+n:t+="?callback="+n;var r=document.createElement("script");return r.type="text/javascript",r.src=t,window[n]=function(t){e(null,t),document.getElementsByTagName("head")[0].removeChild(r),r=null,delete window[n]},document.getElementsByTagName("head")[0].appendChild(r),this},get:function(t,e,n){if(_(e)){var r=n;n=e,e=r}if(A&&sn.get.node)return sn.get.node(t,n,e);var i=sn._getClient(n);if(i.open("GET",t,!0),e){for(var o in e.headers)i.setRequestHeader(o,e.headers[o]);i.withCredentials="include"===e.credentials,e.responseType&&(i.responseType=e.responseType)}return i.send(null),i},post:function(t,e,n){var r;if(y(t)){if(_(e)){var i=n;n=e,e=i}r=(e=e||{}).postData}else{var o=n;r=e,t=(e=t).url,n=o}if(A&&sn.post.node)return e.url=t,sn.post.node(e,r,n);var a=sn._getClient(n);if(a.open("POST",e.url,!0),e.headers||(e.headers={}),e.headers["Content-Type"]||(e.headers["Content-Type"]="application/x-www-form-urlencoded"),"setRequestHeader"in a)for(var s in e.headers)e.headers.hasOwnProperty(s)&&a.setRequestHeader(s,e.headers[s]);return y(r)||(r=JSON.stringify(r)),a.send(r),a},_wrapCallback:function(t,e){return function(){4===t.readyState&&(200===t.status?"arraybuffer"===t.responseType?0===t.response.byteLength?e(new Error("http status 200 returned without content.")):e(null,{data:t.response,cacheControl:t.getResponseHeader("Cache-Control"),expires:t.getResponseHeader("Expires"),contentType:t.getResponseHeader("Content-Type")}):e(null,t.responseText):e(new Error(t.statusText+","+t.status)))}},_getClient:function(t){var e;try{e=new XMLHttpRequest}catch(t){try{e=new ActiveXObject("Msxml2.XMLHTTP")}catch(t){try{e=new ActiveXObject("Microsoft.XMLHTTP")}catch(t){}}}return e.onreadystatechange=sn._wrapCallback(e,t),e},getArrayBuffer:function(t,e,n){if(_(e)){var r=n;n=e,e=r}return e||(e={}),e.responseType="arraybuffer",sn.get(t,e,n)},getImage:function(t,e,n){return sn.getArrayBuffer(e,n,(function(e,n){if(e)t.onerror&&t.onerror(e);else if(n){var r=window.URL||window.webkitURL,i=t.onload;t.onload=function(){i&&i(),r.revokeObjectURL(t.src)};var o=new Blob([new Uint8Array(n.data)],{type:n.contentType});t.cacheControl=n.cacheControl,t.expires=n.expires,t.src=n.data.byteLength?r.createObjectURL(o):Q}}))},getJSON:function(t,e,n){if(_(e)){var r=n;n=e,e=r}var i=function(t,e){var r=e?k(e):null;n(t,r)};return e&&e.jsonp?sn.jsonp(t,i):sn.get(t,e,i)}},un=!1,cn=null,ln=Math.PI/180,hn={setHitTesting:function(t){un=t},createCanvas:function(t,e,n){var r;return A?r=new n(t,e):((r=je("canvas")).width=t,r.height=e),r},prepareCanvasFont:function(t,e){t.textBaseline="top",t.font=Ce(e);var n=e.textFill;n||(n="#000"),t.fillStyle=hn.getRgba(n,e.textOpacity)},prepareCanvas:function(t,e,n,r){if(e){var i=e.lineWidth;p(i)||t.lineWidth===i||(t.lineWidth=i);var o=e.linePatternFile,a=e.lineColor||"#000";if(r)t.strokeStyle="#000";else if(o&&n){var s;(e.linePatternDx||e.linePatternDy)&&(s=[e.linePatternDx,e.linePatternDy]),hn._setStrokePattern(t,o,i,s,n),e.lineDasharray=[]}else Rt(a)?e.lineGradientExtent?t.strokeStyle=hn._createGradient(t,a,e.lineGradientExtent):t.strokeStyle="#000":t.strokeStyle=a;e.lineJoin&&(t.lineJoin=e.lineJoin),e.lineCap&&(t.lineCap=e.lineCap),t.setLineDash&&U(e.lineDasharray)&&t.setLineDash(e.lineDasharray);var u=e.polygonPatternFile,c=e.polygonFill||"rgba(255,255,255,0)";if(r)t.fillStyle="#000";else if(u&&n){var l=pn(u),h=n.getImage([l,null,null]);if(h||(h=n.getImage([l+"-texture",null,i])),C(l)&&h instanceof Image&&(he.edge||he.ie)){var f=h.width||20,d=h.height||20,m=hn.createCanvas(f,d);hn.image(m.getContext("2d"),h,0,0,f,d),h=m}h?(t.fillStyle=t.createPattern(h,"repeat"),(e.polygonPatternDx||e.polygonPatternDy)&&(t.fillStyle.polygonPatternOffset=[e.polygonPatternDx,e.polygonPatternDy])):"undefined"!=typeof console&&console.warn("img not found for",l)}else Rt(c)?e.polygonGradientExtent?t.fillStyle=hn._createGradient(t,c,e.polygonGradientExtent):t.fillStyle="rgba(255,255,255,0)":t.fillStyle=c}},_createGradient:function(t,e,n){var r=null,i=e.places,o=n.getMin(),a=n.getMax(),s=n.getWidth(),u=n.getHeight();if(e.type&&"linear"!==e.type){if("radial"===e.type){if(i){if(6!==i.length)throw new Error("A radial gradient's places should have 6 numbers.");i=[o.x+i[0]*s,o.y+i[1]*u,s*i[2],o.x+i[3]*s,o.y+i[4]*u,s*i[5]]}else{var c=n.getCenter()._round();i=[c.x,c.y,Math.abs(c.x-o.x),c.x,c.y,0]}r=t.createRadialGradient.apply(t,i)}}else{if(i){if(4!==i.length)throw new Error("A linear gradient's places should have 4 numbers.");i=[o.x+i[0]*s,o.y+i[1]*u,o.x+i[2]*s,o.y+i[3]*u]}else i=[o.x,o.y,a.x,o.y];r=t.createLinearGradient.apply(t,i)}return e.colorStops.forEach((function(t){r.addColorStop.apply(r,t)})),r},_setStrokePattern:function(t,e,n,r,i){var o,a=pn(e);if(A)o=i.getImage([a,null,n]);else{var s=a+"-texture-"+n;if(!(o=i.getImage(s))){var u=i.getImage([a,null,null]);if(u){var c;c=u.width&&u.height?Math.round(u.width*n/u.height):n;var l=hn.createCanvas(c,n,t.canvas.constructor);hn.image(l.getContext("2d"),u,0,0,c,n),i.addResource([s,null,n],l),o=l}}}o?(t.strokeStyle=t.createPattern(o,"repeat"),t.strokeStyle.linePatternOffset=r):"undefined"!=typeof console&&console.warn("img not found for",a)},clearRect:function(t,e,n,r,i){t.canvas._drawn=!1,t.clearRect(e,n,r,i)},fillCanvas:function(t,e,n,r){if(un&&(e=1),t.canvas._drawn=!0,0!==e){var i,o=hn._isPattern(t.fillStyle),a=t.fillStyle&&t.fillStyle.polygonPatternOffset,s=a?a[0]:0,u=a?a[1]:0;p(e)&&(e=1),e<1&&(i=t.globalAlpha,t.globalAlpha*=e),o&&(n=n||0,r=r||0,t.translate(n+s,r+u)),t.fill(),o&&t.translate(-n-s,-r-u),e<1&&(t.globalAlpha=i)}},getRgba:function(t,e){return p(e)&&(e=1),"#"!==t[0]?t:(7===t.length?(n=parseInt(t.substring(1,3),16),r=parseInt(t.substring(3,5),16),i=parseInt(t.substring(5,7),16)):(n=17*parseInt(t.substring(1,2),16),r=17*parseInt(t.substring(2,3),16),i=17*parseInt(t.substring(3,4),16)),"rgba("+n+","+r+","+i+","+e+")");var n,r,i},image:function(t,e,n,r,i,o){t.canvas._drawn=!0;try{m(i)&&m(o)?t.drawImage(e,n,r,i,o):t.drawImage(e,n,r)}catch(t){console&&(console.warn("error when drawing image on canvas:",t),console.warn(e))}},text:function(t,e,n,r,i){hn._textOnMultiRow(t,i.rows,r,n,i.size,i.rawSize)},_textOnMultiRow:function(t,e,n,r,i,o){for(var a,s,u=Ae(i,n.textHorizontalAlignment,n.textVerticalAlignment),c=o.height+n.textLineSpacing,l=r.add(0,u.y),h=n.textMaxHeight,f=0,d=0,p=e.length;d<p&&(a=e[d].text,s=Ae(e[d].size,n.textHorizontalAlignment,n.textVerticalAlignment),hn._textOnLine(t,a,l.add(s.x,d*c),n.textHaloRadius,n.textHaloFill,n.textHaloOpacity),!(h>0&&(f+=c,f+o.height>=h)));d++);},_textOnLine:function(t,e,n,r,i,o){un&&(o=1);var a,s,u=0!==o&&0!==r;t.textBaseline="top";var c=t.shadowBlur,l=t.shadowOffsetX,h=t.shadowOffsetY;if(u){var f=t.globalAlpha;t.globalAlpha*=o,t.miterLimit=2,t.lineJoin="round",t.lineCap="round",t.lineWidth=2*r,t.strokeStyle=i,t.strokeText(e,n.x,n.y+1),t.miterLimit=10,t.globalAlpha=f,a=t.globalCompositeOperation,t.globalCompositeOperation="destination-out",s=t.fillStyle,t.fillStyle="#000"}c&&u&&(t.shadowBlur=t.shadowOffsetX=t.shadowOffsetY=0),hn.fillText(t,e,n),a&&(t.globalCompositeOperation=a,hn.fillText(t,e,n,s),c&&(t.shadowBlur=c,t.shadowOffsetX=l,t.shadowOffsetY=h))},fillText:function(t,e,n,r){t.canvas._drawn=!0,r&&(t.fillStyle=r),t.fillText(e,n.x,n.y+1)},_stroke:function(t,e,n,r){if(un&&(e=1),t.canvas._drawn=!0,0!==e){var i,o=t.strokeStyle&&t.strokeStyle.linePatternOffset,a=o?o[0]:0,s=o?o[1]:0,u=hn._isPattern(t.strokeStyle)&&(!p(n)&&!p(r)||!p(a)&&!p(s));p(e)&&(e=1),e<1&&(i=t.globalAlpha,t.globalAlpha*=e),u&&(n=n||0,r=r||0,t.translate(n+a,r+s)),t.stroke(),u&&t.translate(-n-a,-r-s),e<1&&(t.globalAlpha=i)}},_path:function(t,e,n,r,i){if(U(e))for(var o,a,s=U(n),u=!0!==i&&hn._isPattern(t.strokeStyle),c=0,l=e.length;c<l;c++)if(o=e[c],!s||t.setLineDash)t.lineTo(o.x,o.y),u&&c>0&&(h(e[c-1],o),t.beginPath(),t.moveTo(o.x,o.y));else if(s){if(c===l-1)break;a=e[c+1],fn(t,o,a,n)}function h(e,n){var i=$(e.x,e.y,n.x,n.y);t.save();var o=Math.cos(i);Math.abs(o)<1e-7?t.translate(e.x-t.lineWidth/2,e.y):t.translate(e.x,e.y-t.lineWidth/2/o),t.rotate(i),hn._stroke(t,r),t.restore()}},path:function(t,e,n,r,i){U(e)&&(t.beginPath(),t.moveTo(e[0].x,e[0].y),hn._path(t,e,i,n),hn._stroke(t,n))},_multiClip:function(t,e){if(e&&0!==e.length)for(var n=0,r=(e=e[0]).length;n<r;n++){var i=e[n],o=i.x,a=i.y;0===n?t.moveTo(o,a):t.lineTo(o,a),n===r-1&&(o=e[0].x,a=e[0].y,t.lineTo(o,a))}},polygon:function(t,e,n,r,i,o){if(t.isMultiClip)hn._multiClip(t,e);else if(U(e)){var a=hn._isPattern(t.strokeStyle),s=U(i)&&!t.setLineDash||a&&!o;U(e[0])||(e=[e]);var u,c,l,h=t;if(e.length>1&&!A&&(cn||(cn=hn.createCanvas(1,1)),t.canvas._drawn=!1,cn.width=t.canvas.width,cn.height=t.canvas.height,mn(t=cn.getContext("2d"),h)),s){for(t.save(),c=0,l=e.length;c<l;c++)U(e[c])&&(hn._ring(t,e[c],null,0,!0),u=r,c>0&&(t.globalCompositeOperation="destination-out",u=1),hn.fillCanvas(t,u,e[c][0].x,e[c][0].y),c>0?t.globalCompositeOperation="source-over":l>1&&(t.fillStyle="#fff"),hn._stroke(t,0));t.restore()}for(c=0,l=e.length;c<l;c++)U(e[c])&&(o?(hn.paintSmoothLine(t,e[c],n,o,!0),t.closePath()):hn._ring(t,e[c],i,n),s||(u=r,c>0&&(t.globalCompositeOperation="destination-out",u=1),hn.fillCanvas(t,u,e[c][0].x,e[c][0].y),c>0?t.globalCompositeOperation="source-over":l>1&&(t.fillStyle="#fff")),hn._stroke(t,n));e.length>1&&!A&&(h.drawImage(cn,0,0),h.canvas._drawn=t.canvas._drawn,mn(h,t))}},_ring:function(t,e,n,r,i){var o=hn._isPattern(t.strokeStyle);i||!o||e[0].equals(e[e.length-1])||(e=e.concat([e[0]])),t.beginPath(),t.moveTo(e[0].x,e[0].y),hn._path(t,e,n,r,i),o||t.closePath()},paintSmoothLine:function(t,e,n,r,i,o,a){if(e)if(e.length<=2||!r)hn.path(t,e,n);else{var s,u=e.length,c=i?u:u-1;t.beginPath(),t.moveTo(e[0].x,e[0].y),void 0!==a&&(c-=Math.max(c-o-1,0));for(var l=0;l<c;l++){var h=e[l].x,f=e[l].y,d=void 0,p=void 0,m=void 0,g=void 0,v=void 0,y=void 0;l-1<0?i?(d=e[c-1].x,p=e[c-1].y):(d=e[l+1].x,p=e[l+1].y):(d=e[l-1].x,p=e[l-1].y),l+1<u?(m=e[l+1].x,g=e[l+1].y):(m=e[l+1-u].x,g=e[l+1-u].y),l+2<u?(v=e[l+2].x,y=e[l+2].y):i?(v=e[l+2-u].x,y=e[l+2-u].y):(v=e[l].x,y=e[l].y);var _=b(d,p,h,f,m,g,v,y,r,l===c-1?a:1);if(l===c-1&&a>=0&&a<1){t.bezierCurveTo(_[0],_[1],_[2],_[3],_[4],_[5]),e.splice(c-1,u-(c-1)-1);var x=new me(_[4],_[5]);x.prevCtrlPoint=new me(_[2],_[3]),e.push(x),u=e.length}else t.bezierCurveTo(_[0],_[1],_[2],_[3],m,g);e[l].nextCtrlPoint=_.slice(0,2),e[l].prevCtrlPoint=s?s.slice(2):null,s=_}!i&&e[1].prevCtrlPoint&&(e[0].nextCtrlPoint=e[1].prevCtrlPoint,delete e[0].prevCtrlPoint),e[u-1].prevCtrlPoint||(e[u-1].prevCtrlPoint=e[u-2].nextCtrlPoint),hn._stroke(t,n)}function b(t,e,n,r,i,o,a,s,u,c){var l=(t+n)/2,h=(e+r)/2,f=(n+i)/2,d=(r+o)/2,p=(i+a)/2,m=(o+s)/2,g=Math.sqrt((n-t)*(n-t)+(r-e)*(r-e)),v=Math.sqrt((i-n)*(i-n)+(o-r)*(o-r)),y=g/(g+v),_=v/(v+Math.sqrt((a-i)*(a-i)+(s-o)*(s-o))),x=l+(f-l)*y,b=h+(d-h)*y,w=f+(p-f)*_,M=d+(m-d)*_,S=x+(f-x)*u+n-x,T=b+(d-b)*u+r-b,E=w+(f-w)*u+i-w,A=M+(d-M)*u+o-M,C=[S,T,E,A];return c<1?function(t,e,n,r,i,o,a,s,u,c){var l=1-t,h=1-e,f=n*h*h+2*i*e*h+a*e*e,d=i*h*h+2*a*e*h+u*e*e,p=r*h*h+2*o*e*h+s*e*e,m=o*h*h+2*s*e*h+c*e*e;return[(n*l*l+2*i*t*l+a*t*t)*h+(i*l*l+2*a*t*l+u*t*t)*e,(r*l*l+2*o*t*l+s*t*t)*h+(o*l*l+2*s*t*l+c*t*t)*e,f*l+d*t,p*l+m*t,f*h+d*e,p*h+m*e]}(0,c,n,r,S,T,E,A,i,o):C}},_arcBetween:function(t,e,n,r){var i=r,o=e.distanceTo(n),a=o/2/Math.sin(i/2),s=Math.asin((n.y-e.y)/o);e.x>n.x&&(s=Math.PI-s);var u=s-(90*ln-i/2),c=Math.cos(u)*a,l=Math.sin(u)*a,h=e.x+c,f=e.y+l,d=Math.asin((n.y-f)/a);h>n.x&&(d=Math.PI-d);var p=d+i;return t.beginPath(),t.arc(h,f,a,d,p),[h,f]},_lineTo:function(t,e){t.lineTo(e.x,e.y)},bezierCurveAndFill:function(t,e,n,r){t.beginPath();var i=e[0];t.moveTo(i.x,i.y);var o=[t];o.push.apply(o,e.splice(1)),hn._bezierCurveTo.apply(hn,o),hn.fillCanvas(t,r),hn._stroke(t,n)},_bezierCurveTo:function(t,e,n,r){t.bezierCurveTo(e.x,e.y,n.x,n.y,r.x,r.y)},ellipse:function(t,e,n,r,i,o,a){t.beginPath(),n===r&&n===i?t.arc(e.x,e.y,n,0,2*Math.PI):t.ellipse?r!==i?(t.ellipse(e.x,e.y,n,r,0,180*ln,360*ln,!1),t.ellipse(e.x,e.y,n,i,0,0,180*ln,!1)):t.ellipse(e.x,e.y,n,r,0,0,360*ln,!1):function(e,n,r,i,o){var a=.5522848,s=r*a,u=i*a,c=o*a;t.moveTo(e-r,n),t.bezierCurveTo(e-r,n-u,e-s,n-i,e,n-i),t.bezierCurveTo(e+s,n-i,e+r,n-u,e+r,n),t.bezierCurveTo(e+r,n+c,e+s,n+o,e,n+o),t.bezierCurveTo(e-s,n+o,e-r,n+c,e-r,n),t.closePath()}(e.x,e.y,n,r,i),hn.fillCanvas(t,a,e.x-n,e.y-r),hn._stroke(t,o,e.x-n,e.y-r)},rectangle:function(t,e,n,r,i){var o=e.x,a=e.y;t.beginPath(),t.rect(o,a,n.width,n.height),hn.fillCanvas(t,i,o,a),hn._stroke(t,r,o,a)},sector:function(t,e,n,r,i,o){var a=ln,s=r[0],u=r[1];!function(t,e,n,r,s,u){var c=a*-u,l=a*-s;t.beginPath(),t.moveTo(e,n),t.arc(e,n,r,c,l),t.lineTo(e,n),hn.fillCanvas(t,o,e-r,n-r),hn._stroke(t,i,e-r,n-r)}(t,e.x,e.y,n,s,u)},_isPattern:function(t){return!y(t)&&!("addColorStop"in t)},drawCross:function(t,e,n,r,i){t.canvas._drawn=!0,t.strokeStyle=i,t.lineWidth=r,t.beginPath(),t.moveTo(e-5,n),t.lineTo(e+5,n),t.moveTo(e,n-5),t.lineTo(e,n+5),t.stroke()},copy:function(t,e){var n=e||je("canvas");return n.width=t.width,n.height=t.height,n.getContext("2d").drawImage(t,0,0),n}};function fn(t,e,n,r){var i=e.x,o=e.y,a=n.x,s=n.y,u=r,c=function(t,e){return t<=e},l=function(t,e){return t>=e},h=function(t,e){return Math.min(t,e)},f=function(t,e){return Math.max(t,e)},d={thereYet:l,cap:h},p={thereYet:l,cap:h};o-s>0&&(p.thereYet=c,p.cap=f),i-a>0&&(d.thereYet=c,d.cap=f),t.moveTo(i,o);for(var m,g,v=i,y=o,_=0,x=!0;!d.thereYet(v,a)||!p.thereYet(y,s);)m=Math.atan2(s-o,a-i),g=u[_],v=d.cap(a,v+Math.cos(m)*g),y=p.cap(s,y+Math.sin(m)*g),x?t.lineTo(v,y):t.moveTo(v,y),_=(_+1)%u.length,x=!x}var dn="data:image/";function pn(t){return t.substring(0,dn.length)===dn?t:Y(t)}function mn(t,e){t.filter=e.filter,t.fillStyle=e.fillStyle,t.globalAlpha=e.globalAlpha,t.lineCap=e.lineCap,t.lineDashOffset=e.lineDashOffset,t.lineJoin=e.lineJoin,t.lineWidth=e.lineWidth,t.shadowBlur=e.shadowBlur,t.shadowColor=e.shadowColor,t.shadowOffsetX=e.shadowOffsetX,t.shadowOffsetY=e.shadowOffsetY,t.strokeStyle=e.strokeStyle}var gn="undefined"!=typeof window?window:void 0!==r?r:"undefined"!=typeof self?self:{};function vn(t,e){return t(e={exports:{}},e.exports),e.exports}var yn=vn((function(t){!function(e){function n(t){if(t){var e=this;t((function(t){e.resolve(t)}),(function(t){e.reject(t)}))}}function r(t,e){if("function"==typeof t.y)try{var n=t.y.call(a,e);t.p.resolve(n)}catch(e){t.p.reject(e)}else t.p.resolve(e)}function i(t,e){if("function"==typeof t.n)try{var n=t.n.call(a,e);t.p.resolve(n)}catch(e){t.p.reject(e)}else t.p.reject(e)}var o,a,s="fulfilled",u="undefined",c=function(){function t(){for(;n.length-r;){try{n[r]()}catch(t){e.console&&e.console.error(t)}n[r++]=a,r==i&&(n.splice(0,i),r=0)}}var n=[],r=0,i=1024,o=function(){if(typeof MutationObserver!==u){var e=document.createElement("div");return new MutationObserver(t).observe(e,{attributes:!0}),function(){e.setAttribute("a",0)}}return typeof setImmediate!==u?function(){setImmediate(t)}:function(){setTimeout(t,0)}}();return function(t){n.push(t),n.length-r==1&&o()}}();n.prototype={resolve:function(t){if(this.state===o){if(t===this)return this.reject(new TypeError("Attempt to resolve promise with self"));var e=this;if(t&&("function"==typeof t||"object"==typeof t))try{var n=!0,i=t.then;if("function"==typeof i)return void i.call(t,(function(t){n&&(n=!1,e.resolve(t))}),(function(t){n&&(n=!1,e.reject(t))}))}catch(t){return void(n&&this.reject(t))}this.state=s,this.v=t,e.c&&c((function(){for(var n=0,i=e.c.length;i>n;n++)r(e.c[n],t)}))}},reject:function(t){if(this.state===o){this.state="rejected",this.v=t;var r=this.c;r?c((function(){for(var e=0,n=r.length;n>e;e++)i(r[e],t)})):!n.suppressUncaughtRejectionError&&e.console&&e.console.log("You upset Zousan. Please catch rejections: ",t,t?t.stack:null)}},then:function(t,e){var a=new n,u={y:t,n:e,p:a};if(this.state===o)this.c?this.c.push(u):this.c=[u];else{var l=this.state,h=this.v;c((function(){l===s?r(u,h):i(u,h)}))}return a},catch:function(t){return this.then(null,t)},finally:function(t){return this.then(t,t)},timeout:function(t,e){e=e||"Timeout";var r=this;return new n((function(n,i){setTimeout((function(){i(Error(e))}),t),r.then((function(t){n(t)}),(function(t){i(t)}))}))}},n.resolve=function(t){var e=new n;return e.resolve(t),e},n.reject=function(t){var e=new n;return e.reject(t),e},n.all=function(t){function e(e,a){e&&"function"==typeof e.then||(e=n.resolve(e)),e.then((function(e){r[a]=e,++i==t.length&&o.resolve(r)}),(function(t){o.reject(t)}))}for(var r=[],i=0,o=new n,a=0;a<t.length;a++)e(t[a],a);return t.length||o.resolve(r),o},t.exports&&(t.exports=n),e.define&&e.define.amd&&e.define([],(function(){return n})),e.Zousan=n,n.soon=c}(gn)})),_n="undefined"!=typeof Promise?Promise:yn,xn=function(t){return function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.on=function(t,e,n){if(!t)return this;if(!y(t))return this._switch("on",t,e);if(!e)return this;this._eventMap||(this._eventMap={});var r,i,o=t.toLowerCase().split(" ");n||(n=this);for(var a=0,s=o.length;a<s;a++){r=o[a],(i=this._eventMap[r])||(i=[],this._eventMap[r]=i);var u=i.length;if(u>0)for(var c=0;c<u;c++)if(e===i[c].handler&&i[c].context===n)return this;i.push({handler:e,context:n})}return this},n.addEventListener=function(){return this.on.apply(this,arguments)},n.once=function(t,e,n){if(!y(t)){var r={};for(var i in t)t.hasOwnProperty(i)&&(r[i]=this._wrapOnceHandler(i,t[i],n));return this._switch("on",r)}for(var o=t.split(" "),a=0,s=o.length;a<s;a++)this.on(o[a],this._wrapOnceHandler(o[a],e,n));return this},n.off=function(t,e,n){if(!this._eventMap||!t)return this;if(!y(t))return this._switch("off",t,e);if(!e)return this;var r,i,o,a=t.split(" ");n||(n=this);for(var s=0,u=a.length;s<u;s++){if(o="Z__"+(r=a[s].toLowerCase()),!(i=this._eventMap[r]))return this;for(var c=i.length-1;c>=0;c--){var l=i[c];e!==l.handler&&e!==l.handler[o]||l.context!==n||(delete l.handler[o],i.splice(c,1))}i.length||delete this._eventMap[r]}return this},n.removeEventListener=function(){return this.off.apply(this,arguments)},n.listens=function(t,e,n){if(!this._eventMap||!y(t))return 0;var r=this._eventMap[t.toLowerCase()];if(!r||!r.length)return 0;if(!e)return r.length;for(var i=0,o=r.length;i<o;i++)if(e===r[i].handler&&(p(n)||r[i].context===n))return 1;return 0},n.getListeningEvents=function(){return this._eventMap?Object.keys(this._eventMap):[]},n.copyEventListeners=function(t){var e,n=t._eventMap;if(!n)return this;for(var r in n)for(var i=0,o=(e=n[r]).length;i<o;i++)this.on(r,e[i].handler,e[i].context);return this},n.fire=function(){return this._eventParent?this._eventParent.fire.apply(this._eventParent,arguments):this._fire.apply(this,arguments)},n._wrapOnceHandler=function(t,e,n){var r=this,i="Z__"+t,o=!1,a=function s(){o||(delete a[i],o=!0,n?e.apply(n,arguments):e.apply(this,arguments),r.off(t,s,this))};return a[i]=e,a},n._switch=function(t,e,n){for(var r in e)e.hasOwnProperty(r)&&this[t](r,e[r],n);return this},n._clearListeners=function(t){this._eventMap&&y(t)&&this._eventMap[t.toLowerCase()]&&(this._eventMap[t]=null)},n._clearAllListeners=function(){this._eventMap=null},n._setEventParent=function(t){return this._eventParent=t,this},n._setEventTarget=function(t){return this._eventTarget=t,this},n._fire=function(t,e){if(!this._eventMap)return this;var n=this._eventMap[t.toLowerCase()];if(!n)return this;e||(e={}),e.type=t,e.target=this._eventTarget||this;for(var r,i,o=n.slice(0),a=0,s=o.length;a<s;a++)o[a]&&(r=o[a].context,i=d({},e),!1===(r?o[a].handler.call(r,i):o[a].handler(i))&&e.domEvent&&Ue(e.domEvent));return this},e}(t)},bn=function(){function t(t){this.target=t}var e=t.prototype;return e.enable=function(){return this._enabled||(this._enabled=!0,this.addHooks()),this},e.disable=function(){return this._enabled?(this._enabled=!1,this.removeHooks(),this):this},e.enabled=function(){return!!this._enabled},e.remove=function(){this.disable(),delete this.target,delete this.dom},t}(),wn=xn(bn),Mn=function(){function t(t){if(!this||!this.setOptions)throw new Error('Class instance is being created without "new" operator.');this.setOptions(t),this.callInitHooks()}var e=t.prototype;return e.callInitHooks=function(){var t=Object.getPrototypeOf(this);return this._visitInitHooks(t),this},e.setOptions=function(t){if(this.hasOwnProperty("options")||(this.options=this.options?Object.create(this.options):{}),!t)return this;for(var e in t)this.options[e]=t[e];return this},e.config=function(t){if(!t){var e={};for(var n in this.options)this.options.hasOwnProperty(n)&&(e[n]=this.options[n]);return e}if(2===arguments.length){var r={};r[t]=arguments[1],t=r}for(var i in t)this.options[i]=t[i],this[i]&&this[i]instanceof wn&&(t[i]?this[i].enable():this[i].disable());return this.onConfig(t),this},e.onConfig=function(){},e._visitInitHooks=function(t){if(!this._initHooksCalled){var e=Object.getPrototypeOf(t);e._visitInitHooks&&e._visitInitHooks.call(this,e),this._initHooksCalled=!0;var n=t._initHooks;if(n&&n!==e._initHooks)for(var r=0;r<n.length;r++)n[r].call(this)}},t.addInitHook=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];var i="function"==typeof t?t:function(){this[t].apply(this,n)},o=this.prototype,a=Object.getPrototypeOf(o);return o._initHooks&&o._initHooks!==a._initHooks||(o._initHooks=[]),o._initHooks.push(i),this},t.include=function(){for(var t=0;t<arguments.length;t++)d(this.prototype,t<0||arguments.length<=t?void 0:arguments[t]);return this},t.mergeOptions=function(t){var e=this.prototype,n=Object.getPrototypeOf(e);return e.options&&e.options!==n.options||(e.options=e.options?Object.create(e.options):{}),d(e.options,t),this},t}(),Sn={},Tn=function(t){return function(t){function e(){return t.apply(this,arguments)||this}return fe(e,t),e.registerJSONType=function(t){return t?(Sn[t]=this,this):this},e.getJSONClass=function(t){return t?Sn[t]:null},e.prototype.getJSONType=function(){if(void 0===this._jsonType){var t=Object.getPrototypeOf(this).constructor;for(var e in Sn)if(Sn[e]===t){this._jsonType=e;break}}if(!this._jsonType)throw new Error("Found an unregistered geometry class!");return this._jsonType},e}(t)};function En(t){return function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.addHandler=function(t,e){if(!e)return this;if(this._handlers||(this._handlers=[]),this[t])return this[t].enable(),this;var n=this[t]=new e(this);return this._handlers.push(n),this.options[t]&&n.enable(),this},n.removeHandler=function(t){if(!t)return this;var e=this[t];if(e){var n=this._handlers.indexOf(e);n>=0&&this._handlers.splice(n,1),this[t].remove(),delete this[t]}return this},n._clearHandlers=function(){for(var t=0,e=this._handlers.length;t<e;t++)this._handlers[t].remove();this._handlers=[]},e}(t)}var An="touchstart mousedown",Cn={mousedown:"mousemove",touchstart:"touchmove",pointerdown:"touchmove",MSPointerDown:"touchmove"},Pn={mousedown:"mouseup",touchstart:"touchend",pointerdown:"touchend",MSPointerDown:"touchend"},Ln=function(t){function e(e,n){var r;return void 0===n&&(n={}),(r=t.call(this,null)||this).dom=e,r.options=n,r}fe(e,t);var n=e.prototype;return n.enable=function(){return this.dom?(this._onMouseDown=function(t){return this.onMouseDown(t)},rn(this.dom,An,this._onMouseDown,this),this):this},n.disable=function(){return this.dom?(this._offEvents(),on(this.dom,An,this._onMouseDown),delete this._onMouseDown,this):this},n.onMouseDown=function(t){if((this.options.rightclick||2!==t.button)&&!(t.touches&&t.touches.length>1)&&(!this.options.cancelOn||!0!==this.options.cancelOn(t))){var e=this.dom;e.setCapture?e.setCapture():window.captureEvents&&window.captureEvents(window.Event.MOUSEMOVE|window.Event.MOUSEUP),e.ondragstart=function(){return!1},delete this.moved;var n=t.touches?t.touches[0]:t;this.startPos=new me(n.clientX,n.clientY),rn(document,Cn[t.type],this.onMouseMove,this),rn(document,Pn[t.type],this.onMouseUp,this),this.options.ignoreMouseleave||rn(this.dom,"mouseleave",this.onMouseUp,this),this.fire("mousedown",{domEvent:t,mousePos:new me(n.clientX,n.clientY)})}},n.onMouseMove=function(t){if(t.touches&&t.touches.length>1)this.moved&&(this.interupted=!0,this.onMouseUp(t));else{var e=t.touches?t.touches[0]:t,n=new me(e.clientX,e.clientY).sub(this.startPos);(n.x||n.y)&&(this.moved?this.fire("dragging",{domEvent:t,mousePos:new me(e.clientX,e.clientY)}):(this.fire("dragstart",{domEvent:t,mousePos:this.startPos.copy()}),this.moved=!0))}},n.onMouseUp=function(t){var e=t.changedTouches?t.changedTouches[0]:t;this._offEvents();var n={domEvent:t};m(e.clientX)&&(n.mousePos=new me(parseInt(e.clientX,0),parseInt(e.clientY,0))),this.moved&&(n.interupted=this.interupted,this.fire("dragend",n),delete this.interupted,delete this.moved),this.fire("mouseup",n)},n._offEvents=function(){var t=this.dom;if(on(t,"mouseleave",this.onMouseUp,this),"undefined"!=typeof document&&"undefined"!=typeof window){for(var e in Cn)on(document,Cn[e],this.onMouseMove,this),on(document,Pn[e],this.onMouseUp,this);t.releaseCapture?t.releaseCapture():window.captureEvents&&window.captureEvents(window.Event.MOUSEMOVE|window.Event.MOUSEUP)}},e}(wn),On=function(t){function e(){return t.apply(this,arguments)||this}return fe(e,t),e.toNumberArrays=function(t){return Array.isArray(t)?j(t,(function(t){return[t.x,t.y]})):[t.x,t.y]},e.toCoordinates=function(t){if(m(t[0])&&m(t[1]))return new e(t);for(var n=[],r=0,i=t.length;r<i;r++){var o=t[r];Array.isArray(o)?m(o[0])?n.push(new e(o)):n.push(e.toCoordinates(o)):n.push(new e(o))}return n},e}(pe),Rn=function(){function t(t,e){this.type=t,this.properties=e}return t.createProj4=function(e){return new t("proj4",{proj:e})},t.fromProjectionCode=function(e){return e&&t[e=e.toUpperCase().replace(":","")]||null},t}();Rn.WGS84=Rn.createProj4("+proj=longlat +datum=WGS84 +no_defs"),Rn.EPSG4326=Rn.WGS84,Rn.EPSG3857=Rn.createProj4("+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +wktext +no_defs"),Rn.IDENTITY=Rn.createProj4("+proj=identity +no_defs"),Rn.CGCS2000=Rn.createProj4("+proj=longlat +datum=CGCS2000"),Rn.EPSG4490=Rn.CGCS2000,Rn.BD09LL=Rn.createProj4("+proj=longlat +datum=BD09"),Rn.GCJ02=Rn.createProj4("+proj=longlat +datum=GCJ02");var kn,In=new me(0,0),Dn=new On(0,0),jn=new On(0,0),zn=new On(0,0),Nn=new On(0,0),Fn=new On(0,0),Bn=new On(0,0),Hn=new On(0,0),Gn=new On(0,0),Un=[],Wn=[],Vn=function(){function t(t,e,n,r){this._clazz=On;var i=arguments.length,o=i>0?arguments[i-1]:null;o&&o.unproject&&(this.projection=arguments[i-1]),this._dirty=!0,this._initialize(t,e,n,r)}var e=t.prototype;return e._initialize=function(t,e,n,r){if(this.xmin=null,this.xmax=null,this.ymin=null,this.ymax=null,!p(t)){var i=this.projection;m(t)&&m(e)&&m(n)&&m(r)?i?this.set(t,e,n,r):this.set(Math.min(t,n),Math.min(e,r),Math.max(t,n),Math.max(e,r)):Array.isArray(t)?i?this.set(t[0],t[1],t[2],t[3]):this.set(Math.min(t[0],t[2]),Math.min(t[1],t[3]),Math.max(t[0],t[2]),Math.max(t[1],t[3])):m(t.x)&&m(e.x)&&m(t.y)&&m(e.y)?i?this.set(t.x,t.y,e.x,e.y):(t.x>e.x?(this.xmin=e.x,this.xmax=t.x):(this.xmin=t.x,this.xmax=e.x),t.y>e.y?(this.ymin=e.y,this.ymax=t.y):(this.ymin=t.y,this.ymax=e.y)):m(t.xmin)&&m(t.xmax)&&m(t.ymin)&&m(t.ymax)&&this.set(t.xmin,t.ymin,t.xmax,t.ymax)}},e._add=function(t){return this._dirty=!0,p(t.x)?p(t.xmin)?p(t[0])||(this.xmin+=t[0],this.ymin+=t[1],this.xmax+=t[0],this.ymax+=t[1]):(this.xmin+=t.xmin,this.ymin+=t.ymin,this.xmax+=t.xmax,this.ymax+=t.ymax):(this.xmin+=t.x,this.ymin+=t.y,this.xmax+=t.x,this.ymax+=t.y),this},e.add=function(){var t=new this.constructor(this.xmin,this.ymin,this.xmax,this.ymax,this.projection);return t._add.apply(t,arguments)},e._scale=function(t){return this._dirty=!0,this.xmin*=t,this.ymin*=t,this.xmax*=t,this.ymax*=t,this},e._sub=function(t){return this._dirty=!0,p(t.x)?p(t.xmin)?p(t[0])||(this.xmin-=t[0],this.ymin-=t[1],this.xmax-=t[0],this.ymax-=t[1]):(this.xmin-=t.xmin,this.ymin-=t.ymin,this.xmax-=t.xmax,this.ymax-=t.ymax):(this.xmin-=t.x,this.ymin-=t.y,this.xmax-=t.x,this.ymax-=t.y),this},e._substract=function(){return this._sub.apply(this,arguments)},e.sub=function(){var t=new this.constructor(this.xmin,this.ymin,this.xmax,this.ymax,this.projection);return t._sub.apply(t,arguments)},e.substract=function(){return this.sub.apply(this,arguments)},e.round=function(){return new this.constructor(Math.round(this.xmin),Math.round(this.ymin),Math.round(this.xmax),Math.round(this.ymax),this.projection)},e._round=function(){return this._dirty=!0,this.xmin=Math.round(this.xmin),this.ymin=Math.round(this.ymin),this.xmax=Math.round(this.xmax),this.ymax=Math.round(this.ymax),this},e.getMin=function(t){return t?(t.set(this.xmin,this.ymin),t):new this._clazz(this.xmin,this.ymin)},e.getMax=function(t){return t?(t.set(this.xmax,this.ymax),t):new this._clazz(this.xmax,this.ymax)},e.getCenter=function(t){var e=(this.xmin+this.xmax)/2,n=(this.ymin+this.ymax)/2;return t?(t.set(e,n),t):new this._clazz(e,n)},e.isValid=function(){return!(p(this.xmin)||p(this.ymin)||p(this.xmax)||p(this.ymax))},e.equals=function(t){return this.xmin===t.xmin&&this.xmax===t.xmax&&this.ymin===t.ymin&&this.ymax===t.ymax},e.intersects=function(t){this._project(this),this._project(t);var e=Math.max(this.pxmin,t.pxmin),n=Math.max(this.pymin,t.pymin),r=Math.min(this.pxmax,t.pxmax),i=Math.min(this.pymax,t.pymax);return!(e>r||n>i)},e.within=function(t){return this._project(this),this._project(t),this.pxmin>=t.pxmin&&this.pxmax<=t.pxmax&&this.pymin>=t.pymin&&this.pymax<=t.pymax},e.contains=function(t){if(!t)return!1;this._project(this);var e=this.projection;if(e)if(void 0!==t.x){var n=Dn;Array.isArray(t)?(n.x=t[0],n.y=t[1]):(n.x=t.x,n.y=t.y),t=e.project(n,n)}else void 0!==t.xmin&&this._project(t);return(t.x||t.pxmin||0)>=this.pxmin&&(t.x||t.pxmax||0)<=this.pxmax&&(t.y||t.pymin||0)>=this.pymin&&(t.y||t.pymax||0)<=this.pymax},e.getWidth=function(){return Math.abs(this.xmax-this.xmin)},e.getHeight=function(){return Math.abs(this.ymax-this.ymin)},e.getSize=function(){return new ge(this.getWidth(),this.getHeight())},e.set=function(t,e,n,r){return this.xmin=t,this.ymin=e,this.xmax=n,this.ymax=r,this._dirty=!0,this},e.__combine=function(t){var e,n,r,i;void 0!==t.x&&(kn.xmin=kn.xmax=t.x,kn.ymin=kn.ymax=t.y,t=kn),this._project(t),this._project(this),m(this.pxmin)?(e=Math.min(this.pxmin,t.pxmin),n=Math.min(this.pymin,t.pymin),r=Math.max(this.pxmax,t.pxmax),i=Math.max(this.pymax,t.pymax)):(e=t.pxmin,n=t.pymin,r=t.pxmax,i=t.pymax);var o=this.projection;if(o){jn.set(e,n),zn.set(r,i);var a=o.unproject(jn,jn),s=o.unproject(zn,zn);e=a.x,n=a.y,r=s.x,i=s.y}return Wn[0]=e,Wn[1]=n,Wn[2]=r,Wn[3]=i,Wn},e._combine=function(t){if(!t||t.isValid&&!t.isValid())return this;var e=this.__combine(t);return this.set(e[0],e[1],e[2],e[3]),this._dirty=!0,this},e.combine=function(t){if(!t||t.isValid&&!t.isValid())return this;var e=this.__combine(t);return new this.constructor(e[0],e[1],e[2],e[3],this.projection)},e.intersection=function(t){if(!this.intersects(t))return null;Nn.x=Math.max(this.pxmin,t.pxmin),Nn.y=Math.max(this.pymin,t.pymin),Fn.x=Math.min(this.pxmax,t.pxmax),Fn.y=Math.min(this.pymax,t.pymax);var e=Nn,n=Fn,r=this.projection;return r&&(e=r.unproject(e,e),n=r.unproject(n,n)),new this.constructor(e,n,r)},e.expand=function(t){var e,n;return m(t)?e=n=t:(e=t.width||t.x||t[0]||0,n=t.height||t.y||t[1]||0),new this.constructor(this.xmin-e,this.ymin-n,this.xmax+e,this.ymax+n,this.projection)},e._expand=function(t){var e,n;return m(t)?e=n=t:(e=t.width||t.x||t[0]||0,n=t.height||t.y||t[1]||0),this.xmin-=e,this.ymin-=n,this.xmax+=e,this.ymax+=n,this._dirty=!0,this},e.toJSON=function(){return{xmin:this.xmin,ymin:this.ymin,xmax:this.xmax,ymax:this.ymax}},e.toArray=function(){var t=this.xmin,e=this.ymin,n=this.xmax,r=this.ymax;return[new this._clazz([t,r]),new this._clazz([n,r]),new this._clazz([n,e]),new this._clazz([t,e]),new this._clazz([t,r])]},e.toString=function(){return this.xmin+","+this.ymin+","+this.xmax+","+this.ymax},e.copy=function(){return new this.constructor(this.xmin,this.ymin,this.xmax,this.ymax,this.projection)},e.convertTo=function(t,e){if(!this.isValid())return null;var n,r=e||new this.constructor;return e&&r.set(null,null,null,null),this._clazz===On?n=Bn:this._clazz===me&&(n=In),n.x=this.xmin,n.y=this.ymax,r._combine(t(n)),n.x=this.xmax,r._combine(t(n)),n.y=this.ymin,r._combine(t(n)),n.x=this.xmin,r._combine(t(n)),r},e._project=function(t){if(t&&t.isValid()){var e=this.projection;if(e){if(t._dirty){Hn.set(t.xmax,t.ymin),Gn.set(t.xmin,t.ymax),Un[0]=Hn,Un[1]=Gn;var n=e.projectCoords(Un),r=n[0],i=n[1];t.pxmin=Math.min(r.x,i.x),t.pymin=Math.min(r.y,i.y),t.pxmax=Math.max(r.x,i.x),t.pymax=Math.max(r.y,i.y)}delete t._dirty}else t.pxmin=t.xmin,t.pxmax=t.xmax,t.pymin=t.ymin,t.pymax=t.ymax}else t&&(t.pxmin=t.pxmax=t.pymin=t.pymax=null)},t}();kn=new Vn(0,0,0,0);var Zn=function(t){function e(e,n,r,i){var o;return(o=t.call(this,e,n,r,i)||this)._clazz=me,o}return fe(e,t),e}(Vn),qn=function(){function t(t){this.matrix=t}var e=t.prototype;return e.transform=function(t,e,n){var r=this.matrix[0]*(t.x-this.matrix[2])/e,i=-this.matrix[1]*(t.y-this.matrix[3])/e;return n?(n.x=r,n.y=i,n):new me(r,i)},e.untransform=function(t,e,n){var r=t.x*e/this.matrix[0]+this.matrix[2],i=t.y*e/-this.matrix[1]+this.matrix[3];return n?(n.x=r,n.y=i,n):new On(r,i)},t}(),Yn={project:function(){},unproject:function(){},projectCoords:function(t){var e=this;if(!t)return[];if(!Array.isArray(t))return this.project(t);if(0===t.length)return[];if(!this.isSphere())return j(t,this.project,this);if(Array.isArray(t[0]))return t.map((function(t){return e.projectCoords(t)}));for(var n,r,i,o,a,s,u=this.getCircum(),c=this.getSphereExtent(),l=c.sx,h=c.sy,f=t[0],d=[this.project(f)],p=1,m=t.length;p<m;p++)o=(i=t[p]).x-f.x,a=i.y-f.y,s=this.project(i),Math.abs(o)>180&&(void 0===n&&(n=i.x>f.x),n&&(s._add(-u.x*N(o)*l,0),i._add(-360*N(o),0))),Math.abs(a)>90&&(void 0===r&&(r=i.y<f.y),r&&(s._add(0,-u.y*N(a)*h),i._add(0,-180*N(a)))),f=i,d.push(s);return d},unprojectCoords:function(t){return t?Array.isArray(t)?j(t,this.unproject,this):this.unproject(t):[]},isSphere:function(){return!!this.sphere},isOutSphere:function(t){return!!this.isSphere()&&!this.getSphereExtent().contains(t)},wrapCoord:function(t){if(!this.isSphere())return t;var e=this.getSphereExtent(),n=new On(t);return e.contains(n)||(n.x=H(t.x,e.xmin,e.xmax),n.y=H(t.y,e.ymin,e.ymax)),n},getCircum:function(){if(!this.circum&&this.isSphere()){var t=this.getSphereExtent();this.circum={x:t.getWidth(),y:t.getHeight()}}return this.circum},getSphereExtent:function(){if(!this.extent&&this.isSphere()){var t=this.project(new On(180,90)),e=this.project(new On(-180,-90));this.extent=new Vn(e,t,this),this.extent.sx=t.x>e.x?1:-1,this.extent.sy=t.y>e.y?1:-1}return this.extent}},Jn={measureLength:function(t,e){if(!Array.isArray(t))return this.measureLenBetween(t,e);for(var n=0,r=0,i=t.length;r<i-1;r++)n+=this.measureLenBetween(t[r],t[r+1]);return n}},Xn=d({measure:"IDENTITY",measureLenBetween:function(t,e){if(!t||!e)return 0;try{return Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))}catch(t){return 0}},measureArea:function(t){if(!Array.isArray(t))return 0;for(var e=0,n=0,r=t.length;n<r;n++){var i,o=t[n];i=n===r-1?t[0]:t[n+1],e+=o.x*i.y-o.y*i.x}return Math.abs(e/2)},locate:function(t,e,n){return t=new On(t.x,t.y),this._locate(t,e,n)},_locate:function(t,e,n){return t?(e||(e=0),n||(n=0),e||n?(t.x=t.x+e,t.y=t.y+n,t):t):null},rotate:function(t,e,n){return t=new On(t.x,t.y),this._rotate(t,e,n)},_rotate:function(){var t=new me(0,0);return function(e,n,r){return t.x=e.x-n.x,t.y=e.y-n.y,t._rotate(r*Math.PI/180),e.x=n.x+t.x,e.y=n.y+t.y,e}}()},Jn),$n=function(){function t(t){this.radius=t}var e=t.prototype;return e.measureLenBetween=function(t,e){if(!t||!e)return 0;var n=M(t.y),r=M(e.y),i=n-r,o=M(t.x)-M(e.x);return n=2*Math.asin(Math.sqrt(Math.pow(Math.sin(i/2),2)+Math.cos(n)*Math.cos(r)*Math.pow(Math.sin(o/2),2))),n*=this.radius,Math.round(1e5*n)/1e5},e.measureArea=function(t){var e,n=M(this.radius),r=0,i=t,o=i.length;if(o<3)return 0;for(e=0;e<o-1;e++){var a=i[e],s=i[e+1];r+=a.x*n*Math.cos(M(a.y))*s.y*n-s.x*n*Math.cos(M(s.y))*a.y*n}return o=i[e],i=i[0],r+=o.x*n*Math.cos(M(o.y))*i.y*n-i.x*n*Math.cos(M(i.y))*o.y*n,.5*Math.abs(r)},e.locate=function(t,e,n){return t=new On(t.x,t.y),this._locate(t,e,n)},e._locate=function(t,e,n){if(!t)return null;if(e||(e=0),n||(n=0),!e&&!n)return t;var r,i,o=M(t.y);if(0!==n){var a=Math.abs(n);i=H(180*(o+=2*Math.sin(a/(2*this.radius))*(n>0?1:-1))/Math.PI,-90,90)}else i=t.y;if(0!==e){var s=Math.abs(e),u=M(t.x);r=H(180*(u+=2*Math.sqrt(Math.pow(Math.sin(s/(2*this.radius)),2)/Math.pow(Math.cos(o),2))*(e>0?1:-1))/Math.PI,-180,180)}else r=t.x;return t.x=r,t.y=i,t},e.rotate=function(t,e,n){return t=new On(t),this._rotate(t,e,n)},e._rotate=function(t,e,n){var r=function(t,e,n){var r;return void 0===n&&(n={}),(r=n.final?Qn(e,t):Qn(t,e))>180?-(360-r):r}(e,t)-n,i=this.measureLenBetween(e,t);return t.x=e.x,t.y=e.y,function(t,e,n,r){var i=e/r,o=t.x*Math.PI/180,a=M(t.y),s=M(n),u=i*Math.cos(s),c=a+u;Math.abs(c)>Math.PI/2&&(c=c>0?Math.PI-c:-Math.PI-c);var l=Math.log(Math.tan(c/2+Math.PI/4)/Math.tan(a/2+Math.PI/4)),h=Math.abs(l)>1e-11?u/l:Math.cos(a),f=i*Math.sin(s)/h,d=o+f;return t.x=(180*d/Math.PI+540)%360-180,t.y=180*c/Math.PI,t}(t,i,r,this.radius)},t}();function Qn(t,e){var n=M(t.y),r=M(e.y),i=M(e.x-t.x);i>Math.PI&&(i-=2*Math.PI),i<-Math.PI&&(i+=2*Math.PI);var o=Math.log(Math.tan(r/2+Math.PI/4)/Math.tan(n/2+Math.PI/4));return(S(Math.atan2(i,o))+360)%360}var Kn=d({measure:"EPSG:4326",sphere:new $n(6378137),measureLenBetween:function(){return this.sphere.measureLenBetween.apply(this.sphere,arguments)},measureArea:function(){return this.sphere.measureArea.apply(this.sphere,arguments)},_locate:function(){return this.sphere._locate.apply(this.sphere,arguments)},locate:function(){return this.sphere.locate.apply(this.sphere,arguments)},_rotate:function(){return this.sphere._rotate.apply(this.sphere,arguments)},rotate:function(){return this.sphere.rotate.apply(this.sphere,arguments)}},Jn),tr=d({measure:"BAIDU",sphere:new $n(6370996.81),measureLenBetween:function(){return this.sphere.measureLenBetween.apply(this.sphere,arguments)},measureArea:function(){return this.sphere.measureArea.apply(this.sphere,arguments)},_locate:function(){return this.sphere._locate.apply(this.sphere,arguments)},locate:function(){return this.sphere.locate.apply(this.sphere,arguments)},_rotate:function(){return this.sphere._rotate.apply(this.sphere,arguments)},rotate:function(){return this.sphere.rotate.apply(this.sphere,arguments)}},Jn),er=Kn,nr={};function rr(t){nr[t.measure]=t}rr(Xn),rr(Kn),rr(tr);var ir,or={getInstance:function(t){if(!t)return er;for(var e in nr)if(b(nr,e)){var n=nr[e].measure;if(!n)continue;if(t.toLowerCase()===n.toLowerCase())return nr[e]}return null}},ar=Object.freeze({Identity:Xn,DEFAULT:er,Measurer:or,WGS84Sphere:Kn,BaiduSphere:tr}),sr=d({},Yn,{code:"EPSG:3857",rad:Math.PI/180,metersPerDegree:6378137*Math.PI/180,maxLatitude:85.0511287798,project:function(t,e){var n=this.rad,r=this.metersPerDegree,i=this.maxLatitude,o=t.x,a=Math.max(Math.min(i,t.y),-i),s=o*r,u=(0===a?0:Math.log(Math.tan((90+a)*n/2))/n)*r;return e?(e.x=s,e.y=u,e):new On(s,u)},unproject:function(t,e){var n,r=this.rad,i=this.metersPerDegree,o=t.x/i,a=t.y;0===a?n=0:(n=a/i,n=(2*Math.atan(Math.exp(n*r))-Math.PI/2)/r),Math.abs(Math.abs(o)-180)<1e-7&&(o=180*N(o)),Math.abs(Math.abs(n)-this.maxLatitude)<1e-7&&(n=N(n)*this.maxLatitude);var s=H(o,-180,180),u=H(n,-this.maxLatitude,this.maxLatitude);return e?(e.x=s,e.y=u,e):new On(s,u)}},Kn),ur=d({},Yn,{code:"EPSG:4326",project:function(t,e){return e?(e.x=t.x,e.y=t.y,e):new On(t)},unproject:function(t,e){return e?(e.x=t.x,e.y=t.y,e):new On(t)}},Kn),cr=d({},ur,{code:"EPSG:4490"}),lr=d({},Yn,{code:"BAIDU",project:function(t,e){return this.convertLL2MC(t,e)},unproject:function(t,e){return this.convertMC2LL(t,e)}},tr,{EARTHRADIUS:6370996.81,MCBAND:[12890594.86,8362377.87,5591021,3481989.83,1678043.12,0],LLBAND:[75,60,45,30,15,0],MC2LL:[[1.410526172116255e-8,898305509648872e-20,-1.9939833816331,200.9824383106796,-187.2403703815547,91.6087516669843,-23.38765649603339,2.57121317296198,-.03801003308653,17337981.2],[-7.435856389565537e-9,8983055097726239e-21,-.78625201886289,96.32687599759846,-1.85204757529826,-59.36935905485877,47.40033549296737,-16.50741931063887,2.28786674699375,10260144.86],[-3.030883460898826e-8,898305509983578e-20,.30071316287616,59.74293618442277,7.357984074871,-25.38371002664745,13.45380521110908,-3.29883767235584,.32710905363475,6856817.37],[-1.981981304930552e-8,8983055099779535e-21,.03278182852591,40.31678527705744,.65659298677277,-4.44255534477492,.85341911805263,.12923347998204,-.04625736007561,4482777.06],[3.09191371068437e-9,8983055096812155e-21,6995724062e-14,23.10934304144901,-.00023663490511,-.6321817810242,-.00663494467273,.03430082397953,-.00466043876332,2555164.4],[2.890871144776878e-9,8983055095805407e-21,-3.068298e-8,7.47137025468032,-353937994e-14,-.02145144861037,-1234426596e-14,.00010322952773,-323890364e-14,826088.5]],LL2MC:[[-.0015702102444,111320.7020616939,0x60e374c3105a3,-0x24bb4115e2e164,0x5cc55543bb0ae8,-0x7ce070193f3784,0x5e7ca61ddf8150,-0x261a578d8b24d0,0x665d60f3742ca,82.5],[.0008277824516172526,111320.7020463578,647795574.6671607,-4082003173.641316,10774905663.51142,-15171875531.51559,12053065338.62167,-5124939663.577472,913311935.9512032,67.5],[.00337398766765,111320.7020202162,4481351.045890365,-23393751.19931662,79682215.47186455,-115964993.2797253,97236711.15602145,-43661946.33752821,8477230.501135234,52.5],[.00220636496208,111320.7020209128,51751.86112841131,3796837.749470245,992013.7397791013,-1221952.21711287,1340652.697009075,-620943.6990984312,144416.9293806241,37.5],[-.0003441963504368392,111320.7020576856,278.2353980772752,2485758.690035394,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]],convertMC2LL:function(t,e){for(var n,r=0,i=this.MCBAND.length;r<i;r++)if(Math.abs(t.y)>=this.MCBAND[r]){n=this.MC2LL[r];break}return this.convertor(t,n,e)},convertLL2MC:function(t,e){var n,r,i;t.x=this.getLoop(t.x,-180,180),t.y=this.getRange(t.y,-74,74);var o=new On(t.x,t.y);for(r=0,i=this.LLBAND.length;r<i;r++)if(o.y>=this.LLBAND[r]){n=this.LL2MC[r];break}if(!n)for(r=this.LLBAND.length-1;r>=0;r--)if(o.y<=-this.LLBAND[r]){n=this.LL2MC[r];break}return this.convertor(t,n,e)},convertor:function(t,e,n){if(!t||!e)return null;var r=e[0]+e[1]*Math.abs(t.x),i=Math.abs(t.y)/e[9],o=e[2]+e[3]*i+e[4]*i*i+e[5]*i*i*i+e[6]*i*i*i*i+e[7]*i*i*i*i*i+e[8]*i*i*i*i*i*i;return r*=t.x<0?-1:1,o*=t.y<0?-1:1,n?(n.x=r,n.y=o,n):new On(r,o)},toRadians:function(t){return Math.PI*t/180},toDegrees:function(t){return 180*t/Math.PI},getRange:function(t,e,n){return null!=e&&(t=Math.max(t,e)),null!=n&&(t=Math.min(t,n)),t},getLoop:function(t,e,n){if(t===1/0)return n;if(t===-1/0)return e;for(;t>n;)t-=n-e;for(;t<e;)t+=n-e;return t}}),hr=d({},Yn,{code:"IDENTITY",project:function(t,e){return e?(e.x=t.x,e.y=t.y,e):t.copy()},unproject:function(t,e){return e?(e.x=t.x,e.y=t.y,e):t.copy()}},Xn),fr=sr,dr=Object.freeze({EPSG3857:sr,DEFAULT:fr,EPSG4326:ur,EPSG4490:cr,BAIDU:lr,IDENTITY:hr,Common:Yn}),pr=function(t){return function(t){function e(){return t.apply(this,arguments)||this}return fe(e,t),e.registerRenderer=function(t,e){var n=this.prototype,r=Object.getPrototypeOf(n);return n._rendererClasses&&n._rendererClasses!==r._rendererClasses||(n._rendererClasses=n._rendererClasses?Object.create(n._rendererClasses):{}),n._rendererClasses[t.toLowerCase()]=e,this},e.getRendererClass=function(t){var e=this.prototype;return e._rendererClasses?e._rendererClasses[t.toLowerCase()]:null},e}(t)},mr=function(t){function e(e){var n;return(n=t.call(this)||this).layer=e,n._painted=!1,n._drawTime=0,n.setToRedraw(),n}fe(e,t);var n=e.prototype;return n.render=function(t){this.prepareRender(),this.getMap()&&this.layer.isVisible()&&(this.resources||(this.resources=new gr),this.checkAndDraw(this._tryToDraw,t))},n.checkAndDraw=function(t){for(var e=this,n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];if(this.checkResources){var o=this.checkResources();o.length>0?(this._loadingResource=!0,this.loadResources(o).then((function(){e._loadingResource=!1,e.layer&&(e.layer.fire("resourceload"),e.setToRedraw())}))):t.call.apply(t,[this].concat(r))}else t.call.apply(t,[this].concat(r))},n.testIfNeedRedraw=function(){var t=this.getMap();return!(this._loadingResource||!this._toRedraw&&(t.isInteracting()&&!this.drawOnInteracting||!this.needToRedraw()))},n.needToRedraw=function(){var t=this.getMap();return!(!t.isInteracting()&&!t.getRenderer().isViewChanged()||!t.getPitch()&&t.isMoving()&&!t.isZooming()&&!t.isRotating()&&!this.layer.options.forceRenderOnMoving)},n.onSkipDrawOnInteracting=function(){},n.isLoadingResource=function(){return this._loadingResource},n.isRenderComplete=function(){return!!this._renderComplete},n.mustRenderOnInteracting=function(){return!this._painted},n.setToRedraw=function(){return this._toRedraw=!0,this},n.setCanvasUpdated=function(){return this._canvasUpdated=!0,this},n.isCanvasUpdated=function(){return!!this._canvasUpdated},n.remove=function(){this.onRemove(),delete this._loadingResource,delete this.southWest,delete this.canvas,delete this.context,delete this.canvasExtent2D,delete this._extent2D,delete this.resources,delete this.layer},n.onRemove=function(){},n.onAdd=function(){},n.getMap=function(){return this.layer?this.layer.getMap():null},n.getCanvasImage=function(){var t=this.getMap();if(this._canvasUpdated=!1,this._renderZoom!==t.getZoom()||!this.canvas||!this._extent2D)return null;if(this.isBlank())return null;if(this.layer.isEmpty&&this.layer.isEmpty())return null;var e=t._pointToContainerPoint(this.southWest)._add(0,-t.height);return{image:this.canvas,layer:this.layer,point:e}},n.clear=function(){this.clearCanvas()},n.isBlank=function(){return!this._painted},n.show=function(){this.setToRedraw()},n.hide=function(){this.clear(),this.setToRedraw()},n.setZIndex=function(){this.setToRedraw()},n.hitDetect=function(t){if(!this.context||this.layer.isEmpty&&this.layer.isEmpty()||this.isBlank()||this._errorThrown)return!1;var e=this.getMap(),n=e.getDevicePixelRatio(),r=e.getSize();if(t.x<0||t.x>r.width*n||t.y<0||t.y>r.height*n)return!1;try{if(this.context.getImageData(n*t.x,n*t.y,1,1).data[3]>0)return!0}catch(t){return this._errorThrown||(console&&console.warn("hit detect failed with tainted canvas, some geometries have external resources in another domain:\n",t),this._errorThrown=!0),!1}return!1},n.loadResources=function(t){this.resources||(this.resources=new gr);var e=this.resources,n=[];if(U(t))for(var r={},i=t.length-1;i>=0;i--){var o=t[i];o&&o.length&&!r[o.join("-")]&&(r[o.join("-")]=1,e.isResourceLoaded(o,!0)||n.push(new _n(this._promiseResource(o))))}return _n.all(n)},n.prepareRender=function(){delete this._renderComplete;var t=this.getMap();this._renderZoom=t.getZoom(),this.canvasExtent2D=this._extent2D=t._get2DExtent(),this.southWest=t._containerPointToPoint(new me(0,t.height))},n.createCanvas=function(){if(!this.canvas){var t=this.getMap(),e=t.getSize(),n=t.getDevicePixelRatio(),r=n*e.width,i=n*e.height;if(this.layer._canvas){var o=this.layer._canvas;o.width=r,o.height=i,o.style&&(o.style.width=e.width+"px",o.style.height=e.height+"px"),this.canvas=this.layer._canvas}else this.canvas=hn.createCanvas(r,i,t.CanvasClass);this.onCanvasCreate()}},n.onCanvasCreate=function(){},n.createContext=function(){if(!(this.gl&&this.gl.canvas===this.canvas||this.context)&&(this.context=this.canvas.getContext("2d"),this.context)){this.layer.options.globalCompositeOperation&&(this.context.globalCompositeOperation=this.layer.options.globalCompositeOperation);var t=this.getMap().getDevicePixelRatio();1!==t&&this.context.scale(t,t)}},n.resetCanvasTransform=function(){if(this.context){var t=this.getMap().getDevicePixelRatio();this.context.setTransform(t,0,0,t,0,0)}},n.resizeCanvas=function(t){var e=this.canvas;if(e){var n=t||this.getMap().getSize(),r=this.getMap().getDevicePixelRatio();e.width===r*n.width&&e.height===r*n.height||(e.height=r*n.height,e.width=r*n.width,1!==r&&this.context&&this.context.scale(r,r),this.layer._canvas&&e.style&&(e.style.width=n.width+"px",e.style.height=n.height+"px"))}},n.clearCanvas=function(){this.context&&hn.clearRect(this.context,0,0,this.canvas.width,this.canvas.height)},n.prepareCanvas=function(){this.canvas?(this.resetCanvasTransform(),this.clearCanvas(),this.resizeCanvas()):(this.createCanvas(),this.createContext(),this.layer.onCanvasCreate(),this.layer.fire("canvascreate",{context:this.context,gl:this.gl})),delete this._maskExtent;var t=this.layer.getMask();if(!t)return this.layer.fire("renderstart",{context:this.context,gl:this.gl}),null;var e=this._maskExtent=t._getMaskPainter().get2DExtent();return e.intersects(this._extent2D),this.layer.fire("renderstart",{context:this.context,gl:this.gl}),e},n.clipCanvas=function(t){var e=this.layer.getMask();if(!e)return!1;var n=this.southWest,r=this.getMap();this.southWest=r._containerPointToPoint(new me(0,r.height)),t.save();var i=r.getDevicePixelRatio();if(1!==i&&(t.save(),t.scale(i,i)),e.getGeometries){t.isMultiClip=!0;var o=e.getGeometries()||[];t.beginPath(),o.forEach((function(e){e._getMaskPainter().paint(null,t)})),t.stroke(),delete t.isMultiClip}else e._getMaskPainter().paint(null,t);return 1!==i&&t.restore(),t.clip(),this.southWest=n,!0},n.getViewExtent=function(){return{extent:this._extent2D,maskExtent:this._maskExtent,zoom:this._renderZoom,southWest:this.southWest}},n.completeRender=function(){this.getMap()&&(this._renderComplete=!0,this.layer.fire("renderend",{context:this.context,gl:this.gl}),this.setCanvasUpdated())},n.getEvents=function(){return{_zoomstart:this.onZoomStart,_zooming:this.onZooming,_zoomend:this.onZoomEnd,_resize:this.onResize,_movestart:this.onMoveStart,_moving:this.onMoving,_moveend:this.onMoveEnd,_dragrotatestart:this.onDragRotateStart,_dragrotating:this.onDragRotating,_dragrotateend:this.onDragRotateEnd,_spatialreferencechange:this.onSpatialReferenceChange}},n.onZoomStart=function(){},n.onZoomEnd=function(){this.setToRedraw()},n.onZooming=function(){},n.onMoveStart=function(){},n.onMoving=function(){},n.onMoveEnd=function(){this.setToRedraw()},n.onResize=function(){delete this._extent2D,this.resizeCanvas(),this.setToRedraw()},n.onDragRotateStart=function(){},n.onDragRotating=function(){},n.onDragRotateEnd=function(){this.setToRedraw()},n.onSpatialReferenceChange=function(){},n.getDrawTime=function(){return this._drawTime},n._tryToDraw=function(t){this._toRedraw=!1,!this.canvas&&this.layer.isEmpty&&this.layer.isEmpty()?this._renderComplete=!0:this._drawAndRecord(t)},n._drawAndRecord=function(t){if(this.getMap()){var e=this._painted;this._painted=!0;var n=f();this.draw(t),n=f()-n,this._drawTime=e?n:n/2,e&&this.layer&&this.layer.options.logDrawTime&&console.log(this.layer.getId(),"frameTimeStamp:",t,"drawTime:",this._drawTime)}},n._promiseResource=function(t){var e=this,n=this.resources,r=this.layer.options.crossOrigin;return function(i){if(n.isResourceLoaded(t,!0))i(t);else{var o=new Image;p(r)||(o.crossOrigin=r),C(t[0])&&!A&&(t[1]&&(t[1]*=2),t[2]&&(t[2]*=2)),o.onload=function(){e._cacheResource(t,o),i(t)},o.onabort=function(e){console&&console.warn("image loading aborted: "+t[0]),e&&console&&console.warn(e),i(t)},o.onerror=function(e){e&&"undefined"!=typeof console&&console.warn(e),n.markErrorResource(t),i(t)},P(o,t)}}},n._cacheResource=function(t,e){if(this.layer&&this.resources){var n=t[1],r=t[2];if(this.layer.options.cacheSvgOnCanvas&&1===C(t[0])&&(he.edge||he.ie)){p(n)&&(n=e.width||this.layer.options.defaultIconSize[0]),p(r)&&(r=e.height||this.layer.options.defaultIconSize[1]);var i=hn.createCanvas(n,r);hn.image(i.getContext("2d"),e,0,0,n,r),e=i}this.resources.addResource(t,e)}},e}(Mn),gr=function(){function t(){this.resources={},this._errors={}}var e=t.prototype;return e.addResource=function(t,e){this.resources[t[0]]={image:e,width:+t[1],height:+t[2]}},e.isResourceLoaded=function(t,e){if(!t)return!1;var n=this._getImgUrl(t);if(this._errors[n])return!0;var r=this.resources[n];return!(!r||e&&C(t[0])&&(+t[1]>r.width||+t[2]>r.height))},e.getImage=function(t){var e=this._getImgUrl(t);return!this.isResourceLoaded(t)||this._errors[e]?null:this.resources[e].image},e.markErrorResource=function(t){this._errors[this._getImgUrl(t)]=1},e.merge=function(t){if(!t)return this;for(var e in t.resources){var n=t.resources[e];this.addResource([e,n.width,n.height],n.image)}return this},e.forEach=function(t){if(!this.resources)return this;for(var e in this.resources)b(this.resources,e)&&t(e,this.resources[e]);return this},e._getImgUrl=function(t){return Array.isArray(t)?t[0]:t},t}();function vr(t,e,n,r){for(var i,o=[],a=0,s=0,u=t.length;s<u-1;s++)(i=yr(t[s],t[s+1],e,s,n,r))&&(o[a]=o[a]||[],o[a].push({point:i[0],index:s}),i[1]===t[s+1]&&s!==u-2||(o[a].push({point:i[1],index:s+1}),a++));return o}function yr(t,e,n,r,i,o){var a,s,u,c=r?ir:br(t,n),l=br(e,n);for(ir=l;;){if(!(c|l))return[t,e];if(c&l)return!1;if(o)return[t,e];u=br(s=xr(t,e,a=c||l,n,i),n),a===c?(t=s,c=u):(e=s,l=u)}}function _r(t,e,n){var r,i,o,a,s,u,c,l,h,f=[1,4,2,8];for(i=0,c=t.length;i<c;i++)t[i]._code=br(t[i],e);for(a=0;a<4;a++){for(l=f[a],r=[],i=0,o=(c=t.length)-1;i<c;o=i++)s=t[i],u=t[o],s._code&l?u._code&l||((h=xr(u,s,l,e,n))._code=br(h,e),r.push(h)):(u._code&l&&((h=xr(u,s,l,e,n))._code=br(h,e),r.push(h)),r.push(s));t=r}return t}function xr(t,e,n,r,i){var o,a,s=e.x-t.x,u=e.y-t.y,c=r.getMin(),l=r.getMax();8&n?(o=t.x+s*(l.y-t.y)/u,a=l.y):4&n?(o=t.x+s*(c.y-t.y)/u,a=c.y):2&n?(o=l.x,a=t.y+u*(l.x-t.x)/s):1&n&&(o=c.x,a=t.y+u*(c.x-t.x)/s);var h=new me(o,a);return i&&h._round(),h}function br(t,e){var n=0;return t.x<e.getMin().x?n|=1:t.x>e.getMax().x&&(n|=2),t.y<e.getMin().y?n|=4:t.y>e.getMax().y&&(n|=8),n}function wr(t,e,n,r){t=new me(t);var i,o,a,s=Math.abs(n.x-e.x),u=Math.abs(n.y-e.y),c=Math.sqrt(Math.abs(s*s-u*u));return s>=u?(i=new me(e.x-c,e.y),o=new me(e.x+c,e.y),a=2*s):(i=new me(e.x,e.y-c),o=new me(e.x,e.y+c),a=2*u),t.distanceTo(i)+t.distanceTo(o)<=a+2*r}var Mr=function(){function t(){}var e=t.prototype;return e.getMap=function(){return this.geometry.getMap()},e.getPainter=function(){return this.painter},e.isDynamicSize=function(){return!1},t.testColor=function(t){return!(!t||!y(t))&&l.indexOf(t)>=0},t}(),Sr=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n._prepareContext=function(t){m(this.symbol.opacity)?t.globalAlpha!==this.symbol.opacity&&(t.globalAlpha=this.symbol.opacity):1!==t.globalAlpha&&(t.globalAlpha=1)},n.prepareCanvas=function(t,e,n){hn.prepareCanvas(t,e,n,this.getPainter().isHitTesting())},n.remove=function(){},n.setZIndex=function(){},n.show=function(){},n.hide=function(){},n._defineStyle=function(t){return function(){var e=this,n=[],r={};return Mt(t,(function(){var t=e.getMap();return function(t,e,n){return t[0]=e,t[1]=n,t}(n,t.getZoom(),d({},e.geometry.getProperties(),function(t,e,n,r){return t["{bearing}"]=e,t["{pitch}"]=n,t["{zoom}"]=r,t}(r,t.getBearing(),t.getPitch(),t.getZoom())))}))}.bind(this)()},e}(Mr),Tr=new me(0,0),Er=new me(0,0),Ar=function(t){function e(e,n,r){var i;return(i=t.call(this)||this).symbol=e,i.geometry=n,i.painter=r,i}fe(e,t);var n=e.prototype;return n.get2DExtent=function(){for(var t=this.getMap(),e=t.getGLZoom(),n=new Zn,r=this._getRenderPoints()[0],i=r.length-1;i>=0;i--)r[i]&&n._combine(t._pointToPoint(r[i],e));return n},n.isDynamicSize=function(){var t=this.symbol;return xt(t.markerWidth)||xt(t.markerHeight)||xt(t.textSize)},n._rotateExtent=function(t,e){return t.convertTo((function(t){return t._rotate(e)}))},n._getRenderPoints=function(){var t=this.getPainter().isSpriting()?"center":this.getPlacement();return this.getPainter().getRenderPoints(t)},n._getRenderContainerPoints=function(t){var e=this.getPainter(),n=this._getRenderPoints()[0];if(e.isSpriting())return n;var r=this.getDxDy(),i=this.painter._pointContainerPoints(n,r.x,r.y,t,!0,this.getPlacement());if(!i||!Array.isArray(i[0]))return i;for(var o=[],a=0,s=i.length;a<s;a++)for(var u=0,c=i[a].length;u<c;u++)o.push(i[a][u]);return o},n._getRotationAt=function(t){var e=this.getRotation();e||(e=0);var n=this._getRenderPoints()[1];if(!n||!n[t])return e;var r=this.getMap(),i=n[t][0],o=n[t][1];if(r.isTransforming()){var a=r.getGLZoom();return i=r._pointToContainerPoint(n[t][0],a,0,Tr),o=r._pointToContainerPoint(n[t][1],a,0,Er),e+$(i.x,i.y,o.x,o.y)}return e+-$(i.x,i.y,o.x,o.y)},n._rotate=function(t,e,n){if(n){var r=this.getDxDy(),i=e.sub(r);return t.save(),t.translate(i.x,i.y),t.rotate(n),this.getDxDy()}return null},e}(Sr),Cr=function(t){function e(n,r,i){var o;(o=t.call(this,n,r,i)||this)._dynamic=bt(n),o.style=o._defineStyle(o.translate()),o.strokeAndFill=o._defineStyle(e.translateLineAndFill(o.style));var a=o.strokeAndFill.lineWidth;return o.padding=a%2==0?2:1.5,o}fe(e,t),e.test=function(t){return!!t&&!(!p(t.markerFile)||p(t.markerType)||"path"===t.markerType)};var n=e.prototype;return n.symbolize=function(t,e){var n=this.style;if(this.painter.isHitTesting()||0!==n.markerWidth&&0!==n.markerHeight&&(0!==n.polygonOpacity||0!==n.lineOpacity)){var r=this._getRenderContainerPoints();U(r)&&(this._prepareContext(t),this.getPainter().isSpriting()||this.geometry.getLayer().getMask()===this.geometry||this._dynamic||!1===this.geometry.getLayer().options.cacheVectorOnCanvas?this._drawMarkers(t,r,e):this._drawMarkersWithCache(t,r,e))}},n.getDxDy=function(){var t=this.style,e=t.markerDx,n=t.markerDy;return new me(e,n)},n._drawMarkers=function(t,e,n){var r=this.strokeAndFill;Rt(r.lineColor)||Rt(r.polygonFill)||this.prepareCanvas(t,r,n);for(var i=e.length-1;i>=0;i--){var o=e[i],a=this._rotate(t,o,this._getRotationAt(i));a&&(o=a),this._drawVectorMarker(t,o,n),a&&t.restore()}},n._drawMarkersWithCache=function(t,e,n){var r=this._stampSymbol(),i=n.getImage(r);i||(i=this._createMarkerImage(t,n),n.addResource([r,i.width,i.height],i));for(var o=this._getAnchor(i.width,i.height),a=e.length-1;a>=0;a--){var s=e[a],u=this._rotate(t,s,this._getRotationAt(a));u&&(s=u),hn.image(t,i,s.x+o.x,s.y+o.y),u&&t.restore()}},n._calMarkerSize=function(){if(!this._size){var t=this.strokeAndFill.lineWidth,e=2*(this.symbol.shadowBlur||0),n=Math.round(this.style.markerWidth+t+2*e+2*this.padding),r=Math.round(this.style.markerHeight+t+2*e+2*this.padding);if(xt(this.symbol.markerWidth)||xt(this.symbol.markerHeight))return[n,r];this._size=[n,r]}return this._size},n._createMarkerImage=function(t,e){var n=t.canvas.constructor,r=this._calMarkerSize(),i=hn.createCanvas(r[0],r[1],n),o=this._getCacheImageAnchor(r[0],r[1]),a=i.getContext("2d");return Rt(this.strokeAndFill.lineColor)||Rt(this.strokeAndFill.polygonFill)||this.prepareCanvas(a,this.strokeAndFill,e),this._drawVectorMarker(a,o,e),i},n._stampSymbol=function(){return this._stamp||(this._stamp=[this.style.markerType,Rt(this.style.markerFill)?kt(this.style.markerFill):this.style.markerFill,this.style.markerFillOpacity,this.style.markerFillPatternFile,Rt(this.style.markerLineColor)?kt(this.style.markerLineColor):this.style.markerLineColor,this.style.markerLineWidth,this.style.markerLineOpacity,this.style.markerLineDasharray?this.style.markerLineDasharray.join(","):"",this.style.markerLinePatternFile,this.style.markerWidth,this.style.markerHeight,this.style.markerHorizontalAlignment,this.style.markerVerticalAlignment].join("_")),this._stamp},n._getAnchor=function(t,e){var n=2*(this.symbol.shadowBlur||0)+this.padding,r=Ae(new ge(t,e),this.style.markerHorizontalAlignment,this.style.markerVerticalAlignment);return r.x!==-t/2&&(r.x-=N(r.x+t/2)*n),r.y!==-e/2&&(r.y-=N(r.y+e/2)*n),r},n._getCacheImageAnchor=function(t,e){var n=2*(this.symbol.shadowBlur||0)+this.padding,r=this.style.markerType;return"bar"===r||"pie"===r||"pin"===r?new me(t/2,e-n):"rectangle"===r?new me(n,n):new me(t/2,e/2)},n._getGraidentExtent=function(t){var e=new Zn,n=this.getDxDy(),r=this.getFixedExtent();if(Array.isArray(t))for(var i=t.length-1;i>=0;i--)e._combine(t[i]);else e._combine(t);return e.xmin+=r.xmin-n.x,e.ymin+=r.ymin-n.y,e.xmax+=r.xmax-n.x,e.ymax+=r.ymax-n.y,e},n._drawVectorMarker=function(t,n,r){var i,o=this.style,a=this.strokeAndFill,s=o.markerType.toLowerCase(),u=e._getVectorPoints(s,o.markerWidth,o.markerHeight),c=a.lineOpacity,l=a.polygonOpacity;(Rt(a.lineColor)||Rt(a.polygonFill))&&(Rt(a.lineColor)&&(i=this._getGraidentExtent(n),a.lineGradientExtent=i.expand(a.lineWidth)),Rt(a.polygonFill)&&(i||(i=this._getGraidentExtent(n)),a.polygonGradientExtent=i),this.prepareCanvas(t,a,r));var h=o.markerWidth,f=o.markerHeight,d=o.markerLineWidth/2;if("ellipse"===s)hn.ellipse(t,n,h/2,f/2,f/2,c,l);else if("cross"===s||"x"===s){for(var p=u.length-1;p>=0;p--)u[p]._add(n);hn.path(t,u.slice(0,2),c),hn.path(t,u.slice(2,4),c)}else if("diamond"===s||"bar"===s||"square"===s||"rectangle"===s||"triangle"===s){"bar"===s?n=n.add(0,-d):"rectangle"===s&&(n=n.add(d,d));for(var m=u.length-1;m>=0;m--)u[m]._add(n);hn.polygon(t,u,c,l)}else if("pin"===s){n=n.add(0,-d);for(var g=u.length-1;g>=0;g--)u[g]._add(n);var v=t.lineCap;t.lineCap="round",hn.bezierCurveAndFill(t,u,c,l),t.lineCap=v}else{if("pie"!==s)throw new Error("unsupported markerType: "+s);n=n.add(0,d);var y=180*Math.atan(h/2/f)/Math.PI,_=t.lineCap;t.lineCap="round",hn.sector(t,n,f,[90-y,90+y],c,l),t.lineCap=_}},n.getPlacement=function(){return this.symbol.markerPlacement},n.getRotation=function(){var t=this.style.markerRotation;return m(t)?-t*Math.PI/180:null},n.getFixedExtent=function(){var t=this.getDxDy(),e=2*this.padding,n=this._calMarkerSize().map((function(t){return t-e})),r=this._getAnchor(n[0],n[1]),i=new Zn(t.add(0,0),t.add(n[0],n[1]));i._add(r);var o=this.getRotation();return o&&(i=this._rotateExtent(i,o)),i},n.translate=function(){var t,e,n=this.symbol,r={markerType:z(n.markerType,"ellipse"),markerFill:z(n.markerFill,"#00f"),markerFillOpacity:z(n.markerFillOpacity,1),markerFillPatternFile:z(n.markerFillPatternFile,null),markerLineColor:z(n.markerLineColor,"#000"),markerLineWidth:z(n.markerLineWidth,1),markerLineOpacity:z(n.markerLineOpacity,1),markerLineDasharray:z(n.markerLineDasharray,[]),markerLinePatternFile:z(n.markerLinePatternFile,null),markerDx:z(n.markerDx,0),markerDy:z(n.markerDy,0),markerWidth:z(n.markerWidth,10),markerHeight:z(n.markerHeight,10),markerRotation:z(n.markerRotation,0)},i=r.markerType;return"bar"===i||"pie"===i||"pin"===i?(t="middle",e="top"):"rectangle"===i?(t="right",e="bottom"):(t="middle",e="middle"),r.markerHorizontalAlignment=z(n.markerHorizontalAlignment,t),r.markerVerticalAlignment=z(n.markerVerticalAlignment,e),m(n.markerOpacity)&&(m(n.markerFillOpacity)&&(r.markerFillOpacity*=n.markerOpacity),m(n.markerLineOpacity)&&(r.markerLineOpacity*=n.markerOpacity)),r},e.translateLineAndFill=function(t){var e={lineColor:t.markerLineColor,linePatternFile:t.markerLinePatternFile,lineWidth:t.markerLineWidth,lineOpacity:t.markerLineOpacity,lineDasharray:t.markerLineDasharray,lineCap:"butt",lineJoin:"round",polygonFill:t.markerFill,polygonPatternFile:t.markerFillPatternFile,polygonOpacity:t.markerFillOpacity};return 0===e.lineWidth&&(e.lineOpacity=0),e},e._getVectorPoints=function(t,e,n){var r,i,o,a,s=n/2,u=e/2;if("triangle"===t)return[r=new me(0,0-s),i=new me(0-u,0+s),o=new me(0+u,0+s)];if("cross"===t)return[r=new me(0-u,0),i=new me(0+u,0),o=new me(0,0-s),a=new me(0,0+s)];if("diamond"===t)return[r=new me(0-u,0),i=new me(0,0-s),o=new me(0+u,0),a=new me(0,0+s)];if("square"===t)return[r=new me(0-u,0+s),i=new me(0+u,0+s),o=new me(0+u,0-s),a=new me(0-u,0-s)];if("rectangle"===t)return i=(r=new me(0,0)).add(e,0),o=r.add(e,n),a=r.add(0,n),[r,i,o,a];if("x"===t)return[r=new me(0-u,0+s),i=new me(0+u,0-s),o=new me(0+u,0+s),a=new me(0-u,0-s)];if("bar"===t)return[r=new me(0-u,0-n),i=new me(0+u,0-n),o=new me(0+u,0),a=new me(0-u,0)];if("pin"===t){var c=n*Math.atan(u/s);return[r=new me(0,0),i=new me(0-c,0-n),o=new me(0+c,0-n),a=new me(0,0)]}return[]},e}(Ar),Pr=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.getPlacement=function(){return"point"},n.getDxDy=function(){return new me(0,0)},n.symbolize=function(t){var e=this.geometry,n=e.getLayer();if(e.options.debug||!n||n.options.debug){var r=this.getMap();if(r&&!r.isZooming()){var i=n.options.debugOutline;t.strokeStyle=i,t.fillStyle=i;var o=this.getPainter().getContainerExtent().toArray();hn.polygon(t,[o],1,0);for(var a=this._getRenderContainerPoints(),s=this.geometry.getId(),u=Cr._getVectorPoints("cross",10,10),c=0;c<a.length;c++){var l=a[c];p(s)||hn.fillText(t,s,l.add(8,-4),i);for(var h=[],f=0;f<u.length;f++)h.push(u[f].add(l));hn.path(t,h.slice(0,2),1),hn.path(t,h.slice(2,4),1)}}}},e}(Ar),Lr=function(t){function e(e,n,r){var i;return(i=t.call(this,e,n,r)||this).style=i._defineStyle(i.translate()),i}fe(e,t),e.test=function(t){return!!t&&!p(t.markerFile)};var n=e.prototype;return n.symbolize=function(t,e){var n=this.style;if(this.painter.isHitTesting()||0!==n.markerWidth&&0!==n.markerHeight&&0!==n.markerOpacity){var r=this._getRenderContainerPoints();if(U(r)){var i=this._getImage(e);if(i){this._prepareContext(t);var o,a=n.markerWidth,s=n.markerHeight;if(!m(a)||!m(s)){a=i.width,s=i.height,n.markerWidth=a,n.markerHeight=s;var u=[n.markerFile,n.markerWidth,n.markerHeight];e.isResourceLoaded(u)||e.addResource(u,i);var c=this.getPainter();c.isSpriting()||c.removeCache()}"path"!==this.symbol.markerType&&m(n.markerOpacity)&&n.markerOpacity<1&&(o=t.globalAlpha,t.globalAlpha*=n.markerOpacity);for(var l=Ae(new ge(a,s),n.markerHorizontalAlignment,n.markerVerticalAlignment),h=0,f=r.length;h<f;h++){var d=r[h],p=this._rotate(t,d,this._getRotationAt(h));p&&(d=p),hn.image(t,i,d.x+l.x,d.y+l.y,a,s),p&&t.restore()}void 0!==o&&(t.globalAlpha=o)}else"undefined"!=typeof console&&console.warn("no img found for "+(this.style.markerFile||this._url[0]))}}},n._getImage=function(t){return t?t.getImage([this.style.markerFile,this.style.markerWidth,this.style.markerHeight]):null},n.getPlacement=function(){return this.symbol.markerPlacement},n.getRotation=function(){var t=this.style.markerRotation;return m(t)?-t*Math.PI/180:null},n.getDxDy=function(){var t=this.style,e=t.markerDx,n=t.markerDy;return new me(e,n)},n.getFixedExtent=function(t){var e=this.style,n=e.markerFile,r=t?t.getImage(n):null,i=e.markerWidth||(r?r.width:0),o=e.markerHeight||(r?r.height:0),a=this.getDxDy(),s=Ae(new ge(i,o),e.markerHorizontalAlignment,e.markerVerticalAlignment),u=new Zn(a.add(0,0),a.add(i,o));u._add(s);var c=this.getRotation();return c&&(u=this._rotateExtent(u,c)),u},n.translate=function(){var t=this.symbol;return{markerFile:t.markerFile,markerOpacity:z(t.markerOpacity,1),markerWidth:z(t.markerWidth,null),markerHeight:z(t.markerHeight,null),markerRotation:z(t.markerRotation,0),markerDx:z(t.markerDx,0),markerDy:z(t.markerDy,0),markerHorizontalAlignment:z(t.markerHorizontalAlignment,"middle"),markerVerticalAlignment:z(t.markerVerticalAlignment,"top")}},e}(Ar),Or=new On(0,0),Rr=new On(0,0),kr=function(t){function e(e,n,r){var i;return(i=t.call(this)||this).symbol=e,i.geometry=n,i.painter=r,"Point"===n.type?de(i):(i.style=i._defineStyle(i.translate()),i)}fe(e,t),e.test=function(t,e){if(!t)return!1;if(e&&"Point"===e.type)return!1;for(var n in t){var r=n.slice(0,4);if("line"===r||"poly"===r)return!0}return!1};var n=e.prototype;return n.symbolize=function(t,e){var n=this.style;if(0!==n.polygonOpacity||0!==n.lineOpacity||this.painter.isHitTesting()){var r=this._getPaintParams();if(r){this._prepareContext(t);var i=Rt(n.lineColor),o="Polygon"===this.geometry.getJSONType()||"LineString"===this.geometry.type;!i||!n.lineColor.places&&o||(n.lineGradientExtent=this.getPainter().getContainerExtent()._expand(n.lineWidth)),Rt(n.polygonFill)&&(n.polygonGradientExtent=this.getPainter().getContainerExtent());var a=r[0];if("Polygon"===this.geometry.getJSONType()&&a.length>0&&Array.isArray(a[0][0])||"LineString"===this.geometry.type&&a.length>0&&Array.isArray(a[0]))for(var s=0;s<a.length;s++){this.prepareCanvas(t,n,e),i&&o&&!n.lineColor.places&&this._createGradient(t,a[s],n.lineColor);var u=[t,a[s]];r.length>1&&u.push.apply(u,r.slice(1)),u.push(n.lineOpacity,n.polygonOpacity,n.lineDasharray),this.geometry._paintOn.apply(this.geometry,u)}else{this.prepareCanvas(t,n,e),i&&o&&!n.lineColor.places&&this._createGradient(t,a,n.lineColor);var c=[t];c.push.apply(c,r),c.push(n.lineOpacity,n.polygonOpacity,n.lineDasharray),this.geometry._paintOn.apply(this.geometry,c)}t.setLineDash&&Array.isArray(n.lineDasharray)&&t.setLineDash([])}}},n.get2DExtent=function(){var t=this.getMap(),e=this.geometry._getPrjExtent();if(!e)return null;this._extMin&&this._extMax||(this._extMin=new On(0,0),this._extMax=new On(0,0)),this._extMin.x=e.xmin,this._extMin.y=e.ymin,this._extMax.x=e.xmax,this._extMax.y=e.ymax;var n=t._prjToPoint(this._extMin,void 0,Or),r=t._prjToPoint(this._extMax,void 0,Rr);return this._pxExtent?this._pxExtent.set(Math.min(n.x,r.x),Math.min(n.y,r.y),Math.max(n.x,r.x),Math.max(n.y,r.y)):this._pxExtent=new Zn(n,r),this._pxExtent},n.getFixedExtent=function(){var t=this.style.lineWidth/2;return new Zn(-t,-t,t,t)},n._getPaintParams=function(){return this.getPainter().getPaintParams(this.style.lineDx,this.style.lineDy)},n.translate=function(){var t=this.symbol,e={lineColor:z(t.lineColor,"#000"),lineWidth:z(t.lineWidth,2),lineOpacity:z(t.lineOpacity,1),lineDasharray:z(t.lineDasharray,[]),lineCap:z(t.lineCap,"butt"),lineJoin:z(t.lineJoin,"miter"),linePatternFile:z(t.linePatternFile,null),lineDx:z(t.lineDx,0),lineDy:z(t.lineDy,0),polygonFill:z(t.polygonFill,null),polygonOpacity:z(t.polygonOpacity,1),polygonPatternFile:z(t.polygonPatternFile,null),polygonPatternDx:z(t.polygonPatternDx,0),polygonPatternDy:z(t.polygonPatternDy,0),linePatternDx:z(t.linePatternDx,0),linePatternDy:z(t.linePatternDy,0)};return 0===e.lineWidth&&(e.lineOpacity=0),"LineString"!==this.geometry.type||e.polygonFill||(e.polygonFill=e.lineColor),e},n._createGradient=function(t,e,n){if(Array.isArray(e)&&e.length){var r=e.length,i=t.createLinearGradient(e[0].x,e[0].y,e[r-1].x,e[r-1].y);n.colorStops.forEach((function(t){i.addColorStop.apply(i,t)})),t.strokeStyle=i}},e}(Sr),Ir="___text_symbol_cache",Dr=function(t){function e(e,n,r){var i;if((i=t.call(this,e,n,r)||this)._dynamic=bt(e),i.style=i._defineStyle(i.translate()),0===i.style.textWrapWidth)return de(i);i.strokeAndFill=i._defineStyle(i.translateLineAndFill(i.style));var o=Ee(i.style.textName,i.geometry.getProperties());return i._dynamic||(i._cacheKey=function(t,e){var n=[t];for(var r in e)e.hasOwnProperty(r)&&r.length>4&&"text"===r.substring(0,4)&&n.push(r+"="+e[r]);return n.join("-")}(o,i.style)),i._descText(o),i}fe(e,t),e.test=function(t){return!!t&&!p(t.textName)};var n=e.prototype;return n.symbolize=function(t,e){if(this.painter.isHitTesting()||0!==this.style.textSize&&(this.style.textOpacity||this.style.textHaloRadius&&this.style.textHaloOpacity)&&0!==this.style.textWrapWidth){var n=this._getRenderContainerPoints();if(U(n)){var r=this.style,i=this.strokeAndFill,o=Ee(this.style.textName,this.geometry.getProperties());this._descText(o),this._prepareContext(t),this.prepareCanvas(t,i,e),hn.prepareCanvasFont(t,r);for(var a=0,s=n.length;a<s;a++){var u=n[a],c=this._rotate(t,u,this._getRotationAt(a));c&&(u=c),hn.text(t,o,u,r,this.textDesc),c&&t.restore()}}}},n.getPlacement=function(){return this.symbol.textPlacement},n.getRotation=function(){var t=this.style.textRotation;return m(t)?-t*Math.PI/180:null},n.getDxDy=function(){var t=this.style;return new me(t.textDx,t.textDy)},n.getFixedExtent=function(){var t=this.getDxDy(),e=this.style,n=this.textDesc.size,r=Ae(n,e.textHorizontalAlignment,e.textVerticalAlignment),i=r.x,o=r.y;if(e.textHaloRadius){var a=e.textHaloRadius;n=n.add(2*a,2*a)}var s=new Zn(t.add(i,o),t.add(i+n.width,o+n.height)),u=this.getRotation();return u&&(s=this._rotateExtent(s,u)),s},n.translate=function(){var t=this.symbol,e={textName:t.textName,textFaceName:z(t.textFaceName,"monospace"),textWeight:z(t.textWeight,"normal"),textStyle:z(t.textStyle,"normal"),textSize:z(t.textSize,h),textFont:z(t.textFont,null),textFill:z(t.textFill,"#000"),textOpacity:z(t.textOpacity,1),textHaloFill:z(t.textHaloFill,"#ffffff"),textHaloRadius:z(t.textHaloRadius,0),textHaloOpacity:z(t.textHaloOpacity,1),textWrapWidth:z(t.textWrapWidth,null),textWrapCharacter:z(t.textWrapCharacter,"\n"),textLineSpacing:z(t.textLineSpacing,0),textDx:z(t.textDx,0),textDy:z(t.textDy,0),textHorizontalAlignment:z(t.textHorizontalAlignment,"middle"),textVerticalAlignment:z(t.textVerticalAlignment,"middle"),textAlign:z(t.textAlign,"center"),textRotation:z(t.textRotation,0),textMaxWidth:z(t.textMaxWidth,0),textMaxHeight:z(t.textMaxHeight,0)};return e.textMaxWidth>0&&(!e.textWrapWidth||e.textWrapWidth>e.textMaxWidth)&&(e.textWrapWidth||(e.textMaxHeight=1),e.textWrapWidth=e.textMaxWidth),e},n.translateLineAndFill=function(t){return{lineColor:t.textHaloRadius?t.textHaloFill:t.textFill,lineWidth:t.textHaloRadius,lineOpacity:t.textOpacity,lineDasharray:null,lineCap:"butt",lineJoin:"round",polygonFill:t.textFill,polygonOpacity:t.textOpacity}},n._descText=function(t){this._dynamic?this.textDesc=this._measureText(t):(this.textDesc=this._loadFromCache(),this.textDesc||(this.textDesc=this._measureText(t),this._storeToCache(this.textDesc)))},n._measureText=function(t){var e=this.style.textMaxHeight,n=Pe(t,this.style);return e&&e<n.size.height&&(n.size.height=e),n},n._storeToCache=function(t){A||(this.geometry[Ir]||(this.geometry[Ir]={}),this.geometry[Ir][this._cacheKey]={desc:t,active:!0})},n._loadFromCache=function(){if(!this.geometry[Ir])return null;var t=this.geometry[Ir][this._cacheKey];return t?(t.active=!0,t.desc):null},e}(Ar);Dr.CACHE_KEY=Ir;var jr,zr=function(t){function e(e,n,r){var i;p(e.markerWidth)&&(e.markerWidth=80),p(e.markerHeight)&&(e.markerHeight=80),e=d(e,(i=t.call(this,e,n,r)||this).translate());var o=i.style=i._defineStyle(e);return he.gecko?i._url=[Ct(o,o.markerWidth,o.markerHeight),o.markerWidth,o.markerHeight]:i._url=[Ct(o),o.markerWidth,o.markerHeight],i}fe(e,t),e.test=function(t){return!!t&&!(!p(t.markerFile)||"path"!==t.markerType)};var n=e.prototype;return n._prepareContext=function(){},n._getImage=function(t){var e=this;if(t&&t.isResourceLoaded(this._url))return t.getImage(this._url);var n=this.painter,r=new Image;return r.onload=function(){var t=n.getLayer()&&n.getLayer().getRenderer();t&&t.setToRedraw()},r.onerror=function(n){n&&"undefined"!=typeof console&&console.warn(n),t.markErrorResource(e._url)},r.src=this._url[0],t&&t.addResource(this._url,r),r},e}(Lr),Nr={lineWidth:1,polygonFill:"#fff",polygonOpacity:.5},Fr=function(t){function e(e,n,r){var i;return(i=t.call(this,e,n,r)||this).style=n.getLayer().options.drawAltitude,i.style&&v(i.style)||(i.style={lineWidth:2}),i.style.lineWidth||(i.style.lineWidth=0),i.dxdy=i._defineStyle({dx:e.textDx||e.markerDx,dy:e.textDy||e.markerDy}),i}fe(e,t),e.test=function(t,e){if(!e.getLayer())return!1;var n=e.getJSONType();return"Marker"===n||"LineString"===n};var n=e.prototype;return n.symbolize=function(t){var e=this.geometry.getLayer();if(e.options.drawAltitude){var n=this.geometry.getProperties();if(n&&n[e.options.altitudeProperty]){var r=this._getStyle();if(this._prepareContext(t),"LineString"===this.geometry.type){var i=this._getPaintParams(r.lineDx,r.lineDy);if(!i)return;var o=this.getPainter().getPaintParams(r.lineDx,r.lineDy,!0)[0];this._drawLineAltitude(t,i[0],o)}else{var a=this._getRenderContainerPoints(),s=this._getRenderContainerPoints(!0);if(!a||0===a.length)return;this._drawMarkerAltitude(t,a[0],s[0])}}}},n.getDxDy=function(){var t=this.dxdy;return new me(t.dx||0,t.dy||0)},n.get2DExtent=function(){return"LineString"===this.geometry.type?kr.prototype.get2DExtent.apply(this):t.prototype.get2DExtent.call(this)},n.getPlacement=function(){return"point"},n._getPaintParams=function(t,e){return this.getPainter().getPaintParams(t||0,e||0)},n._drawMarkerAltitude=function(t,e,n){var r=this._getStyle();this.prepareCanvas(t,r),hn.path(t,[e,n],r.lineOpacity,null,r.lineDasharray)},n._drawLineAltitude=function(t,e,n){var r=this._getStyle();if(e.length>0&&Array.isArray(e[0]))for(var i=0;i<e.length;i++)this._drawLine(t,e[i],n[i]);else this._drawLine(t,e,n);t.setLineDash&&Array.isArray(r.lineDasharray)&&t.setLineDash([])},n._drawLine=function(t,e,n){var r=this._getStyle();this.prepareCanvas(t,r);for(var i=0,o=e.length-1;i<o;i++)hn.polygon(t,[e[i],e[i+1],n[i+1],n[i]],r.lineOpacity,r.polygonOpacity,r.lineDasharray)},n._getStyle=function(){var t=this.geometry.getLayer().options.drawAltitude;return v(t)||(t=Nr),t.lineWidth||(t.lineWidth=0,t.lineOpacity=0),t},e}(Ar),Br=Object.freeze({Symbolizer:Mr,CanvasSymbolizer:Sr,DebugSymbolizer:Pr,ImageMarkerSymbolizer:Lr,PointSymbolizer:Ar,StrokeAndFillSymbolizer:kr,TextMarkerSymbolizer:Dr,VectorMarkerSymbolizer:Cr,VectorPathMarkerSymbolizer:zr,DrawAltitudeSymbolizer:Fr}),Hr=[Fr,kr,Lr,zr,Cr,Dr],Gr=new me(0,0),Ur=new Zn,Wr=new Zn,Vr=new Zn,Zr=new Zn,qr=new Zn,Yr=function(t){function e(e){var n;return(n=t.call(this)||this).geometry=e,n.symbolizers=n._createSymbolizers(),n._altAtGLZoom=n._getGeometryAltitude(),n}fe(e,t);var n=e.prototype;return n.getMap=function(){return this.geometry.getMap()},n.getLayer=function(){return this.geometry.getLayer()},n._createSymbolizers=function(){var t=this.getSymbol(),e=[],n=Hr,r=t;Array.isArray(t)||(r=[t]);for(var i=r.length-1;i>=0;i--)for(var o=r[i],a=n.length-1;a>=0;a--)if(n[a].test(o,this.geometry)){var s=new n[a](o,this.geometry,this);e.push(s),s instanceof Ar&&(this._hasPoint=!0)}if(!e.length&&console){var u=this.geometry.getId();console.warn("invalid symbol for geometry("+(this.geometry?this.geometry.getType()+(u?":"+u:""):"")+") to draw : "+JSON.stringify(t))}return this._debugSymbolizer=new Pr(t,this.geometry,this),e},n.hasPoint=function(){return!!this._hasPoint},n.getRenderPoints=function(t){return this._renderPoints||(this._renderPoints={}),t||(t="center"),this._renderPoints[t]||(this._renderPoints[t]=this.geometry._getRenderPoints(t)),this._renderPoints[t]},n.getPaintParams=function(t,e,n){var r=this.getMap(),i=this.geometry,o=r.getResolution(),a=0!==r.getPitch(),s=0!==r.getBearing(),u=this._cachedParams,c=i._paintAsPath&&i._paintAsPath();if(c&&this._unsimpledParams&&o<=this._unsimpledParams._res)u=this._unsimpledParams;else if(!u||u._res!==r.getResolution()||this._pitched!==a&&i._redrawWhenPitch()||this._rotated!==s&&i._redrawWhenRotate()){if(!(u=i._getPaintParams()))return null;u._res=o,!i._simplified&&c&&(this._unsimpledParams||(this._unsimpledParams=u),o>this._unsimpledParams._res&&(this._unsimpledParams._res=o)),this._cachedParams=u}if(!u)return null;this._pitched=a,this._rotated=s;var l=r.getGLScale(),h=[],f=u[0],d=r.getContainerExtent(),p=this._pointContainerPoints(f,t,e,n,this._hitPoint&&!d.contains(this._hitPoint));if(!p)return null;h.push(p);for(var g=1,v=u.length;g<v;g++)m(u[g])||u[g]instanceof ge?m(u[g])?h.push(u[g]/l):h.push(u[g].multi(1/l)):h.push(u[g]);return h},n._pointContainerPoints=function(t,e,n,r,i,o){if(this._aboveCamera())return null;var a,s=this.getMap(),u=s.getGLZoom(),c=this.containerOffset;function l(t,r){var i=s._pointToContainerPoint(t,u,r)._sub(c);return(e||n)&&i._add(e||0,n||0),i}var h=this.getAltitude();if(Array.isArray(t)){var f,d=this.geometry,p=(f=!i&&d.options.enableClip?this._clip(t,h):{points:t,altitude:h}).points;h=f.altitude,r&&(h=0);var m=h;a=[];for(var g=0,v=p.length;g<v;g++){var y=p[g];if(Array.isArray(y)){for(var _=[],x=0,b=y.length;x<b;x++){var w=y[x];Array.isArray(h)&&(m=h[g]?h[g][x]:0),_.push(l(w,m))}a.push(_)}else Array.isArray(h)&&(m="vertex-last"===o?h[h.length-1-g]:"line"===o?(h[g]+h[g+1])/2:h[g]),a.push(l(y,m))}}else t instanceof me&&(r&&(h=0),a=s._pointToContainerPoint(t,u,h)._sub(c),(e||n)&&a._add(e,n));return a},n._clip=function(t,e){var n=this.getMap(),r=this.geometry,i=this.getSymbol().lineWidth;m(i)||(i=4);var o=n._get2DExtent(void 0,Zr)._expand(i);if(n.getPitch()>0&&e){var a=n.cameraLookAt,s=n.cameraPosition;Gr.set(s.x,s.y),o=o._combine(Gr._add(N(a[0]-s[0]),N(a[1]-s[1])))}var u=t;if(this.get2DExtent(null,qr).within(o))return{points:u,altitude:e};var c=n._get2DExtent(n.getGLZoom(),Zr)._expand(i*n._glScale),l=r.options.smoothness;if(r.getShell&&this.geometry.getHoles&&!l)if(Array.isArray(t[0])){u=[];for(var h=0;h<t.length;h++){var f=_r(t[h],c);f.length&&u.push(f)}}else u=_r(t,c);else if("LineString"===r.getJSONType()&&!l){if(Array.isArray(t[0])){u=[];for(var d=0;d<t.length;d++)I(u,vr(t[d],c,!1,!!l))}else u=vr(t,c,!1,!!l);return this._interpolateSegAlt(u,t,e)}return{points:u,altitude:e}},n._interpolateSegAlt=function(t,e,n){if(!Array.isArray(n)){var r=function(t){return t.point};return{points:t.map((function(t){return Array.isArray(t)?t.map(r):t.point})),altitude:n}}var i=function t(e,n,r){if(!Array.isArray(r))return e;for(var i=[],o=0,a=e.length;o<a;o++)if(Array.isArray(e[o]))i.push(t(e[o],n,r));else{var s=e[o];if(s.point.equals(n[s.index]))s.altitude=r[s.index],i.push(s);else{var u=void 0,c=void 0;0===s.index?(u=s.index,c=s.index+1):(u=s.index-1,c=s.index);var l=s.point.distanceTo(n[c]),h=l/(l+n[u].distanceTo(s.point)),f=B(r[u],r[c],1-h);s.altitude=f,i.push(s)}}return i}(t,e,n);return n=[],{points:i.map((function(t){if(Array.isArray(t)){var e=[],r=t.map((function(t){return e.push(t.altitude),t.point}));return n.push(e),r}return n.push(t.altitude),t.point})),altitude:n}},n.getSymbol=function(){return this.geometry._getInternalSymbol()},n.paint=function(t,e,n){if(this.symbolizers){var r=this.getLayer()._getRenderer();if(r&&(r.context||e)&&(!t||t.intersects(this.get2DExtent(r.resources,Ur)))){var i=this.getMap(),o=this.getMinAltitude(),a=i.getFrustumAltitude();if(!(o&&a&&a<o)){this.containerOffset=n||i._pointToContainerPoint(r.southWest)._add(0,-i.height),this._beforePaint();for(var s=e||r.context,u=[s,r.resources],c=this.symbolizers.length-1;c>=0;c--)this._prepareShadow(s,this.symbolizers[c].symbol),this.symbolizers[c].symbolize.apply(this.symbolizers[c],u);this._afterPaint(),this._painted=!0,this._debugSymbolizer.symbolize.apply(this._debugSymbolizer,u)}}}},n.getSprite=function(t,e){if("Point"!==this.geometry.type)return null;if(this._spriting=!0,!this._sprite&&this.symbolizers.length>0){var n=new Zn;this.symbolizers.forEach((function(e){var r=e.getFixedExtent(t);n._combine(r)}));var r,i=n.getMin().multi(-1),o=e||(this.getMap()?this.getMap().CanvasClass:null),a=hn.createCanvas(n.getWidth(),n.getHeight(),o);this._renderPoints&&(r=this._renderPoints);for(var s=a.getContext("2d"),u=[s,t],c=this.symbolizers.length-1;c>=0;c--){var l=this.symbolizers[c].getDxDy();this._renderPoints={center:[[i.add(l)]]},this._prepareShadow(s,this.symbolizers[c].symbol),this.symbolizers[c].symbolize.apply(this.symbolizers[c],u)}r&&(this._renderPoints=r),this._sprite={canvas:a,offset:n.getCenter()}}return this._spriting=!1,this._sprite},n.isSpriting=function(){return!!this._spriting},n.hitTest=function(t,e){(!e||e<.5)&&(e=.5),jr||(jr=hn.createCanvas(1,1)),hn.setHitTesting(!0),jr.width=jr.height=2*e;var n=jr.getContext("2d");this._hitPoint=t.sub(e,e);try{this.paint(null,n,this._hitPoint)}catch(t){throw t}finally{hn.setHitTesting(!1)}delete this._hitPoint;for(var r=n.getImageData(0,0,jr.width,jr.height).data,i=3,o=r.length;i<o;i+=4)if(r[i]>0)return!0;return!1},n.isHitTesting=function(){return!!this._hitPoint},n._prepareShadow=function(t,e){e.shadowBlur?(t.shadowBlur=this.isHitTesting()?0:e.shadowBlur,t.shadowColor=e.shadowColor||"#000",t.shadowOffsetX=e.shadowOffsetX||0,t.shadowOffsetY=e.shadowOffsetY||0):t.shadowBlur&&(t.shadowBlur=null,t.shadowColor=null,t.shadowOffsetX=null,t.shadowOffsetY=null)},n._eachSymbolizer=function(t,e){if(this.symbolizers){e||(e=this);for(var n=this.symbolizers.length-1;n>=0;n--)t.apply(e,[this.symbolizers[n]])}},n.get2DExtent=function(t,e){this._verifyProjection();var n=this.getMap();t=t||this.getLayer()._getRenderer().resources;var r=n.getZoom(),i=this._isDynamicSize();if(this._extent2D&&this._extent2D._zoom===r&&this._fixedExtent||(this._extent2D&&this._extent2D._zoom!==r&&delete this._extent2D,this.symbolizers&&(this._extent2D||(this._extent2D=this._computeExtent2D(new Zn),this._extent2D._zoom=r),this._fixedExtent||(this._fixedExtent=this._computeFixedExtent(t,new Zn)))),!this._extent2D)return i&&delete this._fixedExtent,null;var o=this._fixedExtent,a=o.xmin,s=o.ymin,u=o.xmax,c=o.ymax;return i&&delete this._fixedExtent,Vr.set(a,-c,u,-s),e?(e.set(this._extent2D.xmin,this._extent2D.ymin,this._extent2D.xmax,this._extent2D.ymax),e._add(Vr),e):this._extent2D.add(Vr)},n._computeExtent2D=function(t){for(var e=this.symbolizers.length-1;e>=0;e--){var n=this.symbolizers[e];t._combine(n.get2DExtent())}return t},n._computeFixedExtent=function(t,e){for(var n=this.symbolizers.length-1;n>=0;n--){var r=this.symbolizers[n];r.getFixedExtent&&e._combine(r.getFixedExtent(t))}return e},n._isDynamicSize=function(){for(var t=this.symbolizers.length-1;t>=0;t--)if(this.symbolizers[t].isDynamicSize())return!0;return!1},n.getContainerExtent=function(t){if(this._aboveCamera())return null;this._verifyProjection();var e=this.getMap(),n=e.getZoom(),r=e._glScale;this._extent2D&&this._extent2D._zoom===n||this.get2DExtent(null,Wr);var i=this.getMinAltitude(),o=this._extent2D.convertTo((function(t){return e._pointToContainerPoint(t,n,i/r,Gr)}),t),a=this.getMaxAltitude();if(a!==i){var s=this._extent2D.convertTo((function(t){return e._pointToContainerPoint(t,n,a/r,Gr)}),Wr);o._combine(s)}var u=this.geometry.getLayer();if("LineString"===this.geometry.type&&a&&u.options.drawAltitude){var c=this._extent2D.convertTo((function(t){return e._pointToContainerPoint(t,n,0,Gr)}),Wr);o._combine(c)}return o&&o._add(this._fixedExtent||this._computeFixedExtent(null,new Zn)),this.geometry.options.smoothness&&o._expand(.15*o.getWidth()),o},n._aboveCamera=function(){var t=this.getMinAltitude(),e=this.getMap().getFrustumAltitude();return t&&e&&e<t},n.getFixedExtent=function(){var t=this.getMap().getZoom();return this._isDynamicSize()?this._computeFixedExtent(null,new Zn):(this._extent2D&&this._extent2D._zoom===t||this.get2DExtent(null,Vr),this._fixedExtent)},n.setZIndex=function(t){this._eachSymbolizer((function(e){e.setZIndex(t)}))},n.show=function(){this._painted?(this.removeCache(),this._eachSymbolizer((function(t){t.show()}))):this.getLayer().isCanvasRender()||this.paint()},n.hide=function(){this._eachSymbolizer((function(t){t.hide()}))},n.repaint=function(){this._altAtGLZoom=this._getGeometryAltitude(),this.removeCache();var t=this.getLayer();if(t){var e=t.getRenderer();e&&e.setToRedraw()&&e.setToRedraw()}},n.refreshSymbol=function(){this.removeCache(),this._removeSymbolizers(),this.symbolizers=this._createSymbolizers()},n.remove=function(){this.removeCache(),this._removeSymbolizers()},n._removeSymbolizers=function(){this._eachSymbolizer((function(t){delete t.painter,t.remove()})),delete this.symbolizers},n.removeCache=function(){delete this._renderPoints,delete this._paintParams,delete this._sprite,delete this._extent2D,delete this._fixedExtent,delete this._cachedParams,delete this._unsimpledParams,this.geometry&&delete this.geometry[Dr.CACHE_KEY]},n.getAltitude=function(){return this.geometry.getAltitude()!==this._propAlt&&(this._altAtGLZoom=this._getGeometryAltitude()),this._altAtGLZoom?this._altAtGLZoom:0},n.getMinAltitude=function(){return this.minAltitude?this.minAltitude:0},n.getMaxAltitude=function(){return this.maxAltitude?this.maxAltitude:0},n._getGeometryAltitude=function(){var t=this;if(!this.getMap())return 0;var e=this.geometry.getAltitude();if(this._propAlt=e,!e)return this.minAltitude=this.maxAltitude=0,0;var n=this.geometry.getCenter();return n?Array.isArray(e)?(this.minAltitude=Number.MAX_VALUE,this.maxAltitude=Number.MIN_VALUE,e.map((function(e){var r=t._meterToPoint(n,e);return r<t.minAltitude&&(t.minAltitude=r),r>t.maxAltitude&&(t.maxAltitude=r),r}))):(this.minAltitude=this.maxAltitude=this._meterToPoint(n,e),this.minAltitude):0},n._meterToPoint=function(t,e){var n=this.getMap(),r=n.getGLZoom();return n.distanceToPoint(e,0,r,t).x*N(e)},n._verifyProjection=function(){var t=this.geometry._getProjection();this._projCode&&this._projCode!==t.code&&this.removeCache(),this._projCode=t.code},n._beforePaint=function(){var t=this.geometry[Dr.CACHE_KEY];if(t)for(var e in t)b(t,e)&&(t[e].active=!1)},n._afterPaint=function(){var t=this.geometry[Dr.CACHE_KEY];if(t)for(var e in t)b(t,e)&&(t[e].active||delete t[e])},e}(Mn),Jr=new Zn,Xr=function(t){function e(e,n){var r;return(r=t.call(this)||this).geometry=e,r.isMask=n,r}fe(e,t);var n=e.prototype;return n._eachPainter=function(t){for(var e,n=this.geometry.getGeometries(),r=0,i=n.length;r<i&&(!(e=this.isMask?n[r]._getMaskPainter():n[r]._getPainter())||!e||!1!==t.call(this,e));r++);},n.paint=function(t){this.geometry&&this._eachPainter((function(e){e.paint(t)}))},n.get2DExtent=function(t,e){e&&e.set(null,null,null,null);var n=e||new Zn;return this._eachPainter((function(e){n=n._combine(e.get2DExtent(t,Jr))})),n},n.getContainerExtent=function(){var t=new Zn;return this._eachPainter((function(e){t=t.combine(e.getContainerExtent())})),t},n.remove=function(){var t=arguments;this._eachPainter((function(e){e.remove.apply(e,t)}))},n.setZIndex=function(){var t=arguments;this._eachPainter((function(e){e.setZIndex.apply(e,t)}))},n.show=function(){var t=arguments;this._eachPainter((function(e){e.show.apply(e,t)}))},n.hide=function(){var t=arguments;this._eachPainter((function(e){e.hide.apply(e,t)}))},n.repaint=function(){var t=arguments;this._eachPainter((function(e){e.repaint.apply(e,t)}))},n.refreshSymbol=function(){var t=arguments;this._eachPainter((function(e){e.refreshSymbol.apply(e,t)}))},n.hasPoint=function(){var t=!1;return this._eachPainter((function(e){return!e.hasPoint()||(t=!0,!1)})),t},n.getMinAltitude=function(){var t=!0,e=0;return this._eachPainter((function(n){var r=n.getMinAltitude();(t||r<e)&&(t=!1,e=r)})),e},n.getMaxAltitude=function(){var t=0;return this._eachPainter((function(e){var n=e.getMaxAltitude();n>t&&(t=n)})),t},e}(Mn),$r={"EPSG:3857":{resolutions:function(){for(var t=[],e=12756274*Math.PI,n=0;n<21;n++)t[n]=e/(256*Math.pow(2,n));return t}(),fullExtent:{top:6378137*Math.PI,left:-6378137*Math.PI,bottom:-6378137*Math.PI,right:6378137*Math.PI}},"EPSG:4326":{fullExtent:{top:90,left:-180,bottom:-90,right:180},resolutions:function(){for(var t=[],e=0;e<20;e++)t[e]=180/(128*Math.pow(2,e));return t}()},BAIDU:{resolutions:function(){for(var t=Math.pow(2,18),e=[],n=0;n<20;n++)e[n]=t,t*=.5;return e}(),fullExtent:{top:33554432,left:-33554432,bottom:-33554432,right:33554432}},IDENTITY:{resolutions:function(){for(var t=Math.pow(2,8),e=[],n=0;n<18;n++)e[n]=t,t*=.5;return e}(),fullExtent:{top:2e5,left:-2e5,bottom:-2e5,right:2e5}}};$r["EPSG:4490"]=$r["EPSG:4326"];var Qr=function(){function t(t){void 0===t&&(t={}),this.options=t,this._initSpatialRef()}t.getProjectionInstance=function(t){if(!t)return null;if(v(t))return t;for(var e in t=(t+"").toLowerCase(),dr)if(b(dr,e)){var n=dr[e].code;if(n&&n.toLowerCase()===t)return dr[e]}return null},t.equals=function(t,e){if(!t&&!e)return!0;if(!t||!e)return!1;if(t.projection!==e.projection)return!1;var n=t.fullExtent,r=e.fullExtent;if(n&&!r||!n&&r)return!1;if(n&&r&&(n.top!==r.top||n.bottom!==r.bottom||n.left!==r.left||n.right!==r.right))return!1;var i=t.resolutions,o=e.resolutions;if(i&&o){if(i.length!==o.length)return!1;for(var a=0;a<i.length;a++)if(i[a]!==o[a])return!1}return!0};var e=t.prototype;return e._initSpatialRef=function(){var e=this.options.projection;if(!(e=e?t.getProjectionInstance(e):fr))throw new Error("must provide a valid projection in map's spatial reference.");(e=d({},Yn,e)).measureLength||d(e,or.DEFAULT),this._projection=e;var n,r=this.options.resolutions;if(!r&&(e.code&&(n=$r[e.code])&&(r=n.resolutions,this.isEPSG="IDENTITY"!==e.code),!r))throw new Error("must provide valid resolutions in map's spatial reference.");this._resolutions=r;var i=this.options.fullExtent;if(!i&&(e.code&&(n=$r[e.code])&&(i=n.fullExtent),!i))throw new Error("must provide a valid fullExtent in map's spatial reference.");if(p(i.left)?(this._fullExtent=new Vn(i),i.left=i.xmin,i.right=i.xmax,i.top=i.ymax,i.bottom=i.ymin):this._fullExtent=new Vn(new On(i.left,i.top),new On(i.right,i.bottom)),p(i.top)||p(i.bottom)||p(i.left)||p(i.right))throw new Error("must provide valid top/bottom/left/right in fullExtent.");d(this._fullExtent,i),this._projection.fullExtent=i;var o=i.right>=i.left?1:-1,a=i.top>=i.bottom?-1:1;this._transformation=new qn([o,a,0,0])},e.getResolutions=function(){return this._resolutions||[]},e.getResolution=function(t){var e=0|t;e<0?e=0:e>this._resolutions.length-1&&(e=this._resolutions.length-1);var n=this._resolutions[e];return e!==t&&t>0&&e<this._resolutions.length-1?n+(this._resolutions[e+1]-n)*(t-e):n},e.getProjection=function(){return this._projection},e.getFullExtent=function(){return this._fullExtent},e.getTransformation=function(){return this._transformation},e.getMinZoom=function(){for(var t=0;t<this._resolutions.length;t++)if(!p(this._resolutions[t]))return t;return 0},e.getMaxZoom=function(){for(var t=this._resolutions.length-1;t>=0;t--)if(!p(this._resolutions[t]))return t;return this._resolutions.length-1},e.getZoomDirection=function(){return N(this._resolutions[this.getMinZoom()]-this._resolutions[this.getMaxZoom()])},e.toJSON=function(){return this.json||(this.json={resolutions:this._resolutions,fullExtent:{top:this._fullExtent.top,left:this._fullExtent.left,bottom:this._fullExtent.bottom,right:this._fullExtent.right},projection:this._projection.code}),this.json},t}(),Kr=function(t){function e(e){var n,r=d({},e),i=r.symbol,o=r.properties,a=r.id;return delete r.symbol,delete r.id,delete r.properties,n=t.call(this,r)||this,i&&n.setSymbol(i),o&&n.setProperties(o),p(a)||n.setId(a),n}fe(e,t);var n=e.prototype;return n.getFirstCoordinate=function(){if("GeometryCollection"===this.type){var t=this.getGeometries();return t.length?t[0].getFirstCoordinate():null}var e=this.getCoordinates();if(!Array.isArray(e))return e;do{e=e[0]}while(Array.isArray(e)&&e.length>0);return e},n.getLastCoordinate=function(){if("GeometryCollection"===this.type){var t=this.getGeometries();return t.length?t[t.length-1].getLastCoordinate():null}var e=this.getCoordinates();if(!Array.isArray(e))return e;do{e=e[e.length-1]}while(Array.isArray(e)&&e.length>0);return e},n.addTo=function(t,e){return t.addGeometry(this,e),this},n.getLayer=function(){return this._layer?this._layer:null},n.getMap=function(){return this._layer?this._layer.getMap():null},n.getId=function(){return this._id},n.setId=function(t){var e=this.getId();return this._id=t,this._fireEvent("idchange",{old:e,new:t}),this},n.getProperties=function(){return this.properties?this.properties:this._getParent()?this._getParent().getProperties():null},n.setProperties=function(t){var e=this.properties;return this.properties=v(t)?d({},t):t,this._repaint(),this._fireEvent("propertieschange",{old:e,new:t}),this},n.getType=function(){return this.type},n.getSymbol=function(){var t=this._symbol;return t?Array.isArray(t)?Dt(t):d({},t):null},n.setSymbol=function(t){return this._symbol=this._prepareSymbol(t),this.onSymbolChanged(),this},n.updateSymbol=function(t){if(!t)return this;var e=this._getSymbol();return e=Dt(e||this._getInternalSymbol(),t),this._eventSymbolProperties=t,this.setSymbol(e)},n.getCenter=function(){return this._computeCenter(this._getMeasurer())},n.getExtent=function(){var t=this._getPrjExtent(),e=this._getProjection();if(t&&e){var n=e.unproject(new On(t.xmin,t.ymin)),r=e.unproject(new On(t.xmax,t.ymax));return new Vn(n,r,e)}return this._computeExtent(this._getMeasurer())},n.getContainerExtent=function(t){var e=this._getPainter();return e?e.getContainerExtent(t):null},n.getSize=function(){var t=this.getContainerExtent();return t?t.getSize():null},n.containsPoint=function(t,e){if(!this.getMap())throw new Error('The geometry is required to be added on a map to perform "containsPoint".');return t instanceof On&&(t=this.getMap().coordToContainerPoint(t)),this._containsPoint(t,e)},n._containsPoint=function(t,e){var n=this._getPainter();return!!n&&(p(e)&&this._hitTestTolerance&&(e=this._hitTestTolerance()),n.hitTest(t,e))},n.show=function(){if(this.options.visible=!0,this.getMap()){var t=this._getPainter();t&&t.show(),this._fireEvent("show")}return this},n.hide=function(){if(this.options.visible=!1,this.getMap()){this.onHide();var t=this._getPainter();t&&t.hide(),this._fireEvent("hide")}return this},n.isVisible=function(){if(!this.options.visible)return!1;var t=this._getInternalSymbol();if(!t)return!0;if(Array.isArray(t)){if(!t.length)return!0;for(var e=0,n=t.length;e<n;e++)if(p(t[e].opacity)||t[e].opacity>0)return!0;return!1}return p(t.opacity)||m(t.opacity)&&t.opacity>0},n.getZIndex=function(){return this.options.zIndex||0},n.setZIndex=function(t){var e=this.options.zIndex;return this.options.zIndex=t,this._fireEvent("zindexchange",{old:e,new:t}),this},n.setZIndexSilently=function(t){return this.options.zIndex=t,this},n.bringToFront=function(){var t=this.getLayer();if(!t||!t.getGeoMaxZIndex)return this;var e=t.getGeoMaxZIndex();return this.setZIndex(e+1),this},n.bringToBack=function(){var t=this.getLayer();if(!t||!t.getGeoMinZIndex)return this;var e=t.getGeoMinZIndex();return this.setZIndex(e-1),this},n.translate=function(t,e){if(p(t))return this;var n=new On(t,e);if(0===n.x&&0===n.y)return this;var r=this.getCoordinates();if(r)if(Array.isArray(r)){var i=j(r,(function(t){return t.add(n)}));this.setCoordinates(i)}else this.setCoordinates(r.add(n));return this},n.flash=function(t,e,n,r){return et.call(this,t,e,n,r)},n.copy=function(){var t=this.toJSON(),n=e.fromJSON(t);return n.options.visible=!0,n},n.remove=function(){return this.getLayer()?(this._fireEvent("removestart"),this._unbind(),this._fireEvent("removeend"),this._fireEvent("remove"),this):this},n.toGeoJSONGeometry=function(){return this._exportGeoJSONGeometry()},n.toGeoJSON=function(t){t||(t={});var e={type:"Feature",geometry:null};if(p(t.geometry)||t.geometry){var n=this._exportGeoJSONGeometry();e.geometry=n}var r,i=this.getId();return p(i)||(e.id=i),(p(t.properties)||t.properties)&&(r=this._exportProperties()),e.properties=r,e},n.toJSON=function(t){t||(t={});var e=this._toJSON(t);return d(e,this._exportGraphicOptions(t)),e},n.getLength=function(){return this._computeGeodesicLength(this._getMeasurer())},n.getArea=function(){return this._computeGeodesicArea(this._getMeasurer())},n.rotate=function(t,e){if("GeometryCollection"===this.type)return this.getGeometries().forEach((function(n){return n.rotate(t,e)})),this;e=e?new On(e):this.getCenter();var n=this._getMeasurer(),r=this.getCoordinates();if(!Array.isArray(r)){if(e.x!==r.x||e.y!==r.y){var i=n._rotate(r,e,t);this.setCoordinates(i)}return this}return j(r,(function(r){return n._rotate(r,e,t)})),this.setCoordinates(r),this},n._getConnectPoints=function(){return[this.getCenter()]},n._initOptions=function(t){var e=d({},t),n=e.symbol,r=e.properties,i=e.id;delete e.symbol,delete e.id,delete e.properties,this.setOptions(e),n&&this.setSymbol(n),r&&this.setProperties(r),p(i)||this.setId(i)},n._bindLayer=function(t){if(this.getLayer())throw new Error("Geometry cannot be added to two or more layers at the same time.");this._layer=t,this._clearCache()},n._prepareSymbol=function(t){if(Array.isArray(t)){for(var e=[],n=0;n<t.length;n++)e.push(Lt(this._checkAndCopySymbol(t[n])));return e}return t?Lt(t=this._checkAndCopySymbol(t)):null},n._checkAndCopySymbol=function(t){var e={};for(var n in t)c[n]&&y(t[n])?e[n]=+t[n]:e[n]=t[n];return e},n._getSymbol=function(){return this._symbol},n._setExternSymbol=function(t){return this._eventSymbolProperties=t,this._externSymbol=this._prepareSymbol(t),this.onSymbolChanged(),this},n._getInternalSymbol=function(){return this._symbol?this._symbol:this._externSymbol?this._externSymbol:this.options.symbol?this.options.symbol:null},n._getPrjExtent=function(){var t=this._getProjection();return this._verifyProjection(),!this._extent&&t&&(this._extent=this._computePrjExtent(t)),this._extent},n._unbind=function(){var t=this.getLayer();t&&(this._animPlayer&&this._animPlayer.finish(),this._clearHandlers(),this._unbindMenu(),this._unbindInfoWindow(),this.isEditing()&&this.endEdit(),this._removePainter(),this.onRemove&&this.onRemove(),t.onRemoveGeometry&&t.onRemoveGeometry(this),delete this._layer,delete this._internalId,delete this._extent)},n._getInternalId=function(){return this._internalId},n._setInternalId=function(t){this._internalId=t},n._getMeasurer=function(){return this._getProjection()?this._getProjection():Qr.getProjectionInstance(this.options.defaultProjection)},n._getProjection=function(){var t=this.getMap();return t?t.getProjection():null},n._verifyProjection=function(){var t=this._getProjection();this._projCode&&t&&this._projCode!==t.code&&this._clearProjection(),this._projCode=t?t.code:this._projCode},n._getExternalResources=function(){return Pt(this._getInternalSymbol())},n._getPainter=function(){var t=this.getLayer();if(!this._painter&&t)if(-1!==o.indexOf(this.type)){if(t.constructor.getCollectionPainterClass){var e=t.constructor.getCollectionPainterClass();this._painter=new e(this)}}else if(t.constructor.getPainterClass){var n=t.constructor.getPainterClass();this._painter=new n(this)}return this._painter},n._getMaskPainter=function(){return this._maskPainter||(this._maskPainter=this.getGeometries&&this.getGeometries()?new Xr(this,!0):new Yr(this)),this._maskPainter},n._removePainter=function(){this._painter&&this._painter.remove(),delete this._painter},n._paint=function(t){this._painter&&this._painter.paint(t)},n._clearCache=function(){delete this._extent},n._clearProjection=function(){delete this._extent},n._repaint=function(){this._painter&&this._painter.repaint()},n.onHide=function(){this.closeMenu(),this.closeInfoWindow()},n.onShapeChanged=function(){this._clearCache(),this._repaint(),this._fireEvent("shapechange")},n.onPositionChanged=function(){this._clearCache(),this._repaint(),this._fireEvent("positionchange")},n.onSymbolChanged=function(){this._painter&&this._painter.refreshSymbol();var t={};this._eventSymbolProperties&&(t.properties=d({},this._eventSymbolProperties),delete this._eventSymbolProperties),this._fireEvent("symbolchange",t)},n.onConfig=function(t){var e;t.properties&&(e=t.properties,delete t.properties);var n=!1;for(var r in t)if(t.hasOwnProperty(r)){var i=r.slice(0,5);if("arrow"===i||"smoot"===i){n=!0;break}}e?(this.setProperties(e),this._repaint()):n&&this._repaint()},n._setParent=function(t){t&&(this._parent=t)},n._getParent=function(){return this._parent},n._fireEvent=function(t,e){this.getLayer()&&this.getLayer()._onGeometryEvent&&(e||(e={}),e.type=t,e.target=this,this.getLayer()._onGeometryEvent(e)),this.fire(t,e)},n._toJSON=function(t){return{feature:this.toGeoJSON(t)}},n._exportGraphicOptions=function(t){var e={};return(p(t.options)||t.options)&&(e.options=this.config()),(p(t.symbol)||t.symbol)&&(e.symbol=this.getSymbol()),(p(t.infoWindow)||t.infoWindow)&&this._infoWinOptions&&(e.infoWindow=this._infoWinOptions),e},n._exportGeoJSONGeometry=function(){var t=this.getCoordinates(),e=On.toNumberArrays(t);return{type:this.getType(),coordinates:e}},n._exportProperties=function(){var t=null,e=this.getProperties();return p(e)||(t=v(e)?d({},e):e),t},n.getAltitude=function(){var t=this.getLayer();if(!t)return 0;var e=t.options,n=this.getProperties(),r=e.enableAltitude&&n?n[e.altitudeProperty]:0,i=t.getAltitude?t.getAltitude():0;return Array.isArray(r)?r.map((function(t){return t+i})):r+i},e}(Tn(xn(En(Mn))));Kr.mergeOptions({id:null,visible:!0,interactive:!0,editable:!0,cursor:null,defaultProjection:"EPSG:4326"});var ti={attribution:null,minZoom:null,maxZoom:null,visible:!0,opacity:1,globalCompositeOperation:null,renderer:"canvas",debugOutline:"#0f0",cssFilter:null,forceRenderOnMoving:!1,forceRenderOnZooming:!1,forceRenderOnRotating:!1,hitDetect:!he.mobile},ei=function(t){function e(e,n){var r,i;return n&&(i=n.canvas,delete n.canvas),(r=t.call(this,n)||this)._canvas=i,r.setId(e),n&&(r.setZIndex(n.zIndex),n.mask&&r.setMask(Kr.fromJSON(n.mask))),r}fe(e,t);var n=e.prototype;return n.load=function(){if(!this.getMap())return this;if(this.onLoad()){this._initRenderer();var t=this.getZIndex();p(t)||(this._renderer.setZIndex(t),this.isCanvasRender()||this._renderer.render()),this.onLoadEnd()}return this},n.getId=function(){return this._id},n.setId=function(t){var e=this._id;return p(t)||(t+=""),this._id=t,this.fire("idchange",{old:e,new:t}),this},n.addTo=function(t){return t.addLayer(this),this},n.setZIndex=function(t){return this._zIndex=t,p(t)?delete this.options.zIndex:this.options.zIndex=t,this.map&&this.map._sortLayersByZIndex(),this._renderer&&this._renderer.setZIndex(t),this},n.getZIndex=function(){return this._zIndex||0},n.getMinZoom=function(){var t=this.getMap(),e=this.options.minZoom;return t?Math.max(t.getMinZoom(),e||0):e},n.getMaxZoom=function(){var t=this.getMap(),e=this.options.maxZoom;return t?Math.min(t.getMaxZoom(),p(e)?1/0:e):e},n.getOpacity=function(){return this.options.opacity},n.setOpacity=function(t){return this.config("opacity",t),this},n.isCanvasRender=function(){var t=this._getRenderer();return t&&t instanceof mr},n.getMap=function(){return this.map?this.map:null},n.getProjection=function(){var t=this.getMap();return t?t.getProjection():null},n.bringToFront=function(){var t=this._getLayerList();if(!t.length)return this;var e=t[t.length-1];if(1===t.length||e===this)return this;var n=e.getZIndex();return this.setZIndex(n+1),this},n.bringToBack=function(){var t=this._getLayerList();if(!t.length)return this;var e=t[0];if(1===t.length||e===this)return this;var n=e.getZIndex();return this.setZIndex(n-1),this},n.show=function(){var t=this;if(!this.options.visible){this.options.visible=!0;var e=this.getRenderer();e&&e.show();var n=this.getMap();e&&n?n.once("renderend",(function(){t.fire("show")})):this.fire("show")}return this},n.hide=function(){var t=this;if(this.options.visible){this.options.visible=!1;var e=this.getRenderer();e&&e.hide();var n=this.getMap();e&&n?n.once("renderend",(function(){t.fire("hide")})):this.fire("hide")}return this},n.isVisible=function(){if(m(this.options.opacity)&&this.options.opacity<=0)return!1;var t=this.getMap();if(t){var e=t.getZoom();if(!p(this.options.maxZoom)&&this.options.maxZoom<e||!p(this.options.minZoom)&&this.options.minZoom>e)return!1}return p(this.options.visible)&&(this.options.visible=!0),this.options.visible},n.remove=function(){return this.map&&this.map.removeLayer(this),this},n.getMask=function(){return this._mask},n.setMask=function(t){if(!("Point"===t.type&&t._isVectorMarker()||"Polygon"===t.type||"MultiPolygon"===t.type))throw new Error("Mask for a layer must be a marker with vector marker symbol or a Polygon(MultiPolygon).");if(t._bindLayer(this),"Point"===t.type?t.updateSymbol({markerLineColor:"rgba(0, 0, 0, 0)",markerFillOpacity:0}):t.setSymbol({lineColor:"rgba(0, 0, 0, 0)",polygonOpacity:0}),this._mask=t,this.options.mask=t.toJSON(),!this.getMap()||this.getMap().isZooming())return this;var e=this._getRenderer();return e&&e.setToRedraw&&this._getRenderer().setToRedraw(),this},n.removeMask=function(){if(delete this._mask,delete this.options.mask,!this.getMap()||this.getMap().isZooming())return this;var t=this._getRenderer();return t&&t.setToRedraw&&this._getRenderer().setToRedraw(),this},n.onLoad=function(){return!0},n.onLoadEnd=function(){},n.isLoaded=function(){return!!this._loaded},n.getRenderer=function(){return this._getRenderer()},n.onConfig=function(t){if(m(t.opacity)||t.cssFilter){var e=this.getRenderer();e&&e.setToRedraw()}},n.onAdd=function(){},n.onRendererCreate=function(){},n.onCanvasCreate=function(){},n.onRemove=function(){},n._bindMap=function(t,e){t&&(this.map=t,p(e)||this.setZIndex(e),this._switchEvents("on",this),this.onAdd(),this.fire("add"))},n._initRenderer=function(){var t=this.options.renderer;if(this.constructor.getRendererClass){var e=this.constructor.getRendererClass(t);if(!e)throw new Error("Invalid renderer for Layer("+this.getId()+"):"+t);this._renderer=new e(this),this._renderer.layer=this,this._renderer.setZIndex(this.getZIndex()),this._switchEvents("on",this._renderer),this._renderer.onAdd&&this._renderer.onAdd(),this.onRendererCreate(),this.fire("renderercreate",{renderer:this._renderer})}},n._doRemove=function(){this._loaded=!1,this.onRemove(),this._switchEvents("off",this),this._renderer&&(this._switchEvents("off",this._renderer),this._renderer.remove(),delete this._renderer),delete this.map},n._switchEvents=function(t,e){e&&e.getEvents&&this.getMap()[t](e.getEvents(),e)},n._getRenderer=function(){return this._renderer},n._getLayerList=function(){return this.map?this.map._layers:[]},n._getMask2DExtent=function(){if(!this._mask||!this.getMap())return null;var t=this._mask._getMaskPainter();return t?t.get2DExtent():null},e}(Tn(xn(pr(Mn))));ei.mergeOptions(ti);var ni=ei.prototype.fire;ei.prototype.fire=function(t,e){return"layerload"===t&&(this._loaded=!0),this.map&&(e||(e={}),e.type=t,e.target=this,this.map._onLayerEvent(e)),ni.apply(this,arguments)};var ri={maxVisualPitch:70,maxPitch:80,centerCross:!1,zoomInCenter:!1,zoomOrigin:null,zoomAnimation:!A,zoomAnimationDuration:330,panAnimation:!A,panAnimationDuration:600,zoomable:!0,enableInfoWindow:!0,hitDetect:!he.mobile,hitDetectLimit:5,fpsOnInteracting:25,layerCanvasLimitOnInteracting:-1,maxZoom:null,minZoom:null,maxExtent:null,fixCenterOnResize:!0,checkSize:!0,checkSizeInterval:1e3,renderer:"canvas",cascadePitches:[10,60]},ii=function(t){function e(n,r){var i;if(!r)throw new Error("Invalid options when creating map.");if(!r.center)throw new Error("Invalid center when creating map.");var o=d({},r),a=o.zoom;delete o.zoom;var s=new On(o.center);delete o.center;var u=o.baseLayer;delete o.baseLayer;var c=o.layers;return delete o.layers,(i=t.call(this,o)||this).VERSION=e.VERSION,Object.defineProperty(de(de(i)),"id",{value:O(),writable:!1}),i._loaded=!1,i._initContainer(n),i._panels={},i._baseLayer=null,i._layers=[],i._zoomLevel=a,i._center=s,i.setSpatialReference(o.spatialReference||o.view),i.setMaxExtent(o.maxExtent),i._mapViewPoint=new me(0,0),i._initRenderer(),i._updateMapSize(i._getContainerDomSize()),u&&i.setBaseLayer(u),c&&i.addLayer(c),i._Load(),i}fe(e,t),e.addOnLoadHook=function(t){var e=Array.prototype.slice.call(arguments,1),n="function"==typeof t?t:function(){this[t].apply(this,e)};return this.prototype._onLoadHooks=this.prototype._onLoadHooks||[],this.prototype._onLoadHooks.push(n),this};var n=e.prototype;return n.isLoaded=function(){return!!this._loaded},n.getContainer=function(){return this._containerDOM},n.getSpatialReference=function(){return this._spatialReference},n.setSpatialReference=function(t){var e=this.options.spatialReference;return this._loaded&&Qr.equals(e,t)||this._updateSpatialReference(t,e),this},n._updateSpatialReference=function(t,e){if(t=d({},t),this._center=this.getCenter(),this.options.spatialReference=t,this._spatialReference=new Qr(t),this.options.spatialReference&&_(this.options.spatialReference.projection)){var n=this._spatialReference.getProjection();this.options.spatialReference.projection=n.code}return this._resetMapStatus(),this._fireEvent("spatialreferencechange",{old:e,new:d({},this.options.spatialReference)}),this},n.onConfig=function(t){var e=t.spatialReference||t.view;return p(e)||this._updateSpatialReference(e,null),this},n.getProjection=function(){return this._spatialReference?this._spatialReference.getProjection():null},n.getFullExtent=function(){return this._spatialReference?this._spatialReference.getFullExtent():null},n.setCursor=function(t){return delete this._cursor,this._trySetCursor(t),this._cursor=t,this},n.resetCursor=function(){return this.setCursor(null)},n.getCenter=function(){return this._loaded&&this._prjCenter?this.getProjection().unproject(this._prjCenter):this._center},n.setCenter=function(t){if(!t)return this;t=new On(t);var e=this.getProjection().project(t);return this._verifyExtent(e)?this._loaded?(this.onMoveStart(),this._setPrjCenter(e),this.onMoveEnd(this._parseEventFromCoord(this.getCenter())),this):(this._center=t,this):this},n.getSize=function(){return p(this.width)||p(this.height)?this._getContainerDomSize():new ge(this.width,this.height)},n.getContainerExtent=function(){var t=this.height,e=this.getPitch(),n=this.options.maxVisualPitch;return n&&e>n&&(t=this._getVisualHeight(n)),new Zn(0,this.height-t,this.width,this.height)},n._getVisualHeight=function(t){t=t||.01;var e=(90-this.getPitch())*Math.PI/180,n=this.getFov()*Math.PI/180;t*=Math.PI/180;var r=this.cameraCenterDistance/this.getGLScale(),i=Math.tan(n/2),o=r*i/(1/Math.tan(t)-i)/Math.sin(t),a=r*(Math.sin(e)*o/(r+Math.cos(e)*o));return this.height/2+a},n.getExtent=function(){return this._pointToExtent(this._get2DExtent())},n.getProjExtent=function(){var t=this._get2DExtent();return new Vn(this._pointToPrj(t.getMin()),this._pointToPrj(t.getMax()))},n.getPrjExtent=function(){return this.getProjExtent()},n.getMaxExtent=function(){return this.options.maxExtent?new Vn(this.options.maxExtent,this.getProjection()):null},n.setMaxExtent=function(t){if(t){var e=new Vn(t,this.getProjection());this.options.maxExtent=e,this._verifyExtent(this._getPrjCenter())||this._panTo(this._prjMaxExtent().getCenter());var n=this.getProjection();this._prjMaxExtent=e.convertTo((function(t){return n.project(t)}))}else delete this.options.maxExtent,delete this._prjMaxExtent;return this},n.getZoom=function(){return this._zoomLevel},n.getZoomForScale=function(t,e,n){var r=this.getZoom();if(p(e)&&(e=r),1===t&&e===r)return r;var i=this._getResolution(e)/t,o=this.getZoomFromRes(i);if(n)return o;var a=1e-6;return this.getSpatialReference().getZoomDirection()<0?Math.ceil(o-a):Math.floor(o+a)},n.getZoomFromRes=function(t){var e=this._getResolutions(),n=this._getResolution(this.getMinZoom()),r=this._getResolution(this.getMaxZoom());if(n<=r){if(t<=n)return this.getMinZoom();if(t>=r)return this.getMaxZoom()}else{if(t>=n)return this.getMinZoom();if(t<=r)return this.getMaxZoom()}for(var i=e.length,o=0;o<i-1;o++)if(e[o]){var a=e[o+1]-e[o],s=t-e[o];if(N(a)===N(s)&&Math.abs(a)>=Math.abs(s))return o+s/a}return i-1},n.setZoom=function(t,e){return void 0===e&&(e={animation:!0}),isNaN(t)||p(t)||(t=+t,this._loaded&&this.options.zoomAnimation&&e.animation?this._zoomAnimation(t):this._zoom(t)),this},n.getMaxZoom=function(){return p(this.options.maxZoom)?this.getMaxNativeZoom():this.options.maxZoom},n.setMaxZoom=function(t){var e=this.getMaxNativeZoom();return t>e&&(t=e),null!==t&&t<this._zoomLevel&&(this.setZoom(t),t=+t),this.options.maxZoom=t,this},n.getMinZoom=function(){return p(this.options.minZoom)?this._spatialReference.getMinZoom():this.options.minZoom},n.setMinZoom=function(t){if(null!==t){t=+t;var e=this._spatialReference.getMinZoom();t<e&&(t=e),t>this._zoomLevel&&this.setZoom(t)}return this.options.minZoom=t,this},n.getMaxNativeZoom=function(){var t=this.getSpatialReference();return t?t.getMaxZoom():null},n.getGLZoom=function(){return this.getMaxNativeZoom()/2},n.getGLScale=function(t){return p(t)&&(t=this.getZoom()),this._getResolution(t)/this._getResolution(this.getGLZoom())},n.zoomIn=function(){return this.setZoom(this.getZoom()+1)},n.zoomOut=function(){return this.setZoom(this.getZoom()-1)},n.isZooming=function(){return!!this._zooming},n.isInteracting=function(){return this.isZooming()||this.isMoving()||this.isRotating()},n.setCenterAndZoom=function(t,e){return p(e)||this._zoomLevel===e?this.setCenter(t):(this.setCenter(t),this.setZoom(e,{animation:!1})),this},n.getFitZoom=function(t,e){var n=this;if(!(t&&t instanceof Vn))return this._zoomLevel;if(t.xmin===t.xmax&&t.ymin===t.ymax)return this.getMaxZoom();var r=this.getSize(),i=t.convertTo((function(t){return n.coordToContainerPoint(t)})),o=i.getWidth(),a=i.getHeight(),s=r.width/o,u=r.height/a,c=this.getSpatialReference().getZoomDirection()<0?Math.max(s,u):Math.min(s,u);return this.getZoomForScale(c,null,e)},n.getView=function(){return{center:this.getCenter().toArray(),zoom:this.getZoom(),pitch:this.getPitch(),bearing:this.getBearing()}},n.setView=function(t){return t?(t.center&&this.setCenter(t.center),null===t.zoom||isNaN(+t.zoom)||this.setZoom(+t.zoom,{animation:!1}),null===t.pitch||isNaN(+t.pitch)||this.setPitch(+t.pitch),null===t.pitch||isNaN(+t.bearing)||this.setBearing(+t.bearing),this):this},n.getResolution=function(t){return this._getResolution(t)},n.getScale=function(t){var e=p(t)?this.getZoom():t,n=this._getResolution(this.getMaxNativeZoom());return this._getResolution(e)/n},n.fitExtent=function(t,e,n,r){if(void 0===n&&(n={}),!t)return this;t=new Vn(t,this.getProjection());var i=this.getFitZoom(t)+(e||0),o=t.getCenter();return void 0===n.animation||n.animation?this._animateTo({center:o,zoom:i},{duration:n.duration||this.options.zoomAnimationDuration,easing:n.easing||"out"},r):this.setCenterAndZoom(o,i)},n.getBaseLayer=function(){return this._baseLayer},n.setBaseLayer=function(t){var e=!1;return this._baseLayer&&(e=!0,this._fireEvent("baselayerchangestart"),this._baseLayer.remove()),t?(this._baseLayer=t,t._bindMap(this,-1),this._baseLayer.on("layerload",(function(){this._fireEvent("baselayerload"),e&&(e=!1,this._fireEvent("baselayerchangeend"))}),this),this._loaded&&this._baseLayer.load(),this._fireEvent("setbaselayer"),this):(delete this._baseLayer,this._fireEvent("baselayerchangeend"),this._fireEvent("setbaselayer"),this)},n.removeBaseLayer=function(){return this._baseLayer&&(this._baseLayer.remove(),delete this._baseLayer,this._fireEvent("baselayerremove")),this},n.getLayers=function(t){return this._getLayers((function(e){return!(e===this._baseLayer||e.getId().indexOf(i)>=0)&&(!t||t(e))}))},n.getLayer=function(t){if(!t)return null;var e=this._layerCache?this._layerCache[t]:null;if(e)return e;var n=this.getBaseLayer();return n&&n.getId()===t?n:null},n.addLayer=function(t){if(!t)return this;if(!Array.isArray(t))return t=Array.prototype.slice.call(arguments,0),this.addLayer(t);this._layerCache||(this._layerCache={});for(var e=this._layers,n=0,r=t.length;n<r;n++){var i=t[n],o=i.getId();if(p(o))throw new Error("Invalid id for the layer: "+o);if(i.getMap()!==this){if(this._layerCache[o])throw new Error("Duplicate layer id in the map: "+o);this._layerCache[o]=i,i._bindMap(this),e.push(i),this._loaded&&i.load()}}return this._sortLayersByZIndex(),this._fireEvent("addlayer",{layers:t}),this},n.removeLayer=function(t){if(!t)return this;if(!Array.isArray(t))return this.removeLayer([t]);for(var e=[],n=0,r=t.length;n<r;n++){var i=t[n];if(i instanceof ei||(i=this.getLayer(i)),i){var o=i.getMap();if(o&&o===this){e.push(i),this._removeLayer(i,this._layers),this._loaded&&i._doRemove();var a=i.getId();this._layerCache&&delete this._layerCache[a]}}}if(e.length>0){var s=this.getRenderer();s&&s.setLayerCanvasUpdated(),this.once("frameend",(function(){e.forEach((function(t){t.fire("remove")}))}))}return this._fireEvent("removelayer",{layers:t}),this},n.sortLayers=function(t){if(!t||!Array.isArray(t))return this;for(var e=[],n=Number.MAX_VALUE,r=0,i=t.length;r<i;r++){var o=t[r];if(y(t[r])&&(o=this.getLayer(o)),!(o instanceof ei&&o.getMap()&&o.getMap()===this))throw new Error("It must be a layer added to this map to order.");o.getZIndex()<n&&(n=o.getZIndex()),e.push(o)}for(var a=0,s=e.length;a<s;a++)e[a].setZIndex(n+a);return this},n.toDataURL=function(t){t||(t={});var e=t.mimeType;e||(e="image/png");var n=t.save,r=this._getRenderer();if(r&&r.toDataURL){var i=t.fileName;i||(i="export");var o=r.toDataURL(e);if(n&&o){var a;if("undefined"!=typeof Blob&&"undefined"!=typeof atob){var s=X(o.replace(/^data:image\/(png|jpeg|jpg);base64,/,""),e);a=URL.createObjectURL(s)}else a=o;var u=document.createElement("a");u.download=i,u.href=a,document.body.appendChild(u),u.click(),document.body.removeChild(u)}return o}return null},n.coordToPoint=function(t,e,n){return this.coordinateToPoint(t,e,n)},n.pointToCoord=function(t,e,n){return this.pointToCoordinate(t,e,n)},n.coordToViewPoint=function(t,e,n){return this.coordinateToViewPoint(t,e,n)},n.viewPointToCoord=function(t,e){return this.viewPointToCoordinate(t,e)},n.coordToContainerPoint=function(t,e,n){return this.coordinateToContainerPoint(t,e,n)},n.containerPointToCoord=function(t,e){return this.containerPointToCoordinate(t,e)},n.containerPointToViewPoint=function(t,e){return e?e.set(t.x,t.y):e=t.copy(),e._sub(this.getViewPoint())},n.viewPointToContainerPoint=function(t,e){return e?e.set(t.x,t.y):e=t.copy(),e._add(this.getViewPoint())},n.checkSize=function(){var t=f()-this._initTime<1500&&0===this.width||0===this.height,e=this._getContainerDomSize(),n=this.height,r=this.width;if(e.width===r&&e.height===n)return this;var i=this.getCenter();if(this.options.fixCenterOnResize)this._updateMapSize(e);else{var o=this._getVisualHeight(this.getPitch()),a=new me(0,this.height-o),s=this._containerPointToPrj(a);this._updateMapSize(e);var u=this._getVisualHeight(this.getPitch()),c=new me(0,this.height-u);this._setPrjCoordAtContainerPoint(s,c),this._mapViewCoord=this._getPrjCenter()}var l=0===e.width||0===e.height||0===r||0===n;return(t||l)&&(this._eventSilence=!0,this.setCenter(i),delete this._eventSilence),this._fireEvent("resize"),this},n.locate=function(t,e,n){return this.getProjection()._locate(new On(t),e,n)},n.getMainPanel=function(){return this._getRenderer().getMainPanel()},n.getPanels=function(){return this._panels},n.remove=function(){var t=this;if(this.isRemoved())return this;this._fireEvent("removestart"),this._removeDomEvents(),this._clearHandlers(),this.removeBaseLayer();for(var e=this.getLayers(),n=0;n<e.length;n++)e[n].remove();return this._getRenderer()&&this._getRenderer().remove(),this._containerDOM.childNodes&&this._containerDOM.childNodes.length>0&&Array.prototype.slice.call(this._containerDOM.childNodes,0).filter((function(t){return"maptalks-wrapper"===t.className})).forEach((function(e){return t._containerDOM.removeChild(e)})),delete this._panels,delete this._containerDOM,delete this.renderer,this._fireEvent("removeend"),this._clearAllListeners(),this},n.isRemoved=function(){return!this._containerDOM},n.isMoving=function(){return!!this._moving},n.onMoveStart=function(t){var e=this._getPrjCenter();this._originCenter&&!this._verifyExtent(e)||(this._originCenter=e),this._moving=!0,this._trySetCursor("move"),this._fireEvent("movestart",this._parseEvent(t?t.domEvent:null,"movestart"))},n.onMoving=function(t){this._fireEvent("moving",this._parseEvent(t?t.domEvent:null,"moving"))},n.onMoveEnd=function(t){if(this._moving=!1,this._trySetCursor("default"),this._fireEvent("moveend",t&&t.domEvent?this._parseEvent(t.domEvent,"moveend"):t),!this._verifyExtent(this._getPrjCenter())&&this._originCenter){var e=this._originCenter;this._panTo(e)}},n.onDragRotateStart=function(t){this._dragRotating=!0,this._fireEvent("dragrotatestart",this._parseEvent(t?t.domEvent:null,"dragrotatestart"))},n.onDragRotating=function(t){this._fireEvent("dragrotating",this._parseEvent(t?t.domEvent:null,"dragrotating"))},n.onDragRotateEnd=function(t){this._dragRotating=!1,this._fireEvent("dragrotateend",this._parseEvent(t?t.domEvent:null,"dragrotateend"))},n.isDragRotating=function(){return!!this._dragRotating},n.getRenderer=function(){return this._getRenderer()},n.getDevicePixelRatio=function(){return this.options.devicePixelRatio||he.devicePixelRatio||1},n._initContainer=function(t){if(y(t)){if(this._containerDOM=document.getElementById(t),!this._containerDOM)throw new Error("Invalid container when creating map: '"+t+"'")}else this._containerDOM=t,A&&(this.CanvasClass=this._containerDOM.constructor);if(this._containerDOM.childNodes&&this._containerDOM.childNodes.length>0&&"maptalks-wrapper"===this._containerDOM.childNodes[0].className)throw new Error("Container is already loaded with another map instance, use map.remove() to clear it.")},n._trySetCursor=function(t){return this._cursor||this._priorityCursor||(t||(t="default"),this._setCursorToPanel(t)),this},n._setPriorityCursor=function(t){if(t)this._priorityCursor=t,this._setCursorToPanel(t);else{var e=!1;this._priorityCursor&&(e=!0),delete this._priorityCursor,e&&this.setCursor(this._cursor)}return this},n._setCursorToPanel=function(t){var e=this.getMainPanel();e&&e.style&&e.style.cursor!==t&&(e.style.cursor=t)},n._removeLayer=function(t,e){if(t&&e){var n=e.indexOf(t);n>-1&&e.splice(n,1)}},n._sortLayersByZIndex=function(){if(this._layers){for(var t=0,e=this._layers.length;t<e;t++)this._layers[t]._order=t;this._layers.sort((function(t,e){var n=t.getZIndex()-e.getZIndex();return 0===n?t._order-e._order:n}))}},n._fireEvent=function(t,e){this._eventSilence||(this.fire("_"+t,e),this.fire(t,e))},n._Load=function(){this._resetMapStatus(),this.options.pitch&&(this.setPitch(this.options.pitch),delete this.options.pitch),this.options.bearing&&(this.setBearing(this.options.bearing),delete this.options.bearing),this._loadAllLayers(),this._getRenderer().onLoad(),this._loaded=!0,this._callOnLoadHooks(),this._initTime=f()},n._initRenderer=function(){var t=this.options.renderer,n=e.getRendererClass(t);this._renderer=new n(this),this._renderer.load()},n._getRenderer=function(){return this._renderer},n._loadAllLayers=function(){this._baseLayer&&this._baseLayer.load(),this._eachLayer((function(t){t&&t.load()}),this.getLayers())},n._getLayers=function(t){for(var e=this._baseLayer?[this._baseLayer].concat(this._layers):this._layers,n=[],r=0;r<e.length;r++)t&&!t.call(this,e[r])||n.push(e[r]);return n},n._eachLayer=function(t){if(!(arguments.length<2)){var e=Array.prototype.slice.call(arguments,1);e&&!Array.isArray(e)&&(e=[e]);for(var n=[],r=0,i=e.length;r<i;r++)n=n.concat(e[r]);for(var o=0,a=n.length;o<a;o++)t.call(t,n[o])}},n._onLayerEvent=function(t){t&&"idchange"===t.type&&(delete this._layerCache[t.old],this._layerCache[t.new]=t.target)},n._resetMapStatus=function(){var t=this.getMaxZoom(),e=this.getMinZoom(),n=this._spatialReference.getMaxZoom(),r=this._spatialReference.getMinZoom();(p(t)||-1===t||t>n)&&this.setMaxZoom(n),(p(e)||-1===e||e<r)&&this.setMinZoom(r),(t=this.getMaxZoom())<(e=this.getMinZoom())&&this.setMaxZoom(e),(p(this._zoomLevel)||this._zoomLevel>t)&&(this._zoomLevel=t),this._zoomLevel<e&&(this._zoomLevel=e),delete this._prjCenter;var i=this.getProjection();this._prjCenter=i.project(this._center),this._calcMatrices();var o=this._getRenderer();o&&o.resetContainer()},n._getContainerDomSize=function(){if(!this._containerDOM)return null;var t,e,n=this._containerDOM;if(p(n.width)||p(n.height)){if(p(n.clientWidth)||p(n.clientHeight))throw new Error("can not get size of container");t=parseInt(n.clientWidth,0),e=parseInt(n.clientHeight,0)}else{t=n.width,e=n.height;var r=this.getDevicePixelRatio();1!==r&&n.layer&&(t/=r,e/=r)}return new ge(t,e)},n._updateMapSize=function(t){return this.width=t.width,this.height=t.height,this._getRenderer().updateMapSize(t),this._calcMatrices(),this},n._getPrjCenter=function(){return this._prjCenter},n._setPrjCenter=function(t){this._prjCenter=t,this.isInteracting()&&!this.isMoving()&&(this._mapViewCoord=t),this._calcMatrices()},n._setPrjCoordAtContainerPoint=function(t,e){if(e.x===this.width/2&&e.y===this.height/2)return this;var n=this._containerPointToPoint(e)._sub(this._prjToPoint(this._getPrjCenter())),r=this._pointToPrj(this._prjToPoint(t).sub(n));return this._setPrjCenter(r),this},n._verifyExtent=function(t){if(!t)return!1;var e=this._prjMaxExtent;return!e||e.contains(t)},n._offsetCenterByPixel=function(t){var e=new me(this.width/2-t.x,this.height/2-t.y),n=this._containerPointToPrj(e);return this._setPrjCenter(n),n},n.offsetPlatform=function(t){return t?(this._getRenderer().offsetPlatform(t),this._mapViewCoord=this._getPrjCenter(),this._mapViewPoint=this._mapViewPoint.add(t),this):this._mapViewPoint},n.getViewPoint=function(){var t=this._getViewPointFrameOffset(),e=this.offsetPlatform();return t&&(e=e.add(t)),e},n._resetMapViewPoint=function(){this._mapViewPoint=new me(0,0),this._mapViewCoord=this._getPrjCenter()},n._getResolution=function(t){return void 0!==t&&t!==this._zoomLevel||void 0===this._mapRes?t===this.getGLZoom()&&void 0!==this._mapGlRes?this._mapGlRes:(p(t)&&(t=this._zoomLevel),this._spatialReference.getResolution(t)):this._mapRes},n._getResolutions=function(){return this._spatialReference.getResolutions()},n._prjToPoint=function(t,e,n){return e=p(e)?this.getZoom():e,this._spatialReference.getTransformation().transform(t,this._getResolution(e),n)},n._pointToPrj=function(t,e,n){return e=p(e)?this.getZoom():e,this._spatialReference.getTransformation().untransform(t,this._getResolution(e),n)},n._pointToPoint=function(t,e,n){return n?(n.x=t.x,n.y=t.y):n=t.copy(),p(e)?n:n._multi(this._getResolution(e)/this._getResolution())},n._pointToPointAtZoom=function(t,e,n){return n?(n.x=t.x,n.y=t.y):n=t.copy(),p(e)?n:n._multi(this._getResolution()/this._getResolution(e))},n._containerPointToPrj=function(t,e){return this._pointToPrj(this._containerPointToPoint(t,void 0,e),void 0,e)},n._callOnLoadHooks=function(){var t=e.prototype;if(t._onLoadHooks)for(var n=0,r=t._onLoadHooks.length;n<r;n++)t._onLoadHooks[n].call(this)},e}(En(xn(pr(Mn))));ii.include({coordinateToPoint:function(){var t=new On(0,0);return function(e,n,r){var i=this.getProjection().project(e,t);return this._prjToPoint(i,n,r)}}(),pointToCoordinate:function(){var t=new On(0,0);return function(e,n,r){var i=this._pointToPrj(e,n,t);return this.getProjection().unproject(i,r)}}(),coordinateToViewPoint:function(){var t=new On(0,0);return function(e,n,r){return this._prjToViewPoint(this.getProjection().project(e,t),n,r)}}(),viewPointToCoordinate:function(){var t=new On(0,0);return function(e,n){return this.getProjection().unproject(this._viewPointToPrj(e,t),n)}}(),coordinateToContainerPoint:function(){var t=new On(0,0);return function(e,n,r){var i=this.getProjection().project(e,t);return this._prjToContainerPoint(i,n,r)}}(),containerPointToCoordinate:function(){var t=new On(0,0);return function(e,n){var r=this._containerPointToPrj(e,t);return this.getProjection().unproject(r,n)}}(),containerToExtent:function(){var t=new me(0,0),e=new me(0,0);return function(n){var r=new Zn(this._containerPointToPoint(n.getMin(t),void 0,t),this._containerPointToPoint(n.getMax(e),void 0,e));return this._pointToExtent(r)}}(),distanceToPixel:function(){var t=new me(0,0),e=new me(0,0);return function(n,r,i){var o=this.getProjection();if(!o)return null;var a=this.getScale()/this.getScale(i),s=this.getCenter(),u=o.locate(s,n,r),c=this.coordToContainerPoint(s,void 0,t),l=this.coordToContainerPoint(u,void 0,e);return l._sub(c)._multi(a)._abs(),new ge(l.x,l.y)}}(),distanceToPoint:function(){var t=new me(0,0);return function(e,n,r,i){var o=this.getProjection();if(!o)return null;var a=i||this.getCenter(),s=o.locate(a,e,n),u=this.coordToPoint(a,r,t),c=this.coordToPoint(s,r);return c._sub(u)._abs(),c}}(),pixelToDistance:function(){var t=new On(0,0),e=new On(0,0);return function(n,r){var i=this.getProjection();if(!i)return null;var o=this.getFullExtent(),a=o.top>o.bottom?-1:1,s=t.set(this.width/2+n,this.height/2+a*r),u=this.containerPointToCoord(s,e);return i.measureLength(this.getCenter(),u)}}(),pointToDistance:function(){var t=new me(0,0),e=new On(0,0);return function(n,r,i){var o=this.getProjection();if(!o)return null;var a=this._prjToPoint(this._getPrjCenter(),i,t);a._add(n,r);var s=this.pointToCoord(a,i,e);return o.measureLength(this.getCenter(),s)}}(),locateByPoint:function(){var t=new me(0,0);return function(e,n,r){var i=this.coordToContainerPoint(e,void 0,t);return this.containerPointToCoord(i._add(n,r))}}(),_get2DExtent:function(){var t=new me(0,0);return function(e,n){var r,i=this;return void 0!==e&&e!==this._zoomLevel||!this._mapExtent2D?e===this.getGLZoom()&&this._mapGlExtent2D&&(r=this._mapGlExtent2D):r=this._mapExtent2D,r?n?(n.set(r.xmin,r.ymin,r.xmax,r.ymax),n):r.copy():this.getContainerExtent().convertTo((function(n){return i._containerPointToPoint(n,e,t)}),n)}}(),_pointToExtent:function(){var t=new On(0,0),e=new On(0,0);return function(n){var r=n.getMin(),i=n.getMax(),o=this.getFullExtent(),a=!o||o.left<=o.right?[r.x,i.x]:[i.x,r.x],s=a[0],u=a[1],c=!o||o.top>o.bottom?[i.y,r.y]:[r.y,i.y],l=c[0],h=c[1],f=r.set(s,h),d=i.set(u,l);return new Vn(this.pointToCoord(f,void 0,t),this.pointToCoord(d,void 0,e),this.getProjection())}}(),_getViewPointFrameOffset:function(){var t=new me(0,0);return function(){if(this.isZooming())return null;var e=this._getPrjCenter();return this._mapViewCoord&&!this._mapViewCoord.equals(e)?this._prjToContainerPoint(this._mapViewCoord)._sub(this._prjToContainerPoint(e,void 0,t)):null}}(),_viewPointToPrj:function(){var t=new me(0,0);return function(e,n){return this._containerPointToPrj(this.viewPointToContainerPoint(e,t),n)}}(),_prjToContainerPoint:function(){var t=new me(0,0);return function(e,n,r,i){return this._pointToContainerPoint(this._prjToPoint(e,n,t),n,i||0,r)}}(),_prjToViewPoint:function(){var t=new me(0,0);return function(e,n,r){var i=this._prjToContainerPoint(e,void 0,t,r);return this.containerPointToViewPoint(i,n)}}(),_viewPointToPoint:function(){var t=new me(0,0);return function(e,n,r){return this._containerPointToPoint(this.viewPointToContainerPoint(e,t),n,r)}}(),_pointToViewPoint:function(){var t=new On(0,0);return function(e,n,r){return this._prjToViewPoint(this._pointToPrj(e,n,t),r)}}()}),ii.mergeOptions(ri);var oi=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.addHooks=function(){this.target&&this.target.on("_dblclick",this._onDoubleClick,this)},n.removeHooks=function(){this.target&&this.target.off("_dblclick",this._onDoubleClick,this)},n._onDoubleClick=function(t){var e=this.target;if(e.options.doubleClickZoom){var n=e.getZoom(),r=t.domEvent.shiftKey?Math.ceil(n)-1:Math.floor(n)+1;e._zoomAnimation(r,t.containerPoint)}},e}(wn);ii.mergeOptions({doubleClickZoom:!0}),ii.addOnLoadHook("addHandler","doubleClickZoom",oi);var ai=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.addHooks=function(){var t=this.target;if(t){var e=t._panels.mapWrapper||t._containerDOM;this._dragHandler=new Ln(e,{cancelOn:this._cancelOn.bind(this),rightclick:!0}),this._dragHandler.on("mousedown",this._onMouseDown,this).on("dragstart",this._onDragStart,this).on("dragging",this._onDragging,this).on("dragend",this._onDragEnd,this).enable()}},n.removeHooks=function(){this._dragHandler.off("mousedown",this._onMouseDown,this).off("dragstart",this._onDragStart,this).off("dragging",this._onDragging,this).off("dragend",this._onDragEnd,this),this._dragHandler.remove(),delete this._dragHandler},n._cancelOn=function(t){return!(!this.target.isZooming()&&!this._ignore(t))},n._ignore=function(t){return!!t&&(t.domEvent&&(t=t.domEvent),this.target._ignoreEvent(t))},n._onMouseDown=function(t){delete this.startDragTime,delete this._mode,2===t.domEvent.button||t.domEvent.ctrlKey?(this.target.options.dragRotate||this.target.options.dragPitch)&&(this._mode="rotatePitch"):this.target.options.dragPan&&(this._mode="move"),this.target._stopAnim(this.target._mapAnimPlayer),Ge(t.domEvent)},n._onDragStart=function(t){this.startDragTime=f(),"move"===this._mode?this._moveStart(t):"rotatePitch"===this._mode&&this._rotateStart(t)},n._onDragging=function(t){this.target._isEventOutMap(t.domEvent)||("move"===this._mode?this._moving(t):"rotatePitch"===this._mode&&this._rotating(t))},n._onDragEnd=function(t){"move"===this._mode?this._moveEnd(t):"rotatePitch"===this._mode&&this._rotateEnd(t),delete this.startDragTime,delete this.startBearing},n._start=function(t){this.preX=t.mousePos.x,this.preY=t.mousePos.y,this.startX=this.preX,this.startY=this.preY},n._moveStart=function(t){this._start(t);var e=this.target;e.onMoveStart(t);var n=qe(e._getActualEvent(t.domEvent),e.getContainer());this.startPrjCoord=e._containerPointToPrj(n)},n._moving=function(t){if(this.startDragTime){var e=this.target,n=qe(e._getActualEvent(t.domEvent),e.getContainer());e._setPrjCoordAtContainerPoint(this.startPrjCoord,n),e.onMoving(t)}},n._moveEnd=function(t){if(this.startDragTime){var e=this.target,n=f()-this.startDragTime,r=t.mousePos.x,i=t.mousePos.y,o=r-this.startX,a=i-this.startY;this._clear(),e.options.panAnimation&&!t.interupted&&e._verifyExtent(e._getPrjCenter())&&n<280&&Math.abs(a)+Math.abs(o)>5?(n=5*n*(Math.abs(o)+Math.abs(a))/500,e.panBy(new me(o,a),{duration:n})):e.onMoveEnd(t)}},n._rotateStart=function(t){this._start(t),delete this._rotateMode,this.startBearing=this.target.getBearing(),this.target.onDragRotateStart(t),this._db=0},n._rotating=function(t){var e=this.target,n=t.mousePos.x,r=t.mousePos.y,i=e.getPitch(),o=e.getBearing(),a=Math.abs(n-this.preX),s=Math.abs(r-this.preY);if(this._rotateMode||(e.options.dragRotatePitch?this._rotateMode="rotate_pitch":this._rotateMode=a>s?"rotate":a<s?"pitch":"rotate"),!("pitch"===this._rotateMode&&0===i&&s<10)){if(this._rotateMode.indexOf("rotate")>=0&&e.options.dragRotate){var u;u=e.options.dragPitch||a>s?-.6*(this.preX-n):n>e.width/2?.6*(this.preY-r):-.6*(this.preY-r);var c=e.getBearing()+u;this._db=this._db||0,this._db+=u,e.setBearing(c)}this._rotateMode.indexOf("pitch")>=0&&e.options.dragPitch&&e.setPitch(e.getPitch()+.4*(this.preY-r)),this.preX=n,this.preY=r,e.getBearing()===o&&e.getPitch()===i||e.onDragRotating(t)}},n._rotateEnd=function(t){var e=this.target,n=e.getBearing();this._clear();var r=f()-this.startDragTime;if(e.onDragRotateEnd(t),Math.abs(n-this.startBearing)>20&&("rotate"===this._rotateMode||"rotate_pitch"===this._rotateMode)&&!t.interupted&&r<400){var i=e.getBearing();e._animateTo({bearing:i+this._db/2},{easing:"out",duration:800})}},n._clear=function(){delete this.startPrjCoord,delete this.preX,delete this.preY,delete this.startX,delete this.startY},e}(wn);ii.mergeOptions({draggable:!0,dragPan:!0,dragRotatePitch:!0,dragRotate:!0,dragPitch:!0}),ii.addOnLoadHook("addHandler","draggable",ai);var si="mousedown mouseup mousemove click dblclick contextmenu touchstart touchmove touchend",ui=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.addHooks=function(){var t=this.target,e=t._panels.allLayers||t._containerDOM;rn(e,si,this._identifyGeometryEvents,this)},n.removeHooks=function(){var t=this.target,e=t._panels.allLayers||t._containerDOM;on(e,si,this._identifyGeometryEvents,this)},n._identifyGeometryEvents=function(t,e){var n=this.target;if(!n.isInteracting()&&!n._ignoreEvent(t)){var r=n._getLayers((function(t){return!(!t.identify||!t.options.geometryEvents)}));if(r.length){var i=null,o=e||t.type;if("mousedown"===o||"touchstart"===o&&1===t.touches.length)this._mouseDownTime=f();else if(("click"===o||"touchend"===o)&&this._mouseDownTime){var a=this._mouseDownTime;if(delete this._mouseDownTime,f()-a>300){if("click"===o)return}else"touchend"===o&&(i="click")}var s=t.touches&&t.touches.length>0?t.touches[0]:t.changedTouches&&t.changedTouches.length>0?t.changedTouches[0]:t;if(s){var u=qe(s,n._containerDOM),c=n.containerPointToCoordinate(u);"touchstart"===o&&Ge(t);var l=null,h={includeInternals:!0,filter:function(e){if(!(e instanceof Kr))return!1;var n=e._getEventTypeToFire(t);if("mousemove"===o){if(!l&&e.options.cursor&&(l=e.options.cursor),!e.listens("mousemove")&&!e.listens("mouseover")&&!e.listens("mouseenter"))return!1}else if(!e.listens(n)&&!e.listens(i))return!1;return!0},count:1,coordinate:c,onlyVisible:n.options.onlyVisibleGeometryEvents,layers:r},d=function(e){var r=!0;if("mousemove"===o){var a={};if(e.length>0)for(var s=e.length-1;s>=0;s--){var u=e[s];if(u instanceof Kr){var c=u._getInternalId();a[c]=u,u._onEvent(t),this._prevOverGeos&&this._prevOverGeos.geomap[c]||u._onEvent(t,"mouseenter"),r=u._onEvent(t,"mouseover")}}n._setPriorityCursor(l);var h=this._prevOverGeos&&this._prevOverGeos.geos;if(this._prevOverGeos={geos:e,geomap:a},h&&h.length>0)for(var f=h.length-1;f>=0;f--){var d=h[f];if(d instanceof Kr){var p=h[f]._getInternalId();a[p]||(r=d._onEvent(t,"mouseout"))}}}else{if(!e||!e.length)return;for(var m=e.length-1;m>=0;m--)if(e[m]instanceof Kr){r=e[m]._onEvent(t),i&&e[m]._onEvent(t,i);break}}!1===r&&Ue(t)}.bind(this);"mousemove"===o||"touchmove"===o?this._queryIdentifyTimeout=n.getRenderer().callInNextFrame((function(){n.isInteracting()||n.identify(h,d)})):n.identify(h,d)}}}},e}(wn);ii.mergeOptions({geometryEvents:!0,onlyVisibleGeometryEvents:!0}),ii.addOnLoadHook("addHandler","geometryEvents",ui);var ci=4.000244140625,li=function(t){function e(e){var n;return(n=t.call(this,e)||this)._thisScrollZoom=n._scrollZoom.bind(de(de(n))),n._wheelZoomRate=1/450,n._defaultZoomRate=.01,n._delta=0,n}fe(e,t);var n=e.prototype;return n.addHooks=function(){Fe(this.target._containerDOM,"wheel",this._onWheelScroll,this)},n.removeHooks=function(){Be(this.target._containerDOM,"wheel",this._onWheelScroll)},n._onWheelScroll=function(t){Ge(t),Ue(t);var e=this.target;if(e._ignoreEvent(t)||!e.options.zoomable)return!1;var n=e._containerDOM,r=e._checkZoomOrigin(qe(t,n));return e.options.seamlessZoom?(this._zooming||(this._trackPadSuspect=0,this._ensureTrackpad=!1),this._seamless(t,r)):this._interval(t,r)},n._seamless=function(t,e){var n=t.deltaMode===window.WheelEvent.DOM_DELTA_LINE?60*t.deltaY:t.deltaY;if(n%ci!=0&&(this._ensureTrackpad||(Math.abs(n)<60?this._trackPadSuspect++:this._trackPadSuspect=0,this._trackPadSuspect>=2&&(this._ensureTrackpad=!0)),this._ensureTrackpad&&(n*=14)),t.shiftKey&&n&&(n/=4),this._lastWheelEvent=t,this._delta-=n,!this._zooming&&this._delta){var r=this.target;this._zoomOrigin=e,r.onZoomStart(null,e)}this._start()},n._start=function(){if(this._delta){this._zooming=!0;var t=this.target;this._active||(t.getRenderer().callInNextFrame(this._thisScrollZoom),this._active=!0)}},n._scrollZoom=function(){var t=this;if(this._active=!1,this._delta){var e=Math.abs(this._delta)>ci?this._wheelZoomRate:this._defaultZoomRate,n=2/(1+Math.exp(-Math.abs(this._delta*e)));this._delta<0&&0!==n&&(n=1/n);var r=this.target,i=r.getZoom(),o=r.getZoomForScale(n,i,!0);this._delta=0,r.onZooming(o,this._zoomOrigin),this._timeout&&clearTimeout(this._timeout),this._timeout=setTimeout((function(){t._zooming=!1,delete t._timeout,r.onZoomEnd(r.getZoom(),t._zoomOrigin)}),210)}},n._interval=function(t,e){var n=this,r=this.target;if(this._zooming)return this._requesting++,!1;this._requesting=0;var i=(t.deltaY?-1*t.deltaY:t.wheelDelta?t.wheelDelta:t.detail)>0?1:-1;t.detail&&(i*=-1);var o=r.getZoom(),a=o+i;return(a=r._checkZoom(i>0?Math.ceil(a):Math.floor(a)))===o||(this._zooming=!0,this._delta||(r.onZoomStart(null,e),this._origin=e,this._delta=i,this._startZoom=r.getZoom()),r._animateTo({zoom:a-1*this._delta/2,around:this._origin},{continueOnViewChanged:!0,easing:"linear",duration:90,wheelZoom:!0},(function(e){"finished"===e.state.playState?n._requesting<1||Math.abs(a-n._startZoom)>2||a===r.getMaxZoom()||a===r.getMinZoom()?(r._animateTo({zoom:a,around:n._origin},{continueOnViewChanged:!0,duration:100},(function(t){"running"!==t.state.playState&&(delete n._zooming,delete n._requesting)})),delete n._startZoom,delete n._origin,delete n._delta,n._requesting=0):p(n._requesting)||(delete n._zooming,n._onWheelScroll(t)):"running"!==e.state.playState&&(delete n._zooming,delete n._requesting)}))),!1},e}(wn);ii.mergeOptions({scrollWheelZoom:!0,seamlessZoom:!1}),ii.addOnLoadHook("addHandler","scrollWheelZoom",li);var hi=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.addHooks=function(){Fe(this.target.getContainer(),"touchstart",this._onTouchStart,this)},n.removeHooks=function(){Be(this.target.getContainer(),"touchstart",this._onTouchStart)},n._onTouchStart=function(t){var e=this.target;if(t.touches&&!(t.touches.length<2)){var n=e.getContainer(),r=qe(t.touches[0],n),i=qe(t.touches[1],n);this.preY=r.y,this._startP1=r,this._startP2=i,this._startDist=r.distanceTo(i),this._startVector=r.sub(i),this._startZoom=e.getZoom(),this._startBearing=e.getBearing(),on(document,"touchmove",this._onTouchMove,this),on(document,"touchend",this._onTouchEnd,this),Fe(document,"touchmove",this._onTouchMove,this),Fe(document,"touchend",this._onTouchEnd,this),Ge(t),e._fireEvent("touchactstart")}},n._onTouchMove=function(t){var e=this.target;if(t.touches&&!(t.touches.length<2)){var n=e.getContainer(),r=qe(t.touches[0],n),i=qe(t.touches[1],n),o=r.sub(this._startP1),a=i.sub(this._startP2),s=r.sub(i),u=r.distanceTo(i)/this._startDist,c=180*s.angleWith(this._startVector)/Math.PI,l=.4*((this.preY||r.y)-r.y);this.preY=r.y;var h={domEvent:t,mousePos:[r,i]};if(this.mode||(e.options.touchRotate&&Math.abs(c)>8?this.mode=e.options.touchZoomRotate?"rotate_zoom":"rotate":e.options.touchPitch&&o.y*a.y>0&&Math.abs(o.y)>10&&Math.abs(a.y)>10?this.mode="pitch":e.options.zoomable&&e.options.touchZoom&&Math.abs(1-u)>.15&&(this.mode=e.options.touchZoomRotate&&e.options.touchRotate?"rotate_zoom":"zoom"),this._startTouching(h)),"zoom"===this.mode||"rotate_zoom"===this.mode){this._scale=u;var f=e._getResolution(this._startZoom)/u,d=e.getZoomFromRes(f);e.onZooming(d,this._Origin)}"rotate"===this.mode||"rotate_zoom"===this.mode?(e.setBearing(this._startBearing+c),e.onDragRotating(h)):"pitch"===this.mode&&(e.setPitch(e.getPitch()+l),e.onDragRotating(h)),e._fireEvent("touchactinging")}},n._startTouching=function(t){var e=this.target;if("zoom"===this.mode||"rotate_zoom"===this.mode){var n=e.getSize();this._Origin=new me(n.width/2,n.height/2),e.onZoomStart(null,this._Origin)}"rotate"!==this.mode&&"pitch"!==this.mode&&"rotate_zoom"!==this.mode||e.onDragRotateStart(t)},n._onTouchEnd=function(t){delete this.preY;var e=this.target;if(on(document,"touchmove",this._onTouchMove,this),on(document,"touchend",this._onTouchEnd,this),"zoom"===this.mode||"rotate_zoom"===this.mode){var n=this._scale,r=e._getResolution(this._startZoom)/n,i=e.getZoomFromRes(r);e.onZoomEnd(i,this._Origin)}"pitch"!==this.mode&&"rotate"!==this.mode&&"rotate_zoom"!==this.mode||e.onDragRotateEnd({domEvent:t}),delete this.mode,e._fireEvent("touchactend")},e}(wn);ii.mergeOptions({touchGesture:!0,touchZoom:!0,touchPitch:!0,touchRotate:!0,touchZoomRotate:!1}),ii.addOnLoadHook("addHandler","touchGesture",hi);var fi="__anim_player",di={in:function(t){return Math.pow(t,2)},out:function(t){return 1-di.in(1-t)},inAndOut:function(t){return 3*t*t-2*t*t*t},linear:function(t){return t},upAndDown:function(t){return t<.5?di.inAndOut(2*t):1-di.inAndOut(2*(t-.5))}},pi=function(t,e){this.state=t,this.styles=e},mi=function(t,e,n,r){this._animation=t,this.options=e,this._onFrame=n,this.playState="idle",this.ready=!0,this.finished=!1,this.target=r},gi={speed:{slow:2e3,normal:1e3,fast:500},_resolveStyles:function(t){if(!t)return null;function e(t){if(!Array.isArray(t))return gi._resolveStyles(t);for(var e=[],n=[],r=[],i=0;i<t.length;i++){var o=gi._resolveStyles(t[i]);o&&(e.push(o[0]),n.push(o[1]),r.push(o[2]))}return e.length?[e,n,r]:null}function n(t){var e,n=t;Array.isArray(t)||(n=m(t)?[0,t]:t instanceof me||t instanceof On?[new(e=t.constructor)(0,0),t]:[t,t]);var r=n[0],i=n[1];return m(r)&&m(i)?r===i?null:[r,i-r,i]:Array.isArray(r)&&m(r[0])||r instanceof On||r instanceof me?(Array.isArray(r)?(r=new On(r),i=new On(i)):(r=new(e=r.constructor)(r),i=new e(i)),r.equals(i)?null:[r,i.sub(r),i]):[r,i,i]}function r(t){return!Array.isArray(t)&&t.constructor===Object||!(!Array.isArray(t)||t[0].constructor!==Object)}var i={},o={},a={};for(var s in t)if(t.hasOwnProperty(s)){var u,c=t[s];if(!c)continue;if(Array.isArray(c)&&(p(c[0])||p(c[1])))continue;(u=r(c)?e(c):n(c))&&(o[s]=u[0],i[s]=u[1],a[s]=u[2])}return[o,i,a]},framing:function(t,e){e||(e={});var n,r,i,o=e.easing?di[e.easing]:di.linear;return o||(o=di.linear),(t=gi._resolveStyles(t))&&(r=t[0],n=t[1],i=t[2]),function(t,e){var a,s;if(t<0)a={playState:"idle",delta:0},s=r;else if(t<e){var u=o(t/e);a={playState:"running",delta:u},s=function t(e,n,r){if(!n||!r)return null;var o={};for(var a in r)if(r.hasOwnProperty(a)){if(n[a]===i[a]){o[a]=n[a];continue}var s=n[a],u=r[a];if(m(u))o[a]=s+e*u;else if(Array.isArray(u)){for(var c=[],l=0;l<u.length;l++)c.push(t(e,s[l],u[l]));o[a]=c}else{var h=u.constructor;o[a]=h===Object?t(e,s,u):s instanceof me||s instanceof On?s.add(u.multi(e)):u}}return o}(u,r,n)}else a={playState:"finished",delta:1},s=i;return a.startStyles=r,a.destStyles=i,a.progress=t,a.remainingMs=e-t,new pi(a,s)}},_requestAnimFrame:function(t){this._frameQueue||(this._frameQueue=[]),this._frameQueue.push(t),this._a()},_a:function(){this._animationFrameId||(this._animationFrameId=T(gi._frameFn))},_run:function(){if(this._frameQueue.length){var t=this._frameQueue;this._frameQueue=[];for(var e=0,n=t.length;e<n;e++)t[e]();this._frameQueue.length?this._animationFrameId=T(gi._frameFn):delete this._animationFrameId}},animate:function(t,e,n,r){e||(e={});var i=gi.framing(t,e);return new mi(i,e,n,r)}};gi._frameFn=gi._run.bind(gi),d(mi.prototype,{_prepare:function(){var t=this.options,e=t.speed||t.duration;y(e)&&((e=gi.speed[e])||(e=+e)),e||(e=gi.speed.normal),this.duration=e,this._framer=t.framer||gi._requestAnimFrame.bind(gi)},play:function(){if("idle"!==this.playState&&"paused"!==this.playState||this.target&&this.target[fi])return this;this.target&&(this.target[fi]=1),"idle"===this.playState&&(this.currentTime=0,this._prepare());var t=f();if(!this.startTime){var e=this.options;this.startTime=e.startTime?e.startTime:t}return this._playStartTime=Math.max(t,this.startTime),"paused"===this.playState&&(this._playStartTime-=this.currentTime),this.playState="running",this._run(),this},pause:function(){return"paused"===this.playState||(this.playState="paused",this._run()),this},cancel:function(){return"idle"===this.playState||(this.playState="idle",this.finished=!1,this._run()),this},finish:function(){return"finished"===this.playState||(this.playState="finished",this.finished=!0,this._run()),this},reverse:function(){},_run:function(){var t=this,e=this._onFrame,n=f(),r=n-this._playStartTime;if(this.options.repeat&&r>=this.duration&&(this._playStartTime=n,r=0),"running"===this.playState){var i=this._animation(r,this.duration);this.playState=i.state.playState,"running"!==this.playState&&this.target&&delete this.target[fi],"idle"===this.playState?this.startTime>n&&setTimeout(this._run.bind(this),this.startTime-n):"running"===this.playState?this._framer((function(){"running"===t.playState&&(t.currentTime=r,e&&e(i),t._run())})):"finished"===this.playState&&(this.finished=!0,e&&e(i))}else if(this.target&&delete this.target[fi],e){"finished"===this.playState?r=this.duration:"idle"===this.playState&&(r=0);var o=this._animation(r,this.duration);o.state.playState=this.playState,e(o)}}});var vi=Object.freeze({Animation:gi,Easing:di,Player:mi,Frame:pi}),yi=vn((function(t){!function(){function e(t,e){var n=t.x-e.x,r=t.y-e.y;return n*n+r*r}function n(t,e,n){var r=e.x,i=e.y,o=n.x-r,a=n.y-i;if(0!==o||0!==a){var s=((t.x-r)*o+(t.y-i)*a)/(o*o+a*a);s>1?(r=n.x,i=n.y):s>0&&(r+=o*s,i+=a*s)}return(o=t.x-r)*o+(a=t.y-i)*a}function r(t,n){for(var r,i=t[0],o=[i],a=1,s=t.length;a<s;a++)e(r=t[a],i)>n&&(o.push(r),i=r);return i!==r&&o.push(r),o}function i(t,e,r,o,a){for(var s,u=o,c=e+1;c<r;c++){var l=n(t[c],t[e],t[r]);l>u&&(s=c,u=l)}u>o&&(s-e>1&&i(t,e,s,o,a),a.push(t[s]),r-s>1&&i(t,s,r,o,a))}function o(t,e){var n=t.length-1,r=[t[0]];return i(t,0,n,e,r),r.push(t[n]),r}function a(t,e,n){if(t.length<=2)return t;var i=void 0!==e?e*e:1;return t=o(t=n?t:r(t,i),i)}t.exports=a,t.exports.default=a}()})),_i=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.getOutline=function(){if(!this._getPainter())return null;var t=this.getExtent();return new bi(t.toArray(),{symbol:{lineWidth:1,lineColor:"6b707b"}})},n.animateShow=function(t,e){var n=this;void 0===t&&(t={}),this._showPlayer&&this._showPlayer.finish(),_(t)&&(e=t={});var r=this.getCoordinates();if(0===r.length)return this;this._animIdx=0,this._animLenSoFar=0,this.show();var i=this.getShell?this.getShell().concat(this.getShell()[0]):this.getCoordinates(),o=this._getProjection(),a=o.projectCoords(i);this._prjAniShowCenter=this._getPrjExtent().getCenter(),this._aniShowCenter=o.unproject(this._prjAniShowCenter);var s=t.duration||1e3,u=t.easing||"out";this.setCoordinates([]);for(var c=0,l=1;l<a.length;l++)c+=a[l].distanceTo(a[l-1]);var h=this._showPlayer=gi.animate({t:s},{duration:s,easing:u},(function(t){if(n.getMap()){var o=n._drawAnimShowFrame(t.styles.t,s,c,i,a);"finished"===t.state.playState&&(delete n._showPlayer,delete n._aniShowCenter,delete n._prjAniShowCenter,delete n._animIdx,delete n._animLenSoFar,delete n._animTailRatio,n.setCoordinates(r)),e&&e(t,o)}else if("finished"!==h.playState&&(h.finish(),e)){var u=n.getCoordinates();e(t,u[u.length-1])}}),this);return h.play(),h},n._drawAnimShowFrame=function(t,e,n,r,i){if(0===t)return r[0];var o,a,s=this._getProjection(),u=t/e*n,c=0;for(o=this._animIdx,a=i.length;o<a-1&&(c=i[o].distanceTo(i[o+1]),!(this._animLenSoFar+c>u));o++)this._animLenSoFar+=c;if(this._animIdx=o,this._animIdx>=a-1)return this.setCoordinates(r),r[r.length-1];var l=this._animIdx,h=i[l],f=i[l+1],d=(u-this._animLenSoFar)/c;this._animTailRatio=d;var p=h.x+(f.x-h.x)*d,m=h.y+(f.y-h.y)*d,g=new On(p,m),v=s.unproject(g),y=!!this.getShell;if(!y&&this.options.smoothness>0){var _=r.slice(0,this._animIdx+3);this.setCoordinates(_);var x=i.slice(0,this._animIdx+3);this._setPrjCoordinates(x)}else{var b=r.slice(0,this._animIdx+1);b.push(v);var w=i.slice(0,this._animIdx+1);w.push(g),y?(this.setCoordinates([this._aniShowCenter].concat(b)),this._setPrjCoordinates([this._prjAniShowCenter].concat(w))):(this.setCoordinates(b),this._setPrjCoordinates(w))}return v},n._getCenterInExtent=function(t,e,n){var r=this.getExtent();if(!t.intersects(r))return null;var i=n(e,t);if(0===i.length)return null;var o=0,a=0,s=0;i.forEach((function(t){Array.isArray(t)?t.forEach((function(t){t.point&&(t=t.point),o+=t.x,a+=t.y,s++})):(t.point&&(t=t.point),o+=t.x,a+=t.y,s++)}));var u=new On(o,a)._multi(1/s);return u.count=s,u},n._getPath2DPoints=function(t,e,n){if(!U(t))return[];var r=this.getMap(),i=!e&&this._shouldSimplify(),o=this.options.simplifyTolerance*r._getResolution(),a=Array.isArray(t[0]);if(delete this._simplified,i&&!a){var s=t.length;t=yi(t,o,!1),this._simplified=t.length<s}return p(n)&&(n=r.getZoom()),j(t,(function(t){return r._prjToPoint(t,n)}))},n._shouldSimplify=function(){var t=this.getLayer(),e=this.getProperties(),n=e&&t.options.enableAltitude&&!p(e[t.options.altitudeProperty]);return t&&t.options.enableSimplify&&!n&&this.options.enableSimplify&&!this._showPlayer},n._setPrjCoordinates=function(t){this._prjCoords=t,this.onShapeChanged()},n._getPrjCoordinates=function(){return this._verifyProjection(),!this._prjCoords&&this._getProjection()&&(this._prjCoords=this._projectCoords(this._coordinates)),this._prjCoords},n._updateCache=function(){this._clearCache(),this._getProjection()&&this._prjCoords&&(this._coordinates=this._unprojectCoords(this._getPrjCoordinates()))},n._clearProjection=function(){this._prjCoords=null,t.prototype._clearProjection.call(this)},n._projectCoords=function(t){var e=this._getProjection();return e?e.projectCoords(t):[]},n._unprojectCoords=function(t){var e=this._getProjection();return e?e.unprojectCoords(t):[]},n._computeCenter=function(){var t=this._coordinates;if(!U(t))return null;for(var e=0,n=0,r=0,i=t.length,o=0;o<i;o++)t[o]&&m(t[o].x)&&m(t[o].y)&&(e+=t[o].x,n+=t[o].y,r++);return new On(e/r,n/r)},n._computeExtent=function(){var t=this._coordinates;if(!U(t))return null;var e=[t];return this.hasHoles&&this.hasHoles()&&e.push.apply(e,this.getHoles()),this._coords2Extent(e,this._getProjection())},n._computePrjExtent=function(){var t=[this._getPrjCoordinates()];return this.hasHoles&&this.hasHoles()&&t.push.apply(t,this._getPrjHoles()),this._coords2Extent(t)},n._get2DLength=function(){for(var t=this._getPath2DPoints(this._getPrjCoordinates(),!0),e=0,n=1,r=t.length;n<r;n++)e+=t[n].distanceTo(t[n-1]);return e},n._hitTestTolerance=function(){var t,e=this._getInternalSymbol();if(Array.isArray(e)){t=0;for(var n=0;n<e.length;n++)m(e[n].lineWidth)&&e[n].lineWidth>t&&(t=e[n].lineWidth)}else t=e.lineWidth;return m(t)?t/2:1.5},n._coords2Extent=function(t,e){for(var n=new Vn(e),r=0,i=t.length;r<i;r++)for(var o=0,a=t[r].length;o<a;o++)n._combine(t[r][o]);return n},e}(Kr);_i.mergeOptions({smoothness:0,enableClip:!0,enableSimplify:!0,simplifyTolerance:2,symbol:{lineColor:"#000",lineWidth:2,lineOpacity:1,polygonFill:"#fff",polygonOpacity:1,opacity:1}});var xi="Polygon",bi=function(t){function e(e,n){var r;return(r=t.call(this,n)||this).type="Polygon",e&&r.setCoordinates(e),r}fe(e,t);var n=e.prototype;return n.setCoordinates=function(t){if(!t)return this._coordinates=null,this._holes=null,this._projectRings(),this;var e=On.toCoordinates(t),n=e.length;if(Array.isArray(e[0])){if(this._coordinates=this._trimRing(e[0]),n>1){for(var r=[],i=1;i<n;i++)e[i]&&r.push(this._trimRing(e[i]));this._holes=r}}else this._coordinates=this._trimRing(e);return this._projectRings(),this},n.getCoordinates=function(){if(!this._coordinates)return[];for(var t=this.getHoles(),e=[this._copyAndCloseRing(this._coordinates)],n=0,r=t.length;n<r;n++)e.push(this._copyAndCloseRing(t[n]));return e},n.getCenterInExtent=function(t){return this._getCenterInExtent(t,this.getShell(),_r)},n.getShell=function(){return this._coordinates||[]},n.getHoles=function(){return this._holes||[]},n.hasHoles=function(){return this.getHoles().length>0},n._projectRings=function(){this.getMap()?(this._prjCoords=this._projectCoords(this._coordinates),this._prjHoles=this._projectCoords(this._holes),this.onShapeChanged()):this.onShapeChanged()},n._setPrjCoordinates=function(t){this._prjCoords=t,this.onShapeChanged()},n._cleanRing=function(t){for(var e=t.length-1;e>=0;e--)t[e]||t.splice(e,1)},n._checkRing=function(t){if(this._cleanRing(t),!t||!U(t))return!1;var e=t[t.length-1],n=!0;return t[0].x===e.x&&t[0].y===e.y||(n=!1),n},n._trimRing=function(t){var e=this._checkRing(t);return U(t)&&e&&t.splice(t.length-1,1),t},n._copyAndCloseRing=function(t){t=t.slice(0);var e=this._checkRing(t);return U(t)&&!e?(t.push(t[0].copy()),t):t},n._getPrjShell=function(){return this.getJSONType()===xi?this._getPrjCoordinates():(this._verifyProjection(),this._getProjection()&&!this._prjShell&&(this._prjShell=this._projectCoords(this.getShell())),this._prjShell)},n._getPrjHoles=function(){var t=this._getProjection();return this._verifyProjection(),t&&!this._prjHoles&&(this._prjHoles=this._projectCoords(this.getHoles())),this._prjHoles},n._computeGeodesicLength=function(t){var e=this.getCoordinates();if(!U(e))return 0;for(var n=0,r=0,i=e.length;r<i;r++)n+=t.measureLength(e[r]);return n},n._computeGeodesicArea=function(t){var e=this.getCoordinates();if(!U(e))return 0;for(var n=t.measureArea(e[0]),r=1,i=e.length;r<i;r++)n-=t.measureArea(e[r]);return n},n._updateCache=function(){t.prototype._updateCache.call(this),this._prjHoles&&(this._holes=this._unprojectCoords(this._getPrjHoles()))},n._clearCache=function(){return delete this._prjShell,t.prototype._clearCache.call(this)},n._clearProjection=function(){this._prjHoles&&(this._prjHoles=null),this._prjShell&&(this._prjShell=null),t.prototype._clearProjection.call(this)},e}(_i);function wi(t){return function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.getCoordinates=function(){return this._coordinates},n.setCoordinates=function(t){var e=t instanceof On?t:new On(t);if(e.equals(this._coordinates))return this;if(this._coordinates=e,!this.getMap())return this.onPositionChanged(),this;var n=this._getProjection();return this._setPrjCoordinates(n.project(this._coordinates)),this},n._getCenter2DPoint=function(t){var e=this.getMap();if(!e)return null;var n=p(t)?e.getZoom():e.getGLZoom(),r=this._getPrjCoordinates();return r?e._prjToPoint(r,n):null},n._getPrjCoordinates=function(){var t=this._getProjection();return this._verifyProjection(),!this._pcenter&&t&&this._coordinates&&(this._pcenter=t.project(this._coordinates)),this._pcenter},n._setPrjCoordinates=function(t){this._pcenter=t,this.onPositionChanged()},n._updateCache=function(){this._clearCache();var t=this._getProjection();this._pcenter&&t&&(this._coordinates=t.unproject(this._pcenter))},n._clearProjection=function(){this._pcenter=null,t.prototype._clearProjection.call(this)},n._computeCenter=function(){return this._coordinates?this._coordinates.copy():null},e}(t)}bi.registerJSONType(xi);var Mi=function(t){function e(e,n){var r;return(r=t.call(this,n)||this).type="Point",e&&r.setCoordinates(e),r}fe(e,t);var n=e.prototype;return n.getOutline=function(){var t=this._getPainter();if(!t)return null;var n=this.getCoordinates(),r=t.getContainerExtent(),i=this.getMap().coordToContainerPoint(n);return new e(n,{symbol:{markerType:"square",markerWidth:r.getWidth(),markerHeight:r.getHeight(),markerLineWidth:1,markerLineColor:"6b707b",markerFill:"rgba(0, 0, 0, 0)",markerDx:r.xmin-(i.x-r.getWidth()/2),markerDy:r.ymin-(i.y-r.getHeight()/2)}})},n._isVectorMarker=function(){var t=this._getInternalSymbol();return!Array.isArray(t)&&Cr.test(t)},n._canEdit=function(){var t=this._getInternalSymbol();return!Array.isArray(t)&&(Cr.test(t)||zr.test(t)||Lr.test(t))},n._containsPoint=function(e,n){var r=this.getContainerExtent();return n&&(r=r.expand(n)),!!r.contains(e)&&(!this.options.hitTestForEvent||t.prototype._containsPoint.call(this,e,n))},n._computeExtent=function(){return Si.call(this,"getCenter")},n._computePrjExtent=function(){return Si.call(this,"_getPrjCoordinates")},n._computeGeodesicLength=function(){return 0},n._computeGeodesicArea=function(){return 0},n._getSprite=function(t,e){return this._getPainter()?this._getPainter().getSprite(t,e):new Yr(this).getSprite(t,e)},e}(wi(Kr));function Si(t){var e=this[t]();return e?new Vn(e,e,this._getProjection()):null}Mi.mergeOptions({symbol:{markerType:"path",markerPath:[{path:"M8 23l0 0 0 0 0 0 0 0 0 0c-4,-5 -8,-10 -8,-14 0,-5 4,-9 8,-9l0 0 0 0c4,0 8,4 8,9 0,4 -4,9 -8,14z M3,9 a5,5 0,1,0,0,-0.9Z",fill:"#DE3333"}],markerPathWidth:16,markerPathHeight:23,markerWidth:24,markerHeight:34},hitTestForEvent:!1}),Mi.registerJSONType("Marker");var Ti=function(t){function e(e,n){var r;return(r=t.call(this,n)||this).type="LineString",e&&r.setCoordinates(e),r}fe(e,t);var n=e.prototype;return n.setCoordinates=function(t){return t?(this._coordinates=On.toCoordinates(t),this.getMap()?this._setPrjCoordinates(this._projectCoords(this._coordinates)):this.onShapeChanged(),this):(this._coordinates=null,this._setPrjCoordinates(null),this)},n.getCoordinates=function(){return this._coordinates||[]},n.getCenterInExtent=function(t){return this._getCenterInExtent(t,this.getCoordinates(),vr)},n._computeGeodesicLength=function(t){return t.measureLength(this.getCoordinates())},n._computeGeodesicArea=function(){return 0},e}(_i);Ti.mergeOptions({arrowStyle:null,arrowPlacement:"vertex-last"}),Ti.registerJSONType("LineString");var Ei=function(t){function e(e,n){var r;return(r=t.call(this,n)||this).type="GeometryCollection",r.setGeometries(e),r}fe(e,t);var n=e.prototype;return n.setGeometries=function(t){for(var e=this._checkGeometries(t||[]),n=this._getSymbol(),r=this.config(),i=e.length-1;i>=0;i--)e[i]._initOptions(r),e[i]._setParent(this),e[i]._setEventParent(this),n&&e[i].setSymbol(n);return this._geometries=e,this.getLayer()&&(this._bindGeometriesToLayer(),this.onShapeChanged()),this},n.getGeometries=function(){return this._geometries||[]},n.forEach=function(t,e){for(var n=this.getGeometries(),r=0,i=n.length;r<i;r++)n[r]&&(e?t.call(e,n[r],r):t(n[r],r));return this},n.filter=function(t,n){if(!t)return new e;var r=[],i=_(t),o=i?t:rt(t);return this.forEach((function(t){var e=i?t:ft(t);(n?o.call(n,e):o(e))&&r.push(t)}),this),new e(r)},n.translate=function(t){if(!t)return this;if(this.isEmpty())return this;var e=arguments;return this.forEach((function(t){t&&t.translate&&t.translate.apply(t,e)})),this},n.isEmpty=function(){return!U(this.getGeometries())},n.remove=function(){return this.forEach((function(t){t._unbind()})),Kr.prototype.remove.apply(this,arguments)},n.show=function(){return this.options.visible=!0,this.forEach((function(t){t.show()})),this},n.hide=function(){return this.options.visible=!1,this.forEach((function(t){t.hide()})),this},n.onConfig=function(t){this.forEach((function(e){e.config(t)}))},n.getSymbol=function(){var e=t.prototype.getSymbol.call(this);if(!e){var n=[],r=!1;this.forEach((function(t){t.getSymbol()&&!r&&(r=!0),n.push(t.getSymbol())})),r&&(e={children:n})}return e},n.setSymbol=function(t){if(t&&t.children)this._symbol=null,this.forEach((function(e,n){e.setSymbol(t.children[n])}));else{var e=this._prepareSymbol(t);this._symbol=e,this.forEach((function(t){t.setSymbol(e)}))}return this.onSymbolChanged(),this},n._setExternSymbol=function(t){return t=this._prepareSymbol(t),this._externSymbol=t,this.forEach((function(e){e._setExternSymbol(t)})),this.onSymbolChanged(),this},n._bindLayer=function(){t.prototype._bindLayer.apply(this,arguments),this._bindGeometriesToLayer()},n._bindGeometriesToLayer=function(){var t=this.getLayer();this.forEach((function(e){e._bindLayer(t)}))},n._checkGeometries=function(t){var e="The geometry added to collection is invalid.";if(t&&!Array.isArray(t)){if(t instanceof Kr)return[t];throw new Error(e)}for(var n=0,r=t.length;n<r;n++)if(!this._checkGeo(t[n]))throw new Error(e+" Index: "+n);return t},n._checkGeo=function(t){return t instanceof Kr},n._updateCache=function(){this._clearCache(),this.isEmpty()||this.forEach((function(t){t&&t._updateCache&&t._updateCache()}))},n._removePainter=function(){this._painter&&this._painter.remove(),delete this._painter,this.forEach((function(t){t._removePainter()}))},n._computeCenter=function(t){if(!t||this.isEmpty())return null;for(var e=0,n=0,r=0,i=this.getGeometries(),o=0,a=i.length;o<a;o++)if(i[o]){var s=i[o]._computeCenter(t);s&&(e+=s.x,n+=s.y,r++)}return 0===r?null:new On(e/r,n/r)},n._containsPoint=function(t,e){if(this.isEmpty())return!1;for(var n=this.getGeometries(),r=0,i=n.length;r<i;r++)if(n[r]._containsPoint(t,e))return!0;return!1},n._computeExtent=function(t){return Ai.call(this,t,"_computeExtent")},n._computePrjExtent=function(t){return Ai.call(this,t,"_computePrjExtent")},n._computeGeodesicLength=function(t){if(!t||this.isEmpty())return 0;for(var e=this.getGeometries(),n=0,r=0,i=e.length;r<i;r++)e[r]&&(n+=e[r]._computeGeodesicLength(t));return n},n._computeGeodesicArea=function(t){if(!t||this.isEmpty())return 0;for(var e=this.getGeometries(),n=0,r=0,i=e.length;r<i;r++)e[r]&&(n+=e[r]._computeGeodesicArea(t));return n},n._exportGeoJSONGeometry=function(){var t=[];if(!this.isEmpty())for(var e=this.getGeometries(),n=0,r=e.length;n<r;n++)e[n]&&t.push(e[n]._exportGeoJSONGeometry());return{type:"GeometryCollection",geometries:t}},n._clearProjection=function(){if(!this.isEmpty())for(var t=this.getGeometries(),e=0,n=t.length;e<n;e++)t[e]&&t[e]._clearProjection()},n._getConnectPoints=function(){var t=this.getExtent();return[new On(t.xmin,t.ymax),new On(t.xmax,t.ymin),new On(t.xmin,t.ymin),new On(t.xmax,t.ymax)]},n._getExternalResources=function(){if(this.isEmpty())return[];for(var t,e,n=this.getGeometries(),r=[],i={},o=0,a=n.length;o<a;o++)if(n[o])for(var s=0,u=(t=Pt(n[o]._getInternalSymbol())).length;s<u;s++)i[e=t[s].join()]||(r.push(t[s]),i[e]=1);return r},n.startEdit=function(t){var e=this;if(this.isEmpty())return this;t||(t={}),t.symbol&&(this._originalSymbol=this.getSymbol(),this.setSymbol(t.symbol)),this._draggbleBeforeEdit=this.options.draggable,this.config("draggable",!1);for(var n=this.getGeometries(),r=0,i=n.length;r<i;r++)n[r].startEdit(t);return this._editing=!0,this.hide(),setTimeout((function(){e.fire("editstart")}),1),this},n.endEdit=function(){if(this.isEmpty())return this;for(var t=this.getGeometries(),e=0,n=t.length;e<n;e++)t[e].endEdit();return this._originalSymbol&&(this.setSymbol(this._originalSymbol),delete this._originalSymbol),this._editing=!1,this.show(),this.config("draggable",this._draggbleBeforeEdit),this.fire("editend"),this},n.isEditing=function(){return!!this._editing},e}(Kr);function Ai(t,e){if(this.isEmpty())return null;for(var n=this.getGeometries(),r=null,i=0,o=n.length;i<o;i++){var a=n[i];if(a){var s=a[e](t);s&&(r=s.combine(r))}}return r}Ei.registerJSONType("GeometryCollection");var Ci=function(t){function e(e,n,r,i){var o;return(o=t.call(this,null,i)||this).GeometryType=e,o.type=n,o._initData(r),o}fe(e,t);var n=e.prototype;return n.getCoordinates=function(){for(var t=[],e=this.getGeometries(),n=0,r=e.length;n<r;n++){var i=e[n];t.push(i.getShell&&"Polygon"!==i.getJSONType()?[i.getShell()]:i.getCoordinates())}return t},n.setCoordinates=function(t){for(var e=[],n=0,r=(t=t||[]).length;n<r;n++){var i=new this.GeometryType(t[n],this.config());e.push(i)}return this.setGeometries(e),this},n._initData=function(t){(t=t||[]).length&&(t[0]instanceof this.GeometryType?this.setGeometries(t):this.setCoordinates(t))},n._checkGeo=function(t){return t instanceof this.GeometryType},n._exportGeoJSONGeometry=function(){var t=this.getCoordinates(),e=On.toNumberArrays(t);return{type:this.getType(),coordinates:e}},e}(Ei),Pi=function(t){function e(e,n){return t.call(this,Mi,"MultiPoint",e,n)||this}return fe(e,t),e.prototype.findClosest=function(t){if(!t)return null;var e=this.getCoordinates(),n=null,r=1/0;return e.forEach((function(e){var i=function(t,e){var n=e.x-t.x,r=e.y-t.y;return Math.sqrt(n*n+r*r)}(e,t);i<r&&(n=e,r=i)})),n},e}(Ci);Pi.registerJSONType("MultiPoint");var Li=function(t){function e(){return t.apply(this,arguments)||this}return fe(e,t),e.prototype.getCenterInExtent=function(t){var e=this.getGeometries(),n=0,r=0,i=0;return e.forEach((function(e){var o=e.getCenterInExtent(t);o&&(n+=o.x*o.count,r+=o.y*o.count,i+=o.count)})),0===i?null:new On(n,r)._multi(1/i)},e}(Ci),Oi=function(t){function e(e,n){return t.call(this,Ti,"MultiLineString",e,n)||this}return fe(e,t),e}(Li);Oi.registerJSONType("MultiLineString");var Ri=function(t){function e(e,n){return t.call(this,bi,"MultiPolygon",e,n)||this}return fe(e,t),e}(Li);Ri.registerJSONType("MultiPolygon");var ki={Marker:Mi,LineString:Ti,Polygon:bi,MultiPoint:Pi,MultiLineString:Oi,MultiPolygon:Ri},Ii={toGeometry:function(t,e){if(y(t)&&(t=k(t)),Array.isArray(t)){for(var n=[],r=0,i=t.length;r<i;r++){var o=Ii._convert(t[r],e);Array.isArray(o)?I(n,o):n.push(o)}return n}return Ii._convert(t,e)},_convert:function(t,e){if(!t||p(t.type))return null;var n=t.type;if("Feature"===n){var r=t.geometry,i=Ii._convert(r);return i?(i.setId(t.id),i.setProperties(t.properties),e&&e(i),i):null}if("FeatureCollection"===n){var o=t.features;return o?Ii.toGeometry(o,e):null}if(["Point","LineString","Polygon","MultiPoint","MultiLineString","MultiPolygon"].indexOf(n)>=0){var a=new ki["Point"===n?"Marker":n](t.coordinates);return e&&e(a),a}if("GeometryCollection"===n){var s=t.geometries;if(!U(s)){var u=new Ei;return e&&e(u),u}for(var c=[],l=s.length,h=0;h<l;h++)c.push(Ii._convert(s[h]));var f=new Ei(c);return e&&e(f),f}return null}},Di=function(t){function e(e,n,r){var i;return i=t.call(this,null,r)||this,e&&i.setCoordinates(e),i._radius=n,i}fe(e,t),e.fromJSON=function(t){var n=t.feature,r=new e(t.coordinates,t.radius,t.options);return r.setProperties(n.properties),r};var n=e.prototype;return n.getRadius=function(){return this._radius},n.setRadius=function(t){return this._radius=t,this.onShapeChanged(),this},n.getShell=function(){for(var t,e,n,r=this._getMeasurer(),i=this.getCoordinates(),o=this.options.numberOfShellPoints,a=this.getRadius(),s=[],u=0,c=o-1;u<c;u++){t=360*u/c*Math.PI/180,e=a*Math.cos(t),n=a*Math.sin(t);var l=r.locate(i,e,n);s.push(l)}return s.push(s[0]),s},n.getHoles=function(){return[]},n.animateShow=function(){return this.show()},n._containsPoint=function(e,n){var r=this.getMap();if(r.getPitch())return t.prototype._containsPoint.call(this,e,n);var i=r._pointToContainerPoint(this._getCenter2DPoint()),o=this.getSize(),a=p(n)?this._hitTestTolerance():n,s=i.add(o.width/2,o.height/2);return wr(e,i,s,a)},n._computePrjExtent=function(t){var e=this._getMinMax(t);if(!e)return null;var n=this._getPrjCoordinates(),r=e.map((function(e){return t.project(e)})),i=r[0].x-n.x,o=r[1].x-n.x,a=r[2].y-n.y,s=r[3].y-n.y;return new Vn(n.add(i,a),n.add(o,s))},n._computeExtent=function(t){var e=this._getMinMax(t);return e?new Vn(e[0].x,e[2].y,e[1].x,e[3].y,this._getProjection()):null},n._getMinMax=function(t){if(!t||!this._coordinates||p(this._radius))return null;var e=this._radius;return[t.locate(this._coordinates,-e,0),t.locate(this._coordinates,e,0),t.locate(this._coordinates,0,e),t.locate(this._coordinates,0,-e)]},n._computeGeodesicLength=function(){return p(this._radius)?0:2*Math.PI*this._radius},n._computeGeodesicArea=function(){return p(this._radius)?0:Math.PI*Math.pow(this._radius,2)},n._exportGeoJSONGeometry=function(){return{type:"Polygon",coordinates:On.toNumberArrays([this.getShell()])}},n._toJSON=function(t){var e=this.getCenter(),n=d({},t);n.geometry=!1;var r=this.toGeoJSON(n);return r.geometry={type:"Polygon"},{feature:r,subType:"Circle",coordinates:[e.x,e.y],radius:this.getRadius()}},e}(wi(bi));Di.mergeOptions({numberOfShellPoints:60}),Di.registerJSONType("Circle");var ji=function(t){function e(e,n,r,i){var o;return o=t.call(this,null,i)||this,e&&o.setCoordinates(e),o.width=n,o.height=r,o}fe(e,t),e.fromJSON=function(t){var n=t.feature,r=new e(t.coordinates,t.width,t.height,t.options);return r.setProperties(n.properties),r};var n=e.prototype;return n.getWidth=function(){return this.width},n.setWidth=function(t){return this.width=t,this.onShapeChanged(),this},n.getHeight=function(){return this.height},n.setHeight=function(t){return this.height=t,this.onShapeChanged(),this},n.getShell=function(){for(var t,e,n,r,i=this._getMeasurer(),o=this.getCoordinates(),a=this.options.numberOfShellPoints,s=this.getWidth(),u=this.getHeight(),c=[],l=Math.pow(s/2,2)*Math.pow(u/2,2),h=Math.pow(s/2,2),f=Math.pow(u/2,2),d=0;d<a;d++){e=(t=360*d/a)*Math.PI/180,n=Math.sqrt(l/(h*Math.pow(Math.tan(e),2)+f)),r=Math.sqrt(l/(f*Math.pow(1/Math.tan(e),2)+h)),t>90&&t<270&&(n*=-1),t>180&&t<360&&(r*=-1);var p=i.locate(o,n,r);c.push(p)}return c},n.getHoles=function(){return[]},n.animateShow=function(){return this.show()},n._containsPoint=function(e,n){var r=this.getMap();if(r.isTransforming())return t.prototype._containsPoint.call(this,e,n);var i=r.getProjection(),o=p(n)?this._hitTestTolerance():n,a=i.projectCoords([this._coordinates,r.locate(this._coordinates,this.getWidth()/2,this.getHeight()/2)]);return wr(e,r._prjToContainerPoint(a[0]),r._prjToContainerPoint(a[1]),o)},n._computePrjExtent=function(){return Di.prototype._computePrjExtent.apply(this,arguments)},n._computeExtent=function(){return Di.prototype._computeExtent.apply(this,arguments)},n._getMinMax=function(t){if(!t||!this._coordinates||p(this.width)||p(this.height))return null;var e=this.getWidth(),n=this.getHeight();return[t.locate(this._coordinates,-e/2,0),t.locate(this._coordinates,e/2,0),t.locate(this._coordinates,0,-n/2),t.locate(this._coordinates,0,n/2)]},n._computeGeodesicLength=function(){if(p(this.width)||p(this.height))return 0;var t=this.width>this.height?this.width:this.height;return 2*Math.PI*t/2-4*Math.abs(this.width-this.height)},n._computeGeodesicArea=function(){return p(this.width)||p(this.height)?0:Math.PI*this.width*this.height/4},n._exportGeoJSONGeometry=function(){return{type:"Polygon",coordinates:On.toNumberArrays([this.getShell()])}},n._toJSON=function(t){var e=d({},t),n=this.getCenter();e.geometry=!1;var r=this.toGeoJSON(e);return r.geometry={type:"Polygon"},{feature:r,subType:"Ellipse",coordinates:[n.x,n.y],width:this.getWidth(),height:this.getHeight()}},e}(wi(bi));ji.mergeOptions({numberOfShellPoints:80}),ji.registerJSONType("Ellipse");var zi=function(t){function e(e,n,r,i){var o;return o=t.call(this,null,i)||this,e&&o.setCoordinates(e),o._width=n,o._height=r,o}fe(e,t),e.fromJSON=function(t){var n=t.feature,r=new e(t.coordinates,t.width,t.height,t.options);return r.setProperties(n.properties),r};var n=e.prototype;return n.getCoordinates=function(){return this._coordinates},n.setCoordinates=function(t){if(this._coordinates=t instanceof On?t:new On(t),!this._coordinates||!this.getMap())return this.onPositionChanged(),this;var e=this._getProjection();return this._setPrjCoordinates(e.project(this._coordinates)),this},n.getWidth=function(){return this._width},n.setWidth=function(t){return this._width=t,this.onShapeChanged(),this},n.getHeight=function(){return this._height},n.setHeight=function(t){return this._height=t,this.onShapeChanged(),this},n.getShell=function(){var t=this._getMeasurer(),e=this._coordinates,n=this.getMap(),r=1,i=-1;if(n){var o=n.getFullExtent();o.left>o.right&&(r=-1),o.bottom>o.top&&(i=1)}var a=[];return a.push(e),a.push(t.locate(e,r*this._width,0)),a.push(t.locate(e,r*this._width,i*this._height)),a.push(t.locate(e,0,i*this._height)),a.push(e),a},n.getHoles=function(){return[]},n.animateShow=function(){return this.show()},n._getPrjCoordinates=function(){var t=this._getProjection();return this._verifyProjection(),!this._pnw&&t&&this._coordinates&&(this._pnw=t.project(this._coordinates)),this._pnw},n._setPrjCoordinates=function(t){this._pnw=t,this.onPositionChanged()},n._getPrjShell=function(){var e=t.prototype._getPrjShell.call(this),n=this._getProjection();if(!n.isSphere())return e;for(var r=n.getSphereExtent(),i=r.sx,o=r.sy,a=this._getProjection().getCircum(),s=e[0],u=1,c=e.length;u<c;u++){var l=e[u],h=0,f=0;i*(s.x-l.x)>0&&(h=a.x*i),o*(s.y-l.y)<0&&(f=a.y*o),e[u]._add(h,f)}return e},n._updateCache=function(){this._clearCache();var t=this._getProjection();this._pnw&&t&&(this._coordinates=t.unproject(this._pnw))},n._clearProjection=function(){this._pnw=null,t.prototype._clearProjection.call(this)},n._computeCenter=function(t){return t.locate(this._coordinates,this._width/2,-this._height/2)},n._containsPoint=function(e,n){var r=this.getMap();if(r.isTransforming())return t.prototype._containsPoint.call(this,e,n);var i=p(n)?this._hitTestTolerance():n,o=r._getResolution()*i,a=this._getPrjExtent().expand(o),s=r._containerPointToPrj(e);return a.contains(s)},n._computePrjExtent=function(t){var e=this._getSouthEast(t);if(!e)return null;var n=t.projectCoords([new On(this._coordinates.x,e.y),new On(e.x,this._coordinates.y)]);return new Vn(n[0],n[1])},n._computeExtent=function(t){var e=this._getSouthEast(t);return e?new Vn(this._coordinates,e,this._getProjection()):null},n._getSouthEast=function(t){if(!t||!this._coordinates||p(this._width)||p(this._height))return null;var e=this.getWidth(),n=-this.getHeight();if(t.fullExtent){var r=t.fullExtent;e*=r.right>r.left?1:-1,n*=r.top>r.bottom?1:-1}return t.locate(this._coordinates,e,n)},n._computeGeodesicLength=function(){return p(this._width)||p(this._height)?0:2*(this._width+this._height)},n._computeGeodesicArea=function(){return p(this._width)||p(this._height)?0:this._width*this._height},n._exportGeoJSONGeometry=function(){return{type:"Polygon",coordinates:On.toNumberArrays([this.getShell()])}},n._toJSON=function(t){var e=d({},t),n=this.getCoordinates();e.geometry=!1;var r=this.toGeoJSON(e);return r.geometry={type:"Polygon"},{feature:r,subType:"Rectangle",coordinates:[n.x,n.y],width:this.getWidth(),height:this.getHeight()}},e}(bi);zi.registerJSONType("Rectangle");var Ni=function(t){function e(e,n,r,i,o){var a;return(a=t.call(this,e,n,o)||this).startAngle=r,a.endAngle=i,a}fe(e,t),e.fromJSON=function(t){var n=t.feature,r=new e(t.coordinates,t.radius,t.startAngle,t.endAngle,t.options);return r.setProperties(n.properties),r};var n=e.prototype;return n.getStartAngle=function(){return this.startAngle},n.setStartAngle=function(t){return this.startAngle=t,this.onShapeChanged(),this},n.getEndAngle=function(){return this.endAngle},n.setEndAngle=function(t){return this.endAngle=t,this.onShapeChanged(),this},n.getShell=function(){for(var t,e,n,r=this._getMeasurer(),i=this.getCoordinates(),o=this.options.numberOfShellPoints-2,a=this.getRadius(),s=[i.copy()],u=this.getStartAngle(),c=this.getEndAngle()-u,l=0;l<o;l++){t=(c*l/(o-1)+u)*Math.PI/180,e=a*Math.cos(t),n=a*Math.sin(t);var h=r.locate(i,e,n);s.push(h)}return s.push(i.copy()),s},n._containsPoint=function(e,n){var r=this.getMap();if(r.isTransforming())return t.prototype._containsPoint.call(this,e,n);var i,o=r._pointToContainerPoint(this._getCenter2DPoint()),a=p(n)?this._hitTestTolerance():n,s=this.getSize(),u=o,c=e,l=c.x-u.x,h=u.y-c.y,f=Math.atan2(h,l),d=f<0?360*(f+2*Math.PI)/(2*Math.PI):360*f/(2*Math.PI),m=this.startAngle%360,g=this.endAngle%360;return i=m>g?!(d>g&&d<m):d>=m&&d<=g,c.distanceTo(u)<=s.width/2+a&&i},n._computeGeodesicLength=function(){return p(this._radius)?0:2*Math.PI*this._radius*Math.abs(this.startAngle-this.endAngle)/360+2*this._radius},n._computeGeodesicArea=function(){return p(this._radius)?0:Math.PI*Math.pow(this._radius,2)*Math.abs(this.startAngle-this.endAngle)/360},n._toJSON=function(t){var e=d({},t),n=this.getCenter();e.geometry=!1;var r=this.toGeoJSON(e);return r.geometry={type:"Polygon"},{feature:r,subType:"Sector",coordinates:[n.x,n.y],radius:this.getRadius(),startAngle:this.getStartAngle(),endAngle:this.getEndAngle()}},e}(Di);Ni.mergeOptions({numberOfShellPoints:60}),Ni.registerJSONType("Sector");var Fi=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n._arc=function(t,e,n){for(var r=this.options.arcDegree*Math.PI/180,i=1,o=e.length;i<o;i++){var a=hn._arcBetween(t,e[i-1],e[i],r),s=[e[i-1].x+e[i].x-a[0],e[i-1].y+e[i].y-a[1]];e[i-1].nextCtrlPoint=s,e[i].prevCtrlPoint=s,hn._stroke(t,n)}},n._quadraticCurve=function(t,e){if(e.length<=2)hn._path(t,e);else{var n,r;for(n=2,r=e.length;n<r;n+=2)t.quadraticCurveTo(e[n-1].x,e[n-1].y,e[n].x,e[n].y);if((n-=1)<r)for(;n<r;n++)t.lineTo(e[n].x,e[n].y)}},n._bezierCurve=function(t,e){if(e.length<=3)hn._path(t,e);else{var n,r;for(n=1,r=e.length;n+2<r;n+=3)t.bezierCurveTo(e[n].x,e[n].y,e[n+1].x,e[n+1].y,e[n+2].x,e[n+2].y);if(n<r)for(;n<r;n++)t.lineTo(e[n].x,e[n].y)}},n._getCurveArrowPoints=function(t,e,n,r,i,o){var a,s=e.length;for(a=o;a<s;a+=o){var u=this._getArrowShape(e[a-1],e[a],n,r,i);u&&t.push(u)}if((a-=o)<s-1)for(a+=1;a<s;a++){var c=this._getArrowShape(e[a-1],e[a],n,r,i);c&&t.push(c)}},e}(Ti);Fi.mergeOptions({enableSimplify:!1,enableClip:!1});var Bi=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n._toJSON=function(t){return{feature:this.toGeoJSON(t),subType:"ArcCurve"}},n._paintOn=function(t,e,n){t.beginPath(),this._arc(t,e,n),hn._stroke(t,n),this._paintArrow(t,e,n)},e.fromJSON=function(t){var n=t.feature,r=new e(n.geometry.coordinates,t.options);return r.setProperties(n.properties),r},e}(Fi);Bi.registerJSONType("ArcCurve"),Bi.mergeOptions({arcDegree:90});var Hi=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t),e.fromJSON=function(t){var n=t.feature,r=new e(n.geometry.coordinates,t.options);return r.setProperties(n.properties),r};var n=e.prototype;return n._toJSON=function(t){return{feature:this.toGeoJSON(t),subType:"CubicBezierCurve"}},n._paintOn=function(t,e,n){t.beginPath(),t.moveTo(e[0].x,e[0].y),this._bezierCurve(t,e),hn._stroke(t,n),this._paintArrow(t,e,n)},n._getArrowPoints=function(t,e,n,r,i){return this._getCurveArrowPoints(t,e,n,r,i,3)},e}(Fi);Hi.registerJSONType("CubicBezierCurve");var Gi=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t),e.fromJSON=function(t){var n=t.feature,r=new e(n.geometry.coordinates,t.options);return r.setProperties(n.properties),r};var n=e.prototype;return n._toJSON=function(t){return{feature:this.toGeoJSON(t),subType:"QuadBezierCurve"}},n._paintOn=function(t,e,n){t.beginPath(),t.moveTo(e[0].x,e[0].y),this._quadraticCurve(t,e,n),hn._stroke(t,n),this._paintArrow(t,e,n)},n._getArrowPoints=function(t,e,n,r,i){return this._getCurveArrowPoints(t,e,n,r,i,2)},e}(Fi);Gi.registerJSONType("QuadBezierCurve");var Ui={textFaceName:"monospace",textSize:12,textLineSpacing:8,textWrapCharacter:"\n",textHorizontalAlignment:"middle",textVerticalAlignment:"middle"},Wi={markerType:"square",markerLineColor:"#000",markerLineWidth:2,markerLineOpacity:1,markerFill:"#fff",markerOpacity:1},Vi=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.getContent=function(){return this._content},n.setContent=function(t){var e=this._content;return this._content=_e(t),this._refresh(),this._fireEvent("contentchange",{old:e,new:t}),this},n.onAdd=function(){this._refresh()},n.toJSON=function(){var e=t.prototype.toJSON.call(this);return delete e.symbol,e},n.setSymbol=function(e){if(this._refreshing||!e)return t.prototype.setSymbol.call(this,e);var n=this._parseSymbol(e);if(this.setTextStyle){var r=this.getTextStyle()||{};r.symbol=n[0],this.setTextStyle(r)}else this.setTextSymbol&&this.setTextSymbol(n[0]);if(this.setBoxStyle){var i=this.getBoxStyle()||{};i.symbol=n[1],this.setBoxStyle(i)}else this.setBoxSymbol&&this.setBoxSymbol(n[1]);return this},n._parseSymbol=function(t){var e={},n={};for(var r in t)b(t,r)&&(0===r.indexOf("text")?e[r]=t[r]:n[r]=t[r]);return[e,n]},n._getTextSize=function(t){return Pe(this._content,t).size},n._getInternalSymbol=function(){return this._symbol},n._getDefaultTextSymbol=function(){return d({},Ui)},n._getDefaultBoxSymbol=function(){return d({},Wi)},n._getDefaultPadding=function(){return[12,8]},e}(Mi),Zi=function(t){function e(e,n,r,i,o){var a;return void 0===o&&(o={}),(a=t.call(this,n,o)||this)._content=_e(e),a._width=p(r)?100:r,a._height=p(i)?40:i,o.boxSymbol&&a.setBoxSymbol(o.boxSymbol),o.textStyle&&a.setTextStyle(o.textStyle),a._refresh(),a}fe(e,t);var n=e.prototype;return n.getWidth=function(){return this._width},n.setWidth=function(t){return this._width=t,this._refresh(),this},n.getHeight=function(){return this._height},n.setHeight=function(t){return this._height=t,this._refresh(),this},n.getBoxSymbol=function(){return d({},this.options.boxSymbol)},n.setBoxSymbol=function(t){return this.options.boxSymbol=t?d({},t):t,this.getSymbol()&&this._refresh(),this},n.getTextStyle=function(){return this.options.textStyle?d({},this.options.textStyle):null},n.setTextStyle=function(t){return this.options.textStyle=t?d({},t):t,this.getSymbol()&&this._refresh(),this},e.fromJSON=function(t){var n=t.feature,r=new e(t.content,n.geometry.coordinates,t.width,t.height,t.options);return r.setProperties(n.properties),r.setId(n.id),t.symbol&&r.setSymbol(t.symbol),r},n._toJSON=function(t){return{feature:this.toGeoJSON(t),width:this.getWidth(),height:this.getHeight(),subType:"TextBox",content:this._content}},n._refresh=function(){var t=this.getTextStyle()||{},e=t.padding||[12,8],n=this._width-2*e[0],r=this._height-2*e[1],i=d({},t.symbol||this._getDefaultTextSymbol(),this.options.boxSymbol||this._getDefaultBoxSymbol(),{textName:this._content,markerWidth:this._width,markerHeight:this._height,textHorizontalAlignment:"middle",textVerticalAlignment:"middle",textMaxWidth:n,textMaxHeight:r});t.wrap&&!i.textWrapWidth&&(i.textWrapWidth=n);var o=t.horizontalAlignment;i.textDx=i.markerDx||0;var a=i.markerWidth/2-e[0];"left"===o?(i.textHorizontalAlignment="right",i.textDx=i.textDx-a):"right"===o&&(i.textHorizontalAlignment="left",i.textDx=i.textDx+a);var s=t.verticalAlignment;i.textDy=i.markerDy||0;var u=i.markerHeight/2-e[1];"top"===s?(i.textVerticalAlignment="bottom",i.textDy-=u):"bottom"===s&&(i.textVerticalAlignment="top",i.textDy+=u),this._refreshing=!0,this.updateSymbol(i),delete this._refreshing},e}(Vi);Zi.mergeOptions({textStyle:{wrap:!0,padding:[12,8],verticalAlignment:"middle",horizontalAlignment:"middle"},boxSymbol:null}),Zi.registerJSONType("TextBox");var qi=function(t){function e(e,n,r){var i;return void 0===r&&(r={}),i=t.call(this,n,r)||this,r.textSymbol&&i.setTextSymbol(r.textSymbol),r.boxStyle&&i.setBoxStyle(r.boxStyle),i._content=_e(e),i._refresh(),i}fe(e,t);var n=e.prototype;return n.getBoxStyle=function(){return this.options.boxStyle?d({},this.options.boxStyle):null},n.setBoxStyle=function(t){return this.options.boxStyle=t?d({},t):t,this._refresh(),this},n.getTextSymbol=function(){return d({},this._getDefaultTextSymbol(),this.options.textSymbol)},n.setTextSymbol=function(t){return this.options.textSymbol=t?d({},t):t,this._refresh(),this},e.fromJSON=function(t){var n=t.feature,r=new e(t.content,n.geometry.coordinates,t.options);return r.setProperties(n.properties),r.setId(n.id),t.symbol&&r.setSymbol(t.symbol),r},n._canEdit=function(){return!1},n._toJSON=function(t){return{feature:this.toGeoJSON(t),subType:"Label",content:this._content}},n._refresh=function(){var t=d({},this.getTextSymbol(),{textName:this._content}),e=this.getBoxStyle();if(e){d(t,e.symbol);var n=this._getBoxSize(t),r=n[1],i=e.padding||this._getDefaultPadding(),o=n[0];t.markerWidth=o.width,t.markerHeight=o.height;var a=t.textDx||0,s=t.textDy||0,u=Ae(r,t.textHorizontalAlignment,t.textVerticalAlignment)._add(a,s),c=e.horizontalAlignment||"middle";t.markerDx=u.x,"left"===c?t.markerDx+=t.markerWidth/2-i[0]:"right"===c?t.markerDx-=t.markerWidth/2-r.width-i[0]:t.markerDx+=r.width/2;var l=e.verticalAlignment||"middle";t.markerDy=u.y,"top"===l?t.markerDy+=t.markerHeight/2-i[1]:"bottom"===l?t.markerDy-=t.markerHeight/2-r.height-i[1]:t.markerDy+=r.height/2}this._refreshing=!0,this.updateSymbol(t),delete this._refreshing},n._getBoxSize=function(t){t.markerType||(t.markerType="square");var e,n,r=this.getBoxStyle(),i=this._getTextSize(t),o=r.padding||this._getDefaultPadding();return e=i.width+2*o[0],n=i.height+2*o[1],r.minWidth&&(!e||e<r.minWidth)&&(e=r.minWidth),r.minHeight&&(!n||n<r.minHeight)&&(n=r.minHeight),[new ge(e,n),i]},e}(Vi);qi.mergeOptions({boxStyle:null,textSymbol:null}),qi.registerJSONType("Label");var Yi=function(t){return function(t){function e(){return t.apply(this,arguments)||this}fe(e,t),e._hasConnectors=function(t){return!p(t.__connectors)&&t.__connectors.length>0},e._getConnectors=function(t){return t.__connectors};var n=e.prototype;return n.getConnectSource=function(){return this._connSource},n.setConnectSource=function(t){var e=this._connTarget;return this.onRemove(),this._connSource=t,this._connTarget=e,this.onAdd(),this},n.getConnectTarget=function(){return this._connTarget},n.setConnectTarget=function(t){var e=this._connSource;return this.onRemove(),this._connSource=e,this._connTarget=t,this._updateCoordinates(),this._registerEvents(),this},n._updateCoordinates=function(){var t=this.getMap();if(!t&&this._connSource&&(t=this._connSource.getMap()),!t&&this._connTarget&&(t=this._connTarget.getMap()),t&&this._connSource&&this._connTarget){for(var e,n,r=this._connSource._getConnectPoints(),i=this._connTarget._getConnectPoints(),o=0,a=this.getCoordinates(),s=0,u=r.length;s<u;s++)for(var c=r[s],l=0,h=i.length;l<h;l++){var f=i[l],d=t.computeLength(c,f);0===s&&0===l?(e=c,n=f,o=d):d<o&&(e=c,n=f)}U(a)&&a[0].equals(e)&&a[1].equals(n)||this.setCoordinates([e,n])}},n.onAdd=function(){this._registerEvents(),this._updateCoordinates()},n.onRemove=function(){if(this._connSource&&(this._connSource.__connectors&&D(this,this._connSource.__connectors),this._connSource.off("dragging positionchange",this._updateCoordinates,this).off("remove",this.onRemove,this),this._connSource.off("dragstart mousedown mouseover",this._showConnect,this),this._connSource.off("dragend mouseup mouseout",this.hide,this),this._connSource.off("show",this._showConnect,this).off("hide",this.hide,this),delete this._connSource),this._connTarget&&(D(this,this._connTarget.__connectors),this._connTarget.off("dragging positionchange",this._updateCoordinates,this).off("remove",this.onRemove,this),this._connTarget.off("show",this._showConnect,this).off("hide",this.hide,this),delete this._connTarget),!(this._connSource instanceof Kr&&this._connTarget instanceof Kr)){var t=this.getMap();t&&t.off("movestart moving moveend zoomstart zooming zoomend rotate pitch fovchange spatialreferencechange",this._updateCoordinates,this)}},n._showConnect=function(){this._connSource&&this._connTarget&&this._connSource.isVisible()&&this._connTarget.isVisible()&&(this._updateCoordinates(),this.show())},n._registerEvents=function(){if(this._connSource&&this._connTarget){this._connSource.__connectors||(this._connSource.__connectors=[]),this._connTarget.__connectors||(this._connTarget.__connectors=[]),this._connSource.__connectors.push(this),this._connTarget.__connectors.push(this),this._connSource.on("dragging positionchange",this._updateCoordinates,this).on("remove",this.remove,this),this._connTarget.on("dragging positionchange",this._updateCoordinates,this).on("remove",this.remove,this),this._connSource.on("show",this._showConnect,this).on("hide",this.hide,this),this._connTarget.on("show",this._showConnect,this).on("hide",this.hide,this);var t=this.options.showOn;if(this.hide(),"moving"===t?(this._connSource.on("dragstart",this._showConnect,this).on("dragend",this.hide,this),this._connTarget.on("dragstart",this._showConnect,this).on("dragend",this.hide,this)):"click"===t?(this._connSource.on("mousedown",this._showConnect,this).on("mouseup",this.hide,this),this._connTarget.on("mousedown",this._showConnect,this).on("mouseup",this.hide,this)):"mouseover"===t?(this._connSource.on("mouseover",this._showConnect,this).on("mouseout",this.hide,this),this._connTarget.on("mouseover",this._showConnect,this).on("mouseout",this.hide,this)):this._showConnect(),!(this._connSource instanceof Kr&&this._connTarget instanceof Kr)){var e=this.getMap();e&&e.on("movestart moving moveend zoomstart zooming zoomend rotate pitch fovchange spatialreferencechange",this._updateCoordinates,this)}}},e}(t)},Ji={showOn:"always"},Xi=function(t){function e(e,n,r){var i;return i=t.call(this,null,r)||this,1===arguments.length&&(r=e,e=null,n=null),i._connSource=e,i._connTarget=n,i}return fe(e,t),e}(Yi(Ti));Xi.mergeOptions(Ji),Xi.registerJSONType("ConnectorLine");var $i=function(t){function e(e,n,r){var i;return i=t.call(this,null,r)||this,1===arguments.length&&(r=e,e=null,n=null),i._connSource=e,i._connTarget=n,i}return fe(e,t),e}(Yi(Bi));$i.mergeOptions(Ji),$i.registerJSONType("ArcConnectorLine");var Qi=function(t){function e(e,n,r){var i;n&&!(n instanceof Kr)&&!Array.isArray(n)&&a.indexOf(n.type)<0&&(r=n,n=null),(i=t.call(this,e,r)||this)._maxZIndex=0,i._minZIndex=0,i._initCache(),n&&i.addGeometry(n);var o=i.options.style;return o&&i.setStyle(o),i}fe(e,t);var n=e.prototype;return n.getGeometryById=function(t){return p(t)||""===t?null:this._geoMap[t]?this._geoMap[t]:null},n.getGeometries=function(t,e){if(!t)return this._geoList.slice(0);for(var n,r=[],i=0,o=this._geoList.length;i<o;i++)n=this._geoList[i],(e?t.call(e,n):t(n))&&r.push(n);return r},n.getFirstGeometry=function(){return this._geoList.length?this._geoList[0]:null},n.getLastGeometry=function(){var t=this._geoList.length;return 0===t?null:this._geoList[t-1]},n.getCount=function(){return this._geoList.length},n.getExtent=function(){if(0===this.getCount())return null;var t=new Vn(this.getProjection());return this.forEach((function(e){t._combine(e.getExtent())})),t},n.forEach=function(t,e){for(var n=this._geoList.slice(0),r=0,i=n.length;r<i;r++)e?t.call(e,n[r],r):t(n[r],r);return this},n.filter=function(t,e){var n=[],r=_(t),i=r?t:rt(t);return this.forEach((function(t){var o=r?t:ft(t);(e?i.call(e,o):i(o))&&n.push(t)}),this),n},n.isEmpty=function(){return!this._geoList.length},n.addGeometry=function(t,e){if(!t)return this;if("FeatureCollection"===t.type)return this.addGeometry(Ii.toGeometry(t),e);if(!Array.isArray(t)){var n=arguments.length,r=arguments[n-1];return t=Array.prototype.slice.call(arguments,0,n-1),e=r,r&&v(r)&&("type"in r||r instanceof Kr)&&(t.push(r),e=!1),this.addGeometry(t,e)}if(0===t.length)return this;var i;this._initCache(),e&&(i=new Vn),this._toSort=this._maxZIndex>0;for(var o=[],a=0,s=t.length;a<s;a++){var u=t[a];if(!u)throw new Error("Invalid geometry to add to layer("+this.getId()+") at index:"+a);if(!(u instanceof Kr)&&(u=Kr.fromJSON(u),Array.isArray(u)))for(var c=0,l=u.length;c<l;c++)this._add(u[c],i,a),o.push(u[c]);Array.isArray(u)||(this._add(u,i,a),o.push(u))}var h=this.getMap();if(h&&(this._getRenderer().onGeometryAdd(o),i&&!p(i.xmin))){var f=i.getCenter(),m=h.getFitZoom(i);if(v(e)){var g=_(e.step)?e.step:function(){};h.animateTo({center:f,zoom:m},d({duration:h.options.zoomAnimationDuration,easing:"out"},e),g)}else!0===e&&h.setCenterAndZoom(f,m)}return this.fire("addgeo",{geometries:t}),this},n.getGeoMinZIndex=function(){return this._minZIndex},n.getGeoMaxZIndex=function(){return this._maxZIndex},n._add=function(t,e,n){this._toSort||(this._toSort=0!==t.getZIndex()),this._updateZIndex(t.getZIndex());var r=t.getId();if(!p(r)){if(!p(this._geoMap[r]))throw new Error("Duplicate geometry id in layer("+this.getId()+"):"+r+", at index:"+n);this._geoMap[r]=t}var i=O();t._setInternalId(i),this._geoList.push(t),this.onAddGeometry(t),t._bindLayer(this),t.onAdd&&t.onAdd(),e&&e._combine(t.getExtent()),t._fireEvent("add",{layer:this}),this._cookedStyles&&this._styleGeometry(t)},n.removeGeometry=function(t){if(!Array.isArray(t))return this.removeGeometry([t]);for(var e=t.length-1;e>=0;e--)t[e]instanceof Kr||(t[e]=this.getGeometryById(t[e])),t[e]&&this===t[e].getLayer()&&t[e].remove();return this.fire("removegeo",{geometries:t}),this},n.clear=function(){this._clearing=!0,this.forEach((function(t){t.remove()})),this._geoMap={};var t=this._geoList;return this._geoList=[],this._getRenderer()&&this._getRenderer().onGeometryRemove(t),this._clearing=!1,this.fire("clear"),this},n.onRemoveGeometry=function(t){if(t&&!this._clearing&&this===t.getLayer()&&!p(t._getInternalId())){var e=t.getId();p(e)||delete this._geoMap[e];var n=this._findInList(t);n>=0&&this._geoList.splice(n,1),this._getRenderer()&&this._getRenderer().onGeometryRemove([t])}},n.getStyle=function(){return this.options.style?this.options.style:null},n.setStyle=function(t){return this.options.style=t,t=jt(t),this._cookedStyles=dt(t),this.forEach((function(t){this._styleGeometry(t)}),this),this.fire("setstyle",{style:t}),this},n._styleGeometry=function(t){if(!this._cookedStyles)return!1;for(var e=ft(t),n=0,r=this._cookedStyles.length;n<r;n++)if(!0===this._cookedStyles[n].filter(e))return t._setExternSymbol(this._cookedStyles[n].symbol),!0;return!1},n.removeStyle=function(){return this.options.style?(delete this.options.style,delete this._cookedStyles,this.forEach((function(t){t._setExternSymbol(null)}),this),this.fire("removestyle"),this):this},n.onAddGeometry=function(t){this.getStyle()&&this._styleGeometry(t)},n.hide=function(){for(var t=0,e=this._geoList.length;t<e;t++)this._geoList[t].onHide();return ei.prototype.hide.call(this)},n._initCache=function(){this._geoList||(this._geoList=[],this._geoMap={})},n._updateZIndex=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];this._maxZIndex=Math.max(this._maxZIndex,Math.max.apply(Math,e)),this._minZIndex=Math.min(this._minZIndex,Math.min.apply(Math,e))},n._sortGeometries=function(){var t=this;this._toSort&&(this._maxZIndex=0,this._minZIndex=0,this._geoList.sort((function(e,n){return t._updateZIndex(e.getZIndex(),n.getZIndex()),t._compare(e,n)})),this._toSort=!1)},n._compare=function(t,e){return t.getZIndex()===e.getZIndex()?t._getInternalId()-e._getInternalId():t.getZIndex()-e.getZIndex()},n._findInList=function(t){var e=this._geoList.length;if(0===e)return-1;this._sortGeometries();for(var n,r=0,i=e-1;r<=i;){if(n=Math.floor((r+i)/2),this._geoList[n]===t)return n;this._compare(this._geoList[n],t)>0?i=n-1:r=n+1}return-1},n._onGeometryEvent=function(t){if(t&&t.target){var e=t.type;"idchange"===e?this._onGeometryIdChange(t):"zindexchange"===e?this._onGeometryZIndexChange(t):"positionchange"===e?this._onGeometryPositionChange(t):"shapechange"===e?this._onGeometryShapeChange(t):"symbolchange"===e?this._onGeometrySymbolChange(t):"show"===e?this._onGeometryShow(t):"hide"===e?this._onGeometryHide(t):"propertieschange"===e&&this._onGeometryPropertiesChange(t)}},n._onGeometryIdChange=function(t){if(t.new!==t.old||!this._geoMap[t.old]||this._geoMap[t.old]!==t.target){if(!p(t.new)){if(this._geoMap[t.new])throw new Error("Duplicate geometry id in layer("+this.getId()+"):"+t.new);this._geoMap[t.new]=t.target}p(t.old)||t.new===t.old||delete this._geoMap[t.old]}},n._onGeometryZIndexChange=function(t){t.old!==t.new&&(this._updateZIndex(t.new),this._toSort=!0,this._getRenderer()&&this._getRenderer().onGeometryZIndexChange(t))},n._onGeometryPositionChange=function(t){this._getRenderer()&&this._getRenderer().onGeometryPositionChange(t)},n._onGeometryShapeChange=function(t){this._getRenderer()&&this._getRenderer().onGeometryShapeChange(t)},n._onGeometrySymbolChange=function(t){this._getRenderer()&&this._getRenderer().onGeometrySymbolChange(t)},n._onGeometryShow=function(t){this._getRenderer()&&this._getRenderer().onGeometryShow(t)},n._onGeometryHide=function(t){this._getRenderer()&&this._getRenderer().onGeometryHide(t)},n._onGeometryPropertiesChange=function(t){this._getRenderer()&&this._getRenderer().onGeometryPropertiesChange(t)},e}(ei);Qi.mergeOptions({drawImmediate:!1});var Ki=new Zn,to={debug:!1,enableSimplify:!0,geometryEvents:!0,defaultIconSize:[20,20],cacheVectorOnCanvas:!0,cacheSvgOnCanvas:he.gecko,enableAltitude:!1,altitudeProperty:"altitude",drawAltitude:!1,altitude:0},eo=function(t){function e(e,n,r){return t.call(this,e,n,r)||this}fe(e,t);var n=e.prototype;return n.onConfig=function(e){if(t.prototype.onConfig.call(this,e),e.enableAltitude||e.drawAltitude||e.altitudeProperty){var n=this.getRenderer();n&&n.setToRedraw&&n.setToRedraw()}},n.identify=function(t,e){void 0===e&&(e={});var n=this.getRenderer();return e.onlyVisible&&n&&n.identify?n.identify(t,e):(t instanceof On||(t=new On(t)),this._hitGeos(this._geoList,t,e))},n._hitGeos=function(t,e,n){void 0===n&&(n={});for(var r=n.filter,i=n.tolerance,o=[],a=this.getMap(),s=a.coordToPoint(e),u=a._pointToContainerPoint(s,void 0,0,s),c=t.length-1;c>=0;c--){var l=t[c];if(l&&l.isVisible()&&l._getPainter()&&l.options.interactive){if(!(l instanceof Ti&&(l._getArrowStyle()||l instanceof Fi))){var h=l.getContainerExtent(Ki);if(i&&(h=h._expand(i)),!h||!h.contains(u))continue}if(l._containsPoint(u,i)&&(!r||r(l))&&(o.push(l),n.count&&o.length>=n.count))break}}return o},n.getAltitude=function(){return this.options.altitude||0},n.toJSON=function(t){t||(t={});var e={type:this.getJSONType(),id:this.getId(),options:this.config()};if(p(t.geometries)||t.geometries){var n;if(t.clipExtent){var r=this.getMap(),i=r?r.getProjection():null;n=new Vn(t.clipExtent,i)}for(var o=[],a=this.getGeometries(),s=0,u=a.length;s<u;s++){var c=a[s],l=c.getExtent();if(l&&(!n||n.intersects(l))){var h=c.toJSON(t.geometries);o.push(h)}}e.geometries=o}return e},e.fromJSON=function(t){if(!t||"VectorLayer"!==t.type)return null;for(var n=new e(t.id,t.options),r=t.geometries,i=[],o=0;o<r.length;o++){var a=Kr.fromJSON(r[o]);a&&i.push(a)}return n.addGeometry(i),n},e.getPainterClass=function(){return Yr},e.getCollectionPainterClass=function(){return Xr},e}(Qi);eo.mergeOptions(to),eo.registerJSONType("VectorLayer");var no="_map_tool",ro=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.addTo=function(t){return t?(this._map=t,t[no]&&t[no].disable(),this.onAdd&&this.onAdd(),this.enable(),t[no]=this,this._fireEvent("add"),this):this},n.getMap=function(){return this._map},n.enable=function(){return!this._map||this._enabled||(this._enabled=!0,this._switchEvents("off"),this._registerEvents(),this.onEnable&&this.onEnable(),this._fireEvent("enable")),this},n.disable=function(){return this._enabled&&this._map?(this._enabled=!1,this._switchEvents("off"),this.onDisable&&this.onDisable(),this._fireEvent("disable"),this):this},n.isEnabled=function(){return!!this._enabled},n.remove=function(){return this._map?(this.disable(),this._map&&(delete this._map[no],delete this._map),this._fireEvent("remove"),this):this},n._registerEvents=function(){this._switchEvents("on")},n._switchEvents=function(t){var e=this.getEvents();e&&this._map[t](e,this)},n._fireEvent=function(t,e){e||(e={}),this.fire(t,e)},e}(xn(Mn)),io={},oo=function(t){function e(e){var n;return(n=t.call(this,e)||this)._checkMode(),n._events={click:n._clickHandler,mousemove:n._mouseMoveHandler,dblclick:n._doubleClickHandler,mousedown:n._mouseDownHandler,mouseup:n._mouseUpHandler},n}fe(e,t),e.registerMode=function(t,e){io[t.toLowerCase()]=e},e.getRegisterMode=function(t){return io[t.toLowerCase()]};var n=e.prototype;return n.getMode=function(){return this.options.mode?this.options.mode.toLowerCase():null},n.setMode=function(t){return this._geometry&&(this._geometry.remove(),delete this._geometry),this._clearStage(),this._switchEvents("off"),this.options.mode=t,this._checkMode(),this.isEnabled()&&(this._switchEvents("on"),this._restoreMapCfg(),this._saveMapCfg()),this},n.getSymbol=function(){return Dt(this.options.symbol||this.options.symbol)},n.setSymbol=function(t){return t?(this.options.symbol=t,this._geometry&&this._geometry.setSymbol(t),this):this},n.getCurrentGeometry=function(){return this._geometry},n.onAdd=function(){this._checkMode()},n.onEnable=function(){if(this._saveMapCfg(),this._drawToolLayer=this._getDrawLayer(),this._clearStage(),this._loadResources(),this.options.autoPanAtEdge){var t=this.getMap();this._mapAutoPanAtEdge=t.options.autoPanAtEdge,this._mapAutoPanAtEdge||t.config({autoPanAtEdge:!0})}return this},n.onDisable=function(){var t=this.getMap();return this._restoreMapCfg(),this.endDraw(),this._map&&(t.removeLayer(this._getDrawLayer()),this.options.autoPanAtEdge&&(this._mapAutoPanAtEdge||t.config({autoPanAtEdge:!1}))),this},n.undo=function(){var t=this._getRegisterMode(),e=t.action;if(!this._shouldRecordHistory(e)||!this._historyPointer)return this;var n=this._clickCoords.slice(0,--this._historyPointer);return t.update(this.getMap().getProjection(),n,this._geometry),this},n.redo=function(){var t=this._getRegisterMode(),e=t.action;if(!this._shouldRecordHistory(e)||p(this._historyPointer)||this._historyPointer===this._clickCoords.length)return this;var n=this._clickCoords.slice(0,++this._historyPointer);return t.update(this.getMap().getProjection(),n,this._geometry),this},n._shouldRecordHistory=function(t){return Array.isArray(t)&&"click"===t[0]&&"mousemove"===t[1]&&"dblclick"===t[2]},n._checkMode=function(){this._getRegisterMode()},n._saveMapCfg=function(){var t=this.getMap();if(this._mapDoubleClickZoom=t.options.doubleClickZoom,t.config({doubleClickZoom:this.options.doubleClickZoom}),this._getRegisterMode().action.indexOf("mousedown")>-1){var e=this.getMap();this._mapDraggable=e.options.draggable,e.config({draggable:!1})}},n._restoreMapCfg=function(){var t=this.getMap();t.config({doubleClickZoom:this._mapDoubleClickZoom}),p(this._mapDraggable)||t.config("draggable",this._mapDraggable),delete this._mapDraggable,delete this._mapDoubleClickZoom},n._loadResources=function(){var t=Pt(this.getSymbol());t.length>0&&this._drawToolLayer._getRenderer().loadResources(t)},n._getProjection=function(){return this._map.getProjection()},n._getRegisterMode=function(){var t=this.getMode(),n=e.getRegisterMode(t);if(!n)throw new Error(t+" is not a valid mode of DrawTool.");return n},n.getEvents=function(){var t=this._getRegisterMode().action,e={};if(Array.isArray(t)){for(var n=0;n<t.length;n++)e[t[n]]=this._events[t[n]];return e}return null},n._mouseDownHandler=function(t){this._createGeometry(t)},n._mouseUpHandler=function(t){this.endDraw(t)},n._clickHandler=function(t){var e=this._getRegisterMode();if(this._geometry){var n=this.getMap()._pointToPrj(t.point2d);p(this._historyPointer)||(this._clickCoords=this._clickCoords.slice(0,this._historyPointer)),this._clickCoords.push(n),this._historyPointer=this._clickCoords.length,t.drawTool=this,e.update(this.getMap().getProjection(),this._clickCoords,this._geometry,t),this._fireEvent("drawvertex",t),e.clickLimit&&e.clickLimit===this._historyPointer&&this.endDraw(t)}else this._createGeometry(t)},n._createGeometry=function(t){var e=this.getMode(),n=this._getRegisterMode(),r=this.getMap()._pointToPrj(t.point2d),i=this.getSymbol();this._geometry||(this._clickCoords=[r],t.drawTool=this,this._geometry=n.create(this.getMap().getProjection(),this._clickCoords,t),i&&"point"!==e?this._geometry.setSymbol(i):this.options.hasOwnProperty("symbol")&&this._geometry.setSymbol(this.options.symbol),this._addGeometryToStage(this._geometry),this._fireEvent("drawstart",t)),"point"===e&&this.endDraw(t)},n._mouseMoveHandler=function(t){var e=this.getMap();if(this._geometry&&e&&!e.isInteracting()){var n=this._getMouseContainerPoint(t);if(this._isValidContainerPoint(n)){var r=this.getMap()._pointToPrj(t.point2d),i=e.getProjection();t.drawTool=this;var o=this._getRegisterMode();if(this._shouldRecordHistory(o.action)){var a=this._clickCoords.slice(0,this._historyPointer);if(a&&a.length>0&&r.equals(a[a.length-1]))return;o.update(i,a.concat([r]),this._geometry,t)}else o.update(i,r,this._geometry,t);this._fireEvent("mousemove",t)}}},n._doubleClickHandler=function(t){if(this._geometry){var e=this._getMouseContainerPoint(t);if(this._isValidContainerPoint(e)){var n=this._getRegisterMode(),r=this._clickCoords;if(!(r.length<2)){for(var i=this.getMap().getProjection(),o=[r[0]],a=1,s=r.length;a<s;a++)r[a].x===r[a-1].x&&r[a].y===r[a-1].y||o.push(r[a]);o.length<2||this._geometry&&this._geometry instanceof bi&&o.length<3||(t.drawTool=this,n.update(i,o,this._geometry,t),this.endDraw(t))}}}},n._addGeometryToStage=function(t){this._getDrawLayer().addGeometry(t)},n.endDraw=function(t){if(!this._geometry||this._ending)return this;this._ending=!0;var e=this._geometry;return this._clearStage(),t=t||{},this._geometry=e,this._fireEvent("drawend",t),delete this._geometry,this.options.once&&this.disable(),delete this._ending,delete this._historyPointer,this},n._clearStage=function(){this._getDrawLayer().clear(),delete this._geometry,delete this._clickCoords},n._getMouseContainerPoint=function(t){return"mousedown"===this._getRegisterMode().action&&Ue(t.domEvent),t.containerPoint},n._isValidContainerPoint=function(t){var e=this._map.getSize(),n=e.width,r=e.height;return!(t.x<0||t.y<0||t.x>n||t.y>r)},n._getDrawLayer=function(){var t=i+"drawtool",e=this._map.getLayer(t);return e||(e=new eo(t,{enableSimplify:!1}),this._map.addLayer(e)),e},n._fireEvent=function(t,e){e||(e={}),this._geometry&&(e.geometry=this._getRegisterMode().generate(this._geometry,{drawTool:this})),ro.prototype._fireEvent.call(this,t,e)},e}(ro);oo.mergeOptions({symbol:{lineColor:"#000",lineWidth:2,lineOpacity:1,polygonFill:"#fff",polygonOpacity:.3},doubleClickZoom:!1,mode:null,once:!1,autoPanAtEdge:!1,ignoreMouseleave:!0});var ao=function(t){function e(e){var n;return(n=t.call(this,e)||this).drawTool=new oo({mode:"boxZoom",ignoreMouseleave:!1}),n}fe(e,t);var n=e.prototype;return n.addHooks=function(){this.target.on("_mousedown",this._onMouseDown,this)},n.removeHooks=function(){this.target.off("_mousedown",this._onMouseDown,this),this.drawTool.isEnabled()&&this.drawTool.remove()},n._onMouseDown=function(t){this.target.options.boxZoom&&t.domEvent.shiftKey&&this.drawTool.setSymbol(this.target.options.boxZoomSymbol).on("drawend",this._boxZoom,this).addTo(this.target)},n._boxZoom=function(t){var e=this.target;this.drawTool.remove();var n=t.geometry,r=n.getCenter(),i=n.getSymbol(),o=i.markerWidth,a=i.markerHeight,s=new Vn(r,e.locateByPoint(r,o,a),e.getProjection()),u=e.getFitZoom(s);e._animateTo({center:s.getCenter(),zoom:u})},e}(wn);ii.mergeOptions({boxZoom:!0,boxZoomSymbol:{markerType:"rectangle",markerLineWidth:3,markerLineColor:"#1bbc9b",markerLineDasharray:[10,5],markerFillOpacity:.1,markerFill:"#1bbc9b",markerWidth:1,markerHeight:1}}),ii.addOnLoadHook("addHandler","boxZoom",ao);var so=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.addHooks=function(){this.target&&this.target.on("_mousemove",this._onMouseMove,this)},n.removeHooks=function(){this.target&&this.target.off("_mousemove",this._onMouseMove,this)},n._onMouseMove=function(t){var e=this.target;if(e.options.autoPanAtEdge){var n=t.containerPoint,r=e.getContainerExtent();if(r){var i,o=n.x,a=n.y,s=r.xmax,u=r.ymax;o<30&&(i=[Math.abs(o-30),0]),a<30&&(i=[0,Math.abs(a-30)]),o+30>s&&(i=[-Math.abs(o+30-s),0]),a+30>u&&(i=[0,-Math.abs(a+30-u)]),i&&e.panBy(i,{duration:1})}}},e}(wn);ii.mergeOptions({autoPanAtEdge:!1}),ii.addOnLoadHook("addHandler","autoPanAtEdge",so),ii.include({animateTo:function(t,e,n){var r=this;void 0===e&&(e={}),_(e)&&(n=e,e={});var i=this.getProjection(),o=this.getView(),a={},s=!0;for(var u in t)if(b(t,u)&&!p(t[u])&&("prjCenter"===u||!p(o[u])))if(s=!1,"center"===u){var c=new On(o[u]).toFixed(7),l=new On(t[u]).toFixed(7);c.equals(l)||(a.center=[c,l])}else if("prjCenter"===u){var h=new On(this._getPrjCenter()),f=new On(t[u]);h.equals(f)||(a.prjCenter=[h,f])}else o[u]!==t[u]&&"around"!==u&&(a[u]=[o[u],t[u]]);if(s)return null;this._animPlayer&&(this._isInternalAnimation?"running"===this._animPlayer.playState&&(this._animPlayer.pause(),this._prevAnimPlayer=this._animPlayer):(delete this._prevAnimPlayer,this._stopAnim(this._animPlayer)));var d=t.around||new me(this.width/2,this.height/2),m=this._getRenderer(),g=this._animPlayer=gi.animate(a,{easing:e.easing||"out",duration:e.duration||this.options.zoomAnimationDuration,framer:function(t){m.callInNextFrame(t)}},(function(t){if(r.isRemoved())g.finish();else{if("running"===g.playState){if(t.styles.center){var o=t.styles.center;r._setPrjCenter(i.project(o)),r.onMoving(r._parseEventFromCoord(r.getCenter()))}else if(t.styles.prjCenter){var s=t.styles.prjCenter;r._setPrjCenter(s),r.onMoving(r._parseEventFromCoord(r.getCenter()))}p(t.styles.zoom)||r.onZooming(t.styles.zoom,d),p(t.styles.pitch)||r.setPitch(t.styles.pitch),p(t.styles.bearing)||r.setBearing(t.styles.bearing),r._fireEvent("animating")}else"paused"===g.playState&&g!==r._mapAnimPlayer||(g._interupted||(a.center?r._setPrjCenter(i.project(a.center[1])):a.prjCenter&&r._setPrjCenter(a.prjCenter[1]),p(a.pitch)||r.setPitch(a.pitch[1]),p(a.bearing)||r.setBearing(a.bearing[1])),r._endAnim(g,a,d,e));n&&n(t)}}),this);return this._startAnim(a,d),g},_animateTo:function(t,e,n){return void 0===e&&(e={}),this._mapAnimPlayer&&this._stopAnim(this._mapAnimPlayer),this._isInternalAnimation=!0,this._mapAnimPlayer=this.animateTo(t,e,n),delete this._isInternalAnimation,this._mapAnimPlayer},isAnimating:function(){return!!this._animPlayer},isRotating:function(){return this.isDragRotating()||!!this._animRotating},_endAnim:function(t,e,n,r){delete this._animRotating;var i,o=t._interupted?"animateinterrupted":"animateend";if(t===this._animPlayer&&delete this._animPlayer,t===this._mapAnimPlayer&&delete this._mapAnimPlayer,e.center)i=t._interupted?this.getCenter():e.center[1],this.onMoveEnd(this._parseEventFromCoord(i));else if(e.prjCenter){var a;a=t._interupted?this._getPrjCenter():e.prjCenter[1];var s=this._parseEventFromCoord(this.getProjection().unproject(a));s.point2d=this._prjToPoint(a),this.onMoveEnd(s)}p(e.zoom)||(t._interupted?this.onZoomEnd(this.getZoom(),n):r.wheelZoom?this.onZooming(e.zoom[1],n):this.onZoomEnd(e.zoom[1],n)),o&&this._fireEvent(o),p(e.pitch)||this.getPitch()||this.getRenderer().setToRedraw(),this._resumePrev(t)},_startAnim:function(t,e){this._animPlayer&&(t.center&&this.onMoveStart(),t.zoom&&!this.isZooming()&&this.onZoomStart(t.zoom[1],e),(t.pitch||t.bearing)&&(this._animRotating=!0),this._fireEvent("animatestart"),this._animPlayer.play())},_stopAnim:function(t){t&&(delete this._animRotating,"finished"!==t.playState&&(t._interupted=!0,t.cancel()),t===this._animPlayer&&delete this._animPlayer,t===this._mapAnimPlayer&&delete this._mapAnimPlayer)},_resumePrev:function(t){if(this._prevAnimPlayer){var e=this._prevAnimPlayer;"paused"!==e.playState&&delete this._prevAnimPlayer,t!==e&&(this._animPlayer=e,e.play())}}});var uo="mousedown mouseup mouseover mouseout mouseenter mouseleave mousemove click dblclick contextmenu keypress touchstart touchmove touchend ";function co(t,e,n,r,i){var o=1/Math.tan(e/2),a=1/(r-i);return t[0]=o/n,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=o,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=(i+r)*a,t[11]=-1,t[12]=0,t[13]=0,t[14]=2*i*r*a,t[15]=0,t}function lo(t,e,n){var r,i,o,a,s,u,c,l,h,f,d,p,m=n[0],g=n[1],v=n[2];return e===t?(t[12]=e[0]*m+e[4]*g+e[8]*v+e[12],t[13]=e[1]*m+e[5]*g+e[9]*v+e[13],t[14]=e[2]*m+e[6]*g+e[10]*v+e[14],t[15]=e[3]*m+e[7]*g+e[11]*v+e[15]):(r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],c=e[6],l=e[7],h=e[8],f=e[9],d=e[10],p=e[11],t[0]=r,t[1]=i,t[2]=o,t[3]=a,t[4]=s,t[5]=u,t[6]=c,t[7]=l,t[8]=h,t[9]=f,t[10]=d,t[11]=p,t[12]=r*m+s*g+h*v+e[12],t[13]=i*m+u*g+f*v+e[13],t[14]=o*m+c*g+d*v+e[14],t[15]=a*m+l*g+p*v+e[15]),t}function ho(t,e,n){var r=n[0],i=n[1],o=n[2];return t[0]=e[0]*r,t[1]=e[1]*r,t[2]=e[2]*r,t[3]=e[3]*r,t[4]=e[4]*i,t[5]=e[5]*i,t[6]=e[6]*i,t[7]=e[7]*i,t[8]=e[8]*o,t[9]=e[9]*o,t[10]=e[10]*o,t[11]=e[11]*o,t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}function fo(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],c=e[6],l=e[7],h=e[8],f=e[9],d=e[10],p=e[11],m=e[12],g=e[13],v=e[14],y=e[15],_=n[0],x=n[1],b=n[2],w=n[3];return t[0]=_*r+x*s+b*h+w*m,t[1]=_*i+x*u+b*f+w*g,t[2]=_*o+x*c+b*d+w*v,t[3]=_*a+x*l+b*p+w*y,_=n[4],x=n[5],b=n[6],w=n[7],t[4]=_*r+x*s+b*h+w*m,t[5]=_*i+x*u+b*f+w*g,t[6]=_*o+x*c+b*d+w*v,t[7]=_*a+x*l+b*p+w*y,_=n[8],x=n[9],b=n[10],w=n[11],t[8]=_*r+x*s+b*h+w*m,t[9]=_*i+x*u+b*f+w*g,t[10]=_*o+x*c+b*d+w*v,t[11]=_*a+x*l+b*p+w*y,_=n[12],x=n[13],b=n[14],w=n[15],t[12]=_*r+x*s+b*h+w*m,t[13]=_*i+x*u+b*f+w*g,t[14]=_*o+x*c+b*d+w*v,t[15]=_*a+x*l+b*p+w*y,t}function po(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],c=e[7],l=e[8],h=e[9],f=e[10],d=e[11],p=e[12],m=e[13],g=e[14],v=e[15],y=n*s-r*a,_=n*u-i*a,x=n*c-o*a,b=r*u-i*s,w=r*c-o*s,M=i*c-o*u,S=l*m-h*p,T=l*g-f*p,E=l*v-d*p,A=h*g-f*m,C=h*v-d*m,P=f*v-d*g,L=y*P-_*C+x*A+b*E-w*T+M*S;return L?(L=1/L,t[0]=(s*P-u*C+c*A)*L,t[1]=(i*C-r*P-o*A)*L,t[2]=(m*M-g*w+v*b)*L,t[3]=(f*w-h*M-d*b)*L,t[4]=(u*E-a*P-c*T)*L,t[5]=(n*P-i*E+o*T)*L,t[6]=(g*x-p*M-v*_)*L,t[7]=(l*M-f*x+d*_)*L,t[8]=(a*C-s*E+c*S)*L,t[9]=(r*E-n*C-o*S)*L,t[10]=(p*w-m*x+v*y)*L,t[11]=(h*x-l*w-d*y)*L,t[12]=(s*T-a*A-u*S)*L,t[13]=(n*A-r*T+i*S)*L,t[14]=(m*_-p*b-g*y)*L,t[15]=(l*b-h*_+f*y)*L,t):null}function mo(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function go(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}function vo(t,e,n,r){return t[0]=e,t[1]=n,t[2]=r,t}function yo(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t}function _o(t){var e=t[0],n=t[1],r=t[2];return Math.sqrt(e*e+n*n+r*r)}function xo(t,e){var n=e[0],r=e[1],i=e[2],o=n*n+r*r+i*i;return o>0&&(o=1/Math.sqrt(o),t[0]=e[0]*o,t[1]=e[1]*o,t[2]=e[2]*o),t}function bo(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[0],s=n[1],u=n[2];return t[0]=i*u-o*s,t[1]=o*a-r*u,t[2]=r*s-i*a,t}function wo(t,e){var n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2];return Math.hypot?Math.hypot(n,r,i):function(){for(var t=0,e=arguments.length;e--;)t+=arguments[e]*arguments[e];return Math.sqrt(t)}(n,r,i)}function Mo(t,e,n){var r=e[0],i=e[1],o=e[2],a=1/(n[3]*r+n[7]*i+n[11]*o+n[15]);return t[0]=(n[0]*r+n[4]*i+n[8]*o+n[12])*a,t[1]=(n[1]*r+n[5]*i+n[9]*o+n[13])*a,t[2]=(n[2]*r+n[6]*i+n[10]*o+n[14])*a,t}ii.include({_registerDomEvents:function(){Fe(this._panels.mapWrapper||this._containerDOM,uo,this._handleDOMEvent,this)},_removeDomEvents:function(){Be(this._panels.mapWrapper||this._containerDOM,uo,this._handleDOMEvent)},_handleDOMEvent:function(t){var e=t.type;if("contextmenu"===e&&Ge(t),!this._ignoreEvent(t)){var n=!1;if("mousedown"===e||"touchstart"===e&&1===t.touches.length)this._mouseDownTime=f();else if("click"===e||"touchend"===e||"contextmenu"===e){if(!this._mouseDownTime)return;var r=this._mouseDownTime;if(delete this._mouseDownTime,f()-r>300){if("click"===e||"contextmenu"===e)return}else"touchend"===e&&(n=!0)}this._fireDOMEvent(this,t,e),n&&(this._clickTime&&f()-this._clickTime<=300?(delete this._clickTime,this._fireDOMEvent(this,t,"dblclick")):(this._clickTime=f(),this._fireDOMEvent(this,t,"click")))}},_ignoreEvent:function(t){if(!t||!this._panels.control)return!1;if(this._isEventOutMap(t))return!0;var e,n=t.srcElement||t.target;if(n)for(;n&&n!==this._containerDOM;){if(n.className&&n.className.indexOf&&(n.className.indexOf("maptalks-control")>=0||n.className.indexOf("maptalks-ui")>=0&&!e.eventsPropagation))return!0;e=n,n=n.parentNode}return!1},_isEventOutMap:function(t){if(this.getPitch()>this.options.maxVisualPitch){var e=qe(this._getActualEvent(t),this._containerDOM);if(!this.getContainerExtent().contains(e))return!0}return!1},_parseEvent:function(t,e){if(!t)return null;var n={domEvent:t};if("keypress"!==e){var r=this._getActualEvent(t);if(r){var i=qe(r,this._containerDOM);n=d(n,{coordinate:this.containerPointToCoord(i),containerPoint:i,viewPoint:this.containerPointToViewPoint(i),point2d:this._containerPointToPoint(i)})}}return n},_parseEventFromCoord:function(t){var e=this.coordToContainerPoint(t);return{coordinate:t,containerPoint:e,viewPoint:this.containerPointToViewPoint(e),point2d:this.coordToPoint(t)}},_getActualEvent:function(t){return t.touches&&t.touches.length>0?t.touches[0]:t.changedTouches&&t.changedTouches.length>0?t.changedTouches[0]:t},_fireDOMEvent:function(t,e,n){if(!this.isRemoved()){var r=this._parseEvent(e,n);this._fireEvent(n,r)}}}),ii.addOnLoadHook("_registerDomEvents"),ii.include({isFullScreen:function(){return!!(document.webkitIsFullScreen||document.mozFullScreen||document.msFullscreenElement||document.fullscreenElement)},requestFullScreen:function(t){return this._fireEvent("fullscreenstart"),this._requestFullScreen(t||this._containerDOM),this._fireEvent("fullscreenend"),this},cancelFullScreen:function(){return this._cancelFullScreen(),this._fireEvent("cancelfullscreen"),this},_requestFullScreen:function(t){if(t.requestFullscreen)t.requestFullscreen();else if(t.mozRequestFullScreen)t.mozRequestFullScreen();else if(t.webkitRequestFullScreen)t.webkitRequestFullScreen();else if(t.msRequestFullScreen)t.msRequestFullScreen();else{var e="fullscreen=1,status=no,resizable=yes,top=0,left=0,scrollbars=no,titlebar=no,menubar=no,location=no,toolbar=no,z-look=yes,width="+(screen.availWidth-8)+",height="+(screen.availHeight-45);null!==window.open(location.href,"_blank",e)&&(window.opener=null,window.close())}},_cancelFullScreen:function(){document.exitFullscreen?document.exitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitCancelFullScreen?document.webkitCancelFullScreen():null!==window.open(location.href,"_blank","fullscreen=no,status=yes,resizable=yes,scrollbars=no,titlebar=no,menubar=yes,location=yes,toolbar=yes,z-look=yes")&&(window.opener=null,window.close())}}),ii.include({panTo:function(t,e,n){if(void 0===e&&(e={}),!t)return this;if(_(e)&&(n=e,e={}),t=new On(t),void 0===e.animation||e.animation){var r=this.getProjection().project(t);return this._panAnimation(r,e.duration,n)}return this.setCenter(t),this},_panTo:function(t,e){return void 0===e&&(e={}),void 0===e.animation||e.animation?this._panAnimation(t,e.duration):(this.onMoveStart(),this._setPrjCenter(t),this.onMoveEnd(this._parseEventFromCoord(this.getCenter())),this)},panBy:function(t,e,n){if(void 0===e&&(e={}),!t)return this;if(_(e)&&(n=e,e={}),t=new me(t),this.getContainerExtent().ymin>0&&t.y>30){var r=t.y;t.y=30,t.x=30*t.x/r,console.warn("offset is limited to panBy when pitch is above maxPitch")}if(this.onMoveStart(),void 0===e.animation||e.animation){t=t.multi(-1);var i=this._containerPointToPrj(new me(this.width/2+t.x,this.height/2+t.y));this._panAnimation(i,e.duration,n)}else this._offsetCenterByPixel(t),this.onMoveEnd(this._parseEventFromCoord(this.getCenter()));return this},_panAnimation:function(t,e,n){return this._animateTo({prjCenter:t},{duration:e||this.options.panAnimationDuration},n)}}),Kr.fromJSON=function(t){if(Array.isArray(t)){for(var e=[],n=0,r=t.length;n<r;n++){var i=Kr.fromJSON(t[n]);Array.isArray(t)?e=e.concat(i):e.push(i)}return e}return t&&!t.feature?Ii.toGeometry(t):(t.subType?(o=Kr.getJSONClass(t.subType).fromJSON(t),p(t.feature.id)||o.setId(t.feature.id)):(o=Ii.toGeometry(t.feature),t.options&&o.config(t.options)),t.symbol&&o.setSymbol(t.symbol),t.infoWindow&&o.setInfoWindow(t.infoWindow),o);var o},ei.fromJSON=function(t){if(!t)return null;var e=t.type,n=ei.getJSONClass(e);if(!n||!n.fromJSON)throw new Error("unsupported layer type:"+e);return n.fromJSON(t)},ii.include({JSON_VERSION:"1.0",toJSON:function(t){t||(t={});var e={jsonVersion:this.JSON_VERSION,version:this.VERSION,extent:this.getExtent().toJSON()};e.options=this.config(),e.options.center=this.getCenter(),e.options.zoom=this.getZoom(),e.options.bearing=this.getBearing(),e.options.pitch=this.getPitch();var n=this.getBaseLayer();(p(t.baseLayer)||t.baseLayer)&&n&&(e.baseLayer=n.toJSON(t.baseLayer));var r={};t.clipExtent&&(!0===t.clipExtent?r.clipExtent=this.getExtent():r.clipExtent=t.clipExtent);var i=[];if(p(t.layers)||t.layers&&!Array.isArray(t.layers)){for(var o=this.getLayers(),a=0,s=o.length;a<s;a++)if(o[a].toJSON){var u=d({},v(t.layers)?t.layers:{},r);i.push(o[a].toJSON(u))}e.layers=i}else if(U(t.layers)){for(var c=t.layers,l=0;l<c.length;l++){var h=c[l],f=this.getLayer(h.id);if(f.toJSON){var m=d({},h.options,r);i.push(f.toJSON(m))}}e.layers=i}else e.layers=[];return e}}),ii.fromJSON=function(t,e,n){if(!t||!e)return null;n||(n={});var r=new ii(t,e.options);if(p(n.baseLayer)||n.baseLayer){var i=ei.fromJSON(e.baseLayer);i&&r.setBaseLayer(i)}if(p(n.layers)||n.layers){for(var o=[],a=e.layers,s=0;s<a.length;s++){var u=ei.fromJSON(a[s]);o.push(u)}r.addLayer(o)}return r},ii.include({computeLength:function(t,e){if(!this.getProjection())return null;var n=new On(t),r=new On(e);return n.equals(r)?0:this.getProjection().measureLength(n,r)},computeGeometryLength:function(t){return t._computeGeodesicLength(this.getProjection())},computeGeometryArea:function(t){return t._computeGeodesicArea(this.getProjection())},identify:function(t,e){if(!t)return this;var n=t.layers;if(!U(n))return this;for(var r=[],o=0,a=n.length;o<a;o++)y(n[o])?r.push(this.getLayer(n[o])):r.push(n[o]);for(var s=new On(t.coordinate),u=d({},t),c=[],l=r.length-1;l>=0&&!(t.count&&c.length>=t.count);l--){var h=r[l];if(h&&h.getMap()&&(t.includeInvisible||h.isVisible())&&(t.includeInternals||!(h.getId().indexOf(i)>=0))){var f=h.identify(s,u);f&&(Array.isArray(f)?I(c,f):c.push(f))}}return e.call(this,c),this}}),ii.include({_zoom:function(t,e){this.options.zoomable&&!this.isZooming()&&(e=this._checkZoomOrigin(e),t=this._checkZoom(t),this.onZoomStart(t,e),this._frameZoom=this.getZoom(),this.onZoomEnd(t,e))},_zoomAnimation:function(t,e,n){this.options.zoomable&&!this.isZooming()&&(t=this._checkZoom(t),this.getZoom()!==t&&(e=this._checkZoomOrigin(e),this._startZoomAnim(t,e,n)))},_checkZoomOrigin:function(t){return t&&!this.options.zoomInCenter||(t=new me(this.width/2,this.height/2)),this.options.zoomOrigin&&(t=new me(this.options.zoomOrigin)),t},_startZoomAnim:function(t,e,n){p(n)&&(n=1);var r=this._getResolution(this._startZoomVal)/this._getResolution(t),i=this.options.zoomAnimationDuration*Math.abs(r-n)/Math.abs(r-1);this._frameZoom=this._startZoomVal,this._animateTo({zoom:t,around:e},{continueOnViewChanged:!0,duration:i})},onZoomStart:function(t,e){this.options.zoomable&&!this.isZooming()&&(this._mapAnimPlayer&&this._stopAnim(this._mapAnimPlayer),this._zooming=!0,this._startZoomVal=this.getZoom(),this._startZoomCoord=this._containerPointToPrj(e),this._fireEvent("zoomstart",{from:this._startZoomVal,to:t}))},onZooming:function(t,e,n){if(this.options.zoomable&&this._frameZoom!==t){p(n)&&(n=1),this._zoomTo(t,e);var r=this.getResolution(t),i=this.getResolution(this._startZoomVal)/r/n,o=this._prjToContainerPoint(this._startZoomCoord,this._startZoomVal),a=this.getViewPoint();if(!this.isRotating()&&!o.equals(e)&&1!==i){var s=this.getPitch(),u=o._sub(e)._multi(1/(1-i));s&&(u.y/=Math.cos(s*Math.PI/180)),e=e.add(u)}var c={view:[i,0,0,i,(e.x-a.x)*(1-i),(e.y-a.y)*(1-i)]},l=this.getDevicePixelRatio();1!==l&&(e=e.multi(l)),c.container=[i,0,0,i,e.x*(1-i),e.y*(1-i)],this._fireEvent("zooming",{from:this._startZoomVal,to:t,origin:e,matrix:c}),this._frameZoom=t}},onZoomEnd:function(t,e){if(this.options.zoomable){var n=this._startZoomVal;this._zoomTo(t,e),this._zooming=!1,this._getRenderer().onZoomEnd(),this._fireEvent("zoomend",{from:n,to:t}),this._verifyExtent(this._getPrjCenter())||this._panTo(this._prjMaxExtent.getCenter())}},_zoomTo:function(t,e){this._zoomLevel=t,this._calcMatrices(),e&&this._setPrjCoordAtContainerPoint(this._startZoomCoord,e)},_checkZoom:function(t){var e=this.getMaxZoom(),n=this.getMinZoom();return t<n&&(t=n),t>e&&(t=e),t}});var So=Math.PI/180,To=new On(0,0);function Eo(){return mo(new Array(16))}ii.include({getFov:function(){return this._fov||(this._fov=.6435011087932844),this._fov/So},setFov:function(t){if(this.isZooming())return this;if(t=Math.max(.01,Math.min(60,t)),this._fov===t)return this;var e=this.getFov();return this._fov=t*So,this._calcMatrices(),this._renderLayers(),this._fireEvent("fovchange",{from:e,to:this.getFov()}),this},getBearing:function(){return this._angle?-this._angle/So:0},setBearing:function(t){if(he.ie9)throw new Error("map can't rotate in IE9.");var e=-H(t,-180,180)*So;if(this._angle===e)return this;var n=this.getBearing();return this._fireEvent("rotatestart",{from:n,to:e}),this._angle=e,this._calcMatrices(),this._renderLayers(),this._fireEvent("rotate",{from:n,to:e}),this._fireEvent("rotateend",{from:n,to:e}),this},getPitch:function(){return this._pitch?this._pitch/Math.PI*180:0},setPitch:function(t){if(he.ie9)throw new Error("map can't tilt in IE9.");var e=G(t,0,this.options.maxPitch)*So;if(this._pitch===e)return this;var n=this.getPitch();return this._fireEvent("pitchstart",{from:n,to:e}),this._pitch=e,this._calcMatrices(),this._renderLayers(),this._fireEvent("pitch",{from:n,to:e}),this._fireEvent("pitchend",{from:n,to:e}),this},isTransforming:function(){return!(!this._pitch&&!this._angle)},getFrustumAltitude:function(){return this._frustumAltitude},_calcFrustumAltitude:function(){var t=90-this.getPitch(),e=this.getFov()/2,n=this.cameraPosition?this.cameraPosition[2]:0;if(e<=t)return n;e=Math.PI*e/180;var r=new me(this.cameraPosition).distanceTo(new me(this.cameraLookAt)),i=n*Math.tan(2*e);return n+Math.tan(e)*(r+i)},_pointToContainerPoint:function(){var t=[0,0,0];return function(e,n,r,i){if(void 0===r&&(r=0),e=this._pointToPoint(e,n,i),this.isTransforming()||r){r*=this._getResolution(n)/this._getResolution();var o=this._glScale;vo(t,e.x*o,e.y*o,r*o);var a=this._projIfBehindCamera(t,this.cameraPosition,this.cameraForward);Mo(a,a,this.projViewMatrix);var s=this.width/2,u=this.height/2;return a[0]=a[0]*s+s,a[1]=-a[1]*u+u,i?(i.x=a[0],i.y=a[1],i):new me(a[0],a[1])}var c=this._prjToPoint(this._getPrjCenter(),void 0,To);return i?(i.x=e.x,i.y=e.y):i=e,i._sub(c.x,c.y),i.set(i.x,-i.y),i._add(this.width/2,this.height/2)}}(),_projIfBehindCamera:function(){var t=new Array(3),e=new Array(3),n=new Array(3);return function(r,i,o){yo(t,r,i);var a=function(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}(o,t);return a<=0&&(function(t,e,n){t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n}(e,o,1.01*a),function(t,e,n){t[0]=e[0]+n[0],t[1]=e[1]+n[1],t[2]=e[2]+n[2]}(r,i,yo(n,t,e))),r}}(),_containerPointToPoint:function(){var t=[0,0,0],e=[0,0,0,1],n=[0,0,0,1];return function(r,i,o){if(this.isTransforming()){var a=this.width/2||1,s=this.height/2||1;vo(t,(r.x-a)/a,(s-r.y)/s,0),vo(e,t[0],t[1],0),vo(n,t[0],t[1],1),e[3]=n[3]=1,Mo(e,e,this.projViewMatrixInverse),Mo(n,n,this.projViewMatrixInverse);var u=e[0],c=n[0],l=e[1],h=n[1],f=e[2],d=n[2],p=f===d?0:(0-f)/(d-f),m=B(u,c,p),g=B(l,h,p);return o?(o.x=m,o.y=g):o=new me(m,g),o._multi(1/this._glScale),void 0===i||this.getZoom()===i?o:this._pointToPointAtZoom(o,i,o)}var v=this._prjToPoint(this._getPrjCenter(),i,o),y=void 0!==i?this._getResolution()/this._getResolution(i):1,_=y*(r.x-this.width/2),x=y*(r.y-this.height/2);return v._add(_,-x)}}(),_calcMatrices:function(){var t=Eo();return function(){delete this._mapRes,delete this._mapGlRes,delete this._mapExtent2D,delete this._mapGlExtent2D;var e=this.getSize(),n=e.width||1,r=e.height||1;this._glScale=this.getGLScale();var i=this.getPitch()*Math.PI/180,o=this._getCameraWorldMatrix(),a=this.getFov()*Math.PI/180,s=this._getCameraFar(a,this.getPitch());this.cameraFar=s,this.cameraNear=Math.max(this._glScale*this.getResolution(this.getGLZoom())*Math.cos(i),.1);var u=this.projMatrix||Eo();co(u,a,n/r,this.cameraNear,s),this.projMatrix=u,this.viewMatrix=po(this.viewMatrix||Eo(),o),this.projViewMatrix=fo(this.projViewMatrix||Eo(),u,this.viewMatrix),this._calcCascadeMatrixes(),this.projViewMatrixInverse=fo(this.projViewMatrixInverse||Eo(),o,po(t,u)),this.domCssMatrix=this._calcDomMatrix(),this._frustumAltitude=this._calcFrustumAltitude(),this._mapRes=this._getResolution(),this._mapGlRes=this._getResolution(this.getGLZoom()),this._mapExtent2D=this._get2DExtent(),this._mapGlExtent2D=this._get2DExtent(this.getGLZoom())}}(),_getCameraFar:function(t,e){var n=this.cameraCenterDistance=wo(this.cameraPosition,this.cameraLookAt),r=n;if(e>0){var i;if(e=e*Math.PI/180,2/Math.PI-e<=t/2)i=4*n;else{var o=Math.tan(t/2);i=n*o/(1/Math.tan(e)-o)}r+=i}return r+1},_calcCascadeMatrixes:function(){var t=Eo();function e(e,n,r){var i=this.width,o=this.height,a=this.getFov()*Math.PI/180,s=this._getCameraFar(a,n),u=this.cameraCenterDistance;s=u+(s-u)/Math.cos((90-n)*Math.PI/180)*Math.cos((90-e)*Math.PI/180),co(t,a,i/o,.1,s);var c=this.viewMatrix;return fo(r,t,c)}return function(){var t=this.getPitch(),n=this.options.cascadePitches[0],r=this.options.cascadePitches[1],i=this.cascadeFrustumMatrix0=this.cascadeFrustumMatrix0||Eo(),o=this.cascadeFrustumMatrix1=this.cascadeFrustumMatrix1||Eo();t>n?e.call(this,t,n,i):go(this.cascadeFrustumMatrix0,this.projViewMatrix),t>r?e.call(this,t,r,o):go(this.cascadeFrustumMatrix1,this.cascadeFrustumMatrix0)}}(),_calcDomMatrix:function(){var t=Eo(),e=Eo(),n=[1,-1,1],r=[0,0,0];return function(){var i=this.width||1,o=this.height||1,a=.5/Math.tan(this._fov/2)*o;return ho(t,this.projMatrix,n),lo(t,t,vo(r,0,0,-a)),this._pitch&&function(t,e,n){var r=Math.sin(n),i=Math.cos(n),o=e[4],a=e[5],s=e[6],u=e[7],c=e[8],l=e[9],h=e[10],f=e[11];e!==t&&(t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[4]=o*i+c*r,t[5]=a*i+l*r,t[6]=s*i+h*r,t[7]=u*i+f*r,t[8]=c*i-o*r,t[9]=l*i-a*r,t[10]=h*i-s*r,t[11]=f*i-u*r}(t,t,this._pitch),this._angle&&function(t,e,n){var r=Math.sin(n),i=Math.cos(n),o=e[0],a=e[1],s=e[2],u=e[3],c=e[4],l=e[5],h=e[6],f=e[7];e!==t&&(t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[0]=o*i+c*r,t[1]=a*i+l*r,t[2]=s*i+h*r,t[3]=u*i+f*r,t[4]=c*i-o*r,t[5]=l*i-a*r,t[6]=h*i-s*r,t[7]=f*i-u*r}(t,t,this._angle),mo(e),ho(e,e,vo(r,i/2,-o/2,1)),fo(this.domCssMatrix||Eo(),e,t)}}(),_getCameraWorldMatrix:function(){var t={};return function(){var e=this.getGLZoom(),n=this.getSize(),r=this.getGLScale(),i=this._prjToPoint(this._prjCenter,e);this.cameraLookAt=vo(this.cameraLookAt||[0,0,0],i.x,i.y,0);var o=this.getPitch()*So,a=this.getBearing()*So,s=this._getFovRatio(),u=r*(n.height||1)/2/s,c=u*Math.cos(o),l=Math.sin(o)*u,h=i.x-l*Math.sin(a),f=i.y-l*Math.cos(a);this.cameraPosition=vo(this.cameraPosition||[0,0,0],h,f,c);var d=l||1,p=this.cameraUp=vo(this.cameraUp||[0,0,0],Math.sin(a)*d,Math.cos(a)*d,0),m=this.cameraWorldMatrix=this.cameraWorldMatrix||Eo();!function(t,e,n,r){var i=[0,0,0],o=[0,0,0],a=[0,0,0];yo(a,e,n),0===_o(a)&&(a[2]=1),xo(a,a),bo(i,r,a),0===_o(a)&&(1===Math.abs(r[2])?a[0]+=1e-4:a[2]+=1e-4,xo(a,a),bo(i,r,a)),xo(i,i),bo(o,a,i),t[0]=i[0],t[4]=o[0],t[8]=a[0],t[1]=i[1],t[5]=o[1],t[9]=a[1],t[2]=i[2],t[6]=o[2],t[10]=a[2]}(m,this.cameraPosition,this.cameraLookAt,p);var g=this.cameraForward||[0,0,0];return yo(g,this.cameraLookAt,this.cameraPosition),this.cameraForward=xo(g,g),function(t,e){var n,r=e[0],i=e[4],o=e[8],a=e[1],s=e[5],u=e[9],c=e[2],l=e[6],h=e[10],f=r+s+h;f>0?(n=.5/Math.sqrt(f+1),t.w=.25/n,t.x=(l-u)*n,t.y=(o-c)*n,t.z=(a-i)*n):r>s&&r>h?(n=2*Math.sqrt(1+r-s-h),t.w=(l-u)/n,t.x=.25*n,t.y=(i+a)/n,t.z=(o+c)/n):s>h?(n=2*Math.sqrt(1+s-r-h),t.w=(o-c)/n,t.x=(i+a)/n,t.y=.25*n,t.z=(u+l)/n):(n=2*Math.sqrt(1+h-r-s),t.w=(a-i)/n,t.x=(o+c)/n,t.y=(u+l)/n,t.z=.25*n)}(t,m),function(t,e){var n=t,r=e.x,i=e.y,o=e.z,a=e.w,s=r+r,u=i+i,c=o+o,l=r*s,h=r*u,f=r*c,d=i*u,p=i*c,m=o*c,g=a*s,v=a*u,y=a*c;n[0]=1-(d+m),n[4]=h-y,n[8]=f+v,n[1]=h+y,n[5]=1-(l+m),n[9]=p-g,n[2]=f-v,n[6]=p+g,n[10]=1-(l+d),n[3]=0,n[7]=0,n[11]=0,n[12]=0,n[13]=0,n[14]=0,n[15]=1}(m,t),function(t,e){var n=t;n[12]=e[0],n[13]=e[1],n[14]=e[2]}(m,this.cameraPosition),m}}(),_getFovRatio:function(){var t=this.getFov();return Math.tan(t/2*So)},_renderLayers:function(){this.isInteracting()||this._getLayers().forEach((function(t){if(t){var e=t._getRenderer();e&&e.setToRedraw&&e.setToRedraw()}}))}}),ii.include({_onViewChange:function(t){this._viewHistory||(this._viewHistory=[],this._viewHistoryPointer=0);for(var e=this._getCurrentView(),n=this._viewHistory.length-1;n>=0;n--)if(K(t,this._viewHistory[n]))return this._viewHistoryPointer=n,void this._fireViewChange(e,t);this._viewHistoryPointer<this._viewHistory.length-1&&this._viewHistory.splice(this._viewHistoryPointer+1),this._viewHistory.push(t);var r=this.options.viewHistoryCount;r>0&&this._viewHistory.length>r&&this._viewHistory.splice(0,this._viewHistory.length-r),this._viewHistoryPointer=this._viewHistory.length-1,this._fireViewChange(e,t)},zoomToPreviousView:function(t){if(void 0===t&&(t={}),!this.hasPreviousView())return null;var e=this._viewHistory[--this._viewHistoryPointer];return this._zoomToView(e,t),e},hasPreviousView:function(){return!(!this._viewHistory||0===this._viewHistoryPointer)},zoomToNextView:function(t){if(void 0===t&&(t={}),!this.hasNextView())return null;var e=this._viewHistory[++this._viewHistoryPointer];return this._zoomToView(e,t),e},hasNextView:function(){return!(!this._viewHistory||this._viewHistoryPointer===this._viewHistory.length-1)},_zoomToView:function(t,e){var n=this,r=this.getView();e.animation?this._animateTo(t,{duration:e.duration},(function(e){"finished"===e.state.playState&&n._fireViewChange(r,t)})):(this.setView(t),this._fireViewChange(r,t))},getViewHistory:function(){return this._viewHistory},_fireViewChange:function(t,e){this._fireEvent("viewchange",{old:t,new:e})},_getCurrentView:function(){return this._viewHistory?this._viewHistory[this._viewHistoryPointer]:null}}),ii.mergeOptions({viewHistory:!0,viewHistoryCount:10});var Ao=function(t){function e(e){var n;return(n=t.call(this,e)||this).on("enable",n._afterEnable,de(de(n))).on("disable",n._afterDisable,de(de(n))),n._measureLayers=[],n}fe(e,t);var n=e.prototype;return n.clear=function(){if(U(this._measureLayers))for(var t=0;t<this._measureLayers.length;t++)this._measureLayers[t].remove();return delete this._lastMeasure,delete this._lastVertex,this._measureLayers=[],this},n.getMeasureLayers=function(){return this._measureLayers},n.getLastMeasure=function(){return this._lastMeasure?this._lastMeasure:0},n.undo=function(){t.prototype.undo.call(this);var e=this._historyPointer;if(e!==this._vertexes.length)for(var n=e;n<this._vertexes.length;n++)this._vertexes[n].label&&this._vertexes[n].label.remove(),this._vertexes[n].marker.remove();return this},n.redo=function(){t.prototype.redo.call(this);var e=this._historyPointer-1;return this._vertexes[e]&&(this._vertexes[e].marker.getLayer()||(this._vertexes[e].label&&this._vertexes[e].label.addTo(this._measureMarkerLayer),this._vertexes[e].marker.addTo(this._measureMarkerLayer))),this},n._measure=function(t){var e,n,r=this.getMap();t instanceof Kr?e=r.computeGeometryLength(t):Array.isArray(t)&&(e=r.getProjection().measureLength(t)),this._lastMeasure=e,n="zh-CN"===this.options.language?[" 米"," 公里"," 英尺"," 英里"]:[" m"," km"," feet"," mile"];var i="";return this.options.metric&&(i+=e<1e3?e.toFixed(0)+n[0]:(e/1e3).toFixed(2)+n[1]),this.options.imperial&&(e*=3.2808399,i.length>0&&(i+="\n"),i+=e<5280?e.toFixed(0)+n[2]:(e/5280).toFixed(2)+n[3]),i},n._registerMeasureEvents=function(){this.on("drawstart",this._msOnDrawStart,this).on("drawvertex",this._msOnDrawVertex,this).on("mousemove",this._msOnMouseMove,this).on("drawend",this._msOnDrawEnd,this)},n._afterEnable=function(){this._registerMeasureEvents()},n._afterDisable=function(){this.off("drawstart",this._msOnDrawStart,this).off("drawvertex",this._msOnDrawVertex,this).off("mousemove",this._msOnMouseMove,this).off("drawend",this._msOnDrawEnd,this)},n._msOnDrawStart=function(t){var e=this.getMap(),n=e._pointToPrj(t.point2d),r=O(),i="distancetool_"+r,o="distancetool_markers_"+r;e.getLayer(i)?(this._measureLineLayer=e.getLayer(i),this._measureMarkerLayer=e.getLayer(o)):(this._measureLineLayer=new eo(i).addTo(e),this._measureMarkerLayer=new eo(o).addTo(e)),this._measureLayers.push(this._measureLineLayer),this._measureLayers.push(this._measureMarkerLayer);var a=new Mi(t.coordinate,{symbol:this.options.vertexSymbol});a._setPrjCoordinates(n);var s="zh-CN"===this.options.language?"起点":"start",u=new qi(s,t.coordinate,this.options.labelOptions);u._setPrjCoordinates(n),this._lastVertex=u,this._addVertexMarker(a,u)},n._msOnMouseMove=function(t){var e=this._measure(this._msGetCoordsToMeasure(t));if(!this._tailMarker){var n=Dt(this.options.vertexSymbol);n.markerWidth/=2,n.markerHeight/=2,this._tailMarker=new Mi(t.coordinate,{symbol:n}).addTo(this._measureMarkerLayer),this._tailLabel=new qi(e,t.coordinate,this.options.labelOptions).addTo(this._measureMarkerLayer)}var r=this._geometry._getPrjCoordinates(),i=r[r.length-1];this._tailMarker.setCoordinates(t.coordinate),this._tailMarker._setPrjCoordinates(i),this._tailLabel.setContent(e),this._tailLabel.setCoordinates(t.coordinate),this._tailLabel._setPrjCoordinates(i)},n._msGetCoordsToMeasure=function(t){return t.geometry.getCoordinates().concat([t.coordinate])},n._msOnDrawVertex=function(t){var e=this._geometry._getPrjCoordinates(),n=e[e.length-1],r=t.geometry,i=new Mi(t.coordinate,{symbol:this.options.vertexSymbol}),o=this._measure(r),a=new qi(o,t.coordinate,this.options.labelOptions);this._addVertexMarker(i,a),a._setPrjCoordinates(n),i._setPrjCoordinates(n),this._lastVertex=a},n._addVertexMarker=function(t,e){this._vertexes||(this._vertexes=[]),this._vertexes.push({label:e,marker:t}),void 0!==this._historyPointer&&(this._vertexes.length=this._historyPointer),this._measureMarkerLayer.addGeometry(t),e&&this._measureMarkerLayer.addGeometry(e)},n._msOnDrawEnd=function(t){this._clearTailMarker();var e=this._lastVertex.getSize();e||(e=new ge(10,10)),this._addClearMarker(this._lastVertex.getCoordinates(),this._lastVertex._getPrjCoordinates(),e.width);var n=t.geometry.copy();n._setPrjCoordinates(t.geometry._getPrjCoordinates()),n.addTo(this._measureLineLayer),this._lastMeasure=n.getLength()},n._addClearMarker=function(t,e,n){var r=this.options.clearButtonSymbol,i={markerDx:(r.markerDx||0)+n,textDx:(r.textDx||0)+n};Array.isArray(r)&&(i=r.map((function(t){return t?{markerDx:(t.markerDx||0)+n,textDx:(t.textDx||0)+n}:null}))),r=Dt(r,i);var o=new Mi(t,{symbol:r}),a=this._measureLineLayer,s=this._measureMarkerLayer;o.on("click",(function(){return a.remove(),s.remove(),!1}),this),o.addTo(this._measureMarkerLayer),o._setPrjCoordinates(e)},n._clearTailMarker=function(){this._tailMarker&&(this._tailMarker.remove(),delete this._tailMarker),this._tailLabel&&(this._tailLabel.remove(),delete this._tailLabel)},e}(oo);Ao.mergeOptions({mode:"LineString",language:"zh-CN",metric:!0,imperial:!1,symbol:{lineColor:"#000",lineWidth:3,lineOpacity:1},vertexSymbol:{markerType:"ellipse",markerFill:"#fff",markerLineColor:"#000",markerLineWidth:3,markerWidth:11,markerHeight:11},labelOptions:{textSymbol:{textFaceName:"monospace",textLineSpacing:1,textHorizontalAlignment:"right",textDx:15},boxStyle:{padding:[6,2],symbol:{markerType:"square",markerFill:"#fff",markerFillOpacity:.9,markerLineColor:"#b4b3b3"}}},clearButtonSymbol:[{markerType:"square",markerFill:"#fff",markerLineColor:"#b4b3b3",markerLineWidth:2,markerWidth:15,markerHeight:15,markerDx:20},{markerType:"x",markerWidth:10,markerHeight:10,markerDx:20}]});var Co=function(t){function e(e){var n;return(n=t.call(this,e)||this).on("enable",n._afterEnable,de(de(n))).on("disable",n._afterDisable,de(de(n))),n._measureLayers=[],n}fe(e,t);var n=e.prototype;return n._measure=function(t){var e,n,r=this.getMap();t instanceof Kr?e=r.computeGeometryArea(t):Array.isArray(t)&&(e=r.getProjection().measureArea(t)),this._lastMeasure=e,n="zh-CN"===this.options.language?[" 平方米"," 平方公里"," 平方英尺"," 平方英里"]:[" sq.m"," sq.km"," sq.ft"," sq.mi"];var i="";if(this.options.metric&&(i+=e<1e6?e.toFixed(0)+n[0]:(e/1e6).toFixed(2)+n[1]),this.options.imperial){e*=3.2808399,i.length>0&&(i+="\n");var o=27878400;i+=e<o?e.toFixed(0)+n[2]:(e/o).toFixed(2)+n[3]}return i},n._msGetCoordsToMeasure=function(t){return t.geometry.getShell().concat([t.coordinate])},n._msOnDrawVertex=function(t){var e=this.getMap()._pointToPrj(t.point2d),n=new Mi(t.coordinate,{symbol:this.options.vertexSymbol});n._setPrjCoordinates(e),this._measure(t.geometry),this._lastVertex=n,this._addVertexMarker(n)},n._msOnDrawEnd=function(t){this._clearTailMarker();var e=this.getMap()._pointToPrj(t.point2d),n=this._measure(t.geometry),r=new qi(n,t.coordinate,this.options.labelOptions).addTo(this._measureMarkerLayer);r._setPrjCoordinates(e);var i=r.getSize();i||(i=new ge(10,10)),this._addClearMarker(t.coordinate,e,i.width);var o=t.geometry.copy();o._setPrjCoordinates(t.geometry._getPrjCoordinates()),o.addTo(this._measureLineLayer),this._lastMeasure=o.getArea()},e}(Ao);Co.mergeOptions({mode:"Polygon",symbol:{lineColor:"#000000",lineWidth:2,lineOpacity:1,lineDasharray:"",polygonFill:"#ffffff",polygonOpacity:.5}});var Po={create:function(t,e){var n=t.unproject(e[0]),r=new Di(n,0);return r._setPrjCoordinates(e[0]),r},update:function(t,e,n){var r=n.getMap(),i=Array.isArray(e)?e[e.length-1]:e,o=t.unproject(i),a=r.computeLength(n.getCenter(),o);n.setRadius(a)},generate:function(t){return t}};oo.registerMode("circle",d({clickLimit:2,action:["click","mousemove","click"]},Po)),oo.registerMode("freeHandCircle",d({action:["mousedown","mousemove","mouseup"]},Po));var Lo={create:function(t,e){var n=t.unproject(e[0]),r=new ji(n,0,0);return r._setPrjCoordinates(e[0]),r},update:function(t,e,n){var r=n.getMap(),i=n.getCenter(),o=Array.isArray(e)?e[e.length-1]:e,a=t.unproject(o),s=r.computeLength(i,new On({x:a.x,y:i.y})),u=r.computeLength(i,new On({x:i.x,y:a.y}));n.setWidth(2*s),n.setHeight(2*u)},generate:function(t){return t}};oo.registerMode("ellipse",d({clickLimit:2,action:["click","mousemove","click"]},Lo)),oo.registerMode("freeHandEllipse",d({action:["mousedown","mousemove","mouseup"]},Lo));var Oo={create:function(t,e){var n=new bi([]);return n._firstClick=e[0],n},update:function(t,e,n,r){var i=n.getMap(),o=r.containerPoint,a=i._prjToContainerPoint(n._firstClick),s=[[a.x,a.y],[o.x,a.y],[o.x,o.y],[a.x,o.y]];n.setCoordinates(s.map((function(t){return i.containerPointToCoord(new me(t))}))),n._setPrjCoordinates(s.map((function(t){return i._containerPointToPrj(new me(t))})))},generate:function(t){return t}};oo.registerMode("rectangle",d({clickLimit:2,action:["click","mousemove","click"]},Oo)),oo.registerMode("freeHandRectangle",d({action:["mousedown","mousemove","mouseup"]},Oo)),oo.registerMode("point",{clickLimit:1,action:["click"],create:function(t,e){var n=t.unproject(e[0]),r=new Mi(n);return r._setPrjCoordinates(e[0]),r},generate:function(t){return t}});var Ro={create:function(t,e){var n=e.map((function(e){return t.unproject(e)})),r=new Ti(n);return r._setPrjCoordinates(e),r},update:function(t,e,n){var r,i=n.getSymbol();Array.isArray(e)?r=e:(r=n._getPrjCoordinates()).push(e);var o=r.map((function(e){return t.unproject(e)}));n.setCoordinates(o),n._setPrjCoordinates(r);var a=n.getLayer();if(a){var s=a.getGeometryById("polygon");if(!s&&r.length>=3){if(s=new bi([o],{id:"polygon"}),i){var u=Dt(i,{lineOpacity:0});s.setSymbol(u)}s.addTo(a)}s&&s._setPrjCoordinates(r)}},generate:function(t){var e=new bi(t.getCoordinates(),{symbol:t.getSymbol()});return e._setPrjCoordinates(t._getPrjCoordinates()),e._projCode=t._projCode,e}};oo.registerMode("polygon",d({action:["click","mousemove","dblclick"]},Ro)),oo.registerMode("freeHandPolygon",d({action:["mousedown","mousemove","mouseup"]},Ro));var ko={create:function(t,e){var n=e.map((function(e){return t.unproject(e)})),r=new Ti(n);return r._setPrjCoordinates(e),r},update:function(t,e,n){var r;Array.isArray(e)?r=e:(r=n._getPrjCoordinates()).push(e);var i=r.map((function(e){return t.unproject(e)}));n.setCoordinates(i),n._setPrjCoordinates(r)},generate:function(t){return t}};function Io(t){for(var e=t.tileInfo,n=[e.cols,e.rows],r=[],i=e.lods,o=0,a=i.length;o<a;o++)r.push(i[o].resolution);var s=t.fullExtent,u=e.origin,c=[1,-1,u.x,u.y];return delete s.spatialReference,{spatialReference:{resolutions:r,fullExtent:s},tileSystem:c,tileSize:n}}function Do(t,e){return void 0===e&&(e=[]),e.forEach((function(e){var n=e[0],r=e[1];t=t.replace(n,r)})),t}function jo(t,e,n){void 0===n&&(n={});var r,i,o=t[e],a=o.getElementsByTagName("TileMatrix"),s=[],u=[],c=[];if(!r){var l=o.getElementsByTagName("ows:SupportedCRS")[0];if(l){for(r=(r=l.textContent).split("EPSG")[1];r.indexOf(":")>-1;)r=r.replace(":","");r=function(t){var e=t.indexOf("EPSG")>-1?t:"EPSG:"+t;return e=Do(e,[["4490","4326"],["102100","3857"],["900913","3857"]])}(r)}}i||(i=o.getElementsByTagName("ows:Identifier")[0])&&(i=i.textContent);var h=.0002645833333333333;n.isArcgis&&(h=28e-5),r&&r.indexOf("4326")>-1&&(h=2.3767925226029154e-9,n.isArcgis&&(h=2.518101729011901e-9));for(var f=1/0,d=0;d<a.length;d++){var p=a[d],m=p.getElementsByTagName("ows:Identifier")[0].textContent;m=parseInt(m),f=Math.min(f,m);var g=p.getElementsByTagName("ScaleDenominator")[0].textContent,v=p.getElementsByTagName("TopLeftCorner")[0].textContent,y=p.getElementsByTagName("TileWidth")[0].textContent,_=p.getElementsByTagName("TileHeight")[0].textContent;if(0===c.length&&c.push(parseInt(y),parseInt(_)),0===u.length){var x=v.split(" ").filter((function(t){return""!==t})).map((function(t){return parseFloat(t)})),b=x[0],w=x[1];b>0?u.push(1,-1,w,b):u.push(1,-1,b,w)}var M=parseFloat(g)*h;s.push(M)}if(f>0)for(var S=s[0],T=f-1;T>=0;T--)S*=2,s.splice(0,0,S);return{resolutions:s,tileSize:c,tileSystem:u,projection:r,TileMatrixSet:i}}oo.registerMode("linestring",d({action:["click","mousemove","dblclick"]},ko)),oo.registerMode("freeHandLinestring",d({action:["mousedown","mousemove","mouseup"]},ko)),oo.registerMode("arccurve",{action:["click","mousemove","dblclick"],create:function(t,e){var n=e.map((function(e){return t.unproject(e)})),r=new Bi(n);return r._setPrjCoordinates(e),r},update:ko.update,generate:function(t){return t}}),oo.registerMode("quadbeziercurve",{action:["click","mousemove","dblclick"],create:function(t,e){var n=e.map((function(e){return t.unproject(e)})),r=new Gi(n);return r._setPrjCoordinates(e),r},update:ko.update,generate:function(t){return t}}),oo.registerMode("cubicbeziercurve",{action:["click","mousemove","dblclick"],create:function(t,e){var n=e.map((function(e){return t.unproject(e)})),r=new Hi(n);return r._setPrjCoordinates(e),r},update:ko.update,generate:function(t){return t}}),oo.registerMode("boxZoom",{action:["mousedown","mousemove","mouseup"],create:function(t,e){e=e[0];var n=t.unproject(e),r=new Mi(n);return r._firstClick=e,r},update:function(t,e,n,r){var i=n.getMap(),o=i._prjToContainerPoint(n._firstClick),a=r.containerPoint;e=i._containerPointToPrj(new On(Math.min(o.x,a.x),Math.min(o.y,a.y)));var s=t.unproject(e);n.setCoordinates(s)._setPrjCoordinates(e),n.updateSymbol({markerWidth:Math.abs(o.x-a.x),markerHeight:Math.abs(o.y-a.y)})},generate:function(t){return t}}),Qr.loadArcgis=function(t,e,n){if(void 0===n&&(n={jsonp:!0}),y(t)&&"{"!==t.substring(0,1))sn.getJSON(t,(function(t,n){if(t)e(t);else{var r=Io(n);e(null,r)}}),n);else{y(t)&&(t=k(t));var r=Io(t);e(null,r)}return this},Qr.loadWMTS=function(t,e,n){return void 0===n&&(n={jsonp:!0}),y(t)&&sn.get(t,(function(r,i){if(r)e(r);else{var o=function(t,e,n){var r=(new DOMParser).parseFromString(t,"text/xml").querySelectorAll("Contents")[0];if(!r)return[];var i=r.getElementsByTagName("Layer");if(!i.length)return[];for(var o=[],a=0,s=r.childNodes.length;a<s;a++)"TileMatrixSet"===r.childNodes[a].nodeName&&o.push(r.childNodes[a]);if(!o.length)return[];for(var u=[],c=0,l=i.length;c<l;c++){var h=i[c],f=h.querySelectorAll("Style")[0];f&&(f=f.getElementsByTagName("ows:Identifier")[0])&&(f=f.textContent);var d=h.getElementsByTagName("ows:Identifier")[0];d&&(d=d.textContent);var p=h.querySelectorAll("ResourceURL")[0],m="";p&&(m=p.attributes.template.value);var g=jo(o,c,n),v=g.resolutions,y=g.tileSize,_=g.tileSystem,x=g.projection,b=g.TileMatrixSet;m.length||(m=e.substr(0,e.lastIndexOf("?")),m+="?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER={LAYER}&STYLE={Style}&TILEMATRIXSET={TileMatrixSet}&FORMAT=tiles&TILEMATRIX={TileMatrix}&TILEROW={TileRow}&TILECOL={TileCol}");var w=Do(m,[["{LAYER}",d],["{Layer}",d],["{layer}",d],["{STYLE}",f],["{Style}",f],["{style}",f],["{TileMatrixSet}",b],["{TileMatrix}","{z}"],["{TileRow}","{y}"],["{TileCol}","{x}"]]);u.push({tileSize:y,tileSystem:_,spatialReference:{resolutions:v,projection:x},urlTemplate:w,info:{layerName:d,TileMatrixSet:b,style:f,tileSize:y,tileSystem:_,resolutions:v,projection:x,urlTemplate:w}})}return u}(i,t,n);e(null,o)}}),n),this};var zo=function(t){function e(e){return t.call(this,e)||this}fe(e,t);var n=e.prototype;return n.addTo=function(t){return this._owner=t,this._switchEvents("on"),this.onAdd&&this.onAdd(),this.fire("add"),this},n.getMap=function(){return this._owner?this._owner.getBaseLayer?this._owner:this._owner.getMap():null},n.show=function(t){var e=this.getMap();if(!e)return this;this._mapEventsOn||this._switchMapEvents("on"),t=t||this._coordinate||this._owner.getCenter();var n=this.isVisible();this.fire("showstart");var r=this._getUIContainer();this._coordinate=t,this._removePrevDOM();var i=this.__uiDOM=this.buildOn(e);if(i.eventsPropagation=this.options.eventsPropagation,!i)return this.fire("showend"),this;this._measureSize(i),this._singleton()&&(e[this._uiDomKey()]=i),this._setPosition(),i.style[Ie]=null,r.appendChild(i);var o=this._getAnimation();if(n&&(o.ok=!1),o.ok&&(o.fade&&(i.style.opacity=0),o.scale)){if(this.getTransformOrigin){var a=this.getTransformOrigin();i.style[ke]=a}i.style[Re]=this._toCSSTranslate(this._pos)+" scale(0)"}i.style.display="",this.options.eventsToStop&&rn(i,this.options.eventsToStop,Ue),this.options.autoPan&&this._autoPan();var s=o.transition;return o.ok&&s&&(i.offsetHeight,s&&(i.style[Ie]=s),o.fade&&(i.style.opacity=1),o.scale&&(i.style[Re]=this._toCSSTranslate(this._pos)+" scale(1)")),this.fire("showend"),this},n.hide=function(){var t=this;if(!this.getDOM()||!this.getMap())return this;var e=this._getAnimation(),n=this.getDOM();return this.options.animationOnHide||(e.ok=!1),e.ok?(n.offsetHeight,n.style[Ie]=e.transition,setTimeout((function(){n.style.display="none",t.fire("hide")}),this.options.animationDuration)):(n.style.display="none",this.fire("hide")),e.fade&&(n.style.opacity=0),e.scale&&(n.style[Re]=this._toCSSTranslate(this._pos)+" scale(0)"),this},n.isVisible=function(){var t=this.getDOM();return this.getMap()&&t&&t.parentNode&&"none"!==t.style.display},n.remove=function(){return delete this._mapEventsOn,this._owner?(this.hide(),this._switchEvents("off"),this.onRemove&&this.onRemove(),!this._singleton()&&this.__uiDOM&&this._removePrevDOM(),delete this._owner,this.fire("remove"),this):this},n.getSize=function(){return this._size?this._size.copy():null},n.getOwner=function(){return this._owner},n.getDOM=function(){return this.__uiDOM},n.getPosition=function(){if(!this.getMap())return null;var t=this._getViewPoint()._round();if(this.getOffset){var e=this.getOffset()._round();e&&t._add(e)}return t},n._getAnimation=function(){for(var t={fade:!1,scale:!1},e=this.options.animation?this.options.animation.split(","):[],n=0;n<e.length;n++){var r=ve(e[n]);"fade"===r?t.fade=!0:"scale"===r&&(t.scale=!0)}var i=null;return t.fade&&(i="opacity "+this.options.animationDuration+"ms"),t.scale&&(i=i?i+",":"",i+=Re+" "+this.options.animationDuration+"ms"),t.transition=i,t.ok=null!==i,t},n._getViewPoint=function(){var t=0;if(this._owner&&this._owner.getAltitude){var e=this._owner.getAltitude();e>0&&(t=this._meterToPoint(this._coordinate,e))}return this.getMap().coordToViewPoint(this._coordinate,void 0,t)._add(this.options.dx,this.options.dy)},n._meterToPoint=function(t,e){return this.getMap().distanceToPoint(e,0,void 0,t).x*N(e)},n._autoPan=function(){var t=this.getMap(),e=this.getDOM();if(!t.isMoving()){var n=this._pos,r=t.getSize(),i=r.width,o=r.height,a=t.viewPointToContainerPoint(n),s=parseInt(e.clientWidth),u=parseInt(e.clientHeight),c=0,l=0;a.x<0?c=-(a.x-s/2):a.x+s-35>i&&(c=i-(a.x+3*s/2)),a.y-u<0?l=50-(a.y-u):a.y>o&&(l=o-a.y-u-30),0===l&&0===c||t.panBy(new me(c,l),{duration:this.options.autoPanDuration})}},n._measureSize=function(t){var e=this._getUIContainer();t.style.position="absolute",t.style.left="-99999px";var n=t.style.bottom?"bottom":"top";return t.style[n]="-99999px",t.style.display="",e.appendChild(t),this._size=new ge(t.clientWidth,t.clientHeight),t.style.display="none",t.style.left="0px",t.style[n]="0px",this._size},n._removePrevDOM=function(){this.onDomRemove&&this.onDomRemove();var t=this.options.eventsToStop;if(this._singleton()){var e=this.getMap(),n=this._uiDomKey();e[n]&&(t&&on(e[n],t,Ue),Ne(e[n]),delete e[n]),delete this.__uiDOM}else this.__uiDOM&&(t&&on(this.__uiDOM,t,Ue),Ne(this.__uiDOM),delete this.__uiDOM)},n._uiDomKey=function(){return"__ui_"+this._getClassName()},n._singleton=function(){return this.options.single},n._getUIContainer=function(){return this.getMap()._panels.ui},n._getClassName=function(){return"UIComponent"},n._switchMapEvents=function(t){var e=this.getMap();if(e){this._mapEventsOn="on"===t;var n=this._getDefaultEvents();if(this.getEvents&&d(n,this.getEvents()),n)for(var r in n)n.hasOwnProperty(r)&&e[t](r,n[r],this)}},n._switchEvents=function(t){this._switchMapEvents(t);var e=this._getOwnerEvents();if(this._owner)for(var n in e)e.hasOwnProperty(n)&&this._owner[t](n,e[n],this)},n._getDefaultEvents=function(){return{"zooming rotate pitch":this.onEvent,zoomend:this.onZoomEnd,moving:this.onMoving,resize:this.onResize}},n._getOwnerEvents=function(){var t={};return this._owner&&this._owner instanceof Kr&&(t.positionchange=this.onGeometryPositionChange),this.getOwnerEvents&&d(t,this.getOwnerEvents()),t},n.onGeometryPositionChange=function(t){this._owner&&this.isVisible()&&this.show(t.target.getCenter())},n.onMoving=function(){this.isVisible()&&this.getMap().isTransforming()&&this._updatePosition()},n.onEvent=function(){this.isVisible()&&this._updatePosition()},n.onZoomEnd=function(){this.isVisible()&&this._setPosition()},n.onResize=function(){this.isVisible()&&this._setPosition()},n._updatePosition=function(){this.getMap()._getRenderer().callInNextFrame(this._setPosition.bind(this))},n._setPosition=function(){var t=this.getDOM();if(t){t.style[Ie]=null;var e=this.getPosition();this._pos=e,t.style[Re]=this._toCSSTranslate(e)+" scale(1)"}},n._toCSSTranslate=function(t){if(!t)return"";if(he.any3d){var e=this.getMap(),n=e?e.getBearing():0,r=e?e.getPitch():0,i="";return this.options.pitchWithMap&&r&&(i+=" rotateX("+Math.round(r)+"deg)"),this.options.rotateWithMap&&n&&(i+=" rotateZ("+Math.round(-n)+"deg)"),"translate3d("+t.x+"px,"+t.y+"px, 0px)"+i}return"translate("+t.x+"px,"+t.y+"px)"},e.isSupport=function(t){return!!(t&&_(t.on)&&_(t.off)&&_(t.getCenter))},e}(xn(Mn));zo.mergeOptions({eventsPropagation:!1,eventsToStop:null,dx:0,dy:0,autoPan:!1,autoPanDuration:600,single:!0,animation:"scale",animationOnHide:!0,animationDuration:500,pitchWithMap:!1,rotateWithMap:!1});var No="mousedown mouseup mouseenter mouseover mouseout mousemove click dblclick contextmenu keypress touchstart touchmove touchend",Fo=function(t){function e(e,n){var r;return(r=t.call(this,n)||this)._markerCoord=new On(e),r}fe(e,t);var n=e.prototype;return n._getClassName=function(){return"UIMarker"},n.setCoordinates=function(t){return this._markerCoord=t,this.fire("positionchange"),this.isVisible()&&(this._coordinate=this._markerCoord,this._setPosition()),this},n.getCoordinates=function(){return this._markerCoord},n.setContent=function(t){var e=this.options.content;return this.options.content=t,this.fire("contentchange",{old:e,new:t}),this.isVisible()&&this.show(),this},n.getContent=function(){return this.options.content},n.onAdd=function(){this.show()},n.show=function(){return t.prototype.show.call(this,this._markerCoord)},n.flash=function(t,e,n,r){return et.call(this,t,e,n,r)},n.buildOn=function(){var t;return y(this.options.content)?(t=je("div")).innerHTML=this.options.content:t=this.options.content,this.options.containerClass&&(t.className=this.options.containerClass),this._registerDOMEvents(t),t},n.getOffset=function(){var t=this.getSize();return new me(-t.width/2,-t.height/2)},n.getTransformOrigin=function(){return"center center"},n.onDomRemove=function(){var t=this.getDOM();this._removeDOMEvents(t)},n.isDragging=function(){return!!this.draggable&&this.draggable.isDragging()},n._registerDOMEvents=function(t){rn(t,No,this._onDomEvents,this)},n._onDomEvents=function(t){var e=this.getMap()._parseEvent(t,t.type);this.fire(t.type,e)},n._removeDOMEvents=function(t){on(t,No,this._onDomEvents,this)},n._getConnectPoints=function(){var t=this.getMap(),e=t.coordToContainerPoint(this.getCoordinates()),n=this.getSize(),r=n.width,i=n.height;return[t.containerPointToCoordinate(e.add(-r/2,0)),t.containerPointToCoordinate(e.add(r/2,0)),t.containerPointToCoordinate(e.add(0,i/2)),t.containerPointToCoordinate(e.add(0,-i/2))]},e}(En(zo));Fo.mergeOptions({containerClass:null,eventsPropagation:!0,draggable:!1,single:!1,content:null});var Bo=he.touch?"touchstart mousedown":"mousedown",Ho=function(t){function e(e){return t.call(this,e)||this}fe(e,t);var n=e.prototype;return n.addHooks=function(){this.target.on(Bo,this._startDrag,this)},n.removeHooks=function(){this.target.off(Bo,this._startDrag,this)},n._startDrag=function(t){var e=t.domEvent;e.touches&&e.touches.length>1||2===e.button||this.isDragging()||(this.target.on("click",this._endDrag,this),this._lastCoord=t.coordinate,this._lastPoint=t.containerPoint,this._prepareDragHandler(),this._dragHandler.onMouseDown(t.domEvent),this.target.fire("dragstart",t))},n._prepareDragHandler=function(){this._dragHandler=new Ln(this.target.getDOM(),{cancelOn:this._cancelOn.bind(this),ignoreMouseleave:!0}),this._dragHandler.on("mousedown",this._onMouseDown,this),this._dragHandler.on("dragging",this._dragging,this),this._dragHandler.on("mouseup",this._endDrag,this),this._dragHandler.enable()},n._cancelOn=function(t){var e=(t.srcElement||t.target).tagName.toLowerCase();return"button"===e||"input"===e||"select"===e||"option"===e||"textarea"===e},n._onMouseDown=function(t){Ue(t.domEvent)},n._dragging=function(t){var e=this.target,n=e.getMap()._parseEvent(t.domEvent),r=n.domEvent;if(!(r.touches&&r.touches.length>1))if(this._isDragging){var i=n.coordinate,o=n.containerPoint;this._lastCoord||(this._lastCoord=i),this._lastPoint||(this._lastPoint=o);var a=i.sub(this._lastCoord),s=o.sub(this._lastPoint);this._lastCoord=i,this._lastPoint=o,this.target.setCoordinates(this.target.getCoordinates().add(a)),n.coordOffset=a,n.pointOffset=s,e.fire("dragging",n)}else this._isDragging=!0},n._endDrag=function(t){var e=this.target,n=e.getMap();if(this._dragHandler&&(e.off("click",this._endDrag,this),this._dragHandler.disable(),delete this._dragHandler),delete this._lastCoord,delete this._lastPoint,this._isDragging=!1,n){var r=n._parseEvent(t.domEvent);e.fire("dragend",r)}},n.isDragging=function(){return!!this._isDragging},e}(wn);Fo.addInitHook("addHandler","draggable",Ho);var Go=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n._getClassName=function(){return"InfoWindow"},n.addTo=function(e){return e instanceof Kr&&(e.getInfoWindow()&&e.getInfoWindow()!==this&&e.removeInfoWindow(),e._infoWindow=this),t.prototype.addTo.call(this,e)},n.setContent=function(t){var e=this.options.content;return this.options.content=t,this.fire("contentchange",{old:e,new:t}),this.isVisible()&&this.show(this._coordinate),this},n.getContent=function(){return this.options.content},n.setTitle=function(t){var e=t;return this.options.title=t,this.fire("contentchange",{old:e,new:t}),this.isVisible()&&this.show(this._coordinate),this},n.getTitle=function(){return this.options.title},n.buildOn=function(){if(this.options.custom){if(y(this.options.content)){var t=je("div");return t.innerHTML=this.options.content,t}return this.options.content}var e=je("div");this.options.containerClass&&(e.className=this.options.containerClass),e.style.width=this._getWindowWidth()+"px",e.style.bottom="0px";var n='<em class="maptalks-ico"></em>';this.options.title&&(n+="<h2>"+this.options.title+"</h2>"),n+='<a href="javascript:void(0);" class="maptalks-close"></a><div class="maptalks-msgContent"></div>',e.innerHTML=n;var r=e.querySelector(".maptalks-msgContent");return y(this.options.content)?r.innerHTML=this.options.content:r.appendChild(this.options.content),this._onCloseBtnClick=this.hide.bind(this),Fe(e.querySelector(".maptalks-close"),"click touchend",this._onCloseBtnClick),e},n.getTransformOrigin=function(){return this.getSize().width/2+"px bottom"},n.getOffset=function(){var t=this.getSize(),e=new me(-t.width/2,0);this.options.custom?e._sub(0,t.height):e._sub(4,12);var n=this.getOwner();if(n instanceof Mi||n instanceof Pi){var r,i;if(n instanceof Mi)r=n._getPainter(),i=n.getSize();else{var o=n.getGeometries();if(!o||!o.length)return e;r=o[0]._getPainter(),i=o[0].getSize()}if(r){var a=r.getFixedExtent();e._add(a.xmax-i.width/2,a.ymin)}else e._add(0,-i.height)}return e},n.show=function(e){return this.getMap()&&this.getMap().options.enableInfoWindow?t.prototype.show.call(this,e):this},n.getEvents=function(){if(!this.options.autoCloseOn)return null;var t={};return t[this.options.autoCloseOn]=this.hide,t},n.getOwnerEvents=function(){var t=this.getOwner();if(!this.options.autoOpenOn||!t)return null;var e={};return e[this.options.autoOpenOn]=this._onAutoOpen,e},n.onRemove=function(){this.onDomRemove()},n.onDomRemove=function(){this._onCloseBtnClick&&(Be(this.getDOM().childNodes[2],"click touchend",this._onCloseBtnClick),delete this._onCloseBtnClick)},n._onAutoOpen=function(t){var e=this,n=this.getOwner();setTimeout((function(){n instanceof Mi||n instanceof zo?e.show(n.getCoordinates()):n instanceof Pi?e.show(n.findClosest(t.coordinate)):n instanceof Ti||n instanceof Oi?(e.getMap().getScale()>=8&&(t.coordinate=e._rectifyMouseCoordinte(n,t.coordinate)),e.show(t.coordinate)):e.show(t.coordinate)}),1)},n._rectifyMouseCoordinte=function(t,e){var n=this;return t instanceof Ti?this._rectifyLineStringMouseCoordinate(t,e).coordinate:t instanceof Oi?t.getGeometries().map((function(t){return n._rectifyLineStringMouseCoordinate(t,e)})).sort((function(t,e){return t.dis-e.dis}))[0].coordinate:e},n._rectifyLineStringMouseCoordinate=function(t,e){for(var n=this,r=t.getCoordinates().map((function(t){return n.getMap().coordToContainerPoint(t)})),i=this.getMap().coordToContainerPoint(e),o=1/0,a=-1,s=0,u=r.length;s<u;s++){var c=r[s],l=i.distanceTo(c);l<o&&(o=l,a=s)}var h=[];0===a?h.push(r[0],r[1]):a===r.length-1?h.push(r[a-1],r[a]):h.push(r[a-1],r[a],r[a+1]);for(var f=[],d=this.getMap().getSize(),p=d.width,m=d.height,g=0,v=h.length-1;g<v;g++){var y=h[g],_=h[g+1];if(y.x===_.x)for(var x=Math.max(0,Math.min(y.y,_.y)),b=Math.min(m,Math.max(y.y,_.y)),w=x;w<=b;w++)f.push(new me(y.x,w));else for(var M=(_.y-y.y)/(_.x-y.x),S=Math.max(0,Math.min(y.x,_.x)),T=Math.min(p,Math.max(y.x,_.x)),E=S;E<=T;E++){var A=M*(E-y.x)+y.y;f.push(new me(E,A))}}for(var C=1/0,P=-1,L=0,O=f.length;L<O;L++){var R=f[L],k=i.distanceTo(R);k<C&&(C=k,P=L)}return{dis:C,coordinate:P<0?e:this.getMap().containerPointToCoord(f[P])}},n._getWindowWidth=function(){var t=this.options.width;return t||(t=300),t},e}(zo);Go.mergeOptions({containerClass:"maptalks-msgBox",autoPan:!0,autoCloseOn:null,autoOpenOn:"click",width:300,minHeight:120,custom:!1,title:null,content:null});var Uo=function(t){fe(n,t);var e=n.prototype;function n(e,n){var r;return void 0===n&&(n={}),(r=t.call(this,n)||this)._content=e,r}return e._getClassName=function(){return"ToolTip"},e.addTo=function(e){if(n.isSupport(e))return e.on("mousemove",this.onMouseMove,this),e.on("mouseout",this.onMouseOut,this),t.prototype.addTo.call(this,e);throw new Error("Invalid geometry or UIMarker the tooltip is added to.")},e.setStyle=function(t){return this.options.containerClass=t,this},e.getStyle=function(){return this.options.containerClass},e.getContent=function(){return this._content},e.buildOn=function(){var t=je("div"),e=this.options||{};e.height&&(t.style.height=e.height+"px"),e.width&&(t.style.width=e.width+"px");var n=e.containerClass||e.cssName;return!n&&e.height&&(t.style.lineHeight=e.height+"px"),t.innerHTML='<div class="'+n+'">'+this._content+"</div>",t},e.onMouseOut=function(){clearTimeout(this._timeout),this.isVisible()&&this._removePrevDOM()},e.onMouseMove=function(t){var e=this;clearTimeout(this._timeout);var n=this.getMap();if(n){var r=n.locateByPoint(t.coordinate,-5,25);0===this.options.showTimeout?this.show(r):this._timeout=setTimeout((function(){n&&e.show(r)}),this.options.showTimeout)}},e.onRemove=function(){clearTimeout(this._timeout),this._owner&&(this._owner.off("mouseover",this.onMouseOver,this),this._owner.off("mouseout",this.onMouseOut,this))},e._getViewPoint=function(){return this.getMap().coordToViewPoint(this._coordinate,void 0,0)._add(this.options.dx,this.options.dy)},n}(zo);Uo.mergeOptions({width:0,height:0,animation:"fade",containerClass:"maptalks-tooltip",showTimeout:400});var Wo=function(t){function e(e){return t.call(this,e)||this}fe(e,t);var n=e.prototype;return n._getClassName=function(){return"Menu"},n.addTo=function(t){return t._menu&&t._menu!==this&&t.removeMenu(),t._menu=this,zo.prototype.addTo.apply(this,arguments)},n.setItems=function(t){return this.options.items=t,this},n.getItems=function(){return this.options.items||[]},n.buildOn=function(){if(this.options.custom){if(y(this.options.items)){var t=je("div");return t.innerHTML=this.options.items,t}return this.options.items}var e=je("div");this.options.containerClass&&Xe(e,this.options.containerClass),e.style.width=this._getMenuWidth()+"px";var n=this._createMenuItemDom();return e.appendChild(n),rn(e,"contextmenu",Ge),e},n.getOffset=function(){if(!this.getMap())return null;var t=this.getMap().getSize(),e=this.getMap().viewPointToContainerPoint(this._getViewPoint()),n=this.getSize(),r=0,i=0;return e.x+n.width>t.width&&(r=-n.width),e.y+n.height>t.height&&(i=-n.height),new me(r,i)},n.getTransformOrigin=function(){var t=this.getOffset()._multi(-1);return t.x+"px "+t.y+"px"},n.getEvents=function(){return{"_zoomstart _zoomend _movestart _dblclick _click":this._removePrevDOM}},n._createMenuItemDom=function(){var t=this,e=this.getMap(),n=je("ul");Xe(n,"maptalks-menu-items");var r,i,o=this.getItems();function a(n){return function(r){var i=e._parseEvent(r,"click");i.target=t,i.owner=t._owner,i.index=n,!1!==this._callback(i)&&t.hide()}}for(var s=0,u=o.length;s<u;s++){if("-"===(r=o[s])||"_"===r)Xe(i=je("li"),"maptalks-menu-splitter");else{i=je("li");var c=r.item;_(c)&&(c=c({owner:this._owner,index:s})),i.innerHTML=c,i._callback=r.click,rn(i,"click",a(s))}n.appendChild(i)}var l=this.options.maxHeight||0;return l>0&&Ye(n,"max-height: "+l+"px; overflow-y: auto;"),n},n._getMenuWidth=function(){return this.options.width||160},e}(zo);Wo.mergeOptions({containerClass:"maptalks-menu",animation:null,animationDelay:10,animationOnHide:!1,autoPan:!1,width:160,maxHeight:0,custom:!1,items:[]});var Vo={setMenu:function(t){return this._menuOptions=t,this._menu?this._menu.setOptions(t):this.on("contextmenu",this._defaultOpenMenu,this),this},openMenu:function(t){var e=this instanceof ii?this:this.getMap();return t||(t=this.getCenter()),this._menu?this._menu.show(t):this._menuOptions&&e&&(this._bindMenu(this._menuOptions),this._menu.show(t)),this},setMenuItems:function(t){return this._menuOptions||(this._menuOptions={}),Array.isArray(t)&&(this._menuOptions.custom=!1),this._menuOptions.items=t,this.setMenu(this._menuOptions),this},getMenuItems:function(){return this._menu?this._menu.getItems():this._menuOptions&&this._menuOptions.items||[]},closeMenu:function(){return this._menu&&this._menu.hide(),this},removeMenu:function(){return this.off("contextmenu",this._defaultOpenMenu,this),this._unbindMenu(),delete this._menuOptions,this},_bindMenu:function(t){return this._menu=new Wo(t),this._menu.addTo(this),this},_unbindMenu:function(){return this._menu&&(this.closeMenu(),this._menu.remove(),delete this._menu),this},_defaultOpenMenu:function(t){return this.listens("contextmenu")>1||(this.openMenu(t.coordinate),!1)}};ii.include(Vo),Kr.include(Vo);var Zo=Object.freeze({UIComponent:zo,UIMarker:Fo,InfoWindow:Go,ToolTip:Uo,Menuable:Vo,Menu:Wo}),qo=function(t){function e(e){return e&&e.position&&!y(e.position)&&(e.position=d({},e.position)),t.call(this,e)||this}fe(e,t);var n=e.prototype;return n.addTo=function(t){if(this.remove(),!t.options.control)return this;this._map=t;var e=t._panels.control;return this.__ctrlContainer=je("div"),Ye(this.__ctrlContainer,"position:absolute;overflow:visible;"),this.update(),e.appendChild(this.__ctrlContainer),this.onAdd&&this.onAdd(),this.fire("add",{dom:e}),this},n.update=function(){return this.__ctrlContainer.innerHTML="",this._controlDom=this.buildOn(this.getMap()),this._controlDom&&(this._updatePosition(),this.__ctrlContainer.appendChild(this._controlDom)),this},n.getMap=function(){return this._map},n.getPosition=function(){return d({},this._parse(this.options.position))},n.setPosition=function(t){return y(t)?this.options.position=t:this.options.position=d({},t),this._updatePosition(),this},n.getContainerPoint=function(){var t,e,n=this.getPosition(),r=this.getMap().getSize();return p(n.left)?p(n.right)||(t=r.width-parseInt(n.right)):t=parseInt(n.left),p(n.top)?p(n.bottom)||(e=r.height-parseInt(n.bottom)):e=parseInt(n.top),new me(t,e)},n.getContainer=function(){return this.__ctrlContainer},n.getDOM=function(){return this._controlDom},n.show=function(){return this.__ctrlContainer.style.display="",this},n.hide=function(){return this.__ctrlContainer.style.display="none",this},n.isVisible=function(){return this.__ctrlContainer&&""===this.__ctrlContainer.style.display},n.remove=function(){return this._map?(Ne(this.__ctrlContainer),this.onRemove&&this.onRemove(),delete this._map,delete this.__ctrlContainer,delete this._controlDom,this.fire("remove"),this):this},n._parse=function(t){var n=t;return y(t)&&(n=e.positions[n]),n},n._updatePosition=function(){var t=this.getPosition();for(var e in t||(t={top:20,left:20}),t)t.hasOwnProperty(e)&&(t[e]=parseInt(t[e]),this.__ctrlContainer.style[e]=t[e]+"px");this.fire("positionchange",{position:d({},t)})},e}(xn(Mn));qo.positions={"top-left":{top:20,left:20},"top-right":{top:20,right:20},"bottom-left":{bottom:20,left:20},"bottom-right":{bottom:20,right:20}},ii.mergeOptions({control:!0}),ii.include({addControl:function(t){return this._containerDOM.getContext||t.addTo(this),this},removeControl:function(t){return t&&t.getMap()===this?(t.remove(),this):this}});var Yo="addlayer removelayer setbaselayer baselayerremove",Jo=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.buildOn=function(){return this._attributionContainer=je("div"),this._attributionContainer.className="maptalks-attribution",this._update(),this._attributionContainer},n.onAdd=function(){this.getMap().on(Yo,this._update,this)},n.onRemove=function(){this.getMap().off(Yo,this._update,this)},n._update=function(){var t=this.getMap();if(t){var e=t._getLayers((function(t){return t.options.attribution})).reverse().map((function(t){return t.options.attribution})),n=this.options.content+(e.length>0?" - "+e.join(", "):"");this._attributionContainer.innerHTML='<span style="padding:0px 4px">'+n+"</span>"}},e}(qo);Jo.mergeOptions({position:{bottom:0,left:0},content:'<a href="http://maptalks.org" target="_blank">maptalks</a>'}),ii.mergeOptions({attribution:!0}),ii.addOnLoadHook((function(){var t=this.options.attribution||this.options.attributionControl;t&&(this.attributionControl=new Jo(t),this.addControl(this.attributionControl))}));var Xo=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.buildOn=function(){var t=this.container=je("div",this.options.containerClass),e=this.panel=je("div","panel"),n=this.button=je("button");return t.appendChild(n),t.appendChild(e),t},n.onAdd=function(){rn(this.button,"mouseover",this._show,this),rn(this.panel,"mouseleave",this._hide,this),rn(this.getMap(),"click",this._hide,this)},n.onRemove=function(){this.panel&&(on(this.button,"mouseover",this._show,this),on(this.panel,"mouseleave",this._hide,this),on(this.getMap(),"click",this._hide,this),Ne(this.panel),Ne(this.button),delete this.panel,delete this.button,delete this.container)},n._show=function(){Je(this.container,"shown")||(Xe(this.container,"shown"),this._createPanel())},n._hide=function(t){this.panel.contains(t.toElement||t.relatedTarget)||$e(this.container,this.options.containerClass)},n._createPanel=function(){this.panel.innerHTML="";var t=je("ul");this.panel.appendChild(t),this._renderLayers(this.getMap(),t)},n._renderLayers=function(t,e){var n=t.getBaseLayer(),r=t.getLayers(),i=r.length;if(n){var o=n.layers||[n],a=je("li","group"),s=je("ul"),u=je("label");u.innerHTML=this.options.baseTitle,a.appendChild(u);for(var c=0,l=o.length;c<l;c++){var h=o[c];this._isExcluded(h)&&(s.appendChild(this._renderLayer(o[c],!0)),a.appendChild(s),e.appendChild(a))}}if(i){var f=je("li","group"),d=je("ul"),p=je("label");p.innerHTML=this.options.overlayTitle,f.appendChild(p);for(var m=0;m<i;m++){var g=r[m];this._isExcluded(g)&&d.appendChild(this._renderLayer(g))}f.appendChild(d),e.appendChild(f)}},n._isExcluded=function(t){var e=t.getId(),n=this.options.excludeLayers;return!(n.length&&n.indexOf(e)>=0)},n._renderLayer=function(t,e){var n=this,r=je("li","layer"),i=je("label"),o=je("input"),a=this.getMap(),s=t.options.visible;t.options.visible=!0;var u=t.isVisible();return t.options.visible=s,r.className="layer",e?(o.type="radio",o.name="base"):o.type="checkbox",o.checked=s&&u,u||o.setAttribute("disabled","disabled"),o.onchange=function(e){if("radio"===e.target.type){var r=a.getBaseLayer(),i=r.layers;if(i)for(var o=0,s=i.length;o<s;o++){var u=i[o];u[u===t?"show":"hide"]()}else r.isVisible()||r.show();a._fireEvent("setbaselayer")}else t[e.target.checked?"show":"hide"]();n.fire("layerchange",{target:t})},r.appendChild(o),i.innerHTML=t.getId(),r.appendChild(i),r},e}(qo);Xo.mergeOptions({position:"top-right",baseTitle:"Base Layers",overlayTitle:"Layers",excludeLayers:[],containerClass:"maptalks-layer-switcher"}),ii.mergeOptions({layerSwitcherControl:!1}),ii.addOnLoadHook((function(){this.options.layerSwitcherControl&&(this.layerSwitcherControl=new Xo(this.options.layerSwitcherControl),this.addControl(this.layerSwitcherControl))}));var $o=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.buildOn=function(){var t=this.options.size;this.options.maximize||(t=[0,0]);var e=je("div"),n=this.mapContainer=je("div");n.style.width=t[0]+"px",n.style.height=t[1]+"px",n.className=this.options.containerClass;var r=this.button=je("div");return r.className=this.options.buttonClass,e.appendChild(n),e.appendChild(r),e},n.onAdd=function(){this.options.maximize&&this._createOverview(),this.getMap().on("resize moving zooming rotate dragrotating viewchange",this._update,this).on("setbaselayer",this._updateBaseLayer,this).on("spatialreferencechange",this._updateSpatialReference,this),rn(this.button,"click",this._onButtonClick,this),this._updateButtonText()},n.onRemove=function(){this.getMap().off("resize moving zooming rotate dragrotating viewchange",this._update,this).off("setbaselayer",this._updateBaseLayer,this).off("spatialreferencechange",this._updateSpatialReference,this),this._overview&&(this._overview.remove(),delete this._overview,delete this._perspective),on(this.button,"click",this._onButtonClick,this)},n.maxmize=function(){var t=this.options.size,e=this.mapContainer;return e.style.width=t[0]+"px",e.style.height=t[1]+"px",this._createOverview(),this},n.minimize=function(){this._overview&&this._overview.remove(),delete this._overview,delete this._perspective;var t=this.mapContainer;return t.style.width="0px",t.style.height="0px",this},n.getOverviewMap=function(){return this._overview},n._onButtonClick=function(){this._overview?this.minimize():this.maxmize(),this._updateButtonText()},n._updateButtonText=function(){this._overview?this.button.innerHTML="-":this.button.innerHTML="+"},n._createOverview=function(){var t=this.getMap(),e=this.mapContainer,n=t.config();d(n,{center:t.getCenter(),zoom:this._getOverviewZoom(),zoomAnimationDuration:150,pitch:0,bearing:0,scrollWheelZoom:!1,checkSize:!1,doubleClickZoom:!1,touchZoom:!1,control:!1,draggable:!1,maxExtent:null}),this._overview=new ii(e,n),this._updateBaseLayer(),this._perspective=new bi(this._getPerspectiveCoords(),{draggable:!0,cursor:"move",symbol:this.options.symbol}).on("dragend",this._onDragEnd,this),new eo("perspective_layer",this._perspective).addTo(this._overview),this.fire("load")},n._getOverviewZoom=function(){var t=this.getMap(),e=t.getZoom(),n=t.getMinZoom(),r=this.options.level;if(r>0){for(var i=r;i>0;i--)if(e-i>=n)return e-i}else for(var o=r;o<0;o++)if(e-o>=n)return e-o;return e},n._onDragEnd=function(){var t=this._perspective.getCenter();this._overview.setCenter(t),this.getMap().panTo(t)},n._getPerspectiveCoords=function(){var t=this.getMap();return t.getContainerExtent().toArray().map((function(e){return t.containerPointToCoordinate(e)}))},n._update=function(){if(this._overview){Ze(this._overview._containerDOM);var t=this._getPerspectiveCoords();this._perspective.setCoordinates(t),this._overview.setCenterAndZoom(this.getMap().getCenter(),this._getOverviewZoom())}},n._updateSpatialReference=function(){if(this._overview){var t=this.getMap().options.spatialReference;this._overview.setSpatialReference(t)}},n._updateBaseLayer=function(){if(this._overview){var t=this.getMap().getBaseLayer();if(t){var e=t.layers,n=0;if(e)for(var r=0,i=e.length;r<i;r++)if(e[r].isVisible()){n=r;break}var o=t.toJSON(),a=null;e?(a=o.layers[n].options).visible=!0:a=o.options,this._overview.setMinZoom(a.minZoom||null).setMaxZoom(a.maxZoom||null),delete a.minZoom,delete a.maxZoom,delete o.options.canvas,o.options.visible=!0,o.options.renderer="canvas";var s=ei.fromJSON(o);for(var u in t)_(t[u])&&t.hasOwnProperty(u)&&t[u]!==t.constructor.prototype[u]&&(s[u]=t[u]);this._overview.setBaseLayer(s)}else this._overview.setBaseLayer(null)}},e}(qo);$o.mergeOptions({level:4,position:{right:1,bottom:1},size:[300,200],maximize:!0,symbol:{lineWidth:3,lineColor:"#1bbc9b",polygonFill:"#1bbc9b",polygonOpacity:.4},containerClass:"maptalks-overview",buttonClass:"maptalks-overview-button"}),ii.mergeOptions({overviewControl:!1}),ii.addOnLoadHook((function(){this.options.overviewControl&&(this.overviewControl=new $o(this.options.overviewControl),this.addControl(this.overviewControl))}));var Qo=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.buildOn=function(){var t;if(this.options.custom)y(this.options.content)?(t=je("div")).innerHTML=this.options.content:t=this.options.content;else{if(t=je("div","maptalks-panel"),this.options.closeButton){var e=je("a","maptalks-close");e.href="javascript:;",e.onclick=function(){t.style.display="none"},t.appendChild(e)}var n=je("div","maptalks-panel-content");n.innerHTML=this.options.content,t.appendChild(n)}return this.draggable=new Ln(t,{cancelOn:this._cancelOn.bind(this),ignoreMouseleave:!0}),this.draggable.on("dragstart",this._onDragStart,this).on("dragging",this._onDragging,this).on("dragend",this._onDragEnd,this),this.options.draggable&&this.draggable.enable(),t},n.update=function(){return this.draggable&&(this.draggable.disable(),delete this.draggable),qo.prototype.update.call(this)},n.setContent=function(t){var e=this.options.content;return this.options.content=t,this.fire("contentchange",{old:e,new:t}),this.isVisible()&&this.update(),this},n.getContent=function(){return this.options.content},n._cancelOn=function(t){var e=(t.srcElement||t.target).tagName.toLowerCase();return"button"===e||"input"===e||"select"===e||"option"===e||"textarea"===e},n._onDragStart=function(t){this._startPos=t.mousePos,this._startPosition=d({},this.getPosition()),this.fire("dragstart",t)},n._onDragging=function(t){var e=t.mousePos.sub(this._startPos),n=this._startPosition,r=this.getPosition();p(r.top)||(r.top=parseInt(n.top)+e.y),p(r.bottom)||(r.bottom=parseInt(n.bottom)-e.y),p(r.left)||(r.left=parseInt(n.left)+e.x),p(r.right)||(r.right=parseInt(n.right)-e.x),this.setPosition(r),this.fire("dragging",t)},n._onDragEnd=function(t){delete this._startPos,delete this._startPosition,this.fire("dragend",t)},n._getConnectPoints=function(){var t=this.getMap(),e=this.getContainerPoint(),n=this.getDOM(),r=parseInt(n.clientWidth),i=parseInt(n.clientHeight);return[t.containerPointToCoordinate(e.add(r/2,0)),t.containerPointToCoordinate(e.add(r,i/2)),t.containerPointToCoordinate(e.add(r/2,i)),t.containerPointToCoordinate(e.add(0,i/2))]},e}(qo);Qo.mergeOptions({position:"top-right",draggable:!0,custom:!1,content:"",closeButton:!0});var Ko=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.buildOn=function(t){return this._map=t,this._scaleContainer=je("div",this.options.containerClass),this._addScales(),t.on("zoomend",this._update,this),this._map._loaded&&this._update(),this._scaleContainer},n.onRemove=function(){this.getMap().off("zoomend",this._update,this)},n._addScales=function(){var t="border: 2px solid #000000;border-top: none;line-height: 1.1;padding: 0px;color: #000000;font-size: 11px;text-align:center;white-space: nowrap;overflow: hidden;-moz-box-sizing: content-box;box-sizing: content-box;background: #fff; background: rgba(255, 255, 255, 0);";this.options.metric&&(this._mScale=ze("div",this.options.containerClass?null:t,this._scaleContainer)),this.options.imperial&&(this._iScale=ze("div",this.options.containerClass?null:t,this._scaleContainer))},n._update=function(){var t=this._map.pixelToDistance(this.options.maxWidth,0);this._updateScales(t)},n._updateScales=function(t){this.options.metric&&t&&this._updateMetric(t),this.options.imperial&&t&&this._updateImperial(t)},n._updateMetric=function(t){var e=this._getRoundNum(t),n=e<1e3?e+" m":e/1e3+" km";this._updateScale(this._mScale,n,e/t)},n._updateImperial=function(t){var e,n,r,i=3.2808399*t;i>5280?(e=i/5280,n=this._getRoundNum(e),this._updateScale(this._iScale,n+" mile",n/e)):(r=this._getRoundNum(i),this._updateScale(this._iScale,r+" feet",r/i))},n._updateScale=function(t,e,n){t.style.width=Math.round(this.options.maxWidth*n)+"px",t.innerHTML=e},n._getRoundNum=function(t){var e=Math.pow(10,(Math.floor(t)+"").length-1),n=t/e;return e*(n=n>=10?10:n>=5?5:n>=3?3:n>=2?2:1)},e}(qo);Ko.mergeOptions({position:"bottom-left",maxWidth:100,metric:!0,imperial:!1,containerClass:null}),ii.mergeOptions({scaleControl:!1}),ii.addOnLoadHook((function(){this.options.scaleControl&&(this.scaleControl=new Ko(this.options.scaleControl),this.addControl(this.scaleControl))}));var ta=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.buildOn=function(t){this._map=t;var e=je("div"),n=je("ul","maptalks-toolbar-hx");e.appendChild(n),this.options.vertical?Xe(e,"maptalks-toolbar-vertical"):Xe(e,"maptalks-toolbar-horizonal");var r=this;function i(t,e,n,i){var o=r._getItems()[e];return function(r){return Ue(r),t({target:o,index:e,childIndex:n,dom:i})}}var o=this.options.items;if(U(o))for(var a=0,s=o.length;a<s;a++){var u=o[a],c=je("li");if(28!==this.options.height&&(c.style.lineHeight=this.options.height+"px"),c.style.height=this.options.height+"px",c.style.cursor="pointer",tn(u.item)){c.style.textAlign="center";var l=en("div",u.item);c.innerHTML='<div style="margin-top:'+(this.options.height-l.height)/2+'px;">'+u.item+"</div>"}else c.innerHTML=u.item;if(u.click&&rn(c,"click",i(u.click,a,null,c)),U(u.children)){var h=this._createDropMenu(a);c.appendChild(h),c._menu=h,rn(c,"mouseover",(function(){this._menu.style.display=""})),rn(c,"mouseout",(function(){this._menu.style.display="none"}))}n.appendChild(c)}return e},n._createDropMenu=function(t){var e=this;function n(t,n,r){var i=e._getItems()[n].children[r];return function(e){return Ue(e),t({target:i,index:n,childIndex:r})}}var r=je("div","maptalks-dropMenu"),i=this._getItems(),o=i.length,a=je("ul"),s=i[t].children;t===o-1&&s&&(r.style.cssText="right: 0px;",a.style.cssText="right: 0px;position: absolute;",this.options.reverseMenu&&(a.style.bottom=0)),r.appendChild(je("em","maptalks-ico"));for(var u=0,c=0,l=s.length;c<l;c++){var h=Me(s[c].item,"12px");h.width>u&&(u=h.width)}for(var f=0,d=s.length;f<d;f++){var p=s[f],m=je("li");m.innerHTML='<a href="javascript:;">'+p.item+"</a>",m.style.cursor="pointer",m.style.width=u+24+"px",rn(m.childNodes[0],"click",n(p.click,t,f)),a.appendChild(m)}if(this.options.vertical){var g=u<95?95:u;this.options.reverseMenu?r.style.right=-(g+20)+"px":r.style.left=-(g+20)+"px"}else this.options.reverseMenu?r.style.bottom="28px":r.style.top="28px";return r.appendChild(a),r.style.display="none",r},n._getItems=function(){return this.options.items||[]},e}(qo);ta.mergeOptions({height:28,vertical:!1,position:"top-right",reverseMenu:!1,items:{}});var ea=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.buildOn=function(t){var e=this.options,n=je("div","maptalks-zoom");if(e.zoomLevel){var r=je("span","maptalks-zoom-zoomlevel");n.appendChild(r),this._levelDOM=r}var i=je("div","maptalks-zoom-slider"),o=je("a","maptalks-zoom-zoomin");if(o.href="javascript:;",o.innerHTML="+",i.appendChild(o),this._zoomInButton=o,e.slider){var a=je("div","maptalks-zoom-slider-box"),s=je("div","maptalks-zoom-slider-ruler"),u=je("span","maptalks-zoom-slider-reading"),c=je("span","maptalks-zoom-slider-dot");s.appendChild(u),a.appendChild(s),a.appendChild(c),i.appendChild(a),this._sliderBox=a,this._sliderRuler=s,this._sliderReading=u,this._sliderDot=c}var l=je("a","maptalks-zoom-zoomout");return l.href="javascript:;",l.innerHTML="-",i.appendChild(l),this._zoomOutButton=l,n.appendChild(i),t.on("_zoomend _zooming _zoomstart _spatialreferencechange",this._update,this),this._update(),this._registerDomEvents(),n},n.onRemove=function(){this.getMap().off("_zoomend _zooming _zoomstart _spatialreferencechange",this._update,this),this._zoomInButton&&on(this._zoomInButton,"click",this._onZoomInClick,this),this._zoomOutButton&&on(this._zoomOutButton,"click",this._onZoomOutClick,this),this._sliderRuler&&(on(this._sliderRuler,"click",this._onClickRuler,this),this.dotDragger.disable(),delete this.dotDragger)},n._update=function(){var t=this.getMap();if(this._sliderBox){var e=10*(t.getMaxZoom()-t.getMinZoom());this._sliderBox.style.height=e+16+"px",this._sliderRuler.style.height=e+8+"px",this._sliderRuler.style.cursor="pointer";var n=10*(t.getMaxZoom()-t.getZoom());this._sliderReading.style.height=10*(t.getZoom()-t.getMinZoom()+1)+"px",this._sliderDot.style.top=n+"px"}this._updateText()},n._updateText=function(){if(this._levelDOM){var t=this.getMap().getZoom();g(t)||(t=Math.floor(10*t)/10),this._levelDOM.innerHTML=t}},n._registerDomEvents=function(){this._zoomInButton&&rn(this._zoomInButton,"click",this._onZoomInClick,this),this._zoomOutButton&&rn(this._zoomOutButton,"click",this._onZoomOutClick,this),this._sliderRuler&&(rn(this._sliderRuler,"click",this._onClickRuler,this),this.dotDragger=new Ln(this._sliderDot,{ignoreMouseleave:!0}),this.dotDragger.on("dragstart",this._onDotDragstart,this).on("dragging dragend",this._onDotDrag,this).enable())},n._onZoomInClick=function(t){Ge(t),this.getMap().zoomIn()},n._onZoomOutClick=function(t){Ge(t),this.getMap().zoomOut()},n._onClickRuler=function(t){Ge(t);var e=this.getMap(),n=qe(t,this._sliderRuler).y,r=e.getMaxZoom(),i=Math.floor(r-n/10);e.setZoom(i)},n._onDotDragstart=function(t){Ge(t.domEvent);var e=this.getMap(),n=e.getSize().toPoint()._multi(.5);e.onZoomStart(e.getZoom(),n)},n._onDotDrag=function(t){Ge(t.domEvent);var e=this.getMap(),n=e.getSize().toPoint()._multi(.5),r=qe(t.domEvent,this._sliderRuler),i=e.getMaxZoom(),o=e.getMinZoom(),a=r.y,s=i-a/10;i<s?(s=i,a=0):o>s&&(s=o,a=10*(i-o)),"dragging"===t.type?e.onZooming(s,n,1):"dragend"===t.type&&(this.options.seamless?e.onZoomEnd(s,n):e.onZoomEnd(Math.round(s),n)),this._sliderDot.style.top=a+"px",this._sliderReading.style.height=10*(e.getZoom()-o+1)+"px",this._updateText()},e}(qo);ea.mergeOptions({position:"top-left",slider:!0,zoomLevel:!0,seamless:!1}),ii.mergeOptions({zoomControl:!1}),ii.addOnLoadHook((function(){this.options.zoomControl&&(this.zoomControl=new ea(this.options.zoomControl),this.addControl(this.zoomControl))}));var na=Object.freeze({Control:qo,Attribution:Jo,LayerSwitcher:Xo,Overview:$o,Panel:Qo,Scale:Ko,Toolbar:ta,Zoom:ea}),ra=function(){function t(t,e,n,r){Array.isArray(t)?(this.scale={x:t[0],y:t[1]},this.origin={x:t[2],y:t[3]}):(this.scale={x:t,y:e},this.origin={x:n,y:r})}return t.getDefault=function(t){return"baidu"===t.code.toLowerCase()?"baidu":t.code.toLowerCase()==="EPSG:4326".toLowerCase()?"tms-global-geodetic":"identity"===t.code.toLowerCase()?[1,-1,0,0]:"web-mercator"},t}(),ia=6378137*Math.PI;d(ra,{"web-mercator":new ra([1,-1,-ia,ia]),"tms-global-mercator":new ra([1,1,-ia,-ia]),"tms-global-geodetic":new ra([1,1,-180,-90]),baidu:new ra([1,1,0,0])});for(var oa=function(){function t(t,e,n,r){this.map=t,this.tileSize=r,this.fullExtent=n,this.prepareTileInfo(e,n),this._xScale=n.right>=n.left?1:-1,this._yScale=n.top>=n.bottom?1:-1,this._pointOrigin=t._prjToPoint(new me(this.tileSystem.origin),t.getGLZoom()),this._glRes=t.getResolution(t.getGLZoom())}var e=t.prototype;return e.prepareTileInfo=function(t,e){if(y(t)?t=ra[t.toLowerCase()]:Array.isArray(t)&&(t=new ra(t)),!t)throw new Error("Invalid TileSystem");this.tileSystem=t;var n=e.right>e.left?1:-1,r=e.top>e.bottom?-1:1,i=t.origin.x,o=t.origin.y;this.transformation=new qn([n,r,i,o])},e._getTileNum=function(t,e){var n=this.tileSystem,r=this.tileSize,i=Math.floor(1e-7*n.scale.x+t.x/(r.width*e)),o=Math.ceil(1e-7*n.scale.y+t.y/(r.height*e));return{x:n.scale.x*i,y:n.scale.y*o}},e.getTileIndex=function(t,e,n){var r=this.tileSystem,i=this.transformation.transform(t,1),o=this._getTileNum(i,e);return r.scale.x<0&&(o.x-=1),r.scale.y>0&&(o.y-=1),this.getNeighorTileIndex(o.x,o.y,0,0,e,n)},e.getNeighorTileIndex=function(t,e,n,r,i,o){var a=this.tileSystem,s=t+a.scale.x*n,u=e-a.scale.y*r,c=!1,l=s,h=u,f=this._getTileFullIndex(i);return o&&(!0!==o&&"x"!==o||(f.xmax===f.xmin?s=f.xmin:s<f.xmin?(s=f.xmax-(f.xmin-s)%(f.xmax-f.xmin))===f.xmax&&(s=f.xmin):s>=f.xmax&&(s=f.xmin+(s-f.xmin)%(f.xmax-f.xmin))),!0!==o&&"y"!==o||(f.ymax===f.ymin?u=f.ymin:u>=f.ymax?u=f.ymin+(u-f.ymin)%(f.ymax-f.ymin):u<f.ymin&&(u=f.ymax-(f.ymin-u)%(f.ymax-f.ymin))===f.ymax&&(u=f.ymin))),(s<f.xmin||s>f.xmax||u>f.ymax||u<f.ymin)&&(c=!0),{x:s,y:u,idx:l,idy:h,out:c}},e._getTileFullIndex=function(t){if(this._tileFullIndex||(this._tileFullIndex={}),this._tileFullIndex[t])return this._tileFullIndex[t];var e=this.fullExtent,n=this.transformation,r=this._getTileNum(n.transform(new On(e.left,e.top),1),t),i=this._getTileNum(n.transform(new On(e.right,e.bottom),1),t),o=this.tileSystem;return o.scale.x<0&&(r.x-=1,i.x-=1),o.scale.y>0&&(r.y-=1,i.y-=1),this._tileFullIndex[t]=new Vn(r,i),this._tileFullIndex[t]},e.getTilePrjNW=function(t,e,n){var r=this.tileSystem,i=this.tileSize,o=r.origin.y+this._yScale*r.scale.y*(e+(1===r.scale.y?1:0))*n*i.height,a=r.origin.x+this._xScale*r.scale.x*(t+(1===r.scale.x?0:1))*n*i.width;return new On(a,o)},e.getTilePointNW=function(t,e,n){var r=this._glRes/n,i=this.tileSystem,o=this.tileSize,a=this._pointOrigin.y*r+this._yScale*i.scale.y*(e+(1===i.scale.y?1:0))*o.height,s=this._pointOrigin.x*r+this._xScale*i.scale.x*(t+(1===i.scale.x?0:1))*o.width;return new me(s,a)},e.getTilePrjSE=function(t,e,n){var r=this.tileSystem,i=this.tileSize,o=r.origin.y+this._yScale*r.scale.y*(e+(1===r.scale.y?0:1))*n*i.height,a=r.origin.x+this._xScale*r.scale.x*(t+(1===r.scale.x?1:0))*n*i.width;return new On(a,o)},e.getTilePointSE=function(t,e,n){var r=this._glRes/n,i=this.tileSystem,o=this.tileSize,a=this._pointOrigin.y*r+this._yScale*i.scale.y*(e+(1===i.scale.y?0:1))*o.height,s=this._pointOrigin.x*r+this._xScale*i.scale.x*(t+(1===i.scale.x?1:0))*o.width;return new me(s,a)},e.getTilePrjExtent=function(t,e,n){var r=this.getTilePrjNW(t,e,n),i=this.getTilePrjSE(t,e,n);return new Vn(r,i)},t}(),aa=[],sa=0;sa<6;sa++)aa[sa]=[];var ua=[];function ca(t,e,n){!function(t){var e=t,n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],c=e[7],l=e[8],h=e[9],f=e[10],d=e[11],p=e[12],m=e[13],g=e[14],v=e[15];la(aa[0],o-n,c-a,d-l,v-p),la(aa[1],o+n,c+a,d+l,v+p),la(aa[2],o+r,c+s,d+h,v+m),la(aa[3],o-r,c-s,d-h,v-m),la(aa[4],o-i,c-u,d-f,v-g),la(aa[5],o+i,c+u,d+f,v+g)}(t);for(var r=0;r<6;r++)if(!n||"0"!==n.charAt(r)){var i=aa[r];if(ua[0]=i[0]>0?e[1][0]:e[0][0],ua[1]=i[1]>0?e[1][1]:e[0][1],ua[2]=i[2]>0?e[1][2]:e[0][2],ha(i,ua)<0)return!1}return!0}function la(t,e,n,r,i){return t[0]=e*(1/6),t[1]=n*(1/6),t[2]=r*(1/6),t[3]=i*(1/6),t}function ha(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]+t[3]}var fa="undefined"!=typeof Set,da=function(){function t(){this._table=fa?new Set:{}}var e=t.prototype;return e.add=function(t){fa?this._table.add(t):this._table[t]=!0},e.has=function(t){return fa?this._table.has(t):this._table[t]},e.reset=function(){fa?this._table.clear():this._table={}},t}(),pa={urlTemplate:null,subdomains:null,errorUrl:null,repeatWorld:!0,background:!0,backgroundZoomDiff:6,loadingLimitOnInteracting:3,tileRetryCount:0,placeholder:!1,crossOrigin:null,tileSize:[256,256],offset:[0,0],tileSystem:null,fadeAnimation:!A,debug:!1,spatialReference:null,maxCacheSize:256,renderer:he.webgl?"gl":"canvas",clipByPitch:!0,maxAvailableZoom:null,cascadeTiles:!0,zoomOffset:0},ma=/\{ *([\w_]+) *\}/g,ga=new me(0,0),va=new me(0,0),ya=new me(0,0),_a=new me(0,0),xa=new me(0,0),ba=new me(0,0),wa=new me(0,0),Ma=[[0,0,0],[0,0,0]],Sa=[],Ta=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t),e.fromJSON=function(t){return t&&"TileLayer"===t.type?new e(t.id,t.options):null};var n=e.prototype;return n.getTileSize=function(){if(this._tileSize)return this._tileSize;var t=this.options.tileSize;return m(t)&&(t=[t,t]),this._tileSize=new ge(t),this._tileSize},n.getTiles=function(t,e){var n=this.getMap(),r=n.getPitch(),i=e&&e.getRenderer(),o=n.getContainerExtent(),a=[],s=0,u=this.getMinZoom(),c=n.options.cascadePitches[0],l=n.options.cascadePitches[1],h=Math.floor(n._getVisualHeight(l)),f=p(t)?this._getTileZoom(n.getZoom()):t;if(this._visitedTiles=new da,this._coordCache={},!p(t)||!this.options.cascadeTiles||r<=c||!p(u)&&f<=u){var d=r<=l?o:new Zn(0,n.height-h,n.width,n.height),m=this._getTiles(f,d,2,i);return m&&(s+=m.tiles.length,a.push(m)),{tileGrids:a,count:s}}var g=Math.floor(n._getVisualHeight(c)),v=new Zn(0,n.height-g,n.width,n.height),y=this._getTiles(f,v,0,i);s+=y?y.tiles.length:0,a.push(y);var _,x,b=v.ymin,w=n.getSpatialReference().getZoomDirection(),M=w;if(r>l){f-M<=u&&(M=0);var S=new Zn(0,n.height-h,n.width,b);s+=(_=this._getTiles(f-M,S,1,i))?_.tiles.length:0,b=S.ymin,M+=4*w}if(f-M>=u){var T=new Zn(0,o.ymin,n.width,b);s+=(x=this._getTiles(f-M,T,2,i))?x.tiles.length:0,a.push(x)}return _&&x&&(a[1]=x,a[2]=_),{tileGrids:a,count:s}},n.getTileUrl=function(t,e,n){var r=this.options.urlTemplate,i="";if(this.options.subdomains){var o=this.options.subdomains;if(U(o)){var a=(t+e)%o.length;a<0&&(a=0),i=o[a]}}if(_(r))return r(t,e,n,i);var s={x:t,y:e,z:n,s:i};return r.replace(ma,(function(t,e){var n=s[e];if(void 0===n)throw new Error("No value provided for variable "+t);return"function"==typeof n&&(n=n(s)),n}))},n.clear=function(){return this._renderer&&this._renderer.clear(),this.fire("clear"),this},n.toJSON=function(){return{type:this.getJSONType(),id:this.getId(),options:this.config()}},n.getSpatialReference=function(){var t=this.getMap();return!t||this.options.spatialReference&&!Qr.equals(this.options.spatialReference,t.options.spatialReference)?(this._sr=this._sr||new Qr(this.options.spatialReference),void 0===this._srMinZoom&&(this._srMinZoom=this._sr.getMinZoom(),this._srMaxZoom=this._sr.getMaxZoom()),this._sr):t.getSpatialReference()},n.getMinZoom=function(){return this.getSpatialReference()!==this.getMap().getSpatialReference()?Math.max(t.prototype.getMinZoom.call(this),this._srMinZoom):t.prototype.getMinZoom.call(this)},n.getMaxZoom=function(){return this.getSpatialReference()!==this.getMap().getSpatialReference()?Math.min(t.prototype.getMaxZoom.call(this),this._srMaxZoom):t.prototype.getMaxZoom.call(this)},n._getTileZoom=function(t){g(t)||(t=Math.round(t));var e=this.options.maxAvailableZoom;return!p(e)&&t>e&&(t=e),t},n._getTiles=function(t,e,n,r){var i=this,o=this.getMap(),a=t,s=o.projViewMatrix;n<2&&(0===n&&(a-=1),s=0===n?o.cascadeFrustumMatrix0:1===n?o.cascadeFrustumMatrix1:o.projViewMatrix);var u=a+this.options.zoomOffset,c=this._getTileOffset(u),l=c[0]||c[1],h={zoom:a,extent:null,offset:c,tiles:[]};if(u<0)return h;var f=this.getMinZoom(),d=this.getMaxZoom();if(!(o&&this.isVisible()&&o.width&&o.height))return h;if(!p(f)&&a<f||!p(d)&&a>d)return h;var m=this._getTileConfig();if(!m)return h;var g={zoom:c},v=this.getSpatialReference(),y=o.getSpatialReference(),_=v.getResolution(u),x=o.getGLScale(a),b=v===y&&this.options.repeatWorld,w=e.convertTo((function(t){if(t.y>0&&t.y<o.height){var e=(0===t.x?0:1)+t.y;i._coordCache[e]||(i._coordCache[e]=o._containerPointToPoint(t)),i._coordCache[e]}return o._containerPointToPoint(t,void 0,ga)})),M=this._getMask2DExtent();if(M){var S=M.intersection(w);if(!S)return h;e=S.convertTo((function(t){return o._pointToContainerPoint(t,void 0,0,ga)}))}var T,E=o._containerPointToPrj(e.getCenter(),va),A=o._prjToPoint(E,u,ya);T=l?this._project(o._pointToPrj(A._add(c),u,ya),ya):this._project(E,ya);var C=o.getGLScale()/o.getGLScale(u);_a.x=w.xmin*C,_a.y=w.ymax*C,xa.x=w.xmax*C,xa.y=w.ymin*C;for(var P=this._project(o._pointToPrj(_a._add(c),u,_a),_a),L=this._project(o._pointToPrj(xa._add(c),u,xa),xa),O=m.getTileIndex(T,_,b),R=m.getTileIndex(P,_,b),k=m.getTileIndex(L,_,b),I=Math.ceil(Math.abs(O.idy-R.idy)),D=Math.ceil(Math.abs(O.idx-R.idx)),j=Math.ceil(Math.abs(O.idy-k.idy)),z=Math.ceil(Math.abs(O.idx-k.idx)),N=(I+j+1)*(D+z+1),F=this.getTileSize(),B=this.getRenderer()||r,H=this._getTileConfig().tileSystem.scale,G=[],U=new Zn,W=new me(0,0),V=-I;V<=j;V++)for(var Z=-D,q=-1/0,Y=!1;Z>=q&&Z<=z;){var J=m.getNeighorTileIndex(O.idx,O.idy,Z,V,_,b);q===-1/0?Z++:Z--;var X=this._getTileId(J.idx,J.idy,a);if(!(J.out||this._visitedTiles&&this._visitedTiles.has(X))){var $=B&&B.isTileCachedOrLoading(X);$&&($=$.info);var Q=void 0;if($){var K=$.extent2d;W.set(K.xmin,K.ymax),Q=W}else if(this._hasOwnSR){var tt=m.getTilePrjNW(J.x,J.y,_);Q=o._prjToPoint(this._unproject(tt,xa),a)}else Q=m.getTilePointNW(J.x,J.y,_);var et=void 0,nt=void 0;if(v===y)et=F.width,nt=F.height;else{var rt=void 0;if(this._hasOwnSR){var it=m.getTilePrjSE(J.x,J.y,_);rt=o._prjToPoint(this._unproject(it,xa),a,xa)}else rt=m.getTilePointSE(J.x,J.y,_);et=Math.ceil(Math.abs(rt.x-Q.x)),nt=Math.ceil(Math.abs(rt.y-Q.y))}var ot=H.x*(J.idx-J.x)*et,at=H.y*(J.idy-J.y)*nt;$||!ot&&!at||Q._add(ot,at);var st=$&&$.extent2d||new Zn(Q.x,Q.y-nt,Q.x+et,Q.y);(N<=4||Y||this._isTileInExtent(s,st,c,x))&&(this._visitedTiles&&0===n&&this._visitedTiles.add(X),0===n?(this._splitTiles(s,G,B,J,a+1,st,ot,at,g,r),U._combine(st)):($?($.offset[0]=c[0],$.offset[1]=c[1]):($={z:a,x:J.x,y:J.y,extent2d:st,offset:c,id:X,url:this.getTileUrl(J.x,J.y,a)},r&&($.layer=this.getId())),G.push($),U._combine(st)),q===-1/0?(q=Z,Z=z):Y||(Y=!0))}}if(G.length){var ut=o._containerPointToPoint(e.getCenter(),a,ga)._add(c),ct=new me(0,0),lt=new me(0,0);G.sort((function(t,e){return ct.set((t.extent2d.xmin+t.extent2d.xmax)/2,(t.extent2d.ymin+t.extent2d.ymax)/2),lt.set((e.extent2d.xmin+e.extent2d.xmax)/2,(e.extent2d.ymin+e.extent2d.ymax)/2),ct.distanceTo(ut)-lt.distanceTo(ut)}))}return{offset:c,zoom:t,extent:U,tiles:G}},n._splitTiles=function(t,e,n,r,i,o,a,s,u,c){var l=this._getTileConfig().tileSystem.scale.y,h=this.getMap().getGLScale(i),f=ba.set(2*o.xmin,l<0?2*o.ymax:2*o.ymin),d=o.getWidth(),p=o.getHeight(),m=2*r.idx,g=2*r.idy,v=2*r.x,y=2*r.y,_=this._checkAndAddTile(t,n,m,g,v,y,i,0,0,d,p,f,h,u,c);_&&e.push(_),(_=this._checkAndAddTile(t,n,m,g,v,y,i,0,1,d,p,f,h,u,c))&&e.push(_),(_=this._checkAndAddTile(t,n,m,g,v,y,i,1,0,d,p,f,h,u,c))&&e.push(_),(_=this._checkAndAddTile(t,n,m,g,v,y,i,1,1,d,p,f,h,u,c))&&e.push(_)},n._checkAndAddTile=function(t,e,n,r,i,o,a,s,u,c,l,h,f,d,p){var m=this._getTileId(n+s,r+u,a);if(this._visitedTiles&&this._visitedTiles.has(m))return null;var g=d[a];g||(g=d[a]=this._getTileOffset(a));var v=this._getTileConfig().tileSystem.scale.y,y=new Zn(h.x+s*c,h.y+v*u*l,h.x+(s+1)*c,h.y+v*(u+1)*l);if(!this._isSplittedTileInExtent(t,y,g,f))return null;var _=e&&e.isTileCachedOrLoading(m);return _?_=_.info:(_={z:a,x:i+s,y:o+u,extent2d:y,id:m,offset:g,url:this.getTileUrl(i+s,o+u,a+this.options.zoomOffset)},p&&(_.layer=this.getId())),_},n._getTileOffset=function(t){var e=this.options.offset;return _(e)&&(e=e(t)),e},n._getTileId=function(t,e,n,r){return(r||this.getId())+"_"+e+"_"+t+"_"+n},n._project=function(t,e){if(this._hasOwnSR){var n=this.getMap().getProjection();return this.getSpatialReference().getProjection().project(n.unproject(t,e),e)}return t},n._unproject=function(t,e){if(this._hasOwnSR){var n=this.getMap(),r=this.getSpatialReference(),i=n.getProjection(),o=r.getProjection();return i.project(o.unproject(t,e),e)}return t},n._initTileConfig=function(){var t=this.getMap(),e=this.getTileSize(),n=this.getSpatialReference(),r=n.getProjection(),i=n.getFullExtent();this._defaultTileConfig=new oa(t,ra.getDefault(r),i,e),this.options.tileSystem&&(this._tileConfig=new oa(t,this.options.tileSystem,i,e)),this._hasOwnSR=n!==t.getSpatialReference()},n._getTileConfig=function(){return this._defaultTileConfig||this._initTileConfig(),this._tileConfig||this._defaultTileConfig},n._bindMap=function(e){var n=e.getBaseLayer();return n===this&&(n.options.hasOwnProperty("forceRenderOnMoving")||this.config({forceRenderOnMoving:!0})),t.prototype._bindMap.apply(this,arguments)},n._isTileInExtent=function(t,e,n,r){var i,o=this.getMap();if(t!==o.projViewMatrix){var a=e.getCenter(wa)._sub(n[0],n[1])._multi(r);vo(Sa,a.x,a.y,0),i=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[3]*r+n[7]*i+n[11]*o+n[15];return a=a||1,t[0]=(n[0]*r+n[4]*i+n[8]*o+n[12])/a,t[1]=(n[1]*r+n[5]*i+n[9]*o+n[13])/a,t[2]=(n[2]*r+n[6]*i+n[10]*o+n[14])/a,t}(Sa,Sa,o.projViewMatrix)[1]<0?o.projViewMatrix:t}else i=o.projViewMatrix;return Ma[0][0]=(e.xmin-n[0])*r,Ma[0][1]=(e.ymin-n[1])*r,Ma[1][0]=(e.xmax-n[0])*r,Ma[1][1]=(e.ymax-n[1])*r,ca(i,Ma)},n._isSplittedTileInExtent=function(t,e,n,r){var i=this.getMap();return Ma[0][0]=(e.xmin-n[0])*r,Ma[0][1]=(e.ymin-n[1])*r,Ma[1][0]=(e.xmax-n[0])*r,Ma[1][1]=(e.ymax-n[1])*r,ca(i.projViewMatrix,Ma)},n.getEvents=function(){return{spatialreferencechange:this._onSpatialReferenceChange}},n._onSpatialReferenceChange=function(){delete this._tileConfig,delete this._defaultTileConfig,delete this._sr;var t=this.getRenderer();t&&t.clear()},e}(ei);Ta.registerJSONType("TileLayer"),Ta.mergeOptions(pa);var Ea=function(t){function e(e,n,r){var i;return(i=t.call(this,e,r)||this).layers=n||[],i._checkChildren(),i.layerMap={},i._groupChildren=[],i}fe(e,t),e.fromJSON=function(t){if(!t||"GroupTileLayer"!==t.type)return null;var n=t.layers.map((function(t){return ei.fromJSON(t)}));return new e(t.id,n,t.options)};var n=e.prototype;return n.getLayers=function(){return this.layers},n.toJSON=function(){return{type:this.getJSONType(),id:this.getId(),layers:this.layers.map((function(t){return t.toJSON()})),options:this.config()}},n.getTiles=function(t){for(var e=this.layers,n=[],r=0,i=0,o=e.length;i<o;i++){var a=e[i];if(a.options.visible){var s=a.getTiles(t,this);s&&0!==s.count&&(r+=s.count,I(n,s.tileGrids))}}return{count:r,tileGrids:n}},n.onAdd=function(){var e=this,n=this.getMap();this.layers.forEach((function(t){e.layerMap[t.getId()]=t,t.getChildLayer&&e._groupChildren.push(t),t._bindMap(n),t.on("show hide",e._onLayerShowHide,e)})),t.prototype.onAdd.call(this)},n.onRemove=function(){var e=this;this.layers.forEach((function(t){t._doRemove(),t.off("show hide",e._onLayerShowHide,e)})),this.layerMap={},this._groupChildren=[],t.prototype.onRemove.call(this)},n.getChildLayer=function(t){var e=this.layerMap[t];if(e)return e;for(var n=0;n<this._groupChildren.length;n++){var r=this._groupChildren[n].getChildLayer(t);if(r)return r}return null},n._onLayerShowHide=function(){var t=this.getRenderer();t&&t.setToRedraw()},n.isVisible=function(){if(!t.prototype.isVisible.call(this))return!1;for(var e=this.layers,n=0,r=e.length;n<r;n++)if(e[n].isVisible())return!0;return!1},n._checkChildren=function(){var t=this,e={};this.layers.forEach((function(n){var r=n.getId();if(e[r])throw new Error("Duplicate child layer id ("+r+") in the GroupTileLayer ("+t.getId()+")");e[r]=1}))},e}(Ta);Ea.registerJSONType("GroupTileLayer");var Aa={crs:null,uppercase:!1,detectRetina:!1},Ca={service:"WMS",request:"GetMap",layers:"",styles:"",format:"image/jpeg",transparent:!1,version:"1.1.1"},Pa=function(t){function e(e,n){var r;r=t.call(this,e)||this;var i=d({},Ca);for(var o in n)o in r.options||(i[o]=n[o]);r.setOptions(n),r.setZIndex(n.zIndex);var a=r.getTileSize();return i.width=a.width,i.height=a.height,r.wmsParams=i,r._wmsVersion=parseFloat(i.version),r}fe(e,t);var n=e.prototype;return n.onAdd=function(){var e=this.getMap().getDevicePixelRatio(),n=Aa.detectRetina?e:1;this.wmsParams.width*=n,this.wmsParams.height*=n;var r=this.options.crs||this.getMap().getProjection().code,i=this._wmsVersion>=1.3?"crs":"srs";this.wmsParams[i]=r,t.prototype.onAdd.call(this)},n.getTileUrl=function(e,n,r){var i=this.getSpatialReference().getResolution(r),o=this._getTileConfig().getTilePrjExtent(e,n,i),a=o.getMax(),s=o.getMin(),u=(this._wmsVersion>=1.3&&"EPSG:4326"===this.wmsParams.crs?[s.y,s.x,a.y,a.x]:[s.x,s.y,a.x,a.y]).join(","),c=t.prototype.getTileUrl.call(this,e,n,r);return c+function(t,e,n){var r=[];for(var i in t)r.push(encodeURIComponent(n?i.toUpperCase():i)+"="+encodeURIComponent(t[i]));return(e&&-1!==e.indexOf("?")?"&":"?")+r.join("&")}(this.wmsParams,c,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+u},n.toJSON=function(){return{type:"WMSTileLayer",id:this.getId(),options:this.config()}},e.fromJSON=function(t){return t&&"WMSTileLayer"===t.type?new e(t.id,t.options):null},e}(Ta);Pa.registerJSONType("WMSTileLayer"),Pa.mergeOptions(Aa);var La=function(t){function e(e,n){var r;return(r=t.call(this,e,n)||this).options.hasOwnProperty("forceRenderOnMoving")||(r.options.forceRenderOnMoving=!1),r}fe(e,t);var n=e.prototype;return n.drawTile=function(){},n.toJSON=function(){return{type:"CanvasTileLayer",id:this.getId(),options:this.config()}},e.fromJSON=function(t){return t&&"CanvasTileLayer"===t.type?new e(t.id,t.options):null},e}(Ta);function Oa(t,e,n){var r=t.createShader(e);if(t.shaderSource(r,n),t.compileShader(r),!t.getShaderParameter(r,t.COMPILE_STATUS)){var i=t.getShaderInfoLog(r);throw t.deleteShader(r),new Error("Failed to compile shader: "+i)}return r}La.registerJSONType("CanvasTileLayer");var Ra="\n attribute vec2 a_position;\n\n attribute vec2 a_texCoord;\n\n uniform mat4 u_matrix;\n\n varying vec2 v_texCoord;\n\n void main() {\n gl_Position = u_matrix * vec4(a_position, 0., 1.);\n\n v_texCoord = a_texCoord;\n }\n ",ka="\n precision mediump float;\n\n uniform sampler2D u_image;\n\n uniform float u_opacity;\n uniform float u_debug_line;\n\n varying vec2 v_texCoord;\n\n void main() {\n if (u_debug_line == 1.) {\n gl_FragColor = vec4(0., 1., 0., 1.);\n } else {\n gl_FragColor = texture2D(u_image, v_texCoord) * u_opacity;\n }\n }\n ",Ia=[0,0],Da=[0,0,0],ja=new Array(16),za=new me(20,20),Na=function(t){var e=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.drawGLImage=function(t,e,n,r,i,o,a,s){this.gl.program!==this.program&&this.useProgram(this.program);var u=this.gl;this.loadTexture(t),Da[0]=e||0,Da[1]=n||0;var c=mo(ja);lo(c,c,Da),ho(c,c,[o,o,1]),fo(c,this.getMap().projViewMatrix,c),u.uniformMatrix4fv(this.program.u_matrix,!1,c),u.uniform1f(this.program.u_opacity,a),u.uniform1f(this.program.u_debug_line,0);var l=t.glBuffer;!l||l.width===r&&l.height===i||(this.saveImageBuffer(l),delete t.glBuffer),t.glBuffer?u.bindBuffer(u.ARRAY_BUFFER,l):t.glBuffer=this.bufferTileData(0,0,r,i),Ia[0]="a_position",Ia[1]=2,Ia[2]=t.glBuffer.type,this.enableVertexAttrib(Ia),u.drawArrays(u.TRIANGLE_STRIP,0,4),s&&this.drawDebug(c,Ia,0,0,r,i,s)},n.drawDebug=function(t,e,n,r,i,o,a){var s=this.gl;s.bindBuffer(s.ARRAY_BUFFER,this._debugBuffer),this.enableVertexAttrib(["a_position",2,"FLOAT"]),s.bufferData(s.ARRAY_BUFFER,new Float32Array([n,r,n+i,r,n+i,r-o,n,r-o,n,r]),s.DYNAMIC_DRAW),s.uniformMatrix4fv(this.program.u_matrix,!1,t),s.uniform1f(this.program.u_debug_line,1),s.drawArrays(s.LINE_STRIP,0,5);var u=this._debugInfoCanvas;if(!u){var c=this.getMap().getDevicePixelRatio()>1?2:1;(u=this._debugInfoCanvas=document.createElement("canvas")).width=256*c,u.height=32*c;var l=u.getContext("2d");l.font="20px monospace",l.scale(c,c)}var h=u.getContext("2d");h.clearRect(0,0,u.width,u.height);var f=this.layer.options.debugOutline;hn.fillText(h,a,za,f),this.loadTexture(u),s.texImage2D(s.TEXTURE_2D,0,s.RGBA,s.RGBA,s.UNSIGNED_BYTE,u);var d=n,p=n+(i=256),m=r,g=r-(o=32);s.bufferData(s.ARRAY_BUFFER,this.set8(d,m,d,g,p,m,p,g),s.DYNAMIC_DRAW),s.uniform1f(this.program.u_debug_line,0),s.drawArrays(s.TRIANGLE_STRIP,0,4)},n.bufferTileData=function(t,e,n,r,i){var o,a=t,s=t+n,u=e,c=e-r;o=g(a)&&g(s)&&g(u)&&g(c)?this.set8Int(a,u,a,c,s,u,s,c):this.set8(a,u,a,c,s,u,s,c);var l=this.loadImageBuffer(o,i);return l.width=n,l.height=r,l.type=o instanceof Int16Array?"SHORT":"FLOAT",l},n.drawTinImage=function(t,e,n,r,i){var o=this.gl;this.loadTexture(t),o.uniformMatrix4fv(this.program.u_matrix,!1,this.getMap().projViewMatrix),o.uniform1f(this.program.u_opacity,i),o.bindBuffer(o.ARRAY_BUFFER,this.posBuffer),this.enableVertexAttrib(["a_position",3]),o.bufferData(o.ARRAY_BUFFER,new Float32Array(e),o.DYNAMIC_DRAW),o.bindBuffer(o.ARRAY_BUFFER,this.texBuffer),this.enableVertexAttrib(["a_texCoord",2]),o.bufferData(o.ARRAY_BUFFER,new Float32Array(n),o.DYNAMIC_DRAW),o.bufferData(o.ELEMENT_ARRAY_BUFFER,new Uint16Array(r),o.DYNAMIC_DRAW),o.drawElements(o.TRIANGLES,r.length,o.UNSIGNED_SHORT,0)},n.createCanvas2=function(){this.canvas2=hn.createCanvas(this.canvas.width,this.canvas.height)},n.createGLContext=function(){this.canvas.gl&&this.canvas.gl.wrap?this.gl=this.canvas.gl.wrap():this.gl=function(t,e){for(var n={alpha:!0,stencil:!0,preserveDrawingBuffer:!0,antialias:!1},r=["webgl","experimental-webgl"],i=null,o=0;o<r.length;++o){try{i=t.getContext(r[o],e||n)}catch(t){}if(i)break}return i}(this.canvas2||this.canvas,this.layer.options.glOptions);var t=this.gl;t.clearColor(0,0,0,0),t.disable(t.DEPTH_TEST),t.enable(t.STENCIL_TEST),t.enable(t.BLEND),t.blendFunc(t.ONE,t.ONE_MINUS_SRC_ALPHA),this.program=this.createProgram(Ra,this.layer.options.fragmentShader||ka,["u_matrix","u_image","u_opacity","u_debug_line"]),this._debugBuffer=this.createBuffer(),this.useProgram(this.program),this.texBuffer=this.createBuffer(),t.bindBuffer(t.ARRAY_BUFFER,this.texBuffer),this.enableVertexAttrib(["a_texCoord",2,"UNSIGNED_BYTE"]),t.bufferData(t.ARRAY_BUFFER,new Uint8Array([0,0,0,1,1,0,1,1]),t.STATIC_DRAW),this.enableSampler("u_image"),t.activeTexture(t.TEXTURE0),t.pixelStorei(t.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0)},n.resizeGLCanvas=function(){this.gl&&this.gl.viewport(0,0,this.canvas.width,this.canvas.height),this.canvas2&&(this.canvas2.width===this.canvas.width&&this.canvas2.height===this.canvas.height||(this.canvas2.width=this.canvas.width,this.canvas2.height=this.canvas.height))},n.clearGLCanvas=function(){this.gl&&this.gl.clear(this.gl.COLOR_BUFFER_BIT|this.gl.STENCIL_BUFFER_BIT)},n.disposeImage=function(t){t&&(t.texture&&this.saveTexture(t.texture),t.glBuffer&&this.saveImageBuffer(t.glBuffer),delete t.texture,delete t.glBuffer)},n._createTexture=function(t){var e=this.gl,n=this.getTexture()||e.createTexture();return e.bindTexture(e.TEXTURE_2D,n),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE),e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,e.UNSIGNED_BYTE,t),g(F(t.width))&&g(F(t.width))&&e.generateMipmap(e.TEXTURE_2D),n},n.getTexture=function(){this._textures||(this._textures=[]);var t=this._textures;return t&&t.length>0?t.pop():null},n.saveTexture=function(t){this._textures.push(t)},n.loadTexture=function(t){var e=this.gl,n=t.texture;return n||(n=this._createTexture(t),t.texture=n),e.bindTexture(e.TEXTURE_2D,n),n},n.getImageBuffer=function(){this._imageBuffers||(this._imageBuffers=[]);var t=this._imageBuffers;return t&&t.length>0?t.pop():null},n.saveImageBuffer=function(t){this._imageBuffers.push(t)},n.loadImageBuffer=function(t,e){var n=this.gl,r=e||this.createImageBuffer();return n.bindBuffer(n.ARRAY_BUFFER,r),n.bufferData(n.ARRAY_BUFFER,t,n.STATIC_DRAW),r},n.createImageBuffer=function(){return this.getImageBuffer()||this.createBuffer()},n.removeGLCanvas=function(){var t=this.gl;if(t){if(this._debugBuffer&&(t.deleteBuffer(this._debugBuffer),delete this._debugBuffer),this._buffers&&(this._buffers.forEach((function(e){t.deleteBuffer(e)})),delete this._buffers),this._textures&&(this._textures.forEach((function(e){return t.deleteTexture(e)})),delete this._textures),this._debugInfoCanvas){var e=this._debugInfoCanvas.texture;e&&t.deleteTexture(e),delete this._debugInfoCanvas.texture,delete this._debugInfoCanvas}var n=t.program;t.deleteShader(n.fragmentShader),t.deleteShader(n.vertexShader),t.deleteProgram(n),delete this.gl,delete this.canvas2}},n.createBuffer=function(){var t=this.gl.createBuffer();if(!t)throw new Error("Failed to create the buffer object");return this._buffers||(this._buffers=[]),this._buffers.push(t),t},n.enableVertexAttrib=function(t){!function(t,e,n){if(Array.isArray(n[0])){for(var r=Float32Array.BYTES_PER_ELEMENT,i=0,o=0;o<n.length;o++)i+=n[o][1]||0;for(var a=0,s=0;s<n.length;s++){var u=t.getAttribLocation(e,n[s][0]);if(u<0)throw new Error("Failed to get the storage location of "+n[s][0]);t.vertexAttribPointer(u,n[s][1],t[n[s][2]||"FLOAT"],!1,r*i,r*a),a+=n[s][1]||0,t.enableVertexAttribArray(u)}}else{var c=t.getAttribLocation(e,n[0]);t.vertexAttribPointer(c,n[1],t[n[2]||"FLOAT"],!1,0,0),t.enableVertexAttribArray(c)}}(this.gl,this.gl.program,t)},n.createProgram=function(t,e,n){var r=function(t,e,n){var r=Oa(t,t.VERTEX_SHADER,e),i=Oa(t,t.FRAGMENT_SHADER,n);if(!r||!i)return null;var o=t.createProgram();return o?(t.attachShader(o,r),t.attachShader(o,i),t.linkProgram(o),{program:o,vertexShader:r,fragmentShader:i}):null}(this.gl,t,e),i=r.program,o=r.vertexShader,a=r.fragmentShader;return i.vertexShader=o,i.fragmentShader=a,this._initUniforms(i,n),i},n.useProgram=function(t){var e=this.gl;return e.useProgram(t),e.program=t,this},n.enableSampler=function(t,e){var n=this.gl,r=this._getUniform(n.program,t);return e||(e=0),n.uniform1i(r,e),r},n._initUniforms=function(t,e){for(var n=0;n<e.length;n++){var r=e[n],i=e[n],o=r.indexOf("[");o>=0&&(r=r.substring(0,o),A||(i=i.substring(0,o))),t[r]=this._getUniform(t,i)}},n._getUniform=function(t,e){var n=this.gl.getUniformLocation(t,e);if(!n)throw new Error("Failed to get the storage location of "+e);return n},e}(t);return d(e.prototype,{set8:function(){var t=he.ie9?null:new Float32Array(8);return function(e,n,r,i,o,a,s,u){return t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=o,t[5]=a,t[6]=s,t[7]=u,t}}(),set8Int:function(){var t=he.ie9?null:new Int16Array(8);return function(e,n,r,i,o,a,s,u){return t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=o,t[5]=a,t[6]=s,t[7]=u,t}}()}),e},Fa={renderer:he.webgl?"gl":"canvas",crossOrigin:null},Ba=new me(0,0),Ha=function(t){function e(e,n,r){var i;return!n||Array.isArray(n)||n.url||(r=n,n=null),(i=t.call(this,e,r)||this)._images=n,i}fe(e,t);var n=e.prototype;return n.onAdd=function(){this._prepareImages(this._images)},n.setImages=function(t){return this._images=t,this._prepareImages(t),this},n.getImages=function(){return this._images},n._prepareImages=function(t){t=t||[],Array.isArray(t)||(t=[t]);var e=this.getMap();this._imageData=t.map((function(t){var n=new Vn(t.extent);return d({},t,{extent:n,extent2d:n.convertTo((function(t){return e.coordToPoint(t,e.getGLZoom())}))})})),this._images=t;var n=this.getRenderer();n&&n.refreshImages()},e}(ei);Ha.mergeOptions(Fa);var Ga=[],Ua=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.isDrawable=function(){return!this.getMap().getPitch()||(console&&console.warn("ImageLayer with canvas renderer can't be pitched, use gl renderer ('renderer' : 'gl') instead."),!1)},n.checkResources=function(){var t=this;if(this._imageLoaded)return Ga;var e=this.layer._imageData.map((function(t){return[t.url,null,null]}));if(this.resources){var n=[],r=new gr;e.forEach((function(e){if(t.resources.isResourceLoaded(e)){var i=t.resources.getImage(e);r.addResource(e,i)}else n.push(e)})),this.resources.forEach((function(e,n){r.isResourceLoaded(e)||t.retireImage(n.image)})),this.resources=r,e=n}return this._imageLoaded=!0,e},n.retireImage=function(){},n.refreshImages=function(){this._imageLoaded=!1,this.setToRedraw()},n.needToRedraw=function(){var e=this.getMap();return!(e.isZooming()&&!e.getPitch())&&t.prototype.needToRedraw.call(this)},n.draw=function(){this.isDrawable()&&(this.prepareCanvas(),this._painted=!1,this._drawImages(),this.completeRender())},n._drawImages=function(){var t=this.layer._imageData,e=this.getMap(),n=e._get2DExtent(e.getGLZoom());if(t&&t.length)for(var r=0;r<t.length;r++){var i=t[r].extent2d,o=this.resources&&this.resources.getImage(t[r].url);o&&n.intersects(i)&&(this._painted=!0,this._drawImage(o,i,t[r].opacity||1))}},n._drawImage=function(t,e,n){var r=0,i=this.context;n<1&&(r=i.globalAlpha,i.globalAlpha=n);var o=this.getMap(),a=Ba.set(e.xmin,e.ymax),s=o._pointToContainerPoint(a,o.getGLZoom()),u=s.x,c=s.y,l=o.getBearing();l&&(i.save(),i.translate(u,c),l&&i.rotate(-l*Math.PI/180),u=c=0);var h=o.getGLScale();i.drawImage(t,u,c,e.getWidth()/h,e.getHeight()/h),l&&i.restore(),r&&(i.globalAlpha=r)},n.drawOnInteracting=function(){this.draw()},e}(mr),Wa=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.isDrawable=function(){return!0},n._drawImage=function(t,e,n){this.drawGLImage(t,e.xmin,e.ymax,e.getWidth(),e.getHeight(),1,n)},n.createContext=function(){this.createGLContext()},n.resizeCanvas=function(e){this.canvas&&(t.prototype.resizeCanvas.call(this,e),this.resizeGLCanvas())},n.clearCanvas=function(){this.canvas&&(t.prototype.clearCanvas.call(this),this.clearGLCanvas())},n.retireImage=function(t){this.disposeImage(t)},n.onRemove=function(){this.removeGLCanvas(),t.prototype.onRemove.call(this)},e}(Na(Ua));Ha.registerRenderer("canvas",Ua),Ha.registerRenderer("gl",Wa);var Va=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.getPrepareParams=function(){return[]},n.getDrawParams=function(){return[]},n.onCanvasCreate=function(){this.canvas&&this.layer.options.doubleBuffer&&(this.buffer=hn.createCanvas(this.canvas.width,this.canvas.height,this.getMap().CanvasClass))},n.needToRedraw=function(){return!!this.layer.options.animation||!(this.getMap().isInteracting()&&!this.layer.drawOnInteracting)&&t.prototype.needToRedraw.call(this)},n.draw=function(){this.prepareCanvas(),this.prepareDrawContext(),this._drawLayer()},n.drawOnInteracting=function(){this._drawLayerOnInteracting()},n.getCanvasImage=function(){var e=t.prototype.getCanvasImage.call(this);if(e&&e.image&&this.layer.options.doubleBuffer){var n=e.image;this.buffer.width===n.width&&this.buffer.height===n.height||(this.buffer.width=n.width,this.buffer.height=n.height);var r=this.buffer.getContext("2d"),i=this.layer.doubleBuffer(r,this.context);(void 0===i||i)&&(hn.image(r,n,0,0),e.image=this.buffer)}return e},n.remove=function(){return delete this._drawContext,t.prototype.remove.call(this)},n.onZoomStart=function(e){this.layer.onZoomStart(e),t.prototype.onZoomStart.call(this,e)},n.onZooming=function(e){this.layer.onZooming(e),t.prototype.onZooming.call(this,e)},n.onZoomEnd=function(e){this.layer.onZoomEnd(e),t.prototype.onZoomEnd.call(this,e)},n.onMoveStart=function(e){this.layer.onMoveStart(e),t.prototype.onMoveStart.call(this,e)},n.onMoving=function(e){this.layer.onMoving(e),t.prototype.onMoving.call(this,e)},n.onMoveEnd=function(e){this.layer.onMoveEnd(e),t.prototype.onMoveEnd.call(this,e)},n.onResize=function(e){this.layer.onResize(e),t.prototype.onResize.call(this,e)},n.prepareDrawContext=function(){if(!this._predrawed){var t=Za(this.getPrepareParams());this._drawContext=this.layer.prepareToDraw.apply(this.layer,[this.context].concat(t)),this._drawContext||(this._drawContext=[]),Array.isArray(this._drawContext)||(this._drawContext=[this._drawContext]),this._predrawed=!0}},n._prepareDrawParams=function(){if(!this.getMap())return null;var t=this.getViewExtent();if(t.maskExtent&&!t.extent.intersects(t.maskExtent))return this.completeRender(),null;var e=[this.context,t],n=Za(this.getDrawParams());return e.push.apply(e,n),e.push.apply(e,this._drawContext),e},n._drawLayer=function(){var t=this._prepareDrawParams();t&&(this.layer.draw.apply(this.layer,t),this.completeRender())},n._drawLayerOnInteracting=function(){if(this.layer.drawOnInteracting){var t=this._prepareDrawParams();t&&(this.layer.drawOnInteracting.apply(this.layer,t),this.completeRender())}},e}(mr);function Za(t){return t||(t=[]),Array.isArray(t)||(t=[t]),t}var qa=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.isCanvasRender=function(){return!0},n.prepareToDraw=function(){},n.draw=function(){},n.redraw=function(){return this._getRenderer()&&this._getRenderer().setToRedraw(),this},n.play=function(){return this.config("animation",!0),this},n.pause=function(){return this.config("animation",!1),this},n.isPlaying=function(){return this.options.animation},n.clearCanvas=function(){return this._getRenderer()&&this._getRenderer().clearCanvas(),this},n.requestMapToRender=function(){return this._getRenderer()&&this._getRenderer().requestMapToRender(),this},n.completeRender=function(){return this._getRenderer()&&this._getRenderer().completeRender(),this},n.onCanvasCreate=function(){return this},n.onZoomStart=function(){},n.onZooming=function(){},n.onZoomEnd=function(){},n.onMoveStart=function(){},n.onMoving=function(){},n.onMoveEnd=function(){},n.onResize=function(){},n.doubleBuffer=function(t){return t.clearRect(0,0,t.canvas.width,t.canvas.height),this},e}(ei);qa.mergeOptions({doubleBuffer:!1,animation:!1}),qa.registerRenderer("canvas",Va);var Ya=new me(0,0),Ja=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.getParticles=function(){},n.draw=function(t,e){var n=this.getParticles(f());if(n&&0!==n.length){var r=this.getMap(),i=e.extent;e.maskExtent&&(i=e.extent.intersection(e.maskExtent)),i=i.convertTo((function(t){return r._pointToContainerPoint(t,void 0,0,Ya)}));for(var o=2*Math.PI,a=0,s=n.length;a<s;a++){var u=n[a].point;if(i.contains(u)){var c=n[a].color||this.options.lineColor||"#fff",l=n[a].r;t.fillStyle!==c&&(t.fillStyle=c),l<=2?t.fillRect(u.x-l/2,u.y-l/2,l,l):(t.beginPath(),t.arc(u.x,u.y,l/2,0,o),t.fill())}}this._fillCanvas(t)}else this._getRenderer()&&(this._getRenderer()._shouldClear=!0)},n._fillCanvas=function(t){var e=t.globalCompositeOperation;t.globalCompositeOperation="destination-out";var n=this.options.trail||30;t.fillStyle="rgba(0, 0, 0, "+1/n+")",t.fillRect(0,0,t.canvas.width,t.canvas.height),t.globalCompositeOperation=e},e}(qa);Ja.mergeOptions({animation:!0}),Ja.registerRenderer("canvas",function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.draw=function(){this.canvas&&this.layer.options.animation&&!this._shouldClear||(this.prepareCanvas(),this._shouldClear=!1),this.prepareDrawContext(),this._drawLayer()},n.drawOnInteracting=function(){this.draw(),this._shouldClear=!1},n.onSkipDrawOnInteracting=function(){this._shouldClear=!0},e}(Va));var Xa=i+"_edit_stage_";function $a(t,e){return{markerType:t,markerFill:"#fff",markerLineColor:"#000",markerLineWidth:2,markerWidth:10,markerHeight:10,opacity:e}}var Qa={fixAspectRatio:!1,symbol:null,removeVertexOn:"contextmenu",centerHandleSymbol:$a("ellipse",1),vertexHandleSymbol:$a("square",1),newVertexHandleSymbol:$a("square",.4)},Ka=function(t){function e(e,n){var r;return(r=t.call(this,n)||this)._geometry=e,r._geometry?r:de(r)}fe(e,t);var n=e.prototype;return n.getMap=function(){return this._geometry.getMap()},n.prepare=function(){this.getMap()&&(this.options.symbol&&(this._originalSymbol=this._geometry.getSymbol(),this._geometry.setSymbol(this.options.symbol)),this._prepareEditStageLayer())},n._prepareEditStageLayer=function(){var t=this.getMap(),e=O(),n=Xa+e,r=Xa+e+"_shadow";this._editStageLayer=t.getLayer(n),this._shadowLayer=t.getLayer(r),this._editStageLayer||(this._editStageLayer=new eo(n),t.addLayer(this._editStageLayer)),this._shadowLayer||(this._shadowLayer=new eo(r),t.addLayer(this._shadowLayer))},n.start=function(){var t=this;if(this._geometry&&this._geometry.getMap()&&!this._geometry.editing){var e=this.getMap();this.editing=!0;var n=this._geometry;this._geometryDraggble=n.options.draggable,n.config("draggable",!1),this.prepare();var r=n.copy();r.setSymbol(n._getInternalSymbol()),r.copyEventListeners(n),n._getParent()&&r.copyEventListeners(n._getParent()),r._setEventTarget(n),r.setId(null).config({draggable:!1}),this._shadow=r,this._switchGeometryEvents("on"),n.hide(),(n instanceof Mi||n instanceof Di||n instanceof zi||n instanceof ji)&&this._createOrRefreshOutline(),this._shadowLayer.bringToFront().addGeometry(r),this._editStageLayer.bringToFront(),this._addListener([e,"zoomstart",function(){t._editStageLayer.hide()}]),this._addListener([e,"zoomend",function(){t._editStageLayer.show()}]),n instanceof Mi?(r.config("draggable",!0),r.on("dragend",this._onMarkerDragEnd,this)):this._createCenterHandle(),n instanceof Mi?this.createMarkerEditor():n instanceof Di?this.createCircleEditor():n instanceof zi||n instanceof ji?this.createEllipseOrRectEditor():n instanceof Ni||(n instanceof bi||n instanceof Ti)&&this.createPolygonEditor()}},n.stop=function(){delete this._history,delete this._historyPointer,delete this._editOutline,this._switchGeometryEvents("off"),this.getMap()&&(delete this._shadow,this._geometry.config("draggable",this._geometryDraggble),delete this._geometryDraggble,this._geometry.show(),this._editStageLayer.remove(),this._shadowLayer.remove(),this._clearAllListeners(),this._refreshHooks=[],this.options.symbol&&(this._geometry.setSymbol(this._originalSymbol),delete this._originalSymbol),this.editing=!1)},n.isEditing=function(){return!p(this.editing)&&this.editing},n._getGeometryEvents=function(){return{symbolchange:this._onGeoSymbolChange,"positionchange shapechange":this._exeAndReset}},n._switchGeometryEvents=function(t){if(this._geometry){var e=this._getGeometryEvents();for(var n in e)this._geometry[t](n,e[n],this)}},n._onGeoSymbolChange=function(t){this._shadow&&this._shadow.setSymbol(t.target._getInternalSymbol())},n._onMarkerDragEnd=function(){this._update("setCoordinates",this._shadow.getCoordinates().toArray()),this._refresh()},n._createOrRefreshOutline=function(){var t=this._geometry,e=this._editOutline;return e?(e.remove(),this._editOutline=e=t.getOutline(),this._editStageLayer.addGeometry(e)):(e=t.getOutline(),this._editStageLayer.addGeometry(e),this._editOutline=e,this._addRefreshHook(this._createOrRefreshOutline)),e},n._createCenterHandle=function(){var t,e=this,n=this._shadow.getCenter(),r=this.options.centerHandleSymbol,i=this.createHandle(n,{symbol:r,cursor:"move",onDown:function(){var n=It((t=e._shadow.copy())._getInternalSymbol(),.5);t.setSymbol(n).addTo(e._editStageLayer)},onMove:function(e,n){var r=n.coordOffset;t.translate(r)},onUp:function(){e._update("setCoordinates",On.toNumberArrays(t.getCoordinates())),t.remove(),e._refresh()}});this._addRefreshHook((function(){var t=e._shadow.getCenter();i.setCoordinates(t)}))},n._createHandleInstance=function(t,e){var n=e.symbol;return new Mi(t,{draggable:!0,dragShadow:!1,dragOnAxis:e.axis,cursor:e.cursor,symbol:n})},n.createHandle=function(t,e){e||(e={});var n=this.getMap(),r=this._createHandleInstance(t,e),i=this;function o(t){return e.onDown&&(this._geometry.fire("handledragstart"),e.onDown.call(i,t.viewPoint,t)),!1}function a(t){i._hideContext();var o=n._prjToViewPoint(r._getPrjCoordinates());return e.onMove&&(this._geometry.fire("handledragging"),e.onMove.call(i,o,t)),!1}function s(t){return e.onUp&&(this._geometry.fire("handledragend"),e.onUp.call(i,t)),!1}return r.on("dragstart",o,this),r.on("dragging",a,this),r.on("dragend",s,this),r.on("removestart",(function t(){r.config("draggable",!1),r.off("dragstart",o,i),r.off("dragging",a,i),r.off("dragend",s,i),r.off("removestart",t,i),delete r["maptalks--editor-refresh-fn"]}),this),e.onRefresh&&(r["maptalks--editor-refresh-fn"]=e.onRefresh),this._editStageLayer.addGeometry(r),r},n._createResizeHandles=function(t,e,n){var r=this,i=["nw-resize","n-resize","ne-resize","w-resize","e-resize","sw-resize","s-resize","se-resize"],o=[null,"y",null,"x","x",null,"y",null],a=this._geometry;t||(t=[]);var s=this,u=[],c={},l=this.getMap(),h=this.options.vertexHandleSymbol,f=function(){for(var f=function(t){return[new me(t.xmin,t.ymax),new me((t.xmax+t.xmin)/2,t.ymax),new me(t.xmax,t.ymax),new me(t.xmin,(t.ymax+t.ymin)/2),new me(t.xmax,(t.ymax+t.ymin)/2),new me(t.xmin,t.ymin),new me((t.xmax+t.xmin)/2,t.ymin),new me(t.xmax,t.ymin)]}(a._getPainter().get2DExtent()),d=function(d){if(Array.isArray(t)&&t.some((function(t){return t===d})))return"continue";var p=f[d],m=l.pointToCoordinate(p);if(u.length<f.length-t.length){var g=r.createHandle(m,{symbol:h,cursor:i[d],axis:o[d],onMove:function(t){return function(n){s._updating=!0,e(n,t),a.fire("resizing")}}(d),onUp:function(){s._updating=!1,n(),r._refresh()}});g.setId(d),c[d]=u.length,u.push(g)}else u[c[d]].setCoordinates(m)},p=0;p<f.length;p++)d(p)};return f(),this._addRefreshHook(f),u},n.createMarkerEditor=function(){var t=this,e=this._geometry,n=this._shadow,r=this.getMap();if(n._canEdit()){this._history||this._recordHistory(h());var i=n._getInternalSymbol(),o=new me(0,0);m(i.markerDx)&&(o.x=i.markerDx),m(i.markerDy)&&(o.y=i.markerDy);var a=null;Cr.test(i)?"pin"!==i.markerType&&"pie"!==i.markerType&&"bar"!==i.markerType||(a=[5,6,7]):(Lr.test(i)||zr.test(i))&&(a=[5,6,7]);var s,u=[2,1,2,0,0,2,1,2];if(this.options.fixAspectRatio){var c=n.getSize();s=c.width/c.height}var l=this._createResizeHandles(null,(function(i,c){if(a&&a.indexOf(c)>=0){var h=r.viewPointToCoordinate(i.sub(o)),f=n.getCoordinates();h.x=f.x,n.setCoordinates(h),t._updateCoordFromShadow(!0);var d=l[l.length-1-c];i=r.coordToViewPoint(d.getCoordinates())}var p=r._pointToViewPoint(n._getCenter2DPoint()).add(o),m=n._getInternalSymbol(),g=i.sub(p);a&&i.y>p.y&&(g.y=0);var v=a?1:2,y=2*Math.abs(g.x),_=Math.abs(g.y)*v;s&&(_=(y=Math.max(y,_*s))/s);var x=u[c];n instanceof Zi?((s||0===x||2===x)&&(n.setWidth(y),e.setWidth(y)),(s||1===x||2===x)&&(n.setHeight(_),e.setHeight(_))):((s||0===x||2===x)&&(m.markerWidth=y),(s||1===x||2===x)&&(m.markerHeight=_),n.setSymbol(m),e.setSymbol(m))}),(function(){t._update(h())}));this._addListener([r,"zoomend",function(){this._refresh()}])}else console&&console.warn("A marker can't be resized with symbol:",n.getSymbol());function h(){var t=[["setCoordinates",n.getCoordinates().toArray()]];return n instanceof Zi?(t.push(["setWidth",n.getWidth()]),t.push(["setHeight",n.getHeight()])):t.push(["setSymbol",n.getSymbol()]),t}},n.createCircleEditor=function(){var t=this,e=this._geometry,n=this._shadow,r=this.getMap();this._history||this._recordHistory([["setCoordinates",n.getCoordinates().toArray()],["setRadius",n.getRadius()]]),this._createResizeHandles(null,(function(t){var i=e.getCenter(),o=r.viewPointToCoordinate(t),a=new Ti([[i.x,i.y],[o.x,i.y]]),s=new Ti([[i.x,i.y],[i.x,o.y]]),u=Math.max(r.computeGeometryLength(a),r.computeGeometryLength(s));n.setRadius(u),e.setRadius(u)}),(function(){t._update("setRadius",n.getRadius())}))},n.createEllipseOrRectEditor=function(){var t=this,e=[2,1,2,0,0,2,1,2],n=this._geometry,r=this._shadow;this._history||this._recordHistory(u());var i,o=this.getMap(),a=this._geometry instanceof zi;this.options.fixAspectRatio&&(i=n.getWidth()/n.getHeight());var s=this._createResizeHandles(null,(function(u,c){var l,h,f,d=a?1:2,p=u,m=e[c];if(a){var g=s[7-c],v=o.coordToViewPoint(g.getCoordinates()),y=(l=p.sub(v)).abs();h=o.pixelToDistance(y.x,0),f=o.pixelToDistance(0,y.y);var _=n.getSize(),x=s[0].getCoordinates(),b=o.viewPointToCoordinate(u),w=g.getCoordinates(),M=new Ti([[w.x,w.y],[b.x,w.y]]),S=new Ti([[w.x,w.y],[w.x,b.y]]);h=o.computeGeometryLength(M),f=o.computeGeometryLength(S),0===m?(i&&(y.y=y.x/i,_.height=Math.abs(y.y),f=h/i),p.y=v.y-_.height/2,b.y=x.y,b.x=4===c?Math.min(b.x,x.x):Math.min(b.x,w.x)):1===m?(i&&(y.x=y.y*i,_.width=Math.abs(y.x),h=f*i),p.x=v.x-_.width/2,b.x=x.x,b.y=Math.max(b.y,w.y)):(i&&(h>f*i?(f=h/i,p.y=v.y+y.x*N(l.y)/i):(h=f*i,p.x=v.x+y.y*N(l.x)*i)),b.x=Math.min(b.x,w.x),b.y=Math.max(b.y,w.y)),r.setCoordinates(b),t._updateCoordFromShadow(!0)}else{var T=n.getCenter(),E=o.viewPointToCoordinate(p),A=new Ti([[T.x,T.y],[E.x,T.y]]),C=new Ti([[T.x,T.y],[T.x,E.y]]);h=o.computeGeometryLength(A),f=o.computeGeometryLength(C),i&&(f=(h=Math.max(h,f*i))/i)}(i||0===m||2===m)&&(r.setWidth(h*d),n.setWidth(h*d)),(i||1===m||2===m)&&(r.setHeight(f*d),n.setHeight(f*d))}),(function(){t._update(u())}));function u(){return[["setCoordinates",r.getCoordinates().toArray()],["setWidth",r.getWidth()],["setHeight",r.getHeight()]]}},n.createPolygonEditor=function(){var t=this.getMap(),e=this._shadow,n=this,r=t.getProjection();this._history||this._recordHistory("setCoordinates",On.toNumberArrays(e.getCoordinates()));var i=e instanceof bi?3:2,o="maptalks--editor-refresh-fn",a="maptalks--editor-vertex-index",s={0:[]},u={0:[]};function c(t){if(void 0===t&&(t=0),e instanceof bi){var n=e.getCoordinates()[t]||[];return n.slice(0,n.length-1)}return e.getCoordinates()}function l(t){return void 0===t&&(t=0),0===t?e._getPrjCoordinates():e._getPrjHoles()[t-1]}function h(){for(var t in s){for(var e=s[t].length-1;e>=0;e--)s[t][e][a]=e;for(var r=u[t].length-1;r>=0;r--)u[t][r][a]=r}n._updateCoordFromShadow()}function f(t){var r,o=t.target,c=o[a],f=m(o._ringIndex)?o._ringIndex:0,d=l(f);d.length<=i||(d.splice(c,1),f>0?e._prjHoles[f-1]=d:e._setPrjCoordinates(d),e._updateCache(),s[f].splice(c,1)[0].remove(),c<u[f].length&&u[f].splice(c,1)[0].remove(),r=0===c?u[f].length-1:c-1,u[f].splice(r,1)[0].remove(),u[f].splice(r,0,g.call(n,r,f)),h(),n._refresh())}function d(r,i,a){void 0===a&&(a=0);var s,c=l(a),h=t._viewPointToPrj(r),f=c[i];f.x=h.x,f.y=h.y,e._updateCache(),e.onShapeChanged(),n._updateCoordFromShadow(!0),s=0===i?u[a].length-1:i-1,u[a][i]&&u[a][i][o](),u[a][s]&&u[a][s][o]()}function p(t,e){void 0===e&&(e=0);var r=c(e)[t],i=n.createHandle(r,{symbol:n.options.vertexHandleSymbol,cursor:"pointer",axis:null,onMove:function(t){d(t,i[a],e)},onRefresh:function(){r=c(e)[i[a]],i.setCoordinates(r)},onUp:function(){n._refresh(),n._updateCoordFromShadow()},onDown:function(t,e){!e||!e.domEvent||e.domEvent.button}});return i[a]=t,i._ringIndex=e,i.on(n.options.removeVertexOn,f),i}function g(t,i){void 0===i&&(i=0);var o,f=c(i);o=t+1>=f.length?f[0]:f[t+1];var m=f[t].add(o).multi(.5),v=n.createHandle(m,{symbol:n.options.newVertexHandleSymbol,cursor:"pointer",axis:null,onDown:function(t,o){if(!o||!o.domEvent||2!==o.domEvent.button){var s=l(i),c=v[a],h=r.project(v.getCoordinates());s.splice(c+1,0,h),i>0?e._prjHoles[i-1]=s:e._setPrjCoordinates(s),e._updateCache();var f=v.getSymbol();delete f.opacity,v.setSymbol(f),u[i].splice(c,0,g.call(n,c,i),g.call(n,c+1,i))}},onMove:function(t){d(t,v[a]+1,i)},onUp:function(t){if(!t||!t.domEvent||2!==t.domEvent.button){var e=v[a];D(v,u[i]),v.remove(),s[i].splice(e+1,0,p.call(n,e+1,i)),h(),n._updateCoordFromShadow(),n._refresh()}},onRefresh:function(){f=c(i);var t,e=v[a];t=e===f.length-1?0:e+1;var n=f[e].add(f[t]).multi(.5);v.setCoordinates(n)}});return v[a]=t,v}if(e instanceof bi)for(var v=e.getHoles().length+1,y=0;y<v;y++){s[y]=[],u[y]=[];for(var _=c(y),x=0,b=_.length;x<b;x++)s[y].push(p.call(this,x,y)),x<b-1&&u[y].push(g.call(this,x,y));u[y].push(g.call(this,_.length-1,y))}else for(var w=0,M=c(0).length;w<M;w++)s[0].push(p.call(this,w,0)),w<M-1&&u[0].push(g.call(this,w,0));this._addRefreshHook((function(){for(var t in u)for(var e=u[t].length-1;e>=0;e--)u[t][e][o](t);for(var n in s)for(var r=s[n].length-1;r>=0;r--)s[n][r][o](n)}))},n._refresh=function(){if(this._refreshHooks)for(var t=this._refreshHooks.length-1;t>=0;t--)this._refreshHooks[t].call(this)},n._hideContext=function(){this._geometry&&(this._geometry.closeMenu(),this._geometry.closeInfoWindow())},n._addListener=function(t){this._eventListeners||(this._eventListeners=[]),this._eventListeners.push(t),t[0].on(t[1],t[2],this)},n._clearAllListeners=function(){if(this._eventListeners&&this._eventListeners.length>0){for(var t=this._eventListeners.length-1;t>=0;t--){var e=this._eventListeners[t];e[0].off(e[1],e[2],this)}this._eventListeners=[]}},n._addRefreshHook=function(t){t&&(this._refreshHooks||(this._refreshHooks=[]),this._refreshHooks.push(t))},n._update=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];this._exeHistory([t,n]),this._recordHistory.apply(this,[t].concat(n))},n._updateCoordFromShadow=function(t){if(this._shadow){var e=this._shadow.getCoordinates(),n=this._geometry,r=this._updating;this._updating=!0,n.setCoordinates(e),t||this._recordHistory("setCoordinates",On.toNumberArrays(n.getCoordinates())),this._updating=r}},n._recordHistory=function(t){this._history||(this._history=[],this._historyPointer=0);for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];if(this._history.length){var i=this._history[this._history.length-1];if(i[0]===t&&JSON.stringify(i[1])===JSON.stringify(n))return}this._historyPointer<this._history.length-1&&this._history.splice(this._historyPointer+1),this._history.push([t,n]),this._historyPointer=this._history.length-1,this._geometry.fire("editrecord")},n.cancel=function(){if(!this._history||0===this._historyPointer)return this;this._historyPointer=0;var t=this._history[0];return this._exeAndReset(t),this},n.undo=function(){if(!this._history||0===this._historyPointer)return this;var t=this._history[--this._historyPointer];return this._exeAndReset(t),this},n.redo=function(){if(!this._history||this._historyPointer===this._history.length-1)return this;var t=this._history[++this._historyPointer];return this._exeAndReset(t),this},n._exeAndReset=function(t){if(!this._updating){this._exeHistory(t);var e=this._history,n=this._historyPointer;this.stop(),this._history=e,this._historyPointer=n,this.start()}},n._exeHistory=function(t){var e=this;if(Array.isArray(t)){var n=this._updating;this._updating=!0;var r=this._geometry;Array.isArray(t[0])?t[0].forEach((function(t){var n=t[0],i=t.slice(1);e._shadow[n].apply(e._shadow,i),r[n].apply(r,i)})):(this._shadow[t[0]].apply(this._shadow,t[1]),r[t[0]].apply(r,t[1])),this._updating=n}},e}(xn(Mn));Ka.mergeOptions(Qa);var ts={startEditText:function(){return this.getMap()?(this.hide(),this.endEditText(),this._prepareEditor(),this._fireEvent("edittextstart"),this):this},endEditText:function(){if(this._textEditor){var t=this._textEditor.innerHTML;t=t.replace(/<p>/gi,"").replace(/<\/p>/gi,"<br/>"),this._textEditor.innerHTML=t;var e=this._textEditor.innerText.replace(/[\r\n]+$/gi,"");this.setContent(e),on(this._textEditor,"mousedown dblclick",Ue),this.getMap().off("mousedown",this.endEditText,this),this._editUIMarker.remove(),delete this._editUIMarker,this._textEditor.onkeyup=null,delete this._textEditor,this.show(),this._fireEvent("edittextend")}return this},isEditingText:function(){return!!this._textEditor},getTextEditor:function(){return this._editUIMarker},_prepareEditor:function(){var t=this.getMap(),e=this._createEditor();this._textEditor=e,t.on("mousedown",this.endEditText,this);var n=this._getEditorOffset();this._editUIMarker=new Fo(this.getCoordinates(),{animation:null,content:e,dx:n.dx,dy:n.dy}).addTo(t),this._setCursorToLast(this._textEditor)},_getEditorOffset:function(){var t=this._getInternalSymbol()||{},e=0,n=0,r=t.textHorizontalAlignment;return"middle"===r||p(r)?(e=(t.textDx||0)-2,n=(t.textDy||0)-2):(e=(t.markerDx||0)-2,n=(t.markerDy||0)-2),{dx:e,dy:n}},_createEditor:function(){var t=this.getContent(),e=this.getSize(),n=this._getInternalSymbol()||{},r=e.width,i=n.textFill||"#000000",o=n.textSize||12,a=e.height,s=n.markerLineColor||"#000",u=n.markerFill||"#3398CC",c=n.textLineSpacing||0,l=je("div");return l.contentEditable=!0,l.style.cssText="background:"+u+"; border:1px solid "+s+";\n color:"+i+";font-size:"+o+"px;width:"+(r-2)+"px;height:"+(a-2)+"px;margin: auto;\n line-height:"+(o+c)+"px;outline: 0; padding:0; margin:0;word-wrap: break-word;\n overflow: hidden;-webkit-user-modify: read-write-plaintext-only;",l.innerText=t,rn(l,"mousedown dblclick",Ue),l.onkeyup=function(t){var e=l.style.height||0;13===t.keyCode&&(l.style.height=parseInt(e)+o/2+"px")},l},_setCursorToLast:function(t){var e;window.getSelection?(t.focus(),(e=window.getSelection()).selectAllChildren(t),e.collapseToEnd()):document.selection&&((e=document.selection.createRange()).moveToElementText(t),e.collapse(!1),e.select())}};Vi.include(ts),Kr.include({animate:function(t,e,n){var r=this;this._animPlayer&&this._animPlayer.finish(),_(e)&&(n=e),e||(e={});var i,o=this.getMap(),a=this._getProjection(),s=this.getSymbol()||{},u=this._prepareAnimationStyles(t),c=e.focus;if(delete this._animationStarted,o){var l=o._getRenderer();e.framer=function(t){l.callInNextFrame(t)}}var h=gi.animate(u,e,(function(t){if(o&&o.isRemoved())h.finish();else{o&&!r._animationStarted&&c&&o.onMoveStart();var e=t.styles;for(var u in e)if("symbol"!==u&&"translate"!==u&&e.hasOwnProperty(u)){var l="set"+u[0].toUpperCase()+u.slice(1);r[l](e[u])}var f=e.translate;if(f){var d=f;i&&(d=f.sub(i)),i=f,r.translate(d)}var p=e.symbol;if(p&&r.setSymbol(Dt(s,p)),o&&c){var m=a.project(r.getCenter());o._setPrjCenter(m);var g=o._parseEventFromCoord(a.unproject(m));"running"!==h.playState?o.onMoveEnd(g):o.onMoving(g)}r._fireAnimateEvent(h.playState),n&&n(t)}}),this);return this._animPlayer=h,this._animPlayer.play()},_prepareAnimationStyles:function(t){var e=this._getInternalSymbol(),n={};for(var r in t)if(t.hasOwnProperty(r)){var i=t[r];if("translate"!==r&&"symbol"!==r){var o=this["get"+r[0].toUpperCase()+r.substring(1)]();n[r]=[o,i]}else if("symbol"===r){var a=void 0;if(Array.isArray(t.symbol)){if(!Array.isArray(e))throw new Error("geometry'symbol isn't a composite symbol, while the symbol in styles is.");a=[];for(var s=t.symbol,u=0;u<s.length;u++)if(s[u]){var c={};for(var l in s[u])s[u].hasOwnProperty(l)&&(c[l]=[e[u][l],s[u][l]]);a.push(c)}else a.push(null)}else{if(Array.isArray(e))throw new Error("geometry'symbol is a composite symbol, while the symbol in styles isn't.");for(var h in a={},i)i.hasOwnProperty(h)&&(a[h]=[e[h],i[h]])}n.symbol=a}else"translate"===r&&(n.translate=new On(i))}return n},_fireAnimateEvent:function(t){"finished"===t?(delete this._animationStarted,this._fireEvent("animateend")):"running"===t&&(this._animationStarted?this._fireEvent("animating"):(this._fireEvent("animatestart"),this._animationStarted=!0))}});var es=i+"_drag_stage",ns=he.touch?"touchstart mousedown":"mousedown",rs=function(t){function e(e){return t.call(this,e)||this}fe(e,t);var n=e.prototype;return n.addHooks=function(){this.target.on(ns,this._startDrag,this)},n.removeHooks=function(){this._endDrag(),this.target.off(ns,this._startDrag,this),delete this.container},n._prepareDragHandler=function(){this._dragHandler=new Ln(this.container),this._dragHandler.on("dragging",this._dragging,this).on("mouseup",this._endDrag,this).enable()},n._prepareShadow=function(){var t=this,e=this.target;this._prepareDragStageLayer(),this._shadow&&this._shadow.remove();var n=this._shadow=e.copy();if(n.getGeometries){var r=n.getGeometries(),i=e.getGeometries();r.forEach((function(e,n){t._updateShadowSymbol(e,i[n])}))}else this._updateShadowSymbol(n,e);n.setId(null),this._prepareShadowConnectors()},n._updateShadowSymbol=function(t,e){if(t.setSymbol(e._getInternalSymbol()),e.options.dragShadow){var n=It(t._getInternalSymbol(),.5);t.setSymbol(n)}},n._prepareShadowConnectors=function(){var t=this.target,e=this._shadow,n=this._dragStageLayer._getRenderer().resources,r=[];if(Xi._hasConnectors(t))for(var i=Xi._getConnectors(t),o=0,a=i.length;o<a;o++){var s,u=i[o],c=u.config(),l=u._getInternalSymbol();c.symbol=It(l,.5),s=u.getConnectSource()===t?new u.constructor(e,u.getConnectTarget(),c):new u.constructor(u.getConnectSource(),e,c),r.push(s),u.getLayer()&&u.getLayer()._getRenderer()&&n.merge(u.getLayer()._getRenderer().resources)}this._shadowConnectors=r,r.push(e),this._dragStageLayer.bringToFront().addGeometry(r)},n._onTargetUpdated=function(){this._shadow&&this._shadow.setSymbol(this.target._getSymbol())},n._prepareDragStageLayer=function(){var t=this.target.getMap(),e=this.target.getLayer();this._dragStageLayer=t.getLayer(es),this._dragStageLayer||(this._dragStageLayer=new eo(es,{enableAltitude:e.options.enableAltitude,altitudeProperty:e.options.altitudeProperty}),t.addLayer(this._dragStageLayer));var n=new gr;n.merge(e._getRenderer().resources),this._dragStageLayer._getRenderer().resources=n},n._startDrag=function(t){var e=this.target.getMap();if(e&&!this.target._getParent()&&!this.isDragging()){var n=t.domEvent;n.touches&&n.touches.length>1||2===n.button||(this.container=e._panels.mapWrapper||e._containerDOM,this.target.on("click",this._endDrag,this),this._lastCoord=this._correctCoord(t.coordinate),this._lastPoint=t.containerPoint,this._prepareDragHandler(),this._dragHandler.onMouseDown(t.domEvent),rn(this.container,"mouseleave",this._endDrag,this),this._startParam=t,this._moved=!1)}},n._dragging=function(t){var e=this.target,n=e.getMap()._parseEvent(t.domEvent),r=n.domEvent;if(!(r.touches&&r.touches.length>1)){if(!this._moved)return this._moved=!0,e.on("symbolchange",this._onTargetUpdated,this),this._isDragging=!0,this._prepareShadow(),e.options.dragShadow||e.hide(),this._shadow._fireEvent("dragstart",n),this.target._fireEvent("dragstart",this._startParam||n),void delete this._startParam;if(this._shadow){var i=this._shadow.options.dragOnAxis,o=this._correctCoord(n.coordinate),a=n.containerPoint;this._lastPoint=this._lastPoint||a,this._lastCoord=this._lastCoord||o;var s=a.sub(this._lastPoint),u=o.sub(this._lastCoord);"x"===i?s.y=u.y=0:"y"===i&&(s.x=u.x=0),this._lastPoint=a,this._lastCoord=o,this._shadow.translate(u),e.options.dragShadow||e.translate(u),n.coordOffset=u,n.pointOffset=s,this._shadow._fireEvent("dragging",n),e._fireEvent("dragging",n)}}},n._endDrag=function(t){if(this._dragHandler&&(this._dragHandler.disable(),delete this._dragHandler),this.container&&on(this.container,"mouseleave",this._endDrag,this),this.target){var e=this.target;e.off("click",this._endDrag,this),e.off("symbolchange",this._onTargetUpdated,this),delete this._lastCoord,delete this._lastPoint,this._isDragging=!1;var n=e.getMap();if(this.enabled()&&n){var r=n._parseEvent(t?t.domEvent:null);this._updateTargetAndRemoveShadow(r),this._moved&&e._fireEvent("dragend",r)}}},n.isDragging=function(){return!!this._isDragging},n._updateTargetAndRemoveShadow=function(t){var e=this.target,n=e.getMap();e.options.dragShadow||e.show();var r=this._shadow;if(r){if(e.options.dragShadow)if(e.getGeometries){var i=r.getGeometries(),o=e.getGeometries();i.forEach((function(t,e){o[e].setCoordinates(i[e].getCoordinates())}))}else e.setCoordinates(r.getCoordinates());r._fireEvent("dragend",t),r.remove(),delete this._shadow}this._shadowConnectors&&(n.getLayer(es).removeGeometry(this._shadowConnectors),delete this._shadowConnectors),this._dragStageLayer&&this._dragStageLayer.remove()},n._correctCoord=function(t){var e=this.target.getMap();if(!e.getPitch())return t;var n=this.target._getPainter();if(!n.getMinAltitude())return t;var r=(n.getMinAltitude()+n.getMaxAltitude())/2;return e.locateByPoint(t,0,-r)},e}(wn);Kr.mergeOptions({draggable:!1,dragShadow:!0,dragOnAxis:null}),Kr.addInitHook("addHandler","draggable",rs),Kr.include({isDragging:function(){return this._getParent()?this._getParent().isDragging():!!this.draggable&&this.draggable.isDragging()}}),Kr.include({startEdit:function(t){return this.getMap()&&this.options.editable?(this.endEdit(),this._editor=new Ka(this,t),this._editor.start(),this.fire("editstart"),this):this},endEdit:function(){return this._editor&&(this._editor.stop(),delete this._editor,this.fire("editend")),this},redoEdit:function(){return this.isEditing()?(this._editor.redo(),this.fire("redoedit"),this):this},undoEdit:function(){return this.isEditing()?(this._editor.undo(),this.fire("undoedit"),this):this},cancelEdit:function(){return this.isEditing()?(this._editor.cancel(),this.fire("canceledit"),this):this},isEditing:function(){return!!this._editor&&this._editor.isEditing()}}),Kr.include({_onEvent:function(t,e){if(this.getMap()){var n=e||this._getEventTypeToFire(t);"contextmenu"===n&&this.listens("contextmenu")&&(Ue(t),Ge(t));var r=this._getEventParams(t);this._fireEvent(n,r)}},_getEventTypeToFire:function(t){return t.type},_getEventParams:function(t){var e=this.getMap(),n={domEvent:t},r=t.touches&&t.touches.length>0?t.touches[0]:t.changedTouches&&t.changedTouches.length>0?t.changedTouches[0]:t;if(r){var i=qe(r,e._containerDOM);n.coordinate=e.containerPointToCoordinate(i),n.containerPoint=i,n.viewPoint=e.containerPointToViewPoint(i),n.pont2d=e._containerPointToPoint(i)}return n}}),Kr.include({setInfoWindow:function(t){return this.removeInfoWindow(),t instanceof Go?(this._infoWindow=t,this._infoWinOptions=d({},this._infoWindow.options),this._infoWindow.addTo(this),this):(this._infoWinOptions=d({},t),this._infoWindow?this._infoWindow.setOptions(t):this.getMap()&&this._bindInfoWindow(this._infoWinOptions),this)},getInfoWindow:function(){return this._infoWindow?this._infoWindow:null},openInfoWindow:function(t){return this.getMap()?(t||(t=this.getCenter()),this._infoWindow?this._infoWindow.show(t):this._infoWinOptions&&this.getMap()&&(this._bindInfoWindow(this._infoWinOptions),this._infoWindow.show(t)),this):this},closeInfoWindow:function(){return this._infoWindow&&this._infoWindow.hide(),this},removeInfoWindow:function(){return this._unbindInfoWindow(),delete this._infoWinOptions,delete this._infoWindow,this},_bindInfoWindow:function(t){return this._infoWindow=new Go(t),this._infoWindow.addTo(this),this},_unbindInfoWindow:function(){return this._infoWindow&&(this.closeInfoWindow(),this._infoWindow.remove(),delete this._infoWindow),this}});var is=function(){function t(t,e){this.max=t,this.onRemove=e,this.reset()}var e=t.prototype;return e.reset=function(){for(var t in this.data)this.onRemove(this.data[t]);return this.data={},this.order=[],this},e.clear=function(){this.reset(),delete this.onRemove},e.add=function(t,e){if(this.has(t))this.order.splice(this.order.indexOf(t),1),this.data[t]=e,this.order.push(t);else if(this.data[t]=e,this.order.push(t),this.order.length>this.max){var n=this.getAndRemove(this.order[0]);n&&this.onRemove(n)}return this},e.has=function(t){return t in this.data},e.keys=function(){return this.order},e.getAndRemove=function(t){if(!this.has(t))return null;var e=this.data[t];return delete this.data[t],this.order.splice(this.order.indexOf(t),1),e},e.get=function(t){return this.has(t)?this.data[t]:null},e.remove=function(t){if(!this.has(t))return this;var e=this.data[t];return delete this.data[t],this.onRemove(e),this.order.splice(this.order.indexOf(t),1),this},e.setMaxSize=function(t){for(this.max=t;this.order.length>this.max;){var e=this.getAndRemove(this.order[0]);e&&this.onRemove(e)}return this},t}(),os=new me(0,0),as=new me(0,0),ss=new me(0,0),us=new me(0,0),cs=function(t){function e(e){var n;return(n=t.call(this,e)||this).tilesInView={},n.tilesLoading={},n._parentTiles=[],n._childTiles=[],n.tileCache=new is(e.options.maxCacheSize,n.deleteTile.bind(de(de(n)))),n}fe(e,t);var n=e.prototype;return n.getCurrentTileZoom=function(){return this._tileZoom},n.draw=function(){var t=this.getMap();if(this.isDrawable()){var e=this.prepareCanvas();if(!e||e.intersects(this.canvasExtent2D)){var n=this.layer.getTiles().tileGrids;if(n&&n.length){var r=0,i=!1,o={},a=[],s=[],u={},c=[],l={},h=[],f={},d={},p=this._markTiles(),m=this._getLoadLimit(),g=n.length;this._tileZoom=n[0].zoom;for(var v=0;v<g;v++)for(var y=n[v],_=y.tiles,x=this._generatePlaceHolder(y.zoom),b=0,w=_.length;b<w;b++){var M=_[b],S=M.id,T=!1;if(this._isLoadingTile(S))T=i=!0,this.tilesLoading[S].current=!0;else{var E=this._getCachedTile(S);E?(E.image&&this.getTileOpacity(E.image)<1&&(T=i=!0),a.push(E)):(T=i=!0,m&&r+p[0]>m||t.isInteracting()&&!t.isMoving()&&!t.isRotating()||(r++,d[S]=M))}if(T&&!o[S]){o[S]=1,x&&!f[S]&&(M.cache=!1,h.push({image:x,info:M}),f[S]=1);var A=this._findParentTile(M);if(A){var C=A.info.id;void 0===u[C]&&(u[C]=s.length,s.push(A))}else if(!s.length){var P=this._findChildTiles(M);P.length&&P.forEach((function(t){l[t.info.id]||(c.push(t),l[t.info.id]=1)}))}}}s.length&&(c.length=0,this._childTiles.length=0),this._drawTiles(a,s,c,h),r?this.loadTileQueue(d):i||(t.isAnimating()||!this._parentTiles.length&&!this._childTiles.length||(this._parentTiles=[],this._childTiles=[],this.setToRedraw()),this.completeRender()),this._retireTiles()}else this.completeRender()}else this.completeRender()}},n.isTileCachedOrLoading=function(t){return this.tilesLoading[t]||this.tilesInView[t]||this.tileCache.get(t)},n._drawTiles=function(t,e,n,r){var i=this;e.length&&(e.sort((function(t,e){return Math.abs(e.info.z-i._tileZoom)-Math.abs(t.info.z-i._tileZoom)})),this._parentTiles=e),n.length&&(this._childTiles=n);var o={tiles:t,parentTiles:this._parentTiles,childTiles:this._childTiles};this.onDrawTileStart(o),this._parentTiles.forEach((function(t){return i._drawTileAndCache(t)})),this._childTiles.forEach((function(t){return i._drawTile(t.info,t.image)})),r.forEach((function(t){return i._drawTile(t.info,t.image)}));var a=this.layer,s=this.getMap();if(!a.options.cascadeTiles||s.getPitch()<=s.options.cascadePitches[0])t.forEach((function(t){return i._drawTileAndCache(t)}));else{this.writeZoomStencil();for(var u=!1,c=0,l=t.length;c<l;c++)t[c].info.z!==this._tileZoom?u?this.resumeZoomStencilTest():(this.startZoomStencilTest(),u=!0):u&&this.pauseZoomStencilTest(),this._drawTileAndCache(t[c]);this.endZoomStencilTest()}this.onDrawTileEnd(o)},n.writeZoomStencil=function(){},n.startZoomStencilTest=function(){},n.endZoomStencilTest=function(){},n.pauseZoomStencilTest=function(){},n.resumeZoomStencilTest=function(){},n.onDrawTileStart=function(){},n.onDrawTileEnd=function(){},n._drawTile=function(t,e){e&&this.drawTile(t,e)},n._drawTileAndCache=function(t){t.current=!0,this.tilesInView[t.info.id]=t,this._drawTile(t.info,t.image),this.tileCache.add(t.info.id,t)},n.drawOnInteracting=function(){this.draw()},n.needToRedraw=function(){var e=this.getMap();return e.getPitch()?t.prototype.needToRedraw.call(this):!(!e.isRotating()&&!e.isZooming())||(e.isMoving()?!!this.layer.options.forceRenderOnMoving:t.prototype.needToRedraw.call(this))},n.hitDetect=function(){return!1},n._getLoadLimit=function(){return this.getMap().isInteracting()?this.layer.options.loadingLimitOnInteracting:0},n.isDrawable=function(){return!this.getMap().getPitch()||(console&&console.warn("TileLayer with canvas renderer can't be pitched, use gl renderer ('renderer' : 'gl') instead."),this.clear(),!1)},n.clear=function(){this._retireTiles(!0),this.tileCache.reset(),this.tilesInView={},this.tilesLoading={},this._parentTiles=[],this._childTiles=[],t.prototype.clear.call(this)},n._isLoadingTile=function(t){return!!this.tilesLoading[t]},n.clipCanvas=function(e){return t.prototype.clipCanvas.call(this,e)},n._clipByPitch=function(t){var e=this.getMap();if(e.getPitch()<=e.options.maxVisualPitch)return!1;if(!this.layer.options.clipByPitch)return!1;var n=e.getContainerExtent(),r=e.getDevicePixelRatio();return t.save(),t.strokeStyle="rgba(0, 0, 0, 0)",t.beginPath(),t.rect(0,Math.ceil(n.ymin)*r,Math.ceil(n.getWidth())*r,Math.ceil(n.getHeight())*r),t.stroke(),t.clip(),!0},n.loadTileQueue=function(t){for(var e in t)if(t.hasOwnProperty(e)){var n=t[e],r=this.loadTile(n);void 0===r.loadTime&&(this.tilesLoading[n.id]={image:r,current:!0,info:n})}},n.loadTile=function(t){var e=this.layer.getTileSize(),n=new Image;return n.width=e.width,n.height=e.height,n.onload=this.onTileLoad.bind(this,n,t),n.onerror=this.onTileError.bind(this,n,t),this.loadTileImage(n,t.url),n},n.loadTileImage=function(t,e){var n=this.layer.options.crossOrigin;return p(n)||(t.crossOrigin=n),P(t,[e])},n.abortTileLoading=function(t){t&&(t.onload=ls,t.onerror=ls,t.src=Q)},n.onTileLoad=function(t,e){if(this.layer){var n=e.id;if(this.tilesInView){var r={tile:e,tileImage:t};this.layer.fire("tileload",r),(t=r.tileImage).loadTime=f(),delete this.tilesLoading[n],this._addTileToCache(e,t),this.setToRedraw()}}},n.onTileError=function(t,e){if(this.layer){if(t.onerrorTick=t.onerrorTick||0,this.layer.options.tileRetryCount>t.onerrorTick)return t.onerrorTick++,void(t.src=e.url);if(t instanceof Image){var n=this.layer.options.errorUrl;if(n&&t.src!==n)return void(t.src=n);this.abortTileLoading(t,e)}t.loadTime=0,delete this.tilesLoading[e.id],this._addTileToCache(e,t),this.setToRedraw(),this.layer.fire("tileerror",{tile:e})}},n.drawTile=function(t,e){if(e&&this.getMap()){var n=t.extent2d,r=t.offset,i=os.set(n.xmin-r[0],n.ymax-r[1]),o=t.z,a=t.id,s=this.getMap(),u=this.layer.getTileSize(),c=s.getZoom(),l=this.context,h=s._pointToContainerPoint(i,o,0,as),f=s.getBearing(),d=f||c!==o,p=this.getTileOpacity(e),m=l.globalAlpha;p<1&&(l.globalAlpha=p,this.setToRedraw()),d||h._round();var g=h.x,v=h.y,y=u.width,_=u.height;if(d){if(l.save(),l.translate(g,v),f&&(l.rotate(-f*Math.PI/180),y+=.1,_+=.1),c!==o){var x=s._getResolution(o)/s._getResolution();l.scale(x,x)}g=v=0}if(hn.image(l,e,g,v,y,_),this.layer.options.debug){var b=this.layer.options.debugOutline;l.save(),l.strokeStyle=b,l.fillStyle=b,l.strokeWidth=10,l.font="20px monospace";var w=new me(g,v);hn.rectangle(l,w,{width:y,height:_},1,0),hn.fillText(l,this.getDebugInfo(a),w._add(10,20),b),hn.drawCross(l,g+y/2,v+_/2,2,b),l.restore()}d&&l.restore(),l.globalAlpha!==m&&(l.globalAlpha=m),this.setCanvasUpdated()}},n.getDebugInfo=function(t){var e=t.split("_"),n=e.length;return"x:"+e[n-2]+", y:"+e[n-3]+", z:"+e[n-1]},n._findChildTiles=function(t){var e=this._getLayerOfTile(t.layer);if(!e.options.background)return[];for(var n=this.getMap(),r=[],i=t.extent2d.getMin(),o=t.extent2d.getMax(),a=t.offset,s=e._project(n._pointToPrj(i,t.z,ss),ss),u=e._project(n._pointToPrj(o,t.z,us),us),c=1;c<2;c++)this._findChildTilesAt(r,s,u,e,t.z+c,a);return r},n._findChildTilesAt=function(t,e,n,r,i,o){var a=r.options.zoomOffset,s=r.getId(),u=r.getSpatialReference().getResolution(i+a);if(u)for(var c,l,h=r._getTileConfig().getTileIndex(e,u,o),f=r._getTileConfig().getTileIndex(n,u,o),d=Math.min(h.idx,f.idx),p=Math.max(h.idx,f.idx),m=Math.min(h.idy,f.idy),g=Math.max(h.idy,f.idy),v=d;v<p;v++)for(var y=m;y<g;y++)c=r._getTileId(v,y,i+a,s),this.tileCache.has(c)&&(l=this.tileCache.getAndRemove(c),t.push(l),this.tileCache.add(c,l))},n._findParentTile=function(t){var e=this.getMap(),n=this._getLayerOfTile(t.layer);if(!n.options.background)return null;for(var r=n.getSpatialReference(),i=r.getZoomDirection(),o=n.options.zoomOffset,a=n.options.backgroundZoomDiff,s=t.extent2d.getCenter(),u=t.offset,c=n._project(e._pointToPrj(s,t.z)),l=1;l<=a;l++){var h=t.z-i*l,f=r.getResolution(h+o);if(f){var d=n._getTileConfig().getTileIndex(c,f,u),p=n._getTileId(d.x,d.y,h+o,t.layer);if(this.tileCache.has(p)){var m=this.tileCache.getAndRemove(p);return this.tileCache.add(p,m),m}}}return null},n._getLayerOfTile=function(t){return this.layer.getChildLayer?this.layer.getChildLayer(t):this.layer},n._getCachedTile=function(t){var e=this.tilesInView,n=this.tileCache.getAndRemove(t);if(n){e[t]=n;var r=this.tilesLoading;if(r&&r[t]){r[t].current=!1;var i=r[t],o=i.image,a=i.info;this.abortTileLoading(o,a),delete r[t]}}else n=e[t];return n},n._addTileToCache=function(t,e){this.tilesInView[t.id]={image:e,current:!0,info:t}},n.getTileOpacity=function(t){return this.layer.options.fadeAnimation&&t.loadTime?Math.min(1,(f()-t.loadTime)/(1e3/60*10)):1},n.onRemove=function(){this.clear(),delete this.tileCache,delete this._tilePlaceHolder,t.prototype.onRemove.call(this)},n._markTiles=function(){var t=0,e=0;if(this.tilesLoading)for(var n in this.tilesLoading)this.tilesLoading[n].current=!1,t++;if(this.tilesInView)for(var r in this.tilesInView)this.tilesInView[r].current=!1,e++;return[t,e]},n._retireTiles=function(t){for(var e in this.tilesLoading){var n=this.tilesLoading[e];!t&&n.current||(n.image&&this.abortTileLoading(n.image,n.info),this.deleteTile(n),delete this.tilesLoading[e])}for(var r in this.tilesInView){var i=this.tilesInView[r];i.current||(delete this.tilesInView[r],this.tileCache.has(r)||this.deleteTile(i))}},n.deleteTile=function(t){t&&t.image&&(t.image.onload=null,t.image.onerror=null)},n._generatePlaceHolder=function(t){var e=this.getMap(),n=this.layer.options.placeholder;if(!n||e.getPitch())return null;var r=this.layer.getTileSize(),i=e._getResolution(t)/e._getResolution(),o=this._tilePlaceHolder=this._tilePlaceHolder||hn.createCanvas(1,1,e.CanvasClass);return o.width=r.width*i,o.height=r.height*i,_(n)?n(o):function(t){var e=t.getContext("2d"),n=t.width,r=t.height,i=n/16,o=r/16;e.beginPath();for(var a=0;a<16;a++)e.moveTo(0,a*o),e.lineTo(n,a*o),e.moveTo(a*i,0),e.lineTo(a*i,r);e.strokeStyle="rgba(180, 180, 180, 0.1)",e.lineWidth=1,e.stroke(),e.beginPath();for(var s=[[0,0],[n,0],[0,r],[n,r],[0,0],[0,r],[n,0],[n,r],[0,r/2],[n,r/2],[n/2,0],[n/2,r]],u=1;u<s.length;u+=2)e.moveTo(s[u-1][0],s[u-1][1]),e.lineTo(s[u][0],s[u][1]);e.lineWidth=4,e.stroke()}(o),o},e}(mr);function ls(){return!1}Ta.registerRenderer("canvas",cs);var hs=new me(0,0),fs=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.isDrawable=function(){return!0},n.needToRedraw=function(){var e=this.getMap();return!(!this._gl()||e.getPitch()||!e.isZooming()||e.isMoving()||e.isRotating())||t.prototype.needToRedraw.call(this)},n.drawTile=function(e,n){var r=this.getMap();if(e&&r&&n){var i=e._glScale=e._glScale||r.getGLScale(e.z),o=this.layer.getTileSize(),a=o.width,s=o.height;if(!1!==e.cache&&this._bindGLBuffer(n,a,s),this._gl()){var u=e.extent2d,c=e.offset,l=hs.set(u.xmin-c[0],e.extent2d.ymax-c[1]),h=l.x*i,f=l.y*i,d=this.getTileOpacity(n),p=null;this.layer.options.debug&&(p=this.getDebugInfo(e.id)),this.drawGLImage(n,h,f,a,s,i,d,p),d<1?this.setToRedraw():this.setCanvasUpdated()}else t.prototype.drawTile.call(this,e,n)}},n.writeZoomStencil=function(){var t=this.gl;t.stencilFunc(t.ALWAYS,1,255),t.stencilOp(t.KEEP,t.KEEP,t.REPLACE)},n.startZoomStencilTest=function(){var t=this.gl;t.stencilOp(t.KEEP,t.KEEP,t.KEEP),t.stencilFunc(t.EQUAL,0,255)},n.endZoomStencilTest=function(){this.pauseZoomStencilTest()},n.pauseZoomStencilTest=function(){var t=this.gl;t.stencilFunc(t.ALWAYS,1,255)},n.resumeZoomStencilTest=function(){var t=this.gl;t.stencilFunc(t.EQUAL,0,255)},n._bindGLBuffer=function(t,e,n){t.glBuffer||(t.glBuffer=this.bufferTileData(0,0,e,n))},n.loadTileImage=function(t,e){var n=this.layer.options.crossOrigin;t.crossOrigin=null!==n?n:"",t.src=e},n.onCanvasCreate=function(){this.canvas.gl&&this.canvas.gl.wrap||this.createCanvas2()},n.createContext=function(){t.prototype.createContext.call(this),this.createGLContext()},n.resizeCanvas=function(e){this.canvas&&(t.prototype.resizeCanvas.call(this,e),this.resizeGLCanvas())},n.clearCanvas=function(){this.canvas&&(t.prototype.clearCanvas.call(this),this.clearGLCanvas())},n.getCanvasImage=function(){if(!this._gl()||!this.canvas2)return t.prototype.getCanvasImage.call(this);var e=t.prototype.getCanvasImage.call(this);return e&&(e.image=this.canvas2),e},n._gl=function(){if(this.canvas.gl&&this.canvas.gl.wrap)return!0;var t=this.getMap();return t&&(t.getPitch()||t.getBearing())||this.layer&&!!this.layer.options.fragmentShader},n.deleteTile=function(e){t.prototype.deleteTile.call(this,e),e&&e.image&&this.disposeImage(e.image),delete e.image},n.onRemove=function(){t.prototype.onRemove.call(this),this.removeGLCanvas()},e}(Na(cs));function ds(t){var e=this.layer.getTileSize(),n=this.canvas.constructor,r=this.getMap(),i=r.getDevicePixelRatio(),o=hn.createCanvas(e.width*i,e.height*i,n);o.layer=this.layer;var a=this,s=new me(t.extent2d.xmin,t.extent2d.ymax),u=new Vn(r.pointToCoordinate(s),r.pointToCoordinate(s.add(e.width,e.height)),r.getProjection());return this.layer.drawTile(o,{url:t.url,point:s,center:r.pointToCoordinate(s.add(e.width/2,e.height/2)),extent:u,z:t.z,x:t.x,y:t.y},(function(e){e?a.onTileError(o,t):a.onTileLoad(o,t)})),o}Ta.registerRenderer("gl",fs);var ps=function(t){function e(){return t.apply(this,arguments)||this}return fe(e,t),e.prototype.loadTile=function(){return ds.apply(this,arguments)},e}(cs),ms=function(t){function e(){return t.apply(this,arguments)||this}return fe(e,t),e.prototype.loadTile=function(){return ds.apply(this,arguments)},e}(fs);La.registerRenderer("canvas",ps),La.registerRenderer("gl",ms);var gs=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.checkResources=function(){var t=this._geosToCheck;if(this._resourceChecked||t||(t=this.layer._geoList),!U(t))return[];for(var e=[],n={},r=t.length-1;r>=0;r--){var i=t[r]._getExternalResources();if(i.length)if(this.resources)for(var o=0;o<i.length;o++){var a=i[o][0];this.resources.isResourceLoaded(i[o])||n[a]||(e.push(i[o]),n[a]=1)}else e.push.apply(e,i)}return this._resourceChecked=!0,delete this._geosToCheck,e},n.render=function(){return this.layer._sortGeometries(),t.prototype.render.apply(this,arguments)},n._addGeoToCheckRes=function(t){t&&(Array.isArray(t)||(t=[t]),this._geosToCheck||(this._geosToCheck=[]),I(this._geosToCheck,t))},n.onGeometryAdd=function(t){this._addGeoToCheckRes(t),vs(this)},n.onGeometryRemove=function(){vs(this)},n.onGeometrySymbolChange=function(t){this._addGeoToCheckRes(t.target),vs(this)},n.onGeometryShapeChange=function(){vs(this)},n.onGeometryPositionChange=function(){vs(this)},n.onGeometryZIndexChange=function(){vs(this)},n.onGeometryShow=function(){vs(this)},n.onGeometryHide=function(){vs(this)},n.onGeometryPropertiesChange=function(){vs(this)},e}(mr);function vs(t){t.layer.options.drawImmediate&&t.render(),t.setToRedraw()}var ys=new Zn,_s=function(t){function e(){return t.apply(this,arguments)||this}fe(e,t);var n=e.prototype;return n.checkResources=function(){var e=this,n=t.prototype.checkResources.apply(this,arguments),r=this.layer.getStyle();return r&&(Array.isArray(r)||(r=[r]),r.forEach((function(t){for(var r=Pt(t.symbol,!0),i=0,o=r.length;i<o;i++)e.resources.isResourceLoaded(r[i])||n.push(r[i])}))),n},n.needToRedraw=function(){var e=this.getMap();return!(!e.isInteracting()||!this.layer.options.enableAltitude)||!(e.isZooming()&&!e.isRotating()&&!e.getPitch()&&!this._hasPoint&&this.layer.constructor===eo)&&t.prototype.needToRedraw.call(this)},n.draw=function(){if(this.getMap()){if(!this.layer.isVisible()||this.layer.isEmpty())return this.clearCanvas(),void this.completeRender();this.prepareCanvas(),this.drawGeos(),this.completeRender()}},n.isBlank=function(){return!!this.context&&!this.context.canvas._drawn},n.drawOnInteracting=function(){if(this._geosToDraw){this._updateDisplayExtent();var t=this.getMap(),e=this.layer.getCount(),n=this.getMap().getResolution();(t.isZooming()&&t.options.seamlessZoom&&void 0!==this._drawnRes&&n>1.5*this._drawnRes&&this._geosToDraw.length<e||t.isMoving()||t.isInteracting())&&(this.prepareToDraw(),this.forEachGeo(this.checkGeo,this),this._drawnRes=n);for(var r=0,i=this._geosToDraw.length;r<i;r++){var o=this._geosToDraw[r];o.isVisible()&&o._paint(this._displayExtent)}}},n.show=function(){this.layer.forEach((function(t){t._repaint()})),t.prototype.show.apply(this,arguments)},n.forEachGeo=function(t,e){this.layer.forEach(t,e)},n.drawGeos=function(){this._drawnRes=this.getMap().getResolution(),this._updateDisplayExtent(),this.prepareToDraw(),this.forEachGeo(this.checkGeo,this);for(var t=0,e=this._geosToDraw.length;t<e;t++)this._geosToDraw[t]._paint()},n.prepareToDraw=function(){this._hasPoint=!1,this._geosToDraw=[]},n.checkGeo=function(t){if(t&&t.isVisible()&&t.getMap()&&t.getLayer()&&t.getLayer().isCanvasRender()){var e=t._getPainter(),n=e.get2DExtent(this.resources,ys);n&&n.intersects(this._displayExtent)&&(e.hasPoint()&&(this._hasPoint=!0),this._geosToDraw.push(t))}},n.onZoomEnd=function(){delete this.canvasExtent2D,t.prototype.onZoomEnd.apply(this,arguments)},n.onRemove=function(){this.forEachGeo((function(t){t.onHide()})),delete this._geosToDraw},n.onGeometryPropertiesChange=function(e){e&&this.layer._styleGeometry(e.target),t.prototype.onGeometryPropertiesChange.call(this,e)},n._updateDisplayExtent=function(){var t=this.canvasExtent2D;if(this._maskExtent){if(!this._maskExtent.intersects(t))return void this.completeRender();t=t.intersection(this._maskExtent)}this._displayExtent=t},n.identify=function(t,e){void 0===e&&(e={});var n=this._geosToDraw;return n?this.layer._hitGeos(n,t,e):[]},e}(gs);eo.registerRenderer("canvas",_s);var xs=function(t){function e(e){var n;return(n=t.call(this)||this).map=e,n._handlerQueue={},n}fe(e,t);var n=e.prototype;return n.callInNextFrame=function(t){this._handlerQueue.push(t)},n.executeFrameCallbacks=function(){var t=this._handlerQueue;this._handlerQueue=[];for(var e=0,n=t.length;e<n;e++)t[e]()},n.offsetPlatform=function(t,e){if(!this.map._panels.front)return this;if(!e&&0===t.x&&0===t.y)return this;var n=this.map._panels,r=this._frontCount=n.back.layerDOM.childElementCount,i=this._backCount=n.front.layerDOM.childElementCount,o=this._uiCount=n.front.uiDOM.childElementCount;if(r||i||o){var a=this.map.offsetPlatform();a=t?a.add(t)._round():a.round(),i&&Ve(n.back,a),(r||o)&&Ve(n.front,a)}return this},n.domChanged=function(){var t=this.map._panels;if(!t.front)return!1;var e=t.back.layerDOM.childElementCount;if(void 0===this._frontCount||this._frontCount!==e)return!0;var n=t.front.layerDOM.childElementCount;if(void 0===this._backCount||this._backCount!==n)return!0;var r=t.front.uiDOM.childElementCount;return void 0===this._uiCount||this._uiCount!==r},n.resetContainer=function(){if(this.map&&(this.map._resetMapViewPoint(),this.map._panels.front)){var t=new me(0,0);Ve(this.map._panels.back,t),Ve(this.map._panels.front,t)}},n.onZoomEnd=function(){this.resetContainer()},n.onLoad=function(){this._frameLoop()},e}(Mn),bs=function(t){function e(e){var n;return(n=t.call(this,e)||this)._containerIsCanvas=!!e._containerDOM.getContext,n._thisVisibilitychange=n._onVisibilitychange.bind(de(de(n))),n._registerEvents(),n._loopTime=0,n}fe(e,t);var n=e.prototype;return n.load=function(){this.initContainer()},n.renderFrame=function(t){if(!this.map)return!1;delete this._isViewChanged;var e=this.map;e._fireEvent("framestart"),this.updateMapDOM();var n=this._getAllLayerToRender();return this.drawLayers(n,t),this.drawLayerCanvas(n)&&this._drawCenterCross(),e._fireEvent("frameend"),this._recordView(),this._mapview=this._getMapView(),delete this._spatialRefChanged,this._fireLayerLoadEvents(),this.executeFrameCallbacks(),this._canvasUpdated=!1,!0},n.updateMapDOM=function(){var t=this.map;if(!t.isZooming()){var e=t._getViewPointFrameOffset();e?t.offsetPlatform(e):this.domChanged()&&this.offsetPlatform(null,!0)}},n.drawLayers=function(t,e){for(var n=this.map,r=n.isInteracting(),i=[],o=[],a=n.options.fpsOnInteracting||0,s=0===a?0:1e3/a,u=this.map.options.layerCanvasLimitOnInteracting,c=t.length,l=n.getBaseLayer(),h=0,f=0;f<c;f++){var d=t[f];if(d.isVisible()){var p=d.isCanvasRender();p&&i.push(d.getId());var m=d._getRenderer();if(m){var g=this._checkLayerRedraw(d);p&&m.isCanvasUpdated()&&(g||o.push(d.getId()),this.setLayerCanvasUpdated());var v=m.__zoomTransformMatrix;if(delete m.__zoomTransformMatrix,g){if(r&&p){if(u>0&&c-1-f>u&&d!==l){d._getRenderer().clearCanvas();continue}h+=this._drawCanvasLayerOnInteracting(d,h,s,e)}else r&&m.drawOnInteracting?(m.prepareRender&&m.prepareRender(),m.checkAndDraw?m.checkAndDraw(m.drawOnInteracting,this._eventParam,e):m.drawOnInteracting(this._eventParam,e)):(m.render(e),p&&v&&m.isLoadingResource()&&(m.__zoomTransformMatrix=v));p&&(o.push(d.getId()),this.setLayerCanvasUpdated())}else p&&r&&(n.isZooming()&&!n.getPitch()?(m.prepareRender(),m.__zoomTransformMatrix=this._zoomMatrix):(n.getPitch()||n.isRotating())&&m.clearCanvas())}}}var y=this._canvasIds||[],_=this._updatedIds||[];if(this._canvasIds=i,this._updatedIds=o,!this.isLayerCanvasUpdated()){var x="---";y.join(x)===i.join(x)&&_.join(x)===o.join(x)||this.setLayerCanvasUpdated()}},n._checkLayerRedraw=function(t){if(this.isSpatialReferenceChanged())return!0;var e=this.map,n=t._getRenderer();return t.isCanvasRender()?n.testIfNeedRedraw():!(!n.needToRedraw||!n.needToRedraw())||e.isInteracting()||this.isViewChanged()},n._drawCanvasLayerOnInteracting=function(t,e,n,r){var i=this.map,o=t._getRenderer(),a=o.getDrawTime(),s=0===n||n>0&&e+a<=n;if(o.mustRenderOnInteracting&&o.mustRenderOnInteracting())o.render(r);else{if(o.drawOnInteracting&&(t===i.getBaseLayer()||s||i.isZooming()&&t.options.forceRenderOnZooming||i.isMoving()&&t.options.forceRenderOnMoving||i.isRotating()&&t.options.forceRenderOnRotating))return o.prepareRender(),o.prepareCanvas(),o.checkAndDraw?o.checkAndDraw(o.drawOnInteracting,this._eventParam,r):o.drawOnInteracting(this._eventParam,r),a;!i.isZooming()||i.getPitch()||i.isRotating()?(i.getPitch()||i.isRotating())&&o.clearCanvas():(o.prepareRender(),o.__zoomTransformMatrix=this._zoomMatrix)}return o.drawOnInteracting&&!s&&o.onSkipDrawOnInteracting(this._eventParam,r),0},n._fireLayerLoadEvents=function(){if(this._updatedIds&&this._updatedIds.length>0){var t=this.map;this._updatedIds.reverse().forEach((function(e){var n=t.getLayer(e);if(n){var r=n._getRenderer();r&&r.isRenderComplete()&&n.fire("layerload")}}))}},n.isLayerCanvasUpdated=function(){return this._canvasUpdated},n.setLayerCanvasUpdated=function(){this._canvasUpdated=!0},n.drawLayerCanvas=function(t){var e=this.map;if(!e)return!1;if(!this.isLayerCanvasUpdated()&&!this.isViewChanged())return!1;this.canvas||this.createCanvas(),e._fireEvent("renderstart",{context:this.context}),this._updateCanvasSize()||this.clearCanvas();for(var n,r=e.isInteracting(),i=e.options.layerCanvasLimitOnInteracting,o=t.length,a=[],s=0;s<o;s++)if(t[s].isVisible()&&t[s].isCanvasRender()&&t[s]._getRenderer()){var u=this._getLayerImage(t[s]);u&&u.image&&(t[s]===e.getBaseLayer()?n=[t[s],u]:a.push([t[s],u]))}n&&(this._drawLayerCanvasImage(n[0],n[1]),this._drawFog()),o=a.length;for(var c=r&&i>=0&&o>i?o-i:0;c<o;c++)this._drawLayerCanvasImage(a[c][0],a[c][1]);return e._fireEvent("renderend",{context:this.context}),!0},n.setToRedraw=function(){for(var t=this._getAllLayerToRender(),e=0,n=t.length;e<n;e++){var r=t[e].getRenderer();r&&r.canvas&&r.setToRedraw&&r.setToRedraw()}},n.updateMapSize=function(t){if(t&&!this._containerIsCanvas){var e=t.width+"px",n=t.height+"px",r=this.map._panels;r.mapWrapper.style.width=e,r.mapWrapper.style.height=n,this._updateCanvasSize()}},n.getMainPanel=function(){return this.map?this._containerIsCanvas?this.map._containerDOM:this.map._panels?this.map._panels.mapWrapper:null:null},n.toDataURL=function(t){return this.canvas?this.canvas.toDataURL(t):null},n.remove=function(){he.webgl&&"undefined"!=typeof document&&Be(document,"visibilitychange",this._thisVisibilitychange),this._resizeInterval&&clearInterval(this._resizeInterval),delete this.context,delete this.canvas,delete this.map,delete this._spatialRefChanged,this._cancelFrameLoop()},n.hitDetect=function(t){var e=this.map;if(e&&e.options.hitDetect&&!e.isInteracting()){for(var n=e._getLayers(),r="default",i=e.options.hitDetectLimit||0,o=0,a=n.length-1;a>=0;a--){var s=n[a];if(!(!s.options.hitDetect||s.isEmpty&&s.isEmpty())){var u=s._getRenderer();if(u&&u.hitDetect&&(!u.isBlank||!u.isBlank())){if("default"!==s.options.cursor&&u.hitDetect(t)){r=s.options.cursor||"pointer";break}if(o++,i>0&&o>i)break}}}e._trySetCursor(r)}},n._getLayerImage=function(t){var e=t._getRenderer();return e.getCanvasImage?e.getCanvasImage():null},n.initContainer=function(){var t=this.map._panels;function e(e,n,r,i){var o=je("div",n);return r&&(o.style.cssText=r),t[e]=o,i||We(o),o}var n=this.map._containerDOM;if(!this._containerIsCanvas){n.innerHTML="";var r="position:absolute;top:0px;left:0px;",i=e("mapWrapper","maptalks-wrapper","position:absolute;overflow:hidden;",!0),o=e("allLayers","maptalks-all-layers",r+"padding:0px;margin:0px;z-index:0;overflow:visible;",!0),a=e("backStatic","maptalks-back-static",r+"z-index:0;",!0),s=e("back","maptalks-back",r+"z-index:1;"),u=e("backLayer","maptalks-back-layer",r),c=e("canvasContainer","maptalks-canvas-layer",r+"border:none;z-index:2;"),l=e("frontStatic","maptalks-front-static",r+"z-index:3;",!0),h=e("front","maptalks-front",r+"z-index:4;",!0),f=e("frontLayer","maptalks-front-layer",r+"z-index:0;"),d=e("ui","maptalks-ui",r+"border:none;z-index:1;",!0),p=e("control","maptalks-control","z-index:1",!0);n.appendChild(i),o.appendChild(a),s.appendChild(u),s.layerDOM=u,o.appendChild(s),o.appendChild(c),h.appendChild(f),h.layerDOM=f,h.uiDOM=d,o.appendChild(l),o.appendChild(h),h.appendChild(d),i.appendChild(o),i.appendChild(p),this.createCanvas(),this.resetContainer();var m=this.map._getContainerDomSize();this.updateMapSize(m)}},n.isViewChanged=function(){if(void 0!==this._isViewChanged)return this._isViewChanged;var t=this._mapview,e=this._getMapView();return this._isViewChanged=!t||!K(t,e),this._isViewChanged},n._recordView=function(){var t=this.map;!t._onViewChange||t.isInteracting()||t.isAnimating()||K(t.getView(),t._getCurrentView())||t._onViewChange(t.getView())},n.isSpatialReferenceChanged=function(){return this._spatialRefChanged},n._getMapView=function(){var t=this.map,e=t._getPrjCenter();return{x:e.x,y:e.y,zoom:t.getZoom(),pitch:t.getPitch(),bearing:t.getBearing(),width:t.width,height:t.height}},n._frameLoop=function(t){var e=this;this.map?(this.renderFrame(t),this._animationFrame=T((function(t){e._frameLoop(t)}))):this._cancelFrameLoop()},n._cancelFrameLoop=function(){this._animationFrame&&E(this._animationFrame)},n._drawLayerCanvasImage=function(t,e){var n=this.context,r=e.point.round(),i=this.map.getDevicePixelRatio();1!==i&&r._multi(i);var o=e.image,a=o.width,s=o.height;if(!(r.x+a<=0||r.y+s<=0)){var u=t.options.opacity;if(m(u)||(u=1),!(u<=0)){var c=e.opacity;if(m(c)||(c=1),!(c<=0)){var l=n.globalAlpha;u<1&&(n.globalAlpha*=u),c<1&&(n.globalAlpha*=c),t.options.cssFilter&&(n.filter=t.options.cssFilter);var h=t.getRenderer(),f=h.__zoomTransformMatrix,d=h.clipCanvas(this.context);f&&(n.save(),n.setTransform.apply(n,f)),n.drawImage(o,0,0,a,s,r.x,r.y,a,s),f&&n.restore(),d&&n.restore(),"none"!==n.filter&&(n.filter="none"),n.globalAlpha=l}}}},n._drawCenterCross=function(){var t=this.map.options.centerCross;if(t){var e=this.context,n=new me(this.canvas.width/2,this.canvas.height/2);_(t)?t(e,n):hn.drawCross(this.context,n.x,n.y,2,"#f00")}},n._drawContainerExtent=function(){var t=this.map.options.cascadePitches,e=this.map.height-this.map._getVisualHeight(t[0]),n=this.map.height-this.map._getVisualHeight(t[1]),r=this.map.getContainerExtent(),i=this.context;i.beginPath(),i.moveTo(0,r.ymin),i.lineTo(r.xmax,r.ymin),i.stroke(),i.beginPath(),i.moveTo(0,e),i.lineTo(r.xmax,e),i.stroke(),i.beginPath(),i.moveTo(0,n),i.lineTo(r.xmax,n),i.stroke()},n._drawFog=function(){var t=this.map;if(!(t.getPitch()<=t.options.maxVisualPitch)&&t.options.fog){var e=t.getDevicePixelRatio(),n=this.context,r=t.getContainerExtent(),i=(t.height-t._getVisualHeight(75))*e;i<0&&(i=0);var o=r.ymin*e,a=Math.ceil(o-i),s=t.options.fogColor.join(),u=n.createLinearGradient(0,i,0,o+30),c=1-30/(a+30);u.addColorStop(0,"rgba("+s+", 0)"),u.addColorStop(.3,"rgba("+s+", 0.3)"),u.addColorStop(c,"rgba("+s+", 1)"),u.addColorStop(1,"rgba("+s+", 0)"),n.beginPath(),n.fillStyle=u,n.fillRect(0,i,Math.ceil(r.getWidth())*e,Math.ceil(a+30))}},n._getAllLayerToRender=function(){return this.map._getLayers()},n.clearCanvas=function(){this.canvas&&hn.clearRect(this.context,0,0,this.canvas.width,this.canvas.height)},n._updateCanvasSize=function(){if(!this.canvas||this._containerIsCanvas)return!1;var t=this.map,e=t.getSize(),n=this.canvas,r=t.getDevicePixelRatio();return(e.width*r!==n.width||e.height*r!==n.height)&&(n.height=r*e.height,n.width=r*e.width,n.style&&(n.style.width=e.width+"px",n.style.height=e.height+"px"),!0)},n.createCanvas=function(){this._containerIsCanvas?this.canvas=this.map._containerDOM:(this.canvas=je("canvas"),this._updateCanvasSize(),this.map._panels.canvasContainer.appendChild(this.canvas)),this.context=this.canvas.getContext("2d")},n._checkSize=function(){this.map&&!this.map.isInteracting()&&(Ze(this.map._containerDOM),this.map.checkSize())},n._setCheckSizeInterval=function(t){var e=this;clearInterval(this._resizeInterval),this._checkSizeInterval=t,this._resizeInterval=setInterval((function(){!e.map||e.map.isRemoved()?clearInterval(e._resizeInterval):e._checkSize()}),this._checkSizeInterval)},n._registerEvents=function(){var t=this,e=this.map;e.options.checkSize&&!A&&"undefined"!=typeof window&&this._setCheckSizeInterval(e.options.checkSizeInterval),he.mobile||e.on("_mousemove",this._onMapMouseMove,this),e.on("_dragrotatestart _dragrotating _dragrotateend _movestart _moving _moveend _zoomstart",(function(e){t._eventParam=e})),e.on("_zooming",(function(n){e.getPitch()||(t._zoomMatrix=n.matrix.container),t._eventParam=n})),e.on("_zoomend",(function(e){t._eventParam=e,delete t._zoomMatrix})),e.on("_spatialreferencechange",(function(){t._spatialRefChanged=!0})),he.webgl&&"undefined"!=typeof document&&Fe(document,"visibilitychange",this._thisVisibilitychange,this)},n._onMapMouseMove=function(t){var e=this,n=this.map;!n.isInteracting()&&n.options.hitDetect&&(this._hitDetectFrame&&E(this._hitDetectFrame),this._hitDetectFrame=T((function(){e.hitDetect(t.containerPoint)})))},n._getCanvasLayers=function(){return this.map._getLayers((function(t){return t.isCanvasRender()}))},n._onVisibilitychange=function(){"visible"===document.visibilityState&&this.setToRedraw()},e}(xs);ii.registerRenderer("canvas",bs),ii.mergeOptions({fog:!1,fogColor:[233,233,233]});var ws=Object.freeze({ResourceCache:gr,CanvasRenderer:mr,ImageGLRenderable:Na,MapRenderer:xs,MapCanvasRenderer:bs,Renderable:pr,ImageLayerCanvasRenderer:Ua,ImageLayerGLRenderer:Wa,TileLayerCanvasRenderer:cs,TileLayerGLRenderer:fs,CanvasTileLayerCanvasRenderer:ps,CanvasTileLayerGLRenderer:ms,OverlayLayerCanvasRenderer:gs,VectorLayerCanvasRenderer:_s,CanvasLayerRenderer:Va}),Ms={_getRenderPoints:function(){return[[this._getCenter2DPoint(this.getMap().getGLZoom())],null]}};Mi.include(Ms),ji.include(Ms),Di.include(Ms),Ni.include(Ms),zi.include({_getRenderPoints:function(t){var e=this.getMap();if("vertex"===t){for(var n=this._trimRing(this.getShell()),r=[],i=0,o=n.length;i<o;i++)r.push(e.coordToPoint(n[i],e.getGLZoom()));return[r,null]}return[[e.coordToPoint(this.getCenter(),e.getGLZoom())],null]}});var Ss={_getRenderPoints:function(t){var e,n=this.getMap(),r=n.getGLZoom(),i=null;if("point"===t)(e=this._getPath2DPoints(this._getPrjCoordinates(),!1,r))&&e.length>0&&Array.isArray(e[0])&&(e=e[0].concat(e[1]));else if("vertex"===t)if(i=[],(e=this._getPath2DPoints(this._getPrjCoordinates(),!1,r))&&e.length>0&&Array.isArray(e[0])){for(var o=0,a=e.length;o<a;o++)for(var s=0,u=e[o].length;s<u;s++)0===s?i.push([e[o][s],e[o][s+1]]):i.push([e[o][s-1],e[o][s]]);e=e[0].concat(e[1])}else for(var c=0,l=e.length;c<l;c++)0===c?i.push([e[c],e[c+1]]):i.push([e[c-1],e[c]]);else if("line"===t){e=[],i=[];var h=this._getPath2DPoints(this._getPrjCoordinates(),!1,r);if(h.length>0&&Array.isArray(h[0]))for(var f,d=1,p=h.length;d<p;d++){f=h[d],this instanceof bi&&f.length>0&&!f[0].equals(f[f.length-1])&&f.push(f[0]);for(var m=1,g=f.length;m<g;m++)e.push(f[m].add(f[m-1])._multi(.5)),i.push([f[m-1],f[m]])}else{this instanceof bi&&h.length>0&&!h[0].equals(h[h.length-1])&&h.push(h[0]);for(var v=1,y=h.length;v<y;v++)e.push(h[v].add(h[v-1])._multi(.5)),i.push([h[v-1],h[v]])}}else if("vertex-first"===t){var _=this._getPrjCoordinates();e=_.length?[n._prjToPoint(_[0],r)]:[],i=_.length?[[n._prjToPoint(_[0],r),n._prjToPoint(_[1],r)]]:[]}else if("vertex-last"===t){var x=this._getPrjCoordinates(),b=x.length;e=b?[n._prjToPoint(x[b-1],r)]:[];var w=b-1,M=b>1?b-2:b-1;i=b?[[n._prjToPoint(x[M],r),n._prjToPoint(x[w],r)]]:[]}else{var S=this._getProjection().project(this.getCenter());e=[n._prjToPoint(S,r)]}return[e,i]}};Ti.include(Ss),bi.include(Ss),Kr.include({_redrawWhenPitch:function(){return!1},_redrawWhenRotate:function(){return!1}});var Ts={_redrawWhenPitch:function(){return!0},_redrawWhenRotate:function(){return this instanceof ji||this instanceof Ni},_paintAsPath:function(){var t=this.getMap();return this.getAltitude()>0||t.getPitch()||this instanceof ji&&t.getBearing()},_getPaintParams:function(){var t=this.getMap();if(this._paintAsPath())return bi.prototype._getPaintParams.call(this,!0);var e=this._getPrjCoordinates(),n=t._prjToPoint(e,t.getGLZoom()),r=this._getRenderSize(n);return[n].concat(r)},_paintOn:function(){return this._paintAsPath()?hn.polygon.apply(hn,arguments):hn.ellipse.apply(hn,arguments)},_getRenderSize:function(t){var e=this.getMap(),n=e.getGLZoom(),r=this._getPrjExtent(),i=e._prjToPoint(r.getMin(),n),o=e._prjToPoint(r.getMax(),n);return[Math.abs(o.x-i.x)/2,Math.abs(o.y-t.y),Math.abs(t.y-i.y)]}};ji.include(Ts),Di.include(Ts),zi.include({_getPaintParams:function(){var t=this.getMap().getGLZoom(),e=this._getPrjShell();return[this._getPath2DPoints(e,!1,t)]},_paintOn:hn.polygon}),Ni.include(Ts,{_redrawWhenPitch:function(){return!0},_getPaintParams:function(){if(this._paintAsPath())return bi.prototype._getPaintParams.call(this,!0);var t=this.getMap(),e=t._prjToPoint(this._getPrjCoordinates(),t.getGLZoom());return[e,this._getRenderSize(e)[0],[this.getStartAngle(),this.getEndAngle()]]},_paintOn:function(){if(this._paintAsPath())return hn.polygon.apply(hn,arguments);var t=this.getMap().getBearing(),e=arguments;return t&&(e[3]=e[3].slice(0),e[3][0]+=t,e[3][1]+=t),hn.sector.apply(hn,e)}}),_i.include({_paintAsPath:function(){return!0}}),Ti.include({arrowStyles:{classic:[3,4]},_getArrowShape:function(t,e,n,r,i){if(!t||!e||t.equals(e))return null;i||(i=0);var o,a=n*r[0],s=n*r[1]+i,u=a/2+i;(o=e.nextCtrlPoint||e.prevCtrlPoint?e.prevCtrlPoint?e.sub(new me(e.prevCtrlPoint)):e.sub(new me(e.nextCtrlPoint)):e.sub(t))._unit();var c=e.sub(o.multi(s));o._perp();var l=c.add(o.multi(u));return o._multi(-1),[l,e,c.add(o.multi(u)),l]},_getPaintParams:function(){var t=this._getPrjCoordinates();return[this._getPath2DPoints(t,!1,this.getMap().getGLZoom())]},_paintOn:function(t,e,n,r,i){this.options.smoothness?hn.paintSmoothLine(t,e,n,this.options.smoothness,!1,this._animIdx,this._animTailRatio):hn.path(t,e,n,null,i),this._paintArrow(t,e,n)},_getArrowPlacement:function(){return this.options.arrowPlacement},_getArrowStyle:function(){var t=this.options.arrowStyle;return t?Array.isArray(t)?t:this.arrowStyles[t]:null},_getArrows:function(t,e,n){var r=this._getArrowStyle();if(!r||t.length<2)return[];for(var i=t.length>0&&Array.isArray(t[0])?t:[t],o=this._getArrowPlacement(),a=[],s=this.getMap(),u=s.coordToContainerPoint(this.getFirstCoordinate()),c=s.coordToContainerPoint(this.getLastCoordinate()),l=i.length-1;l>=0;l--){if("vertex-first"===o||"vertex-firstlast"===o&&i[l][0].closeTo(u,.01)){var h=this._getArrowShape(i[l][1],i[l][0],e,r,n);h&&a.push(h)}if("vertex-last"===o||"vertex-firstlast"===o&&i[l][i[l].length-1].closeTo(c,.01)){var f=this._getArrowShape(i[l][i[l].length-2],i[l][i[l].length-1],e,r,n);f&&a.push(f)}else"point"===o&&this._getArrowPoints(a,i[l],e,r,n)}return a},_getArrowPoints:function(t,e,n,r,i){for(var o=0,a=e.length-1;o<a;o++){var s=this._getArrowShape(e[o],e[o+1],n,r,i);s&&t.push(s)}},_paintArrow:function(t,e,n){var r=this._getInternalSymbol().lineWidth;(!m(r)||r<3)&&(r=3);var i=this._getArrows(e,r);if(i.length){t.setLineDash&&t.setLineDash([]);for(var o=i.length-1;o>=0;o--)t.fillStyle=t.strokeStyle,hn.polygon(t,i[o],n,n)}}}),bi.include({_getPaintParams:function(t){var e=this.getMap().getGLZoom(),n=this._getPrjShell(),r=this._getPath2DPoints(n,t,e),i=r.length>0&&Array.isArray(r[0]);i&&(r=[[r[0]],[r[1]]]);var o=this._getPrjHoles(),a=[];if(o&&o.length>0){for(var s=this._simplified,u=0;u<o.length;u++){var c=this._getPath2DPoints(o[u],t,e);Array.isArray(c)&&i?Array.isArray(c[0])?(r[0].push(c[0]),r[1].push(c[1])):r[0].push(c):a.push(c)}s&&(this._simplified=s)}return i||I(r=[r],a),[r]},_paintOn:function(t,e,n,r,i){hn.polygon(t,e,n,r,i,this.options.smoothness)}}),ii.VERSION="0.49.4"}.call(this,n("eef6"),n("2409"))},f869:function(t,e){t.exports="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView},f97a:function(t,e,n){var r=n("ca14"),i=n("c7e7"),o=n("081e"),a=n("41a4"),s=n("53b8"),u=n("c813"),c=s("IE_PROTO"),l=r.Object,h=l.prototype;t.exports=u?l.getPrototypeOf:function(t){var e=a(t);if(i(e,c))return e[c];var n=e.constructor;return o(n)&&e instanceof n?n.prototype:e instanceof l?h:null}},fc50:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAYAAAAHCAIAAACk8qu6AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA0ppVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDIxIDc5LjE1NTc3MiwgMjAxNC8wMS8xMy0xOTo0NDowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6RTM3RTZFNDFBOTZDMTFFNUE2QTA4M0M3MDI4QUVDMTQiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6RTM3RTZFNDBBOTZDMTFFNUE2QTA4M0M3MDI4QUVDMTQiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTQgKFdpbmRvd3MpIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9ImFkb2JlOmRvY2lkOnBob3Rvc2hvcDo3ZmI2MGZkMi1hOTZjLTExZTUtYWU4Yi1kYzQ2ODQxNzA1ZmIiIHN0UmVmOmRvY3VtZW50SUQ9ImFkb2JlOmRvY2lkOnBob3Rvc2hvcDo3ZmI2MGZkMi1hOTZjLTExZTUtYWU4Yi1kYzQ2ODQxNzA1ZmIiLz4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz6Qths+AAAAgElEQVR42iSNMQ4EERiFrd3KKHEBKkeYYziAxAXVCiq9SkPpDMQ0s9k/s694yZd8eQ/NOccY3yettfu+31LKnLMQopQSQsAYv2qt3ntQEELHcVhrsdZaKYWenOfJOf/EGHvvhJDrulJKjDG81qKUOueMMSACIljZe/8fgaF/AgwARJdHBal88EIAAAAASUVORK5CYII="},fdf1:function(t,e,n){var r=n("c252"),i=n("41a4"),o=Math.floor,a=r("".charAt),s=r("".replace),u=r("".slice),c=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,l=/\$([$&'`]|\d{1,2})/g;t.exports=function(t,e,n,r,h,f){var d=n+t.length,p=r.length,m=l;return void 0!==h&&(h=i(h),m=c),s(f,m,(function(i,s){var c;switch(a(s,0)){case"$":return"$";case"&":return t;case"`":return u(e,0,n);case"'":return u(e,d);case"<":c=h[u(s,1,-1)];break;default:var l=+s;if(0===l)return i;if(l>p){var f=o(l/10);return 0===f?i:f<=p?void 0===r[f-1]?a(s,1):r[f-1]+a(s,1):i}c=r[l-1]}return void 0===c?"":c}))}},fe2f:function(t,e,n){"use strict";var r=n("d582").IteratorPrototype,i=n("a30f"),o=n("7e3c"),a=n("9207"),s=n("db7f"),u=function(){return this};t.exports=function(t,e,n){var c=e+" Iterator";return t.prototype=i(r,{next:o(1,n)}),a(t,c,!1,!0),s[c]=u,t}},fec6:function(t,e,n){var r=n("cc43"),i=n("097d"),o=n("9cd9").f,a=n("9a1e"),s="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];t.exports.f=function(t){return s&&"Window"==r(t)?function(t){try{return o(t)}catch(t){return a(s)}}(t):o(i(t))}}})},module.exports=e()}).call(this,__webpack_require__(140).setImmediate)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(9),i=n(8),o=s(n(18)),a=s(n(270));function s(t){return t&&t.__esModule?t:{default:t}}e.default={name:"Sidebar",computed:{nav:function(){return this.$store.state.user.addRouters}},props:{theme:{type:String,default:"light"},sidebarList:{type:Array,default:function(){return[]}}},data:function(){return{currentSelect:[],openKeys:[],currentOpen:[],isOpenSideBar:!0}},mounted:function(){var t=this;this.$watch("$route",(function(e){e.path&&t.highMenu(e)}),{immediate:!0,deep:!0})},methods:{findParent:function(t,e){var n=[];return function e(r,i){for(var o=0;o<r.length;o++){var a=r[o];if(a.name===i){n.push(a),e(t,a.meta.parentId);break}a.children&&e(a.children,i)}}(t,e),n},highMenu:function(t){var e=this.findParent(this.nav[0].children,t.name),n=(0,i.find)(e,{type:1});if(this.currentSelect=[n.name],(0,i.isEmpty)(t.meta.subType))this.isOpenSideBar=!0;else{var r=JSON.parse(t.meta.subType);r&&"1"===r.fullPage?this.isOpenSideBar=!1:this.isOpenSideBar=!0}},findCurrentNodes:function(t,e,n){var r=this;return t.forEach((function(t){t.name===e?n.push(t):t.children&&r.findCurrentNodes(t.children,e,n)})),n},handleNav:function(t){t.item;var e=t.key;t.keyPath;if(!e)return!1;var n=[];if(this.findCurrentNodes(this.nav[0].children,e,n),!(0,i.isEmpty)(n))if(1===n[0].meta.chainType){var r=e.indexOf("http")>-1?e:"http://"+e;window.open(r)}else this.currentSelect=[e],this.$router.push({name:e}).then((function(t){}))},renderIcon:function(t){var e=this.$createElement;return t?e("i",{class:(0,o.default)(["icon","iconfont",t])}):e(a.default)},getChildrenType1:function(t){return t.children.every((function(t){return 3===t.type}))}},render:function(){var t=this,e=arguments[0],n=function n(r){if(r){if(t.getChildrenType1(r))return e("a-menu-item",{key:r.name},[t.renderIcon(r.meta.icon),e("span",[r.meta.title])]);var i=r.children.map((function(r){return r.children?n(r):1===r.type?e("a-menu-item",{key:r.name},[t.renderIcon(r.meta.icon),e("span",[r.meta.title])]):null}));return e("a-sub-menu",{key:r.name},[e("span",{slot:"title"},[t.renderIcon(r.meta.icon),e("span",[r.meta.title])]),i])}return[]},o=this.sidebarList&&!(0,i.isEmpty)(this.sidebarList)?this.sidebarList.map((function(r){return r.meta&&r.meta.subType?null:!r.children||t.getChildrenType1(r)?e("a-menu-item",{key:r.name},[t.renderIcon(r.meta.icon),e("span",[r.meta.title])]):n(r)})):null,a=o&&o.length?e("a-menu",{attrs:{mode:"inline",theme:this.theme,inlineCollapsed:!0,selectedKeys:this.currentSelect},on:{click:this.handleNav}},[o]):null;return e("a-layout-sider",{class:r.prefixCls+"-slider",attrs:{width:this.isOpenSideBar?250:0}},[a])}}},function(t,e,n){var r=n(22)(n(11),"Map");t.exports=r},function(t,e,n){var r=n(309);t.exports=function(t){return null==t?"":r(t)}},function(t,e,n){var r=n(51);t.exports=function(t){if("string"==typeof t||r(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}},function(t,e,n){var r=n(89),i=n(55),o=Object.prototype.hasOwnProperty;t.exports=function(t,e,n){var a=t[e];o.call(t,e)&&i(a,n)&&(void 0!==n||e in t)||r(t,e,n)}},function(t,e,n){var r=n(143);t.exports=function(t,e,n){"__proto__"==e&&r?r(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}},function(t,e){t.exports=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}},function(t,e){t.exports=function(t){return t}},function(t,e){t.exports=function(t,e){var n=-1,r=t.length;for(e||(e=Array(r));++n<r;)e[n]=t[n];return e}},function(t,e,n){var r=n(359);t.exports=function(t){var e=new t.constructor(t.byteLength);return new r(e).set(new r(t)),e}},function(t,e){var n=Object.prototype;t.exports=function(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||n)}},function(t,e,n){(function(t){var r=n(11),i=n(362),o=e&&!e.nodeType&&e,a=o&&"object"==typeof t&&t&&!t.nodeType&&t,s=a&&a.exports===o?r.Buffer:void 0,u=(s?s.isBuffer:void 0)||i;t.exports=u}).call(this,n(44)(t))},function(t,e){t.exports=function(t){return function(e){return t(e)}}},function(t,e,n){(function(t){var r=n(135),i=e&&!e.nodeType&&e,o=i&&"object"==typeof t&&t&&!t.nodeType&&t,a=o&&o.exports===i&&r.process,s=function(){try{var t=o&&o.require&&o.require("util").types;return t||a&&a.binding&&a.binding("util")}catch(t){}}();t.exports=s}).call(this,n(44)(t))},function(t,e,n){var r=n(386),i=n(157),o=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols,s=a?function(t){return null==t?[]:(t=Object(t),r(a(t),(function(e){return o.call(t,e)})))}:i;t.exports=s},function(t,e,n){var r=n(390),i=n(85),o=n(391),a=n(392),s=n(393),u=n(28),c=n(142),l=c(r),h=c(i),f=c(o),d=c(a),p=c(s),m=u;(r&&"[object DataView]"!=m(new r(new ArrayBuffer(1)))||i&&"[object Map]"!=m(new i)||o&&"[object Promise]"!=m(o.resolve())||a&&"[object Set]"!=m(new a)||s&&"[object WeakMap]"!=m(new s))&&(m=function(t){var e=u(t),n="[object Object]"==e?t.constructor:void 0,r=n?c(n):"";if(r)switch(r){case l:return"[object DataView]";case h:return"[object Map]";case f:return"[object Promise]";case d:return"[object Set]";case p:return"[object WeakMap]"}return e}),t.exports=m},function(t,e,n){t.exports={default:n(165),__esModule:!0}},function(t,e,n){var r=n(39);t.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==r(t)?t.split(""):Object(t)}},function(t,e,n){var r=n(1),i=n(5),o=i["__core-js_shared__"]||(i["__core-js_shared__"]={});(t.exports=function(t,e){return o[t]||(o[t]=void 0!==e?e:{})})("versions",[]).push({version:r.version,mode:n(69)?"pure":"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})},function(t,e){var n=0,r=Math.random();t.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++n+r).toString(36))}},function(t,e){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(t,e){e.f={}.propertyIsEnumerable},function(t,e,n){"use strict";var r=n(69),i=n(7),o=n(191),a=n(23),s=n(25),u=n(192),c=n(74),l=n(195),h=n(6)("iterator"),f=!([].keys&&"next"in[].keys()),d=function(){return this};t.exports=function(t,e,n,p,m,g,v){u(n,e,p);var y,_,x,b=function(t){if(!f&&t in T)return T[t];switch(t){case"keys":case"values":return function(){return new n(this,t)}}return function(){return new n(this,t)}},w=e+" Iterator",M="values"==m,S=!1,T=t.prototype,E=T[h]||T["@@iterator"]||m&&T[m],A=E||b(m),C=m?M?b("entries"):A:void 0,P="Array"==e&&T.entries||E;if(P&&(x=l(P.call(new t)))!==Object.prototype&&x.next&&(c(x,w,!0),r||"function"==typeof x[h]||a(x,h,d)),M&&E&&"values"!==E.name&&(S=!0,A=function(){return E.call(this)}),r&&!v||!f&&!S&&T[h]||a(T,h,A),s[e]=A,s[w]=d,m)if(y={values:M?A:b("values"),keys:g?A:b("keys"),entries:C},v)for(_ in y)_ in T||o(T,_,y[_]);else i(i.P+i.F*(f||S),e,y);return y}},function(t,e,n){var r=n(5).document;t.exports=r&&r.documentElement},function(t,e,n){var r=n(15);t.exports=function(t,e,n,i){try{return i?e(r(n)[0],n[1]):e(n)}catch(e){var o=t.return;throw void 0!==o&&r(o.call(t)),e}}},function(t,e,n){var r=n(25),i=n(6)("iterator"),o=Array.prototype;t.exports=function(t){return void 0!==t&&(r.Array===t||o[i]===t)}},function(t,e,n){var r=n(15),i=n(40),o=n(6)("species");t.exports=function(t,e){var n,a=r(t).constructor;return void 0===a||null==(n=r(a)[o])?e:i(n)}},function(t,e,n){var r,i,o,a=n(29),s=n(202),u=n(107),c=n(70),l=n(5),h=l.process,f=l.setImmediate,d=l.clearImmediate,p=l.MessageChannel,m=l.Dispatch,g=0,v={},y=function(){var t=+this;if(v.hasOwnProperty(t)){var e=v[t];delete v[t],e()}},_=function(t){y.call(t.data)};f&&d||(f=function(t){for(var e=[],n=1;arguments.length>n;)e.push(arguments[n++]);return v[++g]=function(){s("function"==typeof t?t:Function(t),e)},r(g),g},d=function(t){delete v[t]},"process"==n(39)(h)?r=function(t){h.nextTick(a(y,t,1))}:m&&m.now?r=function(t){m.now(a(y,t,1))}:p?(o=(i=new p).port2,i.port1.onmessage=_,r=a(o.postMessage,o,1)):l.addEventListener&&"function"==typeof postMessage&&!l.importScripts?(r=function(t){l.postMessage(t+"","*")},l.addEventListener("message",_,!1)):r="onreadystatechange"in c("script")?function(t){u.appendChild(c("script")).onreadystatechange=function(){u.removeChild(this),y.call(t)}}:function(t){setTimeout(a(y,t,1),0)}),t.exports={set:f,clear:d}},function(t,e){t.exports=function(t){try{return{e:!1,v:t()}}catch(t){return{e:!0,v:t}}}},function(t,e,n){var r=n(15),i=n(30),o=n(78);t.exports=function(t,e){if(r(t),i(e)&&e.constructor===t)return e;var n=o.f(t);return(0,n.resolve)(e),n.promise}},function(t,e,n){var r=n(6)("iterator"),i=!1;try{var o=[7][r]();o.return=function(){i=!0},Array.from(o,(function(){throw 2}))}catch(t){}t.exports=function(t,e){if(!e&&!i)return!1;var n=!1;try{var o=[7],a=o[r]();a.next=function(){return{done:n=!0}},o[r]=function(){return a},t(o)}catch(t){}return n}},function(t,e,n){var r=n(26),i=r.slice,o=r.pluck,a=r.each,s=r.bind,u=r.create,c=r.isList,l=r.isFunction,h=r.isObject;t.exports={createStore:d};var f={version:"2.0.12",enabled:!1,get:function(t,e){var n=this.storage.read(this._namespacePrefix+t);return this._deserialize(n,e)},set:function(t,e){return void 0===e?this.remove(t):(this.storage.write(this._namespacePrefix+t,this._serialize(e)),e)},remove:function(t){this.storage.remove(this._namespacePrefix+t)},each:function(t){var e=this;this.storage.each((function(n,r){t.call(e,e._deserialize(n),(r||"").replace(e._namespaceRegexp,""))}))},clearAll:function(){this.storage.clearAll()},hasNamespace:function(t){return this._namespacePrefix=="__storejs_"+t+"_"},createStore:function(){return d.apply(this,arguments)},addPlugin:function(t){this._addPlugin(t)},namespace:function(t){return d(this.storage,this.plugins,t)}};function d(t,e,n){n||(n=""),t&&!c(t)&&(t=[t]),e&&!c(e)&&(e=[e]);var r=n?"__storejs_"+n+"_":"",d=n?new RegExp("^"+r):null;if(!/^[a-zA-Z0-9_\-]*$/.test(n))throw new Error("store.js namespaces can only have alphanumerics + underscores and dashes");var p=u({_namespacePrefix:r,_namespaceRegexp:d,_testStorage:function(t){try{var e="__storejs__test__";t.write(e,e);var n=t.read(e)===e;return t.remove(e),n}catch(t){return!1}},_assignPluginFnProp:function(t,e){var n=this[e];this[e]=function(){var e=i(arguments,0),r=this;function o(){if(n)return a(arguments,(function(t,n){e[n]=t})),n.apply(r,e)}var s=[o].concat(e);return t.apply(r,s)}},_serialize:function(t){return JSON.stringify(t)},_deserialize:function(t,e){if(!t)return e;var n="";try{n=JSON.parse(t)}catch(e){n=t}return void 0!==n?n:e},_addStorage:function(t){this.enabled||this._testStorage(t)&&(this.storage=t,this.enabled=!0)},_addPlugin:function(t){var e=this;if(c(t))a(t,(function(t){e._addPlugin(t)}));else if(!o(this.plugins,(function(e){return t===e}))){if(this.plugins.push(t),!l(t))throw new Error("Plugins must be function values that return objects");var n=t.call(this);if(!h(n))throw new Error("Plugins must return an object of function properties");a(n,(function(n,r){if(!l(n))throw new Error("Bad plugin property: "+r+" from plugin "+t.name+". Plugins should only return functions.");e._assignPluginFnProp(n,r)}))}},addStorage:function(t){!function(){var t="undefined"==typeof console?null:console;if(t){var e=t.warn?t.warn:t.log;e.apply(t,arguments)}}("store.addStorage(storage) is deprecated. Use createStore([storages])"),this._addStorage(t)}},f,{plugins:[]});return p.raw={},a(p,(function(t,e){l(t)&&(p.raw[e]=s(p,t))})),a(t,(function(t){p._addStorage(t)})),a(e,(function(t){p._addPlugin(t)})),p}},function(t,e,n){var r=n(115),i=n(209),o=[n(213)];t.exports=r.createStore(i,o)},function(t,e,n){var r=n(26).Global;function i(){return r.localStorage}function o(t){return i().getItem(t)}t.exports={name:"localStorage",read:o,write:function(t,e){return i().setItem(t,e)},each:function(t){for(var e=i().length-1;e>=0;e--){var n=i().key(e);t(o(n),n)}},remove:function(t){return i().removeItem(t)},clearAll:function(){return i().clear()}}},function(t,e,n){var r=n(26),i=r.Global,o=r.trim;t.exports={name:"cookieStorage",read:function(t){if(!t||!c(t))return null;var e="(?:^|.*;\\s*)"+escape(t).replace(/[\-\.\+\*]/g,"\\$&")+"\\s*\\=\\s*((?:[^;](?!;))*[^;]?).*";return unescape(a.cookie.replace(new RegExp(e),"$1"))},write:function(t,e){if(!t)return;a.cookie=escape(t)+"="+escape(e)+"; expires=Tue, 19 Jan 2038 03:14:07 GMT; path=/"},each:s,remove:u,clearAll:function(){s((function(t,e){u(e)}))}};var a=i.document;function s(t){for(var e=a.cookie.split(/; ?/g),n=e.length-1;n>=0;n--)if(o(e[n])){var r=e[n].split("="),i=unescape(r[0]);t(unescape(r[1]),i)}}function u(t){t&&c(t)&&(a.cookie=escape(t)+"=; expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/")}function c(t){return new RegExp("(?:^|;\\s*)"+escape(t).replace(/[\-\.\+\*]/g,"\\$&")+"\\s*\\=").test(a.cookie)}},function(t,e,n){var r=n(26).Global;function i(){return r.sessionStorage}function o(t){return i().getItem(t)}t.exports={name:"sessionStorage",read:o,write:function(t,e){return i().setItem(t,e)},each:function(t){for(var e=i().length-1;e>=0;e--){var n=i().key(e);t(o(n),n)}},remove:function(t){return i().removeItem(t)},clearAll:function(){return i().clear()}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=u(n(21)),i=u(n(45)),o=u(n(121)),a=n(27),s=n(13);function u(t){return t&&t.__esModule?t:{default:t}}var c=!1,l=[],h=o.default.create({timeout:6e4,withCredentials:!0});function f(t){if(!t)return{};if(t instanceof FormData)return t;var e=new FormData,n=function(n){var r=t[n];Array.isArray(t[n])?t[n].forEach((function(t){e.append(n,t)})):e.append(n,r)};for(var r in t)n(r);return e}h.interceptors.request.use((function(t){return t.headers["Authorization-sys"]||(t.headers["Authorization-sys"]="Bearer "+s.localStore.get("access_token")),t.url=t.url.replace(/{\w+}/g,(function(e){var n=e.substring(1,e.length-1),r=t.params[n];return["delete","get"].includes(t.method)&&delete t.params[n],r})),t.baseURL=s.sessionStore.get("BASE_URL"),t}),(function(t){return i.default.reject(t)})),h.interceptors.response.use((function(t){return t.data}),(function(t){if(t&&t.response&&(401===t.response.status||400===t.response.status)){var e=s.sessionStore.get("IAM_BASE_URL")+"/iam/v1/oauth/logout?redirect_uri="+window.origin;return(t.response.config.url.includes("refresh/token")||t.response.config.url.includes("oauth/token"))&&(s.storage.clearAll(),window.open(e,"_self")),c?new i.default((function(e){l.push((function(n){t.config.headers["Authorization-sys"]="Bearer "+n,e(h(t.config))}))})):(c=!0,(0,a.refreshToken)({refreshToken:"Bearer "+s.localStore.get("refresh_token")}).then((function(e){var n=e.data,r=n.access_token,i=n.refresh_token;return s.localStore.set("access_token",r),s.localStore.set("refresh_token",i),t.config.headers["Authorization-sys"]="Bearer "+r,l.forEach((function(t){return t(r)})),l=[],h(t.config)})).catch((function(t){s.storage.clearAll(),window.open(e,"_self")})).finally((function(){c=!1})))}return i.default.reject(t)})),e.default={service:h,get:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h.get(t,{params:e,headers:(0,r.default)({},n)})},post:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h.post(t,e,{headers:n})},postQuery:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h.post(t,{},{headers:n,params:e})},put:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h.put(t,e,{headers:n})},file:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h.post(t,f(e),{headers:(0,r.default)({"Content-Type":"multipart/form-data"},n)})},download:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h.get(t,{params:e,responseType:"blob",headers:(0,r.default)({},n)})},delete:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return h.delete(t,{params:e,headers:(0,r.default)({"Content-Type":"multipart/form-data"},n)})}}},function(t,e,n){t.exports=n(216)},function(t,e,n){"use strict";t.exports=function(t,e){return function(){for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];return t.apply(e,n)}}},function(t,e,n){"use strict";var r=n(4);function i(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}t.exports=function(t,e,n){if(!e)return t;var o;if(n)o=n(e);else if(r.isURLSearchParams(e))o=e.toString();else{var a=[];r.forEach(e,(function(t,e){null!=t&&(r.isArray(t)?e+="[]":t=[t],r.forEach(t,(function(t){r.isDate(t)?t=t.toISOString():r.isObject(t)&&(t=JSON.stringify(t)),a.push(i(e)+"="+i(t))})))})),o=a.join("&")}if(o){var s=t.indexOf("#");-1!==s&&(t=t.slice(0,s)),t+=(-1===t.indexOf("?")?"?":"&")+o}return t}},function(t,e){var n,r,i=t.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(t){if(n===setTimeout)return setTimeout(t,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:o}catch(t){n=o}try{r="function"==typeof clearTimeout?clearTimeout:a}catch(t){r=a}}();var u,c=[],l=!1,h=-1;function f(){l&&u&&(l=!1,u.length?c=u.concat(c):h=-1,c.length&&d())}function d(){if(!l){var t=s(f);l=!0;for(var e=c.length;e;){for(u=c,c=[];++h<e;)u&&u[h].run();h=-1,e=c.length}u=null,l=!1,function(t){if(r===clearTimeout)return clearTimeout(t);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(t);try{r(t)}catch(e){try{return r.call(null,t)}catch(e){return r.call(this,t)}}}(t)}}function p(t,e){this.fun=t,this.array=e}function m(){}i.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];c.push(new p(t,e)),1!==c.length||l||s(d)},p.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=m,i.addListener=m,i.once=m,i.off=m,i.removeListener=m,i.removeAllListeners=m,i.emit=m,i.prependListener=m,i.prependOnceListener=m,i.listeners=function(t){return[]},i.binding=function(t){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(t){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},function(t,e,n){"use strict";t.exports=function(t,e,n,r,i){return t.config=e,n&&(t.code=n),t.request=r,t.response=i,t.isAxiosError=!0,t.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code}},t}},function(t,e,n){"use strict";var r=n(4),i=n(222),o=n(223),a=n(123),s=n(224),u=n(227),c=n(228),l=n(127);t.exports=function(t){return new Promise((function(e,n){var h=t.data,f=t.headers,d=t.responseType;r.isFormData(h)&&delete f["Content-Type"];var p=new XMLHttpRequest;if(t.auth){var m=t.auth.username||"",g=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";f.Authorization="Basic "+btoa(m+":"+g)}var v=s(t.baseURL,t.url);function y(){if(p){var r="getAllResponseHeaders"in p?u(p.getAllResponseHeaders()):null,o={data:d&&"text"!==d&&"json"!==d?p.response:p.responseText,status:p.status,statusText:p.statusText,headers:r,config:t,request:p};i(e,n,o),p=null}}if(p.open(t.method.toUpperCase(),a(v,t.params,t.paramsSerializer),!0),p.timeout=t.timeout,"onloadend"in p?p.onloadend=y:p.onreadystatechange=function(){p&&4===p.readyState&&(0!==p.status||p.responseURL&&0===p.responseURL.indexOf("file:"))&&setTimeout(y)},p.onabort=function(){p&&(n(l("Request aborted",t,"ECONNABORTED",p)),p=null)},p.onerror=function(){n(l("Network Error",t,null,p)),p=null},p.ontimeout=function(){var e="timeout of "+t.timeout+"ms exceeded";t.timeoutErrorMessage&&(e=t.timeoutErrorMessage),n(l(e,t,t.transitional&&t.transitional.clarifyTimeoutError?"ETIMEDOUT":"ECONNABORTED",p)),p=null},r.isStandardBrowserEnv()){var _=(t.withCredentials||c(v))&&t.xsrfCookieName?o.read(t.xsrfCookieName):void 0;_&&(f[t.xsrfHeaderName]=_)}"setRequestHeader"in p&&r.forEach(f,(function(t,e){void 0===h&&"content-type"===e.toLowerCase()?delete f[e]:p.setRequestHeader(e,t)})),r.isUndefined(t.withCredentials)||(p.withCredentials=!!t.withCredentials),d&&"json"!==d&&(p.responseType=t.responseType),"function"==typeof t.onDownloadProgress&&p.addEventListener("progress",t.onDownloadProgress),"function"==typeof t.onUploadProgress&&p.upload&&p.upload.addEventListener("progress",t.onUploadProgress),t.cancelToken&&t.cancelToken.promise.then((function(t){p&&(p.abort(),n(t),p=null)})),h||(h=null),p.send(h)}))}},function(t,e,n){"use strict";var r=n(125);t.exports=function(t,e,n,i,o){var a=new Error(t);return r(a,e,n,i,o)}},function(t,e,n){"use strict";t.exports=function(t){return!(!t||!t.__CANCEL__)}},function(t,e,n){"use strict";var r=n(4);t.exports=function(t,e){e=e||{};var n={},i=["url","method","data"],o=["headers","auth","proxy","params"],a=["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","timeoutMessage","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","decompress","maxContentLength","maxBodyLength","maxRedirects","transport","httpAgent","httpsAgent","cancelToken","socketPath","responseEncoding"],s=["validateStatus"];function u(t,e){return r.isPlainObject(t)&&r.isPlainObject(e)?r.merge(t,e):r.isPlainObject(e)?r.merge({},e):r.isArray(e)?e.slice():e}function c(i){r.isUndefined(e[i])?r.isUndefined(t[i])||(n[i]=u(void 0,t[i])):n[i]=u(t[i],e[i])}r.forEach(i,(function(t){r.isUndefined(e[t])||(n[t]=u(void 0,e[t]))})),r.forEach(o,c),r.forEach(a,(function(i){r.isUndefined(e[i])?r.isUndefined(t[i])||(n[i]=u(void 0,t[i])):n[i]=u(void 0,e[i])})),r.forEach(s,(function(r){r in e?n[r]=u(t[r],e[r]):r in t&&(n[r]=u(void 0,t[r]))}));var l=i.concat(o).concat(a).concat(s),h=Object.keys(t).concat(Object.keys(e)).filter((function(t){return-1===l.indexOf(t)}));return r.forEach(h,c),n}},function(t,e,n){"use strict";function r(t){this.message=t}r.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},r.prototype.__CANCEL__=!0,t.exports=r},function(t,e,n){"use strict";var r=Object.prototype.hasOwnProperty,i=Array.isArray,o=function(){for(var t=[],e=0;e<256;++e)t.push("%"+((e<16?"0":"")+e.toString(16)).toUpperCase());return t}(),a=function(t,e){for(var n=e&&e.plainObjects?Object.create(null):{},r=0;r<t.length;++r)void 0!==t[r]&&(n[r]=t[r]);return n};t.exports={arrayToObject:a,assign:function(t,e){return Object.keys(e).reduce((function(t,n){return t[n]=e[n],t}),t)},combine:function(t,e){return[].concat(t,e)},compact:function(t){for(var e=[{obj:{o:t},prop:"o"}],n=[],r=0;r<e.length;++r)for(var o=e[r],a=o.obj[o.prop],s=Object.keys(a),u=0;u<s.length;++u){var c=s[u],l=a[c];"object"==typeof l&&null!==l&&-1===n.indexOf(l)&&(e.push({obj:a,prop:c}),n.push(l))}return function(t){for(;t.length>1;){var e=t.pop(),n=e.obj[e.prop];if(i(n)){for(var r=[],o=0;o<n.length;++o)void 0!==n[o]&&r.push(n[o]);e.obj[e.prop]=r}}}(e),t},decode:function(t,e,n){var r=t.replace(/\+/g," ");if("iso-8859-1"===n)return r.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(r)}catch(t){return r}},encode:function(t,e,n){if(0===t.length)return t;var r="string"==typeof t?t:String(t);if("iso-8859-1"===n)return escape(r).replace(/%u[0-9a-f]{4}/gi,(function(t){return"%26%23"+parseInt(t.slice(2),16)+"%3B"}));for(var i="",a=0;a<r.length;++a){var s=r.charCodeAt(a);45===s||46===s||95===s||126===s||s>=48&&s<=57||s>=65&&s<=90||s>=97&&s<=122?i+=r.charAt(a):s<128?i+=o[s]:s<2048?i+=o[192|s>>6]+o[128|63&s]:s<55296||s>=57344?i+=o[224|s>>12]+o[128|s>>6&63]+o[128|63&s]:(a+=1,s=65536+((1023&s)<<10|1023&r.charCodeAt(a)),i+=o[240|s>>18]+o[128|s>>12&63]+o[128|s>>6&63]+o[128|63&s])}return i},isBuffer:function(t){return!(!t||"object"!=typeof t)&&!!(t.constructor&&t.constructor.isBuffer&&t.constructor.isBuffer(t))},isRegExp:function(t){return"[object RegExp]"===Object.prototype.toString.call(t)},merge:function t(e,n,o){if(!n)return e;if("object"!=typeof n){if(i(e))e.push(n);else{if(!e||"object"!=typeof e)return[e,n];(o&&(o.plainObjects||o.allowPrototypes)||!r.call(Object.prototype,n))&&(e[n]=!0)}return e}if(!e||"object"!=typeof e)return[e].concat(n);var s=e;return i(e)&&!i(n)&&(s=a(e,o)),i(e)&&i(n)?(n.forEach((function(n,i){if(r.call(e,i)){var a=e[i];a&&"object"==typeof a&&n&&"object"==typeof n?e[i]=t(a,n,o):e.push(n)}else e[i]=n})),e):Object.keys(n).reduce((function(e,i){var a=n[i];return r.call(e,i)?e[i]=t(e[i],a,o):e[i]=a,e}),s)}}},function(t,e,n){"use strict";var r=String.prototype.replace,i=/%20/g;t.exports={default:"RFC3986",formatters:{RFC1738:function(t){return r.call(t,i,"+")},RFC3986:function(t){return t}},RFC1738:"RFC1738",RFC3986:"RFC3986"}},function(t,e,n){var r=n(16),i=n(36),o=n(38),a=n(105).f;t.exports=function(t){return function(e){for(var n,s=o(e),u=i(s),c=u.length,l=0,h=[];c>l;)n=u[l++],r&&!a.call(s,n)||h.push(t?[n,s[n]]:s[n]);return h}}},function(t,e,n){var r=n(28),i=n(80),o=n(17),a=Function.prototype,s=Object.prototype,u=a.toString,c=s.hasOwnProperty,l=u.call(Object);t.exports=function(t){if(!o(t)||"[object Object]"!=r(t))return!1;var e=i(t);if(null===e)return!0;var n=c.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&u.call(n)==l}},function(t,e,n){(function(e){var n="object"==typeof e&&e&&e.Object===Object&&e;t.exports=n}).call(this,n(20))},function(t,e){t.exports=function(t,e){return function(n){return t(e(n))}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=l(n(18)),i=n(9),o=l(n(81)),a=n(8),s=l(n(138)),u=l(n(139)),c=l(n(259));function l(t){return t&&t.__esModule?t:{default:t}}e.default={name:"MapAndBasicHeader",inject:["slotsList","propsList"],props:{theme:{type:String,default:"light"},fixed:{type:Boolean,default:!1},navList:{type:Array,default:function(){return[]}}},data:function(){return{currentPath:void 0,currentIndex:0}},mounted:function(){var t=this;this.$watch("$route",(function(e){var n=e.matched;if(t.navList&&!(0,a.isEmpty)(t.navList)){var r=(0,i.treeFindPath)(t.navList,(function(t){return t.meta.id===n[n.length-1].meta.id}));t.currentPath=r[0].path;var o=t.navList.findIndex((function(e){return e.path===t.currentPath}));t.currentIndex=-1!==o?o:0,t.propsList.nav&&c.default._toggle(t.currentIndex)}}),{immediate:!0}),this.propsList.nav&&this.$nextTick((function(){c.default.drawNav({index:t.currentIndex,canvas:document.getElementById("navCanvas"),navItem:document.querySelector(".rk-web-core-header-right-nav-item"),navCount:t.navList.length})}))},methods:{renderNav:function(){var t=this,e=this.$createElement;return this.navList&&!(0,a.isEmpty)(this.navList)?this.navList.filter((function(t){return 1===t.type})).map((function(n,o){var a="dark"!==t.theme?(0,r.default)([i.prefixCls+"-header-right-nav-item",n.path===t.currentPath?i.prefixCls+"-header-right-nav-active":""]):(0,r.default)([i.prefixCls+"-header-right-nav-item",i.prefixCls+"-header-dark-nav-item",n.path===t.currentPath?i.prefixCls+"-header-dark-nav-active":""]);return e("div",{class:a,ref:"navItem",on:{click:function(){return t.handleTap(n,o)}}},[n.meta.title])})):null},handleTap:function(t,e){if(1===t.meta.chainType){var n=t.path.indexOf("http")>-1?t.path:"http://"+t.path;window.open(n)}else this.propsList.nav&&c.default._toggle(e),this.currentPath=t.path,this.$store.commit("user/SET_NAV_INDEX",e),this.$router.push(t.path).then((function(t){})),this.$emit("change",t)},setNavIndex:function(t){c.default._toggle(t)}},render:function(){var t=arguments[0],e=this.theme,n=this.fixed,a=this.slotsList,c=this.propsList,l=(0,r.default)([i.prefixCls+"-header",i.prefixCls+"-header-"+e,n?i.prefixCls+"-header-fixed":""]);return t("a-layout-header",{class:l},[t("div",{class:[i.prefixCls+"-header-"+e+"-inner",i.prefixCls+"-header-inner"]},[a.logo?a.logo:t(o.default,{attrs:{prefix:"basic",theme:e}}),a.prefix,t("div",{class:i.prefixCls+"-header-right"},[c.nav?t("div",{class:[i.prefixCls+"-header-right-nav","dark"===e?i.prefixCls+"-header-dark":""]},[t("canvas",{attrs:{id:"navCanvas"},style:"position: absolute; z-index: -1"}),this.renderNav()]):null,c.right?t("div",{class:i.prefixCls+"-header-right-extra"},[a.header,t(s.default,{attrs:{theme:e}}),a.extends,t(u.default,{attrs:{theme:e}})]):null]),a.suffix])])}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=d(n(72)),o=d(n(73)),a=d(n(21)),s=n(9),u=n(13),c=d(n(116)),l=n(27),h=n(8),f=d(n(18));function d(t){return t&&t.__esModule?t:{default:t}}e.default={name:"AppExternal",props:{theme:{type:String,default:"light"}},computed:{currentUser:function(){return u.localStore.get("userName")},currentProject:function(){return u.localStore.get("currentProject")}},data:function(){return{projectList:[],currentProjectInfo:void 0}},mounted:function(){this.getAllProject()},methods:{getAllProject:function(){var t=this;(0,l.getBelongList)().then((function(e){u.sessionStore.get("CLIENT_ID");t.projectList=e.data.map((function(e){return(0,a.default)({},e,{check:e.id===t.currentProject.id})}));var n=(0,h.find)(t.projectList,["id",t.currentProject.id]);(0,h.isEmpty)(n)||(t.currentProjectInfo=n.name)}))},changeBtn:(r=(0,o.default)(i.default.mark((function t(e,n){var r,o;return i.default.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(1!==e){t.next=14;break}return localStorage.removeItem("menuList"),localStorage.removeItem("consumer"),localStorage.removeItem("currentProject"),localStorage.removeItem("consumerExtList"),localStorage.removeItem("userMessage"),u.localStore.set("currentProject",n),t.next=9,(0,l.postConsumer)(n.id);case 9:r=t.sent,o=r.data,!(0,h.isEmpty)(o)&&o.access_token&&(localStorage.removeItem("access_token"),localStorage.setItem("access_token",o.access_token),this.$nextTick((function(){window.location.reload()}))),t.next=16;break;case 14:c.default.clearAll(),window.open(sessionStorage.getItem("IAM_BASE_URL")+"/iam/v1/oauth/logout?redirect_uri="+window.origin,"_self");case 16:case"end":return t.stop()}}),t,this)}))),function(t,e){return r.apply(this,arguments)})},render:function(){var t=this,e=arguments[0],n=this.projectList.map((function(n){var r=(0,f.default)([s.prefixCls+"-app-external-cell",n.check?s.prefixCls+"-app-external-active":""]);return e("div",{class:r,on:{click:function(){return t.changeBtn(1,n)}}},[n.name])}));return e("a-dropdown",{attrs:{trigger:["click"]}},[e("span",{class:[s.prefixCls+"-app-external-link",s.prefixCls+"-app-external-link-"+this.theme]},[e("span",{class:s.prefixCls+"-app-external-link-title"},[this.currentUser]),this.currentProject?e("span",{class:s.prefixCls+"-app-external-link-sub"},["【",this.currentProjectInfo,"】"]):null,e("a-icon",{attrs:{type:"caret-down"}})]),e("div",{slot:"overlay",class:s.prefixCls+"-app-external-wrapper"},[(0,h.isEmpty)(this.projectList)?null:e("div",{class:s.prefixCls+"-app-external-list"},[n]),e("div",{class:s.prefixCls+"-app-external-btn",on:{click:function(){return t.changeBtn(2)}}},[e("span",["退出登录"])])])])}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=c(n(100)),i=c(n(255)),o=n(9),a=n(27),s=c(n(258)),u=n(13);function c(t){return t&&t.__esModule?t:{default:t}}var l={"东北⻛":[22.5,67.5],"东⻛":[67.5,112.5],"东南⻛":[112.5,157.5],"南⻛":[157.5,202.5],"⻄南⻛":[202.5,247.5],"⻄⻛":[247.5,292.5],"⻄北⻛":[292.5,337.5]},h={"0级":[0,.2],"1级":[.2,1.5],"2级":[1.5,3.3],"3级":[3.3,5.4],"4级":[5.4,7.9],"5级":[7.9,10.7],"6级":[10.7,13.8],"7级":[13.8,17.1],"8级":[17.1,20.7],"9级":[20.7,24.4],"10级":[24.4,28.4],"11级":[28.4,32.6]};e.default={name:"HeaderInfoGroup",inject:["propsList"],props:{theme:{type:String,default:"light"}},data:function(){return{ymd:"00-00-00",hms:"--:--:--",regionDataInfo:{temperature:0,time:void 0,url:void 0,value:0,windDirection:0,windSpeed:0,iconDay:void 0,iconNight:void 0,weather:"晴",windDegrees:180,windLevel:2},isDay:!0}},mounted:function(){var t=this;this.timer=setInterval((function(){t.initDateTime()}),1e3),this.getRealDate()},methods:{calcWindDirection:function(t){return{transform:"rotateZ("+t+"deg)"}},calcWind:function(t){var e=(0,i.default)(l).findIndex((function(e){return t>e[0]&&t<=e[1]}));return""+((0,r.default)(l)[e]||"北风")},calcWindLevel:function(t){if(0===t)return"0级";var e=(0,i.default)(h).findIndex((function(e){return t>e[0]&&t<=e[1]}));return""+((0,r.default)(h)[e]||"12级")},initDateTime:function(){var t=new Date,e=t.getFullYear(),n=t.getMonth()+1,r=t.getDate(),i=(new Date).getHours(),o=(new Date).getMinutes(),a=(new Date).getSeconds();this.ymd=e+"-"+this.addZero(n)+"-"+this.addZero(r),this.isDay=i>6&&i<=18,this.hms=this.addZero(i)+":"+this.addZero(o)+":"+this.addZero(a)},addZero:function(t){return t<10?"0"+t:t},getRealDate:function(){var t=this,e=u.localStore.get("consumer").regionId;(0,a.getRegionDataInfo)({areaCode:e}).then((function(e){t.regionDataInfo=e.data.live}))}},beforeDestroy:function(){this.timer&&clearInterval(this.timer)},render:function(){var t=arguments[0];return t("div",{class:[o.prefixCls+"-header-info-group",o.prefixCls+"-header-info-group-"+this.theme]},[this.propsList.datetime?t("div",{class:[o.prefixCls+"-header-info-group-time",o.prefixCls+"-header-info-group-item"]},[t("span",[this.hms]),t("small",[this.ymd])]):null,this.propsList.weather?t("div",{class:[o.prefixCls+"-header-info-group-weather",o.prefixCls+"-header-info-group-item"]},[t("img",{attrs:{src:this.regionDataInfo.icon,alt:""}}),t("span",[this.regionDataInfo.temperature,"℃"])]):null,this.propsList.wind?t("div",{class:[o.prefixCls+"-header-info-group-wind",o.prefixCls+"-header-info-group-item"]},[t("div",{class:o.prefixCls+"-header-info-group-wind-img"},[t(s.default,{style:this.calcWindDirection(this.regionDataInfo.windDegrees)})]),t("div",{class:o.prefixCls+"-header-info-group-wind-info"},[t("span",[this.regionDataInfo.windLevel,"级"]),t("span",[this.regionDataInfo.windDirection])])]):null])}}},function(t,e,n){(function(t){var r=void 0!==t&&t||"undefined"!=typeof self&&self||window,i=Function.prototype.apply;function o(t,e){this._id=t,this._clearFn=e}e.setTimeout=function(){return new o(i.call(setTimeout,r,arguments),clearTimeout)},e.setInterval=function(){return new o(i.call(setInterval,r,arguments),clearInterval)},e.clearTimeout=e.clearInterval=function(t){t&&t.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(r,this._id)},e.enroll=function(t,e){clearTimeout(t._idleTimeoutId),t._idleTimeout=e},e.unenroll=function(t){clearTimeout(t._idleTimeoutId),t._idleTimeout=-1},e._unrefActive=e.active=function(t){clearTimeout(t._idleTimeoutId);var e=t._idleTimeout;e>=0&&(t._idleTimeoutId=setTimeout((function(){t._onTimeout&&t._onTimeout()}),e))},n(265),e.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==t&&t.setImmediate||this&&this.setImmediate,e.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==t&&t.clearImmediate||this&&this.clearImmediate}).call(this,n(20))},function(t,e,n){var r=n(288),i=n(304),o=n(306),a=n(307),s=n(308);function u(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=i,u.prototype.get=o,u.prototype.has=a,u.prototype.set=s,t.exports=u},function(t,e){var n=Function.prototype.toString;t.exports=function(t){if(null!=t){try{return n.call(t)}catch(t){}try{return t+""}catch(t){}}return""}},function(t,e,n){var r=n(22),i=function(){try{var t=r(Object,"defineProperty");return t({},"",{}),t}catch(t){}}();t.exports=i},function(t,e,n){var r=n(59),i=n(318);t.exports=function t(e,n,o,a,s){var u=-1,c=e.length;for(o||(o=i),s||(s=[]);++u<c;){var l=e[u];n>0&&o(l)?n>1?t(l,n-1,o,a,s):r(s,l):a||(s[s.length]=l)}return s}},function(t,e,n){var r=n(319),i=Math.max;t.exports=function(t,e,n){return e=i(void 0===e?t.length-1:e,0),function(){for(var o=arguments,a=-1,s=i(o.length-e,0),u=Array(s);++a<s;)u[a]=o[e+a];a=-1;for(var c=Array(e+1);++a<e;)c[a]=o[a];return c[e]=n(u),r(t,this,c)}}},function(t,e,n){var r=n(320),i=n(322)(r);t.exports=i},function(t,e,n){var r=n(53),i=n(352),o=n(353),a=n(354),s=n(355),u=n(356);function c(t){var e=this.__data__=new r(t);this.size=e.size}c.prototype.clear=i,c.prototype.delete=o,c.prototype.get=a,c.prototype.has=s,c.prototype.set=u,t.exports=c},function(t,e,n){var r=n(89),i=n(55);t.exports=function(t,e,n){(void 0!==n&&!i(t[e],n)||void 0===n&&!(e in t))&&r(t,e,n)}},function(t,e,n){var r=n(357)();t.exports=r},function(t,e,n){(function(t){var r=n(11),i=e&&!e.nodeType&&e,o=i&&"object"==typeof t&&t&&!t.nodeType&&t,a=o&&o.exports===i?r.Buffer:void 0,s=a?a.allocUnsafe:void 0;t.exports=function(t,e){if(e)return t.slice();var n=t.length,r=s?s(n):new t.constructor(n);return t.copy(r),r}}).call(this,n(44)(t))},function(t,e,n){var r=n(93);t.exports=function(t,e){var n=e?r(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}},function(t,e,n){var r=n(360),i=n(80),o=n(94);t.exports=function(t){return"function"!=typeof t.constructor||o(t)?{}:r(i(t))}},function(t,e,n){var r=n(363),i=n(96),o=n(97),a=o&&o.isTypedArray,s=a?i(a):r;t.exports=s},function(t,e){t.exports=function(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}},function(t,e,n){var r=n(365),i=n(58),o=n(10),a=n(95),s=n(57),u=n(153),c=Object.prototype.hasOwnProperty;t.exports=function(t,e){var n=o(t),l=!n&&i(t),h=!n&&!l&&a(t),f=!n&&!l&&!h&&u(t),d=n||l||h||f,p=d?r(t.length,String):[],m=p.length;for(var g in t)!e&&!c.call(t,g)||d&&("length"==g||h&&("offset"==g||"parent"==g)||f&&("buffer"==g||"byteLength"==g||"byteOffset"==g)||s(g,m))||p.push(g);return p}},function(t,e){t.exports=function(t,e){for(var n=-1,r=null==t?0:t.length;++n<r&&!1!==e(t[n],n,t););return t}},function(t,e){t.exports=function(){return[]}},function(t,e,n){var r=n(59),i=n(80),o=n(98),a=n(157),s=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)r(e,o(t)),t=i(t);return e}:a;t.exports=s},function(t,e,n){var r=n(59),i=n(10);t.exports=function(t,e,n){var o=e(t);return i(t)?o:r(o,n(t))}},function(t,e,n){"use strict";n.r(e),n.d(e,"loadMicroApp",(function(){return Wn})),n.d(e,"registerMicroApps",(function(){return Hn})),n.d(e,"start",(function(){return Vn})),n.d(e,"initGlobalState",(function(){return Ft})),n.d(e,"__internalGetCurrentRunningApp",(function(){return Ge})),n.d(e,"addErrorHandler",(function(){return g.b})),n.d(e,"removeErrorHandler",(function(){return g.i})),n.d(e,"addGlobalUncaughtErrorHandler",(function(){return Zn})),n.d(e,"removeGlobalUncaughtErrorHandler",(function(){return qn})),n.d(e,"setDefaultMountApp",(function(){return Yn})),n.d(e,"runDefaultMountEffects",(function(){return Jn})),n.d(e,"runAfterFirstMounted",(function(){return Xn})),n.d(e,"SandBoxType",(function(){return Rt})),n.d(e,"prefetchApps",(function(){return In}));var r={};n.r(r),n.d(r,"ScopedCSS",(function(){return Zt})),n.d(r,"QiankunCSSRewriteAttr",(function(){return qt})),n.d(r,"process",(function(){return Yt}));var i=n(0),o=n.n(i),a=n(14),s=n.n(a);function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function c(t){return function(t){if(Array.isArray(t))return u(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return u(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?u(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function l(t){return(l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}
52
52
  /*! *****************************************************************************
53
53
  Copyright (c) Microsoft Corporation.
54
54