mars3d-echarts 3.5.17 → 3.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/mars3d-echarts.js +3 -3
- package/package.json +2 -2
package/dist/mars3d-echarts.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Mars3D平台插件,结合echarts可视化功能插件 mars3d-echarts
|
|
3
3
|
*
|
|
4
|
-
* 版本信息:v3.
|
|
5
|
-
* 编译日期:2023-
|
|
4
|
+
* 版本信息:v3.6.0
|
|
5
|
+
* 编译日期:2023-08-04 12:18:40
|
|
6
6
|
* 版权所有:Copyright by 火星科技 http://mars3d.cn
|
|
7
7
|
* 使用单位:免费公开版 ,2023-03-17
|
|
8
8
|
*/
|
|
@@ -11,5 +11,5 @@
|
|
|
11
11
|
typeof define === 'function' && define.amd ? define(['exports', 'echarts', 'mars3d'], factory) :
|
|
12
12
|
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["mars3d-echarts"] = {}, global.echarts, global.mars3d));
|
|
13
13
|
})(this, (function (exports, echarts, mars3d) {
|
|
14
|
-
'use strict';const _0x289d3f=_0x2ade;(function(_0x28e402,_0x1c699f){const _0x4b9a38={_0x3f7fd4:0x224,_0x3d078b:0x201},_0x5b0cf9=_0x2ade,_0x496810=_0x28e402();while(!![]){try{const _0x2d25bd=-parseInt(_0x5b0cf9(_0x4b9a38._0x3f7fd4))/0x1*(-parseInt(_0x5b0cf9(0x1ff))/0x2)+parseInt(_0x5b0cf9(0x227))/0x3+-parseInt(_0x5b0cf9(0x222))/0x4*(parseInt(_0x5b0cf9(0x20a))/0x5)+parseInt(_0x5b0cf9(0x21b))/0x6+-parseInt(_0x5b0cf9(0x1ec))/0x7*(parseInt(_0x5b0cf9(0x1f1))/0x8)+-parseInt(_0x5b0cf9(0x223))/0x9+parseInt(_0x5b0cf9(_0x4b9a38._0x3d078b))/0xa;if(_0x2d25bd===_0x1c699f)break;else _0x496810['push'](_0x496810['shift']());}catch(_0x52e142){_0x496810['push'](_0x496810['shift']());}}}(_0x28fb,0x3bc1f));function _0x2ade(_0x3b61ca,_0x55de7b){const _0x28fbb4=_0x28fb();return _0x2ade=function(_0x2ade0d,_0x55d19c){_0x2ade0d=_0x2ade0d-0x1eb;let _0x1c06e3=_0x28fbb4[_0x2ade0d];return _0x1c06e3;},_0x2ade(_0x3b61ca,_0x55de7b);}function _interopNamespace(_0x41d65f){const _0x3cdbcd={_0x3fb970:0x203},_0x34c0bb={_0x41f99a:0x228},_0x4f767d=_0x2ade;if(_0x41d65f&&_0x41d65f['__esModule'])return _0x41d65f;var _0x545d44=Object['create'](null);return _0x41d65f&&Object['keys'](_0x41d65f)[_0x4f767d(_0x3cdbcd._0x3fb970)](function(_0x582517){const _0x5278d7=_0x4f767d;if(_0x582517!==_0x5278d7(_0x34c0bb._0x41f99a)){var _0x38ff26=Object['getOwnPropertyDescriptor'](_0x41d65f,_0x582517);Object['defineProperty'](_0x545d44,_0x582517,_0x38ff26[_0x5278d7(0x22d)]?_0x38ff26:{'enumerable':!![],'get':function(){return _0x41d65f[_0x582517];}});}}),_0x545d44['default']=_0x41d65f,_0x545d44;}var echarts__namespace=_interopNamespace(echarts),mars3d__namespace=_interopNamespace(mars3d);const Cesium$1=mars3d__namespace[_0x289d3f(0x20d)];class CompositeCoordinateSystem{constructor(_0x1c6af5,_0x1cadde){const _0x221d7={_0x3cef42:0x20e},_0x196477=_0x289d3f;this[_0x196477(0x1f2)]=_0x1c6af5,this['dimensions']=['lng',_0x196477(_0x221d7._0x3cef42)],this['_mapOffset']=[0x0,0x0],this['_api']=_0x1cadde;}[_0x289d3f(0x208)](_0x3816d4){const _0xb87ccb={_0x50104e:0x1f5},_0x57ec7c=_0x289d3f;this[_0x57ec7c(_0xb87ccb._0x50104e)]=_0x3816d4;}['getBMap'](){return this['_mars3d_scene'];}['dataToPoint'](_0x5ac07e){const _0x5a2687={_0x23b358:0x219,_0x42a4d2:0x22c,_0x6a34e2:0x207,_0x2dfa15:0x220},_0x4192d5=_0x289d3f,_0x4aef0b=this[_0x4192d5(0x1f2)],_0x410175=[NaN,NaN];let _0x24ae32=_0x4aef0b['echartsFixedHeight'];_0x4aef0b['echartsAutoHeight']&&(_0x24ae32=_0x4aef0b['globe']['getHeight'](Cesium$1[_0x4192d5(_0x5a2687._0x23b358)][_0x4192d5(0x231)](_0x5ac07e[0x0],_0x5ac07e[0x1])));const _0x4ebb2b=Cesium$1[_0x4192d5(_0x5a2687._0x42a4d2)][_0x4192d5(0x231)](_0x5ac07e[0x0],_0x5ac07e[0x1],_0x24ae32);if(!_0x4ebb2b)return _0x410175;const _0x33505e=Cesium$1['SceneTransforms']['wgs84ToWindowCoordinates'](_0x4aef0b,_0x4ebb2b);if(!_0x33505e)return _0x410175;if(_0x4aef0b[_0x4192d5(0x1fb)]&&_0x4aef0b[_0x4192d5(_0x5a2687._0x6a34e2)]===Cesium$1[_0x4192d5(0x21c)]['SCENE3D']){const _0x2e7022=new Cesium$1['EllipsoidalOccluder'](_0x4aef0b['globe']['ellipsoid'],_0x4aef0b[_0x4192d5(_0x5a2687._0x2dfa15)][_0x4192d5(0x229)]),_0x538616=_0x2e7022[_0x4192d5(0x1fc)](_0x4ebb2b);if(!_0x538616)return _0x410175;}return[_0x33505e['x']-this['_mapOffset'][0x0],_0x33505e['y']-this['_mapOffset'][0x1]];}['getViewRect'](){const _0x36eda3={_0x29af43:0x225},_0x34d3e6=_0x289d3f,_0x38ef1a=this['_api'];return new echarts__namespace['graphic'][(_0x34d3e6(_0x36eda3._0x29af43))](0x0,0x0,_0x38ef1a['getWidth'](),_0x38ef1a['getHeight']());}['getRoamTransform'](){return echarts__namespace['matrix']['create']();}}CompositeCoordinateSystem[_0x289d3f(0x215)]=[_0x289d3f(0x21f),_0x289d3f(0x20e)],CompositeCoordinateSystem['create']=function(_0x2342de,_0x4f1265){const _0x5bda08={_0x523044:0x213},_0x5dd82c={_0x5f5c51:0x204},_0x5461c1=_0x289d3f;let _0x264287;const _0x356c5c=_0x2342de['scheduler']['ecInstance'][_0x5461c1(0x1f2)];_0x2342de['eachComponent'](_0x5461c1(0x1f4),function(_0x48019a){const _0x5bceda=_0x5461c1,_0x471543=_0x4f1265[_0x5bceda(_0x5dd82c._0x5f5c51)]()['painter'];if(!_0x471543)return;!_0x264287&&(_0x264287=new CompositeCoordinateSystem(_0x356c5c,_0x4f1265)),_0x48019a['coordinateSystem']=_0x264287,_0x264287['setMapOffset'](_0x48019a[_0x5bceda(0x221)]||[0x0,0x0]);}),_0x2342de['eachSeries'](function(_0x4c90f3){const _0xe1bcd6=_0x5461c1;_0x4c90f3['get'](_0xe1bcd6(_0x5bda08._0x523044))==='mars3dMap'&&(!_0x264287&&(_0x264287=new CompositeCoordinateSystem(_0x356c5c,_0x4f1265)),_0x4c90f3['coordinateSystem']=_0x264287);});};if(echarts__namespace!==null&&echarts__namespace!==void 0x0&&echarts__namespace['init'])echarts__namespace['registerCoordinateSystem']('mars3dMap',CompositeCoordinateSystem),echarts__namespace[_0x289d3f(0x1f3)]({'type':'mars3dMapRoam','event':_0x289d3f(0x1fe),'update':_0x289d3f(0x21a)},function(_0x37a430,_0x5a0c80){}),echarts__namespace['extendComponentModel']({'type':'mars3dMap','getBMap':function(){const _0x498d85=_0x289d3f;return this[_0x498d85(0x1f2)];},'defaultOption':{'roam':![]}}),echarts__namespace['extendComponentView']({'type':'mars3dMap','init':function(_0x2dd7b6,_0x143a93){const _0x25a6d3={_0x26bcb8:0x200},_0x30a465=_0x289d3f;this['api']=_0x143a93,this['scene']=_0x2dd7b6['scheduler']['ecInstance'][_0x30a465(0x1f2)],this['scene']['postRender'][_0x30a465(_0x25a6d3._0x26bcb8)](this['moveHandler'],this);},'moveHandler':function(_0x23f2c2,_0x15414d){const _0x242330={_0xf01f0a:0x230,_0x291cf2:0x1fe},_0x474496=_0x289d3f;this[_0x474496(_0x242330._0xf01f0a)]['dispatchAction']({'type':_0x474496(_0x242330._0x291cf2)});},'render':function(_0x2f3b2e,_0x473381,_0x151ec2){},'dispose':function(_0x4832fb){this['scene']['postRender']['removeEventListener'](this['moveHandler'],this);}});else throw new Error(_0x289d3f(0x22f));const Cesium=mars3d__namespace[_0x289d3f(0x20d)],BaseLayer=mars3d__namespace['layer']['BaseLayer'];class EchartsLayer extends BaseLayer{constructor(_0x5d3a9a={}){super(_0x5d3a9a),this['_pointerEvents']=this['options']['pointerEvents'];}get['layer'](){return this['_echartsInstance'];}get['pointerEvents'](){return this['_pointerEvents'];}set['pointerEvents'](_0x118af2){const _0x3825fd={_0xbcb47a:0x1f9},_0x1a41fb=_0x289d3f;this['_pointerEvents']=_0x118af2,this['_echartsContainer']&&(_0x118af2?this['_echartsContainer']['style']['pointerEvents']='all':this['_echartsContainer'][_0x1a41fb(_0x3825fd._0xbcb47a)][_0x1a41fb(0x211)]=_0x1a41fb(0x22b));}['_setOptionsHook'](_0x87fb91,_0x2ffd53){this['setEchartsOption'](_0x87fb91);}['_showHook'](_0x6d614a){const _0x4687c1={_0x5603a5:0x206,_0x52974b:0x210,_0x2b5e49:0x20f,_0x38e9d6:0x226},_0x93201f=_0x289d3f;_0x6d614a?this[_0x93201f(_0x4687c1._0x5603a5)]['style'][_0x93201f(_0x4687c1._0x52974b)]=_0x93201f(_0x4687c1._0x2b5e49):this['_echartsContainer']['style']['visibility']=_0x93201f(_0x4687c1._0x38e9d6);}['_mountedHook'](){const _0x103052=_0x289d3f;this['_map']['scene']['echartsDepthTest']=this['options']['depthTest']??!![],this['_map']['scene'][_0x103052(0x1f7)]=this[_0x103052(0x216)]['clampToGround']??![],this['_map']['scene']['echartsFixedHeight']=this['options']['fixedHeight']??0x0;}['_addedHook'](){const _0x1fc9b9={_0x4a9acb:0x21d,_0x527dcd:0x22e,_0x55f0f1:0x22a},_0x40a0d2=_0x289d3f;this[_0x40a0d2(0x206)]=this[_0x40a0d2(_0x1fc9b9._0x4a9acb)](),this['_echartsInstance']=echarts__namespace['init'](this['_echartsContainer']),this[_0x40a0d2(0x1eb)]['_mars3d_scene']=this[_0x40a0d2(_0x1fc9b9._0x527dcd)][_0x40a0d2(_0x1fc9b9._0x55f0f1)],this['setEchartsOption'](this['options']);}['_removedHook'](){const _0x3bc500={_0x21349d:0x1f8,_0x8b9854:0x22e},_0x112089=_0x289d3f;this['_echartsInstance']&&(this['_echartsInstance']['clear'](),this['_echartsInstance'][_0x112089(_0x3bc500._0x21349d)](),delete this['_echartsInstance']),this['_echartsContainer']&&(this[_0x112089(_0x3bc500._0x8b9854)]['container'][_0x112089(0x1f0)](this['_echartsContainer']),delete this['_echartsContainer']);}['_createChartOverlay'](){const _0x176280={_0xf5f6d8:0x202,_0x134b4d:0x1fd,_0x3c3c5b:0x22e,_0x2f91d1:0x20c,_0x1afddd:0x1f9,_0x24a00e:0x1f6,_0x50691e:0x20b,_0x1b7e04:0x22b},_0x29c02d=_0x289d3f,_0x21fd25=mars3d__namespace['DomUtil']['create'](_0x29c02d(_0x176280._0xf5f6d8),_0x29c02d(_0x176280._0x134b4d),this[_0x29c02d(_0x176280._0x3c3c5b)]['container']);return _0x21fd25['id']=this['id'],_0x21fd25['style']['position']='absolute',_0x21fd25['style'][_0x29c02d(_0x176280._0x2f91d1)]='0px',_0x21fd25['style'][_0x29c02d(0x217)]='0px',_0x21fd25[_0x29c02d(_0x176280._0x1afddd)]['width']=this[_0x29c02d(0x22e)][_0x29c02d(0x22a)]['canvas'][_0x29c02d(_0x176280._0x24a00e)]+'px',_0x21fd25['style']['height']=this['_map']['scene'][_0x29c02d(0x218)][_0x29c02d(_0x176280._0x50691e)]+'px',_0x21fd25['style']['pointerEvents']=this['_pointerEvents']?'all':_0x29c02d(_0x176280._0x1b7e04),_0x21fd25['style']['zIndex']=this['options'][_0x29c02d(0x1fa)]??0x9,_0x21fd25;}['resize'](){const _0x31a16b={_0x4e1ab5:0x1eb,_0x44c8dd:0x206,_0x25e6dc:0x1f9,_0x416d0a:0x22e,_0xb72b58:0x1f6,_0x77ba4e:0x20b},_0x1be9be=_0x289d3f;if(!this[_0x1be9be(_0x31a16b._0x4e1ab5)])return;this[_0x1be9be(_0x31a16b._0x44c8dd)][_0x1be9be(_0x31a16b._0x25e6dc)]['width']=this[_0x1be9be(_0x31a16b._0x416d0a)]['scene'][_0x1be9be(0x218)][_0x1be9be(_0x31a16b._0xb72b58)]+'px',this['_echartsContainer'][_0x1be9be(_0x31a16b._0x25e6dc)]['height']=this[_0x1be9be(0x22e)][_0x1be9be(0x22a)]['canvas'][_0x1be9be(_0x31a16b._0x77ba4e)]+'px',this['_echartsInstance']['resize']();}['setEchartsOption'](_0x241398,_0x1ad2f6,_0x2a374a){const _0x4efea4={_0x4aaf65:0x1f4},_0x24fa73=_0x289d3f;this['_echartsInstance']&&(_0x241398[_0x24fa73(0x1f4)]=_0x241398[_0x24fa73(_0x4efea4._0x4aaf65)]||{},this['_echartsInstance']['setOption'](_0x241398,_0x1ad2f6,_0x2a374a));}['getRectangle'](_0x270fff){const _0x3a49f0={_0x3ffe04:0x21e},_0x12edf3={_0x5b85a3:0x1ed},_0x462641=_0x289d3f;let _0x367cf4,_0x5f50a6,_0x4bbdf0,_0x5dcbd2;function _0xa0ce8c(_0x5f14ab){if(!Array['isArray'](_0x5f14ab))return;const _0x24eb3b=_0x5f14ab[0x0]||0x0,_0x3585fa=_0x5f14ab[0x1]||0x0;_0x24eb3b!==0x0&&_0x3585fa!==0x0&&(_0x367cf4===undefined?(_0x367cf4=_0x24eb3b,_0x5f50a6=_0x24eb3b,_0x4bbdf0=_0x3585fa,_0x5dcbd2=_0x3585fa):(_0x367cf4=Math['min'](_0x367cf4,_0x24eb3b),_0x5f50a6=Math['max'](_0x5f50a6,_0x24eb3b),_0x4bbdf0=Math['min'](_0x4bbdf0,_0x3585fa),_0x5dcbd2=Math['max'](_0x5dcbd2,_0x3585fa)));}const _0x314863=this['options'][_0x462641(0x214)];_0x314863&&_0x314863['forEach'](_0x5cfce9=>{const _0x29a74d=_0x462641;_0x5cfce9[_0x29a74d(_0x3a49f0._0x3ffe04)]&&_0x5cfce9['data']['forEach'](_0x4fb7e4=>{const _0x70cbd8=_0x29a74d;if(_0x4fb7e4['value'])_0xa0ce8c(_0x4fb7e4[_0x70cbd8(_0x12edf3._0x5b85a3)]);else _0x4fb7e4['coords']&&_0x4fb7e4[_0x70cbd8(0x205)]['forEach'](_0x49bb3c=>{_0xa0ce8c(_0x49bb3c);});});});if(_0x367cf4===0x0&&_0x4bbdf0===0x0&&_0x5f50a6===0x0&&_0x5dcbd2===0x0)return null;return _0x270fff!==null&&_0x270fff!==void 0x0&&_0x270fff[_0x462641(0x212)]?{'xmin':_0x367cf4,'xmax':_0x5f50a6,'ymin':_0x4bbdf0,'ymax':_0x5dcbd2}:Cesium['Rectangle']['fromDegrees'](_0x367cf4,_0x4bbdf0,_0x5f50a6,_0x5dcbd2);}['on'](_0x20df21,_0x176567,_0x2d8464){return this['_echartsInstance']['on'](_0x20df21,_0x176567,_0x2d8464||this),this;}['onByQuery'](_0x99efb8,_0x46442f,_0x16f629,_0x150be7){return this['_echartsInstance']['on'](_0x99efb8,_0x46442f,_0x16f629,_0x150be7||this),this;}['off'](_0x357397,_0x25088a,_0x4982ea){return this['_echartsInstance']['off'](_0x357397,_0x25088a,_0x4982ea||this),this;}}function _0x28fb(){const _0x175057=['fromDegrees','_echartsInstance','231ltXJyN','value','hasOwnProperty','echarts','removeChild','102640GpxkNh','_mars3d_scene','registerAction','mars3dMap','_mapOffset','clientWidth','echartsAutoHeight','dispose','style','zIndex','echartsDepthTest','isPointVisible','mars3d-echarts','mars3dMapRoam','4NyknRd','addEventListener','6814630MkpFvZ','div','forEach','getZr','coords','_echartsContainer','mode','setMapOffset','EchartsLayer','105CBGFFT','clientHeight','top','Cesium','lat','visible','visibility','pointerEvents','isFormat','coordinateSystem','series','dimensions','options','left','canvas','Cartographic','updateLayout','1101924NHOPcs','SceneMode','_createChartOverlay','data','lng','camera','__mapOffset','34924cHSGBF','3863196RLNRkT','12214znSVrm','BoundingRect','hidden','1173621qQXsBl','default','positionWC','scene','none','Cartesian3','get','_map','请引入\x20echarts\x20库\x20','api'];_0x28fb=function(){return _0x175057;};return _0x28fb();}mars3d__namespace['LayerUtil']['register'](_0x289d3f(0x1ef),EchartsLayer),mars3d__namespace['layer']['EchartsLayer']=EchartsLayer,mars3d__namespace['echarts']=echarts__namespace,exports[_0x289d3f(0x209)]=EchartsLayer,Object['keys'](echarts)['forEach'](function(_0x420885){const _0x39d836=_0x289d3f;if(_0x420885!=='default'&&!exports[_0x39d836(0x1ee)](_0x420885))Object['defineProperty'](exports,_0x420885,{'enumerable':!![],'get':function(){return echarts[_0x420885];}});}),Object['defineProperty'](exports,'__esModule',{'value':!![]});
|
|
14
|
+
'use strict';const _0x2ee574=_0x1611;function _0x40b9(){const _0xa6f993=['lat','8NzNtkG','SceneMode','registerAction','DomUtil','SceneTransforms','_echartsContainer','width','scene','setOption','661633pfyZlF','echarts','default','_map','219wrhHpd','_pointerEvents','moveHandler','height','matrix','Cesium','_mars3d_scene','echartsDepthTest','register','__mapOffset','_echartsInstance','setMapOffset','scheduler','BaseLayer','coordinateSystem','off','clientWidth','globe','8116seUnaP','_api','clientHeight','963840TLEkEt','setEchartsOption','get','create','LayerUtil','position','graphic','_mapOffset','dimensions','_addedHook','extendComponentView','getOwnPropertyDescriptor','registerCoordinateSystem','5543056hQmBLE','hidden','44361042jSfhZn','8626160MpRjJQ','Rectangle','2129289aAfalk','18gfAQIs','updateLayout','style','12zhzwmW','echartsFixedHeight','请引入\x20echarts\x20库\x20','forEach','fromDegrees'];_0x40b9=function(){return _0xa6f993;};return _0x40b9();}(function(_0x49b7d8,_0x4a1ba0){const _0x524118={_0x5738ba:0x178,_0x4f6e29:0x14f,_0x21e9a8:0x159,_0x4fce5a:0x162,_0x21062c:0x14c},_0x49d748=_0x1611,_0x5e5865=_0x49b7d8();while(!![]){try{const _0x3d863b=parseInt(_0x49d748(0x166))/0x1*(-parseInt(_0x49d748(_0x524118._0x5738ba))/0x2)+-parseInt(_0x49d748(_0x524118._0x4f6e29))/0x3*(parseInt(_0x49d748(_0x524118._0x21e9a8))/0x4)+-parseInt(_0x49d748(0x17b))/0x5*(parseInt(_0x49d748(0x153))/0x6)+-parseInt(_0x49d748(_0x524118._0x4fce5a))/0x7+parseInt(_0x49d748(0x14a))/0x8*(-parseInt(_0x49d748(0x150))/0x9)+parseInt(_0x49d748(0x14d))/0xa+parseInt(_0x49d748(_0x524118._0x21062c))/0xb;if(_0x3d863b===_0x4a1ba0)break;else _0x5e5865['push'](_0x5e5865['shift']());}catch(_0x1117c4){_0x5e5865['push'](_0x5e5865['shift']());}}}(_0x40b9,0xb01ef));function _interopNamespace(_0x51780b){const _0x2ff48b={_0x59a0a6:0x148,_0x5b8531:0x17d},_0x412858=_0x1611;if(_0x51780b&&_0x51780b['__esModule'])return _0x51780b;var _0x4976ba=Object['create'](null);return _0x51780b&&Object['keys'](_0x51780b)[_0x412858(0x156)](function(_0x1ca8f4){const _0x4e719e=_0x412858;if(_0x1ca8f4!=='default'){var _0x19e476=Object[_0x4e719e(_0x2ff48b._0x59a0a6)](_0x51780b,_0x1ca8f4);Object['defineProperty'](_0x4976ba,_0x1ca8f4,_0x19e476[_0x4e719e(_0x2ff48b._0x5b8531)]?_0x19e476:{'enumerable':!![],'get':function(){return _0x51780b[_0x1ca8f4];}});}}),_0x4976ba['default']=_0x51780b,_0x4976ba;}var echarts__namespace=_interopNamespace(echarts),mars3d__namespace=_interopNamespace(mars3d);const Cesium$1=mars3d__namespace[_0x2ee574(0x16b)];class CompositeCoordinateSystem{constructor(_0xb2b238,_0x1cc5b){const _0x4b83fb={_0x192321:0x145},_0xa76e4b=_0x2ee574;this['_mars3d_scene']=_0xb2b238,this[_0xa76e4b(_0x4b83fb._0x192321)]=['lng','lat'],this['_mapOffset']=[0x0,0x0],this[_0xa76e4b(0x179)]=_0x1cc5b;}['setMapOffset'](_0x28b233){const _0x59d66f=_0x2ee574;this[_0x59d66f(0x182)]=_0x28b233;}['getBMap'](){const _0x2273e6=_0x2ee574;return this[_0x2273e6(0x16c)];}['dataToPoint'](_0x46e5b4){const _0x5d63b2={_0x43b451:0x15d,_0x741771:0x16d,_0x19659a:0x177},_0x2474f1=_0x2ee574,_0x206105=this[_0x2474f1(0x16c)],_0x16116e=[NaN,NaN];let _0x2ffba1=_0x206105['echartsFixedHeight'];_0x206105['echartsAutoHeight']&&(_0x2ffba1=_0x206105['globe']['getHeight'](Cesium$1['Cartographic'][_0x2474f1(0x157)](_0x46e5b4[0x0],_0x46e5b4[0x1])));const _0x2ffe94=Cesium$1['Cartesian3']['fromDegrees'](_0x46e5b4[0x0],_0x46e5b4[0x1],_0x2ffba1);if(!_0x2ffe94)return _0x16116e;const _0x411027=Cesium$1[_0x2474f1(_0x5d63b2._0x43b451)]['wgs84ToWindowCoordinates'](_0x206105,_0x2ffe94);if(!_0x411027)return _0x16116e;if(_0x206105[_0x2474f1(_0x5d63b2._0x741771)]&&_0x206105['mode']===Cesium$1[_0x2474f1(0x15a)]['SCENE3D']){const _0x54671a=new Cesium$1['EllipsoidalOccluder'](_0x206105[_0x2474f1(_0x5d63b2._0x19659a)]['ellipsoid'],_0x206105['camera']['positionWC']),_0x5d172e=_0x54671a['isPointVisible'](_0x2ffe94);if(!_0x5d172e)return _0x16116e;}return[_0x411027['x']-this[_0x2474f1(0x182)][0x0],_0x411027['y']-this['_mapOffset'][0x1]];}['getViewRect'](){const _0x369711={_0x4b3336:0x181},_0x2366e8=_0x2ee574,_0x40caee=this['_api'];return new echarts__namespace[(_0x2366e8(_0x369711._0x4b3336))]['BoundingRect'](0x0,0x0,_0x40caee['getWidth'](),_0x40caee['getHeight']());}['getRoamTransform'](){const _0x160448={_0x1e24f3:0x16a},_0xbc7a2c=_0x2ee574;return echarts__namespace[_0xbc7a2c(_0x160448._0x1e24f3)]['create']();}}CompositeCoordinateSystem['dimensions']=['lng',_0x2ee574(0x158)],CompositeCoordinateSystem[_0x2ee574(0x17e)]=function(_0x29cc3b,_0x41efcb){const _0x30cf5d={_0x342fb0:0x17d,_0x39a4d9:0x174},_0x25f867={_0x477d70:0x171},_0x36750a=_0x2ee574;let _0x4c66e4;const _0x313c53=_0x29cc3b[_0x36750a(0x172)]['ecInstance']['_mars3d_scene'];_0x29cc3b['eachComponent']('mars3dMap',function(_0x2f62cd){const _0x2751d6=_0x36750a,_0x1ad739=_0x41efcb['getZr']()['painter'];if(!_0x1ad739)return;!_0x4c66e4&&(_0x4c66e4=new CompositeCoordinateSystem(_0x313c53,_0x41efcb)),_0x2f62cd['coordinateSystem']=_0x4c66e4,_0x4c66e4[_0x2751d6(_0x25f867._0x477d70)](_0x2f62cd[_0x2751d6(0x16f)]||[0x0,0x0]);}),_0x29cc3b['eachSeries'](function(_0x536378){const _0x4da3ca=_0x36750a;_0x536378[_0x4da3ca(_0x30cf5d._0x342fb0)](_0x4da3ca(_0x30cf5d._0x39a4d9))==='mars3dMap'&&(!_0x4c66e4&&(_0x4c66e4=new CompositeCoordinateSystem(_0x313c53,_0x41efcb)),_0x536378['coordinateSystem']=_0x4c66e4);});};if(echarts__namespace!==null&&echarts__namespace!==void 0x0&&echarts__namespace['init'])echarts__namespace[_0x2ee574(0x149)]('mars3dMap',CompositeCoordinateSystem),echarts__namespace[_0x2ee574(0x15b)]({'type':'mars3dMapRoam','event':'mars3dMapRoam','update':_0x2ee574(0x151)},function(_0x43068f,_0x1592ba){}),echarts__namespace['extendComponentModel']({'type':'mars3dMap','getBMap':function(){return this['_mars3d_scene'];},'defaultOption':{'roam':![]}}),echarts__namespace[_0x2ee574(0x147)]({'type':'mars3dMap','init':function(_0x303b6e,_0x5a19f9){const _0x18d503=_0x2ee574;this['api']=_0x5a19f9,this['scene']=_0x303b6e['scheduler']['ecInstance']['_mars3d_scene'],this[_0x18d503(0x160)]['postRender']['addEventListener'](this['moveHandler'],this);},'moveHandler':function(_0x5257ed,_0x113ca){this['api']['dispatchAction']({'type':'mars3dMapRoam'});},'render':function(_0x5b031b,_0x3a8f38,_0x10dae3){},'dispose':function(_0x21e151){const _0x29f8a8={_0x53ec28:0x168},_0x2f4fd7=_0x2ee574;this['scene']['postRender']['removeEventListener'](this[_0x2f4fd7(_0x29f8a8._0x53ec28)],this);}});else throw new Error(_0x2ee574(0x155));const Cesium=mars3d__namespace['Cesium'],BaseLayer=mars3d__namespace['layer'][_0x2ee574(0x173)];class EchartsLayer extends BaseLayer{constructor(_0x1c9eab={}){super(_0x1c9eab),this['_pointerEvents']=this['options']['pointerEvents'];}get['layer'](){return this['_echartsInstance'];}get['pointerEvents'](){const _0x2bbbbe=_0x2ee574;return this[_0x2bbbbe(0x167)];}set['pointerEvents'](_0x1a0cce){const _0x2f3759={_0xc84bff:0x15e,_0x25f99f:0x152},_0x101b1f=_0x2ee574;this['_pointerEvents']=_0x1a0cce,this['_echartsContainer']&&(_0x1a0cce?this[_0x101b1f(_0x2f3759._0xc84bff)]['style']['pointerEvents']='all':this['_echartsContainer'][_0x101b1f(_0x2f3759._0x25f99f)]['pointerEvents']='none');}['_setOptionsHook'](_0x55a000,_0x575629){this['setEchartsOption'](_0x55a000);}['_showHook'](_0xc82071){const _0x28ce3f={_0x3aba62:0x152,_0x351c80:0x14b},_0xaf5d76=_0x2ee574;_0xc82071?this[_0xaf5d76(0x15e)][_0xaf5d76(_0x28ce3f._0x3aba62)]['visibility']='visible':this['_echartsContainer']['style']['visibility']=_0xaf5d76(_0x28ce3f._0x351c80);}['_mountedHook'](){const _0x4a6e3f={_0x521298:0x165,_0x484618:0x154},_0x1fcc38=_0x2ee574;this[_0x1fcc38(_0x4a6e3f._0x521298)]['scene']['echartsDepthTest']=this['options']['depthTest']??!![],this[_0x1fcc38(0x165)][_0x1fcc38(0x160)]['echartsAutoHeight']=this['options']['clampToGround']??![],this['_map']['scene'][_0x1fcc38(_0x4a6e3f._0x484618)]=this['options']['fixedHeight']??0x0;}[_0x2ee574(0x146)](){const _0x3f07bc={_0xaee3c8:0x15e,_0x4b11cf:0x165},_0x229e56=_0x2ee574;this[_0x229e56(0x15e)]=this['_createChartOverlay'](),this['_echartsInstance']=echarts__namespace['init'](this[_0x229e56(_0x3f07bc._0xaee3c8)]),this['_echartsInstance'][_0x229e56(0x16c)]=this[_0x229e56(_0x3f07bc._0x4b11cf)][_0x229e56(0x160)],this[_0x229e56(0x17c)](this['options']);}['_removedHook'](){const _0x500c31=_0x2ee574;this[_0x500c31(0x170)]&&(this['_echartsInstance']['clear'](),this['_echartsInstance']['dispose'](),delete this['_echartsInstance']),this['_echartsContainer']&&(this[_0x500c31(0x165)]['container']['removeChild'](this['_echartsContainer']),delete this['_echartsContainer']);}['_createChartOverlay'](){const _0x20a21d={_0x3fa1d4:0x165,_0x34ff5d:0x152,_0x625953:0x176},_0x1cd6f0=_0x2ee574,_0x154131=mars3d__namespace[_0x1cd6f0(0x15c)][_0x1cd6f0(0x17e)]('div','mars3d-echarts',this[_0x1cd6f0(_0x20a21d._0x3fa1d4)]['container']);return _0x154131['id']=this['id'],_0x154131['style'][_0x1cd6f0(0x180)]='absolute',_0x154131['style']['top']='0px',_0x154131['style']['left']='0px',_0x154131[_0x1cd6f0(_0x20a21d._0x34ff5d)]['width']=this[_0x1cd6f0(_0x20a21d._0x3fa1d4)]['scene']['canvas'][_0x1cd6f0(_0x20a21d._0x625953)]+'px',_0x154131['style']['height']=this['_map'][_0x1cd6f0(0x160)]['canvas'][_0x1cd6f0(0x17a)]+'px',_0x154131['style']['pointerEvents']=this['_pointerEvents']?'all':'none',_0x154131['style']['zIndex']=this['options']['zIndex']??0x9,_0x154131;}['resize'](){const _0x561915={_0x122818:0x170,_0x1fc26c:0x15f,_0x4a0470:0x165,_0x337505:0x169,_0xd4357d:0x160},_0x3c89bb=_0x2ee574;if(!this[_0x3c89bb(_0x561915._0x122818)])return;this['_echartsContainer'][_0x3c89bb(0x152)][_0x3c89bb(_0x561915._0x1fc26c)]=this[_0x3c89bb(_0x561915._0x4a0470)]['scene']['canvas']['clientWidth']+'px',this[_0x3c89bb(0x15e)]['style'][_0x3c89bb(_0x561915._0x337505)]=this[_0x3c89bb(0x165)][_0x3c89bb(_0x561915._0xd4357d)]['canvas']['clientHeight']+'px',this['_echartsInstance']['resize']();}['setEchartsOption'](_0x4f8e7c,_0x1c8522,_0x207592){const _0x339bc0={_0x36cf61:0x170},_0x5da2a0=_0x2ee574;this[_0x5da2a0(_0x339bc0._0x36cf61)]&&(_0x4f8e7c['mars3dMap']=_0x4f8e7c['mars3dMap']||{},this[_0x5da2a0(0x170)][_0x5da2a0(0x161)](_0x4f8e7c,_0x1c8522,_0x207592));}['getRectangle'](_0x492935){const _0x36cfc2={_0x51867b:0x14e},_0x1596f2=_0x2ee574;let _0x129d7f,_0x16520b,_0x264159,_0x143375;function _0x263512(_0x3cde60){if(!Array['isArray'](_0x3cde60))return;const _0x4fdaec=_0x3cde60[0x0]||0x0,_0x251d9f=_0x3cde60[0x1]||0x0;_0x4fdaec!==0x0&&_0x251d9f!==0x0&&(_0x129d7f===undefined?(_0x129d7f=_0x4fdaec,_0x16520b=_0x4fdaec,_0x264159=_0x251d9f,_0x143375=_0x251d9f):(_0x129d7f=Math['min'](_0x129d7f,_0x4fdaec),_0x16520b=Math['max'](_0x16520b,_0x4fdaec),_0x264159=Math['min'](_0x264159,_0x251d9f),_0x143375=Math['max'](_0x143375,_0x251d9f)));}const _0x419e91=this['options']['series'];_0x419e91&&_0x419e91['forEach'](_0x2aa6da=>{_0x2aa6da['data']&&_0x2aa6da['data']['forEach'](_0x48b13e=>{if(_0x48b13e['value'])_0x263512(_0x48b13e['value']);else _0x48b13e['coords']&&_0x48b13e['coords']['forEach'](_0xd18aa5=>{_0x263512(_0xd18aa5);});});});if(_0x129d7f===0x0&&_0x264159===0x0&&_0x16520b===0x0&&_0x143375===0x0)return null;return _0x492935!==null&&_0x492935!==void 0x0&&_0x492935['isFormat']?{'xmin':_0x129d7f,'xmax':_0x16520b,'ymin':_0x264159,'ymax':_0x143375}:Cesium[_0x1596f2(_0x36cfc2._0x51867b)]['fromDegrees'](_0x129d7f,_0x264159,_0x16520b,_0x143375);}['on'](_0x9aaa81,_0x59db68,_0x42efa7){return this['_echartsInstance']['on'](_0x9aaa81,_0x59db68,_0x42efa7||this),this;}['onByQuery'](_0x25756a,_0x17f885,_0x18d696,_0x2eebfc){return this['_echartsInstance']['on'](_0x25756a,_0x17f885,_0x18d696,_0x2eebfc||this),this;}['off'](_0x59663f,_0x3359d9,_0x189579){const _0x50b59a={_0x73063c:0x175},_0x3d8a5a=_0x2ee574;return this['_echartsInstance'][_0x3d8a5a(_0x50b59a._0x73063c)](_0x59663f,_0x3359d9,_0x189579||this),this;}}function _0x1611(_0x547d2b,_0x26b71a){const _0x40b92f=_0x40b9();return _0x1611=function(_0x1611b6,_0xd404a9){_0x1611b6=_0x1611b6-0x145;let _0x363e67=_0x40b92f[_0x1611b6];return _0x363e67;},_0x1611(_0x547d2b,_0x26b71a);}mars3d__namespace[_0x2ee574(0x17f)][_0x2ee574(0x16e)](_0x2ee574(0x163),EchartsLayer),mars3d__namespace['layer']['EchartsLayer']=EchartsLayer,mars3d__namespace['echarts']=echarts__namespace,exports['EchartsLayer']=EchartsLayer,Object['keys'](echarts)['forEach'](function(_0x632f9d){const _0x21d152={_0x5897ac:0x164},_0x575b07=_0x2ee574;if(_0x632f9d!==_0x575b07(_0x21d152._0x5897ac)&&!exports['hasOwnProperty'](_0x632f9d))Object['defineProperty'](exports,_0x632f9d,{'enumerable':!![],'get':function(){return echarts[_0x632f9d];}});}),Object['defineProperty'](exports,'__esModule',{'value':!![]});
|
|
15
15
|
}));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mars3d-echarts",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.6.0",
|
|
4
4
|
"description": "Mars3D平台插件,结合echarts可视化功能插件",
|
|
5
5
|
"main": "dist/mars3d-echarts.js",
|
|
6
6
|
"files": [
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
"echarts": "^5.4.1"
|
|
11
11
|
},
|
|
12
12
|
"devDependencies": {
|
|
13
|
-
"mars3d": "~3.
|
|
13
|
+
"mars3d": "~3.6.0"
|
|
14
14
|
},
|
|
15
15
|
"scripts": {
|
|
16
16
|
"lint": "eslint ./src/**/*.{js,ts} --fix"
|