@univerjs-pro/sheets-shape 0.22.0 → 0.22.1-insiders.20260515-225d350

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/lib/cjs/facade.js CHANGED
@@ -1 +1 @@
1
- const _0x2d7b2e=_0x6a60;function _0x6a60(_0x25794b,_0xfb9792){_0x25794b=_0x25794b-0xf4;const _0x36eef6=_0x36ee();let _0x6a6081=_0x36eef6[_0x25794b];return _0x6a6081;}(function(_0x561cb6,_0x3859af){const _0x5af7e1=_0x6a60,_0x1bb1df=_0x561cb6();while(!![]){try{const _0x424b9f=parseInt(_0x5af7e1(0x14c))/0x1+parseInt(_0x5af7e1(0x14e))/0x2*(parseInt(_0x5af7e1(0x172))/0x3)+-parseInt(_0x5af7e1(0x129))/0x4*(-parseInt(_0x5af7e1(0x152))/0x5)+-parseInt(_0x5af7e1(0x13c))/0x6*(parseInt(_0x5af7e1(0xfc))/0x7)+parseInt(_0x5af7e1(0x156))/0x8*(-parseInt(_0x5af7e1(0x18e))/0x9)+parseInt(_0x5af7e1(0x12d))/0xa*(-parseInt(_0x5af7e1(0x189))/0xb)+-parseInt(_0x5af7e1(0xf7))/0xc*(parseInt(_0x5af7e1(0x126))/0xd);if(_0x424b9f===_0x3859af)break;else _0x1bb1df['push'](_0x1bb1df['shift']());}catch(_0x3259bc){_0x1bb1df['push'](_0x1bb1df['shift']());}}}(_0x36ee,0x4826e),Object[_0x2d7b2e(0x123)](exports,Symbol[_0x2d7b2e(0x169)],{'value':_0x2d7b2e(0x12c)}));let _univerjs_pro_engine_shape=require('@univerjs-pro/engine-shape'),_univerjs_core_facade=require('@univerjs/core/facade'),_univerjs_pro_sheets_shape=require('@univerjs-pro/sheets-shape'),_univerjs_core=require('@univerjs/core'),_univerjs_drawing=require('@univerjs/drawing'),_univerjs_sheets=require('@univerjs/sheets'),_univerjs_sheets_drawing=require('@univerjs/sheets-drawing'),_univerjs_sheets_facade=require('@univerjs/sheets/facade');var FSheetsShapeEnumMixin=class extends _univerjs_core_facade[_0x2d7b2e(0x165)]{get['ShapeTypeEnum'](){const _0x51845f=_0x2d7b2e;return _univerjs_pro_engine_shape[_0x51845f(0x139)];}get[_0x2d7b2e(0xf9)](){return _univerjs_pro_engine_shape['ShapeFillEnum'];}get[_0x2d7b2e(0xf8)](){const _0x27f3c5=_0x2d7b2e;return _univerjs_pro_engine_shape[_0x27f3c5(0xf8)];}get['ShapeLineTypeEnum'](){const _0xf9c5d6=_0x2d7b2e;return _univerjs_pro_engine_shape[_0xf9c5d6(0x17c)];}get[_0x2d7b2e(0x107)](){const _0x22c146=_0x2d7b2e;return _univerjs_pro_engine_shape[_0x22c146(0x107)];}get[_0x2d7b2e(0x122)](){return _univerjs_pro_engine_shape['ShapeLineCapEnum'];}get[_0x2d7b2e(0x155)](){const _0x58ebed=_0x2d7b2e;return _univerjs_pro_engine_shape[_0x58ebed(0x155)];}get[_0x2d7b2e(0x135)](){const _0x28b827=_0x2d7b2e;return _univerjs_pro_engine_shape[_0x28b827(0x135)];}get['ShapeArrowSizeEnum'](){const _0x53ed59=_0x2d7b2e;return _univerjs_pro_engine_shape[_0x53ed59(0x18b)];}};_univerjs_core_facade[_0x2d7b2e(0x165)][_0x2d7b2e(0x124)](FSheetsShapeEnumMixin);function _typeof(_0x2d9e0a){'@babel/helpers - typeof';const _0x5b75e2=_0x2d7b2e;return _typeof='function'==typeof Symbol&&_0x5b75e2(0x18d)==typeof Symbol[_0x5b75e2(0x125)]?function(_0x8232f){return typeof _0x8232f;}:function(_0x2c721f){const _0x423e54=_0x5b75e2;return _0x2c721f&&_0x423e54(0x11c)==typeof Symbol&&_0x2c721f['constructor']===Symbol&&_0x2c721f!==Symbol[_0x423e54(0x16a)]?'symbol':typeof _0x2c721f;},_typeof(_0x2d9e0a);}function toPrimitive(_0x5996eb,_0x164e25){const _0x292430=_0x2d7b2e;if(_0x292430(0xff)!=_typeof(_0x5996eb)||!_0x5996eb)return _0x5996eb;var _0x8fd060=_0x5996eb[Symbol[_0x292430(0x161)]];if(void 0x0!==_0x8fd060){var _0x5485e2=_0x8fd060[_0x292430(0x112)](_0x5996eb,_0x164e25||'default');if('object'!=_typeof(_0x5485e2))return _0x5485e2;throw new TypeError(_0x292430(0x104));}return(_0x292430(0x110)===_0x164e25?String:Number)(_0x5996eb);}function toPropertyKey(_0x59d8ec){const _0x3a9a65=_0x2d7b2e;var _0x548625=toPrimitive(_0x59d8ec,_0x3a9a65(0x110));return _0x3a9a65(0x18d)==_typeof(_0x548625)?_0x548625:_0x548625+'';}function _0x36ee(){const _0x5e196c=['getConnectionSiteList','lineType','\x20not\x20found','setStrokeWidth','setWidth','setShapeGradientFill','477orHaUc','setStrokeColor','getShapeData','_commandService','type','_resolveEndpoints','setNoneFill','top','updateContext','push','ShapeLineTypeEnum','getStartConnectInfo','Skeleton\x20for\x20unitId\x20','setShapeSolidFill','DRAWING_SHAPE','endArrow','DrawingTypeEnum','executeCommand','stringify','from','gradientType','length','transform','622490VsfWVX','find','ShapeArrowSizeEnum','newShape','symbol','27ukQTjU','relation','generateRandomId','SolidFill','colorStops\x20is\x20required\x20and\x20should\x20contain\x20at\x20least\x20one\x20color\x20stop.','shape','width','opacity','convertPositionCellToSheetOverGrid','NoFill','469428SWkztv','ShapeGradientTypeEnum','ShapeFillEnum','getWorkbook','getConnectionSites','1603ICFvbi','worldRect','FConnectorShape','object','getShapeModel','isConnectorShape','getSheetId','getSize','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','\x20and\x20subUnitId\x20','index','ShapeLineDashEnum','setStrokeLineJoinType','SheetSkeletonService','setStrokeLineDashType','getBasicShapeRotateBound','setStrokeLineType','getShapeType','fill','get','string','gradientAngle','call','rotation','ensureSkeleton','unitId','Invalid\x20shape\x20type\x20for\x20connector.\x20Received\x20','ConnectorCoordinateTransform','left','point','_injector','flipY','function','ang',',\x20but\x20expected\x20a\x20connector\x20shape\x20type.','fillType','getConnectorLinePoints','setEndArrowType','ShapeLineCapEnum','defineProperty','extend','iterator','65GgqtDQ','startArrow','SetShapeDrawingDataCommand','4luTqtu','setPosition','routeConnectorLineShape','Module','10PMWmAd','keys','size','Shape\x20type\x20is\x20required.\x20Please\x20call\x20setShapeType()\x20before\x20build().','getEndConnectInfo','getAdjustValueByName','GradientFill','subUnitId','ShapeArrowTypeEnum','shapeData','cxnIndex','flipX','ShapeTypeEnum','getDrawingData','height','5976JGUgNX','drawingType','adjustValues','gradientStops','parse','setStrokeLineCapType','setShapeType','FWorksheet','FShape','drawId','_resolveExistingOrFreeEndpoint','abs','setStrokeOpacity','ISheetDrawingService','build','setStartArrowSize','527880FLXygC','dashType','6070OzJxSh','lineJoinType','_preloadShapeProperties','getUnitId','1125165yTvGia','connectionSiteIndex','isLineShape','ShapeLineJoinEnum','1225800kxwgOS','updateShape','getDrawingPoints','DEFAULT_SHAPE_WIDTH','getPosition','DEFAULT_SHAPE_HEIGHT','sin','UpdateConnectorRelationCommand','getAdjustPoints','shapeType','computeConnectorRouteLayout','toPrimitive','SheetsShapeService','entries','getDrawingByParam','FEnum','stroke','IDrawingManagerService','lineStrokeType','toStringTag','prototype','getAdjustNames'];_0x36ee=function(){return _0x5e196c;};return _0x36ee();}function _defineProperty(_0x53c341,_0x3d7122,_0x49190c){const _0x13fd3e=_0x2d7b2e;return(_0x3d7122=toPropertyKey(_0x3d7122))in _0x53c341?Object[_0x13fd3e(0x123)](_0x53c341,_0x3d7122,{'value':_0x49190c,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x53c341[_0x3d7122]=_0x49190c,_0x53c341;}var FShape=class{constructor(_0x451bee,_0x16e586,_0x385439,_0x8bc4e2){const _0x40c86c=_0x2d7b2e;_defineProperty(this,_0x40c86c(0x115),void 0x0),_defineProperty(this,_0x40c86c(0x134),void 0x0),_defineProperty(this,_0x40c86c(0x145),void 0x0),_defineProperty(this,'x',0x0),_defineProperty(this,'y',0x0),_defineProperty(this,_0x40c86c(0x194),_univerjs_pro_sheets_shape[_0x40c86c(0x159)]),_defineProperty(this,'height',_univerjs_pro_sheets_shape[_0x40c86c(0x15b)]),_defineProperty(this,_0x40c86c(0x15f),void 0x0),_defineProperty(this,_0x40c86c(0x136),{}),_defineProperty(this,'_injector',void 0x0),this[_0x40c86c(0x115)]=_0x451bee,this['subUnitId']=_0x16e586,this[_0x40c86c(0x145)]=_0x385439||(0x0,_univerjs_core[_0x40c86c(0x190)])(),this['_injector']=_0x8bc4e2;}[_0x2d7b2e(0x12a)](_0x4787e9,_0x2ffe0f,_0x4e8957,_0x1ce24d){const _0x10e118=_0x2d7b2e,_0x303b12=this[_0x10e118(0x11a)]['get'](_univerjs_sheets[_0x10e118(0x109)])[_0x10e118(0x114)](this[_0x10e118(0x115)],this[_0x10e118(0x134)]);if(!_0x303b12)throw new Error(_0x10e118(0x17e)+this[_0x10e118(0x115)]+_0x10e118(0x105)+this[_0x10e118(0x134)]+_0x10e118(0x16e));const {transform:_0x1cfad4}=(0x0,_univerjs_sheets[_0x10e118(0xf5)])(this[_0x10e118(0x115)],this['subUnitId'],{'row':_0x4787e9,'column':_0x2ffe0f,'rowOffset':_0x4e8957,'columnOffset':_0x1ce24d},0x1,0x1,_0x303b12);return this['x']=_0x1cfad4['left'],this['y']=_0x1cfad4['top'],this;}['setAbsolutePosition'](_0x1f9e04,_0x2f5c73){return this['x']=_0x1f9e04,this['y']=_0x2f5c73,this;}[_0x2d7b2e(0x142)](_0x47001e){return this['shapeType']=_0x47001e,this;}[_0x2d7b2e(0x17f)](_0x5d18ff,_0xf1b8d9){const _0x502280=_0x2d7b2e;if(!this[_0x502280(0x136)][_0x502280(0x10e)])this[_0x502280(0x136)]['fill']={};this[_0x502280(0x136)][_0x502280(0x10e)][_0x502280(0x11f)]=_univerjs_pro_engine_shape['ShapeFillEnum'][_0x502280(0x191)];if(_0x5d18ff!==void 0x0)this[_0x502280(0x136)][_0x502280(0x10e)]['color']=_0x5d18ff;if(_0xf1b8d9!==void 0x0)this[_0x502280(0x136)][_0x502280(0x10e)]['opacity']=_0xf1b8d9;return this;}[_0x2d7b2e(0x171)](_0x4388ad,_0x9391d1,_0x3f805b){const _0xb4a396=_0x2d7b2e;if(_0x9391d1===void 0x0||_0x9391d1[_0xb4a396(0x187)]===0x0)throw new Error(_0xb4a396(0x192));if(!this[_0xb4a396(0x136)][_0xb4a396(0x10e)])this[_0xb4a396(0x136)][_0xb4a396(0x10e)]={};this[_0xb4a396(0x136)]['fill'][_0xb4a396(0x13f)]=_0x9391d1,this['shapeData'][_0xb4a396(0x10e)][_0xb4a396(0x11f)]=_univerjs_pro_engine_shape[_0xb4a396(0xf9)][_0xb4a396(0x133)],this[_0xb4a396(0x136)][_0xb4a396(0x10e)][_0xb4a396(0x186)]=_0x4388ad;if(_0x3f805b!==void 0x0)this[_0xb4a396(0x136)][_0xb4a396(0x10e)][_0xb4a396(0x111)]=_0x3f805b;return this;}[_0x2d7b2e(0x178)](){const _0x190256=_0x2d7b2e;return this[_0x190256(0x136)][_0x190256(0x10e)]={'fillType':_univerjs_pro_engine_shape[_0x190256(0xf9)][_0x190256(0xf6)]},this;}[_0x2d7b2e(0x173)](_0x489aae){const _0x23e51f=_0x2d7b2e;if(!this[_0x23e51f(0x136)]['stroke'])this[_0x23e51f(0x136)][_0x23e51f(0x166)]={};return this[_0x23e51f(0x136)][_0x23e51f(0x166)]['color']=_0x489aae,this;}[_0x2d7b2e(0x16f)](_0x3f074c){const _0x5921fc=_0x2d7b2e;if(!this[_0x5921fc(0x136)][_0x5921fc(0x166)])this[_0x5921fc(0x136)][_0x5921fc(0x166)]={};return this[_0x5921fc(0x136)][_0x5921fc(0x166)][_0x5921fc(0x194)]=_0x3f074c,this;}[_0x2d7b2e(0x10a)](_0x39c6ae){const _0xf02d82=_0x2d7b2e;if(!this[_0xf02d82(0x136)][_0xf02d82(0x166)])this[_0xf02d82(0x136)][_0xf02d82(0x166)]={};return this[_0xf02d82(0x136)][_0xf02d82(0x166)][_0xf02d82(0x14d)]=_0x39c6ae,this;}[_0x2d7b2e(0x108)](_0x5aed1e){const _0x2c28cb=_0x2d7b2e;if(!this['shapeData'][_0x2c28cb(0x166)])this[_0x2c28cb(0x136)][_0x2c28cb(0x166)]={};return this[_0x2c28cb(0x136)][_0x2c28cb(0x166)][_0x2c28cb(0x14f)]=_0x5aed1e,this;}[_0x2d7b2e(0x141)](_0x46236c){const _0x3119ff=_0x2d7b2e;if(!this[_0x3119ff(0x136)][_0x3119ff(0x166)])this[_0x3119ff(0x136)][_0x3119ff(0x166)]={};return this['shapeData']['stroke']['capType']=_0x46236c,this;}[_0x2d7b2e(0x148)](_0x805c77){const _0x35fbb3=_0x2d7b2e;if(!this[_0x35fbb3(0x136)][_0x35fbb3(0x166)])this[_0x35fbb3(0x136)][_0x35fbb3(0x166)]={};return this[_0x35fbb3(0x136)][_0x35fbb3(0x166)][_0x35fbb3(0xf4)]=_0x805c77,this;}[_0x2d7b2e(0x10c)](_0x346053){const _0x190371=_0x2d7b2e;if(!this[_0x190371(0x136)][_0x190371(0x166)])this[_0x190371(0x136)]['stroke']={};return this[_0x190371(0x136)][_0x190371(0x166)][_0x190371(0x168)]=_0x346053,this;}[_0x2d7b2e(0x170)](_0x2b9349){const _0x1e8e02=_0x2d7b2e;return this[_0x1e8e02(0x194)]=_0x2b9349,this;}['setHeight'](_0x1a8b4e){const _0x230bd6=_0x2d7b2e;return this[_0x230bd6(0x13b)]=_0x1a8b4e,this;}[_0x2d7b2e(0x154)](){const _0x35e60b=_0x2d7b2e,_0x3aa4ab=this[_0x35e60b(0x11a)][_0x35e60b(0x10f)](_univerjs_pro_sheets_shape['SheetsShapeService'])[_0x35e60b(0x100)](this[_0x35e60b(0x115)],this[_0x35e60b(0x134)],this[_0x35e60b(0x145)]);if(_0x3aa4ab)return(0x0,_univerjs_pro_engine_shape[_0x35e60b(0x101)])(_0x3aa4ab[_0x35e60b(0x10d)]());if(this[_0x35e60b(0x15f)])return(0x0,_univerjs_pro_engine_shape[_0x35e60b(0x101)])(this['shapeType']);return![];}[_0x2d7b2e(0xfb)](){const _0x4f4fff=_0x2d7b2e,_0x443db6=this['_injector'][_0x4f4fff(0x10f)](_univerjs_pro_sheets_shape[_0x4f4fff(0x162)])['getShapeModel'](this['unitId'],this[_0x4f4fff(0x134)],this[_0x4f4fff(0x145)]);if(!_0x443db6)return[];const _0x4660a1=this['_injector'][_0x4f4fff(0x10f)](_univerjs_drawing[_0x4f4fff(0x167)])[_0x4f4fff(0x164)]({'unitId':this[_0x4f4fff(0x115)],'subUnitId':this[_0x4f4fff(0x134)],'drawingId':this[_0x4f4fff(0x145)]});if(!(_0x4660a1===null||_0x4660a1===void 0x0?void 0x0:_0x4660a1[_0x4f4fff(0x188)]))return[];const {width:width=0x0,height:height=0x0}=_0x4660a1[_0x4f4fff(0x188)];return _0x443db6[_0x4f4fff(0x17a)]({'width':width,'height':height}),_0x443db6['getConnectionSiteList']();}[_0x2d7b2e(0x15e)](){const _0x597c8a=_0x2d7b2e,_0x248f00=this[_0x597c8a(0x11a)]['get'](_univerjs_pro_sheets_shape['SheetsShapeService'])[_0x597c8a(0x100)](this[_0x597c8a(0x115)],this[_0x597c8a(0x134)],this[_0x597c8a(0x145)]);if(!_0x248f00)return[];const _0x186c06=this[_0x597c8a(0x11a)]['get'](_univerjs_drawing[_0x597c8a(0x167)])['getDrawingByParam']({'unitId':this[_0x597c8a(0x115)],'subUnitId':this[_0x597c8a(0x134)],'drawingId':this['drawId']});if(!(_0x186c06===null||_0x186c06===void 0x0?void 0x0:_0x186c06[_0x597c8a(0x188)]))return[];const {width:width=0x0,height:height=0x0}=_0x186c06['transform'];return _0x248f00[_0x597c8a(0x17a)]({'width':width,'height':height}),_0x248f00[_0x597c8a(0x158)]();}[_0x2d7b2e(0x120)](){const _0x30b1fa=_0x2d7b2e,_0x1883e1=this[_0x30b1fa(0x11a)][_0x30b1fa(0x10f)](_univerjs_pro_sheets_shape[_0x30b1fa(0x162)])[_0x30b1fa(0x100)](this[_0x30b1fa(0x115)],this[_0x30b1fa(0x134)],this['drawId']);if(!_0x1883e1)return[];if(!(0x0,_univerjs_pro_engine_shape[_0x30b1fa(0x101)])(_0x1883e1['getShapeType']()))return[];const _0x4fc532=this[_0x30b1fa(0x11a)]['get'](_univerjs_drawing['IDrawingManagerService'])['getDrawingByParam']({'unitId':this['unitId'],'subUnitId':this[_0x30b1fa(0x134)],'drawingId':this[_0x30b1fa(0x145)]});if(!(_0x4fc532===null||_0x4fc532===void 0x0?void 0x0:_0x4fc532[_0x30b1fa(0x188)]))return[];const {width:width=0x0,height:height=0x0}=_0x4fc532[_0x30b1fa(0x188)];return _0x1883e1['updateContext']({'width':width,'height':height}),_0x1883e1[_0x30b1fa(0x120)]();}[_0x2d7b2e(0x17d)](){const _0x3de0dc=_0x2d7b2e;var _0x5e217b;const _0x3eaf49=this[_0x3de0dc(0x11a)][_0x3de0dc(0x10f)](_univerjs_pro_sheets_shape['SheetsShapeService'])[_0x3de0dc(0x100)](this[_0x3de0dc(0x115)],this[_0x3de0dc(0x134)],this['drawId']);if(!_0x3eaf49)return null;return(_0x5e217b=_0x3eaf49[_0x3de0dc(0x17d)]())!==null&&_0x5e217b!==void 0x0?_0x5e217b:null;}[_0x2d7b2e(0x131)](){const _0x112565=_0x2d7b2e;var _0x27ebbc;const _0x11ae32=this[_0x112565(0x11a)][_0x112565(0x10f)](_univerjs_pro_sheets_shape[_0x112565(0x162)])[_0x112565(0x100)](this[_0x112565(0x115)],this[_0x112565(0x134)],this[_0x112565(0x145)]);if(!_0x11ae32)return null;return(_0x27ebbc=_0x11ae32[_0x112565(0x131)]())!==null&&_0x27ebbc!==void 0x0?_0x27ebbc:null;}[_0x2d7b2e(0x14a)](){const _0x32852a=_0x2d7b2e;var _0x3f1dbe,_0xfaa018;if(!this[_0x32852a(0x15f)])throw new Error(_0x32852a(0x130));if(this['x']===0x0||this['y']===0x0){const _0x1c17f0=this[_0x32852a(0x11a)][_0x32852a(0x10f)](_univerjs_sheets[_0x32852a(0x109)])['ensureSkeleton'](this[_0x32852a(0x115)],this['subUnitId']);if(!_0x1c17f0)throw new Error(_0x32852a(0x17e)+this[_0x32852a(0x115)]+_0x32852a(0x105)+this[_0x32852a(0x134)]+_0x32852a(0x16e));const {transform:_0x24304d}=(0x0,_univerjs_sheets[_0x32852a(0xf5)])(this[_0x32852a(0x115)],this[_0x32852a(0x134)],{'row':0x1,'column':0x1,'rowOffset':0x0,'columnOffset':0x0},0x1,0x1,_0x1c17f0);this['x']=this['x']>0x0?this['x']:_0x24304d[_0x32852a(0x118)],this['y']=this['y']>0x0?this['y']:_0x24304d[_0x32852a(0x179)];}return this[_0x32852a(0x194)]=(_0x3f1dbe=this['width'])!==null&&_0x3f1dbe!==void 0x0?_0x3f1dbe:_univerjs_pro_sheets_shape['DEFAULT_SHAPE_WIDTH'],this['height']=(_0xfaa018=this[_0x32852a(0x13b)])!==null&&_0xfaa018!==void 0x0?_0xfaa018:_univerjs_pro_sheets_shape[_0x32852a(0x15b)],{'unitId':this[_0x32852a(0x115)],'subUnitId':this[_0x32852a(0x134)],'shapeId':this[_0x32852a(0x145)],'shapeType':this[_0x32852a(0x15f)],'shapeData':Object[_0x32852a(0x12e)](this[_0x32852a(0x136)])[_0x32852a(0x187)]>0x0?this['shapeData']:void 0x0,'x':this['x'],'y':this['y'],'width':this[_0x32852a(0x194)],'height':this[_0x32852a(0x13b)]};}['getShapeId'](){const _0x308fe3=_0x2d7b2e;return this[_0x308fe3(0x145)];}[_0x2d7b2e(0x10d)](){const _0x19bd56=_0x2d7b2e;return this[_0x19bd56(0x15f)];}[_0x2d7b2e(0x174)](){const _0x20b98b=_0x2d7b2e;return this[_0x20b98b(0x136)];}[_0x2d7b2e(0x15a)](){return{'x':this['x'],'y':this['y']};}[_0x2d7b2e(0x103)](){const _0x4a6c78=_0x2d7b2e;return{'width':this[_0x4a6c78(0x194)],'height':this[_0x4a6c78(0x13b)]};}},FConnectorShape=class extends FShape{constructor(_0x892e5f,_0x37b044,_0x38e792,_0x546b85){super(_0x892e5f,_0x37b044,_0x38e792,_0x546b85),_defineProperty(this,'shapeData',{});}[_0x2d7b2e(0x142)](_0x29cf55){const _0x3d85d0=_0x2d7b2e;if(!(0x0,_univerjs_pro_engine_shape[_0x3d85d0(0x101)])(_0x29cf55))throw new Error(_0x3d85d0(0x116)+_0x29cf55+_0x3d85d0(0x11e));return super[_0x3d85d0(0x142)](_0x29cf55),this;}['setStartArrowType'](_0x299d18){const _0x38632b=_0x2d7b2e;var _0x327244,_0x4f6a67;if(!((_0x327244=this[_0x38632b(0x136)])===null||_0x327244===void 0x0?void 0x0:_0x327244['ln']))this[_0x38632b(0x136)]['ln']={};if(!((_0x4f6a67=this[_0x38632b(0x136)])===null||_0x4f6a67===void 0x0||(_0x4f6a67=_0x4f6a67['ln'])===null||_0x4f6a67===void 0x0?void 0x0:_0x4f6a67[_0x38632b(0x127)]))this[_0x38632b(0x136)]['ln']['startArrow']={};return this['shapeData']['ln'][_0x38632b(0x127)][_0x38632b(0x176)]=_0x299d18,this;}[_0x2d7b2e(0x121)](_0x235342){const _0x1b790c=_0x2d7b2e;var _0x188003,_0x1c746f;if(!((_0x188003=this[_0x1b790c(0x136)])===null||_0x188003===void 0x0?void 0x0:_0x188003['ln']))this['shapeData']['ln']={};if(!((_0x1c746f=this[_0x1b790c(0x136)])===null||_0x1c746f===void 0x0||(_0x1c746f=_0x1c746f['ln'])===null||_0x1c746f===void 0x0?void 0x0:_0x1c746f[_0x1b790c(0x181)]))this[_0x1b790c(0x136)]['ln'][_0x1b790c(0x181)]={};return this[_0x1b790c(0x136)]['ln']['endArrow'][_0x1b790c(0x176)]=_0x235342,this;}[_0x2d7b2e(0x14b)](_0x4381c4){const _0x55ecf9=_0x2d7b2e;var _0x1c126b,_0x3440bd;if(!((_0x1c126b=this[_0x55ecf9(0x136)])===null||_0x1c126b===void 0x0?void 0x0:_0x1c126b['ln']))this[_0x55ecf9(0x136)]['ln']={};if(!((_0x3440bd=this[_0x55ecf9(0x136)])===null||_0x3440bd===void 0x0||(_0x3440bd=_0x3440bd['ln'])===null||_0x3440bd===void 0x0?void 0x0:_0x3440bd['startArrow']))this[_0x55ecf9(0x136)]['ln']['startArrow']={};return this[_0x55ecf9(0x136)]['ln'][_0x55ecf9(0x127)][_0x55ecf9(0x12f)]=_0x4381c4,this;}['setEndArrowSize'](_0x23a339){const _0x2f9d53=_0x2d7b2e;var _0x3ab94d,_0x1ce263;if(!((_0x3ab94d=this[_0x2f9d53(0x136)])===null||_0x3ab94d===void 0x0?void 0x0:_0x3ab94d['ln']))this['shapeData']['ln']={};if(!((_0x1ce263=this[_0x2f9d53(0x136)])===null||_0x1ce263===void 0x0||(_0x1ce263=_0x1ce263['ln'])===null||_0x1ce263===void 0x0?void 0x0:_0x1ce263[_0x2f9d53(0x181)]))this[_0x2f9d53(0x136)]['ln'][_0x2f9d53(0x181)]={};return this[_0x2f9d53(0x136)]['ln'][_0x2f9d53(0x181)][_0x2f9d53(0x12f)]=_0x23a339,this;}[_0x2d7b2e(0x14a)](){const _0x374aa8=_0x2d7b2e;return super[_0x374aa8(0x14a)]();}['getEndConnectInfo'](){const _0x4af340=_0x2d7b2e;var _0x20fea5;return((_0x20fea5=this[_0x4af340(0x136)])===null||_0x20fea5===void 0x0||(_0x20fea5=_0x20fea5[_0x4af340(0x18f)])===null||_0x20fea5===void 0x0?void 0x0:_0x20fea5['to'])||null;}[_0x2d7b2e(0x17d)](){const _0x3d24d8=_0x2d7b2e;var _0x4be542;return((_0x4be542=this[_0x3d24d8(0x136)])===null||_0x4be542===void 0x0||(_0x4be542=_0x4be542[_0x3d24d8(0x18f)])===null||_0x4be542===void 0x0?void 0x0:_0x4be542[_0x3d24d8(0x185)])||null;}};function computeConnectionPointInfo(_0x158d16,_0x598cf7,_0x36fa82,_0x3c833f,_0x29e155,_0x3e548a){const _0x23d48f=_0x2d7b2e,_0x2343ff=_0x29e155[_0x23d48f(0x100)](_0x158d16,_0x598cf7,_0x36fa82);if(!_0x2343ff)return null;const _0x3844ec=_0x3e548a[_0x23d48f(0x164)]({'unitId':_0x158d16,'subUnitId':_0x598cf7,'drawingId':_0x36fa82});if(!(_0x3844ec===null||_0x3844ec===void 0x0?void 0x0:_0x3844ec[_0x23d48f(0x188)]))return null;const {left:left=0x0,top:top=0x0,width:width=0x0,height:height=0x0,flipX:flipX=![],flipY:flipY=![],angle:_0x26d7a1}=_0x3844ec[_0x23d48f(0x188)];_0x2343ff[_0x23d48f(0x17a)]({'width':width,'height':height});const _0x305b69=_0x2343ff[_0x23d48f(0x16c)]()[_0x23d48f(0x18a)](_0x1eb7a0=>_0x1eb7a0[_0x23d48f(0x106)]===_0x3c833f);if(!_0x305b69)return null;let _0x148849=flipX?width-_0x305b69['x']:_0x305b69['x'],_0x11d593=flipY?height-_0x305b69['y']:_0x305b69['y'];if(_0x26d7a1&&_0x26d7a1!==0x0){const _0x45ec9a=_0x26d7a1*Math['PI']/0xb4,_0x4d1220=Math['cos'](_0x45ec9a),_0x24e76e=Math[_0x23d48f(0x15c)](_0x45ec9a),_0x4bec12=width/0x2,_0x505c02=height/0x2,_0x2d194a=_0x148849-_0x4bec12,_0x501cc9=_0x11d593-_0x505c02;_0x148849=_0x4bec12+_0x2d194a*_0x4d1220-_0x501cc9*_0x24e76e,_0x11d593=_0x505c02+_0x2d194a*_0x24e76e+_0x501cc9*_0x4d1220;}_0x148849+=left,_0x11d593+=top;let _0x4bce2d=_0x305b69[_0x23d48f(0x11d)]/0xea60;if(flipX)_0x4bce2d=0xb4-_0x4bce2d;if(flipY)_0x4bce2d=-_0x4bce2d;_0x4bce2d+=_0x26d7a1||0x0,_0x4bce2d=(_0x4bce2d%0x168+0x168)%0x168;const _0x3a2645=(0x0,_univerjs_pro_engine_shape[_0x23d48f(0x10b)])({'left':left,'top':top,'width':width,'height':height},_0x26d7a1||0x0);return{'point':{'x':_0x148849,'y':_0x11d593},'angle':_0x4bce2d,'bounds':_0x3a2645};}function calculateFreeEndpointAngle(_0x5fd981,_0x5b92a8){const _0xde95b=_0x2d7b2e,_0x3db834=_0x5b92a8['x']-_0x5fd981['x'],_0x27b9a4=_0x5b92a8['y']-_0x5fd981['y'];if(Math[_0xde95b(0x147)](_0x3db834)>=Math[_0xde95b(0x147)](_0x27b9a4))return _0x3db834>=0x0?0xb4:0x0;return _0x27b9a4>=0x0?0x10e:0x5a;}function computeFreeEndpointInfo(_0x33dc70,_0x10b3ff,_0x5e21c1,_0x2d52db,_0x3ae86a,_0x55b8ac,_0x267e11){const _0x1071b9=_0x2d7b2e,_0x305ea9=_0x55b8ac['getShapeModel'](_0x33dc70,_0x10b3ff,_0x5e21c1);if(!_0x305ea9)return null;const _0x267283=_0x267e11[_0x1071b9(0x164)]({'unitId':_0x33dc70,'subUnitId':_0x10b3ff,'drawingId':_0x5e21c1});if(!(_0x267283===null||_0x267283===void 0x0?void 0x0:_0x267283[_0x1071b9(0x188)]))return null;const {left:left=0x0,top:top=0x0,width:width=0x0,height:height=0x0,flipX:flipX=![],flipY:flipY=![]}=_0x267283[_0x1071b9(0x188)];_0x305ea9[_0x1071b9(0x17a)]({'width':width,'height':height});const _0x13fbaf=_0x305ea9[_0x1071b9(0x120)]();if(_0x13fbaf[_0x1071b9(0x187)]<0x2)return null;const _0x498ce3=_0x2d52db?_0x13fbaf[0x0]:_0x13fbaf[_0x13fbaf[_0x1071b9(0x187)]-0x1],_0x23c44c=new _univerjs_pro_engine_shape[(_0x1071b9(0x117))]({'left':left,'top':top,'width':width,'height':height,'flipX':flipX,'flipY':flipY})['localToWorld'](_0x498ce3);return{'point':_0x23c44c,'angle':calculateFreeEndpointAngle(_0x3ae86a[_0x1071b9(0x119)],_0x23c44c),'bounds':{'left':_0x23c44c['x'],'top':_0x23c44c['y'],'width':0x0,'height':0x0}};}var FWorksheetShapeMixin=class extends _univerjs_sheets_facade[_0x2d7b2e(0x143)]{async['insertShape'](_0x50d735){const _0x2f4f18=_0x2d7b2e,{unitId:_0x567fca,subUnitId:_0x58e423,shapeId:_0x3ccbd8,shapeType:_0x168973,shapeData:_0x328810,x:_0x487adf,y:_0x1f5d5d,width:_0x2d3334,height:_0x5f36ba}=_0x50d735;return this[_0x2f4f18(0x175)]['executeCommand'](_univerjs_pro_sheets_shape['InsertShapeCommand']['id'],{'unitId':_0x567fca,'subUnitId':_0x58e423,'shapeId':_0x3ccbd8,'shapeType':_0x168973,'shapeData':_0x328810,'position':{'x':_0x487adf,'y':_0x1f5d5d},'width':_0x2d3334,'height':_0x5f36ba});}async[_0x2d7b2e(0x157)](_0x31ea2d){const _0x2fd384=_0x2d7b2e,{unitId:_0x233731,subUnitId:_0x10fbfc,shapeId:_0x50aec6,shapeType:_0x4c5ca0,shapeData:_0x502755,x:_0x24a966,y:_0x207eaf,width:_0xc4d0d8,height:_0xb6b469}=_0x31ea2d;return this[_0x2fd384(0x175)][_0x2fd384(0x183)](_univerjs_pro_sheets_shape[_0x2fd384(0x128)]['id'],{'unitId':_0x233731,'subUnitId':_0x10fbfc,'shapeId':_0x50aec6,'shapeType':_0x4c5ca0,'shapeData':_0x502755,'position':{'x':_0x24a966,'y':_0x207eaf},'width':_0xc4d0d8,'height':_0xb6b469});}[_0x2d7b2e(0x18c)](_0x308a27){const _0x171ff3=_0x2d7b2e,_0x557fb2=this['getWorkbook']()[_0x171ff3(0x151)](),_0x3793f4=this['getSheetId']();if(_0x308a27){const _0x4cf3d4=new FShape(_0x557fb2,_0x3793f4,_0x308a27[_0x171ff3(0x145)],this[_0x171ff3(0x11a)]);return this[_0x171ff3(0x150)](_0x4cf3d4,_0x557fb2,_0x3793f4,_0x308a27[_0x171ff3(0x145)]),_0x4cf3d4;}return new FShape(_0x557fb2,_0x3793f4,(0x0,_univerjs_core[_0x171ff3(0x190)])(),this['_injector']);}['newConnector'](_0xf5d752){const _0x2dae03=_0x2d7b2e,_0x39e4db=this[_0x2dae03(0xfa)]()['getUnitId'](),_0x1fc8ab=this[_0x2dae03(0x102)]();if(_0xf5d752){const _0xbba2c6=new FConnectorShape(_0x39e4db,_0x1fc8ab,_0xf5d752[_0x2dae03(0x145)],this[_0x2dae03(0x11a)]);return this[_0x2dae03(0x150)](_0xbba2c6,_0x39e4db,_0x1fc8ab,_0xf5d752['drawId']),_0xbba2c6;}return new FConnectorShape(_0x39e4db,_0x1fc8ab,(0x0,_univerjs_core['generateRandomId'])(),this[_0x2dae03(0x11a)]);}['getShapes'](){const _0x3425be=_0x2d7b2e,_0x40b9cf=this[_0x3425be(0x11a)][_0x3425be(0x10f)](_univerjs_sheets_drawing[_0x3425be(0x149)]),_0x259a37=this[_0x3425be(0xfa)]()[_0x3425be(0x151)](),_0x544cf7=this['getSheetId'](),_0x32d61d=_0x40b9cf[_0x3425be(0x13a)](_0x259a37,_0x544cf7);if(!_0x32d61d)return[];const _0x4e1045=[];for(const [_0x1e9cb1,_0x5ae722]of Object[_0x3425be(0x163)](_0x32d61d))if(_0x5ae722&&_0x5ae722[_0x3425be(0x13d)]===_univerjs_core[_0x3425be(0x182)][_0x3425be(0x180)]){const _0x1dd18b=new FShape(_0x259a37,_0x544cf7,_0x1e9cb1,this[_0x3425be(0x11a)]);this[_0x3425be(0x150)](_0x1dd18b,_0x259a37,_0x544cf7,_0x1e9cb1),_0x4e1045[_0x3425be(0x17b)](_0x1dd18b);}return _0x4e1045;}['removeShape'](_0x185546){const _0x215422=_0x2d7b2e,{unitId:_0x26148a,subUnitId:_0x394563,drawId:_0x2d3198}=_0x185546;return this[_0x215422(0x175)][_0x215422(0x183)](_univerjs_sheets_drawing['RemoveSheetDrawingCommand']['id'],{'unitId':_0x26148a,'drawings':[{'unitId':_0x26148a,'subUnitId':_0x394563,'drawingId':_0x2d3198,'drawingType':_univerjs_core[_0x215422(0x182)][_0x215422(0x180)]}]});}async['connectShapes'](_0x3a0ca8){const _0x2143c9=_0x2d7b2e,{connector:_0x448c7c,startTarget:_0x1173a8,endTarget:_0x1921e7}=_0x3a0ca8;if(!_0x1173a8&&!_0x1921e7)return![];const _0x55504c=this['getWorkbook']()[_0x2143c9(0x151)](),_0x11c3f=this['getSheetId'](),_0x3ef40a=this[_0x2143c9(0x11a)][_0x2143c9(0x10f)](_univerjs_pro_sheets_shape[_0x2143c9(0x162)]),_0x4b6a69=this[_0x2143c9(0x11a)][_0x2143c9(0x10f)](_univerjs_drawing['IDrawingManagerService']),_0x5d3b31=_0x3ef40a[_0x2143c9(0x100)](_0x55504c,_0x11c3f,_0x448c7c[_0x2143c9(0x145)]);if(!_0x5d3b31)return![];const _0x62c186=_0x5d3b31['getShapeType'](),_0x347715=_0x5d3b31['getShapeRelation'](),_0x1ec0cb={};for(const _0x7c9635 of _0x5d3b31[_0x2143c9(0x16b)]()){const _0x41833b=_0x5d3b31[_0x2143c9(0x132)](_0x7c9635);if(_0x41833b!==void 0x0)_0x1ec0cb[_0x7c9635]=_0x41833b;}const {startInfo:_0x2664c9,endInfo:_0x3dcbf9}=this['_resolveEndpoints'](_0x55504c,_0x11c3f,_0x448c7c,_0x5d3b31,_0x1173a8,_0x1921e7,_0x3ef40a,_0x4b6a69,_0x347715);if(!_0x2664c9||!_0x3dcbf9)return![];const _0x555fa1=(0x0,_univerjs_pro_engine_shape[_0x2143c9(0x160)])((0x0,_univerjs_pro_engine_shape[_0x2143c9(0x12b)])(_0x2664c9,_0x3dcbf9,_0x62c186),_0x62c186),_0x4e81cd={};if(_0x1173a8)_0x4e81cd['from']={'shapeId':_0x1173a8['shape'][_0x2143c9(0x145)],'cxnIndex':_0x1173a8[_0x2143c9(0x153)]};else{if(_0x347715===null||_0x347715===void 0x0?void 0x0:_0x347715[_0x2143c9(0x185)])_0x4e81cd['from']=_0x347715[_0x2143c9(0x185)];}if(_0x1921e7)_0x4e81cd['to']={'shapeId':_0x1921e7[_0x2143c9(0x193)][_0x2143c9(0x145)],'cxnIndex':_0x1921e7[_0x2143c9(0x153)]};else{if(_0x347715===null||_0x347715===void 0x0?void 0x0:_0x347715['to'])_0x4e81cd['to']=_0x347715['to'];}return this[_0x2143c9(0x175)]['executeCommand'](_univerjs_pro_sheets_shape[_0x2143c9(0x15d)]['id'],{'unitId':_0x55504c,'subUnitId':_0x11c3f,'connectorShapeId':_0x448c7c[_0x2143c9(0x145)],'width':_0x555fa1['worldRect'][_0x2143c9(0x194)],'height':_0x555fa1[_0x2143c9(0xfd)][_0x2143c9(0x13b)],'left':_0x555fa1['worldRect'][_0x2143c9(0x118)],'top':_0x555fa1[_0x2143c9(0xfd)][_0x2143c9(0x179)],'flipX':_0x555fa1[_0x2143c9(0xfd)][_0x2143c9(0x138)]||![],'flipY':_0x555fa1[_0x2143c9(0xfd)][_0x2143c9(0x11b)]||![],'oldAdjustValues':_0x1ec0cb,'newAdjustValues':_0x555fa1[_0x2143c9(0x13e)],'newLineType':_0x555fa1[_0x2143c9(0x16d)],'oldLineType':_0x62c186,'rotation':_0x555fa1[_0x2143c9(0x113)],'oldRelation':_0x347715,'newRelation':_0x4e81cd});}[_0x2d7b2e(0x150)](_0x353b95,_0x3ec829,_0x4a8eda,_0x296fb6){const _0x3b7003=_0x2d7b2e,_0x395f8b=this[_0x3b7003(0x11a)][_0x3b7003(0x10f)](_univerjs_drawing[_0x3b7003(0x167)])['getDrawingByParam']({'unitId':_0x3ec829,'subUnitId':_0x4a8eda,'drawingId':_0x296fb6});if(_0x395f8b===null||_0x395f8b===void 0x0?void 0x0:_0x395f8b[_0x3b7003(0x188)]){var _0x55979a,_0x25493d,_0x1e38e0,_0x4b4fed;_0x353b95['x']=(_0x55979a=_0x395f8b['transform'][_0x3b7003(0x118)])!==null&&_0x55979a!==void 0x0?_0x55979a:0x0,_0x353b95['y']=(_0x25493d=_0x395f8b[_0x3b7003(0x188)][_0x3b7003(0x179)])!==null&&_0x25493d!==void 0x0?_0x25493d:0x0,_0x353b95[_0x3b7003(0x194)]=(_0x1e38e0=_0x395f8b[_0x3b7003(0x188)][_0x3b7003(0x194)])!==null&&_0x1e38e0!==void 0x0?_0x1e38e0:_0x353b95[_0x3b7003(0x194)],_0x353b95[_0x3b7003(0x13b)]=(_0x4b4fed=_0x395f8b[_0x3b7003(0x188)][_0x3b7003(0x13b)])!==null&&_0x4b4fed!==void 0x0?_0x4b4fed:_0x353b95[_0x3b7003(0x13b)];}const _0x29de72=this[_0x3b7003(0x11a)]['get'](_univerjs_pro_sheets_shape[_0x3b7003(0x162)])[_0x3b7003(0x100)](_0x3ec829,_0x4a8eda,_0x296fb6);if(_0x29de72){_0x353b95[_0x3b7003(0x15f)]=_0x29de72[_0x3b7003(0x10d)]();const _0x475cd8=_0x29de72['getShapeData']();if(_0x475cd8)_0x353b95[_0x3b7003(0x136)]=JSON[_0x3b7003(0x140)](JSON[_0x3b7003(0x184)](_0x475cd8));}}[_0x2d7b2e(0x177)](_0x1804fa,_0x144b42,_0xc40324,_0x45390b,_0x12dfd5,_0x159759,_0x471964,_0x54ee0f,_0x7b2172){const _0x40b0fd=_0x2d7b2e;let _0x43c803=null,_0x38ac3c=null;if(_0x12dfd5)_0x43c803=computeConnectionPointInfo(_0x1804fa,_0x144b42,_0x12dfd5[_0x40b0fd(0x193)][_0x40b0fd(0x145)],_0x12dfd5[_0x40b0fd(0x153)],_0x471964,_0x54ee0f);if(_0x159759)_0x38ac3c=computeConnectionPointInfo(_0x1804fa,_0x144b42,_0x159759['shape'][_0x40b0fd(0x145)],_0x159759[_0x40b0fd(0x153)],_0x471964,_0x54ee0f);if(!_0x43c803)_0x43c803=this[_0x40b0fd(0x146)](_0x1804fa,_0x144b42,_0xc40324[_0x40b0fd(0x145)],!![],_0x38ac3c,_0x7b2172===null||_0x7b2172===void 0x0?void 0x0:_0x7b2172[_0x40b0fd(0x185)],_0x471964,_0x54ee0f);if(!_0x38ac3c)_0x38ac3c=this['_resolveExistingOrFreeEndpoint'](_0x1804fa,_0x144b42,_0xc40324[_0x40b0fd(0x145)],![],_0x43c803,_0x7b2172===null||_0x7b2172===void 0x0?void 0x0:_0x7b2172['to'],_0x471964,_0x54ee0f);return{'startInfo':_0x43c803,'endInfo':_0x38ac3c};}[_0x2d7b2e(0x146)](_0x5eb03b,_0x572a8a,_0x393703,_0x53eb6d,_0x3f0699,_0x9831fb,_0x5cfaeb,_0x10549a){const _0x48b901=_0x2d7b2e;if(_0x9831fb){const _0x4c7dce=computeConnectionPointInfo(_0x5eb03b,_0x572a8a,_0x9831fb['shapeId'],_0x9831fb[_0x48b901(0x137)],_0x5cfaeb,_0x10549a);if(_0x4c7dce)return _0x4c7dce;}if(!_0x3f0699)return null;return computeFreeEndpointInfo(_0x5eb03b,_0x572a8a,_0x393703,_0x53eb6d,_0x3f0699,_0x5cfaeb,_0x10549a);}};_univerjs_sheets_facade['FWorksheet'][_0x2d7b2e(0x124)](FWorksheetShapeMixin),exports[_0x2d7b2e(0xfe)]=FConnectorShape,exports[_0x2d7b2e(0x144)]=FShape;
1
+ const _0x4a2ac5=_0x9e0d;(function(_0x58ca09,_0x1f5788){const _0x1481fb=_0x9e0d,_0x19b005=_0x58ca09();while(!![]){try{const _0x167d57=-parseInt(_0x1481fb(0x1fc))/0x1+parseInt(_0x1481fb(0x26a))/0x2*(-parseInt(_0x1481fb(0x1e7))/0x3)+parseInt(_0x1481fb(0x275))/0x4+-parseInt(_0x1481fb(0x269))/0x5*(parseInt(_0x1481fb(0x1f4))/0x6)+parseInt(_0x1481fb(0x276))/0x7*(-parseInt(_0x1481fb(0x248))/0x8)+parseInt(_0x1481fb(0x267))/0x9+-parseInt(_0x1481fb(0x1fd))/0xa*(-parseInt(_0x1481fb(0x224))/0xb);if(_0x167d57===_0x1f5788)break;else _0x19b005['push'](_0x19b005['shift']());}catch(_0x410c9c){_0x19b005['push'](_0x19b005['shift']());}}}(_0x56e3,0xb80a6),Object[_0x4a2ac5(0x21f)](exports,Symbol[_0x4a2ac5(0x21e)],{'value':'Module'}));function _0x56e3(){const _0x1debea=['toPrimitive','350gxRWVq','110kLYaWR','ShapeLineCapEnum','left','_resolveEndpoints','from','dashType','point','flipY','shapeData','insertShape','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','584280rdQFzV','644MdWKld','colorStops\x20is\x20required\x20and\x20should\x20contain\x20at\x20least\x20one\x20color\x20stop.','lineJoinType','setAbsolutePosition','executeCommand','getDrawingData','ensureSkeleton','shape','_commandService','get','removeShape','lineStrokeType','UpdateConnectorRelationCommand','fill','length','20721nxxlyJ','SheetSkeletonService','transform','gradientAngle','cos','shapeType','build','ang','function','getPosition','sin','getConnectorLinePoints','worldRect','21864QTeCss','setEndArrowSize','ShapeArrowSizeEnum','top','getShapes','Skeleton\x20for\x20unitId\x20','DRAWING_SHAPE','entries','123170xfqOcJ','25110630bOqylu','call','prototype','RemoveSheetDrawingCommand','setStrokeColor','getEndConnectInfo','type','setStrokeLineCapType','getShapeType','DEFAULT_SHAPE_WIDTH','getAdjustPoints','ShapeArrowTypeEnum','relation','DEFAULT_SHAPE_HEIGHT','stringify','Shape\x20type\x20is\x20required.\x20Please\x20call\x20setShapeType()\x20before\x20build().',',\x20but\x20expected\x20a\x20connector\x20shape\x20type.','size','getSheetId','abs','DrawingTypeEnum','_preloadShapeProperties','IDrawingManagerService','getDrawingPoints','string','FShape','FEnum','getAdjustNames','setEndArrowType','extend','color','getDrawingByParam','symbol','toStringTag','defineProperty','generateRandomId','iterator','startArrow','updateContext','11cPaXoI','index','getShapeRelation','getConnectionSiteList','ShapeLineTypeEnum','getBasicShapeRotateBound','width','routeConnectorLineShape','capType','isLineShape','convertPositionCellToSheetOverGrid','setStrokeWidth','getShapeId','subUnitId','getSize','getWorkbook','connectionSiteIndex','setPosition','shapeId','getUnitId','gradientType','_resolveExistingOrFreeEndpoint','getStartConnectInfo','setShapeType','parse','adjustValues','keys','Invalid\x20shape\x20type\x20for\x20connector.\x20Received\x20','FWorksheet','object','setStrokeLineDashType','SolidFill','stroke','\x20not\x20found','getAdjustValueByName','getShapeModel','113480cymfEU','computeConnectorRouteLayout','rotation','\x20and\x20subUnitId\x20','unitId','setNoneFill','getConnectionSites','ShapeGradientTypeEnum','ISheetDrawingService','SheetsShapeService','drawingType','getShapeData','_injector','updateShape','find','setShapeSolidFill','drawId','InsertShapeCommand','NoFill','flipX','ShapeLineJoinEnum','opacity','ShapeFillEnum','FConnectorShape','setStrokeOpacity','ShapeLineDashEnum','endArrow','isConnectorShape','setStrokeLineType','default','height','1438668NjTeeV'];_0x56e3=function(){return _0x1debea;};return _0x56e3();}let _univerjs_pro_engine_shape=require('@univerjs-pro/engine-shape'),_univerjs_core_facade=require('@univerjs/core/facade'),_univerjs_pro_sheets_shape=require('@univerjs-pro/sheets-shape'),_univerjs_core=require('@univerjs/core'),_univerjs_drawing=require('@univerjs/drawing'),_univerjs_sheets=require('@univerjs/sheets'),_univerjs_sheets_drawing=require('@univerjs/sheets-drawing'),_univerjs_sheets_facade=require('@univerjs/sheets/facade');var FSheetsShapeEnumMixin=class extends _univerjs_core_facade[_0x4a2ac5(0x217)]{get['ShapeTypeEnum'](){return _univerjs_pro_engine_shape['ShapeTypeEnum'];}get[_0x4a2ac5(0x25e)](){const _0x3186c9=_0x4a2ac5;return _univerjs_pro_engine_shape[_0x3186c9(0x25e)];}get[_0x4a2ac5(0x24f)](){const _0x2ee048=_0x4a2ac5;return _univerjs_pro_engine_shape[_0x2ee048(0x24f)];}get[_0x4a2ac5(0x228)](){const _0x173949=_0x4a2ac5;return _univerjs_pro_engine_shape[_0x173949(0x228)];}get[_0x4a2ac5(0x261)](){const _0x50bfd8=_0x4a2ac5;return _univerjs_pro_engine_shape[_0x50bfd8(0x261)];}get[_0x4a2ac5(0x26b)](){return _univerjs_pro_engine_shape['ShapeLineCapEnum'];}get[_0x4a2ac5(0x25c)](){return _univerjs_pro_engine_shape['ShapeLineJoinEnum'];}get['ShapeArrowTypeEnum'](){const _0x8a38b2=_0x4a2ac5;return _univerjs_pro_engine_shape[_0x8a38b2(0x208)];}get[_0x4a2ac5(0x1f6)](){return _univerjs_pro_engine_shape['ShapeArrowSizeEnum'];}};_univerjs_core_facade['FEnum'][_0x4a2ac5(0x21a)](FSheetsShapeEnumMixin);function _typeof(_0x33f8ff){'@babel/helpers - typeof';const _0xc2e2e7=_0x4a2ac5;return _typeof=_0xc2e2e7(0x1ef)==typeof Symbol&&_0xc2e2e7(0x21d)==typeof Symbol[_0xc2e2e7(0x221)]?function(_0x2874a8){return typeof _0x2874a8;}:function(_0x45e537){const _0x5c03f7=_0xc2e2e7;return _0x45e537&&_0x5c03f7(0x1ef)==typeof Symbol&&_0x45e537['constructor']===Symbol&&_0x45e537!==Symbol[_0x5c03f7(0x1ff)]?_0x5c03f7(0x21d):typeof _0x45e537;},_typeof(_0x33f8ff);}function toPrimitive(_0x488aed,_0x19cdea){const _0x42fbe0=_0x4a2ac5;if(_0x42fbe0(0x241)!=_typeof(_0x488aed)||!_0x488aed)return _0x488aed;var _0x467225=_0x488aed[Symbol[_0x42fbe0(0x268)]];if(void 0x0!==_0x467225){var _0x86c7cd=_0x467225[_0x42fbe0(0x1fe)](_0x488aed,_0x19cdea||_0x42fbe0(0x265));if(_0x42fbe0(0x241)!=_typeof(_0x86c7cd))return _0x86c7cd;throw new TypeError(_0x42fbe0(0x274));}return(_0x42fbe0(0x215)===_0x19cdea?String:Number)(_0x488aed);}function toPropertyKey(_0x5cc9b0){const _0xca20d3=_0x4a2ac5;var _0x588c2a=toPrimitive(_0x5cc9b0,_0xca20d3(0x215));return _0xca20d3(0x21d)==_typeof(_0x588c2a)?_0x588c2a:_0x588c2a+'';}function _defineProperty(_0x55ca40,_0x476c19,_0x1a4422){const _0x16453c=_0x4a2ac5;return(_0x476c19=toPropertyKey(_0x476c19))in _0x55ca40?Object[_0x16453c(0x21f)](_0x55ca40,_0x476c19,{'value':_0x1a4422,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x55ca40[_0x476c19]=_0x1a4422,_0x55ca40;}var FShape=class{constructor(_0x41d7fc,_0x336bdb,_0x3ecab0,_0x40117e){const _0x5b2a19=_0x4a2ac5;_defineProperty(this,_0x5b2a19(0x24c),void 0x0),_defineProperty(this,_0x5b2a19(0x231),void 0x0),_defineProperty(this,_0x5b2a19(0x258),void 0x0),_defineProperty(this,'x',0x0),_defineProperty(this,'y',0x0),_defineProperty(this,_0x5b2a19(0x22a),_univerjs_pro_sheets_shape[_0x5b2a19(0x206)]),_defineProperty(this,_0x5b2a19(0x266),_univerjs_pro_sheets_shape[_0x5b2a19(0x20a)]),_defineProperty(this,_0x5b2a19(0x1ec),void 0x0),_defineProperty(this,_0x5b2a19(0x272),{}),_defineProperty(this,_0x5b2a19(0x254),void 0x0),this['unitId']=_0x41d7fc,this['subUnitId']=_0x336bdb,this[_0x5b2a19(0x258)]=_0x3ecab0||(0x0,_univerjs_core['generateRandomId'])(),this[_0x5b2a19(0x254)]=_0x40117e;}[_0x4a2ac5(0x235)](_0x303179,_0xfc07a6,_0x32c9fa,_0x2e1419){const _0x252b9a=_0x4a2ac5,_0x2269a1=this['_injector'][_0x252b9a(0x27f)](_univerjs_sheets[_0x252b9a(0x1e8)])[_0x252b9a(0x27c)](this['unitId'],this[_0x252b9a(0x231)]);if(!_0x2269a1)throw new Error(_0x252b9a(0x1f9)+this[_0x252b9a(0x24c)]+_0x252b9a(0x24b)+this[_0x252b9a(0x231)]+_0x252b9a(0x245));const {transform:_0x22f423}=(0x0,_univerjs_sheets[_0x252b9a(0x22e)])(this[_0x252b9a(0x24c)],this['subUnitId'],{'row':_0x303179,'column':_0xfc07a6,'rowOffset':_0x32c9fa,'columnOffset':_0x2e1419},0x1,0x1,_0x2269a1);return this['x']=_0x22f423['left'],this['y']=_0x22f423[_0x252b9a(0x1f7)],this;}[_0x4a2ac5(0x279)](_0x4e75cc,_0x2b8054){return this['x']=_0x4e75cc,this['y']=_0x2b8054,this;}[_0x4a2ac5(0x23b)](_0x4b5e00){const _0x510c60=_0x4a2ac5;return this[_0x510c60(0x1ec)]=_0x4b5e00,this;}[_0x4a2ac5(0x257)](_0x572f2d,_0x5cb0cf){const _0x9a10ff=_0x4a2ac5;if(!this['shapeData'][_0x9a10ff(0x283)])this[_0x9a10ff(0x272)][_0x9a10ff(0x283)]={};this['shapeData'][_0x9a10ff(0x283)]['fillType']=_univerjs_pro_engine_shape['ShapeFillEnum'][_0x9a10ff(0x243)];if(_0x572f2d!==void 0x0)this[_0x9a10ff(0x272)][_0x9a10ff(0x283)][_0x9a10ff(0x21b)]=_0x572f2d;if(_0x5cb0cf!==void 0x0)this[_0x9a10ff(0x272)][_0x9a10ff(0x283)][_0x9a10ff(0x25d)]=_0x5cb0cf;return this;}['setShapeGradientFill'](_0x4cd5ef,_0x21b3be,_0x1a3247){const _0x3437bc=_0x4a2ac5;if(_0x21b3be===void 0x0||_0x21b3be[_0x3437bc(0x1e6)]===0x0)throw new Error(_0x3437bc(0x277));if(!this['shapeData'][_0x3437bc(0x283)])this[_0x3437bc(0x272)][_0x3437bc(0x283)]={};this[_0x3437bc(0x272)][_0x3437bc(0x283)]['gradientStops']=_0x21b3be,this[_0x3437bc(0x272)][_0x3437bc(0x283)]['fillType']=_univerjs_pro_engine_shape[_0x3437bc(0x25e)]['GradientFill'],this[_0x3437bc(0x272)][_0x3437bc(0x283)][_0x3437bc(0x238)]=_0x4cd5ef;if(_0x1a3247!==void 0x0)this['shapeData'][_0x3437bc(0x283)][_0x3437bc(0x1ea)]=_0x1a3247;return this;}[_0x4a2ac5(0x24d)](){const _0x19df90=_0x4a2ac5;return this[_0x19df90(0x272)]['fill']={'fillType':_univerjs_pro_engine_shape['ShapeFillEnum'][_0x19df90(0x25a)]},this;}[_0x4a2ac5(0x201)](_0x1457e4){const _0x585fde=_0x4a2ac5;if(!this[_0x585fde(0x272)][_0x585fde(0x244)])this[_0x585fde(0x272)][_0x585fde(0x244)]={};return this[_0x585fde(0x272)][_0x585fde(0x244)]['color']=_0x1457e4,this;}[_0x4a2ac5(0x22f)](_0x5ab0e8){const _0x25756c=_0x4a2ac5;if(!this[_0x25756c(0x272)][_0x25756c(0x244)])this[_0x25756c(0x272)][_0x25756c(0x244)]={};return this['shapeData'][_0x25756c(0x244)][_0x25756c(0x22a)]=_0x5ab0e8,this;}[_0x4a2ac5(0x242)](_0x5d85d5){const _0x5a444d=_0x4a2ac5;if(!this[_0x5a444d(0x272)][_0x5a444d(0x244)])this[_0x5a444d(0x272)]['stroke']={};return this[_0x5a444d(0x272)][_0x5a444d(0x244)][_0x5a444d(0x26f)]=_0x5d85d5,this;}['setStrokeLineJoinType'](_0x31f9bd){const _0x491037=_0x4a2ac5;if(!this['shapeData'][_0x491037(0x244)])this[_0x491037(0x272)]['stroke']={};return this[_0x491037(0x272)]['stroke'][_0x491037(0x278)]=_0x31f9bd,this;}[_0x4a2ac5(0x204)](_0x15e9a7){const _0x544225=_0x4a2ac5;if(!this[_0x544225(0x272)][_0x544225(0x244)])this['shapeData']['stroke']={};return this['shapeData'][_0x544225(0x244)][_0x544225(0x22c)]=_0x15e9a7,this;}[_0x4a2ac5(0x260)](_0x44df32){const _0x4468ff=_0x4a2ac5;if(!this['shapeData']['stroke'])this['shapeData'][_0x4468ff(0x244)]={};return this[_0x4468ff(0x272)][_0x4468ff(0x244)][_0x4468ff(0x25d)]=_0x44df32,this;}[_0x4a2ac5(0x264)](_0x49fef8){const _0x16d73c=_0x4a2ac5;if(!this[_0x16d73c(0x272)][_0x16d73c(0x244)])this[_0x16d73c(0x272)][_0x16d73c(0x244)]={};return this[_0x16d73c(0x272)][_0x16d73c(0x244)][_0x16d73c(0x281)]=_0x49fef8,this;}['setWidth'](_0x1daa24){const _0x2535cb=_0x4a2ac5;return this[_0x2535cb(0x22a)]=_0x1daa24,this;}['setHeight'](_0x595e57){const _0x308306=_0x4a2ac5;return this[_0x308306(0x266)]=_0x595e57,this;}[_0x4a2ac5(0x22d)](){const _0x36d292=_0x4a2ac5,_0x206c45=this['_injector']['get'](_univerjs_pro_sheets_shape['SheetsShapeService'])[_0x36d292(0x247)](this['unitId'],this[_0x36d292(0x231)],this[_0x36d292(0x258)]);if(_0x206c45)return(0x0,_univerjs_pro_engine_shape[_0x36d292(0x263)])(_0x206c45['getShapeType']());if(this[_0x36d292(0x1ec)])return(0x0,_univerjs_pro_engine_shape['isConnectorShape'])(this['shapeType']);return![];}[_0x4a2ac5(0x24e)](){const _0x440222=_0x4a2ac5,_0x3f36b7=this[_0x440222(0x254)][_0x440222(0x27f)](_univerjs_pro_sheets_shape[_0x440222(0x251)])[_0x440222(0x247)](this['unitId'],this[_0x440222(0x231)],this[_0x440222(0x258)]);if(!_0x3f36b7)return[];const _0x55a202=this[_0x440222(0x254)][_0x440222(0x27f)](_univerjs_drawing[_0x440222(0x213)])[_0x440222(0x21c)]({'unitId':this[_0x440222(0x24c)],'subUnitId':this[_0x440222(0x231)],'drawingId':this[_0x440222(0x258)]});if(!(_0x55a202===null||_0x55a202===void 0x0?void 0x0:_0x55a202[_0x440222(0x1e9)]))return[];const {width:width=0x0,height:height=0x0}=_0x55a202[_0x440222(0x1e9)];return _0x3f36b7[_0x440222(0x223)]({'width':width,'height':height}),_0x3f36b7[_0x440222(0x227)]();}[_0x4a2ac5(0x207)](){const _0x32201c=_0x4a2ac5,_0xb31fd5=this['_injector'][_0x32201c(0x27f)](_univerjs_pro_sheets_shape[_0x32201c(0x251)])['getShapeModel'](this['unitId'],this[_0x32201c(0x231)],this[_0x32201c(0x258)]);if(!_0xb31fd5)return[];const _0x4818c5=this[_0x32201c(0x254)][_0x32201c(0x27f)](_univerjs_drawing[_0x32201c(0x213)])[_0x32201c(0x21c)]({'unitId':this['unitId'],'subUnitId':this['subUnitId'],'drawingId':this[_0x32201c(0x258)]});if(!(_0x4818c5===null||_0x4818c5===void 0x0?void 0x0:_0x4818c5[_0x32201c(0x1e9)]))return[];const {width:width=0x0,height:height=0x0}=_0x4818c5[_0x32201c(0x1e9)];return _0xb31fd5[_0x32201c(0x223)]({'width':width,'height':height}),_0xb31fd5[_0x32201c(0x214)]();}[_0x4a2ac5(0x1f2)](){const _0x3d9e9f=_0x4a2ac5,_0x4128c8=this[_0x3d9e9f(0x254)][_0x3d9e9f(0x27f)](_univerjs_pro_sheets_shape[_0x3d9e9f(0x251)])['getShapeModel'](this[_0x3d9e9f(0x24c)],this[_0x3d9e9f(0x231)],this['drawId']);if(!_0x4128c8)return[];if(!(0x0,_univerjs_pro_engine_shape[_0x3d9e9f(0x263)])(_0x4128c8[_0x3d9e9f(0x205)]()))return[];const _0x3190f8=this[_0x3d9e9f(0x254)][_0x3d9e9f(0x27f)](_univerjs_drawing[_0x3d9e9f(0x213)])[_0x3d9e9f(0x21c)]({'unitId':this[_0x3d9e9f(0x24c)],'subUnitId':this[_0x3d9e9f(0x231)],'drawingId':this[_0x3d9e9f(0x258)]});if(!(_0x3190f8===null||_0x3190f8===void 0x0?void 0x0:_0x3190f8[_0x3d9e9f(0x1e9)]))return[];const {width:width=0x0,height:height=0x0}=_0x3190f8[_0x3d9e9f(0x1e9)];return _0x4128c8[_0x3d9e9f(0x223)]({'width':width,'height':height}),_0x4128c8[_0x3d9e9f(0x1f2)]();}[_0x4a2ac5(0x23a)](){const _0x538424=_0x4a2ac5;var _0x446fa3;const _0x82458c=this[_0x538424(0x254)][_0x538424(0x27f)](_univerjs_pro_sheets_shape[_0x538424(0x251)])['getShapeModel'](this[_0x538424(0x24c)],this['subUnitId'],this[_0x538424(0x258)]);if(!_0x82458c)return null;return(_0x446fa3=_0x82458c[_0x538424(0x23a)]())!==null&&_0x446fa3!==void 0x0?_0x446fa3:null;}[_0x4a2ac5(0x202)](){const _0x2cd000=_0x4a2ac5;var _0x4e68b6;const _0x2b094a=this[_0x2cd000(0x254)]['get'](_univerjs_pro_sheets_shape['SheetsShapeService'])[_0x2cd000(0x247)](this['unitId'],this['subUnitId'],this[_0x2cd000(0x258)]);if(!_0x2b094a)return null;return(_0x4e68b6=_0x2b094a[_0x2cd000(0x202)]())!==null&&_0x4e68b6!==void 0x0?_0x4e68b6:null;}[_0x4a2ac5(0x1ed)](){const _0x29bb01=_0x4a2ac5;var _0x50fe86,_0x2fdc65;if(!this['shapeType'])throw new Error(_0x29bb01(0x20c));if(this['x']===0x0||this['y']===0x0){const _0x40e33e=this[_0x29bb01(0x254)]['get'](_univerjs_sheets[_0x29bb01(0x1e8)])['ensureSkeleton'](this[_0x29bb01(0x24c)],this['subUnitId']);if(!_0x40e33e)throw new Error(_0x29bb01(0x1f9)+this[_0x29bb01(0x24c)]+_0x29bb01(0x24b)+this[_0x29bb01(0x231)]+'\x20not\x20found');const {transform:_0x1666ec}=(0x0,_univerjs_sheets[_0x29bb01(0x22e)])(this[_0x29bb01(0x24c)],this[_0x29bb01(0x231)],{'row':0x1,'column':0x1,'rowOffset':0x0,'columnOffset':0x0},0x1,0x1,_0x40e33e);this['x']=this['x']>0x0?this['x']:_0x1666ec['left'],this['y']=this['y']>0x0?this['y']:_0x1666ec[_0x29bb01(0x1f7)];}return this[_0x29bb01(0x22a)]=(_0x50fe86=this[_0x29bb01(0x22a)])!==null&&_0x50fe86!==void 0x0?_0x50fe86:_univerjs_pro_sheets_shape[_0x29bb01(0x206)],this[_0x29bb01(0x266)]=(_0x2fdc65=this[_0x29bb01(0x266)])!==null&&_0x2fdc65!==void 0x0?_0x2fdc65:_univerjs_pro_sheets_shape[_0x29bb01(0x20a)],{'unitId':this[_0x29bb01(0x24c)],'subUnitId':this[_0x29bb01(0x231)],'shapeId':this['drawId'],'shapeType':this[_0x29bb01(0x1ec)],'shapeData':Object[_0x29bb01(0x23e)](this[_0x29bb01(0x272)])[_0x29bb01(0x1e6)]>0x0?this[_0x29bb01(0x272)]:void 0x0,'x':this['x'],'y':this['y'],'width':this[_0x29bb01(0x22a)],'height':this[_0x29bb01(0x266)]};}[_0x4a2ac5(0x230)](){const _0x22ec1a=_0x4a2ac5;return this[_0x22ec1a(0x258)];}[_0x4a2ac5(0x205)](){const _0xd17e1b=_0x4a2ac5;return this[_0xd17e1b(0x1ec)];}[_0x4a2ac5(0x253)](){const _0xc8c9fc=_0x4a2ac5;return this[_0xc8c9fc(0x272)];}[_0x4a2ac5(0x1f0)](){return{'x':this['x'],'y':this['y']};}[_0x4a2ac5(0x232)](){const _0x5ec312=_0x4a2ac5;return{'width':this[_0x5ec312(0x22a)],'height':this[_0x5ec312(0x266)]};}},FConnectorShape=class extends FShape{constructor(_0x487f32,_0x21badb,_0x303b3a,_0xaa0633){const _0x469893=_0x4a2ac5;super(_0x487f32,_0x21badb,_0x303b3a,_0xaa0633),_defineProperty(this,_0x469893(0x272),{});}[_0x4a2ac5(0x23b)](_0x4cb3ad){const _0x2466ae=_0x4a2ac5;if(!(0x0,_univerjs_pro_engine_shape['isConnectorShape'])(_0x4cb3ad))throw new Error(_0x2466ae(0x23f)+_0x4cb3ad+_0x2466ae(0x20d));return super[_0x2466ae(0x23b)](_0x4cb3ad),this;}['setStartArrowType'](_0x3762d5){const _0x38bda3=_0x4a2ac5;var _0x1d1b92,_0x5c80d1;if(!((_0x1d1b92=this[_0x38bda3(0x272)])===null||_0x1d1b92===void 0x0?void 0x0:_0x1d1b92['ln']))this[_0x38bda3(0x272)]['ln']={};if(!((_0x5c80d1=this[_0x38bda3(0x272)])===null||_0x5c80d1===void 0x0||(_0x5c80d1=_0x5c80d1['ln'])===null||_0x5c80d1===void 0x0?void 0x0:_0x5c80d1[_0x38bda3(0x222)]))this[_0x38bda3(0x272)]['ln'][_0x38bda3(0x222)]={};return this[_0x38bda3(0x272)]['ln'][_0x38bda3(0x222)][_0x38bda3(0x203)]=_0x3762d5,this;}[_0x4a2ac5(0x219)](_0x1aea65){const _0x4bbf24=_0x4a2ac5;var _0x76867a,_0xfb3251;if(!((_0x76867a=this[_0x4bbf24(0x272)])===null||_0x76867a===void 0x0?void 0x0:_0x76867a['ln']))this[_0x4bbf24(0x272)]['ln']={};if(!((_0xfb3251=this[_0x4bbf24(0x272)])===null||_0xfb3251===void 0x0||(_0xfb3251=_0xfb3251['ln'])===null||_0xfb3251===void 0x0?void 0x0:_0xfb3251[_0x4bbf24(0x262)]))this[_0x4bbf24(0x272)]['ln']['endArrow']={};return this[_0x4bbf24(0x272)]['ln'][_0x4bbf24(0x262)][_0x4bbf24(0x203)]=_0x1aea65,this;}['setStartArrowSize'](_0x26ee71){const _0x56db73=_0x4a2ac5;var _0x2f4c00,_0x2844ba;if(!((_0x2f4c00=this['shapeData'])===null||_0x2f4c00===void 0x0?void 0x0:_0x2f4c00['ln']))this[_0x56db73(0x272)]['ln']={};if(!((_0x2844ba=this['shapeData'])===null||_0x2844ba===void 0x0||(_0x2844ba=_0x2844ba['ln'])===null||_0x2844ba===void 0x0?void 0x0:_0x2844ba[_0x56db73(0x222)]))this[_0x56db73(0x272)]['ln'][_0x56db73(0x222)]={};return this[_0x56db73(0x272)]['ln']['startArrow'][_0x56db73(0x20e)]=_0x26ee71,this;}[_0x4a2ac5(0x1f5)](_0xaa581){const _0x4799b9=_0x4a2ac5;var _0x3619b1,_0x2a35ce;if(!((_0x3619b1=this['shapeData'])===null||_0x3619b1===void 0x0?void 0x0:_0x3619b1['ln']))this[_0x4799b9(0x272)]['ln']={};if(!((_0x2a35ce=this[_0x4799b9(0x272)])===null||_0x2a35ce===void 0x0||(_0x2a35ce=_0x2a35ce['ln'])===null||_0x2a35ce===void 0x0?void 0x0:_0x2a35ce[_0x4799b9(0x262)]))this['shapeData']['ln'][_0x4799b9(0x262)]={};return this[_0x4799b9(0x272)]['ln'][_0x4799b9(0x262)][_0x4799b9(0x20e)]=_0xaa581,this;}[_0x4a2ac5(0x1ed)](){const _0x32c1fe=_0x4a2ac5;return super[_0x32c1fe(0x1ed)]();}[_0x4a2ac5(0x202)](){const _0x1e621a=_0x4a2ac5;var _0x415525;return((_0x415525=this[_0x1e621a(0x272)])===null||_0x415525===void 0x0||(_0x415525=_0x415525[_0x1e621a(0x209)])===null||_0x415525===void 0x0?void 0x0:_0x415525['to'])||null;}[_0x4a2ac5(0x23a)](){const _0x46bd2f=_0x4a2ac5;var _0x93c41;return((_0x93c41=this[_0x46bd2f(0x272)])===null||_0x93c41===void 0x0||(_0x93c41=_0x93c41[_0x46bd2f(0x209)])===null||_0x93c41===void 0x0?void 0x0:_0x93c41[_0x46bd2f(0x26e)])||null;}};function _0x9e0d(_0x28a709,_0x881b60){_0x28a709=_0x28a709-0x1e6;const _0x56e376=_0x56e3();let _0x9e0d04=_0x56e376[_0x28a709];return _0x9e0d04;}function computeConnectionPointInfo(_0x5ed9d8,_0x3472b7,_0x56aae4,_0xc0519e,_0x4ad144,_0x3cc094){const _0x3a1267=_0x4a2ac5,_0x2f46ca=_0x4ad144[_0x3a1267(0x247)](_0x5ed9d8,_0x3472b7,_0x56aae4);if(!_0x2f46ca)return null;const _0x4efa00=_0x3cc094[_0x3a1267(0x21c)]({'unitId':_0x5ed9d8,'subUnitId':_0x3472b7,'drawingId':_0x56aae4});if(!(_0x4efa00===null||_0x4efa00===void 0x0?void 0x0:_0x4efa00['transform']))return null;const {left:left=0x0,top:top=0x0,width:width=0x0,height:height=0x0,flipX:flipX=![],flipY:flipY=![],angle:_0x54089}=_0x4efa00[_0x3a1267(0x1e9)];_0x2f46ca[_0x3a1267(0x223)]({'width':width,'height':height});const _0x92a562=_0x2f46ca['getConnectionSiteList']()[_0x3a1267(0x256)](_0x475bb4=>_0x475bb4[_0x3a1267(0x225)]===_0xc0519e);if(!_0x92a562)return null;let _0x2bd920=flipX?width-_0x92a562['x']:_0x92a562['x'],_0x1f438a=flipY?height-_0x92a562['y']:_0x92a562['y'];if(_0x54089&&_0x54089!==0x0){const _0x137e56=_0x54089*Math['PI']/0xb4,_0x257ca6=Math[_0x3a1267(0x1eb)](_0x137e56),_0x164d18=Math[_0x3a1267(0x1f1)](_0x137e56),_0x584b77=width/0x2,_0x7d0bd3=height/0x2,_0x44d90a=_0x2bd920-_0x584b77,_0x4a2423=_0x1f438a-_0x7d0bd3;_0x2bd920=_0x584b77+_0x44d90a*_0x257ca6-_0x4a2423*_0x164d18,_0x1f438a=_0x7d0bd3+_0x44d90a*_0x164d18+_0x4a2423*_0x257ca6;}_0x2bd920+=left,_0x1f438a+=top;let _0x194aef=_0x92a562[_0x3a1267(0x1ee)]/0xea60;if(flipX)_0x194aef=0xb4-_0x194aef;if(flipY)_0x194aef=-_0x194aef;_0x194aef+=_0x54089||0x0,_0x194aef=(_0x194aef%0x168+0x168)%0x168;const _0x403b7d=(0x0,_univerjs_pro_engine_shape[_0x3a1267(0x229)])({'left':left,'top':top,'width':width,'height':height},_0x54089||0x0);return{'point':{'x':_0x2bd920,'y':_0x1f438a},'angle':_0x194aef,'bounds':_0x403b7d};}function calculateFreeEndpointAngle(_0x219ddf,_0x476118){const _0x57bde1=_0x4a2ac5,_0x46c04a=_0x476118['x']-_0x219ddf['x'],_0x1f55a8=_0x476118['y']-_0x219ddf['y'];if(Math[_0x57bde1(0x210)](_0x46c04a)>=Math[_0x57bde1(0x210)](_0x1f55a8))return _0x46c04a>=0x0?0xb4:0x0;return _0x1f55a8>=0x0?0x10e:0x5a;}function computeFreeEndpointInfo(_0x444976,_0x373830,_0xd101f4,_0x227fb3,_0x29cb73,_0x23cdc9,_0x1d7384){const _0x1c79c2=_0x4a2ac5,_0x2c105b=_0x23cdc9[_0x1c79c2(0x247)](_0x444976,_0x373830,_0xd101f4);if(!_0x2c105b)return null;const _0x41541c=_0x1d7384[_0x1c79c2(0x21c)]({'unitId':_0x444976,'subUnitId':_0x373830,'drawingId':_0xd101f4});if(!(_0x41541c===null||_0x41541c===void 0x0?void 0x0:_0x41541c[_0x1c79c2(0x1e9)]))return null;const {left:left=0x0,top:top=0x0,width:width=0x0,height:height=0x0,flipX:flipX=![],flipY:flipY=![]}=_0x41541c[_0x1c79c2(0x1e9)];_0x2c105b[_0x1c79c2(0x223)]({'width':width,'height':height});const _0x5e4cc0=_0x2c105b['getConnectorLinePoints']();if(_0x5e4cc0[_0x1c79c2(0x1e6)]<0x2)return null;const _0x39e18c=_0x227fb3?_0x5e4cc0[0x0]:_0x5e4cc0[_0x5e4cc0[_0x1c79c2(0x1e6)]-0x1],_0x4609f2=new _univerjs_pro_engine_shape['ConnectorCoordinateTransform']({'left':left,'top':top,'width':width,'height':height,'flipX':flipX,'flipY':flipY})['localToWorld'](_0x39e18c);return{'point':_0x4609f2,'angle':calculateFreeEndpointAngle(_0x29cb73[_0x1c79c2(0x270)],_0x4609f2),'bounds':{'left':_0x4609f2['x'],'top':_0x4609f2['y'],'width':0x0,'height':0x0}};}var FWorksheetShapeMixin=class extends _univerjs_sheets_facade['FWorksheet']{async[_0x4a2ac5(0x273)](_0x1718e1){const _0x45c77c=_0x4a2ac5,{unitId:_0x1cf9e6,subUnitId:_0x5b8c59,shapeId:_0x1ef362,shapeType:_0x517ad1,shapeData:_0x37bfd9,x:_0x415e78,y:_0x4566fd,width:_0x182024,height:_0xb20d29}=_0x1718e1;return this[_0x45c77c(0x27e)]['executeCommand'](_univerjs_pro_sheets_shape[_0x45c77c(0x259)]['id'],{'unitId':_0x1cf9e6,'subUnitId':_0x5b8c59,'shapeId':_0x1ef362,'shapeType':_0x517ad1,'shapeData':_0x37bfd9,'position':{'x':_0x415e78,'y':_0x4566fd},'width':_0x182024,'height':_0xb20d29});}async[_0x4a2ac5(0x255)](_0x55d624){const _0xf77a00=_0x4a2ac5,{unitId:_0x3bb908,subUnitId:_0x475964,shapeId:_0x4534ed,shapeType:_0x60dcfe,shapeData:_0x48fffe,x:_0x158a9f,y:_0x1337b5,width:_0x569d9b,height:_0x37780e}=_0x55d624;return this['_commandService'][_0xf77a00(0x27a)](_univerjs_pro_sheets_shape['SetShapeDrawingDataCommand']['id'],{'unitId':_0x3bb908,'subUnitId':_0x475964,'shapeId':_0x4534ed,'shapeType':_0x60dcfe,'shapeData':_0x48fffe,'position':{'x':_0x158a9f,'y':_0x1337b5},'width':_0x569d9b,'height':_0x37780e});}['newShape'](_0x37600f){const _0x2b5744=_0x4a2ac5,_0x26323e=this[_0x2b5744(0x233)]()[_0x2b5744(0x237)](),_0x4dbbca=this[_0x2b5744(0x20f)]();if(_0x37600f){const _0x38fc22=new FShape(_0x26323e,_0x4dbbca,_0x37600f[_0x2b5744(0x258)],this[_0x2b5744(0x254)]);return this[_0x2b5744(0x212)](_0x38fc22,_0x26323e,_0x4dbbca,_0x37600f[_0x2b5744(0x258)]),_0x38fc22;}return new FShape(_0x26323e,_0x4dbbca,(0x0,_univerjs_core[_0x2b5744(0x220)])(),this[_0x2b5744(0x254)]);}['newConnector'](_0x1bb0cf){const _0x1c285e=_0x4a2ac5,_0x10d173=this[_0x1c285e(0x233)]()[_0x1c285e(0x237)](),_0x37bf4b=this[_0x1c285e(0x20f)]();if(_0x1bb0cf){const _0x50f16f=new FConnectorShape(_0x10d173,_0x37bf4b,_0x1bb0cf[_0x1c285e(0x258)],this[_0x1c285e(0x254)]);return this['_preloadShapeProperties'](_0x50f16f,_0x10d173,_0x37bf4b,_0x1bb0cf['drawId']),_0x50f16f;}return new FConnectorShape(_0x10d173,_0x37bf4b,(0x0,_univerjs_core[_0x1c285e(0x220)])(),this['_injector']);}[_0x4a2ac5(0x1f8)](){const _0x31c0e7=_0x4a2ac5,_0x59a003=this[_0x31c0e7(0x254)][_0x31c0e7(0x27f)](_univerjs_sheets_drawing[_0x31c0e7(0x250)]),_0x402ebc=this[_0x31c0e7(0x233)]()[_0x31c0e7(0x237)](),_0x5979d2=this[_0x31c0e7(0x20f)](),_0x44b5f5=_0x59a003[_0x31c0e7(0x27b)](_0x402ebc,_0x5979d2);if(!_0x44b5f5)return[];const _0x3d46e2=[];for(const [_0x59f758,_0x3810fa]of Object[_0x31c0e7(0x1fb)](_0x44b5f5))if(_0x3810fa&&_0x3810fa[_0x31c0e7(0x252)]===_univerjs_core['DrawingTypeEnum']['DRAWING_SHAPE']){const _0x4c6fcc=new FShape(_0x402ebc,_0x5979d2,_0x59f758,this[_0x31c0e7(0x254)]);this['_preloadShapeProperties'](_0x4c6fcc,_0x402ebc,_0x5979d2,_0x59f758),_0x3d46e2['push'](_0x4c6fcc);}return _0x3d46e2;}[_0x4a2ac5(0x280)](_0x5307f6){const _0x21b6fc=_0x4a2ac5,{unitId:_0xb698ac,subUnitId:_0x3b4154,drawId:_0x1e0a2a}=_0x5307f6;return this[_0x21b6fc(0x27e)]['executeCommand'](_univerjs_sheets_drawing[_0x21b6fc(0x200)]['id'],{'unitId':_0xb698ac,'drawings':[{'unitId':_0xb698ac,'subUnitId':_0x3b4154,'drawingId':_0x1e0a2a,'drawingType':_univerjs_core[_0x21b6fc(0x211)][_0x21b6fc(0x1fa)]}]});}async['connectShapes'](_0xddd5d5){const _0x40e77a=_0x4a2ac5,{connector:_0x255133,startTarget:_0x2bec8d,endTarget:_0x40c0ca}=_0xddd5d5;if(!_0x2bec8d&&!_0x40c0ca)return![];const _0x4d6c2a=this[_0x40e77a(0x233)]()[_0x40e77a(0x237)](),_0x30b800=this['getSheetId'](),_0x4f3e27=this['_injector'][_0x40e77a(0x27f)](_univerjs_pro_sheets_shape['SheetsShapeService']),_0x47fea1=this[_0x40e77a(0x254)][_0x40e77a(0x27f)](_univerjs_drawing[_0x40e77a(0x213)]),_0x2b27b2=_0x4f3e27['getShapeModel'](_0x4d6c2a,_0x30b800,_0x255133[_0x40e77a(0x258)]);if(!_0x2b27b2)return![];const _0x243564=_0x2b27b2[_0x40e77a(0x205)](),_0x4be738=_0x2b27b2[_0x40e77a(0x226)](),_0x588cad={};for(const _0x130f1b of _0x2b27b2[_0x40e77a(0x218)]()){const _0x4b197b=_0x2b27b2[_0x40e77a(0x246)](_0x130f1b);if(_0x4b197b!==void 0x0)_0x588cad[_0x130f1b]=_0x4b197b;}const {startInfo:_0x4f1ddc,endInfo:_0x114d9d}=this[_0x40e77a(0x26d)](_0x4d6c2a,_0x30b800,_0x255133,_0x2b27b2,_0x2bec8d,_0x40c0ca,_0x4f3e27,_0x47fea1,_0x4be738);if(!_0x4f1ddc||!_0x114d9d)return![];const _0x43b47a=(0x0,_univerjs_pro_engine_shape[_0x40e77a(0x249)])((0x0,_univerjs_pro_engine_shape[_0x40e77a(0x22b)])(_0x4f1ddc,_0x114d9d,_0x243564),_0x243564),_0x1c62d2={};if(_0x2bec8d)_0x1c62d2[_0x40e77a(0x26e)]={'shapeId':_0x2bec8d[_0x40e77a(0x27d)][_0x40e77a(0x258)],'cxnIndex':_0x2bec8d[_0x40e77a(0x234)]};else{if(_0x4be738===null||_0x4be738===void 0x0?void 0x0:_0x4be738['from'])_0x1c62d2['from']=_0x4be738['from'];}if(_0x40c0ca)_0x1c62d2['to']={'shapeId':_0x40c0ca[_0x40e77a(0x27d)]['drawId'],'cxnIndex':_0x40c0ca['connectionSiteIndex']};else{if(_0x4be738===null||_0x4be738===void 0x0?void 0x0:_0x4be738['to'])_0x1c62d2['to']=_0x4be738['to'];}return this[_0x40e77a(0x27e)][_0x40e77a(0x27a)](_univerjs_pro_sheets_shape[_0x40e77a(0x282)]['id'],{'unitId':_0x4d6c2a,'subUnitId':_0x30b800,'connectorShapeId':_0x255133[_0x40e77a(0x258)],'width':_0x43b47a[_0x40e77a(0x1f3)][_0x40e77a(0x22a)],'height':_0x43b47a['worldRect'][_0x40e77a(0x266)],'left':_0x43b47a[_0x40e77a(0x1f3)][_0x40e77a(0x26c)],'top':_0x43b47a['worldRect'][_0x40e77a(0x1f7)],'flipX':_0x43b47a[_0x40e77a(0x1f3)][_0x40e77a(0x25b)]||![],'flipY':_0x43b47a[_0x40e77a(0x1f3)][_0x40e77a(0x271)]||![],'oldAdjustValues':_0x588cad,'newAdjustValues':_0x43b47a[_0x40e77a(0x23d)],'newLineType':_0x43b47a['lineType'],'oldLineType':_0x243564,'rotation':_0x43b47a[_0x40e77a(0x24a)],'oldRelation':_0x4be738,'newRelation':_0x1c62d2});}[_0x4a2ac5(0x212)](_0x48e634,_0x19fe70,_0x421ba0,_0x2a9ad7){const _0x4ee572=_0x4a2ac5,_0x58fd7c=this[_0x4ee572(0x254)][_0x4ee572(0x27f)](_univerjs_drawing[_0x4ee572(0x213)])[_0x4ee572(0x21c)]({'unitId':_0x19fe70,'subUnitId':_0x421ba0,'drawingId':_0x2a9ad7});if(_0x58fd7c===null||_0x58fd7c===void 0x0?void 0x0:_0x58fd7c[_0x4ee572(0x1e9)]){var _0x4697dc,_0x5e56a3,_0x6a0fb4,_0x3c8e74;_0x48e634['x']=(_0x4697dc=_0x58fd7c[_0x4ee572(0x1e9)][_0x4ee572(0x26c)])!==null&&_0x4697dc!==void 0x0?_0x4697dc:0x0,_0x48e634['y']=(_0x5e56a3=_0x58fd7c['transform'][_0x4ee572(0x1f7)])!==null&&_0x5e56a3!==void 0x0?_0x5e56a3:0x0,_0x48e634[_0x4ee572(0x22a)]=(_0x6a0fb4=_0x58fd7c[_0x4ee572(0x1e9)][_0x4ee572(0x22a)])!==null&&_0x6a0fb4!==void 0x0?_0x6a0fb4:_0x48e634[_0x4ee572(0x22a)],_0x48e634[_0x4ee572(0x266)]=(_0x3c8e74=_0x58fd7c[_0x4ee572(0x1e9)][_0x4ee572(0x266)])!==null&&_0x3c8e74!==void 0x0?_0x3c8e74:_0x48e634['height'];}const _0x2af9ea=this[_0x4ee572(0x254)][_0x4ee572(0x27f)](_univerjs_pro_sheets_shape[_0x4ee572(0x251)])[_0x4ee572(0x247)](_0x19fe70,_0x421ba0,_0x2a9ad7);if(_0x2af9ea){_0x48e634[_0x4ee572(0x1ec)]=_0x2af9ea[_0x4ee572(0x205)]();const _0x1883ed=_0x2af9ea[_0x4ee572(0x253)]();if(_0x1883ed)_0x48e634[_0x4ee572(0x272)]=JSON[_0x4ee572(0x23c)](JSON[_0x4ee572(0x20b)](_0x1883ed));}}[_0x4a2ac5(0x26d)](_0x3055a7,_0x11cf6a,_0x45e756,_0x1cca91,_0x3ea449,_0x1123d0,_0xb6e198,_0x58b095,_0x4cfeea){const _0x276f25=_0x4a2ac5;let _0x28c46b=null,_0x5bd858=null;if(_0x3ea449)_0x28c46b=computeConnectionPointInfo(_0x3055a7,_0x11cf6a,_0x3ea449[_0x276f25(0x27d)][_0x276f25(0x258)],_0x3ea449[_0x276f25(0x234)],_0xb6e198,_0x58b095);if(_0x1123d0)_0x5bd858=computeConnectionPointInfo(_0x3055a7,_0x11cf6a,_0x1123d0[_0x276f25(0x27d)][_0x276f25(0x258)],_0x1123d0[_0x276f25(0x234)],_0xb6e198,_0x58b095);if(!_0x28c46b)_0x28c46b=this[_0x276f25(0x239)](_0x3055a7,_0x11cf6a,_0x45e756[_0x276f25(0x258)],!![],_0x5bd858,_0x4cfeea===null||_0x4cfeea===void 0x0?void 0x0:_0x4cfeea[_0x276f25(0x26e)],_0xb6e198,_0x58b095);if(!_0x5bd858)_0x5bd858=this[_0x276f25(0x239)](_0x3055a7,_0x11cf6a,_0x45e756['drawId'],![],_0x28c46b,_0x4cfeea===null||_0x4cfeea===void 0x0?void 0x0:_0x4cfeea['to'],_0xb6e198,_0x58b095);return{'startInfo':_0x28c46b,'endInfo':_0x5bd858};}[_0x4a2ac5(0x239)](_0x421a7e,_0x49f1b3,_0x4f5768,_0x2afd76,_0x29614a,_0x536ccb,_0x383822,_0x362f40){const _0x5880cf=_0x4a2ac5;if(_0x536ccb){const _0x830a37=computeConnectionPointInfo(_0x421a7e,_0x49f1b3,_0x536ccb[_0x5880cf(0x236)],_0x536ccb['cxnIndex'],_0x383822,_0x362f40);if(_0x830a37)return _0x830a37;}if(!_0x29614a)return null;return computeFreeEndpointInfo(_0x421a7e,_0x49f1b3,_0x4f5768,_0x2afd76,_0x29614a,_0x383822,_0x362f40);}};_univerjs_sheets_facade[_0x4a2ac5(0x240)]['extend'](FWorksheetShapeMixin),exports[_0x4a2ac5(0x25f)]=FConnectorShape,exports[_0x4a2ac5(0x216)]=FShape;
package/lib/cjs/index.js CHANGED
@@ -1 +1 @@
1
- const _0x3add6b=_0x515c;function _0x515c(_0x1783e1,_0x30bb4f){_0x1783e1=_0x1783e1-0x14d;const _0x1fbb04=_0x1fbb();let _0x515c56=_0x1fbb04[_0x1783e1];return _0x515c56;}(function(_0x39d982,_0x10a5b3){const _0x45e1f1=_0x515c,_0x542b86=_0x39d982();while(!![]){try{const _0x441136=-parseInt(_0x45e1f1(0x20c))/0x1*(parseInt(_0x45e1f1(0x21a))/0x2)+parseInt(_0x45e1f1(0x204))/0x3*(parseInt(_0x45e1f1(0x20b))/0x4)+-parseInt(_0x45e1f1(0x210))/0x5+-parseInt(_0x45e1f1(0x17e))/0x6*(-parseInt(_0x45e1f1(0x1fc))/0x7)+-parseInt(_0x45e1f1(0x1ca))/0x8*(-parseInt(_0x45e1f1(0x18a))/0x9)+-parseInt(_0x45e1f1(0x1dd))/0xa+-parseInt(_0x45e1f1(0x216))/0xb*(-parseInt(_0x45e1f1(0x14e))/0xc);if(_0x441136===_0x10a5b3)break;else _0x542b86['push'](_0x542b86['shift']());}catch(_0x115f61){_0x542b86['push'](_0x542b86['shift']());}}}(_0x1fbb,0x41ca5),Object[_0x3add6b(0x206)](exports,Symbol[_0x3add6b(0x211)],{'value':'Module'}));let _univerjs_pro_engine_shape=require('@univerjs-pro/engine-shape'),_univerjs_core=require('@univerjs/core'),_univerjs_sheets=require('@univerjs/sheets'),_univerjs_sheets_drawing=require('@univerjs/sheets-drawing'),_univerjs_pro_license=require('@univerjs-pro/license'),_univerjs_drawing=require('@univerjs/drawing');const DEFAULT_SHAPE_WIDTH=0xc8,DEFAULT_SHAPE_HEIGHT=0xc8;function _typeof(_0x4552a8){'@babel/helpers - typeof';const _0x1bedb8=_0x3add6b;return _typeof='function'==typeof Symbol&&_0x1bedb8(0x15c)==typeof Symbol[_0x1bedb8(0x170)]?function(_0x478f75){return typeof _0x478f75;}:function(_0x3c6d58){const _0x5a2b4a=_0x1bedb8;return _0x3c6d58&&_0x5a2b4a(0x1d9)==typeof Symbol&&_0x3c6d58['constructor']===Symbol&&_0x3c6d58!==Symbol[_0x5a2b4a(0x16f)]?_0x5a2b4a(0x15c):typeof _0x3c6d58;},_typeof(_0x4552a8);}function toPrimitive(_0x524531,_0x391816){const _0x2a6cd1=_0x3add6b;if('object'!=_typeof(_0x524531)||!_0x524531)return _0x524531;var _0x48bede=_0x524531[Symbol[_0x2a6cd1(0x164)]];if(void 0x0!==_0x48bede){var _0x3da6bd=_0x48bede[_0x2a6cd1(0x1bc)](_0x524531,_0x391816||_0x2a6cd1(0x19e));if(_0x2a6cd1(0x1c9)!=_typeof(_0x3da6bd))return _0x3da6bd;throw new TypeError(_0x2a6cd1(0x1d0));}return(_0x2a6cd1(0x1fa)===_0x391816?String:Number)(_0x524531);}function toPropertyKey(_0x72190e){const _0x2e99dd=_0x3add6b;var _0x57dda6=toPrimitive(_0x72190e,_0x2e99dd(0x1fa));return _0x2e99dd(0x15c)==_typeof(_0x57dda6)?_0x57dda6:_0x57dda6+'';}function _defineProperty(_0x29139b,_0x55b84d,_0x42b639){const _0x20c2e1=_0x3add6b;return(_0x55b84d=toPropertyKey(_0x55b84d))in _0x29139b?Object[_0x20c2e1(0x206)](_0x29139b,_0x55b84d,{'value':_0x42b639,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x29139b[_0x55b84d]=_0x42b639,_0x29139b;}var SheetShapeModelManager=class extends _univerjs_core['Disposable']{constructor(){const _0xdfa5ed=_0x3add6b;super(),_defineProperty(this,_0xdfa5ed(0x18f),new Map()),_defineProperty(this,'_linesIds',new Set()),_defineProperty(this,_0xdfa5ed(0x1d4),new Set());}['addShape'](_0x179f34,_0x30c021,_0x1d51b){const _0x405d22=_0x3add6b,_0x57f8f1=new _univerjs_pro_engine_shape[(_0x405d22(0x1e4))](_0x179f34,_0x30c021,_0x1d51b);this['_shapes'][_0x405d22(0x20f)](_0x30c021,_0x57f8f1);if((0x0,_univerjs_pro_engine_shape[_0x405d22(0x1cb)])(_0x179f34))this[_0x405d22(0x158)][_0x405d22(0x1c2)](_0x30c021);return _0x57f8f1;}[_0x3add6b(0x15d)](_0x48b0f3){const _0x35f700=_0x3add6b,_0x1f322d=[];for(const _0x32c3b0 of this['_linesIds']){const _0x5e9ade=this[_0x35f700(0x18f)]['get'](_0x32c3b0);if(_0x5e9ade){const _0x40da0a=_0x5e9ade['getShapeRelation']();if(_0x40da0a){var _0x4fd44a,_0x43745a;if(((_0x4fd44a=_0x40da0a[_0x35f700(0x1ff)])===null||_0x4fd44a===void 0x0?void 0x0:_0x4fd44a[_0x35f700(0x1e7)])===_0x48b0f3)_0x1f322d[_0x35f700(0x182)]({..._0x40da0a['from'],'lineShapeId':_0x32c3b0,'isFrom':!![]});if(((_0x43745a=_0x40da0a['to'])===null||_0x43745a===void 0x0?void 0x0:_0x43745a[_0x35f700(0x1e7)])===_0x48b0f3)_0x1f322d[_0x35f700(0x182)]({..._0x40da0a['to'],'lineShapeId':_0x32c3b0,'isFrom':![]});}}}return _0x1f322d;}[_0x3add6b(0x215)](_0x152108){const _0x1837f7=_0x3add6b,_0x46cf12=this[_0x1837f7(0x18f)][_0x1837f7(0x19c)](_0x152108);if(_0x46cf12)return _0x46cf12[_0x1837f7(0x1b2)]();}['getShapeType'](_0x166c32){const _0x380e9d=_0x3add6b,_0x3c7740=this['_shapes'][_0x380e9d(0x19c)](_0x166c32);if(_0x3c7740)return _0x3c7740[_0x380e9d(0x1a9)]();}['hasShape'](_0x40e4d6){const _0x12497a=_0x3add6b;return this[_0x12497a(0x18f)]['has'](_0x40e4d6);}[_0x3add6b(0x1a6)](_0x44bec0){const _0x1e427b=_0x3add6b,_0xe07692=this['_shapes']['get'](_0x44bec0);if(!_0xe07692)return;if((0x0,_univerjs_pro_engine_shape[_0x1e427b(0x1cb)])(_0xe07692[_0x1e427b(0x1a9)]()))this['_linesIds'][_0x1e427b(0x1e5)](_0x44bec0);this[_0x1e427b(0x18f)][_0x1e427b(0x1e5)](_0x44bec0);}['toJSON'](){const _0x55b425=_0x3add6b,_0x3cc2d5=[];return this[_0x55b425(0x18f)]['forEach'](_0x1576ed=>{const _0x293674=_0x55b425;_0x3cc2d5[_0x293674(0x182)](_0x1576ed[_0x293674(0x213)]());}),_0x3cc2d5;}['fromJSON'](_0x39478c){const _0x36ae6a=_0x3add6b;for(const _0x28619e of _0x39478c){const {id:_0x1b111c,shapeType:_0x4fb1da}=_0x28619e,_0x2bc737=this[_0x36ae6a(0x1c1)](_0x4fb1da,_0x1b111c,_0x28619e['shapeData']);if(_0x2bc737&&_0x2bc737[_0x36ae6a(0x17f)]())this[_0x36ae6a(0x158)][_0x36ae6a(0x1c2)](_0x1b111c);}}['dispose'](){const _0x143911=_0x3add6b;if(this[_0x143911(0x191)])return;this[_0x143911(0x18f)][_0x143911(0x1b3)](_0x1b221c=>{_0x1b221c['dispose']();}),this[_0x143911(0x18f)][_0x143911(0x1eb)](),this[_0x143911(0x158)][_0x143911(0x1eb)](),this[_0x143911(0x1d4)][_0x143911(0x1eb)](),super[_0x143911(0x217)]();}};function __decorateParam(_0x4a7522,_0x447277){return function(_0x5d381a,_0x3267f5){_0x447277(_0x5d381a,_0x3267f5,_0x4a7522);};}function __decorate(_0x42ed50,_0x54322a,_0x4da069,_0x2fd08d){const _0x2c2462=_0x3add6b;var _0x3399a1=arguments[_0x2c2462(0x16b)],_0x22d0d1=_0x3399a1<0x3?_0x54322a:_0x2fd08d===null?_0x2fd08d=Object[_0x2c2462(0x1f9)](_0x54322a,_0x4da069):_0x2fd08d,_0x32a7a0;if(typeof Reflect===_0x2c2462(0x1c9)&&typeof Reflect['decorate']===_0x2c2462(0x1d9))_0x22d0d1=Reflect[_0x2c2462(0x19f)](_0x42ed50,_0x54322a,_0x4da069,_0x2fd08d);else{for(var _0x53364a=_0x42ed50['length']-0x1;_0x53364a>=0x0;_0x53364a--)if(_0x32a7a0=_0x42ed50[_0x53364a])_0x22d0d1=(_0x3399a1<0x3?_0x32a7a0(_0x22d0d1):_0x3399a1>0x3?_0x32a7a0(_0x54322a,_0x4da069,_0x22d0d1):_0x32a7a0(_0x54322a,_0x4da069))||_0x22d0d1;}return _0x3399a1>0x3&&_0x22d0d1&&Object['defineProperty'](_0x54322a,_0x4da069,_0x22d0d1),_0x22d0d1;}const SHEET_SHAPE_PLUGIN=_0x3add6b(0x19b);function _0x1fbb(){const _0x1f5ddd=['SetSheetDrawingCommand','parse','2XjXftc','getEndConnectInfo','12WYYOqo','preRedos','getBasicShapeRotateBound','INSERT','getShapeTextData','left','_drawingManagerService','CommandType','_initCommands','pushUndoRedo','_linesIds','getDrawingByParam','filter','fromJSON','symbol','getBasicShapeRelation','width','sheet.command.insert-shape','_getConnectPointInfo','relation','getSheetCommandTarget','type','toPrimitive','IConfigService','DrawingTypeEnum','preUndos','pluginName','getAdjustValueByName','keys','length','lineShapeId','getStartConnectInfo','IDrawingManagerService','prototype','iterator','SetSheetsShapeTextVerticalToggleCommand','IUndoRedoService','sheet.command.update-connector-relation','DRAWING_SHAPE','onStarting','Inject','ensureSkeleton','packageName','IResourceManagerService','sheet.mutation.insert-shape','_resourcesManagerService','angle','getShapeModel','14754LgSdze','isLineShape','sheet.mutation.update-shape-type','DEFAULT_SHAPE_HEIGHT','push','resizeEnabled','getShapeDataById','hasShape','getShapeData','sin','ISheetDrawingService','sheet.command.set-shape-text-vertical-toggle','9xPBlYH','startX','sheet.command.set-shape-rotate','getDrawingData','borderEnabled','_shapes','InsertShapeCommand','_disposed','ToggleSheetsShapeFlipCommand','_commandService','_sheetsShapeService','assign','worldRect','data','sheets-shape.config','fill','_initSnapshot','SHEET_SHAPE_PLUGIN','get','getBasicShapeType','default','decorate','InsertSheetDrawingCommand','sheet.mutation.update-shape-data','SheetInterceptorService','_deserializeShapeForUnit','_injector','flipX','removeShape','sheet.command.update-shape-type','DEFAULT_SHAPE_WIDTH','getShapeType','height','setShapeData','UpdateSheetsShapeTypeMutation','updateContext','position','getCellIndexAndOffsetByPosition','Injector','getSkeleton','getShapeRelation','forEach','entries','ICommandService','UPDATE','every','UNIVER_SHEET','_sheetSkeletonService','disposeWithMe','onCommandExecute','call','_addLineFollowShapeUpdates','MUTATION','Plugin','generateRandomId','addShape','add','sequenceExecute','ClearSheetDrawingTransformerOperation','registerPluginResource','_addLineRerouteUpdates','UpdateLineShapeResizeCommand','syncExecuteCommand','object','2001176VpPOiA','isConnectorShape','UpdateSheetsShapeTypeCommand','transform','adjustValues','routeConnectorLineShape','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','setConfig','SetDrawingApplyMutation','touchDependencies','_groupIds','interceptCommand','sheet.command.set-shape-drawing-data','SetSheetsShapeRotateCommand','UpdateSheetsShapeDataMutation','function','transformToDrawingPosition','Fail\x20to\x20get\x20shape\x20model,\x20get:\x20','setShapeType','1574580teGlIz','rotateEnabled','UpdateConnectorRelationCommand','SetShapeDrawingDataCommand','version','_shapeModelManagerMap','rotation','ShapeModel','delete','COMMAND','shapeId','@univerjs-pro/sheets-shape','top','insertShape','clear','RemoveSheetsShapeMutation','lineType','IUniverInstanceService','cxnIndex','stringify','cos','flipY','_initCommandInterceptor','removeLinePoints','params','_configService','drawingType','isFrom','getOwnPropertyDescriptor','string','find','861KuBPnD','_sheetInterceptorService','undos','from','getBatchUpdateOp','redos','DrawingApplyType','computeConnectorRouteLayout','246153lNnDDh','transformToAxisAlignPosition','defineProperty','RemoveSheetDrawingCommand','getAdjustNames','_ensureShapeModelManager','index','8AOFLCj','484548JexQoQ','SheetSkeletonService','isHorizontal','set','1491720Elhzah','toStringTag','result','toJSON','InsertSheetsShapeMutation','getLineShapeRelation','5424331aEbFyR','dispose'];_0x1fbb=function(){return _0x1f5ddd;};return _0x1fbb();}let SheetsShapeService=class SheetsShapeService extends _univerjs_core['Disposable']{constructor(_0x10daca){const _0x4dd9b6=_0x3add6b;super(),this[_0x4dd9b6(0x17b)]=_0x10daca,_defineProperty(this,'_shapeModelManagerMap',new Map()),this[_0x4dd9b6(0x19a)]();}[_0x3add6b(0x209)](_0x447d74,_0x16aedb){const _0x560051=_0x3add6b;let _0x42e18f=this[_0x560051(0x1e2)][_0x560051(0x19c)](_0x447d74);!_0x42e18f&&(_0x42e18f=new Map(),this[_0x560051(0x1e2)][_0x560051(0x20f)](_0x447d74,_0x42e18f));let _0x428d4c=_0x42e18f['get'](_0x16aedb);return!_0x428d4c&&(_0x428d4c=new SheetShapeModelManager(),_0x42e18f[_0x560051(0x20f)](_0x16aedb,_0x428d4c)),_0x428d4c;}['insertShape'](_0xb6bc37,_0x4d9b67,_0x49d0cc,_0x33ba1d,_0x35ee98){const _0x2f8945=_0x3add6b;this[_0x2f8945(0x209)](_0xb6bc37,_0x4d9b67)['addShape'](_0x49d0cc,_0x33ba1d,_0x35ee98);}[_0x3add6b(0x1a6)](_0x566f5e,_0x2605df,_0x38e4ab){const _0x52ae82=_0x3add6b;this[_0x52ae82(0x209)](_0x566f5e,_0x2605df)['removeShape'](_0x38e4ab);}[_0x3add6b(0x19d)](_0x2aaab2,_0x2c136b,_0x42d6f4){const _0x19e2c4=_0x3add6b;return this['_ensureShapeModelManager'](_0x2aaab2,_0x2c136b)[_0x19e2c4(0x1a9)](_0x42d6f4);}['getShapeType'](_0xfb7c2d,_0x437087,_0x18d4b3){const _0x2a05be=_0x3add6b;return this[_0x2a05be(0x209)](_0xfb7c2d,_0x437087)['getShapeType'](_0x18d4b3);}[_0x3add6b(0x185)](_0x37cb81,_0x55512d,_0x19e6bd){const _0xa854a2=_0x3add6b;return this[_0xa854a2(0x209)](_0x37cb81,_0x55512d)[_0xa854a2(0x185)](_0x19e6bd);}['getShapeTypeById'](_0x2b69d5,_0x180fb4,_0x17b646){const _0x371a18=_0x3add6b;return this[_0x371a18(0x209)](_0x2b69d5,_0x180fb4)[_0x371a18(0x1a9)](_0x17b646);}[_0x3add6b(0x184)](_0x1077a1,_0x59aea2,_0x1e8177){const _0x23639d=_0x3add6b,_0x53a1e1=this[_0x23639d(0x209)](_0x1077a1,_0x59aea2);if(!_0x53a1e1['getShapeType'](_0x1e8177))return;const _0x236250=_0x53a1e1[_0x23639d(0x18f)][_0x23639d(0x19c)](_0x1e8177);if(!_0x236250)return;return _0x236250[_0x23639d(0x186)]();}[_0x3add6b(0x17d)](_0x40c8f6,_0x58061f,_0x47ad5f){const _0x26fdc2=_0x3add6b;return this[_0x26fdc2(0x209)](_0x40c8f6,_0x58061f)[_0x26fdc2(0x18f)][_0x26fdc2(0x19c)](_0x47ad5f);}[_0x3add6b(0x15d)](_0x54516b,_0x39f55f,_0x265f9b){const _0x4c62c9=_0x3add6b;return this[_0x4c62c9(0x209)](_0x54516b,_0x39f55f)['getBasicShapeRelation'](_0x265f9b);}['getLineShapeRelation'](_0x883bc2,_0x54ae59,_0x1f26a8){const _0x4c20ed=_0x3add6b,_0x90c4d7=this[_0x4c20ed(0x209)](_0x883bc2,_0x54ae59)[_0x4c20ed(0x18f)][_0x4c20ed(0x19c)](_0x1f26a8);if(!_0x90c4d7)return;return _0x90c4d7[_0x4c20ed(0x1b2)]();}[_0x3add6b(0x1dc)](){}['_serializeShapeForUnit'](_0x46df8f){const _0x24cdc3=_0x3add6b,_0x3d279a={},_0x2424b4=this[_0x24cdc3(0x1e2)]['get'](_0x46df8f);if(_0x2424b4)_0x2424b4['forEach']((_0xeaab7e,_0x329272)=>{const _0x5b5c0e=_0x24cdc3,_0x599e80=_0xeaab7e[_0x5b5c0e(0x213)]();if(_0x599e80[_0x5b5c0e(0x16b)]>0x0)_0x3d279a[_0x329272]=_0x599e80;});return JSON[_0x24cdc3(0x1f0)](_0x3d279a);}[_0x3add6b(0x1a3)](_0x261d9c,_0x1fac7b){const _0x1d7732=_0x3add6b;Object['keys'](_0x1fac7b)[_0x1d7732(0x1b3)](_0x32c9f3=>{const _0x3f19e4=_0x1d7732;this[_0x3f19e4(0x209)](_0x261d9c,_0x32c9f3)[_0x3f19e4(0x15b)](_0x1fac7b[_0x32c9f3]);});}[_0x3add6b(0x213)](){const _0x2f93f5=_0x3add6b,_0x4cc517={};return this[_0x2f93f5(0x1e2)][_0x2f93f5(0x1b3)]((_0x37b64f,_0x2b42fa)=>{_0x4cc517[_0x2b42fa]={},_0x37b64f['forEach']((_0x39247c,_0x296822)=>{const _0x1e3920=_0x515c;_0x4cc517[_0x2b42fa][_0x296822]=_0x39247c[_0x1e3920(0x213)]();});}),_0x4cc517;}[_0x3add6b(0x15b)](_0x3629a1){const _0x386335=_0x3add6b;Object[_0x386335(0x16a)](_0x3629a1)[_0x386335(0x1b3)](_0x32312e=>{const _0x37256e=_0x386335,_0x5af6d5=_0x3629a1[_0x32312e];Object['keys'](_0x5af6d5)[_0x37256e(0x1b3)](_0x2f998a=>{const _0x15a79e=_0x37256e;this[_0x15a79e(0x209)](_0x32312e,_0x2f998a)[_0x15a79e(0x15b)](_0x5af6d5[_0x2f998a]);});});}['_initSnapshot'](){const _0x2506a3=_0x3add6b;this[_0x2506a3(0x17b)][_0x2506a3(0x1c5)]({'pluginName':SHEET_SHAPE_PLUGIN,'businesses':[_univerjs_core['UniverInstanceType'][_0x2506a3(0x1b8)]],'toJson':_0x260bda=>this['_serializeShapeForUnit'](_0x260bda),'parseJson':_0x3680d1=>JSON[_0x2506a3(0x219)](_0x3680d1),'onLoad':(_0x47ed93,_0x1d94b0)=>{const _0x2184c1=_0x2506a3;this[_0x2184c1(0x1a3)](_0x47ed93,_0x1d94b0);},'onUnLoad':_0x25f1d0=>{const _0x170795=_0x2506a3,_0x1cb54e=this[_0x170795(0x1e2)]['get'](_0x25f1d0);_0x1cb54e&&(_0x1cb54e[_0x170795(0x1b3)](_0xb7be1a=>{const _0x51150d=_0x170795;_0xb7be1a[_0x51150d(0x217)]();}),this[_0x170795(0x1e2)][_0x170795(0x1e5)](_0x25f1d0));}});}[_0x3add6b(0x217)](){const _0x5d390d=_0x3add6b;this['_shapeModelManagerMap'][_0x5d390d(0x1b3)](_0x43d096=>{const _0xee28d2=_0x5d390d;_0x43d096[_0xee28d2(0x1b3)](_0x143a34=>{const _0x399910=_0xee28d2;_0x143a34[_0x399910(0x217)]();});});}};SheetsShapeService=__decorate([__decorateParam(0x0,_univerjs_core[_0x3add6b(0x179)])],SheetsShapeService);const InsertSheetsShapeMutation={'id':_0x3add6b(0x17a),'type':_univerjs_core['CommandType'][_0x3add6b(0x1be)],'handler':(_0x3dd8d9,_0x137825)=>{const _0x565d15=_0x3add6b,{unitId:_0x2e9763,subUnitId:_0x40cdea,shapeType:_0x1566f8,shapeId:_0x2510d6,shapeData:_0x39b469}=_0x137825;return _0x3dd8d9['get'](SheetsShapeService)[_0x565d15(0x1ea)](_0x2e9763,_0x40cdea,_0x1566f8,_0x2510d6,_0x39b469),!![];}},RemoveSheetsShapeMutation={'id':'sheet.mutation.remove-shape','type':_univerjs_core['CommandType']['MUTATION'],'handler':(_0x4fd5fb,_0x1f3209)=>{const _0x5694ce=_0x3add6b,{unitId:_0x218f93,subUnitId:_0xa3df73,shapeId:_0x1852d3}=_0x1f3209;return _0x4fd5fb['get'](SheetsShapeService)[_0x5694ce(0x1a6)](_0x218f93,_0xa3df73,_0x1852d3),!![];}},InsertShapeCommand={'type':_univerjs_core[_0x3add6b(0x155)][_0x3add6b(0x1e6)],'id':_0x3add6b(0x15f),'handler':(_0x1075ac,_0x4e0199)=>{const _0x25139d=_0x3add6b;var _0x5943e7,_0x5c0d49;const _0xe8b1b1=(0x0,_univerjs_sheets['getSheetCommandTarget'])(_0x1075ac['get'](_univerjs_core[_0x25139d(0x1ee)]),_0x4e0199);if(!_0xe8b1b1)return![];const _0x44c275=_0x1075ac[_0x25139d(0x19c)](_univerjs_sheets[_0x25139d(0x20d)]),{unitId:_0x803189,subUnitId:_0x1638b2}=_0xe8b1b1,_0x3dcf01=_0x44c275['ensureSkeleton'](_0x803189,_0x1638b2);if(!_0x3dcf01)return![];const _0x1e82b4=_0x1075ac['get'](_univerjs_core[_0x25139d(0x1b5)]),_0x2e954b=_0x1075ac[_0x25139d(0x19c)](_univerjs_core[_0x25139d(0x172)]),_0xcad110=_0x1075ac[_0x25139d(0x19c)](_univerjs_sheets[_0x25139d(0x1a2)]),_0x518079=_0x1075ac[_0x25139d(0x19c)](_univerjs_sheets_drawing[_0x25139d(0x188)]),{shapeType:_0x76ad2d,shapeData:_0x57fe84}=_0x4e0199,_0x5d96c7=_0x4e0199[_0x25139d(0x1e7)]||(0x0,_univerjs_core[_0x25139d(0x1c0)])(),_0x45342c={'unitId':_0x803189,'subUnitId':_0x1638b2,'shapeId':_0x5d96c7,'shapeType':_0x76ad2d,'shapeData':_0x57fe84},_0x3f99af=_0x4e0199['width']||0xc8,_0x27d036=_0x4e0199[_0x25139d(0x1aa)]||0xc8;let _0x464559=0x0,_0x11c4a6=0x0,_0x521601={'row':0x0,'rowOffset':0x0,'column':0x0,'columnOffset':0x0},_0x5a9569={'row':0x0,'rowOffset':0x0,'column':0x0,'columnOffset':0x0};if(_0x4e0199[_0x25139d(0x1ae)]){const {x:_0x35d79a,y:_0x13d615}=_0x4e0199[_0x25139d(0x1ae)];_0x464559=_0x35d79a,_0x11c4a6=_0x13d615,_0x521601=_0x3dcf01[_0x25139d(0x1af)](_0x35d79a,_0x13d615),_0x5a9569=_0x3dcf01[_0x25139d(0x1af)](_0x35d79a+_0x3f99af,_0x13d615+_0x27d036);}else{if(_0x4e0199['range']){const {startRow:_0x52aec8,startColumn:_0x449241}=_0x4e0199['range'],_0x254764=0xa,_0x1b465f=0xa;_0x521601={'row':_0x52aec8,'rowOffset':_0x254764,'column':_0x449241,'columnOffset':_0x1b465f};const _0x391c3c=_0x3dcf01['getCellWithCoordByIndex'](_0x52aec8,_0x449241);_0x464559=_0x391c3c[_0x25139d(0x18b)]+_0x1b465f,_0x11c4a6=_0x391c3c['startY']+_0x254764,_0x5a9569=_0x3dcf01[_0x25139d(0x1af)](_0x464559+_0x3f99af,_0x11c4a6+_0x27d036);}}const _0xaa0d8e={'from':_0x521601,'to':_0x5a9569},_0x557b14={'unitId':_0x803189,'subUnitId':_0x1638b2,'drawingId':_0x5d96c7,'drawingType':_univerjs_core[_0x25139d(0x166)]['DRAWING_SHAPE'],'sheetTransform':_0xaa0d8e,'transform':{'left':_0x464559,'top':_0x11c4a6,'width':_0x3f99af,'height':_0x27d036},'data':{'shapeType':_0x76ad2d,'shapeData':_0x57fe84},'axisAlignSheetTransform':_0xaa0d8e,'allowTransform':!![]};(0x0,_univerjs_pro_engine_shape[_0x25139d(0x1cb)])(_0x76ad2d)&&(_0x557b14[_0x25139d(0x197)][_0x25139d(0x199)]=![],_0x557b14[_0x25139d(0x197)][_0x25139d(0x1de)]=![],_0x557b14[_0x25139d(0x197)][_0x25139d(0x183)]=![],_0x557b14['data'][_0x25139d(0x18e)]=![],_0x557b14[_0x25139d(0x1cd)][_0x25139d(0x1de)]=![],_0x557b14[_0x25139d(0x1cd)][_0x25139d(0x183)]=![],_0x557b14[_0x25139d(0x1cd)]['borderEnabled']=![]);const {undo:_0x403a0d,redo:_0x572c00,objects:_0x57c231}=_0x518079['getBatchAddOp']([_0x557b14]),_0x585f99=_0xcad110[_0x25139d(0x1bb)]({'id':_univerjs_sheets_drawing[_0x25139d(0x1a0)]['id'],'params':{'unitId':_0x803189,'drawings':[_0x557b14]}}),_0x617d1e=[...(_0x5943e7=_0x585f99[_0x25139d(0x14f)])!==null&&_0x5943e7!==void 0x0?_0x5943e7:[],{'id':_univerjs_sheets_drawing[_0x25139d(0x1d2)]['id'],'params':{'unitId':_0x803189,'subUnitId':_0x1638b2,'op':_0x572c00,'objects':_0x57c231,'type':_univerjs_sheets_drawing['DrawingApplyType'][_0x25139d(0x151)]}},{'id':_univerjs_sheets_drawing[_0x25139d(0x1c4)]['id'],'params':[_0x803189]},..._0x585f99[_0x25139d(0x201)],{'id':InsertSheetsShapeMutation['id'],'params':_0x45342c}],_0x704694=[{'id':RemoveSheetsShapeMutation['id'],'params':{'unitId':_0x803189,'subUnitId':_0x1638b2,'shapeId':_0x5d96c7}},...(_0x5c0d49=_0x585f99[_0x25139d(0x167)])!==null&&_0x5c0d49!==void 0x0?_0x5c0d49:[],{'id':_univerjs_sheets_drawing[_0x25139d(0x1d2)]['id'],'params':{'unitId':_0x803189,'subUnitId':_0x1638b2,'op':_0x403a0d,'objects':_0x57c231,'type':_univerjs_sheets_drawing[_0x25139d(0x202)]['REMOVE']}},{'id':_univerjs_sheets_drawing[_0x25139d(0x1c4)]['id'],'params':[_0x803189]},..._0x585f99[_0x25139d(0x1fe)]];if((0x0,_univerjs_core[_0x25139d(0x1c3)])(_0x617d1e,_0x1e82b4)[_0x25139d(0x212)])return _0x2e954b[_0x25139d(0x157)]({'unitID':_0x803189,'undoMutations':_0x704694,'redoMutations':_0x617d1e}),!![];return![];}},UpdateSheetsShapeDataMutation={'id':_0x3add6b(0x1a1),'type':_univerjs_core[_0x3add6b(0x155)]['MUTATION'],'handler':(_0x4fc26b,_0x4769e1)=>{const _0x53330a=_0x3add6b,{unitId:_0x9e38fd,subUnitId:_0x297683,shapeType:_0x3a7c52,shapeId:_0x5bd03a,shapeData:_0x39d502}=_0x4769e1,_0x2c7596=_0x4fc26b[_0x53330a(0x19c)](SheetsShapeService)[_0x53330a(0x17d)](_0x9e38fd,_0x297683,_0x5bd03a);if(_0x2c7596){if(_0x3a7c52!==void 0x0)_0x2c7596[_0x53330a(0x1dc)](_0x3a7c52);if(_0x39d502)_0x2c7596===null||_0x2c7596===void 0x0||_0x2c7596[_0x53330a(0x1ab)](_0x39d502,!![]);}return!![];}},SetShapeDrawingDataCommand={'type':_univerjs_core[_0x3add6b(0x155)][_0x3add6b(0x1e6)],'id':_0x3add6b(0x1d6),'handler':(_0x3ec429,_0x2c4c68)=>{const _0x5f1e09=_0x3add6b;var _0xbe11a3,_0x162aa1;const _0x1dd586=(0x0,_univerjs_sheets[_0x5f1e09(0x162)])(_0x3ec429[_0x5f1e09(0x19c)](_univerjs_core['IUniverInstanceService']),_0x2c4c68);if(!_0x1dd586)return![];const _0x4c57af=_0x3ec429[_0x5f1e09(0x19c)](_univerjs_sheets[_0x5f1e09(0x20d)]),{unitId:_0x303849,subUnitId:_0x5688da}=_0x1dd586,_0xfd261d=_0x4c57af[_0x5f1e09(0x177)](_0x303849,_0x5688da);if(!_0xfd261d)return![];const _0x52688a=_0x3ec429[_0x5f1e09(0x19c)](SheetsShapeService),{shapeId:_0x3968a0,shapeType:_0x5928ed,shapeData:_0x27fd15,position:_0x1ef527,width:_0x1833dd,height:_0x350822}=_0x2c4c68,_0xb7e162=_0x52688a[_0x5f1e09(0x17d)](_0x303849,_0x5688da,_0x3968a0);if(!_0xb7e162)return![];const _0x197695=_0x3ec429['get'](_univerjs_core['ICommandService']),_0x471c14=_0x3ec429[_0x5f1e09(0x19c)](_univerjs_core[_0x5f1e09(0x172)]),_0x4c84e0=_0x3ec429[_0x5f1e09(0x19c)](_univerjs_sheets[_0x5f1e09(0x1a2)]),_0x394d02=_0x3ec429[_0x5f1e09(0x19c)](_univerjs_sheets_drawing[_0x5f1e09(0x188)]),_0x41522d={'unitId':_0x303849,'subUnitId':_0x5688da,'shapeId':_0x3968a0,'shapeType':_0x5928ed,'shapeData':_0x27fd15},_0x2ea2a9=_0xb7e162[_0x5f1e09(0x1a9)](),_0x133493=_0xb7e162[_0x5f1e09(0x186)](),{x:_0x4152c6,y:_0x7ca03d}=_0x1ef527,_0x20525b={'from':_0xfd261d['getCellIndexAndOffsetByPosition'](_0x4152c6,_0x7ca03d),'to':_0xfd261d[_0x5f1e09(0x1af)](_0x4152c6+_0x1833dd,_0x7ca03d+_0x350822)},_0x1d2fdf={'unitId':_0x303849,'subUnitId':_0x5688da,'drawingId':_0x3968a0,'drawingType':_univerjs_core[_0x5f1e09(0x166)][_0x5f1e09(0x174)],'sheetTransform':_0x20525b,'transform':{'left':_0x4152c6,'top':_0x7ca03d,'width':_0x1833dd,'height':_0x350822},'data':{'shapeType':_0x5928ed,'shapeData':_0x27fd15},'axisAlignSheetTransform':_0x20525b,'allowTransform':!![]};(0x0,_univerjs_pro_engine_shape[_0x5f1e09(0x1cb)])(_0x5928ed)&&(_0x1d2fdf[_0x5f1e09(0x197)][_0x5f1e09(0x199)]=![],_0x1d2fdf[_0x5f1e09(0x197)]['rotateEnabled']=![],_0x1d2fdf[_0x5f1e09(0x197)][_0x5f1e09(0x183)]=![],_0x1d2fdf['data'][_0x5f1e09(0x18e)]=![],_0x1d2fdf[_0x5f1e09(0x1cd)][_0x5f1e09(0x1de)]=![],_0x1d2fdf[_0x5f1e09(0x1cd)][_0x5f1e09(0x183)]=![],_0x1d2fdf[_0x5f1e09(0x1cd)][_0x5f1e09(0x18e)]=![]);const {undo:_0x2e6ad3,redo:_0x40db2c,objects:_0x5c8b10}=_0x394d02['getBatchUpdateOp']([_0x1d2fdf]),_0x2e0549=_0x4c84e0['onCommandExecute']({'id':_univerjs_sheets_drawing['SetSheetDrawingCommand']['id'],'params':{'unitId':_0x303849,'drawings':[_0x1d2fdf]}}),_0xa7d8f8=[...(_0xbe11a3=_0x2e0549['preRedos'])!==null&&_0xbe11a3!==void 0x0?_0xbe11a3:[],{'id':_univerjs_sheets_drawing[_0x5f1e09(0x1d2)]['id'],'params':{'unitId':_0x303849,'subUnitId':_0x5688da,'op':_0x40db2c,'objects':_0x5c8b10,'type':_univerjs_sheets_drawing['DrawingApplyType'][_0x5f1e09(0x1b6)]}},{'id':_univerjs_sheets_drawing['ClearSheetDrawingTransformerOperation']['id'],'params':[_0x303849]},..._0x2e0549['redos'],{'id':UpdateSheetsShapeDataMutation['id'],'params':_0x41522d}],_0x3c9f45=[...(_0x162aa1=_0x2e0549[_0x5f1e09(0x167)])!==null&&_0x162aa1!==void 0x0?_0x162aa1:[],{'id':_univerjs_sheets_drawing['SetDrawingApplyMutation']['id'],'params':{'unitId':_0x303849,'subUnitId':_0x5688da,'op':_0x2e6ad3,'objects':_0x5c8b10,'type':_univerjs_sheets_drawing[_0x5f1e09(0x202)][_0x5f1e09(0x1b6)]}},{'id':_univerjs_sheets_drawing['ClearSheetDrawingTransformerOperation']['id'],'params':[_0x303849]},..._0x2e0549[_0x5f1e09(0x1fe)],{'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x303849,'subUnitId':_0x5688da,'shapeType':_0x2ea2a9,'shapeId':_0x3968a0,'shapeData':_0x133493}}];if((0x0,_univerjs_core[_0x5f1e09(0x1c3)])(_0xa7d8f8,_0x197695)[_0x5f1e09(0x212)])return _0x471c14[_0x5f1e09(0x157)]({'unitID':_0x303849,'undoMutations':_0x3c9f45,'redoMutations':_0xa7d8f8}),!![];return![];}},ToggleSheetsShapeFlipCommand={'type':_univerjs_core['CommandType'][_0x3add6b(0x1e6)],'id':'sheet.command.toggle-shape-flip','handler':(_0x5c6f50,_0x125c24)=>{const _0x4a2875=_0x3add6b;var _0x5d69bb,_0x344674;const _0x40ad6e=(0x0,_univerjs_sheets['getSheetCommandTarget'])(_0x5c6f50['get'](_univerjs_core[_0x4a2875(0x1ee)]),_0x125c24);if(!_0x40ad6e)return![];const _0x424ccd=_0x5c6f50[_0x4a2875(0x19c)](_univerjs_sheets[_0x4a2875(0x20d)]),{unitId:_0x16836c,subUnitId:_0xc3d30a}=_0x40ad6e,_0x258eec=_0x424ccd[_0x4a2875(0x1b1)](_0x16836c,_0xc3d30a);if(!_0x258eec)return![];const _0x54f7dd=_0x5c6f50[_0x4a2875(0x19c)](_univerjs_sheets_drawing[_0x4a2875(0x188)]),{shapeId:_0x3f0c81,flipH:_0x53c480,flipV:_0x317df8}=_0x125c24,_0x442094=_0x54f7dd[_0x4a2875(0x159)]({'unitId':_0x16836c,'subUnitId':_0xc3d30a,'drawingId':_0x3f0c81});if(!_0x442094)return![];const _0x339a6b=_0x5c6f50['get'](SheetsShapeService)[_0x4a2875(0x17d)](_0x16836c,_0xc3d30a,_0x3f0c81);if(!_0x339a6b)return![];const _0x381c74=_0x5c6f50[_0x4a2875(0x19c)](_univerjs_core['ICommandService']),_0x579fe4=_0x5c6f50[_0x4a2875(0x19c)](_univerjs_core[_0x4a2875(0x172)]),_0xeb7402=_0x5c6f50[_0x4a2875(0x19c)](_univerjs_sheets['SheetInterceptorService']),_0x1ca7e5={..._0x442094[_0x4a2875(0x1cd)]};if(_0x53c480!==void 0x0)_0x1ca7e5[_0x4a2875(0x1a5)]=!_0x1ca7e5[_0x4a2875(0x1a5)];if(_0x317df8!==void 0x0)_0x1ca7e5[_0x4a2875(0x1f2)]=!_0x1ca7e5['flipY'];const _0x587241=(0x0,_univerjs_sheets_drawing[_0x4a2875(0x1da)])(_0x1ca7e5,_0x258eec),_0x3d72d2=(0x0,_univerjs_sheets_drawing[_0x4a2875(0x205)])(_0x1ca7e5,_0x258eec),_0x2c45af=_0x339a6b[_0x4a2875(0x1a9)](),_0x26923c=_0x339a6b[_0x4a2875(0x186)](),_0x5a2441={'unitId':_0x16836c,'subUnitId':_0xc3d30a,'drawingId':_0x3f0c81,'drawingType':_univerjs_core[_0x4a2875(0x166)]['DRAWING_SHAPE'],'sheetTransform':_0x587241,'transform':_0x1ca7e5,'data':{'shapeType':_0x2c45af,'shapeData':_0x26923c},'axisAlignSheetTransform':_0x3d72d2,'allowTransform':!![]},{undo:_0x49a022,redo:_0x25d835,objects:_0x4a90c0}=_0x54f7dd['getBatchUpdateOp']([_0x5a2441]),_0x117a05=_0xeb7402[_0x4a2875(0x1bb)]({'id':_univerjs_sheets_drawing[_0x4a2875(0x218)]['id'],'params':{'unitId':_0x16836c,'drawings':[_0x5a2441]}}),_0x3de728=[...(_0x5d69bb=_0x117a05[_0x4a2875(0x14f)])!==null&&_0x5d69bb!==void 0x0?_0x5d69bb:[],{'id':_univerjs_sheets_drawing[_0x4a2875(0x1d2)]['id'],'params':{'unitId':_0x16836c,'subUnitId':_0xc3d30a,'op':_0x25d835,'objects':_0x4a90c0,'type':_univerjs_sheets_drawing[_0x4a2875(0x202)][_0x4a2875(0x1b6)]}},{'id':_univerjs_sheets_drawing['ClearSheetDrawingTransformerOperation']['id'],'params':[_0x16836c]},..._0x117a05[_0x4a2875(0x201)]],_0x41919d=[...(_0x344674=_0x117a05[_0x4a2875(0x167)])!==null&&_0x344674!==void 0x0?_0x344674:[],{'id':_univerjs_sheets_drawing[_0x4a2875(0x1d2)]['id'],'params':{'unitId':_0x16836c,'subUnitId':_0xc3d30a,'op':_0x49a022,'objects':_0x4a90c0,'type':_univerjs_sheets_drawing[_0x4a2875(0x202)]['UPDATE']}},{'id':_univerjs_sheets_drawing['ClearSheetDrawingTransformerOperation']['id'],'params':[_0x16836c]},..._0x117a05['undos']];if((0x0,_univerjs_pro_engine_shape[_0x4a2875(0x1cb)])(_0x2c45af)){const _0x57f4be=_0x339a6b[_0x4a2875(0x1b2)]();if(_0x57f4be){const _0x361532={..._0x57f4be};_0x361532[_0x4a2875(0x1ff)]=void 0x0,_0x361532['to']=void 0x0,_0x3de728[_0x4a2875(0x182)]({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x16836c,'subUnitId':_0xc3d30a,'shapeId':_0x3f0c81,'shapeType':_0x2c45af,'shapeData':{'relation':_0x361532}}}),_0x41919d[_0x4a2875(0x182)]({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x16836c,'subUnitId':_0xc3d30a,'shapeId':_0x3f0c81,'shapeType':_0x2c45af,'shapeData':{'relation':_0x57f4be}}});}}if((0x0,_univerjs_core['sequenceExecute'])(_0x3de728,_0x381c74)['result'])return _0x579fe4[_0x4a2875(0x157)]({'unitID':_0x16836c,'undoMutations':_0x41919d,'redoMutations':_0x3de728}),!![];return![];}},SetSheetsShapeRotateCommand={'type':_univerjs_core[_0x3add6b(0x155)][_0x3add6b(0x1e6)],'id':_0x3add6b(0x18c),'handler':(_0x259d6e,_0x3ef077)=>{const _0x4aeb09=_0x3add6b;var _0x51b63a,_0x3fde81;const _0x3b0319=(0x0,_univerjs_sheets[_0x4aeb09(0x162)])(_0x259d6e[_0x4aeb09(0x19c)](_univerjs_core[_0x4aeb09(0x1ee)]),_0x3ef077);if(!_0x3b0319)return![];const _0x5dafa1=_0x259d6e[_0x4aeb09(0x19c)](_univerjs_sheets[_0x4aeb09(0x20d)]),{unitId:_0x103472,subUnitId:_0x2b7373}=_0x3b0319,_0x28c8e1=_0x5dafa1[_0x4aeb09(0x1b1)](_0x103472,_0x2b7373);if(!_0x28c8e1)return![];const _0x559dbc=_0x259d6e[_0x4aeb09(0x19c)](_univerjs_sheets_drawing[_0x4aeb09(0x188)]),{shapeId:_0x4ee0b1,rotate:_0xdde142}=_0x3ef077,_0x18de32=_0x559dbc[_0x4aeb09(0x159)]({'unitId':_0x103472,'subUnitId':_0x2b7373,'drawingId':_0x4ee0b1});if(!_0x18de32)return![];const _0x46e12d=_0x259d6e[_0x4aeb09(0x19c)](SheetsShapeService)[_0x4aeb09(0x17d)](_0x103472,_0x2b7373,_0x4ee0b1);if(!_0x46e12d)return![];const _0x562f67=_0x259d6e['get'](_univerjs_core[_0x4aeb09(0x1b5)]),_0x489fae=_0x259d6e[_0x4aeb09(0x19c)](_univerjs_core[_0x4aeb09(0x172)]),_0x423a3f=_0x259d6e[_0x4aeb09(0x19c)](_univerjs_sheets[_0x4aeb09(0x1a2)]),_0x444c05={..._0x18de32[_0x4aeb09(0x1cd)]};if(_0xdde142!==void 0x0)_0x444c05[_0x4aeb09(0x17c)]=(_0x444c05[_0x4aeb09(0x17c)]||0x0)+_0xdde142;const _0xcc759e=(0x0,_univerjs_sheets_drawing[_0x4aeb09(0x1da)])(_0x444c05,_0x28c8e1),_0x4b9045=(0x0,_univerjs_sheets_drawing[_0x4aeb09(0x205)])(_0x444c05,_0x28c8e1),_0xefa875=_0x46e12d[_0x4aeb09(0x1a9)](),_0xcbbaea=_0x46e12d['getShapeData'](),_0xc3d5ab={'unitId':_0x103472,'subUnitId':_0x2b7373,'drawingId':_0x4ee0b1,'drawingType':_univerjs_core['DrawingTypeEnum'][_0x4aeb09(0x174)],'sheetTransform':_0xcc759e,'transform':_0x444c05,'data':{'shapeType':_0xefa875,'shapeData':_0xcbbaea},'axisAlignSheetTransform':_0x4b9045,'allowTransform':!![]},{undo:_0x2ace1c,redo:_0x47a3fa,objects:_0x28281b}=_0x559dbc[_0x4aeb09(0x200)]([_0xc3d5ab]),_0x2547f0=_0x423a3f['onCommandExecute']({'id':_univerjs_sheets_drawing[_0x4aeb09(0x218)]['id'],'params':{'unitId':_0x103472,'drawings':[_0xc3d5ab]}}),_0x4b68a3=[...(_0x51b63a=_0x2547f0[_0x4aeb09(0x14f)])!==null&&_0x51b63a!==void 0x0?_0x51b63a:[],{'id':_univerjs_sheets_drawing['SetDrawingApplyMutation']['id'],'params':{'unitId':_0x103472,'subUnitId':_0x2b7373,'op':_0x47a3fa,'objects':_0x28281b,'type':_univerjs_sheets_drawing['DrawingApplyType']['UPDATE']}},{'id':_univerjs_sheets_drawing[_0x4aeb09(0x1c4)]['id'],'params':[_0x103472]},..._0x2547f0[_0x4aeb09(0x201)]],_0x3156ec=[...(_0x3fde81=_0x2547f0[_0x4aeb09(0x167)])!==null&&_0x3fde81!==void 0x0?_0x3fde81:[],{'id':_univerjs_sheets_drawing[_0x4aeb09(0x1d2)]['id'],'params':{'unitId':_0x103472,'subUnitId':_0x2b7373,'op':_0x2ace1c,'objects':_0x28281b,'type':_univerjs_sheets_drawing['DrawingApplyType'][_0x4aeb09(0x1b6)]}},{'id':_univerjs_sheets_drawing[_0x4aeb09(0x1c4)]['id'],'params':[_0x103472]},..._0x2547f0['undos']];if((0x0,_univerjs_core[_0x4aeb09(0x1c3)])(_0x4b68a3,_0x562f67)[_0x4aeb09(0x212)])return _0x489fae[_0x4aeb09(0x157)]({'unitID':_0x103472,'undoMutations':_0x3156ec,'redoMutations':_0x4b68a3}),!![];return![];}},SetSheetsShapeTextVerticalToggleCommand={'type':_univerjs_core[_0x3add6b(0x155)][_0x3add6b(0x1e6)],'id':_0x3add6b(0x189),'handler':(_0x40078f,_0xa2bbd9)=>{const _0x48c241=_0x3add6b;var _0x22ea11;const _0xdddfb6=(0x0,_univerjs_sheets[_0x48c241(0x162)])(_0x40078f[_0x48c241(0x19c)](_univerjs_core[_0x48c241(0x1ee)]),_0xa2bbd9);if(!_0xdddfb6)return![];const {unitId:_0x7c9b4b,subUnitId:_0x3af391}=_0xdddfb6,{shapeId:_0x1eae7a}=_0xa2bbd9,_0x13a02b=_0x40078f[_0x48c241(0x19c)](SheetsShapeService)[_0x48c241(0x17d)](_0x7c9b4b,_0x3af391,_0x1eae7a);if(!_0x13a02b)return![];const _0x219329=_0x13a02b[_0x48c241(0x152)](),_0x10f9f7=(_0x22ea11=_0x219329===null||_0x219329===void 0x0?void 0x0:_0x219329[_0x48c241(0x20e)])!==null&&_0x22ea11!==void 0x0?_0x22ea11:!![],_0x440b82=!_0x10f9f7,_0x20d11d=_0x40078f['get'](_univerjs_core[_0x48c241(0x1b5)]),_0x3cd189=_0x40078f[_0x48c241(0x19c)](_univerjs_core[_0x48c241(0x172)]),_0x5d79cc={'unitId':_0x7c9b4b,'subUnitId':_0x3af391,'shapeId':_0x1eae7a,'shapeData':{'shapeText':{'isHorizontal':_0x440b82}}},_0x42c252={'unitId':_0x7c9b4b,'subUnitId':_0x3af391,'shapeId':_0x1eae7a,'shapeData':{'shapeText':{'isHorizontal':_0x10f9f7}}},_0x135f7c=[{'id':UpdateSheetsShapeDataMutation['id'],'params':_0x5d79cc}],_0x32a5df=[{'id':UpdateSheetsShapeDataMutation['id'],'params':_0x42c252}];if((0x0,_univerjs_core['sequenceExecute'])(_0x135f7c,_0x20d11d)[_0x48c241(0x212)])return _0x3cd189[_0x48c241(0x157)]({'unitID':_0x7c9b4b,'undoMutations':_0x32a5df,'redoMutations':_0x135f7c}),!![];return![];}},UpdateConnectorRelationCommand={'type':_univerjs_core[_0x3add6b(0x155)][_0x3add6b(0x1e6)],'id':_0x3add6b(0x173),'handler':(_0x49c640,_0x4710fe)=>{const _0x5d7a29=_0x3add6b;var _0x49b101,_0x501213,_0x386e18,_0x197845;const _0x4f6c3c=(0x0,_univerjs_sheets[_0x5d7a29(0x162)])(_0x49c640[_0x5d7a29(0x19c)](_univerjs_core[_0x5d7a29(0x1ee)]),_0x4710fe);if(!_0x4f6c3c)return![];const _0x2faa21=_0x49c640[_0x5d7a29(0x19c)](_univerjs_sheets[_0x5d7a29(0x20d)]),{unitId:_0x350b3a,subUnitId:_0x145dcc}=_0x4f6c3c,_0x897e57=_0x2faa21['getSkeleton'](_0x350b3a,_0x145dcc);if(!_0x897e57)return![];const _0x5208a7=_0x49c640[_0x5d7a29(0x19c)](_univerjs_sheets_drawing['ISheetDrawingService']),{connectorShapeId:_0x5d3e32,width:_0x1540d5,height:_0x499870,left:_0x3ef48c,top:_0xf5a222,flipX:_0x332790,flipY:_0x1c7697,rotation:_0x85d6c5,oldAdjustValues:_0x9b446f,newAdjustValues:_0x3fe026,oldLineType:_0x10b24f,newLineType:_0x4d70ba,oldRelation:_0x565128,newRelation:_0x291c64}=_0x4710fe,_0x599d10=_0x5208a7[_0x5d7a29(0x159)]({'unitId':_0x350b3a,'subUnitId':_0x145dcc,'drawingId':_0x5d3e32});if(!_0x599d10)return![];const _0x39a213=_0x49c640[_0x5d7a29(0x19c)](SheetsShapeService)[_0x5d7a29(0x17d)](_0x350b3a,_0x145dcc,_0x5d3e32);if(!_0x39a213)return![];const _0x3d6cc1=_0x49c640[_0x5d7a29(0x19c)](_univerjs_core[_0x5d7a29(0x1b5)]),_0x1c0fcb=_0x49c640[_0x5d7a29(0x19c)](_univerjs_core[_0x5d7a29(0x172)]),_0x3d0d19=_0x49c640['get'](_univerjs_sheets[_0x5d7a29(0x1a2)]),_0x55279d={..._0x599d10['transform'],'width':_0x1540d5,'height':_0x499870,'left':_0x3ef48c,'top':_0xf5a222,'flipX':_0x332790,'flipY':_0x1c7697,'angle':(_0x49b101=_0x85d6c5!==null&&_0x85d6c5!==void 0x0?_0x85d6c5:(_0x501213=_0x599d10[_0x5d7a29(0x1cd)])===null||_0x501213===void 0x0?void 0x0:_0x501213[_0x5d7a29(0x17c)])!==null&&_0x49b101!==void 0x0?_0x49b101:0x0},_0x16eb27=(0x0,_univerjs_sheets_drawing['transformToDrawingPosition'])(_0x55279d,_0x897e57),_0x2811bf=(0x0,_univerjs_sheets_drawing[_0x5d7a29(0x205)])(_0x55279d,_0x897e57),_0x36c698=_0x39a213[_0x5d7a29(0x1a9)](),_0x44579f=_0x39a213[_0x5d7a29(0x186)](),_0x4afc7f={'unitId':_0x350b3a,'subUnitId':_0x145dcc,'drawingId':_0x5d3e32,'drawingType':_univerjs_core[_0x5d7a29(0x166)][_0x5d7a29(0x174)],'sheetTransform':_0x16eb27,'transform':_0x55279d,'data':{'shapeType':_0x4d70ba||_0x10b24f||_0x36c698,'shapeData':{..._0x44579f,'adjustValues':_0x3fe026||_0x9b446f||(_0x44579f===null||_0x44579f===void 0x0?void 0x0:_0x44579f[_0x5d7a29(0x1ce)]),'relation':_0x291c64||_0x565128||(_0x44579f===null||_0x44579f===void 0x0?void 0x0:_0x44579f[_0x5d7a29(0x161)])}},'axisAlignSheetTransform':_0x2811bf,'allowTransform':!![]},{undo:_0x4f3272,redo:_0x501f35,objects:_0x11fd68}=_0x5208a7[_0x5d7a29(0x200)]([_0x4afc7f]),_0x3091e4=_0x3d0d19[_0x5d7a29(0x1bb)]({'id':_univerjs_sheets_drawing['SetSheetDrawingCommand']['id'],'params':{'unitId':_0x350b3a,'drawings':[_0x4afc7f]}}),_0x5ac546=[...(_0x386e18=_0x3091e4[_0x5d7a29(0x14f)])!==null&&_0x386e18!==void 0x0?_0x386e18:[],{'id':_univerjs_sheets_drawing[_0x5d7a29(0x1d2)]['id'],'params':{'unitId':_0x350b3a,'subUnitId':_0x145dcc,'op':_0x501f35,'objects':_0x11fd68,'type':_univerjs_sheets_drawing[_0x5d7a29(0x202)][_0x5d7a29(0x1b6)]}},{'id':_univerjs_sheets_drawing[_0x5d7a29(0x1c4)]['id'],'params':[_0x350b3a]},..._0x3091e4[_0x5d7a29(0x201)],{'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x350b3a,'subUnitId':_0x145dcc,'shapeId':_0x5d3e32,'shapeType':_0x4d70ba,'shapeData':{'adjustValues':_0x3fe026,'relation':_0x291c64}}}],_0x132a5d=[...(_0x197845=_0x3091e4['preUndos'])!==null&&_0x197845!==void 0x0?_0x197845:[],{'id':_univerjs_sheets_drawing[_0x5d7a29(0x1d2)]['id'],'params':{'unitId':_0x350b3a,'subUnitId':_0x145dcc,'op':_0x4f3272,'objects':_0x11fd68,'type':_univerjs_sheets_drawing[_0x5d7a29(0x202)][_0x5d7a29(0x1b6)]}},{'id':_univerjs_sheets_drawing['ClearSheetDrawingTransformerOperation']['id'],'params':[_0x350b3a]},..._0x3091e4[_0x5d7a29(0x1fe)],{'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x350b3a,'subUnitId':_0x145dcc,'shapeId':_0x5d3e32,'shapeType':_0x36c698,'shapeData':{..._0x44579f,'adjustValues':_0x9b446f||(_0x44579f===null||_0x44579f===void 0x0?void 0x0:_0x44579f[_0x5d7a29(0x1ce)]),'relation':_0x565128||(_0x44579f===null||_0x44579f===void 0x0?void 0x0:_0x44579f[_0x5d7a29(0x161)])}}}];if((0x0,_univerjs_core[_0x5d7a29(0x1c3)])(_0x5ac546,_0x3d6cc1)[_0x5d7a29(0x212)])return _0x1c0fcb[_0x5d7a29(0x157)]({'unitID':_0x350b3a,'undoMutations':_0x132a5d,'redoMutations':_0x5ac546}),!![];return![];}},UpdateLineShapeResizeCommand={'type':_univerjs_core[_0x3add6b(0x155)][_0x3add6b(0x1e6)],'id':'sheet.command.update-line-shape-resize','handler':(_0x497f6c,_0x5a33b6)=>{const _0x2bf45c=_0x3add6b;var _0x23d722,_0x250112;const _0x16a45f=(0x0,_univerjs_sheets[_0x2bf45c(0x162)])(_0x497f6c['get'](_univerjs_core[_0x2bf45c(0x1ee)]),_0x5a33b6);if(!_0x16a45f)return![];const _0x54ce1e=_0x497f6c[_0x2bf45c(0x19c)](_univerjs_sheets[_0x2bf45c(0x20d)]),{unitId:_0x5e6e5a,subUnitId:_0x12b9dd}=_0x16a45f,_0x39305d=_0x54ce1e[_0x2bf45c(0x1b1)](_0x5e6e5a,_0x12b9dd);if(!_0x39305d)return![];const _0x10e7bb=_0x497f6c['get'](_univerjs_sheets_drawing[_0x2bf45c(0x188)]),{shapeId:_0x240387,width:_0x55f688,height:_0x803263,left:_0x3a77a8,top:_0x11150e,flipX:_0x558c7d,flipY:_0x3b9075,angle:_0x514859,oldAdjustValues:_0x12c713,newAdjustValues:_0x7d0cb3,oldLineType:_0x3bf08a,newLineType:_0xd15ac0}=_0x5a33b6,_0x301db8=_0x10e7bb[_0x2bf45c(0x159)]({'unitId':_0x5e6e5a,'subUnitId':_0x12b9dd,'drawingId':_0x240387});if(!_0x301db8)return![];const _0x2ea41c=_0x497f6c[_0x2bf45c(0x19c)](SheetsShapeService)[_0x2bf45c(0x17d)](_0x5e6e5a,_0x12b9dd,_0x240387);if(!_0x2ea41c)return![];const _0x30c55b=_0x497f6c[_0x2bf45c(0x19c)](_univerjs_core[_0x2bf45c(0x1b5)]),_0x15f39a=_0x497f6c['get'](_univerjs_core[_0x2bf45c(0x172)]),_0x9e0980=_0x497f6c[_0x2bf45c(0x19c)](_univerjs_sheets[_0x2bf45c(0x1a2)]),_0x37d840={..._0x301db8[_0x2bf45c(0x1cd)],'width':_0x55f688,'height':_0x803263,'left':_0x3a77a8,'top':_0x11150e,'flipX':_0x558c7d,'flipY':_0x3b9075,'angle':_0x514859},_0x5772c8=(0x0,_univerjs_sheets_drawing[_0x2bf45c(0x1da)])(_0x37d840,_0x39305d),_0x392031=(0x0,_univerjs_sheets_drawing['transformToAxisAlignPosition'])(_0x37d840,_0x39305d),_0x57c8e0=_0x2ea41c[_0x2bf45c(0x1a9)](),_0x4f7318=_0x2ea41c['getShapeData'](),_0x3cd205={'unitId':_0x5e6e5a,'subUnitId':_0x12b9dd,'drawingId':_0x240387,'drawingType':_univerjs_core['DrawingTypeEnum'][_0x2bf45c(0x174)],'sheetTransform':_0x5772c8,'transform':_0x37d840,'data':{'shapeType':_0xd15ac0||_0x3bf08a||_0x57c8e0,'shapeData':{..._0x4f7318,'adjustValues':_0x7d0cb3||_0x12c713||(_0x4f7318===null||_0x4f7318===void 0x0?void 0x0:_0x4f7318[_0x2bf45c(0x1ce)])}},'axisAlignSheetTransform':_0x392031,'allowTransform':!![]},{undo:_0x1fb088,redo:_0x138ec5,objects:_0x2a6927}=_0x10e7bb['getBatchUpdateOp']([_0x3cd205]),_0x17eeb4=_0x9e0980[_0x2bf45c(0x1bb)]({'id':_univerjs_sheets_drawing[_0x2bf45c(0x218)]['id'],'params':{'unitId':_0x5e6e5a,'drawings':[_0x3cd205]}}),_0x5ed9e7=[...(_0x23d722=_0x17eeb4['preRedos'])!==null&&_0x23d722!==void 0x0?_0x23d722:[],{'id':_univerjs_sheets_drawing[_0x2bf45c(0x1d2)]['id'],'params':{'unitId':_0x5e6e5a,'subUnitId':_0x12b9dd,'op':_0x138ec5,'objects':_0x2a6927,'type':_univerjs_sheets_drawing[_0x2bf45c(0x202)][_0x2bf45c(0x1b6)]}},{'id':_univerjs_sheets_drawing[_0x2bf45c(0x1c4)]['id'],'params':[_0x5e6e5a]},..._0x17eeb4[_0x2bf45c(0x201)],{'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x5e6e5a,'subUnitId':_0x12b9dd,'shapeId':_0x240387,'shapeType':_0xd15ac0,'shapeData':{'adjustValues':_0x7d0cb3}}}],_0x38d2bf=[...(_0x250112=_0x17eeb4[_0x2bf45c(0x167)])!==null&&_0x250112!==void 0x0?_0x250112:[],{'id':_univerjs_sheets_drawing['SetDrawingApplyMutation']['id'],'params':{'unitId':_0x5e6e5a,'subUnitId':_0x12b9dd,'op':_0x1fb088,'objects':_0x2a6927,'type':_univerjs_sheets_drawing['DrawingApplyType'][_0x2bf45c(0x1b6)]}},{'id':_univerjs_sheets_drawing[_0x2bf45c(0x1c4)]['id'],'params':[_0x5e6e5a]},..._0x17eeb4['undos'],{'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x5e6e5a,'subUnitId':_0x12b9dd,'shapeId':_0x240387,'shapeType':_0x57c8e0,'shapeData':{..._0x4f7318,'adjustValues':_0x12c713||(_0x4f7318===null||_0x4f7318===void 0x0?void 0x0:_0x4f7318[_0x2bf45c(0x1ce)])}}}];if((0x0,_univerjs_core['sequenceExecute'])(_0x5ed9e7,_0x30c55b)['result'])return _0x15f39a[_0x2bf45c(0x157)]({'unitID':_0x5e6e5a,'undoMutations':_0x38d2bf,'redoMutations':_0x5ed9e7}),!![];return![];}},UpdateSheetsShapeTypeMutation={'id':_0x3add6b(0x180),'type':_univerjs_core[_0x3add6b(0x155)][_0x3add6b(0x1be)],'handler':(_0xf8147d,_0x2272b0)=>{const _0xa656e3=_0x3add6b,{unitId:_0xd4648b,subUnitId:_0x2cc9d6,shapeType:_0x563ddc,shapeId:_0x547677,shapeData:_0x591146}=_0x2272b0,_0x112450=_0xf8147d[_0xa656e3(0x19c)](SheetsShapeService)[_0xa656e3(0x17d)](_0xd4648b,_0x2cc9d6,_0x547677);if(_0x112450){_0x112450[_0xa656e3(0x1dc)](_0x563ddc);if(_0x591146)_0x112450===null||_0x112450===void 0x0||_0x112450[_0xa656e3(0x1ab)](_0x591146);}return!![];}},UpdateSheetsShapeTypeCommand={'id':_0x3add6b(0x1a7),'type':_univerjs_core[_0x3add6b(0x155)][_0x3add6b(0x1e6)],'handler':(_0x2f2267,_0x394350)=>{const _0x52e7c1=_0x3add6b;if(!_0x394350)return![];const _0x8bbc71=_0x2f2267['get'](_univerjs_core[_0x52e7c1(0x1b5)]),_0x566921=_0x2f2267[_0x52e7c1(0x19c)](SheetsShapeService),_0x4b713a=_0x2f2267[_0x52e7c1(0x19c)](_univerjs_core[_0x52e7c1(0x172)]),_0x40b593=[],_0x21593e=[],{unitId:_0x53b7ab,subUnitId:_0x3073fb,shapeId:_0x3cdd05,shapeType:_0x22eb3f,shapeData:_0x5133b0}=_0x394350,_0x5e02e2=_0x566921[_0x52e7c1(0x17d)](_0x53b7ab,_0x3073fb,_0x3cdd05);if(_0x5e02e2){const _0x4fc9a3=_0x5e02e2[_0x52e7c1(0x1a9)](),_0x5acd2b=Object[_0x52e7c1(0x195)]({},_0x5e02e2[_0x52e7c1(0x186)]()),_0x4327f4={'unitId':_0x53b7ab,'subUnitId':_0x3073fb,'shapeId':_0x3cdd05,'shapeType':_0x22eb3f,'shapeData':_0x5133b0},_0x281fe1={'unitId':_0x53b7ab,'subUnitId':_0x3073fb,'shapeId':_0x3cdd05,'shapeType':_0x4fc9a3,'shapeData':_0x5acd2b};_0x40b593[_0x52e7c1(0x182)]({'id':UpdateSheetsShapeTypeMutation['id'],'params':_0x4327f4}),_0x21593e[_0x52e7c1(0x182)]({'id':UpdateSheetsShapeTypeMutation['id'],'params':_0x281fe1});if(_0x40b593[_0x52e7c1(0x1b7)](_0x4f9229=>_0x8bbc71[_0x52e7c1(0x1c8)](_0x4f9229['id'],_0x4f9229[_0x52e7c1(0x1f5)])))_0x4b713a[_0x52e7c1(0x157)]({'unitID':_0x53b7ab,'redoMutations':[..._0x40b593],'undoMutations':[..._0x21593e]});return!![];}return![];}};var name=_0x3add6b(0x1e8),version='0.22.0';const SHEETS_SHAPE_PLUGIN_CONFIG_KEY=_0x3add6b(0x198),configSymbol=Symbol(SHEETS_SHAPE_PLUGIN_CONFIG_KEY),defaultPluginConfig={};let SheetsShapeController=class SheetsShapeController extends _univerjs_core['Disposable']{constructor(_0x1e1b9a,_0x354826,_0x3e9a27,_0x354ed8,_0x3764d2){const _0x26cadc=_0x3add6b;super(),this[_0x26cadc(0x193)]=_0x1e1b9a,this[_0x26cadc(0x1fd)]=_0x354826,this[_0x26cadc(0x1b9)]=_0x3e9a27,this[_0x26cadc(0x194)]=_0x354ed8,this['_drawingManagerService']=_0x3764d2,this[_0x26cadc(0x156)](),this['_initCommandInterceptor']();}['_initCommands'](){const _0x327cb3=_0x3add6b;[InsertShapeCommand,SetShapeDrawingDataCommand,ToggleSheetsShapeFlipCommand,SetSheetsShapeRotateCommand,SetSheetsShapeTextVerticalToggleCommand,UpdateConnectorRelationCommand,UpdateLineShapeResizeCommand,InsertSheetsShapeMutation,RemoveSheetsShapeMutation,UpdateSheetsShapeTypeMutation,UpdateSheetsShapeDataMutation][_0x327cb3(0x1b3)](_0x23e021=>this[_0x327cb3(0x1ba)](this[_0x327cb3(0x193)]['registerCommand'](_0x23e021)));}[_0x3add6b(0x1f3)](){const _0x1ba492=_0x3add6b;this['disposeWithMe'](this[_0x1ba492(0x1fd)][_0x1ba492(0x1d5)]({'getMutations':_0xaf68d3=>{const _0x3c58c6=_0x1ba492;if(_0xaf68d3['id']===_univerjs_sheets_drawing[_0x3c58c6(0x207)]['id']){const {drawings:_0x543e22}=_0xaf68d3[_0x3c58c6(0x1f5)],_0x20aa5e=_0x543e22[_0x3c58c6(0x15a)](_0x45ec6e=>_0x45ec6e[_0x3c58c6(0x1f7)]===_univerjs_core[_0x3c58c6(0x166)]['DRAWING_SHAPE']);if(_0x20aa5e[_0x3c58c6(0x16b)]===0x0)return{'preRedos':[],'redos':[],'preUndos':[],'undos':[]};const _0x41974d=[],_0x5ef199=[];return _0x20aa5e[_0x3c58c6(0x1b3)](_0x4d5b1d=>{const _0x2566d1=_0x3c58c6,{unitId:_0x4cf296,subUnitId:_0x3ac355,drawingId:_0x51b56e}=_0x4d5b1d,_0x59a594=this[_0x2566d1(0x194)][_0x2566d1(0x17d)](_0x4cf296,_0x3ac355,_0x51b56e);if(!_0x59a594)throw new TypeError(_0x2566d1(0x1db)+_0x59a594);_0x41974d['push']({'id':RemoveSheetsShapeMutation['id'],'params':{'unitId':_0x4cf296,'subUnitId':_0x3ac355,'shapeId':_0x51b56e}}),_0x5ef199['push']({'id':InsertSheetsShapeMutation['id'],'params':{'unitId':_0x4cf296,'subUnitId':_0x3ac355,'shapeId':_0x51b56e,'shapeType':_0x59a594['getShapeType'](),'shapeData':_0x59a594[_0x2566d1(0x186)]()}});const _0x1fdeaf=this[_0x2566d1(0x194)][_0x2566d1(0x15d)](_0x4cf296,_0x3ac355,_0x51b56e);if(_0x1fdeaf)for(const _0x499980 of _0x1fdeaf){const _0x3f2c90=_0x499980['lineShapeId'],_0x3daaff=_0x499980[_0x2566d1(0x1f8)],_0x586e03=_0x3daaff?{'from':void 0x0}:{'to':void 0x0},_0x28122a=_0x3daaff?{'from':{'shapeId':_0x499980[_0x2566d1(0x1e7)],'cxnIndex':_0x499980[_0x2566d1(0x1ef)]}}:{'to':{'shapeId':_0x499980[_0x2566d1(0x1e7)],'cxnIndex':_0x499980[_0x2566d1(0x1ef)]}};_0x41974d['push']({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x4cf296,'subUnitId':_0x3ac355,'shapeId':_0x3f2c90,'shapeData':{'relation':_0x586e03}}}),_0x5ef199[_0x2566d1(0x182)]({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x4cf296,'subUnitId':_0x3ac355,'shapeId':_0x3f2c90,'shapeData':{'relation':_0x28122a}}});}}),{'preRedos':_0x41974d,'redos':[],'preUndos':[],'undos':_0x5ef199};}if(_0xaf68d3['id']===_univerjs_sheets_drawing['SetSheetDrawingCommand']['id']){const {drawings:_0x39eba2}=_0xaf68d3['params'],_0x57903f=_0x39eba2[_0x3c58c6(0x15a)](_0x4ae2c7=>_0x4ae2c7[_0x3c58c6(0x1f7)]===_univerjs_core['DrawingTypeEnum']['DRAWING_SHAPE']);if(_0x57903f[_0x3c58c6(0x16b)]===0x0)return{'preRedos':[],'redos':[],'preUndos':[],'undos':[]};const _0x50828a=[],_0x5796b5=[];for(const _0x558bf6 of _0x57903f){const {unitId:_0x1e6e0b,subUnitId:_0x367016,drawingId:_0x3be320,transform:_0x31438b}=_0x558bf6;if(!_0x1e6e0b||!_0x367016||!_0x3be320||!_0x31438b)continue;const _0x3b8c6a=this[_0x3c58c6(0x194)][_0x3c58c6(0x17d)](_0x1e6e0b,_0x367016,_0x3be320);if(!_0x3b8c6a)throw new TypeError('Fail\x20to\x20get\x20shape\x20model,\x20get:\x20'+_0x3b8c6a);if((0x0,_univerjs_pro_engine_shape[_0x3c58c6(0x1cb)])(_0x3b8c6a[_0x3c58c6(0x1a9)]())){const _0x20f437=this[_0x3c58c6(0x194)][_0x3c58c6(0x215)](_0x1e6e0b,_0x367016,_0x3be320),_0x442c7a={'from':void 0x0,'to':void 0x0};_0x20f437&&(_0x50828a[_0x3c58c6(0x182)]({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x1e6e0b,'subUnitId':_0x367016,'shapeId':_0x3be320,'shapeData':{'relation':_0x442c7a}}}),_0x5796b5[_0x3c58c6(0x182)]({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x1e6e0b,'subUnitId':_0x367016,'shapeId':_0x3be320,'shapeData':{'relation':_0x20f437}}}));}else{const _0x33aba3=this[_0x3c58c6(0x194)][_0x3c58c6(0x15d)](_0x1e6e0b,_0x367016,_0x3be320);if(_0x33aba3&&_0x33aba3['length']>0x0)for(const _0x16f177 of _0x33aba3){const _0x4f8d92=_0x16f177[_0x3c58c6(0x16c)],_0x1e2a8b=_0x16f177[_0x3c58c6(0x1f8)],_0x311adb=this['_sheetsShapeService'][_0x3c58c6(0x17d)](_0x1e6e0b,_0x367016,_0x4f8d92);if(!_0x311adb)continue;const _0x149747=_0x311adb[_0x3c58c6(0x16d)](),_0x2b72e3=_0x311adb[_0x3c58c6(0x14d)]();if(_0x149747&&_0x2b72e3)this[_0x3c58c6(0x1c6)](_0x1e6e0b,_0x367016,_0x4f8d92,_0x311adb,_0x149747,_0x2b72e3,_0x50828a,_0x5796b5,_0x3be320,_0x31438b);else this[_0x3c58c6(0x1bd)](_0x1e6e0b,_0x367016,_0x4f8d92,_0x311adb,_0x1e2a8b?_0x149747:_0x2b72e3,_0x1e2a8b,_0x50828a,_0x5796b5,_0x3be320,_0x31438b);}}}return{'preRedos':[],'redos':_0x50828a,'preUndos':_0x5796b5,'undos':[]};}return{'preRedos':[],'redos':[],'preUndos':[],'undos':[]};}}));}['_getConnectPointInfo'](_0x25643b,_0x46f0b9,_0x48b762,_0xafd522,_0x3f3299){const _0x4c77d8=_0x3add6b;if(!_0x46f0b9||!_0x48b762)return null;const {shapeId:_0x4c058d,cxnIndex:_0x25caa7}=_0x25643b,_0x593c89=this[_0x4c77d8(0x194)][_0x4c77d8(0x17d)](_0x46f0b9,_0x48b762,_0x4c058d);if(!_0x593c89)return null;const _0x3b3b71=this['_drawingManagerService'][_0x4c77d8(0x159)]({'unitId':_0x46f0b9,'subUnitId':_0x48b762,'drawingId':_0x4c058d});if(!(_0x3b3b71===null||_0x3b3b71===void 0x0?void 0x0:_0x3b3b71[_0x4c77d8(0x1cd)]))return null;let {left:left=0x0,top:top=0x0,width:width=0x0,height:height=0x0,flipX:flipX=![],flipY:flipY=![],angle:_0x92a12d}=_0x3b3b71[_0x4c77d8(0x1cd)];if(_0x3f3299&&_0xafd522===_0x4c058d){var _0x5df30a,_0x4ecda0,_0x28b43c,_0xe64303,_0x1430e2,_0x2bc499,_0xf4e884;left=(_0x5df30a=_0x3f3299[_0x4c77d8(0x153)])!==null&&_0x5df30a!==void 0x0?_0x5df30a:left,top=(_0x4ecda0=_0x3f3299[_0x4c77d8(0x1e9)])!==null&&_0x4ecda0!==void 0x0?_0x4ecda0:top,width=(_0x28b43c=_0x3f3299[_0x4c77d8(0x15e)])!==null&&_0x28b43c!==void 0x0?_0x28b43c:width,height=(_0xe64303=_0x3f3299[_0x4c77d8(0x1aa)])!==null&&_0xe64303!==void 0x0?_0xe64303:height,flipX=(_0x1430e2=_0x3f3299[_0x4c77d8(0x1a5)])!==null&&_0x1430e2!==void 0x0?_0x1430e2:flipX,flipY=(_0x2bc499=_0x3f3299[_0x4c77d8(0x1f2)])!==null&&_0x2bc499!==void 0x0?_0x2bc499:flipY,_0x92a12d=(_0xf4e884=_0x3f3299[_0x4c77d8(0x17c)])!==null&&_0xf4e884!==void 0x0?_0xf4e884:_0x92a12d;}_0x593c89[_0x4c77d8(0x1ad)]({'width':width,'height':height});const _0x309c26=_0x593c89['getConnectionSiteList']()[_0x4c77d8(0x1fb)](_0x2be185=>_0x2be185[_0x4c77d8(0x20a)]===_0x25caa7);if(!_0x309c26)return null;let _0x234e48=flipX?width-_0x309c26['x']:_0x309c26['x'],_0x47bf0f=flipY?height-_0x309c26['y']:_0x309c26['y'];if(_0x92a12d!==0x0&&_0x92a12d!==void 0x0&&_0x92a12d!==null){const _0x16e867=_0x92a12d*Math['PI']/0xb4,_0x8a0016=Math[_0x4c77d8(0x1f1)](_0x16e867),_0x31a210=Math[_0x4c77d8(0x187)](_0x16e867),_0x8660a=width/0x2,_0x1bed8f=height/0x2,_0x402b23=_0x234e48-_0x8660a,_0x40b42e=_0x47bf0f-_0x1bed8f;_0x234e48=_0x8660a+_0x402b23*_0x8a0016-_0x40b42e*_0x31a210,_0x47bf0f=_0x1bed8f+_0x402b23*_0x31a210+_0x40b42e*_0x8a0016;}_0x234e48+=left,_0x47bf0f+=top;let _0x553e22=_0x309c26['ang']/0xea60;if(flipX)_0x553e22=0xb4-_0x553e22;if(flipY)_0x553e22=-_0x553e22;_0x553e22+=_0x92a12d||0x0,_0x553e22=(_0x553e22%0x168+0x168)%0x168;const _0x6aae94=(0x0,_univerjs_pro_engine_shape[_0x4c77d8(0x150)])({'left':left,'top':top,'width':width,'height':height},_0x92a12d||0x0);return{'point':{'x':_0x234e48,'y':_0x47bf0f},'angle':_0x553e22,'bounds':_0x6aae94};}[_0x3add6b(0x1c6)](_0x12d5ce,_0x183e35,_0x5d8308,_0xf46256,_0x1a1025,_0x494579,_0x365852,_0x903636,_0x59cbd4,_0x22c3ef){const _0x2c538c=_0x3add6b,_0x1d6df6=this[_0x2c538c(0x1b9)][_0x2c538c(0x1b1)](_0x12d5ce,_0x183e35);if(!_0x1d6df6)return;const _0xf02145=_0xf46256[_0x2c538c(0x1b2)](),_0x148bd0=_0xf46256[_0x2c538c(0x208)](),_0x2faddf={},_0x2fd3bd={};_0x148bd0[_0x2c538c(0x1b3)](_0x4324f3=>{const _0x1f4925=_0x2c538c,_0x47f34e=_0xf46256[_0x1f4925(0x169)](_0x4324f3);_0x2fd3bd[_0x4324f3]=_0x47f34e!==null&&_0x47f34e!==void 0x0?_0x47f34e:0x0;});const _0x6c0fd6=this[_0x2c538c(0x160)](_0x1a1025,_0x12d5ce,_0x183e35,_0x59cbd4,_0x22c3ef),_0x5b71d=this[_0x2c538c(0x160)](_0x494579,_0x12d5ce,_0x183e35,_0x59cbd4,_0x22c3ef);if(_0x6c0fd6&&_0x5b71d){const _0x2ccea2=_0xf46256[_0x2c538c(0x1a9)](),_0x417950=(0x0,_univerjs_pro_engine_shape[_0x2c538c(0x1cf)])(_0x6c0fd6,_0x5b71d,_0x2ccea2);let _0x46c71b=_0x2ccea2;if(_0x417950){const _0x42d4ea=(0x0,_univerjs_pro_engine_shape[_0x2c538c(0x203)])(_0x417950,_0xf46256[_0x2c538c(0x1a9)]()),_0x45aa57=this[_0x2c538c(0x154)]['getDrawingData'](_0x12d5ce,_0x183e35);if(_0x45aa57&&_0x45aa57[_0x5d8308]){const _0x2118ab=_0x45aa57[_0x5d8308];_0x46c71b=_0x42d4ea[_0x2c538c(0x1ed)];for(const [_0xc2e28,_0x13f7cb]of Object[_0x2c538c(0x1b4)](_0x42d4ea[_0x2c538c(0x1ce)]))_0x2faddf[_0xc2e28]=_0x13f7cb;const _0x378a3e={..._0x2118ab[_0x2c538c(0x1cd)],'width':_0x42d4ea[_0x2c538c(0x196)]['width'],'height':_0x42d4ea['worldRect'][_0x2c538c(0x1aa)],'left':_0x42d4ea[_0x2c538c(0x196)][_0x2c538c(0x153)],'top':_0x42d4ea[_0x2c538c(0x196)][_0x2c538c(0x1e9)],'flipX':_0x42d4ea[_0x2c538c(0x196)][_0x2c538c(0x1a5)],'flipY':_0x42d4ea[_0x2c538c(0x196)][_0x2c538c(0x1f2)],'angle':_0x42d4ea[_0x2c538c(0x1e3)]},_0x3a4f4e=(0x0,_univerjs_sheets_drawing[_0x2c538c(0x1da)])(_0x378a3e,_0x1d6df6),_0x89ae4a=(0x0,_univerjs_sheets_drawing[_0x2c538c(0x205)])(_0x378a3e,_0x1d6df6),_0x1eeec={'unitId':_0x12d5ce,'subUnitId':_0x183e35,'drawingType':_univerjs_core[_0x2c538c(0x166)][_0x2c538c(0x174)],'drawingId':_0x5d8308,'transform':_0x378a3e,'sheetTransform':_0x3a4f4e,'axisAlignSheetTransform':_0x89ae4a},{unitId:_0x51dba2,subUnitId:_0x2cb218,undo:_0x59ad7b,redo:_0x1fed6b,objects:_0x1620d4}=this[_0x2c538c(0x154)][_0x2c538c(0x200)]([_0x1eeec]);_0x365852['push']({'id':_univerjs_sheets_drawing[_0x2c538c(0x1d2)]['id'],'params':{'unitId':_0x51dba2,'subUnitId':_0x2cb218,'op':_0x1fed6b,'objects':_0x1620d4,'type':_univerjs_sheets_drawing[_0x2c538c(0x202)]['UPDATE']}}),_0x903636['push']({'id':_univerjs_sheets_drawing[_0x2c538c(0x1d2)]['id'],'params':{'unitId':_0x51dba2,'subUnitId':_0x2cb218,'op':_0x59ad7b,'objects':_0x1620d4,'type':_univerjs_sheets_drawing[_0x2c538c(0x202)][_0x2c538c(0x1b6)]}});}_0xf46256[_0x2c538c(0x1f4)]();}_0x365852['push']({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x12d5ce,'subUnitId':_0x183e35,'shapeId':_0x5d8308,'shapeType':_0x46c71b,'shapeData':{'adjustValues':_0x2faddf,'relation':_0xf02145}}}),_0x903636['push']({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x12d5ce,'subUnitId':_0x183e35,'shapeId':_0x5d8308,'shapeType':_0x2ccea2,'shapeData':{'adjustValues':_0x2fd3bd,'relation':_0xf02145}}});}}[_0x3add6b(0x1bd)](_0x144415,_0x1a37fc,_0x3422ce,_0x51db20,_0x18b466,_0x96e6b3,_0x12cceb,_0x7ab5f1,_0x26bb36,_0xc8edb2){const _0x4c79cd=_0x3add6b;var _0x30901f;if(!_0x18b466)return;const _0x45b588=this['_sheetSkeletonService'][_0x4c79cd(0x1b1)](_0x144415,_0x1a37fc);if(!_0x45b588)return;const _0x2302cc=(_0x30901f=this[_0x4c79cd(0x154)]['getDrawingByParam']({'unitId':_0x144415,'subUnitId':_0x1a37fc,'drawingId':_0x26bb36}))===null||_0x30901f===void 0x0?void 0x0:_0x30901f[_0x4c79cd(0x1cd)];if(!_0x2302cc)return;const _0x26d524=_0x2302cc[_0x4c79cd(0x153)]!==_0xc8edb2[_0x4c79cd(0x153)]||_0x2302cc[_0x4c79cd(0x1e9)]!==_0xc8edb2['top'],_0x24df88=_0x2302cc[_0x4c79cd(0x15e)]!==_0xc8edb2[_0x4c79cd(0x15e)]||_0x2302cc['height']!==_0xc8edb2[_0x4c79cd(0x1aa)],_0x2a27b8=_0x2302cc[_0x4c79cd(0x1a5)]!==_0xc8edb2[_0x4c79cd(0x1a5)]||_0x2302cc[_0x4c79cd(0x1f2)]!==_0xc8edb2['flipY'],_0x5ae2ea=_0x2302cc[_0x4c79cd(0x17c)]!==_0xc8edb2['angle'];if(_0x26d524&&!_0x24df88&&!_0x2a27b8&&!_0x5ae2ea){var _0x59dba2,_0x3c975a,_0x16653,_0x57cf0a;const _0x41cb96=((_0x59dba2=_0xc8edb2[_0x4c79cd(0x153)])!==null&&_0x59dba2!==void 0x0?_0x59dba2:0x0)-((_0x3c975a=_0x2302cc[_0x4c79cd(0x153)])!==null&&_0x3c975a!==void 0x0?_0x3c975a:0x0),_0x2f7e3a=((_0x16653=_0xc8edb2['top'])!==null&&_0x16653!==void 0x0?_0x16653:0x0)-((_0x57cf0a=_0x2302cc[_0x4c79cd(0x1e9)])!==null&&_0x57cf0a!==void 0x0?_0x57cf0a:0x0),_0x29f4fa=this[_0x4c79cd(0x154)][_0x4c79cd(0x18d)](_0x144415,_0x1a37fc);if(_0x29f4fa&&_0x29f4fa[_0x3422ce]){var _0x7b6b13,_0x5e297c,_0x2fcb0f,_0x58d495;const _0x2b390c=_0x29f4fa[_0x3422ce],_0x3b951b={..._0x2b390c['transform'],'left':((_0x7b6b13=(_0x5e297c=_0x2b390c['transform'])===null||_0x5e297c===void 0x0?void 0x0:_0x5e297c['left'])!==null&&_0x7b6b13!==void 0x0?_0x7b6b13:0x0)+_0x41cb96,'top':((_0x2fcb0f=(_0x58d495=_0x2b390c[_0x4c79cd(0x1cd)])===null||_0x58d495===void 0x0?void 0x0:_0x58d495[_0x4c79cd(0x1e9)])!==null&&_0x2fcb0f!==void 0x0?_0x2fcb0f:0x0)+_0x2f7e3a},_0x4237e5=(0x0,_univerjs_sheets_drawing[_0x4c79cd(0x1da)])(_0x3b951b,_0x45b588),_0xe78956=(0x0,_univerjs_sheets_drawing['transformToAxisAlignPosition'])(_0x3b951b,_0x45b588),_0x41ab14={'unitId':_0x144415,'subUnitId':_0x1a37fc,'drawingType':_univerjs_core['DrawingTypeEnum'][_0x4c79cd(0x174)],'drawingId':_0x3422ce,'transform':_0x3b951b,'sheetTransform':_0x4237e5,'axisAlignSheetTransform':_0xe78956},{unitId:_0x27e9e5,subUnitId:_0x420853,undo:_0x3ed800,redo:_0x1c48d4,objects:_0x44dbdd}=this[_0x4c79cd(0x154)][_0x4c79cd(0x200)]([_0x41ab14]);_0x12cceb[_0x4c79cd(0x182)]({'id':_univerjs_sheets_drawing[_0x4c79cd(0x1d2)]['id'],'params':{'unitId':_0x27e9e5,'subUnitId':_0x420853,'op':_0x1c48d4,'objects':_0x44dbdd,'type':_univerjs_sheets_drawing[_0x4c79cd(0x202)][_0x4c79cd(0x1b6)]}}),_0x7ab5f1[_0x4c79cd(0x182)]({'id':_univerjs_sheets_drawing[_0x4c79cd(0x1d2)]['id'],'params':{'unitId':_0x27e9e5,'subUnitId':_0x420853,'op':_0x3ed800,'objects':_0x44dbdd,'type':_univerjs_sheets_drawing[_0x4c79cd(0x202)][_0x4c79cd(0x1b6)]}});}}else{const _0x1e0cea=_0x51db20[_0x4c79cd(0x16d)](),_0x5ead65=_0x51db20[_0x4c79cd(0x14d)]();this['_addLineRerouteUpdates'](_0x144415,_0x1a37fc,_0x3422ce,_0x51db20,_0x1e0cea,_0x5ead65,_0x12cceb,_0x7ab5f1,_0x26bb36,_0xc8edb2);}}};SheetsShapeController=__decorate([__decorateParam(0x0,_univerjs_core[_0x3add6b(0x1b5)]),__decorateParam(0x1,(0x0,_univerjs_core[_0x3add6b(0x176)])(_univerjs_sheets[_0x3add6b(0x1a2)])),__decorateParam(0x2,(0x0,_univerjs_core[_0x3add6b(0x176)])(_univerjs_sheets['SheetSkeletonService'])),__decorateParam(0x3,(0x0,_univerjs_core[_0x3add6b(0x176)])(SheetsShapeService)),__decorateParam(0x4,(0x0,_univerjs_core[_0x3add6b(0x176)])(_univerjs_drawing[_0x3add6b(0x16e)]))],SheetsShapeController);let UniverSheetsShapePlugin=class UniverSheetsShapePlugin extends _univerjs_core[_0x3add6b(0x1bf)]{constructor(_0x5133b5=defaultPluginConfig,_0x4cfe22,_0x1da6b8,_0x476ac8){const _0x52dc15=_0x3add6b;super(),this['_config']=_0x5133b5,this[_0x52dc15(0x1a4)]=_0x4cfe22,this['_commandService']=_0x1da6b8,this[_0x52dc15(0x1f6)]=_0x476ac8;const {..._0x326bc2}=(0x0,_univerjs_core['merge'])({},defaultPluginConfig,this['_config']);this[_0x52dc15(0x1f6)][_0x52dc15(0x1d1)](SHEETS_SHAPE_PLUGIN_CONFIG_KEY,_0x326bc2);}[_0x3add6b(0x175)](){const _0x4b1d7b=_0x3add6b,_0x1c6b30=this[_0x4b1d7b(0x1a4)];[[SheetShapeModelManager],[SheetsShapeService],[SheetsShapeController]][_0x4b1d7b(0x1b3)](_0x1e7242=>_0x1c6b30['add'](_0x1e7242)),(0x0,_univerjs_core[_0x4b1d7b(0x1d3)])(_0x1c6b30,[[SheetsShapeService],[SheetsShapeController]]);}};_defineProperty(UniverSheetsShapePlugin,_0x3add6b(0x163),_univerjs_core['UniverInstanceType'][_0x3add6b(0x1b8)]),_defineProperty(UniverSheetsShapePlugin,_0x3add6b(0x168),'SHEET_SHAPE_PLUGIN'),_defineProperty(UniverSheetsShapePlugin,_0x3add6b(0x178),name),_defineProperty(UniverSheetsShapePlugin,_0x3add6b(0x1e1),version),UniverSheetsShapePlugin=__decorate([(0x0,_univerjs_core['DependentOn'])(_univerjs_pro_license['UniverLicensePlugin']),__decorateParam(0x1,(0x0,_univerjs_core[_0x3add6b(0x176)])(_univerjs_core[_0x3add6b(0x1b0)])),__decorateParam(0x2,_univerjs_core[_0x3add6b(0x1b5)]),__decorateParam(0x3,_univerjs_core[_0x3add6b(0x165)])],UniverSheetsShapePlugin),exports[_0x3add6b(0x181)]=DEFAULT_SHAPE_HEIGHT,exports[_0x3add6b(0x1a8)]=DEFAULT_SHAPE_WIDTH,exports[_0x3add6b(0x190)]=InsertShapeCommand,exports[_0x3add6b(0x214)]=InsertSheetsShapeMutation,exports[_0x3add6b(0x1ec)]=RemoveSheetsShapeMutation,exports[_0x3add6b(0x1e0)]=SetShapeDrawingDataCommand,exports[_0x3add6b(0x1d7)]=SetSheetsShapeRotateCommand,exports[_0x3add6b(0x171)]=SetSheetsShapeTextVerticalToggleCommand,Object[_0x3add6b(0x206)](exports,'SheetsShapeService',{'enumerable':!![],'get':function(){return SheetsShapeService;}}),exports[_0x3add6b(0x192)]=ToggleSheetsShapeFlipCommand,Object[_0x3add6b(0x206)](exports,'UniverSheetsShapePlugin',{'enumerable':!![],'get':function(){return UniverSheetsShapePlugin;}}),exports[_0x3add6b(0x1df)]=UpdateConnectorRelationCommand,exports[_0x3add6b(0x1c7)]=UpdateLineShapeResizeCommand,exports[_0x3add6b(0x1d8)]=UpdateSheetsShapeDataMutation,exports[_0x3add6b(0x1cc)]=UpdateSheetsShapeTypeCommand,exports[_0x3add6b(0x1ac)]=UpdateSheetsShapeTypeMutation;
1
+ const _0x31b92c=_0x38a0;(function(_0x555af1,_0x1ce3c7){const _0x1a2e86=_0x38a0,_0x51935a=_0x555af1();while(!![]){try{const _0x1e653c=-parseInt(_0x1a2e86(0x243))/0x1+parseInt(_0x1a2e86(0x28a))/0x2*(-parseInt(_0x1a2e86(0x25c))/0x3)+parseInt(_0x1a2e86(0x269))/0x4*(-parseInt(_0x1a2e86(0x259))/0x5)+-parseInt(_0x1a2e86(0x277))/0x6*(parseInt(_0x1a2e86(0x24b))/0x7)+-parseInt(_0x1a2e86(0x1ee))/0x8*(parseInt(_0x1a2e86(0x288))/0x9)+parseInt(_0x1a2e86(0x1fe))/0xa+parseInt(_0x1a2e86(0x260))/0xb;if(_0x1e653c===_0x1ce3c7)break;else _0x51935a['push'](_0x51935a['shift']());}catch(_0x3dcd48){_0x51935a['push'](_0x51935a['shift']());}}}(_0x2a88,0x3e73b),Object[_0x31b92c(0x28d)](exports,Symbol[_0x31b92c(0x207)],{'value':_0x31b92c(0x231)}));let _univerjs_pro_engine_shape=require('@univerjs-pro/engine-shape'),_univerjs_core=require('@univerjs/core'),_univerjs_sheets=require('@univerjs/sheets'),_univerjs_sheets_drawing=require('@univerjs/sheets-drawing'),_univerjs_pro_license=require('@univerjs-pro/license'),_univerjs_drawing=require('@univerjs/drawing');const DEFAULT_SHAPE_WIDTH=0xc8,DEFAULT_SHAPE_HEIGHT=0xc8;function _typeof(_0x1f6bfd){'@babel/helpers - typeof';const _0x5e48c8=_0x31b92c;return _typeof='function'==typeof Symbol&&_0x5e48c8(0x236)==typeof Symbol['iterator']?function(_0x167e38){return typeof _0x167e38;}:function(_0x9c31){const _0x4986ad=_0x5e48c8;return _0x9c31&&_0x4986ad(0x278)==typeof Symbol&&_0x9c31[_0x4986ad(0x1f1)]===Symbol&&_0x9c31!==Symbol[_0x4986ad(0x205)]?_0x4986ad(0x236):typeof _0x9c31;},_typeof(_0x1f6bfd);}function toPrimitive(_0x46bbb7,_0x108fae){const _0xcde50c=_0x31b92c;if(_0xcde50c(0x25f)!=_typeof(_0x46bbb7)||!_0x46bbb7)return _0x46bbb7;var _0xc3318e=_0x46bbb7[Symbol[_0xcde50c(0x1f8)]];if(void 0x0!==_0xc3318e){var _0x588653=_0xc3318e[_0xcde50c(0x22a)](_0x46bbb7,_0x108fae||_0xcde50c(0x1ff));if(_0xcde50c(0x25f)!=_typeof(_0x588653))return _0x588653;throw new TypeError('@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.');}return(_0xcde50c(0x272)===_0x108fae?String:Number)(_0x46bbb7);}function toPropertyKey(_0x270cad){const _0x37ca9a=_0x31b92c;var _0x1c3959=toPrimitive(_0x270cad,'string');return _0x37ca9a(0x236)==_typeof(_0x1c3959)?_0x1c3959:_0x1c3959+'';}function _defineProperty(_0x331dcd,_0x9a00a7,_0x344c26){const _0x318dae=_0x31b92c;return(_0x9a00a7=toPropertyKey(_0x9a00a7))in _0x331dcd?Object[_0x318dae(0x28d)](_0x331dcd,_0x9a00a7,{'value':_0x344c26,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x331dcd[_0x9a00a7]=_0x344c26,_0x331dcd;}function _0x38a0(_0x223cfd,_0x49c5b2){_0x223cfd=_0x223cfd-0x1dd;const _0x2a8835=_0x2a88();let _0x38a0a5=_0x2a8835[_0x223cfd];return _0x38a0a5;}var SheetShapeModelManager=class extends _univerjs_core[_0x31b92c(0x23c)]{constructor(){const _0x4276e2=_0x31b92c;super(),_defineProperty(this,_0x4276e2(0x289),new Map()),_defineProperty(this,_0x4276e2(0x250),new Set()),_defineProperty(this,_0x4276e2(0x29c),new Set());}['addShape'](_0x5093f5,_0x1087e1,_0x2c6f4e){const _0x59883c=_0x31b92c,_0x40ebbc=new _univerjs_pro_engine_shape['ShapeModel'](_0x5093f5,_0x1087e1,_0x2c6f4e);this[_0x59883c(0x289)][_0x59883c(0x25e)](_0x1087e1,_0x40ebbc);if((0x0,_univerjs_pro_engine_shape[_0x59883c(0x1e1)])(_0x5093f5))this['_linesIds']['add'](_0x1087e1);return _0x40ebbc;}[_0x31b92c(0x262)](_0x1aecb0){const _0xeb3ac6=_0x31b92c,_0x58cbbd=[];for(const _0x3108ce of this[_0xeb3ac6(0x250)]){const _0x1d1c6f=this[_0xeb3ac6(0x289)][_0xeb3ac6(0x282)](_0x3108ce);if(_0x1d1c6f){const _0x570479=_0x1d1c6f['getShapeRelation']();if(_0x570479){var _0x2d14d5,_0x15bd3e;if(((_0x2d14d5=_0x570479[_0xeb3ac6(0x28c)])===null||_0x2d14d5===void 0x0?void 0x0:_0x2d14d5[_0xeb3ac6(0x22d)])===_0x1aecb0)_0x58cbbd[_0xeb3ac6(0x241)]({..._0x570479['from'],'lineShapeId':_0x3108ce,'isFrom':!![]});if(((_0x15bd3e=_0x570479['to'])===null||_0x15bd3e===void 0x0?void 0x0:_0x15bd3e[_0xeb3ac6(0x22d)])===_0x1aecb0)_0x58cbbd[_0xeb3ac6(0x241)]({..._0x570479['to'],'lineShapeId':_0x3108ce,'isFrom':![]});}}}return _0x58cbbd;}[_0x31b92c(0x226)](_0x3e88f5){const _0x42f281=_0x31b92c,_0x530f1e=this[_0x42f281(0x289)]['get'](_0x3e88f5);if(_0x530f1e)return _0x530f1e[_0x42f281(0x1f3)]();}[_0x31b92c(0x201)](_0x3fb3f8){const _0x33ca6b=_0x31b92c,_0x1370af=this['_shapes'][_0x33ca6b(0x282)](_0x3fb3f8);if(_0x1370af)return _0x1370af[_0x33ca6b(0x201)]();}[_0x31b92c(0x1df)](_0x54f17e){const _0x1dbaea=_0x31b92c;return this[_0x1dbaea(0x289)][_0x1dbaea(0x223)](_0x54f17e);}[_0x31b92c(0x2a2)](_0x120167){const _0x194aa3=_0x31b92c,_0x5278d4=this[_0x194aa3(0x289)][_0x194aa3(0x282)](_0x120167);if(!_0x5278d4)return;if((0x0,_univerjs_pro_engine_shape[_0x194aa3(0x1e1)])(_0x5278d4['getShapeType']()))this[_0x194aa3(0x250)][_0x194aa3(0x27a)](_0x120167);this[_0x194aa3(0x289)][_0x194aa3(0x27a)](_0x120167);}[_0x31b92c(0x1f4)](){const _0x3260a5=_0x31b92c,_0x3a8546=[];return this['_shapes'][_0x3260a5(0x22e)](_0xb10fa5=>{const _0x2e175d=_0x3260a5;_0x3a8546[_0x2e175d(0x241)](_0xb10fa5[_0x2e175d(0x1f4)]());}),_0x3a8546;}[_0x31b92c(0x293)](_0x13e77d){const _0x59aae5=_0x31b92c;for(const _0x3c38f3 of _0x13e77d){const {id:_0x1ea047,shapeType:_0x5f1159}=_0x3c38f3,_0x33fed3=this[_0x59aae5(0x296)](_0x5f1159,_0x1ea047,_0x3c38f3[_0x59aae5(0x291)]);if(_0x33fed3&&_0x33fed3['isLineShape']())this[_0x59aae5(0x250)]['add'](_0x1ea047);}}[_0x31b92c(0x203)](){const _0x2bc850=_0x31b92c;if(this[_0x2bc850(0x221)])return;this[_0x2bc850(0x289)]['forEach'](_0x5f3dc4=>{const _0x5d0f69=_0x2bc850;_0x5f3dc4[_0x5d0f69(0x203)]();}),this[_0x2bc850(0x289)]['clear'](),this[_0x2bc850(0x250)][_0x2bc850(0x21f)](),this[_0x2bc850(0x29c)]['clear'](),super[_0x2bc850(0x203)]();}};function __decorateParam(_0x1f4434,_0x49705){return function(_0x3baab1,_0x394881){_0x49705(_0x3baab1,_0x394881,_0x1f4434);};}function __decorate(_0x8875ec,_0x1789ac,_0x31da2b,_0x4c1014){const _0x4742f8=_0x31b92c;var _0x206c59=arguments['length'],_0x5565a5=_0x206c59<0x3?_0x1789ac:_0x4c1014===null?_0x4c1014=Object[_0x4742f8(0x1f2)](_0x1789ac,_0x31da2b):_0x4c1014,_0x48b10a;if(typeof Reflect===_0x4742f8(0x25f)&&typeof Reflect[_0x4742f8(0x1eb)]===_0x4742f8(0x278))_0x5565a5=Reflect['decorate'](_0x8875ec,_0x1789ac,_0x31da2b,_0x4c1014);else{for(var _0x4a160d=_0x8875ec['length']-0x1;_0x4a160d>=0x0;_0x4a160d--)if(_0x48b10a=_0x8875ec[_0x4a160d])_0x5565a5=(_0x206c59<0x3?_0x48b10a(_0x5565a5):_0x206c59>0x3?_0x48b10a(_0x1789ac,_0x31da2b,_0x5565a5):_0x48b10a(_0x1789ac,_0x31da2b))||_0x5565a5;}return _0x206c59>0x3&&_0x5565a5&&Object[_0x4742f8(0x28d)](_0x1789ac,_0x31da2b,_0x5565a5),_0x5565a5;}const SHEET_SHAPE_PLUGIN=_0x31b92c(0x255);let SheetsShapeService=class SheetsShapeService extends _univerjs_core[_0x31b92c(0x23c)]{constructor(_0x56fabc){const _0x5d7abe=_0x31b92c;super(),this['_resourcesManagerService']=_0x56fabc,_defineProperty(this,_0x5d7abe(0x214),new Map()),this[_0x5d7abe(0x283)]();}['_ensureShapeModelManager'](_0x4d162e,_0x310b14){const _0x56bcb1=_0x31b92c;let _0x4903ef=this['_shapeModelManagerMap'][_0x56bcb1(0x282)](_0x4d162e);!_0x4903ef&&(_0x4903ef=new Map(),this[_0x56bcb1(0x214)]['set'](_0x4d162e,_0x4903ef));let _0x55ca54=_0x4903ef['get'](_0x310b14);return!_0x55ca54&&(_0x55ca54=new SheetShapeModelManager(),_0x4903ef[_0x56bcb1(0x25e)](_0x310b14,_0x55ca54)),_0x55ca54;}[_0x31b92c(0x24f)](_0x3eaba0,_0x351388,_0x1730af,_0x1bd67e,_0x1388bc){const _0x3e664d=_0x31b92c;this[_0x3e664d(0x242)](_0x3eaba0,_0x351388)[_0x3e664d(0x296)](_0x1730af,_0x1bd67e,_0x1388bc);}[_0x31b92c(0x2a2)](_0x11368f,_0x7fbfe3,_0x4d7333){const _0x3f71c1=_0x31b92c;this[_0x3f71c1(0x242)](_0x11368f,_0x7fbfe3)[_0x3f71c1(0x2a2)](_0x4d7333);}[_0x31b92c(0x1e3)](_0x3194e4,_0x27acb0,_0x1967db){const _0xe2a771=_0x31b92c;return this[_0xe2a771(0x242)](_0x3194e4,_0x27acb0)[_0xe2a771(0x201)](_0x1967db);}[_0x31b92c(0x201)](_0xe68435,_0x1e1a0e,_0x2f406c){return this['_ensureShapeModelManager'](_0xe68435,_0x1e1a0e)['getShapeType'](_0x2f406c);}[_0x31b92c(0x1df)](_0x242385,_0x2cc5ab,_0x4c2d17){const _0x143d1a=_0x31b92c;return this[_0x143d1a(0x242)](_0x242385,_0x2cc5ab)[_0x143d1a(0x1df)](_0x4c2d17);}['getShapeTypeById'](_0x1bde0d,_0x254a3a,_0x51a796){const _0x1a0590=_0x31b92c;return this[_0x1a0590(0x242)](_0x1bde0d,_0x254a3a)[_0x1a0590(0x201)](_0x51a796);}['getShapeDataById'](_0x235965,_0xf73dd2,_0x41da10){const _0x4e2449=_0x31b92c,_0x53338f=this[_0x4e2449(0x242)](_0x235965,_0xf73dd2);if(!_0x53338f['getShapeType'](_0x41da10))return;const _0x1fdbd4=_0x53338f[_0x4e2449(0x289)][_0x4e2449(0x282)](_0x41da10);if(!_0x1fdbd4)return;return _0x1fdbd4[_0x4e2449(0x286)]();}[_0x31b92c(0x251)](_0x12cc46,_0x1add11,_0x5b5529){const _0xa88e0b=_0x31b92c;return this[_0xa88e0b(0x242)](_0x12cc46,_0x1add11)[_0xa88e0b(0x289)][_0xa88e0b(0x282)](_0x5b5529);}[_0x31b92c(0x262)](_0x236380,_0x38a9ff,_0x1bbfe8){return this['_ensureShapeModelManager'](_0x236380,_0x38a9ff)['getBasicShapeRelation'](_0x1bbfe8);}['getLineShapeRelation'](_0x444d88,_0x2e6a3c,_0x5acb79){const _0x2a254a=_0x31b92c,_0x5f3a08=this[_0x2a254a(0x242)](_0x444d88,_0x2e6a3c)[_0x2a254a(0x289)][_0x2a254a(0x282)](_0x5acb79);if(!_0x5f3a08)return;return _0x5f3a08[_0x2a254a(0x1f3)]();}['setShapeType'](){}[_0x31b92c(0x27c)](_0x9a8550){const _0x3a8e7c=_0x31b92c,_0x54c660={},_0xec87d1=this[_0x3a8e7c(0x214)][_0x3a8e7c(0x282)](_0x9a8550);if(_0xec87d1)_0xec87d1['forEach']((_0x5bfd3c,_0xc94e39)=>{const _0x1aa416=_0x3a8e7c,_0x30a762=_0x5bfd3c[_0x1aa416(0x1f4)]();if(_0x30a762[_0x1aa416(0x29e)]>0x0)_0x54c660[_0xc94e39]=_0x30a762;});return JSON['stringify'](_0x54c660);}[_0x31b92c(0x275)](_0x1ffe7d,_0xf50109){const _0xa3da1c=_0x31b92c;Object['keys'](_0xf50109)[_0xa3da1c(0x22e)](_0x1451b6=>{const _0x435619=_0xa3da1c;this[_0x435619(0x242)](_0x1ffe7d,_0x1451b6)['fromJSON'](_0xf50109[_0x1451b6]);});}[_0x31b92c(0x1f4)](){const _0x3c98eb=_0x31b92c,_0x477d4d={};return this[_0x3c98eb(0x214)]['forEach']((_0x56bd45,_0x57a560)=>{const _0x3daf28=_0x3c98eb;_0x477d4d[_0x57a560]={},_0x56bd45[_0x3daf28(0x22e)]((_0x5b3358,_0x7d87d9)=>{const _0xb9c7aa=_0x3daf28;_0x477d4d[_0x57a560][_0x7d87d9]=_0x5b3358[_0xb9c7aa(0x1f4)]();});}),_0x477d4d;}[_0x31b92c(0x293)](_0x3177be){const _0x1890c3=_0x31b92c;Object[_0x1890c3(0x2a1)](_0x3177be)['forEach'](_0x204cf9=>{const _0x18778a=_0x1890c3,_0x2dab4b=_0x3177be[_0x204cf9];Object[_0x18778a(0x2a1)](_0x2dab4b)['forEach'](_0x3fc8ca=>{const _0x503d35=_0x18778a;this[_0x503d35(0x242)](_0x204cf9,_0x3fc8ca)[_0x503d35(0x293)](_0x2dab4b[_0x3fc8ca]);});});}[_0x31b92c(0x283)](){const _0x330d6a=_0x31b92c;this['_resourcesManagerService'][_0x330d6a(0x261)]({'pluginName':SHEET_SHAPE_PLUGIN,'businesses':[_univerjs_core[_0x330d6a(0x246)]['UNIVER_SHEET']],'toJson':_0x124b35=>this[_0x330d6a(0x27c)](_0x124b35),'parseJson':_0x436b53=>JSON[_0x330d6a(0x1f6)](_0x436b53),'onLoad':(_0x23aefe,_0x2059c4)=>{const _0x52a31d=_0x330d6a;this[_0x52a31d(0x275)](_0x23aefe,_0x2059c4);},'onUnLoad':_0x198b1d=>{const _0x3c4c15=_0x330d6a,_0x829357=this[_0x3c4c15(0x214)][_0x3c4c15(0x282)](_0x198b1d);_0x829357&&(_0x829357[_0x3c4c15(0x22e)](_0x523da0=>{_0x523da0['dispose']();}),this[_0x3c4c15(0x214)][_0x3c4c15(0x27a)](_0x198b1d));}});}[_0x31b92c(0x203)](){const _0x312be8=_0x31b92c;this[_0x312be8(0x214)]['forEach'](_0x2eab06=>{const _0x3c7a63=_0x312be8;_0x2eab06[_0x3c7a63(0x22e)](_0x3611f5=>{const _0x1429f1=_0x3c7a63;_0x3611f5[_0x1429f1(0x203)]();});});}};SheetsShapeService=__decorate([__decorateParam(0x0,_univerjs_core[_0x31b92c(0x1e7)])],SheetsShapeService);const InsertSheetsShapeMutation={'id':'sheet.mutation.insert-shape','type':_univerjs_core[_0x31b92c(0x20f)][_0x31b92c(0x28e)],'handler':(_0x232800,_0x335d7a)=>{const _0xbd9da7=_0x31b92c,{unitId:_0x38c7d4,subUnitId:_0x24fa9a,shapeType:_0x1b7b9d,shapeId:_0xfcd570,shapeData:_0x39051d}=_0x335d7a;return _0x232800[_0xbd9da7(0x282)](SheetsShapeService)[_0xbd9da7(0x24f)](_0x38c7d4,_0x24fa9a,_0x1b7b9d,_0xfcd570,_0x39051d),!![];}},RemoveSheetsShapeMutation={'id':'sheet.mutation.remove-shape','type':_univerjs_core[_0x31b92c(0x20f)][_0x31b92c(0x28e)],'handler':(_0x581adb,_0x11baea)=>{const _0x118971=_0x31b92c,{unitId:_0x1efbf2,subUnitId:_0x4a6de6,shapeId:_0x2f5c8a}=_0x11baea;return _0x581adb['get'](SheetsShapeService)[_0x118971(0x2a2)](_0x1efbf2,_0x4a6de6,_0x2f5c8a),!![];}},InsertShapeCommand={'type':_univerjs_core[_0x31b92c(0x20f)][_0x31b92c(0x216)],'id':_0x31b92c(0x292),'handler':(_0x59bb2f,_0x1ce619)=>{const _0x4cd9f5=_0x31b92c;var _0x1b040d,_0x1f4634;const _0x414de3=(0x0,_univerjs_sheets['getSheetCommandTarget'])(_0x59bb2f['get'](_univerjs_core[_0x4cd9f5(0x208)]),_0x1ce619);if(!_0x414de3)return![];const _0xa6cc61=_0x59bb2f['get'](_univerjs_sheets[_0x4cd9f5(0x213)]),{unitId:_0x3e48c1,subUnitId:_0x12af66}=_0x414de3,_0x5a9731=_0xa6cc61['ensureSkeleton'](_0x3e48c1,_0x12af66);if(!_0x5a9731)return![];const _0x192354=_0x59bb2f[_0x4cd9f5(0x282)](_univerjs_core[_0x4cd9f5(0x26b)]),_0x4ec3e6=_0x59bb2f['get'](_univerjs_core[_0x4cd9f5(0x26e)]),_0x43cfec=_0x59bb2f[_0x4cd9f5(0x282)](_univerjs_sheets[_0x4cd9f5(0x279)]),_0x372cf6=_0x59bb2f[_0x4cd9f5(0x282)](_univerjs_sheets_drawing[_0x4cd9f5(0x295)]),{shapeType:_0x361b41,shapeData:_0x40343a}=_0x1ce619,_0x244b62=_0x1ce619[_0x4cd9f5(0x22d)]||(0x0,_univerjs_core['generateRandomId'])(),_0x135741={'unitId':_0x3e48c1,'subUnitId':_0x12af66,'shapeId':_0x244b62,'shapeType':_0x361b41,'shapeData':_0x40343a},_0x114554=_0x1ce619[_0x4cd9f5(0x25a)]||0xc8,_0x5d2cba=_0x1ce619[_0x4cd9f5(0x254)]||0xc8;let _0xfc798d=0x0,_0x5669b8=0x0,_0x1b6b05={'row':0x0,'rowOffset':0x0,'column':0x0,'columnOffset':0x0},_0x4eff1d={'row':0x0,'rowOffset':0x0,'column':0x0,'columnOffset':0x0};if(_0x1ce619[_0x4cd9f5(0x1de)]){const {x:_0x2a1b0b,y:_0x14095e}=_0x1ce619[_0x4cd9f5(0x1de)];_0xfc798d=_0x2a1b0b,_0x5669b8=_0x14095e,_0x1b6b05=_0x5a9731[_0x4cd9f5(0x21e)](_0x2a1b0b,_0x14095e),_0x4eff1d=_0x5a9731[_0x4cd9f5(0x21e)](_0x2a1b0b+_0x114554,_0x14095e+_0x5d2cba);}else{if(_0x1ce619[_0x4cd9f5(0x222)]){const {startRow:_0x5cd404,startColumn:_0x177a41}=_0x1ce619[_0x4cd9f5(0x222)],_0x166bf6=0xa,_0x2215b0=0xa;_0x1b6b05={'row':_0x5cd404,'rowOffset':_0x166bf6,'column':_0x177a41,'columnOffset':_0x2215b0};const _0x9ac8dc=_0x5a9731[_0x4cd9f5(0x1e4)](_0x5cd404,_0x177a41);_0xfc798d=_0x9ac8dc[_0x4cd9f5(0x25d)]+_0x2215b0,_0x5669b8=_0x9ac8dc['startY']+_0x166bf6,_0x4eff1d=_0x5a9731[_0x4cd9f5(0x21e)](_0xfc798d+_0x114554,_0x5669b8+_0x5d2cba);}}const _0x260813={'from':_0x1b6b05,'to':_0x4eff1d},_0x349d31={'unitId':_0x3e48c1,'subUnitId':_0x12af66,'drawingId':_0x244b62,'drawingType':_univerjs_core['DrawingTypeEnum'][_0x4cd9f5(0x23e)],'sheetTransform':_0x260813,'transform':{'left':_0xfc798d,'top':_0x5669b8,'width':_0x114554,'height':_0x5d2cba},'data':{'shapeType':_0x361b41,'shapeData':_0x40343a},'axisAlignSheetTransform':_0x260813,'allowTransform':!![]};(0x0,_univerjs_pro_engine_shape[_0x4cd9f5(0x1e1)])(_0x361b41)&&(_0x349d31[_0x4cd9f5(0x239)]['fill']=![],_0x349d31[_0x4cd9f5(0x239)]['rotateEnabled']=![],_0x349d31['data']['resizeEnabled']=![],_0x349d31[_0x4cd9f5(0x239)]['borderEnabled']=![],_0x349d31[_0x4cd9f5(0x29b)][_0x4cd9f5(0x2a0)]=![],_0x349d31[_0x4cd9f5(0x29b)][_0x4cd9f5(0x200)]=![],_0x349d31[_0x4cd9f5(0x29b)]['borderEnabled']=![]);const {undo:_0x2fdd00,redo:_0x365f8b,objects:_0xfaa836}=_0x372cf6[_0x4cd9f5(0x256)]([_0x349d31]),_0x4216db=_0x43cfec[_0x4cd9f5(0x290)]({'id':_univerjs_sheets_drawing[_0x4cd9f5(0x266)]['id'],'params':{'unitId':_0x3e48c1,'drawings':[_0x349d31]}}),_0x20b5a8=[...(_0x1b040d=_0x4216db['preRedos'])!==null&&_0x1b040d!==void 0x0?_0x1b040d:[],{'id':_univerjs_sheets_drawing[_0x4cd9f5(0x21c)]['id'],'params':{'unitId':_0x3e48c1,'subUnitId':_0x12af66,'op':_0x365f8b,'objects':_0xfaa836,'type':_univerjs_sheets_drawing['DrawingApplyType'][_0x4cd9f5(0x20b)]}},{'id':_univerjs_sheets_drawing[_0x4cd9f5(0x1e2)]['id'],'params':[_0x3e48c1]},..._0x4216db[_0x4cd9f5(0x26a)],{'id':InsertSheetsShapeMutation['id'],'params':_0x135741}],_0x52b493=[{'id':RemoveSheetsShapeMutation['id'],'params':{'unitId':_0x3e48c1,'subUnitId':_0x12af66,'shapeId':_0x244b62}},...(_0x1f4634=_0x4216db['preUndos'])!==null&&_0x1f4634!==void 0x0?_0x1f4634:[],{'id':_univerjs_sheets_drawing['SetDrawingApplyMutation']['id'],'params':{'unitId':_0x3e48c1,'subUnitId':_0x12af66,'op':_0x2fdd00,'objects':_0xfaa836,'type':_univerjs_sheets_drawing[_0x4cd9f5(0x206)][_0x4cd9f5(0x257)]}},{'id':_univerjs_sheets_drawing[_0x4cd9f5(0x1e2)]['id'],'params':[_0x3e48c1]},..._0x4216db['undos']];if((0x0,_univerjs_core[_0x4cd9f5(0x298)])(_0x20b5a8,_0x192354)[_0x4cd9f5(0x284)])return _0x4ec3e6[_0x4cd9f5(0x258)]({'unitID':_0x3e48c1,'undoMutations':_0x52b493,'redoMutations':_0x20b5a8}),!![];return![];}},UpdateSheetsShapeDataMutation={'id':_0x31b92c(0x24c),'type':_univerjs_core['CommandType'][_0x31b92c(0x28e)],'handler':(_0x3dce0f,_0x406117)=>{const _0x23e1b5=_0x31b92c,{unitId:_0x2aa541,subUnitId:_0x5d422e,shapeType:_0x287fd5,shapeId:_0x492cd7,shapeData:_0x401af0}=_0x406117,_0x5c3201=_0x3dce0f[_0x23e1b5(0x282)](SheetsShapeService)[_0x23e1b5(0x251)](_0x2aa541,_0x5d422e,_0x492cd7);if(_0x5c3201){if(_0x287fd5!==void 0x0)_0x5c3201[_0x23e1b5(0x20a)](_0x287fd5);if(_0x401af0)_0x5c3201===null||_0x5c3201===void 0x0||_0x5c3201[_0x23e1b5(0x1f0)](_0x401af0,!![]);}return!![];}},SetShapeDrawingDataCommand={'type':_univerjs_core['CommandType'][_0x31b92c(0x216)],'id':_0x31b92c(0x270),'handler':(_0x5b6d0f,_0x5e54b3)=>{const _0x11f074=_0x31b92c;var _0x21d870,_0x7ae26c;const _0x8be021=(0x0,_univerjs_sheets[_0x11f074(0x212)])(_0x5b6d0f[_0x11f074(0x282)](_univerjs_core[_0x11f074(0x208)]),_0x5e54b3);if(!_0x8be021)return![];const _0x231546=_0x5b6d0f[_0x11f074(0x282)](_univerjs_sheets[_0x11f074(0x213)]),{unitId:_0x393127,subUnitId:_0x19cddc}=_0x8be021,_0x2d108a=_0x231546[_0x11f074(0x267)](_0x393127,_0x19cddc);if(!_0x2d108a)return![];const _0x51f26c=_0x5b6d0f['get'](SheetsShapeService),{shapeId:_0x2793e1,shapeType:_0x37c78c,shapeData:_0x1d6233,position:_0x46dcd7,width:_0x4cce30,height:_0x505d9d}=_0x5e54b3,_0x3dc66e=_0x51f26c[_0x11f074(0x251)](_0x393127,_0x19cddc,_0x2793e1);if(!_0x3dc66e)return![];const _0x24e568=_0x5b6d0f[_0x11f074(0x282)](_univerjs_core['ICommandService']),_0x3a6f23=_0x5b6d0f['get'](_univerjs_core[_0x11f074(0x26e)]),_0x225ec2=_0x5b6d0f['get'](_univerjs_sheets[_0x11f074(0x279)]),_0x1686c9=_0x5b6d0f[_0x11f074(0x282)](_univerjs_sheets_drawing[_0x11f074(0x295)]),_0x19eb9e={'unitId':_0x393127,'subUnitId':_0x19cddc,'shapeId':_0x2793e1,'shapeType':_0x37c78c,'shapeData':_0x1d6233},_0x5337c3=_0x3dc66e[_0x11f074(0x201)](),_0x121576=_0x3dc66e[_0x11f074(0x286)](),{x:_0x5b4ae4,y:_0x1fd06c}=_0x46dcd7,_0x3f781a={'from':_0x2d108a[_0x11f074(0x21e)](_0x5b4ae4,_0x1fd06c),'to':_0x2d108a[_0x11f074(0x21e)](_0x5b4ae4+_0x4cce30,_0x1fd06c+_0x505d9d)},_0xbbb532={'unitId':_0x393127,'subUnitId':_0x19cddc,'drawingId':_0x2793e1,'drawingType':_univerjs_core[_0x11f074(0x20d)][_0x11f074(0x23e)],'sheetTransform':_0x3f781a,'transform':{'left':_0x5b4ae4,'top':_0x1fd06c,'width':_0x4cce30,'height':_0x505d9d},'data':{'shapeType':_0x37c78c,'shapeData':_0x1d6233},'axisAlignSheetTransform':_0x3f781a,'allowTransform':!![]};(0x0,_univerjs_pro_engine_shape[_0x11f074(0x1e1)])(_0x37c78c)&&(_0xbbb532['data'][_0x11f074(0x27e)]=![],_0xbbb532[_0x11f074(0x239)]['rotateEnabled']=![],_0xbbb532['data'][_0x11f074(0x200)]=![],_0xbbb532[_0x11f074(0x239)][_0x11f074(0x232)]=![],_0xbbb532[_0x11f074(0x29b)][_0x11f074(0x2a0)]=![],_0xbbb532[_0x11f074(0x29b)][_0x11f074(0x200)]=![],_0xbbb532[_0x11f074(0x29b)][_0x11f074(0x232)]=![]);const {undo:_0x322ef0,redo:_0x3b1e64,objects:_0x1ec1cb}=_0x1686c9[_0x11f074(0x225)]([_0xbbb532]),_0x38a611=_0x225ec2[_0x11f074(0x290)]({'id':_univerjs_sheets_drawing[_0x11f074(0x22f)]['id'],'params':{'unitId':_0x393127,'drawings':[_0xbbb532]}}),_0x43c280=[...(_0x21d870=_0x38a611['preRedos'])!==null&&_0x21d870!==void 0x0?_0x21d870:[],{'id':_univerjs_sheets_drawing[_0x11f074(0x21c)]['id'],'params':{'unitId':_0x393127,'subUnitId':_0x19cddc,'op':_0x3b1e64,'objects':_0x1ec1cb,'type':_univerjs_sheets_drawing[_0x11f074(0x206)][_0x11f074(0x21d)]}},{'id':_univerjs_sheets_drawing['ClearSheetDrawingTransformerOperation']['id'],'params':[_0x393127]},..._0x38a611[_0x11f074(0x26a)],{'id':UpdateSheetsShapeDataMutation['id'],'params':_0x19eb9e}],_0x213b37=[...(_0x7ae26c=_0x38a611['preUndos'])!==null&&_0x7ae26c!==void 0x0?_0x7ae26c:[],{'id':_univerjs_sheets_drawing[_0x11f074(0x21c)]['id'],'params':{'unitId':_0x393127,'subUnitId':_0x19cddc,'op':_0x322ef0,'objects':_0x1ec1cb,'type':_univerjs_sheets_drawing[_0x11f074(0x206)][_0x11f074(0x21d)]}},{'id':_univerjs_sheets_drawing[_0x11f074(0x1e2)]['id'],'params':[_0x393127]},..._0x38a611['undos'],{'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x393127,'subUnitId':_0x19cddc,'shapeType':_0x5337c3,'shapeId':_0x2793e1,'shapeData':_0x121576}}];if((0x0,_univerjs_core[_0x11f074(0x298)])(_0x43c280,_0x24e568)['result'])return _0x3a6f23[_0x11f074(0x258)]({'unitID':_0x393127,'undoMutations':_0x213b37,'redoMutations':_0x43c280}),!![];return![];}},ToggleSheetsShapeFlipCommand={'type':_univerjs_core[_0x31b92c(0x20f)][_0x31b92c(0x216)],'id':'sheet.command.toggle-shape-flip','handler':(_0x5ce83d,_0x5a27b4)=>{const _0x4f3776=_0x31b92c;var _0x5c01ad,_0x181001;const _0x32c01f=(0x0,_univerjs_sheets[_0x4f3776(0x212)])(_0x5ce83d['get'](_univerjs_core[_0x4f3776(0x208)]),_0x5a27b4);if(!_0x32c01f)return![];const _0x5cb984=_0x5ce83d['get'](_univerjs_sheets[_0x4f3776(0x213)]),{unitId:_0x34bc9c,subUnitId:_0x45f5bc}=_0x32c01f,_0x2918ff=_0x5cb984['getSkeleton'](_0x34bc9c,_0x45f5bc);if(!_0x2918ff)return![];const _0x19c602=_0x5ce83d[_0x4f3776(0x282)](_univerjs_sheets_drawing[_0x4f3776(0x295)]),{shapeId:_0x50f801,flipH:_0x465a20,flipV:_0x3ed46e}=_0x5a27b4,_0x399824=_0x19c602[_0x4f3776(0x28f)]({'unitId':_0x34bc9c,'subUnitId':_0x45f5bc,'drawingId':_0x50f801});if(!_0x399824)return![];const _0xefb71a=_0x5ce83d['get'](SheetsShapeService)[_0x4f3776(0x251)](_0x34bc9c,_0x45f5bc,_0x50f801);if(!_0xefb71a)return![];const _0x23c95b=_0x5ce83d['get'](_univerjs_core[_0x4f3776(0x26b)]),_0x35593f=_0x5ce83d[_0x4f3776(0x282)](_univerjs_core[_0x4f3776(0x26e)]),_0x4cdeae=_0x5ce83d[_0x4f3776(0x282)](_univerjs_sheets[_0x4f3776(0x279)]),_0x2a7889={..._0x399824['transform']};if(_0x465a20!==void 0x0)_0x2a7889[_0x4f3776(0x245)]=!_0x2a7889[_0x4f3776(0x245)];if(_0x3ed46e!==void 0x0)_0x2a7889[_0x4f3776(0x1f7)]=!_0x2a7889[_0x4f3776(0x1f7)];const _0x19736c=(0x0,_univerjs_sheets_drawing[_0x4f3776(0x252)])(_0x2a7889,_0x2918ff),_0x2762d3=(0x0,_univerjs_sheets_drawing[_0x4f3776(0x268)])(_0x2a7889,_0x2918ff),_0x182800=_0xefb71a[_0x4f3776(0x201)](),_0x489e02=_0xefb71a[_0x4f3776(0x286)](),_0x1d493d={'unitId':_0x34bc9c,'subUnitId':_0x45f5bc,'drawingId':_0x50f801,'drawingType':_univerjs_core['DrawingTypeEnum'][_0x4f3776(0x23e)],'sheetTransform':_0x19736c,'transform':_0x2a7889,'data':{'shapeType':_0x182800,'shapeData':_0x489e02},'axisAlignSheetTransform':_0x2762d3,'allowTransform':!![]},{undo:_0x4d4b2f,redo:_0x4f86d7,objects:_0x322cdf}=_0x19c602[_0x4f3776(0x225)]([_0x1d493d]),_0x1fa8e2=_0x4cdeae['onCommandExecute']({'id':_univerjs_sheets_drawing[_0x4f3776(0x22f)]['id'],'params':{'unitId':_0x34bc9c,'drawings':[_0x1d493d]}}),_0x3788c4=[...(_0x5c01ad=_0x1fa8e2[_0x4f3776(0x27f)])!==null&&_0x5c01ad!==void 0x0?_0x5c01ad:[],{'id':_univerjs_sheets_drawing[_0x4f3776(0x21c)]['id'],'params':{'unitId':_0x34bc9c,'subUnitId':_0x45f5bc,'op':_0x4f86d7,'objects':_0x322cdf,'type':_univerjs_sheets_drawing[_0x4f3776(0x206)][_0x4f3776(0x21d)]}},{'id':_univerjs_sheets_drawing['ClearSheetDrawingTransformerOperation']['id'],'params':[_0x34bc9c]},..._0x1fa8e2[_0x4f3776(0x26a)]],_0x29d799=[...(_0x181001=_0x1fa8e2[_0x4f3776(0x24e)])!==null&&_0x181001!==void 0x0?_0x181001:[],{'id':_univerjs_sheets_drawing[_0x4f3776(0x21c)]['id'],'params':{'unitId':_0x34bc9c,'subUnitId':_0x45f5bc,'op':_0x4d4b2f,'objects':_0x322cdf,'type':_univerjs_sheets_drawing[_0x4f3776(0x206)][_0x4f3776(0x21d)]}},{'id':_univerjs_sheets_drawing[_0x4f3776(0x1e2)]['id'],'params':[_0x34bc9c]},..._0x1fa8e2[_0x4f3776(0x23a)]];if((0x0,_univerjs_pro_engine_shape[_0x4f3776(0x1e1)])(_0x182800)){const _0x50b6b7=_0xefb71a['getShapeRelation']();if(_0x50b6b7){const _0x5a6f6c={..._0x50b6b7};_0x5a6f6c[_0x4f3776(0x28c)]=void 0x0,_0x5a6f6c['to']=void 0x0,_0x3788c4[_0x4f3776(0x241)]({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x34bc9c,'subUnitId':_0x45f5bc,'shapeId':_0x50f801,'shapeType':_0x182800,'shapeData':{'relation':_0x5a6f6c}}}),_0x29d799[_0x4f3776(0x241)]({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x34bc9c,'subUnitId':_0x45f5bc,'shapeId':_0x50f801,'shapeType':_0x182800,'shapeData':{'relation':_0x50b6b7}}});}}if((0x0,_univerjs_core[_0x4f3776(0x298)])(_0x3788c4,_0x23c95b)[_0x4f3776(0x284)])return _0x35593f[_0x4f3776(0x258)]({'unitID':_0x34bc9c,'undoMutations':_0x29d799,'redoMutations':_0x3788c4}),!![];return![];}},SetSheetsShapeRotateCommand={'type':_univerjs_core[_0x31b92c(0x20f)][_0x31b92c(0x216)],'id':_0x31b92c(0x265),'handler':(_0x54683,_0x3780cc)=>{const _0x2fb284=_0x31b92c;var _0x1af444,_0x28b529;const _0x2354aa=(0x0,_univerjs_sheets[_0x2fb284(0x212)])(_0x54683[_0x2fb284(0x282)](_univerjs_core[_0x2fb284(0x208)]),_0x3780cc);if(!_0x2354aa)return![];const _0x56fc85=_0x54683[_0x2fb284(0x282)](_univerjs_sheets[_0x2fb284(0x213)]),{unitId:_0x14f48d,subUnitId:_0x45ca6d}=_0x2354aa,_0x559f07=_0x56fc85[_0x2fb284(0x24d)](_0x14f48d,_0x45ca6d);if(!_0x559f07)return![];const _0x47fb36=_0x54683[_0x2fb284(0x282)](_univerjs_sheets_drawing['ISheetDrawingService']),{shapeId:_0x565e7c,rotate:_0x8ae21a}=_0x3780cc,_0x578431=_0x47fb36['getDrawingByParam']({'unitId':_0x14f48d,'subUnitId':_0x45ca6d,'drawingId':_0x565e7c});if(!_0x578431)return![];const _0x5f5471=_0x54683[_0x2fb284(0x282)](SheetsShapeService)[_0x2fb284(0x251)](_0x14f48d,_0x45ca6d,_0x565e7c);if(!_0x5f5471)return![];const _0x13f538=_0x54683[_0x2fb284(0x282)](_univerjs_core[_0x2fb284(0x26b)]),_0x377cbc=_0x54683['get'](_univerjs_core['IUndoRedoService']),_0x4dbd2c=_0x54683[_0x2fb284(0x282)](_univerjs_sheets['SheetInterceptorService']),_0x2a07d5={..._0x578431[_0x2fb284(0x29b)]};if(_0x8ae21a!==void 0x0)_0x2a07d5['angle']=(_0x2a07d5[_0x2fb284(0x27b)]||0x0)+_0x8ae21a;const _0x19f41a=(0x0,_univerjs_sheets_drawing['transformToDrawingPosition'])(_0x2a07d5,_0x559f07),_0x5410aa=(0x0,_univerjs_sheets_drawing[_0x2fb284(0x268)])(_0x2a07d5,_0x559f07),_0x58410a=_0x5f5471[_0x2fb284(0x201)](),_0x23e8a5=_0x5f5471[_0x2fb284(0x286)](),_0x4d779a={'unitId':_0x14f48d,'subUnitId':_0x45ca6d,'drawingId':_0x565e7c,'drawingType':_univerjs_core[_0x2fb284(0x20d)][_0x2fb284(0x23e)],'sheetTransform':_0x19f41a,'transform':_0x2a07d5,'data':{'shapeType':_0x58410a,'shapeData':_0x23e8a5},'axisAlignSheetTransform':_0x5410aa,'allowTransform':!![]},{undo:_0x65a321,redo:_0x382462,objects:_0x4d483d}=_0x47fb36[_0x2fb284(0x225)]([_0x4d779a]),_0x35ec4a=_0x4dbd2c[_0x2fb284(0x290)]({'id':_univerjs_sheets_drawing[_0x2fb284(0x22f)]['id'],'params':{'unitId':_0x14f48d,'drawings':[_0x4d779a]}}),_0x154146=[...(_0x1af444=_0x35ec4a[_0x2fb284(0x27f)])!==null&&_0x1af444!==void 0x0?_0x1af444:[],{'id':_univerjs_sheets_drawing[_0x2fb284(0x21c)]['id'],'params':{'unitId':_0x14f48d,'subUnitId':_0x45ca6d,'op':_0x382462,'objects':_0x4d483d,'type':_univerjs_sheets_drawing[_0x2fb284(0x206)][_0x2fb284(0x21d)]}},{'id':_univerjs_sheets_drawing[_0x2fb284(0x1e2)]['id'],'params':[_0x14f48d]},..._0x35ec4a[_0x2fb284(0x26a)]],_0x26169d=[...(_0x28b529=_0x35ec4a[_0x2fb284(0x24e)])!==null&&_0x28b529!==void 0x0?_0x28b529:[],{'id':_univerjs_sheets_drawing[_0x2fb284(0x21c)]['id'],'params':{'unitId':_0x14f48d,'subUnitId':_0x45ca6d,'op':_0x65a321,'objects':_0x4d483d,'type':_univerjs_sheets_drawing[_0x2fb284(0x206)]['UPDATE']}},{'id':_univerjs_sheets_drawing['ClearSheetDrawingTransformerOperation']['id'],'params':[_0x14f48d]},..._0x35ec4a['undos']];if((0x0,_univerjs_core[_0x2fb284(0x298)])(_0x154146,_0x13f538)[_0x2fb284(0x284)])return _0x377cbc[_0x2fb284(0x258)]({'unitID':_0x14f48d,'undoMutations':_0x26169d,'redoMutations':_0x154146}),!![];return![];}},SetSheetsShapeTextVerticalToggleCommand={'type':_univerjs_core[_0x31b92c(0x20f)][_0x31b92c(0x216)],'id':_0x31b92c(0x249),'handler':(_0x22fb2d,_0x1cb575)=>{const _0x13cbf3=_0x31b92c;var _0x217219;const _0x2699f1=(0x0,_univerjs_sheets['getSheetCommandTarget'])(_0x22fb2d[_0x13cbf3(0x282)](_univerjs_core[_0x13cbf3(0x208)]),_0x1cb575);if(!_0x2699f1)return![];const {unitId:_0x47d536,subUnitId:_0x12dcfb}=_0x2699f1,{shapeId:_0x271cf4}=_0x1cb575,_0x5a81fe=_0x22fb2d[_0x13cbf3(0x282)](SheetsShapeService)[_0x13cbf3(0x251)](_0x47d536,_0x12dcfb,_0x271cf4);if(!_0x5a81fe)return![];const _0xc6bfcd=_0x5a81fe['getShapeTextData'](),_0x4c5be7=(_0x217219=_0xc6bfcd===null||_0xc6bfcd===void 0x0?void 0x0:_0xc6bfcd[_0x13cbf3(0x1ea)])!==null&&_0x217219!==void 0x0?_0x217219:!![],_0x62b396=!_0x4c5be7,_0x3fd2be=_0x22fb2d[_0x13cbf3(0x282)](_univerjs_core[_0x13cbf3(0x26b)]),_0x249ed7=_0x22fb2d[_0x13cbf3(0x282)](_univerjs_core[_0x13cbf3(0x26e)]),_0x11b52b={'unitId':_0x47d536,'subUnitId':_0x12dcfb,'shapeId':_0x271cf4,'shapeData':{'shapeText':{'isHorizontal':_0x62b396}}},_0x3d751e={'unitId':_0x47d536,'subUnitId':_0x12dcfb,'shapeId':_0x271cf4,'shapeData':{'shapeText':{'isHorizontal':_0x4c5be7}}},_0x285f7e=[{'id':UpdateSheetsShapeDataMutation['id'],'params':_0x11b52b}],_0x2e0469=[{'id':UpdateSheetsShapeDataMutation['id'],'params':_0x3d751e}];if((0x0,_univerjs_core['sequenceExecute'])(_0x285f7e,_0x3fd2be)[_0x13cbf3(0x284)])return _0x249ed7[_0x13cbf3(0x258)]({'unitID':_0x47d536,'undoMutations':_0x2e0469,'redoMutations':_0x285f7e}),!![];return![];}},UpdateConnectorRelationCommand={'type':_univerjs_core[_0x31b92c(0x20f)][_0x31b92c(0x216)],'id':'sheet.command.update-connector-relation','handler':(_0x326a4e,_0x3b91da)=>{const _0x1a79bd=_0x31b92c;var _0x5412ea,_0x1bb11f,_0x57bd02,_0x5df92f;const _0x3f12b2=(0x0,_univerjs_sheets[_0x1a79bd(0x212)])(_0x326a4e[_0x1a79bd(0x282)](_univerjs_core[_0x1a79bd(0x208)]),_0x3b91da);if(!_0x3f12b2)return![];const _0x28875f=_0x326a4e[_0x1a79bd(0x282)](_univerjs_sheets[_0x1a79bd(0x213)]),{unitId:_0x1125e5,subUnitId:_0x517eae}=_0x3f12b2,_0x385ba8=_0x28875f[_0x1a79bd(0x24d)](_0x1125e5,_0x517eae);if(!_0x385ba8)return![];const _0x50dccd=_0x326a4e['get'](_univerjs_sheets_drawing['ISheetDrawingService']),{connectorShapeId:_0x17f015,width:_0x228d28,height:_0x262f64,left:_0x161899,top:_0x3e0d81,flipX:_0x314c31,flipY:_0x104bf0,rotation:_0x28082a,oldAdjustValues:_0x3f7f31,newAdjustValues:_0x35b682,oldLineType:_0x12c954,newLineType:_0x2b7248,oldRelation:_0x26f4ce,newRelation:_0x4d882f}=_0x3b91da,_0x5759ce=_0x50dccd[_0x1a79bd(0x28f)]({'unitId':_0x1125e5,'subUnitId':_0x517eae,'drawingId':_0x17f015});if(!_0x5759ce)return![];const _0x2476b2=_0x326a4e[_0x1a79bd(0x282)](SheetsShapeService)[_0x1a79bd(0x251)](_0x1125e5,_0x517eae,_0x17f015);if(!_0x2476b2)return![];const _0x3e8b73=_0x326a4e[_0x1a79bd(0x282)](_univerjs_core[_0x1a79bd(0x26b)]),_0x1036c1=_0x326a4e[_0x1a79bd(0x282)](_univerjs_core[_0x1a79bd(0x26e)]),_0x356b31=_0x326a4e[_0x1a79bd(0x282)](_univerjs_sheets[_0x1a79bd(0x279)]),_0x57c42d={..._0x5759ce['transform'],'width':_0x228d28,'height':_0x262f64,'left':_0x161899,'top':_0x3e0d81,'flipX':_0x314c31,'flipY':_0x104bf0,'angle':(_0x5412ea=_0x28082a!==null&&_0x28082a!==void 0x0?_0x28082a:(_0x1bb11f=_0x5759ce['transform'])===null||_0x1bb11f===void 0x0?void 0x0:_0x1bb11f['angle'])!==null&&_0x5412ea!==void 0x0?_0x5412ea:0x0},_0x52d104=(0x0,_univerjs_sheets_drawing[_0x1a79bd(0x252)])(_0x57c42d,_0x385ba8),_0x2fd34b=(0x0,_univerjs_sheets_drawing[_0x1a79bd(0x268)])(_0x57c42d,_0x385ba8),_0x3176d4=_0x2476b2[_0x1a79bd(0x201)](),_0x554647=_0x2476b2['getShapeData'](),_0x14d898={'unitId':_0x1125e5,'subUnitId':_0x517eae,'drawingId':_0x17f015,'drawingType':_univerjs_core[_0x1a79bd(0x20d)][_0x1a79bd(0x23e)],'sheetTransform':_0x52d104,'transform':_0x57c42d,'data':{'shapeType':_0x2b7248||_0x12c954||_0x3176d4,'shapeData':{..._0x554647,'adjustValues':_0x35b682||_0x3f7f31||(_0x554647===null||_0x554647===void 0x0?void 0x0:_0x554647[_0x1a79bd(0x224)]),'relation':_0x4d882f||_0x26f4ce||(_0x554647===null||_0x554647===void 0x0?void 0x0:_0x554647[_0x1a79bd(0x220)])}},'axisAlignSheetTransform':_0x2fd34b,'allowTransform':!![]},{undo:_0x5b2643,redo:_0x262daf,objects:_0x58b8ea}=_0x50dccd[_0x1a79bd(0x225)]([_0x14d898]),_0x5af9a7=_0x356b31[_0x1a79bd(0x290)]({'id':_univerjs_sheets_drawing['SetSheetDrawingCommand']['id'],'params':{'unitId':_0x1125e5,'drawings':[_0x14d898]}}),_0xc0afcd=[...(_0x57bd02=_0x5af9a7['preRedos'])!==null&&_0x57bd02!==void 0x0?_0x57bd02:[],{'id':_univerjs_sheets_drawing['SetDrawingApplyMutation']['id'],'params':{'unitId':_0x1125e5,'subUnitId':_0x517eae,'op':_0x262daf,'objects':_0x58b8ea,'type':_univerjs_sheets_drawing['DrawingApplyType'][_0x1a79bd(0x21d)]}},{'id':_univerjs_sheets_drawing[_0x1a79bd(0x1e2)]['id'],'params':[_0x1125e5]},..._0x5af9a7['redos'],{'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x1125e5,'subUnitId':_0x517eae,'shapeId':_0x17f015,'shapeType':_0x2b7248,'shapeData':{'adjustValues':_0x35b682,'relation':_0x4d882f}}}],_0x38d342=[...(_0x5df92f=_0x5af9a7[_0x1a79bd(0x24e)])!==null&&_0x5df92f!==void 0x0?_0x5df92f:[],{'id':_univerjs_sheets_drawing['SetDrawingApplyMutation']['id'],'params':{'unitId':_0x1125e5,'subUnitId':_0x517eae,'op':_0x5b2643,'objects':_0x58b8ea,'type':_univerjs_sheets_drawing['DrawingApplyType'][_0x1a79bd(0x21d)]}},{'id':_univerjs_sheets_drawing[_0x1a79bd(0x1e2)]['id'],'params':[_0x1125e5]},..._0x5af9a7['undos'],{'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x1125e5,'subUnitId':_0x517eae,'shapeId':_0x17f015,'shapeType':_0x3176d4,'shapeData':{..._0x554647,'adjustValues':_0x3f7f31||(_0x554647===null||_0x554647===void 0x0?void 0x0:_0x554647[_0x1a79bd(0x224)]),'relation':_0x26f4ce||(_0x554647===null||_0x554647===void 0x0?void 0x0:_0x554647[_0x1a79bd(0x220)])}}}];if((0x0,_univerjs_core[_0x1a79bd(0x298)])(_0xc0afcd,_0x3e8b73)[_0x1a79bd(0x284)])return _0x1036c1[_0x1a79bd(0x258)]({'unitID':_0x1125e5,'undoMutations':_0x38d342,'redoMutations':_0xc0afcd}),!![];return![];}},UpdateLineShapeResizeCommand={'type':_univerjs_core[_0x31b92c(0x20f)][_0x31b92c(0x216)],'id':_0x31b92c(0x1e0),'handler':(_0x1b098a,_0x2b0b6d)=>{const _0x224c8a=_0x31b92c;var _0x3aa4b1,_0x148861;const _0x894e60=(0x0,_univerjs_sheets[_0x224c8a(0x212)])(_0x1b098a[_0x224c8a(0x282)](_univerjs_core[_0x224c8a(0x208)]),_0x2b0b6d);if(!_0x894e60)return![];const _0x5b099a=_0x1b098a['get'](_univerjs_sheets[_0x224c8a(0x213)]),{unitId:_0xcaa39e,subUnitId:_0x31a9ba}=_0x894e60,_0x160da6=_0x5b099a['getSkeleton'](_0xcaa39e,_0x31a9ba);if(!_0x160da6)return![];const _0x305573=_0x1b098a[_0x224c8a(0x282)](_univerjs_sheets_drawing[_0x224c8a(0x295)]),{shapeId:_0x280091,width:_0x589b5e,height:_0x319f61,left:_0x5bc443,top:_0x47c792,flipX:_0xd2d5d9,flipY:_0x3f6e8c,angle:_0x1087d6,oldAdjustValues:_0x32d80f,newAdjustValues:_0xa1a6f0,oldLineType:_0x4666ee,newLineType:_0x28cf9d}=_0x2b0b6d,_0x46feba=_0x305573['getDrawingByParam']({'unitId':_0xcaa39e,'subUnitId':_0x31a9ba,'drawingId':_0x280091});if(!_0x46feba)return![];const _0xfeec4e=_0x1b098a[_0x224c8a(0x282)](SheetsShapeService)[_0x224c8a(0x251)](_0xcaa39e,_0x31a9ba,_0x280091);if(!_0xfeec4e)return![];const _0x505934=_0x1b098a[_0x224c8a(0x282)](_univerjs_core['ICommandService']),_0x395080=_0x1b098a['get'](_univerjs_core[_0x224c8a(0x26e)]),_0x4b3036=_0x1b098a[_0x224c8a(0x282)](_univerjs_sheets[_0x224c8a(0x279)]),_0x3dedc2={..._0x46feba[_0x224c8a(0x29b)],'width':_0x589b5e,'height':_0x319f61,'left':_0x5bc443,'top':_0x47c792,'flipX':_0xd2d5d9,'flipY':_0x3f6e8c,'angle':_0x1087d6},_0x366958=(0x0,_univerjs_sheets_drawing['transformToDrawingPosition'])(_0x3dedc2,_0x160da6),_0x154ee2=(0x0,_univerjs_sheets_drawing[_0x224c8a(0x268)])(_0x3dedc2,_0x160da6),_0x376e28=_0xfeec4e[_0x224c8a(0x201)](),_0x141ec4=_0xfeec4e[_0x224c8a(0x286)](),_0x37fce0={'unitId':_0xcaa39e,'subUnitId':_0x31a9ba,'drawingId':_0x280091,'drawingType':_univerjs_core['DrawingTypeEnum'][_0x224c8a(0x23e)],'sheetTransform':_0x366958,'transform':_0x3dedc2,'data':{'shapeType':_0x28cf9d||_0x4666ee||_0x376e28,'shapeData':{..._0x141ec4,'adjustValues':_0xa1a6f0||_0x32d80f||(_0x141ec4===null||_0x141ec4===void 0x0?void 0x0:_0x141ec4[_0x224c8a(0x224)])}},'axisAlignSheetTransform':_0x154ee2,'allowTransform':!![]},{undo:_0x5d6c73,redo:_0x423738,objects:_0x13650a}=_0x305573['getBatchUpdateOp']([_0x37fce0]),_0x32440f=_0x4b3036['onCommandExecute']({'id':_univerjs_sheets_drawing[_0x224c8a(0x22f)]['id'],'params':{'unitId':_0xcaa39e,'drawings':[_0x37fce0]}}),_0xa751a9=[...(_0x3aa4b1=_0x32440f[_0x224c8a(0x27f)])!==null&&_0x3aa4b1!==void 0x0?_0x3aa4b1:[],{'id':_univerjs_sheets_drawing[_0x224c8a(0x21c)]['id'],'params':{'unitId':_0xcaa39e,'subUnitId':_0x31a9ba,'op':_0x423738,'objects':_0x13650a,'type':_univerjs_sheets_drawing[_0x224c8a(0x206)][_0x224c8a(0x21d)]}},{'id':_univerjs_sheets_drawing[_0x224c8a(0x1e2)]['id'],'params':[_0xcaa39e]},..._0x32440f[_0x224c8a(0x26a)],{'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0xcaa39e,'subUnitId':_0x31a9ba,'shapeId':_0x280091,'shapeType':_0x28cf9d,'shapeData':{'adjustValues':_0xa1a6f0}}}],_0x8a5889=[...(_0x148861=_0x32440f[_0x224c8a(0x24e)])!==null&&_0x148861!==void 0x0?_0x148861:[],{'id':_univerjs_sheets_drawing[_0x224c8a(0x21c)]['id'],'params':{'unitId':_0xcaa39e,'subUnitId':_0x31a9ba,'op':_0x5d6c73,'objects':_0x13650a,'type':_univerjs_sheets_drawing[_0x224c8a(0x206)][_0x224c8a(0x21d)]}},{'id':_univerjs_sheets_drawing['ClearSheetDrawingTransformerOperation']['id'],'params':[_0xcaa39e]},..._0x32440f[_0x224c8a(0x23a)],{'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0xcaa39e,'subUnitId':_0x31a9ba,'shapeId':_0x280091,'shapeType':_0x376e28,'shapeData':{..._0x141ec4,'adjustValues':_0x32d80f||(_0x141ec4===null||_0x141ec4===void 0x0?void 0x0:_0x141ec4['adjustValues'])}}}];if((0x0,_univerjs_core['sequenceExecute'])(_0xa751a9,_0x505934)['result'])return _0x395080[_0x224c8a(0x258)]({'unitID':_0xcaa39e,'undoMutations':_0x8a5889,'redoMutations':_0xa751a9}),!![];return![];}},UpdateSheetsShapeTypeMutation={'id':_0x31b92c(0x233),'type':_univerjs_core[_0x31b92c(0x20f)][_0x31b92c(0x28e)],'handler':(_0x4434e5,_0x2ad724)=>{const _0x1564cb=_0x31b92c,{unitId:_0x415413,subUnitId:_0x43ff42,shapeType:_0x25a9f1,shapeId:_0x5c4065,shapeData:_0x3149c2}=_0x2ad724,_0x1ae64f=_0x4434e5[_0x1564cb(0x282)](SheetsShapeService)[_0x1564cb(0x251)](_0x415413,_0x43ff42,_0x5c4065);if(_0x1ae64f){_0x1ae64f[_0x1564cb(0x20a)](_0x25a9f1);if(_0x3149c2)_0x1ae64f===null||_0x1ae64f===void 0x0||_0x1ae64f[_0x1564cb(0x1f0)](_0x3149c2);}return!![];}},UpdateSheetsShapeTypeCommand={'id':'sheet.command.update-shape-type','type':_univerjs_core[_0x31b92c(0x20f)][_0x31b92c(0x216)],'handler':(_0x113659,_0x128f5c)=>{const _0x311bae=_0x31b92c;if(!_0x128f5c)return![];const _0x43e07a=_0x113659[_0x311bae(0x282)](_univerjs_core[_0x311bae(0x26b)]),_0x2d5428=_0x113659[_0x311bae(0x282)](SheetsShapeService),_0x1ca60a=_0x113659['get'](_univerjs_core[_0x311bae(0x26e)]),_0x4707a8=[],_0x5db9c9=[],{unitId:_0x499101,subUnitId:_0x3d3d64,shapeId:_0x4a536f,shapeType:_0x4854d8,shapeData:_0x4d67a1}=_0x128f5c,_0x529f2c=_0x2d5428[_0x311bae(0x251)](_0x499101,_0x3d3d64,_0x4a536f);if(_0x529f2c){const _0x4acdcb=_0x529f2c['getShapeType'](),_0x14a810=Object['assign']({},_0x529f2c['getShapeData']()),_0x1a0237={'unitId':_0x499101,'subUnitId':_0x3d3d64,'shapeId':_0x4a536f,'shapeType':_0x4854d8,'shapeData':_0x4d67a1},_0x7aee7f={'unitId':_0x499101,'subUnitId':_0x3d3d64,'shapeId':_0x4a536f,'shapeType':_0x4acdcb,'shapeData':_0x14a810};_0x4707a8['push']({'id':UpdateSheetsShapeTypeMutation['id'],'params':_0x1a0237}),_0x5db9c9['push']({'id':UpdateSheetsShapeTypeMutation['id'],'params':_0x7aee7f});if(_0x4707a8[_0x311bae(0x20e)](_0x433ff5=>_0x43e07a[_0x311bae(0x235)](_0x433ff5['id'],_0x433ff5[_0x311bae(0x281)])))_0x1ca60a[_0x311bae(0x258)]({'unitID':_0x499101,'redoMutations':[..._0x4707a8],'undoMutations':[..._0x5db9c9]});return!![];}return![];}};var name=_0x31b92c(0x1e8),version=_0x31b92c(0x211);const SHEETS_SHAPE_PLUGIN_CONFIG_KEY=_0x31b92c(0x274),configSymbol=Symbol(SHEETS_SHAPE_PLUGIN_CONFIG_KEY),defaultPluginConfig={};let SheetsShapeController=class SheetsShapeController extends _univerjs_core['Disposable']{constructor(_0x107fd6,_0x59be7c,_0x42ef9c,_0x3134fe,_0x444014){const _0x3f2efb=_0x31b92c;super(),this['_commandService']=_0x107fd6,this[_0x3f2efb(0x28b)]=_0x59be7c,this[_0x3f2efb(0x20c)]=_0x42ef9c,this[_0x3f2efb(0x1dd)]=_0x3134fe,this[_0x3f2efb(0x287)]=_0x444014,this[_0x3f2efb(0x234)](),this['_initCommandInterceptor']();}[_0x31b92c(0x234)](){const _0x30d4ef=_0x31b92c;[InsertShapeCommand,SetShapeDrawingDataCommand,ToggleSheetsShapeFlipCommand,SetSheetsShapeRotateCommand,SetSheetsShapeTextVerticalToggleCommand,UpdateConnectorRelationCommand,UpdateLineShapeResizeCommand,InsertSheetsShapeMutation,RemoveSheetsShapeMutation,UpdateSheetsShapeTypeMutation,UpdateSheetsShapeDataMutation][_0x30d4ef(0x22e)](_0x357af5=>this[_0x30d4ef(0x237)](this[_0x30d4ef(0x253)][_0x30d4ef(0x202)](_0x357af5)));}['_initCommandInterceptor'](){const _0x964973=_0x31b92c;this[_0x964973(0x237)](this['_sheetInterceptorService'][_0x964973(0x23f)]({'getMutations':_0x1766e5=>{const _0x13b714=_0x964973;if(_0x1766e5['id']===_univerjs_sheets_drawing['RemoveSheetDrawingCommand']['id']){const {drawings:_0x1abfbe}=_0x1766e5['params'],_0x377572=_0x1abfbe[_0x13b714(0x263)](_0x208a4d=>_0x208a4d[_0x13b714(0x1ed)]===_univerjs_core[_0x13b714(0x20d)]['DRAWING_SHAPE']);if(_0x377572[_0x13b714(0x29e)]===0x0)return{'preRedos':[],'redos':[],'preUndos':[],'undos':[]};const _0x412244=[],_0x4c1eb2=[];return _0x377572[_0x13b714(0x22e)](_0x55e307=>{const _0x4099cd=_0x13b714,{unitId:_0x265ad2,subUnitId:_0x25f111,drawingId:_0x3d732e}=_0x55e307,_0x359b8f=this['_sheetsShapeService'][_0x4099cd(0x251)](_0x265ad2,_0x25f111,_0x3d732e);if(!_0x359b8f)throw new TypeError(_0x4099cd(0x240)+_0x359b8f);_0x412244[_0x4099cd(0x241)]({'id':RemoveSheetsShapeMutation['id'],'params':{'unitId':_0x265ad2,'subUnitId':_0x25f111,'shapeId':_0x3d732e}}),_0x4c1eb2[_0x4099cd(0x241)]({'id':InsertSheetsShapeMutation['id'],'params':{'unitId':_0x265ad2,'subUnitId':_0x25f111,'shapeId':_0x3d732e,'shapeType':_0x359b8f[_0x4099cd(0x201)](),'shapeData':_0x359b8f[_0x4099cd(0x286)]()}});const _0x58b312=this[_0x4099cd(0x1dd)]['getBasicShapeRelation'](_0x265ad2,_0x25f111,_0x3d732e);if(_0x58b312)for(const _0x30628a of _0x58b312){const _0x54ef7b=_0x30628a[_0x4099cd(0x297)],_0x241be6=_0x30628a[_0x4099cd(0x244)],_0x15d72e=_0x241be6?{'from':void 0x0}:{'to':void 0x0},_0x3e7a0c=_0x241be6?{'from':{'shapeId':_0x30628a[_0x4099cd(0x22d)],'cxnIndex':_0x30628a[_0x4099cd(0x248)]}}:{'to':{'shapeId':_0x30628a[_0x4099cd(0x22d)],'cxnIndex':_0x30628a['cxnIndex']}};_0x412244[_0x4099cd(0x241)]({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x265ad2,'subUnitId':_0x25f111,'shapeId':_0x54ef7b,'shapeData':{'relation':_0x15d72e}}}),_0x4c1eb2[_0x4099cd(0x241)]({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x265ad2,'subUnitId':_0x25f111,'shapeId':_0x54ef7b,'shapeData':{'relation':_0x3e7a0c}}});}}),{'preRedos':_0x412244,'redos':[],'preUndos':[],'undos':_0x4c1eb2};}if(_0x1766e5['id']===_univerjs_sheets_drawing[_0x13b714(0x22f)]['id']){const {drawings:_0x43b60f}=_0x1766e5[_0x13b714(0x281)],_0x3dab4e=_0x43b60f[_0x13b714(0x263)](_0x5c9e45=>_0x5c9e45[_0x13b714(0x1ed)]===_univerjs_core[_0x13b714(0x20d)][_0x13b714(0x23e)]);if(_0x3dab4e[_0x13b714(0x29e)]===0x0)return{'preRedos':[],'redos':[],'preUndos':[],'undos':[]};const _0x1ca8d0=[],_0x30f035=[];for(const _0x29c9ef of _0x3dab4e){const {unitId:_0x33131f,subUnitId:_0x954d81,drawingId:_0x2abd46,transform:_0x29b9eb}=_0x29c9ef;if(!_0x33131f||!_0x954d81||!_0x2abd46||!_0x29b9eb)continue;const _0x110f92=this['_sheetsShapeService'][_0x13b714(0x251)](_0x33131f,_0x954d81,_0x2abd46);if(!_0x110f92)throw new TypeError(_0x13b714(0x240)+_0x110f92);if((0x0,_univerjs_pro_engine_shape['isConnectorShape'])(_0x110f92[_0x13b714(0x201)]())){const _0x3068ee=this[_0x13b714(0x1dd)]['getLineShapeRelation'](_0x33131f,_0x954d81,_0x2abd46),_0xe6bf51={'from':void 0x0,'to':void 0x0};_0x3068ee&&(_0x1ca8d0[_0x13b714(0x241)]({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x33131f,'subUnitId':_0x954d81,'shapeId':_0x2abd46,'shapeData':{'relation':_0xe6bf51}}}),_0x30f035['push']({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x33131f,'subUnitId':_0x954d81,'shapeId':_0x2abd46,'shapeData':{'relation':_0x3068ee}}}));}else{const _0xf9d328=this[_0x13b714(0x1dd)][_0x13b714(0x262)](_0x33131f,_0x954d81,_0x2abd46);if(_0xf9d328&&_0xf9d328[_0x13b714(0x29e)]>0x0)for(const _0x46b38b of _0xf9d328){const _0x1c407d=_0x46b38b[_0x13b714(0x297)],_0x24af04=_0x46b38b[_0x13b714(0x244)],_0x1e71a7=this[_0x13b714(0x1dd)]['getShapeModel'](_0x33131f,_0x954d81,_0x1c407d);if(!_0x1e71a7)continue;const _0x4db4cf=_0x1e71a7[_0x13b714(0x26d)](),_0xc0cf34=_0x1e71a7[_0x13b714(0x276)]();if(_0x4db4cf&&_0xc0cf34)this['_addLineRerouteUpdates'](_0x33131f,_0x954d81,_0x1c407d,_0x1e71a7,_0x4db4cf,_0xc0cf34,_0x1ca8d0,_0x30f035,_0x2abd46,_0x29b9eb);else this[_0x13b714(0x25b)](_0x33131f,_0x954d81,_0x1c407d,_0x1e71a7,_0x24af04?_0x4db4cf:_0xc0cf34,_0x24af04,_0x1ca8d0,_0x30f035,_0x2abd46,_0x29b9eb);}}}return{'preRedos':[],'redos':_0x1ca8d0,'preUndos':_0x30f035,'undos':[]};}return{'preRedos':[],'redos':[],'preUndos':[],'undos':[]};}}));}[_0x31b92c(0x280)](_0x5b0e62,_0x179cc1,_0x3c1fbe,_0x10e911,_0x1ae4ef){const _0x4131b9=_0x31b92c;if(!_0x179cc1||!_0x3c1fbe)return null;const {shapeId:_0x3a2eca,cxnIndex:_0x258506}=_0x5b0e62,_0x4cb794=this[_0x4131b9(0x1dd)]['getShapeModel'](_0x179cc1,_0x3c1fbe,_0x3a2eca);if(!_0x4cb794)return null;const _0x1ecb3d=this[_0x4131b9(0x287)][_0x4131b9(0x28f)]({'unitId':_0x179cc1,'subUnitId':_0x3c1fbe,'drawingId':_0x3a2eca});if(!(_0x1ecb3d===null||_0x1ecb3d===void 0x0?void 0x0:_0x1ecb3d['transform']))return null;let {left:left=0x0,top:top=0x0,width:width=0x0,height:height=0x0,flipX:flipX=![],flipY:flipY=![],angle:_0x1ef292}=_0x1ecb3d[_0x4131b9(0x29b)];if(_0x1ae4ef&&_0x10e911===_0x3a2eca){var _0x403fad,_0x40b243,_0x531ff9,_0x1fb8ae,_0x4ca30a,_0x2ace27,_0x417aa9;left=(_0x403fad=_0x1ae4ef['left'])!==null&&_0x403fad!==void 0x0?_0x403fad:left,top=(_0x40b243=_0x1ae4ef['top'])!==null&&_0x40b243!==void 0x0?_0x40b243:top,width=(_0x531ff9=_0x1ae4ef[_0x4131b9(0x25a)])!==null&&_0x531ff9!==void 0x0?_0x531ff9:width,height=(_0x1fb8ae=_0x1ae4ef['height'])!==null&&_0x1fb8ae!==void 0x0?_0x1fb8ae:height,flipX=(_0x4ca30a=_0x1ae4ef[_0x4131b9(0x245)])!==null&&_0x4ca30a!==void 0x0?_0x4ca30a:flipX,flipY=(_0x2ace27=_0x1ae4ef['flipY'])!==null&&_0x2ace27!==void 0x0?_0x2ace27:flipY,_0x1ef292=(_0x417aa9=_0x1ae4ef['angle'])!==null&&_0x417aa9!==void 0x0?_0x417aa9:_0x1ef292;}_0x4cb794['updateContext']({'width':width,'height':height});const _0x5592e4=_0x4cb794['getConnectionSiteList']()[_0x4131b9(0x218)](_0x3f9504=>_0x3f9504['index']===_0x258506);if(!_0x5592e4)return null;let _0x4699d1=flipX?width-_0x5592e4['x']:_0x5592e4['x'],_0x36fc43=flipY?height-_0x5592e4['y']:_0x5592e4['y'];if(_0x1ef292!==0x0&&_0x1ef292!==void 0x0&&_0x1ef292!==null){const _0x4a2f2b=_0x1ef292*Math['PI']/0xb4,_0x19d84c=Math[_0x4131b9(0x2a3)](_0x4a2f2b),_0x533384=Math[_0x4131b9(0x271)](_0x4a2f2b),_0x58b9d5=width/0x2,_0x4cd499=height/0x2,_0x4a6dc5=_0x4699d1-_0x58b9d5,_0x1c96bf=_0x36fc43-_0x4cd499;_0x4699d1=_0x58b9d5+_0x4a6dc5*_0x19d84c-_0x1c96bf*_0x533384,_0x36fc43=_0x4cd499+_0x4a6dc5*_0x533384+_0x1c96bf*_0x19d84c;}_0x4699d1+=left,_0x36fc43+=top;let _0x11185f=_0x5592e4[_0x4131b9(0x1fb)]/0xea60;if(flipX)_0x11185f=0xb4-_0x11185f;if(flipY)_0x11185f=-_0x11185f;_0x11185f+=_0x1ef292||0x0,_0x11185f=(_0x11185f%0x168+0x168)%0x168;const _0x1d13f2=(0x0,_univerjs_pro_engine_shape[_0x4131b9(0x247)])({'left':left,'top':top,'width':width,'height':height},_0x1ef292||0x0);return{'point':{'x':_0x4699d1,'y':_0x36fc43},'angle':_0x11185f,'bounds':_0x1d13f2};}[_0x31b92c(0x22c)](_0x5b47a2,_0x41cd76,_0x4b6af2,_0x416b2a,_0x332573,_0x1bd6ee,_0x53ba6e,_0x258853,_0x5816c7,_0x3d8ceb){const _0x42524d=_0x31b92c,_0x4b1b67=this[_0x42524d(0x20c)][_0x42524d(0x24d)](_0x5b47a2,_0x41cd76);if(!_0x4b1b67)return;const _0x23c9f4=_0x416b2a[_0x42524d(0x1f3)](),_0x5b81fb=_0x416b2a[_0x42524d(0x21b)](),_0x56d24b={},_0x57f155={};_0x5b81fb[_0x42524d(0x22e)](_0x485ace=>{const _0x4af473=_0x42524d,_0x27720c=_0x416b2a[_0x4af473(0x24a)](_0x485ace);_0x57f155[_0x485ace]=_0x27720c!==null&&_0x27720c!==void 0x0?_0x27720c:0x0;});const _0x198624=this[_0x42524d(0x280)](_0x332573,_0x5b47a2,_0x41cd76,_0x5816c7,_0x3d8ceb),_0x336054=this[_0x42524d(0x280)](_0x1bd6ee,_0x5b47a2,_0x41cd76,_0x5816c7,_0x3d8ceb);if(_0x198624&&_0x336054){const _0x1a753b=_0x416b2a[_0x42524d(0x201)](),_0x55c354=(0x0,_univerjs_pro_engine_shape[_0x42524d(0x1ef)])(_0x198624,_0x336054,_0x1a753b);let _0x5c36d7=_0x1a753b;if(_0x55c354){const _0x21088c=(0x0,_univerjs_pro_engine_shape[_0x42524d(0x21a)])(_0x55c354,_0x416b2a[_0x42524d(0x201)]()),_0x23f1b6=this[_0x42524d(0x287)]['getDrawingData'](_0x5b47a2,_0x41cd76);if(_0x23f1b6&&_0x23f1b6[_0x4b6af2]){const _0xa24c73=_0x23f1b6[_0x4b6af2];_0x5c36d7=_0x21088c[_0x42524d(0x1ec)];for(const [_0x4680c4,_0x57ee22]of Object[_0x42524d(0x27d)](_0x21088c[_0x42524d(0x224)]))_0x56d24b[_0x4680c4]=_0x57ee22;const _0x5c033e={..._0xa24c73[_0x42524d(0x29b)],'width':_0x21088c[_0x42524d(0x1f5)]['width'],'height':_0x21088c[_0x42524d(0x1f5)][_0x42524d(0x254)],'left':_0x21088c[_0x42524d(0x1f5)]['left'],'top':_0x21088c[_0x42524d(0x1f5)][_0x42524d(0x23d)],'flipX':_0x21088c[_0x42524d(0x1f5)][_0x42524d(0x245)],'flipY':_0x21088c[_0x42524d(0x1f5)]['flipY'],'angle':_0x21088c[_0x42524d(0x209)]},_0x1f01ef=(0x0,_univerjs_sheets_drawing['transformToDrawingPosition'])(_0x5c033e,_0x4b1b67),_0x206203=(0x0,_univerjs_sheets_drawing['transformToAxisAlignPosition'])(_0x5c033e,_0x4b1b67),_0x42388b={'unitId':_0x5b47a2,'subUnitId':_0x41cd76,'drawingType':_univerjs_core[_0x42524d(0x20d)]['DRAWING_SHAPE'],'drawingId':_0x4b6af2,'transform':_0x5c033e,'sheetTransform':_0x1f01ef,'axisAlignSheetTransform':_0x206203},{unitId:_0x24248f,subUnitId:_0x34a7e4,undo:_0x266e37,redo:_0x405f7b,objects:_0x5ac307}=this['_drawingManagerService'][_0x42524d(0x225)]([_0x42388b]);_0x53ba6e['push']({'id':_univerjs_sheets_drawing[_0x42524d(0x21c)]['id'],'params':{'unitId':_0x24248f,'subUnitId':_0x34a7e4,'op':_0x405f7b,'objects':_0x5ac307,'type':_univerjs_sheets_drawing[_0x42524d(0x206)]['UPDATE']}}),_0x258853[_0x42524d(0x241)]({'id':_univerjs_sheets_drawing[_0x42524d(0x21c)]['id'],'params':{'unitId':_0x24248f,'subUnitId':_0x34a7e4,'op':_0x266e37,'objects':_0x5ac307,'type':_univerjs_sheets_drawing[_0x42524d(0x206)][_0x42524d(0x21d)]}});}_0x416b2a[_0x42524d(0x1e9)]();}_0x53ba6e[_0x42524d(0x241)]({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x5b47a2,'subUnitId':_0x41cd76,'shapeId':_0x4b6af2,'shapeType':_0x5c36d7,'shapeData':{'adjustValues':_0x56d24b,'relation':_0x23c9f4}}}),_0x258853[_0x42524d(0x241)]({'id':UpdateSheetsShapeDataMutation['id'],'params':{'unitId':_0x5b47a2,'subUnitId':_0x41cd76,'shapeId':_0x4b6af2,'shapeType':_0x1a753b,'shapeData':{'adjustValues':_0x57f155,'relation':_0x23c9f4}}});}}['_addLineFollowShapeUpdates'](_0x497872,_0x17ae22,_0x5c9438,_0xa247be,_0x42a60e,_0x333c5c,_0x50e445,_0x1f9938,_0x55ed29,_0x4e5879){const _0x476f1f=_0x31b92c;var _0x76ccea;if(!_0x42a60e)return;const _0x53b728=this[_0x476f1f(0x20c)][_0x476f1f(0x24d)](_0x497872,_0x17ae22);if(!_0x53b728)return;const _0x518026=(_0x76ccea=this['_drawingManagerService'][_0x476f1f(0x28f)]({'unitId':_0x497872,'subUnitId':_0x17ae22,'drawingId':_0x55ed29}))===null||_0x76ccea===void 0x0?void 0x0:_0x76ccea['transform'];if(!_0x518026)return;const _0x23cf35=_0x518026[_0x476f1f(0x217)]!==_0x4e5879[_0x476f1f(0x217)]||_0x518026['top']!==_0x4e5879[_0x476f1f(0x23d)],_0x3cf1f8=_0x518026['width']!==_0x4e5879[_0x476f1f(0x25a)]||_0x518026[_0x476f1f(0x254)]!==_0x4e5879[_0x476f1f(0x254)],_0x131b0a=_0x518026['flipX']!==_0x4e5879['flipX']||_0x518026[_0x476f1f(0x1f7)]!==_0x4e5879['flipY'],_0x2cfe6c=_0x518026[_0x476f1f(0x27b)]!==_0x4e5879[_0x476f1f(0x27b)];if(_0x23cf35&&!_0x3cf1f8&&!_0x131b0a&&!_0x2cfe6c){var _0x50d0fb,_0x53c15e,_0x514682,_0x4752fc;const _0x3558b8=((_0x50d0fb=_0x4e5879[_0x476f1f(0x217)])!==null&&_0x50d0fb!==void 0x0?_0x50d0fb:0x0)-((_0x53c15e=_0x518026['left'])!==null&&_0x53c15e!==void 0x0?_0x53c15e:0x0),_0x1aa2f6=((_0x514682=_0x4e5879['top'])!==null&&_0x514682!==void 0x0?_0x514682:0x0)-((_0x4752fc=_0x518026[_0x476f1f(0x23d)])!==null&&_0x4752fc!==void 0x0?_0x4752fc:0x0),_0x456861=this[_0x476f1f(0x287)][_0x476f1f(0x1fd)](_0x497872,_0x17ae22);if(_0x456861&&_0x456861[_0x5c9438]){var _0xd82dc7,_0x5c6dd6,_0x5ce8b6,_0x48656a;const _0x28dc92=_0x456861[_0x5c9438],_0x420784={..._0x28dc92[_0x476f1f(0x29b)],'left':((_0xd82dc7=(_0x5c6dd6=_0x28dc92[_0x476f1f(0x29b)])===null||_0x5c6dd6===void 0x0?void 0x0:_0x5c6dd6['left'])!==null&&_0xd82dc7!==void 0x0?_0xd82dc7:0x0)+_0x3558b8,'top':((_0x5ce8b6=(_0x48656a=_0x28dc92[_0x476f1f(0x29b)])===null||_0x48656a===void 0x0?void 0x0:_0x48656a[_0x476f1f(0x23d)])!==null&&_0x5ce8b6!==void 0x0?_0x5ce8b6:0x0)+_0x1aa2f6},_0x2a8060=(0x0,_univerjs_sheets_drawing['transformToDrawingPosition'])(_0x420784,_0x53b728),_0x33f701=(0x0,_univerjs_sheets_drawing[_0x476f1f(0x268)])(_0x420784,_0x53b728),_0x113f87={'unitId':_0x497872,'subUnitId':_0x17ae22,'drawingType':_univerjs_core[_0x476f1f(0x20d)]['DRAWING_SHAPE'],'drawingId':_0x5c9438,'transform':_0x420784,'sheetTransform':_0x2a8060,'axisAlignSheetTransform':_0x33f701},{unitId:_0x3c134b,subUnitId:_0x616b,undo:_0x2f0dd2,redo:_0x5da9f4,objects:_0x416cbd}=this[_0x476f1f(0x287)][_0x476f1f(0x225)]([_0x113f87]);_0x50e445['push']({'id':_univerjs_sheets_drawing[_0x476f1f(0x21c)]['id'],'params':{'unitId':_0x3c134b,'subUnitId':_0x616b,'op':_0x5da9f4,'objects':_0x416cbd,'type':_univerjs_sheets_drawing['DrawingApplyType'][_0x476f1f(0x21d)]}}),_0x1f9938['push']({'id':_univerjs_sheets_drawing[_0x476f1f(0x21c)]['id'],'params':{'unitId':_0x3c134b,'subUnitId':_0x616b,'op':_0x2f0dd2,'objects':_0x416cbd,'type':_univerjs_sheets_drawing[_0x476f1f(0x206)]['UPDATE']}});}}else{const _0x3bfdfd=_0xa247be['getStartConnectInfo'](),_0x3723b3=_0xa247be[_0x476f1f(0x276)]();this[_0x476f1f(0x22c)](_0x497872,_0x17ae22,_0x5c9438,_0xa247be,_0x3bfdfd,_0x3723b3,_0x50e445,_0x1f9938,_0x55ed29,_0x4e5879);}}};function _0x2a88(){const _0x3d06f8=['length','UpdateLineShapeResizeCommand','rotateEnabled','keys','removeShape','cos','SetSheetsShapeTextVerticalToggleCommand','_sheetsShapeService','position','hasShape','sheet.command.update-line-shape-resize','isConnectorShape','ClearSheetDrawingTransformerOperation','getBasicShapeType','getCellWithCoordByIndex','merge','DEFAULT_SHAPE_HEIGHT','IResourceManagerService','@univerjs-pro/sheets-shape','removeLinePoints','isHorizontal','decorate','lineType','drawingType','1570216QHMoBD','routeConnectorLineShape','setShapeData','constructor','getOwnPropertyDescriptor','getShapeRelation','toJSON','worldRect','parse','flipY','toPrimitive','IDrawingManagerService','UpdateSheetsShapeTypeMutation','ang','Injector','getDrawingData','109910ETTssE','default','resizeEnabled','getShapeType','registerCommand','dispose','_configService','prototype','DrawingApplyType','toStringTag','IUniverInstanceService','rotation','setShapeType','INSERT','_sheetSkeletonService','DrawingTypeEnum','every','CommandType','UNIVER_SHEET','0.22.1-insiders.20260515-225d350','getSheetCommandTarget','SheetSkeletonService','_shapeModelManagerMap','UniverLicensePlugin','COMMAND','left','find','DEFAULT_SHAPE_WIDTH','computeConnectorRouteLayout','getAdjustNames','SetDrawingApplyMutation','UPDATE','getCellIndexAndOffsetByPosition','clear','relation','_disposed','range','has','adjustValues','getBatchUpdateOp','getLineShapeRelation','RemoveSheetsShapeMutation','Inject','pluginName','call','DependentOn','_addLineRerouteUpdates','shapeId','forEach','SetSheetDrawingCommand','UpdateConnectorRelationCommand','Module','borderEnabled','sheet.mutation.update-shape-type','_initCommands','syncExecuteCommand','symbol','disposeWithMe','setConfig','data','undos','Plugin','Disposable','top','DRAWING_SHAPE','interceptCommand','Fail\x20to\x20get\x20shape\x20model,\x20get:\x20','push','_ensureShapeModelManager','69936aENGnN','isFrom','flipX','UniverInstanceType','getBasicShapeRotateBound','cxnIndex','sheet.command.set-shape-text-vertical-toggle','getAdjustValueByName','119VlmhDM','sheet.mutation.update-shape-data','getSkeleton','preUndos','insertShape','_linesIds','getShapeModel','transformToDrawingPosition','_commandService','height','SHEET_SHAPE_PLUGIN','getBatchAddOp','REMOVE','pushUndoRedo','1345645mOTkav','width','_addLineFollowShapeUpdates','1119YzVEhx','startX','set','object','13473306tVLxcY','registerPluginResource','getBasicShapeRelation','filter','InsertShapeCommand','sheet.command.set-shape-rotate','InsertSheetDrawingCommand','ensureSkeleton','transformToAxisAlignPosition','4lllvLt','redos','ICommandService','version','getStartConnectInfo','IUndoRedoService','touchDependencies','sheet.command.set-shape-drawing-data','sin','string','_config','sheets-shape.config','_deserializeShapeForUnit','getEndConnectInfo','65982klNcyV','function','SheetInterceptorService','delete','angle','_serializeShapeForUnit','entries','fill','preRedos','_getConnectPointInfo','params','get','_initSnapshot','result','_injector','getShapeData','_drawingManagerService','9alhqEw','_shapes','1382gAXwei','_sheetInterceptorService','from','defineProperty','MUTATION','getDrawingByParam','onCommandExecute','shapeData','sheet.command.insert-shape','fromJSON','UniverSheetsShapePlugin','ISheetDrawingService','addShape','lineShapeId','sequenceExecute','UpdateSheetsShapeDataMutation','type','transform','_groupIds','SetSheetsShapeRotateCommand'];_0x2a88=function(){return _0x3d06f8;};return _0x2a88();}SheetsShapeController=__decorate([__decorateParam(0x0,_univerjs_core[_0x31b92c(0x26b)]),__decorateParam(0x1,(0x0,_univerjs_core[_0x31b92c(0x228)])(_univerjs_sheets['SheetInterceptorService'])),__decorateParam(0x2,(0x0,_univerjs_core[_0x31b92c(0x228)])(_univerjs_sheets['SheetSkeletonService'])),__decorateParam(0x3,(0x0,_univerjs_core[_0x31b92c(0x228)])(SheetsShapeService)),__decorateParam(0x4,(0x0,_univerjs_core[_0x31b92c(0x228)])(_univerjs_drawing[_0x31b92c(0x1f9)]))],SheetsShapeController);let UniverSheetsShapePlugin=class UniverSheetsShapePlugin extends _univerjs_core[_0x31b92c(0x23b)]{constructor(_0x2f1d88=defaultPluginConfig,_0x28e92f,_0x244eab,_0x5b3206){const _0x9cb833=_0x31b92c;super(),this[_0x9cb833(0x273)]=_0x2f1d88,this['_injector']=_0x28e92f,this[_0x9cb833(0x253)]=_0x244eab,this[_0x9cb833(0x204)]=_0x5b3206;const {..._0x29c499}=(0x0,_univerjs_core[_0x9cb833(0x1e5)])({},defaultPluginConfig,this[_0x9cb833(0x273)]);this[_0x9cb833(0x204)][_0x9cb833(0x238)](SHEETS_SHAPE_PLUGIN_CONFIG_KEY,_0x29c499);}['onStarting'](){const _0x14ba9e=_0x31b92c,_0x25f17e=this[_0x14ba9e(0x285)];[[SheetShapeModelManager],[SheetsShapeService],[SheetsShapeController]]['forEach'](_0x257119=>_0x25f17e['add'](_0x257119)),(0x0,_univerjs_core[_0x14ba9e(0x26f)])(_0x25f17e,[[SheetsShapeService],[SheetsShapeController]]);}};_defineProperty(UniverSheetsShapePlugin,_0x31b92c(0x29a),_univerjs_core[_0x31b92c(0x246)][_0x31b92c(0x210)]),_defineProperty(UniverSheetsShapePlugin,_0x31b92c(0x229),_0x31b92c(0x255)),_defineProperty(UniverSheetsShapePlugin,'packageName',name),_defineProperty(UniverSheetsShapePlugin,_0x31b92c(0x26c),version),UniverSheetsShapePlugin=__decorate([(0x0,_univerjs_core[_0x31b92c(0x22b)])(_univerjs_pro_license[_0x31b92c(0x215)]),__decorateParam(0x1,(0x0,_univerjs_core[_0x31b92c(0x228)])(_univerjs_core[_0x31b92c(0x1fc)])),__decorateParam(0x2,_univerjs_core[_0x31b92c(0x26b)]),__decorateParam(0x3,_univerjs_core['IConfigService'])],UniverSheetsShapePlugin),exports[_0x31b92c(0x1e6)]=DEFAULT_SHAPE_HEIGHT,exports[_0x31b92c(0x219)]=DEFAULT_SHAPE_WIDTH,exports[_0x31b92c(0x264)]=InsertShapeCommand,exports['InsertSheetsShapeMutation']=InsertSheetsShapeMutation,exports[_0x31b92c(0x227)]=RemoveSheetsShapeMutation,exports['SetShapeDrawingDataCommand']=SetShapeDrawingDataCommand,exports[_0x31b92c(0x29d)]=SetSheetsShapeRotateCommand,exports[_0x31b92c(0x2a4)]=SetSheetsShapeTextVerticalToggleCommand,Object[_0x31b92c(0x28d)](exports,'SheetsShapeService',{'enumerable':!![],'get':function(){return SheetsShapeService;}}),exports['ToggleSheetsShapeFlipCommand']=ToggleSheetsShapeFlipCommand,Object[_0x31b92c(0x28d)](exports,_0x31b92c(0x294),{'enumerable':!![],'get':function(){return UniverSheetsShapePlugin;}}),exports[_0x31b92c(0x230)]=UpdateConnectorRelationCommand,exports[_0x31b92c(0x29f)]=UpdateLineShapeResizeCommand,exports[_0x31b92c(0x299)]=UpdateSheetsShapeDataMutation,exports['UpdateSheetsShapeTypeCommand']=UpdateSheetsShapeTypeCommand,exports[_0x31b92c(0x1fa)]=UpdateSheetsShapeTypeMutation;