@senlinz/import-export-wasm 0.1.0-beta.8 → 0.1.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.
@@ -1,855 +1,1891 @@
1
- let wasm;
1
+ /* @ts-self-types="./imexport_wasm.d.ts" */
2
2
 
3
- const heap = new Array(128).fill(undefined);
4
-
5
- heap.push(undefined, null, true, false);
6
-
7
- function getObject(idx) { return heap[idx]; }
8
-
9
- let heap_next = heap.length;
10
-
11
- function dropObject(idx) {
12
- if (idx < 132) return;
13
- heap[idx] = heap_next;
14
- heap_next = idx;
15
- }
16
-
17
- function takeObject(idx) {
18
- const ret = getObject(idx);
19
- dropObject(idx);
20
- return ret;
21
- }
22
-
23
- const cachedTextDecoder = (typeof TextDecoder !== 'undefined' ? new TextDecoder('utf-8', { ignoreBOM: true, fatal: true }) : { decode: () => { throw Error('TextDecoder not available') } } );
24
-
25
- if (typeof TextDecoder !== 'undefined') { cachedTextDecoder.decode(); };
26
-
27
- let cachedUint8ArrayMemory0 = null;
28
-
29
- function getUint8ArrayMemory0() {
30
- if (cachedUint8ArrayMemory0 === null || cachedUint8ArrayMemory0.byteLength === 0) {
31
- cachedUint8ArrayMemory0 = new Uint8Array(wasm.memory.buffer);
3
+ export class ExcelCellFormat {
4
+ static __wrap(ptr) {
5
+ ptr = ptr >>> 0;
6
+ const obj = Object.create(ExcelCellFormat.prototype);
7
+ obj.__wbg_ptr = ptr;
8
+ ExcelCellFormatFinalization.register(obj, obj.__wbg_ptr, obj);
9
+ return obj;
10
+ }
11
+ static __unwrap(jsValue) {
12
+ if (!(jsValue instanceof ExcelCellFormat)) {
13
+ return 0;
14
+ }
15
+ return jsValue.__destroy_into_raw();
16
+ }
17
+ __destroy_into_raw() {
18
+ const ptr = this.__wbg_ptr;
19
+ this.__wbg_ptr = 0;
20
+ ExcelCellFormatFinalization.unregister(this);
21
+ return ptr;
22
+ }
23
+ free() {
24
+ const ptr = this.__destroy_into_raw();
25
+ wasm.__wbg_excelcellformat_free(ptr, 0);
26
+ }
27
+ constructor() {
28
+ const ret = wasm.excelcellformat_new();
29
+ this.__wbg_ptr = ret >>> 0;
30
+ ExcelCellFormatFinalization.register(this, this.__wbg_ptr, this);
31
+ return this;
32
+ }
33
+ /**
34
+ * @param {string} align
35
+ * @returns {ExcelCellFormat}
36
+ */
37
+ withAlign(align) {
38
+ const ptr = this.__destroy_into_raw();
39
+ const ptr0 = passStringToWasm0(align, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
40
+ const len0 = WASM_VECTOR_LEN;
41
+ const ret = wasm.excelcellformat_withAlign(ptr, ptr0, len0);
42
+ return ExcelCellFormat.__wrap(ret);
43
+ }
44
+ /**
45
+ * @param {string} align_vertical
46
+ * @returns {ExcelCellFormat}
47
+ */
48
+ withAlignVertical(align_vertical) {
49
+ const ptr = this.__destroy_into_raw();
50
+ const ptr0 = passStringToWasm0(align_vertical, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
51
+ const len0 = WASM_VECTOR_LEN;
52
+ const ret = wasm.excelcellformat_withAlignVertical(ptr, ptr0, len0);
53
+ return ExcelCellFormat.__wrap(ret);
54
+ }
55
+ /**
56
+ * @param {string} background_color
57
+ * @returns {ExcelCellFormat}
58
+ */
59
+ withBackgroundColor(background_color) {
60
+ const ptr = this.__destroy_into_raw();
61
+ const ptr0 = passStringToWasm0(background_color, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
62
+ const len0 = WASM_VECTOR_LEN;
63
+ const ret = wasm.excelcellformat_withBackgroundColor(ptr, ptr0, len0);
64
+ return ExcelCellFormat.__wrap(ret);
65
+ }
66
+ /**
67
+ * @param {boolean} bold
68
+ * @returns {ExcelCellFormat}
69
+ */
70
+ withBold(bold) {
71
+ const ptr = this.__destroy_into_raw();
72
+ const ret = wasm.excelcellformat_withBold(ptr, bold);
73
+ return ExcelCellFormat.__wrap(ret);
74
+ }
75
+ /**
76
+ * @param {string} border_color
77
+ * @returns {ExcelCellFormat}
78
+ */
79
+ withBorderColor(border_color) {
80
+ const ptr = this.__destroy_into_raw();
81
+ const ptr0 = passStringToWasm0(border_color, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
82
+ const len0 = WASM_VECTOR_LEN;
83
+ const ret = wasm.excelcellformat_withBorderColor(ptr, ptr0, len0);
84
+ return ExcelCellFormat.__wrap(ret);
85
+ }
86
+ /**
87
+ * @param {string} color
88
+ * @returns {ExcelCellFormat}
89
+ */
90
+ withColor(color) {
91
+ const ptr = this.__destroy_into_raw();
92
+ const ptr0 = passStringToWasm0(color, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
93
+ const len0 = WASM_VECTOR_LEN;
94
+ const ret = wasm.excelcellformat_withColor(ptr, ptr0, len0);
95
+ return ExcelCellFormat.__wrap(ret);
96
+ }
97
+ /**
98
+ * @param {string} date_format
99
+ * @returns {ExcelCellFormat}
100
+ */
101
+ withDateFormat(date_format) {
102
+ const ptr = this.__destroy_into_raw();
103
+ const ptr0 = passStringToWasm0(date_format, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
104
+ const len0 = WASM_VECTOR_LEN;
105
+ const ret = wasm.excelcellformat_withDateFormat(ptr, ptr0, len0);
106
+ return ExcelCellFormat.__wrap(ret);
107
+ }
108
+ /**
109
+ * @param {number} font_size
110
+ * @returns {ExcelCellFormat}
111
+ */
112
+ withFontSize(font_size) {
113
+ const ptr = this.__destroy_into_raw();
114
+ const ret = wasm.excelcellformat_withFontSize(ptr, font_size);
115
+ return ExcelCellFormat.__wrap(ret);
116
+ }
117
+ /**
118
+ * @param {boolean} italic
119
+ * @returns {ExcelCellFormat}
120
+ */
121
+ withItalic(italic) {
122
+ const ptr = this.__destroy_into_raw();
123
+ const ret = wasm.excelcellformat_withItalic(ptr, italic);
124
+ return ExcelCellFormat.__wrap(ret);
125
+ }
126
+ /**
127
+ * @param {string} rule
128
+ * @returns {ExcelCellFormat}
129
+ */
130
+ withRule(rule) {
131
+ const ptr = this.__destroy_into_raw();
132
+ const ptr0 = passStringToWasm0(rule, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
133
+ const len0 = WASM_VECTOR_LEN;
134
+ const ret = wasm.excelcellformat_withRule(ptr, ptr0, len0);
135
+ return ExcelCellFormat.__wrap(ret);
136
+ }
137
+ /**
138
+ * @param {boolean} strikethrough
139
+ * @returns {ExcelCellFormat}
140
+ */
141
+ withStrikethrough(strikethrough) {
142
+ const ptr = this.__destroy_into_raw();
143
+ const ret = wasm.excelcellformat_withStrikethrough(ptr, strikethrough);
144
+ return ExcelCellFormat.__wrap(ret);
145
+ }
146
+ /**
147
+ * @param {boolean} underline
148
+ * @returns {ExcelCellFormat}
149
+ */
150
+ withUnderline(underline) {
151
+ const ptr = this.__destroy_into_raw();
152
+ const ret = wasm.excelcellformat_withUnderline(ptr, underline);
153
+ return ExcelCellFormat.__wrap(ret);
154
+ }
155
+ /**
156
+ * @param {string} value
157
+ * @returns {ExcelCellFormat}
158
+ */
159
+ withValue(value) {
160
+ const ptr = this.__destroy_into_raw();
161
+ const ptr0 = passStringToWasm0(value, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
162
+ const len0 = WASM_VECTOR_LEN;
163
+ const ret = wasm.excelcellformat_withValue(ptr, ptr0, len0);
164
+ return ExcelCellFormat.__wrap(ret);
165
+ }
166
+ /**
167
+ * @returns {string}
168
+ */
169
+ get align_vertical() {
170
+ let deferred1_0;
171
+ let deferred1_1;
172
+ try {
173
+ const ret = wasm.__wbg_get_excelcellformat_align_vertical(this.__wbg_ptr);
174
+ deferred1_0 = ret[0];
175
+ deferred1_1 = ret[1];
176
+ return getStringFromWasm0(ret[0], ret[1]);
177
+ } finally {
178
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
179
+ }
180
+ }
181
+ /**
182
+ * @returns {string}
183
+ */
184
+ get align() {
185
+ let deferred1_0;
186
+ let deferred1_1;
187
+ try {
188
+ const ret = wasm.__wbg_get_excelcellformat_align(this.__wbg_ptr);
189
+ deferred1_0 = ret[0];
190
+ deferred1_1 = ret[1];
191
+ return getStringFromWasm0(ret[0], ret[1]);
192
+ } finally {
193
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
194
+ }
195
+ }
196
+ /**
197
+ * @returns {string}
198
+ */
199
+ get background_color() {
200
+ let deferred1_0;
201
+ let deferred1_1;
202
+ try {
203
+ const ret = wasm.__wbg_get_excelcellformat_background_color(this.__wbg_ptr);
204
+ deferred1_0 = ret[0];
205
+ deferred1_1 = ret[1];
206
+ return getStringFromWasm0(ret[0], ret[1]);
207
+ } finally {
208
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
209
+ }
210
+ }
211
+ /**
212
+ * @returns {boolean}
213
+ */
214
+ get bold() {
215
+ const ret = wasm.__wbg_get_excelcellformat_bold(this.__wbg_ptr);
216
+ return ret !== 0;
217
+ }
218
+ /**
219
+ * @returns {string | undefined}
220
+ */
221
+ get border_color() {
222
+ const ret = wasm.__wbg_get_excelcellformat_border_color(this.__wbg_ptr);
223
+ let v1;
224
+ if (ret[0] !== 0) {
225
+ v1 = getStringFromWasm0(ret[0], ret[1]).slice();
226
+ wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
227
+ }
228
+ return v1;
229
+ }
230
+ /**
231
+ * @returns {string}
232
+ */
233
+ get color() {
234
+ let deferred1_0;
235
+ let deferred1_1;
236
+ try {
237
+ const ret = wasm.__wbg_get_excelcellformat_color(this.__wbg_ptr);
238
+ deferred1_0 = ret[0];
239
+ deferred1_1 = ret[1];
240
+ return getStringFromWasm0(ret[0], ret[1]);
241
+ } finally {
242
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
243
+ }
244
+ }
245
+ /**
246
+ * @returns {string | undefined}
247
+ */
248
+ get date_format() {
249
+ const ret = wasm.__wbg_get_excelcellformat_date_format(this.__wbg_ptr);
250
+ let v1;
251
+ if (ret[0] !== 0) {
252
+ v1 = getStringFromWasm0(ret[0], ret[1]).slice();
253
+ wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
254
+ }
255
+ return v1;
256
+ }
257
+ /**
258
+ * @returns {number}
259
+ */
260
+ get font_size() {
261
+ const ret = wasm.__wbg_get_excelcellformat_font_size(this.__wbg_ptr);
262
+ return ret;
263
+ }
264
+ /**
265
+ * @returns {boolean}
266
+ */
267
+ get italic() {
268
+ const ret = wasm.__wbg_get_excelcellformat_italic(this.__wbg_ptr);
269
+ return ret !== 0;
270
+ }
271
+ /**
272
+ * @returns {string}
273
+ */
274
+ get rule() {
275
+ let deferred1_0;
276
+ let deferred1_1;
277
+ try {
278
+ const ret = wasm.__wbg_get_excelcellformat_rule(this.__wbg_ptr);
279
+ deferred1_0 = ret[0];
280
+ deferred1_1 = ret[1];
281
+ return getStringFromWasm0(ret[0], ret[1]);
282
+ } finally {
283
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
284
+ }
285
+ }
286
+ /**
287
+ * @returns {boolean}
288
+ */
289
+ get strikethrough() {
290
+ const ret = wasm.__wbg_get_excelcellformat_strikethrough(this.__wbg_ptr);
291
+ return ret !== 0;
292
+ }
293
+ /**
294
+ * @returns {boolean}
295
+ */
296
+ get underline() {
297
+ const ret = wasm.__wbg_get_excelcellformat_underline(this.__wbg_ptr);
298
+ return ret !== 0;
299
+ }
300
+ /**
301
+ * @returns {string}
302
+ */
303
+ get value() {
304
+ let deferred1_0;
305
+ let deferred1_1;
306
+ try {
307
+ const ret = wasm.__wbg_get_excelcellformat_value(this.__wbg_ptr);
308
+ deferred1_0 = ret[0];
309
+ deferred1_1 = ret[1];
310
+ return getStringFromWasm0(ret[0], ret[1]);
311
+ } finally {
312
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
313
+ }
314
+ }
315
+ /**
316
+ * @param {string} arg0
317
+ */
318
+ set align_vertical(arg0) {
319
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
320
+ const len0 = WASM_VECTOR_LEN;
321
+ wasm.__wbg_set_excelcellformat_align_vertical(this.__wbg_ptr, ptr0, len0);
322
+ }
323
+ /**
324
+ * @param {string} arg0
325
+ */
326
+ set align(arg0) {
327
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
328
+ const len0 = WASM_VECTOR_LEN;
329
+ wasm.__wbg_set_excelcellformat_align(this.__wbg_ptr, ptr0, len0);
330
+ }
331
+ /**
332
+ * @param {string} arg0
333
+ */
334
+ set background_color(arg0) {
335
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
336
+ const len0 = WASM_VECTOR_LEN;
337
+ wasm.__wbg_set_excelcellformat_background_color(this.__wbg_ptr, ptr0, len0);
338
+ }
339
+ /**
340
+ * @param {boolean} arg0
341
+ */
342
+ set bold(arg0) {
343
+ wasm.__wbg_set_excelcellformat_bold(this.__wbg_ptr, arg0);
344
+ }
345
+ /**
346
+ * @param {string | null} [arg0]
347
+ */
348
+ set border_color(arg0) {
349
+ var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
350
+ var len0 = WASM_VECTOR_LEN;
351
+ wasm.__wbg_set_excelcellformat_border_color(this.__wbg_ptr, ptr0, len0);
352
+ }
353
+ /**
354
+ * @param {string} arg0
355
+ */
356
+ set color(arg0) {
357
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
358
+ const len0 = WASM_VECTOR_LEN;
359
+ wasm.__wbg_set_excelcellformat_color(this.__wbg_ptr, ptr0, len0);
360
+ }
361
+ /**
362
+ * @param {string | null} [arg0]
363
+ */
364
+ set date_format(arg0) {
365
+ var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
366
+ var len0 = WASM_VECTOR_LEN;
367
+ wasm.__wbg_set_excelcellformat_date_format(this.__wbg_ptr, ptr0, len0);
368
+ }
369
+ /**
370
+ * @param {number} arg0
371
+ */
372
+ set font_size(arg0) {
373
+ wasm.__wbg_set_excelcellformat_font_size(this.__wbg_ptr, arg0);
374
+ }
375
+ /**
376
+ * @param {boolean} arg0
377
+ */
378
+ set italic(arg0) {
379
+ wasm.__wbg_set_excelcellformat_italic(this.__wbg_ptr, arg0);
380
+ }
381
+ /**
382
+ * @param {string} arg0
383
+ */
384
+ set rule(arg0) {
385
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
386
+ const len0 = WASM_VECTOR_LEN;
387
+ wasm.__wbg_set_excelcellformat_rule(this.__wbg_ptr, ptr0, len0);
388
+ }
389
+ /**
390
+ * @param {boolean} arg0
391
+ */
392
+ set strikethrough(arg0) {
393
+ wasm.__wbg_set_excelcellformat_strikethrough(this.__wbg_ptr, arg0);
394
+ }
395
+ /**
396
+ * @param {boolean} arg0
397
+ */
398
+ set underline(arg0) {
399
+ wasm.__wbg_set_excelcellformat_underline(this.__wbg_ptr, arg0);
400
+ }
401
+ /**
402
+ * @param {string} arg0
403
+ */
404
+ set value(arg0) {
405
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
406
+ const len0 = WASM_VECTOR_LEN;
407
+ wasm.__wbg_set_excelcellformat_value(this.__wbg_ptr, ptr0, len0);
32
408
  }
33
- return cachedUint8ArrayMemory0;
34
- }
35
-
36
- function getStringFromWasm0(ptr, len) {
37
- ptr = ptr >>> 0;
38
- return cachedTextDecoder.decode(getUint8ArrayMemory0().subarray(ptr, ptr + len));
39
- }
40
-
41
- function addHeapObject(obj) {
42
- if (heap_next === heap.length) heap.push(heap.length + 1);
43
- const idx = heap_next;
44
- heap_next = heap[idx];
45
-
46
- heap[idx] = obj;
47
- return idx;
48
409
  }
410
+ if (Symbol.dispose) ExcelCellFormat.prototype[Symbol.dispose] = ExcelCellFormat.prototype.free;
49
411
 
50
- let WASM_VECTOR_LEN = 0;
51
-
52
- const cachedTextEncoder = (typeof TextEncoder !== 'undefined' ? new TextEncoder('utf-8') : { encode: () => { throw Error('TextEncoder not available') } } );
53
-
54
- const encodeString = (typeof cachedTextEncoder.encodeInto === 'function'
55
- ? function (arg, view) {
56
- return cachedTextEncoder.encodeInto(arg, view);
412
+ export class ExcelColumnData {
413
+ static __wrap(ptr) {
414
+ ptr = ptr >>> 0;
415
+ const obj = Object.create(ExcelColumnData.prototype);
416
+ obj.__wbg_ptr = ptr;
417
+ ExcelColumnDataFinalization.register(obj, obj.__wbg_ptr, obj);
418
+ return obj;
419
+ }
420
+ static __unwrap(jsValue) {
421
+ if (!(jsValue instanceof ExcelColumnData)) {
422
+ return 0;
423
+ }
424
+ return jsValue.__destroy_into_raw();
425
+ }
426
+ __destroy_into_raw() {
427
+ const ptr = this.__wbg_ptr;
428
+ this.__wbg_ptr = 0;
429
+ ExcelColumnDataFinalization.unregister(this);
430
+ return ptr;
431
+ }
432
+ free() {
433
+ const ptr = this.__destroy_into_raw();
434
+ wasm.__wbg_excelcolumndata_free(ptr, 0);
435
+ }
436
+ /**
437
+ * @param {string} key
438
+ * @param {string} value
439
+ */
440
+ constructor(key, value) {
441
+ const ptr0 = passStringToWasm0(key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
442
+ const len0 = WASM_VECTOR_LEN;
443
+ const ptr1 = passStringToWasm0(value, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
444
+ const len1 = WASM_VECTOR_LEN;
445
+ const ret = wasm.excelcolumndata_bind_new(ptr0, len0, ptr1, len1);
446
+ this.__wbg_ptr = ret >>> 0;
447
+ ExcelColumnDataFinalization.register(this, this.__wbg_ptr, this);
448
+ return this;
449
+ }
450
+ /**
451
+ * @param {string} group_name
452
+ * @param {string} value
453
+ * @param {ExcelRowData[]} children
454
+ * @returns {ExcelColumnData}
455
+ */
456
+ static newGroup(group_name, value, children) {
457
+ const ptr0 = passStringToWasm0(group_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
458
+ const len0 = WASM_VECTOR_LEN;
459
+ const ptr1 = passStringToWasm0(value, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
460
+ const len1 = WASM_VECTOR_LEN;
461
+ const ptr2 = passArrayJsValueToWasm0(children, wasm.__wbindgen_malloc);
462
+ const len2 = WASM_VECTOR_LEN;
463
+ const ret = wasm.excelcolumndata_newGroup(ptr0, len0, ptr1, len1, ptr2, len2);
464
+ return ExcelColumnData.__wrap(ret);
465
+ }
466
+ /**
467
+ * @param {string} group_name
468
+ * @param {ExcelRowData[]} children
469
+ * @returns {ExcelColumnData}
470
+ */
471
+ static newRootGroup(group_name, children) {
472
+ const ptr0 = passStringToWasm0(group_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
473
+ const len0 = WASM_VECTOR_LEN;
474
+ const ptr1 = passArrayJsValueToWasm0(children, wasm.__wbindgen_malloc);
475
+ const len1 = WASM_VECTOR_LEN;
476
+ const ret = wasm.excelcolumndata_newRootGroup(ptr0, len0, ptr1, len1);
477
+ return ExcelColumnData.__wrap(ret);
478
+ }
479
+ /**
480
+ * @param {ExcelRowData[]} children
481
+ * @returns {ExcelColumnData}
482
+ */
483
+ withChildren(children) {
484
+ const ptr = this.__destroy_into_raw();
485
+ const ptr0 = passArrayJsValueToWasm0(children, wasm.__wbindgen_malloc);
486
+ const len0 = WASM_VECTOR_LEN;
487
+ const ret = wasm.excelcolumndata_withChildren(ptr, ptr0, len0);
488
+ return ExcelColumnData.__wrap(ret);
489
+ }
490
+ /**
491
+ * @returns {ExcelRowData[]}
492
+ */
493
+ get children() {
494
+ const ret = wasm.__wbg_get_excelcolumndata_children(this.__wbg_ptr);
495
+ var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
496
+ wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
497
+ return v1;
498
+ }
499
+ /**
500
+ * @returns {string}
501
+ */
502
+ get key() {
503
+ let deferred1_0;
504
+ let deferred1_1;
505
+ try {
506
+ const ret = wasm.__wbg_get_excelcolumndata_key(this.__wbg_ptr);
507
+ deferred1_0 = ret[0];
508
+ deferred1_1 = ret[1];
509
+ return getStringFromWasm0(ret[0], ret[1]);
510
+ } finally {
511
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
512
+ }
513
+ }
514
+ /**
515
+ * @returns {string}
516
+ */
517
+ get value() {
518
+ let deferred1_0;
519
+ let deferred1_1;
520
+ try {
521
+ const ret = wasm.__wbg_get_excelcolumndata_value(this.__wbg_ptr);
522
+ deferred1_0 = ret[0];
523
+ deferred1_1 = ret[1];
524
+ return getStringFromWasm0(ret[0], ret[1]);
525
+ } finally {
526
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
527
+ }
528
+ }
529
+ /**
530
+ * @param {ExcelRowData[]} arg0
531
+ */
532
+ set children(arg0) {
533
+ const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
534
+ const len0 = WASM_VECTOR_LEN;
535
+ wasm.__wbg_set_excelcolumndata_children(this.__wbg_ptr, ptr0, len0);
536
+ }
537
+ /**
538
+ * @param {string} arg0
539
+ */
540
+ set key(arg0) {
541
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
542
+ const len0 = WASM_VECTOR_LEN;
543
+ wasm.__wbg_set_excelcolumndata_key(this.__wbg_ptr, ptr0, len0);
544
+ }
545
+ /**
546
+ * @param {string} arg0
547
+ */
548
+ set value(arg0) {
549
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
550
+ const len0 = WASM_VECTOR_LEN;
551
+ wasm.__wbg_set_excelcolumndata_value(this.__wbg_ptr, ptr0, len0);
552
+ }
57
553
  }
58
- : function (arg, view) {
59
- const buf = cachedTextEncoder.encode(arg);
60
- view.set(buf);
61
- return {
62
- read: arg.length,
63
- written: buf.length
64
- };
65
- });
554
+ if (Symbol.dispose) ExcelColumnData.prototype[Symbol.dispose] = ExcelColumnData.prototype.free;
66
555
 
67
- function passStringToWasm0(arg, malloc, realloc) {
68
-
69
- if (realloc === undefined) {
70
- const buf = cachedTextEncoder.encode(arg);
71
- const ptr = malloc(buf.length, 1) >>> 0;
72
- getUint8ArrayMemory0().subarray(ptr, ptr + buf.length).set(buf);
73
- WASM_VECTOR_LEN = buf.length;
556
+ export class ExcelColumnInfo {
557
+ static __wrap(ptr) {
558
+ ptr = ptr >>> 0;
559
+ const obj = Object.create(ExcelColumnInfo.prototype);
560
+ obj.__wbg_ptr = ptr;
561
+ ExcelColumnInfoFinalization.register(obj, obj.__wbg_ptr, obj);
562
+ return obj;
563
+ }
564
+ static __unwrap(jsValue) {
565
+ if (!(jsValue instanceof ExcelColumnInfo)) {
566
+ return 0;
567
+ }
568
+ return jsValue.__destroy_into_raw();
569
+ }
570
+ __destroy_into_raw() {
571
+ const ptr = this.__wbg_ptr;
572
+ this.__wbg_ptr = 0;
573
+ ExcelColumnInfoFinalization.unregister(this);
74
574
  return ptr;
75
575
  }
76
-
77
- let len = arg.length;
78
- let ptr = malloc(len, 1) >>> 0;
79
-
80
- const mem = getUint8ArrayMemory0();
81
-
82
- let offset = 0;
83
-
84
- for (; offset < len; offset++) {
85
- const code = arg.charCodeAt(offset);
86
- if (code > 0x7F) break;
87
- mem[ptr + offset] = code;
576
+ free() {
577
+ const ptr = this.__destroy_into_raw();
578
+ wasm.__wbg_excelcolumninfo_free(ptr, 0);
88
579
  }
89
-
90
- if (offset !== len) {
91
- if (offset !== 0) {
92
- arg = arg.slice(offset);
580
+ /**
581
+ * @param {string} key
582
+ * @param {string} name
583
+ */
584
+ constructor(key, name) {
585
+ const ptr0 = passStringToWasm0(key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
586
+ const len0 = WASM_VECTOR_LEN;
587
+ const ptr1 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
588
+ const len1 = WASM_VECTOR_LEN;
589
+ const ret = wasm.excelcolumninfo_bind_new(ptr0, len0, ptr1, len1);
590
+ this.__wbg_ptr = ret >>> 0;
591
+ ExcelColumnInfoFinalization.register(this, this.__wbg_ptr, this);
592
+ return this;
593
+ }
594
+ /**
595
+ * @param {string[]} allowed_values
596
+ * @returns {ExcelColumnInfo}
597
+ */
598
+ withAllowedValues(allowed_values) {
599
+ const ptr = this.__destroy_into_raw();
600
+ const ptr0 = passArrayJsValueToWasm0(allowed_values, wasm.__wbindgen_malloc);
601
+ const len0 = WASM_VECTOR_LEN;
602
+ const ret = wasm.excelcolumninfo_withAllowedValues(ptr, ptr0, len0);
603
+ return ExcelColumnInfo.__wrap(ret);
604
+ }
605
+ /**
606
+ * @param {string} group
607
+ * @returns {ExcelColumnInfo}
608
+ */
609
+ withDataGroup(group) {
610
+ const ptr = this.__destroy_into_raw();
611
+ const ptr0 = passStringToWasm0(group, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
612
+ const len0 = WASM_VECTOR_LEN;
613
+ const ret = wasm.excelcolumninfo_withDataGroup(ptr, ptr0, len0);
614
+ return ExcelColumnInfo.__wrap(ret);
615
+ }
616
+ /**
617
+ * @param {string} group_parent
618
+ * @returns {ExcelColumnInfo}
619
+ */
620
+ withDataGroupParent(group_parent) {
621
+ const ptr = this.__destroy_into_raw();
622
+ const ptr0 = passStringToWasm0(group_parent, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
623
+ const len0 = WASM_VECTOR_LEN;
624
+ const ret = wasm.excelcolumninfo_withDataGroupParent(ptr, ptr0, len0);
625
+ return ExcelColumnInfo.__wrap(ret);
626
+ }
627
+ /**
628
+ * @param {string} data_type
629
+ * @returns {ExcelColumnInfo}
630
+ */
631
+ withDataType(data_type) {
632
+ const ptr = this.__destroy_into_raw();
633
+ const ptr0 = passStringToWasm0(data_type, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
634
+ const len0 = WASM_VECTOR_LEN;
635
+ const ret = wasm.excelcolumninfo_withDataType(ptr, ptr0, len0);
636
+ return ExcelColumnInfo.__wrap(ret);
637
+ }
638
+ /**
639
+ * @param {ExcelCellFormat} format
640
+ * @returns {ExcelColumnInfo}
641
+ */
642
+ withFormat(format) {
643
+ const ptr = this.__destroy_into_raw();
644
+ _assertClass(format, ExcelCellFormat);
645
+ var ptr0 = format.__destroy_into_raw();
646
+ const ret = wasm.excelcolumninfo_withFormat(ptr, ptr0);
647
+ return ExcelColumnInfo.__wrap(ret);
648
+ }
649
+ /**
650
+ * @param {string} note
651
+ * @returns {ExcelColumnInfo}
652
+ */
653
+ withNote(note) {
654
+ const ptr = this.__destroy_into_raw();
655
+ const ptr0 = passStringToWasm0(note, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
656
+ const len0 = WASM_VECTOR_LEN;
657
+ const ret = wasm.excelcolumninfo_withNote(ptr, ptr0, len0);
658
+ return ExcelColumnInfo.__wrap(ret);
659
+ }
660
+ /**
661
+ * @param {string} parent
662
+ * @returns {ExcelColumnInfo}
663
+ */
664
+ withParent(parent) {
665
+ const ptr = this.__destroy_into_raw();
666
+ const ptr0 = passStringToWasm0(parent, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
667
+ const len0 = WASM_VECTOR_LEN;
668
+ const ret = wasm.excelcolumninfo_withParent(ptr, ptr0, len0);
669
+ return ExcelColumnInfo.__wrap(ret);
670
+ }
671
+ /**
672
+ * @param {ExcelCellFormat[]} value_format
673
+ * @returns {ExcelColumnInfo}
674
+ */
675
+ withValueFormat(value_format) {
676
+ const ptr = this.__destroy_into_raw();
677
+ const ptr0 = passArrayJsValueToWasm0(value_format, wasm.__wbindgen_malloc);
678
+ const len0 = WASM_VECTOR_LEN;
679
+ const ret = wasm.excelcolumninfo_withValueFormat(ptr, ptr0, len0);
680
+ return ExcelColumnInfo.__wrap(ret);
681
+ }
682
+ /**
683
+ * @param {number} width
684
+ * @returns {ExcelColumnInfo}
685
+ */
686
+ withWidth(width) {
687
+ const ptr = this.__destroy_into_raw();
688
+ const ret = wasm.excelcolumninfo_withWidth(ptr, width);
689
+ return ExcelColumnInfo.__wrap(ret);
690
+ }
691
+ /**
692
+ * @returns {string[]}
693
+ */
694
+ get allowed_values() {
695
+ const ret = wasm.__wbg_get_excelcolumninfo_allowed_values(this.__wbg_ptr);
696
+ var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
697
+ wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
698
+ return v1;
699
+ }
700
+ /**
701
+ * @returns {string}
702
+ */
703
+ get data_group_parent() {
704
+ let deferred1_0;
705
+ let deferred1_1;
706
+ try {
707
+ const ret = wasm.__wbg_get_excelcolumninfo_data_group_parent(this.__wbg_ptr);
708
+ deferred1_0 = ret[0];
709
+ deferred1_1 = ret[1];
710
+ return getStringFromWasm0(ret[0], ret[1]);
711
+ } finally {
712
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
93
713
  }
94
- ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;
95
- const view = getUint8ArrayMemory0().subarray(ptr + offset, ptr + len);
96
- const ret = encodeString(arg, view);
97
-
98
- offset += ret.written;
99
- ptr = realloc(ptr, len, offset, 1) >>> 0;
100
714
  }
101
-
102
- WASM_VECTOR_LEN = offset;
103
- return ptr;
104
- }
105
-
106
- function isLikeNone(x) {
107
- return x === undefined || x === null;
108
- }
109
-
110
- let cachedDataViewMemory0 = null;
111
-
112
- function getDataViewMemory0() {
113
- if (cachedDataViewMemory0 === null || cachedDataViewMemory0.buffer.detached === true || (cachedDataViewMemory0.buffer.detached === undefined && cachedDataViewMemory0.buffer !== wasm.memory.buffer)) {
114
- cachedDataViewMemory0 = new DataView(wasm.memory.buffer);
715
+ /**
716
+ * @returns {string}
717
+ */
718
+ get data_group() {
719
+ let deferred1_0;
720
+ let deferred1_1;
721
+ try {
722
+ const ret = wasm.__wbg_get_excelcolumninfo_data_group(this.__wbg_ptr);
723
+ deferred1_0 = ret[0];
724
+ deferred1_1 = ret[1];
725
+ return getStringFromWasm0(ret[0], ret[1]);
726
+ } finally {
727
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
728
+ }
729
+ }
730
+ /**
731
+ * @returns {string}
732
+ */
733
+ get data_type() {
734
+ let deferred1_0;
735
+ let deferred1_1;
736
+ try {
737
+ const ret = wasm.__wbg_get_excelcolumninfo_data_type(this.__wbg_ptr);
738
+ deferred1_0 = ret[0];
739
+ deferred1_1 = ret[1];
740
+ return getStringFromWasm0(ret[0], ret[1]);
741
+ } finally {
742
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
743
+ }
744
+ }
745
+ /**
746
+ * @returns {ExcelCellFormat | undefined}
747
+ */
748
+ get format() {
749
+ const ret = wasm.__wbg_get_excelcolumninfo_format(this.__wbg_ptr);
750
+ return ret === 0 ? undefined : ExcelCellFormat.__wrap(ret);
751
+ }
752
+ /**
753
+ * @returns {string}
754
+ */
755
+ get key() {
756
+ let deferred1_0;
757
+ let deferred1_1;
758
+ try {
759
+ const ret = wasm.__wbg_get_excelcolumninfo_key(this.__wbg_ptr);
760
+ deferred1_0 = ret[0];
761
+ deferred1_1 = ret[1];
762
+ return getStringFromWasm0(ret[0], ret[1]);
763
+ } finally {
764
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
765
+ }
766
+ }
767
+ /**
768
+ * @returns {string}
769
+ */
770
+ get name() {
771
+ let deferred1_0;
772
+ let deferred1_1;
773
+ try {
774
+ const ret = wasm.__wbg_get_excelcolumninfo_name(this.__wbg_ptr);
775
+ deferred1_0 = ret[0];
776
+ deferred1_1 = ret[1];
777
+ return getStringFromWasm0(ret[0], ret[1]);
778
+ } finally {
779
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
780
+ }
781
+ }
782
+ /**
783
+ * @returns {string | undefined}
784
+ */
785
+ get note() {
786
+ const ret = wasm.__wbg_get_excelcolumninfo_note(this.__wbg_ptr);
787
+ let v1;
788
+ if (ret[0] !== 0) {
789
+ v1 = getStringFromWasm0(ret[0], ret[1]).slice();
790
+ wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
791
+ }
792
+ return v1;
793
+ }
794
+ /**
795
+ * @returns {string}
796
+ */
797
+ get parent() {
798
+ let deferred1_0;
799
+ let deferred1_1;
800
+ try {
801
+ const ret = wasm.__wbg_get_excelcolumninfo_parent(this.__wbg_ptr);
802
+ deferred1_0 = ret[0];
803
+ deferred1_1 = ret[1];
804
+ return getStringFromWasm0(ret[0], ret[1]);
805
+ } finally {
806
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
807
+ }
808
+ }
809
+ /**
810
+ * @returns {ExcelCellFormat[]}
811
+ */
812
+ get value_format() {
813
+ const ret = wasm.__wbg_get_excelcolumninfo_value_format(this.__wbg_ptr);
814
+ var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
815
+ wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
816
+ return v1;
817
+ }
818
+ /**
819
+ * @returns {number}
820
+ */
821
+ get width() {
822
+ const ret = wasm.__wbg_get_excelcolumninfo_width(this.__wbg_ptr);
823
+ return ret;
824
+ }
825
+ /**
826
+ * @param {string[]} arg0
827
+ */
828
+ set allowed_values(arg0) {
829
+ const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
830
+ const len0 = WASM_VECTOR_LEN;
831
+ wasm.__wbg_set_excelcolumninfo_allowed_values(this.__wbg_ptr, ptr0, len0);
832
+ }
833
+ /**
834
+ * @param {string} arg0
835
+ */
836
+ set data_group_parent(arg0) {
837
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
838
+ const len0 = WASM_VECTOR_LEN;
839
+ wasm.__wbg_set_excelcolumninfo_data_group_parent(this.__wbg_ptr, ptr0, len0);
840
+ }
841
+ /**
842
+ * @param {string} arg0
843
+ */
844
+ set data_group(arg0) {
845
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
846
+ const len0 = WASM_VECTOR_LEN;
847
+ wasm.__wbg_set_excelcolumninfo_data_group(this.__wbg_ptr, ptr0, len0);
848
+ }
849
+ /**
850
+ * @param {string} arg0
851
+ */
852
+ set data_type(arg0) {
853
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
854
+ const len0 = WASM_VECTOR_LEN;
855
+ wasm.__wbg_set_excelcolumninfo_data_type(this.__wbg_ptr, ptr0, len0);
856
+ }
857
+ /**
858
+ * @param {ExcelCellFormat | null} [arg0]
859
+ */
860
+ set format(arg0) {
861
+ let ptr0 = 0;
862
+ if (!isLikeNone(arg0)) {
863
+ _assertClass(arg0, ExcelCellFormat);
864
+ ptr0 = arg0.__destroy_into_raw();
865
+ }
866
+ wasm.__wbg_set_excelcolumninfo_format(this.__wbg_ptr, ptr0);
867
+ }
868
+ /**
869
+ * @param {string} arg0
870
+ */
871
+ set key(arg0) {
872
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
873
+ const len0 = WASM_VECTOR_LEN;
874
+ wasm.__wbg_set_excelcolumninfo_key(this.__wbg_ptr, ptr0, len0);
875
+ }
876
+ /**
877
+ * @param {string} arg0
878
+ */
879
+ set name(arg0) {
880
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
881
+ const len0 = WASM_VECTOR_LEN;
882
+ wasm.__wbg_set_excelcolumninfo_name(this.__wbg_ptr, ptr0, len0);
883
+ }
884
+ /**
885
+ * @param {string | null} [arg0]
886
+ */
887
+ set note(arg0) {
888
+ var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
889
+ var len0 = WASM_VECTOR_LEN;
890
+ wasm.__wbg_set_excelcolumninfo_note(this.__wbg_ptr, ptr0, len0);
891
+ }
892
+ /**
893
+ * @param {string} arg0
894
+ */
895
+ set parent(arg0) {
896
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
897
+ const len0 = WASM_VECTOR_LEN;
898
+ wasm.__wbg_set_excelcolumninfo_parent(this.__wbg_ptr, ptr0, len0);
899
+ }
900
+ /**
901
+ * @param {ExcelCellFormat[]} arg0
902
+ */
903
+ set value_format(arg0) {
904
+ const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
905
+ const len0 = WASM_VECTOR_LEN;
906
+ wasm.__wbg_set_excelcolumninfo_value_format(this.__wbg_ptr, ptr0, len0);
115
907
  }
116
- return cachedDataViewMemory0;
117
- }
118
-
119
- function getArrayJsValueFromWasm0(ptr, len) {
120
- ptr = ptr >>> 0;
121
- const mem = getDataViewMemory0();
122
- const result = [];
123
- for (let i = ptr; i < ptr + 4 * len; i += 4) {
124
- result.push(takeObject(mem.getUint32(i, true)));
908
+ /**
909
+ * @param {number} arg0
910
+ */
911
+ set width(arg0) {
912
+ wasm.__wbg_set_excelcolumninfo_width(this.__wbg_ptr, arg0);
125
913
  }
126
- return result;
127
914
  }
915
+ if (Symbol.dispose) ExcelColumnInfo.prototype[Symbol.dispose] = ExcelColumnInfo.prototype.free;
128
916
 
129
- function passArrayJsValueToWasm0(array, malloc) {
130
- const ptr = malloc(array.length * 4, 4) >>> 0;
131
- const mem = getDataViewMemory0();
132
- for (let i = 0; i < array.length; i++) {
133
- mem.setUint32(ptr + 4 * i, addHeapObject(array[i]), true);
917
+ export class ExcelData {
918
+ static __wrap(ptr) {
919
+ ptr = ptr >>> 0;
920
+ const obj = Object.create(ExcelData.prototype);
921
+ obj.__wbg_ptr = ptr;
922
+ ExcelDataFinalization.register(obj, obj.__wbg_ptr, obj);
923
+ return obj;
134
924
  }
135
- WASM_VECTOR_LEN = array.length;
136
- return ptr;
137
- }
138
-
139
- function _assertClass(instance, klass) {
140
- if (!(instance instanceof klass)) {
141
- throw new Error(`expected instance of ${klass.name}`);
925
+ __destroy_into_raw() {
926
+ const ptr = this.__wbg_ptr;
927
+ this.__wbg_ptr = 0;
928
+ ExcelDataFinalization.unregister(this);
929
+ return ptr;
142
930
  }
143
- return instance.ptr;
144
- }
145
-
146
- function getArrayU8FromWasm0(ptr, len) {
147
- ptr = ptr >>> 0;
148
- return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
149
- }
150
- /**
151
- * @param {ExcelInfo} info
152
- * @returns {Uint8Array}
153
- */
154
- export function createTemplate(info) {
155
- try {
156
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
157
- _assertClass(info, ExcelInfo);
158
- var ptr0 = info.__destroy_into_raw();
159
- wasm.createTemplate(retptr, ptr0);
160
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
161
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
162
- var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
163
- var r3 = getDataViewMemory0().getInt32(retptr + 4 * 3, true);
164
- if (r3) {
165
- throw takeObject(r2);
166
- }
167
- var v2 = getArrayU8FromWasm0(r0, r1).slice();
168
- wasm.__wbindgen_free(r0, r1 * 1, 1);
169
- return v2;
170
- } finally {
171
- wasm.__wbindgen_add_to_stack_pointer(16);
931
+ free() {
932
+ const ptr = this.__destroy_into_raw();
933
+ wasm.__wbg_exceldata_free(ptr, 0);
172
934
  }
173
- }
174
-
175
- function passArray8ToWasm0(arg, malloc) {
176
- const ptr = malloc(arg.length * 1, 1) >>> 0;
177
- getUint8ArrayMemory0().set(arg, ptr / 1);
178
- WASM_VECTOR_LEN = arg.length;
179
- return ptr;
180
- }
181
- /**
182
- * @param {ExcelInfo} info
183
- * @param {Uint8Array} excel_bytes
184
- * @returns {ExcelData}
185
- */
186
- export function importData(info, excel_bytes) {
187
- try {
188
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
189
- _assertClass(info, ExcelInfo);
190
- var ptr0 = info.__destroy_into_raw();
191
- const ptr1 = passArray8ToWasm0(excel_bytes, wasm.__wbindgen_malloc);
192
- const len1 = WASM_VECTOR_LEN;
193
- wasm.importData(retptr, ptr0, ptr1, len1);
194
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
195
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
196
- var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
197
- if (r2) {
198
- throw takeObject(r1);
199
- }
200
- return ExcelData.__wrap(r0);
201
- } finally {
202
- wasm.__wbindgen_add_to_stack_pointer(16);
935
+ /**
936
+ * @param {ExcelRowData[]} rows
937
+ */
938
+ constructor(rows) {
939
+ const ptr0 = passArrayJsValueToWasm0(rows, wasm.__wbindgen_malloc);
940
+ const len0 = WASM_VECTOR_LEN;
941
+ const ret = wasm.exceldata_new(ptr0, len0);
942
+ this.__wbg_ptr = ret >>> 0;
943
+ ExcelDataFinalization.register(this, this.__wbg_ptr, this);
944
+ return this;
203
945
  }
204
- }
205
-
206
- /**
207
- * @param {ExcelInfo} info
208
- * @param {ExcelData} data
209
- * @returns {Uint8Array}
210
- */
211
- export function exportData(info, data) {
212
- try {
213
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
214
- _assertClass(info, ExcelInfo);
215
- var ptr0 = info.__destroy_into_raw();
216
- _assertClass(data, ExcelData);
217
- var ptr1 = data.__destroy_into_raw();
218
- wasm.exportData(retptr, ptr0, ptr1);
219
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
220
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
221
- var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
222
- var r3 = getDataViewMemory0().getInt32(retptr + 4 * 3, true);
223
- if (r3) {
224
- throw takeObject(r2);
225
- }
226
- var v3 = getArrayU8FromWasm0(r0, r1).slice();
227
- wasm.__wbindgen_free(r0, r1 * 1, 1);
228
- return v3;
229
- } finally {
230
- wasm.__wbindgen_add_to_stack_pointer(16);
946
+ /**
947
+ * @returns {ExcelRowData[]}
948
+ */
949
+ get rows() {
950
+ const ret = wasm.__wbg_get_exceldata_rows(this.__wbg_ptr);
951
+ var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
952
+ wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
953
+ return v1;
954
+ }
955
+ /**
956
+ * @param {ExcelRowData[]} arg0
957
+ */
958
+ set rows(arg0) {
959
+ const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
960
+ const len0 = WASM_VECTOR_LEN;
961
+ wasm.__wbg_set_exceldata_rows(this.__wbg_ptr, ptr0, len0);
231
962
  }
232
963
  }
964
+ if (Symbol.dispose) ExcelData.prototype[Symbol.dispose] = ExcelData.prototype.free;
233
965
 
234
- export const ExcelDataType = Object.freeze({ Text:0,"0":"Text",Number:1,"1":"Number", });
235
-
236
- const ExcelColumnDataFinalization = (typeof FinalizationRegistry === 'undefined')
237
- ? { register: () => {}, unregister: () => {} }
238
- : new FinalizationRegistry(ptr => wasm.__wbg_excelcolumndata_free(ptr >>> 0, 1));
239
-
240
- export class ExcelColumnData {
241
-
966
+ export class ExcelInfo {
242
967
  static __wrap(ptr) {
243
968
  ptr = ptr >>> 0;
244
- const obj = Object.create(ExcelColumnData.prototype);
969
+ const obj = Object.create(ExcelInfo.prototype);
245
970
  obj.__wbg_ptr = ptr;
246
- ExcelColumnDataFinalization.register(obj, obj.__wbg_ptr, obj);
971
+ ExcelInfoFinalization.register(obj, obj.__wbg_ptr, obj);
247
972
  return obj;
248
973
  }
249
-
250
- static __unwrap(jsValue) {
251
- if (!(jsValue instanceof ExcelColumnData)) {
252
- return 0;
253
- }
254
- return jsValue.__destroy_into_raw();
255
- }
256
-
257
974
  __destroy_into_raw() {
258
975
  const ptr = this.__wbg_ptr;
259
976
  this.__wbg_ptr = 0;
260
- ExcelColumnDataFinalization.unregister(this);
977
+ ExcelInfoFinalization.unregister(this);
261
978
  return ptr;
262
979
  }
263
-
264
980
  free() {
265
981
  const ptr = this.__destroy_into_raw();
266
- wasm.__wbg_excelcolumndata_free(ptr, 0);
982
+ wasm.__wbg_excelinfo_free(ptr, 0);
983
+ }
984
+ /**
985
+ * @param {string} name
986
+ * @param {string} sheet_name
987
+ * @param {ExcelColumnInfo[]} columns
988
+ * @param {string} author
989
+ * @param {string} create_time
990
+ */
991
+ constructor(name, sheet_name, columns, author, create_time) {
992
+ const ptr0 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
993
+ const len0 = WASM_VECTOR_LEN;
994
+ const ptr1 = passStringToWasm0(sheet_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
995
+ const len1 = WASM_VECTOR_LEN;
996
+ const ptr2 = passArrayJsValueToWasm0(columns, wasm.__wbindgen_malloc);
997
+ const len2 = WASM_VECTOR_LEN;
998
+ const ptr3 = passStringToWasm0(author, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
999
+ const len3 = WASM_VECTOR_LEN;
1000
+ const ptr4 = passStringToWasm0(create_time, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1001
+ const len4 = WASM_VECTOR_LEN;
1002
+ const ret = wasm.excelinfo_bind_new(ptr0, len0, ptr1, len1, ptr2, len2, ptr3, len3, ptr4, len4);
1003
+ this.__wbg_ptr = ret >>> 0;
1004
+ ExcelInfoFinalization.register(this, this.__wbg_ptr, this);
1005
+ return this;
1006
+ }
1007
+ /**
1008
+ * @param {number} row_height
1009
+ * @returns {ExcelInfo}
1010
+ */
1011
+ withDefaultRowHeight(row_height) {
1012
+ const ptr = this.__destroy_into_raw();
1013
+ const ret = wasm.excelinfo_withDefaultRowHeight(ptr, row_height);
1014
+ return ExcelInfo.__wrap(ret);
1015
+ }
1016
+ /**
1017
+ * @param {number} row_height
1018
+ * @returns {ExcelInfo}
1019
+ */
1020
+ withHeaderRowHeight(row_height) {
1021
+ const ptr = this.__destroy_into_raw();
1022
+ const ret = wasm.excelinfo_withHeaderRowHeight(ptr, row_height);
1023
+ return ExcelInfo.__wrap(ret);
1024
+ }
1025
+ /**
1026
+ * @param {Function} fetcher
1027
+ * @returns {ExcelInfo}
1028
+ */
1029
+ withImageFetcher(fetcher) {
1030
+ const ptr = this.__destroy_into_raw();
1031
+ const ret = wasm.excelinfo_withImageFetcher(ptr, fetcher);
1032
+ return ExcelInfo.__wrap(ret);
1033
+ }
1034
+ /**
1035
+ * @param {boolean} is_header_freeze
1036
+ * @returns {ExcelInfo}
1037
+ */
1038
+ withIsHeaderFreeze(is_header_freeze) {
1039
+ const ptr = this.__destroy_into_raw();
1040
+ const ret = wasm.excelinfo_withIsHeaderFreeze(ptr, is_header_freeze);
1041
+ return ExcelInfo.__wrap(ret);
1042
+ }
1043
+ /**
1044
+ * @param {number} dx
1045
+ * @param {number} dy
1046
+ * @returns {ExcelInfo}
1047
+ */
1048
+ withOffset(dx, dy) {
1049
+ const ptr = this.__destroy_into_raw();
1050
+ const ret = wasm.excelinfo_withOffset(ptr, dx, dy);
1051
+ return ExcelInfo.__wrap(ret);
1052
+ }
1053
+ /**
1054
+ * @param {Function} callback
1055
+ * @returns {ExcelInfo}
1056
+ */
1057
+ withProgressCallback(callback) {
1058
+ const ptr = this.__destroy_into_raw();
1059
+ const ret = wasm.excelinfo_withProgressCallback(ptr, callback);
1060
+ return ExcelInfo.__wrap(ret);
1061
+ }
1062
+ /**
1063
+ * @param {string} title
1064
+ * @returns {ExcelInfo}
1065
+ */
1066
+ withTitle(title) {
1067
+ const ptr = this.__destroy_into_raw();
1068
+ const ptr0 = passStringToWasm0(title, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1069
+ const len0 = WASM_VECTOR_LEN;
1070
+ const ret = wasm.excelinfo_withTitle(ptr, ptr0, len0);
1071
+ return ExcelInfo.__wrap(ret);
1072
+ }
1073
+ /**
1074
+ * @param {ExcelCellFormat} title_format
1075
+ * @returns {ExcelInfo}
1076
+ */
1077
+ withTitleFormat(title_format) {
1078
+ const ptr = this.__destroy_into_raw();
1079
+ _assertClass(title_format, ExcelCellFormat);
1080
+ var ptr0 = title_format.__destroy_into_raw();
1081
+ const ret = wasm.excelinfo_withTitleFormat(ptr, ptr0);
1082
+ return ExcelInfo.__wrap(ret);
1083
+ }
1084
+ /**
1085
+ * @param {number} title_height
1086
+ * @returns {ExcelInfo}
1087
+ */
1088
+ withTitleHeight(title_height) {
1089
+ const ptr = this.__destroy_into_raw();
1090
+ const ret = wasm.excelinfo_withTitleHeight(ptr, title_height);
1091
+ return ExcelInfo.__wrap(ret);
267
1092
  }
268
1093
  /**
269
1094
  * @returns {string}
270
1095
  */
271
- get key() {
1096
+ get author() {
272
1097
  let deferred1_0;
273
1098
  let deferred1_1;
274
1099
  try {
275
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
276
- wasm.__wbg_get_excelcolumndata_key(retptr, this.__wbg_ptr);
277
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
278
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
279
- deferred1_0 = r0;
280
- deferred1_1 = r1;
281
- return getStringFromWasm0(r0, r1);
1100
+ const ret = wasm.__wbg_get_excelinfo_author(this.__wbg_ptr);
1101
+ deferred1_0 = ret[0];
1102
+ deferred1_1 = ret[1];
1103
+ return getStringFromWasm0(ret[0], ret[1]);
282
1104
  } finally {
283
- wasm.__wbindgen_add_to_stack_pointer(16);
284
1105
  wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
285
1106
  }
286
1107
  }
287
1108
  /**
288
- * @param {string} arg0
1109
+ * @returns {ExcelColumnInfo[]}
289
1110
  */
290
- set key(arg0) {
291
- const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
292
- const len0 = WASM_VECTOR_LEN;
293
- wasm.__wbg_set_excelcolumndata_key(this.__wbg_ptr, ptr0, len0);
1111
+ get columns() {
1112
+ const ret = wasm.__wbg_get_excelinfo_columns(this.__wbg_ptr);
1113
+ var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
1114
+ wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
1115
+ return v1;
294
1116
  }
295
1117
  /**
296
1118
  * @returns {string}
297
1119
  */
298
- get value() {
1120
+ get create_time() {
299
1121
  let deferred1_0;
300
1122
  let deferred1_1;
301
1123
  try {
302
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
303
- wasm.__wbg_get_excelcolumndata_value(retptr, this.__wbg_ptr);
304
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
305
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
306
- deferred1_0 = r0;
307
- deferred1_1 = r1;
308
- return getStringFromWasm0(r0, r1);
1124
+ const ret = wasm.__wbg_get_excelinfo_create_time(this.__wbg_ptr);
1125
+ deferred1_0 = ret[0];
1126
+ deferred1_1 = ret[1];
1127
+ return getStringFromWasm0(ret[0], ret[1]);
309
1128
  } finally {
310
- wasm.__wbindgen_add_to_stack_pointer(16);
311
1129
  wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
312
1130
  }
313
1131
  }
314
1132
  /**
315
- * @param {string} arg0
1133
+ * @returns {number | undefined}
316
1134
  */
317
- set value(arg0) {
318
- const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
319
- const len0 = WASM_VECTOR_LEN;
320
- wasm.__wbg_set_excelcolumndata_value(this.__wbg_ptr, ptr0, len0);
1135
+ get default_row_height() {
1136
+ const ret = wasm.__wbg_get_excelinfo_default_row_height(this.__wbg_ptr);
1137
+ return ret[0] === 0 ? undefined : ret[1];
321
1138
  }
322
1139
  /**
323
- * @param {string} key
324
- * @param {string} value
1140
+ * @returns {number}
325
1141
  */
326
- constructor(key, value) {
327
- const ptr0 = passStringToWasm0(key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
328
- const len0 = WASM_VECTOR_LEN;
329
- const ptr1 = passStringToWasm0(value, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
330
- const len1 = WASM_VECTOR_LEN;
331
- const ret = wasm.excelcolumndata_new(ptr0, len0, ptr1, len1);
332
- this.__wbg_ptr = ret >>> 0;
333
- ExcelColumnDataFinalization.register(this, this.__wbg_ptr, this);
334
- return this;
335
- }
336
- }
337
-
338
- const ExcelColumnInfoFinalization = (typeof FinalizationRegistry === 'undefined')
339
- ? { register: () => {}, unregister: () => {} }
340
- : new FinalizationRegistry(ptr => wasm.__wbg_excelcolumninfo_free(ptr >>> 0, 1));
341
-
342
- export class ExcelColumnInfo {
343
-
344
- static __wrap(ptr) {
345
- ptr = ptr >>> 0;
346
- const obj = Object.create(ExcelColumnInfo.prototype);
347
- obj.__wbg_ptr = ptr;
348
- ExcelColumnInfoFinalization.register(obj, obj.__wbg_ptr, obj);
349
- return obj;
1142
+ get dx() {
1143
+ const ret = wasm.__wbg_get_excelinfo_dx(this.__wbg_ptr);
1144
+ return ret;
350
1145
  }
351
-
352
- static __unwrap(jsValue) {
353
- if (!(jsValue instanceof ExcelColumnInfo)) {
354
- return 0;
355
- }
356
- return jsValue.__destroy_into_raw();
1146
+ /**
1147
+ * @returns {number}
1148
+ */
1149
+ get dy() {
1150
+ const ret = wasm.__wbg_get_excelinfo_dy(this.__wbg_ptr);
1151
+ return ret >>> 0;
357
1152
  }
358
-
359
- __destroy_into_raw() {
360
- const ptr = this.__wbg_ptr;
361
- this.__wbg_ptr = 0;
362
- ExcelColumnInfoFinalization.unregister(this);
363
- return ptr;
1153
+ /**
1154
+ * @returns {number | undefined}
1155
+ */
1156
+ get header_row_height() {
1157
+ const ret = wasm.__wbg_get_excelinfo_header_row_height(this.__wbg_ptr);
1158
+ return ret[0] === 0 ? undefined : ret[1];
364
1159
  }
365
-
366
- free() {
367
- const ptr = this.__destroy_into_raw();
368
- wasm.__wbg_excelcolumninfo_free(ptr, 0);
1160
+ /**
1161
+ * @returns {boolean}
1162
+ */
1163
+ get is_header_freeze() {
1164
+ const ret = wasm.__wbg_get_excelinfo_is_header_freeze(this.__wbg_ptr);
1165
+ return ret !== 0;
369
1166
  }
370
1167
  /**
371
1168
  * @returns {string}
372
1169
  */
373
- get key() {
1170
+ get name() {
374
1171
  let deferred1_0;
375
1172
  let deferred1_1;
376
1173
  try {
377
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
378
- wasm.__wbg_get_excelcolumninfo_key(retptr, this.__wbg_ptr);
379
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
380
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
381
- deferred1_0 = r0;
382
- deferred1_1 = r1;
383
- return getStringFromWasm0(r0, r1);
1174
+ const ret = wasm.__wbg_get_excelinfo_name(this.__wbg_ptr);
1175
+ deferred1_0 = ret[0];
1176
+ deferred1_1 = ret[1];
1177
+ return getStringFromWasm0(ret[0], ret[1]);
384
1178
  } finally {
385
- wasm.__wbindgen_add_to_stack_pointer(16);
386
1179
  wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
387
1180
  }
388
1181
  }
389
- /**
390
- * @param {string} arg0
391
- */
392
- set key(arg0) {
393
- const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
394
- const len0 = WASM_VECTOR_LEN;
395
- wasm.__wbg_set_excelcolumninfo_key(this.__wbg_ptr, ptr0, len0);
396
- }
397
1182
  /**
398
1183
  * @returns {string}
399
1184
  */
400
- get name() {
1185
+ get sheet_name() {
401
1186
  let deferred1_0;
402
1187
  let deferred1_1;
403
1188
  try {
404
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
405
- wasm.__wbg_get_excelcolumninfo_name(retptr, this.__wbg_ptr);
406
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
407
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
408
- deferred1_0 = r0;
409
- deferred1_1 = r1;
410
- return getStringFromWasm0(r0, r1);
1189
+ const ret = wasm.__wbg_get_excelinfo_sheet_name(this.__wbg_ptr);
1190
+ deferred1_0 = ret[0];
1191
+ deferred1_1 = ret[1];
1192
+ return getStringFromWasm0(ret[0], ret[1]);
411
1193
  } finally {
412
- wasm.__wbindgen_add_to_stack_pointer(16);
413
1194
  wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
414
1195
  }
415
1196
  }
416
1197
  /**
417
- * @param {string} arg0
1198
+ * @returns {ExcelCellFormat | undefined}
418
1199
  */
419
- set name(arg0) {
420
- const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
421
- const len0 = WASM_VECTOR_LEN;
422
- wasm.__wbg_set_excelcolumninfo_name(this.__wbg_ptr, ptr0, len0);
1200
+ get title_format() {
1201
+ const ret = wasm.__wbg_get_excelinfo_title_format(this.__wbg_ptr);
1202
+ return ret === 0 ? undefined : ExcelCellFormat.__wrap(ret);
423
1203
  }
424
1204
  /**
425
1205
  * @returns {number | undefined}
426
1206
  */
427
- get width() {
428
- try {
429
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
430
- wasm.__wbg_get_excelcolumninfo_width(retptr, this.__wbg_ptr);
431
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
432
- var r2 = getDataViewMemory0().getFloat64(retptr + 8 * 1, true);
433
- return r0 === 0 ? undefined : r2;
434
- } finally {
435
- wasm.__wbindgen_add_to_stack_pointer(16);
1207
+ get title_height() {
1208
+ const ret = wasm.__wbg_get_excelinfo_title_height(this.__wbg_ptr);
1209
+ return ret[0] === 0 ? undefined : ret[1];
1210
+ }
1211
+ /**
1212
+ * @returns {string | undefined}
1213
+ */
1214
+ get title() {
1215
+ const ret = wasm.__wbg_get_excelinfo_title(this.__wbg_ptr);
1216
+ let v1;
1217
+ if (ret[0] !== 0) {
1218
+ v1 = getStringFromWasm0(ret[0], ret[1]).slice();
1219
+ wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
436
1220
  }
1221
+ return v1;
437
1222
  }
438
1223
  /**
439
- * @param {number | undefined} [arg0]
1224
+ * @param {string} arg0
440
1225
  */
441
- set width(arg0) {
442
- wasm.__wbg_set_excelcolumninfo_width(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? 0 : arg0);
1226
+ set author(arg0) {
1227
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1228
+ const len0 = WASM_VECTOR_LEN;
1229
+ wasm.__wbg_set_excelinfo_author(this.__wbg_ptr, ptr0, len0);
443
1230
  }
444
1231
  /**
445
- * @returns {string | undefined}
1232
+ * @param {ExcelColumnInfo[]} arg0
446
1233
  */
447
- get note() {
448
- try {
449
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
450
- wasm.__wbg_get_excelcolumninfo_note(retptr, this.__wbg_ptr);
451
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
452
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
453
- let v1;
454
- if (r0 !== 0) {
455
- v1 = getStringFromWasm0(r0, r1).slice();
456
- wasm.__wbindgen_free(r0, r1 * 1, 1);
457
- }
458
- return v1;
459
- } finally {
460
- wasm.__wbindgen_add_to_stack_pointer(16);
461
- }
1234
+ set columns(arg0) {
1235
+ const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
1236
+ const len0 = WASM_VECTOR_LEN;
1237
+ wasm.__wbg_set_excelinfo_columns(this.__wbg_ptr, ptr0, len0);
462
1238
  }
463
1239
  /**
464
- * @param {string | undefined} [arg0]
1240
+ * @param {string} arg0
465
1241
  */
466
- set note(arg0) {
467
- var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
468
- var len0 = WASM_VECTOR_LEN;
469
- wasm.__wbg_set_excelcolumninfo_note(this.__wbg_ptr, ptr0, len0);
1242
+ set create_time(arg0) {
1243
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1244
+ const len0 = WASM_VECTOR_LEN;
1245
+ wasm.__wbg_set_excelinfo_create_time(this.__wbg_ptr, ptr0, len0);
470
1246
  }
471
1247
  /**
472
- * @returns {ExcelDataType}
1248
+ * @param {number | null} [arg0]
473
1249
  */
474
- get data_type() {
475
- const ret = wasm.__wbg_get_excelcolumninfo_data_type(this.__wbg_ptr);
476
- return ret;
1250
+ set default_row_height(arg0) {
1251
+ wasm.__wbg_set_excelinfo_default_row_height(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? 0 : arg0);
477
1252
  }
478
1253
  /**
479
- * @param {ExcelDataType} arg0
1254
+ * @param {number} arg0
480
1255
  */
481
- set data_type(arg0) {
482
- wasm.__wbg_set_excelcolumninfo_data_type(this.__wbg_ptr, arg0);
1256
+ set dx(arg0) {
1257
+ wasm.__wbg_set_excelinfo_dx(this.__wbg_ptr, arg0);
483
1258
  }
484
1259
  /**
485
- * @returns {(string)[] | undefined}
1260
+ * @param {number} arg0
486
1261
  */
487
- get allowed_values() {
488
- try {
489
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
490
- wasm.__wbg_get_excelcolumninfo_allowed_values(retptr, this.__wbg_ptr);
491
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
492
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
493
- let v1;
494
- if (r0 !== 0) {
495
- v1 = getArrayJsValueFromWasm0(r0, r1).slice();
496
- wasm.__wbindgen_free(r0, r1 * 4, 4);
497
- }
498
- return v1;
499
- } finally {
500
- wasm.__wbindgen_add_to_stack_pointer(16);
501
- }
1262
+ set dy(arg0) {
1263
+ wasm.__wbg_set_excelinfo_dy(this.__wbg_ptr, arg0);
502
1264
  }
503
1265
  /**
504
- * @param {(string)[] | undefined} [arg0]
1266
+ * @param {number | null} [arg0]
505
1267
  */
506
- set allowed_values(arg0) {
507
- var ptr0 = isLikeNone(arg0) ? 0 : passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
508
- var len0 = WASM_VECTOR_LEN;
509
- wasm.__wbg_set_excelcolumninfo_allowed_values(this.__wbg_ptr, ptr0, len0);
1268
+ set header_row_height(arg0) {
1269
+ wasm.__wbg_set_excelinfo_header_row_height(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? 0 : arg0);
510
1270
  }
511
1271
  /**
512
- * @param {string} key
513
- * @param {string} name
514
- * @param {number | undefined} [width]
1272
+ * @param {boolean} arg0
515
1273
  */
516
- constructor(key, name, width) {
517
- const ptr0 = passStringToWasm0(key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1274
+ set is_header_freeze(arg0) {
1275
+ wasm.__wbg_set_excelinfo_is_header_freeze(this.__wbg_ptr, arg0);
1276
+ }
1277
+ /**
1278
+ * @param {string} arg0
1279
+ */
1280
+ set name(arg0) {
1281
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
518
1282
  const len0 = WASM_VECTOR_LEN;
519
- const ptr1 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
520
- const len1 = WASM_VECTOR_LEN;
521
- const ret = wasm.excelcolumninfo_new(ptr0, len0, ptr1, len1, !isLikeNone(width), isLikeNone(width) ? 0 : width);
522
- this.__wbg_ptr = ret >>> 0;
523
- ExcelColumnInfoFinalization.register(this, this.__wbg_ptr, this);
524
- return this;
1283
+ wasm.__wbg_set_excelinfo_name(this.__wbg_ptr, ptr0, len0);
525
1284
  }
526
1285
  /**
527
- * @param {string} note
1286
+ * @param {string} arg0
528
1287
  */
529
- setNote(note) {
530
- const ptr0 = passStringToWasm0(note, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1288
+ set sheet_name(arg0) {
1289
+ const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
531
1290
  const len0 = WASM_VECTOR_LEN;
532
- wasm.excelcolumninfo_setNote(this.__wbg_ptr, ptr0, len0);
1291
+ wasm.__wbg_set_excelinfo_sheet_name(this.__wbg_ptr, ptr0, len0);
533
1292
  }
534
1293
  /**
535
- * @param {ExcelDataType} data_type
1294
+ * @param {ExcelCellFormat | null} [arg0]
536
1295
  */
537
- setDataType(data_type) {
538
- wasm.excelcolumninfo_setDataType(this.__wbg_ptr, data_type);
1296
+ set title_format(arg0) {
1297
+ let ptr0 = 0;
1298
+ if (!isLikeNone(arg0)) {
1299
+ _assertClass(arg0, ExcelCellFormat);
1300
+ ptr0 = arg0.__destroy_into_raw();
1301
+ }
1302
+ wasm.__wbg_set_excelinfo_title_format(this.__wbg_ptr, ptr0);
539
1303
  }
540
1304
  /**
541
- * @param {(string)[]} allowed_values
1305
+ * @param {number | null} [arg0]
542
1306
  */
543
- setAllowedValues(allowed_values) {
544
- const ptr0 = passArrayJsValueToWasm0(allowed_values, wasm.__wbindgen_malloc);
545
- const len0 = WASM_VECTOR_LEN;
546
- wasm.excelcolumninfo_setAllowedValues(this.__wbg_ptr, ptr0, len0);
1307
+ set title_height(arg0) {
1308
+ wasm.__wbg_set_excelinfo_title_height(this.__wbg_ptr, !isLikeNone(arg0), isLikeNone(arg0) ? 0 : arg0);
1309
+ }
1310
+ /**
1311
+ * @param {string | null} [arg0]
1312
+ */
1313
+ set title(arg0) {
1314
+ var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1315
+ var len0 = WASM_VECTOR_LEN;
1316
+ wasm.__wbg_set_excelinfo_title(this.__wbg_ptr, ptr0, len0);
547
1317
  }
548
1318
  }
1319
+ if (Symbol.dispose) ExcelInfo.prototype[Symbol.dispose] = ExcelInfo.prototype.free;
549
1320
 
550
- const ExcelDataFinalization = (typeof FinalizationRegistry === 'undefined')
551
- ? { register: () => {}, unregister: () => {} }
552
- : new FinalizationRegistry(ptr => wasm.__wbg_exceldata_free(ptr >>> 0, 1));
553
-
554
- export class ExcelData {
555
-
1321
+ export class ExcelRowData {
556
1322
  static __wrap(ptr) {
557
1323
  ptr = ptr >>> 0;
558
- const obj = Object.create(ExcelData.prototype);
1324
+ const obj = Object.create(ExcelRowData.prototype);
559
1325
  obj.__wbg_ptr = ptr;
560
- ExcelDataFinalization.register(obj, obj.__wbg_ptr, obj);
1326
+ ExcelRowDataFinalization.register(obj, obj.__wbg_ptr, obj);
561
1327
  return obj;
562
1328
  }
563
-
1329
+ static __unwrap(jsValue) {
1330
+ if (!(jsValue instanceof ExcelRowData)) {
1331
+ return 0;
1332
+ }
1333
+ return jsValue.__destroy_into_raw();
1334
+ }
564
1335
  __destroy_into_raw() {
565
1336
  const ptr = this.__wbg_ptr;
566
1337
  this.__wbg_ptr = 0;
567
- ExcelDataFinalization.unregister(this);
1338
+ ExcelRowDataFinalization.unregister(this);
568
1339
  return ptr;
569
1340
  }
570
-
571
1341
  free() {
572
1342
  const ptr = this.__destroy_into_raw();
573
- wasm.__wbg_exceldata_free(ptr, 0);
1343
+ wasm.__wbg_excelrowdata_free(ptr, 0);
574
1344
  }
575
1345
  /**
576
- * @returns {(ExcelRowData)[]}
1346
+ * @param {ExcelColumnData[]} columns
577
1347
  */
578
- get rows() {
579
- try {
580
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
581
- wasm.__wbg_get_exceldata_rows(retptr, this.__wbg_ptr);
582
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
583
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
584
- var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
585
- wasm.__wbindgen_free(r0, r1 * 4, 4);
586
- return v1;
587
- } finally {
588
- wasm.__wbindgen_add_to_stack_pointer(16);
589
- }
1348
+ constructor(columns) {
1349
+ const ptr0 = passArrayJsValueToWasm0(columns, wasm.__wbindgen_malloc);
1350
+ const len0 = WASM_VECTOR_LEN;
1351
+ const ret = wasm.excelrowdata_new(ptr0, len0);
1352
+ this.__wbg_ptr = ret >>> 0;
1353
+ ExcelRowDataFinalization.register(this, this.__wbg_ptr, this);
1354
+ return this;
590
1355
  }
591
1356
  /**
592
- * @param {(ExcelRowData)[]} arg0
1357
+ * @returns {ExcelColumnData[]}
593
1358
  */
594
- set rows(arg0) {
595
- const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
596
- const len0 = WASM_VECTOR_LEN;
597
- wasm.__wbg_set_exceldata_rows(this.__wbg_ptr, ptr0, len0);
1359
+ get columns() {
1360
+ const ret = wasm.__wbg_get_excelrowdata_columns(this.__wbg_ptr);
1361
+ var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
1362
+ wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
1363
+ return v1;
598
1364
  }
599
1365
  /**
600
- * @param {(ExcelRowData)[]} rows
1366
+ * @param {ExcelColumnData[]} arg0
601
1367
  */
602
- constructor(rows) {
603
- const ptr0 = passArrayJsValueToWasm0(rows, wasm.__wbindgen_malloc);
1368
+ set columns(arg0) {
1369
+ const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
604
1370
  const len0 = WASM_VECTOR_LEN;
605
- const ret = wasm.exceldata_new(ptr0, len0);
606
- this.__wbg_ptr = ret >>> 0;
607
- ExcelDataFinalization.register(this, this.__wbg_ptr, this);
608
- return this;
1371
+ wasm.__wbg_set_excelrowdata_columns(this.__wbg_ptr, ptr0, len0);
1372
+ }
1373
+ }
1374
+ if (Symbol.dispose) ExcelRowData.prototype[Symbol.dispose] = ExcelRowData.prototype.free;
1375
+
1376
+ /**
1377
+ * @param {ExcelInfo} info
1378
+ * @returns {Uint8Array}
1379
+ */
1380
+ export function createTemplate(info) {
1381
+ _assertClass(info, ExcelInfo);
1382
+ var ptr0 = info.__destroy_into_raw();
1383
+ const ret = wasm.createTemplate(ptr0);
1384
+ if (ret[3]) {
1385
+ throw takeFromExternrefTable0(ret[2]);
1386
+ }
1387
+ var v2 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
1388
+ wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
1389
+ return v2;
1390
+ }
1391
+
1392
+ /**
1393
+ * @param {ExcelInfo} info
1394
+ * @param {ExcelData} data
1395
+ * @returns {Promise<any>}
1396
+ */
1397
+ export function exportData(info, data) {
1398
+ _assertClass(info, ExcelInfo);
1399
+ var ptr0 = info.__destroy_into_raw();
1400
+ _assertClass(data, ExcelData);
1401
+ var ptr1 = data.__destroy_into_raw();
1402
+ const ret = wasm.exportData(ptr0, ptr1);
1403
+ return ret;
1404
+ }
1405
+
1406
+ /**
1407
+ * @param {ExcelInfo} info
1408
+ * @param {Uint8Array} excel_bytes
1409
+ * @returns {ExcelData}
1410
+ */
1411
+ export function importData(info, excel_bytes) {
1412
+ _assertClass(info, ExcelInfo);
1413
+ var ptr0 = info.__destroy_into_raw();
1414
+ const ptr1 = passArray8ToWasm0(excel_bytes, wasm.__wbindgen_malloc);
1415
+ const len1 = WASM_VECTOR_LEN;
1416
+ const ret = wasm.importData(ptr0, ptr1, len1);
1417
+ if (ret[2]) {
1418
+ throw takeFromExternrefTable0(ret[1]);
1419
+ }
1420
+ return ExcelData.__wrap(ret[0]);
1421
+ }
1422
+
1423
+ function __wbg_get_imports() {
1424
+ const import0 = {
1425
+ __proto__: null,
1426
+ __wbg_Error_55538483de6e3abe: function(arg0, arg1) {
1427
+ const ret = Error(getStringFromWasm0(arg0, arg1));
1428
+ return ret;
1429
+ },
1430
+ __wbg___wbindgen_debug_string_d89627202d0155b7: function(arg0, arg1) {
1431
+ const ret = debugString(arg1);
1432
+ const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1433
+ const len1 = WASM_VECTOR_LEN;
1434
+ getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
1435
+ getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
1436
+ },
1437
+ __wbg___wbindgen_is_function_2a95406423ea8626: function(arg0) {
1438
+ const ret = typeof(arg0) === 'function';
1439
+ return ret;
1440
+ },
1441
+ __wbg___wbindgen_is_object_59a002e76b059312: function(arg0) {
1442
+ const val = arg0;
1443
+ const ret = typeof(val) === 'object' && val !== null;
1444
+ return ret;
1445
+ },
1446
+ __wbg___wbindgen_is_undefined_87a3a837f331fef5: function(arg0) {
1447
+ const ret = arg0 === undefined;
1448
+ return ret;
1449
+ },
1450
+ __wbg___wbindgen_string_get_f1161390414f9b59: function(arg0, arg1) {
1451
+ const obj = arg1;
1452
+ const ret = typeof(obj) === 'string' ? obj : undefined;
1453
+ var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1454
+ var len1 = WASM_VECTOR_LEN;
1455
+ getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
1456
+ getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
1457
+ },
1458
+ __wbg___wbindgen_throw_5549492daedad139: function(arg0, arg1) {
1459
+ throw new Error(getStringFromWasm0(arg0, arg1));
1460
+ },
1461
+ __wbg__wbg_cb_unref_fbe69bb076c16bad: function(arg0) {
1462
+ arg0._wbg_cb_unref();
1463
+ },
1464
+ __wbg_call_8f5d7bb070283508: function() { return handleError(function (arg0, arg1, arg2) {
1465
+ const ret = arg0.call(arg1, arg2);
1466
+ return ret;
1467
+ }, arguments); },
1468
+ __wbg_excelcellformat_new: function(arg0) {
1469
+ const ret = ExcelCellFormat.__wrap(arg0);
1470
+ return ret;
1471
+ },
1472
+ __wbg_excelcellformat_unwrap: function(arg0) {
1473
+ const ret = ExcelCellFormat.__unwrap(arg0);
1474
+ return ret;
1475
+ },
1476
+ __wbg_excelcolumndata_new: function(arg0) {
1477
+ const ret = ExcelColumnData.__wrap(arg0);
1478
+ return ret;
1479
+ },
1480
+ __wbg_excelcolumndata_unwrap: function(arg0) {
1481
+ const ret = ExcelColumnData.__unwrap(arg0);
1482
+ return ret;
1483
+ },
1484
+ __wbg_excelcolumninfo_new: function(arg0) {
1485
+ const ret = ExcelColumnInfo.__wrap(arg0);
1486
+ return ret;
1487
+ },
1488
+ __wbg_excelcolumninfo_unwrap: function(arg0) {
1489
+ const ret = ExcelColumnInfo.__unwrap(arg0);
1490
+ return ret;
1491
+ },
1492
+ __wbg_excelrowdata_new: function(arg0) {
1493
+ const ret = ExcelRowData.__wrap(arg0);
1494
+ return ret;
1495
+ },
1496
+ __wbg_excelrowdata_unwrap: function(arg0) {
1497
+ const ret = ExcelRowData.__unwrap(arg0);
1498
+ return ret;
1499
+ },
1500
+ __wbg_length_e6e1633fbea6cfa9: function(arg0) {
1501
+ const ret = arg0.length;
1502
+ return ret;
1503
+ },
1504
+ __wbg_new_1d96678aaacca32e: function(arg0) {
1505
+ const ret = new Uint8Array(arg0);
1506
+ return ret;
1507
+ },
1508
+ __wbg_new_from_slice_0bc58e36f82a1b50: function(arg0, arg1) {
1509
+ const ret = new Uint8Array(getArrayU8FromWasm0(arg0, arg1));
1510
+ return ret;
1511
+ },
1512
+ __wbg_new_typed_25dda2388d7e5e9f: function(arg0, arg1) {
1513
+ try {
1514
+ var state0 = {a: arg0, b: arg1};
1515
+ var cb0 = (arg0, arg1) => {
1516
+ const a = state0.a;
1517
+ state0.a = 0;
1518
+ try {
1519
+ return wasm_bindgen__convert__closures_____invoke__h350125d9fff5f488(a, state0.b, arg0, arg1);
1520
+ } finally {
1521
+ state0.a = a;
1522
+ }
1523
+ };
1524
+ const ret = new Promise(cb0);
1525
+ return ret;
1526
+ } finally {
1527
+ state0.a = 0;
1528
+ }
1529
+ },
1530
+ __wbg_now_46736a527d2e74e7: function() {
1531
+ const ret = Date.now();
1532
+ return ret;
1533
+ },
1534
+ __wbg_prototypesetcall_3875d54d12ef2eec: function(arg0, arg1, arg2) {
1535
+ Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), arg2);
1536
+ },
1537
+ __wbg_queueMicrotask_8868365114fe23b5: function(arg0) {
1538
+ queueMicrotask(arg0);
1539
+ },
1540
+ __wbg_queueMicrotask_cfc5a0e62f9ebdbe: function(arg0) {
1541
+ const ret = arg0.queueMicrotask;
1542
+ return ret;
1543
+ },
1544
+ __wbg_resolve_d8059bc113e215bf: function(arg0) {
1545
+ const ret = Promise.resolve(arg0);
1546
+ return ret;
1547
+ },
1548
+ __wbg_static_accessor_GLOBAL_8dfb7f5e26ebe523: function() {
1549
+ const ret = typeof global === 'undefined' ? null : global;
1550
+ return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
1551
+ },
1552
+ __wbg_static_accessor_GLOBAL_THIS_941154efc8395cdd: function() {
1553
+ const ret = typeof globalThis === 'undefined' ? null : globalThis;
1554
+ return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
1555
+ },
1556
+ __wbg_static_accessor_SELF_58dac9af822f561f: function() {
1557
+ const ret = typeof self === 'undefined' ? null : self;
1558
+ return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
1559
+ },
1560
+ __wbg_static_accessor_WINDOW_ee64f0b3d8354c0b: function() {
1561
+ const ret = typeof window === 'undefined' ? null : window;
1562
+ return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
1563
+ },
1564
+ __wbg_then_0150352e4ad20344: function(arg0, arg1, arg2) {
1565
+ const ret = arg0.then(arg1, arg2);
1566
+ return ret;
1567
+ },
1568
+ __wbg_then_5160486c67ddb98a: function(arg0, arg1) {
1569
+ const ret = arg0.then(arg1);
1570
+ return ret;
1571
+ },
1572
+ __wbindgen_cast_0000000000000001: function(arg0, arg1) {
1573
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 375, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
1574
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__hd2460eea81eed436);
1575
+ return ret;
1576
+ },
1577
+ __wbindgen_cast_0000000000000002: function(arg0) {
1578
+ // Cast intrinsic for `F64 -> Externref`.
1579
+ const ret = arg0;
1580
+ return ret;
1581
+ },
1582
+ __wbindgen_cast_0000000000000003: function(arg0, arg1) {
1583
+ // Cast intrinsic for `Ref(String) -> Externref`.
1584
+ const ret = getStringFromWasm0(arg0, arg1);
1585
+ return ret;
1586
+ },
1587
+ __wbindgen_init_externref_table: function() {
1588
+ const table = wasm.__wbindgen_externrefs;
1589
+ const offset = table.grow(4);
1590
+ table.set(0, undefined);
1591
+ table.set(offset + 0, undefined);
1592
+ table.set(offset + 1, null);
1593
+ table.set(offset + 2, true);
1594
+ table.set(offset + 3, false);
1595
+ },
1596
+ };
1597
+ return {
1598
+ __proto__: null,
1599
+ "./imexport_wasm_bg.js": import0,
1600
+ };
1601
+ }
1602
+
1603
+ function wasm_bindgen__convert__closures_____invoke__hd2460eea81eed436(arg0, arg1, arg2) {
1604
+ const ret = wasm.wasm_bindgen__convert__closures_____invoke__hd2460eea81eed436(arg0, arg1, arg2);
1605
+ if (ret[1]) {
1606
+ throw takeFromExternrefTable0(ret[0]);
609
1607
  }
610
1608
  }
611
1609
 
1610
+ function wasm_bindgen__convert__closures_____invoke__h350125d9fff5f488(arg0, arg1, arg2, arg3) {
1611
+ wasm.wasm_bindgen__convert__closures_____invoke__h350125d9fff5f488(arg0, arg1, arg2, arg3);
1612
+ }
1613
+
1614
+ const ExcelCellFormatFinalization = (typeof FinalizationRegistry === 'undefined')
1615
+ ? { register: () => {}, unregister: () => {} }
1616
+ : new FinalizationRegistry(ptr => wasm.__wbg_excelcellformat_free(ptr >>> 0, 1));
1617
+ const ExcelColumnDataFinalization = (typeof FinalizationRegistry === 'undefined')
1618
+ ? { register: () => {}, unregister: () => {} }
1619
+ : new FinalizationRegistry(ptr => wasm.__wbg_excelcolumndata_free(ptr >>> 0, 1));
1620
+ const ExcelColumnInfoFinalization = (typeof FinalizationRegistry === 'undefined')
1621
+ ? { register: () => {}, unregister: () => {} }
1622
+ : new FinalizationRegistry(ptr => wasm.__wbg_excelcolumninfo_free(ptr >>> 0, 1));
1623
+ const ExcelDataFinalization = (typeof FinalizationRegistry === 'undefined')
1624
+ ? { register: () => {}, unregister: () => {} }
1625
+ : new FinalizationRegistry(ptr => wasm.__wbg_exceldata_free(ptr >>> 0, 1));
612
1626
  const ExcelInfoFinalization = (typeof FinalizationRegistry === 'undefined')
613
1627
  ? { register: () => {}, unregister: () => {} }
614
1628
  : new FinalizationRegistry(ptr => wasm.__wbg_excelinfo_free(ptr >>> 0, 1));
1629
+ const ExcelRowDataFinalization = (typeof FinalizationRegistry === 'undefined')
1630
+ ? { register: () => {}, unregister: () => {} }
1631
+ : new FinalizationRegistry(ptr => wasm.__wbg_excelrowdata_free(ptr >>> 0, 1));
615
1632
 
616
- export class ExcelInfo {
617
-
618
- __destroy_into_raw() {
619
- const ptr = this.__wbg_ptr;
620
- this.__wbg_ptr = 0;
621
- ExcelInfoFinalization.unregister(this);
622
- return ptr;
623
- }
1633
+ function addToExternrefTable0(obj) {
1634
+ const idx = wasm.__externref_table_alloc();
1635
+ wasm.__wbindgen_externrefs.set(idx, obj);
1636
+ return idx;
1637
+ }
624
1638
 
625
- free() {
626
- const ptr = this.__destroy_into_raw();
627
- wasm.__wbg_excelinfo_free(ptr, 0);
628
- }
629
- /**
630
- * @returns {string}
631
- */
632
- get name() {
633
- let deferred1_0;
634
- let deferred1_1;
635
- try {
636
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
637
- wasm.__wbg_get_excelinfo_name(retptr, this.__wbg_ptr);
638
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
639
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
640
- deferred1_0 = r0;
641
- deferred1_1 = r1;
642
- return getStringFromWasm0(r0, r1);
643
- } finally {
644
- wasm.__wbindgen_add_to_stack_pointer(16);
645
- wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
646
- }
647
- }
648
- /**
649
- * @param {string} arg0
650
- */
651
- set name(arg0) {
652
- const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
653
- const len0 = WASM_VECTOR_LEN;
654
- wasm.__wbg_set_excelinfo_name(this.__wbg_ptr, ptr0, len0);
655
- }
656
- /**
657
- * @returns {string}
658
- */
659
- get sheet_name() {
660
- let deferred1_0;
661
- let deferred1_1;
662
- try {
663
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
664
- wasm.__wbg_get_excelinfo_sheet_name(retptr, this.__wbg_ptr);
665
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
666
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
667
- deferred1_0 = r0;
668
- deferred1_1 = r1;
669
- return getStringFromWasm0(r0, r1);
670
- } finally {
671
- wasm.__wbindgen_add_to_stack_pointer(16);
672
- wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
673
- }
674
- }
675
- /**
676
- * @param {string} arg0
677
- */
678
- set sheet_name(arg0) {
679
- const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
680
- const len0 = WASM_VECTOR_LEN;
681
- wasm.__wbg_set_excelinfo_sheet_name(this.__wbg_ptr, ptr0, len0);
1639
+ function _assertClass(instance, klass) {
1640
+ if (!(instance instanceof klass)) {
1641
+ throw new Error(`expected instance of ${klass.name}`);
682
1642
  }
683
- /**
684
- * @returns {(ExcelColumnInfo)[]}
685
- */
686
- get columns() {
687
- try {
688
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
689
- wasm.__wbg_get_excelinfo_columns(retptr, this.__wbg_ptr);
690
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
691
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
692
- var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
693
- wasm.__wbindgen_free(r0, r1 * 4, 4);
694
- return v1;
695
- } finally {
696
- wasm.__wbindgen_add_to_stack_pointer(16);
697
- }
1643
+ }
1644
+
1645
+ const CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')
1646
+ ? { register: () => {}, unregister: () => {} }
1647
+ : new FinalizationRegistry(state => wasm.__wbindgen_destroy_closure(state.a, state.b));
1648
+
1649
+ function debugString(val) {
1650
+ // primitive types
1651
+ const type = typeof val;
1652
+ if (type == 'number' || type == 'boolean' || val == null) {
1653
+ return `${val}`;
698
1654
  }
699
- /**
700
- * @param {(ExcelColumnInfo)[]} arg0
701
- */
702
- set columns(arg0) {
703
- const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
704
- const len0 = WASM_VECTOR_LEN;
705
- wasm.__wbg_set_excelinfo_columns(this.__wbg_ptr, ptr0, len0);
1655
+ if (type == 'string') {
1656
+ return `"${val}"`;
706
1657
  }
707
- /**
708
- * @returns {string}
709
- */
710
- get author() {
711
- let deferred1_0;
712
- let deferred1_1;
713
- try {
714
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
715
- wasm.__wbg_get_excelinfo_author(retptr, this.__wbg_ptr);
716
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
717
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
718
- deferred1_0 = r0;
719
- deferred1_1 = r1;
720
- return getStringFromWasm0(r0, r1);
721
- } finally {
722
- wasm.__wbindgen_add_to_stack_pointer(16);
723
- wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
1658
+ if (type == 'symbol') {
1659
+ const description = val.description;
1660
+ if (description == null) {
1661
+ return 'Symbol';
1662
+ } else {
1663
+ return `Symbol(${description})`;
724
1664
  }
725
1665
  }
726
- /**
727
- * @param {string} arg0
728
- */
729
- set author(arg0) {
730
- const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
731
- const len0 = WASM_VECTOR_LEN;
732
- wasm.__wbg_set_excelinfo_author(this.__wbg_ptr, ptr0, len0);
1666
+ if (type == 'function') {
1667
+ const name = val.name;
1668
+ if (typeof name == 'string' && name.length > 0) {
1669
+ return `Function(${name})`;
1670
+ } else {
1671
+ return 'Function';
1672
+ }
733
1673
  }
734
- /**
735
- * @returns {string}
736
- */
737
- get create_time() {
738
- let deferred1_0;
739
- let deferred1_1;
1674
+ // objects
1675
+ if (Array.isArray(val)) {
1676
+ const length = val.length;
1677
+ let debug = '[';
1678
+ if (length > 0) {
1679
+ debug += debugString(val[0]);
1680
+ }
1681
+ for(let i = 1; i < length; i++) {
1682
+ debug += ', ' + debugString(val[i]);
1683
+ }
1684
+ debug += ']';
1685
+ return debug;
1686
+ }
1687
+ // Test for built-in
1688
+ const builtInMatches = /\[object ([^\]]+)\]/.exec(toString.call(val));
1689
+ let className;
1690
+ if (builtInMatches && builtInMatches.length > 1) {
1691
+ className = builtInMatches[1];
1692
+ } else {
1693
+ // Failed to match the standard '[object ClassName]'
1694
+ return toString.call(val);
1695
+ }
1696
+ if (className == 'Object') {
1697
+ // we're a user defined class or Object
1698
+ // JSON.stringify avoids problems with cycles, and is generally much
1699
+ // easier than looping through ownProperties of `val`.
740
1700
  try {
741
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
742
- wasm.__wbg_get_excelinfo_create_time(retptr, this.__wbg_ptr);
743
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
744
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
745
- deferred1_0 = r0;
746
- deferred1_1 = r1;
747
- return getStringFromWasm0(r0, r1);
748
- } finally {
749
- wasm.__wbindgen_add_to_stack_pointer(16);
750
- wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
1701
+ return 'Object(' + JSON.stringify(val) + ')';
1702
+ } catch (_) {
1703
+ return 'Object';
751
1704
  }
752
1705
  }
753
- /**
754
- * @param {string} arg0
755
- */
756
- set create_time(arg0) {
757
- const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
758
- const len0 = WASM_VECTOR_LEN;
759
- wasm.__wbg_set_excelinfo_create_time(this.__wbg_ptr, ptr0, len0);
1706
+ // errors
1707
+ if (val instanceof Error) {
1708
+ return `${val.name}: ${val.message}\n${val.stack}`;
760
1709
  }
761
- /**
762
- * @param {string} name
763
- * @param {string} sheet_name
764
- * @param {(ExcelColumnInfo)[]} columns
765
- * @param {string} author
766
- * @param {string} create_time
767
- */
768
- constructor(name, sheet_name, columns, author, create_time) {
769
- const ptr0 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
770
- const len0 = WASM_VECTOR_LEN;
771
- const ptr1 = passStringToWasm0(sheet_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
772
- const len1 = WASM_VECTOR_LEN;
773
- const ptr2 = passArrayJsValueToWasm0(columns, wasm.__wbindgen_malloc);
774
- const len2 = WASM_VECTOR_LEN;
775
- const ptr3 = passStringToWasm0(author, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
776
- const len3 = WASM_VECTOR_LEN;
777
- const ptr4 = passStringToWasm0(create_time, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
778
- const len4 = WASM_VECTOR_LEN;
779
- const ret = wasm.excelinfo_new(ptr0, len0, ptr1, len1, ptr2, len2, ptr3, len3, ptr4, len4);
780
- this.__wbg_ptr = ret >>> 0;
781
- ExcelInfoFinalization.register(this, this.__wbg_ptr, this);
782
- return this;
1710
+ // TODO we could test for more things here, like `Set`s and `Map`s.
1711
+ return className;
1712
+ }
1713
+
1714
+ function getArrayJsValueFromWasm0(ptr, len) {
1715
+ ptr = ptr >>> 0;
1716
+ const mem = getDataViewMemory0();
1717
+ const result = [];
1718
+ for (let i = ptr; i < ptr + 4 * len; i += 4) {
1719
+ result.push(wasm.__wbindgen_externrefs.get(mem.getUint32(i, true)));
783
1720
  }
1721
+ wasm.__externref_drop_slice(ptr, len);
1722
+ return result;
784
1723
  }
785
1724
 
786
- const ExcelRowDataFinalization = (typeof FinalizationRegistry === 'undefined')
787
- ? { register: () => {}, unregister: () => {} }
788
- : new FinalizationRegistry(ptr => wasm.__wbg_excelrowdata_free(ptr >>> 0, 1));
1725
+ function getArrayU8FromWasm0(ptr, len) {
1726
+ ptr = ptr >>> 0;
1727
+ return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
1728
+ }
789
1729
 
790
- export class ExcelRowData {
1730
+ let cachedDataViewMemory0 = null;
1731
+ function getDataViewMemory0() {
1732
+ if (cachedDataViewMemory0 === null || cachedDataViewMemory0.buffer.detached === true || (cachedDataViewMemory0.buffer.detached === undefined && cachedDataViewMemory0.buffer !== wasm.memory.buffer)) {
1733
+ cachedDataViewMemory0 = new DataView(wasm.memory.buffer);
1734
+ }
1735
+ return cachedDataViewMemory0;
1736
+ }
791
1737
 
792
- static __wrap(ptr) {
793
- ptr = ptr >>> 0;
794
- const obj = Object.create(ExcelRowData.prototype);
795
- obj.__wbg_ptr = ptr;
796
- ExcelRowDataFinalization.register(obj, obj.__wbg_ptr, obj);
797
- return obj;
1738
+ function getStringFromWasm0(ptr, len) {
1739
+ ptr = ptr >>> 0;
1740
+ return decodeText(ptr, len);
1741
+ }
1742
+
1743
+ let cachedUint8ArrayMemory0 = null;
1744
+ function getUint8ArrayMemory0() {
1745
+ if (cachedUint8ArrayMemory0 === null || cachedUint8ArrayMemory0.byteLength === 0) {
1746
+ cachedUint8ArrayMemory0 = new Uint8Array(wasm.memory.buffer);
798
1747
  }
1748
+ return cachedUint8ArrayMemory0;
1749
+ }
799
1750
 
800
- static __unwrap(jsValue) {
801
- if (!(jsValue instanceof ExcelRowData)) {
802
- return 0;
1751
+ function handleError(f, args) {
1752
+ try {
1753
+ return f.apply(this, args);
1754
+ } catch (e) {
1755
+ const idx = addToExternrefTable0(e);
1756
+ wasm.__wbindgen_exn_store(idx);
1757
+ }
1758
+ }
1759
+
1760
+ function isLikeNone(x) {
1761
+ return x === undefined || x === null;
1762
+ }
1763
+
1764
+ function makeMutClosure(arg0, arg1, f) {
1765
+ const state = { a: arg0, b: arg1, cnt: 1 };
1766
+ const real = (...args) => {
1767
+
1768
+ // First up with a closure we increment the internal reference
1769
+ // count. This ensures that the Rust closure environment won't
1770
+ // be deallocated while we're invoking it.
1771
+ state.cnt++;
1772
+ const a = state.a;
1773
+ state.a = 0;
1774
+ try {
1775
+ return f(a, state.b, ...args);
1776
+ } finally {
1777
+ state.a = a;
1778
+ real._wbg_cb_unref();
803
1779
  }
804
- return jsValue.__destroy_into_raw();
1780
+ };
1781
+ real._wbg_cb_unref = () => {
1782
+ if (--state.cnt === 0) {
1783
+ wasm.__wbindgen_destroy_closure(state.a, state.b);
1784
+ state.a = 0;
1785
+ CLOSURE_DTORS.unregister(state);
1786
+ }
1787
+ };
1788
+ CLOSURE_DTORS.register(real, state, state);
1789
+ return real;
1790
+ }
1791
+
1792
+ function passArray8ToWasm0(arg, malloc) {
1793
+ const ptr = malloc(arg.length * 1, 1) >>> 0;
1794
+ getUint8ArrayMemory0().set(arg, ptr / 1);
1795
+ WASM_VECTOR_LEN = arg.length;
1796
+ return ptr;
1797
+ }
1798
+
1799
+ function passArrayJsValueToWasm0(array, malloc) {
1800
+ const ptr = malloc(array.length * 4, 4) >>> 0;
1801
+ for (let i = 0; i < array.length; i++) {
1802
+ const add = addToExternrefTable0(array[i]);
1803
+ getDataViewMemory0().setUint32(ptr + 4 * i, add, true);
805
1804
  }
1805
+ WASM_VECTOR_LEN = array.length;
1806
+ return ptr;
1807
+ }
806
1808
 
807
- __destroy_into_raw() {
808
- const ptr = this.__wbg_ptr;
809
- this.__wbg_ptr = 0;
810
- ExcelRowDataFinalization.unregister(this);
1809
+ function passStringToWasm0(arg, malloc, realloc) {
1810
+ if (realloc === undefined) {
1811
+ const buf = cachedTextEncoder.encode(arg);
1812
+ const ptr = malloc(buf.length, 1) >>> 0;
1813
+ getUint8ArrayMemory0().subarray(ptr, ptr + buf.length).set(buf);
1814
+ WASM_VECTOR_LEN = buf.length;
811
1815
  return ptr;
812
1816
  }
813
1817
 
814
- free() {
815
- const ptr = this.__destroy_into_raw();
816
- wasm.__wbg_excelrowdata_free(ptr, 0);
1818
+ let len = arg.length;
1819
+ let ptr = malloc(len, 1) >>> 0;
1820
+
1821
+ const mem = getUint8ArrayMemory0();
1822
+
1823
+ let offset = 0;
1824
+
1825
+ for (; offset < len; offset++) {
1826
+ const code = arg.charCodeAt(offset);
1827
+ if (code > 0x7F) break;
1828
+ mem[ptr + offset] = code;
817
1829
  }
818
- /**
819
- * @returns {(ExcelColumnData)[]}
820
- */
821
- get columns() {
822
- try {
823
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
824
- wasm.__wbg_get_excelrowdata_columns(retptr, this.__wbg_ptr);
825
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
826
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
827
- var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
828
- wasm.__wbindgen_free(r0, r1 * 4, 4);
829
- return v1;
830
- } finally {
831
- wasm.__wbindgen_add_to_stack_pointer(16);
1830
+ if (offset !== len) {
1831
+ if (offset !== 0) {
1832
+ arg = arg.slice(offset);
832
1833
  }
1834
+ ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;
1835
+ const view = getUint8ArrayMemory0().subarray(ptr + offset, ptr + len);
1836
+ const ret = cachedTextEncoder.encodeInto(arg, view);
1837
+
1838
+ offset += ret.written;
1839
+ ptr = realloc(ptr, len, offset, 1) >>> 0;
833
1840
  }
834
- /**
835
- * @param {(ExcelColumnData)[]} arg0
836
- */
837
- set columns(arg0) {
838
- const ptr0 = passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
839
- const len0 = WASM_VECTOR_LEN;
840
- wasm.__wbg_set_excelrowdata_columns(this.__wbg_ptr, ptr0, len0);
841
- }
842
- /**
843
- * @param {(ExcelColumnData)[]} columns
844
- */
845
- constructor(columns) {
846
- const ptr0 = passArrayJsValueToWasm0(columns, wasm.__wbindgen_malloc);
847
- const len0 = WASM_VECTOR_LEN;
848
- const ret = wasm.excelrowdata_new(ptr0, len0);
849
- this.__wbg_ptr = ret >>> 0;
850
- ExcelRowDataFinalization.register(this, this.__wbg_ptr, this);
851
- return this;
1841
+
1842
+ WASM_VECTOR_LEN = offset;
1843
+ return ptr;
1844
+ }
1845
+
1846
+ function takeFromExternrefTable0(idx) {
1847
+ const value = wasm.__wbindgen_externrefs.get(idx);
1848
+ wasm.__externref_table_dealloc(idx);
1849
+ return value;
1850
+ }
1851
+
1852
+ let cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
1853
+ cachedTextDecoder.decode();
1854
+ const MAX_SAFARI_DECODE_BYTES = 2146435072;
1855
+ let numBytesDecoded = 0;
1856
+ function decodeText(ptr, len) {
1857
+ numBytesDecoded += len;
1858
+ if (numBytesDecoded >= MAX_SAFARI_DECODE_BYTES) {
1859
+ cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
1860
+ cachedTextDecoder.decode();
1861
+ numBytesDecoded = len;
852
1862
  }
1863
+ return cachedTextDecoder.decode(getUint8ArrayMemory0().subarray(ptr, ptr + len));
1864
+ }
1865
+
1866
+ const cachedTextEncoder = new TextEncoder();
1867
+
1868
+ if (!('encodeInto' in cachedTextEncoder)) {
1869
+ cachedTextEncoder.encodeInto = function (arg, view) {
1870
+ const buf = cachedTextEncoder.encode(arg);
1871
+ view.set(buf);
1872
+ return {
1873
+ read: arg.length,
1874
+ written: buf.length
1875
+ };
1876
+ };
1877
+ }
1878
+
1879
+ let WASM_VECTOR_LEN = 0;
1880
+
1881
+ let wasmModule, wasm;
1882
+ function __wbg_finalize_init(instance, module) {
1883
+ wasm = instance.exports;
1884
+ wasmModule = module;
1885
+ cachedDataViewMemory0 = null;
1886
+ cachedUint8ArrayMemory0 = null;
1887
+ wasm.__wbindgen_start();
1888
+ return wasm;
853
1889
  }
854
1890
 
855
1891
  async function __wbg_load(module, imports) {
@@ -857,105 +1893,41 @@ async function __wbg_load(module, imports) {
857
1893
  if (typeof WebAssembly.instantiateStreaming === 'function') {
858
1894
  try {
859
1895
  return await WebAssembly.instantiateStreaming(module, imports);
860
-
861
1896
  } catch (e) {
862
- if (module.headers.get('Content-Type') != 'application/wasm') {
1897
+ const validResponse = module.ok && expectedResponseType(module.type);
1898
+
1899
+ if (validResponse && module.headers.get('Content-Type') !== 'application/wasm') {
863
1900
  console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n", e);
864
1901
 
865
- } else {
866
- throw e;
867
- }
1902
+ } else { throw e; }
868
1903
  }
869
1904
  }
870
1905
 
871
1906
  const bytes = await module.arrayBuffer();
872
1907
  return await WebAssembly.instantiate(bytes, imports);
873
-
874
1908
  } else {
875
1909
  const instance = await WebAssembly.instantiate(module, imports);
876
1910
 
877
1911
  if (instance instanceof WebAssembly.Instance) {
878
1912
  return { instance, module };
879
-
880
1913
  } else {
881
1914
  return instance;
882
1915
  }
883
1916
  }
884
- }
885
-
886
- function __wbg_get_imports() {
887
- const imports = {};
888
- imports.wbg = {};
889
- imports.wbg.__wbg_excelcolumninfo_new = function(arg0) {
890
- const ret = ExcelColumnInfo.__wrap(arg0);
891
- return addHeapObject(ret);
892
- };
893
- imports.wbg.__wbg_excelcolumndata_new = function(arg0) {
894
- const ret = ExcelColumnData.__wrap(arg0);
895
- return addHeapObject(ret);
896
- };
897
- imports.wbg.__wbg_excelrowdata_new = function(arg0) {
898
- const ret = ExcelRowData.__wrap(arg0);
899
- return addHeapObject(ret);
900
- };
901
- imports.wbg.__wbg_excelcolumndata_unwrap = function(arg0) {
902
- const ret = ExcelColumnData.__unwrap(takeObject(arg0));
903
- return ret;
904
- };
905
- imports.wbg.__wbg_excelrowdata_unwrap = function(arg0) {
906
- const ret = ExcelRowData.__unwrap(takeObject(arg0));
907
- return ret;
908
- };
909
- imports.wbg.__wbg_excelcolumninfo_unwrap = function(arg0) {
910
- const ret = ExcelColumnInfo.__unwrap(takeObject(arg0));
911
- return ret;
912
- };
913
- imports.wbg.__wbindgen_object_drop_ref = function(arg0) {
914
- takeObject(arg0);
915
- };
916
- imports.wbg.__wbindgen_string_new = function(arg0, arg1) {
917
- const ret = getStringFromWasm0(arg0, arg1);
918
- return addHeapObject(ret);
919
- };
920
- imports.wbg.__wbg_now_70af4fe37a792251 = function() {
921
- const ret = Date.now();
922
- return ret;
923
- };
924
- imports.wbg.__wbindgen_string_get = function(arg0, arg1) {
925
- const obj = getObject(arg1);
926
- const ret = typeof(obj) === 'string' ? obj : undefined;
927
- var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
928
- var len1 = WASM_VECTOR_LEN;
929
- getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
930
- getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
931
- };
932
- imports.wbg.__wbindgen_throw = function(arg0, arg1) {
933
- throw new Error(getStringFromWasm0(arg0, arg1));
934
- };
935
-
936
- return imports;
937
- }
938
-
939
- function __wbg_init_memory(imports, memory) {
940
-
941
- }
942
-
943
- function __wbg_finalize_init(instance, module) {
944
- wasm = instance.exports;
945
- __wbg_init.__wbindgen_wasm_module = module;
946
- cachedDataViewMemory0 = null;
947
- cachedUint8ArrayMemory0 = null;
948
-
949
-
950
1917
 
951
- return wasm;
1918
+ function expectedResponseType(type) {
1919
+ switch (type) {
1920
+ case 'basic': case 'cors': case 'default': return true;
1921
+ }
1922
+ return false;
1923
+ }
952
1924
  }
953
1925
 
954
1926
  function initSync(module) {
955
1927
  if (wasm !== undefined) return wasm;
956
1928
 
957
1929
 
958
- if (typeof module !== 'undefined') {
1930
+ if (module !== undefined) {
959
1931
  if (Object.getPrototypeOf(module) === Object.prototype) {
960
1932
  ({module} = module)
961
1933
  } else {
@@ -964,15 +1936,10 @@ function initSync(module) {
964
1936
  }
965
1937
 
966
1938
  const imports = __wbg_get_imports();
967
-
968
- __wbg_init_memory(imports);
969
-
970
1939
  if (!(module instanceof WebAssembly.Module)) {
971
1940
  module = new WebAssembly.Module(module);
972
1941
  }
973
-
974
1942
  const instance = new WebAssembly.Instance(module, imports);
975
-
976
1943
  return __wbg_finalize_init(instance, module);
977
1944
  }
978
1945
 
@@ -980,7 +1947,7 @@ async function __wbg_init(module_or_path) {
980
1947
  if (wasm !== undefined) return wasm;
981
1948
 
982
1949
 
983
- if (typeof module_or_path !== 'undefined') {
1950
+ if (module_or_path !== undefined) {
984
1951
  if (Object.getPrototypeOf(module_or_path) === Object.prototype) {
985
1952
  ({module_or_path} = module_or_path)
986
1953
  } else {
@@ -988,7 +1955,7 @@ async function __wbg_init(module_or_path) {
988
1955
  }
989
1956
  }
990
1957
 
991
- if (typeof module_or_path === 'undefined') {
1958
+ if (module_or_path === undefined) {
992
1959
  module_or_path = new URL('imexport_wasm_bg.wasm', import.meta.url);
993
1960
  }
994
1961
  const imports = __wbg_get_imports();
@@ -997,12 +1964,9 @@ async function __wbg_init(module_or_path) {
997
1964
  module_or_path = fetch(module_or_path);
998
1965
  }
999
1966
 
1000
- __wbg_init_memory(imports);
1001
-
1002
1967
  const { instance, module } = await __wbg_load(await module_or_path, imports);
1003
1968
 
1004
1969
  return __wbg_finalize_init(instance, module);
1005
1970
  }
1006
1971
 
1007
- export { initSync };
1008
- export default __wbg_init;
1972
+ export { initSync, __wbg_init as default };