@univerjs/core 0.1.2 → 0.1.3

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.
Files changed (36) hide show
  1. package/lib/cjs/index.js +7 -5
  2. package/lib/es/index.js +2195 -1714
  3. package/lib/types/common/__tests__/array.spec.d.ts +16 -0
  4. package/lib/types/common/array.d.ts +8 -0
  5. package/lib/types/common/interceptor.d.ts +1 -1
  6. package/lib/types/index.d.ts +10 -1
  7. package/lib/types/services/command/command.service.d.ts +4 -4
  8. package/lib/types/services/instance/instance.service.d.ts +1 -1
  9. package/lib/types/services/locale/locale.service.d.ts +4 -2
  10. package/lib/types/services/log/context.d.ts +18 -0
  11. package/lib/types/services/snapshot/__tests__/snapshot-mock.d.ts +37 -0
  12. package/lib/types/services/snapshot/__tests__/snapshot-transform.spec.d.ts +16 -0
  13. package/lib/types/services/snapshot/snapshot-server.service.d.ts +57 -0
  14. package/lib/types/services/snapshot/snapshot-transform.d.ts +43 -0
  15. package/lib/types/services/snapshot/snapshot-utils.d.ts +34 -0
  16. package/lib/types/services/undoredo/undoredo.service.d.ts +20 -7
  17. package/lib/types/shared/coder.d.ts +17 -0
  18. package/lib/types/shared/color/color-kit.d.ts +3 -1
  19. package/lib/types/shared/compare.d.ts +1 -0
  20. package/lib/types/shared/index.d.ts +1 -1
  21. package/lib/types/shared/locale.d.ts +2 -1
  22. package/lib/types/shared/object-matrix.d.ts +3 -0
  23. package/lib/types/shared/rxjs.d.ts +20 -0
  24. package/lib/types/shared/tools.d.ts +1 -1
  25. package/lib/types/sheets/__tests__/create-core-test-bed.d.ts +1 -2
  26. package/lib/types/sheets/row-manager.d.ts +0 -2
  27. package/lib/types/sheets/workbook.d.ts +1 -0
  28. package/lib/types/sheets/worksheet.d.ts +7 -9
  29. package/lib/types/types/interfaces/i-cell-data.d.ts +6 -0
  30. package/lib/types/types/interfaces/i-column-data.d.ts +2 -2
  31. package/lib/types/types/interfaces/i-document-data.d.ts +2 -1
  32. package/lib/types/types/interfaces/i-range.d.ts +5 -0
  33. package/lib/types/types/interfaces/i-row-data.d.ts +2 -2
  34. package/lib/types/types/interfaces/i-selection-data.d.ts +6 -0
  35. package/lib/umd/index.js +7 -5
  36. package/package.json +8 -6
@@ -14,7 +14,7 @@
14
14
  * limitations under the License.
15
15
  */
16
16
  import type { ISize } from '../../services/floating-object/floating-object-interfaces';
17
- import type { BooleanNumber, HorizontalAlign, LocaleType, TextDirection, VerticalAlign, WrapStrategy } from '../enum';
17
+ import type { BooleanNumber, CellValueType, HorizontalAlign, LocaleType, TextDirection, VerticalAlign, WrapStrategy } from '../enum';
18
18
  import type { IExtraModelData } from './i-extra-model-data';
19
19
  import type { IColorStyle, IStyleBase } from './i-style-data';
20
20
  /**
@@ -296,6 +296,7 @@ export interface IDocumentRenderConfig {
296
296
  isRotateNonEastAsian?: BooleanNumber;
297
297
  background?: IColorStyle;
298
298
  wrapStrategy?: WrapStrategy;
299
+ cellValueType?: CellValueType;
299
300
  }
300
301
  export interface ISectionBreakBase {
301
302
  columnProperties?: ISectionColumnProperties[];
@@ -86,6 +86,11 @@ export interface IGridRange {
86
86
  sheetId: string;
87
87
  range: IRange;
88
88
  }
89
+ export interface IUnitRangeName {
90
+ unitId: string;
91
+ sheetName: string;
92
+ range: IRange;
93
+ }
89
94
  /**
90
95
  * Range data of Unit
91
96
  */
@@ -21,7 +21,7 @@ export interface IRowData {
21
21
  /**
22
22
  * height in pixel
23
23
  */
24
- h: number;
24
+ h?: number;
25
25
  /**
26
26
  * is current row self-adaptive to its content, use `ah` to set row height when true, else use `h`.
27
27
  */
@@ -33,5 +33,5 @@ export interface IRowData {
33
33
  /**
34
34
  * hidden
35
35
  */
36
- hd: BooleanNumber;
36
+ hd?: BooleanNumber;
37
37
  }
@@ -38,7 +38,13 @@ export interface ISelectionCellWithCoord extends IPosition, ISingleCell {
38
38
  mergeInfo: IRangeWithCoord;
39
39
  }
40
40
  export interface ISelection {
41
+ /**
42
+ * Sheet selection range.
43
+ */
41
44
  range: IRange;
45
+ /**
46
+ * The highlighted cell in the selection range. If there are several selections, only one selection would have a primary cell.
47
+ */
42
48
  primary: Nullable<ISelectionCell>;
43
49
  }
44
50
  export interface ISelectionWithCoord {