Agriculture-front-end/public/libs/openlayers/ol3-echarts/2.0.6/ol3Echarts.min.js

2 lines
14 KiB
JavaScript
Raw Normal View History

2023-06-22 06:50:23 +08:00
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("openlayers"),require("echarts")):"function"==typeof define&&define.amd?define(["openlayers","echarts"],e):(t=t||self).ol3Echarts=e(t.ol,t.echarts)}(this,function(t,r){"use strict";t=t&&t.hasOwnProperty("default")?t.default:t,r=r&&r.hasOwnProperty("default")?r.default:r;var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)};function s(t){var e=typeof t;return null!==t&&("object"==e||"function"==e)}function o(i,o){for(var t=arguments,r=[],e=2;e<arguments.length;e++)r[e-2]=t[e];return function(){for(var t=arguments,e=[],n=0;n<arguments.length;n++)e[n]=t[n];return i.apply(o,r.concat(Array.prototype.slice.call(e)))}}function i(t,e){for(var n,i=0,o=t.length;i<o;i++)if(t[i].index===e.index){n=i;break}return void 0===n?t.push(e):t[n]=e,t}function a(){return function t(e){return e?(e^16*Math.random()>>e/4).toString(16):([1e7]+-[1e3]+-4e3+-8e3+-1e11).replace(/[018]/g,t)}()}var h=function(e,n){return Object.keys(n).forEach(function(t){s(n[t])&&s(e[t])?h(e[t],n[t]):e[t]=n[t]}),e};function p(t,e){t.forEach(function(t){e[t]&&(e[t]=e[t].bind(e))})}function c(t){return t&&t.parentNode?t.parentNode.removeChild(t):null}function u(t,e){var n=new MouseEvent(t,{bubbles:!0,cancelable:!0,button:e.pointerEvent.button,buttons:e.pointerEvent.buttons,clientX:e.pointerEvent.clientX,clientY:e.pointerEvent.clientY,zrX:e.pointerEvent.offsetX,zrY:e.pointerEvent.offsetY,movementX:e.pointerEvent.movementX,movementY:e.pointerEvent.movementY,relatedTarget:e.pointerEvent.relatedTarget,screenX:e.pointerEvent.screenX,screenY:e.pointerEvent.screenY,view:window});return n.zrX=e.pointerEvent.offsetX,n.zrY=e.pointerEvent.offsetY,n.event=n}function d(t,e,n){for(var i=[],o=[e[0],e[1]],r=o[0],s=o[1],a=0;a<t.length;a+=2){var h=t.charCodeAt(a)-64,p=t.charCodeAt(a+1)-64;h=h>>1^-(1&h),p=p>>1^-(1&p),r=h+=r,s=p+=s,i.push([h/n,p/n])}return i}function e(t){var e=function(t){if(function(t){return!t.UTF8Encoding}(t))return t;var e=t.UTF8Scale;null==e&&(e=1024);for(var n=t.features,i=0;i<n.length;i++)for(var o=n[i].geometry,r=[o.coordinates,o.encodeOffsets],s=r[0],a=r[1],h=0;h<s.length;h++){var p=s[h];if("Polygon"===o.type)s[h]=d(p,a[h],e);else if("MultiPolygon"===o.type)for(var c=0;c<p.length;c++){var u=p[c];p[c]=d(u,a[h][c],e)}}return t.UTF8Encoding=!1,t}(t);return{type:"FeatureCollection",crs:{},features:r.util.map(r.util.filter(e.features,function(t){return t.geometry&&t.properties&&0<t.geometry.coordinates.length}),function(t){var e=t.properties,n=t.geometry,i=n.coordinates,o=[];return"Polygon"===n.type&&o.push(i[0]),"MultiPolygon"===n.type&&r.util.each(i,function(t){t[0]&&o.push(t[0])}),{properties:e,type:"Feature",geometry:{type:"Polygon",coordinates:o}}})}}var l=Object.freeze({pie:function(t,e,n){return e.center=n.dataToPoint(e.coordinates),e},bar:function(i,t,o){return s(i.grid)&&!Array.isArray(i.grid)?console.log(i):Array.isArray(i.grid)&&(i.grid=i.grid.map(function(t,e){var n=o.dataToPoint(i.series[e].coordinates);return t.left=n[0]-parseFloat(t.width)/2,t.top=n[1]-parseFloat(t.height)/2,t})),t},line:function(i,t,o){return s(i.grid)&&!Array.isArray(i.grid)?console.log(i):Array.isArray(i.grid)&&(i.grid=i.grid.map(function(t,e){var n=o.dataToPoint(i.series[e].coordinates);return t.left=n[0]-parseFloat(t.width)/2,t.top=n[1]-parseFloat(t.height)/2,t})),t}}),f=t.Map,y=t.Object,g=t.proj.transform;f.prototype.getOverlayContainer||(f.prototype.getOverlayContainer=function(t){t=t||"ol-overlaycontainer";var e=this.getViewport();if(e){var n=e.getElementsByClassName(t);return n&&0<n.length?n[0]:null}return null}),f.prototype.getOverlayContainerStopEvent||(f.prototype.getOverlayContainerStopEvent=function(t){t=t||"ol-overlaycontainer-stopevent";var e=this.getViewport();if(e){var n=e.getElementsByClassName(t);return n&&0<n.length?n[0]:null}return null});var v,m,w,E={forcedRerender:!1,forcedPrecomposeRerender:!1,hideOnZooming:!1,hideOnMoving:!1,hideOnRotating:!