@kreuzberg/html-to-markdown-wasm 3.1.0 → 3.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/html_to_markdown_wasm.d.ts +481 -33
- package/dist/html_to_markdown_wasm_bg.js +4207 -308
- package/dist/html_to_markdown_wasm_bg.wasm +0 -0
- package/dist/html_to_markdown_wasm_bg.wasm.d.ts +378 -4
- package/dist/package.json +2 -12
- package/dist-node/html_to_markdown_wasm.d.ts +481 -33
- package/dist-node/html_to_markdown_wasm.js +4244 -311
- package/dist-node/html_to_markdown_wasm_bg.wasm +0 -0
- package/dist-node/html_to_markdown_wasm_bg.wasm.d.ts +378 -4
- package/dist-node/package.json +3 -13
- package/dist-web/html_to_markdown_wasm.d.ts +859 -37
- package/dist-web/html_to_markdown_wasm.js +4208 -310
- package/dist-web/html_to_markdown_wasm_bg.wasm +0 -0
- package/dist-web/html_to_markdown_wasm_bg.wasm.d.ts +378 -4
- package/dist-web/package.json +2 -12
- package/package.json +3 -3
- package/LICENSE +0 -21
- package/README.md +0 -586
- package/dist/LICENSE +0 -21
- package/dist/README.md +0 -154
- package/dist-node/LICENSE +0 -21
- package/dist-node/README.md +0 -154
- package/dist-web/LICENSE +0 -21
- package/dist-web/README.md +0 -154
|
@@ -5,34 +5,4084 @@
|
|
|
5
5
|
/* @ts-self-types="./html_to_markdown_wasm.d.ts" */
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
|
-
*
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
*
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
8
|
+
* @enum {0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8}
|
|
9
|
+
*/
|
|
10
|
+
const WasmAnnotationKind = Object.freeze({
|
|
11
|
+
Bold: 0, "0": "Bold",
|
|
12
|
+
Italic: 1, "1": "Italic",
|
|
13
|
+
Underline: 2, "2": "Underline",
|
|
14
|
+
Strikethrough: 3, "3": "Strikethrough",
|
|
15
|
+
Code: 4, "4": "Code",
|
|
16
|
+
Subscript: 5, "5": "Subscript",
|
|
17
|
+
Superscript: 6, "6": "Superscript",
|
|
18
|
+
Highlight: 7, "7": "Highlight",
|
|
19
|
+
Link: 8, "8": "Link",
|
|
20
|
+
});
|
|
21
|
+
exports.WasmAnnotationKind = WasmAnnotationKind;
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* @enum {0 | 1 | 2}
|
|
25
|
+
*/
|
|
26
|
+
const WasmCodeBlockStyle = Object.freeze({
|
|
27
|
+
Indented: 0, "0": "Indented",
|
|
28
|
+
Backticks: 1, "1": "Backticks",
|
|
29
|
+
Tildes: 2, "2": "Tildes",
|
|
30
|
+
});
|
|
31
|
+
exports.WasmCodeBlockStyle = WasmCodeBlockStyle;
|
|
32
|
+
|
|
33
|
+
class WasmConversionOptions {
|
|
34
|
+
static __wrap(ptr) {
|
|
35
|
+
ptr = ptr >>> 0;
|
|
36
|
+
const obj = Object.create(WasmConversionOptions.prototype);
|
|
37
|
+
obj.__wbg_ptr = ptr;
|
|
38
|
+
WasmConversionOptionsFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
39
|
+
return obj;
|
|
40
|
+
}
|
|
41
|
+
__destroy_into_raw() {
|
|
42
|
+
const ptr = this.__wbg_ptr;
|
|
43
|
+
this.__wbg_ptr = 0;
|
|
44
|
+
WasmConversionOptionsFinalization.unregister(this);
|
|
45
|
+
return ptr;
|
|
46
|
+
}
|
|
47
|
+
free() {
|
|
48
|
+
const ptr = this.__destroy_into_raw();
|
|
49
|
+
wasm.__wbg_wasmconversionoptions_free(ptr, 0);
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* @returns {boolean}
|
|
53
|
+
*/
|
|
54
|
+
get autolinks() {
|
|
55
|
+
const ret = wasm.wasmconversionoptions_autolinks(this.__wbg_ptr);
|
|
56
|
+
return ret !== 0;
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* @returns {boolean}
|
|
60
|
+
*/
|
|
61
|
+
get brInTables() {
|
|
62
|
+
const ret = wasm.wasmconversionoptions_brInTables(this.__wbg_ptr);
|
|
63
|
+
return ret !== 0;
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* @returns {WasmConversionOptionsBuilder}
|
|
67
|
+
*/
|
|
68
|
+
static builder() {
|
|
69
|
+
const ret = wasm.wasmconversionoptions_builder();
|
|
70
|
+
return WasmConversionOptionsBuilder.__wrap(ret);
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* @returns {string}
|
|
74
|
+
*/
|
|
75
|
+
get bullets() {
|
|
76
|
+
let deferred1_0;
|
|
77
|
+
let deferred1_1;
|
|
78
|
+
try {
|
|
79
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
80
|
+
wasm.wasmconversionoptions_bullets(retptr, this.__wbg_ptr);
|
|
81
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
82
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
83
|
+
deferred1_0 = r0;
|
|
84
|
+
deferred1_1 = r1;
|
|
85
|
+
return getStringFromWasm0(r0, r1);
|
|
86
|
+
} finally {
|
|
87
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
88
|
+
wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
/**
|
|
92
|
+
* @returns {boolean}
|
|
93
|
+
*/
|
|
94
|
+
get captureSvg() {
|
|
95
|
+
const ret = wasm.wasmconversionoptions_captureSvg(this.__wbg_ptr);
|
|
96
|
+
return ret !== 0;
|
|
97
|
+
}
|
|
98
|
+
/**
|
|
99
|
+
* @returns {WasmCodeBlockStyle}
|
|
100
|
+
*/
|
|
101
|
+
get codeBlockStyle() {
|
|
102
|
+
const ret = wasm.wasmconversionoptions_codeBlockStyle(this.__wbg_ptr);
|
|
103
|
+
return ret;
|
|
104
|
+
}
|
|
105
|
+
/**
|
|
106
|
+
* @returns {string}
|
|
107
|
+
*/
|
|
108
|
+
get codeLanguage() {
|
|
109
|
+
let deferred1_0;
|
|
110
|
+
let deferred1_1;
|
|
111
|
+
try {
|
|
112
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
113
|
+
wasm.wasmconversionoptions_codeLanguage(retptr, this.__wbg_ptr);
|
|
114
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
115
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
116
|
+
deferred1_0 = r0;
|
|
117
|
+
deferred1_1 = r1;
|
|
118
|
+
return getStringFromWasm0(r0, r1);
|
|
119
|
+
} finally {
|
|
120
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
121
|
+
wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* @returns {boolean}
|
|
126
|
+
*/
|
|
127
|
+
get convertAsInline() {
|
|
128
|
+
const ret = wasm.wasmconversionoptions_convertAsInline(this.__wbg_ptr);
|
|
129
|
+
return ret !== 0;
|
|
130
|
+
}
|
|
131
|
+
/**
|
|
132
|
+
* @returns {boolean}
|
|
133
|
+
*/
|
|
134
|
+
get debug() {
|
|
135
|
+
const ret = wasm.wasmconversionoptions_debug(this.__wbg_ptr);
|
|
136
|
+
return ret !== 0;
|
|
137
|
+
}
|
|
138
|
+
/**
|
|
139
|
+
* @returns {WasmConversionOptions}
|
|
140
|
+
*/
|
|
141
|
+
static default() {
|
|
142
|
+
const ret = wasm.wasmconversionoptions_default();
|
|
143
|
+
return WasmConversionOptions.__wrap(ret);
|
|
144
|
+
}
|
|
145
|
+
/**
|
|
146
|
+
* @returns {boolean}
|
|
147
|
+
*/
|
|
148
|
+
get defaultTitle() {
|
|
149
|
+
const ret = wasm.wasmconversionoptions_defaultTitle(this.__wbg_ptr);
|
|
150
|
+
return ret !== 0;
|
|
151
|
+
}
|
|
152
|
+
/**
|
|
153
|
+
* @returns {string}
|
|
154
|
+
*/
|
|
155
|
+
get encoding() {
|
|
156
|
+
let deferred1_0;
|
|
157
|
+
let deferred1_1;
|
|
158
|
+
try {
|
|
159
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
160
|
+
wasm.wasmconversionoptions_encoding(retptr, this.__wbg_ptr);
|
|
161
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
162
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
163
|
+
deferred1_0 = r0;
|
|
164
|
+
deferred1_1 = r1;
|
|
165
|
+
return getStringFromWasm0(r0, r1);
|
|
166
|
+
} finally {
|
|
167
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
168
|
+
wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
/**
|
|
172
|
+
* @returns {boolean}
|
|
173
|
+
*/
|
|
174
|
+
get escapeAscii() {
|
|
175
|
+
const ret = wasm.wasmconversionoptions_escapeAscii(this.__wbg_ptr);
|
|
176
|
+
return ret !== 0;
|
|
177
|
+
}
|
|
178
|
+
/**
|
|
179
|
+
* @returns {boolean}
|
|
180
|
+
*/
|
|
181
|
+
get escapeAsterisks() {
|
|
182
|
+
const ret = wasm.wasmconversionoptions_escapeAsterisks(this.__wbg_ptr);
|
|
183
|
+
return ret !== 0;
|
|
184
|
+
}
|
|
185
|
+
/**
|
|
186
|
+
* @returns {boolean}
|
|
187
|
+
*/
|
|
188
|
+
get escapeMisc() {
|
|
189
|
+
const ret = wasm.wasmconversionoptions_escapeMisc(this.__wbg_ptr);
|
|
190
|
+
return ret !== 0;
|
|
191
|
+
}
|
|
192
|
+
/**
|
|
193
|
+
* @returns {boolean}
|
|
194
|
+
*/
|
|
195
|
+
get escapeUnderscores() {
|
|
196
|
+
const ret = wasm.wasmconversionoptions_escapeUnderscores(this.__wbg_ptr);
|
|
197
|
+
return ret !== 0;
|
|
198
|
+
}
|
|
199
|
+
/**
|
|
200
|
+
* @returns {boolean}
|
|
201
|
+
*/
|
|
202
|
+
get extractImages() {
|
|
203
|
+
const ret = wasm.wasmconversionoptions_extractImages(this.__wbg_ptr);
|
|
204
|
+
return ret !== 0;
|
|
205
|
+
}
|
|
206
|
+
/**
|
|
207
|
+
* @returns {boolean}
|
|
208
|
+
*/
|
|
209
|
+
get extractMetadata() {
|
|
210
|
+
const ret = wasm.wasmconversionoptions_extractMetadata(this.__wbg_ptr);
|
|
211
|
+
return ret !== 0;
|
|
212
|
+
}
|
|
213
|
+
/**
|
|
214
|
+
* @returns {WasmHeadingStyle}
|
|
215
|
+
*/
|
|
216
|
+
get headingStyle() {
|
|
217
|
+
const ret = wasm.wasmconversionoptions_headingStyle(this.__wbg_ptr);
|
|
218
|
+
return ret;
|
|
219
|
+
}
|
|
220
|
+
/**
|
|
221
|
+
* @returns {WasmHighlightStyle}
|
|
222
|
+
*/
|
|
223
|
+
get highlightStyle() {
|
|
224
|
+
const ret = wasm.wasmconversionoptions_highlightStyle(this.__wbg_ptr);
|
|
225
|
+
return ret;
|
|
226
|
+
}
|
|
227
|
+
/**
|
|
228
|
+
* @returns {boolean}
|
|
229
|
+
*/
|
|
230
|
+
get includeDocumentStructure() {
|
|
231
|
+
const ret = wasm.wasmconversionoptions_includeDocumentStructure(this.__wbg_ptr);
|
|
232
|
+
return ret !== 0;
|
|
233
|
+
}
|
|
234
|
+
/**
|
|
235
|
+
* @returns {boolean}
|
|
236
|
+
*/
|
|
237
|
+
get inferDimensions() {
|
|
238
|
+
const ret = wasm.wasmconversionoptions_inferDimensions(this.__wbg_ptr);
|
|
239
|
+
return ret !== 0;
|
|
240
|
+
}
|
|
241
|
+
/**
|
|
242
|
+
* @returns {string[]}
|
|
243
|
+
*/
|
|
244
|
+
get keepInlineImagesIn() {
|
|
245
|
+
try {
|
|
246
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
247
|
+
wasm.wasmconversionoptions_keepInlineImagesIn(retptr, this.__wbg_ptr);
|
|
248
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
249
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
250
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
251
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
252
|
+
return v1;
|
|
253
|
+
} finally {
|
|
254
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
255
|
+
}
|
|
256
|
+
}
|
|
257
|
+
/**
|
|
258
|
+
* @returns {WasmLinkStyle}
|
|
259
|
+
*/
|
|
260
|
+
get linkStyle() {
|
|
261
|
+
const ret = wasm.wasmconversionoptions_linkStyle(this.__wbg_ptr);
|
|
262
|
+
return ret;
|
|
263
|
+
}
|
|
264
|
+
/**
|
|
265
|
+
* @returns {WasmListIndentType}
|
|
266
|
+
*/
|
|
267
|
+
get listIndentType() {
|
|
268
|
+
const ret = wasm.wasmconversionoptions_listIndentType(this.__wbg_ptr);
|
|
269
|
+
return ret;
|
|
270
|
+
}
|
|
271
|
+
/**
|
|
272
|
+
* @returns {number}
|
|
273
|
+
*/
|
|
274
|
+
get listIndentWidth() {
|
|
275
|
+
const ret = wasm.wasmconversionoptions_listIndentWidth(this.__wbg_ptr);
|
|
276
|
+
return ret >>> 0;
|
|
277
|
+
}
|
|
278
|
+
/**
|
|
279
|
+
* @returns {bigint}
|
|
280
|
+
*/
|
|
281
|
+
get maxImageSize() {
|
|
282
|
+
const ret = wasm.wasmconversionoptions_maxImageSize(this.__wbg_ptr);
|
|
283
|
+
return BigInt.asUintN(64, ret);
|
|
284
|
+
}
|
|
285
|
+
/**
|
|
286
|
+
* @param {WasmHeadingStyle | null} [heading_style]
|
|
287
|
+
* @param {WasmListIndentType | null} [list_indent_type]
|
|
288
|
+
* @param {number | null} [list_indent_width]
|
|
289
|
+
* @param {string | null} [bullets]
|
|
290
|
+
* @param {string | null} [strong_em_symbol]
|
|
291
|
+
* @param {boolean | null} [escape_asterisks]
|
|
292
|
+
* @param {boolean | null} [escape_underscores]
|
|
293
|
+
* @param {boolean | null} [escape_misc]
|
|
294
|
+
* @param {boolean | null} [escape_ascii]
|
|
295
|
+
* @param {string | null} [code_language]
|
|
296
|
+
* @param {boolean | null} [autolinks]
|
|
297
|
+
* @param {boolean | null} [default_title]
|
|
298
|
+
* @param {boolean | null} [br_in_tables]
|
|
299
|
+
* @param {WasmHighlightStyle | null} [highlight_style]
|
|
300
|
+
* @param {boolean | null} [extract_metadata]
|
|
301
|
+
* @param {WasmWhitespaceMode | null} [whitespace_mode]
|
|
302
|
+
* @param {boolean | null} [strip_newlines]
|
|
303
|
+
* @param {boolean | null} [wrap]
|
|
304
|
+
* @param {number | null} [wrap_width]
|
|
305
|
+
* @param {boolean | null} [convert_as_inline]
|
|
306
|
+
* @param {string | null} [sub_symbol]
|
|
307
|
+
* @param {string | null} [sup_symbol]
|
|
308
|
+
* @param {WasmNewlineStyle | null} [newline_style]
|
|
309
|
+
* @param {WasmCodeBlockStyle | null} [code_block_style]
|
|
310
|
+
* @param {string[] | null} [keep_inline_images_in]
|
|
311
|
+
* @param {WasmPreprocessingOptions | null} [preprocessing]
|
|
312
|
+
* @param {string | null} [encoding]
|
|
313
|
+
* @param {boolean | null} [debug]
|
|
314
|
+
* @param {string[] | null} [strip_tags]
|
|
315
|
+
* @param {string[] | null} [preserve_tags]
|
|
316
|
+
* @param {boolean | null} [skip_images]
|
|
317
|
+
* @param {WasmLinkStyle | null} [link_style]
|
|
318
|
+
* @param {WasmOutputFormat | null} [output_format]
|
|
319
|
+
* @param {boolean | null} [include_document_structure]
|
|
320
|
+
* @param {boolean | null} [extract_images]
|
|
321
|
+
* @param {bigint | null} [max_image_size]
|
|
322
|
+
* @param {boolean | null} [capture_svg]
|
|
323
|
+
* @param {boolean | null} [infer_dimensions]
|
|
324
|
+
*/
|
|
325
|
+
constructor(heading_style, list_indent_type, list_indent_width, bullets, strong_em_symbol, escape_asterisks, escape_underscores, escape_misc, escape_ascii, code_language, autolinks, default_title, br_in_tables, highlight_style, extract_metadata, whitespace_mode, strip_newlines, wrap, wrap_width, convert_as_inline, sub_symbol, sup_symbol, newline_style, code_block_style, keep_inline_images_in, preprocessing, encoding, debug, strip_tags, preserve_tags, skip_images, link_style, output_format, include_document_structure, extract_images, max_image_size, capture_svg, infer_dimensions) {
|
|
326
|
+
var ptr0 = isLikeNone(bullets) ? 0 : passStringToWasm0(bullets, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
327
|
+
var len0 = WASM_VECTOR_LEN;
|
|
328
|
+
var ptr1 = isLikeNone(strong_em_symbol) ? 0 : passStringToWasm0(strong_em_symbol, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
329
|
+
var len1 = WASM_VECTOR_LEN;
|
|
330
|
+
var ptr2 = isLikeNone(code_language) ? 0 : passStringToWasm0(code_language, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
331
|
+
var len2 = WASM_VECTOR_LEN;
|
|
332
|
+
var ptr3 = isLikeNone(sub_symbol) ? 0 : passStringToWasm0(sub_symbol, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
333
|
+
var len3 = WASM_VECTOR_LEN;
|
|
334
|
+
var ptr4 = isLikeNone(sup_symbol) ? 0 : passStringToWasm0(sup_symbol, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
335
|
+
var len4 = WASM_VECTOR_LEN;
|
|
336
|
+
var ptr5 = isLikeNone(keep_inline_images_in) ? 0 : passArrayJsValueToWasm0(keep_inline_images_in, wasm.__wbindgen_export);
|
|
337
|
+
var len5 = WASM_VECTOR_LEN;
|
|
338
|
+
let ptr6 = 0;
|
|
339
|
+
if (!isLikeNone(preprocessing)) {
|
|
340
|
+
_assertClass(preprocessing, WasmPreprocessingOptions);
|
|
341
|
+
ptr6 = preprocessing.__destroy_into_raw();
|
|
342
|
+
}
|
|
343
|
+
var ptr7 = isLikeNone(encoding) ? 0 : passStringToWasm0(encoding, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
344
|
+
var len7 = WASM_VECTOR_LEN;
|
|
345
|
+
var ptr8 = isLikeNone(strip_tags) ? 0 : passArrayJsValueToWasm0(strip_tags, wasm.__wbindgen_export);
|
|
346
|
+
var len8 = WASM_VECTOR_LEN;
|
|
347
|
+
var ptr9 = isLikeNone(preserve_tags) ? 0 : passArrayJsValueToWasm0(preserve_tags, wasm.__wbindgen_export);
|
|
348
|
+
var len9 = WASM_VECTOR_LEN;
|
|
349
|
+
const ret = wasm.wasmconversionoptions_new(isLikeNone(heading_style) ? 3 : heading_style, isLikeNone(list_indent_type) ? 2 : list_indent_type, isLikeNone(list_indent_width) ? 0x100000001 : (list_indent_width) >>> 0, ptr0, len0, ptr1, len1, isLikeNone(escape_asterisks) ? 0xFFFFFF : escape_asterisks ? 1 : 0, isLikeNone(escape_underscores) ? 0xFFFFFF : escape_underscores ? 1 : 0, isLikeNone(escape_misc) ? 0xFFFFFF : escape_misc ? 1 : 0, isLikeNone(escape_ascii) ? 0xFFFFFF : escape_ascii ? 1 : 0, ptr2, len2, isLikeNone(autolinks) ? 0xFFFFFF : autolinks ? 1 : 0, isLikeNone(default_title) ? 0xFFFFFF : default_title ? 1 : 0, isLikeNone(br_in_tables) ? 0xFFFFFF : br_in_tables ? 1 : 0, isLikeNone(highlight_style) ? 4 : highlight_style, isLikeNone(extract_metadata) ? 0xFFFFFF : extract_metadata ? 1 : 0, isLikeNone(whitespace_mode) ? 2 : whitespace_mode, isLikeNone(strip_newlines) ? 0xFFFFFF : strip_newlines ? 1 : 0, isLikeNone(wrap) ? 0xFFFFFF : wrap ? 1 : 0, isLikeNone(wrap_width) ? 0x100000001 : (wrap_width) >>> 0, isLikeNone(convert_as_inline) ? 0xFFFFFF : convert_as_inline ? 1 : 0, ptr3, len3, ptr4, len4, isLikeNone(newline_style) ? 2 : newline_style, isLikeNone(code_block_style) ? 3 : code_block_style, ptr5, len5, ptr6, ptr7, len7, isLikeNone(debug) ? 0xFFFFFF : debug ? 1 : 0, ptr8, len8, ptr9, len9, isLikeNone(skip_images) ? 0xFFFFFF : skip_images ? 1 : 0, isLikeNone(link_style) ? 2 : link_style, isLikeNone(output_format) ? 3 : output_format, isLikeNone(include_document_structure) ? 0xFFFFFF : include_document_structure ? 1 : 0, isLikeNone(extract_images) ? 0xFFFFFF : extract_images ? 1 : 0, !isLikeNone(max_image_size), isLikeNone(max_image_size) ? BigInt(0) : max_image_size, isLikeNone(capture_svg) ? 0xFFFFFF : capture_svg ? 1 : 0, isLikeNone(infer_dimensions) ? 0xFFFFFF : infer_dimensions ? 1 : 0);
|
|
350
|
+
this.__wbg_ptr = ret >>> 0;
|
|
351
|
+
WasmConversionOptionsFinalization.register(this, this.__wbg_ptr, this);
|
|
352
|
+
return this;
|
|
353
|
+
}
|
|
354
|
+
/**
|
|
355
|
+
* @returns {WasmNewlineStyle}
|
|
356
|
+
*/
|
|
357
|
+
get newlineStyle() {
|
|
358
|
+
const ret = wasm.wasmconversionoptions_newlineStyle(this.__wbg_ptr);
|
|
359
|
+
return ret;
|
|
360
|
+
}
|
|
361
|
+
/**
|
|
362
|
+
* @returns {WasmOutputFormat}
|
|
363
|
+
*/
|
|
364
|
+
get outputFormat() {
|
|
365
|
+
const ret = wasm.wasmconversionoptions_outputFormat(this.__wbg_ptr);
|
|
366
|
+
return ret;
|
|
367
|
+
}
|
|
368
|
+
/**
|
|
369
|
+
* @returns {WasmPreprocessingOptions}
|
|
370
|
+
*/
|
|
371
|
+
get preprocessing() {
|
|
372
|
+
const ret = wasm.wasmconversionoptions_preprocessing(this.__wbg_ptr);
|
|
373
|
+
return WasmPreprocessingOptions.__wrap(ret);
|
|
374
|
+
}
|
|
375
|
+
/**
|
|
376
|
+
* @returns {string[]}
|
|
377
|
+
*/
|
|
378
|
+
get preserveTags() {
|
|
379
|
+
try {
|
|
380
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
381
|
+
wasm.wasmconversionoptions_preserveTags(retptr, this.__wbg_ptr);
|
|
382
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
383
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
384
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
385
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
386
|
+
return v1;
|
|
387
|
+
} finally {
|
|
388
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
/**
|
|
392
|
+
* @param {boolean} value
|
|
393
|
+
*/
|
|
394
|
+
set autolinks(value) {
|
|
395
|
+
wasm.wasmconversionoptions_set_autolinks(this.__wbg_ptr, value);
|
|
396
|
+
}
|
|
397
|
+
/**
|
|
398
|
+
* @param {boolean} value
|
|
399
|
+
*/
|
|
400
|
+
set brInTables(value) {
|
|
401
|
+
wasm.wasmconversionoptions_set_brInTables(this.__wbg_ptr, value);
|
|
402
|
+
}
|
|
403
|
+
/**
|
|
404
|
+
* @param {string} value
|
|
405
|
+
*/
|
|
406
|
+
set bullets(value) {
|
|
407
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
408
|
+
const len0 = WASM_VECTOR_LEN;
|
|
409
|
+
wasm.wasmconversionoptions_set_bullets(this.__wbg_ptr, ptr0, len0);
|
|
410
|
+
}
|
|
411
|
+
/**
|
|
412
|
+
* @param {boolean} value
|
|
413
|
+
*/
|
|
414
|
+
set captureSvg(value) {
|
|
415
|
+
wasm.wasmconversionoptions_set_captureSvg(this.__wbg_ptr, value);
|
|
416
|
+
}
|
|
417
|
+
/**
|
|
418
|
+
* @param {WasmCodeBlockStyle} value
|
|
419
|
+
*/
|
|
420
|
+
set codeBlockStyle(value) {
|
|
421
|
+
wasm.wasmconversionoptions_set_codeBlockStyle(this.__wbg_ptr, value);
|
|
422
|
+
}
|
|
423
|
+
/**
|
|
424
|
+
* @param {string} value
|
|
425
|
+
*/
|
|
426
|
+
set codeLanguage(value) {
|
|
427
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
428
|
+
const len0 = WASM_VECTOR_LEN;
|
|
429
|
+
wasm.wasmconversionoptions_set_codeLanguage(this.__wbg_ptr, ptr0, len0);
|
|
430
|
+
}
|
|
431
|
+
/**
|
|
432
|
+
* @param {boolean} value
|
|
433
|
+
*/
|
|
434
|
+
set convertAsInline(value) {
|
|
435
|
+
wasm.wasmconversionoptions_set_convertAsInline(this.__wbg_ptr, value);
|
|
436
|
+
}
|
|
437
|
+
/**
|
|
438
|
+
* @param {boolean} value
|
|
439
|
+
*/
|
|
440
|
+
set debug(value) {
|
|
441
|
+
wasm.wasmconversionoptions_set_debug(this.__wbg_ptr, value);
|
|
442
|
+
}
|
|
443
|
+
/**
|
|
444
|
+
* @param {boolean} value
|
|
445
|
+
*/
|
|
446
|
+
set defaultTitle(value) {
|
|
447
|
+
wasm.wasmconversionoptions_set_defaultTitle(this.__wbg_ptr, value);
|
|
448
|
+
}
|
|
449
|
+
/**
|
|
450
|
+
* @param {string} value
|
|
451
|
+
*/
|
|
452
|
+
set encoding(value) {
|
|
453
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
454
|
+
const len0 = WASM_VECTOR_LEN;
|
|
455
|
+
wasm.wasmconversionoptions_set_encoding(this.__wbg_ptr, ptr0, len0);
|
|
456
|
+
}
|
|
457
|
+
/**
|
|
458
|
+
* @param {boolean} value
|
|
459
|
+
*/
|
|
460
|
+
set escapeAscii(value) {
|
|
461
|
+
wasm.wasmconversionoptions_set_escapeAscii(this.__wbg_ptr, value);
|
|
462
|
+
}
|
|
463
|
+
/**
|
|
464
|
+
* @param {boolean} value
|
|
465
|
+
*/
|
|
466
|
+
set escapeAsterisks(value) {
|
|
467
|
+
wasm.wasmconversionoptions_set_escapeAsterisks(this.__wbg_ptr, value);
|
|
468
|
+
}
|
|
469
|
+
/**
|
|
470
|
+
* @param {boolean} value
|
|
471
|
+
*/
|
|
472
|
+
set escapeMisc(value) {
|
|
473
|
+
wasm.wasmconversionoptions_set_escapeMisc(this.__wbg_ptr, value);
|
|
474
|
+
}
|
|
475
|
+
/**
|
|
476
|
+
* @param {boolean} value
|
|
477
|
+
*/
|
|
478
|
+
set escapeUnderscores(value) {
|
|
479
|
+
wasm.wasmconversionoptions_set_escapeUnderscores(this.__wbg_ptr, value);
|
|
480
|
+
}
|
|
481
|
+
/**
|
|
482
|
+
* @param {boolean} value
|
|
483
|
+
*/
|
|
484
|
+
set extractImages(value) {
|
|
485
|
+
wasm.wasmconversionoptions_set_extractImages(this.__wbg_ptr, value);
|
|
486
|
+
}
|
|
487
|
+
/**
|
|
488
|
+
* @param {boolean} value
|
|
489
|
+
*/
|
|
490
|
+
set extractMetadata(value) {
|
|
491
|
+
wasm.wasmconversionoptions_set_extractMetadata(this.__wbg_ptr, value);
|
|
492
|
+
}
|
|
493
|
+
/**
|
|
494
|
+
* @param {WasmHeadingStyle} value
|
|
495
|
+
*/
|
|
496
|
+
set headingStyle(value) {
|
|
497
|
+
wasm.wasmconversionoptions_set_headingStyle(this.__wbg_ptr, value);
|
|
498
|
+
}
|
|
499
|
+
/**
|
|
500
|
+
* @param {WasmHighlightStyle} value
|
|
501
|
+
*/
|
|
502
|
+
set highlightStyle(value) {
|
|
503
|
+
wasm.wasmconversionoptions_set_highlightStyle(this.__wbg_ptr, value);
|
|
504
|
+
}
|
|
505
|
+
/**
|
|
506
|
+
* @param {boolean} value
|
|
507
|
+
*/
|
|
508
|
+
set includeDocumentStructure(value) {
|
|
509
|
+
wasm.wasmconversionoptions_set_includeDocumentStructure(this.__wbg_ptr, value);
|
|
510
|
+
}
|
|
511
|
+
/**
|
|
512
|
+
* @param {boolean} value
|
|
513
|
+
*/
|
|
514
|
+
set inferDimensions(value) {
|
|
515
|
+
wasm.wasmconversionoptions_set_inferDimensions(this.__wbg_ptr, value);
|
|
516
|
+
}
|
|
517
|
+
/**
|
|
518
|
+
* @param {string[]} value
|
|
519
|
+
*/
|
|
520
|
+
set keepInlineImagesIn(value) {
|
|
521
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
522
|
+
const len0 = WASM_VECTOR_LEN;
|
|
523
|
+
wasm.wasmconversionoptions_set_keepInlineImagesIn(this.__wbg_ptr, ptr0, len0);
|
|
524
|
+
}
|
|
525
|
+
/**
|
|
526
|
+
* @param {WasmLinkStyle} value
|
|
527
|
+
*/
|
|
528
|
+
set linkStyle(value) {
|
|
529
|
+
wasm.wasmconversionoptions_set_linkStyle(this.__wbg_ptr, value);
|
|
530
|
+
}
|
|
531
|
+
/**
|
|
532
|
+
* @param {WasmListIndentType} value
|
|
533
|
+
*/
|
|
534
|
+
set listIndentType(value) {
|
|
535
|
+
wasm.wasmconversionoptions_set_listIndentType(this.__wbg_ptr, value);
|
|
536
|
+
}
|
|
537
|
+
/**
|
|
538
|
+
* @param {number} value
|
|
539
|
+
*/
|
|
540
|
+
set listIndentWidth(value) {
|
|
541
|
+
wasm.wasmconversionoptions_set_listIndentWidth(this.__wbg_ptr, value);
|
|
542
|
+
}
|
|
543
|
+
/**
|
|
544
|
+
* @param {bigint} value
|
|
545
|
+
*/
|
|
546
|
+
set maxImageSize(value) {
|
|
547
|
+
wasm.wasmconversionoptions_set_maxImageSize(this.__wbg_ptr, value);
|
|
548
|
+
}
|
|
549
|
+
/**
|
|
550
|
+
* @param {WasmNewlineStyle} value
|
|
551
|
+
*/
|
|
552
|
+
set newlineStyle(value) {
|
|
553
|
+
wasm.wasmconversionoptions_set_newlineStyle(this.__wbg_ptr, value);
|
|
554
|
+
}
|
|
555
|
+
/**
|
|
556
|
+
* @param {WasmOutputFormat} value
|
|
557
|
+
*/
|
|
558
|
+
set outputFormat(value) {
|
|
559
|
+
wasm.wasmconversionoptions_set_outputFormat(this.__wbg_ptr, value);
|
|
560
|
+
}
|
|
561
|
+
/**
|
|
562
|
+
* @param {WasmPreprocessingOptions} value
|
|
563
|
+
*/
|
|
564
|
+
set preprocessing(value) {
|
|
565
|
+
_assertClass(value, WasmPreprocessingOptions);
|
|
566
|
+
var ptr0 = value.__destroy_into_raw();
|
|
567
|
+
wasm.wasmconversionoptions_set_preprocessing(this.__wbg_ptr, ptr0);
|
|
568
|
+
}
|
|
569
|
+
/**
|
|
570
|
+
* @param {string[]} value
|
|
571
|
+
*/
|
|
572
|
+
set preserveTags(value) {
|
|
573
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
574
|
+
const len0 = WASM_VECTOR_LEN;
|
|
575
|
+
wasm.wasmconversionoptions_set_preserveTags(this.__wbg_ptr, ptr0, len0);
|
|
576
|
+
}
|
|
577
|
+
/**
|
|
578
|
+
* @param {boolean} value
|
|
579
|
+
*/
|
|
580
|
+
set skipImages(value) {
|
|
581
|
+
wasm.wasmconversionoptions_set_skipImages(this.__wbg_ptr, value);
|
|
582
|
+
}
|
|
583
|
+
/**
|
|
584
|
+
* @param {boolean} value
|
|
585
|
+
*/
|
|
586
|
+
set stripNewlines(value) {
|
|
587
|
+
wasm.wasmconversionoptions_set_stripNewlines(this.__wbg_ptr, value);
|
|
588
|
+
}
|
|
589
|
+
/**
|
|
590
|
+
* @param {string[]} value
|
|
591
|
+
*/
|
|
592
|
+
set stripTags(value) {
|
|
593
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
594
|
+
const len0 = WASM_VECTOR_LEN;
|
|
595
|
+
wasm.wasmconversionoptions_set_stripTags(this.__wbg_ptr, ptr0, len0);
|
|
596
|
+
}
|
|
597
|
+
/**
|
|
598
|
+
* @param {string} value
|
|
599
|
+
*/
|
|
600
|
+
set strongEmSymbol(value) {
|
|
601
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
602
|
+
const len0 = WASM_VECTOR_LEN;
|
|
603
|
+
wasm.wasmconversionoptions_set_strongEmSymbol(this.__wbg_ptr, ptr0, len0);
|
|
604
|
+
}
|
|
605
|
+
/**
|
|
606
|
+
* @param {string} value
|
|
607
|
+
*/
|
|
608
|
+
set subSymbol(value) {
|
|
609
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
610
|
+
const len0 = WASM_VECTOR_LEN;
|
|
611
|
+
wasm.wasmconversionoptions_set_subSymbol(this.__wbg_ptr, ptr0, len0);
|
|
612
|
+
}
|
|
613
|
+
/**
|
|
614
|
+
* @param {string} value
|
|
615
|
+
*/
|
|
616
|
+
set supSymbol(value) {
|
|
617
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
618
|
+
const len0 = WASM_VECTOR_LEN;
|
|
619
|
+
wasm.wasmconversionoptions_set_supSymbol(this.__wbg_ptr, ptr0, len0);
|
|
620
|
+
}
|
|
621
|
+
/**
|
|
622
|
+
* @param {WasmWhitespaceMode} value
|
|
623
|
+
*/
|
|
624
|
+
set whitespaceMode(value) {
|
|
625
|
+
wasm.wasmconversionoptions_set_whitespaceMode(this.__wbg_ptr, value);
|
|
626
|
+
}
|
|
627
|
+
/**
|
|
628
|
+
* @param {boolean} value
|
|
629
|
+
*/
|
|
630
|
+
set wrap(value) {
|
|
631
|
+
wasm.wasmconversionoptions_set_wrap(this.__wbg_ptr, value);
|
|
632
|
+
}
|
|
633
|
+
/**
|
|
634
|
+
* @param {number} value
|
|
635
|
+
*/
|
|
636
|
+
set wrapWidth(value) {
|
|
637
|
+
wasm.wasmconversionoptions_set_wrapWidth(this.__wbg_ptr, value);
|
|
638
|
+
}
|
|
639
|
+
/**
|
|
640
|
+
* @returns {boolean}
|
|
641
|
+
*/
|
|
642
|
+
get skipImages() {
|
|
643
|
+
const ret = wasm.wasmconversionoptions_skipImages(this.__wbg_ptr);
|
|
644
|
+
return ret !== 0;
|
|
645
|
+
}
|
|
646
|
+
/**
|
|
647
|
+
* @returns {boolean}
|
|
648
|
+
*/
|
|
649
|
+
get stripNewlines() {
|
|
650
|
+
const ret = wasm.wasmconversionoptions_stripNewlines(this.__wbg_ptr);
|
|
651
|
+
return ret !== 0;
|
|
652
|
+
}
|
|
653
|
+
/**
|
|
654
|
+
* @returns {string[]}
|
|
655
|
+
*/
|
|
656
|
+
get stripTags() {
|
|
657
|
+
try {
|
|
658
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
659
|
+
wasm.wasmconversionoptions_stripTags(retptr, this.__wbg_ptr);
|
|
660
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
661
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
662
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
663
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
664
|
+
return v1;
|
|
665
|
+
} finally {
|
|
666
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
667
|
+
}
|
|
668
|
+
}
|
|
669
|
+
/**
|
|
670
|
+
* @returns {string}
|
|
671
|
+
*/
|
|
672
|
+
get strongEmSymbol() {
|
|
673
|
+
let deferred1_0;
|
|
674
|
+
let deferred1_1;
|
|
675
|
+
try {
|
|
676
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
677
|
+
wasm.wasmconversionoptions_strongEmSymbol(retptr, this.__wbg_ptr);
|
|
678
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
679
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
680
|
+
deferred1_0 = r0;
|
|
681
|
+
deferred1_1 = r1;
|
|
682
|
+
return getStringFromWasm0(r0, r1);
|
|
683
|
+
} finally {
|
|
684
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
685
|
+
wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
|
|
686
|
+
}
|
|
687
|
+
}
|
|
688
|
+
/**
|
|
689
|
+
* @returns {string}
|
|
690
|
+
*/
|
|
691
|
+
get subSymbol() {
|
|
692
|
+
let deferred1_0;
|
|
693
|
+
let deferred1_1;
|
|
694
|
+
try {
|
|
695
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
696
|
+
wasm.wasmconversionoptions_subSymbol(retptr, this.__wbg_ptr);
|
|
697
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
698
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
699
|
+
deferred1_0 = r0;
|
|
700
|
+
deferred1_1 = r1;
|
|
701
|
+
return getStringFromWasm0(r0, r1);
|
|
702
|
+
} finally {
|
|
703
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
704
|
+
wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
|
|
705
|
+
}
|
|
706
|
+
}
|
|
707
|
+
/**
|
|
708
|
+
* @returns {string}
|
|
709
|
+
*/
|
|
710
|
+
get supSymbol() {
|
|
711
|
+
let deferred1_0;
|
|
712
|
+
let deferred1_1;
|
|
713
|
+
try {
|
|
714
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
715
|
+
wasm.wasmconversionoptions_supSymbol(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_export3(deferred1_0, deferred1_1, 1);
|
|
724
|
+
}
|
|
725
|
+
}
|
|
726
|
+
/**
|
|
727
|
+
* @returns {WasmWhitespaceMode}
|
|
728
|
+
*/
|
|
729
|
+
get whitespaceMode() {
|
|
730
|
+
const ret = wasm.wasmconversionoptions_whitespaceMode(this.__wbg_ptr);
|
|
731
|
+
return ret;
|
|
732
|
+
}
|
|
733
|
+
/**
|
|
734
|
+
* @returns {boolean}
|
|
735
|
+
*/
|
|
736
|
+
get wrap() {
|
|
737
|
+
const ret = wasm.wasmconversionoptions_wrap(this.__wbg_ptr);
|
|
738
|
+
return ret !== 0;
|
|
739
|
+
}
|
|
740
|
+
/**
|
|
741
|
+
* @returns {number}
|
|
742
|
+
*/
|
|
743
|
+
get wrapWidth() {
|
|
744
|
+
const ret = wasm.wasmconversionoptions_wrapWidth(this.__wbg_ptr);
|
|
745
|
+
return ret >>> 0;
|
|
746
|
+
}
|
|
747
|
+
}
|
|
748
|
+
if (Symbol.dispose) WasmConversionOptions.prototype[Symbol.dispose] = WasmConversionOptions.prototype.free;
|
|
749
|
+
exports.WasmConversionOptions = WasmConversionOptions;
|
|
750
|
+
|
|
751
|
+
class WasmConversionOptionsBuilder {
|
|
752
|
+
static __wrap(ptr) {
|
|
753
|
+
ptr = ptr >>> 0;
|
|
754
|
+
const obj = Object.create(WasmConversionOptionsBuilder.prototype);
|
|
755
|
+
obj.__wbg_ptr = ptr;
|
|
756
|
+
WasmConversionOptionsBuilderFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
757
|
+
return obj;
|
|
758
|
+
}
|
|
759
|
+
__destroy_into_raw() {
|
|
760
|
+
const ptr = this.__wbg_ptr;
|
|
761
|
+
this.__wbg_ptr = 0;
|
|
762
|
+
WasmConversionOptionsBuilderFinalization.unregister(this);
|
|
763
|
+
return ptr;
|
|
764
|
+
}
|
|
765
|
+
free() {
|
|
766
|
+
const ptr = this.__destroy_into_raw();
|
|
767
|
+
wasm.__wbg_wasmconversionoptionsbuilder_free(ptr, 0);
|
|
768
|
+
}
|
|
769
|
+
/**
|
|
770
|
+
* @returns {WasmConversionOptions}
|
|
771
|
+
*/
|
|
772
|
+
build() {
|
|
773
|
+
const ret = wasm.wasmconversionoptionsbuilder_build(this.__wbg_ptr);
|
|
774
|
+
return WasmConversionOptions.__wrap(ret);
|
|
775
|
+
}
|
|
776
|
+
/**
|
|
777
|
+
* @param {string[]} tags
|
|
778
|
+
* @returns {WasmConversionOptionsBuilder}
|
|
779
|
+
*/
|
|
780
|
+
keepInlineImagesIn(tags) {
|
|
781
|
+
const ptr0 = passArrayJsValueToWasm0(tags, wasm.__wbindgen_export);
|
|
782
|
+
const len0 = WASM_VECTOR_LEN;
|
|
783
|
+
const ret = wasm.wasmconversionoptionsbuilder_keepInlineImagesIn(this.__wbg_ptr, ptr0, len0);
|
|
784
|
+
return WasmConversionOptionsBuilder.__wrap(ret);
|
|
785
|
+
}
|
|
786
|
+
/**
|
|
787
|
+
* @param {WasmPreprocessingOptions} preprocessing
|
|
788
|
+
* @returns {WasmConversionOptionsBuilder}
|
|
789
|
+
*/
|
|
790
|
+
preprocessing(preprocessing) {
|
|
791
|
+
_assertClass(preprocessing, WasmPreprocessingOptions);
|
|
792
|
+
var ptr0 = preprocessing.__destroy_into_raw();
|
|
793
|
+
const ret = wasm.wasmconversionoptionsbuilder_preprocessing(this.__wbg_ptr, ptr0);
|
|
794
|
+
return WasmConversionOptionsBuilder.__wrap(ret);
|
|
795
|
+
}
|
|
796
|
+
/**
|
|
797
|
+
* @param {string[]} tags
|
|
798
|
+
* @returns {WasmConversionOptionsBuilder}
|
|
799
|
+
*/
|
|
800
|
+
preserveTags(tags) {
|
|
801
|
+
const ptr0 = passArrayJsValueToWasm0(tags, wasm.__wbindgen_export);
|
|
802
|
+
const len0 = WASM_VECTOR_LEN;
|
|
803
|
+
const ret = wasm.wasmconversionoptionsbuilder_preserveTags(this.__wbg_ptr, ptr0, len0);
|
|
804
|
+
return WasmConversionOptionsBuilder.__wrap(ret);
|
|
805
|
+
}
|
|
806
|
+
/**
|
|
807
|
+
* @param {string[]} tags
|
|
808
|
+
* @returns {WasmConversionOptionsBuilder}
|
|
809
|
+
*/
|
|
810
|
+
stripTags(tags) {
|
|
811
|
+
const ptr0 = passArrayJsValueToWasm0(tags, wasm.__wbindgen_export);
|
|
812
|
+
const len0 = WASM_VECTOR_LEN;
|
|
813
|
+
const ret = wasm.wasmconversionoptionsbuilder_stripTags(this.__wbg_ptr, ptr0, len0);
|
|
814
|
+
return WasmConversionOptionsBuilder.__wrap(ret);
|
|
815
|
+
}
|
|
816
|
+
}
|
|
817
|
+
if (Symbol.dispose) WasmConversionOptionsBuilder.prototype[Symbol.dispose] = WasmConversionOptionsBuilder.prototype.free;
|
|
818
|
+
exports.WasmConversionOptionsBuilder = WasmConversionOptionsBuilder;
|
|
819
|
+
|
|
820
|
+
class WasmConversionOptionsUpdate {
|
|
821
|
+
__destroy_into_raw() {
|
|
822
|
+
const ptr = this.__wbg_ptr;
|
|
823
|
+
this.__wbg_ptr = 0;
|
|
824
|
+
WasmConversionOptionsUpdateFinalization.unregister(this);
|
|
825
|
+
return ptr;
|
|
826
|
+
}
|
|
827
|
+
free() {
|
|
828
|
+
const ptr = this.__destroy_into_raw();
|
|
829
|
+
wasm.__wbg_wasmconversionoptionsupdate_free(ptr, 0);
|
|
830
|
+
}
|
|
831
|
+
/**
|
|
832
|
+
* @returns {boolean | undefined}
|
|
833
|
+
*/
|
|
834
|
+
get autolinks() {
|
|
835
|
+
const ret = wasm.wasmconversionoptionsupdate_autolinks(this.__wbg_ptr);
|
|
836
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
837
|
+
}
|
|
838
|
+
/**
|
|
839
|
+
* @returns {boolean | undefined}
|
|
840
|
+
*/
|
|
841
|
+
get brInTables() {
|
|
842
|
+
const ret = wasm.wasmconversionoptionsupdate_brInTables(this.__wbg_ptr);
|
|
843
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
844
|
+
}
|
|
845
|
+
/**
|
|
846
|
+
* @returns {string | undefined}
|
|
847
|
+
*/
|
|
848
|
+
get bullets() {
|
|
849
|
+
try {
|
|
850
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
851
|
+
wasm.wasmconversionoptionsupdate_bullets(retptr, this.__wbg_ptr);
|
|
852
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
853
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
854
|
+
let v1;
|
|
855
|
+
if (r0 !== 0) {
|
|
856
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
857
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
858
|
+
}
|
|
859
|
+
return v1;
|
|
860
|
+
} finally {
|
|
861
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
862
|
+
}
|
|
863
|
+
}
|
|
864
|
+
/**
|
|
865
|
+
* @returns {boolean | undefined}
|
|
866
|
+
*/
|
|
867
|
+
get captureSvg() {
|
|
868
|
+
const ret = wasm.wasmconversionoptionsupdate_captureSvg(this.__wbg_ptr);
|
|
869
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
870
|
+
}
|
|
871
|
+
/**
|
|
872
|
+
* @returns {WasmCodeBlockStyle | undefined}
|
|
873
|
+
*/
|
|
874
|
+
get codeBlockStyle() {
|
|
875
|
+
const ret = wasm.wasmconversionoptionsupdate_codeBlockStyle(this.__wbg_ptr);
|
|
876
|
+
return ret === 3 ? undefined : ret;
|
|
877
|
+
}
|
|
878
|
+
/**
|
|
879
|
+
* @returns {string | undefined}
|
|
880
|
+
*/
|
|
881
|
+
get codeLanguage() {
|
|
882
|
+
try {
|
|
883
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
884
|
+
wasm.wasmconversionoptionsupdate_codeLanguage(retptr, this.__wbg_ptr);
|
|
885
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
886
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
887
|
+
let v1;
|
|
888
|
+
if (r0 !== 0) {
|
|
889
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
890
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
891
|
+
}
|
|
892
|
+
return v1;
|
|
893
|
+
} finally {
|
|
894
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
895
|
+
}
|
|
896
|
+
}
|
|
897
|
+
/**
|
|
898
|
+
* @returns {boolean | undefined}
|
|
899
|
+
*/
|
|
900
|
+
get convertAsInline() {
|
|
901
|
+
const ret = wasm.wasmconversionoptionsupdate_convertAsInline(this.__wbg_ptr);
|
|
902
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
903
|
+
}
|
|
904
|
+
/**
|
|
905
|
+
* @returns {boolean | undefined}
|
|
906
|
+
*/
|
|
907
|
+
get debug() {
|
|
908
|
+
const ret = wasm.wasmconversionoptionsupdate_debug(this.__wbg_ptr);
|
|
909
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
910
|
+
}
|
|
911
|
+
/**
|
|
912
|
+
* @returns {boolean | undefined}
|
|
913
|
+
*/
|
|
914
|
+
get defaultTitle() {
|
|
915
|
+
const ret = wasm.wasmconversionoptionsupdate_defaultTitle(this.__wbg_ptr);
|
|
916
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
917
|
+
}
|
|
918
|
+
/**
|
|
919
|
+
* @returns {string | undefined}
|
|
920
|
+
*/
|
|
921
|
+
get encoding() {
|
|
922
|
+
try {
|
|
923
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
924
|
+
wasm.wasmconversionoptionsupdate_encoding(retptr, this.__wbg_ptr);
|
|
925
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
926
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
927
|
+
let v1;
|
|
928
|
+
if (r0 !== 0) {
|
|
929
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
930
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
931
|
+
}
|
|
932
|
+
return v1;
|
|
933
|
+
} finally {
|
|
934
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
935
|
+
}
|
|
936
|
+
}
|
|
937
|
+
/**
|
|
938
|
+
* @returns {boolean | undefined}
|
|
939
|
+
*/
|
|
940
|
+
get escapeAscii() {
|
|
941
|
+
const ret = wasm.wasmconversionoptionsupdate_escapeAscii(this.__wbg_ptr);
|
|
942
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
943
|
+
}
|
|
944
|
+
/**
|
|
945
|
+
* @returns {boolean | undefined}
|
|
946
|
+
*/
|
|
947
|
+
get escapeAsterisks() {
|
|
948
|
+
const ret = wasm.wasmconversionoptionsupdate_escapeAsterisks(this.__wbg_ptr);
|
|
949
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
950
|
+
}
|
|
951
|
+
/**
|
|
952
|
+
* @returns {boolean | undefined}
|
|
953
|
+
*/
|
|
954
|
+
get escapeMisc() {
|
|
955
|
+
const ret = wasm.wasmconversionoptionsupdate_escapeMisc(this.__wbg_ptr);
|
|
956
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
957
|
+
}
|
|
958
|
+
/**
|
|
959
|
+
* @returns {boolean | undefined}
|
|
960
|
+
*/
|
|
961
|
+
get escapeUnderscores() {
|
|
962
|
+
const ret = wasm.wasmconversionoptionsupdate_escapeUnderscores(this.__wbg_ptr);
|
|
963
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
964
|
+
}
|
|
965
|
+
/**
|
|
966
|
+
* @returns {boolean | undefined}
|
|
967
|
+
*/
|
|
968
|
+
get extractImages() {
|
|
969
|
+
const ret = wasm.wasmconversionoptionsupdate_extractImages(this.__wbg_ptr);
|
|
970
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
971
|
+
}
|
|
972
|
+
/**
|
|
973
|
+
* @returns {boolean | undefined}
|
|
974
|
+
*/
|
|
975
|
+
get extractMetadata() {
|
|
976
|
+
const ret = wasm.wasmconversionoptionsupdate_extractMetadata(this.__wbg_ptr);
|
|
977
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
978
|
+
}
|
|
979
|
+
/**
|
|
980
|
+
* @returns {WasmHeadingStyle | undefined}
|
|
981
|
+
*/
|
|
982
|
+
get headingStyle() {
|
|
983
|
+
const ret = wasm.wasmconversionoptionsupdate_headingStyle(this.__wbg_ptr);
|
|
984
|
+
return ret === 3 ? undefined : ret;
|
|
985
|
+
}
|
|
986
|
+
/**
|
|
987
|
+
* @returns {WasmHighlightStyle | undefined}
|
|
988
|
+
*/
|
|
989
|
+
get highlightStyle() {
|
|
990
|
+
const ret = wasm.wasmconversionoptionsupdate_highlightStyle(this.__wbg_ptr);
|
|
991
|
+
return ret === 4 ? undefined : ret;
|
|
992
|
+
}
|
|
993
|
+
/**
|
|
994
|
+
* @returns {boolean | undefined}
|
|
995
|
+
*/
|
|
996
|
+
get includeDocumentStructure() {
|
|
997
|
+
const ret = wasm.wasmconversionoptionsupdate_includeDocumentStructure(this.__wbg_ptr);
|
|
998
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
999
|
+
}
|
|
1000
|
+
/**
|
|
1001
|
+
* @returns {boolean | undefined}
|
|
1002
|
+
*/
|
|
1003
|
+
get inferDimensions() {
|
|
1004
|
+
const ret = wasm.wasmconversionoptionsupdate_inferDimensions(this.__wbg_ptr);
|
|
1005
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
1006
|
+
}
|
|
1007
|
+
/**
|
|
1008
|
+
* @returns {string[] | undefined}
|
|
1009
|
+
*/
|
|
1010
|
+
get keepInlineImagesIn() {
|
|
1011
|
+
try {
|
|
1012
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1013
|
+
wasm.wasmconversionoptionsupdate_keepInlineImagesIn(retptr, this.__wbg_ptr);
|
|
1014
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1015
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1016
|
+
let v1;
|
|
1017
|
+
if (r0 !== 0) {
|
|
1018
|
+
v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
1019
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
1020
|
+
}
|
|
1021
|
+
return v1;
|
|
1022
|
+
} finally {
|
|
1023
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1024
|
+
}
|
|
1025
|
+
}
|
|
1026
|
+
/**
|
|
1027
|
+
* @returns {WasmLinkStyle | undefined}
|
|
1028
|
+
*/
|
|
1029
|
+
get linkStyle() {
|
|
1030
|
+
const ret = wasm.wasmconversionoptionsupdate_linkStyle(this.__wbg_ptr);
|
|
1031
|
+
return ret === 2 ? undefined : ret;
|
|
1032
|
+
}
|
|
1033
|
+
/**
|
|
1034
|
+
* @returns {WasmListIndentType | undefined}
|
|
1035
|
+
*/
|
|
1036
|
+
get listIndentType() {
|
|
1037
|
+
const ret = wasm.wasmconversionoptionsupdate_listIndentType(this.__wbg_ptr);
|
|
1038
|
+
return ret === 2 ? undefined : ret;
|
|
1039
|
+
}
|
|
1040
|
+
/**
|
|
1041
|
+
* @returns {number | undefined}
|
|
1042
|
+
*/
|
|
1043
|
+
get listIndentWidth() {
|
|
1044
|
+
const ret = wasm.wasmconversionoptionsupdate_listIndentWidth(this.__wbg_ptr);
|
|
1045
|
+
return ret === 0x100000001 ? undefined : ret;
|
|
1046
|
+
}
|
|
1047
|
+
/**
|
|
1048
|
+
* @returns {bigint | undefined}
|
|
1049
|
+
*/
|
|
1050
|
+
get maxImageSize() {
|
|
1051
|
+
try {
|
|
1052
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1053
|
+
wasm.wasmconversionoptionsupdate_maxImageSize(retptr, this.__wbg_ptr);
|
|
1054
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1055
|
+
var r2 = getDataViewMemory0().getBigInt64(retptr + 8 * 1, true);
|
|
1056
|
+
return r0 === 0 ? undefined : BigInt.asUintN(64, r2);
|
|
1057
|
+
} finally {
|
|
1058
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1059
|
+
}
|
|
1060
|
+
}
|
|
1061
|
+
/**
|
|
1062
|
+
* @param {WasmHeadingStyle | null} [heading_style]
|
|
1063
|
+
* @param {WasmListIndentType | null} [list_indent_type]
|
|
1064
|
+
* @param {number | null} [list_indent_width]
|
|
1065
|
+
* @param {string | null} [bullets]
|
|
1066
|
+
* @param {string | null} [strong_em_symbol]
|
|
1067
|
+
* @param {boolean | null} [escape_asterisks]
|
|
1068
|
+
* @param {boolean | null} [escape_underscores]
|
|
1069
|
+
* @param {boolean | null} [escape_misc]
|
|
1070
|
+
* @param {boolean | null} [escape_ascii]
|
|
1071
|
+
* @param {string | null} [code_language]
|
|
1072
|
+
* @param {boolean | null} [autolinks]
|
|
1073
|
+
* @param {boolean | null} [default_title]
|
|
1074
|
+
* @param {boolean | null} [br_in_tables]
|
|
1075
|
+
* @param {WasmHighlightStyle | null} [highlight_style]
|
|
1076
|
+
* @param {boolean | null} [extract_metadata]
|
|
1077
|
+
* @param {WasmWhitespaceMode | null} [whitespace_mode]
|
|
1078
|
+
* @param {boolean | null} [strip_newlines]
|
|
1079
|
+
* @param {boolean | null} [wrap]
|
|
1080
|
+
* @param {number | null} [wrap_width]
|
|
1081
|
+
* @param {boolean | null} [convert_as_inline]
|
|
1082
|
+
* @param {string | null} [sub_symbol]
|
|
1083
|
+
* @param {string | null} [sup_symbol]
|
|
1084
|
+
* @param {WasmNewlineStyle | null} [newline_style]
|
|
1085
|
+
* @param {WasmCodeBlockStyle | null} [code_block_style]
|
|
1086
|
+
* @param {string[] | null} [keep_inline_images_in]
|
|
1087
|
+
* @param {WasmPreprocessingOptionsUpdate | null} [preprocessing]
|
|
1088
|
+
* @param {string | null} [encoding]
|
|
1089
|
+
* @param {boolean | null} [debug]
|
|
1090
|
+
* @param {string[] | null} [strip_tags]
|
|
1091
|
+
* @param {string[] | null} [preserve_tags]
|
|
1092
|
+
* @param {boolean | null} [skip_images]
|
|
1093
|
+
* @param {WasmLinkStyle | null} [link_style]
|
|
1094
|
+
* @param {WasmOutputFormat | null} [output_format]
|
|
1095
|
+
* @param {boolean | null} [include_document_structure]
|
|
1096
|
+
* @param {boolean | null} [extract_images]
|
|
1097
|
+
* @param {bigint | null} [max_image_size]
|
|
1098
|
+
* @param {boolean | null} [capture_svg]
|
|
1099
|
+
* @param {boolean | null} [infer_dimensions]
|
|
1100
|
+
*/
|
|
1101
|
+
constructor(heading_style, list_indent_type, list_indent_width, bullets, strong_em_symbol, escape_asterisks, escape_underscores, escape_misc, escape_ascii, code_language, autolinks, default_title, br_in_tables, highlight_style, extract_metadata, whitespace_mode, strip_newlines, wrap, wrap_width, convert_as_inline, sub_symbol, sup_symbol, newline_style, code_block_style, keep_inline_images_in, preprocessing, encoding, debug, strip_tags, preserve_tags, skip_images, link_style, output_format, include_document_structure, extract_images, max_image_size, capture_svg, infer_dimensions) {
|
|
1102
|
+
var ptr0 = isLikeNone(bullets) ? 0 : passStringToWasm0(bullets, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1103
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1104
|
+
var ptr1 = isLikeNone(strong_em_symbol) ? 0 : passStringToWasm0(strong_em_symbol, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1105
|
+
var len1 = WASM_VECTOR_LEN;
|
|
1106
|
+
var ptr2 = isLikeNone(code_language) ? 0 : passStringToWasm0(code_language, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1107
|
+
var len2 = WASM_VECTOR_LEN;
|
|
1108
|
+
var ptr3 = isLikeNone(sub_symbol) ? 0 : passStringToWasm0(sub_symbol, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1109
|
+
var len3 = WASM_VECTOR_LEN;
|
|
1110
|
+
var ptr4 = isLikeNone(sup_symbol) ? 0 : passStringToWasm0(sup_symbol, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1111
|
+
var len4 = WASM_VECTOR_LEN;
|
|
1112
|
+
var ptr5 = isLikeNone(keep_inline_images_in) ? 0 : passArrayJsValueToWasm0(keep_inline_images_in, wasm.__wbindgen_export);
|
|
1113
|
+
var len5 = WASM_VECTOR_LEN;
|
|
1114
|
+
let ptr6 = 0;
|
|
1115
|
+
if (!isLikeNone(preprocessing)) {
|
|
1116
|
+
_assertClass(preprocessing, WasmPreprocessingOptionsUpdate);
|
|
1117
|
+
ptr6 = preprocessing.__destroy_into_raw();
|
|
1118
|
+
}
|
|
1119
|
+
var ptr7 = isLikeNone(encoding) ? 0 : passStringToWasm0(encoding, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1120
|
+
var len7 = WASM_VECTOR_LEN;
|
|
1121
|
+
var ptr8 = isLikeNone(strip_tags) ? 0 : passArrayJsValueToWasm0(strip_tags, wasm.__wbindgen_export);
|
|
1122
|
+
var len8 = WASM_VECTOR_LEN;
|
|
1123
|
+
var ptr9 = isLikeNone(preserve_tags) ? 0 : passArrayJsValueToWasm0(preserve_tags, wasm.__wbindgen_export);
|
|
1124
|
+
var len9 = WASM_VECTOR_LEN;
|
|
1125
|
+
const ret = wasm.wasmconversionoptionsupdate_new(isLikeNone(heading_style) ? 3 : heading_style, isLikeNone(list_indent_type) ? 2 : list_indent_type, isLikeNone(list_indent_width) ? 0x100000001 : (list_indent_width) >>> 0, ptr0, len0, ptr1, len1, isLikeNone(escape_asterisks) ? 0xFFFFFF : escape_asterisks ? 1 : 0, isLikeNone(escape_underscores) ? 0xFFFFFF : escape_underscores ? 1 : 0, isLikeNone(escape_misc) ? 0xFFFFFF : escape_misc ? 1 : 0, isLikeNone(escape_ascii) ? 0xFFFFFF : escape_ascii ? 1 : 0, ptr2, len2, isLikeNone(autolinks) ? 0xFFFFFF : autolinks ? 1 : 0, isLikeNone(default_title) ? 0xFFFFFF : default_title ? 1 : 0, isLikeNone(br_in_tables) ? 0xFFFFFF : br_in_tables ? 1 : 0, isLikeNone(highlight_style) ? 4 : highlight_style, isLikeNone(extract_metadata) ? 0xFFFFFF : extract_metadata ? 1 : 0, isLikeNone(whitespace_mode) ? 2 : whitespace_mode, isLikeNone(strip_newlines) ? 0xFFFFFF : strip_newlines ? 1 : 0, isLikeNone(wrap) ? 0xFFFFFF : wrap ? 1 : 0, isLikeNone(wrap_width) ? 0x100000001 : (wrap_width) >>> 0, isLikeNone(convert_as_inline) ? 0xFFFFFF : convert_as_inline ? 1 : 0, ptr3, len3, ptr4, len4, isLikeNone(newline_style) ? 2 : newline_style, isLikeNone(code_block_style) ? 3 : code_block_style, ptr5, len5, ptr6, ptr7, len7, isLikeNone(debug) ? 0xFFFFFF : debug ? 1 : 0, ptr8, len8, ptr9, len9, isLikeNone(skip_images) ? 0xFFFFFF : skip_images ? 1 : 0, isLikeNone(link_style) ? 2 : link_style, isLikeNone(output_format) ? 3 : output_format, isLikeNone(include_document_structure) ? 0xFFFFFF : include_document_structure ? 1 : 0, isLikeNone(extract_images) ? 0xFFFFFF : extract_images ? 1 : 0, !isLikeNone(max_image_size), isLikeNone(max_image_size) ? BigInt(0) : max_image_size, isLikeNone(capture_svg) ? 0xFFFFFF : capture_svg ? 1 : 0, isLikeNone(infer_dimensions) ? 0xFFFFFF : infer_dimensions ? 1 : 0);
|
|
1126
|
+
this.__wbg_ptr = ret >>> 0;
|
|
1127
|
+
WasmConversionOptionsUpdateFinalization.register(this, this.__wbg_ptr, this);
|
|
1128
|
+
return this;
|
|
1129
|
+
}
|
|
1130
|
+
/**
|
|
1131
|
+
* @returns {WasmNewlineStyle | undefined}
|
|
1132
|
+
*/
|
|
1133
|
+
get newlineStyle() {
|
|
1134
|
+
const ret = wasm.wasmconversionoptionsupdate_newlineStyle(this.__wbg_ptr);
|
|
1135
|
+
return ret === 2 ? undefined : ret;
|
|
1136
|
+
}
|
|
1137
|
+
/**
|
|
1138
|
+
* @returns {WasmOutputFormat | undefined}
|
|
1139
|
+
*/
|
|
1140
|
+
get outputFormat() {
|
|
1141
|
+
const ret = wasm.wasmconversionoptionsupdate_outputFormat(this.__wbg_ptr);
|
|
1142
|
+
return ret === 3 ? undefined : ret;
|
|
1143
|
+
}
|
|
1144
|
+
/**
|
|
1145
|
+
* @returns {WasmPreprocessingOptionsUpdate | undefined}
|
|
1146
|
+
*/
|
|
1147
|
+
get preprocessing() {
|
|
1148
|
+
const ret = wasm.wasmconversionoptionsupdate_preprocessing(this.__wbg_ptr);
|
|
1149
|
+
return ret === 0 ? undefined : WasmPreprocessingOptionsUpdate.__wrap(ret);
|
|
1150
|
+
}
|
|
1151
|
+
/**
|
|
1152
|
+
* @returns {string[] | undefined}
|
|
1153
|
+
*/
|
|
1154
|
+
get preserveTags() {
|
|
1155
|
+
try {
|
|
1156
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1157
|
+
wasm.wasmconversionoptionsupdate_preserveTags(retptr, this.__wbg_ptr);
|
|
1158
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1159
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1160
|
+
let v1;
|
|
1161
|
+
if (r0 !== 0) {
|
|
1162
|
+
v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
1163
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
1164
|
+
}
|
|
1165
|
+
return v1;
|
|
1166
|
+
} finally {
|
|
1167
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1168
|
+
}
|
|
1169
|
+
}
|
|
1170
|
+
/**
|
|
1171
|
+
* @param {boolean | null} [value]
|
|
1172
|
+
*/
|
|
1173
|
+
set autolinks(value) {
|
|
1174
|
+
wasm.wasmconversionoptionsupdate_set_autolinks(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1175
|
+
}
|
|
1176
|
+
/**
|
|
1177
|
+
* @param {boolean | null} [value]
|
|
1178
|
+
*/
|
|
1179
|
+
set brInTables(value) {
|
|
1180
|
+
wasm.wasmconversionoptionsupdate_set_brInTables(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1181
|
+
}
|
|
1182
|
+
/**
|
|
1183
|
+
* @param {string | null} [value]
|
|
1184
|
+
*/
|
|
1185
|
+
set bullets(value) {
|
|
1186
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1187
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1188
|
+
wasm.wasmconversionoptionsupdate_set_bullets(this.__wbg_ptr, ptr0, len0);
|
|
1189
|
+
}
|
|
1190
|
+
/**
|
|
1191
|
+
* @param {boolean | null} [value]
|
|
1192
|
+
*/
|
|
1193
|
+
set captureSvg(value) {
|
|
1194
|
+
wasm.wasmconversionoptionsupdate_set_captureSvg(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1195
|
+
}
|
|
1196
|
+
/**
|
|
1197
|
+
* @param {WasmCodeBlockStyle | null} [value]
|
|
1198
|
+
*/
|
|
1199
|
+
set codeBlockStyle(value) {
|
|
1200
|
+
wasm.wasmconversionoptionsupdate_set_codeBlockStyle(this.__wbg_ptr, isLikeNone(value) ? 3 : value);
|
|
1201
|
+
}
|
|
1202
|
+
/**
|
|
1203
|
+
* @param {string | null} [value]
|
|
1204
|
+
*/
|
|
1205
|
+
set codeLanguage(value) {
|
|
1206
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1207
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1208
|
+
wasm.wasmconversionoptionsupdate_set_codeLanguage(this.__wbg_ptr, ptr0, len0);
|
|
1209
|
+
}
|
|
1210
|
+
/**
|
|
1211
|
+
* @param {boolean | null} [value]
|
|
1212
|
+
*/
|
|
1213
|
+
set convertAsInline(value) {
|
|
1214
|
+
wasm.wasmconversionoptionsupdate_set_convertAsInline(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1215
|
+
}
|
|
1216
|
+
/**
|
|
1217
|
+
* @param {boolean | null} [value]
|
|
1218
|
+
*/
|
|
1219
|
+
set debug(value) {
|
|
1220
|
+
wasm.wasmconversionoptionsupdate_set_debug(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1221
|
+
}
|
|
1222
|
+
/**
|
|
1223
|
+
* @param {boolean | null} [value]
|
|
1224
|
+
*/
|
|
1225
|
+
set defaultTitle(value) {
|
|
1226
|
+
wasm.wasmconversionoptionsupdate_set_defaultTitle(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1227
|
+
}
|
|
1228
|
+
/**
|
|
1229
|
+
* @param {string | null} [value]
|
|
1230
|
+
*/
|
|
1231
|
+
set encoding(value) {
|
|
1232
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1233
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1234
|
+
wasm.wasmconversionoptionsupdate_set_encoding(this.__wbg_ptr, ptr0, len0);
|
|
1235
|
+
}
|
|
1236
|
+
/**
|
|
1237
|
+
* @param {boolean | null} [value]
|
|
1238
|
+
*/
|
|
1239
|
+
set escapeAscii(value) {
|
|
1240
|
+
wasm.wasmconversionoptionsupdate_set_escapeAscii(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1241
|
+
}
|
|
1242
|
+
/**
|
|
1243
|
+
* @param {boolean | null} [value]
|
|
1244
|
+
*/
|
|
1245
|
+
set escapeAsterisks(value) {
|
|
1246
|
+
wasm.wasmconversionoptionsupdate_set_escapeAsterisks(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1247
|
+
}
|
|
1248
|
+
/**
|
|
1249
|
+
* @param {boolean | null} [value]
|
|
1250
|
+
*/
|
|
1251
|
+
set escapeMisc(value) {
|
|
1252
|
+
wasm.wasmconversionoptionsupdate_set_escapeMisc(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1253
|
+
}
|
|
1254
|
+
/**
|
|
1255
|
+
* @param {boolean | null} [value]
|
|
1256
|
+
*/
|
|
1257
|
+
set escapeUnderscores(value) {
|
|
1258
|
+
wasm.wasmconversionoptionsupdate_set_escapeUnderscores(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1259
|
+
}
|
|
1260
|
+
/**
|
|
1261
|
+
* @param {boolean | null} [value]
|
|
1262
|
+
*/
|
|
1263
|
+
set extractImages(value) {
|
|
1264
|
+
wasm.wasmconversionoptionsupdate_set_extractImages(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1265
|
+
}
|
|
1266
|
+
/**
|
|
1267
|
+
* @param {boolean | null} [value]
|
|
1268
|
+
*/
|
|
1269
|
+
set extractMetadata(value) {
|
|
1270
|
+
wasm.wasmconversionoptionsupdate_set_extractMetadata(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1271
|
+
}
|
|
1272
|
+
/**
|
|
1273
|
+
* @param {WasmHeadingStyle | null} [value]
|
|
1274
|
+
*/
|
|
1275
|
+
set headingStyle(value) {
|
|
1276
|
+
wasm.wasmconversionoptionsupdate_set_headingStyle(this.__wbg_ptr, isLikeNone(value) ? 3 : value);
|
|
1277
|
+
}
|
|
1278
|
+
/**
|
|
1279
|
+
* @param {WasmHighlightStyle | null} [value]
|
|
1280
|
+
*/
|
|
1281
|
+
set highlightStyle(value) {
|
|
1282
|
+
wasm.wasmconversionoptionsupdate_set_highlightStyle(this.__wbg_ptr, isLikeNone(value) ? 4 : value);
|
|
1283
|
+
}
|
|
1284
|
+
/**
|
|
1285
|
+
* @param {boolean | null} [value]
|
|
1286
|
+
*/
|
|
1287
|
+
set includeDocumentStructure(value) {
|
|
1288
|
+
wasm.wasmconversionoptionsupdate_set_includeDocumentStructure(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1289
|
+
}
|
|
1290
|
+
/**
|
|
1291
|
+
* @param {boolean | null} [value]
|
|
1292
|
+
*/
|
|
1293
|
+
set inferDimensions(value) {
|
|
1294
|
+
wasm.wasmconversionoptionsupdate_set_inferDimensions(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1295
|
+
}
|
|
1296
|
+
/**
|
|
1297
|
+
* @param {string[] | null} [value]
|
|
1298
|
+
*/
|
|
1299
|
+
set keepInlineImagesIn(value) {
|
|
1300
|
+
var ptr0 = isLikeNone(value) ? 0 : passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
1301
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1302
|
+
wasm.wasmconversionoptionsupdate_set_keepInlineImagesIn(this.__wbg_ptr, ptr0, len0);
|
|
1303
|
+
}
|
|
1304
|
+
/**
|
|
1305
|
+
* @param {WasmLinkStyle | null} [value]
|
|
1306
|
+
*/
|
|
1307
|
+
set linkStyle(value) {
|
|
1308
|
+
wasm.wasmconversionoptionsupdate_set_linkStyle(this.__wbg_ptr, isLikeNone(value) ? 2 : value);
|
|
1309
|
+
}
|
|
1310
|
+
/**
|
|
1311
|
+
* @param {WasmListIndentType | null} [value]
|
|
1312
|
+
*/
|
|
1313
|
+
set listIndentType(value) {
|
|
1314
|
+
wasm.wasmconversionoptionsupdate_set_listIndentType(this.__wbg_ptr, isLikeNone(value) ? 2 : value);
|
|
1315
|
+
}
|
|
1316
|
+
/**
|
|
1317
|
+
* @param {number | null} [value]
|
|
1318
|
+
*/
|
|
1319
|
+
set listIndentWidth(value) {
|
|
1320
|
+
wasm.wasmconversionoptionsupdate_set_listIndentWidth(this.__wbg_ptr, isLikeNone(value) ? 0x100000001 : (value) >>> 0);
|
|
1321
|
+
}
|
|
1322
|
+
/**
|
|
1323
|
+
* @param {bigint | null} [value]
|
|
1324
|
+
*/
|
|
1325
|
+
set maxImageSize(value) {
|
|
1326
|
+
wasm.wasmconversionoptionsupdate_set_maxImageSize(this.__wbg_ptr, !isLikeNone(value), isLikeNone(value) ? BigInt(0) : value);
|
|
1327
|
+
}
|
|
1328
|
+
/**
|
|
1329
|
+
* @param {WasmNewlineStyle | null} [value]
|
|
1330
|
+
*/
|
|
1331
|
+
set newlineStyle(value) {
|
|
1332
|
+
wasm.wasmconversionoptionsupdate_set_newlineStyle(this.__wbg_ptr, isLikeNone(value) ? 2 : value);
|
|
1333
|
+
}
|
|
1334
|
+
/**
|
|
1335
|
+
* @param {WasmOutputFormat | null} [value]
|
|
1336
|
+
*/
|
|
1337
|
+
set outputFormat(value) {
|
|
1338
|
+
wasm.wasmconversionoptionsupdate_set_outputFormat(this.__wbg_ptr, isLikeNone(value) ? 3 : value);
|
|
1339
|
+
}
|
|
1340
|
+
/**
|
|
1341
|
+
* @param {WasmPreprocessingOptionsUpdate | null} [value]
|
|
1342
|
+
*/
|
|
1343
|
+
set preprocessing(value) {
|
|
1344
|
+
let ptr0 = 0;
|
|
1345
|
+
if (!isLikeNone(value)) {
|
|
1346
|
+
_assertClass(value, WasmPreprocessingOptionsUpdate);
|
|
1347
|
+
ptr0 = value.__destroy_into_raw();
|
|
1348
|
+
}
|
|
1349
|
+
wasm.wasmconversionoptionsupdate_set_preprocessing(this.__wbg_ptr, ptr0);
|
|
1350
|
+
}
|
|
1351
|
+
/**
|
|
1352
|
+
* @param {string[] | null} [value]
|
|
1353
|
+
*/
|
|
1354
|
+
set preserveTags(value) {
|
|
1355
|
+
var ptr0 = isLikeNone(value) ? 0 : passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
1356
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1357
|
+
wasm.wasmconversionoptionsupdate_set_preserveTags(this.__wbg_ptr, ptr0, len0);
|
|
1358
|
+
}
|
|
1359
|
+
/**
|
|
1360
|
+
* @param {boolean | null} [value]
|
|
1361
|
+
*/
|
|
1362
|
+
set skipImages(value) {
|
|
1363
|
+
wasm.wasmconversionoptionsupdate_set_skipImages(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1364
|
+
}
|
|
1365
|
+
/**
|
|
1366
|
+
* @param {boolean | null} [value]
|
|
1367
|
+
*/
|
|
1368
|
+
set stripNewlines(value) {
|
|
1369
|
+
wasm.wasmconversionoptionsupdate_set_stripNewlines(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1370
|
+
}
|
|
1371
|
+
/**
|
|
1372
|
+
* @param {string[] | null} [value]
|
|
1373
|
+
*/
|
|
1374
|
+
set stripTags(value) {
|
|
1375
|
+
var ptr0 = isLikeNone(value) ? 0 : passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
1376
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1377
|
+
wasm.wasmconversionoptionsupdate_set_stripTags(this.__wbg_ptr, ptr0, len0);
|
|
1378
|
+
}
|
|
1379
|
+
/**
|
|
1380
|
+
* @param {string | null} [value]
|
|
1381
|
+
*/
|
|
1382
|
+
set strongEmSymbol(value) {
|
|
1383
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1384
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1385
|
+
wasm.wasmconversionoptionsupdate_set_strongEmSymbol(this.__wbg_ptr, ptr0, len0);
|
|
1386
|
+
}
|
|
1387
|
+
/**
|
|
1388
|
+
* @param {string | null} [value]
|
|
1389
|
+
*/
|
|
1390
|
+
set subSymbol(value) {
|
|
1391
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1392
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1393
|
+
wasm.wasmconversionoptionsupdate_set_subSymbol(this.__wbg_ptr, ptr0, len0);
|
|
1394
|
+
}
|
|
1395
|
+
/**
|
|
1396
|
+
* @param {string | null} [value]
|
|
1397
|
+
*/
|
|
1398
|
+
set supSymbol(value) {
|
|
1399
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1400
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1401
|
+
wasm.wasmconversionoptionsupdate_set_supSymbol(this.__wbg_ptr, ptr0, len0);
|
|
1402
|
+
}
|
|
1403
|
+
/**
|
|
1404
|
+
* @param {WasmWhitespaceMode | null} [value]
|
|
1405
|
+
*/
|
|
1406
|
+
set whitespaceMode(value) {
|
|
1407
|
+
wasm.wasmconversionoptionsupdate_set_whitespaceMode(this.__wbg_ptr, isLikeNone(value) ? 2 : value);
|
|
1408
|
+
}
|
|
1409
|
+
/**
|
|
1410
|
+
* @param {boolean | null} [value]
|
|
1411
|
+
*/
|
|
1412
|
+
set wrap(value) {
|
|
1413
|
+
wasm.wasmconversionoptionsupdate_set_wrap(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
1414
|
+
}
|
|
1415
|
+
/**
|
|
1416
|
+
* @param {number | null} [value]
|
|
1417
|
+
*/
|
|
1418
|
+
set wrapWidth(value) {
|
|
1419
|
+
wasm.wasmconversionoptionsupdate_set_wrapWidth(this.__wbg_ptr, isLikeNone(value) ? 0x100000001 : (value) >>> 0);
|
|
1420
|
+
}
|
|
1421
|
+
/**
|
|
1422
|
+
* @returns {boolean | undefined}
|
|
1423
|
+
*/
|
|
1424
|
+
get skipImages() {
|
|
1425
|
+
const ret = wasm.wasmconversionoptionsupdate_skipImages(this.__wbg_ptr);
|
|
1426
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
1427
|
+
}
|
|
1428
|
+
/**
|
|
1429
|
+
* @returns {boolean | undefined}
|
|
1430
|
+
*/
|
|
1431
|
+
get stripNewlines() {
|
|
1432
|
+
const ret = wasm.wasmconversionoptionsupdate_stripNewlines(this.__wbg_ptr);
|
|
1433
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
1434
|
+
}
|
|
1435
|
+
/**
|
|
1436
|
+
* @returns {string[] | undefined}
|
|
1437
|
+
*/
|
|
1438
|
+
get stripTags() {
|
|
1439
|
+
try {
|
|
1440
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1441
|
+
wasm.wasmconversionoptionsupdate_stripTags(retptr, this.__wbg_ptr);
|
|
1442
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1443
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1444
|
+
let v1;
|
|
1445
|
+
if (r0 !== 0) {
|
|
1446
|
+
v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
1447
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
1448
|
+
}
|
|
1449
|
+
return v1;
|
|
1450
|
+
} finally {
|
|
1451
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1452
|
+
}
|
|
1453
|
+
}
|
|
1454
|
+
/**
|
|
1455
|
+
* @returns {string | undefined}
|
|
1456
|
+
*/
|
|
1457
|
+
get strongEmSymbol() {
|
|
1458
|
+
try {
|
|
1459
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1460
|
+
wasm.wasmconversionoptionsupdate_strongEmSymbol(retptr, this.__wbg_ptr);
|
|
1461
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1462
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1463
|
+
let v1;
|
|
1464
|
+
if (r0 !== 0) {
|
|
1465
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
1466
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
1467
|
+
}
|
|
1468
|
+
return v1;
|
|
1469
|
+
} finally {
|
|
1470
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1471
|
+
}
|
|
1472
|
+
}
|
|
1473
|
+
/**
|
|
1474
|
+
* @returns {string | undefined}
|
|
1475
|
+
*/
|
|
1476
|
+
get subSymbol() {
|
|
1477
|
+
try {
|
|
1478
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1479
|
+
wasm.wasmconversionoptionsupdate_subSymbol(retptr, this.__wbg_ptr);
|
|
1480
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1481
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1482
|
+
let v1;
|
|
1483
|
+
if (r0 !== 0) {
|
|
1484
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
1485
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
1486
|
+
}
|
|
1487
|
+
return v1;
|
|
1488
|
+
} finally {
|
|
1489
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1490
|
+
}
|
|
1491
|
+
}
|
|
1492
|
+
/**
|
|
1493
|
+
* @returns {string | undefined}
|
|
1494
|
+
*/
|
|
1495
|
+
get supSymbol() {
|
|
1496
|
+
try {
|
|
1497
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1498
|
+
wasm.wasmconversionoptionsupdate_supSymbol(retptr, this.__wbg_ptr);
|
|
1499
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1500
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1501
|
+
let v1;
|
|
1502
|
+
if (r0 !== 0) {
|
|
1503
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
1504
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
1505
|
+
}
|
|
1506
|
+
return v1;
|
|
1507
|
+
} finally {
|
|
1508
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1509
|
+
}
|
|
1510
|
+
}
|
|
1511
|
+
/**
|
|
1512
|
+
* @returns {WasmWhitespaceMode | undefined}
|
|
1513
|
+
*/
|
|
1514
|
+
get whitespaceMode() {
|
|
1515
|
+
const ret = wasm.wasmconversionoptionsupdate_whitespaceMode(this.__wbg_ptr);
|
|
1516
|
+
return ret === 2 ? undefined : ret;
|
|
1517
|
+
}
|
|
1518
|
+
/**
|
|
1519
|
+
* @returns {boolean | undefined}
|
|
1520
|
+
*/
|
|
1521
|
+
get wrap() {
|
|
1522
|
+
const ret = wasm.wasmconversionoptionsupdate_wrap(this.__wbg_ptr);
|
|
1523
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
1524
|
+
}
|
|
1525
|
+
/**
|
|
1526
|
+
* @returns {number | undefined}
|
|
1527
|
+
*/
|
|
1528
|
+
get wrapWidth() {
|
|
1529
|
+
const ret = wasm.wasmconversionoptionsupdate_wrapWidth(this.__wbg_ptr);
|
|
1530
|
+
return ret === 0x100000001 ? undefined : ret;
|
|
1531
|
+
}
|
|
1532
|
+
}
|
|
1533
|
+
if (Symbol.dispose) WasmConversionOptionsUpdate.prototype[Symbol.dispose] = WasmConversionOptionsUpdate.prototype.free;
|
|
1534
|
+
exports.WasmConversionOptionsUpdate = WasmConversionOptionsUpdate;
|
|
1535
|
+
|
|
1536
|
+
class WasmConversionResult {
|
|
1537
|
+
static __wrap(ptr) {
|
|
1538
|
+
ptr = ptr >>> 0;
|
|
1539
|
+
const obj = Object.create(WasmConversionResult.prototype);
|
|
1540
|
+
obj.__wbg_ptr = ptr;
|
|
1541
|
+
WasmConversionResultFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
1542
|
+
return obj;
|
|
1543
|
+
}
|
|
1544
|
+
__destroy_into_raw() {
|
|
1545
|
+
const ptr = this.__wbg_ptr;
|
|
1546
|
+
this.__wbg_ptr = 0;
|
|
1547
|
+
WasmConversionResultFinalization.unregister(this);
|
|
1548
|
+
return ptr;
|
|
1549
|
+
}
|
|
1550
|
+
free() {
|
|
1551
|
+
const ptr = this.__destroy_into_raw();
|
|
1552
|
+
wasm.__wbg_wasmconversionresult_free(ptr, 0);
|
|
1553
|
+
}
|
|
1554
|
+
/**
|
|
1555
|
+
* @returns {string | undefined}
|
|
1556
|
+
*/
|
|
1557
|
+
get content() {
|
|
1558
|
+
try {
|
|
1559
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1560
|
+
wasm.wasmconversionresult_content(retptr, this.__wbg_ptr);
|
|
1561
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1562
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1563
|
+
let v1;
|
|
1564
|
+
if (r0 !== 0) {
|
|
1565
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
1566
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
1567
|
+
}
|
|
1568
|
+
return v1;
|
|
1569
|
+
} finally {
|
|
1570
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1571
|
+
}
|
|
1572
|
+
}
|
|
1573
|
+
/**
|
|
1574
|
+
* @returns {WasmDocumentStructure | undefined}
|
|
1575
|
+
*/
|
|
1576
|
+
get document() {
|
|
1577
|
+
const ret = wasm.wasmconversionresult_document(this.__wbg_ptr);
|
|
1578
|
+
return ret === 0 ? undefined : WasmDocumentStructure.__wrap(ret);
|
|
1579
|
+
}
|
|
1580
|
+
/**
|
|
1581
|
+
* @returns {string[]}
|
|
1582
|
+
*/
|
|
1583
|
+
get images() {
|
|
1584
|
+
try {
|
|
1585
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1586
|
+
wasm.wasmconversionresult_images(retptr, this.__wbg_ptr);
|
|
1587
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1588
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1589
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
1590
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
1591
|
+
return v1;
|
|
1592
|
+
} finally {
|
|
1593
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1594
|
+
}
|
|
1595
|
+
}
|
|
1596
|
+
/**
|
|
1597
|
+
* @returns {WasmHtmlMetadata}
|
|
1598
|
+
*/
|
|
1599
|
+
get metadata() {
|
|
1600
|
+
const ret = wasm.wasmconversionresult_metadata(this.__wbg_ptr);
|
|
1601
|
+
return WasmHtmlMetadata.__wrap(ret);
|
|
1602
|
+
}
|
|
1603
|
+
/**
|
|
1604
|
+
* @param {WasmHtmlMetadata | null} [metadata]
|
|
1605
|
+
* @param {WasmTableData[] | null} [tables]
|
|
1606
|
+
* @param {string[] | null} [images]
|
|
1607
|
+
* @param {WasmProcessingWarning[] | null} [warnings]
|
|
1608
|
+
* @param {string | null} [content]
|
|
1609
|
+
* @param {WasmDocumentStructure | null} [document]
|
|
1610
|
+
*/
|
|
1611
|
+
constructor(metadata, tables, images, warnings, content, document) {
|
|
1612
|
+
let ptr0 = 0;
|
|
1613
|
+
if (!isLikeNone(metadata)) {
|
|
1614
|
+
_assertClass(metadata, WasmHtmlMetadata);
|
|
1615
|
+
ptr0 = metadata.__destroy_into_raw();
|
|
1616
|
+
}
|
|
1617
|
+
var ptr1 = isLikeNone(tables) ? 0 : passArrayJsValueToWasm0(tables, wasm.__wbindgen_export);
|
|
1618
|
+
var len1 = WASM_VECTOR_LEN;
|
|
1619
|
+
var ptr2 = isLikeNone(images) ? 0 : passArrayJsValueToWasm0(images, wasm.__wbindgen_export);
|
|
1620
|
+
var len2 = WASM_VECTOR_LEN;
|
|
1621
|
+
var ptr3 = isLikeNone(warnings) ? 0 : passArrayJsValueToWasm0(warnings, wasm.__wbindgen_export);
|
|
1622
|
+
var len3 = WASM_VECTOR_LEN;
|
|
1623
|
+
var ptr4 = isLikeNone(content) ? 0 : passStringToWasm0(content, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1624
|
+
var len4 = WASM_VECTOR_LEN;
|
|
1625
|
+
let ptr5 = 0;
|
|
1626
|
+
if (!isLikeNone(document)) {
|
|
1627
|
+
_assertClass(document, WasmDocumentStructure);
|
|
1628
|
+
ptr5 = document.__destroy_into_raw();
|
|
1629
|
+
}
|
|
1630
|
+
const ret = wasm.wasmconversionresult_new(ptr0, ptr1, len1, ptr2, len2, ptr3, len3, ptr4, len4, ptr5);
|
|
1631
|
+
this.__wbg_ptr = ret >>> 0;
|
|
1632
|
+
WasmConversionResultFinalization.register(this, this.__wbg_ptr, this);
|
|
1633
|
+
return this;
|
|
1634
|
+
}
|
|
1635
|
+
/**
|
|
1636
|
+
* @param {string | null} [value]
|
|
1637
|
+
*/
|
|
1638
|
+
set content(value) {
|
|
1639
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1640
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1641
|
+
wasm.wasmconversionresult_set_content(this.__wbg_ptr, ptr0, len0);
|
|
1642
|
+
}
|
|
1643
|
+
/**
|
|
1644
|
+
* @param {WasmDocumentStructure | null} [value]
|
|
1645
|
+
*/
|
|
1646
|
+
set document(value) {
|
|
1647
|
+
let ptr0 = 0;
|
|
1648
|
+
if (!isLikeNone(value)) {
|
|
1649
|
+
_assertClass(value, WasmDocumentStructure);
|
|
1650
|
+
ptr0 = value.__destroy_into_raw();
|
|
1651
|
+
}
|
|
1652
|
+
wasm.wasmconversionresult_set_document(this.__wbg_ptr, ptr0);
|
|
1653
|
+
}
|
|
1654
|
+
/**
|
|
1655
|
+
* @param {string[]} value
|
|
1656
|
+
*/
|
|
1657
|
+
set images(value) {
|
|
1658
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
1659
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1660
|
+
wasm.wasmconversionresult_set_images(this.__wbg_ptr, ptr0, len0);
|
|
1661
|
+
}
|
|
1662
|
+
/**
|
|
1663
|
+
* @param {WasmHtmlMetadata} value
|
|
1664
|
+
*/
|
|
1665
|
+
set metadata(value) {
|
|
1666
|
+
_assertClass(value, WasmHtmlMetadata);
|
|
1667
|
+
var ptr0 = value.__destroy_into_raw();
|
|
1668
|
+
wasm.wasmconversionresult_set_metadata(this.__wbg_ptr, ptr0);
|
|
1669
|
+
}
|
|
1670
|
+
/**
|
|
1671
|
+
* @param {WasmTableData[]} value
|
|
1672
|
+
*/
|
|
1673
|
+
set tables(value) {
|
|
1674
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
1675
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1676
|
+
wasm.wasmconversionresult_set_tables(this.__wbg_ptr, ptr0, len0);
|
|
1677
|
+
}
|
|
1678
|
+
/**
|
|
1679
|
+
* @param {WasmProcessingWarning[]} value
|
|
1680
|
+
*/
|
|
1681
|
+
set warnings(value) {
|
|
1682
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
1683
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1684
|
+
wasm.wasmconversionresult_set_warnings(this.__wbg_ptr, ptr0, len0);
|
|
1685
|
+
}
|
|
1686
|
+
/**
|
|
1687
|
+
* @returns {WasmTableData[]}
|
|
1688
|
+
*/
|
|
1689
|
+
get tables() {
|
|
1690
|
+
try {
|
|
1691
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1692
|
+
wasm.wasmconversionresult_tables(retptr, this.__wbg_ptr);
|
|
1693
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1694
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1695
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
1696
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
1697
|
+
return v1;
|
|
1698
|
+
} finally {
|
|
1699
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1700
|
+
}
|
|
1701
|
+
}
|
|
1702
|
+
/**
|
|
1703
|
+
* @returns {WasmProcessingWarning[]}
|
|
1704
|
+
*/
|
|
1705
|
+
get warnings() {
|
|
1706
|
+
try {
|
|
1707
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1708
|
+
wasm.wasmconversionresult_warnings(retptr, this.__wbg_ptr);
|
|
1709
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1710
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1711
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
1712
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
1713
|
+
return v1;
|
|
1714
|
+
} finally {
|
|
1715
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1716
|
+
}
|
|
1717
|
+
}
|
|
1718
|
+
}
|
|
1719
|
+
if (Symbol.dispose) WasmConversionResult.prototype[Symbol.dispose] = WasmConversionResult.prototype.free;
|
|
1720
|
+
exports.WasmConversionResult = WasmConversionResult;
|
|
1721
|
+
|
|
1722
|
+
class WasmDocumentMetadata {
|
|
1723
|
+
static __wrap(ptr) {
|
|
1724
|
+
ptr = ptr >>> 0;
|
|
1725
|
+
const obj = Object.create(WasmDocumentMetadata.prototype);
|
|
1726
|
+
obj.__wbg_ptr = ptr;
|
|
1727
|
+
WasmDocumentMetadataFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
1728
|
+
return obj;
|
|
1729
|
+
}
|
|
1730
|
+
__destroy_into_raw() {
|
|
1731
|
+
const ptr = this.__wbg_ptr;
|
|
1732
|
+
this.__wbg_ptr = 0;
|
|
1733
|
+
WasmDocumentMetadataFinalization.unregister(this);
|
|
1734
|
+
return ptr;
|
|
1735
|
+
}
|
|
1736
|
+
free() {
|
|
1737
|
+
const ptr = this.__destroy_into_raw();
|
|
1738
|
+
wasm.__wbg_wasmdocumentmetadata_free(ptr, 0);
|
|
1739
|
+
}
|
|
1740
|
+
/**
|
|
1741
|
+
* @returns {string | undefined}
|
|
1742
|
+
*/
|
|
1743
|
+
get author() {
|
|
1744
|
+
try {
|
|
1745
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1746
|
+
wasm.wasmdocumentmetadata_author(retptr, this.__wbg_ptr);
|
|
1747
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1748
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1749
|
+
let v1;
|
|
1750
|
+
if (r0 !== 0) {
|
|
1751
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
1752
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
1753
|
+
}
|
|
1754
|
+
return v1;
|
|
1755
|
+
} finally {
|
|
1756
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1757
|
+
}
|
|
1758
|
+
}
|
|
1759
|
+
/**
|
|
1760
|
+
* @returns {string | undefined}
|
|
1761
|
+
*/
|
|
1762
|
+
get baseHref() {
|
|
1763
|
+
try {
|
|
1764
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1765
|
+
wasm.wasmdocumentmetadata_baseHref(retptr, this.__wbg_ptr);
|
|
1766
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1767
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1768
|
+
let v1;
|
|
1769
|
+
if (r0 !== 0) {
|
|
1770
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
1771
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
1772
|
+
}
|
|
1773
|
+
return v1;
|
|
1774
|
+
} finally {
|
|
1775
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1776
|
+
}
|
|
1777
|
+
}
|
|
1778
|
+
/**
|
|
1779
|
+
* @returns {string | undefined}
|
|
1780
|
+
*/
|
|
1781
|
+
get canonicalUrl() {
|
|
1782
|
+
try {
|
|
1783
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1784
|
+
wasm.wasmdocumentmetadata_canonicalUrl(retptr, this.__wbg_ptr);
|
|
1785
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1786
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1787
|
+
let v1;
|
|
1788
|
+
if (r0 !== 0) {
|
|
1789
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
1790
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
1791
|
+
}
|
|
1792
|
+
return v1;
|
|
1793
|
+
} finally {
|
|
1794
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1795
|
+
}
|
|
1796
|
+
}
|
|
1797
|
+
/**
|
|
1798
|
+
* @returns {string | undefined}
|
|
1799
|
+
*/
|
|
1800
|
+
get description() {
|
|
1801
|
+
try {
|
|
1802
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1803
|
+
wasm.wasmdocumentmetadata_description(retptr, this.__wbg_ptr);
|
|
1804
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1805
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1806
|
+
let v1;
|
|
1807
|
+
if (r0 !== 0) {
|
|
1808
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
1809
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
1810
|
+
}
|
|
1811
|
+
return v1;
|
|
1812
|
+
} finally {
|
|
1813
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1814
|
+
}
|
|
1815
|
+
}
|
|
1816
|
+
/**
|
|
1817
|
+
* @returns {string[]}
|
|
1818
|
+
*/
|
|
1819
|
+
get keywords() {
|
|
1820
|
+
try {
|
|
1821
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1822
|
+
wasm.wasmdocumentmetadata_keywords(retptr, this.__wbg_ptr);
|
|
1823
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1824
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1825
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
1826
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
1827
|
+
return v1;
|
|
1828
|
+
} finally {
|
|
1829
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1830
|
+
}
|
|
1831
|
+
}
|
|
1832
|
+
/**
|
|
1833
|
+
* @returns {string | undefined}
|
|
1834
|
+
*/
|
|
1835
|
+
get language() {
|
|
1836
|
+
try {
|
|
1837
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1838
|
+
wasm.wasmdocumentmetadata_language(retptr, this.__wbg_ptr);
|
|
1839
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1840
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1841
|
+
let v1;
|
|
1842
|
+
if (r0 !== 0) {
|
|
1843
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
1844
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
1845
|
+
}
|
|
1846
|
+
return v1;
|
|
1847
|
+
} finally {
|
|
1848
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1849
|
+
}
|
|
1850
|
+
}
|
|
1851
|
+
/**
|
|
1852
|
+
* @returns {WasmConversionResult}
|
|
1853
|
+
*/
|
|
1854
|
+
get metaTags() {
|
|
1855
|
+
const ret = wasm.wasmdocumentmetadata_metaTags(this.__wbg_ptr);
|
|
1856
|
+
return takeObject(ret);
|
|
1857
|
+
}
|
|
1858
|
+
/**
|
|
1859
|
+
* @param {string[] | null} [keywords]
|
|
1860
|
+
* @param {any | null} [open_graph]
|
|
1861
|
+
* @param {any | null} [twitter_card]
|
|
1862
|
+
* @param {any | null} [meta_tags]
|
|
1863
|
+
* @param {string | null} [title]
|
|
1864
|
+
* @param {string | null} [description]
|
|
1865
|
+
* @param {string | null} [author]
|
|
1866
|
+
* @param {string | null} [canonical_url]
|
|
1867
|
+
* @param {string | null} [base_href]
|
|
1868
|
+
* @param {string | null} [language]
|
|
1869
|
+
* @param {WasmTextDirection | null} [text_direction]
|
|
1870
|
+
*/
|
|
1871
|
+
constructor(keywords, open_graph, twitter_card, meta_tags, title, description, author, canonical_url, base_href, language, text_direction) {
|
|
1872
|
+
var ptr0 = isLikeNone(keywords) ? 0 : passArrayJsValueToWasm0(keywords, wasm.__wbindgen_export);
|
|
1873
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1874
|
+
var ptr1 = isLikeNone(title) ? 0 : passStringToWasm0(title, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1875
|
+
var len1 = WASM_VECTOR_LEN;
|
|
1876
|
+
var ptr2 = isLikeNone(description) ? 0 : passStringToWasm0(description, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1877
|
+
var len2 = WASM_VECTOR_LEN;
|
|
1878
|
+
var ptr3 = isLikeNone(author) ? 0 : passStringToWasm0(author, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1879
|
+
var len3 = WASM_VECTOR_LEN;
|
|
1880
|
+
var ptr4 = isLikeNone(canonical_url) ? 0 : passStringToWasm0(canonical_url, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1881
|
+
var len4 = WASM_VECTOR_LEN;
|
|
1882
|
+
var ptr5 = isLikeNone(base_href) ? 0 : passStringToWasm0(base_href, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1883
|
+
var len5 = WASM_VECTOR_LEN;
|
|
1884
|
+
var ptr6 = isLikeNone(language) ? 0 : passStringToWasm0(language, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1885
|
+
var len6 = WASM_VECTOR_LEN;
|
|
1886
|
+
const ret = wasm.wasmdocumentmetadata_new(ptr0, len0, isLikeNone(open_graph) ? 0 : addHeapObject(open_graph), isLikeNone(twitter_card) ? 0 : addHeapObject(twitter_card), isLikeNone(meta_tags) ? 0 : addHeapObject(meta_tags), ptr1, len1, ptr2, len2, ptr3, len3, ptr4, len4, ptr5, len5, ptr6, len6, isLikeNone(text_direction) ? 3 : text_direction);
|
|
1887
|
+
this.__wbg_ptr = ret >>> 0;
|
|
1888
|
+
WasmDocumentMetadataFinalization.register(this, this.__wbg_ptr, this);
|
|
1889
|
+
return this;
|
|
1890
|
+
}
|
|
1891
|
+
/**
|
|
1892
|
+
* @returns {WasmConversionResult}
|
|
1893
|
+
*/
|
|
1894
|
+
get openGraph() {
|
|
1895
|
+
const ret = wasm.wasmdocumentmetadata_openGraph(this.__wbg_ptr);
|
|
1896
|
+
return takeObject(ret);
|
|
1897
|
+
}
|
|
1898
|
+
/**
|
|
1899
|
+
* @param {string | null} [value]
|
|
1900
|
+
*/
|
|
1901
|
+
set author(value) {
|
|
1902
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1903
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1904
|
+
wasm.wasmdocumentmetadata_set_author(this.__wbg_ptr, ptr0, len0);
|
|
1905
|
+
}
|
|
1906
|
+
/**
|
|
1907
|
+
* @param {string | null} [value]
|
|
1908
|
+
*/
|
|
1909
|
+
set baseHref(value) {
|
|
1910
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1911
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1912
|
+
wasm.wasmdocumentmetadata_set_baseHref(this.__wbg_ptr, ptr0, len0);
|
|
1913
|
+
}
|
|
1914
|
+
/**
|
|
1915
|
+
* @param {string | null} [value]
|
|
1916
|
+
*/
|
|
1917
|
+
set canonicalUrl(value) {
|
|
1918
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1919
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1920
|
+
wasm.wasmdocumentmetadata_set_canonicalUrl(this.__wbg_ptr, ptr0, len0);
|
|
1921
|
+
}
|
|
1922
|
+
/**
|
|
1923
|
+
* @param {string | null} [value]
|
|
1924
|
+
*/
|
|
1925
|
+
set description(value) {
|
|
1926
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1927
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1928
|
+
wasm.wasmdocumentmetadata_set_description(this.__wbg_ptr, ptr0, len0);
|
|
1929
|
+
}
|
|
1930
|
+
/**
|
|
1931
|
+
* @param {string[]} value
|
|
1932
|
+
*/
|
|
1933
|
+
set keywords(value) {
|
|
1934
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
1935
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1936
|
+
wasm.wasmdocumentmetadata_set_keywords(this.__wbg_ptr, ptr0, len0);
|
|
1937
|
+
}
|
|
1938
|
+
/**
|
|
1939
|
+
* @param {string | null} [value]
|
|
1940
|
+
*/
|
|
1941
|
+
set language(value) {
|
|
1942
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1943
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1944
|
+
wasm.wasmdocumentmetadata_set_language(this.__wbg_ptr, ptr0, len0);
|
|
1945
|
+
}
|
|
1946
|
+
/**
|
|
1947
|
+
* @param {any} value
|
|
1948
|
+
*/
|
|
1949
|
+
set metaTags(value) {
|
|
1950
|
+
wasm.wasmdocumentmetadata_set_metaTags(this.__wbg_ptr, addHeapObject(value));
|
|
1951
|
+
}
|
|
1952
|
+
/**
|
|
1953
|
+
* @param {any} value
|
|
1954
|
+
*/
|
|
1955
|
+
set openGraph(value) {
|
|
1956
|
+
wasm.wasmdocumentmetadata_set_openGraph(this.__wbg_ptr, addHeapObject(value));
|
|
1957
|
+
}
|
|
1958
|
+
/**
|
|
1959
|
+
* @param {WasmTextDirection | null} [value]
|
|
1960
|
+
*/
|
|
1961
|
+
set textDirection(value) {
|
|
1962
|
+
wasm.wasmdocumentmetadata_set_textDirection(this.__wbg_ptr, isLikeNone(value) ? 3 : value);
|
|
1963
|
+
}
|
|
1964
|
+
/**
|
|
1965
|
+
* @param {string | null} [value]
|
|
1966
|
+
*/
|
|
1967
|
+
set title(value) {
|
|
1968
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1969
|
+
var len0 = WASM_VECTOR_LEN;
|
|
1970
|
+
wasm.wasmdocumentmetadata_set_title(this.__wbg_ptr, ptr0, len0);
|
|
1971
|
+
}
|
|
1972
|
+
/**
|
|
1973
|
+
* @param {any} value
|
|
1974
|
+
*/
|
|
1975
|
+
set twitterCard(value) {
|
|
1976
|
+
wasm.wasmdocumentmetadata_set_twitterCard(this.__wbg_ptr, addHeapObject(value));
|
|
1977
|
+
}
|
|
1978
|
+
/**
|
|
1979
|
+
* @returns {WasmTextDirection | undefined}
|
|
1980
|
+
*/
|
|
1981
|
+
get textDirection() {
|
|
1982
|
+
const ret = wasm.wasmdocumentmetadata_textDirection(this.__wbg_ptr);
|
|
1983
|
+
return ret === 3 ? undefined : ret;
|
|
1984
|
+
}
|
|
1985
|
+
/**
|
|
1986
|
+
* @returns {string | undefined}
|
|
1987
|
+
*/
|
|
1988
|
+
get title() {
|
|
1989
|
+
try {
|
|
1990
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1991
|
+
wasm.wasmdocumentmetadata_title(retptr, this.__wbg_ptr);
|
|
1992
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
1993
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
1994
|
+
let v1;
|
|
1995
|
+
if (r0 !== 0) {
|
|
1996
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
1997
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
1998
|
+
}
|
|
1999
|
+
return v1;
|
|
2000
|
+
} finally {
|
|
2001
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2002
|
+
}
|
|
2003
|
+
}
|
|
2004
|
+
/**
|
|
2005
|
+
* @returns {WasmConversionResult}
|
|
2006
|
+
*/
|
|
2007
|
+
get twitterCard() {
|
|
2008
|
+
const ret = wasm.wasmdocumentmetadata_twitterCard(this.__wbg_ptr);
|
|
2009
|
+
return takeObject(ret);
|
|
2010
|
+
}
|
|
2011
|
+
}
|
|
2012
|
+
if (Symbol.dispose) WasmDocumentMetadata.prototype[Symbol.dispose] = WasmDocumentMetadata.prototype.free;
|
|
2013
|
+
exports.WasmDocumentMetadata = WasmDocumentMetadata;
|
|
2014
|
+
|
|
2015
|
+
class WasmDocumentNode {
|
|
2016
|
+
static __wrap(ptr) {
|
|
2017
|
+
ptr = ptr >>> 0;
|
|
2018
|
+
const obj = Object.create(WasmDocumentNode.prototype);
|
|
2019
|
+
obj.__wbg_ptr = ptr;
|
|
2020
|
+
WasmDocumentNodeFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2021
|
+
return obj;
|
|
2022
|
+
}
|
|
2023
|
+
static __unwrap(jsValue) {
|
|
2024
|
+
if (!(jsValue instanceof WasmDocumentNode)) {
|
|
2025
|
+
return 0;
|
|
2026
|
+
}
|
|
2027
|
+
return jsValue.__destroy_into_raw();
|
|
2028
|
+
}
|
|
2029
|
+
__destroy_into_raw() {
|
|
2030
|
+
const ptr = this.__wbg_ptr;
|
|
2031
|
+
this.__wbg_ptr = 0;
|
|
2032
|
+
WasmDocumentNodeFinalization.unregister(this);
|
|
2033
|
+
return ptr;
|
|
2034
|
+
}
|
|
2035
|
+
free() {
|
|
2036
|
+
const ptr = this.__destroy_into_raw();
|
|
2037
|
+
wasm.__wbg_wasmdocumentnode_free(ptr, 0);
|
|
2038
|
+
}
|
|
2039
|
+
/**
|
|
2040
|
+
* @returns {WasmTextAnnotation[]}
|
|
2041
|
+
*/
|
|
2042
|
+
get annotations() {
|
|
2043
|
+
try {
|
|
2044
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2045
|
+
wasm.wasmdocumentnode_annotations(retptr, this.__wbg_ptr);
|
|
2046
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2047
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2048
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
2049
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
2050
|
+
return v1;
|
|
2051
|
+
} finally {
|
|
2052
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2053
|
+
}
|
|
2054
|
+
}
|
|
2055
|
+
/**
|
|
2056
|
+
* @returns {any | undefined}
|
|
2057
|
+
*/
|
|
2058
|
+
get attributes() {
|
|
2059
|
+
const ret = wasm.wasmdocumentnode_attributes(this.__wbg_ptr);
|
|
2060
|
+
return takeObject(ret);
|
|
2061
|
+
}
|
|
2062
|
+
/**
|
|
2063
|
+
* @returns {Uint32Array}
|
|
2064
|
+
*/
|
|
2065
|
+
get children() {
|
|
2066
|
+
try {
|
|
2067
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2068
|
+
wasm.wasmdocumentnode_children(retptr, this.__wbg_ptr);
|
|
2069
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2070
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2071
|
+
var v1 = getArrayU32FromWasm0(r0, r1).slice();
|
|
2072
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
2073
|
+
return v1;
|
|
2074
|
+
} finally {
|
|
2075
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2076
|
+
}
|
|
2077
|
+
}
|
|
2078
|
+
/**
|
|
2079
|
+
* @returns {WasmNodeContent}
|
|
2080
|
+
*/
|
|
2081
|
+
get content() {
|
|
2082
|
+
const ret = wasm.wasmdocumentnode_content(this.__wbg_ptr);
|
|
2083
|
+
return ret;
|
|
2084
|
+
}
|
|
2085
|
+
/**
|
|
2086
|
+
* @returns {string}
|
|
2087
|
+
*/
|
|
2088
|
+
get id() {
|
|
2089
|
+
let deferred1_0;
|
|
2090
|
+
let deferred1_1;
|
|
2091
|
+
try {
|
|
2092
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2093
|
+
wasm.wasmdocumentnode_id(retptr, this.__wbg_ptr);
|
|
2094
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2095
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2096
|
+
deferred1_0 = r0;
|
|
2097
|
+
deferred1_1 = r1;
|
|
2098
|
+
return getStringFromWasm0(r0, r1);
|
|
2099
|
+
} finally {
|
|
2100
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2101
|
+
wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
|
|
2102
|
+
}
|
|
2103
|
+
}
|
|
2104
|
+
/**
|
|
2105
|
+
* @param {string} id
|
|
2106
|
+
* @param {WasmNodeContent} content
|
|
2107
|
+
* @param {Uint32Array} children
|
|
2108
|
+
* @param {WasmTextAnnotation[]} annotations
|
|
2109
|
+
* @param {number | null} [parent]
|
|
2110
|
+
* @param {any | null} [attributes]
|
|
2111
|
+
*/
|
|
2112
|
+
constructor(id, content, children, annotations, parent, attributes) {
|
|
2113
|
+
const ptr0 = passStringToWasm0(id, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2114
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2115
|
+
const ptr1 = passArray32ToWasm0(children, wasm.__wbindgen_export);
|
|
2116
|
+
const len1 = WASM_VECTOR_LEN;
|
|
2117
|
+
const ptr2 = passArrayJsValueToWasm0(annotations, wasm.__wbindgen_export);
|
|
2118
|
+
const len2 = WASM_VECTOR_LEN;
|
|
2119
|
+
const ret = wasm.wasmdocumentnode_new(ptr0, len0, content, ptr1, len1, ptr2, len2, isLikeNone(parent) ? 0x100000001 : (parent) >>> 0, isLikeNone(attributes) ? 0 : addHeapObject(attributes));
|
|
2120
|
+
this.__wbg_ptr = ret >>> 0;
|
|
2121
|
+
WasmDocumentNodeFinalization.register(this, this.__wbg_ptr, this);
|
|
2122
|
+
return this;
|
|
2123
|
+
}
|
|
2124
|
+
/**
|
|
2125
|
+
* @returns {number | undefined}
|
|
2126
|
+
*/
|
|
2127
|
+
get parent() {
|
|
2128
|
+
const ret = wasm.wasmdocumentnode_parent(this.__wbg_ptr);
|
|
2129
|
+
return ret === 0x100000001 ? undefined : ret;
|
|
2130
|
+
}
|
|
2131
|
+
/**
|
|
2132
|
+
* @param {WasmTextAnnotation[]} value
|
|
2133
|
+
*/
|
|
2134
|
+
set annotations(value) {
|
|
2135
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
2136
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2137
|
+
wasm.wasmdocumentnode_set_annotations(this.__wbg_ptr, ptr0, len0);
|
|
2138
|
+
}
|
|
2139
|
+
/**
|
|
2140
|
+
* @param {any | null} [value]
|
|
2141
|
+
*/
|
|
2142
|
+
set attributes(value) {
|
|
2143
|
+
wasm.wasmdocumentnode_set_attributes(this.__wbg_ptr, isLikeNone(value) ? 0 : addHeapObject(value));
|
|
2144
|
+
}
|
|
2145
|
+
/**
|
|
2146
|
+
* @param {Uint32Array} value
|
|
2147
|
+
*/
|
|
2148
|
+
set children(value) {
|
|
2149
|
+
const ptr0 = passArray32ToWasm0(value, wasm.__wbindgen_export);
|
|
2150
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2151
|
+
wasm.wasmdocumentnode_set_children(this.__wbg_ptr, ptr0, len0);
|
|
2152
|
+
}
|
|
2153
|
+
/**
|
|
2154
|
+
* @param {WasmNodeContent} value
|
|
2155
|
+
*/
|
|
2156
|
+
set content(value) {
|
|
2157
|
+
wasm.wasmdocumentnode_set_content(this.__wbg_ptr, value);
|
|
2158
|
+
}
|
|
2159
|
+
/**
|
|
2160
|
+
* @param {string} value
|
|
2161
|
+
*/
|
|
2162
|
+
set id(value) {
|
|
2163
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2164
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2165
|
+
wasm.wasmdocumentnode_set_id(this.__wbg_ptr, ptr0, len0);
|
|
2166
|
+
}
|
|
2167
|
+
/**
|
|
2168
|
+
* @param {number | null} [value]
|
|
2169
|
+
*/
|
|
2170
|
+
set parent(value) {
|
|
2171
|
+
wasm.wasmdocumentnode_set_parent(this.__wbg_ptr, isLikeNone(value) ? 0x100000001 : (value) >>> 0);
|
|
2172
|
+
}
|
|
2173
|
+
}
|
|
2174
|
+
if (Symbol.dispose) WasmDocumentNode.prototype[Symbol.dispose] = WasmDocumentNode.prototype.free;
|
|
2175
|
+
exports.WasmDocumentNode = WasmDocumentNode;
|
|
2176
|
+
|
|
2177
|
+
class WasmDocumentStructure {
|
|
2178
|
+
static __wrap(ptr) {
|
|
2179
|
+
ptr = ptr >>> 0;
|
|
2180
|
+
const obj = Object.create(WasmDocumentStructure.prototype);
|
|
2181
|
+
obj.__wbg_ptr = ptr;
|
|
2182
|
+
WasmDocumentStructureFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2183
|
+
return obj;
|
|
2184
|
+
}
|
|
2185
|
+
__destroy_into_raw() {
|
|
2186
|
+
const ptr = this.__wbg_ptr;
|
|
2187
|
+
this.__wbg_ptr = 0;
|
|
2188
|
+
WasmDocumentStructureFinalization.unregister(this);
|
|
2189
|
+
return ptr;
|
|
2190
|
+
}
|
|
2191
|
+
free() {
|
|
2192
|
+
const ptr = this.__destroy_into_raw();
|
|
2193
|
+
wasm.__wbg_wasmdocumentstructure_free(ptr, 0);
|
|
2194
|
+
}
|
|
2195
|
+
/**
|
|
2196
|
+
* @param {WasmDocumentNode[]} nodes
|
|
2197
|
+
* @param {string | null} [source_format]
|
|
2198
|
+
*/
|
|
2199
|
+
constructor(nodes, source_format) {
|
|
2200
|
+
const ptr0 = passArrayJsValueToWasm0(nodes, wasm.__wbindgen_export);
|
|
2201
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2202
|
+
var ptr1 = isLikeNone(source_format) ? 0 : passStringToWasm0(source_format, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2203
|
+
var len1 = WASM_VECTOR_LEN;
|
|
2204
|
+
const ret = wasm.wasmdocumentstructure_new(ptr0, len0, ptr1, len1);
|
|
2205
|
+
this.__wbg_ptr = ret >>> 0;
|
|
2206
|
+
WasmDocumentStructureFinalization.register(this, this.__wbg_ptr, this);
|
|
2207
|
+
return this;
|
|
2208
|
+
}
|
|
2209
|
+
/**
|
|
2210
|
+
* @returns {WasmDocumentNode[]}
|
|
2211
|
+
*/
|
|
2212
|
+
get nodes() {
|
|
2213
|
+
try {
|
|
2214
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2215
|
+
wasm.wasmdocumentstructure_nodes(retptr, this.__wbg_ptr);
|
|
2216
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2217
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2218
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
2219
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
2220
|
+
return v1;
|
|
2221
|
+
} finally {
|
|
2222
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2223
|
+
}
|
|
2224
|
+
}
|
|
2225
|
+
/**
|
|
2226
|
+
* @param {WasmDocumentNode[]} value
|
|
2227
|
+
*/
|
|
2228
|
+
set nodes(value) {
|
|
2229
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
2230
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2231
|
+
wasm.wasmdocumentstructure_set_nodes(this.__wbg_ptr, ptr0, len0);
|
|
2232
|
+
}
|
|
2233
|
+
/**
|
|
2234
|
+
* @param {string | null} [value]
|
|
2235
|
+
*/
|
|
2236
|
+
set sourceFormat(value) {
|
|
2237
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2238
|
+
var len0 = WASM_VECTOR_LEN;
|
|
2239
|
+
wasm.wasmdocumentstructure_set_sourceFormat(this.__wbg_ptr, ptr0, len0);
|
|
2240
|
+
}
|
|
2241
|
+
/**
|
|
2242
|
+
* @returns {string | undefined}
|
|
2243
|
+
*/
|
|
2244
|
+
get sourceFormat() {
|
|
2245
|
+
try {
|
|
2246
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2247
|
+
wasm.wasmdocumentstructure_sourceFormat(retptr, this.__wbg_ptr);
|
|
2248
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2249
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2250
|
+
let v1;
|
|
2251
|
+
if (r0 !== 0) {
|
|
2252
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
2253
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
2254
|
+
}
|
|
2255
|
+
return v1;
|
|
2256
|
+
} finally {
|
|
2257
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2258
|
+
}
|
|
2259
|
+
}
|
|
2260
|
+
}
|
|
2261
|
+
if (Symbol.dispose) WasmDocumentStructure.prototype[Symbol.dispose] = WasmDocumentStructure.prototype.free;
|
|
2262
|
+
exports.WasmDocumentStructure = WasmDocumentStructure;
|
|
2263
|
+
|
|
2264
|
+
class WasmGridCell {
|
|
2265
|
+
static __wrap(ptr) {
|
|
2266
|
+
ptr = ptr >>> 0;
|
|
2267
|
+
const obj = Object.create(WasmGridCell.prototype);
|
|
2268
|
+
obj.__wbg_ptr = ptr;
|
|
2269
|
+
WasmGridCellFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2270
|
+
return obj;
|
|
2271
|
+
}
|
|
2272
|
+
static __unwrap(jsValue) {
|
|
2273
|
+
if (!(jsValue instanceof WasmGridCell)) {
|
|
2274
|
+
return 0;
|
|
2275
|
+
}
|
|
2276
|
+
return jsValue.__destroy_into_raw();
|
|
2277
|
+
}
|
|
2278
|
+
__destroy_into_raw() {
|
|
2279
|
+
const ptr = this.__wbg_ptr;
|
|
2280
|
+
this.__wbg_ptr = 0;
|
|
2281
|
+
WasmGridCellFinalization.unregister(this);
|
|
2282
|
+
return ptr;
|
|
2283
|
+
}
|
|
2284
|
+
free() {
|
|
2285
|
+
const ptr = this.__destroy_into_raw();
|
|
2286
|
+
wasm.__wbg_wasmgridcell_free(ptr, 0);
|
|
2287
|
+
}
|
|
2288
|
+
/**
|
|
2289
|
+
* @returns {number}
|
|
2290
|
+
*/
|
|
2291
|
+
get col() {
|
|
2292
|
+
const ret = wasm.wasmgridcell_col(this.__wbg_ptr);
|
|
2293
|
+
return ret >>> 0;
|
|
2294
|
+
}
|
|
2295
|
+
/**
|
|
2296
|
+
* @returns {number}
|
|
2297
|
+
*/
|
|
2298
|
+
get colSpan() {
|
|
2299
|
+
const ret = wasm.wasmgridcell_colSpan(this.__wbg_ptr);
|
|
2300
|
+
return ret >>> 0;
|
|
2301
|
+
}
|
|
2302
|
+
/**
|
|
2303
|
+
* @returns {string}
|
|
2304
|
+
*/
|
|
2305
|
+
get content() {
|
|
2306
|
+
let deferred1_0;
|
|
2307
|
+
let deferred1_1;
|
|
2308
|
+
try {
|
|
2309
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2310
|
+
wasm.wasmgridcell_content(retptr, this.__wbg_ptr);
|
|
2311
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2312
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2313
|
+
deferred1_0 = r0;
|
|
2314
|
+
deferred1_1 = r1;
|
|
2315
|
+
return getStringFromWasm0(r0, r1);
|
|
2316
|
+
} finally {
|
|
2317
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2318
|
+
wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
|
|
2319
|
+
}
|
|
2320
|
+
}
|
|
2321
|
+
/**
|
|
2322
|
+
* @returns {boolean}
|
|
2323
|
+
*/
|
|
2324
|
+
get isHeader() {
|
|
2325
|
+
const ret = wasm.wasmgridcell_isHeader(this.__wbg_ptr);
|
|
2326
|
+
return ret !== 0;
|
|
2327
|
+
}
|
|
2328
|
+
/**
|
|
2329
|
+
* @param {string} content
|
|
2330
|
+
* @param {number} row
|
|
2331
|
+
* @param {number} col
|
|
2332
|
+
* @param {number} row_span
|
|
2333
|
+
* @param {number} col_span
|
|
2334
|
+
* @param {boolean} is_header
|
|
2335
|
+
*/
|
|
2336
|
+
constructor(content, row, col, row_span, col_span, is_header) {
|
|
2337
|
+
const ptr0 = passStringToWasm0(content, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2338
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2339
|
+
const ret = wasm.wasmgridcell_new(ptr0, len0, row, col, row_span, col_span, is_header);
|
|
2340
|
+
this.__wbg_ptr = ret >>> 0;
|
|
2341
|
+
WasmGridCellFinalization.register(this, this.__wbg_ptr, this);
|
|
2342
|
+
return this;
|
|
2343
|
+
}
|
|
2344
|
+
/**
|
|
2345
|
+
* @returns {number}
|
|
2346
|
+
*/
|
|
2347
|
+
get row() {
|
|
2348
|
+
const ret = wasm.wasmgridcell_row(this.__wbg_ptr);
|
|
2349
|
+
return ret >>> 0;
|
|
2350
|
+
}
|
|
2351
|
+
/**
|
|
2352
|
+
* @returns {number}
|
|
2353
|
+
*/
|
|
2354
|
+
get rowSpan() {
|
|
2355
|
+
const ret = wasm.wasmgridcell_rowSpan(this.__wbg_ptr);
|
|
2356
|
+
return ret >>> 0;
|
|
2357
|
+
}
|
|
2358
|
+
/**
|
|
2359
|
+
* @param {number} value
|
|
2360
|
+
*/
|
|
2361
|
+
set col(value) {
|
|
2362
|
+
wasm.wasmgridcell_set_col(this.__wbg_ptr, value);
|
|
2363
|
+
}
|
|
2364
|
+
/**
|
|
2365
|
+
* @param {number} value
|
|
2366
|
+
*/
|
|
2367
|
+
set colSpan(value) {
|
|
2368
|
+
wasm.wasmgridcell_set_colSpan(this.__wbg_ptr, value);
|
|
2369
|
+
}
|
|
2370
|
+
/**
|
|
2371
|
+
* @param {string} value
|
|
2372
|
+
*/
|
|
2373
|
+
set content(value) {
|
|
2374
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2375
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2376
|
+
wasm.wasmgridcell_set_content(this.__wbg_ptr, ptr0, len0);
|
|
2377
|
+
}
|
|
2378
|
+
/**
|
|
2379
|
+
* @param {boolean} value
|
|
2380
|
+
*/
|
|
2381
|
+
set isHeader(value) {
|
|
2382
|
+
wasm.wasmgridcell_set_isHeader(this.__wbg_ptr, value);
|
|
2383
|
+
}
|
|
2384
|
+
/**
|
|
2385
|
+
* @param {number} value
|
|
2386
|
+
*/
|
|
2387
|
+
set row(value) {
|
|
2388
|
+
wasm.wasmgridcell_set_row(this.__wbg_ptr, value);
|
|
2389
|
+
}
|
|
2390
|
+
/**
|
|
2391
|
+
* @param {number} value
|
|
2392
|
+
*/
|
|
2393
|
+
set rowSpan(value) {
|
|
2394
|
+
wasm.wasmgridcell_set_rowSpan(this.__wbg_ptr, value);
|
|
2395
|
+
}
|
|
2396
|
+
}
|
|
2397
|
+
if (Symbol.dispose) WasmGridCell.prototype[Symbol.dispose] = WasmGridCell.prototype.free;
|
|
2398
|
+
exports.WasmGridCell = WasmGridCell;
|
|
2399
|
+
|
|
2400
|
+
class WasmHeaderMetadata {
|
|
2401
|
+
static __wrap(ptr) {
|
|
2402
|
+
ptr = ptr >>> 0;
|
|
2403
|
+
const obj = Object.create(WasmHeaderMetadata.prototype);
|
|
2404
|
+
obj.__wbg_ptr = ptr;
|
|
2405
|
+
WasmHeaderMetadataFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2406
|
+
return obj;
|
|
2407
|
+
}
|
|
2408
|
+
static __unwrap(jsValue) {
|
|
2409
|
+
if (!(jsValue instanceof WasmHeaderMetadata)) {
|
|
2410
|
+
return 0;
|
|
2411
|
+
}
|
|
2412
|
+
return jsValue.__destroy_into_raw();
|
|
2413
|
+
}
|
|
2414
|
+
__destroy_into_raw() {
|
|
2415
|
+
const ptr = this.__wbg_ptr;
|
|
2416
|
+
this.__wbg_ptr = 0;
|
|
2417
|
+
WasmHeaderMetadataFinalization.unregister(this);
|
|
2418
|
+
return ptr;
|
|
2419
|
+
}
|
|
2420
|
+
free() {
|
|
2421
|
+
const ptr = this.__destroy_into_raw();
|
|
2422
|
+
wasm.__wbg_wasmheadermetadata_free(ptr, 0);
|
|
2423
|
+
}
|
|
2424
|
+
/**
|
|
2425
|
+
* @returns {number}
|
|
2426
|
+
*/
|
|
2427
|
+
get depth() {
|
|
2428
|
+
const ret = wasm.wasmheadermetadata_depth(this.__wbg_ptr);
|
|
2429
|
+
return ret >>> 0;
|
|
2430
|
+
}
|
|
2431
|
+
/**
|
|
2432
|
+
* @returns {number}
|
|
2433
|
+
*/
|
|
2434
|
+
get htmlOffset() {
|
|
2435
|
+
const ret = wasm.wasmheadermetadata_htmlOffset(this.__wbg_ptr);
|
|
2436
|
+
return ret >>> 0;
|
|
2437
|
+
}
|
|
2438
|
+
/**
|
|
2439
|
+
* @returns {string | undefined}
|
|
2440
|
+
*/
|
|
2441
|
+
get id() {
|
|
2442
|
+
try {
|
|
2443
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2444
|
+
wasm.wasmheadermetadata_id(retptr, this.__wbg_ptr);
|
|
2445
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2446
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2447
|
+
let v1;
|
|
2448
|
+
if (r0 !== 0) {
|
|
2449
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
2450
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
2451
|
+
}
|
|
2452
|
+
return v1;
|
|
2453
|
+
} finally {
|
|
2454
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2455
|
+
}
|
|
2456
|
+
}
|
|
2457
|
+
/**
|
|
2458
|
+
* @returns {boolean}
|
|
2459
|
+
*/
|
|
2460
|
+
isValid() {
|
|
2461
|
+
const ret = wasm.wasmheadermetadata_isValid(this.__wbg_ptr);
|
|
2462
|
+
return ret !== 0;
|
|
2463
|
+
}
|
|
2464
|
+
/**
|
|
2465
|
+
* @returns {number}
|
|
2466
|
+
*/
|
|
2467
|
+
get level() {
|
|
2468
|
+
const ret = wasm.wasmheadermetadata_level(this.__wbg_ptr);
|
|
2469
|
+
return ret;
|
|
2470
|
+
}
|
|
2471
|
+
/**
|
|
2472
|
+
* @param {number} level
|
|
2473
|
+
* @param {string} text
|
|
2474
|
+
* @param {number} depth
|
|
2475
|
+
* @param {number} html_offset
|
|
2476
|
+
* @param {string | null} [id]
|
|
2477
|
+
*/
|
|
2478
|
+
constructor(level, text, depth, html_offset, id) {
|
|
2479
|
+
const ptr0 = passStringToWasm0(text, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2480
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2481
|
+
var ptr1 = isLikeNone(id) ? 0 : passStringToWasm0(id, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2482
|
+
var len1 = WASM_VECTOR_LEN;
|
|
2483
|
+
const ret = wasm.wasmheadermetadata_new(level, ptr0, len0, depth, html_offset, ptr1, len1);
|
|
2484
|
+
this.__wbg_ptr = ret >>> 0;
|
|
2485
|
+
WasmHeaderMetadataFinalization.register(this, this.__wbg_ptr, this);
|
|
2486
|
+
return this;
|
|
2487
|
+
}
|
|
2488
|
+
/**
|
|
2489
|
+
* @param {number} value
|
|
2490
|
+
*/
|
|
2491
|
+
set depth(value) {
|
|
2492
|
+
wasm.wasmheadermetadata_set_depth(this.__wbg_ptr, value);
|
|
2493
|
+
}
|
|
2494
|
+
/**
|
|
2495
|
+
* @param {number} value
|
|
2496
|
+
*/
|
|
2497
|
+
set htmlOffset(value) {
|
|
2498
|
+
wasm.wasmheadermetadata_set_htmlOffset(this.__wbg_ptr, value);
|
|
2499
|
+
}
|
|
2500
|
+
/**
|
|
2501
|
+
* @param {string | null} [value]
|
|
2502
|
+
*/
|
|
2503
|
+
set id(value) {
|
|
2504
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2505
|
+
var len0 = WASM_VECTOR_LEN;
|
|
2506
|
+
wasm.wasmheadermetadata_set_id(this.__wbg_ptr, ptr0, len0);
|
|
2507
|
+
}
|
|
2508
|
+
/**
|
|
2509
|
+
* @param {number} value
|
|
2510
|
+
*/
|
|
2511
|
+
set level(value) {
|
|
2512
|
+
wasm.wasmheadermetadata_set_level(this.__wbg_ptr, value);
|
|
2513
|
+
}
|
|
2514
|
+
/**
|
|
2515
|
+
* @param {string} value
|
|
2516
|
+
*/
|
|
2517
|
+
set text(value) {
|
|
2518
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2519
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2520
|
+
wasm.wasmheadermetadata_set_text(this.__wbg_ptr, ptr0, len0);
|
|
2521
|
+
}
|
|
2522
|
+
/**
|
|
2523
|
+
* @returns {string}
|
|
2524
|
+
*/
|
|
2525
|
+
get text() {
|
|
2526
|
+
let deferred1_0;
|
|
2527
|
+
let deferred1_1;
|
|
2528
|
+
try {
|
|
2529
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2530
|
+
wasm.wasmheadermetadata_text(retptr, this.__wbg_ptr);
|
|
2531
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2532
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2533
|
+
deferred1_0 = r0;
|
|
2534
|
+
deferred1_1 = r1;
|
|
2535
|
+
return getStringFromWasm0(r0, r1);
|
|
2536
|
+
} finally {
|
|
2537
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2538
|
+
wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
|
|
2539
|
+
}
|
|
2540
|
+
}
|
|
2541
|
+
}
|
|
2542
|
+
if (Symbol.dispose) WasmHeaderMetadata.prototype[Symbol.dispose] = WasmHeaderMetadata.prototype.free;
|
|
2543
|
+
exports.WasmHeaderMetadata = WasmHeaderMetadata;
|
|
2544
|
+
|
|
2545
|
+
/**
|
|
2546
|
+
* @enum {0 | 1 | 2}
|
|
2547
|
+
*/
|
|
2548
|
+
const WasmHeadingStyle = Object.freeze({
|
|
2549
|
+
Underlined: 0, "0": "Underlined",
|
|
2550
|
+
Atx: 1, "1": "Atx",
|
|
2551
|
+
AtxClosed: 2, "2": "AtxClosed",
|
|
2552
|
+
});
|
|
2553
|
+
exports.WasmHeadingStyle = WasmHeadingStyle;
|
|
2554
|
+
|
|
2555
|
+
/**
|
|
2556
|
+
* @enum {0 | 1 | 2 | 3}
|
|
2557
|
+
*/
|
|
2558
|
+
const WasmHighlightStyle = Object.freeze({
|
|
2559
|
+
DoubleEqual: 0, "0": "DoubleEqual",
|
|
2560
|
+
Html: 1, "1": "Html",
|
|
2561
|
+
Bold: 2, "2": "Bold",
|
|
2562
|
+
None: 3, "3": "None",
|
|
2563
|
+
});
|
|
2564
|
+
exports.WasmHighlightStyle = WasmHighlightStyle;
|
|
2565
|
+
|
|
2566
|
+
class WasmHtmlMetadata {
|
|
2567
|
+
static __wrap(ptr) {
|
|
2568
|
+
ptr = ptr >>> 0;
|
|
2569
|
+
const obj = Object.create(WasmHtmlMetadata.prototype);
|
|
2570
|
+
obj.__wbg_ptr = ptr;
|
|
2571
|
+
WasmHtmlMetadataFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2572
|
+
return obj;
|
|
2573
|
+
}
|
|
2574
|
+
__destroy_into_raw() {
|
|
2575
|
+
const ptr = this.__wbg_ptr;
|
|
2576
|
+
this.__wbg_ptr = 0;
|
|
2577
|
+
WasmHtmlMetadataFinalization.unregister(this);
|
|
2578
|
+
return ptr;
|
|
2579
|
+
}
|
|
2580
|
+
free() {
|
|
2581
|
+
const ptr = this.__destroy_into_raw();
|
|
2582
|
+
wasm.__wbg_wasmhtmlmetadata_free(ptr, 0);
|
|
2583
|
+
}
|
|
2584
|
+
/**
|
|
2585
|
+
* @returns {WasmDocumentMetadata}
|
|
2586
|
+
*/
|
|
2587
|
+
get document() {
|
|
2588
|
+
const ret = wasm.wasmhtmlmetadata_document(this.__wbg_ptr);
|
|
2589
|
+
return WasmDocumentMetadata.__wrap(ret);
|
|
2590
|
+
}
|
|
2591
|
+
/**
|
|
2592
|
+
* @returns {WasmHeaderMetadata[]}
|
|
2593
|
+
*/
|
|
2594
|
+
get headers() {
|
|
2595
|
+
try {
|
|
2596
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2597
|
+
wasm.wasmhtmlmetadata_headers(retptr, this.__wbg_ptr);
|
|
2598
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2599
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2600
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
2601
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
2602
|
+
return v1;
|
|
2603
|
+
} finally {
|
|
2604
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2605
|
+
}
|
|
2606
|
+
}
|
|
2607
|
+
/**
|
|
2608
|
+
* @returns {WasmImageMetadata[]}
|
|
2609
|
+
*/
|
|
2610
|
+
get images() {
|
|
2611
|
+
try {
|
|
2612
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2613
|
+
wasm.wasmhtmlmetadata_images(retptr, this.__wbg_ptr);
|
|
2614
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2615
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2616
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
2617
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
2618
|
+
return v1;
|
|
2619
|
+
} finally {
|
|
2620
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2621
|
+
}
|
|
2622
|
+
}
|
|
2623
|
+
/**
|
|
2624
|
+
* @returns {WasmLinkMetadata[]}
|
|
2625
|
+
*/
|
|
2626
|
+
get links() {
|
|
2627
|
+
try {
|
|
2628
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2629
|
+
wasm.wasmhtmlmetadata_links(retptr, this.__wbg_ptr);
|
|
2630
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2631
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2632
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
2633
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
2634
|
+
return v1;
|
|
2635
|
+
} finally {
|
|
2636
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2637
|
+
}
|
|
2638
|
+
}
|
|
2639
|
+
/**
|
|
2640
|
+
* @param {WasmDocumentMetadata | null} [document]
|
|
2641
|
+
* @param {WasmHeaderMetadata[] | null} [headers]
|
|
2642
|
+
* @param {WasmLinkMetadata[] | null} [links]
|
|
2643
|
+
* @param {WasmImageMetadata[] | null} [images]
|
|
2644
|
+
* @param {WasmStructuredData[] | null} [structured_data]
|
|
2645
|
+
*/
|
|
2646
|
+
constructor(document, headers, links, images, structured_data) {
|
|
2647
|
+
let ptr0 = 0;
|
|
2648
|
+
if (!isLikeNone(document)) {
|
|
2649
|
+
_assertClass(document, WasmDocumentMetadata);
|
|
2650
|
+
ptr0 = document.__destroy_into_raw();
|
|
2651
|
+
}
|
|
2652
|
+
var ptr1 = isLikeNone(headers) ? 0 : passArrayJsValueToWasm0(headers, wasm.__wbindgen_export);
|
|
2653
|
+
var len1 = WASM_VECTOR_LEN;
|
|
2654
|
+
var ptr2 = isLikeNone(links) ? 0 : passArrayJsValueToWasm0(links, wasm.__wbindgen_export);
|
|
2655
|
+
var len2 = WASM_VECTOR_LEN;
|
|
2656
|
+
var ptr3 = isLikeNone(images) ? 0 : passArrayJsValueToWasm0(images, wasm.__wbindgen_export);
|
|
2657
|
+
var len3 = WASM_VECTOR_LEN;
|
|
2658
|
+
var ptr4 = isLikeNone(structured_data) ? 0 : passArrayJsValueToWasm0(structured_data, wasm.__wbindgen_export);
|
|
2659
|
+
var len4 = WASM_VECTOR_LEN;
|
|
2660
|
+
const ret = wasm.wasmhtmlmetadata_new(ptr0, ptr1, len1, ptr2, len2, ptr3, len3, ptr4, len4);
|
|
2661
|
+
this.__wbg_ptr = ret >>> 0;
|
|
2662
|
+
WasmHtmlMetadataFinalization.register(this, this.__wbg_ptr, this);
|
|
2663
|
+
return this;
|
|
2664
|
+
}
|
|
2665
|
+
/**
|
|
2666
|
+
* @param {WasmDocumentMetadata} value
|
|
2667
|
+
*/
|
|
2668
|
+
set document(value) {
|
|
2669
|
+
_assertClass(value, WasmDocumentMetadata);
|
|
2670
|
+
var ptr0 = value.__destroy_into_raw();
|
|
2671
|
+
wasm.wasmhtmlmetadata_set_document(this.__wbg_ptr, ptr0);
|
|
2672
|
+
}
|
|
2673
|
+
/**
|
|
2674
|
+
* @param {WasmHeaderMetadata[]} value
|
|
2675
|
+
*/
|
|
2676
|
+
set headers(value) {
|
|
2677
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
2678
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2679
|
+
wasm.wasmhtmlmetadata_set_headers(this.__wbg_ptr, ptr0, len0);
|
|
2680
|
+
}
|
|
2681
|
+
/**
|
|
2682
|
+
* @param {WasmImageMetadata[]} value
|
|
2683
|
+
*/
|
|
2684
|
+
set images(value) {
|
|
2685
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
2686
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2687
|
+
wasm.wasmhtmlmetadata_set_images(this.__wbg_ptr, ptr0, len0);
|
|
2688
|
+
}
|
|
2689
|
+
/**
|
|
2690
|
+
* @param {WasmLinkMetadata[]} value
|
|
2691
|
+
*/
|
|
2692
|
+
set links(value) {
|
|
2693
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
2694
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2695
|
+
wasm.wasmhtmlmetadata_set_links(this.__wbg_ptr, ptr0, len0);
|
|
2696
|
+
}
|
|
2697
|
+
/**
|
|
2698
|
+
* @param {WasmStructuredData[]} value
|
|
2699
|
+
*/
|
|
2700
|
+
set structuredData(value) {
|
|
2701
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
2702
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2703
|
+
wasm.wasmhtmlmetadata_set_structuredData(this.__wbg_ptr, ptr0, len0);
|
|
2704
|
+
}
|
|
2705
|
+
/**
|
|
2706
|
+
* @returns {WasmStructuredData[]}
|
|
2707
|
+
*/
|
|
2708
|
+
get structuredData() {
|
|
2709
|
+
try {
|
|
2710
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2711
|
+
wasm.wasmhtmlmetadata_structuredData(retptr, this.__wbg_ptr);
|
|
2712
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2713
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2714
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
2715
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
2716
|
+
return v1;
|
|
2717
|
+
} finally {
|
|
2718
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2719
|
+
}
|
|
2720
|
+
}
|
|
2721
|
+
}
|
|
2722
|
+
if (Symbol.dispose) WasmHtmlMetadata.prototype[Symbol.dispose] = WasmHtmlMetadata.prototype.free;
|
|
2723
|
+
exports.WasmHtmlMetadata = WasmHtmlMetadata;
|
|
2724
|
+
|
|
2725
|
+
class WasmImageMetadata {
|
|
2726
|
+
static __wrap(ptr) {
|
|
2727
|
+
ptr = ptr >>> 0;
|
|
2728
|
+
const obj = Object.create(WasmImageMetadata.prototype);
|
|
2729
|
+
obj.__wbg_ptr = ptr;
|
|
2730
|
+
WasmImageMetadataFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2731
|
+
return obj;
|
|
2732
|
+
}
|
|
2733
|
+
static __unwrap(jsValue) {
|
|
2734
|
+
if (!(jsValue instanceof WasmImageMetadata)) {
|
|
2735
|
+
return 0;
|
|
2736
|
+
}
|
|
2737
|
+
return jsValue.__destroy_into_raw();
|
|
2738
|
+
}
|
|
2739
|
+
__destroy_into_raw() {
|
|
2740
|
+
const ptr = this.__wbg_ptr;
|
|
2741
|
+
this.__wbg_ptr = 0;
|
|
2742
|
+
WasmImageMetadataFinalization.unregister(this);
|
|
2743
|
+
return ptr;
|
|
2744
|
+
}
|
|
2745
|
+
free() {
|
|
2746
|
+
const ptr = this.__destroy_into_raw();
|
|
2747
|
+
wasm.__wbg_wasmimagemetadata_free(ptr, 0);
|
|
2748
|
+
}
|
|
2749
|
+
/**
|
|
2750
|
+
* @returns {string | undefined}
|
|
2751
|
+
*/
|
|
2752
|
+
get alt() {
|
|
2753
|
+
try {
|
|
2754
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2755
|
+
wasm.wasmimagemetadata_alt(retptr, this.__wbg_ptr);
|
|
2756
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2757
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2758
|
+
let v1;
|
|
2759
|
+
if (r0 !== 0) {
|
|
2760
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
2761
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
2762
|
+
}
|
|
2763
|
+
return v1;
|
|
2764
|
+
} finally {
|
|
2765
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2766
|
+
}
|
|
2767
|
+
}
|
|
2768
|
+
/**
|
|
2769
|
+
* @returns {WasmConversionResult}
|
|
2770
|
+
*/
|
|
2771
|
+
get attributes() {
|
|
2772
|
+
const ret = wasm.wasmimagemetadata_attributes(this.__wbg_ptr);
|
|
2773
|
+
return takeObject(ret);
|
|
2774
|
+
}
|
|
2775
|
+
/**
|
|
2776
|
+
* @returns {string | undefined}
|
|
2777
|
+
*/
|
|
2778
|
+
get dimensions() {
|
|
2779
|
+
try {
|
|
2780
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2781
|
+
wasm.wasmimagemetadata_dimensions(retptr, this.__wbg_ptr);
|
|
2782
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2783
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2784
|
+
let v1;
|
|
2785
|
+
if (r0 !== 0) {
|
|
2786
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
2787
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
2788
|
+
}
|
|
2789
|
+
return v1;
|
|
2790
|
+
} finally {
|
|
2791
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2792
|
+
}
|
|
2793
|
+
}
|
|
2794
|
+
/**
|
|
2795
|
+
* @returns {WasmImageType}
|
|
2796
|
+
*/
|
|
2797
|
+
get imageType() {
|
|
2798
|
+
const ret = wasm.wasmimagemetadata_imageType(this.__wbg_ptr);
|
|
2799
|
+
return ret;
|
|
2800
|
+
}
|
|
2801
|
+
/**
|
|
2802
|
+
* @param {string} src
|
|
2803
|
+
* @param {WasmImageType} image_type
|
|
2804
|
+
* @param {any} attributes
|
|
2805
|
+
* @param {string | null} [alt]
|
|
2806
|
+
* @param {string | null} [title]
|
|
2807
|
+
* @param {string | null} [dimensions]
|
|
2808
|
+
*/
|
|
2809
|
+
constructor(src, image_type, attributes, alt, title, dimensions) {
|
|
2810
|
+
const ptr0 = passStringToWasm0(src, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2811
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2812
|
+
var ptr1 = isLikeNone(alt) ? 0 : passStringToWasm0(alt, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2813
|
+
var len1 = WASM_VECTOR_LEN;
|
|
2814
|
+
var ptr2 = isLikeNone(title) ? 0 : passStringToWasm0(title, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2815
|
+
var len2 = WASM_VECTOR_LEN;
|
|
2816
|
+
var ptr3 = isLikeNone(dimensions) ? 0 : passStringToWasm0(dimensions, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2817
|
+
var len3 = WASM_VECTOR_LEN;
|
|
2818
|
+
const ret = wasm.wasmimagemetadata_new(ptr0, len0, image_type, addHeapObject(attributes), ptr1, len1, ptr2, len2, ptr3, len3);
|
|
2819
|
+
this.__wbg_ptr = ret >>> 0;
|
|
2820
|
+
WasmImageMetadataFinalization.register(this, this.__wbg_ptr, this);
|
|
2821
|
+
return this;
|
|
2822
|
+
}
|
|
2823
|
+
/**
|
|
2824
|
+
* @param {string | null} [value]
|
|
2825
|
+
*/
|
|
2826
|
+
set alt(value) {
|
|
2827
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2828
|
+
var len0 = WASM_VECTOR_LEN;
|
|
2829
|
+
wasm.wasmimagemetadata_set_alt(this.__wbg_ptr, ptr0, len0);
|
|
2830
|
+
}
|
|
2831
|
+
/**
|
|
2832
|
+
* @param {any} value
|
|
2833
|
+
*/
|
|
2834
|
+
set attributes(value) {
|
|
2835
|
+
wasm.wasmimagemetadata_set_attributes(this.__wbg_ptr, addHeapObject(value));
|
|
2836
|
+
}
|
|
2837
|
+
/**
|
|
2838
|
+
* @param {string | null} [value]
|
|
2839
|
+
*/
|
|
2840
|
+
set dimensions(value) {
|
|
2841
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2842
|
+
var len0 = WASM_VECTOR_LEN;
|
|
2843
|
+
wasm.wasmimagemetadata_set_dimensions(this.__wbg_ptr, ptr0, len0);
|
|
2844
|
+
}
|
|
2845
|
+
/**
|
|
2846
|
+
* @param {WasmImageType} value
|
|
2847
|
+
*/
|
|
2848
|
+
set imageType(value) {
|
|
2849
|
+
wasm.wasmimagemetadata_set_imageType(this.__wbg_ptr, value);
|
|
2850
|
+
}
|
|
2851
|
+
/**
|
|
2852
|
+
* @param {string} value
|
|
2853
|
+
*/
|
|
2854
|
+
set src(value) {
|
|
2855
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2856
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2857
|
+
wasm.wasmimagemetadata_set_src(this.__wbg_ptr, ptr0, len0);
|
|
2858
|
+
}
|
|
2859
|
+
/**
|
|
2860
|
+
* @param {string | null} [value]
|
|
2861
|
+
*/
|
|
2862
|
+
set title(value) {
|
|
2863
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2864
|
+
var len0 = WASM_VECTOR_LEN;
|
|
2865
|
+
wasm.wasmimagemetadata_set_title(this.__wbg_ptr, ptr0, len0);
|
|
2866
|
+
}
|
|
2867
|
+
/**
|
|
2868
|
+
* @returns {string}
|
|
2869
|
+
*/
|
|
2870
|
+
get src() {
|
|
2871
|
+
let deferred1_0;
|
|
2872
|
+
let deferred1_1;
|
|
2873
|
+
try {
|
|
2874
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2875
|
+
wasm.wasmimagemetadata_src(retptr, this.__wbg_ptr);
|
|
2876
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2877
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2878
|
+
deferred1_0 = r0;
|
|
2879
|
+
deferred1_1 = r1;
|
|
2880
|
+
return getStringFromWasm0(r0, r1);
|
|
2881
|
+
} finally {
|
|
2882
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2883
|
+
wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
|
|
2884
|
+
}
|
|
2885
|
+
}
|
|
2886
|
+
/**
|
|
2887
|
+
* @returns {string | undefined}
|
|
2888
|
+
*/
|
|
2889
|
+
get title() {
|
|
2890
|
+
try {
|
|
2891
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2892
|
+
wasm.wasmimagemetadata_title(retptr, this.__wbg_ptr);
|
|
2893
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2894
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2895
|
+
let v1;
|
|
2896
|
+
if (r0 !== 0) {
|
|
2897
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
2898
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
2899
|
+
}
|
|
2900
|
+
return v1;
|
|
2901
|
+
} finally {
|
|
2902
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2903
|
+
}
|
|
2904
|
+
}
|
|
2905
|
+
}
|
|
2906
|
+
if (Symbol.dispose) WasmImageMetadata.prototype[Symbol.dispose] = WasmImageMetadata.prototype.free;
|
|
2907
|
+
exports.WasmImageMetadata = WasmImageMetadata;
|
|
2908
|
+
|
|
2909
|
+
/**
|
|
2910
|
+
* @enum {0 | 1 | 2 | 3}
|
|
2911
|
+
*/
|
|
2912
|
+
const WasmImageType = Object.freeze({
|
|
2913
|
+
DataUri: 0, "0": "DataUri",
|
|
2914
|
+
InlineSvg: 1, "1": "InlineSvg",
|
|
2915
|
+
External: 2, "2": "External",
|
|
2916
|
+
Relative: 3, "3": "Relative",
|
|
2917
|
+
});
|
|
2918
|
+
exports.WasmImageType = WasmImageType;
|
|
2919
|
+
|
|
2920
|
+
class WasmLinkMetadata {
|
|
2921
|
+
static __wrap(ptr) {
|
|
2922
|
+
ptr = ptr >>> 0;
|
|
2923
|
+
const obj = Object.create(WasmLinkMetadata.prototype);
|
|
2924
|
+
obj.__wbg_ptr = ptr;
|
|
2925
|
+
WasmLinkMetadataFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2926
|
+
return obj;
|
|
2927
|
+
}
|
|
2928
|
+
static __unwrap(jsValue) {
|
|
2929
|
+
if (!(jsValue instanceof WasmLinkMetadata)) {
|
|
2930
|
+
return 0;
|
|
2931
|
+
}
|
|
2932
|
+
return jsValue.__destroy_into_raw();
|
|
2933
|
+
}
|
|
2934
|
+
__destroy_into_raw() {
|
|
2935
|
+
const ptr = this.__wbg_ptr;
|
|
2936
|
+
this.__wbg_ptr = 0;
|
|
2937
|
+
WasmLinkMetadataFinalization.unregister(this);
|
|
2938
|
+
return ptr;
|
|
2939
|
+
}
|
|
2940
|
+
free() {
|
|
2941
|
+
const ptr = this.__destroy_into_raw();
|
|
2942
|
+
wasm.__wbg_wasmlinkmetadata_free(ptr, 0);
|
|
2943
|
+
}
|
|
2944
|
+
/**
|
|
2945
|
+
* @returns {WasmConversionResult}
|
|
2946
|
+
*/
|
|
2947
|
+
get attributes() {
|
|
2948
|
+
const ret = wasm.wasmlinkmetadata_attributes(this.__wbg_ptr);
|
|
2949
|
+
return takeObject(ret);
|
|
2950
|
+
}
|
|
2951
|
+
/**
|
|
2952
|
+
* @param {string} href
|
|
2953
|
+
* @returns {WasmLinkType}
|
|
2954
|
+
*/
|
|
2955
|
+
static classifyLink(href) {
|
|
2956
|
+
const ptr0 = passStringToWasm0(href, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2957
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2958
|
+
const ret = wasm.wasmlinkmetadata_classifyLink(ptr0, len0);
|
|
2959
|
+
return ret;
|
|
2960
|
+
}
|
|
2961
|
+
/**
|
|
2962
|
+
* @returns {string}
|
|
2963
|
+
*/
|
|
2964
|
+
get href() {
|
|
2965
|
+
let deferred1_0;
|
|
2966
|
+
let deferred1_1;
|
|
2967
|
+
try {
|
|
2968
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2969
|
+
wasm.wasmlinkmetadata_href(retptr, this.__wbg_ptr);
|
|
2970
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2971
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
2972
|
+
deferred1_0 = r0;
|
|
2973
|
+
deferred1_1 = r1;
|
|
2974
|
+
return getStringFromWasm0(r0, r1);
|
|
2975
|
+
} finally {
|
|
2976
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2977
|
+
wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
|
|
2978
|
+
}
|
|
2979
|
+
}
|
|
2980
|
+
/**
|
|
2981
|
+
* @returns {WasmLinkType}
|
|
2982
|
+
*/
|
|
2983
|
+
get linkType() {
|
|
2984
|
+
const ret = wasm.wasmlinkmetadata_linkType(this.__wbg_ptr);
|
|
2985
|
+
return ret;
|
|
2986
|
+
}
|
|
2987
|
+
/**
|
|
2988
|
+
* @param {string} href
|
|
2989
|
+
* @param {string} text
|
|
2990
|
+
* @param {WasmLinkType} link_type
|
|
2991
|
+
* @param {string[]} rel
|
|
2992
|
+
* @param {any} attributes
|
|
2993
|
+
* @param {string | null} [title]
|
|
2994
|
+
*/
|
|
2995
|
+
constructor(href, text, link_type, rel, attributes, title) {
|
|
2996
|
+
const ptr0 = passStringToWasm0(href, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2997
|
+
const len0 = WASM_VECTOR_LEN;
|
|
2998
|
+
const ptr1 = passStringToWasm0(text, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
2999
|
+
const len1 = WASM_VECTOR_LEN;
|
|
3000
|
+
const ptr2 = passArrayJsValueToWasm0(rel, wasm.__wbindgen_export);
|
|
3001
|
+
const len2 = WASM_VECTOR_LEN;
|
|
3002
|
+
var ptr3 = isLikeNone(title) ? 0 : passStringToWasm0(title, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
3003
|
+
var len3 = WASM_VECTOR_LEN;
|
|
3004
|
+
const ret = wasm.wasmlinkmetadata_new(ptr0, len0, ptr1, len1, link_type, ptr2, len2, addHeapObject(attributes), ptr3, len3);
|
|
3005
|
+
this.__wbg_ptr = ret >>> 0;
|
|
3006
|
+
WasmLinkMetadataFinalization.register(this, this.__wbg_ptr, this);
|
|
3007
|
+
return this;
|
|
3008
|
+
}
|
|
3009
|
+
/**
|
|
3010
|
+
* @returns {string[]}
|
|
3011
|
+
*/
|
|
3012
|
+
get rel() {
|
|
3013
|
+
try {
|
|
3014
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
3015
|
+
wasm.wasmlinkmetadata_rel(retptr, this.__wbg_ptr);
|
|
3016
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
3017
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
3018
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
3019
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
3020
|
+
return v1;
|
|
3021
|
+
} finally {
|
|
3022
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
3023
|
+
}
|
|
3024
|
+
}
|
|
3025
|
+
/**
|
|
3026
|
+
* @param {any} value
|
|
3027
|
+
*/
|
|
3028
|
+
set attributes(value) {
|
|
3029
|
+
wasm.wasmlinkmetadata_set_attributes(this.__wbg_ptr, addHeapObject(value));
|
|
3030
|
+
}
|
|
3031
|
+
/**
|
|
3032
|
+
* @param {string} value
|
|
3033
|
+
*/
|
|
3034
|
+
set href(value) {
|
|
3035
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
3036
|
+
const len0 = WASM_VECTOR_LEN;
|
|
3037
|
+
wasm.wasmlinkmetadata_set_href(this.__wbg_ptr, ptr0, len0);
|
|
3038
|
+
}
|
|
3039
|
+
/**
|
|
3040
|
+
* @param {WasmLinkType} value
|
|
3041
|
+
*/
|
|
3042
|
+
set linkType(value) {
|
|
3043
|
+
wasm.wasmlinkmetadata_set_linkType(this.__wbg_ptr, value);
|
|
3044
|
+
}
|
|
3045
|
+
/**
|
|
3046
|
+
* @param {string[]} value
|
|
3047
|
+
*/
|
|
3048
|
+
set rel(value) {
|
|
3049
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
3050
|
+
const len0 = WASM_VECTOR_LEN;
|
|
3051
|
+
wasm.wasmlinkmetadata_set_rel(this.__wbg_ptr, ptr0, len0);
|
|
3052
|
+
}
|
|
3053
|
+
/**
|
|
3054
|
+
* @param {string} value
|
|
3055
|
+
*/
|
|
3056
|
+
set text(value) {
|
|
3057
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
3058
|
+
const len0 = WASM_VECTOR_LEN;
|
|
3059
|
+
wasm.wasmlinkmetadata_set_text(this.__wbg_ptr, ptr0, len0);
|
|
3060
|
+
}
|
|
3061
|
+
/**
|
|
3062
|
+
* @param {string | null} [value]
|
|
3063
|
+
*/
|
|
3064
|
+
set title(value) {
|
|
3065
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
3066
|
+
var len0 = WASM_VECTOR_LEN;
|
|
3067
|
+
wasm.wasmlinkmetadata_set_title(this.__wbg_ptr, ptr0, len0);
|
|
3068
|
+
}
|
|
3069
|
+
/**
|
|
3070
|
+
* @returns {string}
|
|
3071
|
+
*/
|
|
3072
|
+
get text() {
|
|
3073
|
+
let deferred1_0;
|
|
3074
|
+
let deferred1_1;
|
|
3075
|
+
try {
|
|
3076
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
3077
|
+
wasm.wasmlinkmetadata_text(retptr, this.__wbg_ptr);
|
|
3078
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
3079
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
3080
|
+
deferred1_0 = r0;
|
|
3081
|
+
deferred1_1 = r1;
|
|
3082
|
+
return getStringFromWasm0(r0, r1);
|
|
3083
|
+
} finally {
|
|
3084
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
3085
|
+
wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
|
|
3086
|
+
}
|
|
3087
|
+
}
|
|
3088
|
+
/**
|
|
3089
|
+
* @returns {string | undefined}
|
|
3090
|
+
*/
|
|
3091
|
+
get title() {
|
|
3092
|
+
try {
|
|
3093
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
3094
|
+
wasm.wasmlinkmetadata_title(retptr, this.__wbg_ptr);
|
|
3095
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
3096
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
3097
|
+
let v1;
|
|
3098
|
+
if (r0 !== 0) {
|
|
3099
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
3100
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
3101
|
+
}
|
|
3102
|
+
return v1;
|
|
3103
|
+
} finally {
|
|
3104
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
3105
|
+
}
|
|
3106
|
+
}
|
|
3107
|
+
}
|
|
3108
|
+
if (Symbol.dispose) WasmLinkMetadata.prototype[Symbol.dispose] = WasmLinkMetadata.prototype.free;
|
|
3109
|
+
exports.WasmLinkMetadata = WasmLinkMetadata;
|
|
3110
|
+
|
|
3111
|
+
/**
|
|
3112
|
+
* @enum {0 | 1}
|
|
3113
|
+
*/
|
|
3114
|
+
const WasmLinkStyle = Object.freeze({
|
|
3115
|
+
Inline: 0, "0": "Inline",
|
|
3116
|
+
Reference: 1, "1": "Reference",
|
|
3117
|
+
});
|
|
3118
|
+
exports.WasmLinkStyle = WasmLinkStyle;
|
|
3119
|
+
|
|
3120
|
+
/**
|
|
3121
|
+
* @enum {0 | 1 | 2 | 3 | 4 | 5}
|
|
3122
|
+
*/
|
|
3123
|
+
const WasmLinkType = Object.freeze({
|
|
3124
|
+
Anchor: 0, "0": "Anchor",
|
|
3125
|
+
Internal: 1, "1": "Internal",
|
|
3126
|
+
External: 2, "2": "External",
|
|
3127
|
+
Email: 3, "3": "Email",
|
|
3128
|
+
Phone: 4, "4": "Phone",
|
|
3129
|
+
Other: 5, "5": "Other",
|
|
3130
|
+
});
|
|
3131
|
+
exports.WasmLinkType = WasmLinkType;
|
|
3132
|
+
|
|
3133
|
+
/**
|
|
3134
|
+
* @enum {0 | 1}
|
|
3135
|
+
*/
|
|
3136
|
+
const WasmListIndentType = Object.freeze({
|
|
3137
|
+
Spaces: 0, "0": "Spaces",
|
|
3138
|
+
Tabs: 1, "1": "Tabs",
|
|
3139
|
+
});
|
|
3140
|
+
exports.WasmListIndentType = WasmListIndentType;
|
|
3141
|
+
|
|
3142
|
+
class WasmMetadataConfig {
|
|
3143
|
+
static __wrap(ptr) {
|
|
3144
|
+
ptr = ptr >>> 0;
|
|
3145
|
+
const obj = Object.create(WasmMetadataConfig.prototype);
|
|
3146
|
+
obj.__wbg_ptr = ptr;
|
|
3147
|
+
WasmMetadataConfigFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
3148
|
+
return obj;
|
|
3149
|
+
}
|
|
3150
|
+
__destroy_into_raw() {
|
|
3151
|
+
const ptr = this.__wbg_ptr;
|
|
3152
|
+
this.__wbg_ptr = 0;
|
|
3153
|
+
WasmMetadataConfigFinalization.unregister(this);
|
|
3154
|
+
return ptr;
|
|
3155
|
+
}
|
|
3156
|
+
free() {
|
|
3157
|
+
const ptr = this.__destroy_into_raw();
|
|
3158
|
+
wasm.__wbg_wasmmetadataconfig_free(ptr, 0);
|
|
3159
|
+
}
|
|
3160
|
+
/**
|
|
3161
|
+
* @returns {boolean}
|
|
3162
|
+
*/
|
|
3163
|
+
anyEnabled() {
|
|
3164
|
+
const ret = wasm.wasmmetadataconfig_anyEnabled(this.__wbg_ptr);
|
|
3165
|
+
return ret !== 0;
|
|
3166
|
+
}
|
|
3167
|
+
/**
|
|
3168
|
+
* @returns {WasmMetadataConfig}
|
|
3169
|
+
*/
|
|
3170
|
+
static default() {
|
|
3171
|
+
const ret = wasm.wasmmetadataconfig_default();
|
|
3172
|
+
return WasmMetadataConfig.__wrap(ret);
|
|
3173
|
+
}
|
|
3174
|
+
/**
|
|
3175
|
+
* @returns {boolean}
|
|
3176
|
+
*/
|
|
3177
|
+
get extractDocument() {
|
|
3178
|
+
const ret = wasm.wasmmetadataconfig_extractDocument(this.__wbg_ptr);
|
|
3179
|
+
return ret !== 0;
|
|
3180
|
+
}
|
|
3181
|
+
/**
|
|
3182
|
+
* @returns {boolean}
|
|
3183
|
+
*/
|
|
3184
|
+
get extractHeaders() {
|
|
3185
|
+
const ret = wasm.wasmmetadataconfig_extractHeaders(this.__wbg_ptr);
|
|
3186
|
+
return ret !== 0;
|
|
3187
|
+
}
|
|
3188
|
+
/**
|
|
3189
|
+
* @returns {boolean}
|
|
3190
|
+
*/
|
|
3191
|
+
get extractImages() {
|
|
3192
|
+
const ret = wasm.wasmmetadataconfig_extractImages(this.__wbg_ptr);
|
|
3193
|
+
return ret !== 0;
|
|
3194
|
+
}
|
|
3195
|
+
/**
|
|
3196
|
+
* @returns {boolean}
|
|
3197
|
+
*/
|
|
3198
|
+
get extractLinks() {
|
|
3199
|
+
const ret = wasm.wasmmetadataconfig_extractLinks(this.__wbg_ptr);
|
|
3200
|
+
return ret !== 0;
|
|
3201
|
+
}
|
|
3202
|
+
/**
|
|
3203
|
+
* @returns {boolean}
|
|
3204
|
+
*/
|
|
3205
|
+
get extractStructuredData() {
|
|
3206
|
+
const ret = wasm.wasmmetadataconfig_extractStructuredData(this.__wbg_ptr);
|
|
3207
|
+
return ret !== 0;
|
|
3208
|
+
}
|
|
3209
|
+
/**
|
|
3210
|
+
* @returns {number}
|
|
3211
|
+
*/
|
|
3212
|
+
get maxStructuredDataSize() {
|
|
3213
|
+
const ret = wasm.wasmmetadataconfig_maxStructuredDataSize(this.__wbg_ptr);
|
|
3214
|
+
return ret >>> 0;
|
|
3215
|
+
}
|
|
3216
|
+
/**
|
|
3217
|
+
* @param {boolean | null} [extract_document]
|
|
3218
|
+
* @param {boolean | null} [extract_headers]
|
|
3219
|
+
* @param {boolean | null} [extract_links]
|
|
3220
|
+
* @param {boolean | null} [extract_images]
|
|
3221
|
+
* @param {boolean | null} [extract_structured_data]
|
|
3222
|
+
* @param {number | null} [max_structured_data_size]
|
|
3223
|
+
*/
|
|
3224
|
+
constructor(extract_document, extract_headers, extract_links, extract_images, extract_structured_data, max_structured_data_size) {
|
|
3225
|
+
const ret = wasm.wasmmetadataconfig_new(isLikeNone(extract_document) ? 0xFFFFFF : extract_document ? 1 : 0, isLikeNone(extract_headers) ? 0xFFFFFF : extract_headers ? 1 : 0, isLikeNone(extract_links) ? 0xFFFFFF : extract_links ? 1 : 0, isLikeNone(extract_images) ? 0xFFFFFF : extract_images ? 1 : 0, isLikeNone(extract_structured_data) ? 0xFFFFFF : extract_structured_data ? 1 : 0, isLikeNone(max_structured_data_size) ? 0x100000001 : (max_structured_data_size) >>> 0);
|
|
3226
|
+
this.__wbg_ptr = ret >>> 0;
|
|
3227
|
+
WasmMetadataConfigFinalization.register(this, this.__wbg_ptr, this);
|
|
3228
|
+
return this;
|
|
3229
|
+
}
|
|
3230
|
+
/**
|
|
3231
|
+
* @param {boolean} value
|
|
3232
|
+
*/
|
|
3233
|
+
set extractDocument(value) {
|
|
3234
|
+
wasm.wasmmetadataconfig_set_extractDocument(this.__wbg_ptr, value);
|
|
3235
|
+
}
|
|
3236
|
+
/**
|
|
3237
|
+
* @param {boolean} value
|
|
3238
|
+
*/
|
|
3239
|
+
set extractHeaders(value) {
|
|
3240
|
+
wasm.wasmmetadataconfig_set_extractHeaders(this.__wbg_ptr, value);
|
|
3241
|
+
}
|
|
3242
|
+
/**
|
|
3243
|
+
* @param {boolean} value
|
|
3244
|
+
*/
|
|
3245
|
+
set extractImages(value) {
|
|
3246
|
+
wasm.wasmmetadataconfig_set_extractImages(this.__wbg_ptr, value);
|
|
3247
|
+
}
|
|
3248
|
+
/**
|
|
3249
|
+
* @param {boolean} value
|
|
3250
|
+
*/
|
|
3251
|
+
set extractLinks(value) {
|
|
3252
|
+
wasm.wasmmetadataconfig_set_extractLinks(this.__wbg_ptr, value);
|
|
3253
|
+
}
|
|
3254
|
+
/**
|
|
3255
|
+
* @param {boolean} value
|
|
3256
|
+
*/
|
|
3257
|
+
set extractStructuredData(value) {
|
|
3258
|
+
wasm.wasmmetadataconfig_set_extractStructuredData(this.__wbg_ptr, value);
|
|
3259
|
+
}
|
|
3260
|
+
/**
|
|
3261
|
+
* @param {number} value
|
|
3262
|
+
*/
|
|
3263
|
+
set maxStructuredDataSize(value) {
|
|
3264
|
+
wasm.wasmmetadataconfig_set_maxStructuredDataSize(this.__wbg_ptr, value);
|
|
3265
|
+
}
|
|
3266
|
+
}
|
|
3267
|
+
if (Symbol.dispose) WasmMetadataConfig.prototype[Symbol.dispose] = WasmMetadataConfig.prototype.free;
|
|
3268
|
+
exports.WasmMetadataConfig = WasmMetadataConfig;
|
|
3269
|
+
|
|
3270
|
+
class WasmMetadataConfigUpdate {
|
|
3271
|
+
__destroy_into_raw() {
|
|
3272
|
+
const ptr = this.__wbg_ptr;
|
|
3273
|
+
this.__wbg_ptr = 0;
|
|
3274
|
+
WasmMetadataConfigUpdateFinalization.unregister(this);
|
|
3275
|
+
return ptr;
|
|
3276
|
+
}
|
|
3277
|
+
free() {
|
|
3278
|
+
const ptr = this.__destroy_into_raw();
|
|
3279
|
+
wasm.__wbg_wasmmetadataconfigupdate_free(ptr, 0);
|
|
3280
|
+
}
|
|
3281
|
+
/**
|
|
3282
|
+
* @returns {boolean | undefined}
|
|
3283
|
+
*/
|
|
3284
|
+
get extractDocument() {
|
|
3285
|
+
const ret = wasm.wasmmetadataconfigupdate_extractDocument(this.__wbg_ptr);
|
|
3286
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3287
|
+
}
|
|
3288
|
+
/**
|
|
3289
|
+
* @returns {boolean | undefined}
|
|
3290
|
+
*/
|
|
3291
|
+
get extractHeaders() {
|
|
3292
|
+
const ret = wasm.wasmmetadataconfigupdate_extractHeaders(this.__wbg_ptr);
|
|
3293
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3294
|
+
}
|
|
3295
|
+
/**
|
|
3296
|
+
* @returns {boolean | undefined}
|
|
3297
|
+
*/
|
|
3298
|
+
get extractImages() {
|
|
3299
|
+
const ret = wasm.wasmmetadataconfigupdate_extractImages(this.__wbg_ptr);
|
|
3300
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3301
|
+
}
|
|
3302
|
+
/**
|
|
3303
|
+
* @returns {boolean | undefined}
|
|
3304
|
+
*/
|
|
3305
|
+
get extractLinks() {
|
|
3306
|
+
const ret = wasm.wasmmetadataconfigupdate_extractLinks(this.__wbg_ptr);
|
|
3307
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3308
|
+
}
|
|
3309
|
+
/**
|
|
3310
|
+
* @returns {boolean | undefined}
|
|
3311
|
+
*/
|
|
3312
|
+
get extractStructuredData() {
|
|
3313
|
+
const ret = wasm.wasmmetadataconfigupdate_extractStructuredData(this.__wbg_ptr);
|
|
3314
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3315
|
+
}
|
|
3316
|
+
/**
|
|
3317
|
+
* @returns {number | undefined}
|
|
3318
|
+
*/
|
|
3319
|
+
get maxStructuredDataSize() {
|
|
3320
|
+
const ret = wasm.wasmmetadataconfigupdate_maxStructuredDataSize(this.__wbg_ptr);
|
|
3321
|
+
return ret === 0x100000001 ? undefined : ret;
|
|
3322
|
+
}
|
|
3323
|
+
/**
|
|
3324
|
+
* @param {boolean | null} [extract_document]
|
|
3325
|
+
* @param {boolean | null} [extract_headers]
|
|
3326
|
+
* @param {boolean | null} [extract_links]
|
|
3327
|
+
* @param {boolean | null} [extract_images]
|
|
3328
|
+
* @param {boolean | null} [extract_structured_data]
|
|
3329
|
+
* @param {number | null} [max_structured_data_size]
|
|
3330
|
+
*/
|
|
3331
|
+
constructor(extract_document, extract_headers, extract_links, extract_images, extract_structured_data, max_structured_data_size) {
|
|
3332
|
+
const ret = wasm.wasmmetadataconfigupdate_new(isLikeNone(extract_document) ? 0xFFFFFF : extract_document ? 1 : 0, isLikeNone(extract_headers) ? 0xFFFFFF : extract_headers ? 1 : 0, isLikeNone(extract_links) ? 0xFFFFFF : extract_links ? 1 : 0, isLikeNone(extract_images) ? 0xFFFFFF : extract_images ? 1 : 0, isLikeNone(extract_structured_data) ? 0xFFFFFF : extract_structured_data ? 1 : 0, isLikeNone(max_structured_data_size) ? 0x100000001 : (max_structured_data_size) >>> 0);
|
|
3333
|
+
this.__wbg_ptr = ret >>> 0;
|
|
3334
|
+
WasmMetadataConfigUpdateFinalization.register(this, this.__wbg_ptr, this);
|
|
3335
|
+
return this;
|
|
3336
|
+
}
|
|
3337
|
+
/**
|
|
3338
|
+
* @param {boolean | null} [value]
|
|
3339
|
+
*/
|
|
3340
|
+
set extractDocument(value) {
|
|
3341
|
+
wasm.wasmmetadataconfigupdate_set_extractDocument(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
3342
|
+
}
|
|
3343
|
+
/**
|
|
3344
|
+
* @param {boolean | null} [value]
|
|
3345
|
+
*/
|
|
3346
|
+
set extractHeaders(value) {
|
|
3347
|
+
wasm.wasmmetadataconfigupdate_set_extractHeaders(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
3348
|
+
}
|
|
3349
|
+
/**
|
|
3350
|
+
* @param {boolean | null} [value]
|
|
3351
|
+
*/
|
|
3352
|
+
set extractImages(value) {
|
|
3353
|
+
wasm.wasmmetadataconfigupdate_set_extractImages(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
3354
|
+
}
|
|
3355
|
+
/**
|
|
3356
|
+
* @param {boolean | null} [value]
|
|
3357
|
+
*/
|
|
3358
|
+
set extractLinks(value) {
|
|
3359
|
+
wasm.wasmmetadataconfigupdate_set_extractLinks(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
3360
|
+
}
|
|
3361
|
+
/**
|
|
3362
|
+
* @param {boolean | null} [value]
|
|
3363
|
+
*/
|
|
3364
|
+
set extractStructuredData(value) {
|
|
3365
|
+
wasm.wasmmetadataconfigupdate_set_extractStructuredData(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
3366
|
+
}
|
|
3367
|
+
/**
|
|
3368
|
+
* @param {number | null} [value]
|
|
3369
|
+
*/
|
|
3370
|
+
set maxStructuredDataSize(value) {
|
|
3371
|
+
wasm.wasmmetadataconfigupdate_set_maxStructuredDataSize(this.__wbg_ptr, isLikeNone(value) ? 0x100000001 : (value) >>> 0);
|
|
3372
|
+
}
|
|
3373
|
+
}
|
|
3374
|
+
if (Symbol.dispose) WasmMetadataConfigUpdate.prototype[Symbol.dispose] = WasmMetadataConfigUpdate.prototype.free;
|
|
3375
|
+
exports.WasmMetadataConfigUpdate = WasmMetadataConfigUpdate;
|
|
3376
|
+
|
|
3377
|
+
/**
|
|
3378
|
+
* @enum {0 | 1}
|
|
3379
|
+
*/
|
|
3380
|
+
const WasmNewlineStyle = Object.freeze({
|
|
3381
|
+
Spaces: 0, "0": "Spaces",
|
|
3382
|
+
Backslash: 1, "1": "Backslash",
|
|
3383
|
+
});
|
|
3384
|
+
exports.WasmNewlineStyle = WasmNewlineStyle;
|
|
3385
|
+
|
|
3386
|
+
/**
|
|
3387
|
+
* @enum {0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12}
|
|
3388
|
+
*/
|
|
3389
|
+
const WasmNodeContent = Object.freeze({
|
|
3390
|
+
Heading: 0, "0": "Heading",
|
|
3391
|
+
Paragraph: 1, "1": "Paragraph",
|
|
3392
|
+
List: 2, "2": "List",
|
|
3393
|
+
ListItem: 3, "3": "ListItem",
|
|
3394
|
+
Table: 4, "4": "Table",
|
|
3395
|
+
Image: 5, "5": "Image",
|
|
3396
|
+
Code: 6, "6": "Code",
|
|
3397
|
+
Quote: 7, "7": "Quote",
|
|
3398
|
+
DefinitionList: 8, "8": "DefinitionList",
|
|
3399
|
+
DefinitionItem: 9, "9": "DefinitionItem",
|
|
3400
|
+
RawBlock: 10, "10": "RawBlock",
|
|
3401
|
+
MetadataBlock: 11, "11": "MetadataBlock",
|
|
3402
|
+
Group: 12, "12": "Group",
|
|
3403
|
+
});
|
|
3404
|
+
exports.WasmNodeContent = WasmNodeContent;
|
|
3405
|
+
|
|
3406
|
+
/**
|
|
3407
|
+
* @enum {0 | 1 | 2}
|
|
3408
|
+
*/
|
|
3409
|
+
const WasmOutputFormat = Object.freeze({
|
|
3410
|
+
Markdown: 0, "0": "Markdown",
|
|
3411
|
+
Djot: 1, "1": "Djot",
|
|
3412
|
+
Plain: 2, "2": "Plain",
|
|
3413
|
+
});
|
|
3414
|
+
exports.WasmOutputFormat = WasmOutputFormat;
|
|
3415
|
+
|
|
3416
|
+
class WasmPreprocessingOptions {
|
|
3417
|
+
static __wrap(ptr) {
|
|
3418
|
+
ptr = ptr >>> 0;
|
|
3419
|
+
const obj = Object.create(WasmPreprocessingOptions.prototype);
|
|
3420
|
+
obj.__wbg_ptr = ptr;
|
|
3421
|
+
WasmPreprocessingOptionsFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
3422
|
+
return obj;
|
|
3423
|
+
}
|
|
3424
|
+
__destroy_into_raw() {
|
|
3425
|
+
const ptr = this.__wbg_ptr;
|
|
3426
|
+
this.__wbg_ptr = 0;
|
|
3427
|
+
WasmPreprocessingOptionsFinalization.unregister(this);
|
|
3428
|
+
return ptr;
|
|
3429
|
+
}
|
|
3430
|
+
free() {
|
|
3431
|
+
const ptr = this.__destroy_into_raw();
|
|
3432
|
+
wasm.__wbg_wasmpreprocessingoptions_free(ptr, 0);
|
|
3433
|
+
}
|
|
3434
|
+
/**
|
|
3435
|
+
* @returns {WasmPreprocessingOptions}
|
|
3436
|
+
*/
|
|
3437
|
+
static default() {
|
|
3438
|
+
const ret = wasm.wasmpreprocessingoptions_default();
|
|
3439
|
+
return WasmPreprocessingOptions.__wrap(ret);
|
|
3440
|
+
}
|
|
3441
|
+
/**
|
|
3442
|
+
* @returns {boolean}
|
|
3443
|
+
*/
|
|
3444
|
+
get enabled() {
|
|
3445
|
+
const ret = wasm.wasmpreprocessingoptions_enabled(this.__wbg_ptr);
|
|
3446
|
+
return ret !== 0;
|
|
3447
|
+
}
|
|
3448
|
+
/**
|
|
3449
|
+
* @param {boolean | null} [enabled]
|
|
3450
|
+
* @param {WasmPreprocessingPreset | null} [preset]
|
|
3451
|
+
* @param {boolean | null} [remove_navigation]
|
|
3452
|
+
* @param {boolean | null} [remove_forms]
|
|
3453
|
+
*/
|
|
3454
|
+
constructor(enabled, preset, remove_navigation, remove_forms) {
|
|
3455
|
+
const ret = wasm.wasmpreprocessingoptions_new(isLikeNone(enabled) ? 0xFFFFFF : enabled ? 1 : 0, isLikeNone(preset) ? 3 : preset, isLikeNone(remove_navigation) ? 0xFFFFFF : remove_navigation ? 1 : 0, isLikeNone(remove_forms) ? 0xFFFFFF : remove_forms ? 1 : 0);
|
|
3456
|
+
this.__wbg_ptr = ret >>> 0;
|
|
3457
|
+
WasmPreprocessingOptionsFinalization.register(this, this.__wbg_ptr, this);
|
|
3458
|
+
return this;
|
|
3459
|
+
}
|
|
3460
|
+
/**
|
|
3461
|
+
* @returns {WasmPreprocessingPreset}
|
|
3462
|
+
*/
|
|
3463
|
+
get preset() {
|
|
3464
|
+
const ret = wasm.wasmpreprocessingoptions_preset(this.__wbg_ptr);
|
|
3465
|
+
return ret;
|
|
3466
|
+
}
|
|
3467
|
+
/**
|
|
3468
|
+
* @returns {boolean}
|
|
3469
|
+
*/
|
|
3470
|
+
get removeForms() {
|
|
3471
|
+
const ret = wasm.wasmpreprocessingoptions_removeForms(this.__wbg_ptr);
|
|
3472
|
+
return ret !== 0;
|
|
3473
|
+
}
|
|
3474
|
+
/**
|
|
3475
|
+
* @returns {boolean}
|
|
3476
|
+
*/
|
|
3477
|
+
get removeNavigation() {
|
|
3478
|
+
const ret = wasm.wasmpreprocessingoptions_removeNavigation(this.__wbg_ptr);
|
|
3479
|
+
return ret !== 0;
|
|
3480
|
+
}
|
|
3481
|
+
/**
|
|
3482
|
+
* @param {boolean} value
|
|
3483
|
+
*/
|
|
3484
|
+
set enabled(value) {
|
|
3485
|
+
wasm.wasmpreprocessingoptions_set_enabled(this.__wbg_ptr, value);
|
|
3486
|
+
}
|
|
3487
|
+
/**
|
|
3488
|
+
* @param {WasmPreprocessingPreset} value
|
|
3489
|
+
*/
|
|
3490
|
+
set preset(value) {
|
|
3491
|
+
wasm.wasmpreprocessingoptions_set_preset(this.__wbg_ptr, value);
|
|
3492
|
+
}
|
|
3493
|
+
/**
|
|
3494
|
+
* @param {boolean} value
|
|
3495
|
+
*/
|
|
3496
|
+
set removeForms(value) {
|
|
3497
|
+
wasm.wasmpreprocessingoptions_set_removeForms(this.__wbg_ptr, value);
|
|
3498
|
+
}
|
|
3499
|
+
/**
|
|
3500
|
+
* @param {boolean} value
|
|
3501
|
+
*/
|
|
3502
|
+
set removeNavigation(value) {
|
|
3503
|
+
wasm.wasmpreprocessingoptions_set_removeNavigation(this.__wbg_ptr, value);
|
|
3504
|
+
}
|
|
3505
|
+
}
|
|
3506
|
+
if (Symbol.dispose) WasmPreprocessingOptions.prototype[Symbol.dispose] = WasmPreprocessingOptions.prototype.free;
|
|
3507
|
+
exports.WasmPreprocessingOptions = WasmPreprocessingOptions;
|
|
3508
|
+
|
|
3509
|
+
class WasmPreprocessingOptionsUpdate {
|
|
3510
|
+
static __wrap(ptr) {
|
|
3511
|
+
ptr = ptr >>> 0;
|
|
3512
|
+
const obj = Object.create(WasmPreprocessingOptionsUpdate.prototype);
|
|
3513
|
+
obj.__wbg_ptr = ptr;
|
|
3514
|
+
WasmPreprocessingOptionsUpdateFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
3515
|
+
return obj;
|
|
3516
|
+
}
|
|
3517
|
+
__destroy_into_raw() {
|
|
3518
|
+
const ptr = this.__wbg_ptr;
|
|
3519
|
+
this.__wbg_ptr = 0;
|
|
3520
|
+
WasmPreprocessingOptionsUpdateFinalization.unregister(this);
|
|
3521
|
+
return ptr;
|
|
3522
|
+
}
|
|
3523
|
+
free() {
|
|
3524
|
+
const ptr = this.__destroy_into_raw();
|
|
3525
|
+
wasm.__wbg_wasmpreprocessingoptionsupdate_free(ptr, 0);
|
|
3526
|
+
}
|
|
3527
|
+
/**
|
|
3528
|
+
* @returns {boolean | undefined}
|
|
3529
|
+
*/
|
|
3530
|
+
get enabled() {
|
|
3531
|
+
const ret = wasm.wasmpreprocessingoptionsupdate_enabled(this.__wbg_ptr);
|
|
3532
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3533
|
+
}
|
|
3534
|
+
/**
|
|
3535
|
+
* @param {boolean | null} [enabled]
|
|
3536
|
+
* @param {WasmPreprocessingPreset | null} [preset]
|
|
3537
|
+
* @param {boolean | null} [remove_navigation]
|
|
3538
|
+
* @param {boolean | null} [remove_forms]
|
|
3539
|
+
*/
|
|
3540
|
+
constructor(enabled, preset, remove_navigation, remove_forms) {
|
|
3541
|
+
const ret = wasm.wasmpreprocessingoptionsupdate_new(isLikeNone(enabled) ? 0xFFFFFF : enabled ? 1 : 0, isLikeNone(preset) ? 3 : preset, isLikeNone(remove_navigation) ? 0xFFFFFF : remove_navigation ? 1 : 0, isLikeNone(remove_forms) ? 0xFFFFFF : remove_forms ? 1 : 0);
|
|
3542
|
+
this.__wbg_ptr = ret >>> 0;
|
|
3543
|
+
WasmPreprocessingOptionsUpdateFinalization.register(this, this.__wbg_ptr, this);
|
|
3544
|
+
return this;
|
|
3545
|
+
}
|
|
3546
|
+
/**
|
|
3547
|
+
* @returns {WasmPreprocessingPreset | undefined}
|
|
3548
|
+
*/
|
|
3549
|
+
get preset() {
|
|
3550
|
+
const ret = wasm.wasmpreprocessingoptionsupdate_preset(this.__wbg_ptr);
|
|
3551
|
+
return ret === 3 ? undefined : ret;
|
|
3552
|
+
}
|
|
3553
|
+
/**
|
|
3554
|
+
* @returns {boolean | undefined}
|
|
3555
|
+
*/
|
|
3556
|
+
get removeForms() {
|
|
3557
|
+
const ret = wasm.wasmpreprocessingoptionsupdate_removeForms(this.__wbg_ptr);
|
|
3558
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3559
|
+
}
|
|
3560
|
+
/**
|
|
3561
|
+
* @returns {boolean | undefined}
|
|
3562
|
+
*/
|
|
3563
|
+
get removeNavigation() {
|
|
3564
|
+
const ret = wasm.wasmpreprocessingoptionsupdate_removeNavigation(this.__wbg_ptr);
|
|
3565
|
+
return ret === 0xFFFFFF ? undefined : ret !== 0;
|
|
3566
|
+
}
|
|
3567
|
+
/**
|
|
3568
|
+
* @param {boolean | null} [value]
|
|
3569
|
+
*/
|
|
3570
|
+
set enabled(value) {
|
|
3571
|
+
wasm.wasmpreprocessingoptionsupdate_set_enabled(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
3572
|
+
}
|
|
3573
|
+
/**
|
|
3574
|
+
* @param {WasmPreprocessingPreset | null} [value]
|
|
3575
|
+
*/
|
|
3576
|
+
set preset(value) {
|
|
3577
|
+
wasm.wasmpreprocessingoptionsupdate_set_preset(this.__wbg_ptr, isLikeNone(value) ? 3 : value);
|
|
3578
|
+
}
|
|
3579
|
+
/**
|
|
3580
|
+
* @param {boolean | null} [value]
|
|
3581
|
+
*/
|
|
3582
|
+
set removeForms(value) {
|
|
3583
|
+
wasm.wasmpreprocessingoptionsupdate_set_removeForms(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
3584
|
+
}
|
|
3585
|
+
/**
|
|
3586
|
+
* @param {boolean | null} [value]
|
|
3587
|
+
*/
|
|
3588
|
+
set removeNavigation(value) {
|
|
3589
|
+
wasm.wasmpreprocessingoptionsupdate_set_removeNavigation(this.__wbg_ptr, isLikeNone(value) ? 0xFFFFFF : value ? 1 : 0);
|
|
3590
|
+
}
|
|
3591
|
+
}
|
|
3592
|
+
if (Symbol.dispose) WasmPreprocessingOptionsUpdate.prototype[Symbol.dispose] = WasmPreprocessingOptionsUpdate.prototype.free;
|
|
3593
|
+
exports.WasmPreprocessingOptionsUpdate = WasmPreprocessingOptionsUpdate;
|
|
3594
|
+
|
|
3595
|
+
/**
|
|
3596
|
+
* @enum {0 | 1 | 2}
|
|
3597
|
+
*/
|
|
3598
|
+
const WasmPreprocessingPreset = Object.freeze({
|
|
3599
|
+
Minimal: 0, "0": "Minimal",
|
|
3600
|
+
Standard: 1, "1": "Standard",
|
|
3601
|
+
Aggressive: 2, "2": "Aggressive",
|
|
3602
|
+
});
|
|
3603
|
+
exports.WasmPreprocessingPreset = WasmPreprocessingPreset;
|
|
3604
|
+
|
|
3605
|
+
class WasmProcessingWarning {
|
|
3606
|
+
static __wrap(ptr) {
|
|
3607
|
+
ptr = ptr >>> 0;
|
|
3608
|
+
const obj = Object.create(WasmProcessingWarning.prototype);
|
|
3609
|
+
obj.__wbg_ptr = ptr;
|
|
3610
|
+
WasmProcessingWarningFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
3611
|
+
return obj;
|
|
3612
|
+
}
|
|
3613
|
+
static __unwrap(jsValue) {
|
|
3614
|
+
if (!(jsValue instanceof WasmProcessingWarning)) {
|
|
3615
|
+
return 0;
|
|
3616
|
+
}
|
|
3617
|
+
return jsValue.__destroy_into_raw();
|
|
3618
|
+
}
|
|
3619
|
+
__destroy_into_raw() {
|
|
3620
|
+
const ptr = this.__wbg_ptr;
|
|
3621
|
+
this.__wbg_ptr = 0;
|
|
3622
|
+
WasmProcessingWarningFinalization.unregister(this);
|
|
3623
|
+
return ptr;
|
|
3624
|
+
}
|
|
3625
|
+
free() {
|
|
3626
|
+
const ptr = this.__destroy_into_raw();
|
|
3627
|
+
wasm.__wbg_wasmprocessingwarning_free(ptr, 0);
|
|
3628
|
+
}
|
|
3629
|
+
/**
|
|
3630
|
+
* @returns {WasmWarningKind}
|
|
3631
|
+
*/
|
|
3632
|
+
get kind() {
|
|
3633
|
+
const ret = wasm.wasmprocessingwarning_kind(this.__wbg_ptr);
|
|
3634
|
+
return ret;
|
|
3635
|
+
}
|
|
3636
|
+
/**
|
|
3637
|
+
* @returns {string}
|
|
3638
|
+
*/
|
|
3639
|
+
get message() {
|
|
3640
|
+
let deferred1_0;
|
|
3641
|
+
let deferred1_1;
|
|
3642
|
+
try {
|
|
3643
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
3644
|
+
wasm.wasmprocessingwarning_message(retptr, this.__wbg_ptr);
|
|
3645
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
3646
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
3647
|
+
deferred1_0 = r0;
|
|
3648
|
+
deferred1_1 = r1;
|
|
3649
|
+
return getStringFromWasm0(r0, r1);
|
|
3650
|
+
} finally {
|
|
3651
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
3652
|
+
wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
|
|
3653
|
+
}
|
|
3654
|
+
}
|
|
3655
|
+
/**
|
|
3656
|
+
* @param {string} message
|
|
3657
|
+
* @param {WasmWarningKind} kind
|
|
3658
|
+
*/
|
|
3659
|
+
constructor(message, kind) {
|
|
3660
|
+
const ptr0 = passStringToWasm0(message, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
3661
|
+
const len0 = WASM_VECTOR_LEN;
|
|
3662
|
+
const ret = wasm.wasmprocessingwarning_new(ptr0, len0, kind);
|
|
3663
|
+
this.__wbg_ptr = ret >>> 0;
|
|
3664
|
+
WasmProcessingWarningFinalization.register(this, this.__wbg_ptr, this);
|
|
3665
|
+
return this;
|
|
3666
|
+
}
|
|
3667
|
+
/**
|
|
3668
|
+
* @param {WasmWarningKind} value
|
|
3669
|
+
*/
|
|
3670
|
+
set kind(value) {
|
|
3671
|
+
wasm.wasmprocessingwarning_set_kind(this.__wbg_ptr, value);
|
|
3672
|
+
}
|
|
3673
|
+
/**
|
|
3674
|
+
* @param {string} value
|
|
3675
|
+
*/
|
|
3676
|
+
set message(value) {
|
|
3677
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
3678
|
+
const len0 = WASM_VECTOR_LEN;
|
|
3679
|
+
wasm.wasmprocessingwarning_set_message(this.__wbg_ptr, ptr0, len0);
|
|
3680
|
+
}
|
|
3681
|
+
}
|
|
3682
|
+
if (Symbol.dispose) WasmProcessingWarning.prototype[Symbol.dispose] = WasmProcessingWarning.prototype.free;
|
|
3683
|
+
exports.WasmProcessingWarning = WasmProcessingWarning;
|
|
3684
|
+
|
|
3685
|
+
class WasmStructuredData {
|
|
3686
|
+
static __wrap(ptr) {
|
|
3687
|
+
ptr = ptr >>> 0;
|
|
3688
|
+
const obj = Object.create(WasmStructuredData.prototype);
|
|
3689
|
+
obj.__wbg_ptr = ptr;
|
|
3690
|
+
WasmStructuredDataFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
3691
|
+
return obj;
|
|
3692
|
+
}
|
|
3693
|
+
static __unwrap(jsValue) {
|
|
3694
|
+
if (!(jsValue instanceof WasmStructuredData)) {
|
|
3695
|
+
return 0;
|
|
3696
|
+
}
|
|
3697
|
+
return jsValue.__destroy_into_raw();
|
|
3698
|
+
}
|
|
3699
|
+
__destroy_into_raw() {
|
|
3700
|
+
const ptr = this.__wbg_ptr;
|
|
3701
|
+
this.__wbg_ptr = 0;
|
|
3702
|
+
WasmStructuredDataFinalization.unregister(this);
|
|
3703
|
+
return ptr;
|
|
3704
|
+
}
|
|
3705
|
+
free() {
|
|
3706
|
+
const ptr = this.__destroy_into_raw();
|
|
3707
|
+
wasm.__wbg_wasmstructureddata_free(ptr, 0);
|
|
3708
|
+
}
|
|
3709
|
+
/**
|
|
3710
|
+
* @returns {WasmStructuredDataType}
|
|
3711
|
+
*/
|
|
3712
|
+
get dataType() {
|
|
3713
|
+
const ret = wasm.wasmstructureddata_dataType(this.__wbg_ptr);
|
|
3714
|
+
return ret;
|
|
3715
|
+
}
|
|
3716
|
+
/**
|
|
3717
|
+
* @param {WasmStructuredDataType} data_type
|
|
3718
|
+
* @param {string} raw_json
|
|
3719
|
+
* @param {string | null} [schema_type]
|
|
3720
|
+
*/
|
|
3721
|
+
constructor(data_type, raw_json, schema_type) {
|
|
3722
|
+
const ptr0 = passStringToWasm0(raw_json, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
3723
|
+
const len0 = WASM_VECTOR_LEN;
|
|
3724
|
+
var ptr1 = isLikeNone(schema_type) ? 0 : passStringToWasm0(schema_type, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
3725
|
+
var len1 = WASM_VECTOR_LEN;
|
|
3726
|
+
const ret = wasm.wasmstructureddata_new(data_type, ptr0, len0, ptr1, len1);
|
|
3727
|
+
this.__wbg_ptr = ret >>> 0;
|
|
3728
|
+
WasmStructuredDataFinalization.register(this, this.__wbg_ptr, this);
|
|
3729
|
+
return this;
|
|
3730
|
+
}
|
|
3731
|
+
/**
|
|
3732
|
+
* @returns {string}
|
|
3733
|
+
*/
|
|
3734
|
+
get rawJson() {
|
|
3735
|
+
let deferred1_0;
|
|
3736
|
+
let deferred1_1;
|
|
3737
|
+
try {
|
|
3738
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
3739
|
+
wasm.wasmstructureddata_rawJson(retptr, this.__wbg_ptr);
|
|
3740
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
3741
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
3742
|
+
deferred1_0 = r0;
|
|
3743
|
+
deferred1_1 = r1;
|
|
3744
|
+
return getStringFromWasm0(r0, r1);
|
|
3745
|
+
} finally {
|
|
3746
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
3747
|
+
wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
|
|
3748
|
+
}
|
|
3749
|
+
}
|
|
3750
|
+
/**
|
|
3751
|
+
* @returns {string | undefined}
|
|
3752
|
+
*/
|
|
3753
|
+
get schemaType() {
|
|
3754
|
+
try {
|
|
3755
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
3756
|
+
wasm.wasmstructureddata_schemaType(retptr, this.__wbg_ptr);
|
|
3757
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
3758
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
3759
|
+
let v1;
|
|
3760
|
+
if (r0 !== 0) {
|
|
3761
|
+
v1 = getStringFromWasm0(r0, r1).slice();
|
|
3762
|
+
wasm.__wbindgen_export3(r0, r1 * 1, 1);
|
|
3763
|
+
}
|
|
3764
|
+
return v1;
|
|
3765
|
+
} finally {
|
|
3766
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
3767
|
+
}
|
|
3768
|
+
}
|
|
3769
|
+
/**
|
|
3770
|
+
* @param {WasmStructuredDataType} value
|
|
3771
|
+
*/
|
|
3772
|
+
set dataType(value) {
|
|
3773
|
+
wasm.wasmstructureddata_set_dataType(this.__wbg_ptr, value);
|
|
3774
|
+
}
|
|
3775
|
+
/**
|
|
3776
|
+
* @param {string} value
|
|
3777
|
+
*/
|
|
3778
|
+
set rawJson(value) {
|
|
3779
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
3780
|
+
const len0 = WASM_VECTOR_LEN;
|
|
3781
|
+
wasm.wasmstructureddata_set_rawJson(this.__wbg_ptr, ptr0, len0);
|
|
3782
|
+
}
|
|
3783
|
+
/**
|
|
3784
|
+
* @param {string | null} [value]
|
|
3785
|
+
*/
|
|
3786
|
+
set schemaType(value) {
|
|
3787
|
+
var ptr0 = isLikeNone(value) ? 0 : passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
3788
|
+
var len0 = WASM_VECTOR_LEN;
|
|
3789
|
+
wasm.wasmstructureddata_set_schemaType(this.__wbg_ptr, ptr0, len0);
|
|
3790
|
+
}
|
|
3791
|
+
}
|
|
3792
|
+
if (Symbol.dispose) WasmStructuredData.prototype[Symbol.dispose] = WasmStructuredData.prototype.free;
|
|
3793
|
+
exports.WasmStructuredData = WasmStructuredData;
|
|
3794
|
+
|
|
3795
|
+
/**
|
|
3796
|
+
* @enum {0 | 1 | 2}
|
|
3797
|
+
*/
|
|
3798
|
+
const WasmStructuredDataType = Object.freeze({
|
|
3799
|
+
JsonLd: 0, "0": "JsonLd",
|
|
3800
|
+
Microdata: 1, "1": "Microdata",
|
|
3801
|
+
RDFa: 2, "2": "RDFa",
|
|
3802
|
+
});
|
|
3803
|
+
exports.WasmStructuredDataType = WasmStructuredDataType;
|
|
3804
|
+
|
|
3805
|
+
class WasmTableData {
|
|
3806
|
+
static __wrap(ptr) {
|
|
3807
|
+
ptr = ptr >>> 0;
|
|
3808
|
+
const obj = Object.create(WasmTableData.prototype);
|
|
3809
|
+
obj.__wbg_ptr = ptr;
|
|
3810
|
+
WasmTableDataFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
3811
|
+
return obj;
|
|
3812
|
+
}
|
|
3813
|
+
static __unwrap(jsValue) {
|
|
3814
|
+
if (!(jsValue instanceof WasmTableData)) {
|
|
3815
|
+
return 0;
|
|
3816
|
+
}
|
|
3817
|
+
return jsValue.__destroy_into_raw();
|
|
3818
|
+
}
|
|
3819
|
+
__destroy_into_raw() {
|
|
3820
|
+
const ptr = this.__wbg_ptr;
|
|
3821
|
+
this.__wbg_ptr = 0;
|
|
3822
|
+
WasmTableDataFinalization.unregister(this);
|
|
3823
|
+
return ptr;
|
|
3824
|
+
}
|
|
3825
|
+
free() {
|
|
3826
|
+
const ptr = this.__destroy_into_raw();
|
|
3827
|
+
wasm.__wbg_wasmtabledata_free(ptr, 0);
|
|
3828
|
+
}
|
|
3829
|
+
/**
|
|
3830
|
+
* @returns {WasmTableGrid}
|
|
3831
|
+
*/
|
|
3832
|
+
get grid() {
|
|
3833
|
+
const ret = wasm.wasmtabledata_grid(this.__wbg_ptr);
|
|
3834
|
+
return WasmTableGrid.__wrap(ret);
|
|
3835
|
+
}
|
|
3836
|
+
/**
|
|
3837
|
+
* @returns {string}
|
|
3838
|
+
*/
|
|
3839
|
+
get markdown() {
|
|
3840
|
+
let deferred1_0;
|
|
3841
|
+
let deferred1_1;
|
|
3842
|
+
try {
|
|
3843
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
3844
|
+
wasm.wasmtabledata_markdown(retptr, this.__wbg_ptr);
|
|
3845
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
3846
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
3847
|
+
deferred1_0 = r0;
|
|
3848
|
+
deferred1_1 = r1;
|
|
3849
|
+
return getStringFromWasm0(r0, r1);
|
|
3850
|
+
} finally {
|
|
3851
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
3852
|
+
wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
|
|
3853
|
+
}
|
|
3854
|
+
}
|
|
3855
|
+
/**
|
|
3856
|
+
* @param {WasmTableGrid} grid
|
|
3857
|
+
* @param {string} markdown
|
|
3858
|
+
*/
|
|
3859
|
+
constructor(grid, markdown) {
|
|
3860
|
+
_assertClass(grid, WasmTableGrid);
|
|
3861
|
+
var ptr0 = grid.__destroy_into_raw();
|
|
3862
|
+
const ptr1 = passStringToWasm0(markdown, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
3863
|
+
const len1 = WASM_VECTOR_LEN;
|
|
3864
|
+
const ret = wasm.wasmtabledata_new(ptr0, ptr1, len1);
|
|
3865
|
+
this.__wbg_ptr = ret >>> 0;
|
|
3866
|
+
WasmTableDataFinalization.register(this, this.__wbg_ptr, this);
|
|
3867
|
+
return this;
|
|
3868
|
+
}
|
|
3869
|
+
/**
|
|
3870
|
+
* @param {WasmTableGrid} value
|
|
3871
|
+
*/
|
|
3872
|
+
set grid(value) {
|
|
3873
|
+
_assertClass(value, WasmTableGrid);
|
|
3874
|
+
var ptr0 = value.__destroy_into_raw();
|
|
3875
|
+
wasm.wasmtabledata_set_grid(this.__wbg_ptr, ptr0);
|
|
3876
|
+
}
|
|
3877
|
+
/**
|
|
3878
|
+
* @param {string} value
|
|
3879
|
+
*/
|
|
3880
|
+
set markdown(value) {
|
|
3881
|
+
const ptr0 = passStringToWasm0(value, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
3882
|
+
const len0 = WASM_VECTOR_LEN;
|
|
3883
|
+
wasm.wasmtabledata_set_markdown(this.__wbg_ptr, ptr0, len0);
|
|
3884
|
+
}
|
|
3885
|
+
}
|
|
3886
|
+
if (Symbol.dispose) WasmTableData.prototype[Symbol.dispose] = WasmTableData.prototype.free;
|
|
3887
|
+
exports.WasmTableData = WasmTableData;
|
|
3888
|
+
|
|
3889
|
+
class WasmTableGrid {
|
|
3890
|
+
static __wrap(ptr) {
|
|
3891
|
+
ptr = ptr >>> 0;
|
|
3892
|
+
const obj = Object.create(WasmTableGrid.prototype);
|
|
3893
|
+
obj.__wbg_ptr = ptr;
|
|
3894
|
+
WasmTableGridFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
3895
|
+
return obj;
|
|
3896
|
+
}
|
|
3897
|
+
__destroy_into_raw() {
|
|
3898
|
+
const ptr = this.__wbg_ptr;
|
|
3899
|
+
this.__wbg_ptr = 0;
|
|
3900
|
+
WasmTableGridFinalization.unregister(this);
|
|
3901
|
+
return ptr;
|
|
3902
|
+
}
|
|
3903
|
+
free() {
|
|
3904
|
+
const ptr = this.__destroy_into_raw();
|
|
3905
|
+
wasm.__wbg_wasmtablegrid_free(ptr, 0);
|
|
3906
|
+
}
|
|
3907
|
+
/**
|
|
3908
|
+
* @returns {WasmGridCell[]}
|
|
3909
|
+
*/
|
|
3910
|
+
get cells() {
|
|
3911
|
+
try {
|
|
3912
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
3913
|
+
wasm.wasmtablegrid_cells(retptr, this.__wbg_ptr);
|
|
3914
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
3915
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
3916
|
+
var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
|
|
3917
|
+
wasm.__wbindgen_export3(r0, r1 * 4, 4);
|
|
3918
|
+
return v1;
|
|
3919
|
+
} finally {
|
|
3920
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
3921
|
+
}
|
|
3922
|
+
}
|
|
3923
|
+
/**
|
|
3924
|
+
* @returns {number}
|
|
3925
|
+
*/
|
|
3926
|
+
get cols() {
|
|
3927
|
+
const ret = wasm.wasmtablegrid_cols(this.__wbg_ptr);
|
|
3928
|
+
return ret >>> 0;
|
|
3929
|
+
}
|
|
3930
|
+
/**
|
|
3931
|
+
* @param {number | null} [rows]
|
|
3932
|
+
* @param {number | null} [cols]
|
|
3933
|
+
* @param {WasmGridCell[] | null} [cells]
|
|
3934
|
+
*/
|
|
3935
|
+
constructor(rows, cols, cells) {
|
|
3936
|
+
var ptr0 = isLikeNone(cells) ? 0 : passArrayJsValueToWasm0(cells, wasm.__wbindgen_export);
|
|
3937
|
+
var len0 = WASM_VECTOR_LEN;
|
|
3938
|
+
const ret = wasm.wasmtablegrid_new(isLikeNone(rows) ? 0x100000001 : (rows) >>> 0, isLikeNone(cols) ? 0x100000001 : (cols) >>> 0, ptr0, len0);
|
|
3939
|
+
this.__wbg_ptr = ret >>> 0;
|
|
3940
|
+
WasmTableGridFinalization.register(this, this.__wbg_ptr, this);
|
|
3941
|
+
return this;
|
|
3942
|
+
}
|
|
3943
|
+
/**
|
|
3944
|
+
* @returns {number}
|
|
3945
|
+
*/
|
|
3946
|
+
get rows() {
|
|
3947
|
+
const ret = wasm.wasmtablegrid_rows(this.__wbg_ptr);
|
|
3948
|
+
return ret >>> 0;
|
|
3949
|
+
}
|
|
3950
|
+
/**
|
|
3951
|
+
* @param {WasmGridCell[]} value
|
|
3952
|
+
*/
|
|
3953
|
+
set cells(value) {
|
|
3954
|
+
const ptr0 = passArrayJsValueToWasm0(value, wasm.__wbindgen_export);
|
|
3955
|
+
const len0 = WASM_VECTOR_LEN;
|
|
3956
|
+
wasm.wasmtablegrid_set_cells(this.__wbg_ptr, ptr0, len0);
|
|
3957
|
+
}
|
|
3958
|
+
/**
|
|
3959
|
+
* @param {number} value
|
|
3960
|
+
*/
|
|
3961
|
+
set cols(value) {
|
|
3962
|
+
wasm.wasmtablegrid_set_cols(this.__wbg_ptr, value);
|
|
3963
|
+
}
|
|
3964
|
+
/**
|
|
3965
|
+
* @param {number} value
|
|
3966
|
+
*/
|
|
3967
|
+
set rows(value) {
|
|
3968
|
+
wasm.wasmtablegrid_set_rows(this.__wbg_ptr, value);
|
|
3969
|
+
}
|
|
3970
|
+
}
|
|
3971
|
+
if (Symbol.dispose) WasmTableGrid.prototype[Symbol.dispose] = WasmTableGrid.prototype.free;
|
|
3972
|
+
exports.WasmTableGrid = WasmTableGrid;
|
|
3973
|
+
|
|
3974
|
+
class WasmTextAnnotation {
|
|
3975
|
+
static __wrap(ptr) {
|
|
3976
|
+
ptr = ptr >>> 0;
|
|
3977
|
+
const obj = Object.create(WasmTextAnnotation.prototype);
|
|
3978
|
+
obj.__wbg_ptr = ptr;
|
|
3979
|
+
WasmTextAnnotationFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
3980
|
+
return obj;
|
|
3981
|
+
}
|
|
3982
|
+
static __unwrap(jsValue) {
|
|
3983
|
+
if (!(jsValue instanceof WasmTextAnnotation)) {
|
|
3984
|
+
return 0;
|
|
3985
|
+
}
|
|
3986
|
+
return jsValue.__destroy_into_raw();
|
|
3987
|
+
}
|
|
3988
|
+
__destroy_into_raw() {
|
|
3989
|
+
const ptr = this.__wbg_ptr;
|
|
3990
|
+
this.__wbg_ptr = 0;
|
|
3991
|
+
WasmTextAnnotationFinalization.unregister(this);
|
|
3992
|
+
return ptr;
|
|
3993
|
+
}
|
|
3994
|
+
free() {
|
|
3995
|
+
const ptr = this.__destroy_into_raw();
|
|
3996
|
+
wasm.__wbg_wasmtextannotation_free(ptr, 0);
|
|
3997
|
+
}
|
|
3998
|
+
/**
|
|
3999
|
+
* @returns {number}
|
|
4000
|
+
*/
|
|
4001
|
+
get end() {
|
|
4002
|
+
const ret = wasm.wasmtextannotation_end(this.__wbg_ptr);
|
|
4003
|
+
return ret >>> 0;
|
|
4004
|
+
}
|
|
4005
|
+
/**
|
|
4006
|
+
* @returns {WasmAnnotationKind}
|
|
4007
|
+
*/
|
|
4008
|
+
get kind() {
|
|
4009
|
+
const ret = wasm.wasmtextannotation_kind(this.__wbg_ptr);
|
|
4010
|
+
return ret;
|
|
4011
|
+
}
|
|
4012
|
+
/**
|
|
4013
|
+
* @param {number} start
|
|
4014
|
+
* @param {number} end
|
|
4015
|
+
* @param {WasmAnnotationKind} kind
|
|
4016
|
+
*/
|
|
4017
|
+
constructor(start, end, kind) {
|
|
4018
|
+
const ret = wasm.wasmtextannotation_new(start, end, kind);
|
|
4019
|
+
this.__wbg_ptr = ret >>> 0;
|
|
4020
|
+
WasmTextAnnotationFinalization.register(this, this.__wbg_ptr, this);
|
|
4021
|
+
return this;
|
|
4022
|
+
}
|
|
4023
|
+
/**
|
|
4024
|
+
* @param {number} value
|
|
4025
|
+
*/
|
|
4026
|
+
set end(value) {
|
|
4027
|
+
wasm.wasmtextannotation_set_end(this.__wbg_ptr, value);
|
|
4028
|
+
}
|
|
4029
|
+
/**
|
|
4030
|
+
* @param {WasmAnnotationKind} value
|
|
4031
|
+
*/
|
|
4032
|
+
set kind(value) {
|
|
4033
|
+
wasm.wasmtextannotation_set_kind(this.__wbg_ptr, value);
|
|
4034
|
+
}
|
|
4035
|
+
/**
|
|
4036
|
+
* @param {number} value
|
|
4037
|
+
*/
|
|
4038
|
+
set start(value) {
|
|
4039
|
+
wasm.wasmtextannotation_set_start(this.__wbg_ptr, value);
|
|
4040
|
+
}
|
|
4041
|
+
/**
|
|
4042
|
+
* @returns {number}
|
|
4043
|
+
*/
|
|
4044
|
+
get start() {
|
|
4045
|
+
const ret = wasm.wasmtextannotation_start(this.__wbg_ptr);
|
|
4046
|
+
return ret >>> 0;
|
|
4047
|
+
}
|
|
4048
|
+
}
|
|
4049
|
+
if (Symbol.dispose) WasmTextAnnotation.prototype[Symbol.dispose] = WasmTextAnnotation.prototype.free;
|
|
4050
|
+
exports.WasmTextAnnotation = WasmTextAnnotation;
|
|
4051
|
+
|
|
4052
|
+
/**
|
|
4053
|
+
* @enum {0 | 1 | 2}
|
|
4054
|
+
*/
|
|
4055
|
+
const WasmTextDirection = Object.freeze({
|
|
4056
|
+
LeftToRight: 0, "0": "LeftToRight",
|
|
4057
|
+
RightToLeft: 1, "1": "RightToLeft",
|
|
4058
|
+
Auto: 2, "2": "Auto",
|
|
4059
|
+
});
|
|
4060
|
+
exports.WasmTextDirection = WasmTextDirection;
|
|
4061
|
+
|
|
4062
|
+
/**
|
|
4063
|
+
* @enum {0 | 1 | 2 | 3 | 4}
|
|
4064
|
+
*/
|
|
4065
|
+
const WasmWarningKind = Object.freeze({
|
|
4066
|
+
ImageExtractionFailed: 0, "0": "ImageExtractionFailed",
|
|
4067
|
+
EncodingFallback: 1, "1": "EncodingFallback",
|
|
4068
|
+
TruncatedInput: 2, "2": "TruncatedInput",
|
|
4069
|
+
MalformedHtml: 3, "3": "MalformedHtml",
|
|
4070
|
+
SanitizationApplied: 4, "4": "SanitizationApplied",
|
|
4071
|
+
});
|
|
4072
|
+
exports.WasmWarningKind = WasmWarningKind;
|
|
4073
|
+
|
|
4074
|
+
/**
|
|
4075
|
+
* @enum {0 | 1}
|
|
4076
|
+
*/
|
|
4077
|
+
const WasmWhitespaceMode = Object.freeze({
|
|
4078
|
+
Normalized: 0, "0": "Normalized",
|
|
4079
|
+
Strict: 1, "1": "Strict",
|
|
4080
|
+
});
|
|
4081
|
+
exports.WasmWhitespaceMode = WasmWhitespaceMode;
|
|
4082
|
+
|
|
4083
|
+
/**
|
|
34
4084
|
* @param {string} html
|
|
35
|
-
* @param {WasmConversionOptions | null
|
|
4085
|
+
* @param {WasmConversionOptions | null} [options]
|
|
36
4086
|
* @returns {WasmConversionResult}
|
|
37
4087
|
*/
|
|
38
4088
|
function convert(html, options) {
|
|
@@ -40,108 +4090,40 @@ function convert(html, options) {
|
|
|
40
4090
|
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
41
4091
|
const ptr0 = passStringToWasm0(html, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
42
4092
|
const len0 = WASM_VECTOR_LEN;
|
|
43
|
-
|
|
4093
|
+
let ptr1 = 0;
|
|
4094
|
+
if (!isLikeNone(options)) {
|
|
4095
|
+
_assertClass(options, WasmConversionOptions);
|
|
4096
|
+
ptr1 = options.__destroy_into_raw();
|
|
4097
|
+
}
|
|
4098
|
+
wasm.convert(retptr, ptr0, len0, ptr1);
|
|
44
4099
|
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
45
4100
|
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
46
4101
|
var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
|
|
47
4102
|
if (r2) {
|
|
48
4103
|
throw takeObject(r1);
|
|
49
4104
|
}
|
|
50
|
-
return
|
|
4105
|
+
return WasmConversionResult.__wrap(r0);
|
|
51
4106
|
} finally {
|
|
52
4107
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
53
4108
|
}
|
|
54
4109
|
}
|
|
55
4110
|
exports.convert = convert;
|
|
56
|
-
|
|
57
|
-
/**
|
|
58
|
-
* Initialize panic hook for better error messages in the browser
|
|
59
|
-
*/
|
|
60
|
-
function init() {
|
|
61
|
-
wasm.init();
|
|
62
|
-
}
|
|
63
|
-
exports.init = init;
|
|
64
|
-
|
|
65
4111
|
function __wbg_get_imports() {
|
|
66
4112
|
const import0 = {
|
|
67
4113
|
__proto__: null,
|
|
68
|
-
|
|
4114
|
+
__wbg_Error_960c155d3d49e4c2: function(arg0, arg1) {
|
|
69
4115
|
const ret = Error(getStringFromWasm0(arg0, arg1));
|
|
70
4116
|
return addHeapObject(ret);
|
|
71
4117
|
},
|
|
72
|
-
|
|
73
|
-
const ret = Number(getObject(arg0));
|
|
74
|
-
return ret;
|
|
75
|
-
},
|
|
76
|
-
__wbg_String_8564e559799eccda: function(arg0, arg1) {
|
|
77
|
-
const ret = String(getObject(arg1));
|
|
78
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
79
|
-
const len1 = WASM_VECTOR_LEN;
|
|
80
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
81
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
82
|
-
},
|
|
83
|
-
__wbg___wbindgen_bigint_get_as_i64_2c5082002e4826e2: function(arg0, arg1) {
|
|
84
|
-
const v = getObject(arg1);
|
|
85
|
-
const ret = typeof(v) === 'bigint' ? v : undefined;
|
|
86
|
-
getDataViewMemory0().setBigInt64(arg0 + 8 * 1, isLikeNone(ret) ? BigInt(0) : ret, true);
|
|
87
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
|
|
88
|
-
},
|
|
89
|
-
__wbg___wbindgen_boolean_get_a86c216575a75c30: function(arg0) {
|
|
90
|
-
const v = getObject(arg0);
|
|
91
|
-
const ret = typeof(v) === 'boolean' ? v : undefined;
|
|
92
|
-
return isLikeNone(ret) ? 0xFFFFFF : ret ? 1 : 0;
|
|
93
|
-
},
|
|
94
|
-
__wbg___wbindgen_debug_string_dd5d2d07ce9e6c57: function(arg0, arg1) {
|
|
95
|
-
const ret = debugString(getObject(arg1));
|
|
96
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
97
|
-
const len1 = WASM_VECTOR_LEN;
|
|
98
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
99
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
100
|
-
},
|
|
101
|
-
__wbg___wbindgen_in_4bd7a57e54337366: function(arg0, arg1) {
|
|
102
|
-
const ret = getObject(arg0) in getObject(arg1);
|
|
103
|
-
return ret;
|
|
104
|
-
},
|
|
105
|
-
__wbg___wbindgen_is_bigint_6c98f7e945dacdde: function(arg0) {
|
|
106
|
-
const ret = typeof(getObject(arg0)) === 'bigint';
|
|
107
|
-
return ret;
|
|
108
|
-
},
|
|
109
|
-
__wbg___wbindgen_is_function_49868bde5eb1e745: function(arg0) {
|
|
110
|
-
const ret = typeof(getObject(arg0)) === 'function';
|
|
111
|
-
return ret;
|
|
112
|
-
},
|
|
113
|
-
__wbg___wbindgen_is_null_344c8750a8525473: function(arg0) {
|
|
114
|
-
const ret = getObject(arg0) === null;
|
|
115
|
-
return ret;
|
|
116
|
-
},
|
|
117
|
-
__wbg___wbindgen_is_object_40c5a80572e8f9d3: function(arg0) {
|
|
118
|
-
const val = getObject(arg0);
|
|
119
|
-
const ret = typeof(val) === 'object' && val !== null;
|
|
120
|
-
return ret;
|
|
121
|
-
},
|
|
122
|
-
__wbg___wbindgen_is_string_b29b5c5a8065ba1a: function(arg0) {
|
|
4118
|
+
__wbg___wbindgen_is_string_6df3bf7ef1164ed3: function(arg0) {
|
|
123
4119
|
const ret = typeof(getObject(arg0)) === 'string';
|
|
124
4120
|
return ret;
|
|
125
4121
|
},
|
|
126
|
-
|
|
4122
|
+
__wbg___wbindgen_is_undefined_29a43b4d42920abd: function(arg0) {
|
|
127
4123
|
const ret = getObject(arg0) === undefined;
|
|
128
4124
|
return ret;
|
|
129
4125
|
},
|
|
130
|
-
|
|
131
|
-
const ret = getObject(arg0) === getObject(arg1);
|
|
132
|
-
return ret;
|
|
133
|
-
},
|
|
134
|
-
__wbg___wbindgen_jsval_loose_eq_3a72ae764d46d944: function(arg0, arg1) {
|
|
135
|
-
const ret = getObject(arg0) == getObject(arg1);
|
|
136
|
-
return ret;
|
|
137
|
-
},
|
|
138
|
-
__wbg___wbindgen_number_get_7579aab02a8a620c: function(arg0, arg1) {
|
|
139
|
-
const obj = getObject(arg1);
|
|
140
|
-
const ret = typeof(obj) === 'number' ? obj : undefined;
|
|
141
|
-
getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
|
|
142
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
|
|
143
|
-
},
|
|
144
|
-
__wbg___wbindgen_string_get_914df97fcfa788f2: function(arg0, arg1) {
|
|
4126
|
+
__wbg___wbindgen_string_get_7ed5322991caaec5: function(arg0, arg1) {
|
|
145
4127
|
const obj = getObject(arg1);
|
|
146
4128
|
const ret = typeof(obj) === 'string' ? obj : undefined;
|
|
147
4129
|
var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
@@ -149,181 +4131,101 @@ function __wbg_get_imports() {
|
|
|
149
4131
|
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
150
4132
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
151
4133
|
},
|
|
152
|
-
|
|
4134
|
+
__wbg___wbindgen_throw_6b64449b9b9ed33c: function(arg0, arg1) {
|
|
153
4135
|
throw new Error(getStringFromWasm0(arg0, arg1));
|
|
154
4136
|
},
|
|
155
|
-
|
|
156
|
-
const ret =
|
|
157
|
-
return addHeapObject(ret);
|
|
158
|
-
}, arguments); },
|
|
159
|
-
__wbg_codePointAt_944099a761b59b26: function(arg0, arg1) {
|
|
160
|
-
const ret = getObject(arg0).codePointAt(arg1 >>> 0);
|
|
4137
|
+
__wbg_new_34d45cc8e36aaead: function() {
|
|
4138
|
+
const ret = new Map();
|
|
161
4139
|
return addHeapObject(ret);
|
|
162
4140
|
},
|
|
163
|
-
|
|
164
|
-
const ret =
|
|
165
|
-
return ret;
|
|
4141
|
+
__wbg_new_aa8d0fa9762c29bd: function() {
|
|
4142
|
+
const ret = new Object();
|
|
4143
|
+
return addHeapObject(ret);
|
|
166
4144
|
},
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
let deferred0_1;
|
|
170
|
-
try {
|
|
171
|
-
deferred0_0 = arg0;
|
|
172
|
-
deferred0_1 = arg1;
|
|
173
|
-
console.error(getStringFromWasm0(arg0, arg1));
|
|
174
|
-
} finally {
|
|
175
|
-
wasm.__wbindgen_export4(deferred0_0, deferred0_1, 1);
|
|
176
|
-
}
|
|
4145
|
+
__wbg_set_6be42768c690e380: function(arg0, arg1, arg2) {
|
|
4146
|
+
getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
|
|
177
4147
|
},
|
|
178
|
-
|
|
179
|
-
const ret =
|
|
180
|
-
return addHeapObject(ret);
|
|
181
|
-
}, arguments); },
|
|
182
|
-
__wbg_get_unchecked_7d7babe32e9e6a54: function(arg0, arg1) {
|
|
183
|
-
const ret = getObject(arg0)[arg1 >>> 0];
|
|
4148
|
+
__wbg_set_fde2cec06c23692b: function(arg0, arg1, arg2) {
|
|
4149
|
+
const ret = getObject(arg0).set(getObject(arg1), getObject(arg2));
|
|
184
4150
|
return addHeapObject(ret);
|
|
185
4151
|
},
|
|
186
|
-
|
|
187
|
-
const ret =
|
|
4152
|
+
__wbg_wasmdocumentnode_new: function(arg0) {
|
|
4153
|
+
const ret = WasmDocumentNode.__wrap(arg0);
|
|
188
4154
|
return addHeapObject(ret);
|
|
189
4155
|
},
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
try {
|
|
193
|
-
result = getObject(arg0) instanceof ArrayBuffer;
|
|
194
|
-
} catch (_) {
|
|
195
|
-
result = false;
|
|
196
|
-
}
|
|
197
|
-
const ret = result;
|
|
198
|
-
return ret;
|
|
199
|
-
},
|
|
200
|
-
__wbg_instanceof_Object_72ee0c53dd8f0726: function(arg0) {
|
|
201
|
-
let result;
|
|
202
|
-
try {
|
|
203
|
-
result = getObject(arg0) instanceof Object;
|
|
204
|
-
} catch (_) {
|
|
205
|
-
result = false;
|
|
206
|
-
}
|
|
207
|
-
const ret = result;
|
|
208
|
-
return ret;
|
|
209
|
-
},
|
|
210
|
-
__wbg_instanceof_Uint8Array_4b8da683deb25d72: function(arg0) {
|
|
211
|
-
let result;
|
|
212
|
-
try {
|
|
213
|
-
result = getObject(arg0) instanceof Uint8Array;
|
|
214
|
-
} catch (_) {
|
|
215
|
-
result = false;
|
|
216
|
-
}
|
|
217
|
-
const ret = result;
|
|
218
|
-
return ret;
|
|
219
|
-
},
|
|
220
|
-
__wbg_isArray_db61795ad004c139: function(arg0) {
|
|
221
|
-
const ret = Array.isArray(getObject(arg0));
|
|
222
|
-
return ret;
|
|
223
|
-
},
|
|
224
|
-
__wbg_isSafeInteger_ea83862ba994770c: function(arg0) {
|
|
225
|
-
const ret = Number.isSafeInteger(getObject(arg0));
|
|
4156
|
+
__wbg_wasmdocumentnode_unwrap: function(arg0) {
|
|
4157
|
+
const ret = WasmDocumentNode.__unwrap(getObject(arg0));
|
|
226
4158
|
return ret;
|
|
227
4159
|
},
|
|
228
|
-
|
|
229
|
-
const ret =
|
|
230
|
-
return addHeapObject(ret);
|
|
231
|
-
},
|
|
232
|
-
__wbg_keys_e611eeb7873788db: function(arg0) {
|
|
233
|
-
const ret = Object.keys(getObject(arg0));
|
|
4160
|
+
__wbg_wasmgridcell_new: function(arg0) {
|
|
4161
|
+
const ret = WasmGridCell.__wrap(arg0);
|
|
234
4162
|
return addHeapObject(ret);
|
|
235
4163
|
},
|
|
236
|
-
|
|
237
|
-
const ret = getObject(arg0)
|
|
4164
|
+
__wbg_wasmgridcell_unwrap: function(arg0) {
|
|
4165
|
+
const ret = WasmGridCell.__unwrap(getObject(arg0));
|
|
238
4166
|
return ret;
|
|
239
4167
|
},
|
|
240
|
-
|
|
241
|
-
const ret =
|
|
242
|
-
return ret;
|
|
4168
|
+
__wbg_wasmheadermetadata_new: function(arg0) {
|
|
4169
|
+
const ret = WasmHeaderMetadata.__wrap(arg0);
|
|
4170
|
+
return addHeapObject(ret);
|
|
243
4171
|
},
|
|
244
|
-
|
|
245
|
-
const ret = getObject(arg0)
|
|
4172
|
+
__wbg_wasmheadermetadata_unwrap: function(arg0) {
|
|
4173
|
+
const ret = WasmHeaderMetadata.__unwrap(getObject(arg0));
|
|
246
4174
|
return ret;
|
|
247
4175
|
},
|
|
248
|
-
|
|
249
|
-
const ret =
|
|
250
|
-
return addHeapObject(ret);
|
|
251
|
-
},
|
|
252
|
-
__wbg_new_4f9fafbb3909af72: function() {
|
|
253
|
-
const ret = new Object();
|
|
4176
|
+
__wbg_wasmimagemetadata_new: function(arg0) {
|
|
4177
|
+
const ret = WasmImageMetadata.__wrap(arg0);
|
|
254
4178
|
return addHeapObject(ret);
|
|
255
4179
|
},
|
|
256
|
-
|
|
257
|
-
const ret =
|
|
258
|
-
return
|
|
4180
|
+
__wbg_wasmimagemetadata_unwrap: function(arg0) {
|
|
4181
|
+
const ret = WasmImageMetadata.__unwrap(getObject(arg0));
|
|
4182
|
+
return ret;
|
|
259
4183
|
},
|
|
260
|
-
|
|
261
|
-
const ret =
|
|
4184
|
+
__wbg_wasmlinkmetadata_new: function(arg0) {
|
|
4185
|
+
const ret = WasmLinkMetadata.__wrap(arg0);
|
|
262
4186
|
return addHeapObject(ret);
|
|
263
4187
|
},
|
|
264
|
-
|
|
265
|
-
const ret =
|
|
266
|
-
return
|
|
4188
|
+
__wbg_wasmlinkmetadata_unwrap: function(arg0) {
|
|
4189
|
+
const ret = WasmLinkMetadata.__unwrap(getObject(arg0));
|
|
4190
|
+
return ret;
|
|
267
4191
|
},
|
|
268
|
-
|
|
269
|
-
const ret =
|
|
4192
|
+
__wbg_wasmprocessingwarning_new: function(arg0) {
|
|
4193
|
+
const ret = WasmProcessingWarning.__wrap(arg0);
|
|
270
4194
|
return addHeapObject(ret);
|
|
271
4195
|
},
|
|
272
|
-
|
|
273
|
-
const ret = getObject(arg0)
|
|
274
|
-
return
|
|
4196
|
+
__wbg_wasmprocessingwarning_unwrap: function(arg0) {
|
|
4197
|
+
const ret = WasmProcessingWarning.__unwrap(getObject(arg0));
|
|
4198
|
+
return ret;
|
|
275
4199
|
},
|
|
276
|
-
|
|
277
|
-
const ret =
|
|
4200
|
+
__wbg_wasmstructureddata_new: function(arg0) {
|
|
4201
|
+
const ret = WasmStructuredData.__wrap(arg0);
|
|
278
4202
|
return addHeapObject(ret);
|
|
279
|
-
}, arguments); },
|
|
280
|
-
__wbg_prototypesetcall_3e05eb9545565046: function(arg0, arg1, arg2) {
|
|
281
|
-
Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), getObject(arg2));
|
|
282
4203
|
},
|
|
283
|
-
|
|
284
|
-
const ret =
|
|
4204
|
+
__wbg_wasmstructureddata_unwrap: function(arg0) {
|
|
4205
|
+
const ret = WasmStructuredData.__unwrap(getObject(arg0));
|
|
285
4206
|
return ret;
|
|
286
4207
|
},
|
|
287
|
-
|
|
288
|
-
const ret =
|
|
4208
|
+
__wbg_wasmtabledata_new: function(arg0) {
|
|
4209
|
+
const ret = WasmTableData.__wrap(arg0);
|
|
289
4210
|
return addHeapObject(ret);
|
|
290
4211
|
},
|
|
291
|
-
|
|
292
|
-
getObject(arg0)
|
|
293
|
-
},
|
|
294
|
-
__wbg_set_6c60b2e8ad0e9383: function(arg0, arg1, arg2) {
|
|
295
|
-
getObject(arg0)[arg1 >>> 0] = takeObject(arg2);
|
|
296
|
-
},
|
|
297
|
-
__wbg_set_8ee2d34facb8466e: function() { return handleError(function (arg0, arg1, arg2) {
|
|
298
|
-
const ret = Reflect.set(getObject(arg0), getObject(arg1), getObject(arg2));
|
|
4212
|
+
__wbg_wasmtabledata_unwrap: function(arg0) {
|
|
4213
|
+
const ret = WasmTableData.__unwrap(getObject(arg0));
|
|
299
4214
|
return ret;
|
|
300
|
-
}, arguments); },
|
|
301
|
-
__wbg_stack_3b0d974bbf31e44f: function(arg0, arg1) {
|
|
302
|
-
const ret = getObject(arg1).stack;
|
|
303
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
304
|
-
const len1 = WASM_VECTOR_LEN;
|
|
305
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
306
|
-
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
307
4215
|
},
|
|
308
|
-
|
|
309
|
-
const ret =
|
|
4216
|
+
__wbg_wasmtextannotation_new: function(arg0) {
|
|
4217
|
+
const ret = WasmTextAnnotation.__wrap(arg0);
|
|
310
4218
|
return addHeapObject(ret);
|
|
311
4219
|
},
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
return addHeapObject(ret);
|
|
4220
|
+
__wbg_wasmtextannotation_unwrap: function(arg0) {
|
|
4221
|
+
const ret = WasmTextAnnotation.__unwrap(getObject(arg0));
|
|
4222
|
+
return ret;
|
|
316
4223
|
},
|
|
317
|
-
|
|
4224
|
+
__wbindgen_cast_0000000000000001: function(arg0, arg1) {
|
|
318
4225
|
// Cast intrinsic for `Ref(String) -> Externref`.
|
|
319
4226
|
const ret = getStringFromWasm0(arg0, arg1);
|
|
320
4227
|
return addHeapObject(ret);
|
|
321
4228
|
},
|
|
322
|
-
__wbindgen_cast_0000000000000003: function(arg0) {
|
|
323
|
-
// Cast intrinsic for `U64 -> Externref`.
|
|
324
|
-
const ret = BigInt.asUintN(64, arg0);
|
|
325
|
-
return addHeapObject(ret);
|
|
326
|
-
},
|
|
327
4229
|
__wbindgen_object_clone_ref: function(arg0) {
|
|
328
4230
|
const ret = getObject(arg0);
|
|
329
4231
|
return addHeapObject(ret);
|
|
@@ -338,6 +4240,70 @@ function __wbg_get_imports() {
|
|
|
338
4240
|
};
|
|
339
4241
|
}
|
|
340
4242
|
|
|
4243
|
+
const WasmConversionOptionsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4244
|
+
? { register: () => {}, unregister: () => {} }
|
|
4245
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmconversionoptions_free(ptr >>> 0, 1));
|
|
4246
|
+
const WasmConversionOptionsBuilderFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4247
|
+
? { register: () => {}, unregister: () => {} }
|
|
4248
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmconversionoptionsbuilder_free(ptr >>> 0, 1));
|
|
4249
|
+
const WasmConversionOptionsUpdateFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4250
|
+
? { register: () => {}, unregister: () => {} }
|
|
4251
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmconversionoptionsupdate_free(ptr >>> 0, 1));
|
|
4252
|
+
const WasmConversionResultFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4253
|
+
? { register: () => {}, unregister: () => {} }
|
|
4254
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmconversionresult_free(ptr >>> 0, 1));
|
|
4255
|
+
const WasmDocumentMetadataFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4256
|
+
? { register: () => {}, unregister: () => {} }
|
|
4257
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmdocumentmetadata_free(ptr >>> 0, 1));
|
|
4258
|
+
const WasmDocumentNodeFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4259
|
+
? { register: () => {}, unregister: () => {} }
|
|
4260
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmdocumentnode_free(ptr >>> 0, 1));
|
|
4261
|
+
const WasmDocumentStructureFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4262
|
+
? { register: () => {}, unregister: () => {} }
|
|
4263
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmdocumentstructure_free(ptr >>> 0, 1));
|
|
4264
|
+
const WasmGridCellFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4265
|
+
? { register: () => {}, unregister: () => {} }
|
|
4266
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmgridcell_free(ptr >>> 0, 1));
|
|
4267
|
+
const WasmHeaderMetadataFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4268
|
+
? { register: () => {}, unregister: () => {} }
|
|
4269
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmheadermetadata_free(ptr >>> 0, 1));
|
|
4270
|
+
const WasmHtmlMetadataFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4271
|
+
? { register: () => {}, unregister: () => {} }
|
|
4272
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmhtmlmetadata_free(ptr >>> 0, 1));
|
|
4273
|
+
const WasmImageMetadataFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4274
|
+
? { register: () => {}, unregister: () => {} }
|
|
4275
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmimagemetadata_free(ptr >>> 0, 1));
|
|
4276
|
+
const WasmLinkMetadataFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4277
|
+
? { register: () => {}, unregister: () => {} }
|
|
4278
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmlinkmetadata_free(ptr >>> 0, 1));
|
|
4279
|
+
const WasmMetadataConfigFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4280
|
+
? { register: () => {}, unregister: () => {} }
|
|
4281
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmmetadataconfig_free(ptr >>> 0, 1));
|
|
4282
|
+
const WasmMetadataConfigUpdateFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4283
|
+
? { register: () => {}, unregister: () => {} }
|
|
4284
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmmetadataconfigupdate_free(ptr >>> 0, 1));
|
|
4285
|
+
const WasmPreprocessingOptionsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4286
|
+
? { register: () => {}, unregister: () => {} }
|
|
4287
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmpreprocessingoptions_free(ptr >>> 0, 1));
|
|
4288
|
+
const WasmPreprocessingOptionsUpdateFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4289
|
+
? { register: () => {}, unregister: () => {} }
|
|
4290
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmpreprocessingoptionsupdate_free(ptr >>> 0, 1));
|
|
4291
|
+
const WasmProcessingWarningFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4292
|
+
? { register: () => {}, unregister: () => {} }
|
|
4293
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmprocessingwarning_free(ptr >>> 0, 1));
|
|
4294
|
+
const WasmStructuredDataFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4295
|
+
? { register: () => {}, unregister: () => {} }
|
|
4296
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmstructureddata_free(ptr >>> 0, 1));
|
|
4297
|
+
const WasmTableDataFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4298
|
+
? { register: () => {}, unregister: () => {} }
|
|
4299
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmtabledata_free(ptr >>> 0, 1));
|
|
4300
|
+
const WasmTableGridFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4301
|
+
? { register: () => {}, unregister: () => {} }
|
|
4302
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmtablegrid_free(ptr >>> 0, 1));
|
|
4303
|
+
const WasmTextAnnotationFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
4304
|
+
? { register: () => {}, unregister: () => {} }
|
|
4305
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_wasmtextannotation_free(ptr >>> 0, 1));
|
|
4306
|
+
|
|
341
4307
|
function addHeapObject(obj) {
|
|
342
4308
|
if (heap_next === heap.length) heap.push(heap.length + 1);
|
|
343
4309
|
const idx = heap_next;
|
|
@@ -347,69 +4313,10 @@ function addHeapObject(obj) {
|
|
|
347
4313
|
return idx;
|
|
348
4314
|
}
|
|
349
4315
|
|
|
350
|
-
function
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
if (type == 'number' || type == 'boolean' || val == null) {
|
|
354
|
-
return `${val}`;
|
|
355
|
-
}
|
|
356
|
-
if (type == 'string') {
|
|
357
|
-
return `"${val}"`;
|
|
358
|
-
}
|
|
359
|
-
if (type == 'symbol') {
|
|
360
|
-
const description = val.description;
|
|
361
|
-
if (description == null) {
|
|
362
|
-
return 'Symbol';
|
|
363
|
-
} else {
|
|
364
|
-
return `Symbol(${description})`;
|
|
365
|
-
}
|
|
366
|
-
}
|
|
367
|
-
if (type == 'function') {
|
|
368
|
-
const name = val.name;
|
|
369
|
-
if (typeof name == 'string' && name.length > 0) {
|
|
370
|
-
return `Function(${name})`;
|
|
371
|
-
} else {
|
|
372
|
-
return 'Function';
|
|
373
|
-
}
|
|
374
|
-
}
|
|
375
|
-
// objects
|
|
376
|
-
if (Array.isArray(val)) {
|
|
377
|
-
const length = val.length;
|
|
378
|
-
let debug = '[';
|
|
379
|
-
if (length > 0) {
|
|
380
|
-
debug += debugString(val[0]);
|
|
381
|
-
}
|
|
382
|
-
for(let i = 1; i < length; i++) {
|
|
383
|
-
debug += ', ' + debugString(val[i]);
|
|
384
|
-
}
|
|
385
|
-
debug += ']';
|
|
386
|
-
return debug;
|
|
387
|
-
}
|
|
388
|
-
// Test for built-in
|
|
389
|
-
const builtInMatches = /\[object ([^\]]+)\]/.exec(toString.call(val));
|
|
390
|
-
let className;
|
|
391
|
-
if (builtInMatches && builtInMatches.length > 1) {
|
|
392
|
-
className = builtInMatches[1];
|
|
393
|
-
} else {
|
|
394
|
-
// Failed to match the standard '[object ClassName]'
|
|
395
|
-
return toString.call(val);
|
|
396
|
-
}
|
|
397
|
-
if (className == 'Object') {
|
|
398
|
-
// we're a user defined class or Object
|
|
399
|
-
// JSON.stringify avoids problems with cycles, and is generally much
|
|
400
|
-
// easier than looping through ownProperties of `val`.
|
|
401
|
-
try {
|
|
402
|
-
return 'Object(' + JSON.stringify(val) + ')';
|
|
403
|
-
} catch (_) {
|
|
404
|
-
return 'Object';
|
|
405
|
-
}
|
|
406
|
-
}
|
|
407
|
-
// errors
|
|
408
|
-
if (val instanceof Error) {
|
|
409
|
-
return `${val.name}: ${val.message}\n${val.stack}`;
|
|
4316
|
+
function _assertClass(instance, klass) {
|
|
4317
|
+
if (!(instance instanceof klass)) {
|
|
4318
|
+
throw new Error(`expected instance of ${klass.name}`);
|
|
410
4319
|
}
|
|
411
|
-
// TODO we could test for more things here, like `Set`s and `Map`s.
|
|
412
|
-
return className;
|
|
413
4320
|
}
|
|
414
4321
|
|
|
415
4322
|
function dropObject(idx) {
|
|
@@ -418,9 +4325,19 @@ function dropObject(idx) {
|
|
|
418
4325
|
heap_next = idx;
|
|
419
4326
|
}
|
|
420
4327
|
|
|
421
|
-
function
|
|
4328
|
+
function getArrayJsValueFromWasm0(ptr, len) {
|
|
4329
|
+
ptr = ptr >>> 0;
|
|
4330
|
+
const mem = getDataViewMemory0();
|
|
4331
|
+
const result = [];
|
|
4332
|
+
for (let i = ptr; i < ptr + 4 * len; i += 4) {
|
|
4333
|
+
result.push(takeObject(mem.getUint32(i, true)));
|
|
4334
|
+
}
|
|
4335
|
+
return result;
|
|
4336
|
+
}
|
|
4337
|
+
|
|
4338
|
+
function getArrayU32FromWasm0(ptr, len) {
|
|
422
4339
|
ptr = ptr >>> 0;
|
|
423
|
-
return
|
|
4340
|
+
return getUint32ArrayMemory0().subarray(ptr / 4, ptr / 4 + len);
|
|
424
4341
|
}
|
|
425
4342
|
|
|
426
4343
|
let cachedDataViewMemory0 = null;
|
|
@@ -436,6 +4353,14 @@ function getStringFromWasm0(ptr, len) {
|
|
|
436
4353
|
return decodeText(ptr, len);
|
|
437
4354
|
}
|
|
438
4355
|
|
|
4356
|
+
let cachedUint32ArrayMemory0 = null;
|
|
4357
|
+
function getUint32ArrayMemory0() {
|
|
4358
|
+
if (cachedUint32ArrayMemory0 === null || cachedUint32ArrayMemory0.byteLength === 0) {
|
|
4359
|
+
cachedUint32ArrayMemory0 = new Uint32Array(wasm.memory.buffer);
|
|
4360
|
+
}
|
|
4361
|
+
return cachedUint32ArrayMemory0;
|
|
4362
|
+
}
|
|
4363
|
+
|
|
439
4364
|
let cachedUint8ArrayMemory0 = null;
|
|
440
4365
|
function getUint8ArrayMemory0() {
|
|
441
4366
|
if (cachedUint8ArrayMemory0 === null || cachedUint8ArrayMemory0.byteLength === 0) {
|
|
@@ -446,14 +4371,6 @@ function getUint8ArrayMemory0() {
|
|
|
446
4371
|
|
|
447
4372
|
function getObject(idx) { return heap[idx]; }
|
|
448
4373
|
|
|
449
|
-
function handleError(f, args) {
|
|
450
|
-
try {
|
|
451
|
-
return f.apply(this, args);
|
|
452
|
-
} catch (e) {
|
|
453
|
-
wasm.__wbindgen_export3(addHeapObject(e));
|
|
454
|
-
}
|
|
455
|
-
}
|
|
456
|
-
|
|
457
4374
|
let heap = new Array(1024).fill(undefined);
|
|
458
4375
|
heap.push(undefined, null, true, false);
|
|
459
4376
|
|
|
@@ -463,6 +4380,23 @@ function isLikeNone(x) {
|
|
|
463
4380
|
return x === undefined || x === null;
|
|
464
4381
|
}
|
|
465
4382
|
|
|
4383
|
+
function passArray32ToWasm0(arg, malloc) {
|
|
4384
|
+
const ptr = malloc(arg.length * 4, 4) >>> 0;
|
|
4385
|
+
getUint32ArrayMemory0().set(arg, ptr / 4);
|
|
4386
|
+
WASM_VECTOR_LEN = arg.length;
|
|
4387
|
+
return ptr;
|
|
4388
|
+
}
|
|
4389
|
+
|
|
4390
|
+
function passArrayJsValueToWasm0(array, malloc) {
|
|
4391
|
+
const ptr = malloc(array.length * 4, 4) >>> 0;
|
|
4392
|
+
const mem = getDataViewMemory0();
|
|
4393
|
+
for (let i = 0; i < array.length; i++) {
|
|
4394
|
+
mem.setUint32(ptr + 4 * i, addHeapObject(array[i]), true);
|
|
4395
|
+
}
|
|
4396
|
+
WASM_VECTOR_LEN = array.length;
|
|
4397
|
+
return ptr;
|
|
4398
|
+
}
|
|
4399
|
+
|
|
466
4400
|
function passStringToWasm0(arg, malloc, realloc) {
|
|
467
4401
|
if (realloc === undefined) {
|
|
468
4402
|
const buf = cachedTextEncoder.encode(arg);
|
|
@@ -531,4 +4465,3 @@ const wasmPath = `${__dirname}/html_to_markdown_wasm_bg.wasm`;
|
|
|
531
4465
|
const wasmBytes = require('fs').readFileSync(wasmPath);
|
|
532
4466
|
const wasmModule = new WebAssembly.Module(wasmBytes);
|
|
533
4467
|
let wasm = new WebAssembly.Instance(wasmModule, __wbg_get_imports()).exports;
|
|
534
|
-
wasm.__wbindgen_start();
|