@univerjs-pro/sheets-shape 1.0.0-rc.0 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,203 @@
1
+ import { ShapeArrowSizeEnum, ShapeArrowTypeEnum, ShapeFillEnum, ShapeGradientTypeEnum, ShapeLineCapEnum, ShapeLineDashEnum, ShapeLineJoinEnum, ShapeLineTypeEnum, ShapeTypeEnum } from '@univerjs-pro/engine-shape';
2
+ /**
3
+ * @ignore
4
+ */
5
+ export interface IFSheetsShapeEnumMixin {
6
+ /**
7
+ * Represents the type of the shape. {@link ShapeTypeEnum}
8
+ * @description This enum defines almost all Excel supported shape types, including basic shapes, block arrows, flowchart shapes, callouts, stars and banners, symbols, and lines.
9
+ *
10
+ * @example
11
+ * ```ts
12
+ * const fWorkbook = univerAPI.getActiveWorkbook();
13
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
14
+ * if (!fWorksheet) return;
15
+ *
16
+ * // Create a rectangle shape.
17
+ * const shapeInfo = fWorksheet.newShape()
18
+ * .setShapeType(univerAPI.Enum.ShapeTypeEnum.Diamond)
19
+ * .setPosition(1, 1, 0, 0)
20
+ * .build();
21
+ * await fWorksheet.insertShape(shapeInfo);
22
+ * ```
23
+ */
24
+ ShapeTypeEnum: typeof ShapeTypeEnum;
25
+ /**
26
+ * Represents the fill type of the shape. {@link ShapeFillEnum}
27
+ * The possible values are: NoFill, SolidFil, GradientFill, PatternFill, PictureFill.
28
+ *
29
+ * @example
30
+ * ```ts
31
+ * const fWorkbook = univerAPI.getActiveWorkbook();
32
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
33
+ * if (!fWorksheet) return;
34
+ *
35
+ * // Create a rectangle shape with solid fill.
36
+ * const shapeInfo = fWorksheet.newShape()
37
+ * .setShapeType(univerAPI.Enum.ShapeTypeEnum.Rect)
38
+ * .setShapeSolidFill('#ff0000')
39
+ * .setPosition(1, 1, 0, 0)
40
+ * .build();
41
+ * await fWorksheet.insertShape(shapeInfo);
42
+ * ```
43
+ */
44
+ ShapeFillEnum: typeof ShapeFillEnum;
45
+ /**
46
+ * Represents the gradient type of the shape fill. {@link ShapeGradientTypeEnum}
47
+ * The possible values are: Linear, Radial, Angular, Diamond.
48
+ *
49
+ * @example
50
+ * ```ts
51
+ * const fWorkbook = univerAPI.getActiveWorkbook();
52
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
53
+ * if (!fWorksheet) return;
54
+ *
55
+ * // Create a rectangle shape with linear gradient fill.
56
+ * const shapeInfo = fWorksheet.newShape()
57
+ * .setShapeType(univerAPI.Enum.ShapeTypeEnum.Rect)
58
+ * .setShapeGradientFill(univerAPI.Enum.ShapeGradientTypeEnum.Linear, [{
59
+ * position: 0,
60
+ * color: '#ff0000'
61
+ * }, {
62
+ * position: 0.5,
63
+ * color: '#00ff00'
64
+ * }, {
65
+ * position: 1,
66
+ * color: '#0000ff'
67
+ * }], 90 )
68
+ * .setPosition(1, 1, 0, 0)
69
+ * .build();
70
+ * await fWorksheet.insertShape(shapeInfo);
71
+ * ```
72
+ */
73
+ ShapeGradientTypeEnum: typeof ShapeGradientTypeEnum;
74
+ /**
75
+ * Represents the line fill type of the shape stroke. {@link ShapeLineTypeEnum}
76
+ * The possible values are: NoLine, SolidLine, GradientLine.
77
+ *
78
+ * @example
79
+ * ```ts
80
+ * const fWorkbook = univerAPI.getActiveWorkbook();
81
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
82
+ * if (!fWorksheet) return;
83
+ *
84
+ * // Create a rectangle shape with solid line stroke type.
85
+ * const shapeInfo = fWorksheet.newShape()
86
+ * .setShapeType(univerAPI.Enum.ShapeTypeEnum.Rect)
87
+ * .setStrokeLineType(univerAPI.Enum.ShapeLineTypeEnum.SolidLine)
88
+ * .setStrokeColor('#000000')
89
+ * .setPosition(1, 1, 0, 0)
90
+ * .build();
91
+ * await fWorksheet.insertShape(shapeInfo);
92
+ * ```
93
+ */
94
+ ShapeLineTypeEnum: typeof ShapeLineTypeEnum;
95
+ /**
96
+ * Represents the line dash type of the shape stroke. {@link ShapeLineDashEnum}
97
+ * The possible values are: Solid, RoundDot, SquareDot, Dash, DashDot, LongDash, LongDashDot, LongDashDotDot.
98
+ *
99
+ * @example
100
+ * ```ts
101
+ * const fWorkbook = univerAPI.getActiveWorkbook();
102
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
103
+ * if (!fWorksheet) return;
104
+ *
105
+ * // Create a rectangle shape with dashed stroke.
106
+ * const shapeInfo = fWorksheet.newShape()
107
+ * .setShapeType(univerAPI.Enum.ShapeTypeEnum.Rect)
108
+ * .setStrokeLineDashType(univerAPI.Enum.ShapeLineDashEnum.Dash)
109
+ * .setPosition(1, 1, 0, 0)
110
+ * .build();
111
+ * await fWorksheet.insertShape(shapeInfo);
112
+ * ```
113
+ */
114
+ ShapeLineDashEnum: typeof ShapeLineDashEnum;
115
+ /**
116
+ * Represents the line cap type of the shape stroke. {@link ShapeLineCapEnum}
117
+ * The possible values are: Flat, Round, Square.
118
+ *
119
+ * @example
120
+ * ```ts
121
+ * const fWorkbook = univerAPI.getActiveWorkbook();
122
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
123
+ * if (!fWorksheet) return;
124
+ *
125
+ * // Create a rectangle shape with round line cap.
126
+ * const shapeInfo = fWorksheet.newShape()
127
+ * .setShapeType(univerAPI.Enum.ShapeTypeEnum.Rect)
128
+ * .setStrokeLineCapType(univerAPI.Enum.ShapeLineCapEnum.Round)
129
+ * .setPosition(1, 1, 0, 0)
130
+ * .build();
131
+ * await fWorksheet.insertShape(shapeInfo);
132
+ * ```
133
+ */
134
+ ShapeLineCapEnum: typeof ShapeLineCapEnum;
135
+ /**
136
+ * Represents the line join type of the shape stroke. {@link ShapeLineJoinEnum}
137
+ * The possible values are: Miter, Round, Bevel.
138
+ *
139
+ * @example
140
+ * ```ts
141
+ * const fWorkbook = univerAPI.getActiveWorkbook();
142
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
143
+ * if (!fWorksheet) return;
144
+ *
145
+ * // Create a rectangle shape with round line join.
146
+ * const shapeInfo = fWorksheet.newShape()
147
+ * .setShapeType(univerAPI.Enum.ShapeTypeEnum.Rect)
148
+ * .setStrokeLineJoinType(univerAPI.Enum.ShapeLineJoinEnum.Round)
149
+ * .setPosition(1, 1, 0, 0)
150
+ * .build();
151
+ * await fWorksheet.insertShape(shapeInfo);
152
+ * ```
153
+ */
154
+ ShapeLineJoinEnum: typeof ShapeLineJoinEnum;
155
+ /**
156
+ * Represents the arrow type of connector line shape. {@link ShapeArrowTypeEnum}
157
+ * The possible values are: None, Arrow, OpenArrow, DiamondArrow, StealthArrow, OvalArrow.
158
+ *
159
+ * @example
160
+ * ```ts
161
+ * const fWorkbook = univerAPI.getActiveWorkbook();
162
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
163
+ * if (!fWorksheet) return;
164
+ *
165
+ * // Create a line shape with arrow type.
166
+ * const shapeInfo = fWorksheet.newConnector()
167
+ * .setShapeType(univerAPI.Enum.ShapeTypeEnum.StraightConnector1)
168
+ * .setPosition(1, 1, 0, 0)
169
+ * .setStartArrowType(univerAPI.Enum.ShapeArrowTypeEnum.Arrow)
170
+ * .setStrokeWidth(3)
171
+ * .build();
172
+ * await fWorksheet.insertShape(shapeInfo);
173
+ * ```
174
+ */
175
+ ShapeArrowTypeEnum: typeof ShapeArrowTypeEnum;
176
+ /**
177
+ * Represents the arrow size of connector line shape. {@link ShapeArrowSizeEnum}
178
+ * The possible values are:Small, Medium, Large.
179
+ *
180
+ * @example
181
+ * ```ts
182
+ * const fWorkbook = univerAPI.getActiveWorkbook();
183
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
184
+ * if (!fWorksheet) return;
185
+ * // Create a line shape with arrow size.
186
+ * const shapeInfo = fWorksheet.newConnector()
187
+ * .setShapeType(univerAPI.Enum.ShapeTypeEnum.BentConnector3)
188
+ * .setPosition(1, 1, 0, 0)
189
+ * .setStartArrowSize(univerAPI.Enum.ShapeArrowSizeEnum.Medium)
190
+ * .setStrokeWidth(3)
191
+ * .build();
192
+ * await fWorksheet.insertShape(shapeInfo);
193
+ * ```
194
+ */
195
+ ShapeArrowSizeEnum: typeof ShapeArrowSizeEnum;
196
+ }
197
+ /**
198
+ * @ignore
199
+ */
200
+ declare module '@univerjs/core/facade' {
201
+ interface FEnum extends IFSheetsShapeEnumMixin {
202
+ }
203
+ }
@@ -0,0 +1,32 @@
1
+ import type { IShapeData, IShapeJSONData, IShapeRelation, IShapeRelationItem, ShapeTypeEnum } from '@univerjs-pro/engine-shape';
2
+ import { ShapeModel } from '@univerjs-pro/engine-shape';
3
+ import { Disposable } from '@univerjs/core';
4
+ export type IShapeRelationItemWithLineId = IShapeRelationItem & {
5
+ lineShapeId: string;
6
+ isFrom: boolean;
7
+ };
8
+ export declare class SheetShapeModelManager extends Disposable {
9
+ _shapes: Map<string, ShapeModel>;
10
+ _linesIds: Set<string>;
11
+ _groupIds: Set<string>;
12
+ constructor();
13
+ addShape(shapeType: ShapeTypeEnum, id: string, shapeData?: IShapeData): ShapeModel;
14
+ /**
15
+ * Get all shape relations associated with a basic shape
16
+ * @param {string} id The basic shape ID
17
+ * @returns {IShapeRelationItemWithLineId[]} List of shape relation items associated with the basic shape
18
+ */
19
+ getBasicShapeRelation(id: string): IShapeRelationItemWithLineId[];
20
+ /**
21
+ * Get the line shape relation info
22
+ * @param lineShapeId The line shape ID
23
+ * @returns {IShapeRelationItem | undefined} The shape relation info for the given line shape ID
24
+ */
25
+ getLineShapeRelation(lineShapeId: string): IShapeRelation | undefined;
26
+ getShapeType(id: string): ShapeTypeEnum | undefined;
27
+ hasShape(id: string): boolean;
28
+ removeShape(id: string): void;
29
+ toJSON(): IShapeJSONData[];
30
+ fromJSON(data: IShapeJSONData[]): void;
31
+ dispose(): void;
32
+ }
package/lib/umd/facade.js CHANGED
@@ -1 +1 @@
1
- (function(_0x2dd469,_0x4a2911){const _0x1f5c84=_0x5369,_0x1fc7ab=_0x2dd469();while(!![]){try{const _0x1fa948=-parseInt(_0x1f5c84(0xfd))/0x1*(parseInt(_0x1f5c84(0x127))/0x2)+-parseInt(_0x1f5c84(0x105))/0x3*(parseInt(_0x1f5c84(0xea))/0x4)+-parseInt(_0x1f5c84(0x10a))/0x5+parseInt(_0x1f5c84(0x107))/0x6+-parseInt(_0x1f5c84(0x10f))/0x7*(-parseInt(_0x1f5c84(0x10d))/0x8)+parseInt(_0x1f5c84(0x115))/0x9+parseInt(_0x1f5c84(0xfb))/0xa;if(_0x1fa948===_0x4a2911)break;else _0x1fc7ab['push'](_0x1fc7ab['shift']());}catch(_0x10c67b){_0x1fc7ab['push'](_0x1fc7ab['shift']());}}}(_0x4a98,0x4749e),function(_0x2f472b,_0x3251a2){const _0x41080c=_0x5369;typeof exports==_0x41080c(0xfa)&&typeof module<'u'?_0x3251a2(exports,require('@univerjs-pro/engine-shape'),require('@univerjs-pro/engine-shape/facade'),require('@univerjs/core'),require('@univerjs/sheets/facade'),require('@univerjs/sheets-drawing')):typeof define==_0x41080c(0x12b)&&define[_0x41080c(0xf2)]?define([_0x41080c(0x12e),'@univerjs-pro/engine-shape',_0x41080c(0xf7),_0x41080c(0x12f),_0x41080c(0x12c),_0x41080c(0x12a)],_0x3251a2):(_0x2f472b=typeof globalThis<'u'?globalThis:_0x2f472b||self,_0x3251a2(_0x2f472b[_0x41080c(0x109)]={},_0x2f472b['UniverProEngineShape'],_0x2f472b[_0x41080c(0x10c)],_0x2f472b[_0x41080c(0x111)],_0x2f472b[_0x41080c(0x12d)],_0x2f472b[_0x41080c(0x113)]));}(this,function(_0x3cbb4e,_0x144dd7,_0x415700,_0xa77a5f,_0x1b5dee,_0x4830cb){const _0x2702a7=_0x5369;Object[_0x2702a7(0xf5)](_0x3cbb4e,Symbol[_0x2702a7(0xfc)],{'value':'Module'});function _0x36cdfc(_0x4ce4b5,_0x11e8bc){return function(_0x512179,_0x4246eb){_0x11e8bc(_0x512179,_0x4246eb,_0x4ce4b5);};}function _0x4f54ff(_0x55a007,_0x1fbbfc,_0x51a89c,_0x1d0891){const _0x484e35=_0x2702a7;var _0x5a05ff=arguments[_0x484e35(0x117)],_0x44140c=_0x5a05ff<0x3?_0x1fbbfc:_0x1d0891===null?_0x1d0891=Object['getOwnPropertyDescriptor'](_0x1fbbfc,_0x51a89c):_0x1d0891,_0x4b62ae;if(typeof Reflect=='object'&&typeof Reflect[_0x484e35(0x11e)]==_0x484e35(0x12b))_0x44140c=Reflect[_0x484e35(0x11e)](_0x55a007,_0x1fbbfc,_0x51a89c,_0x1d0891);else{for(var _0x2d02c5=_0x55a007['length']-0x1;_0x2d02c5>=0x0;_0x2d02c5--)(_0x4b62ae=_0x55a007[_0x2d02c5])&&(_0x44140c=(_0x5a05ff<0x3?_0x4b62ae(_0x44140c):_0x5a05ff>0x3?_0x4b62ae(_0x1fbbfc,_0x51a89c,_0x44140c):_0x4b62ae(_0x1fbbfc,_0x51a89c))||_0x44140c);}return _0x5a05ff>0x3&&_0x44140c&&Object[_0x484e35(0xf5)](_0x1fbbfc,_0x51a89c,_0x44140c),_0x44140c;}let _0x1a34d7=class extends _0x415700[_0x2702a7(0x108)]{constructor(_0x7f7807,_0x7c13ad,_0x50291f,_0x2523a1,_0x3c2916){const _0x22b32f=_0x2702a7;super(_0x7f7807,_0x7c13ad,_0x50291f,_0x2523a1),this[_0x22b32f(0x118)]=_0x3c2916;}['getPlacement'](){const _0x4548cf=_0x2702a7;let _0x13b0c9=this['_sheetDrawingService'][_0x4548cf(0x119)]({'unitId':this[_0x4548cf(0xed)][_0x4548cf(0x122)],'subUnitId':this[_0x4548cf(0xed)][_0x4548cf(0x11a)],'drawingId':this[_0x4548cf(0xed)][_0x4548cf(0x116)]});return _0x13b0c9?(0x0,_0x4830cb[_0x4548cf(0xf4)])(_0x13b0c9):null;}[_0x2702a7(0xf9)](_0x56bf7d){const _0x2e8f66=_0x2702a7;return this[_0x2e8f66(0x102)][_0x2e8f66(0x114)](_0x4830cb[_0x2e8f66(0x11c)]['id'],{'unitId':this[_0x2e8f66(0xed)][_0x2e8f66(0x122)],'subUnitId':this[_0x2e8f66(0xed)]['subUnitId'],'drawings':[{'drawingId':this[_0x2e8f66(0xed)][_0x2e8f66(0x116)],'placement':_0x56bf7d}]});}[_0x2702a7(0xf6)](_0x4fd38c,_0x594603,_0x3b560b,_0xc34090){const _0x42a289=_0x2702a7;var _0x2c3131,_0x36f385;let _0x3184ce=this['_sheetDrawingService']['getDrawingByParam']({'unitId':this[_0x42a289(0xed)][_0x42a289(0x122)],'subUnitId':this[_0x42a289(0xed)]['subUnitId'],'drawingId':this[_0x42a289(0xed)][_0x42a289(0x116)]});if(!_0x3184ce)return console[_0x42a289(0x125)]('[Sheet\x20Shape\x20Facade]:\x20Shape\x20\x22'+this[_0x42a289(0xed)][_0x42a289(0x116)]+_0x42a289(0x10e)),this;let _0x4758ab=(_0x2c3131=_0x3184ce[_0x42a289(0x104)])==null?void 0x0:_0x2c3131[_0x42a289(0x10b)],_0x50a41f=(_0x36f385=_0x3184ce[_0x42a289(0x104)])==null?void 0x0:_0x36f385[_0x42a289(0x110)];return _0x4758ab==null||_0x50a41f==null?(console[_0x42a289(0x125)]('[Sheet\x20Shape\x20Facade]:\x20Shape\x20\x22'+this[_0x42a289(0xed)][_0x42a289(0x116)]+_0x42a289(0x11f)),this):(this['_commandService']['syncExecuteCommand'](_0x4830cb[_0x42a289(0x11c)]['id'],{'unitId':this['_shapeRef'][_0x42a289(0x122)],'subUnitId':this['_shapeRef'][_0x42a289(0x11a)],'drawings':[{'drawingId':this[_0x42a289(0xed)][_0x42a289(0x116)],'placement':{'kind':_0x4830cb[_0x42a289(0x126)][_0x42a289(0x128)],'from':{'row':_0x4fd38c,'column':_0x594603,'rowOffset':_0x3b560b,'columnOffset':_0xc34090},'width':_0x4758ab,'height':_0x50a41f}}]}),this);}};_0x1a34d7=_0x4f54ff([_0x36cdfc(0x2,_0x144dd7['IShapeHostAdapterRegistry']),_0x36cdfc(0x3,_0xa77a5f[_0x2702a7(0xff)]),_0x36cdfc(0x4,_0x4830cb['ISheetDrawingService'])],_0x1a34d7);var _0x16f01d=class extends _0x1b5dee['FWorksheet']{['insertShape'](_0x18a865){const _0x8e02a5=_0x2702a7;let _0x21ffb6=this[_0x8e02a5(0x120)]();if(!_0x21ffb6)return null;try{let _0x26ecfa=_0x21ffb6[_0x8e02a5(0xeb)](this[_0x8e02a5(0x106)](),_0x18a865);return _0x26ecfa?this[_0x8e02a5(0x112)](_0x26ecfa):(console[_0x8e02a5(0x125)](_0x8e02a5(0xf0)),null);}catch(_0x4977a3){return console[_0x8e02a5(0x125)](_0x8e02a5(0xf0),_0x4977a3),null;}}['getShape'](_0x3f3b9d){const _0x4b0f41=_0x2702a7;let _0x57dc3d=this['_getShapeAdapter']();if(!_0x57dc3d)return null;try{let _0x55ad16={...this[_0x4b0f41(0x106)](),'shapeId':_0x3f3b9d},_0x18ccc4=_0x57dc3d[_0x4b0f41(0x130)](_0x55ad16);return _0x18ccc4?this[_0x4b0f41(0x112)](_0x18ccc4):(console[_0x4b0f41(0x125)]('[Sheet\x20Shape\x20Facade]:\x20Shape\x20\x22'+_0x3f3b9d+_0x4b0f41(0x10e)),null);}catch(_0x355fb1){return console[_0x4b0f41(0x125)](_0x4b0f41(0x103)+_0x3f3b9d+'\x22.',_0x355fb1),null;}}[_0x2702a7(0x129)](){const _0x33a119=_0x2702a7;let _0xf47e60=this['_getShapeAdapter']();if(!_0xf47e60)return[];try{return _0xf47e60[_0x33a119(0xf8)](this['_getShapeScope']())['map'](_0x9ead64=>this[_0x33a119(0x112)](_0x9ead64));}catch(_0x4bfa78){return console['warn'](_0x33a119(0xf1),_0x4bfa78),[];}}['_getShapeScope'](){const _0x41712c=_0x2702a7;return{'hostType':_0xa77a5f[_0x41712c(0x100)][_0x41712c(0x121)],'unitId':this[_0x41712c(0xec)]()[_0x41712c(0xf3)](),'subUnitId':this[_0x41712c(0xfe)]()};}[_0x2702a7(0x120)](){const _0x28d5fe=_0x2702a7;return this[_0x28d5fe(0x11d)][_0x28d5fe(0xe9)](_0x144dd7[_0x28d5fe(0x101)])[_0x28d5fe(0xe9)](_0xa77a5f[_0x28d5fe(0x100)][_0x28d5fe(0x121)]);}[_0x2702a7(0x112)](_0x2b51a6){const _0x26e723=_0x2702a7;let {unitId:_0x31c80c,subUnitId:_0x1bf4cb,shapeId:_0x34d9ec}=_0x2b51a6,_0x2a5195={'unitId':_0x31c80c,'subUnitId':_0x1bf4cb,'shapeId':_0x34d9ec,'hostType':_0xa77a5f['UniverInstanceType'][_0x26e723(0x121)]};return(0x0,_0x144dd7[_0x26e723(0x124)])(_0x2b51a6['shapeType'])?this[_0x26e723(0x11d)][_0x26e723(0x123)](_0x415700['FConnectorShape'],_0x2a5195,this[_0x26e723(0x11d)]):this['_injector'][_0x26e723(0x123)](_0x1a34d7,_0x2a5195,this[_0x26e723(0x11d)]);}};_0x1b5dee[_0x2702a7(0xee)][_0x2702a7(0xef)](_0x16f01d),Object[_0x2702a7(0xf5)](_0x3cbb4e,_0x2702a7(0x11b),{'enumerable':!0x0,'get':function(){return _0x1a34d7;}});}));function _0x5369(_0x12b592,_0x52833f){_0x12b592=_0x12b592-0xe9;const _0x4a98d8=_0x4a98();let _0x536985=_0x4a98d8[_0x12b592];return _0x536985;}function _0x4a98(){const _0x49c135=['exports','@univerjs/core','getShape','get','44jRlWiv','createShape','getWorkbook','_shapeRef','FWorksheet','extend','[Sheet\x20Shape\x20Facade]:\x20Failed\x20to\x20insert\x20Shape.','[Sheet\x20Shape\x20Facade]:\x20Failed\x20to\x20list\x20Shapes.','amd','getUnitId','getSheetDrawingPlacement','defineProperty','setPosition','@univerjs-pro/engine-shape/facade','listShapes','setPlacement','object','333950JqHScM','toStringTag','492433HtZDFc','getSheetId','ICommandService','UniverInstanceType','IShapeHostAdapterRegistry','_commandService','[Sheet\x20Shape\x20Facade]:\x20Failed\x20to\x20read\x20Shape\x20\x22','transform','74739EPKCry','_getShapeScope','3076938BmmEId','FShape','UniverProSheetsShapeFacade','2063160OmENUq','width','UniverProEngineShapeFacade','8920xWDvdQ','\x22\x20was\x20not\x20found.','2541nrZTYQ','height','UniverCore','_createShapeHandle','UniverSheetsDrawing','syncExecuteCommand','4681287rlnQbA','shapeId','length','_sheetDrawingService','getDrawingByParam','subUnitId','FSheetShape','SetSheetDrawingPlacementCommand','_injector','decorate','\x22\x20has\x20no\x20transform\x20extent.','_getShapeAdapter','UNIVER_SHEET','unitId','createInstance','isConnectorShape','warn','SheetDrawingAnchorType','2xooZwQ','Position','getShapes','@univerjs/sheets-drawing','function','@univerjs/sheets/facade','UniverSheetsFacade'];_0x4a98=function(){return _0x49c135;};return _0x4a98();}
1
+ function _0x14a9(_0x21129a,_0x31b831){_0x21129a=_0x21129a-0x1f3;const _0x6189d3=_0x6189();let _0x14a90a=_0x6189d3[_0x21129a];return _0x14a90a;}(function(_0x2d964a,_0x5840a0){const _0x512f5e=_0x14a9,_0x5e70f2=_0x2d964a();while(!![]){try{const _0x52e1c9=-parseInt(_0x512f5e(0x1fb))/0x1*(parseInt(_0x512f5e(0x20c))/0x2)+parseInt(_0x512f5e(0x1f9))/0x3+-parseInt(_0x512f5e(0x20b))/0x4+-parseInt(_0x512f5e(0x219))/0x5+-parseInt(_0x512f5e(0x208))/0x6*(parseInt(_0x512f5e(0x200))/0x7)+parseInt(_0x512f5e(0x20e))/0x8*(-parseInt(_0x512f5e(0x223))/0x9)+parseInt(_0x512f5e(0x1ff))/0xa;if(_0x52e1c9===_0x5840a0)break;else _0x5e70f2['push'](_0x5e70f2['shift']());}catch(_0x1a90e0){_0x5e70f2['push'](_0x5e70f2['shift']());}}}(_0x6189,0xdf726),function(_0x38e71e,_0x29cd6c){const _0x1eeeab=_0x14a9;typeof exports=='object'&&typeof module<'u'?_0x29cd6c(exports,require('@univerjs-pro/engine-shape'),require('@univerjs-pro/engine-shape/facade'),require('@univerjs/core'),require('@univerjs/sheets/facade'),require('@univerjs/sheets-drawing')):typeof define=='function'&&define[_0x1eeeab(0x207)]?define([_0x1eeeab(0x202),_0x1eeeab(0x22b),_0x1eeeab(0x209),_0x1eeeab(0x201),_0x1eeeab(0x233),_0x1eeeab(0x22a)],_0x29cd6c):(_0x38e71e=typeof globalThis<'u'?globalThis:_0x38e71e||self,_0x29cd6c(_0x38e71e['UniverProSheetsShapeFacade']={},_0x38e71e[_0x1eeeab(0x225)],_0x38e71e[_0x1eeeab(0x204)],_0x38e71e[_0x1eeeab(0x228)],_0x38e71e[_0x1eeeab(0x221)],_0x38e71e[_0x1eeeab(0x1fd)]));}(this,function(_0x1cea29,_0x1fe565,_0x2ae5b7,_0x5e70d5,_0x16ac14,_0x10b250){const _0x12cc12=_0x14a9;Object[_0x12cc12(0x218)](_0x1cea29,Symbol[_0x12cc12(0x1fa)],{'value':_0x12cc12(0x239)});function _0x3cc045(_0x5c60aa,_0xfc62b7){return function(_0x45239b,_0x41bcca){_0xfc62b7(_0x45239b,_0x41bcca,_0x5c60aa);};}function _0x275e44(_0x142068,_0x4141d8,_0x1b587f,_0x545975){const _0x47da79=_0x12cc12;var _0x2fd725=arguments[_0x47da79(0x216)],_0x3d1dad=_0x2fd725<0x3?_0x4141d8:_0x545975===null?_0x545975=Object[_0x47da79(0x231)](_0x4141d8,_0x1b587f):_0x545975,_0x495b75;if(typeof Reflect==_0x47da79(0x22d)&&typeof Reflect['decorate']==_0x47da79(0x21f))_0x3d1dad=Reflect[_0x47da79(0x21d)](_0x142068,_0x4141d8,_0x1b587f,_0x545975);else{for(var _0x480f92=_0x142068[_0x47da79(0x216)]-0x1;_0x480f92>=0x0;_0x480f92--)(_0x495b75=_0x142068[_0x480f92])&&(_0x3d1dad=(_0x2fd725<0x3?_0x495b75(_0x3d1dad):_0x2fd725>0x3?_0x495b75(_0x4141d8,_0x1b587f,_0x3d1dad):_0x495b75(_0x4141d8,_0x1b587f))||_0x3d1dad);}return _0x2fd725>0x3&&_0x3d1dad&&Object[_0x47da79(0x218)](_0x4141d8,_0x1b587f,_0x3d1dad),_0x3d1dad;}let _0xd2015=class extends _0x2ae5b7[_0x12cc12(0x22c)]{constructor(_0x23875f,_0x2e62e9,_0x5bb9d5,_0x1cd299,_0x51fce2){const _0x2ae4ba=_0x12cc12;super(_0x23875f,_0x2e62e9,_0x5bb9d5,_0x1cd299),this[_0x2ae4ba(0x226)]=_0x51fce2;}[_0x12cc12(0x203)](){const _0x30e134=_0x12cc12;let _0xcc821c=this['_sheetDrawingService'][_0x30e134(0x217)]({'unitId':this[_0x30e134(0x238)][_0x30e134(0x214)],'subUnitId':this[_0x30e134(0x238)][_0x30e134(0x21e)],'drawingId':this['_shapeRef'][_0x30e134(0x222)]});return _0xcc821c?(0x0,_0x10b250[_0x30e134(0x220)])(_0xcc821c):null;}[_0x12cc12(0x227)](_0x151a19){const _0x283390=_0x12cc12;return this[_0x283390(0x1f3)][_0x283390(0x211)](_0x10b250[_0x283390(0x224)]['id'],{'unitId':this[_0x283390(0x238)][_0x283390(0x214)],'subUnitId':this[_0x283390(0x238)][_0x283390(0x21e)],'drawings':[{'drawingId':this[_0x283390(0x238)]['shapeId'],'placement':_0x151a19}]});}[_0x12cc12(0x23c)](_0x6c55d5,_0x58ebd6,_0x334843,_0x3a3da6){const _0x530d46=_0x12cc12;var _0x23ee9b,_0x173d02;let _0x1daa65=this[_0x530d46(0x226)][_0x530d46(0x217)]({'unitId':this[_0x530d46(0x238)]['unitId'],'subUnitId':this[_0x530d46(0x238)][_0x530d46(0x21e)],'drawingId':this[_0x530d46(0x238)][_0x530d46(0x222)]});if(!_0x1daa65)return console[_0x530d46(0x212)]('[Sheet\x20Shape\x20Facade]:\x20Shape\x20\x22'+this[_0x530d46(0x238)][_0x530d46(0x222)]+'\x22\x20was\x20not\x20found.'),this;let _0x36e1f2=(_0x23ee9b=_0x1daa65['transform'])==null?void 0x0:_0x23ee9b[_0x530d46(0x237)],_0x3bf62d=(_0x173d02=_0x1daa65[_0x530d46(0x1f8)])==null?void 0x0:_0x173d02['height'];return _0x36e1f2==null||_0x3bf62d==null?(console[_0x530d46(0x212)](_0x530d46(0x210)+this['_shapeRef'][_0x530d46(0x222)]+'\x22\x20has\x20no\x20transform\x20extent.'),this):(this[_0x530d46(0x1f3)][_0x530d46(0x211)](_0x10b250[_0x530d46(0x224)]['id'],{'unitId':this[_0x530d46(0x238)][_0x530d46(0x214)],'subUnitId':this[_0x530d46(0x238)]['subUnitId'],'drawings':[{'drawingId':this['_shapeRef'][_0x530d46(0x222)],'placement':{'kind':_0x10b250[_0x530d46(0x21b)]['Position'],'from':{'row':_0x6c55d5,'column':_0x58ebd6,'rowOffset':_0x334843,'columnOffset':_0x3a3da6},'width':_0x36e1f2,'height':_0x3bf62d}}]}),this);}};_0xd2015=_0x275e44([_0x3cc045(0x2,_0x1fe565[_0x12cc12(0x22f)]),_0x3cc045(0x3,_0x5e70d5[_0x12cc12(0x1fe)]),_0x3cc045(0x4,_0x10b250[_0x12cc12(0x205)])],_0xd2015);var _0x6e30b0=class extends _0x16ac14['FWorksheet']{[_0x12cc12(0x230)](_0x928001){const _0x59a348=_0x12cc12;let _0x741e4e=this[_0x59a348(0x23b)]();if(!_0x741e4e)return null;try{let _0x3ebadc=_0x741e4e['createShape'](this[_0x59a348(0x1fc)](),_0x928001);return _0x3ebadc?this[_0x59a348(0x20f)](_0x3ebadc):(console[_0x59a348(0x212)](_0x59a348(0x1f6)),null);}catch(_0x2a520b){return console[_0x59a348(0x212)]('[Sheet\x20Shape\x20Facade]:\x20Failed\x20to\x20insert\x20Shape.',_0x2a520b),null;}}[_0x12cc12(0x22e)](_0x3e7b79){const _0x44430e=_0x12cc12;let _0x52597f=this[_0x44430e(0x23b)]();if(!_0x52597f)return null;try{let _0x3df2b3={...this[_0x44430e(0x1fc)](),'shapeId':_0x3e7b79},_0xaba7ca=_0x52597f['getShape'](_0x3df2b3);return _0xaba7ca?this[_0x44430e(0x20f)](_0xaba7ca):(console[_0x44430e(0x212)](_0x44430e(0x210)+_0x3e7b79+_0x44430e(0x206)),null);}catch(_0x5b87af){return console['warn']('[Sheet\x20Shape\x20Facade]:\x20Failed\x20to\x20read\x20Shape\x20\x22'+_0x3e7b79+'\x22.',_0x5b87af),null;}}[_0x12cc12(0x1f7)](){const _0x241d07=_0x12cc12;let _0x28ddb9=this[_0x241d07(0x23b)]();if(!_0x28ddb9)return[];try{return _0x28ddb9[_0x241d07(0x215)](this['_getShapeScope']())[_0x241d07(0x236)](_0x11bbf9=>this[_0x241d07(0x20f)](_0x11bbf9));}catch(_0x45d7be){return console['warn']('[Sheet\x20Shape\x20Facade]:\x20Failed\x20to\x20list\x20Shapes.',_0x45d7be),[];}}[_0x12cc12(0x1fc)](){const _0x4815e5=_0x12cc12;return{'hostType':_0x5e70d5[_0x4815e5(0x20d)]['UNIVER_SHEET'],'unitId':this[_0x4815e5(0x213)]()[_0x4815e5(0x234)](),'subUnitId':this['getSheetId']()};}[_0x12cc12(0x23b)](){const _0x19c6fb=_0x12cc12;return this['_injector'][_0x19c6fb(0x235)](_0x1fe565[_0x19c6fb(0x22f)])['get'](_0x5e70d5[_0x19c6fb(0x20d)][_0x19c6fb(0x21c)]);}[_0x12cc12(0x20f)](_0xed19fe){const _0xa7e6d6=_0x12cc12;let {unitId:_0x195834,subUnitId:_0x138b58,shapeId:_0x38cf95}=_0xed19fe,_0x9f591f={'unitId':_0x195834,'subUnitId':_0x138b58,'shapeId':_0x38cf95,'hostType':_0x5e70d5[_0xa7e6d6(0x20d)][_0xa7e6d6(0x21c)]};return(0x0,_0x1fe565[_0xa7e6d6(0x1f5)])(_0xed19fe['shapeType'])?this['_injector'][_0xa7e6d6(0x23a)](_0x2ae5b7[_0xa7e6d6(0x229)],_0x9f591f,this[_0xa7e6d6(0x232)]):this[_0xa7e6d6(0x232)][_0xa7e6d6(0x23a)](_0xd2015,_0x9f591f,this[_0xa7e6d6(0x232)]);}};_0x16ac14[_0x12cc12(0x21a)][_0x12cc12(0x1f4)](_0x6e30b0),Object['defineProperty'](_0x1cea29,_0x12cc12(0x20a),{'enumerable':!0x0,'get':function(){return _0xd2015;}});}));function _0x6189(){const _0xc44599=['extend','isConnectorShape','[Sheet\x20Shape\x20Facade]:\x20Failed\x20to\x20insert\x20Shape.','getShapes','transform','4767471gBrOmQ','toStringTag','17003SzApms','_getShapeScope','UniverSheetsDrawing','ICommandService','28729520OfKfLt','35XqKEla','@univerjs/core','exports','getPlacement','UniverProEngineShapeFacade','ISheetDrawingService','\x22\x20was\x20not\x20found.','amd','451470hniFwl','@univerjs-pro/engine-shape/facade','FSheetShape','6218204iIwmtB','90FdeXYN','UniverInstanceType','38408MZigyQ','_createShapeHandle','[Sheet\x20Shape\x20Facade]:\x20Shape\x20\x22','syncExecuteCommand','warn','getWorkbook','unitId','listShapes','length','getDrawingByParam','defineProperty','606040cKUVHU','FWorksheet','SheetDrawingAnchorType','UNIVER_SHEET','decorate','subUnitId','function','getSheetDrawingPlacement','UniverSheetsFacade','shapeId','1368nlmCeH','SetSheetDrawingPlacementCommand','UniverProEngineShape','_sheetDrawingService','setPlacement','UniverCore','FConnectorShape','@univerjs/sheets-drawing','@univerjs-pro/engine-shape','FShape','object','getShape','IShapeHostAdapterRegistry','insertShape','getOwnPropertyDescriptor','_injector','@univerjs/sheets/facade','getUnitId','get','map','width','_shapeRef','Module','createInstance','_getShapeAdapter','setPosition','_commandService'];_0x6189=function(){return _0xc44599;};return _0x6189();}