docx 9.5.3 → 9.6.1
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/README.md +1 -1
- package/dist/index.cjs +3244 -2746
- package/dist/index.d.cts +361 -230
- package/dist/index.d.ts +361 -230
- package/dist/index.iife.js +3237 -2739
- package/dist/index.mjs +3244 -2746
- package/dist/index.umd.cjs +3237 -2739
- package/package.json +7 -9
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
|
-
|
|
3
1
|
import { default as default_2 } from 'jszip';
|
|
4
2
|
import { Element as Element_2 } from 'xml-js';
|
|
5
3
|
import { Stream } from 'stream';
|
|
@@ -11,18 +9,6 @@ export declare class AbstractNumbering extends XmlComponent {
|
|
|
11
9
|
|
|
12
10
|
export declare const abstractNumUniqueNumericIdGen: () => UniqueNumericIdCreator;
|
|
13
11
|
|
|
14
|
-
export declare class Alignment extends XmlComponent {
|
|
15
|
-
constructor(type: (typeof AlignmentType)[keyof typeof AlignmentType]);
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
export declare class AlignmentAttributes extends XmlAttributeComponent<{
|
|
19
|
-
readonly val: (typeof AlignmentType)[keyof typeof AlignmentType];
|
|
20
|
-
}> {
|
|
21
|
-
protected readonly xmlKeys: {
|
|
22
|
-
val: string;
|
|
23
|
-
};
|
|
24
|
-
}
|
|
25
|
-
|
|
26
12
|
export declare const AlignmentType: {
|
|
27
13
|
readonly START: "start";
|
|
28
14
|
readonly CENTER: "center";
|
|
@@ -104,20 +90,12 @@ export declare class Attributes extends XmlAttributeComponent<{
|
|
|
104
90
|
};
|
|
105
91
|
}
|
|
106
92
|
|
|
107
|
-
export declare abstract class BaseEmphasisMark extends XmlComponent {
|
|
108
|
-
protected constructor(emphasisMarkType: (typeof EmphasisMarkType)[keyof typeof EmphasisMarkType]);
|
|
109
|
-
}
|
|
110
|
-
|
|
111
93
|
export declare abstract class BaseXmlComponent {
|
|
112
94
|
protected readonly rootKey: string;
|
|
113
95
|
constructor(rootKey: string);
|
|
114
96
|
abstract prepForXml(context: IContext): IXmlableObject | undefined;
|
|
115
97
|
}
|
|
116
98
|
|
|
117
|
-
declare class Begin extends XmlComponent {
|
|
118
|
-
constructor(dirty?: boolean);
|
|
119
|
-
}
|
|
120
|
-
|
|
121
99
|
declare class Body_2 extends XmlComponent {
|
|
122
100
|
private readonly sections;
|
|
123
101
|
constructor();
|
|
@@ -150,10 +128,6 @@ export declare class Border extends IgnoreIfEmptyXmlComponent {
|
|
|
150
128
|
constructor(options: IBordersOptions);
|
|
151
129
|
}
|
|
152
130
|
|
|
153
|
-
export declare class BorderElement extends XmlComponent {
|
|
154
|
-
constructor(elementName: string, { color, size, space, style }: IBorderOptions);
|
|
155
|
-
}
|
|
156
|
-
|
|
157
131
|
export declare const BorderStyle: {
|
|
158
132
|
readonly SINGLE: "single";
|
|
159
133
|
readonly DASH_DOT_STROKED: "dashDotStroked";
|
|
@@ -184,10 +158,6 @@ export declare const BorderStyle: {
|
|
|
184
158
|
readonly WAVE: "wave";
|
|
185
159
|
};
|
|
186
160
|
|
|
187
|
-
declare class Break extends XmlComponent {
|
|
188
|
-
constructor();
|
|
189
|
-
}
|
|
190
|
-
|
|
191
161
|
export declare class BuilderElement<T extends AttributeData = {}> extends XmlComponent {
|
|
192
162
|
constructor({ name, attributes, children, }: {
|
|
193
163
|
readonly name: string;
|
|
@@ -200,6 +170,20 @@ export declare class CarriageReturn extends EmptyElement {
|
|
|
200
170
|
constructor();
|
|
201
171
|
}
|
|
202
172
|
|
|
173
|
+
export declare class CellMerge extends XmlComponent {
|
|
174
|
+
constructor(options: ICellMergeAttributes);
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
export declare class CellMergeAttributes extends XmlAttributeComponent<ICellMergeAttributes> {
|
|
178
|
+
protected readonly xmlKeys: {
|
|
179
|
+
id: string;
|
|
180
|
+
author: string;
|
|
181
|
+
date: string;
|
|
182
|
+
verticalMerge: string;
|
|
183
|
+
verticalMergeOriginal: string;
|
|
184
|
+
};
|
|
185
|
+
}
|
|
186
|
+
|
|
203
187
|
declare const CellSpacingType: {
|
|
204
188
|
readonly DXA: "dxa";
|
|
205
189
|
readonly NIL: "nil";
|
|
@@ -246,17 +230,13 @@ export declare class CheckBoxUtil extends XmlComponent {
|
|
|
246
230
|
}
|
|
247
231
|
|
|
248
232
|
export declare class Column extends XmlComponent {
|
|
249
|
-
constructor(
|
|
233
|
+
constructor(options: IColumnAttributes);
|
|
250
234
|
}
|
|
251
235
|
|
|
252
236
|
export declare class ColumnBreak extends Run {
|
|
253
237
|
constructor();
|
|
254
238
|
}
|
|
255
239
|
|
|
256
|
-
export declare class Columns extends XmlComponent {
|
|
257
|
-
constructor({ space, count, separate, equalWidth, children }: IColumnsAttributes);
|
|
258
|
-
}
|
|
259
|
-
|
|
260
240
|
declare class Comment_2 extends XmlComponent {
|
|
261
241
|
constructor({ id, initials, author, date, children }: ICommentOptions);
|
|
262
242
|
}
|
|
@@ -318,11 +298,19 @@ export declare const convertMillimetersToTwip: (millimeters: number) => number;
|
|
|
318
298
|
|
|
319
299
|
export declare const convertToXmlComponent: (element: Element_2) => ImportedXmlComponent | string | undefined;
|
|
320
300
|
|
|
301
|
+
declare type CoreGroupOptions = {
|
|
302
|
+
readonly children: readonly IGroupChildMediaData[];
|
|
303
|
+
readonly transformation: IMediaTransformation;
|
|
304
|
+
readonly floating?: IFloating;
|
|
305
|
+
readonly altText?: DocPropertiesOptions;
|
|
306
|
+
};
|
|
307
|
+
|
|
321
308
|
declare type CoreImageOptions = {
|
|
322
309
|
readonly transformation: IMediaTransformation;
|
|
323
310
|
readonly floating?: IFloating;
|
|
324
311
|
readonly altText?: DocPropertiesOptions;
|
|
325
312
|
readonly outline?: OutlineOptions;
|
|
313
|
+
readonly solidFill?: SolidFillOptions;
|
|
326
314
|
};
|
|
327
315
|
|
|
328
316
|
declare type CoreMediaData = {
|
|
@@ -335,12 +323,36 @@ declare class CoreProperties extends XmlComponent {
|
|
|
335
323
|
constructor(options: Omit<IPropertiesOptions, "sections">);
|
|
336
324
|
}
|
|
337
325
|
|
|
326
|
+
declare type CoreShapeOptions = {
|
|
327
|
+
readonly transformation: IMediaTransformation;
|
|
328
|
+
readonly floating?: IFloating;
|
|
329
|
+
readonly altText?: DocPropertiesOptions;
|
|
330
|
+
readonly outline?: OutlineOptions;
|
|
331
|
+
readonly solidFill?: SolidFillOptions;
|
|
332
|
+
};
|
|
333
|
+
|
|
334
|
+
export declare const createAlignment: (type: (typeof AlignmentType)[keyof typeof AlignmentType]) => XmlComponent;
|
|
335
|
+
|
|
336
|
+
export declare const createBodyProperties: (options?: IBodyPropertiesOptions) => XmlComponent;
|
|
337
|
+
|
|
338
|
+
export declare const createBorderElement: (elementName: string, { color, size, space, style }: IBorderOptions) => XmlComponent;
|
|
339
|
+
|
|
340
|
+
export declare const createColumns: ({ space, count, separate, equalWidth, children }: IColumnsAttributes) => XmlComponent;
|
|
341
|
+
|
|
338
342
|
export declare const createDocumentGrid: ({ type, linePitch, charSpace }: IDocGridAttributesProperties) => XmlComponent;
|
|
339
343
|
|
|
344
|
+
export declare const createDotEmphasisMark: () => XmlComponent;
|
|
345
|
+
|
|
346
|
+
export declare const createEmphasisMark: (emphasisMarkType?: (typeof EmphasisMarkType)[keyof typeof EmphasisMarkType]) => XmlComponent;
|
|
347
|
+
|
|
340
348
|
export declare const createFrameProperties: (options: IFrameOptions) => XmlComponent;
|
|
341
349
|
|
|
350
|
+
export declare const createHeaderFooterReference: (type: (typeof HeaderFooterType)[keyof typeof HeaderFooterType], options: IHeaderFooterOptions) => XmlComponent;
|
|
351
|
+
|
|
342
352
|
export declare const createHorizontalPosition: ({ relative, align, offset }: IHorizontalPositionOptions) => XmlComponent;
|
|
343
353
|
|
|
354
|
+
export declare const createIndent: ({ start, end, left, right, hanging, firstLine }: IIndentAttributesProperties) => XmlComponent;
|
|
355
|
+
|
|
344
356
|
export declare const createLineNumberType: ({ countBy, start, restart, distance }: ILineNumberAttributes) => XmlComponent;
|
|
345
357
|
|
|
346
358
|
export declare const createMathAccentCharacter: ({ accent }: MathAccentCharacterOptions) => XmlComponent;
|
|
@@ -363,14 +375,58 @@ export declare const createMathSuperScriptElement: ({ children }: MathSuperScrip
|
|
|
363
375
|
|
|
364
376
|
export declare const createMathSuperScriptProperties: () => XmlComponent;
|
|
365
377
|
|
|
378
|
+
export declare const createOutlineLevel: (level: number) => XmlComponent;
|
|
379
|
+
|
|
380
|
+
export declare const createPageMargin: (top: number | UniversalMeasure, right: number | PositiveUniversalMeasure, bottom: number | UniversalMeasure, left: number | PositiveUniversalMeasure, header: number | PositiveUniversalMeasure, footer: number | PositiveUniversalMeasure, gutter: number | PositiveUniversalMeasure) => XmlComponent;
|
|
381
|
+
|
|
382
|
+
export declare const createPageNumberType: ({ start, formatType, separator }: IPageNumberTypeAttributes) => XmlComponent;
|
|
383
|
+
|
|
366
384
|
export declare const createPageSize: ({ width, height, orientation, code }: IPageSizeAttributes) => XmlComponent;
|
|
367
385
|
|
|
386
|
+
export declare const createParagraphStyle: (styleId: string) => XmlComponent;
|
|
387
|
+
|
|
388
|
+
export declare const createRunFonts: (nameOrAttrs: string | IFontAttributesProperties, hint?: string) => XmlComponent;
|
|
389
|
+
|
|
390
|
+
export declare const createSectionType: (value: (typeof SectionType)[keyof typeof SectionType]) => XmlComponent;
|
|
391
|
+
|
|
392
|
+
export declare const createShading: ({ fill, color, type }: IShadingAttributesProperties) => XmlComponent;
|
|
393
|
+
|
|
368
394
|
export declare const createSimplePos: () => XmlComponent;
|
|
369
395
|
|
|
396
|
+
export declare const createSpacing: ({ after, before, line, lineRule, beforeAutoSpacing, afterAutoSpacing }: ISpacingProperties) => XmlComponent;
|
|
397
|
+
|
|
370
398
|
export declare const createStringElement: (name: string, value: string) => XmlComponent;
|
|
371
399
|
|
|
400
|
+
export declare const createTableFloatProperties: ({ horizontalAnchor, verticalAnchor, absoluteHorizontalPosition, relativeHorizontalPosition, absoluteVerticalPosition, relativeVerticalPosition, bottomFromText, topFromText, leftFromText, rightFromText, overlap, }: ITableFloatOptions) => XmlComponent;
|
|
401
|
+
|
|
402
|
+
export declare const createTableLayout: (type: (typeof TableLayoutType)[keyof typeof TableLayoutType]) => XmlComponent;
|
|
403
|
+
|
|
404
|
+
export declare const createTableLook: ({ firstRow, lastRow, firstColumn, lastColumn, noHBand, noVBand }: ITableLookOptions) => XmlComponent;
|
|
405
|
+
|
|
406
|
+
export declare const createTableRowHeight: (value: number | PositiveUniversalMeasure, rule: (typeof HeightRule)[keyof typeof HeightRule]) => XmlComponent;
|
|
407
|
+
|
|
408
|
+
export declare const createTableWidthElement: (name: string, { type, size }: ITableWidthProperties) => XmlComponent;
|
|
409
|
+
|
|
410
|
+
export declare const createTabStop: (tabDefinitions: readonly TabStopDefinition[]) => XmlComponent;
|
|
411
|
+
|
|
412
|
+
export declare const createTabStopItem: ({ type, position, leader }: TabStopDefinition) => XmlComponent;
|
|
413
|
+
|
|
414
|
+
export declare const createTransformation: (options: IMediaTransformation) => IMediaDataTransformation;
|
|
415
|
+
|
|
416
|
+
export declare const createUnderline: (underlineType?: (typeof UnderlineType)[keyof typeof UnderlineType], color?: string) => XmlComponent;
|
|
417
|
+
|
|
418
|
+
export declare const createVerticalAlign: (value: (typeof VerticalAlign)[keyof typeof VerticalAlign]) => XmlComponent;
|
|
419
|
+
|
|
372
420
|
export declare const createVerticalPosition: ({ relative, align, offset }: IVerticalPositionOptions) => XmlComponent;
|
|
373
421
|
|
|
422
|
+
export declare const createWrapNone: () => XmlComponent;
|
|
423
|
+
|
|
424
|
+
export declare const createWrapSquare: (textWrapping: ITextWrapping, margins?: IMargins) => XmlComponent;
|
|
425
|
+
|
|
426
|
+
export declare const createWrapTight: (margins?: IMargins) => XmlComponent;
|
|
427
|
+
|
|
428
|
+
export declare const createWrapTopAndBottom: (margins?: IMargins) => XmlComponent;
|
|
429
|
+
|
|
374
430
|
declare class CustomProperties extends XmlComponent {
|
|
375
431
|
private nextId;
|
|
376
432
|
private readonly properties;
|
|
@@ -391,6 +447,14 @@ export declare class DayShort extends EmptyElement {
|
|
|
391
447
|
|
|
392
448
|
export declare const decimalNumber: (val: number) => number;
|
|
393
449
|
|
|
450
|
+
export declare class DeletedTableCell extends XmlComponent {
|
|
451
|
+
constructor(options: IChangedAttributesProperties);
|
|
452
|
+
}
|
|
453
|
+
|
|
454
|
+
export declare class DeletedTableRow extends XmlComponent {
|
|
455
|
+
constructor(options: IChangedAttributesProperties);
|
|
456
|
+
}
|
|
457
|
+
|
|
394
458
|
export declare class DeletedTextRun extends XmlComponent {
|
|
395
459
|
protected readonly deletedTextRunWrapper: DeletedTextRunWrapper;
|
|
396
460
|
constructor(options: IDeletedRunOptions);
|
|
@@ -404,6 +468,7 @@ declare type DocPropertiesOptions = {
|
|
|
404
468
|
readonly name: string;
|
|
405
469
|
readonly description?: string;
|
|
406
470
|
readonly title?: string;
|
|
471
|
+
readonly id?: string;
|
|
407
472
|
};
|
|
408
473
|
|
|
409
474
|
export declare const docPropertiesUniqueNumericIdGen: () => UniqueNumericIdCreator;
|
|
@@ -501,12 +566,8 @@ declare class DocumentWrapper implements IViewWrapper {
|
|
|
501
566
|
get Relationships(): Relationships;
|
|
502
567
|
}
|
|
503
568
|
|
|
504
|
-
export declare class DotEmphasisMark extends BaseEmphasisMark {
|
|
505
|
-
constructor();
|
|
506
|
-
}
|
|
507
|
-
|
|
508
569
|
export declare class Drawing extends XmlComponent {
|
|
509
|
-
constructor(imageData:
|
|
570
|
+
constructor(imageData: IExtendedMediaData, drawingOptions?: IDrawingOptions);
|
|
510
571
|
}
|
|
511
572
|
|
|
512
573
|
export declare const DropCapType: {
|
|
@@ -517,10 +578,6 @@ export declare const DropCapType: {
|
|
|
517
578
|
|
|
518
579
|
export declare const eighthPointMeasureValue: (val: number) => number;
|
|
519
580
|
|
|
520
|
-
export declare class EmphasisMark extends BaseEmphasisMark {
|
|
521
|
-
constructor(emphasisMarkType?: (typeof EmphasisMarkType)[keyof typeof EmphasisMarkType]);
|
|
522
|
-
}
|
|
523
|
-
|
|
524
581
|
export declare const EmphasisMarkType: {
|
|
525
582
|
readonly DOT: "dot";
|
|
526
583
|
};
|
|
@@ -530,14 +587,41 @@ export declare const EMPTY_OBJECT: {};
|
|
|
530
587
|
export declare class EmptyElement extends XmlComponent {
|
|
531
588
|
}
|
|
532
589
|
|
|
533
|
-
declare
|
|
534
|
-
|
|
590
|
+
export declare const encodeUtf8: (str: string) => Uint8Array;
|
|
591
|
+
|
|
592
|
+
export declare class EndnoteIdReference extends XmlComponent {
|
|
593
|
+
constructor(id: number);
|
|
535
594
|
}
|
|
536
595
|
|
|
537
596
|
export declare class EndnoteReference extends EmptyElement {
|
|
538
597
|
constructor();
|
|
539
598
|
}
|
|
540
599
|
|
|
600
|
+
export declare class EndnoteReferenceRun extends Run {
|
|
601
|
+
constructor(id: number);
|
|
602
|
+
}
|
|
603
|
+
|
|
604
|
+
export declare class EndnoteReferenceRunAttributes extends XmlAttributeComponent<{
|
|
605
|
+
readonly id: number;
|
|
606
|
+
}> {
|
|
607
|
+
protected readonly xmlKeys: {
|
|
608
|
+
id: string;
|
|
609
|
+
};
|
|
610
|
+
}
|
|
611
|
+
|
|
612
|
+
export declare class Endnotes extends XmlComponent {
|
|
613
|
+
constructor();
|
|
614
|
+
createEndnote(id: number, paragraph: readonly Paragraph[]): void;
|
|
615
|
+
}
|
|
616
|
+
|
|
617
|
+
declare class EndnotesWrapper implements IViewWrapper {
|
|
618
|
+
private readonly endnotes;
|
|
619
|
+
private readonly relationships;
|
|
620
|
+
constructor();
|
|
621
|
+
get View(): Endnotes;
|
|
622
|
+
get Relationships(): Relationships;
|
|
623
|
+
}
|
|
624
|
+
|
|
541
625
|
export declare class ExternalHyperlink extends XmlComponent {
|
|
542
626
|
readonly options: IExternalHyperlinkOptions;
|
|
543
627
|
constructor(options: IExternalHyperlinkOptions);
|
|
@@ -558,6 +642,7 @@ declare class File_2 {
|
|
|
558
642
|
private readonly media;
|
|
559
643
|
private readonly fileRelationships;
|
|
560
644
|
private readonly footnotesWrapper;
|
|
645
|
+
private readonly endnotesWrapper;
|
|
561
646
|
private readonly settings;
|
|
562
647
|
private readonly contentTypes;
|
|
563
648
|
private readonly customProperties;
|
|
@@ -584,6 +669,7 @@ declare class File_2 {
|
|
|
584
669
|
get CustomProperties(): CustomProperties;
|
|
585
670
|
get AppProperties(): AppProperties;
|
|
586
671
|
get FootNotes(): FootnotesWrapper;
|
|
672
|
+
get Endnotes(): EndnotesWrapper;
|
|
587
673
|
get Settings(): Settings;
|
|
588
674
|
get Comments(): Comments;
|
|
589
675
|
get FontTable(): FontWrapper;
|
|
@@ -710,10 +796,6 @@ declare class Header_2 extends InitializableXmlComponent {
|
|
|
710
796
|
add(item: Paragraph | Table): void;
|
|
711
797
|
}
|
|
712
798
|
|
|
713
|
-
export declare class HeaderFooterReference extends XmlComponent {
|
|
714
|
-
constructor(type: (typeof HeaderFooterType)[keyof typeof HeaderFooterType], options: IHeaderFooterOptions);
|
|
715
|
-
}
|
|
716
|
-
|
|
717
799
|
export declare const HeaderFooterReferenceType: {
|
|
718
800
|
readonly DEFAULT: "default";
|
|
719
801
|
readonly FIRST: "first";
|
|
@@ -840,6 +922,18 @@ export declare type IBaseParagraphStyleOptions = {
|
|
|
840
922
|
readonly run?: IRunStylePropertiesOptions;
|
|
841
923
|
} & IStyleOptions;
|
|
842
924
|
|
|
925
|
+
export declare type IBodyPropertiesOptions = {
|
|
926
|
+
readonly wrap?: (typeof TextWrappingType)[keyof typeof TextWrappingType];
|
|
927
|
+
readonly verticalAnchor?: VerticalAnchor;
|
|
928
|
+
readonly margins?: {
|
|
929
|
+
readonly top?: number;
|
|
930
|
+
readonly bottom?: number;
|
|
931
|
+
readonly left?: number;
|
|
932
|
+
readonly right?: number;
|
|
933
|
+
};
|
|
934
|
+
readonly noAutoFit?: boolean;
|
|
935
|
+
};
|
|
936
|
+
|
|
843
937
|
export declare type IBookmarkOptions = {
|
|
844
938
|
readonly id: string;
|
|
845
939
|
readonly children: readonly ParagraphChild[];
|
|
@@ -860,6 +954,11 @@ export declare type IBordersOptions = {
|
|
|
860
954
|
readonly between?: IBorderOptions;
|
|
861
955
|
};
|
|
862
956
|
|
|
957
|
+
export declare type ICellMergeAttributes = IChangedAttributesProperties & {
|
|
958
|
+
readonly verticalMerge?: (typeof VerticalMergeRevisionType)[keyof typeof VerticalMergeRevisionType];
|
|
959
|
+
readonly verticalMergeOriginal?: (typeof VerticalMergeRevisionType)[keyof typeof VerticalMergeRevisionType];
|
|
960
|
+
};
|
|
961
|
+
|
|
863
962
|
declare type IChangedAttributesProperties = {
|
|
864
963
|
readonly id: number;
|
|
865
964
|
readonly author: string;
|
|
@@ -882,7 +981,7 @@ export declare type ICheckboxSymbolProperties = {
|
|
|
882
981
|
readonly font?: string;
|
|
883
982
|
};
|
|
884
983
|
|
|
885
|
-
declare type IColumnAttributes = {
|
|
984
|
+
export declare type IColumnAttributes = {
|
|
886
985
|
readonly width: number | PositiveUniversalMeasure;
|
|
887
986
|
readonly space?: number | PositiveUniversalMeasure;
|
|
888
987
|
};
|
|
@@ -1010,6 +1109,9 @@ declare type IDefaultStylesOptions = {
|
|
|
1010
1109
|
readonly footnoteReference?: IBaseCharacterStyleOptions;
|
|
1011
1110
|
readonly footnoteText?: IBaseParagraphStyleOptions;
|
|
1012
1111
|
readonly footnoteTextChar?: IBaseCharacterStyleOptions;
|
|
1112
|
+
readonly endnoteReference?: IBaseCharacterStyleOptions;
|
|
1113
|
+
readonly endnoteText?: IBaseParagraphStyleOptions;
|
|
1114
|
+
readonly endnoteTextChar?: IBaseCharacterStyleOptions;
|
|
1013
1115
|
};
|
|
1014
1116
|
|
|
1015
1117
|
declare type IDeletedRunOptions = IRunOptions & IChangedAttributesProperties;
|
|
@@ -1061,8 +1163,11 @@ export declare type IDrawingOptions = {
|
|
|
1061
1163
|
readonly floating?: IFloating;
|
|
1062
1164
|
readonly docProperties?: DocPropertiesOptions;
|
|
1063
1165
|
readonly outline?: OutlineOptions;
|
|
1166
|
+
readonly solidFill?: SolidFillOptions;
|
|
1064
1167
|
};
|
|
1065
1168
|
|
|
1169
|
+
export declare type IExtendedMediaData = IMediaData | WpsMediaData | WpgMediaData;
|
|
1170
|
+
|
|
1066
1171
|
export declare type IExternalHyperlinkOptions = {
|
|
1067
1172
|
readonly children: readonly ParagraphChild[];
|
|
1068
1173
|
readonly link: string;
|
|
@@ -1096,9 +1201,13 @@ declare type IFontOptions = {
|
|
|
1096
1201
|
export declare type IFrameOptions = IXYFrameOptions | IAlignmentFrameOptions;
|
|
1097
1202
|
|
|
1098
1203
|
export declare abstract class IgnoreIfEmptyXmlComponent extends XmlComponent {
|
|
1204
|
+
private readonly includeIfEmpty;
|
|
1205
|
+
constructor(rootKey: string, includeIfEmpty?: boolean);
|
|
1099
1206
|
prepForXml(context: IContext): IXmlableObject | undefined;
|
|
1100
1207
|
}
|
|
1101
1208
|
|
|
1209
|
+
export declare type IGroupChildMediaData = (WpsMediaData | IMediaData) & WpgCommonMediaData;
|
|
1210
|
+
|
|
1102
1211
|
export declare type IHeaderFooterGroup<T> = {
|
|
1103
1212
|
readonly default?: T;
|
|
1104
1213
|
readonly first?: T;
|
|
@@ -1264,6 +1373,16 @@ export declare type IMathSuperScriptOptions = {
|
|
|
1264
1373
|
export declare type IMediaData = (RegularMediaData | SvgMediaData) & CoreMediaData;
|
|
1265
1374
|
|
|
1266
1375
|
export declare type IMediaDataTransformation = {
|
|
1376
|
+
readonly offset?: {
|
|
1377
|
+
readonly pixels: {
|
|
1378
|
+
readonly x: number;
|
|
1379
|
+
readonly y: number;
|
|
1380
|
+
};
|
|
1381
|
+
readonly emus?: {
|
|
1382
|
+
readonly x: number;
|
|
1383
|
+
readonly y: number;
|
|
1384
|
+
};
|
|
1385
|
+
};
|
|
1267
1386
|
readonly pixels: {
|
|
1268
1387
|
readonly x: number;
|
|
1269
1388
|
readonly y: number;
|
|
@@ -1280,6 +1399,10 @@ export declare type IMediaDataTransformation = {
|
|
|
1280
1399
|
};
|
|
1281
1400
|
|
|
1282
1401
|
export declare type IMediaTransformation = {
|
|
1402
|
+
readonly offset?: {
|
|
1403
|
+
readonly top?: number;
|
|
1404
|
+
readonly left?: number;
|
|
1405
|
+
};
|
|
1283
1406
|
readonly width: number;
|
|
1284
1407
|
readonly height: number;
|
|
1285
1408
|
readonly flip?: {
|
|
@@ -1301,16 +1424,24 @@ export declare class ImportedXmlComponent extends XmlComponent {
|
|
|
1301
1424
|
push(xmlComponent: XmlComponent | string): void;
|
|
1302
1425
|
}
|
|
1303
1426
|
|
|
1304
|
-
export declare class Indent extends XmlComponent {
|
|
1305
|
-
constructor({ start, end, left, right, hanging, firstLine }: IIndentAttributesProperties);
|
|
1306
|
-
}
|
|
1307
|
-
|
|
1308
1427
|
export declare abstract class InitializableXmlComponent extends XmlComponent {
|
|
1309
1428
|
constructor(rootKey: string, initComponent?: InitializableXmlComponent);
|
|
1310
1429
|
}
|
|
1311
1430
|
|
|
1431
|
+
declare type INonVisualShapePropertiesOptions = {
|
|
1432
|
+
readonly txBox: string;
|
|
1433
|
+
};
|
|
1434
|
+
|
|
1312
1435
|
export declare type InputDataType = Buffer | string | number[] | Uint8Array | ArrayBuffer | Blob | NodeJS.ReadableStream | default_2;
|
|
1313
1436
|
|
|
1437
|
+
export declare class InsertedTableCell extends XmlComponent {
|
|
1438
|
+
constructor(options: IChangedAttributesProperties);
|
|
1439
|
+
}
|
|
1440
|
+
|
|
1441
|
+
export declare class InsertedTableRow extends XmlComponent {
|
|
1442
|
+
constructor(options: IChangedAttributesProperties);
|
|
1443
|
+
}
|
|
1444
|
+
|
|
1314
1445
|
export declare class InsertedTextRun extends XmlComponent {
|
|
1315
1446
|
constructor(options: IInsertedRunOptions);
|
|
1316
1447
|
}
|
|
@@ -1383,7 +1514,14 @@ export declare type IParagraphOptions = {
|
|
|
1383
1514
|
readonly children?: readonly ParagraphChild[];
|
|
1384
1515
|
} & IParagraphPropertiesOptions;
|
|
1385
1516
|
|
|
1517
|
+
export declare type IParagraphPropertiesChangeOptions = IChangedAttributesProperties & IParagraphPropertiesOptionsBase;
|
|
1518
|
+
|
|
1386
1519
|
export declare type IParagraphPropertiesOptions = {
|
|
1520
|
+
readonly revision?: IParagraphPropertiesChangeOptions;
|
|
1521
|
+
readonly includeIfEmpty?: boolean;
|
|
1522
|
+
} & IParagraphPropertiesOptionsBase;
|
|
1523
|
+
|
|
1524
|
+
export declare type IParagraphPropertiesOptionsBase = {
|
|
1387
1525
|
readonly heading?: (typeof HeadingLevel)[keyof typeof HeadingLevel];
|
|
1388
1526
|
readonly bidirectional?: boolean;
|
|
1389
1527
|
readonly pageBreakBefore?: boolean;
|
|
@@ -1399,9 +1537,16 @@ export declare type IParagraphPropertiesOptions = {
|
|
|
1399
1537
|
readonly overflowPunctuation?: boolean;
|
|
1400
1538
|
readonly scale?: number;
|
|
1401
1539
|
readonly autoSpaceEastAsianText?: boolean;
|
|
1402
|
-
readonly run?:
|
|
1540
|
+
readonly run?: IParagraphRunOptions;
|
|
1403
1541
|
} & IParagraphStylePropertiesOptions;
|
|
1404
1542
|
|
|
1543
|
+
export declare type IParagraphRunOptions = IRunOptionsBase & IParagraphRunPropertiesOptions;
|
|
1544
|
+
|
|
1545
|
+
export declare type IParagraphRunPropertiesOptions = {
|
|
1546
|
+
readonly insertion?: IChangedAttributesProperties;
|
|
1547
|
+
readonly deletion?: IChangedAttributesProperties;
|
|
1548
|
+
} & IRunPropertiesOptions;
|
|
1549
|
+
|
|
1405
1550
|
export declare type IParagraphStyleOptions = {
|
|
1406
1551
|
readonly id: string;
|
|
1407
1552
|
} & IBaseParagraphStyleOptions;
|
|
@@ -1435,6 +1580,9 @@ export declare type IPropertiesOptions = {
|
|
|
1435
1580
|
readonly footnotes?: Readonly<Record<string, {
|
|
1436
1581
|
readonly children: readonly Paragraph[];
|
|
1437
1582
|
}>>;
|
|
1583
|
+
readonly endnotes?: Readonly<Record<string, {
|
|
1584
|
+
readonly children: readonly Paragraph[];
|
|
1585
|
+
}>>;
|
|
1438
1586
|
readonly background?: IDocumentBackgroundOptions;
|
|
1439
1587
|
readonly features?: {
|
|
1440
1588
|
readonly trackRevisions?: boolean;
|
|
@@ -1449,11 +1597,13 @@ export declare type IPropertiesOptions = {
|
|
|
1449
1597
|
readonly hyphenation?: IHyphenationOptions;
|
|
1450
1598
|
};
|
|
1451
1599
|
|
|
1452
|
-
export declare type IRunOptions =
|
|
1453
|
-
|
|
1600
|
+
export declare type IRunOptions = IRunOptionsBase & IRunPropertiesOptions;
|
|
1601
|
+
|
|
1602
|
+
declare type IRunOptionsBase = {
|
|
1603
|
+
readonly children?: readonly (FieldInstruction | (typeof PageNumber)[keyof typeof PageNumber] | FootnoteReferenceRun | AnnotationReference | CarriageReturn | ContinuationSeparator | DayLong | DayShort | EndnoteReference | FootnoteReferenceElement | LastRenderedPageBreak | MonthLong | MonthShort | NoBreakHyphen | PageNumberElement | Separator | SoftHyphen | Tab | YearLong | YearShort | XmlComponent | string)[];
|
|
1454
1604
|
readonly break?: number;
|
|
1455
1605
|
readonly text?: string;
|
|
1456
|
-
}
|
|
1606
|
+
};
|
|
1457
1607
|
|
|
1458
1608
|
export declare type IRunPropertiesChangeOptions = {} & IRunPropertiesOptions & IChangedAttributesProperties;
|
|
1459
1609
|
|
|
@@ -1519,7 +1669,13 @@ export declare type ISectionOptions = {
|
|
|
1519
1669
|
readonly children: readonly FileChild[];
|
|
1520
1670
|
};
|
|
1521
1671
|
|
|
1672
|
+
export declare type ISectionPropertiesChangeOptions = IChangedAttributesProperties & ISectionPropertiesOptionsBase;
|
|
1673
|
+
|
|
1522
1674
|
export declare type ISectionPropertiesOptions = {
|
|
1675
|
+
readonly revision?: ISectionPropertiesChangeOptions;
|
|
1676
|
+
} & ISectionPropertiesOptionsBase;
|
|
1677
|
+
|
|
1678
|
+
export declare type ISectionPropertiesOptionsBase = {
|
|
1523
1679
|
readonly page?: {
|
|
1524
1680
|
readonly size?: Partial<IPageSizeAttributes>;
|
|
1525
1681
|
readonly margin?: IPageMarginAttributes;
|
|
@@ -1623,7 +1779,14 @@ export declare type ITableCellOptions = {
|
|
|
1623
1779
|
readonly children: readonly (Paragraph | Table)[];
|
|
1624
1780
|
} & ITableCellPropertiesOptions;
|
|
1625
1781
|
|
|
1782
|
+
declare type ITableCellPropertiesChangeOptions = ITableCellPropertiesOptionsBase & IChangedAttributesProperties;
|
|
1783
|
+
|
|
1626
1784
|
declare type ITableCellPropertiesOptions = {
|
|
1785
|
+
readonly revision?: ITableCellPropertiesChangeOptions;
|
|
1786
|
+
readonly includeIfEmpty?: boolean;
|
|
1787
|
+
} & ITableCellPropertiesOptionsBase;
|
|
1788
|
+
|
|
1789
|
+
declare type ITableCellPropertiesOptionsBase = {
|
|
1627
1790
|
readonly shading?: IShadingAttributesProperties;
|
|
1628
1791
|
readonly margins?: ITableCellMarginOptions;
|
|
1629
1792
|
readonly verticalAlign?: TableVerticalAlign;
|
|
@@ -1633,6 +1796,9 @@ declare type ITableCellPropertiesOptions = {
|
|
|
1633
1796
|
readonly columnSpan?: number;
|
|
1634
1797
|
readonly rowSpan?: number;
|
|
1635
1798
|
readonly borders?: ITableCellBorders;
|
|
1799
|
+
readonly insertion?: IChangedAttributesProperties;
|
|
1800
|
+
readonly deletion?: IChangedAttributesProperties;
|
|
1801
|
+
readonly cellMerge?: ICellMergeAttributes;
|
|
1636
1802
|
};
|
|
1637
1803
|
|
|
1638
1804
|
declare type ITableCellSpacingProperties = {
|
|
@@ -1654,6 +1820,20 @@ export declare type ITableFloatOptions = {
|
|
|
1654
1820
|
readonly overlap?: (typeof OverlapType)[keyof typeof OverlapType];
|
|
1655
1821
|
};
|
|
1656
1822
|
|
|
1823
|
+
declare type ITableGridChangeOptions = {
|
|
1824
|
+
readonly id: number;
|
|
1825
|
+
readonly columnWidths: readonly number[] | readonly PositiveUniversalMeasure[];
|
|
1826
|
+
};
|
|
1827
|
+
|
|
1828
|
+
export declare type ITableLookOptions = {
|
|
1829
|
+
readonly firstRow?: boolean;
|
|
1830
|
+
readonly lastRow?: boolean;
|
|
1831
|
+
readonly firstColumn?: boolean;
|
|
1832
|
+
readonly lastColumn?: boolean;
|
|
1833
|
+
readonly noHBand?: boolean;
|
|
1834
|
+
readonly noVBand?: boolean;
|
|
1835
|
+
};
|
|
1836
|
+
|
|
1657
1837
|
export declare type ITableOfContentsOptions = {
|
|
1658
1838
|
readonly captionLabel?: string;
|
|
1659
1839
|
readonly entriesFromBookmark?: string;
|
|
@@ -1677,6 +1857,7 @@ export declare type ITableOptions = {
|
|
|
1677
1857
|
readonly rows: readonly TableRow[];
|
|
1678
1858
|
readonly width?: ITableWidthProperties;
|
|
1679
1859
|
readonly columnWidths?: readonly number[];
|
|
1860
|
+
readonly columnWidthsRevision?: ITableGridChangeOptions;
|
|
1680
1861
|
readonly margins?: ITableCellMarginOptions;
|
|
1681
1862
|
readonly indent?: ITableWidthProperties;
|
|
1682
1863
|
readonly float?: ITableFloatOptions;
|
|
@@ -1685,10 +1866,19 @@ export declare type ITableOptions = {
|
|
|
1685
1866
|
readonly borders?: ITableBordersOptions;
|
|
1686
1867
|
readonly alignment?: (typeof AlignmentType)[keyof typeof AlignmentType];
|
|
1687
1868
|
readonly visuallyRightToLeft?: boolean;
|
|
1869
|
+
readonly tableLook?: ITableLookOptions;
|
|
1688
1870
|
readonly cellSpacing?: ITableCellSpacingProperties;
|
|
1871
|
+
readonly revision?: ITablePropertiesChangeOptions;
|
|
1689
1872
|
};
|
|
1690
1873
|
|
|
1874
|
+
export declare type ITablePropertiesChangeOptions = ITablePropertiesOptions & IChangedAttributesProperties;
|
|
1875
|
+
|
|
1691
1876
|
export declare type ITablePropertiesOptions = {
|
|
1877
|
+
readonly revision?: ITablePropertiesChangeOptions;
|
|
1878
|
+
readonly includeIfEmpty?: boolean;
|
|
1879
|
+
} & ITablePropertiesOptionsBase;
|
|
1880
|
+
|
|
1881
|
+
export declare type ITablePropertiesOptionsBase = {
|
|
1692
1882
|
readonly width?: ITableWidthProperties;
|
|
1693
1883
|
readonly indent?: ITableWidthProperties;
|
|
1694
1884
|
readonly layout?: (typeof TableLayoutType)[keyof typeof TableLayoutType];
|
|
@@ -1699,6 +1889,7 @@ export declare type ITablePropertiesOptions = {
|
|
|
1699
1889
|
readonly alignment?: (typeof AlignmentType)[keyof typeof AlignmentType];
|
|
1700
1890
|
readonly cellMargin?: ITableCellMarginOptions;
|
|
1701
1891
|
readonly visuallyRightToLeft?: boolean;
|
|
1892
|
+
readonly tableLook?: ITableLookOptions;
|
|
1702
1893
|
readonly cellSpacing?: ITableCellSpacingProperties;
|
|
1703
1894
|
};
|
|
1704
1895
|
|
|
@@ -1706,7 +1897,16 @@ export declare type ITableRowOptions = {
|
|
|
1706
1897
|
readonly children: readonly TableCell[];
|
|
1707
1898
|
} & ITableRowPropertiesOptions;
|
|
1708
1899
|
|
|
1709
|
-
export declare type
|
|
1900
|
+
export declare type ITableRowPropertiesChangeOptions = ITableRowPropertiesOptionsBase & IChangedAttributesProperties;
|
|
1901
|
+
|
|
1902
|
+
export declare type ITableRowPropertiesOptions = ITableRowPropertiesOptionsBase & {
|
|
1903
|
+
readonly insertion?: IChangedAttributesProperties;
|
|
1904
|
+
readonly deletion?: IChangedAttributesProperties;
|
|
1905
|
+
readonly revision?: ITableRowPropertiesChangeOptions;
|
|
1906
|
+
readonly includeIfEmpty?: boolean;
|
|
1907
|
+
};
|
|
1908
|
+
|
|
1909
|
+
export declare type ITableRowPropertiesOptionsBase = {
|
|
1710
1910
|
readonly cantSplit?: boolean;
|
|
1711
1911
|
readonly tableHeader?: boolean;
|
|
1712
1912
|
readonly height?: {
|
|
@@ -1738,10 +1938,18 @@ export declare type IVerticalPositionOptions = {
|
|
|
1738
1938
|
};
|
|
1739
1939
|
|
|
1740
1940
|
declare type IViewWrapper = {
|
|
1741
|
-
readonly View: Document_2 | Footer_2 | Header_2 | FootNotes | XmlComponent;
|
|
1941
|
+
readonly View: Document_2 | Footer_2 | Header_2 | FootNotes | Endnotes | XmlComponent;
|
|
1742
1942
|
readonly Relationships: Relationships;
|
|
1743
1943
|
};
|
|
1744
1944
|
|
|
1945
|
+
export declare type IWpgGroupOptions = {
|
|
1946
|
+
readonly type: "wpg";
|
|
1947
|
+
} & CoreGroupOptions;
|
|
1948
|
+
|
|
1949
|
+
export declare type IWpsShapeOptions = WpsShapeCoreOptions & {
|
|
1950
|
+
readonly type: "wps";
|
|
1951
|
+
} & CoreShapeOptions;
|
|
1952
|
+
|
|
1745
1953
|
export declare interface IXmlableObject extends Record<string, unknown> {
|
|
1746
1954
|
readonly [key: string]: any;
|
|
1747
1955
|
}
|
|
@@ -2157,11 +2365,6 @@ declare type OutlineAttributes = {
|
|
|
2157
2365
|
|
|
2158
2366
|
declare type OutlineFillProperties = OutlineNoFill | OutlineSolidFill;
|
|
2159
2367
|
|
|
2160
|
-
export declare class OutlineLevel extends XmlComponent {
|
|
2161
|
-
readonly level: number;
|
|
2162
|
-
constructor(level: number);
|
|
2163
|
-
}
|
|
2164
|
-
|
|
2165
2368
|
declare type OutlineNoFill = {
|
|
2166
2369
|
readonly type: "noFill";
|
|
2167
2370
|
};
|
|
@@ -2240,10 +2443,6 @@ export declare class PageBreakBefore extends XmlComponent {
|
|
|
2240
2443
|
constructor();
|
|
2241
2444
|
}
|
|
2242
2445
|
|
|
2243
|
-
export declare class PageMargin extends XmlComponent {
|
|
2244
|
-
constructor(top: number | UniversalMeasure, right: number | PositiveUniversalMeasure, bottom: number | UniversalMeasure, left: number | PositiveUniversalMeasure, header: number | PositiveUniversalMeasure, footer: number | PositiveUniversalMeasure, gutter: number | PositiveUniversalMeasure);
|
|
2245
|
-
}
|
|
2246
|
-
|
|
2247
2446
|
export declare const PageNumber: {
|
|
2248
2447
|
readonly CURRENT: "CURRENT";
|
|
2249
2448
|
readonly TOTAL_PAGES: "TOTAL_PAGES";
|
|
@@ -2263,18 +2462,6 @@ export declare const PageNumberSeparator: {
|
|
|
2263
2462
|
readonly EN_DASH: "endash";
|
|
2264
2463
|
};
|
|
2265
2464
|
|
|
2266
|
-
export declare class PageNumberType extends XmlComponent {
|
|
2267
|
-
constructor({ start, formatType, separator }: IPageNumberTypeAttributes);
|
|
2268
|
-
}
|
|
2269
|
-
|
|
2270
|
-
export declare class PageNumberTypeAttributes extends XmlAttributeComponent<IPageNumberTypeAttributes> {
|
|
2271
|
-
protected readonly xmlKeys: {
|
|
2272
|
-
start: string;
|
|
2273
|
-
formatType: string;
|
|
2274
|
-
separator: string;
|
|
2275
|
-
};
|
|
2276
|
-
}
|
|
2277
|
-
|
|
2278
2465
|
export declare const PageOrientation: {
|
|
2279
2466
|
readonly PORTRAIT: "portrait";
|
|
2280
2467
|
readonly LANDSCAPE: "landscape";
|
|
@@ -2314,17 +2501,25 @@ export declare class ParagraphProperties extends IgnoreIfEmptyXmlComponent {
|
|
|
2314
2501
|
prepForXml(context: IContext): IXmlableObject | undefined;
|
|
2315
2502
|
}
|
|
2316
2503
|
|
|
2504
|
+
export declare class ParagraphPropertiesChange extends XmlComponent {
|
|
2505
|
+
constructor(options: IParagraphPropertiesChangeOptions);
|
|
2506
|
+
}
|
|
2507
|
+
|
|
2317
2508
|
export declare class ParagraphPropertiesDefaults extends XmlComponent {
|
|
2318
2509
|
constructor(options?: IParagraphStylePropertiesOptions);
|
|
2319
2510
|
}
|
|
2320
2511
|
|
|
2512
|
+
export declare class ParagraphRunProperties extends RunProperties {
|
|
2513
|
+
constructor(options?: IParagraphRunPropertiesOptions);
|
|
2514
|
+
}
|
|
2515
|
+
|
|
2321
2516
|
export declare const patchDetector: ({ data }: PatchDetectorOptions) => Promise<readonly string[]>;
|
|
2322
2517
|
|
|
2323
2518
|
declare type PatchDetectorOptions = {
|
|
2324
2519
|
readonly data: InputDataType;
|
|
2325
2520
|
};
|
|
2326
2521
|
|
|
2327
|
-
export declare const patchDocument: <T extends
|
|
2522
|
+
export declare const patchDocument: <T extends PatchDocumentOutputType = PatchDocumentOutputType>({ outputType, data, patches, keepOriginalStyles, placeholderDelimiters, recursive, }: PatchDocumentOptions<T>) => Promise<OutputByType[T]>;
|
|
2328
2523
|
|
|
2329
2524
|
export declare type PatchDocumentOptions<T extends PatchDocumentOutputType = PatchDocumentOutputType> = {
|
|
2330
2525
|
readonly outputType: T;
|
|
@@ -2407,17 +2602,13 @@ declare type RegularMediaData = {
|
|
|
2407
2602
|
readonly type: "jpg" | "png" | "gif" | "bmp";
|
|
2408
2603
|
};
|
|
2409
2604
|
|
|
2410
|
-
declare class Relationship extends XmlComponent {
|
|
2411
|
-
constructor(id: string, type: RelationshipType, target: string, targetMode?: (typeof TargetModeType)[keyof typeof TargetModeType]);
|
|
2412
|
-
}
|
|
2413
|
-
|
|
2414
2605
|
declare class Relationships extends XmlComponent {
|
|
2415
2606
|
constructor();
|
|
2416
|
-
|
|
2607
|
+
addRelationship(id: number | string, type: RelationshipType, target: string, targetMode?: (typeof TargetModeType)[keyof typeof TargetModeType]): void;
|
|
2417
2608
|
get RelationshipCount(): number;
|
|
2418
2609
|
}
|
|
2419
2610
|
|
|
2420
|
-
declare type RelationshipType = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/image" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/settings" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/fontTable" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/webSettings" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/numbering" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/header" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/footer" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument" | "http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/custom-properties" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/footnotes" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/font";
|
|
2611
|
+
declare type RelationshipType = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/image" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/settings" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/fontTable" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/webSettings" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/numbering" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/header" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/footer" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument" | "http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/custom-properties" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/footnotes" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/endnotes" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments" | "http://schemas.openxmlformats.org/officeDocument/2006/relationships/font";
|
|
2421
2612
|
|
|
2422
2613
|
export declare const RelativeHorizontalPosition: {
|
|
2423
2614
|
readonly CENTER: "center";
|
|
@@ -2438,16 +2629,16 @@ export declare const RelativeVerticalPosition: {
|
|
|
2438
2629
|
readonly TOP: "top";
|
|
2439
2630
|
};
|
|
2440
2631
|
|
|
2632
|
+
declare type RgbColorOptions = {
|
|
2633
|
+
readonly type: "rgb";
|
|
2634
|
+
readonly value: string;
|
|
2635
|
+
};
|
|
2636
|
+
|
|
2441
2637
|
export declare class Run extends XmlComponent {
|
|
2442
2638
|
protected readonly properties: RunProperties;
|
|
2443
2639
|
constructor(options: IRunOptions);
|
|
2444
2640
|
}
|
|
2445
2641
|
|
|
2446
|
-
export declare class RunFonts extends XmlComponent {
|
|
2447
|
-
constructor(name: string, hint?: string);
|
|
2448
|
-
constructor(attrs: string | IFontAttributesProperties);
|
|
2449
|
-
}
|
|
2450
|
-
|
|
2451
2642
|
export declare class RunProperties extends IgnoreIfEmptyXmlComponent {
|
|
2452
2643
|
constructor(options?: IRunPropertiesOptions);
|
|
2453
2644
|
push(item: XmlComponent): void;
|
|
@@ -2481,6 +2672,11 @@ declare const SchemeColor: {
|
|
|
2481
2672
|
readonly PHCLR: "phClr";
|
|
2482
2673
|
};
|
|
2483
2674
|
|
|
2675
|
+
declare type SchemeColorOptions = {
|
|
2676
|
+
readonly type: "scheme";
|
|
2677
|
+
readonly value: (typeof SchemeColor)[keyof typeof SchemeColor];
|
|
2678
|
+
};
|
|
2679
|
+
|
|
2484
2680
|
export declare const sectionMarginDefaults: {
|
|
2485
2681
|
TOP: number;
|
|
2486
2682
|
RIGHT: number;
|
|
@@ -2498,10 +2694,14 @@ export declare const sectionPageSizeDefaults: {
|
|
|
2498
2694
|
};
|
|
2499
2695
|
|
|
2500
2696
|
export declare class SectionProperties extends XmlComponent {
|
|
2501
|
-
constructor({ page: { size: { width, height, orientation, }, margin: { top, right, bottom, left, header, footer, gutter, }, pageNumbers, borders, textDirection, }, grid: { linePitch, charSpace, type: gridType }, headerWrapperGroup, footerWrapperGroup, lineNumbers, titlePage, verticalAlign, column, type, }?: ISectionPropertiesOptions);
|
|
2697
|
+
constructor({ page: { size: { width, height, orientation, }, margin: { top, right, bottom, left, header, footer, gutter, }, pageNumbers, borders, textDirection, }, grid: { linePitch, charSpace, type: gridType }, headerWrapperGroup, footerWrapperGroup, lineNumbers, titlePage, verticalAlign, column, type, revision, }?: ISectionPropertiesOptions);
|
|
2502
2698
|
private addHeaderFooterGroup;
|
|
2503
2699
|
}
|
|
2504
2700
|
|
|
2701
|
+
export declare class SectionPropertiesChange extends XmlComponent {
|
|
2702
|
+
constructor(options: ISectionPropertiesChangeOptions);
|
|
2703
|
+
}
|
|
2704
|
+
|
|
2505
2705
|
export declare const SectionType: {
|
|
2506
2706
|
readonly NEXT_PAGE: "nextPage";
|
|
2507
2707
|
readonly NEXT_COLUMN: "nextColumn";
|
|
@@ -2510,20 +2710,8 @@ export declare const SectionType: {
|
|
|
2510
2710
|
readonly ODD_PAGE: "oddPage";
|
|
2511
2711
|
};
|
|
2512
2712
|
|
|
2513
|
-
export declare class SectionTypeAttributes extends XmlAttributeComponent<{
|
|
2514
|
-
readonly val: (typeof SectionType)[keyof typeof SectionType];
|
|
2515
|
-
}> {
|
|
2516
|
-
protected readonly xmlKeys: {
|
|
2517
|
-
val: string;
|
|
2518
|
-
};
|
|
2519
|
-
}
|
|
2520
|
-
|
|
2521
2713
|
export declare type SectionVerticalAlign = (typeof VerticalAlignSection)[keyof typeof VerticalAlignSection];
|
|
2522
2714
|
|
|
2523
|
-
declare class Separate extends XmlComponent {
|
|
2524
|
-
constructor(dirty?: boolean);
|
|
2525
|
-
}
|
|
2526
|
-
|
|
2527
2715
|
export declare class Separator extends EmptyElement {
|
|
2528
2716
|
constructor();
|
|
2529
2717
|
}
|
|
@@ -2536,10 +2724,6 @@ declare class Settings extends XmlComponent {
|
|
|
2536
2724
|
constructor(options: ISettingsOptions);
|
|
2537
2725
|
}
|
|
2538
2726
|
|
|
2539
|
-
export declare class Shading extends XmlComponent {
|
|
2540
|
-
constructor({ fill, color, type }: IShadingAttributesProperties);
|
|
2541
|
-
}
|
|
2542
|
-
|
|
2543
2727
|
export declare const ShadingType: {
|
|
2544
2728
|
readonly CLEAR: "clear";
|
|
2545
2729
|
readonly DIAGONAL_CROSS: "diagCross";
|
|
@@ -2598,14 +2782,14 @@ export declare class SoftHyphen extends EmptyElement {
|
|
|
2598
2782
|
constructor();
|
|
2599
2783
|
}
|
|
2600
2784
|
|
|
2785
|
+
declare type SolidFillOptions = RgbColorOptions | SchemeColorOptions;
|
|
2786
|
+
|
|
2601
2787
|
export declare const SpaceType: {
|
|
2602
2788
|
readonly DEFAULT: "default";
|
|
2603
2789
|
readonly PRESERVE: "preserve";
|
|
2604
2790
|
};
|
|
2605
2791
|
|
|
2606
|
-
export declare
|
|
2607
|
-
constructor(options: ISpacingProperties);
|
|
2608
|
-
}
|
|
2792
|
+
export declare const standardizeData: (data: string | Buffer | Uint8Array | ArrayBuffer) => Buffer | Uint8Array | ArrayBuffer;
|
|
2609
2793
|
|
|
2610
2794
|
export declare class StringContainer extends XmlComponent {
|
|
2611
2795
|
constructor(name: string, val: string);
|
|
@@ -2619,20 +2803,16 @@ export declare class StringValueElement extends XmlComponent {
|
|
|
2619
2803
|
constructor(name: string, val: string);
|
|
2620
2804
|
}
|
|
2621
2805
|
|
|
2622
|
-
|
|
2623
|
-
constructor(styleId: string);
|
|
2624
|
-
}
|
|
2625
|
-
|
|
2626
|
-
declare class Style_2 extends XmlComponent {
|
|
2806
|
+
declare class Style extends XmlComponent {
|
|
2627
2807
|
constructor(attributes: IStyleAttributes, options: IStyleOptions);
|
|
2628
2808
|
}
|
|
2629
2809
|
|
|
2630
|
-
export declare class StyleForCharacter extends
|
|
2810
|
+
export declare class StyleForCharacter extends Style {
|
|
2631
2811
|
private readonly runProperties;
|
|
2632
2812
|
constructor(options: ICharacterStyleOptions);
|
|
2633
2813
|
}
|
|
2634
2814
|
|
|
2635
|
-
export declare class StyleForParagraph extends
|
|
2815
|
+
export declare class StyleForParagraph extends Style {
|
|
2636
2816
|
private readonly paragraphProperties;
|
|
2637
2817
|
private readonly runProperties;
|
|
2638
2818
|
constructor(options: IParagraphStyleOptions);
|
|
@@ -2667,20 +2847,8 @@ export declare class Tab extends EmptyElement {
|
|
|
2667
2847
|
constructor();
|
|
2668
2848
|
}
|
|
2669
2849
|
|
|
2670
|
-
export declare class TabAttributes extends XmlAttributeComponent<{
|
|
2671
|
-
readonly val: (typeof TabStopType)[keyof typeof TabStopType];
|
|
2672
|
-
readonly pos: string | number;
|
|
2673
|
-
readonly leader?: (typeof LeaderType)[keyof typeof LeaderType];
|
|
2674
|
-
}> {
|
|
2675
|
-
protected readonly xmlKeys: {
|
|
2676
|
-
val: string;
|
|
2677
|
-
pos: string;
|
|
2678
|
-
leader: string;
|
|
2679
|
-
};
|
|
2680
|
-
}
|
|
2681
|
-
|
|
2682
2850
|
export declare class Table extends FileChild {
|
|
2683
|
-
constructor({ rows, width, columnWidths, margins, indent, float, layout, style, borders, alignment, visuallyRightToLeft, cellSpacing, }: ITableOptions);
|
|
2851
|
+
constructor({ rows, width, columnWidths, columnWidthsRevision, margins, indent, float, layout, style, borders, alignment, visuallyRightToLeft, tableLook, cellSpacing, revision, }: ITableOptions);
|
|
2684
2852
|
}
|
|
2685
2853
|
|
|
2686
2854
|
export declare const TableAnchorType: {
|
|
@@ -2690,38 +2858,7 @@ export declare const TableAnchorType: {
|
|
|
2690
2858
|
};
|
|
2691
2859
|
|
|
2692
2860
|
export declare class TableBorders extends XmlComponent {
|
|
2693
|
-
static readonly NONE:
|
|
2694
|
-
top: {
|
|
2695
|
-
style: "none";
|
|
2696
|
-
size: number;
|
|
2697
|
-
color: string;
|
|
2698
|
-
};
|
|
2699
|
-
bottom: {
|
|
2700
|
-
style: "none";
|
|
2701
|
-
size: number;
|
|
2702
|
-
color: string;
|
|
2703
|
-
};
|
|
2704
|
-
left: {
|
|
2705
|
-
style: "none";
|
|
2706
|
-
size: number;
|
|
2707
|
-
color: string;
|
|
2708
|
-
};
|
|
2709
|
-
right: {
|
|
2710
|
-
style: "none";
|
|
2711
|
-
size: number;
|
|
2712
|
-
color: string;
|
|
2713
|
-
};
|
|
2714
|
-
insideHorizontal: {
|
|
2715
|
-
style: "none";
|
|
2716
|
-
size: number;
|
|
2717
|
-
color: string;
|
|
2718
|
-
};
|
|
2719
|
-
insideVertical: {
|
|
2720
|
-
style: "none";
|
|
2721
|
-
size: number;
|
|
2722
|
-
color: string;
|
|
2723
|
-
};
|
|
2724
|
-
};
|
|
2861
|
+
static readonly NONE: ITableBordersOptions;
|
|
2725
2862
|
constructor(options: ITableBordersOptions);
|
|
2726
2863
|
}
|
|
2727
2864
|
|
|
@@ -2735,21 +2872,20 @@ export declare class TableCellBorders extends IgnoreIfEmptyXmlComponent {
|
|
|
2735
2872
|
constructor(options: ITableCellBorders);
|
|
2736
2873
|
}
|
|
2737
2874
|
|
|
2738
|
-
export declare class TableFloatProperties extends XmlComponent {
|
|
2739
|
-
constructor({ horizontalAnchor, verticalAnchor, absoluteHorizontalPosition, relativeHorizontalPosition, absoluteVerticalPosition, relativeVerticalPosition, bottomFromText, topFromText, leftFromText, rightFromText, overlap, }: ITableFloatOptions);
|
|
2740
|
-
}
|
|
2741
|
-
|
|
2742
|
-
export declare class TableLayout extends XmlComponent {
|
|
2743
|
-
constructor(type: (typeof TableLayoutType)[keyof typeof TableLayoutType]);
|
|
2744
|
-
}
|
|
2745
|
-
|
|
2746
2875
|
export declare const TableLayoutType: {
|
|
2747
2876
|
readonly AUTOFIT: "autofit";
|
|
2748
2877
|
readonly FIXED: "fixed";
|
|
2749
2878
|
};
|
|
2750
2879
|
|
|
2751
2880
|
export declare class TableOfContents extends FileChild {
|
|
2752
|
-
constructor(alias?: string, properties?: ITableOfContentsOptions
|
|
2881
|
+
constructor(alias?: string, { contentChildren, cachedEntries, beginDirty, ...properties }?: ITableOfContentsOptions & {
|
|
2882
|
+
readonly contentChildren?: readonly (XmlComponent | string)[];
|
|
2883
|
+
readonly cachedEntries?: readonly ToCEntry[];
|
|
2884
|
+
readonly beginDirty?: boolean;
|
|
2885
|
+
});
|
|
2886
|
+
private getTabStopsForLevel;
|
|
2887
|
+
private buildCachedContentRun;
|
|
2888
|
+
private buildCachedContentParagraphChild;
|
|
2753
2889
|
}
|
|
2754
2890
|
|
|
2755
2891
|
export declare class TableProperties extends IgnoreIfEmptyXmlComponent {
|
|
@@ -2767,33 +2903,15 @@ export declare class TableRow extends XmlComponent {
|
|
|
2767
2903
|
columnIndexToRootIndex(columnIndex: number, allowEndNewCell?: boolean): number;
|
|
2768
2904
|
}
|
|
2769
2905
|
|
|
2770
|
-
export declare class TableRowHeight extends XmlComponent {
|
|
2771
|
-
constructor(value: number | PositiveUniversalMeasure, rule: (typeof HeightRule)[keyof typeof HeightRule]);
|
|
2772
|
-
}
|
|
2773
|
-
|
|
2774
|
-
export declare class TableRowHeightAttributes extends XmlAttributeComponent<{
|
|
2775
|
-
readonly value: number | string;
|
|
2776
|
-
readonly rule: (typeof HeightRule)[keyof typeof HeightRule];
|
|
2777
|
-
}> {
|
|
2778
|
-
protected readonly xmlKeys: {
|
|
2779
|
-
value: string;
|
|
2780
|
-
rule: string;
|
|
2781
|
-
};
|
|
2782
|
-
}
|
|
2783
|
-
|
|
2784
2906
|
export declare class TableRowProperties extends IgnoreIfEmptyXmlComponent {
|
|
2785
2907
|
constructor(options: ITableRowPropertiesOptions);
|
|
2786
2908
|
}
|
|
2787
2909
|
|
|
2788
|
-
export declare
|
|
2789
|
-
|
|
2790
|
-
export declare class TableWidthElement extends XmlComponent {
|
|
2791
|
-
constructor(name: string, { type, size }: ITableWidthProperties);
|
|
2910
|
+
export declare class TableRowPropertiesChange extends XmlComponent {
|
|
2911
|
+
constructor(options: ITableRowPropertiesChangeOptions);
|
|
2792
2912
|
}
|
|
2793
2913
|
|
|
2794
|
-
export declare
|
|
2795
|
-
constructor(tabDefinitions: readonly TabStopDefinition[]);
|
|
2796
|
-
}
|
|
2914
|
+
export declare type TableVerticalAlign = (typeof VerticalAlignTable)[keyof typeof VerticalAlignTable];
|
|
2797
2915
|
|
|
2798
2916
|
export declare type TabStopDefinition = {
|
|
2799
2917
|
readonly type: (typeof TabStopType)[keyof typeof TabStopType];
|
|
@@ -2801,10 +2919,6 @@ export declare type TabStopDefinition = {
|
|
|
2801
2919
|
readonly leader?: (typeof LeaderType)[keyof typeof LeaderType];
|
|
2802
2920
|
};
|
|
2803
2921
|
|
|
2804
|
-
export declare class TabStopItem extends XmlComponent {
|
|
2805
|
-
constructor({ type, position, leader }: TabStopDefinition);
|
|
2806
|
-
}
|
|
2807
|
-
|
|
2808
2922
|
export declare const TabStopPosition: {
|
|
2809
2923
|
readonly MAX: 9026;
|
|
2810
2924
|
};
|
|
@@ -2871,18 +2985,17 @@ export declare class ThematicBreak extends XmlComponent {
|
|
|
2871
2985
|
constructor();
|
|
2872
2986
|
}
|
|
2873
2987
|
|
|
2874
|
-
|
|
2988
|
+
declare type ToCEntry = {
|
|
2989
|
+
readonly title: string;
|
|
2990
|
+
readonly level: number;
|
|
2991
|
+
readonly page?: number;
|
|
2992
|
+
readonly href?: string;
|
|
2993
|
+
};
|
|
2875
2994
|
|
|
2876
|
-
export declare
|
|
2877
|
-
constructor(value: (typeof SectionType)[keyof typeof SectionType]);
|
|
2878
|
-
}
|
|
2995
|
+
export declare const twipsMeasureValue: (val: PositiveUniversalMeasure | number) => PositiveUniversalMeasure | number;
|
|
2879
2996
|
|
|
2880
2997
|
export declare const uCharHexNumber: (val: string) => string;
|
|
2881
2998
|
|
|
2882
|
-
export declare class Underline extends XmlComponent {
|
|
2883
|
-
constructor(underlineType?: (typeof UnderlineType)[keyof typeof UnderlineType], color?: string);
|
|
2884
|
-
}
|
|
2885
|
-
|
|
2886
2999
|
export declare const UnderlineType: {
|
|
2887
3000
|
readonly SINGLE: "single";
|
|
2888
3001
|
readonly WORDS: "words";
|
|
@@ -2925,18 +3038,6 @@ export declare const VerticalAlign: {
|
|
|
2925
3038
|
readonly BOTTOM: "bottom";
|
|
2926
3039
|
};
|
|
2927
3040
|
|
|
2928
|
-
export declare class VerticalAlignAttributes extends XmlAttributeComponent<{
|
|
2929
|
-
readonly verticalAlign?: (typeof VerticalAlign)[keyof typeof VerticalAlign];
|
|
2930
|
-
}> {
|
|
2931
|
-
protected readonly xmlKeys: {
|
|
2932
|
-
verticalAlign: string;
|
|
2933
|
-
};
|
|
2934
|
-
}
|
|
2935
|
-
|
|
2936
|
-
export declare class VerticalAlignElement extends XmlComponent {
|
|
2937
|
-
constructor(value: (typeof VerticalAlign)[keyof typeof VerticalAlign]);
|
|
2938
|
-
}
|
|
2939
|
-
|
|
2940
3041
|
export declare const VerticalAlignSection: {
|
|
2941
3042
|
readonly BOTH: "both";
|
|
2942
3043
|
readonly TOP: "top";
|
|
@@ -2950,10 +3051,21 @@ export declare const VerticalAlignTable: {
|
|
|
2950
3051
|
readonly BOTTOM: "bottom";
|
|
2951
3052
|
};
|
|
2952
3053
|
|
|
3054
|
+
export declare enum VerticalAnchor {
|
|
3055
|
+
CENTER = "ctr",
|
|
3056
|
+
TOP = "t",
|
|
3057
|
+
BOTTOM = "b"
|
|
3058
|
+
}
|
|
3059
|
+
|
|
2953
3060
|
export declare class VerticalMerge extends XmlComponent {
|
|
2954
3061
|
constructor(value: (typeof VerticalMergeType)[keyof typeof VerticalMergeType]);
|
|
2955
3062
|
}
|
|
2956
3063
|
|
|
3064
|
+
export declare const VerticalMergeRevisionType: {
|
|
3065
|
+
readonly CONTINUE: "cont";
|
|
3066
|
+
readonly RESTART: "rest";
|
|
3067
|
+
};
|
|
3068
|
+
|
|
2957
3069
|
export declare const VerticalMergeType: {
|
|
2958
3070
|
readonly CONTINUE: "continue";
|
|
2959
3071
|
readonly RESTART: "restart";
|
|
@@ -3017,20 +3129,39 @@ export declare const WORKAROUND3 = "";
|
|
|
3017
3129
|
|
|
3018
3130
|
export declare const WORKAROUND4 = "";
|
|
3019
3131
|
|
|
3020
|
-
export declare
|
|
3021
|
-
|
|
3022
|
-
|
|
3132
|
+
export declare type WpgCommonMediaData = {
|
|
3133
|
+
readonly outline?: OutlineOptions;
|
|
3134
|
+
readonly solidFill?: SolidFillOptions;
|
|
3135
|
+
};
|
|
3023
3136
|
|
|
3024
|
-
export declare class
|
|
3025
|
-
|
|
3137
|
+
export declare class WpgGroupRun extends Run {
|
|
3138
|
+
private readonly wpgGroupData;
|
|
3139
|
+
private readonly mediaDatas;
|
|
3140
|
+
constructor(options: IWpgGroupOptions);
|
|
3141
|
+
prepForXml(context: IContext): IXmlableObject | undefined;
|
|
3026
3142
|
}
|
|
3027
3143
|
|
|
3028
|
-
export declare
|
|
3029
|
-
|
|
3030
|
-
|
|
3144
|
+
export declare type WpgMediaData = {
|
|
3145
|
+
readonly type: "wpg";
|
|
3146
|
+
readonly transformation: IMediaDataTransformation;
|
|
3147
|
+
readonly children: readonly IGroupChildMediaData[];
|
|
3148
|
+
};
|
|
3149
|
+
|
|
3150
|
+
export declare type WpsMediaData = {
|
|
3151
|
+
readonly type: "wps";
|
|
3152
|
+
readonly transformation: IMediaDataTransformation;
|
|
3153
|
+
readonly data: WpsShapeCoreOptions;
|
|
3154
|
+
};
|
|
3155
|
+
|
|
3156
|
+
declare type WpsShapeCoreOptions = {
|
|
3157
|
+
readonly children: readonly Paragraph[];
|
|
3158
|
+
readonly nonVisualProperties?: INonVisualShapePropertiesOptions;
|
|
3159
|
+
readonly bodyProperties?: IBodyPropertiesOptions;
|
|
3160
|
+
};
|
|
3031
3161
|
|
|
3032
|
-
export declare class
|
|
3033
|
-
|
|
3162
|
+
export declare class WpsShapeRun extends Run {
|
|
3163
|
+
private readonly wpsShapeData;
|
|
3164
|
+
constructor(options: IWpsShapeOptions);
|
|
3034
3165
|
}
|
|
3035
3166
|
|
|
3036
3167
|
export declare abstract class XmlAttributeComponent<T extends Record<string, any>> extends BaseXmlComponent {
|