3 lines
1.1 MiB
3 lines
1.1 MiB
(function(config){!function(global,factory){"object"==typeof exports&&"undefined"!=typeof module?module.exports=factory():"function"==typeof define&&define.amd?define(factory):(global=global||self).AMap=factory()}(this,function(){"use strict";var shared,worker,AMap;function define(_,chunk){var sharedChunk,workerBundleString;shared?worker?(workerBundleString='var sharedChunk = {key:"'+config[0]+'",db:"'+(config[14]||"")+'",nebulaVersion:"'+(config[15]||"")+'",movingDraw:'+Boolean(window.movingDraw)+',host:"'+config[2]+'",}; ('+shared+")(sharedChunk); ("+worker+")(sharedChunk);",sharedChunk={key:config[0],movingDraw:window.movingDraw},shared(sharedChunk),sharedChunk=chunk(sharedChunk),workerBundleString="undefined"!=typeof URL?window.URL.createObjectURL(new Blob([workerBundleString],{type:"text/javascript"})):"",(AMap=sharedChunk(config)).getConfig().workerUrl=workerBundleString):worker=chunk:shared=chunk}define(["exports"],function(exports){var extend=function(t){for(var r,n,i=Array.prototype.slice.call(arguments,1),a=0,o=i.length;a<o;a+=1)for(var s in r=i[a]||{})r.hasOwnProperty(s)&&("function"==typeof(n=r[s])&&t.prototype?t.prototype[s]=n:t[s]=n);return t};function isBrowser(){return"undefined"!=typeof window&&"undefined"!=typeof document}function isWasmSuppport(){try{if("object"==typeof WebAssembly&&"function"==typeof WebAssembly.instantiate&&TextDecoder&&TextEncoder){var t=new WebAssembly.Module(new Uint8Array([0,97,115,109,1,0,0,0]));if(t instanceof WebAssembly.Module)return new WebAssembly.Instance(t)instanceof WebAssembly.Instance}}catch(t){}return!1}var testWepP=function(t){var e=new Image;e.src="data:image/webp;base64,UklGRi4AAABXRUJQVlA4TCEAAAAvAUAAEB8wAiMwAgSSNtse/cXjxyCCmrYNWPwmHRH9jwMA",e.onload=e.onerror=function(){t(2===e.height)}};function isWorkerEnv(){try{return document,!1}catch(t){return!0}}function getSupport(t){function e(t){return-1!==n.indexOf(t)}var r={runSupport:(new Date).getTime()},U=isWasmSuppport(),n=navigator.userAgent.toLowerCase(),j=!0,i=e("macintosh"),F=e("ipad;")||e("ipad "),a=e("ipod touch;"),o=e("iphone;")||e("iphone "),a=o||F||a,s=(i||a)&&e("safari")&&e("version/"),u=e("macwechat"),c=e("windowswechat"),R={touch:!1,mac:i,Ue:!1,webkit:!1,$e:!1,scale:1,android:!1,DW:isWorkerEnv(),wasm:U,safari:s,AQ:u,gQ:c,amapRunTime:r};if(isBrowser()){var f=window,c=(u=document).documentElement,h=/([a-z0-9]*\d+[a-z0-9]*)/,D="google swiftshader;microsoft basic render driver;vmware svga 3d;Intel 965GM;Intel B43;Intel G41;Intel G45;Intel G965;Intel GMA 3600;Intel Mobile 4;Intel Mobile 45;Intel Mobile 965".split(";"),l="ActiveXObject"in f,d=0!=window.detectRetina&&("devicePixelRatio"in f&&1<f.devicePixelRatio||l&&"matchMedia"in f&&f.matchMedia("(min-resolution:144dpi)")&&f.matchMedia("(min-resolution:144dpi)").matches),B=e("windows nt"),v=(n.search(/windows nt [1-5]\./),n.search(/windows nt 5\.[12]/),e("windows nt 10"),e("windows phone")),G=e("Mb2345Browser"),V=(a&&n.search(/ os [456]_/),a&&n.search(/ os [4-8]_/),a&&n.search(/ os [78]_/),a&&e("os 8_"),a&&e("os 10_")),g=e("android"),p=0,z=(g&&(p=parseInt(n.split("android")[1])||0),g&&p<4),y=(g&&5<=p||n.search(/android 4.4/),g?"android":a?"ios":B?"windows":i?"mac":"other"),p=l&&!f.XMLHttpRequest,W=l&&!u.querySelector,m=l&&!u.addEventListener,H=l&&e("msie 9"),q=l&&e("msie 10"),K=l&&e("rv:11"),Y=m||H,b=e("edge"),T=(e("qtweb"),e("ucbrowser")),X=e("alipay")||g&&T,Z=(e("miuibrowser"),e("micromessenger")),A=e("dingtalk"),J=e("mqqbrowser"),Q=e("baidubrowser"),x=e("crios/"),M=e("chrome/"),x=!((M||x)&&e("chromium"))&&(M&&30<parseInt(n.split("chrome/")[1])||x&&30<parseInt(n.split("crios/")[1])),tt=e("firefox"),S=tt&&27<parseInt(n.split("firefox/")[1]),w=s&&7<parseInt(n.split("version/")[1]),P=(a&&e("aliapp"),g||a||v||e("mobile")),v="ontouchstart"in u,et=f.navigator&&f.navigator.msPointerEnabled&&!!f.navigator.msMaxTouchPoints,rt=f.navigator&&!!f.navigator.maxTouchPoints,nt=!v&&(rt||et),v=v||nt,I=function(){if(!P)return f.devicePixelRatio||1;var t=document.getElementsByTagName("meta");if(window.parent&&window.parent!==window)try{if(window.parent.location.origin!==window.location.origin)return 1;t=window.parent.document.getElementsByTagName("meta")}catch(t){return 1}for(var r,n,e,a=t.length-1;0<=a;--a)if("viewport"===t[a].name)return r=void 0,-1!==(e=t[a].content).indexOf("initial-scale")&&(r=parseFloat(e.split("initial-scale=")[1])),n=-1!==e.indexOf("minimum-scale")?parseFloat(e.split("minimum-scale=")[1]):0,e=-1!==e.indexOf("maximum-scale")?parseFloat(e.split("maximum-scale=")[1]):1/0,r?n<=e?e<r?e:r<n?n:r:(console&&console.log&&console.log("viewport参数不合法"),null):n<=e?1<=n?1:Math.min(e,1):(console&&console.log&&console.log("viewport参数不合法"),null)}(),it=d&&(!P||!!I&&1<=I),at=l&&"transition"in c.style,ot=!!u.createElementNS&&!!u.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect,C=u.createElement("canvas"),st=!(!C||!C.getContext),u=window.URL||window.webkitURL,ut=!0!==window.disableWorker&&!l&&!(T&&g&&!x)&&window.Worker&&u&&u.createObjectURL&&window.Blob,N="",$="",k=0,u=0!=window.higtQualityRender||!d,ct=window.movingDraw,L={alpha:!0,antialias:u,depth:!0,stencil:!0},O=(u=function(){if(st&&ut)for(var t,r=["webgl","experimental-webgl","moz-webgl"],n=null,i=0;i<r.length;i+=1){try{n=C.getContext(r[i],L)}catch(t){}if(n){if(n.drawingBufferWidth!==C.width||n.drawingBufferHeight!==C.height)return!1;if(!n.getShaderPrecisionFormat||!n.getParameter||!n.getExtension)return!1;if(k=n.getParameter(n.MAX_RENDERBUFFER_SIZE),!(a=n.getParameter(n.MAX_VIEWPORT_DIMS)))return!1;k=Math.min(k,a[0],a[1]),s&&"mac"==y&&(k=Math.min(k,4096));var a=Math.max(screen.width,screen.height);if(it&&(a*=Math.min(2,window.devicePixelRatio||1)),k<a)return!1;if(n.getShaderPrecisionFormat(35632,36338).precision<23||n.getShaderPrecisionFormat(35633,36338).precision<23)return!1;var e=o=a=void 0,o=(t=$=n.getExtension("WEBGL_debug_renderer_info")?n.getParameter(37446):null)?(a=null,0<=(t=(t=(o=(t=t.toLowerCase()).match(/angle \((.*)\)/))?(t=o[1]).replace(/\s*direct3d.*$/,""):t).replace(/\s*\([^\)]*wddm[^\)]*\)/,"")).indexOf("intel")?(a=["Intel"],0<=t.indexOf("mobile")&&a.push("Mobile"),(0<=t.indexOf("gma")||0<=t.indexOf("graphics media accelerator"))&&a.push("GMA"),0<=t.indexOf("haswell")?a.push("Haswell"):0<=t.indexOf("ivy")?a.push("HD 4000"):0<=t.indexOf("sandy")?a.push("HD 3000"):0<=t.indexOf("ironlake")?a.push("HD"):(0<=t.indexOf("hd")&&a.push("HD"),(e=t.match(h))&&a.push(e[1].toUpperCase())),a.join(" ")):0<=t.indexOf("nvidia")||0<=t.indexOf("quadro")||0<=t.indexOf("geforce")||0<=t.indexOf("nvs")?(a=["nVidia"],0<=t.indexOf("geforce")&&a.push("geForce"),0<=t.indexOf("quadro")&&a.push("Quadro"),0<=t.indexOf("nvs")&&a.push("NVS"),t.match(/\bion\b/)&&a.push("ION"),t.match(/gtx\b/)?a.push("GTX"):t.match(/gts\b/)?a.push("GTS"):t.match(/gt\b/)?a.push("GT"):t.match(/gs\b/)?a.push("GS"):t.match(/ge\b/)?a.push("GE"):t.match(/fx\b/)&&a.push("FX"),(e=t.match(h))&&a.push(e[1].toUpperCase().replace("GS","")),0<=t.indexOf("titan")?a.push("TITAN"):0<=t.indexOf("ti")&&a.push("Ti"),a.join(" ")):0<=t.indexOf("amd")||0<=t.indexOf("ati")||0<=t.indexOf("radeon")||0<=t.indexOf("firegl")||0<=t.indexOf("firepro")?(a=["AMD"],0<=t.indexOf("mobil")&&a.push("Mobility"),0<=(o=t.indexOf("radeon"))&&a.push("Radeon"),0<=t.indexOf("firepro")?a.push("FirePro"):0<=t.indexOf("firegl")&&a.push("FireGL"),0<=t.indexOf("hd")&&a.push("HD"),(e=(t=0<=o?t.substring(o):t).match(h))&&a.push(e[1].toUpperCase().replace("HD","")),a.join(" ")):t.substring(0,100)):null;if(o){if(-1<o.indexOf("google swiftshader"))return j=!1;if(-1!==D.indexOf(o))return!1}return N=r[i],!0}}return!1})(),ft=void 0===t[8]||t[8],O=window.Uint8Array&&ft&&!window.forbidenWebGL&&O&&(window.forceWebGL||(x||S||w||b||Z||A)&&"other"!=y),x=window.forceWebGLBaseRender||O?"w":"d",S=e("webkit"),w="WebKitCSSMatrix"in f&&"m11"in new window.WebKitCSSMatrix,A="MozPerspective"in c.style,c="vV"in c.style,ht=at||w||A||c,t=void 0!==t[12]?t[12]:null,_=!0;try{void 0===f.localStorage?_=!1:(E=(new Date).getTime()+"",f.localStorage.setItem("_test",E),f.localStorage.getItem("_test")!==E&&(_=!1),f.localStorage.removeItem("_test"))}catch(t){_=!1}var E=parseInt(n.split("chrome/")[1]),R={iPad:F,iPhone:o,size:o?100:g?200:500,mac:i,windows:B,ios:a,uT:V,android:g,android23:z,cT:X,plat:y,baidu:Q,qq:J,safari:s,wechat:Z,ie:l,ie6:p,ie7:W,ie9:H,ie10:q,ielt9:m,fT:Y,ie11:K,edge:b,hT:l&&!K,lT:G,RL:_,vT:t,geolocation:P||l&&!m||b,SL:T,uc:T&&!M,chrome:M,gT:!0,firefox:tt,hardwareAccEnabled:j,$e:P,mobileWebkit:P&&S,mobileWebkit3d:P&&w,mobileOpera:P&&f.opera,Ue:d,bT:I,Mr:it,touch:v,msPointer:et,pointer:rt,yT:nt,pT:M&&57<=E,mT:!P&&M&&64<=E,webkit:S,ie3d:at,webkit3d:w,gecko3d:A,opera3d:c,any3d:ht,isSvg:ot,isCanvas:st,isWorker:ut,TT:!1,isWebGL:O,AT:N,xT:L,ST:$,wT:k,MT:!1,movingDraw:ct,baseRender:ft?x:"d",scale:d?2:1,getContext:function(t,e){var r={};return extend(r,L),extend(r,e),t.getContext(N,r)},mH:!1,wasm:U,amapRunTime:r,sY:u};testWepP(function(t){R.mH=t})}return R}var Browser=getSupport("undefined"==typeof config?[]:config),canceledWorkerFetch=("undefined"!=typeof createImageBitmap&&"undefined"!=typeof ImageBitmap&&(Browser.imageBitmap=!0),Boolean(Browser.DW?!Browser.safari&&!Browser.AQ&&!Browser.gQ&&self.fetch&&self.Request&&self.AbortController&&self.Request.prototype.hasOwnProperty("signal"):!Browser.safari&&!Browser.AQ&&!Browser.gQ&&window.fetch&&window.Request&&window.AbortController&&window.Request.prototype.hasOwnProperty("signal"))),freeGlobal=(Browser.LZ=canceledWorkerFetch,Browser.amapRunTime={workerTime:{}},"object"==typeof global&&global&&global.Object===Object&&global),freeSelf="object"==typeof self&&self&&self.Object===Object&&self,root=freeGlobal||freeSelf||Function("return this")(),Symbol$1=root.Symbol,objectProto=Object.prototype,hasOwnProperty=objectProto.hasOwnProperty,nativeObjectToString=objectProto.toString,symToStringTag=Symbol$1?Symbol$1.toStringTag:void 0;function getRawTag(t){var e=hasOwnProperty.call(t,symToStringTag),r=t[symToStringTag];try{var n=!(t[symToStringTag]=void 0)}catch(t){}var i=nativeObjectToString.call(t);return n&&(e?t[symToStringTag]=r:delete t[symToStringTag]),i}var objectProto$1=Object.prototype,nativeObjectToString$1=objectProto$1.toString;function objectToString(t){return nativeObjectToString$1.call(t)}var nullTag="[object Null]",undefinedTag="[object Undefined]",symToStringTag$1=Symbol$1?Symbol$1.toStringTag:void 0;function baseGetTag(t){return null==t?void 0===t?undefinedTag:nullTag:(symToStringTag$1&&symToStringTag$1 in Object(t)?getRawTag:objectToString)(t)}function isObjectLike(t){return null!=t&&"object"==typeof t}var symbolTag="[object Symbol]";function isSymbol(t){return"symbol"==typeof t||isObjectLike(t)&&baseGetTag(t)==symbolTag}function arrayMap(t,e){for(var r=-1,n=null==t?0:t.length,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}var isArray=Array.isArray,INFINITY=1/0,symbolProto=Symbol$1?Symbol$1.prototype:void 0,symbolToString=symbolProto?symbolProto.toString:void 0;function baseToString(t){var e;return"string"==typeof t?t:isArray(t)?arrayMap(t,baseToString)+"":isSymbol(t)?symbolToString?symbolToString.call(t):"":"0"==(e=t+"")&&1/t==-INFINITY?"-0":e}var reWhitespace=/\s/;function trimmedEndIndex(t){for(var e=t.length;e--&&reWhitespace.test(t.charAt(e)););return e}var reTrimStart=/^\s+/;function baseTrim(t){return t&&t.slice(0,trimmedEndIndex(t)+1).replace(reTrimStart,"")}function isObject(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}var NAN=NaN,reIsBadHex=/^[-+]0x[0-9a-f]+$/i,reIsBinary=/^0b[01]+$/i,reIsOctal=/^0o[0-7]+$/i,freeParseInt=parseInt;function toNumber(t){if("number"==typeof t)return t;if(isSymbol(t))return NAN;if("string"!=typeof(t=isObject(t)?isObject(e="function"==typeof t.valueOf?t.valueOf():t)?e+"":e:t))return 0===t?t:+t;t=baseTrim(t);var e=reIsBinary.test(t);return e||reIsOctal.test(t)?freeParseInt(t.slice(2),e?2:8):reIsBadHex.test(t)?NAN:+t}var INFINITY$1=1/0,MAX_INTEGER=17976931348623157e292;function toFinite(t){return t?(t=toNumber(t))===INFINITY$1||t===-INFINITY$1?(t<0?-1:1)*MAX_INTEGER:t==t?t:0:0===t?t:0}function toInteger(t){var e=(t=toFinite(t))%1;return t==t?e?t-e:t:0}function identity(t){return t}var asyncTag="[object AsyncFunction]",funcTag="[object Function]",genTag="[object GeneratorFunction]",proxyTag="[object Proxy]";function isFunction(t){return!!isObject(t)&&((t=baseGetTag(t))==funcTag||t==genTag||t==asyncTag||t==proxyTag)}var coreJsData=root["__core-js_shared__"],maskSrcKey=function(){var t=/[^.]+$/.exec(coreJsData&&coreJsData.keys&&coreJsData.keys.Xb||"");return t?"Symbol(src)_1."+t:""}();function isMasked(t){return maskSrcKey&&maskSrcKey in t}var funcProto=Function.prototype,funcToString=funcProto.toString;function toSource(t){if(null!=t){try{return funcToString.call(t)}catch(t){}try{return t+""}catch(t){}}return""}var reRegExpChar=/[\\^$.*+?()[\]{}|]/g,reIsHostCtor=/^\[object .+?Constructor\]$/,funcProto$1=Function.prototype,objectProto$2=Object.prototype,funcToString$1=funcProto$1.toString,hasOwnProperty$1=objectProto$2.hasOwnProperty,reIsNative=RegExp("^"+funcToString$1.call(hasOwnProperty$1).replace(reRegExpChar,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function baseIsNative(t){return isObject(t)&&!isMasked(t)&&(isFunction(t)?reIsNative:reIsHostCtor).test(toSource(t))}function getValue(t,e){return null==t?void 0:t[e]}function getNative(t,e){return baseIsNative(t=getValue(t,e))?t:void 0}var WeakMap=getNative(root,"WeakMap"),objectCreate=Object.create,baseCreate=function(){function e(){}return function(t){return isObject(t)?objectCreate?objectCreate(t):(e.prototype=t,t=new e,e.prototype=void 0,t):{}}}();function apply(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}function copyArray(t,e){var r=-1,n=t.length;for(e=e||Array(n);++r<n;)e[r]=t[r];return e}var HOT_COUNT=800,HOT_SPAN=16,nativeNow=Date.now;function shortOut(r){var n=0,i=0;return function(){var t=nativeNow(),e=HOT_SPAN-(t-i);if(i=t,0<e){if(++n>=HOT_COUNT)return arguments[0]}else n=0;return r.apply(void 0,arguments)}}function constant(t){return function(){return t}}var defineProperty=function(){try{var t=getNative(Object,"defineProperty");return t({},"",{}),t}catch(t){}}(),baseSetToString=defineProperty?function(t,e){return defineProperty(t,"toString",{configurable:!0,enumerable:!1,value:constant(e),writable:!0})}:identity,setToString=shortOut(baseSetToString);function arrayEach(t,e){for(var r=-1,n=null==t?0:t.length;++r<n&&!1!==e(t[r],r,t););return t}function baseFindIndex(t,e,r,n){for(var i=t.length,a=r+(n?1:-1);n?a--:++a<i;)if(e(t[a],a,t))return a;return-1}var MAX_SAFE_INTEGER=9007199254740991,reIsUint=/^(?:0|[1-9]\d*)$/;function isIndex(t,e){var r=typeof t;return!!(e=null==e?MAX_SAFE_INTEGER:e)&&("number"==r||"symbol"!=r&&reIsUint.test(t))&&-1<t&&t%1==0&&t<e}function baseAssignValue(t,e,r){"__proto__"==e&&defineProperty?defineProperty(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}function eq(t,e){return t===e||t!=t&&e!=e}var objectProto$3=Object.prototype,hasOwnProperty$2=objectProto$3.hasOwnProperty;function assignValue(t,e,r){var n=t[e];hasOwnProperty$2.call(t,e)&&eq(n,r)&&(void 0!==r||e in t)||baseAssignValue(t,e,r)}function copyObject(t,e,r,n){for(var i=!r,a=(r=r||{},-1),o=e.length;++a<o;){var s=e[a],u=n?n(r[s],t[s],s,r,t):void 0;(i?baseAssignValue:assignValue)(r,s,void 0===u?t[s]:u)}return r}var nativeMax=Math.max;function overRest(a,o,s){return o=nativeMax(void 0===o?a.length-1:o,0),function(){for(var t=arguments,e=-1,r=nativeMax(t.length-o,0),n=Array(r);++e<r;)n[e]=t[o+e];for(var e=-1,i=Array(o+1);++e<o;)i[e]=t[e];return i[o]=s(n),apply(a,this,i)}}function baseRest(t,e){return setToString(overRest(t,e,identity),t+"")}var MAX_SAFE_INTEGER$1=9007199254740991;function isLength(t){return"number"==typeof t&&-1<t&&t%1==0&&t<=MAX_SAFE_INTEGER$1}function isArrayLike(t){return null!=t&&isLength(t.length)&&!isFunction(t)}function isIterateeCall(t,e,r){var n;return isObject(r)&&("number"==(n=typeof e)?isArrayLike(r)&&isIndex(e,r.length):"string"==n&&e in r)&&eq(r[e],t)}function createAssigner(s){return baseRest(function(t,e){var r=-1,n=e.length,i=1<n?e[n-1]:void 0,a=2<n?e[2]:void 0,i=3<s.length&&"function"==typeof i?(n--,i):void 0;for(a&&isIterateeCall(e[0],e[1],a)&&(i=n<3?void 0:i,n=1),t=Object(t);++r<n;){var o=e[r];o&&s(t,o,r,i)}return t})}var objectProto$4=Object.prototype;function isPrototype(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||objectProto$4)}function baseTimes(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}var argsTag="[object Arguments]";function baseIsArguments(t){return isObjectLike(t)&&baseGetTag(t)==argsTag}var objectProto$5=Object.prototype,hasOwnProperty$3=objectProto$5.hasOwnProperty,propertyIsEnumerable=objectProto$5.propertyIsEnumerable,isArguments=baseIsArguments(function(){return arguments}())?baseIsArguments:function(t){return isObjectLike(t)&&hasOwnProperty$3.call(t,"callee")&&!propertyIsEnumerable.call(t,"callee")};function stubFalse(){return!1}var freeExports="object"==typeof exports&&exports&&!exports.nodeType&&exports,freeModule=freeExports&&"object"==typeof module&&module&&!module.nodeType&&module,moduleExports=freeModule&&freeModule.exports===freeExports,Buffer=moduleExports?root.Zb:void 0,nativeIsBuffer=Buffer?Buffer.isBuffer:void 0,isBuffer=nativeIsBuffer||stubFalse,argsTag$1="[object Arguments]",arrayTag="[object Array]",boolTag="[object Boolean]",dateTag="[object Date]",errorTag="[object Error]",funcTag$1="[object Function]",mapTag="[object Map]",numberTag="[object Number]",objectTag="[object Object]",regexpTag="[object RegExp]",setTag="[object Set]",stringTag="[object String]",weakMapTag="[object WeakMap]",arrayBufferTag="[object ArrayBuffer]",dataViewTag="[object DataView]",float32Tag="[object Float32Array]",float64Tag="[object Float64Array]",int8Tag="[object Int8Array]",int16Tag="[object Int16Array]",int32Tag="[object Int32Array]",uint8Tag="[object Uint8Array]",uint8ClampedTag="[object Uint8ClampedArray]",uint16Tag="[object Uint16Array]",uint32Tag="[object Uint32Array]",typedArrayTags={};function baseIsTypedArray(t){return isObjectLike(t)&&isLength(t.length)&&!!typedArrayTags[baseGetTag(t)]}function baseUnary(e){return function(t){return e(t)}}typedArrayTags[float32Tag]=typedArrayTags[float64Tag]=typedArrayTags[int8Tag]=typedArrayTags[int16Tag]=typedArrayTags[int32Tag]=typedArrayTags[uint8Tag]=typedArrayTags[uint8ClampedTag]=typedArrayTags[uint16Tag]=typedArrayTags[uint32Tag]=!0,typedArrayTags[argsTag$1]=typedArrayTags[arrayTag]=typedArrayTags[arrayBufferTag]=typedArrayTags[boolTag]=typedArrayTags[dataViewTag]=typedArrayTags[dateTag]=typedArrayTags[errorTag]=typedArrayTags[funcTag$1]=typedArrayTags[mapTag]=typedArrayTags[numberTag]=typedArrayTags[objectTag]=typedArrayTags[regexpTag]=typedArrayTags[setTag]=typedArrayTags[stringTag]=typedArrayTags[weakMapTag]=!1;var freeExports$1="object"==typeof exports&&exports&&!exports.nodeType&&exports,freeModule$1=freeExports$1&&"object"==typeof module&&module&&!module.nodeType&&module,moduleExports$1=freeModule$1&&freeModule$1.exports===freeExports$1,freeProcess=moduleExports$1&&freeGlobal.process,nodeUtil=function(){try{var t=freeModule$1&&freeModule$1.Qb&&freeModule$1.Qb("util").types;return t||freeProcess&&freeProcess.tg&&freeProcess.tg("util")}catch(t){}}(),nodeIsTypedArray=nodeUtil&&nodeUtil.rg,isTypedArray=nodeIsTypedArray?baseUnary(nodeIsTypedArray):baseIsTypedArray,objectProto$6=Object.prototype,hasOwnProperty$4=objectProto$6.hasOwnProperty;function arrayLikeKeys(t,e){var r,n=isArray(t),i=!n&&isArguments(t),a=!n&&!i&&isBuffer(t),o=!n&&!i&&!a&&isTypedArray(t),s=n||i||a||o,u=s?baseTimes(t.length,String):[],c=u.length;for(r in t)!e&&!hasOwnProperty$4.call(t,r)||s&&("length"==r||a&&("offset"==r||"parent"==r)||o&&("buffer"==r||"byteLength"==r||"byteOffset"==r)||isIndex(r,c))||u.push(r);return u}function overArg(e,r){return function(t){return e(r(t))}}var nativeKeys=overArg(Object.keys,Object),objectProto$7=Object.prototype,hasOwnProperty$5=objectProto$7.hasOwnProperty;function baseKeys(t){if(!isPrototype(t))return nativeKeys(t);var e,r=[];for(e in Object(t))hasOwnProperty$5.call(t,e)&&"constructor"!=e&&r.push(e);return r}function keys(t){return(isArrayLike(t)?arrayLikeKeys:baseKeys)(t)}var objectProto$8=Object.prototype,hasOwnProperty$6=objectProto$8.hasOwnProperty,assign=createAssigner(function(t,e){if(isPrototype(e)||isArrayLike(e))copyObject(e,keys(e),t);else for(var r in e)hasOwnProperty$6.call(e,r)&&assignValue(t,r,e[r])});function nativeKeysIn(t){var e=[];if(null!=t)for(var r in Object(t))e.push(r);return e}var objectProto$9=Object.prototype,hasOwnProperty$7=objectProto$9.hasOwnProperty;function baseKeysIn(t){if(!isObject(t))return nativeKeysIn(t);var e,r=isPrototype(t),n=[];for(e in t)("constructor"!=e||!r&&hasOwnProperty$7.call(t,e))&&n.push(e);return n}function keysIn(t){return isArrayLike(t)?arrayLikeKeys(t,!0):baseKeysIn(t)}var reIsDeepProp=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,reIsPlainProp=/^\w*$/;function isKey(t,e){var r;return!isArray(t)&&("number"==(r=typeof t)||"symbol"==r||"boolean"==r||null==t||isSymbol(t)||reIsPlainProp.test(t)||!reIsDeepProp.test(t)||null!=e&&t in Object(e))}var nativeCreate=getNative(Object,"create");function hashClear(){this.ng=nativeCreate?nativeCreate(null):{},this.size=0}function hashDelete(t){return t=this.has(t)&&delete this.ng[t],this.size-=t?1:0,t}var HASH_UNDEFINED="__lodash_hash_undefined__",objectProto$a=Object.prototype,hasOwnProperty$8=objectProto$a.hasOwnProperty;function hashGet(t){var e,r=this.ng;return nativeCreate?(e=r[t])===HASH_UNDEFINED?void 0:e:hasOwnProperty$8.call(r,t)?r[t]:void 0}var objectProto$b=Object.prototype,hasOwnProperty$9=objectProto$b.hasOwnProperty;function hashHas(t){var e=this.ng;return nativeCreate?void 0!==e[t]:hasOwnProperty$9.call(e,t)}var HASH_UNDEFINED$1="__lodash_hash_undefined__";function hashSet(t,e){var r=this.ng;return this.size+=this.has(t)?0:1,r[t]=nativeCreate&&void 0===e?HASH_UNDEFINED$1:e,this}function Hash(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function listCacheClear(){this.ng=[],this.size=0}function assocIndexOf(t,e){for(var r=t.length;r--;)if(eq(t[r][0],e))return r;return-1}Hash.prototype.clear=hashClear,Hash.prototype.delete=hashDelete,Hash.prototype.get=hashGet,Hash.prototype.has=hashHas,Hash.prototype.set=hashSet;var arrayProto=Array.prototype,splice=arrayProto.splice;function listCacheDelete(t){var e=this.ng;return!((t=assocIndexOf(e,t))<0||(t==e.length-1?e.pop():splice.call(e,t,1),--this.size,0))}function listCacheGet(t){var e=this.ng;return(t=assocIndexOf(e,t))<0?void 0:e[t][1]}function listCacheHas(t){return-1<assocIndexOf(this.ng,t)}function listCacheSet(t,e){var r=this.ng,n=assocIndexOf(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}function ListCache(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}ListCache.prototype.clear=listCacheClear,ListCache.prototype.delete=listCacheDelete,ListCache.prototype.get=listCacheGet,ListCache.prototype.has=listCacheHas,ListCache.prototype.set=listCacheSet;var Map=getNative(root,"Map");function mapCacheClear(){this.size=0,this.ng={hash:new Hash,map:new(Map||ListCache),string:new Hash}}function isKeyable(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t}function getMapData(t,e){return t=t.ng,isKeyable(e)?t["string"==typeof e?"string":"hash"]:t.map}function mapCacheDelete(t){return t=getMapData(this,t).delete(t),this.size-=t?1:0,t}function mapCacheGet(t){return getMapData(this,t).get(t)}function mapCacheHas(t){return getMapData(this,t).has(t)}function mapCacheSet(t,e){var r=getMapData(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}function MapCache(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}MapCache.prototype.clear=mapCacheClear,MapCache.prototype.delete=mapCacheDelete,MapCache.prototype.get=mapCacheGet,MapCache.prototype.has=mapCacheHas,MapCache.prototype.set=mapCacheSet;var FUNC_ERROR_TEXT="Expected a function";function memoize(n,i){if("function"!=typeof n||null!=i&&"function"!=typeof i)throw new TypeError(FUNC_ERROR_TEXT);function a(){var t=arguments,e=i?i.apply(this,t):t[0],r=a.cache;return r.has(e)?r.get(e):(t=n.apply(this,t),a.cache=r.set(e,t)||r,t)}return a.cache=new(memoize.Cache||MapCache),a}memoize.Cache=MapCache;var MAX_MEMOIZE_SIZE=500;function memoizeCapped(t){var e=(t=memoize(t,function(t){return e.size===MAX_MEMOIZE_SIZE&&e.clear(),t})).cache;return t}var rePropName=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,reEscapeChar=/\\(\\)?/g,stringToPath=memoizeCapped(function(t){var i=[];return 46===t.charCodeAt(0)&&i.push(""),t.replace(rePropName,function(t,e,r,n){i.push(r?n.replace(reEscapeChar,"$1"):e||t)}),i});function toString(t){return null==t?"":baseToString(t)}function castPath(t,e){return isArray(t)?t:isKey(t,e)?[t]:stringToPath(toString(t))}var INFINITY$2=1/0;function toKey(t){var e;return"string"==typeof t||isSymbol(t)?t:"0"==(e=t+"")&&1/t==-INFINITY$2?"-0":e}function baseGet(t,e){for(var r=0,n=(e=castPath(e,t)).length;null!=t&&r<n;)t=t[toKey(e[r++])];return r&&r==n?t:void 0}function get(t,e,r){return void 0===(t=null==t?void 0:baseGet(t,e))?r:t}function arrayPush(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}var getPrototype=overArg(Object.getPrototypeOf,Object);function stackClear(){this.ng=new ListCache,this.size=0}function stackDelete(t){var e=this.ng,t=e.delete(t);return this.size=e.size,t}function stackGet(t){return this.ng.get(t)}function stackHas(t){return this.ng.has(t)}var LARGE_ARRAY_SIZE=200;function stackSet(t,e){var r=this.ng;if(r instanceof ListCache){var n=r.ng;if(!Map||n.length<LARGE_ARRAY_SIZE-1)return n.push([t,e]),this.size=++r.size,this;r=this.ng=new MapCache(n)}return r.set(t,e),this.size=r.size,this}function Stack(t){t=this.ng=new ListCache(t),this.size=t.size}function baseAssign(t,e){return t&©Object(e,keys(e),t)}function baseAssignIn(t,e){return t&©Object(e,keysIn(e),t)}Stack.prototype.clear=stackClear,Stack.prototype.delete=stackDelete,Stack.prototype.get=stackGet,Stack.prototype.has=stackHas,Stack.prototype.set=stackSet;var freeExports$2="object"==typeof exports&&exports&&!exports.nodeType&&exports,freeModule$2=freeExports$2&&"object"==typeof module&&module&&!module.nodeType&&module,moduleExports$2=freeModule$2&&freeModule$2.exports===freeExports$2,Buffer$1=moduleExports$2?root.Zb:void 0,allocUnsafe=Buffer$1?Buffer$1.ig:void 0;function cloneBuffer(t,e){return e?t.slice():(e=t.length,e=allocUnsafe?allocUnsafe(e):new t.constructor(e),t.eg(e),e)}function arrayFilter(t,e){for(var r=-1,n=null==t?0:t.length,i=0,a=[];++r<n;){var o=t[r];e(o,r,t)&&(a[i++]=o)}return a}function stubArray(){return[]}var objectProto$c=Object.prototype,propertyIsEnumerable$1=objectProto$c.propertyIsEnumerable,nativeGetSymbols=Object.getOwnPropertySymbols,getSymbols=nativeGetSymbols?function(e){return null==e?[]:(e=Object(e),arrayFilter(nativeGetSymbols(e),function(t){return propertyIsEnumerable$1.call(e,t)}))}:stubArray;function copySymbols(t,e){return copyObject(t,getSymbols(t),e)}var nativeGetSymbols$1=Object.getOwnPropertySymbols,getSymbolsIn=nativeGetSymbols$1?function(t){for(var e=[];t;)arrayPush(e,getSymbols(t)),t=getPrototype(t);return e}:stubArray;function copySymbolsIn(t,e){return copyObject(t,getSymbolsIn(t),e)}function baseGetAllKeys(t,e,r){return e=e(t),isArray(t)?e:arrayPush(e,r(t))}function getAllKeys(t){return baseGetAllKeys(t,keys,getSymbols)}function getAllKeysIn(t){return baseGetAllKeys(t,keysIn,getSymbolsIn)}var DataView=getNative(root,"DataView"),Promise$1=getNative(root,"Promise"),Set=getNative(root,"Set"),mapTag$1="[object Map]",objectTag$1="[object Object]",promiseTag="[object Promise]",setTag$1="[object Set]",weakMapTag$1="[object WeakMap]",dataViewTag$1="[object DataView]",dataViewCtorString=toSource(DataView),mapCtorString=toSource(Map),promiseCtorString=toSource(Promise$1),setCtorString=toSource(Set),weakMapCtorString=toSource(WeakMap),getTag=baseGetTag,getTag$1=((DataView&&getTag(new DataView(new ArrayBuffer(1)))!=dataViewTag$1||Map&&getTag(new Map)!=mapTag$1||Promise$1&&getTag(Promise$1.resolve())!=promiseTag||Set&&getTag(new Set)!=setTag$1||WeakMap&&getTag(new WeakMap)!=weakMapTag$1)&&(getTag=function(t){var e=baseGetTag(t);if(t=(t=e==objectTag$1?t.constructor:void 0)?toSource(t):"")switch(t){case dataViewCtorString:return dataViewTag$1;case mapCtorString:return mapTag$1;case promiseCtorString:return promiseTag;case setCtorString:return setTag$1;case weakMapCtorString:return weakMapTag$1}return e}),getTag),objectProto$d=Object.prototype,hasOwnProperty$a=objectProto$d.hasOwnProperty;function initCloneArray(t){var e=t.length,r=new t.constructor(e);return e&&"string"==typeof t[0]&&hasOwnProperty$a.call(t,"index")&&(r.index=t.index,r.input=t.input),r}var Uint8Array$1=root.Uint8Array;function cloneArrayBuffer(t){var e=new t.constructor(t.byteLength);return new Uint8Array$1(e).set(new Uint8Array$1(t)),e}function cloneDataView(t,e){return e=e?cloneArrayBuffer(t.buffer):t.buffer,new t.constructor(e,t.byteOffset,t.byteLength)}var reFlags=/\w*$/;function cloneRegExp(t){var e=new t.constructor(t.source,reFlags.exec(t));return e.lastIndex=t.lastIndex,e}var symbolProto$1=Symbol$1?Symbol$1.prototype:void 0,symbolValueOf=symbolProto$1?symbolProto$1.valueOf:void 0;function cloneSymbol(t){return symbolValueOf?Object(symbolValueOf.call(t)):{}}function cloneTypedArray(t,e){return e=e?cloneArrayBuffer(t.buffer):t.buffer,new t.constructor(e,t.byteOffset,t.length)}var boolTag$1="[object Boolean]",dateTag$1="[object Date]",mapTag$2="[object Map]",numberTag$1="[object Number]",regexpTag$1="[object RegExp]",setTag$2="[object Set]",stringTag$1="[object String]",symbolTag$1="[object Symbol]",arrayBufferTag$1="[object ArrayBuffer]",dataViewTag$2="[object DataView]",float32Tag$1="[object Float32Array]",float64Tag$1="[object Float64Array]",int8Tag$1="[object Int8Array]",int16Tag$1="[object Int16Array]",int32Tag$1="[object Int32Array]",uint8Tag$1="[object Uint8Array]",uint8ClampedTag$1="[object Uint8ClampedArray]",uint16Tag$1="[object Uint16Array]",uint32Tag$1="[object Uint32Array]";function initCloneByTag(t,e,r){var n=t.constructor;switch(e){case arrayBufferTag$1:return cloneArrayBuffer(t);case boolTag$1:case dateTag$1:return new n(+t);case dataViewTag$2:return cloneDataView(t,r);case float32Tag$1:case float64Tag$1:case int8Tag$1:case int16Tag$1:case int32Tag$1:case uint8Tag$1:case uint8ClampedTag$1:case uint16Tag$1:case uint32Tag$1:return cloneTypedArray(t,r);case mapTag$2:return new n;case numberTag$1:case stringTag$1:return new n(t);case regexpTag$1:return cloneRegExp(t);case setTag$2:return new n;case symbolTag$1:return cloneSymbol(t)}}function initCloneObject(t){return"function"!=typeof t.constructor||isPrototype(t)?{}:baseCreate(getPrototype(t))}var mapTag$3="[object Map]";function baseIsMap(t){return isObjectLike(t)&&getTag$1(t)==mapTag$3}var nodeIsMap=nodeUtil&&nodeUtil.isMap,isMap=nodeIsMap?baseUnary(nodeIsMap):baseIsMap,setTag$3="[object Set]";function baseIsSet(t){return isObjectLike(t)&&getTag$1(t)==setTag$3}var nodeIsSet=nodeUtil&&nodeUtil.og,isSet=nodeIsSet?baseUnary(nodeIsSet):baseIsSet,CLONE_DEEP_FLAG=1,CLONE_FLAT_FLAG=2,CLONE_SYMBOLS_FLAG=4,argsTag$2="[object Arguments]",arrayTag$1="[object Array]",boolTag$2="[object Boolean]",dateTag$2="[object Date]",errorTag$1="[object Error]",funcTag$2="[object Function]",genTag$1="[object GeneratorFunction]",mapTag$4="[object Map]",numberTag$2="[object Number]",objectTag$2="[object Object]",regexpTag$2="[object RegExp]",setTag$4="[object Set]",stringTag$2="[object String]",symbolTag$2="[object Symbol]",weakMapTag$2="[object WeakMap]",arrayBufferTag$2="[object ArrayBuffer]",dataViewTag$3="[object DataView]",float32Tag$2="[object Float32Array]",float64Tag$2="[object Float64Array]",int8Tag$2="[object Int8Array]",int16Tag$2="[object Int16Array]",int32Tag$2="[object Int32Array]",uint8Tag$2="[object Uint8Array]",uint8ClampedTag$2="[object Uint8ClampedArray]",uint16Tag$2="[object Uint16Array]",uint32Tag$2="[object Uint32Array]",cloneableTags={};function baseClone(r,n,i,t,e,a){var o,s=n&CLONE_DEEP_FLAG,u=n&CLONE_FLAT_FLAG,c=n&CLONE_SYMBOLS_FLAG;if(void 0===(o=i?e?i(r,t,e,a):i(r):o)){if(!isObject(r))return r;if(t=isArray(r)){if(o=initCloneArray(r),!s)return copyArray(r,o)}else{var f=getTag$1(r),h=f==funcTag$2||f==genTag$1;if(isBuffer(r))return cloneBuffer(r,s);if(f==objectTag$2||f==argsTag$2||h&&!e){if(o=u||h?{}:initCloneObject(r),!s)return u?copySymbolsIn(r,baseAssignIn(o,r)):copySymbols(r,baseAssign(o,r))}else{if(!cloneableTags[f])return e?r:{};o=initCloneByTag(r,f,s)}}if(h=(a=a||new Stack).get(r))return h;a.set(r,o),isSet(r)?r.forEach(function(t){o.add(baseClone(t,n,i,t,r,a))}):isMap(r)&&r.forEach(function(t,e){o.set(e,baseClone(t,n,i,e,r,a))});var l=t?void 0:(c?u?getAllKeysIn:getAllKeys:u?keysIn:keys)(r);arrayEach(l||r,function(t,e){l&&(t=r[e=t]),assignValue(o,e,baseClone(t,n,i,e,r,a))})}return o}cloneableTags[argsTag$2]=cloneableTags[arrayTag$1]=cloneableTags[arrayBufferTag$2]=cloneableTags[dataViewTag$3]=cloneableTags[boolTag$2]=cloneableTags[dateTag$2]=cloneableTags[float32Tag$2]=cloneableTags[float64Tag$2]=cloneableTags[int8Tag$2]=cloneableTags[int16Tag$2]=cloneableTags[int32Tag$2]=cloneableTags[mapTag$4]=cloneableTags[numberTag$2]=cloneableTags[objectTag$2]=cloneableTags[regexpTag$2]=cloneableTags[setTag$4]=cloneableTags[stringTag$2]=cloneableTags[symbolTag$2]=cloneableTags[uint8Tag$2]=cloneableTags[uint8ClampedTag$2]=cloneableTags[uint16Tag$2]=cloneableTags[uint32Tag$2]=!0,cloneableTags[errorTag$1]=cloneableTags[funcTag$2]=cloneableTags[weakMapTag$2]=!1;var CLONE_SYMBOLS_FLAG$1=4;function clone(t){return baseClone(t,CLONE_SYMBOLS_FLAG$1)}var CLONE_DEEP_FLAG$1=1,CLONE_SYMBOLS_FLAG$2=4;function cloneDeep(t){return baseClone(t,CLONE_DEEP_FLAG$1|CLONE_SYMBOLS_FLAG$2)}var HASH_UNDEFINED$2="__lodash_hash_undefined__";function setCacheAdd(t){return this.ng.set(t,HASH_UNDEFINED$2),this}function setCacheHas(t){return this.ng.has(t)}function SetCache(t){var e=-1,r=null==t?0:t.length;for(this.ng=new MapCache;++e<r;)this.add(t[e])}function arraySome(t,e){for(var r=-1,n=null==t?0:t.length;++r<n;)if(e(t[r],r,t))return!0;return!1}function cacheHas(t,e){return t.has(e)}SetCache.prototype.add=SetCache.prototype.push=setCacheAdd,SetCache.prototype.has=setCacheHas;var COMPARE_PARTIAL_FLAG=1,COMPARE_UNORDERED_FLAG=2;function equalArrays(t,e,r,n,i,a){var o=r&COMPARE_PARTIAL_FLAG,s=t.length;if(s!=(u=e.length)&&!(o&&s<u))return!1;var u=a.get(t),c=a.get(e);if(u&&c)return u==e&&c==t;var f=-1,h=!0,l=r&COMPARE_UNORDERED_FLAG?new SetCache:void 0;for(a.set(t,e),a.set(e,t);++f<s;){var d,v=t[f],g=e[f];if(void 0!==(d=n?o?n(g,v,f,e,t,a):n(v,g,f,t,e,a):d)){if(d)continue;h=!1;break}if(l){if(!arraySome(e,function(t,e){if(!cacheHas(l,e)&&(v===t||i(v,t,r,n,a)))return l.push(e)})){h=!1;break}}else if(v!==g&&!i(v,g,r,n,a)){h=!1;break}}return a.delete(t),a.delete(e),h}function mapToArray(t){var r=-1,n=Array(t.size);return t.forEach(function(t,e){n[++r]=[e,t]}),n}function setToArray(t){var e=-1,r=Array(t.size);return t.forEach(function(t){r[++e]=t}),r}var COMPARE_PARTIAL_FLAG$1=1,COMPARE_UNORDERED_FLAG$1=2,boolTag$3="[object Boolean]",dateTag$3="[object Date]",errorTag$2="[object Error]",mapTag$5="[object Map]",numberTag$3="[object Number]",regexpTag$3="[object RegExp]",setTag$5="[object Set]",stringTag$3="[object String]",symbolTag$3="[object Symbol]",arrayBufferTag$3="[object ArrayBuffer]",dataViewTag$4="[object DataView]",symbolProto$2=Symbol$1?Symbol$1.prototype:void 0,symbolValueOf$1=symbolProto$2?symbolProto$2.valueOf:void 0;function equalByTag(t,e,r,n,i,a,o){switch(r){case dataViewTag$4:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case arrayBufferTag$3:return!(t.byteLength!=e.byteLength||!a(new Uint8Array$1(t),new Uint8Array$1(e)));case boolTag$3:case dateTag$3:case numberTag$3:return eq(+t,+e);case errorTag$2:return t.name==e.name&&t.message==e.message;case regexpTag$3:case stringTag$3:return t==e+"";case mapTag$5:var s=mapToArray;case setTag$5:var u,s=s||setToArray;return t.size==e.size||n&COMPARE_PARTIAL_FLAG$1?(u=o.get(t))?u==e:(n|=COMPARE_UNORDERED_FLAG$1,o.set(t,e),u=equalArrays(s(t),s(e),n,i,a,o),o.delete(t),u):!1;case symbolTag$3:if(symbolValueOf$1)return symbolValueOf$1.call(t)==symbolValueOf$1.call(e)}return!1}var COMPARE_PARTIAL_FLAG$2=1,objectProto$e=Object.prototype,hasOwnProperty$b=objectProto$e.hasOwnProperty;function equalObjects(t,e,r,n,i,a){var o=r&COMPARE_PARTIAL_FLAG$2,s=getAllKeys(t),u=s.length;if(u!=getAllKeys(e).length&&!o)return!1;for(var c=u;c--;){var f=s[c];if(!(o?f in e:hasOwnProperty$b.call(e,f)))return!1}var h=a.get(t),l=a.get(e);if(h&&l)return h==e&&l==t;for(var d=!0,v=(a.set(t,e),a.set(e,t),o);++c<u;){var g,p=t[f=s[c]],y=e[f];if(!(void 0===(g=n?o?n(y,p,f,e,t,a):n(p,y,f,t,e,a):g)?p===y||i(p,y,r,n,a):g)){d=!1;break}v=v||"constructor"==f}return d&&!v&&(h=t.constructor)!=(l=e.constructor)&&"constructor"in t&&"constructor"in e&&!("function"==typeof h&&h instanceof h&&"function"==typeof l&&l instanceof l)&&(d=!1),a.delete(t),a.delete(e),d}var COMPARE_PARTIAL_FLAG$3=1,argsTag$3="[object Arguments]",arrayTag$2="[object Array]",objectTag$3="[object Object]",objectProto$f=Object.prototype,hasOwnProperty$c=objectProto$f.hasOwnProperty;function baseIsEqualDeep(t,e,r,n,i,a){var o=isArray(t),s=isArray(e),u=o?arrayTag$2:getTag$1(t),s=s?arrayTag$2:getTag$1(e),c=(u=u==argsTag$3?objectTag$3:u)==objectTag$3,f=(s=s==argsTag$3?objectTag$3:s)==objectTag$3;if((s=u==s)&&isBuffer(t)){if(!isBuffer(e))return!1;c=!(o=!0)}return s&&!c?(a=a||new Stack,o||isTypedArray(t)?equalArrays(t,e,r,n,i,a):equalByTag(t,e,u,r,n,i,a)):r&COMPARE_PARTIAL_FLAG$3||(o=c&&hasOwnProperty$c.call(t,"__wrapped__"),u=f&&hasOwnProperty$c.call(e,"__wrapped__"),!o&&!u)?s&&equalObjects(t,e,r,n,i,a=a||new Stack):i(o?t.value():t,u?e.value():e,r,n,a=a||new Stack)}function baseIsEqual(t,e,r,n,i){return t===e||(null==t||null==e||!isObjectLike(t)&&!isObjectLike(e)?t!=t&&e!=e:baseIsEqualDeep(t,e,r,n,baseIsEqual,i))}var COMPARE_PARTIAL_FLAG$4=1,COMPARE_UNORDERED_FLAG$2=2;function baseIsMatch(t,e,r,n){var i=r.length,a=i,o=!n;if(null==t)return!a;for(t=Object(t);i--;){var s=r[i];if(o&&s[2]?s[1]!==t[s[0]]:!(s[0]in t))return!1}for(;++i<a;){var u=(s=r[i])[0],c=t[u],f=s[1];if(o&&s[2]){if(void 0===c&&!(u in t))return!1}else{var h,l=new Stack;if(!(void 0===(h=n?n(c,f,u,t,e,l):h)?baseIsEqual(f,c,COMPARE_PARTIAL_FLAG$4|COMPARE_UNORDERED_FLAG$2,n,l):h))return!1}}return!0}function isStrictComparable(t){return t==t&&!isObject(t)}function getMatchData(t){for(var e=keys(t),r=e.length;r--;){var n=e[r],i=t[n];e[r]=[n,i,isStrictComparable(i)]}return e}function matchesStrictComparable(e,r){return function(t){return null!=t&&t[e]===r&&(void 0!==r||e in Object(t))}}function baseMatches(e){var r=getMatchData(e);return 1==r.length&&r[0][2]?matchesStrictComparable(r[0][0],r[0][1]):function(t){return t===e||baseIsMatch(t,e,r)}}function baseHasIn(t,e){return null!=t&&e in Object(t)}function hasPath(t,e,r){for(var n=-1,i=(e=castPath(e,t)).length,a=!1;++n<i;){var o=toKey(e[n]);if(!(a=null!=t&&r(t,o)))break;t=t[o]}return a||++n!=i?a:!!(i=null==t?0:t.length)&&isLength(i)&&isIndex(o,i)&&(isArray(t)||isArguments(t))}function hasIn(t,e){return null!=t&&hasPath(t,e,baseHasIn)}var COMPARE_PARTIAL_FLAG$5=1,COMPARE_UNORDERED_FLAG$3=2;function baseMatchesProperty(r,n){return isKey(r)&&isStrictComparable(n)?matchesStrictComparable(toKey(r),n):function(t){var e=get(t,r);return void 0===e&&e===n?hasIn(t,r):baseIsEqual(n,e,COMPARE_PARTIAL_FLAG$5|COMPARE_UNORDERED_FLAG$3)}}function baseProperty(e){return function(t){return null==t?void 0:t[e]}}function basePropertyDeep(e){return function(t){return baseGet(t,e)}}function property(t){return isKey(t)?baseProperty(toKey(t)):basePropertyDeep(t)}function baseIteratee(t){return"function"==typeof t?t:null==t?identity:"object"==typeof t?isArray(t)?baseMatchesProperty(t[0],t[1]):baseMatches(t):property(t)}function createBaseFor(u){return function(t,e,r){for(var n=-1,i=Object(t),a=r(t),o=a.length;o--;){var s=a[u?o:++n];if(!1===e(i[s],s,i))break}return t}}var baseFor=createBaseFor();function baseForOwn(t,e){return t&&baseFor(t,e,keys)}function createBaseEach(a,o){return function(t,e){if(null!=t){if(!isArrayLike(t))return a(t,e);for(var r=t.length,n=o?r:-1,i=Object(t);(o?n--:++n<r)&&!1!==e(i[n],n,i););}return t}}var baseEach=createBaseEach(baseForOwn);function castFunction(t){return"function"==typeof t?t:identity}function forEach(t,e){return(isArray(t)?arrayEach:baseEach)(t,castFunction(e))}function arrayEvery(t,e){for(var r=-1,n=null==t?0:t.length;++r<n;)if(!e(t[r],r,t))return!1;return!0}function baseEvery(t,n){var i=!0;return baseEach(t,function(t,e,r){return i=!!n(t,e,r)}),i}function every(t,e,r){return(isArray(t)?arrayEvery:baseEvery)(t,baseIteratee(e=r&&isIterateeCall(t,e,r)?void 0:e))}function baseFilter(t,n){var i=[];return baseEach(t,function(t,e,r){n(t,e,r)&&i.push(t)}),i}function filter(t,e){return(isArray(t)?arrayFilter:baseFilter)(t,baseIteratee(e))}function createFind(a){return function(t,e,r){var n,i=Object(t);return isArrayLike(t)||(n=baseIteratee(e),t=keys(t),e=function(t){return n(i[t],t,i)}),-1<(e=a(t,e,r))?i[n?t[e]:e]:void 0}}var nativeMax$1=Math.max;function findIndex(t,e,r){var n=null==t?0:t.length;return n?((r=null==r?0:toInteger(r))<0&&(r=nativeMax$1(n+r,0)),baseFindIndex(t,baseIteratee(e),r)):-1}var find=createFind(findIndex);function baseMap(t,n){var i=-1,a=isArrayLike(t)?Array(t.length):[];return baseEach(t,function(t,e,r){a[++i]=n(t,e,r)}),a}function map(t,e){return(isArray(t)?arrayMap:baseMap)(t,baseIteratee(e))}function forIn(t,e){return null==t?t:baseFor(t,castFunction(e),keysIn)}var mapTag$6="[object Map]",setTag$6="[object Set]",objectProto$g=Object.prototype,hasOwnProperty$d=objectProto$g.hasOwnProperty;function isEmpty(t){if(null!=t){if(isArrayLike(t)&&(isArray(t)||"string"==typeof t||"function"==typeof t.splice||isBuffer(t)||isTypedArray(t)||isArguments(t)))return!t.length;var e,r=getTag$1(t);if(r==mapTag$6||r==setTag$6)return!t.size;if(isPrototype(t))return!baseKeys(t).length;for(e in t)if(hasOwnProperty$d.call(t,e))return!1}return!0}function isEqual(t,e){return baseIsEqual(t,e)}function isUndefined(t){return void 0===t}function baseSome(t,n){var i;return baseEach(t,function(t,e,r){return!(i=n(t,e,r))}),!!i}function some(t,e,r){return(isArray(t)?arraySome:baseSome)(t,baseIteratee(e=r&&isIterateeCall(t,e,r)?void 0:e))}var projections={},Projection=function(){function t(t,e,r,n){this.project=e,this.unproject=r,this.getResolution=n,projections[t]=this}return t.prototype.moveWithPixel=function(t,e,r){var r=this.getResolution(r),n=e[0]*r,e=e[1]*r,r=this.project(t[0],t[1]);return this.unproject(r[0]+n,r[1]+e)},t.prototype.moveWithPos=function(t,e){return t=[(t=this.project(t[0],t[1]))[0]+e[0],t[1]+e[1]],this.unproject(t[0],t[1])},t}(),ProjectionManager={getProjection:function(t){return projections[t]}},LngLat=new Projection("EPSG:4326",function(t,e){return[t,e]},function(t,e){return[t,e]},function(t){return.703125/Math.pow(2,t)}),SphericalMercator=function(){var n=Math.PI/180,r=180/Math.PI,i=6378137;return new Projection("EPSG:3857",function(t,e){var r=85.0511287798,r=(e=Math.max(Math.min(r,e),-r),t*n),t=e*n,t=Math.log(Math.tan(Math.PI/4+t/2));return[r*i,t*i]},function(t,e){return[t/i*r,(2*Math.atan(Math.exp(e/i))-Math.PI/2)*r]},function(t){return 156543.03392804097/Math.pow(2,t)})}(),LCS=function(){function t(){this.hg=[-20037508.342789244,-20037508.342789244,20037508.342789244,20037508.342789244],this.cg=128,this.vg=128,this.lg=(this.hg[2]-this.hg[0])/this.cg,this.dg=(this.hg[3]-this.hg[1])/this.vg}return t.prototype.setMap=function(t){this.map=t},t.prototype.getSize=function(){return[this.lg,this.dg]},t.prototype.getNum=function(){return[this.cg,this.vg]},t.prototype.getLocalByLnglat=function(t){var e=(e=ProjectionManager.getProjection("EPSG:3857")).project.apply(e,t);return this.getLocalByCoord(e)},t.prototype.getLocalByCoord=function(t){var e=Math.floor(t[0]/this.lg),r=Math.floor(t[1]/this.dg),n=this.getLocalCenterByXY(e,r);return{Sa:[t[0]-n.center[0],t[1]-n.center[1]],x:e,y:r,center:n.center,Ro:n.Ro}},t.prototype.getLocalCenterByXY=function(t,e){var r={x:t,y:e,center:[0,0],Ro:[0,0,0,0]};return r.center=[(t+.5)*this.lg,(e+.5)*this.dg],r.Ro=[t*this.lg,e*this.dg,(t+1)*this.lg,(e+1)*this.dg],r},t.prototype.getDeltaCoord=function(t){var e=this.getLocalByCoord(t);return[t[0]-e.center[0],t[1]-e.center[1]]},t}(),lcs=new LCS,E4326=ProjectionManager.getProjection("EPSG:4326"),E3857=ProjectionManager.getProjection("EPSG:3857"),HALF_WORLD_SIZE=20037508.342789244,LngLat$1={Ro:[-180,-90,180,90],project:function(t,e,r){return t=E4326.project(t,e),this.transform(t[0],t[1],r)},unproject:function(t,e,r){return t=this.Xs(t,e,r),E4326.unproject(t[0],t[1])},transform:function(t,e,r){var r=void 0===r?180:256<<r,i=this.Ro[2]-this.Ro[0],a=this.Ro[3]-this.Ro[1];return[t=(t-this.Ro[0])/i*(2*r),e=r-(e-this.Ro[1])/a*r]},Xs:function(t,e,r){return[t=360*(t/(2*(r=void 0===r?180:256<<r))-.5),e=180*-(e/r-.5)]},nt:function(t,e,r){return this.Xs(t,e,r)},wu:function(t,e,r){return this.Xs(t,e,r)},yo:function(t,e,r){var n=0<t/this.Ro[3]?Math.abs(Math.floor(t/this.Ro[3])):Math.abs(Math.ceil(t/this.Ro[3])),i=0<e/this.Ro[3]?Math.abs(Math.floor(e/this.Ro[3])):Math.abs(Math.ceil(e/this.Ro[3])),a=t%this.Ro[3],o=e%this.Ro[3],a=this.transform(a,o,r),o=(t=this.wu(t,t,r)[0]*n+a[0],e=this.wu(e,e,r)[1]*i+a[1],this.transform(0,0,r));return[t-o[0],e-o[1]]},Bb:function(t,e,r){return r.X(t,e)},qb:function(t,e,r){return r.H(t,e)},Gd:function(t,e,r,n){var i=n.X(t[0],t[1]);return[(n=n.X(t[0]+e,t[1]+r))[0]-i[0],n[1]-i[1]]}},SphericalMercator$1={Ro:[-20037508.342789244,-20037508.342789244,20037508.342789244,20037508.342789244],project:function(t,e,r){return t=E3857.project(t,e),this.transform(t[0],t[1],r)},unproject:function(t,e,r){return t=this.Xs(t,e,r),E3857.unproject(t[0],t[1])},transform:function(t,e,r){t=Math.min(20037508.342789244,Math.max(t,-20037508.342789244)),e=Math.min(20037508.342789244,Math.max(e,-20037508.342789244)),r=void 0===r?40075016.68557849:256*Math.pow(2,r);var n=this.Ro[2]-this.Ro[0],i=this.Ro[3]-this.Ro[1];return[t=(t-this.Ro[0])/n*r,e=r-(e-this.Ro[1])/i*r]},Xs:function(t,e,r){return[t=(t/(r=void 0===r?40075016.68557849:256*Math.pow(2,r))-.5)*this.Ro[2]*2,e=-(e/r-.5)*this.Ro[2]*2]},nt:function(t,e,r,n){return[t=this.Xs(t,e,r)[0]-this.Ro[0],e=this.Ro[2]-this.Xs(t,e,r)[1]]},wu:function(t,e,r,n){var i=n.center,a=n.size,n=(n.rotation||0)/180*Math.PI,e=(t=this.transform(t,e,r))[0],t=t[1],r=e-(i=this.transform(i[0],i[1],r))[0],e=t-i[1],t=Math.sqrt(Math.pow(r,2)+Math.pow(e,2)),i=0==e?Math.PI/2:Math.atan(Math.abs(r/e)),i=r*e<=0?i+n:i-n,n=0<e?1:-1;return[a[0]/2+t*Math.sin(0<r?i:-i),a[1]/2+t*Math.cos(i)*n]},yo:function(t,e,r,n){var i=0<t/this.Ro[3]?Math.abs(Math.floor(t/this.Ro[3])):Math.abs(Math.ceil(t/this.Ro[3])),a=0<e/this.Ro[3]?Math.abs(Math.floor(e/this.Ro[3])):Math.abs(Math.ceil(e/this.Ro[3])),o=t%this.Ro[3],s=e%this.Ro[3],o=this.transform(o,s,r),r=(s=this.transform(0,0,r))[0],s=s[1];return[(t=r*i+o[0])-r,(e=s*a+o[1])-s]},Bb:function(t,e,r){return r.X(t,e)},qb:function(t,e,r){return r.H(t,e)},Gd:function(t,e,r,n){var i=n.X(t[0],t[1]);return[(n=n.X(t[0]+e,t[1]+r))[0]-i[0],n[1]-i[1]]}},transform={"EPSG:4326":LngLat$1,"EPSG:3857":SphericalMercator$1},LocalZoom=13,LocalTileZoom=12,AMapStyleSource="",zoomRange=[2,26],CONSTS={ID:"__id__",Rp:zoomRange[1],Mp:zoomRange[0],jp:.8,Pp:.2,YM:5,KM:{dom:"div",id:"_amap_custom_labellayer_div_",className:"amap-layer",style:{cssText:"position:absolute;top:0;left:0;",zIndex:"",width:"",height:"",visible:""}},Dp:{Op:180,Ad:70,Td:360,t1:300,e1:30,Bd:Math.PI/10},XM:{top:3,right:3,bottom:3,left:3},JM:{ZM:"top",QM:"right",tj:"bottom",LEFT:"left",nj:"middle",ij:"center",ej:"alphabetic"},oj:{CLICK:"click",MOUSEOVER:"mouseover",MOUSEOUT:"mouseout",MOUSEMOVE:"mousemove",MOUSEDOWN:"mousedown",MOUSEUP:"mouseup",aj:"touchstart",uj:"touchend"},sj:{rank:1,angle:0,opacity:1,offset:[0,0],zooms:zoomRange,icon:{type:"image",image:"://visuallocal.amap.com/public/poi-marker.png",clipOrigin:[0,0],clipSize:[36,36],size:[36,36],anchor:"bottom-center",angel:0,retina:!0,zooms:zoomRange},text:{type:"billboard",direction:"top",offset:[0,0],zooms:zoomRange,style:{fj:6,fontFamily:"sans-serif",fontSize:12,fontWeight:"normal",fillColor:[0,0,0,1],strokeWidth:0,strokeColor:[.988,.988,.988,1],borderColor:"transparent",padding:[3,3,3,3],backgroundColor:""}}},hj:{cj:{opacity:.2},vj:"fadeIn",lj:"fadeOut",dj:{bj:"start",RUNNING:"running",pj:"complete"},yj:{mj:"opacity",gj:"size"}},_d:3,wj:"_AMap_sdf_com_words",Mj:128,pc:["://sdf.amap.com","://sdf01.amap.com","://sdf02.amap.com","://sdf03.amap.com","://sdf04.amap.com"],sp:4,Cd:.78125,Ld:205/256,Aj:{kj:"纹理加载失败,请重试",Oj:"资源加载失败,请重试"},xj:"bufferChanged",Ij:"frameBufferChanged",Tj:"combineFrameBufferChanged",ic:1,ud:13,Cj:12,Ej:"__icon_combination",Nj:"__text_combination",Lj:{file:{0:"://vdata.amap.com/style_icon/2.0/icon-normal-big.png",1:"://vdata.amap.com/style_icon/2.0/icon-biz-big.png"},size:[40,40],Rj:10},Kp:{buffer:3,family:"ios9",size:24},_n:{Uj:[0,0,0,1],Gp:[0,0,0,0]},gH:"sdf",RB:"sdfJson",FN:"version"},DangerousFontSize=(function(t){t.nebula="nebula",t.nebulaLabel="nebulaLabel"}(exports.n0||(exports.n0={})),24),EnumLabelFragType=(function(t){t[t.dynamic=0]="dynamic",t[t.icon=1]="icon"}(exports.cY||(exports.cY={})),{icon:0,bg:6,tq:8,text:2}),defaultCap=["butt","butt"],tmp1=(function(t){t.BLOB="blob",t.TOLOAD="toload",t.LOADING="loading",t.LOADED="loaded",t.UNLOADED="unloaded",t.ERROR="error",t.RELOADING="reloading",t.UNCOMBINED="uncombined",t.COMBINING="combining",t.COMBINED="combined"}(exports.uc||(exports.uc={})),4294901760),tmp2=65535;function getUploadName(t,e){return((t=tmp1-(t<<16))+(e=tmp2-e)).toString(16)}function staticSDFTileKeyToKey(t){var e=(t=map(t.split(","),function(t){return parseInt(t,10)}))[1],r=t[2];return t[0]<10?"lesszoom10":(10!==t[0]&&(12===t[0]?(e=Math.floor(e/4),r=Math.floor(r/4)):14===t[0]?(e=Math.floor(e/16),r=Math.floor(r/16)):15===t[0]&&(e=Math.floor(e/32),r=Math.floor(r/32))),getUploadName(e,r))}var labelsUtil={Bj:function(t){var e,r={};for(e in t=void 0===t?{}:t)t.hasOwnProperty(e)&&(r[e]=1);return r},zj:function(t,e){t.gs=e,t.qj=e.options||{},t.Wj=e.Wj||{},t.Fs=e.Fs||{},t.Gj=e.Gj||{},t.Hj=e.Hj||{},t.Vj=e.Vj||{},t.$j=e.$j||0},Yj:function(t,e){void 0===t&&(t=[NaN,NaN,NaN,NaN]),void 0===e&&(e=[0,0,0,1]);for(var r=0;r<t.length;r++){var n=t[r];isNaN(n)&&(t[r]=e[r])}return t},Kj:function(t){return[((16711680&t)>>16)/255,((65280&t)>>8)/255,(255&t)/255,1]},Xj:function(t,e){for(var r=[],n=(e=void 0===e?{}:e).qw,i=e.Aw,a=e.complete,o=0,s=t;o<s.length;o++){var u=s[o],u=new Promise(u);r.push(u)}var c=0;Promise.all(r).then(function(){n&&n.apply(void 0,arguments),a&&!c&&(c=1,a.apply(void 0,arguments))}).catch(function(){i&&i.apply(void 0,arguments),a&&!c&&(c=1,a.apply(void 0,arguments))})},Jj:function(t,e){var r=t[0],n=void 0===(n=t[1])?0:n,i=e[0],a=void 0===(a=e[1])?0:a;return(void 0===r?0:r)<=(i=void 0===i?0:i)?i<=n?a<n?[i,a]:[i,n]:null:labelsUtil.Jj(e,t)},measureText:function(t,e,r,n){if(void 0===e&&(e=""),"3D"===(n=void 0===n?"3D":n))return t.measureText(e,r)},lnglatToContainer:function(t,e){return(void 0===(e=e.zoom)?20:e)<LocalZoom?t:(e=lcs.getLocalByCoord(t),vector.Ip(t,e.center))},Sd:function(t,e){var r=t[0],t=void 0===(t=t[1])?0:t,n=e[0],e=void 0===(e=e[1])?0:e,n=Math.abs((void 0===n?0:n)-(void 0===r?0:r)),r=Math.abs(e-t);return Math.sqrt(Math.pow(n,2)+Math.pow(r,2))},getAngle:function(t,e){var r=t[0],t=t[1],n=(void 0===(n=e[0])?0:n)-(void 0===r?0:r),r=(void 0===(e=e[1])?0:e)-(void 0===t?0:t);return 0==n?r<0?3*Math.PI/2:Math.PI/2:0===(e=Math.atan(r/n))||0<e?0<=n?e:e+Math.PI:0<n?2*Math.PI+e:Math.PI+e},Fd:function(t,e,r){for(var n=t[0],i=void 0===n?0:n,a=void 0===(n=t[1])?0:n,o=(void 0===(t=e[0])?0:t)-i,s=(void 0===(n=e[1])?0:n)-a,u=[],c=0;c<r;)u.push([i+o/(r+1)*(c+1),a+s/(r+1)*(c+1)]),c++;return u},OG:function(t,e,r){return 0!==r?[t[0]+(e[0]-t[0])*r,t[1]+(e[1]-t[1])*r]:t},Ed:function(t,e){void 0===e&&(e="ch");var r,n,i,a=(t=void 0===t?[]:t).length;return!!a&&(r=t[0],t=t[4<=a?Math.floor(a/4*3):a-1],a=r[0],r=r[1],i=[(n=t[0])-a,(t=t[1])-r],("ch"===e&&1<Math.abs((t-r)/(n-a))?vector.Zj(i,[0,1]):vector.Zj(i,[1,0]))<0)},Nd:function(t,e,r){var n,i=t[0],t=t[1],a=e[0],o=((e=e[1])-t)/(a-i),a=[a-i,e-t];return 1<Math.abs(o)&&"x"!==r?(n=0<vector.Zj(a,[0,-1])?vector.Qj(a,[0,-1]):vector.Qj(a,[0,1]),0<o&&(n=-n)):(n=0<vector.Zj(a,[1,0])?vector.Qj(a,[1,0]):vector.Qj(a,[-1,0]),o<0&&(n=-n)),n},Od:function(t,e,r){var n=r*Math.sin(e),r=r*Math.cos(e);return[t[0]+r,t[1]+n]},jd:function(t,e,r,n){var t=vector.Ip(t,e),i=vector.length(t),r=vector.Ip(r,e),a=vector.length(r),t=vector.Zj(t,r),t=Math.acos(t/(i*a)),a=Math.PI-t,t=i*Math.sin(a),i=i*Math.cos(a),a=Math.sqrt(Math.pow(n,2)-Math.pow(t,2))-i,n=0===r[0]?0<r[1]?Math.PI/2:-Math.PI/2:Math.atan(r[1]/r[0]),t=Math.abs(a*Math.sin(n)),i=a*Math.cos(n),a=vector.Zj(r,[1,0]),n=vector.Zj(r,[0,1]);return vector.add(e,[0<=a?i:-i,0<=n?t:-t])},rank:function(t){for(var e=[],r=0;r<t.length;r++){var n=parseFloat(t[r]);n<0?(t.splice(r--,1),e.push(n)):t[r]=n}return t.sort(function(t,e){return t-e}),e.concat(t)},$p:function(t){var e=CONSTS.Mp,r=CONSTS.Rp;return t[1]>=zoomRange[1]&&(t[1]=r),t[0]<=zoomRange[0]&&(t[0]=e),t},toString:function(t,e){void 0===e&&(e=4);var r="";if(t)for(var n=0,i=t;n<i.length;n++){var a=i[n];r+=(a+"").length<e?a:a.toFixed(e)}return r},xf:function(t,e){var r,n,i,a=[],o=e.ja,s=e.Fa,u=e.Oa,c=e.Ea;for(r in t)t.hasOwnProperty(r)&&r!==CONSTS.gH&&r!==CONSTS.FN&&r!==CONSTS.RB&&("shields"===r||!o||(i=r.split("-"),n=parseInt(i[1],10),i=parseInt(i[2],10),o<=n&&n<=u&&s<=i&&i<=c))&&a.push(t[r]);return a.length?a:t},EQ:function(t,e){for(var r=[],n=e.length,i=0;i<n-1;i++){var a=t.substring(e[i],e[i+1]);r.push(a)}return n?r:t.split("")},aQ:function(t){for(var e=[],r=0;r<t.length;r++){for(var n=t[r],i=[],a=0;a<n.length;a++){var o=n.charCodeAt(a);i.push(o)}var s=i.join("|");e.push(s)}return e},tQ:function(t,e,r){var n="",i=[],a="";if(t.name){if(t.JQ&&0<t.JQ.length)n=getSpiltLineWithSpiltIndex(t.name,t.JQ);else if(r){var o=r.lineBreak(t.name,{from:"labelsLayer",CO:[]}),s=0,u="";if(2<=o.oQ.length){for(var c=1,f=o.oQ.length-1;c<f;c++)u+=t.name.slice(s,o.oQ[c])+" ",s=o.oQ[c];u+=t.name.slice(s)}else u=t.name;n=u}else n=t.name;a="ch"}else{switch(e){case"en":n=t.name_en,i=t.iQ,a="en";break;case"local":n=t.QQ,i=t.$G,a=t.CQ;break;default:n=t.BQ,a="ch"}n||(t.name_en?(n=t.name_en,i=t.iQ,a="en"):t.QQ&&(n=t.QQ,i=t.$G,a=t.QQ))}return{name:n,$G:i,type:a}}},vector={add:function(t,e){for(var r=[],n=0;n<t.length;n++)r[n]=t[n]+e[n];return r},Ip:function(t,e){for(var r=[],n=0;n<t.length;n++)r.push(t[n]-e[n]);return r},multiply:function(t,e){for(var r=[],n=0,i=t;n<i.length;n++){var a=i[n];r.push(a*e)}return r},Up:function(t,e){for(var r=[],n=0;n<t.length;n++)r[n]=t[n]/e;return r},tA:function(t){return this.multiply(t,-1)},Zj:function(t,e){var r=t[0],t=t[1],n=e[0];return(void 0===r?0:r)*(void 0===n?0:n)+(void 0===t?0:t)*(void 0===(e=e[1])?0:e)},Qj:function(t,e){var r=vector.Zj(t,e),t=vector.length(t),e=vector.length(e);return Math.acos(r/(t*e))},length:function(t){var e=t[0],t=t[1];return Math.sqrt(Math.pow(e,2)+Math.pow(t,2))}},noop=function(t){};function getSpiltLineWithSpiltIndex(t,e){if(e.shift(),0===e.length)return t;for(var r="",n=0,i=0,a=e.length;i<a;i++)r+=t.substr(n,e[i]-n)+" ",n=e[i];return r+t.substr(e[e.length-1])}var XHR={send:function(t,e){void 0===e&&(e={});var r=new XMLHttpRequest,i=void 0===(n=e.qw)?noop:n,a=void 0===(n=e.Aw)?noop:n,n=e.Me,o=e.method,e=e.content;return r.onreadystatechange=function(){if(4===r.readyState&&200===r.status){var t=r.response;try{i(t)}catch(t){a(t)}}else 404===r.status&&(r.abort(),a(Error("404")))},r.onerror=function(t){r.abort(),a(t)},r.open(o||"GET",t,!0),r.responseType=n||"json",r.send(e||void 0),r}},scale=Browser.scale,LabelsRenderUtil={getBounds:function(t,e){var r=(e=void 0===e?{}:e).zoom,n=e.centerCoord,i=(e.view,[150*scale,150*scale,150*scale,150*scale]),a=(t=t.boundsCoord)[0],o=t[1],s=t[2],t=t[3],u=this.nt(0,0,r,e),c=vector.Ip(this.nt(i[0],i[1],r,e),u),i=vector.Ip(this.nt(i[2],i[3],r,e),u),u=(e=LocalZoom<=r?n:[0,0])[0],r=e[1];return[[a-u-Math.abs(i[1]),o-r-Math.abs(i[0])],[s-u+Math.abs(c[1]),t-r+Math.abs(c[0])]]},gz:function(t,e){var r=e[0],e=e[1],n=t[0],t=t[1],i=n-r[0],r=t-r[1],n=e[0]-n,e=e[1]-t;return 0<=i&&0<=r&&0<=n&&0<=e},getRank:function(t,e){var r=(e=void 0===e?{}:e).forceShow,e=e._z,t=(t.data||{}).rank||1;return void 0!==r&&r?t-1e5:(void 0===e?0:e)/100*2e5+t},wu:function(t,e,r,n){var i,a,o,s,u,c;if(void 0===t&&(t=0),void 0===e&&(e=0),n)return u=n.viewState,s=n.size,i=n.transform,a=n.view,o=n.viewMode,c=n.centerCoord,n=void 0===(n=n.positionType)?"relative":n,"2D"===o?(o={center:u.centerCoord,rotation:u.rotation,size:s},u=(s=u.optimalZoom>=LocalZoom?c:[0,0])[0],c=s[1],i.wu(t+u,e+c,r,o)):"relative"===n?a.H(t,e):a._u(t,e)},r0:function(t,e,r,n,i){var a,o,s,u,c,f;if(void 0===t&&(t=0),void 0===e&&(e=0),void 0===r&&(r=0),i)return c=i.viewState,u=i.size,a=i.transform,o=i.view,s=i.viewMode,f=i.centerCoord,i=void 0===(i=i.positionType)?"relative":i,"2D"===s?(s={center:c.centerCoord,rotation:c.rotation,size:u},c=(u=c.optimalZoom>=LocalZoom?f:[0,0])[0],f=u[1],a.wu(t+c,e+f,n,s)):"relative"===i?o.H(t,e,r):o._u(t,e,r)},kz:function(t,e,r,n){if(void 0===t&&(t=[]),n=(n=void 0===n?{}:n).centerCoord,e<LocalZoom&&LocalZoom<=r){for(var i=n[0],a=n[1],o=[],s=0,u=t;s<u.length;s++){var c=u[s];o.push([c[0]-i,c[1]-a])}return o}return t},nt:function(t,e,r,n){void 0===t&&(t=0),void 0===e&&(e=0);var i=n.view,a=n.transform;return"2D"===n.viewMode?a.nt(t,e,r):i.X(t,e)},MG:function(t,e){return t<LocalZoom-1?[0,0]:e}};function isLngLat(t){return t&&"AMap.LngLat"===t.className}function isPixel(t){return t&&"AMap.Pixel"===t.className}function isSize(t){return t&&"AMap.Size"===t.className}function isLayer(t){return Boolean(t&&t.el&&"AMap.Layer"===t.el)}function isVectorLayer(t){return t&&"AMap.VectorLayer"===t.CLASS_NAME}function isOverlay(t){return t&&t.className&&Util.startsWith(t.className,"Overlay")}function isOverlayGroup(t){return t&&("Overlay.OverlayGroup"===t.className||"Overlay.GeoJSON"===t.className)}function isCircleMarker(t){return t&&t.className&&"Overlay.CircleMarker"===t.className}function isPolyline(t){return t&&t.className&&"Overlay.Polyline"===t.className}function isBezierCurve(t){return t&&t.className&&"Overlay.BezierCurve"===t.className}function isBounds(t){return t&&"AMap.Bounds"===t.className}function isNumber(t){return"number"==typeof(t=+t)&&!isNaN(t)}function isNumberArray(t){return Array.isArray(t)&&isNumber(t[0])}function isNumberArrayArray(t){return Array.isArray(t)&&isNumberArray(t[0])}function isNumberArrayArrayArray(t){return Array.isArray(t)&&isNumberArrayArray(t[0])}function isNumberArrayArrayArrayArray(t){return Array.isArray(t)&&isNumberArrayArrayArray(t[0])}function isLnglatLike(t){return isLngLat(t)||isNumberArray(t)}function isLnglatLikeArray(t){return Array.isArray(t)&&isLnglatLike(t[0])}function isLnglatLikeArrayArray(t){return Array.isArray(t)&&isLnglatLikeArray(t[0])}function isLnglatLikeArrayArrayArray(t){return Array.isArray(t)&&isLnglatLikeArrayArray(t[0])}function isInnerLabelsLayer(t){return t&&"AMap.Inner.LabelsLayer"===t.CLASS_NAME}function isUndefined$1(t){return void 0===t}function calcTileMectorBounds(t,e,r){var n=ProjectionManager.getProjection("EPSG:3857"),a=180/(t=Math.pow(2,t)),i=(e=(i=360/t)*e-180)+i,r=(t=a*(t-r-1)-90)+a;return[e=(a=n.project(e,t))[0],t=a[1],(a=n.project(i,r))[0],a[1]]}function parseLngLatData(t){if(Array.isArray(t)){var e;if(!Array.isArray(t[0]))return"string"==(e=typeof t[0])||"number"==e?new LngLat$2(t[0],t[1]):t;for(var r=0;r<t.length;r+=1)t[r]=parseLngLatData(t[r])}return t}function jsonLngLatData(t){if(isLngLat(t))return[t.getLng(),t.getLat()];if(Array.isArray(t)){for(var e=t.slice(0),r=0;r<e.length;r+=1)e[r]=jsonLngLatData(e[r]);return e}return t}var Coordinate={lr:function(t,e){for(var r=1/0,n=0,i=1,a=e.length;i<a;n=i,i+=1)r=Math.min(r,this.ur(t,[e[n],e[i]]));return Math.sqrt(r)},ur:function(t,e){return this.cr(t,this.closestOnSegment(t,e))},cr:function(t,e){var r=t[0]-e[0];return r*r+(t=t[1]-e[1])*t},pr:function(t,e,r,n){var i,a;return n=n||1e-6,r[0]===e[0]?(i=Math.min(e[1],r[1]),a=Math.max(e[1],r[1]),Math.abs(t[0]-r[0])<n&&t[1]>=i&&t[1]<=a):(i=Math.min(e[0],r[0]),a=Math.max(e[0],r[0]),r=(r[1]-e[1])/(r[0]-e[0])*(t[0]-e[0])+e[1],Math.abs(r-t[1])<n&&t[0]>=i&&t[0]<=a)},closestOnSegment:function(t,e){var r,n=t[0],t=t[1],i=e[0],e=e[1],a=i[0],i=i[1],o=e[0],s=o-a,u=(e=e[1])-i,t=(n=0==s&&0==u?0:(s*(n-a)+u*(t-i))/(s*s+u*u||0))<=0?(r=a,i):1<=n?(r=o,e):(r=a+n*s,i+n*u);return[r,t]},isClockwise:function(t){for(var e,r,n=t.length,i=0,a=t[n-1],o=a[0],s=a[1],u=0;u<n;u+=1)i+=((e=(r=t[u])[0])-o)*((r=r[1])+s),o=e,s=r;return 0<i},ss:function(t,e,r){for(var n=t[0],i=t[1],a=!1,o=e.length,s=0,u=o-1;s<o;u=s,s+=1){var c=!1,f=e[s][0],h=e[s][1],l=e[u][0],d=e[u][1];if(f===n&&h===i||l===n&&d===i)return!!r;if(h<i==i<=d){if(n===(l=(l-f)*(i-h)/(d-h)+f))return!!r;c=n<l}c&&(a=!a)}return a},dr:function(t,e){for(var r,n=function(t,e,r){return(r[0]-e[0])*(t[1]-e[1])>(r[1]-e[1])*(t[0]-e[0])},i=function(t,e,r,n){var i=[t[0]-e[0],t[1]-e[1]],a=[r[0]-n[0],r[1]-n[1]],t=t[0]*e[1]-t[1]*e[0],e=r[0]*n[1]-r[1]*n[0],r=1/(i[0]*a[1]-i[1]*a[0]);return[(t*a[0]-e*i[0])*r,(t*a[1]-e*i[1])*r]},a=t,o=e[e.length-2],s=0,u=e.length-1;s<u;s++){for(var c=e[s],f=a,a=[],h=f[f.length-1],l=0,d=f.length;l<d;l++)n(r=f[l],o,c)?(n(h,o,c)||a.push(i(o,c,h,r)),a.push(r)):n(h,o,c)&&a.push(i(o,c,h,r)),h=r;o=c}return a.length<3?[]:(a.push(a[0]),a)}},Pixel=function(){function r(t,e,r){if(void 0===r&&(r=!1),this.className="AMap.Pixel",(isNaN(t)||isNaN(e))&&!window._AMapConfig)throw Error("Invalid Object: Pixel("+t+", "+e+")");this.x=r?Math.round(t):Number(t),this.y=r?Math.round(e):Number(e)}return r.prototype.getX=function(){return this.x},r.prototype.round=function(){return new r(Math.round(this.x),Math.round(this.y))},r.prototype.getY=function(){return this.y},r.prototype.toString=function(){return this.x+","+this.y},r.prototype.equals=function(t){return t instanceof r&&Math.max(Math.abs(this.x-t.x),Math.abs(this.y-t.y))<=1e-9},r.prototype.toArray=function(){return[this.x,this.y]},r.prototype.subtract=function(t,e){return new r(this.x-t.x,this.y-t.y,e)},r.prototype.multiplyBy=function(t,e){return new r(this.x*t,this.y*t,e)},r.prototype.direction=function(){var t,e=this.x,r=this.y;return 0===e&&0===r?null:0===e?0<r?90:270:(t=180*Math.atan(r/e)/Math.PI,e<0&&0<r||e<0&&r<0?180+t:0<e&&r<0?360+t:t)},r.prototype.toJSON=function(){return[this.x,this.y]},r}(),commonjsGlobal="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function unwrapExports(t){return t&&t.gP&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function createCommonjsModule(t,e){return t(e={exports:{}},e.exports),e.exports}var dist=createCommonjsModule(function(u,t){function c(t,e){return e<t?1:t<e?-1:0}function y(t,e,r){null===e?(t.PP=!1,t.OP=!0):(t._P===e._P?(t.PP=!e.PP,t.OP=e.OP):(t.PP=!e.OP,t.OP=e.NP()?!e.PP:e.PP),e&&(t.CP=!n(e,r)||e.NP()?e.CP:e)),e=n(t,r),t.hN=e?function(t,e){var r,n=!t.PP,i=!t.OP;switch(e){case w:r=n&&i;break;case P:r=n||i;break;case N:r=n^i;break;case C:r=t._P?n&&!i:i&&!n}return r?1:-1}(t,r):0}function n(t,e){switch(t.type){case o:switch(e){case w:return!t.OP;case P:return t.OP;case C:return t._P&&t.OP||!t._P&&!t.OP;case N:return!0}break;case M:return e===w||e===P;case S:return e===C;case x:return!1}return!1}function v(t,e){return t[0]===e[0]&&t[1]===e[1]}function I(t,e,r,n,i){var a,o,s,u,c=e[0],f=n[0],h=0,l=0,d=(c<f==-c<f?(a=c,c=e[++h]):(a=f,f=n[++l]),0);if(h<t&&l<r)for(c<f==-c<f?(s=a-((o=c+a)-c),c=e[++h]):(s=a-((o=f+a)-f),f=n[++l]),a=o,0!==s&&(i[d++]=s);h<t&&l<r;)c<f==-c<f?(s=a-((o=a+c)-(u=o-a))+(c-u),c=e[++h]):(s=a-((o=a+f)-(u=o-a))+(f-u),f=n[++l]),a=o,0!==s&&(i[d++]=s);for(;h<t;)s=a-((o=a+c)-(u=o-a))+(c-u),c=e[++h],a=o,0!==s&&(i[d++]=s);for(;l<r;)s=a-((o=a+f)-(u=o-a))+(f-u),f=n[++l],a=o,0!==s&&(i[d++]=s);return 0===a&&0!==d||(i[d++]=a),d}function e(t){return new(commonjsGlobal.Float64Array?Float64Array:Array)(t)}function i(t,e,r){n=t[0],t=t[1],i=e[0],e=e[1];var n,i,a,o,s,a=r[0],s=(o=(t-(r=r[1]))*(i-a))-(u=(n-a)*(e-r)),u=0==o||0==u||0<o!=0<u||(o=Math.abs(o+u),Math.abs(s)>=33306690738754716e-32*o)?s:-function(t,e,r,n,i,a,o){var s,u,c,f,h,l,d,v,g,p,y=t-i,m=r-i,b=e-a,T=n-a,A=y*T,x=$*y,M=x-(x-y),S=y-M,w=(k[0]=(d=S*(c=T-(u=(x=$*T)-(x-T)))-(A-M*u-S*u-M*c))-((f=d-(g=(S=b-(M=(x=$*b)-(x-b)))*(c=m-(u=(x=$*m)-(x-m)))-((v=b*m)-M*u-S*u-M*c)))+(s=d-f))+(s-g),k[1]=(l=A-((h=A+f)-(s=h-A))+(f-s))-((f=l-v)+(s=l-f))+(s-v),k[2]=h-((p=h+f)-(s=p-h))+(f-s),k[3]=p,function(e){for(var r=e[0],n=1;n<4;n++)r+=e[n];return r}(k)),P=22204460492503146e-32*o;return P<=w||P<=-w||(t=t-(y+(s=t-y))+(s-i),r=r-(m+(s=r-m))+(s-i),i=e-(b+(s=e-b))+(s-a),e=n-(T+(s=n-T))+(s-a),0==t&&0==i&&0==r&&0==e)||(P=11093356479670487e-47*o+33306690738754706e-32*Math.abs(w))<=(w+=y*e+T*t-(b*r+m*i))||P<=-w?w:(E[0]=(d=(S=t-(M=(x=$*t)-(x-t)))*(c=T-(u=(x=$*T)-(x-T)))-((A=t*T)-M*u-S*u-M*c))-((f=d-(g=(S=i-(M=(x=$*i)-(x-i)))*(c=m-(u=(x=$*m)-(x-m)))-((v=i*m)-M*u-S*u-M*c)))+(s=d-f))+(s-g),E[1]=(l=A-((h=A+f)-(s=h-A))+(f-s))-((f=l-v)+(s=l-f))+(s-v),E[2]=h-((p=h+f)-(s=p-h))+(f-s),E[3]=p,n=I(4,k,4,E,L),E[0]=(d=(S=y-(M=(x=$*y)-(x-y)))*(c=e-(u=(x=$*e)-(x-e)))-((A=y*e)-M*u-S*u-M*c))-((f=d-(g=(S=b-(M=(x=$*b)-(x-b)))*(c=r-(u=(x=$*r)-(x-r)))-((v=b*r)-M*u-S*u-M*c)))+(s=d-f))+(s-g),E[1]=(l=A-((h=A+f)-(s=h-A))+(f-s))-((f=l-v)+(s=l-f))+(s-v),E[2]=h-((p=h+f)-(s=p-h))+(f-s),E[3]=p,a=I(n,L,4,E,O),E[0]=(d=(S=t-(M=(x=$*t)-(x-t)))*(c=e-(u=(x=$*e)-(x-e)))-((A=t*e)-M*u-S*u-M*c))-((f=d-(g=(S=i-(M=(x=$*i)-(x-i)))*(c=r-(u=(x=$*r)-(x-r)))-((v=i*r)-M*u-S*u-M*c)))+(s=d-f))+(s-g),E[1]=(l=A-((h=A+f)-(s=h-A))+(f-s))-((f=l-v)+(s=l-f))+(s-v),E[2]=h-((p=h+f)-(s=p-h))+(f-s),E[3]=p,o=I(a,O,4,E,_),_[o-1])}(n,t,i,e,a,r,o);return 0<u?-1:u<0?1:0}function m(t,e){var r=t.point,n=e.point;return r[0]>n[0]?1:r[0]<n[0]?-1:r[1]!==n[1]?r[1]>n[1]?1:-1:(n=e,e=r,(r=t).left===n.left?0===i(e,r.IP.point,n.IP.point)?!r._P&&n._P?1:-1:r.FP(n.IP.point)?-1:1:r.left?1:-1)}function g(t,e,r){var n=new l(e,!1,t,t._P),e=new l(e,!0,t.IP,t._P);v(t.point,t.IP.point)&&console.warn("what is that, a collapsed segment?",t),n.UP=e.UP=t.UP,0<m(e,t.IP)&&(t.IP.left=!0,e.left=!1),t.IP.IP=e,t.IP=n,r.push(e),r.push(n)}function p(t,e){return t[0]*e[1]-t[1]*e[0]}function b(t,e){return t[0]*e[0]+t[1]*e[1]}function T(t,e,r){n=t.point,i=t.IP.point,h=e.point,d=e.IP.point;var n,i,o,s,u,f,h,l,d,i=[i[0]-n[0],i[1]-n[1]],d=[d[0]-h[0],d[1]-h[1]],u=[h[0]-n[0],h[1]-n[1]],s=p(i,d),f=b(i,i);function c(t,e,r){return[t[0]+e*r[0],t[1]+e*r[1]]}return 0===(d=(u=0<s*s?(o=p(u,d)/s)<0||1<o||(l=p(u,i)/s)<0||1<l?null:0!=o&&1!=o&&(0==l||1==l)?[c(h,l,d)]:[c(n,o,i)]:!(0<(s=p(u,i))*s)&&(l=(h=b(i,u)/f)+b(i,d)/f,o=Math.min(h,l),s=Math.max(h,l),o<=1)&&0<=s?1===o?[c(n,0<o?o:0,i)]:0===s?[c(n,s<1?s:1,i)]:[c(n,0<o?o:0,i),c(n,s<1?s:1,i)]:null)?u.length:0)||1===d&&(v(t.point,e.point)||v(t.IP.point,e.IP.point))||2===d&&t._P===e._P?0:1===d?(v(t.point,u[0])||v(t.IP.point,u[0])||g(t,u[0],r),v(e.point,u[0])||v(e.IP.point,u[0])||g(e,u[0],r),1):(l=h=!(f=[]),v(t.point,e.point)?h=!0:1===m(t,e)?f.push(e,t):f.push(t,e),v(t.IP.point,e.IP.point)?l=!0:1===m(t.IP,e.IP)?f.push(e.IP,t.IP):f.push(t.IP,e.IP),h&&l||h?(e.type=x,t.type=e.PP===t.PP?M:S,h&&!l&&g(f[1].IP,f[0].point,r),2):(l?g(f[0],f[1].point,r):f[0]!==f[3].IP?(g(f[0],f[1].point,r),g(f[1],f[2].point,r)):(g(f[0],f[1].point,r),g(f[3].IP,f[2].point,r)),3))}function D(t,e){var r,n;return t===e?0:0!==i(t.point,t.IP.point,e.point)||0!==i(t.point,t.IP.point,e.IP.point)?v(t.point,e.point)?t.FP(e.IP.point)?-1:1:t.point[0]===e.point[0]?t.point[1]<e.point[1]?-1:1:1===m(t,e)?e.RP(t.point)?-1:1:t.FP(e.point)?-1:1:t._P!==e._P?t._P?-1:1:(r=t.point,n=e.point,r[0]===n[0]&&r[1]===n[1]?(r=t.IP.point,n=e.IP.point,r[0]===n[0]&&r[1]===n[1]?0:t.UP>e.UP?1:-1):1===m(t,e)?1:-1)}function h(t,e){return t<e?-1:e<t?1:0}function G(t,e,r,n,i,a){for(var o=0,s=t.length-1;o<s;o++){var u=t[o],c=t[o+1],f=new l(u,!1,void 0,e),h=new l(c,!1,f,e);f.IP=h,u[0]===c[0]&&u[1]===c[1]||(f.UP=h.UP=r,a||(f.DP=!1,h.DP=!1),0<m(f,h)?h.left=!0:f.left=!0,c=u[0],u=u[1],i[0]=j(i[0],c),i[1]=j(i[1],u),i[2]=d(i[2],c),i[3]=d(i[3],u),n.push(f),n.push(h))}}function r(t,e,r){if("number"==typeof t[0][0][0]&&(t=[t]),u=e="number"==typeof e[0][0][0]?[e]:e,n=null,(c=t).length*u.length==0&&(r===w?n=R:r===C?n=c:r!==P&&r!==N||(n=0===c.length?u:c)),n)return n===R?null:n;var o,s=[1/0,1/0,-1/0,-1/0],u=[1/0,1/0,-1/0,-1/0],c=function(t,e,r,n,i){for(var a,o,s,u,c=new U(null,m),f=0,h=t.length;f<h;f++)for(s=0,u=(a=t[f]).length;s<u;s++)(o=0===s)&&F++,G(a[s],!0,F,c,r,o);for(f=0,h=e.length;f<h;f++)for(s=0,u=(a=e[f]).length;s<u;s++)o=0===s,(o=i!==C&&o)&&F++,G(a[s],!1,F,c,n,o);return c}(t,e,s,u,r),n=t;if(t=e,e=r,o=null,(s[0]>u[2]||s[2]<u[0]||u[3]<s[1]||s[3]<u[1])&&(e===w?o=R:e===C?o=n:e!==P&&e!==N||(o=n.concat(t))),o)return o===R?null:o;for(var f=function(t){for(var f=function(t){for(var e,r,n=[],i=0,a=t.length;i<a;i++)((e=t[i]).left&&e.EP||!e.left&&e.IP.EP)&&n.push(e);for(var o=!1;!o;)for(o=!0,i=0,a=n.length;i<a;i++)i+1<a&&1===m(n[i],n[i+1])&&(r=n[i],n[i]=n[i+1],n[i+1]=r,o=!1);for(i=0,a=n.length;i<a;i++)(e=n[i]).lN=i;for(i=0,a=n.length;i<a;i++)(e=n[i]).left||(r=e.lN,e.lN=e.IP.lN,e.IP.lN=r);return n}(t),h={},l=[],d=0,r=f.length;d<r;d++)!function(){if(!h[d]){var t,e,r,n,i=l.length,a=(c=f[d],t=l,e=i,n=new V,null!=c.CP?(r=(c=c.CP).dN,0<c.hN?null!=(c=t[r]).gN?(t[c=c.gN].vN.push(e),n.gN=c,n.depth=t[r].depth):(t[r].vN.push(e),n.gN=r,n.depth=t[r].depth+1):(n.gN=null,n.depth=t[r].depth)):(n.gN=null,n.depth=0),n),o=function(t){h[t]=!0,f[t].dN=i},s=d,u=d,c=f[d].point;for(a.points.push(c);o(s),o(s=f[s].lN),a.points.push(f[s].point),(s=function(t,e,r,n){var i,a=t+1,o=e[t].point,s=e.length;for(a<s&&(i=e[a].point);a<s&&i[0]===o[0]&&i[1]===o[1];){if(!r[a])return a;i=e[++a].point}for(a=t-1;r[a]&&n<a;)a--;return a}(s,f,h,u))!=u;);l.push(a)}}();return l}(function(t,e,r,n){for(var i=new A(D),a=[],o=Math.min(e[2],r[2]);0!==t.length;){var s,u,c,f,h,l=t.pop();if(a.push(l),n===w&&l.point[0]>o||n===C&&l.point[0]>e[2])break;l.left?(c=u=i.Xc(l),u=u!==(s=i.MP())?i.NM(u):null,c=i.next(c),y(l,f=u?u.key:null,n),c&&2===T(l,c.key,t)&&(y(l,f,n),y(l,c.key,n)),u&&2===T(u.key,l,t)&&(y(f,(h=(h=u)!==s?i.NM(h):null)?h.key:null,n),y(l,f,n))):(l=l.IP,c=u=i.find(l),u&&c&&(u=u!==s?i.NM(u):null,c=i.next(c),i.remove(l),c)&&u&&T(u.key,c.key,t))}return a}(c,s,u,r)),h=[],l=0;l<f.length;l++){var d=f[l];if(d.pN()){for(var v=[d.points],g=0;g<d.vN.length;g++){var p=d.vN[g];v.push(f[p].points)}h.push(v)}}return h}var A,o,x,M,S,w,P,C,N,l,$,k,L,O,_,E,V,U,d,j,F,R,s={size:{configurable:!0}};(A=function(t,e){void 0===e&&(e=!1),this.bP=t=void 0===t?c:t,this.yP=null,this._size=0,this.mP=!!e}).prototype.TP=function(t){var e=t.right;e&&(t.right=e.left,e.left&&(e.left.parent=t),e.parent=t.parent),t.parent?t===t.parent.left?t.parent.left=e:t.parent.right=e:this.yP=e,e&&(e.left=t),t.parent=e},A.prototype.wP=function(t){var e=t.left;e&&(t.left=e.right,e.right&&(e.right.parent=t),e.parent=t.parent),t.parent?t===t.parent.left?t.parent.left=e:t.parent.right=e:this.yP=e,e&&(e.right=t),t.parent=e},A.prototype.AP=function(t){for(;t.parent;){var e=t.parent;e.parent?e.left===t&&e.parent.left===e?(this.wP(e.parent),this.wP(e)):e.right===t&&e.parent.right===e?(this.TP(e.parent),this.TP(e)):e.left===t&&e.parent.right===e?(this.wP(e),this.TP(e)):(this.TP(e),this.wP(e)):e.left===t?this.wP(e):this.TP(e)}},A.prototype.xP=function(t){for(var e,r,n,i;t.parent;)(r=(e=t.parent).parent)&&r.parent?((n=r.parent).left===r?n.left=t:n.right=t,t.parent=n):(t.parent=null,this.yP=t),n=t.left,i=t.right,t===e.left?(r&&(r.left===e?(e.right?(r.left=e.right,r.left.parent=r):r.left=null,(e.right=r).parent=e):(n?(r.right=n).parent=r:r.right=null,(t.left=r).parent=t)),i?(e.left=i).parent=e:e.left=null,(t.right=e).parent=t):(r&&(r.right===e?(e.left?(r.right=e.left,r.right.parent=r):r.right=null,(e.left=r).parent=e):(i?(r.left=i).parent=r:r.left=null,(t.right=r).parent=t)),n?(e.right=n).parent=e:e.right=null,(t.left=e).parent=t)},A.prototype.replace=function(t,e){t.parent?t===t.parent.left?t.parent.left=e:t.parent.right=e:this.yP=e,e&&(e.parent=t.parent)},A.prototype.MP=function(t){if(t=void 0===t?this.yP:t)for(;t.left;)t=t.left;return t},A.prototype.SP=function(t){if(t=void 0===t?this.yP:t)for(;t.right;)t=t.right;return t},A.prototype.Xc=function(t,e){var r=this.yP,n=null,i=this.bP;if(this.mP)for(;r;){if(0===i((n=r).key,t))return;r=i(r.key,t)<0?r.right:r.left}else for(;r;)r=i((n=r).key,t)<0?r.right:r.left;return r={key:t,data:e,left:null,right:null,parent:n},n?i(n.key,r.key)<0?n.right=r:n.left=r:this.yP=r,this.xP(r),this._size++,r},A.prototype.find=function(t){for(var e=this.yP,r=this.bP;e;){var n=r(e.key,t);if(n<0)e=e.right;else{if(!(0<n))return e;e=e.left}}return null},A.prototype.contains=function(t){for(var e=this.yP,r=this.bP;e;){var n=r(t,e.key);if(0===n)return!0;e=n<0?e.left:e.right}return!1},A.prototype.remove=function(t){var e;return!!(t=this.find(t))&&(this.xP(t),t.left?t.right?((e=this.MP(t.right)).parent!==t&&(this.replace(e,e.right),e.right=t.right,e.right.parent=e),this.replace(t,e),e.left=t.left,e.left.parent=e):this.replace(t,t.left):this.replace(t,t.right),this._size--,!0)},A.prototype.removeNode=function(t){var e;return!!t&&(this.xP(t),t.left?t.right?((e=this.MP(t.right)).parent!==t&&(this.replace(e,e.right),e.right=t.right,e.right.parent=e),this.replace(t,e),e.left=t.left,e.left.parent=e):this.replace(t,t.left):this.replace(t,t.right),this._size--,!0)},A.prototype.$P=function(t){var e,r;(t=this.find(t))&&(this.xP(t),e=t.left,t=t.right,r=null,e&&(e.parent=null,r=this.SP(e),this.xP(r),this.yP=r),t&&(e?r.right=t:this.yP=t,t.parent=r),this._size--)},A.prototype.pop=function(){var t=this.yP,e=null;if(t){for(;t.left;)t=t.left;e={key:t.key,data:t.data},this.remove(t.key)}return e},A.prototype.next=function(t){var e=t;if(e)if(e.right)for(e=e.right;e&&e.left;)e=e.left;else for(e=t.parent;e&&e.right===t;)e=(t=e).parent;return e},A.prototype.NM=function(t){var e=t;if(e)if(e.left)for(e=e.left;e&&e.right;)e=e.right;else for(e=t.parent;e&&e.left===t;)e=(t=e).parent;return e},A.prototype.forEach=function(t){for(var e=this.yP,r=[],n=!1,i=0;!n;)e?(r.push(e),e=e.left):0<r.length?(t(e=r.pop(),i++),e=e.right):n=!0;return this},A.prototype.range=function(t,e,r,n){for(var i=[],a=this.bP,o=this.yP;0!==i.length||o;)if(o)i.push(o),o=o.left;else{if(0<a((o=i.pop()).key,e))break;if(0<=a(o.key,t)&&r.call(n,o))return this;o=o.right}return this},A.prototype.keys=function(){for(var t=this.yP,e=[],r=[],n=!1;!n;)t?(e.push(t),t=t.left):0<e.length?(t=e.pop(),r.push(t.key),t=t.right):n=!0;return r},A.prototype.values=function(){for(var t=this.yP,e=[],r=[],n=!1;!n;)t?(e.push(t),t=t.left):0<e.length?(t=e.pop(),r.push(t.data),t=t.right):n=!0;return r},A.prototype.at=function(t){for(var e=this.yP,r=[],n=!1,i=0;!n;)if(e)r.push(e),e=e.left;else if(0<r.length){if(e=r.pop(),i===t)return e;i++,e=e.right}else n=!0;return null},A.prototype.load=function(t,e,r){if(void 0===t&&(t=[]),void 0===e&&(e=[]),void 0===r&&(r=!1),0!==this._size)throw new Error("bulk-load: tree is not empty");var n=t.length;return r&&function t(e,r,n,i,a){if(!(i<=n)){for(var o=e[n+i>>1],s=n-1,u=i+1;;){for(;a(e[++s],o)<0;);for(;0<a(e[--u],o););if(u<=s)break;var c=e[s];e[s]=e[u],e[u]=c,c=r[s],r[s]=r[u],r[u]=c}t(e,r,n,u,a),t(e,r,u+1,i,a)}}(t,e,0,n-1,this.bP),this.yP=function t(e,r,n,i,a){var u,o=a-i;return 0<o?((u={key:u=r[o=i+Math.floor(o/2)],data:n[o],parent:e}).left=t(u,r,n,i,o),u.right=t(u,r,n,o+1,a),u):null}(null,t,e,0,n),this._size=n,this},A.prototype.min=function(){var t=this.MP(this.yP);return t?t.key:null},A.prototype.max=function(){var t=this.SP(this.yP);return t?t.key:null},A.prototype.isEmpty=function(){return null===this.yP},s.size.get=function(){return this._size},A.LP=function(t,e,r,n,i){return new A(r,i).load(t,e,n)},Object.defineProperties(A.prototype,s),P=x=1,C=M=2,N=S=3,s={EP:{configurable:!(w=o=0)}},(l=function(t,e,r,n,i){this.left=e,this.point=t,this.IP=r,this._P=n,this.type=i||o,this.PP=!1,this.OP=!1,this.CP=null,this.hN=0,this.lN=-1,this.dN=-1,this.DP=!0}).prototype.FP=function(t){var e=this.point,r=this.IP.point;return this.left?0<(e[0]-t[0])*(r[1]-t[1])-(r[0]-t[0])*(e[1]-t[1]):0<(r[0]-t[0])*(e[1]-t[1])-(e[0]-t[0])*(r[1]-t[1])},l.prototype.RP=function(t){return!this.FP(t)},l.prototype.NP=function(){return this.point[0]===this.IP.point[0]},s.EP.get=function(){return 0!==this.hN},l.prototype.clone=function(){var t=new l(this.point,this.left,this.IP,this._P,this.type);return t.UP=this.UP,t.hN=this.hN,t.CP=this.CP,t.DP=this.DP,t.PP=this.PP,t.OP=this.OP,t},Object.defineProperties(l.prototype,s),$=134217729,k=e(4),L=e(8),O=e(12),_=e(16),E=e(4),(V=function(){this.points=[],this.vN=[],this.gN=null,this.depth=null}).prototype.pN=function(){return null==this.gN},(s=U=function a(t,e){if(!(this instanceof a))return new a(t,e);if(this.data=t||[],this.length=this.data.length,this.compare=e||h,0<this.length)for(var r=(this.length>>1)-1;0<=r;r--)this.zP(r)}).prototype={push:function(t){this.data.push(t),this.length++,this.El(this.length-1)},pop:function(){var t;if(0!==this.length)return t=this.data[0],this.length--,0<this.length&&(this.data[0]=this.data[this.length],this.zP(0)),this.data.pop(),t},GP:function(){return this.data[0]},El:function(t){for(var e=this.data,r=this.compare,n=e[t];0<t;){var i=t-1>>1,a=e[i];if(0<=r(n,a))break;e[t]=a,t=i}e[t]=n},zP:function(t){for(var e=this.data,r=this.compare,n=this.length>>1,i=e[t];t<n;){var a=1+(t<<1),o=a+1,s=e[a];if(o<this.length&&r(e[o],s)<0&&(s=e[a=o]),0<=r(s,i))break;e[t]=s,t=a}e[t]=i}},U.default=s,d=Math.max,j=Math.min,F=0,R=[],s={VP:P,BP:C,HP:w,WP:N},t.ZP=function(t,e){return r(t,e,C)},t.qP=function(t,e){return r(t,e,w)},t.YP=s,t.union=function(t,e){return r(t,e,P)},t.xor=function(t,e){return r(t,e,N)},Object.defineProperty(t,"gP",{value:!0})}),martinez=unwrapExports(dist),Const={vr:Math.PI/180,mr:180/Math.PI,yr:6378137};function getSphericalCrs(t,e){var r=function(t){switch(t){case"EPSG3857":return ProjectionManager.getProjection("EPSG:3857");case"EPSG4326":return ProjectionManager.getProjection("EPSG:4326")}return ProjectionManager.getProjection("EPSG3857")}(t);return{project:function(t){return Util.isArray(t)&&(t=new LngLat$2(t[0],t[1])),r.project(t.lng,t.lat)},unproject:function(t){return Util.isArray(t)&&(t=new Pixel(t[0],t[1])),r.unproject(t.x,t.y)},normalizePoint:function(t){return Util.parseLngLatData(t)},distance:function(t,e){if(e=this.normalizePoint(e),Util.isArray(e))return this.distanceToLine(t,e);t=this.normalizePoint(t);var r=Const.vr,n=Math.cos,i=t.lat*r,t=t.lng*r,a=e.lat*r,e=e.lng*r,r=2*Const.yr,e=e-t,t=(1-n(a-i)+(1-n(e))*n(i)*n(a))/2;return r*Math.asin(Math.sqrt(t))},ringArea:function(t){t=this.normalizeLine(t);var e=Const.yr*Const.vr,r=0,n=t,i=n.length;if(i<3)return 0;for(var a=0;a<i-1;a+=1){var o=n[a],s=n[a+1],u=o.lng*e*Math.cos(o.lat*Const.vr),o=o.lat*e,c=s.lng*e*Math.cos(s.lat*Const.vr);r+=u*(s.lat*e)-c*o}var t=n[a],f=n[0],h=t.lng*e*Math.cos(t.lat*Const.vr),t=t.lat*e,l=f.lng*e*Math.cos(f.lat*Const.vr);return r+=h*(f.lat*e)-l*t,.5*Math.abs(r)},sphericalCalotteArea:function(t){var e=Const.yr,t=e-e*Math.cos(t/e);return 2*Math.PI*e*t}}}function getPlanarCrs(){return{normalizePoint:function(t){return t&&t.x&&t.y?[t.x,t.y]:t},distance:function(t,e){var r=t[0]-e[0],t=t[1]-e[1];return Math.sqrt(r*r+t*t)},project:function(t){return t},unproject:function(t){return t},ringArea:function(t){for(var e=[0,0],r=[0,0],n=0,i=t[0],a=t.length,o=2;o<a;o++){var s=t[o-1],u=t[o];e[0]=i[0]-u[0],e[1]=i[1]-u[1],r[0]=i[0]-s[0],r[1]=i[1]-s[1],n+=e[0]*r[1]-e[1]*r[0]}return n/2}}}function isClockwise(t){for(var e=0,r=t.length,n=0;n<r-1;n++){var i,a=t[n];e+=((i=t[n+1])[0]-a[0])*(i[1]+a[1])}return t[r-1][0]===t[0][0]&&t[r-1][1]===t[0][1]||(a=t[r-1],e+=((i=t[0])[0]-a[0])*(i[1]+a[1])),0<e}var GeometryUtilCls=function(){function e(t){this.CLASS_NAME="AMap.GeometryUtil",this._opts=assign({onSegmentTolerance:5,crs:"EPSG3857",maxZoom:zoomRange[1]},t),this.setCrs(this._opts.crs)}return e.prototype.clone=function(t){return new e(assign({},this._opts,t))},e.prototype.isPoint=function(t){return t&&(t instanceof LngLat$2||Util.isArray(t)&&!isNaN(t[0]))},e.prototype.normalizePoint=function(t){return t},e.prototype.normalizeLine=function(t){for(var e=[],r=0,n=t.length;r<n;r++)e.push(this.normalizePoint(t[r]));return e},e.prototype.normalizeMultiLines=function(t){for(var e=[],r=0,n=(t=Util.isArray(t)&&this.isPoint(t[0])?[t]:t).length;r<n;r++)e.push(this.normalizeLine(t[r]));return e},e.prototype.setCrs=function(t){t=t&&t.project&&t.unproject?t:"plane"===t?getPlanarCrs():getSphericalCrs(t,this._opts.maxZoom),assign(this,t)},e.prototype.distance=function(t,e){throw new Error("distance Not implemented!")},e.prototype.xr=function(t,e){t=this.normalizeLine(t);for(var r=[],n=0,i=(t=this.isPoint(t[0])?t:t[0]).length;n<i;n++)r.push(this.project(t[n]));return!0===e?r=this.makesureClockwise(r):!1===e&&(r=this.makesureClockwise(r)).reverse(),r},e.prototype.br=function(t){for(var e=[],r=0,n=t.length;r<n;r++)e.push(this.unproject(t[r]));return e},e.prototype.closestOnSegment=function(t,e,r){return t=Coordinate.closestOnSegment(this.project(t),this.xr([e,r])),this.unproject(t)},e.prototype.closestOnLine=function(t,e){for(var r,n=1/0,i=0,a=(e=this.normalizeLine(e)).length;i<a-1;i++){var o=this.closestOnSegment(t,e[i],e[i+1]),s=this.distance(t,o);s<n&&(n=s,r=o)}return r},e.prototype.distanceToSegment=function(t,e,r){return this.distanceToLine(t,[e,r])},e.prototype.distanceToLine=function(t,e){e=this.normalizeLine(e);for(var r=1/0,n=0,i=(e=this.isPoint(e[0])?e:e[0]).length;n<i-1;n++)var a=this.closestOnSegment(t,e[n],e[n+1]),r=Math.min(r,this.distance(t,a));return r},e.prototype.distanceToPolygon=function(t,e){return this.isPointInRing(t,e)?0:this.distanceToLine(t,e)},e.prototype.isPointOnSegment=function(t,e,r,n){return(!n&&0!==n||n<0)&&(n=this._opts.onSegmentTolerance),this.distanceToSegment(t,e,r)<=n},e.prototype.isPointOnLine=function(t,e,r){for(var n=0,i=(e=this.normalizeLine(e)).length;n<i-1;n++)if(this.isPointOnSegment(t,e[n],e[n+1],r))return!0;return!1},e.prototype.isPointOnRing=function(t,e,r){for(var n=0,i=(e=this.normalizeLine(e)).length;n<i;n++)if(this.isPointOnSegment(t,e[n],e[n===i-1?0:n+1],r))return!0;return!1},e.prototype.isPointOnPolygon=function(t,e,r){for(var n=0,i=(e=this.normalizeMultiLines(e)).length;n<i;n++)if(this.isPointOnRing(t,e[n],r))return!0;return!1},e.prototype.makesureClockwise=function(t){return isClockwise(t)||(t=[].concat(t)).reverse(),t},e.prototype.makesureAntiClockwise=function(t){return isClockwise(t)&&(t=[].concat(t)).reverse(),t},e.prototype.pointInRing=function(t,e,r){for(var n=!1,i=0;i<e.length&&!n;i++)if(s(t,e[i][0],r)){for(var a=!1,o=1;o<e[i].length&&!a;)s(t,e[i][o],!r)&&(a=!0),o++;a||(n=!0)}function s(t,e,r){for(var n=!1,i=0,a=(e=e[0][0]===e[e.length-1][0]&&e[0][1]===e[e.length-1][1]?e.slice(0,e.length-1):e).length-1;i<e.length;a=i++){var o=e[i][0],s=e[i][1],u=e[a][0],c=e[a][1];if(t[1]*(o-u)+s*(u-t[0])+c*(t[0]-o)==0&&(o-t[0])*(u-t[0])<=0&&(s-t[1])*(c-t[1])<=0)return!r;s>t[1]!=c>t[1]&&t[0]<(u-o)*(t[1]-s)/(c-s)+o&&(n=!n)}return n}return n},e.prototype.isPointInBbox=function(t,e){for(var r=1/0,n=1/0,i=-1/0,a=-1/0,o=0;o<e.length;o++)var s=e[o],r=Math.min(r,s[0]),i=Math.max(i,s[0]),n=Math.min(n,s[1]),a=Math.max(a,s[1]);return t[0]>r&&t[0]<i&&t[1]>n&&t[1]<a},e.prototype.isPointInRing=function(t,e){return e=this.normalizeLine(e),e=this.xr(e,!0),Coordinate.ss(this.project(t),e,!1)},e.prototype.isRingInRing=function(t,e){for(var r=0,n=t.length;r<n;r++)if(!this.isPointInRing(t[r],e))return!1;return!0},e.prototype.isRingInRingByOutsea=function(t,e){for(var r=0,n=t.length;r<n;r++)if(this.isPointInRing(t[r],e))return!0;for(r=0,n=e.length;r<n;r++)if(this.isPointInRing(e[r],t))return!0;return!1},e.prototype.isRingInRingByMapbox=function(t,e){for(var r=0,n=t.length;r<n;r++)if(!this.isPointInRing(t[r],e))return!1;return!0},e.prototype.isRingInRingByMapboxB=function(t,e){for(var r=0,n=t.length;r<n;r++)if(this.isPointInRing(t[r],e))return!0;return!1},e.prototype.isPixelRingInRing=function(t,e){for(var r=0,n=t.length;r<n;r++)if(Coordinate.ss(t[r],e,!1))return!0;return!1},e.prototype.isPointInPolygon=function(t,e){for(var r,n=0,i=(e=this.normalizeMultiLines(e)).length;n<i&&(r=this.isPointInRing(t,e[n]),r=0<n?!r:r);n+=1);return Boolean(r)},e.prototype.isPointInPolygons=function(t,e){for(var r=0;r<e.length;r++){for(var n=e[r],i=void 0,a=0,o=(n=this.normalizeMultiLines(n)).length;a<o&&(i=this.isPointInRing(t,n[a]),i=0<a?!i:i);a+=1);if(i)return!0}return!1},e.prototype.doesSegmentsIntersect=function(t,e,r,n){t=(i=this.xr([t,e,r,n]))[0],e=i[1],r=i[2];var i=((n=i[3])[0]-r[0])*(t[1]-r[1])-(n[1]-r[1])*(t[0]-r[0]),o=(e[0]-t[0])*(t[1]-r[1])-(e[1]-t[1])*(t[0]-r[0]);return 0!=(n=(n[1]-r[1])*(e[0]-t[0])-(n[0]-r[0])*(e[1]-t[1]))&&(r=o/n,0<=(e=i/n))&&e<=1&&0<=r&&r<=1},e.prototype.doesSegmentLineIntersect=function(t,e,r){for(var n=0,i=(r=this.normalizeLine(r)).length;n<i-1;n++)if(this.doesSegmentsIntersect(t,e,r[n],r[n+1]))return!0;return!1},e.prototype.doesSegmentRingIntersect=function(t,e,r){for(var n=0,i=(r=this.normalizeLine(r)).length;n<i;n++)if(this.doesSegmentsIntersect(t,e,r[n],r[n===i-1?0:n+1]))return!0;return!1},e.prototype.doesSegmentPolygonIntersect=function(t,e,r){for(var n=0,i=(r=this.normalizeMultiLines(r)).length;n<i;n++)if(this.doesSegmentRingIntersect(t,e,r[n]))return!0;return!1},e.prototype.doesLineLineIntersect=function(t,e){for(var r=0,n=(t=this.normalizeLine(t)).length;r<n-1;r++)if(this.doesSegmentLineIntersect(t[r],t[r+1],e))return!0;return!1},e.prototype.doesLineRingIntersect=function(t,e){for(var r=0,n=(t=this.normalizeLine(t)).length;r<n-1;r++)if(this.doesSegmentRingIntersect(t[r],t[r+1],e))return!0;return!1},e.prototype.doesPolygonPolygonIntersect=function(t,e){return!!(this.doesRingRingIntersect(e,t)||this.isRingInRing(t,e)||this.isRingInRing(e,t))},e.prototype.doesRingRingIntersect=function(t,e){for(var r=0,n=(t=this.normalizeLine(t)).length;r<n;r++)if(this.doesSegmentRingIntersect(t[r],t[r===n-1?0:r+1],e))return!0;return!1},e.prototype.along=function(t,e){for(var r=0,n=0;n<t.length-1;n+=1){var i,a=this.distance(t[n],t[n+1]);if(!(a+r<e))return[t[n][0]+(i=(e-r)/a)*(t[n+1][0]-t[n][0]),t[n][1]+i*(t[n+1][1]-t[n][1]),n];r+=a}return null},e.prototype.gr=function(t,e){for(var a,r=function(t){return(c[0]-o[0])*(t[1]-o[1])>(c[1]-o[1])*(t[0]-o[0])},n=function(){var t=[o[0]-c[0],o[1]-c[1]],e=[h[0]-a[0],h[1]-a[1]],r=o[0]*c[1]-o[1]*c[0],n=h[0]*a[1]-h[1]*a[0],i=1/(t[0]*e[1]-t[1]*e[0]);return[(r*e[0]-n*t[0])*i,(r*e[1]-n*t[1])*i]},i=t=this.makesureAntiClockwise(t),o=(e=this.makesureClockwise(e))[e.length-1],s=0,u=e.length;s<u;s++){for(var c=e[s],f=i,i=[],h=f[f.length-1],l=0,d=f.length;l<d;l++)r(a=f[l])?(r(h)||i.push(n()),i.push(a)):r(h)&&i.push(n()),h=a;o=c}return i},e.prototype.ringRingClip=function(t,e){return t=this.xr(t),e=this.xr(e),isEqual(t[0],t[t.length-1])||t.push(t[0].slice()),isEqual(e[0],e[e.length-1])||e.push(e[0].slice()),(t=martinez.qP([t],[e]))&&t[0]&&t[0][0]?this.br(t[0][0]):[]},e.prototype.ringArea=function(t){throw new Error("distance Not implemented!")},e.prototype.distanceOfLine=function(t){for(var e=0,r=0,n=(t=this.normalizeLine(t)).length;r<n-1;r++)e+=this.distance(t[r],t[r+1]);return e},e.prototype.isClockwise=function(t){return isClockwise(t=this.xr(t))},e.prototype.typePolygon=function(t){return isArray(t)&&isArray(t[0])?2===t[0][0].length||t[0][0]instanceof LngLat$2?"Polygon":2<t[0][0].length&&(2===t[0][0][0].length||t[0][0][0]instanceof LngLat$2)?"MultiPolygon":"never":"never"},e}(),GeometryUtilInstance=new GeometryUtilCls({}),PlaneGeometryUtilInstance=new GeometryUtilCls({}),GeometryUtil=(PlaneGeometryUtilInstance.setCrs("plane"),{distance:GeometryUtilInstance.distance.bind(GeometryUtilInstance),ringArea:GeometryUtilInstance.ringArea.bind(GeometryUtilInstance),isClockwise:GeometryUtilInstance.isClockwise.bind(GeometryUtilInstance),typePolygon:GeometryUtilInstance.typePolygon.bind(GeometryUtilInstance),makesureClockwise:GeometryUtilInstance.makesureClockwise.bind(GeometryUtilInstance),makesureAntiClockwise:GeometryUtilInstance.makesureAntiClockwise.bind(GeometryUtilInstance),distanceOfLine:GeometryUtilInstance.distanceOfLine.bind(GeometryUtilInstance),ringRingClip:GeometryUtilInstance.ringRingClip.bind(GeometryUtilInstance),doesSegmentsIntersect:GeometryUtilInstance.doesSegmentsIntersect.bind(GeometryUtilInstance),doesSegmentLineIntersect:GeometryUtilInstance.doesSegmentLineIntersect.bind(GeometryUtilInstance),doesSegmentRingIntersect:GeometryUtilInstance.doesSegmentRingIntersect.bind(GeometryUtilInstance),doesSegmentPolygonIntersect:GeometryUtilInstance.doesSegmentPolygonIntersect.bind(GeometryUtilInstance),doesLineLineIntersect:GeometryUtilInstance.doesLineLineIntersect.bind(GeometryUtilInstance),doesLineRingIntersect:GeometryUtilInstance.doesLineRingIntersect.bind(GeometryUtilInstance),doesRingRingIntersect:GeometryUtilInstance.doesRingRingIntersect.bind(GeometryUtilInstance),pointInRing:GeometryUtilInstance.pointInRing.bind(GeometryUtilInstance),isPointInRing:GeometryUtilInstance.isPointInRing.bind(GeometryUtilInstance),isPointInBbox:GeometryUtilInstance.isPointInBbox.bind(GeometryUtilInstance),isRingInRing:GeometryUtilInstance.isRingInRing.bind(GeometryUtilInstance),isPointInPolygon:GeometryUtilInstance.isPointInPolygon.bind(GeometryUtilInstance),isPointInPolygons:GeometryUtilInstance.isPointInPolygons.bind(GeometryUtilInstance),isPointOnSegment:GeometryUtilInstance.isPointOnSegment.bind(GeometryUtilInstance),isPointOnLine:GeometryUtilInstance.isPointOnLine.bind(GeometryUtilInstance),isPointOnRing:GeometryUtilInstance.isPointOnRing.bind(GeometryUtilInstance),isPointOnPolygon:GeometryUtilInstance.isPointOnPolygon.bind(GeometryUtilInstance),closestOnSegment:GeometryUtilInstance.closestOnSegment.bind(GeometryUtilInstance),closestOnLine:GeometryUtilInstance.closestOnLine.bind(GeometryUtilInstance),distanceToSegment:GeometryUtilInstance.distanceToSegment.bind(GeometryUtilInstance),distanceToLine:GeometryUtilInstance.distanceToLine.bind(GeometryUtilInstance)}),PlaneGeometryUtil={distance:PlaneGeometryUtilInstance.distance.bind(PlaneGeometryUtilInstance),ringArea:PlaneGeometryUtilInstance.ringArea.bind(PlaneGeometryUtilInstance),isClockwise:PlaneGeometryUtilInstance.isClockwise.bind(PlaneGeometryUtilInstance),typePolygon:PlaneGeometryUtilInstance.typePolygon.bind(PlaneGeometryUtilInstance),makesureClockwise:PlaneGeometryUtilInstance.makesureClockwise.bind(PlaneGeometryUtilInstance),makesureAntiClockwise:PlaneGeometryUtilInstance.makesureAntiClockwise.bind(PlaneGeometryUtilInstance),distanceOfLine:PlaneGeometryUtilInstance.distanceOfLine.bind(PlaneGeometryUtilInstance),ringRingClip:PlaneGeometryUtilInstance.ringRingClip.bind(PlaneGeometryUtilInstance),doesSegmentsIntersect:PlaneGeometryUtilInstance.doesSegmentsIntersect.bind(PlaneGeometryUtilInstance),doesSegmentLineIntersect:PlaneGeometryUtilInstance.doesSegmentLineIntersect.bind(PlaneGeometryUtilInstance),doesSegmentRingIntersect:PlaneGeometryUtilInstance.doesSegmentRingIntersect.bind(PlaneGeometryUtilInstance),doesSegmentPolygonIntersect:PlaneGeometryUtilInstance.doesSegmentPolygonIntersect.bind(PlaneGeometryUtilInstance),doesLineLineIntersect:PlaneGeometryUtilInstance.doesLineLineIntersect.bind(PlaneGeometryUtilInstance),doesLineRingIntersect:PlaneGeometryUtilInstance.doesLineRingIntersect.bind(PlaneGeometryUtilInstance),doesRingRingIntersect:PlaneGeometryUtilInstance.doesRingRingIntersect.bind(PlaneGeometryUtilInstance),pointInRing:PlaneGeometryUtilInstance.pointInRing.bind(PlaneGeometryUtilInstance),isPointInRing:PlaneGeometryUtilInstance.isPointInRing.bind(PlaneGeometryUtilInstance),isPointInBbox:PlaneGeometryUtilInstance.isPointInBbox.bind(PlaneGeometryUtilInstance),isRingInRing:PlaneGeometryUtilInstance.isRingInRing.bind(PlaneGeometryUtilInstance),isPointInPolygon:PlaneGeometryUtilInstance.isPointInPolygon.bind(PlaneGeometryUtilInstance),isPointInPolygons:PlaneGeometryUtilInstance.isPointInPolygons.bind(PlaneGeometryUtilInstance),isPointOnSegment:PlaneGeometryUtilInstance.isPointOnSegment.bind(PlaneGeometryUtilInstance),isPointOnLine:PlaneGeometryUtilInstance.isPointOnLine.bind(PlaneGeometryUtilInstance),isPointOnRing:PlaneGeometryUtilInstance.isPointOnRing.bind(PlaneGeometryUtilInstance),isPointOnPolygon:PlaneGeometryUtilInstance.isPointOnPolygon.bind(PlaneGeometryUtilInstance),closestOnSegment:PlaneGeometryUtilInstance.closestOnSegment.bind(PlaneGeometryUtilInstance),closestOnLine:PlaneGeometryUtilInstance.closestOnLine.bind(PlaneGeometryUtilInstance),distanceToSegment:PlaneGeometryUtilInstance.distanceToSegment.bind(PlaneGeometryUtilInstance),distanceToLine:PlaneGeometryUtilInstance.distanceToLine.bind(PlaneGeometryUtilInstance)},LngLat$2=function(){function r(t,e,r){if(void 0===r&&(r=!1),this.className="AMap.LngLat",isNumberArray(t)?(t=parseFloat(t[0]),e=parseFloat(t[1])):(e=parseFloat(e),t=parseFloat(t)),(isNaN(t)||isNaN(e))&&!window._AMapConfig)throw Error("Invalid Object: LngLat("+t+", "+e+")");!0!==r&&(e=Math.max(Math.min(e,90),-90),t=(t+180)%360+(t<-180||180===t?180:-180)),this.kT=e,this.KL=t,this.lng=Math.round(1e6*t)/1e6,this.lat=Math.round(1e6*e)/1e6,this.pos=ProjectionManager.getProjection("EPSG:3857").project(t,e)}return r.from=function(t){return isLngLat(t)?new r(t.KL,t.kT):new r(t[0],t[1])},r.prototype.setLng=function(t){return this.KL=t,this.lng=Math.round(1e6*t)/1e6,this},r.prototype.setLat=function(t){return this.kT=t,this.lat=Math.round(1e6*t)/1e6,this},r.prototype.getLng=function(){return this.lng},r.prototype.getLat=function(){return this.lat},r.prototype.equals=function(t){return(t=parseLngLatData(t))instanceof r&&Math.max(Math.abs(this.kT-t.kT),Math.abs(this.KL-t.KL))<=1e-9},r.prototype.add=function(t,e){return new r(this.KL+t.KL,this.kT+t.kT,e)},r.prototype.subtract=function(t,e){return new r(this.KL-t.KL,this.kT-t.kT,e)},r.prototype.divideBy=function(t,e){return new r(this.KL/t,this.kT/t,e)},r.prototype.multiplyBy=function(t,e){return new r(this.KL*t,this.kT*t,e)},r.prototype.offset=function(t,e){if(isNaN(t)||isNaN(e))throw Error("valid offset args, require number");return t=2*Math.asin(Math.sin(Math.round(t)/12756274)/Math.cos(this.kT*Math.PI/180)),t=this.KL+180*t/Math.PI,e=2*Math.asin(Math.round(e)/12756274),new r(t,this.kT+180*e/Math.PI)},r.prototype.toString=function(){return this.lng+","+this.lat},r.prototype.toArray=function(){return[this.lng,this.lat]},r.prototype.toJSON=function(){return[this.lng,this.lat]},r.prototype.distanceTo=function(t){return GeometryUtil.distance(this,t)},r.prototype.distance=function(t){return GeometryUtil.distance(this,t)},r}(),Size=function(){function t(t,e,r){if(void 0===r&&(r=!1),this.className="AMap.Size",isNaN(t)||isNaN(e))throw new Error("Invalid Object: Pixel("+t+", "+e+")");this.width=r?Math.round(t):Number(t),this.height=r?Math.round(e):Number(e)}return t.prototype.getWidth=function(){return this.width},t.prototype.getHeight=function(){return this.height},t.prototype.toString=function(){return this.width+","+this.height},t.prototype.toArray=function(){return[this.width,this.height]},t}(),easing=function(){var o={},s="function"==typeof Float32Array;function n(t,e){return 1-3*e+3*t}function w(t,e,r){return((n(e,r)*t+(3*r-6*e))*t+3*e)*t}function P(t,e,r){return 3*n(e,r)*t*t+2*(3*r-6*e)*t+3*e}function u(t){return t}return function(b,e,T,r){if(!(0<=b&&b<=1&&0<=T&&T<=1))throw new Error("bezier x values must be in [0, 1] range");var t=arguments.toString();if(o[t])return o[t];if(b===e&&T===r)return u;for(var A=new(s?Float32Array:Array)(11),n=0;n<11;++n)A[n]=w(.1*n,b,T);return o[t]=function(t){return 0===t?0:1===t?1:w(function(t){for(var e=0,r=1;10!==r&&A[r]<=t;++r)e+=.1;var n=e+(t-A[--r])/(A[r+1]-A[r])*.1,i=P(n,b,T);if(.001<=i){for(var a=t,o=n,s=b,u=T,c=0;c<4;++c){var f=P(o,s,u);if(0===f)return o;o-=(w(o,s,u)-a)/f}return o}if(0===i)return n;for(var h,l,d=t,v=e,g=e+.1,p=b,y=T,m=0;0<(h=w(l=v+(g-v)/2,p,y)-d)?g=l:v=l,1e-7<Math.abs(h)&&++m<10;);return l}(t),e,r)}}}();function getQuadBezierValue(t,e,r,n){var i;return 1<=t?n:(i=1-t)*i*e+2*i*t*r+t*t*n}function cubic(t,e,r,n,i){var a,o,s,u;return 1<=t?i:(a=3*(r.pos[0]-e.pos[0]),o=3*(n.pos[0]-r.pos[0])-a,u=i.pos[0]-e.pos[0]-a-o,s=3*(r.pos[1]-e.pos[1]),n=3*(n.pos[1]-r.pos[1])-s,r=i.pos[1]-e.pos[1]-s-n,i=u*Math.pow(t,3)+o*Math.pow(t,2)+a*t+e.pos[0],u=r*Math.pow(t,3)+n*Math.pow(t,2)+s*t+e.pos[1],ProjectionManager.getProjection("EPSG:3857").unproject(i,u))}function quad(t,e,r,n){return ProjectionManager.getProjection("EPSG:3857").unproject(getQuadBezierValue(t,e.pos[0],r.pos[0],n.pos[0]),getQuadBezierValue(t,e.pos[1],r.pos[1],n.pos[1]))}function p20CoordsToLngLat(t,e){return Array.isArray(e)&&(e=new Pixel(e[0],e[1])),t.containerTolnglat(e,20)}function getSplitNum(t,e){for(var n=[3,300],r=Math.max(2,4),i=0,a=0,o=0,s=t.length;o<s-1;o++){var u=t[o],c=t[o+1];i+=Math.abs(c.pos[0]-u.pos[0]),a+=Math.abs(c.pos[1]-u.pos[1])}return Math.min(n[1],Math.max(n[0],Math.round(Math.max(i,a)/e/r)))}function interpolateCoords(t,e){var r=null;switch(e.length){case 3:r=quad;break;case 4:r=cubic;break;default:return null}for(var n=[],i=[0].concat(e),a=1;a<t-2;a++)i[0]=a/t,n.push(r.apply(null,i));return n.push(e[e.length-1]),n}function getCoordsWithControlPoints(t,e,r,n){var i=null;return t&&r&&r.length&&((t=[t]).push.apply(t,r),t.push(e),i=interpolateCoords(getSplitNum(t,n),t)),i||[e]}var BezierUtil={ag:quad,ug:cubic,sg:easing,xb:function(t,e){for(var r=[],n=0,i=t.length;n<i;n+=1)r.push.apply(r,getCoordsWithControlPoints(t[n-1],t[n],t[n].controlPoints,e));return r},fg:function(t,e,r,n){for(var i=this.xb(t,e,r,n),a=[],o=0,s=i.length;o<s;o++)a.push(p20CoordsToLngLat(e,i[o]));return a}},globalInstance=self,TagMap=(function(t){t.LITE="lite",t.LEFT="left",t.ALL="all",t.NONE=""}(exports.zB||(exports.zB={})),{2:"all",3:"all",4:"all",5:"all",6:"lite",7:"all",8:"lite",9:"all",10:"lite",11:"lite",12:"all",13:"all",14:"all",15:"lite",16:"lite",17:"all",18:"all",19:"all",20:"all"}),colorNameDist={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",grey:"#808080",gray:"#808080",green:"#008000",greenyellow:"#adff2f",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgrey:"#d3d3d3",lightgreen:"#90ee90",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370d8",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#d87093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},Util=function(){var n,o,e,r,i,a,s,u,c,f,t={CLASS_NAME:"AMap.Util",WorldAxesCenter:{x:0,y:0},Single:{},stamp:(e=!0===Browser.DW,r=1e5,i="_amap_id",function(t){return t[i]=e?++r:--r,t[i]}),singlton:function(t){return v.Single[t]||new t},getOptimalZoom:function(t){return t<Math.floor(t)+.8?Math.floor(t):Math.ceil(t)},join:function(t,e){if(t.join)return t.join(e);var r,n=[];for(r in t)t.hasOwnProperty(r)&&n.push(r+"="+(t[r]||""));return n.join(e)},getGuid:function(t,e){return void 0===e&&(e=10),(t||"")+Math.round(Math.random()*Math.pow(10,e))+"_"+(new Date).getTime()},uuid:(o="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz".split(""),function(t,e){var r,a,n=o,i=[];if(e=(e=void 0===e?62:e)||n.length,t=void 0===t?0:t)for(r=0;r<t;r++)i[r]=n[0|Math.random()*e];else for(i[8]=i[13]=i[18]=i[23]="-",i[14]="4",r=0;r<36;r++)i[r]||(a=0|16*Math.random(),i[r]=n[19===r?3&a|8:a]);return i.join("")}),endsWith:function(t,e){return t.endsWith?t.endsWith(e):!(t.length<e.length)&&t.substr(t.length-e.length)===e},mg:[],gg:268435456,wg:[215440491,106744817],Mg:{start:function(e){e.startTime=new Date,e.jg=[];var n=(new Date).getTime();e.id=v.requestAnimFrame(function r(){var t=(new Date).getTime();e.jg.push(t-n),n=t,e.id=v.requestAnimFrame(r)})},cancel:function(t){t.id&&v.cancelAnimFrame(t.id)},stop:function(t){t.Ag=Date.now()-t.startTime,this.cancel(t),t.Mg=Math.round(1e3/(t.Ag/(t.jg.length+1)))}},kg:function(t,e,r,n,i){if(void 0===i&&(i=!1),t===e)return e;switch(n=void 0===n?"linear":n){case"ease":r=BezierUtil.sg(.25,.1,.25,1)(r);break;case"ease-in":r=BezierUtil.sg(.42,0,1,1)(r);break;case"ease-out":r=BezierUtil.sg(0,0,.58,1)(r);break;case"ease-in-out":r=BezierUtil.sg(.42,0,.58,1)(r)}return n=t+(e-t)*r,i&&(n>>=0),n},createObjectURL:function(t,e){void 0===e&&(e="text/javascript; charset=utf-8");var r=null;try{r=(globalInstance.URL||globalInstance.webkitURL).createObjectURL(new Blob([t],{type:e}))}catch(t){r=null}return r},revokeObjectURL:function(t){try{(globalInstance.URL||globalInstance.webkitURL).revokeObjectURL(t)}catch(t){}},Og:function(t){for(var e={},r=0,n=t.length;r<n;r++)e[t[r]]=r;return e},EV:function(t,e){var r=180/(e=Math.pow(2,e));return[Math.floor(t[0]/(360/e))+e/2,e/2-Math.ceil(t[1]/r)]},WY:function(t,e,r){void 0===r&&(r=!1);var n=[t[0],t[3]],t=[t[2],t[1]],n=this.EV(n,e),t=this.EV(t,e),i=n[0],a=n[1],o=t[0],s=t[1];if(r)return{ja:i,Fa:a,Oa:o,Ea:s,z:e};this.Pa={ja:i,Fa:a,Oa:o,Ea:s,z:e};for(var u=[],c=i;c<=o;c+=1)for(var f=a;f<=s;f+=1)u.push([e,c,f]);return u},xg:function(t){var e={};if(v.is(t,"object"))for(var r in t)t.hasOwnProperty(r)&&(e[t[r]]=r);return e},Ig:function(t,e){if(e.length<5e4)t.push.apply(t,e);else for(var r=0,n=e.length;r<n;r+=1)t.push(e[r])},clone:function(t){if("object"!=typeof t||null===t)return t;if(t.Tg||this.is(t,"Float32Array")||this.is(t,"Uint16Array"))return t;var e,r=this.isArray(t)?[]:{};for(e in t)t.hasOwnProperty(e)&&(r[e]=v.clone(t[e]));return r},isInteger:function(t){return(0|t)===t},vB:function(t){return!isNaN(t)},setPrototypeOf:"function"==typeof Object.setPrototypeOf?Object.setPrototypeOf:function(t,e){for(var r in e)t[r]=e[r]},isFunction:function(t){return"function"==typeof t},_g:function(t,e){if(void 0===e&&(e="webgl"),!t)return t;for(var r=[],n=0,i=t.length;n<i;n+=2){var a=parseInt(t.substr(n,2),16);("webgl"===e||"rgba"===e&&0===n)&&(a=this.format(a/255,3)),r.push(a)}return r.push(r.shift()),r},Sg:function(){},keys:"function"==typeof Object.keys?Object.keys:function(t){var e,r=[];for(e in t)t.hasOwnProperty(e)&&r.push(e);return r},map:function(r,n,i){void 0===i&&(i=null);var a=[];return r&&r.length?(v.Cg(r,function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];a[t[1]]=n.apply(i||r,t)}),a):r},forEach:function(t,e){if(t&&t.length){var r=t.length;if(0<r&&(e(t[0],0),1<r)){e(t[1],1);for(var n=2;n<r;n++)e(t[n],n)}}},Cg:function(t,e,r){if(void 0===r&&(r=null),t&&t.length)for(var n=0,i=t.length;n<i&&!1!==e.call(r,t[n],n,t);n++);},find:function(t,e,r){void 0===r&&(r=null);for(var n=0,i=t.length;n<i;n++)if("function"==typeof e){if(e.call(r,t[n],n,t))return t[n]}else if(t[n]===e)return t[n];return null},isDOM:function(t){return"object"==typeof HTMLElement?t instanceof HTMLElement:t&&"object"==typeof t&&1===t.nodeType&&"string"==typeof t.nodeName},Eg:function(t,e){for(var r,n,i="ASDFGHJKLQWERTYUIO!sdfghjkleiu3~yr5-P&mq9`%zCN*b=8@^xpVM",a="v5"<(e=e||"v5")?(r=i.length,512):(i=i.substr(0,r=27),333),o=[],s=NaN,u=0,c=t.length;u<c;u++)n=t[u],n=i.indexOf(n),s=isNaN(s)?n*r:(o.push(s+n-a),NaN);return o},Ng:function(t,e){for(var r=512<e.length?Math.round(Math.pow(e.length,.5)):e.length,n=Math.ceil(e.length/r),i=0;i<n;i+=1){var a=r*i,o=a+r;o>e.length&&(o=e.length);for(var s=a;s<o;s+=1)t(e[s])}},Lg:function(t){var e;return/^rgba\(/.test(t)?this.Dg(t):("#"===(e=t=this.colorNameToHex(t))[0]&&(3===(t=t.substring(1)).length&&(t=t.replace(/./g,function(t){return t+t})),e=this.argbHex2Rgba(8===t.length?t:"ff"+t)),this.Dg(e))},colorNameToHex:function(t){return"string"==typeof(t=(t=void 0===t?"":t).toLowerCase())&&colorNameDist[t]||t},Rg:function(t,e,r){var n=Math.floor(r/2),i=r-n;return[r,t&(n=(1<<n)-1<<i)|e&(i=(1<<i)-1),e&n|t&i]},Pg:function(t){return t?encodeURIComponent(t):""},getStyle:function(t,e,r,n){var i=t[e].i[r];if(void 0===i)return null;if(r=t[e].s,"number"==typeof i)return r[i];for(;void 0===i[n.toString()]&&!(--n<3););return"number"==typeof(t=i[n.toString()])?r[t]:null},Dg:function(t){return(t=t.split(","))[0]=parseFloat(t[0].split("rgba(")[1])/255,t[1]=parseFloat(t[1])/255,t[2]=parseFloat(t[2])/255,t[3]=parseFloat(t[3]),t},Ug:function(t){return(t=t.split(","))[0]=parseFloat(t[0].split("rgb(")[1])/255,t[1]=parseFloat(t[1])/255,t[2]=parseFloat(t[2])/255,t},Bg:function(t){return"rgba("+255*t[0]+","+255*t[1]+","+255*t[2]+","+t[3]+")"},color2Rgba:function(t){return this.Bg(this.color2RgbaArray(t))},color2RgbaArray:function(t){var e,r,n,i,a,o,s;return t instanceof Array?(3==t.length&&t.push(1),t):0==(e=this.colorNameToHex(t)).indexOf("rgb(")?((r=this.Ug(e)).push(1),r):0==e.indexOf("rgba(")?this.Dg(e):0==e.indexOf("#")?4===e.length?(s=e.substr(1).replace(/./g,function(t){return t+t}),this.zg(s)):7==e.length?this.zg(e.substr(1)):9==e.length?(r=e.substr(1),this.qg(r)):void 0:0===e.indexOf("hsla")?(n=t.substr(5).split(","),i=parseInt(n[0],10)/360,a=parseInt(n[1],10)/100,o=parseInt(n[2],10)/100,r=parseFloat(n[3]),this.GQ(i,a,o,r)):0===e.indexOf("hsl")?(n=t.substr(4).split(","),i=parseInt(n[0],10)/360,a=parseInt(n[1],10)/100,o=parseInt(n[2],10)/100,this.GQ(i,a,o,1)):3===e.length?(s=e.replace(/./g,function(t){return t+t}),this.zg(s)):6==e.length?this.zg(e):8==e.length?this.qg(e):void 0},GQ:function(t,e,r,n){var i,a,o;return 0===e?i=a=o=r:(i=this.uQ(e=2*r-(r=r<.5?r*(1+e):r+e-r*e),r,t+1/3),a=this.uQ(e,r,t),o=this.uQ(e,r,t-1/3)),[i,a,o,n]},uQ:function(t,e,r){return r<0&&(r+=1),1<r&&--r,r<1/6?t+6*(e-t)*r:r<.5?e:r<2/3?t+(e-t)*(2/3-r)*6:t},rgbHex2Rgba:function(t){return t.startsWith("#")&&(t=t.slice(1)),v.argbHex2Rgba("ff"+t)},argbHex2Rgba:function(t){for(var e=[],r=0,n=(t=t.startsWith("#")?t.slice(1):t).length;r<n;r+=2)e.push(parseInt(t.substr(r,2),16));return e.push((e.shift()/255).toFixed(2)),"rgba("+e.join(",")+")"},Opacity2Rgba:function(t,e){var r=e;return e&&e[3]&&t&&(e[3]=Math.floor(255*t)),r},Hex2Rgba:function(t){if("string"!=typeof t)return!1;for(var e=[],r=0,n=t.length;r<n;r+=2)e.push(parseInt(t.substr(r,2),16));return e.push(parseInt(e.shift())),e},zg:function(t){return this.uE(t+"ff")},qg:function(t){for(var e=[],r=0,n=t.length;r<n;r+=2)e.push(parseInt(t.substr(r,2),16)/255);return e.push(e.shift()),e},uE:function(t){return[((t=parseInt(t,16))>>24&255)/255,(t>>16&255)/255,(t>>8&255)/255,(255&t)/255]},isEmpty:function(t){for(var e in t)if(t.hasOwnProperty(e))return!1;return!0},Wg:function(t,e){return 0<=e&&t.splice(e,1),t},startsWith:function(t,e){return t.startsWith?t.startsWith(e):t.substr(0,e.length)===e},deleteItemFromArray:function(t,e){return e=v.indexOf(t,e),v.Wg(t,e)},deleteItemFromArrayByIndex:function(t,e){return v.Wg(t,e)},filter:function(t,r,n){var i=[];return v.Cg(t,function(t,e){r.call(n,t,e)&&i.push(t)}),i},indexOf:function(t,e){if(t&&t.length){if(t.indexOf)return t.indexOf(e);for(var r=0;r<t.length;r+=1)if(t[r]===e)return r}return-1},Gg:function(t,e){return t.endsWith?t.endsWith(e):!(t.length<e.length)&&t.substr(t.length-e.length)==e},bind:(n=!1,Boolean(Function.prototype.bind)&&(n=!0),function(t,e){var r=2<arguments.length?Array.prototype.slice.call(arguments,2):null;return n?r?(r.unshift(e),t.bind.apply(t,r)):t.bind(e):function(){return t.apply(e,r||arguments)}}),setOptions:function(t,e){return t.opts=assign({},t.opts,e=e||{}),t.opts},yn:function(t,e,r){return"function"==typeof e?this.Hg(t,!0,this.Vg(e,r,1)):this.Hg(t,!0)},Hg:function(r,n,i,t,e,a,o){var s;if(void 0===(s=i?e?i(r,t,e):i(r):s)){if(!this.$g(r))return r;if(t=this.isArray(r)){if(s=this.Yg(r),!n)return this.Kg(r,s)}else{var u=Object.prototype.toString.call(r),c="[object Function]"==u;if("[object Object]"!=u&&"[object Arguments]"!=u&&(!c||e))return e?r:{};if(s=this.Xg(c?{}:r),!n)return this.baseAssign(s,r)}o=o||[];for(var f=(a=a||[]).length;f--;)if(a[f]==r)return o[f];a.push(r),o.push(s),(t?this.Zg:this.Qg)(r,function(t,e){s[e]=v.Hg(t,n,i,e,r,a,o)})}return s},baseAssign:function(t,e){return null==e?t:this.tM(e,Object.keys(e),t)},$g:function(t){var e=typeof t;return!!t&&("object"==e||"function"==e)},rM:function(t){return!!t&&"object"==typeof t},nM:function(t){return"number"==typeof t&&-1<t&&t%1==0&&t<=9007199254740991},Yg:function(t){var e=t.length,r=new Array(e);return e&&"string"==typeof t[0]&&Object.hasOwnProperty.call(t,"index")&&(r.index=t.index,r.input=t.input),r},Kg:function(t,e){var r=-1,n=t.length;for(e=e||Array(n);++r<n;)e[r]=t[r];return e},Xg:function(t){return new(t="function"==typeof(t=t.constructor)&&t instanceof t?t:Object)},Vg:function(a,o,t){if("function"!=typeof a)return this.identity;if(void 0===o)return a;switch(t){case 1:return function(t){return a.call(o,t)};case 3:return function(t,e,r){return a.call(o,t,e,r)};case 4:return function(t,e,r,n){return a.call(o,t,e,r,n)};case 5:return function(t,e,r,n,i){return a.call(o,t,e,r,n,i)}}return function(){return a.apply(o,arguments)}},Zg:function(t,e){for(var r=-1,n=t.length;++r<n&&!1!==e(t[r],r,t););return t},identity:function(t){return t},iM:function(u){return function(t,e,r){for(var n=v.eM(t),i=r(t),a=i.length,o=u?a:-1;u?o--:++o<a;){var s=i[o];if(!1===e(n[s],s,n))break}return t}},Qg:function(t,e){return v.iM()(t,e,Object.keys)},eM:function(t){return v.$g(t)?t:Object(t)},tM:function(t,e,r){r=r||{};for(var n=-1,i=e.length;++n<i;){var a=e[n];r[a]=t[a]}return r},oM:function(){return!1},aM:"data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=",uM:Date.now?function(){return Date.now()}:function(){return(new Date).getTime()},sM:function(t,e,r,n){var i,a,o,s,u,c,f;return s=n?(i=0,o=this.uM,function(){if((a=o())-i<e)return!1;i=a,t.apply(r,arguments)}):(f=function(){u=!1,c&&(s.apply(r,c),c=!1)},function(){u?c=arguments:(u=!0,t.apply(r,arguments),setTimeout(f,e))})},format:function(t,e){return t===t<<0?t:+parseFloat(t+"").toFixed(e||0)},isArray:Array.isArray||function(t){return this.is(t,"array")},is:function(t,e){return Object.prototype.toString.call(t).split(" ")[1].slice(0,-1).toLowerCase()===e.toLowerCase()},includes:"function"==typeof Array.prototype.includes?function(t,e){return t.includes(e)}:function(t,e){return-1!==this.indexOf(t,e)},fM:function(t){var e=0;if(0!==t.length)for(var r=0,n=t.length;r<n;r+=1)e=(e<<5)-e+t.charCodeAt(r),e&=e;return e},hM:function(t,e){e=e?Math.ceil(parseInt(e.substr(6))/24):1;for(var r="",n=0,i=t.length;n<i;n++)r+=String.fromCharCode((t.charCodeAt(n)-256-e+65535)%65535);return r},cM:function(t,e){var r=(t+"").slice(-2),n=(e+"").slice(-2),i=(t=t.slice(0,-2),e=e.slice(0,-2),parseInt((n+r).slice(1))),a=Math.ceil(i/250)%2?1:-1,i=1<i/500?1:-1;return t-=parseInt("1"+r)/3e3*a,e-=parseInt("1"+n)/3e3*i,new LngLat$2(parseFloat(t).toFixed(5),parseFloat(e).toFixed(5))},vM:function(t){return"undefined"!=typeof JSON&&JSON.stringify?v.fM(JSON.stringify(t)):null},lM:function(t,e){var r="_amap_hash";return!e&&t.hasOwnProperty(r)||(e=v.vM(t))&&(t[r]=e),t[r]},parseLngLatData:function(t){if(v.isArray(t)){var e;if(!v.isArray(t[0]))return"string"==(e=typeof t[0])||"number"==e?new LngLat$2(t[0],t[1]):t;for(var r=0;r<t.length;r+=1)t[r]=v.parseLngLatData(t[r])}return t},dM:function(t){for(var e=[],r=0,n=t.length;r<n;r+=1)e[r]=[t[r].x,t[r].y];return e},bM:function(t){return v.isArray(t)?new Size(t[0],t[1]):t},hp:function(t,e){var r,n=[0,0],i=v.getOptimalZoom(e.viewState.zoom);return t&&LocalZoom<=i?(i=lcs.getSize(),e=e.viewState.centerCoord,e=lcs.getLocalByCoord([e[0],e[1]]),r=t.x-e.x,e=t.y-e.y,0!=r&&(r*=i[0],n[0]=r),0!=e&&(e*=i[1],n[1]=e)):t&&(n[0]+=t.center[0],n[1]+=t.center[1]),n},dS:function(t,e){return t>=e[0]&&t<=e[1]},kD:function(t,e,r){return void 0===r&&(r=!1),t=(t=void 0===t?"":t).split(",")[0]||"",!r&&t&&e&&TagMap[e]||"all"},VF:function(t,e,r){return!(r=void 0!==r&&r)&&t&&e&&TagMap[e]||"all"},LD:function(t,e){return!(!t||!e)&&(t=this.iN(t),this.iN(e)<=t)},SD:function(t){var e;switch(t=void 0===t?"all":t){case"lite":e=0;break;case"left":e=1;break;default:e=2}return e},pW:function(t){var e;switch(t=void 0===t?2:t){case 0:e=exports.zB.LITE;break;case 1:e=exports.zB.LEFT;break;default:e=exports.zB.ALL}return e},iN:function(t){var e=0;switch(t){case"lite":e=0;break;case"left":e=1;break;case"all":e=2}return e},loadBaxia:function(){return new Promise(function(t,e){var r,n;window||e({code:"0",I8t:"霸下加载失败"}),window.__AMap_web_baxia__?t({code:"2",I8t:"霸下已加载,无需重复加载"}):(window.__AMap_web_baxia__=!0,r=document.body||document.head,(n=document.createElement("script")).type="text/javascript",n.src="//g.alicdn.com/??AWSC/AWSC/awsc.js,sd/baxia-entry/baxiaCommon.js",n.onerror=function(t){window.__AMap_web_baxia__=!1,e({code:"0",I8t:"霸下加载失败"})},n.onload=function(){t({code:"1",I8t:"霸下加载成功"})},r.appendChild(n))})},getMarkUrl:function(){return"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAQAAAAEABAMAAACuXLVVAAAAGFBMVEUAAABOVWNOVWVNVWJOVWNNVV9OVWNOVWT0TI68AAAACHRSTlMAIwkPFQQbHt8aTjEAAAVJSURBVHja7MGBAAAAAICg/akXqQIAAAAAAAAAYHbqXrlNIArD8MvCipbD8tOCoyQtZCzSQpKx2sX2xC1IdtSyiSLffpyZ3AKoCE9zyvNW32q1Wq1Wq9VqtVqt/lPvKq7H8jDKxNUEUShZE3ElFj8OvrK5VkATobNnd60A1UnLXrKyvUaAqh4l206cnN2k4cDigqj/ud8MMB5V3rcsSxcoc2P6zz8qRF5qV7AkfesitpLWjUiLGBPIogFbJ5eYWrYu/xK0KkutloTF+KPITiVQPxr7sGcTGwLjEstCNtmurMigvPzai9hwyigHXwbmd4O6s36MdxwFysTLdid0MWqx+BXzc43kVif3nWRj4UukX+8NUH8wLEFvRQzg/p6+DZ5jynwC+m8tC9g6OT6m76A73hv6CW3QIpeBoGAJ9XG030UKyop8LylceDK3PwZm58eqAChf5Vy29Ie95N8MdP5C++NNYWKhkfPNIRwIJR8LEpR7+s0i6kp3BrrdnXKXiMDYvuIVlWhm93AH5OjPMlDfGNWdY4KUcPiYg2Vuai85BPHWyfNA/zkTKRKClCDqX5idaiT/UkApkhRAKO6T154IIlTF/AKRceKEestANRVBWvNxqm04MTtVgH8sglQn8NXqRmRAxf0oB2eXWH1vwLIpfBPE/zbwQwRJ+FyEv5idP+Ad9oYno5NwAuRc4MdwAjTz840qRQ5oVzn1vqkYAZVAbZmftiiR8VxWsBm6W5GWrkDtc7hnfltX+SLHrvIq4NbJuYBy10juWMC78e2hGie61Gt5GMX9BvAk/2ots3t7mI0FBOn2NfNa6my3iQA2iWUBWuQnZQu+yEvdVdyDHwNL7F7QPrzwKZzwJlB5E22kAFAJS7D8Yb/eldMGwiiO/9GNlk+rSytxS4uMZVqJxFa7IDtutcaOW+Tg8PoJSV5BotHvBfbM7MyePc8ib+CEeOG8ILJDV+65iOiBFVQSJAuwFEuRhrOrLPmXYEoPHHWaRkaBGxuJczAEY38jCd3TuGtGTW3i8Ad1KVF+BgznrOnl3bPVbRtQLsrNjW/IolZTajg/imj6MJdoC7/S8vEkr+zJ/v65iUY/X+jBzMTbfaXZlzs5LeafXALsGizl0r154cZf91VsVnC28z9h7qFMGE/gic7NjEzQSzk8ZQ2W1EZUXUALTkj3ls/x9tGHdDVvT4n25O4wi5wAOwCXHhjPvxMFIwnymSnGm+abP19nxSikczXgBracFhE4eW2i6ug6E3Xi3Uq6L50nsluDF1rBzERQV/F274TYvl8aRffcoDZy0OnWlz8n31+G/oNMFW4UOl813atF2k+N7UzW++pS/rkc0iKAX/Tii0jurAMYNXcSmJkeFdHMfESwoGtzgGW+1OOm1GTHHze1kcSbmHibKnpQ6noLh13hTJYvtKFVSdtghzONpelB+i4KTMyjyIsdqDbOx0csRQ+m/3c24MU7kQS3iaby5k3gJ93bxNDG1QSgLL/l0gCG+sP0M7I38QrW2vatB8VpFCIBkCXwSvdGr2ez4gmw4ssl6DJwg/IFdiv64Jgoz/ZVgHsrojRY6t1Wjnzg9RVgM01FEoy8S5zArsm+hCx9+mJKSd8yzW2ya6so4VlnbQGavrTt56ZIV0CZFplsceRMnxbfRVbOCiw1Probhffh0qc7UenMHGE3cUJI6Nvr4lTFDyFum1iKa1jKQS8VngLFNaTF3EQBbsGVjCS62QvX4/mX4tdcjR3LIdFcjxsnXFfOYDAYDAaDwWAwGAwGg9/twYEAAAAAgCB/60GuAAAAAAAAAOAnLYvrtEzzqQMAAAAASUVORK5CYII="}};function h(t){var e=+new Date,r=Math.max(0,(Browser.android?50:20)-(e-a));return a=e+r,globalInstance.setTimeout(t,50)}function l(t){globalInstance.clearTimeout(t)}function d(t){for(var e,r=["webkit","moz","o","ms"],n=0;n<r.length&&!e;n+=1)e=globalInstance[r[n]+t];return e}a=0,Browser.DW?(s=h,u=l,t.requestAnimFrame=function(t,e,r,n){if(!r)return s(function(){e?v.bind(t,e).call(e,n):t()});e?v.bind(t,e).call(e,n):t()},t.cancelAnimFrame=function(t){t&&u.call(globalInstance,t)}):(c=globalInstance.requestAnimationFrame||d("RequestAnimationFrame")||h,f=globalInstance.cancelAnimationFrame||d("CancelAnimationFrame")||d("CancelRequestAnimationFrame")||l,t.requestAnimFrame=function(t,e,r,n){if(!r)return c(function(){e?v.bind(t,e).call(e,n):t()});e?v.bind(t,e).call(e,n):t()},t.cancelAnimFrame=function(t){t&&f.call(globalInstance,t)}),Browser.DW||(t.requestIdleCallback=globalInstance.requestIdleCallback?function(t,e){return globalInstance.requestIdleCallback(t,e)}:function(t,e){void 0===e&&(e={});var r=v.uM();return setTimeout(function(){t({didTimeout:!1,timeRemaining:function(){return Math.max(0,70-(v.uM()-r))}})},e.timeout||0)},t.cancelIdleCallback=globalInstance.cancelIdleCallback?function(t){return globalInstance.cancelIdleCallback(t)}:function(t){clearTimeout(t)});var v=t;return v}(),extendStatics=function(t,e){return(extendStatics=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])}))(t,e)};function __extends(t,e){function r(){this.constructor=t}extendStatics(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)}function __decorate(t,e,r,n){var i,a=arguments.length,o=a<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.yV)o=Reflect.yV(t,e,r,n);else for(var s=t.length-1;0<=s;s--)(i=t[s])&&(o=(a<3?i(o):3<a?i(e,r,o):i(e,r))||o);return 3<a&&o&&Object.defineProperty(e,r,o),o}function __awaiter(t,o,s,u){return new(s=s||Promise)(function(r,e){function n(t){try{a(u.next(t))}catch(t){e(t)}}function i(t){try{a(u.throw(t))}catch(t){e(t)}}function a(t){var e;t.done?r(t.value):((e=t.value)instanceof s?e:new s(function(t){t(e)})).then(n,i)}a((u=u.apply(t,o||[])).next())})}function __generator(n,i){var a,o,s,u={label:0,y8t:function(){if(1&s[0])throw s[1];return s[1]},m8t:[],b8t:[]},t={next:e(0),throw:e(1),return:e(2)};return"function"==typeof Symbol&&(t[Symbol.iterator]=function(){return this}),t;function e(r){return function(t){var e=[r,t];if(a)throw new TypeError("Generator is already executing.");for(;u;)try{if(a=1,o&&(s=2&e[0]?o.return:e[0]?o.throw||((s=o.return)&&s.call(o),0):o.next)&&!(s=s.call(o,e[1])).done)return s;switch(o=0,(e=s?[2&e[0],s.value]:e)[0]){case 0:case 1:s=e;break;case 4:return u.label++,{value:e[1],done:!1};case 5:u.label++,o=e[1],e=[0];continue;case 7:e=u.b8t.pop(),u.m8t.pop();continue;default:if(!(s=0<(s=u.m8t).length&&s[s.length-1])&&(6===e[0]||2===e[0])){u=0;continue}if(3===e[0]&&(!s||e[1]>s[0]&&e[1]<s[3]))u.label=e[1];else if(6===e[0]&&u.label<s[1])u.label=s[1],s=e;else{if(!(s&&u.label<s[2])){s[2]&&u.b8t.pop(),u.m8t.pop();continue}u.label=s[2],u.b8t.push(e)}}e=i.call(n,u)}catch(t){e=[6,t],o=0}finally{a=s=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}}}function __spreadArrays(){for(var t=0,e=0,r=arguments.length;e<r;e++)t+=arguments[e].length;for(var n=Array(t),i=0,e=0;e<r;e++)for(var a=arguments[e],o=0,s=a.length;o<s;o++,i++)n[i]=a[o];return n}exports.Ln=function(){return exports.Ln=Object.assign||function(t){for(var e,r=1,n=arguments.length;r<n;r++)for(var i in e=arguments[r])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},exports.Ln.apply(this,arguments)};var LabelFormat=function(){function t(){this.Fs={},this.Es={},this.Ts=[]}return t.prototype.Ns=function(t,e){e.lang&&(this.lang=e.lang)},t.prototype.rV=function(t,e){return t},t.prototype.Ws=function(t,e){for(var r=this.Es,t=labelsUtil.EQ(t=void 0===t?"":t,e=void 0===e?[]:e),n=labelsUtil.aQ(t),i=0;i<n.length;i++)r[n[i]]=1},t.id="labelFormat",t}();function noop$1(){}var URLObject="undefined"!=typeof window?window.URL||window.webkitURL||{createObjectURL:function(){console.error("URL not exist, please use more popular browser")}}:URL||webkitURL||{createObjectURL:function(){console.error("URL not exist, please use more popular browser")}},MockMap=function(){function t(){this.gV={}}return t.prototype.has=function(t){return Boolean(this.gV[t])},t.prototype.set=function(t,e){return this.gV[t]=e},t.prototype.get=function(t){return this.gV[t]},t.prototype.pV=function(t){delete this.gV[t]},t.prototype.clear=function(){this.gV={}},t.prototype.forEach=function(t){for(var e in this.gV)this.gV.hasOwnProperty(e)&&t(this.gV[e])},t}(),AdaptorMap=globalInstance.Map||MockMap,SmartTypedArray=function(){function t(t,e){void 0===e&&(e=1024),this.type=t,this.length=0,this.uf=0,this.value=this.cf(e)}return t.prototype.set=function(t){this.check(t)&&(t.length<this.uf?this.value.set(t):(this.cf(t.length),this.value.set(t),this.length=t.length))},t.prototype.check=function(t){if(Array.isArray(t))return!0;var e=!1;switch(this.type){case"uint8":e=t instanceof Uint8Array;break;case"int8":e=t instanceof Int8Array;break;case"uint16":e=t instanceof Uint16Array;break;case"int16":e=t instanceof Int16Array;break;case"uint32":e=t instanceof Uint32Array;break;case"int32":e=t instanceof Int32Array;break;case"float32":e=t instanceof Float32Array;break;case"float64":e=t instanceof Float64Array;break;default:e=!1}return e},t.prototype.subarray=function(t,e){return this.value.subarray(t,e)},t.prototype.ff=function(t){this.uf<t&&this.cf(t),this.length=t},t.prototype.cf=function(t){var e=this.pf(),r=this.value;return this.value=new e(t),r&&this.value.set(r),this.uf=t,this.value},t.prototype.pf=function(){var t=Float32Array;switch(this.type){case"uint8":t=Uint8Array;break;case"int8":t=Int8Array;break;case"uint16":t=Uint16Array;break;case"int16":t=Int16Array;break;case"uint32":t=Uint32Array;break;case"int32":t=Int32Array;break;case"float32":t=Float32Array;break;case"float64":t=Float64Array;break;default:t=Float32Array}return t},__decorate([InnerClass("SmartTypedArray")],t)}(),INF=(function(t){t[t.fontWidth=0]="fontWidth",t[t.fontHeight=1]="fontHeight",t[t.horiBearingX=2]="horiBearingX",t[t.horiBearingY=3]="horiBearingY",t[t.horiAdvance=4]="horiAdvance",t[t.posX=5]="posX",t[t.posY=6]="posY",t[t.iconWidth=7]="iconWidth",t[t.iconHeight=8]="iconHeight"}(exports.dY||(exports.dY={})),1e20),ControlChars=[[0,31],[127,159]],ZeroWidthChars=[[8203,8207]],f=new SmartTypedArray("float64",4096),d=new SmartTypedArray("float64",4096),z=new SmartTypedArray("float64",4096),v=new SmartTypedArray("float64",4096),ua=navigator.userAgent,TinySDF=function(){function t(t,e,r,n,i,a,o){this.fontSize=t||24,this.buffer=void 0===r?3:r,this.MU=i||.25,this.fontFamily=a||"sans-serif",this.fontWeight=o||"lighter",this.radius=n||8,this.size=e,this.xU(),t=e[0]*e[1],this.TU=new SmartTypedArray("float64",t),this.AU=new SmartTypedArray("float64",t),r=0<=ua.indexOf("Gecko/")||0<=ua.indexOf("Windows"),this.wU=Math.round(e[1]/2*(r?1.2:1))}return t.prototype.bU=function(t){this.size=t||[],this.xU(),this.mU()},t.prototype.Ce=function(t){var e=this.size,r=e[0],n=r*(e=e[1]);if(i=this.Nz){i.clearRect(0,0,r,e),i.fillText(t,this.buffer,this.wU);var a=i.getImageData(0,0,r,e),o=new Uint8ClampedArray(n),s=((i=new Array(9).fill(0))[0]=1,i[1]=1,t.charCodeAt(0));if(this.RU(s))return{bitmap:o,info:i};for(var u=INF,c=INF,f=0,h=0,l=0;l<n;l++){var d,v=l-(d=Math.floor(l/r))*r,g=a.data[4*l+3]/255;0<g&&(d<u&&(u=d),v<c&&(c=v),f<d&&(f=d),h<v)&&(h=v),this.TU.value[l]=1==g?0:0==g?INF:Math.pow(Math.max(0,.5-g),2),this.AU.value[l]=1==g?INF:0==g?0:Math.pow(Math.max(0,g-.5),2)}var i=this.buffer,t=this.getWidth(t,h-c),s=32===s?[6,6,0,-21,9,0,0,r,e]:[t,f-u,c,-u+i,t,c-3,u-3,r,e];for(edt(this.TU.value,r,e),edt(this.AU.value,r,e),l=0;l<n;l++){var y=this.TU.value[l]-this.AU.value[l],y=Math.max(0,Math.min(255,Math.round(255-255*(y/this.radius+this.MU))));o[l]=y}return{bitmap:o,info:s}}return{}},t.prototype.getWidth=function(t,e){var r;switch(t){case"y":case"A":case"T":case"V":case"W":case"Y":r=e;break;default:r=e+2}return r},t.prototype.measureText=function(t){return this.Nz.measureText(t)},t.prototype.xU=function(){var t=this.size;this.canvas||(this.canvas=document.createElement("canvas")),this.canvas.width=t[0],this.canvas.height=t[1],this.Nz=this.canvas.getContext("2d"),this.Nz&&(this.Nz.font=this.fontWeight+" "+this.fontSize+"px "+this.fontFamily,this.Nz.textBaseline="middle",this.Nz.fillStyle="black")},t.prototype.mU=function(){var t=this.size,e=((e=t[0]*(t=t[1]))>this.AU.uf&&(this.AU.ff(e),this.TU.ff(e)),0<=ua.indexOf("Gecko/")||0<=ua.indexOf("Windows"));this.wU=Math.round(t/2*(e?1.2:1))},t.prototype.RU=function(t){var e=this.SU(t,ControlChars),t=this.SU(t,ZeroWidthChars);return e||t},t.prototype.SU=function(t,e){for(var r=0,n=e;r<n.length;r++){var i=n[r];if(t>=i[0]&&t<=i[1])return!0}},t}();function expandTypeArray(t){f.ff(t),d.ff(t),z.ff(t),v.ff(t)}function edt(t,e,r){f.uf<r&&expandTypeArray(r);for(var n=0;n<e;n++){for(var i=0;i<r;i++)f.value[i]=t[i*e+n];for(edt1d(f.value,d.value,v.value,z.value,r),i=0;i<r;i++)t[i*e+n]=d.value[i]}for(f.uf<e&&expandTypeArray(r),i=0;i<r;i++){for(n=0;n<e;n++)f.value[n]=t[i*e+n];for(edt1d(f.value,d.value,v.value,z.value,e),n=0;n<e;n++)t[i*e+n]=Math.sqrt(d.value[n])}}function edt1d(t,e,r,n,i){n[r[0]=0]=-INF,n[1]=+INF;for(var a=1,o=0;a<i;a++){for(var s=(t[a]+a*a-(t[r[o]]+r[o]*r[o]))/(2*a-2*r[o]);s<=n[o];)o--,s=(t[a]+a*a-(t[r[o]]+r[o]*r[o]))/(2*a-2*r[o]);r[++o]=a,n[o]=s,n[o+1]=+INF}for(o=a=0;a<i;a++){for(;n[o+1]<a;)o++;e[a]=(a-r[o])*(a-r[o])+t[r[o]]}}var LangConf={ch:{type:"ch",size:[32,32],fontSize:24,name:"中文简体"},en:{type:"en",size:[32,32],fontSize:24,name:"英文"},th:{type:"th",size:[32,32],fontSize:24,name:"泰语"},my:{type:"my",size:[56,56],fontSize:24,name:"缅甸语"},ja:{type:"ja",size:[32,32],fontSize:24,name:"日文"},km:{type:"km",size:[40,40],fontSize:24,name:"高棉语"},PU:{type:"lao",size:[40,40],fontSize:24,name:"老挝语"},$U:{type:"arabic",size:[40,40],fontSize:24,name:"阿拉伯语"},default:{type:"ch",size:[32,32],fontSize:24,name:"汉语"}},Lang=function(){function t(t){var e=(t=this.CU=t).type,r=t.size,t=t.fontSize,e=(this.type=e,this.width=r[0]),r=this.height=r[1];this.NU=new TinySDF(t,[e,r],(e-t)/2,8,.25,"PingFang SC","normal")}return t.prototype.Ce=function(t){return this.type===LangConf.PU.type?(this.width=10*Math.floor(this.NU.measureText(t).width/10)+10+LangConf.PU.fontSize/2,this.NU.bU([this.width,this.height])):(this.type===LangConf.my.type||this.type===LangConf.PU.type||this.type===LangConf.th.type||this.type===LangConf.$U.type||this.type===LangConf.km.type)&&1<t.length&&(this.width=Math.floor(this.CU.size[0]*t.length*.5),this.NU.bU([this.width,this.height])),this.NU.Ce(t)},t}(),LangManager=function(){function n(){this.OU={}}return n.gG=function(t){return t=t.split("|"),t=parseInt(t[0],10),this.IU(t)},n.kU=function(t){for(var e=[],r=0;r<t.length;r++)e.push(t.charCodeAt(r));return n.gG(e.join("|"))},n.LU=function(t){return t=n.kU(t),-1!==n.EU.indexOf(t)},n.IU=function(t){return 32<t&&t<591?"en":4096<=t&&t<=4255?"my":3584<=t&&t<=3711?"th":6016<=t&&t<=6143?"km":3712<=t&&t<=3839?"lao":1536<=t&&t<=1791?"arabic":"ch"},n.prototype.D$=function(t){var e,r=this.OU[t=void 0===t?"ch":t];return r||(e=LangConf[t]||LangConf.default,r=new Lang(e),this.OU[t]=r),r},n.EU=[LangConf.my.type,LangConf.km.type,LangConf.PU.type],n}(),CHN=[["90.398619","47.62125"],["90.493569","47.512157"],["90.491338","47.430787"],["90.552986","47.391174"],["90.522859","47.318461"],["90.584915","47.224989"],["90.782025","47.019194"],["90.923517","46.97996"],["90.986624","46.807403"],["91.082926","46.722064"],["91.051812","46.596604"],["91.100242","46.564068"],["91.102624","46.537196"],["90.935125","46.300398"],["91.032801","46.126363"],["91.055181","46.011658"],["90.741148","45.713536"],["90.699563","45.544726"],["90.700228","45.504993"],["90.795887","45.449956"],["90.832257","45.31629"],["90.919719","45.26871"],["90.920899","45.225065"],["91.136978","45.244316"],["91.253943","45.164928"],["91.372068","45.142003"],["91.45689","45.18485"],["91.624753","45.098124"],["92.062061","45.11548"],["92.497694","45.030848"],["92.887666","45.075869"],["93.513157","44.997233"],["94.22699","44.694971"],["94.374082","44.542037"],["94.620202","44.47394"],["94.737532","44.366876"],["95.002041","44.282908"],["95.42701","44.324539"],["95.440292","44.292217"],["95.365491","44.054053"],["95.549126","44.026335"],["95.883651","43.431746"],["95.911953","43.287656"],["96.385653","42.919774"],["96.41151","42.75927"],["97.176454","42.824161"],["98.198333","42.682435"],["99.505985","42.597497"],["99.964106","42.676693"],["100.259793","42.666107"],["100.320604","42.718863"],["100.867753","42.700052"],["101.814637","42.530852"],["102.090733","42.250567"],["102.451458","42.173439"],["102.716911","42.181644"],["103.426452","41.910629"],["103.858223","41.830321"],["104.537873","41.903108"],["104.55755","41.881352"],["104.554117","41.69046"],["104.929798","41.682608"],["105.010371","41.620463"],["105.220141","41.778353"],["105.732529","41.977008"],["106.776853","42.319288"],["107.167833","42.354897"],["107.458928","42.487147"],["107.937949","42.433308"],["108.241189","42.489425"],["108.84269","42.425722"],["109.022141","42.487574"],["109.290662","42.465227"],["109.534657","42.500548"],["109.723763","42.60669"],["110.100045","42.671172"],["110.420666","42.80617"],["111.005001","43.354829"],["111.446257","43.521761"],["111.555004","43.519925"],["111.780481","43.697712"],["111.925235","43.719055"],["111.936243","43.796237"],["111.863286","43.902314"],["111.643689","44.039247"],["111.386948","44.360034"],["111.610923","44.793044"],["111.742544","44.988614"],["111.9942","45.118751"],["112.435906","45.103062"],["112.61512","44.956037"],["112.806373","44.882816"],["113.624854","44.775834"],["113.896701","44.9424"],["114.104283","44.984106"],["114.437113","45.233044"],["114.543629","45.41585"],["114.742713","45.46746"],["114.977202","45.40645"],["115.36123","45.421513"],["115.688202","45.487095"],["116.023886","45.712008"],["116.163919","45.717567"],["116.251037","45.785617"],["116.213851","45.874652"],["116.246574","45.98171"],["116.56904","46.316673"],["116.83033","46.413023"],["117.353361","46.390324"],["117.41533","46.528251"],["117.39222","46.582448"],["117.411768","46.610108"],["117.618878","46.628442"],["117.72387","46.549579"],["118.312433","46.768455"],["118.774374","46.71799"],["118.828619","46.795917"],["118.912926","46.804113"],["118.941979","46.764971"],["119.028625","46.769292"],["119.119864","46.669494"],["119.724391","46.623078"],["119.791059","46.707882"],["119.884572","46.701717"],["119.896224","46.880494"],["119.836485","46.899381"],["119.742007","47.13776"],["119.30249","47.404711"],["119.315214","47.461827"],["119.134262","47.517476"],["119.10804","47.64174"],["118.755577","47.747779"],["118.55396","47.96464"],["118.177657","48.02096"],["117.82558","47.987997"],["117.388809","47.612384"],["117.082887","47.796869"],["116.816533","47.867783"],["116.452289","47.808327"],["116.270714","47.845797"],["115.938377","47.653883"],["115.559971","47.900966"],["115.500727","48.161305"],["115.791907","48.279437"],["115.776629","48.537807"],["116.042275","48.826715"],["116.024444","48.890046"],["116.709459","49.880215"],["117.07866","49.723328"],["117.482128","49.648667"],["117.801998","49.554185"],["117.858689","49.620567"],["118.068073","49.643304"],["118.210831","49.759243"],["118.358674","49.80286"],["118.37378","49.853853"],["118.468623","49.857768"],["118.559926","49.957101"],["119.082034","50.01451"],["119.311051","50.169532"],["119.328389","50.327724"],["119.175332","50.320094"],["119.103534","50.373674"],["119.103642","50.409488"],["119.224019","50.469114"],["119.262214","50.625767"],["119.470096","50.763554"],["119.480245","50.910299"],["119.734497","51.106944"],["119.73542","51.228925"],["119.789064","51.243368"],["119.787948","51.298691"],["119.896417","51.365189"],["119.889615","51.410731"],["119.950318","51.426267"],["120.067241","51.699773"],["120.632029","51.963004"],["120.755196","52.16206"],["120.733974","52.23734"],["120.60276","52.318868"],["120.688398","52.529211"],["120.459208","52.615218"],["120.046556","52.554881"],["120.004778","52.785297"],["120.275145","52.889292"],["120.877526","53.323248"],["121.231921","53.310391"],["122.338707","53.534212"],["122.443142","53.474191"],["122.84101","53.486577"],["123.278553","53.592823"],["123.480492","53.533829"],["123.518364","53.587614"],["123.901491","53.509565"],["124.129157","53.379309"],["124.260864","53.404185"],["124.447374","53.252351"],["124.696798","53.233398"],["124.854212","53.143501"],["124.877429","53.19179"],["125.14374","53.233437"],["125.500989","53.129213"],["125.53472","53.084642"],["125.631731","53.108131"],["125.776978","53.000452"],["125.732839","52.906456"],["125.842016","52.927481"],["125.973551","52.795444"],["126.049747","52.829373"],["126.137295","52.788424"],["126.136093","52.7501"],["126.082878","52.727183"],["126.094744","52.66376"],["126.01078","52.632295"],["126.225078","52.557751"],["126.227546","52.502887"],["126.28664","52.498733"],["126.378071","52.405299"],["126.365626","52.334723"],["126.460233","52.313556"],["126.457937","52.278438"],["126.370797","52.21752"],["126.587327","52.146539"],["126.544647","52.022831"],["126.483493","52.004144"],["126.489866","51.963387"],["126.757379","51.72942"],["126.769931","51.638237"],["126.737959","51.604012"],["126.870396","51.541384"],["126.8313","51.449554"],["126.939726","51.411373"],["126.952021","51.35238"],["127.007918","51.339647"],["126.930671","51.194554"],["126.950047","51.077214"],["127.328668","50.761993"],["127.324612","50.674039"],["127.399564","50.585975"],["127.336199","50.480736"],["127.39435","50.441709"],["127.374866","50.346296"],["127.622938","50.242265"],["127.624762","50.159938"],["127.524126","50.053819"],["127.569466","49.832087"],["127.686474","49.798414"],["127.716987","49.69577"],["127.838395","49.617717"],["128.185065","49.56898"],["128.533065","49.633229"],["128.791094","49.618148"],["128.84167","49.562161"],["128.811865","49.506248"],["129.022107","49.485245"],["129.11165","49.389985"],["129.230032","49.429552"],["129.343135","49.392234"],["129.383497","49.461849"],["129.526126","49.451932"],["129.593332","49.316758"],["129.745059","49.313625"],["129.972146","49.057136"],["130.243692","48.89923"],["130.444579","48.939218"],["130.526934","48.889044"],["130.693552","48.907086"],["130.705612","48.869994"],["130.580449","48.630526"],["130.630317","48.609845"],["130.648105","48.52472"],["130.790884","48.525345"],["130.778868","48.413864"],["130.875106","48.300724"],["130.708423","48.108792"],["130.914073","47.945556"],["131.01546","47.736076"],["131.552374","47.750448"],["131.621768","47.692216"],["131.711934","47.740348"],["131.958075","47.703033"],["131.995368","47.741041"],["132.235458","47.739381"],["132.340472","47.796162"],["132.546873","47.750881"],["132.655685","47.89209"],["132.654505","47.979308"],["132.811511","47.967327"],["133.097413","48.158185"],["133.473394","48.128346"],["133.728504","48.281365"],["134.199908","48.411499"],["134.519091","48.448618"],["134.797053","48.402511"],["134.903462","48.476549"],["135.111473","48.465979"],["135.087461","48.366044"],["134.70854","48.235879"],["134.705815","48.142967"],["134.587133","47.991745"],["134.802439","47.732613"],["134.805079","47.701502"],["134.584837","47.454022"],["134.327302","47.405829"],["134.203448","47.309543"],["134.189801","47.25835"],["134.258273","47.190339"],["134.25029","47.096963"],["134.160018","47.066453"],["134.091868","46.968583"],["134.042215","46.633997"],["133.892806","46.477753"],["133.978872","46.404235"],["133.938468","46.35728"],["133.943124","46.251663"],["133.734856","46.143924"],["133.77584","46.068467"],["133.698828","45.924364"],["133.509421","45.823745"],["133.533154","45.779212"],["133.488886","45.719859"],["133.513906","45.69461"],["133.496869","45.599732"],["133.229721","45.489276"],["133.168674","45.414886"],["133.124621","45.258199"],["133.158975","45.105773"],["132.946351","44.989767"],["131.996377","45.226214"],["131.893723","45.301592"],["131.80903","45.186922"],["131.72307","45.208468"],["131.688416","45.166214"],["131.716461","45.107939"],["131.507506","44.942491"],["131.131804","44.90387"],["131.021662","44.839439"],["131.137726","44.723122"],["131.338398","44.056058"],["131.273661","43.974086"],["131.248341","43.566337"],["131.344342","43.514183"],["131.346252","43.391702"],["131.236002","43.22857"],["131.242955","43.131057"],["131.13749","43.018486"],["131.168904","42.923466"],["131.065779","42.901952"],["131.05005","42.834641"],["130.673962","42.819219"],["130.46123","42.731347"],["130.617421","42.685874"],["130.650616","42.595365"],["130.604267","42.509264"],["130.661752","42.412289"],["130.553477","42.421191"],["130.507536","42.571366"],["130.42958","42.523293"],["130.416105","42.590452"],["130.235238","42.692151"],["130.237405","42.873951"],["130.125611","42.876169"],["130.075765","42.911319"],["130.092008","42.956423"],["129.933178","42.975108"],["129.878311","42.92378"],["129.795163","42.719399"],["129.815032","42.601778"],["129.735103","42.411401"],["129.607751","42.418118"],["129.55415","42.330996"],["129.383025","42.403749"],["129.268527","42.323223"],["129.222093","42.257635"],["129.2434","42.19201"],["128.992774","42.075243"],["128.959644","41.997184"],["128.121765","41.974471"],["128.183949","41.746614"],["128.336234","41.608881"],["128.268621","41.434008"],["128.127944","41.337429"],["128.00482","41.417516"],["127.65285","41.377517"],["127.537794","41.447986"],["127.248116","41.454805"],["127.234962","41.492217"],["127.08566","41.544545"],["127.128081","41.592273"],["127.012339","41.679643"],["127.035706","41.702541"],["126.914964","41.778689"],["126.809177","41.669562"],["126.74607","41.691325"],["126.612003","41.629975"],["126.529799","41.412013"],["126.562243","41.368516"],["126.557908","41.33825"],["126.45328","41.325763"],["126.3043","41.139979"],["126.148946","41.070584"],["126.132917","40.990783"],["126.041744","40.924117"],["126.041787","40.876401"],["125.721896","40.840697"],["125.681319","40.80754"],["125.712733","40.774611"],["125.686641","40.761853"],["125.582743","40.75319"],["125.423162","40.624246"],["125.310595","40.636606"],["125.022783","40.521123"],["125.06057","40.46396"],["124.907556","40.445935"],["124.374311","40.078794"],["124.388452","39.905638"],["123.741782","39.10294"],["123.282201","38.058466"],["124.24299","31.368588"],["124.714351","29.508006"],["125.072136","25.859069"],["124.935837","25.676612"],["123.836839","25.5127"],["122.751321","24.515956"],["121.947788","22.070621"],["121.867355","21.383021"],["119.827087","18.177352"],["119.026527","16.873489"],["119.11665","15.951676"],["119.101406","14.063252"],["119.100623","12.209516"],["119.07742","11.23357"],["116.011301","7.678721"],["114.941852","6.182877"],["114.229887","5.47862"],["113.86269","4.692236"],["112.795642","3.695169"],["111.953841","3.231846"],["109.894631","3.714037"],["108.659956","4.748032"],["107.925439","5.91737"],["107.96348","6.895899"],["108.555028","9.28242"],["110.128544","11.338543"],["109.983314","12.44102"],["109.806102","13.535124"],["109.636428","14.636855"],["109.78629","15.402577"],["109.449813","15.723154"],["108.117871","17.258818"],["107.310076","18.842045"],["107.374728","19.467179"],["108.051095","20.114414"],["108.328478","21.187373"],["108.278139","21.403412"],["108.107378","21.47839"],["107.943356","21.509097"],["107.849844","21.619412"],["107.547355","21.55724"],["107.470751","21.571209"],["107.451932","21.615722"],["107.357798","21.570152"],["107.289755","21.702532"],["107.207551","21.682454"],["106.998789","21.79714"],["107.015655","21.907972"],["106.951239","21.893876"],["106.768184","21.978429"],["106.703854","21.935422"],["106.674027","21.941175"],["106.664565","22.266461"],["106.643493","22.30484"],["106.538715","22.328641"],["106.53142","22.460275"],["106.592939","22.622033"],["106.708553","22.615477"],["106.793547","22.794758"],["106.548972","22.899047"],["106.304634","22.830954"],["106.190543","22.951201"],["106.088791","22.966118"],["105.867991","22.889816"],["105.712488","23.033058"],["105.550311","23.045755"],["105.530806","23.163759"],["105.330691","23.346393"],["105.249667","23.237422"],["105.089657","23.231409"],["104.951169","23.149476"],["104.843495","23.101267"],["104.893084","22.94393"],["104.747257","22.79551"],["104.567764","22.813411"],["104.371855","22.65974"],["104.249053","22.720536"],["104.237015","22.806132"],["104.137495","22.783462"],["104.078336","22.740585"],["104.017096","22.520843"],["103.962035","22.492019"],["103.666692","22.741534"],["103.525093","22.580551"],["103.458703","22.648987"],["103.394201","22.751092"],["103.341286","22.767397"],["103.306804","22.661878"],["103.215652","22.621855"],["103.205309","22.536362"],["103.107505","22.486567"],["103.076606","22.416444"],["102.91784","22.456309"],["102.840786","22.583305"],["102.610223","22.696625"],["102.558017","22.673838"],["102.493515","22.738071"],["102.424293","22.676273"],["102.446694","22.621241"],["102.327948","22.511268"],["102.278531","22.386786"],["102.142661","22.36867"],["102.03475","22.427651"],["101.942096","22.415036"],["101.8765","22.355136"],["101.764791","22.472926"],["101.700847","22.453176"],["101.694624","22.349917"],["101.579332","22.223979"],["101.631925","21.988099"],["101.718335","21.962549"],["101.79863","21.848016"],["101.778824","21.73654"],["101.856952","21.62392"],["101.847124","21.595911"],["101.773932","21.558438"],["101.760328","21.349162"],["101.862724","21.239522"],["101.764727","21.115389"],["101.663511","21.164623"],["101.587808","21.146813"],["101.574161","21.209359"],["101.53264","21.221881"],["101.293538","21.149214"],["101.203866","21.206559"],["101.216612","21.289294"],["101.114173","21.403592"],["101.183052","21.497378"],["101.111941","21.560533"],["101.095719","21.734009"],["100.901892","21.659343"],["100.747526","21.494902"],["100.586185","21.423588"],["100.468576","21.433695"],["100.414267","21.504705"],["100.248806","21.434534"],["100.115855","21.481604"],["100.078626","21.591362"],["100.11579","21.654357"],["100.010068","21.666462"],["99.916813","21.811046"],["99.968591","21.972539"],["99.950867","22.023392"],["99.699748","22.008512"],["99.585378","22.083453"],["99.19384","22.094388"],["99.129961","22.147006"],["99.24403","22.347694"],["99.226069","22.407775"],["99.348979","22.505302"],["99.289627","22.751963"],["99.429595","22.858203"],["99.422858","22.95454"],["99.521735","22.955884"],["99.488432","23.051046"],["99.336512","23.101188"],["99.258964","23.048934"],["99.10449","23.057463"],["98.99924","23.151389"],["98.858693","23.167152"],["98.89811","23.292382"],["98.844295","23.323341"],["98.878284","23.4184"],["98.821571","23.466061"],["98.773527","23.530055"],["98.849638","23.617887"],["98.774085","23.751823"],["98.656368","23.775684"],["98.63961","23.801661"],["98.649909","23.978332"],["98.828974","24.077833"],["98.83893","24.109859"],["98.594849","24.051324"],["98.534853","24.098401"],["98.118939","24.06406"],["97.652578","23.812007"],["97.500916","23.916402"],["97.507889","23.946076"],["97.703905","24.12772"],["97.7321","24.242073"],["97.646012","24.307132"],["97.678134","24.384313"],["97.653759","24.420913"],["97.528617","24.403523"],["97.504349","24.421636"],["97.520614","24.750904"],["97.686181","24.867223"],["97.726886","24.872596"],["97.701159","24.901891"],["97.691374","25.085579"],["97.816257","25.289948"],["97.844152","25.297669"],["97.93803","25.249897"],["98.122308","25.413237"],["98.152177","25.643055"],["98.313818","25.589382"],["98.380058","25.615679"],["98.510756","25.863626"],["98.635018","25.83211"],["98.668857","25.860517"],["98.546226","26.121072"],["98.648708","26.171346"],["98.686366","26.138757"],["98.648","26.279486"],["98.751404","26.620222"],["98.701365","26.849746"],["98.733852","27.033154"],["98.685272","27.065508"],["98.663149","27.194049"],["98.708661","27.325701"],["98.657935","27.422786"],["98.67244","27.532116"],["98.574979","27.540164"],["98.537407","27.61841"],["98.464022","27.631357"],["98.417695","27.512725"],["98.29766","27.498051"],["98.144388","27.832814"],["98.155954","27.920407"],["98.109477","27.953809"],["98.111","28.123353"],["97.991245","28.182664"],["97.984571","28.253152"],["97.904449","28.328541"],["97.775702","28.306704"],["97.650433","28.498038"],["97.537651","28.471615"],["97.537544","28.300942"],["97.374809","28.215134"],["97.340262","28.085365"],["97.441328","28.020526"],["97.41045","27.866111"],["97.271254","27.865238"],["97.104206","27.710621"],["97.074959","27.716851"],["96.959302","27.833554"],["96.799979","27.862962"],["96.485238","28.041967"],["96.435456","28.122218"],["96.282742","28.11548"],["96.254032","28.195619"],["96.011753","28.160892"],["95.866721","28.266533"],["95.747824","28.246895"],["95.417182","28.118906"],["95.304315","27.916842"],["94.898787","27.716889"],["94.531603","27.567615"],["94.290032","27.552854"],["93.888688","27.17204"],["93.845987","27.008916"],["93.571308","26.909059"],["92.944937","26.862668"],["92.647405","26.922873"],["92.093539","26.830122"],["92.094247","26.952103"],["91.998589","27.089524"],["92.083004","27.299047"],["92.034273","27.387239"],["91.995907","27.444668"],["91.729424","27.433927"],["91.566002","27.518015"],["91.534996","27.644815"],["91.602566","27.75719"],["91.514804","27.82382"],["91.562676","27.867913"],["91.468799","27.914302"],["91.441784","27.98019"],["91.319818","28.026891"],["91.09123","27.815659"],["90.700164","28.042914"],["90.592875","27.992071"],["90.457885","28.016188"],["90.284765","28.126494"],["90.15898","28.149257"],["90.026414","28.108761"],["89.808083","28.209972"],["89.741178","28.14466"],["89.620585","28.133666"],["89.394701","27.853894"],["89.261577","27.776101"],["89.129934","27.494282"],["89.208705","27.359876"],["89.003119","27.183627"],["88.914757","27.261172"],["88.754318","27.459692"],["88.742559","27.575756"],["88.824484","27.683585"],["88.858366","27.84585"],["88.817167","27.989323"],["88.749833","28.04227"],["88.643789","28.079175"],["88.414536","27.948938"],["88.164768","27.927649"],["88.119621","27.836742"],["87.844298","27.914245"],["87.731731","27.773994"],["87.596998","27.78341"],["87.555606","27.832169"],["87.226918","27.783961"],["87.114007","27.809055"],["87.017899","27.921014"],["86.741974","28.007834"],["86.699681","28.06541"],["86.621253","28.036683"],["86.583402","28.057988"],["86.53626","27.935498"],["86.410089","27.875861"],["86.21079","27.953771"],["86.168518","28.117581"],["86.115561","28.075237"],["86.149271","27.905693"],["85.994046","27.879218"],["85.944521","27.932939"],["85.832512","28.151055"],["85.730202","28.210313"],["85.701256","28.320003"],["85.608344","28.222546"],["85.501399","28.296408"],["85.379283","28.245137"],["85.108273","28.308745"],["85.080035","28.467918"],["85.159664","28.55567"],["85.153999","28.618263"],["85.06716","28.641711"],["84.995663","28.560816"],["84.851232","28.539159"],["84.68178","28.609315"],["84.624424","28.696084"],["84.465938","28.711423"],["84.389849","28.828396"],["84.202845","28.880867"],["84.21602","29.009754"],["84.163899","29.035197"],["84.138279","29.170731"],["84.156046","29.210987"],["84.110534","29.218441"],["84.085858","29.266484"],["83.922973","29.294016"],["83.658078","29.134976"],["83.571818","29.151918"],["83.232014","29.552591"],["83.070545","29.578981"],["82.920063","29.684809"],["82.816744","29.661877"],["82.675381","29.739992"],["82.684436","29.800693"],["82.605515","29.811846"],["82.541184","29.930689"],["82.159367","30.045582"],["82.174859","30.141657"],["82.084479","30.216893"],["82.077913","30.310431"],["81.993091","30.291904"],["81.637645","30.413095"],["81.562006","30.34101"],["81.44238","30.380465"],["81.419613","30.185719"],["81.306617","30.138261"],["81.279452","29.994378"],["81.11603","30.010804"],["80.995588","30.23662"],["80.302677","30.539587"],["80.0878","30.543727"],["79.94236","30.672449"],["79.868267","30.834188"],["79.825373","30.839126"],["79.673774","30.945519"],["79.593372","30.894565"],["79.4033","31.036535"],["79.346716","31.001927"],["79.336288","30.933391"],["79.224193","30.920174"],["79.170227","30.981969"],["79.092743","30.963258"],["78.986249","31.027673"],["78.96668","31.157988"],["78.856924","31.281503"],["78.783796","31.274131"],["78.728542","31.344273"],["78.757918","31.433515"],["78.697536","31.51499"],["78.804524","31.611708"],["78.62458","31.82264"],["78.722126","31.927562"],["78.578596","31.999524"],["78.497701","32.11424"],["78.432641","32.118838"],["78.402622","32.220389"],["78.4762","32.31131"],["78.36638","32.528271"],["78.381336","32.554898"],["78.75176","32.731065"],["78.809223","32.496551"],["78.976872","32.364195"],["79.005883","32.376536"],["79.080126","32.394077"],["79.114029","32.491665"],["79.279168","32.61355"],["79.272795","32.713951"],["79.195912","32.779409"],["79.222884","32.93039"],["79.135616","33.001861"],["79.1289","33.16414"],["78.818901","33.407102"],["78.715496","33.540948"],["78.723736","33.604683"],["78.656015","33.65053"],["78.749506","33.746395"],["78.715582","33.972994"],["78.631468","34.014908"],["78.635867","34.100789"],["78.894839","34.171104"],["78.97243","34.341399"],["78.867137","34.336615"],["78.698266","34.491737"],["78.566988","34.478543"],["78.527312","34.539705"],["78.430667","34.514354"],["78.403587","34.570207"],["78.247139","34.615374"],["78.238835","34.685346"],["78.179204","34.722162"],["78.172767","34.964414"],["78.056982","35.102584"],["77.985699","35.231108"],["77.986279","35.376996"],["78.060694","35.455461"],["77.904546","35.435236"],["77.815948","35.484733"],["77.688854","35.41908"],["77.389219","35.439747"],["77.300084","35.509365"],["77.189727","35.490691"],["76.844516","35.637645"],["76.746969","35.630442"],["76.675837","35.721674"],["76.57151","35.752903"],["76.552477","35.878323"],["76.372211","35.795695"],["76.149781","35.797227"],["76.124933","35.947734"],["75.922673","36.058952"],["75.911558","36.150212"],["76.037836","36.25097"],["75.962627","36.325913"],["75.987883","36.449905"],["75.852334","36.642976"],["75.645268","36.740208"],["75.442793","36.696296"],["75.389578","36.92691"],["75.229053","36.936669"],["75.144038","36.993436"],["74.896481","36.905551"],["74.830134","37.022531"],["74.731107","36.999897"],["74.690745","37.052831"],["74.559724","37.004866"],["74.481919","37.046871"],["74.437845","37.120308"],["74.499922","37.266966"],["74.739861","37.314987"],["74.866312","37.253902"],["75.109062","37.372562"],["75.102367","37.44057"],["74.921629","37.536802"],["74.864573","37.654148"],["74.964759","37.773242"],["74.890065","37.834937"],["74.908884","37.982278"],["74.777327","38.153069"],["74.761705","38.335766"],["74.838288","38.415972"],["74.834661","38.466073"],["74.630191","38.571841"],["74.373536","38.625873"],["74.159667","38.646204"],["74.103234","38.581"],["74.111817","38.521998"],["74.000838","38.494528"],["73.77285","38.599147"],["73.670411","38.8621"],["73.725193","38.95749"],["73.802719","38.951449"],["73.807654","38.986017"],["73.72221","39.008697"],["73.473516","39.38863"],["73.616295","39.498494"],["73.852308","39.511093"],["73.918183","39.600828"],["73.897347","39.705585"],["73.808942","39.800228"],["73.93934","39.994893"],["73.923182","40.040084"],["74.206402","40.150079"],["74.349396","40.120697"],["74.57305","40.295485"],["74.65313","40.30568"],["74.68538","40.371234"],["74.834146","40.370645"],["74.764109","40.445837"],["74.82522","40.547706"],["74.991968","40.485604"],["75.234225","40.478276"],["75.595829","40.68866"],["75.623209","40.675235"],["75.670288","40.537172"],["75.761075","40.482617"],["75.702088","40.361506"],["75.718331","40.319244"],["75.831778","40.356634"],["75.909498","40.327457"],["75.962198","40.405801"],["76.169136","40.4108"],["76.276231","40.468254"],["76.350474","40.381058"],["76.518981","40.485522"],["76.629574","40.63177"],["76.618888","40.769281"],["76.705191","40.836687"],["76.738064","40.970777"],["76.866853","41.052415"],["77.002079","41.102703"],["77.174621","41.038594"],["77.761016","41.051719"],["77.819595","41.177071"],["78.104789","41.252161"],["78.153155","41.41058"],["78.633699","41.494773"],["78.691227","41.573398"],["79.204752","41.752489"],["79.314144","41.836204"],["79.760721","41.919283"],["79.886034","42.062214"],["80.133162","42.067184"],["80.141101","42.212865"],["80.253518","42.271926"],["80.176806","42.427971"],["80.233755","42.509043"],["80.134728","42.629333"],["80.233669","42.836907"],["80.527124","42.908804"],["80.358446","43.012006"],["80.363209","43.05597"],["80.77054","43.196057"],["80.751915","43.283969"],["80.657952","43.321619"],["80.722024","43.489763"],["80.498157","43.799783"],["80.367136","44.112086"],["80.382199","44.282371"],["80.320637","44.484489"],["80.375676","44.600628"],["80.200903","44.711915"],["80.153825","44.809898"],["79.982829","44.769908"],["79.863417","44.896027"],["79.863911","44.925979"],["80.099001","45.081976"],["80.380783","45.073778"],["80.472493","45.151008"],["80.593643","45.1361"],["80.723355","45.20611"],["80.897505","45.157969"],["81.777248","45.412611"],["81.933761","45.262246"],["82.295816","45.254845"],["82.544253","45.206065"],["82.569401","45.340669"],["82.52743","45.402307"],["82.265496","45.514783"],["82.238288","45.626914"],["82.311373","45.780155"],["82.319655","45.956177"],["82.440763","46.003982"],["82.822452","46.775333"],["83.012309","47.24291"],["83.148286","47.241861"],["83.371532","47.179737"],["83.583899","47.087891"],["83.927865","46.999324"],["84.753106","47.038661"],["84.955001","46.896507"],["85.227256","47.083274"],["85.529079","47.087102"],["85.670679","47.295094"],["85.656817","47.416255"],["85.581307","47.505664"],["85.500433","48.023314"],["85.564678","48.210504"],["85.778117","48.445159"],["86.21609","48.461326"],["86.297393","48.520485"],["86.571493","48.56921"],["86.745751","48.738276"],["86.72689","48.79468"],["86.785169","48.850936"],["86.706676","48.980358"],["86.708565","49.011387"],["86.889625","49.162344"],["87.145572","49.183316"],["87.435358","49.10582"],["87.476878","49.120484"],["87.490826","49.169134"],["87.836187","49.198616"],["87.895432","49.115877"],["87.87024","49.056222"],["87.9406","48.974696"],["87.803872","48.87904"],["88.125672","48.72326"],["88.023491","48.591881"],["88.35763","48.495848"],["88.450756","48.423234"],["88.527102","48.435337"],["88.631537","48.352171"],["88.608513","48.280466"],["88.657844","48.207172"],["88.828926","48.136652"],["88.942652","48.146274"],["89.088199","48.017358"],["89.571383","48.066881"],["89.777999","47.863838"],["90.077548","47.910676"],["90.155997","47.747389"],["90.399628","47.669347"],["90.413575","47.647046"],["90.398619","47.62125"]],JPN=[["145.824681","43.408601"],["145.802708","43.198731"],["145.188847","43.068449"],["144.992667","42.907867"],["143.970938","42.890345"],["143.384543","42.351736"],["143.299399","41.875506"],["142.95333","42.100071"],["142.391844","42.272669"],["141.369501","42.535185"],["140.832544","42.147648"],["141.028863","41.945699"],["141.296655","41.765675"],["141.564447","41.265171"],["141.675004","40.481173"],["141.829516","40.300647"],["141.982619","40.122464"],["142.142627","39.594221"],["142.025897","39.368452"],["142.021777","39.317473"],["141.850783","38.901626"],["140.939308","35.65669"],["139.436268","34.193845"],["137.347075","34.1603"],["135.63835","33.29272"],["133.488103","32.70897"],["131.614016","31.325292"],["130.633951","28.842845"],["127.785048","25.789008"],["126.597333","26.344784"],["128.404011","28.563857"],["128.940636","30.856318"],["128.544464","32.79621"],["129.194642","34.475467"],["129.324698","34.765641"],["129.502255","34.700627"],["129.480282","33.855809"],["130.439605","33.915587"],["130.801388","34.159716"],["130.791882","34.445506"],["131.121471","34.437578"],["131.298124","34.567727"],["132.535148","35.287335"],["132.978675","36.154847"],["133.268559","36.366209"],["134.710796","35.708808"],["135.303308","35.794165"],["136.404389","36.456814"],["136.612743","37.37546"],["137.409252","37.580348"],["137.291471","36.906421"],["137.982237","37.126821"],["138.504087","37.383552"],["138.758146","37.83898"],["139.207212","38.04151"],["139.310081","38.315743"],["139.737028","38.85997"],["139.403318","39.234917"],["139.952634","39.328459"],["140.002073","39.745742"],["139.695586","39.824208"],["139.679107","40.025361"],["139.935912","40.077921"],["140.001079","40.309807"],["139.922802","40.434311"],["139.828954","40.646676"],["139.95008","40.766604"],["139.957833","41.432491"],["140.001779","42.027933"],["139.389291","42.038134"],["139.346719","42.242877"],["139.63099","42.291658"],["139.72712","42.641155"],["139.942098","42.710048"],["140.194783","42.842098"],["140.30396","42.856193"],["140.309453","43.306551"],["140.393224","43.399418"],["140.61976","43.355264"],["140.788732","43.238558"],["140.923314","43.24556"],["141.029058","43.24356"],["141.083989","43.216544"],["141.141667","43.185513"],["141.336675","43.240561"],["141.328435","43.731771"],["141.350408","43.792272"],["141.594854","43.937818"],["141.565334","44.291761"],["141.70541","44.45177"],["141.708157","44.742196"],["141.683437","45.002047"],["141.226594","45.076599"],["141.053559","45.165748"],["140.987641","45.335905"],["140.943696","45.481498"],["141.201589","45.501064"],["141.972005","45.52416"],["142.341996","45.204477"],["142.567215","45.014513"],["142.747966","44.801094"],["143.487122","44.343678"],["144.463587","44.078617"],["144.874201","44.098345"],["145.125513","44.222478"],["145.300832","44.391445"],["145.487445","44.320885"],["145.111163","43.848378"],["145.420933","43.545126"],["145.451146","43.393635"]],EAST=[["73.757316","29.95798"],["73.045185","28.989136"],["72.434431","28.60931"],["72.060098","28.097836"],["71.631749","27.60702"],["70.67236","27.593264"],["69.82743","27.041579"],["70.337045","26.566045"],["70.070655","26.098932"],["70.070655","25.85946"],["70.290717","25.713457"],["70.626599","25.671708"],["70.68451","25.201036"],["70.974064","24.791642"],["70.811914","24.612763"],["70.139151","24.465923"],["69.268014","24.435423"],["68.313114","24.267539"],["67.911051","23.808548"],["68.547651","23.00912"],["69.11724","22.684917"],["68.748682","22.406416"],["69.301519","21.536417"],["70.153052","20.55461"],["71.170222","20.332219"],["72.234349","21.204506"],["72.501752","21.087142"],["72.627589","19.003767"],["72.973641","16.878922"],["74.267757","13.888898"],["75.369075","10.48118"],["76.976429","7.781262"],["78.374805","8.242836"],["79.427902","9.641233"],["80.513091","10.734685"],["80.254133","11.953377"],["80.702994","13.082541"],["80.402232","15.312175"],["82.991824","16.887862"],["85.259974","19.051683"],["87.784208","21.10679"],["89.263244","21.658877"],["89.121009","23.437218"],["88.869364","23.717994"],["88.93501","24.317619"],["88.267603","24.596482"],["88.727129","25.073086"],["89.186656","25.132532"],["88.891246","25.626788"],["88.650542","25.666241"],["88.201956","25.892841"],["88.420778","26.12883"],["88.54113","26.285892"],["89.241361","26.020727"],["89.613359","25.863309"],["89.657124","25.330477"],["90.190932","25.070998"],["91.175632","25.051175"],["91.811935","25.05221"],["92.234344","24.983507"],["92.104658","24.649259"],["91.844714","24.363456"],["91.46563","24.215373"],["90.999897","23.839459"],["91.216517","23.054471"],["91.389672","22.300847"],["92.125338","20.623521"],["93.946113","18.753448"],["92.823675","16.135717"],["91.224276","9.998681"],["93.522355","5.752403"],["96.409859","0.991383"],["100.048825","-3.72227"],["104.60328","-7.736835"],["114.01025","-9.967468"],["123.433702","-11.032285"],["123.717523","-10.536628"],["124.427075","-10.257467"],["125.004217","-9.79418"],["125.026253","-9.527403"],["125.12788","-9.406056"],["125.031601","-9.358561"],["124.946021","-9.216037"],["125.026253","-9.168516"],["125.192065","-9.13155"],["125.181368","-8.982538"],["124.999509","-8.987821"],["124.919277","-8.924418"],["125.095787","-8.596662"],["125.555784","-8.088612"],["125.721597","-8.120384"],["127.292232","-8.326419"],["132.424841","-8.447132"],["139.646777","-8.512957"],["141.039618","-9.209048"],["141.025347","-6.894209"],["140.978655","-6.887392"],["140.92235","-6.851943"],["140.912737","-6.791946"],["140.905871","-6.737397"],["140.850939","-6.695117"],["140.903124","-6.59554"],["140.945696","-6.509588"],["141.000442","-6.341825"],["140.971754","-2.322171"],["131.63417","2.671779"],["125.182746","17.665698"],["120.512231","19.243264"],["119.486602","16.550429"],["119.820154","12.379244"],["115.293339","5.77989"],["114.675587","4.850295"],["114.550618","4.735342"],["113.923024","4.60805"],["113.581092","3.881824"],["113.423754","3.763395"],["113.138025","3.427757"],["112.798973","3.119213"],["111.886744","2.960093"],["109.608393","3.016867"],["108.771364","3.935896"],["107.181008","7.101455"],["110.509765","12.398562"],["108.171244","18.449712"],["108.482399","21.923911"],["106.042422","23.36869"],["103.861684","23.500971"],["101.853026","22.51803"],["101.964992","22.453371"],["102.079606","22.467488"],["102.100842","22.366033"],["102.192713","22.264854"],["102.457234","22.052786"],["102.482552","21.991854"],["102.505944","21.933096"],["102.598494","21.858522"],["102.635027","21.768076"],["102.625285","21.706993"],["102.652076","21.663993"],["102.749497","21.641356"],["102.798208","21.673047"],["102.841349","21.836472"],["102.857688","21.688772"],["102.936435","21.684707"],["102.971433","21.587108"],["102.897061","21.530145"],["102.831439","21.416153"],["102.853313","21.363197"],["102.770191","21.249074"],["102.905811","20.975636"],["103.219101","20.747931"],["103.517772","20.714677"],["103.809332","20.581588"],["103.928404","20.796397"],["104.17602","20.868718"],["104.456453","20.674762"],["104.597217","20.649539"],["104.494205","20.561152"],["104.33078","20.448774"],["104.574769","20.381484"],["104.658948","20.213054"],["104.76838","20.149846"],["104.838529","20.181454"],["104.938282","20.043215"],["104.745932","19.888842"],["104.790827","19.817585"],["104.656142","19.725166"],["104.580381","19.643265"],["104.41625","19.738372"],["104.315236","19.711959"],["104.004834","19.776374"],["103.978829","19.601517"],["104.057089","19.487272"],["103.795479","19.292317"],["104.05618","19.205901"],["104.303857","19.041792"],["104.509718","18.953592"],["104.638381","18.819682"],["104.82816","18.734411"],["105.081179","18.714495"],["105.090265","18.561021"],["105.010482","18.494337"],["105.215532","18.232365"],["105.507333","18.022503"],["105.673181","17.706155"],["105.959258","17.411042"],["106.393016","16.974064"],["106.530565","16.907086"],["106.511314","16.705452"],["106.610307","16.485756"],["106.704089","16.360817"],["106.855183","16.430793"],["106.917705","16.245803"],["107.074009","16.275813"],["107.178212","16.130721"],["107.386617","15.975505"],["107.256364","15.895346"],["107.157745","15.729918"],["107.270294","15.538977"],["107.541111","15.371176"],["107.598724","15.119441"],["107.495192","15.087312"],["107.421241","14.973038"],["107.491494","14.719275"],["107.439728","14.558285"],["107.365777","14.619117"],["107.28443","14.576179"],["107.125343","14.454386"],["107.058787","14.468707"],["106.862816","14.336197"],["106.714913","14.443644"],["106.640961","14.525985"],["106.467176","14.622607"],["106.385829","14.475868"],["106.219438","14.500928"],["106.189858","14.42932"],["106.104814","14.407834"],["105.956911","14.346944"],["105.993887","14.192854"],["106.138092","14.056594"],["106.067838","13.984846"],["105.938423","13.948964"],["105.860774","14.067355"],["105.570516","14.196239"],["105.40579","14.123984"],["105.307739","14.207645"],["105.23322","14.257067"],["105.284207","14.321679"],["105.397946","14.336879"],["105.499919","14.435654"],["105.550906","14.617894"],["105.535217","14.773437"],["105.660723","14.90613"],["105.629347","15.019802"],["105.511685","15.118269"],["105.543062","15.182626"],["105.660723","15.2848"],["105.543062","15.368016"],["105.641113","15.40205"],["105.652879","15.526792"],["105.672489","15.723201"],["105.433244","15.866611"],["105.419865","16.077323"],["105.134284","16.158015"],["105.05029","16.303179"],["104.798307","16.56635"],["104.815106","16.791639"],["104.807079","17.064937"],["104.834545","17.357467"],["104.746654","17.518618"],["104.392993","17.569592"],["104.221867","17.790865"],["104.071113","18.043041"],["103.989584","18.196169"],["103.880878","18.236734"],["103.692584","18.269917"],["103.616878","18.310466"],["103.546996","18.349162"],["103.428584","18.336313"],["103.370348","18.277339"],["103.302336","18.221647"],["103.237773","18.102183"],["103.207191","18.040806"],["103.105249","17.937384"],["102.938746","17.875949"],["102.914959","17.827432"],["102.813018","17.765959"],["102.687291","17.753015"],["102.568359","17.830667"],["102.510593","17.840371"],["102.422244","17.921219"],["102.310109","17.960013"],["102.204769","17.995566"],["102.143605","18.066652"],["101.987295","17.966477"],["101.868364","17.927685"],["101.647491","17.811257"],["101.148809","17.535022"],["101.023374","17.599797"],["101.039054","17.808912"],["101.175591","17.993048"],["101.212078","18.10208"],["101.219896","18.173904"],["101.206865","18.240749"],["101.212078","18.344679"],["101.107829","18.394147"],["101.092192","18.45349"],["101.206865","18.578877"],["101.31372","18.655442"],["101.272021","18.741845"],["101.272021","18.830671"],["101.311114","18.939171"],["101.370997","19.079681"],["101.298023","19.148632"],["101.279779","19.212632"],["101.22818","19.375675"],["101.230424","19.441269"],["101.295484","19.487804"],["101.29997","19.591402"],["101.239397","19.633668"],["101.145173","19.587175"],["101.093574","19.629442"],["100.94102","19.650571"],["100.893907","19.65691"],["100.864742","19.616763"],["100.835578","19.570265"],["100.770518","19.534326"],["100.611233","19.574493"],["100.584312","19.52164"],["100.525983","19.540669"],["100.46541","19.637894"],["100.436245","19.777288"],["100.541687","19.91867"],["100.597773","20.190526"],["100.502946","20.195053"],["100.428788","20.262059"],["100.379218","20.36601"],["100.329779","20.413638"],["100.244635","20.387895"],["100.173224","20.317079"],["100.160865","20.244943"],["100.114789","20.260301"],["100.107922","20.315689"],["100.155988","20.507461"],["100.211891","20.650056"],["100.290818","20.736459"],["100.399973","20.811825"],["100.562866","20.788277"],["100.673701","20.899705"],["100.59616","20.954029"],["100.751867","21.254036"],["100.998402","21.338663"],["101.211622","21.580378"],["101.209043","21.846211"],["100.909901","21.894492"],["100.207565","21.580378"],["100.051491","22.159742"],["99.466212","22.436515"],["99.71333","23.024318"],["99.352488","23.281431"],["99.03983","24.3247"],["98.101855","24.95993"],["98.855913","25.608485"],["98.911088","26.812993"],["98.892697","27.483968"],["98.340947","27.826069"],["98.120247","28.377665"],["97.586888","28.733061"],["97.108705","28.329109"],["96.658506","27.787659"],["96.296725","28.010502"],["95.847241","28.136253"],["95.288126","27.787659"],["94.685158","27.233428"],["93.281889","26.647032"],["92.037851","26.720259"],["90.141229","26.820605"],["88.984724","26.833974"],["88.731159","27.080308"],["88.794435","27.331629"],["88.741186","27.914582"],["88.223484","27.953015"],["88.169108","27.50057"],["87.774017","27.262697"],["88.215457","26.870398"],["87.783036","26.535989"],["87.047344","26.702224"],["84.777332","27.310285"],["83.539214","27.665305"],["82.385985","27.880248"],["81.010299","28.662263"],["80.547568","29.001896"],["81.345045","30.304903"],["80.749935","31.185747"],["80.056967","31.015739"],["79.215234","31.178494"],["78.991224","31.346766"],["79.254658","31.656243"],["78.835019","31.979804"],["78.65109","32.12011"],["78.595912","32.240756"],["78.591313","32.400075"],["78.669483","32.54361"],["78.739513","32.426665"],["78.84424","32.288005"],["79.067657","32.24668"],["79.277111","32.470789"],["79.395802","32.676713"],["79.235221","33.233259"],["79.011803","33.47819"],["78.84424","33.681772"],["79.182009","34.336185"],["78.821102","34.565916"],["78.428537","34.758609"],["78.294895","34.940474"],["78.23791","35.530039"],["77.722544","35.628785"],["77.294994","35.609184"],["76.821489","35.701892"],["76.684572","35.988603"],["76.399329","35.919333"],["76.159724","35.933192"],["76.165429","36.20986"],["76.074151","36.366207"],["75.999987","36.641347"],["75.714744","36.787688"],["75.562518","36.805399"],["75.481245","36.811057"],["75.45651","36.950968"],["75.253968","37.023882"],["75.084541","37.066268"],["74.894884","37.084426"],["74.735572","37.122745"],["74.643309","37.074934"],["74.566145","37.033976"],["74.549925","36.938948"],["74.491692","37.015218"],["74.377803","36.998366"],["74.261908","36.915016"],["74.132106","36.91687"],["74.057933","36.840851"],["73.967535","36.853836"],["73.925813","36.892775"],["73.808039","36.908632"],["73.728388","36.920709"],["73.639124","36.911926"],["73.699986","36.820121"],["73.765904","36.814624"],["73.833196","36.776135"],["73.853795","36.743128"],["73.834569","36.711208"],["73.735692","36.736525"],["73.657414","36.707906"],["73.599736","36.711208"],["73.57227","36.735425"],["73.517339","36.729922"],["73.397862","36.757433"],["73.319585","36.738726"],["73.241307","36.720664"],["73.175389","36.732772"],["73.112218","36.71516"],["73.032567","36.686532"],["73.039433","36.651284"],["73.060033","36.609405"],["73.036687","36.564195"],["73.002355","36.529994"],["72.958409","36.507921"],["72.944676","36.475904"],["72.886998","36.474799"],["72.855412","36.448292"],["72.848546","36.400777"],["72.832334","36.374217"],["72.796629","36.362053"],["72.685258","36.303681"],["72.663286","36.274901"],["72.574022","36.267151"],["72.461412","36.175196"],["73.530389","35.809316"],["74.170542","35.420826"],["74.340245","35.055408"],["73.9237","34.612198"],["73.676858","34.332391"],["73.880481","33.422673"],["74.651862","32.906095"],["75.747223","32.542685"],["75.623802","32.256112"],["74.975842","31.968632"],["74.759855","31.732749"],["74.759855","30.955369"],["74.327882","30.584206"],["74.18929","30.224947"],["74.035013","29.864372"]],getOutseaData=function(t){return t&&"mapbox"===t?{boundsP16:[[CHN]],nebulaOutSea:[]}:{boundsP16:[[CHN],[JPN],[EAST]],nebulaOutSea:[[JPN],[EAST]]}},geoUtil=new GeometryUtilCls({}),CONSTS$1={sV:"https://webapi.amap.com/style_icon/sprite_v8@2x.png",EU:[LangConf.my.type,LangConf.km.type,LangConf.PU.type,LangConf.th.type,LangConf.$U.type]},MapboxLabelFormat=function(r){function t(t){var e=r.call(this)||this;return e.kQ={},e}return __extends(t,r),t.prototype.Ns=function(t,e){return r.prototype.Ns.call(this,t,e),this.rV(t,e)},t.prototype.rV=function(t,e){var r,n,i=(t.data||{}).poilabel||[],a=t.road||[],o={},s=this.hV(t);for(r in i)i.hasOwnProperty(r)&&(n=i[r],n=this.nV(n,s,e.zoom,e.VQ),o[r]=n);return this.oV(a,{}),o},t.prototype.nV=function(t,e,r,n){for(var i=[],a=this.kQ,o=0,s=t;o<s.length;o++){var u,c,f,h,l,d,v,g,p,m=(y=s[o]).name,b=y.position,T=y.id,A=y.minzoom,x=y.maxzoom,y=void 0===(y=y.style)?{}:y;"mapbox"!==n&&9<=r&&e&&!this.uV(b[0])||(u=y.lV,c=y.th,f=y.ih,d=y.nh,g=y.qU,v=y.eh,h=void 0===(h=y.textAnchor)?"bottom":h,l=y.rh,y.sh,p=y.Kr,y=y.Qr,A=[A,x],x=null,d&&g&&v&&(this.Fs[CONSTS$1.sV]=1,x=[{image:CONSTS$1.sV,size:[g[6]/2,g[7]/2],clipOrigin:[g[4],g[5]],clipSize:[g[6],g[7]]}]),d=null,m&&p&&(a[p]||(a[p]=Util.color2RgbaArray(p)),v=a[p],g=void 0,p=0,a[y]||(a[y]=Util.color2RgbaArray(y||"")),a[y]&&(g=a[y],p=3),y=this.fV(m)?[0,m.length]:[],this.Ws(m,y),d={txt:m,$G:y,direction:h||"center",offset:[0,0],style:{fontSize:l,fillColor:v,strokeColor:g,strokeWidth:p,fold:!1}}),y={data:{id:T,name:m,txt:m,position:b[0],positionType:"relative",zooms:[c,f],extData:{id:T,type:"poi"}},opts:{zIndex:u,zooms:A,visible:!0}},x&&(y.opts.icon=x),d&&(y.opts.text=d),(y.opts.text||y.opts.icon)&&i.push(y))}return i},t.prototype.oV=function(t,e){for(var r=0,n=t;r<n.length;r++){var i=n[r].name,a=this.fV(i)?[0,i.length]:[];i&&this.Ws(i,a)}},t.prototype.DQ=function(t,e){for(var r=[],n=0,i=t;n<i.length;n++){var o=(a=i[n]).path,s=a.name||"",u=labelsUtil.aQ(s.split("")),c=a.distance||1e5;a.style&&a.style[1];var f=void 0===(f=(a=a.style||{}).th)?zoomRange[0]:f,h=void 0===(h=a.ih)?zoomRange[1]:h,l=a.Kr,d=a.Qr,v=a.rh,g=a.zIndex,a=a.Hr;s&&o&&o.length&&r.push({path:o,positionType:"absolute",name:s,$G:[],CO:u,rank:g,BG:void 0===a?"name_en":a,distance:c,zooms:[f,h],style:{fontSize:v||12,fillColor:l,strokeColor:d}})}return r},t.prototype.fV=function(t){return t=LangManager.kU(t),-1!==CONSTS$1.EU.indexOf(t)},t.prototype.uV=function(t){for(var e=ProjectionManager.getProjection("EPSG:3857").unproject(t[0],t[1]),r=getOutseaData("mapbox").boundsP16,n=0;n<r.length;n++){var i=r[n];if(geoUtil.isPointInPolygon(e,i[0]))return!1}return!0},t.prototype.hV=function(t){return t=[[(t=t.Ro)[0],t[1]],[t[2],t[1]],[t[2],t[3]],[t[0],t[3]]],this.cV(t)},t.prototype.cV=function(t){for(var e=[],r=0;r<t.length;r++){var n=t[r],n=ProjectionManager.getProjection("EPSG:3857").unproject(n[0],n[1]);e.push(n)}for(var i=getOutseaData("mapbox").boundsP16,a=0;a<i.length;a++){var o=i[a];if(geoUtil.isRingInRingByMapboxB(e,o[0]))return!0}return!1},t.id="mapbox",t}(LabelFormat),Color=function(){function t(t){this.type="AMap.Color",this.rgba=[],this.Vb(t)}var e=t;return t.Wb=function(t,e){return{rgba:t.rgba}},t.Gb=function(t){return new e(t.rgba)},t.FV=function(t,e){var r=(t=this.DV(t[0],t[1],t[2],t[3]))[0],n=t[1],i=t[2],t=t[3];return this.GQ(r+=(.5<r?-.5:.5)*e*.35,n-=(n-.5)*e*.35*5,i-=(i-.5)*e*.35,t)},t.DV=function(t,e,r,n){var i,a,o,s=Math.max(t,e,r),u=Math.min(t,e,r),c=(s+u)/2;if(s===u)i=a=0;else{switch(o=s-u,a=.5<c?o/(2-s-u):o/(s+u),s){case t:i=(e-r)/o+(e<r?6:0);break;case e:i=(r-t)/o+2;break;case r:i=(t-e)/o+4}i/=6}return[i,a,c,n]},t.uQ=function(t,e,r){return r<0&&(r+=1),1<r&&--r,r<1/6?t+6*(e-t)*r:r<.5?e:r<2/3?t+(e-t)*(2/3-r)*6:t},t.GQ=function(t,e,r,n){var i,a,o;return 0===e?i=a=o=r:(i=this.uQ(e=2*r-(r=r<.5?r*(1+e):r+e-r*e),r,t+1/3),a=this.uQ(e,r,t),o=this.uQ(e,r,t-1/3)),[i,a,o,n]},t.Hb=function(t,e){void 0===e&&(e=[]);for(var r=0,n=t.length;r<n;r+=2)e[r/2]=parseInt(t.substr(r,2),16);return e},t.Yx=function(t){return t.startsWith("#")&&(t=t.substr(1)),colorNames[t]?e.Hb(colorNames[t].substr(1)):1===t.length?e.Hb(t+t+t+t+t+t):3===t.length?e.Hb(t[0]+t[0]+t[1]+t[1]+t[2]+t[2]):6===t.length?e.Hb(t):[0,0,0]},t.normalize=function(t){for(var e=[],r=0,n=t.length;r<n;r++)e[r]=t[r]/255;return e},t.create=function(t){return t?new e(t):null},t.prototype.normalize=function(){return[this.rgba[0]/255,this.rgba[1]/255,this.rgba[2]/255,this.rgba[3]/255]},t.prototype.Vb=function(t){"string"==typeof t?colorNames[t]?this.Hb(colorNames[t].substr(1)):0!==t.length&&(1===(t=t.startsWith("#")?t.substr(1):t).length?this.Hb(t+t+t+t+t+t):3===t.length?this.Hb(t[0]+t[0]+t[1]+t[1]+t[2]+t[2]):6===t.length?this.Hb(t):8===t.length?this.$b(t):t.startsWith("rgba(")?this.Yb(colorNames[t].substr(1)):t.startsWith("rgb(")&&this.Kb(colorNames[t].substr(1))):t instanceof Array&&(this.rgba[0]=t[0],this.rgba[1]=t[1],this.rgba[2]=t[2],this.rgba[3]=t[3]||255)},t.prototype.Hb=function(t){this.$b(t+"FF")},t.prototype.$b=function(t){for(var e=0,r=t.length;e<r;e+=2)this.rgba[e/2]=parseInt(t.substr(e,2),16)},t.prototype.Kb=function(t){t=t.split(","),this.rgba[0]=parseInt(t[0].substr(4),10),this.rgba[1]=parseInt(t[1],10),this.rgba[2]=parseInt(t[2],10),this.rgba[3]=255},t.prototype.Yb=function(t){t=t.split(","),this.rgba[0]=parseInt(t[0].substr(5),10),this.rgba[1]=parseInt(t[1],10),this.rgba[2]=parseInt(t[2],10),this.rgba[3]=255*parseFloat(t[3])<<0},e=__decorate([InnerClass("Color")],t)}(),colorNames={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgrey:"#d3d3d3",lightgreen:"#90ee90",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370d8",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#d87093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},NebulaLabelFormat=function(r){function t(t){var e=r.call(this)||this;return e.bt=20,e.WW=20,e._opts={},e.uA={},e.vn=t.vn,e}return __extends(t,r),t.prototype.Ns=function(t,e){return e.lang&&(this.lang=e.lang),this._opts=e,this.bt=e.zoom,this.WW=e.ZL,this.rV(t,e.R_)},t.prototype.rV=function(t,e){var r,n,i=t.data||{},a=i.poilabel||[],o={},s=t.cQ;for(r in a)a.hasOwnProperty(r)&&(n=this.nV(a[r],{aV:t.zo.z<10,cQ:s,R_:e}),o[r]=n);return i=i.roadName||[],i=this.oV(i,{R_:e}),o.eA=i,o},t.prototype.nV=function(U,t){for(var e,r,n,i,a,o,s,u,c,f,h,l,d=CONSTS.Lj,j=d.file,F=d.size,R=CONSTS.Mp,D=CONSTS.Pp,B=CONSTS.jp,G=this._opts.scale,V=(t=void 0===t?{}:t).aV,v=t.cQ,z=this.bt,W=[],H=this.lang,q=!v&&5<=z,g=0,K=U;g<K.length;g++){var p=K[g],y=p.cw,m=p.ew,b=p.pos,T=(E=labelsUtil.tQ(p,H,q?t.R_:void 0)).name,Y=E.$G||[],A=p.rank,x=p.minzoom||R,M=(V?zoomRange[1]:p.maxzoom,p.Fp),S=p.Ep;if(3===x&&(x=2),(10002!==M||28!==S)&&(e=this.oA(M,S,this.WW))&&(r=1<G||9<e.fontSize?e.fontSize:9,o=e.iconFile,s=e.showMode,u=e.forceShow,c=e.zIndex,p=e.zooms,w=labelsUtil.Jj([x,zoomRange[1]],p))){for(var w,P=(w=labelsUtil.$p(w))[0],I=[],C={};P<=w[1];){var N=this.vn.dn(M,S,P);N&&"0"!==N.iconID&&(O=N.iconID,-1===I.indexOf(O)&&(I.push(O),C[O]=[]),C[O].push(P)),P++}(10002!==M||20!==S&&18!==S)&&16<r&&(r=15);for(var $,x=[w[0]-D,w[1]+B],k=(10002===M&&(13===S||18===S)&&x[0]<=3&&(x[0]=2.5),f=o&&"https"+j[o],p={data:{id:y?y+S:"",position:b,name:T,txt:T,rank:A,BG:E.type,extData:{Lp:M,Ap:S,id:y,type:"poi",bz:m}},opts:{type:"billboard",angle:0,forceShow:u,zIndex:c,visible:!0,zooms:x}},h=e.xOffset||0,l=e.yOffset||0,[]),b=void 0,A=[0,0],L=0;L<I.length;L++){var O=I[L],X=o&&this.aA(parseInt(O,10)),Z=F,_=labelsUtil.$p(C[O]),J=1;!T||"152"!==O&&"153"!==O&&"154"!==O||(J=T.length<=2?1:T.length/2),$=vector.Up(Z,2),f&&k.push({type:"image",image:f,clipOrigin:vector.add(X,[0,0]),clipSize:Z,size:[$[0]*J,$[1]],anchor:[10-20*h/24,10-20*l/24],angle:0,retina:!0,zooms:[_[0]-D,_[_.length-1]+B]})}T&&(A="曾母暗沙"===T?(b="top",[0,5]):k.length&&k[0].image?(O=I[0],v&&(b="bottom",A=[0,0]),"北京"===T?(b="top",[0,3]):"澳门"===T?(b="left",[0,-2]):"合肥"===T||"太原"===T||"西安"===T||"郑州"===T||"杭州"===T||"台北"===T||"加德满都"===T?(b="bottom",[0,-3]):10002!==M||31!==S&&32!==S&&34!==S&&5!==S?1===s||"152"!==O&&"153"!==O&&"154"!==O?(b="right",[0,-2]):(b="center",[0,-1]):(b="right",[-3,-3])):(b="center",[h,l]));var E=""+M+S;(y=this.uA[E])?(n=y.faceColor,i=y.borderColor,a=y.holoColor):(n=e.faceColor&&Color.normalize(e.faceColor.rgba),i=e.borderColor&&Color.normalize(e.borderColor.rgba),a=3===e.showMode?e.holoColor&&Color.normalize(e.holoColor.rgba):null,this.uA[E]={faceColor:n,borderColor:i,holoColor:a}),m=T?{direction:b,offset:A,$G:Y,style:{fontSize:r,strokeWidth:2,padding:[0,1,0,1],fold:!v&&5<=z}}:{},p.opts&&(p.opts.icon=k,p.opts.text=m),f&&(this.Fs[f]=1),T&&this.Ws(T,Y),W.push(p)}}return W},t.prototype.oV=function(t,e){for(var r=CONSTS.Lj,n=r.file,i=r.size,a=CONSTS.Mp,o=CONSTS.Rp,s=CONSTS.Pp,u=CONSTS.jp,c=[],f=this._opts.scale,h=this.lang,l=(e=void 0===e?{}:e)&&e.R_&&e.R_.protocol||"https",d=0,v=t;d<v.length;d++){var g,p,y=v[d],m=y.path,b=y.rank,T=y.minzoom||a,A=y.maxzoom||o,x=y.shield,M=y.shieldType,S=(y=labelsUtil.tQ(y,h)).name,w=y.$G;S&&this.Ws(S,w),!x||(w=Math.floor(m.length/2))<1||(m=[m[w-1],m[w]],(M=this.oA(40001,w=M,this.WW))&&(g=1<f||9<M.fontSize?M.fontSize:9,p=M.faceColor,M=M.iconID,m={data:{id:Util.stamp(this),position:m,positionType:"relative",name:S,txt:x,rank:b,BG:y.type,extData:{type:"shield",Lp:40001,Ap:w}},opts:{type:"billboard",angle:0,zooms:[T-s,A+u],visible:!0}},S=this.aA(parseInt(M,10)),b=1<x.length/4?x.length/4:1,y={type:"image",image:l+n[0],clipOrigin:S,clipSize:i,size:[24*(1<f?b:9*b/7),24],anchor:"center",angle:0,retina:!0},w=x?{direction:"center",offset:[0,0],style:{fontSize:g,fillColor:p&&Color.normalize(p.rgba),strokeWidth:0,padding:[0,1,0,1]}}:{},m.opts&&(m.opts.text=w,m.opts.icon=[y]),x&&this.Ws(x),c.push(m)))}return c},t.prototype.DQ=function(t,e){for(var r=CONSTS.Mp,n=CONSTS.Rp,i=CONSTS.Pp,a=CONSTS.jp,o=this.WW=e.zoom,s=0,u=[],c=this.lang,f=0,h=t;f<h.length;f++){var l,d,v,g,p,y,m,b,T,A,x,M=h[f],S=M.id,w=(l=labelsUtil.tQ(M,c)).name,P=l.$G||[];w&&(l=l.type,d=labelsUtil.EQ(w,P),d=labelsUtil.aQ(d),v=M.rank,g=M.Fp,p=M.Ep,s=M.distance||0,y=M.minzoom||r,m=M.maxzoom||n,b=(A=(A=this.vn.dn(g,p,o))&&A[1]||{}).fontSize,T=A.faceColor,A=A.borderColor,y=(x=labelsUtil.$p([y,m]))[0],m=20<=(m=x[1])?zoomRange[1]:m,w)&&S&&b&&T&&(x={id:S,positionType:"relative",name:w,$G:P,CO:d,rank:v,BG:l,distance:s,zooms:[y-i,m+a],path:0<M.path.length?M.path:void 0,style:{fontSize:b,fillColor:vector.Up(T.rgba,255),strokeColor:A&&vector.Up(A.rgba,255)},extData:{mainkey:g,subkey:p}},u.push(x))}return u},t.prototype.aA=function(t){var r=(e=CONSTS.Lj).Rj,e=e.size,n=Math.floor(t/r);return t%10==0&&--n,[(t-r*n-1)*e[0],n*e[1]]},t.prototype.oA=function(t,e,r){var n=[3,20],i=this.vn.dn(t,e,r),a=this.vn.mn(t,e);if(!i)for(var o=1;(n[0]<=r-o||r+o<=n[1])&&!(i=(i=this.vn.dn(t,e,r-o))||this.vn.dn(t,e,r+o));)o++;return i&&(i.zooms=a),i},t.prototype.mN=function(t,e){var r=[0,0];if("0"===t)switch(e){case"3":r=[6,6];break;case"4":case"5":case"6":r=[9,9]}return r},t.prototype.TN=function(t,e,r){var n=r=void 0===r?[0,0]:r;if("0"===t)switch(e){case"3":n=[30,30];break;case"4":case"5":case"6":n=[20,20]}return n},t.id=exports.n0.nebulaLabel,t}(LabelFormat),TileCoord=(function(t){t.TOLOAD="toload",t.LOADING="loading",t.LOADED="loaded",t.UNLOADED="unloaded",t.ERROR="error",t.RELOADING="reloading"}(exports.TileState||(exports.TileState={})),function(){function t(t,e,r){this.x=e,this.y=r,this.z=t,this.key=t+","+e+","+r}var n=t;return t.prototype.s0=function(t){var e=t-this.z,r=Math.floor(Math.pow(2,e)*this.x),e=Math.floor(Math.pow(2,e)*this.y);return new n(t,r,e)},n=__decorate([InnerClass("TileCoord")],t)}()),Tile=function(){function t(t){this.type="tile",this.Ro=[0,0,0,0],this.stamp=0,this.zo=t,this.status=exports.TileState.TOLOAD,this._v=null,this.data={}}return t.YH=function(t){return t.status===exports.TileState.LOADED||t.status===exports.TileState.RELOADING},t.prototype.destroy=function(){},t.prototype.nG=function(t){this.type=t},__decorate([InnerClass("Tile")],t)}(),NebulaTile=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="nebula",t.region="world",t.aN=exports.zB.NONE,t.BN=exports.zB.NONE,t}return __extends(t,e),Object.defineProperty(t.prototype,"tag",{get:function(){return this.nN},set:function(t){this.aN=this.tag,this.nN=t},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"gB",{get:function(){return this.VN},set:function(t){this.BN=this.gB,this.VN=t},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"data",{get:function(){var t=[];return this.qc&&this.qc.Dc?t.push(this.qc):(this.sN&&t.push(this.sN),this.uN&&t.push(this.uN)),this.lU&&this.lU.Dc?t.push(this.lU):(this.fU&&t.push(this.fU),this.cU&&t.push(this.cU)),this.zN&&this.zN.labels?t.push(this.zN):(this.HN&&t.push(this.HN),this.WN&&t.push(this.WN)),this.dU&&this.dU.labels?t.push(this.dU):(this.vU&&t.push(this.vU),this.gU&&t.push(this.gU)),t},set:function(t){},enumerable:!1,configurable:!0}),t.prototype.xa=function(t,e){if(void 0===e&&(e=exports.zB.ALL),Object.keys(t))switch(e){case exports.zB.LITE:this.uN=exports.Ln(exports.Ln({},this.uN),t);break;case exports.zB.LEFT:this.sN=exports.Ln(exports.Ln({},this.sN),t);break;default:exports.zB.ALL,this.qc=exports.Ln(exports.Ln({},this.qc),t)}},t.prototype.JE=function(t,e){if(void 0===e&&(e=exports.zB.ALL),Object.keys(t))switch(e){case exports.zB.LITE:this.cU=exports.Ln(exports.Ln({},this.cU),t);break;case exports.zB.LEFT:this.fU=exports.Ln(exports.Ln({},this.fU),t);break;default:exports.zB.ALL,this.lU=exports.Ln(exports.Ln({},this.lU),t)}},t.prototype.rO=function(t,e){if(void 0===e&&(e=exports.zB.ALL),Object.keys(t))switch(e){case exports.zB.LITE:this.WN=exports.Ln(exports.Ln({},this.WN),t);break;case exports.zB.LEFT:this.HN=exports.Ln(exports.Ln({},this.HN),t);break;default:exports.zB.ALL,this.zN=exports.Ln(exports.Ln({},this.zN),t)}},t.prototype.qE=function(t,e){if(void 0===e&&(e=exports.zB.ALL),Object.keys(t))switch(e){case exports.zB.LITE:this.gU=exports.Ln(exports.Ln({},this.gU),t);break;case exports.zB.LEFT:this.vU=exports.Ln(exports.Ln({},this.vU),t);break;default:exports.zB.ALL,this.dU=exports.Ln(exports.Ln({},this.dU),t)}},t.prototype.ID=function(t){t&&(t.uN&&(this.uN=t.uN),t.sN&&(this.sN=t.sN),t.qc&&(this.qc=t.qc),t.WN&&(this.WN=t.WN),t.HN&&(this.HN=t.HN),t.zN)&&(this.zN=t.zN)},t.prototype.rN=function(){this.aN?this.nN=this.aN:this.nN=exports.zB.NONE,this.BN&&(this.VN=this.BN,this.nN=exports.zB.NONE)},t.prototype.AB=function(){var t=[];return this.qc&&this.qc.road&&this.zN&&this.zN.labels?t.push(this.qc):(this.sN&&this.sN.road&&this.HN&&this.HN.labels&&t.push(this.sN),this.uN&&this.uN.road&&this.WN&&this.WN.labels&&t.push(this.uN)),t},t.prototype.LY=function(t,e){for(var r=0,n=this.data;r<n.length;r++){var i=n[r];i.Dc&&i.Dc.upload(t,!0),i.$c&&i.$c.upload(t,!0),i.A_&&i.A_.upload(t,!0),i.FD&&i.FD.upload(t,!0)}},t.prototype.destroy=function(){var t=this.data;if(t)for(var e=0,r=t;e<r.length;e++){var n=r[e];if(n.Dc&&(n.Dc.destroy(),delete n.Dc),n.$c&&(n.$c.destroy(),delete n.$c),n.labels){for(var i=0,a=n.labels;i<a.length;i++)a[i].destroy();delete n.labels}n.Ta=!1,delete n.gf}},t.prototype.KE=function(t){for(var e,r=this.data,n=[],i=0,a=t;i<a.length;i++)(o=a[i]).road&&n.push(o.road);for(var o,s=0,u=r;s<u.length;s++)(o=u[s]).XE&&(e=o.XE,this.pU(n,e))},t.prototype.reload=function(){delete this.lU,delete this.cU,delete this.fU,delete this.zN,delete this.WN,delete this.HN,delete this.VN,this.BN=exports.zB.NONE},t.prototype.pU=function(t,e){for(var r=0,n=e;r<n.length;r++){var i=n[r],a=i.id;if(i.path)break;for(var o=0,s=t;o<s.length;o++){var u=s[o];i.path=this.yU(u,a)}}},t.prototype.yU=function(t,e){for(var r=0,n=t;r<n.length;r++){var i=n[r];if(i.id===e)return i.path}},t.prototype.oN=function(){var t=this.qc;return!!(t=Object.keys(t||{})).length&&(1!==t.length||"sdfLoaded"!==t[0])},__decorate([InnerClass("NebulaTile")],t)}(Tile),RasterTile=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="raster",t}return __extends(t,e),t.prototype.destroy=function(){var t=this.data;t&&(t.texture&&(t.texture.destroy(),delete t.texture),t.zs&&(t.zs.context.deleteBuffer(t.zs),delete t.zs),t.Js)&&(t.Js.destroy(),delete t.Js)},t}(Tile),VectorTile=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type="vector",t}return __extends(t,e),t.prototype.destroy=function(){var t=this.data;t&&(t.$c&&(t.$c.destroy(),delete t.$c),t.Uc)&&delete t.Uc},__decorate([InnerClass("VectorTile")],t)}(Tile);function quickselect(t,e,r,n,i){quickselectStep(t,e,r||0,n||t.length-1,i||defaultCompare)}function quickselectStep(t,e,r,n,i){for(;r<n;){600<n-r&&(a=n-r+1,o=e-r+1,u=Math.log(a),s=.5*Math.exp(2*u/3),u=.5*Math.sqrt(u*s*(a-s)/a)*(o-a/2<0?-1:1),quickselectStep(t,e,Math.max(r,Math.floor(e-o*s/a+u)),Math.min(n,Math.floor(e+(a-o)*s/a+u)),i));var a,o,s,u,c=t[e],f=r,h=n;for(swap(t,r,e),0<i(t[n],c)&&swap(t,r,n);f<h;){for(swap(t,f,h),f++,h--;i(t[f],c)<0;)f++;for(;0<i(t[h],c);)h--}0===i(t[r],c)?swap(t,r,h):swap(t,++h,n),h<=e&&(r=h+1),e<=h&&(n=h-1)}}function swap(t,e,r){var n=t[e];t[e]=t[r],t[r]=n}function defaultCompare(t,e){return t<e?-1:e<t?1:0}var _rbush_2_0_2_rbush=rbush,default_1=rbush,Status,M;function rbush(t,e){if(!(this instanceof rbush))return new rbush(t,e);this.Bc=Math.max(4,t||9),this.Wc=Math.max(2,Math.ceil(.4*this.Bc)),e&&this.Gc(e),this.clear()}function findItem(t,e,r){if(!r)return e.indexOf(t);for(var n=0;n<e.length;n++)if(r(t,e[n]))return n;return-1}function calcBBox(t,e){distBBox(t,0,t.children.length,e,t)}function distBBox(t,e,r,n,i){(i=i||createNode(null)).ja=1/0,i.Fa=1/0,i.Oa=-1/0,i.Ea=-1/0;for(var a,o=e;o<r;o++)a=t.children[o],extend$1(i,t.Zc?n(a):a);return i}function extend$1(t,e){t.ja=Math.min(t.ja,e.ja),t.Fa=Math.min(t.Fa,e.Fa),t.Oa=Math.max(t.Oa,e.Oa),t.Ea=Math.max(t.Ea,e.Ea)}function compareNodeMinX(t,e){return t.ja-e.ja}function compareNodeMinY(t,e){return t.Fa-e.Fa}function bboxArea(t){return(t.Oa-t.ja)*(t.Ea-t.Fa)}function bboxMargin(t){return t.Oa-t.ja+(t.Ea-t.Fa)}function enlargedArea(t,e){return(Math.max(e.Oa,t.Oa)-Math.min(e.ja,t.ja))*(Math.max(e.Ea,t.Ea)-Math.min(e.Fa,t.Fa))}function intersectionArea(t,e){var r=Math.max(t.ja,e.ja),n=Math.max(t.Fa,e.Fa),i=Math.min(t.Oa,e.Oa),t=Math.min(t.Ea,e.Ea);return Math.max(0,i-r)*Math.max(0,t-n)}function contains(t,e){return t.ja<=e.ja&&t.Fa<=e.Fa&&e.Oa<=t.Oa&&e.Ea<=t.Ea}function intersects(t,e){return e.ja<=t.Oa&&e.Fa<=t.Ea&&e.Oa>=t.ja&&e.Ea>=t.Fa}function createNode(t){return{children:t,height:1,Zc:!0,ja:1/0,Fa:1/0,Oa:-1/0,Ea:-1/0}}function multiSelect(t,e,r,n,i){for(var a,o=[e,r];o.length;)(r=o.pop())-(e=o.pop())<=n||(quickselect(t,a=e+Math.ceil((r-e)/n/2)*n,e,r,i),o.push(e,a,a,r))}function getModule(){return M=M||{nS:function(clsName,clsText){try{eval(clsText)}catch(e){throw e}},eS:{iS:"1699967635311",BY:!Browser.DW&&config[13]}},M}rbush.prototype={all:function(){return this.qc(this.data,[])},search:function(t){var e=this.data,r=[],n=this.Yc;if(intersects(t,e))for(var i,a,o,s,u=[];e;){for(i=0,a=e.children.length;i<a;i++)o=e.children[i],intersects(t,s=e.Zc?n(o):o)&&(e.Zc?r.push(o):contains(t,s)?this.qc(o,r):u.push(o));e=u.pop()}return r},Vc:function(t){var e=this.data,r=this.Yc;if(intersects(t,e))for(var n,i,a,o,s=[];e;){for(n=0,i=e.children.length;n<i;n++)if(a=e.children[n],intersects(t,o=e.Zc?r(a):a)){if(e.Zc||contains(t,o))return!0;s.push(a)}e=s.pop()}return!1},load:function(t){if(t&&t.length)if(t.length<this.Wc)for(var e=0,r=t.length;e<r;e++)this.Xc(t[e]);else{var n,i=this.Hc(t.slice(),0,t.length-1,0);this.data.children.length?this.data.height===i.height?this.Jc(this.data,i):(this.data.height<i.height&&(n=this.data,this.data=i,i=n),this.Kc(i,this.data.height-i.height-1,!0)):this.data=i}return this},Xc:function(t){return t&&this.Kc(t,this.data.height-1),this},clear:function(){return this.data=createNode([]),this},remove:function(t,e){if(t)for(var r,n,i,a,o=this.data,s=this.Yc(t),u=[],c=[];o||u.length;){if(o||(o=u.pop(),n=u[u.length-1],r=c.pop(),a=!0),o.Zc&&-1!==(i=findItem(t,o.children,e)))return o.children.splice(i,1),u.push(o),this.Qc(u),this;a||o.Zc||!contains(o,s)?n?(r++,o=n.children[r],a=!1):o=null:(u.push(o),c.push(r),o=(n=o).children[r=0])}return this},Yc:function(t){return t},tf:compareNodeMinX,if:compareNodeMinY,toJSON:function(){return this.data},ef:function(t){return this.data=t,this},qc:function(t,e){for(var r=[];t;)t.Zc?e.push.apply(e,t.children):r.push.apply(r,t.children),t=r.pop();return e},Hc:function(t,e,r,n){var i,a=r-e+1,o=this.Bc;if(a<=o)calcBBox(i=createNode(t.slice(e,r+1)),this.Yc);else{n||(n=Math.ceil(Math.log(a)/Math.log(o)),o=Math.ceil(a/Math.pow(o,n-1))),(i=createNode([])).Zc=!1,i.height=n;var s,u,c,f,h=Math.ceil(a/o),l=h*Math.ceil(Math.sqrt(o));for(multiSelect(t,e,r,l,this.tf),s=e;s<=r;s+=l)for(multiSelect(t,s,c=Math.min(s+l-1,r),h,this.if),u=s;u<=c;u+=h)f=Math.min(u+h-1,c),i.children.push(this.Hc(t,u,f,n-1));calcBBox(i,this.Yc)}return i},nf:function(t,e,r,n){for(var i,a,o,s,u,c,f,h;n.push(e),!e.Zc&&n.length-1!==r;){for(f=h=1/0,i=0,a=e.children.length;i<a;i++)u=bboxArea(o=e.children[i]),(c=enlargedArea(t,o)-u)<h?(h=c,f=u<f?u:f,s=o):c===h&&u<f&&(f=u,s=o);e=s||e.children[0]}return e},Kc:function(t,e,r){var n=this.Yc,r=r?t:n(t),i=[];for((n=this.nf(r,this.data,e,i)).children.push(t),extend$1(n,r);0<=e&&i[e].children.length>this.Bc;)this.af(i,e),e--;this.sf(r,i,e)},af:function(t,e){var r=t[e],n=r.children.length,i=this.Wc,i=(this.rf(r,i,n),this.hf(r,i,n));(n=createNode(r.children.splice(i,r.children.length-i))).height=r.height,n.Zc=r.Zc,calcBBox(r,this.Yc),calcBBox(n,this.Yc),e?t[e-1].children.push(n):this.Jc(r,n)},Jc:function(t,e){this.data=createNode([t,e]),this.data.height=t.height+1,this.data.Zc=!1,calcBBox(this.data,this.Yc)},hf:function(t,e,r){for(var n,i,a,o,s,u=o=1/0,c=e;c<=r-e;c++)i=intersectionArea(a=distBBox(t,0,c,this.Yc),n=distBBox(t,c,r,this.Yc)),a=bboxArea(a)+bboxArea(n),i<u?(u=i,s=c,o=a<o?a:o):i===u&&a<o&&(o=a,s=c);return s},rf:function(t,e,r){var n=t.Zc?this.tf:compareNodeMinX,i=t.Zc?this.if:compareNodeMinY;this.lf(t,e,r,n)<this.lf(t,e,r,i)&&t.children.sort(n)},lf:function(t,e,r,n){t.children.sort(n);for(var i,a=this.Yc,o=distBBox(t,0,e,a),s=distBBox(t,r-e,r,a),u=bboxMargin(o)+bboxMargin(s),c=e;c<r-e;c++)i=t.children[c],extend$1(o,t.Zc?a(i):i),u+=bboxMargin(o);for(c=r-e-1;e<=c;c--)i=t.children[c],extend$1(s,t.Zc?a(i):i),u+=bboxMargin(s);return u},sf:function(t,e,r){for(var n=r;0<=n;n--)extend$1(e[n],t)},Qc:function(t){for(var e,r=t.length-1;0<=r;r--)0===t[r].children.length?0<r?(e=t[r-1].children).splice(e.indexOf(t[r]),1):this.clear():calcBBox(t[r],this.Yc)},Gc:function(t){var e=["return a"," - b",";"];this.tf=new Function("a","b",e.join(t[0])),this.if=new Function("a","b",e.join(t[1])),this.Yc=new Function("a","return {minX: a"+t[0]+", minY: a"+t[1]+", maxX: a"+t[2]+", maxY: a"+t[3]+"};")}},_rbush_2_0_2_rbush.default=default_1,function(t){t.loading="loading",t.loaded="loaded"}(Status=Status||{});var M=getModule(),Queue=function(){function t(){this.tT={}}return t.prototype.add=function(t,e){for(var r=t.length,n=0,i=function(){(n+=1)===r&&e&&e()},a=0,o=t;a<o.length;a++){var s=o[a];this._add(s,i)}},t.prototype.has=function(t){return(t=this.tT[t])&&t.status===Status.loaded},t.prototype.finish=function(t){if(t=this.tT[t]){t.status=Status.loaded;for(var e=0,r=t.pI;e<r.length;e++){var n=r[e];n&&n()}}},t.prototype._add=function(t,e){var r=this.tT[t];r?r.status===Status.loading?r.pI.push(e):e():this.tT[t]={pI:[e],status:Status.loading}},t}(),Module=getModule();function InnerClass(e){return function(t){getModule()[e]=t}}getModule().MapboxLabelFormat=MapboxLabelFormat,getModule().NebulaLabelFormat=NebulaLabelFormat,getModule()._LocalZoom={Ra:13,za:12,Ge:""},getModule().Support=Browser,getModule().geo={lcs:lcs,ProjectionManager:ProjectionManager},getModule().transform=transform,getModule().Util=Util,getModule().TileState=exports.TileState,getModule().assign=assign,getModule().labelsUtil=labelsUtil,getModule().LabelsRenderUtil=LabelsRenderUtil,getModule().vector=vector,getModule().rbush=_rbush_2_0_2_rbush,getModule().lodash={map:map,find:find,assign:assign,every:every,some:some};var isSupportFloat32Array="undefined"!=typeof Float32Array,EPSILON=(isSupportFloat32Array||(window.Float32Array=void 0,setMatrixArrayType(Array)),1e-6),ARRAY_TYPE="undefined"!=typeof Float32Array?Float32Array:Array;function setMatrixArrayType(t){ARRAY_TYPE=t}function fromValues(t,e,r,n){var i=new ARRAY_TYPE(4);return i[0]=t,i[1]=e,i[2]=r,i[3]=n,i}function create(){var t=new ARRAY_TYPE(16);return ARRAY_TYPE!=Float32Array&&(t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[11]=0,t[12]=0,t[13]=0,t[14]=0),t[0]=1,t[5]=1,t[10]=1,t[15]=1,t}function identity$1(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 invert(t,e){var r=e[0],n=e[1],i=e[2],a=e[3],o=e[4],s=e[5],u=e[6],c=e[7],f=e[8],h=e[9],l=e[10],d=e[11],v=e[12],g=e[13],p=e[14],y=r*s-n*o,m=r*u-i*o,b=r*c-a*o,T=n*u-i*s,A=n*c-a*s,x=i*c-a*u,M=f*g-h*v,S=f*p-l*v,w=f*(e=e[15])-d*v,P=h*p-l*g,I=h*e-d*g,C=l*e-d*p,N=y*C-m*I+b*P+T*w-A*S+x*M;return N?(t[0]=(s*C-u*I+c*P)*(N=1/N),t[1]=(i*I-n*C-a*P)*N,t[2]=(g*x-p*A+e*T)*N,t[3]=(l*A-h*x-d*T)*N,t[4]=(u*w-o*C-c*S)*N,t[5]=(r*C-i*w+a*S)*N,t[6]=(p*b-v*x-e*m)*N,t[7]=(f*x-l*b+d*m)*N,t[8]=(o*I-s*w+c*M)*N,t[9]=(n*w-r*I-a*M)*N,t[10]=(v*A-g*b+e*y)*N,t[11]=(h*b-f*A-d*y)*N,t[12]=(s*S-o*P-u*M)*N,t[13]=(r*P-n*S+i*M)*N,t[14]=(g*m-v*T-p*y)*N,t[15]=(f*T-h*m+l*y)*N,t):null}function multiply(t,e,r){var n=e[0],i=e[1],a=e[2],o=e[3],s=e[4],u=e[5],c=e[6],f=e[7],h=e[8],l=e[9],d=e[10],v=e[11],g=e[12],p=e[13],y=e[14],e=e[15],m=r[0],b=r[1],T=r[2],A=r[3];return t[0]=m*n+b*s+T*h+A*g,t[1]=m*i+b*u+T*l+A*p,t[2]=m*a+b*c+T*d+A*y,t[3]=m*o+b*f+T*v+A*e,m=r[4],b=r[5],T=r[6],A=r[7],t[4]=m*n+b*s+T*h+A*g,t[5]=m*i+b*u+T*l+A*p,t[6]=m*a+b*c+T*d+A*y,t[7]=m*o+b*f+T*v+A*e,m=r[8],b=r[9],T=r[10],A=r[11],t[8]=m*n+b*s+T*h+A*g,t[9]=m*i+b*u+T*l+A*p,t[10]=m*a+b*c+T*d+A*y,t[11]=m*o+b*f+T*v+A*e,m=r[12],b=r[13],T=r[14],A=r[15],t[12]=m*n+b*s+T*h+A*g,t[13]=m*i+b*u+T*l+A*p,t[14]=m*a+b*c+T*d+A*y,t[15]=m*o+b*f+T*v+A*e,t}function getTranslation(t,e){return t[0]=e[12],t[1]=e[13],t[2]=e[14],t}function perspective(t,e,r,n,i){return e=1/Math.tan(e/2),t[0]=e/r,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=e,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[11]=-1,t[12]=0,t[13]=0,t[15]=0,null!=i&&i!==1/0?(t[10]=(i+n)*(r=1/(n-i)),t[14]=2*i*n*r):(t[10]=-1,t[14]=-2*n),t}function ortho(t,e,r,n,i,a,o){var s=1/(e-r),u=1/(n-i),c=1/(a-o);return t[0]=-2*s,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=-2*u,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=2*c,t[11]=0,t[12]=(e+r)*s,t[13]=(i+n)*u,t[14]=(o+a)*c,t[15]=1,t}function lookAt(t,e,r,n){var i,a,o,s,u=e[0],c=e[1],e=e[2],f=n[0],h=n[1],n=n[2],l=r[0],d=r[1],r=r[2];return Math.abs(u-l)<EPSILON&&Math.abs(c-d)<EPSILON&&Math.abs(e-r)<EPSILON?identity$1(t):(l=u-l,d=c-d,r=e-r,i=h*(r*=s=1/Math.hypot(l,d,r))-n*(d*=s),n=n*(l*=s)-f*r,f=f*d-h*l,(s=Math.hypot(i,n,f))?(i*=s=1/s,n*=s,f*=s):f=n=i=0,h=d*f-r*n,a=r*i-l*f,o=l*n-d*i,(s=Math.hypot(h,a,o))?(h*=s=1/s,a*=s,o*=s):o=a=h=0,t[0]=i,t[1]=h,t[2]=l,t[3]=0,t[4]=n,t[5]=a,t[6]=d,t[7]=0,t[8]=f,t[9]=o,t[10]=r,t[11]=0,t[12]=-(i*u+n*c+f*e),t[13]=-(h*u+a*c+o*e),t[14]=-(l*u+d*c+r*e),t[15]=1,t)}function equals(t,e){var r=t[0],n=t[1],i=t[2],a=t[3],o=t[4],s=t[5],u=t[6],c=t[7],f=t[8],h=t[9],l=t[10],d=t[11],v=t[12],g=t[13],p=t[14],t=t[15],y=e[0],m=e[1],b=e[2],T=e[3],A=e[4],x=e[5],M=e[6],S=e[7],w=e[8],P=e[9],I=e[10],C=e[11],N=e[12],$=e[13],k=e[14],e=e[15];return Math.abs(r-y)<=EPSILON*Math.max(1,Math.abs(r),Math.abs(y))&&Math.abs(n-m)<=EPSILON*Math.max(1,Math.abs(n),Math.abs(m))&&Math.abs(i-b)<=EPSILON*Math.max(1,Math.abs(i),Math.abs(b))&&Math.abs(a-T)<=EPSILON*Math.max(1,Math.abs(a),Math.abs(T))&&Math.abs(o-A)<=EPSILON*Math.max(1,Math.abs(o),Math.abs(A))&&Math.abs(s-x)<=EPSILON*Math.max(1,Math.abs(s),Math.abs(x))&&Math.abs(u-M)<=EPSILON*Math.max(1,Math.abs(u),Math.abs(M))&&Math.abs(c-S)<=EPSILON*Math.max(1,Math.abs(c),Math.abs(S))&&Math.abs(f-w)<=EPSILON*Math.max(1,Math.abs(f),Math.abs(w))&&Math.abs(h-P)<=EPSILON*Math.max(1,Math.abs(h),Math.abs(P))&&Math.abs(l-I)<=EPSILON*Math.max(1,Math.abs(l),Math.abs(I))&&Math.abs(d-C)<=EPSILON*Math.max(1,Math.abs(d),Math.abs(C))&&Math.abs(v-N)<=EPSILON*Math.max(1,Math.abs(v),Math.abs(N))&&Math.abs(g-$)<=EPSILON*Math.max(1,Math.abs(g),Math.abs($))&&Math.abs(p-k)<=EPSILON*Math.max(1,Math.abs(p),Math.abs(k))&&Math.abs(t-e)<=EPSILON*Math.max(1,Math.abs(t),Math.abs(e))}function create$1(){var t=new ARRAY_TYPE(3);return ARRAY_TYPE!=Float32Array&&(t[0]=0,t[1]=0,t[2]=0),t}function fromValues$1(t,e,r){var n=new ARRAY_TYPE(3);return n[0]=t,n[1]=e,n[2]=r,n}function copy(t,e){t[0]=e[0],t[1]=e[1],t[2]=e[2]}function set(t,e,r,n){return t[0]=e,t[1]=r,t[2]=n,t}function subtract(t,e,r){return t[0]=e[0]-r[0],t[1]=e[1]-r[1],t[2]=e[2]-r[2],t}function cross(t,e,r){var n=e[0],i=e[1],e=e[2],a=r[0],o=r[1],r=r[2];t[0]=i*r-e*o,t[1]=e*a-n*r,t[2]=n*o-i*a}Math.hypot||(Math.hypot=function(){for(var t=0,e=arguments.length;e--;)t+=arguments[e]*arguments[e];return Math.sqrt(t)});var sub=subtract,forEach$1=function(){var u=create$1();return function(t,e,r,n,i,a){var o,s;for(e=e||3,r=r||0,s=n?Math.min(n*e+r,t.length):t.length,o=r;o<s;o+=e)u[0]=t[o],u[1]=t[o+1],u[2]=t[o+2],i(u,u,a),t[o]=u[0],t[o+1]=u[1],t[o+2]=u[2];return t}}();function create$2(){var t=new ARRAY_TYPE(4);return ARRAY_TYPE!=Float32Array&&(t[0]=0,t[1]=0,t[2]=0,t[3]=0),t}function fromValues$2(t,e,r,n){var i=new ARRAY_TYPE(4);return i[0]=t,i[1]=e,i[2]=r,i[3]=n,i}function scale$1(t,e,r){return t[0]=e[0]*r,t[1]=e[1]*r,t[2]=e[2]*r,t[3]=e[3]*r,t}function transformMat4(t,e,r){var n=e[0],i=e[1],a=e[2],e=e[3];return t[0]=r[0]*n+r[4]*i+r[8]*a+r[12]*e,t[1]=r[1]*n+r[5]*i+r[9]*a+r[13]*e,t[2]=r[2]*n+r[6]*i+r[10]*a+r[14]*e,t[3]=r[3]*n+r[7]*i+r[11]*a+r[15]*e,t}var forEach$2=function(){var u=create$2();return function(t,e,r,n,i,a){var o,s;for(e=e||4,r=r||0,s=n?Math.min(n*e+r,t.length):t.length,o=r;o<s;o+=e)u[0]=t[o],u[1]=t[o+1],u[2]=t[o+2],u[3]=t[o+3],i(u,u,a),t[o]=u[0],t[o+1]=u[1],t[o+2]=u[2],t[o+3]=u[3];return t}}();function create$3(){var t=new ARRAY_TYPE(2);return ARRAY_TYPE!=Float32Array&&(t[0]=0,t[1]=0),t}function clone$1(t){var e=new ARRAY_TYPE(2);return e[0]=t[0],e[1]=t[1],e}function fromValues$3(t,e){var r=new ARRAY_TYPE(2);return r[0]=t,r[1]=e,r}function copy$1(t,e){t[0]=e[0],t[1]=e[1]}function set$1(t,e,r){return t[0]=e,t[1]=r,t}function add(t,e,r){t[0]=e[0]+r[0],t[1]=e[1]+r[1]}function subtract$1(t,e,r){return t[0]=e[0]-r[0],t[1]=e[1]-r[1],t}function multiply$1(t,e,r){return t[0]=e[0]*r[0],t[1]=e[1]*r[1],t}function scale$2(t,e,r){t[0]=e[0]*r,t[1]=e[1]*r}function distance(t,e){var r=e[0]-t[0],e=e[1]-t[1];return Math.hypot(r,e)}function negate(t,e){t[0]=-e[0],t[1]=-e[1]}function normalize(t,e){var r=e[0],n=e[1];0<(r=r*r+n*n)&&(r=1/Math.sqrt(r)),t[0]=e[0]*r,t[1]=e[1]*r}function dot(t,e){return t[0]*e[0]+t[1]*e[1]}function cross$1(t,e,r){e=e[0]*r[1]-e[1]*r[0],t[0]=t[1]=0,t[2]=e}function transformMat2(t,e,r){var n=e[0],e=e[1];t[0]=r[0]*n+r[2]*e,t[1]=r[1]*n+r[3]*e}function rotate(t,e,r,n){var i=e[0]-r[0],e=e[1]-r[1],a=Math.sin(n),n=Math.cos(n);t[0]=i*n-e*a+r[0],t[1]=i*a+e*n+r[1]}function angle(t,e){var r=t[0],t=t[1],n=e[0],i=r*r+t*t,a=n*n+(e=e[1])*e;return 1<(r=(r*n+t*e)*(0<i?1/Math.sqrt(i):i)*(0<a?1/Math.sqrt(a):a))?0:r<-1?Math.PI:Math.acos(r)}function equals$1(t,e){var r=t[0],t=t[1],n=e[0],e=e[1];return Math.abs(r-n)<=EPSILON*Math.max(1,Math.abs(r),Math.abs(n))&&Math.abs(t-e)<=EPSILON*Math.max(1,Math.abs(t),Math.abs(e))}var sub$1=subtract$1,mul=multiply$1,dist$1=distance,forEach$3=function(){var u=create$3();return function(t,e,r,n,i,a){var o,s;for(e=e||2,r=r||0,s=n?Math.min(n*e+r,t.length):t.length,o=r;o<s;o+=e)u[0]=t[o],u[1]=t[o+1],i(u,u,a),t[o]=u[0],t[o+1]=u[1];return t}}(),Event=function(){function t(){this.vI={}}return t.addListener=function(t,e,r){t.on(e,r)},t.trigger=function(t,e,r){t.emit(e,r)},t.clearListeners=function(t,e){t.clearEvents(e)},t.addDomListener=function(t,e,r){t.addEventListener(e,r)},t.extend=function(t,r,n){forEach(t="string"==typeof t?[t]:t,function(e){r.on(e,function(t){n.emit(e,t)})})},t.prototype.on=function(t,e,r,n){void 0===r&&(r=this),void 0===n&&(n=!1);for(var i=0,a=Array.isArray(t)?t:[t];i<a.length;i++){var o=a[i];this._on(o,e,r,n)}return this},t.prototype.off=function(t,e,r){void 0===r&&(r=this);var n=this.vI;if(t in n)for(var i=0;i<n[t].length;i+=1)if(n[t][i].fn===e&&n[t][i].context===r)return n[t].splice(i,1),this;return this},t.prototype.hasEvents=function(t,e,r){void 0===r&&(r=this);var n=this.vI;if(t&&e&&t in n)for(var i=0;i<n[t].length;i+=1)if(n[t][i].fn===e&&n[t][i].context===r)return!0;return!1},t.prototype.clearEvents=function(t){return t?this.vI[t]&&delete this.vI[t]:this.vI={},this},t.prototype.emit=function(t,e){if(void 0===e&&(e={}),t in this.vI){for(var r=exports.Ln(exports.Ln({},e),{type:t}),n=this.vI[t],i=0,a=n.length;i<a;i+=1){var o=n[i];o&&o.fn&&(o.fn.call(o.context,r),o.once)&&(this.vI[t].splice(i,1),--i,--a)}0===n.length&&delete this.vI[t]}return this},t.prototype.getEvents=function(){return this.vI},t.prototype._on=function(t,e,r,n){var i;return void 0===n&&(n=!1),this.hasEvents(t,e,r=void 0===r?this:r)||((i=this.vI)[t]=i[t]||[],i[t].push({fn:e,context:r||this,once:n})),this},t}(),NebulaTileCoord=function(){var o=[-180,-90],s=[180,90],u=s[0]-o[0],c=s[1]-o[1];return{ga:function(t,e,r,n){void 0===n&&(n="lnglat");var r=Math.pow(2,r),i=u/r,r=c/r,a=ProjectionManager.getProjection("EPSG:3857");return"lnglat"===n?[t*i+o[0],s[1]-e*r,(t+1)*i+o[0],s[1]-(e+1)*r]:"EPSG:3857"===n?(n=a.project(t*i+o[0],s[1]-e*r),a=a.project((t+1)*i+o[0],s[1]-(e+1)*r),[n[0],n[1],a[0],a[1]]):[0,0,0,0]}}}(),ComputeTileRange=function(){function t(){}return t.ha=function(t,e){for(var r=[t[0],t[3]],t=[t[2],t[1]],r=this.Ga(r,e),t=this.Ga(t,e),n=r[0],i=r[1],a=t[0],o=t[1],s=[],u=n;u<=a;u+=1)for(var c=i;c<=o;c+=1)s.push([e,u,c]);return s},t.Ga=function(t,e){var r=180/(e=Math.pow(2,e));return[Math.floor(t[0]/(360/e))+e/2,e/2-Math.ceil(t[1]/r)]},t.ra=function(t){return{2:3,3:3,4:3,5:3,6:6,7:6,8:8,9:8,10:10,11:10,12:10,13:12,14:12,15:14,16:14,17:14,18:14,19:14,20:14,21:14,22:14}[t]},t}(),Task=function(){function t(t){var r=this;this.xN=t,this.cancel=function(){r.xN&&r.xN.cancel();for(var t=0,e=r.children;t<e.length;t++)e[t].cancel.apply(r)},this.children=[]}return t.prototype._H=function(t){this.children.push(t)},t}(),LabelPlacement=function(){function t(t){this.options={},this.Gj={},this.Hj={},this.Vj={},this.Wj={},this.$j=0,this.render=null,this.NO={},this.ac=t.z_,this.Mf=t.R_,this.io=t.canvas,this.NT=t.Nz}return t.prototype.nO=function(t,e){this.iO=(e=void 0===e?{}:e).from||"inner",labelsUtil.zj(this,t),this.eO(e)},t.prototype.destroy=function(){},t.prototype.oO=function(){return this.gs.aO()},t.prototype.uO=function(){return this.oO().viewMode,!0},t.prototype.eO=function(t){var e,r,n,i,a,o=(t=void 0===t?{}:t).center,s=this.Gj||{},u=this.Vj||{},c=this.Hj||{},f=this.iO,h=0;for(e in s)s.hasOwnProperty(e)&&e&&(a=s[e]||{},c[e]=this.sO(e,a),u[e]=this.fO(e,a,c[e],{from:f,center:o}),r=a.data.txt,n=(i=a.opts).icon,i=i.text||{},a=a.CO,r&&a&&(h+=a.length+1,i.style)&&i.style.borderWidth&&(h+=4),n)&&n.length&&n[0].image&&(h+=n.length);this.$j=h,this.Vj=u,this.Hj=c},t.prototype.hO=function(t,e){var r=CONSTS.Mp,n=CONSTS.Rp,i=(t=void 0===t?[]:t)[0]||r,t=t[1]||n;return[(r=(e=void 0===e?[]:e)[0]||r)<i?i:r,t<(e=e[1]||n)?t:e]},t.prototype.cO=function(t,e){var r={};return r.type=(t=void 0===t?{}:t).type||e.type,r.image=t.image||"",r.clipOrigin=t.clipOrigin||e.clipOrigin,r.clipSize=t.clipSize,r.size=t.size,r.offset=t.offset,r.anchor=t.anchor||e.anchor,r.angel=t.angel||e.angel,r.retina=t.retina||e.retina,r.zooms=t.zooms||e.zooms,r},t.prototype.vO=function(t,e){var r={},e=(r.type=(t=void 0===t?{}:t).type||e.type,r.direction=t.direction||e.direction,r.offset=t.offset||e.offset,r.zooms=t.zooms||e.zooms,e.style),t=t.style||{},n=(r.style={},r.style.fontFamily=t.fontFamily||e.fontFamily,r.style.fontSize=t.fontSize||e.fontSize,r.style.fontWeight=t.fontWeight||e.fontWeight,r.style.fillColor=t.fillColor||e.fillColor,t.strokeColor),i=t.strokeWidth;return isUndefined(i)&&isUndefined(n)?r.style.strokeWidth=e.strokeWidth:isUndefined(i)&&!isUndefined(n)?r.style.strokeWidth=1:r.style.strokeWidth=t.strokeWidth,r.style.borderColor=t.borderColor,r.style.borderWidth=t.borderWidth,r.style.strokeColor=t.strokeColor||e.strokeColor,r.style.borderColor=t.borderColor||e.borderColor,r.style.backgroundColor=t.backgroundColor,r.style.padding=t.padding||e.padding,r.style.fold=void 0!==t.fold&&t.fold,r},t.prototype.lO=function(t){return[(t=(this.ac.Fs||{})[t]||{}).width||36,t.height||36]},t.prototype.dO=function(t,e){var r=CONSTS.sj,e=((r=this.cO(t,r.icon)).zooms=t.zooms||e.bO,this.hO(e.zooms,r.zooms));return r.zooms=e,r.size&&r.clipSize||(t=(e=this.lO(t.image||""))[0]||0,e=e[1]||0,r.size||(r.size=[t,e]),r.clipSize)||(r.clipSize=[t,e]),r},t.prototype.pO=function(t,e){var r=CONSTS.sj,t=((r=this.vO(t=void 0===t?{}:t,r.text)).zooms=t.zooms||e.bO,r.direction),n=e.yO,n=(t=this.mO(t||"",n)).textAlign,t=t.verticalAlign,n=(r.style&&(r.style.textAlign=n,r.style.verticalAlign=t),this.hO(e.zooms,r.zooms));return r.zooms=n,r},t.prototype.sO=function(t,e){var r=(r=e.data)&&r.txt,n=(e=e.opts||{}).angle||0,i=isUndefined(e.opacity)?1:e.opacity,a=e.icon,o=e.text,s=e.zooms,e=e.visible,u={angle:n,opacity:i,zooms:this.options.zooms,bO:s},c=[];if(a)for(var f=0,h=a;f<h.length;f++){var l=h[f];c.push(this.dO(l,u))}return u.yO=!!a,(n=r?this.pO(o,u):null)&&(n.txt=r),i={icon:c,text:n,visible:e},"labelsLayer"===this.iO&&(i.showText=1,i.showIcon=1),i},t.prototype.gO=function(t){var e;return this.oO().zoom<LocalZoom?t:(e=lcs.getLocalByCoord(t),vector.Ip(t,e.center))},t.prototype.wO=function(t,e){var r,n;return e&&e.image?(n=CONSTS.sj.icon,r=e.size||this.lO(e.image),e=e.anchor||n.anchor,{size:r,origin:t,anchorOffset:n=this._getAnchorOffset(r,e),coords:vector.add(t,n)}):{size:[0,0],origin:t,anchorOffset:[0,0],coords:t}},t.prototype.MO=function(t,e,r){var n,i,a,o,s,u;return"text"===(t=void 0===t?"icon":t)?(t=e.origin,e.start,o=r.padding,u=r.c,r=void 0,n=o.offsetX,i=o.offsetY,a=o.w,o=o.h,s=(this.uO()?(r=u[0],u):(r=t[0],t))[1],{x:r+n,y:s+i,width:a,height:o}):(t=e.size,e.coords,{x:(u=e.c)[0],y:u[1],width:(r=void 0===t?[]:t)[0]||0,height:r[1]||0})},t.prototype._getAnchorOffset=function(t,e){var r=CONSTS.JM,n=t[0]||0,i=t[1]||0;if("[object Array]"===Object.prototype.toString.apply(e)){var t=e[0],a=e[1];if("number"==typeof t&&"number"==typeof a)return vector.tA(e)}else if("string"==typeof e){var a=(t=e.split("-"))[0],e=t[1],o=0,s=0;switch(a!==r.ij||e||(a=r.nj,e=r.ij),e){case r.LEFT:o=0;break;case r.ij:o=-n/2;break;case r.QM:o=-n;break;default:o=0}switch(a){case r.ZM:s=0;break;case r.nj:s=-i/2;break;case r.tj:s=-i;break;default:s=0}return[o,s]}return[0,0]},t.prototype.jO=function(t){return this._getAnchorOffset(t.size||[0,0],"middle-center")},t.prototype.AO=function(t,e,r,n){var i,o=CONSTS.JM,u=void 0===(s=(n=void 0===n?{}:n).kO)?0:s,c=void 0!==(s=n.yO)&&s,s=n.padding,f=n.lines,h=(n=this.jO(t))[0]||0,n=n[1]||0,l=t.anchorOffset||[],d=l[0]||0,v=l[1]||0,g=(l=t.size||[])[0]||0,p=l[1]||0,y=d-h,m=v-n,b=s[0],T=s[1],A=s[2],x=s[3],M=.8*u;switch(r){case o.ZM:a=c?(i=y,v-A-.2*u-(S=M*f+3*(f-1))):(i=d+x,v+b);break;case o.QM:var S=M/2*f+1.5*(f-1),a=c?(i=d+g+x,m-S):(i=d-T,v-S-A);break;case o.tj:a=c?(i=y,v+p+b):(i=d+x,v-A-(S=M*f+3*(f-1)));break;case o.LEFT:S=M/2*f+1.5*(f-1);a=c?(i=d-T,m-S):(i=d+x,v-S-A);break;case o.nj:case o.ij:a=c?(i=d+g/2,m-(S=M/2*f+1.5*(f-1))):(i=d,v-(S=M/2*f+1.5*(f-1))-A);break;default:i=d,a=v-(S=M/2*f+1.5*(f-1))-A}return[i,a]},t.prototype.OO=function(t,e){var r,n,i=CONSTS.JM,a=(e=void 0===e?{}:e).xO,o=(e.kO,e.yO),s=e.direction,u=e.lines,c=e.size,f=(e.IO,t[0]||0),h=t[1]||0;switch(this.mO(s,o).textAlign){case i.LEFT:r=f,n=h;break;case i.QM:r=f-a,n=h;break;case i.ij:r=f-a/2,n=h}return{x:r,y:n,w:a,h:this.TO(c,u),FO:f,_O:h}},t.prototype.mO=function(t,e){var r,n,i=CONSTS.JM;if(e)switch(t){case i.LEFT:r=i.QM;break;case i.QM:r=i.LEFT;break;case i.ZM:case i.tj:default:r=i.ij,n=i.tj}else switch(t){case i.LEFT:case i.ij:case i.QM:r=t,n=i.tj;break;case i.ZM:case i.tj:case i.nj:default:r=i.LEFT,n=t}return{textAlign:r,verticalAlign:n}},t.prototype.TO=function(t,e){return void 0===t&&(t=12),(t*=5/4)*(e=void 0===e?1:e)+3*(e-1)},t.prototype.CT=function(t,e){return this.Mf?this.Mf.measureText(t,e):this.NT?(this.NT.font=(e||12)+"px",this.NT.measureText(t.join("")).width):0},t.prototype.SO=function(t,e,r){var n,i,a,o,s,u,c,f;return e&&r.txt?(n=(o=CONSTS.sj.text).direction,i=o.offset,o=o.style,c=r.yO,s=r.CO,n=e.direction||n,i=e.offset||i,a=(e=e.style||o).fontSize||12,f=e.padding||o.padding,e=!1===e.fold?100:o.fj,o=r.txt.length,r=(s=this.Mf.lineBreak(r.txt,{fontSize:a,CO:s,type:r.BG||"ch",fj:e,YQ:this.NT,from:r.from})).lines.length,u=this.TO(a,1),s={xO:s.maxWidth,kO:u,yO:c,direction:n,padding:f,fj:e,lines:r,size:a,IO:o},u=this.AO(t,t.size,n,s),c=vector.add(u,i),f=vector.add(t.origin,c),e=this.OO(f,s),{origin:t.origin,offset:c,coords:f,start:e}):{origin:t.origin,offset:[0,0],coords:t.coords,start:{}}},t.prototype.EO=function(t,e,r){if(!e||!r.txt)return{offsetX:0,offsetY:0,w:0,h:0};var n,i,a=CONSTS.JM,o=CONSTS.sj,s=(t.coords,t.start),u=(t=void 0===(t=t.offset)?[]:t)[0],c=t[1],f=s.w,t=s.h,s=r.yO,o=(r=o.text).direction,r=r.style,o=e.direction||o,h=(e=(e.style||r).padding||r.padding)[0],r=e[1],l=e[2],d=e[3];if(s)switch(o){case a.ZM:n=u-f/2-d,i=c-h;break;case a.QM:n=u-d,i=c-h;break;case a.tj:n=u-f/2-d,i=c-h;break;case a.LEFT:n=u-f-d,i=c-h;break;case a.nj:case a.ij:n=u-f/2-d,i=c-h;break;default:n=u-f/2-d,i=c+l}else switch(o){case a.ZM:n=u-d,i=c+l;break;case a.QM:n=u-f-d,i=c+l;break;case a.tj:case a.LEFT:n=u-d,i=c+l;break;case a.nj:case a.ij:n=u-f/2-d,i=c-h;break;default:n=u-f/2-d,i=c+l}return{offsetX:n,offsetY:i,w:f+d+r,h:t+h+l}},t.prototype.fO=function(t,e,r,n){var i=(n=void 0===n?{}:n).from,a=n.center,o=e.data,s=e.opts||{},u=o.position,c=o.txt,s=s.icon,r=r.text,e=e.CO,f=this.oO().zoom,f=(a[2]=a[2]||0,i="inner"!==i||"relative"!==o.positionType&&LocalZoom<=f?vector.Ip(u,a):u,vector.add(i,[0,0])),a=!!s;return{origin:i,icon:u=this.wO(f,s&&s[0]),text:f=this.SO(u,r,{CO:e,txt:c,yO:a,BG:o.BG,from:n.from}),padding:this.EO(f,r,{txt:c,yO:a})}},t}(),LabelGroup=function(){function t(){this.oT={},this.index=1}return t.prototype.nT=function(t){var e,r,n,i,a;return t?(e=t.fontSize,a=void 0===(a=t.fillColor)?CONSTS.COLOR.Uj:a,r=void 0===(r=t.strokeColor)?CONSTS.COLOR.Uj:r,n=t.strokeWidth,i=t.backgroundColor,t=t.borderColor,a=labelsUtil.toString(a)+labelsUtil.toString(r)+(i?labelsUtil.toString(i):""+(t?labelsUtil.toString(t):""))+e+n,this.AS(a),this.oT[a]):""},t.prototype.AS=function(t){this.oT[t]||(this.oT[t]=this.index++)},t}(),labelGroup=new LabelGroup,isSupportFloat64Array="undefined"!=typeof Float64Array,isSupportFloat32Array$1="undefined"!=typeof Float32Array,RESIZE_MULTIPLIER=(isSupportFloat64Array?setMatrixArrayType(Float64Array):isSupportFloat32Array$1?setMatrixArrayType(Float32Array):(window.Float32Array=void 0,setMatrixArrayType(Array)),2),DEFAULT_CAPACITY=128,StructArray=function(){function t(){this.pM=!1,this.yM=-1,this.length=0}return t.Wb=function(t,e){return t.trim(),e&&(t.pM=!0,e.push(t.arrayBuffer)),{length:t.length,arrayBuffer:t.arrayBuffer}},t.Gb=function(t){var e=Object.create(this.prototype);return e.arrayBuffer=t.arrayBuffer,e.length=t.length,e.yM=t.arrayBuffer.byteLength/this.Rb,e.mM(),e},t.prototype.trim=function(){this.length!==this.yM&&(this.yM=this.length,this.arrayBuffer=this.arrayBuffer.slice(0,this.length*this.constructor.Rb),this.mM())},t.prototype.resize=function(t){this.gM(t),this.length=t},t.prototype.gM=function(t){t>this.yM&&(this.yM=Math.max(t,Math.floor(this.yM*RESIZE_MULTIPLIER),DEFAULT_CAPACITY),t=this.wM,this.arrayBuffer=new ArrayBuffer(this.yM*this.constructor.Rb),this.mM(),t)&&this.wM.set(t)},t}(),FillArray=function(e){function t(){var t=e.call(this)||this;return t.pM=!1,t.resize(0),t}return __extends(t,e),t.prototype.kb=function(t,e){var r=this.length;this.resize(this.length+1),this.MM(r,t,e)},t.prototype.MM=function(t,e,r){this.Mb[t*=2]=e,this.Mb[1+t]=r},t.prototype.mM=function(){this.wM=new Uint8Array(this.arrayBuffer),this.Mb=new Float32Array(this.arrayBuffer)},t.Rb=8,t}(StructArray),FillExtrusionArray=function(e){function t(){var t=e.call(this)||this;return t.pM=!1,t.resize(0),t}return __extends(t,e),t.prototype.kb=function(t,e,r,n,i,a){var o=this.length;this.resize(o+1),this.MM(o,t,e,r,n,i,a)},t.prototype.MM=function(t,e,r,n,i,a,o){var s=8*t,e=(this.Mb[s]=e,this.Mb[1+s]=r,this.Mb[2+s]=n,this.Mb[3+s]=i,this.Mb[4+s]=a[0],this.Mb[5+s]=a[1],this.Mb[6+s]=a[2],16*t);this.jM[14+e]=o[0],this.jM[15+e]=o[1]},t.prototype.mM=function(){this.wM=new Uint8Array(this.arrayBuffer),this.Mb=new Float32Array(this.arrayBuffer),this.jM=new Uint16Array(this.arrayBuffer)},t.Rb=32,t}(StructArray),LinesIndexArray=function(e){function t(){var t=e.call(this)||this;return t.length=0,t.resize(0),t}return __extends(t,e),t.prototype.kb=function(t,e){var r=this.length;this.resize(this.length+1),this.MM(r,t,e)},t.prototype.MM=function(t,e,r){this.jM[t*=2]=e,this.jM[1+t]=r},t.prototype.mM=function(){this.wM=new Uint8Array(this.arrayBuffer),this.jM=new Uint16Array(this.arrayBuffer)},t.Rb=4,t}(StructArray),LinesIndexArrayUint=function(e){function t(){var t=e.call(this)||this;return t.length=0,t.resize(0),t}return __extends(t,e),t.prototype.kb=function(t,e){var r=this.length;this.resize(this.length+1),this.MM(r,t,e)},t.prototype.MM=function(t,e,r){this.UI[t*=2]=e,this.UI[1+t]=r},t.prototype.mM=function(){this.wM=new Uint8Array(this.arrayBuffer),this.UI=new Uint32Array(this.arrayBuffer)},t.Rb=8,t}(StructArray),LineArrayBuffer=function(e){function t(){var t=e.call(this)||this;return t.resize(0),t}return __extends(t,e),t.prototype.kb=function(t,e,r,n){var i=this.length;this.resize(i+1),this.MM(i,t,e,r,n)},t.prototype.MM=function(t,e,r,n,i){t*=this.constructor.Rb/4,this.Mb[t]=e[0],this.Mb[1+t]=e[1],this.Mb[2+t]=r[0],this.Mb[3+t]=r[1],this.Mb[4+t]=n,this.Mb[5+t]=i[0],this.Mb[6+t]=i[1]},t.prototype.mM=function(){this.wM=new Uint8Array(this.arrayBuffer),this.Mb=new Float32Array(this.arrayBuffer)},t.Rb=28,t}(StructArray),TriangleIndexArray=function(e){function t(){var t=e.call(this)||this;return t.resize(0),t}return __extends(t,e),t.prototype.kb=function(t,e,r){var n=this.length;this.resize(n+1),this.MM(n,t,e,r)},t.prototype.MM=function(t,e,r,n){this.jM[t*=3]=e,this.jM[1+t]=r,this.jM[2+t]=n},t.prototype.mM=function(){this.wM=new Uint8Array(this.arrayBuffer),this.jM=new Uint16Array(this.arrayBuffer)},t.Rb=6,t}(StructArray),TriangleIndexArrayUint=function(e){function t(){var t=e.call(this)||this;return t.resize(0),t}return __extends(t,e),t.prototype.kb=function(t,e,r){var n=this.length;this.resize(n+1),this.MM(n,t,e,r)},t.prototype.MM=function(t,e,r,n){this.UI[t*=3]=e,this.UI[1+t]=r,this.UI[2+t]=n},t.prototype.mM=function(){this.wM=new Uint8Array(this.arrayBuffer),this.UI=new Uint32Array(this.arrayBuffer)},t.Rb=12,t}(StructArray),SymbolArray=function(e){function t(){var t=e.call(this)||this;return t.pM=!1,t.resize(0),t}return __extends(t,e),t.prototype.kb=function(t,e,r){var n=this.length;this.resize(this.length+1),this.MM(n,t,e,r)},t.prototype.MM=function(t,e,r,n){var t=13*t,e=(this.Mb[t]=e,this.Mb[1+t]=r,n.color),r=n.borderColor,i=n.radius,a=n.borderWidth;this.Mb[2+t]=i,this.Mb[3+t]=a,this.Mb[4+t]=e[0],this.Mb[5+t]=e[1],this.Mb[6+t]=e[2],this.Mb[7+t]=e[3],this.Mb[8+t]=r[0],this.Mb[9+t]=r[1],this.Mb[10+t]=r[2],this.Mb[11+t]=r[3],this.Mb[12+t]=+(n.visible&&n.filter)},t.prototype.mM=function(){this.wM=new Uint8Array(this.arrayBuffer),this.Mb=new Float32Array(this.arrayBuffer)},t.Rb=52,t}(StructArray),SimpleSymbolArray=function(e){function t(){var t=e.call(this)||this;return t.pM=!1,t.resize(0),t}return __extends(t,e),t.prototype.kb=function(t,e){var r=this.length;this.resize(this.length+1),this.MM(r,t,e)},t.prototype.MM=function(t,e,r){this.Mb[t*=2]=e,this.Mb[1+t]=r},t.prototype.mM=function(){this.wM=new Uint8Array(this.arrayBuffer),this.Mb=new Float32Array(this.arrayBuffer)},t.Rb=4,t}(StructArray),SmartArrayBuffer=function(){function t(t,e,r,n){void 0===n&&(n="ARRAY_BUFFER"),this.AM=t,this.kM=r,this.type=n,t&&(this.buffer="ARRAY_BUFFER"===n?t.fe(e,r,"DYNAMIC_DRAW"):t.ve(e),this.uf=e.byteLength,this.byteLength=e.byteLength)}return t.prototype.update=function(t){var e,r,n;0!==t.length&&this.AM&&(e="ARRAY_BUFFER"===this.type,r=this.AM.gl,n=(e?this.AM.de:this.AM.me).current,(e?this.AM.de:this.AM.me).set(this.buffer),this.uf<t.byteLength?(r.bufferData(r[this.type],t,r.STATIC_DRAW),this.byteLength=t.byteLength,this.uf=t.byteLength):(r.bufferSubData(r[this.type],0,t),this.byteLength=t.byteLength),(e?this.AM.de:this.AM.me).set(n))},t.prototype.destroy=function(){this.buffer&&this.AM&&this.AM.deleteBuffer(this.buffer)},t.prototype.TX=function(){this.AM=null},__decorate([InnerClass("SmartArrayBuffer")],t)}(),COS_HALF_SHARP_CORNER=Math.cos(Math.PI/180*75),prepMatClockwise=fromValues(0,-1,1,0),perpMatCounterClockwise=fromValues(0,1,-1,0);function perpCounterClockwise(t,e){transformMat2(t,e,perpMatCounterClockwise)}function perpClockwise(t,e){transformMat2(t,e,prepMatClockwise)}var minRoundAngle=Math.PI/9,emptyVec2=create$3(),emptyVec3=create$1(),prevPos=create$3(),currentPos=create$3(),nextPos=create$3(),tmpPos=create$3(),currentNormal=create$3(),nextNormal=create$3(),distance$1=0,nextDir=create$3(),currentDir=create$3(),negateCurrentNormal=create$3(),lineJoin,lineCap,currentNormal_addLineVertex=create$3(),leftNormal=create$3(),rightNormal=create$3(),offsetLeft=create$3(),offsetRight=create$3(),joinNormal_addMiter=create$3(),tmp_addTiangleVertex=create$1(),currentNormal_addTiangleVertex=create$3(),nextNormal_addTiangleVertex=create$3(),normal_addTiangleVertex=create$3(),tmp_addRoundVertex=create$1(),currentNormal_addRoundVertex=create$3(),nextNormal_addRoundVertex=create$3(),tmpNormal_addRoundVertex=create$3(),roundCenter_addRoundVertex=create$3(),CoreLineBucket=function(){function h(){this._b=new LineArrayBuffer,this.e1=this.e2=this.e3=-1,this.uploaded=!1}return h.OM=function(t,e,r){sub$1(t,e,r),normalize(t,t),perpCounterClockwise(t,t)},h.xM=function(t,e,r){add(t,e,r),0===t[0]&&0===t[1]||normalize(t,t)},h.prototype.hb=function(t,e){if(t.length<4)return{Iw:0,distance:0};"auto"===(e=void(distance$1=0)===e?{X_:1,lineJoin:"miter",lineCap:"butt"}:e).lineJoin&&(e.lineJoin="miter"),lineJoin=e.lineJoin,lineCap=e.lineCap||"butt";for(var r,n=this.Qx.length,i=0,a=t.length;i<a;i+=2)0===i?(currentPos[0]=t[i],currentPos[1]=t[i+1],nextPos[0]=t[i+2],nextPos[1]=t[i+3],h.OM(nextNormal,nextPos,currentPos),copy$1(currentNormal,nextNormal),sub$1(nextDir,nextPos,currentPos),normalize(nextDir,nextDir),"square"===lineCap?this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!0,e.X_,"bevel"):("round"===lineCap&&(copy$1(negateCurrentNormal,currentNormal),negate(negateCurrentNormal,currentNormal),this.DI(currentPos,negateCurrentNormal,currentNormal,distance$1)),this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!0,0,"bevel")),copy$1(currentDir,nextDir),copy$1(prevPos,currentPos)):i===a-2?(currentPos[0]=t[i],currentPos[1]=t[i+1],r=dist$1(currentPos,prevPos),distance$1+=r,"square"===lineCap?this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!1,-1*e.X_,"miter"):"round"===lineCap?(this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!1,0,"miter"),copy$1(negateCurrentNormal,nextNormal),negate(negateCurrentNormal,nextNormal),this.DI(currentPos,nextNormal,negateCurrentNormal,distance$1)):this.IM(currentPos,currentNormal,nextNormal,distance$1,currentDir,!1,0,"miter")):(currentPos[0]=t[i],currentPos[1]=t[i+1],nextPos[0]=t[i+2],nextPos[1]=t[i+3],h.OM(nextNormal,nextPos,currentPos),0===nextNormal[0]&&0===nextNormal[1]||(r=dist$1(currentPos,prevPos),distance$1+=r,sub$1(nextDir,nextPos,currentPos),normalize(nextDir,nextDir),this.IM(currentPos,currentNormal,nextNormal,distance$1,currentDir,!1,0,e.lineJoin),this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!0,0,e.lineJoin),copy$1(prevPos,currentPos),copy$1(currentNormal,nextNormal),copy$1(currentDir,nextDir)));return{Iw:3*(this.Qx.length-n),distance:distance$1}},h.prototype.g0=function(t,e){if(t.length<2)return{Iw:0,distance:0};"auto"===(e=void(distance$1=0)===e?{X_:1,lineJoin:"miter",lineCap:"butt"}:e).lineJoin&&(e.lineJoin="miter"),lineJoin=e.lineJoin,lineCap=e.lineCap||"butt";for(var r,n=this.Qx.length,i=0,a=t.length;i<a;i++)0===i?(currentPos[0]=t[i][0],currentPos[1]=t[i][1],nextPos[0]=t[i+1][0],nextPos[1]=t[i+1][1],h.OM(nextNormal,nextPos,currentPos),copy$1(currentNormal,nextNormal),sub$1(nextDir,nextPos,currentPos),normalize(nextDir,nextDir),"square"===lineCap?this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!0,e.X_,"bevel"):("round"===lineCap&&(copy$1(negateCurrentNormal,currentNormal),negate(negateCurrentNormal,currentNormal),this.DI(currentPos,negateCurrentNormal,currentNormal,distance$1)),this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!0,0,"bevel")),copy$1(currentDir,nextDir),copy$1(prevPos,currentPos)):i===a-1?(currentPos[0]=t[i][0],currentPos[1]=t[i][1],r=dist$1(currentPos,prevPos),distance$1+=r,"square"===lineCap?this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!1,-1*e.X_,"miter"):"round"===lineCap?(this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!1,0,"miter"),copy$1(negateCurrentNormal,nextNormal),negate(negateCurrentNormal,nextNormal),this.DI(currentPos,nextNormal,negateCurrentNormal,distance$1)):this.IM(currentPos,currentNormal,nextNormal,distance$1,currentDir,!1,0,"miter")):(currentPos[0]=t[i][0],currentPos[1]=t[i][1],nextPos[0]=t[i+1][0],nextPos[1]=t[i+1][1],h.OM(nextNormal,nextPos,currentPos),0===nextNormal[0]&&0===nextNormal[1]||(r=dist$1(currentPos,prevPos),distance$1+=r,sub$1(nextDir,nextPos,currentPos),normalize(nextDir,nextDir),this.IM(currentPos,currentNormal,nextNormal,distance$1,currentDir,!1,0,e.lineJoin),this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!0,0,e.lineJoin),copy$1(prevPos,currentPos),copy$1(currentNormal,nextNormal),copy$1(currentDir,nextDir)));return{Iw:3*(this.Qx.length-n),distance:distance$1}},h.prototype.eD=function(t,e,r){if(void 0===r&&(r=3e3),t.length<4)return{Iw:0,distance:0};"auto"===(e=void(distance$1=0)===e?{X_:1,lineJoin:"miter",lineCap:"butt"}:e).lineJoin&&(e.lineJoin="miter"),lineJoin=e.lineJoin,lineCap=e.lineCap||"butt";for(var n=this.Qx.length,i=0,a=t.length;i<a;i+=2)if(0===i)currentPos[0]=t[i],currentPos[1]=t[i+1],nextPos[0]=t[i+2],nextPos[1]=t[i+3],h.OM(nextNormal,nextPos,currentPos),copy$1(currentNormal,nextNormal),sub$1(nextDir,nextPos,currentPos),normalize(nextDir,nextDir),"square"===lineCap?this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!0,e.X_,"bevel"):("round"===lineCap&&(copy$1(negateCurrentNormal,currentNormal),negate(negateCurrentNormal,currentNormal),this.DI(currentPos,negateCurrentNormal,currentNormal,distance$1)),this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!0,0,"bevel")),copy$1(currentDir,nextDir),copy$1(prevPos,currentPos);else if(i===a-2){tmpPos[0]=t[i],tmpPos[1]=t[i+1];var o=dist$1(tmpPos,prevPos);copy$1(tmpPos,prevPos);for(var s=0;r<o-s;)tmpPos[0]=tmpPos[0]+currentDir[0]*r,tmpPos[1]=tmpPos[1]+currentDir[1]*r,s+=r,this.IM(tmpPos,currentNormal,nextNormal,distance$1+s,currentDir,!1,0,"miter"),this.IM(tmpPos,currentNormal,nextNormal,distance$1+s,currentDir,!0,0,"miter");currentPos[0]=t[i],currentPos[1]=t[i+1],distance$1+=o,"square"===lineCap?this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!1,-1*e.X_,"miter"):"round"===lineCap?(this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!1,0,"miter"),copy$1(negateCurrentNormal,nextNormal),negate(negateCurrentNormal,nextNormal),this.DI(currentPos,nextNormal,negateCurrentNormal,distance$1)):this.IM(currentPos,currentNormal,nextNormal,distance$1,currentDir,!1,0,"miter")}else if(currentPos[0]=t[i],currentPos[1]=t[i+1],nextPos[0]=t[i+2],nextPos[1]=t[i+3],h.OM(nextNormal,nextPos,currentPos),0!==nextNormal[0]||0!==nextNormal[1]){var u=dist$1(currentPos,prevPos);for(copy$1(tmpPos,prevPos),s=0;r<u-s;)tmpPos[0]=tmpPos[0]+currentDir[0]*r,tmpPos[1]=tmpPos[1]+currentDir[1]*r,s+=r,this.IM(tmpPos,currentNormal,currentNormal,distance$1+s,currentDir,!1,0,"miter"),this.IM(tmpPos,currentNormal,currentNormal,distance$1+s,currentDir,!0,0,"miter");currentPos[0]=t[i],currentPos[1]=t[i+1],distance$1+=u,sub$1(nextDir,nextPos,currentPos),normalize(nextDir,nextDir),this.IM(currentPos,currentNormal,nextNormal,distance$1,currentDir,!1,0,e.lineJoin),this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!0,0,e.lineJoin),copy$1(prevPos,currentPos),copy$1(currentNormal,nextNormal),copy$1(currentDir,nextDir)}return{Iw:3*(this.Qx.length-n),distance:distance$1}},h.prototype.Nx=function(t,e){if(void 0===e&&(e={lineJoin:"miter"}),t.length<2)return{Iw:0,distance:0};for(var r,n,i=this.Qx.length,a=0,o=t.length;a<o;a++)0===a?(copy$1(currentPos,t[a]),r=t[a+1],n=t[o-2],h.OM(nextNormal,r,currentPos),h.OM(currentNormal,currentPos,n),sub$1(nextDir,r,currentPos),normalize(nextDir,nextDir),this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!0,0,e.lineJoin),copy$1(currentDir,nextDir),copy$1(currentNormal,nextNormal),copy$1(prevPos,currentPos)):a===o-1?(copy$1(currentPos,t[a]),copy$1(nextPos,t[1]),distance$1+=dist$1(currentPos,prevPos),h.OM(nextNormal,nextPos,currentPos),this.IM(currentPos,currentNormal,nextNormal,distance$1,currentDir,!1,0,e.lineJoin)):(copy$1(currentPos,t[a]),copy$1(nextPos,t[a+1]),distance$1+=dist$1(currentPos,prevPos),h.OM(nextNormal,nextPos,currentPos),sub$1(nextDir,nextPos,currentPos),normalize(nextDir,nextDir),this.IM(currentPos,currentNormal,nextNormal,distance$1,currentDir,!1,0,e.lineJoin),this.IM(currentPos,currentNormal,nextNormal,distance$1,nextDir,!0,0,e.lineJoin),copy$1(prevPos,currentPos),copy$1(currentNormal,nextNormal),copy$1(currentDir,nextDir));return{Iw:3*(this.Qx.length-i),distance:distance$1}},h.prototype.destroy=function(){this.uploaded=!1,this.zs&&(this.zs.destroy(),delete this.zs),this.Pc&&(this.Pc.destroy(),delete this.Pc)},h.prototype.IM=function(t,e,r,n,i,a,o,s){copy$1(joinNormal_addMiter,emptyVec2),h.xM(joinNormal_addMiter,e,r);var u=dot(joinNormal_addMiter,e),c=(scale$2(joinNormal_addMiter,joinNormal_addMiter,1/u),0),f=0;o&&(f=c=o),"bevel"===s||"miter"===s&&u<COS_HALF_SHARP_CORNER?a?this.SM(t,r,n,c,f,i):(this.SM(t,e,n,c,f,i),this.e3=this._b.length-2,this.e2=this.e3-1,this.e1=this.e2-1,this.Qx.kb(this.e1,this.e2,this.e3),this.e1=this.e2,this.e2=this.e3,this.e3=this.e3+1,this.Qx.kb(this.e1,this.e2,this.e3),this.CM(t,e,r,n)):"round"===s?a?this.SM(t,r,n,c,f,i):(this.SM(t,e,n,c,f,i),this.e3=this._b.length-2,this.e2=this.e3-1,this.e1=this.e2-1,this.Qx.kb(this.e1,this.e2,this.e3),this.e1=this.e2,this.e2=this.e3,this.e3=this.e3+1,this.Qx.kb(this.e1,this.e2,this.e3),this.DI(t,e,r,n)):(this.SM(t,joinNormal_addMiter,n,c,f,i),a||(this.e3=this._b.length-2,this.e2=this.e3-1,this.e1=this.e2-1,this.Qx.kb(this.e1,this.e2,this.e3),this.e1=this.e2,this.e2=this.e3,this.e3=this.e3+1,this.Qx.kb(this.e1,this.e2,this.e3)))},h.prototype.SM=function(t,e,r,n,i,a){copy$1(currentNormal_addLineVertex,e),copy$1(leftNormal,currentNormal_addLineVertex),copy$1(rightNormal,currentNormal_addLineVertex),copy$1(offsetLeft,emptyVec2),copy$1(offsetRight,emptyVec2),scale$2(rightNormal,currentNormal_addLineVertex,-1),n&&(perpCounterClockwise(offsetLeft,leftNormal),scale$2(offsetLeft,offsetLeft,n),add(leftNormal,offsetLeft,leftNormal)),i&&(perpClockwise(offsetRight,rightNormal),scale$2(offsetRight,offsetRight,i),add(rightNormal,offsetRight,rightNormal)),this._b.kb(t,leftNormal,r,a),this._b.kb(t,rightNormal,r,a)},h.prototype.CM=function(t,e,r,n){void 0===n&&(n=0),copy(tmp_addTiangleVertex,emptyVec3),copy$1(currentNormal_addTiangleVertex,e),copy$1(nextNormal_addTiangleVertex,r),copy$1(normal_addTiangleVertex,emptyVec2),cross$1(tmp_addTiangleVertex,currentNormal_addTiangleVertex,nextNormal_addTiangleVertex),e=0<tmp_addTiangleVertex[2],this._b.kb(t,normal_addTiangleVertex,n,normal_addTiangleVertex),e&&(negate(currentNormal_addTiangleVertex,currentNormal_addTiangleVertex),negate(nextNormal_addTiangleVertex,nextNormal_addTiangleVertex)),this._b.kb(t,currentNormal_addTiangleVertex,n,normal_addTiangleVertex),this._b.kb(t,nextNormal_addTiangleVertex,n,normal_addTiangleVertex),this.e3=this._b.length-1,this.e2=this.e3-1,this.e1=this.e2-1,this.Qx.kb(this.e1,this.e2,this.e3)},h.prototype.DI=function(t,e,r,n){void 0===n&&(n=0),copy(tmp_addRoundVertex,emptyVec3),copy$1(currentNormal_addRoundVertex,e),copy$1(nextNormal_addRoundVertex,r);var i=angle(currentNormal_addRoundVertex,nextNormal_addRoundVertex),a=(cross$1(tmp_addRoundVertex,currentNormal_addRoundVertex,nextNormal_addRoundVertex),0<tmp_addRoundVertex[2]),o=[];o.push(currentNormal_addRoundVertex);for(var s=minRoundAngle;s<i;s+=minRoundAngle){var u=create$3();rotate(u,currentNormal_addRoundVertex,fromValues$3(0,0),a?s:-1*s),o.push(u)}o.push(nextNormal_addRoundVertex),a&&forEach(o,function(t){negate(t,t)}),copy$1(roundCenter_addRoundVertex,emptyVec2),this._b.kb(t,roundCenter_addRoundVertex,n,roundCenter_addRoundVertex);var c=this._b.length-1;this._b.kb(t,o[0],n,roundCenter_addRoundVertex),this.e3=this._b.length-1,this.e2=this.e3-1;for(var f=1,h=o.length;f<h;f++)this._b.kb(t,o[f],n,roundCenter_addRoundVertex),this.e3=this._b.length-1,this.e2=this.e3-1,this.Qx.kb(c,this.e2,this.e3)},h}(),PolylineBucket=function(e){function t(){var t=e.call(this)||this;return t.Qx=new TriangleIndexArrayUint,t}return __extends(t,e),t.prototype.upload=function(t,e){void 0===e&&(e=!1),this.uploaded||(this.uploaded=!0,this.zs?this.zs.update(this._b.Mb):this.zs=new SmartArrayBuffer(t,this._b.Mb,LineArrayBuffer.Rb),this.Pc?this.Pc.update(this.Qx.UI):this.Pc=new SmartArrayBuffer(t,this.Qx.UI,32,"ELEMENT_ARRAY_BUFFER"),e&&(delete this.Qx,delete this._b))},t.prototype.reset=function(){this.uploaded=!1,this._b=new LineArrayBuffer,this.Qx=new TriangleIndexArrayUint,this.e1=this.e2=this.e3=-1,this.uploaded=!1},t}(CoreLineBucket),earcut_1=earcut,default_1$1=earcut;function earcut(t,e,r){r=r||2;var n,i,a,o,s,u=e&&e.length,c=u?e[0]*r:t.length,f=linkedList(t,0,c,r,!0),h=[];if(f&&f.next!==f.NM){if(u&&(f=eliminateHoles(t,e,f,r)),t.length>80*r){for(var l=n=t[0],d=i=t[1],v=r;v<c;v+=r)(a=t[v])<l&&(l=a),(o=t[v+1])<d&&(d=o),n<a&&(n=a),i<o&&(i=o);s=0!==(s=Math.max(n-l,i-d))?32767/s:0}earcutLinked(f,h,r,l,d,s,0)}return h}function linkedList(t,e,r,n,i){var a,o;if(i===0<signedArea(t,e,r,n))for(a=e;a<r;a+=n)o=insertNode(a,t[a],t[a+1],o);else for(a=r-n;e<=a;a-=n)o=insertNode(a,t[a],t[a+1],o);return o&&equals$2(o,o.next)&&(removeNode(o),o=o.next),o}function filterPoints(t,e){if(!t)return t;e=e||t;var r,n=t;do{if(r=!1,n.LM||!equals$2(n,n.next)&&0!==area(n.NM,n,n.next))n=n.next;else{if(removeNode(n),(n=e=n.NM)===n.next)break;r=!0}}while(r||n!==e);return e}function earcutLinked(t,e,r,n,i,a,o){if(t){!o&&a&&indexCurve(t,n,i,a);for(var s,u,c=t;t.NM!==t.next;)if(s=t.NM,u=t.next,a?isEarHashed(t,n,i,a):isEar(t))e.push(s.i/r|0),e.push(t.i/r|0),e.push(u.i/r|0),removeNode(t),t=u.next,c=u.next;else if((t=u)===c){o?1===o?earcutLinked(t=cureLocalIntersections(filterPoints(t),e,r),e,r,n,i,a,2):2===o&&splitEarcut(t,e,r,n,i,a):earcutLinked(filterPoints(t),e,r,n,i,a,1);break}}}function isEar(t){var e=t.NM,r=t;if(!(0<=area(e,r,t=t.next))){for(var n=e.x,i=r.x,a=t.x,o=e.y,s=r.y,u=t.y,c=n<i?n<a?n:a:i<a?i:a,f=o<s?o<u?o:u:s<u?s:u,h=i<n?a<n?n:a:a<i?i:a,l=s<o?u<o?o:u:u<s?s:u,d=t.next;d!==e;){if(d.x>=c&&d.x<=h&&d.y>=f&&d.y<=l&&pointInTriangle(n,o,i,s,a,u,d.x,d.y)&&0<=area(d.NM,d,d.next))return;d=d.next}return 1}}function isEarHashed(t,e,r,n){var i=t.NM,a=t,o=t.next;if(!(0<=area(i,a,o))){for(var s=i.x,u=a.x,c=o.x,f=i.y,h=a.y,l=o.y,d=s<u?s<c?s:c:u<c?u:c,v=f<h?f<l?f:l:h<l?h:l,g=u<s?c<s?s:c:c<u?u:c,p=h<f?l<f?f:l:l<h?h:l,y=zOrder(d,v,e,r,n),m=zOrder(g,p,e,r,n),b=t.DM,T=t.RM;b&&b.z>=y&&T&&T.z<=m;){if(b.x>=d&&b.x<=g&&b.y>=v&&b.y<=p&&b!==i&&b!==o&&pointInTriangle(s,f,u,h,c,l,b.x,b.y)&&0<=area(b.NM,b,b.next))return;if(b=b.DM,T.x>=d&&T.x<=g&&T.y>=v&&T.y<=p&&T!==i&&T!==o&&pointInTriangle(s,f,u,h,c,l,T.x,T.y)&&0<=area(T.NM,T,T.next))return;T=T.RM}for(;b&&b.z>=y;){if(b.x>=d&&b.x<=g&&b.y>=v&&b.y<=p&&b!==i&&b!==o&&pointInTriangle(s,f,u,h,c,l,b.x,b.y)&&0<=area(b.NM,b,b.next))return;b=b.DM}for(;T&&T.z<=m;){if(T.x>=d&&T.x<=g&&T.y>=v&&T.y<=p&&T!==i&&T!==o&&pointInTriangle(s,f,u,h,c,l,T.x,T.y)&&0<=area(T.NM,T,T.next))return;T=T.RM}return 1}}function cureLocalIntersections(t,e,r){var n=t;do{var i=n.NM,a=n.next.next}while(!equals$2(i,a)&&intersects$1(i,n,n.next,a)&&locallyInside(i,a)&&locallyInside(a,i)&&(e.push(i.i/r|0),e.push(n.i/r|0),e.push(a.i/r|0),removeNode(n),removeNode(n.next),n=t=a),(n=n.next)!==t);return filterPoints(n)}function splitEarcut(t,e,r,n,i,a){var o=t;do{for(var s,u=o.next.next;u!==o.NM;){if(o.i!==u.i&&isValidDiagonal(o,u))return s=splitPolygon(o,u),o=filterPoints(o,o.next),s=filterPoints(s,s.next),earcutLinked(o,e,r,n,i,a,0),earcutLinked(s,e,r,n,i,a,0);u=u.next}}while((o=o.next)!==t)}function eliminateHoles(t,e,r,n){for(var i,a=[],o=0,s=e.length;o<s;o++)(i=linkedList(t,e[o]*n,o<s-1?e[o+1]*n:t.length,n,!1))===i.next&&(i.LM=!0),a.push(getLeftmost(i));for(a.sort(compareX),o=0;o<a.length;o++)r=eliminateHole(a[o],r);return r}function compareX(t,e){return t.x-e.x}function eliminateHole(t,e){var r=findHoleBridge(t,e);return r?(filterPoints(t=splitPolygon(r,t),t.next),filterPoints(r,r.next)):e}function findHoleBridge(t,e){var r,n=e,i=t.x,a=t.y,o=-1/0;do{if(a<=n.y&&a>=n.next.y&&n.next.y!==n.y){var s=n.x+(a-n.y)*(n.next.x-n.x)/(n.next.y-n.y);if(s<=i&&o<s&&(r=n.x<n.next.x?n:n.next,(o=s)===i))return r}}while((n=n.next)!==e);if(!r)return null;for(var u,c=r,f=r.x,h=r.y,l=1/0,n=r;i>=n.x&&n.x>=f&&i!==n.x&&pointInTriangle(a<h?i:o,a,f,h,a<h?o:i,a,n.x,n.y)&&(u=Math.abs(a-n.y)/(i-n.x),locallyInside(n,t))&&(u<l||u===l&&(n.x>r.x||n.x===r.x&§orContainsSector(r,n)))&&(r=n,l=u),(n=n.next)!==c;);return r}function sectorContainsSector(t,e){return area(t.NM,t,e.NM)<0&&area(e.next,t,t.next)<0}function indexCurve(t,e,r,n){for(var i=t;0===i.z&&(i.z=zOrder(i.x,i.y,e,r,n)),i.DM=i.NM,i.RM=i.next,(i=i.next)!==t;);i.DM.RM=null,i.DM=null,sortLinked(i)}function sortLinked(t){var e,r,n,i,a,o,s,u,c=1;do{for(r=t,a=t=null,o=0;r;){for(o++,n=r,e=s=0;e<c&&(s++,n=n.RM);e++);for(u=c;0<s||0<u&&n;)0!==s&&(0===u||!n||r.z<=n.z)?(r=(i=r).RM,s--):(n=(i=n).RM,u--),a?a.RM=i:t=i,i.DM=a,a=i;r=n}}while(a.RM=null,c*=2,1<o)}function zOrder(t,e,r,n,i){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=(t-r)*i|0)|t<<8))|t<<4))|t<<2))|t<<1))|(1431655765&((e=858993459&((e=252645135&((e=16711935&((e=(e-n)*i|0)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function getLeftmost(t){for(var e=t,r=t;(e.x<r.x||e.x===r.x&&e.y<r.y)&&(r=e),(e=e.next)!==t;);return r}function pointInTriangle(t,e,r,n,i,a,o,s){return(t-o)*(a-s)<=(i-o)*(e-s)&&(r-o)*(e-s)<=(t-o)*(n-s)&&(i-o)*(n-s)<=(r-o)*(a-s)}function isValidDiagonal(t,e){return t.next.i!==e.i&&t.NM.i!==e.i&&!intersectsPolygon(t,e)&&(locallyInside(t,e)&&locallyInside(e,t)&&middleInside(t,e)&&(area(t.NM,t,e.NM)||area(t,e.NM,e))||equals$2(t,e)&&0<area(t.NM,t,t.next)&&0<area(e.NM,e,e.next))}function area(t,e,r){return(e.y-t.y)*(r.x-e.x)-(e.x-t.x)*(r.y-e.y)}function equals$2(t,e){return t.x===e.x&&t.y===e.y}function intersects$1(t,e,r,n){var i=sign(area(t,e,r)),a=sign(area(t,e,n)),o=sign(area(r,n,t)),s=sign(area(r,n,e));return i!==a&&o!==s||0===i&&onSegment(t,r,e)||0===a&&onSegment(t,n,e)||0===o&&onSegment(r,t,n)||0===s&&onSegment(r,e,n)}function onSegment(t,e,r){return e.x<=Math.max(t.x,r.x)&&e.x>=Math.min(t.x,r.x)&&e.y<=Math.max(t.y,r.y)&&e.y>=Math.min(t.y,r.y)}function sign(t){return 0<t?1:t<0?-1:0}function intersectsPolygon(t,e){var r=t;do{if(r.i!==t.i&&r.next.i!==t.i&&r.i!==e.i&&r.next.i!==e.i&&intersects$1(r,r.next,t,e))return 1}while((r=r.next)!==t)}function locallyInside(t,e){return area(t.NM,t,t.next)<0?0<=area(t,e,t.next)&&0<=area(t,t.NM,e):area(t,e,t.NM)<0||area(t,t.next,e)<0}function middleInside(t,e){for(var r=t,n=!1,i=(t.x+e.x)/2,a=(t.y+e.y)/2;r.y>a!=r.next.y>a&&r.next.y!==r.y&&i<(r.next.x-r.x)*(a-r.y)/(r.next.y-r.y)+r.x&&(n=!n),(r=r.next)!==t;);return n}function splitPolygon(t,e){var r=new Node(t.i,t.x,t.y),n=new Node(e.i,e.x,e.y),i=t.next,a=e.NM;return(t.next=e).NM=t,(r.next=i).NM=r,(n.next=r).NM=n,(a.next=n).NM=a,n}function insertNode(t,e,r,n){return t=new Node(t,e,r),n?(t.next=n.next,(t.NM=n).next.NM=t,n.next=t):(t.NM=t).next=t,t}function removeNode(t){t.next.NM=t.NM,t.NM.next=t.next,t.DM&&(t.DM.RM=t.RM),t.RM&&(t.RM.DM=t.DM)}function Node(t,e,r){this.i=t,this.x=e,this.y=r,this.NM=null,this.next=null,this.z=0,this.DM=null,this.RM=null,this.LM=!1}function signedArea(t,e,r,n){for(var i=0,a=e,o=r-n;a<r;a+=n)i+=(t[o]-t[a])*(t[a+1]+t[o+1]),o=a;return i}earcut.PM=function(t,e,r,n){var i=e&&e.length,a=i?e[0]*r:t.length,o=Math.abs(signedArea(t,0,a,r));if(i)for(var s=0,u=e.length;s<u;s++){var c=e[s]*r,f=s<u-1?e[s+1]*r:t.length;o-=Math.abs(signedArea(t,c,f,r))}for(var h=0,s=0;s<n.length;s+=3){var l=n[s]*r,d=n[s+1]*r,v=n[s+2]*r;h+=Math.abs((t[l]-t[v])*(t[1+d]-t[1+l])-(t[l]-t[d])*(t[1+v]-t[1+l]))}return 0===o&&0===h?0:Math.abs((h-o)/o)},earcut.UM=function(t){for(var e=t[0][0].length,r={rp:[],BM:[],dimensions:e},n=0,i=0;i<t.length;i++){for(var a=0;a<t[i].length;a++)for(var o=0;o<e;o++)r.rp.push(t[i][a][o]);0<i&&(n+=t[i-1].length,r.BM.push(n))}return r},earcut_1.default=default_1$1;var CoreFillBucket=function(){function t(){this._b=new FillArray,this.zM=new FillArray,this.uploaded=!1}return t.prototype.Nx=function(t,e){if(t.length<6)return 0;for(var r=this.Qx.length,n=this._b.length,i=earcut_1(t,e),a=0,o=i.length;a<o;a+=3)this.Qx.kb(n+i[a],n+i[a+1],n+i[a+2]);for(a=0,o=t.length;a<o;a+=2)this._b.kb(t[a],t[a+1]);return 0<(e=3*(this.Qx.length-r))&&(this.uploaded=!1),e},t.prototype.Ew=function(t){if(t.length<2)return 0;for(var e=this.qM.length,r=this.zM.length,n=0,i=t.length;n<i;n+=2)this.zM.kb(t[n][0],t[n][1]),this.zM.kb(t[n+1][0],t[n+1][1]),this.qM.kb(r+n,r+n+1);return 0<(e=2*(this.qM.length-e))&&(this.uploaded=!1),e},t.prototype.destroy=function(){this.uploaded=!1,this.zs&&(this.zs.context.deleteBuffer(this.zs),delete this.zs),this.Pc&&(this.Pc.context.deleteBuffer(this.Pc),delete this.Pc),this.Ec&&(this.Ec.context.deleteBuffer(this.Ec),delete this.Ec),this.Nc&&(this.Nc.context.deleteBuffer(this.Nc),delete this.Nc)},t}(),PolygonBucket=function(e){function t(){var t=e.call(this)||this;return t.Qx=new TriangleIndexArrayUint,t.qM=new LinesIndexArrayUint,t}return __extends(t,e),t.prototype.upload=function(t,e){void 0===e&&(e=!1),this.uploaded||(this.destroy(),this.uploaded=!0,this.zs=t.fe(this._b.Mb,FillArray.Rb),this.Pc=t.ve(this.Qx.UI),this.Ec=t.fe(this.zM.Mb,LinesIndexArray.Rb),this.Nc=t.ve(this.qM.UI),e&&(delete this.Qx,delete this._b,delete this.zM,delete this.qM))},t.prototype.reset=function(){this._b=new FillArray,this.zM=new FillArray,this.Qx=new TriangleIndexArrayUint,this.qM=new LinesIndexArrayUint,this.uploaded=!1},t}(CoreFillBucket),FaceTextureCoord={empty:fromValues$3(-1,-1),Gm:fromValues$3(1,1),qm:fromValues$3(0,1),Nm:fromValues$3(1,0),Um:fromValues$3(0,0)},MaxInfo={Gm:create$3(),qm:create$3(),Nm:create$3(),Um:create$3()},floorHeight=6,FillExtrusionBucket=function(){function t(){this._b=new FillExtrusionArray,this.uploaded=!1}return t.prototype.tz=function(t,e,r){void 0===e&&(e=100);for(var n=[],i=[],a=t.length,o=0;o<a;o+=2)i[s=o/2*3]=t[o],i[s+1]=t[o+1],i[s+2]=0;for(var s,o=0;o<a;o+=2)n[s=o/2*3]=t[o],n[s+1]=t[o+1],n[s+2]=e;return this.Nx(n,e,r)+this.RI(i,n,r)},t.prototype.RI=function(t,e,r){var n=e.length,i=e[2],a=this._b.length;t=t.concat(t.slice(0,3)),e=e.concat(e.slice(0,3));for(var o=0;o<n-3;o+=3){var s=Math.abs(t[o]-t[o+3]),u=Math.abs(t[o+1]-t[o+4]),c=Math.round(i),s=Math.round(Math.sqrt(Math.pow(s,2)+Math.pow(u,2))),s=(0<(u=fromValues$3(Math.ceil(s/floorHeight),Math.round(c/floorHeight)))[1]?(mul(MaxInfo.qm,FaceTextureCoord.qm,u),mul(MaxInfo.Gm,FaceTextureCoord.Gm,u),mul(MaxInfo.Um,FaceTextureCoord.Um,u),mul(MaxInfo.Nm,FaceTextureCoord.Nm,u)):(set$1(MaxInfo.qm,-1,-1),set$1(MaxInfo.Gm,-1,-1),set$1(MaxInfo.Um,-1,-1),set$1(MaxInfo.Nm,-1,-1)),this.zI(t.slice(o,o+3),t.slice(o+3,o+6),e.slice(o+3,o+6)));this._b.kb(t[o],t[o+1],t[o+2],i,s,MaxInfo.qm),this._b.kb(e[o+3],e[o+4],e[o+5],i,s,MaxInfo.Nm),this._b.kb(t[o+3],t[o+4],t[o+5],i,s,MaxInfo.Gm),this._b.kb(t[o],t[o+1],t[o+2],i,s,MaxInfo.qm),this._b.kb(e[o],e[o+1],e[o+2],i,s,MaxInfo.Um),this._b.kb(e[o+3],e[o+4],e[o+5],i,s,MaxInfo.Nm)}return 0<(a=this._b.length-a)&&(this.uploaded=!1),a},t.prototype.Nx=function(t,e,r){if(t.length<9)return 0;for(var n=this._b.length,i=earcut_1(t,r,3),a=i.length-1;0<=a;a--){var o=3*i[a];this._b.kb(t[o],t[1+o],t[2+o],e,fromValues$1(0,0,1),FaceTextureCoord.empty)}return 0<(r=this._b.length-n)&&(this.uploaded=!1),r},t.prototype.zI=function(t,e,r){var t=fromValues$1(t[0],t[1],t[2]),e=fromValues$1(e[0],e[1],e[2]),r=fromValues$1(r[0],r[1],r[2]),n=create$1(),i=create$1(),a=create$1();return sub(i,t,e),sub(a,r,e),cross(n,i,a),n},t.prototype.upload=function(t,e){void 0===e&&(e=!1),this.uploaded||(this.destroy(),this.uploaded=!0,this.zs=t.fe(this._b.Mb,FillExtrusionArray.Rb),e&&delete this._b)},t.prototype.destroy=function(){this.uploaded=!1,this.zs&&(this.zs.context.deleteBuffer(this.zs),delete this.zs),this.Pc&&(this.Pc.context.deleteBuffer(this.Pc),delete this.Pc)},t.prototype.reset=function(){this._b=new FillExtrusionArray,this.uploaded=!1},t}(),StyleParser=function(){function b(t){this.TY=t,this.CI=new AdaptorMap,this.Ve=null,this.RV=null,this.bN=null}return b.Wb=function(t){return{style:JSON.stringify(t.styles),TY:t.TY}},b.Gb=function(t){var e=new b(t.TY);return e.jY(JSON.parse(t.style)),e},b.mV=function(t){var e,r={};for(e in t)if(t.hasOwnProperty(e)){var n=t[e],i=void 0;switch(e[0]){case"1":i=b.Xe;break;case"2":i=b.rn,n.type="road";break;case"3":i=b.cn;break;case"4":i=b.un;break;case"5":i=b.ln,n.type="building"}if(i){for(var o=(a=n.key)[0],a=a[1],s=(void 0===r[o]&&(r[o]={}),(r[o][a]=n).browserStyle),u=0,c=s.length;u<c;u+=1){var f=s[u];if(s[u]=i(f),void 0===n.z)switch(e[0]){case"2":n.z=(s[u]?s[u][0]:n).z;break;case"1":case"3":case"4":case"5":n.z=s[u].z;break;default:n.z=-1}}b.Sn(n)}else delete t[e]}return r},b.$V=function(t){var e,r={};for(e in t)if(t.hasOwnProperty(e)){var n=t[e],i=void 0;switch(e[0]){case"1":i=b.Xe;break;case"2":i=b.rn,n.type="road";break;case"3":i=b.cn;break;case"4":i=b.un;break;case"5":i=b.ln,n.type="building"}if(i){for(var o=(a=e.split(":"))[0],a=a[1],s=(void 0===r[o]&&(r[o]={}),(r[o][a]=n).browserStyle),u=0,c=s.length;u<c;u+=1){var f=s[u];if(s[u]=i(f),void 0===n.z)switch(e[0]){case"2":n.z=(s[u]?s[u][0]:n).z;break;case"1":case"3":case"4":case"5":n.z=s[u].z;break;default:n.z=-1}}b.Sn(n)}else delete t[e]}return r},b.SZ=function(t){for(var e=t.stylemaps,r=e.length,n={},i=0;i<r;i++){for(var a=e[i],o=a.key[0],s=a.key[1],u={},c=(void 0===n[o]&&(n[o]={}),(n[o][s]=u).browserStyle=a.browserStyle,{}),f=a.levelStyleMapping.length,h=0;h<f;h+=2){var l=a.levelStyleMapping[h],d=a.levelStyleMapping[h+1];c[l]=d}u.levelStyleMapping=c;var v=void 0;switch(o[0]){case"1":v=b.Xe;break;case"2":v=b.rn,u.type="road";break;case"3":v=b.cn;break;case"4":v=b.un;break;case"5":v=b.ln,u.type="building"}for(var g=u.browserStyle,p=0,y=g.length;p<y;p+=1){var m=g[p];if(g[p]=v(m),void 0===u.z)switch(o[0]){case"2":u.z=(g[p]?g[p][0]:u).z;break;case"1":case"3":case"4":case"5":u.z=g[p].z;break;default:u.z=-1}}b.Sn(u)}return n},b.Je=function(t){var e;return t&&"0"!==t?(8===t.length&&(t=t.slice(2)+t.slice(0,2)),this.yQ&&this.yQ[t]?Color.create(this.yQ[t]):(e=Color.create(t),this.yQ||(this.yQ={}),this.yQ[t]||(this.yQ[t]=e.rgba.slice(0)),e)):null},b.Sn=function(t){if(void 0!==t.levelStyleMapping[3]&&(t.levelStyleMapping[2]=t.levelStyleMapping[3]),void 0!==t.levelStyleMapping[20]&&(t.levelStyleMapping[21]=t.levelStyleMapping[20],t.levelStyleMapping[22]=t.levelStyleMapping[20],t.levelStyleMapping[23]=t.levelStyleMapping[20],t.levelStyleMapping[24]=t.levelStyleMapping[20],t.levelStyleMapping[25]=t.levelStyleMapping[20],t.levelStyleMapping[26]=t.levelStyleMapping[20],t.levelStyleMapping[27]=t.levelStyleMapping[20],t.levelStyleMapping[28]=t.levelStyleMapping[20],t.levelStyleMapping[29]=t.levelStyleMapping[20],t.levelStyleMapping[30]=t.levelStyleMapping[20]),"building"===t.type&&t.levelStyleMapping&&(delete t.levelStyleMapping[15],delete t.levelStyleMapping[16]),"road"===t.type&&void 0!==t.levelStyleMapping[20]){var e=t.browserStyle,r=t.levelStyleMapping[20],n=e[r];if(n)for(var i=1;i<=10;i++){var a=[];a.push(exports.Ln({},n[0])),a.push(exports.Ln({},n[1])),a[0].roadWidth=a[0].roadWidth*Math.pow(2,i),a[0].borderWidth=a[0].borderWidth*Math.pow(2,i),t.browserStyle.push(a),t.levelStyleMapping[i+20]=r+i}}},b.prototype._Q=function(){return Boolean(this.styles)},b.prototype.jY=function(t){this.styles=t},b.prototype.clearStyleCache=function(){this.EI=-1,this.CI.clear()},b.prototype.setStyle=function(t){this.Ve=t,this.clearStyleCache()},b.prototype.EY=function(t){this.RV=t},b.prototype.MS=function(t){if(this.RV)return this.RV[t]},b.prototype.kF=function(t){this.bN=t},b.prototype.dn=function(t,e,r){if(this.styles)return this.SI(t,e,r)?this.CI.get((t<<16)+e):(r=this.jk(t,e,r)?this.Ak(t,e,r,this.Ve)||null:this.kk(t,e,r)||null,this.CI.set((t<<16)+e,r),r)},b.prototype.MF=function(t,e){var r=this.bN;if(!r||!r[t])return null;if(r[t].styles&&r[t].styles.color){var n,i,e=Util.getOptimalZoom(e),a={};for(n in r[t].styles.color.nodesObj)r[t].styles.color.nodesObj.hasOwnProperty(n)&&(a[(i=r[t].styles.color.nodesObj[n]).zoom]=i.value);return a[e=this._k(a,e)]?Util.Hex2Rgba(a[e]):null}return r[t].color?(e=r[t].color,Util.Hex2Rgba(e)):void 0},b.prototype.nX=function(t,e,r,n){var i=this.Ve;return i&&i[t]&&i[t][e]?(i=i[t][e]).styles&&i.styles[r]?(t=Util.getOptimalZoom(n),(n=this._k(i.styles[r].nodesObj,t))&&i.styles[r].nodesObj[n]?i.styles[r].nodesObj[n]:null):"visible"===r||i[r]&&(i.visible||"3"!==e)?i[r]:void 0:null},b.prototype.Ok=function(t,e,r){return void 0!==this.styles[t]&&(t=this.styles[t][e])&&void 0!==(e=t.levelStyleMapping[r])?t.browserStyle[e]:null},b.prototype.xk=function(t,e,r){if(void 0===this.styles[t])return null;if(void 0===this.styles[t][e])return null;if(void 0===this.styles[t][e].levelStyleMapping)return null;if(void 0===this.styles[t][e].browserStyle)return null;var n=this.styles[t][e].levelStyleMapping,t=this.styles[t][e].browserStyle,i=Math.floor(r);if(i===(e=Math.ceil(r)))return(a=t[n[i]])?(g=l=cloneDeep(a),l instanceof Array&&(g=l[0]),l):null;var a=r-i<.8?i:e,o=t[n[i]],t=t[n[e]];if((o||t)&&(o||a!==i)&&(!o||t||a!==e)&&(o||!t||i!==a)){if(!o&&t){for(var s,u,c=l=cloneDeep(t),f=(l instanceof Array&&(c=l[0]),Object.keys(c)),h=0;h<f.length;h++)-1<(d=f[h]).indexOf("Color")&&c[d]&&c[d].rgba?(u=(r-i-.8)/.2,s=Math.floor(c[d].rgba[3]*u),c[d].rgba[3]=s):-1<d.indexOf("Width")&&(c[d]=c[d]*(u=(r-i-.8)/.2));return l}if(o&&t){for(var l,d,v,g=l=cloneDeep(o),c=t,f=(l instanceof Array&&(g=l[0]),l instanceof Array&&(c=t[0]),Object.keys(g)),h=0;h<f.length;h++)-1<(d=f[h]).indexOf("Width")&&(v=(r-i)*(c[d]-g[d])+g[d],g[d]=v);return l}return o&&!t?(g=l=cloneDeep(o),l instanceof Array&&(g=l[0]),l):null}},b.prototype.Ik=function(t,e,r){var n=[];return n[0]=t[0]+(e[0]-t[0])*r,n[1]=t[1]+(e[1]-t[1])*r,n[2]=t[2]+(e[2]-t[2])*r,n[3]=t[3]+(e[3]-t[3])*r,n},b.prototype.kk=function(t,e,r){var n=t.toString()[0];return"1"===n||"4"===n?(n=Util.getOptimalZoom(r),this.Ok(t,e,n)):this.xk(t,e,r)},b.prototype.Ak=function(t,e,r,n){var i=r,a=n[t][e]||n[t].all,o=null;if(a.styles){var s=Util.getOptimalZoom(r);if(a.styles.visible&&(n=this._k(a.styles.visible.nodesObj,s))&&void 0!==(n=a.styles.visible.nodesObj[n])&&!1===n)return null;for(var u=(b=cloneDeep(this.styles[t][e])).levelStyleMapping,c=b.browserStyle,f=Object.keys(a.styles),h=0;h<f.length;h++){var l=f[h],d=a.styles[l],v=null;if(d.transitional&&"linear"===d.transitional){var g,p=this.Tk(d.nodesObj,r);if(!p||!p[0])continue;if(!(i=p[0]))continue;if(void 0===(g=u[s]))continue;o=c[g],1===p.length?v=d.nodesObj[i]:"color"===l&&(v=this.Fk(p,d.nodesObj,r))}else{if(!(i=this._k(d.nodesObj,s)))continue;if(void 0===(g=u[s]))continue;o=c[g],v=d.nodesObj[i]}if(!o)return null;var y=t.toString()[0],m=this.uP(a,s);if("1"===y){if(!m)return null;this.NI(l,v,o,t,e)}else"2"===y?(this.Sk(l,v,o),!m&&o&&o[1]&&(o[1]=null)):"4"===y?this.LI(l,v,o):this.Ck(l,v,o)}}else{if(void 0!==a.visible&&!1===a.visible)return null;if(void 0===(g=(u=this.styles[t][e].levelStyleMapping)[i=Util.getOptimalZoom(i)]))return null;if(!this.styles[t][e].browserStyle[g])return null;for(var b,o=(c=(b=cloneDeep(this.styles[t][e])).browserStyle)[g],f=Object.keys(a),m=this.uP(a,i),h=0;h<f.length;h++){if(l=f[h],!o)return null;if("1"===(y=t.toString()[0])){if(!m)return null;this.NI(l,a[l],o,t,e)}else"2"===y?(this.Sk(l,a[l],o),!m&&o&&o[1]&&(o[1]=null)):"4"===y?this.LI(l,a[l],o):this.Ck(l,a[l],o)}}return o},b.prototype.mn=function(t,e){return void 0===this.styles[t]?null:(t=this.styles[t][e])?(e=t.levelStyleMapping||{},t=Object.keys(e),[parseInt(t[0],10),parseInt(t[t.length-1],10)]):[]},b.prototype.Lw=function(t,e){return void 0!==this.styles[t]&&(t=this.styles[t][e])?t.z:null},b.prototype.mW=function(t,e,r){return 2===Math.floor(t/1e4)&&(t=this.xk(t,e,r))&&t[0]?(e=["butt","butt"],-1<(r=t[0]).roadStyle.indexOf("roundcap")?e[0]="round":-1<r.roadStyle.indexOf("squarecap")&&(e[0]="square"),-1<r.borderStyle.indexOf("roundcap")?e[1]="round":-1<r.borderStyle.indexOf("squarecap")&&(e[1]="square"),e):defaultCap},b.prototype.destroy=function(){this.styles&&(this.styles={})},b.prototype.uP=function(t,e){var r=!0;return t.styles&&t.styles.showLabel?(e=this._k(t.styles.showLabel.nodesObj,e),void 0!==(e=t.styles.showLabel.nodesObj[e])&&!1===e&&(r=!1)):void 0!==t.showLabel&&!1===t.showLabel&&(r=!1),r},b.prototype.SI=function(t,e,r){return r=this.TY?Math.floor(r):Math.floor(r*(16.8<=r?100:10)),this.EI!==r&&(this.EI=r,this.CI.clear()),this.CI.has((t<<16)+e)},b.prototype.jk=function(t,e,r){return!!this.Ve&&!!this.Ve[t]&&!(!this.Ve[t][e]&&!this.Ve[t].all||!this.styles||!this.styles[t]||!this.styles[t][e])},b.prototype.Fk=function(t,e,r){var n=Util.Hex2Rgba(e[t[0]]),e=Util.Hex2Rgba(e[t[1]]),r=(r-t[0])/(t[1]-t[0]);return[Math.floor(n[0]+r*(e[0]-n[0])),Math.floor(n[1]+r*(e[1]-n[1])),Math.floor(n[2]+r*(e[2]-n[2])),Math.floor(n[3]+r*(e[3]-n[3]))]},b.prototype.UV=function(t){for(var e={},r=0;r<t.length;r++){t[r];var n=t[r].zoom,i=t[r].value;e[n]=i}return e},b.prototype.Tk=function(t,e){var r=[];if(t[e])r.push(e);else{for(var n=!0,i=Math.floor(e);n&&0<i;){if(t[i]){r.push(i),n=!1;break}i--}for(i=Math.ceil(e),n=!0;n&&i<25;){if(t[i]){r.push(i),n=!1;break}i++}}return r},b.prototype._k=function(t,e){if(!t)return null;if(!isUndefined$1(t[e]))return e;for(var r=!0,n=e;r&&0<n;)if(t[--n]||!1===t[n]||""===t[n]){r=!1;break}if(!r)return n;for(n=e;r&&n<25;)if(t[++n]||!1===t[n]||""===t[n]){r=!1;break}return r?null:n},b.prototype.Ck=function(t,e,r){var n=null;switch(t){case"color":case"fillColor":n=e,Array.isArray(e)||(n=Util.Hex2Rgba(e)),r.faceColor||(r.faceColor=new Color(n)),r.faceColor.rgba=n;break;case"fontSize":r.fontSize=e;break;case"texture":r.texture=e?AMap.getConfig().protocol+"://"+e:"";break;case"backgroundColor":n=Util.Hex2Rgba(e),r.holoColor&&(r.holoColor.rgba=n);break;case"strokeColor":n=Util.Hex2Rgba(e),r.borderColor||(r.borderColor=new Color(n)),r.borderColor.rgba=n;break;case"showIcon":!1===e&&r.iconID&&(r.iconID="0")}},b.prototype.LI=function(t,e,r){var n=null;switch(t){case"textFillColor":n=e,Array.isArray(e)||(n=Util.Hex2Rgba(e)),r.faceColor||(r.faceColor=new Color(n)),r.faceColor.rgba=n;break;case"fontSize":r.fontSize=e;break;case"backgroundColor":n=Util.Hex2Rgba(e),r.holoColor&&(r.holoColor.rgba=n);break;case"textStrokeColor":n=Util.Hex2Rgba(e),r.borderColor||(r.borderColor=new Color(n)),r.borderColor.rgba=n;break;case"showIcon":!1===e&&r.iconID&&(r.iconID="0");break;case"showLabel":r.showText=e?1:0}},b.prototype.NI=function(t,e,r,n,i){var a=null;switch(t){case"showIcon":!1===e&&r.iconID&&(r.iconID="0");break;case"textFillColor":a=e,Array.isArray(e)||(a=Util.Hex2Rgba(e)),r.faceColor||(r.faceColor=new Color(a)),r.faceColor.rgba=a;break;case"fontSize":r.fontSize=e;break;case"backgroundColor":a=Util.Hex2Rgba(e),r.holoColor?r.holoColor.rgba=a:10002!==n||8!==i&&37!==i||(r.holoColor=new Color(a));break;case"textStrokeColor":a=Util.Hex2Rgba(e),r.borderColor||(r.borderColor=new Color(a)),r.borderColor.rgba=a;break;case"sel-highlight":r["sel-highlight"]=!0===e;break;case"sel-textFillColor":a=Util.Hex2Rgba(e),r["sel-textFillColor"]=map(a,function(t){return t/255});break;case"sel-textStrokeColor":a=Util.Hex2Rgba(e),r["sel-textStrokeColor"]=map(a,function(t){return t/255});break;case"label-bg":r["label-bg"]=!0===e;break;case"label-bgColor":a=Util.Hex2Rgba(e),r.holoColor?r.holoColor.rgba=a:10002!==n||8!==i&&37!==i||(r.holoColor=new Color(a));break;case"showLabel":r.showText=e?1:0}},b.prototype.Sk=function(t,e,r){var n,i=null;switch(t){case"color":case"fillColor":i=Util.Hex2Rgba(e),r[0]&&(r[0].roadColor||(r[0].roadColor=new Color(i)),r[0].roadColor.rgba=i);break;case"fillOpacity":r[0]&&r[0].roadColor&&r[0].roadColor.rgba&&(n=r[0].roadColor.rgba,i=Util.Opacity2Rgba(e,n),r[0].roadColor.rgba=i);break;case"fillWidth":r[0]&&(r[0].roadWidth=e);break;case"strokeColor":i=Util.Hex2Rgba(e),r[0]&&(r[0].borderColor||(r[0].borderColor=new Color(i)),r[0].borderColor.rgba=i);break;case"strokeWidth":r[0]&&(r[0].borderWidth=e);break;case"textFillColor":r[1]&&(i=Util.Hex2Rgba(e),r[1].faceColor||(r[1].faceColor=new Color(i)),r[1].faceColor.rgba=i);break;case"textStrokeColor":r[1]&&(i=Util.Hex2Rgba(e),r[1].borderColor||(r[1].borderColor=new Color(i)),r[1].borderColor.rgba=i);break;case"fontSize":r[1]&&(r[1].fontSize=e);break;case"showLabel":r.showText=e?1:0}},b.Xe=function(t){var t=t.split("&"),e={};return e.iconID=t[0],e.fontSize=parseInt(t[1],10),e.faceColor=b.Je(t[2]),e.borderColor=b.Je(t[3]),e.holoColor=b.Je(t[4]),e.showMode=parseInt(t[6],10),e.showText=2===e.showMode?0:1,e.forceShow=parseInt(t[7],10),e.clickEnable=parseInt(t[8],10),e.xOffset=parseInt(t[9],10),e.yOffset=parseInt(t[10],10),e.iconFile=t[5],e},b.rn=function(t){var e=(t=t.split("|"))[0].split("&"),r={},e=(t[0]?(r.roadWidth=parseInt(e[0],10),r.roadColor=b.Je(e[1]),r.roadStyle=e[2]||"",r.borderWidth=parseInt(e[3],10),r.borderColor=b.Je(e[4]),r.borderStyle=e[5]||"",r.z=parseInt(e[6],10),r.roadStyle&&r.roadStyle.indexOf&&(0===r.roadStyle.indexOf("dash")?(r.roadDash=r.roadStyle.substring(4).slice(1,-1).split(","),r.roadDash=map(r.roadDash,function(t){return parseInt(t,10)}),2===r.roadDash.length&&(e=r.roadDash).push.apply(e,r.roadDash)):0<r.roadStyle.indexOf("railway")||r.roadStyle.indexOf("dash_crewel")),r.borderStyle&&r.borderStyle.indexOf&&(0===r.borderStyle.indexOf("dash")?(r.borderDash=r.borderStyle.substring(4).slice(1,-1).split(","),r.borderDash=map(r.borderDash,function(t){return parseInt(t,10)}),2===r.borderDash.length&&(e=r.borderDash).push.apply(e,r.borderDash)):0<r.borderStyle.indexOf("railway")||r.borderStyle.indexOf("dash_crewel"))):(r.roadWidth=0,r.roadColor=b.Je("00000000"),r.roadStyle="",r.borderWidth=0,r.borderColor=b.Je("00000000"),r.borderStyle="",r.z=0),{});return t[1]&&(t=t[1].split("&"),e.iconID="",e.fontSize=parseInt(t[1],10),e.faceColor=b.Je(t[2]),e.borderColor=b.Je(t[3]),e.z=parseInt(t[4],10)),[r,e]},b.ln=function(t){var t=t.split("&"),e={};return e.faceColor=b.Je(t[0]),e.borderWidth=parseInt(t[1],10),e.borderColor=b.Je(t[2]),e.wallColor1=b.Je(t[3]),e.wallColor2=b.Je(t[4]),e.opacity=parseFloat(t[5]),e.z=parseInt(t[6],10),e},b.un=function(t){var t=t.split("&"),e={};return e.iconID=t[0],e.fontSize=parseInt(t[1],10),e.faceColor=b.Je(t[2]),e.borderColor=b.Je(t[3]),e.holoColor=null,e.z=parseInt(t[5],10),e},b.cn=function(t){var t=t.split("&"),e={};return e.faceColor=b.Je(t[0]),e.borderWidth=0,e.borderColor=null,e.z=parseInt(t[3],10),e},b}(),NebulaSegements=function(){function t(){this.jc=[],this.GM=-1,this.HM=-1,this.VM=0,this.WM=new LineSegement(-1,-1,-1,-1,-1)}return t.prototype.add=function(t,e,r,n,i,a,o,s){this.WM.eT(t,e,i,n)&&a===this.WM.bz&&o+""==this.WM.roofColor+""&&s+""==this.WM.wallColor+""||(this.GM=t,this.HM=e,this.VM+=this.WM?this.WM.length:0,this.WM=new LineSegement(t,e,this.VM,n,i,a,o,s),this.jc.push(this.WM)),this.WM.add(r)},t.prototype.reset=function(){this.WM=new LineSegement(-1,-1,-1,-1,-1)},t}(),LineSegement=function(){function t(t,e,r,n,i,a,o,s){this.mainkey=t,this.subkey=e,this.offset=r,this.minzoom=n,this.maxzoom=i,this.bz=a,this.roofColor=o,this.wallColor=s,this.length=0}return t.prototype.add=function(t){this.length+=t},t.prototype.eT=function(t,e,r,n){return this.mainkey===t&&this.subkey===e&&this.maxzoom===r&&this.minzoom===n},t}(),PolygonSegements=function(){function t(){this.jc=[],this.VM=0}return t.prototype.add=function(t){this.jc.push({length:t,offset:this.VM}),this.VM+=t},t.prototype.reset=function(){this.jc=[],this.VM=0},t.prototype.destroy=function(){this.jc&&0<this.jc.length&&(this.jc=[])},t}(),VectorTileFeature=function(t,e,r,n,i){this.properties={},this.extent=r,this.type=0,this.fA=t,this.hA=-1,this.cA=n,this.vA=i,t.nw(readFeature,this,e)};function readFeature(t,e,r){1===t?e.id=r.ow():2===t?readTag(r,e):3===t?e.type=r.ow():4===t&&(e.hA=r.pos)}function readTag(t,e){for(var r=t.ow()+t.pos;t.pos<r;){var n=e.cA[t.ow()],i=e.vA[t.ow()];e.properties[n]=i}}function classifyRings(t){var e=t.length;if(e<=1)return[t];for(var r,n=[],i=[],a=0;a<e;a++){var o=signedArea$1(t[a]);0!==o&&((r=void 0===r?o<0:r)===o<0?(i&&n.push(i),i=[t[a]]):i.push(t[a]))}return i&&n.push(i),n}function signedArea$1(t){for(var e,r,n=0,i=0,a=t.length,o=a-1;i<a;o=i++)e=t[i],n+=((r=t[o]).x-e.x)*(e.y+r.y);return n}VectorTileFeature.types=["Unknown","Point","LineString","Polygon"],VectorTileFeature.prototype.Dw=function(){for(var t,e=this.fA,r=(e.pos=this.hA,e.ow()+e.pos),n=1,i=0,a=0,o=0,s=[],u=[];e.pos<r;)if(i<=0&&(n=7&(t=e.ow()),i=t>>3),i--,1===n||2===n)a+=e.lA(),o+=e.lA(),1===n&&(u&&0<u.length&&s.push(u),u=[]),u.push([a,o]);else{if(7!==n)throw new Error("unknown command "+n);u&&u.push([u[0][0],u[0][1]])}return u&&0<u.length&&s.push(u),this.lines=s},VectorTileFeature.prototype.Ro=function(){for(var t,e=this.fA,r=(e.pos=this.hA,e.ow()+e.pos),n=1,i=0,a=0,o=0,s=1/0,u=-1/0,c=1/0,f=-1/0;e.pos<r;)if(i<=0&&(n=7&(t=e.ow()),i=t>>3),i--,1===n||2===n)(a+=e.lA())<s&&(s=a),u<a&&(u=a),(o+=e.lA())<c&&(c=o),f<o&&(f=o);else if(7!==n)throw new Error("unknown command "+n);return[s,c,u,f]},VectorTileFeature.prototype.dA=function(t,e,r){var n,i=this.extent*Math.pow(2,r),a=this.extent*t,o=this.extent*e,s=this.Dw(),r=VectorTileFeature.types[this.type];function u(t){for(var e=0;e<t.length;e++){var r=t[e],n=180-360*(r.y+o)/i;t[e]=[360*(r.x+a)/i-180,360/Math.PI*Math.atan(Math.exp(n*Math.PI/180))-90]}}switch(this.type){case 1:for(var c=[],f=0;f<s.length;f++)c[f]=s[f][0];u(s=c);break;case 2:for(f=0;f<s.length;f++)u(s[f]);break;case 3:for(s=classifyRings(s),f=0;f<s.length;f++)for(n=0;n<s[f].length;n++)u(s[f][n])}return 1===s.length?s=s[0]:r="Multi"+r,t={type:"Feature",geometry:{type:r,coordinates:s},properties:this.properties},"id"in this&&(t.id=this.id),t};var VectorTileLayer=function(t,e){this.version=1,this.name=null,this.extent=4096,this.length=0,this.fA=t,this.cA=[],this.vA=[],this.Cw=[],t.nw(readLayer,this,e),this.length=this.Cw.length};function readLayer(t,e,r){15===t?e.version=r.ow():1===t?e.name=r.aw():5===t?e.extent=r.ow():2===t?e.Cw.push(r.pos):3===t?e.cA.push(r.aw()):4===t&&e.vA.push(readValueMessage(r))}function readValueMessage(t){for(var e=null,r=t.ow()+t.pos;t.pos<r;)var n=t.ow()>>3,e=1==n?t.aw():2==n?t.pA():3==n?t.yA():4==n?t.mA():5==n?t.ow():6==n?t.lA():7==n?t.vw():null;return e}VectorTileLayer.prototype.Gw=function(t){if(t<0||t>=this.Cw.length)throw new Error("feature index out of bounds");return this.fA.pos=this.Cw[t],t=this.fA.ow()+this.fA.pos,new VectorTileFeature(this.fA,t,this.extent,this.cA,this.vA)};var VectorTile$1=function(t,e){this.type="vector",this.layers=t.nw(readTile,{},e)};function readTile(t,e,r){3===t&&(t=new VectorTileLayer(r,r.ow()+r.pos)).length&&(e[t.name]=t)}VectorTile$1.Wb=function(t){return t},VectorTile$1.Gb=function(t){return t},VectorTile$1.prototype.nG=function(t){this.type=t};var SHIFT_LEFT_32=4294967296,SHIFT_RIGHT_32=1/SHIFT_LEFT_32,Pbf=function(){function n(t){this.gA=ArrayBuffer.isView&&ArrayBuffer.isView(t)?t:new Uint8Array(t||0),this.pos=0,this.type=0,this.length=this.gA.length}return n.prototype.destroy=function(){this.gA=new Uint8Array(0)},n.prototype.nw=function(t,e,r){for(r=r||this.length;this.pos<r;){var n=this.ow(),i=n>>3,a=this.pos;this.type=7&n,t(i,e,this),this.pos===a&&this.wA(n)}return e},n.prototype.MA=function(t,e){return this.nw(t,e,this.ow()+this.pos)},n.prototype.jA=function(){var t=readUInt32(this.gA,this.pos);return this.pos+=4,t},n.prototype.AA=function(){var t=readInt32(this.gA,this.pos);return this.pos+=4,t},n.prototype.kA=function(){var t=readUInt32(this.gA,this.pos)+readUInt32(this.gA,this.pos+4)*SHIFT_LEFT_32;return this.pos+=8,t},n.prototype.OA=function(){var t=readUInt32(this.gA,this.pos)+readInt32(this.gA,this.pos+4)*SHIFT_LEFT_32;return this.pos+=8,t},n.prototype.pA=function(){var t=this.xA(this.gA,this.pos,!0,23,4);return this.pos+=4,t},n.prototype.yA=function(){var t=this.xA(this.gA,this.pos,!0,52,8);return this.pos+=8,t},n.prototype.ow=function(t){var e=this.gA,r=e[this.pos++],n=127&r;return r<128||(n|=(127&(r=e[this.pos++]))<<7,r<128)||(n|=(127&(r=e[this.pos++]))<<14,r<128)||(n|=(127&(r=e[this.pos++]))<<21,r<128)?n:readVarintRemainder(n|=(15&e[this.pos])<<28,t,this)},n.prototype.mA=function(){return this.ow(!0)},n.prototype.lA=function(){var t=this.ow();return t%2==1?(t+1)/-2:t/2},n.prototype.vw=function(){return Boolean(this.ow())},n.prototype.aw=function(){var t=this.ow()+this.pos,e=readUtf8(this.gA,this.pos,t);return this.pos=t,e},n.prototype.mw=function(){var t=this.ow()+this.pos,e=this.gA.subarray(this.pos,t);return this.pos=t,e},n.prototype.tw=function(t,e){var r=readPackedEnd(this);for(t=t||[];this.pos<r;)t.push(this.ow(e));return t},n.prototype.IA=function(t){var e=readPackedEnd(this);for(t=t||[];this.pos<e;)t.push(this.lA());return t},n.prototype.TA=function(t){var e=readPackedEnd(this);for(t=t||[];this.pos<e;)t.push(this.vw());return t},n.prototype.FA=function(t){var e=readPackedEnd(this);for(t=t||[];this.pos<e;)t.push(this.pA());return t},n.prototype._A=function(t){var e=readPackedEnd(this);for(t=t||[];this.pos<e;)t.push(this.yA());return t},n.prototype.SA=function(t){var e=readPackedEnd(this);for(t=t||[];this.pos<e;)t.push(this.jA());return t},n.prototype.CA=function(t){var e=readPackedEnd(this);for(t=t||[];this.pos<e;)t.push(this.AA());return t},n.prototype.EA=function(t){var e=readPackedEnd(this);for(t=t||[];this.pos<e;)t.push(this.kA());return t},n.prototype.NA=function(t){var e=readPackedEnd(this);for(t=t||[];this.pos<e;)t.push(this.OA());return t},n.prototype.wA=function(t){(t&=7)!==n.LA&&(t===n.DA?this.pos=this.ow()+this.pos:t===n.RA?this.pos+=4:t===n.PA?this.pos+=8:console.log("Unimplemented type: "+t))},n.prototype.UA=function(t,e){this.BA(t<<3|e)},n.prototype.zA=function(t){for(var e,r=this.length||16;r<this.pos+t;)r*=2;r!==this.length&&((e=new Uint8Array(r)).set(this.gA),this.gA=e,this.length=r)},n.prototype.finish=function(){return this.length=this.pos,this.pos=0,this.gA.subarray(0,this.length)},n.prototype.qA=function(t){this.zA(4),writeInt32(this.gA,t,this.pos),this.pos+=4},n.prototype.WA=function(t){this.zA(4),writeInt32(this.gA,t,this.pos),this.pos+=4},n.prototype.GA=function(t){this.zA(8),writeInt32(this.gA,-1&t,this.pos),writeInt32(this.gA,Math.floor(t*SHIFT_RIGHT_32),this.pos+4),this.pos+=8},n.prototype.HA=function(t){this.zA(8),writeInt32(this.gA,-1&t,this.pos),writeInt32(this.gA,Math.floor(t*SHIFT_RIGHT_32),this.pos+4),this.pos+=8},n.prototype.BA=function(t){268435455<(t=+t||0)||t<0?writeBigVarint(t,this):(this.zA(4),this.gA[this.pos++]=127&t|(127<t?128:0),t<=127||(this.gA[this.pos++]=127&(t>>>=7)|(127<t?128:0),t<=127)||(this.gA[this.pos++]=127&(t>>>=7)|(127<t?128:0),t<=127)||(this.gA[this.pos++]=t>>>7&127))},n.prototype.VA=function(t){this.BA(t<0?2*-t-1:2*t)},n.prototype.$A=function(t){this.BA(Boolean(t))},n.prototype.YA=function(t){t=String(t),this.zA(4*t.length),this.pos++;var e=this.pos;this.pos=writeUtf8(this.gA,t,this.pos),128<=(t=this.pos-e)&&makeRoomForExtraLength(e,t,this),this.pos=e-1,this.BA(t),this.pos+=t},n.prototype.KA=function(t){this.zA(4),this.XA(this.gA,t,this.pos,!0,23,4),this.pos+=4},n.prototype.JA=function(t){this.zA(8),this.XA(this.gA,t,this.pos,!0,52,8),this.pos+=8},n.prototype.ZA=function(t){var e=t.length;this.BA(e),this.zA(e);for(var r=0;r<e;r++)this.gA[this.pos++]=t[r]},n.prototype.QA=function(t,e){this.pos++;var r=this.pos;t(e,this),128<=(t=this.pos-r)&&makeRoomForExtraLength(r,t,this),this.pos=r-1,this.BA(t),this.pos+=t},n.prototype.fw=function(t,e,r){this.UA(t,n.DA),this.QA(e,r)},n.prototype.tk=function(t,e){this.fw(t,writePackedVarint,e)},n.prototype.rk=function(t,e){this.fw(t,writePackedSVarint,e)},n.prototype.nk=function(t,e){this.fw(t,writePackedBoolean,e)},n.prototype.ik=function(t,e){this.fw(t,writePackedFloat,e)},n.prototype.ek=function(t,e){this.fw(t,writePackedDouble,e)},n.prototype.ak=function(t,e){this.fw(t,writePackedFixed32,e)},n.prototype.uk=function(t,e){this.fw(t,writePackedSFixed32,e)},n.prototype.sk=function(t,e){this.fw(t,writePackedFixed64,e)},n.prototype.fk=function(t,e){this.fw(t,writePackedSFixed64,e)},n.prototype.ww=function(t,e){this.UA(t,n.DA),this.ZA(e)},n.prototype.hk=function(t,e){this.UA(t,n.RA),this.qA(e)},n.prototype.ck=function(t,e){this.UA(t,n.RA),this.WA(e)},n.prototype.vk=function(t,e){this.UA(t,n.PA),this.GA(e)},n.prototype.lk=function(t,e){this.UA(t,n.PA),this.HA(e)},n.prototype.rw=function(t,e){this.UA(t,n.LA),this.BA(e)},n.prototype.dk=function(t,e){this.UA(t,n.LA),this.VA(e)},n.prototype.uw=function(t,e){this.UA(t,n.DA),this.YA(e)},n.prototype.bk=function(t,e){this.UA(t,n.RA),this.KA(e)},n.prototype.pk=function(t,e){this.UA(t,n.PA),this.JA(e)},n.prototype.hw=function(t,e){this.rw(t,Boolean(e))},n.prototype.xA=function(t,e,r,n,i){var a,o,s=8*i-n-1,u=(1<<s)-1,c=u>>1,f=-7,h=r?i-1:0,l=r?-1:1,i=t[e+h];for(h+=l,a=i&(1<<-f)-1,i>>=-f,f+=s;0<f;a=256*a+t[e+h],h+=l,f-=8);for(o=a&(1<<-f)-1,a>>=-f,f+=n;0<f;o=256*o+t[e+h],h+=l,f-=8);if(0===a)a=1-c;else{if(a===u)return o?NaN:1/0*(i?-1:1);o+=Math.pow(2,n),a-=c}return(i?-1:1)*o*Math.pow(2,a-n)},n.prototype.XA=function(t,e,r,n,i,a){var o,s,u=8*a-i-1,c=(1<<u)-1,f=c>>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,l=n?0:a-1,d=n?1:-1,a=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(s=isNaN(e)?1:0,o=c):(o=Math.floor(Math.log(e)/Math.LN2),e*(n=Math.pow(2,-o))<1&&(o--,n*=2),2<=(e+=1<=o+f?h/n:h*Math.pow(2,1-f))*n&&(o++,n/=2),c<=o+f?(s=0,o=c):1<=o+f?(s=(e*n-1)*Math.pow(2,i),o+=f):(s=e*Math.pow(2,f-1)*Math.pow(2,i),o=0));8<=i;t[r+l]=255&s,l+=d,s/=256,i-=8);for(o=o<<i|s,u+=i;0<u;t[r+l]=255&o,l+=d,o/=256,u-=8);t[r+l-d]|=128*a},n.LA=0,n.PA=1,n.DA=2,n.RA=5,n}();function readVarintRemainder(t,e,r){var n=r.gA,i=n[r.pos++],a=(112&i)>>4;if(i<128)return toNum(t,a,e);if(a|=(127&(i=n[r.pos++]))<<3,i<128)return toNum(t,a,e);if(a|=(127&(i=n[r.pos++]))<<10,i<128)return toNum(t,a,e);if(a|=(127&(i=n[r.pos++]))<<17,i<128)return toNum(t,a,e);if(a|=(127&(i=n[r.pos++]))<<24,i<128)return toNum(t,a,e);if(a|=(1&(i=n[r.pos++]))<<31,i<128)return toNum(t,a,e);throw new Error("Expected varint not more than 10 bytes")}function readPackedEnd(t){return t.type===Pbf.DA?t.ow()+t.pos:t.pos+1}function toNum(t,e,r){return r?4294967296*e+(t>>>0):4294967296*(e>>>0)+(t>>>0)}function writeBigVarint(t,e){var r,n;if(0<=t?(r=t%4294967296|0,n=t/4294967296|0):(n=~(-t/4294967296),4294967295^(r=~(-t%4294967296))?r=r+1|0:n=n+1|(r=0)),0x10000000000000000<=t||t<-0x10000000000000000)throw new Error("Given varint doesn't fit into 10 bytes");e.zA(10),writeBigVarintLow(r,n,e),writeBigVarintHigh(n,e)}function writeBigVarintLow(t,e,r){r.gA[r.pos++]=127&t|128,t>>>=7,r.gA[r.pos++]=127&t|128,t>>>=7,r.gA[r.pos++]=127&t|128,t>>>=7,r.gA[r.pos++]=127&t|128,r.gA[r.pos]=127&(t>>>=7)}function writeBigVarintHigh(t,e){var r=(7&t)<<4;e.gA[e.pos++]|=r|((t>>>=3)?128:0),t&&(e.gA[e.pos++]=127&t|((t>>>=7)?128:0),t)&&(e.gA[e.pos++]=127&t|((t>>>=7)?128:0),t)&&(e.gA[e.pos++]=127&t|((t>>>=7)?128:0),t)&&(e.gA[e.pos++]=127&t|((t>>>=7)?128:0),t)&&(e.gA[e.pos++]=127&t)}function makeRoomForExtraLength(t,e,r){var n=e<=16383?1:e<=2097151?2:e<=268435455?3:Math.ceil(Math.log(e)/(7*Math.LN2));r.zA(n);for(var i=r.pos-1;t<=i;i--)r.gA[i+n]=r.gA[i]}function writePackedVarint(t,e){for(var r=0;r<t.length;r++)e.BA(t[r])}function writePackedSVarint(t,e){for(var r=0;r<t.length;r++)e.VA(t[r])}function writePackedFloat(t,e){for(var r=0;r<t.length;r++)e.KA(t[r])}function writePackedDouble(t,e){for(var r=0;r<t.length;r++)e.JA(t[r])}function writePackedBoolean(t,e){for(var r=0;r<t.length;r++)e.$A(t[r])}function writePackedFixed32(t,e){for(var r=0;r<t.length;r++)e.qA(t[r])}function writePackedSFixed32(t,e){for(var r=0;r<t.length;r++)e.WA(t[r])}function writePackedFixed64(t,e){for(var r=0;r<t.length;r++)e.GA(t[r])}function writePackedSFixed64(t,e){for(var r=0;r<t.length;r++)e.HA(t[r])}function readUInt32(t,e){return(t[e]|t[e+1]<<8|t[e+2]<<16)+16777216*t[e+3]}function writeInt32(t,e,r){t[r]=e,t[r+1]=e>>>8,t[r+2]=e>>>16,t[r+3]=e>>>24}function readInt32(t,e){return(t[e]|t[e+1]<<8|t[e+2]<<16)+(t[e+3]<<24)}function readUtf8(t,e,r){for(var n="",i=e;i<r;){var a=t[i],o=null,s=239<a?4:223<a?3:191<a?2:1;if(r<i+s)break;var u,c=void 0,f=void 0;1===s?a<128&&(o=a):2===s?128==(192&(c=t[i+1]))&&(o=(31&a)<<6|63&c)<=127&&(o=null):3===s?(c=t[i+1],f=t[i+2],128==(192&c)&&128==(192&f)&&((o=(15&a)<<12|(63&c)<<6|63&f)<=2047||55296<=o&&o<=57343)&&(o=null)):4===s&&(c=t[i+1],f=t[i+2],u=t[i+3],128==(192&c))&&128==(192&f)&&128==(192&u)&&((o=(15&a)<<18|(63&c)<<12|(63&f)<<6|63&u)<=65535||1114112<=o)&&(o=null),null===o?(o=65533,s=1):65535<o&&(o-=65536,n+=String.fromCharCode(o>>>10&1023|55296),o=56320|1023&o),n+=String.fromCharCode(o),i+=s}return n}function writeUtf8(t,e,r){for(var n=0,i=void 0,a=void 0;n<e.length;n++){if(55295<(i=e.charCodeAt(n))&&i<57344){if(!a){56319<i||n+1===e.length?(t[r++]=239,t[r++]=191,t[r++]=189):a=i;continue}if(i<56320){t[r++]=239,t[r++]=191,t[r++]=189,a=i;continue}i=a-55296<<10|i-56320|65536,a=null}else a&&(t[r++]=239,t[r++]=191,t[r++]=189,a=null);i<128?t[r++]=i:(i<2048?t[r++]=i>>6|192:(i<65536?t[r++]=i>>12|224:(t[r++]=i>>18|240,t[r++]=i>>12&63|128),t[r++]=i>>6&63|128),t[r++]=63&i|128)}return r}var StyleOptionsBuilding=function(){this.hideWithoutStyle=!1,this.areas=[]},VectorTileSegements=function(){function t(){this.jc=[],this.VM=0}return t.prototype.add=function(t,e,r,n,i){VTLineSegement.getKey(t,e,i,n)!==(this.WM?this.WM.getKey():"-1")&&(this.VM+=this.WM?this.WM.length:0,this.WM=new VTLineSegement(t,e,this.VM,n,i),this.jc.push(this.WM)),this.WM.add(r)},t}(),VTLineSegement=function(){function t(t,e,r,n,i){this.mainkey=t,this.subkey=e,this.offset=r,this.minzoom=n,this.maxzoom=i,this.length=0}return t.getKey=function(t,e,r,n){return t+":"+e+":"+r+":"+n},t.prototype.add=function(t){this.length+=t},t.prototype.getKey=function(){return this.mainkey+":"+this.subkey+":"+this.maxzoom+":"+this.minzoom},t}(),MapboxSegements=function(){function t(){this.jc=[],this.GM=-1,this.HM=-1,this.VM=0}return t.prototype.add=function(t,e){MBLineSegement.getKey(t),this.WM&&this.WM.getKey(),this.GM=t,this.VM+=this.WM?this.WM.length:0,this.WM=new MBLineSegement(t,this.VM),this.jc.push(this.WM),this.WM.add(e)},t}(),MBLineSegement=function(){function t(t,e){this.style=t,this.offset=e,this.length=0}return t.getKey=function(t){return""+t},t.prototype.add=function(t){this.length+=t},t.prototype.getKey=function(){return""+this.style},t}(),ImageDataWraperType,ImageDataWraper=(function(t){t.base64="base64",t.arraybuffer="arraybuffer",t.bitmap="bitmap",t.empty="empty"}(ImageDataWraperType=ImageDataWraperType||{}),function(){function t(t,e,r){this.hash=t,this.IV=!1,"string"!=typeof e?r&&r.imageBitmap?(this.type=ImageDataWraperType.bitmap,this.status="success",this.data=e):(t=new Blob([e],{type:"image/png"}),(r=URLObject.createObjectURL(t))?(this.data=r,this.type=ImageDataWraperType.arraybuffer,this.status="success"):(this.data="",this.type=ImageDataWraperType.arraybuffer,this.status="error")):(this.data=e,this.type=ImageDataWraperType.base64,this.status="success")}return t.AV=function(t){return createImageBitmap(new Blob([new Uint8Array(t)]))},t.Wb=function(t){var e={data:t.data,type:t.type,status:t.status,IV:t.IV,hash:t.hash};return t.transform(),e},t.prototype.transform=function(){this.IV=!0,this.type===ImageDataWraperType.bitmap&&(this.data="")},t.prototype.destroy=function(){"destroyed"!==this.status&&(this.type===ImageDataWraperType.arraybuffer&&URLObject.revokeObjectURL(this.data),this.data="",this.status="destroyed")},t.prototype.IZ=function(t){var e;this.type===ImageDataWraperType.bitmap?t(this.data):((e=new Image).crossOrigin="",e.onload=function(){t(e)},e.src=this.data)},t}()),EmptyImageDataWraper=new ImageDataWraper("",""),CircleBucket=(EmptyImageDataWraper.type=ImageDataWraperType.empty,function(){function t(){this._b=new SymbolArray,this.uploaded=!1}return t.prototype.wb=function(t,e){var r=this._b.length;return this._b.kb(t[0],t[1],e),this._b.length-r},t.prototype.upload=function(t){this.uploaded||(this.destroy(),this.uploaded=!0,this.zs=t.fe(this._b.Mb,SymbolArray.Rb))},t.prototype.destroy=function(){this.uploaded=!1,this.zs&&this.zs.context&&(this.zs.context.deleteBuffer(this.zs),delete this.zs)},t.prototype.reset=function(){this._b=new SymbolArray,this.uploaded=!1},t}()),SimpleCircleBucket=function(){function t(){this._b=new SimpleSymbolArray,this.uploaded=!1}return t.prototype.wb=function(t){var e=this._b.length;return this._b.kb(t[0],t[1]),this._b.length-e},t.prototype.upload=function(t){this.uploaded||(this.destroy(),this.uploaded=!0,this.zs=t.fe(this._b.Mb,SimpleSymbolArray.Rb))},t.prototype.destroy=function(){this.uploaded=!1,this.zs&&this.zs.context&&(this.zs.context.deleteBuffer(this.zs),delete this.zs)},t.prototype.reset=function(){this._b=new SimpleSymbolArray,this.uploaded=!1},t}(),DistrictLayerStyle=function(){this["stroke-width"]="",this["coastline-stroke"]="",this["nation-stroke"]="",this["province-stroke"]="",this["city-stroke"]="",this["county-stroke"]="",this.fill=""},registry={};function register(t,e,r){void 0===r&&(r={}),Object.defineProperty(e,"yk",{value:t,writable:!1}),registry[t]={mk:e,gk:r.gk||[],wk:r.wk||[]}}function serialize(t,e){if(null==t||"boolean"==typeof t||"number"==typeof t||"string"==typeof t||t instanceof Boolean||t instanceof Number||t instanceof String||t instanceof Date||t instanceof RegExp)return t;if(t instanceof ArrayBuffer)return e&&e.push(t),t;if(Browser.imageBitmap&&t instanceof ImageBitmap)return e&&e.indexOf(t)<0&&e.push(t),t;if(ArrayBuffer.isView(t))return o=t,e&&e.push(o.buffer),o;if(t instanceof ImageData)return e&&e.push(t.data.buffer),t;if(Array.isArray(t)){for(var r=[],n=0,i=t;n<i.length;n++){var a=i[n];r.push(serialize(a,e))}return r}if("object"!=typeof t)throw new Error("can't serialize object of type "+typeof t);var o=t.constructor,s=o.yk;if(!s)throw new Error("can't serialize object of unregistered class");var u,c=void 0;if(o.Wb)c=o.Wb(t,e);else{for(var f in c={},t)!t.hasOwnProperty(f)||0<=registry[s].gk.indexOf(f)||(u=t[f],c[f]=0<=registry[s].wk.indexOf(f)?u:serialize(u,e));t instanceof Error&&(c.message=t.message)}if(c.$name)throw new Error("$name property is reserved for worker serialization logic.");return"Object"!==s&&(c.$name=s),c}function deserialize(t){if(null==t||"boolean"==typeof t||"number"==typeof t||"string"==typeof t||t instanceof Boolean||t instanceof Number||t instanceof String||t instanceof Date||t instanceof RegExp||t instanceof ArrayBuffer||ArrayBuffer.isView(t)||t instanceof ImageData||Browser.imageBitmap&&t instanceof ImageBitmap)return t;if(Array.isArray(t))return map(t,deserialize);if("object"!=typeof t)throw new Error("can't deserialize object of type "+typeof t);var e=t.$name||"Object",r=registry[e].mk;if(!r)throw new Error("can't deserialize unregistered class "+e);if(r.Gb)return r.Gb(t);for(var n=Object.create(r.prototype),i=0,a=Object.keys(t);i<a.length;i++){var o,s=a[i];"$name"!==s&&(o=t[s],n[s]=0<=registry[e].wk.indexOf(s)?o:deserialize(o))}return n}register("Object",Object),register("LineArrayBuffer",LineArrayBuffer),register("TriangleIndexArray",TriangleIndexArray),register("TriangleIndexArrayUint",TriangleIndexArrayUint),register("PolylineBucket",PolylineBucket),register("LinesIndexArray",LinesIndexArray),register("LinesIndexArrayUint",LinesIndexArrayUint),register("FillArray",FillArray),register("PolygonBucket",PolygonBucket),register("CircleBucket",CircleBucket),register("SymbolArray",SymbolArray),register("FillExtrusionBucket",FillExtrusionBucket),register("FillExtrusionArray",FillExtrusionArray),register("SmartArrayBuffer",SmartArrayBuffer),register("Color",Color),register("Segements",NebulaSegements),register("VectorTileSegements",VectorTileSegements),register("VTLineSegement",VTLineSegement),register("LineSegement",LineSegement),register("PolygonSegements",PolygonSegements),register("VectorTile",VectorTile$1),register("VectorTileLayer",VectorTileLayer),register("VectorTileFeature",VectorTileFeature),register("Pbf",Pbf),register("StyleOptionsBuilding",StyleOptionsBuilding),register("DistrictStyleOptions",DistrictLayerStyle),register("MapboxSegements",MapboxSegements),register("MBLineSegement",MBLineSegement),register("ImageDataWraper",ImageDataWraper),register("TileCoord",TileCoord),register("Tile",Tile),register("StyleParser",StyleParser);var LabelTextStyle=function(){function t(t){this.origin=t}return t.BV=function(t,e){var r=DangerousFontSize,n=void 0===(n=t.fontSize)?12:n,i=t.fillColor,a=t.strokeColor,o=void 0===(o=t.strokeWidth)?0:o,s=void 0===(s=t.backgroundColor)?0:s,t=t.borderColor,i=labelsUtil.Yj(Util.color2RgbaArray(void 0===i?[0,0,0,1]:i)),s=s?labelsUtil.Yj(Util.color2RgbaArray(s)):[0,0,0,0],a=labelsUtil.Yj(Util.color2RgbaArray(a),[.988,.988,.988,1]),t=labelsUtil.Yj(Util.color2RgbaArray(t),[.988,.988,.988,1]),u=(n=n||12)<10?.78125:205/256,c=0,r=(o&&(c=u*(1-(10<o*e?10:o)/10.1)),o=1.4142*(r<n||1<e?1.7:1.5)/n,u+1.5/256*(e-1));return(n=new Float32Array(28)).set(i,0),n.set(a,4),n[8]=o,n[9]=c,n[10]=r,n.set(s,11),n.set(t,15),n[19]=1,n.set(i,20),n.set(a,24),n},t.prototype.GV=function(t){switch(t){case"fillColor":return this.origin.slice(0,4);case"strokeColor":return this.origin.slice(4,8);case"backgroundColor":return this.origin.slice(11,15);case"borderColor":return this.origin.slice(15,19);case"u_gamma":return this.origin[8];case"u_borderBuffer":return this.origin[9];case"u_buffer":return this.origin[10];case"u_fontSizeFactor":return this.origin[19];case"u_highlightFillColor":return this.origin.slice(20,24);case"u_highlightStrokeColor":return this.origin.slice(24,28);default:return}},t.prototype.VV=function(t,e){switch(t){case"u_fontSizeFactor":this.origin[19]=e;break;case"fillColor":this.origin.set(e,0);break;case"strokeColor":this.origin.set(e,4);break;case"backgroundColor":this.origin.set(e,11);break;case"borderColor":this.origin.set(e,8);break;case"u_highlightFillColor":this.origin.set(e,20);break;case"u_highlightStrokeColor":this.origin.set(e,24)}},t}(),LabelBucket=(register("LabelTextStyle",LabelTextStyle),function(){function t(t){this.DO={rp:[],pp:[],bd:[],up:0},this.ZO=[],this.options={},this.Gj={},this.Hj={},this.Vj={},this.QO={},this.tI={},this.Fs={},this.$j=0,this.qO={},this.$O=0,this.rI={},this.iO="inner",this._id=Util.stamp(this),this.Mf=t.R_,this.ac=t.z_,this.io=t.canvas,this.NT=t.Nz}return t.prototype.rQ=function(t,e){var r=void 0===(r=e.from)?"inner":r,n=CONSTS.ud,t=(labelsUtil.zj(this,t),this.iO=r,this.Mf&&"SDFManagerBase"!==this.Mf.CLASS_NAME),i=this.DO,a=(t&&(i.rp=new Float32Array(this.$j*n*6)),this.Gj),o=this.Hj,s=this.Vj;if(!o||!s)return null;var r=assign(this.options,e),u=this.RO(a),c=isUndefined(r.opacity)?1:r.opacity;if(t){for(var f=0,h=0,l=0,d=u;l<d.length;l++){for(var v=d[l],g=void 0,p=0,y=v;p<y.length&&!((g=o[y[p]])&&g.text&&g.text.style);p++);var m,b={vd:[]},T=this.ym().KO;g&&g.text&&g.text.style?(m=g.text.style||{},b.vd=new LabelTextStyle(LabelTextStyle.BV(m,void 0===T?1:T))):(b.vd=new LabelTextStyle(new Float32Array(28)),b.vd.VV("u_fontSizeFactor",1)),m=h,b.start=m;var A=isUndefined(A=(T=a[v[0]].opts||{}).opacity)?1:A,x=T.icon&&T.icon[0]&&T.icon[0].image;b.opacity=A,b.rotation=T.rotation,b.opacity*=c,i.pp.push(b),b.dp=[];for(var M=0,S=v;M<S.length;M++){var w=S[M],P=a[w].CO||[],I={height:a[w]&&a[w].opts.height||0,from:e.from,angle:a[w]&&a[w].data.rotation||0},C=this.PO(w,s[w],o[w],i,I),N=this.zV(w,s[w],o[w],a[w],i,I,P),P=this.BO(w,s[w],o[w],a[w],i,P,I);b.dp.push({id:w,Rd:P,icon:C,bg:N,kd:I=6*(P+C+N)}),h+=I*n}b.end=h,b.pd=x,f+=A=h-m,i.bd.push(A)}i.up=f}return i.Fz=u,this.DO=i},t.prototype.destroy=function(){},t.prototype.ym=function(){return this.gs.aO()},t.prototype.zO=function(t){var e;return t?this.qO[t]||(e=labelsUtil.Kj(parseInt(t,10)),this.qO[t]=e,this.qO[t]):[]},t.prototype.RO=function(t){var e,r,n,i,a,o,s,u={},c=this.Gj,f=this.iO;for(e in t)t.hasOwnProperty(e)&&(n=(r=c[e]).data||{},i=(o=r.opts||{}).zIndex,a=o.forceShow,v=n.rank,v=a?v-1e5:v,n=isUndefined(o.opacity)?1:o.opacity,o=void 0===(o=(a=this.Hj[e]||{}).text)?{}:o,a=a.icon,u[i=("labelsLayer"===f?i||v:i)||1]=u[i]||{},o=o&&o.style||"",s=void 0,"labelsLayer"===f?(s=o?labelGroup.nT(o)+n:s,s+=a&&a[0]&&a[0].image?a[0].image:""):s=r.data.extData.Lp?(r.data.extData.Lp<<16)+r.data.extData.Ap:o?labelGroup.nT(o)+n:"-1-"+n,u[i][s]||(u[i][s]=[]),u[i][s].push(e));for(var h=[],l=0,d=labelsUtil.rank(Object.keys(u));l<d.length;l++)for(var v,g=u[v=d[l]],p=0,y=Object.keys(g).sort();p<y.length;p++){var m=y[p];h.push(g[m])}return h},t.prototype.WO=function(t,e){var r=Util.WorldAxesCenter;return[t-r.x,e-r.y]},t.prototype.GO=function(t){return t},t.prototype.HO=function(t,e,r,n,i){var a,o,s=i.VO,u=void 0===(u=i.type)?EnumLabelFragType.icon:u,c=i.zooms,f=i.height,e=void 0===(e=e.icon)?[]:e,h=CONSTS.ud,l=this.$O,d=0,v=0,g=((g=this.ac.getImage(r.image))&&(d=g.startX||0,v=g.startY||0),s[0]),s=s[1],p=c[0],c=c[1],y=exports.cY.icon,e=e.anchorOffset,m=r.size,b=r.clipSize,T=r.clipOrigin,A=m[0],m=m[1],x=b[0],b=b[1],M=T[0],T=T[1],S=(e=this.GO(e))[0]||0,e=e[1]||0,r=((r=r.offset)&&(o=r instanceof Array||void 0===r.x||void 0===r.y?(a=r[0],r[1]):(a=r.x,r.y)),d+M),d=v+T,M=(void 0!==a&&(S+=a),void 0!==o&&(e+=o),-i.angle*Math.PI/180||0);n.set([S,e,r,d,g,s,y,u,p,c,f,M,0,S+A,e,r+x,d,g,s,y,u,p,c,f,M,0,S,m+e,r,d+b,g,s,y,u,p,c,f,M,0,S+A,e,r+x,d,g,s,y,u,p,c,f,M,0,S+A,m+e,r+x,d+b,g,s,y,u,p,c,f,M,0,S,m+e,r,d+b,g,s,y,u,p,c,f,M,0],l),this.$O+=6*h},t.prototype.PO=function(t,e,r,n,i){if(!e||!r)return 0;var a=e.icon;if(!(r=void 0===(r=r.icon)?[]:r).length||!r[0].image)return 0;for(var o=(a=(void 0===a?{}:a).origin)[0],s=a[1],u=(a[2],this.WO(o,s)),c=i.height,f=i.angle,h=0,l=r;h<l.length;h++){var d=l[h];this.HO(t,e,d,n.rp,{VO:u,zooms:d.zooms,height:c,angle:f}),delete d.clipOrigin,delete d.clipSize,delete d.size,delete d.image,delete d.type,delete d.anchor,delete d.retina}return r.length},t.prototype.YO=function(t,e,r,n,i){var a=i.VO,o=void 0===(o=i.type)?EnumLabelFragType.bg:o,s=i.zooms,u=i.height,c=CONSTS.ud,f=CONSTS.Kp,h=this.$O,e=e.padding,l=a[0],a=a[1],d=s[0],s=s[1],v=e.w,g=e.h,f=e.offsetX-f.buffer,e=e.offsetY,i=-i.angle*Math.PI/180||0;if(n.set([f,e,0,0,l,a,0,o,d,s,u,i,0,f+v,e,0,0,l,a,0,o,d,s,u,i,0,f,g+e,0,0,l,a,0,o,d,s,u,i,0,f+v,e,0,0,l,a,0,o,d,s,u,i,0,f+v,g+e,0,0,l,a,0,o,d,s,u,i,0,f,g+e,0,0,l,a,0,o,d,s,u,i,0],h),this.$O+=6*c,h=this.$O,o=r.text.style.borderWidth){for(var p=[f,e,v,g,l,a,o,d,s,u,i],y=0;y<4;y++)p[11]=y,this.sT(p,n,h),h+=6*c;this.$O=h}},t.prototype.sT=function(t,e,r){var n=(t=void 0===t?{}:t)[0],i=t[1],a=t[2],o=t[3],s=t[4],u=t[5],c=t[6],f=t[7],h=t[8],l=t[9],d=t[10],t=t[11],v=EnumLabelFragType.tq,g=0,p=0,y=0,m=0,b=0,T=0,A=0,x=0;switch(t){case 0:m=p=i-c,b=g=n+0,A=y=n+a,x=T=i+0;break;case 1:y=(g=n+a)+c,m=p=i-c,A=(b=n+a)+c,x=T=i+o+c;break;case 2:b=g=n+0,A=y=n+a,x=T=(m=p=i+o)+c;break;case 3:g=n-c,m=p=i-c,b=(y=n)-c,A=n,x=T=i+o+c}e.set([g,p,0,0,s,u,0,v,f,h,l,d,0,y,m,0,0,s,u,0,v,f,h,l,d,0,b,T,0,0,s,u,0,v,f,h,l,d,0,y,m,0,0,s,u,0,v,f,h,l,d,0,b,T,0,0,s,u,0,v,f,h,l,d,0,A,x,0,0,s,u,0,v,f,h,l,d,0],r)},t.prototype.UO=function(t,e,r,n,i){var a,o,s,u,c,f;return e&&r&&(a=CONSTS.Mp,o=CONSTS.Rp,f=e.text,s=(r.text||{}).zooms,r.text)&&f.origin?(u=(f=f.origin)[0],c=f[1],f[2],f=i.height,this.YO(t,e,r,n.rp,{VO:[u,c],zooms:void 0===s?[a,o]:s,height:f}),i=1,r.text.style.borderWidth&&(i+=4),i):0},t.prototype.zV=function(t,e,r,n,i,a,o){if(!e||!r)return 0;var s=CONSTS.Mp,u=CONSTS.Rp,f=e.text.offset,l=(h=(c=r).text||{}).style;h.type;var d=void 0===(d=h.direction)?"left":d,s=void 0===(h=h.zooms)?[s,u]:h;if(!c.text||!c.text.style)return 0;if(o.length,u=!1===(l=void 0===l?{}:l).fold?100:6,h=this.Mf.lineBreak(c.text.txt,{fontSize:l.fontSize,CO:n.CO,type:n.data&&n.data.BG||"ch",fj:u,from:a.from}),o={direction:d,size:l.fontSize,yO:c.icon.length&&c.icon[0].image},c=(u=(n=e.text).origin)[0],e=u[1],u[2],!r.text||!n.origin)return 0;var u=[c,e],n=a.height,c=EnumLabelFragType.bg,v=CONSTS.ud,g=this.$O,e=u[0],u=u[1],p=s[0],s=s[1],y=i.rp,i=h.maxWidth+6,l=l.fontSize*h.width.length+8,h=this.XV(i,d,o.yO),d=f[0]+h[0]-1,o=f[1]-2,h=-a.angle*Math.PI/180||0;if(y.set([d,o,0,0,e,u,0,c,p,s,n,h,0,d+i,o,0,0,e,u,0,c,p,s,n,h,0,d,l+o,0,0,e,u,0,c,p,s,n,h,0,d+i,o,0,0,e,u,0,c,p,s,n,h,0,d+i,l+o,0,0,e,u,0,c,p,s,n,h,0,d,l+o,0,0,e,u,0,c,p,s,n,h,0],g),this.$O+=6*v,g=this.$O,f=r.text.style.borderWidth){for(var m=[d,o,i,l,e,u,f,p,s,n,h],b=0;b<4;b++)m[11]=b,this.sT(m,y,g),g+=6*v;return this.$O=g,5}return 1},t.prototype.CT=function(t,e){return this.Mf?this.Mf.measureText(t,e):this.NT?(this.NT.font=(e||12)+"px",this.NT.measureText(t.join("")).width):0},t.prototype.XO=function(t,e){var r=CONSTS.JM,r=void 0===(n=(e=void 0===e?{}:e).direction)?r.LEFT:n,n=e.size,e=void 0!==(e=e.yO)&&e,t=this.CT(t=void 0===t?[]:t,void 0===n?DangerousFontSize:n);return this.XV(t,r,e)},t.prototype.XV=function(t,e,r){void 0===r&&(r=!1);var n=0,i=0;switch(e){case(r=CONSTS.JM).LEFT:n=-t,i=0;break;case r.QM:i=n=0;break;case r.ZM:case r.tj:n=-t/2,i=0;break;case r.ij:case r.nj:n=-t/2,i=0;break;default:i=n=0}return[n,i]},t.prototype.JO=function(t,e,r,n){var i,a,o,s,u,c,f,h,l,d,v,g,p=CONSTS.ud,y=this.$O,m=n.size,b=n.VO,T=void 0===(T=n.type)?EnumLabelFragType.text:T,A=(n.id,n.zooms),x=n.height,M=CONSTS.Kp,S=this.Mf.mz(e);S&&(i=S.index,g=S.pos,S=S.char,a=b[0],b=b[1],o=A[0],A=A[1],S||(console.log("!metric",e,String.fromCharCode(e)),S=this.Mf.mz(32).char),e=m/M.size,m=S[0],s=S[1],S[2],S[3],S[4],v=S[5],u=S[6],M=M.buffer,0<m&&0<s&&(c=(f=r.x)-M*e,f=+(f+((m+=2*M)-M)*e),h=+((l=r.y)+u*e),l=+(l+((s+=2*M)+u)*e),d=M=0,M=(M+=g.startX)+v,v=(d+=g.startY)+u,g=-n.angle*Math.PI/180||0,t.set([c,h,M,v,a,b,i,T,o,A,x,g,0,f,h,M+m,v,a,b,i,T,o,A,x,g,0,c,l,M,v+s,a,b,i,T,o,A,x,g,0,c,l,M,v+s,a,b,i,T,o,A,x,g,0,f,h,M+m,v,a,b,i,T,o,A,x,g,0,f,l,M+m,v+s,a,b,i,T,o,A,x,g,0],y),this.$O+=6*p),r.x=r.x+(S[0]+CONSTS.ic)*e)},t.prototype.BO=function(t,e,r,n,i,a,o){if(!(e&&r&&r.text&&r.text.txt))return 0;var s=CONSTS.Mp,u=CONSTS.Rp,c=(e=e.text).origin,f=e.offset,h=(e=r.text||{}).style;e.type;var l=void 0===(l=e.direction)?"left":l,d=void 0===(e=e.zooms)?[s,u]:e,v=a,s=c[0],u=c[1];if(c[2],!r.text||!r.text.style)return 0;for(var g=v.length,p=g,e=!1===(h=void 0===h?{}:h).fold?100:6,y=((a=this.Mf.lineBreak(r.text.txt,{fontSize:h.fontSize,CO:(n=void 0===n?{}:n).CO,type:n.data&&n.data.BG||"ch",fj:e,from:o.from})).lines.length,a.oQ),m=h.fontSize,b={direction:l,size:m,yO:r.icon.length&&r.icon[0].image},T=[s,u],A={x:0,y:0},x=o.height,M=o.angle,S=-1,w=0,P=0;P<g;P++){var I=v[P],C=this.eQ(y,w),N=(w+=I.split("|").length,this.nQ(v,y[C],y[C+1])),N=v.slice.apply(v,N),N=this.XO(N,b),N=vector.add(f,N);if(0===C&&0===P&&(A.x=N[0],A.y=N[1]),C&&(A.y=N[1]+(m+3)*C,S!==C)){if("32"===I){p--;continue}A.x=N[0]}S=C,this.JO(i.rp,I,A,{size:m,VO:T,id:t,zooms:d,height:x,angle:M})}return p},t.prototype.nQ=function(t,e,r){for(var n=0,i=0,a=0,o=t.length,s=0;s<o;s++){for(var u=t[s].split("|").length,c=0;c<u;c++){var f=a+c;f===e&&(n=s),f===r&&(i=s)}a+=u}return[n,i=a<=r?o:i]},t.prototype.eQ=function(t,e){for(var r=(t=void 0===t?[]:t).length,n=0;n<r-1;n++)if(e>=t[n]&&e<t[n+1])return n;return 0},t}()),DefaultLabelsLayerOpts={opacity:1,collision:!0,animation:!0},Labels=function(){function t(t){if(this.CLASS_NAME="AMap.LabelsLayer",this.Gj={},this.Hj={},this.Vj={},this.Fs={},this.Es={},this.Wj={},this.$j=0,this.zp={},this.render=null,this.eI={},this.nI=[],this.cI=!1,this.iI=!1,this.iO="",this.cI=!1,this._opts=assign({},DefaultLabelsLayerOpts,{opacity:t.opacity}),this.Mf=t.R_,this.ac=t.z_,this.PN=t.info||{},!this.Mf||"SDFManagerBase"===this.Mf.CLASS_NAME)try{var e=this.io=document.createElement("canvas"),r=void 0;e&&(r=this.NT=e.getContext("2d")),t.canvas=e,t.Nz=r}catch(t){console.log("canvas 初始化失败")}this.sI=new LabelPlacement(t),this.fI=new LabelBucket(t)}return t.prototype.Ns=function(t,e){var r=(e=void 0===e?{}:e).zoom,n=e.center,i=e.from;return this.nI=t,this.iI=!0,this.iO=i,this.eI.zoom=r||20,this.oI(),this.hu=n,this.uI(e)},t.prototype.aO=function(){return this.eI},t.prototype.zL=function(t){return this.Wj[t]},t.prototype.uI=function(t){var e=this.iO,e={center:this.hu,from:e};if(assign(e,t=void 0===t?{}:t),this.sI.nO(this,e),this.$j=this.sI.$j,t=this.fI.rQ(this,e)){var r,n,i,a,o,s,u,c={},f={},e=t.Fz||{},h=(delete t.Fz,this.Gj);if("inner"!==this.iO)return{Nf:h,style:this.Hj,coords:this.Vj,rp:t,zp:this.zp,Fz:e};for(r in h)h.hasOwnProperty(r)&&(n=h[r],i=this.Vj[r],a=(u=n.data).extData,o=u.position,s=u.name,u=u.rank,c[r]={data:{position:o,name:s,rank:u,extData:{type:a.type,id:a.id,Lp:a.Lp,Ap:a.Ap,bz:a.bz}}},f[r]={origin:i.origin,icon:{anchorOffset:i.icon.anchorOffset,size:i.icon.size},padding:i.padding},n.opts)&&(c[r].opts={zooms:n.opts.zooms});return{Nf:c,style:this.Hj,coords:f,rp:t,zp:this.zp,Fz:e}}},t.prototype.oI=function(){for(var t=this.nI,e=this.Gj||{},r=this.Wj,n=this.zp,i=CONSTS.Mp,a=CONSTS.Rp,o=CONSTS.Pp,s=CONSTS.jp,u=0,c=t;u<c.length;u++){for(var f=c[u],h=f.data.id,l=f.opts&&f.opts.zooms||[],d=void 0===(d=l[0])?i:d,v=void 0===(l=l[1])?a:l,g=isUndefined(r[h])?Util.stamp(this):r[h],p=(h&&(r[h]=g),Math.ceil(d-o));p<=v+s;)n[p]||(n[p]=[]),n[p].push(g),p++;e[g]=f,e[g].CO=this.Ws(f),this.hI(f)}if("undefined"!=typeof Uint32Array)for(var y in n)n.hasOwnProperty(y)&&(n[y]=new Uint32Array(n[y]));this.Gj=e},t.prototype.hI=function(t){var e=this.Fs;(t=(t=t.opts.icon)&&t.image||"")&&(e[t]=1)},t.prototype.Ws=function(t){this.Es;var e=t.data.txt||"",t=(t.opts&&t.opts.text||{}).$G||[],e=labelsUtil.EQ(e,t);return labelsUtil.aQ(e)},t}(),DynamicVerticeStyle=function(){},DynamicVertice=function(){function r(t,e){this.zo=t,this.Nf=e.Nf,this.style=e.style,Object.setPrototypeOf(this.style,new DynamicVerticeStyle),this.coords=e.coords,this.rp=e.rp,this.zp=e.zp}return r.Wb=function(t,e){var r={zo:t.zo,coords:t.coords,Nf:t.Nf,style:t.style};return{JSON:JSON.stringify(r),kV:{rp:serialize(t.rp,e),zp:serialize(t.zp,e)}}},r.Gb=function(t){var e=JSON.parse(t.JSON);return t.kV.rp.pp=deserialize(t.kV.rp.pp),e.rp=t.kV.rp,e.zp=t.kV.zp,new r(e.zo,e)},r.prototype.upload=function(t){this.buffer||(this.buffer=t.fe(this.rp.rp,CONSTS.sp))},r.prototype.destroy=function(){this.buffer&&(this.buffer.context.deleteBuffer(this.buffer),delete this.buffer)},r}();function feature(t,e,r){var n={type:"Feature"};return 0!==(r=void 0===r?{}:r).id&&!r.id||(n.id=r.id),r.Ro&&(n.Ro=r.Ro),n.properties=e||{},n.geometry=t,n}function polygon(t,e,r){void 0===r&&(r={});for(var n=0,i=t;n<i.length;n++){var a=i[n];if(a.length<4)throw new Error("Each LinearRing of a Polygon must have 4 or more Positions.");for(var o=0;o<a[a.length-1].length;o++)if(a[a.length-1][o]!==a[0][o])throw new Error("First and last Position are not equivalent.")}return feature({type:"Polygon",coordinates:t},e,r)}function lineString(t,e,r){if(void 0===r&&(r={}),t.length<2)throw new Error("coordinates must be an array of two or more positions");return feature({type:"LineString",coordinates:t},e,r)}function multiLineString(t,e,r){return feature({type:"MultiLineString",coordinates:t},e,r=void 0===r?{}:r)}function multiPolygon(t,e,r){return feature({type:"MultiPolygon",coordinates:t},e,r=void 0===r?{}:r)}function getGeom(t){return"Feature"===t.type?t.geometry:t}function lineclip(t,e,r){var n,i,a,o,s,u=t.length,c=bitCode(t[0],e),f=[];for(r=r||[],n=1;n<u;n++){for(o=t[n-1],i=a=bitCode(s=t[n],e);;){if(!(c|i)){f.push(o),i!==a?(f.push(s),n<u-1&&(r.push(f),f=[])):n===u-1&&f.push(s);break}if(c&i)break;c?c=bitCode(o=intersect(o,s,c,e),e):i=bitCode(s=intersect(o,s,i,e),e)}c=a}f.length&&r.push(f)}function polygonclip(t,e){for(var r,n,i,a,o,s,u=1;u<=8;u*=2){for(r=[],i=!(bitCode(n=t[t.length-1],e)&u),a=0;a<t.length;a++)(s=!(bitCode(o=t[a],e)&u))!==i&&r.push(intersect(n,o,u,e)),s&&r.push(o),n=o,i=s;if(!(t=r).length)break}return r}function intersect(t,e,r,n){return 8&r?[t[0]+(e[0]-t[0])*(n[3]-t[1])/(e[1]-t[1]),n[3]]:4&r?[t[0]+(e[0]-t[0])*(n[1]-t[1])/(e[1]-t[1]),n[1]]:2&r?[n[2],t[1]+(e[1]-t[1])*(n[2]-t[0])/(e[0]-t[0])]:1&r?[n[0],t[1]+(e[1]-t[1])*(n[0]-t[0])/(e[0]-t[0])]:null}function bitCode(t,e){var r=0;return t[0]<e[0]?r|=1:t[0]>e[2]&&(r|=2),t[1]<e[1]?r|=4:t[1]>e[3]&&(r|=8),r}function bboxClip(t,e){var r=getGeom(t),n=r.type,i="Feature"===t.type?t.properties:{},a=r.coordinates;switch(n){case"LineString":case"MultiLineString":var o=[];return(a="LineString"===n?[a]:a).forEach(function(t){lineclip(t,e,o)}),1===o.length?lineString(o[0],i):multiLineString(o,i);case"Polygon":return polygon(clipPolygon(a,e),i);case"MultiPolygon":return multiPolygon(a.map(function(t){return clipPolygon(t,e)}),i);default:throw new Error("geometry "+n+" not supported")}}function clipPolygon(t,e){for(var r=[],n=0,i=t;n<i.length;n++){var a=polygonclip(i[n],e);0<a.length&&(a[0][0]===a[a.length-1][0]&&a[0][1]===a[a.length-1][1]||a.push(a[0]),4<=a.length)&&r.push(a)}return r}register("DynamicVertice",DynamicVertice);var DEF_NDS_MAX_COORD=2147483648,DEF_DEGREE_MAX_COORD=180,MKT=20037508.342789244;function tileInnerCoord2LngLat(t,e,r,n){var a=r+(i=getTileSWCoord(t,e))[0],i=n+i[1];return r=a<<(t=getCoordShift(t.z,e)),n=i<<t,[coord2Degree(r=0<a&&r<0?DEF_NDS_MAX_COORD-1:r),coord2Degree(n)]}function LngLat2TileInnerCoord(t,e,r,n,i){var r=degree2Coord(r),n=degree2Coord(n),a=getCoordShift(i.z,e),n=n>>a;return[(r=r>>a)-(a=getTileSWCoord(i,e))[0],n-a[1]]}var cache={};function lnglat2WGSCoord2(t){var e,r;return cache[t]||(r=33-t,e=degree2Coord(180)/(1<<r),r=degree2Coord(90)/(1<<r),e=0<e?Math.floor(.5+e):Math.floor(e-.5),r=0<r?Math.floor(.5+r):Math.floor(r-.5),cache[t]=[2*e,2*r]),cache[t]}function getWorldSize(t,e){return lnglat2WGSCoord2(t+e)}function getTileSWCoord(t,e){var r=(e=getWorldSize(t.z,e))[0],e=e[1],n=1<<t.z;return[-r/2+t.x*r/n,e/2-(t.y+1)*e/n]}function degree2Coord(t){return Math.floor(t*DEF_NDS_MAX_COORD/DEF_DEGREE_MAX_COORD+.5)}function coord2Degree(t){return t*DEF_DEGREE_MAX_COORD/DEF_NDS_MAX_COORD}function getCoordShift(t,e){return 33-e-t}function getMVTTileBbox(t,e,r,n,i){return[t*(i=void 0===i?256:i)*n-MKT,-((e+1)*i*n-MKT),(t+1)*i*n-MKT,-(e*i*n-MKT)]}var MapboxVTSourceWorker=function(){function t(){}return t.prototype.bw=function(t,e,r,n,i,a){var o=this,s={point:{},line:{},polygon:{},polyhedron:{},label:{}},u=new XMLHttpRequest;return u.onreadystatechange=function(){var t;4!==u.readyState||200!==u.status&&204!==u.status||(s.point=o.AX(i.point),s.line=o.AX(i.line),s.polygon=o.AX(i.polygon),s.polyhedron=o.AX(i.polyhedron),s.label=o.AX(i.label),t=new VectorTile$1(new Pbf(new Uint8Array(u.response))),t=o.Ow(t,{x:e.x,y:e.y,z:e.z,projectionId:r,tileSize:n},s),a(null,exports.Ln({zo:e},t)))},u.responseType="arraybuffer",u.open("GET",t,!0),u.send(),{cancel:function(){u.abort()}}},t.prototype.mX=function(t,e,r){var n={point:{},line:{},polygon:{},polyhedron:{},label:{}};n.point=this.AX(e.point),n.line=this.AX(e.line),n.polygon=this.AX(e.polygon),n.polyhedron=this.AX(e.polyhedron),n.label=this.AX(e.label),this.xw(t,n,!0),this.zw(t,n,!0),this.nz(t,n,!0),this.SX(t,n,!0),this.i1(t,n,!0),r&&r(null,t)},t.prototype.Ow=function(h,t,e){var r=t.x,n=t.y,i=t.z,a=t.tileSize,o=t.projectionId,l=(h.z=i,h.x=r,h.y=n,ProjectionManager.getProjection(o)),t=l.getResolution(i),s=(h.projectionId=o,h.Ro=getMVTTileBbox(r,n,i,t,a),h.zS=lcs.getLocalByCoord([h.Ro[0],h.Ro[1]]),h.visible={point:{},line:{},polygon:{},label:{},polyhedron:{}},ProjectionManager.getProjection(o).getResolution(i));return forIn(h.layers,function(f){var t=f.Cw,e=(f.Ah=[],f.scale=s*a/f.extent,transform[o].Xs(a*r,a*n,i));f.ox=e[0],f.oy=e[1],forEach(t,function(t,e){if((t=f.Gw(e)).Dw(),f.Ah.push(t),t.lines&&0<t.lines.length){t.Rw=[],t.n1=[];for(var r=0,n=t.lines.length;r<n;r++){for(var i=[],a=[],o=0,s=t.lines[r].length;o<s;o++){var u=[f.ox+f.scale*t.lines[r][o][0],f.oy-f.scale*t.lines[r][o][1]],c=[u[0]-h.zS.center[0],u[1]-h.zS.center[1]];a.push(l.unproject(u[0],u[1])),i.push(c)}t.Rw.push(i),t.n1.push(a)}}})}),this.uW(h),this.xw(h,e),this.zw(h,e),this.nz(h,e),this.SX(h,e),this.i1(h,e),h},t.prototype.uW=function(t){for(var e in t.polygons={},t.polygonOut={},t.polyhedrons={},t.polylines={},t.points={},t.layers)if(t.layers.hasOwnProperty(e)){for(var r=t.layers[e],n=[],i=[],a=[],o=[],s=[],u=0;u<r.Ah.length;u+=1){var c=r.Ah[u];if(3==+c.type&&c.Rw){for(var f=c.Rw,h=c.n1,l=[],d=this.g8t(c),v=d.w8t,g=d.height,p=0;p<f.length;p++)PlaneGeometryUtilInstance.isClockwise(f[p])?l.push([p]):l.length&&l[l.length-1].push(p);for(var y=0;y<l.length;y++){var m=l[y];if(1<m.length)if(v){for(var b=[],T=[],A=0;A<m.length;A++){var x=h[m[A]];if(P=this.d8t(t,x)){0<A&&b.push(T.length/2);for(var M=[],S=0;S<P.length;S++){var w=P[S];M.unshift(w[0],w[1])}T.push.apply(T,M)}}a.push({_id_:Util.getGuid("amap_"),properties:c.properties,path:T,LQ:b,height:g})}else{for(b=[],T=[],A=0;A<m.length;A++){var P=f[m[A]];for(0<A&&b.push(T.length/2),S=0;S<P.length;S++){var I=P[S];T.push(I[0],I[1])}i.push({properties:c.properties,path:P,_id_:Util.getGuid("amap_")})}n.push({properties:c.properties,path:T,LQ:b})}else if(v){if(T=[],x=h[m[0]],P=this.d8t(t,x)){for(S=0;S<P.length;S++){var C=P[S];T.unshift(C[0],C[1])}a.push({_id_:Util.getGuid("amap_"),properties:c.properties,path:T,height:g})}}else{for(T=[],P=f[m[0]],S=0;S<P.length;S++){var N=P[S];T.push(N[0],N[1])}n.push({properties:c.properties,path:T}),i.push({properties:c.properties,path:P,_id_:Util.getGuid("amap_")})}}}else if(2==+c.type&&c.Rw)for(var $=0,k=c.Rw.length;$<k;$++)o.push({properties:c.properties,path:c.Rw[$],_id_:Util.getGuid("amap_")});else if(1==+c.type&&c.Rw)for(h=c.n1,y=0;y<c.Rw.length;y++)s.push({_id_:Util.getGuid("amap_"),properties:c.properties,path:c.Rw[y],lnglat:__spreadArrays(h[0][0])});delete c.n1}t.polygons[e]=n,t.polygonOut[e]=i,t.polyhedrons[e]=a,t.polylines[e]=o,t.points[e]=s}delete t.layers},t.prototype.xw=function(t,e,r){if(void 0===r&&(r=!1),!t||!t.$c||r){var n=new VectorTileSegements,i=(t.Uc=n,r||(t.$c=new PolylineBucket),e.line.sourceLayer),a=t.polylines;if(a)for(var o in t.visible.line[i]=[],a)if(!i||i===o)for(var u=a[o],c=0,f=u.length;c<f;c++){var h,l=u[c],v=(d=this.Mn(e.line,l.properties)).color,g=d.lineWidth,p=d.dash,d=+(d.visible||!d.filter);t.visible.line[i]||(t.visible.line[i]=[]),d&&t.visible.line[i].push(l._id_),v[3]*=d,r?n.add(v+":"+g+":"+p,0,l.a1,0,22):(h=(d=t.$c.g0(l.path,{X_:0,lineJoin:"round",lineCap:"butt"})).Iw,d=d.distance,0<h&&(l.a1=h,n.add(v+":"+g+":"+p,0,h,0,22),l.distance=d))}}},t.prototype.zw=function(t,e,r){if(void 0===r&&(r=!1),!t||!t.Dc||r){var n=new VectorTileSegements,i=(t.Oc=n,new VectorTileSegements),a=(t.Fc=i,r||(t.Dc=new PolygonBucket,t.pX=new PolylineBucket),e.polygon.sourceLayer),o=t.polygons;if(o){for(var s in o)if(!a||a===s)for(var u=0,c=(v=o[s]).length;u<c;u++){var f,h=v[u],l=+((g=this.Mn(e.polygon,h.properties)).visible||!g.filter);g.color[3]*=l,r?n.add(g.color+"",0,h.a1,0,22):0<(f=t.Dc.Nx(h.path,h.LQ))&&(h.a1=f,n.add(g.color+"",0,f,0,22))}var d=t.polygonOut;for(s in d)if(!a||a===s)for(var v,u=0,c=(v=d[s]).length;u<c;u++){var g,p,y,m=v[u],l=+((g=this.Mn(e.polygon,m.properties)).visible||!g.filter);t.visible.polygon[a]||(t.visible.polygon[a]=[]),l&&t.visible.polygon[a].push(m._id_),g.borderWidth*=l,r?i.add(g.borderColor+":"+g.dash+":"+g.borderWidth,0,m.a1,0,22):(p=(y=t.pX.g0(m.path,{X_:0,lineJoin:"round",lineCap:"butt"})).Iw,y=y.distance,0<p&&(m.a1=p,i.add(g.borderColor+":"+g.dash+":"+g.borderWidth,0,p,0,22),m.distance=y))}}}},t.prototype.nz=function(t,e,r){if(void 0===r&&(r=!1),!t||!t.A_||r){var n=new NebulaSegements,i=(t.w0=n,r||(t.A_=new FillExtrusionBucket),e.polyhedron.sourceLayer),a=t.polyhedrons;if(a)for(var o in t.visible.polyhedron[i]=[],a)if(!i||i===o)for(var u=a[o],c=0,f=u.length;c<f;c++){var h=u[c],l=h.properties,d=+((l=this.Mn(e.polyhedron,void 0===l?{}:l)).visible||!l.filter);t.visible.polyhedron[i]||(t.visible.polyhedron[i]=[]),d?t.visible.polyhedron[i].push(h._id_):(l.topColor=void 0,l.sideColor=void 0,l.texture=""),r?n.add(h._id_,1e3,h.a1,0,22,l.texture,l.topColor,l.sideColor):0<(d=t.A_.tz(h.path,h.height,h.LQ))&&(h.a1=d,n.add(h._id_,1e3,d,0,22,l.texture,l.topColor,l.sideColor))}}},t.prototype.SX=function(t,e,r){if(void 0===r&&(r=!1),!t||!t.dX||r){var n=t.IX,n=new VectorTileSegements,i=(t.IX=n,t.dX=new CircleBucket,e.point.sourceLayer),a=t.points;if(a)for(var o in t.visible.point[i]=[],a)if(!i||i===o)for(var u=a[o],c=0,f=u.length;c<f;c++){var h=u[c],l=this.Mn(e.point,h.properties);t.visible.point[i]||(t.visible.point[i]=[]),t.visible.point[i].push(h._id_),0<(h=t.dX.wb(h.path[0],l))&&n.add("point",0,h,0,22)}}},t.prototype.i1=function(t,e,r){if(void 0===r&&(r=!1),!t||!t.labels||r){t.labels=[];var n=e.label.sourceLayer,i=(t.visible.label[n]=[],t.points[n]);if(i)for(var a=0,o=i.length;a<o;a++){var s=i[a],c=(u=this.g8t(s)).height,u=u.w8t,f=this.Mn(e.label,s.properties);t.visible.label[n].push(s._id_),t.labels.push(exports.Ln(exports.Ln({},f),{position:u?__spreadArrays(s.lnglat,[c+1]):s.lnglat}))}}},t.prototype.Mn=function(t,e){var r,n={visible:!0,filter:!0};for(r in t){var i=t[r];n[r]="style"===r||"icon"===r||"text"===r?this.Mn(i,e):"function"==typeof i?i()(e,t.injection):i,-1<r.toLowerCase().indexOf("color")&&(n[r]=Util.color2RgbaArray(n[r])),"filter"===r&&(n.filter=this.$X(e,i))}return n},t.prototype.AX=function(t){var e,r={};for(e in t){var n=t[e];n.indexOf&&-1<n.indexOf("function")?(n=n.replace("function","return function"),r[e]=new Function(n)):r[e]="style"===e||"icon"===e||"text"===e?this.AX(n):n}return r},t.prototype.$X=function(t,e){if(e){var r=e[0],n=e[1],i=e[2],a=t[r];switch(n){case"in":return-1<i.indexOf(a);case"out":return i.indexOf(a)<0}}return!0},t.prototype.d8t=function(t,e){var r=t.projectionId,n=t.zS,t=t.Ro,i=ProjectionManager.getProjection(r),r=t[0],a=t[1],o=t[2],t=t[3],r=__spreadArrays(i.unproject(r,a),i.unproject(o,t)),s=null==(a=bboxClip(polygon([e]),r).geometry)?void 0:a.coordinates[0];if(!s)return s;for(var u=[],c=0;c<s.length;c++){var f=s[c],f=i.project(f[0],f[1]);u.push([f[0]-n.center[0],f[1]-n.center[1]])}return u},t.prototype.g8t=function(t){var e="Y"===(t=t.properties||{})._AS_CUBE&&t._HEIGHT_PROP,t=e?+t[t._HEIGHT_PROP]:0;return{w8t:e,height:t=Number.isNaN(t)||t<0?0:t}},t}(),Ring={read:function(t,e){return t.nw(Ring.iw,{path:[]},e)},iw:function(t,e,r){0===t&&r.tw(e.path,!0)},write:function(t,e){if(t.path)for(var r=0;r<t.path.length;r++)e.rw(0,t.path[r])}},Building={read:function(t,e){return t.nw(Building.iw,{minzoom:0,maxzoom:0,path:[],height:0,ew:"",altitude:0},e)},iw:function(t,e,r){0===t?e.minzoom=r.ow():1===t?e.maxzoom=r.ow():2===t?e.path.push(Ring.read(r,r.ow()+r.pos)):3===t?e.height=r.ow():4===t?e.ew=r.aw():5===t&&(e.altitude=r.ow())},write:function(t,e){if(t.minzoom&&e.rw(0,t.minzoom),t.maxzoom&&e.rw(1,t.maxzoom),t.path)for(var r=0;r<t.path.length;r++)e.fw(2,Ring.write,t.path[r]);t.height&&e.rw(3,t.height),t.ew&&e.uw(4,t.ew),t.altitude&&e.rw(5,t.altitude)}},BuildingSameStyle={read:function(t,e){return t.nw(BuildingSameStyle.iw,{mainkey:0,subkey:0,items:[],resolution:0},e)},iw:function(t,e,r){0===t?e.mainkey=r.ow():1===t?e.subkey=r.ow():2===t?e.items.push(Building.read(r,r.ow()+r.pos)):3===t&&(e.resolution=r.ow())},write:function(t,e){if(t.mainkey&&e.rw(0,t.mainkey),t.subkey&&e.rw(1,t.subkey),t.items)for(var r=0;r<t.items.length;r++)e.fw(2,Building.write,t.items[r]);t.resolution&&e.rw(3,t.resolution)}},buildingLayer={read:function(t,e){return t.nw(buildingLayer.iw,{building:[]},e)},iw:function(t,e,r){0===t&&e.building.push(BuildingSameStyle.read(r,r.ow()+r.pos))},write:function(t,e){if(t.building)for(var r=0;r<t.building.length;r++)e.fw(0,BuildingSameStyle.write,t.building[r])}},Poi={read:function(t,e){return t.nw(Poi.IQ,{minzoom:0,maxzoom:0,pos:[],cw:"",ew:"",name:"",rank:0,BQ:"",name_en:"",QQ:"",CQ:"",$G:[],iQ:[],JQ:[]},e)},IQ:function(t,e,r){0===t?e.minzoom=r.ow():1===t?e.maxzoom=r.ow():2===t?r.tw(e.pos,!0):3===t?e.cw=r.aw():4===t?e.ew=r.aw():5===t?e.name=r.aw():6===t?e.rank=r.ow():7===t?e.BQ=r.aw():8===t?e.name_en=r.aw():9===t?e.QQ=r.aw():10===t?e.CQ=r.aw():11===t?r.tw(e.$G):12===t?r.tw(e.iQ):13===t&&r.tw(e.JQ)},write:function(t,e){if(t.minzoom&&e.rw(0,t.minzoom),t.maxzoom&&e.rw(1,t.maxzoom),t.pos)for(var r=0;r<t.pos.length;r++)e.rw(2,t.pos[r]);if(t.cw&&e.uw(3,t.cw),t.ew&&e.uw(4,t.ew),t.name&&e.uw(5,t.name),t.rank&&e.rw(6,t.rank),t.BQ&&e.uw(7,t.BQ),t.name_en&&e.uw(8,t.name_en),t.QQ&&e.uw(9,t.QQ),t.CQ&&e.uw(10,t.CQ),t.$G)for(r=0;r<t.$G.length;r++)e.rw(11,t.$G[r]);if(t.iQ)for(r=0;r<t.iQ.length;r++)e.rw(12,t.iQ[r]);if(t.JQ)for(r=0;r<t.JQ.length;r++)e.rw(13,t.JQ[r])}},PoiSameStyle={read:function(t,e){return t.nw(PoiSameStyle.IQ,{mainkey:0,subkey:0,items:[],resolution:0},e)},IQ:function(t,e,r){0===t?e.mainkey=r.ow():1===t?e.subkey=r.ow():2===t?e.items.push(Poi.read(r,r.ow()+r.pos)):3===t&&(e.resolution=r.ow())},write:function(t,e){if(t.mainkey&&e.rw(0,t.mainkey),t.subkey&&e.rw(1,t.subkey),t.items)for(var r=0;r<t.items.length;r++)e.fw(2,Poi.write,t.items[r]);t.resolution&&e.rw(3,t.resolution)}},PoiLayer={read:function(t,e){return t.nw(PoiLayer.IQ,{poilabel:[]},e)},IQ:function(t,e,r){0===t&&e.poilabel.push(PoiSameStyle.read(r,r.ow()+r.pos))},write:function(t,e){if(t.poilabel)for(var r=0;r<t.poilabel.length;r++)e.fw(0,PoiSameStyle.write,t.poilabel[r])}},Ring$1={read:function(t,e){return t.nw(Ring$1.iw,{path:[]},e)},iw:function(t,e,r){0===t&&r.tw(e.path,!0)},write:function(t,e){if(t.path)for(var r=0;r<t.path.length;r++)e.rw(0,t.path[r])}},Region={read:function(t,e){return t.nw(Region.iw,{minzoom:0,maxzoom:0,path:[],sw:""},e)},iw:function(t,e,r){0===t?e.minzoom=r.ow():1===t?e.maxzoom=r.ow():2===t?e.path.push(Ring$1.read(r,r.ow()+r.pos)):3===t&&(e.sw=r.aw())},write:function(t,e){if(t.minzoom&&e.rw(0,t.minzoom),t.maxzoom&&e.rw(1,t.maxzoom),t.path)for(var r=0;r<t.path.length;r++)e.fw(2,Ring$1.write,t.path[r]);t.sw&&e.uw(3,t.sw)}},RegionSameStyle={read:function(t,e){return t.nw(RegionSameStyle.iw,{mainkey:0,subkey:0,items:[],resolution:0},e)},iw:function(t,e,r){0===t?e.mainkey=r.ow():1===t?e.subkey=r.ow():2===t?e.items.push(Region.read(r,r.ow()+r.pos)):3===t&&(e.resolution=r.ow())},write:function(t,e){if(t.mainkey&&e.rw(0,t.mainkey),t.subkey&&e.rw(1,t.subkey),t.items)for(var r=0;r<t.items.length;r++)e.fw(2,Region.write,t.items[r]);t.resolution&&e.rw(3,t.resolution)}},regionLayer={read:function(t,e){return t.nw(regionLayer.iw,{region:[]},e)},iw:function(t,e,r){0===t&&e.region.push(RegionSameStyle.read(r,r.ow()+r.pos))},write:function(t,e){if(t.region)for(var r=0;r<t.region.length;r++)e.fw(0,RegionSameStyle.write,t.region[r])}},Road={read:function(t,e){return t.nw(Road.iw,{minzoom:0,maxzoom:0,path:[],shield:"",shieldType:0,name:"",rank:0,name_en:"",BQ:"",QQ:"",CQ:"",$G:[],iQ:[]},e)},iw:function(t,e,r){0===t?e.minzoom=r.ow():1===t?e.maxzoom=r.ow():2===t?r.tw(e.path,!0):3===t?e.shield=r.aw():4===t?e.shieldType=r.ow():5===t?e.name=r.aw():6===t?e.rank=r.ow():7===t?e.BQ=r.aw():8===t?e.name_en=r.aw():9===t?e.QQ=r.aw():10===t?e.CQ=r.aw():11===t?r.tw(e.$G):12===t&&(e.id=r.ow())},write:function(t,e){if(t.minzoom&&e.rw(0,t.minzoom),t.maxzoom&&e.rw(1,t.maxzoom),t.path)for(var r=0;r<t.path.length;r++)e.rw(2,t.path[r]);if(t.shield&&e.uw(3,t.shield),t.shieldType&&e.rw(4,t.shieldType),t.name&&e.uw(5,t.name),t.rank&&e.rw(6,t.rank),t.BQ&&e.uw(7,t.BQ),t.name_en&&e.uw(8,t.name_en),t.QQ&&e.uw(9,t.QQ),t.CQ&&e.uw(10,t.CQ),t.$G)for(r=0;r<t.$G.length;r++)e.rw(11,t.$G[r]);t.id&&e.rw(12,t.id)}},RoadSameStyle={read:function(t,e){return t.nw(RoadSameStyle.iw,{mainkey:0,subkey:0,items:[],resolution:0},e)},iw:function(t,e,r,n){0===t?e.mainkey=r.ow():1===t?e.subkey=r.ow():2===t?e.items.push(Road.read(r,r.ow()+r.pos)):3===t&&(e.resolution=r.ow())},write:function(t,e){if(t.mainkey&&e.rw(0,t.mainkey),t.subkey&&e.rw(1,t.subkey),t.items)for(var r=0;r<t.items.length;r++)e.fw(2,Road.write,t.items[r]);t.resolution&&e.rw(3,t.resolution)}},roadLayer={read:function(t,e){return t.nw(roadLayer.iw,{road:[]},e)},iw:function(t,e,r,n){0===t&&e.road.push(RoadSameStyle.read(r,r.ow()+r.pos))},write:function(t,e){if(t.road)for(var r=0;r<t.road.length;r++)e.fw(0,RoadSameStyle.write,t.road[r])}},roadNameLayer={read:function(t,e){return t.nw(roadNameLayer.iw,{roadName:[]},e)},iw:function(t,e,r,n){0===t&&e.roadName.push(RoadSameStyle.read(r,r.ow()+r.pos))},write:function(t,e){if(t.roadName)for(var r=0;r<t.road.length;r++)e.fw(0,RoadSameStyle.write,t.roadName[r])}},Result={read:function(t,e){return t.nw(Result.IQ,{tiles:[],version:"",status:!1,db:""},e)},IQ:function(t,e,r){0===t?e.tiles.push(Result.Gh.read(r,r.ow()+r.pos)):1===t?e.version=r.aw():2===t?e.status=r.vw():3===t&&(e.db=r.aw())},write:function(t,e){if(t.tiles)for(var r=0;r<t.tiles.length;r++)e.fw(0,Result.Gh.write,t.tiles[r]);t.version&&e.uw(1,t.version),t.status&&e.hw(2,t.status),t.db&&e.uw(3,t.db)},Gh:{}},Style=(Result.Gh.read=function(t,e){return t.nw(Result.Gh.IQ,{z:0,x:0,y:0,layers:[],t:0},e)},Result.Gh.IQ=function(t,e,r){0===t?e.z=r.ow():1===t?e.x=r.ow():2===t?e.y=r.ow():3===t?e.layers.push(Result.Gh.lw.read(r,r.ow()+r.pos)):4===t&&(e.t=r.ow())},Result.Gh.write=function(t,e){if(t.z&&e.rw(0,t.z),t.x&&e.rw(1,t.x),t.y&&e.rw(2,t.y),t.layers)for(var r=0;r<t.layers.length;r++)e.fw(3,Result.Gh.lw.write,t.layers[r]);t.t&&e.rw(4,t.t)},Result.Gh.lw={},Result.Gh.lw.read=function(t,e){return t.nw(Result.Gh.lw.IQ,{z:0,x:0,y:0,type:0,d:null,t:0},e)},Result.Gh.lw.IQ=function(t,e,r){0===t?e.z=r.ow():1===t?e.x=r.ow():2===t?e.y=r.ow():3===t?e.type=r.ow():4===t?e.d=r.mw():5===t&&(e.t=r.ow())},Result.Gh.lw.write=function(t,e){t.z&&e.rw(0,t.z),t.x&&e.rw(1,t.x),t.y&&e.rw(2,t.y),t.type&&e.rw(3,t.type),t.d&&e.ww(4,t.d),t.t&&e.rw(5,t.t)},{read:function(t,e){return t.nw(Style.IQ,{bgColor:"",zn:0,xV:"",stylemaps:[],test:0},e)},IQ:function(t,e,r){1===t?e.bgColor=r.aw():2===t?e.zn=r.ow(!0):3===t?e.xV=r.aw():4===t?e.stylemaps.push(Style.SV.read(r,r.ow()+r.pos)):5===t&&(e.test=r.ow(!0))},write:function(t,e){if(t.bgColor&&e.uw(1,t.bgColor),t.zn&&e.rw(2,t.zn),t.xV&&e.uw(3,t.xV),t.stylemaps)for(var r=0;r<t.stylemaps.length;r++)e.fw(4,Style.SV.write,t.stylemaps[r]);t.test&&e.rw(5,t.test)},SV:{}}),decodeStyle=(Style.SV.read=function(t,e){return t.nw(Style.SV.IQ,{key:[],browserStyle:[],levelStyleMapping:[]},e)},Style.SV.IQ=function(t,e,r){1===t?e.key.push(r.aw()):2===t?e.browserStyle.push(r.aw()):3===t&&r.tw(e.levelStyleMapping,!0)},Style.SV.write=function(t,e){if(t.key)for(var r=0;r<t.key.length;r++)e.uw(1,t.key[r]);if(t.browserStyle)for(r=0;r<t.browserStyle.length;r++)e.uw(2,t.browserStyle[r]);if(t.levelStyleMapping)for(r=0;r<t.levelStyleMapping.length;r++)e.rw(3,t.levelStyleMapping[r])},function(t){return t=new Pbf(t),Style.read(t)}),decodePois=function(t){return t=new Pbf(t),PoiLayer.read(t)},decodeRoads=function(t){return t=new Pbf(t),roadLayer.read(t)},decodeRoadNames=function(t){return t=new Pbf(t),roadNameLayer.read(t)},decodeRegions=function(t){return t=new Pbf(t),regionLayer.read(t)},decodeBuildings=function(t){return t=new Pbf(t),buildingLayer.read(t)},decodeTiles=function(t){for(var t=new Pbf(t),e=(t=Result.read(t)).tiles,r=0,n=e.length;r<n;r+=1)for(var i=e[r].layers,a=0,o=i.length;a<o;a+=1)switch(i[a].type){case 0:i[a].d=decodePois(i[a].d);break;case 1:i[a].d=decodeRoads(i[a].d);break;case 2:i[a].d=decodeRegions(i[a].d);break;case 3:i[a].d=decodeBuildings(i[a].d);break;case 4:i[a].d=decodeRoadNames(i[a].d)}return t},CONSTS$2={_U:["th","my"]},SDFManagerBase=function(e){function t(){var t=e.call(this)||this;return t.CLASS_NAME="SDFManagerBase",t}return __extends(t,e),t.jU=function(t){return t=LangManager.gG(t+""),-1!==CONSTS$2._U.indexOf(t)},t.prototype.FU=function(t){for(var e=[],r=0,n=t;r<n.length;r++){var i=n[r];LangManager.gG(i+""),e.push(i)}return{UU:e,DU:[]}},t.prototype.measureText=function(t,e,r){if(r){r.font=(e||12)+"px";for(var n="",i=0,a=t;i<a.length;i++){var o=a[i];n+=String.fromCharCode(o)}return r.measureText(n).width}return 0},t.prototype.lineBreak=function(t,e){var n=void 0===(r=(e=void 0===e?{}:e).fontSize)?12:r,r=e.maxWidth,i=e.CO,a=void 0===(a=e.fj)?6:a,s=void 0===(o=e.type)?"en":o,u=e.YQ,c=(t=void 0===t?"":t).split(" "),f=[],o=r||90,h=0,l=[],d=[],v=[0];if("labelsLayer"===e.from){for(var g=t.length,p=Math.ceil(g/a),y=Math.ceil(g/p),m=void 0,b=0,T=0;T<p;T++){l[T]||(l[T]=[b]),0===T?m=i.slice(0,b=g%y||y):(m=i.slice(b,b+y),b+=y);var A=this.measureText(m,n,u);d.push(A),l[T].push(b)}for(T=0;T<l.length;T++){var x=l[T];v.push(x[x.length-1])}}else if("ch"===s)for(T=b=0;T<c.length;T++){for(var x=c[T],m=[],M=0;M<x.length;M++)m.push(x.charCodeAt(M));A=this.measureText(m,n,u),d.push(A),l.push([b,b+x.length+1]),b+=x.length+1,v.push(b)}else{for(T=0;T<c.length;T++){var S=c[T],m=[];if("en"===s)for(var w=0;w<S.length;w++)m.push(S.charCodeAt(w));else{var P=-1===(P=i.indexOf("32",h))?i.length:P;m=i.slice(h,P),h=P+1}A=this.measureText(m,n,u),f.push(A)}for(r=Math.max.apply(Math,f),l=(e=this.GU(f,o<r?r:o)).lines,d=e.BU,T=0;T<l.length;T++){var x=l[T],I=c.slice(x[0],x[x.length-1]+1).join(" "),C=t.indexOf(I),I=I.length-1;v.push(C+I+1)}}return{lines:l,oQ:v,width:d,maxWidth:Math.max.apply(Math,d)}},t.prototype.GU=function(t,e){for(var r=[],n=0,i=0,a=[],o=0,s=t.length,u=0;u<s;u++){var c=t[u];i+=c,r[n]||(r[n]=[]),e<i&&(r[++n]=[],a.push(o),o=i=0),r[n].push(u),o+=c,u===s-1&&a.push(o)}return{lines:r,BU:a}},t.prototype.destroy=function(){},t}(Event),LoadFlag,SDFManagerWorker=(function(t){t.TEXTUREFINISH="TEXTUREFINISH",t.UNLOAD="unload",t.LOADING="loading",t.LOADED="loaded",t.FAIL="fail"}(LoadFlag=LoadFlag||{}),function(t){t.AllLoaded="AllLoaded",t.AllUnLoaded="AllUnLoaded",t.SomeLoading="SomeLoading",t.AllLoading="AllLoading"}(exports.qu||(exports.qu={})),function(r){function t(t){var e=r.call(this)||this;return e.CLASS_NAME="SDFManagerWorker",e.protocol="https",e.range=[],e.info={},e.dc=0,e._c={},e._size=24,e.nc=new AdaptorMap,e.xc=[],e.bc={},e.Xu={},e.yc=1,e.fN={},e.ac=t.z_,e._parent=t.parent,e}return __extends(t,r),t.prototype.vW=function(t,e){var n=void 0===(r=e.tiles)?[]:r,i=e.cb,a=e.optimalZoom,r=void 0===(r=e.tags)?[]:r,o=e.stamp;this.cN=a,this.fN[o]||(this.fN[o]=r);for(var s=0;s<n.length;s++){var u=n[s],c=this.Zu(t);e.result=c,this.loadData(t,{tile:u,result:c,cb:i,optimalZoom:a,stamp:o,i:s})}},t.prototype.loadData=function(t,e){var r=this,n=e.cb,i=e.tile,a=e.result,o=(e.optimalZoom,e.stamp),s=e.i,u=a||this.Zu(t);switch(u.status){case exports.qu.AllLoaded:n([]);break;case exports.qu.AllUnLoaded:var c=this.Yu(n,{tile:i,stamp:o,index:s});this.MI(u.Vu,function(t){r.Xu[c]=t=void 0===t?{}:t,r.Hu()});break;case exports.qu.SomeLoading:var f=this.Yu(n,{tile:i,stamp:o,index:s});this.MI(u.Vu,function(t){r.Xu[f]=t=void 0===t?{}:t,r.Hu()});break;case exports.qu.AllLoading:var h=this.Yu(n,{tile:i,stamp:o,index:s});this.Xu[h]=[],this.Hu()}},t.prototype.mz=function(t){var e=this.info||{};return e[t]&&(e=e[t]).pos&&e.info[t]?{key:t,index:exports.cY.dynamic,char:e.info[t],pos:e.pos}:null},t.prototype.measureText=function(t,e){for(var r=CONSTS.ic,n=0,i=this.info,a=e/this._size,o=this.nc,s=0,u=t;s<u.length;s++){var c=u[s],f=void 0,h=c;(f=o.get(h))||i.hasOwnProperty(h)&&(h=i[h].info[h])&&this.nc.set(c,f=h[4]),n+=(f+r)*a}return n},t.prototype.Ju=function(t){for(var e={},r=0,n=t;r<n.length;r++){var a=(i=n[r]).range,o=i.info,i=i.pos,s=this.info;s[a],s[a]={info:((s={})[a]=o,s),pos:i},this.range.push(a),e[a]=1}return e},t.prototype.AI=function(t,e){this.info[t]&&(this.info[t].pos=e)},t.prototype.MI=function(e,r){for(var n=this,t=(void 0===e&&(e=[]),CONSTS.Mj),i=0,a=e;i<a.length;i++){var o=a[i];this._c[o]=!0}for(var s=[],u=0,c=this.FU(e),f=c.UU,h=c.DU,l=h.length,d=Math.ceil(l/CONSTS.Mj);u<d;){var v=h.slice(v=t*u,l<v+t?l:v+t),v=this.xI(v);s.push(v),u++}s.push(this.pG(f)),Promise.all(s).then(function(t){n.II(e),t=n.zU(t),n.Ju(t),r(t)})},t.prototype.pG=function(t){var r=this;return new Promise(function(e){r._parent.loadWordsByFront({Es:t,cb:function(t){e(t)}})})},t.prototype.xI=function(t){var a=this,e=this.fc()+("/getsdfdata?chars="+t.join(",").split(",").join("|"));return new Promise(function(n,i){XHR.send(e,{Me:"json",method:"get",qw:function(t){var e,r;t&&t.info?(e=a.vc(t.info),r=new ImageDataWraper(e,t.url),t.url=r,n({range:e,info:t})):i(null)},error:function(){i(null)}})})},t.prototype.fc=function(){var t=CONSTS.pc,e=this.protocol+t[this.dc];return this.dc=(this.dc+1)%t.length,e},t.prototype.vc=function(t){void 0===t&&(t={});(t=map(Object.keys(t),function(t){return parseInt(t,10)})).sort(function(t,e){return t-e});var e=t.length;return 2<=e?t[0]+"-"+t[e-1]:1===e?""+t[0]:""},t.prototype.gc=function(t){var e=this.range||[],r=this.info||{};if(-1!==e.indexOf(t))return!0;for(var n=parseInt(t,10),i=0,a=e;i<a.length;i++){var o=a[i];if(o.indexOf("-")<0){if(n===+o&&(r[o]&&r[o].info||{})[t])return!0}else{var s=o.split("-"),u=parseInt(s[0]||"",10),s=parseInt(s[1]||"",10);if(u<=n&&n<=s&&(r[o]&&r[o].info||{})[t])return!0}}return!1},t.prototype.wc=function(t){return this._c[t]},t.prototype.Zu=function(t){for(var e=[],r=0,n=0,i=0,a=t;i<a.length;i++){var o=a[i];this.gc(o)||(this.wc(o)?n+=1:(r+=1,e.push(o)))}return 0===n&&0===r?{status:exports.qu.AllLoaded,Vu:e}:0<r&&0===n?{status:exports.qu.AllUnLoaded,Vu:e}:0===r&&0<n?{status:exports.qu.AllLoading,Vu:e}:{status:exports.qu.SomeLoading,Vu:e}},t.prototype.Yu=function(t,e){void 0===e&&(e={});var r=this.yc+=1;return this.xc.push(r),this.bc[r]=t,this.bc[r]={cb:t,params:e},r},t.prototype.Hu=function(){var t,e,r=this.xc[0];r&&(t=this.Xu[r])&&(this.xc.shift(),(e=this.bc[r])?e.cb(t):console.error("sdf task error"),delete this.Xu[r],delete this.bc[r],this.Hu())},t.prototype.II=function(t){for(var e=0,r=t;e<r.length;e++){var n=r[e];delete this._c[n]}},t.prototype.zU=function(t){for(var e=[],r=0,n=t=void 0===t?[]:t;r<n.length;r++){var i=n[r];if(Array.isArray(i))for(var a=0,o=i;a<o.length;a++){var s=o[a];e.push(s)}else e.push(i)}return e},t}(SDFManagerBase)),TaskManager=(function(t){t[t.stop=0]="stop",t[t.finish=1]="finish",t[t.pause=2]="pause"}(exports.vY||(exports.vY={})),function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.id=0,t.LV=[],t._V={},t.CV={},t}return __extends(t,e),t.prototype.register=function(t,e,r){if(this.CV[t])throw Error("TaskManager: Exist Task Creator");this.CV[t]={PV:e,OV:r}},t.prototype.add=function(t,e){var r;if(this.CV[t])return t=this.CV[t],r=this.id++,e=t.PV(e),this.LV.push({UQ:e,OV:{id:r,kY:t.OV.kY}}),r;throw Error("TaskManager: Not Exist Task Type")},t.prototype.XQ=function(t,e,r){void 0===e&&(e={kY:1/0}),void 0===r&&(r=!1);var n=this.id++;return r?this.LV.unshift({UQ:t,OV:{id:this.id++,kY:e.kY}}):this.LV.push({UQ:t,OV:{id:this.id++,kY:e.kY}}),n},t.prototype.exec=function(t){this.jV();for(var e=t,r=Date.now();0<e;){var n=this.LV.shift();if(!n)break;var i=n.UQ.play(e);n.UQ.status===exports.vY.finish?this.emit("task:"+n.OV.id,{data:i}):this.LV.unshift(n),e=t-(Date.now()-r),0===this.LV.length&&this.emit("taskclear",!0)}},t.prototype.xY=function(){return 0<this.LV.length},t.prototype.destroy=function(){this.LV=[]},t.prototype.clear=function(e){this.LV=e?this.LV.filter(function(t){return t.UQ.type===e}):[]},t.prototype.jV=function(){this.LV.sort(function(t,e){return t.OV.kY-e.OV.kY})},t}(Event)),Actor=function(){function t(t,e,r){this.UD=!1,this.gI=this.gI.bind(this),this.target=t,this.parent=e,this.dI=r,this.pI={},this.bI=Browser.DW?1:0,this.target.addEventListener("message",this.gI,!1)}return t.prototype.send=function(t,e,r,n){var i=this,a=r?this.dI+":"+this.bI:null,o=(this.bI+=2,r&&a&&(this.pI[a]=r),[]),s=serialize(e,o);if(this.target.postMessage({yI:n,mI:this.dI,type:t,id:String(a),data:s},o),r)return{cancel:function(){i.target.postMessage({yI:n,mI:i.dI,type:"<cancel>",id:String(a),key:e.ya}),a&&delete i.pI[a]}}},t.prototype.gI=function(t){var n,e,i=this;Browser.DW&&"destroy"===t.data.type&&self.close();var a=(t=t.data).id;t.yI&&this.dI!==t.yI||("<cancel>"===t.type?(e=this.pI[t.id],delete this.pI[t.id],e&&e("<cancel>")):"<response>"===t.type?(e=this.pI[t.id],delete this.pI[t.id],e&&t.error?e(deserialize(t.error)):e&&e(null,deserialize(t.data))):void 0!==t.id&&this.parent[t.type]&&(n=function(t,e){delete i.pI[a];var r=[],e=serialize(e,r);i.target.postMessage({mI:i.dI,type:"<response>",id:String(a),error:t?serialize(t):null,data:e},r),n=void 0},this.pI[t.id]=null,e=this.parent[t.type](t.mI,deserialize(t.data),n))&&null===this.pI[t.id]&&(this.pI[t.id]=e.cancel))},t.prototype.remove=function(){this.target.removeEventListener("message",this.gI,!1)},t}(),TaskPool=function(){function t(){this.listener={},this.SN={}}return t.prototype.nS=function(r,t){var n=this;return this.SN[r]=!0,this.listener[r]||(this.listener[r]=[]),t(function(t,e){n.$N(r,t,e)})},t.prototype.cancel=function(t){delete this.SN[t]},t.prototype.has=function(t){return Boolean(this.SN[t])},t.prototype.GN=function(t){return this.listener[t]&&0<this.listener[t].length},t.prototype.SH=function(t,e){this.listener[t]||(this.listener[t]=[]),this.listener[t].push(e)},t.prototype.kN=function(t,e){this.listener[t]&&-1<(e=this.listener[t].indexOf(e))&&this.listener[t].splice(e,1)},t.prototype.$N=function(t,e,r){delete this.SN[t];var n=this.listener[t];if(delete this.listener[t],n)for(var i=0,a=n;i<a.length;i++)(0,a[i])(e,r)},t}(),StaticSDFManagerWorker=function(){function t(t,e){this.parent=t,this.CN=e,this.jN=[],this.EN=0,this._N={},this.NN={},this.LN=new TaskPool,this.zW(this.parent.GW.db),this.parent.Uh.send("updateDataVersion",this.parent.GW.nebulaVersion)}return t.prototype.loadData=function(t,o,r){var s,u,c,n,e,f,h=this,l=staticSDFTileKeyToKey(t);return l?(s=this.fc(),u=s+l+".json",c=s+l+(o.mH?".webp":".png"),n=this.parent.protocol,void 0!==this._N[l]&&void 0!==this.NN[l]?(r(null,[this._N[l],this.NN[l]]),{cancel:noop$1}):(e=this.LN.has(l),this.LN.SH(l,f=function(t,e){e&&(e.protocol=n),r(t,e)}),e?{cancel:function(){h.NW(t)}}:this.LN.nS(l,function(r){function n(t,e){r(null,e)}var i=0,a=[],t=h.ON(u,function(t,e){t?"404"!==t?(console.log(t),n(0,null)):(a[0]=e?{}:null,h._N[l]=a[0],2==++i&&n(0,a)):(a[0]=e,h._N[l]=e,2==++i&&n(0,a))}),e=h.IN(c,function(t,e){t||!e?"404"!==t?(console.log(t),n(0,e)):(a[1]=null,h.NN[l]=a[1],2==++i&&n(0,a)):!e||e.byteLength<128?(a[1]=null,h.NN[l]=a[1],2==++i&&n(0,a)):o.imageBitmap?ImageDataWraper.AV(e).then(function(t){"success"!==(t=new ImageDataWraper(c,t,{imageBitmap:!0})).status?(console.log("createObjectURL fail"),r("createObjectURL fail",null)):(a[1]=t,h.NN[l]=t,2==++i&&n(0,a))}):"success"!==(t=new ImageDataWraper(s,e)).status?(console.log("createObjectURL fail"),n(0,null)):(a[1]=t,h.NN[l]=t,2==++i&&n(0,a))});return"lesszoom10"!==l?{cancel:function(){h.LN.kN(l,f),h.LN.GN(l)||(t.abort(),e.abort(),h.LN.cancel(l)),f("cancel",null)}}:{cancel:function(){h.LN.kN(l,f),f("cancel",null)}}}))):(console.log("!key"),r(null,[void 0,null]),{cancel:noop$1})},t.prototype.NW=function(t){var e=this.NN[t];e&&e.destroy(),delete this.NN[t],delete this._N[t]},t.prototype.zW=function(t){this._N={},this.NN={},this.jN=["://glyph.amap.com/sdf"+t+"/","://glyph01.amap.com/sdf"+t+"/","://glyph02.amap.com/sdf"+t+"/","://glyph03.amap.com/sdf"+t+"/","://glyph04.amap.com/sdf"+t+"/"]},t.prototype.ON=function(t,e){return this.CN.send(t,{Me:"json",method:"get",qw:function(t){e(null,t||null)},Aw:function(t){e(t&&t.message||"unknown error")}})},t.prototype.IN=function(t,e){return this.CN.send(t,{Me:"arraybuffer",method:"get",qw:function(t){t?e(null,t):e("empty data",null)},Aw:function(t){e(t&&t.message||"unknown error")}})},t.prototype.fc=function(){this.EN=this.EN%this.jN.length;var t=this.parent.protocol+this.jN[this.EN];return this.EN++,t},t}(),emptyObj={},SDFStaticTextureCache=function(){function t(t,e,r){this.parent=t,this.DN=e,this.UN=r,this.RN={},this.XN={}}return t.prototype.xH=function(t,e){void 0===e&&(e=!1);var r=staticSDFTileKeyToKey(t),n=this.RN[r];if(e){if(!n)return;n.indexOf(t)<0&&n.push(t)}return this.DN.getImage(r)},t.prototype.LB=function(t){return t=staticSDFTileKeyToKey(t),this.XN[t]||emptyObj},t.prototype.bH=function(n,i,a,o){var t,s=this,u=staticSDFTileKeyToKey(n);i.type===ImageDataWraperType.bitmap?i.IV?(t=this.DN.getImage(i.hash),o(null,t)):this.DN.addImageBitmap(i.data,{url:u,cb:function(t,e){var r;t||(i.destroy(),s.RN[u]||(s.RN[u]=[],s.XN[u]=a),(r=s.RN[u]).indexOf(n)<0&&r.push(n)),o(t,e)}}):this.DN.addImage(u,{url:i.data,cb:function(t,e){var r;t||(s.RN[u]||(s.RN[u]=[],s.XN[u]=a),(r=s.RN[u]).indexOf(n)<0&&r.push(n)),o(t,e)}})},t.prototype.kH=function(t){var e=staticSDFTileKeyToKey(t),r=this.RN[e];r?(0<=(t=r.indexOf(t))&&r.splice(t,1),0===r.length&&(this.DN.RH(e),this.UN.deleteTileStaticSDF(e),delete this.RN[e],delete this.XN[e])):delete this.XN[e]},t}(),RenderThread=function(){function t(t){this.Jv=5,this.Qv=0,this.Yv=!1,this.render=t.render,this.check=t.check}return t.prototype.Yf=function(){this.Yv||(0<this.Jv&&this.Kv?(this.render(),this.Qv=Util.requestAnimFrame(this.Yf.bind(this))):(this.Jv<=0||!this.Kv)&&(this.Kv=!1,Util.cancelAnimFrame(this.Qv),this.Qv=0,this.Qv||this.check()&&(this.render(),this.setNeedUpdate(!0))),this.Jv--)},t.prototype.setNeedUpdate=function(t){this.Jv=5,t&&!this.Kv&&(this.Kv=t,Util.cancelAnimFrame(this.Qv),this.Qv=0,this.to()),this.Kv=t},t.prototype.to=function(){this.Qv||(this.Qv=Util.requestAnimFrame(this.Yf.bind(this)))},t.prototype.destroy=function(){this.Yv=!0},t}();Uint8Array.prototype.fill||(Uint8Array.prototype.fill=Array.prototype.fill),Float32Array.prototype.slice||Object.defineProperty(Float32Array.prototype,"slice",{value:function(t,e){return new Float32Array(Array.prototype.slice.call(this,t,e))}}),Float64Array.prototype.slice||Object.defineProperty(Float64Array.prototype,"slice",{value:function(t,e){return new Float64Array(Array.prototype.slice.call(this,t,e))}}),exports.Ge=AMapStyleSource,exports.Bh=Actor,exports.OZ=AdaptorMap,exports.bb=BezierUtil,exports.tc=CONSTS,exports._n=Color,exports.ZQ=ComputeTileRange,exports.hL=Coordinate,exports.PY=DangerousFontSize,exports.La=DynamicVertice,exports.Event=Event,exports.iz=FillExtrusionBucket,exports.GeometryUtil=GeometryUtil,exports.rW=GeometryUtilCls,exports.x_=HALF_WORLD_SIZE,exports.WQ=ImageDataWraper,exports.pZ=InnerClass,exports.eG=Labels,exports.LabelsRenderUtil=LabelsRenderUtil,exports.bG=LangManager,exports.LngLat=LngLat$2,exports.ZY=LngLat2TileInnerCoord,exports.za=LocalTileZoom,exports.Ra=LocalZoom,exports.MapboxLabelFormat=MapboxLabelFormat,exports.fQ=MapboxSegements,exports.bX=MapboxVTSourceWorker,exports.Module=Module,exports.NebulaLabelFormat=NebulaLabelFormat,exports._w=NebulaSegements,exports.pa=NebulaTile,exports.wa=NebulaTileCoord,exports.pw=Pbf,exports.Pixel=Pixel,exports.PlaneGeometryUtil=PlaneGeometryUtil,exports.kS=PlaneGeometryUtilInstance,exports.K_=PolygonBucket,exports.oE=PolygonSegements,exports.J_=PolylineBucket,exports.ProjectionManager=ProjectionManager,exports.tS=Queue,exports.Vs=RasterTile,exports.wY=RenderThread,exports.vG=SDFManagerBase,exports.jb=SDFManagerWorker,exports.LH=SDFStaticTextureCache,exports.e0=SimpleCircleBucket,exports.Size=Size,exports.yp=SmartArrayBuffer,exports.xW=StaticSDFManagerWorker,exports.StyleParser=StyleParser,exports.Support=Browser,exports.vH=Task,exports.MY=TaskManager,exports.IH=TaskPool,exports.Gh=Tile,exports.ca=TileCoord,exports.V=transform,exports.Util=Util,exports.Sw=VectorTile,exports.tW=VectorTile$1,exports.LW=VectorTileSegements,exports.Yw=XHR,exports.T8t=__awaiter,exports.dZ=__decorate,exports.Ei=__extends,exports.x8t=__generator,exports.Pt=__spreadArrays,exports.assign=assign,exports.jw=calcTileMectorBounds,exports.clone=clone,exports.Ex=clone$1,exports.yn=cloneDeep,exports.create=create$3,exports.Il=create,exports.Dl=create$1,exports.Zl=create$2,exports.M8t=createCommonjsModule,exports.CZ=decodeStyle,exports.KQ=decodeTiles,exports.equals=equals$1,exports.Ru=equals,exports.every=every,exports.extend=extend,exports.filter=filter,exports.find=find,exports.findIndex=findIndex,exports.forEach=forEach,exports.vx=forIn,exports.Bu=fromValues$2,exports.xd=fromValues$3,exports.$Q=getMVTTileBbox,exports.vZ=getOutseaData,exports.Ol=getTranslation,exports.Ul=invert,exports.VB=isBezierCurve,exports.xs=isBounds,exports.sB=isCircleMarker,exports.isEmpty=isEmpty,exports.isEqual=isEqual,exports.isFunction=isFunction,exports.qG=isInnerLabelsLayer,exports.px=isLayer,exports.Bs=isLngLat,exports.iL=isLnglatLikeArray,exports.eL=isLnglatLikeArrayArray,exports.yL=isLnglatLikeArrayArrayArray,exports.vB=isNumber,exports.ys=isNumberArrayArray,exports.Ox=isNumberArrayArrayArray,exports.tL=isNumberArrayArrayArrayArray,exports.er=isOverlay,exports.RF=isOverlayGroup,exports.oy=isPixel,exports.GB=isPolyline,exports.ay=isSize,exports.FF=isVectorLayer,exports.jsonLngLatData=jsonLngLatData,exports.keys=keys,exports.labelsUtil=labelsUtil,exports.lcs=lcs,exports.lookAt=lookAt,exports.map=map,exports.multiply=multiply,exports.ou=ortho,exports.parseLngLatData=parseLngLatData,exports.perspective=perspective,exports.rbush=_rbush_2_0_2_rbush,exports.scale=scale$1,exports.set=set$1,exports.Pl=set,exports.some=some,exports.XY=tileInnerCoord2LngLat,exports.Gu=transformMat4,exports.vector=vector,exports.zoomRange=zoomRange}),define(["./shared"],function(polyfill){var _aesJs_3_1_2_aesJs=polyfill.M8t(function(i,t){function e(i){return parseInt(i)===i}function o(i){if(e(i.length)){for(var t=0;t<i.length;t++)if(!e(i[t])||i[t]<0||255<i[t])return;return 1}}function r(i,t){if(i.buffer&&"Uint8Array"===i.name)return t?i.slice?i.slice():Array.prototype.slice.call(i):i;if(Array.isArray(i)){if(o(i))return new Uint8Array(i);throw new Error("Array contains invalid value: "+i)}if(e(i.length)&&o(i))return new Uint8Array(i);throw new Error("unsupported array-like object")}function a(i){return new Uint8Array(i)}function n(i,t,e,o,h){null==o&&null==h||(i=i.slice?i.slice(o,h):Array.prototype.slice.call(i,o,h)),t.set(i,e)}var h,l={AAA:function(i){var t=[],e=0;for(i=encodeURI(i);e<i.length;){var o=i.charCodeAt(e++);37===o?(t.push(parseInt(i.substr(e,2),16)),e+=2):t.push(o)}return r(t)},iAA:function(i){for(var t=[],e=0;e<i.length;){var o=i[e];o<128?(t.push(String.fromCharCode(o)),e++):191<o&&o<224?(t.push(String.fromCharCode((31&o)<<6|63&i[e+1])),e+=2):(t.push(String.fromCharCode((15&o)<<12|(63&i[e+1])<<6|63&i[e+2])),e+=3)}return t.join("")}},s=(h="0123456789abcdef",{AAA:function(i){for(var t=[],e=0;e<i.length;e+=2)t.push(parseInt(i.substr(e,2),16));return t},iAA:function(i){for(var t=[],e=0;e<i.length;e++){var o=i[e];t.push(h[(240&o)>>4]+h[15&o])}return t.join("")}}),u={16:10,24:12,32:14},p=[1,2,4,8,16,32,64,128,27,54,108,216,171,77,154,47,94,188,99,198,151,53,106,212,179,125,250,239,197,145],d=[99,124,119,123,242,107,111,197,48,1,103,43,254,215,171,118,202,130,201,125,250,89,71,240,173,212,162,175,156,164,114,192,183,253,147,38,54,63,247,204,52,165,229,241,113,216,49,21,4,199,35,195,24,150,5,154,7,18,128,226,235,39,178,117,9,131,44,26,27,110,90,160,82,59,214,179,41,227,47,132,83,209,0,237,32,252,177,91,106,203,190,57,74,76,88,207,208,239,170,251,67,77,51,133,69,249,2,127,80,60,159,168,81,163,64,143,146,157,56,245,188,182,218,33,16,255,243,210,205,12,19,236,95,151,68,23,196,167,126,61,100,93,25,115,96,129,79,220,34,42,144,136,70,238,184,20,222,94,11,219,224,50,58,10,73,6,36,92,194,211,172,98,145,149,228,121,231,200,55,109,141,213,78,169,108,86,244,234,101,122,174,8,186,120,37,46,28,166,180,198,232,221,116,31,75,189,139,138,112,62,181,102,72,3,246,14,97,53,87,185,134,193,29,158,225,248,152,17,105,217,142,148,155,30,135,233,206,85,40,223,140,161,137,13,191,230,66,104,65,153,45,15,176,84,187,22],f=[82,9,106,213,48,54,165,56,191,64,163,158,129,243,215,251,124,227,57,130,155,47,255,135,52,142,67,68,196,222,233,203,84,123,148,50,166,194,35,61,238,76,149,11,66,250,195,78,8,46,161,102,40,217,36,178,118,91,162,73,109,139,209,37,114,248,246,100,134,104,152,22,212,164,92,204,93,101,182,146,108,112,72,80,253,237,185,218,94,21,70,87,167,141,157,132,144,216,171,0,140,188,211,10,247,228,88,5,184,179,69,6,208,44,30,143,202,63,15,2,193,175,189,3,1,19,138,107,58,145,17,65,79,103,220,234,151,242,207,206,240,180,230,115,150,172,116,34,231,173,53,133,226,249,55,232,28,117,223,110,71,241,26,113,29,41,197,137,111,183,98,14,170,24,190,27,252,86,62,75,198,210,121,32,154,219,192,254,120,205,90,244,31,221,168,51,136,7,199,49,177,18,16,89,39,128,236,95,96,81,127,169,25,181,74,13,45,229,122,159,147,201,156,239,160,224,59,77,174,42,245,176,200,235,187,60,131,83,153,97,23,43,4,126,186,119,214,38,225,105,20,99,85,33,12,125],x=[3328402341,4168907908,4000806809,4135287693,4294111757,3597364157,3731845041,2445657428,1613770832,33620227,3462883241,1445669757,3892248089,3050821474,1303096294,3967186586,2412431941,528646813,2311702848,4202528135,4026202645,2992200171,2387036105,4226871307,1101901292,3017069671,1604494077,1169141738,597466303,1403299063,3832705686,2613100635,1974974402,3791519004,1033081774,1277568618,1815492186,2118074177,4126668546,2211236943,1748251740,1369810420,3521504564,4193382664,3799085459,2883115123,1647391059,706024767,134480908,2512897874,1176707941,2646852446,806885416,932615841,168101135,798661301,235341577,605164086,461406363,3756188221,3454790438,1311188841,2142417613,3933566367,302582043,495158174,1479289972,874125870,907746093,3698224818,3025820398,1537253627,2756858614,1983593293,3084310113,2108928974,1378429307,3722699582,1580150641,327451799,2790478837,3117535592,0,3253595436,1075847264,3825007647,2041688520,3059440621,3563743934,2378943302,1740553945,1916352843,2487896798,2555137236,2958579944,2244988746,3151024235,3320835882,1336584933,3992714006,2252555205,2588757463,1714631509,293963156,2319795663,3925473552,67240454,4269768577,2689618160,2017213508,631218106,1269344483,2723238387,1571005438,2151694528,93294474,1066570413,563977660,1882732616,4059428100,1673313503,2008463041,2950355573,1109467491,537923632,3858759450,4260623118,3218264685,2177748300,403442708,638784309,3287084079,3193921505,899127202,2286175436,773265209,2479146071,1437050866,4236148354,2050833735,3362022572,3126681063,840505643,3866325909,3227541664,427917720,2655997905,2749160575,1143087718,1412049534,999329963,193497219,2353415882,3354324521,1807268051,672404540,2816401017,3160301282,369822493,2916866934,3688947771,1681011286,1949973070,336202270,2454276571,201721354,1210328172,3093060836,2680341085,3184776046,1135389935,3294782118,965841320,831886756,3554993207,4068047243,3588745010,2345191491,1849112409,3664604599,26054028,2983581028,2622377682,1235855840,3630984372,2891339514,4092916743,3488279077,3395642799,4101667470,1202630377,268961816,1874508501,4034427016,1243948399,1546530418,941366308,1470539505,1941222599,2546386513,3421038627,2715671932,3899946140,1042226977,2521517021,1639824860,227249030,260737669,3765465232,2084453954,1907733956,3429263018,2420656344,100860677,4160157185,470683154,3261161891,1781871967,2924959737,1773779408,394692241,2579611992,974986535,664706745,3655459128,3958962195,731420851,571543859,3530123707,2849626480,126783113,865375399,765172662,1008606754,361203602,3387549984,2278477385,2857719295,1344809080,2782912378,59542671,1503764984,160008576,437062935,1707065306,3622233649,2218934982,3496503480,2185314755,697932208,1512910199,504303377,2075177163,2824099068,1841019862,739644986],y=[2781242211,2230877308,2582542199,2381740923,234877682,3184946027,2984144751,1418839493,1348481072,50462977,2848876391,2102799147,434634494,1656084439,3863849899,2599188086,1167051466,2636087938,1082771913,2281340285,368048890,3954334041,3381544775,201060592,3963727277,1739838676,4250903202,3930435503,3206782108,4149453988,2531553906,1536934080,3262494647,484572669,2923271059,1783375398,1517041206,1098792767,49674231,1334037708,1550332980,4098991525,886171109,150598129,2481090929,1940642008,1398944049,1059722517,201851908,1385547719,1699095331,1587397571,674240536,2704774806,252314885,3039795866,151914247,908333586,2602270848,1038082786,651029483,1766729511,3447698098,2682942837,454166793,2652734339,1951935532,775166490,758520603,3000790638,4004797018,4217086112,4137964114,1299594043,1639438038,3464344499,2068982057,1054729187,1901997871,2534638724,4121318227,1757008337,0,750906861,1614815264,535035132,3363418545,3988151131,3201591914,1183697867,3647454910,1265776953,3734260298,3566750796,3903871064,1250283471,1807470800,717615087,3847203498,384695291,3313910595,3617213773,1432761139,2484176261,3481945413,283769337,100925954,2180939647,4037038160,1148730428,3123027871,3813386408,4087501137,4267549603,3229630528,2315620239,2906624658,3156319645,1215313976,82966005,3747855548,3245848246,1974459098,1665278241,807407632,451280895,251524083,1841287890,1283575245,337120268,891687699,801369324,3787349855,2721421207,3431482436,959321879,1469301956,4065699751,2197585534,1199193405,2898814052,3887750493,724703513,2514908019,2696962144,2551808385,3516813135,2141445340,1715741218,2119445034,2872807568,2198571144,3398190662,700968686,3547052216,1009259540,2041044702,3803995742,487983883,1991105499,1004265696,1449407026,1316239930,504629770,3683797321,168560134,1816667172,3837287516,1570751170,1857934291,4014189740,2797888098,2822345105,2754712981,936633572,2347923833,852879335,1133234376,1500395319,3084545389,2348912013,1689376213,3533459022,3762923945,3034082412,4205598294,133428468,634383082,2949277029,2398386810,3913789102,403703816,3580869306,2297460856,1867130149,1918643758,607656988,4049053350,3346248884,1368901318,600565992,2090982877,2632479860,557719327,3717614411,3697393085,2249034635,2232388234,2430627952,1115438654,3295786421,2865522278,3633334344,84280067,33027830,303828494,2747425121,1600795957,4188952407,3496589753,2434238086,1486471617,658119965,3106381470,953803233,334231800,3005978776,857870609,3151128937,1890179545,2298973838,2805175444,3056442267,574365214,2450884487,550103529,1233637070,4289353045,2018519080,2057691103,2399374476,4166623649,2148108681,387583245,3664101311,836232934,3330556482,3100665960,3280093505,2955516313,2002398509,287182607,3413881008,4238890068,3597515707,975967766],c=[1671808611,2089089148,2006576759,2072901243,4061003762,1807603307,1873927791,3310653893,810573872,16974337,1739181671,729634347,4263110654,3613570519,2883997099,1989864566,3393556426,2191335298,3376449993,2106063485,4195741690,1508618841,1204391495,4027317232,2917941677,3563566036,2734514082,2951366063,2629772188,2767672228,1922491506,3227229120,3082974647,4246528509,2477669779,644500518,911895606,1061256767,4144166391,3427763148,878471220,2784252325,3845444069,4043897329,1905517169,3631459288,827548209,356461077,67897348,3344078279,593839651,3277757891,405286936,2527147926,84871685,2595565466,118033927,305538066,2157648768,3795705826,3945188843,661212711,2999812018,1973414517,152769033,2208177539,745822252,439235610,455947803,1857215598,1525593178,2700827552,1391895634,994932283,3596728278,3016654259,695947817,3812548067,795958831,2224493444,1408607827,3513301457,0,3979133421,543178784,4229948412,2982705585,1542305371,1790891114,3410398667,3201918910,961245753,1256100938,1289001036,1491644504,3477767631,3496721360,4012557807,2867154858,4212583931,1137018435,1305975373,861234739,2241073541,1171229253,4178635257,33948674,2139225727,1357946960,1011120188,2679776671,2833468328,1374921297,2751356323,1086357568,2408187279,2460827538,2646352285,944271416,4110742005,3168756668,3066132406,3665145818,560153121,271589392,4279952895,4077846003,3530407890,3444343245,202643468,322250259,3962553324,1608629855,2543990167,1154254916,389623319,3294073796,2817676711,2122513534,1028094525,1689045092,1575467613,422261273,1939203699,1621147744,2174228865,1339137615,3699352540,577127458,712922154,2427141008,2290289544,1187679302,3995715566,3100863416,339486740,3732514782,1591917662,186455563,3681988059,3762019296,844522546,978220090,169743370,1239126601,101321734,611076132,1558493276,3260915650,3547250131,2901361580,1655096418,2443721105,2510565781,3828863972,2039214713,3878868455,3359869896,928607799,1840765549,2374762893,3580146133,1322425422,2850048425,1823791212,1459268694,4094161908,3928346602,1706019429,2056189050,2934523822,135794696,3134549946,2022240376,628050469,779246638,472135708,2800834470,3032970164,3327236038,3894660072,3715932637,1956440180,522272287,1272813131,3185336765,2340818315,2323976074,1888542832,1044544574,3049550261,1722469478,1222152264,50660867,4127324150,236067854,1638122081,895445557,1475980887,3117443513,2257655686,3243809217,489110045,2662934430,3778599393,4162055160,2561878936,288563729,1773916777,3648039385,2391345038,2493985684,2612407707,505560094,2274497927,3911240169,3460925390,1442818645,678973480,3749357023,2358182796,2717407649,2306869641,219617805,3218761151,3862026214,1120306242,1756942440,1103331905,2578459033,762796589,252780047,2966125488,1425844308,3151392187,372911126],v=[1667474886,2088535288,2004326894,2071694838,4075949567,1802223062,1869591006,3318043793,808472672,16843522,1734846926,724270422,4278065639,3621216949,2880169549,1987484396,3402253711,2189597983,3385409673,2105378810,4210693615,1499065266,1195886990,4042263547,2913856577,3570689971,2728590687,2947541573,2627518243,2762274643,1920112356,3233831835,3082273397,4261223649,2475929149,640051788,909531756,1061110142,4160160501,3435941763,875846760,2779116625,3857003729,4059105529,1903268834,3638064043,825316194,353713962,67374088,3351728789,589522246,3284360861,404236336,2526454071,84217610,2593830191,117901582,303183396,2155911963,3806477791,3958056653,656894286,2998062463,1970642922,151591698,2206440989,741110872,437923380,454765878,1852748508,1515908788,2694904667,1381168804,993742198,3604373943,3014905469,690584402,3823320797,791638366,2223281939,1398011302,3520161977,0,3991743681,538992704,4244381667,2981218425,1532751286,1785380564,3419096717,3200178535,960056178,1246420628,1280103576,1482221744,3486468741,3503319995,4025428677,2863326543,4227536621,1128514950,1296947098,859002214,2240123921,1162203018,4193849577,33687044,2139062782,1347481760,1010582648,2678045221,2829640523,1364325282,2745433693,1077985408,2408548869,2459086143,2644360225,943212656,4126475505,3166494563,3065430391,3671750063,555836226,269496352,4294908645,4092792573,3537006015,3452783745,202118168,320025894,3974901699,1600119230,2543297077,1145359496,387397934,3301201811,2812801621,2122220284,1027426170,1684319432,1566435258,421079858,1936954854,1616945344,2172753945,1330631070,3705438115,572679748,707427924,2425400123,2290647819,1179044492,4008585671,3099120491,336870440,3739122087,1583276732,185277718,3688593069,3772791771,842159716,976899700,168435220,1229577106,101059084,606366792,1549591736,3267517855,3553849021,2897014595,1650632388,2442242105,2509612081,3840161747,2038008818,3890688725,3368567691,926374254,1835907034,2374863873,3587531953,1313788572,2846482505,1819063512,1448540844,4109633523,3941213647,1701162954,2054852340,2930698567,134748176,3132806511,2021165296,623210314,774795868,471606328,2795958615,3031746419,3334885783,3907527627,3722280097,1953799400,522133822,1263263126,3183336545,2341176845,2324333839,1886425312,1044267644,3048588401,1718004428,1212733584,50529542,4143317495,235803164,1633788866,892690282,1465383342,3115962473,2256965911,3250673817,488449850,2661202215,3789633753,4177007595,2560144171,286339874,1768537042,3654906025,2391705863,2492770099,2610673197,505291324,2273808917,3924369609,3469625735,1431699370,673740880,3755965093,2358021891,2711746649,2307489801,218961690,3217021541,3873845719,1111672452,1751693520,1094828930,2576986153,757954394,252645662,2964376443,1414855848,3149649517,370555436],g=[1374988112,2118214995,437757123,975658646,1001089995,530400753,2902087851,1273168787,540080725,2910219766,2295101073,4110568485,1340463100,3307916247,641025152,3043140495,3736164937,632953703,1172967064,1576976609,3274667266,2169303058,2370213795,1809054150,59727847,361929877,3211623147,2505202138,3569255213,1484005843,1239443753,2395588676,1975683434,4102977912,2572697195,666464733,3202437046,4035489047,3374361702,2110667444,1675577880,3843699074,2538681184,1649639237,2976151520,3144396420,4269907996,4178062228,1883793496,2403728665,2497604743,1383856311,2876494627,1917518562,3810496343,1716890410,3001755655,800440835,2261089178,3543599269,807962610,599762354,33778362,3977675356,2328828971,2809771154,4077384432,1315562145,1708848333,101039829,3509871135,3299278474,875451293,2733856160,92987698,2767645557,193195065,1080094634,1584504582,3178106961,1042385657,2531067453,3711829422,1306967366,2438237621,1908694277,67556463,1615861247,429456164,3602770327,2302690252,1742315127,2968011453,126454664,3877198648,2043211483,2709260871,2084704233,4169408201,0,159417987,841739592,504459436,1817866830,4245618683,260388950,1034867998,908933415,168810852,1750902305,2606453969,607530554,202008497,2472011535,3035535058,463180190,2160117071,1641816226,1517767529,470948374,3801332234,3231722213,1008918595,303765277,235474187,4069246893,766945465,337553864,1475418501,2943682380,4003061179,2743034109,4144047775,1551037884,1147550661,1543208500,2336434550,3408119516,3069049960,3102011747,3610369226,1113818384,328671808,2227573024,2236228733,3535486456,2935566865,3341394285,496906059,3702665459,226906860,2009195472,733156972,2842737049,294930682,1206477858,2835123396,2700099354,1451044056,573804783,2269728455,3644379585,2362090238,2564033334,2801107407,2776292904,3669462566,1068351396,742039012,1350078989,1784663195,1417561698,4136440770,2430122216,775550814,2193862645,2673705150,1775276924,1876241833,3475313331,3366754619,270040487,3902563182,3678124923,3441850377,1851332852,3969562369,2203032232,3868552805,2868897406,566021896,4011190502,3135740889,1248802510,3936291284,699432150,832877231,708780849,3332740144,899835584,1951317047,4236429990,3767586992,866637845,4043610186,1106041591,2144161806,395441711,1984812685,1139781709,3433712980,3835036895,2664543715,1282050075,3240894392,1181045119,2640243204,25965917,4203181171,4211818798,3009879386,2463879762,3910161971,1842759443,2597806476,933301370,1509430414,3943906441,3467192302,3076639029,3776767469,2051518780,2631065433,1441952575,404016761,1942435775,1408749034,1610459739,3745345300,2017778566,3400528769,3110650942,941896748,3265478751,371049330,3168937228,675039627,4279080257,967311729,135050206,3635733660,1683407248,2076935265,3576870512,1215061108,3501741890],w=[1347548327,1400783205,3273267108,2520393566,3409685355,4045380933,2880240216,2471224067,1428173050,4138563181,2441661558,636813900,4233094615,3620022987,2149987652,2411029155,1239331162,1730525723,2554718734,3781033664,46346101,310463728,2743944855,3328955385,3875770207,2501218972,3955191162,3667219033,768917123,3545789473,692707433,1150208456,1786102409,2029293177,1805211710,3710368113,3065962831,401639597,1724457132,3028143674,409198410,2196052529,1620529459,1164071807,3769721975,2226875310,486441376,2499348523,1483753576,428819965,2274680428,3075636216,598438867,3799141122,1474502543,711349675,129166120,53458370,2592523643,2782082824,4063242375,2988687269,3120694122,1559041666,730517276,2460449204,4042459122,2706270690,3446004468,3573941694,533804130,2328143614,2637442643,2695033685,839224033,1973745387,957055980,2856345839,106852767,1371368976,4181598602,1033297158,2933734917,1179510461,3046200461,91341917,1862534868,4284502037,605657339,2547432937,3431546947,2003294622,3182487618,2282195339,954669403,3682191598,1201765386,3917234703,3388507166,0,2198438022,1211247597,2887651696,1315723890,4227665663,1443857720,507358933,657861945,1678381017,560487590,3516619604,975451694,2970356327,261314535,3535072918,2652609425,1333838021,2724322336,1767536459,370938394,182621114,3854606378,1128014560,487725847,185469197,2918353863,3106780840,3356761769,2237133081,1286567175,3152976349,4255350624,2683765030,3160175349,3309594171,878443390,1988838185,3704300486,1756818940,1673061617,3403100636,272786309,1075025698,545572369,2105887268,4174560061,296679730,1841768865,1260232239,4091327024,3960309330,3497509347,1814803222,2578018489,4195456072,575138148,3299409036,446754879,3629546796,4011996048,3347532110,3252238545,4270639778,915985419,3483825537,681933534,651868046,2755636671,3828103837,223377554,2607439820,1649704518,3270937875,3901806776,1580087799,4118987695,3198115200,2087309459,2842678573,3016697106,1003007129,2802849917,1860738147,2077965243,164439672,4100872472,32283319,2827177882,1709610350,2125135846,136428751,3874428392,3652904859,3460984630,3572145929,3593056380,2939266226,824852259,818324884,3224740454,930369212,2801566410,2967507152,355706840,1257309336,4148292826,243256656,790073846,2373340630,1296297904,1422699085,3756299780,3818836405,457992840,3099667487,2135319889,77422314,1560382517,1945798516,788204353,1521706781,1385356242,870912086,325965383,2358957921,2050466060,2388260884,2313884476,4006521127,901210569,3990953189,1014646705,1503449823,1062597235,2031621326,3212035895,3931371469,1533017514,350174575,2256028891,2177544179,1052338372,741876788,1606591296,1914052035,213705253,2334669897,1107234197,1899603969,3725069491,2631447780,2422494913,1635502980,1893020342,1950903388,1120974935],b=[2807058932,1699970625,2764249623,1586903591,1808481195,1173430173,1487645946,59984867,4199882800,1844882806,1989249228,1277555970,3623636965,3419915562,1149249077,2744104290,1514790577,459744698,244860394,3235995134,1963115311,4027744588,2544078150,4190530515,1608975247,2627016082,2062270317,1507497298,2200818878,567498868,1764313568,3359936201,2305455554,2037970062,1047239e3,1910319033,1337376481,2904027272,2892417312,984907214,1243112415,830661914,861968209,2135253587,2011214180,2927934315,2686254721,731183368,1750626376,4246310725,1820824798,4172763771,3542330227,48394827,2404901663,2871682645,671593195,3254988725,2073724613,145085239,2280796200,2779915199,1790575107,2187128086,472615631,3029510009,4075877127,3802222185,4107101658,3201631749,1646252340,4270507174,1402811438,1436590835,3778151818,3950355702,3963161475,4020912224,2667994737,273792366,2331590177,104699613,95345982,3175501286,2377486676,1560637892,3564045318,369057872,4213447064,3919042237,1137477952,2658625497,1119727848,2340947849,1530455833,4007360968,172466556,266959938,516552836,0,2256734592,3980931627,1890328081,1917742170,4294704398,945164165,3575528878,958871085,3647212047,2787207260,1423022939,775562294,1739656202,3876557655,2530391278,2443058075,3310321856,547512796,1265195639,437656594,3121275539,719700128,3762502690,387781147,218828297,3350065803,2830708150,2848461854,428169201,122466165,3720081049,1627235199,648017665,4122762354,1002783846,2117360635,695634755,3336358691,4234721005,4049844452,3704280881,2232435299,574624663,287343814,612205898,1039717051,840019705,2708326185,793451934,821288114,1391201670,3822090177,376187827,3113855344,1224348052,1679968233,2361698556,1058709744,752375421,2431590963,1321699145,3519142200,2734591178,188127444,2177869557,3727205754,2384911031,3215212461,2648976442,2450346104,3432737375,1180849278,331544205,3102249176,4150144569,2952102595,2159976285,2474404304,766078933,313773861,2570832044,2108100632,1668212892,3145456443,2013908262,418672217,3070356634,2594734927,1852171925,3867060991,3473416636,3907448597,2614737639,919489135,164948639,2094410160,2997825956,590424639,2486224549,1723872674,3157750862,3399941250,3501252752,3625268135,2555048196,3673637356,1343127501,4130281361,3599595085,2957853679,1297403050,81781910,3051593425,2283490410,532201772,1367295589,3926170974,895287692,1953757831,1093597963,492483431,3528626907,1446242576,1192455638,1636604631,209336225,344873464,1015671571,669961897,3375740769,3857572124,2973530695,3747192018,1933530610,3464042516,935293895,3454686199,2858115069,1863638845,3683022916,4085369519,3292445032,875313188,1080017571,3279033885,621591778,1233856572,2504130317,24197544,3017672716,3835484340,3247465558,2220981195,3060847922,1551124588,1463996600],R=[4104605777,1097159550,396673818,660510266,2875968315,2638606623,4200115116,3808662347,821712160,1986918061,3430322568,38544885,3856137295,718002117,893681702,1654886325,2975484382,3122358053,3926825029,4274053469,796197571,1290801793,1184342925,3556361835,2405426947,2459735317,1836772287,1381620373,3196267988,1948373848,3764988233,3385345166,3263785589,2390325492,1480485785,3111247143,3780097726,2293045232,548169417,3459953789,3746175075,439452389,1362321559,1400849762,1685577905,1806599355,2174754046,137073913,1214797936,1174215055,3731654548,2079897426,1943217067,1258480242,529487843,1437280870,3945269170,3049390895,3313212038,923313619,679998e3,3215307299,57326082,377642221,3474729866,2041877159,133361907,1776460110,3673476453,96392454,878845905,2801699524,777231668,4082475170,2330014213,4142626212,2213296395,1626319424,1906247262,1846563261,562755902,3708173718,1040559837,3871163981,1418573201,3294430577,114585348,1343618912,2566595609,3186202582,1078185097,3651041127,3896688048,2307622919,425408743,3371096953,2081048481,1108339068,2216610296,0,2156299017,736970802,292596766,1517440620,251657213,2235061775,2933202493,758720310,265905162,1554391400,1532285339,908999204,174567692,1474760595,4002861748,2610011675,3234156416,3693126241,2001430874,303699484,2478443234,2687165888,585122620,454499602,151849742,2345119218,3064510765,514443284,4044981591,1963412655,2581445614,2137062819,19308535,1928707164,1715193156,4219352155,1126790795,600235211,3992742070,3841024952,836553431,1669664834,2535604243,3323011204,1243905413,3141400786,4180808110,698445255,2653899549,2989552604,2253581325,3252932727,3004591147,1891211689,2487810577,3915653703,4237083816,4030667424,2100090966,865136418,1229899655,953270745,3399679628,3557504664,4118925222,2061379749,3079546586,2915017791,983426092,2022837584,1607244650,2118541908,2366882550,3635996816,972512814,3283088770,1568718495,3499326569,3576539503,621982671,2895723464,410887952,2623762152,1002142683,645401037,1494807662,2595684844,1335535747,2507040230,4293295786,3167684641,367585007,3885750714,1865862730,2668221674,2960971305,2763173681,1059270954,2777952454,2724642869,1320957812,2194319100,2429595872,2815956275,77089521,3973773121,3444575871,2448830231,1305906550,4021308739,2857194700,2516901860,3518358430,1787304780,740276417,1699839814,1592394909,2352307457,2272556026,188821243,1729977011,3687994002,274084841,3594982253,3613494426,2701949495,4162096729,322734571,2837966542,1640576439,484830689,1202797690,3537852828,4067639125,349075736,3342319475,4157467219,4255800159,1030690015,1155237496,2951971274,1757691577,607398968,2738905026,499347990,3794078908,1011452712,227885567,2818666809,213114376,3034881240,1455525988,3414450555,850817237,1817998408,3092726480],m=[0,235474187,470948374,303765277,941896748,908933415,607530554,708780849,1883793496,2118214995,1817866830,1649639237,1215061108,1181045119,1417561698,1517767529,3767586992,4003061179,4236429990,4069246893,3635733660,3602770327,3299278474,3400528769,2430122216,2664543715,2362090238,2193862645,2835123396,2801107407,3035535058,3135740889,3678124923,3576870512,3341394285,3374361702,3810496343,3977675356,4279080257,4043610186,2876494627,2776292904,3076639029,3110650942,2472011535,2640243204,2403728665,2169303058,1001089995,899835584,666464733,699432150,59727847,226906860,530400753,294930682,1273168787,1172967064,1475418501,1509430414,1942435775,2110667444,1876241833,1641816226,2910219766,2743034109,2976151520,3211623147,2505202138,2606453969,2302690252,2269728455,3711829422,3543599269,3240894392,3475313331,3843699074,3943906441,4178062228,4144047775,1306967366,1139781709,1374988112,1610459739,1975683434,2076935265,1775276924,1742315127,1034867998,866637845,566021896,800440835,92987698,193195065,429456164,395441711,1984812685,2017778566,1784663195,1683407248,1315562145,1080094634,1383856311,1551037884,101039829,135050206,437757123,337553864,1042385657,807962610,573804783,742039012,2531067453,2564033334,2328828971,2227573024,2935566865,2700099354,3001755655,3168937228,3868552805,3902563182,4203181171,4102977912,3736164937,3501741890,3265478751,3433712980,1106041591,1340463100,1576976609,1408749034,2043211483,2009195472,1708848333,1809054150,832877231,1068351396,766945465,599762354,159417987,126454664,361929877,463180190,2709260871,2943682380,3178106961,3009879386,2572697195,2538681184,2236228733,2336434550,3509871135,3745345300,3441850377,3274667266,3910161971,3877198648,4110568485,4211818798,2597806476,2497604743,2261089178,2295101073,2733856160,2902087851,3202437046,2968011453,3936291284,3835036895,4136440770,4169408201,3535486456,3702665459,3467192302,3231722213,2051518780,1951317047,1716890410,1750902305,1113818384,1282050075,1584504582,1350078989,168810852,67556463,371049330,404016761,841739592,1008918595,775550814,540080725,3969562369,3801332234,4035489047,4269907996,3569255213,3669462566,3366754619,3332740144,2631065433,2463879762,2160117071,2395588676,2767645557,2868897406,3102011747,3069049960,202008497,33778362,270040487,504459436,875451293,975658646,675039627,641025152,2084704233,1917518562,1615861247,1851332852,1147550661,1248802510,1484005843,1451044056,933301370,967311729,733156972,632953703,260388950,25965917,328671808,496906059,1206477858,1239443753,1543208500,1441952575,2144161806,1908694277,1675577880,1842759443,3610369226,3644379585,3408119516,3307916247,4011190502,3776767469,4077384432,4245618683,2809771154,2842737049,3144396420,3043140495,2673705150,2438237621,2203032232,2370213795],k=[0,185469197,370938394,487725847,741876788,657861945,975451694,824852259,1483753576,1400783205,1315723890,1164071807,1950903388,2135319889,1649704518,1767536459,2967507152,3152976349,2801566410,2918353863,2631447780,2547432937,2328143614,2177544179,3901806776,3818836405,4270639778,4118987695,3299409036,3483825537,3535072918,3652904859,2077965243,1893020342,1841768865,1724457132,1474502543,1559041666,1107234197,1257309336,598438867,681933534,901210569,1052338372,261314535,77422314,428819965,310463728,3409685355,3224740454,3710368113,3593056380,3875770207,3960309330,4045380933,4195456072,2471224067,2554718734,2237133081,2388260884,3212035895,3028143674,2842678573,2724322336,4138563181,4255350624,3769721975,3955191162,3667219033,3516619604,3431546947,3347532110,2933734917,2782082824,3099667487,3016697106,2196052529,2313884476,2499348523,2683765030,1179510461,1296297904,1347548327,1533017514,1786102409,1635502980,2087309459,2003294622,507358933,355706840,136428751,53458370,839224033,957055980,605657339,790073846,2373340630,2256028891,2607439820,2422494913,2706270690,2856345839,3075636216,3160175349,3573941694,3725069491,3273267108,3356761769,4181598602,4063242375,4011996048,3828103837,1033297158,915985419,730517276,545572369,296679730,446754879,129166120,213705253,1709610350,1860738147,1945798516,2029293177,1239331162,1120974935,1606591296,1422699085,4148292826,4233094615,3781033664,3931371469,3682191598,3497509347,3446004468,3328955385,2939266226,2755636671,3106780840,2988687269,2198438022,2282195339,2501218972,2652609425,1201765386,1286567175,1371368976,1521706781,1805211710,1620529459,2105887268,1988838185,533804130,350174575,164439672,46346101,870912086,954669403,636813900,788204353,2358957921,2274680428,2592523643,2441661558,2695033685,2880240216,3065962831,3182487618,3572145929,3756299780,3270937875,3388507166,4174560061,4091327024,4006521127,3854606378,1014646705,930369212,711349675,560487590,272786309,457992840,106852767,223377554,1678381017,1862534868,1914052035,2031621326,1211247597,1128014560,1580087799,1428173050,32283319,182621114,401639597,486441376,768917123,651868046,1003007129,818324884,1503449823,1385356242,1333838021,1150208456,1973745387,2125135846,1673061617,1756818940,2970356327,3120694122,2802849917,2887651696,2637442643,2520393566,2334669897,2149987652,3917234703,3799141122,4284502037,4100872472,3309594171,3460984630,3545789473,3629546796,2050466060,1899603969,1814803222,1730525723,1443857720,1560382517,1075025698,1260232239,575138148,692707433,878443390,1062597235,243256656,91341917,409198410,325965383,3403100636,3252238545,3704300486,3620022987,3874428392,3990953189,4042459122,4227665663,2460449204,2578018489,2226875310,2411029155,3198115200,3046200461,2827177882,2743944855],_=[0,218828297,437656594,387781147,875313188,958871085,775562294,590424639,1750626376,1699970625,1917742170,2135253587,1551124588,1367295589,1180849278,1265195639,3501252752,3720081049,3399941250,3350065803,3835484340,3919042237,4270507174,4085369519,3102249176,3051593425,2734591178,2952102595,2361698556,2177869557,2530391278,2614737639,3145456443,3060847922,2708326185,2892417312,2404901663,2187128086,2504130317,2555048196,3542330227,3727205754,3375740769,3292445032,3876557655,3926170974,4246310725,4027744588,1808481195,1723872674,1910319033,2094410160,1608975247,1391201670,1173430173,1224348052,59984867,244860394,428169201,344873464,935293895,984907214,766078933,547512796,1844882806,1627235199,2011214180,2062270317,1507497298,1423022939,1137477952,1321699145,95345982,145085239,532201772,313773861,830661914,1015671571,731183368,648017665,3175501286,2957853679,2807058932,2858115069,2305455554,2220981195,2474404304,2658625497,3575528878,3625268135,3473416636,3254988725,3778151818,3963161475,4213447064,4130281361,3599595085,3683022916,3432737375,3247465558,3802222185,4020912224,4172763771,4122762354,3201631749,3017672716,2764249623,2848461854,2331590177,2280796200,2431590963,2648976442,104699613,188127444,472615631,287343814,840019705,1058709744,671593195,621591778,1852171925,1668212892,1953757831,2037970062,1514790577,1463996600,1080017571,1297403050,3673637356,3623636965,3235995134,3454686199,4007360968,3822090177,4107101658,4190530515,2997825956,3215212461,2830708150,2779915199,2256734592,2340947849,2627016082,2443058075,172466556,122466165,273792366,492483431,1047239e3,861968209,612205898,695634755,1646252340,1863638845,2013908262,1963115311,1446242576,1530455833,1277555970,1093597963,1636604631,1820824798,2073724613,1989249228,1436590835,1487645946,1337376481,1119727848,164948639,81781910,331544205,516552836,1039717051,821288114,669961897,719700128,2973530695,3157750862,2871682645,2787207260,2232435299,2283490410,2667994737,2450346104,3647212047,3564045318,3279033885,3464042516,3980931627,3762502690,4150144569,4199882800,3070356634,3121275539,2904027272,2686254721,2200818878,2384911031,2570832044,2486224549,3747192018,3528626907,3310321856,3359936201,3950355702,3867060991,4049844452,4234721005,1739656202,1790575107,2108100632,1890328081,1402811438,1586903591,1233856572,1149249077,266959938,48394827,369057872,418672217,1002783846,919489135,567498868,752375421,209336225,24197544,376187827,459744698,945164165,895287692,574624663,793451934,1679968233,1764313568,2117360635,1933530610,1343127501,1560637892,1243112415,1192455638,3704280881,3519142200,3336358691,3419915562,3907448597,3857572124,4075877127,4294704398,3029510009,3113855344,2927934315,2744104290,2159976285,2377486676,2594734927,2544078150],S=[0,151849742,303699484,454499602,607398968,758720310,908999204,1059270954,1214797936,1097159550,1517440620,1400849762,1817998408,1699839814,2118541908,2001430874,2429595872,2581445614,2194319100,2345119218,3034881240,3186202582,2801699524,2951971274,3635996816,3518358430,3399679628,3283088770,4237083816,4118925222,4002861748,3885750714,1002142683,850817237,698445255,548169417,529487843,377642221,227885567,77089521,1943217067,2061379749,1640576439,1757691577,1474760595,1592394909,1174215055,1290801793,2875968315,2724642869,3111247143,2960971305,2405426947,2253581325,2638606623,2487810577,3808662347,3926825029,4044981591,4162096729,3342319475,3459953789,3576539503,3693126241,1986918061,2137062819,1685577905,1836772287,1381620373,1532285339,1078185097,1229899655,1040559837,923313619,740276417,621982671,439452389,322734571,137073913,19308535,3871163981,4021308739,4104605777,4255800159,3263785589,3414450555,3499326569,3651041127,2933202493,2815956275,3167684641,3049390895,2330014213,2213296395,2566595609,2448830231,1305906550,1155237496,1607244650,1455525988,1776460110,1626319424,2079897426,1928707164,96392454,213114376,396673818,514443284,562755902,679998e3,865136418,983426092,3708173718,3557504664,3474729866,3323011204,4180808110,4030667424,3945269170,3794078908,2507040230,2623762152,2272556026,2390325492,2975484382,3092726480,2738905026,2857194700,3973773121,3856137295,4274053469,4157467219,3371096953,3252932727,3673476453,3556361835,2763173681,2915017791,3064510765,3215307299,2156299017,2307622919,2459735317,2610011675,2081048481,1963412655,1846563261,1729977011,1480485785,1362321559,1243905413,1126790795,878845905,1030690015,645401037,796197571,274084841,425408743,38544885,188821243,3613494426,3731654548,3313212038,3430322568,4082475170,4200115116,3780097726,3896688048,2668221674,2516901860,2366882550,2216610296,3141400786,2989552604,2837966542,2687165888,1202797690,1320957812,1437280870,1554391400,1669664834,1787304780,1906247262,2022837584,265905162,114585348,499347990,349075736,736970802,585122620,972512814,821712160,2595684844,2478443234,2293045232,2174754046,3196267988,3079546586,2895723464,2777952454,3537852828,3687994002,3234156416,3385345166,4142626212,4293295786,3841024952,3992742070,174567692,57326082,410887952,292596766,777231668,660510266,1011452712,893681702,1108339068,1258480242,1343618912,1494807662,1715193156,1865862730,1948373848,2100090966,2701949495,2818666809,3004591147,3122358053,2235061775,2352307457,2535604243,2653899549,3915653703,3764988233,4219352155,4067639125,3444575871,3294430577,3746175075,3594982253,836553431,953270745,600235211,718002117,367585007,484830689,133361907,251657213,2041877159,1891211689,1806599355,1654886325,1568718495,1418573201,1335535747,1184342925];function I(i){for(var t=[],e=0;e<i.length;e+=4)t.push(i[e]<<24|i[e+1]<<16|i[e+2]<<8|i[e+3]);return t}function A(i){if(!(this instanceof A))throw Error("AES must be instanitated with `new`");Object.defineProperty(this,"key",{value:r(i,!0)}),this.gAA()}function C(i){if(!(this instanceof C))throw Error("AES must be instanitated with `new`");this.description="Electronic Code Block",this.name="ecb",this.tAA=new A(i)}function E(i,t){if(!(this instanceof E))throw Error("AES must be instanitated with `new`");if(this.description="Cipher Block Chaining",this.name="cbc",t){if(16!=t.length)throw new Error("invalid initialation vector size (must be 16 bytes)")}else t=a(16);this.IAA=r(t,!0),this.tAA=new A(i)}function M(i,t,e){if(!(this instanceof M))throw Error("AES must be instanitated with `new`");if(this.description="Cipher Feedback",this.name="cfb",t){if(16!=t.length)throw new Error("invalid initialation vector size (must be 16 size)")}else t=a(16);this.BAA=e=e||1,this.eAA=r(t,!0),this.tAA=new A(i)}function D(i,t){if(!(this instanceof D))throw Error("AES must be instanitated with `new`");if(this.description="Output Feedback",this.name="ofb",t){if(16!=t.length)throw new Error("invalid initialation vector size (must be 16 bytes)")}else t=a(16);this.QAA=r(t,!0),this.oAA=16,this.tAA=new A(i)}function T(i){if(!(this instanceof T))throw Error("Counter must be instanitated with `new`");"number"==typeof(i=0!==i?i||1:i)?(this.g2t=a(16),this.VV(i)):this.CAA(i)}function z(i,t){if(!(this instanceof z))throw Error("AES must be instanitated with `new`");this.description="Counter",this.name="ctr",t instanceof T||(t=new T(t)),this.g2t=t,this.EAA=null,this.hAA=16,this.tAA=new A(i)}A.prototype.gAA=function(){var i=u[this.key.length];if(null==i)throw new Error("invalid key size (must be 16, 24 or 32 bytes)");this.aAA=[],this.nAA=[];for(var t=0;t<=i;t++)this.aAA.push([0,0,0,0]),this.nAA.push([0,0,0,0]);for(var e,o=4*(i+1),h=this.key.length/4,r=I(this.key),t=0;t<h;t++)this.aAA[e=t>>2][t%4]=r[t],this.nAA[i-e][t%4]=r[t];for(var n,l=0,a=h;a<o;){if(n=r[h-1],r[0]^=d[n>>16&255]<<24^d[n>>8&255]<<16^d[255&n]<<8^d[n>>24&255]^p[l]<<24,l+=1,8!=h)for(t=1;t<h;t++)r[t]^=r[t-1];else{for(t=1;t<h/2;t++)r[t]^=r[t-1];for(n=r[h/2-1],r[h/2]^=d[255&n]^d[n>>8&255]<<8^d[n>>16&255]<<16^d[n>>24&255]<<24,t=h/2+1;t<h;t++)r[t]^=r[t-1]}for(t=0;t<h&&a<o;)this.aAA[s=a>>2][f=a%4]=r[t],this.nAA[i-s][f]=r[t++],a++}for(var s=1;s<i;s++)for(var f=0;f<4;f++)n=this.nAA[s][f],this.nAA[s][f]=m[n>>24&255]^k[n>>16&255]^_[n>>8&255]^S[255&n]},A.prototype.encrypt=function(i){if(16!=i.length)throw new Error("invalid plaintext size (must be 16 bytes)");for(var t=this.aAA.length-1,e=[0,0,0,0],o=I(i),h=0;h<4;h++)o[h]^=this.aAA[0][h];for(var r=1;r<t;r++){for(h=0;h<4;h++)e[h]=x[o[h]>>24&255]^y[o[(h+1)%4]>>16&255]^c[o[(h+2)%4]>>8&255]^v[255&o[(h+3)%4]]^this.aAA[r][h];o=e.slice()}for(var n,l=a(16),h=0;h<4;h++)n=this.aAA[t][h],l[4*h]=255&(d[o[h]>>24&255]^n>>24),l[4*h+1]=255&(d[o[(h+1)%4]>>16&255]^n>>16),l[4*h+2]=255&(d[o[(h+2)%4]>>8&255]^n>>8),l[4*h+3]=255&(d[255&o[(h+3)%4]]^n);return l},A.prototype.decrypt=function(i){if(16!=i.length)throw new Error("invalid ciphertext size (must be 16 bytes)");for(var t=this.nAA.length-1,e=[0,0,0,0],o=I(i),h=0;h<4;h++)o[h]^=this.nAA[0][h];for(var r=1;r<t;r++){for(h=0;h<4;h++)e[h]=g[o[h]>>24&255]^w[o[(h+3)%4]>>16&255]^b[o[(h+2)%4]>>8&255]^R[255&o[(h+1)%4]]^this.nAA[r][h];o=e.slice()}for(var n,l=a(16),h=0;h<4;h++)n=this.nAA[t][h],l[4*h]=255&(f[o[h]>>24&255]^n>>24),l[4*h+1]=255&(f[o[(h+3)%4]>>16&255]^n>>16),l[4*h+2]=255&(f[o[(h+2)%4]>>8&255]^n>>8),l[4*h+3]=255&(f[255&o[(h+1)%4]]^n);return l},C.prototype.encrypt=function(i){if((i=r(i)).length%16!=0)throw new Error("invalid plaintext size (must be multiple of 16 bytes)");for(var t=a(i.length),e=a(16),o=0;o<i.length;o+=16)n(i,e,0,o,o+16),n(e=this.tAA.encrypt(e),t,o);return t},C.prototype.decrypt=function(i){if((i=r(i)).length%16!=0)throw new Error("invalid ciphertext size (must be multiple of 16 bytes)");for(var t=a(i.length),e=a(16),o=0;o<i.length;o+=16)n(i,e,0,o,o+16),n(e=this.tAA.decrypt(e),t,o);return t},E.prototype.encrypt=function(i){if((i=r(i)).length%16!=0)throw new Error("invalid plaintext size (must be multiple of 16 bytes)");for(var t=a(i.length),e=a(16),o=0;o<i.length;o+=16){n(i,e,0,o,o+16);for(var h=0;h<16;h++)e[h]^=this.IAA[h];this.IAA=this.tAA.encrypt(e),n(this.IAA,t,o)}return t},E.prototype.decrypt=function(i){if((i=r(i)).length%16!=0)throw new Error("invalid ciphertext size (must be multiple of 16 bytes)");for(var t=a(i.length),e=a(16),o=0;o<i.length;o+=16){n(i,e,0,o,o+16);for(var e=this.tAA.decrypt(e),h=0;h<16;h++)t[o+h]=e[h]^this.IAA[h];n(i,this.IAA,0,o,o+16)}return t},M.prototype.encrypt=function(i){if(i.length%this.BAA!=0)throw new Error("invalid plaintext size (must be segmentSize bytes)");for(var t=r(i,!0),e=0;e<t.length;e+=this.BAA){for(var o=this.tAA.encrypt(this.eAA),h=0;h<this.BAA;h++)t[e+h]^=o[h];n(this.eAA,this.eAA,0,this.BAA),n(t,this.eAA,16-this.BAA,e,e+this.BAA)}return t},M.prototype.decrypt=function(i){if(i.length%this.BAA!=0)throw new Error("invalid ciphertext size (must be segmentSize bytes)");for(var t=r(i,!0),e=0;e<t.length;e+=this.BAA){for(var o=this.tAA.encrypt(this.eAA),h=0;h<this.BAA;h++)t[e+h]^=o[h];n(this.eAA,this.eAA,0,this.BAA),n(i,this.eAA,16-this.BAA,e,e+this.BAA)}return t},D.prototype.decrypt=D.prototype.encrypt=function(i){for(var t=r(i,!0),e=0;e<t.length;e++)16===this.oAA&&(this.QAA=this.tAA.encrypt(this.QAA),this.oAA=0),t[e]^=this.QAA[this.oAA++];return t},T.prototype.VV=function(i){if("number"!=typeof i||parseInt(i)!=i)throw new Error("invalid counter value (must be an integer)");if(i>Number.MAX_SAFE_INTEGER)throw new Error("integer value out of safe range");for(var t=15;0<=t;--t)this.g2t[t]=i%256,i=parseInt(i/256)},T.prototype.CAA=function(i){if(16!=(i=r(i,!0)).length)throw new Error("invalid counter bytes size (must be 16 bytes)");this.g2t=i},T.prototype.lAA=function(){for(var i=15;0<=i;i--){if(255!==this.g2t[i]){this.g2t[i]++;break}this.g2t[i]=0}},z.prototype.decrypt=z.prototype.encrypt=function(i){for(var t=r(i,!0),e=0;e<t.length;e++)16===this.hAA&&(this.EAA=this.tAA.encrypt(this.g2t.g2t),this.hAA=0,this.g2t.lAA()),t[e]^=this.EAA[this.hAA++];return t},i.exports={rAA:A,Counter:T,sAA:{wAA:C,cAA:E,yAA:M,xAA:D,dAA:z},fAA:{pAA:s,DAA:l},padding:{uAA:{pad:function(i){var t=16-(i=r(i,!0)).length%16,e=a(i.length+t);n(i,e);for(var o=i.length;o<e.length;o++)e[o]=t;return e},RAA:function(i){if((i=r(i,!0)).length<16)throw new Error("PKCS#7 invalid length");var t=i[i.length-1];if(16<t)throw new Error("PKCS#7 padding byte out of range");for(var e=i.length-t,o=0;o<t;o++)if(i[e+o]!==t)throw new Error("PKCS#7 invalid padding byte");var h=a(e);return n(i,h,0,0,e),h}}},vAA:{bAA:r,SAA:a,GAA:n}}}),_a,geoUtil=new polyfill.rW({}),LabelFormatMap=(_a={},_a[polyfill.NebulaLabelFormat.id]=polyfill.NebulaLabelFormat,_a.nebula=polyfill.NebulaLabelFormat,_a[polyfill.MapboxLabelFormat.id]=polyfill.MapboxLabelFormat,_a),NebulaSourceWorker=function(e){function h(i){var t=e.call(this)||this;return t.parent=i,t.id="nebula",t.sQ={},t.aW=null,t.WW=20,t.xQ=[],t.bQ=[],t.iii=[26,16,8,4,12,20,9,3,6,23,14,17,1,5,19,2],t.bind(),t}return polyfill.Ei(h,e),h.prototype.bind=function(){var g=this;this.on("styleReady",function(){var i=g.xQ.length;if(0<i){for(var t=0;t<i;t++){var e=(d=g.xQ[t]).data,o=d.projectionId,h=d.zoom,r=d.viewMode,n=d.showBuildingBlock,l=d.mS,a=d.optimalZoom,s=d.ZL,f=d.cb,u=d.url;g.pQ(e,o,h,r,n,l,a,s,f,u)}g.xQ=[]}var p=g.bQ.length;if(0<p){for(t=0;t<p;t++){var d,x=(d=g.bQ[t]).CD,y=d.cQ,e=d.data,o=d.projectionId,f=d.cb,c=d.UQ,v=d.mH,s=d.ZL;g.mQ(x,y,e,o,f,c,v,s)}g.bQ=[]}})},h.prototype.bw=function(e,i,o,h,r,t,n,l,a,s,f,u,p){var d=this;if(void 0===p&&(p=!0),polyfill.Support.wasm&&p){if(!this.parent.PW)return void u("not init");p=i.join(";"),p=_aesJs_3_1_2_aesJs.fAA.DAA.AAA('["'+p+'","'+f+'"]'),p=new _aesJs_3_1_2_aesJs.sAA.dAA(this.iii,new _aesJs_3_1_2_aesJs.Counter(5)).encrypt(p),p=_aesJs_3_1_2_aesJs.fAA.pAA.iAA(p),e=e+("?key="+this.parent.key)+"&val="+p}else e=e+("?key="+this.parent.key)+"&flds="+f+"&t="+i.join(";");return e+="&p=3",makeFetchRequest(this.parent.Uh,e,function(i,t){i?u(i):setTimeout(function(){d.pQ(t,r,o,l,a,n,h,s,u,e)},10)})},h.prototype.pQ=function(i,e,o,h,r,n,l,t,a,s){var f=this;if(this.parent.vn&&this.parent.vn._Q()){polyfill.Support.amapRunTime&&!polyfill.Support.amapRunTime["data-decode-begin"]&&(polyfill.Support.amapRunTime["data-decode-begin"]=(new Date).getTime());for(var u=polyfill.KQ(new Uint8Array(i)),p=[],d=(polyfill.forEach(u.tiles,function(i){var t=new polyfill.Gh(new polyfill.ca(i.z,i.x,i.y)),i=(t.data=f.kw(i,e,t),f.xw(t,o),f.zw(t,o,h,r),f.nz(t,n,l),polyfill.Util.pW(i.t));p.push({zo:t.zo,ba:t.data,tag:i,version:u.version||""})}),[]),x=this.parent.vn,y=0,c=p;y<c.length;y++){var v=c[y];if(v&&v.ba){if(v.ba.road){for(var g=[],w=0,b=v.ba.road;w<b.length;w++){var m=b[w],R=(R=x.dn(m.Fp,m.Ep,t))?R[1]:null;m.id&&R&&R.fontSize&&R.faceColor&&(delete m.gw,g.push({path:m.path,id:m.id}))}v.ba.road=g}delete v.ba.poilabel,delete v.ba.region,delete v.ba.building,delete v.ba.Mw}d.push(v)}polyfill.Support.amapRunTime&&!polyfill.Support.amapRunTime["data-decode-end"]&&(polyfill.Support.amapRunTime["data-decode-end"]=(new Date).getTime()),a(null,{nebulaDatas:d,amapRunTime:polyfill.Support.amapRunTime})}else this.xQ.push({data:i,projectionId:e,zoom:o,viewMode:h,showBuildingBlock:r,mS:n,optimalZoom:l,ZL:t,cb:a,url:s})},h.prototype.mQ=function(i,t,e,o,h,r,n,l){this.parent.vn?this.HQ(e,t,o,i,r,n,l,h):this.bQ.push({CD:i,cQ:t,data:e,projectionId:o,cb:h,UQ:r,mH:n,ZL:l})},h.prototype.bW=function(i,e,o,h,r,n){var l=this;if(polyfill.Support.wasm){if(!this.parent.PW)return void n("not init");var t=e.join(";"),t=_aesJs_3_1_2_aesJs.fAA.DAA.AAA('["'+t+'","poi,roadname"]'),t=new _aesJs_3_1_2_aesJs.sAA.dAA(this.iii,new _aesJs_3_1_2_aesJs.Counter(5)).encrypt(t),t=_aesJs_3_1_2_aesJs.fAA.pAA.iAA(t);i=i+("?key="+this.parent.key)+"&val="+t}else i=i+("?key="+this.parent.key)+"&flds=poi,roadname&t="+e.join(";");i+="&p=3",this.WW=h;var a=-1!==i.indexOf("/oversea"),s=new polyfill.vH;return s._H(makeFetchRequest(this.parent.Uh,i,function(i,t){i?n(i):setTimeout(function(){l.mQ(e,a,t,o,n,s,r,h)},10)})),{cancel:s.cancel}},h.prototype.HQ=function(i,t,e,o,h,r,n,l){for(var a=this,s=polyfill.KQ(new Uint8Array(i)),f=(!t&&s.version&&this.parent.GW.nebulaVersion!==s.version&&(this.parent.GW.nebulaVersion=s.version,this.parent.GW.db=s.db,this.parent.IW.zW(this.parent.GW.db),this.parent.Uh.send("updateDataVersion",this.parent.GW.nebulaVersion)),[]),u=(polyfill.forEach(s.tiles,function(i){var t=new polyfill.Gh(new polyfill.ca(i.z,i.x,i.y)),i=(t.data=a.kw(i,e,t),polyfill.Util.pW(i.t));f.push({zo:t.zo,ba:t.data,tag:i})}),[]),p=0,d=f;p<d.length;p++){var x,y,c=d[p];c&&c.ba&&(x=c.ba.roadName,y=c.ba.poilabel,delete c.ba.poilabel,delete c.ba.Mw,u.push({zo:c.zo,ba:{roadName:x,poilabel:y},tag:c.tag,version:s.version||""}))}if(u.length){for(var v={},g=0,w=u;g<w.length;g++){var R=new polyfill.Gh((b=w[g]).zo),m=polyfill.wa.ga(R.zo.x,R.zo.y,R.zo.z,"EPSG:3857"),m=(R.type="nebula",t&&(R.cQ=!0),polyfill.lcs.getLocalByCoord([m[0],m[1]]));R.localCoord=m,R.data=b.ba;(m=this.parent.params).showLabel;var m=m.scale,b=b.tag;this.sQ[R.zo.key+","+b]={tile:R,params:{scale:m,tag:b}},v[R.zo.key+","+polyfill.Util.SD(b)]=!0}l(null,v)}},h.prototype.OW=function(i){this.parent.Zw?this.on("once",i):i()},h.prototype.YE=function(i,t){polyfill.map(polyfill.ZQ.ha(t.bounds,polyfill.ZQ.ra(t.zoom)),function(i){return i.join(",")});var t=this.sQ,e=polyfill.Util.getOptimalZoom(this.WW);i(t,{ZL:this.WW,optimalZoom:e,cb:function(){}}),this.sQ={}},h.prototype.kw=function(i,t,e){var x=this,o={},y=polyfill.ProjectionManager.getProjection(t),t=polyfill.wa.ga(i.x,i.y,i.z,"EPSG:3857"),c=polyfill.lcs.getLocalByCoord([t[0],t[1]]).center,v=(e.Mw=c,e.Ro=t,e.zo.z);return polyfill.forEach(i.layers,function(u){var i,p=[],d=h.Wa[u.type];polyfill.forEach(u.d[d],function(s){s.items.sort(x.A0);var f=x.parent.vn.mW(s.mainkey,s.subkey,v);polyfill.forEach(s.items,function(i){switch(d){case"road":for(var t=0;t<i.path.length;t+=2){var e=i.path[t],o=i.path[t+1],h=polyfill.XY(u,s.resolution,e,o),h=y.project(h[0],h[1]);v>=polyfill.Ra&&(h[0]-=c[0],h[1]-=c[1]),i.path[t]=h[0],i.path[t+1]=h[1]}break;case"region":for(var r=i.path,n=0;n<r.length;n+=1){for(var l=r[n].path,a=[],t=0;t<l.length;t+=2)e=l[t],o=l[t+1],h=polyfill.XY(u,s.resolution,e,o),a[t]=h[0],a[t+1]=h[1],h=y.project(h[0],h[1]),v>=polyfill.Ra&&(h[0]-=c[0],h[1]-=c[1]),l[t]=h[0],l[t+1]=h[1];r[n]=l}break;case"building":for(r=i.path,i.oW=[],n=0;n<r.length;n+=1){for(l=r[n].path,a=[],t=0;t<l.length;t+=2)e=l[t],o=l[t+1],h=polyfill.XY(u,s.resolution,e,o),a[t]=h[0],a[t+1]=h[1],h=y.project(h[0],h[1]),v>=polyfill.Ra&&(h[0]-=c[0],h[1]-=c[1]),l[t]=h[0],l[t+1]=h[1];r[n]=l,i.oW[n]=a}break;case"poilabel":case"roadName":if(i.pos&&(a=polyfill.XY(u,s.resolution,i.pos[0],i.pos[1]),i.pos=y.project(a[0],a[1])),i.path)if(i.shield)a=polyfill.XY(u,s.resolution,i.path[0],i.path[1]),h=y.project(a[0],a[1]),v>=polyfill.Ra&&(h[0]-=c[0],h[1]-=c[1]),i.path[0]=h[0],i.path[1]=h[1];else for(t=0;t<i.path.length;t+=2)e=i.path[t],o=i.path[t+1],h=polyfill.XY(u,s.resolution,e,o),h=y.project(h[0],h[1]),v>=polyfill.Ra&&(h[0]-=c[0],h[1]-=c[1]),i.path[t]=h[0],i.path[t+1]=h[1]}i.du=s.resolution,i.Fp=s.mainkey,i.Ep=s.subkey,i.zIndex=x.parent.vn.Lw(s.mainkey,s.subkey),i.lineCap=f[0],i.RQ=f[1],i.gw={z:u.z,y:u.y,x:u.x},p.push(i)})}),"poilabel"!==d?x.Tw(p):x.Na(p),"poilabel"===d?(i=u.z+"-"+u.x+"-"+u.y,o[d]?o[d][i]?o[d][i].push.apply(o[d][i],p):o[d][i]=p:(o[d]={},o[d][i]=p)):o[d]?o[d].push.apply(o[d],p):o[d]=p}),o.Mw=c,o},h.prototype.A0=function(i,t){return i.minzoom-t.minzoom||i.maxzoom-t.maxzoom},h.prototype.Tw=function(i){return i.sort(function(i,t){return i.zIndex-t.zIndex}),i},h.prototype.Na=function(i){return i.sort(function(i,t){return i.rank-t.rank}),i},h.prototype.xw=function(i,t){var e=i.data,o=new polyfill._w;if(e.Uc=o,!e.$c){e.$c=new polyfill.J_,e.road=e.road||[];var h=i.Mw.slice(0);if(i.zo.z<=polyfill.za&&(h[0]=0,h[1]=0),e.road.push({name:"",rank:1,maxzoom:polyfill.zoomRange[1],minzoom:polyfill.zoomRange[0],path:[i.Ro[0]-h[0],i.Ro[1]-h[1],i.Ro[2]-h[0],i.Ro[1]-h[1],i.Ro[2]-h[0],i.Ro[3]-h[1],i.Ro[0]-h[0],i.Ro[3]-h[1],i.Ro[0]-h[0],i.Ro[1]-h[1]],Fp:-2,Ep:-2,shield:"",shieldType:0,du:13,lineCap:"butt",RQ:"butt"}),e.road)for(var r=0,n=e.road;r<n.length;r++){var l=n[r],a=l.path,s=(a=e.$c.hb(a,{X_:"butt"===l.lineCap?0:.9,lineCap:l.lineCap,lineJoin:"auto"})).Iw,a=a.distance;0<s&&(o.add(l.Fp,l.Ep,s,l.minzoom,l.maxzoom),l.distance=a)}}},h.prototype.zw=function(i,L,P,t){var e=i.data,o=new polyfill._w;if(e.Oc=o,e.Fc=new polyfill._w,!e.Dc){e.Dc=new polyfill.K_,e.region=e.region||[];var h=i.Mw.slice(0);if(i.zo.z<=polyfill.za&&(h[0]=0,h[1]=0),e.region.unshift({maxzoom:polyfill.zoomRange[1],minzoom:polyfill.zoomRange[0],path:[[i.Ro[0]-h[0],i.Ro[1]-h[1],i.Ro[2]-h[0],i.Ro[1]-h[1],i.Ro[2]-h[0],i.Ro[3]-h[1],i.Ro[0]-h[0],i.Ro[3]-h[1],i.Ro[0]-h[0],i.Ro[1]-h[1]]],Fp:30001,Ep:1}),e.region)for(var r=0,n=e.region;r<n.length;r++)for(var l=n[r],a=0,s=l.path;a<s.length;a++)(b=s[a]).push(b[0],b[1]),0<(A=e.Dc.Nx(b))&&o.add(l.Fp,l.Ep,A,l.minzoom,l.maxzoom);if(!t&&e.building){if(e.FD)return;e.FD=new polyfill.K_,e.BD=new polyfill._w;for(var f=e.BD,u=0,p=e.building;u<p.length;u++){for(var d=p[u],y=(x=polyfill.jw(d.gw.z,d.gw.x,d.gw.y))[0],c=x[1],v=x[2],x=x[3],B=(i.Mw&&(y-=i.Mw[0],v-=i.Mw[0],c-=i.Mw[1],x-=i.Mw[1]),Math.floor(y)),O=Math.floor(v),J=Math.floor(c),U=Math.floor(x),g=0,w=d.path;g<w.length;g++){var b=w[g];0<(A=e.FD.Nx(b))&&f.add(d.Fp,d.Ep,A,d.minzoom,d.maxzoom,d.ew||"indoor_out_building")}for(var R=0,m=d.path;R<m.length;R++){for(var k=m[R],b=(k.push(k[0],k[1]),[]),_=0,S=k.length;_<S-2;_+=2)b.push(polyfill.xd(k[_],k[_+1])),b.push(polyfill.xd(k[_+2],k[_+3]));for(var I=[],_=0,S=b.length;_<S;_+=2){var A,C=b[_][0],E=b[_][1],j=b[_+1][0],V=b[_+1][1],M=Math.floor(C),D=Math.floor(E);(C!==j||M!==B&&M!==O)&&(E!==V||D!==J&&D!==U)?I.push(b[_],b[_+1]):(0<(A=e.Dc.Ew(I))&&e.Fc.add(d.Fp,d.Ep,A,d.minzoom,d.maxzoom,d.ew||"indoor_out_building"),I=[])}0<I.length&&0<(A=e.Dc.Ew(I))&&e.Fc.add(d.Fp,d.Ep,A,d.minzoom,d.maxzoom,d.ew)}}}if(e.building){for(var T=[],z=0,W=e.building;z<W.length;z++)if((d=W[z]).ew)if(-1<d.ew.indexOf("|"))for(var F=d.ew.split("|"),_=0;_<F.length;_++)T.push(F[_]);else T.push(d.ew);e.indoorInfo||(e.indoorInfo=[]),e.indoorInfo=T}}},h.prototype.nz=function(i,t,e){void 0===t&&(t={});var o=i.data;if(o.C_=new polyfill._w,!o.A_){o.A_=new polyfill.iz;var h=t.hideWithoutStyle,r=t.areas;if(o.building)for(var n=0,l=o.building;n<l.length;n++)for(var a=l[n],s=0;s<a.path.length;s++){for(var f=a.path[s],u=a.oW[s],p=(f.push(f[0],f[1]),u.push(u[0],u[1]),[]),d=0;d<u.length;d+=2)p.push([u[d],u[d+1]]);if(r){for(var x,y=!1,c=!1,v={},g=0;g<r.length;g++){var w=r[g],b=w.path;geoUtil.isRingInRing(p,b)&&(y=!0,!w.visible&&void 0!==w.visible||(c=!0,v={roofColor:polyfill.Util.color2RgbaArray(w.color1),wallColor:polyfill.Util.color2RgbaArray(w.color2)}))}!y&&h||y&&!c||0<(x=o.A_.tz(f,a.height))&&o.C_.add(a.Fp,a.Ep,x,a.minzoom,a.maxzoom,a.ew,v.roofColor,v.wallColor)}else 0<(x=o.A_.tz(f,a.height))&&o.C_.add(a.Fp,a.Ep,x,a.minzoom,a.maxzoom,a.ew)}}},h.prototype.hQ=function(i,t){if(i)for(var e=this.SQ(i)||[],o=0,h=e=new LabelFormatMap[i.type]({vn:this.parent.vn}).DQ(e,{zoom:t});o<h.length;o++){var r=h[o],n=r.CO;r.EG||(r.EG={});for(var l=0,a=n;l<a.length;l++){var s=a[l],f=this.parent.R_.mz(s);r.EG[s]=f}}return e},h.prototype.SQ=function(i){return i.data&&i.data.roadName||i.Dh},h.Pw=[1,0,1,0],h.Wa={0:"poilabel",1:"road",2:"region",3:"building",4:"roadName"},h}(polyfill.Event),hasWarning=!1;function makeFetchRequest(i,t,e){var o,h,r;return!polyfill.Support.safari&&!polyfill.Support.AQ&&!polyfill.Support.gQ&&self.fetch&&self.Request&&self.AbortController&&self.Request.prototype.hasOwnProperty("signal")?(h=(o=new AbortController).signal,h=new self.Request(t,{method:"GET",referrer:"null"===self.location.origin?void 0:self.location.origin,signal:h}),polyfill.Support.amapRunTime&&!polyfill.Support.amapRunTime["data-request"]&&(polyfill.Support.amapRunTime["data-request"]=(new Date).getTime()),fetch(h).then(function(i){return polyfill.Support.amapRunTime&&!polyfill.Support.amapRunTime["data-loaded"]&&(polyfill.Support.amapRunTime["data-loaded"]=(new Date).getTime()),"application/x-protobuf"===i.headers.get("content-type")?i.arrayBuffer():i.json()}).then(function(i){i.info?hasWarning||(hasWarning=!0,console.log(t),console.log("<AMap JSAPI> KEY异常,错误信息:"+i.info)):e(null,i)}).catch(function(i){"AbortError"!==i.name&&e(i.message||"unknown error")}),{cancel:function(){o.abort()}}):r=i.send("request",t,function(i,t){i?("<cancel>"===i&&r&&r.cancel&&r.cancel(),r=void 0,e(i)):(r=void 0,e(null,t))})}var DistrictSourceWorker=function(){function DistrictSourceWorker(i){this.parent=i,this.fW={}}return DistrictSourceWorker.prototype.bw=function(i,t,e,o,h){var r=this,n=new XMLHttpRequest;return n.onreadystatechange=function(){var i;4!==n.readyState||200!==n.status&&204!==n.status||(i=new polyfill.tW(new polyfill.pw(new Uint8Array(n.response))),i=r.Ow(i,{x:t.x,y:t.y,z:t.z,projectionId:e,tileSize:o}),h(null,polyfill.Ln({zo:t},i)))},n.open("GET",i,!0),n.responseType="arraybuffer",n.send(),{cancel:function(){n.abort()}}},DistrictSourceWorker.prototype.Ow=function(s,i){var e=i.x,o=i.y,h=i.z,r=i.tileSize,n=i.projectionId,i=(s.z=h,s.x=e,s.y=o,polyfill.ProjectionManager.getProjection(n).getResolution(h)),l=(s.Ro=polyfill.$Q(e,o,h,i,r),s.zS=polyfill.lcs.getLocalByCoord([s.Ro[0],s.Ro[1]]),polyfill.ProjectionManager.getProjection(n).getResolution(h));return polyfill.vx(s.layers,function(a){var i=a.Cw,t=(a.Ah=[],a.scale=l*r/a.extent,polyfill.V[n].Xs(r*e,r*o,h));a.ox=t[0],a.oy=t[1],polyfill.forEach(i,function(i,t){if((i=a.Gw(t)).Dw(),a.Ah.push(i),i.lines&&0<i.lines.length){i.Rw=[];for(var e=0,o=i.lines.length;e<o;e++){for(var h=[],r=0,n=i.lines[e].length;r<n;r++){var l=[a.ox+a.scale*i.lines[e][r][0]-s.zS.center[0],a.oy-a.scale*i.lines[e][r][1]-s.zS.center[1]];h.push(l)}i.Rw.push(h)}}})}),this.uW(s),this.xw(s),this.zw(s),s},DistrictSourceWorker.prototype.uW=function(i){var t,e=[],o=[];for(t in i.layers)if(i.layers.hasOwnProperty(t))for(var h=i.layers[t],r=0;r<h.Ah.length;r+=1){var n=h.Ah[r];if(3==+n.type&&n.Rw){for(var l=n.Rw,a=[],s=0;s<l.length;s++)polyfill.kS.isClockwise(l[s])?a.push([s]):a.length&&a[a.length-1].push(s);for(var f=0;f<a.length;f++){var u=a[f];if(1<u.length){for(var p=[],d=[],x=0;x<u.length;x++){var y=l[u[x]];0<x&&p.push(d.length/2);for(var c=0;c<y.length;c++){var v=y[c];d.push(v[0],v[1])}}e.push({properties:n.properties,path:d,LQ:p})}else{for(d=[],y=l[u[0]],c=0;c<y.length;c++){var g=y[c];d.push(g[0],g[1])}e.push({properties:n.properties,path:d})}}}else if(3!==n.type&&n.Rw)for(var w=0;w<n.Rw.length;w++)o.push({properties:n.properties,path:n.Rw[w]});this.cW(n)}i.polygons=e,i.Dh=o,delete i.layers},DistrictSourceWorker.prototype.xw=function(i){if(!i||!i.$c){var t=new polyfill.LW;if(!i.$c&&(i.Uc=t,i.$c=new polyfill.J_,i.Dh))for(var e=0,o=i.Dh;e<o.length;e++){var h=o[e],r=JSON.stringify(h.properties),l=(n=i.$c.g0(h.path,{X_:0,lineJoin:"round",lineCap:"butt"})).Iw,n=n.distance;0<l&&(t.add(r,0,l,0,22),h.distance=n)}}},DistrictSourceWorker.prototype.zw=function(i){if(!i||!i.Dc){var t=new polyfill.LW;i.Oc=t,i.Dc=new polyfill.K_;for(var e=0,o=i.polygons;e<o.length;e++){var h=o[e],r=JSON.stringify(h.properties);0<(h=i.Dc.Nx(h.path,h.LQ))&&t.add(r,0,h,0,22)}}},DistrictSourceWorker.prototype.dW=function(i){switch(i){case 0:case 1:return"Nation_Border_China";case 2:return"Coastline_China";case 3:case 4:return"Province_Border_China";case 5:return"City_Border_China";case 6:return"County_Border_China";case 7:case 8:return"Nation_Border_Foreign";case 9:return"Coastline_Foreign";case 10:case 11:return"Nation_Border_Foreign";case 12:return"Province_Border_Foreign";default:return""}},DistrictSourceWorker.prototype.sW=function(code){return this.fW[code]||(this.fW[code]=eval("'"+code.replace(/\//g,"\\u")+"'")),this.fW[code]},DistrictSourceWorker.prototype.cW=function(i){i.properties.NAME_CHN&&(i.properties.NAME_CHN=this.sW(i.properties.NAME_CHN.trim())),i.properties.NAME_ENG&&(i.properties.NAME_ENG=i.properties.NAME_ENG.trim()),i.properties.level&&(i.properties.level=i.properties.level.trim()),i.properties.citycode&&i.properties.citycode.length&&(i.properties.citycode=i.properties.citycode.trim()),i.properties.type_=+i.properties.type,i.properties.feature_type_=+i.type,i.properties.type=this.dW(+i.properties.type)},DistrictSourceWorker}(),mbStyle={Hr:void 0,_r:{},kr:{"pedestrian-polygon":{width:128,height:128,x:0,y:0,pixelRatio:2,visible:!0},"turning-circle-outline":{width:92,height:92,x:128,y:0,pixelRatio:2,visible:!0},"turning-circle":{width:84,height:84,x:0,y:128,pixelRatio:2,visible:!0},"us-interstate-truck-2":{width:40,height:80,x:84,y:128,pixelRatio:2,visible:!0},"us-interstate-truck-3":{width:52,height:80,x:124,y:128,pixelRatio:2,visible:!0},"us-highway-business-2":{width:40,height:76,x:176,y:128,pixelRatio:2,visible:!0},"us-highway-business-3":{width:52,height:76,x:216,y:128,pixelRatio:2,visible:!0},"us-highway-bypass-2":{width:40,height:76,x:268,y:128,pixelRatio:2,visible:!0},"us-highway-bypass-3":{width:52,height:76,x:308,y:128,pixelRatio:2,visible:!0},"us-highway-truck-2":{width:40,height:76,x:360,y:128,pixelRatio:2,visible:!0},"us-highway-truck-3":{width:52,height:76,x:400,y:128,pixelRatio:2,visible:!0},"ae-f-route-3":{width:48,height:54,x:452,y:128,pixelRatio:2,visible:!0},"ae-s-route-4":{width:76,height:52,x:220,y:0,pixelRatio:2,visible:!0},"pe-national-2":{width:36,height:52,x:296,y:0,pixelRatio:2,visible:!0},"pe-national-3":{width:44,height:52,x:332,y:0,pixelRatio:2,visible:!0},"ae-national-3":{width:52,height:50,x:376,y:0,pixelRatio:2,visible:!0},"ae-national-4":{width:64,height:50,x:428,y:0,pixelRatio:2,visible:!0},"ae-d-route-3":{width:48,height:48,x:0,y:212,pixelRatio:2,visible:!0},"ae-d-route-4":{width:60,height:48,x:48,y:212,pixelRatio:2,visible:!0},"tw-provincial-2":{width:44,height:48,x:108,y:212,pixelRatio:2,visible:!0},"tw-provincial-3":{width:56,height:48,x:152,y:212,pixelRatio:2,visible:!0},"tw-provincial-expy-2":{width:44,height:48,x:208,y:212,pixelRatio:2,visible:!0},"tw-provincial-expy-3":{width:56,height:48,x:252,y:212,pixelRatio:2,visible:!0},"za-provincial-2":{width:48,height:48,x:308,y:212,pixelRatio:2,visible:!0},"cn-nths-expy-2":{width:40,height:46,x:356,y:212,pixelRatio:2,visible:!0},"cn-nths-expy-3":{width:52,height:46,x:396,y:212,pixelRatio:2,visible:!0},"cn-nths-expy-4":{width:64,height:46,x:448,y:212,pixelRatio:2,visible:!0},"cn-nths-expy-5":{width:76,height:46,x:0,y:260,pixelRatio:2,visible:!0},"cn-provincial-expy-2":{width:40,height:46,x:76,y:260,pixelRatio:2,visible:!0},"cn-provincial-expy-3":{width:52,height:46,x:116,y:260,pixelRatio:2,visible:!0},"cn-provincial-expy-4":{width:64,height:46,x:168,y:260,pixelRatio:2,visible:!0},"cn-provincial-expy-5":{width:76,height:46,x:232,y:260,pixelRatio:2,visible:!0},"br-federal-3":{width:52,height:44,x:308,y:260,pixelRatio:2,visible:!0},"hk-strategic-route-2":{width:36,height:44,x:360,y:260,pixelRatio:2,visible:!0},"in-national-2":{width:32,height:44,x:396,y:260,pixelRatio:2,visible:!0},"in-national-3":{width:40,height:44,x:428,y:260,pixelRatio:2,visible:!0},"in-national-4":{width:48,height:44,x:0,y:306,pixelRatio:2,visible:!0},"in-state-2":{width:32,height:44,x:48,y:306,pixelRatio:2,visible:!0},"in-state-3":{width:40,height:44,x:80,y:306,pixelRatio:2,visible:!0},"kr-natl-expy-2":{width:40,height:44,x:120,y:306,pixelRatio:2,visible:!0},"kr-natl-expy-3":{width:52,height:44,x:160,y:306,pixelRatio:2,visible:!0},"mx-federal-2":{width:36,height:44,x:212,y:306,pixelRatio:2,visible:!0},"mx-federal-3":{width:46,height:44,x:248,y:306,pixelRatio:2,visible:!0},"mx-federal-4":{width:56,height:44,x:294,y:306,pixelRatio:2,visible:!0},"mx-state-2":{width:36,height:44,x:350,y:306,pixelRatio:2,visible:!0},"mx-state-3":{width:46,height:44,x:386,y:306,pixelRatio:2,visible:!0},"mx-state-4":{width:56,height:44,x:432,y:306,pixelRatio:2,visible:!0},"pe-regional-3":{width:46,height:44,x:0,y:350,pixelRatio:2,visible:!0},"pe-regional-4":{width:56,height:44,x:46,y:350,pixelRatio:2,visible:!0},"tw-national-2":{width:42,height:44,x:102,y:350,pixelRatio:2,visible:!0},"us-interstate-2":{width:40,height:44,x:144,y:350,pixelRatio:2,visible:!0},"us-interstate-3":{width:52,height:44,x:184,y:350,pixelRatio:2,visible:!0},"us-interstate-4":{width:64,height:44,x:236,y:350,pixelRatio:2,visible:!0},"us-interstate-business-2":{width:40,height:44,x:300,y:350,pixelRatio:2,visible:!0},"us-interstate-business-3":{width:52,height:44,x:340,y:350,pixelRatio:2,visible:!0},"us-interstate-duplex-4":{width:64,height:44,x:392,y:350,pixelRatio:2,visible:!0},"us-interstate-duplex-5":{width:76,height:44,x:0,y:394,pixelRatio:2,visible:!0},"airfield-15":{width:42,height:42,x:456,y:350,pixelRatio:2,visible:!0},"airport-15":{width:42,height:42,x:76,y:394,pixelRatio:2,visible:!0},"alcohol-shop-15":{width:42,height:42,x:118,y:394,pixelRatio:2,visible:!0},"american-football-15":{width:42,height:42,x:160,y:394,pixelRatio:2,visible:!0},"amusement-park-15":{width:42,height:42,x:202,y:394,pixelRatio:2,visible:!0},"aquarium-15":{width:42,height:42,x:244,y:394,pixelRatio:2,visible:!0},"art-gallery-15":{width:42,height:42,x:286,y:394,pixelRatio:2,visible:!0},"attraction-15":{width:42,height:42,x:328,y:394,pixelRatio:2,visible:!0},"au-tourist-2":{width:40,height:42,x:370,y:394,pixelRatio:2,visible:!0},"au-tourist-3":{width:56,height:42,x:410,y:394,pixelRatio:2,visible:!0},"bakery-15":{width:42,height:42,x:466,y:394,pixelRatio:2,visible:!0},"bank-15":{width:42,height:42,x:468,y:260,pixelRatio:2,visible:!0},"bar-15":{width:42,height:42,x:0,y:438,pixelRatio:2,visible:!0},"basketball-15":{width:42,height:42,x:42,y:438,pixelRatio:2,visible:!0},"beach-15":{width:42,height:42,x:84,y:438,pixelRatio:2,visible:!0},"beer-15":{width:42,height:42,x:126,y:438,pixelRatio:2,visible:!0},"bicycle-15":{width:42,height:42,x:168,y:438,pixelRatio:2,visible:!0},"bowling-alley-15":{width:42,height:42,x:210,y:438,pixelRatio:2,visible:!0},"bridge-15":{width:42,height:42,x:252,y:438,pixelRatio:2,visible:!0},"cafe-15":{width:42,height:42,x:294,y:438,pixelRatio:2,visible:!0},"campsite-15":{width:42,height:42,x:336,y:438,pixelRatio:2,visible:!0},"car-15":{width:42,height:42,x:378,y:438,pixelRatio:2,visible:!0},"car-rental-15":{width:42,height:42,x:420,y:438,pixelRatio:2,visible:!0},"car-repair-15":{width:42,height:42,x:462,y:438,pixelRatio:2,visible:!0},"casino-15":{width:42,height:42,x:504,y:438,pixelRatio:2,visible:!0},"castle-15":{width:42,height:42,x:546,y:438,pixelRatio:2,visible:!0},"cemetery-15":{width:42,height:42,x:588,y:438,pixelRatio:2,visible:!0},"charging-station-15":{width:42,height:42,x:630,y:438,pixelRatio:2,visible:!0},"cinema-15":{width:42,height:42,x:672,y:438,pixelRatio:2,visible:!0},"clothing-store-15":{width:42,height:42,x:714,y:438,pixelRatio:2,visible:!0},"college-15":{width:42,height:42,x:756,y:438,pixelRatio:2,visible:!0},"communications-tower-15":{width:42,height:42,x:798,y:438,pixelRatio:2,visible:!0},"confectionery-15":{width:42,height:42,x:840,y:438,pixelRatio:2,visible:!0},"convenience-15":{width:42,height:42,x:882,y:438,pixelRatio:2,visible:!0},"dentist-15":{width:42,height:42,x:924,y:438,pixelRatio:2,visible:!0},"doctor-15":{width:42,height:42,x:966,y:438,pixelRatio:2,visible:!0},"dog-park-15":{width:42,height:42,x:488,y:306,pixelRatio:2,visible:!0},"drinking-water-15":{width:42,height:42,x:530,y:306,pixelRatio:2,visible:!0},"embassy-15":{width:42,height:42,x:572,y:306,pixelRatio:2,visible:!0},"farm-15":{width:42,height:42,x:614,y:306,pixelRatio:2,visible:!0},"fast-food-15":{width:42,height:42,x:656,y:306,pixelRatio:2,visible:!0},"fire-station-15":{width:42,height:42,x:698,y:306,pixelRatio:2,visible:!0},"fitness-centre-15":{width:42,height:42,x:740,y:306,pixelRatio:2,visible:!0},"fuel-15":{width:42,height:42,x:782,y:306,pixelRatio:2,visible:!0},"furniture-15":{width:42,height:42,x:824,y:306,pixelRatio:2,visible:!0},"garden-15":{width:42,height:42,x:866,y:306,pixelRatio:2,visible:!0},"globe-15":{width:42,height:42,x:908,y:306,pixelRatio:2,visible:!0},"golf-15":{width:42,height:42,x:950,y:306,pixelRatio:2,visible:!0},"grocery-15":{width:42,height:42,x:498,y:350,pixelRatio:2,visible:!0},"harbor-15":{width:42,height:42,x:540,y:350,pixelRatio:2,visible:!0},"hardware-15":{width:42,height:42,x:582,y:350,pixelRatio:2,visible:!0},"heliport-15":{width:42,height:42,x:624,y:350,pixelRatio:2,visible:!0},"horse-riding-15":{width:42,height:42,x:666,y:350,pixelRatio:2,visible:!0},"hospital-15":{width:42,height:42,x:708,y:350,pixelRatio:2,visible:!0},"ice-cream-15":{width:42,height:42,x:750,y:350,pixelRatio:2,visible:!0},"information-15":{width:42,height:42,x:792,y:350,pixelRatio:2,visible:!0},"jewelry-store-15":{width:42,height:42,x:834,y:350,pixelRatio:2,visible:!0},"laundry-15":{width:42,height:42,x:876,y:350,pixelRatio:2,visible:!0},"library-15":{width:42,height:42,x:918,y:350,pixelRatio:2,visible:!0},"lodging-15":{width:42,height:42,x:960,y:350,pixelRatio:2,visible:!0},"mobile-phone-15":{width:42,height:42,x:508,y:394,pixelRatio:2,visible:!0},"monument-15":{width:42,height:42,x:550,y:394,pixelRatio:2,visible:!0},"mountain-15":{width:42,height:42,x:592,y:394,pixelRatio:2,visible:!0},"museum-15":{width:42,height:42,x:634,y:394,pixelRatio:2,visible:!0},"music-15":{width:42,height:42,x:676,y:394,pixelRatio:2,visible:!0},"optician-15":{width:42,height:42,x:718,y:394,pixelRatio:2,visible:!0},"park-15":{width:42,height:42,x:760,y:394,pixelRatio:2,visible:!0},"parking-15":{width:42,height:42,x:802,y:394,pixelRatio:2,visible:!0},"parking-garage-15":{width:42,height:42,x:844,y:394,pixelRatio:2,visible:!0},"pharmacy-15":{width:42,height:42,x:886,y:394,pixelRatio:2,visible:!0},"picnic-site-15":{width:42,height:42,x:928,y:394,pixelRatio:2,visible:!0},"pitch-15":{width:42,height:42,x:970,y:394,pixelRatio:2,visible:!0},"place-of-worship-15":{width:42,height:42,x:510,y:260,pixelRatio:2,visible:!0},"playground-15":{width:42,height:42,x:552,y:260,pixelRatio:2,visible:!0},"police-15":{width:42,height:42,x:594,y:260,pixelRatio:2,visible:!0},"post-15":{width:42,height:42,x:636,y:260,pixelRatio:2,visible:!0},"prison-15":{width:42,height:42,x:678,y:260,pixelRatio:2,visible:!0},"ranger-station-15":{width:42,height:42,x:720,y:260,pixelRatio:2,visible:!0},"religious-buddhist-15":{width:42,height:42,x:762,y:260,pixelRatio:2,visible:!0},"religious-christian-15":{width:42,height:42,x:804,y:260,pixelRatio:2,visible:!0},"religious-jewish-15":{width:42,height:42,x:846,y:260,pixelRatio:2,visible:!0},"religious-muslim-15":{width:42,height:42,x:888,y:260,pixelRatio:2,visible:!0},"restaurant-15":{width:42,height:42,x:930,y:260,pixelRatio:2,visible:!0},"restaurant-noodle-15":{width:42,height:42,x:972,y:260,pixelRatio:2,visible:!0},"restaurant-pizza-15":{width:42,height:42,x:512,y:212,pixelRatio:2,visible:!0},"restaurant-seafood-15":{width:42,height:42,x:554,y:212,pixelRatio:2,visible:!0},"rocket-15":{width:42,height:42,x:596,y:212,pixelRatio:2,visible:!0},"school-15":{width:42,height:42,x:638,y:212,pixelRatio:2,visible:!0},"shoe-15":{width:42,height:42,x:680,y:212,pixelRatio:2,visible:!0},"shop-15":{width:42,height:42,x:722,y:212,pixelRatio:2,visible:!0},"skateboard-15":{width:42,height:42,x:764,y:212,pixelRatio:2,visible:!0},"slipway-15":{width:42,height:42,x:806,y:212,pixelRatio:2,visible:!0},"stadium-15":{width:42,height:42,x:848,y:212,pixelRatio:2,visible:!0},"suitcase-15":{width:42,height:42,x:890,y:212,pixelRatio:2,visible:!0},"swimming-15":{width:42,height:42,x:932,y:212,pixelRatio:2,visible:!0},"table-tennis-15":{width:42,height:42,x:974,y:212,pixelRatio:2,visible:!0},"tennis-15":{width:42,height:42,x:500,y:128,pixelRatio:2,visible:!0},"theatre-15":{width:42,height:42,x:542,y:128,pixelRatio:2,visible:!0},"toilet-15":{width:42,height:42,x:584,y:128,pixelRatio:2,visible:!0},"town-hall-15":{width:42,height:42,x:626,y:128,pixelRatio:2,visible:!0},"veterinary-15":{width:42,height:42,x:668,y:128,pixelRatio:2,visible:!0},"viewpoint-15":{width:42,height:42,x:710,y:128,pixelRatio:2,visible:!0},"volcano-15":{width:42,height:42,x:752,y:128,pixelRatio:2,visible:!0},"volleyball-15":{width:42,height:42,x:794,y:128,pixelRatio:2,visible:!0},"watch-15":{width:42,height:42,x:836,y:128,pixelRatio:2,visible:!0},"waterfall-15":{width:42,height:42,x:878,y:128,pixelRatio:2,visible:!0},"watermill-15":{width:42,height:42,x:920,y:128,pixelRatio:2,visible:!0},"windmill-15":{width:42,height:42,x:962,y:128,pixelRatio:2,visible:!0},"zoo-15":{width:42,height:42,x:492,y:0,pixelRatio:2,visible:!0},"au-national-highway-2":{width:40,height:40,x:534,y:0,pixelRatio:2,visible:!0},"au-national-highway-3":{width:52,height:40,x:574,y:0,pixelRatio:2,visible:!0},"au-national-route-2":{width:40,height:40,x:626,y:0,pixelRatio:2,visible:!0},"au-national-route-3":{width:52,height:40,x:666,y:0,pixelRatio:2,visible:!0},"au-national-route-4":{width:64,height:40,x:718,y:0,pixelRatio:2,visible:!0},"au-national-route-5":{width:76,height:40,x:782,y:0,pixelRatio:2,visible:!0},"au-national-route-6":{width:86,height:40,x:858,y:0,pixelRatio:2,visible:!0},"au-state-2":{width:36,height:40,x:944,y:0,pixelRatio:2,visible:!0},"au-state-3":{width:46,height:40,x:0,y:480,pixelRatio:2,visible:!0},"au-state-4":{width:58,height:40,x:46,y:480,pixelRatio:2,visible:!0},"au-state-5":{width:68,height:40,x:104,y:480,pixelRatio:2,visible:!0},"au-state-6":{width:78,height:40,x:172,y:480,pixelRatio:2,visible:!0},"br-state-2":{width:40,height:40,x:250,y:480,pixelRatio:2,visible:!0},"br-state-3":{width:56,height:40,x:290,y:480,pixelRatio:2,visible:!0},"circle-white-2":{width:40,height:40,x:346,y:480,pixelRatio:2,visible:!0},"circle-white-3":{width:52,height:40,x:386,y:480,pixelRatio:2,visible:!0},"circle-white-4":{width:64,height:40,x:438,y:480,pixelRatio:2,visible:!0},"hu-main-2":{width:40,height:40,x:502,y:480,pixelRatio:2,visible:!0},"hu-main-3":{width:52,height:40,x:542,y:480,pixelRatio:2,visible:!0},"hu-main-4":{width:64,height:40,x:594,y:480,pixelRatio:2,visible:!0},"hu-main-5":{width:76,height:40,x:658,y:480,pixelRatio:2,visible:!0},"hu-motorway-2":{width:40,height:40,x:734,y:480,pixelRatio:2,visible:!0},"hu-motorway-3":{width:52,height:40,x:774,y:480,pixelRatio:2,visible:!0},"marker-15":{width:24,height:40,x:826,y:480,pixelRatio:2,visible:!0},"nz-state-2":{width:36,height:40,x:850,y:480,pixelRatio:2,visible:!0},"nz-state-3":{width:46,height:40,x:886,y:480,pixelRatio:2,visible:!0},"ro-communal-2":{width:40,height:40,x:932,y:480,pixelRatio:2,visible:!0},"ro-communal-3":{width:52,height:40,x:972,y:480,pixelRatio:2,visible:!0},"ro-communal-4":{width:64,height:40,x:0,y:520,pixelRatio:2,visible:!0},"ro-county-3":{width:52,height:40,x:64,y:520,pixelRatio:2,visible:!0},"ro-county-4":{width:64,height:40,x:116,y:520,pixelRatio:2,visible:!0},"ro-national-2":{width:40,height:40,x:180,y:520,pixelRatio:2,visible:!0},"ro-national-3":{width:52,height:40,x:220,y:520,pixelRatio:2,visible:!0},"tw-county-township-2":{width:40,height:40,x:272,y:520,pixelRatio:2,visible:!0},"tw-county-township-3":{width:52,height:40,x:312,y:520,pixelRatio:2,visible:!0},"tw-county-township-4":{width:64,height:40,x:364,y:520,pixelRatio:2,visible:!0},"tw-county-township-5":{width:76,height:40,x:428,y:520,pixelRatio:2,visible:!0},"tw-county-township-6":{width:88,height:40,x:504,y:520,pixelRatio:2,visible:!0},"us-bia-2":{width:40,height:40,x:592,y:520,pixelRatio:2,visible:!0},"us-bia-3":{width:52,height:40,x:632,y:520,pixelRatio:2,visible:!0},"us-bia-4":{width:60,height:40,x:684,y:520,pixelRatio:2,visible:!0},"us-highway-2":{width:40,height:40,x:744,y:520,pixelRatio:2,visible:!0},"us-highway-3":{width:52,height:40,x:784,y:520,pixelRatio:2,visible:!0},"us-highway-4":{width:64,height:40,x:836,y:520,pixelRatio:2,visible:!0},"us-highway-alternate-2":{width:40,height:40,x:900,y:520,pixelRatio:2,visible:!0},"us-highway-alternate-3":{width:52,height:40,x:940,y:520,pixelRatio:2,visible:!0},"us-highway-duplex-3":{width:52,height:40,x:0,y:560,pixelRatio:2,visible:!0},"us-highway-duplex-4":{width:64,height:40,x:52,y:560,pixelRatio:2,visible:!0},"us-highway-duplex-5":{width:76,height:40,x:116,y:560,pixelRatio:2,visible:!0},"za-national-2":{width:40,height:40,x:192,y:560,pixelRatio:2,visible:!0},"za-national-3":{width:56,height:40,x:232,y:560,pixelRatio:2,visible:!0},"barcelona-metro":{width:38,height:38,x:288,y:560,pixelRatio:2,visible:!0},"boston-t":{width:38,height:38,x:326,y:560,pixelRatio:2,visible:!0},"de-s-bahn":{width:38,height:38,x:364,y:560,pixelRatio:2,visible:!0},"de-s-bahn.de-u-bahn":{width:70,height:38,x:402,y:560,pixelRatio:2,visible:!0},"delhi-metro":{width:38,height:38,x:472,y:560,pixelRatio:2,visible:!0},"kiev-metro":{width:38,height:38,x:510,y:560,pixelRatio:2,visible:!0},"kr-metro-expy-2":{width:40,height:38,x:548,y:560,pixelRatio:2,visible:!0},"kr-metro-expy-3":{width:52,height:38,x:588,y:560,pixelRatio:2,visible:!0},"kr-metro-expy-4":{width:64,height:38,x:640,y:560,pixelRatio:2,visible:!0},"madrid-metro":{width:38,height:38,x:704,y:560,pixelRatio:2,visible:!0},"new-york-subway":{width:38,height:38,x:742,y:560,pixelRatio:2,visible:!0},"oslo-metro":{width:38,height:38,x:780,y:560,pixelRatio:2,visible:!0},"paris-metro":{width:38,height:38,x:818,y:560,pixelRatio:2,visible:!0},"paris-metro.paris-rer":{width:74,height:38,x:856,y:560,pixelRatio:2,visible:!0},"paris-rer":{width:38,height:38,x:930,y:560,pixelRatio:2,visible:!0},"paris-rer.paris-transilien":{width:70,height:38,x:0,y:600,pixelRatio:2,visible:!0},"road-closure":{width:38,height:38,x:70,y:600,pixelRatio:2,visible:!0},"stockholm-metro":{width:38,height:38,x:108,y:600,pixelRatio:2,visible:!0},"taipei-metro":{width:38,height:38,x:146,y:600,pixelRatio:2,visible:!0},"vienna-u-bahn":{width:38,height:38,x:184,y:600,pixelRatio:2,visible:!0},"kr-natl-hwy-2":{width:44,height:36,x:222,y:600,pixelRatio:2,visible:!0},"airfield-11":{width:34,height:34,x:266,y:600,pixelRatio:2,visible:!0},"airport-11":{width:34,height:34,x:300,y:600,pixelRatio:2,visible:!0},"alcohol-shop-11":{width:34,height:34,x:334,y:600,pixelRatio:2,visible:!0},"american-football-11":{width:34,height:34,x:368,y:600,pixelRatio:2,visible:!0},"amusement-park-11":{width:34,height:34,x:402,y:600,pixelRatio:2,visible:!0},"aquarium-11":{width:34,height:34,x:436,y:600,pixelRatio:2,visible:!0},"art-gallery-11":{width:34,height:34,x:470,y:600,pixelRatio:2,visible:!0},"attraction-11":{width:34,height:34,x:504,y:600,pixelRatio:2,visible:!0},"bakery-11":{width:34,height:34,x:538,y:600,pixelRatio:2,visible:!0},"bank-11":{width:34,height:34,x:572,y:600,pixelRatio:2,visible:!0},"bar-11":{width:34,height:34,x:606,y:600,pixelRatio:2,visible:!0},"basketball-11":{width:34,height:34,x:640,y:600,pixelRatio:2,visible:!0},"beach-11":{width:34,height:34,x:674,y:600,pixelRatio:2,visible:!0},"beer-11":{width:34,height:34,x:708,y:600,pixelRatio:2,visible:!0},"bicycle-11":{width:34,height:34,x:742,y:600,pixelRatio:2,visible:!0},"bicycle-share":{width:34,height:34,x:776,y:600,pixelRatio:2,visible:!0},"bowling-alley-11":{width:34,height:34,x:810,y:600,pixelRatio:2,visible:!0},"bridge-11":{width:34,height:34,x:844,y:600,pixelRatio:2,visible:!0},bus:{width:34,height:34,x:878,y:600,pixelRatio:2,visible:!0},"cafe-11":{width:34,height:34,x:912,y:600,pixelRatio:2,visible:!0},"campsite-11":{width:34,height:34,x:946,y:600,pixelRatio:2,visible:!0},"car-11":{width:34,height:34,x:980,y:600,pixelRatio:2,visible:!0},"car-rental-11":{width:34,height:34,x:968,y:560,pixelRatio:2,visible:!0},"car-repair-11":{width:34,height:34,x:980,y:0,pixelRatio:2,visible:!0},"casino-11":{width:34,height:34,x:0,y:638,pixelRatio:2,visible:!0},"castle-11":{width:34,height:34,x:34,y:638,pixelRatio:2,visible:!0},"cemetery-11":{width:34,height:34,x:68,y:638,pixelRatio:2,visible:!0},"charging-station-11":{width:34,height:34,x:102,y:638,pixelRatio:2,visible:!0},"chongqing-rail-transit":{width:50,height:34,x:136,y:638,pixelRatio:2,visible:!0},"cinema-11":{width:34,height:34,x:186,y:638,pixelRatio:2,visible:!0},"clothing-store-11":{width:34,height:34,x:220,y:638,pixelRatio:2,visible:!0},"college-11":{width:34,height:34,x:254,y:638,pixelRatio:2,visible:!0},"communications-tower-11":{width:34,height:34,x:288,y:638,pixelRatio:2,visible:!0},"confectionery-11":{width:34,height:34,x:322,y:638,pixelRatio:2,visible:!0},"convenience-11":{width:34,height:34,x:356,y:638,pixelRatio:2,visible:!0},"de-u-bahn":{width:34,height:34,x:390,y:638,pixelRatio:2,visible:!0},"dentist-11":{width:34,height:34,x:424,y:638,pixelRatio:2,visible:!0},"doctor-11":{width:34,height:34,x:458,y:638,pixelRatio:2,visible:!0},"dog-park-11":{width:34,height:34,x:492,y:638,pixelRatio:2,visible:!0},"drinking-water-11":{width:34,height:34,x:526,y:638,pixelRatio:2,visible:!0},"embassy-11":{width:34,height:34,x:560,y:638,pixelRatio:2,visible:!0},entrance:{width:34,height:34,x:594,y:638,pixelRatio:2,visible:!0},"farm-11":{width:34,height:34,x:628,y:638,pixelRatio:2,visible:!0},"fast-food-11":{width:34,height:34,x:662,y:638,pixelRatio:2,visible:!0},ferry:{width:34,height:34,x:696,y:638,pixelRatio:2,visible:!0},"fire-station-11":{width:34,height:34,x:730,y:638,pixelRatio:2,visible:!0},"fitness-centre-11":{width:34,height:34,x:764,y:638,pixelRatio:2,visible:!0},"fuel-11":{width:34,height:34,x:798,y:638,pixelRatio:2,visible:!0},"furniture-11":{width:34,height:34,x:832,y:638,pixelRatio:2,visible:!0},"garden-11":{width:34,height:34,x:866,y:638,pixelRatio:2,visible:!0},"globe-11":{width:34,height:34,x:900,y:638,pixelRatio:2,visible:!0},"golf-11":{width:34,height:34,x:934,y:638,pixelRatio:2,visible:!0},"grocery-11":{width:34,height:34,x:968,y:638,pixelRatio:2,visible:!0},"harbor-11":{width:34,height:34,x:0,y:672,pixelRatio:2,visible:!0},"hardware-11":{width:34,height:34,x:34,y:672,pixelRatio:2,visible:!0},"heliport-11":{width:34,height:34,x:68,y:672,pixelRatio:2,visible:!0},"hong-kong-mtr":{width:38,height:34,x:102,y:672,pixelRatio:2,visible:!0},"horse-riding-11":{width:34,height:34,x:140,y:672,pixelRatio:2,visible:!0},"hospital-11":{width:34,height:34,x:174,y:672,pixelRatio:2,visible:!0},"ice-cream-11":{width:34,height:34,x:208,y:672,pixelRatio:2,visible:!0},"information-11":{width:34,height:34,x:242,y:672,pixelRatio:2,visible:!0},"jewelry-store-11":{width:34,height:34,x:276,y:672,pixelRatio:2,visible:!0},"laundry-11":{width:34,height:34,x:310,y:672,pixelRatio:2,visible:!0},"library-11":{width:34,height:34,x:344,y:672,pixelRatio:2,visible:!0},"lodging-11":{width:34,height:34,x:378,y:672,pixelRatio:2,visible:!0},"marker-11":{width:24,height:34,x:412,y:672,pixelRatio:2,visible:!0},"mexico-city-metro":{width:34,height:34,x:436,y:672,pixelRatio:2,visible:!0},"milan-metro":{width:34,height:34,x:470,y:672,pixelRatio:2,visible:!0},"mobile-phone-11":{width:34,height:34,x:504,y:672,pixelRatio:2,visible:!0},"monument-11":{width:34,height:34,x:538,y:672,pixelRatio:2,visible:!0},"moscow-metro":{width:34,height:34,x:572,y:672,pixelRatio:2,visible:!0},"mountain-11":{width:34,height:34,x:606,y:672,pixelRatio:2,visible:!0},"museum-11":{width:34,height:34,x:640,y:672,pixelRatio:2,visible:!0},"music-11":{width:34,height:34,x:674,y:672,pixelRatio:2,visible:!0},"optician-11":{width:34,height:34,x:708,y:672,pixelRatio:2,visible:!0},"osaka-subway":{width:40,height:34,x:742,y:672,pixelRatio:2,visible:!0},"paris-transilien":{width:34,height:34,x:782,y:672,pixelRatio:2,visible:!0},"park-11":{width:34,height:34,x:816,y:672,pixelRatio:2,visible:!0},"parking-11":{width:34,height:34,x:850,y:672,pixelRatio:2,visible:!0},"parking-garage-11":{width:34,height:34,x:884,y:672,pixelRatio:2,visible:!0},"pharmacy-11":{width:34,height:34,x:918,y:672,pixelRatio:2,visible:!0},"philadelphia-septa":{width:38,height:34,x:952,y:672,pixelRatio:2,visible:!0},"picnic-site-11":{width:34,height:34,x:990,y:672,pixelRatio:2,visible:!0},"pitch-11":{width:34,height:34,x:0,y:706,pixelRatio:2,visible:!0},"place-of-worship-11":{width:34,height:34,x:34,y:706,pixelRatio:2,visible:!0},"playground-11":{width:34,height:34,x:68,y:706,pixelRatio:2,visible:!0},"police-11":{width:34,height:34,x:102,y:706,pixelRatio:2,visible:!0},"post-11":{width:34,height:34,x:136,y:706,pixelRatio:2,visible:!0},"prison-11":{width:34,height:34,x:170,y:706,pixelRatio:2,visible:!0},rail:{width:34,height:34,x:204,y:706,pixelRatio:2,visible:!0},"rail-light":{width:34,height:34,x:238,y:706,pixelRatio:2,visible:!0},"rail-metro":{width:34,height:34,x:272,y:706,pixelRatio:2,visible:!0},"ranger-station-11":{width:34,height:34,x:306,y:706,pixelRatio:2,visible:!0},"religious-buddhist-11":{width:34,height:34,x:340,y:706,pixelRatio:2,visible:!0},"religious-christian-11":{width:34,height:34,x:374,y:706,pixelRatio:2,visible:!0},"religious-jewish-11":{width:34,height:34,x:408,y:706,pixelRatio:2,visible:!0},"religious-muslim-11":{width:34,height:34,x:442,y:706,pixelRatio:2,visible:!0},"restaurant-11":{width:34,height:34,x:476,y:706,pixelRatio:2,visible:!0},"restaurant-noodle-11":{width:34,height:34,x:510,y:706,pixelRatio:2,visible:!0},"restaurant-pizza-11":{width:34,height:34,x:544,y:706,pixelRatio:2,visible:!0},"restaurant-seafood-11":{width:34,height:34,x:578,y:706,pixelRatio:2,visible:!0},"rocket-11":{width:34,height:34,x:612,y:706,pixelRatio:2,visible:!0},"san-francisco-bart":{width:34,height:34,x:646,y:706,pixelRatio:2,visible:!0},"school-11":{width:34,height:34,x:680,y:706,pixelRatio:2,visible:!0},"shoe-11":{width:34,height:34,x:714,y:706,pixelRatio:2,visible:!0},"shop-11":{width:34,height:34,x:748,y:706,pixelRatio:2,visible:!0},"singapore-mrt":{width:34,height:34,x:782,y:706,pixelRatio:2,visible:!0},"skateboard-11":{width:34,height:34,x:816,y:706,pixelRatio:2,visible:!0},"slipway-11":{width:34,height:34,x:850,y:706,pixelRatio:2,visible:!0},"stadium-11":{width:34,height:34,x:884,y:706,pixelRatio:2,visible:!0},"suitcase-11":{width:34,height:34,x:918,y:706,pixelRatio:2,visible:!0},"swimming-11":{width:34,height:34,x:952,y:706,pixelRatio:2,visible:!0},"table-tennis-11":{width:34,height:34,x:986,y:706,pixelRatio:2,visible:!0},"tennis-11":{width:34,height:34,x:0,y:740,pixelRatio:2,visible:!0},"theatre-11":{width:34,height:34,x:34,y:740,pixelRatio:2,visible:!0},"toilet-11":{width:34,height:34,x:68,y:740,pixelRatio:2,visible:!0},"tokyo-metro":{width:34,height:34,x:102,y:740,pixelRatio:2,visible:!0},"town-hall-11":{width:34,height:34,x:136,y:740,pixelRatio:2,visible:!0},"traffic-signal":{width:16,height:34,x:1002,y:638,pixelRatio:2,visible:!0},"veterinary-11":{width:34,height:34,x:170,y:740,pixelRatio:2,visible:!0},"viewpoint-11":{width:34,height:34,x:204,y:740,pixelRatio:2,visible:!0},"volcano-11":{width:34,height:34,x:238,y:740,pixelRatio:2,visible:!0},"volleyball-11":{width:34,height:34,x:272,y:740,pixelRatio:2,visible:!0},"washington-metro":{width:34,height:34,x:306,y:740,pixelRatio:2,visible:!0},"watch-11":{width:34,height:34,x:340,y:740,pixelRatio:2,visible:!0},"waterfall-11":{width:34,height:34,x:374,y:740,pixelRatio:2,visible:!0},"watermill-11":{width:34,height:34,x:408,y:740,pixelRatio:2,visible:!0},"windmill-11":{width:34,height:34,x:442,y:740,pixelRatio:2,visible:!0},"zoo-11":{width:34,height:34,x:476,y:740,pixelRatio:2,visible:!0},"ch-motorway-2":{width:44,height:32,x:510,y:740,pixelRatio:2,visible:!0},"ch-motorway-3":{width:56,height:32,x:554,y:740,pixelRatio:2,visible:!0},"de-motorway-2":{width:44,height:32,x:610,y:740,pixelRatio:2,visible:!0},"de-motorway-3":{width:56,height:32,x:654,y:740,pixelRatio:2,visible:!0},"gb-national-rail.london-dlr":{width:72,height:32,x:710,y:740,pixelRatio:2,visible:!0},"gb-national-rail.london-dlr.london-overground.london-tfl-rail.london-underground":{width:186,height:32,x:782,y:740,pixelRatio:2,visible:!0},"gb-national-rail.london-dlr.london-overground.london-underground":{width:148,height:32,x:0,y:774,pixelRatio:2,visible:!0},"gb-national-rail.london-dlr.london-underground":{width:110,height:32,x:148,y:774,pixelRatio:2,visible:!0},"gb-national-rail.london-overground":{width:72,height:32,x:258,y:774,pixelRatio:2,visible:!0},"gb-national-rail.london-overground.london-tfl-rail.london-underground":{width:148,height:32,x:330,y:774,pixelRatio:2,visible:!0},"gb-national-rail.london-overground.london-underground":{width:110,height:32,x:478,y:774,pixelRatio:2,visible:!0},"gb-national-rail.london-tfl-rail":{width:72,height:32,x:588,y:774,pixelRatio:2,visible:!0},"gb-national-rail.london-tfl-rail.london-overground":{width:110,height:32,x:660,y:774,pixelRatio:2,visible:!0},"gb-national-rail.london-tfl-rail.london-underground":{width:110,height:32,x:770,y:774,pixelRatio:2,visible:!0},"gb-national-rail.london-underground":{width:72,height:32,x:880,y:774,pixelRatio:2,visible:!0},"gr-motorway-2":{width:44,height:32,x:952,y:774,pixelRatio:2,visible:!0},"gr-motorway-3":{width:56,height:32,x:968,y:740,pixelRatio:2,visible:!0},"gr-motorway-4":{width:68,height:32,x:0,y:806,pixelRatio:2,visible:!0},"hr-motorway-3":{width:56,height:32,x:68,y:806,pixelRatio:2,visible:!0},"hr-motorway-4":{width:68,height:32,x:124,y:806,pixelRatio:2,visible:!0},"kr-metropolitan-2":{width:40,height:32,x:192,y:806,pixelRatio:2,visible:!0},"kr-metropolitan-3":{width:52,height:32,x:232,y:806,pixelRatio:2,visible:!0},"kr-metropolitan-4":{width:64,height:32,x:284,y:806,pixelRatio:2,visible:!0},"kr-metropolitan-5":{width:76,height:32,x:348,y:806,pixelRatio:2,visible:!0},"kr-metropolitan-6":{width:88,height:32,x:424,y:806,pixelRatio:2,visible:!0},"london-dlr":{width:40,height:32,x:512,y:806,pixelRatio:2,visible:!0},"london-dlr.london-tfl-rail":{width:78,height:32,x:552,y:806,pixelRatio:2,visible:!0},"london-dlr.london-tfl-rail.london-underground":{width:116,height:32,x:630,y:806,pixelRatio:2,visible:!0},"london-dlr.london-underground":{width:78,height:32,x:746,y:806,pixelRatio:2,visible:!0},"london-overground":{width:40,height:32,x:824,y:806,pixelRatio:2,visible:!0},"london-overground.london-tfl-rail":{width:78,height:32,x:864,y:806,pixelRatio:2,visible:!0},"london-overground.london-tfl-rail.london-underground":{width:116,height:32,x:0,y:838,pixelRatio:2,visible:!0},"london-overground.london-underground":{width:78,height:32,x:942,y:806,pixelRatio:2,visible:!0},"london-tfl-rail":{width:40,height:32,x:116,y:838,pixelRatio:2,visible:!0},"london-tfl-rail.london-underground":{width:78,height:32,x:156,y:838,pixelRatio:2,visible:!0},"london-underground":{width:40,height:32,x:234,y:838,pixelRatio:2,visible:!0},"si-motorway-2":{width:44,height:32,x:274,y:838,pixelRatio:2,visible:!0},wetland:{width:32,height:32,x:318,y:838,pixelRatio:2,visible:!0},"level-crossing":{width:30,height:30,x:350,y:838,pixelRatio:2,visible:!0},"default-2":{width:40,height:28,x:380,y:838,pixelRatio:2,visible:!0},"default-3":{width:52,height:28,x:420,y:838,pixelRatio:2,visible:!0},"default-4":{width:64,height:28,x:472,y:838,pixelRatio:2,visible:!0},"default-5":{width:76,height:28,x:536,y:838,pixelRatio:2,visible:!0},"default-6":{width:88,height:28,x:612,y:838,pixelRatio:2,visible:!0},"gb-national-rail":{width:34,height:28,x:700,y:838,pixelRatio:2,visible:!0},"motorway-exit-1":{width:40,height:28,x:734,y:838,pixelRatio:2,visible:!0},"motorway-exit-2":{width:40,height:28,x:774,y:838,pixelRatio:2,visible:!0},"motorway-exit-3":{width:52,height:28,x:814,y:838,pixelRatio:2,visible:!0},"motorway-exit-4":{width:64,height:28,x:866,y:838,pixelRatio:2,visible:!0},"motorway-exit-5":{width:76,height:28,x:930,y:838,pixelRatio:2,visible:!0},"motorway-exit-6":{width:88,height:28,x:0,y:870,pixelRatio:2,visible:!0},"motorway-exit-7":{width:100,height:28,x:88,y:870,pixelRatio:2,visible:!0},"motorway-exit-8":{width:112,height:28,x:188,y:870,pixelRatio:2,visible:!0},"motorway-exit-9":{width:124,height:28,x:300,y:870,pixelRatio:2,visible:!0},"rectangle-blue-2":{width:40,height:28,x:424,y:870,pixelRatio:2,visible:!0},"rectangle-blue-3":{width:52,height:28,x:464,y:870,pixelRatio:2,visible:!0},"rectangle-blue-4":{width:64,height:28,x:516,y:870,pixelRatio:2,visible:!0},"rectangle-green-2":{width:40,height:28,x:580,y:870,pixelRatio:2,visible:!0},"rectangle-green-3":{width:52,height:28,x:620,y:870,pixelRatio:2,visible:!0},"rectangle-green-4":{width:64,height:28,x:672,y:870,pixelRatio:2,visible:!0},"rectangle-green-5":{width:76,height:28,x:736,y:870,pixelRatio:2,visible:!0},"rectangle-green-6":{width:88,height:28,x:812,y:870,pixelRatio:2,visible:!0},"rectangle-red-2":{width:40,height:28,x:900,y:870,pixelRatio:2,visible:!0},"rectangle-red-3":{width:52,height:28,x:940,y:870,pixelRatio:2,visible:!0},"rectangle-red-4":{width:64,height:28,x:0,y:898,pixelRatio:2,visible:!0},"rectangle-white-2":{width:40,height:28,x:64,y:898,pixelRatio:2,visible:!0},"rectangle-white-3":{width:52,height:28,x:104,y:898,pixelRatio:2,visible:!0},"rectangle-white-4":{width:64,height:28,x:156,y:898,pixelRatio:2,visible:!0},"rectangle-white-5":{width:76,height:28,x:220,y:898,pixelRatio:2,visible:!0},"rectangle-white-6":{width:88,height:28,x:296,y:898,pixelRatio:2,visible:!0},"rectangle-yellow-2":{width:40,height:28,x:384,y:898,pixelRatio:2,visible:!0},"rectangle-yellow-3":{width:52,height:28,x:424,y:898,pixelRatio:2,visible:!0},"rectangle-yellow-4":{width:64,height:28,x:476,y:898,pixelRatio:2,visible:!0},"rectangle-yellow-5":{width:76,height:28,x:540,y:898,pixelRatio:2,visible:!0},"rectangle-yellow-6":{width:88,height:28,x:616,y:898,pixelRatio:2,visible:!0},"border-dot-13":{width:26,height:26,x:992,y:870,pixelRatio:2,visible:!0},"dot-10":{width:22,height:22,x:704,y:898,pixelRatio:2,visible:!0},"dot-11":{width:22,height:22,x:726,y:898,pixelRatio:2,visible:!0},"dot-9":{width:22,height:22,x:748,y:898,pixelRatio:2,visible:!0},cliff:{width:16,height:14,x:770,y:898,pixelRatio:2,visible:!0},"oneway-large":{width:28,height:12,x:786,y:898,pixelRatio:2,visible:!0},"oneway-white-large":{width:28,height:12,x:814,y:898,pixelRatio:2,visible:!0},"oneway-small":{width:22,height:10,x:842,y:898,pixelRatio:2,visible:!0},"oneway-white-small":{width:22,height:10,x:864,y:898,pixelRatio:2,visible:!0}},VU:{"Latin-1 Supplement":function(i){return 128<=i&&i<=255},Arabic:function(i){return 1536<=i&&i<=1791},"Arabic Supplement":function(i){return 1872<=i&&i<=1919},"Arabic Extended-A":function(i){return 2208<=i&&i<=2303},"Hangul Jamo":function(i){return 4352<=i&&i<=4607},"Unified Canadian Aboriginal Syllabics":function(i){return 5120<=i&&i<=5759},Khmer:function(i){return 6016<=i&&i<=6143},"Unified Canadian Aboriginal Syllabics Extended":function(i){return 6320<=i&&i<=6399},"General Punctuation":function(i){return 8192<=i&&i<=8303},"Letterlike Symbols":function(i){return 8448<=i&&i<=8527},"Number Forms":function(i){return 8528<=i&&i<=8591},"Miscellaneous Technical":function(i){return 8960<=i&&i<=9215},"Control Pictures":function(i){return 9216<=i&&i<=9279},"Optical Character Recognition":function(i){return 9280<=i&&i<=9311},"Enclosed Alphanumerics":function(i){return 9312<=i&&i<=9471},"Geometric Shapes":function(i){return 9632<=i&&i<=9727},"Miscellaneous Symbols":function(i){return 9728<=i&&i<=9983},"Miscellaneous Symbols and Arrows":function(i){return 11008<=i&&i<=11263},"CJK Radicals Supplement":function(i){return 11904<=i&&i<=12031},"Kangxi Radicals":function(i){return 12032<=i&&i<=12255},"Ideographic Description Characters":function(i){return 12272<=i&&i<=12287},"CJK Symbols and Punctuation":function(i){return 12288<=i&&i<=12351},Hiragana:function(i){return 12352<=i&&i<=12447},Katakana:function(i){return 12448<=i&&i<=12543},Bopomofo:function(i){return 12544<=i&&i<=12591},"Hangul Compatibility Jamo":function(i){return 12592<=i&&i<=12687},Kanbun:function(i){return 12688<=i&&i<=12703},"Bopomofo Extended":function(i){return 12704<=i&&i<=12735},"CJK Strokes":function(i){return 12736<=i&&i<=12783},"Katakana Phonetic Extensions":function(i){return 12784<=i&&i<=12799},"Enclosed CJK Letters and Months":function(i){return 12800<=i&&i<=13055},"CJK Compatibility":function(i){return 13056<=i&&i<=13311},"CJK Unified Ideographs Extension A":function(i){return 13312<=i&&i<=19903},"Yijing Hexagram Symbols":function(i){return 19904<=i&&i<=19967},"CJK Unified Ideographs":function(i){return 19968<=i&&i<=40959},"Yi Syllables":function(i){return 40960<=i&&i<=42127},"Yi Radicals":function(i){return 42128<=i&&i<=42191},"Hangul Jamo Extended-A":function(i){return 43360<=i&&i<=43391},"Hangul Syllables":function(i){return 44032<=i&&i<=55215},"Hangul Jamo Extended-B":function(i){return 55216<=i&&i<=55295},"Private Use Area":function(i){return 57344<=i&&i<=63743},"CJK Compatibility Ideographs":function(i){return 63744<=i&&i<=64255},"Arabic Presentation Forms-A":function(i){return 64336<=i&&i<=65023},"Vertical Forms":function(i){return 65040<=i&&i<=65055},"CJK Compatibility Forms":function(i){return 65072<=i&&i<=65103},"Small Form Variants":function(i){return 65104<=i&&i<=65135},"Arabic Presentation Forms-B":function(i){return 65136<=i&&i<=65279},"Halfwidth and Fullwidth Forms":function(i){return 65280<=i&&i<=65519}},layers:[],styles:{},Mr:!0,Rr:function(i,t){var l,n=this;if(!i)return!1;l=i,this.styles.zr=[];for(var a=this,e=0,o=l.length;e<o;e+=1)!function(i){var o,h,e,r=l[i],t=(r.zIndex=i,"line"===r.type&&(r.paint["line-width"]=void 0===r.paint["line-width"]?1:r.paint["line-width"]),r.paint["line-width"]&&(i=r.paint["line-width"],t=0,r.paint["line-gap-width"]&&(t=r.paint["line-gap-width"]),o=i,h=t,a.styles.zr.push(i=function(i,t){var e=0;return h&&(e=n.HU(t,h,i)),t=n.HU(t,o,i),e?2*t+e:t}),r.paint["line-width"]=i,r.paint["line-width"].Cr=a.styles.zr.length-1,delete r.paint["line-gap-width"]),r["source-layer"]);t?(a.styles[t]||(a.styles[t]=[]),(i=r.filter)&&(r.filters=[],(e=function(i){if("all"!==i[0])"in"===i[0]||"!in"===i[0]?r.filters.push([i[0],i[1],i.slice(2)]):r.filters.push(i);else for(var t=1;t<i.length;t+=1)e(i[t])})(i)),a.styles[t].push(r)):a.styles[r.id]=r}(e);this.backgroundColor=this.HU({},this.styles.land.paint["background-color"],12)},Ar:function(i,t,e,o){return i-=e,0==(o-=e)?0:1===t?i/o:(Math.pow(t,i)-1)/(Math.pow(t,o)-1)},Sr:function(i,t,e){var o=t.base||1,h=t.stops;if(e<=h[0][0])return this.HU(i,h[0][1],e);if(e>=h[h.length-1][0])return this.HU(i,h[h.length-1][1],e);for(var r=1,n=h.length;r<n;r+=1)if(e>h[r-1][0]&&e<=h[r][0]){var l=this.HU(i,h[r-1][1],e),a=this.HU(i,h[r][1],e);if(l instanceof Array){for(var s=new Array(l.length),f=0;f<l.length;f+=1){var u=a[f]-l[f];s[f]=l[f]+this.Ar(e,o,h[r-1][0])*u}return s}return"number"==typeof l?(u=a-l,l+this.Ar(e,o,h[r-1][0],h[r][0])*u):l}},Lr:function(i,t){if(i){var e=void 0;if("string"==typeof i)e=i;else if(i.stops)for(var o=0,h=i.stops.length;o<h;o+=1){if(i.stops[o][0]>t){e=i.stops[o][1];break}e=i.stops[h-1][1]}else if("interpolate"===i[0]){for(var r=i.slice(3),n=[],l=0;l<r.length;l+=2)n.push([r[l],r[l+1]]);for(o=0,h=n.length;o<h;o+=1){if(n[o][0]>t){e=n[o][1];break}e=n[h-1][1]}}return e}},Tr:function(i,t){if(i){var e=void 0;if(i.stops)for(var o=0,h=i.stops.length;o<h;o+=1){if(i.stops[o][0]>t){e=i.stops[o][1];break}e=i.stops[h-1][1]}else e=i;return e}},Ir:function(i,t){var e;if(void 0===i)return 0;if("function"==typeof i)return i(t);if("number"!=typeof i){if(i.stops)e=this.Sr(i.base||1,i.stops,t);else if("interpolate"===i[0]){for(var o=i.slice(3),h=[],r=0;r<o.length;r+=2)h.push([o[r],o[r+1]]);e=this.Sr(1,h,t)}}else e=i;return e},Dr:function(i,t,e,o){var h;if(void 0===t)return t;t instanceof Array?h=t:t.stops&&(h=this.Sr(i,t,e));var r=new Array(h.length);return h.forEach(function(i,t){r[t]=i*o}),r},Pr:function(i,t,e){for(var o,h,r,n,l,a,s,f,u,p,d,x,y,c="butt",v="butt",g="solid",w="solid",b=0,R=0,m=0;m<i.length;m+=1)"line"!==i[m].type||void 0!==(h=i[m]).minzoom&&h.minzoom>t||void 0!==h.maxzoom&&h.maxzoom<t||(o=h.paint,h=h.layout,void 0===(r=o["line-opacity"])&&(r=1),(r=this.HU(e,r,t))&&(this.WU(i[m].id,"-low")?(n=r,i[m].id,y=o["line-color"],l=this.HU(e,y,t),c=this.HU(e,h["line-cap"]||c,t),a=this.HU(e,o["line-width"],t),s=o["line-width"].Cr,this.Dr(e,o["line-dasharray"],t,a)&&(g="dashed"),R=Math.max(R,i[m].zIndex)):this.WU(i[m].id,"-case")||this.WU(i[m].id,"-tracks")?(f=!0,i[m].id,u=r,y=o["line-color"],p=this.HU(e,y,t),d=this.HU(e,o["line-width"],t),x=o["line-width"].Cr,v=this.HU(e,h["line-cap"]||v,t),this.Dr(e,o["line-dasharray"],t,d)&&(w="dashed"),b=Math.max(b,i[m].zIndex)):this.WU(i[m].id,"-bg")?(f=!0,i[m].id,u=r,y=o["line-color"],p=this.HU(e,y,t),v=this.HU(e,h["line-cap"]||v,t),d=this.HU(e,o["line-width"],t),x=o["line-width"].Cr,this.Dr(e,o["line-dasharray"],t,d)&&(w="dashed"),b=Math.max(b,i[m].zIndex)):(n=r,i[m].id,y=o["line-color"],l=this.HU(e,y,t),c=this.HU(e,h["line-cap"]||c,t),a=this.HU(e,o["line-width"],t),s=o["line-width"].Cr,this.Dr(e,o["line-dasharray"],t,a)&&(g="dashed"),R=Math.max(R,i[m].zIndex))));if(a)return{facezIndex:R,borderzIndex:b,faceStrokeStyle:g,faceOpacity:n,faceDashArray:void 0,faceWidth:a,faceColor:l,faceLineCap:c,borderLineCap:v,isOutline:f,borderOpacity:u,borderStrokeStyle:w,borderDashArray:void 0,borderColor:p,borderWidth:d,faceWidthFunIndex:s,borderWidthFunIndex:x}},QU:function(i){return i instanceof Array&&-1<this.KU(["geometry-type","to-number","case","step","is-supported-script","concat","get","literal","match","interpolate","to-string","string","coalesce","has","+","==","!=",">","<",">=","<=","in","!in"],i[0])||"object"==typeof i&&i.stops},KU:function(i,t){if(i&&i.length){if(i.indexOf)return i.indexOf(t);for(var e=0;e<i.length;e+=1)if(i[e]===t)return e}return-1},WU:function(i,t){return i.endsWith?i.endsWith(t):!(i.length<t.length)&&i.substr(i.length-t.length)===t},Vr:function(i,t,e){for(var o=0,h=0;h<i.length;h+=1){var r,n,l,a,s,f,u=i[h];"line"===i[h].type?u.minzoom&&u.minzoom>t||(o=Math.max(o,u.zIndex),s=(a=u.paint)["line-color"],r=this.HU(e,s,t),n=this.HU(e,a["line-width"],t),s=void 0===a["line-opacity"]?1:a["line-opacity"],l=this.HU(e,s,t)):"fill"!==i[h].type||u.minzoom&&u.minzoom>t||(o=Math.max(o,u.zIndex),s=(a=u.paint)["fill-color"],f=this.HU(e,s,t))}return{zIndex:o,fillColor:f,fillOpacity:1,strokeWeight:n,strokeColor:r,strokeOpacity:l}},Xr:function(i,t,e){var o,h,r,n,l,a,s,f,u,p,d,x,y=(i=i[0]).paint,c=i.layout;if("symbol"===i.type)return o=this.HU(e,y["text-color"],t),h=this.HU(e,y["text-halo-color"],t),a=this.HU(e,y["text-halo-width"],t),r=void 0===y["icon-opacity"]?1:y["icon-opacity"],r=this.HU(e,r,t),y=void 0===y["text-opacity"]?1:y["text-opacity"],y=this.HU(e,y,t),n=l=void 0,0===a&&(h=""),c["icon-image"]&&(l=this.HU(e,c["icon-image"],t),a=this.kr[l])&&r&&(a.height,n=[-a.width/2,-a.height/2,a.width,a.height,a.x,a.y,a.width,a.height]),a=this.HU(e,c["icon-rotation-alignment"],t),s=c["text-max-width"],f=this.HU(e,c["text-anchor"]||"center",t),(u=this.HU(e,c["text-font"],t)||"Microsoft YaHei")instanceof Array&&(u=u.join(" ")),p=c["text-offset"]?this.HU(e,c["text-offset"],t):[0,0],d=this.HU(e,c["text-size"],t),x="",y&&c["text-field"]&&(x=this.HU(e,c["text-field"]||"{name}",t)),{zIndex:i.zIndex,Jr:a,Kr:o||"black",Qr:h,th:(i.minzoom||1)+.5,ih:(i.maxzoom||20)+.5,eh:r,nh:l,qU:n,oh:s,textAnchor:f,ah:u,sh:p,rh:d,name:x}},lh:function(i,t,e){var o=[],h=this.Pr(i,t,e);return h&&(h.type="line",o.push(h)),(h=this.uh(i,t,e)).length&&o.push.apply(o,h),o},uh:function(i,t,e){for(var o=[],h=0;h<i.length;h+=1){var r=this.Xr([i[h]],t,e);r&&o.push(r)}return o},YU:function(i,t,e){for(var o=1,h=t.length-1;o<h;o+=2)if(this.HU(i,t[o],e))return this.HU(i,t[o+1],e);return this.HU(i,t[t.length-1],e)},JU:function(i,t,e){var o=this.HU(i,t[1],e),h=this.HU(i,t[2],e);return[o,this.HU(i,t[3],e)].join(h)},ZU:function(i,t,e){for(var o=t[1],h=1,r=("exponential"===o[0]?h=o[1]:"linear"===o[0]&&(h=1),t.slice(3)),n=[],l=0;l<r.length;l+=2)n.push([r[l],r[l+1]]);return o=this.Sr(i,{base:h,stops:n},e),this.HU(i,o,e)},XU:function(i,t,e){"zoom"!==t[1][0]&&"get"===t[1][0]&&(e=i.properties[t[1][1]]);for(var o=[],h=2,r=t.length;h<r;h+=2)o.push([parseFloat(t[h-1])||0,this.HU(i,t[h],e)]);if(e<o[0][0])return this.HU(i,o[0][1],e);if(e>=o[o.length-1][0])return this.HU(i,o[o.length-1][1],e);for(h=1,r=o.length;h<r;h+=1)if(e<=o[h][0])return this.HU(i,o[h-1][1],e)},tV:function(i,t,e){var o=this.HU(i,t[1],e);if(o){for(var h=2,r=t.length-1;h<r;h+=2)if(t[h]instanceof Array?-1!==this.KU(t[h],o):t[h]===o)return this.HU(i,t[h+1],e);return this.HU(i,t[t.length-1],e)}},HU:function(i,t,e){if(null==t)return null;var o=typeof t;if("number"==o||"boolean"==o)return t;if("function"==o)return t(e,i);if(!this.QU(t)){if("string"==typeof t&&-1!==this.KU(t,"{")){for(var h,r=[],n=0,l=0,a=t.length;l<a;l+=1)"{"===t[l]&&(n=l),"}"===t[l]&&(h=l,r.push(t.substring(n,h+1)));for(var s,l=0,a=r.length;l<a;l+=1){if(void 0===(s=i.properties[r[l].substring(1,r[l].length-1)]))return"";t=t.replace(r[l],s)}}return t}if("literal"===t[0])return t[1];if(t.stops)return this.Sr(i,t,e);if("get"===t[0])return this.Hr&&"name"===t[1].substr(0,4)&&(i.properties["name_zh-Hant"]||i.properties["name_zh-Hans"])||i.properties[t[1]];if("to-number"===t[0])return parseFloat(this.HU(i,t[1],e));if("to-string"===t[0])return(s=this.HU(i,t[1],e))?s+"":"";if("string"===t[0])return(s=this.HU(i,t[1],e))?s+"":"";if("match"===t[0])return this.tV(i,t,e);if("case"===t[0])return this.YU(i,t,e);if("interpolate"===t[0])return this.ZU(i,t,e);if("concat"===t[0])return this.JU(i,t,e);if("step"===t[0])return this.XU(i,t,e);if("coalesce"!==t[0])return"+"===t[0]?this.HU(i,t[1],e)+this.HU(i,t[2],e):"has"===t[0]?void 0!==i.properties[t[1]]:"is-supported-script"===t[0]?this.iV(this.HU(i,t[1],e)):"=="===t[0]?this.HU(i,t[1],e)===this.HU(i,t[2],e):"!="===t[0]?this.HU(i,t[1],e)!==this.HU(i,t[2],e):">"===t[0]?this.HU(i,t[1],e)>this.HU(i,t[2],e):"<"===t[0]?this.HU(i,t[1],e)<this.HU(i,t[2],e):">="===t[0]?this.HU(i,t[1],e)>=this.HU(i,t[2],e):"<="===t[0]?this.HU(i,t[1],e)<=this.HU(i,t[2],e):"in"===t[0]?-1<this.KU(this.HU(i,t[2],e),this.HU(i,t[1],e)):"!in"===t[0]?-1===this.KU(this.HU(i,t[2],e),this.HU(i,t[1],e)):"geometry-type"===t[0]?3===i.type?"Polygon":2===i.type?"LineString":"Point":void 0;for(l=1;l<t.length;l+=1){var f=this.HU(i,t[l],e);if(f)return f}},eV:function(i,t){return!(!t&&(1424<=i&&i<=2303||this.VU["Arabic Presentation Forms-A"](i)||this.VU["Arabic Presentation Forms-B"](i))||2304<=i&&i<=3583||3840<=i&&i<=4255||this.VU.Khmer(i))},iV:function(i){if(!i)return!1;for(var t=0,e=i.length;t<e;t+=1){var o=i[t];if(!this.eV(o.charCodeAt(0),!1))return!1}return!0},getStyle:function(l,a,i,s){var t,e=l.type,f=(l.properties.class,l.properties.type,this),u=this.styles[a];if(u&&(t=function(){for(var i=[],t=0,e=u.length;t<e;t+=1){var o=u[t];if(o.filters){for(var h=!0,r=0;r<o.filters.length;r+=1){var n=o.filters[r];if(!f.HU(l,n,s)){h=!1;break}}h&&i.push(o)}else o.id===a&&i.push(o)}return i}()).length)return 1===e?this.Xr(t,s,l):2===e?this.lh(t,s,l):3===e?this.Vr(t,s,l):void 0},fh:function(i,t){for(var e=1<<20-t.z,o=i.extent/256,h=0;h<i.style.length;h+=1){var r=i.style[h];if("line"!==r.type){for(var n="",l=(r.hh&&(n=i.properties[r.hh]),this.Mr),a=l?1.8*r.rh:r.rh,s=i.lines[0],f=1;f<i.lines.length;f+=1)s.length<i.lines[f].length&&(s=i.lines[f]);for(var u=[],p=0;p<s.length;p+=1){var d=[t.x*e*256+s[p][0]/o*e,256*t.y*e+s[p][1]/o*e];u.push(d)}var x=r.textAnchor,y=(this._r.font=r.rh+"px "+r.ah,this._r.measureText(n).width),c=0,v=0,g=r.nh&&"viewport"===r.Jr;if(r.nh){var c=(-i.properties.dh||0)-100,b=(w=polyfill.kS._S(u,polyfill.kS.distanceOfLine(u)/2)||[])[2];"viewport"!==r.Jr&&1<u.length&&(v=360-(new polyfill.Pixel(u[b+1][0]-u[b][0],u[b+1][1]-u[b][1]).direction()||0)),u=[w[0],w[1]]}else{if(this.vh(s))continue;if(90<(b=new polyfill.Pixel(s[1][0]-s[0][0],s[1][1]-s[0][1]).direction()||0)&&b<270&&(u.reverse(),s.reverse()),c=-i.properties.dh-1e6,polyfill.kS.distanceOfLine(u)/e<1.5*y)continue}var R,w={margin:this.mh,foreign:!0,zIndex:r.zIndex,yh:v,rank:c,font:r.ah,Kr:r.Kr,Qr:r.Qr,rh:a,id:i.id,xh:u,name:n,textAlign:"center",textBaseline:"center"===x?"middle":"top",bh:[],gh:new Array,wh:g,_h:!g,kh:!r.nh,th:r.th,Mh:!0,Rh:new Array,zh:!1,zoom:t.z};r.nh?(v=0,c=r.nh.replace("{maki}",i.properties.maki).replace("{shield}",i.properties.shield).replace("{reflen}",i.properties.reflen).replace("{network}",i.properties.network),(g=this.kr[c])&&r.eh&&(v=g.height,R=[-g.width/2,-g.height/2,g.width,g.height,g.x,g.y,g.width,g.height],w.gh.push(R)),n&&(c=void 0,g="center"===x?(c=0,-a/2):c=h*(a+2)+v/2,w.Rh.push([n,r.ah,a,r.Kr,r.Qr,0,0,!1,[0,c,l?1.8*y:y,a]]),w.gh.push(R=[-y/2,g,y,a])),(v||n)&&(n?w.id="mapbox_guideboard_"+polyfill.Util.stamp(w):(w.id="mapbox_singleway_"+polyfill.Util.stamp(w),w.zh=!0),t.labels.push(w))):n&&(w.id="mapbox_roadname_"+polyfill.Util.stamp(w),t.labels.push(w))}}},Sh:function(i,t){var e=1<<20-t.z,o=i.extent/256,h=i.Ch.xh[0][0],r=i.properties[i.style.hh];if(r){var n=this.Mr?2*i.style.rh:i.style.rh,e=[t.x*e*256+h[0]/o*e,256*t.y*e+h[1]/o*e],l=i.style.textAnchor,a={foreign:!0,margin:this.mh,zIndex:i.style.zIndex,rank:-i.properties.dh||0,id:i.id,xh:e,name:r,textAlign:"center",textBaseline:"center"===l?"middle":"top",bh:[],gh:new Array,yh:0,pos:[h[0]/o,h[1]/o],wh:!0,th:i.style.th,Mh:!0,Rh:new Array},s=0,f=(i.style.nh&&(e=i.style.nh.replace("{maki}",i.properties.maki).replace("{shield}",i.properties.shield).replace("{reflen}",i.properties.reflen).replace("{network}",i.properties.network),h=this.kr[e])&&i.style.eh&&(s=h.height,y=[-h.width/2,-h.height/2,h.width,h.height,h.x,h.y,h.width,h.height],a.gh=[y]),0<(o=r.indexOf("("))?[r.substr(0,o),r.substr(o)]:20<r.length&&1<(e=r.split(" ")).length?(h=Math.floor(e.length/2),[e.slice(0,h).join(" "),e.slice(h).join(" ")]):[r]);this._r.font=n+"px "+i.style.ah;for(var u=0;u<f.length;u+=1){var p=f[u],d=this._r.measureText(p).width,y=(a.Rh.push([p,i.style.ah,n,i.style.Kr,i.style.Qr,0,0,!1,[0,p="center"===l?(-.5*f.length+u)*(n+2):u*(n+2)+s/2,d,n]]),[-d/2,p,d,n]);a.gh.push(y)}return t.labels.push(a),a}},Lh:function(i){var t,e=[],o=[];for(t in i.layers)if(i.layers.hasOwnProperty(t)){for(var h=i.layers[t],r=[],n=0;n<h.Ah.length;n+=1)3==+(l=h.Ah[n]).type?e.push(l):2==+l.type&&r.push(l);for(n=0;n<r.length;n+=1){var l,a=(l=r[n]).style;a.isOutline&&o.push([l,{zIndex:a.borderzIndex,Th:a.borderWidthFunIndex,strokeStyle:a.borderStrokeStyle,strokeOpacity:a.borderOpacity,strokeDasharray:a.borderDashArray,lineCap:a.borderLineCap,strokeWeight:a.borderWidth,strokeColor:a.borderColor}]),o.push([l,{zIndex:a.facezIndex,Th:a.faceWidthFunIndex,strokeStyle:a.faceStrokeStyle,strokeOpacity:a.faceOpacity,strokeDasharray:a.faceDashArray,lineCap:a.faceLineCap,strokeWeight:a.faceWidth,strokeColor:a.faceColor}])}}o.sort(function(i,t){return i[1].zIndex>t[1].zIndex?1:-1}),i.polygons=e,i.Dh=o,delete i.layers},Ph:function(i){i.type,i.lines},jh:function(i,t,e,o){this.mh=3;var h,r=t.vt,n=(r.labels=[],[]);for(h in r.layers)if(r.layers.hasOwnProperty(h)){var l=r.layers[h],a=l.Ah;n.push(h);for(var s=0,f=a.length;s<f;s++){var u=a[s];u.Fh=l.name,u.style=this.getStyle(u,l.name,!0,r.z-1),u.style,this.Ph(u),u.style&&1!=+u.type&&2==+u.type&&u.style.length&&(this.fh(u,r),"line"===u.style[0].type)&&(u.style=u.style[0])}}this.Lh(r),this.Eh||(this.Eh=!0),e.features=r.labels,r.labels=null,n.length>this.layers.length&&(this.layers=n),o(null,{vt:r})}},MapboxStyle=function(){function i(i){var t=null,e="";i&&((i=i.KG)&&i.styles&&(t=JSON.parse(i.styles).layers),i)&&i.vectorMapForeign&&(e=i.vectorMapForeign),mbStyle.Rr(t,e)}return i.prototype.getMapboxStyle=function(){return mbStyle},i}(),MapboxSourceWorker=function(){function i(i){this.parent=i,this.id="mapbox",this.sQ={},this.yQ={},this.kQ={}}return i.prototype.YE=function(i){var t=polyfill.Util.getOptimalZoom(this.WW);i(this.sQ,{ZL:this.WW,optimalZoom:t,cb:function(){}}),this.sQ={}},i.prototype.bw=function(i,h,r,n,t,e,l){var a=this,s=new XMLHttpRequest;return s.onreadystatechange=function(){var i,t,e,o;4===s.readyState&&200===s.status&&(o=new polyfill.pw(new Uint8Array(s.response)),(o=new polyfill.tW(o)).nG("mapbox"),i=h.z,t=h.x,e=h.y,o.data={},o=a.Ow(o,{x:h.x,y:h.y,z:h.z,projectionId:r,tileSize:n}),a.wQ(o),o.zo=new polyfill.ca(i,t,e),a.FQ(o),delete o.road,l(null,polyfill.Ln({zo:h},o)))},s.open("GET",i,!0),s.responseType="arraybuffer",s.send(),{cancel:function(){s.abort()}}},i.prototype.wQ=function(i){i.stencil={};var t=new polyfill.fQ,i=(i.stencil.Oc=t,i.stencil.Dc=new polyfill.K_,i.stencil.Dc.Nx(i.MQ));t.add({},i)},i.prototype.Ow=function(e,i){var o=i.x,h=i.y,s=i.z,r=i.tileSize,f=i.projectionId;e.z=s,e.x=o,e.y=h;for(var i=polyfill.ProjectionManager.getProjection(f).getResolution(s),i=polyfill.$Q(o,h,s,i,r),n=(e.Ro=i,e.MQ=[i[0],i[1],i[2],i[1],i[2],i[3],i[0],i[3]],e.zS=polyfill.lcs.getLocalByCoord([e.Ro[0],e.Ro[1]]),e.localCoord=e.zS,Object.keys(e.layers)),t=0;t<n.length;t++)!function(i){var a=e.layers[n[i]],i=a.Cw,t=a.extent;a.Ah=[],a.scale=r/t,a.ox=r*o,a.oy=r*h,polyfill.forEach(i,function(i,t){if((i=a.Gw(t)).Dw(),a.Ah.push(i),i.lines&&i.lines.length&&(2===i.type||3===i.type||1===i.type)){i.Rw=[];for(var e=0,o=i.lines.length;e<o;e++){for(var h=[],r=0,n=i.lines[e].length;r<n;r++){var l=[a.ox+a.scale*i.lines[e][r][0],a.oy+a.scale*i.lines[e][r][1]],l=[(l=polyfill.V[f].Xs(l[0],l[1],s))[0],l[1]];h.push(l)}i.Rw.push(h)}}})}(t);return this.uW(e,s),this.xw(e),this.zw(e),e},i.prototype.uW=function(i,t){var e,o=[],h=[],r=[],n=(this.kQ,null);for(e in this.parent&&this.parent.QG&&(n=this.parent.QG),this.$h=new MapboxStyle({KG:n}).getMapboxStyle(),i.bgColor=this.$h.backgroundColor,i.layers)if(i.layers.hasOwnProperty(e))for(var l=i.layers[e],a=0;a<l.Ah.length;a+=1){var s,f=l.Ah[a],u=this.$h.getStyle(f,l.name,!0,t);u&&(f.style=u,3===f.type?o.push(f):2===f.type?h.push(f):1===f.type&&(s=u.name)&&((s={name:s,position:f.Rw[0],id:f.id,minzoom:u.th,maxzoom:u.ih}).style=u,r.push(s)))}h.sort(function(i,t){return i.style&&t.style&&i.style.zIndex>t.style.zIndex?1:-1}),o.sort(function(i,t){return i.style&&t.style&&i.style.zIndex>t.style.zIndex?1:-1}),i.polygons=o,i.Dh=h,i.data.poilabel=((n={})[i.z+","+i.x+","+i.y]=r,n),delete i.layers},i.prototype.startsWith=function(i,t){return i.startsWith?i.startsWith(t):i.substr(0,t.length)===t},i.prototype.argbHex2Rgba=function(i){for(var t=[],e=0,o=i.length;e<o;e+=2)t.push(parseInt(i.substr(e,2),16)/255);return t.push(t.shift()),t},i.prototype.uQ=function(i,t,e){return e<0&&(e+=1),1<e&&--e,e<1/6?i+6*(t-i)*e:e<.5?t:e<2/3?i+(t-i)*(2/3-e)*6:i},i.prototype.GQ=function(i,t,e,o){var h,r,n;return 0===t?h=r=n=e:(h=this.uQ(t=2*e-(e=e<.5?e*(1+t):e+t-e*t),e,i+1/3),r=this.uQ(t,e,i),n=this.uQ(t,e,i-1/3)),[h,r,n,o]},i.prototype.color2RgbaArray=function(i,t){var e,o,h,r,n,l,a;return void 0===t&&(t=1),i?(e=i.toString(),this.yQ[e]||(i instanceof Array?i:this.startsWith(i,"hsla")?(l=i.substr(5).split(","),o=parseInt(l[0],10)/360,h=parseInt(l[1],10)/100,r=parseInt(l[2],10)/100,a=parseFloat(l[3]),n=this.GQ(o,h,r,a),this.yQ[e]=n):this.startsWith(i,"hsl")?(l=i.substr(4).split(","),o=parseInt(l[0],10)/360,h=parseInt(l[1],10)/100,r=parseInt(l[2],10)/100,n=this.GQ(o,h,r,t),this.yQ[e]=n):this.startsWith(i,"#")?7===i.length?(n=this.argbHex2Rgba("ff"+i.substr(1)),this.yQ[e]=n):9===i.length?(n=this.argbHex2Rgba(i.substr(1)),this.yQ[e]=n):void 0:this.startsWith(i,"rgba")?(l=i.substr(5).split(","),[parseInt(l[0],10)/255,parseInt(l[1],10)/255,parseInt(l[2],10)/255,a=parseFloat(l[3])]):this.startsWith(i,"rgb")?(l=i.substr(4).split(","),[parseInt(l[0],10)/255,parseInt(l[1],10)/255,parseInt(l[2],10)/255,a=1]):void 0)):null},i.prototype.zw=function(i){if(!i||!i.Dc){var t=new polyfill.fQ,e=(i.Oc=t,i.Dc=new polyfill.K_,{fillColor:this.color2RgbaArray(i.bgColor),zIndex:0}),o=i.Dc.Nx(i.MQ);t.add(e,o);for(var h=0,r=i.polygons;h<r.length;h++){var n=r[h],l=n.style;if(l&&l.fillColor){l.fillColor=this.color2RgbaArray(l.fillColor);var a=n.Rw;if(1<a.length){for(var s=[],f=0;f<a.length;f++)polyfill.kS.isClockwise(a[f])?s.push([f]):s.length&&s[s.length-1].push(f);for(var u=0;u<s.length;u++){var p=s[u];if(1<p.length){for(var d=[],x=[],y=0;y<p.length;y++){var c=a[p[y]];0<y&&d.push(x.length/2);for(var v=0;v<c.length;v++){var g=c[v];x.push(g[0],g[1])}}var w=i.Dc.Nx(x,d)}else{for(x=[],c=a[p[0]],v=0;v<c.length;v++){var b=c[v];x.push(b[0],b[1])}w=i.Dc.Nx(x)}t.add(l,w)}}else{for(var R=a.length,x=[],m=0;m<R;m++){var k=a[m];if(0<k.length)for(v=0;v<k.length;v++)u=k[v],x.push(u[0],u[1])}n=i.Dc.Nx(x),t.add(l,n)}}}delete i.polygons}},i.prototype.xw=function(i){if(!i||!i.$c){var t=[],e=this.kQ,o=(i.$c=new polyfill.J_,new polyfill.fQ);i.Uc=o;for(var h=0,r=i.Dh;h<r.length;h++){var n=r[h],l=n.Rw,a=l.length,s=0,f=0;n.style&&n.style[0]&&n.style[0].borderColor&&(n.style[0].borderColor=this.color2RgbaArray(n.style[0].borderColor)),n.style&&n.style[0]&&n.style[0].faceColor&&(n.style[0].faceColor=this.color2RgbaArray(n.style[0].faceColor));for(var p=(u=n.style||[])[0],u=u[1],d=0;d<a;d++){var x=l[d];if(0<x.length){for(var y=[],c=0;c<x.length;c++){var v=x[c];y.push(v[0],v[1])}var g=i.$c.hb(y,{X_:0,lineJoin:"miter",lineCap:"round"});s+=g.Iw,f+=g.distance}}if(0<s&&(o.add(n.style,s),n.distance=f),p&&p.borderColor&&(n.style[0].borderColor=this.color2RgbaArray(p.borderColor)),p&&p.faceColor&&(n.style[0].faceColor=this.color2RgbaArray(p.faceColor)),u&&(n=u.name||"")){var p=u.Kr,w=u.Qr;p&&!e[p]&&(e[p]=polyfill.Util.color2RgbaArray(p)),w&&!e[w]&&(e[w]=polyfill.Util.color2RgbaArray(w)),u.Kr=e[p],u.Qr=e[w];for(var b=(p={style:u,path:[],name:n,distance:f}).path,R=0;R<a;R++)for(var m=l[R],c=0;c<m.length;c++)v=m[c],b.push(v[0],v[1]);t.push(p)}}i.road=t,delete i.Dh}},i.prototype.FQ=function(i){var t,e={};for(t in i)i.hasOwnProperty(t)&&"fillBucket"!==t&&"fillSegements"!==t&&"lineBucket"!==t&&"lineSegements"!==t&&(e[t]=i[t]);this.sQ[i.zo.key]={tile:e,params:{scale:this.parent.params.scale,tag:"all"}}},i}(),_a$1,mapBoxSprite="https://webapi.amap.com/style_icon/sprite_v8@2x.png",DefaultIconInfo=(_a$1={TW:{img:"https://vdata.amap.com/style_icon/2.0/icon-normal-big.png",width:512,height:1024,startX:0,startY:0,status:"loaded",type:"icon",ext:{hv:0}},RW:{img:"https://vdata.amap.com/style_icon/2.0/icon-biz-big.png",width:512,height:1024,startX:0,startY:1024,status:"loaded",type:"icon",ext:{hv:1}}},_a$1[mapBoxSprite]={img:mapBoxSprite,width:1024,height:926,startX:0,startY:2048,status:"loaded",type:"icon",ext:{hv:2}},_a$1),ImageManagerWorker=function(e){function i(){var i,t=e.call(this)||this;return t.Fs=((i={})[DefaultIconInfo.TW.img]=DefaultIconInfo.TW,i[DefaultIconInfo.RW.img]=DefaultIconInfo.RW,i),t.Cc=16,t.Uw=3,t.Hw={},t.Mc={},t}return polyfill.Ei(i,e),i.prototype.loadImage=function(i,t){var e=t.name,o=t.type,h=t.cb,r=this.Fs[e=e||i];r&&r.status===polyfill.uc.LOADED?h(r,t):r&&r.status===polyfill.uc.LOADING?(this.Mc[e]||(this.Mc[e]=[]),this.Mc[e].push({cb:h,opts:t})):("icon"===o&&(DefaultIconInfo[i]?t.hv=DefaultIconInfo[i].ext.hv:t.hv=this.Uw,this.Uw++),this.Rc(i,t))},i.prototype.loadImages=function(i,t){var h=this,e=t.cb,r=t.type;if(0===Object.keys(i).filter(function(i){return!h.Fs[i]}).length)e();else{var n=[],l=[];if(i.length){for(var o=0,a=i;o<a.length;o++)!function(o){var i=new Promise(function(e,i){h.loadImage(o,{cb:function(i,t){l.push(h.Fs[o]),e()},type:r})});n.push(i)}(a[o]);Promise.all(n).then(function(){e(l)}).catch(function(){e(l)})}else e(l)}},i.prototype.Vw=function(i,t){var h=this,r=t.cb,n=i.filter(function(i){return!h.Fs[i]});if(0===n.length)r([]);else{var e=[],l=[];if(i.length){for(var o=0,a=i;o<a.length;o++)!function(o){var i=new Promise(function(e,i){h.loadImage(o,{cb:function(i,t){l.push(h.Fs[o]),e()},type:"icon"})});e.push(i)}(a[o]);Promise.all(e).then(function(){var i=[];if(0<n.length){for(var t=0,e=n;t<e.length;t++){var o=e[t];i.push({url:o,data:h.getImage(o)})}h.emit("iconImageLoaded",{data:i})}r(l)}).catch(function(){r(l)})}else r(l)}},i.prototype.getImage=function(i){return this.Fs[i=void 0===i?"":i]},i.prototype.destory=function(){var i;this.Fs=((i={})[DefaultIconInfo.TW.img]=DefaultIconInfo.TW,i[DefaultIconInfo.RW.img]=DefaultIconInfo.RW,i)},i.prototype.Rc=function(t,e){var o=this,h=e.name,i=e.ext,r=void 0===i?{}:i,n=void 0===(i=e.type)?"other":i,l=e.cb,a=e.imageBitmap,s=this.Fs;s[h||t]={status:polyfill.uc.LOADING,startX:0,startY:1024*(e.hv||0),type:n,height:0,width:0},polyfill.Yw.send(t,{Me:"arraybuffer",qw:function(i){a?(console.time("createImageBitmap"),createImageBitmap(new Blob([new Uint8Array(i)])).then(function(i){console.timeEnd("createImageBitmap"),i=new polyfill.WQ(t,i,{imageBitmap:!0}),o.qQ(h||t,i,l,e,n,r)})):(i=new polyfill.WQ(t,i),o.qQ(h||t,i,l,e,n,r))},Aw:function(i){console.log(i),s[i=h||t].status=polyfill.uc.ERROR,l(s[i],e)}})},i.prototype.qQ=function(i,t,e,o,h,r){var n=this.Fs;if("success"!==t.status)console.error("createObjectURL fail"),n[i].status=polyfill.uc.ERROR,e(n[i],o);else if("icon"===h?(r.hv=o.hv,n[i]=DefaultIconInfo[i]||{ext:r,type:h,startX:0,startY:1024*(o.hv||0),height:1024,width:512,status:polyfill.uc.LOADED},n[i].data=t):n[i]={ext:r,type:h,startX:0,startY:0,height:0,width:0,data:t,status:polyfill.uc.LOADED},e(n[i],o),this.Mc[i]){for(var l=0,a=this.Mc[i];l<a.length;l++){var s=a[l];s.cb(n[i],s.opts)}delete this.Mc[i]}},i.prototype.Sc=function(i){var t,e=(e=(i=void 0===i?{}:i).img)&&e.context?(t=e.width||0,e.height||0):(t=i.width||0,i.height||0);return[t,e]},i}(polyfill.Event),Counter=function(e){function i(i){var t=e.call(this)||this;return t.OQ=i,t.zQ=0,t}return polyfill.Ei(i,e),i.prototype.TQ=function(){this.zQ+=1,this.zQ===this.OQ&&this.emit("count")},i.prototype.clear=function(){this.zQ=0},i}(polyfill.Event),_a$2,LabelFormatMap$1=(_a$2={},_a$2[polyfill.NebulaLabelFormat.id]=polyfill.NebulaLabelFormat,_a$2[polyfill.MapboxLabelFormat.id]=polyfill.MapboxLabelFormat,_a$2.nebula=polyfill.NebulaLabelFormat,_a$2),LabelWorker=function(e){function i(i){var t=e.call(this)||this;return t.parent=i,t.MW={},t.hD=["https://vdata.amap.com/style_icon/2.0/icon-normal-big.png","https://vdata.amap.com/style_icon/2.0/icon-biz-big.png"],t.z_=i.z_,t.R_=i.R_,t}return polyfill.Ei(i,e),i.prototype.iW=function(r,n){var i,f=this,u=(void 0===n&&(n={}),this.MW.ZL=n.ZL||polyfill.zoomRange[1],[]),p=(n.cb,this.parent.langForeign),d=this;for(i in r)!function(i){var l,t,e,o,a,h,s;r.hasOwnProperty(i)&&(o=(i=r[i]).tile,t=(i=i.params).scale,i=i.tag,u.push(i),e={vn:d.parent.vn},t=(e=new LabelFormatMap$1[n.id](e)).Ns(o,{ZL:d.MW.ZL,zoom:o.zo.z,scale:t,lang:p,VQ:d.parent.QZ}),l=[[o,e,t,i]],t=Object.keys(e.Fs),i=Object.keys(e.Es),e=[o],o=Date.now(),a=[],h=n.optimalZoom,(s=new Counter(2)).on("count",function(){f.parent.jQ.XQ(new LoadDynamicsTask(f.parent.vn,h,f.R_,f.z_,a,n,function(i){f.emit("dynamicTextVerticeLoadedByTile",{data:i.data,id:n.id})}),void 0,!0),f.parent.yY.setNeedUpdate(!0)},null,!0),d.R_.vW(i,{tiles:e,optimalZoom:h,tags:u,stamp:o,cb:function(i){for(var t=0,e=l;t<e.length;t++){var h=(o=e[t])[0],r=o[1],n=o[2],o=o[3];a.push({tile:h,gW:r,SW:n,tag:o})}s.TQ()}}),d.wW(t)?s.TQ():d.z_.Vw(t,{type:"icon",cb:function(){s.TQ()}}))}(i)},i.prototype.hW=function(i,t,e){var o=this;this.parent.jQ.XQ(new LoadDynamicsTask(this.parent.vn,this.MW.ZL,this.R_,this.z_,i,e,function(i){o.emit("dynamicTextVerticeLoadedByTile",{data:i.data,id:e.id})}),void 0,!0),this.parent.yY.setNeedUpdate(!0)},i.prototype.wW=function(i){for(var t=this.hD,e=0,o=0,h=i=void 0===i?[]:i;o<h.length;o++){var r=h[o];-1!==t.indexOf(r)&&e++}return e===i.length},i}(polyfill.Event),LoadDynamicsTask=function(){function i(i,t,e,o,h,r,n){this.vn=i,this.ZL=t,this.R_=e,this.z_=o,this.data=h,this.params=r,this.cb=n,this.type="LoadDynamicsTask",this.offset=0,this.result=[]}return i.prototype.play=function(i){for(var t=i,e=Date.now();0<t&&this.offset!==this.data.length;){var o,h=[],r=this.data[this.offset],n=r.tile,l=r.SW,a=(r.gW,r.tag),s=Object.keys(l).length,f={},u=0;if(0===s)h.push({data:n.zo});else{for(var p in l)l.hasOwnProperty(p)&&(o=l[p],o=new polyfill.eG({R_:this.R_,z_:this.z_}).Ns(o,{ZL:this.ZL,zoom:n.zo.z,from:"inner",center:n.localCoord.center}),f[p]=new polyfill.La(n.zo,o),++u===s)&&(p=this.hQ(n,this.ZL),h.push({data:f,XE:p,tag:a}));this.offset++,this.cb({data:h}),t=i-(Date.now()-e)}}return this.offset,this.data.length,this.result},Object.defineProperty(i.prototype,"status",{get:function(){return this.offset>=this.data.length?polyfill.vY.finish:polyfill.vY.pause},eb:!1,nb:!0}),i.prototype.hQ=function(i,t){if(i)for(var e=this.SQ(i)||[],o=0,h=e=new LabelFormatMap$1[i.type]({vn:this.vn}).DQ(e,{zoom:t});o<h.length;o++){var r=h[o],n=r.CO;r.EG||(r.EG={});for(var l=0,a=n;l<a.length;l++){var s=a[l],f=this.R_.mz(s);r.EG[s]=f}}return e},i.prototype.SQ=function(i){return i.data&&i.data.roadName||i.road},i}(),InnerLabelsSourceWorker=function(){function i(i){this.parent=i,this.Mf=i.R_,this.ac=i.z_}return i.prototype.loadData=function(h,r){var n=this,i=h.id===polyfill.n0.nebulaLabel?polyfill.n0.nebula:h.id;(i=this.parent.dQ(i))&&i.YE?i.YE(function(i,t){t.GW;var e=t.cb,o=t.ZL,t=t.optimalZoom;polyfill.isEmpty(i)?r&&r({}):n.parent.yw.iW(i,{ZL:o,optimalZoom:t,id:h.id,cb:function(i){r(i),e&&e()}})},h):r&&r({})},i}(),StaticSourceID,EnumTextureIndex,ImageStatus,noop=(function(i){i.nebula="nebula",i.nebulaLabel="nebulaLabel"}(StaticSourceID=StaticSourceID||{}),function(i){i[i.dynamic=0]="dynamic",i[i.icon=1]="icon"}(EnumTextureIndex=EnumTextureIndex||{}),function(i){i.BLOB="blob",i.TOLOAD="toload",i.LOADING="loading",i.LOADED="loaded",i.UNLOADED="unloaded",i.ERROR="error",i.RELOADING="reloading",i.UNCOMBINED="uncombined",i.COMBINING="combining",i.COMBINED="combined"}(ImageStatus=ImageStatus||{}),function(i){}),XHR={send:function(i,t){void 0===t&&(t={});var e=new XMLHttpRequest,h=void 0===(o=t.qw)?noop:o,r=void 0===(o=t.Aw)?noop:o,o=t.Me,n=t.method,t=t.content;return e.onreadystatechange=function(){if(4===e.readyState&&200===e.status){var i=e.response;try{h(i)}catch(i){r(i)}}else 404===e.status&&(e.abort(),r(Error("404")))},e.onerror=function(i){e.abort(),r(i)},e.open(n||"GET",i,!0),e.responseType=o||"json",e.send(t||void 0),e}};function parserFunc(i){var z={TS:function(){this.PS=0}},Ui=(z.TS.prototype.create=function(i){this.OS&&this.PS===i||(this.OS=[]),this.PS=i,this.FS=0,this.BS=0},z.TS.prototype.flush=function(){var i=this.FS-this.BS;if(0!==i){for(;i--;)this.ES.jS(this.OS[this.BS++]);this.FS>=this.PS&&(this.FS=0),this.BS=this.FS}},z.TS.prototype.NS=function(){this.flush(),this.ES=null},z.TS.prototype.US=function(i){this.NS(),this.ES=i},z.TS.prototype.init=function(i){i||(this.BS=0,this.FS=0)},z.TS.prototype.WS=function(i,t){var e=this.FS-i-1;for(e<0&&(e+=this.PS);t--;)e>=this.PS&&(e=0),this.OS[this.FS++]=this.OS[e++],this.FS>=this.PS&&this.flush()},z.TS.prototype.GS=function(i){this.OS[this.FS++]=i,this.FS>=this.PS&&this.flush()},z.TS.prototype.HS=function(i){return(i=this.FS-i-1)<0&&(i+=this.PS),this.OS[i]},z.VS=function(){},z.VS.prototype.US=function(i){this.ES=i},z.VS.prototype.NS=function(){this.ES=null},z.VS.prototype.init=function(){var i=5;for(this.ZS=0,this.YS=-1;i--;)this.ZS=this.ZS<<8|this.ES.JS()},z.VS.prototype.XS=function(i){for(var t,e=0,o=i;o--;)this.YS>>>=1,t=this.ZS-this.YS>>>31,this.ZS-=this.YS&t-1,e=e<<1|1-t,0==(4278190080&this.YS)&&(this.ZS=this.ZS<<8|this.ES.JS(),this.YS<<=8);return e},z.VS.prototype.qS=function(i,t){var e=i[t],o=(this.YS>>>11)*e;return(2147483648^this.ZS)<(2147483648^o)?(this.YS=o,i[t]+=2048-e>>>5,0==(4278190080&this.YS)&&(this.ZS=this.ZS<<8|this.ES.JS(),this.YS<<=8),0):(this.YS-=o,this.ZS-=o,i[t]-=e>>>5,0==(4278190080&this.YS)&&(this.ZS=this.ZS<<8|this.ES.JS(),this.YS<<=8),1)},z.QS=function(i,t){for(;t--;)i[t]=1024},z.KS=function(i){this.tR=[],this.iR=i},z.KS.prototype.init=function(){z.QS(this.tR,1<<this.iR)},z.KS.prototype.decode=function(i){for(var t=1,e=this.iR;e--;)t=t<<1|i.qS(this.tR,t);return t-(1<<this.iR)},z.KS.prototype.eR=function(i){for(var t,e=1,o=0,h=0;h<this.iR;++h)e=e<<1|(t=i.qS(this.tR,e)),o|=t<<h;return o},z.nR=function(i,t,e,o){for(var h,r=1,n=0,l=0;l<o;++l)r=r<<1|(h=e.qS(i,t+r)),n|=h<<l;return n},z.oR=function(){this.rR=[],this.aR=[],this.sR=[],this.hR=new z.KS(8),this.lR=0},z.oR.prototype.create=function(i){for(;this.lR<i;++this.lR)this.aR[this.lR]=new z.KS(3),this.sR[this.lR]=new z.KS(3)},z.oR.prototype.init=function(){var i=this.lR;for(z.QS(this.rR,2);i--;)this.aR[i].init(),this.sR[i].init();this.hR.init()},z.oR.prototype.decode=function(i,t){return 0===i.qS(this.rR,0)?this.aR[t].decode(i):0===i.qS(this.rR,1)?8+this.sR[t].decode(i):16+this.hR.decode(i)},z.fR=function(){this.uR=[]},z.fR.prototype.init=function(){z.QS(this.uR,768)},z.fR.prototype.cR=function(i){for(var t=1;(t=t<<1|i.qS(this.uR,t))<256;);return 255&t},z.fR.prototype.dR=function(i,t){var e,o,h=1;do{if(e=t>>7&1,t<<=1,h=h<<1|(o=i.qS(this.uR,(1+e<<8)+h)),e!==o){for(;h<256;)h=h<<1|i.qS(this.uR,h);break}}while(h<256);return 255&h},z.pR=function(){},z.pR.prototype.create=function(i,t){var e;if(!this.vR||this.mR!==t||this.yR!==i)for(this.yR=i,this.xR=(1<<i)-1,this.mR=t,this.vR=[],e=1<<this.mR+this.yR;e--;)this.vR[e]=new z.fR},z.pR.prototype.init=function(){for(var i=1<<this.mR+this.yR;i--;)this.vR[i].init()},z.pR.prototype.bR=function(i,t){return this.vR[((i&this.xR)<<this.mR)+((255&t)>>>8-this.mR)]},z.gR=function(){this.wR=new z.TS,this._R=new z.VS,this.kR=[],this.MR=[],this.SR=[],this.RR=[],this.zR=[],this.CR=[],this.AR=[],this.IR=[],this.$R=new z.KS(4),this.LR=new z.oR,this.DR=new z.oR,this.TR=new z.pR,this.PR=-1,this.OR=-1,this.AR[0]=new z.KS(6),this.AR[1]=new z.KS(6),this.AR[2]=new z.KS(6),this.AR[3]=new z.KS(6)},z.gR.prototype.FR=function(i){return!(i<0||(this.PR!==i&&(this.PR=i,this.OR=Math.max(this.PR,1),this.wR.create(Math.max(this.OR,4096))),0))},z.gR.prototype.BR=function(i,t,e){var o=1<<e;return!(8<i||4<t||4<e||(this.TR.create(t,i),this.LR.create(o),this.DR.create(o),this.jR=o-1,0))},z.gR.prototype.init=function(){var i=4;for(this.wR.init(!1),z.QS(this.kR,192),z.QS(this.CR,192),z.QS(this.MR,12),z.QS(this.SR,12),z.QS(this.RR,12),z.QS(this.zR,12),z.QS(this.IR,114),this.TR.init();i--;)this.AR[i].init();this.LR.init(),this.DR.init(),this.$R.init(),this._R.init()},z.gR.prototype.decode=function(i,t,e){var o,h,r,n,l=0,a=0,s=0,f=0,u=0,p=0,d=0;for(this._R.US(i),this.wR.US(t),this.init();e<0||p<e;)if(n=p&this.jR,0===this._R.qS(this.kR,(l<<4)+n))r=this.TR.bR(p++,d),d=7<=l?r.dR(this._R,this.wR.HS(a)):r.cR(this._R),this.wR.GS(d),l=l<4?0:l-(l<10?3:6);else{if(1===this._R.qS(this.MR,l))(o=0)===this._R.qS(this.SR,l)?0===this._R.qS(this.CR,(l<<4)+n)&&(l=l<7?9:11,o=1):(0===this._R.qS(this.RR,l)?h=s:(0===this._R.qS(this.zR,l)?h=f:(h=u,u=f),f=s),s=a,a=h),0===o&&(o=2+this.DR.decode(this._R,n),l=l<7?8:11);else if(u=f,f=s,s=a,o=2+this.LR.decode(this._R,n),l=l<7?7:10,4<=(r=this.AR[o<=5?o-2:3].decode(this._R))){if(a=(2|1&r)<<(n=(r>>1)-1),r<14)a+=z.nR(this.IR,a-r-1,this._R,n);else if((a=(a+=this._R.XS(n-4)<<4)+this.$R.eR(this._R))<0){if(-1===a)break;return!1}}else a=r;if(p<=a||a>=this.OR)return!1;this.wR.WS(a,o),p+=o,d=this.wR.HS(0)}return this.wR.flush(),this.wR.NS(),this._R.NS(),!0},z.gR.prototype.ER=function(i){var t;return!(i.size<5||(t=i.JS(),!this.BR(t%9,(t=~~(t/9))%5,~~(t/5))))&&(t=i.JS(),t=(t=(t|=i.JS()<<8)|i.JS()<<16)+16777216*i.JS(),this.FR(t))},z.NR=function(i,t){var e,o=new z.gR;if(!o.ER(i))throw new Error("Incorrect stream properties");if(e=i.JS(),e=((e|=i.JS()<<8)|i.JS()<<16)+16777216*i.JS(),i.JS(),i.JS(),i.JS(),i.JS(),o.decode(i,t,e))return!0;throw new Error("Error in data stream")},1e-9);function ji(i,t,e){for(var o,a,h=i.subarray(t,e),r=0,n="",l=0,r=0;r<h.length;)(a=h[r])>>>7==0?("0"!==(o=String.fromCharCode(h[r])).charCodeAt(0).toString(16)&&(n+=o),r+=1):252==(252&a)?(l=(3&h[r])<<30,l=(l=(l=(l=(l|=(63&h[r+1])<<24)|(63&h[r+2])<<18)|(63&h[r+3])<<12)|(63&h[r+4])<<6)|63&h[r+5],n+=String.fromCharCode(l),r+=6):248==(248&a)?(l=(7&h[r])<<24,l=(l=(l=(l|=(63&h[r+1])<<18)|(63&h[r+2])<<12)|(63&h[r+3])<<6)|63&h[r+4],n+=String.fromCharCode(l),r+=5):240==(240&a)?(l=(15&h[r])<<18,l=(l=(l|=(63&h[r+1])<<12)|(63&h[r+2])<<6)|63&h[r+3],n+=String.fromCharCode(l),r+=4):224==(224&a)?(l=(31&h[r])<<12,l=(l|=(63&h[r+1])<<6)|63&h[r+2],n+=String.fromCharCode(l),r+=3):192==(192&a)?(l=(63&h[r])<<6,l|=63&h[r+1],n+=String.fromCharCode(l),r+=2):("0"!==(o=String.fromCharCode(h[r])).charCodeAt(0).toString(16)&&(n+=o),r+=1);return n.trim()}var o=new RegExp("^[+\\-]?[0-1]*[.]?[0-1]*$","gi");function Vi(i,t){i=i.toString(),t=t.toString(),i=new Array(32-i.length+1).join("0")+i,t=new Array(32-t.length+1).join("0")+t;var e=o;return e.lastIndex=0,(t=(t+i).toString().match(e))?(i=-1===t[i=0].indexOf(".")?parseInt(t,2):i).toString(36).toUpperCase():"error"}i.getUnifyJson=function(i){var t=[];if(i instanceof ArrayBuffer){var e=new DataView(i),o=0,h=e.getInt16(o+=4,!1);o+=2;try{for(;0<h;){o+=4;for(var r=e.getUint8(o),n=(o+=1,new ArrayBuffer(r)),l=new Uint8Array(n),a=0;a<r;a++)l[a]=e.getUint8(o),o+=1;var s=ji(l,0,r),f=(o+=2,e.getInt8(o)),u=(o+=1,0!==f&&((C={}).status=f,C.building={},C.floor={},C.id=s,t.push(C)),e.getInt32(o,!1)),p=(o+=4,e.getInt32(o,!0)),d=(o+=4,u-p);if(0!==p){for(var x=2078870821,y=8*Math.ceil(p/8),c=p%8,v=new ArrayBuffer(y),g=new Int32Array(v),w=0;8<=p;){var b=e.getInt32(o,!0),R=e.getInt32(o+4,!0),m=b^x,k=292664^R;g[w]=m,g[w+1]=k,w+=2,o+=8,p-=8}0!==p&&(b=e.getInt32(o,!0),R=e.getInt32(o+4,!0),m=b^x,k=292664^R,g[w]=m,g[w+1]=k,o+=p);for(var _=new Uint8Array(v),S=_.length,I=S-8+c,A=new Uint8Array(I),a=0;a<I;a++)A[a]=_[a];for(a=0;a<c;a++)A[I-c+a]=_[S-1-a];for(var C,E={data:[],offset:0,jS:function(i){this.data[this.offset++]=i}},M=(z.NR({data:A,offset:0,JS:function(){return this.data[this.offset++]}},E),E.data),I=M.length,D=new ArrayBuffer(I),T=new Int8Array(D),a=0;a<I;a++)T[a]=M[a];(C=function(i){for(var t={},e={},o=new Uint8Array(i),h=new DataView(i),r=0,L=h.getInt32(r=r+4+4,!0),i=h.getInt32(r=r+4+4,!0),i=Vi(i=h.getUint32(r=r+(4+i)+4,!0).toString(2),h.getUint32(r+4,!0).toString(2)),n=ji(o,r+=8,r+64),l=ji(o,r+=64,r+64),a=h.getInt8(r+=64),P=ji(o,r+=1,r+8),B=h.getInt16(r+=8,!0),O=h.getInt16(r+2,!0),s=h.getFloat32(r+=4,!0),f=h.getFloat32(r+4,!0),J=h.getFloat32(r+=8,!0),U=h.getFloat32(r+4,!0),j=h.getFloat32(r+=8,!0),V=h.getFloat32(r+4,!0),u=h.getInt32(r+=8,!0),p=h.getInt32(r+=4,!0),d=h.getInt32(r+=4,!0),x=(r+=4,[]),y=0;y<u;y++)x.push(h.getInt32(r,!0)),r+=4;for(var c=[],y=0;y<d;y++)c.push(h.getInt32(r,!0)),r+=4;for(var v=[],y=0;y<u;y++){var N=ji(o,r,r+48);v.push(N),r+=48}for(var g=[],y=0;y<u;y++){var K=ji(o,r,r+8);g.push(K),r+=8}for(var w=[],y=0;y<p;y++){var b=h.getInt32(r,!0)*Ui+f,R=h.getInt32(r+4,!0)*Ui+s;w.push([b,R]),r+=8}i={type:"Feature",geometry:{type:"Polygon",coordinates:[w]},properties:{pid:i,name_cn:n,name_en:l,default_floor:a,buildingtype:P,building_poi_style:[B,O],centerPoint:[f,s],left_bottom_Point:[J,U],width:j,height:V,numberofFloor:u,numberofGeoPoints:p,park_floor_count:d,floor_indexs:x,park_floors:c,floor_names:v,floor_nonas:g}};for(var m=0;m<L;m++){for(var H=ji(o,r,r+8),k=(r+=8,h.getInt8(r)),G=(r+=1,e[k]={floor:{},shops:[],pubs:[],cons:[]},h.getInt16(r,!0)),$=h.getInt16(r+2,!0),X=(r+=4,h.getInt16(r,!0)),Z=h.getInt16(r+2,!0),q=(r+=4,h.getInt16(r,!0)),Y=h.getInt16(r+2,!0),_=(r+=4,h.getInt32(r,!0)),S=(r+=4,h.getInt32(r,!0)),I=(r+=4,h.getInt32(r,!0)),A=(r+=4,h.getInt32(r,!0)),C=(r+=4,[]),E=0;E<A;E++){for(var Q=h.getInt32(r,!0),M=(r+=4,[]),D=0;D<Q;D++)b=h.getInt32(r,!0)*Ui+f,R=h.getInt32(r+4,!0)*Ui+s,M.push([b,R]),r+=8;C.push(M)}for(var T="Polygon",z=C[0],T=(1<A&&(T="MultiPolygon",z=C),{type:"Feature",geometry:{type:T,coordinates:[z]},properties:{namecode:H,index:k,floor_region_type:[G,$],unhighlighted_floor_line_style:[X,Z],highlighted_floor_line_style:[q,Y],numberofShopCount:_,numberofPubCount:S,numberofConCount:I,floor_area_count:A}}),ii=(e[k].floor=T,[]),ti=0;ti<_;ti++){var ei=ji(o,r,r+128);r+=128;for(var oi=Vi(h.getUint32(r,!0).toString(2),h.getUint32(r+4,!0).toString(2)),hi=ji(o,r+=8,r+24),ri=ji(o,r+=24,r+12),ni=(r+=12,h.getInt32(r,!0)),li=(r+=4,h.getFloat32(r,!0)),ai=(r+=4,h.getInt8(r)),si=(r+=1,h.getInt16(r,!0)),fi=h.getInt16(r+2,!0),ui=(r+=4,h.getInt16(r,!0)),pi=h.getInt16(r+2,!0),di=(r+=4,h.getInt32(r,!0)*Ui+f),xi=h.getInt32(r+4,!0)*Ui+s,yi=(r+=8,h.getInt32(r,!0)),ci=(r+=4,[]),E=0;E<yi;E++)b=h.getInt32(r,!0)*Ui+f,R=h.getInt32(r+4,!0)*Ui+s,ci.push([b,R]),r+=8;ii.push({type:"Feature",geometry:{type:"Polygon",coordinates:[ci]},properties:{name:ei,pid:oi,cpid:hi,logo:ri,area:ni,rank:li,height:ai,poitype:[si,fi],regiontype:[ui,pi],font_anthor_point:[di,xi],shop_point_number:yi}})}e[k].shops=ii;for(var vi=[],gi=0;gi<S;gi++){var wi=ji(o,r,r+24);r+=24;var bi=Vi(h.getUint32(r,!0).toString(2),h.getUint32(r+4,!0).toString(2)),Ri=ji(o,r+=8,r+48),mi=(r+=48,h.getFloat32(r,!0)),ki=(r+=4,h.getInt16(r,!0)),_i=h.getInt16(r+2,!0),b=(r+=4,h.getInt32(r,!0)*Ui+f),R=h.getInt32(r+4,!0)*Ui+s;r+=8,vi.push({type:"Feature",geometry:{type:"Point",coordinates:[b,R]},properties:{cpid:wi,pid:bi,name:Ri,rank:mi,poitype:[ki,_i]}})}e[k].pubs=vi;for(var Si=[],Ii=0;Ii<I;Ii++){var Ai=ji(o,r,r+24);r+=24;var Ci=Vi(h.getUint32(r,!0).toString(2),h.getUint32(r+4,!0).toString(2)),Ei=ji(o,r+=8,r+48),Mi=(r+=48,h.getFloat32(r,!0)),Di=(r+=4,h.getInt16(r,!0)),Ti=h.getInt16(r+2,!0),b=(r+=4,h.getInt32(r,!0)*Ui+f),R=h.getInt32(r+4,!0)*Ui+s;r+=8,Si.push({type:"Feature",geometry:{type:"Point",coordinates:[b,R]},properties:{cpid:Ai,pid:Ci,name:Ei,rank:Mi,poitype:[Di,Ti]}})}e[k].cons=Si}for(var n=h.getInt32(r+=4,!0),zi=h.getInt32(r+=4+n,!0),Wi=(r+=4,[]),y=0;y<zi;y++)b=h.getInt32(r,!0)*Ui+f,R=h.getInt32(r+4,!0)*Ui+s,Wi.push([b,R]),r+=8;i.properties.outside_outline=Wi;var W,F={};for(W in e)if(e.hasOwnProperty(W)){for(F.floor=e[W].floor,D=0;D<e[W].shops.length;D++){var Fi=h.getInt16(r,!0),Li=(r+=2,h.getInt16(r,!0));r+=2,e[W].shops[D].properties.zoom_min=Fi,e[W].shops[D].properties.zoom_max=Li}for(F.shops=e[W].shops,D=0;D<e[W].pubs.length;D++){var Pi=h.getInt16(r,!0),Bi=(r+=2,h.getInt16(r,!0));r+=2,e[W].pubs[D].properties.zoom_min=Pi,e[W].pubs[D].properties.zoom_max=Bi}for(F.pubs=e[W].pubs,D=0;D<e[W].cons.length;D++){var Oi=h.getInt16(r,!0),Ji=(r+=2,h.getInt16(r,!0));r+=2,e[W].cons[D].properties.zoom_min=Oi,e[W].cons[D].properties.zoom_max=Ji}F.cons=e[W].cons,t.floor=F}return l=h.getInt32(r+=4,!0),a=h.getInt8(r+=4+l),r+=1,i.properties.UR=a,t.building=i,t}(D)).status=f,C.id=s,t.push(C)}o+=d,--h}}catch(i){}}else t.push(C={status:3,building:{},floor:{},id:""});return t}}var obj={WR:parserFunc},IndoorMapBinDataParser=(parserFunc(obj),obj),OverlayWorker=function(){function i(i){this.parent=i}return i.prototype.setPathWebgl=function(i,t){try{for(var e=new polyfill.K_,o=new polyfill.J_,h=new polyfill.oE,r=new polyfill.oE,n=i.data,l=this.EW(n[0][0][0]),a=0,s=n;a<s.length;a++){for(var f=s[a],u=l.center,p=[],d=[],x=f[0],y=[],c=[],v=[],g=0,w=x;g<w.length;g++){var b=w[g],R=polyfill.ProjectionManager.getProjection("EPSG:3857").project(b[0],b[1]);p.push(R[0]-u[0],R[1]-u[1]),d.push(b)}for(var m=1,k=f.length;m<k;m++){for(var _=f[m],S=[],I=[],A=0,C=_;A<C.length;A++)b=C[A],polyfill.Bs(b)?(S.push(b.pos[0]-u[0],b.pos[1]-u[1]),I.push(b.toJSON())):(R=polyfill.ProjectionManager.getProjection("EPSG:3857").project(b[0],b[1]),S.push(R[0]-u[0],R[1]-u[1]),I.push(b));y.push(S),c.push(I)}for(var E=[],m=0,k=p.length;m<k;m+=2)E.push(polyfill.xd(p[m],p[m+1]));polyfill.equals(E[0],E[E.length-1])||E.push(polyfill.Ex(E[0]));for(var M=p.length,m=0;m<y.length;m++)v.push(M/2),M+=y[m].length,polyfill.Util.Ig(p,y[m]);for(var D=e.Nx(p,v),T=(h.add(D),o.Nx(E,{lineJoin:"miter"}).Iw),m=0;m<y.length;m++){for(var z=[],W=0,k=(S=y[m]).length;W<k;W+=2)z.push(polyfill.xd(S[W],S[W+1]));z.push(polyfill.xd(S[0],S[1])),T+=o.Nx(z,{lineJoin:"miter"}).Iw}r.add(T)}t(null,{$c:o,Dc:e,Sx:l,Oc:h,Uc:r})}catch(i){t(i.message)}},i.prototype.AW=function(i,t){try{var e={},o=IndoorMapBinDataParser.getUnifyJson(i);if(!o)return!1;for(var h,r,n,l,a,s,f,u=0;u<o.length;u++)0===o[u].status&&(r=(h=o[u]).floor,n=h.building,l=h.status,a=h.id,s=r.floor.properties.index,e[a]||(e[a]={}),e[a].building=n,e[a].data||(e[a].data={}),f={floor:r,status:l,id:a,building:n},e[a].data[s]=f);t(null,e)}catch(i){t(i.message,null)}},i.prototype.EW=function(i){if(i)return i=polyfill.Bs(i)?polyfill.ProjectionManager.getProjection("EPSG:3857").project(i.KL,i.kT):polyfill.ProjectionManager.getProjection("EPSG:3857").project(i[0],i[1]),polyfill.lcs.getLocalByCoord(i)},i}(),wasm,heap=new Array(32).fill(void 0);function getObject(i){return heap[i]}heap.push(void 0,null,!0,!1);var heap_next=heap.length;function dropObject(i){i<36||(heap[i]=heap_next,heap_next=i)}function takeObject(i){getObject(i),dropObject(i)}var cachedTextDecoder=self.TextDecoder?new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}):{},cachegetUint8Memory0=(cachedTextDecoder.decode&&cachedTextDecoder.decode(),null);function getUint8Memory0(){return cachegetUint8Memory0=null!==cachegetUint8Memory0&&cachegetUint8Memory0.buffer===wasm.memory.buffer?cachegetUint8Memory0:new Uint8Array(wasm.memory.buffer)}function getStringFromWasm0(i,t){return cachedTextDecoder.decode(getUint8Memory0().subarray(i,i+t))}var WASM_VECTOR_LEN=0,cachedTextEncoder=self.TextEncoder?new TextEncoder:{},encodeString="function"==typeof cachedTextEncoder.encodeInto?function(i,t){return cachedTextEncoder.encodeInto(i,t)}:function(i,t){var e=cachedTextEncoder.encode(i);return t.set(e),{read:i.length,jW:e.length}};function passStringToWasm0(i,t,e){var o;if(void 0===e)return o=t((h=cachedTextEncoder.encode(i)).length),getUint8Memory0().subarray(o,o+h.length).set(h),WASM_VECTOR_LEN=h.length,o;for(var h,r=i.length,n=t(r),l=getUint8Memory0(),a=0;a<r;a++){var s=i.charCodeAt(a);if(127<s)break;l[n+a]=s}return a!==r&&(n=e(n,r,r=a+3*(i=0!==a?i.slice(a):i).length),h=getUint8Memory0().subarray(n+a,n+r),a+=encodeString(i,h).jW),WASM_VECTOR_LEN=a,n}var cachegetInt32Memory0=null;function getInt32Memory0(){return cachegetInt32Memory0=null!==cachegetInt32Memory0&&cachegetInt32Memory0.buffer===wasm.memory.buffer?cachegetInt32Memory0:new Int32Array(wasm.memory.buffer)}function addHeapObject(i){heap_next===heap.length&&heap.push(heap.length+1);var t=heap_next;return heap_next=heap[t],heap[t]=i,t}var RSAPublicKeyPair=function(){function e(){var i=wasm.rsapublickeypair_new();return e.XW(i)}return e.XW=function(i){var t=Object.create(e.prototype);return t.UW=i,t},e.prototype.VW=function(){var i=this.UW;this.UW=0,wasm.__wbg_rsapublickeypair_free(i)},e.prototype.init=function(){wasm.rsapublickeypair_init(this.UW)},e.prototype.encode=function(i){try{var t=passStringToWasm0(i,wasm.__wbindgen_malloc,wasm.__wbindgen_realloc),e=WASM_VECTOR_LEN;return wasm.rsapublickeypair_encode(8,this.UW,t,e),getStringFromWasm0(o=getInt32Memory0()[2],h=getInt32Memory0()[3])}finally{var o=getInt32Memory0()[2],h=getInt32Memory0()[3];wasm.__wbindgen_free(o,h)}},e}();function loadSync(i,t){var e=new WebAssembly.Module(i);return{module:i,instance:new WebAssembly.Instance(e,t)}}function initSync(i){var t={wbg:{}};t.wbg.__wbg_new_59cb74e423758ede=function(){return addHeapObject(new Error)},t.wbg.__wbg_stack_558ba5917b466edd=function(i,t){var t=passStringToWasm0(getObject(t).stack,wasm.__wbindgen_malloc,wasm.__wbindgen_realloc),e=WASM_VECTOR_LEN;getInt32Memory0()[i/4+1]=e,getInt32Memory0()[i/4+0]=t},t.wbg.__wbg_error_4bb6c2a97407129a=function(i,t){try{console.error(getStringFromWasm0(i,t))}finally{wasm.__wbindgen_free(i,t)}},t.wbg.__wbindgen_object_drop_ref=function(i){takeObject(i)},t.wbg.__wbindgen_throw=function(i,t){throw new Error(getStringFromWasm0(i,t))},i=loadSync(i,t).instance,wasm=i.exports}var RSAWorker=function(){function i(i,t){this.parent=i}return i.prototype.transform=function(i){if(this.instance)return this.instance.encode(i)},i.prototype.dE=function(i){initSync(base64ToBuffer(data)),this.instance=new RSAPublicKeyPair,this.instance.init(),i&&i(null)},i}(),env;function base64ToBuffer(i){for(var t=atob(i),e=new Uint8Array(t.length),o=0,h=t.length;o<h;o++)e[o]=t.charCodeAt(o);return e.buffer}var env=polyfill.Support.DW?{movingDraw:sharedChunk.movingDraw,db:sharedChunk.db,nebulaVersion:sharedChunk.nebulaVersion,host:sharedChunk.host}:{movingDraw:window.movingDraw},AMapWorker=function(h){function i(i,t,e){var o=h.call(this)||this,t=(o.key=t,o.GW=e,o.lQ={},o.Zw=!1,o._id="-1",o.protocol="https",o.Yw=XHR,o.jQ=new polyfill.MY,o.QZ="",o.$w=[],o.Uh=new polyfill.Bh(i,o),o.self=i,o.z_=new ImageManagerWorker);return o.R_=new polyfill.jb({parent:o,z_:t}),o.IW=new polyfill.xW(o,XHR),o.Ww=new NebulaSourceWorker(o),o.NQ=new InnerLabelsSourceWorker(o),o.lQ[o.Ww.id]=o.Ww,o.yw=new LabelWorker(o),o.BW=new OverlayWorker(o),polyfill.Support.wasm&&(o.PW=new RSAWorker(o)),o.Fb(),o.yY=new polyfill.wY({render:function(){o.jQ.exec(10)},check:function(){return o.jQ.xY()}}),o}return polyfill.Ei(i,h),i.prototype.initCryptWorker=function(i,t,e){e()},i.prototype.setId=function(i,t,e){this._id=t,e()},i.prototype.loadNebulaSourceTile=function(i,t,e){var o=this,h=t.url,r=t.ya,n=t.zoom,l=t.projectionId,a=t.optimalZoom,s=t.Ca,f=t.mS,u=t.viewMode,p=t.showBuildingBlock,d=t.ZL,x=t.hH,t=t.kZ;return this.Ww.bw(h,r,n,a,l,s,f,u,p,d,x,function(i,t){o.Zw?o.$w.push({done:e,type:"NebulaSourceTile",data:t}):e(i,t)},t)},i.prototype.decodeNebulaSourceTile=function(i,t,e){var o=t.url,h=(t.ya,t.zoom),r=t.projectionId,n=t.optimalZoom,l=(t.Ca,t.mS),a=t.viewMode,s=t.showBuildingBlock,f=t.ZL,t=(t.hH,t.buffer);return this.Ww.pQ(t,r,h,a,s,l,n,f,e,o)},i.prototype.loadNebulaSourceTileSdf=function(i,t,e){var o=this,h=t.url,r=t.ya,n=(t.zoom,t.projectionId),l=(t.optimalZoom,t.Ca,t.mS,t.viewMode,t.showBuildingBlock,t.mH),t=t.ZL;return this.Ww.bW(h,r,n,t,l,function(i,t){o.Zw?o.$w.push({done:e,type:"NebulaSourceTileSdf",data:t}):e(i,t)})},i.prototype.decodeNebulaSourceTileSdf=function(i,t,e){var o=this,h=t.url,r=t.ya,n=(t.zoom,t.projectionId),l=(t.optimalZoom,t.Ca,t.mS,t.viewMode,t.showBuildingBlock,t.mH),a=t.ZL,t=t.buffer,h=-1!==h.indexOf("/oversea"),s=new polyfill.vH;return this.Ww.HQ(t,h,n,r,s,l,a,function(i,t){o.Zw?o.$w.push({done:e,type:"NebulaSourceTileSdf",data:t}):e(i,t)}),{cancel:s.cancel}},i.prototype.loadDistrictSourceTile=function(i,t,e){var o=t.url,h=t.tileCoord,r=t.projectionId,n=t.tileSize;return t.styles,this._getDistrictSourceWorker(),this.kW.bw(o,h,r,n,e)},i.prototype.loadMapboxVTSourceTile=function(i,t,e){var o=this,h=t.url,r=t.tileCoord,n=t.projectionId,l=t.tileSize,t=t.styles;return this._getMapboxVTSourceWorker(),this.QJ.bw(h,r,n,l,t,function(i,t){o.Zw?o.$w.push({done:e,type:"loadMapboxVTSourceTile",data:t}):e(i,t)})},i.prototype.reBufferMapboxVTSource=function(i,t,e){var o=t.MX,t=t.styles;return this._getMapboxVTSourceWorker(),this.QJ.mX(o,t,e)},i.prototype.loadMapboxSourceTile=function(i,t,e){var o=t.url,h=t.tileCoord,r=t.projectionId,n=t.tileSize,l=t.styles,t=t.adcode;return this._getMapboxSourceWorker(),this.vQ.bw(o,h,r,n,l,t,e)},i.prototype.updateMapStyle=function(i,t,e){polyfill.Support.amapRunTime&&!polyfill.Support.amapRunTime["style-parse-begin"]&&(polyfill.Support.amapRunTime["style-parse-begin"]=Date.now());var o=JSON.parse(t.value);polyfill.Support.amapRunTime&&!polyfill.Support.amapRunTime["style-parse-end"]&&(polyfill.Support.amapRunTime["style-parse-end"]=Date.now()),this.vn=new polyfill.StyleParser(t.TY),this.vn.jY(o),this.Ww.emit("styleReady")},i.prototype.updateUserStyle=function(i,t,e){this.vn&&this.vn.setStyle(t.Kd),e&&e()},i.prototype.sendHttp=function(i,t){this.R_.protocol=t.protocol,this.protocol=t.protocol},i.prototype.updateParams=function(i,t){this.params=polyfill.assign(this.params,t),t.langForeign&&(this.langForeign=t.langForeign),t.QG&&(this.QG=t.QG)},i.prototype.getSDFData=function(i,t,e){this.R_.loadData(t,{cb:function(i){e(null,i)}})},i.prototype.getImages=function(i,t){var r=this,n=t.data,l=t.cb,a=this.z_;a.loadImages(n,{cb:function(i){for(var t=[],e=0,o=n;e<o.length;e++){var h=o[e];t.push({url:h,data:a.getImage(h)})}r.Uh.send("imageLoaded",{data:t,cb:l})},type:"icon"})},i.prototype.setPathWebgl=function(i,t,e){this.BW.setPathWebgl(t,e)},i.prototype.sendIndoorRequest=function(i,t,e){var o=this;this.BW.AW(t,function(i,t){o.Zw?o.$w.push({done:e,type:"sendIndoorRequest",data:t}):e(i,t)})},i.prototype.Qw=function(i){this.Uh.send("NebulaTileSdfLoaded",polyfill.ca)},i.prototype.setMainThreadBusy=function(i,t){if(env.movingDraw)this.Zw=!1;else{if(this.Zw=t,!this.Zw)for(var e=0,o=this.$w;e<o.length;e++){var h=o[e];h.done?h.done(null,h.data):this.Uh.send(h.type,h.data)}this.$w=[]}},i.prototype.loadWordsByFront=function(i){this.Uh.send("loadWordsByFront",i.Es,i.cb)},i.prototype.innerLabelsLoadData=function(i,t,e){this.NQ.loadData(t,e)},i.prototype.dQ=function(i){return this.lQ[i]},i.prototype.deleteTileStaticSDF=function(i,t){this.IW.NW(t)},i.prototype.PQ=function(i,t){this.QZ=t},i.prototype._getNebulaSourceWorker=function(){return this.Ww||(this.Ww=new NebulaSourceWorker(this)),this.Ww},i.prototype._getDistrictSourceWorker=function(){return this.kW||(this.kW=new DistrictSourceWorker(this)),this.kW},i.prototype._getMapboxVTSourceWorker=function(){return this.QJ||(this.QJ=new polyfill.bX),this.QJ},i.prototype._getMapboxSourceWorker=function(){var i;return this.vQ||(i=this.vQ=new MapboxSourceWorker(this),this.lQ[i.id]=i),this.vQ},i.prototype.Fb=function(){var o=this;this.z_.on("iconImageLoaded",function(i){delete i.type,o.Uh.send("iconImageLoaded",i)}),this.R_.on("dynamicTextSDFInfoLoaded",function(i){delete i.type,o.Uh.send("dynamicTextSDFInfoLoaded",i.data)}),this.yw.on("dynamicTextVerticeLoaded",function(i){var t,e=i;o.Zw?(t=i.type,delete i.type,o.$w.push({type:t,data:e})):(delete i.type,o.Uh.send("dynamicTextVerticeLoaded",e))}),this.yw.on("dynamicTextVerticeLoadedByTile",function(i){var t,e=i;o.Zw?(t=i.type,delete i.type,o.$w.push({type:t,data:e})):(delete i.type,o.Uh.send("dynamicTextVerticeLoadedByTile",e))})},i}(polyfill.Event);return polyfill.Support.DW&&(self.Wh=new AMapWorker(self,sharedChunk.key,env),self.StyleParser=polyfill.StyleParser),AMapWorker}),define(["./shared"],function(_){var P={"AMap.MouseTool":["AMap.RangingTool"],"AMap.Adaptor":["AMap.CallAMap"]},j=new _.tS;function B(t){try{var i,n=localStorage.getItem("_AMap_"+t);return n&&((i=JSON.parse(n)).version===_.Module.eS.iS?(window._jsload_(t,i.script,!0),i.css&&window._cssload_(t,i.css,!0),j.add([t],void 0),j.finish(t),1):void window.localStorage.removeItem("_AMap_"+t))}catch(t){}}function W(t){for(var i=[],n=0,s=t;n<s.length;n++){var e=s[n],r=e;if(!j.has(e)){if(r=P[r])for(var h=0,o=r;h<o.length;h++){var a=o[h];!t[a]&&i.indexOf(a)<0&&(B(a)||i.push(a))}i.indexOf(e)<0&&(B(e)||i.push(e))}}return i}function F(t,i){var n=document.createElement("script");n.type="text/javascript",(document.body?(n.onload=function(){document.body.removeChild(n),i()},n.src=t,document.body):(n.onload=function(){document.head.removeChild(n),i()},n.src=t,document.head)).appendChild(n)}(G=document.getElementById("AMap_Dynamic_style"))||((G=document.createElement("style")).type="text/css",G.id="AMap_Dynamic_style",(ct=document.head||document.getElementsByTagName("head")[0]).childNodes.length<2?ct.appendChild(G):ct.insertBefore(G,ct.childNodes[1]));function N(t){G.appendChild(document.createTextNode(t))}window._cssload_=function(t,i,n){try{!n&&window.localStorage&&i&&""!==i&&window.localStorage.setItem("_AMap_"+t,JSON.stringify({css:i,version:_.Module.eS.iS}))}catch(t){}N(i)},window._jsload_=function(t,i,n){try{var s;!n&&i&&""!==i&&(s=window.localStorage["_AMap_"+t]||"{}",(s=JSON.parse(s)).version!==_.Module.eS.iS||s.script?window.localStorage.setItem("_AMap_"+t,JSON.stringify({version:_.Module.eS.iS,script:i})):window.localStorage.setItem("_AMap_"+t,JSON.stringify({version:_.Module.eS.iS,script:i,css:s.css})))}catch(t){}_.Module.nS(t,i)},window.cZ=_.Module;var G,U="function"==typeof Float32Array;function Y(t,i){return 1-3*i+3*t}function Z(t,i){return 3*i-6*t}function X(t,i,n){return((Y(i,n)*t+Z(i,n))*t+3*i)*t}function J(t,i,n){return 3*Y(i,n)*t*t+2*Z(i,n)*t+3*i}V.prototype.t=function(t){for(var i=0,n=1;10!==n&&this.i[n]<=t;++n)i+=.1;var s=i+(t-this.i[--n])/(this.i[n+1]-this.i[n])*.1,e=J(s,this.o,this.s);if(.001<=e){for(var r=t,h=s,o=this.o,a=this.s,u=0;u<4;++u){var c=J(h,o,a);if(0===c)return h;h-=(X(h,o,a)-r)/c}return h}if(0===e)return s;for(var f,l,d=t,v=i,p=i+.1,m=this.o,y=this.s,b=0;0<(f=X(l=v+(p-v)/2,m,y)-d)?p=l:v=l,1e-7<Math.abs(f)&&++b<10;);return l},V.prototype.h=function(t){return 0===t?0:1===t?1:X(this.t(t),this.l,this.u)},V.prototype.p=function(t){return t};var H=V;function V(t,i,n,s){if(!(0<=t&&t<=1&&0<=n&&n<=1))throw new Error("bezier x values must be in [0, 1] range");this.o=t,this.l=i,this.s=n,this.u=s,this.i=new(U?Float32Array:Array)(11);for(var e=0;e<11;++e)this.i[e]=X(.1*e,t,n)}var q,K,w={getViewport:function(t){return t?[t.clientWidth,t.clientHeight]:[0,0]},getStyle:function(t,i){var n,s=t.style[i];return"auto"===(s=(s=(s=s&&"auto"!==s||!document.defaultView?s:(n=document.defaultView.getComputedStyle(t,null))?n[i]:null)&&"auto"!==s||"height"!==i?s:t.clientHeight+"px")&&"auto"!==s||"width"!==i?s:t.clientWidth+"px")?null:s},getViewportOffset:function(t){var i,n=0,s=0,e=t,r=document.body,h=document.documentElement;do{if(n+=e.offsetTop||0,s+=e.offsetLeft||0,n+=parseInt(w.getStyle(e,"borderTopWidth"),10)||0,s+=parseInt(w.getStyle(e,"borderLeftWidth"),10)||0,i=w.getStyle(e,"position"),e.offsetParent===r&&"absolute"===i)break;if("fixed"===i){n+=r.scrollTop||h.scrollTop||0,s+=r.scrollLeft||h.scrollLeft||0;break}}while(e=e.offsetParent);for(e=t;e!==r&&(n-=e.scrollTop||0,s-=e.scrollLeft||0,!w.m()&&_.Support.webkit&&(s+=e.scrollWidth-e.clientWidth),e=e.parentNode););return[s,n]},m:function(){return q||(K="ltr"===w.getStyle(document.body,"direction"),q=!0),K},create:function(t,i,n,s){return t=document.createElement(t),n&&(t.className=n),i&&(s&&"before"===s?(n=i.firstChild,i.insertBefore(t,n)):i.appendChild(t)),t},toggleClass:function(t,i,n){n?this.addClass(t,i):this.removeClass(t,i)},hasClass:function(t,i){if(t&&i)return 0<t.className.length&&new RegExp("(^|\\s)"+i+"(\\s|$)").test(t.className)},addClass:function(t,i){t&&i&&(t.classList&&t.classList.add?t.classList.add(i):this.hasClass(t,i)||(t.className+=(t.className?" ":"")+i))},setClass:function(t,i){t&&(t.className=i||"")},removeClass:function(t,n){t&&n&&(t.classList&&t.classList.remove?t.classList.remove(n):t.className=t.className.replace(/(\S+)\s*/g,function(t,i){return i===n?"":t}).replace(/(^\s+|\s+$)/,""))},watchSize:function(n,s,e){var i=document.createElement("iframe"),r=(i.style.cssText="width: 100%;height: 100%;position: absolute;pointEvents:none; opacity:0; margin: 0;padding: 0;border: none;",i.onload=function(){i&&(i.contentWindow.onresize=t)},n.appendChild(i),i.src="javascript:void(0)",0),h=0;function t(){e.k=n.getBoundingClientRect(),e.M=[n.clientLeft,n.clientTop];var t=n.offsetWidth,i=n.offsetHeight;t===r&&i===h||(s(t,i),r=t,h=i)}return t(),e.resize=t,window.onscroll=t,function(){var t;e.resize&&(e.resize=null),window.onscroll&&(window.onscroll=null),i.contentWindow&&(i.contentWindow.onresize=null,i.contentWindow.document.write(""),i.parentNode.removeChild(i),null!=(t=i.contentWindow))&&t.close()}},watchSize2:function(n,s,e){var r,h,o=document.createElement("_"),a=(o.className="expand",o.appendChild(document.createElement("_"))),u=(a.className="shrink",o.appendChild(document.createElement("_"))),t=(u.className="expandChild",a.appendChild(document.createElement("_")));return t.className="shrinkChild",a.style.cssText=o.style.cssText="height:100%;left:0;opacity:0;overflow:hidden;pointer-events:none;position:absolute;top:0;transition:0s;width:100%;z-index:-1",t.style.cssText=u.style.cssText="display:block;height:100%;transition:0s;width:100%",t.style.width=t.style.height="200%",n.appendChild(o),c(),function(){f(),n.removeChild(o)};function c(){f(),e.k=n.getBoundingClientRect(),e.M=[n.clientLeft,n.clientTop];var t=n.offsetWidth,i=n.offsetHeight;t===r&&i===h||(r=t,h=i,u.style.width=2*t+"px",u.style.height=2*i+"px",o.scrollLeft=o.scrollWidth,o.scrollTop=o.scrollHeight,a.scrollLeft=a.scrollWidth,a.scrollTop=a.scrollHeight,s(t,i)),a.addEventListener("scroll",c),o.addEventListener("scroll",c)}function f(){a.removeEventListener("scroll",c),o.removeEventListener("scroll",c)}},mousePos:function(t,i,n){return t&&(n.k=t.getBoundingClientRect(),n.M=[t.clientLeft,t.clientTop]),t=n.k,[(i=i.touches&&i.changedTouches?0<i.touches.length?i.touches[0]:i.changedTouches[i.changedTouches.length-1]:i).clientX-t.left-n.M[0],i.clientY-t.top-n.M[1]]},remove:function(t){t&&t.parentNode&&t.parentNode.removeChild(t)},empty:function(t){for(;t.firstChild;)t.removeChild(t.firstChild)},closest:function(t,i){return t?this.hasClass(t,i)?t:(t=t.parentElement)?w.closest(t,i):null:null},fillText:function(t,i){if(t)return void 0!==t.textContent?t.textContent=i:void 0!==t.innerText?t.innerText=i:t.innerHTML=i,t},_L:function(t){for(var i=document.documentElement.style,n=0;n<t.length;n+=1)if(t[n]in i)return t[n];return!1},rotate:function(t,i,n){var s,e=w.kL;n=n||{x:t.clientWidth/2,y:t.clientHeight/2},e?(s="",t.style[e]=s+=" rotate("+i+"deg)",t.style[w.ML[e]+"-origin"]=n.x+"px "+n.y+"px"):(s=Math.cos(i*Math.PI/180),e=Math.sin(i*Math.PI/180),t.style.filter="progid:DXImageTransform.Microsoft.Matrix()",0<t.filters.length&&((i=t.filters.item(0)).Dx=-n.x*s+n.y*e+n.x,i.Dy=-n.x*e-n.y*s+n.y,i.M11=i.M22=s,i.M12=-(i.M21=e)))},setCss:function(t,i){t=t instanceof Array?t:[t];for(var n=0;n<t.length;n+=1)for(var s in i)i.hasOwnProperty(s)&&(t[n].style[s]=i[s]);return this},setOpacity:function(t,i){t.style&&("opacity"in t.style?t.style.opacity=""+i:"filter"in t.style&&(i=Math.round(100*i),t.style.filter="",100!==i)&&(t.style.filter=" progid:DXImageTransform.Microsoft.Alpha(opacity="+i+")"))},ML:{},kL:K=q=!1},Q=(w.kL=w._L(["WebkitTransform","OTransform","MozTransform","msTransform","transform"]),w.ML={transform:"transform",WebkitTransform:"-webkit-transform",OTransform:"-o-transform",MozTransform:"-moz-transform",msTransform:"-ms-transform"},t.prototype.isEnabled=function(){return"disabled"!==this.R},t.prototype.isActive=function(){return"active"===this.R},t.prototype.enable=function(){this.isEnabled()||(this.R="enabled")},t.prototype.disable=function(){this.isEnabled()&&(this.R,this.R="disabled")},t.prototype.L=function(t){this.A&&(this.A=!1),t.ctrlKey||0!==t.button||(document.addEventListener("mousemove",this.T),document.addEventListener("mouseup",this.I),this.D(t))},t.prototype.P=function(t){this.Xdt=t.Hdt,1<t.touches.length?(this.j.removeEventListener("touchmove",this.T),this.R="enabled"):(this.A&&(this.A=!1),"enabled"===this.R&&(this.j.addEventListener("touchmove",this.T,{capture:!0,passive:!0}),document.addEventListener("touchend",this.oS),this.D(t)))},t.prototype.D=function(t){this.$=this.U=this.B=w.mousePos(this.j,t,this._map),this.YF=this._map.getView().getStatus().centerCoord,this.XF=this._map.containerToCoord(this.$),this.W=[[Date.now(),this.$]],this.R="active"},t.prototype.Z=function(t){var i=(new Date).getTime(),n=this.Xdt;"touchmove"===t.type&&1<t.touches.length||i-n<50||(this.W.length<2&&"active"===this.R&&this.G("dragstart",t),"touchmove"===t.type&&this.G("touchmove",t),this.G("dragging",t),this.isEnabled()&&("active"===this.R&&(this.R="pending"),"disabled"!==this.R)&&this._map.getStatus().dragEnable&&(i=w.mousePos(this.j,t,this._map),this.q=t,this.B=_.set(_.create(),i[0],i[1]),this.Y(),this.W.push([Date.now(),this.B]),this.W.length<2||(n=this._map.getView(),t=this._map.containerToCoord(i),i=[this.XF[0]-t[0]+this.YF[0],this.XF[1]-t[1]+this.YF[1]],n.setOptions({center:this._map.getProjection().unproject(i[0],i[1])}))))},t.prototype.tt=function(t){if(0===t.button)if(this.it())this.S(),this.C();else switch(this.R){case"active":this.R="enabled",this.S(),this.C();break;case"pending":this.R="enabled",this.S(),this.C(),this.et(t),this.G("dragend",t);break;default:this.R="enabled",this.S(),this.G("dragend",t)}},t.prototype.N=function(t){if(0<t.touches.length)this.$=this.U=this.B=w.mousePos(this.j,t,this._map),this.YF=this._map.getView().getStatus().centerCoord,this.XF=this._map.containerToCoord(this.$);else if(this.it())this.S(),this.C(),this.R="enabled",this.G("dragend",t);else switch(this.R){case"active":this.R="enabled",this.S(),this.C();break;case"pending":this.R="enabled",this.S(),this.C(),this.G("dragend",t),this.et(t);break;default:this.G("dragend",t),this.S()}},t.prototype.it=function(){var t,i,n,s,e=this._map.getLimitBounds();if(e=e&&e.toJSON())return t=this._map.getBounds().toJSON(),i=[],s=[(n=this._map.getCenter().toJSON())[0],n[1]],(t[0]<e[0]||t[1]<e[1]||t[2]>e[2]||t[3]>e[3])&&(i[0]=t[0]-e[0],i[1]=t[1]-e[1],i[2]=t[2]-e[2],i[3]=t[3]-e[3],i[0]<0&&0<i[2]?s[0]=(e[0]+e[2])/2:i[0]<0?s[0]=n[0]-i[0]:0<i[2]&&(s[0]=n[0]-i[2]),i[1]<0&&0<i[3]?s[1]=(e[1]+e[3])/2:i[1]<0?s[1]=n[1]-i[1]:0<i[3]&&(s[1]=n[1]-i[3]),this._map.panTo(s,100),!0)},t.prototype.S=function(){this.j.removeEventListener("touchmove",this.T),document.removeEventListener("touchend",this.oS),document.removeEventListener("mousemove",this.T),document.removeEventListener("mouseup",this.I)},t.prototype.C=function(){delete this.q,delete this.$,delete this.U,delete this.B},t.prototype.Y=function(){for(var t=this.W,i=Date.now();0<t.length&&60<i-t[0][0];)t.shift()},t.prototype.et=function(t){var i,n,s,e,r,h,o,a,u,c,f,l,d,v;function p(){this.isEnabled()&&this.A||(h=-1);var t=Date.now()-a,t=(u<t&&(h=-1),[l[0]*t+d[0]*t*t/2,l[1]*t+d[1]*t*t/2]);o=[o[0]+(t[0]-v[0]),o[1]+(t[1]-v[1])],v=t,h<=0?this.A=!1:(s.setOptions({center:_.ProjectionManager.getProjection(e.projectionId).unproject(o[0],o[1])}),_.Util.requestAnimFrame(p.bind(this)),h--)}this._map.getStatus().jogEnable&&(this.A=!0,this.Y(),(i=this.W).length<2||(n=i[i.length-1],f=i[0],c=[n[1][0]-f[1][0],n[1][1]-f[1][1]],0==(r=(n[0]-f[0])/1e3)||_.equals(n[1],f[1])?this.G("moveend",t):(f=[c[0]/(.3/r),c[1]/(.3/r)],t=Math.sqrt(f[0]*f[0]+f[1]*f[1])/750,s=this._map.getView(),r=(e=s.getStatus()).rotation,f=h=parseInt((1e3*t+400)/17+"",10),new H(.1,0,1,.1),_.V[e.projectionId].nt(-c[0]/7,c[1]/7,e.zoom),o=_.ProjectionManager.getProjection(e.projectionId).project(e.center[0],e.center[1]),a=Date.now(),u=17*f,t=i[i.length-Math.min(i.length,3)],c=[n[1][0]-t[1][0],n[1][1]-t[1][1]],0!==r&&(c=this.J(r,c)),c=_.V[e.projectionId].nt(c[0],-c[1],e.zoom),f=Math.min(t[0]-n[0],-15),l=[c[0]/f,c[1]/f],d=[-l[0]/u,-l[1]/u],v=[0,0],_.Util.requestAnimFrame(p.bind(this)))))},t.prototype.J=function(t,i){var n=Math.sqrt(i[0]*i[0]+i[1]*i[1]),s=Math.atan2(i[1],i[0]),t=t/180*Math.PI-s;return i[0]=n*Math.cos(t),i[1]=-n*Math.sin(t),i},t.prototype.G=function(t,i){this._map.getBindHandler().fireEvent(t,i)},t);function t(t,i){this.st="mouse",this.Xdt=0,this._map=i,this.W=[],this.j=t,this.R="disabled",this.T=this.Z.bind(this),this.I=this.tt.bind(this),this.oS=this.N.bind(this)}i.prototype.isEnabled=function(){return"disabled"!==this.R},i.prototype.isActive=function(){return"active"===this.R},i.prototype.enable=function(){this.isEnabled()||(this.rt=!0,this.R="enabled")},i.prototype.ht=function(){return!!this.lt},i.prototype.disable=function(){if(this.isEnabled())switch(this.R){case"enabled":case"active":this.R="disabled",this.S(),this.C();break;case"pending":this.R="disabled",this.S();break;default:this.R="disabled"}},i.prototype.ut=function(t){t.preventDefault(),"enabled"===this.R&&this._map.getStatus().doubleClickZoom&&!t.ctrlKey&&0===t.button&&this.D(t)},i.prototype.P=function(t,i){var n=this;this.$=w.mousePos(this.j,t,this._map),2===t.touches.length?(this.rt=!1,this.ct=0):(this.rt=!0,this.ct++,this.ft=i,this.lt=!1,setTimeout(function(){1===n.ct&&(n.ct=0)},300),this.pt=[t.changedTouches[0].clientX,t.changedTouches[0].clientY],this.j.addEventListener("touchmove",this.dt),2<=this.ct&&this.j.addEventListener("touchend",this.N.bind(this)))},i.prototype.vt=function(t){var i=this;this.rt&&(this.yt++,setTimeout(function(){i.yt=0},300),2===this.yt&&!this.lt&&this._map.getStatus().doubleClickZoom&&(t.preventDefault(),this.yt=0,this.ct=0,this.D(t)),2===this.ct)&&(this.ct=0)},i.prototype.D=function(i){var n,s,e=this,r=(this.lt=!0,this.R="active",this.G("zoomstart"),400),h=0,o=this._map.getView().getStatus().zoom,a=new H(.4,0,.15,1);o>=this.xt[1]||(s=0,n=function(){h+=16;var t=o+a.h(h/r);t>=e.xt[1]||(e.bt(i,t),o+1<=t&&(_.Util.cancelAnimFrame(s),e.lt=!1,e.R="enabled",e.tt(),e.N()),(e.lt||h<400)&&(s=_.Util.requestAnimFrame(n)))},s=_.Util.requestAnimFrame(n))},i.prototype.gt=function(t){var i,n,s=w.mousePos(this.j,t,this._map);s[0]-this.$[0]==0&&s[1]-this.$[1]==0||(this.yt=-1,this.ct<2?this.ct=0:this.rt&&(this.lt=!0,this.wt=!0,this.ft.disable(),s=t.changedTouches.length,i=this._map.getView(),n=this._map.getView().getStatus().zoom-(t.changedTouches[s-1].clientY-this.pt[1])/100,i.setOptions({zoom:n}),this.pt=[t.changedTouches[s-1].clientX,t.changedTouches[s-1].clientY]))},i.prototype.N=function(){this.wt&&2<=this.ct&&(this.ft.enable(),this.tt(),this.lt=!1,this.wt=!1)},i.prototype.bt=function(t,i){var n,s,e,r=this._map.getView(),o=(h=r.getStatus()).center,a=h.zoom,u=h.rotation,h=h.projectionId;this._map.getStatus().zoomEnable&&(t=w.mousePos(this.j,t,this._map),e=[this.j.clientWidth/2,this.j.clientHeight/2],s=this._t(e,t),n=Math.atan((t[1]-e[1])/(t[0]-e[0])),u=-u/180*Math.PI+n,n=[-Math.cos(u)*s,Math.sin(u)*s],t[0]-e[0]<0&&(n[0]=-n[0],n[1]=-n[1]),u=_.V[h].nt(n[0],n[1],a),s=_.V[h].nt(n[0],n[1],i),e=Math.pow(2,i-a),r.setOptions({kt:{pos:t,Mt:i,Rt:s,zt:u,scale:e,center:_.set(_.create(),o[0],o[1])}}),this.G("zooming"))},i.prototype.tt=function(t){t&&0!==t.button||(this.S(),this.C(),this.G("zoomend"))},i.prototype.S=function(){this.j.removeEventListener("dblclick",this.St),this.j.removeEventListener("touchmove",this.dt)},i.prototype.C=function(){delete this.$,delete this.U,delete this.U},i.prototype._t=function(t,i){var n=i[0]-t[0],i=i[1]-t[1];return Math.sqrt(n*n+i*i)},i.prototype.G=function(t,i){this._map.getBindHandler().fireEvent(t,i)};var $=i;function i(t,i){this.lt=!1,this.wt=!1,this.rt=!0,this.xt=_.zoomRange,this.yt=0,this.ct=0,this.pt=[0,0],this._map=i,this.j=t,this.R="disabled",this.St=this.ut.bind(this),this.dt=this.gt.bind(this)}it.prototype.isEnabled=function(){return"disabled"!==this.R},it.prototype.isActive=function(){return"active"===this.R},it.prototype.enable=function(){this.isEnabled()||(this.R="enabled")},it.prototype.disable=function(){if(this.isEnabled())switch(w.removeClass(this.j,"mapboxgl-touch-drag-pan"),this.R){case"active":this.R="disabled",this.S(),this.G("zoomstart");break;case"pending":this.R="disabled",this.S();break;default:this.R="disabled"}},it.prototype.ht=function(){return!!this.lt},it.prototype.P=function(t){2===t.touches.length&&(t.stopPropagation(),this.G("zoomstart"),this.$=[{clientX:t.touches[0].clientX,clientY:t.touches[0].clientY,pageX:t.touches[0].pageX,pageY:t.touches[0].pageY},{clientX:t.touches[1].clientX,clientY:t.touches[1].clientY,pageX:t.touches[1].pageX,pageY:t.touches[1].pageY}],this.B=this.$,t=this._map.getView(),this.zY=t.getStatus(),this.j.addEventListener("touchmove",this.T),this.j.addEventListener("touchend",this.At))},it.prototype.Z=function(t){var i,n,s,e,r,h,o,a,u,c,f,l,d,v,p,m,y,b,g,M,k;t.touches.length<2||(this.G("touchmove"),this._map.getStatus().touchZoom&&this.isEnabled()&&(this.lt=!0,i=-this.CF(t),s=(c=(n=this._map.getView()).getStatus()).rotation,e=c.center,r=c.zoom,g=c.projectionId,g=void 0===(h=c.Tt)?g:h,h=c.pitch,o=(c=this._map.getStatus()).rotateEnable,a=c.zoomEnable,u=c.pitchEnable,c=c.touchZoomCenter,f=this.MW.CY,d=l=!1,y=this.It(this.B[0],this.B[1]),p=this.It(t.touches[0],t.touches[1]),v=this.Dt(this.$[0],this.$[1]),k=this.Dt(t.touches[0],t.touches[1]),p=r+(p-y)/180,y=[((y=_.Pt(w.mousePos(this.j,this.$[0],this._map),w.mousePos(this.j,this.$[1],this._map)))[0]+y[2])/2,(y[1]+y[3])/2],b=[this.j.clientWidth/2,this.j.clientHeight/2],m=this.jt(b,y),M=Math.atan((y[1]-b[1])/(y[0]-b[0])),M=s*Math.PI/180+M,M=[-Math.cos(M)*m,Math.sin(M)*m],y[0]-b[0]<0&&(M[0]=-M[0],M[1]=-M[1]),m=_.V[g].nt(M[0],M[1],r),y=_.V[g].nt(M[0],M[1],p),b=Math.pow(2,p-r),g=this.zY.rotation+(k-v),10<Math.abs(k-v)&&(this.MW.CY=!0),.1<Math.abs(i)&&(l=f=!(d=!0)),.01<Math.abs(p-r)&&(l=!0),M=w.mousePos(this.j,this.$[0],this._map),k=w.mousePos(this.j,this.$[1],this._map),1===c?n.setOptions({pitch:u&&d?h+i:h,zoom:a&&l?p:r,rotation:o&&f?g:s}):n.setOptions({pitch:u&&d?h+i:h,kt:a&&l&&{Mt:p,Rt:y,zt:m,pos:[(M[0]+k[0])/2,(M[1]+k[1])/2],scale:b,center:_.set(_.create(),e[0],e[1])},rotation:o&&f?g:s}),this.B=[{clientX:t.touches[0].clientX,clientY:t.touches[0].clientY,pageX:t.touches[0].pageX,pageY:t.touches[0].pageY},{clientX:t.touches[1].clientX,clientY:t.touches[1].clientY,pageX:t.touches[1].pageX,pageY:t.touches[1].pageY}]))},it.prototype.CF=function(t){var i,n=this.B,s=this.$,n=[w.mousePos(this.j,n[0],this._map),w.mousePos(this.j,n[1],this._map)],s=(w.mousePos(this.j,s[0],this._map),w.mousePos(this.j,s[1],this._map),[w.mousePos(this.j,t.touches[0],this._map),w.mousePos(this.j,t.touches[1],this._map)]),t=Math.sqrt(Math.pow(n[0][0]-n[1][0],2)+Math.pow(n[0][1]-n[1][1],2)),e=Math.sqrt(Math.pow(s[0][0]-s[1][0],2)+Math.pow(s[0][1]-s[1][1],2));return 2<Math.abs(e-t)||(e=s[0][0]-n[0][0],t=s[0][1]-n[0][1],i=s[1][0]-n[1][0],s=s[1][1]-n[1][1],Math.abs(t)<Math.abs(e))||Math.abs(s)<Math.abs(i)?0:-(t+s)/2/4},it.prototype.Et=function(t){this.MW.CY=!1,this.G("zoomend"),this.S()},it.prototype.It=function(t,i){var n=i.clientX-t.clientX,i=i.clientY-t.clientY;return Math.sqrt(n*n+i*i)},it.prototype.jt=function(t,i){var n=i[0]-t[0],i=i[1]-t[1];return Math.sqrt(n*n+i*i)},it.prototype.Dt=function(t,i){var n=t.pageX-i.pageX,t=t.pageY-i.pageY;return Math.atan2(t,n)/Math.PI*180},it.prototype.S=function(){this.j.removeEventListener("touchstart",this.Nt),this.j.removeEventListener("touchmove",this.T),this.j.removeEventListener("touchend",this.At)},it.prototype.G=function(t,i){this._map.getBindHandler().fireEvent(t,i)};var tt=it;function it(t,i){this.MW={CY:!1},this._map=i,this.j=t,this.R="disabled",this.T=this.Z.bind(this),this.At=this.Et.bind(this)}var nt=4.000244140625,st=(et.prototype.isEnabled=function(){return"disabled"!==this.R},et.prototype.isActive=function(){return"active"===this.R},et.prototype.enable=function(){this.isEnabled()||(this.R="enabled")},et.prototype.disable=function(){this.isEnabled()&&(this.R="disabled",this.C(),this.G("zoomend"))},et.prototype.Ut=function(t){t.preventDefault();var i,n,s,e=this._map.getStatus();this.G("zoomstart"),this.isEnabled()&&(i=t.deltaMode===WheelEvent.DOM_DELTA_LINE?40*t.deltaY:t.deltaMode===WheelEvent.DOM_DELTA_PAGE?400*t.deltaY:t.deltaY,s=(n=Date.now())-(this.Bt||0),this.Bt=n,0!==i&&i%nt==0?this.Wt="wheel":0!==i&&Math.abs(i)<4?this.Wt="trackpad":400<s?(this.Wt=null,this.Gt=i):this.Wt||(this.Wt=Math.abs(s*i)<200?"trackpad":"wheel",this.Zt&&(i+=this.Gt)),t.shiftKey&&i&&(i/=4),e&&e.zoomSpeed&&(i*=e.zoomSpeed),this.Wt)&&(this.$t-=i,this.isActive()||this.D(t))},et.prototype.D=function(t){var i,n,s,e,r,h,o,a,u;this.$t&&(a=(e=(i=this._map.getView()).getStatus()).rotation,n=e.zoom,s=e.center,e=e.projectionId,h="wheel"===this.Wt&&Math.abs(this.$t)>nt?1/450:.01,h=2/(1+Math.exp(-Math.abs(this.$t*h))),this.$t<0&&0!==h&&(h=1/h),r=this.Yt(n),r=Math.min(this._map.getZooms()[1],Math.max(2,this.Vt(r*h))),h=w.mousePos(this.j,t,this._map),t=[this.j.clientWidth/2,this.j.clientHeight/2],u=this._t(t,h),o=Math.atan((h[1]-t[1])/(h[0]-t[0])),a=-a/180*Math.PI+o,o=[-Math.cos(a)*u,Math.sin(a)*u],h[0]-t[0]<0&&(o[0]=-o[0],o[1]=-o[1]),a=_.V[e].nt(o[0],o[1],n),u=_.V[e].nt(o[0],o[1],r),t=Math.pow(2,r-n),this._map.XT(o),i.setOptions({kt:{pos:h,Mt:r,Rt:u,zt:a,scale:t,center:_.set(_.create(),s[0],s[1])}}),this.$t=0)},et.prototype.Yt=function(t){return Math.pow(2,t)},et.prototype.Vt=function(t){return Math.log(t)/Math.LN2},et.prototype._t=function(t,i){var n=i[0]-t[0],i=i[1]-t[1];return Math.sqrt(n*n+i*i)},et.prototype.C=function(){delete this.q,delete this.$,delete this.U,delete this.B},et.prototype.G=function(t,i){this._map.getBindHandler().fireEvent(t,i)},et);function et(t,i){this._map=i,this.j=t,this.R="disabled",this.Wt="wheel",this.$t=0}ht.prototype.isEnabled=function(){return"disabled"!==this.R},ht.prototype.isActive=function(){return"active"===this.R},ht.prototype.enable=function(){this.isEnabled()||(this.R="enabled")},ht.prototype.disable=function(){if(this.isEnabled()){switch(this.R){case"active":this.S(),this.C();break;case"pending":this.S()}this.R="disabled"}},ht.prototype.L=function(t){this.A&&clearInterval(this.A),(2===t.button||t.ctrlKey&&0===t.button)&&(this.j.addEventListener("mousemove",this.T,{passive:!0}),this.j.addEventListener("mouseup",this.I),this.j.addEventListener("mouseleave",this.I),this.D(t))},ht.prototype.D=function(t){this.$=this.U=this.B=w.mousePos(this.j,t,this._map),this.W=[[Date.now(),this.$]],this.R="active"},ht.prototype.Z=function(t){var i,n,s;this.W.length<2&&"active"===this.R&&this.G("dragstart",t),this.G("dragging",t),this.isEnabled()&&(n=w.mousePos(this.j,t,this._map),this.q=t,this.B=_.set(_.create(),n[0],n[1]),this.Y(),this.W.push([Date.now(),this.B]),this.W.length<2||("active"===this.R&&(this.R="pending"),"disabled"!==this.R&&(i=(n=(t=this._map.getView()).getStatus()).rotation,n=n.pitch,s=[this.B[0]-this.W[this.W.length-2][1][0],this.B[1]-this.W[this.W.length-2][1][1]],(!this._map.getStatus().pitchEnable||Math.abs(s[0])>Math.abs(s[1]))&&(s[1]=0),(!this._map.getStatus().rotateEnable||Math.abs(s[0])<Math.abs(s[1]))&&(s[0]=0),15<Math.abs(this.B[0]-this.$[0])&&(this.B[1]>this.j.clientHeight/2?i-=s[0]/10:i+=s[0]/10),n-=s[1]/this._map.getZooms()[1]*2,t.setOptions({rotation:i,pitch:n}))))},ht.prototype.tt=function(t){switch(this.R){case"active":this.R="enabled",this.C();break;case"pending":this.R="enabled",this.G("dragend",t);break;default:this.G("dragend",t)}this.S()},ht.prototype.S=function(){this.j.removeEventListener("mousemove",this.T),this.j.removeEventListener("mouseup",this.I),this.j.removeEventListener("mouseleave",this.I)},ht.prototype.C=function(){delete this.q,delete this.$,delete this.U,delete this.B},ht.prototype.Y=function(){for(var t=this.W,i=Date.now();0<t.length&&160<i-t[0][0];)t.shift()},ht.prototype.G=function(t,i){this._map.getBindHandler().fireEvent(t,i)};var rt=ht;function ht(t,i){this._map=i,this.W=[],this.j=t,this.R="disabled",this.T=this.Z.bind(this),this.I=this.tt.bind(this)}n.prototype.Xt=function(){this._container.addEventListener("mouseenter",this.DL.bind(this)),this._container.addEventListener("mouseover",this.OL.bind(this)),this._container.addEventListener("mouseleave",this.PL.bind(this)),this._container.addEventListener("mouseup",this.tt.bind(this)),this._container.addEventListener("mouseout",this.BL.bind(this)),this._container.addEventListener("mousemove",this.jL.bind(this)),this._container.addEventListener("mousedown",this.Jt.bind(this)),this._container.addEventListener("touchend",this.N.bind(this)),this._container.addEventListener("touchstart",this.Kt.bind(this),!1),this._container.addEventListener("touchmove",this.gt.bind(this),!1),this._container.addEventListener("wheel",this.Qt.bind(this),{passive:!1}),this._container.addEventListener("contextmenu",this.EL.bind(this)),this._container.addEventListener("keydown",this.ii.bind(this))},n.prototype.fireEvent=function(t,i){if(i){i.Adt=t;var n=this._map.getStatus();if("scrollWheel"===t){if(!n.scrollWheel)return void this.oi.disable();this.oi.enable()}var s,r=(e=w.mousePos(this._container,i,this._map))[0],e=e[1],o=(h=this._map.getView().containerTolnglat(r,e))[0],h=h[1];if("mousemove"===t&&this.ri&&this.ri.P$)s=this.ri;else if("dragstart"===t||"dragging"===t||"dragend"===t)switch(t){case"dragstart":s=!n.pickWhenMoving&&this._map.TL()?this.ri:this.si(i),this.ri=s;break;case"dragging":s=this.ri;break;case"dragend":s=this.ri,this.ri=void 0}else s=!n.pickWhenMoving&&this._map.TL()?this.ri:this.si(i);var a=this.hi(s,t),u=new _.LngLat(o,h),o={lnglat:u,target:s,pixel:r=new _.Pixel(r,e),originEvent:i,pos:e=this._map.getProjection().project(o,h),vectorIndex:0},h=(s&&(o.vectorIndex=s&&s.iE&&i.lnglat&&s.iE(i.lnglat)||0),-1!==["mouseover","mousemove","mouseout","mouseenter","mouseleave"].indexOf(t)?this.ui(t,o):s&&this.ci(s,t,o),o.target),o={lnglat:u,target:s,pixel:r,originEvent:i,pos:e};h&&"poi"!==h.type&&!a||(o.target=this._map),s&&"poi"===s.type||s&&a?this._map.emit(t,o):"dblclick"===t&&s?this.fi.disable():"dragstart"!==t&&"dragging"!==t&&"dragend"!==t||!s||!s.getDraggable()&&"AMap.InfoWindow"!==s.type&&"AMap.ContextMenu"!==s.type?s||(n.dragEnable||"dragging"!==t&&"dragstart"!==t&&"dragend"!==t)&&this._map.emit(t,o):"dragend"===t?this.ft.enable():this.ft.disable()}},n.prototype.hi=function(t,i){return!!t&&"poi"!==t.type&&!("dragstart"===i||"dragging"===i||"dragend"===i||!this._map.getStatus().allBubble&&!Boolean(t.getOptions().bubble))},n.prototype.ti=function(t){this.fi.enable(),this.fireEvent("dblclick",t),this.fi.ut(t)},n.prototype.Jt=function(t){this._map.cancelMapAnimate(),this.Ht="mousedown",this.fireEvent("mousedown",t),this.ft.enable(),this.ft.L(t),this.ei.L(t),this.$=w.mousePos(this._container,t,this._map)},n.prototype.OL=function(t){this.fireEvent("mouseover",t)},n.prototype.DL=function(t){this.fireEvent("mouseenter",t)},n.prototype.PL=function(t){this.fireEvent("mouseleave",t)},n.prototype.BL=function(t){this.fireEvent("mouseout",t)},n.prototype.tt=function(t){var i=this;"mousedown"!==this.Ht||t.ctrlKey||(setTimeout(function(){i.nB=0},300),this.Ht="false",2===t.button?this.fireEvent("rightclick",t):(this.nB++,2<=this.nB?(this.fi.enable(),this.fireEvent("dblclick",t),this.fi.ut(t),this.nB=0):this.fireEvent("click",t))),this.fireEvent("mouseup",t)},n.prototype.FL=function(t){"move"!==this.Ht&&this.fireEvent("click",t)},n.prototype.jL=function(t){var i;"mousedown"===this.Ht&&(i=w.mousePos(this._container,t,this._map),1<Math.abs(this.$[0]-i[0])||1<Math.abs(this.$[1]-i[1]))&&(this.Ht="move"),this.fireEvent("mousemove",t)},n.prototype.Kt=function(t){var i=this;"infoWindow"!==t.cH&&"markerContent"!==t.cH&&t.cancelable&&t.preventDefault(),this.oB="touchstart",this.$=w.mousePos(this._container,t,this._map),this._map.cancelMapAnimate(),this.fireEvent("touchstart",t),this.rB=(new Date).getTime(),t.Hdt=this.rB,this.ft.enable(),this.ft.P(t),this.fi.P(t,this.ft),this.ni.P(t),clearTimeout(this.aB),1===t.touches.length&&(this.aB=setTimeout(function(){i.fireEvent("rightclick",t)},800))},n.prototype.gt=function(t){this.$&&(t=w.mousePos(this._container,t,this._map),1<Math.abs(t[0]-this.$[0])||1<Math.abs(t[1]-this.$[1]))&&"touchstart"===this.oB&&(this.oB="touchmove")},n.prototype.N=function(t){var i=this,n=(new Date).getTime();this.fireEvent("touchend",t),clearTimeout(this.aB),"touchstart"===this.oB&&n-this.rB<800&&(this.oB="false",this.fireEvent("click",t),setTimeout(function(){i.dH=0},300),this.dH++,2<=this.dH)&&(this.fireEvent("dblclick",t),this.dH=0),this.fi.vt(t)},n.prototype.Qt=function(t){this._map.cancelMapAnimate(),this.fireEvent("mousewheel",t),this._map.getStatus().scrollWheel&&(t.preventDefault(),this.ft.disable(),this.oi.Ut(t))},n.prototype.EL=function(t){t.ctrlKey,t.preventDefault()},n.prototype.si=function(t){for(var i,s=(n=this._map).DF(),e=n.pi,r=n.di,n=n.vm,h=s.concat([e,r,n]),e=(s=w.mousePos(this._container,t,this._map))[0],r=s[1],s=(n=this._map.getView().containerTolnglat(e,r))[0],n=n[1],o=(t.lnglat=new _.LngLat(s,n),t.pixel=new _.Pixel(e,r),h.length-1);0<=o;o--){var a=h[o];if(a=a&&a.vi(t)){if(!a.getOptions){i=a;break}if(!0!==a.getOptions().noSelect){i=a;break}}}return i},n.prototype.ui=function(t,i){var s=void 0===(s=(n=this.mi).yi)?null:s,e=void 0===(e=n.xi)?null:e,n=n.vectorIndex,r=i.target;"mousemove"!==t&&"mouseleave"!==t||("mousemove"===t?s?r?s.hS!==r.hS||(void 0===n?-1:n)!==i.vectorIndex?(this.ci(s,"mouseout",e),this.ci(r,"mouseover",i)):this.ci(r,"mousemove",i):this.ci(s,"mouseout",e):r&&this.ci(r,"mouseover",i):"mouseleave"===t&&s&&this.ci(s,"mouseout",e),this.mi.yi=r,this.mi.vectorIndex=i.vectorIndex,this.mi.xi=i)},n.prototype.ci=function(t,i,n){"poi"===t.type?this._map.getStatus().isHotspot&&this.bi(t,i,n):t.emit(i,n)},n.prototype.bi=function(t,i,n){var s,e,r,h="hotspot";switch(i){case"click":this._map.setCursor("pointer"),s=h+i;break;case"mouseover":this._map.setCursor("pointer"),s=h+"over";break;case"mouseout":this._map.setCursor(""),s=h+"out"}s&&(e=(r=this._map.getProjection().unproject(t.lnglat[0],t.lnglat[1]))[0],r=r[1],t={type:s,id:t.id,name:t.name,lnglat:new _.LngLat(e,r),originEvent:n.originEvent},this._map.emit(s,t))},n.prototype.ii=function(t){var i,n;this._map.getStatus().keyboardEnable&&(i=this._map.getZoom(),n=this._map.getRotation(),"="===t.key?this._map.setZoom(i+1,!0):"-"===t.key&&this._map.setZoom(i-1,!0),t.ctrlKey?"ArrowLeft"===t.key?this._map.setRotation(n-90,!0):"ArrowRight"===t.key&&this._map.setRotation(n+90,!0):"ArrowUp"===t.key?this._map.panBy(0,300):"ArrowDown"===t.key?this._map.panBy(0,-300):"ArrowLeft"===t.key?this._map.panBy(300,0):"ArrowRight"===t.key&&this._map.panBy(-300,0))};var ot=n;function n(t){this.Ht="false",this.oB="false",this.nB=0,this.dH=0,this.aB=0,this.rB=0,this.mi={yi:null,xi:null},this._map=t,this._container=this._map.getMapsContainer(),this.ft=new Q(this._container,t),this.ft.enable(),this.oi=new st(this._container,t),this.oi.enable(),this.fi=new $(this._container,t),this.fi.enable(),this.ni=new tt(this._container,t),this.ni.enable(),this.ei=new rt(this._container,t),this.ei.enable()}var at,ut=new _.rW({}),ct=(at=_.Event,_.Ei(ft,at),ft.prototype.lo=function(){return this.Oo},ft.prototype.destroy=function(){},ft.prototype.Fo=function(t){!t||t===this.Oo||this.pS||this.Oo||(this.pS=!0,this.Oo=!0,this.emit("complete"))},ft.prototype.VE=function(t,i,n){for(var s=this.lZ(),e=[],r=0;r<t.length;r++){var h=t[r],h=_.ProjectionManager.getProjection("EPSG:3857").unproject(h[0],h[1]);e.push(h)}var o=s.boundsP16;i&&"china"===i?o=[o[0]]:i&&"oversea"===i&&(o=s.nebulaOutSea);for(var a=0;a<o.length;a++){var u=o[a];if(ut.isRingInRingByOutsea(e,u[0]))return!0}return!1},ft.prototype.rG=function(t,i){for(var n=this.lZ(),s=[],e=0;e<t.length;e++){var r=t[e],r=_.ProjectionManager.getProjection("EPSG:3857").unproject(r[0],r[1]);s.push(r)}for(var h=n.boundsP16,o=0;o<h.length;o++){var a=h[o];if(ut.isRingInRingByMapbox(s,a[0]))return!0}return!1},ft.prototype.aU=function(t,i){for(var n=this.lZ(),s=[],e=0;e<t.length;e++){var r=t[e],r=_.ProjectionManager.getProjection("EPSG:3857").unproject(r[0],r[1]);s.push(r)}for(var h=n.boundsP16,o=0;o<h.length;o++){var a=h[o];if(ut.isRingInRingByMapboxB(s,a[0]))return!0}return!1},ft.prototype.sU=function(t){for(var i=this.lZ().boundsP16,n=i.length,s=t.projectionId,e=[],r=0;r<n;r++){var h=i[r],h=_.V[s].Xs(h[0],h[1],16);e.push(h[0]),e.push(h[1])}return e},ft.prototype.UH=function(t){},ft.prototype.Eo=function(){this.map.setNeedUpdate(!0)},ft.prototype.lZ=function(){var t=this.map.getOutseaDataType();return _.vZ(t)},_.dZ([_.pZ("Source")],ft));function ft(t,i,n,s){var e=at.call(this)||this;return e.map=n,e.layer=s,e.Oo=!1,e.pS=!1,e._id=t.id,e.Wt=t.type,e._tileUrl=t.tileUrl,t.url&&(e.$o=t.url),e}Object.defineProperty(dt.prototype,"size",{get:function(){return _.keys(this.VL).length},eb:!1,nb:!0}),dt.prototype.clear=function(){this.VL={}},dt.prototype.set=function(t,i){this.VL[t]=i},dt.prototype.get=function(t){return this.VL[t]},dt.prototype.delete=function(t){delete this.VL[t]},dt.prototype.has=function(t){return void 0!==this.VL[t]};var lt=dt;function dt(){this.VL={}}var h="newer",o="older",s=(e.prototype.Uo=function(t){var i=this.Bo;(this.Bo=t)<i&&this.MN()},e.prototype.keys=function(){return new pt(this.Wo)},e.prototype.values=function(){return new yt(this.Wo)},e.prototype.entries=function(){return this},e.prototype.forEach=function(t,i){"object"!=typeof i&&(i=this);for(var n=this.Wo;n;)t.call(i,n.value,n.key,this),n=n[h]},e.prototype.toJSON=function(){for(var t=new Array(this.size),i=0,n=this.Wo;n;)t[i++]={key:n.key,value:n.value},n=n[h];return t},e.prototype.toString=function(){for(var t="",i=this.Wo;i;)t+=String(i.key)+":"+i.value,(i=i[h])&&(t+=" < ");return t},e.prototype.Go=function(t){t!==this.Zo&&(t[h]&&(t===this.Wo&&(this.Wo=t[h]),t[h][o]=t[o]),t[o]&&(t[o][h]=t[h]),t[h]=void 0,t[o]=this.Zo,this.Zo&&(this.Zo[h]=t),this.Zo=t)},e.prototype.assign=function(t){for(var i,n=this.Bo||Number.MAX_VALUE,s=(this.qo.clear(),t),e=s.next();!e.done;e=s.next()){var r=new vt(e.value[0],e.value[1]);if(this.qo.set(r.key,r),i?(i[h]=r)[o]=i:this.Wo=r,i=r,0==n--)throw new Error("overflow")}this.Zo=i,this.size=this.qo.size},e.prototype.get=function(t,i){if(t=this.qo.get(t))return i&&this.Go(t),t.value},e.prototype.set=function(t,i){var n=this.qo.get(t);return n?(n.value=i,this.Go(n)):(this.qo.set(t,n=new vt(t,i)),this.Zo?(this.Zo[h]=n)[o]=this.Zo:this.Wo=n,this.Zo=n,++this.size,this.size>this.Bo&&this.MN()),this},e.prototype.shift=function(){var t=this.Wo;if(t)return this.Wo[h]?(this.Wo=this.Wo[h],this.Wo[o]=void 0):(this.Wo=void 0,this.Zo=void 0),t[h]=t[o]=void 0,t.value.destroy(),this.qo.delete(t.key),--this.size,[t.key,t.value]},e.prototype.find=function(t){return(t=this.qo.get(t))?t.value:void 0},e.prototype.has=function(t){return this.qo.has(t)},e.prototype.delete=function(t){if(t=this.qo.get(t))return this.qo.delete(t.key),t[h]&&t[o]?(t[o][h]=t[h],t[h][o]=t[o]):t[h]?(t[h][o]=void 0,this.Wo=t[h]):t[o]?(t[o][h]=void 0,this.Zo=t[o]):this.Wo=this.Zo=void 0,this.size--,t.value},e.prototype.clear=function(){this.Wo=this.Zo=void 0,this.size=0,this.qo.clear()},e.prototype.AN=function(t){return"loaded"!==t.value.status||(t=t.value.stamp)&&this.wN&&t===this.wN},e.prototype.QF=function(t){this.wN=t},e.prototype.MN=function(){if(this.Wo&&this.Zo)for(var t=this.Wo,i=this.Zo.key;t&&i&&t.key!==i;){if(this.AN(t))this.Go(t);else if(this.shift(),this.size<=this.Bo)return;t=this.Wo}},e);function e(t,i){this.entries=i,"number"!=typeof(this.Bo=t)&&(i=t,t=0),this.size=0,this.Bo=t,this.Wo=this.Zo=void 0,this.qo=new("undefined"!=typeof Map?Map:lt),i&&(this.assign(i),t<1)&&(this.Bo=this.size)}var vt=function(t,i){this.key=t,this.value=i,this[h]=void 0,this[o]=void 0},pt=(mt.prototype.next=function(){var t=this.Yo;return t?(this.Yo=t[h],{done:!1,value:t.key}):{done:!0,value:void 0}},mt);function mt(t){this.Vo=t}bt.prototype.next=function(){var t=this.Yo;return t?(this.Yo=t[h],{done:!1,value:t.value}):{done:!0,value:void 0}};var yt=bt;function bt(t){this.Vo=t}gt=s,_.Ei(kt,gt),kt.prototype.shift=function(){var t=this.Wo;if(t)return this.Wo[h]?(this.Wo=this.Wo[h],this.Wo[o]=void 0):(this.Wo=void 0,this.Zo=void 0),t[h]=t[o]=void 0,this.qo.delete(t.key),this.emit("delete",{key:t.key}),--this.size,[t.key,t.value]},kt.prototype.on=function(t,i,n,s){void 0===n&&(n=this),void 0===s&&(s=!1);for(var e=0,r=Array.isArray(t)?t:[t];e<r.length;e++){var h=r[e];this._on(h,i,n,s)}return this},kt.prototype.off=function(t,i,n){void 0===n&&(n=this);var s=this.vI;if(t in s)for(var e=0;e<s[t].length;e+=1)if(s[t][e].fn===i&&s[t][e].context===n)return s[t].splice(e,1),this;return this},kt.prototype.hasEvents=function(t,i,n){void 0===n&&(n=this);var s=this.vI;if(t&&i&&t in s)for(var e=0;e<s[t].length;e+=1)if(s[t][e].fn===i&&s[t][e].context===n)return!0;return!1},kt.prototype.clearEvents=function(t){return t?this.vI[t]&&delete this.vI[t]:this.vI={},this},kt.prototype.emit=function(t,i){if(void 0===i&&(i={}),t in this.vI)for(var n=_.Ln(_.Ln({},i),{type:t}),s=this.vI[t],e=0,r=s.length;e<r;e+=1){var h=s[e];h.fn&&(h.fn.call(h.context,n),h.once)&&(this.vI[t].splice(e,1),--e,--r)}return this},kt.prototype._on=function(t,i,n,s){var e;return void 0===s&&(s=!1),this.hasEvents(t,i,n=void 0===n?this:n)||((e=this.vI)[t]=e[t]||[],e[t].push({fn:i,context:n||this,once:s})),this};var gt,Mt=kt;function kt(){var t=null!==gt&>.apply(this,arguments)||this;return t.vI={},t}wt=_.Event,_.Ei(At,wt),At.prototype.QF=function(t){this.Ho.QF(t)},At.prototype.Xo=function(t){this.Ho.Uo(t)},At.prototype.Jo=function(t){var i=this.ia(t.zo);this.keys[i]=1,this.Ho.set(i,t)},At.prototype.Qo=function(t){var i=this.ia(t.zo);this.Ho.set(i,t)},At.prototype.getTile=function(t,i){return void 0===i&&(i=!0),this.Ko(t)?this.Ho.get(this.ia(t),i):null},At.prototype.xf=function(t,i){return void 0===i&&(i=!1),this.Ho.has(t)?this.Ho.get(t,i):null},At.prototype.ea=function(t){var i=this.ia(t.zo);return!!this.Ko(t.zo)&&(this.Ho.delete(i),delete this.keys[i],!0)},At.prototype.Ko=function(t){return t=this.ia(t),!!this.Ho.has(t)},At.prototype.destroy=function(){this.Ho.clear()},At.prototype.forEach=function(t){this.Ho.forEach(t)},At.prototype.ia=function(t){var i;return t.key||(i=t.z+","+t.x+","+t.y,t.key=i)};var wt,xt=_.dZ([_.pZ("TileCache")],At);function At(t){void 0===t&&(t=500);var i=wt.call(this)||this;return i.keys={},i.na=t,i.Ho=new Mt(i.na),i}zt=xt,_.Ei(St,zt),St.prototype.MD=function(t,i){void 0===i&&(i=_.zB.ALL);var n="";return t?i!==t&&(n="all"===t?"":i===_.zB.ALL?t?t===_.zB.LITE?_.zB.LEFT:_.zB.LITE:_.zB.ALL:i):n=i,n},St.prototype.ea=function(t){return t.rN(),zt.prototype.ea.call(this,t)};var zt,Ct=St;function St(t){return t=zt.call(this,t=void 0===t?500:t)||this,_.Event.extend("delete",t.Ho,t),t}Tt=xt,_.Ei(It,Tt);var Tt,Lt=It;function It(t){return t=Tt.call(this,t=void 0===t?500:t)||this,_.Event.extend("delete",t.Ho,t),t}Ot.prototype.Uo=function(t){this.Bo=t},Ot.prototype._B=function(t,i,n,s){void 0===s&&(s=this.Bo);for(var e=n||"china",r=0;r<t.length;r+=s){var h=t.slice(r,r+s),o=this.qN++,h={wD:this.target(h,o,i,e),ZN:h,id:o};this.KN.push(h),this.YN[o]=h}},Ot.prototype.qH=function(t){for(var i=[],n=[],s=0,e=this.KN;s<e.length;s++)for(var r=e[s],h=0;h<r.ZN.length;h++){var o=r.ZN[h];if(this.QN(t,o)){Array.prototype.push.apply(i,r.ZN);break}h===r.ZN.length-1&&n.push(r)}for(var a=0,u=n;a<u.length;a++){(r=u[a]).wD&&r.wD.cancel();var c=this.KN.indexOf(r);this.KN.splice(c,1),delete this.YN[r.id],this.JN(r.ZN)}return{yB:i,SB:n}},Ot.prototype.QN=function(t,i){return-1<t.indexOf(i.slice(0,-2))},Ot.prototype.CB=function(t){var i=this.YN[t];delete this.YN[t],i&&(t=this.KN.indexOf(i),this.KN.splice(t,1))};var Dt=Ot;function Ot(t,i,n){void 0===n&&(n=5),this.target=t,this.JN=i,this.Bo=n,this.qN=0,this.KN=[],this.YN={}}var Rt,Et=_.Support.scale,s=(Rt=ct,_.Ei(r,Rt),r.prototype.loadData=function(t,i,n,s){var e=this;if("optimise"===s.loadData()&&s.TL())return!1;this.aa=t,this.sa=[];for(var r=t.bounds,h=this.ra(t.optimalZoom),o=this.ha(r,h),a=[],u=t.optimalZoom,r=_.map(o,function(t){var i=e.fa(t.x,t.z);return t.z+","+i+","+t.y}),c=this.QH.qH(r),f=[],l=0;l<o.length;l++){var d,v,p=o[l],m=new _.ca(p.z,this.fa(p.x,p.z),p.y),y=new _.ca(p.z,p.x,p.y),b=_.Util.kD(m.key,u),g=this.ua.getTile(m,!0);g?(d=this.ua.MD(g.tag,b))&&(g.tag=b,v=p.key+","+_.Util.SD(d),c.yB.indexOf(v)<0)&&f.push(v):(v=m.key+","+_.Util.SD(b),c.yB.indexOf(v)<0&&((m=new _.pa(m)).status=_.TileState.LOADING,m.xB=_.TileState.LOADING,this.ua.Jo(m),m.tag=b,m.gB=b,f.push(v))),!g||g.status!==_.TileState.LOADED&&g.status!==_.TileState.RELOADING||this.sa.push(y),g&&(g.status===_.TileState.LOADED||g.status===_.TileState.RELOADING)||a.push(p),g&&g.status===_.TileState.LOADED&&g.version&&g.version!==this.VH&&(this.sa.push(y),g.status=_.TileState.RELOADING,f.push(p.key+","+_.Util.SD(g.tag)),d=this.ua.MD(g.tag,b))&&(v=p.key+","+_.Util.SD(d),c.yB.indexOf(v)<0)&&f.push(v)}this.da(t,this.sa,a,s);var M,k,w,x,r=this.map.getOutseaState(),A=this.map.getOutseaDataType();return r&&!A?9.8<=h?(M=(w=this.OE(f)).overseaTile,x=w.chinaTile,k=w.mapboxTile,this.PE(M,"oversea"),this.PE(x,"china"),this.PE(k,"mapbox"),this.zD(x,t,h,s,n),this.zD(M,t,h,s,n,void 0,"outsea")):(this.PE(f,"china"),this.zD(f,t,h,s,n,void 0,"a00")):r&&A&&"mapbox"===A?9.8<=u?(x=(w=this.OE(f)).chinaTile,this.PE(x,"china"),this.zD(x,t,h,s,n,void 0)):(this.PE(f,"china"),this.zD(f,t,h,s,n,void 0,"a00")):(this.PE(f,"china"),this.zD(f,t,h,s,n,void 0)),0===f.length},r.prototype.getData=function(i){var n=this,t=i.bounds,s=this.ra(i.optimalZoom),e=this.ha(t,s),r=[],h={},o=(14===s&&(h=this.ha(t,15,!0)),this.map.qF());if(this.ua.QF(o),this.sa.sort(function(t){return n.ra(i.optimalZoom)===t.z?1:-1}),0<this.sa.length)for(var a=0;a<this.sa.length;a++){var u,c=this.sa[a],f=this.ua.getTile(c,!0),l=0,d=0,v=[0,0],p=i.centerCoord;f?(p=_.lcs.getLocalByCoord([p[0],p[1]]),i.optimalZoom>=_.Ra?(u=_.lcs.getSize(),l=f.localCoord.x-p.x,d=f.localCoord.y-p.y,0!=l&&(l*=u[0],v[0]=l),0!=d&&(d*=u[1],v[1]=d),i.optimalZoom>=_.Ra&&_.za>=f.zo.z&&(v[0]=-p.center[0],v[1]=-p.center[1])):i.optimalZoom<_.Ra&&_.za<f.zo.z&&(v[0]=p.center[0],v[1]=p.center[1])):(l=new _.ca(c.z,this.fa(c.x,c.z),c.y),(d=this.ua.getTile(l,!0))&&(f=new _.pa(c),u=1<<c.z,(c.x<0||c.x>=u)&&(p=Math.floor(c.x/u),v[0]+=20037508.342789244*p*2),l=d.tag,f.Ro=d.Ro,f.ID(d),f.Sa=v,f.status=d.status,f.tag=l)),f&&(f.stamp=o,f.Sa=v,r.push(f))}var m=i.optimalZoom,t=_.every(e,function(s){return _.some(r,function(t){var i=t.zo.key,n=t.zo.z,n=_.Util.VF(n,m),t=t.tag,t=_.Util.LD(t,n);return i===s.key&&t})}),y=this.map.getOutseaState(),b=this.map.getOutseaDataType(),e=(y&&!b&&(t=!(b=_.filter(e,function(t){return!(t=n.NE.getTile(t))||!t.boundsStatus||!1!==t.boundsStatus.isInNebulaOversea})).length||_.every(b,function(s){return _.some(r,function(t){var i=t.zo.key,n=t.zo.z,n=_.Util.VF(n,m),t=t.tag,t=_.Util.LD(t,n);return i===s.key&&t})})),this.jE(r)),b=(t&&(this.a_=!0,this.map.bZ.dynamic.set("firstAllLoaded",!0)),e&&this.map.bZ.dynamic.set("firstLabelDataAllLoaded",!0),{s_:this.a_,fo:!!t&&e,yZ:e,tiles:r,Ca:h,outseaData:void 0});return 0!==r.length&&!t||this.Fo(!0),y&&r.length&&(e=this.map.bZ.MZ.wZ.gZ(),b.outseaData=e),b.tiles=this.UE(r,s),b},r.prototype.pe=function(t){return t=new _.ca(t[0],t[1],t[2]),this.ua.getTile(t)},r.prototype.ZE=function(t){return!1},r.prototype.OE=function(t){for(var i=t.length,n=[],s=[],e=[],r=0;r<i;r++){var h=void 0,o=void 0,a=t[r],u=a.split(","),c=new _.ca(u[0],u[1],u[2]),f=this.NE.getTile(c);if(f&&f.boundsStatus)h=f.boundsStatus.isInChina,o=f.boundsStatus.isInNebulaOversea;else{if(!(f=_.wa.ga(parseInt(u[1],10),parseInt(u[2],10),parseInt(u[0],10),"EPSG:3857")))continue;u=[[f[0],f[1]],[f[2],f[1]],[f[2],f[3]],[f[0],f[3]]],h=this.VE(u,"china",a),o=this.VE(u,"oversea",a),(f=new _.pa(c)).boundsStatus={isInChina:h,isInNebulaOversea:o},this.NE.Jo(f)}h&&n.push(a),o&&s.push(a),h||o||e.push(a)}return{chinaTile:n,overseaTile:s,mapboxTile:e}},r.prototype.ra=function(t){return("fast"!==this.map.bZ.MZ.drawMode||this.map.bZ.dynamic.get("firstPaint")?{2:3,3:3,4:3,5:3,6:6,7:6,8:8,9:8,10:10,11:10,12:10,13:12,14:12,15:14,16:14,17:14,18:14,19:14,20:14,21:14,22:14,23:14,24:14,25:14,26:14,27:14,28:14,29:14,30:14}:{2:3,3:3,4:3,5:3,6:6,7:6,8:8,9:8,10:8,11:8,12:8,13:12,14:12,15:14,16:14,17:14,18:14,19:14,20:14,21:14,22:14,23:14,24:14,25:14,26:14,27:14,28:14,29:14,30:14})[t]},r.prototype.YE=function(t){var i=this;return t(null,{GW:"worker",cb:function(t){i.dynamicTextVerticeLoadedByTile(t)}}),!0},r.prototype.destroy=function(){this.ua.forEach(function(t){t.status!==_.TileState.LOADED&&t.request&&(t.request.cancel(),delete t.request),t.destroy()}),this.ua.destroy(),this.sa=[],this.la=[],this.mapStyle&&this.mapStyle.destroy&&(this.mapStyle.destroy(),delete this.mapStyle),this.R_&&this.R_.destroy&&(this.R_.destroy(),delete this.R_)},r.prototype.reload=function(){this.ua.forEach(function(t){t.status!==_.TileState.LOADED&&t.request&&(t.request.cancel(),delete t.request),t.reload()}),this.sa=[],this.la=[]},r.prototype.Aa=function(t){var i;t.zo&&(i=this.ua.getTile(t.zo))&&(i.rO({Ta:!0},t.tag),i.xa({Ta:!0},t.tag),i.JE({Ta:!0},t.tag))},r.prototype.setTileCacheSize=function(t){t=t||(_.Support.$e?50:200),this.ua.Xo(t)},r.prototype.UH=function(t){this.VH=t},r.prototype.dynamicTextVerticeLoaded=function(t){console.log("errorr")},r.prototype.dynamicTextVerticeLoadedByTile=function(t){for(var i=0,n=t.data;i<n.length;i++){var s=n[i];this.dynamicTextVerticeLoaded({data:s.data,tag:s.tag,XE:s.XE})}},r.prototype.Ia=function(){this.map.on("tileSdfInfoFinished",this.Aa.bind(this))},r.prototype.zD=function(t,i,n,s,e,r,h){void 0===r&&(r="road,building,region");var a={},o=((o=this.cP())&&(a=o.getState().vS),a=_.Ln(_.Ln({},a),{buildingColor:_.Ln({},s.getBuildingColor())}),{zoom:i.zoom,optimalZoom:i.optimalZoom,projectionId:i.projectionId,mS:a,viewMode:i.viewMode,showBuildingBlock:this.map.yS(),ZL:i.zoom,hH:r});this.QH._B(t,o,h)},r.prototype.cP=function(){for(var t,i=this.map.getLayers(),n=0;n<i.length;n++)if("AMap.Buildings"===(s=i[n]).CLASS_NAME&&!s.getState().u$){t=s;break}if(!t)for(var s,n=0;n<i.length;n++)if("AMap.Buildings"===(s=i[n]).CLASS_NAME){t=s;break}return t},r.prototype.ma=function(t,i){var n,s=new RegExp(/\{(\w|\,)+\}/g);return s.test(this._tileUrl)?(n=this._tileUrl.match(s)[0].replace(/[\{|\}]/g,"").split(","),this._tileUrl.replace(s,n[(t+i)%4])):this._tileUrl},r.prototype.AD=function(){var t=new RegExp(/\{(\w|\,)+\}/g),i=this._tileUrl.match(t)[0].replace(/[\{|\}]/g,"").split(","),n=i.length,t=this._tileUrl.replace(t,i[this.$D%n]);return this.$D=(this.$D+1)%n,t},r.prototype.ha=function(t,i,n){void 0===n&&(n=!1);var s=[t[0],t[3]],t=[t[2],t[1]],s=this.Ga(s,i),t=this.Ga(t,i),e=s[0],r=s[1],h=t[0],o=t[1];if(n)return{ja:e,Fa:r,Oa:h,Ea:o,z:i};this.Pa={ja:e,Fa:r,Oa:h,Ea:o,z:i};for(var a=[],u=e;u<=h;u+=1)for(var c=r;c<=o;c+=1)a.push(new _.ca(i,u,c));return this.Da(a),a},r.prototype.da=function(t,i,n,s){var e=[3,6,8,10,12,14],r=this.ra(t.optimalZoom);if(this.Za)for(var h=Math.min(14,r+3),o=r+1;n.length&&o<=h;o+=1)if(-1!==e.indexOf(o)){for(var a=o-r,u=[],c=[],f=n.length-1;0<=f;--f)for(var l=n[f].x<<a,d=n[f].y<<a,v=1<<a;0<=v;--v)for(var p=1<<a;0<=p;--p){var m=new _.ca(o,this.fa(l+v,o),d+p),y=new _.ca(o,l+v,d+p);((M=this.ua.getTile(m,!0))&&M.status===_.TileState.LOADED?c:u).push(y)}c.length&&i.push.apply(i,c),n=u}if(this.qa)for(var b=this.xt[0],o=r-1;n.length&&b<=o;--o)if(-1!==e.indexOf(o)){for(var c=[],u=[],g={},f=n.length-1;0<=f;--f){var M,k=n[f],a=o,w=k.z-a,v=k.x>>w,p=k.y>>w;g[k=(m=new _.ca(a,v,p)).key]||(w=new _.ca(a,this.fa(v,a),p),y=new _.ca(a,v,p),M=this.ua.getTile(w,!0),g[k]=!0,(M&&M.status===_.TileState.LOADED?c:u).push(y))}c.length&&i.push.apply(i,c),n=u}return i},r.prototype.Da=function(t){var e,r,h;t.length&&(e=this.Pa.z,r=(this.Pa.ja+this.Pa.Oa)/2,h=(this.Pa.Fa+this.Pa.Ea)/2,t.sort(function(t,i){var n=(t.x<<e-t.z)-r,t=(t.y<<e-t.z)-h,s=(i.x<<e-i.z)-r;return n*n+t*t<=s*s+(i=(i.y<<e-i.z)-h)*i?-1:1}))},r.prototype.Ga=function(t,i){var n=180/(i=Math.pow(2,i));return[Math.floor(t[0]/(360/i))+i/2,i/2-Math.ceil(t[1]/n)]},r.prototype.fa=function(t,i){for(var n=1<<(i=i||this.aa.optimalZoom);t<0||n<=t;)t=n<=t?t-n:t<0?n+t:t;return t},r.prototype.sD=function(){var e,r,h=this;this.map.bZ.dynamic.get("_preloadNebulaIcons")||(this.map.bZ.dynamic.set("_preloadNebulaIcons",!0),e=this.hD,(r=this.z_).loadImages(e,{type:"icon",imageBitmap:_.Support.imageBitmap,cb:function(){for(var t=[],i=0;i<e.length;i++){var n=e[i],s=r.getImage(n);t.push({img:s.img,name:n,hv:i,width:s.width,height:s.height})}h.map.so.sv(t)}},this.Bdt))},r.prototype.PE=function(t,i){for(var n=0,s=t;n<s.length;n++){var e=s[n].split(",").slice(0,3).join(",");(e=this.ua.xf(e))&&(e.region=i)}},r.prototype.UE=function(t,i){void 0===t&&(t=[]);var n=[];if(10<=i){for(var s=0,e=t;s<e.length;s++){var r=e[s];"china"!==r.region&&"oversea"!==r.region||n.push(r)}return n}return t},r.prototype.jE=function(t){for(var i=!!t.length,n=0,s=t;n<s.length;n++){var e=s[n].data;if(i)for(var r=0,h=e;r<h.length;r++){var o=h[r];if(!(i=i&&!!o.Ta))break}}return i},r);function r(t,i,n,s){var a=Rt.call(this,t,i,n,s)||this,i=(a.xt=_.zoomRange,a.sa=[],a.la=[],a.qa=!0,a.Za=!0,a.a_=!1,a.$D=0,a.hD=[AMap.getConfig().protocol+"://vdata.amap.com/style_icon/2.0/icon-normal-big.png",AMap.getConfig().protocol+"://vdata.amap.com/style_icon/2.0/icon-biz-big.png"],a.VH="",a.Bdt="",a.wH=function(t){!a.map.yH||parseInt(t.key.split(",")[0],10)<10||a.map.yH.kH(t.key)},a.Xa=t.tileSize,a._tileUrl=t.tileUrl,a.tG=null,_.Support.$e?30:200);return a.ua=new Ct(i),a.NE=new Lt(i),n.Wdt&&(a.hD=n.Wdt),window.xZ=a.ua,n.gn.Ha({scale:Et,showLabel:n.showLabel,DD:-1!==location.search.indexOf("forceAll")}),a.R_=n.R_,a.z_=n.z_,n.gn.Ja(AMap.getConfig().protocol),a.Bdt=AMap.getConfig().key,a.mapStyle=n.mapStyle,a.mapStyle.pn(function(t){n&&n.gn&&n.gn.Ka({value:t,TY:"fast"===a.map.bZ.MZ.drawMode})}),a.Ia(),a.sD(),a.ua.on("delete",a.wH),a.QH=new Dt(function(t,h,i,o){var n=a.AD(),s=a.map.bZ.dynamic.get("firstLabelDataAllLoaded")||!1;return!o||"outsea"!==o&&"a00"!==o||(n=n.replace("/nebula/","/oversea/")),!s&&_.Support.wasm&&(n=n.replace("/v3","/v2")),new _.vH(a.map.gn.va({url:n,zoom:i.zoom,optimalZoom:i.optimalZoom,projectionId:i.projectionId,mS:i.mS,viewMode:i.viewMode,showBuildingBlock:i.showBuildingBlock,ya:t,ZL:i.zoom,hH:i.hH,kZ:s},function(t){a.QH.CB(h);for(var i=0,n=t;i<n.length;i++){var s,e=n[i],r=e&&a.ua.getTile(e.zo);r&&(delete r.request,o&&"outsea"===o?r.JE(e.ba,e.tag):r.xa(e.ba,e.tag),a.map.Mv.t0(r.zo),r.status=_.TileState.LOADED,e=_.wa.ga(r.zo.x,r.zo.y,r.zo.z,"EPSG:3857"),s=_.lcs.getLocalByCoord([e[0],e[1]]),r.localCoord=s,r.Ro=e,a.map.mm)&&r.LY(a.map.mm.context)}a.map.setNeedUpdate(!0)}))},function(t){for(var i=0,n=t;i<n.length;i++){var s=n[i];(s=a.ua.xf(s.slice(0,-2)))&&s.status!==_.TileState.LOADED&&a.ua.ea(s)}},"fast"===n.bZ.MZ.drawMode?1:5),"fast"===n.bZ.MZ.drawMode&&a.map.bZ.dynamic.subscribe("firstPaint",function(){a.QH.Uo(5)},a,!0),a}function a(){}a.prototype.Qa=function(t){for(var i=this.createEmpty(),n=0,s=t.length;n<s;n+=1)this.extendCoordinate(i,t[n]);return i},a.prototype.ns=function(t,i,n){var s=Math.min.apply(null,t),t=Math.max.apply(null,t),e=Math.min.apply(null,i),i=Math.max.apply(null,i);return this.os(s,t,e,i,n)},a.prototype.buffer=function(t,i){t[0]-=i,t[1]-=i,t[2]+=i,t[3]+=i},a.prototype.clone=function(t){return t.slice()},a.prototype.ss=function(t,i){return t[0]<=i[0]&&i[0]<=t[2]&&t[1]<=i[1]&&i[1]<=t[3]},a.prototype.rs=function(t,i){return t[0]<=i[0]&&i[2]<=t[2]&&t[1]<=i[1]&&i[3]<=t[3]},a.prototype.createEmpty=function(){return[1/0,1/0,-1/0,-1/0]},a.prototype.os=function(t,i,n,s,e){return void 0!==e?(e[0]=t,e[2]=i,e[1]=n,e[3]=s,e):[t,n,i,s]},a.prototype.empty=function(t){return t[0]=t[1]=1/0,t[2]=t[3]=-1/0,t},a.prototype.equals=function(t,i){return t[0]===i[0]&&t[2]===i[2]&&t[1]===i[1]&&t[3]===i[3]},a.prototype.extend=function(t,i){i[0]<t[0]&&(t[0]=i[0]),i[2]>t[2]&&(t[2]=i[2]),i[1]<t[1]&&(t[1]=i[1]),i[3]>t[3]&&(t[3]=i[3])},a.prototype.extendCoordinate=function(t,i){+i[0]<t[0]&&(t[0]=i[0]),+i[0]>t[2]&&(t[2]=i[0]),+i[1]<t[1]&&(t[1]=i[1]),+i[1]>t[3]&&(t[3]=i[1])},a.prototype.hs=function(t){return[t[0],t[1]]},a.prototype.ls=function(t){return[t[2],t[1]]},a.prototype.getCenter=function(t){return[(t[0]+t[2])/2,(t[1]+t[3])/2]},a.prototype.us=function(t,i,n,s,e){for(var r,h,o=i*s[0]/2,i=i*s[1]/2,a=Math.cos(n),u=Math.sin(n),c=[-o,-o,o,o],f=[-i,i,-i,i],l=0;l<4;l+=1)r=c[l],h=f[l],c[l]=t[0]+r*a-h*u,f[l]=t[1]+r*u+h*a;return this.ns(c,f,e)},a.prototype.getHeight=function(t){return t[3]-t[1]},a.prototype.getSize=function(t){return[t[2]-t[0],t[3]-t[1]]},a.prototype.cs=function(t){return[t[0],t[3]]},a.prototype.fs=function(t){return[t[2],t[3]]},a.prototype.getWidth=function(t){return t[2]-t[0]},a.prototype.intersects=function(t,i){return t[0]<=i[2]&&t[2]>=i[0]&&t[1]<=i[3]&&t[3]>=i[1]},a.prototype.isEmpty=function(t){return t[2]<t[0]||t[3]<t[1]},a.prototype.normalize=function(t,i){return[(i[0]-t[0])/(t[2]-t[0]),(i[1]-t[1])/(t[3]-t[1])]},a.prototype.ps=function(t,i){var n=(t[2]-t[0])/2*(i-1),i=(t[3]-t[1])/2*(i-1);t[0]-=n,t[2]+=n,t[1]-=i,t[3]+=i},a.prototype.touches=function(t,i){return this.intersects(t,i)&&(t[0]===i[2]||t[2]===i[0]||t[1]===i[3]||t[3]===i[1])},a.prototype.transform=function(t,i,n){return i(t=[t[0],t[1],t[0],t[3],t[2],t[1],t[2],t[3]],t,2),this.ns([t[0],t[2],t[4],t[6]],[t[1],t[3],t[5],t[7]],n)};var Pt=new a,l=(u.from=function(t){for(var i=1/0,n=1/0,s=-1/0,e=-1/0,r=0,h=t;r<h.length;r++)var o=h[r],i=Math.min(i,o.southWest.KL),n=Math.min(n,o.southWest.kT),s=Math.max(s,o.northEast.KL),e=Math.max(e,o.northEast.kT);return new u(new _.LngLat(i,n),new _.LngLat(s,e))},u.xS=function(t){if(t)return t=_.jsonLngLatData(t),new u(Pt.Qa(t))},u.bS=function(t){if(t&&t.length){for(var i,n=0,s=_.jsonLngLatData(t);n<s.length;n++){var e,r=s[n];i?(e=u.ds(r))&&i.union(e):i=u.xS(r)}return i}},u.ds=function(t){if(t)return t=_.jsonLngLatData(t),_.ys(t)?u.xS(t):u.xS(t[0])},u.ms=function(t){if(t&&t.length){for(var i,n=0,s=_.jsonLngLatData(t);n<s.length;n++){var e,r=s[n];i?(e=u.ds(r))&&i.union(e):i=u.ds(r)}return i}},u.prototype.getSouthWest=function(){return this.southWest},u.prototype.getNorthEast=function(){return this.northEast},u.prototype.getNorthWest=function(){return new _.LngLat(this.southWest.KL,this.northEast.kT,!0)},u.prototype.getSouthEast=function(){return new _.LngLat(this.northEast.KL,this.southWest.kT,!0)},u.prototype.contains=function(t){var i,n,s=this.southWest,e=this.northEast;return!_.xs(t)&&(t=_.parseLngLatData(t),i=s.KL,(n=e.KL)<i&&(n+=360),t.KL>=i)&&t.kT>=s.kT&&t.KL<=n&&t.kT<=e.kT},u.prototype.intersects=function(t){var i=this.southWest,n=this.northEast,s=t.southWest,e=(t=t.northEast).kT>=i.kT&&s.kT<=n.kT,t=t.KL>=i.KL&&s.KL<=n.KL;return e&&t},u.prototype.getCenter=function(){var t=this.southWest.KL>this.northEast.KL?(this.southWest.KL+this.northEast.KL+360)/2%360:(this.southWest.KL+this.northEast.KL)/2,i=(this.southWest.kT+this.northEast.kT)/2;return new _.LngLat(t,i)},u.prototype.extend=function(t){return this.southWest.setLng(Math.min(this.southWest.KL,t.KL)),this.southWest.setLat(Math.min(this.southWest.kT,t.kT)),this.northEast.setLng(Math.max(this.northEast.KL,t.KL)),this.northEast.setLat(Math.max(this.northEast.kT,t.kT)),this},u.prototype.union=function(t){return this.extend(t.southWest).extend(t.northEast)},u.prototype.toString=function(){return this.southWest.toString()+";"+this.northEast.toString()},u.prototype.toJSON=function(){return[this.southWest.lng,this.southWest.lat,this.northEast.lng,this.northEast.lat]},u.prototype.getWidth=function(){return Math.abs(this.northEast.lng-this.southWest.lng)},u.prototype.getHeight=function(){return Math.abs(this.southWest.lat-this.northEast.lat)},u.prototype.clone=function(){return u.from([this])},u.prototype.check=function(){return!!(this.northEast&&this.southWest&&this.northEast.lat&&this.southWest.lat)},u);function u(){this.className="AMap.Bounds";var i,n,s,e,r,h="undefined"!=typeof Float64Array;if(1===arguments.length&&(arguments[0]instanceof Array||h&&arguments[0]instanceof Float64Array))e=new _.LngLat(arguments[0][0],arguments[0][1],!0),r=new _.LngLat(arguments[0][2],arguments[0][3],!0);else if(2===arguments.length)e=_.parseLngLatData(arguments[0]),r=_.parseLngLatData(arguments[1]);else if(4===arguments.length)e=new _.LngLat(arguments[0],arguments[1]),r=new _.LngLat(arguments[2],arguments[3]);else{if(0!==arguments.length)throw Error("Invalid Object: Bounds("+arguments+")");e=new _.LngLat(-180,-90),r=new _.LngLat(180,90)}(e.KL>r.KL||e.kT>r.kT)&&(h=Math.max(e.KL,r.KL),i=Math.min(e.KL,r.KL),n=Math.max(e.kT,r.kT),s=Math.min(e.kT,r.kT),e=new _.LngLat(i,s),r=new _.LngLat(h,n)),this.southWest=e,this.northEast=r}jt=ct,_.Ei(Wt,jt),Wt.prototype.loadData=function(t,i,n){return this.ze=i,!(this.Oo&&!this.io||!this.map.isDOMMode()&&!i||(t=this.c0(t,i,n),this.io?t(this.io,"canvas"):((i=new Image).crossOrigin="",i.onload=t,i.src=this.gs.getImageUrl(),this.Rs=i),0))},Wt.prototype.reLoadImgage=function(t){var s=this;t&&this.Rs&&((t=new Image).crossOrigin="",t.onload=function(t,i){var n;"image"===(i=void 0===i?"image":i)?n=t.target:"canvas"===i&&(n=t),s._s&&s._s.update(n),s.Fo(!0)},t.src=this.gs.getImageUrl(),this.Rs=t)},Wt.prototype.c0=function(t,s,e){var r=this;return function(t,i){var n;void 0===i&&(i="image"),s&&(n=void 0,"image"===i?n=t.target:"canvas"===i&&(n=t),r._s?r._s.update(n):(r._s=s.createTexture(n,{Zi:!0}),r._s.bind(s.gl.CLAMP_TO_EDGE,s.gl.LINEAR,s.gl.LINEAR)),r.Fo(!0)),e()}},Wt.prototype.getData=function(t){if(this.Oo&&this._s){(i=this.gs.getBounds())instanceof l&&(i=i.toJSON());var n=_.lcs.getLocalByCoord([t.centerCoord[0],t.centerCoord[1]]),e=(s=_.ProjectionManager.getProjection(t.projectionId)).project(i[0],i[1]),s=s.project(i[2],i[3]),r=[0,0,0,0];if(t.optimalZoom>=_.Ra){for(var i=_.lcs.getLocalByCoord([e[0],e[1]]),t=_.lcs.getLocalByCoord([s[0],s[1]]),h=_.lcs.getSize(),r=[i.x-n.x,i.y-n.y,t.x-n.x,t.y-n.y],o=0;o<r.length;o++)0!==r[o]&&(r[o]*=h[0]);r=[r[0]-i.center[0],r[1]-i.center[1],r[2]-t.center[0],r[3]-t.center[1]]}return this.ze&&(this.ks=this.ze.fe(new Float32Array([e[0]+r[0],e[1]+r[1],0,1,s[0]+r[2],e[1]+r[1],1,1,e[0]+r[0],s[1]+r[3],0,0,s[0]+r[2],e[1]+r[1],1,1,s[0]+r[2],s[1]+r[3],1,0,e[0]+r[0],s[1]+r[3],0,0]),16)),{Ro:this.ws,image:this.Rs,texture:this._s,zs:this.ks,Sa:[0,0]}}},Wt.prototype.destroy=function(){this.Rs&&delete this.Rs,this._s&&this._s.destroy&&(this._s.destroy(),delete this._s),this.ks&&delete this.ks,this.gs};var jt,Bt=Wt;function Wt(t,i,n,s){return(t=jt.call(this,t,i,n,s)||this).gs=s,t.io=s.canvas,t}Ft=ct,_.Ei(Nt,Ft),Nt.prototype.add=function(t,i,n){void 0===t&&(t={}),void 0===i&&(i={}),Object.keys(t).length&&(this.Ls=t,this.HB=!0,this.OB=i,n)&&n()},Nt.prototype.remove=function(t,i,n){void 0===i&&(i={}),this.Ls=t=void 0===t?{}:t,this.HB=!0,this.OB=i,n&&n()},Nt.prototype.update=function(t,i){void 0===t&&(t={}),this.HB=!0,this.OB=t,i&&i()},Nt.prototype.clear=function(){this.Ls={},this.Ts=[],this.gS=null},Nt.prototype.getData=function(){return{other:this.gS}},Nt.prototype.Ds=function(t){return this.Ls[t]||null},Nt.prototype.zL=function(t){return this.CL&&this.CL.zL(t)},Nt.prototype.destroy=function(){this.R_&&this.R_.destroy&&(this.R_.destroy(),delete this.R_),this.z_&&this.z_.destory&&(this.z_.destory(),delete this.z_)},Nt.prototype.loadData=function(t,i,n){var s=this;return 0===Object.keys(this.Ls).length&&this.Fo(!0),this.HB&&(this.HB=!1,this.As(this.OB,function(){s.Fo(!0),s._map.bZ.dynamic.set("firstLabelLayerDataAllLoaded",!0),n()})),!0},Nt.prototype.As=function(i,n){var t,s,e,r=this,h=(void 0===i&&(i={}),this.R_),o=this.z_,a=this.Ls;for(t in this.Ts=[],a)a.hasOwnProperty(t)&&(s=a[t],s=this.Ps(s),this.Ts.push(s));this.Ts.length?(e=this.Ts[0].data.position,this.Os(e),o.loadImages(Object.keys(this.Fs),{cb:function(){var t;h&&"SDFManagerBase"!==h.CLASS_NAME?(t=Object.keys(r.Es),h.getData(t,function(t){r.qL(i,n)})):r.qL(i,n)}})):(this.clear(),n())},Nt.prototype.qL=function(t,i){void 0===t&&(t={});var n=this.R_,s=this.z_,n=this.CL=new _.eG({R_:n,z_:s}),s=this.Us,e={from:"labelsLayer",zoom:this._map.getView().getOptions().zoom,center:s.center},t=(_.assign(e,t),n.Ns(this.Ts,e));this._map&&this._map.isDOMMode()?this.gS=t:this.gS=new _.La(null,t),this.gS.zo=s,i&&i(t)},Nt.prototype.Ps=function(t){var i,n,s,e,r,h,o,a,u,c,f,l,d,v,p,m,y,b;if(!t||"AMap.LabelMarker"===t.type)return i=this._map.getProjection(),this.AL={},c=t.getOptions(),(n=t._position)?(s=[_.tc.Mp,_.tc.Rp],e=void 0===(e=c.zooms)?s:e,r=c.opacity,h=c.rank,v=c.icon,o=c.text,a=c.zIndex,u=c.rotation,c=void 0===(c=c.visible)||c,f=_.Bs(n)?n.toJSON():n,l=o&&o.content||"",d=o&&o.style,v&&v.image&&(this.Fs[v.image]=1),o&&o.content&&this.Ws(o.content),v=v&&v.image?[{type:"image",image:v.image||"",size:v.size,clipOrigin:v.clipOrigin,clipSize:v.clipSize,offset:v.offset,anchor:v.anchor,retina:v.retina}]:{},b=m=0,d&&(m=!d.strokeWidth&&d.strokeColor?1:d.strokeWidth||0,p=!d.strokeColor&&d.strokeWidth?"#fcfcfc":d.strokeColor,b=!d.borderWidth&&d.borderColor?1:d.borderWidth||0,y=!d.borderColor&&d.strokeWidth?"#ccc":d.borderColor),p=d?{fontFamily:d.fontFamily,fontSize:d.fontSize,fontWeight:d.fontWeight,fillColor:d.fillColor,strokeColor:p,strokeWidth:m,borderColor:y,borderWidth:b,padding:this.Gs(d.padding||[3]),backgroundColor:d.backgroundColor,fold:d.fold}:{},m=_.labelsUtil.Jj(e,o&&o.zooms||s),y=o&&l?{txt:o.content||"",direction:o.direction,offset:o.offset,zooms:m,style:p}:{},b=i.project(f[0],f[1]),{data:{id:t.hS,name:l,txt:l,position:[b[0],b[1],n[2]||0],positionType:"lnglat",extData:{id:t.hS},rank:h,rotation:u,zooms:e},opts:{visible:c,opacity:r,zooms:e,zIndex:a,icon:v,text:y,rotation:u,height:n[2]||0}}):null},Nt.prototype.Ws=function(t){void 0===t&&(t="");for(var i=0;i<t.length;i++)this.Es[t.substr(i,1)]=1},Nt.prototype.Os=function(t){_.Bs(t)?this.Us=_.lcs.getLocalByCoord([t.KL,t.kT]):this.Us=_.lcs.getLocalByCoord(t)},Nt.prototype.Gs=function(t){if("string"==typeof t&&(t=(t=t.trim()).split(" ")),"[object Array]"!==Object.prototype.toString.apply(t))return[3,3,3,3];for(var i=t.length,n=0;n<i;n++){var s="string"==typeof(s=t[n])?parseInt(s,10):s;isNaN(s)?t[n]=3:t[n]=s}switch(i){case 0:t=[3,3,3,3];break;case 1:t=[t[0],t[0],t[0],t[0]];break;case 2:t=[t[0],t[1],t[0],t[1]];break;case 3:t=[t[0],t[1],t[2],t[1]]}return t};var Ft,Gt=Nt;function Nt(t,i,n,s){return(t=Ft.call(this,t,i,n,s)||this).Fs={},t.Es={},t.Ts=[],t.HB=!1,t.Ls={},t.AL={},i=n.R_,s=n.z_,t.R_=i,t.z_=s,t._map=n,t}_t=ct,_.Ei(Yt,_t),Yt.prototype.setTileUrl=function(t){this._tileUrl=t=void 0===t?"":t},Yt.prototype.loadData=function(t,i,n,s){var h=this;if(!i&&"d"!==s.baseRender)return!1;this.aa=t,this.ze=i,this.Zs=[],this.sa=[];var e=t.projectionId,r=[],o=t.boundsCoord,a=t.optimalZoom,u=t.optimalResolution,c=this.ha(o,a,u),o=(this.ua.forEach(function(t){var i=t.zo,n=!1;if(t.status!==_.TileState.LOADED){for(var s=c.ja;s<=c.Oa;s+=1)for(var e=c.Fa;e<=c.Ea;e+=1){var r=h.fa(s,c.z);i.z===c.z&&i.y===e&&r===i.x&&(n=!0)}n||(t.data.src="",h.ua.ea(t))}}),this.qs(t,this.Zs,r));return this.Ys(o,i,e,n),this.da(t,this.sa,r,s),this.sa=this.sa.concat(this.Zs),0===o.length},Yt.prototype.getData=function(){var t=this.aa,i=[],n=this.map.qF();if(this.ua.QF(n),0<this.sa.length)for(var s=0;s<this.sa.length;s++){for(var e=this.sa[s],r=[],h=0;h<e.length;h++){var o,u,f,l,d,a,c,m=[0,0],y=t.centerCoord,b=this.ua.getTile(e[h]),y=_.lcs.getLocalByCoord([y[0],y[1]]);b||(o=this.ua.getTile(new _.ca(e[h].z,this.fa(e[h].x,e[h].z),e[h].y)),b=new _.Vs(e[h]),o&&o.data.texture&&(l=this.aa.projectionId,f=_.ProjectionManager.getProjection(l).getResolution(b.zo.z),u=(a=b.zo.x*this.Xa*f)+this.Xa*f,f=(c=b.zo.y*this.Xa*f)+this.Xa*f,d=_.V[l].Xs(a,c),l=_.V[l].Xs(u,f),a=d[0],u=l[0],c=l[1],f=d[1],b.Ro=[a,c,u,f],l=_.lcs.getLocalByCoord([b.Ro[0],b.Ro[1]]),this.aa.optimalZoom>=_.Ra&&(b.Ro[0]-=l.center[0],b.Ro[1]-=l.center[1],b.Ro[2]-=l.center[0],b.Ro[3]-=l.center[1]),this.ze?b.data={Hs:l,texture:o.data.texture,Js:o.data.Js,zs:this.ze.fe(new Float32Array([b.Ro[0],b.Ro[1],0,1,b.Ro[2],b.Ro[1],1,1,b.Ro[0],b.Ro[3],0,0,b.Ro[2],b.Ro[1],1,1,b.Ro[2],b.Ro[3],1,0,b.Ro[0],b.Ro[3],0,0]),16)}:(b.data=o.data,b.data.Hs=l),b.data)&&(b.status=_.TileState.LOADED)),b.data&&(t.optimalZoom>=_.Ra&&b.data.Hs?(d=_.lcs.getSize(),a=b.data.Hs.x-y.x,c=b.data.Hs.y-y.y,0!=a&&(a*=d[0],m[0]=a),0!=c&&(c*=d[1],m[1]=c),t.optimalZoom>=_.Ra&&_.za>=b.zo.z&&(m[0]=-y.center[0],m[1]=-y.center[1])):t.optimalZoom<_.Ra&&_.za<b.zo.z&&(m[0]=y.center[0],m[1]=y.center[1]),b.data.Sa=m,b.stamp=n,r.push(b))}i.push(r)}return{tiles:i}},Yt.prototype.setTileCacheSize=function(t){t=t||(_.Support.$e?50:200),this.ua.Xo(t)},Yt.prototype.reload=function(){this.ua.forEach(function(t){t.status!==_.TileState.LOADED&&t.request&&t.request.cancel&&(t.request.cancel(),delete t.request)}),this.ua.destroy(),this.sa=[],this.pS=!1,this.Fo(!1)},Yt.prototype.getTileCache=function(){return this.ua},Yt.prototype.Da=function(t,i){var e,r,h;t.length&&(e=this.Pa.z,r=(this.Pa.ja+this.Pa.Oa)/2,h=(this.Pa.Fa+this.Pa.Ea)/2,t.sort(function(t,i){var n=(t.x<<e-t.z)-r,t=(t.y<<e-t.z)-h,s=(i.x<<e-i.z)-r;return n*n+t*t<=s*s+(i=(i.y<<e-i.z)-h)*i?-1:1}))},Yt.prototype.ha=function(t,i,n){var s=this.aa.projectionId,s=_.ProjectionManager.getProjection(s),s=(this.TB()&&(n=s.getResolution(++i)),i<this.Qs[0]?(i=this.Qs[0],n=s.getResolution(i)):i>this.Qs[1]&&(i=this.Qs[1],n=s.getResolution(i)),this.Xa),e=20037508.342789244,r=t[0]+e,h=-(t[3]-e),o=t[2]+e,r=r/n,h=h/n,t=-(t[1]-e)/n;return{Oa:Math.floor(o/n/s),Ea:Math.min((1<<i)-1,Math.floor(t/s)),ja:Math.floor(r/s),Fa:Math.max(Math.floor(h/s),0),z:i}},Yt.prototype.qs=function(t,i,n){for(var s=t.optimalZoom,e=t.optimalResolution,r=t.boundsCoord,h=_.ProjectionManager.getProjection(t.projectionId),r=this.ha(r,s,e),o=(this.TB()&&s++,s<this.Qs[0]?s=this.Qs[0]:s>this.Qs[1]&&(s=this.Qs[1]),h.getResolution(s),[]),a=[],u=!0,c=r,f=c.ja;f<=c.Oa;f+=1)for(var l=c.Fa;l<=c.Ea;l+=1){var d=new _.ca(s,this.fa(f,s),l),v=this.ua.getTile(d),p=(this.PF(d,t.projectionId),new _.ca(s,f,l));(v?v.status===_.TileState.LOADED||v.status===_.TileState.ERROR?a:(u=!1,n):(u=!1,o.push(d),n)).push(p)}return a.length&&i.push(a),this.Pa=r,this.Fo(u),o},Yt.prototype.da=function(t,i,n,s){if(t=t.optimalZoom,this.Za="overlay"!==this.layer.type,this.qa="overlay"!==this.layer.type,this.Za)for(var e=Math.min(this.xt[1],t+2),r=t+1;n.length&&r<=e;r+=1){for(var h=[],o=[],a=r,u=n.length-1;0<=u;--u)for(var c=n[u],f=c.x<<1,l=c.y<<1,d=1;0<=d;--d)for(var v=1;0<=v;--v){var p=new _.ca(a,this.fa(f+d,a),l+v),m=this.ua.getTile(p),y=new _.ca(a,f+d,l+v);(m&&m.status===_.TileState.LOADED?o:h).push(y)}o.length&&i.push(o),n=h}if(this.qa)for(var b=this.xt[0],r=t-1;n.length&&b<=r;--r){for(var o=[],h=[],g={},u=n.length-1;0<=u;--u){var M=n[u],a=r,k=M.z-a,d=M.x>>k,v=M.y>>k;g[M=(p=new _.ca(a,this.fa(d,a),v)).key]||(m=this.ua.getTile(p),g[M]=!0,(m&&m.status===_.TileState.LOADED?o:h).push(new _.ca(a,d,v)))}o.length&&i.push(o),n=h}return i},Yt.prototype.ma=function(){var t,i=new RegExp(/\{(\w|\,)+\}/g);return i.test(this._tileUrl)?(t=this._tileUrl.match(i)[0].replace(/[\{|\}]/g,"").split(","),this.tr++,t&&this.tr>=t.length&&(this.tr=0),this._tileUrl.replace(i,t[this.tr])):this._tileUrl},Yt.prototype.Ys=function(l,d,v,p){var m;if(!(this.aa.optimalZoom<this.xt[0]||this.aa.optimalZoom>this.xt[1])){this.Da(l);for(var y=this,i=0,n=l.length;i<n;i+=1)!function(t){var n=y.layer.getLayerConfig(),t=l[t],s=y.ma().replace("[z]",t.z+"").replace("[x]",t.x+"").replace("[y]",t.y+""),h=new _.Vs(t),e=(y.ua.Qo(h),n.getTileUrl&&(s=n.getTileUrl(t.x,t.y,t.z)),_.ProjectionManager.getProjection(v).getResolution(t.z)),r=t.x*y.Xa*e,o=r+y.Xa*e,a=t.y*y.Xa*e,e=a+y.Xa*e,u=_.V[v].Xs(r,a),c=_.V[v].Xs(o,e);function f(t){var i,n,s,e,r;d&&((t=d.createTexture(t.target||t,{Zi:!0})).bind(d.gl.CLAMP_TO_EDGE,d.gl.LINEAR,d.gl.LINEAR),i=_.lcs.getLocalByCoord([h.Ro[0],h.Ro[1]]),h.zo.z>_.za&&(h.Ro[0]-=i.center[0],h.Ro[1]-=i.center[1],h.Ro[2]-=i.center[0],h.Ro[3]-=i.center[1]),n=d.fe(new Float32Array([h.Ro[0],h.Ro[1],0,1,h.Ro[2],h.Ro[1],1,1,h.Ro[0],h.Ro[3],0,0,h.Ro[2],h.Ro[1],1,1,h.Ro[2],h.Ro[3],1,0,h.Ro[0],h.Ro[3],0,0]),16),(e=(s=document.createElement("canvas")).getContext("2d"))&&(r=this.Xa,s.height=s.width=r,s.style.height=s.style.width=r+"px",e.beginPath(),e.moveTo(0,0),e.lineTo(r,0),e.lineTo(r,r),e.lineTo(0,r),e.lineTo(0,0),e.lineWidth=1,e.font="20px Verdana",e.fillStyle="#ff0000",e.strokeStyle="#FF0000",e.strokeRect(0,0,r,r),e.fillText("z: "+h.zo.z,10,30),e.fillText("x: "+h.zo.x,10,60),e.fillText("y: "+h.zo.y,10,90),e.stroke()),(r=d.createTexture(s,{Zi:!0})).bind(d.gl.MIRRORED_REPEAT,d.gl.LINEAR,d.gl.LINEAR_MIPMAP_NEAREST),h.data={texture:t,zs:n,Js:r,Hs:i}),h.status=_.TileState.LOADED,p()}r=u[0],o=c[0],a=c[1],e=u[1],h.Ro=[r,a,o,e],h.status=_.TileState.LOADING,"AMap.TileLayer.Flexible"===y.layer.CLASS_NAME||"AMap.TileLayer.WMTS"===y.layer.CLASS_NAME||"AMap.TileLayer.WMS"===y.layer.CLASS_NAME?n.createTile(t.x,t.y,t.z,function(t){d?f.call(this,t):(h.data=t,h.status=_.TileState.LOADED)}.bind(y),function(){h.status=_.TileState.ERROR,p()}):(c=new Image,"w"===(null==(m=y.map)?void 0:m.baseRender)&&(c.crossOrigin="anonymous"),c.onload=f.bind(y),"d"===(null==(m=y.map)?void 0:m.baseRender)&&0<s.indexOf("traffictile")&&(s+="&hash="+Math.random()),c.src=s,(h.data=c).addEventListener("dragstart",function(t){return t.preventDefault(),!1}))}(i)}},Yt.prototype.fa=function(t,i){i=i||this.aa.optimalZoom;for(var n=this.Xa/256,s=(n<1?n=1/n:n--,1<<(i+=n));t<0||s<=t;)t=s<=t?t-s:t<0?s+t:t;return t},Yt.prototype.PF=function(t,i){var n=_.ProjectionManager.getProjection(i).getResolution(t.z),s=(e=t.x*this.Xa*n)+this.Xa*n,n=(t=t.y*this.Xa*n)+this.Xa*n,t=_.V[i].Xs(e,t),i=_.V[i].Xs(s,n),e=t[0],s=i[0],n=(i[1],t[1]);return!(s<(i=this.map.getView().getStatus().boundsCoord)[0]&&n<i[1]||e>i[2]&&s>i[3])},Yt.prototype.TB=function(){var t=!1;return this.layer.getState().detectRetina&&(t=!0),!("d"!==_.Support.baseRender||!_.Support.Ue||!_.Support.$e)||t};var _t,Ut=Yt;function Yt(t,i,n,s){return(i=_t.call(this,t,i,n,s)||this).ua=new xt(_.Support.$e?200:400),i.Xa=256,i.sa=[],i.Zs=[],i.tr=-1,i.qa=!0,i.Za=!0,i.xt=t.zooms,i.Qs=t.dataZooms,i.Xa=t.tileSize,i._tileUrl=t.tileUrl,i}Zt=ct,_.Ei(Jt,Zt),Jt.prototype.loadData=function(t,i,n){return this.ze=i,this.Oo||(this.Fo(!0),n()),!0},Jt.prototype.getData=function(t){if(this.ir=t.bounds,this.Oo){var i=_.lcs.getLocalByCoord([t.centerCoord[0],t.centerCoord[1]]),s=(n=_.ProjectionManager.getProjection(t.projectionId)).project(this.ir[0],this.ir[1]),n=n.project(this.ir[2],this.ir[3]),e=[0,0,0,0];if(t.optimalZoom>=_.Ra){for(var t=_.lcs.getLocalByCoord([s[0],s[1]]),s=_.lcs.getLocalByCoord([n[0],n[1]]),r=_.lcs.getSize(),e=[t.x-i.x,t.y-i.y,s.x-i.x,s.y-i.y],h=0;h<e.length;h++)0!==e[h]&&(e[h]*=r[0]);e=[e[0]-t.center[0],e[1]-t.center[1],e[2]-s.center[0],e[3]-s.center[1]]}return{texture:this._s,zs:this.ks,Sa:[0,0]}}};var Zt,Xt=Jt;function Jt(t,i,n,s){return(t=Zt.call(this,t,i,n,s)||this).ir=n.getView().getStatus().bounds,t.io=s.canvas,t}Ht=ct,_.Ei(qt,Ht),qt.prototype.hasOverlay=function(t){return-1<this._overlays.indexOf(t)},qt.prototype.getAllOverlays=function(){return this._overlays},qt.prototype.add=function(t){this.hasOverlay(t)||_.er(t)&&(this._overlays.push(t),t.Zx(this.map),t.init(),t._bindEvents&&t._bindEvents(),(_.GB(t)||_.VB(t))&&this.YB.push(t),t._afterSetMap&&t._afterSetMap(this.map),this.map.setNeedUpdate(!0))},qt.prototype.remove=function(t){this.hasOverlay(t)&&_.er(t)&&(t._beforeRemoveMap&&t._beforeRemoveMap(),this.ar(t),this.map.setNeedUpdate(!0),t.Zx(null))},qt.prototype.getData=function(t,i){this.nr();var n=0,s=0,e=this._overlays.length,r=[],h=new l(t.bounds);if(this.map.isDOMMode())return{sr:this._overlays};for(;n<8&&s<e;){var o,a=this._overlays[s];s++,a&&(o=Date.now(),a._needUpdate&&(a.ZB(i),this.map.setNeedUpdate(!0)),n+=Date.now()-o)}for(var u=0,c=this._overlays;u<c.length;u++){var f=(a=c[u]).getBounds();a.visible&&f&&h.intersects(f)&&r.push(a)}return{sr:r}},qt.prototype.loadData=function(){return!0},qt.prototype.destroy=function(){this.map&&this.map.off("zoomend",this.W_);for(var t=0,i=this._overlays.slice(0);t<i.length;t++){var n=i[t];this.remove(n),n.destroy()}this._overlays=[]},qt.prototype.rr=function(t){for(var i=t.lnglat,n=t.pixel,s=this._overlays.length-1;0<=s;s--){var e=this._overlays[s];if(!e._opts.noSelect&&e.visible)if(_.sB(e)&&n){if(e.containsWithPixel(n))return e}else if(e.contains(i,t))return e}},qt.prototype.W_=function(){for(var t=0,i=this.YB;t<i.length;t++){var n=i[t];n.W_&&n.W_()}},qt.prototype.nr=function(){this._overlays.sort(function(t,i){return t._opts.zIndex-i._opts.zIndex})},qt.prototype.ar=function(t){var i=this._overlays.indexOf(t);-1<i&&this._overlays.splice(i,1),(_.GB(t)||_.VB(t))&&-1<(i=this.YB.indexOf(t))&&this.YB.splice(i,1)};var Ht,Kt,Vt=qt;function qt(t,i,n,s){return(t=Ht.call(this,t,i,n,s)||this)._overlays=[],t.YB=[],t.Fo(!0),t.W_=t.W_.bind(t),n.on("zoomend",t.W_),t}function c(t,i,n,s){return(i=Kt.call(this,t,i,n,s)||this).type="vector",i.Ya=!1,i.Va=!1,i.Xa=256,i.sa=[],i.la=[],i.xt=[2,22],i.qa=!0,i.Za=!0,i.a_=!1,i.Xa=t.tileSize,i._tileUrl=t.tileUrl,s=_.Support.$e?50:200,i.ua=new xt(s),i.NE=new Lt(s),(i.map=n).gn.Ja(AMap.getConfig().protocol),i}Kt=ct,_.Ei(c,Kt),c.prototype.loadData=function(s,t,e,i){for(var r=this,n=(this.aa=s,this.sa=[],s.optimalResolution),h=s.boundsCoord,o=s.zoom,a=s.optimalZoom,u=this.ha(h,a,n,s),c=[],f=_.map(u,function(t){return t.key}),l=[],d=0,v=this.la;d<v.length;d++){var p=v[d];f.indexOf(p.key)<0&&(b=this.ua.getTile(p))&&b.status!==_.TileState.LOADED&&b.request&&(b.request.cancel(),delete b.request,this.ua.ea(b))}for(var m=[],y=((h=i.getMapState()).panning,h.zooming,0);y<u.length;y++){var b,g=u[y],M=new _.ca(g.z,this.fa(g.x,g.z),g.y),k=new _.ca(g.z,g.x,g.y);(b=this.ua.getTile(M))?b.status===_.TileState.LOADED?this.sa.push(k):l.push(g):((k=new _.Sw(M)).nG(this.type),k.status=_.TileState.LOADING,this.ua.Jo(k),m.push(M),l.push(g)),b&&b.status===_.TileState.LOADED||c.push(g)}return this.da(s,this.sa,c,i),this.la=l,0===m.length||(_.map(m,function(t){var i,n=r.ua.getTile(t);n&&(i=r.AD(t.x,t.y,t.z),r.bw(n,{url:i,zo:t,zoom:o,viewState:s},e))}),0===m.length)},c.prototype.bw=function(t,i,s){var n,e=this,r=i.url,h=i.zo,o=i.zoom,i=i.viewState;"AMap.MapboxVectorTileLayer"===this.layer.CLASS_NAME&&(n=this.layer.cX&&this.layer.cX()),this.lX(t,{url:r,ya:h.key,zoom:o,optimalZoom:i.optimalZoom,projectionId:i.projectionId,tileCoord:h,tileSize:this.Xa,styles:n},function(t){var i,n=t&&e.ua.getTile(t.zo);n&&(delete n.request,n.status=_.TileState.LOADED,n.localCoord=t.zS,n.Ro=t.Ro,n.stencil=t.stencil,i=_.lcs.getLocalByCoord([n.Ro[0],n.Ro[1]]),n.data=_.Ln(_.Ln({},t),{Hs:i}),s())})},c.prototype.getData=function(t){var i=t.optimalResolution,n=t.optimalZoom,s=t.boundsCoord,s=this.ha(s,n,i,t),i=this.aa.projectionId,e=_.ProjectionManager.getProjection(i),r=[],h=this.map.qF();if(this.ua.QF(h),this.sa.sort(function(t){return n===t.z+1?1:-1}),0<this.sa.length)for(var o=0;o<this.sa.length;o++){var u,a,c=this.sa[o],f=this.ua.getTile(c),l=[0,0],d=t.centerCoord,d=_.lcs.getLocalByCoord([d[0],d[1]]);!f&&(a=this.fa(c.x,c.z),a=this.ua.getTile(new _.ca(c.z,a,c.y)))&&(f=new _.Sw(c),u=e.getResolution(c.z),c=c.x-a.zo.x,l[0]+=u*this.Xa*c,f.Ro=a.Ro,f.localCoord=a.localCoord,f.data=a.data,f.Sa=l,f.status=a.status),f&&10<n&&(n>=_.Ra&&f.data.Hs?(u=_.lcs.getSize(),c=f.data.Hs.x-d.x,a=f.data.Hs.y-d.y,0!=c&&(c*=u[0],l[0]=c),0!=a&&(a*=u[1],l[1]=a),n>=_.Ra&&_.za>=f.zo.z&&(l[0]=-d.center[0],l[1]=-d.center[1])):n<_.Ra&&_.za<f.zo.z&&(l[0]=d.center[0],l[1]=d.center[1])),f&&(f.Sa=l,f.stamp=h,r.push(f))}return i=_.every(s,function(i){return _.some(r,function(t){return t.zo.key===i.key})}),this.Fo(i),s=this.jE(r),i&&(this.a_=!0,this.map.bZ.dynamic.set("firstAllLoaded",!0)),this.a_&&this.map.bZ.dynamic.set("firstLabelDataAllLoaded",!0),{s_:this.a_,yZ:s,fo:!!i,tiles:r}},c.prototype.destroy=function(){this.ua.forEach(function(t){t.status!==_.TileState.LOADED&&t.request&&(t.request.cancel(),delete t.request),t.destroy()}),this.ua.destroy(),this.sa=[],this.la=[]},c.prototype.forEachTileCache=function(t){this.ua.forEach(t)},c.prototype.reload=function(){this.ua.forEach(function(t){t.status!==_.TileState.LOADED&&t.request&&(t.request.cancel(),delete t.request)}),this.ua.destroy(),this.sa=[],this.la=[]},c.prototype.setTileUrl=function(t){this._tileUrl=t||this._tileUrl},c.prototype.getTileCache=function(){return this.ua},c.prototype.setTileCacheSize=function(t){t=t||(_.Support.$e?50:200),this.ua.Xo(t)},c.prototype.AD=function(t,i,n){return this._tileUrl.replace("[x]",t.toString()).replace("[y]",i.toString()).replace("[z]",n.toString()).replace("{1234}",(Math.abs(t+i)%4+1).toString())},c.prototype.Da=function(t,i){var e,r,h;t.length&&(e=this.Pa.z,r=(this.Pa.ja+this.Pa.Oa)/2,h=(this.Pa.Fa+this.Pa.Ea)/2,t.sort(function(t,i){var n=(t.x<<e-t.z)-r,t=(t.y<<e-t.z)-h,s=(i.x<<e-i.z)-r;return n*n+t*t<=s*s+(i=(i.y<<e-i.z)-h)*i?-1:1}))},c.prototype.ha=function(t,i,n,s){for(var e=this.layer.getSourceConfig().dataZooms,e=(i=+Math.max(Math.min(i,e[1]),e[0]),n=_.ProjectionManager.getProjection(s.projectionId).getResolution(i),this.Xa),s=20037508.342789244,r=t[0]+s,h=-(t[3]-s),o=t[2]+s,r=r/n,h=h/n,t=-(t[1]-s)/n,a=Math.floor(o/n/e),u=Math.min((1<<i)-1,Math.floor(t/e)),s=Math.floor(r/e),c=Math.max(Math.floor(h/e),0),f=(this.Pa={Oa:a,Ea:u,ja:s,Fa:c,z:i},[]),l=s;l<=a;l+=1)for(var d=c;d<=u;d+=1)f.push(new _.ca(i,l,d));return this.Da(f),f},c.prototype.da=function(t,i,n,s){if(t=t.optimalZoom-1,this.Za="overlay"!==this.layer.type,this.qa="overlay"!==this.layer.type,this.Za)for(var e=Math.min(this.xt[1]-1,2+t),r=1+t;n.length&&r<=e;r+=1){for(var h=[],o=[],a=r,u=n.length-1;0<=u;--u)for(var c=n[u],f=c.x<<1,l=c.y<<1,d=1;0<=d;--d)for(var v=1;0<=v;--v){var p=new _.ca(a,this.fa(f+d,a),l+v),m=this.ua.getTile(p),y=new _.ca(a,f+d,l+v);(m&&m.status===_.TileState.LOADED?o:h).push(y)}o.length&&i.push.apply(i,o),n=h}if(this.qa)for(var b=this.xt[0]-1,r=t-1;n.length&&b<=r;--r){for(var o=[],h=[],g={},u=n.length-1;0<=u;--u){var M=n[u],a=r,k=M.z-a,d=M.x>>k,v=M.y>>k;g[M=(p=new _.ca(a,this.fa(d,a),v)).key]||(m=this.ua.getTile(p),g[M]=!0,(m&&m.status===_.TileState.LOADED?o:h).push(new _.ca(a,d,v)))}o.length&&i.push.apply(i,o),n=h}return i},c.prototype.fa=function(t,i){for(var n=1<<(i=i||this.aa.optimalZoom);t<0||n<=t;)t=n<=t?t-n:t<0?n+t:t;return t},c.prototype.vX=function(t,i){var n=[-180,-90],s=[180,90],r=(e=_.ProjectionManager.getProjection("EPSG:3857")).project(256*t+n[0],s[1]-256*i),e=e.project(256*(t+1)+n[0],s[1]-256*(i+1));return[r[0],r[1],e[0],e[1]]},c.prototype.jE=function(t){for(var i=!!t.length,n=0,s=t;n<s.length;n++){var e=s[n].data;if(i)for(var r=0,h=e;r<h.length;r++){var o=h[r];if(!(i=i&&!!o.Ta))break}}return i},$t=Qt=c,_.Ei(ii,$t),ii.prototype.ha=function(t,i,n,s){for(var e=this.layer.getSourceConfig().dataZooms,e=(i=Math.max(Math.min(i,e[1]),e[0])-1,n=_.ProjectionManager.getProjection(s.projectionId).getResolution(i),this.Xa),s=20037508.342789304,r=t[0]+s,h=-(t[3]-s),o=t[2]+s,r=r/n,h=h/n,t=-(t[1]-s)/n,a=Math.floor(o/n/e),u=Math.min((1<<i)-1,Math.floor(t/e)),s=Math.floor(r/e),c=Math.max(Math.floor(h/e),0),f=(this.Pa={Oa:a,Ea:u,ja:s,Fa:c,z:i},[]),l=s;l<=a;l+=1)for(var d=c;d<=u;d+=1)f.push(new _.ca(i,l,d));return this.Da(f),f};var $t,ti=ii;function ii(t,i,n,s){return(t=$t.call(this,t,i,n,s)||this).lX=t.map.gn.loadDistrictSourceTile.bind(t.map.gn),t}ni=Qt,_.Ei(ei,ni),ei.prototype.reStyle=function(i,s){var e=this;this.ua.forEach(function(n){var t;n.status===_.TileState.LOADED?(n.zo.z+1!==s&&e.ua.ea(n),t=_.Ln(_.Ln({},n.data),{dX:null,Dc:null,A_:null,$c:null,pX:null,labels:null}),e.yX.mX(t,i,function(t,i){n.data.Oc=i.Oc,n.data.Fc=i.Fc,n.data.w0=i.w0,n.data.Uc=i.Uc,n.data.dX=i.dX,n.data.IX=i.IX,n.data.labels=i.labels,e.map.setNeedUpdate(!0)})):n.status===_.TileState.LOADING&&(null!=(t=n.request)&&t.cancel(),e.ua.ea(n))})},ei.prototype.ha=function(t,i,n,s){for(var e=this.layer.getSourceConfig().dataZooms,e=(i=Math.max(Math.min(i-1,e[1]),e[0]),n=_.ProjectionManager.getProjection(s.projectionId).getResolution(i),this.Xa),s=20037508.342789244,r=t[0]+s,h=-(t[3]-s),o=t[2]+s,r=r/n,h=h/n,t=-(t[1]-s)/n,a=Math.floor(o/n/e),u=Math.min((1<<i)-1,Math.floor(t/e)),s=Math.floor(r/e),c=Math.max(Math.floor(h/e),0),f=(this.Pa={Oa:a,Ea:u,ja:s,Fa:c,z:i},[]),l=s;l<=a;l+=1)for(var d=c;d<=u;d+=1)f.push(new _.ca(i,l,d));return this.Da(f),f};var ni,si=ei;function ei(t,i,n,s){return(t=ni.call(this,t,i,n,s)||this).yX=new _.bX,t._tileUrl=s.getSourceConfig().tileUrl,t.lX=t.map.gn.gX.bind(t.map.gn),t}ri=ct,_.Ei(oi,ri),oi.prototype.loadData=function(t,i,n){return this.ze=i,this.Oo||(this.Fo(!0),n()),!0},oi.prototype.getData=function(t){return this.ir=t.bounds,{Sa:[0,0]}};var ri,hi=oi;function oi(t,i,n,s){return(t=ri.call(this,t,i,n,s)||this).ir=n.getView().getStatus().bounds,t.io=s.canvas,t}ai=ct,_.Ei(ci,ai),ci.prototype.loadData=function(t,i,n){return!0},ci.prototype.getData=function(t){return!0},ci.prototype.destroy=function(){this.gs&&this.gs.destroy&&this.gs.destroy()};var ai,ui=ci;function ci(t,i,n,s){return(t=ai.call(this,t,i,n,s)||this).gs=s,t}fi=ct,_.Ei(di,fi),di.prototype.CS=function(){this.AS=!1},di.prototype.loadData=function(t,i,n){return!0},di.prototype.getData=function(t){var i,r,e,h,n,o,a,u=this,s=this.gs.getState().path;return this.AS||!s||(i=_.GeometryUtil.typePolygon(s),r={type:"Polygon",$S:new Array,polygons:new Array,BM:new Array,LS:{x:0,y:0}},i&&"Polygon"===i?(s[0][0]instanceof _.LngLat?r.LS=_.lcs.getLocalByLnglat(s[0][0].toString()):r.LS=_.lcs.getLocalByLnglat(s[0][0]),e=(n=r.LS).x,h=n.y,_.forEach(s,function(t,i){var s;0===i?_.forEach(t,function(t){t instanceof _.LngLat&&(t=t.toArray());var t=_.lcs.getLocalByLnglat(t),n=(i=u.DS(e,h,t.x,t.y))[0],i=i[1];r.$S.push(t.Sa[0]+n,t.Sa[1]+i)}):(s=[],_.forEach(t,function(t){t instanceof _.LngLat&&(t=t.toArray());var t=_.lcs.getLocalByLnglat(t),n=(i=u.DS(e,h,t.x,t.y))[0],i=i[1];s.push(t.Sa[0]+n,t.Sa[1]+i)}),r.BM.push(s))})):i&&"MultiPolygon"===i&&(r.type="MultiPolygon",s[0][0][0]instanceof _.LngLat?r.LS=_.lcs.getLocalByLnglat(s[0][0][0].toArray()):r.LS=_.lcs.getLocalByLnglat(s[0][0][0]),o=(n=r.LS).x,a=n.y,_.forEach(s,function(t){var e=[],n=[];_.forEach(t,function(t,i){var s;0===i?_.forEach(t,function(t){t instanceof _.LngLat&&(t=t.toArray());var t=_.lcs.getLocalByLnglat(t),n=(i=u.DS(o,a,t.x,t.y))[0],i=i[1];e.push(t.Sa[0]+n,t.Sa[1]+i)}):(s=[],_.forEach(t,function(t){t instanceof _.LngLat&&(t=t.toArray());var t=_.lcs.getLocalByLnglat(t),n=(i=u.DS(o,a,t.x,t.y))[0],i=i[1];s.push(t.Sa[0]+n,t.Sa[1]+i)}),n.push(s))}),r.BM.push(n),r.polygons.push(e)})),this.AS=this.zw(r),this.AS)},di.prototype.zw=function(t){if(t.Oc=new _._w,!t.Dc){t.Dc=new _.K_;var i=[],n=[];"Polygon"===t.type?(i=[t.$S],n=[t.BM]):"MultiPolygon"===t.type&&(i=t.polygons,n=t.BM);for(var s=0;s<i.length;s++){for(var e=i[s],r=[],h=0;h<n[s].length;h++){var o=n[s][h];r.push(e.length/2),e.push.apply(e,o)}var a=t.Dc.Nx(e,r);0<a&&t.Oc.add(99,99,a,_.zoomRange[0],_.zoomRange[1])}return t}},di.prototype.DS=function(t,i,n,s){return n-=t,t=s-i,[n*(s=_.lcs.getSize())[0],t*s[1]]};var fi,li=di;function di(t,i,n,s){return(t=fi.call(this,t,i,n,s)||this).gs=s,t}vi=Qt,_.Ei(mi,vi),mi.prototype.YE=function(t){var i=this;return t(null,{GW:"worker",cb:function(t){i.dynamicTextVerticeLoadedByTile(t)}}),!0},mi.prototype.dynamicTextVerticeLoadedByTile=function(t){for(var i=0,n=t.data;i<n.length;i++){var s=n[i];this.dynamicTextVerticeLoaded({data:s.data,tag:s.tag,XE:s.XE})}},mi.prototype.dynamicTextVerticeLoaded=function(t){var i=t.data,t=t.XE;if(i instanceof _.ca)this.ua.getTile(i);else{var n=i[Object.keys(i)[0]];if((n=this.ua.getTile(n.zo,!0))&&n.data){var s,e,r={};for(s in i)i.hasOwnProperty(s)&&(e=i[s],r[s]=new _.La(e.zo,e));n.data.labels=r,n.data.XE=t,n.data.Ta=!0,this.Eo()}}},mi.prototype.Aa=function(t){t.zo&&(t=this.ua.getTile(t.zo))&&(t.data.Ta=!0)},mi.prototype.loadData=function(s,t,e,i){var h=this,n=(this.aa=s,this.sa=[],s.optimalResolution),r=s.boundsCoord,o=s.zoom,a=s.optimalZoom;if(a<9.8)return!1;for(var u=this.ha(r,a,n,s),c=[],f=_.map(u,function(t){return t.key}),l=[],d=0,v=this.la;d<v.length;d++){var p=v[d];f.indexOf(p.key)<0&&(x=this.ua.getTile(p))&&x.status!==_.TileState.LOADED&&x.request&&(x.request.cancel(),delete x.request,this.ua.ea(x))}for(var m,y,b,g=[],M=(r=i.getMapState()).panning,k=r.zooming,w=0;w<u.length;w++){var x,A=u[w],z=new _.ca(A.z,this.fa(A.x,A.z),A.y),C=new _.ca(A.z,A.x,A.y);!(x=this.ua.getTile(z))&&M&&!k||(x?x.status===_.TileState.LOADED?this.sa.push(C):l.push(A):((C=new _.Sw(z)).nG(this.type),C.status=_.TileState.LOADING,this.ua.Jo(C),g.push(z),l.push(A)),x&&x.status===_.TileState.LOADED)||c.push(A)}return this.da(s,this.sa,c,i),this.la=l,0!==g.length&&(m=this.map.getMapboxStyle(),y=[],b=256,_.map(g,function(t){var i=t.x,n=t.y,s=t.z,e=h.NE.getTile(t),r=null,n=(e&&e.boundsStatus?r=e.boundsStatus.isInNebulaOversea:(e=h.aa.projectionId,e=[_.V[e].Xs(i*b,n*b,s),_.V[e].Xs((i+1)*b,n*b,s),_.V[e].Xs((i+1)*b,(n+1)*b,s),_.V[e].Xs(i*b,(n+1)*b,s)],r=h.rG(e,t.key),(i=new _.pa(t)).boundsStatus={isInNebulaOversea:r},h.NE.Jo(i)),r||y.push(t),h.NE.getTile(t));(s=h.ua.getTile(t))&&n&&n.boundsStatus&&(s.sG=n.boundsStatus)}),_.map(g=y,function(t){var i,n=h.ua.getTile(t);n&&(i=h.AD(t.x,t.y,t.z),h.bw(n,{url:i,zo:t,zoom:o,viewState:s,styles:m},e))}),0===g.length)},mi.prototype.oG=function(t,i,n,s){void 0===s&&(s="lnglat");var e=[-180,-90],r=[180,90],h=_.ProjectionManager.getProjection("EPSG:3857");return"lnglat"===s?[256*t+e[0],r[1]-256*i,256*(t+1)+e[0],r[1]-256*(i+1)]:"EPSG:3857"===s?(s=h.project(256*t+e[0],r[1]-256*i),h=h.project(256*(t+1)+e[0],r[1]-256*(i+1)),[s[0],s[1],h[0],h[1]]):[0,0,0,0]},mi.prototype.bw=function(t,i,s){var e=this,n=i.url,r=i.zo,h=i.zoom,o=i.viewState,i=i.styles;this.map.gn.aG(t,{url:n,ya:r.key,zoom:h,optimalZoom:o.optimalZoom,projectionId:o.projectionId,tileCoord:r,tileSize:this.Xa,styles:i},function(t){var i,n=t&&e.ua.getTile(t.zo);n&&(delete n.request,n.status=_.TileState.LOADED,n.localCoord=t.zS,n.Ro=t.Ro,n.stencil=t.stencil,i=_.lcs.getLocalByCoord([n.Ro[0],n.Ro[1]]),n.data=_.Ln(_.Ln({},t),{Hs:i}),s())})},mi.prototype.getData=function(t){var i=this,n=t.optimalResolution,s=t.boundsCoord,e=t.optimalZoom;if(e<10)return this.Fo(!0),!1;var s=this.ha(s,e,n,t),n=t.projectionId,r=_.ProjectionManager.getProjection(n),h=[],o=this.map.qF();if(this.ua.QF(o),this.sa.sort(function(t){return e===t.z+1?1:-1}),0<this.sa.length)for(var a=0;a<this.sa.length;a++){var c,u,f=this.sa[a],l=this.ua.getTile(f),d=[0,0],v=t.centerCoord,v=_.lcs.getLocalByCoord([v[0],v[1]]);l||(u=this.ua.getTile(new _.ca(f.z,this.fa(f.x,f.z),f.y)))&&((l=new _.Sw(f)).nG(this.type),c=r.getResolution(f.z),f=f.x-u.zo.x,d[0]+=c*this.Xa*f,l.Ro=u.Ro,l.localCoord=u.localCoord,l.data=u.data,l.Sa=d,l.status=u.status),l&&(e>=_.Ra&&l.data.Hs?(c=_.lcs.getSize(),f=l.data.Hs.x-v.x,u=l.data.Hs.y-v.y,0!=f&&(f*=c[0],d[0]=f),0!=u&&(u*=c[1],d[1]=u),d[0]=-v.center[0],d[1]=-v.center[1]):(d[0]=v.center[0],d[1]=v.center[1])),l&&(l.Sa=d,l.stamp=o,h.push(l))}return s=!(n=_.filter(s,function(t){return!(!(t=i.NE.getTile(t))||!t.boundsStatus||!1!==t.boundsStatus.isInNebulaOversea)})).length||_.every(n,function(i){return _.some(h,function(t){return t.zo.key===i.key})}),n=this.jE(h),s&&(this.a_=!0,this.map.bZ.dynamic.set("firstAllLoaded",!0)),this.a_&&this.map.bZ.dynamic.set("firstLabelDataAllLoaded",!0),s&&this.Fo(!0),{s_:this.a_,fo:!!s,yZ:n,tiles:h}},mi.prototype.Ia=function(){this.map.on("tileSdfInfoFinished",this.Aa.bind(this))},mi.prototype.ha=function(t,i,n,s){for(var e=this.layer.getSourceConfig().dataZooms,e=(i=Math.max(Math.min(i,e[1]),e[0])-1,n=_.ProjectionManager.getProjection(s.projectionId).getResolution(i),this.Xa),s=20037508.342789244,r=t[0]+s,h=-(t[3]-s),o=t[2]+s,r=r/n,h=h/n,t=-(t[1]-s)/n,a=Math.floor(o/n/e),u=Math.min((1<<i)-1,Math.floor(t/e)),s=Math.floor(r/e),c=Math.max(Math.floor(h/e),0),f=(this.Pa={Oa:a,Ea:u,ja:s,Fa:c,z:i},[]),l=s;l<=a;l+=1)for(var d=c;d<=u;d+=1)f.push(new _.ca(i,l,d));return this.Da(f),f},mi.prototype.jE=function(t){for(var i=!!t.length,n=0,s=t;n<s.length;n++){var e=s[n].data;if(i)for(var r=0,h=e;r<h.length;r++){var o=h[r];if(!(i=i&&!!o.Ta))break}}return i};var vi,pi=mi;function mi(t,i,n,s){return(t=vi.call(this,t,i,n,s)||this).type="mapbox",t.hD=[AMap.getConfig().protocol+"://vdata.amap.com/style_icon/2.0/icon-normal-big.png",AMap.getConfig().protocol+"://vdata.amap.com/style_icon/2.0/icon-biz-big.png"],t.Ia(),t}var yi={ielt9:"ActiveXObject"in window&&!document.addEventListener,opts:{callback:"callback",type:"json",charset:"utf-8"},setOptions:function(t){this.opts=_.assign(this.opts,t)},bv:function(){},gv:function(){this.emit("error",{info:"TIME_OUT_A"})},JSONP:function(i,n,t){function s(){window[e]=null,r.onerror=null,r.parentNode&&r.parentNode.removeChild(r)}void 0===t&&(t={}),i=encodeURI(i);var e=_.Util.getGuid("jsonp_",6)+"_",r=document.createElement("script"),h=(r.type="text/javascript",r.charset="utf-8",r.async=!0,t=_.assign({},this.opts,t),r.onerror=function(t){s(),n&&n("error",{url:i,info:"Request Error"})},window[e]=function(t){s(),n&&n("complete",{info:"ok",url:i,data:t})},"?"),h=(-1!==i.indexOf("?")&&(h="&"),i+h+t.callback+"="+e);r.src=h,(document.getElementsByTagName("body")[0]||document.getElementsByTagName("head")[0]).appendChild(r)},Ajax:function(i,t,n){var s,e;return void 0===window.XMLHttpRequest&&window.wv?((s=this._v=new window.wv).onerror=function(t){n("error",{info:"Request Error",url:i,data:""})},s.onload=function(){n("complete",{url:i,data:s.responseText})},s.open(t.type||"GET",i),setTimeout(function(){s.send(t.content||null)},0),s):window.XMLHttpRequest?((e=new XMLHttpRequest).onreadystatechange=function(){var t;4===e.readyState&&(200===e.status?(t="arraybuffer"===e.responseType?e.response:e.responseText,n("complete",{info:"ok",url:i,data:t})):(e.abort(),n("error",{info:e.status,url:i,data:""})))},e.onerror=function(t){e.abort(),n("error",{info:"Request Error",url:i,data:""})},e.open(t.type||"GET",i,!0),e.responseType=t.responseType||"text","POST"===t.type&&e.setRequestHeader("Content-Type",t.requestContentType||"application/x-www-form-urlencoded"),e.send(t.content||null),e):void n("error",{info:"Not Support Ajax",url:i,data:""})}},bi=(gi.prototype.add=function(t,i,n,s,e){Mi.getKey(t,i,e,s)!==(this.WM?this.WM.getKey():"-1")&&(this.XR=t,this.qR=i,this.VM+=this.WM?this.WM.length:0,this.WM=new Mi(t,i,this.VM,s,e),this.jc.push(this.WM)),this.WM.add(n)},gi);function gi(){this.jc=[],this.XR=0,this.qR=0,this.VM=0}ki.getKey=function(t,i,n,s){return t+":"+i+":"+n+":"+s},ki.prototype.add=function(t){this.length+=t},ki.prototype.getKey=function(){return this.color+":"+this.width+":"+this.maxzoom+":"+this.minzoom};var Mi=ki;function ki(t,i,n,s,e){this.color=t,this.width=i,this.offset=n,this.minzoom=s,this.maxzoom=e,this.length=0}wi=Ut,_.Ei(Ai,wi),Ai.prototype.loadData=function(t,i,n,s){var h=this,e=(this.aa=t,this.ze=i,this.Zs=[],this.sa=[],t.projectionId),r=[],o=t.boundsCoord,a=t.optimalZoom,u=t.optimalResolution,c=this.ha(o,a,u),o=(this.ua.forEach(function(t){var i=t.zo,n=!1;if(t.status!==_.TileState.LOADED){for(var s=c.ja;s<=c.Oa;s+=1)for(var e=c.Fa;e<=c.Ea;e+=1){var r=h.fa(s,c.z);i.z===c.z&&i.y===e&&r===i.x&&(n=!0)}n||(t.request&&t.request.abort&&t.request.abort(),h.ua.ea(t))}}),this.qs(t,this.Zs,r));return this.Ys(o,i,e,n),this.da(t,this.sa,r,s),this.sa=this.sa.concat(this.Zs),0===o.length},Ai.prototype.Ys=function(o,t,z,C){if(!(this.aa.optimalZoom<this.xt[0]||this.aa.optimalZoom>this.xt[1])){this.Da(o);var i=this.map.mapStyle.vn.MS("traffic");i&&i.multiFillColors&&((i=i.multiFillColors).congested&&i.congested,i.slow&&i.slow,i.smooth&&i.smooth,i.seriousCongested&&i.seriousCongested,i.unknown)&&i.unknown;for(var S=this.layer.getOptions().rZ,a=this,n=0,s=o.length;n<s;n+=1)!function(t){var t=o[t],M=_.Util.Rg(t.x,t.y,t.z),i=a.ll(M),k=new _.Sw(t),w=(a.ua.Qo(k),_.ProjectionManager.getProjection(z).getResolution(t.z)),n=(h=t.x*a.Xa*w)+a.Xa*w,s=(t=t.y*a.Xa*w)+a.Xa*w,e=_.V[z].Xs(h,t),r=_.V[z].Xs(n,s),h=e[0],n=r[0],t=r[1],s=e[1],x=(k.Ro=[h,t,n,s],k.status=_.TileState.LOADING,_.lcs.getLocalByCoord([k.Ro[0],k.Ro[1]])),A=k.zo.z>_.za;A&&(k.Ro[0]-=x.center[0],k.Ro[1]-=x.center[1],k.Ro[2]-=x.center[0],k.Ro[3]-=x.center[1]),k.request=yi.Ajax(i,{},function(t,i){k.data={};try{i=JSON.parse(i.data)}catch(t){return k.status=_.TileState.LOADED,void C()}if(i=i.data[M.join("_")],"complete"===t&&i){for(var n=new bi,s=new _.J_,e=0,r=i.length;e<r;e++)for(var h=i[e],o=0,a=h.length;o<a;o++)for(var u=h[o],c=.6*u[0]*S,f=0,l=u[1].length;f<l;f++){for(var d=[],v=_.Util.Eg(u[1][f]),p=0,m=v.length;p<m;p+=2){var y=w*(256*k.zo.x+v[p]),b=w*(256*k.zo.y+v[p+1]),y=_.V[z].Xs(y,b);A&&(y[0]-=x.center[0],y[1]-=x.center[1]),d.push(y[0],y[1])}var g=s.hb(d).Iw;n.add(e,c,g,8,20)}k.data={$c:s,Uc:n,Hs:x}}k.status=_.TileState.LOADED,C()})}(n)}};var wi,xi=Ai;function Ai(t,i,n,s){return(t=wi.call(this,t,i,n,s)||this).Qs=[3,17],t.Xa=256,t.Za=t.qa=!1,t.ll=function(t){return AMap.getConfig().protocol+"://vdata.amap.com/traffic?key="+AMap.getConfig().key+"&v="+AMap.getConfig().version+"&t="+t+"&w="+(new Date).getTime()},t}var zi,Si={nebula:"tile",mapbox:"tile",nebulaLabel:"tile",indoor:"other"},Ti=(zi=ct,_.Ei(Li,zi),Li.prototype.loadData=function(e,t,i,r,n){var s,h=this,o=this.Yh;for(s in Object.keys(o).length,o)!function(s){o.hasOwnProperty(s)&&o[s].YE(function(t,i){var n=i.GW,i=i.cb;"worker"===(void 0===n?"main":n)?(h.Ye[s]=i,r.gn.innerLabelsLoadData({id:s,bounds:e.bounds.slice(),zoom:e.optimalZoom},function(t){Object.keys(t).length})):(t=function(t,i){var n,s,e=i.R_,r=i.z_,h={};for(n in t)t.hasOwnProperty(n)&&(s=t[n],s=new _.eG({R_:e,z_:r}).Ns(s.data,{zoom:s.zoom,from:"inner",center:s.center}),h[n]=new _.La(n,s));return h}(t,{R_:h.Mf,z_:h.ac}),i&&i(t))})}(s);return!0},Li.prototype.getData=function(t){var i,n,s,e,r=this.Yh,h={tile:[],other:[]},o=!0;for(i in r)r.hasOwnProperty(i)&&(e=r[i],n=Si[i]||"other",e)&&(s=e.getData(t),e=e.lo(),h[n].push(s),o=o&&e);return this.Oo=o,this.Fo(o),h},Li.prototype.getSources=function(){return this.Yh},Li.prototype.addSource=function(t,i){this.Yh[t]=i},Li.prototype.Xh=function(t){delete this.Yh[t]},Li.prototype.uU=function(t){var i=t.id,n=this.Ye;n[i]&&n[i](t)},Li.prototype.destroy=function(){var t,i,n=this.Yh;for(t in n)n.hasOwnProperty(t)&&(i=n[t])&&i.destroy()},Li.prototype.reload=function(){var t,i,n=this.Yh;for(t in n)n.hasOwnProperty(t)&&(i=n[t])&&i.reload&&i.reload()},Li.prototype.Ia=function(){this.map.gn.on("dynamicTextVerticeLoadedByTile",this.uU.bind(this))},Li);function Li(t,i,n,s){return(t=zi.call(this,t,i,n,s)||this).Yh={},t.Ye={},t.Mf=n.R_,t.ac=n.z_,t.Ia(),t}var Ii,Di=_.Support.scale,Oi=(Ii=s,_.Ei(Ri,Ii),Ri.prototype.loadData=function(t,i,n,s){var e=this;if(!s.gn.dE)return!1;this.aa=t,this.sa=[];for(var r=t.bounds,h=this.ra(t.optimalZoom),o=this.ha(r,h),r=_.map(o,function(t){var i=e.fa(t.x,t.z);return t.z+","+i+","+t.y}),a=this.QH.qH(r).yB,u=[],c=0;c<o.length;c++){var f,l,d=o[c],v=new _.ca(d.z,this.fa(d.x,d.z),d.y),p=new _.ca(d.z,d.x,d.y),m=_.zB.ALL,y=this.ua.getTile(v,!0);y?(f=this.ua.MD(y.tag,m))&&(y.tag=m,l=d.key+","+_.Util.SD(f),a.indexOf(l)<0)&&u.push(l):(l=v.key+","+_.Util.SD(m),a.indexOf(l)<0&&((d=new _.pa(v)).status=_.TileState.LOADING,this.ua.Jo(d),d.tag=m,u.push(l))),!y||y.status!==_.TileState.LOADED&&y.status!==_.TileState.RELOADING||this.sa.push(p)}var b=(r=this.OE(u)).overseaTile,g=r.chinaTile,r=r.mapboxTile;return this.PE(b,"oversea"),this.PE(g,"china"),this.PE(r,"mapbox"),this.da(t,this.sa,[],s),this.zD(u,t,h,s,n,"building"),0===u.length},Ri.prototype.destroy=function(){this.mapStyle&&this.mapStyle.destroy&&(this.mapStyle.destroy(),delete this.mapStyle),this.R_&&this.R_.destroy&&(this.R_.destroy(),delete this.R_)},Ri.prototype.reload=function(){var i=this;this.ua.forEach(function(t){t.status!==_.TileState.LOADED&&t.request&&(t.request.cancel(),delete t.request),t.destroy(),i.ua.ea(t)}),this.sa=[],this.la=[]},Ri);function Ri(t,i,n,s){return(i=Ii.call(this,t,i,n,s)||this).Xa=t.tileSize,i._tileUrl=t.tileUrl,s=_.Support.$e?50:200,i.ua=new Ct(s),n.gn.Ha({scale:Di,showLabel:n.showLabel,DD:-1!==location.search.indexOf("forceAll")}),i.R_=n.R_,i.z_=n.z_,n.gn.Ja(AMap.getConfig().protocol),i.mapStyle=n.mapStyle,i.mapStyle.pn(function(){}),i.Ia(),i.sD(),i}Ei=ct,_.Ei(ji,Ei),ji.prototype.loadData=function(t,i,n,s,e){var r;if(!(e=e.getSource("nebula")))return this.gs&&(r=this.gs.VR.showId)&&this.GR([r]),!1;for(var h=e.getData(t).tiles,o=h.length,a=[],u=0;u<o;u++)for(var c=0,f=h[u].data||[];c<f.length;c++){var l=f[c];if(l.indoorInfo)for(var d=l.indoorInfo,v=d.length,p=0;p<v;p++){for(var m=d[p],y=!1,b=0;b<a.length;b++)m===a[b]&&(y=!0);y||a.push(m)}}return this.GR(a),this.Fo(!0),!0},ji.prototype.getData=function(){return this._indoorData},ji.prototype.lo=function(){return!0},ji.prototype.GR=function(t,i){if(!t||t.length<1)return null;if(!this.map.isDOMMode()){for(var s=(n=this.gs).VR,e=(n._map,[]),n=this._config.server+"/v3/indoor/indoormaps?",r=t,h=r.length,o=[],a=[],t=[],u=!1,c=0;c<h;c++){var f=r[c],l=1,d=(this._indoorData.data[f]||(this._indoorData.data[f]={}),s.floorInfo&&s.floorInfo[f]&&(d=s.floorInfo[f])&&(l=d),this._indoorData.data[f]);d&&d.data&&d.data[l]||(u=!0,o.push(l),a.push(0),e.push(f))}this.LL=e,t.push("poiid="+e.join(";")),t.push("floor="+o.join(";")),t.push("version="+a.join(";")),t.push("s=rsv3"),t.push("from=indoorH5Map"),t.push("servicetype=unify"),t.push("key="+this._config.key),this._config.jscode?t.push("jscode="+this._config.jscode):this._config.gaodeserver&&(n=this._config.gaodeserver+"/v3/indoor/indoormaps?"),n+=t.join("&"),u&&this.ZR.url!==n?(this.ZR.url=n,this.YR(n,this.jF)):(this.jF(),i&&i())}},ji.prototype.JR=function(t,i,n){var s=this;if(!t||!i)return!1;this.GR([t],function(){s.gs&&s.gs._map&&s.gs._map.setNeedUpdate(!0),n&&n()})},ji.prototype.YR=function(t,u){var c=this,i=new XMLHttpRequest;i.onreadystatechange=function(){4===i.readyState&&200===i.status&&c.map.gn.JB(i.response,function(t,i){if(t)console.log(t);else for(var n=0,s=Object.keys(i);n<s.length;n++)for(var e=s[n],r=(c._indoorData.data[e]&&c._indoorData.data[e].data||(c._indoorData.data[e].data={}),c._indoorData.data[e].building=i[e].building,i[e].data),h=0,o=Object.keys(r);h<o.length;h++){var a=o[h];c._indoorData.data[e].data[a]=r[a]}u()})},i.open("GET",t,!0),i.responseType="arraybuffer",i.send()};var Ei,Pi=ji;function ji(t,i,n,s){var e=Ei.call(this,t,i,n,s)||this;return e.jF=function(){var t;e.gs&&(t=e.gs.getRender())&&t.render(e._indoorData)},e.gs=s,e._config=AMap.getConfig(),e._indoorData={extData:{},data:{}},e.LL=[],e.ZR={url:null,status:!1},e}var Bi,Wi,Fi=_.Support.scale,ct=(Bi=ct,_.Ei(f,Bi),f.prototype.loadData=function(t,i,n,s){var e=this;if("optimise"===s.loadData()&&s.TL())return!1;this.aa=t,this.sa=[];for(var r=t.bounds,h=this.ra(t.optimalZoom),o=this.ha(r,h),a=[],u=t.optimalZoom,r=_.map(o,function(t){var i=e.fa(t.x,t.z);return t.z+","+i+","+t.y}),c=this.KH.qH(r),f=[],l=0;l<o.length;l++){var d,v,p=o[l],m=new _.ca(p.z,this.fa(p.x,p.z),p.y),y=new _.ca(p.z,p.x,p.y),b=_.Util.kD(m.key,u),g=this.ua.getTile(m,!0);g?(d=this.ua.MD(g.gB,b))&&(g.gB=b,v=p.key+","+_.Util.SD(d),c.yB.indexOf(v)<0)&&f.push(v):(v=m.key+","+_.Util.SD(b),c.yB.indexOf(v)<0&&((m=new _.pa(m)).status=_.TileState.LOADING,m.xB=_.TileState.LOADING,this.ua.Jo(m),m.tag=b,m.gB=b,f.push(v))),!g||g.xB!==_.TileState.LOADED&&g.xB!==_.TileState.RELOADING||this.sa.push(y),g&&(g.xB===_.TileState.LOADED||g.xB===_.TileState.RELOADING)||a.push(p),g&&g.xB===_.TileState.LOADED&&g.version&&g.version!==this.VH&&(this.sa.push(y),g.xB=_.TileState.RELOADING,f.push(p.key+","+_.Util.SD(g.gB)),d=this.ua.MD(g.gB,b))&&(v=p.key+","+_.Util.SD(d),c.yB.indexOf(v)<0)&&f.push(v)}this.da(t,this.sa,a,s);var M,k,w,r=this.map.getOutseaState(),x=this.map.getOutseaDataType();return r&&!x?9.8<=h?(h=(k=this.OE(f)).overseaTile,w=k.chinaTile,M=k.mapboxTile,this.PE(h,"oversea"),this.PE(w,"china"),this.PE(M,"mapbox"),s.showLabel&&this.bB(k.chinaTile,t),s.showLabel&&this.bB(k.overseaTile,t,"outsea")):(this.PE(f,"china"),s.showLabel&&this.bB(f,t,"a00")):r&&x&&"mapbox"===x?9.8<=u?(w=(k=this.OE(f)).chinaTile,this.PE(w,"china"),s.showLabel&&this.bB(f,t)):(this.PE(f,"china"),s.showLabel&&this.bB(f,t,"a00")):(this.PE(f,"china"),s.showLabel&&this.bB(f,t)),0===f.length},f.prototype.getData=function(i){var n=this,t=i.bounds,s=this.ra(i.optimalZoom),e=this.ha(t,s),r=[],h={},o=(14===s&&(h=this.ha(t,15,!0)),this.map.qF());if(this.ua.QF(o),this.sa.sort(function(t){return n.ra(i.optimalZoom)===t.z?1:-1}),0<this.sa.length)for(var a=0;a<this.sa.length;a++){var u,c,f,l=this.sa[a],d=this.ua.getTile(l,!0),v=0,p=0,m=[0,0],y=i.centerCoord;d?(d.localCoord||(c=_.wa.ga(d.zo.x,d.zo.y,d.zo.z,"EPSG:3857"),u=_.lcs.getLocalByCoord([c[0],c[1]]),d.localCoord=u,d.Ro=c),u=_.lcs.getLocalByCoord([y[0],y[1]]),i.optimalZoom>=_.Ra?(f=_.lcs.getSize(),v=d.localCoord.x-u.x,p=d.localCoord.y-u.y,0!=v&&(v*=f[0],m[0]=v),0!=p&&(p*=f[1],m[1]=p),i.optimalZoom>=_.Ra&&_.za>=d.zo.z&&(m[0]=-u.center[0],m[1]=-u.center[1])):i.optimalZoom<_.Ra&&_.za<d.zo.z&&(m[0]=u.center[0],m[1]=u.center[1])):(c=new _.ca(l.z,this.fa(l.x,l.z),l.y),(y=this.ua.getTile(c,!0))&&(d=new _.pa(l),f=1<<l.z,(l.x<0||l.x>=f)&&(v=Math.floor(l.x/f),m[0]+=20037508.342789244*v*2),p=y.gB,d.Ro=y.Ro,d.ID(y),d.Sa=m,d.status=y.status,d.tag=p,d.gB=p)),d&&(d.stamp=o,d.Sa=m,r.push(d))}var b=i.optimalZoom,t=_.every(e,function(s){return _.some(r,function(t){var i=t.zo.key,n=t.zo.z,n=_.Util.VF(n,b),t=t.gB,t=_.Util.LD(t,n);return i===s.key&&t})}),g=this.map.getOutseaState(),M=this.map.getOutseaDataType(),e=(g&&!M&&(t=!(M=_.filter(e,function(t){return!(t=n.NE.getTile(t))||!t.boundsStatus||!1!==t.boundsStatus.isInNebulaOversea})).length||_.every(M,function(s){return _.some(r,function(t){var i=t.zo.key,n=t.zo.z,n=_.Util.VF(n,b),t=t.gB,t=_.Util.LD(t,n);return i===s.key&&t})})),r&&0<=r.length&&this.Fo(!0),this.jE(r)),M=(t&&(this.a_=!0,this.map.bZ.dynamic.set("firstAllLoaded",!0)),e&&this.map.bZ.dynamic.set("firstLabelDataAllLoaded",!0),t&&e&&this.Fo(!0),{s_:this.a_,fo:!!t&&e,yZ:e,tiles:r,Ca:h,outseaData:void 0});return g&&r.length&&(t=this.map.bZ.MZ.wZ.gZ(),M.outseaData=t),M.tiles=this.UE(r,s),M},f.prototype.pe=function(t){return t=new _.ca(t[0],t[1],t[2]),this.ua.getTile(t)},f.prototype.ZE=function(t){return!1},f.prototype.OE=function(t){for(var i=t.length,n=[],s=[],e=[],r=0;r<i;r++){var h=void 0,o=void 0,a=t[r],u=a.split(","),c=new _.ca(u[0],u[1],u[2]),f=this.NE.getTile(c);if(f&&f.boundsStatus)h=f.boundsStatus.isInChina,o=f.boundsStatus.isInNebulaOversea;else{if(!(f=_.wa.ga(parseInt(u[1],10),parseInt(u[2],10),parseInt(u[0],10),"EPSG:3857")))continue;u=[[f[0],f[1]],[f[2],f[1]],[f[2],f[3]],[f[0],f[3]]],h=this.VE(u,"china",a),o=this.VE(u,"oversea",a),(f=new _.pa(c)).boundsStatus={isInChina:h,isInNebulaOversea:o},this.NE.Jo(f)}h&&n.push(a),o&&s.push(a),h||o||e.push(a)}return{chinaTile:n,overseaTile:s,mapboxTile:e}},f.prototype.ra=function(t){return("fast"!==this.map.bZ.MZ.drawMode||this.map.bZ.dynamic.get("firstPaint")?{2:3,3:3,4:3,5:3,6:6,7:6,8:8,9:8,10:10,11:10,12:10,13:12,14:12,15:15,16:15,17:15,18:15,19:15,20:15,21:15,22:15,23:15,24:15,25:15,26:15,27:15,28:15,29:15,30:15}:{2:3,3:3,4:3,5:3,6:6,7:6,8:8,9:8,10:8,11:8,12:8,13:12,14:12,15:15,16:15,17:15,18:15,19:15,20:15,21:15,22:15,23:15,24:15,25:15,26:15,27:15,28:15,29:15,30:15})[t]},f.prototype.YE=function(t){var i=this;return t(null,{GW:"worker",cb:function(t){i.dynamicTextVerticeLoadedByTile(t)}}),!0},f.prototype.destroy=function(){this.ua.forEach(function(t){t.status!==_.TileState.LOADED&&t.request&&(t.request.cancel(),delete t.request),t.destroy()}),this.ua.destroy(),this.sa=[],this.la=[],this.mapStyle&&this.mapStyle.destroy&&(this.mapStyle.destroy(),delete this.mapStyle),this.R_&&this.R_.destroy&&(this.R_.destroy(),delete this.R_)},f.prototype.reload=function(){this.ua.forEach(function(t){t.status!==_.TileState.LOADED&&t.request&&(t.request.cancel(),delete t.request),t.reload()}),this.sa=[],this.la=[]},f.prototype.Aa=function(t){var i;t.zo&&(i=this.ua.getTile(t.zo))&&(i.rO({Ta:!0},t.tag),i.xa({Ta:!0},t.tag),i.JE({Ta:!0},t.tag))},f.prototype.setTileCacheSize=function(t){t=t||(_.Support.$e?30:100),this.ua.Xo(t)},f.prototype.UH=function(t){this.VH=t},f.prototype.dynamicTextVerticeLoaded=function(t){var i=t.data,n=t.XE;if(i instanceof _.ca)return(s=this.ua.getTile(i))?(s.data||s.xa({},t.tag),void s.rO({},t.tag)):void 0;var s=i[Object.keys(i)[0]];if(s=this.ua.getTile(s.zo,!0)){s.data||s.xa({},t.tag);var e,r,h={};for(e in i)i.hasOwnProperty(e)&&(r=i[e],h[e]=new _.La(r.zo,r));s.rO({Ta:!0,labels:h,XE:n},t.tag),s.xa({Ta:!0},t.tag),s.JE({Ta:!0},t.tag),s.xB=_.TileState.LOADED,this.map.Mv.t0(s.zo),this.Eo()}},f.prototype.dynamicTextVerticeLoadedByTile=function(t){for(var i=0,n=t.data;i<n.length;i++){var s=n[i];this.dynamicTextVerticeLoaded({data:s.data,tag:s.tag,XE:s.XE})}},f.prototype.Ia=function(){this.map.on("tileSdfInfoFinished",this.Aa.bind(this))},f.prototype.bB=function(t,i,n){i={zoom:i.zoom,projectionId:i.projectionId,mH:_.Support.mH},this.KH._B(t,i,n)},f.prototype.cP=function(){for(var t,i=this.map.getLayers(),n=0;n<i.length;n++)if("AMap.Buildings"===(s=i[n]).CLASS_NAME&&!s.getState().u$){t=s;break}if(!t)for(var s,n=0;n<i.length;n++)if("AMap.Buildings"===(s=i[n]).CLASS_NAME){t=s;break}return t},f.prototype.ma=function(t,i){var n,s=new RegExp(/\{(\w|\,)+\}/g);return s.test(this._tileUrl)?(n=this._tileUrl.match(s)[0].replace(/[\{|\}]/g,"").split(","),this._tileUrl.replace(s,n[(t+i)%4])):this._tileUrl},f.prototype.AD=function(){var t=new RegExp(/\{(\w|\,)+\}/g),i=this._tileUrl.match(t)[0].replace(/[\{|\}]/g,"").split(","),n=i.length,t=this._tileUrl.replace(t,i[this.$D%n]);return this.$D=(this.$D+1)%n,t},f.prototype.ha=function(t,i,n){void 0===n&&(n=!1);var s=[t[0],t[3]],t=[t[2],t[1]],s=this.Ga(s,i),t=this.Ga(t,i),e=s[0],r=s[1],h=t[0],o=t[1];if(n)return{ja:e,Fa:r,Oa:h,Ea:o,z:i};this.Pa={ja:e,Fa:r,Oa:h,Ea:o,z:i};for(var a=[],u=e;u<=h;u+=1)for(var c=r;c<=o;c+=1)a.push(new _.ca(i,u,c));return this.Da(a),a},f.prototype.da=function(t,i,n,s){var e=[3,6,8,10,12,15],r=this.ra(t.optimalZoom);if(this.Za)for(var h=Math.min(14,r+3),o=r+1;n.length&&o<=h;o+=1)if(-1!==e.indexOf(o)){for(var a=o-r,u=[],c=[],f=n.length-1;0<=f;--f)for(var l=n[f].x<<a,d=n[f].y<<a,v=1<<a;0<=v;--v)for(var p=1<<a;0<=p;--p){var m=new _.ca(o,this.fa(l+v,o),d+p),y=new _.ca(o,l+v,d+p);((M=this.ua.getTile(m,!0))&&M.status===_.TileState.LOADED?c:u).push(y)}c.length&&i.push.apply(i,c),n=u}if(this.qa)for(var b=this.xt[0],o=r-1;n.length&&b<=o;--o)if(-1!==e.indexOf(o)){for(var c=[],u=[],g={},f=n.length-1;0<=f;--f){var M,k=n[f],a=o,w=k.z-a,v=k.x>>w,p=k.y>>w;g[k=(m=new _.ca(a,v,p)).key]||(w=new _.ca(a,this.fa(v,a),p),y=new _.ca(a,v,p),M=this.ua.getTile(w,!0),g[k]=!0,(M&&M.status===_.TileState.LOADED?c:u).push(y))}c.length&&i.push.apply(i,c),n=u}return i},f.prototype.Da=function(t){var e,r,h;t.length&&(e=this.Pa.z,r=(this.Pa.ja+this.Pa.Oa)/2,h=(this.Pa.Fa+this.Pa.Ea)/2,t.sort(function(t,i){var n=(t.x<<e-t.z)-r,t=(t.y<<e-t.z)-h,s=(i.x<<e-i.z)-r;return n*n+t*t<=s*s+(i=(i.y<<e-i.z)-h)*i?-1:1}))},f.prototype.Ga=function(t,i){var n=180/(i=Math.pow(2,i));return[Math.floor(t[0]/(360/i))+i/2,i/2-Math.ceil(t[1]/n)]},f.prototype.fa=function(t,i){for(var n=1<<(i=i||this.aa.optimalZoom);t<0||n<=t;)t=n<=t?t-n:t<0?n+t:t;return t},f.prototype.sD=function(){var e,r,h=this;this.map.bZ.dynamic.get("_preloadNebulaIcons")||(this.map.bZ.dynamic.set("_preloadNebulaIcons",!0),e=this.hD,(r=this.z_).loadImages(e,{type:"icon",imageBitmap:_.Support.imageBitmap,cb:function(){for(var t=[],i=0;i<e.length;i++){var n=e[i],s=r.getImage(n);t.push({img:s.img,name:n,hv:i,width:s.width,height:s.height})}h.map.so.sv(t)}}))},f.prototype.PE=function(t,i){for(var n=0,s=t;n<s.length;n++){var e=s[n].split(",").slice(0,3).join(",");(e=this.ua.xf(e))&&(e.region=i)}},f.prototype.UE=function(t,i){void 0===t&&(t=[]);var n=[];if(10<=i){for(var s=0,e=t;s<e.length;s++){var r=e[s];"china"!==r.region&&"oversea"!==r.region||n.push(r)}return n}return t},f.prototype.jE=function(t){for(var i=!!t.length,n=0,s=t;n<s.length;n++){var e=s[n].data;if(i)for(var r=0,h=e;r<h.length;r++){var o=h[r];if(!(i=i&&!!o.Ta))break}}return i},f);function f(t,i,n,s){var a=Bi.call(this,t,i,n,s)||this,i=(a.xt=_.zoomRange,a.sa=[],a.la=[],a.qa=!0,a.Za=!0,a.a_=!1,a.$D=0,a.hD=[AMap.getConfig().protocol+"://vdata.amap.com/style_icon/2.0/icon-normal-big.png",AMap.getConfig().protocol+"://vdata.amap.com/style_icon/2.0/icon-biz-big.png"],a.VH="",a.wH=function(t){!a.map.yH||parseInt(t.key.split(",")[0],10)<10||a.map.yH.kH(t.key)},a.Xa=t.tileSize,a._tileUrl=t.tileUrl,a.tG=null,_.Support.$e?30:200);return a.ua=new Ct(i),a.NE=new Lt(i),window.xZ=a.ua,n.gn.Ha({scale:Fi,showLabel:n.showLabel,DD:-1!==location.search.indexOf("forceAll")}),a.R_=n.R_,a.z_=n.z_,n.gn.Ja(AMap.getConfig().protocol),a.mapStyle=n.mapStyle,a.mapStyle.pn(function(t){n&&n.gn&&n.gn.Ka({value:t,TY:"fast"===a.map.bZ.MZ.drawMode})}),a.Ia(),a.sD(),a.ua.on("delete",a.wH),a.KH=new Dt(function(t,o,i,n){var s=a.AD();return!n||"outsea"!==n&&"a00"!==n||(s=_.Support.wasm?s.replace("/nebula/v3","/oversea/v3"):s.replace("/nebula/v2","/oversea/v2")),new _.vH(a.map.gn.RD({url:s,projectionId:i.projectionId,ya:t,ZL:i.zoom,mH:i.mH},function(t,i){if(a.Eo(),a.KH.CB(o),t)console.log(t),a.map.emit("TileDecodeError",{type:"nebulasdf",err:t});else if(i)for(var n=0,s=Object.keys(i);n<s.length;n++){var e,r,h=s[n].slice(0,-2);(h=a.ua.xf(h))&&(h.status=_.TileState.LOADED,h.xB=_.TileState.LOADED,e=_.wa.ga(h.zo.x,h.zo.y,h.zo.z,"EPSG:3857"),r=_.lcs.getLocalByCoord([e[0],e[1]]),h.localCoord=r,h.Ro=e)}else console.log("no data"),a.map.emit("TileDecodeError",{type:"nebulasdf",err:"no data"})}))},function(t){for(var i=0,n=t;i<n.length;i++){var s=n[i];(s=a.ua.xf(s.slice(0,-2)))&&s.status!==_.TileState.LOADED&&a.ua.ea(s)}}),_.Support.$e&&!_.Support.iPad&&(a.map.on("zoomend",function(){15<=a.map.getZoom()?a.ua.Xo(6):a.ua.Xo(20)}),15<=a.map.getZoom())&&a.ua.Xo(6),a}function Ni(t,i,n,s){return(t=Wi.call(this,t,i,n,s)||this).Rs=null,t}Wi=Ut,_.Ei(Ni,Wi),Ni.prototype.Ys=function(a,u,c,f){var l=this;if(!(this.aa.optimalZoom<this.xt[0]||this.aa.optimalZoom>this.xt[1])){this.Da(a);for(var d=this,i=0,n=a.length;i<n;i+=1)!function(t){var n=d.layer.getLayerConfig(),t=a[t],h=(d.ma().replace("[z]",t.z+"").replace("[x]",t.x+"").replace("[y]",t.y+""),new _.Vs(t)),n=(d.ua.Qo(h),n.getTileUrl&&n.getTileUrl(t.x,t.y,t.z),_.ProjectionManager.getProjection(c).getResolution(t.z)),e=(s=t.x*d.Xa*n)+d.Xa*n,n=(t=t.y*d.Xa*n)+d.Xa*n,r=_.V[c].Xs(s,t),o=_.V[c].Xs(e,n),s=r[0],e=o[0];t=o[1],n=r[1],h.Ro=[s,t,e,n],h.status=_.TileState.LOADING,setTimeout(function(){var t,i;if(u){if(t=_.lcs.getLocalByCoord([h.Ro[0],h.Ro[1]]),h.zo.z>_.za&&(h.Ro[0]-=t.center[0],h.Ro[1]-=t.center[1],h.Ro[2]-=t.center[0],h.Ro[3]-=t.center[1]),i=u.fe(new Float32Array([h.Ro[0],h.Ro[1],0,1,h.Ro[2],h.Ro[1],1,1,h.Ro[0],h.Ro[3],0,0,h.Ro[2],h.Ro[1],1,1,h.Ro[2],h.Ro[3],1,0,h.Ro[0],h.Ro[3],0,0]),16),!l.Rs){var n=document.createElement("canvas"),s=n.getContext("2d");if(s){n.height=n.width=256,n.style.height=n.style.width="256px",s.font="14px Verdana",s.fillStyle="rgba(76,83,98,0.15)",s.rotate(-15*Math.PI/180);for(var e="暂未获得高德开放平台商用授权",r=0;r<e.length;r++)s.fillText(e[r],17*r-35,180);s.stroke()}l.Rs=n}(n=u.createTexture(l.Rs,{Zi:!0})).bind(u.gl.MIRRORED_REPEAT,u.gl.LINEAR,u.gl.LINEAR_MIPMAP_NEAREST),h.data={texture:n,zs:i,Js:n,Hs:t}}h.status=_.TileState.LOADED,f()},10)}(i)}};var _i={nebula:s,nebulaLabel:ct,building:Oi,sky:ui,mask:li,inner:Ti,image:Bt,custom:Xt,gl_custom:hi,raster:Ut,overlay:Vt,labelsLayer:Gt,vectorTile:Qt,districtVectorTile:ti,mapboxVectorTile:si,indoor:Pi,mapbox:pi,vectortraffic:xi,markLayer:Ni},Ui=(Yi.addSource=function(t,i){_i[t]||(_i[t]=i)},Yi.prototype.addSource=function(t,i,n){return("nebula"===t.id||"indoor"===t.id)&&this.Yh[t.id]||this.Yh[t.id]||(this.Yh[t.id]=new _i[t.type](t,i,this.map,n),n.source=this.Yh[t.id]),this.Yh[t.id]},Yi.prototype.getSource=function(t){return this.Yh[t]},Yi.prototype.Xh=function(t){delete this.Yh[t]},Yi.prototype.getData=function(t,i,n){return this.Yh[t].getData(i,n)},Yi.prototype.loadData=function(t,i,n){for(var s=0,e=i.Zdt()||[];s<e.length;s++){var h=(r=e[s]).getOptions(),r=r.getSource();_.Util.dS(i.getZoom(),h.zooms)&&r&&h.visible&&0<h.opacity&&r.loadData(t,n,function(){i.setNeedUpdate(!0)},i,this)}},Yi.prototype.destroy=function(){for(var t in this.Yh)this.Yh[t]&&this.Yh[t].destroy();this.Yh={}},Yi.prototype.UH=function(t){for(var i in this.Yh)this.Yh[i]&&this.Yh[i].UH&&this.Yh[i].UH(t)},Yi.prototype.i0=function(t,i){if(this.Yh[t])return this.Yh[t].ua.getTile(i,!1)},Yi.prototype.t0=function(t){var i=this.i0(_.n0.nebulaLabel,t);(t=15===t.z?this.i0(_.n0.nebula,t.s0(14)):this.i0(_.n0.nebula,t))&&i&&i.KE(t.data)},_.dZ([_.pZ("SourceManager")],Yi));function Yi(t){this.map=t,this.Yh={}}Zi=_.Event,_.Ei(d,Zi),d.prototype.onAdd=function(){},d.prototype.v$=function(){},d.prototype.Hh=function(t){this.uo=t},d.prototype.Do=function(t){return this.Jh=t,this.Jh},d.prototype.setMap=function(t){var i,n=this;null===t&&this.map?this.map.removeLayer(this):(this.map=t)&&(i=t.getLayers(),_.find(i,function(t){return t.getLayerConfig().id===n.getLayerConfig().id})||t.addLayer(this))},d.prototype.Kh=function(t){var i=this;(this.source=t)&&this.source.on("complete",function(){i.emit("complete")})},d.prototype.setzIndex=function(t){this.Qh=t,this.map&&this.map.setNeedUpdate(!0)},d.prototype.setOpacity=function(t){this.tl=t,this.map&&this.map.setNeedUpdate(!0)},d.prototype.getOpacity=function(){return this.tl},d.prototype.getSource=function(){if(this.uo)return this.uo.getSource(this.co())},d.prototype.getzIndex=function(){return this.getLayerConfig().zIndex},d.prototype.getMap=function(){return this.map},d.prototype.getRender=function(){return this.Jh},d.prototype.getLayerConfig=function(){return{id:this._id,zooms:this.xt,zIndex:this.Qh,opacity:this.tl,visible:this.il,createTile:void 0,rejectMapMask:this._rejectMapMask}},d.prototype.getOptions=function(){var t=this.getLayerConfig(),i=this._opts||{};return _.assign({},i,t)},d.prototype.getZooms=function(){return this.xt},d.prototype.setZooms=function(t){this.xt=t,this.map&&this.map.setNeedUpdate(!0)},d.prototype.getVisible=function(){return this.il},d.prototype.beforeRender=function(){},d.prototype.afterRender=function(){},d.prototype.get=function(t){return this.getOptions()[t]},d.prototype.vi=function(t){return null},d.prototype.lo=function(){if(this.source)return this.source.lo()},d.prototype.T$=function(){return this._id},d.prototype.show=function(){this.il=!0,this.map&&this.map.setNeedUpdate(!0)},d.prototype.hide=function(){this.il=!1,this.map&&this.map.setNeedUpdate(!0)},d.prototype.destroy=function(){this.Jh&&this.Jh.destroy&&(this.Jh.destroy(),delete this.Jh)},d.prototype.onCreated=function(){this.map&&this.map.addLayer(this)};var Zi,s=_.dZ([_.pZ("Layer")],d);function d(t){void 0===t&&(t={});var i=Zi.call(this)||this;return i.el="AMap.Layer",i.CLASS_NAME="AMap.Layer",i.hS=_.Util.stamp(i),i.il=!0,i.tl=1,i.xt=_.zoomRange,i._id="layer",i.nl=!0,i._id="layer_"+_.Util.uuid(),i.xt=t.zooms||_.zoomRange,i.tl=void 0===t.opacity?1:t.opacity,i.Qh=t.zIndex||1,i._rejectMapMask=void 0!==t.rejectMapMask&&t.rejectMapMask,i.il=void 0===t.visible||t.visible,i.AF=void 0!==t.depthTest&&Boolean(t.depthTest),i.IF=void 0!==t.ce&&Boolean(t.ce),i.wl=t.cacheSize,i.map=t&&t.map||null,i._opts=t,i}Xi=s,_.Ei(Hi,Xi),Hi.prototype.getState=function(){return{ol:!0,al:!0,visible:this.il,opacity:this.tl,layer:this,rejectMapMask:this._rejectMapMask,depthTest:this.AF,ce:this.IF,cacheSize:this.wl}},Hi.prototype.getLayerConfig=function(){var t=Xi.prototype.getLayerConfig.call(this);return t.mapNumber="GS(2021)6375",t},Hi.prototype.getSourceConfig=function(){return{id:"nebula",type:"nebula",tileUrl:AMap.getConfig().protocol+(_.Support.wasm?"://{vdata,vdata01,vdata02,vdata03,vdata04}.amap.com/nebula/v3":"://{vdata,vdata01,vdata02,vdata03,vdata04}.amap.com/nebula/v2"),tileSize:0,zooms:_.zoomRange}},Hi.prototype.co=function(){return"nebula"},Hi.prototype.destroy=function(){this.Jh&&this.Jh.destroy&&(this.Jh.destroy(),delete this.Jh)},Hi.prototype.show=function(){Xi.prototype.show.call(this);var t=this.iP();t&&t.show(),(t=this.map&&this.map.getLayerByClass("AMap.Inner.LabelsLayer"))&&t.oP()&&t.show()},Hi.prototype.hide=function(){Xi.prototype.hide.call(this);var t=this.iP();t&&t.hide(),this.rP()},Hi.prototype.v$=function(){Xi.prototype.v$.call(this);var t=this.iP();t&&this.map.removeLayer(t),this.rP()},Hi.prototype.Hh=function(t){this.uo=t,this.uo.getSource(this.co()).setTileCacheSize(this.wl)},Hi.prototype.rP=function(){var t=this.map&&this.map.getLayerByClass("AMap.Inner.LabelsLayer");t&&t.aP()&&t.hide()},Hi.prototype.iP=function(){var t;if(this.map)for(var i=null==(t=this.map)?void 0:t.getLayers(),n=0;n<i.length;n++){var s=i[n];if("AMap.Buildings"===s.CLASS_NAME&&s.getState().u$)return s}};var Xi,Ji=Hi;function Hi(){var t=null!==Xi&&Xi.apply(this,arguments)||this;return t.CLASS_NAME="AMap.NebulaLayer",t}var Vi,qi="inner.labelsLayer",Qi="inner",$i=(Vi=s,_.Ei(tn,Vi),tn.prototype.getState=function(){return _.assign({},{layer:this,rejectMapMask:this._rejectMapMask},Vi.prototype.getLayerConfig.call(this))},tn.prototype.getSourceConfig=function(){return{id:Qi,type:Qi,tileUrl:AMap.getConfig().protocol+(_.Support.wasm?"://{vdata,vdata01,vdata02,vdata03,vdata04}.amap.com/nebula/v3":"://{vdata,vdata01,vdata02,vdata03,vdata04}.amap.com/nebula/v2"),tileSize:0,zooms:_.zoomRange}},tn.prototype.co=function(){return Qi},tn.prototype.sl=function(){this.source.reload(),this.Jh&&this.Jh.reset()},tn.prototype.vi=function(t,i){return void 0===i&&(i=!1),this.fz?this.fz.vi(t,this.hS,i):null},tn.prototype.Do=function(t){return t=Vi.prototype.Do.call(this,t),this.map&&this.uz(this.map),t},tn.prototype.aP=function(){var t,i=this.map;return!!i&&(t=i&&i.getLayerByClass("AMap.TileLayer.RoadNet"),i=i&&i.getLayerByClass("AMap.NebulaLayer"),t=t&&t.getVisible(),i=i&&i.getVisible(),!t)&&!i},tn.prototype.oP=function(){var t,i,n=this.map;return!!n&&(t=n&&n.getLayerByClass("AMap.TileLayer.RoadNet"),i=n&&n.getLayerByClass("AMap.NebulaLayer"),t=t&&t.getVisible(),i=i&&i.getVisible(),n.showLabel)&&(t||i)},tn.prototype.destroy=function(){this.Jh&&this.Jh.destroy&&(this.Jh.destroy(),delete this.Jh),this.source&&this.source.destroy&&(this.source.destroy(),delete this.source)},tn.prototype.uz=function(t){(this.fz=t.fS()).add(this)},tn);function tn(t){var i=Vi.call(this,t=void 0===t?{}:t)||this;return i.CLASS_NAME="AMap.Inner.LabelsLayer",i._opts={id:qi,type:qi,opacity:1,visible:1,collision:!0,allowCollision:!1},i._opts=_.assign({},i._opts,t),i.Qh=t.labelzIndex||100,i.il=!1!==t.showLabel,i.tl=void 0===t.opacity?1:t.opacity,i}nn=s,_.Ei(sn,nn),sn.prototype.getState=function(){return{ol:!0,al:!0,visible:this.il,opacity:this.tl,layer:this,zooms:this.xt,zIndex:this.Qh,rejectMapMask:this._rejectMapMask,depthTest:this.AF,ce:this.IF,HY:this.rX()}},sn.prototype.getLayerConfig=function(){var t=nn.prototype.getLayerConfig.call(this);return t.mapNumber="",t},sn.prototype.getSourceConfig=function(){return{id:"vectortraffic",type:"vectortraffic",tileUrl:"",tileSize:256,zooms:this.xt}},sn.prototype.co=function(){return"vectortraffic"},sn.prototype.destroy=function(){this.Jh&&this.Jh.destroy&&(this.Jh.destroy(),delete this.Jh)},sn.prototype.onAdd=function(){var t=this;this.map.on("styleChanged",this.reload,this),this.dl&&(this.iT=setInterval(function(){t.reload()},1e3*this.vl))},sn.prototype.v$=function(){this.map.off("styleChanged",this.reload,this),clearInterval(this.iT),delete this.iT},sn.prototype.reload=function(){var t=this.getSource();t&&this.map&&(t.reload(),this.map.setNeedUpdate(!0))},sn.prototype.rX=function(){var t,i=["fff93a43","fffcac19","ff20a962","ff83171c","ffadadad"];this.map&&(t=this.map.mapStyle.vn.MS("traffic"))&&t.multiFillColors&&((t=t.multiFillColors).congested&&(i[0]=t.congested),t.slow&&(i[1]=t.slow),t.smooth&&(i[2]=t.smooth),t.seriousCongested&&(i[3]=t.seriousCongested),t.unknown)&&(i[4]=t.unknown);for(var n=0,s=i.length;n<s;n++)i[n]=_.Util.qg(i[n]);return i};var nn;function sn(){var t=null!==nn&&nn.apply(this,arguments)||this;return t.vl=60,t.dl=!0,t}var en,rn={opacity:1,visible:!0,zIndex:4,zooms:[7,_.zoomRange[1]],dataZooms:[7,17],interval:60,ml:!0,depthTest:!1,rZ:1},Oi=(en=sn,_.Ei(hn,en),hn);function hn(t){var i=this;return(t=void 0===t?rn:t).id=_.Util.uuid(),t.opacity=(void 0===t.opacity?rn:t).opacity,t.visible=(void 0===t.visible?rn:t).visible,t.zIndex=(void 0===t.zIndex?rn:t).zIndex,t.zooms=(void 0===t.zooms?rn:t).zooms,t.interval=(void 0===t.interval?rn:t).interval,t.ml=(void 0===t.ml?rn:t).ml,t.depthTest=(void 0===t.depthTest?rn:t).depthTest,t.rZ=(void 0===t.rZ?rn:t).rZ,(i=en.call(this,t)||this).vl=Math.max(30,t.interval||i.vl),i.dl=void 0!==t.ml&&i.dl,i.CLASS_NAME="AMap.TileLayer.Traffic",i.onCreated(),i}on=s,_.Ei(an,on),an.prototype.getSourceConfig=function(){return{id:this._id||"tile",tileUrl:this._tileUrl||"",type:"raster",tileSize:this.Xa||256,zooms:this.xt,dataZooms:this.Qs||[7,17],projection:this.hl||"EPS3857"}},an.prototype.co=function(){return this._id},an.prototype.getState=function(){return{visible:this.il,opacity:this.tl,rejectMapMask:this._rejectMapMask,depthTest:this.AF,ce:this.IF,detectRetina:this.yl}},an.prototype.Hh=function(t){this.uo=t,this.uo.getSource(this.co()).setTileCacheSize(this.wl)};var on,ui=an;function an(t){var i=on.call(this,t)||this;return i.CLASS_NAME="AMap.RasterLayer",i._tileUrl=t.tileUrl,i.xt=t.zooms||_.zoomRange,i.Qs=t.dataZooms,i.tl=void 0===t.opacity?1:t.opacity,i.Qh=t.zIndex||1,i.il=void 0===t.visible||t.visible,i.Xa=t.tileSize||256,i.hl=t.projection,i.AF=void 0!==t.depthTest&&Boolean(t.depthTest),i.yl=void 0===t.detectRetina||Boolean(t.detectRetina),i.wl=t.cacheSize,i}var un,cn={id:"tile_"+_.Util.uuid(),tileUrl:void 0,zooms:_.zoomRange,dataZooms:[2,18],opacity:1,tileSize:256,visible:!0,projection:"EPSG:3857",zIndex:2},fn={id:"satellite"+_.Util.uuid(),tileUrl:"http://webst0{1,2,3,4}.is.autonavi.com/appmaptile?style=6&x=[x]&y=[y]&z=[z]",zooms:_.zoomRange,dataZooms:[3,18],opacity:1,tileSize:256,visible:!0,projection:"EPSG:3857",zIndex:2},ln={id:"traffic"+_.Util.uuid(),tileUrl:"http://tm.amap.com/trafficengine/mapabc/traffictile?v=1.0&t=1&zoom=[z]&x=[x]&y=[y]",zooms:[7,_.zoomRange[1]],dataZooms:[7,17],opacity:1,tileSize:256,visible:!0,projection:"EPSG:3857",zIndex:4,getTileUrl:function(t,i,n){return AMap.getConfig().protocol+"://tm.amap.com/trafficengine/mapabc/traffictile?v=1.0\n&t=1&zoom="+(17-n)+"&x="+t+"&y="+i}},dn={id:"roadnet"+_.Util.uuid(),tileUrl:"http://wprd0{1,2,3,4}.is.autonavi.com/appmaptile?x=[x]&y=[y]&z=[z]&lang=zh_cn&size=1&scl=1&style=8<ype=11",zooms:_.zoomRange,dataZooms:[3,18],opacity:1,tileSize:256,visible:!0,projection:"EPSG:3857",zIndex:3},vn={id:"flexible"+_.Util.uuid(),zooms:_.zoomRange,dataZooms:_.zoomRange,opacity:1,tileSize:256,visible:!0,projection:"EPSG:3857",zIndex:3},pn={id:"wms"+_.Util.uuid(),url:"",zooms:_.zoomRange,dataZooms:_.zoomRange,opacity:1,tileSize:512,visible:!0,projection:"EPSG:3857",zIndex:3},v=(un=ui,_.Ei(mn,un),mn.prototype.setTileUrl=function(t){t=0===(t=t.replace(/^\/\//,"").replace("http://","")).indexOf("http")?t:AMap.getConfig().protocol+"://"+t,this._tileUrl=t,this.reload()},mn.prototype.getTileUrl=function(){return this._tileUrl},mn.prototype.getLayerConfig=function(){var t="";return this._tileUrl!==AMap.getConfig().qT&&this._tileUrl!==AMap.getConfig().YT||(t="GS(2021)6375"),{id:this._id,tileUrl:this._tileUrl,zooms:this.xt,zIndex:this.Qh,opacity:this.tl,visible:this.il,getTileUrl:this.ll,mapNumber:t}},mn.prototype.reload=function(){var t=this.getSource();t&&(t.setTileUrl(this._tileUrl),t.reload(),t.Fo(!1),this.map)&&this.map.setNeedUpdate(!0)},_.dZ([_.pZ("TileLayer")],mn));function mn(t){var i=this,n={};return(t=void 0===t?cn:t).getTileUrl&&"string"==typeof t.getTileUrl&&(t.tileUrl=t.getTileUrl,delete t.getTileUrl),n.tileUrl=void 0===t.tileUrl?AMap.getConfig().y_:t.tileUrl,n.tileUrl&&(n.tileUrl=n.tileUrl.replace(/^\/\//,"").replace("http://","")),t&&t.name&&"AMap.TileLayer.Mark"===t.name||(n.tileUrl=n.tileUrl&&0===n.tileUrl.indexOf("http")?n.tileUrl:AMap.getConfig().protocol+"://"+n.tileUrl),n.id=t.id||"tile_"+_.Util.uuid(),n.tileSize=t.tileSize||cn.tileSize,"d"===_.Support.baseRender&&_.Support.$e&&(cn.dataZooms=[2,20]),n.dataZooms=t.dataZooms||cn.dataZooms,n.zooms=t.zooms||cn.zooms,n.projection=t.projection||cn.projection,n.opacity=(void 0===t.opacity?cn:t).opacity,n.visible=(void 0===t.visible?cn:t).visible,n.zIndex=(void 0===t.zIndex?cn:t).zIndex,n.rejectMapMask=t.rejectMapMask,n.depthTest=void 0!==t.depthTest&&Boolean(t.depthTest),n.map=t.map,n.detectRetina=void 0!==t.detectRetina&&t.detectRetina,n.cacheSize=t.cacheSize,(i=un.call(this,n)||this).type=t.type||"base",i.ll=t.getTileUrl,i.CLASS_NAME="AMap.TileLayer",i.onCreated(),i}yn=v,_.Ei(bn,yn),bn.prototype.getLayerConfig=function(){var t=yn.prototype.getLayerConfig.call(this);return t.mapNumber="GS京(2022)1061",t.OY=!0,t};var yn,li=bn;function bn(t){var i=this;return(t=void 0===t?fn:t).id="satellite_"+_.Util.uuid(),t.tileUrl=fn.tileUrl,t.zooms=(void 0===t.zooms?fn:t).zooms,t.opacity=(void 0===t.opacity?fn:t).opacity,t.visible=(void 0===t.visible?fn:t).visible,t.zIndex=(void 0===t.zIndex?fn:t).zIndex,(i=yn.call(this,t)||this).CLASS_NAME="AMap.TileLayer.Satellite",i.type=t.type||"base",i.onCreated(),i}gn=v,_.Ei(Mn,gn),Mn.prototype.ul=function(){clearInterval(this.cl)},Mn.prototype.pl=function(){var t=this;this.dl&&0<this.vl&&(this.cl=setInterval(function(){t.reload()},1e3*this.vl))};var gn,Ti=Mn;function Mn(t){var i=this;return(t=void 0===t?ln:t).id="traffic_"+_.Util.uuid(),t.tileUrl=ln.tileUrl,t.zooms=(void 0===t.zooms?ln:t).zooms,t.opacity=(void 0===t.opacity?ln:t).opacity,t.visible=(void 0===t.visible?ln:t).visible,t.zIndex=(void 0===t.zIndex?ln:t).zIndex,t.getTileUrl=t.getTileUrl||ln.getTileUrl,(i=gn.call(this,t)||this).vl=Math.max(30,t.interval||60),i.dl=void 0===t.ml||t.ml,i.CLASS_NAME="AMap.TileLayer.Traffic",i.type=t.type||"overlay",i.onCreated(),i.pl(),i}kn=v,_.Ei(wn,kn),wn.prototype.show=function(){kn.prototype.show.call(this);var t=this.map&&this.map.getLayerByClass("AMap.Inner.LabelsLayer");t&&t.oP()&&t.show()},wn.prototype.hide=function(){kn.prototype.hide.call(this);var t=this.map&&this.map.getLayerByClass("AMap.Inner.LabelsLayer");t&&t.aP()&&t.hide()},wn.prototype.v$=function(){kn.prototype.v$.call(this);var t=this.map&&this.map.getLayerByClass("AMap.Inner.LabelsLayer");t&&t.aP()&&t.hide()};var kn,Bt=wn;function wn(t){var i,n=this;return(t=void 0===t?dn:t).id="roadNet_"+_.Util.uuid(),t.tileUrl=dn.tileUrl,"d"===_.Support.baseRender&&(t.tileUrl=null==(i=t.tileUrl)?void 0:i.replace("<ype=11","")),t.zooms=(void 0===t.zooms?dn:t).zooms,t.opacity=(void 0===t.opacity?dn:t).opacity,t.visible=(void 0===t.visible?dn:t).visible,t.zIndex=(void 0===t.zIndex?dn:t).zIndex,(n=kn.call(this,t)||this).CLASS_NAME="AMap.TileLayer.RoadNet",n.type=t.type||"overlay",n.onCreated(),n}xn=v,_.Ei(An,xn),An.prototype.getLayerConfig=function(){return{id:this._id,zooms:this.xt,zIndex:this.Qh,opacity:this.tl,visible:this.il,createTile:this.bl,cacheSize:this.wl,getTileUrl:this.ll,rejectMapMask:this._rejectMapMask}},An.prototype.Hh=function(t){this.uo=t,this.uo.getSource(this.co()).setTileCacheSize(this.wl)};var xn,Xt=An;function An(t){var i=this;return(t=void 0===t?vn:t).id=vn.id,t.id="flexible_"+_.Util.uuid(),t.zooms=(void 0===t.zooms?vn:t).zooms,t.opacity=(void 0===t.opacity?vn:t).opacity,t.visible=(void 0===t.visible?vn:t).visible,t.zIndex=(void 0===t.zIndex?vn:t).zIndex,(i=xn.call(this,t)||this).bl=t.createTile,i.CLASS_NAME="AMap.TileLayer.Flexible",i.type=t.type||"base",i.onCreated(),i}zn=v,_.Ei(Cn,zn),Cn.prototype._l=function(){this.kl.TileMatrixSet=this.kl.TileMatrixSet||"EPSG:3857",this.kl.Request="GetTile",this.kl.Service="WMTS",this.kl.Format=this.kl.Format||"image/png",this._tileUrl=this.Ml+"?"+_.Util.join(this.kl,"&"),this.map&&this.map.setNeedUpdate(!0)},Cn.prototype.setParams=function(t){this.kl=_.assign({},t),this._l()},Cn.prototype.getParams=function(){return this.kl},Cn.prototype.getUrl=function(){return this.Ml},Cn.prototype.setUrl=function(t){this.Ml=t,this._l()},Cn.prototype.getLayerConfig=function(){return{id:this._id,zooms:this.xt,zIndex:this.Qh,opacity:this.tl,visible:this.il,Ll:this.kl,createTile:this.bl,getTileUrl:this.ll}};var zn,hi=Cn;function Cn(t){var o=this;return(t=void 0===t?vn:t).id="wmts_"+_.Util.uuid(),t.cacheSize=vn.cacheSize,t.zooms=(void 0===t.zooms?vn:t).zooms,t.opacity=(void 0===t.opacity?vn:t).opacity,t.visible=(void 0===t.visible?vn:t).visible,t.zIndex=(void 0===t.zIndex?vn:t).zIndex,(o=zn.call(this,t)||this).kl=t.params||{},o.CLASS_NAME="AMap.TileLayer.WMTS",o.type=t.type||"base",o._tileUrl=t.url,o.Ml=t.url,o.bl=function(t,i,n,s,e){var r,h=document.createElement("img");"w"===(null==(r=o.map)?void 0:r.baseRender)&&(h.crossOrigin="anonymous"),h.onload=function(){s(h)},h.onerror=function(){e(h)},h.src=o._tileUrl+"&TileMatrix="+n+"&TileRow="+i+"&TileCol="+t},o._l(),o.onCreated(),o}Sn=v,_.Ei(Tn,Sn),Tn.prototype._l=function(){this.kl.WIDTH=this.Xa,this.kl.HEIGHT=this.Xa,this.kl.CRS=this.kl.CRS||"EPSG:3857",this.kl.REQUEST="GetMap",this.kl.SERVICE="WMS",this.kl.FORMAT=this.kl.FORMAT||"image/png",this.kl.TRANSPARENT=void 0===this.kl.TRANSPARENT?"true":this.kl.TRANSPARENT,delete this.kl.BBOX,this._tileUrl=this.Ml+"?"+_.Util.join(this.kl,"&")},Tn.prototype.setParams=function(t){this.kl=_.assign({},t),this._l()},Tn.prototype.getParams=function(){return this.kl},Tn.prototype.getUrl=function(){return this.Ml},Tn.prototype.setUrl=function(t){this.Ml=t,this._l()},Tn.prototype.getLayerConfig=function(){return{id:this._id,zooms:this.xt,zIndex:this.Qh,opacity:this.tl,visible:this.il,Ll:this.kl,createTile:this.bl,getTileUrl:this.ll}};var Sn,Ut=Tn;function Tn(t){var o=this;return(t=void 0===t?pn:t).id="wms_"+_.Util.uuid(),t.cacheSize=vn.cacheSize,t.zooms=(void 0===t.zooms?vn:t).zooms,t.opacity=(void 0===t.opacity?vn:t).opacity,t.visible=(void 0===t.visible?vn:t).visible,t.zIndex=(void 0===t.zIndex?vn:t).zIndex,(o=Sn.call(this,t)||this)._tileUrl=t.url,o.Ml=t.url,o.kl=t.params||{},o.CLASS_NAME="AMap.TileLayer.WMS",o.type=t.type||"base",o.bl=function(t,i,n,s,e){var r=[(n=2*_.x_/256/Math.pow(2,n)*o.Xa)*t-_.x_,_.x_-n*(i+1)],t=[n*(t+1)-_.x_,_.x_-n*i],h=document.createElement("img");"w"===(null==(n=o.map)?void 0:n.baseRender)&&(h.crossOrigin="anonymous"),h.onload=function(){s(h)},h.onerror=function(){e(h)},o._l(),h.src=o._tileUrl+"&BBOX="+r+","+t},o.bl=o.bl.bind(o),o.onCreated(),o}Ln=v,_.Ei(In,Ln),In.prototype.getLayerConfig=function(){return Ln.prototype.getLayerConfig.call(this)},In.prototype.getTileUrl=function(){return _.Util.getMarkUrl()};var Ln,Vt=In;function In(t){var i=this;return t.id="mark_"+_.Util.uuid(),t.tileUrl=_.Util.getMarkUrl(),t.zooms=[2,30],t.opacity=1,t.visible=!0,t.zIndex=999999,t.name="AMap.TileLayer.Mark",(i=Ln.call(this,t)||this).CLASS_NAME="AMap.TileLayer.Mark",i.type=t.type||"base",i.onCreated(),i}function Dn(){this.Wl=!0,this._position=_.Dl(),_.Pl(this._position,0,0,10),this.Gl=_.Dl(),_.Pl(this.Gl,0,0,-1),this.jl=_.Dl(),_.Pl(this.jl,0,0,-1),this.El=_.Dl(),_.Pl(this.El,0,1,0),this.Nl=_.Zl(),this.Fl=_.Il(),this.Bl=_.Il(),this.ql=_.Il(),this.Yl=_.Il()}v.RoadNet=Bt,v.Satellite=li,v.Traffic="d"===_.Support.baseRender?Ti:Oi,v.Flexible=Xt,v.WMTS=hi,v.WMS=Ut,v.Mark=Vt,Dn.prototype.lookAt=function(t){var i,n,s,e,r,h,o,a,u,c=_.Il(),f=_.Dl();_.Pl(this.jl,t[0],t[0],t[2]),f=_.Ol(f,this.Fl),c=_.lookAt(c,f,t,this.El),f=this.Nl,c=(t=c)[0],n=t[4],s=t[8],e=t[1],r=t[5],h=t[9],o=t[2],a=t[6],0<(u=c+r+(t=t[10]))?(i=.5/Math.sqrt(u+1),f[3]=.25/i,f[0]=(a-h)*i,f[1]=(s-o)*i,f[2]=(e-n)*i):r<c&&t<c?(i=2*Math.sqrt(1+c-r-t),f[3]=(a-h)/i,f[0]=.25*i,f[1]=(n+e)/i,f[2]=(s+o)/i):t<r?(i=2*Math.sqrt(1+r-c-t),f[3]=(s-o)/i,f[0]=(n+e)/i,f[1]=.25*i,f[2]=(h+a)/i):(i=2*Math.sqrt(1+t-c-r),f[3]=(e-n)/i,f[0]=(s+o)/i,f[1]=(h+a)/i,f[2]=.25*i),this.$l()},Dn.prototype.setPosition=function(t){_.Pl(this._position,t[0],t[1],t[2]),this.$l()},Dn.prototype.getPosition=function(){return this._position},Dn.prototype.$l=function(){var h,u,c,f,t=this.Fl,i=this._position,n=this.Nl,s=n[0],e=n[1],r=n[2],o=s*(c=s+s),a=s*(f=e+e);s*=h=r+r,u=e*f,e*=h,c*=n=n[3],f*=n,n*=h,t[0]=1-(u+(r*=h)),t[1]=a+n,t[2]=s-f,t[3]=0,t[4]=a-n,t[5]=1-(o+r),t[6]=e+c,t[7]=0,t[8]=s+f,t[9]=e-c,t[10]=1-(o+u),t[11]=0,t[12]=i[0],t[13]=i[1],t[14]=i[2],t[15]=1,_.Ul(this.Bl,this.Fl)},On=Gt=Dn,_.Ei(En,On),En.prototype.Vl=function(){var t=_.Il();return _.multiply(t,this.ql,this.Xl),_.multiply(t,t,this.Bl),t},En.prototype.setOptions=function(t,i,n,s,e,r){this.Hl=void 0!==t?t:-1,this.Jl=void 0!==i?i:1,this.Kl=void 0!==n?n:1,this.Ql=void 0!==s?s:-1,this.tu=void 0!==e?e:.1,this.iu=void 0!==r?r:1,this.eu()},En.prototype.scale=function(t){void 0===t&&(t=1);var i=_.Il();i.set([t,0,0,0,0,t,0,0,0,0,1,0,0,0,0,1]),_.multiply(this.Xl,this.Xl,i)},En.prototype.setRotation=function(t){var i=_.Il(),n=(t-this.nu)/180*Math.PI;0!==(this.nu=t)&&(i.set([Math.cos(n),-Math.sin(n),0,0,Math.sin(n),Math.cos(n),0,0,0,0,1,0,0,0,0,1]),_.multiply(this.Xl,this.Xl,i))},En.prototype.kt=function(t,i,n){var s,e,r,h,o,a;void 0!==t&&(s=t.Rt,e=t.zt,r=t.center,t=t.scale,h=_.Il(),a=_.Il(),o=_.Il(),h.set([1,0,0,0,0,1,0,0,0,0,1,0,e[0],e[1],0,1]),a.set([t,0,0,0,0,t,0,0,0,0,1,0,0,0,0,1]),o.set([1,0,0,0,0,1,0,0,0,0,1,0,-s[0],-s[1],0,1]),_.multiply(h,h,a),_.multiply(h,h,o),_.multiply(this.Xl,this.Xl,h),a=[(t=_.ProjectionManager.getProjection(i).project(r[0],r[1]))[0]-e[0]+s[0],t[1]-e[1]+s[1]],n(_.ProjectionManager.getProjection(i).unproject(a[0],a[1])))},En.prototype.Cu=function(){return this.Yl},En.prototype.lB=function(){return{left:this.Hl,right:this.Jl,top:this.Kl,bottom:this.Ql,rotation:this.nu,far:this.iu,near:this.tu,position:this._position}},En.prototype.eu=function(){var t=(this.Jl-this.Hl)/(2*this.bt),i=(this.Kl-this.Ql)/(2*this.bt),n=(this.Jl+this.Hl)/2,s=(this.Kl+this.Ql)/2;_.ou(this.ql,n-t,n+t,s-i,s+i,this.tu,this.iu),_.Ul(this.Yl,this.ql)};var On,Rn=En;function En(t,i,n,s,e,r){var h=On.call(this)||this;return h.type="OthoCamera",h.bt=1,h.nu=0,h.Xl=_.Il(),h.Hl=void 0!==t?t:-1,h.Jl=void 0!==i?i:1,h.Kl=void 0!==n?n:1,h.Ql=void 0!==s?s:-1,h.tu=void 0!==e?e:.1,h.iu=void 0!==r?r:1,h.eu(),h}Pn=_.Event,_.Ei(p,Pn),p.prototype.au=function(){return this.su},p.prototype.ru=function(){return _.ProjectionManager.getProjection(this.su)},p.prototype.setOptions=function(t,i){void 0===i&&(i=!0),t.projectionId&&(this.su=t.projectionId);var n=_.ProjectionManager.getProjection(this.su);if(t.center&&(this.hu=t.center,s=this.lu(n),e=n.unproject(s[0],s[1]),this.hu=e,_.Pl(this.uu,s[0],s[1],0),this.cu.setPosition(this.fu())),void 0!==t.zoom&&(t.zoom=Math.min(Math.max(t.zoom,this.map.getZooms()[0]),this.map.getZooms()[1]),this.pu=Math.pow(2,t.zoom-this.bt),this.bt=t.zoom,this.du=n.getResolution(this.bt),this.vu(),this.cu.setPosition(this.fu())),t.size&&(this.map.emit("resize"),this._size=t.size,this.vu()),void 0!==t.rotation&&"w"===_.Support.baseRender&&(360<t.rotation?t.rotation-=360:t.rotation<-360&&(t.rotation+=360),this.cu.setRotation(t.rotation),this.nu=t.rotation),t.kt){if(!this.map.getStatus().zoomEnable)return;var s,e,r=t.kt.Mt;this.mu=t.kt,r<=this.map.getZooms()[1]&&r>=this.map.getZooms()[0]&&(this.bt=r,this.du=n.getResolution(this.bt),r=(t=this.mu).Rt,t=t.zt,(s=this.lu(n))[0]=s[0]-t[0]+r[0],s[1]=s[1]-t[1]+r[1],e=n.unproject(s[0],s[1]),this.hu=e,_.Pl(this.uu,s[0],s[1],0),this.vu(),this.cu.setPosition(this.fu()),this.mu=void 0)}!this.h_()&&i&&this.map.setNeedUpdate(!0)},p.prototype.getOptions=function(){return{zoom:this.bt,center:this.hu,rotation:this.nu,projectionId:this.su,pitch:0}},p.prototype.getStatus=function(){var t=_.Zl(),i=_.Zl(),n=_.Zl(),s=(this.xu(t,i,n),_.Util.getOptimalZoom(this.bt));return{pitch:this.Pu,size:this._size,rotation:this.nu,zoom:this.bt,optimalZoom:s,resolution:this.du,optimalResolution:_.ProjectionManager.getProjection(this.su).getResolution(s),center:this.hu,bounds:t,boundsCoord:i,transformedBoundsCoord:n,centerCoord:this.uu,projectionId:this.su,mvpMatrix:this.cu.Vl(),viewMode:this.type,skyHeight:this.EF(),fov:60}},p.prototype.bu=function(t){this.hu=[t[0],t[1]],t=_.ProjectionManager.getProjection(this.su).project(this.hu[0],this.hu[1]),_.Pl(this.uu,t[0],t[1],0)},p.prototype.containerTolnglat=function(t,i,n){var s,r=(e=this.getStatus()).centerCoord,e=e.rotation,r=_.V[this.su].transform(r[0],r[1],n),h=(r=0!==e?(n=e/180*Math.PI,e=t-this._size[0]/2,s=-(i-this._size[1]/2),h=Math.sqrt(e*e+s*s),e=Math.atan(e/s)-n,s<0&&(e+=Math.PI),n=h*Math.sin(e),s=h*Math.cos(e),[r[0]+n*this.du,r[1]-s*this.du]):[r[0]+(t-this._size[0]/2)*this.du,r[1]+(i-this._size[1]/2)*this.du],r=_.V[this.su].Xs(r[0],r[1]),_.ProjectionManager.getProjection(this.su).unproject(r[0],r[1]));return h[0]=180<h[0]?h[0]-360:h[0]<-180?h[0]+360:h[0],h},p.prototype.lnglatToContainer=function(t,i,n,s){s=s||this.bt;var r=(e=this.getStatus()).rotation,e=e.centerCoord,i=[(t=_.ProjectionManager.getProjection(this.su).project(t,i))[0],t[1]],t={center:e,rotation:r,size:this._size};return _.V[this.su].wu(i[0],i[1],s,t)},p.prototype._u=function(t,i){(n=this.getStatus()).optimalZoom;var s=n.zoom,e=n.rotation,n={center:n.centerCoord,rotation:e,size:this._size};return _.V[this.su].wu(t,i,s,n)},p.prototype.ku=function(t,i){(n=this.getStatus()).optimalZoom,n.centerCoord,n.zoom,n.rotation;var n=this.containerTolnglat(t,i);return(t=_.ProjectionManager.getProjection(this.su)).project.apply(t,n)},p.prototype.h_=function(){return _.Ru(this.Xl,this.cu.Vl())},p.prototype.aD=function(){return this.Xl=this.cu.Vl(),this.Xl},p.prototype.EF=function(){return 1},p.prototype.pz=function(){return this.cu},p.prototype.xu=function(t,i,n){var s=this.nu/180*Math.PI,e=this._size,e=[(Math.abs(e[0]*Math.cos(s))+Math.abs(e[1]*Math.sin(s)))/2*this.du,(Math.abs(e[0]*Math.sin(s))+Math.abs(e[1]*Math.cos(s)))/2*this.du],s=_.ProjectionManager.getProjection(this.su),r=this.uu[0]-e[0],h=this.uu[0]+e[0],o=this.uu[1]-e[1],e=this.uu[1]+e[1],a=s.unproject(r,o),s=s.unproject(h,e),r=(i[0]=r,i[1]=o,i[2]=h,i[3]=e,t[0]=a[0],t[1]=a[1],t[2]=s[0],t[3]=s[1],_.V[this.su].transform(i[0],i[3])),o=_.V[this.su].transform(i[2],i[1]);return n[0]=r[0],n[1]=r[1],n[2]=o[0],n[3]=o[1],t},p.prototype.vu=function(){var i=(t=this._size)[0]*this.du,t=t[1]*this.du;this.cu.setOptions(-i/2,i/2,t/2,-t/2,1,11e5)},p.prototype.fu=function(){var t,i=_.Dl();return _.Util.getOptimalZoom(this.bt)<_.Ra?_.Pl(i,this.uu[0],this.uu[1],this.cz):(t=_.lcs.getDeltaCoord([this.uu[0],this.uu[1]]),_.Pl(i,t[0],t[1],this.cz)),i},p.prototype.lu=function(t){return this.hu[0]=180<this.hu[0]?this.hu[0]-360:this.hu[0]<-180?this.hu[0]+360:this.hu[0],t.project(this.hu[0],this.hu[1])};var Pn,jn=p;function p(t,i){var n=Pn.call(this)||this;return n.type="2D",n.Pu=0,n.hu=[0,0],n.bt=12,n._size=[0,0],n.pu=1,n.nu=0,n.cu=new Rn(-1,1,1,-1,10,1e3),n.su="EPSG:3857",n.uu=_.Dl(),n.cz=1e6,n.du=_.ProjectionManager.getProjection(n.su).getResolution(12),n.Xl=_.Il(),n.bt=void 0!==t.zoom?t.zoom:12,n.map=i,n.setOptions(t),n.vu(),n.Xl=n.cu.Vl(),n}Bn=Gt,_.Ei(m,Bn),m.prototype.Vl=function(){var t=[];return _.multiply(t,this.ql,this.zu),t},m.prototype.Su=function(){return this.ql},m.prototype.Cu=function(){return this.Yl},m.prototype.Lu=function(){return this.zu},m.prototype.Au=function(){return this.cu},m.prototype.setOptions=function(t,i,n,s,e){void 0===t&&(t=[1,1]),void 0===n&&(n=1),void 0===s&&(s=1),void 0===e&&(e=10),this.Tu=this.Iu(i=void 0===i?60:i),this.tu=s,this.iu=e,this.Du=n,this._size=t,this.eu()},m.prototype.setSize=function(t){this._size=t},m.prototype.setPitch=function(t){this.Pu=void 0!==t?t:this.Pu;var t=this._size[1]/2/Math.tan(this.Tu/2),i=this.Iu(this.Pu),n=this.Iu(this.nu),s=t*Math.sin(i),e=this.jl[0]-s*Math.sin(n),s=this.jl[1]-s*Math.cos(n),n=t*Math.cos(i);_.Pl(this._position,e,s,n),this.ju()},m.prototype.setRotation=function(t){this.nu=void 0!==t?-t:this.nu;var t=this.Iu(this.nu),i=Math.sin(t),t=Math.cos(t);_.Pl(this.El,i,t,0),this.Ou()},m.prototype.Fu=function(t,i,n){_.Pl(this.jl,t,i,n),this.ju()},m.prototype.Ou=function(t,i,n){void 0!==t&&void 0!==i?(_.Pl(this._position,t,i,void 0===n?this._position[2]:n),this.ju()):(t=this._size[1]/2/Math.tan(this.Tu/2),_.Pl(this._position,this.jl[0],this.jl[1],t),this.setPitch())},m.prototype.Eu=function(t){var i=this._size;this.cz=t||i[1]/2/Math.tan(this.Tu/2)||0,_.Pl(this._position,this._position[0],this._position[1],this.cz),this.setPitch()},m.prototype.Nu=function(t,i,n){_.Pl(this.El,t=void 0===t?0:t,i=void 0===i?1:i,n=void 0===n?0:n),this.ju()},m.prototype.dz=function(){return this.cz},m.prototype.lB=function(){return{fov:this.Tu,target:this.jl,up:this.El,position:this._position,far:this.iu,near:this.tu}},m.prototype.eu=function(){_.perspective(this.ql,this.Tu,this.Du,this.tu,this.iu),_.Ul(this.Yl,this.ql)},m.prototype.ju=function(){_.lookAt(this.zu,this._position,this.jl,this.El),_.Ul(this.cu,this.zu)},m.prototype.Iu=function(t){return t*Math.PI/180};var Bn,Wn=m;function m(t,i,n,s,e){void 0===t&&(t=[1,1]),void 0===i&&(i=60),void 0===n&&(n=1),void 0===s&&(s=10),void 0===e&&(e=2e4);var r=Bn.call(this)||this;return r.Wt="PerspectiveCamera",r.Pu=0,r.nu=0,r.cu=_.Il(),r.zu=_.Il(),r.cz=0,r.Tu=r.Iu(i),r.tu=s,r.iu=e,r.Du=n,_.Pl(r.El,0,1,0),r._size=t,r.eu(),r}Fn=_.Event,_.Ei(y,Fn),y.prototype.setOptions=function(t){var i=_.ProjectionManager.getProjection(this.su);if(t.projectionId&&(this.su=t.projectionId),t.size&&(this.map.emit("resize"),this._size=t.size,this.vu(),this.cu.Ou()),void 0!==t.rotation&&"w"===_.Support.baseRender&&(this.cu.setRotation(t.rotation),this.nu=t.rotation),void 0!==t.zoom&&(t.zoom=Math.min(Math.max(t.zoom,this.map.getZooms()[0]),this.map.getZooms()[1]),n=this.bt,this.bt=t.zoom,this.du=i.getResolution(this.bt),e=this.fu(),(_.Util.getOptimalZoom(t.zoom)<_.Ra&&_.Util.getOptimalZoom(n)>=_.Ra||_.Util.getOptimalZoom(t.zoom)>=_.Ra&&_.Util.getOptimalZoom(n)<_.Ra)&&(s=this.fu(),this.cu.Fu(s[0],s[1],0),this.cu.Ou(),this.vu()),this.cu.Fu(e[0],e[1],0),this.cu.Ou(),this.vu()),void 0!==t.pitch&&"w"===_.Support.baseRender&&(t.pitch>this.$u()||this.Pu>this.$u()?t.pitch=this.$u():(t.pitch<0||this.Pu<0)&&(t.pitch=0),this.Pu=Math.min(t.pitch,this.$u()),this.cu.setPitch(t.pitch)),t.center&&(this.hu=t.center,r=this.lu(i),_.Pl(this.uu,r[0],r[1],0),e=this.fu(),s=i.unproject(r[0],r[1]),this.hu=s,this.cu.Fu(e[0],e[1],0),this.cu.Ou()),t.kt){if(!this.map.getStatus().zoomEnable)return;var n=this.bt,n=(this.bt=Math.min(Math.max(t.kt.Mt,this.map.getZooms()[0]),this.map.getZooms()[1]),this.du=i.getResolution(this.bt),(_.Util.getOptimalZoom(t.kt.Mt)<_.Ra&&_.Util.getOptimalZoom(n)>=_.Ra||_.Util.getOptimalZoom(t.kt.Mt)>=_.Ra&&_.Util.getOptimalZoom(n)<_.Ra)&&(s=this.fu(),this.cu.Fu(s[0],s[1],0),this.cu.Ou()),this.lu(i)),s=t.kt.pos,i=this.X(s[0],s[1]),t=_.lcs.getLocalByCoord([n[0],n[1]]),e=(this.vu(),this.fu());this.cu.Fu(e[0],e[1],0),this.cu.Ou();var s=[(s=this.X(s[0],s[1]))[0]-i[0],s[1]-i[1]],i=[e[0]-s[0],e[1]-s[1]],r=[n[0]-s[0],n[1]-s[1]],e=_.lcs.getLocalByCoord(r);this.bt>=_.Ra&&(e.x!==t.x||t.y!==e.y)&&(n=e.x-t.x,s=e.y-t.y,i[0]-=n*_.lcs.getSize()[0],i[1]-=s*_.lcs.getSize()[1]),this.cu.Fu(i[0],i[1],0),this.cu.Ou(),this.bu(r)}this.h_()||this.map.setNeedUpdate(!0)},y.prototype.bu=function(t){var i=_.ProjectionManager.getProjection(this.su),i=(_.Pl(this.uu,t[0],t[1],0),i.unproject(t[0],t[1]));this.hu=i},y.prototype.getOptions=function(){return{size:this._size,zoom:this.bt,center:this.hu,rotation:this.nu,projectionId:this.su,pitch:this.Pu,resolution:this.du}},y.prototype.au=function(){return this.su},y.prototype.ru=function(){return _.ProjectionManager.getProjection(this.su)},y.prototype.getStatus=function(){var t=_.Zl(),i=_.Zl(),n=_.Zl(),s=(this.xu(t,i,n),_.Util.getOptimalZoom(this.bt));return{size:this._size,pitch:this.Pu,rotation:this.nu,zoom:this.bt,optimalZoom:s,resolution:this.du,optimalResolution:_.ProjectionManager.getProjection(this.su).getResolution(s),center:this.hu,bounds:t,boundsCoord:i,transformedBoundsCoord:n,centerCoord:this.uu,projectionId:this.su,mvpMatrix:this.cu.Vl(),modelMatrix:this.cu.Au(),viewMode:this.type,skyHeight:this.EF(),fov:this.cu.Tu}},y.prototype.$u=function(t){return 80},y.prototype.Uu=function(t){var t=void 0!==t?t:this.Pu,i=this.bt,t=Math.max(t/100-.4,0),i=Math.max(4*(i-22),0)/100;return this._size[1]*(t-i)-10},y.prototype.EF=function(){var t=1;return 0<(t=this.Uu())?1-t/this._size[1]*2:1},y.prototype.X=function(t,i){var n,s=this.cu.Cu(),e=this.cu.Au(),r=this._size;return t=t/r[0]*2-1,i=1-i/r[1]*2,s?(r=_.Bu(t,i,-1,1),this.Wu(r,this.tu),n=_.Zl(),_.Gu(n,r,s),r=_.Bu(t,i,1,1),this.Wu(r,this.iu),t=_.Zl(),_.Gu(t,r,s),i=_.Zl(),_.Gu(i,n,e),r=_.Zl(),_.Gu(r,t,e),s=+i[2]/(i[2]-r[2]),[i[0]-s*(i[0]-r[0]),i[1]-s*(i[1]-r[1])]):[0,0]},y.prototype.ku=function(t,i){var n=_.Util.getOptimalZoom(this.bt),s=this.uu,e=this.X(t,i);return t=e[0],i=e[1],n>=_.Ra&&(t+=(e=_.lcs.getLocalByCoord([s[0],s[1]])).center[0],i+=e.center[1]),[t,i]},y.prototype.H=function(t,i,n){void 0===n&&(n=0);var s=this.cu.Su(),e=this.cu.Lu(),t=((r=this.fG)[0]=t,r[1]=i,r[2]=n,this.uG),i=this.cG,n=(_.Gu(t,r,e),_.Gu(i,t,s),_.scale(i,i,1/i[3]),(i[0]+1)/2*this._size[0]),r=(1-i[1])/2*this._size[1];return this.lG(i),this.lG(t),[n,r]},y.prototype._u=function(t,i,n){void 0===n&&(n=0);var s=_.Util.getOptimalZoom(this.bt),e=this.uu;return s>=_.Ra&&(t-=(s=_.lcs.getLocalByCoord([e[0],e[1]])).center[0],i-=s.center[1]),this.H(t,i,n)},y.prototype.containerTolnglat=function(t,i){var t=this.X(t,i),i=0,n=0,s=(_.Util.getOptimalZoom(this.bt)>=_.Ra&&(i=(s=_.lcs.getLocalByCoord([this.uu[0],this.uu[1]]).center)[0],n=s[1]),t[0]+=i,t[1]+=n,_.ProjectionManager.getProjection(this.su).unproject(t[0],t[1]));return s[0]=180<s[0]?s[0]-360:s[0]<-180?s[0]+360:s[0],s},y.prototype.lnglatToContainer=function(t,i,n,s){return void 0===n&&(n=0),t=_.ProjectionManager.getProjection(this.su).project(t,i),_.Util.getOptimalZoom(this.bt)>=_.Ra&&(i=_.lcs.getLocalByCoord([this.uu[0],this.uu[1]]),t[0]-=i.center[0],t[1]-=i.center[1]),this.H(t[0],t[1],n)},y.prototype.pz=function(){return this.cu},y.prototype.h_=function(){return _.Ru(this.Xl,this.cu.Vl())},y.prototype.aD=function(){return this.Xl=this.cu.Vl(),this.Xl},y.prototype.xu=function(t,i,n){var s=0,e=0,r=this.Uu(),h=(_.Util.getOptimalZoom(this.bt)>=_.Ra&&(s=(h=_.lcs.getLocalByCoord([this.uu[0],this.uu[1]]).center)[0],e=h[1]),_.ProjectionManager.getProjection(this.su)),o=this.X(0,r),a=this.X.apply(this,this._size),r=this.X(this._size[0],r),u=this.X(0,this._size[1]),c=Math.min(o[0],u[0],r[0],a[0])+s,s=Math.max(o[0],u[0],r[0],a[0])+s,f=Math.min(o[1],u[1],r[1],a[1])+e,o=Math.max(o[1],u[1],r[1],a[1])+e,u=h.unproject(c,f),r=h.unproject(s,o),a=(i[0]=c,i[1]=f,i[2]=s,i[3]=o,t[0]=u[0],t[1]=u[1],t[2]=r[0],t[3]=r[1],_.V[this.su].transform(i[0],i[3])),e=_.V[this.su].transform(i[2],i[1]);return n[0]=a[0],n[1]=a[1],n[2]=e[0],n[3]=e[1],t},y.prototype.vu=function(){var t=this._size,i=t[0]*this.du,n=t[1]*this.du,s=(this.cu.setSize([i,n]),this.cu.Eu(),this.cu.dz()),s=(this.tu=s/10,this.iu=50*s,56-this.bt);this.cu.setOptions([i,n],s,t[0]/t[1],this.tu,this.iu),this.cu.Eu()},y.prototype.fu=function(){var t;return _.Util.getOptimalZoom(this.bt)<_.Ra?[this.uu[0],this.uu[1]]:[(t=_.lcs.getDeltaCoord([this.uu[0],this.uu[1]]))[0],t[1]]},y.prototype.lu=function(t){return this.hu[0]=180<this.hu[0]?this.hu[0]-360:this.hu[0]<-180?this.hu[0]+360:this.hu[0],t.project(this.hu[0],this.hu[1])},y.prototype.Wu=function(t,i){t[0]*=i,t[1]*=i,t[2]*=i,t[3]*=i},y.prototype.lG=function(t){for(var i=t.length,n=0;n<i;n++)t[n]=0};var Fn,Gn=y;function y(t,i){var n=Fn.call(this)||this;return n.type="3D",n.Pu=0,n.hu=[116.397128,39.916527],n.bt=12,n.tu=1e3,n.iu=1<<30,n._size=[0,0],n.nu=0,n.cu=new Wn,n.su="EPSG:3857",n.uu=_.Dl(),n.du=_.ProjectionManager.getProjection(n.su).getResolution(12),n.Xl=_.Il(),n.fG=[0,0,0,1],n.uG=[0,0,0,0],n.cG=[0,0,0,0],n.map=i,n.setOptions(t),n.cu.Ou(n.uu[0],n.uu[1]),n.Xl=n.cu.Vl(),n}var Nn={Fe:["water","buildings","sky","atmosphere","bg","traffic"],aX:{regions:{subType:{land:{styleMap:[{mainkey:30001,subkey:[1,4,5]}],name:["区域面","陆地"]},green:{styleMap:[{mainkey:30001,subkey:[3,7,8,9,10,12,37]}],name:["区域面","绿地"]},"water:ocean":{styleMap:[{mainkey:30001,subkey:[6]},{mainkey:10002,subkey:[38]}],name:["区域面","海洋"]},"water:watersystem":{styleMap:[{mainkey:30001,subkey:[2,11,13]},{mainkey:20014},{mainkey:10002,subkey:[13]}],name:["区域面","其他水系"]},edu:{styleMap:[{mainkey:30002,subkey:[3,31]},{mainkey:30005,subkey:[1,2,3,4,5,6]}],name:["区域面","教育体育"]},scenicSpot:{styleMap:[{mainkey:30002,subkey:[5,33,41]}],name:["区域面","景区"]},sports:{styleMap:[{mainkey:30002,subkey:[9,10,13,19,20,21,34,37,39]}],name:["区域面","运动场所"]},parkingLot:{styleMap:[{mainkey:30002,subkey:[1]}],name:["区域面","停车场"]},subway:{styleMap:[{mainkey:30003}],name:["区域面","地铁设施"]},servicearea:{styleMap:[{mainkey:30002,subkey:[42,43]}],name:["区域面","高速服务区"]},desert:{styleMap:[{mainkey:30002,subkey:[41]}],name:["区域面","沙漠沙地"]},culture:{styleMap:[{mainkey:30002,subkey:[7,35]}],name:["区域面","文化"]},public:{styleMap:[{mainkey:30002,subkey:[4,12,22,32,42,43]},{mainkey:30005,subkey:[7]}],name:["区域面","公共设施"]},health:{styleMap:[{mainkey:30002,subkey:[8,36]}],name:["区域面","医疗卫生"]},business:{styleMap:[{mainkey:30002,subkey:[11,23,24,25,26,27,28,29,30,38]}],name:["区域面","商业场所"]},transporthub:{styleMap:[{mainkey:30002,subkey:[6,14,40]},{mainkey:30004}],name:["区域面","交通枢纽"]}}},roads:{subType:{"highWay:highway":{styleMap:[{mainkey:20001,subkey:[1,5]}],name:["道路","高速"]},"highWay:highwayTunnel":{styleMap:[{mainkey:20001,subkey:[3]}],name:["道路","高速隧道"]},"highWay:highwayOthers":{styleMap:[{mainkey:20001,subkey:[2,6]}],name:["道路","高速其他路"]},"ringRoad:ringRoad":{styleMap:[{mainkey:20002,subkey:[1,5]}],name:["道路","环路"]},"ringRoad:ringRoadTunnel":{styleMap:[{mainkey:20002,subkey:[3]}],name:["道路","环路隧道"]},"ringRoad:ringRoadOthers":{styleMap:[{mainkey:20002,subkey:[2]}],name:["道路","环路其他路"]},"nationalRoad:nationalRoad":{styleMap:[{mainkey:20003,subkey:[1]}],name:["道路","国道"]},"nationalRoad:nationalRoadTunnel":{styleMap:[{mainkey:20003,subkey:[3]}],name:["道路","国道隧道"]},"nationalRoad:nationalRoadOthers":{styleMap:[{mainkey:20003,subkey:[2,5]}],name:["道路","国道其他路"]},"provincialRoad:provincialRoad":{styleMap:[{mainkey:20004,subkey:[1]}],name:["道路","省道"]},"provincialRoad:provincialRoadTunnel":{styleMap:[{mainkey:20004,subkey:[3]}],name:["道路","省道隧道"]},"provincialRoad:provincialRoadOthers":{styleMap:[{mainkey:20004,subkey:[2]}],name:["道路","省道其他路"]},secondaryRoad:{styleMap:[{mainkey:20007},{mainkey:20031},{mainkey:20032}],name:["道路","二级道路"]},levelThreeRoad:{styleMap:[{mainkey:20008}],name:["道路","三级道路"]},levelFourRoad:{styleMap:[{mainkey:20009},{mainkey:20026}],name:["道路","四级道路"]},roadsBeingBuilt:{styleMap:[{mainkey:20018},{mainkey:20023}],name:["道路","在建道路"]},railway:{styleMap:[{mainkey:20010,subkey:[1,3]}],name:["道路","铁路"]},highSpeedRailway:{styleMap:[{mainkey:20010,subkey:[2]}],name:["道路","高铁"]},subway:{styleMap:[{mainkey:20015,subkey:[3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,31,32,33,34,35,36,37,38,39,40,41,42,44,45,46,47,48,50,51,52,54,55,56,57,58,59,60,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,86,87,89,90,91,92,93,94,95,96,97,98,99,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190]}],name:["道路","地铁"]},subwayBeingBuilt:{styleMap:[{mainkey:20015,subkey:[1,2]},{mainkey:20019}],name:["道路","在建地铁"]},overPass:{styleMap:[{mainkey:20012}],name:["道路","天桥"]},underPass:{styleMap:[{mainkey:20013}],name:["道路","地道"]},other:{styleMap:[{mainkey:20011},{mainkey:20017},{mainkey:20020},{mainkey:20024},{mainkey:20028}],name:["道路","其他线路"]},guideBoards:{styleMap:[{mainkey:40001}],name:["道路","道路路牌"]}}},labels:{subType:{"building:officebuilding":{styleMap:[{mainkey:10001,subkey:[5,74,75,76,77,78,79]},{mainkey:10004,subkey:[12]}],name:["标注","商务大厦"]},"building:residence":{styleMap:[{mainkey:10001,subkey:[6,80,81]}],name:["标注","住宅"]},"building:landmark":{styleMap:[{mainkey:10007,subkey:[187,188,189,190,192,193,195,196,198]}],name:["标注","地标建筑"]},"repast:restaurant":{styleMap:[{mainkey:10001,subkey:[19,20,114,115,116,117,118,119]},{mainkey:10007,subkey:[179,180,181]},{mainkey:10010,subkey:[5,6]}],name:["标注","餐厅"]},"repast:tearoom":{styleMap:[{mainkey:10007,subkey:[167]}],name:["标注","茶馆"]},"repast:cafe":{styleMap:[{mainkey:10001,subkey:[22]},{mainkey:10007,subkey:[215]}],name:["标注","咖啡厅"]},"repast:dessert":{styleMap:[{mainkey:10007,subkey:[166]}],name:["标注","甜品店"]},"entertainment:mall":{styleMap:[{mainkey:10001,subkey:[7,68,82,83,84,85,93,94,98]},{mainkey:10004,subkey:[8,18]},{mainkey:10007,subkey:[175,200,201,202,203,204]}],name:["标注","购物商场"]},"entertainment:market":{styleMap:[{mainkey:10001,subkey:[8,92]},{mainkey:10007,subkey:[1,2,3,4,5,6,10,168]}],name:["标注","便利超市"]},"entertainment:cinema":{styleMap:[{mainkey:10001,subkey:[60]},{mainkey:10007,subkey:[178]}],name:["标注","影剧院"]},"entertainment:entertainment":{styleMap:[{mainkey:10001,subkey:[61,62]},{mainkey:10007,subkey:[169]}],name:["标注","娱乐场所"]},"entertainment:pedestrainmall":{styleMap:[{mainkey:10001,subkey:[99]}],name:["标注","步行街"]},"entertainment:hotel":{styleMap:[{mainkey:10001,subkey:[9,133,134,135,136]}],name:["标注","酒店"]},"entertainment:zoo":{styleMap:[{mainkey:10001,subkey:[38,103]}],name:["标注","动物园"]},"entertainment:funfair":{styleMap:[{mainkey:10001,subkey:[37,73,184,185,188,203,204,205]}],name:["标注","游乐场"]},"scenic:attraction":{styleMap:[{mainkey:10001,subkey:[4,12,104,105,106,107,108,109,110,111,112,120,167,168,171,213]},{mainkey:10004,subkey:[3,13,21]},{mainkey:10007,subkey:[48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,216,217,218,219,220,221,222,223,224,225,227,228,229,230,231,236]},{mainkey:10008}],name:["标注","风景名胜"]},"scenic:park":{styleMap:[{mainkey:10001,subkey:[14,69,100,101,102]}],name:["标注","公园"]},"scenic:mountain":{styleMap:[{mainkey:10001,subkey:[18]}],name:["标注","山"]},"traffic:busstop":{styleMap:[{mainkey:10001,subkey:[24]}],name:["标注","公交站"]},"traffic:port":{styleMap:[{mainkey:10001,subkey:[36]}],name:["标注","港口"]},"traffic:transporthub":{styleMap:[{mainkey:10001,subkey:[2,27,28,29,30,31,172,175]},{mainkey:10004,subkey:[4,10,14,20]}],name:["标注","交通枢纽"]},"traffic:trainstation":{styleMap:[{mainkey:10001,subkey:[26]}],name:["标注","火车站"]},"traffic:airportterminal":{styleMap:[{mainkey:10001,subkey:[23,176,177,178]},{mainkey:10009}],name:["标注","机场航站楼"]},"traffic:coachstation":{styleMap:[{mainkey:10001,subkey:[25]}],name:["标注","长途汽车站"]},culture:{styleMap:[{mainkey:10001,subkey:[10,11,13,35,138,139,140,141,142,143,163,164,165,166,170]},{mainkey:10004,subkey:[1,5,11,15]},{mainkey:10007,subkey:[43,44,45,46,47,176,177]}]},"service:lifestyle":{styleMap:[{mainkey:10001,subkey:[58,63,64,65,66,67,121,122,123,173,214]},{mainkey:10007,subkey:[28,29,30,58]}],name:["标注","生活服务"]},"service:bank":{styleMap:[{mainkey:10007,subkey:[14,15,16,17]}],name:["标注","银行"]},"service:restroom":{styleMap:[{mainkey:10001,subkey:[59]}],name:["标注","卫生间"]},"medical:medicalcenter":{styleMap:[{mainkey:10001,subkey:[70]},{mainkey:10004,subkey:[6,16]}],name:["标注","大型医院"]},"medical:hospital":{styleMap:[{mainkey:10001,subkey:[32,33,169,206,207,208,209,210]},{mainkey:10007,subkey:[170]}],name:["标注","医院"]},"medical:emergencycenter":{styleMap:[{mainkey:10001,subkey:[132]}],name:["标注","急救中心"]},"medical:clinic":{styleMap:[{mainkey:10001,subkey:[131]},{mainkey:10007,subkey:[209]}],name:["标注","诊所"]},"medical:pharmacy":{styleMap:[{mainkey:10001,subkey:[57]}],name:["标注","药店"]},"casual:golf":{styleMap:[{mainkey:10004,subkey:[7,17]}],name:["标注","高尔夫"]},"casual:swimmingpool":{styleMap:[{mainkey:10007,subkey:[171]}],name:["标注","游泳馆"]},"casual:basketballcourt":{styleMap:[{mainkey:10001,subkey:[129]}],name:["标注","篮球馆"]},"casual:soccerfield":{styleMap:[{mainkey:10001,subkey:[130]}],name:["标注","足球场"]},"casual:tenniscourt":{styleMap:[{mainkey:10007,subkey:[174]}],name:["标注","网球场"]},"casual:otherstadium":{styleMap:[{mainkey:10001,subkey:[15,16,17,124,125,126,127,128]},{mainkey:10007,subkey:[172,173]}],name:["标注","其他体育馆"]},"point:toll":{styleMap:[{mainkey:10001,subkey:[218]}],name:["标注","收费站"]},"point:trafficlight":{styleMap:[{mainkey:10001,subkey:[2]}],name:["标注","红绿灯"]},"point:tunnel":{styleMap:[{mainkey:10002,subkey:[16]}],name:["标注","隧道"]},insurance:{styleMap:[{mainkey:10001,subkey:[42,55]}],name:["标注","金融保险"]},motorcycleservices:{styleMap:[{mainkey:10001,subkey:[113]}],name:["标注","摩托车服务"]},automobileservices:{styleMap:[{mainkey:10001,subkey:[39,40,41,71,72]},{mainkey:10007,subkey:[40,41,42]}],name:["标注","汽车服务"]},subway:{styleMap:[{mainkey:10005},{mainkey:10006}],name:["标注","地铁站"]},transportfacilities:{styleMap:[{mainkey:10001,subkey:[149,150,215,216,217]},{mainkey:10002,subkey:[11]},{mainkey:11001,subkey:[1,2,3]},{mainkey:10004,subkey:[22,23]}],name:["标注","道路附属设施"]},bizcircle:{styleMap:[{mainkey:10002,subkey:[10]}],name:["标注","商圈"]},others:{styleMap:[{mainkey:10001,subkey:[1,3,34,43,137]},{mainkey:10002,subkey:[12,14,15,21,23,28,36]},{mainkey:10004,subkey:[2]},{mainkey:10007,subkey:[208,210,211,212,213,214]},{mainkey:10011},{mainkey:10012},{mainkey:10013},{mainkey:10014},{mainkey:10015},{mainkey:10016}],name:["标注","其他"]}}},districtsname:{subType:{continent:{styleMap:[{mainkey:10002,subkey:[20]}],name:["行政区名","大洲名"]},country_cn:{styleMap:[{mainkey:10002,subkey:[18]}],name:["行政区名","中国国家名"]},country_global:{styleMap:[{mainkey:10002,subkey:[19]}],name:["行政区名","世界国家名"]},capital_global:{styleMap:[{mainkey:10002,subkey:[24,35]}],name:["行政区名","境外首都名"]},state:{styleMap:[{mainkey:10002,subkey:[1,3,4,22,26,30,32,33,34]}],name:["行政区名","省/直辖市/特别行政区名"]},"city:provincial_capital":{styleMap:[{mainkey:10002,subkey:[2,31]}],name:["行政区名","省会名"]},"city:city":{styleMap:[{mainkey:10002,subkey:[5,7,25,27]}],name:["行政区名","地级市名"]},"city:district":{styleMap:[{mainkey:10002,subkey:[6]}],name:["行政区名","县级市名"]},district:{styleMap:[{mainkey:10002,subkey:[8,37]}],name:["行政区名","区县名"]},town:{styleMap:[{mainkey:10002,subkey:[9]}],name:["行政区名","乡镇名"]},village:{styleMap:[{mainkey:10002,subkey:[17]}],name:["行政区名","村庄名"]}}},borders:{subType:{global:{styleMap:[{mainkey:20016,subkey:[3,4,8,10,11,14]}],name:["行政区边界","外国国界/停火线/主张线"]},provincial:{styleMap:[{mainkey:20016,subkey:[5,6,7,12]}],name:["行政区边界","省界线"]}}},buildings:{subType:{default:{styleMap:[{mainkey:50001,subkey:[1,2]}],name:["楼块","默认楼块"]},education:{styleMap:[{mainkey:50002,subkey:[1,2,3,4]}],name:["楼块","高校教学"]}}},environment:{subType:{sky:{styleMap:[{mainkey:"00001",subkey:[1]}],name:["环境","天空"]},atmosphere:{styleMap:[{mainkey:"00001",subkey:[2]}],name:["环境","大气"]}}},bg:{styleMap:[{mainkey:"00001",subkey:[3]}]}},uX:{regions:{name:"区域面",subType:{land:{name:"陆地",keyMap:["regions#land"],styleMap:[{mainkey:30001,subkey:[1,4,5]}]},green:{name:"绿地",keyMap:["regions#green:greenspace","regions#green:grass","regions#green:woodland","regions#green:mountain","regions#green:golf"],styleMap:[{mainkey:30001,subkey:[3,7,8,9,10,12]}]},edu:{name:"教育体育",keyMap:["regions#edu"],styleMap:[{mainkey:30002,subkey:[3,31]}]},public:{name:"公共设施",keyMap:["regions#public"],styleMap:[{mainkey:30002,subkey:[4,12,22,32]}]},traffic:{name:"交通枢纽",keyMap:["regions#transporthub"],styleMap:[{mainkey:30002,subkey:[6,14,40]},{mainkey:30004,subkey:[6,14,40]}]},scenicSpot:{name:"景区",keyMap:["regions#scenicSpot"],styleMap:[{mainkey:30002,subkey:[5,33]}]},culture:{name:"文化",keyMap:["regions#culture"],styleMap:[{mainkey:30002,subkey:[7,35]}]},health:{name:"医疗卫生",keyMap:["regions#health"],styleMap:[{mainkey:30002,subkey:[8,36]}]},sports:{name:"运动场所",keyMap:["regions#sports"],styleMap:[{mainkey:30002,subkey:[9,10,13,19,20,21,34,37,39]}]},business:{name:"商业场所",keyMap:["regions#business"],styleMap:[{mainkey:30002,subkey:[11,23,24,25,26,27,28,29,30,38]}]},parkingLot:{name:"停车场",keyMap:["regions#parkingLot"],styleMap:[{mainkey:30002,subkey:[1]}]},subway:{name:"地铁设施",keyMap:["regions#subway"],styleMap:[{mainkey:30003,allSubKey:!0}]}}},water:{name:"水系",keyMap:["regions#water:ocean","regions#water:watersystem"],styleMap:[{mainkey:30001,subkey:[2,6,11,13]},{mainkey:20014,subkey:[1,2]},{mainkey:10002,subkey:[13,38]}]},buildings:{name:"建筑物",keyMap:["buildings#default","buildings#residence","buildings#education","buildings#life","buildings#event","buildings#landmark"],styleMap:[{mainkey:50001,subkey:[1,2]},{mainkey:50002,subkey:[1,2,3,4]},{mainkey:50003,subkey:[1]},{mainkey:50004,subkey:[1]},{mainkey:30002,subkey:[2,15,16,17,18]}]},roads:{name:"道路",subType:{highWay:{name:"高速公路",keyMap:["roads#highWay:highway","roads#highWay:highwayTunnel","roads#highWay:highwayOthers"],styleMap:[{mainkey:20001,subkey:[1,2,3,5,6]}]},ringRoad:{name:"城市环线",keyMap:["roads#ringRoad:ringRoad","roads#ringRoad:ringRoadTunnel","roads#ringRoad:ringRoadOthers"],styleMap:[{mainkey:20002,subkey:[1,2,3]}]},nationalRoad:{name:"国道",keyMap:["roads#nationalRoad:nationalRoad","roads#nationalRoad:nationalRoadTunnel","roads#nationalRoad:nationalRoadOthers"],styleMap:[{mainkey:20003,subkey:[1,2,3,5]}]},provincialRoad:{name:"省道",keyMap:["roads#provincialRoad:provincialRoad","roads#provincialRoad:provincialRoadTunnel","roads#provincialRoad:provincialRoadOthers"],styleMap:[{mainkey:20004,subkey:[1,2,3]}]},secondaryRoad:{name:"二级公路",keyMap:["roads#secondaryRoad"],styleMap:[{mainkey:20007,subkey:[1,2,3]}]},levelThreeRoad:{name:"三级公路",keyMap:["roads#levelThreeRoad"],styleMap:[{mainkey:20008,subkey:[1,2,4,5]}]},levelFourRoad:{name:"四级道路",keyMap:["roads#levelFourRoad"],styleMap:[{mainkey:20009,subkey:[1,2,3,5,6,7]}]},roadsBeingBuilt:{name:"在建道路",keyMap:["roads#roadsBeingBuilt"],styleMap:[{mainkey:20018,subkey:[2,3,4,5,6,7,8,9,10,11]}]},railway:{name:"铁路",keyMap:["roads#railway"],styleMap:[{mainkey:20010,subkey:[1]}]},highSpeedRailway:{name:"高铁",keyMap:["roads#highSpeedRailway"],styleMap:[{mainkey:20010,subkey:[2]}]},subway:{name:"地铁",keyMap:["roads#subway"],styleMap:[{mainkey:20015,allSubKey:!0,subkey0:[1,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,31,32,33,34,35,36,37,38,39,40,41,42,44,45,46,47,48,50,51,52,54,55,56,57,58,59,60,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,86,87,89,90,91,92,93,94,95,96,97,98,99,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,131,132,133,143]}]},subwayBeingBuilt:{name:"在建地铁",keyMap:["roads#subwayBeingBuilt"],styleMap:[{mainkey:20015,subkey:[1,2]},{mainkey:20019,subkey:[1]}]},overPass:{name:"天桥",keyMap:["roads#overPass"],styleMap:[{mainkey:20012,subkey:[1,2,3]}]},underPass:{name:"地道",keyMap:["roads#underPass"],styleMap:[{mainkey:20013,subkey:[1,2,3]}]},other:{name:"其他线条",keyMap:["roads#other"],styleMap:[{mainkey:20011,subkey:[1]},{mainkey:20017,subkey:[1,2,3,4,8]},{mainkey:20020,subkey:[1,2,3]},{mainkey:20024,subkey:[1,2]},{mainkey:20028,subkey:[1]}]},guideBoards:{name:"道路路牌",keyMap:["roads#guideBoards"],styleMap:[{mainkey:40001,subkey:[2800,110100,110101,110102,110103,110104,110105]}]}}},labels:{name:"标注",subType:{pois:{name:"兴趣点",subType:{hotel:{name:"住宿",keyMap:["labels#entertainment:hotel"],isDetailedType:!0,detailedCode:0,styleMap:[{mainkey:10001,subkey:[9,133,134,135,136,155,156,157,158,159,160,161,162,186]},{mainkey:10007,subkey:[31,32,33,34,35,36,37,38,39,164,165]}]},restaurant:{name:"餐饮",keyMap:["labels#repast:restaurant"],isDetailedType:!0,detailedCode:1,styleMap:[{mainkey:10001,subkey:[19,20,21,22,114,115,116,117,118,119,183,187]},{mainkey:10007,subkey:[1,2,3,4,166,167,168,179,180,181,203,205,206,215]}]},shop:{name:"购物",keyMap:["labels#entertainment:mall"],isDetailedType:!0,detailedCode:2,styleMap:[{mainkey:10001,subkey:[7,8,68,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99]},{mainkey:10007,subkey:[5,6,7,8,9,10,11,12,13,175,200,201,202,204]}]},scenicSpot:{name:"风景名胜",keyMap:["labels#repast:restaurant","labels#scenic:park"],isDetailedType:!0,detailedCode:3,styleMap:[{mainkey:10001,subkey:[4,12,14,38,69,100,101,102,103,104,105,106,107,108,109,110,111,112,120,167,171,188,189,190,191,192]},{mainkey:10008,allSubKey:!0},{mainkey:10007,subkey:[48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,187,188,190,192,193,194,195,196,198,216,217,218,219,220,221,223,224,225]}]},traffic:{name:"交通设施",isDetailedType:!0,detailedCode:4,styleMap:[{mainkey:10001,subkey:[23,24,25,26,31,36,148,154,168,172,175,176,177,178]},{mainkey:10002,subkey:[11,16]},{mainkey:10009,allSubKey:!0}]},bank:{name:"金融保险",isDetailedType:!0,detailedCode:5,styleMap:[{mainkey:10001,subkey:[42,44,45,46,47,48,49,50,51,52,53,54,55,144,145,146,147]},{mainkey:10007,subkey:[14,15,16,17,18,19,20,21,22,23,24,25,26,27]}]},edu:{name:"科教文化",isDetailedType:!0,detailedCode:6,styleMap:[{mainkey:10001,subkey:[10,11,13,35,138,139,140,141,142,143,163,164,165,166,170]},{mainkey:10007,subkey:[43,44,45,46,47,176,177]}]},live:{name:"生活服务",isDetailedType:!0,detailedCode:7,styleMap:[{mainkey:10001,subkey:[58,63,64,65,66,67,121,122,123]},{mainkey:10007,subkey:[28,29,30]}]},hospital:{name:"医疗保健",isDetailedType:!0,detailedCode:8,styleMap:[{mainkey:10001,subkey:[32,33,57,70,131,132,169,193,206,207,208,209,210]},{mainkey:10007,subkey:[170,209]}]},pe:{name:"休闲体育",isDetailedType:!0,detailedCode:9,styleMap:[{mainkey:10001,subkey:[15,16,17,37,60,61,62,73,124,125,126,127,128,129,130,180,181,182,184,185,194,195,196,197,198,199,200,201,202,203,204,205,213,214]},{mainkey:10007,subkey:[169,171,172,173,174,178,197,207]}]},public:{name:"公共设施",isDetailedType:!0,detailedCode:10,styleMap:[{mainkey:10001,subkey:[59,173,215]}]},buidling:{name:"商务住宅",isDetailedType:!0,detailedCode:11,styleMap:[{mainkey:10001,subkey:[5,6,74,75,76,77,78,79,80,81,179]},{mainkey:10007,subkey:[189,191]}]},gov:{name:"政府机构及社会团体",isDetailedType:!0,detailedCode:12,styleMap:[{mainkey:10001,subkey:[3,34,43,137]}]},moto:{name:"摩托车服务",isDetailedType:!0,detailedCode:13,styleMap:[{mainkey:10001,subkey:[113]}]},vehicle:{name:"汽车服务",isDetailedType:!0,detailedCode:14,styleMap:[{mainkey:10001,subkey:[39,40,41,71,72,151,152,153]},{mainkey:10007,subkey:[40,41,42,182,183,184,185,186]}]},pass:{name:"通行设施",isDetailedType:!0,detailedCode:15,styleMap:[{mainkey:10001,subkey:[27,28,149,150,174]},{mainkey:10002,subkey:[21]}]},subway:{name:"地铁站",isDetailedType:!0,detailedCode:16,styleMap:[{mainkey:10005,subkey:[1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31,33,35,37,39,41,43,45,47,49,51,53,54,55,56,57,59,86,87,88,89,90,91,92,93,94,95,96,97,98,99,103,104,105]},{mainkey:10006,subkey:[1,2]}]},roadFacilities:{name:"道路附属设施",isDetailedType:!0,detailedCode:17,styleMap:[{mainkey:10001,subkey:[2,29,30]},{mainkey:10017,allSubKey:!0}]},address:{name:"地名",isDetailedType:!0,detailedCode:18,styleMap:[{mainkey:10001,subkey:[18]},{mainkey:10002,subkey:[10,12,14,15,23,36]}]},other:{name:"其他",isDetailedType:!0,detailedCode:19,styleMap:[{mainkey:10001,subkey:[1,211,212]},{mainkey:10002,subkey:[28]},{mainkey:10007,subkey:[208,210,211,212,213,214]},{mainkey:10010},{mainkey:10011},{mainkey:10012},{mainkey:10013},{mainkey:10014},{mainkey:10015},{mainkey:10016,allSubKey:!0}]}}},aois:{name:"区域标注",keyMap:["labels#building:officebuilding","labels#entertainment:mall","labels#traffic:transporthub","labels#medical:medicalcenter","labels#casual:golf"],styleMap:[{mainkey:10004,allSubKey:!0,subkey:[1,3,4,5,6,7,8,11,12,13,14,15,16,17,18,21,22,23]}]},continent:{name:"大洲",keyMap:["districtsname#continent"],styleMap:[{mainkey:10002,subkey:[20]}]},country:{name:"国家",keyMap:["districtsname#country_cn"],styleMap:[{mainkey:10002,subkey:[18,19,29]}]},province:{name:"省/直辖市/自治区/特别行政区",keyMap:["districtsname#state"],styleMap:[{mainkey:10002,subkey:[22,26,33]}]},city:{name:"城市",keyMap:["districtsname#city:provincial_capital","districtsname#city:city"],styleMap:[{mainkey:10002,subkey:[1,2,3,4,5,7,24,25,27,30,31,32,34,35]}]},district:{name:"区县",keyMap:["districtsname#city:district"],styleMap:[{mainkey:10002,subkey:[6,8,37]}]},town:{name:"乡镇",keyMap:["districtsname#town"],styleMap:[{mainkey:10002,subkey:[9]}]},village:{name:"村庄",keyMap:["districtsname#village"],styleMap:[{mainkey:10002,subkey:[17]}]}}},borders:{name:"行政区边界",subType:{China:{name:"中国国界",keyMap:["borders#China"],styleMap:[{mainkey:20016,subkey:[1,2,9]}]},foreign:{name:"外国国界/停火线/主张线",keyMap:["borders#global"],styleMap:[{mainkey:20016,subkey:[3,4,8,10,11,14,16]}]},provincial:{name:"省界线",keyMap:["borders#provincial"],styleMap:[{mainkey:20016,subkey:[5,6,7,12]}]}}},sky:{name:"天空",keyMap:["environment#sky"],styleMap:[{mainkey:"00001",subkey:[1]}]},atmosphere:{name:"大气",keyMap:["environment#atmosphere"],styleMap:[{mainkey:"00001",subkey:[2]}]},bg:{name:"背景网格线",keyMap:["bg"],styleMap:[{mainkey:"00001",subkey:[3]}]}}},_n=(Un.prototype.pn=function(t){this.qe?t(this.ON):this.Ye.push(t)},Un.prototype.dn=function(t,i,n){return this.vn.dn(t,i,n)},Un.prototype.mn=function(t,i){return this.vn.mn(t,i)},Un.prototype.setStyle=function(t,i,n){var s=t;this.vn.setStyle(s),t.layer&&this.vn.EY(t.layer),this.vn.kF(t),n.gn.bn(s,function(){n.emit("styleChanged")})},Un.prototype.setStyleByPlat=function(t,i){var n;_.Module.eS.BY&&(n=this.xn(t),this.vn.setStyle(n),t.layer&&this.vn.EY(t.layer),this.vn.kF(t),i.gn.bn(n,function(){i.emit("styleChanged")}))},Un.prototype.destroy=function(){this.vn&&this.vn.destroy(),this.Ze={},this.ON=""},Un.prototype.w_=function(t){var i;return this.Ze&&this.Ze[t]?(i=[],Object.keys(this.Ze[t]).forEach(function(t){t=parseFloat(t),i.push(t)}),i):null},Un.prototype.VY=function(t){var t={style:t},i=new XMLHttpRequest;i.onreadystatechange=function(){4===i.readyState&&200===i.status?console.log("qqqqq"):404===i.status&&i.abort()},i.open("POST","http://webapi.amap.com/formatstyle"),i.setRequestHeader("Content-type","application/json"),i.send(JSON.stringify(t))},Un.prototype.xn=function(t){for(var i={},n=t.version&&"2.0"===t.version?t.mapStyle:t,s=t.version&&"2.0"===t.version?Nn.aX:Nn.uX,e=Object.keys(n),r=0;r<e.length;r++){var h=e[r],o=n[h];if(s[h]){var a=s[h];if(a.styleMap){for(var u=a.styleMap,c=0;c<u.length;c++)if(i[A=u[c].mainkey]||(i[A]={}),u[c].subkey)for(var f=0;f<u[c].subkey.length;f++){var l=u[c].subkey[f],d=_.yn(o);if(o.styles)for(var v=Object.keys(o.styles),p=0;p<v.length;p++){var m=v[p],y=o.styles[m].transitional,b=o.styles[m].nodes;d.styles[m]={nodes:b,transitional:y||void 0,nodesObj:{}};for(var g=0;g<b.length;g++){var M=b[g].zoom,k=b[g].value;d.styles[m].nodesObj[M]=k}}i[A][l]=d}}else if(a.subType&&o.subType)for(var w=Object.keys(o.subType),c=0;c<w.length;c++){var x=w[c];if(a.subType[x]&&a.subType[x].styleMap){for(u=a.subType[x].styleMap,f=0;f<u.length;f++)if(u[f].mainkey){i[A=u[f].mainkey]||(i[A]={});var A,z=u[f].subkey;if(z=(u[f].allSubKey?this.w_(A):z)||["all"])for(var C=0;C<z.length;C++){var l=z[C],S=o.subType[x];if((d=_.yn(S)).styles)for(v=Object.keys(S.styles),p=0;p<v.length;p++)for(m=v[p],y=S.styles[m].transitional,b=S.styles[m].nodes,d.styles[m]={nodes:b,nodesObj:{},transitional:y||void 0},g=0;g<b.length;g++)M=b[g].zoom,k=b[g].value,d.styles[m].nodesObj[M]=k;i[A][l]=d}}}else if(a.subType[x]&&a.subType[x].subType)for(var T=a.subType[x].subType,j=Object.keys(T),S=o.subType[x],d=_.yn(S),L=0;L<j.length;L++){var I=j[L];if(T[I].styleMap)for(var D=0;D<T[I].styleMap.length;D++){var O=T[I].styleMap[D];if(O.mainkey&&O.subkey){i[O.mainkey]||(i[O.mainkey]={});for(var R=0;R<O.subkey.length;R++){var B=O.subkey[R];if(d.detailedType&&d.detailedType[I]){var E=d.detailedType[I],P=_.yn(E);if(E.styles)for(v=Object.keys(E.styles),p=0;p<v.length;p++)for(m=v[p],b=E.styles[m].nodes,P.styles[m]={nodes:b,nodesObj:{}},g=0;g<b.length;g++)M=b[g].zoom,k=b[g].value,P.styles[m].nodesObj[M]=k;i[O.mainkey][B]=P}else i[O.mainkey][B]=d}}}}}}}return i},Un.prototype.wn=function(t){for(var i=0,n=this.Ye.length;i<n;i+=1)(0,this.Ye[i])(t);this.Ye=[]},Un.prototype.fn=function(t){var i=this,n=(_.Support.amapRunTime&&!_.Support.amapRunTime["style2.0-request"]&&(_.Support.amapRunTime["style2.0-request"]=(new Date).getTime()),window.amap_sdk_log&&window.amap_sdk_log("style-request:"+t+"-"+Date.now()),new XMLHttpRequest);n.onreadystatechange=function(){4===n.readyState&&200===n.status?(_.Support.amapRunTime&&!_.Support.amapRunTime["style2.0-loaded"]&&(_.Support.amapRunTime["style2.0-loaded"]=(new Date).getTime()),window.amap_sdk_log&&window.amap_sdk_log("style-loaded:"+t+"-"+Date.now()),i.zZ(n.response),_.Support.amapRunTime&&!_.Support.amapRunTime["style2.0-decoded"]&&(_.Support.amapRunTime["style2.0-decoded"]=(new Date).getTime()),window.amap_sdk_log&&window.amap_sdk_log("style-decoded:"+t+"-"+Date.now())):404===n.status&&n.abort()},n.open("GET",t,!0),n.responseType="arraybuffer",n.send()},Un.prototype.zZ=function(t){_.Support.amapRunTime&&!_.Support.amapRunTime["style2.0-parseStylesFromText-End"]&&(_.Support.amapRunTime["style2.0-parseStylesFromText-End"]=(new Date).getTime()),t=_.CZ(t),_.Support.amapRunTime&&!_.Support.amapRunTime["style2.0-jsonParse-End"]&&(_.Support.amapRunTime["style2.0-jsonParse-End"]=(new Date).getTime()),window["amapjsapi-style2-local"]?this.Ze=window["amapjsapi-style2-local"]:this.Ze=_.StyleParser.SZ(t),_.Support.amapRunTime&&!_.Support.amapRunTime["style2.0-format-End"]&&(_.Support.amapRunTime["style2.0-format-End"]=(new Date).getTime()),this.vn.jY(this.Ze),this.Ze.Rn=_._n.create("fcf9f2"),this.Ze.zn=24,this.qe=!0,this.ON=JSON.stringify(this.Ze),this.wn(this.ON)},Un);function Un(t){this._map=t,this.vz=null,this.qe=!1,this.Ne=_.Support.$e&&!_.Support.Ue,this._tileUrl=window.__AMapStyleSource||_.Ge||AMap.getConfig().protocol+"://vdata.amap.com/style/2.0.1",this.Ze={},this.Ye=[],this.Ve=null,this.fn(this._tileUrl),this.vn=new _.StyleParser("fast"===t.bZ.MZ.drawMode)}Yn=_.vG,_.Ei(b,Yn),b.prototype.getData=function(t,i){for(var n=this,s=[],e=0,r=t;e<r.length;e++){var h=r[e];s.push(h.charCodeAt(0).toString())}var o=this.Zu(s),a=this._map.gn;switch(o.status){case _.qu.AllLoaded:i();break;case _.qu.AllUnLoaded:var u=this.Yu(i);a&&a.getSDFData(o.Vu,function(t,i){n.Xu[u]=i=void 0===i?{}:i,n.Hu()});break;case _.qu.SomeLoading:var c=this.Yu(i);a&&a.getSDFData(o.Vu,function(t,i){n.Xu[c]=i=void 0===i?{}:i,n.Hu()});break;case _.qu.AllLoading:var f=this.Yu(i);this.Xu[f]=[],this.Hu()}},b.prototype.Ju=function(t){for(var i={},n=0,s=t;n<s.length;n++){var r=(e=s[n]).range,h=e.info,e=e.pos,o=this.info;o[r],o[r]={info:((o={})[r]=h,o),pos:e},this.range.push(r),i[r]=1}return i},b.prototype.mz=function(t,i){var n=this.info||[];return!(i=void 0===i?!1:i)&&n.hasOwnProperty(t)&&(i=n[t]).pos&&i.info[t]?{key:t,index:_.cY.dynamic,char:i.info[t],pos:i.pos}:null},b.prototype.measureText=function(t,i){for(var n=_.PY,s=_.tc.ic,e=0,r=this.info,h=i/this._size,o=this.nc,a=0,u=t;a<u.length;a++){var c=u[a],f=void 0,l=c;(f=13312<=l&&l<=40959?n:o[l])||r.hasOwnProperty(l)&&(l=r[l].info[l])&&(this.nc[c]=f=l[4]),e+=(f+s)*h}return e},b.prototype.destroy=function(){this.range=[],this.info={},this.sc=[],this.Xu&&(this.Xu={}),this._c=[],this.nc={},this.xc=[],this.bc={},this.Xu={}},b.prototype._bindEvents=function(){this.dG.on("loadWordsByFront",this.pG.bind(this))},b.prototype.fc=function(){var t=_.tc.pc,i=t[this.dc];return this.dc=(this.dc+1)%t.length,i},b.prototype.vc=function(t){void 0===t&&(t={});var i=(t=(Object.keys(t)||[]).sort(function(t,i){return t-i})).length;return 2<=i?t[0]+"-"+t[i-1]:1===i?t[0]:""},b.prototype.mc=function(){},b.prototype.Yu=function(t,i){void 0===i&&(i={});var n=this.yc+=1;return this.xc.push(n),this.bc&&(this.bc[n]=t,this.bc[n]={cb:t,params:i}),n},b.prototype.Hu=function(){var t,i,n=this.xc[0];n&&(t=this.Xu[n])&&(this.xc.shift(),(i=this.bc[n])?i.cb(t):console.error("sdf task error"),delete this.Xu[n],delete this.bc[n],this.Hu())},b.prototype.gc=function(t){for(var i=this.range||[],n=this.info||{},s=parseInt(t,10),e=0,r=i;e<r.length;e++){var h=r[e];if(h.indexOf("-")<0){if(s===+h&&(n[h]&&n[h].info||{})[t])return!0}else{var o=h.split("-"),a=parseInt(o[0]||"",10),o=parseInt(o[1]||"",10);if(a<=s&&s<=o&&(n[h]&&n[h].info||{})[t])return!0}}return!1},b.prototype.pG=function(t){var i=this,n=t.mG,s=t.cb,t=this._map.bZ.MZ.lY.add("LangSDF",n);this._map.bZ.MZ.yY.setNeedUpdate(!0),this._map.bZ.MZ.lY.on("task:"+t,function(t){t=i._map.bZ.MZ.lY.add("SDFCombine",t.data),i._map.bZ.MZ.yY.setNeedUpdate(!0),i._map.bZ.MZ.lY.on("task:"+t,function(t){i.Ju(t.data),s(t.data)},i,!0)},this,!0)},b.prototype._G=function(t){for(var i="",n=0,s=t.split("|");n<s.length;n++){var e=s[n];i+=String.fromCharCode(parseInt(e,10))}return i},b.prototype.wc=function(t){return-1!==this._c.indexOf(t)},b.prototype.Zu=function(t){for(var i=[],n=(this.range,0),s=0,e=0,r=t;e<r.length;e++){var h=r[e];this.gc(h)||(this.wc(h)?s+=1:(n+=1,i.push(h)))}return 0===s&&0===n?{status:_.qu.AllLoaded,Vu:i}:0<n&&0===s?{status:_.qu.AllUnLoaded,Vu:i}:0===n&&0<s?{status:_.qu.AllLoading,Vu:i}:{status:_.qu.SomeLoading,Vu:i}};var Yn,Zn=b;function b(t,i){var n=Yn.call(this)||this;return n._map=i,n.CLASS_NAME="SDFManager",n.range=[],n.info={},n.sc=[],n.dc=0,n._c=[],n._size=24,n.nc={},n.xc=[],n.bc={},n.Xu={},n.yc=1,n.ac=t,n.yG=new _.bG,n.dG=n._map.gn,n._bindEvents(),n}Jn.prototype.play=function(t){for(var i=t,n=Date.now(),s=this.result;0<i&&this.offset<this.mG.length;){var e=this.mG[this.offset],r={},h=this._G(e),o=_.bG.gG(e),h=(o=this.lang.D$(o).Ce(h)).bitmap,o=o.info;r.range=e,r.info=o,r.data=h,s.push(r),this.offset++,i=t-(Date.now()-n)}return this.result},Jn.prototype._G=function(t){for(var i="",n=0,s=t.split("|");n<s.length;n++){var e=s[n];i+=String.fromCharCode(parseInt(e,10))}return i},Object.defineProperty(Jn.prototype,"status",{get:function(){return this.offset>=this.mG.length?_.vY.finish:_.vY.pause},eb:!1,nb:!0});var Xn=Jn;function Jn(t,i){this.lang=t,this.mG=i,this.type="LangSDFTask",this.offset=0,this.result=[]}var Hn={Fdt:["vdata.amap.com","pre-lbs-jsapi-vdata.amap.com"],Gdt:function(i){return Hn.Fdt.some(function(t){return-1<i.indexOf(t)&&-1===i.indexOf("key=")})},getKeyUrl:function(t,i){return Hn.Gdt(t)&&(-1<t.indexOf("?")?t+="&key="+i:t+="?key="+i),t}},Vn=(qn.prototype.loadImage=function(t,i,n){var s=i.name,e=(i.type,i.cb),r=this.Fs[s=s||t];r&&r.status===_.uc.LOADED?e(r,i):r&&r.status===_.uc.LOADING?(this.Mc[s]||(this.Mc[s]=[]),this.Mc[s].push({cb:e,opts:i})):t?this.Rc(t,i,n):e(null,i)},qn.prototype.TZ=function(t,i){this.Rc(t.data,{name:t.hash,cb:i})},qn.prototype.loadImages=function(t,i,n){var s=t.length,e=i.cb,r=0;if(t.length){i.cb=function(){(r+=1)===s&&e()};for(var h=0,o=t;h<o.length;h++){var a=o[h];this.loadImage(a,i,n)}}else e()},qn.prototype.imageLoaded=function(t,i){var n=i.data,i=i.cb,s=this.zc[i];s&&(s(n),delete this.zc[i])},qn.prototype.addImageData=function(t,i){this.Fs[t]||(this.Fs[t]=i)},qn.prototype.getImage=function(t){return this.Fs[t=void 0===t?"":t]||{}},qn.prototype.destory=function(){this.Fs={},this.Mc&&(this.Mc={}),this.zc&&(this.zc={})},qn.prototype.Rc=function(t,e,i){var r=this,n=e.name,h=e.ext,s=e.type,o=void 0===s?"other":s,a=e.cb,u=this.Fs,c=new Image,f=n||t;u[f]={type:o,img:c,ext:h,width:c.width,height:c.height,status:_.uc.LOADING},c.crossOrigin="anonymous",c.onload=function(){if(e.imageBitmap)createImageBitmap(c).then(function(t){if(u[f]={type:o,img:t,ext:h,width:t.width,height:t.height,status:_.uc.LOADED},a(u[f],e),r.Mc[f])for(var i=0,n=r.Mc[f];i<n.length;i++){var s=n[i];s.cb(u[f],s.opts)}c.onload=null,c.onerror=null});else{if(u[f]={type:o,img:c,ext:h,width:c.width,height:c.height,status:_.uc.LOADED},a(u[f],e),r.Mc[f])for(var t=0,i=r.Mc[f];t<i.length;t++){var n=i[t];n.cb(u[f],n.opts)}c.onload=null,c.onerror=null}},c.onerror=function(){a(null,e),c.onload=null,c.onerror=null},t=Hn.getKeyUrl(t,i),c.src=t},qn.prototype.Sc=function(t){var i,n=(n=(t=void 0===t?{}:t).img)&&n.context?(i=n.width||0,n.height||0):(i=t.width||0,t.height||0);return[i,n]},qn);function qn(){this.Fs={},this.Cc=16,this.zc={},this.Mc={}}var Kn,Qn=0;function $n(t){var i=Kn.call(this,t=void 0===t?{}:t)||this;return i.CLASS_NAME="AMap.VectorLayer",i.zF="AMap.VectorLayer"+Qn++,i.pC=!1,i.Qh=t.zIndex||110,i}Kn=s,_.Ei($n,Kn),$n.prototype.add=function(t){for(var i=0,n=t=Array.isArray(t)?t:[t];i<n.length;i++){var s=n[i];this.source.add(s)}},$n.prototype.remove=function(t){for(var i=0,n=t=Array.isArray(t)?t:[t];i<n.length;i++){var s=n[i];this.source.remove(s)}},$n.prototype.getSourceConfig=function(){return{id:this.zF,type:"overlay",url:""}},$n.prototype.co=function(){return this.zF},$n.prototype.getState=function(){return{visible:this.il,opacity:1,rejectMapMask:this._rejectMapMask,depthTest:this.AF,ce:this.IF}},$n.prototype.vi=function(t){var i=this.source;if(i)return i.rr(t)||null},$n.prototype.getAllOverlays=function(i){return this.source.getAllOverlays().filter(function(t){return!i||-1<t.className.toLocaleLowerCase().indexOf(i)})},$n.prototype.destroy=function(){this.source&&this.source.destroy&&this.source.destroy(),this._container&&delete this._container},ts=$n,_.Ei(ns,ts),ns.prototype.has=function(t){return!!this.source&&-1<this.source.getAllOverlays().indexOf(t)},ns.prototype.clear=function(){var t;this.source&&(t=this.source.getAllOverlays(),this.remove(t.slice(0)))},ns.prototype.setOptions=function(t){if(this.source)for(var i=0,n=this.source.getAllOverlays();i<n.length;i++)n[i].setOptions(t)},ns.prototype.query=function(t){if(this.source)return this.source.rr({lnglat:t})},ns.prototype.getBounds=function(){if(this.source){var t=this.getAllOverlays();if(0<t.length){for(var i,n=void 0,s=0;s<t.length;s++)n?(i=t[s].getBounds())&&n.union(i):n=(n=t[s].getBounds())&&n.clone();return n}}};var ts,is=ns;function ns(){return null!==ts&&ts.apply(this,arguments)||this}var ss,es=!1,rs=(ss=_.Event,_.Ei(g,ss),g.prototype.va=function(t,n,i){var s,e=this,r=this.jD();return _.Support.LZ&&r.UD?(window.amap_sdk_log&&(s=t.url+"t="+t.ya.join(";"),window.amap_sdk_log("loadNebulaTile"+s+"-"+Date.now())),AMap.getConfig().vdataProxy&&(t.url=AMap.getConfig().vdataProxy+"/"+t.url.split("/")[3]+"/"+t.url.split("/")[4]),r.send("loadNebulaSourceTile",t,function(t,i){t&&e._map.emit("TileDecodeError",{type:"nebula",err:t}),i&&i.nebulaDatas&&(_.Support.amapRunTime&&(_.Support.amapRunTime.workerTime=i.amapRunTime),n(i.nebulaDatas))})):this.DZ.va(t,n)},g.prototype.RD=function(t,i){return AMap.getConfig().vdataProxy&&(t.url=AMap.getConfig().vdataProxy+"/"+t.url.split("/")[3]+"/"+t.url.split("/")[4]),this.Uh.send("loadNebulaSourceTileSdf",t,i)},g.prototype.loadDistrictSourceTile=function(t,i,n){t.request=this.Uh.send("loadDistrictSourceTile",i,function(t,i){i&&n(i)})},g.prototype.gX=function(t,i,n){t.request=this.Uh.send("loadMapboxVTSourceTile",i,function(t,i){i&&n(i)})},g.prototype.kX=function(t,i,n,s){t.request=this.Uh.send("reBufferMapboxVTSource",{MX:i,styles:n},function(t,i){i&&s(i)})},g.prototype.aG=function(t,i,n){var s=this;t.request=this.Uh.send("loadMapboxSourceTile",i,function(t,i){t&&s._map.emit("TileDecodeError",{type:"mapbox",err:t}),i&&n(i)})},g.prototype._C=function(t){this.Uh.send("processLabels",{id:t})},g.prototype.deleteTileStaticSDF=function(t){this.Uh.send("deleteTileStaticSDF",t)},g.prototype.Ha=function(i){this.Uh.send("updateParams",i),_.forEach(this.ED,function(t){t.send("updateParams",i)})},g.prototype.Ka=function(i){this.Uh.send("updateMapStyle",i),_.forEach(this.ED,function(t){t.send("updateMapStyle",i)})},g.prototype.bn=function(t,i){this.Uh.send("updateUserStyle",{Kd:t},i)},g.prototype.Ja=function(i){this.Uh.send("sendHttp",{protocol:i}),_.forEach(this.ED,function(t){t.send("sendHttp",{protocol:i})})},g.prototype.innerLabelsLoadData=function(t,i){this.Uh.send("innerLabelsLoadData",t,i)},g.prototype.signal=function(t,i){},g.prototype.dynamicTextSDFInfoLoaded=function(t,i){this.emit("dynamicTextSDFInfoLoaded",{data:i})},g.prototype.dynamicTextVerticeLoaded=function(t,i){this.emit("dynamicTextVerticeLoaded",i)},g.prototype.dynamicTextVerticeLoadedByTile=function(t,i){this.emit("dynamicTextVerticeLoadedByTile",i)},g.prototype.iconImageLoaded=function(t,i){this.emit("iconImageLoaded",i)},g.prototype.getSDFData=function(t,i){this.Uh.send("getSDFData",t,function(t){i&&i(t)})},g.prototype.loadWordsByFront=function(t,i,n){this.emit("loadWordsByFront",{mG:i,cb:n})},g.prototype.QB=function(t,i){this.jD().send("setPathWebgl",t,i)},g.prototype.JB=function(t,i){this.jD().send("sendIndoorRequest",t,i)},g.prototype.destroy=function(){this.jD().send("destroy","destroy"),this.Wh&&this.Wh.terminate();for(var t=0,i=this.HD;t<i.length;t++){var n=i[t];n&&n.terminate()}this.DZ&&delete this.DZ,this.Wh&&delete this.Wh},g.prototype.request=function(t,n,s){window.amap_sdk_log&&window.amap_sdk_log("data-request:"+n+"-"+Date.now());var e=new XMLHttpRequest;return e.onreadystatechange=function(){var t,i;4===e.readyState&&200===e.status&&(window.amap_sdk_log&&window.amap_sdk_log("data-loaded:"+n+"-"+Date.now()),t=e.getResponseHeader("content-type"),i=e.response,"application/x-protobuf"===t?s(null,i):es||(es=!0,console.log("<AMap JSAPI> KEY异常。")))},e.onerror=function(t){s("error")},e.open("GET",n,!0),e.responseType="arraybuffer",e.send(),{cancel:function(){e.abort()}}},g.prototype.jD=function(){var t=this.GD%this.ND;return this.GD=1+t,this.ED[t]},g.prototype.updateDataVersion=function(t,i){this.emit("updateDataVersion",{version:i})},g.prototype.tv=function(){var t=this;this._map.on("movestart",function(){t.iv=!0,t.ev()}),this._map.on("moveend",function(){t.iv=!1,t.ev()}),this._map.on("dragstart",function(){t._dragging=!0,t.ev()}),this._map.on("dragend",function(){t._dragging=!1,t.ev()}),this._map.on("zoomstart",function(){t.lt=!0,t.ev()}),this._map.on("zoomend",function(){t.lt=!1,t.ev()})},g.prototype.ev=function(){var i=!1;(this._dragging||this.lt||this.iv)&&(i=!0),this.nv!==i&&(this.Uh.send("setMainThreadBusy",i),_.forEach(this.ED,function(t){t.send("setMainThreadBusy",i)})),this.nv=i},g.prototype.WD=function(){for(var t=0;t<this.ND;t++)if(!this.ED[t].UD)return!1;return!0},g);function g(t){var i=ss.call(this)||this;if(i._map=t,i.dE=!1,i._dragging=!1,i.lt=!1,i.nv=!1,i.iv=!1,i.GD=0,i.ND=1,i.HD=[],i.ED=[],i.VD=[],i.ZD=[],i.YD=0,i.DZ=new hs(i),i.pE=function(){window.amap_sdk_log&&window.amap_sdk_log("initWorker:"+Date.now()),i.YD+=1,i.YD===i.ED.length+1&&(i.dE=!0,i._map.setNeedUpdate(!0))},window._PreLoadedWorker){var n=window._PreLoadedWorker,s=new _.Bh(n,i,"AMap.nebula");i.HD.push(n),i.ED.push(s),s.UD=!0,i.pE()}else{for(var e=0;e<i.ND;e++)n=new Worker(AMap.getConfig().workerUrl),s=new _.Bh(n,i,"AMap.nebula"),i.HD.push(n),i.ED.push(s);for(var r=0,h=i.ED;r<h.length;r++)!function(t){t.send("initCryptWorker",!0,function(){t.UD=!0,i.pE()})}(s=h[r])}return i.Wh=new Worker(AMap.getConfig().workerUrl),i.Uh=new _.Bh(i.Wh,i,"AMap.SDF"),i.Uh.send("initCryptWorker",!0,function(){i.Uh.UD=!0,i.pE()}),i.tv(),i}os.prototype.va=function(n,s){var e=this,r=(AMap.getConfig().vdataProxy&&(n.url=AMap.getConfig().vdataProxy+"/"+n.url.split("/")[3]+"/"+n.url.split("/")[4]),n.url+("?key="+AMap.getConfig().key+"&flds="+n.hH)+"&t="+n.ya.join(";")),h=(r=(r=r.replace("nebula/v3","nebula/v2")).replace("oversea/v3","oversea/v2"),r+="&p=3",window.amap_sdk_log&&window.amap_sdk_log("data-request:"+r+"-"+Date.now()),_.Support.amapRunTime&&!_.Support.amapRunTime.workerTime["data-request"]&&(_.Support.amapRunTime.workerTime["data-request"]=Date.now()),new _.vH),t=yi.Ajax(r,{responseType:"arraybuffer"},function(t,i){window.amap_sdk_log&&window.amap_sdk_log("data-loaded:"+r+"-"+Date.now()),_.Support.amapRunTime&&!_.Support.amapRunTime.workerTime["data-loaded"]&&(_.Support.amapRunTime.workerTime["data-loaded"]=Date.now()),"complete"===t&&(n.buffer=i.data,t=e.parent.jD().send("decodeNebulaSourceTile",n,function(t,i){t&&e.parent._map.emit("TileDecodeError",{type:"nebula",err:t}),i&&i.nebulaDatas&&(_.Support.amapRunTime&&!_.Support.amapRunTime.workerTime["data-decode-begin"]&&(_.Support.amapRunTime.workerTime["data-decode-begin"]=i.amapRunTime["data-decode-begin"]),_.Support.amapRunTime&&!_.Support.amapRunTime.workerTime["data-decode-end"]&&(_.Support.amapRunTime.workerTime["data-decode-end"]=i.amapRunTime["data-decode-end"]),_.Support.amapRunTime&&!_.Support.amapRunTime.workerTime["style-parse-begin"]&&(_.Support.amapRunTime.workerTime["style-parse-begin"]=i.amapRunTime["style-parse-begin"]),_.Support.amapRunTime&&!_.Support.amapRunTime.workerTime["style-parse-end"]&&(_.Support.amapRunTime.workerTime["style-parse-end"]=i.amapRunTime["data-decode-end"]),s(i.nebulaDatas))}),h._H(t))});return h._H({cancel:t.abort.bind(t)}),h},os.prototype.RD=function(n,s){var e=this,r=(t=(t=(t=n.url+("?key="+AMap.getConfig().key)+"&flds=poi,roadname&t="+n.ya.join(";")).replace("nebula/v3","nebula/v2")).replace("oversea/v3","oversea/v2"),t+="&p=3",new _.vH),t=yi.Ajax(t,{responseType:"arraybuffer"},function(t,i){"complete"===t&&(n.buffer=i.data,t=e.parent.Uh.send("decodeNebulaSourceTileSdf",n,function(t,i){s(t,i)}),r._H(t))});return r._H({cancel:t.abort.bind(t)}),r};var hs=os;function os(t){this.parent=t}us.prototype.ov=function(t){var i=t.gl;if(this.buffer||(this.buffer=new _.yp(t,new Uint16Array(0),8)),this.texture||(this.texture=t.createTexture({height:1024,width:1024,data:null},{Yi:!0}),this.texture.bind(i.CLAMP_TO_EDGE,i.NEAREST,i.LINEAR)),this.av||(this.av=t.createFramebuffer(1024,1024)),!this.Pc){for(var n=new Uint16Array(192),s=0;s<32;s++){var e=6*s,r=4*s;n[e]=r,n[1+e]=1+r,n[2+e]=2+r,n[3+e]=r,n[4+e]=2+r,n[5+e]=3+r}this.Pc=t.ve(n)}},us.prototype.sv=function(t){for(var i=0,n=t;i<n.length;i++){var s=n[i];this.rv[s.hv]=s.name,this.images[s.name]=s.img,this.lv.push(s.name),this.jG[s.name]={width:s.width,height:s.height}}},us.prototype.update=function(t){this.ov(t.context),this.uv(t,this.lv),this.lv=[]},us.prototype.uv=function(t,i){if(0!==i.length){for(var n=t.context,s=n.gl,e=0,r=i;e<r.length;e++){var h,o=r[e];this.De[o]||((h=n.createTexture(this.images[o],{Yi:!0})).bind(s.CLAMP_TO_EDGE,s.LINEAR,s.LINEAR),this.De[o]=h)}for(var a=[],u=0,c=this.rv.length;u<c;u++){var f=this.rv[u],d=void 0===(l=(f=this.jG[f]||{}).width)?512:l,v=void 0===(l=f.height)?1024:l,f=4*u*4,l=this.cv(u);a[f]=0,a[1+f]=0,a[2+f]=l[0],a[3+f]=l[1],a[4+f]=0,a[5+f]=v,a[6+f]=l[0],a[7+f]=l[1]+v,a[8+f]=d,a[9+f]=v,a[10+f]=l[0]+d,a[11+f]=l[1]+v,a[12+f]=d,a[13+f]=0,a[14+f]=l[0]+d,a[15+f]=l[1]}var p=n.fe(new Uint16Array(a),8),m=t.Hn(),y=(this.fv(),this.av.Wi.set(this.texture.texture),this.getSize()),i=(n.bindFramebuffer.set(this.av.framebuffer),n.be.current);for(n.be.set([0,0,y[0],y[1]]),u=0,c=this.rv.length;u<c;u++){var b=this.rv[u],g=this.jG[b]||{},M=g.width,d=void 0===M?512:M,v=void 0===(M=g.height)?1024:M;b&&m.Ce({u_sourceTexture:this.De[b],u_sourceTextureSize:[d,v],u_targetTextureSize:y},{a_sourceTexturePos:{buffer:p,type:"vec2",Re:8,offset:0},a_targetTexturePos:{buffer:p,type:"vec2",Re:8,offset:4}},6,this.Pc,void 0,void 0,void 0,void 0,void 0,6*u)}n.bindTexture.set(null),this.texture.bind(s.CLAMP_TO_EDGE,s.NEAREST,s.LINEAR),n.be.set(i),n.bindFramebuffer.set(null)}},us.prototype.getSize=function(){return[1024,1024*this.rv.length]},us.prototype.destroy=function(){this.buffer&&(this.buffer.destroy(),delete this.buffer),this.texture&&(this.texture.destroy(),delete this.texture);for(var t=0,i=this.De;t<i.length;t++)i[t].destroy();this.av&&(this.av.destroy(),delete this.av),this.Pc&&(this.Pc.context.deleteBuffer(this.Pc),delete this.Pc),this.images={},this.lv=[],this.rv=[],this.De={}},us.prototype.fv=function(){var t=this.getSize();this.texture.update({width:t[0],height:t[1],data:null},{resize:!0})},us.prototype.cv=function(t){return[0,1024*t]};var as=us;function us(){this.pv=0,this.lv=[],this.rv=[],this.images={},this.jG={},this.De={},this.dv=[256,256]}var cs,fs="labelsLayer",ds={visible:!0,zIndex:120,opacity:1,collision:!0,animation:!0,allowCollision:!1,zooms:_.zoomRange,VT:!1};function vs(t){var i=cs.call(this,t=void 0===t?{}:t)||this;return i.CLASS_NAME="AMap.LabelsLayer",i._opts={id:fs,type:fs,opacity:1,visible:1},i._opts=_.assign({},ds,t),i.xt=i._opts.zooms,i.Qh=void 0===t.zIndex?120:t.zIndex,i.il=void 0===t.visible||t.visible,i.tl=void 0===t.opacity?1:t.opacity,i}cs=s,_.Ei(vs,cs),vs.prototype.getSourceConfig=function(){return{id:this.hS,type:fs}},vs.prototype.getState=function(){return cs.prototype.getLayerConfig.call(this)},vs.prototype.co=function(){return this.hS},vs.prototype.vi=function(t){var i=this.fz;return(i=i&&i.vi(t,this.hS)||"")?this.getSource().Ds(i):null},vs.prototype.Do=function(t){return t=cs.prototype.Do.call(this,t),this.map&&this.uz(this.map),t},vs.prototype.v$=function(){this.fz&&this.fz.remove(this)},vs.prototype.destroy=function(){this.Jh&&this.Jh.destroy&&(this.Jh.destroy(),delete this.Jh)},vs.prototype.IL=function(t){var i=this.fz,n=this.source;return!!(t&&i&&n&&(i=i.$f||{},n=n.zL(t)))&&!!i[n]},vs.prototype.uz=function(t){(this.fz=t.fS()).add(this)},ps=vs,_.Ei(M,ps),M.prototype.getCollision=function(){return this._opts.collision},M.prototype.setCollision=function(t){this._opts.collision=t=void 0===t||t,this.to({vv:!1})},M.prototype.getAllowCollision=function(){return this._opts.allowCollision},M.prototype.setAllowCollision=function(t){this._opts.allowCollision=t=void 0===t||t,this.to({vv:!1})},M.prototype.getOpacity=function(){return this._opts.opacity},M.prototype.setOpacity=function(t){void 0!==t&&(this._opts.opacity=t,this.tl=t,this.to({vv:!0}))},M.prototype.getZooms=function(){return this._opts.zooms},M.prototype.setZooms=function(t){void 0!==t&&(this._opts.zooms=t,this.xt=t,this.to({vv:!0}))},M.prototype.getzIndex=function(){return this._opts.zIndex},M.prototype.setzIndex=function(t){void 0!==t&&(this._opts.zIndex=t,this.Qh=t,this.to({vv:!0}))},M.prototype.add=function(t){Array.isArray(t)||(t=[t]),this._add(t),(t=this.getSource())&&t.add(this.mv,this._opts,this.to.bind(this))},M.prototype.remove=function(t){Array.isArray(t)||(t=[t]),this._remove(t),(t=this.getSource())&&t.remove(this.mv,this._opts,this.to.bind(this))},M.prototype.clear=function(){this.mv={};var t=this.getSource();t&&(t.clear(),this.to({vv:!1}))},M.prototype.show=function(){ps.prototype.show.call(this)},M.prototype.hide=function(){ps.prototype.hide.call(this)},M.prototype.getAllOverlays=function(){var t,i,n=this.mv,s=[];for(t in n)n.hasOwnProperty(t)&&(i=n[t])&&s.push(i);return s},M.prototype.getState=function(){var t=this._opts;return{zIndex:this.Qh,zooms:this.xt,visible:this.il,opacity:this.tl,collision:t.collision,animation:t.animation,rejectMapMask:this._rejectMapMask,depthTest:this.AF,ce:this.IF}},M.prototype.setTop=function(t,i){var n=this.Kl;t&&(i?(n&&n.hS!==t.hS&&n.setTop(!1),this.Kl=t):this.Kl=null)},M.prototype.Kh=function(t){ps.prototype.Kh.call(this,t);var i=this.mv;Object.keys(i).length&&t.add(i,this._opts,this.to.bind(this,{vv:!1}))},M.prototype.to=function(t,i){var n=this,t=(t=void 0===t?{}:t).vv;this.map&&(void 0===t||t?(t=this.getSource())&&t.update(this._opts,function(){i&&(i(),AMap.Util.requestAnimFrame(function(){n.emit("complete")})),n.map&&n.map.setNeedUpdate(!0)}):this.map.setNeedUpdate(!0))},M.prototype.onAdd=function(){var t,i=this.mv;for(t in i)i.hasOwnProperty(t)&&i[t].Cs(this)},M.prototype.v$=function(){ps.prototype.v$.call(this);var t,i=this.mv;for(t in i)i.hasOwnProperty(t)&&i[t].Cs(null)},M.prototype._add=function(t){for(var i=0,n=t;i<n.length;i++){var s=n[i];(this.mv[s.hS]=s).Cs(this)}},M.prototype._remove=function(t){for(var i=0,n=t;i<n.length;i++){var s=n[i];delete this.mv[s.hS],s.Cs(null)}};var ps,ms=_.dZ([_.pZ("LabelsLayer")],M);function M(t){return(t=ps.call(this,t=void 0===t?{}:t)||this).mv={},t}bs.prototype.addImage=function(e,r){var h=this;this.getImage(e)?console.log("there is already a image named "+e):(this.zH.SH(e,function(t,i){r.cb&&r.cb(t,i)}),this.zH.has(e)||this.zH.nS(e,function(s){h.map.z_.loadImage(r.url,{name:e,type:"userImage",cb:function(t){var i,n;t&&t.img?(n=h.map.getContext())&&(t=n.createTexture(t.img,{Zi:!0}),i=r.filter?n.gl[r.filter]:n.gl.LINEAR,n=r.wrap?n.gl[r.wrap]:n.gl.CLAMP_TO_EDGE,t.bind(n,i,i),h.De[e]=t,s(null,t)):s(new Error("no img"))}})}))},bs.prototype.addImageBitmap=function(e,r){var h=this,o=r.url;this.getImage(o)?console.log("there is already a image named "+o):(this.zH.SH(o,function(t,i){r.cb&&r.cb(t,i)}),this.zH.has(o)||this.zH.nS(o,function(t){var i={img:e,startX:0,startY:0,status:_.uc.LOADED,height:e.height,width:e.width,type:"userImage"};h.map.z_.addImageData(o,i);var i=(n=h.map.getContext()).createTexture(i.img,{Zi:!0}),s=r.filter?n.gl[r.filter]:n.gl.LINEAR,n=r.wrap?n.gl[r.wrap]:n.gl.CLAMP_TO_EDGE;i.bind(n,s,s),t(null,h.De[o]=i)}))},bs.prototype.getImage=function(t){return this.De[t]},bs.prototype.RH=function(t){var i=this.De[t];i&&(delete this.De[t],i.destroy())},bs.prototype.MH=function(t){return this.zH.has(t)},bs.prototype.L_=function(){var t=w.create("canvas",null),i=(t.getContext||console.error("createArrowTexture error"),t.height=64,t.width=64,t.getContext("2d"));i?(i.fillStyle="white",i.beginPath(),i.moveTo(8,56),i.lineTo(32,36),i.lineTo(58,56),i.lineTo(58,36),i.lineTo(32,14),i.lineTo(8,36),i.fill(),(t=(i=this.map.getContext()).createTexture(t,{Zi:!0})).bind(i.gl.CLAMP_TO_EDGE,i.gl.LINEAR,i.gl.LINEAR),this.De.AMapArrow=t):console.error("createArrowTexture error")},bs.prototype.AH=function(){this.addImage("emptyTexture",{url:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"})};var ys=bs;function bs(t){this.map=t,this.De={},this.zH=new _.IH,this.L_(),this.AH()}gs=s,_.Ei(ks,gs),ks.prototype.getSourceConfig=function(){return{id:this._id,type:"sky"}},ks.prototype.destroy=function(){this._id&&(this._id="")},ks.prototype.co=function(){return this._id},ks.prototype.getState=function(){return{visible:this.il,opacity:1,skyColor:this.$C,layer:this,rejectMapMask:this._rejectMapMask,depthTest:this.AF,ce:this.IF}},ks.prototype.lo=function(){return!0};var gs,Ms=ks;function ks(t){var i=gs.call(this,t=void 0===t?{visible:!0}:t)||this;return i.CLASS_NAME="AMap.SkyLayer",i._id="sky_"+_.Util.uuid(),i.il=void 0===t.visible||t.visible,i.$C=t.skyColor,i.$C=i.$C&&_.Util.color2RgbaArray(i.$C),i.Qh=t.zIndex||500,i._rejectMapMask=!0,i}k.prototype.cS=function(t,i,n){for(var s=(this.wf=i).viewState,e=s.projectionId,r=s.viewMode,h=(s.zoom,this.If=_.V[e],this._viewMode=r,this.reset(),this.Of(),this._map),o={},a=0,u=this.Tw();a<u.length;a++){var c=u[a],f=c.getLayerConfig(),l=c._opts,d=c.hS,v=c.getRender();if(v){var p,m=n[d];if(m)for(var y in m)m.hasOwnProperty(y)&&(p=m[y],"AMap.Inner.LabelsLayer"===c.CLASS_NAME&&"other"===y||"AMap.LabelsLayer"===c.CLASS_NAME&&"tile"===y||p&&(y=v.Hz(t,i,this,p,h,f))&&(o[d]=y,(l.collision||l.allowCollision)&&(this.YL=!1),l.allowCollision)&&(this.UT=!1))}}this.Ps=o,e=(s=this._map.getMapState()).rotating,r=s.zooming,s=s.panning,r||s||this.reset(),this.YL&&this.UT&&(e||r||s)||this.Ff(),s=void 0===(r=(e=this.Ef()).Uf)?{}:r,r=e.$f,this.$f=void 0===r?{}:r,this.Uf=s},k.prototype.uS=function(){return this.LC},k.prototype.add=function(t){this.LC[t.hS]=t},k.prototype.remove=function(t){t&&delete this.LC[t.hS]},k.prototype.destroy=function(){this.LC&&(this.LC={}),this.Uf&&(this.Uf={},delete this.Uf),this.$f&&(this.$f={},delete this.$f)},k.prototype.vi=function(t,i,n){if((void 0===n&&(n=!1),this._map)&&((this._map.getStatus().pickWhenMoving||!this._map.TL())&&t&&this._p)){var s=this._map.getMapsContainer(),t=(s=w.mousePos(s,t,this._map))[0],s=s[1],e=this._p.search({ja:t-1,Fa:s-1,Oa:t+1,Ea:s+1});if(e.length){if(e=this.NL(e,i),(i=this.sP(e))&&i.path&&0<i.path.length&&(e=i.path,!this.ss([t,s],e)))return null;if(!i)return null;if(t=i.id,(s=this.DC(t))&&s.Nf&&(i=(e=s.Nf[t])&&e.data.extData||{},this.Uf[t])){if(n)return[i.Lp,i.Ap];if("poi"===i.type)return{type:i.type,id:i.id,lnglat:e.data.position,name:e.data.name};if(!i.type)return i.id}}}return null},k.prototype.search=function(t){for(var i=[],n=0,s=this._p.search(t);n<s.length;n++){var e,r=s[n],h=r.id;(e=this.FC(h))&&"AMap.Inner.LabelsLayer"===e.CLASS_NAME&&this.TC(h)&&i.push(r)}return i},k.prototype.reset=function(){this.Uf={},this.$f={}},k.prototype.tC=function(){return this._p},k.prototype.iC=function(t,i,n,s){var e=void 0===(e=(t=void 0===t?{}:t).x)?0:e,r=void 0===(r=t.y)?0:r,h=void 0===(h=t.width)?0:h,t=void 0===(t=t.height)?0:t,o=(i=void 0===i?{}:i).id,a=i.rank,u=i.padding,c=void 0===(c=i.type)?"":c,i=i.name,f=_.tc._d,u=u||f||0;return n&&0<n.length&&void 0!==s&&0!==s?(n=(f=this.Ddt(n[0],n[1],{ja:e-u,Fa:r-u,Oa:e+h+u,Ea:r+t+u},s))&&f.Ro||[],s=f&&f.path||[],{id:o,name:i,type:c,rank:a||1,ja:n[0],Fa:n[1],Oa:n[2],Ea:n[3],path:s}):{id:o,name:i,type:c,rank:a||1,ja:e-u,Fa:r-u,Oa:e+h+u,Ea:r+t+u}},k.prototype.NL=function(t,i){for(var n=[],s=0,e=t=void 0===t?[]:t;s<e.length;s++){var r,h=e[s];h.id&&(r=this.FC(h.id))&&r.hS===i&&n.push(h)}return n},k.prototype.sP=function(t){for(var i=this.Uf||{},n=[],s=0,e=t;s<e.length;s++){var r=e[s];i[r.id]&&n.push(r)}for(var h=-1/0,o=null,a=0,u=n;a<u.length;a++){var c=u[a],f=c.rank;h<f&&(h=f,o=c)}return o},k.prototype.Tw=function(){var t,i,n=this.LC,s=[];for(t in n)n.hasOwnProperty(t)&&(i=n[t],s.push(i));return s.sort(function(t,i){return i.Qh-t.Qh}),s},k.prototype.Rdt=function(t,i,n){var s=n.x,n=n.y,e=t[0],t=t[1],r=s+(e-s)*Math.cos(i*Math.PI/180)-(t-n)*Math.sin(i*Math.PI/180),e=n+(e-s)*Math.sin(i*Math.PI/180)+(t-n)*Math.cos(i*Math.PI/180);return[this.Pdt(r,2),this.Pdt(e,2)]},k.prototype.Pdt=function(t,i){return Math.round(t*Math.pow(10,i))/Math.pow(10,i)},k.prototype.ss=function(t,i,n){for(var s=t[0],e=t[1],r=!1,h=i.length,o=0,a=h-1;o<h;a=o,o+=1){var u=!1,c=i[o][0],f=i[o][1],l=i[a][0],d=i[a][1];if(c===s&&f===e||l===s&&d===e)return!!n;if(f<e==e<=d){if(s===(l=(l-c)*(e-f)/(d-f)+c))return!!n;u=s<l}u&&(r=!r)}return r},k.prototype.Ddt=function(t,i,n,s){var e,r,t={x:t,y:i};return void 0!==s&&0!==s?(i=[n.ja,n.Fa],s=this.Rdt(i,i=-s,t),e=[n.Oa,n.Fa],e=this.Rdt(e,i,t),r=[n.Oa,n.Ea],r=this.Rdt(r,i,t),n=[n.ja,n.Ea],s=[s,e,r,this.Rdt(n,i,t)],{Ro:Pt.Qa(s),path:s}):null},k.prototype.rd=function(t,i){var n=i.anchorOffset,s=(i=void 0===(i=i.size)?[0,0]:i)[0],i=i[1];return{x:(t=_.vector.add(t,n))[0],y:t[1],width:s,height:i}},k.prototype.hd=function(t,i,n,s){var e=i.offsetX,r=i.offsetY,h=i.w,i=i.h;return{x:t[0]+(void 0===e?0:e)*n,y:t[1]+(void 0===r?0:r)*n,width:(void 0===h?0:h)*n,height:(void 0===i?0:i)*n}},k.prototype.Ff=function(){var t=this.Ps,i=this.wf&&this.wf.viewState,n=this.ad,s=this.$f;if(i){var e,r={viewState:i,size:this.wf.size,transform:this.If,view:this._view,viewMode:this._viewMode,positionType:"relative"},h=i.zoom;for(e in t)if(t.hasOwnProperty(e)&&t[e]){var o=t[e],a=o.coords,u=o.style,c=o.Nf;if(o=this.LC[e]){var f,l,d,v,p,m,y,b,g,M,k=o.getRender().Jz(),w=k.Sa,x=o.Qh;for(f in a)a.hasOwnProperty(f)&&(g=(M=a[f]).origin,m=M.icon,M=M.padding,(l=u[f]).forceShow,this.TC(f)||(s[f]=1),s[f]||(d=(b=c[f]).data&&b.data.rotation||0,v=(y=b.data.extData||{}).Sa||w||[0,0],v=(g=_.vector.add(g,[v[0],v[1],0]))[0],p=g[1],g=g[2],r.centerCoord=k.centerCoord,v=_.LabelsRenderUtil.r0(v,p,g,h,r),p={id:f,rank:_.LabelsRenderUtil.getRank(b,{forceShow:l.forceShow,_z:x}),name:b.data.name,type:y.type||""},g=this.rd(v,m),y=this.PC(l)||_.zoomRange,m=_.Util.dS(h,y),l.showIcon&&m&&g.width&&g.height&&(y=this.iC(g,p,v,d),n.push(y)),m=1,b.data.extData.Lp&&b.data.extData.Ap&&(m=(g=this._map.mapStyle.dn(b.data.extData.Lp,b.data.extData.Ap,i.optimalZoom))&&l.text?g.fontSize/l.text.style.fontSize:1),y=this.hd(v,M,m),b=this.OC(l)||[2,20],g=_.Util.dS(h,b),l.showText&&g&&y.width&&y.height&&(M=this.iC(y,p,v,d),n.push(M))))}}this.ld(n)}},k.prototype.Ef=function(){var t={},i=this.$f;if(!this.wf)return{};var n=(this.wf&&this.wf.viewState).zoom,s=this.Ps,e={};if(this.YL){for(var r in s)if(s.hasOwnProperty(r)&&s[r]){var h,o=s[r],a=o.Nf,u=void 0===a?{}:a;for(h in o.coords,o.style,u)u.hasOwnProperty(h)&&(t[h]=1)}}else{for(var r in s)if(s.hasOwnProperty(r)&&s[r]){var c,f,l=s[r],d=l.Nf,v=void 0===d?{}:d;l.coords;var j=void 0===(d=l.style)?{}:d,B=(w=this.LC[r]).Qh;for(c in v)v.hasOwnProperty(c)&&(f=j[c],e[f=_.LabelsRenderUtil.getRank(v[c],{forceShow:f.forceShow,_z:B})]||(e[f]={}),e[f][c]=v[c])}for(var p,m=_.labelsUtil.rank(Object.keys(e)),W=m.length,y=this.wf,b={viewState:y.viewState,size:y.size,transform:this.If,view:this._view,viewMode:this._viewMode,positionType:"relative"},g=W-1;0<=g;g--)for(var M,F=e[m[g]],k=(M=Object.keys(F)).length-1;0<=k;k--){var w,x=M[k];if(!i[x]&&(w=this.FC(x)))if(!(A=w._opts||{}).collision&&this.UT||A.VT)t[x]=1;else{var A,z=(A=w.getRender().Jz()).Sa,C=(E=this.DC(x)).style,S=E.coords;if((E=E.Nf)[x].data&&E[x].data.rotation,(C=C[x])&&C.forceShow)t[x]=1;else{if(O=(S=S[x]).icon||{},p=S.padding||{},S=S.origin||{},z=((E=E[x]).data.extData||{}).Sa||z||[0,0],z=(S=_.vector.add(S,[z[0],z[1],0]))[0],L=S[1],S=S[2],b.centerCoord=A.centerCoord,A=_.LabelsRenderUtil.r0(z,L,S,n,b),(z=O.size)[0]&&z[1])for(var T,L=this.rd(A,O),S=this.iC(L),G=(T=this._p.search(S)).length,I=0;I<G;I++){var D=T[I];D.id===x?t[D.id]=1:this.BC(x,D.id)&&(i[D.id]=1)}var z=this.wf&&this.wf.viewState,O=1;if(E.data.extData.Lp&&E.data.extData.Ap&&(O=(L=this._map.mapStyle.dn(E.data.extData.Lp,E.data.extData.Ap,z.optimalZoom))&&C.text?L.fontSize/C.text.style.fontSize:1),(S=this.hd(A,p,O)).width&&S.height)for(var R,E=this.iC(S),N=(R=this._p.search(E)).length,I=0;I<N;I++){var P=R[I];P.id===x?t[P.id]=1:this.BC(x,P.id)&&(i[P.id]=1)}}}}}return{Uf:t,$f:i}},k.prototype.ld=function(t){this._p&&(this._p.clear(),this._p.load(t))},k.prototype.Of=function(){this._p&&(this._p.clear(),this.ad=[])},k.prototype.DC=function(t){var i,n,s=this.Ps;for(n in s)if(s.hasOwnProperty(n)){var e=s[n];if(e&&e.Nf&&e.Nf[t]){i=e;break}}return i||{}},k.prototype.jC=function(t){var i,n=this.Ps,s="";for(i in n)if(n.hasOwnProperty(i)){var e=n[i]||{};if(e.Nf&&e.Nf[t]){s=i;break}}return s},k.prototype.FC=function(t){return(t=this.jC(t))?this.LC[t]:null},k.prototype.TC=function(t){var i=this.DC(t),n=this._map.qz(),s=this._map.getLayerByClass("AMap.MaskLayer"),e=this._map.jH();if(i){var r=i.Nf;if(!(i=i.style[t]))return!1;var h=r[t].data.extData||{};if("poi"===h.type&&!1===n)return!1;if(!i.visible)return!1;if(n=this.EC(i),i=this.wf.viewState.zoom,!_.Util.dS(i,n))return!1;if(i=this._map.getLayerByClass("AMap.IndoorMap"),r[t]&&h.bz&&i&&i.yD().show)return!1;if(s){if(n=s.getRender(),e)return!0;if(n&&!n.EH(r[t].data.position,this.wf))return!1}return!0}return!1},k.prototype.BC=function(t,i,n){if(void 0===n&&(n=!1),s=this.DC(i)){var s=s.style,e=(t=this.FC(t))&&t._opts||{},r=this.FC(i),h=r&&r._opts||{};if(s[i].forceShow)return n&&console.log(""," -1- ",1),!1;if(t&&r){if(t.hS!==r.hS&&!e.allowCollision&&!h.allowCollision)return n&&console.log(""," -2- ",1),!1;if(t.hS===r.hS&&!h.collision)return n&&console.log(""," -3- ",1),!1}}return n&&console.log(""," -4- ",1),!0},k.prototype.EC=function(t){var n=(i=this.PC(t)||[])[0],i=i[1],s=(t=this.OC(t)||[])[0],t=t[1];return[n&&s?n<=s?n:s:n||s||2,n&&s?i<=t?t:i:i||t||_.zoomRange[1]]},k.prototype.PC=function(t){return t.icon&&t.icon[0]&&t.icon[0].zooms},k.prototype.OC=function(t){return t.text&&t.text.zooms};var ws=_.dZ([_.pZ("LabelsManager")],k);function k(t){this.LC={},this.Uf={},this.$f={},this.Ps={},this._p=_.rbush(),this.ad=[],this._viewMode="2D",this.YL=!0,this.UT=!0,this._map=t,this._view=t.getView()}xs=s,_.Ei(zs,xs),zs.prototype.getState=function(){return{visible:this.il,opacity:this.tl,zIndex:this.Qh,layer:this,path:this.$x,depthTest:this.AF,ce:this.IF}},zs.prototype.setMask=function(t){t&&(this.$x=t,this.getSource().CS(),null!=(t=this.map))&&t.setNeedUpdate(!1)},zs.prototype.getSourceConfig=function(){return{id:this._id,type:"mask",zooms:_.zoomRange}},zs.prototype.co=function(){return this._id},zs.prototype.lo=function(){return!0};var xs,As=zs;function zs(t){var i=xs.call(this,t)||this;return i.CLASS_NAME="AMap.MaskLayer",i.$x=t.path,i.Qh=t.zIndex||-100,i.tl=void 0===t.opacity?1:t.opacity,i.il=void 0===t.visible||t.visible,i.xt=t.zooms||_.zoomRange,i}var Cs,Ss="Nebula.labelsLayer",Ls="nebulaLabel",Is=(Cs=s,_.Ei(Ds,Cs),Ds.prototype.getState=function(){return _.assign({},{layer:this,rejectMapMask:this._rejectMapMask},Cs.prototype.getLayerConfig.call(this))},Ds.prototype.getSourceConfig=function(){var t=AMap.getConfig().protocol;return{id:Ls,type:Ls,tileUrl:t+(_.Support.wasm?"://{vdata,vdata01,vdata02,vdata03,vdata04}.amap.com/nebula/v3":"://{vdata,vdata01,vdata02,vdata03,vdata04}.amap.com/nebula/v2"),tileSize:0,zooms:_.zoomRange}},Ds.prototype.co=function(){return Ls},Ds.prototype.vi=function(t){return null},Ds.prototype.destroy=function(){this.Jh&&this.Jh.destroy&&(this.Jh.destroy(),delete this.Jh)},Ds.prototype.Do=function(t){return Cs.prototype.Do.call(this,t)},Ds);function Ds(t){var i=Cs.call(this,t=void 0===t?{}:t)||this;return i.CLASS_NAME="AMap.Nebula.LabelsLayer",i._opts={id:Ss,type:Ss,opacity:1,visible:1,collision:!0,allowCollision:!1},i._opts=_.assign({},i._opts,t),i.Qh=t.labelzIndex||100,i.il=!1!==t.showLabel,i.tl=void 0===t.opacity?1:t.opacity,i}Rs.prototype.qk=function(t){return t=Object.keys(t),this.Uk+t.length<this.uf},Rs.prototype.getSize=function(){return[this.maxWidth,this.Uk/this.Hk*this.unit]},Rs.prototype.clear=function(){},Rs.prototype.destroy=function(){},Rs.prototype.Rk=function(t){var i=this.Vk,n=this.$k,s=t[_.dY.iconWidth],t=t[_.dY.iconHeight];return this.pY<t&&(this.pY=t),i+s<=this.maxWidth||(this.$k+=this.pY,n=this.$k,this.Vk=i=0,this.pY=t),this.Vk+=s,this.nU=[i,n],{startX:i,startY:n}};var Os=Rs;function Rs(){this.Uk=0,this.unit=32,this.Hk=128,this.maxWidth=this.unit*this.Hk,this.maxHeight=this.unit*this.Hk,this.uf=this.maxWidth/this.unit*(this.maxHeight/this.unit),this.Kv=!1,this.Vk=0,this.$k=0,this.pY=0,this.nU=[0,0],this.Es={};var t=document.createElement("canvas");t.width=this.maxWidth,t.height=this.maxHeight,this.mY=t,this.Nz=t.getContext("2d")}Ps.prototype.play=function(t){for(var i=t,n=Date.now();0<i&&this.offset!==this.mG.length;){var s=this.mG[this.offset],e=this.bY.Rk(s.info),r=s.info[_.dY.iconWidth],h=s.info[_.dY.iconHeight];0<r&&0<h&&this.bY.Nz.putImageData(function(t,i,n,s){for(var e=(t=t.createImageData(n,s)).data,r=0;r<i.length;r++)e[4*r+0]=i[r],e[4*r+1]=i[r],e[4*r+2]=i[r],e[4*r+3]=255;return t}(this.bY.Nz,s.data,s.info[_.dY.iconWidth],s.info[_.dY.iconHeight]),e.startX,e.startY),s.pos=e,delete s.data,this.result.push(s),this.offset++,i=t-(Date.now()-n)}return this.offset===this.mG.length&&(this.bY.Kv=!0),this.result},Object.defineProperty(Ps.prototype,"status",{get:function(){return this.offset>=this.mG.length?_.vY.finish:_.vY.pause},eb:!1,nb:!0});var Es=Ps;function Ps(t,i){this.bY=t,this.mG=i,this.type="SDFCombineTask",this.offset=0,this.result=[]}Bs.prototype.dynamicTextSDFInfoLoaded=function(t){var i=this.map.R_;i&&"SDFManagerBase"!==i.CLASS_NAME&&(i.Ju(t.data),this.Eo())},Bs.prototype.iconImageLoaded=function(t){for(var i=this,t=t.data,e=[],n=0,s=t;n<s.length;n++)!function(n){n.url;var s=n.data;e.push(new Promise(function(t){var i=new Image;i.src=n.data.data.data,i.onload=function(){t({img:i,name:n.data.data.hash,hv:n.data.ext.hv,width:s.width,height:s.height})}}))}(s[n]);Promise.all(e).then(function(t){i.map.so.sv(t)}),this.Eo()},Bs.prototype.updateDataVersion=function(t){this.map.UH(t.version)},Bs.prototype.destroy=function(){this.$$()},Bs.prototype.Ia=function(){this.map.gn.on("dynamicTextSDFInfoLoaded",this.dynamicTextSDFInfoLoaded.bind(this)),this.map.gn.on("iconImageLoaded",this.iconImageLoaded.bind(this)),this.map.gn.on("updateDataVersion",this.updateDataVersion.bind(this))},Bs.prototype.$$=function(){this.map.gn.clearEvents("dynamicTextSDFInfoLoaded"),this.map.gn.clearEvents("commonWordLoaded"),this.map.gn.clearEvents("iconImageLoaded"),this.map.gn.clearEvents("updateDataVersion")},Bs.prototype.Eo=function(){this.map.setNeedUpdate(!0)};var js=Bs;function Bs(t){this.map=t,this.Ia()}Fs.prototype.CS=function(){this.AS=!1},Fs.prototype.getData=function(){var t,r,e,h,i,o,a,u=this,n=this.$E;return this.AS||!n||(t=_.GeometryUtil.typePolygon(n),r={type:"Polygon",$S:new Array,polygons:new Array,BM:new Array,LS:{x:0,y:0}},t&&"Polygon"===t?(n[0][0]instanceof _.LngLat?r.LS=_.lcs.getLocalByLnglat(n[0][0].toString()):r.LS=_.lcs.getLocalByLnglat(n[0][0]),e=(i=r.LS).x,h=i.y,_.forEach(n,function(t,i){var s;0===i?_.forEach(t,function(t){t instanceof _.LngLat&&(t=t.toArray());var t=_.lcs.getLocalByLnglat(t),n=(i=u.DS(e,h,t.x,t.y))[0],i=i[1];r.$S.push(t.Sa[0]+n,t.Sa[1]+i)}):(s=[],_.forEach(t,function(t){t instanceof _.LngLat&&(t=t.toArray());var t=_.lcs.getLocalByLnglat(t),n=(i=u.DS(e,h,t.x,t.y))[0],i=i[1];s.push(t.Sa[0]+n,t.Sa[1]+i)}),r.BM.push(s))})):t&&"MultiPolygon"===t&&(r.type="MultiPolygon",n[0][0][0]instanceof _.LngLat?r.LS=_.lcs.getLocalByLnglat(n[0][0][0].toArray()):r.LS=_.lcs.getLocalByLnglat(n[0][0][0]),o=(i=r.LS).x,a=i.y,_.forEach(n,function(t){var e=[],n=[];_.forEach(t,function(t,i){var s;0===i?_.forEach(t,function(t){t instanceof _.LngLat&&(t=t.toArray());var t=_.lcs.getLocalByLnglat(t),n=(i=u.DS(o,a,t.x,t.y))[0],i=i[1];e.push(t.Sa[0]+n,t.Sa[1]+i)}):(s=[],_.forEach(t,function(t){t instanceof _.LngLat&&(t=t.toArray());var t=_.lcs.getLocalByLnglat(t),n=(i=u.DS(o,a,t.x,t.y))[0],i=i[1];s.push(t.Sa[0]+n,t.Sa[1]+i)}),n.push(s))}),r.BM.push(n),r.polygons.push(e)})),this.AS=this.zw(r),this.AS)},Fs.prototype.DS=function(t,i,n,s){return n-=t,t=s-i,[n*(s=_.lcs.getSize())[0],t*s[1]]},Fs.prototype.zw=function(t){if(t.Oc=new _._w,!t.Dc){t.Dc=new _.K_;var i=[],n=[];"Polygon"===t.type?(i=[t.$S],n=[t.BM]):"MultiPolygon"===t.type&&(i=t.polygons,n=t.BM);for(var s=0;s<i.length;s++){for(var e=i[s],r=[],h=0;h<n[s].length;h++){var o=n[s][h];r.push(e.length/2),e.push.apply(e,o)}var a=t.Dc.Nx(e,r);0<a&&t.Oc.add(99,99,a,_.zoomRange[0],_.zoomRange[1])}return t}},Fs.prototype.EE=function(t){if(!t)return null;for(var i=[],n=t.length,s=0;s<n;s++){var e=t[s],e=[(e=this.map.pixelToLngLat(e,16)).lng,e.lat];i.push(e)}return[i]};var Ws=Fs;function Fs(t,i,n){this.map=i,this.$E=t}Ns.prototype.destroy=function(){for(var t=0,i=this.MZ;t<i.length;t++){var n=i[t];"function"==typeof n.destroy&&n.destroy.call(n)}};var Gs=Ns;function Ns(t){this.MZ=t,this.dynamic=new Us}_s=_.Event,_.Ei(Ys,_s),Ys.prototype.has=function(t){return this.gV.has(t)},Ys.prototype.set=function(t,i,n){(n=void 0===n||n)?(n=this.gV.get(t),this.gV.set(t,i),n!==i&&this.emit(t,i)):this.gV.set(t,i)},Ys.prototype.get=function(t){return this.gV.get(t)},Ys.prototype.subscribe=function(t,i,n,s){var e=this;return this.on(t,i,n,s=void 0!==s&&s),function(){return e.off(t,i,n)}};var _s,Us=Ys;function Ys(){var t=null!==_s&&_s.apply(this,arguments)||this;return t.gV=new _.OZ,t}function Zs(t){var i=this,t=(this.map=t,this.gZ=function(){return i.stencil.getData()},t.getOutseaDataType()),t=_.vZ(t).boundsP16;this.stencil=new Ws(t,this.map)}Js.prototype.update=function(t){var i=this;void 0===t?this.PZ.forEach(function(t){i.jZ(t)}):(t=this.WZ(t))&&this.jZ(t)},Js.prototype.add=function(t){if(this.PZ.has(t.group)){var i=this.PZ.get(t.group);if(null==i||!i.includes(t))return null!=(i=this.PZ.get(t.group))&&i.push(t),!0}return!1},Js.prototype.remove=function(t){if(this.PZ.has(t.group)){var i=null==(i=this.PZ.get(t.group))?void 0:i.indexOf(t);if(-1!==i)return null!=(t=this.PZ.get(t.group))&&t.splice(i,1),!0}return!1},Js.prototype.BZ=function(t){var i=0;return void 0===t?this.PZ.forEach(function(t){i+=t.length}):i+=null!=(t=null==(t=this.WZ(t))?void 0:t.length)?t:0,i},Js.prototype.RZ=function(t,i,n){if(void 0===n&&(n=1),!this.WZ(t)||this.BZ(t)<=0)return!1;for(var s=0;s<n&&0<this.BZ(t);s++){var e=this.GZ(t,!0);void 0!==e&&(!i||null!=i&&i(e)?e.NZ():this.add(e))}return!0},Js.prototype.GZ=function(t,i){var n,s;return void 0===i&&(i=!1),this.WZ(t)&&(s=null==(s=this.WZ(t))?void 0:s.pop(),i)&&s&&null!=(n=s.UZ)&&n.call(s)?this.GZ(t,i):s},Js.prototype.sort=function(t,i){return i.FZ()-t.FZ()},Js.prototype.WZ=function(t){return this.PZ.get(t)},Js.prototype.jZ=function(t){for(var i,n=0;n<t.length;n++){var s=t[n];null!=(i=null==s?void 0:s.UZ)&&i.call(s)&&(t.splice(n,1),n--)}t.sort(this.sort)},Js.prototype.destroy=function(){this.PZ.clear()};var Xs=Js;function Js(t){var i=this;this.PZ=new _.OZ,this.ZZ=t,null!=(t=this.ZZ.Fz)&&t.forEach(function(t){i.PZ.set(t,[])}),this.ZZ._Z&&(this.sort=this.ZZ._Z)}var Hs={rainbow:{HY:["#96005A","#0000C8","#0019FF","#0098FF","#2CFF96","#97FF00","#FFEA00","#FF6F00","#FF0000"],JY:[0,.125,.25,.375,.5,.625,.75,.875,1]},jet:{HY:["#000083","#003CAA","#05FFFF","#FFFF00","#FA0000","#800000"],JY:[0,.125,.375,.625,.875,1]},hsv:{HY:["#ff0000","#fdff02","#f7ff02","#00fc04","#00fc0a","#01f9ff","#0200fd","#0800fd","#ff00fb","#ff00f5","#ff0006"],JY:[0,.169,.173,.337,.341,.506,.671,.675,.839,.843,1]},hot:{HY:["#000000","#e60000","#ffd200","#ffffff"],JY:[0,.3,.6,1]},greys:{HY:["#000000","#ffffff"],JY:[0,1]},greens:{HY:["#00441b","#006d2c","#238b45","#41ab5d","#74c476","#a1d99b","#c7e9c0","#e5f5e0","#f7fcf5"],JY:[0,.125,.25,.375,.5,.625,.75,.875,1]},ylgnbu:{HY:["#081d58","#253494","#225ea8","#1d91c0","#41b6c4","#7fcdbb","#c7e9b4","#edf8d9","#ffffd9"],JY:[1,.875,.75,.625,.5,.375,.25,.125,0]},ylorrd:{HY:["#800026","#bd0026","#e31a1c","#fc4e2a","#fd8d3c","#feb24c","#fed976","#ffeda0","#ffffcc"],JY:[1,.875,.75,.625,.5,.375,.25,.125,0]}},Vs=(qs.getTexture=function(t,i){var n;return this.cache[i]||(Hs[i]&&(n=function(t){t.JY,t.HY;for(var i=document.createElement("canvas"),n=(i.height=1,i.width=256,i.getContext("2d")),s=n.createLinearGradient(0,0,256,1),e=0;e<t.JY.length;e++){var r=t.JY[e],h=t.HY[e];s.addColorStop(r,h)}return n.fillStyle=s,n.fillRect(0,0,256,1),i}(Hs[i]),n=t.createTexture(n,{Zi:!0}),t=t.gl,n.bind(t.CLAMP_TO_EDGE,t.NEAREST,t.NEAREST_MIPMAP_NEAREST),this.cache[i]=n),null)},qs.cache={},_.dZ([_.pZ("ColorScale")],qs));function qs(){}Qs.oX=function(t){var i=document.createElement("canvas"),n=(i.width=256,i.height=256,i.getContext("2d"));if(n){n.beginPath();for(var s="rgba("+t[0]+","+t[1]+","+t[2]+","+t[3]/255+")",e=0;e<9;e++){n.lineWidth=1,n.strokeStyle=s;var r=256*e/8;8===e?(n.moveTo(.5,r-.5),n.lineTo(255.5,r-.5),n.moveTo(r-.5,.5),n.lineTo(r-.5,255.5)):(n.moveTo(.5,.5+r),n.lineTo(255.5,.5+r),n.moveTo(.5+r,.5),n.lineTo(.5+r,255.5))}return n.stroke(),"url("+i.toDataURL("image/png")+")"}},Qs.hX=function(t,i){var n=t.toLowerCase();if(n&&/^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/.test(n)){if(4===n.length){for(var s="#",e=1;e<4;e+=1)s+=n.slice(e,e+1).concat(n.slice(e,e+1));n=s}for(var r=[],e=1;e<7;e+=2)r.push(parseInt("0x"+n.slice(e,e+2),10));return i&&(t=parseFloat((parseInt(i,16)/255).toFixed(2)),r.push(t)),"RGB("+r.join(",")+")"}return n};var Ks=Qs;function Qs(){}new _.rW({}),te.addLayerRender=function(t,i,n){i&&(this.YZ[t]=i),n&&(this.JZ[t]=n),this.XZ(!0)},te.XZ=function(t){this.HZ=t},te.VZ=function(){return this.HZ},te.HZ=!0,te.YZ={},te.JZ={};var $s=_.dZ([_.pZ("LayerRenderManager")],te);function te(){}ie=_.Event,_.Ei(x,ie),x.prototype.TL=function(){return!window.movingDraw&&(this.gm||this.Lv||this.lt||this.Cv)},x.prototype.getContext=function(){var t;return null==(t=this.mm)?void 0:t.context},x.prototype.getGL=function(){return this.gl},x.prototype.getView=function(){return this._view},x.prototype.loadData=function(){return this.IY},x.prototype.wX=function(){return{hardwareAccEnabled:_.Support.hardwareAccEnabled}},x.prototype.getContainer=function(){return this.kv},x.prototype.getSize=function(){var t=this._view.getStatus().size;return new _.Size(t[0],t[1])},x.prototype.addLayer=function(t){var i,n,s;"d"===_.Support.baseRender&&/^(AMap\.DistrictLayer)|(AMap\.MapboxLayer)$/g.test(t.CLASS_NAME)?console.log("浏览器版本过低,请升级最新版本的浏览器,或使用高版本火狐、谷歌等浏览器。"):(t.map=this,i=t.getSourceConfig(),n=this.Mv.addSource(i,this._view.au(),t),t.Hh(this.Mv),t.Kh(n),s=this.Rv(t,{}),t.Do(s),this.zv.push(t),this.zv.sort(function(t,i){return t.getOptions().zIndex-i.getOptions().zIndex}),"AMap.NebulaLayer"!==t.CLASS_NAME&&"AMap.TileLayer.RoadNet"!==t.CLASS_NAME||!1===this.showLabel||"w"!==this.baseRender||this.getLayerByClass("AMap.Nebula.LabelsLayer")||(s=new Is(_.Ln(_.Ln({},this.options),{rejectMapMask:!0})),this.addLayer(s)),"AMap.Nebula.LabelsLayer"!==t.CLASS_NAME&&"AMap.MapboxLayer"!==t.CLASS_NAME||!1===this.showLabel||"w"!==this.baseRender||((s=this.getLayerByClass("AMap.Inner.LabelsLayer"))?s.oP()&&s.show():(s=new $i(_.Ln(_.Ln({},this.options),{rejectMapMask:!0})),this.addLayer(s)),s.getSource().addSource(i.id,n)),"AMap.NebulaLayer"===t.CLASS_NAME&&this.yS()&&!_.some(this.zv,function(t){return"AMap.Buildings"===t.CLASS_NAME})&&this.addLayer(new AMap.Buildings({zooms:[16.8,_.zoomRange[1]],rejectMapMask:!0,zIndex:10,visible:!0,u$:!0})),!this.c$||_.some(this.zv,function(t){return"AMap.MaskLayer"===t.CLASS_NAME})||this.d$||(this.d$=new As({zIndex:-10,visible:!0,path:this.c$}),this.addLayer(this.d$)),"3D"!==this.getView().type||_.some(this.zv,function(t){return"AMap.SkyLayer"===t.CLASS_NAME})||this.addLayer(new Ms({zIndex:-1,visible:!0,skyColor:this.$C})),t.onAdd&&t.onAdd(),this.d_(),this.setNeedUpdate(!0))},x.prototype.removeLayer=function(t){for(var i,n=0;n<this.zv.length;n++)this.zv[n]===t&&(this.zv.splice(n,1),t.v$&&(t.v$(),"d"===_.Support.baseRender)&&null!=(i=t.getRender())&&i.destroy(),t.map=null,--n);this.d_(),this.setNeedUpdate(!0)},x.prototype.setLayers=function(t){for(var i=0;i<this.zv.length;i++)"AMap.VectorLayer"!==(n=this.zv[i]).CLASS_NAME&&this.removeLayer(n);for(var n,i=0;i<t.length;i++)(n=t[i]).setMap(this)},x.prototype.getLayers=function(){return this.zv.filter(function(t){return!t._opts||!t._opts.TF})},x.prototype.DF=function(){return this.zv},x.prototype.getDefaultLayer=function(){for(var t=this.getLayers(),i=0;i<t.length;i++){var n=t[i];if(n instanceof Ji||"_defaultLayer"===n.getLayerConfig().id)return n}},x.prototype.getLayerByClass=function(t){for(var i=this.getLayers(),n=0;n<i.length;n++){var s=i[n];if(s.CLASS_NAME===t)return s}},x.prototype.isDOMRender=function(){return!_.Support.isWebGL||"d"===this.baseRender},x.prototype.isDOMMode=function(){return!_.Support.isWebGL||"d"===this.baseRender},x.prototype.getMapState=function(){return{zooming:this.lt,panning:this.Cv,rotating:this.Lv,pitching:this.gm}},x.prototype.getControlContainer=function(){return this.Tv},x.prototype.getMapsContainer=function(){return this.Iv},x.prototype.getStatus=function(){return{dragEnable:this.Dv,zoomEnable:this.Pv,doubleClickZoom:this.fi,keyboardEnable:this.jv,jogEnable:this.Ov,scrollWheel:this.Fv,zoomSpeed:this.fZ,animateEnable:this.Ev,touchZoomCenter:this.Nv,touchZoom:this.$v,pitchEnable:this.Uv,rotateEnable:this.Bv,showBuildingBlock:this.m$,isHotspot:this.Wv,mapstyleUrl:this.c_,features:this.Cw,allBubble:this.HL,pickWhenMoving:this.UB}},x.prototype.setStatus=function(t){this.Dv=void 0!==t.dragEnable?t.dragEnable:this.Dv,this.Pv=void 0!==t.zoomEnable?t.zoomEnable:this.Pv,this.fi=void 0!==t.doubleClickZoom?t.doubleClickZoom:this.fi,this.jv=void 0!==t.keyboardEnable?t.keyboardEnable:this.jv,this.Ov=void 0!==t.jogEnable?t.jogEnable:this.Ov,this.Fv=void 0!==t.scrollWheel?t.scrollWheel:this.Fv,this.Ev=void 0===t.animateEnable?this.Ev:t.animateEnable,this.Uv=void 0===t.pitchEnable?this.Uv:t.pitchEnable,this.$v=void 0===t.touchZoom?this.$v:t.touchZoom,this.Wv=void 0===t.isHotspot?this.Wv:t.isHotspot,this.Bv=void 0===t.rotateEnable?this.Bv:t.rotateEnable,this.HL=void 0===t.allBubble?this.HL:t.allBubble},x.prototype.getBuildingColor=function(){return{buildingColor:this.az,roofColor:this.rz,wallColor:this.sz}},x.prototype.getMask=function(){return this.c$},x.prototype.getOutseaState=function(){return this.YG},x.prototype.getOutseaDataType=function(){return this.QZ},x.prototype.getMapboxStyle=function(){return this.JG},x.prototype._setStyle=function(t){this.mapStyle.setStyle(t,!1,this)},x.prototype.RY=function(t){"d"!==this.baseRender&&(this.mapStyle.setStyleByPlat(t,this),this.u0(t))},x.prototype.f_=function(t){var i=this;if(!t)return!1;"d"!==this.baseRender?(this.c_=t,this.mapStyle.pn(function(){i._getUserStyle(t),i.d_(),i.setNeedUpdate(!0)})):console.log("浏览器版本过低,请升级最新版本的浏览器,或使用高版本火狐、谷歌等浏览器。")},x.prototype.getProjection=function(){return _.ProjectionManager.getProjection(this._view.au())},x.prototype.getDefaultCursor=function(){return this.Zv},x.prototype.setDefaultCursor=function(t){this.Zv=t,this.setCursor()},x.prototype.setCursor=function(t){this.kv&&(t=t||this.getDefaultCursor())!==this.qv&&(_.Support.$e||(this.kv.style.cursor=t),this.qv=t)},x.prototype.destroy=function(){this.G("beforeDestroy"),this.y$=!0,this.bZ&&(this.bZ.destroy(),delete this.bZ),this.x$&&(this.x$.destroy(),delete this.x$),this.gn&&(this.gn.destroy(),delete this.gn),this.mapStyle&&this.mapStyle.destroy&&(this.mapStyle.destroy(),delete this.mapStyle),this.b$&&this.b$.destroy&&(this.b$.destroy(),delete this.b$),this.$F&&this.$F.destroy&&(this.$F.destroy(),delete this.$F),this.wm&&delete this.wm,this.z_&&this.z_.destory&&(this.z_.destory(),delete this.z_),this._view&&delete this._view,this.I_&&delete this.I_,this.yH&&delete this.yH,this.m_&&delete this.m_,this.gl&&delete this.gl,this.canvas&&delete this.canvas,this.lcs&&(this.lcs=null),this.Vv(),this.Xv(),this.Hv(),this.G("afterDestroy")},x.prototype.getLimitBounds=function(){return this.it},x.prototype.setLimitBounds=function(t){t instanceof l?this.it=t:this.it=new l(t)},x.prototype.clearLimitBounds=function(){this.it=void 0},x.prototype.getZooms=function(){return[Math.max(this.xt[0],_.zoomRange[0]),Math.min(_.zoomRange[1],this.xt[1])]},x.prototype.setZooms=function(t){this.xt=t},x.prototype.setNeedUpdate=function(t){this.zX||(this.Jv=5,t&&!this.Kv&&(this.Kv=t,_.Util.cancelAnimFrame(this.Qv),this.Qv=0,this.Eo()),this.Kv=t,this.bZ&&this.bZ.MZ.yY.setNeedUpdate(t))},x.prototype.render=function(){this.setNeedUpdate(!0)},x.prototype.qz=function(){return!1!==this.showLabel&&(!this.Cw||-1<this.Cw.indexOf("point"))},x.prototype.Qz=function(){return!1!==this.showLabel&&(!this.Cw||-1<this.Cw.indexOf("road"))},x.prototype.yS=function(){return!!this.m$||void 0===this.m$&&(!this.Cw||-1<this.Cw.indexOf("building"))},x.prototype.getViewMode_=function(){return this._view.type},x.prototype.fS=function(){return this.b$},x.prototype.XT=function(t){this.QT=t},x.prototype.JF=function(t){return this.mapStyle.vn?((t=this.mapStyle.vn.nX("00001","1","color",t))&&(t=_.Util.Hex2Rgba(t),t=_.vector.Up(t,255)),this.$C||t||[.329,.549,.839,1]):this.$C||[.329,.549,.839,1]},x.prototype.sX=function(t){var i;return this.mapStyle.vn?((i=(i=this.mapStyle.vn.nX("00001","2","color",t))||this.mapStyle.vn.nX("00001","1","color",t))&&(i=_.Util.Hex2Rgba(i),i=_.vector.Up(i,255)),this.$C||i||[.329,.549,.839,1]):this.$C||[.329,.549,.839,1]},x.prototype.qF=function(){return this.tB},x.prototype.qY=function(t,i){var n;return t&&2===t.length?(n=t[0],t=t[1],this.mapStyle.dn(n,t,i)):null},x.prototype.ra=function(t){return{2:3,3:3,4:3,5:3,6:6,7:6,8:8,9:8,10:10,11:10,12:10,13:12,14:12,15:14,16:14,17:14,18:14,19:14,20:14,21:14,22:14}[t]},x.prototype.getCustomTypeByPos=function(t){var i=this.ym().viewState.optimalZoom,i=this.ra(i),t=[(t=t.lnglat).lng,t.lat,t.lng,t.lat];return _.Util.WY(t,i)},x.prototype.jH=function(){return this.NH},x.prototype.UH=function(t){this.Mv.UH(t)},x.prototype.setHighlight=function(t,i){var n;this.bZ&&(n=this.bZ.MZ.KY)&&n.setHighlight(t,i)},x.prototype.start=function(){this.zX=!1,this.setNeedUpdate(!0)},x.prototype.stop=function(){this.setNeedUpdate(!1),this.zX=!0},x.prototype.Zdt=function(){return this.zv.filter(function(t){return!t._opts||!t._opts.TF||"AMap.MarkLayer"===t.CLASS_NAME})},x.prototype.im=function(){return this.Mv},x.prototype.em=function(t,i,n){var s,e,r,h,o,a,u,c,f;return void 0===i&&(i=[0,0,0,0]),void 0===n&&(n=_.zoomRange[1]),t?(r=_.ProjectionManager.getProjection(this._view.au()),s=_.V[this._view.au()],e=r.project(t[0],t[1]),t=[(r=r.project(t[2],t[3]))[0]-e[0],r[1]-e[1]],f=this.getSize().toArray(),h=this._view.getStatus().pitch,c=this._view.getStatus().rotation,c*=Math.PI/180,a=(i[2]-i[3])/2,u=(i[0]-i[1])/2,o=a*Math.cos(c)+Math.sin(c)*u,a=-Math.sin(c)*a+Math.cos(c)*u,u=t[0],0!=c&&(t[0]=Math.abs(t[0]*Math.cos(c))+Math.abs(t[1]*Math.sin(c)),t[1]=Math.abs(t[1]*Math.cos(c))+Math.abs(u*Math.sin(c))),u=Math.max(10,f[0]-i[2]-i[3]),c=Math.max(10,f[1]-i[0]-i[1]),f=Math.log(156543.03392804097/t[0]*u)/Math.log(2),i=Math.log(156543.03392804097/t[1]*c)/Math.log(2),u=Math.min(f,i),0<h&&(u-=h/60),u=Math.min(u,n),t=[(e[0]+r[0])/2,(e[1]+r[1])/2],(c=s.transform(t[0],t[1],u))[0]-=o,c[1]-=a,f=s.unproject(c[0],c[1],u),_.Pt(f,[u])):[116.39708007097433,39.874529056682476,12]},x.prototype.nm=function(t){if(0<t.length){for(var i,n=void 0,s=0;s<t.length;s++)n?(i=t[s].getBounds())&&n.union(i):n=(n=t[s].getBounds())&&n.clone();return n}},x.prototype.om=function(t,i){void 0===i&&(i=!0),this._view&&this._view.setOptions(t,i)},x.prototype.Eo=function(){this.zX||(this.Qv||(this.Qv=_.Util.requestAnimFrame(this.Yf.bind(this))),this.bZ&&this.bZ.MZ.yY.to())},x.prototype.rm=function(){return this.hm||(this.hm=new ms,this.addLayer(this.hm)),this.hm},x.prototype.sm=function(){return this.$F.source},x.prototype.FY=function(t){if(_.Module.eS.BY)return this.getLayerByClass("AMap.Inner.LabelsLayer").vi(t,!0)},x.prototype._getUserStyle=function(t){t&&this._changeStyle(t)},x.prototype._changeStyle=function(t){var s=this,i=t.split("amap://styles/")[1],e=(n=AMap.getConfig()).protocol,n=n.key,r=((t=-1!==t.indexOf("?isPublic=true"))&&(i=i.split("?isPublic")[0]),null),h=!1;i.length<32?(h=!0,r=e+"://webapi.amap.com/style2?name="+i+"&key="+n):(r=e+"://webapi.amap.com/v4/map/styles2?styleid="+i+"&s=rsv3&key="+n+(t?"&ispublic=1":""),AMap.getConfig().jscode?r+="&jscode="+AMap.getConfig().jscode:AMap.getConfig().gaodeserver&&(r=AMap.getConfig().gaodeserver+"/v4/map/styles2?styleid="+i+"&s=rsv3&key="+n+(t?"&ispublic=1":""))),yi.JSONP(r,function(t,i){var n;"complete"===t&&(i=i.data)&&i.data&&i.data.content?(t=JSON.parse(i.data.content),n=JSON.parse(i.data.layer||"{}"),s.QR=t,s.mapStyle&&(s.mapStyle.setStyle(t,h,s),n)&&s.mapStyle.vn.EY(n),s.u0(i.data)):s.emit("styleChanged")})},x.prototype._getMapboxStyle=function(n){var s=this,t=AMap.getConfig(),i=t.protocol;t.key,yi.Ajax(i+"://a.amap.com/jsapi/static/json/web_v8_2.0_"+n+".json",{type:"GET",requestContentType:"application/json"},function(t,i){"complete"===t?(i=i.data,s.JG={styles:i,vectorMapForeign:n},s.gn&&s.gn.Ha({QG:s.JG}),s.Eo()):s.JG=null})},x.prototype.um=function(t){for(var i=0,n=t.length;i<n;i+=1)this.addLayer(t[i])},x.prototype.u0=function(t){var i=this;t&&t.third_layer&&_.Module.module("AMap.StyleParser",function(){setTimeout(function(){i.y$||(i.f0||(i.f0=new AMap.StyleParser(i)),i.emit("styleLoaded",t))},0)})},x.prototype.cm=function(){var n=this,t=(w.addClass(this.kv,"amap-container"),this.l0=w.watchSize(this.kv,function(t,i){n.om({size:[t,i]})},this),this.kv),i=(!1===this.options.showMapGrid&&(this.kv.style.backgroundImage="none"),this.Iv=w.create("div",null,"amap-maps"),this.do=w.create("div",this.Iv,"amap-layers"),this.fm=w.create("div",this.Iv,"amap-overlays"),t.appendChild(this.Iv),this.Tv=w.create("div",this.kv,"amap-controls"),this.Iv.tabIndex=0,{});i.p_=w.create("a",t,"amap-logo"),w.create("img",i.p_).src=_.Support.Ue?AMap.getConfig().protocol+"://"+AMap.getConfig().domain+"/theme/v2.0/logo@2x.png":AMap.getConfig().protocol+"://"+AMap.getConfig().domain+"/theme/v2.0/logo@1x.png",i.v_=w.create("div",t,"amap-copyright"),i.v_.style.display="none",350<w.getViewport(this.kv)[0]&&(i.v_.innerHTML=AMap.getConfig().v_,i.v_.mapNumber=w.create("span",i.v_,"amap-mcode")),this.m_=i},x.prototype.d_=function(){var t=this.getLayers();if(t){for(var i=-1,n="",s=0;s<t.length;s+=1){var e=t[s].get("mapNumber"),r=t[s].get("zIndex");e&&i<r&&t[s].get("visible")&&(n=e,i=r)}var h=this.c_;return(n=!this.g$||"GS(2021)6375"===n&&h&&"normal"!==h&&"amap://styles/normal"!==h?"":n)&&this.tE!==n&&this.m_&&this.m_.v_&&this.m_.v_.mapNumber&&(this.m_.v_.mapNumber.innerHTML="- "+n+"号"),this.tE=n}},x.prototype.pm=function(t){var i={size:w.getViewport(this.kv),zoom:t.zoom,center:t.center,rotation:t.rotation,projectionId:t.projection,pitch:t.pitch};return new(t.viewMode&&"3D"===t.viewMode?Gn:jn)(i,this)},x.prototype.dm=function(){},x.prototype.Hv=function(){for(w.remove(this.Iv),delete this.Iv,this.do&&(w.remove(this.do),delete this.do),this.Tv&&(w.remove(this.Tv),delete this.Tv),this.fm&&(w.remove(this.fm),delete this.fm),this.l0&&(this.l0(),delete this.l0);this.kv&&this.kv.firstChild;)this.kv.removeChild(this.kv.firstChild);this.kv&&delete this.kv,Vs.cache&&(Vs.cache={})},x.prototype.Vv=function(){this.pi&&(this.pi.destroy(),delete this.pi),this.di&&(this.di.destroy(),delete this.di),this.vm&&(this.vm.destroy(),delete this.vm)},x.prototype.Xv=function(){this.mm&&this.mm.destroy&&(this.mm.destroy(),delete this.mm);for(var t=0,i=this.getLayers();t<i.length;t++)i[t].destroy();this.so&&this.so.destroy(),this.R_&&(this.R_.destroy(),delete this.R_),this.zv=[],this.Mv&&this.Mv.destroy&&(this.Mv.destroy(),delete this.Mv)},x.prototype.ym=function(){var t=this._view.getStatus();return{debug:this.debug,layers:this.zv,uo:this.Mv,size:t.size,do:this.do,viewState:t,map:this}},x.prototype.Yf=function(){if(!this.zX&&(this.w$(),!this.y$)){if($s.VZ())for(var t=0,i=this.ym().layers;t<i.length;t++){var n,s=i[t];s.getRender()||(n=this.Rv(s,{}),s.Do(n))}this.pi&&this.pi.iy({}),this.di&&this.di.iy({});var e=this.ym();if(this.bm(e),this.tB=(new Date).getTime(),this.Mv.loadData(e.viewState,this,this.mm?this.mm.context:null),this.mm&&this.mm.renderFrame(e),this.Jv&&this.Kv)this.Qv=_.Util.requestAnimFrame(this.Yf.bind(this));else if((this.Jv<=0||!this.Kv)&&(this.Kv=!1,_.Util.cancelAnimFrame(this.Qv),this.Qv=0,this.gm||this.Lv||this.lt||this.Cv)){if(this.lt&&-1!==this.k$){if("d"===_.Support.baseRender&&0<=this.k$){if(this.KT(),!this.tD)return void(this.tD=!0);this.tD=!1}this.G("zoomend",{target:e.map})}this.Cv&&-1!==this._$&&this.G("moveend",{target:e.map}),this.Lv&&-1!==this.M$&&this.G("rotateend"),this.gm&&-1!==this.S$&&this.G("pitchend"),this.Lv=!1,this.gm=!1,this.lt=!1,this.Cv=!1,this.Qv||(this.Mv.loadData(e.viewState,this,this.mm?this.mm.context:null),this.mm&&this.mm.renderFrame(e))}this.Jv--}},x.prototype.bm=function(t){var i=t.viewState,s=(n=this.wm).center,e=n.rotation,r=n.zoom,n=n.pitch,h=i.center,o=i.zoom,a=i.rotation,u=i.pitch;if(s[0]!==h[0]||s[1]!==h[1]?(this._$=1,this.Cv||this.G("movestart",{target:t.map}),this.Cv=!0,this.G("mapmove",{target:t.map})):1<=this._$&&this._$++,r!==o?(this.lt||this.G("zoomstart",{target:t.map}),this.G("zoomchange",{target:t.map}),this.lt=!0,this.k$=1):1<=this.k$&&this.k$++,e!==a?(this.Lv||this.G("rotatestart"),this.G("rotatechange"),this.Lv=!0,this.M$=1):1<=this.M$&&this.M$++,n!==u?(this.gm||this.G("pitchstart"),this.G("pitchchange"),this.gm=!0,this.S$=1):1<=this.S$&&this.S$++,5<=this._$&&(this.Cv=!1,this._$=-1,this.G("moveend",{target:t.map})),5<=this.k$&&(this.lt=!1,this.k$=-1,this.G("zoomend",{target:t.map})),5<=this.M$&&(this.Lv=!1,this.M$=-1,this.G("rotateend")),5<=this.S$&&(this.gm=!1,this.S$=-1,this.G("pitchend")),"d"===_.Support.baseRender&&4<=this.k$){if(this.KT(),!this.tD)return void(this.tD=!0);this.tD=!1}this.Qv||this.mm&&(this.Mv.loadData(t.viewState,this,this.mm.context),this.mm.renderFrame(t)),this.wm=i},x.prototype.G=function(t,i){this.emit(t,i=void 0===i?{}:i)},x.prototype.Rm=function(){var r=this;this.on("styleChanged",function(){if(r.kv){var t=void 0,i=(t=r.options.backgroundColor||(r.mapStyle&&(i="fast"===r.bZ.MZ.drawMode?_.Util.getOptimalZoom(r.getZoom()):r.getZoom(),i=r.mapStyle.dn(30001,1,i))&&i.faceColor?((t=i.faceColor.rgba.slice(0))[3]=t[3]/255,"rgba( "+t.join(",")+")"):"#f7f7f7"),r.kv.style.backgroundColor=t,r.mapStyle.vn.nX("00001","3","visible",10)),t=r.mapStyle.vn.nX("00001","3","lineColor",10);i&&t?(t=_.Util.Hex2Rgba(t),(t=Ks.oX(t))&&(r.kv.style.backgroundImage=t,r.kv.style.backgroundSize="100px 100px")):!1===i&&(r.kv.style.backgroundImage="none");for(var n=0,s=r.zv;n<s.length;n++){var e=s[n];_.qG(e)&&e.sl()}}r.xm=!0,r.Eo()}),this.on("repaint",function(){r.Eo()})},x.prototype.w$=function(){var t=this;this.R$||("d"===this.baseRender?(this.R$=!0,_.Module.module("DomRender",function(){setTimeout(function(){t.y$||(t.mm=new _.Module.DomRender(t),t.Eo())},0)})):(this.R$=!0,_.Module.module("WebGLRender",function(){setTimeout(function(){t.y$||(AMap.Browser.isWebGL&&!t.KZ?(t.KZ=!0,t.mm=new _.Module.WebGLRender(t),t.I_=new ys(t),t.yH=new _.LH(t,t.I_,t.gn),t.Eo()):t.R$=!1)},0)})))},x.prototype.Rv=function(t,i){return this.isDOMMode()?$s.JZ[t.CLASS_NAME]?new $s.JZ[t.CLASS_NAME](this,t):void 0:$s.YZ[t.CLASS_NAME]?new $s.YZ[t.CLASS_NAME]:void 0},x.prototype.KT=function(){var e,r,h,o,a,u,c=this,t=this._view.getStatus(),f=t.zoom,l=t.centerCoord,d=f,v=0;0!=(v=(d=this.bo>f?Math.floor(f):Math.ceil(f))-f)&&(this.bo=d,e=_.V[this._view.au()],r=200*Math.abs(v)+100,h=new H(0,.6,.15,1),u=o=0,a=function(){o+=16;var t=c._view.getStatus().zoom,i=f+v*h.h(o/r),t=(r<o&&(i=d),e.nt(c.QT[0],c.QT[1],t)),s=(n=e.nt(c.QT[0],c.QT[1],i))[0]-t[0]+l[0],n=n[1]-t[1]+l[1],t=c.getProjection().unproject(s,n);c.setZoomAndCenter(i,t,!0),d<=i&&0<v||v<0&&i<=d?(c.setZoom(d,!0),_.Util.cancelAnimFrame(u)):o<r&&(u=_.Util.requestAnimFrame(a))},u=_.Util.requestAnimFrame(a))},x.prototype.iB=function(){window.onbeforeload=this.destroy,window.onunload=this.destroy,window.onbeforeunload=this.destroy},x.t_=[2,20];var ie,ne=x;function x(t,i){var n=ie.call(this)||this;n.className="AMap.Map",n.so=new as,n.lcs=_.lcs,n.debug=!1,n.complete=!1,n.Kv=!1,n.controls=[],n.langForeign="zh_cn",n.fE=!0,n.IY="normal",n.az=[.92,.92,.9,.9],n.sz=[.94,.94,.94,.9],n.rz=[.94,.94,.94,.9],n.$C=[.329,.549,.839,1],n.Ov=!0,n.Dv=!0,n.Pv=!0,n.Fv=!0,n.fZ=1,n.fi=!0,n.jv=!0,n.Ev=!0,n.Uv=!0,n.Bv=!0,n.$v=!0,n.Nv=0,n.Sm=!1,n.c_="",n.Zv="default",n.qv="",n.xt=[2,20],n.YG=!1,n.QZ="",n.zv=[],n.A$=!1,n.R$=!1,n.Qv=0,n.f0=void 0,n.xm=!1,n.lt=!1,n.Cv=!1,n.Lv=!1,n.gm=!1,n.km=0,n.Jv=5,n.y$=!1,n.Wv=!_.Support.$e,n.g$=!0,n.tB=(new Date).getTime(),n._$=-1,n.M$=-1,n.S$=-1,n.k$=-1,n.HL=!1,n.bo=10,n.tD=!1,n.QT=[0,0],n.UB=!1,n.tE="",n.KZ=!1,n.zX=!1,_.Support.hardwareAccEnabled||console&&console.log&&console.log("检测到您已关闭硬件加速模式,开启以获得更好的体验!"),n.Rm(),n.options=i,n.xX=i.cacheSize,n.g$=void 0===i.I$?n.g$:i.I$,n.az=_.Util.color2RgbaArray(i.buildingColor=i.buildingColor),n.sz=_.Util.color2RgbaArray(i.wallColor),n.rz=_.Util.color2RgbaArray(i.roofColor),n.$C=_.Util.color2RgbaArray(i.skyColor),n.Dv=void 0===i.dragEnable?n.Dv:i.dragEnable,n.Pv=void 0===i.zoomEnable?n.Pv:i.zoomEnable,n.Fv=void 0===i.scrollWheel?n.Fv:i.scrollWheel,n.fZ=void 0===i.zoomSpeed?n.fZ:i.zoomSpeed,n.Ov=void 0===i.jogEnable?n.Ov:i.jogEnable,n.fi=void 0===i.doubleClickZoom?n.fi:i.doubleClickZoom,n.jv=void 0===i.keyboardEnable?n.jv:i.keyboardEnable,n.Ev=void 0===i.animateEnable?n.Ev:i.animateEnable,n.Uv=void 0===i.pitchEnable?n.Uv:i.pitchEnable,n.$v=void 0!==i.touchZoom?i.touchZoom:n.$v,n.Nv=void 0!==i.touchZoomCenter?i.touchZoomCenter:n.Nv,n.Zv=i.defaultCursor||n.Zv,n.QZ=i.overseaDataType||n.QZ,n.IY=i.loadData||"normal",n.Wdt=i.poiIcon,i.limitBounds&&n.setLimitBounds(i.limitBounds),n.Sm=i.Lm||!1,n.xt=i.zooms||n.xt,n.bo=i.zoom||n.bo,n.baseRender=_.Support.baseRender,i.viewMode="d"===_.Support.baseRender?"2D":i.viewMode,n.Bv=!("3D"!==i.viewMode),n.Bv=void 0===i.rotateEnable?n.Bv:i.rotateEnable,n.debug=i.debug||!1,n.m$="3D"===i.viewMode&&i.showBuildingBlock,n.Wv=void 0===i.isHotspot?n.Wv:i.isHotspot,n.UB=void 0===i.pickWhenMoving?n.UB:i.pickWhenMoving,n.fE=void 0===i.asyncOverlay?n.fE:i.asyncOverlay,n.showLabel=void 0===i.showLabel||Boolean(i.showLabel),n.Cw=i.features||["bg","point","road","building"],n.c$=i.mask,n.NH=void 0!==i.labelRejectMask&&Boolean(i.labelRejectMask),n.bZ=new Gs({lY:new _.MY,gY:new Os,yY:new _.wY({check:function(){return!!n.bZ&&n.bZ.MZ.lY.xY()},render:function(){if(n.TL())return!1;n.bZ&&n.bZ.MZ.lY.exec(20)}}),drawMode:i.drawMode||"normal",tY:new Xs({Fz:["default"]}),wZ:new Zs(n),KY:new se(n)}),n.WebGLParams=void 0===i.WebGLParams?{}:i.WebGLParams,"d"!==n.baseRender?(n.bZ.dynamic.subscribe("firstPaint",function(){n.emit("firstPaint",_.Support.amapRunTime)},n,!0),n.bZ.MZ.lY.on("taskclear",function(){n.setNeedUpdate(!0)}),n.bZ.MZ.lY.register("SDFCombine",function(t){return new Es(n.bZ.MZ.gY,t)},{kY:10}),n.bZ.MZ.lY.register("LangSDF",function(t){return new Xn(n.R_.yG,t)},{kY:10}),n.mapStyle=new _n(n),n.mapStyle.pn(function(){var t=i.mapStyle;t?n._getUserStyle(t):n.emit("styleChanged")}),n.Eo(),s=n.z_=new Vn,n.gn=new rs(n),n.R_=new Zn(s,n),n.x$=new js(n)):(n.z_=new Vn,n.R_=new _.vG,n.emit("styleChanged"));(s=i.vectorMapForeign)&&n._getMapboxStyle(s),i.langForeign&&(n.langForeign=i.langForeign),n.gn&&n.gn.Ha({langForeign:n.langForeign}),t&&(t.amap&&t.amap.destroy(),t.amap=n),n.kv=t,n.isDOMMode()&&(i.zoom=i.zoom&&18<i.zoom?18:i.zoom),n._view=n.pm(i),n.b$=new ws(n),n.Mv=new Ui(n),n.c_=i.mapStyle||"normal",n.QR=null;var s=_.Support.isWebGL,t=AMap.getConfig().y_,e=i.layers||[],r=(n.cm(),s&&"d"!==n.baseRender&&(n.canvas=w.create("canvas",n.do,"amap-layer"),n.canvas.width=0,n.canvas.height=0,n.gl=_.Support.getContext(n.canvas,n.WebGLParams)),n.w$(),0===e.length?n.isDOMMode()?(n.bo=18<n.bo?18:n.bo,r=[n.xt[0],n.xt[1]],n.xt[0]=2<r[0]?r[0]:2,n.xt[1]=18<r[1]?18:r[1],n.addLayer(new v({id:"_defaultLayer",tileUrl:t})),n.Bv=!1):s&&n.addLayer(new Ji({cacheSize:n.xX})):n.um(e),n.d_(),n.$F=new is({map:n}),n.addLayer(n.$F),n._view.getStatus());return n.wm=r,n.setCursor(n.Zv),AMap.getConfig().keytype&&"1"===AMap.getConfig().keytype&&(n.isDOMMode()?n.addLayer(new v.Mark({})):n.addLayer(new AMap.Mark({zIndex:8,opacity:1,map:n}))),n}ee.prototype.setHighlight=function(t,i){this.Lp=t,this.Ap=i,this._Y.setNeedUpdate(!0)},ee.prototype.destroy=function(){this.map.off("hotspotclick",this.$Y),this.map.off("hotspotover",this.$Y),this.map.off("hotspotout",this.tX)},ee.prototype.$Y=function(t){this.iX=t.id,this.map.setNeedUpdate(!0)},ee.prototype.tX=function(t){this.iX="",this.map.setNeedUpdate(!0)};var se=ee;function ee(t){var i=this;this.map=t,this.Lp=-2,this.Ap=[],this.iX="",this.$Y=this.$Y.bind(this),this.tX=this.tX.bind(this),this.map.on("hotspotclick",this.$Y),this.map.on("hotspotover",this.$Y),this.map.on("hotspotout",this.tX),this.GY=Date.now(),this.NY=0,this.UY=!0,this._Y=new _.wY({check:function(){return-1<i.Lp},render:function(){var t=Date.now()-i.GY;i.NY=2400<t%3e3?0:.5-Math.abs(t%3e3/2400-.5),i.map.setNeedUpdate(!0)}}),this._Y.setNeedUpdate(!0)}he.prototype.setImageSize=function(t){t instanceof _.Size&&(t=t.toArray()),this._opts.imageSize=t},he.prototype.getImageSize=function(){var t=this._opts.imageSize,i=this.Om;return t||(i.length?i:[])},he.prototype.setSize=function(t){t instanceof _.Size&&(t=t.toArray()),this._opts.size=t},he.prototype.getSize=function(){return this._opts.size},he.prototype.setImageOffset=function(t){t instanceof _.Pixel&&(t=t.toArray()),this._opts.imageOffset=t},he.prototype.getImageOffset=function(){return this._opts.imageOffset||[0,0]},he.prototype.getImage=function(){return this._opts.image},he.prototype.setImage=function(t){this._opts.image=t},he.prototype.Fm=function(){return this.Om||[]},he.prototype.Em=function(t){t instanceof _.Size&&(t=t.toArray()),this.Om=t};var re=he;function he(t){this.CLASS_NAME="AMap.Icon",this._opts={size:[0,0],imageOffset:new _.Pixel(0,0),image:AMap.getConfig().protocol+"://webapi.amap.com/theme/v1.3/markers/0.png"},this.Om=[];var i=t.size,n=t.imageSize,s=t.image,t=t.imageOffset;i&&this.setSize(i),n&&this.setImageSize(n),t&&this.setImageOffset(t),s&&this.setImage(s)}var oe,ae="AMap.Overlay",Qt=(oe=_.Event,_.Ei(ue,oe),ue);function ue(){var t=null!==oe&&oe.apply(this,arguments)||this;return t.type=ae,t.className=ae,t}ce=_.Event,_.Ei(fe,ce);var ce;function fe(){var t=null!==ce&&ce.apply(this,arguments)||this;return t.type=ae,t.className=ae,t}var le,de={_dt:function(t){return!!(window&&window._AMapConfig&&window._AMapConfig.wiaBizToken)&&!!(t&&t[0]&&"string"==typeof t[0]&&-1<t[0].indexOf("WIA"))},Ydt:function(e){return _.T8t(this,void 0,void 0,function(){var i,n;return _.x8t(this,function(t){return i="http://dev-restapi.amap.com/api/v1/wia/point/get/lonlat?s=rsv3&key="+AMap.getConfig().key+"&bizToken="+window._AMapConfig.wiaBizToken,(n=AMap.getConfig()).jscode&&(i+="&jscode="+n.jscode),[2,new Promise(function(n,s){yi.Ajax(i,{requestContentType:"application/json",type:"POST",content:JSON.stringify({wiaLonLat:e})},function(t,i){i&&i.data&&(i=JSON.parse(i.data))&&i.data&&i.data.list&&i.data.list[0]?(i=i.data.list[0],i=new AMap.LngLat(i.lon,i.lat),n([i.lng,i.lat])):s("error")})})]})})}},ve="AMap.DOMOverlay",ge={top:"top",right:"right",bottom:"bottom",left:"left",Nm:"top-left",$m:"top-center",Um:"top-right",Bm:"middle-left",center:"center",Wm:"middle-right",Gm:"bottom-left",Zm:"bottom-center",qm:"bottom-right"},Me_Ym="viewchange",ke=[10,0,0,0],we={map:null,visible:!0,offset:[0,0],anchor:"top-left",rotate:0,orientation:null,scale:1,zooms:_.zoomRange,noSelect:!1,innerOverlay:!1,isCustom:!1},si=(le=fe,_.Ei(xe,le),xe.prototype.getOptions=function(){return this._options},xe.prototype.add=function(t){for(var i=this._map,n=0,s=t=void 0===t?[]:t;n<s.length;n++)s[n].add(i)},xe.prototype.remove=function(t){for(var i=0,n=t=void 0===t?[]:t;i<n.length;i++)n[i].remove()},xe.prototype.updateOverlay=function(t){if(t)for(var i=0,n=t;i<n.length;i++)n[i].updateOverlay();else{var s,e=!this.aZ&&this.viewChange,r=(this.aZ=!1,this._overlays);for(s in r)r.hasOwnProperty(s)&&r[s].updateOverlay({viewChange:e})}},xe.prototype.iy=function(t){this.updateOverlay()},xe.prototype.addToGroup=function(t){var i=this._container,n=this._overlays,s=t.hS,e=t.dom;i.appendChild(e),n[s]=t},xe.prototype.removeFromGroup=function(t){var i=this._container,n=this._overlays,s=t.hS,t=t.dom;i.removeChild(t),delete n[s]},xe.prototype.vi=function(t){return null},xe.prototype.destroy=function(){this.ey();var t,i=this._overlays;for(t in i)i.hasOwnProperty(t)&&i[t].remove();this._overlays={},this._container&&w.remove(this._container)},xe.prototype.getAllOverlays=function(){var t,i,n=this._overlays,s=[];for(t in n)n.hasOwnProperty(t)&&(i=n[t])&&s.push(i);return s},xe.prototype.ny=function(){this._map},xe.prototype.ey=function(){var t=this._map,i=Me_Ym;t.off(i,this.iy)},xe);function xe(t,i){void 0===i&&(i={});var n=le.call(this)||this,t=(n.type="AMap.DOMOverlayGroup",n.viewChange=!1,n.aZ=!1,n._options={zIndex:120},n._overlays={},(n._map=t).kv),t=(n._parent=t.querySelector(".amap-layers"),i.className);return n._className=t,n.iy=n.iy.bind(n),n.ny(),n}Ae=Qt,_.Ei(A,Ae),Object.defineProperty(A.prototype,"CLASS_NAME",{get:function(){return this.className},eb:!1,nb:!0}),A.prototype.getMap=function(){return this._map||null},A.prototype.setMap=function(t){t instanceof ur?this.add(t):null==t&&this.remove()},A.prototype.addTo=function(t){this.add(t)},A.prototype.add=function(t){t&&(this._add(t),this._parent)&&(this._parent.addToGroup(this),this.updateOverlay())},A.prototype.remove=function(){this._map&&this._parent&&(this._parent.removeFromGroup(this),this._remove())},A.prototype.show=function(){this._opts.visible=!0,this.updateOverlay()},A.prototype.hide=function(){this._opts.visible=!1,this.updateOverlay()},A.prototype.getPosition=function(){var t=this._position;return t?_.Bs(t)?t:new _.LngLat(t[0],t[1]):null},A.prototype.setPosition=function(t){this._position=t,this.updateOverlay()},A.prototype.getAnchor=function(){return this._opts.anchor||ge.Nm},A.prototype.setAnchor=function(t){t&&(this._opts.anchor=t,this.updateOverlay())},A.prototype.getOffset=function(){var t=this._opts.offset||[0,0];return new _.Pixel(t[0],t[1])},A.prototype.setOffset=function(t){t&&(t instanceof Array||void 0===t.x||void 0===t.y||(this._opts.offset=[t.x,t.y]),this.updateOverlay())},A.prototype.getAngle=function(){return this._opts.rotate||0},A.prototype.setAngle=function(t){this._opts.rotate=t,this.updateOverlay()},A.prototype.getOrientation=function(){return this._opts.orientation},A.prototype.setOrientation=function(t){"number"==typeof t?(this._opts.orientation=t,this._opts.rotate=this.dP(t)):(this._opts.orientation=void 0,this._opts.rotate=0),this.updateOverlay()},A.prototype.getSize=function(){return this._getSize()},A.prototype.setSize=function(t){this._opts.size=_.ay(t)?t.toArray():t,this.updateOverlay()},A.prototype.getzIndex=function(){return this._opts.zIndex},A.prototype.setzIndex=function(t){this._opts.zIndex=t,this.updateOverlay()},A.prototype.getOptions=function(){return this._opts},A.prototype.getContent=function(){return this._opts.content||""},A.prototype.setContent=function(t){this._opts.content=t=void 0===t?"":t,this._size=[0,0],this._removeContent(),this._createDom(this.dom,t),this.updateOverlay()},A.prototype.getBounds=function(){var t=this._position;return new l(t,t)},A.prototype.getVisible=function(){return void 0===this._opts.visible||this._opts.visible},A.prototype.updateOverlay=function(t){t=void 0!==(t=(t=void 0===t?{}:t).viewChange)&&t,this._map&&this._setStyle(t)&&this._applyStyle(t)},A.prototype.uZ=function(t){t=void 0!==(t=(t=void 0===t?{}:t).viewChange)&&t,this._map&&(this._setStyle(t),this._applyStyle(t))},A.prototype.destroy=function(){this.dom&&w.remove(this.dom)},A.prototype.getCursor=function(){if(this._map)return this._map.getDefaultCursor()},A.prototype.getContentDom=function(){return this.dom},A.prototype._add=function(t){},A.prototype._remove=function(){this._map=null,this._parent=null},A.prototype._createContainer=function(){var t=document.createElement("div");return w.addClass(t,this._className),t},A.prototype._createDefaultInnerDom=function(){return document.createElement("div")},A.prototype._setStyle=function(t){void 0===t&&(t=!1);var i=this._position,i=this._points=this._map&&i&&this._map.lngLatToContainer(i).toArray(),n=(this._map&&this._map.getRotation(),this._style),s=this._map&&this._map.getZoom(),e=this._opts.zooms||[2,20],r=void 0===this._opts.visible||this._opts.visible,s=s&&(s<e[0]||s>e[1]),e=n.visible,r=(void 0!==r&&(n.visible=r),r&&(n.visible=!s),this.ZF(i));n.visible&&(n.visible=!r);var r=(s=this._opts).zIndex,h=void 0===(h=s.anchor)?ge.Nm:h,o=void 0===(o=s.offset)?[0,0]:o,a=s.rotate,u=s.scale,c=s.noSelect,f=[0,0];return"number"==typeof(s=s.orientation)?n.rotate=this.dP(s):void 0!==a&&(n.rotate=a),e!==n.visible&&this._map&&(this._map.render(),this._parent)?!(this._parent.aZ=!0):(t?i&&(n.left=i[0]+"px",n.top=i[1]+"px",f=n.translate):(this._getContentSize(),(s=this._getStyleZIndex(r))&&(n.zIndex=s),void 0!==u&&(n.scale=u),i&&(n.left=i[0]+"px",n.top=i[1]+"px"),(h||o)&&(f=this._getOffset(h,o),n.translate=f,n.transformOrigin=-f[0]+"px "+-f[1]+"px"),n.pointerEvents=!0===c?"none":"auto"),a="translate("+f[0]+"px, "+f[1]+"px) scale("+n.scale+") rotate("+n.rotate+"deg)",_.Support.ie&&(n.msTransform=a),n.transform=a,!0)},A.prototype._getStyleZIndex=function(t){return t},A.prototype._getSize=function(){var i=(t=(t=this._opts.size||[])instanceof _.Size?t.toArray():t)[0],t=void 0===(t=t[1])?0:t,s=(n=this._size)[0],n=n[1];return[(void 0===i?0:i)||(void 0===s?0:s),t||(void 0===n?0:n)]},A.prototype._getContentSize=function(){var t=this._style,i=this._getSize(),n=0,s=0;i[0]&&i[1]?(n=i[0],s=i[1]):this.dom&&(i=this.dom,n=Math.ceil(i.offsetWidth)||0,s=Math.ceil(i.offsetHeight)||0,this._size=[n,s]),t.width=n+"px",t.height=s+"px",t.size=[n,s]},A.prototype._applyStyle=function(t){void 0===t&&(t=!1);var i,n,s=this._style,e=this.dom;for(i in s)s.hasOwnProperty(i)&&("visible"===i?(n=s[i]?"block":"none",e.style.display=n):t?"top"!==i&&"left"!==i&&"transform"!==i&&"msTransform"!==i||(e.style[i]=s[i]):"width"===i||"height"===i?"0px"!==s[i]&&(n=this._opts.size)&&"AMap.InfoWindow"!==this.type&&("width"===i&&(e.style[i]=n[0]+"px"),"height"===i)&&(e.style[i]=n[1]+"px"):"translate"!==i&&"scale"!==i&&"rotate"!==i&&(e.style[i]=s[i]))},A.prototype._getOffset=function(t,i){var n=(t=this._getAnchorOffset(t))[0],t=t[1];return[n+i[0],t+i[1]]},A.prototype._getAnchorOffset=function(t){var n=(i=this._style.size)[0],s=i[1],i=ge,e=0,r=0;if(Array.isArray(t))return t;switch(t){case i.Nm:e=0;break;case i.$m:e=-n/2;break;case i.Um:e=-n;break;case i.Bm:e=0,r=-s/2;break;case i.center:e=-n/2,r=-s/2;break;case i.Wm:e=-n,r=-s/2;break;case i.Gm:r=-s;break;case i.Zm:e=-n/2,r=-s;break;case i.qm:e=-n,r=-s}return[e,r]},A.prototype._createDom=function(t,i){return i&&("object"==typeof i&&i instanceof HTMLElement?t.appendChild(i):t.innerHTML=i),t.addEventListener("touchstart",function(t){t.cH="markerContent"}),t},A.prototype._removeContent=function(){this.dom.innerHTML=""},A.prototype._formatSize=function(t){return[t.getWidth(),t.getHeight()]},A.prototype.ZF=function(t){var i,n=this._map;return!!(n&&t&&"3D"===(n=n.getView()).type&&(n=n.Uu(),i=ke,t)&&t[1]-n-i[0]<=0)},A.prototype._getRotationByPoints=function(t,i){var n=i.y-t.y,s=i.x-t.x,e=0;return(0!=n||0!=s)&&(i.x-t.x!=0?(e=Math.atan((i.y-t.y)/(i.x-t.x)),0<=n&&s<0||n<0&&s<=0?e=Math.PI+e:n<0&&0<=s&&(e=2*Math.PI+e)):e=i.y>t.y?Math.PI/2:3*Math.PI/2,Math.round(180*e/Math.PI*10)/10)},A.prototype._getRotationByLngLats=function(t,i){var n=null==(n=this._map)?void 0:n.getProjection().project(t.KL,t.kT),i=(t=null==(t=this._map)?void 0:t.getProjection().project(i.KL,i.kT))[0]-n[0],t=t[1]-n[1],n=0;return(0!=i||0!=t)&&(0!=t?(n=Math.atan(i/t),0<=i&&0<t||(0<=i&&t<0||i<0&&t<0?n=Math.PI+n:i<0&&0<t&&(n=2*Math.PI+n))):n=0<i?Math.PI/2:3*Math.PI/2,Math.round(180*n/Math.PI*10)/10)},A.prototype.dP=function(t){var i=0,n=this._position,s=(n instanceof AMap.LngLat&&(n=[n.lng,n.lat]),this._map);return s&&n&&(t=this.pP(n,t),n=s.lngLatToContainer(n),s=s.lngLatToContainer(t),i=!1===(t=this._getRotationByPoints(n,s))?0:t+Math.PI),i+90},A.prototype.pP=function(t,i){var n=null==(n=this._map)?void 0:n.getProjection().project(t[0],t[1]);return n[0]+=Math.sin(i*Math.PI/180)*Math.pow(2,18-this._map.getZoom()),n[1]+=Math.cos(i*Math.PI/180)*Math.pow(2,18-this._map.getZoom()),null==(t=this._map)?void 0:t.getProjection().unproject(n[0],n[1])},A.prototype.vP=function(t){return 10/Math.pow(2,t-2)},A.prototype.Ydt=function(n){return _.T8t(this,void 0,void 0,function(){var i;return _.x8t(this,function(t){switch(t.label){case 0:return[4,de.Ydt(n)];case 1:return i=t.y8t(),this._position=i,this.updateOverlay(),[2]}})})};var Ae,Pi=A;function A(t,i){void 0===t&&(t={}),void 0===i&&(i={});var n=Ae.call(this)||this,s=(n.type=ve,n.className=ve,n._style={width:0,height:0,size:[0,0],position:"absolute",top:0,left:0,translate:[0,0],rotate:0,scale:1,transformOrigin:[0,0],zIndex:12,visible:!0,draggable:!1,zooms:_.zoomRange,noSelect:!1},n._size=[0,0],n._dragObjects={sy:[0,0],hy:[0,0],ly:[0,0]},n._className="amap-overlay",n._originOpts=t,n._opts=_.assign({},we,t),n._opts.angle&&(n._opts.rotate=n._opts.angle),!t.offset||t.offset instanceof Array||void 0===t.offset.x||void 0===t.offset.y||(n._opts.offset=[t.offset.x,t.offset.y]),n.hS=_.Util.stamp(n),i.className),i=i.anchor,s=(n._className=s,!t.anchor&&i&&(n._opts.anchor=i),t.content),i=n._createContainer();return n.dom=n._createDom(i,s),n._position=t.position,n.updateOverlay(),n}var ze,Ce={uy:"AMap.Marker",py:"amap-markers",vy:"amap-marker",my:"//webapi.amap.com/theme/v1.3/markers/b/mark_bs.png",yy:120,xy:12,by:2,gy:Math.pow(2,31)},Se=_.assign({},we,{title:"",clickable:!0,draggable:!1,bubble:!1,topWhenClick:!1,zIndex:Ce.xy,cursor:"pointer",extData:{}}),Te=(ze=si,_.Ei(Le,ze),Le.prototype.vi=function(t){var i,n,t=t.target;return _.isEmpty(this._overlays)||!t?null:(i=w.closest(t,"amap-marker"),t=this._overlays,n=null,i&&_.forEach(t,function(t){t.dom===i&&(n=t)}),n)},Le.prototype.setTop=function(t){var i;t&&((i=this.Kl)&&i!==t&&i.setTop(!1),this.Kl=t)},Le.prototype._createContainer=function(t){var i=document.createElement("div");return w.addClass(i,this._className),t.appendChild(i),i},Le);function Le(t){return(t=ze.call(this,t,{className:Ce.py})||this).type=Ce.uy,t.className=Ce.uy,t._container=t._createContainer(t._parent),t}Ie=Pi,_.Ei(z,Ie),z.prototype.getTitle=function(){return this._opts.title},z.prototype.setTitle=function(t){this._opts.title=t,this.dom&&this.dom.setAttribute("title",t)},z.prototype.getIcon=function(){return this._opts.icon},z.prototype.setIcon=function(t){t&&(this._opts.icon=t,this._opts.content||this._removeContent(),"AMap.Icon"===t.CLASS_NAME&&(this._opts.size=t.getSize()),this.wy(),this.updateOverlay())},z.prototype.getLabel=function(){return this._opts.label||{}},z.prototype.setLabel=function(t){var i,n=this._opts.label||{},t=(this._opts.label=_.assign(n,t),n.content),n=void 0===(n=n._needUpdate)||n;t?((i=this._y?this.ky(t,this._y):this._y=this.ky(t))&&(11<=(t=void 0,t=this.v0())||t<0)&&this.d0(),this.dom&&this.dom.appendChild(i),n&&this.updateOverlay()):this._y&&(w.remove(this._y),this._y=null)},z.prototype.getClickable=function(){var t=this._opts.clickable;return!(void 0!==t&&!t)},z.prototype.setClickable=function(t){this._opts.clickable=!!(t=void 0===t||t)},z.prototype.getDraggable=function(){var t=this._opts.draggable;return void 0!==t&&t},z.prototype.setDraggable=function(t){(this._opts.draggable=t)?this._bindEvents():this.T_()},z.prototype.getTop=function(){return this._isTop},z.prototype.setTop=function(t){this._isTop=t=void 0!==t&&t;var i=this._parent;i&&t&&i.setTop(this),this.updateOverlay()},z.prototype.getCursor=function(){var t=this._opts.cursor;return!t&&this._map?this._map.getDefaultCursor():t},z.prototype.setCursor=function(t){t&&(this._opts.cursor=t)},z.prototype.getExtData=function(){return this._opts.extData},z.prototype.setExtData=function(t){this._opts.extData=t},z.prototype.remove=function(){this.T_(),this.ZH(),Ie.prototype.remove.call(this)},z.prototype.moveTo=function(){console.log("Should implement AMap.moveAnimation plugin first.")},z.prototype.moveAlong=function(){console.log("Should implement AMap.moveAnimation plugin first.")},z.prototype.startMove=function(){console.log("Should implement AMap.moveAnimation plugin first.")},z.prototype.stopMove=function(){console.log("Should implement AMap.moveAnimation plugin first.")},z.prototype.pauseMove=function(){console.log("Should implement AMap.moveAnimation plugin first.")},z.prototype.resumeMove=function(){console.log("Should implement AMap.moveAnimation plugin first.")},z.prototype.setOptions=function(t){this._opts=_.assign({},Se,this._opts,t),t.content&&this.setContent(t.content),t.offset&&this.setOffset(t.offset),t.title&&this.setTitle(t.title),t.label&&this.setLabel(t.label),t.draggable&&this.setDraggable(!0),this.updateOverlay()},z.prototype.updateOverlay=function(t){Ie.prototype.updateOverlay.call(this,t=void 0===t?{}:t);t=this._y;this._opts.label&&t&&(!t.parentElement&&this.dom&&this.dom.appendChild(t),0<(t=void 0,t=this.v0())&&t<11&&this.My(),this.Ry())},z.prototype.emit=function(t,i){var n=this.getCursor();return this._map&&("mouseout"===t?this._map.setCursor():this._map.setCursor(n)),"click"===t?this.getClickable()&&(Ie.prototype.emit.call(this,t,i),void 0!==(n=this.getOptions().topWhenClick))&&n&&this.setTop(!0):("dragstart"!==t&&"dragging"!==t&&"dragend"!==t||(_.Support.$e||i.originEvent.buttons&&2!==i.originEvent.buttons&&i.originEvent.preventDefault(),this.getDraggable()))&&Ie.prototype.emit.call(this,t,i),this},z.prototype.toGeometry=function(){var t=this.getPosition();if(t)return{type:"Point",coordinates:t&&t.toJSON()}},z.prototype.v0=function(){var t=navigator.userAgent,i=-1<t.indexOf("compatible")&&-1<t.indexOf("MSIE"),n=-1<t.indexOf("Edge")&&!i,s=-1<t.indexOf("Trident")&&-1<t.indexOf("rv:11.0");return i?(new RegExp("MSIE (\\d+\\.\\d+);").test(t),7===(i=parseFloat(RegExp.$1))?7:8===i?8:9===i?9:10===i?10:6):n?"edge":s?11:-1},z.prototype.d0=function(){var t=this;new MutationObserver(function(){t._opts.label&&t.My()}).observe(this._y,{attributes:!0,characterData:!0,childList:!0,subtree:!0})},z.prototype._add=function(t){this._map=t,this._parent=t.pi,this.updateOverlay()},z.prototype._createDom=function(t,i){return this.dom=Ie.prototype._createDom.call(this,t,i),this.wy(),t},z.prototype._createDefaultInnerDom=function(){var t=document.createElement("img");return t.setAttribute("width","19px"),t.setAttribute("height","32px"),t.setAttribute("src",Ce.my),this._size=[19,32],t},z.prototype._getMarkerOffset=function(t,i){return i},z.prototype._getStyleZIndex=function(t){var i;return this._isTop?i=Ce.gy:void 0!==t&&(i=t),i},z.prototype._createIcon=function(n,s){var e=this,t=n.getImage(),i=n.getSize(),r=n.getImageSize(),h=n.getImageOffset(),o=document.createElement("div"),a=(o.className="amap-icon",o.style.overflow="hidden",document.createElement("img"));return a.onload=function(){var t=a.width,i=a.height,t=(n.Em([t,i]),e._size=r&&r.length?r:[t,i],e._getSize());e._setIconSize(o,a,t,r),s&&s()},a.onerror=function(){},o.appendChild(a),this._setIconStyle(o,a,{size:i,imageSize:r,imageOffset:h}),a.src=t,o},z.prototype._setIconStyle=function(t,i,n){var s=void 0===(s=n.size)?[0,0]:s,e=void 0===(e=n.imageSize)?[0,0]:e,n=void 0===(n=n.imageOffset)?[0,0]:n;i.style.top=n[1]+"px",i.style.left=n[0]+"px",this._setIconSize(t,i,s,e)},z.prototype._setIconSize=function(t,i,n,s){var e=n[0],n=n[1],r=s[0],s=s[1];e&&(t.style.width=e+"px"),n&&(t.style.height=n+"px"),r&&s&&(i.style.width=r+"px",i.style.height=s+"px")},z.prototype._removeContent=function(){this.dom.innerHTML="",this._opts.label&&this.setLabel(this._opts.label)},z.prototype._getD=function(){return this.dom},z.prototype.wy=function(){var t,i=this,s=(n=this._opts).content,e=n.icon,n=n.text;!s&&e?(t="string"==typeof e?new re({image:e}):e,t=this._createIcon(t,function(){i.updateOverlay(),i._opts.label&&i.My()}),this.dom.appendChild(t)):s||e||n||(t=this._createDefaultInnerDom(),this._originOpts.anchor||(this._opts.anchor="bottom-center"),this.dom.appendChild(t))},z.prototype.ky=function(t,i){return i||((i=document.createElement("div")).className="amap-marker-label"),i.innerHTML=t,i},z.prototype.My=function(){var t,i,n,s,e,r;this._y&&(r=this._style.size,i=(e=this._opts.label).offset,t=(i=_.oy(i=void 0===i?[0,0]:i)?i.toArray():i)[0],i=i[1],n=this._y.offsetWidth,s=this._y.offsetHeight,n=this.zy.size=[n,s],r=(e=[(s=this.Sy(e,r,n))[0]+t,s[1]+i])[0],this.zy.top=e[1],this.zy.left=r)},z.prototype.Sy=function(t,i,n){var t=t.direction,e=i[0],r=i[1],h=n[0],o=n[1],a=0,u=0;switch(void 0===t?"right":t){case ge.Nm:a=0,u=-o;break;case ge.top:case ge.$m:a=e/2-h/2,u=-o;break;case ge.Um:a=e,u=-o;break;case ge.right:case ge.Wm:a=e,u=r/2-o/2;break;case ge.center:a=e/2-h/2,u=r/2-o/2;break;case ge.left:case ge.Bm:a=-h,u=r/2-o/2;break;case ge.Gm:a=0,u=r;break;case ge.bottom:case ge.Zm:a=e/2-h/2,u=r;break;case ge.qm:a=e,u=r;break;default:a=e/2-h/2,u=-o}return[a,u]},z.prototype.Ry=function(){var i=(t=this.zy).top,t=t.left,n=this._y;n.style.top=i+"px",n.style.left=t+"px"},z.prototype._bindEvents=function(){this.on("dragstart",this.Cy.bind(this)),this.on("dragging",this._dragging.bind(this)),this.on("dragend",this.Ly.bind(this))},z.prototype.XH=function(){this.dom&&(this.dom.ondragstart=function(){return!1})},z.prototype.T_=function(){this.off("dragstart",this.Cy.bind(this)),this.off("dragging",this._dragging.bind(this)),this.off("dragend",this.Ly.bind(this))},z.prototype.ZH=function(){this.dom&&(this.dom.ondragstart=null)},z.prototype.Cy=function(t){this.Ay(t)},z.prototype._dragging=function(t){var n=(i=t.lnglat).lng,i=i.lat,n=new _.LngLat(n,i);this._map&&(this.setPosition(n.toJSON()),this.Ay(t))},z.prototype.Ly=function(t){},z.prototype.Ay=function(t){this._dragObjects={sy:t.pixel,hy:t.pos,ly:t.lnglat}};var Ie,De=z;function z(t){var i=Ie.call(this,t=void 0===t?{}:t,{className:Ce.vy})||this,n=(i.type=Ce.uy,i.className=Ce.uy,i._isTop=!1,i.zy={width:0,height:0,size:[0,0],top:0,left:0,translate:[0,0],zIndex:Ce.by},i._opts=_.assign({},Se,i._opts),i._opts.size),s=i._opts.icon;return!n&&s instanceof re&&(n=s.getSize(),i._opts.size=n),n instanceof _.Size&&(i._opts.size=i._formatSize(n)),t.title&&i.setTitle(t.title),t.label&&i.setLabel(t.label),t.draggable&&i.setDraggable(!0),(s=t.map)&&s instanceof ur&&i.add(s),i.XH(),i}var Oe,Re,Ee,C={getViewport:function(t){return t?[t.clientWidth,t.clientHeight]:[0,0]},getStyle:function(t,i){var n,s=t.style[i];return"auto"===(s=(s=(s=s&&"auto"!==s||!document.defaultView?s:(n=document.defaultView.getComputedStyle(t,null))?n[i]:null)&&"auto"!==s||"height"!==i?s:t.clientHeight+"px")&&"auto"!==s||"width"!==i?s:t.clientWidth+"px")?null:s},getViewportOffset:function(t){var i,n=0,s=0,e=t,r=document.body,h=document.documentElement;do{if(n+=e.offsetTop||0,s+=e.offsetLeft||0,n+=parseInt(C.getStyle(e,"borderTopWidth"),10)||0,s+=parseInt(C.getStyle(e,"borderLeftWidth"),10)||0,i=C.getStyle(e,"position"),e.offsetParent===r&&"absolute"===i)break;if("fixed"===i){n+=r.scrollTop||h.scrollTop||0,s+=r.scrollLeft||h.scrollLeft||0;break}}while(e=e.offsetParent);for(e=t;e!==r&&(n-=e.scrollTop||0,s-=e.scrollLeft||0,!C.m()&&_.Support.webkit&&(s+=e.scrollWidth-e.clientWidth),e=e.parentNode););return[s,n]},m:function(){return Oe||(Re="ltr"===C.getStyle(document.body,"direction"),Oe=!0),Re},create:function(t,i,n,s){return t=document.createElement(t),n&&(t.className=n),i&&(s&&"before"===s?(n=i.firstChild,i.insertBefore(t,n)):i.appendChild(t)),t},toggleClass:function(t,i,n){n?this.addClass(t,i):this.removeClass(t,i)},hasClass:function(t,i){if(t&&i)return 0<t.className.length&&new RegExp("(^|\\s)"+i+"(\\s|$)").test(t.className)},addClass:function(t,i){t&&i&&(t.classList&&t.classList.add?t.classList.add(i):this.hasClass(t,i)||(t.className+=(t.className?" ":"")+i))},setClass:function(t,i){t&&(t.className=i||"")},removeClass:function(t,n){t&&n&&(t.classList&&t.classList.remove?t.classList.remove(n):t.className=t.className.replace(/(\S+)\s*/g,function(t,i){return i===n?"":t}).replace(/(^\s+|\s+$)/,""))},watchSize:function(n,s,e){var i=document.createElement("iframe"),r=(i.style.cssText="width: 100%;height: 100%;position: absolute;pointEvents:none; opacity:0; margin: 0;padding: 0;border: none;",i.onload=function(){i&&(i.contentWindow.onresize=t)},n.appendChild(i),i.src="javascript:void(0)",0),h=0;function t(){e.k=n.getBoundingClientRect(),e.M=[n.clientLeft,n.clientTop];var t=n.offsetWidth,i=n.offsetHeight;t===r&&i===h||(s(t,i),r=t,h=i)}return t(),e.resize=t,window.onscroll=t,function(){var t;e.resize&&(e.resize=null),window.onscroll&&(window.onscroll=null),i.contentWindow&&(i.contentWindow.onresize=null,i.contentWindow.document.write(""),i.parentNode.removeChild(i),null!=(t=i.contentWindow))&&t.close()}},watchSize2:function(n,s,e){var r,h,o=document.createElement("_"),a=(o.className="expand",o.appendChild(document.createElement("_"))),u=(a.className="shrink",o.appendChild(document.createElement("_"))),t=(u.className="expandChild",a.appendChild(document.createElement("_")));return t.className="shrinkChild",a.style.cssText=o.style.cssText="height:100%;left:0;opacity:0;overflow:hidden;pointer-events:none;position:absolute;top:0;transition:0s;width:100%;z-index:-1",t.style.cssText=u.style.cssText="display:block;height:100%;transition:0s;width:100%",t.style.width=t.style.height="200%",n.appendChild(o),c(),function(){f(),n.removeChild(o)};function c(){f(),e.k=n.getBoundingClientRect(),e.M=[n.clientLeft,n.clientTop];var t=n.offsetWidth,i=n.offsetHeight;t===r&&i===h||(r=t,h=i,u.style.width=2*t+"px",u.style.height=2*i+"px",o.scrollLeft=o.scrollWidth,o.scrollTop=o.scrollHeight,a.scrollLeft=a.scrollWidth,a.scrollTop=a.scrollHeight,s(t,i)),a.addEventListener("scroll",c),o.addEventListener("scroll",c)}function f(){a.removeEventListener("scroll",c),o.removeEventListener("scroll",c)}},mousePos:function(t,i,n){return t&&(n.k=t.getBoundingClientRect(),n.M=[t.clientLeft,t.clientTop]),t=n.k,[(i=i.touches&&i.changedTouches?0<i.touches.length?i.touches[0]:i.changedTouches[i.changedTouches.length-1]:i).clientX-t.left-n.M[0],i.clientY-t.top-n.M[1]]},remove:function(t){t&&t.parentNode&&t.parentNode.removeChild(t)},empty:function(t){for(;t.firstChild;)t.removeChild(t.firstChild)},closest:function(t,i){return t?this.hasClass(t,i)?t:(t=t.parentElement)?C.closest(t,i):null:null},fillText:function(t,i){if(t)return void 0!==t.textContent?t.textContent=i:void 0!==t.innerText?t.innerText=i:t.innerHTML=i,t},_L:function(t){for(var i=document.documentElement.style,n=0;n<t.length;n+=1)if(t[n]in i)return t[n];return!1},rotate:function(t,i,n){var s,e=C.kL;n=n||{x:t.clientWidth/2,y:t.clientHeight/2},e?(s="",t.style[e]=s+=" rotate("+i+"deg)",t.style[C.ML[e]+"-origin"]=n.x+"px "+n.y+"px"):(s=Math.cos(i*Math.PI/180),e=Math.sin(i*Math.PI/180),t.style.filter="progid:DXImageTransform.Microsoft.Matrix()",0<t.filters.length&&((i=t.filters.item(0)).Dx=-n.x*s+n.y*e+n.x,i.Dy=-n.x*e-n.y*s+n.y,i.M11=i.M22=s,i.M12=-(i.M21=e)))},setCss:function(t,i){t=t instanceof Array?t:[t];for(var n=0;n<t.length;n+=1)for(var s in i)i.hasOwnProperty(s)&&(t[n].style[s]=i[s]);return this},setOpacity:function(t,i){t.style&&("opacity"in t.style?t.style.opacity=""+i:"filter"in t.style&&(i=Math.round(100*i),t.style.filter="",100!==i)&&(t.style.filter=" progid:DXImageTransform.Microsoft.Alpha(opacity="+i+")"))},ML:{},kL:Re=Oe=!1},Pe=(C.kL=C._L(["WebkitTransform","OTransform","MozTransform","msTransform","transform"]),C.ML={transform:"transform",WebkitTransform:"-webkit-transform",OTransform:"-o-transform",MozTransform:"-moz-transform",msTransform:"-ms-transform"},{uy:"AMap.InfoWindow",JP:"",XP:"amap-info",QP:121,KP:8,tF:8,iF:[20,20,20,20]}),je=_.assign({},we,{isCustom:!1,closeWhenClickMap:!1,anchor:"bottom-center",autoMove:!0,avoid:Pe.iF}),Be=(Ee=si,_.Ei(We,Ee),We.prototype.addToGroup=function(t){this.Iy&&this._overlays[this.Iy]&&this.Iy!==t.hS&&this._overlays[this.Iy].remove(),this.Iy=t.hS,Ee.prototype.addToGroup.call(this,t)},We.prototype.removeFromGroup=function(t){Ee.prototype.removeFromGroup.call(this,t),this.Iy=0},We.prototype.close=function(){var t=this.Iy;(t=this._overlays[t])&&(this.Iy=0,t.close())},We.prototype.vi=function(t){return t=t.target,this.Iy&&t&&C.closest(t,"amap-info")?this._overlays[this.Iy]:null},We.prototype.destroy=function(){this.Dy(),Ee.prototype.destroy.call(this)},We.prototype.Rm=function(){this._map.on("click",this.Py)},We.prototype.Dy=function(){this._map.off("click",this.Py)},We);function We(t){var n=Ee.call(this,t,{className:Pe.JP})||this;return n.type=Pe.uy,n.Py=function(t){var i=n.Iy,i=n._overlays[i];!C.closest(t.originEvent.target,"amap-info")&&i&&i.getOptions().closeWhenClickMap&&(n.Iy=0,i.close())},n._container=n._parent,n.Rm(),n}Fe=Pi,_.Ei(S,Fe),S.prototype.open=function(t,i){t&&t instanceof ur&&i?(this._opts.visible=!0,this.add(t),this.setPosition(i),this.jy(),this.emit("open"),this.GF()):t&&this._position?(this._opts.visible=!0,this.add(t),this.jy(),this.emit("open"),this.GF()):this._map&&this._position&&(this._opts.visible=!0,this.updateOverlay(),this.emit("open"),this.GF())},S.prototype.close=function(){this._parent&&(this._opts.visible=!1,this.updateOverlay(),this.emit("close"))},S.prototype.getIsOpen=function(){return!(!this._map||!this._opts.visible)},S.prototype.setSize=function(t){t instanceof _.Size&&(t=t.toArray()),this._opts.size=t,this.updateOverlay()},S.prototype.setContent=function(t){Fe.prototype.setContent.call(this,t=void 0===t?"":t),this.jy()},S.prototype.setAnchor=function(t){var i,n=this.dom&&this.dom.querySelector(".amap-info-contentContainer");t&&n&&((i=this.g_([].slice.call(n.className.split(" "))))&&C.removeClass(n,i),this._size=[0,0],C.addClass(n,t)),Fe.prototype.setAnchor.call(this,t)},S.prototype.getDraggable=function(){return!1},S.prototype.setOptions=function(t){this._opts=_.assign({},je,this._opts,t)},S.prototype.updateOverlay=function(t){void 0===t&&(t={}),this._map&&(t=t.viewChange,this._setStyle(t=void 0!==t&&t),this._applyStyle(t),t=this._getSize(),this.Fy)&&t[0]&&window.getComputedStyle(this.Fy).boxSizing},S.prototype.getBounds=function(){return null},S.prototype.getExtData=function(){return this._opts.extData||null},S.prototype.setExtData=function(t){this._opts.extData=t},S.prototype._add=function(t){this._map=t,this._parent=t.di,this.updateOverlay()},S.prototype._remove=function(){Fe.prototype._remove.call(this),this.Ey()},S.prototype._createDefaultInnerDom=function(){return document.createElement("div")},S.prototype._createDom=function(t,i){var n=this.Ny(t);return this.$y(n,i),t},S.prototype._getContentSize=function(){var t,i,n=this._style,s=this._getSize();s[0]&&s[1]&&!this._opts.isCustom?(t=s[0],i=s[1]):(s=this.dom.querySelector(".amap-info-contentContainer"))&&(t=s.clientWidth,i=s.clientHeight,this._size=[t,i]),n.width=t+"px",n.height=i+"px",n.size=[t,i]},S.prototype._getAnchorOffset=function(t){return[(t=Fe.prototype._getAnchorOffset.call(this,t))[0],t[1]]},S.prototype.Ny=function(t){var i=document.createElement("div"),n=(C.addClass(i,"amap-info-shadowContainer"),document.createElement("div"));return C.addClass(n,"amap-info-contentContainer"),n.addEventListener("touchstart",function(t){t.cH="infoWindow"}),t.style.position="absolute",i.style.position="absolute",t.appendChild(i),t.appendChild(n),n},S.prototype.$y=function(t,i){var s=(n=this._opts).isCustom,n=n.anchor;void 0!==s&&s?"object"==typeof i&&i instanceof HTMLElement?t.appendChild(i):t.innerHTML=i+"":(s=this.Fy=document.createElement("div"),C.addClass(s,"amap-info-content"),C.addClass(s,"amap-info-outer"),"object"==typeof i&&i instanceof HTMLElement?s.appendChild(i):s.innerHTML=i?i+"":"",i=document.createElement("a"),C.addClass(i,"amap-info-close"),i.innerText="×",s.appendChild(i),i=document.createElement("div"),C.addClass(i,"amap-info-sharp"),C.addClass(t,n),t.appendChild(s),t.appendChild(i))},S.prototype.jy=function(){var t=this.dom.querySelector(".amap-info-close");t&&t.addEventListener("click",this.close.bind(this))},S.prototype.Ey=function(){var t=this,i=this.dom.querySelector(".amap-info-close");i&&i.removeEventListener("click",function(){t.close()})},S.prototype.Oy=function(){if(this._position){var t=this._map;if(t&&this._opts.autoMove&&this.dom){for(var i=this._getSize(),n=new _.Size(i[0],i[1]),s=t.lngLatToContainer(this._position).toArray(),e=this._getOffset(this.getAnchor(),this.getOffset().toArray()),r=_.vector.add(s,e),h=_.vector.add(r,i),o=t.getSize(),a=[this._opts.avoid||Pe.iF],u=0,c=0,f=0;f<a.length;f+=1){var l=a[f],d=0,v=0;0!==l[3]&&0<(d=l[3]-(r[0]+u))&&(u+=d),0!==l[1]&&(d=o.getWidth()-l[1]-(h[0]+u))<0&&(u+=d),0!==l[0]&&0<(v=l[0]-(r[1]+c))&&(c+=v),0!==l[2]&&(v=o.getHeight()-l[2]-(h[1]+c))<0&&(c+=v)}r=_.vector.add(r,[u,c]),h=_.vector.add(h,[u,c]),r[e=s=0]<0||n.getWidth()>o.getWidth()?s=20-r[0]:o.getWidth()<h[0]&&(s=o.getWidth()-h[0]-25),r[1]<0||n.getHeight()>o.getHeight()?e=5-r[1]:o.getHeight()<h[1]&&(e=o.getHeight()-h[1]-15),e+=c,((s+=u)||e)&&t.panBy(s,e)}}},S.prototype.GF=function(){var t,i,n,s,e,r,h,o,a,u,c,f;this._position&&(t=this._map)&&this._opts.autoMove&&this.dom&&(i=this._position,_.Bs(i)&&(i=i.toArray()),o=(u=t.getSize()).getWidth()||0,u=u.getHeight()||0,c=this._getSize(),f=t.lngLatToContainer(i).toArray(),n=this._getOffset(this.getAnchor(),this.getOffset().toArray()),f=_.vector.add(f,n),a=_.vector.add(f,c),s=this._opts.avoid||Pe.iF,e=f[0],r=f[1],h=!1,f[1]-s[0]<0&&(r=s[0],h=!0),a[0]+s[1]>o&&(e=o-c[0]-s[1],h=!0),a[1]+s[2]>u&&(r=u-s[2]-c[1],h=!0),f[0]-s[3]<0&&(e=s[3],h=!0),h)&&(o=_.vector.Ip([e,r],n),a=t.containerToLngLat(o).toArray(),u=_.vector.Ip(a,i),c=t.getCenter().toArray(),f=_.vector.Ip(c,u),t.panTo(f))},S.prototype.g_=function(t){var i,n,s=ge;for(n in s)if(s.hasOwnProperty(n)){var e=s[n];if(-1!==t.indexOf(e)){i=e;break}}return i};var Fe,Ge=S;function S(t){(t=Fe.call(this,t=void 0===t?{}:t,{className:Pe.XP,anchor:je.anchor})||this).type=Pe.uy,t._opts=_.assign({},je,t._opts),t._originOpts.zIndex||(t._opts.zIndex=Pe.QP);var i=t._opts.size;return i instanceof _.Size&&(t._opts.size=t._formatSize(i)),t.jy(),t}var Ne,_e="AMap.ContextMenu",Je=(Ne=si,_.Ei(He,Ne),He.prototype.addToGroup=function(t){this.Iy&&this._overlays[this.Iy]&&this.Iy!==t.hS&&this._overlays[this.Iy].remove(),this.Iy=t.hS,Ne.prototype.addToGroup.call(this,t)},He.prototype.removeFromGroup=function(t){Ne.prototype.removeFromGroup.call(this,t),this.Iy=0},He.prototype.vi=function(t){return t=t.target,this.Iy&&t&&w.closest(t,"amap-menu")?this._overlays[this.Iy]:null},He.prototype.destroy=function(){this.Uy(),Ne.prototype.destroy.call(this)},He.prototype.By=function(){this._map.on("viewchange",this.Wy),this._map.on("click",this.Py)},He.prototype.Uy=function(){this._map.off("viewchange",this.Wy),this._map.off("click",this.Py)},He);function He(t){var n=Ne.call(this,t,{className:""})||this;return n.type=_e,n.className=_e,n.Wy=function(){var t;n.Iy&&(t=n._overlays[n.Iy])&&!t.getOptions().aliveWhenMapClick&&n.removeFromGroup(t)},n.Py=function(t){var i=n.Iy,i=n._overlays[i];w.closest(t.originEvent.target,"amap-info")||!i||i.getOptions().aliveWhenMapClick||(n.Iy=0,i.close())},n._container=n._parent,n.By(),n}Ve=Pi,_.Ei(Ke,Ve),Ke.prototype.open=function(t,i){t&&i?(this._opts.visible=!0,this.add(t),this.setPosition(i),this.emit("open")):this._map&&this._position&&(this._opts.visible=!0,this.updateOverlay(),this.emit("open"))},Ke.prototype.close=function(){this._parent&&(this._opts.visible=!1,this.uZ(),this.emit("close"))},Ke.prototype.addItem=function(t,i,n){this.Zy.push({content:t,fn:i,order:n}),this.qy(this.dom),this.updateOverlay()},Ke.prototype.removeItem=function(t,i){for(var n=this.Zy,s=0;s<n.length;s++){var e=n[s];e.content===t&&e.fn===i&&(n.splice(s,1),s--)}this.qy(this.dom),this.updateOverlay()},Ke.prototype.getBounds=function(){return null},Ke.prototype.getDraggable=function(){return!1},Ke.prototype._add=function(t){this._map=t,this._parent=t.vm,this.updateOverlay()},Ke.prototype._createDefaultInnerDom=function(){return document.createElement("div")},Ke.prototype._createDom=function(t,i){var n=this.dom=this.Yy();return this._opts.isCustom&&this._opts.content?Ve.prototype._createDom.call(this,n,this._opts.content):this.qy(n),n},Ke.prototype.Yy=function(){var t=document.createElement("div");return w.addClass(t,this._className),t},Ke.prototype.qy=function(t){var i=this.Vy(this.Zy),n=document.createElement("ul");w.addClass(n,"amap-menu-outer");for(var s=0,e=i;s<e.length;s++){var r=e[s],r=this.Xy(r);n.appendChild(r)}t.innerHTML="",t.appendChild(n)},Ke.prototype.Vy=function(t){return(t=void 0===t?[]:t).sort(function(t,i){return isNaN(t.order)||isNaN(i.order)?0:t.order-i.order}),t},Ke.prototype.Xy=function(i){var n=this,t=document.createElement("li");return t.innerHTML=i.content,t.addEventListener("click",function(t){i.fn(t),n._opts.aliveWhenMapClick||n.hide()}),t};var Ve,qe=Ke;function Ke(t){var i=Ve.call(this,t=void 0===t?{}:t,{className:"amap-menu"})||this;return i.type=_e,i.className=_e,i._opts={},i.Zy=[],i._opts=t,i._style.zIndex=140,i}function Qe(){this.Hy=!1,this.ex=null,this.Ky=this.nx()}Qe.prototype.open=function(t,i,n){var s,e,r,h,o,a,u,c,f,l=this;this.Hy||(s=this.Jy,e=AMap.getConfig().server+"/verify/",(_.Support.$e?(this.Ky.style.marginLeft=-Math.min(330,screen.width)/2+"px",document.body):(r=this.Qy("amap-container",document.body)[0])&&322<r.clientWidth&&346<r.clientHeight?(this.Ky.style.position="absolute",r):(o=h=0,r&&(r=w.getViewportOffset(r),h=r[0],o=r[1]),this.Ky.style.top="0%",this.Ky.style.left="0%",a=(.5-h)/5,u=(.5-o)/5,c=setInterval(function(){o+=u,.5-(h+=a)<.05&&.5-o<.05?(l.Ky.style.top="50%",l.Ky.style.left="50%",clearInterval(c)):(l.Ky.style.top=100*o+"%",l.Ky.style.left=100*h+"%")},25),document.body)).appendChild(this.Ky),f=!0,s.onload=function(){f?f=!1:l.Hy&&(l.Ky.parentNode&&l.Ky.parentNode.removeChild(l.Ky),l.Hy=!1,l.tx())},s.src=e+"jsapi.html?channel=JSAPI-"+t+"&from="+encodeURIComponent(e+"success.html")+"&th="+i+"&restUrl="+encodeURIComponent(n),this.Hy=!0)},Qe.prototype.ix=function(t){this.ex=t},Qe.prototype.tx=function(){this.ex&&this.ex()},Qe.prototype.Qy=function(t,i){if(window.getElementsByClassName)return window.getElementsByClassName(t,i);for(var n=(i||document).getElementsByTagName("*"),s=[],e=0;e<n.length;e+=1)for(var r=n[e],h=r.className.split(" "),o=0;o<h.length;o+=1)if(h[o]===t){s.push(r);break}return s},Qe.prototype.nx=function(){var t=document.createElement("div"),i=(t.className="amap-popup",t.style.zIndex="2147483647",document.createElement("iframe"));return i.className="amap-popup-content",t.appendChild(i),i.style.width=Math.min(330,screen.width)+"px",this.Jy=i,t};var $e={"restapi.amap.com/v3/place/text":"KEYWORD","restapi.amap.com/v3/place/polygon":"POLYGON","restapi.amap.com/v3/place/around":"NEARBY","restapi.amap.com/v3/place/detail":"ID","restapi.amap.com/v3/geocode/regeo":"REGEO"},tr=new Qe,ir=(tr.ix(function(){ir.ox=!1;for(var t=ir.ax,i=0,n=t.length;i<n;i+=1){var s=t[i];10<n-i?t[2]({status:"error",info:"TIME_OUT_A"}):ir.get(s[0],s[1],s[2])}ir.ax=[]}),nr.get=function(n,s,e,t){if(void 0===t&&(t={}),nr.ox)nr.ax.push([n,s,e]);else{var i,r=n.split("://")[1],h=$e[r],o=void 0!==h,u=(a=AMap.getConfig()).key,c=a.version,f=a.appname,l=a.jscode,a=a.gaodeserver,d=n+"?platform=JS&s=rsv3&logversion=2.0&key="+u+"&sdkversion="+c+"&appname="+f+"&csid="+_.Util.uuid();for(i in l?d+="&jscode="+l:a&&r&&"restapi.amap.com"===r.split("/")[0]&&(d=r.replace(r.split("/")[0],a)+"?platform=JS&s=rsv3&logversion=2.0&key="+u+"&sdkversion="+c+"&appname="+f+"&csid="+_.Util.uuid()),s)s.hasOwnProperty(i)&&(d+="&"+i+"="+s[i]);yi.JSONP(d,function(t,i){"complete"===t&&(i=i.data,o)&&3e4===i.errcode&&i.data?(nr.ox=!0,nr.ax.push([n,s,e]),tr.open(h,i.data.host,d)):e(t,i)},t)}},nr.post=function(t,i,n){var e=(s=AMap.getConfig()).key,r=s.version,h=s.appname,o=s.jscode,s=s.gaodeserver,a=t.split("://")[1],t=t+"?platform=JS&s=rsv3&logversion=2.0&key="+e+"&sdkversion="+r+"&appname="+h+"&csid="+_.Util.uuid();o?t+="&jscode="+o:s&&a&&"restapi.amap.com"===a.split("/")[0]&&(t=a.replace(a.split("/")[0],s)+"?platform=JS&s=rsv3&logversion=2.0&key="+e+"&sdkversion="+r+"&appname="+h+"&csid="+_.Util.uuid()),yi.Ajax(t,{type:"POST",content:JSON.stringify(i),requestContentType:"text/plain"},function(t,i){"complete"===t?(i=i.data,n(t,JSON.parse(i))):n(t,i)})},nr.ox=!1,nr.ax=[],nr);function nr(){}function sr(t,i,r){var n=AMap.getConfig(),s=n.server+"/v3/assistant/coordinate/convert",e=AMap.Util.parseLngLatData(t),h=[];if(e instanceof Array){for(var o=0,a=e.length;o<a;o+=1)h.push(e[o]+"");h=h.join(";")}else h=e+"";t={key:n.key,s:"rsv3",locations:h,coordsys:i||"gps"},AMap.WebService.get(s,t,function(t,i){if("complete"===t&&i.status&&"1"===i.status){for(var n=i.locations.split(";"),s=0;s<n.length;s+=1){var e=n[s].split(",");n[s]=new AMap.LngLat(e[0],e[1])}r&&"function"==typeof r&&r("complete",{info:"ok",locations:n})}else r&&"function"==typeof r&&r("error",i.info);"error"===t&&r("error",i.info)})}hr.prototype.setCenter=function(t){t instanceof _.LngLat?this.cB=t.toArray():this.cB=t,this.dB=(t=this.map.getProjection()).project.apply(t,this.cB)},hr.prototype.getCenter=function(){return this.cB},hr.prototype.lngLatToCoord=function(t){var i=this.map.getProjection().project;return t instanceof _.LngLat&&(t=t.toArray()),this.cB||this.setCenter(t),this.pB(i(t[0],t[1]),this.dB)},hr.prototype.lngLatsToCoords=function(t){if(_.Util.isArray(t)){var i=this.map.getProjection().project,n=[];if(_.Util.vB(t[0]))this.cB||this.setCenter(t),n[0]=this.pB(i(t[0],t[1]),this.dB);else for(var s=0,e=t.length;s<e;s++){var r=t[s];if(_.Util.vB(r[0]))this.cB||this.setCenter(r),n[s]=this.pB(i(r[0],r[1]),this.dB);else{for(var h=[],o=0,a=r.length;o<a;o++){var u=r[o];if(_.Util.vB(u[0]))this.cB||this.setCenter(u),h[o]=this.pB(i(u[0],u[1]),this.dB);else{for(var c=[],f=0,l=r.length;f<l;f++){var d=u[f];_.Util.vB(d[0])&&(this.cB||this.setCenter(d),c[f]=this.pB(i(d[0],d[1]),this.dB))}h[o]=c}}n[s]=h}}return 0<n.length?n:t}return t},hr.prototype.getCameraParams=function(){this.mB();var t,i,n,s,e,r,h,o=this.map.getView(),a=o.pz(),u=this.pB(this.dB,this.Us);return"3D"===o.type?(t=(e=a.lB()).fov,n=e.near,s=e.far,h=e.position,i=e.target,e=e.up,{fov:t/Math.PI*180,near:n,far:s,position:_.Pt(this.pB(h,u),[h[2]]),lookAt:_.Pt(this.pB(i,u),[i[2]]),up:e}):"2D"===o.type?(i=(t=a.lB()).rotation,n=t.near,s=t.far,e=t.top,o=t.bottom,a=t.left,r=t.right,h=t.position,{rotation:i,near:n,far:s,top:e,bottom:o,left:a,right:r,position:_.Pt(this.pB(h,u),[h[2]])}):void 0},hr.prototype.getMVPMatrix=function(){this.mB();var t=this.map.getView().pz(),i=this.pB(this.dB,this.Us),n=_.Il();return this.Xl=t.Vl(),n.set([1,0,0,0,0,1,0,0,0,0,1,0,i[0],i[1],0,1]),_.multiply(this.Xl,this.Xl,n),this.Xl},hr.prototype.mB=function(){var i=(t=this.map.getView().getStatus()).optimalZoom,t=t.centerCoord;i>=_.Ra?(i=_.lcs.getLocalByCoord([t[0],t[1]]),this.Us=i.center):this.Us=[0,0]},hr.prototype.pB=function(t,i){var n=[0,0];return n[0]=t[0]-i[0],n[1]=t[1]-i[1],n};var er,rr=hr;function hr(t){this.Us=[0,0],t||console.error("需要传入 map 实例对象。new AMap.CustomCoords(map);"),this.map=t,this.mB()}var or=[116.397128,39.916527],ar=ne;_.Ei(T,ar),T.prototype.setCenter=function(t,i,n){void 0===i&&(i=!1),t instanceof _.LngLat&&(t=t.toJSON()),!i&&this.Ev?this.viewChange({lng:t[0],lat:t[1]},n):this.om({center:t})},T.prototype.getStyleByUserId=function(t,i){return this.qY(t,i)},T.prototype.getCustomTypeByContainerPos=function(t){var i,n,s,e=this.getCustomTypeByPos(t);return e&&e[0]?(i={},s=e[0][0],e={x:e[0][1],y:e[0][2],z:s},n=(t=t.lnglat).lng,t=t.lat,s=_.ZY(s,s,n,t,e),i.tileInnerCoord=s,i.tileCoord=e,i):null},T.prototype.getScreenShot=function(t,i){for(var n=this.getSize(),s=document.createElement("canvas"),e=s.getContext("2d"),r=(t=t||n.width,i=i||n.height,s.width=t,s.height=i,n.width,n.height,this.do.childNodes),h=[],o=0;o<r.length;o+=1)h.push(r[o]);for(o=0;o<h.length;o+=1){var a=h[o];"CANVAS"===a.tagName&&e.drawImage(a,0,0,t,i)}return s.toDataURL()},T.prototype.updateView=function(t,i){this.om(t,i=void 0===i||i)},T.prototype.destroy=function(){delete this.hx,ar.prototype.destroy.call(this)},T.prototype.setZoomAndCenter=function(t,i,n,s){void 0===n&&(n=!1),this.Pv||(t=this.getZoom()),i instanceof _.LngLat&&(i=i.toJSON()),!n&&this.Ev?this.viewChange({lng:i[0],lat:i[1],zoom:t},s):this.om({center:i,zoom:t})},T.prototype.getBounds=function(){return new l(this._view.getStatus().bounds)},T.prototype.getCenter=function(){var i=(t=this._view.getOptions().center)[0],t=t[1];return new _.LngLat(+i.toFixed(6),+t.toFixed(6))},T.prototype.getGraphicInfo=function(){return this.wX()},T.prototype.setZoom=function(t,i,n){void 0===i&&(i=!1),this.Pv&&(!i&&this.Ev?this.viewChange({zoom:t},n):this.om({zoom:t}))},T.prototype.getZoom=function(t){return void 0===t&&(t=2),+this._view.getOptions().zoom.toFixed(t)},T.prototype.zoomIn=function(){this.setZoom(this.getZoom()+1)},T.prototype.zoomOut=function(){this.setZoom(this.getZoom()-1)},T.prototype.getPitch=function(){return this._view.getOptions().pitch},T.prototype.setPitch=function(t,i,n){!(i=void 0!==i&&i)&&this.Ev?this.viewChange({pitch:t},n):this.om({pitch:t})},T.prototype.getRotation=function(){return this._view.getOptions().rotation},T.prototype.setRotation=function(t,i,n){void 0===t&&(t=0),!(i=void 0!==i&&i)&&this.Ev?this.viewChange({rotation:t},n):this.om({rotation:t})},T.prototype.setBounds=function(t,i,n){void 0===i&&(i=!1),n=(void 0===n?[0,0,0,0]:n)||[0,0,0,0],t instanceof l&&(t=t.toJSON()),t=this.em(t,n),this.setZoomAndCenter(t[2],[t[0],t[1]],i)},T.prototype.panTo=function(t,i){t instanceof _.LngLat&&(t=t.toJSON()),this.viewChange({lng:t[0],lat:t[1]},i)},T.prototype.getBindHandler=function(){return this.hx},T.prototype.panBy=function(t,i,n){var s,e,r,h,o,a,u,c,l=(f=this.getSize()).width/2-t,f=f.height/2-i,d=this.getCenter();this.lx&&this.ux&&(s=Math.sqrt(t*t+i*i),u=this.getProjection(),e=(void 0===this.ux.lng?d:this.ux).lng,d=(void 0===this.ux.lat?d:this.ux).lat,r=void 0===this.ux.zoom?this.getZoom():this.ux.zoom,h=void 0===this.ux.rotation?this.getRotation():this.ux.rotation,o=void 0===this.ux.pitch?this.getPitch():this.ux.pitch,a=u.getResolution(r),u=u.project(e,d),c=h/180*Math.PI,t=Math.atan(t/i)-c,i<0&&(t+=Math.PI),c=s*Math.sin(t),i=s*Math.cos(t),u[0]-=a*c,u[1]+=a*i,this.setCenter([e,d],!0),this.setZoom(r,!0),this.setRotation(h,!0),this.setPitch(o,!0)),this.panTo(this.containerToLngLat([l,f]),n)},T.prototype.viewChange=function(t,i){var n,s,e,r,h,o,a,u=new H(.4,0,.15,1),c=(new H(.67,0,1,.42),new H(.95,.25,.79,1)),f=new H(.18,.66,.55,.86),l=this.getZoom(),d=this.getPitch(),v=this.getRotation(),p=this.getCenter().toJSON(),m=0,y=0,b=0,g=0;this.lx?(_.Util.cancelAnimFrame(this.lx),this.ux=_.assign(this.ux,t)):this.ux=t;var M=(t=this.ux).zoom,k=t.pitch,w=t.rotation,x=t.lng,A=t.lat,z=(void 0!==M&&(n=M-l,m=u.h(Math.abs(n/10)),m=1e3*Math.max(Math.min(1,m),.1)),void 0!==k&&(s=k-d,y=Math.abs(16.7*s)),void 0!==w&&(e=w-v,b=Math.abs(16.7*e)),void 0!==x&&void 0!==A&&(t=[],a=this._view.getStatus().centerCoord,r=x-p[0],h=A-p[1],o=this.getProjection().project(x,A),t[0]=Math.abs(o[0]-a[0])/this.getResolution(),t[1]=Math.abs(o[1]-a[1])/this.getResolution(),0,o=u.h(Math.min(t[0]/this.getSize().width,1)),a=u.h(Math.min(t[1]/this.getSize().height,1)),g=1e3*Math.max(Math.min(1,a,o),.05,o,a)),Math.max(m,y,b,g)),C=0;function S(){var t,i={};z<=C?(void 0!==M&&(i.zoom=M),void 0!==k&&(i.pitch=k),void 0!==w&&(i.rotation=w),void 0!==x&&void 0!==A&&(i.center=[x,A]),this.om(i),_.Util.cancelAnimFrame(this.lx),this.lx=!1,this.ux={}):(C+=16.7,t=Math.min(1,u.p(C/z)),void 0!==k&&(i.pitch=s*t+d),void 0!==w&&(i.rotation=e*t+v),void 0!==x&&void 0!==A&&(n&&.5<n?t=f.h(C/z):n&&n<-.5&&(t=c.h(C/z)),i.center=[r*t+p[0],h*t+p[1]]),void 0!==M&&(t=(n<0?f:c).h(C/z),i.zoom=n*t+l),this.om(i),this.lx=_.Util.requestAnimFrame(S.bind(this)))}void 0!==i&&(z=i),this.Ev||(z=-1),S.call(this)},T.prototype.getContainer=function(){return this.kv},T.prototype.add=function(t){for(var i=[],n=[],s=[],e=[],r=0,h=t=Array.isArray(t)?t:[t];r<h.length;r++){var o=h[r];if(_.px(o))this.addLayer(o);else if(_.er(o))_.RF(o)?(this.add(o.getOverlays()),o.setMap(this)):this.am(o);else switch(o.type){case"AMap.Marker":case"AMap.ElasticMarker":case"AMap.Text":i.push(o);break;case"AMap.InfoWindow":n.push(o);break;case"AMap.ContextMenu":s.push(o);break;case"AMap.LabelMarker":e.push(o)}}this.pi.add(i),this.di.add(n),this.vm.add(s),e.length&&this.rm().add(e),this.setNeedUpdate(!0)},T.prototype.remove=function(t){for(var i=[],n=[],s=[],e=[],r=0,h=t=Array.isArray(t)?t:[t];r<h.length;r++){var o=h[r];if(_.er(o))_.RF(o)?(this.remove(o.getOverlays()),o.setMap(null)):this.$F.remove(o);else if(_.px(o))this.removeLayer(o);else switch(o.type){case"AMap.Marker":case"AMap.ElasticMarker":case"AMap.Text":i.push(o);break;case"AMap.InfoWindow":n.push(o);break;case"AMap.ContextMenu":s.push(o);break;case"AMap.LabelMarker":e.push(o)}}e.length&&this.rm().remove(e),this.pi&&this.pi.remove(i),this.di&&this.di.remove(n),this.vm&&this.vm.remove(s),this.setNeedUpdate(!0)},T.prototype.lngLatToCoords=function(t){var i;return _.Bs(t)&&(t=[t.lng,t.lat]),(i=this.getProjection()).project.apply(i,t)},T.prototype.coordsToLngLat=function(t){var i=(i=this.getProjection()).unproject.apply(i,t);return new AMap.LngLat(i[0],i[1])},T.prototype.lngLatToContainer=function(t){var i=(t=_.Bs(t)?[t.lng,t.lat]:t)[0],n=t[1],t=void 0===(t=t[2])?0:t,s=this._view,e=s.getOptions().zoom||this.xt[1],i=(s=s.lnglatToContainer(+i,+n,t,e))[0],n=s[1];return new _.Pixel(i,n)},T.prototype.lnglatToContainer=function(){console.log&&console.log("请使用 lngLatToContainer 方法替代。")},T.prototype.containerTolnglat=function(){console.log&&console.log("请使用 containerToLngLat 方法替代。")},T.prototype.containerToLngLat=function(t){var t=t instanceof Array?(i=t[0],t[1]):(i=t.x,t.y),t=(i=this._view.containerTolnglat(i,t))[0],i=i[1];return new _.LngLat(t,i)},T.prototype.coordToContainer=function(t){var i;return(i=this._view)._u.apply(i,t)},T.prototype.containerToCoord=function(t){return t instanceof _.Pixel&&(t=t.toArray()),this._view.ku(t[0],t[1])},T.prototype.pixelToLngLat=function(t,i){void 0===i&&(i=this.getZoom()),t=t instanceof Array?(n=t[0],t[1]):(n=t.x,t.y);var n=_.V[this._view.au()].unproject(n,t,i),t=n[0],i=n[1];return new _.LngLat(t,i)},T.prototype.pixelTolnglat=function(){console.log&&console.log("请使用 pixelToLngLat 方法替代。")},T.prototype.unproject=function(){console.log&&console.log("请使用 pixelToLngLat 方法替代。")},T.prototype.lngLatToPixel=function(t,i){var n=(t=t instanceof _.LngLat?t.toJSON():t)[0],t=t[1];void 0===i&&(i=this.getZoom());t=(n=_.V[this._view.au()].project(n,t,i))[0],i=n[1];return new _.Pixel(t,i)},T.prototype.project=function(t,i){return console.log&&console.log("请使用 lngLatToPixel 方法替代。"),this.lngLatToPixel(t,i)},T.prototype.lnglatToPixel=function(t,i){return console.log&&console.log("请使用 lngLatToPixel 方法替代。"),this.lngLatToPixel(t,i)},T.prototype.lnglatToPixelArray=function(t,i){var n=(t=t instanceof _.LngLat?t.toJSON():t)[0],t=t[1];return void 0===i&&(i=this.getZoom()),_.V[this.getView().au()].project(n,t,i)},T.prototype.getTileCoordByLngLat=function(t,i,n){var s=(t=t instanceof _.LngLat?t.toJSON():t)[0],t=t[1],s=_.V[this.getView().au()].project(s,t,n),t=Math.floor(s[0]/256),s=Math.floor(s[1]/256);return new _.ca(n,t,s)},T.prototype.addOverlay=function(t){this.am(t),this.setNeedUpdate(!0)},T.prototype.removeOverlay=function(t){this.ar(t),this.setNeedUpdate(!0)},T.prototype.getResolution=function(t){return t=(t||this.getCenter()).kT,this.getProjection().getResolution(this.getZoom())*Math.cos(t*Math.PI/180)},T.prototype.getScale=function(t){return this.getResolution()*(t||96)/.0254},T.prototype.getCity=function(n,t){ir.get(AMap.getConfig().server+"/v3/geocode/regeo",{extensions:"",output:"json",location:t||this.getCenter().toJSON()},function(t,i){"complete"===t&&i.status+""=="1"?(t=i.regeocode.addressComponent,n({province:t.province,city:t.city instanceof Array?"":t.city,citycode:t.citycode instanceof Array?"":t.citycode,district:t.district instanceof Array?"":t.district})):n({})})},T.prototype.setCity=function(r,h){var o=this;ir.get(AMap.getConfig().server+"/v3/config/district",{output:"json",subdistrict:"0",extensions:"all",keywords:r},function(t,i){if("complete"===t&&i.status+""=="1"){if((t=i.districts)&&t.length){i=t[0],/[^\w]+/.test(r)&&(t=_.find(t,function(t){return t.name===r}))&&t!==i&&(i=t);try{var n=i.center.split(","),s=i.level,e=void 0;switch(s){case"city":e=10;break;case"province":e=7;break;case"district":e=12;break;case"country":e=4;break;default:e=12}-1!==i.name.indexOf("市")&&(e=10),o.setZoomAndCenter(e,n),h&&h.call(o,n,e)}catch(t){}}}else h(null,null)})},T.prototype.setFitView=function(t,i,n,s){if(void 0===i&&(i=!1),void 0===n&&(n=[60,60,60,60]),void 0===s&&(s=Math.min(17.5,ne.t_[1])),!((t=_.FF(t)?t.getAllOverlays():t)instanceof Array&&0===t.length)){n=Boolean(n)?n:[60,60,60,60],(t=!(t=t||[])||t instanceof Array?t:[t])&&0!==t.length||(t=this.getAllOverlays());var e,r,t=this.nm(t);if(t&&(!window._AMapConfig||t.check()))return e=t.toJSON(),e=this.em(e,n,s),"d"===_.Support.baseRender&&(e[2]=Math.floor(e[2])),this.viewChange({lng:e[0],lat:e[1],zoom:e[2]},r=i?0:r),t}},T.prototype.getFitZoomAndCenterByOverlays=function(t,i,n){if(void 0===i&&(i=[0,0,0,0]),void 0===n&&(n=_.zoomRange[1]),t=this.nm(t))return t=t.toJSON(),[(t=this.em(t,i,n))[2],new _.LngLat(t[0],t[1])]},T.prototype.getFitZoomAndCenterByBounds=function(t,i,n){return void 0===i&&(i=[0,0,0,0]),void 0===n&&(n=_.zoomRange[1]),t instanceof l&&(t=t.toJSON()),[(t=this.em(t,i,n))[2],new _.LngLat(t[0],t[1])]},T.prototype.addControl=function(t){t.addTo(this),this.controls.push(t)},T.prototype.removeControl=function(t){t.remove?t.remove():t.removeFrom&&t.removeFrom(this,this.controls);for(var i=0;i<this.controls.length;i++)if(this.controls[i]===t)return void this.controls.splice(i-1,1)},T.prototype.L$=function(){},T.prototype.D$=function(){return"zh_cn"},T.prototype.set=function(t,i){switch(t){case"layers":this.setLayers(i);break;case"projection":break;case"pitch":this.setPitch(i);break;case"debug":this.debug=i;break;case"showLabel":this.showLabel=i;break;case"zoom":this.setZoom(i);break;case"center":this.setCenter(i);break;case"rotation":this.setRotation(i);break;case"dragEnable":this.setStatus({dragEnable:i});break;case"zoomEnable":this.setStatus({zoomEnable:i});break;case"scrollWheel":this.setStatus({scrollWheel:i});break;case"jogEnable":this.setStatus({jogEnable:i});break;case"doubleClickZoom":this.setStatus({doubleClickZoom:i});break;case"keyboardEnable":this.setStatus({keyboardEnable:i});break;case"animateEnable":this.setStatus({animateEnable:i});break;case"pitchEnable":this.setStatus({pitchEnable:i});break;case"touchZoom":this.setStatus({touchZoom:i});break;case"isHotspot":this.setStatus({isHotspot:i});break;case"style":this.setStyleByPlat(i)}},T.prototype.setMapStyle=function(t){this.f_(t),this.setStatus({mapStyle:t}),this.indoorMap&&this.indoorMap.hide()},T.prototype.getMapStyle=function(){var t,i=this.getStatus();return i&&i.mapstyleUrl?(t=i.mapstyleUrl,"normal"===i.mapstyleUrl?"amap://styles/normal":t):""},T.prototype.getAllOverlays=function(i){var t=this.$F.getAllOverlays(),n=_.Pt(t),t=this.pi.getAllOverlays(),s=this.di.getAllOverlays();_.vx(t,function(t){n.push(t)}),s&&s.length&&_.Util.Ig(n,s);for(var e=0,r=this.zv;e<r.length;e++){var h=r[e];h instanceof ms&&_.Util.Ig(n,h.getAllOverlays())}return n=n.filter(function(t){return!(t._opts&&t._opts.innerOverlay||i&&!(-1<t.className.toLocaleLowerCase().indexOf(i)))})},T.prototype.clearMap=function(){for(var t=this.getAllOverlays(),i=0;i<t.length;i++){var n=t[i];n&&n.remove&&n.remove()}},T.prototype.clearInfoWindow=function(){this.di&&this.di.close()},T.prototype.addImage=function(t,i){this.I_&&this.I_.addImage(t,i)},T.prototype.getImage=function(t){if(this.I_)return this.I_.getImage(t)},T.prototype.getFeatures=function(){return this.Cw},T.prototype.setFeatures=function(t){this.Cw=t;for(var i=this.yS(),n=this.getLayers(),s=0;s<n.length;s++){var e=n[s];"AMap.Buildings"===e.CLASS_NAME&&e.getState().u$&&(i?e.show():e.hide())}this.setNeedUpdate(!0)},T.prototype.hasLayer=function(i){var t=this.getLayers();return-1<_.findIndex(t,function(t){return t===i})},T.prototype.getMapApprovalNumber=function(){var t=this.c_,i={satellite:"GS(2021)6342",district:"GS(2021)6375"};return t&&("normal"===t||"amap://styles/normal"===t)||(i.base="GS(2021)6375"),i},T.prototype.setMask=function(t){t&&(this.c$=t,this.d$||(this.d$=new As({zIndex:-10,visible:!0,path:this.c$}),this.addLayer(this.d$)),null!=(t=this.d$))&&t.setMask(this.c$)},T.prototype.cancelMapAnimate=function(){this.lx&&(_.Util.cancelAnimFrame(this.lx),this.lx=-1,this.ux={})},T.prototype.setLabelRejectMask=function(t){void 0!==t&&(this.NH=t,this.setNeedUpdate(!0))},T.prototype.queryOverlayByPosition=function(t){return this.FY(t)},T.prototype.am=function(t){this.$F.add(t)},T.prototype.ar=function(t){this.sm().remove(t)},T.prototype.setStyle=function(t){this.RY(t)},T.prototype.setStyleByPlat=function(t){this.RY(t)};var ar,cr,ur=T;function T(t,i){void 0===i&&(i={zoom:9,center:[116.397128,39.916527],rotation:0,pitch:0,viewMode:"2D"});var n=this,s=null;if(null===(s=t instanceof HTMLDivElement||null!==(t=document.getElementById(t))?t:s))throw Error("Map container div not exist");_.Support.amapRunTime&&!_.Support.amapRunTime["map-init"]&&(_.Support.amapRunTime["map-init"]=(new Date).getTime()),i.zooms=i.zooms||ne.t_,t=!1,void 0===i.zoom&&(t=!0,i.zoom=Math.max(Math.min(i.zooms[1],12),i.zooms[0])),i.center=i.center?_.Bs(i.center)?i.center.toJSON():i.center:or,i.rotation=i.rotation||0,i.layers=i.layers||[new AMap.VectorLayer()],i.baseRender=_.Support.isWebGL?"w":"d",i.showIndoorMap=i.showIndoorMap||!1,i.vectorMapForeign=i.vectorMapForeign||!1,i.overseaDataType=i.overseaDataType||"",i.vdataProxy=i.vdataProxy||"",i.poiIcon=i.poiIcon||void 0,i.vdataProxy&&(AMap.getConfig().vdataProxy=i.vdataProxy),n=ar.call(this,s,i)||this,t&&(s=n.em(er)[2],n.setZoom(s,!0)),n.pi=new Te(n),n.di=new Be(n),n.vm=new Je(n),n.hx=new ot(n),n.hx.Xt(),n.plugin=AMap.plugin;for(var e=0;e<i.layers.length;e++){var r=i.layers[e];r&&"AMap.IndoorMap"===r.CLASS_NAME&&r.setMap(n)}return!i.showIndoorMap||"normal"!==n.c_&&"amap://styles/normal"!==n.c_||n.isDOMMode()||n.addLayer(n.indoorMap=new AMap.IndoorMap({zIndex:8,opacity:1,map:n})),n.YG=i.vectorMapForeign,n.QZ=i.overseaDataType,n.jdt=performance&&performance.now(),i.vectorMapForeign&&n.addLayer(new AMap.Mapbox({zIndex:8,opacity:1,visible:!0,map:n})),n.lcs.setMap(n),n.customCoords=new rr(n),n.getOutseaState()&&n.bZ.MZ.tY.add({NZ:function(){n.bZ.MZ.wZ.gZ()},group:"default",UZ:function(){return n.bZ.MZ.wZ.stencil.AS},FZ:function(){return 0}}),n}function fr(t){var i=cr.call(this,t)||this;return i.CLASS_NAME="AMap.ImageLayer",i._tileUrl=t.url||t.tileUrl,i.ir=t.bounds,i.Qh=t.zIndex||6,i.tl=void 0===t.opacity?1:t.opacity,i.il=void 0===t.visible||t.visible,i.xt=void 0===t.zooms?_.zoomRange:t.zooms,i.canvas=t.canvas,i}cr=s,_.Ei(fr,cr),fr.prototype.getSourceConfig=function(){return{id:this._id,type:"image",tileUrl:this._tileUrl,bounds:this.ir,canvas:this.canvas,zooms:this.xt}},fr.prototype.co=function(){return this._id},fr.prototype.getState=function(){return{visible:this.il,opacity:this.tl,layer:this,rejectMapMask:this._rejectMapMask,depthTest:this.AF,ce:this.IF}};var lr,dr={tileUrl:"",url:"",bounds:[0,0,0,0],opacity:1,visible:!0,zIndex:4,zooms:_.zoomRange},vr=(lr=pi=fr,_.Ei(pr,lr),pr.prototype.getImageUrl=function(){return this._tileUrl},pr.prototype.setImageUrl=function(t){var i;t&&(this._tileUrl=t,this.getSourceConfig(),(i=this.getSource())&&i._tileUrl&&i.reLoadImgage&&(i._tileUrl=t,i.reLoadImgage(t)),this._opts.url=t,this.uo.getSource(this._id).Fo(!1),this.map)&&this.map.setNeedUpdate(!0)},pr.prototype.getBounds=function(){return this.ir},pr.prototype.setBounds=function(t){t&&(this.ir=t,this.map.setNeedUpdate(!0))},pr);function pr(t){var i=this;if((t=void 0===t?dr:t).tileUrl||t.url)return t.bounds=t.bounds||dr.bounds,t.opacity=(void 0===t.opacity?dr:t).opacity,t.visible=(void 0===t.visible?dr:t).visible,t.zIndex=(void 0===t.zIndex?dr:t).zIndex,t.canvas=void 0,(i=lr.call(this,t)||this).onCreated(),i;throw new Error("ImageLayer need an Url")}var mr,yr,br={url:"",tileUrl:"",bounds:[0,0,0,0],opacity:1,visible:!0,zooms:_.zoomRange,zIndex:6},gr=(mr=pi,_.Ei(Mr,mr),Mr.prototype.setCanvas=function(t){this.canvas=t,this.reFresh()},Mr.prototype.getElement=function(){return this.canvas},Mr.prototype.getBounds=function(){return this.ir},Mr.prototype.setBounds=function(t){t&&(this.ir=t,this.map.setNeedUpdate(!0))},Mr.prototype.reFresh=function(){this.map&&this.map.setNeedUpdate(!0)},Mr.prototype.destroy=function(){var t=this.getSource();t&&t.destroy&&t.destroy()},Mr);function Mr(t){var i=this;return(t=void 0===t?br:t).bounds=t.bounds||br.bounds,t.opacity=(void 0===t.opacity?br:t).opacity,t.visible=(void 0===t.visible?br:t).visible,t.tileUrl="",(i=mr.call(this,t)||this).onCreated(),i.CLASS_NAME="AMap.CanvasLayer",i}function kr(t,i){var n=yr.call(this,i)||this;return n.CLASS_NAME="AMap.CustomLayer",n.eP=!1,n.UF=!1,n.render=i.render||function(){},n.canvas=t,n.Qh=i.zIndex||11,n.tl=void 0===i.opacity?1:i.opacity,n.il=void 0===i.visible||i.visible,n.UF=void 0!==i.alwaysRender&&i.alwaysRender,n.xt=i.zooms||_.zoomRange,n.canvas.style.opacity=""+n.tl,n.canvas.style.display=n.il?"block":"none",n.map&&n.gx(n.canvas),n}yr=s,_.Ei(kr,yr),kr.prototype.getState=function(){return!this.eP&&this.map&&this.gx(this.canvas),{visible:this.il,opacity:this.tl,zIndex:this.Qh,layer:this,rejectMapMask:this._rejectMapMask,depthTest:this.AF,ce:this.IF,kv:this._container,alwaysRender:this.UF}},kr.prototype.getSourceConfig=function(){return{id:this._id,type:"custom",zooms:this.xt}},kr.prototype.co=function(){return this._id},kr.prototype.setOpacity=function(t){yr.prototype.setOpacity.call(this,t),this.canvas.style.opacity=""+this.tl},kr.prototype.setMap=function(t){t||this.destroy(),yr.prototype.setMap.call(this,t),t&&this.gx(this.canvas)},kr.prototype.setzIndex=function(t){this.Qh=t,this._container&&(this._container.style.zIndex=this.Qh+"")},kr.prototype.destroy=function(){var t;this._container&&(this.map?this.map.do.removeChild(this._container):(t=document.querySelector(".amap-layers"))&&t.removeChild(this._container),this._container=null)},kr.prototype.gx=function(t){this._container||(this._container=document.createElement("div"),this._container.style.zIndex=this.Qh+"",this._container.className="amap-layer amap-e",this._container.appendChild(t),this.map.do.appendChild(this._container),this.eP=!0)},wr=kr,_.Ei(Ar,wr);var wr,xr=Ar;function Ar(t,i){return(t=wr.call(this,t,i)||this).onCreated(),t}var zr,Cr={zIndex:120,opacity:1,zooms:_.zoomRange,cursor:"pointer",alwaysRender:!0},Sr=(zr=_.Event,_.Ei(L,zr),L.prototype.setMap=function(t){t?(this._map=t).add(this.a$):this._map&&(this.clear(),this._map.remove(this.a$))},L.prototype.getMap=function(){return this._map||null},L.prototype.getData=function(){return this.VL},L.prototype.setData=function(t){var i=this;t&&(this.VL=t,this.XD(),AMap.Util.requestAnimFrame(function(){i.emit("complete")}))},L.prototype.getStyle=function(){return 1===this.Ze.length?this.Ze[0]:this.Ze},L.prototype.setStyle=function(t){if(t){Array.isArray(t)||(t=[t]);var i=this.Ze,n=[];if(i&&i.length)for(var s=0;s<t.length;s++){var e=t[s],r=i[s]||i[0];n.push(AMap.extend({},r,e))}else n=t;this.Ze=n,this.XD()}},L.prototype.getOpacity=function(){return this._opts.opacity},L.prototype.setOpacity=function(t){this._opts.opacity=t,this.a$&&this.a$.setOpacity(t)},L.prototype.getzIndex=function(){return this._opts.zIndex},L.prototype.setzIndex=function(t){this._opts.zIndex=t,this.a$&&this.a$.setzIndex(t)},L.prototype.getZooms=function(){return this._opts.zooms||[2,30]},L.prototype.setZooms=function(t){this._opts.zooms=t,this.a$&&this.a$.setZooms(t)},L.prototype.getCursor=function(){return this._opts.cursor||"default"},L.prototype.show=function(){this.a$.show()},L.prototype.hide=function(){this.a$.hide()},L.prototype.clear=function(){this.a$.clear(),this.VL=[]},L.prototype.XD=function(){var t=this.VL,i=this.Ze,n=[],s=this.getCursor();if(t&&i){for(var e=0,r=t;e<r.length;e++){var h,o,a,u,c,f=r[e],l=f.lnglat,d=void 0===(d=f.style)?0:d;l&&(h=(a=i[d]||i[0]).url,c=void 0===(c=a.anchor)?new AMap.Pixel(0,0):c,u=a.size,o=a.rotation,d=void 0===(a=a.zIndex)?d:a,a=u.width?u.toArray():u,u=c.x?c.toArray():c,(c=new AMap.LabelMarker({position:l,zIndex:d,cursor:s,rotation:o,icon:{image:h,size:a,anchor:u}})).qD=f,this.Rm(c),n.push(c))}this.jT=n,this.a$.clear(),this.a$.add(n)}},L.prototype.Rm=function(t){var r=this;t.on(["click","dblclick","mouseover","mousemove","mouseout","mouseup","mousedown","touchstart","touchend"],function(t){var i,n=t.type,s=r._map,e=r.getCursor();"default"!==e&&s&&(i=s.getDefaultCursor(),"mouseover"===n?s.setCursor(e):"mouseout"===n&&s.setCursor(i)),r.QD(t)})},L.prototype.QD=function(t){var i=t.type,t=this.KD(t);this.emit(i,t)},L.prototype.KD=function(t){var i=t.target;return t.target=this,{target:t.target,type:t.type,data:i.qD||{}}},L);function L(t,i){var n=zr.call(this)||this;n.CLASS_NAME="AMap.MassMarks",n._opts=AMap.extend({},Cr,i);var s=(i=n._opts).zIndex,e=i.opacity,r=i.zooms,i=i.style;return n.a$=new AMap.LabelsLayer({zIndex:s,opacity:e,zooms:r,collision:!1,allowCollision:!1,VT:!0}),n.setData(t),n.setStyle(i),n.XD(),n}var Tr,Lr="AMap.Text",Ir="amap-overlay-text-container",Dr=(Tr=De,_.Ei(Or,Tr),Or.prototype.getText=function(){return this._opts.text},Or.prototype.getOptions=function(){return this._opts},Or.prototype.setText=function(t){var i=this.wx(t);this._opts.text=t,this.setContent(i)},Or.prototype.setStyle=function(t){t&&(this._x=t,this._opts.style=t,this._size=[0,0],this.updateOverlay())},Or.prototype.updateOverlay=function(t){void 0===t&&(t={}),this.dom&&!_.isEmpty(this._x)&&this.kx(this._x),Tr.prototype.updateOverlay.call(this,t)},Or.prototype.wx=function(t){var i=document.createElement("div");return w.addClass(i,Ir),i.innerHTML=t||"",i},Or.prototype.kx=function(t){void 0===t&&(t={});var i=this.dom.querySelector("."+Ir);if(i)for(var n in t)t.hasOwnProperty(n)&&(i.style[n]=t[n])},Or);function Or(t){var i=Tr.call(this,t=void 0===t?{}:t)||this;return i.className=Lr,i.type=Lr,i._x={},i._size=[0,0],t.style&&(i._x=t.style),t.text&&i.setText(t.text),i}var Rr,Er={zooms:_.zoomRange,opacity:1,rank:1,bubble:!1,visible:!0,zIndex:1,cursor:"pointer",noSelect:!1,icon:{clipOrigin:[0,0],anchor:[0,0],retina:!0},innerOverlay:!1,rotation:0,text:{content:"",direction:"right",offset:[0,0],zooms:_.zoomRange,style:{fontSize:12,fontFamily:"sans-serif",fontWeight:"normal",fillColor:"#000",strokeWidth:0,padding:"3",fold:!1}}},Pr={uy:"AMap.LabelMarker",gy:Math.pow(2,31)},jr={constructor:{time:0,highResTime:0},setIcon:{time:0,highResTime:0},setText:{time:0,highResTime:0}},Br=(Rr=Qt,_.Ei(I,Rr),I.prototype.nY=function(t){var i,n=_.yn(t);for(i in Er)Er.hasOwnProperty(i)&&void 0===n[i]&&(n[i]=_.clone(Er[i]));return n},I.prototype.getName=function(){return this._opts.name},I.prototype.setName=function(t){this._opts.name=t},I.prototype.getBounds=function(){var t=this._position;return new l(t,t)},I.prototype.getPosition=function(){return new _.LngLat(this._position[0],this._position[1])},I.prototype.setPosition=function(t){t&&("string"==typeof t?t=_.map(t.split(","),function(t){return parseFloat(t)}):_.Bs(t)&&(t=t.toJSON()),this._position=t,this.to())},I.prototype.getZooms=function(){return this._opts.zooms},I.prototype.setZooms=function(t){void 0===t&&(t=_.zoomRange),this._opts.zooms=t,this.to()},I.prototype.getOpacity=function(){return this._opts.opacity},I.prototype.setOpacity=function(t){void 0!==t&&(this._opts.opacity=t,this.to())},I.prototype.setRotation=function(t){void 0!==t&&(this._opts.rotation=t,this.to())},I.prototype.getRotation=function(){return void 0===this._opts.rotation?0:this._opts.rotation},I.prototype.getzIndex=function(){return this._opts.zIndex},I.prototype.setzIndex=function(t){this._opts.zIndex=t,this.to()},I.prototype.getRank=function(){return this._opts.rank},I.prototype.setRank=function(t){this._opts.rank=t,this.to()},I.prototype.getText=function(){return this._originOpts.text&&this._opts.text||null},I.prototype.setText=function(t){t&&(_.assign(this._opts.text,t),this.to())},I.prototype.getIcon=function(){return this._originOpts.icon&&this._opts.icon||null},I.prototype.setIcon=function(t){t&&(_.assign(this._opts.icon,t),this.to())},I.prototype.getOptions=function(){return this._opts},I.prototype.getDraggable=function(){return!1},I.prototype.getExtData=function(){return this._opts.extData||null},I.prototype.setExtData=function(t){this._opts.extData=t},I.prototype.setTop=function(t){void 0===t&&(t=!0),this._parent&&this._parent.setTop(this,t),t?(this.vL=this._opts.zIndex||1,this.setzIndex(Pr.gy)):(t=this.vL||this._opts.zIndex||1,this.setzIndex(t))},I.prototype.setCursor=function(t){t&&(this._opts.cursor=t)},I.prototype.getCursor=function(){return this._opts.cursor||"default"},I.prototype.setVisible=function(t){void 0!==t&&(this._opts.visible=t,this.to())},I.prototype.getVisible=function(){return this._opts.visible||!0},I.prototype.getCollision=function(){var t,i=this.getVisible(),n=!1;return this._parent&&i&&(t=this.hS,n=this._parent.IL(t)),i&&n},I.prototype.show=function(){this._opts.visible=!0,this.to()},I.prototype.hide=function(){this._opts.visible=!1,this.to()},I.prototype.emit=function(t,i){var n=this._opts||{},s=n.icon,e=n.text,r=e&&e.content,h=this.getCursor(),h=(this._map&&("mouseout"===t?this._map.setCursor():this._map.setCursor(h)),{data:{name:r,txt:r,position:this._position,extData:{},rank:n.rank,zooms:n.zooms},opts:{visible:n.visible,opacity:n.opacity,zooms:n.zooms,zIndex:n.zIndex,icon:s,text:e}});return i.data=h,Rr.prototype.emit.call(this,t,i),this},I.prototype.remove=function(){this._parent&&this._parent.remove(this)},I.prototype.to=function(){var n=this;this._parent&&this._parent.to({vv:!0},function(){var t=(new Date).getTime(),i=0;"performance"in window&&"function"==typeof performance.now&&(i=performance.now()),n.Ndt.setIcon={time:t,highResTime:i},n.Ndt.setText={time:t,highResTime:i}})},I.prototype.getStatus=function(){return this.Ndt},I.prototype.Cs=function(t){(this._parent=t)&&t.map?this._map=t.map:this._map=null},I.prototype.Ydt=function(n){return _.T8t(this,void 0,void 0,function(){var i;return _.x8t(this,function(t){switch(t.label){case 0:return[4,de.Ydt(n)];case 1:return i=t.y8t(),this.setPosition(i),[2]}})})},I);function I(t){var i=Rr.call(this)||this,t=(i.type=Pr.uy,i.className=Pr.uy,i.hS=_.Util.stamp(i),i._originOpts=t,i._opts=i.nY(t),t.position&&i.setPosition(t.position),i.Ndt=jr,(new Date).getTime()),n=0;return"performance"in window&&"function"==typeof performance.now&&(n=performance.now()),i.Ndt.constructor={time:t,highResTime:n},i}Wr=_.Event,_.Ei(Gr,Wr),Gr.prototype.addTo=function(t){this.map=t,this.map.controls.push(this),t.getControlContainer().appendChild(this._container),t.on("beforeDestroy",this.remove.bind(this))},Gr.prototype.removeFrom=function(t){t?(t.off("beforeDestroy",this.remove.bind(this)),t.getControlContainer().removeChild(this._container),delete this.map):this.map&&(this.map.off("beforeDestroy",this.remove.bind(this)),this.map.getControlContainer().removeChild(this._container),delete this.map)},Gr.prototype.remove=function(){this.map&&(this.map.off("beforeDestroy",this.remove.bind(this)),this.map.getControlContainer().removeChild(this._container),delete this.map)},Gr.prototype.show=function(){this._container.style.display="block",this.emit("show"),this.il=!0},Gr.prototype.hide=function(){this._container.style.display="none",this.emit("hide"),this.il=!1},Gr.prototype.initContainer=function(){this._className?(this._container=w.create("div",null,"amap-control amap-"+this._className),void 0===this._config.visible||this._config.visible||(this._container.style.display="none")):this._container=w.create("div",null,"amap-control"),this.Pb()},Gr.prototype.Pb=function(){var t=0,i=0,n=0,s=0;switch(this._config.offset&&0<this._config.offset.length&&(t=this._config.offset[0]+t,i=this._config.offset[1]+i,n=this._config.offset[0]+n,s=this._config.offset[1]+s),t+="px",i+="px",n+="px",s+="px",this._config.position){case"LT":this._container.style.top=i,this._container.style.left=t,this._container.style.bottom="",this._container.style.right="";break;case"RT":this._container.style.top=i,this._container.style.right=n,this._container.style.bottom="",this._container.style.left="";break;case"LB":this._container.style.bottom=s,this._container.style.left=t,this._container.style.top="",this._container.style.right="";break;case"RB":this._container.style.bottom=s,this._container.style.right=n,this._container.style.top="",this._container.style.left="";break;default:this._container.style.top=this._config.position.top||"",this._container.style.left=this._config.position.left||"",this._container.style.right=this._config.position.right||"",this._container.style.bottom=this._config.position.bottom||""}};var Wr,Fr=Gr;function Gr(t){var i=Wr.call(this)||this;return i.il=!0,i._config=t,i.il=void 0===t.visible||t.visible,i}var Nr,_r={ua:(xi=window.navigator).userAgent,mobile:_.Support.$e,plat:_.Support.plat,mac:_.Support.mac,windows:_.Support.windows,ios:_.Support.ios,iPad:_.Support.iPad,iPhone:_.Support.iPhone,android:_.Support.android,android23:_.Support.android23,chrome:_.Support.chrome,firefox:_.Support.firefox,safari:_.Support.safari,wechat:_.Support.wechat,uc:_.Support.SL,qq:_.Support.qq,ie:_.Support.ie,ie6:_.Support.ie6,ie7:_.Support.ie7,ie8:_.Support.ielt9&&!_.Support.ie7&&!_.Support.ie6,ie9:_.Support.ie9,ie10:_.Support.ie10,ie11:_.Support.ie11,edge:_.Support.edge,ielt9:_.Support.ielt9,baidu:_.Support.baidu,isLocalStorage:_.Support.RL,isGeolocation:!!xi.geolocation,mobileWebkit:_.Support.mobileWebkit,mobileWebkit3d:_.Support.mobileWebkit3d,mobileOpera:!!_.Support.mobileOpera,retina:_.Support.Ue,touch:!!_.Support.touch,msPointer:!!_.Support.msPointer,pointer:!!_.Support.pointer,baseRender:_.Support.baseRender,wasm:_.Support.wasm,webkit:_.Support.webkit,ie3d:_.Support.ie3d,webkit3d:_.Support.webkit3d,gecko3d:_.Support.gecko3d,opera3d:_.Support.opera3d,any3d:_.Support.any3d,isCanvas:_.Support.isCanvas,isSvg:_.Support.isSvg,isVML:_.Support.ie,isWorker:!!window.Worker,isWebsocket:!!window.WebSocket,isWebGL:_.Support.isWebGL,checkWebGL:function(){return _.Support.isWebGL=_.Support.sY(),_.Support.isWebGL}},ct=(Nr=s,_.Ei(Ur,Nr),Ur.prototype.getState=function(){return{zooms:this.xt,heightFactor:this.Q_,visible:this.il,zIndex:this.Qh,opacity:this.tl,wallColor:[],roofColor:[],layer:this,rejectMapMask:this._rejectMapMask,depthTest:this.AF,ce:this.IF}},Ur.prototype.getLayerConfig=function(){return Nr.prototype.getLayerConfig.call(this)},Ur.prototype.getSourceConfig=function(){return{id:this._id,type:"building",tileUrl:AMap.getConfig().protocol+(_.Support.wasm?"://{vdata,vdata01,vdata02,vdata03,vdata04}.amap.com/nebula/v3":"://{vdata,vdata01,vdata02,vdata03,vdata04}.amap.com/nebula/v2"),tileSize:0,zooms:_.zoomRange}},Ur.prototype.co=function(){return this._id},Ur.prototype.destroy=function(){this.Jh&&this.Jh.destroy&&(this.Jh.destroy(),delete this.Jh)},Ur);function Ur(){var t=Nr.call(this)||this;return t.CLASS_NAME="AMap.Buildings",t.Q_=1,t._id="building",t}var Yr,Zr={zooms:[14.8,_.zoomRange[1]],opacity:1,heightFactor:1,visible:!0,zIndex:11,wallColor:[.94,.94,.94,.9],roofColor:[.89,.89,.86,.9],u$:!1},Xr=(Yr=ct,_.Ei(Jr,Yr),Jr.prototype.setStyle=function(t){this.fL=t,this.uL()},Jr.prototype.getState=function(){return{zooms:this.xt,heightFactor:this.Q_,visible:this.il,zIndex:this.Qh,opacity:this.tl,wallColor:this.sz,roofColor:this.rz,vS:this.fL,layer:this,u$:this.cL,rejectMapMask:this._rejectMapMask,depthTest:this.AF,ce:this.IF}},Jr.prototype.uL=function(){this.map&&(this.getSource().reload(),this.map.setNeedUpdate(!0))},Jr);function Jr(t){void 0===t&&(t=Zr);var i=Yr.call(this)||this;return i.cL=!1,i.xt=(void 0===t.zooms?Zr:t).zooms,i.xt[0]=Math.max(i.xt[0],14.8),i.tl=(void 0===t.opacity?Zr:t).opacity,i.Q_=(void 0===t.heightFactor?Zr:t).heightFactor,i.il=(void 0===t.visible?Zr:t).visible,i.Qh=(void 0===t.zIndex?Zr:t).zIndex,i.sz=void 0!==t.wallColor&&_.Util.color2RgbaArray(t.wallColor),i.rz=void 0!==t.roofColor&&_.Util.color2RgbaArray(t.roofColor),i.AF=void 0===t.depthTest||Boolean(t.depthTest),i.cL=t.u$,i.cL&&(i._id="nebula"),i.onCreated(),i}Vr.add=function(){};var Hr=Vr;function Vr(){}function qr(t){return _.Support.isWebGL?new Ji(t):new v(_.Ln({id:"_defaultLayer_"+_.Util.uuid(),tileUrl:AMap.getConfig().y_},t))}var Kr,Qr="gl_custom";function $r(t){var i=Kr.call(this,t)||this;return i.CLASS_NAME="AMap.GLCustomLayer",i.init=t.init||function(t){},i.render=t.render||function(t,i,n){},i.Qh=t.zIndex||120,i.tl=void 0===t.opacity?1:t.opacity,i.il=void 0===t.visible||t.visible,i.xt=t.zooms||_.zoomRange,i}Kr=s,_.Ei($r,Kr),$r.prototype.getState=function(){return{visible:this.il,opacity:this.tl,zIndex:this.Qh,layer:this,rejectMapMask:this._rejectMapMask,depthTest:this.AF,ce:this.IF}},$r.prototype.getSourceConfig=function(){return{id:Qr,type:Qr,zooms:this.xt}},$r.prototype.co=function(){return Qr},$r.prototype.setMap=function(t){Kr.prototype.setMap.call(this,t)},$r.prototype.setzIndex=function(t){this.Qh=t},th=$r,_.Ei(nh,th);var th,ih=nh;function nh(t){return(t=th.call(this,t)||this).onCreated(),t}sh=_.Event,_.Ei(rh,sh),rh.prototype.setMap=function(t){var i=this;return t&&t!==this._map&&(this._map=t,_.forEach(this.zv,function(t){i._map&&!i._map.hasLayer(t)&&t.setMap(i._map)})),this},rh.prototype.hasLayer=function(i){return!!_.find(this.zv,function(t){return t===i})},rh.prototype.setOptions=function(e){var r=this.zv;return _.vx(e,function(t,i){for(var n=0;n<r.length;n++){var s=r[n];if("AMap.Layer"===s.el)switch(i){case"visible":t?s.show():s.hide();break;case"opacity":s.setOpacity&&s.setOpacity(t);break;case"zIndex":s.setzIndex&&s.setzIndex(t);break;case"zooms":s.setZooms&&s.setZooms(t)}else s.setOptions&&s.setOptions(e)}}),this},rh.prototype.eachLayer=function(t){if(_.isFunction(t))for(var i=0;i<this.zv.length;i++)t(this.zv[i],i,this.zv)},rh.prototype.addLayer=function(t){this.hasLayer(t)||(this.zv.push(t),t.setMap(this._map))},rh.prototype.addLayers=function(t){if(0<t.length)for(var i=0;i<t.length;i++){var n=t[i];this.addLayer(n)}},rh.prototype.removeLayer=function(t){for(var i=0;i<this.zv.length;i++)t===this.zv[i]&&this.zv.splice(i,1);return t.setMap(null),t},rh.prototype.removeLayers=function(t){if(t&&0<t.length)for(var i=0;i<t.length;i++){var n=t[i];this.removeLayer(n)}},rh.prototype.getLayers=function(){return this.zv},rh.prototype.clearLayers=function(){for(var t=0;t<this.zv.length;t++){var i=this.zv[t];this.removeLayer(i)}},rh.prototype.hide=function(){for(var t=0;t<this.zv.length;t++)this.zv[t].hide();return this},rh.prototype.show=function(){for(var t=0;t<this.zv.length;t++)this.zv[t].show();return this},rh.prototype.on=function(t,i){for(var n=0;n<this.zv.length;n++){var s=this.zv[n];s.on instanceof Function&&i instanceof Function&&s.on(t,i)}return this},rh.prototype.reload=function(){for(var t=0;t<this.zv.length;t++){var i=this.zv[t];i.reload&&i.reload()}return this};var sh,oh,eh=rh;function rh(t){var i=sh.call(this)||this;if(i.zv=[],i._map=null,t&&0<t.length)for(var n=0;n<t.length;n++){var s=t[n];i.addLayer(s)}return i}function hh(){console.log("jsapi2.0 AMap.Heatmap is renamed, please use AMap.HeatMap"),console.log("jsapi2.0 AMap.Heatmap 已重命名, 请使用 AMap.HeatMap")}function ah(t){var i=oh.call(this)||this;return i.CLASS_NAME="AMap.MapboxLayer",i._id="mapbox",i._tileUrl=AMap.getConfig().protocol+"://fmap0{1234}.amap.com/v3/vectormap?version=v8&key="+AMap.getConfig().key+"&s=rsv3&x=[x]&y=[y]&zoom=[z]",AMap.getConfig().jscode?i._tileUrl+="&jscode="+AMap.getConfig().jscode:AMap.getConfig().gaodeserver&&(i._tileUrl=AMap.getConfig().gaodeserver+"/v3/vectormap?version=v8&key="+AMap.getConfig().key+"&s=rsv3&x=[x]&y=[y]&zoom=[z]"),i.Xa=t.tileSize||256,i.Qs=[2,22],i.Qh=2,i.xt=[9.8,_.zoomRange[1]],i}oh=s,_.Ei(ah,oh),ah.prototype.getState=function(){return{zooms:[17,23],visible:this.il,zIndex:2,opacity:this.tl,layer:this,depthTest:this.AF,ce:this.IF,tileUrl:this._tileUrl}},ah.prototype.getSourceConfig=function(){return{id:this._id,tileUrl:this._tileUrl||"",type:"mapbox",tileSize:this.Xa||256,zooms:this.xt,dataZooms:this.Qs,projection:"EPS3857"}},ah.prototype.co=function(){return this._id},uh=ah,_.Ei(fh,uh);var uh,ch=fh;function fh(t){return uh.call(this,t)||this}Object.defineProperty(vh.prototype,"CLASS_NAME",{get:function(){return this.className},eb:!1,nb:!0}),vh.prototype.addOverlay=function(t){this._overlays.indexOf(t)<0&&(this._overlays.push(t),this._map)&&this._map.add(t)},vh.prototype.addOverlays=function(t){for(var i=0,n=t;i<n.length;i++){var s=n[i];this.addOverlay(s)}},vh.prototype.getOverlays=function(){return this._overlays},vh.prototype.hasOverlay=function(t){return-1<this._overlays.indexOf(t)},vh.prototype.removeOverlay=function(t){this.hasOverlay(t)&&(_.Util.deleteItemFromArray(this._overlays,t),this._map)&&this._map.remove(t)},vh.prototype.removeOverlays=function(t){for(var i=0,n=t;i<n.length;i++){var s=n[i];this.removeOverlay(s)}},vh.prototype.clearOverlays=function(){this._map&&this._map.remove(this._overlays),this._overlays=[]},vh.prototype.eachOverlay=function(t){_.forEach(this._overlays,t)},vh.prototype.setMap=function(t){this._map=t},vh.prototype.show=function(){for(var t=0,i=this._overlays;t<i.length;t++)i[t].show()},vh.prototype.hide=function(){for(var t=0,i=this._overlays;t<i.length;t++)i[t].hide()},vh.prototype.setOptions=function(t){for(var i=0,n=this._overlays;i<n.length;i++)n[i].setOptions(t)},vh.prototype.on=function(i,n,s,e){this.eachOverlay(function(t){t.on(i,n,s,e)})},vh.prototype.off=function(i,n,s,t){this.eachOverlay(function(t){t.off(i,n,s)})};var lh,dh=vh;function vh(t){void 0===t&&(t=[]),this.className="Overlay.OverlayGroup",this._overlays=[],this.addOverlays(t)}function ph(){var t=null!==lh&&lh.apply(this,arguments)||this;return t.P$=!1,t._dragObjects={sy:{x:0,y:0},hy:[0,0],ly:{lng:0,lat:0}},t}lh=Qt,_.Ei(ph,lh),ph.prototype.Cy=function(t){this.P$=!0,_.Support.$e||t.originEvent.preventDefault(),this.Ay(t)},ph.prototype.Ly=function(t){this.P$=!1,_.Support.$e||t.originEvent.preventDefault()},ph.prototype.Ay=function(t){this._dragObjects={sy:t.pixel,hy:t.pos,ly:t.lnglat}},ph.prototype.Mx=function(){this.on("dragstart",this.Cy.bind(this)),this.on("dragging",this._dragging.bind(this)),this.on("dragend",this.Ly.bind(this))},ph.prototype.Rx=function(){this.off("dragstart",this.Cy.bind(this)),this.off("dragging",this._dragging.bind(this)),this.off("dragend",this.Ly.bind(this))},mh=ph,_.Ei(D,mh),Object.defineProperty(D.prototype,"CLASS_NAME",{get:function(){return this.className},eb:!1,nb:!0}),D.prototype.Zx=function(t){this._map=t,this._opts&&(this._opts.map=t)},D.prototype.setMap=function(t){this._map!==t&&(this._map&&this._map.remove(this),t)&&t.add(this)},D.prototype.getMap=function(){return this._map||null},D.prototype.destroy=function(){this.Rx(),this._beforeRemoveMap&&this._beforeRemoveMap(),this._map=null,this.F$&&delete this.F$,this._bindEvents&&delete this._bindEvents,this._afterSetMap&&delete this._afterSetMap},D.prototype.remove=function(){this.setMap(null)},D.prototype.hide=function(){this.visible&&(this.visible=!1,this._map&&this._map.setNeedUpdate(!0),this.emit("hide",{target:this}))},D.prototype.show=function(){this.visible||(this.visible=!0,this._map&&this._map.setNeedUpdate(!0),this.emit("show",{target:this}))},D.prototype.setDraggable=function(t){return this._opts.draggable=t},D.prototype.getOptions=function(){return _.extend({},this._opts)},D.prototype.to=function(){var t=this;this._map&&(AMap.Util.requestAnimFrame(function(){t.emit("complete")}),this._map.setNeedUpdate(!0))},D.prototype.getExtData=function(){var t=this._opts;if(t&&t.extData)return t.extData},D.prototype.setExtData=function(t){this.setOptions({extData:t})},D.prototype.getCursor=function(){var t=this._opts.cursor;return!t&&this._map?this._map.getDefaultCursor():t},D.prototype.emit=function(t,i){var n=this.getCursor();return this._map&&("mouseout"===t?this._map.setCursor():this._map.setCursor(n)),("dragstart"!==t&&"dragging"!==t&&"dragend"!==t||this.getDraggable())&&mh.prototype.emit.call(this,t,i),this},D.prototype.getDraggable=function(){var t=this._opts.draggable;return void 0!==t&&t},D.prototype.BB=function(){this.b_([0,0])},D.prototype.getDeltaCoord=function(){return this.zx},D.prototype.b_=function(t){this.zx=t},D.prototype.rY=function(t){var i=this.Sx;return _.Util.hp(i,t)},D.prototype._beforeRemoveMap=function(){var t;this.F$&&(null!=(t=this.F$.parentNode)&&t.removeChild(this.F$),delete this.F$)},D.prototype.nY=function(t){var i,n=this._opts;for(i in t)t.hasOwnProperty(i)&&(n[i]=t[i]);return n},D.prototype._dragging=function(t){var i,n,s,e,r;this.getDraggable()&&(n=this._dragObjects.hy,i=t.pos[0]-n[0],n=t.pos[1]-n[1],r=this._dragObjects.sy,this.F$&&"d"===this._map.baseRender?(e=t.pixel.x-r.x,r=t.pixel.y-r.y,s=this.B$,this.B$=[e+s[0],r+s[1]],e=" translate("+this.B$[0]+"px, "+this.B$[1]+"px)",this.F$.style.transform=e,this.F$.style.webkitTransform=e,this.F$.style.MozTransform=e,this.F$.style.msTransform=e):this.to(),r=this.getDeltaCoord(),this.b_([i+r[0],n+r[1]]),this.Ay(t))},D.prototype.Ly=function(t){mh.prototype.Ly.call(this,t),this.Ay(t),this.F$&&"d"===this._map.baseRender?this.moveWithPixel(this.B$[0],-1*this.B$[1]):this.moveWithPos(this.zx[0],this.zx[1]),this.BB(),this.B$=[0,0],this.F$&&(this.F$.style.transform="",this.F$.style.webkitTransform="",this.F$.style.MozTransform="",this.F$.style.msTransform=""),this.to()},D.prototype.moveWithPixel=function(){console.log("please implement movePixel")},D.prototype.moveWithPos=function(){console.log("please implement moveWithPos")},D.prototype._checkMap=function(){this._opts&&this._opts.map!==this._map&&this.setMap(this._opts.map)},D.prototype.cE=function(){this._needUpdate=!0,!this._map||this._map.fE&&!this._map.isDOMMode()||this.ZB()};var mh,Bt=D;function D(){var t=mh.call(this)||this;return t._needUpdate=!1,t.className="Overlay",t.gdt=!1,t.visible=!0,t.P$=!1,t.zx=[0,0],t.B$=[0,0],t.Ax=[0,0],t.hS=_.Util.stamp(t),t.Mx(),t}function yh(t){if(t=_.jsonLngLatData(t),_.ys(t))t=[[t]];else if(_.Ox(t))t=[t];else if(!_.tL(t))return;return t}function bh(t,i,n){return _.hL.ss(t,i,n)}function gh(t,i){if(!bh(t,i[0]))return!1;for(var n=1,s=i.length;n<s;n++)if(bh(t,i[n],!0))return!1;return!0}function Mh(t,i){for(var n=0,s=i.length;n<s;n++)if(gh(t,i[n]))return!0;return!1}function kh(t,i,n){for(var s=[],e=0,r=t;e<r.length;e++){var h=r[e];s.push(n.moveWithPos(h,i))}return s}function wh(t,i,n){for(var s=[],e=0,r=t;e<r.length;e++){var h=kh(r[e],i,n);s.push(h)}return s}function xh(t,i,n,s){for(var e=[],r=0,h=t;r<h.length;r++){var o=h[r];e.push(s.moveWithPixel(o,i,n))}return e}function Ah(t,i,n,s){for(var e=[],r=0,h=t;r<h.length;r++){var o=xh(h[r],i,n,s);e.push(o)}return e}function zh(t){return _.GeometryUtil.ringArea(t)}function Ch(t){for(var i=zh(t[0]),n=1;n<t.length;n++)i-=zh(t[n]);return i}function Sh(t){for(var i=0,n=0,s=t;n<s.length;n++)i+=Ch(s[n]);return i}function Th(t){return t=_.jsonLngLatData(t),_.ys(t)?[t]:t}function Lh(t){return _.GeometryUtil.distanceOfLine(t)}function Ih(t){if(t.length<2)return t;var i=[];i.push(t[0]);for(var n=1,s=t.length;n<s;n++){var e=t[n-1],r=t[n];Array.prototype.push.apply(i,function(t,i){var n=Math.round(Math.abs(t.KL-i.KL));if(!n||Math.abs(t.KL-i.KL)<.001)return[];for(var e,r,h,o,a=[],u=Math.PI,c=Math.asin,f=Math.sqrt,l=Math.sin,d=Math.pow,v=Math.cos,p=Math.atan2,m=t.kT*Dh,y=t.KL*Dh,b=i.kT*Dh,g=i.KL*Dh,M=2*c(f(d(l((m-b)/2),2)+v(m)*v(b)*d(l((y-g)/2),2))),s=1;s<n;s+=1)o=l((1-(h=1/n*s))*M)/l(M),h=l(h*M)/l(M),e=o*v(m)*v(y)+h*v(b)*v(g),r=o*v(m)*l(y)+h*v(b)*l(g),h=p(o=o*l(m)+h*l(b),f(d(e,2)+d(r,2))),o=p(r,e),y<g?(o<y&&(o+=2*u),g<o&&(o-=2*u)):(y<o&&(o-=2*u),o<g&&(o+=2*u)),a.push([o*Oh,h*Oh]);return a}(_.LngLat.from(e),_.LngLat.from(r))),i.push(r)}return i}var Dh=Math.PI/180,Oh=180/Math.PI;function Rh(t,i){var n=[],t=_.parseLngLatData(t),s=_.ProjectionManager.getProjection("EPSG:3857");if(t)for(var e=s.project(t.KL,t.kT),r=e[0],h=e[1],o=6*Math.PI/180,a=Math.cos(t.kT*Math.PI/180),u=0;u<=60;u++){var c=u*o,f=i*Math.cos(c)/a,c=i*Math.sin(c)/a,f=s.unproject(r+f,h+c);n.push(f)}return n}function Eh(t,i,n){var s=[],t=_.parseLngLatData(t),e=_.ProjectionManager.getProjection("EPSG:3857");if(t)for(var h=(r=e.project(t.KL,t.kT))[0],o=r[1],r=n?89:359,a=(n?4:1)*Math.PI/180,u=i[0],c=i[1],f=Math.cos(t.kT*Math.PI/180),l=0,d=r;l<=d;l++){var v=l*a,p=u*Math.cos(v)/f,v=c*Math.sin(v)/f,p=e.unproject(h+p,o+v);s.push(p)}return s}function Ph(t){var i=t.getSouthWest(),t=t.getNorthEast();return[new _.LngLat(i.KL,i.kT,!0),new _.LngLat(t.KL,i.kT,!0),new _.LngLat(t.KL,t.kT,!0),new _.LngLat(i.KL,t.kT,!0)]}Bh.prototype.init=function(t,i){var n,s,e=t.length;this.tdt=new Array(e);for(var r=0;r<e;r+=1)if(n=t[r],s=new Uh(n),this.tdt[r]=s,!i)if(0===r){if(0===n.length)return;s.isClockwise(n)||n.reverse()}else 0!==n.length&&s.isClockwise(n)&&n.reverse()},Bh.prototype.getBounds=function(){if(0===this.tdt.length)return Pt.createEmpty();if(!this.ndt){for(var t=this.tdt[0].getBounds(),i=1;i<this.tdt.length;i+=1){var n=this.tdt[i].getBounds();Pt.rs(t,n)||Pt.extend(t,n)}this.ndt=t}return this.ndt},Bh.prototype.sdt=function(){return this.tdt},Bh.prototype.edt=function(){for(var t=0;t<this.tdt.length;t+=1)this.tdt[t].xh},Bh.prototype.getType=function(){return Fh.rdt.POLYGON},Bh.prototype.ss=function(t){for(var i,n=this.tdt,s=0,e=n.length;s<e&&(i=n[s].ss(t),i=0<s?!i:i);s+=1);return i},Bh.prototype.odt=function(t){for(var i=this.tdt,n=[],s=0,e=i.length;s<e;s+=1)_.hL.isClockwise(i[s].xh)?n.length&&n[n.length-1].push(s):n.push([s]);for(s=0,e=n.length;s<e;s+=1){for(var a=!1,r=0,h=n[s].length;r<h;r+=1){var o=n[s][r],a=Uh.prototype.ss.call(i[o],t);if(!(a=0<r?!a:a))break}if(a)return!0}};var jh=Bh;function Bh(){}(li=ea=ea||{}).POINT="point",li.LINESTRING="linestring",li.LINEARRING="linearring",li.POLYGON="polygon",li.MULTIPOINT="multipoint",li.MULTILINESTRING="multilinestring",li.MULTIPOLYGON="multipolygon",li.GEOMETRYCOLLECTION="geometrycollection",Gh.prototype.hdt=function(){var t=this.getBounds();return t.center||(t.center=Pt.getCenter(t)),t.center},Gh.prototype.clone=function(){var t=new this.constructor;return t.init(this.XK()),t},Gh.prototype.XK=function(){return this.xh},Gh.prototype.got=function(t){if(this.adt=this.getBounds(),this.ndt=null,this instanceof jh)for(var i=t.length,n=void(this.tdt=new Array(i)),s=void 0,e=0;e<i;e+=1)if(n=t[e],s=new Uh(n),this.tdt[e]=s,0===e){if(0===n.length)return;s.isClockwise(n)||n.reverse()}else 0!==n.length&&s.isClockwise(n)&&n.reverse();else this.xh=t},Gh.rdt=ea;var Wh,Fh=Gh;function Gh(t){var i=this;this.setCoords=function(t){i.got(t)},this.init(t)}function Nh(){return null!==Wh&&Wh.apply(this,arguments)||this}Wh=Fh,_.Ei(Nh,Wh),Nh.prototype.init=function(t){this.xh=t},Nh.prototype.getBounds=function(){if(!this.ndt){for(var t=Pt.createEmpty(),i=0,n=this.xh.length;i<n;i+=1)Pt.extendCoordinate(t,this.xh[i]);this.ndt=t}return this.ndt},Nh.prototype.XK=function(){return this.xh},Nh.prototype.getType=function(){return Fh.rdt.LINESTRING},Nh.prototype.getCount=function(){return this.XK().length},Nh.prototype.udt=function(t){return _.hL.lr(t,this.XK())},_h=Nh,_.Ei(Yh,_h),Yh.prototype.getType=function(){return Fh.rdt.LINEARRING},Yh.prototype.ss=function(t){return _.hL.ss(t,this.xh)};var _h,Uh=Yh;function Yh(){var t=null!==_h&&_h.apply(this,arguments)||this;return t.isClockwise=_.hL.isClockwise,t}Zh=Bt,_.Ei(Xh,Zh),Xh.prototype.Tx=function(t){t&&(t=_.Bs(t)?_.ProjectionManager.getProjection("EPSG:3857").project(t.KL,t.kT):_.ProjectionManager.getProjection("EPSG:3857").project(t[0],t[1]),this.Sx=_.lcs.getLocalByCoord(t))},Xh.prototype.toGeometry=function(){var t;if(this._opts.path)return t=this._opts.path.slice(0),_.ys(t)?{type:"Polygon",coordinates:[t]}:_.Ox(t)?{type:"Polygon",coordinates:t}:{type:"MultiPolygon",coordinates:t}},Xh.prototype.toString=function(){var t=this._opts.path;return _.ys(t)?""+t.join(";"):_.Ox(t)?""+_.map(t,function(t){return""+t.join(";")}).join("|"):_.tL(t)?_.map(t,function(t){return _.map(t,function(t){return""+t.join(";")}).join("|")}).join("^"):""},Xh.prototype.reset=function(){this.Dx&&this.Dx.reset(),this.Px&&this.Px.reset(),this.XB&&this.XB.reset(),this.qB&&this.qB.reset(),this.p0&&this.p0.reset(),this.m0&&this.m0.reset()},Xh.prototype.destroy=function(){this.Dx&&(this.Dx.destroy(),delete this.Dx),this.Px&&(this.Px.destroy(),delete this.Px),this.XB&&this.XB.destroy&&(this.XB.destroy(),delete this.XB),this.qB&&this.qB.destroy&&(this.qB.destroy(),delete this.qB),this.p0&&(this.p0.destroy(),delete this.p0),this.p0&&this.Px.destroy&&(this.p0.destroy(),delete this.p0),this.q$&&delete this.X$,this.$x&&(this.$x=[]),Zh.prototype.destroy.call(this)},Xh.prototype.pdt=function(t,i,n){var s=0;if(i&&this._opts.extrusionHeight){for(var e=[],r=0;r<i.length;r++)e.push(i[r][0],i[r][1]);s=this.p0.tz(e,this._opts.extrusionHeight,n)}return n={bz:"",length:1,mainkey:this.hS,maxzoom:26,minzoom:2,offset:0,subkey:1},s&&0<s&&this.m0.add(n.mainkey,n.subkey,s,n.minzoom,n.maxzoom,n.bz),this.p0.upload(t),s},Xh.prototype.X$=function(t){for(var i=[],n=0,s=t;n<s.length;n++){for(var e=s[n],r=[],h=[],o=0,a=e[0];o<a.length;o++){var u=a[o],c=_.ProjectionManager.getProjection("EPSG:3857").project(u[0],u[1]);h.push([c[0],c[1]])}h.length&&(h.push(h[0].slice()),r.push(h));for(var f=1,l=e.length;f<l;f++){var d=e[f],v=[];if(d&&d.length){for(var p=0,m=d;p<m.length;p++)u=m[p],c=_.ProjectionManager.getProjection("EPSG:3857").project(u[0],u[1]),v.push([c[0],c[1]]);v.push(v[0].slice()),r.push(v)}}i.push(r)}this.q$=i},Xh.prototype.Q$=function(t,i){this.BB(),this.JL(),this.reset();var n=this.Dx,s=this.Px,e=this.XB,r=this.qB;this.Tx(t[0][0][0]);for(var h=0,o=t;h<o.length;h++){for(var a=o[h],u=this.Sx.center,c=[],f=[],l=[],d=[],v=[],p=0,m=a[0];p<m.length;p++){var y=m[p],b=_.ProjectionManager.getProjection("EPSG:3857").project(y[0],y[1]);c.push(b[0]-u[0],b[1]-u[1]),f.push(y)}for(var g=1,M=a.length;g<M;g++){for(var k=[],w=[],x=0,A=a[g];x<A.length;x++)y=A[x],_.Bs(y)?(k.push(y.pos[0]-u[0],y.pos[1]-u[1]),w.push(y.toJSON())):(b=_.ProjectionManager.getProjection("EPSG:3857").project(y[0],y[1]),k.push(b[0]-u[0],b[1]-u[1]),w.push(y));l.push(k),d.push(w)}for(var z=[],g=0,M=c.length;g<M;g+=2)z.push(_.xd(c[g],c[g+1]));_.equals(z[0],z[z.length-1])||z.push(_.Ex(z[0]));for(var C=c.length,g=0;g<l.length;g++)v.push(C/2),C+=l[g].length,_.Util.Ig(c,l[g]);var S=n.Nx(c,v);if(i&&c&&0<this._opts.extrusionHeight){for(var T=z,L=[],g=0;g<l.length;g++)for(var I=l[g],D=0;D<I.length;D+=2)L.push([I[D],I[D+1]]);L&&0<L.length&&(new Uh(L).isClockwise(L)||L.reverse()),new Uh(z).isClockwise(z)&&z.reverse(),_.Util.Ig(T,L),this.pdt(i,T,v)}e.add(S);var O=s.Nx(z,{lineJoin:"miter"}).Iw;for(r.add(O),g=0;g<l.length;g++){for(var R=[],E=0,M=(k=l[g]).length;E<M;E+=2)R.push(_.xd(k[E],k[E+1]));R.push(_.xd(k[0],k[1])),O=s.Nx(R,{lineJoin:"miter"}).Iw,r.add(O)}}i&&(this.Dx.upload(i),this.Px.upload(i))},Xh.prototype.JL=function(){this.Dx||(this.Dx=new _.K_),this.Px||(this.Px=new _.J_),this.XB||(this.XB=new _.oE),this.qB||(this.qB=new _.oE),this.p0||(this.p0=new _.iz),this.m0||(this.m0=new _._w)};var Zh,Ti=Xh;function Xh(){return null!==Zh&&Zh.apply(this,arguments)||this}var Jh,Kh,Hh={map:void 0,fillColor:"#00D3FC",fillOpacity:.5,strokeColor:"#00B2D5",strokeWeight:2,strokeOpacity:.9,strokeStyle:"solid",draggable:!1,extrusionHeight:0,bubble:!1,strokeDasharray:[10,5],zIndex:50,extData:{},noSelect:!1,innerOverlay:!1,zooms:_.zoomRange,async:!1},Vh={constructor:{time:0,highResTime:0},setPath:{time:0,highResTime:0}},qh=(Jh=Ti,_.Ei(O,Jh),O.prototype.getOptions=function(){return _.extend({},this._opts)},O.prototype.setOptions=function(t){var t=this.nY(t),i=!_.isEqual(this._opts.path,t.path);this._opts=t,this._checkMap(),i&&this.setPath(this._opts.path),this.to()},O.prototype.init=function(t){this.reset(),t=t||this._opts,this._opts=this.nY(t),this.setPath(this._opts.path),this._map&&(0<this._opts.extrusionHeight&&(this.zdt=this.Cdt.bind(this),this.Sdt=this.Ldt.bind(this),this.tv()),this._map.setNeedUpdate(!0))},O.prototype.destroy=function(){0<this._opts.extrusionHeight&&(this.Tdt(),this.zdt=null,this.Sdt=null),this.gdt&&delete this.gdt,this._opts,Jh.prototype.destroy.call(this)},O.prototype.getPath=function(){if(this._opts&&this._opts.path)return _.parseLngLatData(_.yn(this._opts.path))},O.prototype.getStatus=function(){return this.Ndt},O.prototype.setExtrusionHeight=function(t){this._opts&&(this._opts.extrusionHeight=t,this.reset(),this.Ix(this._opts.path)),this.to()},O.prototype.getExtrusionHeight=function(){return this._opts&&this._opts.extrusionHeight?this._opts.extrusionHeight:0},O.prototype.getBounds=function(){var t;if(this.ir)t=this.ir;else{var i=this._opts.path;if(!i)return;if(!(i=yh(i)))return;(i=l.ms(i))&&(t=this.ir=i)}if(t)return this._map&&this.zx&&(0!==this.zx[0]||0!==this.zx[1])?(i=t.getSouthWest(),t=t.getNorthEast(),i=this._map.getView().ru().moveWithPos([i.KL,i.kT],this.zx),t=this._map.getView().ru().moveWithPos([t.KL,t.kT],this.zx),new l(i,t)):this.ir},O.prototype.getArea=function(){var t;return this._opts&&this._opts.path?(t=_.jsonLngLatData(this._opts.path),_.ys(t)?+_.GeometryUtil.ringArea(t).toFixed(2):_.Ox(t)?+Ch(t).toFixed(2):+Sh(t).toFixed(2)):0},O.prototype.contains=function(t,i){var n,s,e;return!!this.jx()&&(n=this._opts.path,s=_.parseLngLatData(t),!!(e=null==(e=this._map)?void 0:e.lngLatToContainer(s)))&&(0<this._opts.extrusionHeight&&(this._opts.bubble&&i&&i.Adt&&"click"===i.Adt&&(this.gdt=!1),!this.gdt)&&(0<(i=this.queryPolyhedronFeature([e.x,e.y]))&&i===this.hS)||!(this.ir&&!this.ir.contains(t))&&(_.ys(n)?bh:_.Ox(n)?gh:Mh)([s.lng,s.lat],n))},O.prototype.setPath=function(t){var i;t&&(this.reset(),this.Ix(t),t=(new Date).getTime(),i=0,"performance"in window&&"function"==typeof performance.now&&(i=performance.now()),this.Ndt&&(this.Ndt.setPath={time:t,highResTime:i}),this.to())},O.prototype.iE=function(t){if(this.jx()&&(!this.ir||this.ir.contains(t))){var i=this._opts.path,t=_.parseLngLatData(t);if(_.ys(i))return 0;if(_.Ox(i))return 0;for(var n=[t.lng,t.lat],s=i,e=0,r=s.length;e<r;e++)if(gh(n,s[e]))return e}return-1},O.prototype.ZB=function(t){var i,n=this;this._map&&(this._needUpdate=!1,this._opts.path)&&(i=yh(this._opts.path))&&(this._opts.async?this._map.gn.QB({data:i,type:"polygon"},function(t,i){t?console.log(t):(n.Dx=i.Dc,n.Px=i.$c,n.Sx=i.Sx,n.XB=i.Oc,n.qB=i.Uc)}):this.Q$(i,t))},O.prototype.queryPolyhedronFeature=function(t){if(this._map&&this.bdt()){for(var i,s=(n=this._map).getView().getStatus(),s={layers:n.getLayers(),uo:n.Mv,size:s.size,do:n.do,viewState:s,map:n},e=0,r=n.getLayers();e<r.length;e++){var h=r[e];"AMap.VectorLayer"===h.CLASS_NAME&&(i=h)}var o=i.getRender();if(o){var a=o.pu||0,n=n.getGL(),u=t[0]*a,t=n.drawingBufferHeight-t[1]*a,a=new Uint8Array(4);if(o.vdt&&(s=o.pickRender(s,this),n.bindFramebuffer(n.FRAMEBUFFER,s),n.readPixels(u,t,1,1,n.RGBA,n.UNSIGNED_BYTE,a),n.bindFramebuffer(n.FRAMEBUFFER,null)),u=(s=o.ydt)&&s.GV([a[0],a[1],a[2]]))return u}}},O.prototype.Cdt=function(){this.gdt=!0},O.prototype.Ldt=function(){this.gdt=!1},O.prototype.tv=function(){this._map&&(this._map.on("mousedown",this.zdt),this._map.on("mouseup",this.Sdt))},O.prototype.Tdt=function(){this._map&&(this._map.off("mousedown",this.zdt),this._map.off("mouseup",this.Sdt))},O.prototype._dragging=function(t){var i,n,s;this.getDraggable()&&(n=this._dragObjects.hy,i=t.pos[0]-n[0],n=t.pos[1]-n[1],this._dragObjects.sy,s=this.getDeltaCoord(),this.b_([i+s[0],n+s[1]]),this.Ay(t),this.F$&&"d"===this._map.baseRender?this.moveWithPixel(this.B$[0],-1*this.B$[1]):this.moveWithPos(this.zx[0],this.zx[1]),this.BB(),this.B$=[0,0],this.F$&&(this.F$.style.transform="",this.F$.style.webkitTransform=""),this.to())},O.prototype.jx=function(){return Boolean(this._opts&&this._opts.path&&0<this._opts.path.length)},O.prototype.moveWithPixel=function(t,i){var n,s,e;this._map&&(n=this._map,s=_.ProjectionManager.getProjection(n.getView().au()),e=this._opts.path,e=(_.ys(e)?xh:_.Ox(e)?Ah:function(t,i,n,s){for(var e=[],r=0,h=t;r<h.length;r++){var o=Ah(h[r],i,n,s);e.push(o)}return e})(e,[t,i],n.getZoom(),s),this.setPath(e))},O.prototype.moveWithPos=function(t,i){var n,s;this._map&&(n=this._map,n=_.ProjectionManager.getProjection(n.getView().au()),s=this._opts.path.slice(0),s=(_.ys(s)?kh:_.Ox(s)?wh:function(t,i,n){for(var s=[],e=0,r=t;e<r.length;e++){var h=wh(r[e],i,n);s.push(h)}return s})(s,[t,i],n),this.setPath(s))},O.prototype.bdt=function(){var t;return!(this._opts.fillOpacity<=0||null!=(t=this._map)&&t.TL()||(t=this._map.getZoom())<this._opts.zooms[0]||t>this._opts.zooms[1])},O);function O(t){void 0===t&&(t={});var n=Jh.call(this)||this,i=(n.Ix=function(t){var i;n._opts.path=_.jsonLngLatData(t),(t=yh(t))&&(n.ir=l.ms(t),i=n._map)&&("d"===i.baseRender?n.X$(t):n.cE())},t.path),i=(_.iL(i)?(s=i[0],n.Tx(s)):_.eL(i)?(s=i[0][0],n.Tx(s)):_.yL(i)&&(s=i[0][0][0],n.Tx(s)),n.className="Overlay.Polygon",n._opts={fillColor:"#00D3FC",fillOpacity:.5,strokeColor:"#00B2D5",strokeWeight:2,strokeOpacity:.9,strokeStyle:"solid",draggable:!1,extrusionHeight:0,wallColor:"#00D3FC",roofColor:"#00B2D5",bubble:!1,strokeDasharray:[10,5],zIndex:50,extData:{},noSelect:!1,innerOverlay:!1,zooms:_.zoomRange,async:!1},n._opts=n.nY(t),n._checkMap(),n.Ndt=Vh,(new Date).getTime()),s=0;return"performance"in window&&"function"==typeof performance.now&&(s=performance.now()),n.Ndt.constructor={time:i,highResTime:s},n}function Qh(){var n=null!==Kh&&Kh.apply(this,arguments)||this;return n.contains=function(t){var i;return!(!n.aE||n.ir&&!n.ir.contains(t))&&(i=n.aE,t=_.parseLngLatData(t),(_.ys(i)?bh:_.Ox(i)?gh:Mh)([t.lng,t.lat],i))},n}Kh=Ti,_.Ei(Qh,Kh),Qh.prototype.getOptions=function(){return _.extend({},this._opts)},Qh.prototype.getArea=function(){var t=this.aE;return t?+Sh(t).toFixed(2):0},$h=Oi=Qh,_.Ei(io,$h),io.prototype.init=function(t){t=t||this._opts,this._opts=this.nY(t),this.setBounds(t.bounds)},io.prototype.setBounds=function(t){t&&(_.xs(t)||(t=new l(t)),this._opts.bounds=t,this.ir=t.clone(),this.cE(),this.to())},io.prototype.ZB=function(t){var i,n,s;this._map&&(this._needUpdate=!1,i=this._opts.bounds)&&(n=this._map,(s=yh(Ph(i)))&&(this.ir=i.clone(),this.aE=s,"d"===n.baseRender?this.X$(s):this.Q$(s,t)),this.to())},io.prototype.moveWithPixel=function(t,i){var n,s,e;this._map&&(n=this._map,s=(e=this._opts.bounds).southWest.toJSON(),e=e.northEast.toJSON(),s=this._map.getView().ru().moveWithPixel(s,[t,i],n.getZoom()),e=this._map.getView().ru().moveWithPixel(e,[t,i],n.getZoom()),t=new l(s,e),this.setBounds(t))},io.prototype.moveWithPos=function(t,i){var n,s;this._map&&(n=(s=this._opts.bounds).southWest.toJSON(),s=s.northEast.toJSON(),n=this._map.getView().ru().moveWithPos(n,[t,i]),s=this._map.getView().ru().moveWithPos(s,[t,i]),t=new l(n,s),this.setBounds(t))},io.prototype.setOptions=function(t){var t=this.nY(t),i=!_.isEqual(this._opts.bounds,t.bounds);this._opts=t,this._checkMap(),i&&this.setBounds(t.bounds),this.to()},io.prototype.getPath=function(){var t,i,n;if(!this.ir){var s=this._opts.bounds;if(!s)return;this.ir=s.clone()}if(s=this.ir)return this.P$&&(i=s.getSouthWest(),n=s.getNorthEast(),i=this._map.getView().ru().moveWithPos([i.KL,i.kT],this.zx),n=this._map.getView().ru().moveWithPos([n.KL,n.kT],this.zx),s=new l(i,n)),s?Ph(s):t},io.prototype.getBounds=function(){var t;if(!this.ir){var i=this._opts.bounds;if(!i)return;this.ir=i.clone()}if(i=this.ir)return this.P$?(t=i.getSouthWest(),i=i.getNorthEast(),t=this._map.getView().ru().moveWithPos([t.KL,t.kT],this.zx),i=this._map.getView().ru().moveWithPos([i.KL,i.kT],this.zx),new l(t,i)):this.ir},io.prototype.getCenter=function(){if(this._opts.bounds)return this._opts.bounds.getCenter()};var $h,to=io;function io(t){void 0===t&&(t={});var n=$h.call(this)||this;return n.className="Overlay.Rectangle",n.contains=function(t){var i=n.getBounds();return!!i&&i.contains(t)},n._opts={fillColor:"#00D3FC",fillOpacity:.5,strokeColor:"#00B2D5",strokeWeight:2,strokeOpacity:.9,strokeStyle:"solid",draggable:!1,bubble:!1,strokeDasharray:[10,5],zIndex:50,extData:{},noSelect:!1,innerOverlay:!1,zooms:_.zoomRange,async:!1},n._opts=n.nY(t),n._checkMap(),n}no=Oi,_.Ei(eo,no),eo.prototype.init=function(t){t=t||this._opts,this._opts=this.nY(t),this.setCenterAndRadius(this._opts.center,this._opts.radius)},eo.prototype.setCenter=function(t){this.setCenterAndRadius(t,this._opts.radius)},eo.prototype.setRadius=function(t){this.setCenterAndRadius(this._opts.center,t)},eo.prototype.getCenter=function(){var t=_.parseLngLatData(this._opts.center),t=this._map.getView().ru().moveWithPos([t.KL,t.kT],this.zx);return new _.LngLat(t[0],t[1])},eo.prototype.getRadius=function(){return this._opts.radius},eo.prototype.getPath=function(){var t;return this._opts.center&&this._opts.radius&&(t=Eh(this._opts.center,this._opts.radius,_.Support.$e))&&0<t.length?_.parseLngLatData(_.yn(t)):[]},eo.prototype.setCenterAndRadius=function(t,i){this._opts.center=t,this._opts.radius=i,this.cE(),this.to()},eo.prototype.ZB=function(t){var i,n,s;this._map&&(this._needUpdate=!1,s=this._opts.center,i=this._opts.radius,s)&&i&&(s=_.jsonLngLatData(s),n=this._map,(s=yh(Eh(s,i,_.Support.$e)))&&(this.ir=l.ms(s),this.aE=s,"d"===n.baseRender?this.X$(s):this.Q$(s,t)),this.BB(),this._map.setNeedUpdate(!0))},eo.prototype.moveWithPixel=function(t,i){var n,s;this._map&&(n=this._map,s=_.parseLngLatData(this._opts.center),s=this._map.getView().ru().moveWithPixel([s.KL,s.kT],[t,i],n.getZoom()),this.setCenter(s))},eo.prototype.moveWithPos=function(t,i){var n;this._map&&(n=_.parseLngLatData(this._opts.center),n=this._map.getView().ru().moveWithPos([n.KL,n.kT],[t,i]),this.setCenter(n))},eo.prototype.getBounds=function(){if(!this.ir){var t=this._opts.center,i=this._opts.radius;if(!t||!i)return;var i=Math.max(i[0],i[1]),n=(t=_.parseLngLatData(t)).offset(-i,-i),t=t.offset(i,i);this.ir=new l(n,t)}if(i=this.ir,this.ir)return this.P$?(n=i.getSouthWest(),t=i.getNorthEast(),n=this._map.getView().ru().moveWithPos([n.KL,n.kT],this.zx),t=this._map.getView().ru().moveWithPos([t.KL,t.kT],this.zx),new l(n,t)):this.ir},eo.prototype.setOptions=function(t){var t=this.nY(t),i=!_.isEqual(this._opts.center,t.center)||!_.isEqual(this._opts.radius,t.radius);this._opts=t,this._checkMap(),i&&this.setCenterAndRadius(this._opts.center,this._opts.radius),this.to()};var no,so=eo;function eo(t){void 0===t&&(t={});var i=no.call(this)||this;return i.className="Overlay.Ellipse",i.Cx=_.assign({center:void 0,radius:void 0},Hh),i._opts={fillColor:"#00D3FC",fillOpacity:.5,strokeColor:"#00B2D5",strokeWeight:2,strokeOpacity:.9,strokeStyle:"solid",draggable:!1,bubble:!1,strokeDasharray:[10,5],zIndex:50,extData:{},noSelect:!1,innerOverlay:!1,zooms:_.zoomRange,async:!1},i._opts=i.nY(t),i._checkMap(),i}ro=Oi,_.Ei(ao,ro),ao.prototype.init=function(t){t=t||this._opts,this._opts=this.nY(t),this.setCenterAndRadius(this._opts.center,this._opts.radius)},ao.prototype.setCenter=function(t){this.setCenterAndRadius(t,this._opts.radius)},ao.prototype.setRadius=function(t){this.setCenterAndRadius(this._opts.center,t)},ao.prototype.getCenter=function(){var t,i=_.parseLngLatData(this._opts.center);return this.P$?(t=this._map.getView().ru().moveWithPos([i.KL,i.kT],this.zx),new _.LngLat(t[0],t[1])):i},ao.prototype.getPath=function(){var t;return this._opts.center&&this._opts.radius&&(t=Rh(this._opts.center,this._opts.radius))&&0<t.length?_.parseLngLatData(_.yn(t)):[]},ao.prototype.getRadius=function(){return parseFloat(this._opts.radius)},ao.prototype.setCenterAndRadius=function(t,i){this._opts.center=t,_.vB(i)&&0<=i&&(this._opts.radius=i),this.cE(),this.to()},ao.prototype.ZB=function(t){var i,n,s;this._map&&(this._needUpdate=!1,s=this._opts.center,i=this._opts.radius,s)&&_.vB(i)&&(n=this._map,(s=yh(Rh(s,i)))&&(this.ir=l.ms(s),this.aE=s,"d"===n.baseRender?this.X$(s):this.Q$(s,t)),this.BB(),this._map.setNeedUpdate(!0))},ao.prototype.moveWithPixel=function(t,i){var n,s;this._map&&(n=this._map,s=_.parseLngLatData(this._opts.center),s=this._map.getView().ru().moveWithPixel([s.KL,s.kT],[t,i],n.getZoom()),this.setCenter(s))},ao.prototype.moveWithPos=function(t,i){var n;this._map&&(n=_.parseLngLatData(this._opts.center),n=this._map.getView().ru().moveWithPos([n.KL,n.kT],[t,i]),this.setCenter(n))},ao.prototype.setOptions=function(t){var t=this.nY(t),i=!_.isEqual(this._opts.center,t.center)||!_.isEqual(this._opts.radius,t.radius);this._opts=t,this._checkMap(),i&&this.setCenterAndRadius(this._opts.center,this._opts.radius),this.to()},ao.prototype.O$=function(t,i,n){},ao.prototype.getBounds=function(){if(!this.ir){var t=this._opts.center,i=this._opts.radius;if(!t)return;if(!_.vB(i))return;var n=(t=_.parseLngLatData(t)).offset(-i,-i),t=t.offset(i,i);this.ir=new l(n,t)}if(i=this.ir,this.ir)return this.P$?(n=i.getSouthWest(),t=i.getNorthEast(),n=this._map.getView().ru().moveWithPos([n.KL,n.kT],this.zx),t=this._map.getView().ru().moveWithPos([t.KL,t.kT],this.zx),new l(n,t)):this.ir},ao.prototype.ab=function(t){return delete(t=_.extend({},t)).center,delete t.radius,delete t.map,delete t.path,t};var ro,ho,oo=ao;function ao(t){void 0===t&&(t={});var i=ro.call(this)||this;return i.className="Overlay.Circle",i._opts={fillColor:"#00D3FC",fillOpacity:.5,strokeColor:"#00B2D5",strokeWeight:2,strokeOpacity:.9,strokeStyle:"solid",draggable:!1,bubble:!1,strokeDasharray:[10,5],zIndex:50,extData:{},noSelect:!1,innerOverlay:!1,zooms:_.zoomRange,async:!1},i._opts=i.nY(t),i}function uo(t){var i=ho.call(this)||this;return i.className="Overlay.Circle",i.Tx(t),i}ho=Bt,_.Ei(uo,ho),uo.prototype.Tx=function(t){t&&(t=_.Bs(t)?_.ProjectionManager.getProjection("EPSG:3857").project(t.KL,t.kT):_.ProjectionManager.getProjection("EPSG:3857").project(t[0],t[1]),this.Sx=_.lcs.getLocalByCoord(t))},uo.prototype.setCenter=function(t){t&&(this._opts.center=_.parseLngLatData(t),this.ir=new l(this._opts.center,this._opts.center),this.cE(),this.to())},uo.prototype.destroy=function(){this.KB&&delete this.KB,this.Sb&&(this.Sb.destroy(),delete this.Sb),ho.prototype.destroy.call(this)},uo.prototype.reset=function(){this.KB&&delete this.KB,this.Sb&&this.Sb.reset()},uo.prototype.toGeometry=function(){var t;if(this._opts.center)return{type:"Point",coordinates:(t=_.parseLngLatData(this._opts.center))&&t.toJSON()}},uo.prototype.Ydt=function(n){return _.T8t(this,void 0,void 0,function(){var i;return _.x8t(this,function(t){switch(t.label){case 0:return[4,de.Ydt(n)];case 1:return i=t.y8t(),this.setCenter(i),[2]}})})},uo.prototype.XL=function(t){var i=_.parseLngLatData(t),t=(this.reset(),this.Tx(t),this.Sx.center),i=this._map.getView().ru().project(i.KL,i.kT);this.KB=[i[0]-t[0],i[1]-t[1]],_.Support.safari&&(this.Sb||(this.Sb=new _.e0),this.Sb.wb([i[0]-t[0],i[1]-t[1]]))},co=uo,_.Ei(lo,co),lo.prototype.init=function(t){t=t||this._opts,this._opts=this.nY(t),this.setCenter(this._opts.center)},lo.prototype.setRadius=function(t){this._opts.radius=t,this.to()},lo.prototype.ZB=function(){var t;this._map&&(this._needUpdate=!1,t=this._opts.center)&&this._map&&"d"!==this._map.baseRender&&(this.XL(t),this.BB())},lo.prototype.getCenter=function(){var t,i=_.parseLngLatData(this._opts.center);return this._map?(t=this._map.getView().ru().moveWithPos([i.KL,i.kT],this.zx),new _.LngLat(t[0],t[1])):i},lo.prototype.getRadius=function(){return this._opts.radius},lo.prototype.moveWithPixel=function(t,i){var n,s;this._map&&(n=this._map,s=_.parseLngLatData(this._opts.center),s=this._map.getView().ru().moveWithPixel([s.KL,s.kT],[t,i],n.getZoom()),this.setCenter(s))},lo.prototype.moveWithPos=function(t,i){var n;this._map&&(n=_.parseLngLatData(this._opts.center),n=this._map.getView().ru().moveWithPos([n.KL,n.kT],[t,i]),this.setCenter(n))},lo.prototype.setOptions=function(t){var t=this.nY(t),i=!_.isEqual(this._opts.center,t.center);this._opts=t,this._checkMap(),i&&this.setCenter(t.center),this.to()},lo.prototype.getOptions=function(){return _.extend({},this._opts)},lo.prototype.getBounds=function(){var t;if(!this.ir){var i=this._opts.center;if(!i)return;this.ir=new l(i,i)}if(i=this.ir)return this.P$?(t=i.getSouthWest(),i=i.getNorthEast(),t=this._map.getView().ru().moveWithPos([t.KL,t.kT],this.zx),i=this._map.getView().ru().moveWithPos([i.KL,i.kT],this.zx),new l(t,i)):this.ir},lo.prototype.Ib=function(){var t=(t=this._opts).radius+(t.strokeWeight||0);return Math.min(t,64)};var co,vo,fo=lo;function lo(t){var e=co.call(this,(t=void 0===t?{}:t).center||void 0)||this;return e.contains=function(t){return!!e._map&&(t=e._map.lngLatToContainer(t),e.containsWithPixel(t))},e.containsWithPixel=function(t){var i,n,s;return!!e._map&&!(!e._opts.center||(i=e.Ib(),n=_.parseLngLatData(e._opts.center),n=e._map.getView().ru().moveWithPos([n.KL,n.kT],e.zx),n=e._map.lngLatToContainer(n),Math.abs(n.x-t.x)>i)||Math.abs(n.y-t.y)>i)&&(t=t.toJSON(),n=n.toJSON(),s=Math.abs(t[0]-n[0]),t=Math.abs(t[1]-n[1]),s=Math.sqrt(s*s+t*t),t=e._map.getView().Pu||0,s/Math.cos(t)<i)},e.className="Overlay.CircleMarker",e._opts={radius:20,fillColor:"#00D3FC",fillOpacity:.5,strokeColor:"#00B2D5",strokeWeight:2,strokeOpacity:.9,strokeStyle:"solid",draggable:!1,bubble:!1,strokeDasharray:[10,5],zIndex:50,extData:{},noSelect:!1,innerOverlay:!1,zooms:_.zoomRange,async:!1},e._opts=e.nY(t),t&&t.center&&de._dt(t.center)&&e.Ydt(t.center),e._checkMap(),e}function po(){var u=null!==vo&&vo.apply(this,arguments)||this;return u.sC=0,u.W_=function(){if(_r.isWebGL&&u._map&&u.q$&&!u._opts.geodesic&&!u._needUpdate){var t=u._map,i=Math.min(_.Util.getOptimalZoom(t.getZoom()),20);if(u.EI!==i)if(i<18){u.EI=i;for(var n=_.ProjectionManager.getProjection("EPSG:3857").getResolution(Math.min(_.Util.getOptimalZoom(t.getZoom()),18)),s=[],e=0,r=u.q$;e<r.length;e++){for(var h=r[e],o=[],a=0;a<h.length;a+=1)h[a][2]>n*n*1&&o.push([h[a][0],h[a][1]]);s.push(o)}u.D_(s)}else u.EI=i,u.D_(u.q$)}},u}vo=Bt,_.Ei(po,vo),po.prototype.Tx=function(t){t&&(t=_.Bs(t)?_.ProjectionManager.getProjection("EPSG:3857").project(t.KL,t.kT):_.ProjectionManager.getProjection("EPSG:3857").project(t[0],t[1]),this.Sx=_.lcs.getLocalByCoord(t))},po.prototype.destroy=function(){this.Px&&(this.Px.destroy(),delete this.Px),vo.prototype.destroy.call(this)},po.prototype.toGeometry=function(){var t=this._opts.path;if(t)return _.ys(t)?{type:"LineString",coordinates:t}:_.Ox(t)?{type:"MultiLineString",coordinates:t}:void 0},po.prototype.U_=function(t){this.F_&&!this.E_&&(this.E_=t.createTexture(this.F_,{Zi:!0}),this.E_.bind(t.gl.CLAMP_TO_EDGE,t.gl.LINEAR,t.gl.LINEAR))},po.prototype.aC=function(t,i){this.rC||(i=function(t){for(var i=document.createElement("canvas"),n=(i.height=1,i.width=4096,i.getContext("2d")),s=n.createImageData(4096,1),e=0,r=0;r<4096;r++){for(var h=void 0;e<t.length;e++){if(e===t.length-1){h=t[e][1];break}if(!(4096*t[e+1][0]<r)){h=t[e][1];break}}var h=t[e][1],a=_.Util.color2RgbaArray(h);s.data[4*r]=255*a[0],s.data[4*r+1]=255*a[1],s.data[4*r+2]=255*a[2],s.data[4*r+3]=255*a[3]}return n.putImageData(s,0,0),i}(i.values),this.rC=t.createTexture(i,{Zi:!0}),i=t.gl,this.rC.bind(i.CLAMP_TO_EDGE,i.NEAREST,i.NEAREST_MIPMAP_NEAREST))},po.prototype.X$=function(t){for(var i=[],n=[],s=0,e=t;s<e.length;s++){for(var r=[],h=[],o=0,a=e[s];o<a.length;o++){var u=a[o],c=_.ProjectionManager.getProjection("EPSG:3857").project(u[0],u[1]);r.push([c[0],c[1]]),h.push(u)}i.push(r),n.push(h)}this.$x=n,this.q$=i},po.prototype.Q$=function(t){for(var i=[],n=[],s=0,e=t;s<e.length;s++){for(var r=[],h=[],o=0,a=e[s];o<a.length;o++){var u=a[o],c=_.ProjectionManager.getProjection("EPSG:3857").project(u[0],u[1]);r.push([c[0],c[1],0]),h.push(u)}this.P_(r),i.push(r),n.push(h)}this.$x=n,this.q$=i,this.cE()},po.prototype.D_=function(t,i){if(0!==t.length){this.Px?this.Px.reset():this.Px=new _.J_;for(var n=this.Sx.center,s=0,e=_.ProjectionManager.getProjection("EPSG:3857"),r=this.EI,h=e.getResolution(r),o=0,a=t;o<a.length;o++){for(var u=a[o],c=[],f=0,l=u.length;f<l;f+=1)c.push(u[f][0]-n[0],u[f][1]-n[1]);var d=this._opts;10<=this.EI&&(this._opts.showDir||"dashed"===this._opts.strokeStyle)?s+=this.Px.eD(c,{X_:1,lineJoin:d.lineJoin,lineCap:d.lineCap},Math.floor(2048*h)).distance:s+=this.Px.hb(c,{X_:1,lineJoin:d.lineJoin,lineCap:d.lineCap}).distance}this.sC=s,i&&this.Px.upload(i)}},po.prototype.P_=function(t){t[0][2]=1/0,t[t.length-1][2]=1/0;var i=_.ProjectionManager.getProjection("EPSG:3857").getResolution(16);!function t(i,n,s,e){for(var r=e,h=s-n>>1,o=s-n,a=s,u=i[n][0],c=i[n][1],f=i[s][0],l=i[s][1],d=n+1;d<s;d+=1){var v=function(t,i,n,s,e,r){var h,o=e-n,a=r-s;return 0==o&&0==a||(1<(h=((t-n)*o+(i-s)*a)/(o*o+a*a))?(n=e,s=r):0<h&&(n+=o*h,s+=a*h)),(o=t-n)*o+(a=i-s)*a}(i[d][0],i[d][1],u,c,f,l);r<v?(a=d,r=v):v===r&&(v=Math.abs(d-h))<o&&(a=d,o=v)}e<r&&(1<a-n&&t(i,n,a,e),i[a][2]=r,1<s-a)&&t(i,a,s,e)}(t,0,t.length-1,i*i)};var mo,yo={constructor:{time:0,highResTime:0},setPath:{time:0,highResTime:0}},bo=(mo=Xt=po,_.Ei(R,mo),R.prototype.getOptions=function(){return _.extend({},this._opts)},R.prototype.getPath=function(){if(this._opts&&this._opts.path)return _.parseLngLatData(_.yn(this._opts.path))},R.prototype.getStatus=function(){return this.Ndt},R.prototype.destroy=function(){this.E_&&(this.E_.destroy(),delete this.E_),mo.prototype.destroy.call(this)},R.prototype.getBounds=function(){var t;if(this.ir)t=this.ir;else{var i=this._opts.path;if(!i)return;if(!(i=Th(i)))return;(i=l.bS(i))&&(t=this.ir=i)}if(t)return this._map&&this.zx&&(0!==this.zx[0]||0!==this.zx[1])?(i=t.getSouthWest(),t=t.getNorthEast(),i=this._map.getView().ru().moveWithPos([i.KL,i.kT],this.zx),t=this._map.getView().ru().moveWithPos([t.KL,t.kT],this.zx),new l(i,t)):this.ir},R.prototype.setPath=function(t){var i;t&&(this.Ix(t),t=(new Date).getTime(),i=0,"performance"in window&&"function"==typeof performance.now&&(i=performance.now()),this.Ndt&&(this.Ndt.setPath={time:t,highResTime:i}),this.to())},R.prototype.moveWithPixel=function(t,i){if(this._map){for(var n=this._map,s=_.ProjectionManager.getProjection(n.getView().au()),e=[],r=0,h=this.$x;r<h.length;r++){for(var o=[],a=0,u=h[r];a<u.length;a++){var c=u[a];o.push(s.moveWithPixel(c,[t,i],n.getZoom()))}e.push(o)}this.setPath(e)}},R.prototype.moveWithPos=function(t,i){if(this._map){for(var n=this._map,s=_.ProjectionManager.getProjection(n.getView().au()),e=[],r=0,h=this.$x;r<h.length;r++){for(var o=[],a=0,u=h[r];a<u.length;a++){var c=u[a];o.push(s.moveWithPos(c,[t,i]))}e.push(o)}this.setPath(_.parseLngLatData(e))}},R.prototype.getLength=function(){var t=this._opts&&this._opts.path;return _.ys(t)?+Lh(t).toFixed(2):_.Ox(t)?+function(t){for(var i=0,n=0,s=t;n<s.length;n++)i+=Lh(s[n]);return i}(t).toFixed(2):0},R.prototype.rL=function(){return this.sC},R.prototype.ZB=function(t){this._map&&(this._needUpdate=!1,this.D_(this.q$,t))},R.prototype.setOptions=function(t){var t=this.nY(t),i=function(t,i,n){for(var s=0,e=n.length;s<e;s+=1){var r=n[s];if(t[r]!==i[r])return!0}return!1}(this._opts,t,["path","lineCap","lineJoin","geodesic"]);t.lineGradient!==this._opts.lineGradient&&this.rC&&(this.rC.destroy(),delete this.rC),this._opts=t,this._checkMap(),i&&this.setPath(this._opts.path),this.to()},R.prototype.init=function(t){var i,n=this,t=t||this._opts,t=this.nY(t);this._opts=t,this._opts.dirImg&&(this._opts.dirImg instanceof HTMLCanvasElement?this.F_=this._opts.dirImg:(i=this._opts.dirImg,this._map.z_.loadImage(this._opts.dirImg,{type:"dirImg",cb:function(t){t?n.F_=t.img:console.error("load dirImg error",i)}}))),this.setPath(this._opts.path),this._map&&(this.W_(),this._map.setNeedUpdate(!0))},R.prototype.contains=function(t){if(this.jx()&&(!this.ir||this.ir.southWest.lat===this.ir.northEast.lat||this.ir.southWest.lng===this.ir.northEast.lng||this.ir.contains(t)))for(var i=this._map.getView(),n=i.getStatus().pitch*Math.PI/180,t=_.parseLngLatData(t),s=i.ru().project(t.lng,t.lat),e=i.ru().getResolution(this._map.getZoom()),r=0,h=this.q$;r<h.length;r++){var o=h[r];if(_.hL.lr(s,o)*Math.cos(n)<this._opts.strokeWeight*e)return!0}return!1},R.prototype.jx=function(){return Boolean(this._opts&&this._opts.path&&0<this._opts.path.length)},R.prototype.Ix=function(t){var i=_.jsonLngLatData(t);this._opts.path=i,i=Th(t),_.Ox(i)?(this._opts.geodesic&&(i=_.map(i,Ih)),this.Tx(i[0][0]),this.ir=l.bS(i),this._map&&("d"===this._map.baseRender?this.X$(i):(this.Q$(i),this.BB()))):console.error("error Polyline path")},R.prototype.rD=function(t){var i=_.jsonLngLatData(t);this._opts.path=i,i=Th(t),_.Ox(i)?(this._opts.geodesic&&(i=_.map(i,Ih)),this.Tx(i[0][0]),this.ir=l.bS(i)):console.error("error Polyline path")},R);function R(t){void 0===t&&(t={});var i=mo.call(this)||this,t=(i.className="Overlay.Polyline",i._opts={cursor:"",strokeColor:"#00B2D5",strokeWeight:2,strokeOpacity:.5,strokeStyle:"solid",draggable:!1,bubble:!1,strokeDasharray:[10,5],isOutline:!1,geodesic:!1,showDir:!1,outlineColor:"#00B2D5",borderWeight:1,lineJoin:"miter",lineCap:"butt",extData:{},zIndex:50,dirColor:"white",dirImg:"",lineGradient:void 0,noSelect:!1,innerOverlay:!1,zooms:_.zoomRange,animate:!1,speed:100,dirImgGap:1},i.EI=-1,i._opts=i.nY(t),i._opts.path&&i.rD(i._opts.path),i._checkMap(),i.Ndt=yo,(new Date).getTime()),n=0;return"performance"in window&&"function"==typeof performance.now&&(n=performance.now()),i.Ndt.constructor={time:t,highResTime:n},i}go=Xt,_.Ei(Mo,go),Mo.prototype.getOptions=function(){return _.extend({},this._opts)};var go,hi=Mo;function Mo(){return null!==go&&go.apply(this,arguments)||this}wo=_.LngLat,_.Ei(Ao,wo),Ao.prototype.lL=function(){for(var t=[],i=0,n=this.controlPoints;i<n.length;i++){var s=n[i];t.push(s.toJSON())}return t.push(this.toJSON()),t},Ao.prototype.moveWithPos=function(t,i,n){for(var s=t.moveWithPos(this.toJSON(),[i,n]),e=[],r=0,h=this.controlPoints.length;r<h;r++){var o=this.controlPoints[r];e.push(t.moveWithPos(o.toJSON(),[i,n]))}return e.push(s),new Ao(e)},Ao.prototype.moveWithPixel=function(t,i,n,s){for(var e=t.moveWithPixel(this.toJSON(),[i,n],s),r=[],h=0,o=this.controlPoints.length;h<o;h++){var a=this.controlPoints[h];r.push(t.moveWithPixel(a.toJSON(),[i,n],s))}return r.push(e),new Ao(r)};var wo,xo=Ao;function Ao(t){var i=this;if(_.ys(t))for(var n=t.length,i=wo.call(this,t[n-1][0],t[n-1][1])||this,s=[],e=0,r=n-1;e<r;e+=1){var h=t[e][0],o=t[e][1];s.push(new _.LngLat(h,o))}else for(n=t.length,i=wo.call(this,t[n-2],t[n-1])||this,s=[],e=0,r=n-2;e<r;e+=2)h=t[e],o=t[e+1],s.push(new _.LngLat(h,o));return i.controlPoints=s,i}zo=hi,_.Ei(So,zo),So.prototype.init=function(t){var i,n=this,t=t||this._opts;this._opts=this.nY(t),this._opts.dirImg&&(this._opts.dirImg instanceof HTMLCanvasElement?this.F_=this._opts.dirImg:(i=this._opts.dirImg,this._map.z_.loadImage(this._opts.dirImg,{type:"dirImg",cb:function(t){t?n.F_=t.img:console.error("load dirImg error",i)}}))),this.setPath(this._opts.path),this._map&&(this.W_(),this._map.setNeedUpdate(!0))},So.prototype.setOptions=function(t){var t=this.nY(t),i=!_.isEqual(this._opts.path,t.path);this._opts=t,this._checkMap(),i&&this.Ix(this._opts.path),this.BB(),this.to()},So.prototype.ZB=function(t){this._map&&(this._needUpdate=!1,this.D_(this.q$,t))},So.prototype.getPath=function(){if(this._opts)return this._opts.path},So.prototype.setPath=function(t){t&&(this._opts.path=t,this.Ix(t))},So.prototype.getBounds=function(){var t;if(this.ir)t=this.ir;else{var i=this.$x;if(!i)return;if(!(i=Th(i)))return;(i=l.bS(i))&&(t=this.ir=i)}if(t)return this._map&&this.zx&&(0!==this.zx[0]||0!==this.zx[1])?(i=t.getSouthWest(),t=t.getNorthEast(),i=this._map.getView().ru().moveWithPos([i.KL,i.kT],this.zx),t=this._map.getView().ru().moveWithPos([t.KL,t.kT],this.zx),new l(i,t)):this.ir},So.prototype.moveWithPos=function(t,i){if(this._map){var n=this._map,s=_.ProjectionManager.getProjection(n.getView().au());if(n=this.getPath()){for(var e=[],r=0,h=n;r<h.length;r++){var o=h[r],o=(o=new xo(o)).moveWithPos(s,t,i);e.push(o.lL())}this.setPath(e)}}},So.prototype.moveWithPixel=function(t,i){if(this._map){var n=this._map,s=_.ProjectionManager.getProjection(n.getView().au()),e=this.getPath();if(e){for(var r=[],h=n.getZoom(),o=0,a=e;o<a.length;o++){var u=a[o],u=(u=new xo(u)).moveWithPixel(s,t,i,h);r.push(u.lL())}this.setPath(r)}}},So.prototype.contains=function(t){if(this.jx()&&(!this.ir||this.ir.contains(t)))for(var i=this._map.getView(),n=i.getStatus().pitch*Math.PI/180,t=_.parseLngLatData(t),s=i.ru().project(t.lng,t.lat),e=i.ru().getResolution(this._map.getZoom()),r=0,h=this.q$;r<h.length;r++){var o=h[r];if(_.hL.lr(s,o)*Math.cos(n)<this._opts.strokeWeight*e)return!0}return!1},So.prototype.Ix=function(t){var i=[];if(t)for(var n=0,s=t;n<s.length;n++){var e=s[n];i.push(new xo(e))}t=Th(this.yb(i)),this.Tx(t[0][0]),this.ir=l.bS(t),this._map&&("d"===this._map.baseRender?this.X$(t):(this.Q$(t),this.BB()))},So.prototype.jx=function(){return Boolean(this._opts&&this._opts.path&&0<this._opts.path.length)},So.prototype.yb=function(t){var i;return this._map?(i=_.ProjectionManager.getProjection("EPSG:3857").getResolution(this._map.getZoom()),_.bb.xb(t,i)):[]};var zo,Co=So;function So(t){void 0===t&&(t={});var i=zo.call(this)||this;return i.className="Overlay.BezierCurve",i.bo=3,i.W_=function(){},i._opts={cursor:"",strokeColor:"#00D3FC",strokeWeight:2,strokeOpacity:.5,strokeStyle:"solid",draggable:!1,bubble:!1,strokeDasharray:[10,5],isOutline:!1,geodesic:!1,showDir:!1,outlineColor:"#00B2D5",borderWeight:1,lineJoin:"miter",lineCap:"butt",extData:{},zIndex:50,dirColor:"white",dirImg:"",lineGradient:void 0,noSelect:!1,innerOverlay:!1,zooms:_.zoomRange},i.EI=-1,i._opts=i.nY(t),i._checkMap(),i}var To,Ro={high:{fillColor:"rgb(252, 249, 242)",strokeColor:"rgb(230,142,0)"},unHigh:{fillColor:"rgb(252, 249, 242)",strokeColor:"rgb(171,171,171)"}},Eo=(To=s,_.Ei(E,To),E.prototype.Do=function(t){return t&&(this.Jh=t).HF(this),t},E.prototype.onAdd=function(){var t;this.$F=new is({zIndex:this.Qh,visible:this.il,TF:!0}),null!=(t=this.map)&&t.addLayer(this.$F)},E.prototype.v$=function(){var t;null!=(t=this.map)&&t.removeLayer(this.$F)},E.prototype.destroy=function(){To.prototype.destroy.call(this),this.$F.destroy(),this.$F&&this.$F.destroy&&(this.$F.destroy(),delete this.$F)},E.prototype.yD=function(){return{show:this.xD}},E.prototype.mD=function(t){this.xD=t},E.prototype.cD=function(){var n=this;if(this.dD)return!1;this.dD=!0,this._map.on("moveend",function(){var t=n._map.getZoom(),i=n.VR;n.VR.showId,i&&i.centerId&&i.indoor&&(!n.ZT(i.indoor)||t<n.xt[0]?(n.e$&&(n.e$.hide(),n.xD=!1),n.nD()):n.e$&&n.VR.visible&&(n.mL||n.e$.show(),n.xD=!0))})},E.prototype.uD=function(){for(var t=this.VR,i=t.indoor,n=t.centerId,s=Object.keys(i),e=Ro,r=0;r<s.length;r++){var h=s[r];if(i[h]&&i[h].outline)for(var o=i[h].outline,a=0;a<o.length;a++){var u=o[a],c=u.getOptions();c.strokeColor=(h===n?e.high:e.unHigh).strokeColor,u.setOptions(c)}}},E.prototype.oZ=function(){for(var t=this.VR,i=t.indoor,n=(t.centerId,Object.keys(i)),s=Ro,e=0;e<n.length;e++){var r=n[e];if(i[r]&&i[r].outline)for(var h=i[r].outline,o=0;o<h.length;o++){var a=h[o],u=a.getOptions();u.strokeColor=s.unHigh.strokeColor,a.setOptions(u)}}},E.prototype.BT=function(){var t=this;setTimeout(function(){t._map&&t._map.emit("indoor_create")},500)},E.prototype.bL=function(t){this.VR.opacity=t,this.gL()},E.prototype.wL=function(t){this.VR.zIndex=t,this.gL()},E.prototype.ZI=function(){return this.VR},E.prototype.KI=function(t){this.VR=t},E.prototype.getState=function(){return{zooms:[17,_.zoomRange[1]],visible:this.il,opacity:this.tl,layer:this,rejectMapMask:this._rejectMapMask,depthTest:this.AF,ce:this.IF}},E.prototype.getSourceConfig=function(){return{id:this._id,type:"indoor",zooms:[17,_.zoomRange[1]],url:""}},E.prototype.co=function(){return this._id},E.prototype.getMap=function(){return this._map},E.prototype.n$=function(t,i){this.VR.floorInfo||(this.VR.floorInfo={}),this.VR.floorInfo[t]=i},E.prototype.emit=function(t,i){return To.prototype.emit.call(this,t,i),this},E.prototype.showId=function(t){this.VR.showId=t},E.prototype.setBar=function(t){this.e$=t},E.prototype.setBarOpt=function(t){this.VR.defaultBarFloor=t},E.prototype._hideLayer=function(t){this.VR.visible=t,this.DT(t),this._hideBar(!t),t?this.$F.show():this.$F.hide(),this.gL()},E.prototype._hideBar=function(t){this.mL=t,this.VR.hideFloorBar=t,this.e$&&t?this.e$.hide():this.e$&&this.e$.show()},E.prototype._showLabels=function(t){this.VR.showLabels=t;var i=this._map&&this._map.showLabel;this.VR.labelsLayer&&t&&i?this.VR.labelsLayer.show():this.VR.labelsLayer&&this.VR.labelsLayer.hide()},E.prototype.setShowId=function(t){this.VR.hasId=t},E.prototype.update=function(){this.gL()},E.prototype._getSelectedBuildingId=function(){return this.VR.centerId},E.prototype._getSelectedBuilding=function(){return this.VR.building},E.prototype.setRenderData=function(t){this.VR=_.assign(this.VR,t)},E.prototype.getIntersectPoly=function(t){var t=t.getBounds(),n=this._map&&this._map.getBounds();return!(!t||!n)&&n.intersects(t)},E.prototype.getIntersect=function(t){if(!t)return!1;for(var i=!1,n=this._map&&this._map.getBounds(),s=0;s<t.length;s++){var e=t[s],e=new AMap.LngLat(e[0],e[1]);if(i=n.contains(e))return!0}return i},E.prototype.getRingInRing=function(t){var i;return!!t&&(i=this._map&&this._map.getBounds(),t=new AMap.Polygon({path:t}),_.GeometryUtil.isRingInRing(i,t))},E.prototype.YR=function(t,s){var i,e=this;try{this._map&&this._map.gn&&((i=new XMLHttpRequest).onreadystatechange=function(){4===i.readyState&&200===i.status&&e._map.gn.JB(i.response,function(t,i){var n;t?console.log(t):(n=(t=Object.keys(i))[0]?i[t[0]].building:void 0)&&n.properties&&n.properties.outside_outline&&(n=i[t[0]].building.properties.outside_outline,i=AMap.Bounds.xS(n))&&e._map.setBounds(i),s&&s()})},i.open("GET",t,!0),i.responseType="arraybuffer",i.send())}catch(t){}},E.prototype.DT=function(t){for(var i=this.VR.indoor,n=Object.keys(i),s=0;s<n.length;s++){var e=i[n[s]];if(e.polygons)for(var r=0;r<e.polygons.length;r++){var h=e.polygons[r];t?h.show():h.hide()}if(e.markers)for(var o=0;o<e.markers.length;o++){var a=e.markers[o];t?a.show():a.hide()}}},E.prototype.ZT=function(t){for(var i=Object.keys(t),n=0;n<i.length;n++){var s=i[n];if(this._map&&t[s].outline&&(s=t[s].outline,s=this.getIntersectPoly(s[0])))return s}return!1},E.prototype.gL=function(){},E.prototype.nD=function(){for(var t=this.VR.indoor,i=Object.keys(t),n=0;n<i.length;n++){var s=i[n],e=t[s];e.polygons&&this.$F.remove(e.polygons),e&&e.markers&&0<e.markers.length&&this.VR.labelsLayer&&this.VR.labelsLayer.remove(e.markers),delete t[s]}},E);function E(t){var i=To.call(this)||this;return i.CLASS_NAME="AMap.IndoorLayer",t=t||{},i._id="indoor",i.il=!0,i.Qh=t.zIndex||5,i.tl=t.opacity||1,i.mL=t.hideFloorBar||!1,i.xL=t.cursor||"auto",i.xt=[17,_.zoomRange[1]],i.xD=!1,i.dD=!1,0===t.opacity&&(i.tl=0),i.VR={opacity:i.tl,zIndex:i.Qh,visible:i.il,cursor:i.xL,centerId:null,centerFloor:null,indoor:{},hideFloorBar:i.mL,showLabels:!0,reRender:!1,floorInfo:{},indoorState:{},centerBuilding:{}},t&&t.map&&(i._map=t.map,i.cD()),i._config=AMap.getConfig(),i.BT(),i}Po=Eo,_.Ei(Bo,Po),Bo.prototype.showIndoorMap=function(t,i,n){var s,e,i=i||1;t&&(this.pL=t,Po.prototype.showId.call(this,t),Po.prototype.n$.call(this,t,i),this.pL=t,e=this._config.server+"/v3/indoor/indoormaps?",(s=[]).push("poiid="+t),s.push("floor="+i),s.push("version=0"),s.push("s=rsv3"),s.push("from=indoorH5Map"),s.push("servicetype=unify"),s.push("key="+this._config.key),this._config.jscode?s.push("jscode="+this._config.jscode):this._config.gaodeserver&&(e=this._config.gaodeserver+"/v3/indoor/indoormaps?"),t=e+s.join("&"),Po.prototype.YR.call(this,t))},Bo.prototype.showFloor=function(t,i){this.pL&&this.showIndoorMap(this.pL,t)},Bo.prototype.show=function(){this._hideLayer(!0)},Bo.prototype.hide=function(){this._hideLayer(!1)},Bo.prototype.getMap=function(){return this._map},Bo.prototype.setMap=function(t){var i=(this._map=t).getStatus().animateEnable;Po.prototype.setRenderData.call(this,{animateState:i}),t.setStatus({animateEnable:!1}),Po.prototype.setMap.call(this,t),Po.prototype.cD.call(this)},Bo.prototype.setzIndex=function(t){Po.prototype.wL.call(this,t)},Bo.prototype.showFloorBar=function(){this._hideBar(!1)},Bo.prototype.hideFloorBar=function(){this._hideBar(!0)},Bo.prototype.setOpacity=function(t){Po.prototype.bL.call(this,t)},Bo.prototype.getOpacity=function(){return Po.prototype.getOpacity.call(this)},Bo.prototype.showLabels=function(){this._showLabels(!0)},Bo.prototype.hideLabels=function(){this._showLabels(!1)},Bo.prototype.getSelectedBuildingId=function(){return Po.prototype._getSelectedBuildingId.call(this)},Bo.prototype.getSelectedBuilding=function(){return Po.prototype._getSelectedBuilding.call(this)};var Po,jo=Bo;function Bo(t){var i=Po.call(this,t)||this;return i.CLASS_NAME="AMap.IndoorMap",i._config=AMap.getConfig(),i.pL="",t&&t.map&&(i._map=t.map,t=t.map.getStatus().animateEnable,Po.prototype.setRenderData.call(i,{animateState:t})),i}function Fo(t,i,n){this.x=i,this.y=n,this.z=t,this.key=t+","+i+","+n}var Wo;function Go(){var t=null!==Wo&&Wo.apply(this,arguments)||this;return t.CLASS_NAME="AMap.DistrictLayer",t._E=AMap.getConfig().protocol+"://mvt.amap.com/getDistrictInfo",t}Wo=v,_.Ei(Go,Wo),Go.prototype.getLayerConfig=function(){var t=Wo.prototype.getLayerConfig.call(this);return t.mapNumber="GS(2019)756",t},Go.prototype.getSourceConfig=function(){return{id:this._id,tileUrl:this._tileUrl||"",type:"districtVectorTile",tileSize:this.Xa||256,zooms:this.xt,dataZooms:this.Qs||[3,16],projection:this.hl||"EPS3857",SOC:this.SOC}},Go.prototype.getLayerOptions=function(){return{zIndex:this.Qh,visible:this.il,zooms:this.xt,opacity:this.tl,adcode:this._adcode,styles:this.Ze,layer:this,rejectMapMask:this._rejectMapMask,depthTest:this.AF}},Go.prototype.getState=function(){return _.Ln({},this.getLayerOptions())},Go.prototype.getDistrictByContainerPos=function(t){if(i=this.map){var n,t=i.containerToLngLat(t),s=i.getProjection().project(t.lng,t.lat),e=i.getView().getStatus().optimalZoom,i=i.getTileCoordByLngLat(t,this.Xa||256,e-1);if(!(e=(t=this.getSource().getTileCache()).getTile(i))&&i.z<12&&(n=Math.pow(2,i.z)/((this.Xa||256)/256),e=t.getTile(new Fo(i.z,i.x+n,i.y))||t.getTile(new Fo(i.z,i.x-n,i.y))),e&&e.localCoord&&e.data){var r=[s[0]-e.localCoord.center[0],s[1]-e.localCoord.center[1]],h=e.data;if(h.polygons)for(var o=0,a=h.polygons.length;o<a;o+=1){var u=h.polygons[o];if(3<u.path.length&&3===u.properties.feature_type_){for(var c=[],f=0,l=u.path.length;f<l;f+=2)c.push([u.path[f],u.path[f+1]]);if(AMap.GeometryUtil.pointInRing(r,[[c]]))return u.properties}}}}},Go.prototype.co=function(){return this._id},Go.prototype.destroy=function(){this.Jh&&this.Jh.destroy&&(this.Jh.destroy(),delete this.Jh)},Go.prototype.reload=function(){var t;this.map&&((t=this.getSource()).setTileUrl(this._tileUrl),t.reload(),this.map.setNeedUpdate(!0))},Go.prototype.yE=function(){var n=this;AMap.xE||AMap.bE||(AMap.bE="loading",AMap.Http.Ajax(this._E,{},function(t,i){i&&i.data&&(i=JSON.parse(i.data),AMap.xE||(AMap.xE=i,n.wE&&(i=n.wE,n.setFitViewByAdcode(i.CE,i.zE,i.avoid))))}))},No=Go,_.Ei(Uo,No),Uo.prototype.setSOC=function(t){this.SOC=t,this._tileUrl=this.Ml.replace("[SOC]",this.SOC),this.reload()},Uo.prototype.setDistricts=function(t){this.setAdcode(t)},Uo.prototype.getDistricts=function(){return this._adcode},Uo.prototype.setStyles=function(t){this.Ze=_.Util.baseAssign(_.Util.baseAssign({},this.tP.styles),t),this.map&&((t=this.getRender())&&t.clearStyleCache(),this.map.setNeedUpdate(!0))},Uo.prototype.getStyle=function(){return this.Ze},Uo.prototype.setAdcode=function(t){t instanceof Array||(t=[t]);for(var i,n={},s=0;s<t.length;s+=1)n[t[s]]=1;this._adcode=t=n,null!=(i=this.map)&&i.setNeedUpdate(!0)},Uo.prototype.setFitViewByAdcode=function(t,i,n){var s,e;if(void 0===i&&(i=!1),t instanceof Array||(t=[t]),this.RE||(this.RE=window.AE),AMap.xE){this.RE=AMap.xE;for(var r=0;r<t.length;r+=1){var h=this.RE[t[r]],h=new l(_.Pt(h[0],h[1]));e?e.union(h):e=h}this.map&&null!=(s=this.map)&&s.setBounds(e,i,n)}else this.wE={CE:t,zE:i,avoid:n}},Uo.prototype.on=function(s,t,i,n){var e=this,r=(void 0===n&&(n=!1),this.getEvents()),h=!!r[s];return No.prototype.on.call(this,s,t,i,n),this.map?h||("click"!==s&&"mousemove"!==s||null!=(h=this.map)&&h.on(s,function(t){if(!r[s])return e;t.type=s,t.target=e;var i=t.pixel,i=e.getDistrictByContainerPos(i),i={preProps:e.IE,props:i,origin:t};e.emit(s,i)}),/(mouseenter|mouseleave|mouseover|mouseout)/.test(s)&&(null!=(h=this.map)&&h.on("mouseleave",function(t){if("mouseleave"===s||"mouseout"===s){if(!r[s])return e;t.type=s,t={preProps:(t.target=e).IE,props:void 0,origin:t},e.emit(s,t),e.IE=void 0}}),null!=(h=this.map))&&h.on("mousemove",function(t){if(!r[s])return e;var i,n=t.pixel;(n=e.getDistrictByContainerPos(n))?e.IE&&e.IE.adcode===n.adcode&&e.IE.SOC===n.SOC||(t.type=s,i={preProps:(t.target=e).IE,props:n,origin:t},e.emit("mouseleave",i),e.emit("mouseout",i),e.emit("mouseenter",i),e.emit("mouseover",i),e.IE=n):!e.IE||"mouseout"!==s&&"mouseleave"!==s||(t.type=s,i={preProps:(t.target=e).IE,props:n,origin:t},e.emit("mouseleave",i),e.emit("mouseout",i),e.IE=n)})):(h={fn:t,context:i,once:n},this.LE[s]?this.LE[s].push(h):this.LE[s]=[h]),this},Uo.prototype.onAdd=function(){if(No.prototype.onAdd.call(this),this.LE)for(var t in this.LE)if(this.LE.hasOwnProperty(t))for(var i=this.LE[t],n=0;n<i.length;n++)this.on(t,i[n].fn,i[n].context)};var No,_o=Uo;function Uo(t){var i=No.call(this,t)||this;return i.LE={},i.CX="2"===t.dataVersion?"2":"",i.tP={id:"DistrictLayer_"+_.Util.uuid(),tileUrl:AMap.getConfig().protocol+"://mvt.amap.com/district/[SOC]/[z]/[x]/[y]/4096?\nkey="+AMap.getConfig().key+"&version="+i.CX,zooms:_.zoomRange,dataZooms:[1,18],opacity:1,visible:!0,depth:0,zIndex:80,styles:{"stroke-width":.5,"nation-stroke":[.35,.35,.35,1],"coastline-stroke":[.18,.63,.94,1],"province-stroke":[.5,.5,.5,1],"city-stroke":[.7,.7,.7,1],"county-stroke":[.85,.85,.85,1],fill:[1,1,1,1],dash:void 0,zIndex:0},SOC:"CHN"},i.SOC=t.SOC||i.tP.SOC,i._id=i.tP.id,t.adcode&&i.setAdcode(t.adcode),i._depth=t.depth||i.tP.depth,i.Ze=_.Util.baseAssign(_.Util.baseAssign({},i.tP.styles),t.styles||{}),i.Ml=i.tP.tileUrl,i._tileUrl=i.tP.tileUrl.replace("[SOC]",i.SOC),i.xt=t.zooms||i.tP.zooms,i.tl=(void 0===t.opacity?i.tP:t).opacity,i.il=(void 0===t.visible?i.tP:t).visible,i.Qh=(void 0===t.zIndex?i.tP:t).zIndex,i.Qs=i.tP.dataZooms,i.CLASS_NAME="AMap.DistrictLayer",i}Yo=_o,_.Ei(Zo,Yo);var Yo,Ut=Zo;function Zo(t){var i=this,n={id:"WorldLayer_"+_.Util.uuid(),zIndex:81,SOC:"WLD"};return(i=Yo.call(this,t)||this)._id=n.id,i.SOC=t.SOC||n.SOC,i.Qh=(void 0===t.zIndex?n:t).zIndex,i._tileUrl=i.Ml.replace("[SOC]",i.SOC),i.CLASS_NAME="AMap.DistrictLayer.World",i}Xo=_o,_.Ei(Jo,Xo);var Xo,Vt=Jo;function Jo(t){var i=this,n={id:"CountryLayer_"+_.Util.uuid(),depth:1,zIndex:82,SOC:"CHN"};return 0===(t=t||n).depth&&(t.styles||(t.styles={}),t.styles["stroke-width"]=0),(i=Xo.call(this,t)||this)._id=n.id,i._depth=void 0===t.depth?n.depth:+t.depth,i.SOC=t.SOC||n.SOC,i.Qh=(void 0===t.zIndex?n:t).zIndex,"CHN"===i.SOC&&1<i._depth&&(i.SOC="CHN2"),i._tileUrl=i.Ml.replace("[SOC]",i.SOC),i.CLASS_NAME="AMap.DistrictLayer.Country",i}Ho=_o,_.Ei(Vo,Ho);var Ho,Gt=Vo;function Vo(t){var i=this,n={id:"ProvinceLayer_"+_.Util.uuid(),depth:1,zIndex:83,SOC:"CHN5"};return(i=Ho.call(this,t)||this)._id=n.id,i._depth=void 0===t.depth?n.depth:+t.depth,i.SOC=t.SOC||n.SOC,i.Qh=(void 0===t.zIndex?n:t).zIndex,0===i._depth&&(i.SOC="CHN4"),1===i._depth&&(i.SOC="CHN5"),2===i._depth&&(i.SOC="CHN3"),i._tileUrl=i.Ml.replace("[SOC]",i.SOC),i.CLASS_NAME="AMap.DistrictLayer.Province",i.onCreated(),i}_o.World=Ut,_o.Country=Vt,_o.Province=Gt,qo=ui,_.Ei(Qo,qo),Qo.prototype._l=function(){this.kl.TileMatrixSet=this.kl.TileMatrixSet||"EPSG:3857",this.kl.Request="GetTile",this.kl.Service="WMTS",this.kl.Format=this.kl.Format||"image/png",this._tileUrl=this.Ml+"?"+_.Util.join(this.kl,"&"),this.map&&this.map.setNeedUpdate(!0)},Qo.prototype.getSourceConfig=function(){return{id:this._id||"tile",tileUrl:this._tileUrl||"",type:"markLayer",tileSize:this.Xa||256,zooms:this.xt,dataZooms:this.Qs||[7,17],projection:this.hl||"EPS3857"}};var qo,ia,na,sa,Ko=Qo;function Qo(){var o=this,t={id:"mark_"+_.Util.uuid(),cacheSize:1,opacity:1,tileUrl:"",visible:!0,zIndex:1e3,detectRetina:!1,dataZooms:[2,30],TF:!0};return(o=qo.call(this,t)||this)._opts=t,o.CLASS_NAME="AMap.MarkLayer",o.bl=function(t,i,n,s,e){console.log("_createTile");var r,h=document.createElement("img");"w"===(null==(r=o.map)?void 0:r.baseRender)&&(h.crossOrigin="anonymous"),h.onload=function(){s(h)},h.onerror=function(){e(h)},h.src=o._tileUrl+"&TileMatrix="+n+"&TileRow="+i+"&TileCol="+t},o}function $o(t,i){var s=W(t=Array.isArray(t)?t:[t]);0===s.length?i():(j.add(s,i),F(ia+"/mapsplugin?v="+na+"&cls="+s.join()+"&key="+sa,function(){for(var t=0,i=s;t<i.length;t++){var n=i[t];j.finish(n)}}))}function ta(){return ra}ti=config,ia=(ti=void 0===ti?[]:ti)[16]+"://"+ti[17]||"",na=ti[4],sa=ti[0],ti[18]||console.log("地图 JS API 将于2023年1月1日起,禁止非Web端key的调用权限。请您提前确保已正确使用 Web 端 key 进行服务访问,避免对您的服务产生不必要的影响。"),_.Module.module=function(t,i){var s=W(t=Array.isArray(t)?t:[t]);0===s.length?i&&i():(j.add(s,i),F(ia+"/mapsplugin?v="+na+"&cls="+s.join()+"&key="+sa,function(){for(var t=0,i=s;t<i.length;t++){var n=i[t];j.finish(n)}}))},N('.amap-custom{top:0;left:0;position:absolute}.amap-container img{max-width:none!important;max-height:none!important}.amap-container{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABkCAYAAABw4pVUAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAACC2lUWHRYTUw6Y29tLmFkb2JlLnhtcAAAAAAAPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iWE1QIENvcmUgNS40LjAiPgogICA8cmRmOlJERiB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiPgogICAgICA8cmRmOkRlc2NyaXB0aW9uIHJkZjphYm91dD0iIgogICAgICAgICAgICB4bWxuczp0aWZmPSJodHRwOi8vbnMuYWRvYmUuY29tL3RpZmYvMS4wLyI+CiAgICAgICAgIDx0aWZmOlJlc29sdXRpb25Vbml0PjI8L3RpZmY6UmVzb2x1dGlvblVuaXQ+CiAgICAgICAgIDx0aWZmOkNvbXByZXNzaW9uPjE8L3RpZmY6Q29tcHJlc3Npb24+CiAgICAgICAgIDx0aWZmOk9yaWVudGF0aW9uPjE8L3RpZmY6T3JpZW50YXRpb24+CiAgICAgICAgIDx0aWZmOlBob3RvbWV0cmljSW50ZXJwcmV0YXRpb24+MjwvdGlmZjpQaG90b21ldHJpY0ludGVycHJldGF0aW9uPgogICAgICA8L3JkZjpEZXNjcmlwdGlvbj4KICAgPC9yZGY6UkRGPgo8L3g6eG1wbWV0YT4KD0UqkwAAAf1JREFUeAHtmtGpAkEQBE9TMAi/zMb8MzCGU/97Ye8QunDrfQ7qNFUMS8Pbtom/fd8fEx/b/FymdIDL85p/wmmLgEJa5Ad7FTIA0xorpEV+sFchAzCtsUJa5Ad7FTIA0xorpEV+sPcyW1oG33f8WwL3qZ+blebnMs4DXGzqGWFv6hvSYx83KyRi6Q0V0mMfNyskYukNFdJjHzcrJGLpDRXSYx8329QjltrQpp7QH2jWv/5fA5t6EtKc+YY06YfdCglQmiOFNOmH3QoJUJojhTTph90KCVCaI4U06YfdNvUApTiyqSf4NvVEZdGZbwhMvEIUAiMAi+OFKARGABbHC1EIjAAsjk2dJcSmnnzY1BOVRWc+6jDxClEIjAAsjheiEBgBWBwvRCEwArA4/9LUbx+uLxjbM3Fs6omaTT1RWXTmow4TrxCFwAjA4nghCoERgMXxQhQCIwCL8y9NHYb1dBybekJnU09UFp35qMPEK0QhMAKwOF6IQmAEYHG8EIXACMDi2NRZQmzqyYdNPVFZdOajDhOvEIXACMDieCEKgRGAxfFCFAIjAItjU2cJsaknHzb1RGXRmY86TLxCFAIjAIvjhSgERgAWxwtRCIwALI5NnSXEpp582NQTlUVnPuow8QpRCIwALI4XohAYAVgcL0QhMAKwON+m/oRlWjrOG2SeYNIaKe7fAAAAAElFTkSuQmCC);background-color:#f1f1f1;touch-action:none;position:relative;overflow:hidden;-ms-touch-action:none}.amap-drags,.amap-layers{width:100%;height:100%;position:absolute;overflow:hidden;transform:translateZ(0)}.amap-layers canvas{-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.amap-layers .amap-layer-tile{transform:translateZ(0)}.amap-layers .amap-layer-tile,.amap-layers .amap-layer-tile img{position:absolute;top:0;left:0;user-select:none;-webkit-user-select:none}.amap-layers .amap-layer-image{position:absolute;top:0;left:0;transform:translateZ(0)}.amap-layers .amap-layer-image img{position:absolute;top:0;left:0}.amap-layer img{pointer-events:none;display:block}.amap-layers .amap-layer-overlay{position:absolute;top:0;left:0;transform:translateZ(0)}.amap-e,.amap-maps{width:100%;height:100%;outline:none}.amap-maps{z-index:0}.amap-e,.amap-layers,.amap-maps,.amap-tile-container{position:absolute;left:0;top:0;overflow:hidden}.amap-context,.amap-marker,.amap-markers,.amap-overlays{position:absolute;left:0;top:0}.amap-layers{z-index:0}.amap-overlays{z-index:110;cursor:default}.amap-markers{z-index:120}.amap-controls{z-index:150}.amap-copyright{display:block!important;left:85px;height:16px;bottom:1.8px;line-height:1.5;padding-bottom:2px;font-size:11px;font-family:Arial,sans-serif}.amap-copyright,.amap-logo{position:absolute;z-index:160;user-select:none;-webkit-user-select:none}.amap-logo{bottom:1.5px;left:4px;height:20px}.amap-logo img{width:73px!important;height:20px!important;border:none;vertical-align:baseline!important;user-select:none;-webkit-user-select:none}.amap-icon{position:relative;z-index:1}.amap-icon img{position:absolute;z-index:-1}.amap-marker-label{position:absolute;z-index:2;border:1px solid #00f;background-color:#fff;white-space:nowrap;cursor:default;padding:3px;font-size:12px;line-height:14px}.amap-info{left:0;width:fit-content;width:-webkit-fit-content;width:-moz-max-content}.amap-info,.amap-menu{position:absolute;z-index:140}.amap-info-close{position:absolute;right:5px;top:5px;color:#c3c3c3;text-decoration:none;font:700 16px/14px Tahoma,Verdana,sans-serif;width:14px;height:14px;cursor:pointer}.amap-info-outer,.amap-menu-outer{box-shadow:0 1px 2px rgba(0,0,0,.1);background:none repeat scroll 0 0 #fff;border-radius:2px;padding:1px;text-align:left}.amap-info-contentContainer:hover .amap-info-outer,.amap-menu-outer:hover{box-shadow:0 1px 2px rgba(0,0,0,.3)}.amap-info-content{position:relative;background:#fff;padding:10px 18px 10px 10px;line-height:1.4;overflow:auto}.amap-marker-content{position:relative}.amap-info-sharp-old{overflow:hidden;position:absolute;background-image:url(https://webapi.amap.com/images/arrows.png)}.bottom-center .amap-info-sharp-old{height:12px;width:20px;background-position:center 12px;top:100%;left:50%;margin:-9px auto 0 -10px}.bottom-left .amap-info-sharp-old{height:12px;width:13px;background-position:-16px -46px;top:100%;margin-top:-9px}.bottom-right .amap-info-sharp-old{height:12px;width:13px;top:-1px;background-position:-56px -46px;left:100%;margin-left:-13px;top:100%;margin-top:-9px}.middle-left .amap-info-sharp-old{height:20px;width:12px;background-position:0;top:50%;margin-top:-10px;margin-left:-11px}.center .amap-info-sharp-old{display:none}.middle-right .amap-info-sharp-old{height:20px;margin-right:0;width:12px;background-position:100%;left:100%;margin-left:-9px;top:50%;margin-top:-10px}.top-center .amap-info-sharp-old{height:12px;width:20px;background-position:top;top:0;left:50%;margin:-3px auto 0 -10px}.top-left .amap-info-sharp-old{height:12px;width:13px;background-position:-16px -3px;top:0;margin-top:-3px}.top-right .amap-info-sharp-old{height:12px;width:13px;background-position:-56px -3px;left:100%;margin-left:-13px;top:0;margin-top:-3px}.amap-info-sharp{position:absolute}.bottom-center .amap-info-sharp{bottom:0;left:50%;border-top:8px solid #fff}.bottom-center .amap-info-sharp,.bottom-center .amap-info-sharp:after{margin-left:-8px;border-left:8px solid transparent;border-right:8px solid transparent}.bottom-center .amap-info-sharp:after{position:absolute;content:"";margin-top:-7px;border-top:8px solid rgba(0,0,0,.3);filter:blur(2px);z-index:-1}.amap-info-contentContainer:hover.bottom-center .amap-info-sharp:after{border-top:8px solid rgba(0,0,0,.5)}.bottom-left .amap-info-sharp{border-color:transparent #fff;border-style:solid;border-width:0 0 10px 10px}.bottom-left .amap-info-sharp:after{position:absolute;content:"";margin-left:-10px;border-color:transparent rgba(0,0,0,.3);border-style:solid;border-width:0 0 10px 10px;filter:blur(1px);z-index:-1}.amap-info-contentContainer:hover.bottom-left .amap-info-sharp:after{border-color:transparent rgba(0,0,0,.5)}.bottom-left .amap-info-content{border-radius:2px 2px 2px 0}.bottom-right .amap-info-sharp{right:0;border-top:10px solid #fff;border-left:10px solid transparent}.bottom-right .amap-info-sharp:after{position:absolute;margin-top:-9px;margin-left:-10px;content:"";border-top:10px solid rgba(0,0,0,.3);border-left:10px solid transparent;filter:blur(1px);z-index:-1}.amap-info-contentContainer:hover.bottom-right .amap-info-sharp:after{border-top:10px solid rgba(0,0,0,.5)}.bottom-right .amap-info-content{border-radius:2px 2px 0 2px}.top-center .amap-info-sharp{top:0;left:50%;border-bottom:8px solid #fff}.top-center .amap-info-sharp,.top-center .amap-info-sharp:after{margin-left:-8px;border-left:8px solid transparent;border-right:8px solid transparent}.top-center .amap-info-sharp:after{position:absolute;content:"";margin-top:0;border-bottom:8px solid rgba(0,0,0,.3);filter:blur(1px);z-index:-1}.top-left .amap-info-sharp{left:0;top:0;border-bottom:10px solid #fff;border-right:10px solid transparent}.top-left .amap-info-sharp:after{position:absolute;content:"";margin-top:0;margin-left:0;border-bottom:10px solid rgba(0,0,0,.3);border-right:10px solid transparent;filter:blur(1px);z-index:-1}.top-right .amap-info-sharp{right:0;top:0;border-bottom:10px solid #fff;border-left:10px solid transparent}.top-right .amap-info-sharp:after{position:absolute;content:"";margin-top:0;margin-left:-10px;border-bottom:10px solid rgba(0,0,0,.3);border-left:10px solid transparent;filter:blur(1px);z-index:-1}.middle-right .amap-info-sharp{right:0;top:50%;border-left:8px solid #fff}.middle-right .amap-info-sharp,.middle-right .amap-info-sharp:after{margin-top:-8px;border-top:8px solid transparent;border-bottom:8px solid transparent}.middle-right .amap-info-sharp:after{position:absolute;content:"";margin-left:-8px;border-left:8px solid rgba(0,0,0,.3);filter:blur(1px);z-index:-1}.amap-info-contentContainer:hover.middle-right .amap-info-sharp:after{border-left:8px solid rgba(0,0,0,.5)}.middle-left .amap-info-sharp{left:0;top:50%;border-right:8px solid #fff}.middle-left .amap-info-sharp,.middle-left .amap-info-sharp:after{margin-top:-8px;border-top:8px solid transparent;border-bottom:8px solid transparent}.middle-left .amap-info-sharp:after{position:absolute;content:"";margin-left:0;border-right:8px solid rgba(0,0,0,.3);filter:blur(1px);z-index:-1}.amap-info-contentContainer:hover.middle-left .amap-info-sharp:after{border-right:8px solid rgba(0,0,0,.5)}.amap-info-contentContainer.top-center,.amap-info-contentContainer.top-left,.amap-info-contentContainer.top-right{padding-top:8px}.amap-info-contentContainer.bottom-center,.amap-info-contentContainer.bottom-left,.amap-info-contentContainer.bottom-right{padding-bottom:8px}.amap-info-contentContainer.middle-right{padding-right:8px}.amap-info-contentContainer.middle-left{padding-left:8px}.amap-menu-outer{margin:0;padding:0;list-style-type:none}ul.amap-menu-outer li{height:35px;line-height:35px;word-break:break-all;padding:0 10px;font-size:12px;white-space:nowrap}ul.amap-menu-outer li a{text-decoration:none;font-size:13px;margin:0 5px;color:#000;padding:5px}ul.amap-menu-outer li:hover{background-color:#f3f3ee}.amap-overlay-text-container{display:block;width:auto;word-break:keep-all;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;background:#fff;padding:2px 3px;border:1px solid #ccc;border-radius:3px}.amap-overlay-text-container.amap-overlay-text-empty{display:none}.amap-info-content-ie8{border:1px solid #9c9c9c}.amap-control{position:absolute;-webkit-tap-highlight-color:transparent}.amap-toolbar{background-color:#fff;border-radius:4px;box-shadow:0 0 3px rgba(0,0,0,.5)}.amap-toolbar span{display:block;width:30px;height:30px;line-height:30px;text-align:center;border-radius:0 0 4px 4px;-webkit-user-select:none;-moz-user-select:none;user-select:none;font-size:20px}.amap-toolbar span:first-child{border-bottom:1px solid #eee;border-radius:4px 4px 0 0}.amap-toolbar span:hover{font-weight:bolder;background-color:#f0f0f0}.amap-scalecontrol{pointer-events:none;background-color:hsla(0,0%,100%,.5);border-radius:2px;user-select:none}.amap-scalecontrol .amap-scale-text{font-size:10px;text-align:center;transition:width .3s;user-select:none}.amap-scalecontrol .amap-scale-line{position:relative;height:8px;left:2px;user-select:none}.amap-scalecontrol .amap-scale-edgeleft,.amap-scalecontrol .amap-scale-edgeright,.amap-scalecontrol .amap-scale-middle{position:absolute;background-color:#333;overflow:hidden;box-sizing:content-box!important}.amap-scalecontrol .amap-scale-edgeright{width:1px;height:6px;border:1px solid #fff;transition:left .3s}.amap-scalecontrol .amap-scale-middle{height:2px;left:2px;top:2px;border-top:1px solid #fff;border-bottom:1px solid #fff;transition:width .3s}.amap-scalecontrol .amap-scale-edgeleft{width:1px;height:6px;border:1px solid #fff}.amap-controlbar,.amap-controlbar *{user-select:none}.amap-controlbar .amap-luopan{width:92px;height:92px;background:url(https://webapi.amap.com/theme/v1.3/controlbar/ctb.png) -22px -30px no-repeat;background-size:348px 270px;user-select:none}.amap-luopan .amap-compass{top:46px;left:50%;position:absolute;margin:-24px;width:48px;height:48px;z-index:10;background:url(https://webapi.amap.com/theme/v1.3/controlbar/ctb.png) -231px -26px no-repeat;background-size:348px 270px}.amap-luopan .amap-compass.amap-compass-black{background:url(https://webapi.amap.com/theme/v1.3/controlbar/ctb.png) no-repeat -231px -79px;background-size:348px 270px}.amap-luopan .amap-compass .amap-pointers{position:absolute;width:30px;height:48px;top:0;left:9px;border:none;z-index:2;background:url(https://webapi.amap.com/theme/v1.3/controlbar/ctb.png) -281px -26px no-repeat;background-size:348px 270px}.amap-pitchDown,.amap-pitchUp{width:30px;height:25.5px;position:absolute;top:3.5px;margin-left:-15px;left:50%;z-index:1;background:url(https://webapi.amap.com/theme/v1.3/controlbar/ctb.png) -302.5px -49px no-repeat;background-size:348px 270px}.amap-pitchDown:hover,.amap-pitchUp:hover{background:url(https://webapi.amap.com/theme/v1.3/controlbar/ctb.png) no-repeat -302.5px -23.5px;background-size:348px 270px}.amap-pitchDown{top:66px;transform:rotate(180deg);-ms-transform:rotate(180deg);-webkit-transform:rotate(180deg);-o-transform:rotate(180deg);-moz-transform:rotate(180deg)}.amap-rotateLeft,.amap-rotateRight{width:21px;height:52px;top:19px;position:absolute;z-index:2;background:url(https://webapi.amap.com/theme/v1.3/controlbar/ctb.png) -301.5px -77px no-repeat;background-size:348px 270px}.amap-rotateLeft:hover,.amap-rotateRight:hover{background:url(https://webapi.amap.com/theme/v1.3/controlbar/ctb.png) no-repeat -278.5px -76.5px;background-size:348px 270px}.amap-rotateLeft{left:5px}.amap-rotateRight{right:5px;transform:rotateY(180deg);-ms-transform:rotateY(180deg);-webkit-transform:rotateY(180deg);-o-transform:rotateY(180deg);-moz-transform:rotateY(180deg)}.amap-ctrl-icon-layer{width:30px;height:30px}.amap-ctrl-icon-layer,.amap-ctrl-list-layer{background-color:#fff;border-radius:3px;box-shadow:0 0 4px 1px rgba(0,0,0,.2)}.amap-ctrl-list-layer{position:absolute;top:0;right:0;overflow:hidden;z-index:1}.amap-ctrl-list-layer ul{overflow:hidden;list-style:none;margin:0;padding:5px 8px}.amap-ctrl-list-layer ul li{float:left;width:100%}.amap-ctrl-list-layer ul p{white-space:nowrap;font-size:12px;height:20px;line-height:20px;padding-left:5px;margin:0 10px}.amap-ctrl-list-layer input{float:left;height:20px;width:12px;margin:0 5px}.amap-ctrl-base-layer{border-bottom:1px solid #eee}.amap-ranging-label{_width:10px;font-size:12px;line-height:14px;background:#fff;border:1px solid #ccc;padding:3px 7px 3px 2px;white-space:nowrap}.amap-ranging-label span{height:12px;vertical-align:center;display:inline-block;white-space:nowrap;margin-left:5px}.amap-popup{text-align:center;position:fixed;top:50%;left:50%;margin-left:-165px;margin-top:-170px}.amap-popup-content{vertical-align:middle;line-height:200px;overflow:hidden;background-color:#fff;border:solid;border-width:3px 1px;border-radius:5px;border-color:#ddf;margin:0 auto;text-align:center;height:340px}.amap-labellayers{position:absolute;top:0;left:0;transform-origin:0 0}.amap-indoormap-floorbar-control{position:absolute;width:40px;text-align:center;line-height:1.3em;border-radius:20px;box-shadow:0 0 3px 3px rgba(0,0,0,.1);background-color:#fff;margin-top:-100px}.amap-indoormap-floorbar-control .floor-list-box{max-height:160px;overflow:scroll;-ms-overflow-style:none;overflow:-moz-scrollbars-none;-webkit-user-select:none;-moz-user-select:none}.floor-list-box::-webkit-scrollbar{width:0!important;height:0!important}.amap-indoormap-floorbar-control ul{list-style:none;margin:0;padding:0 4px;width:40px;box-sizing:border-box}.amap-indoormap-floorbar-control ul li{height:32px;width:32px;border-radius:16px}.amap-indoormap-floorbar-control ul li:hover{background-color:#efefef}.amap-indoormap-floorbar-control ul li div{height:32px;text-align:center;line-height:32px;font-size:12px}.amap-indoormap-floorbar-control ul li.selected{color:#fff;background-color:#4196ff}.amap-indoormap-floorbar-control .floor-minus,.amap-indoormap-floorbar-control .floor-plus{height:32px;width:32px;margin:0 auto;border-radius:16px;position:relative}.amap-indoormap-floorbar-control .floor-minus:after,.amap-indoormap-floorbar-control .floor-plus:after{content:"";position:absolute;margin:auto;bottom:4px;left:0;right:0;width:0;height:0;border:7px solid transparent;border-top-color:#777}.amap-indoormap-floorbar-control .floor-plus:after{border-bottom-color:#777;border-top-color:transparent;bottom:11px}.amap-indoormap-floorbar-control .floor-plus:hover:after{border-bottom-color:#222}.amap-indoormap-floorbar-control .floor-minus:hover:after{border-top-color:#222}.amap-indoormap-floorbar-control .floor-plus.disabled:after{border-bottom-color:#ddd}.amap-indoormap-floorbar-control .floor-minus.disabled:after{border-top-color:#ddd}.amap-indoormap-floorbar-control .floor-list-item.selected:after{right:0;left:auto;border-left-color:transparent;border-right-color:#4196ff}.amap-indoormap-floorbar-control .floor-btn.disabled,.amap-indoormap-floorbar-control .floor-btn.disabled *,.amap-indoormap-floorbar-control.with-indrm-loader *{-webkit-pointer-events:none!important;pointer-events:none!important}.amap-indoormap-floorbar-control .with-indrm-loader .floor-nonas{opacity:.5}'),-1!==(si=0!==(si=window.location.href).indexOf("http")&&window.parent&&window.parent!==window?window.parent.location.href:si).indexOf("?")&&(si=si.substr(0,si.indexOf("?"))),si=encodeURIComponent(si);var pi=(Pi=config[16]||config[2].split(":")[0])+"://restapi.amap.com",ct=(xi=Pi+"://"+config[2].split("://")[1])+"/theme/v1.3/markers/"+(_.Support.Ue?"b":"n"),Qt=Pi+"://webrd0{1,2,3,4}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&scale=1&style=8&x=[x]&y=[y]&z=[z]",li=Pi+"://wprd0{1,2,3,4}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&style=7&x=[x]&y=[y]&z=[z]",ea="",Ti="",ra=(window._AMapSecurityConfig&&(window._AMapSecurityConfig.securityJsCode?ea=window._AMapSecurityConfig.securityJsCode||"":window._AMapSecurityConfig.serviceHost&&(Oi="",Bt=(Oi="https"===(Ti=window._AMapSecurityConfig.serviceHost||"").split(":")[0]?Ti.replace(/https:\/\/\S+?\//g,""):Ti.replace(/http:\/\/\S+?\//g,""))&&Oi.split("/")[0],Xt=window.location.hostname,"_AMapService"!==Bt)&&("127.0.0.1"===Xt||"localhost"===Xt?window.alert("使用 JSAPI 安全模式,代理服务请以_AMapService 作为一级路由"):"undefined"!=typeof console&&console.log("<AMap JSAPI> 使用 JSAPI 安全模式,代理服务请以_AMapService 作为一级路由"))),{key:config[0],host:config[2],domain:config[17],server:pi,protocol:Pi,version:config[4],adcode:config[6],callback:config[5],appname:si,client:xi,markers:ct,pc:"http://gaode.com",mo:"http://m.amap.com",workerUrl:"",YT:Qt,qT:li,y_:_.Support.$e?li:Qt,v_:"\x3c!--v2.0--\x3e © "+(new Date).getFullYear()+" AutoNavi ",db:config[14]||"",JH:config[15]||"",jscode:ea,gaodeserver:Ti,vdataProxy:"",keytype:config[19]});return hi=(new Date).getTime(),Ut=ra.server+"/v3/log/init?",(s=["platform=JS&s=rsv3&logversion=2.0&product=JsInit&key="+ra.key,"t="+hi]).push("sdkversion=2.0"),s.push("appname="+si),s.push("csid="+_.Util.uuid()),s.push("resolution="+window.screen.width+"*"+window.screen.height),s.push("mob="+(_.Support.$e?1:0)),s.push("vt="+(_.Support.isWebGL?1:0)),s.push("dpr="+window.devicePixelRatio),s.push("scale="+(_.Support.Ue?2:1)),s.push("detect="+_.Support.Ue),ra.jscode?s.push("jscode="+ra.jscode):ra.gaodeserver&&(Ut=ra.gaodeserver+"/v3/log/init?"),Ut+=s.join("&"),yi.JSONP(Ut),function(t){return t[1]&&(or=t[1].slice(-2),er=t[1].slice(0,4)),{Map:ur,ImageLayer:vr,createDefaultLayer:qr,TileLayer:v,NebulaLayer:Ji,Buildings:Xr,Indoor:Eo,SkyLayer:Ms,DistrictLayer:_o,CanvasLayer:gr,CustomLayer:xr,GLCustomLayer:ih,LabelsLayer:ms,MassMarks:Sr,Event:_.Event,version:"2.0",plugin:$o,LngLat:_.LngLat,Pixel:_.Pixel,Size:_.Size,Icon:re,Bounds:l,extent:Pt,Marker:De,Text:Dr,InfoWindow:Ge,ContextMenu:qe,LabelMarker:Br,Polygon:qh,Rectangle:to,Ellipse:so,Circle:oo,CircleMarker:fo,Polyline:bo,BezierCurve:Co,OverlayGroup:dh,VectorLayer:is,LayerGroup:eh,Control:Fr,DomUtil:w,Util:_.Util,GeometryUtil:_.GeometryUtil,Browser:_r,UA:{ie:_r.ie,ie9:_r.ie9,ie11:_r.ie11,mobile:_r.mobile,android:_r.android,ios:_r.ios},PlaneGeometryUtil:_.PlaneGeometryUtil,getConfig:ta,WebService:ir,extend:_.extend,Http:yi,addCss:N,BuryPoint:Hr,lcs:_.lcs,convertFrom:sr,Heatmap:hh,IndoorMap:jo,Mapbox:ch,BuildingLayer:Xr,Mark:Ko}}});var __AMap_callback=AMap.getConfig().callback,tryGetCallback,tryCallback;return __AMap_callback&&(tryGetCallback=function(){var c=__AMap_callback.split("."),context=window;do{if(!(context=context[c.shift()]))return null}while(c.length);return context||null},tryCallback=function(isFinalTry){var func=tryGetCallback();if(func){if("function"!=typeof func)throw new Error(__AMap_callback+" is not a function!");setTimeout(func,1)}else if(isFinalTry)throw new Error("Can not find callback: "+__AMap_callback+", try define it before load JsApi!")},document.body&&tryGetCallback()?tryCallback():setTimeout(function(){tryCallback(!0)},1)),AMap});
|
||
(typeof _cssload_=="function")&&_cssload_("logo",".amap-logo{display:block!important;pointer-events:none;}",true)})(["1d61961cc5f61f643bcfb6f0b5021e80",[118.363373,31.228098,119.241663,32.614363,118.767413,32.041544],"https://webapi.amap.com",1,"2.0.5.21",null,"320100","AMap.ElasticMarker,AMap.ToolBar,AMap.Scale,AMap.HawkEye,AMap.MapType,AMap.MouseTool,AMap.CircleEditor,AMap.PolygonEditor,AMap.PolylineEditor,AMap.MarkerCluster,AMap.RangingTool",true,false,false,true,"20230103011500-20201123-1",false,"A","3_23_10_10_00","https","webapi.amap.com",1,"0"])
|
||
_jsload_('AMap.ElasticMarker', '(function(){"use strict";var extendStatics=function(d,b){extendStatics=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,b){d.__proto__=b}||function(d,b){for(var p in b)if(b.hasOwnProperty(p))d[p]=b[p]};return extendStatics(d,b)};function __extends(d,b){extendStatics(d,b);function __(){this.constructor=d}d.prototype=b===null?Object.create(b):(__.prototype=b.prototype,new __)}var extend=function(dest){var args=[];for(var _i=1;_i<arguments.length;_i++){args[_i-1]=arguments[_i]}var sources=Array.prototype.slice.call(arguments,1);var j;var len;var src;for(j=0,len=sources.length;j<len;j=j+1){src=sources[j]||{};for(var key in src){if(src.hasOwnProperty(key)){var target=src[key];if(typeof target!=="function"||!dest.prototype){dest[key]=target}else{dest.prototype[key]=target}}}}return dest};function isBrowser(){return typeof window!=="undefined"&&typeof document!=="undefined"}function isWasmSuppport(){try{if(typeof WebAssembly==="object"&&typeof WebAssembly.instantiate==="function"&&TextDecoder&&TextEncoder){var module=new WebAssembly.Module(new Uint8Array([0,97,115,109,1,0,0,0]));if(module instanceof WebAssembly.Module){return new WebAssembly.Instance(module)instanceof WebAssembly.Instance}}}catch(e){}return false}var testWepP=function(callback){var webP=new Image;webP.src="data:image/webp;base64,UklGRi4AAABXRUJQVlA4TCEAAAAvAUAAEB8wAiMw"+"AgSSNtse/cXjxyCCmrYNWPwmHRH9jwMA";webP.onload=webP.onerror=function(){callback(webP.height===2)}};function isWorkerEnv(){try{var flag=!!document;return false}catch(e){return true}}function getSupport(config){var amapRunTime={runSupport:(new Date).getTime()};var isRetina=false;var isMobile=false;var android=false;var webkit=false;var touch=false;var wasm=isWasmSuppport();var ua=navigator.userAgent.toLowerCase();var uaHas=function(key){return ua.indexOf(key)!==-1};var hardwareAccEnabled=true;var mac=uaHas("macintosh");var iPad=uaHas("ipad;")||uaHas("ipad "),iTouch=uaHas("ipod touch;"),iPhone=uaHas("iphone;")||uaHas("iphone "),ios=iPhone||iPad||iTouch,safari=(mac||ios)&&uaHas("safari")&&uaHas("version/"),macWechat=uaHas("macwechat"),windowsWechat=uaHas("windowswechat");var Browser={touch:touch,mac:mac,isRetina:isRetina,webkit:webkit,isMobile:isMobile,scale:1,android:android,isWorkerEnv:isWorkerEnv(),wasm:wasm,safari:safari,macWechat:macWechat,windowsWechat:windowsWechat,amapRunTime:amapRunTime};if(isBrowser()){var win_1=window,doc=document,docE=doc.documentElement,numberRegex_1=/([a-z0-9]*\\d+[a-z0-9]*)/,getGraphicCardShortStr_1=function(graphicVersion){if(!graphicVersion){return null}graphicVersion=graphicVersion.toLowerCase();var forShort=null;var b=graphicVersion.match(/angle \\((.*)\\)/);if(b){graphicVersion=b[1];graphicVersion=graphicVersion.replace(/\\s*direct3d.*$/,"")}graphicVersion=graphicVersion.replace(/\\s*\\([^\\)]*wddm[^\\)]*\\)/,"");if(graphicVersion.indexOf("intel")>=0){forShort=["Intel"];if(0<=graphicVersion.indexOf("mobile")){forShort.push("Mobile")}if(0<=graphicVersion.indexOf("gma")||0<=graphicVersion.indexOf("graphics media accelerator")){forShort.push("GMA")}if(0<=graphicVersion.indexOf("haswell")){forShort.push("Haswell")}else if(0<=graphicVersion.indexOf("ivy")){forShort.push("HD 4000")}else if(0<=graphicVersion.indexOf("sandy")){forShort.push("HD 3000")}else if(0<=graphicVersion.indexOf("ironlake")){forShort.push("HD")}else{if(0<=graphicVersion.indexOf("hd")){forShort.push("HD")}var number=graphicVersion.match(numberRegex_1);if(number){forShort.push(number[1].toUpperCase())}}forShort=forShort.join(" ");return forShort}if(graphicVersion.indexOf("nvidia")>=0||graphicVersion.indexOf("quadro")>=0||graphicVersion.indexOf("geforce")>=0||graphicVersion.indexOf("nvs")>=0){forShort=["nVidia"];if(0<=graphicVersion.indexOf("geforce")){forShort.push("geForce")}if(0<=graphicVersion.indexOf("quadro")){forShort.push("Quadro")}if(0<=graphicVersion.indexOf("nvs")){forShort.push("NVS")}if(graphicVersion.match(/\\bion\\b/)){forShort.push("ION")}if(graphicVersion.match(/gtx\\b/)){forShort.push("GTX")}else if(graphicVersion.match(/gts\\b/)){forShort.push("GTS")}else if(graphicVersion.match(/gt\\b/)){forShort.push("GT")}else if(graphicVersion.match(/gs\\b/)){forShort.push("GS")}else if(graphicVersion.match(/ge\\b/)){forShort.push("GE")}else if(graphicVersion.match(/fx\\b/)){forShort.push("FX")}var number=graphicVersion.match(numberRegex_1);if(number){forShort.push(number[1].toUpperCase().replace("GS",""))}if(0<=graphicVersion.indexOf("titan")){forShort.push("TITAN")}else if(0<=graphicVersion.indexOf("ti")){forShort.push("Ti")}forShort=forShort.join(" ");return forShort}if(graphicVersion.indexOf("amd")>=0||graphicVersion.indexOf("ati")>=0||graphicVersion.indexOf("radeon")>=0||graphicVersion.indexOf("firegl")>=0||graphicVersion.indexOf("firepro")>=0){forShort=["AMD"];if(0<=graphicVersion.indexOf("mobil")){forShort.push("Mobility")}var radeonIndex=graphicVersion.indexOf("radeon");if(0<=radeonIndex){forShort.push("Radeon")}if(0<=graphicVersion.indexOf("firepro")){forShort.push("FirePro")}else if(0<=graphicVersion.indexOf("firegl")){forShort.push("FireGL")}if(0<=graphicVersion.indexOf("hd")){forShort.push("HD")}if(radeonIndex>=0){graphicVersion=graphicVersion.substring(radeonIndex)}var number=graphicVersion.match(numberRegex_1);if(number){forShort.push(number[1].toUpperCase().replace("HD",""))}forShort=forShort.join(" ");return forShort}return graphicVersion.substring(0,100)},blackGraphicCard_1="google swiftshader;microsoft basic render driver;vmware svga 3d;Intel 965GM;Intel B43;Intel G41;Intel G45;Intel G965;Intel GMA 3600;Intel Mobile 4;Intel Mobile 45;Intel Mobile 965".split(";"),ie="ActiveXObject"in win_1,retina=window["detectRetina"]==false?false:"devicePixelRatio"in win_1&&win_1["devicePixelRatio"]>1||ie&&"matchMedia"in win_1&&win_1.matchMedia("(min-resolution:144dpi)")&&win_1.matchMedia("(min-resolution:144dpi)").matches,windows=uaHas("windows nt"),windowslt7=ua.search(/windows nt [1-5]\\./)!==-1,windowsXP=ua.search(/windows nt 5\\.[12]/)!==-1,windows10=uaHas("windows nt 10"),winPhone=uaHas("windows phone"),mb2345Browser=uaHas("Mb2345Browser"),ioslt7=ios&&ua.search(/ os [456]_/)!==-1,ioslt9=ios&&ua.search(/ os [4-8]_/)!==-1,ios78=ios&&ua.search(/ os [78]_/)!==-1,ios8=ios&&uaHas("os 8_"),ios10=ios&&uaHas("os 10_"),android_1=uaHas("android");var androidVersion=0;if(android_1){androidVersion=parseInt(ua.split("android")[1])||0}var android23=android_1&&androidVersion<4,android5plus=android_1&&androidVersion>=5,android44plus=android5plus||ua.search(/android 4.4/)!==-1,plat_1=android_1?"android":ios?"ios":windows?"windows":mac?"mac":"other",ie6=ie&&!win_1["XMLHttpRequest"],ie7=ie&&!doc.querySelector,ielt9=ie&&!doc.addEventListener,ie9=ie&&uaHas("msie 9"),ie10=ie&&uaHas("msie 10"),ie11=ie&&uaHas("rv:11"),ielt10=ielt9||ie9,edge=uaHas("edge"),QtWeb=uaHas("qtweb"),uc=uaHas("ucbrowser"),gaodeCoords=uaHas("alipay")||android_1&&uc,xiaomi=uaHas("miuibrowser"),wechat=uaHas("micromessenger"),dingding=uaHas("dingtalk"),qq=uaHas("mqqbrowser"),baidu=uaHas("baidubrowser"),crios=uaHas("crios/"),chrome=uaHas("chrome/"),chromium=(chrome||crios)&&uaHas("chromium"),chrome30plus=!chromium&&(chrome&&parseInt(ua.split("chrome/")[1])>30||crios&&parseInt(ua.split("crios/")[1])>30),firefox=uaHas("firefox"),firefox27plus=firefox&&parseInt(ua.split("firefox/")[1])>27,safari7plus=safari&&parseInt(ua.split("version/")[1])>7,aliApp=ios&&uaHas("aliapp"),mobile_1=android_1||ios||winPhone||uaHas("mobile"),touchDev="ontouchstart"in doc,msPointer=win_1["navigator"]&&win_1["navigator"]["msPointerEnabled"]&&!!win_1["navigator"]["msMaxTouchPoints"],pointer=win_1["navigator"]&&!!win_1["navigator"]["maxTouchPoints"],pointerDev=!touchDev&&(pointer||msPointer),touch_1=touchDev||pointerDev,getScale=function(){if(!mobile_1){return win_1.devicePixelRatio||1}var metas=document.getElementsByTagName("meta");if(window.parent&&window.parent!==window){try{if(window.parent.location.origin===window.location.origin){metas=window.parent.document.getElementsByTagName("meta")}else{return 1}}catch(e){return 1}}for(var i=metas.length-1;i>=0;i-=1){if(metas[i].name==="viewport"){var content=metas[i].content;var initial_scale=void 0,minimum_scale=void 0,maximum_scale=void 0;if(content.indexOf("initial-scale")!==-1){initial_scale=parseFloat(content.split("initial-scale=")[1])}if(content.indexOf("minimum-scale")!==-1){minimum_scale=parseFloat(content.split("minimum-scale=")[1])}else{minimum_scale=0}if(content.indexOf("maximum-scale")!==-1){maximum_scale=parseFloat(content.split("maximum-scale=")[1])}else{maximum_scale=Infinity}if(initial_scale){if(maximum_scale>=minimum_scale){if(initial_scale>maximum_scale){return maximum_scale}else if(initial_scale<minimum_scale){return minimum_scale}else{return initial_scale}}else{console&&console.log&&console.log("viewport参数不合法");return null}}else{if(maximum_scale>=minimum_scale){if(minimum_scale>=1){return 1}else{return Math.min(maximum_scale,1)}}else{console&&console.log&&console.log("viewport参数不合法");return null}}}}return undefined},viewportScale=getScale(),needFitRetina_1=retina&&(!mobile_1||!!viewportScale&&viewportScale>=1),ie3d=ie&&"transition"in docE.style,isSvg=!!doc.createElementNS&&!!doc.createElementNS("http://www.w3.org/2000/svg","svg")["createSVGRect"],canvas_1=doc.createElement("canvas"),isCanvas_1=!!(canvas_1&&canvas_1.getContext),UrlLib=window["URL"]||window["webkitURL"],DataUrl2Blob=false;var isWorker_1=window["disableWorker"]!==true&&!ie&&!(uc&&android_1&&!chrome30plus)&&window["Worker"]&&UrlLib&&UrlLib["createObjectURL"]&&window["Blob"],webglContextName_1="",graphicCard_1="",maxRenderSize_1=0,needAntialias=window["higtQualityRender"]==false?retina?false:true:true,movingDraw=window["movingDraw"],webglParams_1=window["forceWebGL"]?{alpha:true,antialias:needAntialias,depth:true,stencil:true}:{alpha:true,antialias:needAntialias,depth:true,stencil:true},checkWebgl=function(){if(!isCanvas_1||!isWorker_1){return false}var contextName=["webgl","experimental-webgl","moz-webgl"];var gl=null;for(var i=0;i<contextName.length;i+=1){try{var para=webglParams_1;gl=canvas_1.getContext(contextName[i],para)}catch(err){}if(!gl){continue}else{if(gl.drawingBufferWidth!==canvas_1.width||gl.drawingBufferHeight!==canvas_1.height){return false}if(!gl.getShaderPrecisionFormat||!gl.getParameter||!gl.getExtension){return false}maxRenderSize_1=gl.getParameter(gl.MAX_RENDERBUFFER_SIZE);var maxViewPortSize=gl.getParameter(gl.MAX_VIEWPORT_DIMS);if(!maxViewPortSize){return false}maxRenderSize_1=Math.min(maxRenderSize_1,maxViewPortSize[0],maxViewPortSize[1]);if(safari&&plat_1==="mac"){maxRenderSize_1=Math.min(maxRenderSize_1,4096)}var renderSize=Math.max(screen.width,screen.height);if(needFitRetina_1){renderSize*=Math.min(2,window.devicePixelRatio||1)}if(renderSize>maxRenderSize_1){return false}if(23>gl.getShaderPrecisionFormat(35632,36338).precision||23>gl.getShaderPrecisionFormat(35633,36338).precision){return false}graphicCard_1=gl.getExtension("WEBGL_debug_renderer_info")?gl.getParameter(37446):null;var graphicCardShort=getGraphicCardShortStr_1(graphicCard_1);if(graphicCardShort){if(graphicCardShort.indexOf("google swiftshader")>-1){hardwareAccEnabled=false;return false}if(-1!==blackGraphicCard_1.indexOf(graphicCardShort)){return false}}webglContextName_1=contextName[i];return true}}return false},canWebGL=checkWebgl(),enableVector=config[8]!==undefined?config[8]:true,byWebgl=window["Uint8Array"]&&enableVector&&!window["forbidenWebGL"]&&canWebGL&&(window["forceWebGL"]||(chrome30plus||firefox27plus||safari7plus||edge||wechat||dingding)&&plat_1!=="other"),baseRender=window["forceWebGLBaseRender"]?"w":byWebgl?"w":"d",webkit_1=uaHas("webkit"),webkit3d="WebKitCSSMatrix"in win_1&&"m11"in new window["WebKitCSSMatrix"],gecko3d="MozPerspective"in docE.style,opera3d="OTransition"in docE.style,any3d=ie3d||webkit3d||gecko3d||opera3d,enableLabelImage=false,vdataVersion=config[12]!==undefined?config[12]:null;var localStore=true;try{if(typeof win_1.localStorage==="undefined"){localStore=false}else{var tmpData=(new Date).getTime()+"";win_1.localStorage.setItem("_test",tmpData);if(win_1.localStorage.getItem("_test")!==tmpData){localStore=false}win_1.localStorage.removeItem("_test")}}catch(e){localStore=false}var getContext=function(canvas,opt){var params={};extend(params,webglParams_1);extend(params,opt);return canvas.getContext(webglContextName_1,params)};var chromeversion=parseInt(ua.split("chrome/")[1]);Browser={iPad:iPad,iPhone:iPhone,size:iPhone?100:android_1?200:500,mac:mac,windows:windows,ios:ios,ios10:ios10,android:android_1,android23:android23,gaodeCoords:gaodeCoords,plat:plat_1,baidu:baidu,qq:qq,safari:safari,wechat:wechat,ie:ie,ie6:ie6,ie7:ie7,ie9:ie9,ie10:ie10,ielt9:ielt9,ielt10:ielt10,ie11:ie11,edge:edge,ielt11:ie&&!ie11,mb2345Browser:mb2345Browser,localStore:localStore,vdataVersion:vdataVersion,geolocation:mobile_1||ie&&!ielt9||edge,uc_:uc,uc:uc&&!chrome,chrome:chrome,drawTextDir:true,firefox:firefox,hardwareAccEnabled:hardwareAccEnabled,isMobile:mobile_1,mobileWebkit:mobile_1&&webkit_1,mobileWebkit3d:mobile_1&&webkit3d,mobileOpera:mobile_1&&win_1.opera,isRetina:retina,viewportScale:viewportScale,needFitRetina:needFitRetina_1,touch:touch_1,msPointer:msPointer,pointer:pointer,pointerDev:pointerDev,chrome57:chrome&&chromeversion>=57,chrome64:!mobile_1&&chrome&&chromeversion>=64,webkit:webkit_1,ie3d:ie3d,webkit3d:webkit3d,gecko3d:gecko3d,opera3d:opera3d,any3d:any3d,isSvg:isSvg,isCanvas:isCanvas_1,isWorker:isWorker_1,useLabelImage:enableLabelImage,isWebGL:byWebgl,webglContextName:webglContextName_1,webglParams:webglParams_1,graphicCard:graphicCard_1,maxRenderSize:maxRenderSize_1,DataUrl2Blob:DataUrl2Blob,movingDraw:movingDraw,baseRender:enableVector?baseRender:"d",scale:retina?2:1,getContext:getContext,isWebp:false,wasm:wasm,amapRunTime:amapRunTime,checkWebgl:checkWebgl};testWepP(function(isWebp){Browser.isWebp=isWebp})}return Browser}var Browser=getSupport(typeof config==="undefined"?[]:config);if(typeof createImageBitmap!=="undefined"&&typeof ImageBitmap!=="undefined"){Browser.imageBitmap=true}var canceledWorkerFetch=Boolean(Browser.isWorkerEnv?!Browser.safari&&!Browser.macWechat&&!Browser.windowsWechat&&self.fetch&&self.Request&&self.AbortController&&self.Request.prototype.hasOwnProperty("signal"):!Browser.safari&&!Browser.macWechat&&!Browser.windowsWechat&&window.fetch&&window.Request&&window.AbortController&&window.Request.prototype.hasOwnProperty("signal"));Browser.canceledWorkerFetch=canceledWorkerFetch;Browser["amapRunTime"]={workerTime:{}};var DomUtil={getViewport:function(obj){if(!obj){return[0,0]}return[obj.clientWidth,obj.clientHeight]},getStyle:function(obj,key){var value=obj.style[key];if((!value||value==="auto")&&document.defaultView){var css=document.defaultView.getComputedStyle(obj,null);value=css?css[key]:null}if((!value||value==="auto")&&key==="height"){value=obj.clientHeight+"px"}if((!value||value==="auto")&&key==="width"){value=obj.clientWidth+"px"}return value==="auto"?null:value},getViewportOffset:function(element){var top=0;var left=0;var el=element;var docBody=document.body;var docEl=document.documentElement;var pos;do{top+=el.offsetTop||0;left+=el.offsetLeft||0;top+=parseInt(DomUtil.getStyle(el,"borderTopWidth"),10)||0;left+=parseInt(DomUtil.getStyle(el,"borderLeftWidth"),10)||0;pos=DomUtil.getStyle(el,"position");if(el.offsetParent===docBody&&pos==="absolute"){break}if(pos==="fixed"){top+=docBody.scrollTop||docEl.scrollTop||0;left+=docBody.scrollLeft||docEl.scrollLeft||0;break}el=el.offsetParent}while(el);el=element;do{if(el===docBody){break}top-=el.scrollTop||0;left-=el.scrollLeft||0;if(!DomUtil.documentIsLtr()&&Browser.webkit){left+=el.scrollWidth-el.clientWidth}el=el.parentNode}while(el);return[left,top]},documentIsLtr:function(){var checked=false;var _docIsLtr=false;return function(){if(!checked){_docIsLtr=DomUtil.getStyle(document.body,"direction")==="ltr";checked=true}return _docIsLtr}}(),create:function(tagName,container,className,position){var el=document.createElement(tagName);if(className){el.className=className}if(container){if(position&&position==="before"){var firstDom=container.firstChild;container.insertBefore(el,firstDom)}else{container.appendChild(el)}}return el},toggleClass:function(el,name,on){if(on){this.addClass(el,name)}else{this.removeClass(el,name)}},hasClass:function(el,name){if(!el||!name){return}return el.className.length>0&&new RegExp("(^|\\\\s)"+name+"(\\\\s|$)").test(el.className)},addClass:function(el,name){if(!el||!name){return}if(el.classList&&el.classList.add){el.classList.add(name)}else if(!this.hasClass(el,name)){el.className+=(el.className?" ":"")+name}},setClass:function(el,name){if(!el){return}el.className=name||""},removeClass:function(el,name){function replaceFn(w,match){if(match===name){return""}return w}if(!el||!name){return}if(el.classList&&el.classList.remove){el.classList.remove(name)}else{el.className=el.className.replace(/(\\S+)\\s*/g,replaceFn).replace(/(^\\s+|\\s+$)/,"")}},watchSize:function(element,listener,map){var iframe=document.createElement("iframe");iframe.style.cssText="width: 100%;height: 100%;position: absolute;pointEvents:none; opacity:0; margin: 0;padding: 0;border: none;";iframe.onload=function(){if(iframe){iframe.contentWindow.onresize=sizeChange}};element.appendChild(iframe);iframe.src="javascript:void(0)";var oldWidth=0;var oldHeight=0;sizeChange();map.resize=sizeChange;function sizeChange(){map._boundingClientRect=element.getBoundingClientRect();map._clientPos=[element.clientLeft,element.clientTop];var width=element.offsetWidth;var height=element.offsetHeight;if(width!==oldWidth||height!==oldHeight){listener(width,height);oldWidth=width;oldHeight=height}}window.onscroll=sizeChange;return function(){var _a;if(map.resize){map.resize=null}if(window.onscroll){window.onscroll=null}if(iframe.contentWindow){iframe.contentWindow.onresize=null;iframe.contentWindow.document.write("");iframe.parentNode.removeChild(iframe);(_a=iframe.contentWindow)===null||_a===void 0?void 0:_a.close()}}},watchSize2:function(element,listener,map){var expand=document.createElement("_");expand.className="expand";var shrink=expand.appendChild(document.createElement("_"));shrink.className="shrink";var expandChild=expand.appendChild(document.createElement("_"));expandChild.className="expandChild";var shrinkChild=shrink.appendChild(document.createElement("_"));shrinkChild.className="shrinkChild";var lastWidth;var lastHeight;var style="height:100%;left:0;opacity:0;overflow:hidden;pointer-events:none;position:absolute;top:0;transition:0s;width:100%;z-index:-1";shrink.style.cssText=expand.style.cssText=style;shrinkChild.style.cssText=expandChild.style.cssText="display:block;height:100%;transition:0s;width:100%";shrinkChild.style.width=shrinkChild.style.height="200%";element.appendChild(expand);test();return stop;function test(){unbind();map._boundingClientRect=element.getBoundingClientRect();map._clientPos=[element.clientLeft,element.clientTop];var width=element.offsetWidth;var height=element.offsetHeight;if(width!==lastWidth||height!==lastHeight){lastWidth=width;lastHeight=height;expandChild.style.width=width*2+"px";expandChild.style.height=height*2+"px";expand.scrollLeft=expand.scrollWidth;expand.scrollTop=expand.scrollHeight;shrink.scrollLeft=shrink.scrollWidth;shrink.scrollTop=shrink.scrollHeight;listener(width,height)}shrink.addEventListener("scroll",test);expand.addEventListener("scroll",test)}function unbind(){shrink.removeEventListener("scroll",test);expand.removeEventListener("scroll",test)}function stop(){unbind();element.removeChild(expand)}},mousePos:function(el,e,map){if(el){map._boundingClientRect=el.getBoundingClientRect();map._clientPos=[el.clientLeft,el.clientTop]}var rect=map._boundingClientRect;var t=e;if(t.touches&&t.changedTouches){if(t.touches.length>0){t=t.touches[0]}else{t=t.changedTouches[t.changedTouches.length-1]}}return[t.clientX-rect.left-map._clientPos[0],t.clientY-rect.top-map._clientPos[1]]},remove:function(el){if(el&&el.parentNode){el.parentNode.removeChild(el)}},empty:function(el){while(el.firstChild){el.removeChild(el.firstChild)}},closest:function(elem,className){if(elem){if(this.hasClass(elem,className)){return elem}else{var parent=elem.parentElement;if(parent){return DomUtil.closest(parent,className)}return null}}return null},fillText:function(el,text){if(!el){return}if(el.textContent!==void 0){el.textContent=text}else if(el.innerText!==void 0){el.innerText=text}else{el.innerHTML=text}return el},testProp:function(props){var style=document.documentElement.style;for(var i=0;i<props.length;i+=1){if(props[i]in style){return props[i]}}return false},rotate:function(target,angle,center){var trans=DomUtil.TRANSFORM;center=center||{x:target.clientWidth/2,y:target.clientHeight/2};if(trans){var cache="";cache+=" rotate("+angle+"deg)";target.style[trans]=cache;target.style[DomUtil.trans[trans]+"-origin"]=center.x+"px "+center.y+"px"}else{var cosDeg=Math.cos(angle*Math.PI/180);var sinDeg=Math.sin(angle*Math.PI/180);target.style.filter="progid:DXImageTransform.Microsoft.Matrix()";if(target["filters"].length>0){var t=target["filters"].item(0);t["Dx"]=-center.x*cosDeg+center.y*sinDeg+center.x;t["Dy"]=-center.x*sinDeg-center.y*cosDeg+center.y;t["M11"]=t["M22"]=cosDeg;t["M12"]=-(t["M21"]=sinDeg)}}},setCss:function(obj,css){obj=obj instanceof Array?obj:[obj];for(var i=0;i<obj.length;i+=1){for(var j in css){if(css.hasOwnProperty(j)){obj[i].style[j]=css[j]}}}return this},setOpacity:function(el,value){if(!el.style){return}if("opacity"in el.style){el.style.opacity=""+value}else if("filter"in el.style){var filterName="DXImageTransform.Microsoft.Alpha";var finalOpacity=Math.round(value*100);el.style.filter="";if(finalOpacity!==100){el.style.filter=" progid:"+filterName+"(opacity="+finalOpacity+")"}}},trans:{},TRANSFORM:false};DomUtil.TRANSFORM=DomUtil.testProp(["WebkitTransform","OTransform","MozTransform","msTransform","transform"]);DomUtil.trans={transform:"transform",WebkitTransform:"-webkit-transform",OTransform:"-o-transform",MozTransform:"-moz-transform",msTransform:"-ms-transform"};var zoomRange=[2,26];var defaultMarkerOptions={map:null,visible:true,zIndex:12,offset:[0,0],anchor:[0,0],rotate:0,scale:1,zooms:zoomRange,title:"",clickable:true,draggable:false,bubble:false};var CONSTS={Type:"AMap.ElasticMarker",ElasticMarkerClass:"amap-overlay-elastic-container"};var LabelDirectionMapping={BL:"bottom-left",BM:"bottom-center",BR:"bottom-right",ML:"middle-left",MR:"middle-right",TL:"top-left",TM:"top-center",TR:"top-right",C:"center"};var ElasticMarker=function(_super){__extends(ElasticMarker,_super);function ElasticMarker(opts){if(opts===void 0){opts={}}var _this=_super.call(this,opts)||this;_this.className=CONSTS.Type;_this.type=CONSTS.Type;_this._iconMap={};_this._elasticScale=1;_this._opts=AMap.extend({},defaultMarkerOptions,_this._opts);var styles=opts.styles,zoomStyleMapping=opts.zoomStyleMapping;if(styles){_this.setStyle(styles)}if(zoomStyleMapping){_this.setMapping(zoomStyleMapping)}var map=opts.map;if(map){_this.add(map)}return _this}ElasticMarker.prototype.add=function(map){if(map){this._add(map);if(this._parent){this._parent.addToGroup(this);this.updateOverlay()}}};ElasticMarker.prototype.setStyle=function(styles){this._elasticStyles=styles};ElasticMarker.prototype.setMapping=function(mapping){this._mapping=mapping};ElasticMarker.prototype.updateOverlay=function(params){this._createDom(this.dom);_super.prototype.updateOverlay.call(this)};ElasticMarker.prototype._createDom=function(container){this.dom=container;container.innerHTML="";var outter=this._createElasticOutter();container.appendChild(outter);this._outter=outter;this._createElasticDom();return container};ElasticMarker.prototype._createElasticDom=function(){var outter=this._createElasticOutter();this._updateElasticContent();return outter};ElasticMarker.prototype._getSize=function(){var elasticScale=this._elasticScale;var _a=_super.prototype._getSize.call(this),w=_a[0],h=_a[1];var targetW=w*elasticScale;var targetH=h*elasticScale;return[targetW,targetH]};ElasticMarker.prototype._getImageSize=function(icon){var elasticScale=this._elasticScale;var imageSize=icon.getImageSize();var size;if(imageSize.width){size=imageSize.toArray()}else{size=imageSize}var targetW=size[0]*elasticScale;var targetH=size[1]*elasticScale;return[targetW,targetH]};ElasticMarker.prototype._getImageOffset=function(icon){var elasticScale=this._elasticScale;var imageOffset=icon.getImageOffset();var offset;if(imageOffset.x){offset=imageOffset.toArray()}else{offset=imageOffset}var targetW=offset[0]*elasticScale;var targetH=offset[1]*elasticScale;return[targetW,targetH]};ElasticMarker.prototype._createElasticOutter=function(){var container=document.createElement("div");DomUtil.addClass(container,CONSTS.ElasticMarkerClass);return container};ElasticMarker.prototype._updateElasticContent=function(){if(this._map){var curZoom=this._map.getZoom();var zoom=AMap.Util.getOptimalZoom(curZoom);var style=this._getContentByZoom(zoom);if(style){var icon=style.icon,_a=style.label,label=_a===void 0?{}:_a;if(icon){this._elasticScale=this._updateElasticSize(icon,curZoom);this._updateIcon(icon)}if(label){var minZoom=label.minZoom||2;if(minZoom<=zoom){this._updateLabel(label)}else{this._updateLabel({})}}}}return null};ElasticMarker.prototype._getContentByZoom=function(zoom){var styles=this._elasticStyles;var mapping=this._mapping||{};var styleIndex=mapping[zoom];if(typeof styleIndex==="undefined"){return null}var curStyle=styles[styleIndex];return curStyle};ElasticMarker.prototype._updateIcon=function(icon){var _this=this;var iconData=this._iconMap[icon.img];if(!iconData){var iconParams_1=AMap.extend({image:icon.img},icon);var iconObj_1=new AMap.Icon(iconParams_1);this._opts.anchor=icon.ancher||icon.anchor;this._opts.size=iconObj_1.getSize();var iconElem_1=this._createIcon(iconObj_1,function(){_this._iconMap[icon.img]={icon:iconObj_1,elem:iconElem_1,size:_super.prototype._getSize.call(_this),params:iconParams_1};var curSize=_this._getSize();var imageSize=iconParams_1.imageSize?_this._getImageSize(iconObj_1):curSize;var imageOffset=_this._getImageOffset(iconObj_1);var img=iconElem_1.children[0];_this._setIconSize(iconElem_1,img,curSize,imageSize);_this._setIconStyle(iconElem_1,img,{curSize:curSize,imageSize:imageSize,imageOffset:imageOffset});_super.prototype.updateOverlay.call(_this)});this._outter.appendChild(iconElem_1)}else{var iconElem=iconData.elem,icon_1=iconData.params,size=iconData.size,iconObj=iconData.icon;this._opts.anchor=icon_1.ancher||icon_1.anchor;this._opts.size=iconObj.getSize();var curSize=this._getSize();var imageSize=icon_1.imageSize?this._getImageSize(iconObj):curSize;this._size=size;var imageOffset=this._getImageOffset(iconObj);var img=iconElem.children[0];this._setIconSize(iconElem,img,curSize,imageSize);this._setIconStyle(iconElem,img,{curSize:curSize,imageSize:imageSize,imageOffset:imageOffset});this._outter.appendChild(iconElem)}};ElasticMarker.prototype._updateLabel=function(label){var _a=label||{},content=_a.content,_b=_a.position,position=_b===void 0?"C":_b,offset=_a.offset;var direction=LabelDirectionMapping[position];var labelOpts={content:content,direction:direction,offset:offset,_needUpdate:false};this.setLabel(labelOpts)};ElasticMarker.prototype._updateElasticSize=function(icon,zoom){var _a=icon.fitZoom,fitZoom=_a===void 0?zoom:_a,_b=icon.scaleFactor,scaleFactor=_b===void 0?1:_b,_c=icon.maxScale,maxScale=_c===void 0?zoomRange[0]:_c,_d=icon.minScale,minScale=_d===void 0?zoomRange[1]:_d;var scaleZoom=zoom-fitZoom;var scaleAbs=Math.abs(scaleZoom);var upperExponent=Math.pow(scaleFactor,Math.ceil(scaleAbs));var lowerExponent=Math.pow(scaleFactor,Math.floor(scaleAbs));var upperScatter=(Math.ceil(scaleAbs)-scaleAbs)*(scaleFactor-1)+1;var lowerScatter=(scaleAbs-Math.floor(scaleAbs))*(scaleFactor-1)+1;var scale=scaleZoom>=0?lowerExponent*lowerScatter:1/upperExponent*upperScatter;scale=Math.min(maxScale,Math.max(minScale,scale));return scale};return ElasticMarker}(AMap.Marker);AMap["ElasticMarker"]=ElasticMarker})(); ');_jsload_('AMap.ToolBar', '(function(){"use strict";var extendStatics=function(d,b){extendStatics=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,b){d.__proto__=b}||function(d,b){for(var p in b)if(b.hasOwnProperty(p))d[p]=b[p]};return extendStatics(d,b)};function __extends(d,b){extendStatics(d,b);function __(){this.constructor=d}d.prototype=b===null?Object.create(b):(__.prototype=b.prototype,new __)}var zoomRange=[2,26];var defultOpts={position:{bottom:"20px",right:"20px"},offset:[15,15]};var ToolBar=function(_super){__extends(ToolBar,_super);function ToolBar(opts){if(opts===void 0){opts=defultOpts}var _this=_super.call(this,opts)||this;_this._className="toolbar";_this._handleZoomEnd=_this._handleZoomEnd.bind(_this);_this._config=AMap.extend(defultOpts,opts);_this.initContainer();_this._initUI();return _this}ToolBar.prototype.addTo=function(map){_super.prototype.addTo.call(this,map);this._handleZoomEnd();map.on("zoomend",this._handleZoomEnd)};ToolBar.prototype.remove=function(){if(this.map){this.map.off("zoomend",this._handleZoomEnd)}_super.prototype.remove.call(this)};ToolBar.prototype.removeFrom=function(map){if(map){map.off("zoomend",this._handleZoomEnd)}_super.prototype.removeFrom.call(this,map)};ToolBar.prototype._handleZoomEnd=function(){var map=this.map;var zooms=map.getZooms();if(map.getZoom()<=zooms[0]){this._zoomOut.style.color="#ddd"}else{this._zoomOut.style.color="#000"}if(map.getZoom()>=zooms[1]){this._zoomIn.style.color="#ddd"}else{this._zoomIn.style.color="#000"}};ToolBar.prototype._initUI=function(){var _this=this;this._zoomIn=AMap.DomUtil.create("span",this._container,"amap-ctrl-zoomin");this._zoomOut=AMap.DomUtil.create("span",this._container,"amap-ctrl-zoomout");this._zoomIn.innerHTML="+";this._zoomOut.innerHTML="-";this._zoomIn.setAttribute("data-type","add");this._zoomOut.setAttribute("data-type","sub");this._container.addEventListener("click",function(event){if(event.target instanceof HTMLElement){var type=event.target.getAttribute("data-type");var z=_this.map.getZoom();if(type==="add"){_this.map.setZoom(Math.min(z+1,zoomRange[1]))}else if(type==="sub"){_this.map.setZoom(Math.max(z-1,2))}}})};return ToolBar}(AMap.Control);AMap["ToolBar"]=ToolBar})(); ');_jsload_('AMap.Scale', '(function(){"use strict";var extendStatics=function(d,b){extendStatics=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,b){d.__proto__=b}||function(d,b){for(var p in b)if(b.hasOwnProperty(p))d[p]=b[p]};return extendStatics(d,b)};function __extends(d,b){extendStatics(d,b);function __(){this.constructor=d}d.prototype=b===null?Object.create(b):(__.prototype=b.prototype,new __)}var defultOpts={position:"LB",offset:[15,25]};var Scale=function(_super){__extends(Scale,_super);function Scale(opts){if(opts===void 0){opts=defultOpts}var _this=_super.call(this,opts)||this;_this._className="scalecontrol";_this._scaleLevel=[[1e7,"10000"],[5e6,"5000"],[2e6,"2000"],[1e6,"1000"],[5e5,"500"],[2e5,"200"],[1e5,"100"],[5e4,"50"],[3e4,"30"],[2e4,"20"],[1e4,"10"],[5e3,"5"],[2e3,"2"],[1e3,"1"],[500,"500"],[200,"200"],[100,"100"],[50,"50"],[25,"25"],[10,"10"],[5,"5"],[2,"2"],[1,"1"],[.5,"50"],[.2,"20"],[.1,"10"],[.05,"5"],[.02,"2"],[.01,"1"],[.01,"1"],[.01,"1"]];_this._handleViewChange=_this._handleViewChange.bind(_this);_this._config=AMap.extend(defultOpts,opts);_this.initContainer();return _this}Scale.prototype.addTo=function(map){_super.prototype.addTo.call(this,map);this._initUI();map.on("viewchange",this._handleViewChange)};Scale.prototype.remove=function(){if(this.map){this.map.off("viewchange",this._handleViewChange)}this._destroyUI();_super.prototype.remove.call(this)};Scale.prototype.removeFrom=function(map){if(map){map.off("viewchange",this._handleViewChange)}this._destroyUI();_super.prototype.removeFrom.call(this,map)};Scale.prototype._handleViewChange=function(){this._updateUI()};Scale.prototype._initUI=function(){this._text=AMap.DomUtil.create("div",this._container,"amap-scale-text");this._line=AMap.DomUtil.create("div",this._container,"amap-scale-line");this._lineLeft=AMap.DomUtil.create("div",this._container,"amap-scale-edgeleft");this._lineRight=AMap.DomUtil.create("div",this._container,"amap-scale-edgeright");this._lineMid=AMap.DomUtil.create("div",this._container,"amap-scale-middle");this._line.appendChild(this._lineLeft);this._line.appendChild(this._lineMid);this._line.appendChild(this._lineRight);this._updateUI()};Scale.prototype._destroyUI=function(){while(this._container.firstChild){this._container.removeChild(this._container.firstChild)}};Scale.prototype._updateUI=function(){var _a=this.map.getView().getStatus(),optimalZoom=_a.optimalZoom,center=_a.center,resolution=_a.resolution;var size=this.map.getSize().toArray();var level=optimalZoom-1;var coordX=resolution*Math.cos(center[1]/180*Math.PI);var len=this._scaleLevel[level][0]/coordX;for(var i=level;i<this._scaleLevel.length;i++){len=this._scaleLevel[level][0]/coordX;if(len<120){break}level++;level=Math.min(level,this._scaleLevel.length-1)}var scale=this._scaleLevel[level][1];if(level<=13){scale+=" 公里"}else if(level<23){scale+=" 米"}else{scale+=" 厘米"}this._text.innerText=scale;this._text.style.width=len+8+"px";this._lineMid.style.width=len+"px";this._lineRight.style.left=len+1+"px"};return Scale}(AMap.Control);AMap["Scale"]=Scale})(); ');_cssload_('AMap.HawkEye', '.amap-hawkeye{transition:width .2s,height .2s}.amap-hawkeye .button{position:absolute;z-index:1;cursor:pointer;border-color:silver;border-style:solid none none solid;border-width:1px;bottom:0;right:0;background-color:#fff;background-size:12px;background-image:url(https://a.amap.com/jsapi/static/image/plugin/arrow.png);background-size:cover}.amap-hawkeye .amap-container{z-index:0;width:100%;height:100%;min-width:1px;min-height:1px}.amap-hawkeye .amap-container .amap-copyright,.amap-hawkeye .amap-container .amap-logo{display:none!important}');_jsload_('AMap.HawkEye', '!function(r){"use strict";function t(t,e){var n,i=Object.keys(t);return Object.getOwnPropertySymbols&&(n=Object.getOwnPropertySymbols(t),e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),i.push.apply(i,n)),i}function a(i){for(var e=1;e<arguments.length;e++){var o=null!=arguments[e]?arguments[e]:{};e%2?t(Object(o),!0).forEach(function(e){var t,n;t=i,n=o[e=e],e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n}):Object.getOwnPropertyDescriptors?Object.defineProperties(i,Object.getOwnPropertyDescriptors(o)):t(Object(o)).forEach(function(e){Object.defineProperty(i,e,Object.getOwnPropertyDescriptor(o,e))})}return i}function s(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function c(e){return(c=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function l(e,t){return(l=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function h(e){if(void 0===e)throw new ReferenceError("this hasn\'t been initialised - super() hasn\'t been called");return e}function u(n){var i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var e,t=c(n),t=(e=i?(e=c(this).constructor,Reflect.construct(t,arguments,e)):t.apply(this,arguments),this);if(e&&("object"==typeof e||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return h(t)}}function f(){return(f="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var i=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=c(e)););return e}(e,t);if(i)return i=Object.getOwnPropertyDescriptor(i,t),i.get?i.get.call(arguments.length<3?e:n):i.value}).apply(this,arguments)}var e=function(e){var t=o;if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&l(t,e);var n,i=u(o);function o(e){if(!(this instanceof o))throw new TypeError("Cannot call a class as a function");var e=a({position:"RB",offset:[-2,-2],width:"150px",height:"180px",borderStyle:"double solid solid double",borderColor:"silver",borderRadius:"0px",borderWidth:"3px",buttonSize:"12px",showRectangle:!0,mapStyle:"",layers:[],autoMove:!0,showButton:!0,isOpen:!0,visible:!0},e);return(e=i.call(this,e))._className="hawkeye",e.initContainer(),e.CLASS_NAME="AMap.HawkEye",e.initUI(),e._config.isOpen||(e._container.style.width=e._config.buttonSize,e._container.style.height=e._config.buttonSize,e._config.autoMove&&e.map&&e.map.off("viewchange",e._handleViewChange,h(e))),e}return t=o,(e=[{key:"initUI",value:function(){for(var e=["width","height","borderStyle","borderWidth","borderColor","borderRadius"],t=0,n=e.length;t<n;t+=1)this._config[e[t]]&&(this._container.style[e[t]]=this._config[e[t]]);this.addButton()}},{key:"addButton",value:function(){var e,t=this;this._config.showButton&&((e=document.createElement("div")).className="button",e.style.width=e.style.height=this._config.buttonSize,this._container.appendChild(e),e.style.backgroundPositionX=this._config.isOpen?"0":"100%",e.addEventListener("click",function(){e.style.backgroundPositionX=t._config.isOpen?"0":"100%",t._config.isOpen?t.close():t.open()}))}},{key:"initMap",value:function(){var e=document.createElement("div");this._container.appendChild(e),this._smallMap=new r.Map(e,{zoom:this._config.zoom,mapStyle:this._config.mapStyle,center:this._config.center,layers:this._config.layers,dragEnable:!1,scrollWheel:!1,doubleClickZoom:!1,touchZoom:!1})}},{key:"addTo",value:function(e){f(c(o.prototype),"addTo",this).call(this,e),this._smallMap||this.initMap(),this._config.autoMove?(this._handleViewChange({zoom:e.getZoom(),center:e.getCenter()}),e.on("viewchange",this._handleViewChange,this)):(this._smallMap.setStatus({}),this._smallMap.setZoomAndCenter(this._config.zoom,this._config.center,!0))}},{key:"remove",value:function(){this.map&&this.map.off("viewchange",this._handleViewChange,this),this._smallMap&&(this.viewRectangle&&this._smallMap.remove(this.viewRectangle),this.optimalRectangle&&this._smallMap.remove(this.optimalRectangle),this._smallMap.destroy(),this._smallMap=null),f(c(o.prototype),"remove",this).call(this),this.viewRectangle=null,this.optimalRectangle=null,this._container.innerHTML=""}},{key:"_handleViewChange",value:function(e){var t,n=this;this._smallMap.setZoomAndCenter(e.zoom-4,e.center,!0),this._config.showRectangle&&(t=this.map.getBounds(),this.viewRectangle||(this.viewRectangle=new r.Rectangle({bounds:t,draggable:!0,fillOpacity:.1,zIndex:111}),this.optimalRectangle=new r.Rectangle({bounds:t,draggable:!1,fillOpacity:.1,zIndex:110}),this.viewRectangle.on("dragstart",function(){console.log("dragstart",n.viewRectangle.getBounds()+""),n.optimalRectangle.setBounds(n.viewRectangle.getBounds()),n._smallMap.add(n.optimalRectangle),n.optimalRectangle.show()}),this.viewRectangle.on("dragend",function(){console.log("dragend",n.viewRectangle.getBounds()+"");var e=n.viewRectangle.getBounds();n.optimalRectangle.setBounds(e),n.map.setBounds(e),n._smallMap.on("moveend",function(){n.optimalRectangle.hide()},n,!0)}),this._smallMap.add(this.viewRectangle)),this.viewRectangle.setBounds(t),e.zoom<4.5?(this.viewRectangle.hide(),this.optimalRectangle.hide()):this.viewRectangle.show())}},{key:"open",value:function(){this.show(),this._config.isOpen||(this._config.isOpen=!0,this._container.style.display="block",this._container.style.width=this._config.width,this._container.style.height=this._config.height,this._config.autoMove&&this.map.on("viewchange",this._handleViewChange,this),this.emit("open"))}},{key:"close",value:function(){this._config.isOpen&&(this._config.isOpen=!1,this._container.style.width=this._config.buttonSize,this._container.style.height=this._config.buttonSize,this._config.autoMove&&this.map.off("viewchange",this._handleViewChange,this),this.emit("close"))}},{key:"show",value:function(){this._config.visible||(this._config.visible=!0,this._container.style.display="block",this.emit("show"))}},{key:"hide",value:function(){this._config.visible&&(this._config.visible=!1,this._container.style.display="none",this.emit("hide"))}}])&&s(t.prototype,e),n&&s(t,n),Object.defineProperty(t,"prototype",{writable:!1}),o}(r.Control);r.HawkEye=e}(window.AMap); ');_jsload_('AMap.MapType', '(function(){"use strict";var extendStatics=function(d,b){extendStatics=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,b){d.__proto__=b}||function(d,b){for(var p in b)if(b.hasOwnProperty(p))d[p]=b[p]};return extendStatics(d,b)};function __extends(d,b){extendStatics(d,b);function __(){this.constructor=d}d.prototype=b===null?Object.create(b):(__.prototype=b.prototype,new __)}var extend=function(dest){var args=[];for(var _i=1;_i<arguments.length;_i++){args[_i-1]=arguments[_i]}var sources=Array.prototype.slice.call(arguments,1);var j;var len;var src;for(j=0,len=sources.length;j<len;j=j+1){src=sources[j]||{};for(var key in src){if(src.hasOwnProperty(key)){var target=src[key];if(typeof target!=="function"||!dest.prototype){dest[key]=target}else{dest.prototype[key]=target}}}}return dest};function isBrowser(){return typeof window!=="undefined"&&typeof document!=="undefined"}function isWasmSuppport(){try{if(typeof WebAssembly==="object"&&typeof WebAssembly.instantiate==="function"&&TextDecoder&&TextEncoder){var module=new WebAssembly.Module(new Uint8Array([0,97,115,109,1,0,0,0]));if(module instanceof WebAssembly.Module){return new WebAssembly.Instance(module)instanceof WebAssembly.Instance}}}catch(e){}return false}var testWepP=function(callback){var webP=new Image;webP.src="data:image/webp;base64,UklGRi4AAABXRUJQVlA4TCEAAAAvAUAAEB8wAiMw"+"AgSSNtse/cXjxyCCmrYNWPwmHRH9jwMA";webP.onload=webP.onerror=function(){callback(webP.height===2)}};function isWorkerEnv(){try{var flag=!!document;return false}catch(e){return true}}function getSupport(config){var amapRunTime={runSupport:(new Date).getTime()};var isRetina=false;var isMobile=false;var android=false;var webkit=false;var touch=false;var wasm=isWasmSuppport();var ua=navigator.userAgent.toLowerCase();var uaHas=function(key){return ua.indexOf(key)!==-1};var hardwareAccEnabled=true;var mac=uaHas("macintosh");var iPad=uaHas("ipad;")||uaHas("ipad "),iTouch=uaHas("ipod touch;"),iPhone=uaHas("iphone;")||uaHas("iphone "),ios=iPhone||iPad||iTouch,safari=(mac||ios)&&uaHas("safari")&&uaHas("version/"),macWechat=uaHas("macwechat"),windowsWechat=uaHas("windowswechat");var Browser={touch:touch,mac:mac,isRetina:isRetina,webkit:webkit,isMobile:isMobile,scale:1,android:android,isWorkerEnv:isWorkerEnv(),wasm:wasm,safari:safari,macWechat:macWechat,windowsWechat:windowsWechat,amapRunTime:amapRunTime};if(isBrowser()){var win_1=window,doc=document,docE=doc.documentElement,numberRegex_1=/([a-z0-9]*\\d+[a-z0-9]*)/,getGraphicCardShortStr_1=function(graphicVersion){if(!graphicVersion){return null}graphicVersion=graphicVersion.toLowerCase();var forShort=null;var b=graphicVersion.match(/angle \\((.*)\\)/);if(b){graphicVersion=b[1];graphicVersion=graphicVersion.replace(/\\s*direct3d.*$/,"")}graphicVersion=graphicVersion.replace(/\\s*\\([^\\)]*wddm[^\\)]*\\)/,"");if(graphicVersion.indexOf("intel")>=0){forShort=["Intel"];if(0<=graphicVersion.indexOf("mobile")){forShort.push("Mobile")}if(0<=graphicVersion.indexOf("gma")||0<=graphicVersion.indexOf("graphics media accelerator")){forShort.push("GMA")}if(0<=graphicVersion.indexOf("haswell")){forShort.push("Haswell")}else if(0<=graphicVersion.indexOf("ivy")){forShort.push("HD 4000")}else if(0<=graphicVersion.indexOf("sandy")){forShort.push("HD 3000")}else if(0<=graphicVersion.indexOf("ironlake")){forShort.push("HD")}else{if(0<=graphicVersion.indexOf("hd")){forShort.push("HD")}var number=graphicVersion.match(numberRegex_1);if(number){forShort.push(number[1].toUpperCase())}}forShort=forShort.join(" ");return forShort}if(graphicVersion.indexOf("nvidia")>=0||graphicVersion.indexOf("quadro")>=0||graphicVersion.indexOf("geforce")>=0||graphicVersion.indexOf("nvs")>=0){forShort=["nVidia"];if(0<=graphicVersion.indexOf("geforce")){forShort.push("geForce")}if(0<=graphicVersion.indexOf("quadro")){forShort.push("Quadro")}if(0<=graphicVersion.indexOf("nvs")){forShort.push("NVS")}if(graphicVersion.match(/\\bion\\b/)){forShort.push("ION")}if(graphicVersion.match(/gtx\\b/)){forShort.push("GTX")}else if(graphicVersion.match(/gts\\b/)){forShort.push("GTS")}else if(graphicVersion.match(/gt\\b/)){forShort.push("GT")}else if(graphicVersion.match(/gs\\b/)){forShort.push("GS")}else if(graphicVersion.match(/ge\\b/)){forShort.push("GE")}else if(graphicVersion.match(/fx\\b/)){forShort.push("FX")}var number=graphicVersion.match(numberRegex_1);if(number){forShort.push(number[1].toUpperCase().replace("GS",""))}if(0<=graphicVersion.indexOf("titan")){forShort.push("TITAN")}else if(0<=graphicVersion.indexOf("ti")){forShort.push("Ti")}forShort=forShort.join(" ");return forShort}if(graphicVersion.indexOf("amd")>=0||graphicVersion.indexOf("ati")>=0||graphicVersion.indexOf("radeon")>=0||graphicVersion.indexOf("firegl")>=0||graphicVersion.indexOf("firepro")>=0){forShort=["AMD"];if(0<=graphicVersion.indexOf("mobil")){forShort.push("Mobility")}var radeonIndex=graphicVersion.indexOf("radeon");if(0<=radeonIndex){forShort.push("Radeon")}if(0<=graphicVersion.indexOf("firepro")){forShort.push("FirePro")}else if(0<=graphicVersion.indexOf("firegl")){forShort.push("FireGL")}if(0<=graphicVersion.indexOf("hd")){forShort.push("HD")}if(radeonIndex>=0){graphicVersion=graphicVersion.substring(radeonIndex)}var number=graphicVersion.match(numberRegex_1);if(number){forShort.push(number[1].toUpperCase().replace("HD",""))}forShort=forShort.join(" ");return forShort}return graphicVersion.substring(0,100)},blackGraphicCard_1="google swiftshader;microsoft basic render driver;vmware svga 3d;Intel 965GM;Intel B43;Intel G41;Intel G45;Intel G965;Intel GMA 3600;Intel Mobile 4;Intel Mobile 45;Intel Mobile 965".split(";"),ie="ActiveXObject"in win_1,retina=window["detectRetina"]==false?false:"devicePixelRatio"in win_1&&win_1["devicePixelRatio"]>1||ie&&"matchMedia"in win_1&&win_1.matchMedia("(min-resolution:144dpi)")&&win_1.matchMedia("(min-resolution:144dpi)").matches,windows=uaHas("windows nt"),windowslt7=ua.search(/windows nt [1-5]\\./)!==-1,windowsXP=ua.search(/windows nt 5\\.[12]/)!==-1,windows10=uaHas("windows nt 10"),winPhone=uaHas("windows phone"),mb2345Browser=uaHas("Mb2345Browser"),ioslt7=ios&&ua.search(/ os [456]_/)!==-1,ioslt9=ios&&ua.search(/ os [4-8]_/)!==-1,ios78=ios&&ua.search(/ os [78]_/)!==-1,ios8=ios&&uaHas("os 8_"),ios10=ios&&uaHas("os 10_"),android_1=uaHas("android");var androidVersion=0;if(android_1){androidVersion=parseInt(ua.split("android")[1])||0}var android23=android_1&&androidVersion<4,android5plus=android_1&&androidVersion>=5,android44plus=android5plus||ua.search(/android 4.4/)!==-1,plat_1=android_1?"android":ios?"ios":windows?"windows":mac?"mac":"other",ie6=ie&&!win_1["XMLHttpRequest"],ie7=ie&&!doc.querySelector,ielt9=ie&&!doc.addEventListener,ie9=ie&&uaHas("msie 9"),ie10=ie&&uaHas("msie 10"),ie11=ie&&uaHas("rv:11"),ielt10=ielt9||ie9,edge=uaHas("edge"),QtWeb=uaHas("qtweb"),uc=uaHas("ucbrowser"),gaodeCoords=uaHas("alipay")||android_1&&uc,xiaomi=uaHas("miuibrowser"),wechat=uaHas("micromessenger"),dingding=uaHas("dingtalk"),qq=uaHas("mqqbrowser"),baidu=uaHas("baidubrowser"),crios=uaHas("crios/"),chrome=uaHas("chrome/"),chromium=(chrome||crios)&&uaHas("chromium"),chrome30plus=!chromium&&(chrome&&parseInt(ua.split("chrome/")[1])>30||crios&&parseInt(ua.split("crios/")[1])>30),firefox=uaHas("firefox"),firefox27plus=firefox&&parseInt(ua.split("firefox/")[1])>27,safari7plus=safari&&parseInt(ua.split("version/")[1])>7,aliApp=ios&&uaHas("aliapp"),mobile_1=android_1||ios||winPhone||uaHas("mobile"),touchDev="ontouchstart"in doc,msPointer=win_1["navigator"]&&win_1["navigator"]["msPointerEnabled"]&&!!win_1["navigator"]["msMaxTouchPoints"],pointer=win_1["navigator"]&&!!win_1["navigator"]["maxTouchPoints"],pointerDev=!touchDev&&(pointer||msPointer),touch_1=touchDev||pointerDev,getScale=function(){if(!mobile_1){return win_1.devicePixelRatio||1}var metas=document.getElementsByTagName("meta");if(window.parent&&window.parent!==window){try{if(window.parent.location.origin===window.location.origin){metas=window.parent.document.getElementsByTagName("meta")}else{return 1}}catch(e){return 1}}for(var i=metas.length-1;i>=0;i-=1){if(metas[i].name==="viewport"){var content=metas[i].content;var initial_scale=void 0,minimum_scale=void 0,maximum_scale=void 0;if(content.indexOf("initial-scale")!==-1){initial_scale=parseFloat(content.split("initial-scale=")[1])}if(content.indexOf("minimum-scale")!==-1){minimum_scale=parseFloat(content.split("minimum-scale=")[1])}else{minimum_scale=0}if(content.indexOf("maximum-scale")!==-1){maximum_scale=parseFloat(content.split("maximum-scale=")[1])}else{maximum_scale=Infinity}if(initial_scale){if(maximum_scale>=minimum_scale){if(initial_scale>maximum_scale){return maximum_scale}else if(initial_scale<minimum_scale){return minimum_scale}else{return initial_scale}}else{console&&console.log&&console.log("viewport参数不合法");return null}}else{if(maximum_scale>=minimum_scale){if(minimum_scale>=1){return 1}else{return Math.min(maximum_scale,1)}}else{console&&console.log&&console.log("viewport参数不合法");return null}}}}return undefined},viewportScale=getScale(),needFitRetina_1=retina&&(!mobile_1||!!viewportScale&&viewportScale>=1),ie3d=ie&&"transition"in docE.style,isSvg=!!doc.createElementNS&&!!doc.createElementNS("http://www.w3.org/2000/svg","svg")["createSVGRect"],canvas_1=doc.createElement("canvas"),isCanvas_1=!!(canvas_1&&canvas_1.getContext),UrlLib=window["URL"]||window["webkitURL"],DataUrl2Blob=false;var isWorker_1=window["disableWorker"]!==true&&!ie&&!(uc&&android_1&&!chrome30plus)&&window["Worker"]&&UrlLib&&UrlLib["createObjectURL"]&&window["Blob"],webglContextName_1="",graphicCard_1="",maxRenderSize_1=0,needAntialias=window["higtQualityRender"]==false?retina?false:true:true,movingDraw=window["movingDraw"],webglParams_1=window["forceWebGL"]?{alpha:true,antialias:needAntialias,depth:true,stencil:true}:{alpha:true,antialias:needAntialias,depth:true,stencil:true},checkWebgl=function(){if(!isCanvas_1||!isWorker_1){return false}var contextName=["webgl","experimental-webgl","moz-webgl"];var gl=null;for(var i=0;i<contextName.length;i+=1){try{var para=webglParams_1;gl=canvas_1.getContext(contextName[i],para)}catch(err){}if(!gl){continue}else{if(gl.drawingBufferWidth!==canvas_1.width||gl.drawingBufferHeight!==canvas_1.height){return false}if(!gl.getShaderPrecisionFormat||!gl.getParameter||!gl.getExtension){return false}maxRenderSize_1=gl.getParameter(gl.MAX_RENDERBUFFER_SIZE);var maxViewPortSize=gl.getParameter(gl.MAX_VIEWPORT_DIMS);if(!maxViewPortSize){return false}maxRenderSize_1=Math.min(maxRenderSize_1,maxViewPortSize[0],maxViewPortSize[1]);if(safari&&plat_1==="mac"){maxRenderSize_1=Math.min(maxRenderSize_1,4096)}var renderSize=Math.max(screen.width,screen.height);if(needFitRetina_1){renderSize*=Math.min(2,window.devicePixelRatio||1)}if(renderSize>maxRenderSize_1){return false}if(23>gl.getShaderPrecisionFormat(35632,36338).precision||23>gl.getShaderPrecisionFormat(35633,36338).precision){return false}graphicCard_1=gl.getExtension("WEBGL_debug_renderer_info")?gl.getParameter(37446):null;var graphicCardShort=getGraphicCardShortStr_1(graphicCard_1);if(graphicCardShort){if(graphicCardShort.indexOf("google swiftshader")>-1){hardwareAccEnabled=false;return false}if(-1!==blackGraphicCard_1.indexOf(graphicCardShort)){return false}}webglContextName_1=contextName[i];return true}}return false},canWebGL=checkWebgl(),enableVector=config[8]!==undefined?config[8]:true,byWebgl=window["Uint8Array"]&&enableVector&&!window["forbidenWebGL"]&&canWebGL&&(window["forceWebGL"]||(chrome30plus||firefox27plus||safari7plus||edge||wechat||dingding)&&plat_1!=="other"),baseRender=window["forceWebGLBaseRender"]?"w":byWebgl?"w":"d",webkit_1=uaHas("webkit"),webkit3d="WebKitCSSMatrix"in win_1&&"m11"in new window["WebKitCSSMatrix"],gecko3d="MozPerspective"in docE.style,opera3d="OTransition"in docE.style,any3d=ie3d||webkit3d||gecko3d||opera3d,enableLabelImage=false,vdataVersion=config[12]!==undefined?config[12]:null;var localStore=true;try{if(typeof win_1.localStorage==="undefined"){localStore=false}else{var tmpData=(new Date).getTime()+"";win_1.localStorage.setItem("_test",tmpData);if(win_1.localStorage.getItem("_test")!==tmpData){localStore=false}win_1.localStorage.removeItem("_test")}}catch(e){localStore=false}var getContext=function(canvas,opt){var params={};extend(params,webglParams_1);extend(params,opt);return canvas.getContext(webglContextName_1,params)};var chromeversion=parseInt(ua.split("chrome/")[1]);Browser={iPad:iPad,iPhone:iPhone,size:iPhone?100:android_1?200:500,mac:mac,windows:windows,ios:ios,ios10:ios10,android:android_1,android23:android23,gaodeCoords:gaodeCoords,plat:plat_1,baidu:baidu,qq:qq,safari:safari,wechat:wechat,ie:ie,ie6:ie6,ie7:ie7,ie9:ie9,ie10:ie10,ielt9:ielt9,ielt10:ielt10,ie11:ie11,edge:edge,ielt11:ie&&!ie11,mb2345Browser:mb2345Browser,localStore:localStore,vdataVersion:vdataVersion,geolocation:mobile_1||ie&&!ielt9||edge,uc_:uc,uc:uc&&!chrome,chrome:chrome,drawTextDir:true,firefox:firefox,hardwareAccEnabled:hardwareAccEnabled,isMobile:mobile_1,mobileWebkit:mobile_1&&webkit_1,mobileWebkit3d:mobile_1&&webkit3d,mobileOpera:mobile_1&&win_1.opera,isRetina:retina,viewportScale:viewportScale,needFitRetina:needFitRetina_1,touch:touch_1,msPointer:msPointer,pointer:pointer,pointerDev:pointerDev,chrome57:chrome&&chromeversion>=57,chrome64:!mobile_1&&chrome&&chromeversion>=64,webkit:webkit_1,ie3d:ie3d,webkit3d:webkit3d,gecko3d:gecko3d,opera3d:opera3d,any3d:any3d,isSvg:isSvg,isCanvas:isCanvas_1,isWorker:isWorker_1,useLabelImage:enableLabelImage,isWebGL:byWebgl,webglContextName:webglContextName_1,webglParams:webglParams_1,graphicCard:graphicCard_1,maxRenderSize:maxRenderSize_1,DataUrl2Blob:DataUrl2Blob,movingDraw:movingDraw,baseRender:enableVector?baseRender:"d",scale:retina?2:1,getContext:getContext,isWebp:false,wasm:wasm,amapRunTime:amapRunTime,checkWebgl:checkWebgl};testWepP(function(isWebp){Browser.isWebp=isWebp})}return Browser}var Browser=getSupport(typeof config==="undefined"?[]:config);if(typeof createImageBitmap!=="undefined"&&typeof ImageBitmap!=="undefined"){Browser.imageBitmap=true}var canceledWorkerFetch=Boolean(Browser.isWorkerEnv?!Browser.safari&&!Browser.macWechat&&!Browser.windowsWechat&&self.fetch&&self.Request&&self.AbortController&&self.Request.prototype.hasOwnProperty("signal"):!Browser.safari&&!Browser.macWechat&&!Browser.windowsWechat&&window.fetch&&window.Request&&window.AbortController&&window.Request.prototype.hasOwnProperty("signal"));Browser.canceledWorkerFetch=canceledWorkerFetch;Browser["amapRunTime"]={workerTime:{}};var freeGlobal=typeof global=="object"&&global&&global.Object===Object&&global;var freeSelf=typeof self=="object"&&self&&self.Object===Object&&self;var root=freeGlobal||freeSelf||Function("return this")();var Symbol=root.Symbol;var objectProto=Object.prototype;var hasOwnProperty=objectProto.hasOwnProperty;var nativeObjectToString=objectProto.toString;var symToStringTag=Symbol?Symbol.toStringTag:undefined;function getRawTag(value){var isOwn=hasOwnProperty.call(value,symToStringTag),tag=value[symToStringTag];try{value[symToStringTag]=undefined;var unmasked=true}catch(e){}var result=nativeObjectToString.call(value);if(unmasked){if(isOwn){value[symToStringTag]=tag}else{delete value[symToStringTag]}}return result}var objectProto$1=Object.prototype;var nativeObjectToString$1=objectProto$1.toString;function objectToString(value){return nativeObjectToString$1.call(value)}var nullTag="[object Null]",undefinedTag="[object Undefined]";var symToStringTag$1=Symbol?Symbol.toStringTag:undefined;function baseGetTag(value){if(value==null){return value===undefined?undefinedTag:nullTag}return symToStringTag$1&&symToStringTag$1 in Object(value)?getRawTag(value):objectToString(value)}function isObjectLike(value){return value!=null&&typeof value=="object"}var isArray=Array.isArray;function isObject(value){var type=typeof value;return value!=null&&(type=="object"||type=="function")}function identity(value){return value}var asyncTag="[object AsyncFunction]",funcTag="[object Function]",genTag="[object GeneratorFunction]",proxyTag="[object Proxy]";function isFunction(value){if(!isObject(value)){return false}var tag=baseGetTag(value);return tag==funcTag||tag==genTag||tag==asyncTag||tag==proxyTag}var coreJsData=root["__core-js_shared__"];var maskSrcKey=function(){var uid=/[^.]+$/.exec(coreJsData&&coreJsData.keys&&coreJsData.keys.IE_PROTO||"");return uid?"Symbol(src)_1."+uid:""}();function isMasked(func){return!!maskSrcKey&&maskSrcKey in func}var funcProto=Function.prototype;var funcToString=funcProto.toString;function toSource(func){if(func!=null){try{return funcToString.call(func)}catch(e){}try{return func+""}catch(e){}}return""}var reRegExpChar=/[\\\\^$.*+?()[\\]{}|]/g;var reIsHostCtor=/^\\[object .+?Constructor\\]$/;var funcProto$1=Function.prototype,objectProto$2=Object.prototype;var funcToString$1=funcProto$1.toString;var hasOwnProperty$1=objectProto$2.hasOwnProperty;var reIsNative=RegExp("^"+funcToString$1.call(hasOwnProperty$1).replace(reRegExpChar,"\\\\$&").replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g,"$1.*?")+"$");function baseIsNative(value){if(!isObject(value)||isMasked(value)){return false}var pattern=isFunction(value)?reIsNative:reIsHostCtor;return pattern.test(toSource(value))}function getValue(object,key){return object==null?undefined:object[key]}function getNative(object,key){var value=getValue(object,key);return baseIsNative(value)?value:undefined}function apply(func,thisArg,args){switch(args.length){case 0:return func.call(thisArg);case 1:return func.call(thisArg,args[0]);case 2:return func.call(thisArg,args[0],args[1]);case 3:return func.call(thisArg,args[0],args[1],args[2])}return func.apply(thisArg,args)}var HOT_COUNT=800,HOT_SPAN=16;var nativeNow=Date.now;function shortOut(func){var count=0,lastCalled=0;return function(){var stamp=nativeNow(),remaining=HOT_SPAN-(stamp-lastCalled);lastCalled=stamp;if(remaining>0){if(++count>=HOT_COUNT){return arguments[0]}}else{count=0}return func.apply(undefined,arguments)}}function constant(value){return function(){return value}}var defineProperty=function(){try{var func=getNative(Object,"defineProperty");func({},"",{});return func}catch(e){}}();var baseSetToString=!defineProperty?identity:function(func,string){return defineProperty(func,"toString",{configurable:true,enumerable:false,value:constant(string),writable:true})};var setToString=shortOut(baseSetToString);var MAX_SAFE_INTEGER=9007199254740991;var reIsUint=/^(?:0|[1-9]\\d*)$/;function isIndex(value,length){var type=typeof value;length=length==null?MAX_SAFE_INTEGER:length;return!!length&&(type=="number"||type!="symbol"&&reIsUint.test(value))&&(value>-1&&value%1==0&&value<length)}function baseAssignValue(object,key,value){if(key=="__proto__"&&defineProperty){defineProperty(object,key,{configurable:true,enumerable:true,value:value,writable:true})}else{object[key]=value}}function eq(value,other){return value===other||value!==value&&other!==other}var objectProto$3=Object.prototype;var hasOwnProperty$2=objectProto$3.hasOwnProperty;function assignValue(object,key,value){var objValue=object[key];if(!(hasOwnProperty$2.call(object,key)&&eq(objValue,value))||value===undefined&&!(key in object)){baseAssignValue(object,key,value)}}function copyObject(source,props,object,customizer){var isNew=!object;object||(object={});var index=-1,length=props.length;while(++index<length){var key=props[index];var newValue=customizer?customizer(object[key],source[key],key,object,source):undefined;if(newValue===undefined){newValue=source[key]}if(isNew){baseAssignValue(object,key,newValue)}else{assignValue(object,key,newValue)}}return object}var nativeMax=Math.max;function overRest(func,start,transform){start=nativeMax(start===undefined?func.length-1:start,0);return function(){var args=arguments,index=-1,length=nativeMax(args.length-start,0),array=Array(length);while(++index<length){array[index]=args[start+index]}index=-1;var otherArgs=Array(start+1);while(++index<start){otherArgs[index]=args[index]}otherArgs[start]=transform(array);return apply(func,this,otherArgs)}}function baseRest(func,start){return setToString(overRest(func,start,identity),func+"")}var MAX_SAFE_INTEGER$1=9007199254740991;function isLength(value){return typeof value=="number"&&value>-1&&value%1==0&&value<=MAX_SAFE_INTEGER$1}function isArrayLike(value){return value!=null&&isLength(value.length)&&!isFunction(value)}function isIterateeCall(value,index,object){if(!isObject(object)){return false}var type=typeof index;if(type=="number"?isArrayLike(object)&&isIndex(index,object.length):type=="string"&&index in object){return eq(object[index],value)}return false}function createAssigner(assigner){return baseRest(function(object,sources){var index=-1,length=sources.length,customizer=length>1?sources[length-1]:undefined,guard=length>2?sources[2]:undefined;customizer=assigner.length>3&&typeof customizer=="function"?(length--,customizer):undefined;if(guard&&isIterateeCall(sources[0],sources[1],guard)){customizer=length<3?undefined:customizer;length=1}object=Object(object);while(++index<length){var source=sources[index];if(source){assigner(object,source,index,customizer)}}return object})}var objectProto$4=Object.prototype;function isPrototype(value){var Ctor=value&&value.constructor,proto=typeof Ctor=="function"&&Ctor.prototype||objectProto$4;return value===proto}function baseTimes(n,iteratee){var index=-1,result=Array(n);while(++index<n){result[index]=iteratee(index)}return result}var argsTag="[object Arguments]";function baseIsArguments(value){return isObjectLike(value)&&baseGetTag(value)==argsTag}var objectProto$5=Object.prototype;var hasOwnProperty$3=objectProto$5.hasOwnProperty;var propertyIsEnumerable=objectProto$5.propertyIsEnumerable;var isArguments=baseIsArguments(function(){return arguments}())?baseIsArguments:function(value){return isObjectLike(value)&&hasOwnProperty$3.call(value,"callee")&&!propertyIsEnumerable.call(value,"callee")};function stubFalse(){return false}var freeExports=typeof exports=="object"&&exports&&!exports.nodeType&&exports;var freeModule=freeExports&&typeof module=="object"&&module&&!module.nodeType&&module;var moduleExports=freeModule&&freeModule.exports===freeExports;var Buffer=moduleExports?root.Buffer:undefined;var nativeIsBuffer=Buffer?Buffer.isBuffer:undefined;var isBuffer=nativeIsBuffer||stubFalse;var argsTag$1="[object Arguments]",arrayTag="[object Array]",boolTag="[object Boolean]",dateTag="[object Date]",errorTag="[object Error]",funcTag$1="[object Function]",mapTag="[object Map]",numberTag="[object Number]",objectTag="[object Object]",regexpTag="[object RegExp]",setTag="[object Set]",stringTag="[object String]",weakMapTag="[object WeakMap]";var arrayBufferTag="[object ArrayBuffer]",dataViewTag="[object DataView]",float32Tag="[object Float32Array]",float64Tag="[object Float64Array]",int8Tag="[object Int8Array]",int16Tag="[object Int16Array]",int32Tag="[object Int32Array]",uint8Tag="[object Uint8Array]",uint8ClampedTag="[object Uint8ClampedArray]",uint16Tag="[object Uint16Array]",uint32Tag="[object Uint32Array]";var typedArrayTags={};typedArrayTags[float32Tag]=typedArrayTags[float64Tag]=typedArrayTags[int8Tag]=typedArrayTags[int16Tag]=typedArrayTags[int32Tag]=typedArrayTags[uint8Tag]=typedArrayTags[uint8ClampedTag]=typedArrayTags[uint16Tag]=typedArrayTags[uint32Tag]=true;typedArrayTags[argsTag$1]=typedArrayTags[arrayTag]=typedArrayTags[arrayBufferTag]=typedArrayTags[boolTag]=typedArrayTags[dataViewTag]=typedArrayTags[dateTag]=typedArrayTags[errorTag]=typedArrayTags[funcTag$1]=typedArrayTags[mapTag]=typedArrayTags[numberTag]=typedArrayTags[objectTag]=typedArrayTags[regexpTag]=typedArrayTags[setTag]=typedArrayTags[stringTag]=typedArrayTags[weakMapTag]=false;function baseIsTypedArray(value){return isObjectLike(value)&&isLength(value.length)&&!!typedArrayTags[baseGetTag(value)]}function baseUnary(func){return function(value){return func(value)}}var freeExports$1=typeof exports=="object"&&exports&&!exports.nodeType&&exports;var freeModule$1=freeExports$1&&typeof module=="object"&&module&&!module.nodeType&&module;var moduleExports$1=freeModule$1&&freeModule$1.exports===freeExports$1;var freeProcess=moduleExports$1&&freeGlobal.process;var nodeUtil=function(){try{var types=freeModule$1&&freeModule$1.require&&freeModule$1.require("util").types;if(types){return types}return freeProcess&&freeProcess.binding&&freeProcess.binding("util")}catch(e){}}();var nodeIsTypedArray=nodeUtil&&nodeUtil.isTypedArray;var isTypedArray=nodeIsTypedArray?baseUnary(nodeIsTypedArray):baseIsTypedArray;var objectProto$6=Object.prototype;var hasOwnProperty$4=objectProto$6.hasOwnProperty;function arrayLikeKeys(value,inherited){var isArr=isArray(value),isArg=!isArr&&isArguments(value),isBuff=!isArr&&!isArg&&isBuffer(value),isType=!isArr&&!isArg&&!isBuff&&isTypedArray(value),skipIndexes=isArr||isArg||isBuff||isType,result=skipIndexes?baseTimes(value.length,String):[],length=result.length;for(var key in value){if((inherited||hasOwnProperty$4.call(value,key))&&!(skipIndexes&&(key=="length"||isBuff&&(key=="offset"||key=="parent")||isType&&(key=="buffer"||key=="byteLength"||key=="byteOffset")||isIndex(key,length)))){result.push(key)}}return result}function overArg(func,transform){return function(arg){return func(transform(arg))}}var nativeKeys=overArg(Object.keys,Object);var objectProto$7=Object.prototype;var hasOwnProperty$5=objectProto$7.hasOwnProperty;function baseKeys(object){if(!isPrototype(object)){return nativeKeys(object)}var result=[];for(var key in Object(object)){if(hasOwnProperty$5.call(object,key)&&key!="constructor"){result.push(key)}}return result}function keys(object){return isArrayLike(object)?arrayLikeKeys(object):baseKeys(object)}var objectProto$8=Object.prototype;var hasOwnProperty$6=objectProto$8.hasOwnProperty;var assign=createAssigner(function(object,source){if(isPrototype(source)||isArrayLike(source)){copyObject(source,keys(source),object);return}for(var key in source){if(hasOwnProperty$6.call(source,key)){assignValue(object,key,source[key])}}});var MapType=function(_super){__extends(MapType,_super);function MapType(opts){var _this=_super.call(this,opts||{})||this;_this._className="maptype";_this._guid=Math.random();var defultOpts={position:{top:"20px",right:"20px"},defaultType:0,showRoad:false,showTraffic:false,layerInfos:[{id:"AMap.TileLayer",name:"标准图层",enable:true,type:"base",layer:Browser.baseRender==="w"?AMap.createDefaultLayer():new AMap["TileLayer"]({tileUrl:AMap.getConfig().defaultTileUrl})},{id:"AMap.TileLayer.Satellite",name:"卫星图",enable:true,type:"base",layer:new AMap.TileLayer.Satellite({})},{id:"AMap.TileLayer.RoadNet",enable:true,name:"路网",type:"overlay",layer:new AMap.TileLayer.RoadNet({})},{id:"AMap.TileLayer.Traffic",enable:true,name:"路况",type:"overlay",layer:new AMap.TileLayer.Traffic({})}]};_this._layerData={base:[],overlay:[]};_this._config=assign(defultOpts,opts);_this.initContainer();_this._initUI();return _this}MapType.prototype.addLayer=function(layerInfo){if(layerInfo.enable===undefined){layerInfo.enable=true}if(layerInfo.type==="base"){this._addBaseDiv(layerInfo)}else if(layerInfo.type==="overlay"){this._addOverlayDiv(layerInfo)}else{console.log(\'图层配置 type 信息不完正确!可选值:"base"、"overlay"\')}};MapType.prototype.removeLayer=function(id){var overlays=this._layerData.overlay;var bases=this._layerData.base;for(var i=0;i<overlays.length;i++){var o=overlays[i];if(id===o.layerInfo.id){this._layerOverlayList.removeChild(o.container);overlays.splice(i,1);i--}}for(var i=0;i<bases.length;i++){var b=bases[i];if(id===b.layerInfo.id){this._layerBaseList.removeChild(b.container);bases.splice(i,1);i--}}return this};MapType.prototype.addTo=function(map){_super.prototype.addTo.call(this,map);this._initLayers()};MapType.prototype.remove=function(){this._layerData={base:[],overlay:[]};AMap.DomUtil.empty(this._layerBaseList);AMap.DomUtil.empty(this._layerOverlayList);_super.prototype.remove.call(this)};MapType.prototype.removeFrom=function(map){this._layerData={base:[],overlay:[]};AMap.DomUtil.empty(this._layerBaseList);AMap.DomUtil.empty(this._layerOverlayList);_super.prototype.removeFrom.call(this,map)};MapType.prototype._initUI=function(){var _this=this;this._layerIcon=AMap.DomUtil.create("div",this._container,"amap-ctrl-icon-layer");this._layerIcon.style.display="none";this._layerList=AMap.DomUtil.create("div",this._container,"amap-ctrl-list-layer");this._layerBaseList=AMap.DomUtil.create("ul",this._container,"amap-ctrl-base-layer");this._layerOverlayList=AMap.DomUtil.create("ul",this._container,"amap-ctrl-overlay-layer");this._layerList.appendChild(this._layerBaseList);this._layerList.appendChild(this._layerOverlayList);this._container.addEventListener("mouseenter",function(event){});this._container.addEventListener("mouseleave",function(event){});this._container.addEventListener("click",function(event){var t=event.target;if(t&&t.nodeName==="INPUT"){var id=t.getAttribute("data-id");var type=t.getAttribute("data-type");var checked=t.checked;if(type){if(type==="base"){for(var i=0;i<_this._layerData.base.length;i++){var l=_this._layerData.base[i];l.layerInfo.layer.hide()}}for(var i=0;i<_this._layerData[type].length;i++){var l=_this._layerData[type][i];if(l.layerInfo.id===id){if(checked){l.layerInfo.layer.show()}else{l.layerInfo.layer.hide()}}}}}})};MapType.prototype._initLayers=function(){var config=this._config;var mapLayers=this.map.getLayers();for(var i=0;i<mapLayers.length;i++){var ml=mapLayers[i];if(/AMap\\.(TileLayer\\.RoadNet|TileLayer\\.Traffic|TileLayer\\.Satellite|NebulaLayer|TileLayer)/g.test(ml.CLASS_NAME)){if(config.layerInfos){for(var u=0;u<config.layerInfos.length;u++){var info=config.layerInfos[u];if(info.id===ml.CLASS_NAME){config.layerInfos[u].layer=ml}}}}}if(config.layerInfos&&config.layerInfos.length>0){for(var i=0;i<config.layerInfos.length;i++){var layerInfo=config.layerInfos[i];this.map.addLayer(layerInfo.layer);if(config.defaultType===0&&(layerInfo.layer.CLASS_NAME==="AMap.NebulaLayer"||layerInfo.layer.CLASS_NAME==="AMap.TileLayer")||config.showRoad&&layerInfo.layer.CLASS_NAME==="AMap.TileLayer.RoadNet"||config.showTraffic&&layerInfo.layer.CLASS_NAME==="AMap.TileLayer.Traffic"||config.defaultType===1&&layerInfo.layer.CLASS_NAME==="AMap.TileLayer.Satellite"){layerInfo.layer.show();layerInfo.show=true}else{layerInfo.layer.hide()}this.addLayer(layerInfo)}}};MapType.prototype._addBaseDiv=function(layerInfo){var div=AMap.DomUtil.create("li",this._container,"amap-ui-ctrl-layer-base-item");this._layerBaseList.appendChild(div);div.innerHTML="\\n <input data-id=\'"+layerInfo.id+"\'\\n data-type=\'base\'\\n name=\'layer-base-item-"+this._guid+"\'\\n type=\'radio\' "+(layerInfo.enable?"":"disabled")+"\\n "+(layerInfo.show?"checked":"")+" />\\n <p>"+layerInfo.name+"</p>\\n ";this._layerData.base.push({layerInfo:layerInfo,container:div})};MapType.prototype._addOverlayDiv=function(layerInfo){var div=AMap.DomUtil.create("li",this._container,"amap-ui-ctrl-layer-overlay-item");this._layerOverlayList.appendChild(div);div.innerHTML="\\n <input data-id=\'"+layerInfo.id+"\'\\n data-type=\'overlay\'\\n name=\'layer-overlay-item\'\\n type=\'checkbox\' "+(layerInfo.enable?"":"disabled")+"\\n "+(layerInfo.show?"checked":"")+" />\\n <p>"+layerInfo.name+"</p>\\n ";this._layerData.overlay.push({layerInfo:layerInfo,container:div})};return MapType}(AMap.Control);AMap["MapType"]=MapType})(); ');_jsload_('AMap.MouseTool', '(function(){"use strict";var extendStatics=function(d,b){extendStatics=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,b){d.__proto__=b}||function(d,b){for(var p in b)if(b.hasOwnProperty(p))d[p]=b[p]};return extendStatics(d,b)};function __extends(d,b){extendStatics(d,b);function __(){this.constructor=d}d.prototype=b===null?Object.create(b):(__.prototype=b.prototype,new __)}var freeGlobal=typeof global=="object"&&global&&global.Object===Object&&global;var freeSelf=typeof self=="object"&&self&&self.Object===Object&&self;var root=freeGlobal||freeSelf||Function("return this")();var Symbol=root.Symbol;var objectProto=Object.prototype;var hasOwnProperty=objectProto.hasOwnProperty;var nativeObjectToString=objectProto.toString;var symToStringTag=Symbol?Symbol.toStringTag:undefined;function getRawTag(value){var isOwn=hasOwnProperty.call(value,symToStringTag),tag=value[symToStringTag];try{value[symToStringTag]=undefined;var unmasked=true}catch(e){}var result=nativeObjectToString.call(value);if(unmasked){if(isOwn){value[symToStringTag]=tag}else{delete value[symToStringTag]}}return result}var objectProto$1=Object.prototype;var nativeObjectToString$1=objectProto$1.toString;function objectToString(value){return nativeObjectToString$1.call(value)}var nullTag="[object Null]",undefinedTag="[object Undefined]";var symToStringTag$1=Symbol?Symbol.toStringTag:undefined;function baseGetTag(value){if(value==null){return value===undefined?undefinedTag:nullTag}return symToStringTag$1&&symToStringTag$1 in Object(value)?getRawTag(value):objectToString(value)}function isObjectLike(value){return value!=null&&typeof value=="object"}var isArray=Array.isArray;function isObject(value){var type=typeof value;return value!=null&&(type=="object"||type=="function")}function identity(value){return value}var asyncTag="[object AsyncFunction]",funcTag="[object Function]",genTag="[object GeneratorFunction]",proxyTag="[object Proxy]";function isFunction(value){if(!isObject(value)){return false}var tag=baseGetTag(value);return tag==funcTag||tag==genTag||tag==asyncTag||tag==proxyTag}var coreJsData=root["__core-js_shared__"];var maskSrcKey=function(){var uid=/[^.]+$/.exec(coreJsData&&coreJsData.keys&&coreJsData.keys.IE_PROTO||"");return uid?"Symbol(src)_1."+uid:""}();function isMasked(func){return!!maskSrcKey&&maskSrcKey in func}var funcProto=Function.prototype;var funcToString=funcProto.toString;function toSource(func){if(func!=null){try{return funcToString.call(func)}catch(e){}try{return func+""}catch(e){}}return""}var reRegExpChar=/[\\\\^$.*+?()[\\]{}|]/g;var reIsHostCtor=/^\\[object .+?Constructor\\]$/;var funcProto$1=Function.prototype,objectProto$2=Object.prototype;var funcToString$1=funcProto$1.toString;var hasOwnProperty$1=objectProto$2.hasOwnProperty;var reIsNative=RegExp("^"+funcToString$1.call(hasOwnProperty$1).replace(reRegExpChar,"\\\\$&").replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g,"$1.*?")+"$");function baseIsNative(value){if(!isObject(value)||isMasked(value)){return false}var pattern=isFunction(value)?reIsNative:reIsHostCtor;return pattern.test(toSource(value))}function getValue(object,key){return object==null?undefined:object[key]}function getNative(object,key){var value=getValue(object,key);return baseIsNative(value)?value:undefined}function apply(func,thisArg,args){switch(args.length){case 0:return func.call(thisArg);case 1:return func.call(thisArg,args[0]);case 2:return func.call(thisArg,args[0],args[1]);case 3:return func.call(thisArg,args[0],args[1],args[2])}return func.apply(thisArg,args)}var HOT_COUNT=800,HOT_SPAN=16;var nativeNow=Date.now;function shortOut(func){var count=0,lastCalled=0;return function(){var stamp=nativeNow(),remaining=HOT_SPAN-(stamp-lastCalled);lastCalled=stamp;if(remaining>0){if(++count>=HOT_COUNT){return arguments[0]}}else{count=0}return func.apply(undefined,arguments)}}function constant(value){return function(){return value}}var defineProperty=function(){try{var func=getNative(Object,"defineProperty");func({},"",{});return func}catch(e){}}();var baseSetToString=!defineProperty?identity:function(func,string){return defineProperty(func,"toString",{configurable:true,enumerable:false,value:constant(string),writable:true})};var setToString=shortOut(baseSetToString);var MAX_SAFE_INTEGER=9007199254740991;var reIsUint=/^(?:0|[1-9]\\d*)$/;function isIndex(value,length){var type=typeof value;length=length==null?MAX_SAFE_INTEGER:length;return!!length&&(type=="number"||type!="symbol"&&reIsUint.test(value))&&(value>-1&&value%1==0&&value<length)}function baseAssignValue(object,key,value){if(key=="__proto__"&&defineProperty){defineProperty(object,key,{configurable:true,enumerable:true,value:value,writable:true})}else{object[key]=value}}function eq(value,other){return value===other||value!==value&&other!==other}var objectProto$3=Object.prototype;var hasOwnProperty$2=objectProto$3.hasOwnProperty;function assignValue(object,key,value){var objValue=object[key];if(!(hasOwnProperty$2.call(object,key)&&eq(objValue,value))||value===undefined&&!(key in object)){baseAssignValue(object,key,value)}}function copyObject(source,props,object,customizer){var isNew=!object;object||(object={});var index=-1,length=props.length;while(++index<length){var key=props[index];var newValue=customizer?customizer(object[key],source[key],key,object,source):undefined;if(newValue===undefined){newValue=source[key]}if(isNew){baseAssignValue(object,key,newValue)}else{assignValue(object,key,newValue)}}return object}var nativeMax=Math.max;function overRest(func,start,transform){start=nativeMax(start===undefined?func.length-1:start,0);return function(){var args=arguments,index=-1,length=nativeMax(args.length-start,0),array=Array(length);while(++index<length){array[index]=args[start+index]}index=-1;var otherArgs=Array(start+1);while(++index<start){otherArgs[index]=args[index]}otherArgs[start]=transform(array);return apply(func,this,otherArgs)}}function baseRest(func,start){return setToString(overRest(func,start,identity),func+"")}var MAX_SAFE_INTEGER$1=9007199254740991;function isLength(value){return typeof value=="number"&&value>-1&&value%1==0&&value<=MAX_SAFE_INTEGER$1}function isArrayLike(value){return value!=null&&isLength(value.length)&&!isFunction(value)}function isIterateeCall(value,index,object){if(!isObject(object)){return false}var type=typeof index;if(type=="number"?isArrayLike(object)&&isIndex(index,object.length):type=="string"&&index in object){return eq(object[index],value)}return false}function createAssigner(assigner){return baseRest(function(object,sources){var index=-1,length=sources.length,customizer=length>1?sources[length-1]:undefined,guard=length>2?sources[2]:undefined;customizer=assigner.length>3&&typeof customizer=="function"?(length--,customizer):undefined;if(guard&&isIterateeCall(sources[0],sources[1],guard)){customizer=length<3?undefined:customizer;length=1}object=Object(object);while(++index<length){var source=sources[index];if(source){assigner(object,source,index,customizer)}}return object})}var objectProto$4=Object.prototype;function isPrototype(value){var Ctor=value&&value.constructor,proto=typeof Ctor=="function"&&Ctor.prototype||objectProto$4;return value===proto}function baseTimes(n,iteratee){var index=-1,result=Array(n);while(++index<n){result[index]=iteratee(index)}return result}var argsTag="[object Arguments]";function baseIsArguments(value){return isObjectLike(value)&&baseGetTag(value)==argsTag}var objectProto$5=Object.prototype;var hasOwnProperty$3=objectProto$5.hasOwnProperty;var propertyIsEnumerable=objectProto$5.propertyIsEnumerable;var isArguments=baseIsArguments(function(){return arguments}())?baseIsArguments:function(value){return isObjectLike(value)&&hasOwnProperty$3.call(value,"callee")&&!propertyIsEnumerable.call(value,"callee")};function stubFalse(){return false}var freeExports=typeof exports=="object"&&exports&&!exports.nodeType&&exports;var freeModule=freeExports&&typeof module=="object"&&module&&!module.nodeType&&module;var moduleExports=freeModule&&freeModule.exports===freeExports;var Buffer=moduleExports?root.Buffer:undefined;var nativeIsBuffer=Buffer?Buffer.isBuffer:undefined;var isBuffer=nativeIsBuffer||stubFalse;var argsTag$1="[object Arguments]",arrayTag="[object Array]",boolTag="[object Boolean]",dateTag="[object Date]",errorTag="[object Error]",funcTag$1="[object Function]",mapTag="[object Map]",numberTag="[object Number]",objectTag="[object Object]",regexpTag="[object RegExp]",setTag="[object Set]",stringTag="[object String]",weakMapTag="[object WeakMap]";var arrayBufferTag="[object ArrayBuffer]",dataViewTag="[object DataView]",float32Tag="[object Float32Array]",float64Tag="[object Float64Array]",int8Tag="[object Int8Array]",int16Tag="[object Int16Array]",int32Tag="[object Int32Array]",uint8Tag="[object Uint8Array]",uint8ClampedTag="[object Uint8ClampedArray]",uint16Tag="[object Uint16Array]",uint32Tag="[object Uint32Array]";var typedArrayTags={};typedArrayTags[float32Tag]=typedArrayTags[float64Tag]=typedArrayTags[int8Tag]=typedArrayTags[int16Tag]=typedArrayTags[int32Tag]=typedArrayTags[uint8Tag]=typedArrayTags[uint8ClampedTag]=typedArrayTags[uint16Tag]=typedArrayTags[uint32Tag]=true;typedArrayTags[argsTag$1]=typedArrayTags[arrayTag]=typedArrayTags[arrayBufferTag]=typedArrayTags[boolTag]=typedArrayTags[dataViewTag]=typedArrayTags[dateTag]=typedArrayTags[errorTag]=typedArrayTags[funcTag$1]=typedArrayTags[mapTag]=typedArrayTags[numberTag]=typedArrayTags[objectTag]=typedArrayTags[regexpTag]=typedArrayTags[setTag]=typedArrayTags[stringTag]=typedArrayTags[weakMapTag]=false;function baseIsTypedArray(value){return isObjectLike(value)&&isLength(value.length)&&!!typedArrayTags[baseGetTag(value)]}function baseUnary(func){return function(value){return func(value)}}var freeExports$1=typeof exports=="object"&&exports&&!exports.nodeType&&exports;var freeModule$1=freeExports$1&&typeof module=="object"&&module&&!module.nodeType&&module;var moduleExports$1=freeModule$1&&freeModule$1.exports===freeExports$1;var freeProcess=moduleExports$1&&freeGlobal.process;var nodeUtil=function(){try{var types=freeModule$1&&freeModule$1.require&&freeModule$1.require("util").types;if(types){return types}return freeProcess&&freeProcess.binding&&freeProcess.binding("util")}catch(e){}}();var nodeIsTypedArray=nodeUtil&&nodeUtil.isTypedArray;var isTypedArray=nodeIsTypedArray?baseUnary(nodeIsTypedArray):baseIsTypedArray;var objectProto$6=Object.prototype;var hasOwnProperty$4=objectProto$6.hasOwnProperty;function arrayLikeKeys(value,inherited){var isArr=isArray(value),isArg=!isArr&&isArguments(value),isBuff=!isArr&&!isArg&&isBuffer(value),isType=!isArr&&!isArg&&!isBuff&&isTypedArray(value),skipIndexes=isArr||isArg||isBuff||isType,result=skipIndexes?baseTimes(value.length,String):[],length=result.length;for(var key in value){if((inherited||hasOwnProperty$4.call(value,key))&&!(skipIndexes&&(key=="length"||isBuff&&(key=="offset"||key=="parent")||isType&&(key=="buffer"||key=="byteLength"||key=="byteOffset")||isIndex(key,length)))){result.push(key)}}return result}function overArg(func,transform){return function(arg){return func(transform(arg))}}var nativeKeys=overArg(Object.keys,Object);var objectProto$7=Object.prototype;var hasOwnProperty$5=objectProto$7.hasOwnProperty;function baseKeys(object){if(!isPrototype(object)){return nativeKeys(object)}var result=[];for(var key in Object(object)){if(hasOwnProperty$5.call(object,key)&&key!="constructor"){result.push(key)}}return result}function keys(object){return isArrayLike(object)?arrayLikeKeys(object):baseKeys(object)}var objectProto$8=Object.prototype;var hasOwnProperty$6=objectProto$8.hasOwnProperty;var assign=createAssigner(function(object,source){if(isPrototype(source)||isArrayLike(source)){copyObject(source,keys(source),object);return}for(var key in source){if(hasOwnProperty$6.call(source,key)){assignValue(object,key,source[key])}}});var MouseTool=function(_super){__extends(MouseTool,_super);function MouseTool(map,toolBubble){var _this=_super.call(this)||this;_this["CLASS_NAME"]="AMap.MouseTool";_this._map=map;_this._container=_this._map.getMapsContainer();_this.overlayBubble=toolBubble?toolBubble:false;_this.overlays={marker:[],circle:[],rectangle:[],polyline:[],polygon:[],measureArea:[]};_this.ruler=null;_this.eventsList=[];_this.keyboardEventsList=[];return _this}MouseTool.prototype.marker=function(opts){this._onStart();this._bind("click",this._renderMarker.bind(this,opts))};MouseTool.prototype.circle=function(opts){this._onStart();this._bind("mousedown",this._createCircle.bind(this,opts));this._bind("mouseup",this._doneCircle)};MouseTool.prototype.rectangle=function(opts){this._onStart();this._bind("mousedown",this._createRectangle.bind(this,opts));this._bind("mouseup",this._doneRectangle)};MouseTool.prototype.polyline=function(opts){this._onStart();this._bind("click",this._addPolylinePoint.bind(this,opts));this._bind("rightclick",this._delPolylineLinePoint.bind(this));this._bind("dblclick",this._endPolylineLine.bind(this,"db"))};MouseTool.prototype.polygon=function(opts){this._onStart();this._bind("click",this._addPolygonPoint.bind(this,opts));this._bind("dblclick",this._delPolygonPoint.bind(this));this._bind("rightclick",this._endPolygon.bind(this))};MouseTool.prototype.measureArea=function(opts){this._onStart();this._bind("click",this._addMeasureAreaPoint.bind(this,opts));this._bind("rightclick",this._endMeasureArea.bind(this));this._bind("dblclick",this._endMeasureArea.bind(this));this._bind("keydown",this._keydownMeasureArea.bind(this,opts))};MouseTool.prototype.rule=function(opts){var _this=this;this._onStart();AMap.plugin("AMap.RangingTool",function(){_this.ruler=new AMap.RangingTool(_this._map,opts);_this.ruler.turnOn();_this.ruler.on("end",function(e){_this.emit("draw",{obj:e.polyline})})})};MouseTool.prototype.rectZoomIn=function(opts){this._onStart();this._bind("mousedown",this._createRectangle.bind(this,opts));this._bind("mouseup",this._doneZoomIn)};MouseTool.prototype.rectZoomOut=function(opts){this._onStart();this._bind("mousedown",this._createRectangle.bind(this,opts));this._bind("mouseup",this._doneZoomOut)};MouseTool.prototype.close=function(ifClear){if(ifClear){if(this.ruler){this.ruler.turnOff(true)}var keys=Object.keys(this.overlays);for(var i=0;i<keys.length;i++){var overlay=this.overlays[keys[i]];this._map.remove(overlay)}this.overlays={marker:[],circle:[],rectangle:[],polyline:[],polygon:[],measureArea:[]}}this._onEnd(ifClear)};MouseTool.prototype._bind=function(TYPE,FUN){if(TYPE&&TYPE==="keydown"){this._container.addEventListener("keydown",FUN,this);this.keyboardEventsList.push({type:TYPE,fun:FUN})}else{this._map.on(TYPE,FUN,this);this.eventsList.push({type:TYPE,fun:FUN})}};MouseTool.prototype._unbind=function(){var eventLen=this.eventsList.length;var keyboardEventLen=this.keyboardEventsList.length;for(var i=0;i<eventLen;i++){var event=this.eventsList[i];this._map.off(event.type,event.fun,this)}for(var i=0;i<keyboardEventLen;i++){var event=this.keyboardEventsList[i];this._container.removeEventListener("keydown",event.fun)}};MouseTool.prototype._keydownMeasureArea=function(opts,e){if(e&&e.key==="Escape"){this._endMeasureArea()}};MouseTool.prototype._addMeasureAreaPoint=function(opts,e){this.mapDoubleClickZoom=this._map["getStatus"]()["doubleClickZoom"];this._map["setStatus"]({doubleClickZoom:false});if(!this.MeasureAreaTemp){var options={path:[e["lnglat"],e["lnglat"]],strokeColor:"#1791fc",fillColor:"#1791fc",strokeOpacity:.8,fillOpacity:.35,strokeWeight:2,strokeStyle:"solid",strokeDasharray:[10,5],zIndex:10,extData:{},bubble:true,innerOverlay:true};var polylineOpts=assign(options,opts);this.MeasureAreaTemp={path:[]};this.MeasureAreaTemp.obj=new AMap.Polygon(polylineOpts);this._map.add(this.MeasureAreaTemp.obj);this._map.on("mousemove",this._drawMeasureArea,this)}else{var newPoint=[e["lnglat"].lng,e["lnglat"].lat];var pathArr=this.MeasureAreaTemp.obj["getPath"]();pathArr.push(newPoint);this.MeasureAreaTemp.obj["setPath"](pathArr)}this.emit("addnode",{obj:this.MeasureAreaTemp.obj})};MouseTool.prototype._drawMeasureArea=function(e){if(this.MeasureAreaTemp&&this.MeasureAreaTemp.obj){var newPoint=[e["lnglat"].lng,e["lnglat"].lat];var pathArr=this.MeasureAreaTemp.obj["getPath"]();pathArr.pop();pathArr.push(newPoint);this.MeasureAreaTemp.obj["setPath"](pathArr)}};MouseTool.prototype._endMeasureArea=function(){this._map["setStatus"]({doubleClickZoom:this.mapDoubleClickZoom});var pathArr=this.MeasureAreaTemp&&this.MeasureAreaTemp.obj&&this.MeasureAreaTemp.obj["getPath"]();if(pathArr&&pathArr.length>3){pathArr.pop();this.MeasureAreaTemp.obj["setPath"](pathArr);var area=this.MeasureAreaTemp.obj["getArea"]();var areaHTML=area>1*1e5?(area*1e-6).toFixed(2)+"平方公里":area.toFixed(1)+"平方米";var lastPoint=pathArr[pathArr.length-1];var text=new AMap.Text({text:areaHTML,position:lastPoint});this.overlays.measureArea.push(text);this._map.add(text);this.overlays.measureArea.push(this.MeasureAreaTemp["obj"]);this.emit("draw",{obj:this.MeasureAreaTemp.obj});this.MeasureAreaTemp=null}else{if(this.MeasureAreaTemp){this._map.remove(this.MeasureAreaTemp.obj)}this.MeasureAreaTemp=null}this.emit("cancel",{obj:this.MeasureAreaTemp&&this.MeasureAreaTemp.obj||false});this._map.off("mousemove",this._drawMeasureArea,this)};MouseTool.prototype._addPolygonPoint=function(opts,e){this.mapDoubleClickZoom=this._map["getStatus"]()["doubleClickZoom"];this._map["setStatus"]({doubleClickZoom:false});if(this.overlayBubble){var curOverlays=this._map.getAllOverlays();if(curOverlays&&curOverlays.length>0){for(var _i=0,curOverlays_1=curOverlays;_i<curOverlays_1.length;_i++){var item=curOverlays_1[_i];if(item.className==="Overlay.Polygon"||item.className==="Overlay.Circle"||item.className==="Overlay.Rectangle"){var IsRange=item.contains(e.lnglat);if(IsRange){return}}}}}if(!this.polygonTemp){var options={path:[e["lnglat"],e["lnglat"]],strokeColor:"#1791fc",fillColor:"#1791fc",strokeOpacity:.8,fillOpacity:.35,strokeWeight:2,strokeStyle:"solid",strokeDasharray:[10,5],zIndex:10,extData:{}};this.polygonTemp={path:[]};var polylineOpts=assign(options,opts);this.polygonTemp["path"].push(e.lnglat);this.polygonTemp.obj=new AMap.Polygon(polylineOpts);this._map.add(this.polygonTemp.obj);this._map.on("mousemove",this._drawGon,this)}else{var newPoint=[e["lnglat"].lng,e["lnglat"].lat];var pathArr=this.polygonTemp.obj["getPath"]();pathArr.push(newPoint);this.polygonTemp.obj["setPath"](pathArr)}this.overlays.polygon.push(this.polygonTemp.obj)};MouseTool.prototype._drawGon=function(e){if(this.polygonTemp&&this.polygonTemp.obj){var newPoint=[e["lnglat"].lng,e["lnglat"].lat];var pathArr=this.polygonTemp.obj["getPath"]();pathArr.pop();pathArr.push(newPoint);this.polygonTemp.obj["setPath"](pathArr)}};MouseTool.prototype._delPolygonPoint=function(){if(this.polygonTemp&&this.polygonTemp.obj){var pathArr=this.polygonTemp.obj["getPath"]();this.polygonTemp.obj["setPath"](pathArr)}this._endPolygon()};MouseTool.prototype._endPolygon=function(){if(this.polygonTemp&&this.polygonTemp.obj){var pathArr=this.polygonTemp.obj["getPath"]();pathArr.pop();this.polygonTemp.obj["setPath"](pathArr);this.emit("draw",{obj:this.polygonTemp.obj})}this.polygonTemp=null;this._map["setStatus"]({doubleClickZoom:this.mapDoubleClickZoom});this._map.off("mousemove",this._drawGon,this)};MouseTool.prototype._addPolylinePoint=function(opts,e){this.mapDoubleClickZoom=this._map["getStatus"]()["doubleClickZoom"];this._map["setStatus"]({doubleClickZoom:false});if(this.overlayBubble){var curOverlays=this._map.getAllOverlays();if(curOverlays&&curOverlays.length>0){for(var _i=0,curOverlays_2=curOverlays;_i<curOverlays_2.length;_i++){var item=curOverlays_2[_i];if(item.className==="Overlay.Polygon"||item.className==="Overlay.Circle"||item.className==="Overlay.Rectangle"){var IsRange=item.contains(e.lnglat);if(IsRange){return}}}}}if(!this.polylineTemp){var options={path:[e["lnglat"],e["lnglat"]],strokeColor:"#1791fc",strokeOpacity:.8,strokeWeight:2,strokeStyle:"solid",strokeDasharray:[10,5],zIndex:10,extData:{},bubble:true};var polylineOpts=assign(options,opts);this.polylineTemp={path:[]};this.polylineTemp["path"].push(e.lnglat);this.polylineTemp.obj=new AMap.Polyline(polylineOpts);this._map.add(this.polylineTemp.obj);this._map.on("mousemove",this._drawLine,this)}else{var newPoint=[e["lnglat"].lng,e["lnglat"].lat];var pathArr=this.polylineTemp.obj["getPath"]();pathArr.push(newPoint);this.polylineTemp.obj["setPath"](pathArr)}this.overlays.polyline.push(this.polylineTemp.obj)};MouseTool.prototype._drawLine=function(e){if(this.polylineTemp&&this.polylineTemp.obj){var newPoint=[e["lnglat"].lng,e["lnglat"].lat];var pathArr=this.polylineTemp.obj["getPath"]();pathArr.pop();pathArr.push(newPoint);this.polylineTemp.obj["setPath"](pathArr)}};MouseTool.prototype._endPolylineLine=function(type){var pathArr=this.polylineTemp.obj["getPath"]();if(type&&type==="db"){pathArr.pop()}this.polylineTemp.obj["setPath"](pathArr);this.emit("draw",{obj:this.polylineTemp.obj});this.polylineTemp=null;this._map["setStatus"]({doubleClickZoom:this.mapDoubleClickZoom});this._map.off("mousemove",this._drawLine,this)};MouseTool.prototype._delPolylineLinePoint=function(){var pathArr=this.polylineTemp.obj["getPath"]();pathArr.pop();this.polylineTemp.obj["setPath"](pathArr);this._endPolylineLine()};MouseTool.prototype._renderMarker=function(opts,e){var markerOpts=assign({position:e.lnglat},opts);var marker=new AMap.Marker(markerOpts);this.overlays.marker.push(marker);if(this.overlayBubble){var curOverlays=this._map.getAllOverlays();if(curOverlays&&curOverlays.length>0){for(var _i=0,curOverlays_3=curOverlays;_i<curOverlays_3.length;_i++){var item=curOverlays_3[_i];if(item.className==="Overlay.Polygon"||item.className==="Overlay.Circle"||item.className==="Overlay.Rectangle"){var IsRange=item.contains(e.lnglat);if(IsRange){return}}}}}this._map.add(marker);this.emit("draw",{obj:marker})};MouseTool.prototype._createCircle=function(opts,e){if(this.overlayData){return null}if(this.overlayBubble){var curOverlays=this._map.getAllOverlays();if(curOverlays&&curOverlays.length>0){for(var _i=0,curOverlays_4=curOverlays;_i<curOverlays_4.length;_i++){var item=curOverlays_4[_i];if(item.className==="Overlay.Polygon"||item.className==="Overlay.Circle"||item.className==="Overlay.Rectangle"){var IsRange=item.contains(e.lnglat);if(IsRange){return}}}}}this._map.on("mousemove",this._updateCircle,this);var options={center:e.lnglat,strokeColor:"#1791fc",strokeOpacity:.8,strokeWeight:2,fillColor:"#1791fc",fillOpacity:.35,strokeStyle:"solid",strokeDasharray:[10,5],zIndex:10,bubble:true,radius:0};var circleOpts=assign(options,opts);this.mapDragEnable=this._map["getStatus"]()["dragEnable"];this._map["setStatus"]({dragEnable:false});var newCircle=new AMap.Circle(circleOpts);this._map.add(newCircle);this.overlayData={obj:newCircle,center:e}};MouseTool.prototype._doneCircle=function(){if(!this.overlayData){return}this.overlays.circle.push(this.overlayData.obj);this.emit("draw",{obj:this.overlayData.obj});this.overlayData=null;this._map.off("mousemove",this._updateCircle,this);this._map["setStatus"]({dragEnable:this.mapDragEnable})};MouseTool.prototype._updateCircle=function(e){if(this.overlayData){var optRadius=AMap.GeometryUtil.distance(this.overlayData.center.lnglat,e.lnglat).toFixed(3);this.overlayData.obj.setRadius(optRadius);this.emit("drawing",{obj:this.overlayData.obj})}};MouseTool.prototype._createRectangle=function(opts,e){if(this.overlayData){return null}if(this.overlayBubble){var curOverlays=this._map.getAllOverlays();if(curOverlays&&curOverlays.length>0){for(var _i=0,curOverlays_5=curOverlays;_i<curOverlays_5.length;_i++){var item=curOverlays_5[_i];if(item.className==="Overlay.Polygon"||item.className==="Overlay.Circle"||item.className==="Overlay.Rectangle"){var IsRange=item.contains(e.lnglat);if(IsRange){return}}}}}this._map.on("mousemove",this._updateRectangle,this);var options={bounds:new AMap.Bounds(e.lnglat,e.lnglat),strokeColor:"#1791fc",strokeOpacity:.8,strokeWeight:2,fillColor:"#1791fc",fillOpacity:.35,strokeStyle:"solid",strokeDasharray:[10,5],zIndex:10,bubble:true};var rectangleOpts=assign(options,opts);var newRectangle=new AMap.Rectangle(rectangleOpts);this.mapDragEnable=this._map["getStatus"]()["dragEnable"];this._map["setStatus"]({dragEnable:false});this._map.add(newRectangle);this.overlayData={obj:newRectangle,center:e}};MouseTool.prototype._doneRectangle=function(){if(!this.overlayData){return}this.overlays.rectangle.push(this.overlayData.obj);this._map["setStatus"]({dragEnable:this.mapDragEnable});this.emit("draw",{obj:this.overlayData.obj});this.overlayData=null;this._map.off("mousemove",this._updateRectangle,this)};MouseTool.prototype._updateRectangle=function(e){if(this.overlayData){var optBounds=new AMap.Bounds(this.overlayData.center.lnglat,e.lnglat);this.overlayData.obj.setBounds(optBounds);this.emit("drawing",{obj:this.overlayData.obj})}};MouseTool.prototype._doneZoomIn=function(){this._map.setFitView([this.overlayData.obj]);this._map.remove(this.overlayData.obj);this.overlayData=null;this._map.off("mousemove",this._updateCircle,this)};MouseTool.prototype._doneZoomOut=function(){var center=this.overlayData.obj.getCenter();var zoom=this._map.getZoom();this._map.setZoomAndCenter(zoom-1,[center.lng,center.lat]);this._map.remove(this.overlayData.obj);this.overlayData=null;this._map.off("mousemove",this._updateCircle,this)};MouseTool.prototype._onStart=function(){this._map["setStatus"]({allBubble:true});if(this.ruler){this.ruler.turnOff()}this._unbind()};MouseTool.prototype._onEnd=function(ifClear){this._unbind();this.polylineTemp=null;this.polygonTemp=null;if(this.MeasureAreaTemp){if(ifClear&&this.MeasureAreaTemp.obj){this._map.remove(this.MeasureAreaTemp.obj)}this._map.off("mousemove",this._drawMeasureArea,this);this.MeasureAreaTemp=null}if(this.ruler){this.ruler.turnOff(ifClear)}this._map["setStatus"]({allBubble:false})};return MouseTool}(AMap.Event);AMap["MouseTool"]=MouseTool})(); ');_cssload_('AMap.CircleEditor', '.amap-circle-node{cursor:pointer;width:15px;height:15px}.amap-circle-node.amap-circle-moveNode{cursor:move}.amap-circle-node.amap-circle-moveNode,.amap-circle-node.amap-circle-resizeNode{background:url(https://a.amap.com/jsapi/static/image/plugin/editor/circle-pie.png) 50% 50% no-repeat}.amap-circle-node.amap-circle-mobile{background-color:rgba(23,145,252,.2);border-radius:15px;width:25px;height:25px}.amap-circle-node+.amap-marker-label{border-color:#1791fc;border-radius:2px}');_jsload_('AMap.CircleEditor', '!function(AMap){"use strict";function _typeof(obj){"@babel/helpers - typeof";if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"){_typeof=function(obj){return typeof obj}}else{_typeof=function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj}}return _typeof(obj)}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}}function _defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor)}}function _createClass(Constructor,protoProps,staticProps){if(protoProps)_defineProperties(Constructor.prototype,protoProps);if(staticProps)_defineProperties(Constructor,staticProps);return Constructor}function _inherits(subClass,superClass){if(typeof superClass!=="function"&&superClass!==null){throw new TypeError("Super expression must either be null or a function")}subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,writable:true,configurable:true}});if(superClass)_setPrototypeOf(subClass,superClass)}function _getPrototypeOf(o){_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf:function _getPrototypeOf(o){return o.__proto__||Object.getPrototypeOf(o)};return _getPrototypeOf(o)}function _setPrototypeOf(o,p){_setPrototypeOf=Object.setPrototypeOf||function _setPrototypeOf(o,p){o.__proto__=p;return o};return _setPrototypeOf(o,p)}function _isNativeReflectConstruct(){if(typeof Reflect==="undefined"||!Reflect.construct)return false;if(Reflect.construct.sham)return false;if(typeof Proxy==="function")return true;try{Date.prototype.toString.call(Reflect.construct(Date,[],function(){}));return true}catch(e){return false}}function _assertThisInitialized(self){if(self===void 0){throw new ReferenceError("this hasn\'t been initialised - super() hasn\'t been called")}return self}function _possibleConstructorReturn(self,call){if(call&&(typeof call==="object"||typeof call==="function")){return call}return _assertThisInitialized(self)}function _createSuper(Derived){var hasNativeReflectConstruct=_isNativeReflectConstruct();return function _createSuperInternal(){var Super=_getPrototypeOf(Derived),result;if(hasNativeReflectConstruct){var NewTarget=_getPrototypeOf(this).constructor;result=Reflect.construct(Super,arguments,NewTarget)}else{result=Super.apply(this,arguments)}return _possibleConstructorReturn(this,result)}}var ListEvent;(function(ListEvent){ListEvent["removeNode"]="removenode";ListEvent["addNode"]="addnode";ListEvent["adjust"]="adjust";ListEvent["end"]="end";ListEvent["change"]="change";ListEvent["move"]="move";ListEvent["add"]="add"})(ListEvent||(ListEvent={}));var PointList=function(_AMap$Event){_inherits(PointList,_AMap$Event);var _super=_createSuper(PointList);function PointList(){var _this;_classCallCheck(this,PointList);_this=_super.apply(this,arguments);_this.length=0;return _this}_createClass(PointList,[{key:"add",value:function add(node){if(!this.head){this.head=node}else{var lastNode=this.head;while(lastNode.next){lastNode=lastNode.next}lastNode.setNext(node);node.setPrev(lastNode)}node.setList(this);this.bindNodeEvent(node);this.length+=1}},{key:"insertBefore",value:function insertBefore(node,origin){origin.prev.setNext(node);node.setPrev(origin.prev);node.setNext(origin);origin.setPrev(node);node.setList(this);this.bindNodeEvent(node);this.length+=1}},{key:"insertAfter",value:function insertAfter(node,origin){origin.next.setPrev(node);node.setNext(origin.next);node.setPrev(origin);origin.setNext(node);node.setList(this);this.bindNodeEvent(node);this.length+=1}},{key:"bindNodeEvent",value:function bindNodeEvent(node){node.on(ListEvent.change,this.handleChange.bind(this));node.on(ListEvent.addNode,this.handleAddNode.bind(this));node.on(ListEvent.adjust,this.handleAdjust.bind(this));node.on(ListEvent.removeNode,this.handleRemoveNode.bind(this))}},{key:"unbindNodeEvent",value:function unbindNodeEvent(node){node.off(ListEvent.change,this.handleChange.bind(this));node.off(ListEvent.addNode,this.handleAddNode.bind(this));node.off(ListEvent.adjust,this.handleAdjust.bind(this));node.off(ListEvent.removeNode,this.handleRemoveNode.bind(this))}},{key:"remove",value:function remove(node){this.unbindNodeEvent(node);if(node.prev){node.prev.setNext(node.next);if(node.next){node.next.setPrev(node.prev)}node.setPrev();node.setNext()}else{this.head=node.next;node.setPrev();if(node.next){node.next.setPrev()}}this.length-=1}},{key:"handleChange",value:function handleChange(e){this.emit(ListEvent.change,e)}},{key:"handleAddNode",value:function handleAddNode(e){this.emit(ListEvent.addNode,e)}},{key:"handleRemoveNode",value:function handleRemoveNode(e){this.emit(ListEvent.removeNode,e)}},{key:"handleAdjust",value:function handleAdjust(e){this.emit(ListEvent.adjust,e)}},{key:"forEach",value:function forEach(cb){var p=this.head;while(p){cb(p);p=p.next}}},{key:"destroy",value:function destroy(){var p=this.head;while(p){this.remove(p);p.destroy();p=p.next}}}]);return PointList}(AMap.Event);var AbstractPointListNode=function(_AMap$Event2){_inherits(AbstractPointListNode,_AMap$Event2);var _super2=_createSuper(AbstractPointListNode);function AbstractPointListNode(){var _this2;_classCallCheck(this,AbstractPointListNode);_this2=_super2.apply(this,arguments);_this2.editing=false;return _this2}_createClass(AbstractPointListNode,[{key:"setNext",value:function setNext(next){this.next=next}},{key:"setPrev",value:function setPrev(prev){this.prev=prev}},{key:"setList",value:function setList(list){this.list=list}}]);return AbstractPointListNode}(AMap.Event);var Point=function(_AMap$Event){_inherits(Point,_AMap$Event);var _super=_createSuper(Point);function Point(map,pos){var _this;var opts=arguments.length>2&&arguments[2]!==undefined?arguments[2]:{};_classCallCheck(this,Point);_this=_super.call(this);_this.map=map;_this.pos=pos;_this._markerOptions={draggable:true,radius:AMap.Browser.mobile?6:6,strokeColor:"#1791fc",strokeWeight:AMap.Browser.mobile?6:2,strokeOpacity:AMap.Browser.mobile?.4:1,fillColor:"white",fillOpacity:1,cursor:"pointer",visible:false,zIndex:99999,innerOverlay:true};_this._middleMarkerOptions={draggable:true,radius:6,strokeColor:"white",strokeWeight:AMap.Browser.mobile?6:2,strokeOpacity:AMap.Browser.mobile?.6:1,fillColor:"#1791fc",fillOpacity:1,cursor:"pointer",visible:false,zIndex:99999};if(opts.controlPoint){_this._markerOptions=AMap.extend(_this._markerOptions,opts.controlPoint)}if(opts.controlPoint){_this._middleMarkerOptions=AMap.extend(_this._middleMarkerOptions,opts.midControlPoint)}_this.init();_this.hide();return _this}_createClass(Point,[{key:"init",value:function init(){this.marker=new AMap.CircleMarker(AMap.extend({map:this.map,center:this.pos},this._markerOptions))}},{key:"show",value:function show(){this.marker.show()}},{key:"hide",value:function hide(){this.marker.hide()}},{key:"remove",value:function remove(){this.marker.remove()}},{key:"setMiddle",value:function setMiddle(middle){this.marker.setOptions(middle?this._middleMarkerOptions:this._markerOptions)}}]);return Point}(AMap.Event);var PointWithMarker=function(_AMap$Event2){_inherits(PointWithMarker,_AMap$Event2);var _super2=_createSuper(PointWithMarker);function PointWithMarker(map,pos){var _this2;var controlPoint=arguments.length>2&&arguments[2]!==undefined?arguments[2]:{draggable:true,icon:new AMap.Icon({size:new AMap.Size(11,11),imageOffset:new AMap.Pixel(0,0),image:AMap.getConfig().client+"/images/dd-via.png"}),offset:new AMap.Pixel(-6,-6),cursor:"pointer",zIndex:1e3};_classCallCheck(this,PointWithMarker);_this2=_super2.call(this);_this2.map=map;_this2.pos=pos;_this2.controlPoint=controlPoint;_this2.init();_this2.hide();return _this2}_createClass(PointWithMarker,[{key:"init",value:function init(){this.marker=new AMap.Marker(AMap.extend({map:this.map,position:this.pos,draggable:true,cursor:"pointer",zIndex:1e3,innerOverlay:true},this.controlPoint))}},{key:"show",value:function show(){this.marker.show()}},{key:"hide",value:function hide(){this.marker.hide()}},{key:"remove",value:function remove(){this.marker.remove()}}]);return PointWithMarker}(AMap.Event);var CirlePoint=function(_AMap$Event){_inherits(CirlePoint,_AMap$Event);var _super=_createSuper(CirlePoint);function CirlePoint(map,circle){var _this;var opts=arguments.length>2&&arguments[2]!==undefined?arguments[2]:{};_classCallCheck(this,CirlePoint);_this=_super.call(this);_this.map=map;_this.circle=circle;var center=circle.getCenter();var radius=circle.getRadius();var isMobile=AMap.Browser.mobile;_this.movePoint=new PointWithMarker(map,center.toJSON(),opts.movePoint||{content:\'<div class="\'+(isMobile?"amap-circle-mobile ":"")+"amap-circle-node amap-circle-"+"moveNode"+\'"></div>\',offset:isMobile?new AMap.Pixel(-13,-13):new AMap.Pixel(-8,-8)});var movePos=center.offset(radius,0);_this.resizePoint=new PointWithMarker(map,movePos,opts.resizePoint||{content:\'<div class="\'+(isMobile?"amap-circle-mobile ":"")+"amap-circle-node amap-circle-"+"resizeNode"+\'"></div>\',offset:isMobile?new AMap.Pixel(-13,-13):new AMap.Pixel(-8,-8)});_this.bindEvent();return _this}_createClass(CirlePoint,[{key:"bindEvent",value:function bindEvent(){this.movePoint.marker.on("dragging",this._handleMovePointDragging.bind(this));this.resizePoint.marker.on("dragging",this._handleResizePointDragging.bind(this));this.movePoint.marker.on("dragend",this._handleMovePointDragend.bind(this));this.resizePoint.marker.on("dragend",this._handleResizePointDragend.bind(this))}},{key:"unbindEvent",value:function unbindEvent(){this.movePoint.marker.off("dragging",this._handleMovePointDragging.bind(this));this.resizePoint.marker.off("dragging",this._handleResizePointDragging.bind(this));this.movePoint.marker.off("dragend",this._handleMovePointDragend.bind(this));this.resizePoint.marker.off("dragend",this._handleResizePointDragend.bind(this))}},{key:"show",value:function show(){this.movePoint.show();this.resizePoint.show();this._updateText();this._updateText()}},{key:"hide",value:function hide(){this.movePoint.hide();this.resizePoint.hide()}},{key:"destroy",value:function destroy(){this.unbindEvent();this.movePoint.remove();this.resizePoint.remove()}},{key:"getBounds",value:function getBounds(){return new AMap.Bounds(this.movePoint.marker.getPosition(),this.resizePoint.marker.getPosition())}},{key:"_updateText",value:function _updateText(){var radius=this.circle.getRadius();this.resizePoint.marker.setLabel({content:"半径:".concat(radius,"米")})}},{key:"_handleMovePointDragging",value:function _handleMovePointDragging(){var pos=this.movePoint.marker.getPosition();var resizePos=this.resizePoint.marker.getPosition();var circleCenter=this.circle.getCenter();if(!pos||!resizePos){return}var newPos=pos.add(resizePos.subtract(circleCenter,false),false);this.resizePoint.marker.setPosition(newPos.toJSON());this.circle.setCenter(pos);this._updateText();this.emit(ListEvent.change)}},{key:"_handleResizePointDragging",value:function _handleResizePointDragging(){var moveLatLng=this.circle["getCenter"]();var resizeLatlng=this.resizePoint.marker.getPosition();var radius=Math.round(AMap.GeometryUtil.distance(moveLatLng,resizeLatlng));this.circle.setRadius(radius);this._updateText();this.emit(ListEvent.change)}},{key:"_handleResizePointDragend",value:function _handleResizePointDragend(event){var radius=this.circle.getRadius();this.emit(ListEvent.adjust,{radius:radius,lnglat:event.lnglat,pixel:event.pixel})}},{key:"_handleMovePointDragend",value:function _handleMovePointDragend(event){this.emit(ListEvent.move,event)}}]);return CirlePoint}(AMap.Event);function _typeof$1(obj){if(typeof Symbol==="function"&&_typeof(Symbol.iterator)==="symbol"){_typeof$1=function _typeof$1(obj){return _typeof(obj)}}else{_typeof$1=function _typeof$1(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":_typeof(obj)}}return _typeof$1(obj)}function boundMethod(target,key,descriptor){var fn=descriptor.value;if(typeof fn!=="function"){throw new TypeError("@boundMethod decorator can only be applied to methods not: ".concat(_typeof$1(fn)))}var definingProperty=false;return{configurable:true,get:function get(){if(definingProperty||this===target.prototype||this.hasOwnProperty(key)||typeof fn!=="function"){return fn}var boundFn=fn.bind(this);definingProperty=true;Object.defineProperty(this,key,{configurable:true,get:function get(){return boundFn},set:function set(value){fn=value;delete this[key]}});definingProperty=false;return boundFn},set:function set(value){fn=value}}}function boundClass(target){var keys;if(typeof Reflect!=="undefined"&&typeof Reflect.ownKeys==="function"){keys=Reflect.ownKeys(target.prototype)}else{keys=Object.getOwnPropertyNames(target.prototype);if(typeof Object.getOwnPropertySymbols==="function"){keys=keys.concat(Object.getOwnPropertySymbols(target.prototype))}}keys.forEach(function(key){if(key==="constructor"){return}var descriptor=Object.getOwnPropertyDescriptor(target.prototype,key);if(typeof descriptor.value==="function"){Object.defineProperty(target.prototype,key,boundMethod(target,key,descriptor))}});return target}function autobind(){if(arguments.length===1){return boundClass.apply(void 0,arguments)}return boundMethod.apply(void 0,arguments)}var __decorate=undefined&&undefined.__decorate||function(decorators,target,key,desc){var c=arguments.length,r=c<3?target:desc===null?desc=Object.getOwnPropertyDescriptor(target,key):desc,d;if((typeof Reflect==="undefined"?"undefined":_typeof(Reflect))==="object"&&typeof Reflect.decorate==="function")r=Reflect.decorate(decorators,target,key,desc);else for(var i=decorators.length-1;i>=0;i--){if(d=decorators[i])r=(c<3?d(r):c>3?d(target,key,r):d(target,key))||r}return c>3&&r&&Object.defineProperty(target,key,r),r};var BaseEditor=function(_AMap$Event){_inherits(BaseEditor,_AMap$Event);var _super=_createSuper(BaseEditor);function BaseEditor(_map,_poly){var _this;_classCallCheck(this,BaseEditor);_this=_super.call(this);_this._map=_map;_this.className="AMap.BaseEditor";_this._editing=false;_this._poly=_poly;return _this}_createClass(BaseEditor,[{key:"setTarget",value:function setTarget(overlay){this.close();if(this._poly&&this._poly!==overlay){this.destroy()}if(overlay){this._poly=overlay}}},{key:"getTarget",value:function getTarget(){return this._poly}},{key:"bindListEvent",value:function bindListEvent(){if(this.list){this.list.on(ListEvent.addNode,this.handleAddNode);this.list.on(ListEvent.adjust,this.handleAdjust);this.list.on(ListEvent.change,this.handleChange);this.list.on(ListEvent.move,this.handleMove)}}},{key:"unbindListEvent",value:function unbindListEvent(){if(this.list){this.list.off(ListEvent.addNode,this.handleAddNode);this.list.off(ListEvent.adjust,this.handleAdjust);this.list.off(ListEvent.change,this.handleChange);this.list.off(ListEvent.move,this.handleMove)}}},{key:"handleChange",value:function handleChange(){}},{key:"handleMove",value:function handleMove(event){this.emit(ListEvent.move,{target:this.getTarget(),lnglat:event.lnglat,pixel:event.pixel})}},{key:"handleAddNode",value:function handleAddNode(event){this.emit(ListEvent.addNode,event)}},{key:"handleRemoveNode",value:function handleRemoveNode(){}},{key:"handleAdjust",value:function handleAdjust(event){this.emit(ListEvent.adjust,AMap.extend({},event,{target:this.getTarget()}))}},{key:"open",value:function open(){if(this._poly&&!this._editing){this._editing=true;this.initList();this._openEdit()}else{this._creator.open()}if(!this._poly||!this.list){return}}},{key:"_openEdit",value:function _openEdit(){if(!this.list||!this._poly){return}this.list.show();this._saveCustomStyle();this._poly.setOptions(this._editStyle?this._editStyle:{})}},{key:"_saveCustomStyle",value:function _saveCustomStyle(){if(!this._poly){return}this._customStyle=AMap.extend({},this._poly.getOptions());delete this._customStyle.map;delete this._customStyle.center;delete this._customStyle.radius;delete this._customStyle.path;delete this._customStyle.bounds}},{key:"close",value:function close(){this._editing=false;if(!this._poly){return}if(!this.list){return}this.list.hide();this._poly.setOptions(this._customStyle);this.emit(ListEvent.end,{target:this.getTarget()})}},{key:"destroy",value:function destroy(){if(this.list){this.unbindListEvent();this.list.destroy();delete this.list}delete this._poly}},{key:"CLASS_NAME",get:function get(){return this.className}}]);return BaseEditor}(AMap.Event);__decorate([autobind],BaseEditor.prototype,"handleChange",null);__decorate([autobind],BaseEditor.prototype,"handleMove",null);__decorate([autobind],BaseEditor.prototype,"handleAddNode",null);__decorate([autobind],BaseEditor.prototype,"handleRemoveNode",null);__decorate([autobind],BaseEditor.prototype,"handleAdjust",null);var __decorate$1=undefined&&undefined.__decorate||function(decorators,target,key,desc){var c=arguments.length,r=c<3?target:desc===null?desc=Object.getOwnPropertyDescriptor(target,key):desc,d;if((typeof Reflect==="undefined"?"undefined":_typeof(Reflect))==="object"&&typeof Reflect.decorate==="function")r=Reflect.decorate(decorators,target,key,desc);else for(var i=decorators.length-1;i>=0;i--){if(d=decorators[i])r=(c<3?d(r):c>3?d(target,key,r):d(target,key))||r}return c>3&&r&&Object.defineProperty(target,key,r),r};var CirclrCreator=function(_AMap$Event){_inherits(CirclrCreator,_AMap$Event);var _super=_createSuper(CirclrCreator);function CirclrCreator(_map){var _this;_classCallCheck(this,CirclrCreator);_this=_super.call(this);_this._map=_map;return _this}_createClass(CirclrCreator,[{key:"open",value:function open(){this._map.on("click",this._onMapClick)}},{key:"close",value:function close(){this._map.off("click",this._onMapClick)}},{key:"_onMapClick",value:function _onMapClick(e){var center=e.lnglat.toJSON();var radius=this._map.getResolution()*60;this.emit("create",{center:center,radius:radius});this.close()}}]);return CirclrCreator}(AMap.Event);__decorate$1([autobind],CirclrCreator.prototype,"_onMapClick",null);var CircleEditor=function(_BaseEditor){_inherits(CircleEditor,_BaseEditor);var _super2=_createSuper(CircleEditor);function CircleEditor(map,_poly){var _this2;var opts=arguments.length>2&&arguments[2]!==undefined?arguments[2]:{};_classCallCheck(this,CircleEditor);_this2=_super2.call(this,map,_poly);_this2.className="AMap.CircleEditor";_this2._normalCircleStyle={draggbable:true,strokeColor:"#FF33FF",strokeWeight:3,strokeOpacity:.2,fillOpacity:.4,strokeStyle:"dashed",strokeDasharray:[10,10],fillColor:"#1791fc",zIndex:50};_this2._editStyle={strokeColor:"#1791fc",strokeWeight:3,strokeOpacity:.8,fillOpacity:.4,strokeStyle:"solid",strokeDasharray:[10,10],fillColor:"#1791fc",draggable:false};_this2._opts=opts;_this2._normalCircleStyle=AMap.extend(_this2._normalCircleStyle,opts.createOptions||{});_this2._editStyle=AMap.extend(_this2._editStyle,opts.editOptions||{});_this2._creator=new CirclrCreator(map);_this2._creator.on("create",function(data){_this2._creator.close();var poly=new AMap.Circle(AMap.extend({map:_this2._map,center:data.center,radius:data.radius},_this2._normalCircleStyle));_this2.setTarget(poly);_this2.open();_this2.emit(ListEvent.add,{target:_this2.getTarget(),obj:poly})});return _this2}_createClass(CircleEditor,[{key:"initList",value:function initList(){if(!this._poly){return}if(!this.list){this.list=new CirlePoint(this._map,this._poly,this._opts)}this.bindListEvent()}}]);return CircleEditor}(BaseEditor);AMap.CircleEditor=CircleEditor}(window.AMap); ');_jsload_('AMap.PolygonEditor', '!function(AMap){"use strict";function _iterableToArrayLimit(arr,i){var _i=null==arr?null:"undefined"!=typeof Symbol&&arr[Symbol.iterator]||arr["@@iterator"];if(null!=_i){var _s,_e,_x,_r,_arr=[],_n=!0,_d=!1;try{if(_x=(_i=_i.call(arr)).next,0===i){if(Object(_i)!==_i)return;_n=!1}else for(;!(_n=(_s=_x.call(_i)).done)&&(_arr.push(_s.value),_arr.length!==i);_n=!0);}catch(err){_d=!0,_e=err}finally{try{if(!_n&&null!=_i.return&&(_r=_i.return(),Object(_r)!==_r))return}finally{if(_d)throw _e}}return _arr}}function _typeof(obj){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(obj){return typeof obj}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj},_typeof(obj)}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}}function _defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,_toPropertyKey(descriptor.key),descriptor)}}function _createClass(Constructor,protoProps,staticProps){if(protoProps)_defineProperties(Constructor.prototype,protoProps);if(staticProps)_defineProperties(Constructor,staticProps);Object.defineProperty(Constructor,"prototype",{writable:false});return Constructor}function _inherits(subClass,superClass){if(typeof superClass!=="function"&&superClass!==null){throw new TypeError("Super expression must either be null or a function")}subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,writable:true,configurable:true}});Object.defineProperty(subClass,"prototype",{writable:false});if(superClass)_setPrototypeOf(subClass,superClass)}function _getPrototypeOf(o){_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function _getPrototypeOf(o){return o.__proto__||Object.getPrototypeOf(o)};return _getPrototypeOf(o)}function _setPrototypeOf(o,p){_setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function _setPrototypeOf(o,p){o.__proto__=p;return o};return _setPrototypeOf(o,p)}function _isNativeReflectConstruct(){if(typeof Reflect==="undefined"||!Reflect.construct)return false;if(Reflect.construct.sham)return false;if(typeof Proxy==="function")return true;try{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}));return true}catch(e){return false}}function _assertThisInitialized(self){if(self===void 0){throw new ReferenceError("this hasn\'t been initialised - super() hasn\'t been called")}return self}function _possibleConstructorReturn(self,call){if(call&&(typeof call==="object"||typeof call==="function")){return call}else if(call!==void 0){throw new TypeError("Derived constructors may only return object or undefined")}return _assertThisInitialized(self)}function _createSuper(Derived){var hasNativeReflectConstruct=_isNativeReflectConstruct();return function _createSuperInternal(){var Super=_getPrototypeOf(Derived),result;if(hasNativeReflectConstruct){var NewTarget=_getPrototypeOf(this).constructor;result=Reflect.construct(Super,arguments,NewTarget)}else{result=Super.apply(this,arguments)}return _possibleConstructorReturn(this,result)}}function _slicedToArray(arr,i){return _arrayWithHoles(arr)||_iterableToArrayLimit(arr,i)||_unsupportedIterableToArray(arr,i)||_nonIterableRest()}function _toConsumableArray(arr){return _arrayWithoutHoles(arr)||_iterableToArray(arr)||_unsupportedIterableToArray(arr)||_nonIterableSpread()}function _arrayWithoutHoles(arr){if(Array.isArray(arr))return _arrayLikeToArray(arr)}function _arrayWithHoles(arr){if(Array.isArray(arr))return arr}function _iterableToArray(iter){if(typeof Symbol!=="undefined"&&iter[Symbol.iterator]!=null||iter["@@iterator"]!=null)return Array.from(iter)}function _unsupportedIterableToArray(o,minLen){if(!o)return;if(typeof o==="string")return _arrayLikeToArray(o,minLen);var n=Object.prototype.toString.call(o).slice(8,-1);if(n==="Object"&&o.constructor)n=o.constructor.name;if(n==="Map"||n==="Set")return Array.from(o);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return _arrayLikeToArray(o,minLen)}function _arrayLikeToArray(arr,len){if(len==null||len>arr.length)len=arr.length;for(var i=0,arr2=new Array(len);i<len;i++)arr2[i]=arr[i];return arr2}function _nonIterableSpread(){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 _nonIterableRest(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _createForOfIteratorHelper(o,allowArrayLike){var it=typeof Symbol!=="undefined"&&o[Symbol.iterator]||o["@@iterator"];if(!it){if(Array.isArray(o)||(it=_unsupportedIterableToArray(o))||allowArrayLike&&o&&typeof o.length==="number"){if(it)o=it;var i=0;var F=function(){};return{s:F,n:function(){if(i>=o.length)return{done:true};return{done:false,value:o[i++]}},e:function(e){throw e},f:F}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var normalCompletion=true,didErr=false,err;return{s:function(){it=it.call(o)},n:function(){var step=it.next();normalCompletion=step.done;return step},e:function(e){didErr=true;err=e},f:function(){try{if(!normalCompletion&&it.return!=null)it.return()}finally{if(didErr)throw err}}}}function _toPrimitive(input,hint){if(typeof input!=="object"||input===null)return input;var prim=input[Symbol.toPrimitive];if(prim!==undefined){var res=prim.call(input,hint||"default");if(typeof res!=="object")return res;throw new TypeError("@@toPrimitive must return a primitive value.")}return(hint==="string"?String:Number)(input)}function _toPropertyKey(arg){var key=_toPrimitive(arg,"string");return typeof key==="symbol"?key:String(key)}function getNearestPoint(pt,pts){var nearest=null;pts.forEach(function(p,i){var lngDiff=p[0]-pt[0];var latDiff=p[1]-pt[1];var l=Math.sqrt(Math.pow(lngDiff,2)+Math.pow(latDiff,2));var cur={distance:l,point:p,index:i};if(nearest){if(nearest.distance>l){nearest=cur}}else{nearest=cur}});return nearest}function getPixelDistance(_map,_ref){var _ref2=_slicedToArray(_ref,2),p1=_ref2[0],p2=_ref2[1];var toPixel=function toPixel(p){var lnglat=new AMap.LngLat(p[0],p[1]);return _map.lngLatToContainer(lnglat)};var pixel1=toPixel(p1);var pixel2=toPixel(p2);var xDiff=pixel1.x-pixel2.x;var yDiff=pixel1.y-pixel2.y;var l=Math.sqrt(Math.pow(xDiff,2)+Math.pow(yDiff,2));return l}function e2ll(e){if(e&&e.lnglat){return e.lnglat}return null}function getPolygonOptions(opt){return{path:opt["path"],map:opt["map"],strokeColor:opt["strokeColor"]||"#1791fc",strokeOpacity:opt["strokeOpacity"]||.8,strokeWeight:opt["strokeWeight"]||2,fillColor:opt["fillColor"]||"#1791fc",fillOpacity:opt["fillOpacity"]||.35,strokeStyle:opt["strokeStyle"]||"solid",strokeDasharray:opt["strokeDasharray"]||[10,5],zIndex:opt["zIndex"]||10,extData:opt["extData"]||{},bubble:!!opt["bubble"]}}function createPolygon(path,opt){var _opt=AMap.extend({},getPolygonOptions(opt),{path:path});var p=new AMap.Polygon(_opt);if(_opt["map"]){_opt["map"].add(p)}return p}var earthRadius=6371008.8;var factors={centimeters:earthRadius*100,centimetres:earthRadius*100,degrees:earthRadius/111325,feet:earthRadius*3.28084,inches:earthRadius*39.37,kilometers:earthRadius/1e3,kilometres:earthRadius/1e3,meters:earthRadius,metres:earthRadius,miles:earthRadius/1609.344,millimeters:earthRadius*1e3,millimetres:earthRadius*1e3,nauticalmiles:earthRadius/1852,radians:1,yards:earthRadius*1.0936};var unitsFactors={centimeters:100,centimetres:100,degrees:1/111325,feet:3.28084,inches:39.37,kilometers:1/1e3,kilometres:1/1e3,meters:1,metres:1,miles:1/1609.344,millimeters:1e3,millimetres:1e3,nauticalmiles:1/1852,radians:1/earthRadius,yards:1.0936133};var areaFactors={acres:247105e-9,centimeters:1e4,centimetres:1e4,feet:10.763910417,hectares:1e-4,inches:1550.003100006,kilometers:1e-6,kilometres:1e-6,meters:1,metres:1,miles:386e-9,millimeters:1e6,millimetres:1e6,yards:1.195990046};function feature(geom,properties,options){if(options===void 0){options={}}var feat={type:"Feature"};if(options.id===0||options.id){feat.id=options.id}if(options.bbox){feat.bbox=options.bbox}feat.properties=properties||{};feat.geometry=geom;return feat}function geometry(type,coordinates,_options){switch(type){case"Point":return point(coordinates).geometry;case"LineString":return lineString(coordinates).geometry;case"Polygon":return polygon(coordinates).geometry;case"MultiPoint":return multiPoint(coordinates).geometry;case"MultiLineString":return multiLineString(coordinates).geometry;case"MultiPolygon":return multiPolygon(coordinates).geometry;default:throw new Error(type+" is invalid")}}function point(coordinates,properties,options){if(options===void 0){options={}}if(!coordinates){throw new Error("coordinates is required")}if(!Array.isArray(coordinates)){throw new Error("coordinates must be an Array")}if(coordinates.length<2){throw new Error("coordinates must be at least 2 numbers long")}if(!isNumber(coordinates[0])||!isNumber(coordinates[1])){throw new Error("coordinates must contain numbers")}var geom={type:"Point",coordinates:coordinates};return feature(geom,properties,options)}function points(coordinates,properties,options){if(options===void 0){options={}}return featureCollection(coordinates.map(function(coords){return point(coords,properties)}),options)}function polygon(coordinates,properties,options){if(options===void 0){options={}}for(var _i=0,coordinates_1=coordinates;_i<coordinates_1.length;_i++){var ring=coordinates_1[_i];if(ring.length<4){throw new Error("Each LinearRing of a Polygon must have 4 or more Positions.")}for(var j=0;j<ring[ring.length-1].length;j++){if(ring[ring.length-1][j]!==ring[0][j]){throw new Error("First and last Position are not equivalent.")}}}var geom={type:"Polygon",coordinates:coordinates};return feature(geom,properties,options)}function polygons(coordinates,properties,options){if(options===void 0){options={}}return featureCollection(coordinates.map(function(coords){return polygon(coords,properties)}),options)}function lineString(coordinates,properties,options){if(options===void 0){options={}}if(coordinates.length<2){throw new Error("coordinates must be an array of two or more positions")}var geom={type:"LineString",coordinates:coordinates};return feature(geom,properties,options)}function lineStrings(coordinates,properties,options){if(options===void 0){options={}}return featureCollection(coordinates.map(function(coords){return lineString(coords,properties)}),options)}function featureCollection(features,options){if(options===void 0){options={}}var fc={type:"FeatureCollection"};if(options.id){fc.id=options.id}if(options.bbox){fc.bbox=options.bbox}fc.features=features;return fc}function multiLineString(coordinates,properties,options){if(options===void 0){options={}}var geom={type:"MultiLineString",coordinates:coordinates};return feature(geom,properties,options)}function multiPoint(coordinates,properties,options){if(options===void 0){options={}}var geom={type:"MultiPoint",coordinates:coordinates};return feature(geom,properties,options)}function multiPolygon(coordinates,properties,options){if(options===void 0){options={}}var geom={type:"MultiPolygon",coordinates:coordinates};return feature(geom,properties,options)}function geometryCollection(geometries,properties,options){if(options===void 0){options={}}var geom={type:"GeometryCollection",geometries:geometries};return feature(geom,properties,options)}function round(num,precision){if(precision===void 0){precision=0}if(precision&&!(precision>=0)){throw new Error("precision must be a positive number")}var multiplier=Math.pow(10,precision||0);return Math.round(num*multiplier)/multiplier}function radiansToLength(radians,units){if(units===void 0){units="kilometers"}var factor=factors[units];if(!factor){throw new Error(units+" units is invalid")}return radians*factor}function lengthToRadians(distance,units){if(units===void 0){units="kilometers"}var factor=factors[units];if(!factor){throw new Error(units+" units is invalid")}return distance/factor}function lengthToDegrees(distance,units){return radiansToDegrees(lengthToRadians(distance,units))}function bearingToAzimuth(bearing){var angle=bearing%360;if(angle<0){angle+=360}return angle}function radiansToDegrees(radians){var degrees=radians%(2*Math.PI);return degrees*180/Math.PI}function degreesToRadians(degrees){var radians=degrees%360;return radians*Math.PI/180}function convertLength(length,originalUnit,finalUnit){if(originalUnit===void 0){originalUnit="kilometers"}if(finalUnit===void 0){finalUnit="kilometers"}if(!(length>=0)){throw new Error("length must be a positive number")}return radiansToLength(lengthToRadians(length,originalUnit),finalUnit)}function convertArea(area,originalUnit,finalUnit){if(originalUnit===void 0){originalUnit="meters"}if(finalUnit===void 0){finalUnit="kilometers"}if(!(area>=0)){throw new Error("area must be a positive number")}var startFactor=areaFactors[originalUnit];if(!startFactor){throw new Error("invalid original units")}var finalFactor=areaFactors[finalUnit];if(!finalFactor){throw new Error("invalid final units")}return area/startFactor*finalFactor}function isNumber(num){return!isNaN(num)&&num!==null&&!Array.isArray(num)}function isObject(input){return!!input&&input.constructor===Object}function validateBBox(bbox){if(!bbox){throw new Error("bbox is required")}if(!Array.isArray(bbox)){throw new Error("bbox must be an Array")}if(bbox.length!==4&&bbox.length!==6){throw new Error("bbox must be an Array of 4 or 6 numbers")}bbox.forEach(function(num){if(!isNumber(num)){throw new Error("bbox must only contain numbers")}})}function validateId(id){if(!id){throw new Error("id is required")}if(["string","number"].indexOf(_typeof(id))===-1){throw new Error("id must be a number or a string")}}var es=Object.freeze({__proto__:null,earthRadius:earthRadius,factors:factors,unitsFactors:unitsFactors,areaFactors:areaFactors,feature:feature,geometry:geometry,point:point,points:points,polygon:polygon,polygons:polygons,lineString:lineString,lineStrings:lineStrings,featureCollection:featureCollection,multiLineString:multiLineString,multiPoint:multiPoint,multiPolygon:multiPolygon,geometryCollection:geometryCollection,round:round,radiansToLength:radiansToLength,lengthToRadians:lengthToRadians,lengthToDegrees:lengthToDegrees,bearingToAzimuth:bearingToAzimuth,radiansToDegrees:radiansToDegrees,degreesToRadians:degreesToRadians,convertLength:convertLength,convertArea:convertArea,isNumber:isNumber,isObject:isObject,validateBBox:validateBBox,validateId:validateId});function getCoord(coord){if(!coord){throw new Error("coord is required")}if(!Array.isArray(coord)){if(coord.type==="Feature"&&coord.geometry!==null&&coord.geometry.type==="Point"){return coord.geometry.coordinates}if(coord.type==="Point"){return coord.coordinates}}if(Array.isArray(coord)&&coord.length>=2&&!Array.isArray(coord[0])&&!Array.isArray(coord[1])){return coord}throw new Error("coord must be GeoJSON Point or an Array of numbers")}function getCoords(coords){if(Array.isArray(coords)){return coords}if(coords.type==="Feature"){if(coords.geometry!==null){return coords.geometry.coordinates}}else{if(coords.coordinates){return coords.coordinates}}throw new Error("coords must be GeoJSON Feature, Geometry Object or an Array")}function bearing(start,end,options){if(options===void 0){options={}}if(options.final===true){return calculateFinalBearing(start,end)}var coordinates1=getCoord(start);var coordinates2=getCoord(end);var lon1=degreesToRadians(coordinates1[0]);var lon2=degreesToRadians(coordinates2[0]);var lat1=degreesToRadians(coordinates1[1]);var lat2=degreesToRadians(coordinates2[1]);var a=Math.sin(lon2-lon1)*Math.cos(lat2);var b=Math.cos(lat1)*Math.sin(lat2)-Math.sin(lat1)*Math.cos(lat2)*Math.cos(lon2-lon1);return radiansToDegrees(Math.atan2(a,b))}function calculateFinalBearing(start,end){var bear=bearing(end,start);bear=(bear+180)%360;return bear}function distance(from,to,options){if(options===void 0){options={}}var coordinates1=getCoord(from);var coordinates2=getCoord(to);var dLat=degreesToRadians(coordinates2[1]-coordinates1[1]);var dLon=degreesToRadians(coordinates2[0]-coordinates1[0]);var lat1=degreesToRadians(coordinates1[1]);var lat2=degreesToRadians(coordinates2[1]);var a=Math.pow(Math.sin(dLat/2),2)+Math.pow(Math.sin(dLon/2),2)*Math.cos(lat1)*Math.cos(lat2);return radiansToLength(2*Math.atan2(Math.sqrt(a),Math.sqrt(1-a)),options.units)}function destination(origin,distance,bearing,options){if(options===void 0){options={}}var coordinates1=getCoord(origin);var longitude1=degreesToRadians(coordinates1[0]);var latitude1=degreesToRadians(coordinates1[1]);var bearingRad=degreesToRadians(bearing);var radians=lengthToRadians(distance,options.units);var latitude2=Math.asin(Math.sin(latitude1)*Math.cos(radians)+Math.cos(latitude1)*Math.sin(radians)*Math.cos(bearingRad));var longitude2=longitude1+Math.atan2(Math.sin(bearingRad)*Math.sin(radians)*Math.cos(latitude1),Math.cos(radians)-Math.sin(latitude1)*Math.sin(latitude2));var lng=radiansToDegrees(longitude2);var lat=radiansToDegrees(latitude2);return point([lng,lat],options.properties)}function coordEach(geojson,callback,excludeWrapCoord){if(geojson===null)return;var j,k,l,geometry,stopG,coords,geometryMaybeCollection,wrapShrink=0,coordIndex=0,isGeometryCollection,type=geojson.type,isFeatureCollection=type==="FeatureCollection",isFeature=type==="Feature",stop=isFeatureCollection?geojson.features.length:1;for(var featureIndex=0;featureIndex<stop;featureIndex++){geometryMaybeCollection=isFeatureCollection?geojson.features[featureIndex].geometry:isFeature?geojson.geometry:geojson;isGeometryCollection=geometryMaybeCollection?geometryMaybeCollection.type==="GeometryCollection":false;stopG=isGeometryCollection?geometryMaybeCollection.geometries.length:1;for(var geomIndex=0;geomIndex<stopG;geomIndex++){var multiFeatureIndex=0;var geometryIndex=0;geometry=isGeometryCollection?geometryMaybeCollection.geometries[geomIndex]:geometryMaybeCollection;if(geometry===null)continue;coords=geometry.coordinates;var geomType=geometry.type;wrapShrink=excludeWrapCoord&&(geomType==="Polygon"||geomType==="MultiPolygon")?1:0;switch(geomType){case null:break;case"Point":if(callback(coords,coordIndex,featureIndex,multiFeatureIndex,geometryIndex)===false)return false;coordIndex++;multiFeatureIndex++;break;case"LineString":case"MultiPoint":for(j=0;j<coords.length;j++){if(callback(coords[j],coordIndex,featureIndex,multiFeatureIndex,geometryIndex)===false)return false;coordIndex++;if(geomType==="MultiPoint")multiFeatureIndex++}if(geomType==="LineString")multiFeatureIndex++;break;case"Polygon":case"MultiLineString":for(j=0;j<coords.length;j++){for(k=0;k<coords[j].length-wrapShrink;k++){if(callback(coords[j][k],coordIndex,featureIndex,multiFeatureIndex,geometryIndex)===false)return false;coordIndex++}if(geomType==="MultiLineString")multiFeatureIndex++;if(geomType==="Polygon")geometryIndex++}if(geomType==="Polygon")multiFeatureIndex++;break;case"MultiPolygon":for(j=0;j<coords.length;j++){geometryIndex=0;for(k=0;k<coords[j].length;k++){for(l=0;l<coords[j][k].length-wrapShrink;l++){if(callback(coords[j][k][l],coordIndex,featureIndex,multiFeatureIndex,geometryIndex)===false)return false;coordIndex++}geometryIndex++}multiFeatureIndex++}break;case"GeometryCollection":for(j=0;j<geometry.geometries.length;j++)if(coordEach(geometry.geometries[j],callback,excludeWrapCoord)===false)return false;break;default:throw new Error("Unknown Geometry Type")}}}}function coordReduce(geojson,callback,initialValue,excludeWrapCoord){var previousValue=initialValue;coordEach(geojson,function(currentCoord,coordIndex,featureIndex,multiFeatureIndex,geometryIndex){if(coordIndex===0&&initialValue===undefined)previousValue=currentCoord;else previousValue=callback(previousValue,currentCoord,coordIndex,featureIndex,multiFeatureIndex,geometryIndex)},excludeWrapCoord);return previousValue}function propEach(geojson,callback){var i;switch(geojson.type){case"FeatureCollection":for(i=0;i<geojson.features.length;i++){if(callback(geojson.features[i].properties,i)===false)break}break;case"Feature":callback(geojson.properties,0);break}}function propReduce(geojson,callback,initialValue){var previousValue=initialValue;propEach(geojson,function(currentProperties,featureIndex){if(featureIndex===0&&initialValue===undefined)previousValue=currentProperties;else previousValue=callback(previousValue,currentProperties,featureIndex)});return previousValue}function featureEach(geojson,callback){if(geojson.type==="Feature"){callback(geojson,0)}else if(geojson.type==="FeatureCollection"){for(var i=0;i<geojson.features.length;i++){if(callback(geojson.features[i],i)===false)break}}}function featureReduce(geojson,callback,initialValue){var previousValue=initialValue;featureEach(geojson,function(currentFeature,featureIndex){if(featureIndex===0&&initialValue===undefined)previousValue=currentFeature;else previousValue=callback(previousValue,currentFeature,featureIndex)});return previousValue}function coordAll(geojson){var coords=[];coordEach(geojson,function(coord){coords.push(coord)});return coords}function geomEach(geojson,callback){var i,j,g,geometry,stopG,geometryMaybeCollection,isGeometryCollection,featureProperties,featureBBox,featureId,featureIndex=0,isFeatureCollection=geojson.type==="FeatureCollection",isFeature=geojson.type==="Feature",stop=isFeatureCollection?geojson.features.length:1;for(i=0;i<stop;i++){geometryMaybeCollection=isFeatureCollection?geojson.features[i].geometry:isFeature?geojson.geometry:geojson;featureProperties=isFeatureCollection?geojson.features[i].properties:isFeature?geojson.properties:{};featureBBox=isFeatureCollection?geojson.features[i].bbox:isFeature?geojson.bbox:undefined;featureId=isFeatureCollection?geojson.features[i].id:isFeature?geojson.id:undefined;isGeometryCollection=geometryMaybeCollection?geometryMaybeCollection.type==="GeometryCollection":false;stopG=isGeometryCollection?geometryMaybeCollection.geometries.length:1;for(g=0;g<stopG;g++){geometry=isGeometryCollection?geometryMaybeCollection.geometries[g]:geometryMaybeCollection;if(geometry===null){if(callback(null,featureIndex,featureProperties,featureBBox,featureId)===false)return false;continue}switch(geometry.type){case"Point":case"LineString":case"MultiPoint":case"Polygon":case"MultiLineString":case"MultiPolygon":{if(callback(geometry,featureIndex,featureProperties,featureBBox,featureId)===false)return false;break}case"GeometryCollection":{for(j=0;j<geometry.geometries.length;j++){if(callback(geometry.geometries[j],featureIndex,featureProperties,featureBBox,featureId)===false)return false}break}default:throw new Error("Unknown Geometry Type")}}featureIndex++}}function geomReduce(geojson,callback,initialValue){var previousValue=initialValue;geomEach(geojson,function(currentGeometry,featureIndex,featureProperties,featureBBox,featureId){if(featureIndex===0&&initialValue===undefined)previousValue=currentGeometry;else previousValue=callback(previousValue,currentGeometry,featureIndex,featureProperties,featureBBox,featureId)});return previousValue}function flattenEach(geojson,callback){geomEach(geojson,function(geometry,featureIndex,properties,bbox,id){var type=geometry===null?null:geometry.type;switch(type){case null:case"Point":case"LineString":case"Polygon":if(callback(feature(geometry,properties,{bbox:bbox,id:id}),featureIndex,0)===false)return false;return}var geomType;switch(type){case"MultiPoint":geomType="Point";break;case"MultiLineString":geomType="LineString";break;case"MultiPolygon":geomType="Polygon";break}for(var multiFeatureIndex=0;multiFeatureIndex<geometry.coordinates.length;multiFeatureIndex++){var coordinate=geometry.coordinates[multiFeatureIndex];var geom={type:geomType,coordinates:coordinate};if(callback(feature(geom,properties),featureIndex,multiFeatureIndex)===false)return false}})}function flattenReduce(geojson,callback,initialValue){var previousValue=initialValue;flattenEach(geojson,function(currentFeature,featureIndex,multiFeatureIndex){if(featureIndex===0&&multiFeatureIndex===0&&initialValue===undefined)previousValue=currentFeature;else previousValue=callback(previousValue,currentFeature,featureIndex,multiFeatureIndex)});return previousValue}function segmentEach(geojson,callback){flattenEach(geojson,function(feature,featureIndex,multiFeatureIndex){var segmentIndex=0;if(!feature.geometry)return;var type=feature.geometry.type;if(type==="Point"||type==="MultiPoint")return;var previousCoords;var previousFeatureIndex=0;var previousMultiIndex=0;var prevGeomIndex=0;if(coordEach(feature,function(currentCoord,coordIndex,featureIndexCoord,multiPartIndexCoord,geometryIndex){if(previousCoords===undefined||featureIndex>previousFeatureIndex||multiPartIndexCoord>previousMultiIndex||geometryIndex>prevGeomIndex){previousCoords=currentCoord;previousFeatureIndex=featureIndex;previousMultiIndex=multiPartIndexCoord;prevGeomIndex=geometryIndex;segmentIndex=0;return}var currentSegment=lineString([previousCoords,currentCoord],feature.properties);if(callback(currentSegment,featureIndex,multiFeatureIndex,geometryIndex,segmentIndex)===false)return false;segmentIndex++;previousCoords=currentCoord})===false)return false})}function segmentReduce(geojson,callback,initialValue){var previousValue=initialValue;var started=false;segmentEach(geojson,function(currentSegment,featureIndex,multiFeatureIndex,geometryIndex,segmentIndex){if(started===false&&initialValue===undefined)previousValue=currentSegment;else previousValue=callback(previousValue,currentSegment,featureIndex,multiFeatureIndex,geometryIndex,segmentIndex);started=true});return previousValue}function lineEach(geojson,callback){if(!geojson)throw new Error("geojson is required");flattenEach(geojson,function(feature,featureIndex,multiFeatureIndex){if(feature.geometry===null)return;var type=feature.geometry.type;var coords=feature.geometry.coordinates;switch(type){case"LineString":if(callback(feature,featureIndex,multiFeatureIndex,0,0)===false)return false;break;case"Polygon":for(var geometryIndex=0;geometryIndex<coords.length;geometryIndex++){if(callback(lineString(coords[geometryIndex],feature.properties),featureIndex,multiFeatureIndex,geometryIndex)===false)return false}break}})}function lineReduce(geojson,callback,initialValue){var previousValue=initialValue;lineEach(geojson,function(currentLine,featureIndex,multiFeatureIndex,geometryIndex){if(featureIndex===0&&initialValue===undefined)previousValue=currentLine;else previousValue=callback(previousValue,currentLine,featureIndex,multiFeatureIndex,geometryIndex)});return previousValue}function findSegment(geojson,options){options=options||{};if(!isObject(options))throw new Error("options is invalid");var featureIndex=options.featureIndex||0;var multiFeatureIndex=options.multiFeatureIndex||0;var geometryIndex=options.geometryIndex||0;var segmentIndex=options.segmentIndex||0;var properties=options.properties;var geometry;switch(geojson.type){case"FeatureCollection":if(featureIndex<0)featureIndex=geojson.features.length+featureIndex;properties=properties||geojson.features[featureIndex].properties;geometry=geojson.features[featureIndex].geometry;break;case"Feature":properties=properties||geojson.properties;geometry=geojson.geometry;break;case"Point":case"MultiPoint":return null;case"LineString":case"Polygon":case"MultiLineString":case"MultiPolygon":geometry=geojson;break;default:throw new Error("geojson is invalid")}if(geometry===null)return null;var coords=geometry.coordinates;switch(geometry.type){case"Point":case"MultiPoint":return null;case"LineString":if(segmentIndex<0)segmentIndex=coords.length+segmentIndex-1;return lineString([coords[segmentIndex],coords[segmentIndex+1]],properties,options);case"Polygon":if(geometryIndex<0)geometryIndex=coords.length+geometryIndex;if(segmentIndex<0)segmentIndex=coords[geometryIndex].length+segmentIndex-1;return lineString([coords[geometryIndex][segmentIndex],coords[geometryIndex][segmentIndex+1]],properties,options);case"MultiLineString":if(multiFeatureIndex<0)multiFeatureIndex=coords.length+multiFeatureIndex;if(segmentIndex<0)segmentIndex=coords[multiFeatureIndex].length+segmentIndex-1;return lineString([coords[multiFeatureIndex][segmentIndex],coords[multiFeatureIndex][segmentIndex+1]],properties,options);case"MultiPolygon":if(multiFeatureIndex<0)multiFeatureIndex=coords.length+multiFeatureIndex;if(geometryIndex<0)geometryIndex=coords[multiFeatureIndex].length+geometryIndex;if(segmentIndex<0)segmentIndex=coords[multiFeatureIndex][geometryIndex].length-segmentIndex-1;return lineString([coords[multiFeatureIndex][geometryIndex][segmentIndex],coords[multiFeatureIndex][geometryIndex][segmentIndex+1]],properties,options)}throw new Error("geojson is invalid")}function findPoint(geojson,options){options=options||{};if(!isObject(options))throw new Error("options is invalid");var featureIndex=options.featureIndex||0;var multiFeatureIndex=options.multiFeatureIndex||0;var geometryIndex=options.geometryIndex||0;var coordIndex=options.coordIndex||0;var properties=options.properties;var geometry;switch(geojson.type){case"FeatureCollection":if(featureIndex<0)featureIndex=geojson.features.length+featureIndex;properties=properties||geojson.features[featureIndex].properties;geometry=geojson.features[featureIndex].geometry;break;case"Feature":properties=properties||geojson.properties;geometry=geojson.geometry;break;case"Point":case"MultiPoint":return null;case"LineString":case"Polygon":case"MultiLineString":case"MultiPolygon":geometry=geojson;break;default:throw new Error("geojson is invalid")}if(geometry===null)return null;var coords=geometry.coordinates;switch(geometry.type){case"Point":return point(coords,properties,options);case"MultiPoint":if(multiFeatureIndex<0)multiFeatureIndex=coords.length+multiFeatureIndex;return point(coords[multiFeatureIndex],properties,options);case"LineString":if(coordIndex<0)coordIndex=coords.length+coordIndex;return point(coords[coordIndex],properties,options);case"Polygon":if(geometryIndex<0)geometryIndex=coords.length+geometryIndex;if(coordIndex<0)coordIndex=coords[geometryIndex].length+coordIndex;return point(coords[geometryIndex][coordIndex],properties,options);case"MultiLineString":if(multiFeatureIndex<0)multiFeatureIndex=coords.length+multiFeatureIndex;if(coordIndex<0)coordIndex=coords[multiFeatureIndex].length+coordIndex;return point(coords[multiFeatureIndex][coordIndex],properties,options);case"MultiPolygon":if(multiFeatureIndex<0)multiFeatureIndex=coords.length+multiFeatureIndex;if(geometryIndex<0)geometryIndex=coords[multiFeatureIndex].length+geometryIndex;if(coordIndex<0)coordIndex=coords[multiFeatureIndex][geometryIndex].length-coordIndex;return point(coords[multiFeatureIndex][geometryIndex][coordIndex],properties,options)}throw new Error("geojson is invalid")}var es$1=Object.freeze({__proto__:null,coordAll:coordAll,coordEach:coordEach,coordReduce:coordReduce,featureEach:featureEach,featureReduce:featureReduce,findPoint:findPoint,findSegment:findSegment,flattenEach:flattenEach,flattenReduce:flattenReduce,geomEach:geomEach,geomReduce:geomReduce,lineEach:lineEach,lineReduce:lineReduce,propEach:propEach,propReduce:propReduce,segmentEach:segmentEach,segmentReduce:segmentReduce});function lineSegment(geojson){if(!geojson){throw new Error("geojson is required")}var results=[];flattenEach(geojson,function(feature){lineSegmentFeature(feature,results)});return featureCollection(results)}function lineSegmentFeature(geojson,results){var coords=[];var geometry=geojson.geometry;if(geometry!==null){switch(geometry.type){case"Polygon":coords=getCoords(geometry);break;case"LineString":coords=[getCoords(geometry)]}coords.forEach(function(coord){var segments=createSegments(coord,geojson.properties);segments.forEach(function(segment){segment.id=results.length;results.push(segment)})})}}function createSegments(coords,properties){var segments=[];coords.reduce(function(previousCoords,currentCoords){var segment=lineString([previousCoords,currentCoords],properties);segment.bbox=bbox(previousCoords,currentCoords);segments.push(segment);return currentCoords});return segments}function bbox(coords1,coords2){var x1=coords1[0];var y1=coords1[1];var x2=coords2[0];var y2=coords2[1];var west=x1<x2?x1:x2;var south=y1<y2?y1:y2;var east=x1>x2?x1:x2;var north=y1>y2?y1:y2;return[west,south,east,north]}function quickselect(arr,k,left,right,compare){quickselectStep(arr,k,left||0,right||arr.length-1,compare||defaultCompare)}function quickselectStep(arr,k,left,right,compare){while(right>left){if(right-left>600){var n=right-left+1;var m=k-left+1;var z=Math.log(n);var s=.5*Math.exp(2*z/3);var sd=.5*Math.sqrt(z*s*(n-s)/n)*(m-n/2<0?-1:1);var newLeft=Math.max(left,Math.floor(k-m*s/n+sd));var newRight=Math.min(right,Math.floor(k+(n-m)*s/n+sd));quickselectStep(arr,k,newLeft,newRight,compare)}var t=arr[k];var i=left;var j=right;swap(arr,left,k);if(compare(arr[right],t)>0)swap(arr,left,right);while(i<j){swap(arr,i,j);i++;j--;while(compare(arr[i],t)<0)i++;while(compare(arr[j],t)>0)j--}if(compare(arr[left],t)===0)swap(arr,left,j);else{j++;swap(arr,j,right)}if(j<=k)left=j+1;if(k<=j)right=j-1}}function swap(arr,i,j){var tmp=arr[i];arr[i]=arr[j];arr[j]=tmp}function defaultCompare(a,b){return a<b?-1:a>b?1:0}var RBush=function(){function RBush(){var maxEntries=arguments.length>0&&arguments[0]!==undefined?arguments[0]:9;_classCallCheck(this,RBush);this._maxEntries=Math.max(4,maxEntries);this._minEntries=Math.max(2,Math.ceil(this._maxEntries*.4));this.clear()}_createClass(RBush,[{key:"all",value:function all(){return this._all(this.data,[])}},{key:"search",value:function search(bbox){var node=this.data;var result=[];if(!intersects(bbox,node))return result;var toBBox=this.toBBox;var nodesToSearch=[];while(node){for(var i=0;i<node.children.length;i++){var child=node.children[i];var childBBox=node.leaf?toBBox(child):child;if(intersects(bbox,childBBox)){if(node.leaf)result.push(child);else if(contains(bbox,childBBox))this._all(child,result);else nodesToSearch.push(child)}}node=nodesToSearch.pop()}return result}},{key:"collides",value:function collides(bbox){var node=this.data;if(!intersects(bbox,node))return false;var nodesToSearch=[];while(node){for(var i=0;i<node.children.length;i++){var child=node.children[i];var childBBox=node.leaf?this.toBBox(child):child;if(intersects(bbox,childBBox)){if(node.leaf||contains(bbox,childBBox))return true;nodesToSearch.push(child)}}node=nodesToSearch.pop()}return false}},{key:"load",value:function load(data){if(!(data&&data.length))return this;if(data.length<this._minEntries){for(var i=0;i<data.length;i++){this.insert(data[i])}return this}var node=this._build(data.slice(),0,data.length-1,0);if(!this.data.children.length){this.data=node}else if(this.data.height===node.height){this._splitRoot(this.data,node)}else{if(this.data.height<node.height){var tmpNode=this.data;this.data=node;node=tmpNode}this._insert(node,this.data.height-node.height-1,true)}return this}},{key:"insert",value:function insert(item){if(item)this._insert(item,this.data.height-1);return this}},{key:"clear",value:function clear(){this.data=createNode([]);return this}},{key:"remove",value:function remove(item,equalsFn){if(!item)return this;var node=this.data;var bbox=this.toBBox(item);var path=[];var indexes=[];var i,parent,goingUp;while(node||path.length){if(!node){node=path.pop();parent=path[path.length-1];i=indexes.pop();goingUp=true}if(node.leaf){var index=findItem(item,node.children,equalsFn);if(index!==-1){node.children.splice(index,1);path.push(node);this._condense(path);return this}}if(!goingUp&&!node.leaf&&contains(node,bbox)){path.push(node);indexes.push(i);i=0;parent=node;node=node.children[0]}else if(parent){i++;node=parent.children[i];goingUp=false}else node=null}return this}},{key:"toBBox",value:function toBBox(item){return item}},{key:"compareMinX",value:function compareMinX(a,b){return a.minX-b.minX}},{key:"compareMinY",value:function compareMinY(a,b){return a.minY-b.minY}},{key:"toJSON",value:function toJSON(){return this.data}},{key:"fromJSON",value:function fromJSON(data){this.data=data;return this}},{key:"_all",value:function _all(node,result){var nodesToSearch=[];while(node){if(node.leaf)result.push.apply(result,_toConsumableArray(node.children));else nodesToSearch.push.apply(nodesToSearch,_toConsumableArray(node.children));node=nodesToSearch.pop()}return result}},{key:"_build",value:function _build(items,left,right,height){var N=right-left+1;var M=this._maxEntries;var node;if(N<=M){node=createNode(items.slice(left,right+1));calcBBox(node,this.toBBox);return node}if(!height){height=Math.ceil(Math.log(N)/Math.log(M));M=Math.ceil(N/Math.pow(M,height-1))}node=createNode([]);node.leaf=false;node.height=height;var N2=Math.ceil(N/M);var N1=N2*Math.ceil(Math.sqrt(M));multiSelect(items,left,right,N1,this.compareMinX);for(var i=left;i<=right;i+=N1){var right2=Math.min(i+N1-1,right);multiSelect(items,i,right2,N2,this.compareMinY);for(var j=i;j<=right2;j+=N2){var right3=Math.min(j+N2-1,right2);node.children.push(this._build(items,j,right3,height-1))}}calcBBox(node,this.toBBox);return node}},{key:"_chooseSubtree",value:function _chooseSubtree(bbox,node,level,path){while(true){path.push(node);if(node.leaf||path.length-1===level)break;var minArea=Infinity;var minEnlargement=Infinity;var targetNode=void 0;for(var i=0;i<node.children.length;i++){var child=node.children[i];var area=bboxArea(child);var enlargement=enlargedArea(bbox,child)-area;if(enlargement<minEnlargement){minEnlargement=enlargement;minArea=area<minArea?area:minArea;targetNode=child}else if(enlargement===minEnlargement){if(area<minArea){minArea=area;targetNode=child}}}node=targetNode||node.children[0]}return node}},{key:"_insert",value:function _insert(item,level,isNode){var bbox=isNode?item:this.toBBox(item);var insertPath=[];var node=this._chooseSubtree(bbox,this.data,level,insertPath);node.children.push(item);extend(node,bbox);while(level>=0){if(insertPath[level].children.length>this._maxEntries){this._split(insertPath,level);level--}else break}this._adjustParentBBoxes(bbox,insertPath,level)}},{key:"_split",value:function _split(insertPath,level){var node=insertPath[level];var M=node.children.length;var m=this._minEntries;this._chooseSplitAxis(node,m,M);var splitIndex=this._chooseSplitIndex(node,m,M);var newNode=createNode(node.children.splice(splitIndex,node.children.length-splitIndex));newNode.height=node.height;newNode.leaf=node.leaf;calcBBox(node,this.toBBox);calcBBox(newNode,this.toBBox);if(level)insertPath[level-1].children.push(newNode);else this._splitRoot(node,newNode)}},{key:"_splitRoot",value:function _splitRoot(node,newNode){this.data=createNode([node,newNode]);this.data.height=node.height+1;this.data.leaf=false;calcBBox(this.data,this.toBBox)}},{key:"_chooseSplitIndex",value:function _chooseSplitIndex(node,m,M){var index;var minOverlap=Infinity;var minArea=Infinity;for(var i=m;i<=M-m;i++){var bbox1=distBBox(node,0,i,this.toBBox);var bbox2=distBBox(node,i,M,this.toBBox);var overlap=intersectionArea(bbox1,bbox2);var area=bboxArea(bbox1)+bboxArea(bbox2);if(overlap<minOverlap){minOverlap=overlap;index=i;minArea=area<minArea?area:minArea}else if(overlap===minOverlap){if(area<minArea){minArea=area;index=i}}}return index||M-m}},{key:"_chooseSplitAxis",value:function _chooseSplitAxis(node,m,M){var compareMinX=node.leaf?this.compareMinX:compareNodeMinX;var compareMinY=node.leaf?this.compareMinY:compareNodeMinY;var xMargin=this._allDistMargin(node,m,M,compareMinX);var yMargin=this._allDistMargin(node,m,M,compareMinY);if(xMargin<yMargin)node.children.sort(compareMinX)}},{key:"_allDistMargin",value:function _allDistMargin(node,m,M,compare){node.children.sort(compare);var toBBox=this.toBBox;var leftBBox=distBBox(node,0,m,toBBox);var rightBBox=distBBox(node,M-m,M,toBBox);var margin=bboxMargin(leftBBox)+bboxMargin(rightBBox);for(var i=m;i<M-m;i++){var child=node.children[i];extend(leftBBox,node.leaf?toBBox(child):child);margin+=bboxMargin(leftBBox)}for(var _i=M-m-1;_i>=m;_i--){var _child=node.children[_i];extend(rightBBox,node.leaf?toBBox(_child):_child);margin+=bboxMargin(rightBBox)}return margin}},{key:"_adjustParentBBoxes",value:function _adjustParentBBoxes(bbox,path,level){for(var i=level;i>=0;i--){extend(path[i],bbox)}}},{key:"_condense",value:function _condense(path){for(var i=path.length-1,siblings;i>=0;i--){if(path[i].children.length===0){if(i>0){siblings=path[i-1].children;siblings.splice(siblings.indexOf(path[i]),1)}else this.clear()}else calcBBox(path[i],this.toBBox)}}}]);return RBush}();function findItem(item,items,equalsFn){if(!equalsFn)return items.indexOf(item);for(var i=0;i<items.length;i++){if(equalsFn(item,items[i]))return i}return-1}function calcBBox(node,toBBox){distBBox(node,0,node.children.length,toBBox,node)}function distBBox(node,k,p,toBBox,destNode){if(!destNode)destNode=createNode(null);destNode.minX=Infinity;destNode.minY=Infinity;destNode.maxX=-Infinity;destNode.maxY=-Infinity;for(var i=k;i<p;i++){var child=node.children[i];extend(destNode,node.leaf?toBBox(child):child)}return destNode}function extend(a,b){a.minX=Math.min(a.minX,b.minX);a.minY=Math.min(a.minY,b.minY);a.maxX=Math.max(a.maxX,b.maxX);a.maxY=Math.max(a.maxY,b.maxY);return a}function compareNodeMinX(a,b){return a.minX-b.minX}function compareNodeMinY(a,b){return a.minY-b.minY}function bboxArea(a){return(a.maxX-a.minX)*(a.maxY-a.minY)}function bboxMargin(a){return a.maxX-a.minX+(a.maxY-a.minY)}function enlargedArea(a,b){return(Math.max(b.maxX,a.maxX)-Math.min(b.minX,a.minX))*(Math.max(b.maxY,a.maxY)-Math.min(b.minY,a.minY))}function intersectionArea(a,b){var minX=Math.max(a.minX,b.minX);var minY=Math.max(a.minY,b.minY);var maxX=Math.min(a.maxX,b.maxX);var maxY=Math.min(a.maxY,b.maxY);return Math.max(0,maxX-minX)*Math.max(0,maxY-minY)}function contains(a,b){return a.minX<=b.minX&&a.minY<=b.minY&&b.maxX<=a.maxX&&b.maxY<=a.maxY}function intersects(a,b){return b.minX<=a.maxX&&b.minY<=a.maxY&&b.maxX>=a.minX&&b.maxY>=a.minY}function createNode(children){return{children:children,height:1,leaf:true,minX:Infinity,minY:Infinity,maxX:-Infinity,maxY:-Infinity}}function multiSelect(arr,left,right,n,compare){var stack=[left,right];while(stack.length){right=stack.pop();left=stack.pop();if(right-left<=n)continue;var mid=left+Math.ceil((right-left)/n/2)*n;quickselect(arr,mid,left,right,compare);stack.push(left,mid,mid,right)}}function bbox$1(geojson){var result=[Infinity,Infinity,-Infinity,-Infinity];coordEach(geojson,function(coord){if(result[0]>coord[0]){result[0]=coord[0]}if(result[1]>coord[1]){result[1]=coord[1]}if(result[2]<coord[0]){result[2]=coord[0]}if(result[3]<coord[1]){result[3]=coord[1]}});return result}bbox$1["default"]=bbox$1;var turfBBox=bbox$1.default;var featureEach$1=es$1.featureEach;var coordEach$1=es$1.coordEach;var polygon$1=es.polygon;var featureCollection$1=es.featureCollection;function geojsonRbush(maxEntries){var tree=new RBush(maxEntries);tree.insert=function(feature){if(feature.type!=="Feature")throw new Error("invalid feature");feature.bbox=feature.bbox?feature.bbox:turfBBox(feature);return RBush.prototype.insert.call(this,feature)};tree.load=function(features){var load=[];if(Array.isArray(features)){features.forEach(function(feature){if(feature.type!=="Feature")throw new Error("invalid features");feature.bbox=feature.bbox?feature.bbox:turfBBox(feature);load.push(feature)})}else{featureEach$1(features,function(feature){if(feature.type!=="Feature")throw new Error("invalid features");feature.bbox=feature.bbox?feature.bbox:turfBBox(feature);load.push(feature)})}return RBush.prototype.load.call(this,load)};tree.remove=function(feature,equals){if(feature.type!=="Feature")throw new Error("invalid feature");feature.bbox=feature.bbox?feature.bbox:turfBBox(feature);return RBush.prototype.remove.call(this,feature,equals)};tree.clear=function(){return RBush.prototype.clear.call(this)};tree.search=function(geojson){var features=RBush.prototype.search.call(this,this.toBBox(geojson));return featureCollection$1(features)};tree.collides=function(geojson){return RBush.prototype.collides.call(this,this.toBBox(geojson))};tree.all=function(){var features=RBush.prototype.all.call(this);return featureCollection$1(features)};tree.toJSON=function(){return RBush.prototype.toJSON.call(this)};tree.fromJSON=function(json){return RBush.prototype.fromJSON.call(this,json)};tree.toBBox=function(geojson){var bbox;if(geojson.bbox)bbox=geojson.bbox;else if(Array.isArray(geojson)&&geojson.length===4)bbox=geojson;else if(Array.isArray(geojson)&&geojson.length===6)bbox=[geojson[0],geojson[1],geojson[3],geojson[4]];else if(geojson.type==="Feature")bbox=turfBBox(geojson);else if(geojson.type==="FeatureCollection")bbox=turfBBox(geojson);else throw new Error("invalid geojson");return{minX:bbox[0],minY:bbox[1],maxX:bbox[2],maxY:bbox[3]}};return tree}var _geojsonRbush_3_2_0_geojsonRbush=geojsonRbush;var default_1=geojsonRbush;_geojsonRbush_3_2_0_geojsonRbush.default=default_1;function lineIntersect(line1,line2){var unique={};var results=[];if(line1.type==="LineString"){line1=feature(line1)}if(line2.type==="LineString"){line2=feature(line2)}if(line1.type==="Feature"&&line2.type==="Feature"&&line1.geometry!==null&&line2.geometry!==null&&line1.geometry.type==="LineString"&&line2.geometry.type==="LineString"&&line1.geometry.coordinates.length===2&&line2.geometry.coordinates.length===2){var intersect=intersects$1(line1,line2);if(intersect){results.push(intersect)}return featureCollection(results)}var tree=_geojsonRbush_3_2_0_geojsonRbush();tree.load(lineSegment(line2));featureEach(lineSegment(line1),function(segment){featureEach(tree.search(segment),function(match){var intersect=intersects$1(segment,match);if(intersect){var key=getCoords(intersect).join(",");if(!unique[key]){unique[key]=true;results.push(intersect)}}})});return featureCollection(results)}function intersects$1(line1,line2){var coords1=getCoords(line1);var coords2=getCoords(line2);if(coords1.length!==2){throw new Error("<intersects> line1 must only contain 2 coordinates")}if(coords2.length!==2){throw new Error("<intersects> line2 must only contain 2 coordinates")}var x1=coords1[0][0];var y1=coords1[0][1];var x2=coords1[1][0];var y2=coords1[1][1];var x3=coords2[0][0];var y3=coords2[0][1];var x4=coords2[1][0];var y4=coords2[1][1];var denom=(y4-y3)*(x2-x1)-(x4-x3)*(y2-y1);var numeA=(x4-x3)*(y1-y3)-(y4-y3)*(x1-x3);var numeB=(x2-x1)*(y1-y3)-(y2-y1)*(x1-x3);if(denom===0){if(numeA===0&&numeB===0){return null}return null}var uA=numeA/denom;var uB=numeB/denom;if(uA>=0&&uA<=1&&uB>=0&&uB<=1){var x=x1+uA*(x2-x1);var y=y1+uA*(y2-y1);return point([x,y])}return null}function nearestPointOnLine(lines,pt,options){if(options===void 0){options={}}var closestPt=point([Infinity,Infinity],{dist:Infinity});var length=0;flattenEach(lines,function(line){var coords=getCoords(line);for(var i=0;i<coords.length-1;i++){var start=point(coords[i]);start.properties.dist=distance(pt,start,options);var stop_1=point(coords[i+1]);stop_1.properties.dist=distance(pt,stop_1,options);var sectionLength=distance(start,stop_1,options);var heightDistance=Math.max(start.properties.dist,stop_1.properties.dist);var direction=bearing(start,stop_1);var perpendicularPt1=destination(pt,heightDistance,direction+90,options);var perpendicularPt2=destination(pt,heightDistance,direction-90,options);var intersect=lineIntersect(lineString([perpendicularPt1.geometry.coordinates,perpendicularPt2.geometry.coordinates]),lineString([start.geometry.coordinates,stop_1.geometry.coordinates]));var intersectPt=null;if(intersect.features.length>0){intersectPt=intersect.features[0];intersectPt.properties.dist=distance(pt,intersectPt,options);intersectPt.properties.location=length+distance(start,intersectPt,options)}if(start.properties.dist<closestPt.properties.dist){closestPt=start;closestPt.properties.index=i;closestPt.properties.location=length}if(stop_1.properties.dist<closestPt.properties.dist){closestPt=stop_1;closestPt.properties.index=i+1;closestPt.properties.location=length+sectionLength}if(intersectPt&&intersectPt.properties.dist<closestPt.properties.dist){closestPt=intersectPt;closestPt.properties.index=i}length+=sectionLength}});return closestPt}var freeGlobal=(typeof global==="undefined"?"undefined":_typeof(global))=="object"&&global&&global.Object===Object&&global;var freeSelf=(typeof self==="undefined"?"undefined":_typeof(self))=="object"&&self&&self.Object===Object&&self;var root=freeGlobal||freeSelf||Function("return this")();var _Symbol=root.Symbol;var objectProto=Object.prototype;var hasOwnProperty=objectProto.hasOwnProperty;var nativeObjectToString=objectProto.toString;var symToStringTag=_Symbol?_Symbol.toStringTag:undefined;function getRawTag(value){var isOwn=hasOwnProperty.call(value,symToStringTag),tag=value[symToStringTag];try{value[symToStringTag]=undefined;var unmasked=true}catch(e){}var result=nativeObjectToString.call(value);if(unmasked){if(isOwn){value[symToStringTag]=tag}else{delete value[symToStringTag]}}return result}var objectProto$1=Object.prototype;var nativeObjectToString$1=objectProto$1.toString;function objectToString(value){return nativeObjectToString$1.call(value)}var nullTag="[object Null]",undefinedTag="[object Undefined]";var symToStringTag$1=_Symbol?_Symbol.toStringTag:undefined;function baseGetTag(value){if(value==null){return value===undefined?undefinedTag:nullTag}return symToStringTag$1&&symToStringTag$1 in Object(value)?getRawTag(value):objectToString(value)}function isObjectLike(value){return value!=null&&_typeof(value)=="object"}var symbolTag="[object Symbol]";function isSymbol(value){return _typeof(value)=="symbol"||isObjectLike(value)&&baseGetTag(value)==symbolTag}function arrayMap(array,iteratee){var index=-1,length=array==null?0:array.length,result=Array(length);while(++index<length){result[index]=iteratee(array[index],index,array)}return result}var isArray=Array.isArray;var INFINITY=1/0;var symbolProto=_Symbol?_Symbol.prototype:undefined,symbolToString=symbolProto?symbolProto.toString:undefined;function baseToString(value){if(typeof value=="string"){return value}if(isArray(value)){return arrayMap(value,baseToString)+""}if(isSymbol(value)){return symbolToString?symbolToString.call(value):""}var result=value+"";return result=="0"&&1/value==-INFINITY?"-0":result}function isObject$1(value){var type=_typeof(value);return value!=null&&(type=="object"||type=="function")}function identity(value){return value}var asyncTag="[object AsyncFunction]",funcTag="[object Function]",genTag="[object GeneratorFunction]",proxyTag="[object Proxy]";function isFunction(value){if(!isObject$1(value)){return false}var tag=baseGetTag(value);return tag==funcTag||tag==genTag||tag==asyncTag||tag==proxyTag}var coreJsData=root["__core-js_shared__"];var maskSrcKey=function(){var uid=/[^.]+$/.exec(coreJsData&&coreJsData.keys&&coreJsData.keys.IE_PROTO||"");return uid?"Symbol(src)_1."+uid:""}();function isMasked(func){return!!maskSrcKey&&maskSrcKey in func}var funcProto=Function.prototype;var funcToString=funcProto.toString;function toSource(func){if(func!=null){try{return funcToString.call(func)}catch(e){}try{return func+""}catch(e){}}return""}var reRegExpChar=/[\\\\^$.*+?()[\\]{}|]/g;var reIsHostCtor=/^\\[object .+?Constructor\\]$/;var funcProto$1=Function.prototype,objectProto$2=Object.prototype;var funcToString$1=funcProto$1.toString;var hasOwnProperty$1=objectProto$2.hasOwnProperty;var reIsNative=RegExp("^"+funcToString$1.call(hasOwnProperty$1).replace(reRegExpChar,"\\\\$&").replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g,"$1.*?")+"$");function baseIsNative(value){if(!isObject$1(value)||isMasked(value)){return false}var pattern=isFunction(value)?reIsNative:reIsHostCtor;return pattern.test(toSource(value))}function getValue(object,key){return object==null?undefined:object[key]}function getNative(object,key){var value=getValue(object,key);return baseIsNative(value)?value:undefined}var WeakMap=getNative(root,"WeakMap");function arrayEach(array,iteratee){var index=-1,length=array==null?0:array.length;while(++index<length){if(iteratee(array[index],index,array)===false){break}}return array}var MAX_SAFE_INTEGER=9007199254740991;var reIsUint=/^(?:0|[1-9]\\d*)$/;function isIndex(value,length){var type=_typeof(value);length=length==null?MAX_SAFE_INTEGER:length;return!!length&&(type=="number"||type!="symbol"&&reIsUint.test(value))&&value>-1&&value%1==0&&value<length}function eq(value,other){return value===other||value!==value&&other!==other}var MAX_SAFE_INTEGER$1=9007199254740991;function isLength(value){return typeof value=="number"&&value>-1&&value%1==0&&value<=MAX_SAFE_INTEGER$1}function isArrayLike(value){return value!=null&&isLength(value.length)&&!isFunction(value)}var objectProto$3=Object.prototype;function isPrototype(value){var Ctor=value&&value.constructor,proto=typeof Ctor=="function"&&Ctor.prototype||objectProto$3;return value===proto}function baseTimes(n,iteratee){var index=-1,result=Array(n);while(++index<n){result[index]=iteratee(index)}return result}var argsTag="[object Arguments]";function baseIsArguments(value){return isObjectLike(value)&&baseGetTag(value)==argsTag}var objectProto$4=Object.prototype;var hasOwnProperty$2=objectProto$4.hasOwnProperty;var propertyIsEnumerable=objectProto$4.propertyIsEnumerable;var isArguments=baseIsArguments(function(){return arguments}())?baseIsArguments:function(value){return isObjectLike(value)&&hasOwnProperty$2.call(value,"callee")&&!propertyIsEnumerable.call(value,"callee")};function stubFalse(){return false}var freeExports=(typeof exports==="undefined"?"undefined":_typeof(exports))=="object"&&exports&&!exports.nodeType&&exports;var freeModule=freeExports&&(typeof module==="undefined"?"undefined":_typeof(module))=="object"&&module&&!module.nodeType&&module;var moduleExports=freeModule&&freeModule.exports===freeExports;var Buffer=moduleExports?root.Buffer:undefined;var nativeIsBuffer=Buffer?Buffer.isBuffer:undefined;var isBuffer=nativeIsBuffer||stubFalse;var argsTag$1="[object Arguments]",arrayTag="[object Array]",boolTag="[object Boolean]",dateTag="[object Date]",errorTag="[object Error]",funcTag$1="[object Function]",mapTag="[object Map]",numberTag="[object Number]",objectTag="[object Object]",regexpTag="[object RegExp]",setTag="[object Set]",stringTag="[object String]",weakMapTag="[object WeakMap]";var arrayBufferTag="[object ArrayBuffer]",dataViewTag="[object DataView]",float32Tag="[object Float32Array]",float64Tag="[object Float64Array]",int8Tag="[object Int8Array]",int16Tag="[object Int16Array]",int32Tag="[object Int32Array]",uint8Tag="[object Uint8Array]",uint8ClampedTag="[object Uint8ClampedArray]",uint16Tag="[object Uint16Array]",uint32Tag="[object Uint32Array]";var typedArrayTags={};typedArrayTags[float32Tag]=typedArrayTags[float64Tag]=typedArrayTags[int8Tag]=typedArrayTags[int16Tag]=typedArrayTags[int32Tag]=typedArrayTags[uint8Tag]=typedArrayTags[uint8ClampedTag]=typedArrayTags[uint16Tag]=typedArrayTags[uint32Tag]=true;typedArrayTags[argsTag$1]=typedArrayTags[arrayTag]=typedArrayTags[arrayBufferTag]=typedArrayTags[boolTag]=typedArrayTags[dataViewTag]=typedArrayTags[dateTag]=typedArrayTags[errorTag]=typedArrayTags[funcTag$1]=typedArrayTags[mapTag]=typedArrayTags[numberTag]=typedArrayTags[objectTag]=typedArrayTags[regexpTag]=typedArrayTags[setTag]=typedArrayTags[stringTag]=typedArrayTags[weakMapTag]=false;function baseIsTypedArray(value){return isObjectLike(value)&&isLength(value.length)&&!!typedArrayTags[baseGetTag(value)]}function baseUnary(func){return function(value){return func(value)}}var freeExports$1=(typeof exports==="undefined"?"undefined":_typeof(exports))=="object"&&exports&&!exports.nodeType&&exports;var freeModule$1=freeExports$1&&(typeof module==="undefined"?"undefined":_typeof(module))=="object"&&module&&!module.nodeType&&module;var moduleExports$1=freeModule$1&&freeModule$1.exports===freeExports$1;var freeProcess=moduleExports$1&&freeGlobal.process;var nodeUtil=function(){try{var types=freeModule$1&&freeModule$1.require&&freeModule$1.require("util").types;if(types){return types}return freeProcess&&freeProcess.binding&&freeProcess.binding("util")}catch(e){}}();var nodeIsTypedArray=nodeUtil&&nodeUtil.isTypedArray;var isTypedArray=nodeIsTypedArray?baseUnary(nodeIsTypedArray):baseIsTypedArray;var objectProto$5=Object.prototype;var hasOwnProperty$3=objectProto$5.hasOwnProperty;function arrayLikeKeys(value,inherited){var isArr=isArray(value),isArg=!isArr&&isArguments(value),isBuff=!isArr&&!isArg&&isBuffer(value),isType=!isArr&&!isArg&&!isBuff&&isTypedArray(value),skipIndexes=isArr||isArg||isBuff||isType,result=skipIndexes?baseTimes(value.length,String):[],length=result.length;for(var key in value){if((inherited||hasOwnProperty$3.call(value,key))&&!(skipIndexes&&(key=="length"||isBuff&&(key=="offset"||key=="parent")||isType&&(key=="buffer"||key=="byteLength"||key=="byteOffset")||isIndex(key,length)))){result.push(key)}}return result}function overArg(func,transform){return function(arg){return func(transform(arg))}}var nativeKeys=overArg(Object.keys,Object);var objectProto$6=Object.prototype;var hasOwnProperty$4=objectProto$6.hasOwnProperty;function baseKeys(object){if(!isPrototype(object)){return nativeKeys(object)}var result=[];for(var key in Object(object)){if(hasOwnProperty$4.call(object,key)&&key!="constructor"){result.push(key)}}return result}function keys(object){return isArrayLike(object)?arrayLikeKeys(object):baseKeys(object)}var reIsDeepProp=/\\.|\\[(?:[^[\\]]*|(["\'])(?:(?!\\1)[^\\\\]|\\\\.)*?\\1)\\]/,reIsPlainProp=/^\\w*$/;function isKey(value,object){if(isArray(value)){return false}var type=_typeof(value);if(type=="number"||type=="symbol"||type=="boolean"||value==null||isSymbol(value)){return true}return reIsPlainProp.test(value)||!reIsDeepProp.test(value)||object!=null&&value in Object(object)}var nativeCreate=getNative(Object,"create");function hashClear(){this.__data__=nativeCreate?nativeCreate(null):{};this.size=0}function hashDelete(key){var result=this.has(key)&&delete this.__data__[key];this.size-=result?1:0;return result}var HASH_UNDEFINED="__lodash_hash_undefined__";var objectProto$7=Object.prototype;var hasOwnProperty$5=objectProto$7.hasOwnProperty;function hashGet(key){var data=this.__data__;if(nativeCreate){var result=data[key];return result===HASH_UNDEFINED?undefined:result}return hasOwnProperty$5.call(data,key)?data[key]:undefined}var objectProto$8=Object.prototype;var hasOwnProperty$6=objectProto$8.hasOwnProperty;function hashHas(key){var data=this.__data__;return nativeCreate?data[key]!==undefined:hasOwnProperty$6.call(data,key)}var HASH_UNDEFINED$1="__lodash_hash_undefined__";function hashSet(key,value){var data=this.__data__;this.size+=this.has(key)?0:1;data[key]=nativeCreate&&value===undefined?HASH_UNDEFINED$1:value;return this}function Hash(entries){var index=-1,length=entries==null?0:entries.length;this.clear();while(++index<length){var entry=entries[index];this.set(entry[0],entry[1])}}Hash.prototype.clear=hashClear;Hash.prototype["delete"]=hashDelete;Hash.prototype.get=hashGet;Hash.prototype.has=hashHas;Hash.prototype.set=hashSet;function listCacheClear(){this.__data__=[];this.size=0}function assocIndexOf(array,key){var length=array.length;while(length--){if(eq(array[length][0],key)){return length}}return-1}var arrayProto=Array.prototype;var splice=arrayProto.splice;function listCacheDelete(key){var data=this.__data__,index=assocIndexOf(data,key);if(index<0){return false}var lastIndex=data.length-1;if(index==lastIndex){data.pop()}else{splice.call(data,index,1)}--this.size;return true}function listCacheGet(key){var data=this.__data__,index=assocIndexOf(data,key);return index<0?undefined:data[index][1]}function listCacheHas(key){return assocIndexOf(this.__data__,key)>-1}function listCacheSet(key,value){var data=this.__data__,index=assocIndexOf(data,key);if(index<0){++this.size;data.push([key,value])}else{data[index][1]=value}return this}function ListCache(entries){var index=-1,length=entries==null?0:entries.length;this.clear();while(++index<length){var entry=entries[index];this.set(entry[0],entry[1])}}ListCache.prototype.clear=listCacheClear;ListCache.prototype["delete"]=listCacheDelete;ListCache.prototype.get=listCacheGet;ListCache.prototype.has=listCacheHas;ListCache.prototype.set=listCacheSet;var Map=getNative(root,"Map");function mapCacheClear(){this.size=0;this.__data__={hash:new Hash,map:new(Map||ListCache),string:new Hash}}function isKeyable(value){var type=_typeof(value);return type=="string"||type=="number"||type=="symbol"||type=="boolean"?value!=="__proto__":value===null}function getMapData(map,key){var data=map.__data__;return isKeyable(key)?data[typeof key=="string"?"string":"hash"]:data.map}function mapCacheDelete(key){var result=getMapData(this,key)["delete"](key);this.size-=result?1:0;return result}function mapCacheGet(key){return getMapData(this,key).get(key)}function mapCacheHas(key){return getMapData(this,key).has(key)}function mapCacheSet(key,value){var data=getMapData(this,key),size=data.size;data.set(key,value);this.size+=data.size==size?0:1;return this}function MapCache(entries){var index=-1,length=entries==null?0:entries.length;this.clear();while(++index<length){var entry=entries[index];this.set(entry[0],entry[1])}}MapCache.prototype.clear=mapCacheClear;MapCache.prototype["delete"]=mapCacheDelete;MapCache.prototype.get=mapCacheGet;MapCache.prototype.has=mapCacheHas;MapCache.prototype.set=mapCacheSet;var FUNC_ERROR_TEXT="Expected a function";function memoize(func,resolver){if(typeof func!="function"||resolver!=null&&typeof resolver!="function"){throw new TypeError(FUNC_ERROR_TEXT)}var memoized=function memoized(){var args=arguments,key=resolver?resolver.apply(this,args):args[0],cache=memoized.cache;if(cache.has(key)){return cache.get(key)}var result=func.apply(this,args);memoized.cache=cache.set(key,result)||cache;return result};memoized.cache=new(memoize.Cache||MapCache);return memoized}memoize.Cache=MapCache;var MAX_MEMOIZE_SIZE=500;function memoizeCapped(func){var result=memoize(func,function(key){if(cache.size===MAX_MEMOIZE_SIZE){cache.clear()}return key});var cache=result.cache;return result}var rePropName=/[^.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|(["\'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))/g;var reEscapeChar=/\\\\(\\\\)?/g;var stringToPath=memoizeCapped(function(string){var result=[];if(string.charCodeAt(0)===46){result.push("")}string.replace(rePropName,function(match,number,quote,subString){result.push(quote?subString.replace(reEscapeChar,"$1"):number||match)});return result});function toString(value){return value==null?"":baseToString(value)}function castPath(value,object){if(isArray(value)){return value}return isKey(value,object)?[value]:stringToPath(toString(value))}var INFINITY$1=1/0;function toKey(value){if(typeof value=="string"||isSymbol(value)){return value}var result=value+"";return result=="0"&&1/value==-INFINITY$1?"-0":result}function baseGet(object,path){path=castPath(path,object);var index=0,length=path.length;while(object!=null&&index<length){object=object[toKey(path[index++])]}return index&&index==length?object:undefined}function get(object,path,defaultValue){var result=object==null?undefined:baseGet(object,path);return result===undefined?defaultValue:result}function arrayPush(array,values){var index=-1,length=values.length,offset=array.length;while(++index<length){array[offset+index]=values[index]}return array}function stackClear(){this.__data__=new ListCache;this.size=0}function stackDelete(key){var data=this.__data__,result=data["delete"](key);this.size=data.size;return result}function stackGet(key){return this.__data__.get(key)}function stackHas(key){return this.__data__.has(key)}var LARGE_ARRAY_SIZE=200;function stackSet(key,value){var data=this.__data__;if(data instanceof ListCache){var pairs=data.__data__;if(!Map||pairs.length<LARGE_ARRAY_SIZE-1){pairs.push([key,value]);this.size=++data.size;return this}data=this.__data__=new MapCache(pairs)}data.set(key,value);this.size=data.size;return this}function Stack(entries){var data=this.__data__=new ListCache(entries);this.size=data.size}Stack.prototype.clear=stackClear;Stack.prototype["delete"]=stackDelete;Stack.prototype.get=stackGet;Stack.prototype.has=stackHas;Stack.prototype.set=stackSet;function arrayFilter(array,predicate){var index=-1,length=array==null?0:array.length,resIndex=0,result=[];while(++index<length){var value=array[index];if(predicate(value,index,array)){result[resIndex++]=value}}return result}function stubArray(){return[]}var objectProto$9=Object.prototype;var propertyIsEnumerable$1=objectProto$9.propertyIsEnumerable;var nativeGetSymbols=Object.getOwnPropertySymbols;var getSymbols=!nativeGetSymbols?stubArray:function(object){if(object==null){return[]}object=Object(object);return arrayFilter(nativeGetSymbols(object),function(symbol){return propertyIsEnumerable$1.call(object,symbol)})};function baseGetAllKeys(object,keysFunc,symbolsFunc){var result=keysFunc(object);return isArray(object)?result:arrayPush(result,symbolsFunc(object))}function getAllKeys(object){return baseGetAllKeys(object,keys,getSymbols)}var DataView=getNative(root,"DataView");var Promise=getNative(root,"Promise");var Set=getNative(root,"Set");var mapTag$1="[object Map]",objectTag$1="[object Object]",promiseTag="[object Promise]",setTag$1="[object Set]",weakMapTag$1="[object WeakMap]";var dataViewTag$1="[object DataView]";var dataViewCtorString=toSource(DataView),mapCtorString=toSource(Map),promiseCtorString=toSource(Promise),setCtorString=toSource(Set),weakMapCtorString=toSource(WeakMap);var getTag=baseGetTag;if(DataView&&getTag(new DataView(new ArrayBuffer(1)))!=dataViewTag$1||Map&&getTag(new Map)!=mapTag$1||Promise&&getTag(Promise.resolve())!=promiseTag||Set&&getTag(new Set)!=setTag$1||WeakMap&&getTag(new WeakMap)!=weakMapTag$1){getTag=function getTag(value){var result=baseGetTag(value),Ctor=result==objectTag$1?value.constructor:undefined,ctorString=Ctor?toSource(Ctor):"";if(ctorString){switch(ctorString){case dataViewCtorString:return dataViewTag$1;case mapCtorString:return mapTag$1;case promiseCtorString:return promiseTag;case setCtorString:return setTag$1;case weakMapCtorString:return weakMapTag$1}}return result}}var getTag$1=getTag;var Uint8Array=root.Uint8Array;var HASH_UNDEFINED$2="__lodash_hash_undefined__";function setCacheAdd(value){this.__data__.set(value,HASH_UNDEFINED$2);return this}function setCacheHas(value){return this.__data__.has(value)}function SetCache(values){var index=-1,length=values==null?0:values.length;this.__data__=new MapCache;while(++index<length){this.add(values[index])}}SetCache.prototype.add=SetCache.prototype.push=setCacheAdd;SetCache.prototype.has=setCacheHas;function arraySome(array,predicate){var index=-1,length=array==null?0:array.length;while(++index<length){if(predicate(array[index],index,array)){return true}}return false}function cacheHas(cache,key){return cache.has(key)}var COMPARE_PARTIAL_FLAG=1,COMPARE_UNORDERED_FLAG=2;function equalArrays(array,other,bitmask,customizer,equalFunc,stack){var isPartial=bitmask&COMPARE_PARTIAL_FLAG,arrLength=array.length,othLength=other.length;if(arrLength!=othLength&&!(isPartial&&othLength>arrLength)){return false}var arrStacked=stack.get(array);var othStacked=stack.get(other);if(arrStacked&&othStacked){return arrStacked==other&&othStacked==array}var index=-1,result=true,seen=bitmask&COMPARE_UNORDERED_FLAG?new SetCache:undefined;stack.set(array,other);stack.set(other,array);while(++index<arrLength){var arrValue=array[index],othValue=other[index];if(customizer){var compared=isPartial?customizer(othValue,arrValue,index,other,array,stack):customizer(arrValue,othValue,index,array,other,stack)}if(compared!==undefined){if(compared){continue}result=false;break}if(seen){if(!arraySome(other,function(othValue,othIndex){if(!cacheHas(seen,othIndex)&&(arrValue===othValue||equalFunc(arrValue,othValue,bitmask,customizer,stack))){return seen.push(othIndex)}})){result=false;break}}else if(!(arrValue===othValue||equalFunc(arrValue,othValue,bitmask,customizer,stack))){result=false;break}}stack["delete"](array);stack["delete"](other);return result}function mapToArray(map){var index=-1,result=Array(map.size);map.forEach(function(value,key){result[++index]=[key,value]});return result}function setToArray(set){var index=-1,result=Array(set.size);set.forEach(function(value){result[++index]=value});return result}var COMPARE_PARTIAL_FLAG$1=1,COMPARE_UNORDERED_FLAG$1=2;var boolTag$1="[object Boolean]",dateTag$1="[object Date]",errorTag$1="[object Error]",mapTag$2="[object Map]",numberTag$1="[object Number]",regexpTag$1="[object RegExp]",setTag$2="[object Set]",stringTag$1="[object String]",symbolTag$1="[object Symbol]";var arrayBufferTag$1="[object ArrayBuffer]",dataViewTag$2="[object DataView]";var symbolProto$1=_Symbol?_Symbol.prototype:undefined,symbolValueOf=symbolProto$1?symbolProto$1.valueOf:undefined;function equalByTag(object,other,tag,bitmask,customizer,equalFunc,stack){switch(tag){case dataViewTag$2:if(object.byteLength!=other.byteLength||object.byteOffset!=other.byteOffset){return false}object=object.buffer;other=other.buffer;case arrayBufferTag$1:if(object.byteLength!=other.byteLength||!equalFunc(new Uint8Array(object),new Uint8Array(other))){return false}return true;case boolTag$1:case dateTag$1:case numberTag$1:return eq(+object,+other);case errorTag$1:return object.name==other.name&&object.message==other.message;case regexpTag$1:case stringTag$1:return object==other+"";case mapTag$2:var convert=mapToArray;case setTag$2:var isPartial=bitmask&COMPARE_PARTIAL_FLAG$1;convert||(convert=setToArray);if(object.size!=other.size&&!isPartial){return false}var stacked=stack.get(object);if(stacked){return stacked==other}bitmask|=COMPARE_UNORDERED_FLAG$1;stack.set(object,other);var result=equalArrays(convert(object),convert(other),bitmask,customizer,equalFunc,stack);stack["delete"](object);return result;case symbolTag$1:if(symbolValueOf){return symbolValueOf.call(object)==symbolValueOf.call(other)}}return false}var COMPARE_PARTIAL_FLAG$2=1;var objectProto$a=Object.prototype;var hasOwnProperty$7=objectProto$a.hasOwnProperty;function equalObjects(object,other,bitmask,customizer,equalFunc,stack){var isPartial=bitmask&COMPARE_PARTIAL_FLAG$2,objProps=getAllKeys(object),objLength=objProps.length,othProps=getAllKeys(other),othLength=othProps.length;if(objLength!=othLength&&!isPartial){return false}var index=objLength;while(index--){var key=objProps[index];if(!(isPartial?key in other:hasOwnProperty$7.call(other,key))){return false}}var objStacked=stack.get(object);var othStacked=stack.get(other);if(objStacked&&othStacked){return objStacked==other&&othStacked==object}var result=true;stack.set(object,other);stack.set(other,object);var skipCtor=isPartial;while(++index<objLength){key=objProps[index];var objValue=object[key],othValue=other[key];if(customizer){var compared=isPartial?customizer(othValue,objValue,key,other,object,stack):customizer(objValue,othValue,key,object,other,stack)}if(!(compared===undefined?objValue===othValue||equalFunc(objValue,othValue,bitmask,customizer,stack):compared)){result=false;break}skipCtor||(skipCtor=key=="constructor")}if(result&&!skipCtor){var objCtor=object.constructor,othCtor=other.constructor;if(objCtor!=othCtor&&"constructor"in object&&"constructor"in other&&!(typeof objCtor=="function"&&objCtor instanceof objCtor&&typeof othCtor=="function"&&othCtor instanceof othCtor)){result=false}}stack["delete"](object);stack["delete"](other);return result}var COMPARE_PARTIAL_FLAG$3=1;var argsTag$2="[object Arguments]",arrayTag$1="[object Array]",objectTag$2="[object Object]";var objectProto$b=Object.prototype;var hasOwnProperty$8=objectProto$b.hasOwnProperty;function baseIsEqualDeep(object,other,bitmask,customizer,equalFunc,stack){var objIsArr=isArray(object),othIsArr=isArray(other),objTag=objIsArr?arrayTag$1:getTag$1(object),othTag=othIsArr?arrayTag$1:getTag$1(other);objTag=objTag==argsTag$2?objectTag$2:objTag;othTag=othTag==argsTag$2?objectTag$2:othTag;var objIsObj=objTag==objectTag$2,othIsObj=othTag==objectTag$2,isSameTag=objTag==othTag;if(isSameTag&&isBuffer(object)){if(!isBuffer(other)){return false}objIsArr=true;objIsObj=false}if(isSameTag&&!objIsObj){stack||(stack=new Stack);return objIsArr||isTypedArray(object)?equalArrays(object,other,bitmask,customizer,equalFunc,stack):equalByTag(object,other,objTag,bitmask,customizer,equalFunc,stack)}if(!(bitmask&COMPARE_PARTIAL_FLAG$3)){var objIsWrapped=objIsObj&&hasOwnProperty$8.call(object,"__wrapped__"),othIsWrapped=othIsObj&&hasOwnProperty$8.call(other,"__wrapped__");if(objIsWrapped||othIsWrapped){var objUnwrapped=objIsWrapped?object.value():object,othUnwrapped=othIsWrapped?other.value():other;stack||(stack=new Stack);return equalFunc(objUnwrapped,othUnwrapped,bitmask,customizer,stack)}}if(!isSameTag){return false}stack||(stack=new Stack);return equalObjects(object,other,bitmask,customizer,equalFunc,stack)}function baseIsEqual(value,other,bitmask,customizer,stack){if(value===other){return true}if(value==null||other==null||!isObjectLike(value)&&!isObjectLike(other)){return value!==value&&other!==other}return baseIsEqualDeep(value,other,bitmask,customizer,baseIsEqual,stack)}var COMPARE_PARTIAL_FLAG$4=1,COMPARE_UNORDERED_FLAG$2=2;function baseIsMatch(object,source,matchData,customizer){var index=matchData.length,length=index,noCustomizer=!customizer;if(object==null){return!length}object=Object(object);while(index--){var data=matchData[index];if(noCustomizer&&data[2]?data[1]!==object[data[0]]:!(data[0]in object)){return false}}while(++index<length){data=matchData[index];var key=data[0],objValue=object[key],srcValue=data[1];if(noCustomizer&&data[2]){if(objValue===undefined&&!(key in object)){return false}}else{var stack=new Stack;if(customizer){var result=customizer(objValue,srcValue,key,object,source,stack)}if(!(result===undefined?baseIsEqual(srcValue,objValue,COMPARE_PARTIAL_FLAG$4|COMPARE_UNORDERED_FLAG$2,customizer,stack):result)){return false}}}return true}function isStrictComparable(value){return value===value&&!isObject$1(value)}function getMatchData(object){var result=keys(object),length=result.length;while(length--){var key=result[length],value=object[key];result[length]=[key,value,isStrictComparable(value)]}return result}function matchesStrictComparable(key,srcValue){return function(object){if(object==null){return false}return object[key]===srcValue&&(srcValue!==undefined||key in Object(object))}}function baseMatches(source){var matchData=getMatchData(source);if(matchData.length==1&&matchData[0][2]){return matchesStrictComparable(matchData[0][0],matchData[0][1])}return function(object){return object===source||baseIsMatch(object,source,matchData)}}function baseHasIn(object,key){return object!=null&&key in Object(object)}function hasPath(object,path,hasFunc){path=castPath(path,object);var index=-1,length=path.length,result=false;while(++index<length){var key=toKey(path[index]);if(!(result=object!=null&&hasFunc(object,key))){break}object=object[key]}if(result||++index!=length){return result}length=object==null?0:object.length;return!!length&&isLength(length)&&isIndex(key,length)&&(isArray(object)||isArguments(object))}function hasIn(object,path){return object!=null&&hasPath(object,path,baseHasIn)}var COMPARE_PARTIAL_FLAG$5=1,COMPARE_UNORDERED_FLAG$3=2;function baseMatchesProperty(path,srcValue){if(isKey(path)&&isStrictComparable(srcValue)){return matchesStrictComparable(toKey(path),srcValue)}return function(object){var objValue=get(object,path);return objValue===undefined&&objValue===srcValue?hasIn(object,path):baseIsEqual(srcValue,objValue,COMPARE_PARTIAL_FLAG$5|COMPARE_UNORDERED_FLAG$3)}}function baseProperty(key){return function(object){return object==null?undefined:object[key]}}function basePropertyDeep(path){return function(object){return baseGet(object,path)}}function property(path){return isKey(path)?baseProperty(toKey(path)):basePropertyDeep(path)}function baseIteratee(value){if(typeof value=="function"){return value}if(value==null){return identity}if(_typeof(value)=="object"){return isArray(value)?baseMatchesProperty(value[0],value[1]):baseMatches(value)}return property(value)}function createBaseFor(fromRight){return function(object,iteratee,keysFunc){var index=-1,iterable=Object(object),props=keysFunc(object),length=props.length;while(length--){var key=props[fromRight?length:++index];if(iteratee(iterable[key],key,iterable)===false){break}}return object}}var baseFor=createBaseFor();function baseForOwn(object,iteratee){return object&&baseFor(object,iteratee,keys)}function createBaseEach(eachFunc,fromRight){return function(collection,iteratee){if(collection==null){return collection}if(!isArrayLike(collection)){return eachFunc(collection,iteratee)}var length=collection.length,index=fromRight?length:-1,iterable=Object(collection);while(fromRight?index--:++index<length){if(iteratee(iterable[index],index,iterable)===false){break}}return collection}}var baseEach=createBaseEach(baseForOwn);function castFunction(value){return typeof value=="function"?value:identity}function forEach(collection,iteratee){var func=isArray(collection)?arrayEach:baseEach;return func(collection,castFunction(iteratee))}function baseMap(collection,iteratee){var index=-1,result=isArrayLike(collection)?Array(collection.length):[];baseEach(collection,function(value,key,collection){result[++index]=iteratee(value,key,collection)});return result}function map(collection,iteratee){var func=isArray(collection)?arrayMap:baseMap;return func(collection,baseIteratee(iteratee))}function _typeof$1(obj){if(typeof Symbol==="function"&&_typeof(Symbol.iterator)==="symbol"){_typeof$1=function _typeof$1(obj){return _typeof(obj)}}else{_typeof$1=function _typeof$1(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":_typeof(obj)}}return _typeof$1(obj)}function boundMethod(target,key,descriptor){var fn=descriptor.value;if(typeof fn!=="function"){throw new TypeError("@boundMethod decorator can only be applied to methods not: ".concat(_typeof$1(fn)))}var definingProperty=false;return{configurable:true,get:function get(){if(definingProperty||this===target.prototype||this.hasOwnProperty(key)||typeof fn!=="function"){return fn}var boundFn=fn.bind(this);definingProperty=true;Object.defineProperty(this,key,{configurable:true,get:function get(){return boundFn},set:function set(value){fn=value;delete this[key]}});definingProperty=false;return boundFn},set:function set(value){fn=value}}}function boundClass(target){var keys;if(typeof Reflect!=="undefined"&&typeof Reflect.ownKeys==="function"){keys=Reflect.ownKeys(target.prototype)}else{keys=Object.getOwnPropertyNames(target.prototype);if(typeof Object.getOwnPropertySymbols==="function"){keys=keys.concat(Object.getOwnPropertySymbols(target.prototype))}}keys.forEach(function(key){if(key==="constructor"){return}var descriptor=Object.getOwnPropertyDescriptor(target.prototype,key);if(typeof descriptor.value==="function"){Object.defineProperty(target.prototype,key,boundMethod(target,key,descriptor))}});return target}function autobind(){if(arguments.length===1){return boundClass.apply(void 0,arguments)}return boundMethod.apply(void 0,arguments)}function getMiddleLatLngByLngLat(map,p1,p2){var pos1=p1.pos;var pos2=p2.pos;if(map){return map.coordsToLngLat([(pos1[0]+pos2[0])/2,(pos1[1]+pos2[1])/2])}}var callbacks=[];document.addEventListener("keydown",function(e){for(var i=0,len=callbacks.length;i<len;i++){var cb=callbacks[i];try{cb(e)}catch(error){console.log(error)}}});function onKeyDown(cb){if(callbacks.indexOf(cb)<0){callbacks.push(cb)}}function isLngLat(obj){return obj.className==="AMap.LngLat"}function jsonLngLatData(originData){if(isLngLat(originData)){return[originData.getLng(),originData.getLat()]}else if(Array.isArray(originData)){var data=originData.slice(0);for(var i=0;i<data.length;i+=1){data[i]=jsonLngLatData(data[i])}return data}else{return originData}}function isNumber$1(obj){var tmp=+obj;return typeof+tmp==="number"&&!isNaN(tmp)}function isNumberArray(obj){return Array.isArray(obj)&&isNumber$1(obj[0])}function isNumberArrayArray(obj){return Array.isArray(obj)&&isNumberArray(obj[0])}function isNumberArrayArrayArray(obj){return Array.isArray(obj)&&isNumberArrayArray(obj[0])}function isNumberArrayArrayArrayArray(obj){return Array.isArray(obj)&&isNumberArrayArrayArray(obj[0])}function multiPolygonJson(originPath){var jsonPath=jsonLngLatData(originPath);if(isNumberArrayArray(jsonPath)){jsonPath=[[jsonPath]]}else if(isNumberArrayArrayArray(jsonPath)){jsonPath=[jsonPath]}else if(isNumberArrayArrayArrayArray(jsonPath)){jsonPath=jsonPath}else{return undefined}return jsonPath}var EnumSingleRingEvent;(function(EnumSingleRingEvent){EnumSingleRingEvent["adjust"]="adjust";EnumSingleRingEvent["add"]="add";EnumSingleRingEvent["removenode"]="removenode";EnumSingleRingEvent["addnode"]="addnode";EnumSingleRingEvent["end"]="end";EnumSingleRingEvent["change"]="change";EnumSingleRingEvent["pointmouseover"]="pointmouseover";EnumSingleRingEvent["pointmouseout"]="pointmouseout"})(EnumSingleRingEvent||(EnumSingleRingEvent={}));var SingleRingList=function(_AMap$Event){_inherits(SingleRingList,_AMap$Event);var _super=_createSuper(SingleRingList);function SingleRingList(path,_opt,parent){var _this;_classCallCheck(this,SingleRingList);_this=_super.call(this);_this.path=path;_this._opt=_opt;_this.parent=parent;_this.editingVertexMarkerList=[];_this.editingMidTipMarkerList=[];_this.movePoint={};_this.destroyed=false;_this.handleVertexMouseOver=_this.handleVertexMouseOver.bind(_assertThisInitialized(_this));_this.handleVertexMouseOut=_this.handleVertexMouseOut.bind(_assertThisInitialized(_this));_this.handleMidVertexMouseOver=_this.handleMidVertexMouseOver.bind(_assertThisInitialized(_this));_this.handleMidVertexMouseOut=_this.handleMidVertexMouseOut.bind(_assertThisInitialized(_this));return _this}_createClass(SingleRingList,[{key:"defaultMarkerOpt",get:function get(){return this.parent.defaultMarkerOpt}},{key:"controlPoint",get:function get(){return this.parent.controlPoint}},{key:"editingPolyObj",get:function get(){return this.parent.editingPolyObj}},{key:"map",get:function get(){return this.parent.map}},{key:"adsorb",get:function get(){return this.parent.adsorb}},{key:"adsorbPolygons",get:function get(){return this.parent.adsorbPolygons}},{key:"adsorbDistance",get:function get(){return this.parent.adsorbDistance}},{key:"midControlPoint",get:function get(){return this.parent.midControlPoint}},{key:"createMarker",value:function createMarker(opt){var _opt=this.getMergeMkrOptions(opt);return new AMap.CircleMarker(_opt)}},{key:"deleteChosedItem",value:function deleteChosedItem(e){if(this.editingPolyObj){if(this.chosedPoint){var _this$chosedPoint=this.chosedPoint,marker=_this$chosedPoint.marker,pointIndex=_this$chosedPoint.pointIndex,_point=_this$chosedPoint.point,path=_this$chosedPoint.path,poly=_this$chosedPoint.poly,lnglat=_this$chosedPoint.lnglat,pixel=_this$chosedPoint.pixel,isFirstEqualLast=_this$chosedPoint.isFirstEqualLast;var minPointLimit=isFirstEqualLast?4:3;if(path.length>minPointLimit){path.splice(pointIndex,1);if(isFirstEqualLast){path[path.length-1]=AMap.LngLat.from(path[0])}this.path=path;this.map.remove(marker);this.highLightEditPoly();this.emit(EnumSingleRingEvent.removenode,{target:this.getTarget(),lnglat:_point,pixel:pixel})}else{this.path=[];this.highLightEditPoly();this.emit(EnumSingleRingEvent.removenode,{target:this.getTarget(),lnglat:_point,pixel:pixel})}}}}},{key:"highLightEditPoly",value:function highLightEditPoly(){var _this2=this;if(this.destroyed){return}var poly=this.editingPolyObj.poly;var path=this.path;var pointOnClick=function pointOnClick(chosedObj){var marker=chosedObj.marker;var _markerOpt=_this2.getMergeMkrOptions(_this2.controlPoint);var chosedOpt=_this2.getMergeMkrOptions({radius:3});if(_this2.chosedPoint){var cm=_this2.chosedPoint.marker;cm.setOptions(_markerOpt)}marker.setOptions(chosedOpt);_this2.chosedPoint=chosedObj};this.clearVertexMarkers();var isFirstEqualLast=path.length===0?false:path[0].equals(path[path.length-1]);this.editingVertexMarkerList=map(path,function(pt,pointIndex){var opt=AMap.extend({},_this2.controlPoint,{center:pt});var m=_this2.createMarker(opt);if(pointIndex===path.length-1&&isFirstEqualLast){return m}_this2.map.add(m);m.on("click",function(e){pointOnClick({lnglat:e.lnglat,pixel:e.pixel,marker:m,pointIndex:pointIndex,point:pt,path:path,poly:poly,isFirstEqualLast:isFirstEqualLast});_this2.deleteChosedItem(e)});m.on("dragging",function(e){_this2.clearTipMarkers();var _paths=_this2.getPath();var ll=_this2.getAdjustedPoint(_paths,e2ll(e));path[pointIndex]=ll;if(pointIndex===0&&isFirstEqualLast){path[path.length-1]=ll}_this2.path=path;_this2.emit(EnumSingleRingEvent.change,{target:_this2.getTarget(),pixel:e.pixel,lnglat:e.lnglat})});m.on("dragend",function(e){_this2.initTipMarkers();var _paths=_this2.getPath();var ll=_this2.getAdjustedPoint(_paths,e2ll(e));m.setCenter(ll);path[pointIndex]=ll;if(pointIndex===0&&isFirstEqualLast){path[path.length-1]=ll}_this2.path=path;_this2.emit(EnumSingleRingEvent.adjust,{target:_this2.getTarget(),pixel:e.pixel,lnglat:e.lnglat})});m.on("mouseover",_this2.handleVertexMouseOver);m.on("mouseout",_this2.handleVertexMouseOut);return m});this.initTipMarkers()}},{key:"getTarget",value:function getTarget(){return this.editingPolyObj&&this.editingPolyObj.poly}},{key:"getMergeMkrOptions",value:function getMergeMkrOptions(opt){var _opt=AMap.extend({},this.defaultMarkerOpt,opt);_opt.radius*=1;return _opt}},{key:"close",value:function close(){this.clearVertexMarkers();this.clearTipMarkers();this.emit("end",{target:this.getTarget()})}},{key:"clearVertexMarkers",value:function clearVertexMarkers(){var _this3=this;this.editingVertexMarkerList&&this.editingVertexMarkerList.forEach(function(mk){mk.clearEvents();_this3.map.remove(mk)});this.editingVertexMarkerList=[]}},{key:"initTipMarkers",value:function initTipMarkers(){var _this4=this;var path=this.path;var isFirstEqualLast=path.length===0?false:path[0].equals(path[path.length-1]);this.clearTipMarkers();var _loop=function _loop(i){if(i===path.length-1&&isFirstEqualLast){return"continue"}var cur=path[i];var next=i===path.length-1?path[0]:path[i+1];var midll=getMiddleLatLngByLngLat(_this4.map,cur,next);var opt=AMap.extend({},_this4.midControlPoint,{zIndex:999997,center:midll,bubble:false,draggable:true});var m=_this4.createMarker(opt);_this4.map.add(m);m.on("dragstart",function(e){if(_this4.destroyed){return}var breakPoint=midll;var breakIndex=i;var lnglat=breakPoint;var path=_this4.path;var index=breakIndex+1;path.splice(index,0,lnglat);_this4.path=path;var option=_this4.getMergeMkrOptions(_this4.controlPoint);m.setOptions(option)});m.on("dragging",function(e){if(_this4.destroyed){return}_this4.path;var _paths=_this4.getPath();var ll=_this4.getAdjustedPoint(_paths,e2ll(e));var pointIndex=i+1;path[pointIndex]=ll;_this4.path=path;_this4.emit(EnumSingleRingEvent.change,{target:_this4.getTarget(),pixel:e.pixel,lnglat:e.lnglat})});m.on("dragend",function(e){if(_this4.destroyed){return}_this4.handleMidVertexMouseOut({target:_this4.getTarget(),pixel:e.pixel,lnglat:e.lnglat});_this4.highLightEditPoly();_this4.emit("addnode",{target:_this4.getTarget(),pixel:e.pixel,lnglat:e.lnglat})});m.on("mouseover",_this4.handleMidVertexMouseOver);m.on("mouseout",_this4.handleMidVertexMouseOut);_this4.editingMidTipMarkerList.push(m)};for(var i=0;i<path.length;i++){var _ret=_loop(i);if(_ret==="continue")continue}}},{key:"clearTipMarkers",value:function clearTipMarkers(){var _this5=this;this.editingMidTipMarkerList&&this.editingMidTipMarkerList.forEach(function(mk){mk.clearEvents();_this5.map.remove(mk)});this.editingMidTipMarkerList=[]}},{key:"getPointOnLine",value:function getPointOnLine(_paths,ll){_paths.forEach(function(path){if(path.length>2&&path[0]!==path[path.length-1]){path.push(path[0])}});var mvPt=[ll.lng,ll.lat];var lines=multiLineString(_paths);var pt=point(mvPt);var _nearestPointOnLine=nearestPointOnLine(lines,pt,{units:"kilometers"}),linePt=_nearestPointOnLine.geometry.coordinates,properties=_nearestPointOnLine.properties;return{point:linePt,properties:properties}}},{key:"getAdjustedPoint",value:function getAdjustedPoint(_paths,ll){var ajustPt=ll;if(this.adsorb&&_paths&&_paths.length>0){var mvPt=[ll.lng,ll.lat];var allPoints=_paths.reduce(function(pre,n){return pre.concat(n)});var _this$getPointOnLine=this.getPointOnLine(_paths,ll),linePt=_this$getPointOnLine.point;var _this$adsorbDistance=this.adsorbDistance,lAbPx=_this$adsorbDistance.line,vAbPx=_this$adsorbDistance.point;var nearVPt=getNearestPoint(mvPt,allPoints);if(!nearVPt){return ajustPt}var vDist=getPixelDistance(this.map,[nearVPt.point,mvPt]);var linePtDist=getPixelDistance(this.map,[linePt,mvPt]);if(vDist<vAbPx){var refLoc=new AMap.LngLat(nearVPt.point[0],nearVPt.point[1]);ajustPt=refLoc}else{if(linePtDist<lAbPx){var _refLoc=new AMap.LngLat(linePt[0],linePt[1]);ajustPt=_refLoc}}}return ajustPt}},{key:"getPath",value:function getPath(){var _this6=this;var result=[];forEach(this.adsorbPolygons,function(p){if(!_this6.editingPolyObj){return}if(p===_this6.editingPolyObj.poly){return}var path=p.getPath();var jsonPath=multiPolygonJson(jsonLngLatData(path));if(!jsonPath){return}var _iterator=_createForOfIteratorHelper(jsonPath),_step;try{for(_iterator.s();!(_step=_iterator.n()).done;){var poly=_step.value;var _iterator2=_createForOfIteratorHelper(poly),_step2;try{for(_iterator2.s();!(_step2=_iterator2.n()).done;){var ring=_step2.value;result.push(ring)}}catch(err){_iterator2.e(err)}finally{_iterator2.f()}}}catch(err){_iterator.e(err)}finally{_iterator.f()}});return result}},{key:"destroy",value:function destroy(){this.clearVertexMarkers();this.clearTipMarkers();this.destroyed=true}},{key:"handleVertexMouseOver",value:function handleVertexMouseOver(e){if(this.destroyed){return}this.emit(EnumSingleRingEvent.pointmouseover,{target:e.target,lnglat:e.lnglat,pixel:e.pixel,markerType:"vertex"})}},{key:"handleVertexMouseOut",value:function handleVertexMouseOut(e){if(this.destroyed){return}this.emit(EnumSingleRingEvent.pointmouseout,{target:e.target,lnglat:e.lnglat,pixel:e.pixel,markerType:"vertex"})}},{key:"handleMidVertexMouseOver",value:function handleMidVertexMouseOver(e){if(this.destroyed){return}this.emit(EnumSingleRingEvent.pointmouseover,{target:e.target,lnglat:e.lnglat,pixel:e.pixel,markerType:"middle"})}},{key:"handleMidVertexMouseOut",value:function handleMidVertexMouseOut(e){if(this.destroyed){return}this.emit(EnumSingleRingEvent.pointmouseout,{lnglat:e.lnglat,pixel:e.pixel,target:e.target,markerType:"middle"})}},{key:"syncPath",value:function syncPath(){var path=[];var _iterator3=_createForOfIteratorHelper(this.editingVertexMarkerList),_step3;try{for(_iterator3.s();!(_step3=_iterator3.n()).done;){var marker=_step3.value;if(!marker.getMap()){var first=this.editingVertexMarkerList[0];if(first){path.push(first.getCenter())}continue}var coord=marker.getCenter();path.push(coord)}}catch(err){_iterator3.e(err)}finally{_iterator3.f()}this.path=path;this.initTipMarkers()}}]);return SingleRingList}(AMap.Event);var SingleRingListHandle=function(){function SingleRingListHandle(parent){_classCallCheck(this,SingleRingListHandle);this.parent=parent;this.list=[]}_createClass(SingleRingListHandle,[{key:"updatePath",value:function updatePath(path,_opt){if(isNumberArrayArray(path)){this.type="Ring";this.list=new SingleRingList(AMap.Util.parseLngLatData(path),_opt,this.parent)}else if(isNumberArrayArrayArray(path)){this.type="Polygon";var _iterator=_createForOfIteratorHelper(path),_step;try{for(_iterator.s();!(_step=_iterator.n()).done;){var ring=_step.value;this.list.push(new SingleRingList(AMap.Util.parseLngLatData(ring),_opt,this.parent))}}catch(err){_iterator.e(err)}finally{_iterator.f()}}else if(isNumberArrayArrayArrayArray(path)){this.type="Multipolygon";var _iterator2=_createForOfIteratorHelper(path),_step2;try{for(_iterator2.s();!(_step2=_iterator2.n()).done;){var poly=_step2.value;var polyArray=[];var _iterator3=_createForOfIteratorHelper(poly),_step3;try{for(_iterator3.s();!(_step3=_iterator3.n()).done;){var _ring=_step3.value;polyArray.push(new SingleRingList(AMap.Util.parseLngLatData(_ring),_opt,this.parent))}}catch(err){_iterator3.e(err)}finally{_iterator3.f()}this.list.push(polyArray)}}catch(err){_iterator2.e(err)}finally{_iterator2.f()}}else{this.type="Error";console.log("WARING: Polygon has no path")}}},{key:"forEach",value:function forEach(cb){switch(this.type){case"Ring":cb(this.list);break;case"Polygon":var _iterator4=_createForOfIteratorHelper(this.list),_step4;try{for(_iterator4.s();!(_step4=_iterator4.n()).done;){var singleRing=_step4.value;cb(singleRing)}}catch(err){_iterator4.e(err)}finally{_iterator4.f()}break;case"Multipolygon":{var _iterator5=_createForOfIteratorHelper(this.list),_step5;try{for(_iterator5.s();!(_step5=_iterator5.n()).done;){var poly=_step5.value;var _iterator6=_createForOfIteratorHelper(poly),_step6;try{for(_iterator6.s();!(_step6=_iterator6.n()).done;){var ring=_step6.value;cb(ring)}}catch(err){_iterator6.e(err)}finally{_iterator6.f()}}}catch(err){_iterator5.e(err)}finally{_iterator5.f()}break}}}},{key:"getPath",value:function getPath(){switch(this.type){case"Ring":return this.list.path;case"Polygon":var polyPath=[];var _iterator7=_createForOfIteratorHelper(this.list),_step7;try{for(_iterator7.s();!(_step7=_iterator7.n()).done;){var singleRing=_step7.value;var ringPath=singleRing.path;if(ringPath&&ringPath.length>0){polyPath.push(ringPath)}}}catch(err){_iterator7.e(err)}finally{_iterator7.f()}return polyPath;case"Multipolygon":var multipolyPath=[];var _iterator8=_createForOfIteratorHelper(this.list),_step8;try{for(_iterator8.s();!(_step8=_iterator8.n()).done;){var poly=_step8.value;var _polyPath=[];var _iterator9=_createForOfIteratorHelper(poly),_step9;try{for(_iterator9.s();!(_step9=_iterator9.n()).done;){var ring=_step9.value;var _ringPath=ring.path;if(_ringPath&&_ringPath.length>0){_polyPath.push(_ringPath)}}}catch(err){_iterator9.e(err)}finally{_iterator9.f()}multipolyPath.push(_polyPath)}}catch(err){_iterator8.e(err)}finally{_iterator8.f()}return multipolyPath}}},{key:"clear",value:function clear(){this.type="Error";this.list=[]}}]);return SingleRingListHandle}();var __decorate=undefined&&undefined.__decorate||function(decorators,target,key,desc){var c=arguments.length,r=c<3?target:desc===null?desc=Object.getOwnPropertyDescriptor(target,key):desc,d;if((typeof Reflect==="undefined"?"undefined":_typeof(Reflect))==="object"&&typeof Reflect.decorate==="function")r=Reflect.decorate(decorators,target,key,desc);else for(var i=decorators.length-1;i>=0;i--)if(d=decorators[i])r=(c<3?d(r):c>3?d(target,key,r):d(target,key))||r;return c>3&&r&&Object.defineProperty(target,key,r),r};var isMobile=AMap.Browser.mobile;var amplify=1;var createOptions={zIndex:50,strokeColor:"#FF33FF",strokeOpacity:.2,strokeWeight:6,strokeStyle:"solid",bubble:false,fillColor:"#1791fc",fillOpacity:.4};var defaultOpt={createOptions:createOptions,adsorbPolygons:[],adsorb:true,editable:false,drawable:false,overlap:false,adsorbDistance:{line:10,point:15},allBubble:true,editOptions:{fillOpacity:.3,cursor:"pointer",strokeWeight:4,strokeStyle:"solid",strokeColor:"#1791fc",strokeOpacity:.8}};var statusRunTimeOpst={constructor:{time:0,highResTime:0},setTarget:{time:0,highResTime:0},open:{time:0,highResTime:0}};var PolygonEditor=function(_AMap$Event){_inherits(PolygonEditor,_AMap$Event);var _super=_createSuper(PolygonEditor);function PolygonEditor(map,target){var _this;var opt=arguments.length>2&&arguments[2]!==undefined?arguments[2]:{};_classCallCheck(this,PolygonEditor);_this=_super.call(this);_this.isOpenStatus=false;_this.singleRingList=[];_this.singleRingListHandle=new SingleRingListHandle(_assertThisInitialized(_this));_this.movePoint={};_this._editing=false;_this.className="PolygonEditor";_this.GRAPH_NAME="Polygon";_this.onAddPick=_this.onAddPick.bind(_assertThisInitialized(_this));_this.onAddingMouseMove=_this.onAddingMouseMove.bind(_assertThisInitialized(_this));_this.open=_this.open.bind(_assertThisInitialized(_this));_this.close=_this.close.bind(_assertThisInitialized(_this));_this.OPEN_STATUS=false;_this._opt=AMap.extend(defaultOpt,opt,{bubble:false});var _this$_opt=_this._opt,originPaths=_this$_opt.paths,adsorbPolygons=_this$_opt.adsorbPolygons,adsorb=_this$_opt.adsorb,editable=_this$_opt.editable,drawable=_this$_opt.drawable,adsorbDistance=_this$_opt.adsorbDistance,overlap=_this$_opt.overlap;if(!map){console.log("ERROR: no map");return _possibleConstructorReturn(_this)}_this.map=map;_this.drawable=drawable;_this.editable=editable;_this.adsorb=adsorb;_this.adsorbDistance=adsorbDistance;_this.overlap=overlap;_this.adsorbPolygons=adsorbPolygons||[];_this.originPaths=originPaths;_this.editingVertexMarkerList=[];_this.editingMidTipMarkerList=[];_this.addingPoly=null;_this.showTipMarker=true;_this.editingPolyObj=target&&{poly:target}||null;_this.defaultMarkerOpt={zIndex:999998,bubble:false,cursor:"pointer",clickable:true,draggable:true,radius:isMobile?6:6,strokeColor:"#1791fc",strokeWeight:isMobile?6:2,strokeOpacity:isMobile?.2:1,fillColor:"white",fillOpacity:1,innerOverlay:true};_this.midControlPoint=AMap.extend({zIndex:999999,bubble:false,cursor:"pointer",clickable:true,radius:6,strokeColor:"white",strokeWeight:isMobile?6:2,strokeOpacity:isMobile?.6:1,fillColor:"#1791fc",fillOpacity:1,innerOverlay:true},opt.midControlPoint||{});_this.controlPoint=AMap.extend({draggable:true,cursor:"pointer",bubble:false,zIndex:999999,innerOverlay:true},opt.controlPoint||{});_this.movePoint=AMap.extend({bubble:true,innerOverlay:true},opt.controlPoint||{});_this.defaultCursor=map.getDefaultCursor();onKeyDown(_this.onHandleKeydown.bind(_assertThisInitialized(_this)));_this.mvPickMarker=_this.createMarker(AMap.extend({center:new AMap.LngLat(0,0),bubble:true,innerOverlay:true},_this.movePoint));_this["mvPickMarker"].hide();_this.map.add(_this.mvPickMarker);_this._handleRingChange=_this._handleRingChange.bind(_assertThisInitialized(_this));_this._handleRingAdjust=_this._handleRingAdjust.bind(_assertThisInitialized(_this));_this._handleRingAddnode=_this._handleRingAddnode.bind(_assertThisInitialized(_this));_this._handleRingRemovenode=_this._handleRingRemovenode.bind(_assertThisInitialized(_this));_this._statusRunTime=statusRunTimeOpst;var time=(new Date).getTime();var highResTime=0;if("performance"in window&&typeof performance.now==="function"){highResTime=performance.now()}_this._statusRunTime.constructor={time:time,highResTime:highResTime};_this.draggListener();return _this}_createClass(PolygonEditor,[{key:"CLASS_NAME",get:function get(){return this.className}},{key:"onMapDblclick",value:function onMapDblclick(e){if(this.drawable){this.finishAddingPolygon(false,e)}}},{key:"draggListener",value:function draggListener(){if(this.editingPolyObj){if(this.isOpenStatus&&this.editingPolyObj.poly){this.editingPolyObj.poly.on("dragstart",this.close);this.editingPolyObj.poly.on("dragend",this.open)}}}},{key:"onMapRightclick",value:function onMapRightclick(e){if(this.drawable){this.finishAddingPolygon(true,e)}}},{key:"editPoly",value:function editPoly(){var _this2=this;this.mvPickMarker.hide();this.chosedPoint=null;var poly=this.editingPolyObj.poly;if(poly){var path=poly.getPath();this.editingPolyObj.origin_path=path;var opt=poly.getOptions();delete opt.path;delete opt.map;this.editingPolyObj.origin_options=opt;var jsonPath=jsonLngLatData(path);this.singleRingListHandle.updatePath(jsonPath,opt);this.singleRingListHandle.forEach(function(list){list.highLightEditPoly();_this2.bindListen(list)});var style=this._opt.editOptions||{fillColor:"#f00",fillOpacity:1};var editOpt=AMap.extend({},this._opt,style);poly.setOptions(editOpt)}}},{key:"getPathFromSingleRings",value:function getPathFromSingleRings(){return this.singleRingListHandle.getPath()}},{key:"setLayerOptions",value:function setLayerOptions(layer,changeOpt){var opt=layer.getOptions();var _opt=AMap.extend({},opt,changeOpt);layer.setOptions(_opt)}},{key:"getIcon",value:function getIcon(){var size=arguments.length>0&&arguments[0]!==undefined?arguments[0]:[10,10];var icon=new AMap.Icon({size:new AMap.Size(size[0],size[1]),image:"http://webapi.amap.com/images/dd-via.png",imageSize:new AMap.Size(size[0],size[1])});return icon}},{key:"getMergeMkrOptions",value:function getMergeMkrOptions(opt){var _opt=AMap.extend({},this.defaultMarkerOpt,opt);_opt.radius*=amplify;return _opt}},{key:"createMarker",value:function createMarker(opt){var _opt=this.getMergeMkrOptions(opt);return new AMap.CircleMarker(_opt)}},{key:"onAddPick",value:function onAddPick(e){if(!this.drawable)return;if(!this.map){console.log("ERROR: no map");return}var adsorbPt=isMobile?e.lnglat:this.mvPickMarker.getCenter();var insertIndex=0;if(!this.addingPoly){var _path=[[adsorbPt.lng,adsorbPt.lat],[adsorbPt.lng,adsorbPt.lat]];if(isMobile){_path.pop()}var opt=AMap.extend({},this._opt,{bubble:true});this.addingPoly=createPolygon(_path,opt.editOptions);this.map.add(this.addingPoly);this._mapStatusDb=this.map.getStatus().doubleClickZoom;this.map["setStatus"]({doubleClickZoom:false})}else{var arr=this.addingPoly["getPath"]();if(!isMobile){arr.pop();arr.push(adsorbPt)}arr.push(adsorbPt);insertIndex=arr.length-2;this.addingPoly["setPath"](arr)}this.emit("addnode",{target:this.addingPoly,pixel:e.pixel,lnglat:e.lnglat})}},{key:"getPointOnLine",value:function getPointOnLine(_paths,ll){if(this.GRAPH_NAME==="Polygon"){_paths.forEach(function(path){if(path.length>2&&path[0]!==path[path.length-1]){path.push(path[0])}})}var mvPt=[ll.lng,ll.lat];var lines=multiLineString(_paths);var pt=point(mvPt);var _nearestPointOnLine=nearestPointOnLine(lines,pt,{units:"kilometers"}),linePt=_nearestPointOnLine.geometry.coordinates,properties=_nearestPointOnLine.properties;return{point:linePt,properties:properties}}},{key:"onAddingMouseMove",value:function onAddingMouseMove(e){if(!this.drawable)return;var ll=e2ll(e);var _paths=this.getPath();var ajustPt=this.getAdjustedPoint(_paths,ll);if(this.mvPickMarker){this.mvPickMarker.setCenter(ajustPt);if(ajustPt==ll){this.mvPickMarker.hide()}else{this.mvPickMarker.show()}}if(this.addingPoly){var arr=this.addingPoly["getPath"]();arr.pop();arr.push(ajustPt);this.addingPoly["setPath"](arr)}}},{key:"getPolyArrPath",value:function getPolyArrPath(poly){var path=poly.getPath();var _path=map(path,function(loc){return[loc.lng,loc.lat]});return _path}},{key:"getAdjustedPoint",value:function getAdjustedPoint(_paths,ll){var ajustPt=ll;if(this.adsorb&&_paths&&_paths.length>0){var mvPt=[ll.lng,ll.lat];var allPoints=_paths.reduce(function(pre,n){return pre.concat(n)});var _this$getPointOnLine=this.getPointOnLine(_paths,ll),linePt=_this$getPointOnLine.point;var _this$adsorbDistance=this.adsorbDistance,lAbPx=_this$adsorbDistance.line,vAbPx=_this$adsorbDistance.point;var nearVPt=getNearestPoint(mvPt,allPoints);if(!nearVPt){return ajustPt}var vDist=getPixelDistance(this.map,[nearVPt.point,mvPt]);var linePtDist=getPixelDistance(this.map,[linePt,mvPt]);if(this.showTipMarker){var mvp=new AMap.LngLat(mvPt[0],mvPt[1]);this.mvPickMarker.setCenter(mvp)}if(vDist<vAbPx){var refLoc=new AMap.LngLat(nearVPt.point[0],nearVPt.point[1]);ajustPt=refLoc}else{if(linePtDist<lAbPx){var _refLoc=new AMap.LngLat(linePt[0],linePt[1]);ajustPt=_refLoc}}}return ajustPt}},{key:"finishAddingPolygon",value:function finishAddingPolygon(){var stripLast=arguments.length>0&&arguments[0]!==undefined?arguments[0]:false;var e=arguments.length>1?arguments[1]:undefined;if(this.addingPoly){var arr=this.addingPoly["getPath"]();if(stripLast){if(!isMobile){arr.pop()}}else{arr.pop();if(!isMobile){arr.pop()}}if(arr.length>2){this.addingPoly["setPath"](arr);var success=this.tailorPolygonOverlaps();if(success){this.emit("add",{target:this.addingPoly,obj:this.addingPoly,lnglat:e.lnglat,pixel:e.pixel});this.editingPolyObj={poly:this.addingPoly};this.addingPoly=undefined;this.openEdit();this.editingPolyObj.origin_options=this._opt.createOptions}else{alert("您正在编辑的多边形不合规(边不能交叉),请重新添加")}}else{this.cancel()}}if(this.addingPoly){this.drawable=false}else{this.emit("cancel",{lnglat:e.lnglat,pixel:e.pixel})}}},{key:"getClosePath",value:function getClosePath(path){var last=path[path.length-1];if(last&&last!==path[0]){return path.concat([path[0]])}else{return path}}},{key:"tailorPolygonOverlaps",value:function tailorPolygonOverlaps(){return true}},{key:"getPolygons",value:function getPolygons(){return this.adsorbPolygons}},{key:"getPath",value:function getPath(){var _this3=this;var result=[];forEach(this.adsorbPolygons,function(p){if(!_this3.editingPolyObj){return}if(p===_this3.editingPolyObj.poly){return}var path=p.getPath();var jsonPath=multiPolygonJson(jsonLngLatData(path));if(!jsonPath){return}var _iterator=_createForOfIteratorHelper(jsonPath),_step;try{for(_iterator.s();!(_step=_iterator.n()).done;){var poly=_step.value;var _iterator2=_createForOfIteratorHelper(poly),_step2;try{for(_iterator2.s();!(_step2=_iterator2.n()).done;){var ring=_step2.value;result.push(ring)}}catch(err){_iterator2.e(err)}finally{_iterator2.f()}}}catch(err){_iterator.e(err)}finally{_iterator.f()}});return result}},{key:"addAddListener",value:function addAddListener(){this.map.on("click",this.onAddPick);this.map.on("mousemove",this.onAddingMouseMove);this.map.on("dblclick",this.onMapDblclick);this.map.on("rightclick",this.onMapRightclick)}},{key:"removeAddListener",value:function removeAddListener(){this.map.off("click",this.onAddPick);this.map.off("mousemove",this.onAddingMouseMove);this.map.off("dblclick",this.onMapDblclick);this.map.off("rightclick",this.onMapRightclick)}},{key:"open",value:function open(cb){if(this.editingPolyObj&&this.editingPolyObj.poly){this.openEdit();if(this.editingPolyObj.poly._opts.draggable){this.isOpenStatus=true}this.draggListener()}else{this.openAdd()}var time=(new Date).getTime();var highResTime=0;if("performance"in window&&typeof performance.now==="function"){highResTime=performance.now()}this._statusRunTime.open={time:time,highResTime:highResTime};if(typeof cb==="function"){cb()}}},{key:"setTarget",value:function setTarget(tar,cb){this.close();this._opt.target=tar;this.editingPolyObj={poly:tar};var time=(new Date).getTime();var highResTime=0;if("performance"in window&&typeof performance.now==="function"){highResTime=performance.now()}this._statusRunTime.setTarget={time:time,highResTime:highResTime};if(cb){cb()}}},{key:"getStatus",value:function getStatus(){return this._statusRunTime}},{key:"getTarget",value:function getTarget(){return this.editingPolyObj&&this.editingPolyObj.poly}},{key:"openAdd",value:function openAdd(){this.closeEdit();this.drawable=true;this.map.setDefaultCursor("crosshair");this.addAddListener();this.setAllBubble()}},{key:"setAllBubble",value:function setAllBubble(){if(!this._opt["allBubble"]){return}this._oldBubble=this.map.getStatus().allBubble;this.map.setStatus({allBubble:true})}},{key:"restoreBubble",value:function restoreBubble(){this.map.setStatus({allBubble:this._oldBubble})}},{key:"closeAdd",value:function closeAdd(){this.drawable=false;this.clearAddingPolygon();this.removeAddListener()}},{key:"openEdit",value:function openEdit(){if(this.editable){return}this.closeAdd();this.clearAddingPolygon();this.editable=true;this.map.setDefaultCursor(this.defaultCursor);this.editPoly();this.setAllBubble()}},{key:"closeEdit",value:function closeEdit(){this.editable=false;this.clearEditingPolyStatus();this.map.setDefaultCursor(this.defaultCursor)}},{key:"clearAddingPolygon",value:function clearAddingPolygon(){if(this.addingPoly){this.map.remove(this.addingPoly)}this.addingPoly=null}},{key:"clearEditingPolyStatus",value:function clearEditingPolyStatus(){var _this4=this;if(this.editingPolyObj&&this.editingPolyObj.poly){var _this$editingPolyObj=this.editingPolyObj,poly=_this$editingPolyObj.poly,origin_options=_this$editingPolyObj.origin_options;if(poly){origin_options&&poly.setOptions(origin_options);delete poly.origin_options}}this.singleRingListHandle.forEach(function(list){list.destroy();_this4.unbindListen(list)});this.singleRingListHandle.clear()}},{key:"setAdsorbPolygons",value:function setAdsorbPolygons(list){this.clearAdsorbPolygons();this.addAdsorbPolygons(list)}},{key:"clearAdsorbPolygons",value:function clearAdsorbPolygons(){this.adsorbPolygons=[]}},{key:"addAdsorbPolygons",value:function addAdsorbPolygons(list){if(!Array.isArray(list)){list=[list]}Array.prototype.push.apply(this.adsorbPolygons,list)}},{key:"removeAdsorbPolygons",value:function removeAdsorbPolygons(list){if(!Array.isArray(list)){list=[list]}for(var i=0,len=list.length;i<len;i++){var item=list[i];var index=this.adsorbPolygons.indexOf(item);if(index>=0){this.adsorbPolygons.splice(index,1)}}}},{key:"close",value:function close(){this.map.setDefaultCursor(this.defaultCursor);if(!this.isOpenStatus&&this.editingPolyObj&&this.editingPolyObj.poly){this.editingPolyObj.poly.off("dragstart",this.close);this.editingPolyObj.poly.off("dragend",this.open)}this.isOpenStatus=false;this.clearAddingPolygon();this.closeAdd();this.closeEdit();this.editingPolyObj={poly:this.editingPolyObj&&this.editingPolyObj.poly};this.mvPickMarker.hide();this.OPEN_STATUS=false;this.restoreBubble();if(!this.editingPolyObj.poly){return}this.emit("end",{target:this.getTarget()})}},{key:"onHandleKeydown",value:function onHandleKeydown(e){if(e.key==="Escape"){this.cancel()}}},{key:"cancel",value:function cancel(){if(this.addingPoly){this.map.remove(this.addingPoly);this.addingPoly=undefined;this.emit("cancel",{})}}},{key:"bindListen",value:function bindListen(ring){ring.on(EnumSingleRingEvent.change,this._handleRingChange);ring.on(EnumSingleRingEvent.adjust,this._handleRingAdjust);ring.on(EnumSingleRingEvent.addnode,this._handleRingAddnode);ring.on(EnumSingleRingEvent.removenode,this._handleRingRemovenode);ring.on(EnumSingleRingEvent.pointmouseout,this._handlePointMouseOut);ring.on(EnumSingleRingEvent.pointmouseover,this._handlePointMouseOver)}},{key:"syncPath",value:function syncPath(){this.singleRingListHandle.forEach(function(list){list.syncPath()});this.editingPolyObj.poly.setPath(this.getPathFromSingleRings())}},{key:"_handleRingChange",value:function _handleRingChange(e){this.editingPolyObj.poly.setPath(this.getPathFromSingleRings())}},{key:"_handleRingAdjust",value:function _handleRingAdjust(e){this.editingPolyObj.poly.setPath(this.getPathFromSingleRings());this.emit(EnumSingleRingEvent.adjust,e)}},{key:"_handleRingAddnode",value:function _handleRingAddnode(e){this.editingPolyObj.poly.setPath(this.getPathFromSingleRings());this.emit(EnumSingleRingEvent.addnode,e)}},{key:"_handleRingRemovenode",value:function _handleRingRemovenode(e){var path=this.getPathFromSingleRings();this.editingPolyObj.poly.setPath(path);this.emit(EnumSingleRingEvent.removenode,e);if(!path||path.length===0){this.close();this.destroy()}}},{key:"_handlePointMouseOver",value:function _handlePointMouseOver(e){this.emit(EnumSingleRingEvent.pointmouseover,e)}},{key:"_handlePointMouseOut",value:function _handlePointMouseOut(e){this.emit(EnumSingleRingEvent.pointmouseout,e)}},{key:"unbindListen",value:function unbindListen(ring){ring.off(EnumSingleRingEvent.change,this._handleRingChange);ring.off(EnumSingleRingEvent.adjust,this._handleRingAdjust);ring.off(EnumSingleRingEvent.addnode,this._handleRingAddnode);ring.off(EnumSingleRingEvent.removenode,this._handleRingRemovenode);ring.off(EnumSingleRingEvent.pointmouseout,this._handlePointMouseOut);ring.off(EnumSingleRingEvent.pointmouseover,this._handlePointMouseOver)}},{key:"destroy",value:function destroy(){this.singleRingListHandle.forEach(function(ring){return ring.destroy()});this.singleRingListHandle.clear();this.map.remove(this.editingPolyObj.poly);delete this.editingPolyObj.poly}}]);return PolygonEditor}(AMap.Event);__decorate([autobind],PolygonEditor.prototype,"onMapDblclick",null);__decorate([autobind],PolygonEditor.prototype,"onMapRightclick",null);__decorate([autobind],PolygonEditor.prototype,"_handlePointMouseOver",null);__decorate([autobind],PolygonEditor.prototype,"_handlePointMouseOut",null);AMap["PolygonEditor"]=PolygonEditor}(window.AMap); ');_jsload_('AMap.PolylineEditor', '!function(AMap){"use strict";function _typeof(obj){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(obj){return typeof obj}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj},_typeof(obj)}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}}function _defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,_toPropertyKey(descriptor.key),descriptor)}}function _createClass(Constructor,protoProps,staticProps){if(protoProps)_defineProperties(Constructor.prototype,protoProps);if(staticProps)_defineProperties(Constructor,staticProps);Object.defineProperty(Constructor,"prototype",{writable:false});return Constructor}function _inherits(subClass,superClass){if(typeof superClass!=="function"&&superClass!==null){throw new TypeError("Super expression must either be null or a function")}subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,writable:true,configurable:true}});Object.defineProperty(subClass,"prototype",{writable:false});if(superClass)_setPrototypeOf(subClass,superClass)}function _getPrototypeOf(o){_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function _getPrototypeOf(o){return o.__proto__||Object.getPrototypeOf(o)};return _getPrototypeOf(o)}function _setPrototypeOf(o,p){_setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function _setPrototypeOf(o,p){o.__proto__=p;return o};return _setPrototypeOf(o,p)}function _isNativeReflectConstruct(){if(typeof Reflect==="undefined"||!Reflect.construct)return false;if(Reflect.construct.sham)return false;if(typeof Proxy==="function")return true;try{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}));return true}catch(e){return false}}function _assertThisInitialized(self){if(self===void 0){throw new ReferenceError("this hasn\'t been initialised - super() hasn\'t been called")}return self}function _possibleConstructorReturn(self,call){if(call&&(typeof call==="object"||typeof call==="function")){return call}else if(call!==void 0){throw new TypeError("Derived constructors may only return object or undefined")}return _assertThisInitialized(self)}function _createSuper(Derived){var hasNativeReflectConstruct=_isNativeReflectConstruct();return function _createSuperInternal(){var Super=_getPrototypeOf(Derived),result;if(hasNativeReflectConstruct){var NewTarget=_getPrototypeOf(this).constructor;result=Reflect.construct(Super,arguments,NewTarget)}else{result=Super.apply(this,arguments)}return _possibleConstructorReturn(this,result)}}function _unsupportedIterableToArray(o,minLen){if(!o)return;if(typeof o==="string")return _arrayLikeToArray(o,minLen);var n=Object.prototype.toString.call(o).slice(8,-1);if(n==="Object"&&o.constructor)n=o.constructor.name;if(n==="Map"||n==="Set")return Array.from(o);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return _arrayLikeToArray(o,minLen)}function _arrayLikeToArray(arr,len){if(len==null||len>arr.length)len=arr.length;for(var i=0,arr2=new Array(len);i<len;i++)arr2[i]=arr[i];return arr2}function _createForOfIteratorHelper(o,allowArrayLike){var it=typeof Symbol!=="undefined"&&o[Symbol.iterator]||o["@@iterator"];if(!it){if(Array.isArray(o)||(it=_unsupportedIterableToArray(o))||allowArrayLike&&o&&typeof o.length==="number"){if(it)o=it;var i=0;var F=function(){};return{s:F,n:function(){if(i>=o.length)return{done:true};return{done:false,value:o[i++]}},e:function(e){throw e},f:F}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var normalCompletion=true,didErr=false,err;return{s:function(){it=it.call(o)},n:function(){var step=it.next();normalCompletion=step.done;return step},e:function(e){didErr=true;err=e},f:function(){try{if(!normalCompletion&&it.return!=null)it.return()}finally{if(didErr)throw err}}}}function _toPrimitive(input,hint){if(typeof input!=="object"||input===null)return input;var prim=input[Symbol.toPrimitive];if(prim!==undefined){var res=prim.call(input,hint||"default");if(typeof res!=="object")return res;throw new TypeError("@@toPrimitive must return a primitive value.")}return(hint==="string"?String:Number)(input)}function _toPropertyKey(arg){var key=_toPrimitive(arg,"string");return typeof key==="symbol"?key:String(key)}function _typeof$1(obj){if(typeof Symbol==="function"&&_typeof(Symbol.iterator)==="symbol"){_typeof$1=function _typeof$1(obj){return _typeof(obj)}}else{_typeof$1=function _typeof$1(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":_typeof(obj)}}return _typeof$1(obj)}function boundMethod(target,key,descriptor){var fn=descriptor.value;if(typeof fn!=="function"){throw new TypeError("@boundMethod decorator can only be applied to methods not: ".concat(_typeof$1(fn)))}var definingProperty=false;return{configurable:true,get:function get(){if(definingProperty||this===target.prototype||this.hasOwnProperty(key)||typeof fn!=="function"){return fn}var boundFn=fn.bind(this);definingProperty=true;Object.defineProperty(this,key,{configurable:true,get:function get(){return boundFn},set:function set(value){fn=value;delete this[key]}});definingProperty=false;return boundFn},set:function set(value){fn=value}}}function boundClass(target){var keys;if(typeof Reflect!=="undefined"&&typeof Reflect.ownKeys==="function"){keys=Reflect.ownKeys(target.prototype)}else{keys=Object.getOwnPropertyNames(target.prototype);if(typeof Object.getOwnPropertySymbols==="function"){keys=keys.concat(Object.getOwnPropertySymbols(target.prototype))}}keys.forEach(function(key){if(key==="constructor"){return}var descriptor=Object.getOwnPropertyDescriptor(target.prototype,key);if(typeof descriptor.value==="function"){Object.defineProperty(target.prototype,key,boundMethod(target,key,descriptor))}});return target}function autobind(){if(arguments.length===1){return boundClass.apply(void 0,arguments)}return boundMethod.apply(void 0,arguments)}var __decorate=undefined&&undefined.__decorate||function(decorators,target,key,desc){var c=arguments.length,r=c<3?target:desc===null?desc=Object.getOwnPropertyDescriptor(target,key):desc,d;if((typeof Reflect==="undefined"?"undefined":_typeof(Reflect))==="object"&&typeof Reflect.decorate==="function")r=Reflect.decorate(decorators,target,key,desc);else for(var i=decorators.length-1;i>=0;i--)if(d=decorators[i])r=(c<3?d(r):c>3?d(target,key,r):d(target,key))||r;return c>3&&r&&Object.defineProperty(target,key,r),r};var ListEvent;(function(ListEvent){ListEvent["removeNode"]="removenode";ListEvent["addNode"]="addnode";ListEvent["adjust"]="adjust";ListEvent["end"]="end";ListEvent["change"]="change";ListEvent["move"]="move";ListEvent["add"]="add";ListEvent["pointMouseOver"]="pointmouseover";ListEvent["pointMouseOut"]="pointmouseout"})(ListEvent||(ListEvent={}));var PointList=function(_AMap$Event){_inherits(PointList,_AMap$Event);var _super=_createSuper(PointList);function PointList(){var _this;_classCallCheck(this,PointList);_this=_super.apply(this,arguments);_this.length=0;return _this}_createClass(PointList,[{key:"add",value:function add(node){if(!this.head){this.head=node}else{var lastNode=this.head;while(lastNode.next){lastNode=lastNode.next}lastNode.setNext(node);node.setPrev(lastNode)}node.setList(this);this.bindNodeEvent(node);this.length+=1}},{key:"insertBefore",value:function insertBefore(node,origin){origin.prev.setNext(node);node.setPrev(origin.prev);node.setNext(origin);origin.setPrev(node);node.setList(this);this.bindNodeEvent(node);this.length+=1}},{key:"insertAfter",value:function insertAfter(node,origin){origin.next.setPrev(node);node.setNext(origin.next);node.setPrev(origin);origin.setNext(node);node.setList(this);this.bindNodeEvent(node);this.length+=1}},{key:"bindNodeEvent",value:function bindNodeEvent(node){node.on(ListEvent.change,this.handleChange.bind(this));node.on(ListEvent.addNode,this.handleAddNode.bind(this));node.on(ListEvent.adjust,this.handleAdjust.bind(this));node.on(ListEvent.removeNode,this.handleRemoveNode.bind(this));node.on(ListEvent.pointMouseOver,this.handlePointMouseOver);node.on(ListEvent.pointMouseOut,this.handlePointMouseOut)}},{key:"unbindNodeEvent",value:function unbindNodeEvent(node){node.off(ListEvent.change,this.handleChange.bind(this));node.off(ListEvent.addNode,this.handleAddNode.bind(this));node.off(ListEvent.adjust,this.handleAdjust.bind(this));node.off(ListEvent.removeNode,this.handleRemoveNode.bind(this));node.off(ListEvent.pointMouseOver,this.handlePointMouseOver);node.off(ListEvent.pointMouseOut,this.handlePointMouseOut)}},{key:"remove",value:function remove(node){this.unbindNodeEvent(node);if(node.prev){node.prev.setNext(node.next);if(node.next){node.next.setPrev(node.prev)}node.setPrev();node.setNext()}else{this.head=node.next;node.setPrev();if(node.next){node.next.setPrev()}}this.length-=1}},{key:"handlePointMouseOver",value:function handlePointMouseOver(e){this.emit(ListEvent.pointMouseOver,e)}},{key:"handlePointMouseOut",value:function handlePointMouseOut(e){this.emit(ListEvent.pointMouseOut,e)}},{key:"handleChange",value:function handleChange(e){this.emit(ListEvent.change,e)}},{key:"handleAddNode",value:function handleAddNode(e){this.emit(ListEvent.addNode,e)}},{key:"handleRemoveNode",value:function handleRemoveNode(e){this.emit(ListEvent.removeNode,e)}},{key:"handleAdjust",value:function handleAdjust(e){this.emit(ListEvent.adjust,e)}},{key:"forEach",value:function forEach(cb){var p=this.head;while(p){cb(p);p=p.next}}},{key:"destroy",value:function destroy(){var p=this.head;while(p){this.remove(p);p.destroy();p=p.next}}}]);return PointList}(AMap.Event);__decorate([autobind],PointList.prototype,"handlePointMouseOver",null);__decorate([autobind],PointList.prototype,"handlePointMouseOut",null);var AbstractPointListNode=function(_AMap$Event2){_inherits(AbstractPointListNode,_AMap$Event2);var _super2=_createSuper(AbstractPointListNode);function AbstractPointListNode(){var _this2;_classCallCheck(this,AbstractPointListNode);_this2=_super2.apply(this,arguments);_this2.editing=false;return _this2}_createClass(AbstractPointListNode,[{key:"setNext",value:function setNext(next){this.next=next}},{key:"setPrev",value:function setPrev(prev){this.prev=prev}},{key:"setList",value:function setList(list){this.list=list}}]);return AbstractPointListNode}(AMap.Event);function getMiddleLatLng(marker1,marker2){var p1=marker1.getCenter();var p2=marker2.getCenter();var pos1=p1.pos;var pos2=p2.pos;var map=marker1.getMap();if(map){return map.coordsToLngLat([(pos1[0]+pos2[0])/2,(pos1[1]+pos2[1])/2])}else{return p1.divideBy(2,false).add(p2.divideBy(2,false),false)}}var callbacks=[];document.addEventListener("keydown",function(e){for(var i=0,len=callbacks.length;i<len;i++){var cb=callbacks[i];try{cb(e)}catch(error){console.log(error)}}});function isLngLat(obj){return obj.className==="AMap.LngLat"}function jsonLngLatData(originData){if(isLngLat(originData)){return[originData.getLng(),originData.getLat()]}else if(Array.isArray(originData)){var data=originData.slice(0);for(var i=0;i<data.length;i+=1){data[i]=jsonLngLatData(data[i])}return data}else{return originData}}function isNumber(obj){var tmp=+obj;return typeof+tmp==="number"&&!isNaN(tmp)}function isNumberArray(obj){return Array.isArray(obj)&&isNumber(obj[0])}function isNumberArrayArray(obj){return Array.isArray(obj)&&isNumberArray(obj[0])}function isNumberArrayArrayArray(obj){return Array.isArray(obj)&&isNumberArrayArray(obj[0])}var PolylineCreator=function(_AMap$Event){_inherits(PolylineCreator,_AMap$Event);var _super=_createSuper(PolylineCreator);function PolylineCreator(_map){var _this;_classCallCheck(this,PolylineCreator);_this=_super.call(this);_this._map=_map;_this._onMapClick=_this._onMapClick.bind(_assertThisInitialized(_this));_this._onMapMouseMove=_this._onMapMouseMove.bind(_assertThisInitialized(_this));_this._onMapDbClick=_this._onMapDbClick.bind(_assertThisInitialized(_this));_this._onMapRightClick=_this._onMapRightClick.bind(_assertThisInitialized(_this));return _this}_createClass(PolylineCreator,[{key:"open",value:function open(){this._map.on("click",this._onMapClick)}},{key:"close",value:function close(){this._map.off("click",this._onMapClick)}},{key:"_onMapClick",value:function _onMapClick(e){var center=e.lnglat;var resolution=this._map.getResolution();var pos1=center.offset(resolution*-30,0).toJSON();var pos2=center.offset(resolution*30,0).toJSON();var path=[pos1,pos2];this.emit("create",{path:path});this.close()}},{key:"_onMapMouseMove",value:function _onMapMouseMove(){}},{key:"_onMapDbClick",value:function _onMapDbClick(){}},{key:"_onMapRightClick",value:function _onMapRightClick(){}}]);return PolylineCreator}(AMap.Event);var Point=function(_AMap$Event){_inherits(Point,_AMap$Event);var _super=_createSuper(Point);function Point(map,pos){var _this;var opts=arguments.length>2&&arguments[2]!==undefined?arguments[2]:{};_classCallCheck(this,Point);_this=_super.call(this);_this.map=map;_this.pos=pos;_this._markerOptions={draggable:true,radius:AMap.Browser.mobile?6:6,strokeColor:"#1791fc",strokeWeight:AMap.Browser.mobile?6:2,strokeOpacity:AMap.Browser.mobile?.4:1,fillColor:"white",fillOpacity:1,cursor:"pointer",visible:false,zIndex:99999,innerOverlay:true};_this._middleMarkerOptions={draggable:true,radius:6,strokeColor:"white",strokeWeight:AMap.Browser.mobile?6:2,strokeOpacity:AMap.Browser.mobile?.6:1,fillColor:"#1791fc",fillOpacity:1,cursor:"pointer",visible:false,zIndex:99999};if(opts.controlPoint){_this._markerOptions=AMap.extend(_this._markerOptions,opts.controlPoint)}if(opts.controlPoint){_this._middleMarkerOptions=AMap.extend(_this._middleMarkerOptions,opts.midControlPoint)}_this.init();_this.hide();return _this}_createClass(Point,[{key:"init",value:function init(){this.marker=new AMap.CircleMarker(AMap.extend({map:this.map,center:this.pos},this._markerOptions))}},{key:"show",value:function show(){this.marker.show()}},{key:"hide",value:function hide(){this.marker.hide()}},{key:"remove",value:function remove(){this.marker.remove()}},{key:"setMiddle",value:function setMiddle(middle){this.marker.setOptions(middle?this._middleMarkerOptions:this._markerOptions)}}]);return Point}(AMap.Event);var PointWithMarker=function(_AMap$Event2){_inherits(PointWithMarker,_AMap$Event2);var _super2=_createSuper(PointWithMarker);function PointWithMarker(map,pos){var _this2;var controlPoint=arguments.length>2&&arguments[2]!==undefined?arguments[2]:{draggable:true,icon:new AMap.Icon({size:new AMap.Size(11,11),imageOffset:new AMap.Pixel(0,0),image:AMap.getConfig().client+"/images/dd-via.png"}),offset:new AMap.Pixel(-6,-6),cursor:"pointer",zIndex:1e3};_classCallCheck(this,PointWithMarker);_this2=_super2.call(this);_this2.map=map;_this2.pos=pos;_this2.controlPoint=controlPoint;_this2.init();_this2.hide();return _this2}_createClass(PointWithMarker,[{key:"init",value:function init(){this.marker=new AMap.Marker(AMap.extend({map:this.map,position:this.pos,draggable:true,cursor:"pointer",zIndex:1e3,innerOverlay:true},this.controlPoint))}},{key:"show",value:function show(){this.marker.show()}},{key:"hide",value:function hide(){this.marker.hide()}},{key:"remove",value:function remove(){this.marker.remove()}},{key:"updatePosition",value:function updatePosition(pos){this.marker.setPosition(pos)}}]);return PointWithMarker}(AMap.Event);var __decorate$1=undefined&&undefined.__decorate||function(decorators,target,key,desc){var c=arguments.length,r=c<3?target:desc===null?desc=Object.getOwnPropertyDescriptor(target,key):desc,d;if((typeof Reflect==="undefined"?"undefined":_typeof(Reflect))==="object"&&typeof Reflect.decorate==="function")r=Reflect.decorate(decorators,target,key,desc);else for(var i=decorators.length-1;i>=0;i--)if(d=decorators[i])r=(c<3?d(r):c>3?d(target,key,r):d(target,key))||r;return c>3&&r&&Object.defineProperty(target,key,r),r};var PolylinePoint=function(_AbstractPointListNod){_inherits(PolylinePoint,_AbstractPointListNod);var _super=_createSuper(PolylinePoint);function PolylinePoint(map,pos){var _this;var opts=arguments.length>2&&arguments[2]!==undefined?arguments[2]:{};_classCallCheck(this,PolylinePoint);_this=_super.call(this);_this.map=map;_this.pos=pos;_this.editing=false;_this.prevIsMiddle=false;_this._opts=opts;_this.point=new Point(map,pos,opts);_this.middleFlag=false;_this.bindEvents();return _this}_createClass(PolylinePoint,[{key:"bindEvents",value:function bindEvents(){this.point.marker.on("dragstart",this.handleHandleDragStart);this.point.marker.on("dragend",this.handleHandleDragEnd);this.point.marker.on("dragging",this.handleHandleDragging);this.point.marker.on("click",this.handleHandleClick);this.point.marker.on("mouseover",this.handleHandleMouseOver);this.point.marker.on("mouseout",this.handleHandleMouseOut)}},{key:"unbindEvents",value:function unbindEvents(){this.point.marker.off("dragstart",this.handleHandleDragStart);this.point.marker.off("dragend",this.handleHandleDragEnd);this.point.marker.off("dragging",this.handleHandleDragging);this.point.marker.off("click",this.handleHandleClick);this.point.marker.off("mouseover",this.handleHandleMouseOver);this.point.marker.off("mouseout",this.handleHandleMouseOut)}},{key:"handleHandleDragStart",value:function handleHandleDragStart(e){if(!this.list){return}this.editing=true;if(!this.middleFlag){return}this.prevIsMiddle=true;this.handleHandleMouseOut(e);this.setMiddle(false);var prevPos=getMiddleLatLng(this.point.marker,this.prev.point.marker);var nextPos=getMiddleLatLng(this.point.marker,this.next.point.marker);var prev=new PolylinePoint(this.map,prevPos,this._opts);var next=new PolylinePoint(this.map,nextPos,this._opts);this.list.insertBefore(prev,this);this.list.insertAfter(next,this);prev.show();next.show();prev.setMiddle(true);next.setMiddle(true);this.handleHandleMouseOver(e)}},{key:"handleHandleClick",value:function handleHandleClick(e){if(!this.middleFlag){this.destroy();this.emit(ListEvent.removeNode,e)}}},{key:"handleHandleDragging",value:function handleHandleDragging(){if(!this.middleFlag){if(this.prev&&this.prev.prev){var newPos=getMiddleLatLng(this.point.marker,this.prev.prev.point.marker);this.prev.point.marker.setCenter(newPos)}if(this.next&&this.next.next){var _newPos=getMiddleLatLng(this.point.marker,this.next.next.point.marker);this.next.point.marker.setCenter(_newPos)}}this.emit(ListEvent.change)}},{key:"handleHandleDragEnd",value:function handleHandleDragEnd(e){this.editing=false;if(this.prevIsMiddle&&this.list){this.prevIsMiddle=false;this.emit(ListEvent.addNode,e)}else{this.emit(ListEvent.adjust,e)}}},{key:"handleHandleMouseOver",value:function handleHandleMouseOver(e){if(!this.middleFlag){this.emit(ListEvent.pointMouseOver,{target:e.target,lnglat:e.lnglat,pixel:e.pixel,markerType:"vertex"})}else{this.emit(ListEvent.pointMouseOver,{target:e.target,lnglat:e.lnglat,pixel:e.pixel,markerType:"middle"})}}},{key:"handleHandleMouseOut",value:function handleHandleMouseOut(e){if(!this.middleFlag){this.emit(ListEvent.pointMouseOut,{target:e.target,lnglat:e.lnglat,pixel:e.pixel,markerType:"vertex"})}else{this.emit(ListEvent.pointMouseOut,{target:e.target,lnglat:e.lnglat,pixel:e.pixel,markerType:"middle"})}}},{key:"destroy",value:function destroy(){var _a,_b;this.unbindEvents();if(this.middleFlag){if(this.list){this.list.remove(this)}this.point.remove()}else{(_a=this.prev)===null||_a===void 0?void 0:_a.destroy();(_b=this.next)===null||_b===void 0?void 0:_b.destroy();if(this.list){var prev=this.prev;var next=this.next;this.list.remove(this);if(prev&&next){var newPos=getMiddleLatLng(prev.point.marker,next.point.marker);var newMiddleMarker=new PolylinePoint(this.map,newPos,this._opts);newMiddleMarker.setMiddle(true);newMiddleMarker.show();this.list.insertAfter(newMiddleMarker,prev)}}this.point.remove()}}},{key:"show",value:function show(){this.point.show()}},{key:"hide",value:function hide(){this.point.hide()}},{key:"setMiddle",value:function setMiddle(middle){this.middleFlag=middle;this.point.setMiddle(middle)}}]);return PolylinePoint}(AbstractPointListNode);__decorate$1([autobind],PolylinePoint.prototype,"handleHandleDragStart",null);__decorate$1([autobind],PolylinePoint.prototype,"handleHandleClick",null);__decorate$1([autobind],PolylinePoint.prototype,"handleHandleDragging",null);__decorate$1([autobind],PolylinePoint.prototype,"handleHandleDragEnd",null);__decorate$1([autobind],PolylinePoint.prototype,"handleHandleMouseOver",null);__decorate$1([autobind],PolylinePoint.prototype,"handleHandleMouseOut",null);var __decorate$2=undefined&&undefined.__decorate||function(decorators,target,key,desc){var c=arguments.length,r=c<3?target:desc===null?desc=Object.getOwnPropertyDescriptor(target,key):desc,d;if((typeof Reflect==="undefined"?"undefined":_typeof(Reflect))==="object"&&typeof Reflect.decorate==="function")r=Reflect.decorate(decorators,target,key,desc);else for(var i=decorators.length-1;i>=0;i--)if(d=decorators[i])r=(c<3?d(r):c>3?d(target,key,r):d(target,key))||r;return c>3&&r&&Object.defineProperty(target,key,r),r};var SingleLine=function(_AMap$Event){_inherits(SingleLine,_AMap$Event);var _super=_createSuper(SingleLine);function SingleLine(path,parent){var _this;_classCallCheck(this,SingleLine);_this=_super.call(this);_this.path=path;_this.parent=parent;_this.handleAddNode=_this.handleAddNode.bind(_assertThisInitialized(_this));_this.handleRemoveNode=_this.handleRemoveNode.bind(_assertThisInitialized(_this));_this.handleAdjust=_this.handleAdjust.bind(_assertThisInitialized(_this));_this.handleChange=_this.handleChange.bind(_assertThisInitialized(_this));return _this}_createClass(SingleLine,[{key:"initList",value:function initList(){if(!this.parent._poly){console.error("no poly target");return}if(!this.list){this.list=new PointList;var path=this.path;var prev;for(var i=0,len=path.length;i<len;i++){var pos=path[i];var current=new PolylinePoint(this.parent._map,pos,{controlPoint:this.parent._markerOptions,midControlPoint:this.parent._middleMarkerOptions});if(i>0){var middlePos=getMiddleLatLng(prev.point.marker,current.point.marker);var middle=new PolylinePoint(this.parent._map,middlePos,{controlPoint:this.parent._markerOptions,midControlPoint:this.parent._middleMarkerOptions});this.list.add(middle);this.list.add(current);middle.setMiddle(true)}else{this.list.add(current)}prev=current}this.bindListEvent()}this.list.forEach(function(node){node.point.marker.show()});this.parent._customStyle=AMap.extend({},this.parent._poly.getOptions());delete this.parent._customStyle.map;delete this.parent._customStyle.center;delete this.parent._customStyle.radius;delete this.parent._customStyle.path;delete this.parent._customStyle.bounds;this.parent._poly.setOptions(this.parent._selectStyle?this.parent._selectStyle:{})}},{key:"bindListEvent",value:function bindListEvent(){if(this.list){this.list.on(ListEvent.addNode,this.handleAddNode);this.list.on(ListEvent.removeNode,this.handleRemoveNode);this.list.on(ListEvent.adjust,this.handleAdjust);this.list.on(ListEvent.change,this.handleChange);this.list.on(ListEvent.pointMouseOver,this.handlePointMouseOver);this.list.on(ListEvent.pointMouseOut,this.handlePointMouseOut)}}},{key:"unbindListEvent",value:function unbindListEvent(){if(this.list){this.list.off(ListEvent.addNode,this.handleAddNode);this.list.off(ListEvent.removeNode,this.handleRemoveNode);this.list.off(ListEvent.adjust,this.handleAdjust);this.list.off(ListEvent.change,this.handleChange);this.list.off(ListEvent.pointMouseOver,this.handlePointMouseOver);this.list.off(ListEvent.pointMouseOut,this.handlePointMouseOut)}}},{key:"handleAddNode",value:function handleAddNode(e){this.emit(ListEvent.addNode,{target:this.parent.getTarget(),pixel:e.pixel,lnglat:e.lnglat})}},{key:"handleRemoveNode",value:function handleRemoveNode(e){if(!this.list){return}if(this.list.length<=1){this.list.destroy();delete this.list}this.emit(ListEvent.removeNode,{target:this.parent.getTarget(),pixel:e.pixel,lnglat:e.lnglat})}},{key:"handleAdjust",value:function handleAdjust(e){this.emit(ListEvent.adjust,{target:this.parent.getTarget(),pixel:e.pixel,lnglat:e.lnglat})}},{key:"handleChange",value:function handleChange(e){this.emit(ListEvent.change,{target:this.parent.getTarget(),pixel:e.pixel,lnglat:e.lnglat})}},{key:"handlePointMouseOver",value:function handlePointMouseOver(e){this.emit(ListEvent.pointMouseOver,e)}},{key:"handlePointMouseOut",value:function handlePointMouseOut(e){this.emit(ListEvent.pointMouseOut,e)}},{key:"syncPath",value:function syncPath(){if(this.list){this.list.forEach(function(point){point.handleHandleDragging()})}}},{key:"getPath",value:function getPath(){if(!this.list){return}var path=[];this.list.forEach(function(node){if(!node.middleFlag||node.editing){path.push(node.point.marker.getCenter())}});return path}},{key:"destroy",value:function destroy(){var _a,_b;this.unbindListEvent();(_a=this.list)===null||_a===void 0?void 0:_a.forEach(function(node){node.point.marker.hide()});(_b=this.list)===null||_b===void 0?void 0:_b.destroy()}}]);return SingleLine}(AMap.Event);__decorate$2([autobind],SingleLine.prototype,"handlePointMouseOver",null);__decorate$2([autobind],SingleLine.prototype,"handlePointMouseOut",null);var __decorate$3=undefined&&undefined.__decorate||function(decorators,target,key,desc){var c=arguments.length,r=c<3?target:desc===null?desc=Object.getOwnPropertyDescriptor(target,key):desc,d;if((typeof Reflect==="undefined"?"undefined":_typeof(Reflect))==="object"&&typeof Reflect.decorate==="function")r=Reflect.decorate(decorators,target,key,desc);else for(var i=decorators.length-1;i>=0;i--)if(d=decorators[i])r=(c<3?d(r):c>3?d(target,key,r):d(target,key))||r;return c>3&&r&&Object.defineProperty(target,key,r),r};var statusRunTimeOpst={constructor:{time:0,highResTime:0},setTarget:{time:0,highResTime:0},open:{time:0,highResTime:0}};var PolylineEditor=function(_AMap$Event){_inherits(PolylineEditor,_AMap$Event);var _super=_createSuper(PolylineEditor);function PolylineEditor(_map,_poly){var _this;var opts=arguments.length>2&&arguments[2]!==undefined?arguments[2]:{};_classCallCheck(this,PolylineEditor);_this=_super.call(this);_this._map=_map;_this.singleLineList=[];_this.singleLineListHandler=new SingleLineHandler(_assertThisInitialized(_this));_this._defaultStyle={isOutline:true,outlineColor:"white",borderWeight:2,strokeColor:"#3366FF",strokeOpacity:1,strokeWeight:6,strokeStyle:"solid",lineJoin:"round",lineCap:"round"};_this._selectStyle={isOutline:true,outlineColor:"white",borderWeight:2,strokeWeight:4,strokeStyle:"solid",strokeDasharray:[10,10],strokeColor:"#1791fc",strokeOpacity:.8,lineJoin:"round",lineCap:"round"};_this._markerOptions={};_this._middleMarkerOptions={};_this.className="AMap.PolylineEditor";_this._editing=false;_this.handleAddNode=_this.handleAddNode.bind(_assertThisInitialized(_this));_this.handleRemoveNode=_this.handleRemoveNode.bind(_assertThisInitialized(_this));_this.handleAdjust=_this.handleAdjust.bind(_assertThisInitialized(_this));_this.handleChange=_this.handleChange.bind(_assertThisInitialized(_this));if(!_this._map){console.log("ERROR: no map")}_this._creator=new PolylineCreator(_map);_this._poly=_poly;if(opts){_this._defaultStyle=opts.createOptions?AMap.extend(_this._defaultStyle,opts.createOptions):_this._defaultStyle;_this._selectStyle=opts.editOptions?AMap.extend(_this._selectStyle,opts.editOptions):_this._selectStyle;_this._markerOptions=opts.controlPoint?AMap.extend(_this._markerOptions,opts.controlPoint):_this._markerOptions;_this._middleMarkerOptions=opts.midControlPoint?AMap.extend(_this._middleMarkerOptions,opts.midControlPoint):_this._middleMarkerOptions}_this._creator.on("create",function(data){_this._creator.close();var path=data.path;var poly=new AMap.Polyline(AMap.extend({map:_map,path:path},_this._defaultStyle));_this.setTarget(poly);_this.open();_this.emit(ListEvent.add,{target:_this.getTarget(),obj:poly})});_this._statusRunTime=statusRunTimeOpst;var time=(new Date).getTime();var highResTime=0;if("performance"in window&&typeof performance.now==="function"){highResTime=performance.now()}_this._statusRunTime.constructor={time:time,highResTime:highResTime};return _this}_createClass(PolylineEditor,[{key:"CLASS_NAME",get:function get(){return this.className}},{key:"createSingleLine",value:function createSingleLine(){var _this2=this;if(!this._poly){console.error("no poly target");return}var path=this._poly.getPath();var jsonPath=jsonLngLatData(path);this.singleLineListHandler.updatePath(jsonPath);this.singleLineListHandler.forEach(function(line){line.initList();_this2._bindSingleLine(line)})}},{key:"setTarget",value:function setTarget(overlay,cb){this.close();if(this._poly&&this._poly!==overlay){this.destroy()}this._poly=overlay;var time=(new Date).getTime();var highResTime=0;if("performance"in window&&typeof performance.now==="function"){highResTime=performance.now()}this._statusRunTime.setTarget={time:time,highResTime:highResTime};if(cb){cb()}}},{key:"getTarget",value:function getTarget(){return this._poly}},{key:"getStatus",value:function getStatus(){return this._statusRunTime}},{key:"bindListEvent",value:function bindListEvent(){}},{key:"unbindListEvent",value:function unbindListEvent(){}},{key:"handleChange",value:function handleChange(){this._updatePath()}},{key:"handleAddNode",value:function handleAddNode(e){this._updatePath();this.emit(ListEvent.addNode,e)}},{key:"handlePointMouseOver",value:function handlePointMouseOver(e){this.emit(ListEvent.pointMouseOver,e)}},{key:"handlePointMouseOut",value:function handlePointMouseOut(e){this.emit(ListEvent.pointMouseOut,e)}},{key:"handleRemoveNode",value:function handleRemoveNode(e){var endflag=this._updatePath();this.emit(ListEvent.removeNode,e);if(endflag){this.close();this.destroy()}}},{key:"handleAdjust",value:function handleAdjust(e){this._updatePath();this.emit(ListEvent.adjust,e)}},{key:"open",value:function open(cb){if(!this._poly&&!this._editing){this._creator.open()}else if(!this._editing){this._editing=true;this.createSingleLine()}var time=(new Date).getTime();var highResTime=0;if("performance"in window&&typeof performance.now==="function"){highResTime=performance.now()}this._statusRunTime.open={time:time,highResTime:highResTime};if(cb){cb()}}},{key:"close",value:function close(){var _this3=this;this._creator.close();this._editing=false;if(!this._poly){return}this.singleLineListHandler.forEach(function(line){_this3._unbindSingleLine(line);line.destroy()});this.singleLineListHandler.clear();this._poly.setOptions(this._customStyle);this.emit(ListEvent.end,{target:this.getTarget()})}},{key:"destroy",value:function destroy(){this.singleLineListHandler.forEach(function(line){return line.destroy()});this.singleLineListHandler.clear();delete this._poly}},{key:"_updatePath",value:function _updatePath(){if(!this._poly){return}var path=this.singleLineListHandler.getPath();if(!path||path.length===0){this._map.remove(this._poly);return true}else{this._poly.setPath(path)}}},{key:"_bindSingleLine",value:function _bindSingleLine(line){line.on(ListEvent.change,this.handleChange);line.on(ListEvent.adjust,this.handleAdjust);line.on(ListEvent.removeNode,this.handleRemoveNode);line.on(ListEvent.addNode,this.handleAddNode);line.on(ListEvent.change,this.handleChange);line.on(ListEvent.pointMouseOver,this.handlePointMouseOver);line.on(ListEvent.pointMouseOut,this.handlePointMouseOut)}},{key:"_unbindSingleLine",value:function _unbindSingleLine(line){line.off(ListEvent.change,this.handleChange);line.off(ListEvent.adjust,this.handleAdjust);line.off(ListEvent.removeNode,this.handleRemoveNode);line.off(ListEvent.addNode,this.handleAddNode);line.off(ListEvent.change,this.handleChange);line.off(ListEvent.pointMouseOver,this.handlePointMouseOver);line.off(ListEvent.pointMouseOut,this.handlePointMouseOut)}},{key:"syncPath",value:function syncPath(){this.singleLineListHandler.forEach(function(line){line.syncPath()});this._updatePath()}}]);return PolylineEditor}(AMap.Event);__decorate$3([autobind],PolylineEditor.prototype,"handlePointMouseOver",null);__decorate$3([autobind],PolylineEditor.prototype,"handlePointMouseOut",null);var SingleLineHandler=function(){function SingleLineHandler(parent){_classCallCheck(this,SingleLineHandler);this.parent=parent}_createClass(SingleLineHandler,[{key:"updatePath",value:function updatePath(path){if(isNumberArrayArray(path)){this.type="Line";this.list=new SingleLine(AMap.Util.parseLngLatData(path),this.parent)}else if(isNumberArrayArrayArray(path)){this.type="MultiLine";this.list=[];var _iterator=_createForOfIteratorHelper(path),_step;try{for(_iterator.s();!(_step=_iterator.n()).done;){var ring=_step.value;this.list.push(new SingleLine(AMap.Util.parseLngLatData(ring),this.parent))}}catch(err){_iterator.e(err)}finally{_iterator.f()}}else{this.type="Error";console.log("WARING: PolyLine has no path")}}},{key:"forEach",value:function forEach(cb){switch(this.type){case"Line":cb(this.list);break;case"MultiLine":var _iterator2=_createForOfIteratorHelper(this.list),_step2;try{for(_iterator2.s();!(_step2=_iterator2.n()).done;){var line=_step2.value;cb(line)}}catch(err){_iterator2.e(err)}finally{_iterator2.f()}break}}},{key:"getPath",value:function getPath(){switch(this.type){case"Line":return this.list.getPath();case"MultiLine":var polyPath=[];var _iterator3=_createForOfIteratorHelper(this.list),_step3;try{for(_iterator3.s();!(_step3=_iterator3.n()).done;){var singleRing=_step3.value;var ringPath=singleRing.getPath();if(ringPath&&ringPath.length>0){polyPath.push(ringPath)}}}catch(err){_iterator3.e(err)}finally{_iterator3.f()}return polyPath}}},{key:"clear",value:function clear(){this.type="Error";this.list=[]}}]);return SingleLineHandler}();AMap.PolylineEditor=PolylineEditor}(window.AMap); ');_jsload_('AMap.MarkerCluster', '!function(u){"use strict";function n(t,i){t.prototype=Object.create(i.prototype),(t.prototype.constructor=t).__proto__=i}var v=function(r){function t(t,i){var n;return(n=r.call(this)||this).CLASS_NAME="AMap.DataCluster",n.t=t,n.i=t.getMap(),n.s=t.getGridSize(),n.h=t.getMinClusterSize(),n.o=t.isAverageCenter(),n.u=t.getUserDataLen(),n.v=t.v,n.l=i,n.p=null,n.m=[],n.M=[],n.I=null,n.g=[],n}n(t,r);var i=t.prototype;return i.j=function(){return this.p},i.O=function(t,i){if(0===this.m.length&&(this.p=t),i&&(this.k=i),this.m.push(t),t._amapMarker&&t._amapMarker.originData&&0<t._amapMarker.originData.length)for(var n=t._amapMarker.originData.length,r=0;r<n;r++){var s=t._amapMarker.originData[r];this.M.push(s)}},i.N=function(t){if(0===this.m.length)return!1;var i=t._amapMarker.posContainer,n=this.p._amapMarker.posContainer;return Math.abs(i.x-n.x)<=this.s&&Math.abs(i.y-n.y)<=this.s},i.A=function(t,i){if(0===this.m.length)return!1;for(var n=!1,r=0;r<i.length;r++){var s=i[r];void 0!==t[s]&&void 0!==this.p[s]&&t[s]===this.p[s]&&(n=!0)}return n},i.S=function(){var t=this.m.length;if(!t)return null;var i={};if(this.o){i.lnglat=this.m[0].lnglat;for(var n=0,r=0,s=0;s<t;s++){var h=this.m[s];if(h.lnglat)n+=parseFloat(h.lnglat.lng),r+=parseFloat(h.lnglat.lat)}i.lnglat=[(n/t).toFixed(7),(r/t).toFixed(7)]}else this.p&&(i.lnglat=this.p.lnglat);for(var o=0,e=0;e<t;e++){o+=this.m[e]._amapMarker.count}return i.COUNT=o,this.m[0]&&this.m[0].originMarker&&(i.originMarker=this.m[0].originMarker),this.D(i)},i.D=function(t){var i=this.t.getStyles(),n=t.COUNT||1,r=null,s=i[this.J(n)-1],h=this.C(n,s),o=this.t.renderClusterMarker,e=this.t.renderMarker;return n>=this.h&&this.l<=this.v?(r=new u.Marker({position:t.lnglat,anchor:"top-left"}),o?o.call(null,{clusterData:this.m,count:n,marker:r,indexs:this.k}):(r.setContent(h.content),r.setOffset(h.offset))):(r=t.originMarker?t.originMarker:new u.Marker({position:t.lnglat,anchor:"top-left",offset:new u.Pixel(-9,-32)}),e&&e.call(null,{count:n,marker:r,data:this.m,indexs:this.k})),r},i.C=function(t,i){var n=document.createElement("div");return n.style.width=i.size.width+"px",n.style.height=i.size.height+"px",n.innerHTML=t,n.style.backgroundImage="url("+i.url+")",n.style.textAlign="center",n.style.lineHeight=i.size.height+"px",n.style.backgroundPosition=i.imageOffset?i.imageOffset.x+"px "+i.imageOffset.y+"px":"0 0",n.style.color=i.textColor||"#000",n.style.fontSize=i.textSize?i.textSize+"px":"12px",n.style.cursor="pointer",{content:n,offset:i.offset||new u.Pixel(0,0)}},i.J=function(t){for(var i=0,n=t;0!==n;)n=parseInt(n/10,10),i+=1;return i=Math.min(i,5)},i.F=function(){return this.m},i.L=function(){for(var t=[],i=this.M.length,n=0;n<i;n++){var r=this.M[n];t=t.concat(r)}return t},i.X=function(t){var i,n=t.constructor===Array?[]:{};if("object"==typeof t){if(window.JSON)i=JSON.stringify(t),n=JSON.parse(i);else for(var r in t)n[r]="object"==typeof t[r]?cloneObj(t[r]):t[r];return n}},t}(u.Event),t=function(s){function t(t,i,n){var r;n=n||{},(r=s.call(this)||this).Y=!1,r.i=t,r.s=n.gridSize||60,r.h=2,r.v=n.maxZoom||18,r.o=void 0===n.averageCenter||n.averageCenter,r.renderClusterMarker=n.renderClusterMarker||n.renderCluserMarker||null,r.renderMarker=n.renderMarker||null,r.G=n.clusterIndexSet||null,r.R=n.styles||r.Z(),r.q=n.pointStyles||r.Z(),r.B=n.clusterByZoomChange||!1;return r.H={K:{default:Math.floor(r.s/3/1),P:Math.floor(r.s/3.5/1),big:Math.floor(r.s/4/1),T:Math.floor(r.s/4.5/1),small:Math.floor(r.s/5/1),U:2}},r.V=[],r.W=[],r.$=[],r._=[],r.tt={},r.it=r.nt(i),t&&(r.l=r.i.getZoom(),r.rt(),r.st(),r.ht()),r}n(t,s);var i=t.prototype;return i.setRenderMarkerStyle=function(t){this.renderMarker=t},i.setMarkers=function(t){if(!t.length)return!1;t.length},i.setData=function(t){this.it=this.nt(t),this.ht()},i.addData=function(t){for(var i=this.nt(t),n=i.length,r=0;r<n;r++){var s=i[r];this.it.push(s)}this.ht()},i.getClustersCount=function(){return this._.length},i.getMap=function(){return this.i},i.setMap=function(t){this.i!==t&&(this.ot(),this.rt(),t&&(this.i=t,this.st(),this.ht()))},i.getGridSize=function(){return this.s},i.setGridSize=function(t){this.s=t,this.ht()},i.getMaxZoom=function(){return this.v},i.setMaxZoom=function(t){this.v=t,this.ht()},i.getUserDataLen=function(){return this.it.length},i.getStyles=function(){return this.R},i.setStyles=function(t){this.R=t,this.ht()},i.getMinClusterSize=function(){return this.h},i.setMinClusterSize=function(t){this.h=t,this.ht()},i.isAverageCenter=function(){return this.o},i.setAverageCenter=function(t){this.o=t,this.ht()},i.st=function(){this.i&&(this.i.on("zoomend",this.et,this),this.i.on("zoomstart",this.ut,this),this.B?this.i.on("zoomchange",this.at,this):this.i.on("moveend",this.moveEnd,this))},i.rt=function(){this.i&&(this.i.off("zoomend",this.et,this),this.i.on("zoomstart",this.ut,this),this.B?this.i.off("zoomchange",this.at,this):this.i.off("moveend",this.moveEnd,this))},i.ut=function(){this.Y=!0},i.et=function(){this.Y=!1,this.ht()},i.moveEnd=function(){this.Y||this.ht()},i.at=function(){this.ht()},i.nt=function(t){var i=[];if(!t)return i;for(var n=t.length,r=0;r<n;r++){var s=t[r];0===r&&void 0!==s.weight&&(this.o=!1),s.lnglat=this.ft(s.lnglat),s.lnglat&&i.push(s)}return i},i.ht=function(){var t;if(this.l=this.i.getZoom(),this.l>this.v){t=this.ct(),this.V=t;var i=this.vt(t);this.lt(i)}else{t=this.pt(),this.V=t;var n=this.vt(t);this.lt(n)}},i.vt=function(t){this._=[];var i=t.length,n=this.l,r=this.i.getBounds();r=this.dt(r,5);for(var s=this.it.length,h=0;h<i;h++){var o=!0,e=t[h],u=(e.lnglat,e._amapMarker);if(this.wt(r,u.posContainer)){if(e._amapMarker.used=!0,n<=this.v&&s>this.h)for(var a=0;a<this._.length;a++){var f=this._[a];if(f.N(e)){f.O(e),o=!1;break}}if(o){var c=new v(this,n);c.O(e),this._.push(c)}}}return this._},i.ct=function(){for(var t=this.it,i=[],n=0;n<t.length;n++){var r=t[n],s=r.lnglat,h=this.i.lngLatToContainer(s);r._amapMarker={posContainer:h,count:1,used:!1},i.push(r)}return i},i.ot=function(){this.i&&this.i.remove(this.W),this.W=[]},i.lt=function(h){for(var o=this,t=h.length,e=[],i=function(t){var i=h[t],n=i.j().lnglat,r=i.S(),s=i.L();e.push(r),r.on("click",function(){o.emit("click",{cluster:i,lnglat:n,target:o,marker:r,clusterData:s})}),r.show()},n=0;n<t;n++)i(n);this.ot(),this.i.add(e),this.W=e},i.dt=function(t,i){var n=this.i.lngLatToContainer(t.getNorthEast()),r=this.i.lngLatToContainer(t.getSouthWest()),s=[parseInt(n.x),parseInt(r.x)],h=[parseInt(n.y),parseInt(r.y)];s.sort(function(t,i){return t-i}),h.sort(function(t,i){return t-i});var o=parseInt(this.s*i);return{Mt:parseInt(s[0]-o),bt:parseInt(h[1]+o),It:parseInt(s[1]+o),gt:parseInt(h[0]-o)}},i.wt=function(t,i){if(!(t&&i&&i.x&&i.y))return!1;var n=t.Mt,r=t.It,s=t.bt,h=t.gt;return i.x<r&&i.x>n&&i.y>h&&i.y<s},i.pt=function(){this.l=this.i.getZoom();var t=this.l,i=this.H.K.default;6<=t&&t<9?i=this.H.K.P:9<=t&&t<11?i=this.H.K.big:11<=t&&t<14?i=this.H.K.T:14<=t&&t<16?i=this.H.K.small:16<=t&&(i=this.H.K.U);var n=this.it,r={},s=[],h=this.i.getBounds();h=this.dt(h,5);for(var o=this.i.lnglatToPixelArray([108.939621,34.343147],this.l),e=Math.floor(o[0]),u=Math.floor(o[1]),a=0;a<n.length;a++){var f=n[a],c=f.lnglat,v=this.i.lngLatToContainer(c);if(this.wt(h,v)){var l=this.i.lnglatToPixelArray(c,this.l),p=Math.floor(l[0]),d=Math.floor(l[1]),m=f.weight,w=Math.floor((p-e)/i),M=Math.floor((d-u)/i);f._amapMarker={posContainer:v,used:!1};var b=r[w];if(b){var I=b[M];I?m?I[m]?I[m].push(f):I[m]=[f]:I[0]?I[0].push(f):I[0]=[f]:(r[w][M]={},m?r[w][M][m]=[f]:r[w][M][0]=[f])}else r[w]={},r[w][M]={},m?r[w][M][m]=[f]:r[w][M][0]=[f]}}for(var g in r){var x=r[g];for(var j in x){var O=r[g][j],y=Object.keys(O),z=O[y[y.length-1]],k=[],N=0;for(var A in O){var S=O[A];N+=S.length,k.push(S)}var D=z[0];D._amapMarker.count=N,D._amapMarker.originData=k,z&&z.length&&z.length,s.push(D)}}return s.sort(function(t,i){return i.weight-t.weight}),s},i.ft=function(t){if(!t)return!1;if(t.className&&"AMap.LngLat"===t.className)return t;if(Array.isArray(t)&&2===t.length&&(t={lng:Number(t[0]),lat:Number(t[1])}),!t.lng||!t.lat)return!1;var i=new u.LngLat(t.lng,t.lat);return!!i.lat&&(!!i.lng&&i)},i.Z=function(){for(var t=[53,56,66,78,90],i=[],n=0;n<5;n+=1)i.push({url:"http://webapi.amap.com/theme/v1.3/m"+(n+1)+".png",size:new u.Size(t[n],t[n]),offset:new u.Pixel(-t[n]/2,-t[n]/2,!0)});return i},i.X=function(t){var i,n=t.constructor===Array?[]:{};if("object"==typeof t){if(window.JSON)i=JSON.stringify(t),n=JSON.parse(i);else for(var r in t)n[r]="object"==typeof t[r]?cloneObj(t[r]):t[r];return n}},t}(u.Event);u.MarkerClusterer=t,u.MarkerCluster=t}(window.AMap); ');_jsload_('AMap.RangingTool', '(function(){"use strict";var extendStatics=function(d,b){extendStatics=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,b){d.__proto__=b}||function(d,b){for(var p in b)if(b.hasOwnProperty(p))d[p]=b[p]};return extendStatics(d,b)};function __extends(d,b){extendStatics(d,b);function __(){this.constructor=d}d.prototype=b===null?Object.create(b):(__.prototype=b.prototype,new __)}var RangingTool=function(_super){__extends(RangingTool,_super);function RangingTool(map,opts){var _this=_super.call(this)||this;_this["CLASS_NAME"]="AMap.RangingTool";_this.STATUS={OFF:0,READY:1,WORKING:2};if(!map){throw new Error("创建AMap.RangingTool实例必须传入地图对象作为第一个参数: new AMap.RangingTool(mapObj);")}_this._map=map;_this._container=_this._map.getMapsContainer();opts=opts||{};var imgHost=AMap.getConfig()["protocol"]+"://webapi.amap.com";var nodeImg=imgHost+"/images/pldot.png";var nodeSize=new AMap.Size(12,12);var nodeOptionsArray=[];var lineOptions={strokeColor:"#1791fc",strokeOpacity:.8,strokeWeight:2,bubble:true,draggable:false,innerOverlay:true};_this._keydownEvent=_this._onKeyDown.bind(_this);var labelOffset=new AMap.Pixel(-6,6);for(var i=0;i<3;i+=1){nodeOptionsArray.push({icon:new AMap.Icon({size:nodeSize,imageOffset:new AMap.Pixel(-12*i,0),image:nodeImg}),anchor:"top-left",offset:[-6,-6],cursor:"pointer",bubble:true,draggable:false,zIndex:120,innerOverlay:true})}_this["startMarkerOptions"]=nodeOptionsArray[0];_this["midMarkerOptions"]=nodeOptionsArray[2];_this["endMarkerOptions"]=nodeOptionsArray[1];_this["lineOptions"]=_this["tmpLineOptions"]=lineOptions;_this["startLabelText"]="起点</div>";_this["midLabelText"]="{d}公里</div>";_this["endLabelText"]="共{d}公里</div>";_this["startLabelOffset"]=_this["midLabelOffset"]=_this["endLabelOffset"]=labelOffset;_this.keyboardEve=false;_this.d=1e3;if(opts["d"]===1){_this.d=1;_this["midLabelText"]="{d}米</div>";_this["endLabelText"]="共{d}米</div>"}_this.dn="<img class=\'deleteNode\' src=\'"+imgHost+"/images/remove.png\' />";_this.dl="<img class=\'delimg\' src=\'"+imgHost+"/images/destroy.png\' />";_this.merge(_this,opts);_this._lastRecord=null;_this._status=_this.STATUS.OFF;return _this}RangingTool.prototype["turnOn"]=function(){if(this._status===this.STATUS.OFF){this._off2Ready();this._cacheDoubleClickZoom=this._map["getStatus"]()["doubleClickZoom"];this._map["setStatus"]({doubleClickZoom:false})}};RangingTool.prototype["turnOff"]=function(removeOverlays){if(this._status===this.STATUS.READY){this._ready2Off();this._map["setStatus"]({doubleClickZoom:this._cacheDoubleClickZoom})}else if(this._status===this.STATUS.WORKING){this._onEnd();this._working2Off();this._map["setStatus"]({doubleClickZoom:this._cacheDoubleClickZoom})}if(removeOverlays){this._removeAllRecords()}};RangingTool.prototype.setOptions=function(opts){this.merge(this,opts)};RangingTool.prototype.merge=function(obj1,obj2){for(var i in obj2){if(obj2.hasOwnProperty(i)){obj1[i]=obj2[i];if(i==="tmpLineOptions"||i==="lineOptions"){obj1[i]["bubble"]=true}}}};RangingTool.prototype.updateOptions=function(marker,options){var setting={position:[undefined,"setPosition"],draggable:[false,"setDraggable"],content:[undefined,"setContent"],icon:[undefined,"setIcon"],offset:[undefined,"setOffset"],zIndex:[100,"setzIndex"]};for(var key in setting){if(setting.hasOwnProperty(key)){var value=options[key]||setting[key][0];if(value!==undefined){marker[setting[key][1]](value)}}}};RangingTool.prototype._off2Ready=function(){this._map.on("click",this._onStart,this,true);this._status=this.STATUS.READY};RangingTool.prototype._ready2Off=function(){this._map.off("click",this._onStart,this);this._status=this.STATUS.OFF};RangingTool.prototype._ready2Working=function(){this._map.on("click",this._onAddNode,this);this._map.on("mousemove",this._onMouseMove,this);this._map.on("rightclick",this._onEnd,this,true);this._map.on("dblclick",this._onEnd,this,true);this._container.addEventListener("keydown",this._keydownEvent);this._status=this.STATUS.WORKING};RangingTool.prototype._working2Off=function(){this._map.off("click",this._onStart,this);this._map.off("click",this._onAddNode,this);this._map.off("mousemove",this._onMouseMove,this);this._map.off("rightclick",this._onEnd,this);this._map.off("dblclick",this._onEnd,this,true);this._container.removeEventListener("keydown",this._keydownEvent);this._status=this.STATUS.OFF};RangingTool.prototype._working2Ready=function(){this._working2Off();this._off2Ready();this._status=this.STATUS.READY};RangingTool.prototype._onStart=function(e){this._map["setStatus"]({allBubble:true});var record={prev:this._lastRecord};var node={_position:e["lnglat"],_marker:null};record._lastNode=node;if(this._lastRecord){this._lastRecord.next=record}this.originDraggable=this._map["getStatus"]()["dragEnable"];this._map["setStatus"]({dragEnable:false});this._lastRecord=record;this._renderMarker(node,this["startMarkerOptions"]);this._renderLabel(node,this["startLabelText"],this["startLabelOffset"],this._getRemoveNodeFunction(node,record));this._ready2Working();var addnodeEvent={position:e["lnglat"],marker:node._marker};this.emit("addnode",addnodeEvent)};RangingTool.prototype._onAddNode=function(e){var record=this._lastRecord;var prevNode=record._lastNode;var newNode={_position:e["lnglat"],prev:prevNode,_marker:null};if(prevNode&&prevNode._position.equals(e["lnglat"])){this._onEnd();return}prevNode.next=newNode;record._lastNode=newNode;this._renderMarker(newNode,this["midMarkerOptions"]);this._renderLabel(newNode,this["midLabelText"],this["midLabelOffset"],this._getRemoveNodeFunction(newNode,record));this._renderLine(record);if(this._tmpLine){this._tmpLine["setPath"]([e["lnglat"],e["lnglat"]])}var addnodeEvent={position:e["lnglat"],marker:newNode._marker};this.emit("addnode",addnodeEvent)};RangingTool.prototype._onMouseMove=function(e){var record=this._lastRecord;var position=record._lastNode._position;if(!this._tmpLine){this._tmpLine=new AMap.Polyline(this["tmpLineOptions"]);this._tmpLine.name="tmpLine";this._map.add(this._tmpLine)}this._tmpLine.isOfficial=true;this._tmpLine["setPath"]([position,e["lnglat"]]);var distance=this._tmpLine["getLength"]();if(record._line){distance+=record._line["getLength"]()}var moveEvent={position:e["lnglat"],distance:distance,target:this};this.emit("move",moveEvent)};RangingTool.prototype._onKeyDown=function(e){if(e.keyCode===27){this._onEnd()}};RangingTool.prototype._onEnd=function(){var record=this._lastRecord;var node=record&&record._lastNode;this._map["setStatus"]({allBubble:false,dragEnable:this.originDraggable});this["endMarkerOptions"]["bubble"]=false;if(node&&node.prev){this._renderMarker(node,this["endMarkerOptions"]);this._renderLabel(node,this["endLabelText"],this["endLabelOffset"],this._getRemoveNodeFunction(node,record),this._getRemoveRecordFunction(record))}else if(record){this._removeRecord(record)}this._working2Ready();if(this._tmpLine){this._map.remove(this._tmpLine);this._tmpLine=null}if(record&&record._line){record._line["setOptions"]({bubble:false});var endEvent={polyline:record._line,points:record._line["getPath"](),distance:record._line["getLength"]()};this.emit("end",endEvent)}else{this.emit("cancel",{obj:false})}};RangingTool.prototype._renderLine=function(record){var path=[];var cur=record._lastNode;while(cur){path.unshift(cur._position);cur=cur.prev}if(path.length<2){this._removeRecord(record)}else{if(record._line){record._line["setPath"](path)}else{record._line=new AMap.Polyline(this["lineOptions"]);record._line.isOfficial=true;record._line.name="recrdLine";record._line["setPath"](path);this._map.add(record._line)}}};RangingTool.prototype._renderMarker=function(node,options){var isNew=!node._marker;var map=this._map;this.merge(options,{position:node._position,bubble:true,innerOverlay:true});if(!isNew){this.updateOptions(node._marker,options)}else{node._marker=new AMap.Marker(options);node._marker.name="marker";this._map.add(node._marker);node._marker.isOfficial=true}};RangingTool.prototype._renderLabel=function(node,text,offset,dnCallback,dlCallback){var content=document.createElement("div");var d=0;if(node._label){this._map.remove(node._label);delete node._label}if(text.match("{d}")){var cur=node.prev;while(cur){var dis=AMap.GeometryUtil.distance(cur._position,cur.next._position);d+=dis;cur=cur.prev}d=(d/this.d).toFixed(this.d===1?1:2);text=text.replace("{d}",d)}content.className="amap-ranging-label";var span=document.createElement("span");span.innerHTML=text;content.appendChild(span);if(dnCallback){content.appendChild(this._getSmallButton(this.dn,dnCallback))}if(dlCallback){content.appendChild(this._getSmallButton(this.dl,dlCallback))}node._label=new AMap.Marker({content:content,position:node._position,offset:offset,cursor:"pointer",zIndex:110,bubble:false});node._label.isOfficial=true;node._marker.name="label";this._map.add(node._label)};RangingTool.prototype._updateLabels=function(record){var cur=record._lastNode;if(cur){this._renderLabel(cur,this["endLabelText"],this["endLabelOffset"],this._getRemoveNodeFunction(cur,record),this._getRemoveRecordFunction(record));while(cur.prev){cur=cur.prev;this._renderLabel(cur,this["midLabelText"],this["midLabelOffset"],this._getRemoveNodeFunction(cur,record))}this._renderLabel(cur,this["startLabelText"],this["startLabelOffset"],this._getRemoveNodeFunction(cur,record))}};RangingTool.prototype._getSmallButton=function(html,callback){var button=document.createElement("span");button.innerHTML=html;button.addEventListener("click",function(e){callback()});button.addEventListener("mousedown",function(e){e.stopPropagation()});return button};RangingTool.prototype._getRemoveNodeFunction=function(node,record){var _this=this;var removeNodeFun=function(){if(_this._status!==_this.STATUS.WORKING){_this._removeNode(node,record)}};return removeNodeFun};RangingTool.prototype._getRemoveRecordFunction=function(record){var self=this;return function(e){if(self._status!==self.STATUS.WORKING){self.emit("delete",{target:self});self._removeRecord(record)}}};RangingTool.prototype._removeNode=function(node,record){if(node.prev){node.prev.next=node.next}else if(node.next){this._renderMarker(node.next,this["startMarkerOptions"])}if(node.next){node.next.prev=node.prev}else if(node.prev){this._renderMarker(node.prev,this["endMarkerOptions"]);record._lastNode=node.prev}node.prev=node.next=null;if(node._marker){this._map.remove(node._marker);node._marker=null}if(node._label){this._map.remove(node._label);node._label=null}this._renderLine(record);this._updateLabels(record);var removenodeEvent={polyline:record._line,points:record._line?record._line["getPath"]():[],distance:record._line?record._line["getLength"]():null,target:this};this.emit("removenode",removenodeEvent)};RangingTool.prototype._removeRecord=function(record){var node=record._lastNode;if(record._line){this._map.remove(record._line);record._line=null}while(node){if(node._marker){this._map.remove(node._marker);node._marker=null}if(node._label){this._map.remove(node._label);node._label=null}node=node.prev}if(record.prev){record.prev.next=record.next}if(record.next){record.next.prev=record.prev}else{this._lastRecord=record.prev}record._lastNode=record.prev=record.next=null};RangingTool.prototype._removeAllRecords=function(){while(this._lastRecord){this._removeRecord(this._lastRecord)}};return RangingTool}(AMap.Event);AMap["RangingTool"]=RangingTool})(); ') |