@univerjs/core 0.5.3 → 0.5.4-nightly.202501131606
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/index.js +9 -8
- package/lib/es/index.js +10202 -7862
- package/lib/types/common/error.d.ts +3 -0
- package/lib/types/docs/data-model/document-data-model.d.ts +4 -3
- package/lib/types/docs/data-model/rich-text-builder.d.ts +1340 -0
- package/lib/types/docs/data-model/text-x/build-utils/index.d.ts +3 -1
- package/lib/types/docs/data-model/text-x/build-utils/text-x-utils.d.ts +3 -2
- package/lib/types/docs/data-model/text-x/utils.d.ts +48 -1
- package/lib/types/facade/f-blob.d.ts +12 -12
- package/lib/types/facade/f-doc.d.ts +7 -0
- package/lib/types/facade/f-enum.d.ts +51 -0
- package/lib/types/facade/f-event.d.ts +168 -13
- package/lib/types/facade/f-univer.d.ts +95 -20
- package/lib/types/facade/f-usermanager.d.ts +4 -3
- package/lib/types/facade/f-util.d.ts +16 -23
- package/lib/types/index.d.ts +4 -3
- package/lib/types/services/context/context.d.ts +1 -0
- package/lib/types/services/image-io/image-io.service.d.ts +12 -0
- package/lib/types/shared/check-if-move.d.ts +1 -1
- package/lib/types/shared/rectangle.d.ts +267 -12
- package/lib/types/sheets/column-manager.d.ts +3 -1
- package/lib/types/sheets/row-manager.d.ts +3 -1
- package/lib/types/sheets/typedef.d.ts +8 -0
- package/lib/types/sheets/workbook.d.ts +11 -1
- package/lib/types/sheets/worksheet.d.ts +11 -1
- package/lib/types/types/const/const.d.ts +9 -0
- package/lib/types/types/interfaces/i-document-data.d.ts +2 -52
- package/lib/types/types/interfaces/i-drawing.d.ts +93 -0
- package/lib/types/types/interfaces/i-slide-data.d.ts +2 -1
- package/lib/types/types/interfaces/i-style-data.d.ts +12 -0
- package/lib/types/types/interfaces/index.d.ts +1 -0
- package/lib/umd/index.js +9 -8
- package/package.json +3 -3
- package/LICENSE +0 -176
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
import { IAbsoluteTransform } from '../../shared/shape';
|
|
2
|
+
import { Nullable } from '../../shared/types';
|
|
3
|
+
import { BooleanNumber } from '../enum/text-style';
|
|
4
|
+
/**
|
|
5
|
+
* The layer type of Drawing, used to distinguish between forward, backward, front, and back
|
|
6
|
+
*/
|
|
7
|
+
export declare enum ArrangeTypeEnum {
|
|
8
|
+
/**
|
|
9
|
+
* Move the current object one layer up, possibly covering other objects
|
|
10
|
+
*/
|
|
11
|
+
forward = 0,
|
|
12
|
+
/**
|
|
13
|
+
* Move the current object one layer down, possibly being covered by other objects
|
|
14
|
+
*/
|
|
15
|
+
backward = 1,
|
|
16
|
+
/**
|
|
17
|
+
* Move the current object to the top layer
|
|
18
|
+
*/
|
|
19
|
+
front = 2,
|
|
20
|
+
/**
|
|
21
|
+
* Move the current object to the bottom layer
|
|
22
|
+
*/
|
|
23
|
+
back = 3
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Types of drawings, used to distinguish between images, shapes, charts, tables, SmartArt, videos, DrawingGroup, Unit, Dom, etc.
|
|
27
|
+
*/
|
|
28
|
+
export declare enum DrawingTypeEnum {
|
|
29
|
+
/**
|
|
30
|
+
* Unrecognized drawing type, requires user to determine
|
|
31
|
+
*/
|
|
32
|
+
UNRECOGNIZED = -1,
|
|
33
|
+
/**
|
|
34
|
+
* Image
|
|
35
|
+
*/
|
|
36
|
+
DRAWING_IMAGE = 0,
|
|
37
|
+
/**
|
|
38
|
+
* Shape, similar to shapes in Office, including circles, rectangles, lines, etc.
|
|
39
|
+
*/
|
|
40
|
+
DRAWING_SHAPE = 1,
|
|
41
|
+
/**
|
|
42
|
+
* Chart
|
|
43
|
+
*/
|
|
44
|
+
DRAWING_CHART = 2,
|
|
45
|
+
/**
|
|
46
|
+
* Table
|
|
47
|
+
*/
|
|
48
|
+
DRAWING_TABLE = 3,
|
|
49
|
+
/**
|
|
50
|
+
* SmartArt, similar to SmartArt in Office
|
|
51
|
+
*/
|
|
52
|
+
DRAWING_SMART_ART = 4,
|
|
53
|
+
/**
|
|
54
|
+
* Video
|
|
55
|
+
*/
|
|
56
|
+
DRAWING_VIDEO = 5,
|
|
57
|
+
/**
|
|
58
|
+
* Drawing group
|
|
59
|
+
*/
|
|
60
|
+
DRAWING_GROUP = 6,
|
|
61
|
+
/**
|
|
62
|
+
* Univer object, allows inserting images, tables, documents, slides as floating objects into the document
|
|
63
|
+
*/
|
|
64
|
+
DRAWING_UNIT = 7,
|
|
65
|
+
/**
|
|
66
|
+
* Dom element, allows inserting HTML elements as floating objects into the document
|
|
67
|
+
*/
|
|
68
|
+
DRAWING_DOM = 8
|
|
69
|
+
}
|
|
70
|
+
export type DrawingType = DrawingTypeEnum | number;
|
|
71
|
+
export interface IDrawingSpace {
|
|
72
|
+
unitId: string;
|
|
73
|
+
subUnitId: string;
|
|
74
|
+
}
|
|
75
|
+
export interface IDrawingSearch extends IDrawingSpace {
|
|
76
|
+
drawingId: string;
|
|
77
|
+
}
|
|
78
|
+
export interface IRotationSkewFlipTransform {
|
|
79
|
+
angle?: number;
|
|
80
|
+
skewX?: number;
|
|
81
|
+
skewY?: number;
|
|
82
|
+
flipX?: boolean;
|
|
83
|
+
flipY?: boolean;
|
|
84
|
+
}
|
|
85
|
+
export interface ITransformState extends IAbsoluteTransform, IRotationSkewFlipTransform {
|
|
86
|
+
}
|
|
87
|
+
export interface IDrawingParam extends IDrawingSearch {
|
|
88
|
+
drawingType: DrawingType;
|
|
89
|
+
transform?: Nullable<ITransformState>;
|
|
90
|
+
transforms?: Nullable<ITransformState[]>;
|
|
91
|
+
isMultiTransform?: BooleanNumber;
|
|
92
|
+
groupId?: string;
|
|
93
|
+
}
|
|
@@ -3,7 +3,8 @@ import { IKeyType, Nullable } from '../../shared/types';
|
|
|
3
3
|
import { IWorksheetData } from '../../sheets/typedef';
|
|
4
4
|
import { LocaleType, ThemeColorType } from '../enum';
|
|
5
5
|
import { ShapeType } from '../enum/prst-geom-type';
|
|
6
|
-
import { ICustomBlock, IDocumentData, ILists
|
|
6
|
+
import { ICustomBlock, IDocumentData, ILists } from './i-document-data';
|
|
7
|
+
import { ITransformState } from './i-drawing';
|
|
7
8
|
import { IImageProperties } from './i-image-properties';
|
|
8
9
|
import { IPlaceholder } from './i-placeholder';
|
|
9
10
|
import { IShapeProperties } from './i-shape-properties';
|
|
@@ -6,9 +6,21 @@ import { ThemeColorType } from '../enum/theme-color-type';
|
|
|
6
6
|
* Properties of text decoration
|
|
7
7
|
*/
|
|
8
8
|
export interface ITextDecoration {
|
|
9
|
+
/**
|
|
10
|
+
* show
|
|
11
|
+
*/
|
|
9
12
|
s: BooleanNumber;
|
|
13
|
+
/**
|
|
14
|
+
* color is follow the font color. the default value is TRUE, it's also TRUE if it is undefined. the cl has no effect when `c` is TRUE.
|
|
15
|
+
*/
|
|
10
16
|
c?: BooleanNumber;
|
|
17
|
+
/**
|
|
18
|
+
* color
|
|
19
|
+
*/
|
|
11
20
|
cl?: IColorStyle;
|
|
21
|
+
/**
|
|
22
|
+
* lineType
|
|
23
|
+
*/
|
|
12
24
|
t?: TextDecoration;
|
|
13
25
|
}
|
|
14
26
|
/**
|