docx 8.2.4 → 8.3.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/build/export/packer/next-compiler.d.ts +1 -1
- package/build/export/packer/packer.d.ts +11 -11
- package/build/file/border/border.d.ts +30 -30
- package/build/file/document/body/section-properties/properties/doc-grid.d.ts +8 -8
- package/build/file/document/body/section-properties/properties/header-footer-reference.d.ts +11 -11
- package/build/file/document/body/section-properties/properties/line-number.d.ts +6 -6
- package/build/file/document/body/section-properties/properties/page-borders.d.ts +16 -16
- package/build/file/document/body/section-properties/properties/page-number.d.ts +9 -9
- package/build/file/document/body/section-properties/properties/page-size.d.ts +6 -6
- package/build/file/document/body/section-properties/properties/page-text-direction.d.ts +5 -5
- package/build/file/document/body/section-properties/properties/section-type.d.ts +9 -9
- package/build/file/document/body/section-properties/section-properties.d.ts +5 -5
- package/build/file/drawing/floating/align.d.ts +1 -1
- package/build/file/drawing/floating/floating-position.d.ts +24 -24
- package/build/file/drawing/text-wrap/text-wrapping.d.ts +14 -14
- package/build/file/footer-wrapper.d.ts +1 -1
- package/build/file/footnotes/footnote/footnote.d.ts +5 -5
- package/build/file/header-wrapper.d.ts +1 -1
- package/build/file/numbering/level.d.ts +73 -73
- package/build/file/paragraph/formatting/alignment.d.ts +17 -17
- package/build/file/paragraph/formatting/spacing.d.ts +7 -7
- package/build/file/paragraph/formatting/style.d.ts +9 -9
- package/build/file/paragraph/formatting/tab-stop.d.ts +26 -26
- package/build/file/paragraph/frame/frame-properties.d.ts +32 -32
- package/build/file/paragraph/links/hyperlink.d.ts +4 -4
- package/build/file/paragraph/properties.d.ts +4 -2
- package/build/file/paragraph/run/emphasis-mark.d.ts +5 -5
- package/build/file/paragraph/run/positional-tab.d.ts +19 -19
- package/build/file/paragraph/run/properties.d.ts +12 -12
- package/build/file/paragraph/run/run-components/text.d.ts +1 -1
- package/build/file/paragraph/run/run.d.ts +6 -6
- package/build/file/paragraph/run/text-attributes.d.ts +1 -1
- package/build/file/paragraph/run/underline.d.ts +21 -21
- package/build/file/relationships/relationship/relationship.d.ts +4 -4
- package/build/file/relationships/relationships.d.ts +1 -1
- package/build/file/shading/shading.d.ts +40 -40
- package/build/file/shared/alignment.d.ts +14 -14
- package/build/file/shared/number-format.d.ts +64 -64
- package/build/file/shared/space-type.d.ts +4 -4
- package/build/file/table/table-cell/table-cell-components.d.ts +11 -11
- package/build/file/table/table-cell/table-cell-properties.d.ts +3 -3
- package/build/file/table/table-properties/table-borders.d.ts +7 -7
- package/build/file/table/table-properties/table-cell-margin.d.ts +7 -7
- package/build/file/table/table-properties/table-float-properties.d.ts +29 -29
- package/build/file/table/table-properties/table-layout.d.ts +5 -5
- package/build/file/table/table-properties/table-properties.d.ts +2 -2
- package/build/file/table/table-row/table-row-height.d.ts +7 -7
- package/build/file/table/table-row/table-row-properties.d.ts +1 -1
- package/build/file/table/table-width.d.ts +7 -7
- package/build/file/table/table.d.ts +2 -2
- package/build/file/vertical-align/vertical-align.d.ts +7 -7
- package/build/index.cjs +939 -773
- package/build/index.iife.js +939 -773
- package/build/index.mjs +939 -773
- package/build/index.umd.js +939 -773
- package/build/patcher/from-docx.d.ts +6 -6
- package/build/patcher/relationship-manager.d.ts +1 -1
- package/package.json +10 -10
package/build/index.mjs
CHANGED
|
@@ -2146,11 +2146,11 @@ function requireBuffer() {
|
|
|
2146
2146
|
function base64ToBytes(str) {
|
|
2147
2147
|
return base64.toByteArray(base64clean(str));
|
|
2148
2148
|
}
|
|
2149
|
-
function blitBuffer(
|
|
2149
|
+
function blitBuffer(src, dst, offset, length) {
|
|
2150
2150
|
for (var i = 0; i < length; ++i) {
|
|
2151
|
-
if (i + offset >= dst.length || i >=
|
|
2151
|
+
if (i + offset >= dst.length || i >= src.length)
|
|
2152
2152
|
break;
|
|
2153
|
-
dst[i + offset] =
|
|
2153
|
+
dst[i + offset] = src[i];
|
|
2154
2154
|
}
|
|
2155
2155
|
return i;
|
|
2156
2156
|
}
|
|
@@ -2455,6 +2455,21 @@ function requireHasSymbols() {
|
|
|
2455
2455
|
};
|
|
2456
2456
|
return hasSymbols;
|
|
2457
2457
|
}
|
|
2458
|
+
var hasProto;
|
|
2459
|
+
var hasRequiredHasProto;
|
|
2460
|
+
function requireHasProto() {
|
|
2461
|
+
if (hasRequiredHasProto)
|
|
2462
|
+
return hasProto;
|
|
2463
|
+
hasRequiredHasProto = 1;
|
|
2464
|
+
var test = {
|
|
2465
|
+
foo: {}
|
|
2466
|
+
};
|
|
2467
|
+
var $Object = Object;
|
|
2468
|
+
hasProto = function hasProto2() {
|
|
2469
|
+
return { __proto__: test }.foo === test.foo && !({ __proto__: null } instanceof $Object);
|
|
2470
|
+
};
|
|
2471
|
+
return hasProto;
|
|
2472
|
+
}
|
|
2458
2473
|
var implementation;
|
|
2459
2474
|
var hasRequiredImplementation;
|
|
2460
2475
|
function requireImplementation() {
|
|
@@ -2462,39 +2477,65 @@ function requireImplementation() {
|
|
|
2462
2477
|
return implementation;
|
|
2463
2478
|
hasRequiredImplementation = 1;
|
|
2464
2479
|
var ERROR_MESSAGE = "Function.prototype.bind called on incompatible ";
|
|
2465
|
-
var slice = Array.prototype.slice;
|
|
2466
2480
|
var toStr = Object.prototype.toString;
|
|
2481
|
+
var max = Math.max;
|
|
2467
2482
|
var funcType = "[object Function]";
|
|
2483
|
+
var concatty = function concatty2(a, b) {
|
|
2484
|
+
var arr = [];
|
|
2485
|
+
for (var i = 0; i < a.length; i += 1) {
|
|
2486
|
+
arr[i] = a[i];
|
|
2487
|
+
}
|
|
2488
|
+
for (var j = 0; j < b.length; j += 1) {
|
|
2489
|
+
arr[j + a.length] = b[j];
|
|
2490
|
+
}
|
|
2491
|
+
return arr;
|
|
2492
|
+
};
|
|
2493
|
+
var slicy = function slicy2(arrLike, offset) {
|
|
2494
|
+
var arr = [];
|
|
2495
|
+
for (var i = offset || 0, j = 0; i < arrLike.length; i += 1, j += 1) {
|
|
2496
|
+
arr[j] = arrLike[i];
|
|
2497
|
+
}
|
|
2498
|
+
return arr;
|
|
2499
|
+
};
|
|
2500
|
+
var joiny = function(arr, joiner) {
|
|
2501
|
+
var str = "";
|
|
2502
|
+
for (var i = 0; i < arr.length; i += 1) {
|
|
2503
|
+
str += arr[i];
|
|
2504
|
+
if (i + 1 < arr.length) {
|
|
2505
|
+
str += joiner;
|
|
2506
|
+
}
|
|
2507
|
+
}
|
|
2508
|
+
return str;
|
|
2509
|
+
};
|
|
2468
2510
|
implementation = function bind(that) {
|
|
2469
2511
|
var target = this;
|
|
2470
|
-
if (typeof target !== "function" || toStr.
|
|
2512
|
+
if (typeof target !== "function" || toStr.apply(target) !== funcType) {
|
|
2471
2513
|
throw new TypeError(ERROR_MESSAGE + target);
|
|
2472
2514
|
}
|
|
2473
|
-
var args =
|
|
2515
|
+
var args = slicy(arguments, 1);
|
|
2474
2516
|
var bound;
|
|
2475
2517
|
var binder = function() {
|
|
2476
2518
|
if (this instanceof bound) {
|
|
2477
2519
|
var result = target.apply(
|
|
2478
2520
|
this,
|
|
2479
|
-
args
|
|
2521
|
+
concatty(args, arguments)
|
|
2480
2522
|
);
|
|
2481
2523
|
if (Object(result) === result) {
|
|
2482
2524
|
return result;
|
|
2483
2525
|
}
|
|
2484
2526
|
return this;
|
|
2485
|
-
} else {
|
|
2486
|
-
return target.apply(
|
|
2487
|
-
that,
|
|
2488
|
-
args.concat(slice.call(arguments))
|
|
2489
|
-
);
|
|
2490
2527
|
}
|
|
2528
|
+
return target.apply(
|
|
2529
|
+
that,
|
|
2530
|
+
concatty(args, arguments)
|
|
2531
|
+
);
|
|
2491
2532
|
};
|
|
2492
|
-
var boundLength =
|
|
2533
|
+
var boundLength = max(0, target.length - args.length);
|
|
2493
2534
|
var boundArgs = [];
|
|
2494
2535
|
for (var i = 0; i < boundLength; i++) {
|
|
2495
|
-
boundArgs
|
|
2536
|
+
boundArgs[i] = "$" + i;
|
|
2496
2537
|
}
|
|
2497
|
-
bound = Function("binder", "return function (" + boundArgs
|
|
2538
|
+
bound = Function("binder", "return function (" + joiny(boundArgs, ",") + "){ return binder.apply(this,arguments); }")(binder);
|
|
2498
2539
|
if (target.prototype) {
|
|
2499
2540
|
var Empty = function Empty2() {
|
|
2500
2541
|
};
|
|
@@ -2516,15 +2557,17 @@ function requireFunctionBind() {
|
|
|
2516
2557
|
functionBind = Function.prototype.bind || implementation2;
|
|
2517
2558
|
return functionBind;
|
|
2518
2559
|
}
|
|
2519
|
-
var
|
|
2520
|
-
var
|
|
2521
|
-
function
|
|
2522
|
-
if (
|
|
2523
|
-
return
|
|
2524
|
-
|
|
2560
|
+
var hasown;
|
|
2561
|
+
var hasRequiredHasown;
|
|
2562
|
+
function requireHasown() {
|
|
2563
|
+
if (hasRequiredHasown)
|
|
2564
|
+
return hasown;
|
|
2565
|
+
hasRequiredHasown = 1;
|
|
2566
|
+
var call = Function.prototype.call;
|
|
2567
|
+
var $hasOwn = Object.prototype.hasOwnProperty;
|
|
2525
2568
|
var bind = requireFunctionBind();
|
|
2526
|
-
|
|
2527
|
-
return
|
|
2569
|
+
hasown = bind.call(call, $hasOwn);
|
|
2570
|
+
return hasown;
|
|
2528
2571
|
}
|
|
2529
2572
|
var getIntrinsic;
|
|
2530
2573
|
var hasRequiredGetIntrinsic;
|
|
@@ -2566,16 +2609,17 @@ function requireGetIntrinsic() {
|
|
|
2566
2609
|
}
|
|
2567
2610
|
}() : throwTypeError;
|
|
2568
2611
|
var hasSymbols2 = requireHasSymbols()();
|
|
2569
|
-
var
|
|
2612
|
+
var hasProto2 = requireHasProto()();
|
|
2613
|
+
var getProto = Object.getPrototypeOf || (hasProto2 ? function(x) {
|
|
2570
2614
|
return x.__proto__;
|
|
2571
|
-
};
|
|
2615
|
+
} : null);
|
|
2572
2616
|
var needsEval = {};
|
|
2573
|
-
var TypedArray = typeof Uint8Array === "undefined" ? undefined$1 : getProto(Uint8Array);
|
|
2617
|
+
var TypedArray = typeof Uint8Array === "undefined" || !getProto ? undefined$1 : getProto(Uint8Array);
|
|
2574
2618
|
var INTRINSICS = {
|
|
2575
2619
|
"%AggregateError%": typeof AggregateError === "undefined" ? undefined$1 : AggregateError,
|
|
2576
2620
|
"%Array%": Array,
|
|
2577
2621
|
"%ArrayBuffer%": typeof ArrayBuffer === "undefined" ? undefined$1 : ArrayBuffer,
|
|
2578
|
-
"%ArrayIteratorPrototype%": hasSymbols2 ? getProto([][Symbol.iterator]()) : undefined$1,
|
|
2622
|
+
"%ArrayIteratorPrototype%": hasSymbols2 && getProto ? getProto([][Symbol.iterator]()) : undefined$1,
|
|
2579
2623
|
"%AsyncFromSyncIteratorPrototype%": undefined$1,
|
|
2580
2624
|
"%AsyncFunction%": needsEval,
|
|
2581
2625
|
"%AsyncGenerator%": needsEval,
|
|
@@ -2583,6 +2627,8 @@ function requireGetIntrinsic() {
|
|
|
2583
2627
|
"%AsyncIteratorPrototype%": needsEval,
|
|
2584
2628
|
"%Atomics%": typeof Atomics === "undefined" ? undefined$1 : Atomics,
|
|
2585
2629
|
"%BigInt%": typeof BigInt === "undefined" ? undefined$1 : BigInt,
|
|
2630
|
+
"%BigInt64Array%": typeof BigInt64Array === "undefined" ? undefined$1 : BigInt64Array,
|
|
2631
|
+
"%BigUint64Array%": typeof BigUint64Array === "undefined" ? undefined$1 : BigUint64Array,
|
|
2586
2632
|
"%Boolean%": Boolean,
|
|
2587
2633
|
"%DataView%": typeof DataView === "undefined" ? undefined$1 : DataView,
|
|
2588
2634
|
"%Date%": Date,
|
|
@@ -2604,10 +2650,10 @@ function requireGetIntrinsic() {
|
|
|
2604
2650
|
"%Int32Array%": typeof Int32Array === "undefined" ? undefined$1 : Int32Array,
|
|
2605
2651
|
"%isFinite%": isFinite,
|
|
2606
2652
|
"%isNaN%": isNaN,
|
|
2607
|
-
"%IteratorPrototype%": hasSymbols2 ? getProto(getProto([][Symbol.iterator]())) : undefined$1,
|
|
2653
|
+
"%IteratorPrototype%": hasSymbols2 && getProto ? getProto(getProto([][Symbol.iterator]())) : undefined$1,
|
|
2608
2654
|
"%JSON%": typeof JSON === "object" ? JSON : undefined$1,
|
|
2609
2655
|
"%Map%": typeof Map === "undefined" ? undefined$1 : Map,
|
|
2610
|
-
"%MapIteratorPrototype%": typeof Map === "undefined" || !hasSymbols2 ? undefined$1 : getProto((/* @__PURE__ */ new Map())[Symbol.iterator]()),
|
|
2656
|
+
"%MapIteratorPrototype%": typeof Map === "undefined" || !hasSymbols2 || !getProto ? undefined$1 : getProto((/* @__PURE__ */ new Map())[Symbol.iterator]()),
|
|
2611
2657
|
"%Math%": Math,
|
|
2612
2658
|
"%Number%": Number,
|
|
2613
2659
|
"%Object%": Object,
|
|
@@ -2620,10 +2666,10 @@ function requireGetIntrinsic() {
|
|
|
2620
2666
|
"%Reflect%": typeof Reflect === "undefined" ? undefined$1 : Reflect,
|
|
2621
2667
|
"%RegExp%": RegExp,
|
|
2622
2668
|
"%Set%": typeof Set === "undefined" ? undefined$1 : Set,
|
|
2623
|
-
"%SetIteratorPrototype%": typeof Set === "undefined" || !hasSymbols2 ? undefined$1 : getProto((/* @__PURE__ */ new Set())[Symbol.iterator]()),
|
|
2669
|
+
"%SetIteratorPrototype%": typeof Set === "undefined" || !hasSymbols2 || !getProto ? undefined$1 : getProto((/* @__PURE__ */ new Set())[Symbol.iterator]()),
|
|
2624
2670
|
"%SharedArrayBuffer%": typeof SharedArrayBuffer === "undefined" ? undefined$1 : SharedArrayBuffer,
|
|
2625
2671
|
"%String%": String,
|
|
2626
|
-
"%StringIteratorPrototype%": hasSymbols2 ? getProto(""[Symbol.iterator]()) : undefined$1,
|
|
2672
|
+
"%StringIteratorPrototype%": hasSymbols2 && getProto ? getProto(""[Symbol.iterator]()) : undefined$1,
|
|
2627
2673
|
"%Symbol%": hasSymbols2 ? Symbol : undefined$1,
|
|
2628
2674
|
"%SyntaxError%": $SyntaxError,
|
|
2629
2675
|
"%ThrowTypeError%": ThrowTypeError,
|
|
@@ -2638,6 +2684,14 @@ function requireGetIntrinsic() {
|
|
|
2638
2684
|
"%WeakRef%": typeof WeakRef === "undefined" ? undefined$1 : WeakRef,
|
|
2639
2685
|
"%WeakSet%": typeof WeakSet === "undefined" ? undefined$1 : WeakSet
|
|
2640
2686
|
};
|
|
2687
|
+
if (getProto) {
|
|
2688
|
+
try {
|
|
2689
|
+
null.error;
|
|
2690
|
+
} catch (e) {
|
|
2691
|
+
var errorProto = getProto(getProto(e));
|
|
2692
|
+
INTRINSICS["%Error.prototype%"] = errorProto;
|
|
2693
|
+
}
|
|
2694
|
+
}
|
|
2641
2695
|
var doEval = function doEval2(name) {
|
|
2642
2696
|
var value;
|
|
2643
2697
|
if (name === "%AsyncFunction%") {
|
|
@@ -2653,7 +2707,7 @@ function requireGetIntrinsic() {
|
|
|
2653
2707
|
}
|
|
2654
2708
|
} else if (name === "%AsyncIteratorPrototype%") {
|
|
2655
2709
|
var gen = doEval2("%AsyncGenerator%");
|
|
2656
|
-
if (gen) {
|
|
2710
|
+
if (gen && getProto) {
|
|
2657
2711
|
value = getProto(gen.prototype);
|
|
2658
2712
|
}
|
|
2659
2713
|
}
|
|
@@ -2714,7 +2768,7 @@ function requireGetIntrinsic() {
|
|
|
2714
2768
|
"%WeakSetPrototype%": ["WeakSet", "prototype"]
|
|
2715
2769
|
};
|
|
2716
2770
|
var bind = requireFunctionBind();
|
|
2717
|
-
var hasOwn =
|
|
2771
|
+
var hasOwn = requireHasown();
|
|
2718
2772
|
var $concat = bind.call(Function.call, Array.prototype.concat);
|
|
2719
2773
|
var $spliceApply = bind.call(Function.apply, Array.prototype.splice);
|
|
2720
2774
|
var $replace = bind.call(Function.call, String.prototype.replace);
|
|
@@ -2823,6 +2877,156 @@ function requireGetIntrinsic() {
|
|
|
2823
2877
|
return getIntrinsic;
|
|
2824
2878
|
}
|
|
2825
2879
|
var callBind = { exports: {} };
|
|
2880
|
+
var hasPropertyDescriptors_1;
|
|
2881
|
+
var hasRequiredHasPropertyDescriptors;
|
|
2882
|
+
function requireHasPropertyDescriptors() {
|
|
2883
|
+
if (hasRequiredHasPropertyDescriptors)
|
|
2884
|
+
return hasPropertyDescriptors_1;
|
|
2885
|
+
hasRequiredHasPropertyDescriptors = 1;
|
|
2886
|
+
var GetIntrinsic = requireGetIntrinsic();
|
|
2887
|
+
var $defineProperty = GetIntrinsic("%Object.defineProperty%", true);
|
|
2888
|
+
var hasPropertyDescriptors = function hasPropertyDescriptors2() {
|
|
2889
|
+
if ($defineProperty) {
|
|
2890
|
+
try {
|
|
2891
|
+
$defineProperty({}, "a", { value: 1 });
|
|
2892
|
+
return true;
|
|
2893
|
+
} catch (e) {
|
|
2894
|
+
return false;
|
|
2895
|
+
}
|
|
2896
|
+
}
|
|
2897
|
+
return false;
|
|
2898
|
+
};
|
|
2899
|
+
hasPropertyDescriptors.hasArrayLengthDefineBug = function hasArrayLengthDefineBug() {
|
|
2900
|
+
if (!hasPropertyDescriptors()) {
|
|
2901
|
+
return null;
|
|
2902
|
+
}
|
|
2903
|
+
try {
|
|
2904
|
+
return $defineProperty([], "length", { value: 1 }).length !== 1;
|
|
2905
|
+
} catch (e) {
|
|
2906
|
+
return true;
|
|
2907
|
+
}
|
|
2908
|
+
};
|
|
2909
|
+
hasPropertyDescriptors_1 = hasPropertyDescriptors;
|
|
2910
|
+
return hasPropertyDescriptors_1;
|
|
2911
|
+
}
|
|
2912
|
+
var gopd;
|
|
2913
|
+
var hasRequiredGopd;
|
|
2914
|
+
function requireGopd() {
|
|
2915
|
+
if (hasRequiredGopd)
|
|
2916
|
+
return gopd;
|
|
2917
|
+
hasRequiredGopd = 1;
|
|
2918
|
+
var GetIntrinsic = requireGetIntrinsic();
|
|
2919
|
+
var $gOPD = GetIntrinsic("%Object.getOwnPropertyDescriptor%", true);
|
|
2920
|
+
if ($gOPD) {
|
|
2921
|
+
try {
|
|
2922
|
+
$gOPD([], "length");
|
|
2923
|
+
} catch (e) {
|
|
2924
|
+
$gOPD = null;
|
|
2925
|
+
}
|
|
2926
|
+
}
|
|
2927
|
+
gopd = $gOPD;
|
|
2928
|
+
return gopd;
|
|
2929
|
+
}
|
|
2930
|
+
var defineDataProperty;
|
|
2931
|
+
var hasRequiredDefineDataProperty;
|
|
2932
|
+
function requireDefineDataProperty() {
|
|
2933
|
+
if (hasRequiredDefineDataProperty)
|
|
2934
|
+
return defineDataProperty;
|
|
2935
|
+
hasRequiredDefineDataProperty = 1;
|
|
2936
|
+
var hasPropertyDescriptors = requireHasPropertyDescriptors()();
|
|
2937
|
+
var GetIntrinsic = requireGetIntrinsic();
|
|
2938
|
+
var $defineProperty = hasPropertyDescriptors && GetIntrinsic("%Object.defineProperty%", true);
|
|
2939
|
+
if ($defineProperty) {
|
|
2940
|
+
try {
|
|
2941
|
+
$defineProperty({}, "a", { value: 1 });
|
|
2942
|
+
} catch (e) {
|
|
2943
|
+
$defineProperty = false;
|
|
2944
|
+
}
|
|
2945
|
+
}
|
|
2946
|
+
var $SyntaxError = GetIntrinsic("%SyntaxError%");
|
|
2947
|
+
var $TypeError = GetIntrinsic("%TypeError%");
|
|
2948
|
+
var gopd2 = requireGopd();
|
|
2949
|
+
defineDataProperty = function defineDataProperty2(obj, property, value) {
|
|
2950
|
+
if (!obj || typeof obj !== "object" && typeof obj !== "function") {
|
|
2951
|
+
throw new $TypeError("`obj` must be an object or a function`");
|
|
2952
|
+
}
|
|
2953
|
+
if (typeof property !== "string" && typeof property !== "symbol") {
|
|
2954
|
+
throw new $TypeError("`property` must be a string or a symbol`");
|
|
2955
|
+
}
|
|
2956
|
+
if (arguments.length > 3 && typeof arguments[3] !== "boolean" && arguments[3] !== null) {
|
|
2957
|
+
throw new $TypeError("`nonEnumerable`, if provided, must be a boolean or null");
|
|
2958
|
+
}
|
|
2959
|
+
if (arguments.length > 4 && typeof arguments[4] !== "boolean" && arguments[4] !== null) {
|
|
2960
|
+
throw new $TypeError("`nonWritable`, if provided, must be a boolean or null");
|
|
2961
|
+
}
|
|
2962
|
+
if (arguments.length > 5 && typeof arguments[5] !== "boolean" && arguments[5] !== null) {
|
|
2963
|
+
throw new $TypeError("`nonConfigurable`, if provided, must be a boolean or null");
|
|
2964
|
+
}
|
|
2965
|
+
if (arguments.length > 6 && typeof arguments[6] !== "boolean") {
|
|
2966
|
+
throw new $TypeError("`loose`, if provided, must be a boolean");
|
|
2967
|
+
}
|
|
2968
|
+
var nonEnumerable = arguments.length > 3 ? arguments[3] : null;
|
|
2969
|
+
var nonWritable = arguments.length > 4 ? arguments[4] : null;
|
|
2970
|
+
var nonConfigurable = arguments.length > 5 ? arguments[5] : null;
|
|
2971
|
+
var loose = arguments.length > 6 ? arguments[6] : false;
|
|
2972
|
+
var desc = !!gopd2 && gopd2(obj, property);
|
|
2973
|
+
if ($defineProperty) {
|
|
2974
|
+
$defineProperty(obj, property, {
|
|
2975
|
+
configurable: nonConfigurable === null && desc ? desc.configurable : !nonConfigurable,
|
|
2976
|
+
enumerable: nonEnumerable === null && desc ? desc.enumerable : !nonEnumerable,
|
|
2977
|
+
value,
|
|
2978
|
+
writable: nonWritable === null && desc ? desc.writable : !nonWritable
|
|
2979
|
+
});
|
|
2980
|
+
} else if (loose || !nonEnumerable && !nonWritable && !nonConfigurable) {
|
|
2981
|
+
obj[property] = value;
|
|
2982
|
+
} else {
|
|
2983
|
+
throw new $SyntaxError("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.");
|
|
2984
|
+
}
|
|
2985
|
+
};
|
|
2986
|
+
return defineDataProperty;
|
|
2987
|
+
}
|
|
2988
|
+
var setFunctionLength;
|
|
2989
|
+
var hasRequiredSetFunctionLength;
|
|
2990
|
+
function requireSetFunctionLength() {
|
|
2991
|
+
if (hasRequiredSetFunctionLength)
|
|
2992
|
+
return setFunctionLength;
|
|
2993
|
+
hasRequiredSetFunctionLength = 1;
|
|
2994
|
+
var GetIntrinsic = requireGetIntrinsic();
|
|
2995
|
+
var define = requireDefineDataProperty();
|
|
2996
|
+
var hasDescriptors = requireHasPropertyDescriptors()();
|
|
2997
|
+
var gOPD = requireGopd();
|
|
2998
|
+
var $TypeError = GetIntrinsic("%TypeError%");
|
|
2999
|
+
var $floor = GetIntrinsic("%Math.floor%");
|
|
3000
|
+
setFunctionLength = function setFunctionLength2(fn, length) {
|
|
3001
|
+
if (typeof fn !== "function") {
|
|
3002
|
+
throw new $TypeError("`fn` is not a function");
|
|
3003
|
+
}
|
|
3004
|
+
if (typeof length !== "number" || length < 0 || length > 4294967295 || $floor(length) !== length) {
|
|
3005
|
+
throw new $TypeError("`length` must be a positive 32-bit integer");
|
|
3006
|
+
}
|
|
3007
|
+
var loose = arguments.length > 2 && !!arguments[2];
|
|
3008
|
+
var functionLengthIsConfigurable = true;
|
|
3009
|
+
var functionLengthIsWritable = true;
|
|
3010
|
+
if ("length" in fn && gOPD) {
|
|
3011
|
+
var desc = gOPD(fn, "length");
|
|
3012
|
+
if (desc && !desc.configurable) {
|
|
3013
|
+
functionLengthIsConfigurable = false;
|
|
3014
|
+
}
|
|
3015
|
+
if (desc && !desc.writable) {
|
|
3016
|
+
functionLengthIsWritable = false;
|
|
3017
|
+
}
|
|
3018
|
+
}
|
|
3019
|
+
if (functionLengthIsConfigurable || functionLengthIsWritable || !loose) {
|
|
3020
|
+
if (hasDescriptors) {
|
|
3021
|
+
define(fn, "length", length, true, true);
|
|
3022
|
+
} else {
|
|
3023
|
+
define(fn, "length", length);
|
|
3024
|
+
}
|
|
3025
|
+
}
|
|
3026
|
+
return fn;
|
|
3027
|
+
};
|
|
3028
|
+
return setFunctionLength;
|
|
3029
|
+
}
|
|
2826
3030
|
var hasRequiredCallBind;
|
|
2827
3031
|
function requireCallBind() {
|
|
2828
3032
|
if (hasRequiredCallBind)
|
|
@@ -2831,10 +3035,11 @@ function requireCallBind() {
|
|
|
2831
3035
|
(function(module) {
|
|
2832
3036
|
var bind = requireFunctionBind();
|
|
2833
3037
|
var GetIntrinsic = requireGetIntrinsic();
|
|
3038
|
+
var setFunctionLength2 = requireSetFunctionLength();
|
|
3039
|
+
var $TypeError = GetIntrinsic("%TypeError%");
|
|
2834
3040
|
var $apply = GetIntrinsic("%Function.prototype.apply%");
|
|
2835
3041
|
var $call = GetIntrinsic("%Function.prototype.call%");
|
|
2836
3042
|
var $reflectApply = GetIntrinsic("%Reflect.apply%", true) || bind.call($call, $apply);
|
|
2837
|
-
var $gOPD = GetIntrinsic("%Object.getOwnPropertyDescriptor%", true);
|
|
2838
3043
|
var $defineProperty = GetIntrinsic("%Object.defineProperty%", true);
|
|
2839
3044
|
var $max = GetIntrinsic("%Math.max%");
|
|
2840
3045
|
if ($defineProperty) {
|
|
@@ -2845,18 +3050,15 @@ function requireCallBind() {
|
|
|
2845
3050
|
}
|
|
2846
3051
|
}
|
|
2847
3052
|
module.exports = function callBind2(originalFunction) {
|
|
2848
|
-
|
|
2849
|
-
|
|
2850
|
-
var desc = $gOPD(func, "length");
|
|
2851
|
-
if (desc.configurable) {
|
|
2852
|
-
$defineProperty(
|
|
2853
|
-
func,
|
|
2854
|
-
"length",
|
|
2855
|
-
{ value: 1 + $max(0, originalFunction.length - (arguments.length - 1)) }
|
|
2856
|
-
);
|
|
2857
|
-
}
|
|
3053
|
+
if (typeof originalFunction !== "function") {
|
|
3054
|
+
throw new $TypeError("a function is required");
|
|
2858
3055
|
}
|
|
2859
|
-
|
|
3056
|
+
var func = $reflectApply(bind, $call, arguments);
|
|
3057
|
+
return setFunctionLength2(
|
|
3058
|
+
func,
|
|
3059
|
+
1 + $max(0, originalFunction.length - (arguments.length - 1)),
|
|
3060
|
+
true
|
|
3061
|
+
);
|
|
2860
3062
|
};
|
|
2861
3063
|
var applyBind = function applyBind2() {
|
|
2862
3064
|
return $reflectApply(bind, $apply, arguments);
|
|
@@ -3166,38 +3368,23 @@ function requireAvailableTypedArrays() {
|
|
|
3166
3368
|
};
|
|
3167
3369
|
return availableTypedArrays;
|
|
3168
3370
|
}
|
|
3169
|
-
var
|
|
3170
|
-
var
|
|
3171
|
-
function
|
|
3172
|
-
if (
|
|
3173
|
-
return
|
|
3174
|
-
|
|
3175
|
-
var GetIntrinsic = requireGetIntrinsic();
|
|
3176
|
-
var $gOPD = GetIntrinsic("%Object.getOwnPropertyDescriptor%", true);
|
|
3177
|
-
if ($gOPD) {
|
|
3178
|
-
try {
|
|
3179
|
-
$gOPD([], "length");
|
|
3180
|
-
} catch (e) {
|
|
3181
|
-
$gOPD = null;
|
|
3182
|
-
}
|
|
3183
|
-
}
|
|
3184
|
-
gopd = $gOPD;
|
|
3185
|
-
return gopd;
|
|
3186
|
-
}
|
|
3187
|
-
var isTypedArray;
|
|
3188
|
-
var hasRequiredIsTypedArray;
|
|
3189
|
-
function requireIsTypedArray() {
|
|
3190
|
-
if (hasRequiredIsTypedArray)
|
|
3191
|
-
return isTypedArray;
|
|
3192
|
-
hasRequiredIsTypedArray = 1;
|
|
3371
|
+
var whichTypedArray;
|
|
3372
|
+
var hasRequiredWhichTypedArray;
|
|
3373
|
+
function requireWhichTypedArray() {
|
|
3374
|
+
if (hasRequiredWhichTypedArray)
|
|
3375
|
+
return whichTypedArray;
|
|
3376
|
+
hasRequiredWhichTypedArray = 1;
|
|
3193
3377
|
var forEach = requireForEach();
|
|
3194
3378
|
var availableTypedArrays2 = requireAvailableTypedArrays();
|
|
3379
|
+
var callBind2 = requireCallBind();
|
|
3195
3380
|
var callBound2 = requireCallBound();
|
|
3381
|
+
var gOPD = requireGopd();
|
|
3196
3382
|
var $toString = callBound2("Object.prototype.toString");
|
|
3197
3383
|
var hasToStringTag = requireShams()();
|
|
3198
|
-
var gOPD = requireGopd();
|
|
3199
3384
|
var g = typeof globalThis === "undefined" ? commonjsGlobal : globalThis;
|
|
3200
3385
|
var typedArrays = availableTypedArrays2();
|
|
3386
|
+
var $slice = callBound2("String.prototype.slice");
|
|
3387
|
+
var getPrototypeOf = Object.getPrototypeOf;
|
|
3201
3388
|
var $indexOf = callBound2("Array.prototype.indexOf", true) || function indexOf(array, value) {
|
|
3202
3389
|
for (var i = 0; i < array.length; i += 1) {
|
|
3203
3390
|
if (array[i] === value) {
|
|
@@ -3206,9 +3393,7 @@ function requireIsTypedArray() {
|
|
|
3206
3393
|
}
|
|
3207
3394
|
return -1;
|
|
3208
3395
|
};
|
|
3209
|
-
var
|
|
3210
|
-
var toStrTags = {};
|
|
3211
|
-
var getPrototypeOf = Object.getPrototypeOf;
|
|
3396
|
+
var cache = { __proto__: null };
|
|
3212
3397
|
if (hasToStringTag && gOPD && getPrototypeOf) {
|
|
3213
3398
|
forEach(typedArrays, function(typedArray) {
|
|
3214
3399
|
var arr = new g[typedArray]();
|
|
@@ -3219,97 +3404,78 @@ function requireIsTypedArray() {
|
|
|
3219
3404
|
var superProto = getPrototypeOf(proto);
|
|
3220
3405
|
descriptor = gOPD(superProto, Symbol.toStringTag);
|
|
3221
3406
|
}
|
|
3222
|
-
|
|
3407
|
+
cache["$" + typedArray] = callBind2(descriptor.get);
|
|
3408
|
+
}
|
|
3409
|
+
});
|
|
3410
|
+
} else {
|
|
3411
|
+
forEach(typedArrays, function(typedArray) {
|
|
3412
|
+
var arr = new g[typedArray]();
|
|
3413
|
+
var fn = arr.slice || arr.set;
|
|
3414
|
+
if (fn) {
|
|
3415
|
+
cache["$" + typedArray] = callBind2(fn);
|
|
3223
3416
|
}
|
|
3224
3417
|
});
|
|
3225
3418
|
}
|
|
3226
3419
|
var tryTypedArrays = function tryAllTypedArrays(value) {
|
|
3227
|
-
var
|
|
3228
|
-
forEach(
|
|
3229
|
-
if (!
|
|
3420
|
+
var found = false;
|
|
3421
|
+
forEach(cache, function(getter, typedArray) {
|
|
3422
|
+
if (!found) {
|
|
3230
3423
|
try {
|
|
3231
|
-
|
|
3424
|
+
if ("$" + getter(value) === typedArray) {
|
|
3425
|
+
found = $slice(typedArray, 1);
|
|
3426
|
+
}
|
|
3232
3427
|
} catch (e) {
|
|
3233
3428
|
}
|
|
3234
3429
|
}
|
|
3235
3430
|
});
|
|
3236
|
-
return
|
|
3237
|
-
};
|
|
3238
|
-
isTypedArray = function isTypedArray2(value) {
|
|
3239
|
-
if (!value || typeof value !== "object") {
|
|
3240
|
-
return false;
|
|
3241
|
-
}
|
|
3242
|
-
if (!hasToStringTag || !(Symbol.toStringTag in value)) {
|
|
3243
|
-
var tag = $slice($toString(value), 8, -1);
|
|
3244
|
-
return $indexOf(typedArrays, tag) > -1;
|
|
3245
|
-
}
|
|
3246
|
-
if (!gOPD) {
|
|
3247
|
-
return false;
|
|
3248
|
-
}
|
|
3249
|
-
return tryTypedArrays(value);
|
|
3431
|
+
return found;
|
|
3250
3432
|
};
|
|
3251
|
-
|
|
3252
|
-
|
|
3253
|
-
|
|
3254
|
-
|
|
3255
|
-
function requireWhichTypedArray() {
|
|
3256
|
-
if (hasRequiredWhichTypedArray)
|
|
3257
|
-
return whichTypedArray;
|
|
3258
|
-
hasRequiredWhichTypedArray = 1;
|
|
3259
|
-
var forEach = requireForEach();
|
|
3260
|
-
var availableTypedArrays2 = requireAvailableTypedArrays();
|
|
3261
|
-
var callBound2 = requireCallBound();
|
|
3262
|
-
var gOPD = requireGopd();
|
|
3263
|
-
var $toString = callBound2("Object.prototype.toString");
|
|
3264
|
-
var hasToStringTag = requireShams()();
|
|
3265
|
-
var g = typeof globalThis === "undefined" ? commonjsGlobal : globalThis;
|
|
3266
|
-
var typedArrays = availableTypedArrays2();
|
|
3267
|
-
var $slice = callBound2("String.prototype.slice");
|
|
3268
|
-
var toStrTags = {};
|
|
3269
|
-
var getPrototypeOf = Object.getPrototypeOf;
|
|
3270
|
-
if (hasToStringTag && gOPD && getPrototypeOf) {
|
|
3271
|
-
forEach(typedArrays, function(typedArray) {
|
|
3272
|
-
if (typeof g[typedArray] === "function") {
|
|
3273
|
-
var arr = new g[typedArray]();
|
|
3274
|
-
if (Symbol.toStringTag in arr) {
|
|
3275
|
-
var proto = getPrototypeOf(arr);
|
|
3276
|
-
var descriptor = gOPD(proto, Symbol.toStringTag);
|
|
3277
|
-
if (!descriptor) {
|
|
3278
|
-
var superProto = getPrototypeOf(proto);
|
|
3279
|
-
descriptor = gOPD(superProto, Symbol.toStringTag);
|
|
3280
|
-
}
|
|
3281
|
-
toStrTags[typedArray] = descriptor.get;
|
|
3282
|
-
}
|
|
3283
|
-
}
|
|
3284
|
-
});
|
|
3285
|
-
}
|
|
3286
|
-
var tryTypedArrays = function tryAllTypedArrays(value) {
|
|
3287
|
-
var foundName = false;
|
|
3288
|
-
forEach(toStrTags, function(getter, typedArray) {
|
|
3289
|
-
if (!foundName) {
|
|
3433
|
+
var trySlices = function tryAllSlices(value) {
|
|
3434
|
+
var found = false;
|
|
3435
|
+
forEach(cache, function(getter, name) {
|
|
3436
|
+
if (!found) {
|
|
3290
3437
|
try {
|
|
3291
|
-
|
|
3292
|
-
|
|
3293
|
-
foundName = name;
|
|
3294
|
-
}
|
|
3438
|
+
getter(value);
|
|
3439
|
+
found = $slice(name, 1);
|
|
3295
3440
|
} catch (e) {
|
|
3296
3441
|
}
|
|
3297
3442
|
}
|
|
3298
3443
|
});
|
|
3299
|
-
return
|
|
3444
|
+
return found;
|
|
3300
3445
|
};
|
|
3301
|
-
var isTypedArray2 = requireIsTypedArray();
|
|
3302
3446
|
whichTypedArray = function whichTypedArray2(value) {
|
|
3303
|
-
if (!
|
|
3447
|
+
if (!value || typeof value !== "object") {
|
|
3304
3448
|
return false;
|
|
3305
3449
|
}
|
|
3306
|
-
if (!hasToStringTag
|
|
3307
|
-
|
|
3450
|
+
if (!hasToStringTag) {
|
|
3451
|
+
var tag = $slice($toString(value), 8, -1);
|
|
3452
|
+
if ($indexOf(typedArrays, tag) > -1) {
|
|
3453
|
+
return tag;
|
|
3454
|
+
}
|
|
3455
|
+
if (tag !== "Object") {
|
|
3456
|
+
return false;
|
|
3457
|
+
}
|
|
3458
|
+
return trySlices(value);
|
|
3459
|
+
}
|
|
3460
|
+
if (!gOPD) {
|
|
3461
|
+
return null;
|
|
3308
3462
|
}
|
|
3309
3463
|
return tryTypedArrays(value);
|
|
3310
3464
|
};
|
|
3311
3465
|
return whichTypedArray;
|
|
3312
3466
|
}
|
|
3467
|
+
var isTypedArray;
|
|
3468
|
+
var hasRequiredIsTypedArray;
|
|
3469
|
+
function requireIsTypedArray() {
|
|
3470
|
+
if (hasRequiredIsTypedArray)
|
|
3471
|
+
return isTypedArray;
|
|
3472
|
+
hasRequiredIsTypedArray = 1;
|
|
3473
|
+
var whichTypedArray2 = requireWhichTypedArray();
|
|
3474
|
+
isTypedArray = function isTypedArray2(value) {
|
|
3475
|
+
return !!whichTypedArray2(value);
|
|
3476
|
+
};
|
|
3477
|
+
return isTypedArray;
|
|
3478
|
+
}
|
|
3313
3479
|
var hasRequiredTypes;
|
|
3314
3480
|
function requireTypes() {
|
|
3315
3481
|
if (hasRequiredTypes)
|
|
@@ -4190,8 +4356,8 @@ function requireBuffer_list() {
|
|
|
4190
4356
|
var _require = requireBuffer(), Buffer2 = _require.Buffer;
|
|
4191
4357
|
var _require2 = requireUtil(), inspect = _require2.inspect;
|
|
4192
4358
|
var custom = inspect && inspect.custom || "inspect";
|
|
4193
|
-
function copyBuffer(
|
|
4194
|
-
Buffer2.prototype.copy.call(
|
|
4359
|
+
function copyBuffer(src, target, offset) {
|
|
4360
|
+
Buffer2.prototype.copy.call(src, target, offset);
|
|
4195
4361
|
}
|
|
4196
4362
|
buffer_list = /* @__PURE__ */ function() {
|
|
4197
4363
|
function BufferList() {
|
|
@@ -5245,9 +5411,9 @@ function requireSafeBuffer() {
|
|
|
5245
5411
|
(function(module, exports) {
|
|
5246
5412
|
var buffer2 = requireBuffer();
|
|
5247
5413
|
var Buffer2 = buffer2.Buffer;
|
|
5248
|
-
function copyProps(
|
|
5249
|
-
for (var key in
|
|
5250
|
-
dst[key] =
|
|
5414
|
+
function copyProps(src, dst) {
|
|
5415
|
+
for (var key in src) {
|
|
5416
|
+
dst[key] = src[key];
|
|
5251
5417
|
}
|
|
5252
5418
|
}
|
|
5253
5419
|
if (Buffer2.from && Buffer2.alloc && Buffer2.allocUnsafe && Buffer2.allocUnsafeSlow) {
|
|
@@ -6234,7 +6400,7 @@ function require_stream_readable() {
|
|
|
6234
6400
|
errorOrDestroy(this, new ERR_METHOD_NOT_IMPLEMENTED("_read()"));
|
|
6235
6401
|
};
|
|
6236
6402
|
Readable.prototype.pipe = function(dest, pipeOpts) {
|
|
6237
|
-
var
|
|
6403
|
+
var src = this;
|
|
6238
6404
|
var state2 = this._readableState;
|
|
6239
6405
|
switch (state2.pipesCount) {
|
|
6240
6406
|
case 0:
|
|
@@ -6254,11 +6420,11 @@ function require_stream_readable() {
|
|
|
6254
6420
|
if (state2.endEmitted)
|
|
6255
6421
|
process$1.nextTick(endFn);
|
|
6256
6422
|
else
|
|
6257
|
-
|
|
6423
|
+
src.once("end", endFn);
|
|
6258
6424
|
dest.on("unpipe", onunpipe);
|
|
6259
6425
|
function onunpipe(readable, unpipeInfo) {
|
|
6260
6426
|
debug("onunpipe");
|
|
6261
|
-
if (readable ===
|
|
6427
|
+
if (readable === src) {
|
|
6262
6428
|
if (unpipeInfo && unpipeInfo.hasUnpiped === false) {
|
|
6263
6429
|
unpipeInfo.hasUnpiped = true;
|
|
6264
6430
|
cleanup();
|
|
@@ -6269,7 +6435,7 @@ function require_stream_readable() {
|
|
|
6269
6435
|
debug("onend");
|
|
6270
6436
|
dest.end();
|
|
6271
6437
|
}
|
|
6272
|
-
var ondrain = pipeOnDrain(
|
|
6438
|
+
var ondrain = pipeOnDrain(src);
|
|
6273
6439
|
dest.on("drain", ondrain);
|
|
6274
6440
|
var cleanedUp = false;
|
|
6275
6441
|
function cleanup() {
|
|
@@ -6279,14 +6445,14 @@ function require_stream_readable() {
|
|
|
6279
6445
|
dest.removeListener("drain", ondrain);
|
|
6280
6446
|
dest.removeListener("error", onerror);
|
|
6281
6447
|
dest.removeListener("unpipe", onunpipe);
|
|
6282
|
-
|
|
6283
|
-
|
|
6284
|
-
|
|
6448
|
+
src.removeListener("end", onend);
|
|
6449
|
+
src.removeListener("end", unpipe);
|
|
6450
|
+
src.removeListener("data", ondata);
|
|
6285
6451
|
cleanedUp = true;
|
|
6286
6452
|
if (state2.awaitDrain && (!dest._writableState || dest._writableState.needDrain))
|
|
6287
6453
|
ondrain();
|
|
6288
6454
|
}
|
|
6289
|
-
|
|
6455
|
+
src.on("data", ondata);
|
|
6290
6456
|
function ondata(chunk) {
|
|
6291
6457
|
debug("ondata");
|
|
6292
6458
|
var ret = dest.write(chunk);
|
|
@@ -6296,7 +6462,7 @@ function require_stream_readable() {
|
|
|
6296
6462
|
debug("false write response, pause", state2.awaitDrain);
|
|
6297
6463
|
state2.awaitDrain++;
|
|
6298
6464
|
}
|
|
6299
|
-
|
|
6465
|
+
src.pause();
|
|
6300
6466
|
}
|
|
6301
6467
|
}
|
|
6302
6468
|
function onerror(er) {
|
|
@@ -6320,24 +6486,24 @@ function require_stream_readable() {
|
|
|
6320
6486
|
dest.once("finish", onfinish);
|
|
6321
6487
|
function unpipe() {
|
|
6322
6488
|
debug("unpipe");
|
|
6323
|
-
|
|
6489
|
+
src.unpipe(dest);
|
|
6324
6490
|
}
|
|
6325
|
-
dest.emit("pipe",
|
|
6491
|
+
dest.emit("pipe", src);
|
|
6326
6492
|
if (!state2.flowing) {
|
|
6327
6493
|
debug("pipe resume");
|
|
6328
|
-
|
|
6494
|
+
src.resume();
|
|
6329
6495
|
}
|
|
6330
6496
|
return dest;
|
|
6331
6497
|
};
|
|
6332
|
-
function pipeOnDrain(
|
|
6498
|
+
function pipeOnDrain(src) {
|
|
6333
6499
|
return function pipeOnDrainFunctionResult() {
|
|
6334
|
-
var state2 =
|
|
6500
|
+
var state2 = src._readableState;
|
|
6335
6501
|
debug("pipeOnDrain", state2.awaitDrain);
|
|
6336
6502
|
if (state2.awaitDrain)
|
|
6337
6503
|
state2.awaitDrain--;
|
|
6338
|
-
if (state2.awaitDrain === 0 && EElistenerCount(
|
|
6504
|
+
if (state2.awaitDrain === 0 && EElistenerCount(src, "data")) {
|
|
6339
6505
|
state2.flowing = true;
|
|
6340
|
-
flow(
|
|
6506
|
+
flow(src);
|
|
6341
6507
|
}
|
|
6342
6508
|
};
|
|
6343
6509
|
}
|
|
@@ -6505,7 +6671,7 @@ function require_stream_readable() {
|
|
|
6505
6671
|
});
|
|
6506
6672
|
for (var i in stream) {
|
|
6507
6673
|
if (this[i] === void 0 && typeof stream[i] === "function") {
|
|
6508
|
-
this[i] = function methodWrap(method) {
|
|
6674
|
+
this[i] = /* @__PURE__ */ function methodWrap(method) {
|
|
6509
6675
|
return function methodWrapReturnFunction() {
|
|
6510
6676
|
return stream[method].apply(stream, arguments);
|
|
6511
6677
|
};
|
|
@@ -9284,22 +9450,34 @@ class BuilderElement extends XmlComponent {
|
|
|
9284
9450
|
}
|
|
9285
9451
|
}
|
|
9286
9452
|
}
|
|
9287
|
-
|
|
9288
|
-
|
|
9289
|
-
|
|
9290
|
-
|
|
9291
|
-
|
|
9292
|
-
|
|
9293
|
-
|
|
9294
|
-
|
|
9295
|
-
|
|
9296
|
-
|
|
9297
|
-
|
|
9298
|
-
|
|
9299
|
-
|
|
9300
|
-
|
|
9301
|
-
|
|
9302
|
-
|
|
9453
|
+
const AlignmentType = {
|
|
9454
|
+
/** Align Start */
|
|
9455
|
+
START: "start",
|
|
9456
|
+
/** Align Center */
|
|
9457
|
+
CENTER: "center",
|
|
9458
|
+
/** End */
|
|
9459
|
+
END: "end",
|
|
9460
|
+
/** Justified */
|
|
9461
|
+
BOTH: "both",
|
|
9462
|
+
/** Medium Kashida Length */
|
|
9463
|
+
MEDIUM_KASHIDA: "mediumKashida",
|
|
9464
|
+
/** Distribute All Characters Equally */
|
|
9465
|
+
DISTRIBUTE: "distribute",
|
|
9466
|
+
/** Align to List Tab */
|
|
9467
|
+
NUM_TAB: "numTab",
|
|
9468
|
+
/** Widest Kashida Length */
|
|
9469
|
+
HIGH_KASHIDA: "highKashida",
|
|
9470
|
+
/** Low Kashida Length */
|
|
9471
|
+
LOW_KASHIDA: "lowKashida",
|
|
9472
|
+
/** Thai Language Justification */
|
|
9473
|
+
THAI_DISTRIBUTE: "thaiDistribute",
|
|
9474
|
+
/** Align Left */
|
|
9475
|
+
LEFT: "left",
|
|
9476
|
+
/** Align Right */
|
|
9477
|
+
RIGHT: "right",
|
|
9478
|
+
/** Justified */
|
|
9479
|
+
JUSTIFIED: "both"
|
|
9480
|
+
};
|
|
9303
9481
|
class AlignmentAttributes extends XmlAttributeComponent {
|
|
9304
9482
|
constructor() {
|
|
9305
9483
|
super(...arguments);
|
|
@@ -9336,36 +9514,35 @@ class BordersAttributes extends XmlAttributeComponent {
|
|
|
9336
9514
|
});
|
|
9337
9515
|
}
|
|
9338
9516
|
}
|
|
9339
|
-
|
|
9340
|
-
|
|
9341
|
-
|
|
9342
|
-
|
|
9343
|
-
|
|
9344
|
-
|
|
9345
|
-
|
|
9346
|
-
|
|
9347
|
-
|
|
9348
|
-
|
|
9349
|
-
|
|
9350
|
-
|
|
9351
|
-
|
|
9352
|
-
|
|
9353
|
-
|
|
9354
|
-
|
|
9355
|
-
|
|
9356
|
-
|
|
9357
|
-
|
|
9358
|
-
|
|
9359
|
-
|
|
9360
|
-
|
|
9361
|
-
|
|
9362
|
-
|
|
9363
|
-
|
|
9364
|
-
|
|
9365
|
-
|
|
9366
|
-
|
|
9367
|
-
|
|
9368
|
-
})(BorderStyle || {});
|
|
9517
|
+
const BorderStyle = {
|
|
9518
|
+
SINGLE: "single",
|
|
9519
|
+
DASH_DOT_STROKED: "dashDotStroked",
|
|
9520
|
+
DASHED: "dashed",
|
|
9521
|
+
DASH_SMALL_GAP: "dashSmallGap",
|
|
9522
|
+
DOT_DASH: "dotDash",
|
|
9523
|
+
DOT_DOT_DASH: "dotDotDash",
|
|
9524
|
+
DOTTED: "dotted",
|
|
9525
|
+
DOUBLE: "double",
|
|
9526
|
+
DOUBLE_WAVE: "doubleWave",
|
|
9527
|
+
INSET: "inset",
|
|
9528
|
+
NIL: "nil",
|
|
9529
|
+
NONE: "none",
|
|
9530
|
+
OUTSET: "outset",
|
|
9531
|
+
THICK: "thick",
|
|
9532
|
+
THICK_THIN_LARGE_GAP: "thickThinLargeGap",
|
|
9533
|
+
THICK_THIN_MEDIUM_GAP: "thickThinMediumGap",
|
|
9534
|
+
THICK_THIN_SMALL_GAP: "thickThinSmallGap",
|
|
9535
|
+
THIN_THICK_LARGE_GAP: "thinThickLargeGap",
|
|
9536
|
+
THIN_THICK_MEDIUM_GAP: "thinThickMediumGap",
|
|
9537
|
+
THIN_THICK_SMALL_GAP: "thinThickSmallGap",
|
|
9538
|
+
THIN_THICK_THIN_LARGE_GAP: "thinThickThinLargeGap",
|
|
9539
|
+
THIN_THICK_THIN_MEDIUM_GAP: "thinThickThinMediumGap",
|
|
9540
|
+
THIN_THICK_THIN_SMALL_GAP: "thinThickThinSmallGap",
|
|
9541
|
+
THREE_D_EMBOSS: "threeDEmboss",
|
|
9542
|
+
THREE_D_ENGRAVE: "threeDEngrave",
|
|
9543
|
+
TRIPLE: "triple",
|
|
9544
|
+
WAVE: "wave"
|
|
9545
|
+
};
|
|
9369
9546
|
class Border extends IgnoreIfEmptyXmlComponent {
|
|
9370
9547
|
constructor(options2) {
|
|
9371
9548
|
super("w:pBdr");
|
|
@@ -9433,6 +9610,11 @@ let Break$1 = class Break extends XmlComponent {
|
|
|
9433
9610
|
super("w:br");
|
|
9434
9611
|
}
|
|
9435
9612
|
};
|
|
9613
|
+
const FieldCharacterType = {
|
|
9614
|
+
BEGIN: "begin",
|
|
9615
|
+
END: "end",
|
|
9616
|
+
SEPARATE: "separate"
|
|
9617
|
+
};
|
|
9436
9618
|
class FidCharAttrs extends XmlAttributeComponent {
|
|
9437
9619
|
constructor() {
|
|
9438
9620
|
super(...arguments);
|
|
@@ -9442,107 +9624,104 @@ class FidCharAttrs extends XmlAttributeComponent {
|
|
|
9442
9624
|
class Begin extends XmlComponent {
|
|
9443
9625
|
constructor(dirty) {
|
|
9444
9626
|
super("w:fldChar");
|
|
9445
|
-
this.root.push(new FidCharAttrs({ type:
|
|
9627
|
+
this.root.push(new FidCharAttrs({ type: FieldCharacterType.BEGIN, dirty }));
|
|
9446
9628
|
}
|
|
9447
9629
|
}
|
|
9448
9630
|
class Separate extends XmlComponent {
|
|
9449
9631
|
constructor(dirty) {
|
|
9450
9632
|
super("w:fldChar");
|
|
9451
|
-
this.root.push(new FidCharAttrs({ type:
|
|
9633
|
+
this.root.push(new FidCharAttrs({ type: FieldCharacterType.SEPARATE, dirty }));
|
|
9452
9634
|
}
|
|
9453
9635
|
}
|
|
9454
9636
|
class End extends XmlComponent {
|
|
9455
9637
|
constructor(dirty) {
|
|
9456
9638
|
super("w:fldChar");
|
|
9457
|
-
this.root.push(new FidCharAttrs({ type:
|
|
9458
|
-
}
|
|
9459
|
-
}
|
|
9460
|
-
|
|
9461
|
-
|
|
9462
|
-
|
|
9463
|
-
|
|
9464
|
-
|
|
9465
|
-
|
|
9466
|
-
|
|
9467
|
-
|
|
9468
|
-
|
|
9469
|
-
|
|
9470
|
-
|
|
9471
|
-
|
|
9472
|
-
|
|
9473
|
-
|
|
9474
|
-
|
|
9475
|
-
|
|
9476
|
-
|
|
9477
|
-
|
|
9478
|
-
|
|
9479
|
-
|
|
9480
|
-
|
|
9481
|
-
|
|
9482
|
-
|
|
9483
|
-
|
|
9484
|
-
|
|
9485
|
-
|
|
9486
|
-
|
|
9487
|
-
|
|
9488
|
-
|
|
9489
|
-
|
|
9490
|
-
|
|
9491
|
-
|
|
9492
|
-
|
|
9493
|
-
|
|
9494
|
-
|
|
9495
|
-
|
|
9496
|
-
|
|
9497
|
-
|
|
9498
|
-
|
|
9499
|
-
|
|
9500
|
-
|
|
9501
|
-
|
|
9502
|
-
|
|
9503
|
-
|
|
9504
|
-
|
|
9505
|
-
|
|
9506
|
-
|
|
9507
|
-
|
|
9508
|
-
|
|
9509
|
-
|
|
9510
|
-
|
|
9511
|
-
|
|
9512
|
-
|
|
9513
|
-
|
|
9514
|
-
|
|
9515
|
-
|
|
9516
|
-
|
|
9517
|
-
|
|
9518
|
-
|
|
9519
|
-
|
|
9520
|
-
|
|
9521
|
-
|
|
9522
|
-
|
|
9523
|
-
|
|
9524
|
-
|
|
9525
|
-
|
|
9526
|
-
|
|
9527
|
-
|
|
9528
|
-
|
|
9529
|
-
|
|
9530
|
-
|
|
9531
|
-
|
|
9532
|
-
|
|
9533
|
-
|
|
9534
|
-
|
|
9535
|
-
|
|
9536
|
-
|
|
9537
|
-
|
|
9538
|
-
|
|
9539
|
-
|
|
9540
|
-
|
|
9541
|
-
|
|
9542
|
-
|
|
9543
|
-
SpaceType2["PRESERVE"] = "preserve";
|
|
9544
|
-
return SpaceType2;
|
|
9545
|
-
})(SpaceType || {});
|
|
9639
|
+
this.root.push(new FidCharAttrs({ type: FieldCharacterType.END, dirty }));
|
|
9640
|
+
}
|
|
9641
|
+
}
|
|
9642
|
+
const HorizontalPositionAlign = {
|
|
9643
|
+
CENTER: "center",
|
|
9644
|
+
INSIDE: "inside",
|
|
9645
|
+
LEFT: "left",
|
|
9646
|
+
OUTSIDE: "outside",
|
|
9647
|
+
RIGHT: "right"
|
|
9648
|
+
};
|
|
9649
|
+
const VerticalPositionAlign = {
|
|
9650
|
+
BOTTOM: "bottom",
|
|
9651
|
+
CENTER: "center",
|
|
9652
|
+
INSIDE: "inside",
|
|
9653
|
+
OUTSIDE: "outside",
|
|
9654
|
+
TOP: "top"
|
|
9655
|
+
};
|
|
9656
|
+
const NumberFormat$1 = {
|
|
9657
|
+
DECIMAL: "decimal",
|
|
9658
|
+
UPPER_ROMAN: "upperRoman",
|
|
9659
|
+
LOWER_ROMAN: "lowerRoman",
|
|
9660
|
+
UPPER_LETTER: "upperLetter",
|
|
9661
|
+
LOWER_LETTER: "lowerLetter",
|
|
9662
|
+
ORDINAL: "ordinal",
|
|
9663
|
+
CARDINAL_TEXT: "cardinalText",
|
|
9664
|
+
ORDINAL_TEXT: "ordinalText",
|
|
9665
|
+
HEX: "hex",
|
|
9666
|
+
CHICAGO: "chicago",
|
|
9667
|
+
IDEOGRAPH_DIGITAL: "ideographDigital",
|
|
9668
|
+
JAPANESE_COUNTING: "japaneseCounting",
|
|
9669
|
+
AIUEO: "aiueo",
|
|
9670
|
+
IROHA: "iroha",
|
|
9671
|
+
DECIMAL_FULL_WIDTH: "decimalFullWidth",
|
|
9672
|
+
DECIMAL_HALF_WIDTH: "decimalHalfWidth",
|
|
9673
|
+
JAPANESE_LEGAL: "japaneseLegal",
|
|
9674
|
+
JAPANESE_DIGITAL_TEN_THOUSAND: "japaneseDigitalTenThousand",
|
|
9675
|
+
DECIMAL_ENCLOSED_CIRCLE: "decimalEnclosedCircle",
|
|
9676
|
+
DECIMAL_FULL_WIDTH_2: "decimalFullWidth2",
|
|
9677
|
+
AIUEO_FULL_WIDTH: "aiueoFullWidth",
|
|
9678
|
+
IROHA_FULL_WIDTH: "irohaFullWidth",
|
|
9679
|
+
DECIMAL_ZERO: "decimalZero",
|
|
9680
|
+
BULLET: "bullet",
|
|
9681
|
+
GANADA: "ganada",
|
|
9682
|
+
CHOSUNG: "chosung",
|
|
9683
|
+
DECIMAL_ENCLOSED_FULL_STOP: "decimalEnclosedFullstop",
|
|
9684
|
+
DECIMAL_ENCLOSED_PAREN: "decimalEnclosedParen",
|
|
9685
|
+
DECIMAL_ENCLOSED_CIRCLE_CHINESE: "decimalEnclosedCircleChinese",
|
|
9686
|
+
IDEOGRAPH_ENCLOSED_CIRCLE: "ideographEnclosedCircle",
|
|
9687
|
+
IDEOGRAPH_TRADITIONAL: "ideographTraditional",
|
|
9688
|
+
IDEOGRAPH_ZODIAC: "ideographZodiac",
|
|
9689
|
+
IDEOGRAPH_ZODIAC_TRADITIONAL: "ideographZodiacTraditional",
|
|
9690
|
+
TAIWANESE_COUNTING: "taiwaneseCounting",
|
|
9691
|
+
IDEOGRAPH_LEGAL_TRADITIONAL: "ideographLegalTraditional",
|
|
9692
|
+
TAIWANESE_COUNTING_THOUSAND: "taiwaneseCountingThousand",
|
|
9693
|
+
TAIWANESE_DIGITAL: "taiwaneseDigital",
|
|
9694
|
+
CHINESE_COUNTING: "chineseCounting",
|
|
9695
|
+
CHINESE_LEGAL_SIMPLIFIED: "chineseLegalSimplified",
|
|
9696
|
+
CHINESE_COUNTING_TEN_THOUSAND: "chineseCountingThousand",
|
|
9697
|
+
KOREAN_DIGITAL: "koreanDigital",
|
|
9698
|
+
KOREAN_COUNTING: "koreanCounting",
|
|
9699
|
+
KOREAN_LEGAL: "koreanLegal",
|
|
9700
|
+
KOREAN_DIGITAL_2: "koreanDigital2",
|
|
9701
|
+
VIETNAMESE_COUNTING: "vietnameseCounting",
|
|
9702
|
+
RUSSIAN_LOWER: "russianLower",
|
|
9703
|
+
RUSSIAN_UPPER: "russianUpper",
|
|
9704
|
+
NONE: "none",
|
|
9705
|
+
NUMBER_IN_DASH: "numberInDash",
|
|
9706
|
+
HEBREW_1: "hebrew1",
|
|
9707
|
+
HEBREW_2: "hebrew2",
|
|
9708
|
+
ARABIC_ALPHA: "arabicAlpha",
|
|
9709
|
+
ARABIC_ABJAD: "arabicAbjad",
|
|
9710
|
+
HINDI_VOWELS: "hindiVowels",
|
|
9711
|
+
HINDI_CONSONANTS: "hindiConsonants",
|
|
9712
|
+
HINDI_NUMBERS: "hindiNumbers",
|
|
9713
|
+
HINDI_COUNTING: "hindiCounting",
|
|
9714
|
+
THAI_LETTERS: "thaiLetters",
|
|
9715
|
+
THAI_NUMBERS: "thaiNumbers",
|
|
9716
|
+
THAI_COUNTING: "thaiCounting",
|
|
9717
|
+
BAHT_TEXT: "bahtText",
|
|
9718
|
+
DOLLAR_TEXT: "dollarText"
|
|
9719
|
+
// <xsd:enumeration value="custom"/>
|
|
9720
|
+
};
|
|
9721
|
+
const SpaceType = {
|
|
9722
|
+
DEFAULT: "default",
|
|
9723
|
+
PRESERVE: "preserve"
|
|
9724
|
+
};
|
|
9546
9725
|
class TextAttributes extends XmlAttributeComponent {
|
|
9547
9726
|
constructor() {
|
|
9548
9727
|
super(...arguments);
|
|
@@ -9592,46 +9771,45 @@ class Shading extends XmlComponent {
|
|
|
9592
9771
|
);
|
|
9593
9772
|
}
|
|
9594
9773
|
}
|
|
9595
|
-
|
|
9596
|
-
|
|
9597
|
-
|
|
9598
|
-
|
|
9599
|
-
|
|
9600
|
-
|
|
9601
|
-
|
|
9602
|
-
|
|
9603
|
-
|
|
9604
|
-
|
|
9605
|
-
|
|
9606
|
-
|
|
9607
|
-
|
|
9608
|
-
|
|
9609
|
-
|
|
9610
|
-
|
|
9611
|
-
|
|
9612
|
-
|
|
9613
|
-
|
|
9614
|
-
|
|
9615
|
-
|
|
9616
|
-
|
|
9617
|
-
|
|
9618
|
-
|
|
9619
|
-
|
|
9620
|
-
|
|
9621
|
-
|
|
9622
|
-
|
|
9623
|
-
|
|
9624
|
-
|
|
9625
|
-
|
|
9626
|
-
|
|
9627
|
-
|
|
9628
|
-
|
|
9629
|
-
|
|
9630
|
-
|
|
9631
|
-
|
|
9632
|
-
|
|
9633
|
-
|
|
9634
|
-
})(ShadingType || {});
|
|
9774
|
+
const ShadingType = {
|
|
9775
|
+
CLEAR: "clear",
|
|
9776
|
+
DIAGONAL_CROSS: "diagCross",
|
|
9777
|
+
DIAGONAL_STRIPE: "diagStripe",
|
|
9778
|
+
HORIZONTAL_CROSS: "horzCross",
|
|
9779
|
+
HORIZONTAL_STRIPE: "horzStripe",
|
|
9780
|
+
NIL: "nil",
|
|
9781
|
+
PERCENT_5: "pct5",
|
|
9782
|
+
PERCENT_10: "pct10",
|
|
9783
|
+
PERCENT_12: "pct12",
|
|
9784
|
+
PERCENT_15: "pct15",
|
|
9785
|
+
PERCENT_20: "pct20",
|
|
9786
|
+
PERCENT_25: "pct25",
|
|
9787
|
+
PERCENT_30: "pct30",
|
|
9788
|
+
PERCENT_35: "pct35",
|
|
9789
|
+
PERCENT_37: "pct37",
|
|
9790
|
+
PERCENT_40: "pct40",
|
|
9791
|
+
PERCENT_45: "pct45",
|
|
9792
|
+
PERCENT_50: "pct50",
|
|
9793
|
+
PERCENT_55: "pct55",
|
|
9794
|
+
PERCENT_60: "pct60",
|
|
9795
|
+
PERCENT_62: "pct62",
|
|
9796
|
+
PERCENT_65: "pct65",
|
|
9797
|
+
PERCENT_70: "pct70",
|
|
9798
|
+
PERCENT_75: "pct75",
|
|
9799
|
+
PERCENT_80: "pct80",
|
|
9800
|
+
PERCENT_85: "pct85",
|
|
9801
|
+
PERCENT_87: "pct87",
|
|
9802
|
+
PERCENT_90: "pct90",
|
|
9803
|
+
PERCENT_95: "pct95",
|
|
9804
|
+
REVERSE_DIAGONAL_STRIPE: "reverseDiagStripe",
|
|
9805
|
+
SOLID: "solid",
|
|
9806
|
+
THIN_DIAGONAL_CROSS: "thinDiagCross",
|
|
9807
|
+
THIN_DIAGONAL_STRIPE: "thinDiagStripe",
|
|
9808
|
+
THIN_HORIZONTAL_CROSS: "thinHorzCross",
|
|
9809
|
+
THIN_REVERSE_DIAGONAL_STRIPE: "thinReverseDiagStripe",
|
|
9810
|
+
THIN_VERTICAL_STRIPE: "thinVertStripe",
|
|
9811
|
+
VERTICAL_STRIPE: "vertStripe"
|
|
9812
|
+
};
|
|
9635
9813
|
class ChangeAttributes extends XmlAttributeComponent {
|
|
9636
9814
|
constructor() {
|
|
9637
9815
|
super(...arguments);
|
|
@@ -9642,10 +9820,9 @@ class ChangeAttributes extends XmlAttributeComponent {
|
|
|
9642
9820
|
});
|
|
9643
9821
|
}
|
|
9644
9822
|
}
|
|
9645
|
-
|
|
9646
|
-
|
|
9647
|
-
|
|
9648
|
-
})(EmphasisMarkType || {});
|
|
9823
|
+
const EmphasisMarkType = {
|
|
9824
|
+
DOT: "dot"
|
|
9825
|
+
};
|
|
9649
9826
|
class BaseEmphasisMark extends XmlComponent {
|
|
9650
9827
|
constructor(emphasisMarkType) {
|
|
9651
9828
|
super("w:em");
|
|
@@ -9657,16 +9834,13 @@ class BaseEmphasisMark extends XmlComponent {
|
|
|
9657
9834
|
}
|
|
9658
9835
|
}
|
|
9659
9836
|
class EmphasisMark extends BaseEmphasisMark {
|
|
9660
|
-
constructor(emphasisMarkType =
|
|
9837
|
+
constructor(emphasisMarkType = EmphasisMarkType.DOT) {
|
|
9661
9838
|
super(emphasisMarkType);
|
|
9662
9839
|
}
|
|
9663
9840
|
}
|
|
9664
9841
|
class DotEmphasisMark extends BaseEmphasisMark {
|
|
9665
9842
|
constructor() {
|
|
9666
|
-
super(
|
|
9667
|
-
"dot"
|
|
9668
|
-
/* DOT */
|
|
9669
|
-
);
|
|
9843
|
+
super(EmphasisMarkType.DOT);
|
|
9670
9844
|
}
|
|
9671
9845
|
}
|
|
9672
9846
|
class CharacterSpacing extends XmlComponent {
|
|
@@ -9778,29 +9952,28 @@ class SubScript extends VerticalAlign$1 {
|
|
|
9778
9952
|
super("subscript");
|
|
9779
9953
|
}
|
|
9780
9954
|
}
|
|
9781
|
-
|
|
9782
|
-
|
|
9783
|
-
|
|
9784
|
-
|
|
9785
|
-
|
|
9786
|
-
|
|
9787
|
-
|
|
9788
|
-
|
|
9789
|
-
|
|
9790
|
-
|
|
9791
|
-
|
|
9792
|
-
|
|
9793
|
-
|
|
9794
|
-
|
|
9795
|
-
|
|
9796
|
-
|
|
9797
|
-
|
|
9798
|
-
|
|
9799
|
-
|
|
9800
|
-
|
|
9801
|
-
})(UnderlineType || {});
|
|
9955
|
+
const UnderlineType = {
|
|
9956
|
+
SINGLE: "single",
|
|
9957
|
+
WORDS: "words",
|
|
9958
|
+
DOUBLE: "double",
|
|
9959
|
+
THICK: "thick",
|
|
9960
|
+
DOTTED: "dotted",
|
|
9961
|
+
DOTTEDHEAVY: "dottedHeavy",
|
|
9962
|
+
DASH: "dash",
|
|
9963
|
+
DASHEDHEAVY: "dashedHeavy",
|
|
9964
|
+
DASHLONG: "dashLong",
|
|
9965
|
+
DASHLONGHEAVY: "dashLongHeavy",
|
|
9966
|
+
DOTDASH: "dotDash",
|
|
9967
|
+
DASHDOTHEAVY: "dashDotHeavy",
|
|
9968
|
+
DOTDOTDASH: "dotDotDash",
|
|
9969
|
+
DASHDOTDOTHEAVY: "dashDotDotHeavy",
|
|
9970
|
+
WAVE: "wave",
|
|
9971
|
+
WAVYHEAVY: "wavyHeavy",
|
|
9972
|
+
WAVYDOUBLE: "wavyDouble",
|
|
9973
|
+
NONE: "none"
|
|
9974
|
+
};
|
|
9802
9975
|
class Underline extends XmlComponent {
|
|
9803
|
-
constructor(underlineType =
|
|
9976
|
+
constructor(underlineType = UnderlineType.SINGLE, color) {
|
|
9804
9977
|
super("w:u");
|
|
9805
9978
|
this.root.push(
|
|
9806
9979
|
new Attributes({
|
|
@@ -9810,16 +9983,15 @@ class Underline extends XmlComponent {
|
|
|
9810
9983
|
);
|
|
9811
9984
|
}
|
|
9812
9985
|
}
|
|
9813
|
-
|
|
9814
|
-
|
|
9815
|
-
|
|
9816
|
-
|
|
9817
|
-
|
|
9818
|
-
|
|
9819
|
-
|
|
9820
|
-
|
|
9821
|
-
|
|
9822
|
-
})(TextEffect || {});
|
|
9986
|
+
const TextEffect = {
|
|
9987
|
+
BLINK_BACKGROUND: "blinkBackground",
|
|
9988
|
+
LIGHTS: "lights",
|
|
9989
|
+
ANTS_BLACK: "antsBlack",
|
|
9990
|
+
ANTS_RED: "antsRed",
|
|
9991
|
+
SHIMMER: "shimmer",
|
|
9992
|
+
SPARKLE: "sparkle",
|
|
9993
|
+
NONE: "none"
|
|
9994
|
+
};
|
|
9823
9995
|
class RunProperties extends IgnoreIfEmptyXmlComponent {
|
|
9824
9996
|
constructor(options2) {
|
|
9825
9997
|
super("w:rPr");
|
|
@@ -9923,7 +10095,7 @@ class RunProperties extends IgnoreIfEmptyXmlComponent {
|
|
|
9923
10095
|
if (options2.border) {
|
|
9924
10096
|
this.push(new BorderElement("w:bdr", options2.border));
|
|
9925
10097
|
}
|
|
9926
|
-
if (options2.snapToGrid) {
|
|
10098
|
+
if (options2.snapToGrid !== void 0) {
|
|
9927
10099
|
this.push(new OnOffElement("w:snapToGrid", options2.snapToGrid));
|
|
9928
10100
|
}
|
|
9929
10101
|
if (options2.vanish) {
|
|
@@ -9973,12 +10145,11 @@ class Text extends XmlComponent {
|
|
|
9973
10145
|
}
|
|
9974
10146
|
}
|
|
9975
10147
|
}
|
|
9976
|
-
|
|
9977
|
-
|
|
9978
|
-
|
|
9979
|
-
|
|
9980
|
-
|
|
9981
|
-
})(PageNumber || {});
|
|
10148
|
+
const PageNumber = {
|
|
10149
|
+
CURRENT: "CURRENT",
|
|
10150
|
+
TOTAL_PAGES: "TOTAL_PAGES",
|
|
10151
|
+
TOTAL_PAGES_IN_SECTION: "TOTAL_PAGES_IN_SECTION"
|
|
10152
|
+
};
|
|
9982
10153
|
class Run extends XmlComponent {
|
|
9983
10154
|
constructor(options2) {
|
|
9984
10155
|
super("w:r");
|
|
@@ -9994,19 +10165,19 @@ class Run extends XmlComponent {
|
|
|
9994
10165
|
for (const child of options2.children) {
|
|
9995
10166
|
if (typeof child === "string") {
|
|
9996
10167
|
switch (child) {
|
|
9997
|
-
case
|
|
10168
|
+
case PageNumber.CURRENT:
|
|
9998
10169
|
this.root.push(new Begin());
|
|
9999
10170
|
this.root.push(new Page());
|
|
10000
10171
|
this.root.push(new Separate());
|
|
10001
10172
|
this.root.push(new End());
|
|
10002
10173
|
break;
|
|
10003
|
-
case
|
|
10174
|
+
case PageNumber.TOTAL_PAGES:
|
|
10004
10175
|
this.root.push(new Begin());
|
|
10005
10176
|
this.root.push(new NumberOfPages());
|
|
10006
10177
|
this.root.push(new Separate());
|
|
10007
10178
|
this.root.push(new End());
|
|
10008
10179
|
break;
|
|
10009
|
-
case
|
|
10180
|
+
case PageNumber.TOTAL_PAGES_IN_SECTION:
|
|
10010
10181
|
this.root.push(new Begin());
|
|
10011
10182
|
this.root.push(new NumberOfPagesSection());
|
|
10012
10183
|
this.root.push(new Separate());
|
|
@@ -10081,28 +10252,26 @@ const concreteNumUniqueNumericIdGen = () => uniqueNumericIdCreator(1);
|
|
|
10081
10252
|
const docPropertiesUniqueNumericIdGen = () => uniqueNumericIdCreator();
|
|
10082
10253
|
const bookmarkUniqueNumericIdGen = () => uniqueNumericIdCreator();
|
|
10083
10254
|
const uniqueId = () => nanoid().toLowerCase();
|
|
10084
|
-
|
|
10085
|
-
|
|
10086
|
-
|
|
10087
|
-
|
|
10088
|
-
|
|
10089
|
-
|
|
10090
|
-
|
|
10091
|
-
|
|
10092
|
-
|
|
10093
|
-
|
|
10094
|
-
|
|
10095
|
-
|
|
10096
|
-
|
|
10097
|
-
|
|
10098
|
-
|
|
10099
|
-
|
|
10100
|
-
|
|
10101
|
-
|
|
10102
|
-
|
|
10103
|
-
|
|
10104
|
-
return VerticalPositionRelativeFrom2;
|
|
10105
|
-
})(VerticalPositionRelativeFrom || {});
|
|
10255
|
+
const HorizontalPositionRelativeFrom = {
|
|
10256
|
+
CHARACTER: "character",
|
|
10257
|
+
COLUMN: "column",
|
|
10258
|
+
INSIDE_MARGIN: "insideMargin",
|
|
10259
|
+
LEFT_MARGIN: "leftMargin",
|
|
10260
|
+
MARGIN: "margin",
|
|
10261
|
+
OUTSIDE_MARGIN: "outsideMargin",
|
|
10262
|
+
PAGE: "page",
|
|
10263
|
+
RIGHT_MARGIN: "rightMargin"
|
|
10264
|
+
};
|
|
10265
|
+
const VerticalPositionRelativeFrom = {
|
|
10266
|
+
BOTTOM_MARGIN: "bottomMargin",
|
|
10267
|
+
INSIDE_MARGIN: "insideMargin",
|
|
10268
|
+
LINE: "line",
|
|
10269
|
+
MARGIN: "margin",
|
|
10270
|
+
OUTSIDE_MARGIN: "outsideMargin",
|
|
10271
|
+
PAGE: "page",
|
|
10272
|
+
PARAGRAPH: "paragraph",
|
|
10273
|
+
TOP_MARGIN: "topMargin"
|
|
10274
|
+
};
|
|
10106
10275
|
class SimplePosAttributes extends XmlAttributeComponent {
|
|
10107
10276
|
constructor() {
|
|
10108
10277
|
super(...arguments);
|
|
@@ -10486,20 +10655,18 @@ class Graphic extends XmlComponent {
|
|
|
10486
10655
|
this.root.push(this.data);
|
|
10487
10656
|
}
|
|
10488
10657
|
}
|
|
10489
|
-
|
|
10490
|
-
|
|
10491
|
-
|
|
10492
|
-
|
|
10493
|
-
|
|
10494
|
-
|
|
10495
|
-
|
|
10496
|
-
|
|
10497
|
-
|
|
10498
|
-
|
|
10499
|
-
|
|
10500
|
-
|
|
10501
|
-
return TextWrappingSide2;
|
|
10502
|
-
})(TextWrappingSide || {});
|
|
10658
|
+
const TextWrappingType = {
|
|
10659
|
+
NONE: 0,
|
|
10660
|
+
SQUARE: 1,
|
|
10661
|
+
TIGHT: 2,
|
|
10662
|
+
TOP_AND_BOTTOM: 3
|
|
10663
|
+
};
|
|
10664
|
+
const TextWrappingSide = {
|
|
10665
|
+
BOTH_SIDES: "bothSides",
|
|
10666
|
+
LEFT: "left",
|
|
10667
|
+
RIGHT: "right",
|
|
10668
|
+
LARGEST: "largest"
|
|
10669
|
+
};
|
|
10503
10670
|
class WrapNone extends XmlComponent {
|
|
10504
10671
|
constructor() {
|
|
10505
10672
|
super("wp:wrapNone");
|
|
@@ -11100,25 +11267,23 @@ class LastRenderedPageBreak extends EmptyElement {
|
|
|
11100
11267
|
super("w:lastRenderedPageBreak");
|
|
11101
11268
|
}
|
|
11102
11269
|
}
|
|
11103
|
-
|
|
11104
|
-
|
|
11105
|
-
|
|
11106
|
-
|
|
11107
|
-
|
|
11108
|
-
|
|
11109
|
-
|
|
11110
|
-
|
|
11111
|
-
|
|
11112
|
-
|
|
11113
|
-
|
|
11114
|
-
|
|
11115
|
-
|
|
11116
|
-
|
|
11117
|
-
|
|
11118
|
-
|
|
11119
|
-
|
|
11120
|
-
return PositionalTabLeader2;
|
|
11121
|
-
})(PositionalTabLeader || {});
|
|
11270
|
+
const PositionalTabAlignment = {
|
|
11271
|
+
LEFT: "left",
|
|
11272
|
+
CENTER: "center",
|
|
11273
|
+
RIGHT: "right"
|
|
11274
|
+
};
|
|
11275
|
+
const PositionalTabRelativeTo = {
|
|
11276
|
+
MARGIN: "margin",
|
|
11277
|
+
INDENT: "indent"
|
|
11278
|
+
};
|
|
11279
|
+
const PositionalTabLeader = {
|
|
11280
|
+
NONE: "none",
|
|
11281
|
+
DOT: "dot",
|
|
11282
|
+
HYPHEN: "hyphen",
|
|
11283
|
+
UNDERSCORE: "underscore",
|
|
11284
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
11285
|
+
MIDDLE_DOT: "middleDot"
|
|
11286
|
+
};
|
|
11122
11287
|
class PositionalTab extends XmlComponent {
|
|
11123
11288
|
constructor(options2) {
|
|
11124
11289
|
super("w:ptab");
|
|
@@ -11140,6 +11305,11 @@ class PositionalTab extends XmlComponent {
|
|
|
11140
11305
|
);
|
|
11141
11306
|
}
|
|
11142
11307
|
}
|
|
11308
|
+
const BreakType = {
|
|
11309
|
+
COLUMN: "column",
|
|
11310
|
+
PAGE: "page"
|
|
11311
|
+
// textWrapping breaks are the default and already exposed via the "Run" class
|
|
11312
|
+
};
|
|
11143
11313
|
class Break2 extends XmlComponent {
|
|
11144
11314
|
constructor(type) {
|
|
11145
11315
|
super("w:br");
|
|
@@ -11153,19 +11323,13 @@ class Break2 extends XmlComponent {
|
|
|
11153
11323
|
class PageBreak extends Run {
|
|
11154
11324
|
constructor() {
|
|
11155
11325
|
super({});
|
|
11156
|
-
this.root.push(new Break2(
|
|
11157
|
-
"page"
|
|
11158
|
-
/* PAGE */
|
|
11159
|
-
));
|
|
11326
|
+
this.root.push(new Break2(BreakType.PAGE));
|
|
11160
11327
|
}
|
|
11161
11328
|
}
|
|
11162
11329
|
class ColumnBreak extends Run {
|
|
11163
11330
|
constructor() {
|
|
11164
11331
|
super({});
|
|
11165
|
-
this.root.push(new Break2(
|
|
11166
|
-
"column"
|
|
11167
|
-
/* COLUMN */
|
|
11168
|
-
));
|
|
11332
|
+
this.root.push(new Break2(BreakType.COLUMN));
|
|
11169
11333
|
}
|
|
11170
11334
|
}
|
|
11171
11335
|
class PageBreakBefore extends XmlComponent {
|
|
@@ -11173,13 +11337,13 @@ class PageBreakBefore extends XmlComponent {
|
|
|
11173
11337
|
super("w:pageBreakBefore");
|
|
11174
11338
|
}
|
|
11175
11339
|
}
|
|
11176
|
-
|
|
11177
|
-
|
|
11178
|
-
|
|
11179
|
-
|
|
11180
|
-
|
|
11181
|
-
|
|
11182
|
-
}
|
|
11340
|
+
const LineRuleType = {
|
|
11341
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
11342
|
+
AT_LEAST: "atLeast",
|
|
11343
|
+
EXACTLY: "exactly",
|
|
11344
|
+
EXACT: "exact",
|
|
11345
|
+
AUTO: "auto"
|
|
11346
|
+
};
|
|
11183
11347
|
class SpacingAttributes extends XmlAttributeComponent {
|
|
11184
11348
|
constructor() {
|
|
11185
11349
|
super(...arguments);
|
|
@@ -11197,16 +11361,15 @@ class Spacing extends XmlComponent {
|
|
|
11197
11361
|
this.root.push(new SpacingAttributes(options2));
|
|
11198
11362
|
}
|
|
11199
11363
|
}
|
|
11200
|
-
|
|
11201
|
-
|
|
11202
|
-
|
|
11203
|
-
|
|
11204
|
-
|
|
11205
|
-
|
|
11206
|
-
|
|
11207
|
-
|
|
11208
|
-
|
|
11209
|
-
})(HeadingLevel || {});
|
|
11364
|
+
const HeadingLevel = {
|
|
11365
|
+
HEADING_1: "Heading1",
|
|
11366
|
+
HEADING_2: "Heading2",
|
|
11367
|
+
HEADING_3: "Heading3",
|
|
11368
|
+
HEADING_4: "Heading4",
|
|
11369
|
+
HEADING_5: "Heading5",
|
|
11370
|
+
HEADING_6: "Heading6",
|
|
11371
|
+
TITLE: "Title"
|
|
11372
|
+
};
|
|
11210
11373
|
let Style$1 = class Style extends XmlComponent {
|
|
11211
11374
|
constructor(styleId) {
|
|
11212
11375
|
super("w:pStyle");
|
|
@@ -11225,30 +11388,28 @@ class TabStop extends XmlComponent {
|
|
|
11225
11388
|
}
|
|
11226
11389
|
}
|
|
11227
11390
|
}
|
|
11228
|
-
|
|
11229
|
-
|
|
11230
|
-
|
|
11231
|
-
|
|
11232
|
-
|
|
11233
|
-
|
|
11234
|
-
|
|
11235
|
-
|
|
11236
|
-
|
|
11237
|
-
|
|
11238
|
-
|
|
11239
|
-
|
|
11240
|
-
|
|
11241
|
-
|
|
11242
|
-
|
|
11243
|
-
|
|
11244
|
-
|
|
11245
|
-
|
|
11246
|
-
|
|
11247
|
-
|
|
11248
|
-
|
|
11249
|
-
|
|
11250
|
-
return TabStopPosition2;
|
|
11251
|
-
})(TabStopPosition || {});
|
|
11391
|
+
const TabStopType = {
|
|
11392
|
+
LEFT: "left",
|
|
11393
|
+
RIGHT: "right",
|
|
11394
|
+
CENTER: "center",
|
|
11395
|
+
BAR: "bar",
|
|
11396
|
+
CLEAR: "clear",
|
|
11397
|
+
DECIMAL: "decimal",
|
|
11398
|
+
END: "end",
|
|
11399
|
+
NUM: "num",
|
|
11400
|
+
START: "start"
|
|
11401
|
+
};
|
|
11402
|
+
const LeaderType = {
|
|
11403
|
+
DOT: "dot",
|
|
11404
|
+
HYPHEN: "hyphen",
|
|
11405
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
11406
|
+
MIDDLE_DOT: "middleDot",
|
|
11407
|
+
NONE: "none",
|
|
11408
|
+
UNDERSCORE: "underscore"
|
|
11409
|
+
};
|
|
11410
|
+
const TabStopPosition = {
|
|
11411
|
+
MAX: 9026
|
|
11412
|
+
};
|
|
11252
11413
|
class TabAttributes extends XmlAttributeComponent {
|
|
11253
11414
|
constructor() {
|
|
11254
11415
|
super(...arguments);
|
|
@@ -11316,10 +11477,9 @@ class RelationshipAttributes extends XmlAttributeComponent {
|
|
|
11316
11477
|
});
|
|
11317
11478
|
}
|
|
11318
11479
|
}
|
|
11319
|
-
|
|
11320
|
-
|
|
11321
|
-
|
|
11322
|
-
})(TargetModeType || {});
|
|
11480
|
+
const TargetModeType = {
|
|
11481
|
+
EXTERNAL: "External"
|
|
11482
|
+
};
|
|
11323
11483
|
class Relationship extends XmlComponent {
|
|
11324
11484
|
constructor(id, type, target, targetMode) {
|
|
11325
11485
|
super("Relationship");
|
|
@@ -11343,11 +11503,10 @@ class HyperlinkAttributes extends XmlAttributeComponent {
|
|
|
11343
11503
|
});
|
|
11344
11504
|
}
|
|
11345
11505
|
}
|
|
11346
|
-
|
|
11347
|
-
|
|
11348
|
-
|
|
11349
|
-
|
|
11350
|
-
})(HyperlinkType || {});
|
|
11506
|
+
const HyperlinkType = {
|
|
11507
|
+
INTERNAL: "INTERNAL",
|
|
11508
|
+
EXTERNAL: "EXTERNAL"
|
|
11509
|
+
};
|
|
11351
11510
|
class ConcreteHyperlink extends XmlComponent {
|
|
11352
11511
|
constructor(children, relationshipId, anchor) {
|
|
11353
11512
|
super("w:hyperlink");
|
|
@@ -11456,12 +11615,11 @@ class PageReference extends Run {
|
|
|
11456
11615
|
});
|
|
11457
11616
|
}
|
|
11458
11617
|
}
|
|
11459
|
-
|
|
11460
|
-
|
|
11461
|
-
|
|
11462
|
-
|
|
11463
|
-
|
|
11464
|
-
})(VerticalAlign2 || {});
|
|
11618
|
+
const VerticalAlign2 = {
|
|
11619
|
+
BOTTOM: "bottom",
|
|
11620
|
+
CENTER: "center",
|
|
11621
|
+
TOP: "top"
|
|
11622
|
+
};
|
|
11465
11623
|
class VerticalAlignAttributes extends XmlAttributeComponent {
|
|
11466
11624
|
constructor() {
|
|
11467
11625
|
super(...arguments);
|
|
@@ -11476,12 +11634,11 @@ class VerticalAlignElement extends XmlComponent {
|
|
|
11476
11634
|
this.root.push(new VerticalAlignAttributes({ verticalAlign: value }));
|
|
11477
11635
|
}
|
|
11478
11636
|
}
|
|
11479
|
-
|
|
11480
|
-
|
|
11481
|
-
|
|
11482
|
-
|
|
11483
|
-
|
|
11484
|
-
})(HeaderFooterReferenceType || {});
|
|
11637
|
+
const HeaderFooterReferenceType = {
|
|
11638
|
+
DEFAULT: "default",
|
|
11639
|
+
FIRST: "first",
|
|
11640
|
+
EVEN: "even"
|
|
11641
|
+
};
|
|
11485
11642
|
class FooterReferenceAttributes extends XmlAttributeComponent {
|
|
11486
11643
|
constructor() {
|
|
11487
11644
|
super(...arguments);
|
|
@@ -11491,17 +11648,16 @@ class FooterReferenceAttributes extends XmlAttributeComponent {
|
|
|
11491
11648
|
});
|
|
11492
11649
|
}
|
|
11493
11650
|
}
|
|
11494
|
-
|
|
11495
|
-
|
|
11496
|
-
|
|
11497
|
-
|
|
11498
|
-
})(HeaderFooterType || {});
|
|
11651
|
+
const HeaderFooterType = {
|
|
11652
|
+
HEADER: "w:headerReference",
|
|
11653
|
+
FOOTER: "w:footerReference"
|
|
11654
|
+
};
|
|
11499
11655
|
class HeaderFooterReference extends XmlComponent {
|
|
11500
11656
|
constructor(type, options2) {
|
|
11501
11657
|
super(type);
|
|
11502
11658
|
this.root.push(
|
|
11503
11659
|
new FooterReferenceAttributes({
|
|
11504
|
-
type: options2.type ||
|
|
11660
|
+
type: options2.type || HeaderFooterReferenceType.DEFAULT,
|
|
11505
11661
|
id: `rId${options2.id}`
|
|
11506
11662
|
})
|
|
11507
11663
|
);
|
|
@@ -11523,13 +11679,12 @@ class Columns extends XmlComponent {
|
|
|
11523
11679
|
}
|
|
11524
11680
|
}
|
|
11525
11681
|
}
|
|
11526
|
-
|
|
11527
|
-
|
|
11528
|
-
|
|
11529
|
-
|
|
11530
|
-
|
|
11531
|
-
|
|
11532
|
-
})(DocumentGridType || {});
|
|
11682
|
+
const DocumentGridType = {
|
|
11683
|
+
DEFAULT: "default",
|
|
11684
|
+
LINES: "lines",
|
|
11685
|
+
LINES_AND_CHARS: "linesAndChars",
|
|
11686
|
+
SNAP_TO_CHARS: "snapToChars"
|
|
11687
|
+
};
|
|
11533
11688
|
class DocGridAttributes extends XmlAttributeComponent {
|
|
11534
11689
|
constructor() {
|
|
11535
11690
|
super(...arguments);
|
|
@@ -11552,12 +11707,11 @@ class DocumentGrid extends XmlComponent {
|
|
|
11552
11707
|
);
|
|
11553
11708
|
}
|
|
11554
11709
|
}
|
|
11555
|
-
|
|
11556
|
-
|
|
11557
|
-
|
|
11558
|
-
|
|
11559
|
-
|
|
11560
|
-
})(LineNumberRestartFormat || {});
|
|
11710
|
+
const LineNumberRestartFormat = {
|
|
11711
|
+
NEW_PAGE: "newPage",
|
|
11712
|
+
NEW_SECTION: "newSection",
|
|
11713
|
+
CONTINUOUS: "continuous"
|
|
11714
|
+
};
|
|
11561
11715
|
class LineNumberType extends XmlComponent {
|
|
11562
11716
|
constructor({ countBy, start, restart, distance }) {
|
|
11563
11717
|
super("w:lnNumType");
|
|
@@ -11566,27 +11720,27 @@ class LineNumberType extends XmlComponent {
|
|
|
11566
11720
|
countBy: { key: "w:countBy", value: countBy === void 0 ? void 0 : decimalNumber(countBy) },
|
|
11567
11721
|
start: { key: "w:start", value: start === void 0 ? void 0 : decimalNumber(start) },
|
|
11568
11722
|
restart: { key: "w:restart", value: restart },
|
|
11569
|
-
distance: {
|
|
11723
|
+
distance: {
|
|
11724
|
+
key: "w:distance",
|
|
11725
|
+
value: distance === void 0 ? void 0 : twipsMeasureValue(distance)
|
|
11726
|
+
}
|
|
11570
11727
|
})
|
|
11571
11728
|
);
|
|
11572
11729
|
}
|
|
11573
11730
|
}
|
|
11574
|
-
|
|
11575
|
-
|
|
11576
|
-
|
|
11577
|
-
|
|
11578
|
-
|
|
11579
|
-
|
|
11580
|
-
|
|
11581
|
-
|
|
11582
|
-
|
|
11583
|
-
|
|
11584
|
-
|
|
11585
|
-
|
|
11586
|
-
|
|
11587
|
-
PageBorderZOrder2["FRONT"] = "front";
|
|
11588
|
-
return PageBorderZOrder2;
|
|
11589
|
-
})(PageBorderZOrder || {});
|
|
11731
|
+
const PageBorderDisplay = {
|
|
11732
|
+
ALL_PAGES: "allPages",
|
|
11733
|
+
FIRST_PAGE: "firstPage",
|
|
11734
|
+
NOT_FIRST_PAGE: "notFirstPage"
|
|
11735
|
+
};
|
|
11736
|
+
const PageBorderOffsetFrom = {
|
|
11737
|
+
PAGE: "page",
|
|
11738
|
+
TEXT: "text"
|
|
11739
|
+
};
|
|
11740
|
+
const PageBorderZOrder = {
|
|
11741
|
+
BACK: "back",
|
|
11742
|
+
FRONT: "front"
|
|
11743
|
+
};
|
|
11590
11744
|
class PageBordersAttributes extends XmlAttributeComponent {
|
|
11591
11745
|
constructor() {
|
|
11592
11746
|
super(...arguments);
|
|
@@ -11644,14 +11798,13 @@ class PageMargin extends XmlComponent {
|
|
|
11644
11798
|
);
|
|
11645
11799
|
}
|
|
11646
11800
|
}
|
|
11647
|
-
|
|
11648
|
-
|
|
11649
|
-
|
|
11650
|
-
|
|
11651
|
-
|
|
11652
|
-
|
|
11653
|
-
|
|
11654
|
-
})(PageNumberSeparator || {});
|
|
11801
|
+
const PageNumberSeparator = {
|
|
11802
|
+
HYPHEN: "hyphen",
|
|
11803
|
+
PERIOD: "period",
|
|
11804
|
+
COLON: "colon",
|
|
11805
|
+
EM_DASH: "emDash",
|
|
11806
|
+
EN_DASH: "endash"
|
|
11807
|
+
};
|
|
11655
11808
|
class PageNumberTypeAttributes extends XmlAttributeComponent {
|
|
11656
11809
|
constructor() {
|
|
11657
11810
|
super(...arguments);
|
|
@@ -11674,15 +11827,14 @@ class PageNumberType extends XmlComponent {
|
|
|
11674
11827
|
);
|
|
11675
11828
|
}
|
|
11676
11829
|
}
|
|
11677
|
-
|
|
11678
|
-
|
|
11679
|
-
|
|
11680
|
-
|
|
11681
|
-
})(PageOrientation || {});
|
|
11830
|
+
const PageOrientation = {
|
|
11831
|
+
PORTRAIT: "portrait",
|
|
11832
|
+
LANDSCAPE: "landscape"
|
|
11833
|
+
};
|
|
11682
11834
|
class PageSize extends XmlComponent {
|
|
11683
11835
|
constructor(width, height, orientation) {
|
|
11684
11836
|
super("w:pgSz");
|
|
11685
|
-
const flip = orientation ===
|
|
11837
|
+
const flip = orientation === PageOrientation.LANDSCAPE;
|
|
11686
11838
|
const widthTwips = twipsMeasureValue(width);
|
|
11687
11839
|
const heightTwips = twipsMeasureValue(height);
|
|
11688
11840
|
this.root.push(
|
|
@@ -11694,11 +11846,10 @@ class PageSize extends XmlComponent {
|
|
|
11694
11846
|
);
|
|
11695
11847
|
}
|
|
11696
11848
|
}
|
|
11697
|
-
|
|
11698
|
-
|
|
11699
|
-
|
|
11700
|
-
|
|
11701
|
-
})(PageTextDirectionType || {});
|
|
11849
|
+
const PageTextDirectionType = {
|
|
11850
|
+
LEFT_TO_RIGHT_TOP_TO_BOTTOM: "lrTb",
|
|
11851
|
+
TOP_TO_BOTTOM_RIGHT_TO_LEFT: "tbRl"
|
|
11852
|
+
};
|
|
11702
11853
|
class PageTextDirectionAttributes extends XmlAttributeComponent {
|
|
11703
11854
|
constructor() {
|
|
11704
11855
|
super(...arguments);
|
|
@@ -11715,14 +11866,13 @@ class PageTextDirection extends XmlComponent {
|
|
|
11715
11866
|
);
|
|
11716
11867
|
}
|
|
11717
11868
|
}
|
|
11718
|
-
|
|
11719
|
-
|
|
11720
|
-
|
|
11721
|
-
|
|
11722
|
-
|
|
11723
|
-
|
|
11724
|
-
|
|
11725
|
-
})(SectionType || {});
|
|
11869
|
+
const SectionType = {
|
|
11870
|
+
NEXT_PAGE: "nextPage",
|
|
11871
|
+
NEXT_COLUMN: "nextColumn",
|
|
11872
|
+
CONTINUOUS: "continuous",
|
|
11873
|
+
EVEN_PAGE: "evenPage",
|
|
11874
|
+
ODD_PAGE: "oddPage"
|
|
11875
|
+
};
|
|
11726
11876
|
class SectionTypeAttributes extends XmlAttributeComponent {
|
|
11727
11877
|
constructor() {
|
|
11728
11878
|
super(...arguments);
|
|
@@ -12063,27 +12213,25 @@ class WordWrap extends XmlComponent {
|
|
|
12063
12213
|
this.root.push(new WordWrapAttributes({ val: 0 }));
|
|
12064
12214
|
}
|
|
12065
12215
|
}
|
|
12066
|
-
|
|
12067
|
-
|
|
12068
|
-
|
|
12069
|
-
|
|
12070
|
-
|
|
12071
|
-
|
|
12072
|
-
|
|
12073
|
-
|
|
12074
|
-
|
|
12075
|
-
|
|
12076
|
-
|
|
12077
|
-
|
|
12078
|
-
|
|
12079
|
-
|
|
12080
|
-
|
|
12081
|
-
|
|
12082
|
-
|
|
12083
|
-
|
|
12084
|
-
|
|
12085
|
-
return FrameWrap2;
|
|
12086
|
-
})(FrameWrap || {});
|
|
12216
|
+
const DropCapType = {
|
|
12217
|
+
NONE: "none",
|
|
12218
|
+
DROP: "drop",
|
|
12219
|
+
MARGIN: "margin"
|
|
12220
|
+
};
|
|
12221
|
+
const FrameAnchorType = {
|
|
12222
|
+
MARGIN: "margin",
|
|
12223
|
+
PAGE: "page",
|
|
12224
|
+
TEXT: "text"
|
|
12225
|
+
};
|
|
12226
|
+
const FrameWrap = {
|
|
12227
|
+
AROUND: "around",
|
|
12228
|
+
AUTO: "auto",
|
|
12229
|
+
NONE: "none",
|
|
12230
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
12231
|
+
NOT_BESIDE: "notBeside",
|
|
12232
|
+
THROUGH: "through",
|
|
12233
|
+
TIGHT: "tight"
|
|
12234
|
+
};
|
|
12087
12235
|
class FramePropertiesAttributes extends XmlAttributeComponent {
|
|
12088
12236
|
constructor() {
|
|
12089
12237
|
super(...arguments);
|
|
@@ -12224,6 +12372,9 @@ class ParagraphProperties extends IgnoreIfEmptyXmlComponent {
|
|
|
12224
12372
|
if (options2.autoSpaceEastAsianText !== void 0) {
|
|
12225
12373
|
this.push(new OnOffElement("w:autoSpaceDN", options2.autoSpaceEastAsianText));
|
|
12226
12374
|
}
|
|
12375
|
+
if (options2.run) {
|
|
12376
|
+
this.push(new RunProperties(options2.run));
|
|
12377
|
+
}
|
|
12227
12378
|
}
|
|
12228
12379
|
push(item) {
|
|
12229
12380
|
this.root.push(item);
|
|
@@ -12653,33 +12804,11 @@ class GridCol extends XmlComponent {
|
|
|
12653
12804
|
}
|
|
12654
12805
|
}
|
|
12655
12806
|
}
|
|
12656
|
-
|
|
12657
|
-
|
|
12658
|
-
|
|
12659
|
-
|
|
12660
|
-
|
|
12661
|
-
return WidthType2;
|
|
12662
|
-
})(WidthType || {});
|
|
12663
|
-
class TableWidthElement extends XmlComponent {
|
|
12664
|
-
constructor(name, { type = "auto", size }) {
|
|
12665
|
-
super(name);
|
|
12666
|
-
let tableWidthValue = size;
|
|
12667
|
-
if (type === "pct" && typeof size === "number") {
|
|
12668
|
-
tableWidthValue = `${size}%`;
|
|
12669
|
-
}
|
|
12670
|
-
this.root.push(
|
|
12671
|
-
new NextAttributeComponent({
|
|
12672
|
-
type: { key: "w:type", value: type },
|
|
12673
|
-
size: { key: "w:w", value: measurementOrPercentValue(tableWidthValue) }
|
|
12674
|
-
})
|
|
12675
|
-
);
|
|
12676
|
-
}
|
|
12677
|
-
}
|
|
12678
|
-
var TableCellMarginElementType = /* @__PURE__ */ ((TableCellMarginElementType2) => {
|
|
12679
|
-
TableCellMarginElementType2["TABLE"] = "w:tblCellMar";
|
|
12680
|
-
TableCellMarginElementType2["TABLE_CELL"] = "w:tcMar";
|
|
12681
|
-
return TableCellMarginElementType2;
|
|
12682
|
-
})(TableCellMarginElementType || {});
|
|
12807
|
+
const TableCellMarginElementType = {
|
|
12808
|
+
TABLE: "w:tblCellMar",
|
|
12809
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
12810
|
+
TABLE_CELL: "w:tcMar"
|
|
12811
|
+
};
|
|
12683
12812
|
class TableCellMargin extends IgnoreIfEmptyXmlComponent {
|
|
12684
12813
|
constructor(type, { marginUnitType = WidthType.DXA, top, left, bottom, right }) {
|
|
12685
12814
|
super(type);
|
|
@@ -12697,6 +12826,31 @@ class TableCellMargin extends IgnoreIfEmptyXmlComponent {
|
|
|
12697
12826
|
}
|
|
12698
12827
|
}
|
|
12699
12828
|
}
|
|
12829
|
+
const WidthType = {
|
|
12830
|
+
/** Auto. */
|
|
12831
|
+
AUTO: "auto",
|
|
12832
|
+
/** Value is in twentieths of a point */
|
|
12833
|
+
DXA: "dxa",
|
|
12834
|
+
/** No (empty) value. */
|
|
12835
|
+
NIL: "nil",
|
|
12836
|
+
/** Value is in percentage. */
|
|
12837
|
+
PERCENTAGE: "pct"
|
|
12838
|
+
};
|
|
12839
|
+
class TableWidthElement extends XmlComponent {
|
|
12840
|
+
constructor(name, { type = WidthType.AUTO, size }) {
|
|
12841
|
+
super(name);
|
|
12842
|
+
let tableWidthValue = size;
|
|
12843
|
+
if (type === WidthType.PERCENTAGE && typeof size === "number") {
|
|
12844
|
+
tableWidthValue = `${size}%`;
|
|
12845
|
+
}
|
|
12846
|
+
this.root.push(
|
|
12847
|
+
new NextAttributeComponent({
|
|
12848
|
+
type: { key: "w:type", value: type },
|
|
12849
|
+
size: { key: "w:w", value: measurementOrPercentValue(tableWidthValue) }
|
|
12850
|
+
})
|
|
12851
|
+
);
|
|
12852
|
+
}
|
|
12853
|
+
}
|
|
12700
12854
|
class TableCellBorders extends IgnoreIfEmptyXmlComponent {
|
|
12701
12855
|
constructor(options2) {
|
|
12702
12856
|
super("w:tcBorders");
|
|
@@ -12736,11 +12890,16 @@ class GridSpan extends XmlComponent {
|
|
|
12736
12890
|
);
|
|
12737
12891
|
}
|
|
12738
12892
|
}
|
|
12739
|
-
|
|
12740
|
-
|
|
12741
|
-
|
|
12742
|
-
|
|
12743
|
-
|
|
12893
|
+
const VerticalMergeType = {
|
|
12894
|
+
/**
|
|
12895
|
+
* Cell that is merged with upper one.
|
|
12896
|
+
*/
|
|
12897
|
+
CONTINUE: "continue",
|
|
12898
|
+
/**
|
|
12899
|
+
* Cell that is starting the vertical merge.
|
|
12900
|
+
*/
|
|
12901
|
+
RESTART: "restart"
|
|
12902
|
+
};
|
|
12744
12903
|
class VerticalMergeAttributes extends XmlAttributeComponent {
|
|
12745
12904
|
constructor() {
|
|
12746
12905
|
super(...arguments);
|
|
@@ -12757,12 +12916,14 @@ class VerticalMerge extends XmlComponent {
|
|
|
12757
12916
|
);
|
|
12758
12917
|
}
|
|
12759
12918
|
}
|
|
12760
|
-
|
|
12761
|
-
|
|
12762
|
-
|
|
12763
|
-
|
|
12764
|
-
|
|
12765
|
-
|
|
12919
|
+
const TextDirection = {
|
|
12920
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
12921
|
+
BOTTOM_TO_TOP_LEFT_TO_RIGHT: "btLr",
|
|
12922
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
12923
|
+
LEFT_TO_RIGHT_TOP_TO_BOTTOM: "lrTb",
|
|
12924
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
12925
|
+
TOP_TO_BOTTOM_RIGHT_TO_LEFT: "tbRl"
|
|
12926
|
+
};
|
|
12766
12927
|
class TDirectionAttributes extends XmlAttributeComponent {
|
|
12767
12928
|
constructor() {
|
|
12768
12929
|
super(...arguments);
|
|
@@ -12879,34 +13040,30 @@ __publicField(TableBorders, "NONE", {
|
|
|
12879
13040
|
insideHorizontal: NONE_BORDER,
|
|
12880
13041
|
insideVertical: NONE_BORDER
|
|
12881
13042
|
});
|
|
12882
|
-
|
|
12883
|
-
|
|
12884
|
-
|
|
12885
|
-
|
|
12886
|
-
|
|
12887
|
-
|
|
12888
|
-
|
|
12889
|
-
|
|
12890
|
-
|
|
12891
|
-
|
|
12892
|
-
|
|
12893
|
-
|
|
12894
|
-
|
|
12895
|
-
|
|
12896
|
-
|
|
12897
|
-
|
|
12898
|
-
|
|
12899
|
-
|
|
12900
|
-
|
|
12901
|
-
|
|
12902
|
-
|
|
12903
|
-
|
|
12904
|
-
|
|
12905
|
-
|
|
12906
|
-
OverlapType2["NEVER"] = "never";
|
|
12907
|
-
OverlapType2["OVERLAP"] = "overlap";
|
|
12908
|
-
return OverlapType2;
|
|
12909
|
-
})(OverlapType || {});
|
|
13043
|
+
const TableAnchorType = {
|
|
13044
|
+
MARGIN: "margin",
|
|
13045
|
+
PAGE: "page",
|
|
13046
|
+
TEXT: "text"
|
|
13047
|
+
};
|
|
13048
|
+
const RelativeHorizontalPosition = {
|
|
13049
|
+
CENTER: "center",
|
|
13050
|
+
INSIDE: "inside",
|
|
13051
|
+
LEFT: "left",
|
|
13052
|
+
OUTSIDE: "outside",
|
|
13053
|
+
RIGHT: "right"
|
|
13054
|
+
};
|
|
13055
|
+
const RelativeVerticalPosition = {
|
|
13056
|
+
CENTER: "center",
|
|
13057
|
+
INSIDE: "inside",
|
|
13058
|
+
BOTTOM: "bottom",
|
|
13059
|
+
OUTSIDE: "outside",
|
|
13060
|
+
INLINE: "inline",
|
|
13061
|
+
TOP: "top"
|
|
13062
|
+
};
|
|
13063
|
+
const OverlapType = {
|
|
13064
|
+
NEVER: "never",
|
|
13065
|
+
OVERLAP: "overlap"
|
|
13066
|
+
};
|
|
12910
13067
|
class TableFloatProperties extends XmlComponent {
|
|
12911
13068
|
constructor({
|
|
12912
13069
|
horizontalAnchor,
|
|
@@ -12924,12 +13081,18 @@ class TableFloatProperties extends XmlComponent {
|
|
|
12924
13081
|
super("w:tblpPr");
|
|
12925
13082
|
this.root.push(
|
|
12926
13083
|
new NextAttributeComponent({
|
|
12927
|
-
leftFromText: {
|
|
13084
|
+
leftFromText: {
|
|
13085
|
+
key: "w:leftFromText",
|
|
13086
|
+
value: leftFromText === void 0 ? void 0 : twipsMeasureValue(leftFromText)
|
|
13087
|
+
},
|
|
12928
13088
|
rightFromText: {
|
|
12929
13089
|
key: "w:rightFromText",
|
|
12930
13090
|
value: rightFromText === void 0 ? void 0 : twipsMeasureValue(rightFromText)
|
|
12931
13091
|
},
|
|
12932
|
-
topFromText: {
|
|
13092
|
+
topFromText: {
|
|
13093
|
+
key: "w:topFromText",
|
|
13094
|
+
value: topFromText === void 0 ? void 0 : twipsMeasureValue(topFromText)
|
|
13095
|
+
},
|
|
12933
13096
|
bottomFromText: {
|
|
12934
13097
|
key: "w:bottomFromText",
|
|
12935
13098
|
value: bottomFromText === void 0 ? void 0 : twipsMeasureValue(bottomFromText)
|
|
@@ -12965,11 +13128,10 @@ class TableFloatProperties extends XmlComponent {
|
|
|
12965
13128
|
}
|
|
12966
13129
|
}
|
|
12967
13130
|
}
|
|
12968
|
-
|
|
12969
|
-
|
|
12970
|
-
|
|
12971
|
-
|
|
12972
|
-
})(TableLayoutType || {});
|
|
13131
|
+
const TableLayoutType = {
|
|
13132
|
+
AUTOFIT: "autofit",
|
|
13133
|
+
FIXED: "fixed"
|
|
13134
|
+
};
|
|
12973
13135
|
class TableLayoutAttributes extends XmlAttributeComponent {
|
|
12974
13136
|
constructor() {
|
|
12975
13137
|
super(...arguments);
|
|
@@ -13072,12 +13234,14 @@ class Table extends FileChild {
|
|
|
13072
13234
|
});
|
|
13073
13235
|
}
|
|
13074
13236
|
}
|
|
13075
|
-
|
|
13076
|
-
|
|
13077
|
-
|
|
13078
|
-
|
|
13079
|
-
|
|
13080
|
-
|
|
13237
|
+
const HeightRule = {
|
|
13238
|
+
/** Height is determined based on the content, so value is ignored. */
|
|
13239
|
+
AUTO: "auto",
|
|
13240
|
+
/** At least the value specified */
|
|
13241
|
+
ATLEAST: "atLeast",
|
|
13242
|
+
/** Exactly the value specified */
|
|
13243
|
+
EXACT: "exact"
|
|
13244
|
+
};
|
|
13081
13245
|
class TableRowHeightAttributes extends XmlAttributeComponent {
|
|
13082
13246
|
constructor() {
|
|
13083
13247
|
super(...arguments);
|
|
@@ -13491,11 +13655,11 @@ class FootnoteRefRun extends Run {
|
|
|
13491
13655
|
this.root.push(new FootnoteRef());
|
|
13492
13656
|
}
|
|
13493
13657
|
}
|
|
13494
|
-
|
|
13495
|
-
|
|
13496
|
-
|
|
13497
|
-
|
|
13498
|
-
}
|
|
13658
|
+
const FootnoteType = {
|
|
13659
|
+
SEPERATOR: "separator",
|
|
13660
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
13661
|
+
CONTINUATION_SEPERATOR: "continuationSeparator"
|
|
13662
|
+
};
|
|
13499
13663
|
class Footnote extends XmlComponent {
|
|
13500
13664
|
constructor(options2) {
|
|
13501
13665
|
super("w:footnote");
|
|
@@ -13762,72 +13926,71 @@ class Media {
|
|
|
13762
13926
|
}
|
|
13763
13927
|
}
|
|
13764
13928
|
const WORKAROUND2 = "";
|
|
13765
|
-
|
|
13766
|
-
|
|
13767
|
-
|
|
13768
|
-
|
|
13769
|
-
|
|
13770
|
-
|
|
13771
|
-
|
|
13772
|
-
|
|
13773
|
-
|
|
13774
|
-
|
|
13775
|
-
|
|
13776
|
-
|
|
13777
|
-
|
|
13778
|
-
|
|
13779
|
-
|
|
13780
|
-
|
|
13781
|
-
|
|
13782
|
-
|
|
13783
|
-
|
|
13784
|
-
|
|
13785
|
-
|
|
13786
|
-
|
|
13787
|
-
|
|
13788
|
-
|
|
13789
|
-
|
|
13790
|
-
|
|
13791
|
-
|
|
13792
|
-
|
|
13793
|
-
|
|
13794
|
-
|
|
13795
|
-
|
|
13796
|
-
|
|
13797
|
-
|
|
13798
|
-
|
|
13799
|
-
|
|
13800
|
-
|
|
13801
|
-
|
|
13802
|
-
|
|
13803
|
-
|
|
13804
|
-
|
|
13805
|
-
|
|
13806
|
-
|
|
13807
|
-
|
|
13808
|
-
|
|
13809
|
-
|
|
13810
|
-
|
|
13811
|
-
|
|
13812
|
-
|
|
13813
|
-
|
|
13814
|
-
|
|
13815
|
-
|
|
13816
|
-
|
|
13817
|
-
|
|
13818
|
-
|
|
13819
|
-
|
|
13820
|
-
|
|
13821
|
-
|
|
13822
|
-
|
|
13823
|
-
|
|
13824
|
-
|
|
13825
|
-
|
|
13826
|
-
|
|
13827
|
-
|
|
13828
|
-
|
|
13829
|
-
|
|
13830
|
-
})(LevelFormat || {});
|
|
13929
|
+
const LevelFormat = {
|
|
13930
|
+
DECIMAL: "decimal",
|
|
13931
|
+
UPPER_ROMAN: "upperRoman",
|
|
13932
|
+
LOWER_ROMAN: "lowerRoman",
|
|
13933
|
+
UPPER_LETTER: "upperLetter",
|
|
13934
|
+
LOWER_LETTER: "lowerLetter",
|
|
13935
|
+
ORDINAL: "ordinal",
|
|
13936
|
+
CARDINAL_TEXT: "cardinalText",
|
|
13937
|
+
ORDINAL_TEXT: "ordinalText",
|
|
13938
|
+
HEX: "hex",
|
|
13939
|
+
CHICAGO: "chicago",
|
|
13940
|
+
IDEOGRAPH__DIGITAL: "ideographDigital",
|
|
13941
|
+
JAPANESE_COUNTING: "japaneseCounting",
|
|
13942
|
+
AIUEO: "aiueo",
|
|
13943
|
+
IROHA: "iroha",
|
|
13944
|
+
DECIMAL_FULL_WIDTH: "decimalFullWidth",
|
|
13945
|
+
DECIMAL_HALF_WIDTH: "decimalHalfWidth",
|
|
13946
|
+
JAPANESE_LEGAL: "japaneseLegal",
|
|
13947
|
+
JAPANESE_DIGITAL_TEN_THOUSAND: "japaneseDigitalTenThousand",
|
|
13948
|
+
DECIMAL_ENCLOSED_CIRCLE: "decimalEnclosedCircle",
|
|
13949
|
+
DECIMAL_FULL_WIDTH2: "decimalFullWidth2",
|
|
13950
|
+
AIUEO_FULL_WIDTH: "aiueoFullWidth",
|
|
13951
|
+
IROHA_FULL_WIDTH: "irohaFullWidth",
|
|
13952
|
+
DECIMAL_ZERO: "decimalZero",
|
|
13953
|
+
BULLET: "bullet",
|
|
13954
|
+
GANADA: "ganada",
|
|
13955
|
+
CHOSUNG: "chosung",
|
|
13956
|
+
DECIMAL_ENCLOSED_FULLSTOP: "decimalEnclosedFullstop",
|
|
13957
|
+
DECIMAL_ENCLOSED_PARENTHESES: "decimalEnclosedParen",
|
|
13958
|
+
DECIMAL_ENCLOSED_CIRCLE_CHINESE: "decimalEnclosedCircleChinese",
|
|
13959
|
+
IDEOGRAPH_ENCLOSED_CIRCLE: "ideographEnclosedCircle",
|
|
13960
|
+
IDEOGRAPH_TRADITIONAL: "ideographTraditional",
|
|
13961
|
+
IDEOGRAPH_ZODIAC: "ideographZodiac",
|
|
13962
|
+
IDEOGRAPH_ZODIAC_TRADITIONAL: "ideographZodiacTraditional",
|
|
13963
|
+
TAIWANESE_COUNTING: "taiwaneseCounting",
|
|
13964
|
+
IDEOGRAPH_LEGAL_TRADITIONAL: "ideographLegalTraditional",
|
|
13965
|
+
TAIWANESE_COUNTING_THOUSAND: "taiwaneseCountingThousand",
|
|
13966
|
+
TAIWANESE_DIGITAL: "taiwaneseDigital",
|
|
13967
|
+
CHINESE_COUNTING: "chineseCounting",
|
|
13968
|
+
CHINESE_LEGAL_SIMPLIFIED: "chineseLegalSimplified",
|
|
13969
|
+
CHINESE_COUNTING_THOUSAND: "chineseCountingThousand",
|
|
13970
|
+
KOREAN_DIGITAL: "koreanDigital",
|
|
13971
|
+
KOREAN_COUNTING: "koreanCounting",
|
|
13972
|
+
KOREAN_LEGAL: "koreanLegal",
|
|
13973
|
+
KOREAN_DIGITAL2: "koreanDigital2",
|
|
13974
|
+
VIETNAMESE_COUNTING: "vietnameseCounting",
|
|
13975
|
+
RUSSIAN_LOWER: "russianLower",
|
|
13976
|
+
RUSSIAN_UPPER: "russianUpper",
|
|
13977
|
+
NONE: "none",
|
|
13978
|
+
NUMBER_IN_DASH: "numberInDash",
|
|
13979
|
+
HEBREW1: "hebrew1",
|
|
13980
|
+
HEBREW2: "hebrew2",
|
|
13981
|
+
ARABIC_ALPHA: "arabicAlpha",
|
|
13982
|
+
ARABIC_ABJAD: "arabicAbjad",
|
|
13983
|
+
HINDI_VOWELS: "hindiVowels",
|
|
13984
|
+
HINDI_CONSONANTS: "hindiConsonants",
|
|
13985
|
+
HINDI_NUMBERS: "hindiNumbers",
|
|
13986
|
+
HINDI_COUNTING: "hindiCounting",
|
|
13987
|
+
THAI_LETTERS: "thaiLetters",
|
|
13988
|
+
THAI_NUMBERS: "thaiNumbers",
|
|
13989
|
+
THAI_COUNTING: "thaiCounting",
|
|
13990
|
+
BAHT_TEXT: "bahtText",
|
|
13991
|
+
DOLLAR_TEXT: "dollarText",
|
|
13992
|
+
CUSTOM: "custom"
|
|
13993
|
+
};
|
|
13831
13994
|
class LevelAttributes extends XmlAttributeComponent {
|
|
13832
13995
|
constructor() {
|
|
13833
13996
|
super(...arguments);
|
|
@@ -13867,12 +14030,11 @@ class LevelJc extends XmlComponent {
|
|
|
13867
14030
|
);
|
|
13868
14031
|
}
|
|
13869
14032
|
}
|
|
13870
|
-
|
|
13871
|
-
|
|
13872
|
-
|
|
13873
|
-
|
|
13874
|
-
|
|
13875
|
-
})(LevelSuffix || {});
|
|
14033
|
+
const LevelSuffix = {
|
|
14034
|
+
NOTHING: "nothing",
|
|
14035
|
+
SPACE: "space",
|
|
14036
|
+
TAB: "tab"
|
|
14037
|
+
};
|
|
13876
14038
|
class Suffix extends XmlComponent {
|
|
13877
14039
|
constructor(value) {
|
|
13878
14040
|
super("w:suff");
|
|
@@ -18776,14 +18938,14 @@ class Compiler {
|
|
|
18776
18938
|
};
|
|
18777
18939
|
}
|
|
18778
18940
|
}
|
|
18779
|
-
|
|
18780
|
-
|
|
18781
|
-
|
|
18782
|
-
|
|
18783
|
-
|
|
18784
|
-
|
|
18785
|
-
}
|
|
18786
|
-
const convertPrettifyType = (prettify) => prettify === true ?
|
|
18941
|
+
const PrettifyType = {
|
|
18942
|
+
NONE: "",
|
|
18943
|
+
WITH_2_BLANKS: " ",
|
|
18944
|
+
WITH_4_BLANKS: " ",
|
|
18945
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
18946
|
+
WITH_TAB: " "
|
|
18947
|
+
};
|
|
18948
|
+
const convertPrettifyType = (prettify) => prettify === true ? PrettifyType.WITH_2_BLANKS : prettify === false ? void 0 : prettify;
|
|
18787
18949
|
class Packer {
|
|
18788
18950
|
static async toString(file, prettify) {
|
|
18789
18951
|
const zip = this.compiler.compile(file, convertPrettifyType(prettify));
|
|
@@ -18855,6 +19017,11 @@ const getFirstLevelElements = (relationships, id) => {
|
|
|
18855
19017
|
var _a;
|
|
18856
19018
|
return ((_a = relationships.elements) == null ? void 0 : _a.filter((e) => e.name === id)[0].elements) ?? [];
|
|
18857
19019
|
};
|
|
19020
|
+
const ReplaceMode = {
|
|
19021
|
+
START: 0,
|
|
19022
|
+
MIDDLE: 1,
|
|
19023
|
+
END: 2
|
|
19024
|
+
};
|
|
18858
19025
|
const replaceTokenInParagraphElement = ({
|
|
18859
19026
|
paragraphElement,
|
|
18860
19027
|
renderedParagraph,
|
|
@@ -18863,11 +19030,11 @@ const replaceTokenInParagraphElement = ({
|
|
|
18863
19030
|
}) => {
|
|
18864
19031
|
const startIndex = renderedParagraph.text.indexOf(originalText);
|
|
18865
19032
|
const endIndex = startIndex + originalText.length - 1;
|
|
18866
|
-
let replaceMode =
|
|
19033
|
+
let replaceMode = ReplaceMode.START;
|
|
18867
19034
|
for (const run of renderedParagraph.runs) {
|
|
18868
19035
|
for (const { text, index, start, end } of run.parts) {
|
|
18869
19036
|
switch (replaceMode) {
|
|
18870
|
-
case
|
|
19037
|
+
case ReplaceMode.START:
|
|
18871
19038
|
if (startIndex >= start) {
|
|
18872
19039
|
const offsetStartIndex = startIndex - start;
|
|
18873
19040
|
const offsetEndIndex = Math.min(endIndex, end) - start;
|
|
@@ -18877,17 +19044,17 @@ const replaceTokenInParagraphElement = ({
|
|
|
18877
19044
|
}
|
|
18878
19045
|
const firstPart = text.replace(partToReplace, replacementText);
|
|
18879
19046
|
patchTextElement(paragraphElement.elements[run.index].elements[index], firstPart);
|
|
18880
|
-
replaceMode =
|
|
19047
|
+
replaceMode = ReplaceMode.MIDDLE;
|
|
18881
19048
|
continue;
|
|
18882
19049
|
}
|
|
18883
19050
|
break;
|
|
18884
|
-
case
|
|
19051
|
+
case ReplaceMode.MIDDLE:
|
|
18885
19052
|
if (endIndex <= end) {
|
|
18886
19053
|
const lastPart = text.substring(endIndex - start + 1);
|
|
18887
19054
|
patchTextElement(paragraphElement.elements[run.index].elements[index], lastPart);
|
|
18888
19055
|
const currentElement2 = paragraphElement.elements[run.index].elements[index];
|
|
18889
19056
|
paragraphElement.elements[run.index].elements[index] = patchSpaceAttribute(currentElement2);
|
|
18890
|
-
replaceMode =
|
|
19057
|
+
replaceMode = ReplaceMode.END;
|
|
18891
19058
|
} else {
|
|
18892
19059
|
patchTextElement(paragraphElement.elements[run.index].elements[index], "");
|
|
18893
19060
|
}
|
|
@@ -19143,11 +19310,10 @@ const appendContentType = (element2, contentType, extension) => {
|
|
|
19143
19310
|
type: "element"
|
|
19144
19311
|
});
|
|
19145
19312
|
};
|
|
19146
|
-
|
|
19147
|
-
|
|
19148
|
-
|
|
19149
|
-
|
|
19150
|
-
})(PatchType || {});
|
|
19313
|
+
const PatchType = {
|
|
19314
|
+
DOCUMENT: "file",
|
|
19315
|
+
PARAGRAPH: "paragraph"
|
|
19316
|
+
};
|
|
19151
19317
|
const imageReplacer = new ImageReplacer();
|
|
19152
19318
|
const patchDocument = async (data, options2) => {
|
|
19153
19319
|
const zipContent = await JSZip.loadAsync(data);
|