@hailin-zheng/editor-core 1.0.23 → 1.0.26
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/package.json +3 -5
- package/lib/doc-ruler.d.ts +0 -51
- package/lib/framework/common-util.d.ts +0 -63
- package/lib/framework/document-change.d.ts +0 -265
- package/lib/framework/document-combine.d.ts +0 -24
- package/lib/framework/document-comment.d.ts +0 -46
- package/lib/framework/document-context.d.ts +0 -149
- package/lib/framework/document-eval-func.d.ts +0 -18
- package/lib/framework/document-event.d.ts +0 -213
- package/lib/framework/document-history.d.ts +0 -26
- package/lib/framework/document-images-loader.d.ts +0 -16
- package/lib/framework/document-input-cursor.d.ts +0 -78
- package/lib/framework/document-paint.d.ts +0 -34
- package/lib/framework/document-print-offscreen.d.ts +0 -38
- package/lib/framework/document-print.d.ts +0 -60
- package/lib/framework/document-segmenter.d.ts +0 -2
- package/lib/framework/document-selection.d.ts +0 -89
- package/lib/framework/document-template.d.ts +0 -4
- package/lib/framework/document-textline-mode.d.ts +0 -7
- package/lib/framework/element-define.d.ts +0 -319
- package/lib/framework/element-event-define.d.ts +0 -98
- package/lib/framework/element-measure.d.ts +0 -97
- package/lib/framework/element-paint.d.ts +0 -42
- package/lib/framework/element-props.d.ts +0 -301
- package/lib/framework/element-reader.d.ts +0 -19
- package/lib/framework/element-render-cut.d.ts +0 -55
- package/lib/framework/element-serialize.d.ts +0 -30
- package/lib/framework/element-util.d.ts +0 -369
- package/lib/framework/impl/checkbox/checkbox-impl.d.ts +0 -24
- package/lib/framework/impl/comments/comment-content-impl.d.ts +0 -40
- package/lib/framework/impl/comments/comment-element-impl.d.ts +0 -21
- package/lib/framework/impl/comments/comments-container-impl.d.ts +0 -22
- package/lib/framework/impl/comments/comments-util.d.ts +0 -12
- package/lib/framework/impl/comments/validate-msg-impl.d.ts +0 -21
- package/lib/framework/impl/data-element/data-decorate-impl.d.ts +0 -30
- package/lib/framework/impl/data-element/data-element-barcode.d.ts +0 -31
- package/lib/framework/impl/data-element/data-element-base-impl.d.ts +0 -68
- package/lib/framework/impl/data-element/data-element-check-impl.d.ts +0 -35
- package/lib/framework/impl/data-element/data-element-date-impl.d.ts +0 -23
- package/lib/framework/impl/data-element/data-element-group-impl.d.ts +0 -23
- package/lib/framework/impl/data-element/data-element-image-impl.d.ts +0 -30
- package/lib/framework/impl/data-element/data-element-list-impl.d.ts +0 -22
- package/lib/framework/impl/data-element/data-element-text-impl.d.ts +0 -23
- package/lib/framework/impl/decorate/fill-null-space-imple.d.ts +0 -21
- package/lib/framework/impl/document/doc-body-impl.d.ts +0 -27
- package/lib/framework/impl/document/doc-body-part-impl.d.ts +0 -30
- package/lib/framework/impl/document/doc-container-impl.d.ts +0 -16
- package/lib/framework/impl/document/doc-footer-impl.d.ts +0 -26
- package/lib/framework/impl/document/doc-header-impl.d.ts +0 -26
- package/lib/framework/impl/document/doc-impl.d.ts +0 -61
- package/lib/framework/impl/index.d.ts +0 -36
- package/lib/framework/impl/media-formula/menstrual-history.d.ts +0 -35
- package/lib/framework/impl/paragraph/p-impl.d.ts +0 -45
- package/lib/framework/impl/picture/image-impl.d.ts +0 -31
- package/lib/framework/impl/radio/radio-impl.d.ts +0 -22
- package/lib/framework/impl/symbol/br-symbol-impl.d.ts +0 -22
- package/lib/framework/impl/symbol/p-symbol-impl.d.ts +0 -19
- package/lib/framework/impl/table/table-cell-impl.d.ts +0 -37
- package/lib/framework/impl/table/table-impl.d.ts +0 -55
- package/lib/framework/impl/table/table-row-impl.d.ts +0 -26
- package/lib/framework/impl/table/table-split-cell-patch.d.ts +0 -20
- package/lib/framework/impl/table/table-split-cell.d.ts +0 -90
- package/lib/framework/impl/table/table-util.d.ts +0 -150
- package/lib/framework/impl/text/text-impl.d.ts +0 -32
- package/lib/framework/impl/text/track-run-impl.d.ts +0 -27
- package/lib/framework/notify.d.ts +0 -13
- package/lib/framework/range-util.d.ts +0 -40
- package/lib/framework/render-context.d.ts +0 -91
- package/lib/framework/render-define.d.ts +0 -109
- package/lib/framework/selection-overlays.d.ts +0 -30
- package/lib/index.d.ts +0 -34
- package/lib/index.js +0 -15672
- package/lib/texteditor.d.ts +0 -318
- package/lib/util/subject.d.ts +0 -34
- package/lib/util/table-bind.d.ts +0 -5
@@ -1,301 +0,0 @@
|
|
1
|
-
import { NullableType, OrientType, PaddingProps, TextAlign, ViewOptions } from "./element-define";
|
2
|
-
import { TrackRunTypeEnum } from "./impl/text/track-run-impl";
|
3
|
-
export declare type TextVertAlign = 'superscript' | 'subscript';
|
4
|
-
export declare abstract class INotifyPropertyChanged {
|
5
|
-
abstract getSerializeProps(viewOptions: ViewOptions): any;
|
6
|
-
private __attatchProperty;
|
7
|
-
registerProperty<T>(propertyName: string, value: T): void;
|
8
|
-
removeProperty(propertyName: string): void;
|
9
|
-
getProperty<T>(propertyName: string): T;
|
10
|
-
}
|
11
|
-
export declare class TextProps extends INotifyPropertyChanged {
|
12
|
-
constructor();
|
13
|
-
color: string;
|
14
|
-
fontName: string;
|
15
|
-
fontSize: number;
|
16
|
-
fontWeight: 'normal' | 'bold';
|
17
|
-
fontStyle: 'normal' | 'italic';
|
18
|
-
underline: boolean;
|
19
|
-
overline: boolean;
|
20
|
-
linethrough: boolean;
|
21
|
-
background: string;
|
22
|
-
letterSpace: number;
|
23
|
-
/**
|
24
|
-
* 上标或者下标
|
25
|
-
*/
|
26
|
-
vertAlign: TextVertAlign;
|
27
|
-
/**
|
28
|
-
* 字符边框
|
29
|
-
*/
|
30
|
-
border: boolean;
|
31
|
-
clearCache(): void;
|
32
|
-
clone(source: TextProps | null): TextProps;
|
33
|
-
setPropsValue(source: TextProps, target: TextProps): void;
|
34
|
-
getSerializeProps(viewOptions: ViewOptions): any;
|
35
|
-
private __cacheFont;
|
36
|
-
getFont(): string;
|
37
|
-
equals(props: TextProps): boolean;
|
38
|
-
}
|
39
|
-
export declare class ParagraphProps extends INotifyPropertyChanged {
|
40
|
-
textProps: TextProps;
|
41
|
-
indent: number;
|
42
|
-
hanging: number;
|
43
|
-
lineHeight: number;
|
44
|
-
textAlign: TextAlign;
|
45
|
-
numberType: number;
|
46
|
-
pageBreak: boolean;
|
47
|
-
clone(dest?: ParagraphProps | null): ParagraphProps;
|
48
|
-
getSerializeProps(viewOptions: ViewOptions): any;
|
49
|
-
}
|
50
|
-
export declare class DocumentProps extends INotifyPropertyChanged {
|
51
|
-
width: number;
|
52
|
-
height: number;
|
53
|
-
padding: PaddingProps;
|
54
|
-
headerLine: number;
|
55
|
-
footerLine: number;
|
56
|
-
orient: OrientType;
|
57
|
-
createUserId: string;
|
58
|
-
createUserName: string;
|
59
|
-
createDate: string;
|
60
|
-
scripts: string;
|
61
|
-
clone(dest: DocumentProps): DocumentProps;
|
62
|
-
getSerializeProps(): any;
|
63
|
-
}
|
64
|
-
export declare class CheckBoxProps extends INotifyPropertyChanged {
|
65
|
-
size: number;
|
66
|
-
isChecked: boolean;
|
67
|
-
groupName: string | null;
|
68
|
-
clone(dest: CheckBoxProps): CheckBoxProps;
|
69
|
-
getSerializeProps(viewOptions: ViewOptions): {
|
70
|
-
size: number;
|
71
|
-
isChecked: boolean;
|
72
|
-
groupName: string | null;
|
73
|
-
};
|
74
|
-
}
|
75
|
-
export declare class RadioBoxProps extends INotifyPropertyChanged {
|
76
|
-
size: number;
|
77
|
-
isChecked: boolean;
|
78
|
-
clone(dest: RadioBoxProps): RadioBoxProps;
|
79
|
-
getSerializeProps(viewOptions: ViewOptions): {
|
80
|
-
size: number;
|
81
|
-
isCheced: boolean;
|
82
|
-
};
|
83
|
-
}
|
84
|
-
export declare class TableRowProps extends INotifyPropertyChanged {
|
85
|
-
minHeight: number;
|
86
|
-
headerRow: boolean;
|
87
|
-
clone(dest: TableRowProps): TableRowProps;
|
88
|
-
getSerializeProps(viewOptions: ViewOptions): any;
|
89
|
-
}
|
90
|
-
export declare type TableAlignment = 'start' | 'end' | 'center';
|
91
|
-
export declare class TableProps extends INotifyPropertyChanged {
|
92
|
-
width: number | string;
|
93
|
-
cols: Array<{
|
94
|
-
width: number | string;
|
95
|
-
}>;
|
96
|
-
alignment: TableAlignment;
|
97
|
-
border: 'all' | 'none';
|
98
|
-
allowBreakRow: boolean;
|
99
|
-
clone(dest: TableProps): TableProps;
|
100
|
-
getSerializeProps(viewOptions: ViewOptions): {
|
101
|
-
width: string | number;
|
102
|
-
cols: {
|
103
|
-
width: string | number;
|
104
|
-
}[];
|
105
|
-
alignment: TableAlignment;
|
106
|
-
border: "all" | "none";
|
107
|
-
};
|
108
|
-
}
|
109
|
-
export declare type CellMergeType = 'col-merge' | 'row-merge';
|
110
|
-
export declare type VMergeType = 'restart' | 'continue';
|
111
|
-
export declare type HMergeType = 'restart' | 'continue';
|
112
|
-
export declare type VerticalAlign = 'top' | 'middle' | 'bottom';
|
113
|
-
export declare class TableCellProps extends INotifyPropertyChanged {
|
114
|
-
vMerge: VMergeType | null;
|
115
|
-
hMerge: HMergeType | null;
|
116
|
-
vAlign: VerticalAlign | null;
|
117
|
-
backgroundColor: string | null;
|
118
|
-
/**
|
119
|
-
* 对角线
|
120
|
-
*/
|
121
|
-
diagonal: 'main' | 'sub' | null;
|
122
|
-
clone(dest: TableCellProps): TableCellProps;
|
123
|
-
getSerializeProps(options: ViewOptions): any;
|
124
|
-
}
|
125
|
-
export declare class PictureProps extends INotifyPropertyChanged {
|
126
|
-
title: string;
|
127
|
-
width: number;
|
128
|
-
height: number;
|
129
|
-
src: string;
|
130
|
-
border: 'all' | 'none';
|
131
|
-
clone(dest: PictureProps): PictureProps;
|
132
|
-
getSerializeProps(viewOptions: ViewOptions): NullableType<PictureProps>;
|
133
|
-
}
|
134
|
-
export declare class DataDecorateProps extends INotifyPropertyChanged {
|
135
|
-
content: string;
|
136
|
-
size: number;
|
137
|
-
clone(dest: DataDecorateProps): DataDecorateProps;
|
138
|
-
getSerializeProps(viewOptions: ViewOptions): {
|
139
|
-
size: number;
|
140
|
-
content: string;
|
141
|
-
};
|
142
|
-
}
|
143
|
-
export declare type DataEleTypes = 'text' | 'droplist' | 'date' | 'check' | 'img';
|
144
|
-
export declare class DataEleBaseProps extends INotifyPropertyChanged {
|
145
|
-
id: string;
|
146
|
-
name: string;
|
147
|
-
fieldName: string;
|
148
|
-
caption: string;
|
149
|
-
required: boolean;
|
150
|
-
printable: boolean;
|
151
|
-
secretBrowse: boolean;
|
152
|
-
editable: boolean;
|
153
|
-
deleteable: boolean;
|
154
|
-
minLength: number;
|
155
|
-
type: DataEleTypes;
|
156
|
-
underline: boolean;
|
157
|
-
cloneBaseProps(destProps: DataEleBaseProps): void;
|
158
|
-
private setPropValue;
|
159
|
-
updateProps(props: DataEleBaseProps): void;
|
160
|
-
getBaseProps(props: NullableType<DataEleBaseProps>, options: ViewOptions): NullableType<DataEleBaseProps>;
|
161
|
-
getSerializeProps(viewOptions: ViewOptions): void;
|
162
|
-
}
|
163
|
-
export declare class DataEleBaseTextProps extends DataEleBaseProps {
|
164
|
-
constructor();
|
165
|
-
valueTextProps: TextProps;
|
166
|
-
nullText: string;
|
167
|
-
nullTextProps: TextProps;
|
168
|
-
dataType: 'text' | 'int' | 'float' | 'email' | 'date' | 'phone' | 'zipcode';
|
169
|
-
clone(dest?: DataEleBaseTextProps | null): DataEleBaseTextProps;
|
170
|
-
getSerializeProps(options: ViewOptions): any;
|
171
|
-
getBaseProps(props: NullableType<DataEleBaseTextProps>, options: ViewOptions): NullableType<DataEleBaseTextProps>;
|
172
|
-
updateProps(props: DataEleBaseTextProps): void;
|
173
|
-
}
|
174
|
-
export interface DataEleListOption {
|
175
|
-
code: string;
|
176
|
-
value: string;
|
177
|
-
}
|
178
|
-
export declare class DataEleListProps extends DataEleBaseTextProps {
|
179
|
-
constructor();
|
180
|
-
options: Array<DataEleListOption>;
|
181
|
-
dropDownStyle: 'DropDownList' | 'DropDown';
|
182
|
-
/**
|
183
|
-
* 是否允许多选
|
184
|
-
*/
|
185
|
-
multiSelect: boolean;
|
186
|
-
clone(dest: DataEleListProps | null): DataEleListProps;
|
187
|
-
getSerializeProps(options: ViewOptions): any;
|
188
|
-
updateProps(props: DataEleListProps): void;
|
189
|
-
}
|
190
|
-
export declare class CommContentProps extends INotifyPropertyChanged {
|
191
|
-
id: string;
|
192
|
-
createId: string;
|
193
|
-
createName: string;
|
194
|
-
createDate: Date;
|
195
|
-
clone(dest: CommContentProps): CommContentProps;
|
196
|
-
getSerializeProps(viewOptions: ViewOptions): {
|
197
|
-
id: string;
|
198
|
-
};
|
199
|
-
}
|
200
|
-
export declare class CommProps extends INotifyPropertyChanged {
|
201
|
-
id: string;
|
202
|
-
markType: "start" | "end";
|
203
|
-
clone(dest: CommProps): CommProps;
|
204
|
-
getSerializeProps(viewOptions: ViewOptions): {
|
205
|
-
id: string;
|
206
|
-
markType: "start" | "end";
|
207
|
-
};
|
208
|
-
}
|
209
|
-
export declare class DataEleCheckProps extends DataEleBaseProps {
|
210
|
-
constructor();
|
211
|
-
size: number;
|
212
|
-
checked: boolean;
|
213
|
-
checkedValue: string;
|
214
|
-
groupName: string;
|
215
|
-
multiSelect: boolean;
|
216
|
-
clone(dest: DataEleCheckProps | null): DataEleCheckProps;
|
217
|
-
getSerializeProps(options: ViewOptions): any;
|
218
|
-
updateProps(props: DataEleCheckProps): void;
|
219
|
-
}
|
220
|
-
export declare class DataEleImageProps extends DataEleBaseProps {
|
221
|
-
constructor();
|
222
|
-
width: number;
|
223
|
-
height: number;
|
224
|
-
src: string;
|
225
|
-
border: 'all' | 'none';
|
226
|
-
clone(dest: DataEleImageProps | null): DataEleImageProps;
|
227
|
-
getSerializeProps(options: ViewOptions): any;
|
228
|
-
updateProps(props: DataEleImageProps): void;
|
229
|
-
}
|
230
|
-
export declare class DataEleDateProps extends DataEleBaseTextProps {
|
231
|
-
constructor();
|
232
|
-
minValue?: Date;
|
233
|
-
maxValue?: Date;
|
234
|
-
format?: string;
|
235
|
-
clone(dest: DataEleDateProps | null): DataEleDateProps;
|
236
|
-
getSerializeProps(options: ViewOptions): any;
|
237
|
-
updateProps(props: DataEleDateProps): void;
|
238
|
-
}
|
239
|
-
export declare class ValidateCondition {
|
240
|
-
required: boolean;
|
241
|
-
maxLength: number;
|
242
|
-
dataType: 'string' | 'date' | 'time' | 'number' | 'float';
|
243
|
-
}
|
244
|
-
export declare class DataEleMHProps extends DataEleBaseProps {
|
245
|
-
age: string;
|
246
|
-
days: string;
|
247
|
-
cycles: string;
|
248
|
-
lastDate: string;
|
249
|
-
closeAge: string;
|
250
|
-
kind: string;
|
251
|
-
clone(dest: DataEleMHProps | null): DataEleMHProps;
|
252
|
-
getSerializeProps(options: ViewOptions): NullableType<DataEleMHProps>;
|
253
|
-
}
|
254
|
-
export declare class TrackRunProps {
|
255
|
-
type: TrackRunTypeEnum;
|
256
|
-
userId: string;
|
257
|
-
userName: string;
|
258
|
-
date: string;
|
259
|
-
id: string;
|
260
|
-
constructor(type: TrackRunTypeEnum);
|
261
|
-
clone(dest: TrackRunProps | null): void;
|
262
|
-
getSerializeProps(): NullableType<TrackRunProps>;
|
263
|
-
}
|
264
|
-
declare class FontMapStruct {
|
265
|
-
fontMap: Map<string, string>;
|
266
|
-
length: number;
|
267
|
-
registerFontMap(name: string, keyName: string): void;
|
268
|
-
getFontMap(name: string): string;
|
269
|
-
}
|
270
|
-
export declare const fontMapFunc: FontMapStruct;
|
271
|
-
export declare class ValidateProps {
|
272
|
-
id: string;
|
273
|
-
title: string;
|
274
|
-
msg: string;
|
275
|
-
}
|
276
|
-
export declare class DataElementGroupProps {
|
277
|
-
id: string;
|
278
|
-
name: string;
|
279
|
-
clone(dest: DataElementGroupProps | null): void;
|
280
|
-
getSerializeProps(): {
|
281
|
-
id: string;
|
282
|
-
name: string;
|
283
|
-
};
|
284
|
-
}
|
285
|
-
export declare class DataElementBarcodeProps {
|
286
|
-
type: 'ena13' | 'code128' | 'code39' | 'qrcode';
|
287
|
-
text: string;
|
288
|
-
width: number;
|
289
|
-
height: number;
|
290
|
-
clone(dest: DataElementBarcodeProps | null): void;
|
291
|
-
getSerializeProps(): {
|
292
|
-
type: "ena13" | "code128" | "code39" | "qrcode";
|
293
|
-
text: string;
|
294
|
-
width: number;
|
295
|
-
height: number;
|
296
|
-
};
|
297
|
-
}
|
298
|
-
export declare class BodyPartProps {
|
299
|
-
partId: string;
|
300
|
-
}
|
301
|
-
export {};
|
@@ -1,19 +0,0 @@
|
|
1
|
-
import { EditorContext } from "./document-context";
|
2
|
-
import { ElementFactory, Element, ViewOptions } from "./element-define";
|
3
|
-
import { DocumentElement } from "./impl/document/doc-impl";
|
4
|
-
import { RenderContenxtType } from "./render-context";
|
5
|
-
export declare class ElementReader {
|
6
|
-
private docCtx;
|
7
|
-
private viewOptions;
|
8
|
-
private renderCtx;
|
9
|
-
constructor(docCtx: EditorContext, viewOptions: ViewOptions, renderCtx: RenderContenxtType);
|
10
|
-
factories: Array<ElementFactory>;
|
11
|
-
addFactory<U extends null | object, T extends ElementFactory<U>>(c: new () => T): void;
|
12
|
-
private initFactory;
|
13
|
-
read(data: any | DocumentElement): void;
|
14
|
-
setDocument(document: DocumentElement): void;
|
15
|
-
readElement(data: any): Element;
|
16
|
-
propsReadFuncs: Map<string, (data: any) => any>;
|
17
|
-
registerReadFunc<T>(propName: string, func: (data: T) => T): void;
|
18
|
-
readExtendsProps(data: any, element: Element): void;
|
19
|
-
}
|
@@ -1,55 +0,0 @@
|
|
1
|
-
import { DocumentBodyRenderObject } from "./impl/document/doc-body-impl";
|
2
|
-
import { DocumentElement, DocumentRenderObject } from "./impl/document/doc-impl";
|
3
|
-
import { RenderContenxtType } from "./render-context";
|
4
|
-
import { BlockContentRenderObject } from "./render-define";
|
5
|
-
import { Rect, ViewOptions } from "./element-define";
|
6
|
-
import { TableRowRenderObject } from "./impl/table/table-row-impl";
|
7
|
-
import { TableCellRenderObject } from "./impl/table/table-cell-impl";
|
8
|
-
import { TableRenderObject } from "./impl/table/table-impl";
|
9
|
-
export declare class ElementRenderCut {
|
10
|
-
private options;
|
11
|
-
private renderContext;
|
12
|
-
constructor(options: ViewOptions, renderContext: RenderContenxtType);
|
13
|
-
cutPage(documentRender: DocumentRenderObject, documentElement: DocumentElement): Array<DocumentRenderObject>;
|
14
|
-
private checkPageBreak;
|
15
|
-
getFullViewDocRender(documentRender: DocumentRenderObject, documentElement: DocumentElement): Array<DocumentRenderObject>;
|
16
|
-
createEmptyBodyRender(bodyRender: DocumentBodyRenderObject, limitRect: Rect): {
|
17
|
-
emptyBody: DocumentBodyRenderObject;
|
18
|
-
innerRect: Rect & {
|
19
|
-
prevMargin: number;
|
20
|
-
};
|
21
|
-
};
|
22
|
-
/**
|
23
|
-
* 切割渲染元素
|
24
|
-
* @param render 被切割的对象
|
25
|
-
* @param limitHeight
|
26
|
-
* @param addFunc
|
27
|
-
* @returns
|
28
|
-
*/
|
29
|
-
cutRenderItem(render: BlockContentRenderObject, limitHeight: number): BlockContentRenderObject | null;
|
30
|
-
/**
|
31
|
-
* 切割渲染元素
|
32
|
-
* @param tbRender 被切割的对象
|
33
|
-
* @param limitHeight
|
34
|
-
* @param addFunc
|
35
|
-
* @returns
|
36
|
-
*/
|
37
|
-
cutTable(tbRender: TableRenderObject, limitHeight: number): BlockContentRenderObject | null;
|
38
|
-
cutRowRenderItem(render: TableRowRenderObject, limitHeight: number): TableRowRenderObject | null;
|
39
|
-
/**
|
40
|
-
* 修复->已经截断的合并单元格要向下移动到合适的位置
|
41
|
-
* @param tbRender
|
42
|
-
* @param cutRows
|
43
|
-
* @returns
|
44
|
-
*/
|
45
|
-
private fixCutTable;
|
46
|
-
/**
|
47
|
-
* 校验当前是否是一个完整的行,没有Null单元格,检查当前是否还需要向下合并
|
48
|
-
* @param row
|
49
|
-
*/
|
50
|
-
private checkFullRow;
|
51
|
-
private existsCellRender;
|
52
|
-
private getBlockLineHeight;
|
53
|
-
getRowInsertCellIndex(sourceCell: TableCellRenderObject, destRow: TableRowRenderObject): number;
|
54
|
-
private getHeaderRows;
|
55
|
-
}
|
@@ -1,30 +0,0 @@
|
|
1
|
-
import { SelectionState } from "./document-selection";
|
2
|
-
import { BranchElement, Element, SerializeProps, ViewOptions } from "./element-define";
|
3
|
-
export declare class ElementSerialize {
|
4
|
-
static serialize(element: Element, viewOptions: ViewOptions): SerializeProps | null;
|
5
|
-
static serializeString(element: Element, options?: {
|
6
|
-
all: boolean;
|
7
|
-
}): string;
|
8
|
-
/**
|
9
|
-
* 获取选中的结构
|
10
|
-
* @param ss
|
11
|
-
* @param viewOptions
|
12
|
-
*/
|
13
|
-
static getSelectedStruct(ss: SelectionState, viewOptions: ViewOptions): Element | null;
|
14
|
-
/**
|
15
|
-
* 选中的文本
|
16
|
-
* @param ss
|
17
|
-
* @param viewOptions
|
18
|
-
*/
|
19
|
-
static getSelectedText(ss: SelectionState, viewOptions: ViewOptions): string;
|
20
|
-
static getSelectedJSON(ss: SelectionState, viewOptions: ViewOptions): string;
|
21
|
-
/**
|
22
|
-
* 遍历指定元素内部所有数据元列表
|
23
|
-
*/
|
24
|
-
static getDataElements(element: BranchElement): Array<Element>;
|
25
|
-
}
|
26
|
-
export interface DataElementValueStruct {
|
27
|
-
id: string;
|
28
|
-
name: string;
|
29
|
-
value: string;
|
30
|
-
}
|