qk-pc-ui 3.7.4 → 3.7.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/qk-pc-ui.mjs +147 -33
- package/dist/qk-pc-ui.umd.js +5 -5
- package/package.json +8 -8
- /package/dist/{style.css → qk-pc-ui.css} +0 -0
package/dist/qk-pc-ui.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { ElForm, ElFormItem, ElButton, ElPagination, ElDialog, ElRow, ElSelect, ElOption, ElMessageBox, ElMessage, ElTable, ElTableColumn,
|
|
1
|
+
import { createElementBlock, openBlock, createVNode, unref, withCtx, renderSlot, createTextVNode, toDisplayString, computed, createElementVNode, createBlock, createCommentVNode, ref, reactive, watch, Fragment, renderList, normalizeStyle, onMounted, useSlots, nextTick, mergeModels, useModel, onBeforeUnmount, normalizeClass, onUnmounted, withDirectives, vModelText, withKeys } from "vue";
|
|
2
|
+
import { ElForm, ElFormItem, ElButton, ElPagination, ElDialog, ElRow, ElSelect, ElOption, ElMessageBox, ElMessage, ElTable, ElTableColumn, ElLink, ElPopover, ElInput, ElCheckboxGroup, ElCheckbox, ElIcon, ElDropdown, ElDropdownMenu, ElDropdownItem, ElLoading, ElDatePicker, ElUpload, ElButtonGroup, ElRadioGroup, ElRadioButton, ElSwitch, ElTag, ElTabs, ElTabPane, ElCascader } from "element-plus";
|
|
3
3
|
import { L, Sleep, SaasApi, AndroidApi, GetUrlParam, SystemModuleApi, AjaxCallWeb, LocalApi, GetEnumName, MemberApi, UnRegisterKeyboard, RegisterKeyboard, PlayTTS, InfrastructureApi } from "qk-lib-v3";
|
|
4
4
|
import { Setting, Plus, ArrowDown } from "@element-plus/icons-vue";
|
|
5
5
|
import E from "wangeditor";
|
|
@@ -433,6 +433,7 @@ function SSF_write_date(e, r, t, a) {
|
|
|
433
433
|
switch (e) {
|
|
434
434
|
case 98:
|
|
435
435
|
l = t.y + 543;
|
|
436
|
+
/* falls through */
|
|
436
437
|
case 121:
|
|
437
438
|
switch (r.length) {
|
|
438
439
|
case 1:
|
|
@@ -823,12 +824,14 @@ function fmt_is_date(e) {
|
|
|
823
824
|
case "B":
|
|
824
825
|
case "b":
|
|
825
826
|
if (e.charAt(r + 1) === "1" || e.charAt(r + 1) === "2") return !0;
|
|
827
|
+
/* falls through */
|
|
826
828
|
case "M":
|
|
827
829
|
case "D":
|
|
828
830
|
case "Y":
|
|
829
831
|
case "H":
|
|
830
832
|
case "S":
|
|
831
833
|
case "E":
|
|
834
|
+
/* falls through */
|
|
832
835
|
case "m":
|
|
833
836
|
case "d":
|
|
834
837
|
case "y":
|
|
@@ -848,6 +851,7 @@ function fmt_is_date(e) {
|
|
|
848
851
|
if (a.match(SSF_abstime)) return !0;
|
|
849
852
|
break;
|
|
850
853
|
case ".":
|
|
854
|
+
/* falls through */
|
|
851
855
|
case "0":
|
|
852
856
|
case "#":
|
|
853
857
|
for (; r < e.length && ("0#?.,E+-%".indexOf(t = e.charAt(++r)) > -1 || t == "\\" && e.charAt(r + 1) == "-" && "0#".indexOf(e.charAt(r + 2)) > -1); )
|
|
@@ -914,6 +918,7 @@ function eval_fmt(e, r, t, a) {
|
|
|
914
918
|
n[n.length] = { t: "X", v: e.substr(s, 2) }, o = l, s += 2;
|
|
915
919
|
break;
|
|
916
920
|
}
|
|
921
|
+
/* falls through */
|
|
917
922
|
case "M":
|
|
918
923
|
case "D":
|
|
919
924
|
case "Y":
|
|
@@ -921,6 +926,7 @@ function eval_fmt(e, r, t, a) {
|
|
|
921
926
|
case "S":
|
|
922
927
|
case "E":
|
|
923
928
|
l = l.toLowerCase();
|
|
929
|
+
/* falls through */
|
|
924
930
|
case "m":
|
|
925
931
|
case "d":
|
|
926
932
|
case "y":
|
|
@@ -949,12 +955,14 @@ function eval_fmt(e, r, t, a) {
|
|
|
949
955
|
n[n.length] = { t: "Z", v: i.toLowerCase() }, o = i.charAt(1);
|
|
950
956
|
} else i.indexOf("$") > -1 && (i = (i.match(/\$([^-\[\]]*)/) || [])[1] || "$", fmt_is_date(e) || (n[n.length] = { t: "t", v: i }));
|
|
951
957
|
break;
|
|
958
|
+
/* Numbers */
|
|
952
959
|
case ".":
|
|
953
960
|
if (f != null) {
|
|
954
961
|
for (i = l; ++s < e.length && (l = e.charAt(s)) === "0"; ) i += l;
|
|
955
962
|
n[n.length] = { t: "s", v: i };
|
|
956
963
|
break;
|
|
957
964
|
}
|
|
965
|
+
/* falls through */
|
|
958
966
|
case "0":
|
|
959
967
|
case "#":
|
|
960
968
|
for (i = l; ++s < e.length && "0#?.,E+-%".indexOf(l = e.charAt(s)) > -1; ) i += l;
|
|
@@ -967,6 +975,7 @@ function eval_fmt(e, r, t, a) {
|
|
|
967
975
|
case "*":
|
|
968
976
|
++s, (e.charAt(s) == " " || e.charAt(s) == "*") && ++s;
|
|
969
977
|
break;
|
|
978
|
+
// **
|
|
970
979
|
case "(":
|
|
971
980
|
case ")":
|
|
972
981
|
n[n.length] = { t: a === 1 ? "t" : l, v: l }, ++s;
|
|
@@ -1003,6 +1012,7 @@ function eval_fmt(e, r, t, a) {
|
|
|
1003
1012
|
break;
|
|
1004
1013
|
case "s":
|
|
1005
1014
|
(I = n[s].v.match(/\.0+$/)) && (C = Math.max(C, I[0].length - 1)), _ < 3 && (_ = 3);
|
|
1015
|
+
/* falls through */
|
|
1006
1016
|
case "d":
|
|
1007
1017
|
case "y":
|
|
1008
1018
|
case "M":
|
|
@@ -1297,6 +1307,7 @@ var CRC32 = /* @__PURE__ */ function() {
|
|
|
1297
1307
|
), g = 0; x.l <= x.length - 4; ) {
|
|
1298
1308
|
var w = x.read_shift(2), T = x.read_shift(2), y = x.l + T, V = {};
|
|
1299
1309
|
switch (w) {
|
|
1310
|
+
/* UNIX-style Timestamps */
|
|
1300
1311
|
case 21589:
|
|
1301
1312
|
g = x.read_shift(1), g & 1 && (V.mtime = x.read_shift(4)), T > 5 && (g & 2 && (V.atime = x.read_shift(4)), g & 4 && (V.ctime = x.read_shift(4))), V.mtime && (V.mt = new Date(V.mtime * 1e3));
|
|
1302
1313
|
break;
|
|
@@ -1328,6 +1339,7 @@ var CRC32 = /* @__PURE__ */ function() {
|
|
|
1328
1339
|
break;
|
|
1329
1340
|
case 0:
|
|
1330
1341
|
if (Y[1] == 0) return Je(x, v);
|
|
1342
|
+
/* falls through */
|
|
1331
1343
|
default:
|
|
1332
1344
|
throw new Error("Major Version: Expected 3 or 4 saw " + g);
|
|
1333
1345
|
}
|
|
@@ -1680,6 +1692,7 @@ var CRC32 = /* @__PURE__ */ function() {
|
|
|
1680
1692
|
return Base64_encode(typeof g == "string" ? g : he(g));
|
|
1681
1693
|
case "buffer":
|
|
1682
1694
|
if (has_buf) return Buffer.isBuffer(g) ? g : Buffer_from(g);
|
|
1695
|
+
/* falls through */
|
|
1683
1696
|
case "array":
|
|
1684
1697
|
return typeof g == "string" ? s2a(g) : g;
|
|
1685
1698
|
}
|
|
@@ -1996,6 +2009,7 @@ var CRC32 = /* @__PURE__ */ function() {
|
|
|
1996
2009
|
break;
|
|
1997
2010
|
case 0:
|
|
1998
2011
|
break;
|
|
2012
|
+
// TODO: scan for magic number
|
|
1999
2013
|
default:
|
|
2000
2014
|
throw new Error("Unsupported ZIP Compression method " + V);
|
|
2001
2015
|
}
|
|
@@ -2220,6 +2234,7 @@ function write_dl(e, r, t) {
|
|
|
2220
2234
|
case "binary":
|
|
2221
2235
|
r = s2ab(r);
|
|
2222
2236
|
break;
|
|
2237
|
+
/* TODO: binary equivalent */
|
|
2223
2238
|
default:
|
|
2224
2239
|
throw new Error("Unsupported encoding " + t);
|
|
2225
2240
|
}
|
|
@@ -2429,6 +2444,7 @@ function parsexmlbool(e) {
|
|
|
2429
2444
|
case "true":
|
|
2430
2445
|
case "TRUE":
|
|
2431
2446
|
return !0;
|
|
2447
|
+
/* case '0': case 'false': case 'FALSE':*/
|
|
2432
2448
|
default:
|
|
2433
2449
|
return !1;
|
|
2434
2450
|
}
|
|
@@ -2538,9 +2554,7 @@ var XMLNS = {
|
|
|
2538
2554
|
dc: "http://purl.org/dc/elements/1.1/",
|
|
2539
2555
|
dcterms: "http://purl.org/dc/terms/",
|
|
2540
2556
|
dcmitype: "http://purl.org/dc/dcmitype/",
|
|
2541
|
-
mx: "http://schemas.microsoft.com/office/mac/excel/2008/main",
|
|
2542
2557
|
r: "http://schemas.openxmlformats.org/officeDocument/2006/relationships",
|
|
2543
|
-
sjs: "http://schemas.openxmlformats.org/package/2006/sheetjs/core-properties",
|
|
2544
2558
|
vt: "http://schemas.openxmlformats.org/officeDocument/2006/docPropsVTypes",
|
|
2545
2559
|
xsi: "http://www.w3.org/2001/XMLSchema-instance",
|
|
2546
2560
|
xsd: "http://www.w3.org/2001/XMLSchema"
|
|
@@ -2666,18 +2680,22 @@ function ReadShift(e, r) {
|
|
|
2666
2680
|
break;
|
|
2667
2681
|
case "wstr":
|
|
2668
2682
|
return ReadShift.call(this, e, "dbcs");
|
|
2683
|
+
/* [MS-OLEDS] 2.1.4 LengthPrefixedAnsiString */
|
|
2669
2684
|
case "lpstr-ansi":
|
|
2670
2685
|
t = __lpstr(this, this.l), e = 4 + __readUInt32LE(this, this.l);
|
|
2671
2686
|
break;
|
|
2672
2687
|
case "lpstr-cp":
|
|
2673
2688
|
t = __cpstr(this, this.l), e = 4 + __readUInt32LE(this, this.l);
|
|
2674
2689
|
break;
|
|
2690
|
+
/* [MS-OLEDS] 2.1.5 LengthPrefixedUnicodeString */
|
|
2675
2691
|
case "lpwstr":
|
|
2676
2692
|
t = __lpwstr(this, this.l), e = 4 + 2 * __readUInt32LE(this, this.l);
|
|
2677
2693
|
break;
|
|
2694
|
+
/* [MS-OFFCRYPTO] 2.1.2 Length-Prefixed Padded Unicode String (UNICODE-LP-P4) */
|
|
2678
2695
|
case "lpp4":
|
|
2679
2696
|
e = 4 + __readUInt32LE(this, this.l), t = __lpp4(this, this.l), e & 2 && (e += 2);
|
|
2680
2697
|
break;
|
|
2698
|
+
/* [MS-OFFCRYPTO] 2.1.3 Length-Prefixed UTF-8 String (UTF-8-LP-P4) */
|
|
2681
2699
|
case "8lpp4":
|
|
2682
2700
|
e = 4 + __readUInt32LE(this, this.l), t = __8lpp4(this, this.l), e & 3 && (e += 4 - (e & 3));
|
|
2683
2701
|
break;
|
|
@@ -2690,6 +2708,7 @@ function ReadShift(e, r) {
|
|
|
2690
2708
|
i.push(_getchar(s)), e += 2;
|
|
2691
2709
|
e += 2, t = i.join("");
|
|
2692
2710
|
break;
|
|
2711
|
+
/* sbcs and dbcs support continue records in the SST way TODO codepages */
|
|
2693
2712
|
case "dbcs-cont":
|
|
2694
2713
|
for (t = "", f = this.l, o = 0; o < e; ++o) {
|
|
2695
2714
|
if (this.lens && this.lens.indexOf(f) !== -1)
|
|
@@ -2699,6 +2718,7 @@ function ReadShift(e, r) {
|
|
|
2699
2718
|
t = i.join(""), e *= 2;
|
|
2700
2719
|
break;
|
|
2701
2720
|
case "cpstr":
|
|
2721
|
+
/* falls through */
|
|
2702
2722
|
case "sbcs-cont":
|
|
2703
2723
|
for (t = "", f = this.l, o = 0; o != e; ++o) {
|
|
2704
2724
|
if (this.lens && this.lens.indexOf(f) !== -1)
|
|
@@ -2721,6 +2741,7 @@ function ReadShift(e, r) {
|
|
|
2721
2741
|
if (r === "f")
|
|
2722
2742
|
return e == 8 ? n = __double(this, this.l) : n = __double([this[this.l + 7], this[this.l + 6], this[this.l + 5], this[this.l + 4], this[this.l + 3], this[this.l + 2], this[this.l + 1], this[this.l + 0]], 0), this.l += 8, n;
|
|
2723
2743
|
e = 8;
|
|
2744
|
+
/* falls through */
|
|
2724
2745
|
case 16:
|
|
2725
2746
|
t = __hexlify(this, this.l, e);
|
|
2726
2747
|
break;
|
|
@@ -2773,6 +2794,7 @@ function WriteShift(e, r, t) {
|
|
|
2773
2794
|
write_double_le(this, r, this.l);
|
|
2774
2795
|
break;
|
|
2775
2796
|
}
|
|
2797
|
+
/* falls through */
|
|
2776
2798
|
case 16:
|
|
2777
2799
|
break;
|
|
2778
2800
|
case -4:
|
|
@@ -3011,7 +3033,7 @@ function write_RichStr(e, r) {
|
|
|
3011
3033
|
var parse_BrtCommentText = parse_RichStr;
|
|
3012
3034
|
function write_BrtCommentText(e, r) {
|
|
3013
3035
|
var t = !1;
|
|
3014
|
-
return r == null && (t = !0, r = new_buf(23 + 4 * e.t.length)), r.write_shift(1, 1), write_XLWideString(e.t, r), r.write_shift(4, 1), write_StrRun({
|
|
3036
|
+
return r == null && (t = !0, r = new_buf(23 + 4 * e.t.length)), r.write_shift(1, 1), write_XLWideString(e.t, r), r.write_shift(4, 1), write_StrRun({}, r), t ? r.slice(0, r.l) : r;
|
|
3015
3037
|
}
|
|
3016
3038
|
function parse_XLSBCell(e) {
|
|
3017
3039
|
var r = e.read_shift(4), t = e.read_shift(2);
|
|
@@ -3046,7 +3068,7 @@ function parse_RkNumber(e) {
|
|
|
3046
3068
|
function write_RkNumber(e, r) {
|
|
3047
3069
|
r == null && (r = new_buf(4));
|
|
3048
3070
|
var t = 0, a = 0, n = e * 100;
|
|
3049
|
-
if (e == (e | 0) && e >= -
|
|
3071
|
+
if (e == (e | 0) && e >= -536870912 && e < 1 << 29 ? a = 1 : n == (n | 0) && n >= -536870912 && n < 1 << 29 && (a = 1, t = 1), a) r.write_shift(-4, ((t ? n : e) << 2) + (t + 2));
|
|
3050
3072
|
else throw new Error("unsupported RkNumber " + e);
|
|
3051
3073
|
}
|
|
3052
3074
|
function parse_RfX(e) {
|
|
@@ -3622,14 +3644,10 @@ function write_ct(e, r) {
|
|
|
3622
3644
|
}
|
|
3623
3645
|
var RELS = {
|
|
3624
3646
|
WB: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",
|
|
3625
|
-
SHEET: "http://sheetjs.openxmlformats.org/officeDocument/2006/relationships/officeDocument",
|
|
3626
3647
|
HLINK: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink",
|
|
3627
3648
|
VML: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/vmlDrawing",
|
|
3628
3649
|
XPATH: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/externalLinkPath",
|
|
3629
3650
|
XMISS: "http://schemas.microsoft.com/office/2006/relationships/xlExternalLinkPath/xlPathMissing",
|
|
3630
|
-
XLINK: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/externalLink",
|
|
3631
|
-
CXML: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/customXml",
|
|
3632
|
-
CXMLP: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/customXmlProps",
|
|
3633
3651
|
CMNT: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments",
|
|
3634
3652
|
CORE_PROPS: "http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties",
|
|
3635
3653
|
EXT_PROPS: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties",
|
|
@@ -3637,16 +3655,10 @@ var RELS = {
|
|
|
3637
3655
|
SST: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings",
|
|
3638
3656
|
STY: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles",
|
|
3639
3657
|
THEME: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",
|
|
3640
|
-
CHART: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/chart",
|
|
3641
|
-
CHARTEX: "http://schemas.microsoft.com/office/2014/relationships/chartEx",
|
|
3642
|
-
CS: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/chartsheet",
|
|
3643
3658
|
WS: [
|
|
3644
3659
|
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet",
|
|
3645
3660
|
"http://purl.oclc.org/ooxml/officeDocument/relationships/worksheet"
|
|
3646
3661
|
],
|
|
3647
|
-
DS: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/dialogsheet",
|
|
3648
|
-
MS: "http://schemas.microsoft.com/office/2006/relationships/xlMacrosheet",
|
|
3649
|
-
IMG: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",
|
|
3650
3662
|
DRAW: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing",
|
|
3651
3663
|
XLMETA: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/sheetMetadata",
|
|
3652
3664
|
TCMNT: "http://schemas.microsoft.com/office/2017/10/relationships/threadedComment",
|
|
@@ -4129,7 +4141,7 @@ function write_Window2(e) {
|
|
|
4129
4141
|
}
|
|
4130
4142
|
function write_Font(e, r) {
|
|
4131
4143
|
var t = e.name || "Arial", a = r && r.biff == 5, n = a ? 15 + t.length : 16 + 2 * t.length, i = new_buf(n);
|
|
4132
|
-
return i.write_shift(2,
|
|
4144
|
+
return i.write_shift(2, e.sz * 20), i.write_shift(4, 0), i.write_shift(2, 400), i.write_shift(4, 0), i.write_shift(2, 0), i.write_shift(1, t.length), a || i.write_shift(1, 1), i.write_shift((a ? 1 : 2) * t.length, t, a ? "sbcs" : "utf16le"), i;
|
|
4133
4145
|
}
|
|
4134
4146
|
function write_LabelSst(e, r, t, a) {
|
|
4135
4147
|
var n = new_buf(10);
|
|
@@ -4443,23 +4455,35 @@ var DBF = /* @__PURE__ */ function() {
|
|
|
4443
4455
|
switch (p) {
|
|
4444
4456
|
case 2:
|
|
4445
4457
|
break;
|
|
4458
|
+
// dBASE II
|
|
4446
4459
|
case 3:
|
|
4447
4460
|
break;
|
|
4461
|
+
// dBASE III
|
|
4448
4462
|
case 48:
|
|
4449
4463
|
d = !0, h = !0;
|
|
4450
4464
|
break;
|
|
4465
|
+
// VFP
|
|
4451
4466
|
case 49:
|
|
4452
4467
|
d = !0, h = !0;
|
|
4453
4468
|
break;
|
|
4469
|
+
// VFP with autoincrement
|
|
4470
|
+
// 0x43 dBASE IV SQL table files
|
|
4471
|
+
// 0x63 dBASE IV SQL system files
|
|
4454
4472
|
case 131:
|
|
4455
4473
|
break;
|
|
4474
|
+
// dBASE III with memo
|
|
4456
4475
|
case 139:
|
|
4457
4476
|
break;
|
|
4477
|
+
// dBASE IV with memo
|
|
4458
4478
|
case 140:
|
|
4459
4479
|
m = !0;
|
|
4460
4480
|
break;
|
|
4481
|
+
// dBASE Level 7 with memo
|
|
4482
|
+
// case 0xCB dBASE IV SQL table files with memo
|
|
4461
4483
|
case 245:
|
|
4462
4484
|
break;
|
|
4485
|
+
// FoxPro 2.x with memo
|
|
4486
|
+
// case 0xFB FoxBASE
|
|
4463
4487
|
default:
|
|
4464
4488
|
throw new Error("DBF Unsupported Version: " + p.toString(16));
|
|
4465
4489
|
}
|
|
@@ -4473,21 +4497,34 @@ var DBF = /* @__PURE__ */ function() {
|
|
|
4473
4497
|
(!d || b.len != 8) && o.WTF && console.log("Skipping " + b.name + ":" + b.type);
|
|
4474
4498
|
break;
|
|
4475
4499
|
case "G":
|
|
4500
|
+
// General (FoxPro and dBASE L7)
|
|
4476
4501
|
case "P":
|
|
4477
4502
|
o.WTF && console.log("Skipping " + b.name + ":" + b.type);
|
|
4478
4503
|
break;
|
|
4479
4504
|
case "+":
|
|
4505
|
+
// Autoincrement (dBASE L7 only)
|
|
4480
4506
|
case "0":
|
|
4507
|
+
// _NullFlags (VFP only)
|
|
4481
4508
|
case "@":
|
|
4509
|
+
// Timestamp (dBASE L7 only)
|
|
4482
4510
|
case "C":
|
|
4511
|
+
// Character (dBASE II)
|
|
4483
4512
|
case "D":
|
|
4513
|
+
// Date (dBASE III)
|
|
4484
4514
|
case "F":
|
|
4515
|
+
// Float (dBASE IV)
|
|
4485
4516
|
case "I":
|
|
4517
|
+
// Long (VFP and dBASE L7)
|
|
4486
4518
|
case "L":
|
|
4519
|
+
// Logical (dBASE II)
|
|
4487
4520
|
case "M":
|
|
4521
|
+
// Memo (dBASE III)
|
|
4488
4522
|
case "N":
|
|
4523
|
+
// Number (dBASE II)
|
|
4489
4524
|
case "O":
|
|
4525
|
+
// Double (dBASE L7 only)
|
|
4490
4526
|
case "T":
|
|
4527
|
+
// Datetime (VFP only)
|
|
4491
4528
|
case "Y":
|
|
4492
4529
|
break;
|
|
4493
4530
|
default:
|
|
@@ -4561,12 +4598,14 @@ var DBF = /* @__PURE__ */ function() {
|
|
|
4561
4598
|
f[A][X] = S.read_shift(8, "f");
|
|
4562
4599
|
break;
|
|
4563
4600
|
}
|
|
4601
|
+
/* falls through */
|
|
4564
4602
|
case "G":
|
|
4565
4603
|
case "P":
|
|
4566
4604
|
S.l += F[X].len;
|
|
4567
4605
|
break;
|
|
4568
4606
|
case "0":
|
|
4569
4607
|
if (F[X].name === "_NullFlags") break;
|
|
4608
|
+
/* falls through */
|
|
4570
4609
|
default:
|
|
4571
4610
|
throw new Error("DBF Unsupported data type " + F[X].type);
|
|
4572
4611
|
}
|
|
@@ -4626,6 +4665,7 @@ var DBF = /* @__PURE__ */ function() {
|
|
|
4626
4665
|
}
|
|
4627
4666
|
for (_ = 0; _ < O.length; ++_) {
|
|
4628
4667
|
switch (typeof O[_]) {
|
|
4668
|
+
/* TODO: check if L2 compat is desired */
|
|
4629
4669
|
case "number":
|
|
4630
4670
|
X = "B";
|
|
4631
4671
|
break;
|
|
@@ -4817,14 +4857,19 @@ var DBF = /* @__PURE__ */ function() {
|
|
|
4817
4857
|
if (B.length > 0) switch (ae) {
|
|
4818
4858
|
case "ID":
|
|
4819
4859
|
break;
|
|
4860
|
+
/* header */
|
|
4820
4861
|
case "E":
|
|
4821
4862
|
break;
|
|
4863
|
+
/* EOF */
|
|
4822
4864
|
case "B":
|
|
4823
4865
|
break;
|
|
4866
|
+
/* dimensions */
|
|
4824
4867
|
case "O":
|
|
4825
4868
|
break;
|
|
4869
|
+
/* options? */
|
|
4826
4870
|
case "W":
|
|
4827
4871
|
break;
|
|
4872
|
+
/* window? */
|
|
4828
4873
|
case "P":
|
|
4829
4874
|
H[1].charAt(0) == "P" && b.push(B.slice(3).replace(/;;/g, ";"));
|
|
4830
4875
|
break;
|
|
@@ -4833,6 +4878,7 @@ var DBF = /* @__PURE__ */ function() {
|
|
|
4833
4878
|
for (I = 1; I < H.length; ++I) switch (H[I].charAt(0)) {
|
|
4834
4879
|
case "A":
|
|
4835
4880
|
break;
|
|
4881
|
+
// TODO: comment
|
|
4836
4882
|
case "X":
|
|
4837
4883
|
_ = parseInt(H[I].slice(1)) - 1, te = !0;
|
|
4838
4884
|
break;
|
|
@@ -4852,6 +4898,7 @@ var DBF = /* @__PURE__ */ function() {
|
|
|
4852
4898
|
break;
|
|
4853
4899
|
case "G":
|
|
4854
4900
|
break;
|
|
4901
|
+
// unknown
|
|
4855
4902
|
case "R":
|
|
4856
4903
|
ve = parseInt(H[I].slice(1)) - 1;
|
|
4857
4904
|
break;
|
|
@@ -4882,17 +4929,22 @@ var DBF = /* @__PURE__ */ function() {
|
|
|
4882
4929
|
break;
|
|
4883
4930
|
case "F":
|
|
4884
4931
|
break;
|
|
4932
|
+
/* ??? */
|
|
4885
4933
|
case "G":
|
|
4886
4934
|
break;
|
|
4935
|
+
/* hide grid */
|
|
4887
4936
|
case "P":
|
|
4888
4937
|
G = b[parseInt(H[I].slice(1))];
|
|
4889
4938
|
break;
|
|
4890
4939
|
case "S":
|
|
4891
4940
|
break;
|
|
4941
|
+
/* cell style */
|
|
4892
4942
|
case "D":
|
|
4893
4943
|
break;
|
|
4944
|
+
/* column */
|
|
4894
4945
|
case "N":
|
|
4895
4946
|
break;
|
|
4947
|
+
/* font */
|
|
4896
4948
|
case "W":
|
|
4897
4949
|
for (S = H[I].slice(1).split(" "), N = parseInt(S[0], 10); N <= parseInt(S[1], 10); ++N)
|
|
4898
4950
|
O = parseInt(S[2], 10), X[N - 1] = O === 0 ? { hidden: !0 } : { wch: O }, process_col(X[N - 1]);
|
|
@@ -5094,6 +5146,7 @@ var DBF = /* @__PURE__ */ function() {
|
|
|
5094
5146
|
break;
|
|
5095
5147
|
case "vtf":
|
|
5096
5148
|
var b = I[I.length - 1];
|
|
5149
|
+
/* falls through */
|
|
5097
5150
|
case "vtc":
|
|
5098
5151
|
switch (I[3]) {
|
|
5099
5152
|
case "nl":
|
|
@@ -5273,7 +5326,7 @@ var DBF = /* @__PURE__ */ function() {
|
|
|
5273
5326
|
h = c;
|
|
5274
5327
|
break;
|
|
5275
5328
|
case "buffer":
|
|
5276
|
-
p.codepage == 65001 ? h = c.toString("utf8") :
|
|
5329
|
+
p.codepage == 65001 ? h = c.toString("utf8") : (p.codepage, h = has_buf && Buffer.isBuffer(c) ? c.toString("binary") : a2s(c));
|
|
5277
5330
|
break;
|
|
5278
5331
|
case "array":
|
|
5279
5332
|
h = cc2str(c);
|
|
@@ -5284,7 +5337,7 @@ var DBF = /* @__PURE__ */ function() {
|
|
|
5284
5337
|
default:
|
|
5285
5338
|
throw new Error("Unrecognized type " + p.type);
|
|
5286
5339
|
}
|
|
5287
|
-
return d[0] == 239 && d[1] == 187 && d[2] == 191 ? h = utf8read(h.slice(3)) : p.type != "string" && p.type != "buffer" && p.codepage == 65001 ? h = utf8read(h) : p.type == "binary"
|
|
5340
|
+
return d[0] == 239 && d[1] == 187 && d[2] == 191 ? h = utf8read(h.slice(3)) : p.type != "string" && p.type != "buffer" && p.codepage == 65001 ? h = utf8read(h) : p.type == "binary", h.slice(0, 19) == "socialcalc:version:" ? ETH.to_sheet(p.type == "string" ? h : utf8read(h), p) : s(h, p);
|
|
5288
5341
|
}
|
|
5289
5342
|
function o(c, p) {
|
|
5290
5343
|
return sheet_to_workbook(l(c, p), p);
|
|
@@ -5346,17 +5399,24 @@ var DBF = /* @__PURE__ */ function() {
|
|
|
5346
5399
|
case 6:
|
|
5347
5400
|
fe = re;
|
|
5348
5401
|
break;
|
|
5402
|
+
/* RANGE */
|
|
5349
5403
|
case 204:
|
|
5350
5404
|
re && (se = re);
|
|
5351
5405
|
break;
|
|
5406
|
+
/* SHEETNAMECS */
|
|
5352
5407
|
case 222:
|
|
5353
5408
|
se = re;
|
|
5354
5409
|
break;
|
|
5410
|
+
/* SHEETNAMELP */
|
|
5355
5411
|
case 15:
|
|
5412
|
+
/* LABEL */
|
|
5356
5413
|
case 51:
|
|
5357
5414
|
P.qpro || (re[1].v = re[1].v.slice(1));
|
|
5415
|
+
/* falls through */
|
|
5358
5416
|
case 13:
|
|
5417
|
+
/* INTEGER */
|
|
5359
5418
|
case 14:
|
|
5419
|
+
/* NUMBER */
|
|
5360
5420
|
case 16:
|
|
5361
5421
|
Ce == 14 && (re[2] & 112) == 112 && (re[2] & 15) > 1 && (re[2] & 15) < 15 && (re[1].z = P.dateNF || table_fmt[14], P.cellDates && (re[1].t = "d", re[1].v = numdate(re[1].v))), P.qpro && re[3] > le && (D["!ref"] = encode_range(fe), ie[K] = D, Z.push(K), D = P.dense ? [] : {}, fe = { s: { r: 0, c: 0 }, e: { r: 0, c: 0 } }, le = re[3], K = se || "Sheet" + (le + 1), se = "");
|
|
5362
5422
|
var Fe = P.dense ? (D[re[0].r] || [])[re[0].c] : D[encode_cell(re[0])];
|
|
@@ -5374,13 +5434,20 @@ var DBF = /* @__PURE__ */ function() {
|
|
|
5374
5434
|
case 204:
|
|
5375
5435
|
K = re;
|
|
5376
5436
|
break;
|
|
5437
|
+
/* SHEETNAMECS */
|
|
5377
5438
|
case 22:
|
|
5378
5439
|
re[1].v = re[1].v.slice(1);
|
|
5440
|
+
/* falls through */
|
|
5379
5441
|
case 23:
|
|
5442
|
+
/* NUMBER17 */
|
|
5380
5443
|
case 24:
|
|
5444
|
+
/* NUMBER18 */
|
|
5381
5445
|
case 25:
|
|
5446
|
+
/* FORMULA19 */
|
|
5382
5447
|
case 37:
|
|
5448
|
+
/* NUMBER25 */
|
|
5383
5449
|
case 39:
|
|
5450
|
+
/* NUMBER27 */
|
|
5384
5451
|
case 40:
|
|
5385
5452
|
if (re[3] > le && (D["!ref"] = encode_range(fe), ie[K] = D, Z.push(K), D = P.dense ? [] : {}, fe = { s: { r: 0, c: 0 }, e: { r: 0, c: 0 } }, le = re[3], K = "Sheet" + (le + 1)), Ee > 0 && re[0].r >= Ee) break;
|
|
5386
5453
|
P.dense ? (D[re[0].r] || (D[re[0].r] = []), D[re[0].r][re[0].c] = re[1]) : D[encode_cell(re[0])] = re[1], fe.e.c < re[0].c && (fe.e.c = re[0].c), fe.e.r < re[0].r && (fe.e.r = re[0].r);
|
|
@@ -6294,6 +6361,7 @@ function parse_BrtFont(e, r, t) {
|
|
|
6294
6361
|
n.fItalic && (a.italic = 1), n.fCondense && (a.condense = 1), n.fExtend && (a.extend = 1), n.fShadow && (a.shadow = 1), n.fOutline && (a.outline = 1), n.fStrikeout && (a.strike = 1);
|
|
6295
6362
|
var i = e.read_shift(2);
|
|
6296
6363
|
switch (i === 700 && (a.bold = 1), e.read_shift(2)) {
|
|
6364
|
+
/* case 0: out.vertAlign = "baseline"; break; */
|
|
6297
6365
|
case 1:
|
|
6298
6366
|
a.vertAlign = "superscript";
|
|
6299
6367
|
break;
|
|
@@ -6307,6 +6375,7 @@ function parse_BrtFont(e, r, t) {
|
|
|
6307
6375
|
l > 0 && (a.family = l);
|
|
6308
6376
|
var o = e.read_shift(1);
|
|
6309
6377
|
switch (o > 0 && (a.charset = o), e.l++, a.color = parse_BrtColor(e), e.read_shift(1)) {
|
|
6378
|
+
/* case 0: out.scheme = "none": break; */
|
|
6310
6379
|
case 1:
|
|
6311
6380
|
a.scheme = "major";
|
|
6312
6381
|
break;
|
|
@@ -6321,7 +6390,7 @@ function write_BrtFont(e, r) {
|
|
|
6321
6390
|
var t = 0;
|
|
6322
6391
|
e.vertAlign == "superscript" ? t = 1 : e.vertAlign == "subscript" && (t = 2), r.write_shift(2, t), r.write_shift(1, e.underline || 0), r.write_shift(1, e.family || 0), r.write_shift(1, e.charset || 0), r.write_shift(1, 0), write_BrtColor(e.color, r);
|
|
6323
6392
|
var a = 0;
|
|
6324
|
-
return
|
|
6393
|
+
return a = 2, r.write_shift(1, a), write_XLWideString(e.name, r), r.length > r.l ? r.slice(0, r.l) : r;
|
|
6325
6394
|
}
|
|
6326
6395
|
var XLSBFillPTNames = [
|
|
6327
6396
|
"none",
|
|
@@ -6374,7 +6443,7 @@ function write_BrtBorder(e, r) {
|
|
|
6374
6443
|
return r || (r = new_buf(51)), r.write_shift(1, 0), write_Blxf(null, r), write_Blxf(null, r), write_Blxf(null, r), write_Blxf(null, r), write_Blxf(null, r), r.length > r.l ? r.slice(0, r.l) : r;
|
|
6375
6444
|
}
|
|
6376
6445
|
function write_BrtStyle(e, r) {
|
|
6377
|
-
return r || (r = new_buf(12 + 4 * 10)), r.write_shift(4, e.xfId), r.write_shift(2, 1), r.write_shift(1,
|
|
6446
|
+
return r || (r = new_buf(12 + 4 * 10)), r.write_shift(4, e.xfId), r.write_shift(2, 1), r.write_shift(1, 0), r.write_shift(1, 0), write_XLNullableWideString(e.name || "", r), r.length > r.l ? r.slice(0, r.l) : r;
|
|
6378
6447
|
}
|
|
6379
6448
|
function write_BrtBeginTableStyles(e, r, t) {
|
|
6380
6449
|
var a = new_buf(2052);
|
|
@@ -6410,8 +6479,7 @@ function write_FONTS_bin(e) {
|
|
|
6410
6479
|
sz: 12,
|
|
6411
6480
|
color: { theme: 1 },
|
|
6412
6481
|
name: "Calibri",
|
|
6413
|
-
family: 2
|
|
6414
|
-
scheme: "minor"
|
|
6482
|
+
family: 2
|
|
6415
6483
|
})), write_record(
|
|
6416
6484
|
e,
|
|
6417
6485
|
612
|
|
@@ -6437,10 +6505,7 @@ function write_BORDERS_bin(e) {
|
|
|
6437
6505
|
function write_CELLSTYLEXFS_bin(e) {
|
|
6438
6506
|
var r = 1;
|
|
6439
6507
|
write_record(e, 626, write_UInt32LE(r)), write_record(e, 47, write_BrtXF({
|
|
6440
|
-
numFmtId: 0
|
|
6441
|
-
fontId: 0,
|
|
6442
|
-
fillId: 0,
|
|
6443
|
-
borderId: 0
|
|
6508
|
+
numFmtId: 0
|
|
6444
6509
|
}, 65535)), write_record(
|
|
6445
6510
|
e,
|
|
6446
6511
|
627
|
|
@@ -6460,7 +6525,6 @@ function write_STYLES_bin(e) {
|
|
|
6460
6525
|
var r = 1;
|
|
6461
6526
|
write_record(e, 619, write_UInt32LE(r)), write_record(e, 48, write_BrtStyle({
|
|
6462
6527
|
xfId: 0,
|
|
6463
|
-
builtinId: 0,
|
|
6464
6528
|
name: "Normal"
|
|
6465
6529
|
})), write_record(
|
|
6466
6530
|
e,
|
|
@@ -6950,12 +7014,15 @@ function parse_SerAr(e, r) {
|
|
|
6950
7014
|
case 2:
|
|
6951
7015
|
t[0] = 4;
|
|
6952
7016
|
break;
|
|
7017
|
+
/* SerBool */
|
|
6953
7018
|
case 4:
|
|
6954
7019
|
t[0] = 16;
|
|
6955
7020
|
break;
|
|
7021
|
+
/* SerErr */
|
|
6956
7022
|
case 0:
|
|
6957
7023
|
t[0] = 1;
|
|
6958
7024
|
break;
|
|
7025
|
+
/* SerNum */
|
|
6959
7026
|
case 1:
|
|
6960
7027
|
t[0] = 2;
|
|
6961
7028
|
break;
|
|
@@ -6965,6 +7032,7 @@ function parse_SerAr(e, r) {
|
|
|
6965
7032
|
t[1] = parsebool(e, 1) ? "TRUE" : "FALSE", r != 12 && (e.l += 7);
|
|
6966
7033
|
break;
|
|
6967
7034
|
case 37:
|
|
7035
|
+
/* appears to be an alias */
|
|
6968
7036
|
case 16:
|
|
6969
7037
|
t[1] = BErr[e[e.l]], e.l += r == 12 ? 4 : 8;
|
|
6970
7038
|
break;
|
|
@@ -7360,8 +7428,11 @@ function parse_RgbExtra(e, r, t, a) {
|
|
|
7360
7428
|
a && a.biff == 12 && (t[s][1][1] = e.read_shift(4), i.push(t[s][1]));
|
|
7361
7429
|
break;
|
|
7362
7430
|
case "PtgList":
|
|
7431
|
+
/* TODO: PtgList -> PtgExtraList */
|
|
7363
7432
|
case "PtgElfRadicalS":
|
|
7433
|
+
/* TODO: PtgElfRadicalS -> PtgExtraElf */
|
|
7364
7434
|
case "PtgElfColS":
|
|
7435
|
+
/* TODO: PtgElfColS -> PtgExtraElf */
|
|
7365
7436
|
case "PtgElfColSV":
|
|
7366
7437
|
throw "Unsupported " + t[s][0];
|
|
7367
7438
|
}
|
|
@@ -7377,6 +7448,7 @@ function stringify_array(e) {
|
|
|
7377
7448
|
for (var a = e[t], n = [], i = 0; i < a.length; ++i) {
|
|
7378
7449
|
var s = a[i];
|
|
7379
7450
|
if (s) switch (s[0]) {
|
|
7451
|
+
// TODO: handle embedded quotes
|
|
7380
7452
|
case 2:
|
|
7381
7453
|
n.push('"' + s[1].replace(/"/g, '""') + '"');
|
|
7382
7454
|
break;
|
|
@@ -7422,6 +7494,8 @@ function get_ixti_raw(e, r, t) {
|
|
|
7422
7494
|
case 358:
|
|
7423
7495
|
return t.SID != null ? e.SheetNames[t.SID] : "SH33TJSSAME" + e[a[0]][0];
|
|
7424
7496
|
case 355:
|
|
7497
|
+
/* 'BrtSupBookSrc' */
|
|
7498
|
+
/* falls through */
|
|
7425
7499
|
default:
|
|
7426
7500
|
return "SH33TJSSRC" + e[a[0]][0];
|
|
7427
7501
|
}
|
|
@@ -7432,6 +7506,7 @@ function get_ixti_raw(e, r, t) {
|
|
|
7432
7506
|
return e[a[0]].slice(1).map(function(i) {
|
|
7433
7507
|
return i.Name;
|
|
7434
7508
|
}).join(";;");
|
|
7509
|
+
//return "SH33TJSERR8";
|
|
7435
7510
|
default:
|
|
7436
7511
|
return e[a[0]][0][3] ? (n = a[1] == -1 ? "#REF" : e[a[0]][0][3][a[1]] || "SH33TJSERR4", a[1] == a[2] ? n : n + ":" + e[a[0]][0][3][a[2]]) : "SH33TJSERR2";
|
|
7437
7512
|
}
|
|
@@ -7443,7 +7518,7 @@ function get_ixti(e, r, t) {
|
|
|
7443
7518
|
function stringify_formula(e, r, t, a, n) {
|
|
7444
7519
|
var i = n && n.biff || 8, s = (
|
|
7445
7520
|
/*range != null ? range :*/
|
|
7446
|
-
{ s: { c: 0, r: 0 }
|
|
7521
|
+
{ s: { c: 0, r: 0 } }
|
|
7447
7522
|
), l = [], o, f, c, p = 0, h = 0, d, m = "";
|
|
7448
7523
|
if (!e[0] || !e[0][0]) return "";
|
|
7449
7524
|
for (var u = -1, _ = "", C = 0, I = e[0].length; C < I; ++C) {
|
|
@@ -7459,16 +7534,27 @@ function stringify_formula(e, r, t, a, n) {
|
|
|
7459
7534
|
l.push(l.pop() + "%");
|
|
7460
7535
|
break;
|
|
7461
7536
|
case "PtgAdd":
|
|
7537
|
+
/* [MS-XLS] 2.5.198.26 */
|
|
7462
7538
|
case "PtgConcat":
|
|
7539
|
+
/* [MS-XLS] 2.5.198.43 */
|
|
7463
7540
|
case "PtgDiv":
|
|
7541
|
+
/* [MS-XLS] 2.5.198.45 */
|
|
7464
7542
|
case "PtgEq":
|
|
7543
|
+
/* [MS-XLS] 2.5.198.56 */
|
|
7465
7544
|
case "PtgGe":
|
|
7545
|
+
/* [MS-XLS] 2.5.198.64 */
|
|
7466
7546
|
case "PtgGt":
|
|
7547
|
+
/* [MS-XLS] 2.5.198.65 */
|
|
7467
7548
|
case "PtgLe":
|
|
7549
|
+
/* [MS-XLS] 2.5.198.68 */
|
|
7468
7550
|
case "PtgLt":
|
|
7551
|
+
/* [MS-XLS] 2.5.198.69 */
|
|
7469
7552
|
case "PtgMul":
|
|
7553
|
+
/* [MS-XLS] 2.5.198.75 */
|
|
7470
7554
|
case "PtgNe":
|
|
7555
|
+
/* [MS-XLS] 2.5.198.78 */
|
|
7471
7556
|
case "PtgPower":
|
|
7557
|
+
/* [MS-XLS] 2.5.198.82 */
|
|
7472
7558
|
case "PtgSub":
|
|
7473
7559
|
if (o = l.pop(), f = l.pop(), u >= 0) {
|
|
7474
7560
|
switch (e[0][u][1][0]) {
|
|
@@ -7513,6 +7599,7 @@ function stringify_formula(e, r, t, a, n) {
|
|
|
7513
7599
|
F[1][1], c = shift_cell_xls(F[1][2], s, n), m = get_ixti(a, p, n), l.push(m + "!" + encode_cell_xls(c, i));
|
|
7514
7600
|
break;
|
|
7515
7601
|
case "PtgFunc":
|
|
7602
|
+
/* [MS-XLS] 2.5.198.62 */
|
|
7516
7603
|
case "PtgFuncVar":
|
|
7517
7604
|
var b = F[1][0], G = F[1][1];
|
|
7518
7605
|
b || (b = 0), b &= 127;
|
|
@@ -7556,6 +7643,7 @@ function stringify_formula(e, r, t, a, n) {
|
|
|
7556
7643
|
l.push("SUM(" + l.pop() + ")");
|
|
7557
7644
|
break;
|
|
7558
7645
|
case "PtgAttrBaxcel":
|
|
7646
|
+
/* [MS-XLS] 2.5.198.33 */
|
|
7559
7647
|
case "PtgAttrSemi":
|
|
7560
7648
|
break;
|
|
7561
7649
|
case "PtgName":
|
|
@@ -7586,15 +7674,19 @@ function stringify_formula(e, r, t, a, n) {
|
|
|
7586
7674
|
var H = "(", ae = ")";
|
|
7587
7675
|
if (u >= 0) {
|
|
7588
7676
|
switch (_ = "", e[0][u][1][0]) {
|
|
7677
|
+
// $FlowIgnore
|
|
7589
7678
|
case 2:
|
|
7590
7679
|
H = fill(" ", e[0][u][1][1]) + H;
|
|
7591
7680
|
break;
|
|
7681
|
+
// $FlowIgnore
|
|
7592
7682
|
case 3:
|
|
7593
7683
|
H = fill("\r", e[0][u][1][1]) + H;
|
|
7594
7684
|
break;
|
|
7685
|
+
// $FlowIgnore
|
|
7595
7686
|
case 4:
|
|
7596
7687
|
ae = fill(" ", e[0][u][1][1]) + ae;
|
|
7597
7688
|
break;
|
|
7689
|
+
// $FlowIgnore
|
|
7598
7690
|
case 5:
|
|
7599
7691
|
ae = fill("\r", e[0][u][1][1]) + ae;
|
|
7600
7692
|
break;
|
|
@@ -7641,6 +7733,7 @@ function stringify_formula(e, r, t, a, n) {
|
|
|
7641
7733
|
case "PtgMemArea":
|
|
7642
7734
|
break;
|
|
7643
7735
|
case "PtgAttrSpace":
|
|
7736
|
+
/* [MS-XLS] 2.5.198.38 */
|
|
7644
7737
|
case "PtgAttrSpaceSemi":
|
|
7645
7738
|
u = C;
|
|
7646
7739
|
break;
|
|
@@ -7671,14 +7764,23 @@ function stringify_formula(e, r, t, a, n) {
|
|
|
7671
7764
|
case "PtgMemNoMem":
|
|
7672
7765
|
break;
|
|
7673
7766
|
case "PtgElfCol":
|
|
7767
|
+
/* [MS-XLS] 2.5.198.46 */
|
|
7674
7768
|
case "PtgElfColS":
|
|
7769
|
+
/* [MS-XLS] 2.5.198.47 */
|
|
7675
7770
|
case "PtgElfColSV":
|
|
7771
|
+
/* [MS-XLS] 2.5.198.48 */
|
|
7676
7772
|
case "PtgElfColV":
|
|
7773
|
+
/* [MS-XLS] 2.5.198.49 */
|
|
7677
7774
|
case "PtgElfLel":
|
|
7775
|
+
/* [MS-XLS] 2.5.198.50 */
|
|
7678
7776
|
case "PtgElfRadical":
|
|
7777
|
+
/* [MS-XLS] 2.5.198.51 */
|
|
7679
7778
|
case "PtgElfRadicalLel":
|
|
7779
|
+
/* [MS-XLS] 2.5.198.52 */
|
|
7680
7780
|
case "PtgElfRadicalS":
|
|
7781
|
+
/* [MS-XLS] 2.5.198.53 */
|
|
7681
7782
|
case "PtgElfRw":
|
|
7783
|
+
/* [MS-XLS] 2.5.198.54 */
|
|
7682
7784
|
case "PtgElfRwV":
|
|
7683
7785
|
throw new Error("Unsupported ELFs");
|
|
7684
7786
|
case "PtgSxName":
|
|
@@ -7691,13 +7793,16 @@ function stringify_formula(e, r, t, a, n) {
|
|
|
7691
7793
|
F = e[0][u];
|
|
7692
7794
|
var he = !0;
|
|
7693
7795
|
switch (F[1][0]) {
|
|
7796
|
+
/* note: some bad XLSB files omit the PtgParen */
|
|
7694
7797
|
case 4:
|
|
7695
7798
|
he = !1;
|
|
7799
|
+
/* falls through */
|
|
7696
7800
|
case 0:
|
|
7697
7801
|
_ = fill(" ", F[1][1]);
|
|
7698
7802
|
break;
|
|
7699
7803
|
case 5:
|
|
7700
7804
|
he = !1;
|
|
7805
|
+
/* falls through */
|
|
7701
7806
|
case 1:
|
|
7702
7807
|
_ = fill("\r", F[1][1]);
|
|
7703
7808
|
break;
|
|
@@ -9390,6 +9495,7 @@ function write_ws_bin_cell(e, r, t, a, n, i, s) {
|
|
|
9390
9495
|
case "d":
|
|
9391
9496
|
r = dup(r), r.z = r.z || table_fmt[14], r.v = datenum(parseDate(r.v)), r.t = "n";
|
|
9392
9497
|
break;
|
|
9498
|
+
/* falls through */
|
|
9393
9499
|
case "n":
|
|
9394
9500
|
case "e":
|
|
9395
9501
|
l = "" + r.v;
|
|
@@ -9912,8 +10018,10 @@ function write_xlscfb(e, r) {
|
|
|
9912
10018
|
switch (t.bookType || "xls") {
|
|
9913
10019
|
case "xls":
|
|
9914
10020
|
t.bookType = "biff8";
|
|
10021
|
+
/* falls through */
|
|
9915
10022
|
case "xla":
|
|
9916
10023
|
t.bookType || (t.bookType = "xla");
|
|
10024
|
+
/* falls through */
|
|
9917
10025
|
case "biff8":
|
|
9918
10026
|
n = "/Workbook", t.biff = 8;
|
|
9919
10027
|
break;
|
|
@@ -14052,6 +14160,7 @@ function write_ws_biff2_cell(e, r, t, a) {
|
|
|
14052
14160
|
case "e":
|
|
14053
14161
|
write_biff_rec(e, 5, write_BIFF2BERR(t, a, r.v, r.t));
|
|
14054
14162
|
return;
|
|
14163
|
+
/* TODO: codepage, sst */
|
|
14055
14164
|
case "s":
|
|
14056
14165
|
case "str":
|
|
14057
14166
|
write_biff_rec(e, 4, write_BIFF2LABEL(t, a, (r.v || "").slice(0, 255)));
|
|
@@ -14082,10 +14191,7 @@ function write_biff2_buf(e, r) {
|
|
|
14082
14191
|
function write_FONTS_biff8(e, r, t) {
|
|
14083
14192
|
write_biff_rec(e, 49, write_Font({
|
|
14084
14193
|
sz: 12,
|
|
14085
|
-
|
|
14086
|
-
name: "Arial",
|
|
14087
|
-
family: 2,
|
|
14088
|
-
scheme: "minor"
|
|
14194
|
+
name: "Arial"
|
|
14089
14195
|
}, t));
|
|
14090
14196
|
}
|
|
14091
14197
|
function write_FMTS_biff8(e, r, t) {
|
|
@@ -14140,6 +14246,7 @@ function write_ws_biff8_cell(e, r, t, a, n) {
|
|
|
14140
14246
|
case "e":
|
|
14141
14247
|
write_biff_rec(e, 517, write_BoolErr(t, a, r.v, i, n, r.t));
|
|
14142
14248
|
break;
|
|
14249
|
+
/* TODO: codepage, sst */
|
|
14143
14250
|
case "s":
|
|
14144
14251
|
case "str":
|
|
14145
14252
|
if (n.bookSST) {
|
|
@@ -14422,6 +14529,7 @@ var write_styles_ods = /* @__PURE__ */ function() {
|
|
|
14422
14529
|
case "d":
|
|
14423
14530
|
F = G.w || parseDate(G.v).toISOString(), I["office:value-type"] = "date", I["office:date-value"] = parseDate(G.v).toISOString(), I["table:style-name"] = "ce1";
|
|
14424
14531
|
break;
|
|
14532
|
+
//case 'e':
|
|
14425
14533
|
default:
|
|
14426
14534
|
o.push(r);
|
|
14427
14535
|
continue;
|
|
@@ -15021,6 +15129,7 @@ function write_zip_xlsxb(e, r) {
|
|
|
15021
15129
|
var c = { "!id": {} }, p = e.Sheets[e.SheetNames[l - 1]], h = (p || {})["!type"] || "sheet";
|
|
15022
15130
|
switch (h) {
|
|
15023
15131
|
case "chart":
|
|
15132
|
+
/* falls through */
|
|
15024
15133
|
default:
|
|
15025
15134
|
s = "xl/worksheets/sheet" + l + "." + t, zip_add_file(i, s, write_ws(l - 1, s, r, e, c)), n.sheets.push(s), add_rels(r.wbrels, -1, "worksheets/sheet" + l + "." + t, RELS.WS[0]);
|
|
15026
15135
|
}
|
|
@@ -15050,6 +15159,7 @@ function write_zip_xlsx(e, r) {
|
|
|
15050
15159
|
var p = { "!id": {} }, h = e.Sheets[e.SheetNames[l - 1]], d = (h || {})["!type"] || "sheet";
|
|
15051
15160
|
switch (d) {
|
|
15052
15161
|
case "chart":
|
|
15162
|
+
/* falls through */
|
|
15053
15163
|
default:
|
|
15054
15164
|
s = "xl/worksheets/sheet" + l + "." + t, zip_add_file(i, s, write_ws_xml(l - 1, r, e, p)), n.sheets.push(s), add_rels(r.wbrels, -1, "worksheets/sheet" + l + "." + t, RELS.WS[0]);
|
|
15055
15165
|
}
|
|
@@ -15173,6 +15283,7 @@ function write_stxt_type(e, r) {
|
|
|
15173
15283
|
return e;
|
|
15174
15284
|
case "string":
|
|
15175
15285
|
return e;
|
|
15286
|
+
/* override in sheet_to_txt */
|
|
15176
15287
|
case "file":
|
|
15177
15288
|
return write_dl(r.file, e, "binary");
|
|
15178
15289
|
case "buffer":
|
|
@@ -15240,12 +15351,15 @@ function writeSync(e, r) {
|
|
|
15240
15351
|
return write_binary_type(WK_.book_to_wk3(e, t), t);
|
|
15241
15352
|
case "biff2":
|
|
15242
15353
|
t.biff || (t.biff = 2);
|
|
15354
|
+
/* falls through */
|
|
15243
15355
|
case "biff3":
|
|
15244
15356
|
t.biff || (t.biff = 3);
|
|
15357
|
+
/* falls through */
|
|
15245
15358
|
case "biff4":
|
|
15246
15359
|
return t.biff || (t.biff = 4), write_binary_type(write_biff_buf(e, t), t);
|
|
15247
15360
|
case "biff5":
|
|
15248
15361
|
t.biff || (t.biff = 5);
|
|
15362
|
+
/* falls through */
|
|
15249
15363
|
case "biff8":
|
|
15250
15364
|
case "xla":
|
|
15251
15365
|
case "xls":
|