@takumi-rs/wasm 1.0.0-rc.9 → 1.0.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.
package/dist/export.cjs CHANGED
@@ -2,6 +2,7 @@ Object.defineProperties(exports, {
2
2
  __esModule: { value: true },
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
+ let _takumi_rs_helpers = require("@takumi-rs/helpers");
5
6
  //#region pkg/takumi_wasm.js
6
7
  /**
7
8
  * The main renderer for Takumi image rendering engine.
@@ -130,25 +131,13 @@ var Renderer$1 = class {
130
131
  }
131
132
  };
132
133
  if (Symbol.dispose) Renderer$1.prototype[Symbol.dispose] = Renderer$1.prototype.free;
133
- /**
134
- * Collects the fetch task urls from the node.
135
- * @param {Node} node
136
- * @returns {string[]}
137
- */
138
- function extractResourceUrls(node) {
139
- const ret = wasm.extractResourceUrls(node);
140
- if (ret[3]) throw takeFromExternrefTable0(ret[2]);
141
- var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
142
- wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
143
- return v1;
144
- }
145
134
  function __wbg_get_imports() {
146
135
  const import0 = {
147
136
  __proto__: null,
148
- __wbg_Error_55538483de6e3abe: function(arg0, arg1) {
137
+ __wbg_Error_2e59b1b37a9a34c3: function(arg0, arg1) {
149
138
  return Error(getStringFromWasm0(arg0, arg1));
150
139
  },
151
- __wbg_Number_f257194b7002d6f9: function(arg0) {
140
+ __wbg_Number_e6ffdb596c888833: function(arg0) {
152
141
  return Number(arg0);
153
142
  },
154
143
  __wbg_String_8564e559799eccda: function(arg0, arg1) {
@@ -157,55 +146,55 @@ function __wbg_get_imports() {
157
146
  getDataViewMemory0().setInt32(arg0 + 4, len1, true);
158
147
  getDataViewMemory0().setInt32(arg0 + 0, ptr1, true);
159
148
  },
160
- __wbg___wbindgen_bigint_get_as_i64_a738e80c0fe6f6a7: function(arg0, arg1) {
149
+ __wbg___wbindgen_bigint_get_as_i64_2c5082002e4826e2: function(arg0, arg1) {
161
150
  const v = arg1;
162
151
  const ret = typeof v === "bigint" ? v : void 0;
163
152
  getDataViewMemory0().setBigInt64(arg0 + 8, isLikeNone(ret) ? BigInt(0) : ret, true);
164
153
  getDataViewMemory0().setInt32(arg0 + 0, !isLikeNone(ret), true);
165
154
  },
166
- __wbg___wbindgen_boolean_get_fe2a24fdfdb4064f: function(arg0) {
155
+ __wbg___wbindgen_boolean_get_a86c216575a75c30: function(arg0) {
167
156
  const v = arg0;
168
157
  const ret = typeof v === "boolean" ? v : void 0;
169
158
  return isLikeNone(ret) ? 16777215 : ret ? 1 : 0;
170
159
  },
171
- __wbg___wbindgen_debug_string_d89627202d0155b7: function(arg0, arg1) {
160
+ __wbg___wbindgen_debug_string_dd5d2d07ce9e6c57: function(arg0, arg1) {
172
161
  const ptr1 = passStringToWasm0(debugString(arg1), wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
173
162
  const len1 = WASM_VECTOR_LEN;
174
163
  getDataViewMemory0().setInt32(arg0 + 4, len1, true);
175
164
  getDataViewMemory0().setInt32(arg0 + 0, ptr1, true);
176
165
  },
177
- __wbg___wbindgen_in_fe3eb6a509f75744: function(arg0, arg1) {
166
+ __wbg___wbindgen_in_4bd7a57e54337366: function(arg0, arg1) {
178
167
  return arg0 in arg1;
179
168
  },
180
- __wbg___wbindgen_is_bigint_ca270ac12ef71091: function(arg0) {
169
+ __wbg___wbindgen_is_bigint_6c98f7e945dacdde: function(arg0) {
181
170
  return typeof arg0 === "bigint";
182
171
  },
183
- __wbg___wbindgen_is_function_2a95406423ea8626: function(arg0) {
172
+ __wbg___wbindgen_is_function_49868bde5eb1e745: function(arg0) {
184
173
  return typeof arg0 === "function";
185
174
  },
186
- __wbg___wbindgen_is_object_59a002e76b059312: function(arg0) {
175
+ __wbg___wbindgen_is_object_40c5a80572e8f9d3: function(arg0) {
187
176
  const val = arg0;
188
177
  return typeof val === "object" && val !== null;
189
178
  },
190
- __wbg___wbindgen_is_string_624d5244bb2bc87c: function(arg0) {
179
+ __wbg___wbindgen_is_string_b29b5c5a8065ba1a: function(arg0) {
191
180
  return typeof arg0 === "string";
192
181
  },
193
- __wbg___wbindgen_is_undefined_87a3a837f331fef5: function(arg0) {
182
+ __wbg___wbindgen_is_undefined_c0cca72b82b86f4d: function(arg0) {
194
183
  return arg0 === void 0;
195
184
  },
196
- __wbg___wbindgen_jsval_eq_eedd705f9f2a4f35: function(arg0, arg1) {
185
+ __wbg___wbindgen_jsval_eq_7d430e744a913d26: function(arg0, arg1) {
197
186
  return arg0 === arg1;
198
187
  },
199
- __wbg___wbindgen_jsval_loose_eq_cf851f110c48f9ba: function(arg0, arg1) {
188
+ __wbg___wbindgen_jsval_loose_eq_3a72ae764d46d944: function(arg0, arg1) {
200
189
  return arg0 == arg1;
201
190
  },
202
- __wbg___wbindgen_number_get_769f3676dc20c1d7: function(arg0, arg1) {
191
+ __wbg___wbindgen_number_get_7579aab02a8a620c: function(arg0, arg1) {
203
192
  const obj = arg1;
204
193
  const ret = typeof obj === "number" ? obj : void 0;
205
194
  getDataViewMemory0().setFloat64(arg0 + 8, isLikeNone(ret) ? 0 : ret, true);
206
195
  getDataViewMemory0().setInt32(arg0 + 0, !isLikeNone(ret), true);
207
196
  },
208
- __wbg___wbindgen_string_get_f1161390414f9b59: function(arg0, arg1) {
197
+ __wbg___wbindgen_string_get_914df97fcfa788f2: function(arg0, arg1) {
209
198
  const obj = arg1;
210
199
  const ret = typeof obj === "string" ? obj : void 0;
211
200
  var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
@@ -213,35 +202,35 @@ function __wbg_get_imports() {
213
202
  getDataViewMemory0().setInt32(arg0 + 4, len1, true);
214
203
  getDataViewMemory0().setInt32(arg0 + 0, ptr1, true);
215
204
  },
216
- __wbg___wbindgen_throw_5549492daedad139: function(arg0, arg1) {
205
+ __wbg___wbindgen_throw_81fc77679af83bc6: function(arg0, arg1) {
217
206
  throw new Error(getStringFromWasm0(arg0, arg1));
218
207
  },
219
- __wbg_call_6ae20895a60069a2: function() {
208
+ __wbg_call_7f2987183bb62793: function() {
220
209
  return handleError(function(arg0, arg1) {
221
210
  return arg0.call(arg1);
222
211
  }, arguments);
223
212
  },
224
- __wbg_done_19f92cb1f8738aba: function(arg0) {
213
+ __wbg_done_547d467e97529006: function(arg0) {
225
214
  return arg0.done;
226
215
  },
227
- __wbg_entries_28ed7cb892e12eff: function(arg0) {
216
+ __wbg_entries_616b1a459b85be0b: function(arg0) {
228
217
  return Object.entries(arg0);
229
218
  },
230
- __wbg_get_94f5fc088edd3138: function(arg0, arg1) {
219
+ __wbg_get_4848e350b40afc16: function(arg0, arg1) {
231
220
  return arg0[arg1 >>> 0];
232
221
  },
233
- __wbg_get_a50328e7325d7f9b: function() {
222
+ __wbg_get_ed0642c4b9d31ddf: function() {
234
223
  return handleError(function(arg0, arg1) {
235
224
  return Reflect.get(arg0, arg1);
236
225
  }, arguments);
237
226
  },
238
- __wbg_get_unchecked_7c6bbabf5b0b1fbf: function(arg0, arg1) {
227
+ __wbg_get_unchecked_7d7babe32e9e6a54: function(arg0, arg1) {
239
228
  return arg0[arg1 >>> 0];
240
229
  },
241
230
  __wbg_get_with_ref_key_6412cf3094599694: function(arg0, arg1) {
242
231
  return arg0[arg1];
243
232
  },
244
- __wbg_instanceof_ArrayBuffer_8d855993947fc3a2: function(arg0) {
233
+ __wbg_instanceof_ArrayBuffer_ff7c1337a5e3b33a: function(arg0) {
245
234
  let result;
246
235
  try {
247
236
  result = arg0 instanceof ArrayBuffer;
@@ -250,7 +239,7 @@ function __wbg_get_imports() {
250
239
  }
251
240
  return result;
252
241
  },
253
- __wbg_instanceof_Map_238410f1463c05ed: function(arg0) {
242
+ __wbg_instanceof_Map_a10a2795ef4bfe97: function(arg0) {
254
243
  let result;
255
244
  try {
256
245
  result = arg0 instanceof Map;
@@ -259,7 +248,7 @@ function __wbg_get_imports() {
259
248
  }
260
249
  return result;
261
250
  },
262
- __wbg_instanceof_Uint8Array_ce24d58a5f4bdcc3: function(arg0) {
251
+ __wbg_instanceof_Uint8Array_4b8da683deb25d72: function(arg0) {
263
252
  let result;
264
253
  try {
265
254
  result = arg0 instanceof Uint8Array;
@@ -268,51 +257,51 @@ function __wbg_get_imports() {
268
257
  }
269
258
  return result;
270
259
  },
271
- __wbg_isArray_867202cf8f195ed8: function(arg0) {
260
+ __wbg_isArray_db61795ad004c139: function(arg0) {
272
261
  return Array.isArray(arg0);
273
262
  },
274
- __wbg_isSafeInteger_1dfae065cbfe1915: function(arg0) {
263
+ __wbg_isSafeInteger_ea83862ba994770c: function(arg0) {
275
264
  return Number.isSafeInteger(arg0);
276
265
  },
277
- __wbg_iterator_54661826e186eb6a: function() {
266
+ __wbg_iterator_de403ef31815a3e6: function() {
278
267
  return Symbol.iterator;
279
268
  },
280
- __wbg_length_e6e1633fbea6cfa9: function(arg0) {
269
+ __wbg_length_0c32cb8543c8e4c8: function(arg0) {
281
270
  return arg0.length;
282
271
  },
283
- __wbg_length_fae3e439140f48a4: function(arg0) {
272
+ __wbg_length_6e821edde497a532: function(arg0) {
284
273
  return arg0.length;
285
274
  },
286
- __wbg_new_1d96678aaacca32e: function(arg0) {
287
- return new Uint8Array(arg0);
288
- },
289
- __wbg_new_4370be21fa2b2f80: function() {
290
- return new Array();
291
- },
292
- __wbg_new_48e1d86cfd30c8e7: function() {
275
+ __wbg_new_4f9fafbb3909af72: function() {
293
276
  return /* @__PURE__ */ new Object();
294
277
  },
295
- __wbg_new_4a843fe2ee4082a9: function(arg0, arg1) {
278
+ __wbg_new_a560378ea1240b14: function(arg0) {
279
+ return new Uint8Array(arg0);
280
+ },
281
+ __wbg_new_e3b04b4d53d1b593: function(arg0, arg1) {
296
282
  return new Error(getStringFromWasm0(arg0, arg1));
297
283
  },
298
- __wbg_next_55d835fe0ab5b3e7: function(arg0) {
284
+ __wbg_new_f3c9df4f38f3f798: function() {
285
+ return new Array();
286
+ },
287
+ __wbg_next_01132ed6134b8ef5: function(arg0) {
299
288
  return arg0.next;
300
289
  },
301
- __wbg_next_e34cfb9df1518d7c: function() {
290
+ __wbg_next_b3713ec761a9dbfd: function() {
302
291
  return handleError(function(arg0) {
303
292
  return arg0.next();
304
293
  }, arguments);
305
294
  },
306
- __wbg_prototypesetcall_3875d54d12ef2eec: function(arg0, arg1, arg2) {
295
+ __wbg_prototypesetcall_3e05eb9545565046: function(arg0, arg1, arg2) {
307
296
  Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), arg2);
308
297
  },
309
- __wbg_set_4702dfa37c77f492: function(arg0, arg1, arg2) {
310
- arg0[arg1 >>> 0] = arg2;
311
- },
312
298
  __wbg_set_6be42768c690e380: function(arg0, arg1, arg2) {
313
299
  arg0[arg1] = arg2;
314
300
  },
315
- __wbg_value_d5b248ce8419bd1b: function(arg0) {
301
+ __wbg_set_6c60b2e8ad0e9383: function(arg0, arg1, arg2) {
302
+ arg0[arg1 >>> 0] = arg2;
303
+ },
304
+ __wbg_value_7f6052747ccf940f: function(arg0) {
316
305
  return arg0.value;
317
306
  },
318
307
  __wbindgen_cast_0000000000000001: function(arg0) {
@@ -656,5 +645,10 @@ function isBuffer(data) {
656
645
  //#endregion
657
646
  exports.Renderer = Renderer;
658
647
  exports.default = __wbg_init;
659
- exports.extractResourceUrls = extractResourceUrls;
648
+ Object.defineProperty(exports, "extractResourceUrls", {
649
+ enumerable: true,
650
+ get: function() {
651
+ return _takumi_rs_helpers.extractResourceUrls;
652
+ }
653
+ });
660
654
  exports.initSync = initSync;
package/dist/export.d.cts CHANGED
@@ -1,4 +1,4 @@
1
- import { ContainerNode, ImageNode, Node, Node as Node$1, NodeMetadata, TextNode } from "@takumi-rs/helpers";
1
+ import { ContainerNode, ImageNode, Node, Node as Node$1, NodeMetadata, TextNode, extractResourceUrls } from "@takumi-rs/helpers";
2
2
  import { Properties } from "csstype";
3
3
 
4
4
  //#region pkg/takumi_wasm.d.ts
@@ -25,7 +25,7 @@ type RenderOptions = {
25
25
  * The format of the image.
26
26
  * @default "png"
27
27
  */
28
- format?: "png" | "jpeg" | "webp" | "raw";
28
+ format?: "png" | "jpeg" | "webp" | "ico" | "raw";
29
29
  /**
30
30
  * The quality of JPEG format (0-100).
31
31
  */
@@ -213,15 +213,10 @@ declare class Renderer$1 {
213
213
  */
214
214
  renderAsDataUrl(node: Node$1, options: RenderOptions): string;
215
215
  }
216
- /**
217
- * Collects the fetch task urls from the node.
218
- */
219
- declare function extractResourceUrls(node: Node$1): string[];
220
216
  type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;
221
217
  interface InitOutput {
222
218
  readonly memory: WebAssembly.Memory;
223
219
  readonly __wbg_renderer_free: (a: number, b: number) => void;
224
- readonly extractResourceUrls: (a: any) => [number, number, number, number];
225
220
  readonly renderer_clearImageStore: (a: number) => void;
226
221
  readonly renderer_encodeFrames: (a: number, b: number, c: number, d: any) => [number, number, number, number];
227
222
  readonly renderer_loadFont: (a: number, b: any) => [number, number];
@@ -271,14 +266,14 @@ type ImageSourceLoader = Omit<ImageSource, "data"> & {
271
266
  };
272
267
  type FontLoader = Font | (Omit<FontDetails, "data"> & {
273
268
  key?: string;
274
- data: () => Promise<FontDetails["data"]> | FontDetails["data"];
269
+ data: FontDetails["data"] | (() => Promise<FontDetails["data"]> | FontDetails["data"]);
275
270
  });
276
271
  type ImageSourceLoaderSync = Omit<ImageSource, "data"> & {
277
272
  data: ImageSource["data"] | (() => ImageSource["data"]);
278
273
  };
279
274
  type FontLoaderSync = Font | (Omit<FontDetails, "data"> & {
280
275
  key?: string;
281
- data: () => FontDetails["data"];
276
+ data: FontDetails["data"] | (() => FontDetails["data"]);
282
277
  });
283
278
  declare class Renderer extends Renderer$1 {
284
279
  private fontsMark;
package/dist/export.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- import { ContainerNode, ImageNode, Node, Node as Node$1, NodeMetadata, TextNode } from "@takumi-rs/helpers";
1
+ import { ContainerNode, ImageNode, Node, Node as Node$1, NodeMetadata, TextNode, extractResourceUrls } from "@takumi-rs/helpers";
2
2
  import { Properties } from "csstype";
3
3
 
4
4
  //#region pkg/takumi_wasm.d.ts
@@ -25,7 +25,7 @@ type RenderOptions = {
25
25
  * The format of the image.
26
26
  * @default "png"
27
27
  */
28
- format?: "png" | "jpeg" | "webp" | "raw";
28
+ format?: "png" | "jpeg" | "webp" | "ico" | "raw";
29
29
  /**
30
30
  * The quality of JPEG format (0-100).
31
31
  */
@@ -213,15 +213,10 @@ declare class Renderer$1 {
213
213
  */
214
214
  renderAsDataUrl(node: Node$1, options: RenderOptions): string;
215
215
  }
216
- /**
217
- * Collects the fetch task urls from the node.
218
- */
219
- declare function extractResourceUrls(node: Node$1): string[];
220
216
  type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;
221
217
  interface InitOutput {
222
218
  readonly memory: WebAssembly.Memory;
223
219
  readonly __wbg_renderer_free: (a: number, b: number) => void;
224
- readonly extractResourceUrls: (a: any) => [number, number, number, number];
225
220
  readonly renderer_clearImageStore: (a: number) => void;
226
221
  readonly renderer_encodeFrames: (a: number, b: number, c: number, d: any) => [number, number, number, number];
227
222
  readonly renderer_loadFont: (a: number, b: any) => [number, number];
@@ -271,14 +266,14 @@ type ImageSourceLoader = Omit<ImageSource, "data"> & {
271
266
  };
272
267
  type FontLoader = Font | (Omit<FontDetails, "data"> & {
273
268
  key?: string;
274
- data: () => Promise<FontDetails["data"]> | FontDetails["data"];
269
+ data: FontDetails["data"] | (() => Promise<FontDetails["data"]> | FontDetails["data"]);
275
270
  });
276
271
  type ImageSourceLoaderSync = Omit<ImageSource, "data"> & {
277
272
  data: ImageSource["data"] | (() => ImageSource["data"]);
278
273
  };
279
274
  type FontLoaderSync = Font | (Omit<FontDetails, "data"> & {
280
275
  key?: string;
281
- data: () => FontDetails["data"];
276
+ data: FontDetails["data"] | (() => FontDetails["data"]);
282
277
  });
283
278
  declare class Renderer extends Renderer$1 {
284
279
  private fontsMark;
package/dist/export.mjs CHANGED
@@ -1,3 +1,4 @@
1
+ import { extractResourceUrls } from "@takumi-rs/helpers";
1
2
  //#region pkg/takumi_wasm.js
2
3
  /**
3
4
  * The main renderer for Takumi image rendering engine.
@@ -126,25 +127,13 @@ var Renderer$1 = class {
126
127
  }
127
128
  };
128
129
  if (Symbol.dispose) Renderer$1.prototype[Symbol.dispose] = Renderer$1.prototype.free;
129
- /**
130
- * Collects the fetch task urls from the node.
131
- * @param {Node} node
132
- * @returns {string[]}
133
- */
134
- function extractResourceUrls(node) {
135
- const ret = wasm.extractResourceUrls(node);
136
- if (ret[3]) throw takeFromExternrefTable0(ret[2]);
137
- var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
138
- wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
139
- return v1;
140
- }
141
130
  function __wbg_get_imports() {
142
131
  const import0 = {
143
132
  __proto__: null,
144
- __wbg_Error_55538483de6e3abe: function(arg0, arg1) {
133
+ __wbg_Error_2e59b1b37a9a34c3: function(arg0, arg1) {
145
134
  return Error(getStringFromWasm0(arg0, arg1));
146
135
  },
147
- __wbg_Number_f257194b7002d6f9: function(arg0) {
136
+ __wbg_Number_e6ffdb596c888833: function(arg0) {
148
137
  return Number(arg0);
149
138
  },
150
139
  __wbg_String_8564e559799eccda: function(arg0, arg1) {
@@ -153,55 +142,55 @@ function __wbg_get_imports() {
153
142
  getDataViewMemory0().setInt32(arg0 + 4, len1, true);
154
143
  getDataViewMemory0().setInt32(arg0 + 0, ptr1, true);
155
144
  },
156
- __wbg___wbindgen_bigint_get_as_i64_a738e80c0fe6f6a7: function(arg0, arg1) {
145
+ __wbg___wbindgen_bigint_get_as_i64_2c5082002e4826e2: function(arg0, arg1) {
157
146
  const v = arg1;
158
147
  const ret = typeof v === "bigint" ? v : void 0;
159
148
  getDataViewMemory0().setBigInt64(arg0 + 8, isLikeNone(ret) ? BigInt(0) : ret, true);
160
149
  getDataViewMemory0().setInt32(arg0 + 0, !isLikeNone(ret), true);
161
150
  },
162
- __wbg___wbindgen_boolean_get_fe2a24fdfdb4064f: function(arg0) {
151
+ __wbg___wbindgen_boolean_get_a86c216575a75c30: function(arg0) {
163
152
  const v = arg0;
164
153
  const ret = typeof v === "boolean" ? v : void 0;
165
154
  return isLikeNone(ret) ? 16777215 : ret ? 1 : 0;
166
155
  },
167
- __wbg___wbindgen_debug_string_d89627202d0155b7: function(arg0, arg1) {
156
+ __wbg___wbindgen_debug_string_dd5d2d07ce9e6c57: function(arg0, arg1) {
168
157
  const ptr1 = passStringToWasm0(debugString(arg1), wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
169
158
  const len1 = WASM_VECTOR_LEN;
170
159
  getDataViewMemory0().setInt32(arg0 + 4, len1, true);
171
160
  getDataViewMemory0().setInt32(arg0 + 0, ptr1, true);
172
161
  },
173
- __wbg___wbindgen_in_fe3eb6a509f75744: function(arg0, arg1) {
162
+ __wbg___wbindgen_in_4bd7a57e54337366: function(arg0, arg1) {
174
163
  return arg0 in arg1;
175
164
  },
176
- __wbg___wbindgen_is_bigint_ca270ac12ef71091: function(arg0) {
165
+ __wbg___wbindgen_is_bigint_6c98f7e945dacdde: function(arg0) {
177
166
  return typeof arg0 === "bigint";
178
167
  },
179
- __wbg___wbindgen_is_function_2a95406423ea8626: function(arg0) {
168
+ __wbg___wbindgen_is_function_49868bde5eb1e745: function(arg0) {
180
169
  return typeof arg0 === "function";
181
170
  },
182
- __wbg___wbindgen_is_object_59a002e76b059312: function(arg0) {
171
+ __wbg___wbindgen_is_object_40c5a80572e8f9d3: function(arg0) {
183
172
  const val = arg0;
184
173
  return typeof val === "object" && val !== null;
185
174
  },
186
- __wbg___wbindgen_is_string_624d5244bb2bc87c: function(arg0) {
175
+ __wbg___wbindgen_is_string_b29b5c5a8065ba1a: function(arg0) {
187
176
  return typeof arg0 === "string";
188
177
  },
189
- __wbg___wbindgen_is_undefined_87a3a837f331fef5: function(arg0) {
178
+ __wbg___wbindgen_is_undefined_c0cca72b82b86f4d: function(arg0) {
190
179
  return arg0 === void 0;
191
180
  },
192
- __wbg___wbindgen_jsval_eq_eedd705f9f2a4f35: function(arg0, arg1) {
181
+ __wbg___wbindgen_jsval_eq_7d430e744a913d26: function(arg0, arg1) {
193
182
  return arg0 === arg1;
194
183
  },
195
- __wbg___wbindgen_jsval_loose_eq_cf851f110c48f9ba: function(arg0, arg1) {
184
+ __wbg___wbindgen_jsval_loose_eq_3a72ae764d46d944: function(arg0, arg1) {
196
185
  return arg0 == arg1;
197
186
  },
198
- __wbg___wbindgen_number_get_769f3676dc20c1d7: function(arg0, arg1) {
187
+ __wbg___wbindgen_number_get_7579aab02a8a620c: function(arg0, arg1) {
199
188
  const obj = arg1;
200
189
  const ret = typeof obj === "number" ? obj : void 0;
201
190
  getDataViewMemory0().setFloat64(arg0 + 8, isLikeNone(ret) ? 0 : ret, true);
202
191
  getDataViewMemory0().setInt32(arg0 + 0, !isLikeNone(ret), true);
203
192
  },
204
- __wbg___wbindgen_string_get_f1161390414f9b59: function(arg0, arg1) {
193
+ __wbg___wbindgen_string_get_914df97fcfa788f2: function(arg0, arg1) {
205
194
  const obj = arg1;
206
195
  const ret = typeof obj === "string" ? obj : void 0;
207
196
  var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
@@ -209,35 +198,35 @@ function __wbg_get_imports() {
209
198
  getDataViewMemory0().setInt32(arg0 + 4, len1, true);
210
199
  getDataViewMemory0().setInt32(arg0 + 0, ptr1, true);
211
200
  },
212
- __wbg___wbindgen_throw_5549492daedad139: function(arg0, arg1) {
201
+ __wbg___wbindgen_throw_81fc77679af83bc6: function(arg0, arg1) {
213
202
  throw new Error(getStringFromWasm0(arg0, arg1));
214
203
  },
215
- __wbg_call_6ae20895a60069a2: function() {
204
+ __wbg_call_7f2987183bb62793: function() {
216
205
  return handleError(function(arg0, arg1) {
217
206
  return arg0.call(arg1);
218
207
  }, arguments);
219
208
  },
220
- __wbg_done_19f92cb1f8738aba: function(arg0) {
209
+ __wbg_done_547d467e97529006: function(arg0) {
221
210
  return arg0.done;
222
211
  },
223
- __wbg_entries_28ed7cb892e12eff: function(arg0) {
212
+ __wbg_entries_616b1a459b85be0b: function(arg0) {
224
213
  return Object.entries(arg0);
225
214
  },
226
- __wbg_get_94f5fc088edd3138: function(arg0, arg1) {
215
+ __wbg_get_4848e350b40afc16: function(arg0, arg1) {
227
216
  return arg0[arg1 >>> 0];
228
217
  },
229
- __wbg_get_a50328e7325d7f9b: function() {
218
+ __wbg_get_ed0642c4b9d31ddf: function() {
230
219
  return handleError(function(arg0, arg1) {
231
220
  return Reflect.get(arg0, arg1);
232
221
  }, arguments);
233
222
  },
234
- __wbg_get_unchecked_7c6bbabf5b0b1fbf: function(arg0, arg1) {
223
+ __wbg_get_unchecked_7d7babe32e9e6a54: function(arg0, arg1) {
235
224
  return arg0[arg1 >>> 0];
236
225
  },
237
226
  __wbg_get_with_ref_key_6412cf3094599694: function(arg0, arg1) {
238
227
  return arg0[arg1];
239
228
  },
240
- __wbg_instanceof_ArrayBuffer_8d855993947fc3a2: function(arg0) {
229
+ __wbg_instanceof_ArrayBuffer_ff7c1337a5e3b33a: function(arg0) {
241
230
  let result;
242
231
  try {
243
232
  result = arg0 instanceof ArrayBuffer;
@@ -246,7 +235,7 @@ function __wbg_get_imports() {
246
235
  }
247
236
  return result;
248
237
  },
249
- __wbg_instanceof_Map_238410f1463c05ed: function(arg0) {
238
+ __wbg_instanceof_Map_a10a2795ef4bfe97: function(arg0) {
250
239
  let result;
251
240
  try {
252
241
  result = arg0 instanceof Map;
@@ -255,7 +244,7 @@ function __wbg_get_imports() {
255
244
  }
256
245
  return result;
257
246
  },
258
- __wbg_instanceof_Uint8Array_ce24d58a5f4bdcc3: function(arg0) {
247
+ __wbg_instanceof_Uint8Array_4b8da683deb25d72: function(arg0) {
259
248
  let result;
260
249
  try {
261
250
  result = arg0 instanceof Uint8Array;
@@ -264,51 +253,51 @@ function __wbg_get_imports() {
264
253
  }
265
254
  return result;
266
255
  },
267
- __wbg_isArray_867202cf8f195ed8: function(arg0) {
256
+ __wbg_isArray_db61795ad004c139: function(arg0) {
268
257
  return Array.isArray(arg0);
269
258
  },
270
- __wbg_isSafeInteger_1dfae065cbfe1915: function(arg0) {
259
+ __wbg_isSafeInteger_ea83862ba994770c: function(arg0) {
271
260
  return Number.isSafeInteger(arg0);
272
261
  },
273
- __wbg_iterator_54661826e186eb6a: function() {
262
+ __wbg_iterator_de403ef31815a3e6: function() {
274
263
  return Symbol.iterator;
275
264
  },
276
- __wbg_length_e6e1633fbea6cfa9: function(arg0) {
265
+ __wbg_length_0c32cb8543c8e4c8: function(arg0) {
277
266
  return arg0.length;
278
267
  },
279
- __wbg_length_fae3e439140f48a4: function(arg0) {
268
+ __wbg_length_6e821edde497a532: function(arg0) {
280
269
  return arg0.length;
281
270
  },
282
- __wbg_new_1d96678aaacca32e: function(arg0) {
283
- return new Uint8Array(arg0);
284
- },
285
- __wbg_new_4370be21fa2b2f80: function() {
286
- return new Array();
287
- },
288
- __wbg_new_48e1d86cfd30c8e7: function() {
271
+ __wbg_new_4f9fafbb3909af72: function() {
289
272
  return /* @__PURE__ */ new Object();
290
273
  },
291
- __wbg_new_4a843fe2ee4082a9: function(arg0, arg1) {
274
+ __wbg_new_a560378ea1240b14: function(arg0) {
275
+ return new Uint8Array(arg0);
276
+ },
277
+ __wbg_new_e3b04b4d53d1b593: function(arg0, arg1) {
292
278
  return new Error(getStringFromWasm0(arg0, arg1));
293
279
  },
294
- __wbg_next_55d835fe0ab5b3e7: function(arg0) {
280
+ __wbg_new_f3c9df4f38f3f798: function() {
281
+ return new Array();
282
+ },
283
+ __wbg_next_01132ed6134b8ef5: function(arg0) {
295
284
  return arg0.next;
296
285
  },
297
- __wbg_next_e34cfb9df1518d7c: function() {
286
+ __wbg_next_b3713ec761a9dbfd: function() {
298
287
  return handleError(function(arg0) {
299
288
  return arg0.next();
300
289
  }, arguments);
301
290
  },
302
- __wbg_prototypesetcall_3875d54d12ef2eec: function(arg0, arg1, arg2) {
291
+ __wbg_prototypesetcall_3e05eb9545565046: function(arg0, arg1, arg2) {
303
292
  Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), arg2);
304
293
  },
305
- __wbg_set_4702dfa37c77f492: function(arg0, arg1, arg2) {
306
- arg0[arg1 >>> 0] = arg2;
307
- },
308
294
  __wbg_set_6be42768c690e380: function(arg0, arg1, arg2) {
309
295
  arg0[arg1] = arg2;
310
296
  },
311
- __wbg_value_d5b248ce8419bd1b: function(arg0) {
297
+ __wbg_set_6c60b2e8ad0e9383: function(arg0, arg1, arg2) {
298
+ arg0[arg1 >>> 0] = arg2;
299
+ },
300
+ __wbg_value_7f6052747ccf940f: function(arg0) {
312
301
  return arg0.value;
313
302
  },
314
303
  __wbindgen_cast_0000000000000001: function(arg0) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@takumi-rs/wasm",
3
- "version": "1.0.0-rc.9",
3
+ "version": "1.0.0",
4
4
  "keywords": [
5
5
  "css",
6
6
  "image",
@@ -24,6 +24,7 @@
24
24
  "dist",
25
25
  "bundlers"
26
26
  ],
27
+ "type": "module",
27
28
  "main": "./dist/export.cjs",
28
29
  "module": "./dist/export.mjs",
29
30
  "types": "./dist/export.d.mts",
@@ -75,7 +76,7 @@
75
76
  "prepublishOnly": "jq '.dependencies[\"@takumi-rs/helpers\"] = .version' package.json > tmp.json && mv tmp.json package.json"
76
77
  },
77
78
  "dependencies": {
78
- "@takumi-rs/helpers": "1.0.0-rc.9"
79
+ "@takumi-rs/helpers": "1.0.0"
79
80
  },
80
81
  "devDependencies": {
81
82
  "@types/bun": "catalog:",
Binary file
@@ -2,7 +2,6 @@
2
2
  /* eslint-disable */
3
3
  export const memory: WebAssembly.Memory;
4
4
  export const __wbg_renderer_free: (a: number, b: number) => void;
5
- export const extractResourceUrls: (a: any) => [number, number, number, number];
6
5
  export const renderer_clearImageStore: (a: number) => void;
7
6
  export const renderer_encodeFrames: (a: number, b: number, c: number, d: any) => [number, number, number, number];
8
7
  export const renderer_loadFont: (a: number, b: any) => [number, number];