@rive-app/canvas-advanced-lite 2.31.6 → 2.32.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,62 +1,62 @@
1
1
 
2
2
  var Rive = (() => {
3
- var _scriptDir = typeof document !== 'undefined' && document.currentScript ? document.currentScript.src : undefined;
3
+ var _scriptName = typeof document != 'undefined' ? document.currentScript?.src : undefined;
4
4
 
5
5
  return (
6
6
  function(moduleArg = {}) {
7
+ var moduleRtn;
7
8
 
8
- var h = moduleArg, aa, ba;
9
- h.ready = new Promise((b, a) => {
9
+ var k = moduleArg, aa, ba, ca = new Promise((b, a) => {
10
10
  aa = b;
11
11
  ba = a;
12
- });
13
- function ca() {
12
+ }), da = "object" == typeof window, ea = "function" == typeof importScripts;
13
+ function ja() {
14
14
  function b(m) {
15
- const k = d;
15
+ const h = d;
16
16
  c = a = 0;
17
17
  d = new Map();
18
- k.forEach(n => {
18
+ h.forEach(l => {
19
19
  try {
20
- n(m);
21
- } catch (l) {
22
- console.error(l);
20
+ l(m);
21
+ } catch (n) {
22
+ console.error(n);
23
23
  }
24
24
  });
25
- this.xa();
26
- e && e.Ta();
25
+ this.ua();
26
+ e && e.Oa();
27
27
  }
28
28
  let a = 0, c = 0, d = new Map(), e = null, f = null;
29
29
  this.requestAnimationFrame = function(m) {
30
- a || (a = requestAnimationFrame(b.bind(this)));
31
- const k = ++c;
32
- d.set(k, m);
33
- return k;
30
+ a ||= requestAnimationFrame(b.bind(this));
31
+ const h = ++c;
32
+ d.set(h, m);
33
+ return h;
34
34
  };
35
35
  this.cancelAnimationFrame = function(m) {
36
36
  d.delete(m);
37
37
  a && 0 == d.size && (cancelAnimationFrame(a), a = 0);
38
38
  };
39
- this.Ra = function(m) {
39
+ this.Ma = function(m) {
40
40
  f && (document.body.remove(f), f = null);
41
- m || (f = document.createElement("div"), f.style.backgroundColor = "black", f.style.position = "fixed", f.style.right = 0, f.style.top = 0, f.style.color = "white", f.style.padding = "4px", f.innerHTML = "RIVE FPS", m = function(k) {
42
- f.innerHTML = "RIVE FPS " + k.toFixed(1);
41
+ m || (f = document.createElement("div"), f.style.backgroundColor = "black", f.style.position = "fixed", f.style.right = 0, f.style.top = 0, f.style.color = "white", f.style.padding = "4px", f.innerHTML = "RIVE FPS", m = function(h) {
42
+ f.innerHTML = "RIVE FPS " + h.toFixed(1);
43
43
  }, document.body.appendChild(f));
44
44
  e = new function() {
45
- let k = 0, n = 0;
46
- this.Ta = function() {
47
- var l = performance.now();
48
- n ? (++k, l -= n, 1000 < l && (m(1000 * k / l), k = n = 0)) : (n = l, k = 0);
45
+ let h = 0, l = 0;
46
+ this.Oa = function() {
47
+ var n = performance.now();
48
+ l ? (++h, n -= l, 1000 < n && (m(1000 * h / n), h = l = 0)) : (l = n, h = 0);
49
49
  };
50
50
  }();
51
51
  };
52
- this.Oa = function() {
52
+ this.Ja = function() {
53
53
  f && (document.body.remove(f), f = null);
54
54
  e = null;
55
55
  };
56
- this.xa = function() {
56
+ this.ua = function() {
57
57
  };
58
58
  }
59
- function da(b) {
59
+ function ka(b) {
60
60
  console.assert(!0);
61
61
  const a = new Map();
62
62
  let c = -Infinity;
@@ -71,84 +71,84 @@ function da(b) {
71
71
  return c << b;
72
72
  };
73
73
  }
74
- const ea = h.onRuntimeInitialized;
75
- h.onRuntimeInitialized = function() {
76
- ea && ea();
77
- let b = h.decodeAudio;
78
- h.decodeAudio = function(e, f) {
74
+ const la = k.onRuntimeInitialized;
75
+ k.onRuntimeInitialized = function() {
76
+ la && la();
77
+ let b = k.decodeAudio;
78
+ k.decodeAudio = function(e, f) {
79
79
  e = b(e);
80
80
  f(e);
81
81
  };
82
- let a = h.decodeFont;
83
- h.decodeFont = function(e, f) {
82
+ let a = k.decodeFont;
83
+ k.decodeFont = function(e, f) {
84
84
  e = a(e);
85
85
  f(e);
86
86
  };
87
- const c = h.FileAssetLoader;
88
- h.ptrToAsset = e => {
89
- let f = h.ptrToFileAsset(e);
90
- return f.isImage ? h.ptrToImageAsset(e) : f.isFont ? h.ptrToFontAsset(e) : f.isAudio ? h.ptrToAudioAsset(e) : f;
87
+ const c = k.FileAssetLoader;
88
+ k.ptrToAsset = e => {
89
+ let f = k.ptrToFileAsset(e);
90
+ return f.isImage ? k.ptrToImageAsset(e) : f.isFont ? k.ptrToFontAsset(e) : f.isAudio ? k.ptrToAudioAsset(e) : f;
91
91
  };
92
- h.CustomFileAssetLoader = c.extend("CustomFileAssetLoader", {__construct:function({loadContents:e}) {
92
+ k.CustomFileAssetLoader = c.extend("CustomFileAssetLoader", {__construct:function({loadContents:e}) {
93
93
  this.__parent.__construct.call(this);
94
- this.Ha = e;
94
+ this.Da = e;
95
95
  }, loadContents:function(e, f) {
96
- e = h.ptrToAsset(e);
97
- return this.Ha(e, f);
96
+ e = k.ptrToAsset(e);
97
+ return this.Da(e, f);
98
98
  },});
99
- h.CDNFileAssetLoader = c.extend("CDNFileAssetLoader", {__construct:function() {
99
+ k.CDNFileAssetLoader = c.extend("CDNFileAssetLoader", {__construct:function() {
100
100
  this.__parent.__construct.call(this);
101
101
  }, loadContents:function(e) {
102
- let f = h.ptrToAsset(e);
102
+ let f = k.ptrToAsset(e);
103
103
  e = f.cdnUuid;
104
104
  if ("" === e) {
105
105
  return !1;
106
106
  }
107
- (function(m, k) {
108
- var n = new XMLHttpRequest();
109
- n.responseType = "arraybuffer";
110
- n.onreadystatechange = function() {
111
- 4 == n.readyState && 200 == n.status && k(n);
107
+ (function(m, h) {
108
+ var l = new XMLHttpRequest();
109
+ l.responseType = "arraybuffer";
110
+ l.onreadystatechange = function() {
111
+ 4 == l.readyState && 200 == l.status && h(l);
112
112
  };
113
- n.open("GET", m, !0);
114
- n.send(null);
113
+ l.open("GET", m, !0);
114
+ l.send(null);
115
115
  })(f.cdnBaseUrl + "/" + e, m => {
116
116
  f.decode(new Uint8Array(m.response));
117
117
  });
118
118
  return !0;
119
119
  },});
120
- h.FallbackFileAssetLoader = c.extend("FallbackFileAssetLoader", {__construct:function() {
120
+ k.FallbackFileAssetLoader = c.extend("FallbackFileAssetLoader", {__construct:function() {
121
121
  this.__parent.__construct.call(this);
122
- this.wa = [];
122
+ this.ta = [];
123
123
  }, addLoader:function(e) {
124
- this.wa.push(e);
124
+ this.ta.push(e);
125
125
  }, loadContents:function(e, f) {
126
- for (let m of this.wa) {
126
+ for (let m of this.ta) {
127
127
  if (m.loadContents(e, f)) {
128
128
  return !0;
129
129
  }
130
130
  }
131
131
  return !1;
132
132
  },});
133
- let d = h.computeAlignment;
134
- h.computeAlignment = function(e, f, m, k, n = 1.0) {
135
- return d.call(this, e, f, m, k, n);
133
+ let d = k.computeAlignment;
134
+ k.computeAlignment = function(e, f, m, h, l = 1.0) {
135
+ return d.call(this, e, f, m, h, l);
136
136
  };
137
137
  };
138
- const fa = "createConicGradient createImageData createLinearGradient createPattern createRadialGradient getContextAttributes getImageData getLineDash getTransform isContextLost isPointInPath isPointInStroke measureText".split(" "), ha = new function() {
138
+ const na = "createConicGradient createImageData createLinearGradient createPattern createRadialGradient getContextAttributes getImageData getLineDash getTransform isContextLost isPointInPath isPointInStroke measureText".split(" "), oa = new function() {
139
139
  function b() {
140
140
  if (!a) {
141
- var g = document.createElement("canvas"), r = {alpha:1, depth:0, stencil:0, antialias:0, premultipliedAlpha:1, preserveDrawingBuffer:0, powerPreference:"high-performance", failIfMajorPerformanceCaveat:0, enableExtensionsByDefault:1, explicitSwapControl:1, renderViaOffscreenBackBuffer:1,};
141
+ var g = document.createElement("canvas"), t = {alpha:1, depth:0, stencil:0, antialias:0, premultipliedAlpha:1, preserveDrawingBuffer:0, powerPreference:"high-performance", failIfMajorPerformanceCaveat:0, enableExtensionsByDefault:1, explicitSwapControl:1, renderViaOffscreenBackBuffer:1,};
142
142
  let q;
143
143
  if (/iPhone|iPad|iPod/i.test(navigator.userAgent)) {
144
- if (q = g.getContext("webgl", r), c = 1, !q) {
144
+ if (q = g.getContext("webgl", t), c = 1, !q) {
145
145
  return console.log("No WebGL support. Image mesh will not be drawn."), !1;
146
146
  }
147
147
  } else {
148
- if (q = g.getContext("webgl2", r)) {
148
+ if (q = g.getContext("webgl2", t)) {
149
149
  c = 2;
150
150
  } else {
151
- if (q = g.getContext("webgl", r)) {
151
+ if (q = g.getContext("webgl", t)) {
152
152
  c = 1;
153
153
  } else {
154
154
  return console.log("No WebGL support. Image mesh will not be drawn."), !1;
@@ -157,7 +157,7 @@ const fa = "createConicGradient createImageData createLinearGradient createPatte
157
157
  }
158
158
  q = new Proxy(q, {get(E, v) {
159
159
  if (E.isContextLost()) {
160
- if (n || (console.error("Cannot render the mesh because the GL Context was lost. Tried to invoke ", v), n = !0), "function" === typeof E[v]) {
160
+ if (l || (console.error("Cannot render the mesh because the GL Context was lost. Tried to invoke ", v), l = !0), "function" === typeof E[v]) {
161
161
  return function() {
162
162
  };
163
163
  }
@@ -168,7 +168,7 @@ const fa = "createConicGradient createImageData createLinearGradient createPatte
168
168
  }
169
169
  }, set(E, v, I) {
170
170
  if (E.isContextLost()) {
171
- n || (console.error("Cannot render the mesh because the GL Context was lost. Tried to set property " + v), n = !0);
171
+ l || (console.error("Cannot render the mesh because the GL Context was lost. Tried to set property " + v), l = !0);
172
172
  } else {
173
173
  return E[v] = I, !0;
174
174
  }
@@ -190,9 +190,9 @@ const fa = "createConicGradient createImageData createLinearGradient createPatte
190
190
  q.bindAttribLocation(g, 0, "vertex");
191
191
  q.bindAttribLocation(g, 1, "uv");
192
192
  q.linkProgram(g);
193
- r = q.getProgramInfoLog(g);
194
- if (0 < (r || "").trim().length) {
195
- throw r;
193
+ t = q.getProgramInfoLog(g);
194
+ if (0 < (t || "").trim().length) {
195
+ throw t;
196
196
  }
197
197
  e = q.getUniformLocation(g, "mat");
198
198
  f = q.getUniformLocation(g, "translate");
@@ -207,122 +207,122 @@ const fa = "createConicGradient createImageData createLinearGradient createPatte
207
207
  }
208
208
  return !0;
209
209
  }
210
- let a = null, c = 0, d = 0, e = null, f = null, m = 0, k = 0, n = !1;
210
+ let a = null, c = 0, d = 0, e = null, f = null, m = 0, h = 0, l = !1;
211
211
  b();
212
- this.eb = function() {
212
+ this.Wa = function() {
213
213
  b();
214
214
  return d;
215
215
  };
216
- this.Ma = function(g) {
216
+ this.Ia = function(g) {
217
217
  a.deleteTexture && a.deleteTexture(g);
218
218
  };
219
- this.La = function(g) {
219
+ this.Ha = function(g) {
220
220
  if (!b()) {
221
221
  return null;
222
222
  }
223
- const r = a.createTexture();
224
- if (!r) {
223
+ const t = a.createTexture();
224
+ if (!t) {
225
225
  return null;
226
226
  }
227
- a.bindTexture(a.TEXTURE_2D, r);
227
+ a.bindTexture(a.TEXTURE_2D, t);
228
228
  a.texImage2D(a.TEXTURE_2D, 0, a.RGBA, a.RGBA, a.UNSIGNED_BYTE, g);
229
229
  a.texParameteri(a.TEXTURE_2D, a.TEXTURE_WRAP_S, a.CLAMP_TO_EDGE);
230
230
  a.texParameteri(a.TEXTURE_2D, a.TEXTURE_WRAP_T, a.CLAMP_TO_EDGE);
231
231
  a.texParameteri(a.TEXTURE_2D, a.TEXTURE_MAG_FILTER, a.LINEAR);
232
232
  2 == c ? (a.texParameteri(a.TEXTURE_2D, a.TEXTURE_MIN_FILTER, a.LINEAR_MIPMAP_LINEAR), a.generateMipmap(a.TEXTURE_2D)) : a.texParameteri(a.TEXTURE_2D, a.TEXTURE_MIN_FILTER, a.LINEAR);
233
- return r;
233
+ return t;
234
234
  };
235
- const l = new da(8), t = new da(8), w = new da(10), x = new da(10);
236
- this.Qa = function(g, r, q, F, E) {
235
+ const n = new ka(8), r = new ka(8), w = new ka(10), y = new ka(10);
236
+ this.La = function(g, t, q, F, E) {
237
237
  if (b()) {
238
- var v = l.push(g), I = t.push(r);
238
+ var v = n.push(g), I = r.push(t);
239
239
  if (a.canvas) {
240
240
  if (a.canvas.width != v || a.canvas.height != I) {
241
241
  a.canvas.width = v, a.canvas.height = I;
242
242
  }
243
- a.viewport(0, I - r, g, r);
243
+ a.viewport(0, I - t, g, t);
244
244
  a.disable(a.SCISSOR_TEST);
245
245
  a.clearColor(0, 0, 0, 0);
246
246
  a.clear(a.COLOR_BUFFER_BIT);
247
247
  a.enable(a.SCISSOR_TEST);
248
- q.sort((C, Y) => Y.Ba - C.Ba);
248
+ q.sort((C, W) => W.xa - C.xa);
249
249
  v = w.push(F);
250
250
  m != v && (a.bufferData(a.ARRAY_BUFFER, 8 * v, a.DYNAMIC_DRAW), m = v);
251
251
  v = 0;
252
- for (var O of q) {
253
- a.bufferSubData(a.ARRAY_BUFFER, v, O.ia), v += 4 * O.ia.length;
252
+ for (var L of q) {
253
+ a.bufferSubData(a.ARRAY_BUFFER, v, L.ha), v += 4 * L.ha.length;
254
254
  }
255
255
  console.assert(v == 4 * F);
256
- for (var Z of q) {
257
- a.bufferSubData(a.ARRAY_BUFFER, v, Z.Ea), v += 4 * Z.Ea.length;
256
+ for (var R of q) {
257
+ a.bufferSubData(a.ARRAY_BUFFER, v, R.Aa), v += 4 * R.Aa.length;
258
258
  }
259
259
  console.assert(v == 8 * F);
260
- v = x.push(E);
261
- k != v && (a.bufferData(a.ELEMENT_ARRAY_BUFFER, 2 * v, a.DYNAMIC_DRAW), k = v);
262
- O = 0;
263
- for (var ia of q) {
264
- a.bufferSubData(a.ELEMENT_ARRAY_BUFFER, O, ia.indices), O += 2 * ia.indices.length;
260
+ v = y.push(E);
261
+ h != v && (a.bufferData(a.ELEMENT_ARRAY_BUFFER, 2 * v, a.DYNAMIC_DRAW), h = v);
262
+ L = 0;
263
+ for (var fa of q) {
264
+ a.bufferSubData(a.ELEMENT_ARRAY_BUFFER, L, fa.indices), L += 2 * fa.indices.length;
265
265
  }
266
- console.assert(O == 2 * E);
267
- ia = 0;
268
- Z = !0;
269
- v = O = 0;
266
+ console.assert(L == 2 * E);
267
+ fa = 0;
268
+ R = !0;
269
+ v = L = 0;
270
270
  for (const C of q) {
271
- C.image.da != ia && (a.bindTexture(a.TEXTURE_2D, C.image.ca || null), ia = C.image.da);
272
- C.hb ? (a.scissor(C.na, I - C.oa - C.va, C.sb, C.va), Z = !0) : Z && (a.scissor(0, I - r, g, r), Z = !1);
271
+ C.image.ca != fa && (a.bindTexture(a.TEXTURE_2D, C.image.ba || null), fa = C.image.ca);
272
+ C.Za ? (a.scissor(C.ma, I - C.na - C.sa, C.kb, C.sa), R = !0) : R && (a.scissor(0, I - t, g, t), R = !1);
273
273
  q = 2 / g;
274
- const Y = -2 / r;
275
- a.uniform4f(e, C.N[0] * q * C.X, C.N[1] * Y * C.Y, C.N[2] * q * C.X, C.N[3] * Y * C.Y);
276
- a.uniform2f(f, C.N[4] * q * C.X + q * (C.na - C.fb * C.X) - 1, C.N[5] * Y * C.Y + Y * (C.oa - C.gb * C.Y) + 1);
274
+ const W = -2 / t;
275
+ a.uniform4f(e, C.M[0] * q * C.W, C.M[1] * W * C.X, C.M[2] * q * C.W, C.M[3] * W * C.X);
276
+ a.uniform2f(f, C.M[4] * q * C.W + q * (C.ma - C.Xa * C.W) - 1, C.M[5] * W * C.X + W * (C.na - C.Ya * C.X) + 1);
277
277
  a.vertexAttribPointer(0, 2, a.FLOAT, !1, 0, v);
278
278
  a.vertexAttribPointer(1, 2, a.FLOAT, !1, 0, v + 4 * F);
279
- a.drawElements(a.TRIANGLES, C.indices.length, a.UNSIGNED_SHORT, O);
280
- v += 4 * C.ia.length;
281
- O += 2 * C.indices.length;
279
+ a.drawElements(a.TRIANGLES, C.indices.length, a.UNSIGNED_SHORT, L);
280
+ v += 4 * C.ha.length;
281
+ L += 2 * C.indices.length;
282
282
  }
283
283
  console.assert(v == 4 * F);
284
- console.assert(O == 2 * E);
284
+ console.assert(L == 2 * E);
285
285
  }
286
286
  }
287
287
  };
288
288
  this.canvas = function() {
289
289
  return b() && a.canvas;
290
290
  };
291
- }(), la = h.onRuntimeInitialized;
292
- h.onRuntimeInitialized = function() {
291
+ }(), pa = k.onRuntimeInitialized;
292
+ k.onRuntimeInitialized = function() {
293
293
  function b(p) {
294
294
  switch(p) {
295
- case l.srcOver:
295
+ case n.srcOver:
296
296
  return "source-over";
297
- case l.screen:
297
+ case n.screen:
298
298
  return "screen";
299
- case l.overlay:
299
+ case n.overlay:
300
300
  return "overlay";
301
- case l.darken:
301
+ case n.darken:
302
302
  return "darken";
303
- case l.lighten:
303
+ case n.lighten:
304
304
  return "lighten";
305
- case l.colorDodge:
305
+ case n.colorDodge:
306
306
  return "color-dodge";
307
- case l.colorBurn:
307
+ case n.colorBurn:
308
308
  return "color-burn";
309
- case l.hardLight:
309
+ case n.hardLight:
310
310
  return "hard-light";
311
- case l.softLight:
311
+ case n.softLight:
312
312
  return "soft-light";
313
- case l.difference:
313
+ case n.difference:
314
314
  return "difference";
315
- case l.exclusion:
315
+ case n.exclusion:
316
316
  return "exclusion";
317
- case l.multiply:
317
+ case n.multiply:
318
318
  return "multiply";
319
- case l.hue:
319
+ case n.hue:
320
320
  return "hue";
321
- case l.saturation:
321
+ case n.saturation:
322
322
  return "saturation";
323
- case l.color:
323
+ case n.color:
324
324
  return "color";
325
- case l.luminosity:
325
+ case n.luminosity:
326
326
  return "luminosity";
327
327
  }
328
328
  }
@@ -330,7 +330,7 @@ h.onRuntimeInitialized = function() {
330
330
  return "rgba(" + ((16711680 & p) >>> 16) + "," + ((65280 & p) >>> 8) + "," + ((255 & p) >>> 0) + "," + ((4278190080 & p) >>> 24) / 255 + ")";
331
331
  }
332
332
  function c() {
333
- 0 < I.length && (ha.Qa(v.drawWidth(), v.drawHeight(), I, O, Z), I = [], Z = O = 0, v.reset(512, 512));
333
+ 0 < I.length && (oa.La(v.drawWidth(), v.drawHeight(), I, L, R), I = [], R = L = 0, v.reset(512, 512));
334
334
  for (const p of E) {
335
335
  for (const u of p.u) {
336
336
  u();
@@ -339,251 +339,251 @@ h.onRuntimeInitialized = function() {
339
339
  }
340
340
  E.clear();
341
341
  }
342
- la && la();
343
- var d = h.RenderPaintStyle;
344
- const e = h.RenderPath, f = h.RenderPaint, m = h.Renderer, k = h.StrokeCap, n = h.StrokeJoin, l = h.BlendMode, t = d.fill, w = d.stroke, x = h.FillRule.evenOdd;
342
+ pa && pa();
343
+ var d = k.RenderPaintStyle;
344
+ const e = k.RenderPath, f = k.RenderPaint, m = k.Renderer, h = k.StrokeCap, l = k.StrokeJoin, n = k.BlendMode, r = d.fill, w = d.stroke, y = k.FillRule.evenOdd;
345
345
  let g = 1;
346
- var r = h.RenderImage.extend("CanvasRenderImage", {__construct:function({R:p, W:u} = {}) {
346
+ var t = k.RenderImage.extend("CanvasRenderImage", {__construct:function({P:p, V:u} = {}) {
347
347
  this.__parent.__construct.call(this);
348
- this.da = g;
348
+ this.ca = g;
349
349
  g = g + 1 & 2147483647 || 1;
350
- this.R = p;
351
- this.W = u;
350
+ this.P = p;
351
+ this.V = u;
352
352
  }, __destruct:function() {
353
- this.ca && (ha.Ma(this.ca), URL.revokeObjectURL(this.la));
353
+ this.ba && (oa.Ia(this.ba), URL.revokeObjectURL(this.ka));
354
354
  this.__parent.__destruct.call(this);
355
355
  }, decode:function(p) {
356
356
  var u = this;
357
- u.W && u.W(u);
357
+ u.V && u.V(u);
358
358
  var A = new Image();
359
- u.la = URL.createObjectURL(new Blob([p], {type:"image/png",}));
359
+ u.ka = URL.createObjectURL(new Blob([p], {type:"image/png",}));
360
360
  A.onload = function() {
361
- u.Ga = A;
362
- u.ca = ha.La(A);
361
+ u.Ca = A;
362
+ u.ba = oa.Ha(A);
363
363
  u.size(A.width, A.height);
364
- u.R && u.R(u);
364
+ u.P && u.P(u);
365
365
  };
366
- A.src = u.la;
366
+ A.src = u.ka;
367
367
  },}), q = e.extend("CanvasRenderPath", {__construct:function() {
368
368
  this.__parent.__construct.call(this);
369
- this.F = new Path2D();
369
+ this.G = new Path2D();
370
370
  }, rewind:function() {
371
- this.F = new Path2D();
372
- }, addPath:function(p, u, A, D, y, B, G) {
373
- var H = this.F, V = H.addPath;
374
- p = p.F;
371
+ this.G = new Path2D();
372
+ }, addPath:function(p, u, A, D, z, B, G) {
373
+ var H = this.G, V = H.addPath;
374
+ p = p.G;
375
375
  const M = new DOMMatrix();
376
376
  M.a = u;
377
377
  M.b = A;
378
378
  M.c = D;
379
- M.d = y;
379
+ M.d = z;
380
380
  M.e = B;
381
381
  M.f = G;
382
382
  V.call(H, p, M);
383
383
  }, fillRule:function(p) {
384
- this.ka = p;
384
+ this.ja = p;
385
385
  }, moveTo:function(p, u) {
386
- this.F.moveTo(p, u);
386
+ this.G.moveTo(p, u);
387
387
  }, lineTo:function(p, u) {
388
- this.F.lineTo(p, u);
389
- }, cubicTo:function(p, u, A, D, y, B) {
390
- this.F.bezierCurveTo(p, u, A, D, y, B);
388
+ this.G.lineTo(p, u);
389
+ }, cubicTo:function(p, u, A, D, z, B) {
390
+ this.G.bezierCurveTo(p, u, A, D, z, B);
391
391
  }, close:function() {
392
- this.F.closePath();
392
+ this.G.closePath();
393
393
  },}), F = f.extend("CanvasRenderPaint", {color:function(p) {
394
- this.ma = a(p);
394
+ this.la = a(p);
395
395
  }, thickness:function(p) {
396
- this.Ja = p;
396
+ this.Fa = p;
397
397
  }, join:function(p) {
398
398
  switch(p) {
399
- case n.miter:
400
- this.ba = "miter";
399
+ case l.miter:
400
+ this.aa = "miter";
401
401
  break;
402
- case n.round:
403
- this.ba = "round";
402
+ case l.round:
403
+ this.aa = "round";
404
404
  break;
405
- case n.bevel:
406
- this.ba = "bevel";
405
+ case l.bevel:
406
+ this.aa = "bevel";
407
407
  }
408
408
  }, cap:function(p) {
409
409
  switch(p) {
410
- case k.butt:
411
- this.aa = "butt";
410
+ case h.butt:
411
+ this.$ = "butt";
412
412
  break;
413
- case k.round:
414
- this.aa = "round";
413
+ case h.round:
414
+ this.$ = "round";
415
415
  break;
416
- case k.square:
417
- this.aa = "square";
416
+ case h.square:
417
+ this.$ = "square";
418
418
  }
419
419
  }, style:function(p) {
420
- this.Ia = p;
420
+ this.Ea = p;
421
421
  }, blendMode:function(p) {
422
- this.Fa = b(p);
422
+ this.Ba = b(p);
423
423
  }, clearGradient:function() {
424
- this.P = null;
424
+ this.O = null;
425
425
  }, linearGradient:function(p, u, A, D) {
426
- this.P = {Ca:p, Da:u, qa:A, ra:D, ga:[],};
426
+ this.O = {ya:p, za:u, pa:A, qa:D, fa:[],};
427
427
  }, radialGradient:function(p, u, A, D) {
428
- this.P = {Ca:p, Da:u, qa:A, ra:D, ga:[], bb:!0,};
428
+ this.O = {ya:p, za:u, pa:A, qa:D, fa:[], Va:!0,};
429
429
  }, addStop:function(p, u) {
430
- this.P.ga.push({color:p, stop:u,});
430
+ this.O.fa.push({color:p, stop:u,});
431
431
  }, completeGradient:function() {
432
432
  }, draw:function(p, u, A) {
433
- let D = this.Ia;
434
- var y = this.ma, B = this.P;
435
- p.globalCompositeOperation = this.Fa;
433
+ let D = this.Ea;
434
+ var z = this.la, B = this.O;
435
+ p.globalCompositeOperation = this.Ba;
436
436
  if (null != B) {
437
- y = B.Ca;
438
- var G = B.Da;
439
- const V = B.qa;
440
- var H = B.ra;
441
- const M = B.ga;
442
- B.bb ? (B = V - y, H -= G, y = p.createRadialGradient(y, G, 0, y, G, Math.sqrt(B * B + H * H))) : y = p.createLinearGradient(y, G, V, H);
443
- for (let T = 0, N = M.length; T < N; T++) {
444
- G = M[T], y.addColorStop(G.stop, a(G.color));
437
+ z = B.ya;
438
+ var G = B.za;
439
+ const V = B.pa;
440
+ var H = B.qa;
441
+ const M = B.fa;
442
+ B.Va ? (B = V - z, H -= G, z = p.createRadialGradient(z, G, 0, z, G, Math.sqrt(B * B + H * H))) : z = p.createLinearGradient(z, G, V, H);
443
+ for (let U = 0, N = M.length; U < N; U++) {
444
+ G = M[U], z.addColorStop(G.stop, a(G.color));
445
445
  }
446
- this.ma = y;
447
- this.P = null;
446
+ this.la = z;
447
+ this.O = null;
448
448
  }
449
449
  switch(D) {
450
450
  case w:
451
- p.strokeStyle = y;
452
- p.lineWidth = this.Ja;
453
- p.lineCap = this.aa;
454
- p.lineJoin = this.ba;
451
+ p.strokeStyle = z;
452
+ p.lineWidth = this.Fa;
453
+ p.lineCap = this.$;
454
+ p.lineJoin = this.aa;
455
455
  p.stroke(u);
456
456
  break;
457
- case t:
458
- p.fillStyle = y, p.fill(u, A);
457
+ case r:
458
+ p.fillStyle = z, p.fill(u, A);
459
459
  }
460
460
  },});
461
461
  const E = new Set();
462
- let v = null, I = [], O = 0, Z = 0;
463
- var ia = h.CanvasRenderer = m.extend("Renderer", {__construct:function(p) {
462
+ let v = null, I = [], L = 0, R = 0;
463
+ var fa = k.CanvasRenderer = m.extend("Renderer", {__construct:function(p) {
464
464
  this.__parent.__construct.call(this);
465
- this.D = [1, 0, 0, 1, 0, 0];
466
- this.o = p.getContext("2d");
467
- this.ja = p;
465
+ this.F = [1, 0, 0, 1, 0, 0];
466
+ this.m = p.getContext("2d");
467
+ this.ia = p;
468
468
  this.u = [];
469
469
  }, save:function() {
470
- this.D.push(...this.D.slice(this.D.length - 6));
471
- this.u.push(this.o.save.bind(this.o));
470
+ this.F.push(...this.F.slice(this.F.length - 6));
471
+ this.u.push(this.m.save.bind(this.m));
472
472
  }, restore:function() {
473
- const p = this.D.length - 6;
473
+ const p = this.F.length - 6;
474
474
  if (6 > p) {
475
475
  throw "restore() called without matching save().";
476
476
  }
477
- this.D.splice(p);
478
- this.u.push(this.o.restore.bind(this.o));
479
- }, transform:function(p, u, A, D, y, B) {
480
- const G = this.D, H = G.length - 6;
481
- G.splice(H, 6, G[H] * p + G[H + 2] * u, G[H + 1] * p + G[H + 3] * u, G[H] * A + G[H + 2] * D, G[H + 1] * A + G[H + 3] * D, G[H] * y + G[H + 2] * B + G[H + 4], G[H + 1] * y + G[H + 3] * B + G[H + 5]);
482
- this.u.push(this.o.transform.bind(this.o, p, u, A, D, y, B));
477
+ this.F.splice(p);
478
+ this.u.push(this.m.restore.bind(this.m));
479
+ }, transform:function(p, u, A, D, z, B) {
480
+ const G = this.F, H = G.length - 6;
481
+ G.splice(H, 6, G[H] * p + G[H + 2] * u, G[H + 1] * p + G[H + 3] * u, G[H] * A + G[H + 2] * D, G[H + 1] * A + G[H + 3] * D, G[H] * z + G[H + 2] * B + G[H + 4], G[H + 1] * z + G[H + 3] * B + G[H + 5]);
482
+ this.u.push(this.m.transform.bind(this.m, p, u, A, D, z, B));
483
483
  }, rotate:function(p) {
484
484
  const u = Math.sin(p);
485
485
  p = Math.cos(p);
486
486
  this.transform(p, u, -u, p, 0, 0);
487
487
  }, _drawPath:function(p, u) {
488
- this.u.push(u.draw.bind(u, this.o, p.F, p.ka === x ? "evenodd" : "nonzero"));
488
+ this.u.push(u.draw.bind(u, this.m, p.G, p.ja === y ? "evenodd" : "nonzero"));
489
489
  }, _drawRiveImage:function(p, u, A, D) {
490
- var y = p.Ga;
491
- if (y) {
492
- var B = this.o, G = b(A);
490
+ var z = p.Ca;
491
+ if (z) {
492
+ var B = this.m, G = b(A);
493
493
  this.u.push(function() {
494
494
  B.globalCompositeOperation = G;
495
495
  B.globalAlpha = D;
496
- B.drawImage(y, 0, 0);
496
+ B.drawImage(z, 0, 0);
497
497
  B.globalAlpha = 1;
498
498
  });
499
499
  }
500
500
  }, _getMatrix:function(p) {
501
- const u = this.D, A = u.length - 6;
501
+ const u = this.F, A = u.length - 6;
502
502
  for (let D = 0; 6 > D; ++D) {
503
503
  p[D] = u[A + D];
504
504
  }
505
- }, _drawImageMesh:function(p, u, A, D, y, B, G, H, V, M, T) {
506
- u = this.o.canvas.width;
507
- var N = this.o.canvas.height;
508
- const tb = M - H, ub = T - V;
505
+ }, _drawImageMesh:function(p, u, A, D, z, B, G, H, V, M, U) {
506
+ u = this.m.canvas.width;
507
+ var N = this.m.canvas.height;
508
+ const rb = M - H, sb = U - V;
509
509
  H = Math.max(H, 0);
510
510
  V = Math.max(V, 0);
511
511
  M = Math.min(M, u);
512
- T = Math.min(T, N);
513
- const wa = M - H, xa = T - V;
514
- console.assert(wa <= Math.min(tb, u));
515
- console.assert(xa <= Math.min(ub, N));
516
- if (!(0 >= wa || 0 >= xa)) {
517
- M = wa < tb || xa < ub;
518
- u = T = 1;
519
- var ja = Math.ceil(wa * T), ka = Math.ceil(xa * u);
520
- N = ha.eb();
521
- ja > N && (T *= N / ja, ja = N);
522
- ka > N && (u *= N / ka, ka = N);
523
- v || (v = new h.DynamicRectanizer(N), v.reset(512, 512));
524
- N = v.addRect(ja, ka);
525
- 0 > N && (c(), E.add(this), N = v.addRect(ja, ka), console.assert(0 <= N));
526
- var vb = N & 65535, wb = N >> 16;
527
- I.push({N:this.D.slice(this.D.length - 6), image:p, na:vb, oa:wb, fb:H, gb:V, sb:ja, va:ka, X:T, Y:u, ia:new Float32Array(y), Ea:new Float32Array(B), indices:new Uint16Array(G), hb:M, Ba:p.da << 1 | (M ? 1 : 0),});
528
- O += y.length;
529
- Z += G.length;
530
- var pa = this.o, oc = b(A);
512
+ U = Math.min(U, N);
513
+ const ta = M - H, ua = U - V;
514
+ console.assert(ta <= Math.min(rb, u));
515
+ console.assert(ua <= Math.min(sb, N));
516
+ if (!(0 >= ta || 0 >= ua)) {
517
+ M = ta < rb || ua < sb;
518
+ u = U = 1;
519
+ var ha = Math.ceil(ta * U), ia = Math.ceil(ua * u);
520
+ N = oa.Wa();
521
+ ha > N && (U *= N / ha, ha = N);
522
+ ia > N && (u *= N / ia, ia = N);
523
+ v || (v = new k.DynamicRectanizer(N), v.reset(512, 512));
524
+ N = v.addRect(ha, ia);
525
+ 0 > N && (c(), E.add(this), N = v.addRect(ha, ia), console.assert(0 <= N));
526
+ var tb = N & 65535, ub = N >> 16;
527
+ I.push({M:this.F.slice(this.F.length - 6), image:p, ma:tb, na:ub, Xa:H, Ya:V, kb:ha, sa:ia, W:U, X:u, ha:new Float32Array(z), Aa:new Float32Array(B), indices:new Uint16Array(G), Za:M, xa:p.ca << 1 | (M ? 1 : 0),});
528
+ L += z.length;
529
+ R += G.length;
530
+ var ma = this.m, lc = b(A);
531
531
  this.u.push(function() {
532
- pa.save();
533
- pa.resetTransform();
534
- pa.globalCompositeOperation = oc;
535
- pa.globalAlpha = D;
536
- const xb = ha.canvas();
537
- xb && pa.drawImage(xb, vb, wb, ja, ka, H, V, wa, xa);
538
- pa.restore();
532
+ ma.save();
533
+ ma.resetTransform();
534
+ ma.globalCompositeOperation = lc;
535
+ ma.globalAlpha = D;
536
+ const vb = oa.canvas();
537
+ vb && ma.drawImage(vb, tb, ub, ha, ia, H, V, ta, ua);
538
+ ma.restore();
539
539
  });
540
540
  }
541
541
  }, _clipPath:function(p) {
542
- this.u.push(this.o.clip.bind(this.o, p.F, p.ka === x ? "evenodd" : "nonzero"));
542
+ this.u.push(this.m.clip.bind(this.m, p.G, p.ja === y ? "evenodd" : "nonzero"));
543
543
  }, clear:function() {
544
544
  E.add(this);
545
- this.u.push(this.o.clearRect.bind(this.o, 0, 0, this.ja.width, this.ja.height));
545
+ this.u.push(this.m.clearRect.bind(this.m, 0, 0, this.ia.width, this.ia.height));
546
546
  }, flush:function() {
547
547
  }, translate:function(p, u) {
548
548
  this.transform(1, 0, 0, 1, p, u);
549
549
  },});
550
- h.makeRenderer = function(p) {
551
- const u = new ia(p), A = u.o;
552
- return new Proxy(u, {get(D, y) {
553
- if ("function" === typeof D[y]) {
550
+ k.makeRenderer = function(p) {
551
+ const u = new fa(p), A = u.m;
552
+ return new Proxy(u, {get(D, z) {
553
+ if ("function" === typeof D[z]) {
554
554
  return function(...B) {
555
- return D[y].apply(D, B);
555
+ return D[z].apply(D, B);
556
556
  };
557
557
  }
558
- if ("function" === typeof A[y]) {
559
- if (-1 < fa.indexOf(y)) {
560
- throw Error("RiveException: Method call to '" + y + "()' is not allowed, as the renderer cannot immediately pass through the return values of any canvas 2d context methods.");
558
+ if ("function" === typeof A[z]) {
559
+ if (-1 < na.indexOf(z)) {
560
+ throw Error("RiveException: Method call to '" + z + "()' is not allowed, as the renderer cannot immediately pass through the return values of any canvas 2d context methods.");
561
561
  }
562
562
  return function(...B) {
563
- u.u.push(A[y].bind(A, ...B));
563
+ u.u.push(A[z].bind(A, ...B));
564
564
  };
565
565
  }
566
- return D[y];
567
- }, set(D, y, B) {
568
- if (y in A) {
566
+ return D[z];
567
+ }, set(D, z, B) {
568
+ if (z in A) {
569
569
  return u.u.push(() => {
570
- A[y] = B;
570
+ A[z] = B;
571
571
  }), !0;
572
572
  }
573
573
  },});
574
574
  };
575
- h.decodeImage = function(p, u) {
576
- (new r({R:u})).decode(p);
575
+ k.decodeImage = function(p, u) {
576
+ (new t({P:u})).decode(p);
577
577
  };
578
- h.renderFactory = {makeRenderPaint:function() {
578
+ k.renderFactory = {makeRenderPaint:function() {
579
579
  return new F();
580
580
  }, makeRenderPath:function() {
581
581
  return new q();
582
582
  }, makeRenderImage:function() {
583
- let p = Y;
584
- return new r({W:() => {
583
+ let p = W;
584
+ return new t({V:() => {
585
585
  p.total++;
586
- }, R:() => {
586
+ }, P:() => {
587
587
  p.loaded++;
588
588
  if (p.loaded === p.total) {
589
589
  const u = p.ready;
@@ -591,187 +591,153 @@ h.onRuntimeInitialized = function() {
591
591
  }
592
592
  },});
593
593
  },};
594
- let C = h.load, Y = null;
595
- h.load = function(p, u, A = !0) {
596
- const D = new h.FallbackFileAssetLoader();
594
+ let C = k.load, W = null;
595
+ k.load = function(p, u, A = !0) {
596
+ const D = new k.FallbackFileAssetLoader();
597
597
  void 0 !== u && D.addLoader(u);
598
- A && (u = new h.CDNFileAssetLoader(), D.addLoader(u));
599
- return new Promise(function(y) {
598
+ A && (u = new k.CDNFileAssetLoader(), D.addLoader(u));
599
+ return new Promise(function(z) {
600
600
  let B = null;
601
- Y = {total:0, loaded:0, ready:function() {
602
- y(B);
601
+ W = {total:0, loaded:0, ready:function() {
602
+ z(B);
603
603
  },};
604
604
  B = C(p, D);
605
- 0 == Y.total && y(B);
605
+ 0 == W.total && z(B);
606
606
  });
607
607
  };
608
- let pc = h.RendererWrapper.prototype.align;
609
- h.RendererWrapper.prototype.align = function(p, u, A, D, y = 1.0) {
610
- pc.call(this, p, u, A, D, y);
608
+ let mc = k.RendererWrapper.prototype.align;
609
+ k.RendererWrapper.prototype.align = function(p, u, A, D, z = 1.0) {
610
+ mc.call(this, p, u, A, D, z);
611
611
  };
612
- d = new ca();
613
- h.requestAnimationFrame = d.requestAnimationFrame.bind(d);
614
- h.cancelAnimationFrame = d.cancelAnimationFrame.bind(d);
615
- h.enableFPSCounter = d.Ra.bind(d);
616
- h.disableFPSCounter = d.Oa;
617
- d.xa = c;
618
- h.resolveAnimationFrame = c;
619
- h.cleanup = function() {
612
+ d = new ja();
613
+ k.requestAnimationFrame = d.requestAnimationFrame.bind(d);
614
+ k.cancelAnimationFrame = d.cancelAnimationFrame.bind(d);
615
+ k.enableFPSCounter = d.Ma.bind(d);
616
+ k.disableFPSCounter = d.Ja;
617
+ d.ua = c;
618
+ k.resolveAnimationFrame = c;
619
+ k.cleanup = function() {
620
620
  v && v.delete();
621
621
  };
622
622
  };
623
- var ma = Object.assign({}, h), na = "./this.program", oa = "object" == typeof window, qa = "function" == typeof importScripts, ra = "", sa, ta;
624
- if (oa || qa) {
625
- qa ? ra = self.location.href : "undefined" != typeof document && document.currentScript && (ra = document.currentScript.src), _scriptDir && (ra = _scriptDir), 0 !== ra.indexOf("blob:") ? ra = ra.substr(0, ra.replace(/[?#].*/, "").lastIndexOf("/") + 1) : ra = "", qa && (ta = b => {
623
+ var qa = Object.assign({}, k), ra = "./this.program", x = "", sa, va;
624
+ if (da || ea) {
625
+ ea ? x = self.location.href : "undefined" != typeof document && document.currentScript && (x = document.currentScript.src), _scriptName && (x = _scriptName), x.startsWith("blob:") ? x = "" : x = x.substr(0, x.replace(/[?#].*/, "").lastIndexOf("/") + 1), ea && (va = b => {
626
626
  var a = new XMLHttpRequest();
627
627
  a.open("GET", b, !1);
628
628
  a.responseType = "arraybuffer";
629
629
  a.send(null);
630
630
  return new Uint8Array(a.response);
631
631
  }), sa = (b, a, c) => {
632
- var d = new XMLHttpRequest();
633
- d.open("GET", b, !0);
634
- d.responseType = "arraybuffer";
635
- d.onload = () => {
636
- 200 == d.status || 0 == d.status && d.response ? a(d.response) : c();
637
- };
638
- d.onerror = c;
639
- d.send(null);
632
+ if (wa(b)) {
633
+ var d = new XMLHttpRequest();
634
+ d.open("GET", b, !0);
635
+ d.responseType = "arraybuffer";
636
+ d.onload = () => {
637
+ 200 == d.status || 0 == d.status && d.response ? a(d.response) : c();
638
+ };
639
+ d.onerror = c;
640
+ d.send(null);
641
+ } else {
642
+ fetch(b, {credentials:"same-origin"}).then(e => e.ok ? e.arrayBuffer() : Promise.reject(Error(e.status + " : " + e.url))).then(a, c);
643
+ }
640
644
  };
641
645
  }
642
- var ua = h.print || console.log.bind(console), va = h.printErr || console.error.bind(console);
643
- Object.assign(h, ma);
644
- ma = null;
645
- h.thisProgram && (na = h.thisProgram);
646
- var ya;
647
- h.wasmBinary && (ya = h.wasmBinary);
648
- var noExitRuntime = h.noExitRuntime || !0;
649
- "object" != typeof WebAssembly && za("no native wasm support detected");
650
- var Aa, z, Ba = !1, Ca, J, Da, Ea, K, L, Fa, Ga;
646
+ var xa = k.print || console.log.bind(console), ya = k.printErr || console.error.bind(console);
647
+ Object.assign(k, qa);
648
+ qa = null;
649
+ k.thisProgram && (ra = k.thisProgram);
650
+ var za;
651
+ k.wasmBinary && (za = k.wasmBinary);
652
+ var Aa, Ba = !1, Ca, J, Da, Ea, K, O, Fa, Ga;
651
653
  function Ha() {
652
654
  var b = Aa.buffer;
653
- h.HEAP8 = Ca = new Int8Array(b);
654
- h.HEAP16 = Da = new Int16Array(b);
655
- h.HEAP32 = K = new Int32Array(b);
656
- h.HEAPU8 = J = new Uint8Array(b);
657
- h.HEAPU16 = Ea = new Uint16Array(b);
658
- h.HEAPU32 = L = new Uint32Array(b);
659
- h.HEAPF32 = Fa = new Float32Array(b);
660
- h.HEAPF64 = Ga = new Float64Array(b);
661
- }
662
- var Ia, Ja = [], Ka = [], La = [];
663
- function Ma() {
664
- var b = h.preRun.shift();
665
- Ja.unshift(b);
666
- }
667
- var Na = 0, Oa = null, Pa = null;
668
- function za(b) {
669
- if (h.onAbort) {
670
- h.onAbort(b);
671
- }
655
+ k.HEAP8 = Ca = new Int8Array(b);
656
+ k.HEAP16 = Da = new Int16Array(b);
657
+ k.HEAPU8 = J = new Uint8Array(b);
658
+ k.HEAPU16 = Ea = new Uint16Array(b);
659
+ k.HEAP32 = K = new Int32Array(b);
660
+ k.HEAPU32 = O = new Uint32Array(b);
661
+ k.HEAPF32 = Fa = new Float32Array(b);
662
+ k.HEAPF64 = Ga = new Float64Array(b);
663
+ }
664
+ var Ia = [], Ja = [], Ka = [];
665
+ function La() {
666
+ var b = k.preRun.shift();
667
+ Ia.unshift(b);
668
+ }
669
+ var Ma = 0, Na = null, Oa = null;
670
+ function Pa(b) {
671
+ k.onAbort?.(b);
672
672
  b = "Aborted(" + b + ")";
673
- va(b);
673
+ ya(b);
674
674
  Ba = !0;
675
675
  b = new WebAssembly.RuntimeError(b + ". Build with -sASSERTIONS for more info.");
676
676
  ba(b);
677
677
  throw b;
678
678
  }
679
- function Qa(b) {
680
- return b.startsWith("data:application/octet-stream;base64,");
681
- }
682
- var Ra;
683
- Ra = "canvas_advanced.wasm";
684
- if (!Qa(Ra)) {
685
- var Sa = Ra;
686
- Ra = h.locateFile ? h.locateFile(Sa, ra) : ra + Sa;
687
- }
688
- function Ta(b) {
689
- if (b == Ra && ya) {
690
- return new Uint8Array(ya);
679
+ var Qa = b => b.startsWith("data:application/octet-stream;base64,"), wa = b => b.startsWith("file://"), Ra;
680
+ function Sa(b) {
681
+ if (b == Ra && za) {
682
+ return new Uint8Array(za);
691
683
  }
692
- if (ta) {
693
- return ta(b);
684
+ if (va) {
685
+ return va(b);
694
686
  }
695
687
  throw "both async and sync fetching of the wasm failed";
696
688
  }
697
- function Ua(b) {
698
- if (!ya && (oa || qa)) {
699
- if ("function" == typeof fetch && !b.startsWith("file://")) {
700
- return fetch(b, {credentials:"same-origin"}).then(a => {
701
- if (!a.ok) {
702
- throw "failed to load wasm binary file at '" + b + "'";
703
- }
704
- return a.arrayBuffer();
705
- }).catch(() => Ta(b));
706
- }
707
- if (sa) {
708
- return new Promise((a, c) => {
709
- sa(b, d => a(new Uint8Array(d)), c);
710
- });
711
- }
712
- }
713
- return Promise.resolve().then(() => Ta(b));
689
+ function Ta(b) {
690
+ return za ? Promise.resolve().then(() => Sa(b)) : new Promise((a, c) => {
691
+ sa(b, d => a(new Uint8Array(d)), () => {
692
+ try {
693
+ a(Sa(b));
694
+ } catch (d) {
695
+ c(d);
696
+ }
697
+ });
698
+ });
714
699
  }
715
- function Va(b, a, c) {
716
- return Ua(b).then(d => WebAssembly.instantiate(d, a)).then(d => d).then(c, d => {
717
- va("failed to asynchronously prepare wasm: " + d);
718
- za(d);
700
+ function Ua(b, a, c) {
701
+ return Ta(b).then(d => WebAssembly.instantiate(d, a)).then(c, d => {
702
+ ya(`failed to asynchronously prepare wasm: ${d}`);
703
+ Pa(d);
719
704
  });
720
705
  }
721
- function Wa(b, a) {
706
+ function Va(b, a) {
722
707
  var c = Ra;
723
- return ya || "function" != typeof WebAssembly.instantiateStreaming || Qa(c) || c.startsWith("file://") || "function" != typeof fetch ? Va(c, b, a) : fetch(c, {credentials:"same-origin"}).then(d => WebAssembly.instantiateStreaming(d, b).then(a, function(e) {
724
- va("wasm streaming compile failed: " + e);
725
- va("falling back to ArrayBuffer instantiation");
726
- return Va(c, b, a);
708
+ return za || "function" != typeof WebAssembly.instantiateStreaming || Qa(c) || wa(c) || "function" != typeof fetch ? Ua(c, b, a) : fetch(c, {credentials:"same-origin"}).then(d => WebAssembly.instantiateStreaming(d, b).then(a, function(e) {
709
+ ya(`wasm streaming compile failed: ${e}`);
710
+ ya("falling back to ArrayBuffer instantiation");
711
+ return Ua(c, b, a);
727
712
  }));
728
713
  }
729
- var Xa = b => {
714
+ var Wa = b => {
730
715
  for (; 0 < b.length;) {
731
- b.shift()(h);
716
+ b.shift()(k);
732
717
  }
733
- };
734
- function Ya(b) {
735
- if (void 0 === b) {
736
- return "_unknown";
718
+ }, Xa = (b, a) => Object.defineProperty(a, "name", {value:b}), Ya = [], P = [], Q, S = b => {
719
+ if (!b) {
720
+ throw new Q("Cannot use deleted val. handle = " + b);
737
721
  }
738
- b = b.replace(/[^a-zA-Z0-9_]/g, "$");
739
- var a = b.charCodeAt(0);
740
- return 48 <= a && 57 >= a ? `_${b}` : b;
741
- }
742
- function Za(b, a) {
743
- b = Ya(b);
744
- return {[b]:function() {
745
- return a.apply(this, arguments);
746
- }}[b];
747
- }
748
- function $a() {
749
- this.G = [void 0];
750
- this.ta = [];
751
- }
752
- var P = new $a(), ab = void 0;
753
- function Q(b) {
754
- throw new ab(b);
755
- }
756
- var R = b => {
757
- b || Q("Cannot use deleted val. handle = " + b);
758
- return P.get(b).value;
759
- }, S = b => {
722
+ return P[b];
723
+ }, Za = b => {
760
724
  switch(b) {
761
725
  case void 0:
762
- return 1;
763
- case null:
764
726
  return 2;
727
+ case null:
728
+ return 4;
765
729
  case !0:
766
- return 3;
730
+ return 6;
767
731
  case !1:
768
- return 4;
732
+ return 8;
769
733
  default:
770
- return P.Za({Aa:1, value:b});
734
+ const a = Ya.pop() || P.length;
735
+ P[a] = b;
736
+ P[a + 1] = 1;
737
+ return a;
771
738
  }
772
- };
773
- function bb(b) {
774
- var a = Error, c = Za(b, function(d) {
739
+ }, $a = b => {
740
+ var a = Error, c = Xa(b, function(d) {
775
741
  this.name = b;
776
742
  this.message = d;
777
743
  d = Error(d).stack;
@@ -783,408 +749,435 @@ function bb(b) {
783
749
  return void 0 === this.message ? this.name : `${this.name}: ${this.message}`;
784
750
  };
785
751
  return c;
786
- }
787
- var cb = void 0, db = void 0;
788
- function U(b) {
752
+ }, ab, bb, T = b => {
789
753
  for (var a = ""; J[b];) {
790
- a += db[J[b++]];
754
+ a += bb[J[b++]];
791
755
  }
792
756
  return a;
793
- }
794
- var eb = [];
795
- function fb() {
796
- for (; eb.length;) {
797
- var b = eb.pop();
798
- b.g.M = !1;
757
+ }, cb = [], db = () => {
758
+ for (; cb.length;) {
759
+ var b = cb.pop();
760
+ b.g.L = !1;
799
761
  b["delete"]();
800
762
  }
801
- }
802
- var gb = void 0, hb = {};
803
- function ib(b, a) {
804
- for (void 0 === a && Q("ptr should not be undefined"); b.l;) {
805
- a = b.S(a), b = b.l;
763
+ }, eb, fb = {}, gb = (b, a) => {
764
+ if (void 0 === a) {
765
+ throw new Q("ptr should not be undefined");
766
+ }
767
+ for (; b.o;) {
768
+ a = b.R(a), b = b.o;
806
769
  }
807
770
  return a;
808
- }
809
- var jb = {};
810
- function kb(b) {
811
- b = lb(b);
812
- var a = U(b);
813
- mb(b);
771
+ }, hb = {}, kb = b => {
772
+ b = ib(b);
773
+ var a = T(b);
774
+ jb(b);
814
775
  return a;
815
- }
816
- function nb(b, a) {
817
- var c = jb[b];
818
- void 0 === c && Q(a + " has unknown type " + kb(b));
776
+ }, lb = (b, a) => {
777
+ var c = hb[b];
778
+ if (void 0 === c) {
779
+ throw b = `${a} has unknown type ${kb(b)}`, new Q(b);
780
+ }
819
781
  return c;
820
- }
821
- function ob() {
822
- }
823
- var pb = !1;
824
- function qb(b) {
825
- --b.count.value;
826
- 0 === b.count.value && (b.s ? b.A.H(b.s) : b.j.h.H(b.i));
827
- }
828
- function rb(b, a, c) {
782
+ }, mb = () => {
783
+ }, nb = !1, ob = (b, a, c) => {
829
784
  if (a === c) {
830
785
  return b;
831
786
  }
832
- if (void 0 === c.l) {
787
+ if (void 0 === c.o) {
833
788
  return null;
834
789
  }
835
- b = rb(b, a, c.l);
836
- return null === b ? null : c.Pa(b);
837
- }
838
- var sb = {};
839
- function yb(b, a) {
840
- a = ib(b, a);
841
- return hb[a];
842
- }
843
- var zb = void 0;
844
- function Ab(b) {
845
- throw new zb(b);
846
- }
847
- function Bb(b, a) {
848
- a.j && a.i || Ab("makeClassHandle requires ptr and ptrType");
849
- !!a.A !== !!a.s && Ab("Both smartPtrType and smartPtr must be specified");
790
+ b = ob(b, a, c.o);
791
+ return null === b ? null : c.Ka(b);
792
+ }, pb = {}, qb = (b, a) => {
793
+ a = gb(b, a);
794
+ return fb[a];
795
+ }, wb, yb = (b, a) => {
796
+ if (!a.j || !a.i) {
797
+ throw new wb("makeClassHandle requires ptr and ptrType");
798
+ }
799
+ if (!!a.v !== !!a.s) {
800
+ throw new wb("Both smartPtrType and smartPtr must be specified");
801
+ }
850
802
  a.count = {value:1};
851
- return Cb(Object.create(b, {g:{value:a,},}));
852
- }
853
- function Cb(b) {
803
+ return xb(Object.create(b, {g:{value:a, writable:!0,},}));
804
+ }, xb = b => {
854
805
  if ("undefined" === typeof FinalizationRegistry) {
855
- return Cb = a => a, b;
806
+ return xb = a => a, b;
856
807
  }
857
- pb = new FinalizationRegistry(a => {
858
- qb(a.g);
808
+ nb = new FinalizationRegistry(a => {
809
+ a = a.g;
810
+ --a.count.value;
811
+ 0 === a.count.value && (a.s ? a.v.C(a.s) : a.j.h.C(a.i));
859
812
  });
860
- Cb = a => {
813
+ xb = a => {
861
814
  var c = a.g;
862
- c.s && pb.register(a, {g:c}, a);
815
+ c.s && nb.register(a, {g:c}, a);
863
816
  return a;
864
817
  };
865
- ob = a => {
866
- pb.unregister(a);
818
+ mb = a => {
819
+ nb.unregister(a);
867
820
  };
868
- return Cb(b);
869
- }
870
- var Db = {};
871
- function Eb(b) {
821
+ return xb(b);
822
+ }, zb = {}, Ab = b => {
872
823
  for (; b.length;) {
873
824
  var a = b.pop();
874
825
  b.pop()(a);
875
826
  }
876
- }
877
- function Fb(b) {
878
- return this.fromWireType(K[b >> 2]);
879
- }
880
- var Gb = {}, Hb = {};
881
- function W(b, a, c) {
882
- function d(k) {
883
- k = c(k);
884
- k.length !== b.length && Ab("Mismatched type converter count");
885
- for (var n = 0; n < b.length; ++n) {
886
- Ib(b[n], k[n]);
827
+ };
828
+ function Bb(b) {
829
+ return this.fromWireType(O[b >> 2]);
830
+ }
831
+ var Cb = {}, Db = {}, X = (b, a, c) => {
832
+ function d(h) {
833
+ h = c(h);
834
+ if (h.length !== b.length) {
835
+ throw new wb("Mismatched type converter count");
836
+ }
837
+ for (var l = 0; l < b.length; ++l) {
838
+ Eb(b[l], h[l]);
887
839
  }
888
840
  }
889
- b.forEach(function(k) {
890
- Hb[k] = a;
841
+ b.forEach(function(h) {
842
+ Db[h] = a;
891
843
  });
892
844
  var e = Array(a.length), f = [], m = 0;
893
- a.forEach((k, n) => {
894
- jb.hasOwnProperty(k) ? e[n] = jb[k] : (f.push(k), Gb.hasOwnProperty(k) || (Gb[k] = []), Gb[k].push(() => {
895
- e[n] = jb[k];
845
+ a.forEach((h, l) => {
846
+ hb.hasOwnProperty(h) ? e[l] = hb[h] : (f.push(h), Cb.hasOwnProperty(h) || (Cb[h] = []), Cb[h].push(() => {
847
+ e[l] = hb[h];
896
848
  ++m;
897
849
  m === f.length && d(e);
898
850
  }));
899
851
  });
900
852
  0 === f.length && d(e);
901
- }
902
- function Jb(b) {
903
- switch(b) {
904
- case 1:
905
- return 0;
906
- case 2:
907
- return 1;
908
- case 4:
909
- return 2;
910
- case 8:
911
- return 3;
912
- default:
913
- throw new TypeError(`Unknown type size: ${b}`);
914
- }
915
- }
916
- function Kb(b, a, c = {}) {
853
+ };
854
+ function Fb(b, a, c = {}) {
917
855
  var d = a.name;
918
- b || Q(`type "${d}" must have a positive integer typeid pointer`);
919
- if (jb.hasOwnProperty(b)) {
920
- if (c.ab) {
856
+ if (!b) {
857
+ throw new Q(`type "${d}" must have a positive integer typeid pointer`);
858
+ }
859
+ if (hb.hasOwnProperty(b)) {
860
+ if (c.Ua) {
921
861
  return;
922
862
  }
923
- Q(`Cannot register type '${d}' twice`);
863
+ throw new Q(`Cannot register type '${d}' twice`);
924
864
  }
925
- jb[b] = a;
926
- delete Hb[b];
927
- Gb.hasOwnProperty(b) && (a = Gb[b], delete Gb[b], a.forEach(e => e()));
865
+ hb[b] = a;
866
+ delete Db[b];
867
+ Cb.hasOwnProperty(b) && (a = Cb[b], delete Cb[b], a.forEach(e => e()));
928
868
  }
929
- function Ib(b, a, c = {}) {
869
+ function Eb(b, a, c = {}) {
930
870
  if (!("argPackAdvance" in a)) {
931
871
  throw new TypeError("registerType registeredInstance requires argPackAdvance");
932
872
  }
933
- Kb(b, a, c);
873
+ return Fb(b, a, c);
934
874
  }
935
- function Lb(b) {
936
- Q(b.g.j.h.name + " instance already deleted");
937
- }
938
- function Mb() {
875
+ var Gb = b => {
876
+ throw new Q(b.g.j.h.name + " instance already deleted");
877
+ };
878
+ function Hb() {
939
879
  }
940
- function Nb(b, a, c) {
941
- if (void 0 === b[a].m) {
880
+ var Ib = (b, a, c) => {
881
+ if (void 0 === b[a].l) {
942
882
  var d = b[a];
943
- b[a] = function() {
944
- b[a].m.hasOwnProperty(arguments.length) || Q(`Function '${c}' called with an invalid number of arguments (${arguments.length}) - expects one of (${b[a].m})!`);
945
- return b[a].m[arguments.length].apply(this, arguments);
883
+ b[a] = function(...e) {
884
+ if (!b[a].l.hasOwnProperty(e.length)) {
885
+ throw new Q(`Function '${c}' called with an invalid number of arguments (${e.length}) - expects one of (${b[a].l})!`);
886
+ }
887
+ return b[a].l[e.length].apply(this, e);
946
888
  };
947
- b[a].m = [];
948
- b[a].m[d.L] = d;
889
+ b[a].l = [];
890
+ b[a].l[d.K] = d;
949
891
  }
950
- }
951
- function Ob(b, a, c) {
952
- h.hasOwnProperty(b) ? ((void 0 === c || void 0 !== h[b].m && void 0 !== h[b].m[c]) && Q(`Cannot register public name '${b}' twice`), Nb(h, b, b), h.hasOwnProperty(c) && Q(`Cannot register multiple overloads of a function with the same number of arguments (${c})!`), h[b].m[c] = a) : (h[b] = a, void 0 !== c && (h[b].tb = c));
953
- }
954
- function Pb(b, a, c, d, e, f, m, k) {
892
+ }, Jb = (b, a, c) => {
893
+ if (k.hasOwnProperty(b)) {
894
+ if (void 0 === c || void 0 !== k[b].l && void 0 !== k[b].l[c]) {
895
+ throw new Q(`Cannot register public name '${b}' twice`);
896
+ }
897
+ Ib(k, b, b);
898
+ if (k.hasOwnProperty(c)) {
899
+ throw new Q(`Cannot register multiple overloads of a function with the same number of arguments (${c})!`);
900
+ }
901
+ k[b].l[c] = a;
902
+ } else {
903
+ k[b] = a, void 0 !== c && (k[b].mb = c);
904
+ }
905
+ }, Kb = b => {
906
+ if (void 0 === b) {
907
+ return "_unknown";
908
+ }
909
+ b = b.replace(/[^a-zA-Z0-9_]/g, "$");
910
+ var a = b.charCodeAt(0);
911
+ return 48 <= a && 57 >= a ? `_${b}` : b;
912
+ };
913
+ function Lb(b, a, c, d, e, f, m, h) {
955
914
  this.name = b;
956
915
  this.constructor = a;
957
916
  this.B = c;
958
- this.H = d;
959
- this.l = e;
960
- this.Ua = f;
961
- this.S = m;
962
- this.Pa = k;
963
- this.ya = [];
964
- }
965
- function Qb(b, a, c) {
917
+ this.C = d;
918
+ this.o = e;
919
+ this.Pa = f;
920
+ this.R = m;
921
+ this.Ka = h;
922
+ this.va = [];
923
+ }
924
+ var Mb = (b, a, c) => {
966
925
  for (; a !== c;) {
967
- a.S || Q(`Expected null or instance of ${c.name}, got an instance of ${a.name}`), b = a.S(b), a = a.l;
926
+ if (!a.R) {
927
+ throw new Q(`Expected null or instance of ${c.name}, got an instance of ${a.name}`);
928
+ }
929
+ b = a.R(b);
930
+ a = a.o;
968
931
  }
969
932
  return b;
970
- }
971
- function Rb(b, a) {
933
+ };
934
+ function Nb(b, a) {
972
935
  if (null === a) {
973
- return this.ea && Q(`null is not a valid ${this.name}`), 0;
936
+ if (this.da) {
937
+ throw new Q(`null is not a valid ${this.name}`);
938
+ }
939
+ return 0;
940
+ }
941
+ if (!a.g) {
942
+ throw new Q(`Cannot pass "${Ob(a)}" as a ${this.name}`);
943
+ }
944
+ if (!a.g.i) {
945
+ throw new Q(`Cannot pass deleted object as a pointer of type ${this.name}`);
974
946
  }
975
- a.g || Q(`Cannot pass "${Sb(a)}" as a ${this.name}`);
976
- a.g.i || Q(`Cannot pass deleted object as a pointer of type ${this.name}`);
977
- return Qb(a.g.i, a.g.j.h, this.h);
947
+ return Mb(a.g.i, a.g.j.h, this.h);
978
948
  }
979
- function Tb(b, a) {
949
+ function Pb(b, a) {
980
950
  if (null === a) {
981
- this.ea && Q(`null is not a valid ${this.name}`);
982
- if (this.V) {
983
- var c = this.fa();
984
- null !== b && b.push(this.H, c);
951
+ if (this.da) {
952
+ throw new Q(`null is not a valid ${this.name}`);
953
+ }
954
+ if (this.U) {
955
+ var c = this.ea();
956
+ null !== b && b.push(this.C, c);
985
957
  return c;
986
958
  }
987
959
  return 0;
988
960
  }
989
- a.g || Q(`Cannot pass "${Sb(a)}" as a ${this.name}`);
990
- a.g.i || Q(`Cannot pass deleted object as a pointer of type ${this.name}`);
991
- !this.U && a.g.j.U && Q(`Cannot convert argument of type ${a.g.A ? a.g.A.name : a.g.j.name} to parameter type ${this.name}`);
992
- c = Qb(a.g.i, a.g.j.h, this.h);
993
- if (this.V) {
994
- switch(void 0 === a.g.s && Q("Passing raw pointer to smart pointer is illegal"), this.nb) {
961
+ if (!a || !a.g) {
962
+ throw new Q(`Cannot pass "${Ob(a)}" as a ${this.name}`);
963
+ }
964
+ if (!a.g.i) {
965
+ throw new Q(`Cannot pass deleted object as a pointer of type ${this.name}`);
966
+ }
967
+ if (!this.T && a.g.j.T) {
968
+ throw new Q(`Cannot convert argument of type ${a.g.v ? a.g.v.name : a.g.j.name} to parameter type ${this.name}`);
969
+ }
970
+ c = Mb(a.g.i, a.g.j.h, this.h);
971
+ if (this.U) {
972
+ if (void 0 === a.g.s) {
973
+ throw new Q("Passing raw pointer to smart pointer is illegal");
974
+ }
975
+ switch(this.fb) {
995
976
  case 0:
996
- a.g.A === this ? c = a.g.s : Q(`Cannot convert argument of type ${a.g.A ? a.g.A.name : a.g.j.name} to parameter type ${this.name}`);
977
+ if (a.g.v === this) {
978
+ c = a.g.s;
979
+ } else {
980
+ throw new Q(`Cannot convert argument of type ${a.g.v ? a.g.v.name : a.g.j.name} to parameter type ${this.name}`);
981
+ }
997
982
  break;
998
983
  case 1:
999
984
  c = a.g.s;
1000
985
  break;
1001
986
  case 2:
1002
- if (a.g.A === this) {
987
+ if (a.g.v === this) {
1003
988
  c = a.g.s;
1004
989
  } else {
1005
990
  var d = a.clone();
1006
- c = this.jb(c, S(function() {
1007
- d["delete"]();
1008
- }));
1009
- null !== b && b.push(this.H, c);
991
+ c = this.ab(c, Za(() => d["delete"]()));
992
+ null !== b && b.push(this.C, c);
1010
993
  }
1011
994
  break;
1012
995
  default:
1013
- Q("Unsupporting sharing policy");
996
+ throw new Q("Unsupporting sharing policy");
1014
997
  }
1015
998
  }
1016
999
  return c;
1017
1000
  }
1018
- function Ub(b, a) {
1001
+ function Qb(b, a) {
1019
1002
  if (null === a) {
1020
- return this.ea && Q(`null is not a valid ${this.name}`), 0;
1003
+ if (this.da) {
1004
+ throw new Q(`null is not a valid ${this.name}`);
1005
+ }
1006
+ return 0;
1007
+ }
1008
+ if (!a.g) {
1009
+ throw new Q(`Cannot pass "${Ob(a)}" as a ${this.name}`);
1021
1010
  }
1022
- a.g || Q(`Cannot pass "${Sb(a)}" as a ${this.name}`);
1023
- a.g.i || Q(`Cannot pass deleted object as a pointer of type ${this.name}`);
1024
- a.g.j.U && Q(`Cannot convert argument of type ${a.g.j.name} to parameter type ${this.name}`);
1025
- return Qb(a.g.i, a.g.j.h, this.h);
1011
+ if (!a.g.i) {
1012
+ throw new Q(`Cannot pass deleted object as a pointer of type ${this.name}`);
1013
+ }
1014
+ if (a.g.j.T) {
1015
+ throw new Q(`Cannot convert argument of type ${a.g.j.name} to parameter type ${this.name}`);
1016
+ }
1017
+ return Mb(a.g.i, a.g.j.h, this.h);
1026
1018
  }
1027
- function Vb(b, a, c, d) {
1019
+ function Rb(b, a, c, d, e, f, m, h, l, n, r) {
1028
1020
  this.name = b;
1029
1021
  this.h = a;
1030
- this.ea = c;
1031
- this.U = d;
1032
- this.V = !1;
1033
- this.H = this.jb = this.fa = this.za = this.nb = this.ib = void 0;
1034
- void 0 !== a.l ? this.toWireType = Tb : (this.toWireType = d ? Rb : Ub, this.v = null);
1035
- }
1036
- function Wb(b, a, c) {
1037
- h.hasOwnProperty(b) || Ab("Replacing nonexistant public symbol");
1038
- void 0 !== h[b].m && void 0 !== c ? h[b].m[c] = a : (h[b] = a, h[b].L = c);
1039
- }
1040
- var Xb = [], Yb = b => {
1041
- var a = Xb[b];
1042
- a || (b >= Xb.length && (Xb.length = b + 1), Xb[b] = a = Ia.get(b));
1022
+ this.da = c;
1023
+ this.T = d;
1024
+ this.U = e;
1025
+ this.$a = f;
1026
+ this.fb = m;
1027
+ this.wa = h;
1028
+ this.ea = l;
1029
+ this.ab = n;
1030
+ this.C = r;
1031
+ e || void 0 !== a.o ? this.toWireType = Pb : (this.toWireType = d ? Nb : Qb, this.A = null);
1032
+ }
1033
+ var Sb = (b, a, c) => {
1034
+ if (!k.hasOwnProperty(b)) {
1035
+ throw new wb("Replacing nonexistent public symbol");
1036
+ }
1037
+ void 0 !== k[b].l && void 0 !== c ? k[b].l[c] = a : (k[b] = a, k[b].K = c);
1038
+ }, Tb = [], Ub, Vb = b => {
1039
+ var a = Tb[b];
1040
+ a || (b >= Tb.length && (Tb.length = b + 1), Tb[b] = a = Ub.get(b));
1043
1041
  return a;
1044
- }, Zb = (b, a) => {
1045
- var c = [];
1046
- return function() {
1047
- c.length = 0;
1048
- Object.assign(c, arguments);
1049
- if (b.includes("j")) {
1050
- var d = h["dynCall_" + b];
1051
- d = c && c.length ? d.apply(null, [a].concat(c)) : d.call(null, a);
1052
- } else {
1053
- d = Yb(a).apply(null, c);
1054
- }
1055
- return d;
1056
- };
1057
- };
1058
- function X(b, a) {
1059
- b = U(b);
1060
- var c = b.includes("j") ? Zb(b, a) : Yb(a);
1061
- "function" != typeof c && Q(`unknown function pointer with signature ${b}: ${a}`);
1042
+ }, Wb = (b, a, c = []) => {
1043
+ b.includes("j") ? (b = b.replace(/p/g, "i"), a = (0,k["dynCall_" + b])(a, ...c)) : a = Vb(a)(...c);
1044
+ return a;
1045
+ }, Xb = (b, a) => (...c) => Wb(b, a, c), Y = (b, a) => {
1046
+ b = T(b);
1047
+ var c = b.includes("j") ? Xb(b, a) : Vb(a);
1048
+ if ("function" != typeof c) {
1049
+ throw new Q(`unknown function pointer with signature ${b}: ${a}`);
1050
+ }
1062
1051
  return c;
1063
- }
1064
- var $b = void 0;
1065
- function ac(b, a) {
1052
+ }, Yb, Zb = (b, a) => {
1066
1053
  function c(f) {
1067
- e[f] || jb[f] || (Hb[f] ? Hb[f].forEach(c) : (d.push(f), e[f] = !0));
1054
+ e[f] || hb[f] || (Db[f] ? Db[f].forEach(c) : (d.push(f), e[f] = !0));
1068
1055
  }
1069
1056
  var d = [], e = {};
1070
1057
  a.forEach(c);
1071
- throw new $b(`${b}: ` + d.map(kb).join([", "]));
1058
+ throw new Yb(`${b}: ` + d.map(kb).join([", "]));
1059
+ };
1060
+ function $b(b) {
1061
+ for (var a = 1; a < b.length; ++a) {
1062
+ if (null !== b[a] && void 0 === b[a].A) {
1063
+ return !0;
1064
+ }
1065
+ }
1066
+ return !1;
1072
1067
  }
1073
- function bc(b, a, c, d, e) {
1068
+ function ac(b, a, c, d, e) {
1074
1069
  var f = a.length;
1075
- 2 > f && Q("argTypes array size mismatch! Must at least get return value and 'this' types!");
1076
- var m = null !== a[1] && null !== c, k = !1;
1077
- for (c = 1; c < a.length; ++c) {
1078
- if (null !== a[c] && void 0 === a[c].v) {
1079
- k = !0;
1080
- break;
1081
- }
1070
+ if (2 > f) {
1071
+ throw new Q("argTypes array size mismatch! Must at least get return value and 'this' types!");
1082
1072
  }
1083
- var n = "void" !== a[0].name, l = f - 2, t = Array(l), w = [], x = [];
1084
- return function() {
1085
- arguments.length !== l && Q(`function ${b} called with ${arguments.length} arguments, expected ${l} args!`);
1086
- x.length = 0;
1073
+ var m = null !== a[1] && null !== c, h = $b(a), l = "void" !== a[0].name, n = f - 2, r = Array(n), w = [], y = [];
1074
+ return Xa(b, function(...g) {
1075
+ if (g.length !== n) {
1076
+ throw new Q(`function ${b} called with ${g.length} arguments, expected ${n}`);
1077
+ }
1078
+ y.length = 0;
1087
1079
  w.length = m ? 2 : 1;
1088
1080
  w[0] = e;
1089
1081
  if (m) {
1090
- var g = a[1].toWireType(x, this);
1091
- w[1] = g;
1082
+ var t = a[1].toWireType(y, this);
1083
+ w[1] = t;
1092
1084
  }
1093
- for (var r = 0; r < l; ++r) {
1094
- t[r] = a[r + 2].toWireType(x, arguments[r]), w.push(t[r]);
1085
+ for (var q = 0; q < n; ++q) {
1086
+ r[q] = a[q + 2].toWireType(y, g[q]), w.push(r[q]);
1095
1087
  }
1096
- r = d.apply(null, w);
1097
- if (k) {
1098
- Eb(x);
1088
+ g = d(...w);
1089
+ if (h) {
1090
+ Ab(y);
1099
1091
  } else {
1100
- for (var q = m ? 1 : 2; q < a.length; q++) {
1101
- var F = 1 === q ? g : t[q - 2];
1102
- null !== a[q].v && a[q].v(F);
1092
+ for (q = m ? 1 : 2; q < a.length; q++) {
1093
+ var F = 1 === q ? t : r[q - 2];
1094
+ null !== a[q].A && a[q].A(F);
1103
1095
  }
1104
1096
  }
1105
- g = n ? a[0].fromWireType(r) : void 0;
1106
- return g;
1107
- };
1097
+ t = l ? a[0].fromWireType(g) : void 0;
1098
+ return t;
1099
+ });
1108
1100
  }
1109
- function cc(b, a) {
1101
+ var bc = (b, a) => {
1110
1102
  for (var c = [], d = 0; d < b; d++) {
1111
- c.push(L[a + 4 * d >> 2]);
1103
+ c.push(O[a + 4 * d >> 2]);
1112
1104
  }
1113
1105
  return c;
1114
- }
1115
- function dc(b, a, c) {
1116
- b instanceof Object || Q(`${c} with invalid "this": ${b}`);
1117
- b instanceof a.h.constructor || Q(`${c} incompatible with "this" of type ${b.constructor.name}`);
1118
- b.g.i || Q(`cannot call emscripten binding method ${c} on deleted object`);
1119
- return Qb(b.g.i, b.g.j.h, a.h);
1120
- }
1121
- function ec(b) {
1122
- b >= P.ua && 0 === --P.get(b).Aa && P.$a(b);
1123
- }
1124
- function fc(b, a, c) {
1106
+ }, cc = b => {
1107
+ b = b.trim();
1108
+ const a = b.indexOf("(");
1109
+ return -1 !== a ? b.substr(0, a) : b;
1110
+ }, dc = (b, a, c) => {
1111
+ if (!(b instanceof Object)) {
1112
+ throw new Q(`${c} with invalid "this": ${b}`);
1113
+ }
1114
+ if (!(b instanceof a.h.constructor)) {
1115
+ throw new Q(`${c} incompatible with "this" of type ${b.constructor.name}`);
1116
+ }
1117
+ if (!b.g.i) {
1118
+ throw new Q(`cannot call emscripten binding method ${c} on deleted object`);
1119
+ }
1120
+ return Mb(b.g.i, b.g.j.h, a.h);
1121
+ }, ec = b => {
1122
+ 9 < b && 0 === --P[b + 1] && (P[b] = void 0, Ya.push(b));
1123
+ }, fc = {name:"emscripten::val", fromWireType:b => {
1124
+ var a = S(b);
1125
+ ec(b);
1126
+ return a;
1127
+ }, toWireType:(b, a) => Za(a), argPackAdvance:8, readValueFromPointer:Bb, A:null,}, gc = (b, a, c) => {
1125
1128
  switch(a) {
1126
- case 0:
1127
- return function(d) {
1128
- return this.fromWireType((c ? Ca : J)[d]);
1129
- };
1130
1129
  case 1:
1131
- return function(d) {
1132
- return this.fromWireType((c ? Da : Ea)[d >> 1]);
1130
+ return c ? function(d) {
1131
+ return this.fromWireType(Ca[d]);
1132
+ } : function(d) {
1133
+ return this.fromWireType(J[d]);
1133
1134
  };
1134
1135
  case 2:
1135
- return function(d) {
1136
- return this.fromWireType((c ? K : L)[d >> 2]);
1136
+ return c ? function(d) {
1137
+ return this.fromWireType(Da[d >> 1]);
1138
+ } : function(d) {
1139
+ return this.fromWireType(Ea[d >> 1]);
1140
+ };
1141
+ case 4:
1142
+ return c ? function(d) {
1143
+ return this.fromWireType(K[d >> 2]);
1144
+ } : function(d) {
1145
+ return this.fromWireType(O[d >> 2]);
1137
1146
  };
1138
1147
  default:
1139
- throw new TypeError("Unknown integer type: " + b);
1148
+ throw new TypeError(`invalid integer width (${a}): ${b}`);
1140
1149
  }
1141
- }
1142
- function Sb(b) {
1150
+ }, Ob = b => {
1143
1151
  if (null === b) {
1144
1152
  return "null";
1145
1153
  }
1146
1154
  var a = typeof b;
1147
1155
  return "object" === a || "array" === a || "function" === a ? b.toString() : "" + b;
1148
- }
1149
- function gc(b, a) {
1156
+ }, hc = (b, a) => {
1150
1157
  switch(a) {
1151
- case 2:
1158
+ case 4:
1152
1159
  return function(c) {
1153
1160
  return this.fromWireType(Fa[c >> 2]);
1154
1161
  };
1155
- case 3:
1162
+ case 8:
1156
1163
  return function(c) {
1157
1164
  return this.fromWireType(Ga[c >> 3]);
1158
1165
  };
1159
1166
  default:
1160
- throw new TypeError("Unknown float type: " + b);
1167
+ throw new TypeError(`invalid float width (${a}): ${b}`);
1161
1168
  }
1162
- }
1163
- function hc(b, a, c) {
1169
+ }, ic = (b, a, c) => {
1164
1170
  switch(a) {
1165
- case 0:
1166
- return c ? function(d) {
1167
- return Ca[d];
1168
- } : function(d) {
1169
- return J[d];
1170
- };
1171
1171
  case 1:
1172
- return c ? function(d) {
1173
- return Da[d >> 1];
1174
- } : function(d) {
1175
- return Ea[d >> 1];
1176
- };
1172
+ return c ? d => Ca[d] : d => J[d];
1177
1173
  case 2:
1178
- return c ? function(d) {
1179
- return K[d >> 2];
1180
- } : function(d) {
1181
- return L[d >> 2];
1182
- };
1174
+ return c ? d => Da[d >> 1] : d => Ea[d >> 1];
1175
+ case 4:
1176
+ return c ? d => K[d >> 2] : d => O[d >> 2];
1183
1177
  default:
1184
- throw new TypeError("Unknown integer type: " + b);
1178
+ throw new TypeError(`invalid integer width (${a}): ${b}`);
1185
1179
  }
1186
- }
1187
- var ic = (b, a, c, d) => {
1180
+ }, jc = (b, a, c, d) => {
1188
1181
  if (0 < d) {
1189
1182
  d = c + d - 1;
1190
1183
  for (var e = 0; e < b.length; ++e) {
@@ -1224,19 +1217,19 @@ var ic = (b, a, c, d) => {
1224
1217
  }
1225
1218
  a[c] = 0;
1226
1219
  }
1227
- }, jc = b => {
1220
+ }, kc = b => {
1228
1221
  for (var a = 0, c = 0; c < b.length; ++c) {
1229
1222
  var d = b.charCodeAt(c);
1230
1223
  127 >= d ? a++ : 2047 >= d ? a += 2 : 55296 <= d && 57343 >= d ? (a += 4, ++c) : a += 3;
1231
1224
  }
1232
1225
  return a;
1233
- }, kc = "undefined" != typeof TextDecoder ? new TextDecoder("utf8") : void 0, lc = (b, a, c) => {
1226
+ }, nc = "undefined" != typeof TextDecoder ? new TextDecoder("utf8") : void 0, oc = (b, a, c) => {
1234
1227
  var d = a + c;
1235
1228
  for (c = a; b[c] && !(c >= d);) {
1236
1229
  ++c;
1237
1230
  }
1238
- if (16 < c - a && b.buffer && kc) {
1239
- return kc.decode(b.subarray(a, c));
1231
+ if (16 < c - a && b.buffer && nc) {
1232
+ return nc.decode(b.subarray(a, c));
1240
1233
  }
1241
1234
  for (d = ""; a < c;) {
1242
1235
  var e = b[a++];
@@ -1254,14 +1247,14 @@ var ic = (b, a, c, d) => {
1254
1247
  }
1255
1248
  }
1256
1249
  return d;
1257
- }, mc = "undefined" != typeof TextDecoder ? new TextDecoder("utf-16le") : void 0, nc = (b, a) => {
1250
+ }, pc = "undefined" != typeof TextDecoder ? new TextDecoder("utf-16le") : void 0, qc = (b, a) => {
1258
1251
  var c = b >> 1;
1259
1252
  for (var d = c + a / 2; !(c >= d) && Ea[c];) {
1260
1253
  ++c;
1261
1254
  }
1262
1255
  c <<= 1;
1263
- if (32 < c - b && mc) {
1264
- return mc.decode(J.subarray(b, c));
1256
+ if (32 < c - b && pc) {
1257
+ return pc.decode(J.subarray(b, c));
1265
1258
  }
1266
1259
  c = "";
1267
1260
  for (d = 0; !(d >= a / 2); ++d) {
@@ -1272,8 +1265,8 @@ var ic = (b, a, c, d) => {
1272
1265
  c += String.fromCharCode(e);
1273
1266
  }
1274
1267
  return c;
1275
- }, qc = (b, a, c) => {
1276
- void 0 === c && (c = 2147483647);
1268
+ }, rc = (b, a, c) => {
1269
+ c ??= 2147483647;
1277
1270
  if (2 > c) {
1278
1271
  return 0;
1279
1272
  }
@@ -1285,7 +1278,7 @@ var ic = (b, a, c, d) => {
1285
1278
  }
1286
1279
  Da[a >> 1] = 0;
1287
1280
  return a - d;
1288
- }, rc = b => 2 * b.length, sc = (b, a) => {
1281
+ }, sc = b => 2 * b.length, tc = (b, a) => {
1289
1282
  for (var c = 0, d = ""; !(c >= a / 4);) {
1290
1283
  var e = K[b + 4 * c >> 2];
1291
1284
  if (0 == e) {
@@ -1295,8 +1288,8 @@ var ic = (b, a, c, d) => {
1295
1288
  65536 <= e ? (e -= 65536, d += String.fromCharCode(55296 | e >> 10, 56320 | e & 1023)) : d += String.fromCharCode(e);
1296
1289
  }
1297
1290
  return d;
1298
- }, tc = (b, a, c) => {
1299
- void 0 === c && (c = 2147483647);
1291
+ }, uc = (b, a, c) => {
1292
+ c ??= 2147483647;
1300
1293
  if (4 > c) {
1301
1294
  return 0;
1302
1295
  }
@@ -1316,68 +1309,68 @@ var ic = (b, a, c, d) => {
1316
1309
  }
1317
1310
  K[a >> 2] = 0;
1318
1311
  return a - d;
1319
- }, uc = b => {
1312
+ }, vc = b => {
1320
1313
  for (var a = 0, c = 0; c < b.length; ++c) {
1321
1314
  var d = b.charCodeAt(c);
1322
1315
  55296 <= d && 57343 >= d && ++c;
1323
1316
  a += 4;
1324
1317
  }
1325
1318
  return a;
1326
- }, vc = {};
1327
- function wc(b) {
1328
- var a = vc[b];
1329
- return void 0 === a ? U(b) : a;
1330
- }
1331
- var xc = [];
1332
- function yc(b) {
1333
- var a = xc.length;
1334
- xc.push(b);
1319
+ }, wc = (b, a, c) => {
1320
+ var d = [];
1321
+ b = b.toWireType(d, c);
1322
+ d.length && (O[a >> 2] = Za(d));
1323
+ return b;
1324
+ }, xc = {}, yc = b => {
1325
+ var a = xc[b];
1326
+ return void 0 === a ? T(b) : a;
1327
+ }, zc = [], Ac = b => {
1328
+ var a = zc.length;
1329
+ zc.push(b);
1335
1330
  return a;
1336
- }
1337
- function zc(b, a) {
1331
+ }, Bc = (b, a) => {
1338
1332
  for (var c = Array(b), d = 0; d < b; ++d) {
1339
- c[d] = nb(L[a + 4 * d >> 2], "parameter " + d);
1333
+ c[d] = lb(O[a + 4 * d >> 2], "parameter " + d);
1340
1334
  }
1341
1335
  return c;
1342
- }
1343
- var Ac = [], Bc = {}, Dc = () => {
1344
- if (!Cc) {
1345
- var b = {USER:"web_user", LOGNAME:"web_user", PATH:"/", PWD:"/", HOME:"/home/web_user", LANG:("object" == typeof navigator && navigator.languages && navigator.languages[0] || "C").replace("-", "_") + ".UTF-8", _:na || "./this.program"}, a;
1346
- for (a in Bc) {
1347
- void 0 === Bc[a] ? delete b[a] : b[a] = Bc[a];
1336
+ }, Cc = Reflect.construct, Dc = {}, Fc = () => {
1337
+ if (!Ec) {
1338
+ var b = {USER:"web_user", LOGNAME:"web_user", PATH:"/", PWD:"/", HOME:"/home/web_user", LANG:("object" == typeof navigator && navigator.languages && navigator.languages[0] || "C").replace("-", "_") + ".UTF-8", _:ra || "./this.program"}, a;
1339
+ for (a in Dc) {
1340
+ void 0 === Dc[a] ? delete b[a] : b[a] = Dc[a];
1348
1341
  }
1349
1342
  var c = [];
1350
1343
  for (a in b) {
1351
1344
  c.push(`${a}=${b[a]}`);
1352
1345
  }
1353
- Cc = c;
1346
+ Ec = c;
1354
1347
  }
1355
- return Cc;
1356
- }, Cc, Ec = [null, [], []], Fc = b => 0 === b % 4 && (0 !== b % 100 || 0 === b % 400), Gc = [31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31], Hc = [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
1357
- function Ic(b) {
1358
- var a = Array(jc(b) + 1);
1359
- ic(b, a, 0, a.length);
1348
+ return Ec;
1349
+ }, Ec, Gc = [null, [], []], Hc = b => 0 === b % 4 && (0 !== b % 100 || 0 === b % 400), Ic = [31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31], Jc = [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
1350
+ function Kc(b) {
1351
+ var a = Array(kc(b) + 1);
1352
+ jc(b, a, 0, a.length);
1360
1353
  return a;
1361
1354
  }
1362
- var Jc = (b, a, c, d) => {
1363
- function e(g, r, q) {
1364
- for (g = "number" == typeof g ? g.toString() : g || ""; g.length < r;) {
1355
+ var Lc = (b, a, c, d) => {
1356
+ function e(g, t, q) {
1357
+ for (g = "number" == typeof g ? g.toString() : g || ""; g.length < t;) {
1365
1358
  g = q[0] + g;
1366
1359
  }
1367
1360
  return g;
1368
1361
  }
1369
- function f(g, r) {
1370
- return e(g, r, "0");
1362
+ function f(g, t) {
1363
+ return e(g, t, "0");
1371
1364
  }
1372
- function m(g, r) {
1365
+ function m(g, t) {
1373
1366
  function q(E) {
1374
1367
  return 0 > E ? -1 : 0 < E ? 1 : 0;
1375
1368
  }
1376
1369
  var F;
1377
- 0 === (F = q(g.getFullYear() - r.getFullYear())) && 0 === (F = q(g.getMonth() - r.getMonth())) && (F = q(g.getDate() - r.getDate()));
1370
+ 0 === (F = q(g.getFullYear() - t.getFullYear())) && 0 === (F = q(g.getMonth() - t.getMonth())) && (F = q(g.getDate() - t.getDate()));
1378
1371
  return F;
1379
1372
  }
1380
- function k(g) {
1373
+ function h(g) {
1381
1374
  switch(g.getDay()) {
1382
1375
  case 0:
1383
1376
  return new Date(g.getFullYear() - 1, 11, 29);
@@ -1395,705 +1388,641 @@ var Jc = (b, a, c, d) => {
1395
1388
  return new Date(g.getFullYear() - 1, 11, 30);
1396
1389
  }
1397
1390
  }
1398
- function n(g) {
1399
- var r = g.J;
1400
- for (g = new Date((new Date(g.K + 1900, 0, 1)).getTime()); 0 < r;) {
1401
- var q = g.getMonth(), F = (Fc(g.getFullYear()) ? Gc : Hc)[q];
1402
- if (r > F - g.getDate()) {
1403
- r -= F - g.getDate() + 1, g.setDate(1), 11 > q ? g.setMonth(q + 1) : (g.setMonth(0), g.setFullYear(g.getFullYear() + 1));
1391
+ function l(g) {
1392
+ var t = g.I;
1393
+ for (g = new Date((new Date(g.J + 1900, 0, 1)).getTime()); 0 < t;) {
1394
+ var q = g.getMonth(), F = (Hc(g.getFullYear()) ? Ic : Jc)[q];
1395
+ if (t > F - g.getDate()) {
1396
+ t -= F - g.getDate() + 1, g.setDate(1), 11 > q ? g.setMonth(q + 1) : (g.setMonth(0), g.setFullYear(g.getFullYear() + 1));
1404
1397
  } else {
1405
- g.setDate(g.getDate() + r);
1398
+ g.setDate(g.getDate() + t);
1406
1399
  break;
1407
1400
  }
1408
1401
  }
1409
1402
  q = new Date(g.getFullYear() + 1, 0, 4);
1410
- r = k(new Date(g.getFullYear(), 0, 4));
1411
- q = k(q);
1412
- return 0 >= m(r, g) ? 0 >= m(q, g) ? g.getFullYear() + 1 : g.getFullYear() : g.getFullYear() - 1;
1413
- }
1414
- var l = K[d + 40 >> 2];
1415
- d = {qb:K[d >> 2], pb:K[d + 4 >> 2], Z:K[d + 8 >> 2], ha:K[d + 12 >> 2], $:K[d + 16 >> 2], K:K[d + 20 >> 2], C:K[d + 24 >> 2], J:K[d + 28 >> 2], ub:K[d + 32 >> 2], ob:K[d + 36 >> 2], rb:l ? l ? lc(J, l) : "" : ""};
1416
- c = c ? lc(J, c) : "";
1417
- l = {"%c":"%a %b %d %H:%M:%S %Y", "%D":"%m/%d/%y", "%F":"%Y-%m-%d", "%h":"%b", "%r":"%I:%M:%S %p", "%R":"%H:%M", "%T":"%H:%M:%S", "%x":"%m/%d/%y", "%X":"%H:%M:%S", "%Ec":"%c", "%EC":"%C", "%Ex":"%m/%d/%y", "%EX":"%H:%M:%S", "%Ey":"%y", "%EY":"%Y", "%Od":"%d", "%Oe":"%e", "%OH":"%H", "%OI":"%I", "%Om":"%m", "%OM":"%M", "%OS":"%S", "%Ou":"%u", "%OU":"%U", "%OV":"%V", "%Ow":"%w", "%OW":"%W", "%Oy":"%y",};
1418
- for (var t in l) {
1419
- c = c.replace(new RegExp(t, "g"), l[t]);
1420
- }
1421
- var w = "Sunday Monday Tuesday Wednesday Thursday Friday Saturday".split(" "), x = "January February March April May June July August September October November December".split(" ");
1422
- l = {"%a":g => w[g.C].substring(0, 3), "%A":g => w[g.C], "%b":g => x[g.$].substring(0, 3), "%B":g => x[g.$], "%C":g => f((g.K + 1900) / 100 | 0, 2), "%d":g => f(g.ha, 2), "%e":g => e(g.ha, 2, " "), "%g":g => n(g).toString().substring(2), "%G":g => n(g), "%H":g => f(g.Z, 2), "%I":g => {
1423
- g = g.Z;
1403
+ t = h(new Date(g.getFullYear(), 0, 4));
1404
+ q = h(q);
1405
+ return 0 >= m(t, g) ? 0 >= m(q, g) ? g.getFullYear() + 1 : g.getFullYear() : g.getFullYear() - 1;
1406
+ }
1407
+ var n = O[d + 40 >> 2];
1408
+ d = {ib:K[d >> 2], hb:K[d + 4 >> 2], Y:K[d + 8 >> 2], ga:K[d + 12 >> 2], Z:K[d + 16 >> 2], J:K[d + 20 >> 2], D:K[d + 24 >> 2], I:K[d + 28 >> 2], nb:K[d + 32 >> 2], gb:K[d + 36 >> 2], jb:n ? n ? oc(J, n) : "" : ""};
1409
+ c = c ? oc(J, c) : "";
1410
+ n = {"%c":"%a %b %d %H:%M:%S %Y", "%D":"%m/%d/%y", "%F":"%Y-%m-%d", "%h":"%b", "%r":"%I:%M:%S %p", "%R":"%H:%M", "%T":"%H:%M:%S", "%x":"%m/%d/%y", "%X":"%H:%M:%S", "%Ec":"%c", "%EC":"%C", "%Ex":"%m/%d/%y", "%EX":"%H:%M:%S", "%Ey":"%y", "%EY":"%Y", "%Od":"%d", "%Oe":"%e", "%OH":"%H", "%OI":"%I", "%Om":"%m", "%OM":"%M", "%OS":"%S", "%Ou":"%u", "%OU":"%U", "%OV":"%V", "%Ow":"%w", "%OW":"%W", "%Oy":"%y",};
1411
+ for (var r in n) {
1412
+ c = c.replace(new RegExp(r, "g"), n[r]);
1413
+ }
1414
+ var w = "Sunday Monday Tuesday Wednesday Thursday Friday Saturday".split(" "), y = "January February March April May June July August September October November December".split(" ");
1415
+ n = {"%a":g => w[g.D].substring(0, 3), "%A":g => w[g.D], "%b":g => y[g.Z].substring(0, 3), "%B":g => y[g.Z], "%C":g => f((g.J + 1900) / 100 | 0, 2), "%d":g => f(g.ga, 2), "%e":g => e(g.ga, 2, " "), "%g":g => l(g).toString().substring(2), "%G":l, "%H":g => f(g.Y, 2), "%I":g => {
1416
+ g = g.Y;
1424
1417
  0 == g ? g = 12 : 12 < g && (g -= 12);
1425
1418
  return f(g, 2);
1426
1419
  }, "%j":g => {
1427
- for (var r = 0, q = 0; q <= g.$ - 1; r += (Fc(g.K + 1900) ? Gc : Hc)[q++]) {
1428
- }
1429
- return f(g.ha + r, 3);
1430
- }, "%m":g => f(g.$ + 1, 2), "%M":g => f(g.pb, 2), "%n":() => "\n", "%p":g => 0 <= g.Z && 12 > g.Z ? "AM" : "PM", "%S":g => f(g.qb, 2), "%t":() => "\t", "%u":g => g.C || 7, "%U":g => f(Math.floor((g.J + 7 - g.C) / 7), 2), "%V":g => {
1431
- var r = Math.floor((g.J + 7 - (g.C + 6) % 7) / 7);
1432
- 2 >= (g.C + 371 - g.J - 2) % 7 && r++;
1433
- if (r) {
1434
- 53 == r && (q = (g.C + 371 - g.J) % 7, 4 == q || 3 == q && Fc(g.K) || (r = 1));
1420
+ for (var t = 0, q = 0; q <= g.Z - 1; t += (Hc(g.J + 1900) ? Ic : Jc)[q++]) {
1421
+ }
1422
+ return f(g.ga + t, 3);
1423
+ }, "%m":g => f(g.Z + 1, 2), "%M":g => f(g.hb, 2), "%n":() => "\n", "%p":g => 0 <= g.Y && 12 > g.Y ? "AM" : "PM", "%S":g => f(g.ib, 2), "%t":() => "\t", "%u":g => g.D || 7, "%U":g => f(Math.floor((g.I + 7 - g.D) / 7), 2), "%V":g => {
1424
+ var t = Math.floor((g.I + 7 - (g.D + 6) % 7) / 7);
1425
+ 2 >= (g.D + 371 - g.I - 2) % 7 && t++;
1426
+ if (t) {
1427
+ 53 == t && (q = (g.D + 371 - g.I) % 7, 4 == q || 3 == q && Hc(g.J) || (t = 1));
1435
1428
  } else {
1436
- r = 52;
1437
- var q = (g.C + 7 - g.J - 1) % 7;
1438
- (4 == q || 5 == q && Fc(g.K % 400 - 1)) && r++;
1439
- }
1440
- return f(r, 2);
1441
- }, "%w":g => g.C, "%W":g => f(Math.floor((g.J + 7 - (g.C + 6) % 7) / 7), 2), "%y":g => (g.K + 1900).toString().substring(2), "%Y":g => g.K + 1900, "%z":g => {
1442
- g = g.ob;
1443
- var r = 0 <= g;
1429
+ t = 52;
1430
+ var q = (g.D + 7 - g.I - 1) % 7;
1431
+ (4 == q || 5 == q && Hc(g.J % 400 - 1)) && t++;
1432
+ }
1433
+ return f(t, 2);
1434
+ }, "%w":g => g.D, "%W":g => f(Math.floor((g.I + 7 - (g.D + 6) % 7) / 7), 2), "%y":g => (g.J + 1900).toString().substring(2), "%Y":g => g.J + 1900, "%z":g => {
1435
+ g = g.gb;
1436
+ var t = 0 <= g;
1444
1437
  g = Math.abs(g) / 60;
1445
- return (r ? "+" : "-") + String("0000" + (g / 60 * 100 + g % 60)).slice(-4);
1446
- }, "%Z":g => g.rb, "%%":() => "%"};
1438
+ return (t ? "+" : "-") + String("0000" + (g / 60 * 100 + g % 60)).slice(-4);
1439
+ }, "%Z":g => g.jb, "%%":() => "%"};
1447
1440
  c = c.replace(/%%/g, "\x00\x00");
1448
- for (t in l) {
1449
- c.includes(t) && (c = c.replace(new RegExp(t, "g"), l[t](d)));
1441
+ for (r in n) {
1442
+ c.includes(r) && (c = c.replace(new RegExp(r, "g"), n[r](d)));
1450
1443
  }
1451
1444
  c = c.replace(/\0\0/g, "%");
1452
- t = Ic(c);
1453
- if (t.length > a) {
1445
+ r = Kc(c);
1446
+ if (r.length > a) {
1454
1447
  return 0;
1455
1448
  }
1456
- Ca.set(t, b);
1457
- return t.length - 1;
1449
+ Ca.set(r, b);
1450
+ return r.length - 1;
1458
1451
  };
1459
- Object.assign($a.prototype, {get(b) {
1460
- return this.G[b];
1461
- }, has(b) {
1462
- return void 0 !== this.G[b];
1463
- }, Za(b) {
1464
- var a = this.ta.pop() || this.G.length;
1465
- this.G[a] = b;
1466
- return a;
1467
- }, $a(b) {
1468
- this.G[b] = void 0;
1469
- this.ta.push(b);
1470
- }});
1471
- ab = h.BindingError = class extends Error {
1452
+ Q = k.BindingError = class extends Error {
1472
1453
  constructor(b) {
1473
1454
  super(b);
1474
1455
  this.name = "BindingError";
1475
1456
  }
1476
1457
  };
1477
- P.G.push({value:void 0}, {value:null}, {value:!0}, {value:!1},);
1478
- P.ua = P.G.length;
1479
- h.count_emval_handles = function() {
1480
- for (var b = 0, a = P.ua; a < P.G.length; ++a) {
1481
- void 0 !== P.G[a] && ++b;
1482
- }
1483
- return b;
1484
- };
1485
- cb = h.PureVirtualError = bb("PureVirtualError");
1486
- for (var Kc = Array(256), Lc = 0; 256 > Lc; ++Lc) {
1487
- Kc[Lc] = String.fromCharCode(Lc);
1488
- }
1489
- db = Kc;
1490
- h.getInheritedInstanceCount = function() {
1491
- return Object.keys(hb).length;
1492
- };
1493
- h.getLiveInheritedInstances = function() {
1458
+ P.push(0, 1, void 0, 1, null, 1, !0, 1, !1, 1,);
1459
+ k.count_emval_handles = () => P.length / 2 - 5 - Ya.length;
1460
+ ab = k.PureVirtualError = $a("PureVirtualError");
1461
+ for (var Mc = Array(256), Nc = 0; 256 > Nc; ++Nc) {
1462
+ Mc[Nc] = String.fromCharCode(Nc);
1463
+ }
1464
+ bb = Mc;
1465
+ k.getInheritedInstanceCount = () => Object.keys(fb).length;
1466
+ k.getLiveInheritedInstances = () => {
1494
1467
  var b = [], a;
1495
- for (a in hb) {
1496
- hb.hasOwnProperty(a) && b.push(hb[a]);
1468
+ for (a in fb) {
1469
+ fb.hasOwnProperty(a) && b.push(fb[a]);
1497
1470
  }
1498
1471
  return b;
1499
1472
  };
1500
- h.flushPendingDeletes = fb;
1501
- h.setDelayFunction = function(b) {
1502
- gb = b;
1503
- eb.length && gb && gb(fb);
1473
+ k.flushPendingDeletes = db;
1474
+ k.setDelayFunction = b => {
1475
+ eb = b;
1476
+ cb.length && eb && eb(db);
1504
1477
  };
1505
- zb = h.InternalError = class extends Error {
1478
+ wb = k.InternalError = class extends Error {
1506
1479
  constructor(b) {
1507
1480
  super(b);
1508
1481
  this.name = "InternalError";
1509
1482
  }
1510
1483
  };
1511
- Mb.prototype.isAliasOf = function(b) {
1512
- if (!(this instanceof Mb && b instanceof Mb)) {
1484
+ Object.assign(Hb.prototype, {isAliasOf:function(b) {
1485
+ if (!(this instanceof Hb && b instanceof Hb)) {
1513
1486
  return !1;
1514
1487
  }
1515
- var a = this.g.j.h, c = this.g.i, d = b.g.j.h;
1516
- for (b = b.g.i; a.l;) {
1517
- c = a.S(c), a = a.l;
1488
+ var a = this.g.j.h, c = this.g.i;
1489
+ b.g = b.g;
1490
+ var d = b.g.j.h;
1491
+ for (b = b.g.i; a.o;) {
1492
+ c = a.R(c), a = a.o;
1518
1493
  }
1519
- for (; d.l;) {
1520
- b = d.S(b), d = d.l;
1494
+ for (; d.o;) {
1495
+ b = d.R(b), d = d.o;
1521
1496
  }
1522
1497
  return a === d && c === b;
1523
- };
1524
- Mb.prototype.clone = function() {
1525
- this.g.i || Lb(this);
1526
- if (this.g.O) {
1498
+ }, clone:function() {
1499
+ this.g.i || Gb(this);
1500
+ if (this.g.N) {
1527
1501
  return this.g.count.value += 1, this;
1528
1502
  }
1529
- var b = Cb, a = Object, c = a.create, d = Object.getPrototypeOf(this), e = this.g;
1530
- b = b(c.call(a, d, {g:{value:{count:e.count, M:e.M, O:e.O, i:e.i, j:e.j, s:e.s, A:e.A,},}}));
1503
+ var b = xb, a = Object, c = a.create, d = Object.getPrototypeOf(this), e = this.g;
1504
+ b = b(c.call(a, d, {g:{value:{count:e.count, L:e.L, N:e.N, i:e.i, j:e.j, s:e.s, v:e.v,},}}));
1531
1505
  b.g.count.value += 1;
1532
- b.g.M = !1;
1506
+ b.g.L = !1;
1533
1507
  return b;
1534
- };
1535
- Mb.prototype["delete"] = function() {
1536
- this.g.i || Lb(this);
1537
- this.g.M && !this.g.O && Q("Object already scheduled for deletion");
1538
- ob(this);
1539
- qb(this.g);
1540
- this.g.O || (this.g.s = void 0, this.g.i = void 0);
1541
- };
1542
- Mb.prototype.isDeleted = function() {
1508
+ }, ["delete"]() {
1509
+ this.g.i || Gb(this);
1510
+ if (this.g.L && !this.g.N) {
1511
+ throw new Q("Object already scheduled for deletion");
1512
+ }
1513
+ mb(this);
1514
+ var b = this.g;
1515
+ --b.count.value;
1516
+ 0 === b.count.value && (b.s ? b.v.C(b.s) : b.j.h.C(b.i));
1517
+ this.g.N || (this.g.s = void 0, this.g.i = void 0);
1518
+ }, isDeleted:function() {
1543
1519
  return !this.g.i;
1544
- };
1545
- Mb.prototype.deleteLater = function() {
1546
- this.g.i || Lb(this);
1547
- this.g.M && !this.g.O && Q("Object already scheduled for deletion");
1548
- eb.push(this);
1549
- 1 === eb.length && gb && gb(fb);
1550
- this.g.M = !0;
1520
+ }, deleteLater:function() {
1521
+ this.g.i || Gb(this);
1522
+ if (this.g.L && !this.g.N) {
1523
+ throw new Q("Object already scheduled for deletion");
1524
+ }
1525
+ cb.push(this);
1526
+ 1 === cb.length && eb && eb(db);
1527
+ this.g.L = !0;
1551
1528
  return this;
1552
- };
1553
- Vb.prototype.Va = function(b) {
1554
- this.za && (b = this.za(b));
1529
+ },});
1530
+ Object.assign(Rb.prototype, {Qa(b) {
1531
+ this.wa && (b = this.wa(b));
1555
1532
  return b;
1556
- };
1557
- Vb.prototype.pa = function(b) {
1558
- this.H && this.H(b);
1559
- };
1560
- Vb.prototype.argPackAdvance = 8;
1561
- Vb.prototype.readValueFromPointer = Fb;
1562
- Vb.prototype.deleteObject = function(b) {
1563
- if (null !== b) {
1564
- b["delete"]();
1565
- }
1566
- };
1567
- Vb.prototype.fromWireType = function(b) {
1533
+ }, oa(b) {
1534
+ this.C?.(b);
1535
+ }, argPackAdvance:8, readValueFromPointer:Bb, fromWireType:function(b) {
1568
1536
  function a() {
1569
- return this.V ? Bb(this.h.B, {j:this.ib, i:c, A:this, s:b,}) : Bb(this.h.B, {j:this, i:b,});
1537
+ return this.U ? yb(this.h.B, {j:this.$a, i:c, v:this, s:b,}) : yb(this.h.B, {j:this, i:b,});
1570
1538
  }
1571
- var c = this.Va(b);
1539
+ var c = this.Qa(b);
1572
1540
  if (!c) {
1573
- return this.pa(b), null;
1541
+ return this.oa(b), null;
1574
1542
  }
1575
- var d = yb(this.h, c);
1543
+ var d = qb(this.h, c);
1576
1544
  if (void 0 !== d) {
1577
1545
  if (0 === d.g.count.value) {
1578
1546
  return d.g.i = c, d.g.s = b, d.clone();
1579
1547
  }
1580
1548
  d = d.clone();
1581
- this.pa(b);
1549
+ this.oa(b);
1582
1550
  return d;
1583
1551
  }
1584
- d = this.h.Ua(c);
1585
- d = sb[d];
1552
+ d = this.h.Pa(c);
1553
+ d = pb[d];
1586
1554
  if (!d) {
1587
1555
  return a.call(this);
1588
1556
  }
1589
- d = this.U ? d.Ka : d.pointerType;
1590
- var e = rb(c, this.h, d.h);
1591
- return null === e ? a.call(this) : this.V ? Bb(d.h.B, {j:d, i:e, A:this, s:b,}) : Bb(d.h.B, {j:d, i:e,});
1592
- };
1593
- $b = h.UnboundTypeError = bb("UnboundTypeError");
1594
- var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
1595
- b = U(b);
1596
- a = nb(a, "wrapper");
1597
- c = R(c);
1598
- var d = [].slice, e = a.h, f = e.B, m = e.l.B, k = e.l.constructor;
1599
- b = Za(b, function() {
1600
- e.l.ya.forEach(function(l) {
1601
- if (this[l] === m[l]) {
1602
- throw new cb(`Pure virtual function ${l} must be implemented in JavaScript`);
1557
+ d = this.T ? d.Ga : d.pointerType;
1558
+ var e = ob(c, this.h, d.h);
1559
+ return null === e ? a.call(this) : this.U ? yb(d.h.B, {j:d, i:e, v:this, s:b,}) : yb(d.h.B, {j:d, i:e,});
1560
+ },});
1561
+ Yb = k.UnboundTypeError = $a("UnboundTypeError");
1562
+ var Pc = {_abort_js:() => {
1563
+ Pa("");
1564
+ }, _embind_create_inheriting_constructor:(b, a, c) => {
1565
+ b = T(b);
1566
+ a = lb(a, "wrapper");
1567
+ c = S(c);
1568
+ var d = a.h, e = d.B, f = d.o.B, m = d.o.constructor;
1569
+ b = Xa(b, function(...h) {
1570
+ d.o.va.forEach(function(l) {
1571
+ if (this[l] === f[l]) {
1572
+ throw new ab(`Pure virtual function ${l} must be implemented in JavaScript`);
1603
1573
  }
1604
1574
  }.bind(this));
1605
- Object.defineProperty(this, "__parent", {value:f});
1606
- this.__construct.apply(this, d.call(arguments));
1575
+ Object.defineProperty(this, "__parent", {value:e});
1576
+ this.__construct(...h);
1607
1577
  });
1608
- f.__construct = function() {
1609
- this === f && Q("Pass correct 'this' to __construct");
1610
- var l = k.implement.apply(void 0, [this].concat(d.call(arguments)));
1611
- ob(l);
1612
- var t = l.g;
1613
- l.notifyOnDestruction();
1614
- t.O = !0;
1615
- Object.defineProperties(this, {g:{value:t}});
1616
- Cb(this);
1617
- l = t.i;
1618
- l = ib(e, l);
1619
- hb.hasOwnProperty(l) ? Q(`Tried to register registered instance: ${l}`) : hb[l] = this;
1578
+ e.__construct = function(...h) {
1579
+ if (this === e) {
1580
+ throw new Q("Pass correct 'this' to __construct");
1581
+ }
1582
+ h = m.implement(this, ...h);
1583
+ mb(h);
1584
+ var l = h.g;
1585
+ h.notifyOnDestruction();
1586
+ l.N = !0;
1587
+ Object.defineProperties(this, {g:{value:l}});
1588
+ xb(this);
1589
+ h = l.i;
1590
+ h = gb(d, h);
1591
+ if (fb.hasOwnProperty(h)) {
1592
+ throw new Q(`Tried to register registered instance: ${h}`);
1593
+ }
1594
+ fb[h] = this;
1620
1595
  };
1621
- f.__destruct = function() {
1622
- this === f && Q("Pass correct 'this' to __destruct");
1623
- ob(this);
1624
- var l = this.g.i;
1625
- l = ib(e, l);
1626
- hb.hasOwnProperty(l) ? delete hb[l] : Q(`Tried to unregister unregistered instance: ${l}`);
1596
+ e.__destruct = function() {
1597
+ if (this === e) {
1598
+ throw new Q("Pass correct 'this' to __destruct");
1599
+ }
1600
+ mb(this);
1601
+ var h = this.g.i;
1602
+ h = gb(d, h);
1603
+ if (fb.hasOwnProperty(h)) {
1604
+ delete fb[h];
1605
+ } else {
1606
+ throw new Q(`Tried to unregister unregistered instance: ${h}`);
1607
+ }
1627
1608
  };
1628
- b.prototype = Object.create(f);
1629
- for (var n in c) {
1630
- b.prototype[n] = c[n];
1631
- }
1632
- return S(b);
1633
- }, _embind_finalize_value_object:function(b) {
1634
- var a = Db[b];
1635
- delete Db[b];
1636
- var c = a.fa, d = a.H, e = a.sa, f = e.map(m => m.Ya).concat(e.map(m => m.lb));
1637
- W([b], f, m => {
1638
- var k = {};
1639
- e.forEach((n, l) => {
1640
- var t = m[l], w = n.Wa, x = n.Xa, g = m[l + e.length], r = n.kb, q = n.mb;
1641
- k[n.Sa] = {read:F => t.fromWireType(w(x, F)), write:(F, E) => {
1609
+ b.prototype = Object.create(e);
1610
+ Object.assign(b.prototype, c);
1611
+ return Za(b);
1612
+ }, _embind_finalize_value_object:b => {
1613
+ var a = zb[b];
1614
+ delete zb[b];
1615
+ var c = a.ea, d = a.C, e = a.ra, f = e.map(m => m.Ta).concat(e.map(m => m.cb));
1616
+ X([b], f, m => {
1617
+ var h = {};
1618
+ e.forEach((l, n) => {
1619
+ var r = m[n], w = l.Ra, y = l.Sa, g = m[n + e.length], t = l.bb, q = l.eb;
1620
+ h[l.Na] = {read:F => r.fromWireType(w(y, F)), write:(F, E) => {
1642
1621
  var v = [];
1643
- r(q, F, g.toWireType(v, E));
1644
- Eb(v);
1622
+ t(q, F, g.toWireType(v, E));
1623
+ Ab(v);
1645
1624
  }};
1646
1625
  });
1647
- return [{name:a.name, fromWireType:function(n) {
1648
- var l = {}, t;
1649
- for (t in k) {
1650
- l[t] = k[t].read(n);
1626
+ return [{name:a.name, fromWireType:l => {
1627
+ var n = {}, r;
1628
+ for (r in h) {
1629
+ n[r] = h[r].read(l);
1651
1630
  }
1652
- d(n);
1653
- return l;
1654
- }, toWireType:function(n, l) {
1655
- for (var t in k) {
1656
- if (!(t in l)) {
1657
- throw new TypeError(`Missing field: "${t}"`);
1631
+ d(l);
1632
+ return n;
1633
+ }, toWireType:(l, n) => {
1634
+ for (var r in h) {
1635
+ if (!(r in n)) {
1636
+ throw new TypeError(`Missing field: "${r}"`);
1658
1637
  }
1659
1638
  }
1660
1639
  var w = c();
1661
- for (t in k) {
1662
- k[t].write(w, l[t]);
1640
+ for (r in h) {
1641
+ h[r].write(w, n[r]);
1663
1642
  }
1664
- null !== n && n.push(d, w);
1643
+ null !== l && l.push(d, w);
1665
1644
  return w;
1666
- }, argPackAdvance:8, readValueFromPointer:Fb, v:d,}];
1645
+ }, argPackAdvance:8, readValueFromPointer:Bb, A:d,}];
1667
1646
  });
1668
- }, _embind_register_bigint:function() {
1669
- }, _embind_register_bool:function(b, a, c, d, e) {
1670
- var f = Jb(c);
1671
- a = U(a);
1672
- Ib(b, {name:a, fromWireType:function(m) {
1673
- return !!m;
1674
- }, toWireType:function(m, k) {
1675
- return k ? d : e;
1676
- }, argPackAdvance:8, readValueFromPointer:function(m) {
1677
- if (1 === c) {
1678
- var k = Ca;
1679
- } else if (2 === c) {
1680
- k = Da;
1681
- } else if (4 === c) {
1682
- k = K;
1683
- } else {
1684
- throw new TypeError("Unknown boolean type size: " + a);
1685
- }
1686
- return this.fromWireType(k[m >> f]);
1687
- }, v:null,});
1688
- }, _embind_register_class:function(b, a, c, d, e, f, m, k, n, l, t, w, x) {
1689
- t = U(t);
1690
- f = X(e, f);
1691
- k && (k = X(m, k));
1692
- l && (l = X(n, l));
1693
- x = X(w, x);
1694
- var g = Ya(t);
1695
- Ob(g, function() {
1696
- ac(`Cannot construct ${t} due to unbound types`, [d]);
1647
+ }, _embind_register_bigint:() => {
1648
+ }, _embind_register_bool:(b, a, c, d) => {
1649
+ a = T(a);
1650
+ Eb(b, {name:a, fromWireType:function(e) {
1651
+ return !!e;
1652
+ }, toWireType:function(e, f) {
1653
+ return f ? c : d;
1654
+ }, argPackAdvance:8, readValueFromPointer:function(e) {
1655
+ return this.fromWireType(J[e]);
1656
+ }, A:null,});
1657
+ }, _embind_register_class:(b, a, c, d, e, f, m, h, l, n, r, w, y) => {
1658
+ r = T(r);
1659
+ f = Y(e, f);
1660
+ h &&= Y(m, h);
1661
+ n &&= Y(l, n);
1662
+ y = Y(w, y);
1663
+ var g = Kb(r);
1664
+ Jb(g, function() {
1665
+ Zb(`Cannot construct ${r} due to unbound types`, [d]);
1697
1666
  });
1698
- W([b, a, c], d ? [d] : [], function(r) {
1699
- r = r[0];
1667
+ X([b, a, c], d ? [d] : [], t => {
1668
+ t = t[0];
1700
1669
  if (d) {
1701
- var q = r.h;
1670
+ var q = t.h;
1702
1671
  var F = q.B;
1703
1672
  } else {
1704
- F = Mb.prototype;
1673
+ F = Hb.prototype;
1705
1674
  }
1706
- r = Za(g, function() {
1675
+ t = Xa(r, function(...L) {
1707
1676
  if (Object.getPrototypeOf(this) !== E) {
1708
- throw new ab("Use 'new' to construct " + t);
1677
+ throw new Q("Use 'new' to construct " + r);
1709
1678
  }
1710
- if (void 0 === v.I) {
1711
- throw new ab(t + " has no accessible constructor");
1679
+ if (void 0 === v.H) {
1680
+ throw new Q(r + " has no accessible constructor");
1712
1681
  }
1713
- var O = v.I[arguments.length];
1714
- if (void 0 === O) {
1715
- throw new ab(`Tried to invoke ctor of ${t} with invalid number of parameters (${arguments.length}) - expected (${Object.keys(v.I).toString()}) parameters instead!`);
1682
+ var R = v.H[L.length];
1683
+ if (void 0 === R) {
1684
+ throw new Q(`Tried to invoke ctor of ${r} with invalid number of parameters (${L.length}) - expected (${Object.keys(v.H).toString()}) parameters instead!`);
1716
1685
  }
1717
- return O.apply(this, arguments);
1686
+ return R.apply(this, L);
1718
1687
  });
1719
- var E = Object.create(F, {constructor:{value:r},});
1720
- r.prototype = E;
1721
- var v = new Pb(t, r, E, x, q, f, k, l);
1722
- v.l && (void 0 === v.l.T && (v.l.T = []), v.l.T.push(v));
1723
- q = new Vb(t, v, !0, !1);
1724
- F = new Vb(t + "*", v, !1, !1);
1725
- var I = new Vb(t + " const*", v, !1, !0);
1726
- sb[b] = {pointerType:F, Ka:I};
1727
- Wb(g, r);
1728
- return [q, F, I];
1688
+ var E = Object.create(F, {constructor:{value:t},});
1689
+ t.prototype = E;
1690
+ var v = new Lb(r, t, E, y, q, f, h, n);
1691
+ if (v.o) {
1692
+ var I;
1693
+ (I = v.o).S ?? (I.S = []);
1694
+ v.o.S.push(v);
1695
+ }
1696
+ q = new Rb(r, v, !0, !1, !1);
1697
+ I = new Rb(r + "*", v, !1, !1, !1);
1698
+ F = new Rb(r + " const*", v, !1, !0, !1);
1699
+ pb[b] = {pointerType:I, Ga:F};
1700
+ Sb(g, t);
1701
+ return [q, I, F];
1729
1702
  });
1730
- }, _embind_register_class_class_function:function(b, a, c, d, e, f, m) {
1731
- var k = cc(c, d);
1732
- a = U(a);
1733
- f = X(e, f);
1734
- W([], [b], function(n) {
1735
- function l() {
1736
- ac(`Cannot call ${t} due to unbound types`, k);
1703
+ }, _embind_register_class_class_function:(b, a, c, d, e, f, m) => {
1704
+ var h = bc(c, d);
1705
+ a = T(a);
1706
+ a = cc(a);
1707
+ f = Y(e, f);
1708
+ X([], [b], l => {
1709
+ function n() {
1710
+ Zb(`Cannot call ${r} due to unbound types`, h);
1737
1711
  }
1738
- n = n[0];
1739
- var t = `${n.name}.${a}`;
1712
+ l = l[0];
1713
+ var r = `${l.name}.${a}`;
1740
1714
  a.startsWith("@@") && (a = Symbol[a.substring(2)]);
1741
- var w = n.h.constructor;
1742
- void 0 === w[a] ? (l.L = c - 1, w[a] = l) : (Nb(w, a, t), w[a].m[c - 1] = l);
1743
- W([], k, function(x) {
1744
- x = bc(t, [x[0], null].concat(x.slice(1)), null, f, m);
1745
- void 0 === w[a].m ? (x.L = c - 1, w[a] = x) : w[a].m[c - 1] = x;
1746
- if (n.h.T) {
1747
- for (const g of n.h.T) {
1748
- g.constructor.hasOwnProperty(a) || (g.constructor[a] = x);
1715
+ var w = l.h.constructor;
1716
+ void 0 === w[a] ? (n.K = c - 1, w[a] = n) : (Ib(w, a, r), w[a].l[c - 1] = n);
1717
+ X([], h, y => {
1718
+ y = ac(r, [y[0], null].concat(y.slice(1)), null, f, m);
1719
+ void 0 === w[a].l ? (y.K = c - 1, w[a] = y) : w[a].l[c - 1] = y;
1720
+ if (l.h.S) {
1721
+ for (const g of l.h.S) {
1722
+ g.constructor.hasOwnProperty(a) || (g.constructor[a] = y);
1749
1723
  }
1750
1724
  }
1751
1725
  return [];
1752
1726
  });
1753
1727
  return [];
1754
1728
  });
1755
- }, _embind_register_class_class_property:function(b, a, c, d, e, f, m, k) {
1756
- a = U(a);
1757
- f = X(e, f);
1758
- W([], [b], function(n) {
1759
- n = n[0];
1760
- var l = `${n.name}.${a}`, t = {get() {
1761
- ac(`Cannot access ${l} due to unbound types`, [c]);
1729
+ }, _embind_register_class_class_property:(b, a, c, d, e, f, m, h) => {
1730
+ a = T(a);
1731
+ f = Y(e, f);
1732
+ X([], [b], l => {
1733
+ l = l[0];
1734
+ var n = `${l.name}.${a}`, r = {get() {
1735
+ Zb(`Cannot access ${n} due to unbound types`, [c]);
1762
1736
  }, enumerable:!0, configurable:!0};
1763
- t.set = k ? () => {
1764
- ac(`Cannot access ${l} due to unbound types`, [c]);
1737
+ r.set = h ? () => {
1738
+ Zb(`Cannot access ${n} due to unbound types`, [c]);
1765
1739
  } : () => {
1766
- Q(`${l} is a read-only property`);
1740
+ throw new Q(`${n} is a read-only property`);
1767
1741
  };
1768
- Object.defineProperty(n.h.constructor, a, t);
1769
- W([], [c], function(w) {
1742
+ Object.defineProperty(l.h.constructor, a, r);
1743
+ X([], [c], w => {
1770
1744
  w = w[0];
1771
- var x = {get() {
1745
+ var y = {get() {
1772
1746
  return w.fromWireType(f(d));
1773
1747
  }, enumerable:!0};
1774
- k && (k = X(m, k), x.set = g => {
1775
- var r = [];
1776
- k(d, w.toWireType(r, g));
1777
- Eb(r);
1748
+ h && (h = Y(m, h), y.set = g => {
1749
+ var t = [];
1750
+ h(d, w.toWireType(t, g));
1751
+ Ab(t);
1778
1752
  });
1779
- Object.defineProperty(n.h.constructor, a, x);
1753
+ Object.defineProperty(l.h.constructor, a, y);
1780
1754
  return [];
1781
1755
  });
1782
1756
  return [];
1783
1757
  });
1784
- }, _embind_register_class_constructor:function(b, a, c, d, e, f) {
1785
- var m = cc(a, c);
1786
- e = X(d, e);
1787
- W([], [b], function(k) {
1788
- k = k[0];
1789
- var n = `constructor ${k.name}`;
1790
- void 0 === k.h.I && (k.h.I = []);
1791
- if (void 0 !== k.h.I[a - 1]) {
1792
- throw new ab(`Cannot register multiple constructors with identical number of parameters (${a - 1}) for class '${k.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`);
1793
- }
1794
- k.h.I[a - 1] = () => {
1795
- ac(`Cannot construct ${k.name} due to unbound types`, m);
1758
+ }, _embind_register_class_constructor:(b, a, c, d, e, f) => {
1759
+ var m = bc(a, c);
1760
+ e = Y(d, e);
1761
+ X([], [b], h => {
1762
+ h = h[0];
1763
+ var l = `constructor ${h.name}`;
1764
+ void 0 === h.h.H && (h.h.H = []);
1765
+ if (void 0 !== h.h.H[a - 1]) {
1766
+ throw new Q(`Cannot register multiple constructors with identical number of parameters (${a - 1}) for class '${h.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`);
1767
+ }
1768
+ h.h.H[a - 1] = () => {
1769
+ Zb(`Cannot construct ${h.name} due to unbound types`, m);
1796
1770
  };
1797
- W([], m, function(l) {
1798
- l.splice(1, 0, null);
1799
- k.h.I[a - 1] = bc(n, l, null, e, f);
1771
+ X([], m, n => {
1772
+ n.splice(1, 0, null);
1773
+ h.h.H[a - 1] = ac(l, n, null, e, f);
1800
1774
  return [];
1801
1775
  });
1802
1776
  return [];
1803
1777
  });
1804
- }, _embind_register_class_function:function(b, a, c, d, e, f, m, k) {
1805
- var n = cc(c, d);
1806
- a = U(a);
1807
- f = X(e, f);
1808
- W([], [b], function(l) {
1809
- function t() {
1810
- ac(`Cannot call ${w} due to unbound types`, n);
1778
+ }, _embind_register_class_function:(b, a, c, d, e, f, m, h) => {
1779
+ var l = bc(c, d);
1780
+ a = T(a);
1781
+ a = cc(a);
1782
+ f = Y(e, f);
1783
+ X([], [b], n => {
1784
+ function r() {
1785
+ Zb(`Cannot call ${w} due to unbound types`, l);
1811
1786
  }
1812
- l = l[0];
1813
- var w = `${l.name}.${a}`;
1787
+ n = n[0];
1788
+ var w = `${n.name}.${a}`;
1814
1789
  a.startsWith("@@") && (a = Symbol[a.substring(2)]);
1815
- k && l.h.ya.push(a);
1816
- var x = l.h.B, g = x[a];
1817
- void 0 === g || void 0 === g.m && g.className !== l.name && g.L === c - 2 ? (t.L = c - 2, t.className = l.name, x[a] = t) : (Nb(x, a, w), x[a].m[c - 2] = t);
1818
- W([], n, function(r) {
1819
- r = bc(w, r, l, f, m);
1820
- void 0 === x[a].m ? (r.L = c - 2, x[a] = r) : x[a].m[c - 2] = r;
1790
+ h && n.h.va.push(a);
1791
+ var y = n.h.B, g = y[a];
1792
+ void 0 === g || void 0 === g.l && g.className !== n.name && g.K === c - 2 ? (r.K = c - 2, r.className = n.name, y[a] = r) : (Ib(y, a, w), y[a].l[c - 2] = r);
1793
+ X([], l, t => {
1794
+ t = ac(w, t, n, f, m);
1795
+ void 0 === y[a].l ? (t.K = c - 2, y[a] = t) : y[a].l[c - 2] = t;
1821
1796
  return [];
1822
1797
  });
1823
1798
  return [];
1824
1799
  });
1825
- }, _embind_register_class_property:function(b, a, c, d, e, f, m, k, n, l) {
1826
- a = U(a);
1827
- e = X(d, e);
1828
- W([], [b], function(t) {
1829
- t = t[0];
1830
- var w = `${t.name}.${a}`, x = {get() {
1831
- ac(`Cannot access ${w} due to unbound types`, [c, m]);
1800
+ }, _embind_register_class_property:(b, a, c, d, e, f, m, h, l, n) => {
1801
+ a = T(a);
1802
+ e = Y(d, e);
1803
+ X([], [b], r => {
1804
+ r = r[0];
1805
+ var w = `${r.name}.${a}`, y = {get() {
1806
+ Zb(`Cannot access ${w} due to unbound types`, [c, m]);
1832
1807
  }, enumerable:!0, configurable:!0};
1833
- x.set = n ? () => {
1834
- ac(`Cannot access ${w} due to unbound types`, [c, m]);
1835
- } : () => {
1836
- Q(w + " is a read-only property");
1808
+ y.set = l ? () => Zb(`Cannot access ${w} due to unbound types`, [c, m]) : () => {
1809
+ throw new Q(w + " is a read-only property");
1837
1810
  };
1838
- Object.defineProperty(t.h.B, a, x);
1839
- W([], n ? [c, m] : [c], function(g) {
1840
- var r = g[0], q = {get() {
1841
- var E = dc(this, t, w + " getter");
1842
- return r.fromWireType(e(f, E));
1811
+ Object.defineProperty(r.h.B, a, y);
1812
+ X([], l ? [c, m] : [c], g => {
1813
+ var t = g[0], q = {get() {
1814
+ var E = dc(this, r, w + " getter");
1815
+ return t.fromWireType(e(f, E));
1843
1816
  }, enumerable:!0};
1844
- if (n) {
1845
- n = X(k, n);
1817
+ if (l) {
1818
+ l = Y(h, l);
1846
1819
  var F = g[1];
1847
1820
  q.set = function(E) {
1848
- var v = dc(this, t, w + " setter"), I = [];
1849
- n(l, v, F.toWireType(I, E));
1850
- Eb(I);
1821
+ var v = dc(this, r, w + " setter"), I = [];
1822
+ l(n, v, F.toWireType(I, E));
1823
+ Ab(I);
1851
1824
  };
1852
1825
  }
1853
- Object.defineProperty(t.h.B, a, q);
1826
+ Object.defineProperty(r.h.B, a, q);
1854
1827
  return [];
1855
1828
  });
1856
1829
  return [];
1857
1830
  });
1858
- }, _embind_register_emval:function(b, a) {
1859
- a = U(a);
1860
- Ib(b, {name:a, fromWireType:function(c) {
1861
- var d = R(c);
1862
- ec(c);
1863
- return d;
1864
- }, toWireType:function(c, d) {
1865
- return S(d);
1866
- }, argPackAdvance:8, readValueFromPointer:Fb, v:null,});
1867
- }, _embind_register_enum:function(b, a, c, d) {
1831
+ }, _embind_register_emval:b => Eb(b, fc), _embind_register_enum:(b, a, c, d) => {
1868
1832
  function e() {
1869
1833
  }
1870
- c = Jb(c);
1871
- a = U(a);
1834
+ a = T(a);
1872
1835
  e.values = {};
1873
- Ib(b, {name:a, constructor:e, fromWireType:function(f) {
1836
+ Eb(b, {name:a, constructor:e, fromWireType:function(f) {
1874
1837
  return this.constructor.values[f];
1875
- }, toWireType:function(f, m) {
1876
- return m.value;
1877
- }, argPackAdvance:8, readValueFromPointer:fc(a, c, d), v:null,});
1878
- Ob(a, e);
1879
- }, _embind_register_enum_value:function(b, a, c) {
1880
- var d = nb(b, "enum");
1881
- a = U(a);
1838
+ }, toWireType:(f, m) => m.value, argPackAdvance:8, readValueFromPointer:gc(a, c, d), A:null,});
1839
+ Jb(a, e);
1840
+ }, _embind_register_enum_value:(b, a, c) => {
1841
+ var d = lb(b, "enum");
1842
+ a = T(a);
1882
1843
  b = d.constructor;
1883
- d = Object.create(d.constructor.prototype, {value:{value:c}, constructor:{value:Za(`${d.name}_${a}`, function() {
1844
+ d = Object.create(d.constructor.prototype, {value:{value:c}, constructor:{value:Xa(`${d.name}_${a}`, function() {
1884
1845
  })},});
1885
1846
  b.values[c] = d;
1886
1847
  b[a] = d;
1887
- }, _embind_register_float:function(b, a, c) {
1888
- c = Jb(c);
1889
- a = U(a);
1890
- Ib(b, {name:a, fromWireType:function(d) {
1891
- return d;
1892
- }, toWireType:function(d, e) {
1893
- return e;
1894
- }, argPackAdvance:8, readValueFromPointer:gc(a, c), v:null,});
1895
- }, _embind_register_function:function(b, a, c, d, e, f) {
1896
- var m = cc(a, c);
1897
- b = U(b);
1898
- e = X(d, e);
1899
- Ob(b, function() {
1900
- ac(`Cannot call ${b} due to unbound types`, m);
1848
+ }, _embind_register_float:(b, a, c) => {
1849
+ a = T(a);
1850
+ Eb(b, {name:a, fromWireType:d => d, toWireType:(d, e) => e, argPackAdvance:8, readValueFromPointer:hc(a, c), A:null,});
1851
+ }, _embind_register_function:(b, a, c, d, e, f) => {
1852
+ var m = bc(a, c);
1853
+ b = T(b);
1854
+ b = cc(b);
1855
+ e = Y(d, e);
1856
+ Jb(b, function() {
1857
+ Zb(`Cannot call ${b} due to unbound types`, m);
1901
1858
  }, a - 1);
1902
- W([], m, function(k) {
1903
- Wb(b, bc(b, [k[0], null].concat(k.slice(1)), null, e, f), a - 1);
1859
+ X([], m, h => {
1860
+ Sb(b, ac(b, [h[0], null].concat(h.slice(1)), null, e, f), a - 1);
1904
1861
  return [];
1905
1862
  });
1906
- }, _embind_register_integer:function(b, a, c, d, e) {
1907
- a = U(a);
1863
+ }, _embind_register_integer:(b, a, c, d, e) => {
1864
+ a = T(a);
1908
1865
  -1 === e && (e = 4294967295);
1909
- e = Jb(c);
1910
- var f = k => k;
1866
+ e = h => h;
1911
1867
  if (0 === d) {
1912
- var m = 32 - 8 * c;
1913
- f = k => k << m >>> m;
1868
+ var f = 32 - 8 * c;
1869
+ e = h => h << f >>> f;
1914
1870
  }
1915
- c = a.includes("unsigned") ? function(k, n) {
1916
- return n >>> 0;
1917
- } : function(k, n) {
1918
- return n;
1871
+ var m = a.includes("unsigned") ? function(h, l) {
1872
+ return l >>> 0;
1873
+ } : function(h, l) {
1874
+ return l;
1919
1875
  };
1920
- Ib(b, {name:a, fromWireType:f, toWireType:c, argPackAdvance:8, readValueFromPointer:hc(a, e, 0 !== d), v:null,});
1921
- }, _embind_register_memory_view:function(b, a, c) {
1876
+ Eb(b, {name:a, fromWireType:e, toWireType:m, argPackAdvance:8, readValueFromPointer:ic(a, c, 0 !== d), A:null,});
1877
+ }, _embind_register_memory_view:(b, a, c) => {
1922
1878
  function d(f) {
1923
- f >>= 2;
1924
- var m = L;
1925
- return new e(m.buffer, m[f + 1], m[f]);
1879
+ return new e(Ca.buffer, O[f + 4 >> 2], O[f >> 2]);
1926
1880
  }
1927
1881
  var e = [Int8Array, Uint8Array, Int16Array, Uint16Array, Int32Array, Uint32Array, Float32Array, Float64Array,][a];
1928
- c = U(c);
1929
- Ib(b, {name:c, fromWireType:d, argPackAdvance:8, readValueFromPointer:d,}, {ab:!0,});
1930
- }, _embind_register_std_string:function(b, a) {
1931
- a = U(a);
1882
+ c = T(c);
1883
+ Eb(b, {name:c, fromWireType:d, argPackAdvance:8, readValueFromPointer:d,}, {Ua:!0,});
1884
+ }, _embind_register_std_string:(b, a) => {
1885
+ a = T(a);
1932
1886
  var c = "std::string" === a;
1933
- Ib(b, {name:a, fromWireType:function(d) {
1934
- var e = L[d >> 2], f = d + 4;
1887
+ Eb(b, {name:a, fromWireType:function(d) {
1888
+ var e = O[d >> 2], f = d + 4;
1935
1889
  if (c) {
1936
- for (var m = f, k = 0; k <= e; ++k) {
1937
- var n = f + k;
1938
- if (k == e || 0 == J[n]) {
1939
- m = m ? lc(J, m, n - m) : "";
1940
- if (void 0 === l) {
1941
- var l = m;
1890
+ for (var m = f, h = 0; h <= e; ++h) {
1891
+ var l = f + h;
1892
+ if (h == e || 0 == J[l]) {
1893
+ m = m ? oc(J, m, l - m) : "";
1894
+ if (void 0 === n) {
1895
+ var n = m;
1942
1896
  } else {
1943
- l += String.fromCharCode(0), l += m;
1897
+ n += String.fromCharCode(0), n += m;
1944
1898
  }
1945
- m = n + 1;
1899
+ m = l + 1;
1946
1900
  }
1947
1901
  }
1948
1902
  } else {
1949
- l = Array(e);
1950
- for (k = 0; k < e; ++k) {
1951
- l[k] = String.fromCharCode(J[f + k]);
1903
+ n = Array(e);
1904
+ for (h = 0; h < e; ++h) {
1905
+ n[h] = String.fromCharCode(J[f + h]);
1952
1906
  }
1953
- l = l.join("");
1907
+ n = n.join("");
1954
1908
  }
1955
- mb(d);
1956
- return l;
1909
+ jb(d);
1910
+ return n;
1957
1911
  }, toWireType:function(d, e) {
1958
1912
  e instanceof ArrayBuffer && (e = new Uint8Array(e));
1959
1913
  var f = "string" == typeof e;
1960
- f || e instanceof Uint8Array || e instanceof Uint8ClampedArray || e instanceof Int8Array || Q("Cannot pass non-string to std::string");
1961
- var m = c && f ? jc(e) : e.length;
1962
- var k = Mc(4 + m + 1), n = k + 4;
1963
- L[k >> 2] = m;
1914
+ if (!(f || e instanceof Uint8Array || e instanceof Uint8ClampedArray || e instanceof Int8Array)) {
1915
+ throw new Q("Cannot pass non-string to std::string");
1916
+ }
1917
+ var m = c && f ? kc(e) : e.length;
1918
+ var h = Oc(4 + m + 1), l = h + 4;
1919
+ O[h >> 2] = m;
1964
1920
  if (c && f) {
1965
- ic(e, J, n, m + 1);
1921
+ jc(e, J, l, m + 1);
1966
1922
  } else {
1967
1923
  if (f) {
1968
1924
  for (f = 0; f < m; ++f) {
1969
- var l = e.charCodeAt(f);
1970
- 255 < l && (mb(n), Q("String has UTF-16 code units that do not fit in 8 bits"));
1971
- J[n + f] = l;
1925
+ var n = e.charCodeAt(f);
1926
+ if (255 < n) {
1927
+ throw jb(l), new Q("String has UTF-16 code units that do not fit in 8 bits");
1928
+ }
1929
+ J[l + f] = n;
1972
1930
  }
1973
1931
  } else {
1974
1932
  for (f = 0; f < m; ++f) {
1975
- J[n + f] = e[f];
1933
+ J[l + f] = e[f];
1976
1934
  }
1977
1935
  }
1978
1936
  }
1979
- null !== d && d.push(mb, k);
1980
- return k;
1981
- }, argPackAdvance:8, readValueFromPointer:Fb, v:function(d) {
1982
- mb(d);
1937
+ null !== d && d.push(jb, h);
1938
+ return h;
1939
+ }, argPackAdvance:8, readValueFromPointer:Bb, A(d) {
1940
+ jb(d);
1983
1941
  },});
1984
- }, _embind_register_std_wstring:function(b, a, c) {
1985
- c = U(c);
1942
+ }, _embind_register_std_wstring:(b, a, c) => {
1943
+ c = T(c);
1986
1944
  if (2 === a) {
1987
- var d = nc;
1988
- var e = qc;
1989
- var f = rc;
1990
- var m = () => Ea;
1991
- var k = 1;
1945
+ var d = qc;
1946
+ var e = rc;
1947
+ var f = sc;
1948
+ var m = h => Ea[h >> 1];
1992
1949
  } else {
1993
- 4 === a && (d = sc, e = tc, f = uc, m = () => L, k = 2);
1950
+ 4 === a && (d = tc, e = uc, f = vc, m = h => O[h >> 2]);
1994
1951
  }
1995
- Ib(b, {name:c, fromWireType:function(n) {
1996
- for (var l = L[n >> 2], t = m(), w, x = n + 4, g = 0; g <= l; ++g) {
1997
- var r = n + 4 + g * a;
1998
- if (g == l || 0 == t[r >> k]) {
1999
- x = d(x, r - x), void 0 === w ? w = x : (w += String.fromCharCode(0), w += x), x = r + a;
1952
+ Eb(b, {name:c, fromWireType:h => {
1953
+ for (var l = O[h >> 2], n, r = h + 4, w = 0; w <= l; ++w) {
1954
+ var y = h + 4 + w * a;
1955
+ if (w == l || 0 == m(y)) {
1956
+ r = d(r, y - r), void 0 === n ? n = r : (n += String.fromCharCode(0), n += r), r = y + a;
2000
1957
  }
2001
1958
  }
2002
- mb(n);
2003
- return w;
2004
- }, toWireType:function(n, l) {
2005
- "string" != typeof l && Q(`Cannot pass non-string to C++ string type ${c}`);
2006
- var t = f(l), w = Mc(4 + t + a);
2007
- L[w >> 2] = t >> k;
2008
- e(l, w + 4, t + a);
2009
- null !== n && n.push(mb, w);
2010
- return w;
2011
- }, argPackAdvance:8, readValueFromPointer:Fb, v:function(n) {
2012
- mb(n);
2013
- },});
2014
- }, _embind_register_value_object:function(b, a, c, d, e, f) {
2015
- Db[b] = {name:U(a), fa:X(c, d), H:X(e, f), sa:[],};
2016
- }, _embind_register_value_object_field:function(b, a, c, d, e, f, m, k, n, l) {
2017
- Db[b].sa.push({Sa:U(a), Ya:c, Wa:X(d, e), Xa:f, lb:m, kb:X(k, n), mb:l,});
2018
- }, _embind_register_void:function(b, a) {
2019
- a = U(a);
2020
- Ib(b, {cb:!0, name:a, argPackAdvance:0, fromWireType:function() {
2021
- }, toWireType:function() {
1959
+ jb(h);
1960
+ return n;
1961
+ }, toWireType:(h, l) => {
1962
+ if ("string" != typeof l) {
1963
+ throw new Q(`Cannot pass non-string to C++ string type ${c}`);
1964
+ }
1965
+ var n = f(l), r = Oc(4 + n + a);
1966
+ O[r >> 2] = n / a;
1967
+ e(l, r + 4, n + a);
1968
+ null !== h && h.push(jb, r);
1969
+ return r;
1970
+ }, argPackAdvance:8, readValueFromPointer:Bb, A(h) {
1971
+ jb(h);
1972
+ }});
1973
+ }, _embind_register_value_object:(b, a, c, d, e, f) => {
1974
+ zb[b] = {name:T(a), ea:Y(c, d), C:Y(e, f), ra:[],};
1975
+ }, _embind_register_value_object_field:(b, a, c, d, e, f, m, h, l, n) => {
1976
+ zb[b].ra.push({Na:T(a), Ta:c, Ra:Y(d, e), Sa:f, cb:m, bb:Y(h, l), eb:n,});
1977
+ }, _embind_register_void:(b, a) => {
1978
+ a = T(a);
1979
+ Eb(b, {lb:!0, name:a, argPackAdvance:0, fromWireType:() => {
1980
+ }, toWireType:() => {
2022
1981
  },});
2023
- }, _emscripten_get_now_is_monotonic:() => !0, _emval_as:function(b, a, c) {
2024
- b = R(b);
2025
- a = nb(a, "emval::as");
2026
- var d = [], e = S(d);
2027
- L[c >> 2] = e;
2028
- return a.toWireType(d, b);
2029
- }, _emval_call_method:function(b, a, c, d, e) {
2030
- b = xc[b];
2031
- a = R(a);
2032
- c = wc(c);
2033
- var f = [];
2034
- L[d >> 2] = S(f);
2035
- return b(a, c, f, e);
2036
- }, _emval_call_void_method:function(b, a, c, d) {
2037
- b = xc[b];
2038
- a = R(a);
2039
- c = wc(c);
2040
- b(a, c, null, d);
2041
- }, _emval_decref:ec, _emval_get_method_caller:function(b, a) {
2042
- var c = zc(b, a), d = c[0];
2043
- a = d.name + "_$" + c.slice(1).map(function(m) {
2044
- return m.name;
2045
- }).join("_") + "$";
2046
- var e = Ac[a];
2047
- if (void 0 !== e) {
2048
- return e;
2049
- }
2050
- var f = Array(b - 1);
2051
- e = yc((m, k, n, l) => {
2052
- for (var t = 0, w = 0; w < b - 1; ++w) {
2053
- f[w] = c[w + 1].readValueFromPointer(l + t), t += c[w + 1].argPackAdvance;
2054
- }
2055
- m = m[k].apply(m, f);
2056
- for (w = 0; w < b - 1; ++w) {
2057
- c[w + 1].Na && c[w + 1].Na(f[w]);
2058
- }
2059
- if (!d.cb) {
2060
- return d.toWireType(n, m);
1982
+ }, _emscripten_get_now_is_monotonic:() => 1, _emscripten_memcpy_js:(b, a, c) => J.copyWithin(b, a, a + c), _emval_as:(b, a, c) => {
1983
+ b = S(b);
1984
+ a = lb(a, "emval::as");
1985
+ return wc(a, c, b);
1986
+ }, _emval_call_method:(b, a, c, d, e) => {
1987
+ b = zc[b];
1988
+ a = S(a);
1989
+ c = yc(c);
1990
+ return b(a, a[c], d, e);
1991
+ }, _emval_decref:ec, _emval_get_method_caller:(b, a, c) => {
1992
+ var d = Bc(b, a), e = d.shift();
1993
+ b--;
1994
+ var f = Array(b);
1995
+ a = `methodCaller<(${d.map(m => m.name).join(", ")}) => ${e.name}>`;
1996
+ return Ac(Xa(a, (m, h, l, n) => {
1997
+ for (var r = 0, w = 0; w < b; ++w) {
1998
+ f[w] = d[w].readValueFromPointer(n + r), r += d[w].argPackAdvance;
2061
1999
  }
2062
- });
2063
- return Ac[a] = e;
2064
- }, _emval_get_module_property:function(b) {
2065
- b = wc(b);
2066
- return S(h[b]);
2067
- }, _emval_get_property:function(b, a) {
2068
- b = R(b);
2069
- a = R(a);
2070
- return S(b[a]);
2071
- }, _emval_incref:function(b) {
2072
- 4 < b && (P.get(b).Aa += 1);
2073
- }, _emval_new_array:function() {
2074
- return S([]);
2075
- }, _emval_new_cstring:function(b) {
2076
- return S(wc(b));
2077
- }, _emval_new_object:function() {
2078
- return S({});
2079
- }, _emval_run_destructors:function(b) {
2080
- var a = R(b);
2081
- Eb(a);
2000
+ m = 1 === c ? Cc(h, f) : h.apply(m, f);
2001
+ return wc(e, l, m);
2002
+ }));
2003
+ }, _emval_get_module_property:b => {
2004
+ b = yc(b);
2005
+ return Za(k[b]);
2006
+ }, _emval_get_property:(b, a) => {
2007
+ b = S(b);
2008
+ a = S(a);
2009
+ return Za(b[a]);
2010
+ }, _emval_incref:b => {
2011
+ 9 < b && (P[b + 1] += 1);
2012
+ }, _emval_new_array:() => Za([]), _emval_new_cstring:b => Za(yc(b)), _emval_new_object:() => Za({}), _emval_run_destructors:b => {
2013
+ var a = S(b);
2014
+ Ab(a);
2082
2015
  ec(b);
2083
- }, _emval_set_property:function(b, a, c) {
2084
- b = R(b);
2085
- a = R(a);
2086
- c = R(c);
2016
+ }, _emval_set_property:(b, a, c) => {
2017
+ b = S(b);
2018
+ a = S(a);
2019
+ c = S(c);
2087
2020
  b[a] = c;
2088
- }, _emval_take_value:function(b, a) {
2089
- b = nb(b, "_emval_take_value");
2021
+ }, _emval_take_value:(b, a) => {
2022
+ b = lb(b, "_emval_take_value");
2090
2023
  b = b.readValueFromPointer(a);
2091
- return S(b);
2092
- }, abort:() => {
2093
- za("");
2094
- }, emscripten_date_now:function() {
2095
- return Date.now();
2096
- }, emscripten_get_now:() => performance.now(), emscripten_memcpy_big:(b, a, c) => J.copyWithin(b, a, a + c), emscripten_resize_heap:b => {
2024
+ return Za(b);
2025
+ }, emscripten_date_now:() => Date.now(), emscripten_get_now:() => performance.now(), emscripten_resize_heap:b => {
2097
2026
  var a = J.length;
2098
2027
  b >>>= 0;
2099
2028
  if (2147483648 < b) {
@@ -2105,7 +2034,7 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
2105
2034
  var e = Math;
2106
2035
  d = Math.max(b, d);
2107
2036
  a: {
2108
- e = e.min.call(e, 2147483648, d + (65536 - d % 65536) % 65536) - Aa.buffer.byteLength + 65535 >>> 16;
2037
+ e = (e.min.call(e, 2147483648, d + (65536 - d % 65536) % 65536) - Aa.buffer.byteLength + 65535) / 65536;
2109
2038
  try {
2110
2039
  Aa.grow(e);
2111
2040
  Ha();
@@ -2122,127 +2051,119 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
2122
2051
  return !1;
2123
2052
  }, environ_get:(b, a) => {
2124
2053
  var c = 0;
2125
- Dc().forEach(function(d, e) {
2054
+ Fc().forEach((d, e) => {
2126
2055
  var f = a + c;
2127
- e = L[b + 4 * e >> 2] = f;
2056
+ e = O[b + 4 * e >> 2] = f;
2128
2057
  for (f = 0; f < d.length; ++f) {
2129
- Ca[e++ >> 0] = d.charCodeAt(f);
2058
+ Ca[e++] = d.charCodeAt(f);
2130
2059
  }
2131
- Ca[e >> 0] = 0;
2060
+ Ca[e] = 0;
2132
2061
  c += d.length + 1;
2133
2062
  });
2134
2063
  return 0;
2135
2064
  }, environ_sizes_get:(b, a) => {
2136
- var c = Dc();
2137
- L[b >> 2] = c.length;
2065
+ var c = Fc();
2066
+ O[b >> 2] = c.length;
2138
2067
  var d = 0;
2139
- c.forEach(function(e) {
2140
- d += e.length + 1;
2141
- });
2142
- L[a >> 2] = d;
2068
+ c.forEach(e => d += e.length + 1);
2069
+ O[a >> 2] = d;
2143
2070
  return 0;
2144
2071
  }, fd_close:() => 52, fd_seek:function() {
2145
2072
  return 70;
2146
2073
  }, fd_write:(b, a, c, d) => {
2147
2074
  for (var e = 0, f = 0; f < c; f++) {
2148
- var m = L[a >> 2], k = L[a + 4 >> 2];
2075
+ var m = O[a >> 2], h = O[a + 4 >> 2];
2149
2076
  a += 8;
2150
- for (var n = 0; n < k; n++) {
2151
- var l = J[m + n], t = Ec[b];
2152
- 0 === l || 10 === l ? ((1 === b ? ua : va)(lc(t, 0)), t.length = 0) : t.push(l);
2077
+ for (var l = 0; l < h; l++) {
2078
+ var n = J[m + l], r = Gc[b];
2079
+ 0 === n || 10 === n ? ((1 === b ? xa : ya)(oc(r, 0)), r.length = 0) : r.push(n);
2153
2080
  }
2154
- e += k;
2081
+ e += h;
2155
2082
  }
2156
- L[d >> 2] = e;
2083
+ O[d >> 2] = e;
2157
2084
  return 0;
2158
- }, strftime_l:(b, a, c, d) => Jc(b, a, c, d)};
2159
- (function() {
2085
+ }, strftime_l:(b, a, c, d) => Lc(b, a, c, d)}, Z = function() {
2160
2086
  function b(c) {
2161
- z = c = c.exports;
2162
- Aa = z.memory;
2087
+ Z = c.exports;
2088
+ Aa = Z.memory;
2163
2089
  Ha();
2164
- Ia = z.__indirect_function_table;
2165
- Ka.unshift(z.__wasm_call_ctors);
2166
- Na--;
2167
- h.monitorRunDependencies && h.monitorRunDependencies(Na);
2168
- if (0 == Na && (null !== Oa && (clearInterval(Oa), Oa = null), Pa)) {
2169
- var d = Pa;
2170
- Pa = null;
2171
- d();
2172
- }
2173
- return c;
2174
- }
2175
- var a = {env:Nc, wasi_snapshot_preview1:Nc,};
2176
- Na++;
2177
- h.monitorRunDependencies && h.monitorRunDependencies(Na);
2178
- if (h.instantiateWasm) {
2090
+ Ub = Z.__indirect_function_table;
2091
+ Ja.unshift(Z.__wasm_call_ctors);
2092
+ Ma--;
2093
+ k.monitorRunDependencies?.(Ma);
2094
+ 0 == Ma && (null !== Na && (clearInterval(Na), Na = null), Oa && (c = Oa, Oa = null, c()));
2095
+ return Z;
2096
+ }
2097
+ var a = {env:Pc, wasi_snapshot_preview1:Pc,};
2098
+ Ma++;
2099
+ k.monitorRunDependencies?.(Ma);
2100
+ if (k.instantiateWasm) {
2179
2101
  try {
2180
- return h.instantiateWasm(a, b);
2102
+ return k.instantiateWasm(a, b);
2181
2103
  } catch (c) {
2182
- va("Module.instantiateWasm callback failed with error: " + c), ba(c);
2104
+ ya(`Module.instantiateWasm callback failed with error: ${c}`), ba(c);
2183
2105
  }
2184
2106
  }
2185
- Wa(a, function(c) {
2107
+ Ra ||= Qa("canvas_advanced.wasm") ? "canvas_advanced.wasm" : k.locateFile ? k.locateFile("canvas_advanced.wasm", x) : x + "canvas_advanced.wasm";
2108
+ Va(a, function(c) {
2186
2109
  b(c.instance);
2187
2110
  }).catch(ba);
2188
2111
  return {};
2189
- })();
2190
- var mb = b => (mb = z.free)(b), Mc = b => (Mc = z.malloc)(b), lb = b => (lb = z.__getTypeName)(b);
2191
- h.__embind_initialize_bindings = () => (h.__embind_initialize_bindings = z._embind_initialize_bindings)();
2192
- h.dynCall_jiji = (b, a, c, d, e) => (h.dynCall_jiji = z.dynCall_jiji)(b, a, c, d, e);
2193
- h.dynCall_viijii = (b, a, c, d, e, f, m) => (h.dynCall_viijii = z.dynCall_viijii)(b, a, c, d, e, f, m);
2194
- h.dynCall_iiiiij = (b, a, c, d, e, f, m) => (h.dynCall_iiiiij = z.dynCall_iiiiij)(b, a, c, d, e, f, m);
2195
- h.dynCall_iiiiijj = (b, a, c, d, e, f, m, k, n) => (h.dynCall_iiiiijj = z.dynCall_iiiiijj)(b, a, c, d, e, f, m, k, n);
2196
- h.dynCall_iiiiiijj = (b, a, c, d, e, f, m, k, n, l) => (h.dynCall_iiiiiijj = z.dynCall_iiiiiijj)(b, a, c, d, e, f, m, k, n, l);
2197
- var Oc;
2198
- Pa = function Pc() {
2199
- Oc || Qc();
2200
- Oc || (Pa = Pc);
2112
+ }(), jb = b => (jb = Z.free)(b), Oc = b => (Oc = Z.malloc)(b), ib = b => (ib = Z.__getTypeName)(b);
2113
+ k.dynCall_jiji = (b, a, c, d, e) => (k.dynCall_jiji = Z.dynCall_jiji)(b, a, c, d, e);
2114
+ k.dynCall_viijii = (b, a, c, d, e, f, m) => (k.dynCall_viijii = Z.dynCall_viijii)(b, a, c, d, e, f, m);
2115
+ k.dynCall_iiiiij = (b, a, c, d, e, f, m) => (k.dynCall_iiiiij = Z.dynCall_iiiiij)(b, a, c, d, e, f, m);
2116
+ k.dynCall_iiiiijj = (b, a, c, d, e, f, m, h, l) => (k.dynCall_iiiiijj = Z.dynCall_iiiiijj)(b, a, c, d, e, f, m, h, l);
2117
+ k.dynCall_iiiiiijj = (b, a, c, d, e, f, m, h, l, n) => (k.dynCall_iiiiiijj = Z.dynCall_iiiiiijj)(b, a, c, d, e, f, m, h, l, n);
2118
+ var Qc;
2119
+ Oa = function Rc() {
2120
+ Qc || Sc();
2121
+ Qc || (Oa = Rc);
2201
2122
  };
2202
- function Qc() {
2123
+ function Sc() {
2203
2124
  function b() {
2204
- if (!Oc && (Oc = !0, h.calledRun = !0, !Ba)) {
2205
- Xa(Ka);
2206
- aa(h);
2207
- if (h.onRuntimeInitialized) {
2208
- h.onRuntimeInitialized();
2125
+ if (!Qc && (Qc = !0, k.calledRun = !0, !Ba)) {
2126
+ Wa(Ja);
2127
+ aa(k);
2128
+ if (k.onRuntimeInitialized) {
2129
+ k.onRuntimeInitialized();
2209
2130
  }
2210
- if (h.postRun) {
2211
- for ("function" == typeof h.postRun && (h.postRun = [h.postRun]); h.postRun.length;) {
2212
- var a = h.postRun.shift();
2213
- La.unshift(a);
2131
+ if (k.postRun) {
2132
+ for ("function" == typeof k.postRun && (k.postRun = [k.postRun]); k.postRun.length;) {
2133
+ var a = k.postRun.shift();
2134
+ Ka.unshift(a);
2214
2135
  }
2215
2136
  }
2216
- Xa(La);
2137
+ Wa(Ka);
2217
2138
  }
2218
2139
  }
2219
- if (!(0 < Na)) {
2220
- if (h.preRun) {
2221
- for ("function" == typeof h.preRun && (h.preRun = [h.preRun]); h.preRun.length;) {
2222
- Ma();
2140
+ if (!(0 < Ma)) {
2141
+ if (k.preRun) {
2142
+ for ("function" == typeof k.preRun && (k.preRun = [k.preRun]); k.preRun.length;) {
2143
+ La();
2223
2144
  }
2224
2145
  }
2225
- Xa(Ja);
2226
- 0 < Na || (h.setStatus ? (h.setStatus("Running..."), setTimeout(function() {
2146
+ Wa(Ia);
2147
+ 0 < Ma || (k.setStatus ? (k.setStatus("Running..."), setTimeout(function() {
2227
2148
  setTimeout(function() {
2228
- h.setStatus("");
2149
+ k.setStatus("");
2229
2150
  }, 1);
2230
2151
  b();
2231
2152
  }, 1)) : b());
2232
2153
  }
2233
2154
  }
2234
- if (h.preInit) {
2235
- for ("function" == typeof h.preInit && (h.preInit = [h.preInit]); 0 < h.preInit.length;) {
2236
- h.preInit.pop()();
2155
+ if (k.preInit) {
2156
+ for ("function" == typeof k.preInit && (k.preInit = [k.preInit]); 0 < k.preInit.length;) {
2157
+ k.preInit.pop()();
2237
2158
  }
2238
2159
  }
2239
- Qc();
2160
+ Sc();
2161
+ moduleRtn = ca;
2240
2162
 
2241
2163
 
2242
2164
 
2243
- return moduleArg.ready
2165
+ return moduleRtn;
2244
2166
  }
2245
-
2246
2167
  );
2247
2168
  })();
2248
- export default Rive;
2169
+ export default Rive;