@quillmark/wasm 0.54.1 → 0.58.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,41 +1,25 @@
1
- export class CompiledDocument {
2
- static __wrap(ptr) {
3
- ptr = ptr >>> 0;
4
- const obj = Object.create(CompiledDocument.prototype);
5
- obj.__wbg_ptr = ptr;
6
- CompiledDocumentFinalization.register(obj, obj.__wbg_ptr, obj);
7
- return obj;
8
- }
1
+ export class ParsedDocument {
9
2
  __destroy_into_raw() {
10
3
  const ptr = this.__wbg_ptr;
11
4
  this.__wbg_ptr = 0;
12
- CompiledDocumentFinalization.unregister(this);
5
+ ParsedDocumentFinalization.unregister(this);
13
6
  return ptr;
14
7
  }
15
8
  free() {
16
9
  const ptr = this.__destroy_into_raw();
17
- wasm.__wbg_compileddocument_free(ptr, 0);
10
+ wasm.__wbg_parseddocument_free(ptr, 0);
18
11
  }
19
12
  /**
20
- * Number of pages in this compiled document.
21
- * @returns {number}
22
- */
23
- get pageCount() {
24
- const ret = wasm.compileddocument_pageCount(this.__wbg_ptr);
25
- return ret >>> 0;
26
- }
27
- /**
28
- * Render selected pages. `pages = null/undefined` renders all pages.
29
- * @param {Uint32Array | null | undefined} pages
30
- * @param {RenderPagesOptions} opts
31
- * @returns {RenderResult}
13
+ * Parse markdown into a ParsedDocument.
14
+ * @param {string} markdown
15
+ * @returns {ParsedDocument}
32
16
  */
33
- renderPages(pages, opts) {
17
+ static fromMarkdown(markdown) {
34
18
  try {
35
19
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
36
- var ptr0 = isLikeNone(pages) ? 0 : passArray32ToWasm0(pages, wasm.__wbindgen_export);
37
- var len0 = WASM_VECTOR_LEN;
38
- wasm.compileddocument_renderPages(retptr, this.__wbg_ptr, ptr0, len0, addHeapObject(opts));
20
+ const ptr0 = passStringToWasm0(markdown, wasm.__wbindgen_export, wasm.__wbindgen_export2);
21
+ const len0 = WASM_VECTOR_LEN;
22
+ wasm.parseddocument_fromMarkdown(retptr, ptr0, len0);
39
23
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
40
24
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
41
25
  var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
@@ -48,111 +32,59 @@ export class CompiledDocument {
48
32
  }
49
33
  }
50
34
  }
51
- if (Symbol.dispose) CompiledDocument.prototype[Symbol.dispose] = CompiledDocument.prototype.free;
35
+ if (Symbol.dispose) ParsedDocument.prototype[Symbol.dispose] = ParsedDocument.prototype.free;
52
36
 
53
37
  /**
54
- * Quillmark WASM Engine
55
- *
56
- * Create once, register Quills, render markdown. That's it.
38
+ * Opaque, shareable Quill handle.
57
39
  */
58
- export class Quillmark {
40
+ export class Quill {
41
+ static __wrap(ptr) {
42
+ ptr = ptr >>> 0;
43
+ const obj = Object.create(Quill.prototype);
44
+ obj.__wbg_ptr = ptr;
45
+ QuillFinalization.register(obj, obj.__wbg_ptr, obj);
46
+ return obj;
47
+ }
59
48
  __destroy_into_raw() {
60
49
  const ptr = this.__wbg_ptr;
61
50
  this.__wbg_ptr = 0;
62
- QuillmarkFinalization.unregister(this);
51
+ QuillFinalization.unregister(this);
63
52
  return ptr;
64
53
  }
65
54
  free() {
66
55
  const ptr = this.__destroy_into_raw();
67
- wasm.__wbg_quillmark_free(ptr, 0);
56
+ wasm.__wbg_quill_free(ptr, 0);
68
57
  }
69
58
  /**
70
- * Compile a parsed document into an opaque compiled document handle.
59
+ * Open an iterative render session for page-selective rendering.
71
60
  * @param {ParsedDocument} parsed
72
- * @param {CompileOptions | null} [opts]
73
- * @returns {CompiledDocument}
74
- */
75
- compile(parsed, opts) {
76
- try {
77
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
78
- wasm.quillmark_compile(retptr, this.__wbg_ptr, addHeapObject(parsed), isLikeNone(opts) ? 0 : addHeapObject(opts));
79
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
80
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
81
- var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
82
- if (r2) {
83
- throw takeObject(r1);
84
- }
85
- return CompiledDocument.__wrap(r0);
86
- } finally {
87
- wasm.__wbindgen_add_to_stack_pointer(16);
88
- }
89
- }
90
- /**
91
- * Compile markdown to JSON data without rendering artifacts.
92
- *
93
- * This exposes the intermediate data structure that would be passed to the backend.
94
- * Useful for debugging and validation.
95
- * @param {string} markdown
96
- * @returns {any}
61
+ * @returns {RenderSession}
97
62
  */
98
- compileData(markdown) {
63
+ open(parsed) {
99
64
  try {
100
65
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
101
- const ptr0 = passStringToWasm0(markdown, wasm.__wbindgen_export, wasm.__wbindgen_export2);
102
- const len0 = WASM_VECTOR_LEN;
103
- wasm.quillmark_compileData(retptr, this.__wbg_ptr, ptr0, len0);
66
+ wasm.quill_open(retptr, this.__wbg_ptr, addHeapObject(parsed));
104
67
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
105
68
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
106
69
  var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
107
70
  if (r2) {
108
71
  throw takeObject(r1);
109
72
  }
110
- return takeObject(r0);
111
- } finally {
112
- wasm.__wbindgen_add_to_stack_pointer(16);
113
- }
114
- }
115
- /**
116
- * Perform a dry run validation without backend compilation.
117
- *
118
- * Executes parsing, schema validation, and template composition to
119
- * surface input errors quickly. Returns successfully on valid input,
120
- * or throws an error with diagnostic payload on failure.
121
- *
122
- * The quill name is read from the markdown's required QUILL tag.
123
- *
124
- * This is useful for fast feedback loops in LLM-driven document generation.
125
- * @param {string} markdown
126
- */
127
- dryRun(markdown) {
128
- try {
129
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
130
- const ptr0 = passStringToWasm0(markdown, wasm.__wbindgen_export, wasm.__wbindgen_export2);
131
- const len0 = WASM_VECTOR_LEN;
132
- wasm.quillmark_dryRun(retptr, this.__wbg_ptr, ptr0, len0);
133
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
134
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
135
- if (r1) {
136
- throw takeObject(r0);
137
- }
73
+ return RenderSession.__wrap(r0);
138
74
  } finally {
139
75
  wasm.__wbindgen_add_to_stack_pointer(16);
140
76
  }
141
77
  }
142
78
  /**
143
- * Get shallow information about a registered Quill
144
- *
145
- * This returns metadata, backend info, field schemas, and supported formats
146
- * that consumers need to configure render options for the next step.
147
- * @param {string} name
148
- * @returns {QuillInfo}
79
+ * Render a document to final artifacts.
80
+ * @param {ParsedDocument} parsed
81
+ * @param {RenderOptions} opts
82
+ * @returns {RenderResult}
149
83
  */
150
- getQuillInfo(name) {
84
+ render(parsed, opts) {
151
85
  try {
152
86
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
153
- const ptr0 = passStringToWasm0(name, wasm.__wbindgen_export, wasm.__wbindgen_export2);
154
- const len0 = WASM_VECTOR_LEN;
155
- wasm.quillmark_getQuillInfo(retptr, this.__wbg_ptr, ptr0, len0);
87
+ wasm.quill_render(retptr, this.__wbg_ptr, addHeapObject(parsed), addHeapObject(opts));
156
88
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
157
89
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
158
90
  var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
@@ -164,55 +96,22 @@ export class Quillmark {
164
96
  wasm.__wbindgen_add_to_stack_pointer(16);
165
97
  }
166
98
  }
167
- /**
168
- * Get the public YAML schema contract for a registered quill.
169
- * @param {string} name
170
- * @returns {string}
171
- */
172
- getQuillSchema(name) {
173
- let deferred3_0;
174
- let deferred3_1;
175
- try {
176
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
177
- const ptr0 = passStringToWasm0(name, wasm.__wbindgen_export, wasm.__wbindgen_export2);
178
- const len0 = WASM_VECTOR_LEN;
179
- wasm.quillmark_getQuillSchema(retptr, this.__wbg_ptr, ptr0, len0);
180
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
181
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
182
- var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
183
- var r3 = getDataViewMemory0().getInt32(retptr + 4 * 3, true);
184
- var ptr2 = r0;
185
- var len2 = r1;
186
- if (r3) {
187
- ptr2 = 0; len2 = 0;
188
- throw takeObject(r2);
189
- }
190
- deferred3_0 = ptr2;
191
- deferred3_1 = len2;
192
- return getStringFromWasm0(ptr2, len2);
193
- } finally {
194
- wasm.__wbindgen_add_to_stack_pointer(16);
195
- wasm.__wbindgen_export4(deferred3_0, deferred3_1, 1);
196
- }
99
+ }
100
+ if (Symbol.dispose) Quill.prototype[Symbol.dispose] = Quill.prototype.free;
101
+
102
+ /**
103
+ * Quillmark WASM Engine
104
+ */
105
+ export class Quillmark {
106
+ __destroy_into_raw() {
107
+ const ptr = this.__wbg_ptr;
108
+ this.__wbg_ptr = 0;
109
+ QuillmarkFinalization.unregister(this);
110
+ return ptr;
197
111
  }
198
- /**
199
- * List registered Quills with their exact versions
200
- *
201
- * Returns strings in the format "name@version" (e.g. "resume-template@2.1.0")
202
- * @returns {string[]}
203
- */
204
- listQuills() {
205
- try {
206
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
207
- wasm.quillmark_listQuills(retptr, this.__wbg_ptr);
208
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
209
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
210
- var v1 = getArrayJsValueFromWasm0(r0, r1).slice();
211
- wasm.__wbindgen_export4(r0, r1 * 4, 4);
212
- return v1;
213
- } finally {
214
- wasm.__wbindgen_add_to_stack_pointer(16);
215
- }
112
+ free() {
113
+ const ptr = this.__destroy_into_raw();
114
+ wasm.__wbg_quillmark_free(ptr, 0);
216
115
  }
217
116
  /**
218
117
  * JavaScript constructor: `new Quillmark()`
@@ -224,65 +123,65 @@ export class Quillmark {
224
123
  return this;
225
124
  }
226
125
  /**
227
- * Parse markdown into a ParsedDocument
126
+ * Load a quill from a file tree and attach the appropriate backend.
228
127
  *
229
- * This is the first step in the workflow. The returned ParsedDocument contains
230
- * the parsed YAML frontmatter fields and the quill_ref from QUILL.
231
- * @param {string} markdown
232
- * @returns {ParsedDocument}
128
+ * The tree must be a `Map<string, Uint8Array>`.
129
+ * @param {any} tree
130
+ * @returns {Quill}
233
131
  */
234
- static parseMarkdown(markdown) {
132
+ quill(tree) {
235
133
  try {
236
134
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
237
- const ptr0 = passStringToWasm0(markdown, wasm.__wbindgen_export, wasm.__wbindgen_export2);
238
- const len0 = WASM_VECTOR_LEN;
239
- wasm.quillmark_parseMarkdown(retptr, ptr0, len0);
135
+ wasm.quillmark_quill(retptr, this.__wbg_ptr, addHeapObject(tree));
240
136
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
241
137
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
242
138
  var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
243
139
  if (r2) {
244
140
  throw takeObject(r1);
245
141
  }
246
- return takeObject(r0);
142
+ return Quill.__wrap(r0);
247
143
  } finally {
248
144
  wasm.__wbindgen_add_to_stack_pointer(16);
249
145
  }
250
146
  }
147
+ }
148
+ if (Symbol.dispose) Quillmark.prototype[Symbol.dispose] = Quillmark.prototype.free;
149
+
150
+ export class RenderSession {
151
+ static __wrap(ptr) {
152
+ ptr = ptr >>> 0;
153
+ const obj = Object.create(RenderSession.prototype);
154
+ obj.__wbg_ptr = ptr;
155
+ RenderSessionFinalization.register(obj, obj.__wbg_ptr, obj);
156
+ return obj;
157
+ }
158
+ __destroy_into_raw() {
159
+ const ptr = this.__wbg_ptr;
160
+ this.__wbg_ptr = 0;
161
+ RenderSessionFinalization.unregister(this);
162
+ return ptr;
163
+ }
164
+ free() {
165
+ const ptr = this.__destroy_into_raw();
166
+ wasm.__wbg_rendersession_free(ptr, 0);
167
+ }
251
168
  /**
252
- * Register a Quill template bundle
253
- *
254
- * Accepts either a JSON string or a JsValue object representing the Quill file tree.
255
- * Validation happens automatically on registration.
256
- * @param {any} quill_json
257
- * @returns {QuillInfo}
169
+ * Number of pages in this render session.
170
+ * @returns {number}
258
171
  */
259
- registerQuill(quill_json) {
260
- try {
261
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
262
- wasm.quillmark_registerQuill(retptr, this.__wbg_ptr, addHeapObject(quill_json));
263
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
264
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
265
- var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
266
- if (r2) {
267
- throw takeObject(r1);
268
- }
269
- return takeObject(r0);
270
- } finally {
271
- wasm.__wbindgen_add_to_stack_pointer(16);
272
- }
172
+ get pageCount() {
173
+ const ret = wasm.rendersession_pageCount(this.__wbg_ptr);
174
+ return ret >>> 0;
273
175
  }
274
176
  /**
275
- * Render a ParsedDocument to final artifacts (PDF, SVG, TXT)
276
- *
277
- * Uses the Quill specified in the ParsedDocument's quill_ref field.
278
- * @param {ParsedDocument} parsed
177
+ * Render all or selected pages from this session.
279
178
  * @param {RenderOptions} opts
280
179
  * @returns {RenderResult}
281
180
  */
282
- render(parsed, opts) {
181
+ render(opts) {
283
182
  try {
284
183
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
285
- wasm.quillmark_render(retptr, this.__wbg_ptr, addHeapObject(parsed), addHeapObject(opts));
184
+ wasm.rendersession_render(retptr, this.__wbg_ptr, addHeapObject(opts));
286
185
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
287
186
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
288
187
  var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
@@ -294,38 +193,8 @@ export class Quillmark {
294
193
  wasm.__wbindgen_add_to_stack_pointer(16);
295
194
  }
296
195
  }
297
- /**
298
- * Resolve a Quill reference to a registered Quill, or null if not available
299
- *
300
- * Accepts a quill reference string like "resume-template", "resume-template@2",
301
- * or "resume-template@2.1.0". Returns QuillInfo if the engine can resolve it
302
- * locally, or null if an external fetch is needed.
303
- * @param {string} quill_ref
304
- * @returns {any}
305
- */
306
- resolveQuill(quill_ref) {
307
- const ptr0 = passStringToWasm0(quill_ref, wasm.__wbindgen_export, wasm.__wbindgen_export2);
308
- const len0 = WASM_VECTOR_LEN;
309
- const ret = wasm.quillmark_resolveQuill(this.__wbg_ptr, ptr0, len0);
310
- return takeObject(ret);
311
- }
312
- /**
313
- * Unregister a Quill by name or specific version
314
- *
315
- * If a base name is provided (e.g., "my-quill"), all versions of that quill are freed.
316
- * If a versioned name is provided (e.g., "my-quill@2.1.0"), only that specific version is freed.
317
- * Returns true if something was unregistered, false if not found.
318
- * @param {string} name_or_ref
319
- * @returns {boolean}
320
- */
321
- unregisterQuill(name_or_ref) {
322
- const ptr0 = passStringToWasm0(name_or_ref, wasm.__wbindgen_export, wasm.__wbindgen_export2);
323
- const len0 = WASM_VECTOR_LEN;
324
- const ret = wasm.quillmark_unregisterQuill(this.__wbg_ptr, ptr0, len0);
325
- return ret !== 0;
326
- }
327
196
  }
328
- if (Symbol.dispose) Quillmark.prototype[Symbol.dispose] = Quillmark.prototype.free;
197
+ if (Symbol.dispose) RenderSession.prototype[Symbol.dispose] = RenderSession.prototype.free;
329
198
 
330
199
  /**
331
200
  * Initialize the WASM module with panic hooks for better error messages
@@ -333,7 +202,7 @@ if (Symbol.dispose) Quillmark.prototype[Symbol.dispose] = Quillmark.prototype.fr
333
202
  export function init() {
334
203
  wasm.init();
335
204
  }
336
- export function __wbg_Error_2e59b1b37a9a34c3(arg0, arg1) {
205
+ export function __wbg_Error_960c155d3d49e4c2(arg0, arg1) {
337
206
  const ret = Error(getStringFromWasm0(arg0, arg1));
338
207
  return addHeapObject(ret);
339
208
  }
@@ -344,64 +213,64 @@ export function __wbg_String_b51de6b05a10845b(arg0, arg1) {
344
213
  getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
345
214
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
346
215
  }
347
- export function __wbg___wbindgen_bigint_get_as_i64_2c5082002e4826e2(arg0, arg1) {
216
+ export function __wbg___wbindgen_bigint_get_as_i64_3d3aba5d616c6a51(arg0, arg1) {
348
217
  const v = getObject(arg1);
349
218
  const ret = typeof(v) === 'bigint' ? v : undefined;
350
219
  getDataViewMemory0().setBigInt64(arg0 + 8 * 1, isLikeNone(ret) ? BigInt(0) : ret, true);
351
220
  getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
352
221
  }
353
- export function __wbg___wbindgen_boolean_get_a86c216575a75c30(arg0) {
222
+ export function __wbg___wbindgen_boolean_get_6ea149f0a8dcc5ff(arg0) {
354
223
  const v = getObject(arg0);
355
224
  const ret = typeof(v) === 'boolean' ? v : undefined;
356
225
  return isLikeNone(ret) ? 0xFFFFFF : ret ? 1 : 0;
357
226
  }
358
- export function __wbg___wbindgen_debug_string_dd5d2d07ce9e6c57(arg0, arg1) {
227
+ export function __wbg___wbindgen_debug_string_ab4b34d23d6778bd(arg0, arg1) {
359
228
  const ret = debugString(getObject(arg1));
360
229
  const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
361
230
  const len1 = WASM_VECTOR_LEN;
362
231
  getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
363
232
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
364
233
  }
365
- export function __wbg___wbindgen_in_4bd7a57e54337366(arg0, arg1) {
234
+ export function __wbg___wbindgen_in_a5d8b22e52b24dd1(arg0, arg1) {
366
235
  const ret = getObject(arg0) in getObject(arg1);
367
236
  return ret;
368
237
  }
369
- export function __wbg___wbindgen_is_bigint_6c98f7e945dacdde(arg0) {
238
+ export function __wbg___wbindgen_is_bigint_ec25c7f91b4d9e93(arg0) {
370
239
  const ret = typeof(getObject(arg0)) === 'bigint';
371
240
  return ret;
372
241
  }
373
- export function __wbg___wbindgen_is_function_49868bde5eb1e745(arg0) {
242
+ export function __wbg___wbindgen_is_function_3baa9db1a987f47d(arg0) {
374
243
  const ret = typeof(getObject(arg0)) === 'function';
375
244
  return ret;
376
245
  }
377
- export function __wbg___wbindgen_is_object_40c5a80572e8f9d3(arg0) {
246
+ export function __wbg___wbindgen_is_object_63322ec0cd6ea4ef(arg0) {
378
247
  const val = getObject(arg0);
379
248
  const ret = typeof(val) === 'object' && val !== null;
380
249
  return ret;
381
250
  }
382
- export function __wbg___wbindgen_is_string_b29b5c5a8065ba1a(arg0) {
251
+ export function __wbg___wbindgen_is_string_6df3bf7ef1164ed3(arg0) {
383
252
  const ret = typeof(getObject(arg0)) === 'string';
384
253
  return ret;
385
254
  }
386
- export function __wbg___wbindgen_is_undefined_c0cca72b82b86f4d(arg0) {
255
+ export function __wbg___wbindgen_is_undefined_29a43b4d42920abd(arg0) {
387
256
  const ret = getObject(arg0) === undefined;
388
257
  return ret;
389
258
  }
390
- export function __wbg___wbindgen_jsval_eq_7d430e744a913d26(arg0, arg1) {
259
+ export function __wbg___wbindgen_jsval_eq_d3465d8a07697228(arg0, arg1) {
391
260
  const ret = getObject(arg0) === getObject(arg1);
392
261
  return ret;
393
262
  }
394
- export function __wbg___wbindgen_jsval_loose_eq_3a72ae764d46d944(arg0, arg1) {
263
+ export function __wbg___wbindgen_jsval_loose_eq_cac3565e89b4134c(arg0, arg1) {
395
264
  const ret = getObject(arg0) == getObject(arg1);
396
265
  return ret;
397
266
  }
398
- export function __wbg___wbindgen_number_get_7579aab02a8a620c(arg0, arg1) {
267
+ export function __wbg___wbindgen_number_get_c7f42aed0525c451(arg0, arg1) {
399
268
  const obj = getObject(arg1);
400
269
  const ret = typeof(obj) === 'number' ? obj : undefined;
401
270
  getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
402
271
  getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
403
272
  }
404
- export function __wbg___wbindgen_string_get_914df97fcfa788f2(arg0, arg1) {
273
+ export function __wbg___wbindgen_string_get_7ed5322991caaec5(arg0, arg1) {
405
274
  const obj = getObject(arg1);
406
275
  const ret = typeof(obj) === 'string' ? obj : undefined;
407
276
  var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
@@ -409,18 +278,22 @@ export function __wbg___wbindgen_string_get_914df97fcfa788f2(arg0, arg1) {
409
278
  getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
410
279
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
411
280
  }
412
- export function __wbg___wbindgen_throw_81fc77679af83bc6(arg0, arg1) {
281
+ export function __wbg___wbindgen_throw_6b64449b9b9ed33c(arg0, arg1) {
413
282
  throw new Error(getStringFromWasm0(arg0, arg1));
414
283
  }
415
- export function __wbg_call_7f2987183bb62793() { return handleError(function (arg0, arg1) {
284
+ export function __wbg_call_14b169f759b26747() { return handleError(function (arg0, arg1) {
416
285
  const ret = getObject(arg0).call(getObject(arg1));
417
286
  return addHeapObject(ret);
418
287
  }, arguments); }
419
- export function __wbg_done_547d467e97529006(arg0) {
288
+ export function __wbg_done_9158f7cc8751ba32(arg0) {
420
289
  const ret = getObject(arg0).done;
421
290
  return ret;
422
291
  }
423
- export function __wbg_entries_616b1a459b85be0b(arg0) {
292
+ export function __wbg_entries_2bf997cf82353e47(arg0) {
293
+ const ret = getObject(arg0).entries();
294
+ return addHeapObject(ret);
295
+ }
296
+ export function __wbg_entries_e0b73aa8571ddb56(arg0) {
424
297
  const ret = Object.entries(getObject(arg0));
425
298
  return addHeapObject(ret);
426
299
  }
@@ -435,34 +308,38 @@ export function __wbg_error_a6fa202b58aa1cd3(arg0, arg1) {
435
308
  wasm.__wbindgen_export4(deferred0_0, deferred0_1, 1);
436
309
  }
437
310
  }
311
+ export function __wbg_from_0dbf29f09e7fb200(arg0) {
312
+ const ret = Array.from(getObject(arg0));
313
+ return addHeapObject(ret);
314
+ }
438
315
  export function __wbg_getRandomValues_3f44b700395062e5() { return handleError(function (arg0, arg1) {
439
316
  globalThis.crypto.getRandomValues(getArrayU8FromWasm0(arg0, arg1));
440
317
  }, arguments); }
441
- export function __wbg_getTime_f6ac312467f7cf09(arg0) {
318
+ export function __wbg_getTime_da7c55f52b71e8c6(arg0) {
442
319
  const ret = getObject(arg0).getTime();
443
320
  return ret;
444
321
  }
445
- export function __wbg_getUTCDate_9b73619d33527a0e(arg0) {
322
+ export function __wbg_getUTCDate_5cd8b68e971333f7(arg0) {
446
323
  const ret = getObject(arg0).getUTCDate();
447
324
  return ret;
448
325
  }
449
- export function __wbg_getUTCFullYear_1c80c08b216993d4(arg0) {
326
+ export function __wbg_getUTCFullYear_f3b3950a0ccb9165(arg0) {
450
327
  const ret = getObject(arg0).getUTCFullYear();
451
328
  return ret;
452
329
  }
453
- export function __wbg_getUTCMonth_ea2d5842542c5998(arg0) {
330
+ export function __wbg_getUTCMonth_62fa72a7522ef806(arg0) {
454
331
  const ret = getObject(arg0).getUTCMonth();
455
332
  return ret;
456
333
  }
457
- export function __wbg_get_4848e350b40afc16(arg0, arg1) {
458
- const ret = getObject(arg0)[arg1 >>> 0];
459
- return addHeapObject(ret);
460
- }
461
- export function __wbg_get_ed0642c4b9d31ddf() { return handleError(function (arg0, arg1) {
334
+ export function __wbg_get_1affdbdd5573b16a() { return handleError(function (arg0, arg1) {
462
335
  const ret = Reflect.get(getObject(arg0), getObject(arg1));
463
336
  return addHeapObject(ret);
464
337
  }, arguments); }
465
- export function __wbg_get_unchecked_7d7babe32e9e6a54(arg0, arg1) {
338
+ export function __wbg_get_8360291721e2339f(arg0, arg1) {
339
+ const ret = getObject(arg0)[arg1 >>> 0];
340
+ return addHeapObject(ret);
341
+ }
342
+ export function __wbg_get_unchecked_17f53dad852b9588(arg0, arg1) {
466
343
  const ret = getObject(arg0)[arg1 >>> 0];
467
344
  return addHeapObject(ret);
468
345
  }
@@ -470,7 +347,7 @@ export function __wbg_get_with_ref_key_f64427178466f623(arg0, arg1) {
470
347
  const ret = getObject(arg0)[getObject(arg1)];
471
348
  return addHeapObject(ret);
472
349
  }
473
- export function __wbg_instanceof_ArrayBuffer_ff7c1337a5e3b33a(arg0) {
350
+ export function __wbg_instanceof_ArrayBuffer_7c8433c6ed14ffe3(arg0) {
474
351
  let result;
475
352
  try {
476
353
  result = getObject(arg0) instanceof ArrayBuffer;
@@ -480,7 +357,17 @@ export function __wbg_instanceof_ArrayBuffer_ff7c1337a5e3b33a(arg0) {
480
357
  const ret = result;
481
358
  return ret;
482
359
  }
483
- export function __wbg_instanceof_Uint8Array_4b8da683deb25d72(arg0) {
360
+ export function __wbg_instanceof_Map_1b76fd4635be43eb(arg0) {
361
+ let result;
362
+ try {
363
+ result = getObject(arg0) instanceof Map;
364
+ } catch (_) {
365
+ result = false;
366
+ }
367
+ const ret = result;
368
+ return ret;
369
+ }
370
+ export function __wbg_instanceof_Uint8Array_152ba1f289edcf3f(arg0) {
484
371
  let result;
485
372
  try {
486
373
  result = getObject(arg0) instanceof Uint8Array;
@@ -490,86 +377,82 @@ export function __wbg_instanceof_Uint8Array_4b8da683deb25d72(arg0) {
490
377
  const ret = result;
491
378
  return ret;
492
379
  }
493
- export function __wbg_isArray_db61795ad004c139(arg0) {
380
+ export function __wbg_isArray_c3109d14ffc06469(arg0) {
494
381
  const ret = Array.isArray(getObject(arg0));
495
382
  return ret;
496
383
  }
497
- export function __wbg_isSafeInteger_ea83862ba994770c(arg0) {
384
+ export function __wbg_isSafeInteger_4fc213d1989d6d2a(arg0) {
498
385
  const ret = Number.isSafeInteger(getObject(arg0));
499
386
  return ret;
500
387
  }
501
- export function __wbg_iterator_de403ef31815a3e6() {
388
+ export function __wbg_iterator_013bc09ec998c2a7() {
502
389
  const ret = Symbol.iterator;
503
390
  return addHeapObject(ret);
504
391
  }
505
- export function __wbg_length_0c32cb8543c8e4c8(arg0) {
392
+ export function __wbg_length_3d4ecd04bd8d22f1(arg0) {
506
393
  const ret = getObject(arg0).length;
507
394
  return ret;
508
395
  }
509
- export function __wbg_length_6e821edde497a532(arg0) {
396
+ export function __wbg_length_9f1775224cf1d815(arg0) {
510
397
  const ret = getObject(arg0).length;
511
398
  return ret;
512
399
  }
513
- export function __wbg_new_0_bfa2ef4bc447daa2() {
400
+ export function __wbg_new_0_4d657201ced14de3() {
514
401
  const ret = new Date();
515
402
  return addHeapObject(ret);
516
403
  }
517
- export function __wbg_new_0f6d2ddfe083319b(arg0) {
518
- const ret = new Date(getObject(arg0));
404
+ export function __wbg_new_0c7403db6e782f19(arg0) {
405
+ const ret = new Uint8Array(getObject(arg0));
519
406
  return addHeapObject(ret);
520
407
  }
521
408
  export function __wbg_new_227d7c05414eb861() {
522
409
  const ret = new Error();
523
410
  return addHeapObject(ret);
524
411
  }
525
- export function __wbg_new_4f9fafbb3909af72() {
526
- const ret = new Object();
527
- return addHeapObject(ret);
528
- }
529
- export function __wbg_new_99cabae501c0a8a0() {
412
+ export function __wbg_new_34d45cc8e36aaead() {
530
413
  const ret = new Map();
531
414
  return addHeapObject(ret);
532
415
  }
533
- export function __wbg_new_a560378ea1240b14(arg0) {
534
- const ret = new Uint8Array(getObject(arg0));
416
+ export function __wbg_new_682678e2f47e32bc() {
417
+ const ret = new Array();
535
418
  return addHeapObject(ret);
536
419
  }
537
- export function __wbg_new_f3c9df4f38f3f798() {
538
- const ret = new Array();
420
+ export function __wbg_new_7913666fe5070684(arg0) {
421
+ const ret = new Date(getObject(arg0));
539
422
  return addHeapObject(ret);
540
423
  }
541
- export function __wbg_next_01132ed6134b8ef5(arg0) {
542
- const ret = getObject(arg0).next;
424
+ export function __wbg_new_aa8d0fa9762c29bd() {
425
+ const ret = new Object();
543
426
  return addHeapObject(ret);
544
427
  }
545
- export function __wbg_next_b3713ec761a9dbfd() { return handleError(function (arg0) {
428
+ export function __wbg_next_0340c4ae324393c3() { return handleError(function (arg0) {
546
429
  const ret = getObject(arg0).next();
547
430
  return addHeapObject(ret);
548
431
  }, arguments); }
549
- export function __wbg_now_88621c9c9a4f3ffc() {
432
+ export function __wbg_next_7646edaa39458ef7(arg0) {
433
+ const ret = getObject(arg0).next;
434
+ return addHeapObject(ret);
435
+ }
436
+ export function __wbg_now_a9b7df1cbee90986() {
550
437
  const ret = Date.now();
551
438
  return ret;
552
439
  }
553
- export function __wbg_parse_545d11396395fbbd() { return handleError(function (arg0, arg1) {
554
- const ret = JSON.parse(getStringFromWasm0(arg0, arg1));
555
- return addHeapObject(ret);
556
- }, arguments); }
557
- export function __wbg_prototypesetcall_3e05eb9545565046(arg0, arg1, arg2) {
440
+ export function __wbg_prototypesetcall_a6b02eb00b0f4ce2(arg0, arg1, arg2) {
558
441
  Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), getObject(arg2));
559
442
  }
560
- export function __wbg_set_08463b1df38a7e29(arg0, arg1, arg2) {
561
- const ret = getObject(arg0).set(getObject(arg1), getObject(arg2));
562
- return addHeapObject(ret);
443
+ export function __wbg_set_3bf1de9fab0cd644(arg0, arg1, arg2) {
444
+ getObject(arg0)[arg1 >>> 0] = takeObject(arg2);
563
445
  }
564
446
  export function __wbg_set_6be42768c690e380(arg0, arg1, arg2) {
565
447
  getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
566
448
  }
567
- export function __wbg_set_6c60b2e8ad0e9383(arg0, arg1, arg2) {
568
- getObject(arg0)[arg1 >>> 0] = takeObject(arg2);
569
- }
570
449
  export function __wbg_set_f071dbb3bd088e0e(arg0, arg1, arg2) {
571
450
  getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
572
451
  }
452
+ export function __wbg_set_fde2cec06c23692b(arg0, arg1, arg2) {
453
+ const ret = getObject(arg0).set(getObject(arg1), getObject(arg2));
454
+ return addHeapObject(ret);
455
+ }
573
456
  export function __wbg_stack_3b0d974bbf31e44f(arg0, arg1) {
574
457
  const ret = getObject(arg1).stack;
575
458
  const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
@@ -577,11 +460,7 @@ export function __wbg_stack_3b0d974bbf31e44f(arg0, arg1) {
577
460
  getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
578
461
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
579
462
  }
580
- export function __wbg_stringify_a2c39d991e1bf91d() { return handleError(function (arg0) {
581
- const ret = JSON.stringify(getObject(arg0));
582
- return addHeapObject(ret);
583
- }, arguments); }
584
- export function __wbg_value_7f6052747ccf940f(arg0) {
463
+ export function __wbg_value_ee3a06f4579184fa(arg0) {
585
464
  const ret = getObject(arg0).value;
586
465
  return addHeapObject(ret);
587
466
  }
@@ -612,12 +491,18 @@ export function __wbindgen_object_clone_ref(arg0) {
612
491
  export function __wbindgen_object_drop_ref(arg0) {
613
492
  takeObject(arg0);
614
493
  }
615
- const CompiledDocumentFinalization = (typeof FinalizationRegistry === 'undefined')
494
+ const ParsedDocumentFinalization = (typeof FinalizationRegistry === 'undefined')
495
+ ? { register: () => {}, unregister: () => {} }
496
+ : new FinalizationRegistry(ptr => wasm.__wbg_parseddocument_free(ptr >>> 0, 1));
497
+ const QuillFinalization = (typeof FinalizationRegistry === 'undefined')
616
498
  ? { register: () => {}, unregister: () => {} }
617
- : new FinalizationRegistry(ptr => wasm.__wbg_compileddocument_free(ptr >>> 0, 1));
499
+ : new FinalizationRegistry(ptr => wasm.__wbg_quill_free(ptr >>> 0, 1));
618
500
  const QuillmarkFinalization = (typeof FinalizationRegistry === 'undefined')
619
501
  ? { register: () => {}, unregister: () => {} }
620
502
  : new FinalizationRegistry(ptr => wasm.__wbg_quillmark_free(ptr >>> 0, 1));
503
+ const RenderSessionFinalization = (typeof FinalizationRegistry === 'undefined')
504
+ ? { register: () => {}, unregister: () => {} }
505
+ : new FinalizationRegistry(ptr => wasm.__wbg_rendersession_free(ptr >>> 0, 1));
621
506
 
622
507
  function addHeapObject(obj) {
623
508
  if (heap_next === heap.length) heap.push(heap.length + 1);
@@ -699,16 +584,6 @@ function dropObject(idx) {
699
584
  heap_next = idx;
700
585
  }
701
586
 
702
- function getArrayJsValueFromWasm0(ptr, len) {
703
- ptr = ptr >>> 0;
704
- const mem = getDataViewMemory0();
705
- const result = [];
706
- for (let i = ptr; i < ptr + 4 * len; i += 4) {
707
- result.push(takeObject(mem.getUint32(i, true)));
708
- }
709
- return result;
710
- }
711
-
712
587
  function getArrayU8FromWasm0(ptr, len) {
713
588
  ptr = ptr >>> 0;
714
589
  return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
@@ -727,14 +602,6 @@ function getStringFromWasm0(ptr, len) {
727
602
  return decodeText(ptr, len);
728
603
  }
729
604
 
730
- let cachedUint32ArrayMemory0 = null;
731
- function getUint32ArrayMemory0() {
732
- if (cachedUint32ArrayMemory0 === null || cachedUint32ArrayMemory0.byteLength === 0) {
733
- cachedUint32ArrayMemory0 = new Uint32Array(wasm.memory.buffer);
734
- }
735
- return cachedUint32ArrayMemory0;
736
- }
737
-
738
605
  let cachedUint8ArrayMemory0 = null;
739
606
  function getUint8ArrayMemory0() {
740
607
  if (cachedUint8ArrayMemory0 === null || cachedUint8ArrayMemory0.byteLength === 0) {
@@ -762,13 +629,6 @@ function isLikeNone(x) {
762
629
  return x === undefined || x === null;
763
630
  }
764
631
 
765
- function passArray32ToWasm0(arg, malloc) {
766
- const ptr = malloc(arg.length * 4, 4) >>> 0;
767
- getUint32ArrayMemory0().set(arg, ptr / 4);
768
- WASM_VECTOR_LEN = arg.length;
769
- return ptr;
770
- }
771
-
772
632
  function passStringToWasm0(arg, malloc, realloc) {
773
633
  if (realloc === undefined) {
774
634
  const buf = cachedTextEncoder.encode(arg);