@univerjs/sheets 0.19.0 → 0.20.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.
@@ -14,7 +14,7 @@
14
14
  * limitations under the License.
15
15
  */
16
16
  import type { ICommand, IRange } from '@univerjs/core';
17
- export interface IDeltaRowHeightCommand {
17
+ export interface IDeltaRowHeightCommandParams {
18
18
  anchorRow: number;
19
19
  deltaY: number;
20
20
  }
@@ -13,12 +13,13 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
+ import { FEnum } from '@univerjs/core/facade';
16
17
  import { SheetSkeletonChangeType, SheetValueChangeType, SplitDelimiterEnum } from '@univerjs/sheets';
17
18
  import { RangePermissionPoint, UnitRole, WorkbookPermissionPoint, WorksheetPermissionPoint } from './permission';
18
19
  /**
19
20
  * @ignore
20
21
  */
21
- export interface IFSheetsEnum {
22
+ export interface IFSheetsEnumMixin {
22
23
  /**
23
24
  * Sheet value change command types. These commands affect the content or style of cells.
24
25
  * Includes operations like setting cell values, moving ranges, merging cells, and applying styles.
@@ -50,7 +51,7 @@ export interface IFSheetsEnum {
50
51
  */
51
52
  RangePermissionPoint: typeof RangePermissionPoint;
52
53
  }
53
- export declare class FSheetsEnum implements IFSheetsEnum {
54
+ export declare class FSheetsEnumMixin extends FEnum implements IFSheetsEnumMixin {
54
55
  get SheetValueChangeType(): typeof SheetValueChangeType;
55
56
  get SheetSkeletonChangeType(): typeof SheetSkeletonChangeType;
56
57
  get SplitDelimiterType(): typeof SplitDelimiterEnum;
@@ -60,6 +61,6 @@ export declare class FSheetsEnum implements IFSheetsEnum {
60
61
  get RangePermissionPoint(): typeof RangePermissionPoint;
61
62
  }
62
63
  declare module '@univerjs/core/facade' {
63
- interface FEnum extends IFSheetsEnum {
64
+ interface FEnum extends IFSheetsEnumMixin {
64
65
  }
65
66
  }
@@ -19,12 +19,13 @@ import type { CommandListenerValueChange } from '@univerjs/sheets';
19
19
  import type { FRange } from './f-range';
20
20
  import type { FWorkbook } from './f-workbook';
21
21
  import type { FWorksheet } from './f-worksheet';
22
+ import { FEventName } from '@univerjs/core/facade';
22
23
  /**
23
24
  * Interface for sheet-related events
24
25
  * Provides event names for sheet creation, workbook creation, and gridline changes
25
26
  * @ignore
26
27
  */
27
- export interface IFSheetEventMixin {
28
+ export interface IFSheetsEventNameMixin {
28
29
  /**
29
30
  * Event fired after a sheet is created
30
31
  * @see {@link ISheetCreatedEventParams}
@@ -38,7 +39,7 @@ export interface IFSheetEventMixin {
38
39
  * // Remove the event listener, use `disposable.dispose()`
39
40
  * ```
40
41
  */
41
- get SheetCreated(): 'SheetCreated';
42
+ readonly SheetCreated: 'SheetCreated';
42
43
  /**
43
44
  * Event fired before a sheet is created
44
45
  * @see {@link IBeforeSheetCreateEventParams}
@@ -55,10 +56,10 @@ export interface IFSheetEventMixin {
55
56
  * // Remove the event listener, use `disposable.dispose()`
56
57
  * ```
57
58
  */
58
- get BeforeSheetCreate(): 'BeforeSheetCreate';
59
+ readonly BeforeSheetCreate: 'BeforeSheetCreate';
59
60
  /**
60
61
  * Event fired before the active sheet changes
61
- * @see {@link IBeforeActiveSheetChangeEvent}
62
+ * @see {@link IBeforeActiveSheetChangeEventParams}
62
63
  * @example
63
64
  * ```ts
64
65
  * const disposable = univerAPI.addEvent(univerAPI.Event.BeforeActiveSheetChange, (params) => {
@@ -72,10 +73,10 @@ export interface IFSheetEventMixin {
72
73
  * // Remove the event listener, use `disposable.dispose()`
73
74
  * ```
74
75
  */
75
- get BeforeActiveSheetChange(): 'BeforeActiveSheetChange';
76
+ readonly BeforeActiveSheetChange: 'BeforeActiveSheetChange';
76
77
  /**
77
78
  * Event fired after the active sheet changes
78
- * @see {@link IActiveSheetChangedEvent}
79
+ * @see {@link IActiveSheetChangedEventParams}
79
80
  * @example
80
81
  * ```ts
81
82
  * const disposable = univerAPI.addEvent(univerAPI.Event.ActiveSheetChanged, (params) => {
@@ -86,10 +87,10 @@ export interface IFSheetEventMixin {
86
87
  * // Remove the event listener, use `disposable.dispose()`
87
88
  * ```
88
89
  */
89
- get ActiveSheetChanged(): 'ActiveSheetChanged';
90
+ readonly ActiveSheetChanged: 'ActiveSheetChanged';
90
91
  /**
91
92
  * Event fired after a sheet is deleted
92
- * @see {@link ISheetDeletedEvent}
93
+ * @see {@link ISheetDeletedEventParams}
93
94
  * @example
94
95
  * ```ts
95
96
  * const disposable = univerAPI.addEvent(univerAPI.Event.SheetDeleted, (params) => {
@@ -100,10 +101,10 @@ export interface IFSheetEventMixin {
100
101
  * // Remove the event listener, use `disposable.dispose()`
101
102
  * ```
102
103
  */
103
- get SheetDeleted(): 'SheetDeleted';
104
+ readonly SheetDeleted: 'SheetDeleted';
104
105
  /**
105
106
  * Event fired before a sheet is deleted
106
- * @see {@link IBeforeSheetDeleteEvent}
107
+ * @see {@link IBeforeSheetDeleteEventParams}
107
108
  * @example
108
109
  * ```ts
109
110
  * const disposable = univerAPI.addEvent(univerAPI.Event.BeforeSheetDelete, (params) => {
@@ -117,10 +118,10 @@ export interface IFSheetEventMixin {
117
118
  * // Remove the event listener, use `disposable.dispose()`
118
119
  * ```
119
120
  */
120
- get BeforeSheetDelete(): 'BeforeSheetDelete';
121
+ readonly BeforeSheetDelete: 'BeforeSheetDelete';
121
122
  /**
122
123
  * Event fired after a sheet is moved
123
- * @see {@link ISheetMovedEvent}
124
+ * @see {@link ISheetMovedEventParams}
124
125
  * @example
125
126
  * ```ts
126
127
  * const disposable = univerAPI.addEvent(univerAPI.Event.SheetMoved, (params) => {
@@ -131,10 +132,10 @@ export interface IFSheetEventMixin {
131
132
  * // Remove the event listener, use `disposable.dispose()`
132
133
  * ```
133
134
  */
134
- get SheetMoved(): 'SheetMoved';
135
+ readonly SheetMoved: 'SheetMoved';
135
136
  /**
136
137
  * Event fired before a sheet is moved
137
- * @see {@link IBeforeSheetMoveEvent}
138
+ * @see {@link IBeforeSheetMoveEventParams}
138
139
  * @example
139
140
  * ```ts
140
141
  * const disposable = univerAPI.addEvent(univerAPI.Event.BeforeSheetMove, (params) => {
@@ -148,10 +149,10 @@ export interface IFSheetEventMixin {
148
149
  * // Remove the event listener, use `disposable.dispose()`
149
150
  * ```
150
151
  */
151
- get BeforeSheetMove(): 'BeforeSheetMove';
152
+ readonly BeforeSheetMove: 'BeforeSheetMove';
152
153
  /**
153
154
  * Event fired after a sheet name is changed
154
- * @see {@link ISheetNameChangedEvent}
155
+ * @see {@link ISheetNameChangedEventParams}
155
156
  * @example
156
157
  * ```ts
157
158
  * const disposable = univerAPI.addEvent(univerAPI.Event.SheetNameChanged, (params) => {
@@ -162,10 +163,10 @@ export interface IFSheetEventMixin {
162
163
  * // Remove the event listener, use `disposable.dispose()`
163
164
  * ```
164
165
  */
165
- get SheetNameChanged(): 'SheetNameChanged';
166
+ readonly SheetNameChanged: 'SheetNameChanged';
166
167
  /**
167
168
  * Event fired before a sheet name is changed
168
- * @see {@link IBeforeSheetNameChangeEvent}
169
+ * @see {@link IBeforeSheetNameChangeEventParams}
169
170
  * @example
170
171
  * ```ts
171
172
  * const disposable = univerAPI.addEvent(univerAPI.Event.BeforeSheetNameChange, (params) => {
@@ -179,10 +180,10 @@ export interface IFSheetEventMixin {
179
180
  * // Remove the event listener, use `disposable.dispose()`
180
181
  * ```
181
182
  */
182
- get BeforeSheetNameChange(): 'BeforeSheetNameChange';
183
+ readonly BeforeSheetNameChange: 'BeforeSheetNameChange';
183
184
  /**
184
185
  * Event fired after a sheet tab color is changed
185
- * @see {@link ISheetTabColorChangedEvent}
186
+ * @see {@link ISheetTabColorChangedEventParams}
186
187
  * @example
187
188
  * ```ts
188
189
  * const disposable = univerAPI.addEvent(univerAPI.Event.SheetTabColorChanged, (params) => {
@@ -193,10 +194,10 @@ export interface IFSheetEventMixin {
193
194
  * // Remove the event listener, use `disposable.dispose()`
194
195
  * ```
195
196
  */
196
- get SheetTabColorChanged(): 'SheetTabColorChanged';
197
+ readonly SheetTabColorChanged: 'SheetTabColorChanged';
197
198
  /**
198
199
  * Event fired before a sheet tab color is changed
199
- * @see {@link IBeforeSheetTabColorChangeEvent}
200
+ * @see {@link IBeforeSheetTabColorChangeEventParams}
200
201
  * @example
201
202
  * ```ts
202
203
  * const disposable = univerAPI.addEvent(univerAPI.Event.BeforeSheetTabColorChange, (params) => {
@@ -210,10 +211,10 @@ export interface IFSheetEventMixin {
210
211
  * // Remove the event listener, use `disposable.dispose()`
211
212
  * ```
212
213
  */
213
- get BeforeSheetTabColorChange(): 'BeforeSheetTabColorChange';
214
+ readonly BeforeSheetTabColorChange: 'BeforeSheetTabColorChange';
214
215
  /**
215
216
  * Event fired after a sheet is hidden
216
- * @see {@link ISheetHideChangedEvent}
217
+ * @see {@link ISheetHideChangedEventParams}
217
218
  * @example
218
219
  * ```ts
219
220
  * const disposable = univerAPI.addEvent(univerAPI.Event.SheetHideChanged, (params) => {
@@ -224,10 +225,10 @@ export interface IFSheetEventMixin {
224
225
  * // Remove the event listener, use `disposable.dispose()`
225
226
  * ```
226
227
  */
227
- get SheetHideChanged(): 'SheetHideChanged';
228
+ readonly SheetHideChanged: 'SheetHideChanged';
228
229
  /**
229
230
  * Event fired before a sheet is hidden
230
- * @see {@link IBeforeSheetHideChangeEvent}
231
+ * @see {@link IBeforeSheetHideChangeEventParams}
231
232
  * @example
232
233
  * ```ts
233
234
  * const disposable = univerAPI.addEvent(univerAPI.Event.BeforeSheetHideChange, (params) => {
@@ -241,10 +242,10 @@ export interface IFSheetEventMixin {
241
242
  * // Remove the event listener, use `disposable.dispose()`
242
243
  * ```
243
244
  */
244
- get BeforeSheetHideChange(): 'BeforeSheetHideChange';
245
+ readonly BeforeSheetHideChange: 'BeforeSheetHideChange';
245
246
  /**
246
247
  * Event fired after a workbook is created
247
- * @see {@link IWorkbookCreateParam}
248
+ * @see {@link IWorkbookCreateEventParams}
248
249
  * @example
249
250
  * ```ts
250
251
  * const disposable = univerAPI.addEvent(univerAPI.Event.WorkbookCreated, (params) => {
@@ -255,10 +256,10 @@ export interface IFSheetEventMixin {
255
256
  * // Remove the event listener, use `disposable.dispose()`
256
257
  * ```
257
258
  */
258
- get WorkbookCreated(): 'WorkbookCreated';
259
+ readonly WorkbookCreated: 'WorkbookCreated';
259
260
  /**
260
261
  * Event fired after a workbook is disposed
261
- * @see {@link IWorkbookDisposedEvent}
262
+ * @see {@link IWorkbookDisposedEventParams}
262
263
  * @example
263
264
  * ```ts
264
265
  * const disposable = univerAPI.addEvent(univerAPI.Event.WorkbookDisposed, (params) => {
@@ -269,10 +270,10 @@ export interface IFSheetEventMixin {
269
270
  * // Remove the event listener, use `disposable.dispose()`
270
271
  * ```
271
272
  */
272
- get WorkbookDisposed(): 'WorkbookDisposed';
273
+ readonly WorkbookDisposed: 'WorkbookDisposed';
273
274
  /**
274
275
  * Event fired when gridline changed
275
- * @see {@link IGridlineChangedEvent}
276
+ * @see {@link IGridlineChangedEventParams}
276
277
  * @example
277
278
  * ```ts
278
279
  * const disposable = univerAPI.addEvent(univerAPI.Event.GridlineChanged, (params) => {
@@ -283,10 +284,10 @@ export interface IFSheetEventMixin {
283
284
  * // Remove the event listener, use `disposable.dispose()`
284
285
  * ```
285
286
  */
286
- get GridlineChanged(): 'GridlineChanged';
287
+ readonly GridlineChanged: 'GridlineChanged';
287
288
  /**
288
289
  * Event fired before gridline enable changed
289
- * @see {@link IBeforeGridlineEnableChange}
290
+ * @see {@link IBeforeGridlineEnableChangeEventParams}
290
291
  * @example
291
292
  * ```ts
292
293
  * const disposable = univerAPI.addEvent(univerAPI.Event.BeforeGridlineEnableChange, (params) => {
@@ -300,10 +301,10 @@ export interface IFSheetEventMixin {
300
301
  * // Remove the event listener, use `disposable.dispose()`
301
302
  * ```
302
303
  */
303
- get BeforeGridlineEnableChange(): 'BeforeGridlineEnableChange';
304
+ readonly BeforeGridlineEnableChange: 'BeforeGridlineEnableChange';
304
305
  /**
305
306
  * Event fired before gridline color changed
306
- * @see {@link IBeforeGridlineColorChanged}
307
+ * @see {@link IBeforeGridlineColorChangedEventParams}
307
308
  * @example
308
309
  * ```ts
309
310
  * const disposable = univerAPI.addEvent(univerAPI.Event.BeforeGridlineColorChange, (params) => {
@@ -317,10 +318,10 @@ export interface IFSheetEventMixin {
317
318
  * // Remove the event listener, use `disposable.dispose()`
318
319
  * ```
319
320
  */
320
- get BeforeGridlineColorChange(): 'BeforeGridlineColorChange';
321
+ readonly BeforeGridlineColorChange: 'BeforeGridlineColorChange';
321
322
  /**
322
323
  * Event fired when sheet value changed
323
- * @see {@link ISheetValueChangedEvent}
324
+ * @see {@link ISheetValueChangedEventParams}
324
325
  * @example
325
326
  * ```ts
326
327
  * const disposable = univerAPI.addEvent(univerAPI.Event.SheetValueChanged, (params)=> {
@@ -337,7 +338,7 @@ export interface IFSheetEventMixin {
337
338
  * Interface for workbook creation parameters
338
339
  * Extends the base event interface and includes workbook initialization details
339
340
  */
340
- export interface IWorkbookCreateParam extends IEventBase {
341
+ export interface IWorkbookCreateEventParams extends IEventBase {
341
342
  /** Unique identifier for the workbook unit */
342
343
  unitId: string;
343
344
  /** Type identifier specifying this is a sheet instance */
@@ -351,7 +352,7 @@ export interface IWorkbookCreateParam extends IEventBase {
351
352
  * Interface for workbook disposal event
352
353
  * Contains information about the disposed workbook including its snapshot data
353
354
  */
354
- export interface IWorkbookDisposedEvent extends IEventBase {
355
+ export interface IWorkbookDisposedEventParams extends IEventBase {
355
356
  /** Unique identifier of the disposed workbook unit */
356
357
  unitId: string;
357
358
  /** Type identifier specifying this was a sheet instance */
@@ -363,7 +364,7 @@ export interface IWorkbookDisposedEvent extends IEventBase {
363
364
  * Interface for gridline change event
364
365
  * Triggered when gridline visibility or color changes in a worksheet
365
366
  */
366
- export interface IGridlineChangedEvent extends IEventBase {
367
+ export interface IGridlineChangedEventParams extends IEventBase {
367
368
  /** The workbook instance containing the worksheet */
368
369
  workbook: FWorkbook;
369
370
  /** The worksheet where gridline changes occurred */
@@ -377,7 +378,7 @@ export interface IGridlineChangedEvent extends IEventBase {
377
378
  * Interface for event before gridline enable/disable
378
379
  * Triggered before changing the gridline visibility state
379
380
  */
380
- export interface IBeforeGridlineEnableChange extends IEventBase {
381
+ export interface IBeforeGridlineEnableChangeEventParams extends IEventBase {
381
382
  /** The workbook instance containing the worksheet */
382
383
  workbook: FWorkbook;
383
384
  /** The worksheet where gridline state will change */
@@ -389,7 +390,7 @@ export interface IBeforeGridlineEnableChange extends IEventBase {
389
390
  * Interface for event before gridline color change
390
391
  * Triggered before changing the gridline color
391
392
  */
392
- export interface IBeforeGridlineColorChanged extends IEventBase {
393
+ export interface IBeforeGridlineColorChangedEventParams extends IEventBase {
393
394
  /** The workbook instance containing the worksheet */
394
395
  workbook: FWorkbook;
395
396
  /** The worksheet where gridline color will change */
@@ -423,7 +424,7 @@ export interface ISheetCreatedEventParams extends IEventBase {
423
424
  * Interface for sheet active change event
424
425
  * Contains information about the sheet that will become active
425
426
  */
426
- export interface IBeforeActiveSheetChangeEvent extends IEventBase {
427
+ export interface IBeforeActiveSheetChangeEventParams extends IEventBase {
427
428
  /** The workbook instance containing the worksheet */
428
429
  workbook: FWorkbook;
429
430
  /** The worksheet that will become active */
@@ -435,7 +436,7 @@ export interface IBeforeActiveSheetChangeEvent extends IEventBase {
435
436
  * Interface for sheet active changed event
436
437
  * Contains information about the newly activated sheet
437
438
  */
438
- export interface IActiveSheetChangedEvent extends IEventBase {
439
+ export interface IActiveSheetChangedEventParams extends IEventBase {
439
440
  /** The workbook instance containing the worksheet */
440
441
  workbook: FWorkbook;
441
442
  /** The worksheet that has become active */
@@ -445,7 +446,7 @@ export interface IActiveSheetChangedEvent extends IEventBase {
445
446
  * Interface for sheet deletion event
446
447
  * Contains information about the sheet that was deleted
447
448
  */
448
- export interface ISheetDeletedEvent extends IEventBase {
449
+ export interface ISheetDeletedEventParams extends IEventBase {
449
450
  /** The workbook instance containing the worksheet */
450
451
  workbook: FWorkbook;
451
452
  /** The worksheet that was deleted */
@@ -455,7 +456,7 @@ export interface ISheetDeletedEvent extends IEventBase {
455
456
  * Interface for before sheet deletion event
456
457
  * Contains information about the sheet that will be deleted
457
458
  */
458
- export interface IBeforeSheetDeleteEvent extends IEventBase {
459
+ export interface IBeforeSheetDeleteEventParams extends IEventBase {
459
460
  /** The workbook instance containing the worksheet */
460
461
  workbook: FWorkbook;
461
462
  /** The worksheet that will be deleted */
@@ -465,7 +466,7 @@ export interface IBeforeSheetDeleteEvent extends IEventBase {
465
466
  * Interface for sheet moved event
466
467
  * Contains information about the sheet movement
467
468
  */
468
- export interface ISheetMovedEvent extends IEventBase {
469
+ export interface ISheetMovedEventParams extends IEventBase {
469
470
  /** The workbook instance containing the worksheet */
470
471
  workbook: FWorkbook;
471
472
  /** The worksheet that was moved */
@@ -477,7 +478,7 @@ export interface ISheetMovedEvent extends IEventBase {
477
478
  * Interface for before sheet move event
478
479
  * Contains information about the planned sheet movement
479
480
  */
480
- export interface IBeforeSheetMoveEvent extends IEventBase {
481
+ export interface IBeforeSheetMoveEventParams extends IEventBase {
481
482
  /** The workbook instance containing the worksheet */
482
483
  workbook: FWorkbook;
483
484
  /** The worksheet that will be moved */
@@ -491,7 +492,7 @@ export interface IBeforeSheetMoveEvent extends IEventBase {
491
492
  * Interface for sheet name change event
492
493
  * Contains information about the sheet name change
493
494
  */
494
- export interface ISheetNameChangedEvent extends IEventBase {
495
+ export interface ISheetNameChangedEventParams extends IEventBase {
495
496
  /** The workbook instance containing the worksheet */
496
497
  workbook: FWorkbook;
497
498
  /** The worksheet whose name was changed */
@@ -503,7 +504,7 @@ export interface ISheetNameChangedEvent extends IEventBase {
503
504
  * Interface for before sheet name change event
504
505
  * Contains information about the planned sheet name change
505
506
  */
506
- export interface IBeforeSheetNameChangeEvent extends IEventBase {
507
+ export interface IBeforeSheetNameChangeEventParams extends IEventBase {
507
508
  /** The workbook instance containing the worksheet */
508
509
  workbook: FWorkbook;
509
510
  /** The worksheet whose name will be changed */
@@ -517,7 +518,7 @@ export interface IBeforeSheetNameChangeEvent extends IEventBase {
517
518
  * Interface for sheet tab color change event
518
519
  * Contains information about the sheet tab color change
519
520
  */
520
- export interface ISheetTabColorChangedEvent extends IEventBase {
521
+ export interface ISheetTabColorChangedEventParams extends IEventBase {
521
522
  /** The workbook instance containing the worksheet */
522
523
  workbook: FWorkbook;
523
524
  /** The worksheet whose tab color was changed */
@@ -529,7 +530,7 @@ export interface ISheetTabColorChangedEvent extends IEventBase {
529
530
  * Interface for before sheet tab color change event
530
531
  * Contains information about the planned sheet tab color change
531
532
  */
532
- export interface IBeforeSheetTabColorChangeEvent extends IEventBase {
533
+ export interface IBeforeSheetTabColorChangeEventParams extends IEventBase {
533
534
  /** The workbook instance containing the worksheet */
534
535
  workbook: FWorkbook;
535
536
  /** The worksheet whose tab color will be changed */
@@ -543,7 +544,7 @@ export interface IBeforeSheetTabColorChangeEvent extends IEventBase {
543
544
  * Interface for sheet hide state change event
544
545
  * Contains information about the sheet visibility change
545
546
  */
546
- export interface ISheetHideChangedEvent extends IEventBase {
547
+ export interface ISheetHideChangedEventParams extends IEventBase {
547
548
  /** The workbook instance containing the worksheet */
548
549
  workbook: FWorkbook;
549
550
  /** The worksheet whose visibility was changed */
@@ -555,7 +556,7 @@ export interface ISheetHideChangedEvent extends IEventBase {
555
556
  * Interface for before sheet hide state change event
556
557
  * Contains information about the planned sheet visibility change
557
558
  */
558
- export interface IBeforeSheetHideChangeEvent extends IEventBase {
559
+ export interface IBeforeSheetHideChangeEventParams extends IEventBase {
559
560
  /** The workbook instance containing the worksheet */
560
561
  workbook: FWorkbook;
561
562
  /** The worksheet whose visibility will be changed */
@@ -567,7 +568,7 @@ export interface IBeforeSheetHideChangeEvent extends IEventBase {
567
568
  * Interface for sheet value changed event
568
569
  * Contains information about the sheet value change
569
570
  */
570
- export interface ISheetValueChangedEvent extends IEventBase {
571
+ export interface ISheetValueChangedEventParams extends IEventBase {
571
572
  /** The affected ranges of the sheet */
572
573
  effectedRanges: FRange[];
573
574
  /** The payload of the value change */
@@ -578,49 +579,49 @@ export interface ISheetValueChangedEvent extends IEventBase {
578
579
  * Provides event names and their corresponding event parameter interfaces
579
580
  * @ignore
580
581
  */
581
- export interface ISheetEventParamConfig {
582
+ export interface ISheetsEventParamConfig {
582
583
  /** Event fired after a worksheet is created */
583
584
  SheetCreated: ISheetCreatedEventParams;
584
585
  /** Event fired before creating a worksheet */
585
586
  BeforeSheetCreate: IBeforeSheetCreateEventParams;
586
587
  /** Event fired after a workbook is created */
587
- WorkbookCreated: IWorkbookCreateParam;
588
+ WorkbookCreated: IWorkbookCreateEventParams;
588
589
  /** Event fired when a workbook is disposed */
589
- WorkbookDisposed: IWorkbookDisposedEvent;
590
+ WorkbookDisposed: IWorkbookDisposedEventParams;
590
591
  /** Event fired when gridline changed */
591
- GridlineChanged: IGridlineChangedEvent;
592
+ GridlineChanged: IGridlineChangedEventParams;
592
593
  /** Event fired before gridline enable changed */
593
- BeforeGridlineEnableChange: IBeforeGridlineEnableChange;
594
+ BeforeGridlineEnableChange: IBeforeGridlineEnableChangeEventParams;
594
595
  /** Event fired before gridline color changed */
595
- BeforeGridlineColorChange: IBeforeGridlineColorChanged;
596
+ BeforeGridlineColorChange: IBeforeGridlineColorChangedEventParams;
596
597
  /** Event fired before active sheet changes */
597
- BeforeActiveSheetChange: IBeforeActiveSheetChangeEvent;
598
+ BeforeActiveSheetChange: IBeforeActiveSheetChangeEventParams;
598
599
  /** Event fired after active sheet changed */
599
- ActiveSheetChanged: IActiveSheetChangedEvent;
600
+ ActiveSheetChanged: IActiveSheetChangedEventParams;
600
601
  /** Event fired after a sheet is deleted */
601
- SheetDeleted: ISheetDeletedEvent;
602
+ SheetDeleted: ISheetDeletedEventParams;
602
603
  /** Event fired before a sheet is deleted */
603
- BeforeSheetDelete: IBeforeSheetDeleteEvent;
604
+ BeforeSheetDelete: IBeforeSheetDeleteEventParams;
604
605
  /** Event fired after a sheet is moved */
605
- SheetMoved: ISheetMovedEvent;
606
+ SheetMoved: ISheetMovedEventParams;
606
607
  /** Event fired before a sheet is moved */
607
- BeforeSheetMove: IBeforeSheetMoveEvent;
608
+ BeforeSheetMove: IBeforeSheetMoveEventParams;
608
609
  /** Event fired after a sheet name is changed */
609
- SheetNameChanged: ISheetNameChangedEvent;
610
+ SheetNameChanged: ISheetNameChangedEventParams;
610
611
  /** Event fired before a sheet name is changed */
611
- BeforeSheetNameChange: IBeforeSheetNameChangeEvent;
612
+ BeforeSheetNameChange: IBeforeSheetNameChangeEventParams;
612
613
  /** Event fired after a sheet tab color is changed */
613
- SheetTabColorChanged: ISheetTabColorChangedEvent;
614
+ SheetTabColorChanged: ISheetTabColorChangedEventParams;
614
615
  /** Event fired before a sheet tab color is changed */
615
- BeforeSheetTabColorChange: IBeforeSheetTabColorChangeEvent;
616
+ BeforeSheetTabColorChange: IBeforeSheetTabColorChangeEventParams;
616
617
  /** Event fired after a sheet visibility is changed */
617
- SheetHideChanged: ISheetHideChangedEvent;
618
+ SheetHideChanged: ISheetHideChangedEventParams;
618
619
  /** Event fired before a sheet visibility is changed */
619
- BeforeSheetHideChange: IBeforeSheetHideChangeEvent;
620
+ BeforeSheetHideChange: IBeforeSheetHideChangeEventParams;
620
621
  /** Event fired after a sheet value is changed */
621
- SheetValueChanged: ISheetValueChangedEvent;
622
+ SheetValueChanged: ISheetValueChangedEventParams;
622
623
  }
623
- export declare class FSheetEventName implements IFSheetEventMixin {
624
+ export declare class FSheetsEventNameMixin extends FEventName implements IFSheetsEventNameMixin {
624
625
  get SheetCreated(): 'SheetCreated';
625
626
  get BeforeSheetCreate(): 'BeforeSheetCreate';
626
627
  get WorkbookCreated(): 'WorkbookCreated';
@@ -643,8 +644,8 @@ export declare class FSheetEventName implements IFSheetEventMixin {
643
644
  get SheetValueChanged(): 'SheetValueChanged';
644
645
  }
645
646
  declare module '@univerjs/core/facade' {
646
- interface FEventName extends IFSheetEventMixin {
647
+ interface FEventName extends IFSheetsEventNameMixin {
647
648
  }
648
- interface IEventParamConfig extends ISheetEventParamConfig {
649
+ interface IEventParamConfig extends ISheetsEventParamConfig {
649
650
  }
650
651
  }
@@ -191,12 +191,6 @@ export declare class FUniverSheetsMixin extends FUniver implements IFUniverSheet
191
191
  worksheet: FWorksheet;
192
192
  }>;
193
193
  setFreezeSync(enabled: boolean): void;
194
- private _fireActiveSheetChanged;
195
- private _fireSheetDeleted;
196
- private _fireSheetMoved;
197
- private _fireSheetNameChanged;
198
- private _fireSheetTabColorChanged;
199
- private _fireSheetHideChanged;
200
194
  }
201
195
  declare module '@univerjs/core/facade' {
202
196
  interface FUniver extends IFUniverSheetsMixin {
@@ -56,7 +56,7 @@ export { type IRemoveWorksheetMergeCommandParams, RemoveWorksheetMergeCommand }
56
56
  export { type IReorderRangeCommandParams, ReorderRangeCommand } from './commands/commands/reorder-range.command';
57
57
  export { type ISetBorderBasicCommandParams, type ISetBorderColorCommandParams, type ISetBorderCommandParams, type ISetBorderPositionCommandParams, type ISetBorderStyleCommandParams, SetBorderBasicCommand, SetBorderColorCommand, SetBorderCommand, SetBorderPositionCommand, SetBorderStyleCommand, } from './commands/commands/set-border-command';
58
58
  export { type ISetColDataCommandParams, SetColDataCommand } from './commands/commands/set-col-data.command';
59
- export { type ISetSpecificColsVisibleCommandParams, SetColHiddenCommand, SetSelectedColsVisibleCommand, SetSpecificColsVisibleCommand, } from './commands/commands/set-col-visible.command';
59
+ export { type ISetColHiddenCommandParams, type ISetSpecificColsVisibleCommandParams, SetColHiddenCommand, SetSelectedColsVisibleCommand, SetSpecificColsVisibleCommand, } from './commands/commands/set-col-visible.command';
60
60
  export { SetDefinedNameCommand } from './commands/commands/set-defined-name.command';
61
61
  export { type ICancelFrozenCommandParams, type ISetFrozenCommandParams } from './commands/commands/set-frozen.command';
62
62
  export { CancelFrozenCommand, SetFrozenCommand } from './commands/commands/set-frozen.command';
@@ -65,7 +65,7 @@ export { SetProtectionCommand } from './commands/commands/set-protection.command
65
65
  export { type ISetRangeCustomMetadataCommandParams, SetRangeCustomMetadataCommand } from './commands/commands/set-range-custom-metadata.command';
66
66
  export { type ISetRangeValuesCommandParams, SetRangeValuesCommand } from './commands/commands/set-range-values.command';
67
67
  export { type ISetRowDataCommandParams, SetRowDataCommand } from './commands/commands/set-row-data.command';
68
- export { type ISetSpecificRowsVisibleCommandParams, SetRowHiddenCommand, SetSelectedRowsVisibleCommand, SetSpecificRowsVisibleCommand, } from './commands/commands/set-row-visible.command';
68
+ export { type ISetRowHiddenCommandParams, type ISetSpecificRowsVisibleCommandParams, SetRowHiddenCommand, SetSelectedRowsVisibleCommand, SetSpecificRowsVisibleCommand, } from './commands/commands/set-row-visible.command';
69
69
  export { AFFECT_LAYOUT_STYLES, type ISetColorCommandParams, type ISetFontFamilyCommandParams, type ISetFontSizeCommandParams, type ISetHorizontalTextAlignCommandParams, type ISetStyleCommandParams, type ISetTextRotationCommandParams, type ISetTextWrapCommandParams, type ISetVerticalTextAlignCommandParams, type IStyleTypeValue, ResetBackgroundColorCommand, ResetTextColorCommand, SetBackgroundColorCommand, SetBoldCommand, SetFontFamilyCommand, SetFontSizeCommand, SetHorizontalTextAlignCommand, SetItalicCommand, SetOverlineCommand, SetStrikeThroughCommand, SetStyleCommand, SetTextColorCommand, SetTextRotationCommand, SetTextWrapCommand, SetUnderlineCommand, SetVerticalTextAlignCommand, } from './commands/commands/set-style.command';
70
70
  export { SetTabColorCommand } from './commands/commands/set-tab-color.command';
71
71
  export { type ISetWorkbookNameCommandParams, SetWorkbookNameCommand } from './commands/commands/set-workbook-name.command';
@@ -83,7 +83,7 @@ export { SetWorksheetProtectionCommand } from './commands/commands/set-worksheet
83
83
  export { SetWorksheetRightToLeftCommand } from './commands/commands/set-worksheet-right-to-left.command';
84
84
  export { SetWorksheetRowCountCommand } from './commands/commands/set-worksheet-row-count.command';
85
85
  export { DeltaRowHeightCommand, type ISetRowHeightCommandParams, SetRowHeightCommand, SetWorksheetRowIsAutoHeightCommand } from './commands/commands/set-worksheet-row-height.command';
86
- export type { IDeltaRowHeightCommand, ISetWorksheetRowIsAutoHeightCommandParams } from './commands/commands/set-worksheet-row-height.command';
86
+ export type { IDeltaRowHeightCommandParams, ISetWorksheetRowIsAutoHeightCommandParams } from './commands/commands/set-worksheet-row-height.command';
87
87
  export { SetWorksheetShowCommand } from './commands/commands/set-worksheet-show.command';
88
88
  export type { ISetWorksheetShowCommandParams } from './commands/commands/set-worksheet-show.command';
89
89
  export { SplitTextToColumnsCommand } from './commands/commands/split-text-to-columns.command';
@@ -219,5 +219,7 @@ export { getNextPrimaryCell } from './services/selections/move-active-cell-util'
219
219
  export { InterceptCellContentPriority, INTERCEPTOR_POINT } from './services/sheet-interceptor/interceptor-const';
220
220
  export { AFTER_CELL_EDIT, BEFORE_CELL_EDIT, type IAutoHeightContext, SheetInterceptorService, VALIDATE_CELL } from './services/sheet-interceptor/sheet-interceptor.service';
221
221
  export type { ISheetLocation, ISheetLocationBase, ISheetRowLocation } from './services/sheet-interceptor/utils/interceptor';
222
- export { SheetSkeletonService } from './skeleton/skeleton.service';
222
+ export { convertPositionCellToSheetOverGrid, convertPositionSheetOverGridToAbsolute } from './skeleton/drawing-position-util';
223
+ export { type ISheetSkeletonManagerParam, SheetSkeletonService } from './skeleton/skeleton.service';
224
+ export { attachPrimaryWithCoord, attachRangeWithCoord, attachSelectionWithCoord } from './skeleton/util';
223
225
  export { UnitAction, UnitObject } from '@univerjs/protocol';
@@ -66,6 +66,7 @@ export declare class SheetInterceptorService extends Disposable {
66
66
  private readonly _worksheetDisposables;
67
67
  private _interceptorsDirty;
68
68
  private _composedInterceptorByKey;
69
+ private _composedInterceptorsLengthByKey;
69
70
  readonly writeCellInterceptor: InterceptorManager<{
70
71
  BEFORE_CELL_EDIT: IInterceptor<ICellDataForSheetInterceptor, ISheetLocationForEditor>;
71
72
  AFTER_CELL_EDIT: IInterceptor<ICellDataForSheetInterceptor, ISheetLocationForEditor>;
@@ -0,0 +1,49 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { SpreadsheetSkeleton } from '@univerjs/engine-render';
17
+ import type { ICellOverGridPosition, ISheetOverGridPosition } from '../basics';
18
+ export declare function convertPositionSheetOverGridToAbsolute(unitId: string, subUnitId: string, sheetOverGridPosition: ISheetOverGridPosition, skeleton: SpreadsheetSkeleton): {
19
+ unitId: string;
20
+ subUnitId: string;
21
+ left: number;
22
+ top: number;
23
+ width: number;
24
+ height: number;
25
+ };
26
+ export declare function convertPositionCellToSheetOverGrid(unitId: string, subUnitId: string, cellOverGridPosition: ICellOverGridPosition, width: number, height: number, skeleton: SpreadsheetSkeleton): {
27
+ unitId: string;
28
+ subUnitId: string;
29
+ sheetTransform: {
30
+ from: {
31
+ column: number;
32
+ columnOffset: number;
33
+ row: number;
34
+ rowOffset: number;
35
+ };
36
+ to: {
37
+ row: number;
38
+ rowOffset: number;
39
+ column: number;
40
+ columnOffset: number;
41
+ };
42
+ };
43
+ transform: {
44
+ left: number;
45
+ top: number;
46
+ width: number;
47
+ height: number;
48
+ };
49
+ };