modern-idoc 0.1.4 → 0.2.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.
package/dist/index.cjs CHANGED
@@ -1,28 +1,65 @@
1
1
  'use strict';
2
2
 
3
- function getDefaultElementStyle() {
3
+ function getDefaultLayoutStyle() {
4
4
  return {
5
5
  overflow: "visible",
6
- visibility: "visible",
7
- filter: "none",
8
- // position
9
- left: 0,
10
- top: 0,
11
- width: 0,
12
- height: 0,
13
- rotate: 0,
14
- opacity: 1,
15
- // margin
16
- marginLeft: 0,
6
+ alignContent: "stretch",
7
+ alignItems: "stretch",
8
+ alignSelf: "auto",
9
+ borderTop: "none",
10
+ borderLeft: "none",
11
+ borderRight: "none",
12
+ borderBottom: "none",
13
+ borderWidth: 0,
14
+ border: "none",
15
+ direction: "inherit",
16
+ display: "flex",
17
+ flex: 0,
18
+ flexBasis: "auto",
19
+ flexDirection: "row",
20
+ flexGrow: 0,
21
+ flexShrink: 1,
22
+ flexWrap: "nowrap",
23
+ height: "auto",
24
+ justifyContent: "flex-start",
25
+ gap: 0,
17
26
  marginTop: 0,
27
+ marginLeft: 0,
18
28
  marginRight: 0,
19
29
  marginBottom: 0,
20
- // padding
21
- paddingLeft: 0,
30
+ margin: 0,
31
+ maxHeight: 0,
32
+ maxWidth: 0,
33
+ minHeight: 0,
34
+ minWidth: 0,
22
35
  paddingTop: 0,
36
+ paddingLeft: 0,
23
37
  paddingRight: 0,
24
38
  paddingBottom: 0,
25
- // transform
39
+ padding: 0,
40
+ top: 0,
41
+ bottom: 0,
42
+ left: 0,
43
+ right: 0,
44
+ position: "static",
45
+ boxSizing: "content-box",
46
+ width: "auto"
47
+ };
48
+ }
49
+
50
+ function getDefaultShadowStyle() {
51
+ return {
52
+ shadowColor: "transparent",
53
+ shadowOffsetX: 0,
54
+ shadowOffsetY: 0,
55
+ shadowBlur: 0,
56
+ boxShadow: "none"
57
+ };
58
+ }
59
+
60
+ function getDefaultTransformStyle() {
61
+ return {
62
+ rotate: 0,
26
63
  scaleX: 1,
27
64
  scaleY: 1,
28
65
  skewX: 0,
@@ -30,19 +67,24 @@ function getDefaultElementStyle() {
30
67
  translateX: 0,
31
68
  translateY: 0,
32
69
  transform: "none",
33
- transformOrigin: "50% 50%",
70
+ transformOrigin: "center"
71
+ };
72
+ }
73
+
74
+ function getDefaultElementStyle() {
75
+ return {
76
+ ...getDefaultTransformStyle(),
77
+ ...getDefaultLayoutStyle(),
78
+ ...getDefaultShadowStyle(),
79
+ visibility: "visible",
80
+ filter: "none",
81
+ opacity: 1,
34
82
  // background
35
83
  backgroundImage: "none",
36
84
  backgroundColor: "transparent",
37
- // shadow
38
- shadowColor: "transparent",
39
- shadowOffsetX: 0,
40
- shadowOffsetY: 0,
41
- shadowBlur: 0,
42
85
  // border
43
86
  borderRadius: 0,
44
- borderColor: "transparent",
45
- borderWidth: 1
87
+ borderColor: "transparent"
46
88
  };
47
89
  }
48
90
 
@@ -83,21 +125,7 @@ function getDefaultTextStyle() {
83
125
  highlightColormap: "none",
84
126
  highlightLine: "none",
85
127
  highlightSize: "cover",
86
- highlightThickness: "100%",
87
- // transform
88
- scaleX: 1,
89
- scaleY: 1,
90
- skewX: 0,
91
- skewY: 0,
92
- translateX: 0,
93
- translateY: 0,
94
- transform: "none",
95
- transformOrigin: "50% 50%",
96
- // shadow
97
- shadowColor: "transparent",
98
- shadowOffsetX: 0,
99
- shadowOffsetY: 0,
100
- shadowBlur: 0
128
+ highlightThickness: "100%"
101
129
  };
102
130
  }
103
131
 
@@ -262,8 +290,10 @@ function normalizeElement(element) {
262
290
  }
263
291
 
264
292
  exports.getDefaultElementStyle = getDefaultElementStyle;
293
+ exports.getDefaultShadowStyle = getDefaultShadowStyle;
265
294
  exports.getDefaultStyle = getDefaultStyle;
266
295
  exports.getDefaultTextStyle = getDefaultTextStyle;
296
+ exports.getDefaultTransformStyle = getDefaultTransformStyle;
267
297
  exports.normalizeElement = normalizeElement;
268
298
  exports.normalizeFill = normalizeFill;
269
299
  exports.normalizeGeometry = normalizeGeometry;
package/dist/index.d.cts CHANGED
@@ -1,19 +1,14 @@
1
- interface IDOCFillDeclaration {
2
- url?: string;
1
+ interface FillDeclaration {
2
+ image?: string;
3
3
  color?: string;
4
4
  opacity?: number;
5
5
  }
6
6
 
7
- type Noneable = 'none';
8
- type Sizeable = `${number}%` | `${number}rem` | number;
9
-
10
- type IDOCFillProp = Noneable | string | IDOCFillDeclaration;
11
-
12
7
  type SVGPathData = string;
13
8
  type FillRule = 'nonzero' | 'evenodd';
14
9
  type StrokeLinecap = 'butt' | 'round' | 'square';
15
10
  type StrokeLinejoin = 'arcs' | 'bevel' | 'miter' | 'miter-clip' | 'round';
16
- interface IDOCPath2DStyle {
11
+ interface Path2DStyle {
17
12
  [key: string]: any;
18
13
  opacity: number;
19
14
  visibility: string;
@@ -33,39 +28,46 @@ interface IDOCPath2DStyle {
33
28
  strokeDasharray: number[];
34
29
  strokeDashoffset: number;
35
30
  }
36
- interface IDOCPath2D extends Partial<IDOCPath2DStyle> {
31
+ interface Path2DDeclaration extends Partial<Path2DStyle> {
37
32
  data: SVGPathData;
38
33
  }
39
- interface IDOCGeometryDeclaration {
40
- data: IDOCPath2D[];
34
+ interface GeometryDeclaration {
35
+ data: Path2DDeclaration[];
41
36
  }
42
37
 
43
- type IDOCGeometryProp = Noneable | SVGPathData | SVGPathData[] | IDOCPath2D[] | IDOCGeometryDeclaration;
38
+ type Noneable = 'none';
39
+ type Sizeable = `${number}%` | `${number}rem` | number;
44
40
 
45
- interface IDOCImageDeclaration {
46
- url: string;
47
- opacity?: number;
48
- }
41
+ type FillProp = Noneable | string | FillDeclaration;
49
42
 
50
- type IDOCImageProp = Noneable | string | IDOCImageDeclaration;
43
+ type GeometryProp = Noneable | SVGPathData | SVGPathData[] | Path2DDeclaration[] | GeometryDeclaration;
51
44
 
52
- interface IDOCMetaProp {
45
+ interface MetaProp {
53
46
  [key: string]: any;
54
47
  }
55
48
 
56
49
  interface IDOCNode {
57
50
  name?: string;
58
51
  children?: IDOCNode[];
59
- meta?: IDOCMetaProp;
52
+ meta?: MetaProp;
60
53
  }
61
54
 
62
- interface IDOCStrokeDeclaration {
63
- url?: string;
55
+ interface ImageDeclaration {
56
+ url: string;
57
+ opacity?: number;
58
+ }
59
+
60
+ type ImageProp = Noneable | string | ImageDeclaration;
61
+
62
+ interface StrokeDeclaration {
63
+ width?: number;
64
+ style?: 'dashed' | 'solid' | string;
65
+ image?: string;
64
66
  color?: string;
65
67
  opacity?: number;
66
68
  }
67
69
 
68
- type IDOCStrokeProp = Noneable | string | IDOCStrokeDeclaration;
70
+ type StrokeProp = Noneable | string | StrokeDeclaration;
69
71
 
70
72
  type Overflow = 'hidden' | 'visible';
71
73
  type Visibility = 'hidden' | 'visible';
@@ -79,63 +81,87 @@ type TextOrientation = 'mixed' | 'upright' | 'sideways-right' | 'sideways';
79
81
  type TextDecoration = Noneable | 'underline' | 'line-through' | 'overline';
80
82
  type VerticalAlign = 'baseline' | 'top' | 'middle' | 'bottom' | 'sub' | 'super' | 'text-top' | 'text-bottom';
81
83
  type WritingMode = 'horizontal-tb' | 'vertical-lr' | 'vertical-rl';
84
+ type Align = 'auto' | 'flex-start' | 'center' | 'flex-end' | 'stretch' | 'baseline' | 'space-between' | 'space-around' | 'space-evenly';
85
+ type FlexDirection = 'column' | 'column-reverse' | 'row' | 'row-reverse';
86
+ type FlexWrap = 'nowrap' | 'wrap' | 'Wrap-reverse';
87
+ type Justify = 'flex-start' | 'center' | 'flex-end' | 'space-between' | 'space-around' | 'space-evenly';
88
+ type Position = 'static' | 'relative' | 'absolute';
89
+ type BoxSizing = 'border-box' | 'content-box';
82
90
  type ListStyleType = Noneable | 'disc';
83
91
  type ListStyleImage = Noneable | string;
84
92
  type ListStyleColormap = Noneable | Record<string, string>;
85
93
  type ListStyleSize = Sizeable | 'cover';
86
94
  type ListStylePosition = 'inside' | 'outside';
87
- interface IDOCListStyleDeclaration {
88
- type: ListStyleType;
89
- image: ListStyleImage;
90
- colormap: ListStyleColormap;
91
- size: ListStyleSize;
92
- position: ListStylePosition;
93
- }
94
- interface IDOCListStyleStyleDeclaration {
95
- listStyle?: Partial<IDOCListStyleDeclaration>;
96
- listStyleType: ListStyleType;
97
- listStyleImage: ListStyleImage;
98
- listStyleColormap: ListStyleColormap;
99
- listStyleSize: ListStyleSize;
100
- listStylePosition: ListStylePosition;
101
- }
102
95
  type HighlightLine = TextDecoration | 'outline';
103
96
  type HighlightImage = Noneable | string;
104
97
  type HighlightReferImage = Noneable | string;
105
98
  type HighlightColormap = Noneable | Record<string, string>;
106
99
  type HighlightSize = Sizeable | 'cover';
107
100
  type HighlightThickness = Sizeable;
108
- interface IDOCHighlightDeclaration {
109
- image: HighlightImage;
110
- referImage: HighlightReferImage;
111
- colormap: HighlightColormap;
112
- line: HighlightLine;
113
- size: HighlightSize;
114
- thickness: HighlightThickness;
115
- }
116
- interface IDOCHighlightStyleDeclaration {
117
- highlight?: Partial<IDOCHighlightDeclaration>;
118
- highlightImage: HighlightImage;
119
- highlightReferImage: HighlightReferImage;
120
- highlightColormap: HighlightColormap;
121
- highlightLine: HighlightLine;
122
- highlightSize: HighlightSize;
123
- highlightThickness: HighlightThickness;
101
+
102
+ interface LayoutStyleDeclaration {
103
+ overflow: Overflow;
104
+ alignContent: Align;
105
+ alignItems: Align;
106
+ alignSelf: Align;
107
+ borderTop: string;
108
+ borderLeft: string;
109
+ borderRight: string;
110
+ borderBottom: string;
111
+ borderWidth: number;
112
+ border: string;
113
+ direction: 'inherit' | 'ltr' | 'rtl';
114
+ display: 'none' | 'flex' | 'contents';
115
+ flex: number;
116
+ flexBasis: number | 'auto' | `${number}%`;
117
+ flexDirection: FlexDirection;
118
+ flexGrow: number;
119
+ flexShrink: number;
120
+ flexWrap: FlexWrap;
121
+ height: number | 'auto' | `${number}%`;
122
+ justifyContent: Justify;
123
+ gap: number | `${number}%`;
124
+ marginTop: number | 'auto' | `${number}%`;
125
+ marginLeft: number | 'auto' | `${number}%`;
126
+ marginRight: number | 'auto' | `${number}%`;
127
+ marginBottom: number | 'auto' | `${number}%`;
128
+ margin: number | 'auto' | `${number}%`;
129
+ maxHeight: number | `${number}%`;
130
+ maxWidth: number | `${number}%`;
131
+ minHeight: number | `${number}%`;
132
+ minWidth: number | `${number}%`;
133
+ paddingTop: number | `${number}%`;
134
+ paddingLeft: number | `${number}%`;
135
+ paddingRight: number | `${number}%`;
136
+ paddingBottom: number | `${number}%`;
137
+ padding: number | `${number}%`;
138
+ top: number | `${number}%`;
139
+ bottom: number | `${number}%`;
140
+ left: number | `${number}%`;
141
+ right: number | `${number}%`;
142
+ position: Position;
143
+ boxSizing: BoxSizing;
144
+ width: number | 'auto' | `${number}%`;
124
145
  }
125
- interface IDCOShadowDeclaration {
146
+
147
+ interface ShadowDeclaration {
126
148
  color: string;
127
149
  offsetX: number;
128
150
  offsetY: number;
129
151
  blur: number;
130
152
  }
131
- interface IDOCShadowStyleDeclaration {
132
- shadow?: Partial<IDCOShadowDeclaration>;
153
+
154
+ interface ShadowStyleDeclaration {
155
+ shadow?: Partial<ShadowDeclaration>;
133
156
  shadowColor: string;
134
157
  shadowOffsetX: number;
135
158
  shadowOffsetY: number;
136
159
  shadowBlur: number;
160
+ boxShadow: 'none' | string;
137
161
  }
138
- interface IDOCTransformStyleDeclaration {
162
+
163
+ interface TransformStyleDeclaration {
164
+ rotate: number;
139
165
  scaleX: number;
140
166
  scaleY: number;
141
167
  skewX: number;
@@ -145,14 +171,54 @@ interface IDOCTransformStyleDeclaration {
145
171
  transform: string;
146
172
  transformOrigin: string;
147
173
  }
148
- interface IDOCTextLineStyleDeclaration extends IDOCListStyleStyleDeclaration {
149
- writingMode: WritingMode;
150
- textWrap: TextWrap;
151
- textAlign: TextAlign;
152
- textIndent: number;
153
- lineHeight: number;
174
+
175
+ interface ElementStyleDeclaration extends LayoutStyleDeclaration, TransformStyleDeclaration, ShadowStyleDeclaration {
176
+ visibility: Visibility;
177
+ filter: string;
178
+ opacity: number;
179
+ backgroundImage: string;
180
+ backgroundColor: string;
181
+ borderRadius: number;
182
+ borderColor: string;
154
183
  }
155
- interface IDOCTextInlineStyleDeclaration extends IDOCHighlightStyleDeclaration {
184
+
185
+ interface HighlightDeclaration {
186
+ image: HighlightImage;
187
+ referImage: HighlightReferImage;
188
+ colormap: HighlightColormap;
189
+ line: HighlightLine;
190
+ size: HighlightSize;
191
+ thickness: HighlightThickness;
192
+ }
193
+
194
+ interface HighlightStyleDeclaration {
195
+ highlight?: Partial<HighlightDeclaration>;
196
+ highlightImage: HighlightImage;
197
+ highlightReferImage: HighlightReferImage;
198
+ highlightColormap: HighlightColormap;
199
+ highlightLine: HighlightLine;
200
+ highlightSize: HighlightSize;
201
+ highlightThickness: HighlightThickness;
202
+ }
203
+
204
+ interface ListStyleDeclaration {
205
+ type: ListStyleType;
206
+ image: ListStyleImage;
207
+ colormap: ListStyleColormap;
208
+ size: ListStyleSize;
209
+ position: ListStylePosition;
210
+ }
211
+
212
+ interface ListStyleStyleDeclaration {
213
+ listStyle?: Partial<ListStyleDeclaration>;
214
+ listStyleType: ListStyleType;
215
+ listStyleImage: ListStyleImage;
216
+ listStyleColormap: ListStyleColormap;
217
+ listStyleSize: ListStyleSize;
218
+ listStylePosition: ListStylePosition;
219
+ }
220
+
221
+ interface TextInlineStyleDeclaration extends HighlightStyleDeclaration {
156
222
  color: string;
157
223
  verticalAlign: VerticalAlign;
158
224
  letterSpacing: number;
@@ -166,113 +232,103 @@ interface IDOCTextInlineStyleDeclaration extends IDOCHighlightStyleDeclaration {
166
232
  textOrientation: TextOrientation;
167
233
  textDecoration: TextDecoration;
168
234
  }
169
- interface IDOCTextDrawStyleDeclaration extends IDOCShadowStyleDeclaration, IDOCTransformStyleDeclaration {
235
+
236
+ interface TextLineStyleDeclaration extends ListStyleStyleDeclaration {
237
+ writingMode: WritingMode;
238
+ textWrap: TextWrap;
239
+ textAlign: TextAlign;
240
+ textIndent: number;
241
+ lineHeight: number;
242
+ }
243
+
244
+ interface TextDrawStyleDeclaration {
170
245
  textStrokeWidth: number;
171
246
  textStrokeColor: string;
172
247
  }
173
- interface IDOCTextStyleDeclaration extends IDOCTextLineStyleDeclaration, IDOCTextInlineStyleDeclaration, IDOCTextDrawStyleDeclaration {
174
- }
175
- interface IDOCElementStyleDeclaration extends IDOCShadowStyleDeclaration, IDOCTransformStyleDeclaration {
176
- overflow: Overflow;
177
- visibility: Visibility;
178
- filter: string;
179
- left: number;
180
- top: number;
181
- width: number;
182
- height: number;
183
- rotate: number;
184
- opacity: number;
185
- marginLeft: number;
186
- marginTop: number;
187
- marginRight: number;
188
- marginBottom: number;
189
- paddingLeft: number;
190
- paddingTop: number;
191
- paddingRight: number;
192
- paddingBottom: number;
193
- backgroundImage: string;
194
- backgroundColor: string;
195
- borderRadius: number;
196
- borderColor: string;
197
- borderWidth: number;
248
+ interface TextStyleDeclaration extends TextLineStyleDeclaration, TextInlineStyleDeclaration, TextDrawStyleDeclaration {
198
249
  }
199
- interface IDOCStyleDeclaration extends IDOCTextStyleDeclaration, IDOCElementStyleDeclaration {
250
+
251
+ interface StyleDeclaration extends TextStyleDeclaration, ElementStyleDeclaration {
200
252
  }
201
253
 
202
- type IDOCStyleProp = Partial<IDOCStyleDeclaration>;
254
+ type StyleProp = Partial<StyleDeclaration>;
203
255
 
204
- interface IDOCFragmentContent extends Partial<IDOCStyleDeclaration> {
256
+ interface FragmentContent extends Partial<StyleDeclaration> {
205
257
  content: string;
206
258
  }
207
- interface IDOCParagraphContent extends Partial<IDOCStyleDeclaration> {
208
- fragments: IDOCFragmentContent[];
259
+ interface ParagraphContent extends Partial<StyleDeclaration> {
260
+ fragments: FragmentContent[];
209
261
  }
210
- type IDOCTextContentFlat = string | IDOCFragmentContent | IDOCParagraphContent | (string | IDOCFragmentContent)[];
211
- type IDOCTextContent = string | IDOCFragmentContent | IDOCParagraphContent | IDOCTextContentFlat[];
212
- type IDOCTextContentDeclaration = IDOCParagraphContent[];
213
- interface IDOCTextDeclaration {
214
- content: IDOCTextContentDeclaration;
215
- effects?: Partial<IDOCStyleDeclaration>[];
262
+ type TextContentFlat = string | FragmentContent | ParagraphContent | (string | FragmentContent)[];
263
+ type TextContent = string | FragmentContent | ParagraphContent | TextContentFlat[];
264
+ type TextContentDeclaration = ParagraphContent[];
265
+ interface TextDeclaration {
266
+ content: TextContentDeclaration;
267
+ effects?: Partial<StyleDeclaration>[];
216
268
  measureDom?: any;
217
269
  fonts?: any;
218
270
  }
219
271
 
220
- type IDOCTextProp = string | IDOCTextContent | (IDOCTextDeclaration & {
221
- content: IDOCTextContent;
222
- }) | IDOCTextDeclaration;
272
+ type TextProp = string | TextContent | (TextDeclaration & {
273
+ content: TextContent;
274
+ }) | TextDeclaration;
223
275
 
224
- interface IDOCVideoDeclaration {
276
+ interface VideoDeclaration {
225
277
  url: string;
226
278
  opacity?: number;
227
279
  }
228
280
 
229
- type IDOCVideoProp = Noneable | string | IDOCVideoDeclaration;
281
+ type VideoProp = Noneable | string | VideoDeclaration;
230
282
 
231
283
  interface IDOCElement extends IDOCNode {
232
- style?: IDOCStyleProp;
233
- image?: IDOCImageProp;
234
- video?: IDOCVideoProp;
235
- text?: IDOCTextProp;
236
- geometry?: IDOCGeometryProp;
237
- fill?: IDOCFillProp;
238
- stroke?: IDOCStrokeProp;
284
+ style?: StyleProp;
285
+ image?: ImageProp;
286
+ video?: VideoProp;
287
+ text?: TextProp;
288
+ geometry?: GeometryProp;
289
+ fill?: FillProp;
290
+ stroke?: StrokeProp;
239
291
  children?: IDOCElement[];
240
292
  }
241
293
 
294
+ interface ElementDeclaration extends IDOCElement {
295
+ image?: ImageDeclaration;
296
+ video?: VideoDeclaration;
297
+ text?: TextDeclaration;
298
+ geometry?: GeometryDeclaration;
299
+ fill?: FillDeclaration;
300
+ stroke?: StrokeDeclaration;
301
+ children?: ElementDeclaration[];
302
+ }
303
+
242
304
  interface IDOCDocument extends IDOCElement {
243
305
  fonts?: any;
244
306
  }
245
307
 
246
- interface IDOCElementDeclaration extends IDOCElement {
247
- image?: IDOCImageDeclaration;
248
- video?: IDOCVideoDeclaration;
249
- text?: IDOCTextDeclaration;
250
- geometry?: IDOCGeometryDeclaration;
251
- fill?: IDOCFillDeclaration;
252
- stroke?: IDOCStrokeDeclaration;
253
- children?: IDOCElementDeclaration[];
254
- }
308
+ declare function getDefaultElementStyle(): ElementStyleDeclaration;
309
+
310
+ declare function getDefaultShadowStyle(): ShadowStyleDeclaration;
255
311
 
256
- declare function getDefaultElementStyle(): IDOCElementStyleDeclaration;
312
+ declare function getDefaultStyle(): StyleDeclaration;
257
313
 
258
- declare function getDefaultStyle(): IDOCStyleDeclaration;
314
+ declare function getDefaultTextStyle(): TextStyleDeclaration;
259
315
 
260
- declare function getDefaultTextStyle(): IDOCTextStyleDeclaration;
316
+ declare function getDefaultTransformStyle(): TransformStyleDeclaration;
261
317
 
262
- declare function normalizeElement(element: IDOCElement): IDOCElementDeclaration;
318
+ declare function normalizeElement(element: IDOCElement): ElementDeclaration;
263
319
 
264
- declare function normalizeFill(fill?: IDOCFillProp): IDOCFillDeclaration | undefined;
320
+ declare function normalizeFill(fill?: FillProp): FillDeclaration | undefined;
265
321
 
266
- declare function normalizeGeometry(geometry?: IDOCGeometryProp): IDOCGeometryDeclaration | undefined;
322
+ declare function normalizeGeometry(geometry?: GeometryProp): GeometryDeclaration | undefined;
267
323
 
268
- declare function normalizeImage(image?: IDOCImageProp): IDOCImageDeclaration | undefined;
324
+ declare function normalizeImage(image?: ImageProp): ImageDeclaration | undefined;
269
325
 
270
- declare function normalizeStroke(stroke?: IDOCStrokeProp): IDOCStrokeDeclaration | undefined;
326
+ declare function normalizeStroke(stroke?: StrokeProp): StrokeDeclaration | undefined;
271
327
 
272
- declare function normalizeText(text?: IDOCTextProp): IDOCTextDeclaration | undefined;
328
+ declare function normalizeText(text?: TextProp): TextDeclaration | undefined;
273
329
 
274
- declare function normalizeTextContent(content?: IDOCTextContent): IDOCTextContentDeclaration;
330
+ declare function normalizeTextContent(content?: TextContent): TextContentDeclaration;
275
331
 
276
- declare function normalizeVideo(video?: IDOCVideoProp): IDOCVideoDeclaration | undefined;
332
+ declare function normalizeVideo(video?: VideoProp): VideoDeclaration | undefined;
277
333
 
278
- export { type FillRule, type FontKerning, type FontStyle, type FontWeight, type HighlightColormap, type HighlightImage, type HighlightLine, type HighlightReferImage, type HighlightSize, type HighlightThickness, type IDCOShadowDeclaration, type IDOCDocument, type IDOCElement, type IDOCElementDeclaration, type IDOCElementStyleDeclaration, type IDOCFillDeclaration, type IDOCFillProp, type IDOCFragmentContent, type IDOCGeometryDeclaration, type IDOCGeometryProp, type IDOCHighlightDeclaration, type IDOCHighlightStyleDeclaration, type IDOCImageDeclaration, type IDOCImageProp, type IDOCListStyleDeclaration, type IDOCListStyleStyleDeclaration, type IDOCMetaProp, type IDOCNode, type IDOCParagraphContent, type IDOCPath2D, type IDOCPath2DStyle, type IDOCShadowStyleDeclaration, type IDOCStrokeDeclaration, type IDOCStrokeProp, type IDOCStyleDeclaration, type IDOCStyleProp, type IDOCTextContent, type IDOCTextContentDeclaration, type IDOCTextContentFlat, type IDOCTextDeclaration, type IDOCTextDrawStyleDeclaration, type IDOCTextInlineStyleDeclaration, type IDOCTextLineStyleDeclaration, type IDOCTextProp, type IDOCTextStyleDeclaration, type IDOCTransformStyleDeclaration, type IDOCVideoDeclaration, type IDOCVideoProp, type ListStyleColormap, type ListStyleImage, type ListStylePosition, type ListStyleSize, type ListStyleType, type Overflow, type SVGPathData, type StrokeLinecap, type StrokeLinejoin, type TextAlign, type TextDecoration, type TextOrientation, type TextTransform, type TextWrap, type VerticalAlign, type Visibility, type WritingMode, getDefaultElementStyle, getDefaultStyle, getDefaultTextStyle, normalizeElement, normalizeFill, normalizeGeometry, normalizeImage, normalizeStroke, normalizeText, normalizeTextContent, normalizeVideo };
334
+ export { type ElementDeclaration, type ElementStyleDeclaration, type FillDeclaration, type FillProp, type FillRule, type FragmentContent, type GeometryDeclaration, type GeometryProp, type HighlightDeclaration, type HighlightStyleDeclaration, type IDOCDocument, type IDOCElement, type IDOCNode, type ImageDeclaration, type ImageProp, type LayoutStyleDeclaration, type ListStyleDeclaration, type ListStyleStyleDeclaration, type MetaProp, type ParagraphContent, type Path2DDeclaration, type Path2DStyle, type SVGPathData, type ShadowDeclaration, type ShadowStyleDeclaration, type StrokeDeclaration, type StrokeLinecap, type StrokeLinejoin, type StrokeProp, type StyleDeclaration, type StyleProp, type TextContent, type TextContentDeclaration, type TextContentFlat, type TextDeclaration, type TextDrawStyleDeclaration, type TextInlineStyleDeclaration, type TextLineStyleDeclaration, type TextProp, type TextStyleDeclaration, type TransformStyleDeclaration, type VideoDeclaration, type VideoProp, getDefaultElementStyle, getDefaultShadowStyle, getDefaultStyle, getDefaultTextStyle, getDefaultTransformStyle, normalizeElement, normalizeFill, normalizeGeometry, normalizeImage, normalizeStroke, normalizeText, normalizeTextContent, normalizeVideo };