@ims-view/server 1.2.1 → 1.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -7
- package/lib/excel/excel-export.worker.cjs +70 -0
- package/lib/excel/excel-parse.worker.cjs +70 -235
- package/lib/server/src/config/env.d.ts +0 -9
- package/lib/server/src/config/env.js +0 -3
- package/lib/server/src/config/env.js.map +1 -1
- package/lib/server/src/excel/excel-storage.service.js +11 -2
- package/lib/server/src/excel/excel-storage.service.js.map +1 -1
- package/lib/server/src/excel/excel.controller.js +1 -1
- package/lib/server/src/excel/excel.controller.js.map +1 -1
- package/lib/server/src/excel/excel.service.d.ts +3 -3
- package/lib/server/src/excel/excel.service.js +212 -66
- package/lib/server/src/excel/excel.service.js.map +1 -1
- package/lib/server/src/main.js +3 -0
- package/lib/server/src/main.js.map +1 -1
- package/lib/utils/src/excel/converter.d.ts +0 -1
- package/lib/utils/src/excel/converter.js +7 -12
- package/lib/utils/src/excel/converter.js.map +1 -1
- package/lib/utils/src/excel/exceljsChunked.d.ts +2 -75
- package/lib/utils/src/excel/exceljsChunked.js +13 -335
- package/lib/utils/src/excel/exceljsChunked.js.map +1 -1
- package/lib/utils/src/excel/exceljsDrawings.d.ts +2 -0
- package/lib/utils/src/excel/exceljsDrawings.js +8 -0
- package/lib/utils/src/excel/exceljsDrawings.js.map +1 -0
- package/lib/utils/src/excel/exceljsStyle.d.ts +2 -0
- package/lib/utils/src/excel/exceljsStyle.js +10 -0
- package/lib/utils/src/excel/exceljsStyle.js.map +1 -0
- package/lib/utils/src/excel/exportWorkerClient.d.ts +31 -0
- package/lib/utils/src/excel/exportWorkerClient.js +105 -0
- package/lib/utils/src/excel/exportWorkerClient.js.map +1 -0
- package/lib/utils/src/excel/index.d.ts +9 -3
- package/lib/utils/src/excel/index.js +20 -2
- package/lib/utils/src/excel/index.js.map +1 -1
- package/lib/utils/src/excel/luckyexcel.d.ts +10 -6
- package/lib/utils/src/excel/luckyexcel.js +110 -36
- package/lib/utils/src/excel/luckyexcel.js.map +1 -1
- package/lib/utils/src/excel/workbookChunked.js +4 -4
- package/lib/utils/src/excel/workbookChunked.js.map +1 -1
- package/package.json +4 -2
|
@@ -1,338 +1,16 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
exports
|
|
11
|
-
exports.
|
|
12
|
-
exports.
|
|
13
|
-
exports.
|
|
14
|
-
exports
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
if (input instanceof ArrayBuffer) {
|
|
20
|
-
return new Uint8Array(input);
|
|
21
|
-
}
|
|
22
|
-
return input;
|
|
23
|
-
};
|
|
24
|
-
const argbToRgb = (argb) => {
|
|
25
|
-
if (!argb || typeof argb !== 'string')
|
|
26
|
-
return undefined;
|
|
27
|
-
const hex = argb.replace(/^#/, '');
|
|
28
|
-
if (hex.length === 8)
|
|
29
|
-
return `#${hex.slice(2)}`;
|
|
30
|
-
if (hex.length === 6)
|
|
31
|
-
return `#${hex}`;
|
|
32
|
-
return undefined;
|
|
33
|
-
};
|
|
34
|
-
const excelColorToRgb = (color) => {
|
|
35
|
-
if (!color)
|
|
36
|
-
return undefined;
|
|
37
|
-
if (color.argb)
|
|
38
|
-
return argbToRgb(color.argb);
|
|
39
|
-
return undefined;
|
|
40
|
-
};
|
|
41
|
-
const cellFromExcelJs = (cell) => {
|
|
42
|
-
const value = cell.value;
|
|
43
|
-
if (value == null || value === '')
|
|
44
|
-
return null;
|
|
45
|
-
let mapped = null;
|
|
46
|
-
if (typeof value === 'object' && value !== null && 'formula' in value) {
|
|
47
|
-
const formula = String(value.formula || '').replace(/^=/, '');
|
|
48
|
-
const result = value.result;
|
|
49
|
-
mapped = {
|
|
50
|
-
f: `=${formula}`,
|
|
51
|
-
v: result,
|
|
52
|
-
t: typeof result === 'number'
|
|
53
|
-
? types_1.CellValueType.NUMBER
|
|
54
|
-
: typeof result === 'boolean'
|
|
55
|
-
? types_1.CellValueType.BOOLEAN
|
|
56
|
-
: types_1.CellValueType.STRING,
|
|
57
|
-
};
|
|
58
|
-
}
|
|
59
|
-
else if (typeof value === 'object' && value !== null && 'richText' in value) {
|
|
60
|
-
const text = (value.richText || [])
|
|
61
|
-
.map((part) => part.text || '')
|
|
62
|
-
.join('');
|
|
63
|
-
if (!text)
|
|
64
|
-
return null;
|
|
65
|
-
mapped = { v: text, t: types_1.CellValueType.STRING };
|
|
66
|
-
}
|
|
67
|
-
else if (typeof value === 'object' && value !== null && 'text' in value && 'hyperlink' in value) {
|
|
68
|
-
const text = String(value.text || '');
|
|
69
|
-
mapped = { v: text, t: types_1.CellValueType.STRING };
|
|
70
|
-
}
|
|
71
|
-
else if (typeof value === 'object' && value !== null && 'error' in value) {
|
|
72
|
-
mapped = { v: String(value.error), t: types_1.CellValueType.STRING };
|
|
73
|
-
}
|
|
74
|
-
else if (value instanceof Date) {
|
|
75
|
-
mapped = { v: value.toISOString(), t: types_1.CellValueType.STRING };
|
|
76
|
-
}
|
|
77
|
-
else if (typeof value === 'number') {
|
|
78
|
-
mapped = { v: value, t: types_1.CellValueType.NUMBER };
|
|
79
|
-
}
|
|
80
|
-
else if (typeof value === 'boolean') {
|
|
81
|
-
mapped = { v: value, t: types_1.CellValueType.BOOLEAN };
|
|
82
|
-
}
|
|
83
|
-
else {
|
|
84
|
-
const text = String(value);
|
|
85
|
-
if (!text)
|
|
86
|
-
return null;
|
|
87
|
-
mapped = { v: text, t: types_1.CellValueType.STRING };
|
|
88
|
-
}
|
|
89
|
-
if (!mapped)
|
|
90
|
-
return null;
|
|
91
|
-
const style = {};
|
|
92
|
-
const font = cell.font;
|
|
93
|
-
if (font) {
|
|
94
|
-
if (font.bold)
|
|
95
|
-
style.bl = 1;
|
|
96
|
-
if (font.italic)
|
|
97
|
-
style.it = 1;
|
|
98
|
-
if (font.size)
|
|
99
|
-
style.fs = font.size;
|
|
100
|
-
if (font.name)
|
|
101
|
-
style.ff = font.name;
|
|
102
|
-
const fc = excelColorToRgb(font.color);
|
|
103
|
-
if (fc)
|
|
104
|
-
style.cl = { rgb: fc };
|
|
105
|
-
}
|
|
106
|
-
const fill = cell.fill;
|
|
107
|
-
if (fill && fill.type === 'pattern' && fill.fgColor) {
|
|
108
|
-
const bg = excelColorToRgb(fill.fgColor);
|
|
109
|
-
if (bg)
|
|
110
|
-
style.bg = { rgb: bg };
|
|
111
|
-
}
|
|
112
|
-
if (cell.alignment) {
|
|
113
|
-
const ht = cell.alignment.horizontal === 'center'
|
|
114
|
-
? 2
|
|
115
|
-
: cell.alignment.horizontal === 'right'
|
|
116
|
-
? 3
|
|
117
|
-
: cell.alignment.horizontal === 'left'
|
|
118
|
-
? 1
|
|
119
|
-
: undefined;
|
|
120
|
-
const vt = cell.alignment.vertical === 'middle'
|
|
121
|
-
? 2
|
|
122
|
-
: cell.alignment.vertical === 'top'
|
|
123
|
-
? 1
|
|
124
|
-
: cell.alignment.vertical === 'bottom'
|
|
125
|
-
? 3
|
|
126
|
-
: undefined;
|
|
127
|
-
if (ht != null)
|
|
128
|
-
style.ht = ht;
|
|
129
|
-
if (vt != null)
|
|
130
|
-
style.vt = vt;
|
|
131
|
-
}
|
|
132
|
-
if (Object.keys(style).length) {
|
|
133
|
-
mapped.s = style;
|
|
134
|
-
}
|
|
135
|
-
return mapped;
|
|
136
|
-
};
|
|
137
|
-
const shouldUseChunkedImport = (sizeBytes, options) => {
|
|
138
|
-
const bytesThreshold = options?.bytesThreshold ?? exports.CHUNKED_FILE_BYTES;
|
|
139
|
-
const rowsThreshold = options?.rowsThreshold ?? exports.CHUNKED_ROW_THRESHOLD;
|
|
140
|
-
if (sizeBytes > bytesThreshold)
|
|
141
|
-
return true;
|
|
142
|
-
if (options?.estimatedRows != null && options.estimatedRows > rowsThreshold)
|
|
143
|
-
return true;
|
|
144
|
-
return false;
|
|
145
|
-
};
|
|
146
|
-
exports.shouldUseChunkedImport = shouldUseChunkedImport;
|
|
147
|
-
const skeletonWorkbookFromMeta = (meta) => {
|
|
148
|
-
const sheets = {};
|
|
149
|
-
meta.sheets.forEach((sheet) => {
|
|
150
|
-
sheets[sheet.id] = {
|
|
151
|
-
id: sheet.id,
|
|
152
|
-
name: sheet.name,
|
|
153
|
-
cellData: {},
|
|
154
|
-
mergeData: sheet.mergeData || [],
|
|
155
|
-
rowCount: Math.max(sheet.rowCount, 1),
|
|
156
|
-
columnCount: Math.max(sheet.columnCount, 1),
|
|
157
|
-
...(sheet.columnData ? { columnData: sheet.columnData } : {}),
|
|
158
|
-
...(sheet.rowData ? { rowData: sheet.rowData } : {}),
|
|
159
|
-
...(sheet.defaultColumnWidth != null
|
|
160
|
-
? { defaultColumnWidth: sheet.defaultColumnWidth }
|
|
161
|
-
: {}),
|
|
162
|
-
...(sheet.defaultRowHeight != null ? { defaultRowHeight: sheet.defaultRowHeight } : {}),
|
|
163
|
-
};
|
|
164
|
-
});
|
|
165
|
-
return {
|
|
166
|
-
id: meta.workbookId || `wb-chunked-${Date.now()}`,
|
|
167
|
-
name: meta.name,
|
|
168
|
-
appVersion: meta.appVersion || '0.25.1',
|
|
169
|
-
locale: meta.locale || 'zhCN',
|
|
170
|
-
sheetOrder: meta.sheetOrder,
|
|
171
|
-
sheets,
|
|
172
|
-
styles: meta.styles,
|
|
173
|
-
resources: meta.resources,
|
|
174
|
-
};
|
|
175
|
-
};
|
|
176
|
-
exports.skeletonWorkbookFromMeta = skeletonWorkbookFromMeta;
|
|
177
|
-
const collectMerges = (worksheet, maxRowExclusive) => {
|
|
178
|
-
const merges = [];
|
|
179
|
-
const raw = worksheet.model?.merges;
|
|
180
|
-
if (!Array.isArray(raw))
|
|
181
|
-
return merges;
|
|
182
|
-
raw.forEach((ref) => {
|
|
183
|
-
try {
|
|
184
|
-
const [start, end] = String(ref).split(':');
|
|
185
|
-
if (!start)
|
|
186
|
-
return;
|
|
187
|
-
const startCell = worksheet.getCell(start);
|
|
188
|
-
const endCell = worksheet.getCell(end || start);
|
|
189
|
-
const top = Number(startCell.row) - 1;
|
|
190
|
-
const left = Number(startCell.col) - 1;
|
|
191
|
-
const bottom = Number(endCell.row) - 1;
|
|
192
|
-
const right = Number(endCell.col) - 1;
|
|
193
|
-
if (top >= maxRowExclusive)
|
|
194
|
-
return;
|
|
195
|
-
merges.push({
|
|
196
|
-
startRow: top,
|
|
197
|
-
startColumn: left,
|
|
198
|
-
endRow: Math.min(bottom, maxRowExclusive - 1),
|
|
199
|
-
endColumn: right,
|
|
200
|
-
});
|
|
201
|
-
}
|
|
202
|
-
catch {
|
|
203
|
-
}
|
|
204
|
-
});
|
|
205
|
-
return merges;
|
|
206
|
-
};
|
|
207
|
-
const excelBufferToChunkedWorkbook = async (input, options = {}) => {
|
|
208
|
-
const fileName = options.fileName || 'workbook.xlsx';
|
|
209
|
-
const blockRowSize = Math.max(100, options.blockRowSize || exports.DEFAULT_BLOCK_ROW_SIZE);
|
|
210
|
-
const maxRows = options.maxRows === 0
|
|
211
|
-
? Number.POSITIVE_INFINITY
|
|
212
|
-
: options.maxRows ?? exports.DEFAULT_MAX_ROWS;
|
|
213
|
-
const bytes = (0, converter_1.ensureXlsxBytes)(toUint8Array(input), fileName);
|
|
214
|
-
options.onProgress?.({ percent: 5, parsedBlocks: 0, totalBlocks: 0, phase: 'load' });
|
|
215
|
-
const workbook = new exceljs_1.default.Workbook();
|
|
216
|
-
const loadInput = typeof Buffer !== 'undefined' ? Buffer.from(bytes.buffer, bytes.byteOffset, bytes.byteLength) : bytes;
|
|
217
|
-
await workbook.xlsx.load(loadInput);
|
|
218
|
-
options.onProgress?.({ percent: 20, parsedBlocks: 0, totalBlocks: 0, phase: 'convert' });
|
|
219
|
-
const sheetsMeta = [];
|
|
220
|
-
const sheetOrder = [];
|
|
221
|
-
const blocks = [];
|
|
222
|
-
let truncated = false;
|
|
223
|
-
let emittedBlocks = 0;
|
|
224
|
-
const sheetInfos = workbook.worksheets.map((worksheet, sheetIndex) => {
|
|
225
|
-
const id = `sheet-${sheetIndex}`;
|
|
226
|
-
const actualRowCount = worksheet.rowCount || 0;
|
|
227
|
-
const cappedRows = Math.min(actualRowCount, maxRows);
|
|
228
|
-
if (actualRowCount > maxRows)
|
|
229
|
-
truncated = true;
|
|
230
|
-
const blockCount = Math.max(1, Math.ceil(Math.max(cappedRows, 1) / blockRowSize));
|
|
231
|
-
return { worksheet, sheetIndex, id, cappedRows, blockCount, actualRowCount };
|
|
232
|
-
});
|
|
233
|
-
const totalBlocks = sheetInfos.reduce((sum, info) => sum + info.blockCount, 0) || 1;
|
|
234
|
-
for (const info of sheetInfos) {
|
|
235
|
-
const { worksheet, sheetIndex, id, cappedRows, blockCount } = info;
|
|
236
|
-
sheetOrder.push(id);
|
|
237
|
-
let maxCol = 0;
|
|
238
|
-
const columnData = {};
|
|
239
|
-
worksheet.columns?.forEach((col, idx) => {
|
|
240
|
-
if (!col)
|
|
241
|
-
return;
|
|
242
|
-
if (col.width != null || col.values?.length) {
|
|
243
|
-
maxCol = Math.max(maxCol, idx + 1);
|
|
244
|
-
}
|
|
245
|
-
if (col.width != null && Number.isFinite(col.width)) {
|
|
246
|
-
columnData[idx] = { w: Math.round(Number(col.width) * 8) };
|
|
247
|
-
}
|
|
248
|
-
});
|
|
249
|
-
const rowData = {};
|
|
250
|
-
if (cappedRows > 0) {
|
|
251
|
-
for (let excelRow = 1; excelRow <= cappedRows; excelRow += 1) {
|
|
252
|
-
const height = worksheet.getRow(excelRow).height;
|
|
253
|
-
if (height != null && Number.isFinite(height)) {
|
|
254
|
-
rowData[excelRow - 1] = { h: Math.round(Number(height) * (4 / 3)) };
|
|
255
|
-
}
|
|
256
|
-
}
|
|
257
|
-
}
|
|
258
|
-
const mergeData = collectMerges(worksheet, cappedRows);
|
|
259
|
-
for (let blockIndex = 0; blockIndex < blockCount; blockIndex += 1) {
|
|
260
|
-
const startRow = blockIndex * blockRowSize;
|
|
261
|
-
const endRow = Math.min(cappedRows, startRow + blockRowSize) - 1;
|
|
262
|
-
const cellData = {};
|
|
263
|
-
if (cappedRows > 0 && endRow >= startRow) {
|
|
264
|
-
for (let excelRow = startRow + 1; excelRow <= endRow + 1; excelRow += 1) {
|
|
265
|
-
const row = worksheet.getRow(excelRow);
|
|
266
|
-
row.eachCell({ includeEmpty: false }, (cell, colNumber) => {
|
|
267
|
-
const mapped = cellFromExcelJs(cell);
|
|
268
|
-
if (!mapped)
|
|
269
|
-
return;
|
|
270
|
-
const r = excelRow - 1;
|
|
271
|
-
const c = colNumber - 1;
|
|
272
|
-
if (!cellData[r])
|
|
273
|
-
cellData[r] = {};
|
|
274
|
-
cellData[r][c] = mapped;
|
|
275
|
-
});
|
|
276
|
-
}
|
|
277
|
-
for (const rowCells of Object.values(cellData)) {
|
|
278
|
-
for (const key of Object.keys(rowCells || {})) {
|
|
279
|
-
const col = Number(key);
|
|
280
|
-
if (Number.isFinite(col))
|
|
281
|
-
maxCol = Math.max(maxCol, col + 1);
|
|
282
|
-
}
|
|
283
|
-
}
|
|
284
|
-
}
|
|
285
|
-
const block = {
|
|
286
|
-
sheetId: id,
|
|
287
|
-
sheetIndex,
|
|
288
|
-
blockIndex,
|
|
289
|
-
startRow: Math.max(0, startRow),
|
|
290
|
-
endRow: Math.max(0, endRow),
|
|
291
|
-
cellData,
|
|
292
|
-
};
|
|
293
|
-
blocks.push(block);
|
|
294
|
-
emittedBlocks += 1;
|
|
295
|
-
await options.onBlock?.(block);
|
|
296
|
-
const percent = Math.min(95, 20 + Math.round((emittedBlocks / totalBlocks) * 75));
|
|
297
|
-
options.onProgress?.({
|
|
298
|
-
percent,
|
|
299
|
-
parsedBlocks: emittedBlocks,
|
|
300
|
-
totalBlocks,
|
|
301
|
-
phase: 'convert',
|
|
302
|
-
});
|
|
303
|
-
}
|
|
304
|
-
sheetsMeta.push({
|
|
305
|
-
id,
|
|
306
|
-
name: worksheet.name || `Sheet${sheetIndex + 1}`,
|
|
307
|
-
rowCount: Math.max(cappedRows, 1),
|
|
308
|
-
columnCount: Math.max(maxCol, 1),
|
|
309
|
-
blockCount,
|
|
310
|
-
mergeData: mergeData.length ? mergeData : undefined,
|
|
311
|
-
columnData: Object.keys(columnData).length ? columnData : undefined,
|
|
312
|
-
rowData: Object.keys(rowData).length ? rowData : undefined,
|
|
313
|
-
});
|
|
314
|
-
}
|
|
315
|
-
const meta = {
|
|
316
|
-
parseEngine: 'exceljs',
|
|
317
|
-
fileName,
|
|
318
|
-
name: fileName.replace(/\.xlsx$/i, '') || 'workbook',
|
|
319
|
-
sheetOrder,
|
|
320
|
-
sheets: sheetsMeta,
|
|
321
|
-
blockRowSize,
|
|
322
|
-
truncated: truncated || undefined,
|
|
323
|
-
maxRows: Number.isFinite(maxRows) ? maxRows : undefined,
|
|
324
|
-
};
|
|
325
|
-
options.onProgress?.({
|
|
326
|
-
percent: 100,
|
|
327
|
-
parsedBlocks: emittedBlocks,
|
|
328
|
-
totalBlocks,
|
|
329
|
-
phase: 'done',
|
|
330
|
-
});
|
|
331
|
-
return { meta, blocks };
|
|
332
|
-
};
|
|
333
|
-
exports.excelBufferToChunkedWorkbook = excelBufferToChunkedWorkbook;
|
|
334
|
-
const chunkedBlockFileName = (id, sheetIndex, blockIndex) => `${id}.block.${sheetIndex}.${blockIndex}.json`;
|
|
335
|
-
exports.chunkedBlockFileName = chunkedBlockFileName;
|
|
336
|
-
const chunkedMetaFileName = (id) => `${id}.meta.json`;
|
|
337
|
-
exports.chunkedMetaFileName = chunkedMetaFileName;
|
|
3
|
+
exports.skeletonWorkbookFromMeta = exports.shouldUseChunkedImport = exports.resolveWorksheetRowCount = exports.excelBufferToChunkedWorkbook = exports.chunkedMetaFileName = exports.chunkedBlockFileName = exports.DEFAULT_PARSE_TIMEOUT_MS = exports.DEFAULT_MAX_ROWS = exports.DEFAULT_BLOCK_ROW_SIZE = exports.CHUNKED_ROW_THRESHOLD = exports.CHUNKED_FILE_BYTES = void 0;
|
|
4
|
+
var univer_import_excel_1 = require("@ims-view/univer-import-excel");
|
|
5
|
+
Object.defineProperty(exports, "CHUNKED_FILE_BYTES", { enumerable: true, get: function () { return univer_import_excel_1.CHUNKED_FILE_BYTES; } });
|
|
6
|
+
Object.defineProperty(exports, "CHUNKED_ROW_THRESHOLD", { enumerable: true, get: function () { return univer_import_excel_1.CHUNKED_ROW_THRESHOLD; } });
|
|
7
|
+
Object.defineProperty(exports, "DEFAULT_BLOCK_ROW_SIZE", { enumerable: true, get: function () { return univer_import_excel_1.DEFAULT_BLOCK_ROW_SIZE; } });
|
|
8
|
+
Object.defineProperty(exports, "DEFAULT_MAX_ROWS", { enumerable: true, get: function () { return univer_import_excel_1.DEFAULT_MAX_ROWS; } });
|
|
9
|
+
Object.defineProperty(exports, "DEFAULT_PARSE_TIMEOUT_MS", { enumerable: true, get: function () { return univer_import_excel_1.DEFAULT_PARSE_TIMEOUT_MS; } });
|
|
10
|
+
Object.defineProperty(exports, "chunkedBlockFileName", { enumerable: true, get: function () { return univer_import_excel_1.chunkedBlockFileName; } });
|
|
11
|
+
Object.defineProperty(exports, "chunkedMetaFileName", { enumerable: true, get: function () { return univer_import_excel_1.chunkedMetaFileName; } });
|
|
12
|
+
Object.defineProperty(exports, "excelBufferToChunkedWorkbook", { enumerable: true, get: function () { return univer_import_excel_1.excelBufferToChunkedWorkbook; } });
|
|
13
|
+
Object.defineProperty(exports, "resolveWorksheetRowCount", { enumerable: true, get: function () { return univer_import_excel_1.resolveWorksheetRowCount; } });
|
|
14
|
+
Object.defineProperty(exports, "shouldUseChunkedImport", { enumerable: true, get: function () { return univer_import_excel_1.shouldUseChunkedImport; } });
|
|
15
|
+
Object.defineProperty(exports, "skeletonWorkbookFromMeta", { enumerable: true, get: function () { return univer_import_excel_1.skeletonWorkbookFromMeta; } });
|
|
338
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AC,GAAG,EAAE,UAAU,UAAU,IAAI,UAAU,OAAO,CAAC;AAJ/C,QAAA,oBAAoB,wBAI2B;AAErD,MAAM,mBAAmB,GAAG,CAAC,EAAU,EAAU,EAAE,CAAC,GAAG,EAAE,YAAY,CAAC;AAAhE,QAAA,mBAAmB,uBAA6C"}
|
|
1
|
+
{"version":3,"file":"exceljsChunked.js","sourceRoot":"","sources":["../../../../../utils/src/excel/exceljsChunked.ts"],"names":[],"mappings":";;;AACA,qEAYuC;AAXrC,yHAAA,kBAAkB,OAAA;AAClB,4HAAA,qBAAqB,OAAA;AACrB,6HAAA,sBAAsB,OAAA;AACtB,uHAAA,gBAAgB,OAAA;AAChB,+HAAA,wBAAwB,OAAA;AACxB,2HAAA,oBAAoB,OAAA;AACpB,0HAAA,mBAAmB,OAAA;AACnB,mIAAA,4BAA4B,OAAA;AAC5B,+HAAA,wBAAwB,OAAA;AACxB,6HAAA,sBAAsB,OAAA;AACtB,+HAAA,wBAAwB,OAAA"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.emuToPx = exports.collectWorksheetFreeze = exports.collectWorkbookDrawingResources = void 0;
|
|
4
|
+
var univer_import_excel_1 = require("@ims-view/univer-import-excel");
|
|
5
|
+
Object.defineProperty(exports, "collectWorkbookDrawingResources", { enumerable: true, get: function () { return univer_import_excel_1.collectWorkbookDrawingResources; } });
|
|
6
|
+
Object.defineProperty(exports, "collectWorksheetFreeze", { enumerable: true, get: function () { return univer_import_excel_1.collectWorksheetFreeze; } });
|
|
7
|
+
Object.defineProperty(exports, "emuToPx", { enumerable: true, get: function () { return univer_import_excel_1.emuToPx; } });
|
|
8
|
+
//# sourceMappingURL=exceljsDrawings.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"exceljsDrawings.js","sourceRoot":"","sources":["../../../../../utils/src/excel/exceljsDrawings.ts"],"names":[],"mappings":";;;AACA,qEAIuC;AAHrC,sIAAA,+BAA+B,OAAA;AAC/B,6HAAA,sBAAsB,OAAA;AACtB,8GAAA,OAAO,OAAA"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.excelStyleToUniver = exports.excelColorToRgb = exports.argbToRgb = exports.StyleInterner = exports.BorderStyleTypes = void 0;
|
|
4
|
+
var univer_import_excel_1 = require("@ims-view/univer-import-excel");
|
|
5
|
+
Object.defineProperty(exports, "BorderStyleTypes", { enumerable: true, get: function () { return univer_import_excel_1.BorderStyleTypes; } });
|
|
6
|
+
Object.defineProperty(exports, "StyleInterner", { enumerable: true, get: function () { return univer_import_excel_1.StyleInterner; } });
|
|
7
|
+
Object.defineProperty(exports, "argbToRgb", { enumerable: true, get: function () { return univer_import_excel_1.argbToRgb; } });
|
|
8
|
+
Object.defineProperty(exports, "excelColorToRgb", { enumerable: true, get: function () { return univer_import_excel_1.excelColorToRgb; } });
|
|
9
|
+
Object.defineProperty(exports, "excelStyleToUniver", { enumerable: true, get: function () { return univer_import_excel_1.excelStyleToUniver; } });
|
|
10
|
+
//# sourceMappingURL=exceljsStyle.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"exceljsStyle.js","sourceRoot":"","sources":["../../../../../utils/src/excel/exceljsStyle.ts"],"names":[],"mappings":";;;AACA,qEAMuC;AALrC,uHAAA,gBAAgB,OAAA;AAChB,oHAAA,aAAa,OAAA;AACb,gHAAA,SAAS,OAAA;AACT,sHAAA,eAAe,OAAA;AACf,yHAAA,kBAAkB,OAAA"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { IWorkbookData } from './types';
|
|
2
|
+
export type ExcelExportWorkerMode = 'off' | 'auto' | 'on';
|
|
3
|
+
export declare const DEFAULT_EXPORT_WORKER_THRESHOLD_BYTES: number;
|
|
4
|
+
export type ExcelExportOptions = {
|
|
5
|
+
fileName?: string;
|
|
6
|
+
worker?: ExcelExportWorkerMode;
|
|
7
|
+
workerThresholdBytes?: number;
|
|
8
|
+
createWorker?: () => Worker;
|
|
9
|
+
};
|
|
10
|
+
export type ExcelExportWorkerInMessage = {
|
|
11
|
+
type: 'export';
|
|
12
|
+
snapshot: Partial<IWorkbookData>;
|
|
13
|
+
fileName: string;
|
|
14
|
+
};
|
|
15
|
+
export type ExcelExportWorkerOutMessage = {
|
|
16
|
+
type: 'done';
|
|
17
|
+
buffer: ArrayBuffer;
|
|
18
|
+
} | {
|
|
19
|
+
type: 'error';
|
|
20
|
+
error: string;
|
|
21
|
+
};
|
|
22
|
+
export declare const estimateWorkbookSnapshotBytes: (data: Partial<IWorkbookData>) => number;
|
|
23
|
+
export declare const resolveShouldUseExportWorker: (sizeBytes: number, options?: Pick<ExcelExportOptions, "worker" | "workerThresholdBytes" | "createWorker">) => boolean;
|
|
24
|
+
export declare const workbookDataToExcelArrayBuffer: (data: Partial<IWorkbookData>, fileName?: string) => Promise<ArrayBuffer>;
|
|
25
|
+
export declare const installExcelExportWorker: (scope?: {
|
|
26
|
+
postMessage: (msg: ExcelExportWorkerOutMessage, transfer?: Transferable[]) => void;
|
|
27
|
+
addEventListener: (type: "message", listener: (event: MessageEvent) => void) => void;
|
|
28
|
+
}) => void;
|
|
29
|
+
export declare const runExcelExportInBrowserWorker: (snapshot: Partial<IWorkbookData>, options: ExcelExportOptions & {
|
|
30
|
+
createWorker: () => Worker;
|
|
31
|
+
}) => Promise<ArrayBuffer>;
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.runExcelExportInBrowserWorker = exports.installExcelExportWorker = exports.workbookDataToExcelArrayBuffer = exports.resolveShouldUseExportWorker = exports.estimateWorkbookSnapshotBytes = exports.DEFAULT_EXPORT_WORKER_THRESHOLD_BYTES = void 0;
|
|
4
|
+
const luckyexcel_1 = require("./luckyexcel");
|
|
5
|
+
exports.DEFAULT_EXPORT_WORKER_THRESHOLD_BYTES = 512 * 1024;
|
|
6
|
+
const estimateWorkbookSnapshotBytes = (data) => {
|
|
7
|
+
try {
|
|
8
|
+
return JSON.stringify(data).length;
|
|
9
|
+
}
|
|
10
|
+
catch {
|
|
11
|
+
return Number.MAX_SAFE_INTEGER;
|
|
12
|
+
}
|
|
13
|
+
};
|
|
14
|
+
exports.estimateWorkbookSnapshotBytes = estimateWorkbookSnapshotBytes;
|
|
15
|
+
const resolveShouldUseExportWorker = (sizeBytes, options = {}) => {
|
|
16
|
+
const mode = options.worker || 'auto';
|
|
17
|
+
if (mode === 'off')
|
|
18
|
+
return false;
|
|
19
|
+
if (!options.createWorker)
|
|
20
|
+
return false;
|
|
21
|
+
if (mode === 'on')
|
|
22
|
+
return true;
|
|
23
|
+
const threshold = options.workerThresholdBytes ?? exports.DEFAULT_EXPORT_WORKER_THRESHOLD_BYTES;
|
|
24
|
+
return sizeBytes > threshold;
|
|
25
|
+
};
|
|
26
|
+
exports.resolveShouldUseExportWorker = resolveShouldUseExportWorker;
|
|
27
|
+
const workbookDataToExcelArrayBuffer = async (data, fileName = 'workbook.xlsx') => {
|
|
28
|
+
const name = fileName.endsWith('.xlsx') ? fileName : `${fileName}.xlsx`;
|
|
29
|
+
const buffer = await (0, luckyexcel_1.transformUniverToExcelBuffer)(data, name);
|
|
30
|
+
if (buffer instanceof ArrayBuffer)
|
|
31
|
+
return buffer;
|
|
32
|
+
const view = typeof Buffer !== 'undefined' && Buffer.isBuffer(buffer)
|
|
33
|
+
? new Uint8Array(buffer.buffer, buffer.byteOffset, buffer.byteLength)
|
|
34
|
+
: buffer instanceof Uint8Array
|
|
35
|
+
? buffer
|
|
36
|
+
: null;
|
|
37
|
+
if (!view) {
|
|
38
|
+
throw new Error('LuckyExcel 导出结果类型未知');
|
|
39
|
+
}
|
|
40
|
+
const copy = new Uint8Array(view.byteLength);
|
|
41
|
+
copy.set(view);
|
|
42
|
+
return copy.buffer;
|
|
43
|
+
};
|
|
44
|
+
exports.workbookDataToExcelArrayBuffer = workbookDataToExcelArrayBuffer;
|
|
45
|
+
const installExcelExportWorker = (scope = self) => {
|
|
46
|
+
scope.addEventListener('message', (event) => {
|
|
47
|
+
const data = event.data;
|
|
48
|
+
if (!data || data.type !== 'export')
|
|
49
|
+
return;
|
|
50
|
+
(async () => {
|
|
51
|
+
const buffer = await (0, exports.workbookDataToExcelArrayBuffer)(data.snapshot, data.fileName);
|
|
52
|
+
const transferable = buffer.slice(0);
|
|
53
|
+
scope.postMessage({ type: 'done', buffer: transferable }, [transferable]);
|
|
54
|
+
})().catch((error) => {
|
|
55
|
+
scope.postMessage({
|
|
56
|
+
type: 'error',
|
|
57
|
+
error: error instanceof Error ? error.message : String(error),
|
|
58
|
+
});
|
|
59
|
+
});
|
|
60
|
+
});
|
|
61
|
+
};
|
|
62
|
+
exports.installExcelExportWorker = installExcelExportWorker;
|
|
63
|
+
const runExcelExportInBrowserWorker = (snapshot, options) => new Promise((resolve, reject) => {
|
|
64
|
+
let worker;
|
|
65
|
+
try {
|
|
66
|
+
worker = options.createWorker();
|
|
67
|
+
}
|
|
68
|
+
catch (error) {
|
|
69
|
+
reject(error instanceof Error ? error : new Error(String(error)));
|
|
70
|
+
return;
|
|
71
|
+
}
|
|
72
|
+
const cleanup = () => {
|
|
73
|
+
try {
|
|
74
|
+
worker.terminate();
|
|
75
|
+
}
|
|
76
|
+
catch {
|
|
77
|
+
}
|
|
78
|
+
};
|
|
79
|
+
worker.onmessage = (event) => {
|
|
80
|
+
const msg = event.data;
|
|
81
|
+
if (!msg)
|
|
82
|
+
return;
|
|
83
|
+
if (msg.type === 'error') {
|
|
84
|
+
cleanup();
|
|
85
|
+
reject(new Error(msg.error));
|
|
86
|
+
return;
|
|
87
|
+
}
|
|
88
|
+
if (msg.type === 'done') {
|
|
89
|
+
cleanup();
|
|
90
|
+
resolve(msg.buffer);
|
|
91
|
+
}
|
|
92
|
+
};
|
|
93
|
+
worker.onerror = (event) => {
|
|
94
|
+
cleanup();
|
|
95
|
+
reject(new Error(event.message || 'Excel export worker failed'));
|
|
96
|
+
};
|
|
97
|
+
const message = {
|
|
98
|
+
type: 'export',
|
|
99
|
+
snapshot,
|
|
100
|
+
fileName: options.fileName || 'workbook.xlsx',
|
|
101
|
+
};
|
|
102
|
+
worker.postMessage(message);
|
|
103
|
+
});
|
|
104
|
+
exports.runExcelExportInBrowserWorker = runExcelExportInBrowserWorker;
|
|
105
|
+
//# sourceMappingURL=exportWorkerClient.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"exportWorkerClient.js","sourceRoot":"","sources":["../../../../../utils/src/excel/exportWorkerClient.ts"],"names":[],"mappings":";;;AAKA,6CAA4D;AAK/C,QAAA,qCAAqC,GAAG,GAAG,GAAG,IAAI,CAAC;AAmBzD,MAAM,6BAA6B,GAAG,CAAC,IAA4B,EAAU,EAAE;IACpF,IAAI,CAAC;QACH,OAAO,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,MAAM,CAAC;IACrC,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,MAAM,CAAC,gBAAgB,CAAC;IACjC,CAAC;AACH,CAAC,CAAC;AANW,QAAA,6BAA6B,iCAMxC;AAEK,MAAM,4BAA4B,GAAG,CAC1C,SAAiB,EACjB,UAAwF,EAAE,EACjF,EAAE;IACX,MAAM,IAAI,GAAG,OAAO,CAAC,MAAM,IAAI,MAAM,CAAC;IACtC,IAAI,IAAI,KAAK,KAAK;QAAE,OAAO,KAAK,CAAC;IACjC,IAAI,CAAC,OAAO,CAAC,YAAY;QAAE,OAAO,KAAK,CAAC;IACxC,IAAI,IAAI,KAAK,IAAI;QAAE,OAAO,IAAI,CAAC;IAC/B,MAAM,SAAS,GAAG,OAAO,CAAC,oBAAoB,IAAI,6CAAqC,CAAC;IACxF,OAAO,SAAS,GAAG,SAAS,CAAC;AAC/B,CAAC,CAAC;AAVW,QAAA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AAS,GAAG,CAAC,KAAgD,EAAE,EAAE;QACtE,MAAM,GAAG,GAAG,KAAK,CAAC,IAAI,CAAC;QACvB,IAAI,CAAC,GAAG;YAAE,OAAO;QACjB,IAAI,GAAG,CAAC,IAAI,KAAK,OAAO,EAAE,CAAC;YACzB,OAAO,EAAE,CAAC;YACV,MAAM,CAAC,IAAI,KAAK,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC;YAC7B,OAAO;QACT,CAAC;QACD,IAAI,GAAG,CAAC,IAAI,KAAK,MAAM,EAAE,CAAC;YACxB,OAAO,EAAE,CAAC;YACV,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;QACtB,CAAC;IACH,CAAC,CAAC;IAEF,MAAM,CAAC,OAAO,GAAG,CAAC,KAAK,EAAE,EAAE;QACzB,OAAO,EAAE,CAAC;QACV,MAAM,CAAC,IAAI,KAAK,CAAC,KAAK,CAAC,OAAO,IAAI,4BAA4B,CAAC,CAAC,CAAC;IACnE,CAAC,CAAC;IAEF,MAAM,OAAO,GAA+B;QAC1C,IAAI,EAAE,QAAQ;QACd,QAAQ;QACR,QAAQ,EAAE,OAAO,CAAC,QAAQ,IAAI,eAAe;KAC9C,CAAC;IACF,MAAM,CAAC,WAAW,CAAC,OAAO,CAAC,CAAC;AAC9B,CAAC,CAAC,CAAC;AA9CQ,QAAA,6BAA6B,iCA8CrC"}
|
|
@@ -1,9 +1,15 @@
|
|
|
1
1
|
export type { ExcelBinary, ExcelImportResult, ExcelSheetImage, ICellData, IRange, IWorkbookData, IWorksheetData, } from './types';
|
|
2
2
|
export { CellValueType } from './types';
|
|
3
|
-
export { assertSupportedExcelSource, ensureXlsxBytes, excelBufferToImportResult, excelBufferToWorkbookData, isLegacyExcelSource,
|
|
3
|
+
export { assertSupportedExcelSource, ensureXlsxBytes, excelBufferToImportResult, excelBufferToWorkbookData, isLegacyExcelSource, workbookDataToExcelBytes, } from './converter';
|
|
4
4
|
export { excelBufferToWorkbookDataBySheetJs, readExcelWithSheetJs, workbookFromSheetJs, workbookHasCellValues, } from './sheetjsConverter';
|
|
5
|
-
export { CHUNKED_FILE_BYTES, CHUNKED_ROW_THRESHOLD, DEFAULT_BLOCK_ROW_SIZE, DEFAULT_MAX_ROWS, DEFAULT_PARSE_TIMEOUT_MS, chunkedBlockFileName, chunkedMetaFileName, excelBufferToChunkedWorkbook, shouldUseChunkedImport, skeletonWorkbookFromMeta, } from './exceljsChunked';
|
|
5
|
+
export { CHUNKED_FILE_BYTES, CHUNKED_ROW_THRESHOLD, DEFAULT_BLOCK_ROW_SIZE, DEFAULT_MAX_ROWS, DEFAULT_PARSE_TIMEOUT_MS, chunkedBlockFileName, chunkedMetaFileName, excelBufferToChunkedWorkbook, resolveWorksheetRowCount, shouldUseChunkedImport, skeletonWorkbookFromMeta, } from './exceljsChunked';
|
|
6
6
|
export type { ChunkedBlock, ChunkedConvertOptions, ChunkedProgress, ChunkedSheetMeta, ChunkedWorkbookMeta, } from './exceljsChunked';
|
|
7
|
+
export { BorderStyleTypes, StyleInterner, argbToRgb, excelColorToRgb, excelStyleToUniver, } from './exceljsStyle';
|
|
8
|
+
export type { UniverStyleData } from './exceljsStyle';
|
|
9
|
+
export { collectWorkbookDrawingResources, collectWorksheetFreeze, emuToPx, } from './exceljsDrawings';
|
|
10
|
+
export type { SheetFreeze } from './exceljsDrawings';
|
|
7
11
|
export { splitWorkbookDataToChunks } from './workbookChunked';
|
|
8
12
|
export type { SplitWorkbookOptions } from './workbookChunked';
|
|
9
|
-
export { fileToImportResult, importExcelBinary, transformExcelToUniver, transformUniverToExcelBuffer, workbookDataToExcelBlob, workbookHasDrawingResources, } from './luckyexcel';
|
|
13
|
+
export { fileToImportResult, importExcelBinary, transformExcelToUniver, transformUniverToExcelBuffer, workbookDataToExcelBlob, workbookDataToExcelBuffer, workbookHasDrawingResources, } from './luckyexcel';
|
|
14
|
+
export type { ExcelExportOptions, ExcelExportWorkerMode } from './exportWorkerClient';
|
|
15
|
+
export { DEFAULT_EXPORT_WORKER_THRESHOLD_BYTES, estimateWorkbookSnapshotBytes, installExcelExportWorker, resolveShouldUseExportWorker, runExcelExportInBrowserWorker, workbookDataToExcelArrayBuffer, } from './exportWorkerClient';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.workbookHasDrawingResources = exports.workbookDataToExcelBlob = exports.transformUniverToExcelBuffer = exports.transformExcelToUniver = exports.importExcelBinary = exports.fileToImportResult = exports.splitWorkbookDataToChunks = exports.skeletonWorkbookFromMeta = exports.shouldUseChunkedImport = exports.excelBufferToChunkedWorkbook = exports.chunkedMetaFileName = exports.chunkedBlockFileName = exports.DEFAULT_PARSE_TIMEOUT_MS = exports.DEFAULT_MAX_ROWS = exports.DEFAULT_BLOCK_ROW_SIZE = exports.CHUNKED_ROW_THRESHOLD = exports.CHUNKED_FILE_BYTES = exports.workbookHasCellValues = exports.workbookFromSheetJs = exports.readExcelWithSheetJs = exports.excelBufferToWorkbookDataBySheetJs = exports.workbookDataToExcelBytes = exports.
|
|
3
|
+
exports.workbookDataToExcelArrayBuffer = exports.runExcelExportInBrowserWorker = exports.resolveShouldUseExportWorker = exports.installExcelExportWorker = exports.estimateWorkbookSnapshotBytes = exports.DEFAULT_EXPORT_WORKER_THRESHOLD_BYTES = exports.workbookHasDrawingResources = exports.workbookDataToExcelBuffer = exports.workbookDataToExcelBlob = exports.transformUniverToExcelBuffer = exports.transformExcelToUniver = exports.importExcelBinary = exports.fileToImportResult = exports.splitWorkbookDataToChunks = exports.emuToPx = exports.collectWorksheetFreeze = exports.collectWorkbookDrawingResources = exports.excelStyleToUniver = exports.excelColorToRgb = exports.argbToRgb = exports.StyleInterner = exports.BorderStyleTypes = exports.skeletonWorkbookFromMeta = exports.shouldUseChunkedImport = exports.resolveWorksheetRowCount = exports.excelBufferToChunkedWorkbook = exports.chunkedMetaFileName = exports.chunkedBlockFileName = exports.DEFAULT_PARSE_TIMEOUT_MS = exports.DEFAULT_MAX_ROWS = exports.DEFAULT_BLOCK_ROW_SIZE = exports.CHUNKED_ROW_THRESHOLD = exports.CHUNKED_FILE_BYTES = exports.workbookHasCellValues = exports.workbookFromSheetJs = exports.readExcelWithSheetJs = exports.excelBufferToWorkbookDataBySheetJs = exports.workbookDataToExcelBytes = exports.isLegacyExcelSource = exports.excelBufferToWorkbookData = exports.excelBufferToImportResult = exports.ensureXlsxBytes = exports.assertSupportedExcelSource = exports.CellValueType = void 0;
|
|
4
4
|
var types_1 = require("./types");
|
|
5
5
|
Object.defineProperty(exports, "CellValueType", { enumerable: true, get: function () { return types_1.CellValueType; } });
|
|
6
6
|
var converter_1 = require("./converter");
|
|
@@ -9,7 +9,6 @@ Object.defineProperty(exports, "ensureXlsxBytes", { enumerable: true, get: funct
|
|
|
9
9
|
Object.defineProperty(exports, "excelBufferToImportResult", { enumerable: true, get: function () { return converter_1.excelBufferToImportResult; } });
|
|
10
10
|
Object.defineProperty(exports, "excelBufferToWorkbookData", { enumerable: true, get: function () { return converter_1.excelBufferToWorkbookData; } });
|
|
11
11
|
Object.defineProperty(exports, "isLegacyExcelSource", { enumerable: true, get: function () { return converter_1.isLegacyExcelSource; } });
|
|
12
|
-
Object.defineProperty(exports, "workbookDataToExcelBuffer", { enumerable: true, get: function () { return converter_1.workbookDataToExcelBuffer; } });
|
|
13
12
|
Object.defineProperty(exports, "workbookDataToExcelBytes", { enumerable: true, get: function () { return converter_1.workbookDataToExcelBytes; } });
|
|
14
13
|
var sheetjsConverter_1 = require("./sheetjsConverter");
|
|
15
14
|
Object.defineProperty(exports, "excelBufferToWorkbookDataBySheetJs", { enumerable: true, get: function () { return sheetjsConverter_1.excelBufferToWorkbookDataBySheetJs; } });
|
|
@@ -25,8 +24,19 @@ Object.defineProperty(exports, "DEFAULT_PARSE_TIMEOUT_MS", { enumerable: true, g
|
|
|
25
24
|
Object.defineProperty(exports, "chunkedBlockFileName", { enumerable: true, get: function () { return exceljsChunked_1.chunkedBlockFileName; } });
|
|
26
25
|
Object.defineProperty(exports, "chunkedMetaFileName", { enumerable: true, get: function () { return exceljsChunked_1.chunkedMetaFileName; } });
|
|
27
26
|
Object.defineProperty(exports, "excelBufferToChunkedWorkbook", { enumerable: true, get: function () { return exceljsChunked_1.excelBufferToChunkedWorkbook; } });
|
|
27
|
+
Object.defineProperty(exports, "resolveWorksheetRowCount", { enumerable: true, get: function () { return exceljsChunked_1.resolveWorksheetRowCount; } });
|
|
28
28
|
Object.defineProperty(exports, "shouldUseChunkedImport", { enumerable: true, get: function () { return exceljsChunked_1.shouldUseChunkedImport; } });
|
|
29
29
|
Object.defineProperty(exports, "skeletonWorkbookFromMeta", { enumerable: true, get: function () { return exceljsChunked_1.skeletonWorkbookFromMeta; } });
|
|
30
|
+
var exceljsStyle_1 = require("./exceljsStyle");
|
|
31
|
+
Object.defineProperty(exports, "BorderStyleTypes", { enumerable: true, get: function () { return exceljsStyle_1.BorderStyleTypes; } });
|
|
32
|
+
Object.defineProperty(exports, "StyleInterner", { enumerable: true, get: function () { return exceljsStyle_1.StyleInterner; } });
|
|
33
|
+
Object.defineProperty(exports, "argbToRgb", { enumerable: true, get: function () { return exceljsStyle_1.argbToRgb; } });
|
|
34
|
+
Object.defineProperty(exports, "excelColorToRgb", { enumerable: true, get: function () { return exceljsStyle_1.excelColorToRgb; } });
|
|
35
|
+
Object.defineProperty(exports, "excelStyleToUniver", { enumerable: true, get: function () { return exceljsStyle_1.excelStyleToUniver; } });
|
|
36
|
+
var exceljsDrawings_1 = require("./exceljsDrawings");
|
|
37
|
+
Object.defineProperty(exports, "collectWorkbookDrawingResources", { enumerable: true, get: function () { return exceljsDrawings_1.collectWorkbookDrawingResources; } });
|
|
38
|
+
Object.defineProperty(exports, "collectWorksheetFreeze", { enumerable: true, get: function () { return exceljsDrawings_1.collectWorksheetFreeze; } });
|
|
39
|
+
Object.defineProperty(exports, "emuToPx", { enumerable: true, get: function () { return exceljsDrawings_1.emuToPx; } });
|
|
30
40
|
var workbookChunked_1 = require("./workbookChunked");
|
|
31
41
|
Object.defineProperty(exports, "splitWorkbookDataToChunks", { enumerable: true, get: function () { return workbookChunked_1.splitWorkbookDataToChunks; } });
|
|
32
42
|
var luckyexcel_1 = require("./luckyexcel");
|
|
@@ -35,5 +45,13 @@ Object.defineProperty(exports, "importExcelBinary", { enumerable: true, get: fun
|
|
|
35
45
|
Object.defineProperty(exports, "transformExcelToUniver", { enumerable: true, get: function () { return luckyexcel_1.transformExcelToUniver; } });
|
|
36
46
|
Object.defineProperty(exports, "transformUniverToExcelBuffer", { enumerable: true, get: function () { return luckyexcel_1.transformUniverToExcelBuffer; } });
|
|
37
47
|
Object.defineProperty(exports, "workbookDataToExcelBlob", { enumerable: true, get: function () { return luckyexcel_1.workbookDataToExcelBlob; } });
|
|
48
|
+
Object.defineProperty(exports, "workbookDataToExcelBuffer", { enumerable: true, get: function () { return luckyexcel_1.workbookDataToExcelBuffer; } });
|
|
38
49
|
Object.defineProperty(exports, "workbookHasDrawingResources", { enumerable: true, get: function () { return luckyexcel_1.workbookHasDrawingResources; } });
|
|
50
|
+
var exportWorkerClient_1 = require("./exportWorkerClient");
|
|
51
|
+
Object.defineProperty(exports, "DEFAULT_EXPORT_WORKER_THRESHOLD_BYTES", { enumerable: true, get: function () { return exportWorkerClient_1.DEFAULT_EXPORT_WORKER_THRESHOLD_BYTES; } });
|
|
52
|
+
Object.defineProperty(exports, "estimateWorkbookSnapshotBytes", { enumerable: true, get: function () { return exportWorkerClient_1.estimateWorkbookSnapshotBytes; } });
|
|
53
|
+
Object.defineProperty(exports, "installExcelExportWorker", { enumerable: true, get: function () { return exportWorkerClient_1.installExcelExportWorker; } });
|
|
54
|
+
Object.defineProperty(exports, "resolveShouldUseExportWorker", { enumerable: true, get: function () { return exportWorkerClient_1.resolveShouldUseExportWorker; } });
|
|
55
|
+
Object.defineProperty(exports, "runExcelExportInBrowserWorker", { enumerable: true, get: function () { return exportWorkerClient_1.runExcelExportInBrowserWorker; } });
|
|
56
|
+
Object.defineProperty(exports, "workbookDataToExcelArrayBuffer", { enumerable: true, get: function () { return exportWorkerClient_1.workbookDataToExcelArrayBuffer; } });
|
|
39
57
|
//# sourceMappingURL=index.js.map
|