barcode-detector 3.0.5 → 3.0.7

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,9 +1,9 @@
1
- var Ie = (o) => {
1
+ var Ue = (o) => {
2
2
  throw TypeError(o);
3
3
  };
4
- var Me = (o, l, h) => l.has(o) || Ie("Cannot " + h);
5
- var Fe = (o, l, h) => (Me(o, l, "read from private field"), h ? h.call(o) : l.get(o)), je = (o, l, h) => l.has(o) ? Ie("Cannot add the same private member more than once") : l instanceof WeakSet ? l.add(o) : l.set(o, h), Re = (o, l, h, f) => (Me(o, l, "write to private field"), f ? f.call(o, h) : l.set(o, h), h);
6
- const Ft = [
4
+ var Ve = (o, l, h) => l.has(o) || Ue("Cannot " + h);
5
+ var We = (o, l, h) => (Ve(o, l, "read from private field"), h ? h.call(o) : l.get(o)), He = (o, l, h) => l.has(o) ? Ue("Cannot add the same private member more than once") : l instanceof WeakSet ? l.add(o) : l.set(o, h), ke = (o, l, h, b) => (Ve(o, l, "write to private field"), b ? b.call(o, h) : l.set(o, h), h);
6
+ const Dt = [
7
7
  ["Aztec", "M"],
8
8
  ["Codabar", "L"],
9
9
  ["Code39", "L"],
@@ -24,44 +24,44 @@ const Ft = [
24
24
  ["rMQRCode", "M"],
25
25
  ["DXFilmEdge", "L"],
26
26
  ["DataBarLimited", "L"]
27
- ], jt = Ft.map(([o]) => o), Ba = jt.filter(
28
- (o, l) => Ft[l][1] === "L"
29
- ), Wa = jt.filter(
30
- (o, l) => Ft[l][1] === "M"
27
+ ], Mt = Dt.map(([o]) => o), Ma = Mt.filter(
28
+ (o, l) => Dt[l][1] === "L"
29
+ ), Aa = Mt.filter(
30
+ (o, l) => Dt[l][1] === "M"
31
31
  );
32
- function Qt(o) {
32
+ function qt(o) {
33
33
  switch (o) {
34
34
  case "Linear-Codes":
35
- return Ba.reduce((l, h) => l | Qt(h), 0);
35
+ return Ma.reduce((l, h) => l | qt(h), 0);
36
36
  case "Matrix-Codes":
37
- return Wa.reduce((l, h) => l | Qt(h), 0);
37
+ return Aa.reduce((l, h) => l | qt(h), 0);
38
38
  case "Any":
39
- return (1 << Ft.length) - 1;
39
+ return (1 << Dt.length) - 1;
40
40
  case "None":
41
41
  return 0;
42
42
  default:
43
- return 1 << jt.indexOf(o);
43
+ return 1 << Mt.indexOf(o);
44
44
  }
45
45
  }
46
- function Ua(o) {
46
+ function Fa(o) {
47
47
  if (o === 0)
48
48
  return "None";
49
49
  const l = 31 - Math.clz32(o);
50
- return jt[l];
50
+ return Mt[l];
51
51
  }
52
- function Va(o) {
53
- return o.reduce((l, h) => l | Qt(h), 0);
52
+ function Ra(o) {
53
+ return o.reduce((l, h) => l | qt(h), 0);
54
54
  }
55
- const ka = [
55
+ const La = [
56
56
  "LocalAverage",
57
57
  "GlobalHistogram",
58
58
  "FixedThreshold",
59
59
  "BoolCast"
60
60
  ];
61
- function Ha(o) {
62
- return ka.indexOf(o);
61
+ function ja(o) {
62
+ return La.indexOf(o);
63
63
  }
64
- const Le = [
64
+ const Ne = [
65
65
  "Unknown",
66
66
  "ASCII",
67
67
  "ISO8859_1",
@@ -101,10 +101,10 @@ const Le = [
101
101
  "UTF32LE",
102
102
  "BINARY"
103
103
  ];
104
- function Na(o) {
105
- return o === "UnicodeBig" ? Le.indexOf("UTF16BE") : Le.indexOf(o);
104
+ function Ba(o) {
105
+ return o === "UnicodeBig" ? Ne.indexOf("UTF16BE") : Ne.indexOf(o);
106
106
  }
107
- const za = [
107
+ const Ua = [
108
108
  "Text",
109
109
  "Binary",
110
110
  "Mixed",
@@ -112,18 +112,18 @@ const za = [
112
112
  "ISO15434",
113
113
  "UnknownECI"
114
114
  ];
115
- function Ga(o) {
116
- return za[o];
115
+ function Va(o) {
116
+ return Ua[o];
117
117
  }
118
- const Xa = ["Ignore", "Read", "Require"];
119
- function qa(o) {
120
- return Xa.indexOf(o);
118
+ const Wa = ["Ignore", "Read", "Require"];
119
+ function Ha(o) {
120
+ return Wa.indexOf(o);
121
121
  }
122
- const Ya = ["Plain", "ECI", "HRI", "Hex", "Escaped"];
123
- function Za(o) {
124
- return Ya.indexOf(o);
122
+ const ka = ["Plain", "ECI", "HRI", "Hex", "Escaped"];
123
+ function Na(o) {
124
+ return ka.indexOf(o);
125
125
  }
126
- const Mt = {
126
+ const It = {
127
127
  formats: [],
128
128
  tryHarder: !0,
129
129
  tryRotate: !0,
@@ -142,804 +142,786 @@ const Mt = {
142
142
  textMode: "HRI",
143
143
  characterSet: "Unknown"
144
144
  };
145
- function Be(o) {
145
+ function ze(o) {
146
146
  return {
147
147
  ...o,
148
- formats: Va(o.formats),
149
- binarizer: Ha(o.binarizer),
150
- eanAddOnSymbol: qa(o.eanAddOnSymbol),
151
- textMode: Za(o.textMode),
152
- characterSet: Na(o.characterSet)
148
+ formats: Ra(o.formats),
149
+ binarizer: ja(o.binarizer),
150
+ eanAddOnSymbol: Ha(o.eanAddOnSymbol),
151
+ textMode: Na(o.textMode),
152
+ characterSet: Ba(o.characterSet)
153
153
  };
154
154
  }
155
- function Qa(o) {
155
+ function za(o) {
156
156
  return {
157
157
  ...o,
158
- format: Ua(o.format),
159
- contentType: Ga(o.contentType),
158
+ format: Fa(o.format),
159
+ contentType: Va(o.contentType),
160
160
  eccLevel: o.ecLevel
161
161
  };
162
162
  }
163
- const bo = "2.2.0", Co = "0a3797f698b339c1c01c487a7a43f1368610f503", Ja = {
163
+ const vo = "2.2.3", yo = "fba4e9503fee4518ca2e89510baeea9bcc36dc8d", Ga = {
164
164
  locateFile: (o, l) => {
165
165
  const h = o.match(/_(.+?)\.wasm$/);
166
- return h ? `https://fastly.jsdelivr.net/npm/zxing-wasm@2.2.0/dist/${h[1]}/${o}` : l + o;
166
+ return h ? `https://fastly.jsdelivr.net/npm/zxing-wasm@2.2.3/dist/${h[1]}/${o}` : l + o;
167
167
  }
168
- }, It = /* @__PURE__ */ new WeakMap();
169
- function Ka(o, l) {
168
+ }, St = /* @__PURE__ */ new WeakMap();
169
+ function Xa(o, l) {
170
170
  return Object.is(o, l) || Object.keys(o).length === Object.keys(l).length && Object.keys(o).every(
171
171
  (h) => Object.hasOwn(l, h) && o[h] === l[h]
172
172
  );
173
173
  }
174
- function Ue(o, {
174
+ function Xe(o, {
175
175
  overrides: l,
176
- equalityFn: h = Ka,
177
- fireImmediately: f = !1
176
+ equalityFn: h = Xa,
177
+ fireImmediately: b = !1
178
178
  } = {}) {
179
- var C;
180
- const [O, I] = (C = It.get(o)) != null ? C : [Ja], j = l != null ? l : O;
181
- let x;
182
- if (f) {
183
- if (I && (x = h(O, j)))
184
- return I;
185
- const M = o({
186
- ...j
179
+ var f;
180
+ const [I, D] = (f = St.get(o)) != null ? f : [Ga], M = l != null ? l : I;
181
+ let _;
182
+ if (b) {
183
+ if (D && (_ = h(I, M)))
184
+ return D;
185
+ const A = o({
186
+ ...M
187
187
  });
188
- return It.set(o, [j, M]), M;
188
+ return St.set(o, [M, A]), A;
189
189
  }
190
- (x != null ? x : h(O, j)) || It.set(o, [j]);
190
+ (_ != null ? _ : h(I, M)) || St.set(o, [M]);
191
191
  }
192
- function to(o) {
193
- It.delete(o);
192
+ function qa(o) {
193
+ St.delete(o);
194
194
  }
195
- async function eo(o, l, h = Mt) {
196
- const f = {
197
- ...Mt,
195
+ async function Ya(o, l, h = It) {
196
+ const b = {
197
+ ...It,
198
198
  ...h
199
- }, C = await Ue(o, {
199
+ }, f = await Xe(o, {
200
200
  fireImmediately: !0
201
201
  });
202
- let O, I;
202
+ let I, D;
203
203
  if ("width" in l && "height" in l && "data" in l) {
204
204
  const {
205
- data: x,
206
- data: { byteLength: M },
207
- width: z,
205
+ data: _,
206
+ data: { byteLength: A },
207
+ width: U,
208
208
  height: X
209
209
  } = l;
210
- I = C._malloc(M), C.HEAPU8.set(x, I), O = C.readBarcodesFromPixmap(
211
- I,
212
- z,
210
+ D = f._malloc(A), f.HEAPU8.set(_, D), I = f.readBarcodesFromPixmap(
211
+ D,
212
+ U,
213
213
  X,
214
- Be(f)
214
+ ze(b)
215
215
  );
216
216
  } else {
217
- let x, M;
217
+ let _, A;
218
218
  if ("buffer" in l)
219
- [x, M] = [l.byteLength, l];
219
+ [_, A] = [l.byteLength, l];
220
220
  else if ("byteLength" in l)
221
- [x, M] = [l.byteLength, new Uint8Array(l)];
221
+ [_, A] = [l.byteLength, new Uint8Array(l)];
222
222
  else if ("size" in l)
223
- [x, M] = [l.size, new Uint8Array(await l.arrayBuffer())];
223
+ [_, A] = [l.size, new Uint8Array(await l.arrayBuffer())];
224
224
  else
225
225
  throw new TypeError("Invalid input type");
226
- I = C._malloc(x), C.HEAPU8.set(M, I), O = C.readBarcodesFromImage(
227
- I,
228
- x,
229
- Be(f)
226
+ D = f._malloc(_), f.HEAPU8.set(A, D), I = f.readBarcodesFromImage(
227
+ D,
228
+ _,
229
+ ze(b)
230
230
  );
231
231
  }
232
- C._free(I);
233
- const j = [];
234
- for (let x = 0; x < O.size(); ++x)
235
- j.push(
236
- Qa(O.get(x))
232
+ f._free(D);
233
+ const M = [];
234
+ for (let _ = 0; _ < I.size(); ++_)
235
+ M.push(
236
+ za(I.get(_))
237
237
  );
238
- return j;
238
+ return M;
239
239
  }
240
240
  ({
241
- ...Mt,
242
- formats: [...Mt.formats]
241
+ ...It,
242
+ formats: [...It.formats]
243
243
  });
244
- var Kt = async function(o = {}) {
245
- var l, h, f = o, C, O, I = new Promise((e, t) => {
246
- C = e, O = t;
247
- }), j = typeof window == "object", x = typeof Bun < "u", M = typeof WorkerGlobalScope < "u";
248
- typeof process == "object" && !((h = process.versions) === null || h === void 0) && h.node && process.type != "renderer";
249
- var z = "./this.program", X, q = "";
250
- function it(e) {
251
- return f.locateFile ? f.locateFile(e, q) : q + e;
252
- }
253
- var st, et;
254
- if (j || M || x) {
244
+ async function Zt(o = {}) {
245
+ var l, h, b, f = o, I = !!globalThis.window, D = typeof Bun < "u", M = !!globalThis.WorkerGlobalScope;
246
+ !((h = globalThis.process) === null || h === void 0 || (h = h.versions) === null || h === void 0) && h.node && ((b = globalThis.process) === null || b === void 0 ? void 0 : b.type) != "renderer";
247
+ var _ = "./this.program", A, U = "";
248
+ function X(t) {
249
+ return f.locateFile ? f.locateFile(t, U) : U + t;
250
+ }
251
+ var tt, q;
252
+ if (I || M || D) {
255
253
  try {
256
- q = new URL(".", X).href;
254
+ U = new URL(".", A).href;
257
255
  } catch {
258
256
  }
259
- M && (et = (e) => {
260
- var t = new XMLHttpRequest();
261
- return t.open("GET", e, !1), t.responseType = "arraybuffer", t.send(null), new Uint8Array(t.response);
262
- }), st = async (e) => {
263
- var t = await fetch(e, {
257
+ M && (q = (t) => {
258
+ var e = new XMLHttpRequest();
259
+ return e.open("GET", t, !1), e.responseType = "arraybuffer", e.send(null), new Uint8Array(e.response);
260
+ }), tt = async (t) => {
261
+ var e = await fetch(t, {
264
262
  credentials: "same-origin"
265
263
  });
266
- if (t.ok)
267
- return t.arrayBuffer();
268
- throw new Error(t.status + " : " + t.url);
264
+ if (e.ok)
265
+ return e.arrayBuffer();
266
+ throw new Error(e.status + " : " + e.url);
269
267
  };
270
268
  }
271
- var vt = console.log.bind(console), G = console.error.bind(console), ut, yt, te = !1, Y, B, mt, rt, nt, P, ee, re;
272
- function ne() {
273
- var e = yt.buffer;
274
- Y = new Int8Array(e), mt = new Int16Array(e), f.HEAPU8 = B = new Uint8Array(e), rt = new Uint16Array(e), nt = new Int32Array(e), P = new Uint32Array(e), ee = new Float32Array(e), re = new Float64Array(e);
269
+ var nt = console.log.bind(console), V = console.error.bind(console), Y, ht = !1, Qt, Jt, Z, W, dt, at, ot, P, Kt, te, ee = !1;
270
+ function re() {
271
+ var t = Pt.buffer;
272
+ Z = new Int8Array(t), dt = new Int16Array(t), f.HEAPU8 = W = new Uint8Array(t), at = new Uint16Array(t), ot = new Int32Array(t), P = new Uint32Array(t), Kt = new Float32Array(t), te = new Float64Array(t);
275
273
  }
276
- function Qe() {
274
+ function ar() {
277
275
  if (f.preRun)
278
276
  for (typeof f.preRun == "function" && (f.preRun = [f.preRun]); f.preRun.length; )
279
- lr(f.preRun.shift());
280
- ae(ie);
277
+ vr(f.preRun.shift());
278
+ ne(oe);
281
279
  }
282
- function Je() {
283
- _.ya();
280
+ function or() {
281
+ ee = !0, lt.xa();
284
282
  }
285
- function Ke() {
283
+ function ir() {
286
284
  if (f.postRun)
287
285
  for (typeof f.postRun == "function" && (f.postRun = [f.postRun]); f.postRun.length; )
288
- cr(f.postRun.shift());
289
- ae(oe);
290
- }
291
- var Z = 0, ct = null;
292
- function tr(e) {
293
- var t;
294
- Z++, (t = f.monitorRunDependencies) === null || t === void 0 || t.call(f, Z);
295
- }
296
- function er(e) {
297
- var t;
298
- if (Z--, (t = f.monitorRunDependencies) === null || t === void 0 || t.call(f, Z), Z == 0 && ct) {
299
- var r = ct;
300
- ct = null, r();
301
- }
302
- }
303
- function Rt(e) {
304
- var t;
305
- (t = f.onAbort) === null || t === void 0 || t.call(f, e), e = "Aborted(" + e + ")", G(e), te = !0, e += ". Build with -sASSERTIONS for more info.";
306
- var r = new WebAssembly.RuntimeError(e);
307
- throw O(r), r;
308
- }
309
- var gt;
310
- function rr() {
311
- return it("zxing_reader.wasm");
312
- }
313
- function nr(e) {
314
- if (e == gt && ut)
315
- return new Uint8Array(ut);
316
- if (et)
317
- return et(e);
286
+ pr(f.postRun.shift());
287
+ ne(ae);
288
+ }
289
+ function At(t) {
290
+ var e, r;
291
+ (e = f.onAbort) === null || e === void 0 || e.call(f, t), t = "Aborted(" + t + ")", V(t), ht = !0, t += ". Build with -sASSERTIONS for more info.";
292
+ var n = new WebAssembly.RuntimeError(t);
293
+ throw (r = Jt) === null || r === void 0 || r(n), n;
294
+ }
295
+ var pt;
296
+ function sr() {
297
+ return X("zxing_reader.wasm");
298
+ }
299
+ function ur(t) {
300
+ if (t == pt && Y)
301
+ return new Uint8Array(Y);
302
+ if (q)
303
+ return q(t);
318
304
  throw "both async and sync fetching of the wasm failed";
319
305
  }
320
- async function ar(e) {
321
- if (!ut)
306
+ async function cr(t) {
307
+ if (!Y)
322
308
  try {
323
- var t = await st(e);
324
- return new Uint8Array(t);
309
+ var e = await tt(t);
310
+ return new Uint8Array(e);
325
311
  } catch {
326
312
  }
327
- return nr(e);
313
+ return ur(t);
328
314
  }
329
- async function or(e, t) {
315
+ async function lr(t, e) {
330
316
  try {
331
- var r = await ar(e), n = await WebAssembly.instantiate(r, t);
317
+ var r = await cr(t), n = await WebAssembly.instantiate(r, e);
332
318
  return n;
333
319
  } catch (a) {
334
- G(`failed to asynchronously prepare wasm: ${a}`), Rt(a);
320
+ V(`failed to asynchronously prepare wasm: ${a}`), At(a);
335
321
  }
336
322
  }
337
- async function ir(e, t, r) {
338
- if (!e && typeof WebAssembly.instantiateStreaming == "function")
323
+ async function fr(t, e, r) {
324
+ if (!t && WebAssembly.instantiateStreaming)
339
325
  try {
340
- var n = fetch(t, {
326
+ var n = fetch(e, {
341
327
  credentials: "same-origin"
342
328
  }), a = await WebAssembly.instantiateStreaming(n, r);
343
329
  return a;
344
330
  } catch (i) {
345
- G(`wasm streaming compile failed: ${i}`), G("falling back to ArrayBuffer instantiation");
331
+ V(`wasm streaming compile failed: ${i}`), V("falling back to ArrayBuffer instantiation");
346
332
  }
347
- return or(t, r);
333
+ return lr(e, r);
348
334
  }
349
- function sr() {
350
- return {
351
- a: Nn
335
+ function hr() {
336
+ var t = {
337
+ a: qn
352
338
  };
339
+ return t;
353
340
  }
354
- async function ur() {
355
- function e(i, u) {
356
- return _ = i.exports, yt = _.xa, ne(), ye = _.Ba, er(), _;
341
+ async function dr() {
342
+ function t(i, s) {
343
+ return lt = i.exports, Xn(lt), re(), lt;
357
344
  }
358
- tr();
359
- function t(i) {
360
- return e(i.instance);
345
+ function e(i) {
346
+ return t(i.instance);
361
347
  }
362
- var r = sr();
348
+ var r = hr();
363
349
  if (f.instantiateWasm)
364
- return new Promise((i, u) => {
365
- f.instantiateWasm(r, (s, c) => {
366
- i(e(s));
350
+ return new Promise((i, s) => {
351
+ f.instantiateWasm(r, (u, c) => {
352
+ i(t(u));
367
353
  });
368
354
  });
369
- gt != null || (gt = rr());
370
- try {
371
- var n = await ir(ut, gt, r), a = t(n);
372
- return a;
373
- } catch (i) {
374
- return O(i), Promise.reject(i);
375
- }
376
- }
377
- var ae = (e) => {
378
- for (; e.length > 0; )
379
- e.shift()(f);
380
- }, oe = [], cr = (e) => oe.push(e), ie = [], lr = (e) => ie.push(e), m = (e) => qn(e), g = () => Yn(), wt = [], $t = 0, fr = (e) => {
381
- var t = new Lt(e);
382
- return t.get_caught() || (t.set_caught(!0), $t--), t.set_rethrown(!1), wt.push(t), Qn(e), Gn(e);
383
- }, V = 0, dr = () => {
384
- y(0, 0);
385
- var e = wt.pop();
386
- Zn(e.excPtr), V = 0;
355
+ pt != null || (pt = sr());
356
+ var n = await fr(Y, pt, r), a = e(n);
357
+ return a;
358
+ }
359
+ var ne = (t) => {
360
+ for (; t.length > 0; )
361
+ t.shift()(f);
362
+ }, ae = [], pr = (t) => ae.push(t), oe = [], vr = (t) => oe.push(t), g = (t) => _e(t), w = () => xe(), vt = [], yt = 0, yr = (t) => {
363
+ var e = new Ft(t);
364
+ return e.get_caught() || (e.set_caught(!0), yt--), e.set_rethrown(!1), vt.push(e), Ie(t), Pe(t);
365
+ }, H = 0, mr = () => {
366
+ m(0, 0);
367
+ var t = vt.pop();
368
+ Se(t.excPtr), H = 0;
387
369
  };
388
- class Lt {
389
- constructor(t) {
390
- this.excPtr = t, this.ptr = t - 24;
370
+ class Ft {
371
+ constructor(e) {
372
+ this.excPtr = e, this.ptr = e - 24;
391
373
  }
392
- set_type(t) {
393
- P[this.ptr + 4 >> 2] = t;
374
+ set_type(e) {
375
+ P[this.ptr + 4 >> 2] = e;
394
376
  }
395
377
  get_type() {
396
378
  return P[this.ptr + 4 >> 2];
397
379
  }
398
- set_destructor(t) {
399
- P[this.ptr + 8 >> 2] = t;
380
+ set_destructor(e) {
381
+ P[this.ptr + 8 >> 2] = e;
400
382
  }
401
383
  get_destructor() {
402
384
  return P[this.ptr + 8 >> 2];
403
385
  }
404
- set_caught(t) {
405
- t = t ? 1 : 0, Y[this.ptr + 12] = t;
386
+ set_caught(e) {
387
+ e = e ? 1 : 0, Z[this.ptr + 12] = e;
406
388
  }
407
389
  get_caught() {
408
- return Y[this.ptr + 12] != 0;
390
+ return Z[this.ptr + 12] != 0;
409
391
  }
410
- set_rethrown(t) {
411
- t = t ? 1 : 0, Y[this.ptr + 13] = t;
392
+ set_rethrown(e) {
393
+ e = e ? 1 : 0, Z[this.ptr + 13] = e;
412
394
  }
413
395
  get_rethrown() {
414
- return Y[this.ptr + 13] != 0;
396
+ return Z[this.ptr + 13] != 0;
415
397
  }
416
- init(t, r) {
417
- this.set_adjusted_ptr(0), this.set_type(t), this.set_destructor(r);
398
+ init(e, r) {
399
+ this.set_adjusted_ptr(0), this.set_type(e), this.set_destructor(r);
418
400
  }
419
- set_adjusted_ptr(t) {
420
- P[this.ptr + 16 >> 2] = t;
401
+ set_adjusted_ptr(e) {
402
+ P[this.ptr + 16 >> 2] = e;
421
403
  }
422
404
  get_adjusted_ptr() {
423
405
  return P[this.ptr + 16 >> 2];
424
406
  }
425
407
  }
426
- var bt = (e) => Xn(e), Bt = (e) => {
427
- var t = V;
428
- if (!t)
429
- return bt(0), 0;
430
- var r = new Lt(t);
431
- r.set_adjusted_ptr(t);
408
+ var mt = (t) => Oe(t), Rt = (t) => {
409
+ var e = H;
410
+ if (!e)
411
+ return mt(0), 0;
412
+ var r = new Ft(e);
413
+ r.set_adjusted_ptr(e);
432
414
  var n = r.get_type();
433
415
  if (!n)
434
- return bt(0), t;
435
- for (var a of e) {
416
+ return mt(0), e;
417
+ for (var a of t) {
436
418
  if (a === 0 || a === n)
437
419
  break;
438
420
  var i = r.ptr + 16;
439
- if (Jn(a, n, i))
440
- return bt(a), t;
441
- }
442
- return bt(n), t;
443
- }, hr = () => Bt([]), pr = (e) => Bt([e]), vr = (e, t) => Bt([e, t]), yr = () => {
444
- var e = wt.pop();
445
- e || Rt("no exception to throw");
446
- var t = e.excPtr;
447
- throw e.get_rethrown() || (wt.push(e), e.set_rethrown(!0), e.set_caught(!1), $t++), V = t, V;
448
- }, mr = (e, t, r) => {
449
- var n = new Lt(e);
450
- throw n.init(t, r), V = e, $t++, V;
451
- }, gr = () => $t, wr = (e) => {
452
- throw V || (V = e), V;
453
- }, $r = () => Rt(""), Ct = {}, Wt = (e) => {
454
- for (; e.length; ) {
455
- var t = e.pop(), r = e.pop();
456
- r(t);
421
+ if (De(a, n, i))
422
+ return mt(a), e;
423
+ }
424
+ return mt(n), e;
425
+ }, gr = () => Rt([]), wr = (t) => Rt([t]), $r = (t, e) => Rt([t, e]), br = () => {
426
+ var t = vt.pop();
427
+ t || At("no exception to throw");
428
+ var e = t.excPtr;
429
+ throw t.get_rethrown() || (vt.push(t), t.set_rethrown(!0), t.set_caught(!1), yt++), H = e, H;
430
+ }, Cr = (t, e, r) => {
431
+ var n = new Ft(t);
432
+ throw n.init(e, r), H = t, yt++, H;
433
+ }, Tr = () => yt, Er = (t) => {
434
+ throw H || (H = t), H;
435
+ }, Pr = () => At(""), gt = {}, Lt = (t) => {
436
+ for (; t.length; ) {
437
+ var e = t.pop(), r = t.pop();
438
+ r(e);
457
439
  }
458
440
  };
459
- function lt(e) {
460
- return this.fromWireType(P[e >> 2]);
441
+ function it(t) {
442
+ return this.fromWireType(P[t >> 2]);
461
443
  }
462
- var at = {}, Q = {}, Tt = {}, br = class extends Error {
463
- constructor(e) {
464
- super(e), this.name = "InternalError";
465
- }
466
- }, Pt = (e) => {
467
- throw new br(e);
468
- }, J = (e, t, r) => {
469
- e.forEach((s) => Tt[s] = t);
470
- function n(s) {
471
- var c = r(s);
472
- c.length !== e.length && Pt("Mismatched type converter count");
473
- for (var d = 0; d < e.length; ++d)
474
- U(e[d], c[d]);
475
- }
476
- var a = new Array(t.length), i = [], u = 0;
477
- t.forEach((s, c) => {
478
- Q.hasOwnProperty(s) ? a[c] = Q[s] : (i.push(s), at.hasOwnProperty(s) || (at[s] = []), at[s].push(() => {
479
- a[c] = Q[s], ++u, u === i.length && n(a);
444
+ var et = {}, Q = {}, wt = {}, Or = class extends Error {
445
+ constructor(t) {
446
+ super(t), this.name = "InternalError";
447
+ }
448
+ }, $t = (t) => {
449
+ throw new Or(t);
450
+ }, J = (t, e, r) => {
451
+ t.forEach((u) => wt[u] = e);
452
+ function n(u) {
453
+ var c = r(u);
454
+ c.length !== t.length && $t("Mismatched type converter count");
455
+ for (var d = 0; d < t.length; ++d)
456
+ j(t[d], c[d]);
457
+ }
458
+ var a = new Array(e.length), i = [], s = 0;
459
+ for (let [u, c] of e.entries())
460
+ Q.hasOwnProperty(c) ? a[u] = Q[c] : (i.push(c), et.hasOwnProperty(c) || (et[c] = []), et[c].push(() => {
461
+ a[u] = Q[c], ++s, s === i.length && n(a);
480
462
  }));
481
- }), i.length === 0 && n(a);
482
- }, Cr = (e) => {
483
- var t = Ct[e];
484
- delete Ct[e];
485
- var r = t.rawConstructor, n = t.rawDestructor, a = t.fields, i = a.map((u) => u.getterReturnType).concat(a.map((u) => u.setterArgumentType));
486
- J([e], i, (u) => {
487
- var s = {};
488
- return a.forEach((c, d) => {
489
- var p = c.fieldName, v = u[d], $ = u[d].optional, b = c.getter, E = c.getterContext, S = u[d + a.length], A = c.setter, D = c.setterContext;
490
- s[p] = {
491
- read: (N) => v.fromWireType(b(E, N)),
492
- write: (N, R) => {
493
- var L = [];
494
- A(D, N, S.toWireType(L, R)), Wt(L);
463
+ i.length === 0 && n(a);
464
+ }, _r = (t) => {
465
+ var e = gt[t];
466
+ delete gt[t];
467
+ var r = e.rawConstructor, n = e.rawDestructor, a = e.fields, i = a.map((s) => s.getterReturnType).concat(a.map((s) => s.setterArgumentType));
468
+ J([t], i, (s) => {
469
+ var u = {};
470
+ for (var [c, d] of a.entries()) {
471
+ const p = s[c], v = d.getter, y = d.getterContext, T = s[c + a.length], S = d.setter, x = d.setterContext;
472
+ u[d.fieldName] = {
473
+ read: (E) => p.fromWireType(v(y, E)),
474
+ write: (E, O) => {
475
+ var G = [];
476
+ S(x, E, T.toWireType(G, O)), Lt(G);
495
477
  },
496
- optional: $
478
+ optional: p.optional
497
479
  };
498
- }), [{
499
- name: t.name,
500
- fromWireType: (c) => {
501
- var d = {};
502
- for (var p in s)
503
- d[p] = s[p].read(c);
504
- return n(c), d;
480
+ }
481
+ return [{
482
+ name: e.name,
483
+ fromWireType: (p) => {
484
+ var v = {};
485
+ for (var y in u)
486
+ v[y] = u[y].read(p);
487
+ return n(p), v;
505
488
  },
506
- toWireType: (c, d) => {
507
- for (var p in s)
508
- if (!(p in d) && !s[p].optional)
509
- throw new TypeError(`Missing field: "${p}"`);
510
- var v = r();
511
- for (p in s)
512
- s[p].write(v, d[p]);
513
- return c !== null && c.push(n, v), v;
489
+ toWireType: (p, v) => {
490
+ for (var y in u)
491
+ if (!(y in v) && !u[y].optional)
492
+ throw new TypeError(`Missing field: "${y}"`);
493
+ var T = r();
494
+ for (y in u)
495
+ u[y].write(T, v[y]);
496
+ return p !== null && p.push(n, T), T;
514
497
  },
515
- argPackAdvance: k,
516
- readValueFromPointer: lt,
498
+ readValueFromPointer: it,
517
499
  destructorFunction: n
518
500
  }];
519
501
  });
520
- }, Tr = (e, t, r, n, a) => {
521
- }, Pr = () => {
522
- for (var e = new Array(256), t = 0; t < 256; ++t)
523
- e[t] = String.fromCharCode(t);
524
- se = e;
525
- }, se, F = (e) => {
526
- for (var t = "", r = e; B[r]; )
527
- t += se[B[r++]];
528
- return t;
529
- }, ft = class extends Error {
530
- constructor(e) {
531
- super(e), this.name = "BindingError";
502
+ }, xr = (t, e, r, n, a) => {
503
+ }, F = (t) => {
504
+ for (var e = ""; ; ) {
505
+ var r = W[t++];
506
+ if (!r) return e;
507
+ e += String.fromCharCode(r);
508
+ }
509
+ }, st = class extends Error {
510
+ constructor(t) {
511
+ super(t), this.name = "BindingError";
532
512
  }
533
- }, T = (e) => {
534
- throw new ft(e);
513
+ }, C = (t) => {
514
+ throw new st(t);
535
515
  };
536
- function _r(e, t) {
516
+ function Sr(t, e) {
537
517
  let r = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};
538
- var n = t.name;
539
- if (e || T(`type "${n}" must have a positive integer typeid pointer`), Q.hasOwnProperty(e)) {
518
+ var n = e.name;
519
+ if (t || C(`type "${n}" must have a positive integer typeid pointer`), Q.hasOwnProperty(t)) {
540
520
  if (r.ignoreDuplicateRegistrations)
541
521
  return;
542
- T(`Cannot register type '${n}' twice`);
522
+ C(`Cannot register type '${n}' twice`);
543
523
  }
544
- if (Q[e] = t, delete Tt[e], at.hasOwnProperty(e)) {
545
- var a = at[e];
546
- delete at[e], a.forEach((i) => i());
524
+ if (Q[t] = e, delete wt[t], et.hasOwnProperty(t)) {
525
+ var a = et[t];
526
+ delete et[t], a.forEach((i) => i());
547
527
  }
548
528
  }
549
- function U(e, t) {
529
+ function j(t, e) {
550
530
  let r = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};
551
- return _r(e, t, r);
531
+ return Sr(t, e, r);
552
532
  }
553
- var k = 8, Er = (e, t, r, n) => {
554
- t = F(t), U(e, {
555
- name: t,
533
+ var Ir = (t, e, r, n) => {
534
+ e = F(e), j(t, {
535
+ name: e,
556
536
  fromWireType: function(a) {
557
537
  return !!a;
558
538
  },
559
539
  toWireType: function(a, i) {
560
540
  return i ? r : n;
561
541
  },
562
- argPackAdvance: k,
563
542
  readValueFromPointer: function(a) {
564
- return this.fromWireType(B[a]);
543
+ return this.fromWireType(W[a]);
565
544
  },
566
545
  destructorFunction: null
567
546
  });
568
- }, Or = (e) => ({
569
- count: e.count,
570
- deleteScheduled: e.deleteScheduled,
571
- preservePointerOnDelete: e.preservePointerOnDelete,
572
- ptr: e.ptr,
573
- ptrType: e.ptrType,
574
- smartPtr: e.smartPtr,
575
- smartPtrType: e.smartPtrType
576
- }), Ut = (e) => {
577
- function t(r) {
547
+ }, Dr = (t) => ({
548
+ count: t.count,
549
+ deleteScheduled: t.deleteScheduled,
550
+ preservePointerOnDelete: t.preservePointerOnDelete,
551
+ ptr: t.ptr,
552
+ ptrType: t.ptrType,
553
+ smartPtr: t.smartPtr,
554
+ smartPtrType: t.smartPtrType
555
+ }), jt = (t) => {
556
+ function e(r) {
578
557
  return r.$$.ptrType.registeredClass.name;
579
558
  }
580
- T(t(e) + " instance already deleted");
581
- }, Vt = !1, ue = (e) => {
582
- }, xr = (e) => {
583
- e.smartPtr ? e.smartPtrType.rawDestructor(e.smartPtr) : e.ptrType.registeredClass.rawDestructor(e.ptr);
584
- }, ce = (e) => {
585
- e.count.value -= 1;
586
- var t = e.count.value === 0;
587
- t && xr(e);
588
- }, dt = (e) => typeof FinalizationRegistry > "u" ? (dt = (t) => t, e) : (Vt = new FinalizationRegistry((t) => {
589
- ce(t.$$);
590
- }), dt = (t) => {
591
- var r = t.$$, n = !!r.smartPtr;
559
+ C(e(t) + " instance already deleted");
560
+ }, Bt = !1, ie = (t) => {
561
+ }, Mr = (t) => {
562
+ t.smartPtr ? t.smartPtrType.rawDestructor(t.smartPtr) : t.ptrType.registeredClass.rawDestructor(t.ptr);
563
+ }, se = (t) => {
564
+ t.count.value -= 1;
565
+ var e = t.count.value === 0;
566
+ e && Mr(t);
567
+ }, ut = (t) => globalThis.FinalizationRegistry ? (Bt = new FinalizationRegistry((e) => {
568
+ se(e.$$);
569
+ }), ut = (e) => {
570
+ var r = e.$$, n = !!r.smartPtr;
592
571
  if (n) {
593
572
  var a = {
594
573
  $$: r
595
574
  };
596
- Vt.register(t, a, t);
575
+ Bt.register(e, a, e);
597
576
  }
598
- return t;
599
- }, ue = (t) => Vt.unregister(t), dt(e)), Ar = () => {
600
- let e = _t.prototype;
601
- Object.assign(e, {
577
+ return e;
578
+ }, ie = (e) => Bt.unregister(e), ut(t)) : (ut = (e) => e, t), Ar = () => {
579
+ let t = bt.prototype;
580
+ Object.assign(t, {
602
581
  isAliasOf(r) {
603
- if (!(this instanceof _t) || !(r instanceof _t))
582
+ if (!(this instanceof bt) || !(r instanceof bt))
604
583
  return !1;
605
584
  var n = this.$$.ptrType.registeredClass, a = this.$$.ptr;
606
585
  r.$$ = r.$$;
607
- for (var i = r.$$.ptrType.registeredClass, u = r.$$.ptr; n.baseClass; )
586
+ for (var i = r.$$.ptrType.registeredClass, s = r.$$.ptr; n.baseClass; )
608
587
  a = n.upcast(a), n = n.baseClass;
609
588
  for (; i.baseClass; )
610
- u = i.upcast(u), i = i.baseClass;
611
- return n === i && a === u;
589
+ s = i.upcast(s), i = i.baseClass;
590
+ return n === i && a === s;
612
591
  },
613
592
  clone() {
614
- if (this.$$.ptr || Ut(this), this.$$.preservePointerOnDelete)
593
+ if (this.$$.ptr || jt(this), this.$$.preservePointerOnDelete)
615
594
  return this.$$.count.value += 1, this;
616
- var r = dt(Object.create(Object.getPrototypeOf(this), {
595
+ var r = ut(Object.create(Object.getPrototypeOf(this), {
617
596
  $$: {
618
- value: Or(this.$$)
597
+ value: Dr(this.$$)
619
598
  }
620
599
  }));
621
600
  return r.$$.count.value += 1, r.$$.deleteScheduled = !1, r;
622
601
  },
623
602
  delete() {
624
- this.$$.ptr || Ut(this), this.$$.deleteScheduled && !this.$$.preservePointerOnDelete && T("Object already scheduled for deletion"), ue(this), ce(this.$$), this.$$.preservePointerOnDelete || (this.$$.smartPtr = void 0, this.$$.ptr = void 0);
603
+ this.$$.ptr || jt(this), this.$$.deleteScheduled && !this.$$.preservePointerOnDelete && C("Object already scheduled for deletion"), ie(this), se(this.$$), this.$$.preservePointerOnDelete || (this.$$.smartPtr = void 0, this.$$.ptr = void 0);
625
604
  },
626
605
  isDeleted() {
627
606
  return !this.$$.ptr;
628
607
  },
629
608
  deleteLater() {
630
- return this.$$.ptr || Ut(this), this.$$.deleteScheduled && !this.$$.preservePointerOnDelete && T("Object already scheduled for deletion"), this.$$.deleteScheduled = !0, this;
609
+ return this.$$.ptr || jt(this), this.$$.deleteScheduled && !this.$$.preservePointerOnDelete && C("Object already scheduled for deletion"), this.$$.deleteScheduled = !0, this;
631
610
  }
632
611
  });
633
- const t = Symbol.dispose;
634
- t && (e[t] = e.delete);
612
+ const e = Symbol.dispose;
613
+ e && (t[e] = t.delete);
635
614
  };
636
- function _t() {
637
- }
638
- var kt = (e, t) => Object.defineProperty(t, "name", {
639
- value: e
640
- }), le = {}, fe = (e, t, r) => {
641
- if (e[t].overloadTable === void 0) {
642
- var n = e[t];
643
- e[t] = function() {
644
- for (var a = arguments.length, i = new Array(a), u = 0; u < a; u++)
645
- i[u] = arguments[u];
646
- return e[t].overloadTable.hasOwnProperty(i.length) || T(`Function '${r}' called with an invalid number of arguments (${i.length}) - expects one of (${e[t].overloadTable})!`), e[t].overloadTable[i.length].apply(this, i);
647
- }, e[t].overloadTable = [], e[t].overloadTable[n.argCount] = n;
648
- }
649
- }, de = (e, t, r) => {
650
- f.hasOwnProperty(e) ? ((r === void 0 || f[e].overloadTable !== void 0 && f[e].overloadTable[r] !== void 0) && T(`Cannot register public name '${e}' twice`), fe(f, e, e), f[e].overloadTable.hasOwnProperty(r) && T(`Cannot register multiple overloads of a function with the same number of arguments (${r})!`), f[e].overloadTable[r] = t) : (f[e] = t, f[e].argCount = r);
651
- }, Sr = 48, Dr = 57, Ir = (e) => {
652
- e = e.replace(/[^a-zA-Z0-9_]/g, "$");
653
- var t = e.charCodeAt(0);
654
- return t >= Sr && t <= Dr ? `_${e}` : e;
615
+ function bt() {
616
+ }
617
+ var Ut = (t, e) => Object.defineProperty(e, "name", {
618
+ value: t
619
+ }), ue = {}, ce = (t, e, r) => {
620
+ if (t[e].overloadTable === void 0) {
621
+ var n = t[e];
622
+ t[e] = function() {
623
+ for (var a = arguments.length, i = new Array(a), s = 0; s < a; s++)
624
+ i[s] = arguments[s];
625
+ return t[e].overloadTable.hasOwnProperty(i.length) || C(`Function '${r}' called with an invalid number of arguments (${i.length}) - expects one of (${t[e].overloadTable})!`), t[e].overloadTable[i.length].apply(this, i);
626
+ }, t[e].overloadTable = [], t[e].overloadTable[n.argCount] = n;
627
+ }
628
+ }, le = (t, e, r) => {
629
+ f.hasOwnProperty(t) ? ((r === void 0 || f[t].overloadTable !== void 0 && f[t].overloadTable[r] !== void 0) && C(`Cannot register public name '${t}' twice`), ce(f, t, t), f[t].overloadTable.hasOwnProperty(r) && C(`Cannot register multiple overloads of a function with the same number of arguments (${r})!`), f[t].overloadTable[r] = e) : (f[t] = e, f[t].argCount = r);
630
+ }, Fr = 48, Rr = 57, Lr = (t) => {
631
+ t = t.replace(/[^a-zA-Z0-9_]/g, "$");
632
+ var e = t.charCodeAt(0);
633
+ return e >= Fr && e <= Rr ? `_${t}` : t;
655
634
  };
656
- function Mr(e, t, r, n, a, i, u, s) {
657
- this.name = e, this.constructor = t, this.instancePrototype = r, this.rawDestructor = n, this.baseClass = a, this.getActualType = i, this.upcast = u, this.downcast = s, this.pureVirtualFunctions = [];
635
+ function jr(t, e, r, n, a, i, s, u) {
636
+ this.name = t, this.constructor = e, this.instancePrototype = r, this.rawDestructor = n, this.baseClass = a, this.getActualType = i, this.upcast = s, this.downcast = u, this.pureVirtualFunctions = [];
658
637
  }
659
- var Ht = (e, t, r) => {
660
- for (; t !== r; )
661
- t.upcast || T(`Expected null or instance of ${r.name}, got an instance of ${t.name}`), e = t.upcast(e), t = t.baseClass;
662
- return e;
663
- }, Nt = (e) => {
664
- if (e === null)
638
+ var Vt = (t, e, r) => {
639
+ for (; e !== r; )
640
+ e.upcast || C(`Expected null or instance of ${r.name}, got an instance of ${e.name}`), t = e.upcast(t), e = e.baseClass;
641
+ return t;
642
+ }, Wt = (t) => {
643
+ if (t === null)
665
644
  return "null";
666
- var t = typeof e;
667
- return t === "object" || t === "array" || t === "function" ? e.toString() : "" + e;
645
+ var e = typeof t;
646
+ return e === "object" || e === "array" || e === "function" ? t.toString() : "" + t;
668
647
  };
669
- function Fr(e, t) {
670
- if (t === null)
671
- return this.isReference && T(`null is not a valid ${this.name}`), 0;
672
- t.$$ || T(`Cannot pass "${Nt(t)}" as a ${this.name}`), t.$$.ptr || T(`Cannot pass deleted object as a pointer of type ${this.name}`);
673
- var r = t.$$.ptrType.registeredClass, n = Ht(t.$$.ptr, r, this.registeredClass);
648
+ function Br(t, e) {
649
+ if (e === null)
650
+ return this.isReference && C(`null is not a valid ${this.name}`), 0;
651
+ e.$$ || C(`Cannot pass "${Wt(e)}" as a ${this.name}`), e.$$.ptr || C(`Cannot pass deleted object as a pointer of type ${this.name}`);
652
+ var r = e.$$.ptrType.registeredClass, n = Vt(e.$$.ptr, r, this.registeredClass);
674
653
  return n;
675
654
  }
676
- function jr(e, t) {
655
+ function Ur(t, e) {
677
656
  var r;
678
- if (t === null)
679
- return this.isReference && T(`null is not a valid ${this.name}`), this.isSmartPointer ? (r = this.rawConstructor(), e !== null && e.push(this.rawDestructor, r), r) : 0;
680
- (!t || !t.$$) && T(`Cannot pass "${Nt(t)}" as a ${this.name}`), t.$$.ptr || T(`Cannot pass deleted object as a pointer of type ${this.name}`), !this.isConst && t.$$.ptrType.isConst && T(`Cannot convert argument of type ${t.$$.smartPtrType ? t.$$.smartPtrType.name : t.$$.ptrType.name} to parameter type ${this.name}`);
681
- var n = t.$$.ptrType.registeredClass;
682
- if (r = Ht(t.$$.ptr, n, this.registeredClass), this.isSmartPointer)
683
- switch (t.$$.smartPtr === void 0 && T("Passing raw pointer to smart pointer is illegal"), this.sharingPolicy) {
657
+ if (e === null)
658
+ return this.isReference && C(`null is not a valid ${this.name}`), this.isSmartPointer ? (r = this.rawConstructor(), t !== null && t.push(this.rawDestructor, r), r) : 0;
659
+ (!e || !e.$$) && C(`Cannot pass "${Wt(e)}" as a ${this.name}`), e.$$.ptr || C(`Cannot pass deleted object as a pointer of type ${this.name}`), !this.isConst && e.$$.ptrType.isConst && C(`Cannot convert argument of type ${e.$$.smartPtrType ? e.$$.smartPtrType.name : e.$$.ptrType.name} to parameter type ${this.name}`);
660
+ var n = e.$$.ptrType.registeredClass;
661
+ if (r = Vt(e.$$.ptr, n, this.registeredClass), this.isSmartPointer)
662
+ switch (e.$$.smartPtr === void 0 && C("Passing raw pointer to smart pointer is illegal"), this.sharingPolicy) {
684
663
  case 0:
685
- t.$$.smartPtrType === this ? r = t.$$.smartPtr : T(`Cannot convert argument of type ${t.$$.smartPtrType ? t.$$.smartPtrType.name : t.$$.ptrType.name} to parameter type ${this.name}`);
664
+ e.$$.smartPtrType === this ? r = e.$$.smartPtr : C(`Cannot convert argument of type ${e.$$.smartPtrType ? e.$$.smartPtrType.name : e.$$.ptrType.name} to parameter type ${this.name}`);
686
665
  break;
687
666
  case 1:
688
- r = t.$$.smartPtr;
667
+ r = e.$$.smartPtr;
689
668
  break;
690
669
  case 2:
691
- if (t.$$.smartPtrType === this)
692
- r = t.$$.smartPtr;
670
+ if (e.$$.smartPtrType === this)
671
+ r = e.$$.smartPtr;
693
672
  else {
694
- var a = t.clone();
695
- r = this.rawShare(r, H.toHandle(() => a.delete())), e !== null && e.push(this.rawDestructor, r);
673
+ var a = e.clone();
674
+ r = this.rawShare(r, B.toHandle(() => a.delete())), t !== null && t.push(this.rawDestructor, r);
696
675
  }
697
676
  break;
698
677
  default:
699
- T("Unsupporting sharing policy");
678
+ C("Unsupporting sharing policy");
700
679
  }
701
680
  return r;
702
681
  }
703
- function Rr(e, t) {
704
- if (t === null)
705
- return this.isReference && T(`null is not a valid ${this.name}`), 0;
706
- t.$$ || T(`Cannot pass "${Nt(t)}" as a ${this.name}`), t.$$.ptr || T(`Cannot pass deleted object as a pointer of type ${this.name}`), t.$$.ptrType.isConst && T(`Cannot convert argument of type ${t.$$.ptrType.name} to parameter type ${this.name}`);
707
- var r = t.$$.ptrType.registeredClass, n = Ht(t.$$.ptr, r, this.registeredClass);
682
+ function Vr(t, e) {
683
+ if (e === null)
684
+ return this.isReference && C(`null is not a valid ${this.name}`), 0;
685
+ e.$$ || C(`Cannot pass "${Wt(e)}" as a ${this.name}`), e.$$.ptr || C(`Cannot pass deleted object as a pointer of type ${this.name}`), e.$$.ptrType.isConst && C(`Cannot convert argument of type ${e.$$.ptrType.name} to parameter type ${this.name}`);
686
+ var r = e.$$.ptrType.registeredClass, n = Vt(e.$$.ptr, r, this.registeredClass);
708
687
  return n;
709
688
  }
710
- var he = (e, t, r) => {
711
- if (t === r)
712
- return e;
689
+ var fe = (t, e, r) => {
690
+ if (e === r)
691
+ return t;
713
692
  if (r.baseClass === void 0)
714
693
  return null;
715
- var n = he(e, t, r.baseClass);
694
+ var n = fe(t, e, r.baseClass);
716
695
  return n === null ? null : r.downcast(n);
717
- }, Lr = {}, Br = (e, t) => {
718
- for (t === void 0 && T("ptr should not be undefined"); e.baseClass; )
719
- t = e.upcast(t), e = e.baseClass;
720
- return t;
721
- }, Wr = (e, t) => (t = Br(e, t), Lr[t]), Et = (e, t) => {
722
- (!t.ptrType || !t.ptr) && Pt("makeClassHandle requires ptr and ptrType");
723
- var r = !!t.smartPtrType, n = !!t.smartPtr;
724
- return r !== n && Pt("Both smartPtrType and smartPtr must be specified"), t.count = {
696
+ }, Wr = {}, Hr = (t, e) => {
697
+ for (e === void 0 && C("ptr should not be undefined"); t.baseClass; )
698
+ e = t.upcast(e), t = t.baseClass;
699
+ return e;
700
+ }, kr = (t, e) => (e = Hr(t, e), Wr[e]), Ct = (t, e) => {
701
+ (!e.ptrType || !e.ptr) && $t("makeClassHandle requires ptr and ptrType");
702
+ var r = !!e.smartPtrType, n = !!e.smartPtr;
703
+ return r !== n && $t("Both smartPtrType and smartPtr must be specified"), e.count = {
725
704
  value: 1
726
- }, dt(Object.create(e, {
705
+ }, ut(Object.create(t, {
727
706
  $$: {
728
- value: t,
707
+ value: e,
729
708
  writable: !0
730
709
  }
731
710
  }));
732
711
  };
733
- function Ur(e) {
734
- var t = this.getPointee(e);
735
- if (!t)
736
- return this.destructor(e), null;
737
- var r = Wr(this.registeredClass, t);
712
+ function Nr(t) {
713
+ var e = this.getPointee(t);
714
+ if (!e)
715
+ return this.destructor(t), null;
716
+ var r = kr(this.registeredClass, e);
738
717
  if (r !== void 0) {
739
718
  if (r.$$.count.value === 0)
740
- return r.$$.ptr = t, r.$$.smartPtr = e, r.clone();
719
+ return r.$$.ptr = e, r.$$.smartPtr = t, r.clone();
741
720
  var n = r.clone();
742
- return this.destructor(e), n;
721
+ return this.destructor(t), n;
743
722
  }
744
723
  function a() {
745
- return this.isSmartPointer ? Et(this.registeredClass.instancePrototype, {
724
+ return this.isSmartPointer ? Ct(this.registeredClass.instancePrototype, {
746
725
  ptrType: this.pointeeType,
747
- ptr: t,
726
+ ptr: e,
748
727
  smartPtrType: this,
749
- smartPtr: e
750
- }) : Et(this.registeredClass.instancePrototype, {
728
+ smartPtr: t
729
+ }) : Ct(this.registeredClass.instancePrototype, {
751
730
  ptrType: this,
752
- ptr: e
731
+ ptr: t
753
732
  });
754
733
  }
755
- var i = this.registeredClass.getActualType(t), u = le[i];
756
- if (!u)
734
+ var i = this.registeredClass.getActualType(e), s = ue[i];
735
+ if (!s)
757
736
  return a.call(this);
758
- var s;
759
- this.isConst ? s = u.constPointerType : s = u.pointerType;
760
- var c = he(t, this.registeredClass, s.registeredClass);
761
- return c === null ? a.call(this) : this.isSmartPointer ? Et(s.registeredClass.instancePrototype, {
762
- ptrType: s,
737
+ var u;
738
+ this.isConst ? u = s.constPointerType : u = s.pointerType;
739
+ var c = fe(e, this.registeredClass, u.registeredClass);
740
+ return c === null ? a.call(this) : this.isSmartPointer ? Ct(u.registeredClass.instancePrototype, {
741
+ ptrType: u,
763
742
  ptr: c,
764
743
  smartPtrType: this,
765
- smartPtr: e
766
- }) : Et(s.registeredClass.instancePrototype, {
767
- ptrType: s,
744
+ smartPtr: t
745
+ }) : Ct(u.registeredClass.instancePrototype, {
746
+ ptrType: u,
768
747
  ptr: c
769
748
  });
770
749
  }
771
- var Vr = () => {
772
- Object.assign(Ot.prototype, {
773
- getPointee(e) {
774
- return this.rawGetPointee && (e = this.rawGetPointee(e)), e;
750
+ var zr = () => {
751
+ Object.assign(Tt.prototype, {
752
+ getPointee(t) {
753
+ return this.rawGetPointee && (t = this.rawGetPointee(t)), t;
775
754
  },
776
- destructor(e) {
777
- var t;
778
- (t = this.rawDestructor) === null || t === void 0 || t.call(this, e);
755
+ destructor(t) {
756
+ var e;
757
+ (e = this.rawDestructor) === null || e === void 0 || e.call(this, t);
779
758
  },
780
- argPackAdvance: k,
781
- readValueFromPointer: lt,
782
- fromWireType: Ur
759
+ readValueFromPointer: it,
760
+ fromWireType: Nr
783
761
  });
784
762
  };
785
- function Ot(e, t, r, n, a, i, u, s, c, d, p) {
786
- this.name = e, this.registeredClass = t, this.isReference = r, this.isConst = n, this.isSmartPointer = a, this.pointeeType = i, this.sharingPolicy = u, this.rawGetPointee = s, this.rawConstructor = c, this.rawShare = d, this.rawDestructor = p, !a && t.baseClass === void 0 ? n ? (this.toWireType = Fr, this.destructorFunction = null) : (this.toWireType = Rr, this.destructorFunction = null) : this.toWireType = jr;
787
- }
788
- var pe = (e, t, r) => {
789
- f.hasOwnProperty(e) || Pt("Replacing nonexistent public symbol"), f[e].overloadTable !== void 0 && r !== void 0 ? f[e].overloadTable[r] = t : (f[e] = t, f[e].argCount = r);
790
- }, ve = [], ye, w = (e) => {
791
- var t = ve[e];
792
- return t || (ve[e] = t = ye.get(e)), t;
793
- }, kr = function(e, t) {
763
+ function Tt(t, e, r, n, a, i, s, u, c, d, p) {
764
+ this.name = t, this.registeredClass = e, this.isReference = r, this.isConst = n, this.isSmartPointer = a, this.pointeeType = i, this.sharingPolicy = s, this.rawGetPointee = u, this.rawConstructor = c, this.rawShare = d, this.rawDestructor = p, !a && e.baseClass === void 0 ? n ? (this.toWireType = Br, this.destructorFunction = null) : (this.toWireType = Vr, this.destructorFunction = null) : this.toWireType = Ur;
765
+ }
766
+ var he = (t, e, r) => {
767
+ f.hasOwnProperty(t) || $t("Replacing nonexistent public symbol"), f[t].overloadTable !== void 0 && r !== void 0 ? f[t].overloadTable[r] = e : (f[t] = e, f[t].argCount = r);
768
+ }, N = {}, Gr = (t, e, r) => {
769
+ t = t.replace(/p/g, "i");
770
+ var n = N[t];
771
+ return n(e, ...r);
772
+ }, de = [], $ = (t) => {
773
+ var e = de[t];
774
+ return e || (de[t] = e = Fe.get(t)), e;
775
+ }, Xr = function(t, e) {
794
776
  let r = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : [];
795
- if (e.includes("j"))
796
- return dynCallLegacy(e, t, r);
797
- var n = w(t), a = n(...r);
777
+ if (t.includes("j"))
778
+ return Gr(t, e, r);
779
+ var n = $(e), a = n(...r);
798
780
  return a;
799
- }, Hr = function(e, t) {
781
+ }, qr = function(t, e) {
800
782
  let r = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : !1;
801
783
  return function() {
802
784
  for (var n = arguments.length, a = new Array(n), i = 0; i < n; i++)
803
785
  a[i] = arguments[i];
804
- return kr(e, t, a, r);
786
+ return Xr(t, e, a, r);
805
787
  };
806
- }, W = function(e, t) {
807
- e = F(e);
788
+ }, L = function(t, e) {
789
+ t = F(t);
808
790
  function r() {
809
- if (e.includes("j"))
810
- return Hr(e, t);
811
- var a = w(t);
791
+ if (t.includes("j"))
792
+ return qr(t, e);
793
+ var a = $(e);
812
794
  return a;
813
795
  }
814
796
  var n = r();
815
- return typeof n != "function" && T(`unknown function pointer with signature ${e}: ${t}`), n;
797
+ return typeof n != "function" && C(`unknown function pointer with signature ${t}: ${e}`), n;
816
798
  };
817
- class Nr extends Error {
799
+ class Yr extends Error {
818
800
  }
819
- var me = (e) => {
820
- var t = zn(e), r = F(t);
821
- return tt(t), r;
822
- }, xt = (e, t) => {
801
+ var pe = (t) => {
802
+ var e = Ee(t), r = F(e);
803
+ return z(e), r;
804
+ }, Et = (t, e) => {
823
805
  var r = [], n = {};
824
806
  function a(i) {
825
807
  if (!n[i] && !Q[i]) {
826
- if (Tt[i]) {
827
- Tt[i].forEach(a);
808
+ if (wt[i]) {
809
+ wt[i].forEach(a);
828
810
  return;
829
811
  }
830
812
  r.push(i), n[i] = !0;
831
813
  }
832
814
  }
833
- throw t.forEach(a), new Nr(`${e}: ` + r.map(me).join([", "]));
834
- }, zr = (e, t, r, n, a, i, u, s, c, d, p, v, $) => {
835
- p = F(p), i = W(a, i), s && (s = W(u, s)), d && (d = W(c, d)), $ = W(v, $);
836
- var b = Ir(p);
837
- de(b, function() {
838
- xt(`Cannot construct ${p} due to unbound types`, [n]);
839
- }), J([e, t, r], n ? [n] : [], (E) => {
840
- E = E[0];
841
- var S, A;
842
- n ? (S = E.registeredClass, A = S.instancePrototype) : A = _t.prototype;
843
- var D = kt(p, function() {
844
- if (Object.getPrototypeOf(this) !== N)
845
- throw new ft(`Use 'new' to construct ${p}`);
815
+ throw e.forEach(a), new Yr(`${t}: ` + r.map(pe).join([", "]));
816
+ }, Zr = (t, e, r, n, a, i, s, u, c, d, p, v, y) => {
817
+ p = F(p), i = L(a, i), u && (u = L(s, u)), d && (d = L(c, d)), y = L(v, y);
818
+ var T = Lr(p);
819
+ le(T, function() {
820
+ Et(`Cannot construct ${p} due to unbound types`, [n]);
821
+ }), J([t, e, r], n ? [n] : [], (S) => {
822
+ S = S[0];
823
+ var x, E;
824
+ n ? (x = S.registeredClass, E = x.instancePrototype) : E = bt.prototype;
825
+ var O = Ut(p, function() {
826
+ if (Object.getPrototypeOf(this) !== G)
827
+ throw new st(`Use 'new' to construct ${p}`);
846
828
  if (R.constructor_body === void 0)
847
- throw new ft(`${p} has no accessible constructor`);
848
- for (var Se = arguments.length, St = new Array(Se), Dt = 0; Dt < Se; Dt++)
849
- St[Dt] = arguments[Dt];
850
- var De = R.constructor_body[St.length];
851
- if (De === void 0)
852
- throw new ft(`Tried to invoke ctor of ${p} with invalid number of parameters (${St.length}) - expected (${Object.keys(R.constructor_body).toString()}) parameters instead!`);
853
- return De.apply(this, St);
854
- }), N = Object.create(A, {
829
+ throw new st(`${p} has no accessible constructor`);
830
+ for (var je = arguments.length, _t = new Array(je), xt = 0; xt < je; xt++)
831
+ _t[xt] = arguments[xt];
832
+ var Be = R.constructor_body[_t.length];
833
+ if (Be === void 0)
834
+ throw new st(`Tried to invoke ctor of ${p} with invalid number of parameters (${_t.length}) - expected (${Object.keys(R.constructor_body).toString()}) parameters instead!`);
835
+ return Be.apply(this, _t);
836
+ }), G = Object.create(E, {
855
837
  constructor: {
856
- value: D
838
+ value: O
857
839
  }
858
840
  });
859
- D.prototype = N;
860
- var R = new Mr(p, D, N, $, S, i, s, d);
841
+ O.prototype = G;
842
+ var R = new jr(p, O, G, y, x, i, u, d);
861
843
  if (R.baseClass) {
862
- var L, At;
863
- (At = (L = R.baseClass).__derivedClasses) !== null && At !== void 0 || (L.__derivedClasses = []), R.baseClass.__derivedClasses.push(R);
844
+ var k, Ot;
845
+ (Ot = (k = R.baseClass).__derivedClasses) !== null && Ot !== void 0 || (k.__derivedClasses = []), R.baseClass.__derivedClasses.push(R);
864
846
  }
865
- var La = new Ot(p, R, !0, !1, !1), xe = new Ot(p + "*", R, !1, !1, !1), Ae = new Ot(p + " const*", R, !1, !0, !1);
866
- return le[e] = {
867
- pointerType: xe,
868
- constPointerType: Ae
869
- }, pe(b, D), [La, xe, Ae];
847
+ var Da = new Tt(p, R, !0, !1, !1), Re = new Tt(p + "*", R, !1, !1, !1), Le = new Tt(p + " const*", R, !1, !0, !1);
848
+ return ue[t] = {
849
+ pointerType: Re,
850
+ constPointerType: Le
851
+ }, he(T, O), [Da, Re, Le];
870
852
  });
871
- }, zt = (e, t) => {
872
- for (var r = [], n = 0; n < e; n++)
873
- r.push(P[t + n * 4 >> 2]);
853
+ }, Ht = (t, e) => {
854
+ for (var r = [], n = 0; n < t; n++)
855
+ r.push(P[e + n * 4 >> 2]);
874
856
  return r;
875
857
  };
876
- function Gr(e) {
877
- for (var t = 1; t < e.length; ++t)
878
- if (e[t] !== null && e[t].destructorFunction === void 0)
858
+ function Qr(t) {
859
+ for (var e = 1; e < t.length; ++e)
860
+ if (t[e] !== null && t[e].destructorFunction === void 0)
879
861
  return !0;
880
862
  return !1;
881
863
  }
882
- function Gt(e, t, r, n, a, i) {
883
- var u = t.length;
884
- u < 2 && T("argTypes array size mismatch! Must at least get return value and 'this' types!");
885
- var s = t[1] !== null && r !== null, c = Gr(t), d = t[0].name !== "void", p = u - 2, v = new Array(p), $ = [], b = [], E = function() {
886
- b.length = 0;
887
- var S;
888
- $.length = s ? 2 : 1, $[0] = a, s && (S = t[1].toWireType(b, this), $[1] = S);
889
- for (var A = 0; A < p; ++A)
890
- v[A] = t[A + 2].toWireType(b, A < 0 || arguments.length <= A ? void 0 : arguments[A]), $.push(v[A]);
891
- var D = n(...$);
892
- function N(R) {
864
+ function kt(t, e, r, n, a, i) {
865
+ var s = e.length;
866
+ s < 2 && C("argTypes array size mismatch! Must at least get return value and 'this' types!");
867
+ var u = e[1] !== null && r !== null, c = Qr(e), d = !e[0].isVoid, p = s - 2, v = new Array(p), y = [], T = [], S = function() {
868
+ T.length = 0;
869
+ var x;
870
+ y.length = u ? 2 : 1, y[0] = a, u && (x = e[1].toWireType(T, this), y[1] = x);
871
+ for (var E = 0; E < p; ++E)
872
+ v[E] = e[E + 2].toWireType(T, E < 0 || arguments.length <= E ? void 0 : arguments[E]), y.push(v[E]);
873
+ var O = n(...y);
874
+ function G(R) {
893
875
  if (c)
894
- Wt(b);
876
+ Lt(T);
895
877
  else
896
- for (var L = s ? 1 : 2; L < t.length; L++) {
897
- var At = L === 1 ? S : v[L - 2];
898
- t[L].destructorFunction !== null && t[L].destructorFunction(At);
878
+ for (var k = u ? 1 : 2; k < e.length; k++) {
879
+ var Ot = k === 1 ? x : v[k - 2];
880
+ e[k].destructorFunction !== null && e[k].destructorFunction(Ot);
899
881
  }
900
882
  if (d)
901
- return t[0].fromWireType(R);
883
+ return e[0].fromWireType(R);
902
884
  }
903
- return N(D);
885
+ return G(O);
904
886
  };
905
- return kt(e, E);
906
- }
907
- var Xr = (e, t, r, n, a, i) => {
908
- var u = zt(t, r);
909
- a = W(n, a), J([], [e], (s) => {
910
- s = s[0];
911
- var c = `constructor ${s.name}`;
912
- if (s.registeredClass.constructor_body === void 0 && (s.registeredClass.constructor_body = []), s.registeredClass.constructor_body[t - 1] !== void 0)
913
- throw new ft(`Cannot register multiple constructors with identical number of parameters (${t - 1}) for class '${s.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`);
914
- return s.registeredClass.constructor_body[t - 1] = () => {
915
- xt(`Cannot construct ${s.name} due to unbound types`, u);
916
- }, J([], u, (d) => (d.splice(1, 0, null), s.registeredClass.constructor_body[t - 1] = Gt(c, d, null, a, i), [])), [];
887
+ return Ut(t, S);
888
+ }
889
+ var Jr = (t, e, r, n, a, i) => {
890
+ var s = Ht(e, r);
891
+ a = L(n, a), J([], [t], (u) => {
892
+ u = u[0];
893
+ var c = `constructor ${u.name}`;
894
+ if (u.registeredClass.constructor_body === void 0 && (u.registeredClass.constructor_body = []), u.registeredClass.constructor_body[e - 1] !== void 0)
895
+ throw new st(`Cannot register multiple constructors with identical number of parameters (${e - 1}) for class '${u.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`);
896
+ return u.registeredClass.constructor_body[e - 1] = () => {
897
+ Et(`Cannot construct ${u.name} due to unbound types`, s);
898
+ }, J([], s, (d) => (d.splice(1, 0, null), u.registeredClass.constructor_body[e - 1] = kt(c, d, null, a, i), [])), [];
917
899
  });
918
- }, ge = (e) => {
919
- e = e.trim();
920
- const t = e.indexOf("(");
921
- return t === -1 ? e : e.slice(0, t);
922
- }, qr = (e, t, r, n, a, i, u, s, c, d) => {
923
- var p = zt(r, n);
924
- t = F(t), t = ge(t), i = W(a, i), J([], [e], (v) => {
900
+ }, ve = (t) => {
901
+ t = t.trim();
902
+ const e = t.indexOf("(");
903
+ return e === -1 ? t : t.slice(0, e);
904
+ }, Kr = (t, e, r, n, a, i, s, u, c, d) => {
905
+ var p = Ht(r, n);
906
+ e = F(e), e = ve(e), i = L(a, i), J([], [t], (v) => {
925
907
  v = v[0];
926
- var $ = `${v.name}.${t}`;
927
- t.startsWith("@@") && (t = Symbol[t.substring(2)]), s && v.registeredClass.pureVirtualFunctions.push(t);
928
- function b() {
929
- xt(`Cannot call ${$} due to unbound types`, p);
908
+ var y = `${v.name}.${e}`;
909
+ e.startsWith("@@") && (e = Symbol[e.substring(2)]), u && v.registeredClass.pureVirtualFunctions.push(e);
910
+ function T() {
911
+ Et(`Cannot call ${y} due to unbound types`, p);
930
912
  }
931
- var E = v.registeredClass.instancePrototype, S = E[t];
932
- return S === void 0 || S.overloadTable === void 0 && S.className !== v.name && S.argCount === r - 2 ? (b.argCount = r - 2, b.className = v.name, E[t] = b) : (fe(E, t, $), E[t].overloadTable[r - 2] = b), J([], p, (A) => {
933
- var D = Gt($, A, v, i, u);
934
- return E[t].overloadTable === void 0 ? (D.argCount = r - 2, E[t] = D) : E[t].overloadTable[r - 2] = D, [];
913
+ var S = v.registeredClass.instancePrototype, x = S[e];
914
+ return x === void 0 || x.overloadTable === void 0 && x.className !== v.name && x.argCount === r - 2 ? (T.argCount = r - 2, T.className = v.name, S[e] = T) : (ce(S, e, y), S[e].overloadTable[r - 2] = T), J([], p, (E) => {
915
+ var O = kt(y, E, v, i, s);
916
+ return S[e].overloadTable === void 0 ? (O.argCount = r - 2, S[e] = O) : S[e].overloadTable[r - 2] = O, [];
935
917
  }), [];
936
918
  });
937
- }, we = [], K = [0, 1, , 1, null, 1, !0, 1, !1, 1], Xt = (e) => {
938
- e > 9 && --K[e + 1] === 0 && (K[e] = void 0, we.push(e));
939
- }, H = {
940
- toValue: (e) => (e || T(`Cannot use deleted val. handle = ${e}`), K[e]),
941
- toHandle: (e) => {
942
- switch (e) {
919
+ }, ye = [], K = [0, 1, , 1, null, 1, !0, 1, !1, 1], Nt = (t) => {
920
+ t > 9 && --K[t + 1] === 0 && (K[t] = void 0, ye.push(t));
921
+ }, B = {
922
+ toValue: (t) => (t || C(`Cannot use deleted val. handle = ${t}`), K[t]),
923
+ toHandle: (t) => {
924
+ switch (t) {
943
925
  case void 0:
944
926
  return 2;
945
927
  case null:
@@ -949,841 +931,802 @@ var Kt = async function(o = {}) {
949
931
  case !1:
950
932
  return 8;
951
933
  default: {
952
- const t = we.pop() || K.length;
953
- return K[t] = e, K[t + 1] = 1, t;
934
+ const e = ye.pop() || K.length;
935
+ return K[e] = t, K[e + 1] = 1, e;
954
936
  }
955
937
  }
956
938
  }
957
- }, $e = {
939
+ }, me = {
958
940
  name: "emscripten::val",
959
- fromWireType: (e) => {
960
- var t = H.toValue(e);
961
- return Xt(e), t;
941
+ fromWireType: (t) => {
942
+ var e = B.toValue(t);
943
+ return Nt(t), e;
962
944
  },
963
- toWireType: (e, t) => H.toHandle(t),
964
- argPackAdvance: k,
965
- readValueFromPointer: lt,
945
+ toWireType: (t, e) => B.toHandle(e),
946
+ readValueFromPointer: it,
966
947
  destructorFunction: null
967
- }, Yr = (e) => U(e, $e), Zr = (e, t) => {
968
- switch (t) {
948
+ }, tn = (t) => j(t, me), en = (t, e) => {
949
+ switch (e) {
969
950
  case 4:
970
951
  return function(r) {
971
- return this.fromWireType(ee[r >> 2]);
952
+ return this.fromWireType(Kt[r >> 2]);
972
953
  };
973
954
  case 8:
974
955
  return function(r) {
975
- return this.fromWireType(re[r >> 3]);
956
+ return this.fromWireType(te[r >> 3]);
976
957
  };
977
958
  default:
978
- throw new TypeError(`invalid float width (${t}): ${e}`);
959
+ throw new TypeError(`invalid float width (${e}): ${t}`);
979
960
  }
980
- }, Qr = (e, t, r) => {
981
- t = F(t), U(e, {
982
- name: t,
961
+ }, rn = (t, e, r) => {
962
+ e = F(e), j(t, {
963
+ name: e,
983
964
  fromWireType: (n) => n,
984
965
  toWireType: (n, a) => a,
985
- argPackAdvance: k,
986
- readValueFromPointer: Zr(t, r),
966
+ readValueFromPointer: en(e, r),
987
967
  destructorFunction: null
988
968
  });
989
- }, Jr = (e, t, r, n, a, i, u, s) => {
990
- var c = zt(t, r);
991
- e = F(e), e = ge(e), a = W(n, a), de(e, function() {
992
- xt(`Cannot call ${e} due to unbound types`, c);
993
- }, t - 1), J([], c, (d) => {
969
+ }, nn = (t, e, r, n, a, i, s, u) => {
970
+ var c = Ht(e, r);
971
+ t = F(t), t = ve(t), a = L(n, a), le(t, function() {
972
+ Et(`Cannot call ${t} due to unbound types`, c);
973
+ }, e - 1), J([], c, (d) => {
994
974
  var p = [d[0], null].concat(d.slice(1));
995
- return pe(e, Gt(e, p, null, a, i), t - 1), [];
975
+ return he(t, kt(t, p, null, a, i), e - 1), [];
996
976
  });
997
- }, Kr = (e, t, r) => {
998
- switch (t) {
977
+ }, an = (t, e, r) => {
978
+ switch (e) {
999
979
  case 1:
1000
- return r ? (n) => Y[n] : (n) => B[n];
980
+ return r ? (n) => Z[n] : (n) => W[n];
1001
981
  case 2:
1002
- return r ? (n) => mt[n >> 1] : (n) => rt[n >> 1];
982
+ return r ? (n) => dt[n >> 1] : (n) => at[n >> 1];
1003
983
  case 4:
1004
- return r ? (n) => nt[n >> 2] : (n) => P[n >> 2];
984
+ return r ? (n) => ot[n >> 2] : (n) => P[n >> 2];
1005
985
  default:
1006
- throw new TypeError(`invalid integer width (${t}): ${e}`);
986
+ throw new TypeError(`invalid integer width (${e}): ${t}`);
1007
987
  }
1008
- }, tn = (e, t, r, n, a) => {
1009
- t = F(t);
988
+ }, on = (t, e, r, n, a) => {
989
+ e = F(e);
1010
990
  const i = n === 0;
1011
- let u = (c) => c;
991
+ let s = (c) => c;
1012
992
  if (i) {
1013
- var s = 32 - 8 * r;
1014
- u = (c) => c << s >>> s, a = u(a);
993
+ var u = 32 - 8 * r;
994
+ s = (c) => c << u >>> u, a = s(a);
1015
995
  }
1016
- U(e, {
1017
- name: t,
1018
- fromWireType: u,
996
+ j(t, {
997
+ name: e,
998
+ fromWireType: s,
1019
999
  toWireType: (c, d) => d,
1020
- argPackAdvance: k,
1021
- readValueFromPointer: Kr(t, r, n !== 0),
1000
+ readValueFromPointer: an(e, r, n !== 0),
1022
1001
  destructorFunction: null
1023
1002
  });
1024
- }, en = (e, t, r) => {
1025
- var n = [Int8Array, Uint8Array, Int16Array, Uint16Array, Int32Array, Uint32Array, Float32Array, Float64Array], a = n[t];
1026
- function i(u) {
1027
- var s = P[u >> 2], c = P[u + 4 >> 2];
1028
- return new a(Y.buffer, c, s);
1003
+ }, sn = (t, e, r) => {
1004
+ var n = [Int8Array, Uint8Array, Int16Array, Uint16Array, Int32Array, Uint32Array, Float32Array, Float64Array], a = n[e];
1005
+ function i(s) {
1006
+ var u = P[s >> 2], c = P[s + 4 >> 2];
1007
+ return new a(Z.buffer, c, u);
1029
1008
  }
1030
- r = F(r), U(e, {
1009
+ r = F(r), j(t, {
1031
1010
  name: r,
1032
1011
  fromWireType: i,
1033
- argPackAdvance: k,
1034
1012
  readValueFromPointer: i
1035
1013
  }, {
1036
1014
  ignoreDuplicateRegistrations: !0
1037
1015
  });
1038
- }, rn = Object.assign({
1016
+ }, un = Object.assign({
1039
1017
  optional: !0
1040
- }, $e), nn = (e, t) => {
1041
- U(e, rn);
1042
- }, an = (e, t, r, n) => {
1018
+ }, me), cn = (t, e) => {
1019
+ j(t, un);
1020
+ }, ln = (t, e, r, n) => {
1043
1021
  if (!(n > 0)) return 0;
1044
- for (var a = r, i = r + n - 1, u = 0; u < e.length; ++u) {
1045
- var s = e.charCodeAt(u);
1046
- if (s >= 55296 && s <= 57343) {
1047
- var c = e.charCodeAt(++u);
1048
- s = 65536 + ((s & 1023) << 10) | c & 1023;
1049
- }
1050
- if (s <= 127) {
1022
+ for (var a = r, i = r + n - 1, s = 0; s < t.length; ++s) {
1023
+ var u = t.codePointAt(s);
1024
+ if (u <= 127) {
1051
1025
  if (r >= i) break;
1052
- t[r++] = s;
1053
- } else if (s <= 2047) {
1026
+ e[r++] = u;
1027
+ } else if (u <= 2047) {
1054
1028
  if (r + 1 >= i) break;
1055
- t[r++] = 192 | s >> 6, t[r++] = 128 | s & 63;
1056
- } else if (s <= 65535) {
1029
+ e[r++] = 192 | u >> 6, e[r++] = 128 | u & 63;
1030
+ } else if (u <= 65535) {
1057
1031
  if (r + 2 >= i) break;
1058
- t[r++] = 224 | s >> 12, t[r++] = 128 | s >> 6 & 63, t[r++] = 128 | s & 63;
1032
+ e[r++] = 224 | u >> 12, e[r++] = 128 | u >> 6 & 63, e[r++] = 128 | u & 63;
1059
1033
  } else {
1060
1034
  if (r + 3 >= i) break;
1061
- t[r++] = 240 | s >> 18, t[r++] = 128 | s >> 12 & 63, t[r++] = 128 | s >> 6 & 63, t[r++] = 128 | s & 63;
1035
+ e[r++] = 240 | u >> 18, e[r++] = 128 | u >> 12 & 63, e[r++] = 128 | u >> 6 & 63, e[r++] = 128 | u & 63, s++;
1062
1036
  }
1063
1037
  }
1064
- return t[r] = 0, r - a;
1065
- }, ot = (e, t, r) => an(e, B, t, r), be = (e) => {
1066
- for (var t = 0, r = 0; r < e.length; ++r) {
1067
- var n = e.charCodeAt(r);
1068
- n <= 127 ? t++ : n <= 2047 ? t += 2 : n >= 55296 && n <= 57343 ? (t += 4, ++r) : t += 3;
1038
+ return e[r] = 0, r - a;
1039
+ }, rt = (t, e, r) => ln(t, W, e, r), ge = (t) => {
1040
+ for (var e = 0, r = 0; r < t.length; ++r) {
1041
+ var n = t.charCodeAt(r);
1042
+ n <= 127 ? e++ : n <= 2047 ? e += 2 : n >= 55296 && n <= 57343 ? (e += 4, ++r) : e += 3;
1069
1043
  }
1070
- return t;
1071
- }, Ce = typeof TextDecoder < "u" ? new TextDecoder() : void 0, Te = function(e) {
1072
- let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0, r = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : NaN;
1073
- for (var n = t + r, a = t; e[a] && !(a >= n); ) ++a;
1074
- if (a - t > 16 && e.buffer && Ce)
1075
- return Ce.decode(e.subarray(t, a));
1076
- for (var i = ""; t < a; ) {
1077
- var u = e[t++];
1078
- if (!(u & 128)) {
1079
- i += String.fromCharCode(u);
1044
+ return e;
1045
+ }, we = globalThis.TextDecoder && new TextDecoder(), $e = (t, e, r, n) => {
1046
+ var a = e + r;
1047
+ if (n) return a;
1048
+ for (; t[e] && !(e >= a); ) ++e;
1049
+ return e;
1050
+ }, be = function(t) {
1051
+ let e = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0, r = arguments.length > 2 ? arguments[2] : void 0, n = arguments.length > 3 ? arguments[3] : void 0;
1052
+ var a = $e(t, e, r, n);
1053
+ if (a - e > 16 && t.buffer && we)
1054
+ return we.decode(t.subarray(e, a));
1055
+ for (var i = ""; e < a; ) {
1056
+ var s = t[e++];
1057
+ if (!(s & 128)) {
1058
+ i += String.fromCharCode(s);
1080
1059
  continue;
1081
1060
  }
1082
- var s = e[t++] & 63;
1083
- if ((u & 224) == 192) {
1084
- i += String.fromCharCode((u & 31) << 6 | s);
1061
+ var u = t[e++] & 63;
1062
+ if ((s & 224) == 192) {
1063
+ i += String.fromCharCode((s & 31) << 6 | u);
1085
1064
  continue;
1086
1065
  }
1087
- var c = e[t++] & 63;
1088
- if ((u & 240) == 224 ? u = (u & 15) << 12 | s << 6 | c : u = (u & 7) << 18 | s << 12 | c << 6 | e[t++] & 63, u < 65536)
1089
- i += String.fromCharCode(u);
1066
+ var c = t[e++] & 63;
1067
+ if ((s & 240) == 224 ? s = (s & 15) << 12 | u << 6 | c : s = (s & 7) << 18 | u << 12 | c << 6 | t[e++] & 63, s < 65536)
1068
+ i += String.fromCharCode(s);
1090
1069
  else {
1091
- var d = u - 65536;
1070
+ var d = s - 65536;
1092
1071
  i += String.fromCharCode(55296 | d >> 10, 56320 | d & 1023);
1093
1072
  }
1094
1073
  }
1095
1074
  return i;
1096
- }, on = (e, t) => e ? Te(B, e, t) : "", sn = (e, t) => {
1097
- t = F(t), U(e, {
1098
- name: t,
1075
+ }, fn = (t, e, r) => t ? be(W, t, e, r) : "", hn = (t, e) => {
1076
+ e = F(e), j(t, {
1077
+ name: e,
1099
1078
  fromWireType(r) {
1100
- for (var n = P[r >> 2], a = r + 4, i, s, u = a, s = 0; s <= n; ++s) {
1101
- var c = a + s;
1102
- if (s == n || B[c] == 0) {
1103
- var d = c - u, p = on(u, d);
1104
- i === void 0 ? i = p : (i += "\0", i += p), u = c + 1;
1105
- }
1106
- }
1107
- return tt(r), i;
1079
+ var n = P[r >> 2], a = r + 4, i;
1080
+ return i = fn(a, n, !0), z(r), i;
1108
1081
  },
1109
1082
  toWireType(r, n) {
1110
1083
  n instanceof ArrayBuffer && (n = new Uint8Array(n));
1111
1084
  var a, i = typeof n == "string";
1112
- i || ArrayBuffer.isView(n) && n.BYTES_PER_ELEMENT == 1 || T("Cannot pass non-string to std::string"), i ? a = be(n) : a = n.length;
1113
- var u = Oe(4 + a + 1), s = u + 4;
1114
- return P[u >> 2] = a, i ? ot(n, s, a + 1) : B.set(n, s), r !== null && r.push(tt, u), u;
1085
+ i || ArrayBuffer.isView(n) && n.BYTES_PER_ELEMENT == 1 || C("Cannot pass non-string to std::string"), i ? a = ge(n) : a = n.length;
1086
+ var s = Xt(4 + a + 1), u = s + 4;
1087
+ return P[s >> 2] = a, i ? rt(n, u, a + 1) : W.set(n, u), r !== null && r.push(z, s), s;
1115
1088
  },
1116
- argPackAdvance: k,
1117
- readValueFromPointer: lt,
1089
+ readValueFromPointer: it,
1118
1090
  destructorFunction(r) {
1119
- tt(r);
1091
+ z(r);
1120
1092
  }
1121
1093
  });
1122
- }, Pe = typeof TextDecoder < "u" ? new TextDecoder("utf-16le") : void 0, un = (e, t) => {
1123
- for (var r = e >> 1, n = r + t / 2, a = r; !(a >= n) && rt[a]; ) ++a;
1124
- if (a - r > 16 && Pe) return Pe.decode(rt.subarray(r, a));
1125
- for (var i = "", u = r; !(u >= n); ++u) {
1126
- var s = rt[u];
1127
- if (s == 0) break;
1128
- i += String.fromCharCode(s);
1094
+ }, Ce = globalThis.TextDecoder ? new TextDecoder("utf-16le") : void 0, dn = (t, e, r) => {
1095
+ var n = t >> 1, a = $e(at, n, e / 2, r);
1096
+ if (a - n > 16 && Ce) return Ce.decode(at.subarray(n, a));
1097
+ for (var i = "", s = n; s < a; ++s) {
1098
+ var u = at[s];
1099
+ i += String.fromCharCode(u);
1129
1100
  }
1130
1101
  return i;
1131
- }, cn = (e, t, r) => {
1102
+ }, pn = (t, e, r) => {
1132
1103
  if (r != null || (r = 2147483647), r < 2) return 0;
1133
1104
  r -= 2;
1134
- for (var n = t, a = r < e.length * 2 ? r / 2 : e.length, i = 0; i < a; ++i) {
1135
- var u = e.charCodeAt(i);
1136
- mt[t >> 1] = u, t += 2;
1137
- }
1138
- return mt[t >> 1] = 0, t - n;
1139
- }, ln = (e) => e.length * 2, fn = (e, t) => {
1140
- for (var r = 0, n = ""; !(r >= t / 4); ) {
1141
- var a = nt[e + r * 4 >> 2];
1142
- if (a == 0) break;
1143
- if (++r, a >= 65536) {
1144
- var i = a - 65536;
1145
- n += String.fromCharCode(55296 | i >> 10, 56320 | i & 1023);
1146
- } else
1147
- n += String.fromCharCode(a);
1105
+ for (var n = e, a = r < t.length * 2 ? r / 2 : t.length, i = 0; i < a; ++i) {
1106
+ var s = t.charCodeAt(i);
1107
+ dt[e >> 1] = s, e += 2;
1108
+ }
1109
+ return dt[e >> 1] = 0, e - n;
1110
+ }, vn = (t) => t.length * 2, yn = (t, e, r) => {
1111
+ for (var n = "", a = t >> 2, i = 0; !(i >= e / 4); i++) {
1112
+ var s = P[a + i];
1113
+ if (!s && !r) break;
1114
+ n += String.fromCodePoint(s);
1148
1115
  }
1149
1116
  return n;
1150
- }, dn = (e, t, r) => {
1117
+ }, mn = (t, e, r) => {
1151
1118
  if (r != null || (r = 2147483647), r < 4) return 0;
1152
- for (var n = t, a = n + r - 4, i = 0; i < e.length; ++i) {
1153
- var u = e.charCodeAt(i);
1154
- if (u >= 55296 && u <= 57343) {
1155
- var s = e.charCodeAt(++i);
1156
- u = 65536 + ((u & 1023) << 10) | s & 1023;
1157
- }
1158
- if (nt[t >> 2] = u, t += 4, t + 4 > a) break;
1119
+ for (var n = e, a = n + r - 4, i = 0; i < t.length; ++i) {
1120
+ var s = t.codePointAt(i);
1121
+ if (s > 65535 && i++, ot[e >> 2] = s, e += 4, e + 4 > a) break;
1159
1122
  }
1160
- return nt[t >> 2] = 0, t - n;
1161
- }, hn = (e) => {
1162
- for (var t = 0, r = 0; r < e.length; ++r) {
1163
- var n = e.charCodeAt(r);
1164
- n >= 55296 && n <= 57343 && ++r, t += 4;
1123
+ return ot[e >> 2] = 0, e - n;
1124
+ }, gn = (t) => {
1125
+ for (var e = 0, r = 0; r < t.length; ++r) {
1126
+ var n = t.codePointAt(r);
1127
+ n > 65535 && r++, e += 4;
1165
1128
  }
1166
- return t;
1167
- }, pn = (e, t, r) => {
1129
+ return e;
1130
+ }, wn = (t, e, r) => {
1168
1131
  r = F(r);
1169
- var n, a, i, u;
1170
- t === 2 ? (n = un, a = cn, u = ln, i = (s) => rt[s >> 1]) : t === 4 && (n = fn, a = dn, u = hn, i = (s) => P[s >> 2]), U(e, {
1132
+ var n, a, i;
1133
+ e === 2 ? (n = dn, a = pn, i = vn) : (n = yn, a = mn, i = gn), j(t, {
1171
1134
  name: r,
1172
1135
  fromWireType: (s) => {
1173
- for (var c = P[s >> 2], d, p = s + 4, v = 0; v <= c; ++v) {
1174
- var $ = s + 4 + v * t;
1175
- if (v == c || i($) == 0) {
1176
- var b = $ - p, E = n(p, b);
1177
- d === void 0 ? d = E : (d += "\0", d += E), p = $ + t;
1178
- }
1179
- }
1180
- return tt(s), d;
1136
+ var u = P[s >> 2], c = n(s + 4, u * e, !0);
1137
+ return z(s), c;
1181
1138
  },
1182
- toWireType: (s, c) => {
1183
- typeof c != "string" && T(`Cannot pass non-string to C++ string type ${r}`);
1184
- var d = u(c), p = Oe(4 + d + t);
1185
- return P[p >> 2] = d / t, a(c, p + 4, d + t), s !== null && s.push(tt, p), p;
1139
+ toWireType: (s, u) => {
1140
+ typeof u != "string" && C(`Cannot pass non-string to C++ string type ${r}`);
1141
+ var c = i(u), d = Xt(4 + c + e);
1142
+ return P[d >> 2] = c / e, a(u, d + 4, c + e), s !== null && s.push(z, d), d;
1186
1143
  },
1187
- argPackAdvance: k,
1188
- readValueFromPointer: lt,
1144
+ readValueFromPointer: it,
1189
1145
  destructorFunction(s) {
1190
- tt(s);
1146
+ z(s);
1191
1147
  }
1192
1148
  });
1193
- }, vn = (e, t, r, n, a, i) => {
1194
- Ct[e] = {
1195
- name: F(t),
1196
- rawConstructor: W(r, n),
1197
- rawDestructor: W(a, i),
1149
+ }, $n = (t, e, r, n, a, i) => {
1150
+ gt[t] = {
1151
+ name: F(e),
1152
+ rawConstructor: L(r, n),
1153
+ rawDestructor: L(a, i),
1198
1154
  fields: []
1199
1155
  };
1200
- }, yn = (e, t, r, n, a, i, u, s, c, d) => {
1201
- Ct[e].fields.push({
1202
- fieldName: F(t),
1156
+ }, bn = (t, e, r, n, a, i, s, u, c, d) => {
1157
+ gt[t].fields.push({
1158
+ fieldName: F(e),
1203
1159
  getterReturnType: r,
1204
- getter: W(n, a),
1160
+ getter: L(n, a),
1205
1161
  getterContext: i,
1206
- setterArgumentType: u,
1207
- setter: W(s, c),
1162
+ setterArgumentType: s,
1163
+ setter: L(u, c),
1208
1164
  setterContext: d
1209
1165
  });
1210
- }, mn = (e, t) => {
1211
- t = F(t), U(e, {
1166
+ }, Cn = (t, e) => {
1167
+ e = F(e), j(t, {
1212
1168
  isVoid: !0,
1213
- name: t,
1214
- argPackAdvance: 0,
1169
+ name: e,
1215
1170
  fromWireType: () => {
1216
1171
  },
1217
1172
  toWireType: (r, n) => {
1218
1173
  }
1219
1174
  });
1220
- }, qt = [], gn = (e, t, r, n) => (e = qt[e], t = H.toValue(t), e(null, t, r, n)), wn = {}, $n = (e) => {
1221
- var t = wn[e];
1222
- return t === void 0 ? F(e) : t;
1223
- }, _e = () => {
1224
- if (typeof globalThis == "object")
1225
- return globalThis;
1226
- function e(t) {
1227
- t.$$$embind_global$$$ = t;
1228
- var r = typeof $$$embind_global$$$ == "object" && t.$$$embind_global$$$ == t;
1229
- return r || delete t.$$$embind_global$$$, r;
1230
- }
1231
- if (typeof $$$embind_global$$$ == "object" || (typeof global == "object" && e(global) ? $$$embind_global$$$ = global : typeof self == "object" && e(self) && ($$$embind_global$$$ = self), typeof $$$embind_global$$$ == "object"))
1232
- return $$$embind_global$$$;
1233
- throw Error("unable to get global object.");
1234
- }, bn = (e) => e === 0 ? H.toHandle(_e()) : (e = $n(e), H.toHandle(_e()[e])), Cn = (e) => {
1235
- var t = qt.length;
1236
- return qt.push(e), t;
1237
- }, Ee = (e, t) => {
1238
- var r = Q[e];
1239
- return r === void 0 && T(`${t} has unknown type ${me(e)}`), r;
1240
- }, Tn = (e, t) => {
1241
- for (var r = new Array(e), n = 0; n < e; ++n)
1242
- r[n] = Ee(P[t + n * 4 >> 2], `parameter ${n}`);
1175
+ }, zt = [], Tn = (t) => {
1176
+ var e = zt.length;
1177
+ return zt.push(t), e;
1178
+ }, En = (t, e) => {
1179
+ var r = Q[t];
1180
+ return r === void 0 && C(`${e} has unknown type ${pe(t)}`), r;
1181
+ }, Pn = (t, e) => {
1182
+ for (var r = new Array(t), n = 0; n < t; ++n)
1183
+ r[n] = En(P[e + n * 4 >> 2], `parameter ${n}`);
1243
1184
  return r;
1244
- }, Pn = (e, t, r) => {
1245
- var n = [], a = e.toWireType(n, r);
1246
- return n.length && (P[t >> 2] = H.toHandle(n)), a;
1247
- }, _n = Reflect.construct, En = (e, t, r) => {
1248
- var n = Tn(e, t), a = n.shift();
1249
- e--;
1250
- var i = new Array(e), u = (c, d, p, v) => {
1251
- for (var $ = 0, b = 0; b < e; ++b)
1252
- i[b] = n[b].readValueFromPointer(v + $), $ += n[b].argPackAdvance;
1253
- var E = r === 1 ? _n(d, i) : d.apply(c, i);
1254
- return Pn(a, p, E);
1255
- }, s = `methodCaller<(${n.map((c) => c.name).join(", ")}) => ${a.name}>`;
1256
- return Cn(kt(s, u));
1257
- }, On = (e) => {
1258
- e > 9 && (K[e + 1] += 1);
1259
- }, xn = (e) => {
1260
- var t = H.toValue(e);
1261
- Wt(t), Xt(e);
1262
- }, An = (e, t) => {
1263
- e = Ee(e, "_emval_take_value");
1264
- var r = e.readValueFromPointer(t);
1265
- return H.toHandle(r);
1266
- }, Sn = (e, t, r, n) => {
1267
- var a = (/* @__PURE__ */ new Date()).getFullYear(), i = new Date(a, 0, 1), u = new Date(a, 6, 1), s = i.getTimezoneOffset(), c = u.getTimezoneOffset(), d = Math.max(s, c);
1268
- P[e >> 2] = d * 60, nt[t >> 2] = +(s != c);
1269
- var p = (b) => {
1270
- var E = b >= 0 ? "-" : "+", S = Math.abs(b), A = String(Math.floor(S / 60)).padStart(2, "0"), D = String(S % 60).padStart(2, "0");
1271
- return `UTC${E}${A}${D}`;
1272
- }, v = p(s), $ = p(c);
1273
- c < s ? (ot(v, r, 17), ot($, n, 17)) : (ot(v, n, 17), ot($, r, 17));
1274
- }, Dn = () => 2147483648, In = (e, t) => Math.ceil(e / t) * t, Mn = (e) => {
1275
- var t = yt.buffer, r = (e - t.byteLength + 65535) / 65536 | 0;
1185
+ }, On = (t, e, r) => {
1186
+ var n = [], a = t(n, r);
1187
+ return n.length && (P[e >> 2] = B.toHandle(n)), a;
1188
+ }, _n = {}, Te = (t) => {
1189
+ var e = _n[t];
1190
+ return e === void 0 ? F(t) : e;
1191
+ }, xn = (t, e, r) => {
1192
+ var n = 8, [a, ...i] = Pn(t, e), s = a.toWireType.bind(a), u = i.map((v) => v.readValueFromPointer.bind(v));
1193
+ t--;
1194
+ var c = new Array(t), d = (v, y, T, S) => {
1195
+ for (var x = 0, E = 0; E < t; ++E)
1196
+ c[E] = u[E](S + x), x += n;
1197
+ var O;
1198
+ switch (r) {
1199
+ case 0:
1200
+ O = B.toValue(v).apply(null, c);
1201
+ break;
1202
+ case 2:
1203
+ O = Reflect.construct(B.toValue(v), c);
1204
+ break;
1205
+ case 3:
1206
+ O = c[0];
1207
+ break;
1208
+ case 1:
1209
+ O = B.toValue(v)[Te(y)](...c);
1210
+ break;
1211
+ }
1212
+ return On(s, T, O);
1213
+ }, p = `methodCaller<(${i.map((v) => v.name)}) => ${a.name}>`;
1214
+ return Tn(Ut(p, d));
1215
+ }, Sn = (t) => t ? (t = Te(t), B.toHandle(globalThis[t])) : B.toHandle(globalThis), In = (t) => {
1216
+ t > 9 && (K[t + 1] += 1);
1217
+ }, Dn = (t, e, r, n, a) => zt[t](e, r, n, a), Mn = (t) => {
1218
+ var e = B.toValue(t);
1219
+ Lt(e), Nt(t);
1220
+ }, An = (t, e, r, n) => {
1221
+ var a = (/* @__PURE__ */ new Date()).getFullYear(), i = new Date(a, 0, 1), s = new Date(a, 6, 1), u = i.getTimezoneOffset(), c = s.getTimezoneOffset(), d = Math.max(u, c);
1222
+ P[t >> 2] = d * 60, ot[e >> 2] = +(u != c);
1223
+ var p = (T) => {
1224
+ var S = T >= 0 ? "-" : "+", x = Math.abs(T), E = String(Math.floor(x / 60)).padStart(2, "0"), O = String(x % 60).padStart(2, "0");
1225
+ return `UTC${S}${E}${O}`;
1226
+ }, v = p(u), y = p(c);
1227
+ c < u ? (rt(v, r, 17), rt(y, n, 17)) : (rt(v, n, 17), rt(y, r, 17));
1228
+ }, Fn = () => 2147483648, Rn = (t, e) => Math.ceil(t / e) * e, Ln = (t) => {
1229
+ var e = Pt.buffer.byteLength, r = (t - e + 65535) / 65536 | 0;
1276
1230
  try {
1277
- return yt.grow(r), ne(), 1;
1231
+ return Pt.grow(r), re(), 1;
1278
1232
  } catch {
1279
1233
  }
1280
- }, Fn = (e) => {
1281
- var t = B.length;
1282
- e >>>= 0;
1283
- var r = Dn();
1284
- if (e > r)
1234
+ }, jn = (t) => {
1235
+ var e = W.length;
1236
+ t >>>= 0;
1237
+ var r = Fn();
1238
+ if (t > r)
1285
1239
  return !1;
1286
1240
  for (var n = 1; n <= 4; n *= 2) {
1287
- var a = t * (1 + 0.2 / n);
1288
- a = Math.min(a, e + 100663296);
1289
- var i = Math.min(r, In(Math.max(e, a), 65536)), u = Mn(i);
1290
- if (u)
1241
+ var a = e * (1 + 0.2 / n);
1242
+ a = Math.min(a, t + 100663296);
1243
+ var i = Math.min(r, Rn(Math.max(t, a), 65536)), s = Ln(i);
1244
+ if (s)
1291
1245
  return !0;
1292
1246
  }
1293
1247
  return !1;
1294
- }, Yt = {}, jn = () => z || "./this.program", ht = () => {
1295
- if (!ht.strings) {
1296
- var e = (typeof navigator == "object" && navigator.languages && navigator.languages[0] || "C").replace("-", "_") + ".UTF-8", t = {
1248
+ }, Gt = {}, Bn = () => _ || "./this.program", ct = () => {
1249
+ if (!ct.strings) {
1250
+ var t = (typeof navigator == "object" && navigator.language || "C").replace("-", "_") + ".UTF-8", e = {
1297
1251
  USER: "web_user",
1298
1252
  LOGNAME: "web_user",
1299
1253
  PATH: "/",
1300
1254
  PWD: "/",
1301
1255
  HOME: "/home/web_user",
1302
- LANG: e,
1303
- _: jn()
1256
+ LANG: t,
1257
+ _: Bn()
1304
1258
  };
1305
- for (var r in Yt)
1306
- Yt[r] === void 0 ? delete t[r] : t[r] = Yt[r];
1259
+ for (var r in Gt)
1260
+ Gt[r] === void 0 ? delete e[r] : e[r] = Gt[r];
1307
1261
  var n = [];
1308
- for (var r in t)
1309
- n.push(`${r}=${t[r]}`);
1310
- ht.strings = n;
1262
+ for (var r in e)
1263
+ n.push(`${r}=${e[r]}`);
1264
+ ct.strings = n;
1311
1265
  }
1312
- return ht.strings;
1313
- }, Rn = (e, t) => {
1266
+ return ct.strings;
1267
+ }, Un = (t, e) => {
1314
1268
  var r = 0, n = 0;
1315
- for (var a of ht()) {
1316
- var i = t + r;
1317
- P[e + n >> 2] = i, r += ot(a, i, 1 / 0) + 1, n += 4;
1269
+ for (var a of ct()) {
1270
+ var i = e + r;
1271
+ P[t + n >> 2] = i, r += rt(a, i, 1 / 0) + 1, n += 4;
1318
1272
  }
1319
1273
  return 0;
1320
- }, Ln = (e, t) => {
1321
- var r = ht();
1322
- P[e >> 2] = r.length;
1274
+ }, Vn = (t, e) => {
1275
+ var r = ct();
1276
+ P[t >> 2] = r.length;
1323
1277
  var n = 0;
1324
1278
  for (var a of r)
1325
- n += be(a) + 1;
1326
- return P[t >> 2] = n, 0;
1327
- }, Bn = (e) => 52;
1328
- function Wn(e, t, r, n, a) {
1279
+ n += ge(a) + 1;
1280
+ return P[e >> 2] = n, 0;
1281
+ }, Wn = (t) => 52;
1282
+ function Hn(t, e, r, n, a) {
1329
1283
  return 70;
1330
1284
  }
1331
- var Un = [null, [], []], Vn = (e, t) => {
1332
- var r = Un[e];
1333
- t === 0 || t === 10 ? ((e === 1 ? vt : G)(Te(r)), r.length = 0) : r.push(t);
1334
- }, kn = (e, t, r, n) => {
1285
+ var kn = [null, [], []], Nn = (t, e) => {
1286
+ var r = kn[t];
1287
+ e === 0 || e === 10 ? ((t === 1 ? nt : V)(be(r)), r.length = 0) : r.push(e);
1288
+ }, zn = (t, e, r, n) => {
1335
1289
  for (var a = 0, i = 0; i < r; i++) {
1336
- var u = P[t >> 2], s = P[t + 4 >> 2];
1337
- t += 8;
1338
- for (var c = 0; c < s; c++)
1339
- Vn(e, B[u + c]);
1340
- a += s;
1290
+ var s = P[e >> 2], u = P[e + 4 >> 2];
1291
+ e += 8;
1292
+ for (var c = 0; c < u; c++)
1293
+ Nn(t, W[s + c]);
1294
+ a += u;
1341
1295
  }
1342
1296
  return P[n >> 2] = a, 0;
1343
- }, Hn = (e) => e;
1344
- Pr(), Ar(), Vr(), f.noExitRuntime && f.noExitRuntime, f.print && (vt = f.print), f.printErr && (G = f.printErr), f.wasmBinary && (ut = f.wasmBinary), f.arguments && f.arguments, f.thisProgram && (z = f.thisProgram);
1345
- var Nn = {
1346
- s: fr,
1347
- w: dr,
1348
- a: hr,
1349
- j: pr,
1350
- m: vr,
1351
- P: yr,
1352
- p: mr,
1353
- ga: gr,
1354
- d: wr,
1355
- ba: $r,
1356
- ua: Cr,
1357
- aa: Tr,
1358
- pa: Er,
1359
- sa: zr,
1360
- ra: Xr,
1361
- H: qr,
1362
- na: Yr,
1363
- V: Qr,
1364
- W: Jr,
1365
- x: tn,
1366
- t: en,
1367
- ta: nn,
1368
- oa: sn,
1369
- Q: pn,
1370
- I: vn,
1371
- va: yn,
1372
- qa: mn,
1373
- da: gn,
1374
- wa: Xt,
1375
- D: bn,
1376
- ma: En,
1377
- X: On,
1378
- Y: xn,
1379
- U: An,
1380
- ca: Sn,
1381
- ha: Fn,
1382
- ea: Rn,
1383
- fa: Ln,
1384
- ia: Bn,
1385
- _: Wn,
1386
- S: kn,
1387
- K: Pa,
1388
- C: Ea,
1389
- M: na,
1390
- R: Ia,
1391
- q: $a,
1392
- b: ia,
1393
- E: Ta,
1394
- ka: xa,
1395
- c: sa,
1396
- ja: Aa,
1397
- h: ra,
1398
- i: fa,
1399
- r: va,
1400
- O: Ca,
1401
- v: ma,
1402
- F: wa,
1403
- L: ba,
1404
- z: Oa,
1405
- J: Ma,
1406
- $: Fa,
1407
- Z: ja,
1408
- k: ua,
1409
- f: ea,
1410
- e: oa,
1411
- g: aa,
1412
- N: Da,
1413
- l: la,
1414
- la: _a,
1415
- o: ya,
1416
- B: da,
1417
- u: ga,
1418
- T: pa,
1419
- A: Sa,
1420
- n: ca,
1421
- G: ha,
1422
- y: Hn
1423
- }, _ = await ur();
1424
- _.ya;
1425
- var zn = _.za, tt = f._free = _.Aa, Oe = f._malloc = _.Ca, Gn = _.Da, y = _.Ea, Xn = _.Fa, qn = _.Ga, Yn = _.Ha, Zn = _.Ia, Qn = _.Ja, Jn = _.Ka;
1426
- f.dynCall_viijii = _.La;
1427
- var Kn = f.dynCall_iiijj = _.Ma;
1428
- f.dynCall_jiji = _.Na;
1429
- var ta = f.dynCall_jiiii = _.Oa;
1430
- f.dynCall_iiiiij = _.Pa, f.dynCall_iiiiijj = _.Qa, f.dynCall_iiiiiijj = _.Ra;
1431
- function ea(e, t) {
1432
- var r = g();
1297
+ }, Gn = (t) => t;
1298
+ if (Ar(), zr(), f.noExitRuntime && f.noExitRuntime, f.print && (nt = f.print), f.printErr && (V = f.printErr), f.wasmBinary && (Y = f.wasmBinary), f.arguments && f.arguments, f.thisProgram && (_ = f.thisProgram), f.preInit)
1299
+ for (typeof f.preInit == "function" && (f.preInit = [f.preInit]); f.preInit.length > 0; )
1300
+ f.preInit.shift()();
1301
+ var Ee, z, Xt, Pe, m, Oe, _e, xe, Se, Ie, De, Me, Ae, Pt, Fe;
1302
+ function Xn(t) {
1303
+ Ee = t.ya, z = f._free = t.za, Xt = f._malloc = t.Ba, Pe = t.Ca, m = t.Da, Oe = t.Ea, _e = t.Fa, xe = t.Ga, Se = t.Ha, Ie = t.Ia, De = t.Ja, N.viijii = t.Ka, Me = N.iiijj = t.La, N.jiji = t.Ma, Ae = N.jiiii = t.Na, N.iiiiij = t.Oa, N.iiiiijj = t.Pa, N.iiiiiijj = t.Qa, Pt = t.wa, Fe = t.Aa;
1304
+ }
1305
+ var qn = {
1306
+ s: yr,
1307
+ w: mr,
1308
+ a: gr,
1309
+ j: wr,
1310
+ m: $r,
1311
+ Q: br,
1312
+ p: Cr,
1313
+ U: Tr,
1314
+ d: Er,
1315
+ ca: Pr,
1316
+ ta: _r,
1317
+ ba: xr,
1318
+ oa: Ir,
1319
+ ra: Zr,
1320
+ qa: Jr,
1321
+ H: Kr,
1322
+ ma: tn,
1323
+ X: rn,
1324
+ Y: nn,
1325
+ x: on,
1326
+ t: sn,
1327
+ sa: cn,
1328
+ na: hn,
1329
+ R: wn,
1330
+ I: $n,
1331
+ ua: bn,
1332
+ pa: Cn,
1333
+ N: xn,
1334
+ va: Nt,
1335
+ D: Sn,
1336
+ S: In,
1337
+ M: Dn,
1338
+ ia: Mn,
1339
+ da: An,
1340
+ ga: jn,
1341
+ ea: Un,
1342
+ fa: Vn,
1343
+ ha: Wn,
1344
+ $: Hn,
1345
+ V: zn,
1346
+ K: ma,
1347
+ C: $a,
1348
+ Z: ea,
1349
+ T: Oa,
1350
+ r: da,
1351
+ b: Kn,
1352
+ E: ya,
1353
+ ka: Ca,
1354
+ c: ra,
1355
+ ja: Ta,
1356
+ h: ta,
1357
+ i: oa,
1358
+ q: ca,
1359
+ P: va,
1360
+ v: fa,
1361
+ F: ha,
1362
+ L: pa,
1363
+ z: ba,
1364
+ J: _a,
1365
+ aa: xa,
1366
+ _: Sa,
1367
+ f: na,
1368
+ l: Yn,
1369
+ e: Jn,
1370
+ g: Qn,
1371
+ O: Pa,
1372
+ k: Zn,
1373
+ la: ga,
1374
+ o: la,
1375
+ B: ia,
1376
+ u: wa,
1377
+ W: ua,
1378
+ A: Ea,
1379
+ n: aa,
1380
+ G: sa,
1381
+ y: Gn
1382
+ };
1383
+ function Yn(t, e) {
1384
+ var r = w();
1433
1385
  try {
1434
- w(e)(t);
1386
+ $(t)(e);
1435
1387
  } catch (n) {
1436
- if (m(r), n !== n + 0) throw n;
1437
- y(1, 0);
1438
- }
1439
- }
1440
- function ra(e, t, r, n) {
1441
- var a = g();
1442
- try {
1443
- return w(e)(t, r, n);
1444
- } catch (i) {
1445
- if (m(a), i !== i + 0) throw i;
1446
- y(1, 0);
1388
+ if (g(r), n !== n + 0) throw n;
1389
+ m(1, 0);
1447
1390
  }
1448
1391
  }
1449
- function na(e, t, r, n, a) {
1450
- var i = g();
1392
+ function Zn(t, e, r, n, a) {
1393
+ var i = w();
1451
1394
  try {
1452
- return w(e)(t, r, n, a);
1453
- } catch (u) {
1454
- if (m(i), u !== u + 0) throw u;
1455
- y(1, 0);
1395
+ $(t)(e, r, n, a);
1396
+ } catch (s) {
1397
+ if (g(i), s !== s + 0) throw s;
1398
+ m(1, 0);
1456
1399
  }
1457
1400
  }
1458
- function aa(e, t, r, n) {
1459
- var a = g();
1401
+ function Qn(t, e, r, n) {
1402
+ var a = w();
1460
1403
  try {
1461
- w(e)(t, r, n);
1404
+ $(t)(e, r, n);
1462
1405
  } catch (i) {
1463
- if (m(a), i !== i + 0) throw i;
1464
- y(1, 0);
1406
+ if (g(a), i !== i + 0) throw i;
1407
+ m(1, 0);
1465
1408
  }
1466
1409
  }
1467
- function oa(e, t, r) {
1468
- var n = g();
1410
+ function Jn(t, e, r) {
1411
+ var n = w();
1469
1412
  try {
1470
- w(e)(t, r);
1413
+ $(t)(e, r);
1471
1414
  } catch (a) {
1472
- if (m(n), a !== a + 0) throw a;
1473
- y(1, 0);
1415
+ if (g(n), a !== a + 0) throw a;
1416
+ m(1, 0);
1474
1417
  }
1475
1418
  }
1476
- function ia(e, t) {
1477
- var r = g();
1419
+ function Kn(t, e) {
1420
+ var r = w();
1478
1421
  try {
1479
- return w(e)(t);
1422
+ return $(t)(e);
1480
1423
  } catch (n) {
1481
- if (m(r), n !== n + 0) throw n;
1482
- y(1, 0);
1424
+ if (g(r), n !== n + 0) throw n;
1425
+ m(1, 0);
1483
1426
  }
1484
1427
  }
1485
- function sa(e, t, r) {
1486
- var n = g();
1428
+ function ta(t, e, r, n) {
1429
+ var a = w();
1487
1430
  try {
1488
- return w(e)(t, r);
1489
- } catch (a) {
1490
- if (m(n), a !== a + 0) throw a;
1491
- y(1, 0);
1431
+ return $(t)(e, r, n);
1432
+ } catch (i) {
1433
+ if (g(a), i !== i + 0) throw i;
1434
+ m(1, 0);
1492
1435
  }
1493
1436
  }
1494
- function ua(e) {
1495
- var t = g();
1437
+ function ea(t, e, r, n, a, i) {
1438
+ var s = w();
1496
1439
  try {
1497
- w(e)();
1498
- } catch (r) {
1499
- if (m(t), r !== r + 0) throw r;
1500
- y(1, 0);
1440
+ return $(t)(e, r, n, a, i);
1441
+ } catch (u) {
1442
+ if (g(s), u !== u + 0) throw u;
1443
+ m(1, 0);
1501
1444
  }
1502
1445
  }
1503
- function ca(e, t, r, n, a, i, u, s, c, d, p) {
1504
- var v = g();
1446
+ function ra(t, e, r) {
1447
+ var n = w();
1505
1448
  try {
1506
- w(e)(t, r, n, a, i, u, s, c, d, p);
1507
- } catch ($) {
1508
- if (m(v), $ !== $ + 0) throw $;
1509
- y(1, 0);
1449
+ return $(t)(e, r);
1450
+ } catch (a) {
1451
+ if (g(n), a !== a + 0) throw a;
1452
+ m(1, 0);
1510
1453
  }
1511
1454
  }
1512
- function la(e, t, r, n, a) {
1513
- var i = g();
1455
+ function na(t) {
1456
+ var e = w();
1514
1457
  try {
1515
- w(e)(t, r, n, a);
1516
- } catch (u) {
1517
- if (m(i), u !== u + 0) throw u;
1518
- y(1, 0);
1458
+ $(t)();
1459
+ } catch (r) {
1460
+ if (g(e), r !== r + 0) throw r;
1461
+ m(1, 0);
1519
1462
  }
1520
1463
  }
1521
- function fa(e, t, r, n, a) {
1522
- var i = g();
1464
+ function aa(t, e, r, n, a, i, s, u, c, d, p) {
1465
+ var v = w();
1523
1466
  try {
1524
- return w(e)(t, r, n, a);
1525
- } catch (u) {
1526
- if (m(i), u !== u + 0) throw u;
1527
- y(1, 0);
1467
+ $(t)(e, r, n, a, i, s, u, c, d, p);
1468
+ } catch (y) {
1469
+ if (g(v), y !== y + 0) throw y;
1470
+ m(1, 0);
1528
1471
  }
1529
1472
  }
1530
- function da(e, t, r, n, a, i, u) {
1531
- var s = g();
1473
+ function oa(t, e, r, n, a) {
1474
+ var i = w();
1532
1475
  try {
1533
- w(e)(t, r, n, a, i, u);
1534
- } catch (c) {
1535
- if (m(s), c !== c + 0) throw c;
1536
- y(1, 0);
1476
+ return $(t)(e, r, n, a);
1477
+ } catch (s) {
1478
+ if (g(i), s !== s + 0) throw s;
1479
+ m(1, 0);
1537
1480
  }
1538
1481
  }
1539
- function ha(e, t, r, n, a, i, u, s, c, d, p, v, $, b, E, S) {
1540
- var A = g();
1482
+ function ia(t, e, r, n, a, i, s) {
1483
+ var u = w();
1541
1484
  try {
1542
- w(e)(t, r, n, a, i, u, s, c, d, p, v, $, b, E, S);
1543
- } catch (D) {
1544
- if (m(A), D !== D + 0) throw D;
1545
- y(1, 0);
1485
+ $(t)(e, r, n, a, i, s);
1486
+ } catch (c) {
1487
+ if (g(u), c !== c + 0) throw c;
1488
+ m(1, 0);
1546
1489
  }
1547
1490
  }
1548
- function pa(e, t, r, n, a, i, u, s, c) {
1549
- var d = g();
1491
+ function sa(t, e, r, n, a, i, s, u, c, d, p, v, y, T, S, x) {
1492
+ var E = w();
1550
1493
  try {
1551
- w(e)(t, r, n, a, i, u, s, c);
1552
- } catch (p) {
1553
- if (m(d), p !== p + 0) throw p;
1554
- y(1, 0);
1494
+ $(t)(e, r, n, a, i, s, u, c, d, p, v, y, T, S, x);
1495
+ } catch (O) {
1496
+ if (g(E), O !== O + 0) throw O;
1497
+ m(1, 0);
1555
1498
  }
1556
1499
  }
1557
- function va(e, t, r, n, a, i) {
1558
- var u = g();
1500
+ function ua(t, e, r, n, a, i, s, u, c) {
1501
+ var d = w();
1559
1502
  try {
1560
- return w(e)(t, r, n, a, i);
1561
- } catch (s) {
1562
- if (m(u), s !== s + 0) throw s;
1563
- y(1, 0);
1503
+ $(t)(e, r, n, a, i, s, u, c);
1504
+ } catch (p) {
1505
+ if (g(d), p !== p + 0) throw p;
1506
+ m(1, 0);
1564
1507
  }
1565
1508
  }
1566
- function ya(e, t, r, n, a, i) {
1567
- var u = g();
1509
+ function ca(t, e, r, n, a, i) {
1510
+ var s = w();
1568
1511
  try {
1569
- w(e)(t, r, n, a, i);
1570
- } catch (s) {
1571
- if (m(u), s !== s + 0) throw s;
1572
- y(1, 0);
1512
+ return $(t)(e, r, n, a, i);
1513
+ } catch (u) {
1514
+ if (g(s), u !== u + 0) throw u;
1515
+ m(1, 0);
1573
1516
  }
1574
1517
  }
1575
- function ma(e, t, r, n, a, i, u) {
1576
- var s = g();
1518
+ function la(t, e, r, n, a, i) {
1519
+ var s = w();
1577
1520
  try {
1578
- return w(e)(t, r, n, a, i, u);
1579
- } catch (c) {
1580
- if (m(s), c !== c + 0) throw c;
1581
- y(1, 0);
1521
+ $(t)(e, r, n, a, i);
1522
+ } catch (u) {
1523
+ if (g(s), u !== u + 0) throw u;
1524
+ m(1, 0);
1582
1525
  }
1583
1526
  }
1584
- function ga(e, t, r, n, a, i, u, s) {
1585
- var c = g();
1527
+ function fa(t, e, r, n, a, i, s) {
1528
+ var u = w();
1586
1529
  try {
1587
- w(e)(t, r, n, a, i, u, s);
1588
- } catch (d) {
1589
- if (m(c), d !== d + 0) throw d;
1590
- y(1, 0);
1530
+ return $(t)(e, r, n, a, i, s);
1531
+ } catch (c) {
1532
+ if (g(u), c !== c + 0) throw c;
1533
+ m(1, 0);
1591
1534
  }
1592
1535
  }
1593
- function wa(e, t, r, n, a, i, u, s) {
1594
- var c = g();
1536
+ function ha(t, e, r, n, a, i, s, u) {
1537
+ var c = w();
1595
1538
  try {
1596
- return w(e)(t, r, n, a, i, u, s);
1539
+ return $(t)(e, r, n, a, i, s, u);
1597
1540
  } catch (d) {
1598
- if (m(c), d !== d + 0) throw d;
1599
- y(1, 0);
1541
+ if (g(c), d !== d + 0) throw d;
1542
+ m(1, 0);
1600
1543
  }
1601
1544
  }
1602
- function $a(e) {
1603
- var t = g();
1545
+ function da(t) {
1546
+ var e = w();
1604
1547
  try {
1605
- return w(e)();
1548
+ return $(t)();
1606
1549
  } catch (r) {
1607
- if (m(t), r !== r + 0) throw r;
1608
- y(1, 0);
1550
+ if (g(e), r !== r + 0) throw r;
1551
+ m(1, 0);
1609
1552
  }
1610
1553
  }
1611
- function ba(e, t, r, n, a, i, u, s, c) {
1612
- var d = g();
1554
+ function pa(t, e, r, n, a, i, s, u, c) {
1555
+ var d = w();
1613
1556
  try {
1614
- return w(e)(t, r, n, a, i, u, s, c);
1557
+ return $(t)(e, r, n, a, i, s, u, c);
1615
1558
  } catch (p) {
1616
- if (m(d), p !== p + 0) throw p;
1617
- y(1, 0);
1559
+ if (g(d), p !== p + 0) throw p;
1560
+ m(1, 0);
1618
1561
  }
1619
1562
  }
1620
- function Ca(e, t, r, n, a, i, u) {
1621
- var s = g();
1563
+ function va(t, e, r, n, a, i, s) {
1564
+ var u = w();
1622
1565
  try {
1623
- return w(e)(t, r, n, a, i, u);
1566
+ return $(t)(e, r, n, a, i, s);
1624
1567
  } catch (c) {
1625
- if (m(s), c !== c + 0) throw c;
1626
- y(1, 0);
1568
+ if (g(u), c !== c + 0) throw c;
1569
+ m(1, 0);
1627
1570
  }
1628
1571
  }
1629
- function Ta(e, t, r, n) {
1630
- var a = g();
1572
+ function ya(t, e, r, n) {
1573
+ var a = w();
1631
1574
  try {
1632
- return w(e)(t, r, n);
1575
+ return $(t)(e, r, n);
1633
1576
  } catch (i) {
1634
- if (m(a), i !== i + 0) throw i;
1635
- y(1, 0);
1577
+ if (g(a), i !== i + 0) throw i;
1578
+ m(1, 0);
1636
1579
  }
1637
1580
  }
1638
- function Pa(e, t, r, n) {
1639
- var a = g();
1581
+ function ma(t, e, r, n) {
1582
+ var a = w();
1640
1583
  try {
1641
- return w(e)(t, r, n);
1584
+ return $(t)(e, r, n);
1642
1585
  } catch (i) {
1643
- if (m(a), i !== i + 0) throw i;
1644
- y(1, 0);
1586
+ if (g(a), i !== i + 0) throw i;
1587
+ m(1, 0);
1645
1588
  }
1646
1589
  }
1647
- function _a(e, t, r, n, a, i, u, s) {
1648
- var c = g();
1590
+ function ga(t, e, r, n, a, i, s, u) {
1591
+ var c = w();
1649
1592
  try {
1650
- w(e)(t, r, n, a, i, u, s);
1593
+ $(t)(e, r, n, a, i, s, u);
1651
1594
  } catch (d) {
1652
- if (m(c), d !== d + 0) throw d;
1653
- y(1, 0);
1595
+ if (g(c), d !== d + 0) throw d;
1596
+ m(1, 0);
1654
1597
  }
1655
1598
  }
1656
- function Ea(e, t, r, n, a, i) {
1657
- var u = g();
1599
+ function wa(t, e, r, n, a, i, s, u) {
1600
+ var c = w();
1658
1601
  try {
1659
- return w(e)(t, r, n, a, i);
1660
- } catch (s) {
1661
- if (m(u), s !== s + 0) throw s;
1662
- y(1, 0);
1602
+ $(t)(e, r, n, a, i, s, u);
1603
+ } catch (d) {
1604
+ if (g(c), d !== d + 0) throw d;
1605
+ m(1, 0);
1606
+ }
1607
+ }
1608
+ function $a(t, e, r, n, a, i) {
1609
+ var s = w();
1610
+ try {
1611
+ return $(t)(e, r, n, a, i);
1612
+ } catch (u) {
1613
+ if (g(s), u !== u + 0) throw u;
1614
+ m(1, 0);
1663
1615
  }
1664
1616
  }
1665
- function Oa(e, t, r, n, a, i, u, s, c, d) {
1666
- var p = g();
1617
+ function ba(t, e, r, n, a, i, s, u, c, d) {
1618
+ var p = w();
1667
1619
  try {
1668
- return w(e)(t, r, n, a, i, u, s, c, d);
1620
+ return $(t)(e, r, n, a, i, s, u, c, d);
1669
1621
  } catch (v) {
1670
- if (m(p), v !== v + 0) throw v;
1671
- y(1, 0);
1622
+ if (g(p), v !== v + 0) throw v;
1623
+ m(1, 0);
1672
1624
  }
1673
1625
  }
1674
- function xa(e, t, r) {
1675
- var n = g();
1626
+ function Ca(t, e, r) {
1627
+ var n = w();
1676
1628
  try {
1677
- return w(e)(t, r);
1629
+ return $(t)(e, r);
1678
1630
  } catch (a) {
1679
- if (m(n), a !== a + 0) throw a;
1680
- y(1, 0);
1631
+ if (g(n), a !== a + 0) throw a;
1632
+ m(1, 0);
1681
1633
  }
1682
1634
  }
1683
- function Aa(e, t, r, n, a) {
1684
- var i = g();
1635
+ function Ta(t, e, r, n, a) {
1636
+ var i = w();
1685
1637
  try {
1686
- return w(e)(t, r, n, a);
1687
- } catch (u) {
1688
- if (m(i), u !== u + 0) throw u;
1689
- y(1, 0);
1638
+ return $(t)(e, r, n, a);
1639
+ } catch (s) {
1640
+ if (g(i), s !== s + 0) throw s;
1641
+ m(1, 0);
1690
1642
  }
1691
1643
  }
1692
- function Sa(e, t, r, n, a, i, u, s, c, d) {
1693
- var p = g();
1644
+ function Ea(t, e, r, n, a, i, s, u, c, d) {
1645
+ var p = w();
1694
1646
  try {
1695
- w(e)(t, r, n, a, i, u, s, c, d);
1647
+ $(t)(e, r, n, a, i, s, u, c, d);
1696
1648
  } catch (v) {
1697
- if (m(p), v !== v + 0) throw v;
1698
- y(1, 0);
1649
+ if (g(p), v !== v + 0) throw v;
1650
+ m(1, 0);
1699
1651
  }
1700
1652
  }
1701
- function Da(e, t, r, n, a, i, u) {
1702
- var s = g();
1653
+ function Pa(t, e, r, n, a, i, s) {
1654
+ var u = w();
1703
1655
  try {
1704
- w(e)(t, r, n, a, i, u);
1656
+ $(t)(e, r, n, a, i, s);
1705
1657
  } catch (c) {
1706
- if (m(s), c !== c + 0) throw c;
1707
- y(1, 0);
1658
+ if (g(u), c !== c + 0) throw c;
1659
+ m(1, 0);
1708
1660
  }
1709
1661
  }
1710
- function Ia(e, t, r, n) {
1711
- var a = g();
1662
+ function Oa(t, e, r, n) {
1663
+ var a = w();
1712
1664
  try {
1713
- return w(e)(t, r, n);
1665
+ return $(t)(e, r, n);
1714
1666
  } catch (i) {
1715
- if (m(a), i !== i + 0) throw i;
1716
- y(1, 0);
1667
+ if (g(a), i !== i + 0) throw i;
1668
+ m(1, 0);
1717
1669
  }
1718
1670
  }
1719
- function Ma(e, t, r, n, a, i, u, s, c, d, p, v) {
1720
- var $ = g();
1671
+ function _a(t, e, r, n, a, i, s, u, c, d, p, v) {
1672
+ var y = w();
1721
1673
  try {
1722
- return w(e)(t, r, n, a, i, u, s, c, d, p, v);
1723
- } catch (b) {
1724
- if (m($), b !== b + 0) throw b;
1725
- y(1, 0);
1674
+ return $(t)(e, r, n, a, i, s, u, c, d, p, v);
1675
+ } catch (T) {
1676
+ if (g(y), T !== T + 0) throw T;
1677
+ m(1, 0);
1726
1678
  }
1727
1679
  }
1728
- function Fa(e, t, r, n, a, i, u) {
1729
- var s = g();
1680
+ function xa(t, e, r, n, a, i, s) {
1681
+ var u = w();
1730
1682
  try {
1731
- return Kn(e, t, r, n, a, i, u);
1683
+ return Me(t, e, r, n, a, i, s);
1732
1684
  } catch (c) {
1733
- if (m(s), c !== c + 0) throw c;
1734
- y(1, 0);
1685
+ if (g(u), c !== c + 0) throw c;
1686
+ m(1, 0);
1735
1687
  }
1736
1688
  }
1737
- function ja(e, t, r, n, a) {
1738
- var i = g();
1689
+ function Sa(t, e, r, n, a) {
1690
+ var i = w();
1739
1691
  try {
1740
- return ta(e, t, r, n, a);
1741
- } catch (u) {
1742
- if (m(i), u !== u + 0) throw u;
1743
- y(1, 0);
1692
+ return Ae(t, e, r, n, a);
1693
+ } catch (s) {
1694
+ if (g(i), s !== s + 0) throw s;
1695
+ m(1, 0);
1744
1696
  }
1745
1697
  }
1746
- function Zt() {
1747
- if (Z > 0) {
1748
- ct = Zt;
1749
- return;
1750
- }
1751
- if (Qe(), Z > 0) {
1752
- ct = Zt;
1753
- return;
1754
- }
1755
- function e() {
1756
- var t;
1757
- f.calledRun = !0, !te && (Je(), C(f), (t = f.onRuntimeInitialized) === null || t === void 0 || t.call(f), Ke());
1698
+ function Ia() {
1699
+ ar();
1700
+ function t() {
1701
+ var e, r;
1702
+ f.calledRun = !0, !ht && (or(), (e = Qt) === null || e === void 0 || e(f), (r = f.onRuntimeInitialized) === null || r === void 0 || r.call(f), ir());
1758
1703
  }
1759
1704
  f.setStatus ? (f.setStatus("Running..."), setTimeout(() => {
1760
- setTimeout(() => f.setStatus(""), 1), e();
1761
- }, 1)) : e();
1705
+ setTimeout(() => f.setStatus(""), 1), t();
1706
+ }, 1)) : t();
1762
1707
  }
1763
- function Ra() {
1764
- if (f.preInit)
1765
- for (typeof f.preInit == "function" && (f.preInit = [f.preInit]); f.preInit.length > 0; )
1766
- f.preInit.shift()();
1767
- }
1768
- return Ra(), Zt(), l = I, l;
1769
- };
1770
- function Ve(o) {
1771
- return Ue(Kt, o);
1708
+ var lt;
1709
+ return lt = await dr(), Ia(), ee ? l = f : l = new Promise((t, e) => {
1710
+ Qt = t, Jt = e;
1711
+ }), l;
1772
1712
  }
1773
- function To() {
1774
- return to(Kt);
1713
+ function qe(o) {
1714
+ return Xe(Zt, o);
1715
+ }
1716
+ function mo() {
1717
+ return qa(Zt);
1775
1718
  }
1776
- function Po(o) {
1777
- Ve({
1719
+ function go(o) {
1720
+ qe({
1778
1721
  overrides: o,
1779
1722
  equalityFn: Object.is,
1780
1723
  fireImmediately: !1
1781
1724
  });
1782
1725
  }
1783
- async function ro(o, l) {
1784
- return eo(Kt, o, l);
1726
+ async function Za(o, l) {
1727
+ return Ya(Zt, o, l);
1785
1728
  }
1786
- const _o = "68d20eb8c486afabf49fab6d9fbc5f118df8648ec6200e8039ef8912a169c00c", ke = [
1729
+ const wo = "85d46f55d7c86a4d09bb04273367408b19c324f582d040d018aecb25a9a82942", Ye = [
1787
1730
  ["aztec", "Aztec"],
1788
1731
  ["code_128", "Code128"],
1789
1732
  ["code_39", "Code39"],
@@ -1807,47 +1750,47 @@ const _o = "68d20eb8c486afabf49fab6d9fbc5f118df8648ec6200e8039ef8912a169c00c", k
1807
1750
  ["linear_codes", "Linear-Codes"],
1808
1751
  ["matrix_codes", "Matrix-Codes"],
1809
1752
  ["any", "Any"]
1810
- ], no = [...ke, ["unknown"]].map((o) => o[0]), Jt = new Map(
1811
- ke
1753
+ ], Qa = [...Ye, ["unknown"]].map((o) => o[0]), Yt = new Map(
1754
+ Ye
1812
1755
  );
1813
- function ao(o) {
1814
- for (const [l, h] of Jt)
1756
+ function Ja(o) {
1757
+ for (const [l, h] of Yt)
1815
1758
  if (o === h)
1816
1759
  return l;
1817
1760
  return "unknown";
1818
1761
  }
1819
- function oo(o) {
1820
- if (He(o))
1762
+ function Ka(o) {
1763
+ if (Ze(o))
1821
1764
  return {
1822
1765
  width: o.naturalWidth,
1823
1766
  height: o.naturalHeight
1824
1767
  };
1825
- if (Ne(o))
1768
+ if (Qe(o))
1826
1769
  return {
1827
1770
  width: o.width.baseVal.value,
1828
1771
  height: o.height.baseVal.value
1829
1772
  };
1830
- if (ze(o))
1773
+ if (Je(o))
1831
1774
  return {
1832
1775
  width: o.videoWidth,
1833
1776
  height: o.videoHeight
1834
1777
  };
1835
- if (Xe(o))
1778
+ if (tr(o))
1836
1779
  return {
1837
1780
  width: o.width,
1838
1781
  height: o.height
1839
1782
  };
1840
- if (Ye(o))
1783
+ if (rr(o))
1841
1784
  return {
1842
1785
  width: o.displayWidth,
1843
1786
  height: o.displayHeight
1844
1787
  };
1845
- if (Ge(o))
1788
+ if (Ke(o))
1846
1789
  return {
1847
1790
  width: o.width,
1848
1791
  height: o.height
1849
1792
  };
1850
- if (qe(o))
1793
+ if (er(o))
1851
1794
  return {
1852
1795
  width: o.width,
1853
1796
  height: o.height
@@ -1856,7 +1799,7 @@ function oo(o) {
1856
1799
  "The provided value is not of type '(Blob or HTMLCanvasElement or HTMLImageElement or HTMLVideoElement or ImageBitmap or ImageData or OffscreenCanvas or SVGImageElement or VideoFrame)'."
1857
1800
  );
1858
1801
  }
1859
- function He(o) {
1802
+ function Ze(o) {
1860
1803
  var l, h;
1861
1804
  try {
1862
1805
  return o instanceof ((h = (l = o == null ? void 0 : o.ownerDocument) == null ? void 0 : l.defaultView) == null ? void 0 : h.HTMLImageElement);
@@ -1864,7 +1807,7 @@ function He(o) {
1864
1807
  return !1;
1865
1808
  }
1866
1809
  }
1867
- function Ne(o) {
1810
+ function Qe(o) {
1868
1811
  var l, h;
1869
1812
  try {
1870
1813
  return o instanceof ((h = (l = o == null ? void 0 : o.ownerDocument) == null ? void 0 : l.defaultView) == null ? void 0 : h.SVGImageElement);
@@ -1872,7 +1815,7 @@ function Ne(o) {
1872
1815
  return !1;
1873
1816
  }
1874
1817
  }
1875
- function ze(o) {
1818
+ function Je(o) {
1876
1819
  var l, h;
1877
1820
  try {
1878
1821
  return o instanceof ((h = (l = o == null ? void 0 : o.ownerDocument) == null ? void 0 : l.defaultView) == null ? void 0 : h.HTMLVideoElement);
@@ -1880,7 +1823,7 @@ function ze(o) {
1880
1823
  return !1;
1881
1824
  }
1882
1825
  }
1883
- function Ge(o) {
1826
+ function Ke(o) {
1884
1827
  var l, h;
1885
1828
  try {
1886
1829
  return o instanceof ((h = (l = o == null ? void 0 : o.ownerDocument) == null ? void 0 : l.defaultView) == null ? void 0 : h.HTMLCanvasElement);
@@ -1888,42 +1831,42 @@ function Ge(o) {
1888
1831
  return !1;
1889
1832
  }
1890
1833
  }
1891
- function Xe(o) {
1834
+ function tr(o) {
1892
1835
  try {
1893
1836
  return o instanceof ImageBitmap || Object.prototype.toString.call(o) === "[object ImageBitmap]";
1894
1837
  } catch {
1895
1838
  return !1;
1896
1839
  }
1897
1840
  }
1898
- function qe(o) {
1841
+ function er(o) {
1899
1842
  try {
1900
1843
  return o instanceof OffscreenCanvas || Object.prototype.toString.call(o) === "[object OffscreenCanvas]";
1901
1844
  } catch {
1902
1845
  return !1;
1903
1846
  }
1904
1847
  }
1905
- function Ye(o) {
1848
+ function rr(o) {
1906
1849
  try {
1907
1850
  return o instanceof VideoFrame || Object.prototype.toString.call(o) === "[object VideoFrame]";
1908
1851
  } catch {
1909
1852
  return !1;
1910
1853
  }
1911
1854
  }
1912
- function io(o) {
1855
+ function to(o) {
1913
1856
  try {
1914
1857
  return o instanceof Blob || Object.prototype.toString.call(o) === "[object Blob]";
1915
1858
  } catch {
1916
1859
  return !1;
1917
1860
  }
1918
1861
  }
1919
- function so(o) {
1862
+ function eo(o) {
1920
1863
  try {
1921
1864
  return o instanceof ImageData || Object.prototype.toString.call(o) === "[object ImageData]";
1922
1865
  } catch {
1923
1866
  return !1;
1924
1867
  }
1925
1868
  }
1926
- function uo(o, l) {
1869
+ function ro(o, l) {
1927
1870
  try {
1928
1871
  const h = new OffscreenCanvas(o, l);
1929
1872
  if (h.getContext("2d") instanceof OffscreenCanvasRenderingContext2D)
@@ -1934,38 +1877,38 @@ function uo(o, l) {
1934
1877
  return h.width = o, h.height = l, h;
1935
1878
  }
1936
1879
  }
1937
- async function Ze(o) {
1938
- if (He(o) && !await ho(o))
1880
+ async function nr(o) {
1881
+ if (Ze(o) && !await io(o))
1939
1882
  throw new DOMException(
1940
1883
  "Failed to load or decode HTMLImageElement.",
1941
1884
  "InvalidStateError"
1942
1885
  );
1943
- if (Ne(o) && !await po(o))
1886
+ if (Qe(o) && !await so(o))
1944
1887
  throw new DOMException(
1945
1888
  "Failed to load or decode SVGImageElement.",
1946
1889
  "InvalidStateError"
1947
1890
  );
1948
- if (Ye(o) && vo(o))
1891
+ if (rr(o) && uo(o))
1949
1892
  throw new DOMException("VideoFrame is closed.", "InvalidStateError");
1950
- if (ze(o) && (o.readyState === 0 || o.readyState === 1))
1893
+ if (Je(o) && (o.readyState === 0 || o.readyState === 1))
1951
1894
  throw new DOMException("Invalid element or state.", "InvalidStateError");
1952
- if (Xe(o) && mo(o))
1895
+ if (tr(o) && lo(o))
1953
1896
  throw new DOMException(
1954
1897
  "The image source is detached.",
1955
1898
  "InvalidStateError"
1956
1899
  );
1957
- const { width: l, height: h } = oo(o);
1900
+ const { width: l, height: h } = Ka(o);
1958
1901
  if (l === 0 || h === 0)
1959
1902
  return null;
1960
- const C = uo(l, h).getContext("2d");
1961
- C.drawImage(o, 0, 0);
1903
+ const f = ro(l, h).getContext("2d");
1904
+ f.drawImage(o, 0, 0);
1962
1905
  try {
1963
- return C.getImageData(0, 0, l, h);
1906
+ return f.getImageData(0, 0, l, h);
1964
1907
  } catch {
1965
1908
  throw new DOMException("Source would taint origin.", "SecurityError");
1966
1909
  }
1967
1910
  }
1968
- async function co(o) {
1911
+ async function no(o) {
1969
1912
  let l;
1970
1913
  try {
1971
1914
  l = await createImageBitmap(o);
@@ -1973,11 +1916,11 @@ async function co(o) {
1973
1916
  try {
1974
1917
  if (globalThis.Image) {
1975
1918
  l = new Image();
1976
- let C = "";
1919
+ let f = "";
1977
1920
  try {
1978
- C = URL.createObjectURL(o), l.src = C, await l.decode();
1921
+ f = URL.createObjectURL(o), l.src = f, await l.decode();
1979
1922
  } finally {
1980
- URL.revokeObjectURL(C);
1923
+ URL.revokeObjectURL(f);
1981
1924
  }
1982
1925
  } else
1983
1926
  return o;
@@ -1988,40 +1931,40 @@ async function co(o) {
1988
1931
  );
1989
1932
  }
1990
1933
  }
1991
- return await Ze(l);
1934
+ return await nr(l);
1992
1935
  }
1993
- function lo(o) {
1936
+ function ao(o) {
1994
1937
  const { width: l, height: h } = o;
1995
1938
  if (l === 0 || h === 0)
1996
1939
  return null;
1997
- const f = o.getContext("2d");
1940
+ const b = o.getContext("2d");
1998
1941
  try {
1999
- return f.getImageData(0, 0, l, h);
1942
+ return b.getImageData(0, 0, l, h);
2000
1943
  } catch {
2001
1944
  throw new DOMException("Source would taint origin.", "SecurityError");
2002
1945
  }
2003
1946
  }
2004
- async function fo(o) {
2005
- if (io(o))
2006
- return await co(o);
2007
- if (so(o)) {
2008
- if (yo(o))
1947
+ async function oo(o) {
1948
+ if (to(o))
1949
+ return await no(o);
1950
+ if (eo(o)) {
1951
+ if (co(o))
2009
1952
  throw new DOMException(
2010
1953
  "The image data has been detached.",
2011
1954
  "InvalidStateError"
2012
1955
  );
2013
1956
  return o;
2014
1957
  }
2015
- return Ge(o) || qe(o) ? lo(o) : await Ze(o);
1958
+ return Ke(o) || er(o) ? ao(o) : await nr(o);
2016
1959
  }
2017
- async function ho(o) {
1960
+ async function io(o) {
2018
1961
  try {
2019
1962
  return await o.decode(), !0;
2020
1963
  } catch {
2021
1964
  return !1;
2022
1965
  }
2023
1966
  }
2024
- async function po(o) {
1967
+ async function so(o) {
2025
1968
  var l;
2026
1969
  try {
2027
1970
  return await ((l = o.decode) == null ? void 0 : l.call(o)), !0;
@@ -2029,122 +1972,122 @@ async function po(o) {
2029
1972
  return !1;
2030
1973
  }
2031
1974
  }
2032
- function vo(o) {
1975
+ function uo(o) {
2033
1976
  return o.format === null;
2034
1977
  }
2035
- function yo(o) {
1978
+ function co(o) {
2036
1979
  return o.data.buffer.byteLength === 0;
2037
1980
  }
2038
- function mo(o) {
1981
+ function lo(o) {
2039
1982
  return o.width === 0 && o.height === 0;
2040
1983
  }
2041
- function We(o, l) {
2042
- return go(o) ? new DOMException(`${l}: ${o.message}`, o.name) : wo(o) ? new o.constructor(`${l}: ${o.message}`) : new Error(`${l}: ${o}`);
1984
+ function Ge(o, l) {
1985
+ return fo(o) ? new DOMException(`${l}: ${o.message}`, o.name) : ho(o) ? new o.constructor(`${l}: ${o.message}`) : new Error(`${l}: ${o}`);
2043
1986
  }
2044
- function go(o) {
1987
+ function fo(o) {
2045
1988
  return o instanceof DOMException || Object.prototype.toString.call(o) === "[object DOMException]";
2046
1989
  }
2047
- function wo(o) {
1990
+ function ho(o) {
2048
1991
  return o instanceof Error || Object.prototype.toString.call(o) === "[object Error]";
2049
1992
  }
2050
- var pt;
2051
- class Eo {
1993
+ var ft;
1994
+ class $o {
2052
1995
  constructor(l = {}) {
2053
- je(this, pt);
1996
+ He(this, ft);
2054
1997
  var h;
2055
1998
  try {
2056
- const f = (h = l == null ? void 0 : l.formats) == null ? void 0 : h.filter(
2057
- (C) => C !== "unknown"
1999
+ const b = (h = l == null ? void 0 : l.formats) == null ? void 0 : h.filter(
2000
+ (f) => f !== "unknown"
2058
2001
  );
2059
- if ((f == null ? void 0 : f.length) === 0)
2002
+ if ((b == null ? void 0 : b.length) === 0)
2060
2003
  throw new TypeError("Hint option provided, but is empty.");
2061
- for (const C of f != null ? f : [])
2062
- if (!Jt.has(C))
2004
+ for (const f of b != null ? b : [])
2005
+ if (!Yt.has(f))
2063
2006
  throw new TypeError(
2064
- `Failed to read the 'formats' property from 'BarcodeDetectorOptions': The provided value '${C}' is not a valid enum value of type BarcodeFormat.`
2007
+ `Failed to read the 'formats' property from 'BarcodeDetectorOptions': The provided value '${f}' is not a valid enum value of type BarcodeFormat.`
2065
2008
  );
2066
- Re(this, pt, f != null ? f : []), Ve({ fireImmediately: !0 }).catch(() => {
2009
+ ke(this, ft, b != null ? b : []), qe({ fireImmediately: !0 }).catch(() => {
2067
2010
  });
2068
- } catch (f) {
2069
- throw We(
2070
- f,
2011
+ } catch (b) {
2012
+ throw Ge(
2013
+ b,
2071
2014
  "Failed to construct 'BarcodeDetector'"
2072
2015
  );
2073
2016
  }
2074
2017
  }
2075
2018
  static async getSupportedFormats() {
2076
- return no.filter((l) => l !== "unknown");
2019
+ return Qa.filter((l) => l !== "unknown");
2077
2020
  }
2078
2021
  async detect(l) {
2079
2022
  try {
2080
- const h = await fo(l);
2023
+ const h = await oo(l);
2081
2024
  if (h === null)
2082
2025
  return [];
2083
- let f;
2084
- const C = {
2026
+ let b;
2027
+ const f = {
2085
2028
  tryCode39ExtendedMode: !1,
2086
2029
  textMode: "Plain",
2087
- formats: Fe(this, pt).map((O) => Jt.get(O))
2030
+ formats: We(this, ft).map((I) => Yt.get(I))
2088
2031
  };
2089
2032
  try {
2090
- f = await ro(h, C);
2091
- } catch (O) {
2092
- throw console.error(O), new DOMException(
2033
+ b = await Za(h, f);
2034
+ } catch (I) {
2035
+ throw console.error(I), new DOMException(
2093
2036
  "Barcode detection service unavailable.",
2094
2037
  "NotSupportedError"
2095
2038
  );
2096
2039
  }
2097
- return f.map((O) => {
2040
+ return b.map((I) => {
2098
2041
  const {
2099
- topLeft: { x: I, y: j },
2100
- topRight: { x, y: M },
2101
- bottomLeft: { x: z, y: X },
2102
- bottomRight: { x: q, y: it }
2103
- } = O.position, st = Math.min(I, x, z, q), et = Math.min(j, M, X, it), vt = Math.max(I, x, z, q), G = Math.max(j, M, X, it);
2042
+ topLeft: { x: D, y: M },
2043
+ topRight: { x: _, y: A },
2044
+ bottomLeft: { x: U, y: X },
2045
+ bottomRight: { x: tt, y: q }
2046
+ } = I.position, nt = Math.min(D, _, U, tt), V = Math.min(M, A, X, q), Y = Math.max(D, _, U, tt), ht = Math.max(M, A, X, q);
2104
2047
  return {
2105
2048
  boundingBox: new DOMRectReadOnly(
2106
- st,
2107
- et,
2108
- vt - st,
2109
- G - et
2049
+ nt,
2050
+ V,
2051
+ Y - nt,
2052
+ ht - V
2110
2053
  ),
2111
- rawValue: O.text,
2112
- format: ao(O.format),
2054
+ rawValue: I.text,
2055
+ format: Ja(I.format),
2113
2056
  cornerPoints: [
2114
2057
  {
2115
- x: I,
2116
- y: j
2058
+ x: D,
2059
+ y: M
2117
2060
  },
2118
2061
  {
2119
- x,
2120
- y: M
2062
+ x: _,
2063
+ y: A
2121
2064
  },
2122
2065
  {
2123
- x: q,
2124
- y: it
2066
+ x: tt,
2067
+ y: q
2125
2068
  },
2126
2069
  {
2127
- x: z,
2070
+ x: U,
2128
2071
  y: X
2129
2072
  }
2130
2073
  ]
2131
2074
  };
2132
2075
  });
2133
2076
  } catch (h) {
2134
- throw We(
2077
+ throw Ge(
2135
2078
  h,
2136
2079
  "Failed to execute 'detect' on 'BarcodeDetector'"
2137
2080
  );
2138
2081
  }
2139
2082
  }
2140
2083
  }
2141
- pt = new WeakMap();
2084
+ ft = new WeakMap();
2142
2085
  export {
2143
- Eo as BarcodeDetector,
2144
- Co as ZXING_CPP_COMMIT,
2145
- _o as ZXING_WASM_SHA256,
2146
- bo as ZXING_WASM_VERSION,
2147
- Ve as prepareZXingModule,
2148
- To as purgeZXingModule,
2149
- Po as setZXingModuleOverrides
2086
+ $o as BarcodeDetector,
2087
+ yo as ZXING_CPP_COMMIT,
2088
+ wo as ZXING_WASM_SHA256,
2089
+ vo as ZXING_WASM_VERSION,
2090
+ qe as prepareZXingModule,
2091
+ mo as purgeZXingModule,
2092
+ go as setZXingModuleOverrides
2150
2093
  };