manim-web 0.30.0 → 0.31.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.
@@ -40611,7 +40611,7 @@ var jg = class e {
40611
40611
  if (this.isHeadless) throw Error("export() is not available in headless mode. Create a Scene with a container for rendering and exporting.");
40612
40612
  let n = e.slice(e.lastIndexOf(".")).toLowerCase(), r;
40613
40613
  if (n === ".gif") {
40614
- let { GifExporter: n } = await Promise.resolve().then(() => KP);
40614
+ let { GifExporter: n } = await Promise.resolve().then(() => QP);
40615
40615
  r = await new n(this, {
40616
40616
  fps: t?.fps,
40617
40617
  quality: t?.quality,
@@ -40623,7 +40623,7 @@ var jg = class e {
40623
40623
  workers: t?.workers
40624
40624
  }).exportTimeline(t?.duration), n.download(r, e);
40625
40625
  } else if (n === ".webm" || n === ".mp4" || n === ".mov") {
40626
- let { VideoExporter: i } = await Promise.resolve().then(() => XP), a = n === ".mp4" ? "mp4" : n === ".mov" ? "mov" : "webm";
40626
+ let { VideoExporter: i } = await Promise.resolve().then(() => nF), a = n === ".mp4" ? "mp4" : n === ".mov" ? "mov" : "webm";
40627
40627
  r = await new i(this, {
40628
40628
  fps: t?.fps,
40629
40629
  quality: t?.quality,
@@ -74624,13 +74624,141 @@ var VP = class {
74624
74624
  _resetTriggers() {
74625
74625
  for (let e of this._inputs.values()) e.kind === "trigger" && (e.value = !1);
74626
74626
  }
74627
+ }, HP = {
74628
+ " ": "space",
74629
+ spacebar: "space",
74630
+ esc: "escape",
74631
+ del: "delete",
74632
+ up: "arrowup",
74633
+ down: "arrowdown",
74634
+ left: "arrowleft",
74635
+ right: "arrowright"
74627
74636
  };
74637
+ function UP(e) {
74638
+ let t = e.toLowerCase();
74639
+ return HP[t] ?? t;
74640
+ }
74641
+ var WP = {
74642
+ right: ["arrowright", "d"],
74643
+ left: ["arrowleft", "a"],
74644
+ up: ["arrowup", "w"],
74645
+ down: ["arrowdown", "s"]
74646
+ };
74647
+ function GP(e) {
74648
+ return e || (typeof window < "u" && typeof window.addEventListener == "function" ? window : typeof document < "u" && typeof document.addEventListener == "function" ? document : null);
74649
+ }
74650
+ var KP = class {
74651
+ _target;
74652
+ _preventDefault;
74653
+ _down = /* @__PURE__ */ new Set();
74654
+ _pressed = /* @__PURE__ */ new Set();
74655
+ _released = /* @__PURE__ */ new Set();
74656
+ _downCallbacks = /* @__PURE__ */ new Map();
74657
+ _upCallbacks = /* @__PURE__ */ new Map();
74658
+ _enabled = !1;
74659
+ _onKeyDown;
74660
+ _onKeyUp;
74661
+ constructor(e = {}, t) {
74662
+ this._target = GP(t), this._preventDefault = Array.isArray(e.preventDefault) ? new Set(e.preventDefault.map(UP)) : e.preventDefault ?? !1, this._onKeyDown = this._handleKeyDown.bind(this), this._onKeyUp = this._handleKeyUp.bind(this), (e.autoEnable ?? !0) && this.enable();
74663
+ }
74664
+ get isEnabled() {
74665
+ return this._enabled;
74666
+ }
74667
+ get hasTarget() {
74668
+ return this._target !== null;
74669
+ }
74670
+ enable() {
74671
+ this._enabled || !this._target || (this._target.addEventListener("keydown", this._onKeyDown), this._target.addEventListener("keyup", this._onKeyUp), this._enabled = !0);
74672
+ }
74673
+ disable() {
74674
+ this._target && (this._target.removeEventListener("keydown", this._onKeyDown), this._target.removeEventListener("keyup", this._onKeyUp)), this._enabled = !1, this.clear();
74675
+ }
74676
+ dispose() {
74677
+ this.disable(), this._downCallbacks.clear(), this._upCallbacks.clear();
74678
+ }
74679
+ clear() {
74680
+ this._down.clear(), this._pressed.clear(), this._released.clear();
74681
+ }
74682
+ isKeyDown(e) {
74683
+ return this._down.has(UP(e));
74684
+ }
74685
+ anyKeyDown() {
74686
+ return this._down.size > 0;
74687
+ }
74688
+ wasPressed(e) {
74689
+ return this._pressed.has(UP(e));
74690
+ }
74691
+ wasReleased(e) {
74692
+ return this._released.has(UP(e));
74693
+ }
74694
+ getAxis() {
74695
+ return [!!this._anyDown(WP.right) - +!!this._anyDown(WP.left), !!this._anyDown(WP.up) - +!!this._anyDown(WP.down)];
74696
+ }
74697
+ getDirectionVector() {
74698
+ let [e, t] = this.getAxis(), n = Math.hypot(e, t);
74699
+ return n === 0 ? [0, 0] : [e / n, t / n];
74700
+ }
74701
+ onKeyDown(e, t) {
74702
+ return this._addCallback(this._downCallbacks, e, t);
74703
+ }
74704
+ onKeyUp(e, t) {
74705
+ return this._addCallback(this._upCallbacks, e, t);
74706
+ }
74707
+ bindBool(e, t, n) {
74708
+ let r = this.onKeyDown(n, () => e.setInput(t, !0)), i = this.onKeyUp(n, () => e.setInput(t, !1));
74709
+ return () => {
74710
+ r(), i();
74711
+ };
74712
+ }
74713
+ bindTrigger(e, t, n) {
74714
+ return this.onKeyDown(n, () => e.fire(t));
74715
+ }
74716
+ bindValue(e, t, n) {
74717
+ let r = n.releasedValue ?? 0, i = this.onKeyDown(t, () => e.setValue(n.heldValue)), a = this.onKeyUp(t, () => e.setValue(r));
74718
+ return () => {
74719
+ i(), a();
74720
+ };
74721
+ }
74722
+ update(e = 0) {
74723
+ this.endFrame();
74724
+ }
74725
+ endFrame() {
74726
+ this._pressed.clear(), this._released.clear();
74727
+ }
74728
+ _anyDown(e) {
74729
+ return e.some((e) => this._down.has(e));
74730
+ }
74731
+ _handleKeyDown(e) {
74732
+ let t = UP(e.key);
74733
+ this._maybePreventDefault(e, t), !(e.repeat || this._down.has(t)) && (this._down.add(t), this._pressed.add(t), this._emit(this._downCallbacks, t, e));
74734
+ }
74735
+ _handleKeyUp(e) {
74736
+ let t = UP(e.key);
74737
+ this._maybePreventDefault(e, t), this._down.delete(t), this._released.add(t), this._emit(this._upCallbacks, t, e);
74738
+ }
74739
+ _maybePreventDefault(e, t) {
74740
+ let n = this._preventDefault;
74741
+ (n === !0 || n instanceof Set && n.has(t)) && e.preventDefault();
74742
+ }
74743
+ _addCallback(e, t, n) {
74744
+ let r = t === "any" ? "any" : UP(t), i = e.get(r) ?? /* @__PURE__ */ new Set();
74745
+ return i.add(n), e.set(r, i), () => {
74746
+ i.delete(n), i.size === 0 && e.delete(r);
74747
+ };
74748
+ }
74749
+ _emit(e, t, n) {
74750
+ e.get(t)?.forEach((e) => e(t, n)), e.get("any")?.forEach((e) => e(t, n));
74751
+ }
74752
+ };
74753
+ function qP(e, t) {
74754
+ return new KP(e, t);
74755
+ }
74628
74756
  //#endregion
74629
74757
  //#region src/interaction/PanZoomControls.ts
74630
- function HP(e, t, n) {
74758
+ function JP(e, t, n) {
74631
74759
  return Math.max(t, Math.min(n, e));
74632
74760
  }
74633
- var UP = class {
74761
+ var YP = class {
74634
74762
  _camera;
74635
74763
  _domElement;
74636
74764
  _options;
@@ -74682,7 +74810,7 @@ var UP = class {
74682
74810
  if (!this._enabled || !this._options.enableZoom) return;
74683
74811
  let t = this._eventToNdc(e.clientX, e.clientY);
74684
74812
  if (!t) return;
74685
- let n = this._worldAt(t.x, t.y), r = this._options.invertZoom ? -e.deltaY : e.deltaY, i = Math.exp(r * this._options.zoomSpeed), a = this._baseFrameWidth / this._options.maxZoom, o = this._baseFrameWidth / this._options.minZoom, s = HP(this._camera.frameWidth * i, a, o) / this._camera.frameWidth;
74813
+ let n = this._worldAt(t.x, t.y), r = this._options.invertZoom ? -e.deltaY : e.deltaY, i = Math.exp(r * this._options.zoomSpeed), a = this._baseFrameWidth / this._options.maxZoom, o = this._baseFrameWidth / this._options.minZoom, s = JP(this._camera.frameWidth * i, a, o) / this._camera.frameWidth;
74686
74814
  if (s === 1) return;
74687
74815
  this._camera.frameWidth = this._camera.frameWidth * s, this._camera.frameHeight = this._camera.frameHeight * s;
74688
74816
  let c = n.x - t.x * this._camera.frameWidth / 2, l = n.y - t.y * this._camera.frameHeight / 2;
@@ -74731,12 +74859,12 @@ var UP = class {
74731
74859
  this._options.onChange?.();
74732
74860
  }
74733
74861
  };
74734
- function WP(e, t, n) {
74735
- return new UP(e, t, n);
74862
+ function XP(e, t, n) {
74863
+ return new YP(e, t, n);
74736
74864
  }
74737
74865
  //#endregion
74738
74866
  //#region node_modules/gif.js/dist/gif.js
74739
- var GP = /* @__PURE__ */ r(((e, t) => {
74867
+ var ZP = /* @__PURE__ */ r(((e, t) => {
74740
74868
  (function(n) {
74741
74869
  if (typeof e == "object" && t !== void 0) t.exports = n();
74742
74870
  else if (typeof define == "function" && define.amd) define([], n);
@@ -74990,10 +75118,10 @@ var GP = /* @__PURE__ */ r(((e, t) => {
74990
75118
  }]
74991
75119
  }, {}, [3])(3);
74992
75120
  });
74993
- })), KP = /* @__PURE__ */ t({
74994
- GifExporter: () => JP,
74995
- createGifExporter: () => YP
74996
- }), qP = /* @__PURE__ */ e(GP(), 1), JP = class e {
75121
+ })), QP = /* @__PURE__ */ t({
75122
+ GifExporter: () => eF,
75123
+ createGifExporter: () => tF
75124
+ }), $P = /* @__PURE__ */ e(ZP(), 1), eF = class e {
74997
75125
  _scene;
74998
75126
  _options;
74999
75127
  constructor(e, t) {
@@ -75011,7 +75139,7 @@ var GP = /* @__PURE__ */ r(((e, t) => {
75011
75139
  };
75012
75140
  }
75013
75141
  async exportTimeline(e) {
75014
- let t = (e || this._options.duration || this._getTimelineDuration()) ?? 5, n = Math.ceil(t * this._options.fps), r = Math.round(1e3 / this._options.fps), i = await this._createWorkerBlobUrl(), a = new qP.default({
75142
+ let t = (e || this._options.duration || this._getTimelineDuration()) ?? 5, n = Math.ceil(t * this._options.fps), r = Math.round(1e3 / this._options.fps), i = await this._createWorkerBlobUrl(), a = new $P.default({
75015
75143
  workers: this._options.workers,
75016
75144
  quality: this._options.quality,
75017
75145
  width: this._options.width,
@@ -75070,15 +75198,15 @@ var GP = /* @__PURE__ */ r(((e, t) => {
75070
75198
  e.download(r, t);
75071
75199
  }
75072
75200
  };
75073
- function YP(e, t) {
75074
- return new JP(e, t);
75201
+ function tF(e, t) {
75202
+ return new eF(e, t);
75075
75203
  }
75076
75204
  //#endregion
75077
75205
  //#region src/export/VideoExporter.ts
75078
- var XP = /* @__PURE__ */ t({
75079
- VideoExporter: () => ZP,
75080
- createVideoExporter: () => QP
75081
- }), ZP = class e {
75206
+ var nF = /* @__PURE__ */ t({
75207
+ VideoExporter: () => rF,
75208
+ createVideoExporter: () => iF
75209
+ }), rF = class e {
75082
75210
  _scene;
75083
75211
  _options;
75084
75212
  _mediaRecorder = null;
@@ -75170,26 +75298,26 @@ var XP = /* @__PURE__ */ t({
75170
75298
  return { ...this._options };
75171
75299
  }
75172
75300
  };
75173
- function QP(e, t) {
75174
- return new ZP(e, t);
75301
+ function iF(e, t) {
75302
+ return new rF(e, t);
75175
75303
  }
75176
75304
  //#endregion
75177
75305
  //#region src/export/alphaBackground.ts
75178
- var $P = "Transparent export needs a WebGL context created with an alpha channel. Create the Scene with { alpha: true } (or backgroundOpacity < 1) so the canvas carries a real alpha channel to export.", eF = "Transparent export needs access to the WebGL renderer, but the scene did not expose one.";
75179
- function tF(e) {
75306
+ var aF = "Transparent export needs a WebGL context created with an alpha channel. Create the Scene with { alpha: true } (or backgroundOpacity < 1) so the canvas carries a real alpha channel to export.", oF = "Transparent export needs access to the WebGL renderer, but the scene did not expose one.";
75307
+ function sF(e) {
75180
75308
  let t = e.renderer;
75181
75309
  return !t || typeof t.getThreeRenderer != "function" ? null : t.getThreeRenderer() ?? null;
75182
75310
  }
75183
- function nF(e) {
75311
+ function cF(e) {
75184
75312
  return e.getContext().getContextAttributes()?.alpha === !0;
75185
75313
  }
75186
- function rF(e) {
75187
- let t = tF(e);
75188
- if (!t) throw Error(eF);
75189
- if (!nF(t)) throw Error($P);
75314
+ function lF(e) {
75315
+ let t = sF(e);
75316
+ if (!t) throw Error(oF);
75317
+ if (!cF(t)) throw Error(aF);
75190
75318
  return t;
75191
75319
  }
75192
- async function iF(e, t) {
75320
+ async function uF(e, t) {
75193
75321
  let n = e.getClearAlpha();
75194
75322
  e.setClearAlpha(0);
75195
75323
  try {
@@ -75200,7 +75328,7 @@ async function iF(e, t) {
75200
75328
  }
75201
75329
  //#endregion
75202
75330
  //#region src/export/FrameExporter.ts
75203
- function aF(e, t, n) {
75331
+ function dF(e, t, n) {
75204
75332
  return new Promise((r, i) => {
75205
75333
  if (typeof e.toBlob == "function") {
75206
75334
  e.toBlob((e) => {
@@ -75209,22 +75337,22 @@ function aF(e, t, n) {
75209
75337
  return;
75210
75338
  }
75211
75339
  try {
75212
- r(oF(e.toDataURL(t, n)));
75340
+ r(fF(e.toDataURL(t, n)));
75213
75341
  } catch (e) {
75214
75342
  i(e instanceof Error ? e : Error(String(e)));
75215
75343
  }
75216
75344
  });
75217
75345
  }
75218
- function oF(e) {
75346
+ function fF(e) {
75219
75347
  let [t, n] = e.split(","), r = t.match(/data:([^;]+)/), i = r ? r[1] : "image/png", a = atob(n), o = new Uint8Array(a.length);
75220
75348
  for (let e = 0; e < a.length; e++) o[e] = a.charCodeAt(e);
75221
75349
  return new Blob([o], { type: i });
75222
75350
  }
75223
- async function sF(e, t) {
75351
+ async function pF(e, t) {
75224
75352
  let n = t?.type ?? "image/png";
75225
- return t?.transparent ? iF(rF(e), () => (cF(e, t?.time), aF(e.getCanvas(), n, t?.quality))) : (t?.time !== void 0 && e.seek(t.time), aF(e.getCanvas(), n, t?.quality));
75353
+ return t?.transparent ? uF(lF(e), () => (mF(e, t?.time), dF(e.getCanvas(), n, t?.quality))) : (t?.time !== void 0 && e.seek(t.time), dF(e.getCanvas(), n, t?.quality));
75226
75354
  }
75227
- function cF(e, t) {
75355
+ function mF(e, t) {
75228
75356
  if (t !== void 0) {
75229
75357
  e.seek(t);
75230
75358
  return;
@@ -75235,29 +75363,29 @@ function cF(e, t) {
75235
75363
  }
75236
75364
  throw Error("Transparent single-frame export needs either a `time` to seek to, or a scene with a render() method, so the frame is re-rendered with a transparent background.");
75237
75365
  }
75238
- async function lF(e, t) {
75366
+ async function hF(e, t) {
75239
75367
  let n = t.fps, r = t.from ?? 0, i = t.to ?? e.getTimelineDuration() ?? 5, a = t.type ?? "image/png", o = t.onProgress ?? (() => {}), s = Math.max(0, i - r), c = Math.ceil(s * n), l = 1 / n, u = async () => {
75240
75368
  let n = [];
75241
75369
  for (let i = 0; i < c; i++) {
75242
75370
  let s = r + i * l;
75243
75371
  e.seek(s);
75244
75372
  let u = e.getCanvas();
75245
- n.push(await aF(u, a, t.quality)), o((i + 1) / c);
75373
+ n.push(await dF(u, a, t.quality)), o((i + 1) / c);
75246
75374
  }
75247
75375
  return n;
75248
75376
  };
75249
- return t.transparent ? iF(rF(e), u) : u();
75377
+ return t.transparent ? uF(lF(e), u) : u();
75250
75378
  }
75251
- function uF(e, t) {
75379
+ function gF(e, t) {
75252
75380
  let n = URL.createObjectURL(e), r = document.createElement("a");
75253
75381
  r.href = n, r.download = t, document.body.appendChild(r), r.click(), document.body.removeChild(r), URL.revokeObjectURL(n);
75254
75382
  }
75255
- async function dF(e, t = "frame.png", n) {
75256
- uF(await sF(e, n), t);
75383
+ async function _F(e, t = "frame.png", n) {
75384
+ gF(await pF(e, n), t);
75257
75385
  }
75258
75386
  //#endregion
75259
75387
  //#region src/export/WebCodecsExporter.ts
75260
- var fF = {
75388
+ var vF = {
75261
75389
  avc: {
75262
75390
  encoderCodec: "avc1.42001f",
75263
75391
  mp4Codec: "avc",
@@ -75278,7 +75406,7 @@ var fF = {
75278
75406
  mp4Codec: "av1",
75279
75407
  webmCodec: "V_AV1"
75280
75408
  }
75281
- }, pF = class e {
75409
+ }, yF = class e {
75282
75410
  _scene;
75283
75411
  _options;
75284
75412
  constructor(e, t) {
@@ -75302,8 +75430,8 @@ var fF = {
75302
75430
  }
75303
75431
  async export() {
75304
75432
  if (!e.isSupported()) throw Error("WebCodecs VideoEncoder is not available in this environment. Use VideoExporter (MediaRecorder) instead to export video.");
75305
- let t = this._options, n = t.duration || this._scene.getTimelineDuration() || 5, r = Math.ceil(n * t.fps), a = fF[t.codec], o = null;
75306
- t.alpha && (this._assertAlphaCodec(), o = rF(this._scene), await this._assertAlphaEncodeSupport(a));
75433
+ let t = this._options, n = t.duration || this._scene.getTimelineDuration() || 5, r = Math.ceil(n * t.fps), a = vF[t.codec], o = null;
75434
+ t.alpha && (this._assertAlphaCodec(), o = lF(this._scene), await this._assertAlphaEncodeSupport(a));
75307
75435
  let s = await this._createMuxer(a), c = new window.VideoEncoder({
75308
75436
  output: (e, t) => s.addVideoChunk(e, t),
75309
75437
  error: (e) => i.error("WebCodecs encoder error:", e)
@@ -75327,7 +75455,7 @@ var fF = {
75327
75455
  c.encode(i, { keyFrame: e % t.keyFrameInterval === 0 }), i.close(), t.onProgress(r === 0 ? 1 : (e + 1) / r);
75328
75456
  }
75329
75457
  };
75330
- return o ? await iF(o, f) : f(), await c.flush(), c.close(), s.finalize();
75458
+ return o ? await uF(o, f) : f(), await c.flush(), c.close(), s.finalize();
75331
75459
  }
75332
75460
  _assertAlphaCodec() {
75333
75461
  let e = this._options;
@@ -75383,30 +75511,30 @@ var fF = {
75383
75511
  return { ...this._options };
75384
75512
  }
75385
75513
  };
75386
- function mF(e, t) {
75387
- return new pF(e, t);
75514
+ function bF(e, t) {
75515
+ return new yF(e, t);
75388
75516
  }
75389
75517
  //#endregion
75390
75518
  //#region src/export/chooseExporter.ts
75391
- function hF(e = pF.isSupported()) {
75519
+ function xF(e = yF.isSupported()) {
75392
75520
  return e ? "webcodecs" : "mediarecorder";
75393
75521
  }
75394
75522
  //#endregion
75395
75523
  //#region src/export/SvgExporter.ts
75396
- var gF = 3;
75397
- function _F(e, t) {
75524
+ var SF = 3;
75525
+ function CF(e, t) {
75398
75526
  if (!Number.isFinite(e)) return "0";
75399
75527
  let n = Number(e.toFixed(t));
75400
75528
  return String(Object.is(n, -0) ? 0 : n);
75401
75529
  }
75402
- function vF(e) {
75530
+ function wF(e) {
75403
75531
  return e.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;");
75404
75532
  }
75405
- function yF(e, t, n) {
75533
+ function TF(e, t, n) {
75406
75534
  let r = e.position.x, i = e.position.y, a = e.frameWidth || 1, o = e.frameHeight || 1;
75407
75535
  return (e) => [(e[0] - r) / a * t + t / 2, n / 2 - (e[1] - i) / o * n];
75408
75536
  }
75409
- function bF(e, t) {
75537
+ function EF(e, t) {
75410
75538
  if (!t || t.length <= 1) return [e];
75411
75539
  let n = [], r = 0;
75412
75540
  for (let i of t) {
@@ -75415,11 +75543,11 @@ function bF(e, t) {
75415
75543
  }
75416
75544
  return r === e.length ? n : [e];
75417
75545
  }
75418
- function xF(e, t, n) {
75546
+ function DF(e, t, n) {
75419
75547
  if (e.length < 4) return null;
75420
75548
  let r = (e) => {
75421
75549
  let [r, i] = t(e);
75422
- return `${_F(r, n)} ${_F(i, n)}`;
75550
+ return `${CF(r, n)} ${CF(i, n)}`;
75423
75551
  }, i = [`M ${r(e[0])}`], a = Math.floor((e.length - 1) / 3);
75424
75552
  for (let t = 0; t < a; t++) {
75425
75553
  let n = e[3 * t + 1], a = e[3 * t + 2], o = e[3 * t + 3];
@@ -75427,65 +75555,65 @@ function xF(e, t, n) {
75427
75555
  }
75428
75556
  return Xi(e) && i.push("Z"), i.join(" ");
75429
75557
  }
75430
- function SF(e) {
75558
+ function OF(e) {
75431
75559
  return e.style.fillColor ?? e.color;
75432
75560
  }
75433
- function CF(e, t, n, r) {
75561
+ function kF(e, t, n, r) {
75434
75562
  let i = e.getPoints();
75435
75563
  if (i.length < 4) return null;
75436
- let a = bF(i, e.getEffectiveSubpathLengths()), o = [];
75564
+ let a = EF(i, e.getEffectiveSubpathLengths()), o = [];
75437
75565
  for (let e of a) {
75438
- let n = xF(e, t, r);
75566
+ let n = DF(e, t, r);
75439
75567
  n && o.push(n);
75440
75568
  }
75441
75569
  if (o.length === 0) return null;
75442
75570
  let s = e.fillOpacity > 0, c = e.strokeWidth > 0;
75443
75571
  if (!s && !c) return null;
75444
75572
  let l = [`d="${o.join(" ")}"`];
75445
- return s ? (l.push(`fill="${vF(SF(e))}"`), l.push("fill-rule=\"nonzero\""), e.fillOpacity < 1 && l.push(`fill-opacity="${_F(e.fillOpacity, r)}"`)) : l.push("fill=\"none\""), c && (l.push(`stroke="${vF(e.color)}"`), l.push(`stroke-width="${_F(e.strokeWidth * n, r)}"`), l.push("stroke-linejoin=\"round\""), l.push("stroke-linecap=\"round\""), e.opacity < 1 && l.push(`stroke-opacity="${_F(e.opacity, r)}"`)), `<path ${l.join(" ")} />`;
75573
+ return s ? (l.push(`fill="${wF(OF(e))}"`), l.push("fill-rule=\"nonzero\""), e.fillOpacity < 1 && l.push(`fill-opacity="${CF(e.fillOpacity, r)}"`)) : l.push("fill=\"none\""), c && (l.push(`stroke="${wF(e.color)}"`), l.push(`stroke-width="${CF(e.strokeWidth * n, r)}"`), l.push("stroke-linejoin=\"round\""), l.push("stroke-linecap=\"round\""), e.opacity < 1 && l.push(`stroke-opacity="${CF(e.opacity, r)}"`)), `<path ${l.join(" ")} />`;
75446
75574
  }
75447
- function wF(e) {
75575
+ function AF(e) {
75448
75576
  return e instanceof I && e.getPoints().length >= 4;
75449
75577
  }
75450
- function TF(e, t) {
75451
- let n = t?.precision ?? gF, r = e.getWidth(), i = e.getHeight(), a = e.camera, o = yF(a, r, i), s = .01 * r / (a.frameWidth || 1), c = [];
75578
+ function jF(e, t) {
75579
+ let n = t?.precision ?? SF, r = e.getWidth(), i = e.getHeight(), a = e.camera, o = TF(a, r, i), s = .01 * r / (a.frameWidth || 1), c = [];
75452
75580
  for (let t of e.mobjects) {
75453
75581
  let e = [];
75454
75582
  for (let r of t.getFamily()) {
75455
- if (!wF(r)) continue;
75456
- let t = CF(r, o, s, n);
75583
+ if (!AF(r)) continue;
75584
+ let t = kF(r, o, s, n);
75457
75585
  t && e.push(t);
75458
75586
  }
75459
75587
  if (e.length === 0) continue;
75460
- let r = t.userId ? ` data-mobject-id="${vF(t.userId)}"` : "";
75588
+ let r = t.userId ? ` data-mobject-id="${wF(t.userId)}"` : "";
75461
75589
  c.push(` <g${r}>\n ${e.join("\n ")}\n </g>`);
75462
75590
  }
75463
- let l = _F(r, n), u = _F(i, n);
75464
- return `${`<svg xmlns="http://www.w3.org/2000/svg" width="${l}" height="${u}" viewBox="0 0 ${l} ${u}">`}${t?.background ? `\n <rect x="0" y="0" width="${l}" height="${u}" fill="${vF(t.background)}" />` : ""}${c.length > 0 ? `\n${c.join("\n")}\n` : "\n"}</svg>`;
75591
+ let l = CF(r, n), u = CF(i, n);
75592
+ return `${`<svg xmlns="http://www.w3.org/2000/svg" width="${l}" height="${u}" viewBox="0 0 ${l} ${u}">`}${t?.background ? `\n <rect x="0" y="0" width="${l}" height="${u}" fill="${wF(t.background)}" />` : ""}${c.length > 0 ? `\n${c.join("\n")}\n` : "\n"}</svg>`;
75465
75593
  }
75466
- function EF(e, t) {
75467
- let n = TF(e, t);
75594
+ function MF(e, t) {
75595
+ let n = jF(e, t);
75468
75596
  return new Blob([n], { type: "image/svg+xml" });
75469
75597
  }
75470
- function DF(e, t = "scene.svg", n) {
75598
+ function NF(e, t = "scene.svg", n) {
75471
75599
  if (typeof document > "u") throw Error("exportAndDownloadSVG requires a DOM (document is undefined)");
75472
- uF(EF(e, n), t);
75600
+ gF(MF(e, n), t);
75473
75601
  }
75474
75602
  //#endregion
75475
75603
  //#region src/export/SlideDeckExporter.ts
75476
- var OF = "PNG";
75477
- function kF(e, t) {
75604
+ var PF = "PNG";
75605
+ function FF(e, t) {
75478
75606
  return e.seek(t), {
75479
75607
  dataUrl: e.getCanvas().toDataURL("image/png"),
75480
75608
  width: e.getWidth(),
75481
75609
  height: e.getHeight()
75482
75610
  };
75483
75611
  }
75484
- async function AF(e) {
75612
+ async function IF(e) {
75485
75613
  let { jsPDF: t } = await import("./jspdf.es.min-CvMJL6nS.js");
75486
75614
  return new t(e);
75487
75615
  }
75488
- function jF(e, t, n, r) {
75616
+ function LF(e, t, n, r) {
75489
75617
  let i = e > 0 ? e : 1, a = t > 0 ? t : 1, o = Math.min(n / i, r / a), s = i * o, c = a * o;
75490
75618
  return {
75491
75619
  x: (n - s) / 2,
@@ -75494,33 +75622,33 @@ function jF(e, t, n, r) {
75494
75622
  h: c
75495
75623
  };
75496
75624
  }
75497
- function MF(e, t) {
75625
+ function RF(e, t) {
75498
75626
  return t === "first" ? e.startTime : e.endTime;
75499
75627
  }
75500
- async function NF(e, t) {
75628
+ async function zF(e, t) {
75501
75629
  let n = e.timeline.getSlides();
75502
75630
  if (n.length === 0) return null;
75503
- let r = t?.still ?? "last", i = t?.orientation ?? "landscape", a = t?.pageSize ?? "a4", o = t?.unit ?? "pt", s = t?.imageFormat ?? OF, c = t?.background, l = t?.captureSlide ?? kF, u = t?.pdfFactory ?? AF, d = t?.onProgress ?? (() => {}), f = await u({
75631
+ let r = t?.still ?? "last", i = t?.orientation ?? "landscape", a = t?.pageSize ?? "a4", o = t?.unit ?? "pt", s = t?.imageFormat ?? PF, c = t?.background, l = t?.captureSlide ?? FF, u = t?.pdfFactory ?? IF, d = t?.onProgress ?? (() => {}), f = await u({
75504
75632
  orientation: i,
75505
75633
  unit: o,
75506
75634
  format: a
75507
75635
  }), p = f.internal.pageSize.getWidth(), m = f.internal.pageSize.getHeight();
75508
75636
  for (let t = 0; t < n.length; t++) {
75509
75637
  t > 0 && f.addPage(a, i), c && (f.setFillColor(c[0], c[1], c[2]), f.rect(0, 0, p, m, "F"));
75510
- let o = await l(e.scene, MF(n[t], r)), u = jF(o.width, o.height, p, m);
75638
+ let o = await l(e.scene, RF(n[t], r)), u = LF(o.width, o.height, p, m);
75511
75639
  f.addImage(o.dataUrl, s, u.x, u.y, u.w, u.h), d((t + 1) / n.length);
75512
75640
  }
75513
75641
  return f.output("blob");
75514
75642
  }
75515
- async function PF(e, t = "slides.pdf", n) {
75643
+ async function BF(e, t = "slides.pdf", n) {
75516
75644
  if (typeof document > "u") {
75517
75645
  i.warn("exportAndDownloadSlidesToPDF: no DOM available, skipping download.");
75518
75646
  return;
75519
75647
  }
75520
- let r = await NF(e, n);
75521
- r && uF(r, t);
75648
+ let r = await zF(e, n);
75649
+ r && gF(r, t);
75522
75650
  }
75523
- async function FF() {
75651
+ async function VF() {
75524
75652
  let e;
75525
75653
  try {
75526
75654
  e = await import(
@@ -75532,14 +75660,14 @@ async function FF() {
75532
75660
  }
75533
75661
  return new (e.default ?? e)();
75534
75662
  }
75535
- async function IF(e, t) {
75663
+ async function HF(e, t) {
75536
75664
  let n = e.timeline.getSlides();
75537
75665
  if (n.length === 0) return null;
75538
- let r = t?.still ?? "last", i = t?.slideWidth ?? 13.333, a = t?.slideHeight ?? 7.5, o = t?.background, s = t?.captureSlide ?? kF, c = t?.pptxFactory ?? FF, l = t?.onProgress ?? (() => {}), u = await c();
75666
+ let r = t?.still ?? "last", i = t?.slideWidth ?? 13.333, a = t?.slideHeight ?? 7.5, o = t?.background, s = t?.captureSlide ?? FF, c = t?.pptxFactory ?? VF, l = t?.onProgress ?? (() => {}), u = await c();
75539
75667
  for (let t = 0; t < n.length; t++) {
75540
75668
  let c = u.addSlide();
75541
75669
  o && (c.background = { color: o });
75542
- let d = await s(e.scene, MF(n[t], r));
75670
+ let d = await s(e.scene, RF(n[t], r));
75543
75671
  c.addImage({
75544
75672
  data: d.dataUrl,
75545
75673
  x: 0,
@@ -75557,7 +75685,7 @@ async function IF(e, t) {
75557
75685
  }
75558
75686
  //#endregion
75559
75687
  //#region src/player/ExportSettingsUI.ts
75560
- var LF = [
75688
+ var UF = [
75561
75689
  {
75562
75690
  id: "current",
75563
75691
  label: "Current",
@@ -75594,11 +75722,11 @@ var LF = [
75594
75722
  width: 3840,
75595
75723
  height: 2160
75596
75724
  }
75597
- ], RF = [
75725
+ ], WF = [
75598
75726
  24,
75599
75727
  30,
75600
75728
  60
75601
- ], zF = [
75729
+ ], GF = [
75602
75730
  {
75603
75731
  id: "low",
75604
75732
  label: "Low",
@@ -75614,12 +75742,12 @@ var LF = [
75614
75742
  label: "High",
75615
75743
  value: .9
75616
75744
  }
75617
- ], BF = 1e7;
75618
- function VF(e) {
75619
- return Math.round(Math.max(0, Math.min(1, e)) * BF);
75745
+ ], KF = 1e7;
75746
+ function qF(e) {
75747
+ return Math.round(Math.max(0, Math.min(1, e)) * KF);
75620
75748
  }
75621
- function HF(e, t, n) {
75622
- let r = LF.find((t) => t.id === e);
75749
+ function JF(e, t, n) {
75750
+ let r = UF.find((t) => t.id === e);
75623
75751
  return !r || r.width === null || r.height === null ? {
75624
75752
  width: t,
75625
75753
  height: n
@@ -75628,7 +75756,7 @@ function HF(e, t, n) {
75628
75756
  height: r.height
75629
75757
  };
75630
75758
  }
75631
- var UF = class {
75759
+ var YF = class {
75632
75760
  _element;
75633
75761
  _fpsSelect;
75634
75762
  _resolutionSelect;
@@ -75641,22 +75769,22 @@ var UF = class {
75641
75769
  display: "flex",
75642
75770
  flexDirection: "column",
75643
75771
  gap: "6px"
75644
- }), this._element.setAttribute("data-export-settings", ""), this._fpsSelect = this._buildSelect("FPS", RF.map((e) => ({
75772
+ }), this._element.setAttribute("data-export-settings", ""), this._fpsSelect = this._buildSelect("FPS", WF.map((e) => ({
75645
75773
  value: String(e),
75646
75774
  label: `${e} fps`
75647
- })), String(this._nearestFps(e.fps))), this._resolutionSelect = this._buildSelect("Resolution", LF.map((e) => ({
75775
+ })), String(this._nearestFps(e.fps))), this._resolutionSelect = this._buildSelect("Resolution", UF.map((e) => ({
75648
75776
  value: e.id,
75649
75777
  label: e.label
75650
- })), "current"), this._qualitySelect = this._buildSelect("Quality", zF.map((e) => ({
75778
+ })), "current"), this._qualitySelect = this._buildSelect("Quality", GF.map((e) => ({
75651
75779
  value: String(e.value),
75652
75780
  label: e.label
75653
- })), String(zF[zF.length - 1].value));
75781
+ })), String(GF[GF.length - 1].value));
75654
75782
  }
75655
75783
  get element() {
75656
75784
  return this._element;
75657
75785
  }
75658
75786
  getSettings() {
75659
- let e = parseInt(this._fpsSelect.value, 10), { width: t, height: n } = HF(this._resolutionSelect.value, this._defaults.width, this._defaults.height);
75787
+ let e = parseInt(this._fpsSelect.value, 10), { width: t, height: n } = JF(this._resolutionSelect.value, this._defaults.width, this._defaults.height);
75660
75788
  return {
75661
75789
  fps: e,
75662
75790
  width: t,
@@ -75665,7 +75793,7 @@ var UF = class {
75665
75793
  };
75666
75794
  }
75667
75795
  _nearestFps(e) {
75668
- return RF.reduce((t, n) => Math.abs(n - e) < Math.abs(t - e) ? n : t);
75796
+ return WF.reduce((t, n) => Math.abs(n - e) < Math.abs(t - e) ? n : t);
75669
75797
  }
75670
75798
  _buildSelect(e, t, n) {
75671
75799
  let r = document.createElement("label");
@@ -75696,7 +75824,7 @@ var UF = class {
75696
75824
  }
75697
75825
  return a.value = n, a.addEventListener("click", (e) => e.stopPropagation()), r.appendChild(i), r.appendChild(a), this._element.appendChild(r), a;
75698
75826
  }
75699
- }, WF = class {
75827
+ }, XF = class {
75700
75828
  _container;
75701
75829
  _bar;
75702
75830
  _playBtn;
@@ -75732,19 +75860,19 @@ var UF = class {
75732
75860
  this._container = e, this._callbacks = t, this._autoHideMs = n.autoHideMs ?? 2500, this._exportControls = n.exportControls ?? !1, getComputedStyle(e).position === "static" && (e.style.position = "relative"), e.style.overflow = "hidden", this._bar = this._createBar(), this._playBtn = this._createPlayBtn(), this._prevBtn = this._createNavBtn("prev"), this._nextBtn = this._createNavBtn("next");
75733
75861
  let r = this._createProgressBar();
75734
75862
  this._progressWrap = r.wrap, this._progressFill = r.fill, this._segmentMarkers = r.markers, this._timeDisplay = this._createTimeDisplay(), this._speedSelect = this._createSpeedSelect(), this._fullscreenBtn = this._createFullscreenBtn(), this._slidesBtn = this._createSlidesBtn(), this._exportBtn = this._createExportBtn();
75735
- let i = GF("div", {
75863
+ let i = ZF("div", {
75736
75864
  display: "flex",
75737
75865
  alignItems: "center",
75738
75866
  gap: "4px"
75739
75867
  });
75740
75868
  i.appendChild(this._prevBtn), i.appendChild(this._playBtn), i.appendChild(this._nextBtn);
75741
- let a = GF("div", {
75869
+ let a = ZF("div", {
75742
75870
  display: "flex",
75743
75871
  alignItems: "center",
75744
75872
  gap: "8px"
75745
75873
  });
75746
75874
  a.appendChild(this._timeDisplay), a.appendChild(this._speedSelect), a.appendChild(this._slidesBtn), a.appendChild(this._exportBtnWrapper), a.appendChild(this._fullscreenBtn), this._bar.appendChild(this._progressWrap);
75747
- let o = GF("div", {
75875
+ let o = ZF("div", {
75748
75876
  display: "flex",
75749
75877
  alignItems: "center",
75750
75878
  justifyContent: "space-between",
@@ -75759,10 +75887,10 @@ var UF = class {
75759
75887
  let n = e / t * 100;
75760
75888
  this._progressFill.style.width = `${n}%`;
75761
75889
  }
75762
- this._timeDisplay.textContent = `${qF(e)} / ${qF(t)}`;
75890
+ this._timeDisplay.textContent = `${$F(e)} / ${$F(t)}`;
75763
75891
  }
75764
75892
  setPlaying(e, t = !1) {
75765
- this._isPlaying = e, t ? (this._playBtn.innerHTML = XF, this._playBtn.title = "Replay (Space)") : (this._playBtn.innerHTML = e ? YF : JF, this._playBtn.title = e ? "Pause (Space)" : "Play (Space)"), e && this._scheduleHide();
75893
+ this._isPlaying = e, t ? (this._playBtn.innerHTML = nI, this._playBtn.title = "Replay (Space)") : (this._playBtn.innerHTML = e ? tI : eI, this._playBtn.title = e ? "Pause (Space)" : "Play (Space)"), e && this._scheduleHide();
75766
75894
  }
75767
75895
  setSlidesMode(e) {
75768
75896
  this._slidesActive = e, this._slidesBtn.style.opacity = e ? "1" : "0.4", this._slidesBtn.style.background = e ? "rgba(74,158,255,0.25)" : "none", this._slidesBtn.title = `Slides mode ${e ? "on" : "off"} (S)`;
@@ -75772,7 +75900,7 @@ var UF = class {
75772
75900
  let t = e.getSlides(), n = e.getDuration();
75773
75901
  if (!(n <= 0)) for (let e of t) {
75774
75902
  if (e.index === 0) continue;
75775
- let t = GF("div", {
75903
+ let t = ZF("div", {
75776
75904
  position: "absolute",
75777
75905
  left: `${e.startTime / n * 100}%`,
75778
75906
  top: "50%",
@@ -75787,7 +75915,7 @@ var UF = class {
75787
75915
  }
75788
75916
  }
75789
75917
  _createBar() {
75790
- let e = GF("div", {
75918
+ let e = ZF("div", {
75791
75919
  position: "absolute",
75792
75920
  bottom: "0",
75793
75921
  left: "0",
@@ -75805,21 +75933,21 @@ var UF = class {
75805
75933
  }
75806
75934
  _createPlayBtn() {
75807
75935
  let e = document.createElement("button");
75808
- return e.innerHTML = JF, e.title = "Play (Space)", KF(e, "36px", "36px"), e.addEventListener("click", () => this._callbacks.onPlayPause()), e;
75936
+ return e.innerHTML = eI, e.title = "Play (Space)", QF(e, "36px", "36px"), e.addEventListener("click", () => this._callbacks.onPlayPause()), e;
75809
75937
  }
75810
75938
  _createNavBtn(e) {
75811
75939
  let t = document.createElement("button");
75812
- return t.innerHTML = e === "prev" ? ZF : QF, t.title = e === "prev" ? "Previous (Left arrow)" : "Next (Right arrow)", KF(t, "28px", "28px"), t.addEventListener("click", () => {
75940
+ return t.innerHTML = e === "prev" ? rI : iI, t.title = e === "prev" ? "Previous (Left arrow)" : "Next (Right arrow)", QF(t, "28px", "28px"), t.addEventListener("click", () => {
75813
75941
  e === "prev" ? this._callbacks.onPrev() : this._callbacks.onNext();
75814
75942
  }), t;
75815
75943
  }
75816
75944
  _createProgressBar() {
75817
- let e = GF("div", {
75945
+ let e = ZF("div", {
75818
75946
  position: "relative",
75819
75947
  height: "16px",
75820
75948
  padding: "6px 12px",
75821
75949
  cursor: "pointer"
75822
- }), t = GF("div", {
75950
+ }), t = ZF("div", {
75823
75951
  position: "absolute",
75824
75952
  left: "12px",
75825
75953
  right: "12px",
@@ -75829,14 +75957,14 @@ var UF = class {
75829
75957
  background: "rgba(255,255,255,0.2)",
75830
75958
  borderRadius: "2px",
75831
75959
  overflow: "visible"
75832
- }), n = GF("div", {
75960
+ }), n = ZF("div", {
75833
75961
  width: "0%",
75834
75962
  height: "100%",
75835
75963
  background: "#4a9eff",
75836
75964
  borderRadius: "2px",
75837
75965
  transition: "none",
75838
75966
  position: "relative"
75839
- }), r = GF("div", {
75967
+ }), r = ZF("div", {
75840
75968
  position: "absolute",
75841
75969
  right: "-5px",
75842
75970
  top: "50%",
@@ -75849,7 +75977,7 @@ var UF = class {
75849
75977
  transition: "transform 0.1s"
75850
75978
  });
75851
75979
  n.appendChild(r);
75852
- let i = GF("div", {
75980
+ let i = ZF("div", {
75853
75981
  width: "0%",
75854
75982
  height: "100%",
75855
75983
  background: "rgba(255,255,255,0.1)",
@@ -75858,7 +75986,7 @@ var UF = class {
75858
75986
  top: "0",
75859
75987
  left: "0",
75860
75988
  pointerEvents: "none"
75861
- }), a = GF("div", {
75989
+ }), a = ZF("div", {
75862
75990
  position: "absolute",
75863
75991
  top: "0",
75864
75992
  left: "0",
@@ -75883,7 +76011,7 @@ var UF = class {
75883
76011
  };
75884
76012
  }
75885
76013
  _createTimeDisplay() {
75886
- let e = GF("span", {
76014
+ let e = ZF("span", {
75887
76015
  fontFamily: "\"SF Mono\", Monaco, Consolas, monospace",
75888
76016
  fontSize: "12px",
75889
76017
  opacity: "0.8",
@@ -75925,16 +76053,16 @@ var UF = class {
75925
76053
  }), e;
75926
76054
  }
75927
76055
  _createExportBtn() {
75928
- let e = GF("div", {
76056
+ let e = ZF("div", {
75929
76057
  position: "relative",
75930
76058
  display: "inline-block"
75931
76059
  }), t = document.createElement("button");
75932
- return t.innerHTML = $F, t.title = "Export animation", KF(t, "28px", "28px"), t.addEventListener("click", (e) => {
76060
+ return t.innerHTML = aI, t.title = "Export animation", QF(t, "28px", "28px"), t.addEventListener("click", (e) => {
75933
76061
  e.stopPropagation(), this._exportMenu ? this._closeExportMenu() : this._showExportMenu();
75934
76062
  }), e.appendChild(t), this._exportBtnWrapper = e, t;
75935
76063
  }
75936
76064
  _showExportMenu() {
75937
- let e = this._exportBtn.getBoundingClientRect(), t = GF("div", {
76065
+ let e = this._exportBtn.getBoundingClientRect(), t = ZF("div", {
75938
76066
  position: "fixed",
75939
76067
  top: "0",
75940
76068
  left: "0",
@@ -75945,7 +76073,7 @@ var UF = class {
75945
76073
  t.setAttribute("data-player-bar", ""), t.addEventListener("mousedown", (e) => {
75946
76074
  e.stopPropagation(), e.preventDefault(), this._closeExportMenu();
75947
76075
  });
75948
- let n = GF("div", {
76076
+ let n = ZF("div", {
75949
76077
  position: "fixed",
75950
76078
  bottom: `${window.innerHeight - e.top + 6}px`,
75951
76079
  left: `${e.left - 60}px`,
@@ -75966,7 +76094,7 @@ var UF = class {
75966
76094
  height: 1080,
75967
76095
  fps: 60
75968
76096
  };
75969
- this._exportPanel = new UF(e), n.appendChild(this._exportPanel.element);
76097
+ this._exportPanel = new YF(e), n.appendChild(this._exportPanel.element);
75970
76098
  }
75971
76099
  for (let e of [
75972
76100
  {
@@ -75985,7 +76113,7 @@ var UF = class {
75985
76113
  desc: "Video file"
75986
76114
  }
75987
76115
  ]) {
75988
- let t = GF("div", {
76116
+ let t = ZF("div", {
75989
76117
  padding: "8px 14px",
75990
76118
  cursor: "pointer",
75991
76119
  fontSize: "13px",
@@ -76010,7 +76138,7 @@ var UF = class {
76010
76138
  this._exportMenu && (this._exportMenuBackdrop?.remove(), this._exportMenuBackdrop = null, this._exportMenu.remove(), this._exportMenu = null, this._exportPanel = null);
76011
76139
  }
76012
76140
  setExportProgress(e) {
76013
- if (e === null) this._exportBtn.innerHTML = $F, this._exportBtn.disabled = !1, this._exportBtn.title = "Export animation";
76141
+ if (e === null) this._exportBtn.innerHTML = aI, this._exportBtn.disabled = !1, this._exportBtn.title = "Export animation";
76014
76142
  else {
76015
76143
  let t = Math.round(e * 100);
76016
76144
  this._exportBtn.innerHTML = `<span style="font-size:10px;font-weight:600">${t}%</span>`, this._exportBtn.disabled = !0, this._exportBtn.title = `Exporting... ${t}%`;
@@ -76018,7 +76146,7 @@ var UF = class {
76018
76146
  }
76019
76147
  _createSlidesBtn() {
76020
76148
  let e = document.createElement("button");
76021
- return e.innerHTML = eI, e.title = "Slides mode off (S)", KF(e, "28px", "28px"), e.style.opacity = "0.4", e.addEventListener("click", () => {
76149
+ return e.innerHTML = oI, e.title = "Slides mode off (S)", QF(e, "28px", "28px"), e.style.opacity = "0.4", e.addEventListener("click", () => {
76022
76150
  this._slidesActive = !this._slidesActive, this.setSlidesMode(this._slidesActive), this._callbacks.onSlidesToggle(this._slidesActive);
76023
76151
  }), e.addEventListener("mouseenter", () => {
76024
76152
  e.style.background = this._slidesActive ? "rgba(74,158,255,0.35)" : "rgba(255,255,255,0.15)";
@@ -76028,7 +76156,7 @@ var UF = class {
76028
76156
  }
76029
76157
  _createFullscreenBtn() {
76030
76158
  let e = document.createElement("button");
76031
- return e.innerHTML = tI, e.title = "Fullscreen (F)", KF(e, "28px", "28px"), e.addEventListener("click", () => this._callbacks.onFullscreen()), e;
76159
+ return e.innerHTML = sI, e.title = "Fullscreen (F)", QF(e, "28px", "28px"), e.addEventListener("click", () => this._callbacks.onFullscreen()), e;
76032
76160
  }
76033
76161
  _showControls() {
76034
76162
  this._isVisible ||= (this._bar.style.opacity = "1", this._bar.style.transform = "translateY(0)", !0), this._scheduleHide();
@@ -76083,11 +76211,11 @@ var UF = class {
76083
76211
  this._hideTimeout && clearTimeout(this._hideTimeout), this._container.removeEventListener("mousemove", this._onMouseMove), this._container.removeEventListener("mouseleave", this._onMouseLeave), this._progressWrap.removeEventListener("mousedown", this._onProgressDown), document.removeEventListener("mousemove", this._onProgressMove), document.removeEventListener("mouseup", this._onProgressUp), this._bar.remove();
76084
76212
  }
76085
76213
  };
76086
- function GF(e, t) {
76214
+ function ZF(e, t) {
76087
76215
  let n = document.createElement(e);
76088
76216
  return Object.assign(n.style, t), n;
76089
76217
  }
76090
- function KF(e, t, n) {
76218
+ function QF(e, t, n) {
76091
76219
  Object.assign(e.style, {
76092
76220
  width: t,
76093
76221
  height: n,
@@ -76108,11 +76236,11 @@ function KF(e, t, n) {
76108
76236
  e.style.background = "none";
76109
76237
  });
76110
76238
  }
76111
- function qF(e) {
76239
+ function $F(e) {
76112
76240
  let t = Math.floor(e / 60), n = Math.floor(e % 60);
76113
76241
  return `${t}:${String(n).padStart(2, "0")}`;
76114
76242
  }
76115
- var JF = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentColor\"><path d=\"M5 3l10 6-10 6V3z\"/></svg>", YF = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentColor\"><rect x=\"4\" y=\"3\" width=\"3.5\" height=\"12\" rx=\"0.5\"/><rect x=\"10.5\" y=\"3\" width=\"3.5\" height=\"12\" rx=\"0.5\"/></svg>", XF = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentColor\"><path d=\"M9 3a6 6 0 1 0 6 6h-2a4 4 0 1 1-4-4v3l4-3.5L9 1v2z\"/></svg>", ZF = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"currentColor\"><rect x=\"2\" y=\"3\" width=\"2\" height=\"10\"/><path d=\"M14 3L6 8l8 5V3z\"/></svg>", QF = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"currentColor\"><rect x=\"12\" y=\"3\" width=\"2\" height=\"10\"/><path d=\"M2 3l8 5-8 5V3z\"/></svg>", $F = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"currentColor\"><path d=\"M8 1L8 10M8 10L5 7M8 10L11 7\" stroke=\"currentColor\" stroke-width=\"1.5\" fill=\"none\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/><path d=\"M3 12v1h10v-1\" stroke=\"currentColor\" stroke-width=\"1.5\" fill=\"none\" stroke-linecap=\"round\"/></svg>", eI = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"currentColor\"><rect x=\"1\" y=\"2\" width=\"14\" height=\"10\" rx=\"1.5\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.5\"/><path d=\"M5 14h6\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\"/><path d=\"M6 6l5 3-5 3V6z\"/></svg>", tI = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"currentColor\"><path d=\"M2 2h4v2H4v2H2V2zm8 0h4v4h-2V4h-2V2zM2 10h2v2h2v2H2v-4zm10 2h-2v2h4v-4h-2v2z\"/></svg>", nI = class {
76243
+ var eI = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentColor\"><path d=\"M5 3l10 6-10 6V3z\"/></svg>", tI = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentColor\"><rect x=\"4\" y=\"3\" width=\"3.5\" height=\"12\" rx=\"0.5\"/><rect x=\"10.5\" y=\"3\" width=\"3.5\" height=\"12\" rx=\"0.5\"/></svg>", nI = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentColor\"><path d=\"M9 3a6 6 0 1 0 6 6h-2a4 4 0 1 1-4-4v3l4-3.5L9 1v2z\"/></svg>", rI = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"currentColor\"><rect x=\"2\" y=\"3\" width=\"2\" height=\"10\"/><path d=\"M14 3L6 8l8 5V3z\"/></svg>", iI = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"currentColor\"><rect x=\"12\" y=\"3\" width=\"2\" height=\"10\"/><path d=\"M2 3l8 5-8 5V3z\"/></svg>", aI = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"currentColor\"><path d=\"M8 1L8 10M8 10L5 7M8 10L11 7\" stroke=\"currentColor\" stroke-width=\"1.5\" fill=\"none\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/><path d=\"M3 12v1h10v-1\" stroke=\"currentColor\" stroke-width=\"1.5\" fill=\"none\" stroke-linecap=\"round\"/></svg>", oI = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"currentColor\"><rect x=\"1\" y=\"2\" width=\"14\" height=\"10\" rx=\"1.5\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.5\"/><path d=\"M5 14h6\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\"/><path d=\"M6 6l5 3-5 3V6z\"/></svg>", sI = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"currentColor\"><path d=\"M2 2h4v2H4v2H2V2zm8 0h4v4h-2V4h-2V2zM2 10h2v2h2v2H2v-4zm10 2h-2v2h4v-4h-2v2z\"/></svg>", cI = class {
76116
76244
  _container;
76117
76245
  _callbacks;
76118
76246
  _onKeyDown;
@@ -76142,7 +76270,7 @@ var JF = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
76142
76270
  dispose() {
76143
76271
  this._container.removeEventListener("keydown", this._onKeyDown);
76144
76272
  }
76145
- }, rI = class {
76273
+ }, lI = class {
76146
76274
  _realScene;
76147
76275
  _masterTimeline;
76148
76276
  constructor(e, t) {
@@ -76179,7 +76307,7 @@ var JF = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
76179
76307
  for (let n of e) t.push(n), n instanceof og && t.push(...this._collectAll(n.animations));
76180
76308
  return t;
76181
76309
  }
76182
- }, iI = [
76310
+ }, uI = [
76183
76311
  "mousedown",
76184
76312
  "mousemove",
76185
76313
  "mouseup",
@@ -76187,7 +76315,7 @@ var JF = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
76187
76315
  "touchstart",
76188
76316
  "touchmove",
76189
76317
  "touchend"
76190
- ], aI = class {
76318
+ ], dI = class {
76191
76319
  _target;
76192
76320
  _scene;
76193
76321
  _isIdle;
@@ -76206,13 +76334,13 @@ var JF = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
76206
76334
  }
76207
76335
  attach() {
76208
76336
  if (!this._attached) {
76209
- for (let e of iI) this._target.addEventListener(e, this._onEvent);
76337
+ for (let e of uI) this._target.addEventListener(e, this._onEvent);
76210
76338
  this._attached = !0;
76211
76339
  }
76212
76340
  }
76213
76341
  dispose() {
76214
76342
  if (this._attached) {
76215
- for (let e of iI) this._target.removeEventListener(e, this._onEvent);
76343
+ for (let e of uI) this._target.removeEventListener(e, this._onEvent);
76216
76344
  this._attached = !1, this._renderScheduled = !1;
76217
76345
  }
76218
76346
  }
@@ -76224,7 +76352,7 @@ var JF = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
76224
76352
  this._renderScheduled = !1, !(!this._attached || !this._isIdle()) && (this._scene.render(), this._renderCount++);
76225
76353
  }));
76226
76354
  }
76227
- }, oI = class {
76355
+ }, fI = class {
76228
76356
  _scene;
76229
76357
  _masterTimeline;
76230
76358
  _ui;
@@ -76247,7 +76375,7 @@ var JF = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
76247
76375
  _origHeight = 0;
76248
76376
  _onFullscreenChange;
76249
76377
  constructor(e, t = {}) {
76250
- this._container = e, this._loop = t.loop ?? !1, this._autoPlay = t.autoPlay ?? !1, this._slidesMode = t.slidesMode ?? !1, this._interactiveSlides = t.interactiveSlides ?? !1, this._exportControls = t.exportControls ?? !1, this._exportFps = t.targetFps ?? 60, this._scene = new jg(e, t), this._masterTimeline = new RA(), this._ui = new WF(e, {
76378
+ this._container = e, this._loop = t.loop ?? !1, this._autoPlay = t.autoPlay ?? !1, this._slidesMode = t.slidesMode ?? !1, this._interactiveSlides = t.interactiveSlides ?? !1, this._exportControls = t.exportControls ?? !1, this._exportFps = t.targetFps ?? 60, this._scene = new jg(e, t), this._masterTimeline = new RA(), this._ui = new XF(e, {
76251
76379
  onPlayPause: () => this.togglePlayPause(),
76252
76380
  onSeek: (e) => this.seek(e),
76253
76381
  onPrev: () => this.prevSegment(),
@@ -76264,7 +76392,7 @@ var JF = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
76264
76392
  }, {
76265
76393
  autoHideMs: t.autoHideMs,
76266
76394
  exportControls: this._exportControls
76267
- }), this._ui.setSlidesMode(this._slidesMode), this._ui.enableScrollScrub(() => this._masterTimeline.getCurrentTime()), this._controller = new nI(e, {
76395
+ }), this._ui.setSlidesMode(this._slidesMode), this._ui.enableScrollScrub(() => this._masterTimeline.getCurrentTime()), this._controller = new cI(e, {
76268
76396
  onPlayPause: () => this.togglePlayPause(),
76269
76397
  onPrev: () => this.prevSegment(),
76270
76398
  onNext: () => this.nextSegment(),
@@ -76278,10 +76406,10 @@ var JF = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
76278
76406
  }, document.addEventListener("fullscreenchange", this._onFullscreenChange), this._interactiveSlides && this._enableSlideInteraction();
76279
76407
  }
76280
76408
  _enableSlideInteraction() {
76281
- this._slideInteraction || (this._slideInteraction = new aI(this._container, this._scene, () => !this._isPlaying), this._slideInteraction.attach());
76409
+ this._slideInteraction || (this._slideInteraction = new dI(this._container, this._scene, () => !this._isPlaying), this._slideInteraction.attach());
76282
76410
  }
76283
76411
  async sequence(e) {
76284
- this._masterTimeline = new RA(), this._activeLoopSlideIndex = null, this._slidesTargetSlideIndex = -1, await e(new rI(this._scene, this._masterTimeline)), this._masterTimeline.finalizeSlides(), this._scene.setTimeline(this._masterTimeline), this._masterTimeline.seek(0), this._scene.render(), this._ui.setSegments(this._masterTimeline), this._ui.updateTime(0, this._masterTimeline.getDuration()), this._autoPlay && this.play();
76412
+ this._masterTimeline = new RA(), this._activeLoopSlideIndex = null, this._slidesTargetSlideIndex = -1, await e(new lI(this._scene, this._masterTimeline)), this._masterTimeline.finalizeSlides(), this._scene.setTimeline(this._masterTimeline), this._masterTimeline.seek(0), this._scene.render(), this._ui.setSegments(this._masterTimeline), this._ui.updateTime(0, this._masterTimeline.getDuration()), this._autoPlay && this.play();
76285
76413
  }
76286
76414
  get scene() {
76287
76415
  return this._scene;
@@ -76392,7 +76520,7 @@ var JF = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
76392
76520
  let a = `animation.${e}`, o = this._masterTimeline.getDuration(), s = (e) => this._ui.setExportProgress(e);
76393
76521
  this._ui.setExportProgress(0);
76394
76522
  try {
76395
- (e === "webm" || e === "mp4") && hF() === "webcodecs" ? await this._exportWithWebCodecs(e === "mp4" ? "mp4" : "webm", t, o, s, a) : await this._scene.export(a, this._buildSceneExportOptions(e, t, o, s));
76523
+ (e === "webm" || e === "mp4") && xF() === "webcodecs" ? await this._exportWithWebCodecs(e === "mp4" ? "mp4" : "webm", t, o, s, a) : await this._scene.export(a, this._buildSceneExportOptions(e, t, o, s));
76396
76524
  } catch (e) {
76397
76525
  i.error("Export failed:", e), this._ui.showError(`Export failed: ${e instanceof Error ? e.message : "Unknown error"}`);
76398
76526
  } finally {
@@ -76400,12 +76528,12 @@ var JF = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
76400
76528
  }
76401
76529
  }
76402
76530
  async _exportWithWebCodecs(e, t, n, r, i) {
76403
- uF(await new pF(this._scene, {
76531
+ gF(await new yF(this._scene, {
76404
76532
  format: e,
76405
76533
  fps: t?.fps ?? this._exportFps,
76406
76534
  width: t?.width ?? this._scene.getWidth(),
76407
76535
  height: t?.height ?? this._scene.getHeight(),
76408
- bitrate: VF(t?.quality ?? .9),
76536
+ bitrate: qF(t?.quality ?? .9),
76409
76537
  duration: n,
76410
76538
  onProgress: r
76411
76539
  }).export(), i);
@@ -76466,36 +76594,36 @@ var JF = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
76466
76594
  _stopLoop() {
76467
76595
  this._animFrameId !== null && (cancelAnimationFrame(this._animFrameId), this._animFrameId = null);
76468
76596
  }
76469
- }, sI = {
76597
+ }, pI = {
76470
76598
  EXPERIMENTAL_3D_LIGHTING: !1,
76471
76599
  WEBGPU_RENDERER: !1,
76472
76600
  ADVANCED_TEXT_LAYOUT: !1
76473
- }, cI = { ...sI };
76474
- function lI(e) {
76475
- return cI[e] ?? !1;
76601
+ }, mI = { ...pI };
76602
+ function hI(e) {
76603
+ return mI[e] ?? !1;
76476
76604
  }
76477
- function uI(e) {
76478
- cI = {
76479
- ...cI,
76605
+ function gI(e) {
76606
+ mI = {
76607
+ ...mI,
76480
76608
  ...e
76481
76609
  };
76482
76610
  }
76483
- function dI() {
76484
- cI = { ...sI };
76611
+ function _I() {
76612
+ mI = { ...pI };
76485
76613
  }
76486
- function fI() {
76487
- return { ...cI };
76614
+ function vI() {
76615
+ return { ...mI };
76488
76616
  }
76489
76617
  //#endregion
76490
76618
  //#region src/utils/ManimColor.ts
76491
- var pI = /(?:#|0[xX])([A-Fa-f0-9]{3,8})/;
76492
- function mI(e) {
76619
+ var yI = /(?:#|0[xX])([A-Fa-f0-9]{3,8})/;
76620
+ function bI(e) {
76493
76621
  return Math.min(255, Math.max(0, Math.trunc(e * 255)));
76494
76622
  }
76495
- function hI(e) {
76496
- return mI(e).toString(16).toUpperCase().padStart(2, "0");
76623
+ function xI(e) {
76624
+ return bI(e).toString(16).toUpperCase().padStart(2, "0");
76497
76625
  }
76498
- function gI(e, t) {
76626
+ function SI(e, t) {
76499
76627
  let n = e;
76500
76628
  (n.length === 3 || n.length === 4) && (n = n.split("").map((e) => e + e).join(""));
76501
76629
  let r = t;
@@ -76508,14 +76636,14 @@ function gI(e, t) {
76508
76636
  r
76509
76637
  ];
76510
76638
  }
76511
- function _I(e, t) {
76512
- let n = pI.exec(e);
76513
- if (n !== null) return gI(n[1], t);
76639
+ function CI(e, t) {
76640
+ let n = yI.exec(e);
76641
+ if (n !== null) return SI(n[1], t);
76514
76642
  let r = se[e.toUpperCase()];
76515
- if (typeof r == "string") return _I(r, t);
76643
+ if (typeof r == "string") return CI(r, t);
76516
76644
  throw Error(`Failed to parse a color from "${e}"`);
76517
76645
  }
76518
- function vI(e, t) {
76646
+ function wI(e, t) {
76519
76647
  return [
76520
76648
  (e >> 16 & 255) / 255,
76521
76649
  (e >> 8 & 255) / 255,
@@ -76523,7 +76651,7 @@ function vI(e, t) {
76523
76651
  t
76524
76652
  ];
76525
76653
  }
76526
- var yI = class e {
76654
+ var TI = class e {
76527
76655
  value;
76528
76656
  constructor(t, n = 1) {
76529
76657
  if (t === null) this.value = [
@@ -76540,8 +76668,8 @@ var yI = class e {
76540
76668
  e[2],
76541
76669
  e[3]
76542
76670
  ];
76543
- } else if (typeof t == "number") this.value = vI(t, n);
76544
- else if (typeof t == "string") this.value = _I(t, n);
76671
+ } else if (typeof t == "number") this.value = wI(t, n);
76672
+ else if (typeof t == "string") this.value = CI(t, n);
76545
76673
  else if (t.length === 3) this.value = [
76546
76674
  t[0],
76547
76675
  t[1],
@@ -76599,18 +76727,18 @@ var yI = class e {
76599
76727
  toIntRgb() {
76600
76728
  let e = this.internalRgba();
76601
76729
  return [
76602
- mI(e[0]),
76603
- mI(e[1]),
76604
- mI(e[2])
76730
+ bI(e[0]),
76731
+ bI(e[1]),
76732
+ bI(e[2])
76605
76733
  ];
76606
76734
  }
76607
76735
  toIntRgba() {
76608
76736
  let e = this.internalRgba();
76609
76737
  return [
76610
- mI(e[0]),
76611
- mI(e[1]),
76612
- mI(e[2]),
76613
- mI(e[3])
76738
+ bI(e[0]),
76739
+ bI(e[1]),
76740
+ bI(e[2]),
76741
+ bI(e[3])
76614
76742
  ];
76615
76743
  }
76616
76744
  toHex(e = !1) {
@@ -76619,7 +76747,7 @@ var yI = class e {
76619
76747
  t[1],
76620
76748
  t[2]
76621
76749
  ]);
76622
- return e ? n + hI(t[3]) : n;
76750
+ return e ? n + xI(t[3]) : n;
76623
76751
  }
76624
76752
  toHsv() {
76625
76753
  return Yb(this.toRgb());
@@ -76679,7 +76807,7 @@ var yI = class e {
76679
76807
  static parse(t, n = 1) {
76680
76808
  return Array.isArray(t) && t.some((e) => typeof e != "number") ? t.map((t) => new e(t, n)) : new e(t, n);
76681
76809
  }
76682
- }, bI = yI, xI = class e extends yI {
76810
+ }, EI = TI, DI = class e extends TI {
76683
76811
  hsva;
76684
76812
  constructor(e, t = 1) {
76685
76813
  if (super(null), e.length === 3) this.hsva = [
@@ -76748,7 +76876,7 @@ var yI = class e {
76748
76876
  return this.hsva[2];
76749
76877
  }
76750
76878
  };
76751
- function SI(e) {
76879
+ function OI(e) {
76752
76880
  let t = e >>> 0;
76753
76881
  return () => {
76754
76882
  t = t + 1831565813 | 0;
@@ -76756,18 +76884,18 @@ function SI(e) {
76756
76884
  return e = e + Math.imul(e ^ e >>> 7, 61 | e) ^ e, ((e ^ e >>> 14) >>> 0) / 4294967296;
76757
76885
  };
76758
76886
  }
76759
- var CI = Array.from(new Set(Object.values(se))).map((e) => new yI(e)), wI = class {
76887
+ var kI = Array.from(new Set(Object.values(se))).map((e) => new TI(e)), AI = class {
76760
76888
  rng;
76761
76889
  colors;
76762
76890
  constructor(e, t) {
76763
- this.rng = e === void 0 ? Math.random : SI(e), this.colors = t === void 0 ? CI : t.map((e) => e instanceof yI ? e : new yI(e));
76891
+ this.rng = e === void 0 ? Math.random : OI(e), this.colors = t === void 0 ? kI : t.map((e) => e instanceof TI ? e : new TI(e));
76764
76892
  }
76765
76893
  next() {
76766
76894
  let e = Math.floor(this.rng() * this.colors.length);
76767
76895
  return this.colors[e];
76768
76896
  }
76769
76897
  };
76770
- function TI(e, t, n, r) {
76898
+ function jI(e, t, n, r) {
76771
76899
  let i = .5 * Fn(n, Rn([
76772
76900
  r[0] - t[0],
76773
76901
  r[1] - t[1],
@@ -76781,7 +76909,7 @@ function TI(e, t, n, r) {
76781
76909
  }
76782
76910
  //#endregion
76783
76911
  //#region src/utils/iterables.ts
76784
- function EI(e, t) {
76912
+ function MI(e, t) {
76785
76913
  let n = e.length;
76786
76914
  if (n === 0) return [];
76787
76915
  let r = [];
@@ -76792,10 +76920,10 @@ function EI(e, t) {
76792
76920
  }
76793
76921
  return r;
76794
76922
  }
76795
- function DI(e) {
76796
- return EI(e, 2);
76923
+ function NI(e) {
76924
+ return MI(e, 2);
76797
76925
  }
76798
- function OI(e) {
76926
+ function PI(e) {
76799
76927
  let t = [], n = /* @__PURE__ */ new Set();
76800
76928
  for (let r = e.length - 1; r >= 0; r--) {
76801
76929
  let i = e[r];
@@ -76803,7 +76931,7 @@ function OI(e) {
76803
76931
  }
76804
76932
  return t.reverse(), t;
76805
76933
  }
76806
- function kI(e, t, n) {
76934
+ function FI(e, t, n) {
76807
76935
  if (n === void 0) {
76808
76936
  let n = new Set(t);
76809
76937
  return e.filter((e) => !n.has(e));
@@ -76811,29 +76939,29 @@ function kI(e, t, n) {
76811
76939
  let r = new Set(t.map((e) => n(e)));
76812
76940
  return e.filter((e) => !r.has(n(e)));
76813
76941
  }
76814
- function AI(e, t, n) {
76815
- return kI(e, t, n).concat(t);
76942
+ function II(e, t, n) {
76943
+ return FI(e, t, n).concat(t);
76816
76944
  }
76817
- function jI(e) {
76945
+ function LI(e) {
76818
76946
  return typeof e == "string" ? [e] : typeof e == "object" && e && Symbol.iterator in e ? [...e] : [e];
76819
76947
  }
76820
- function MI(e, t) {
76948
+ function RI(e, t) {
76821
76949
  let n = e.length, r = t.length, i = Math.max(n, r), a = [], o = [];
76822
76950
  for (let s = 0; s < i; s++) a.push(e[Math.floor(s * n / i)]), o.push(t[Math.floor(s * r / i)]);
76823
76951
  return [a, o];
76824
76952
  }
76825
- function NI(e, t) {
76953
+ function zI(e, t) {
76826
76954
  let n = e.length;
76827
76955
  if (n > t) throw Error("Trying to stretch array to a length shorter than its own");
76828
76956
  let r = [];
76829
76957
  for (let i = 0; i < t; i++) r.push(e[Math.floor(i / t * n)]);
76830
76958
  return r;
76831
76959
  }
76832
- function* PI(...e) {
76960
+ function* BI(...e) {
76833
76961
  let t = /* @__PURE__ */ new Set();
76834
76962
  for (let n of e) for (let e of n) t.has(e) || (t.add(e), yield e);
76835
76963
  }
76836
- function FI(e) {
76964
+ function VI(e) {
76837
76965
  let t = [[]];
76838
76966
  for (let n of e) {
76839
76967
  let e = t.length;
@@ -76841,82 +76969,82 @@ function FI(e) {
76841
76969
  }
76842
76970
  return t;
76843
76971
  }
76844
- function II(e, t) {
76972
+ function HI(e, t) {
76845
76973
  for (let n of e) if (!(n instanceof t)) return !1;
76846
76974
  return !0;
76847
76975
  }
76848
- function LI(...e) {
76976
+ function UI(...e) {
76849
76977
  let t = [];
76850
76978
  for (let n of e) for (let e of n) t.push(e);
76851
76979
  return t;
76852
76980
  }
76853
- function RI(e) {
76981
+ function WI(e) {
76854
76982
  return typeof e == "string" ? [e] : typeof e == "object" && e && Symbol.iterator in e ? [...e] : [e];
76855
76983
  }
76856
- function zI(e) {
76984
+ function GI(e) {
76857
76985
  let t = [];
76858
76986
  for (let n of e) n && t.push(n);
76859
76987
  return t;
76860
76988
  }
76861
- function BI(e, t) {
76989
+ function KI(e, t) {
76862
76990
  let n = Math.max(e.length, t.length), r = [], i = [];
76863
76991
  for (let a = 0; a < n; a++) r.push(e[a % e.length]), i.push(t[a % t.length]);
76864
76992
  return [r, i];
76865
76993
  }
76866
- function VI(e) {
76867
- return UI(HI(e));
76994
+ function qI(e) {
76995
+ return YI(JI(e));
76868
76996
  }
76869
- function HI(e) {
76997
+ function JI(e) {
76870
76998
  if (e === null) return "null";
76871
76999
  if (e === void 0) return "undefined";
76872
77000
  let t = typeof e;
76873
77001
  if (t === "string") return `s:${e}`;
76874
77002
  if (t === "number" || t === "boolean" || t === "bigint") return `${t[0]}:${String(e)}`;
76875
- if (e instanceof Set) return `set:[${[...e].map(HI).sort().join(",")}]`;
76876
- if (e instanceof Map) return `map:{${[...e.entries()].map(([e, t]) => `${HI(e)}=${HI(t)}`).sort().join(",")}}`;
76877
- if (Array.isArray(e)) return `arr:[${e.map(HI).join(",")}]`;
77003
+ if (e instanceof Set) return `set:[${[...e].map(JI).sort().join(",")}]`;
77004
+ if (e instanceof Map) return `map:{${[...e.entries()].map(([e, t]) => `${JI(e)}=${JI(t)}`).sort().join(",")}}`;
77005
+ if (Array.isArray(e)) return `arr:[${e.map(JI).join(",")}]`;
76878
77006
  if (t === "object") {
76879
77007
  let t = e;
76880
- return `obj:{${Object.keys(t).sort().map((e) => `${e}=${HI(t[e])}`).join(",")}}`;
77008
+ return `obj:{${Object.keys(t).sort().map((e) => `${e}=${JI(t[e])}`).join(",")}}`;
76881
77009
  }
76882
77010
  return `${t}:${String(e)}`;
76883
77011
  }
76884
- function UI(e) {
77012
+ function YI(e) {
76885
77013
  let t = 2166136261;
76886
77014
  for (let n = 0; n < e.length; n++) t ^= e.charCodeAt(n), t = Math.imul(t, 16777619);
76887
77015
  return t >>> 0;
76888
77016
  }
76889
77017
  //#endregion
76890
77018
  //#region src/utils/unit.ts
76891
- function WI(e) {
77019
+ function XI(e) {
76892
77020
  return e * Zt / $t;
76893
77021
  }
76894
- function GI(e) {
77022
+ function ZI(e) {
76895
77023
  return e * Math.PI / 180;
76896
77024
  }
76897
- function KI(e) {
77025
+ function QI(e) {
76898
77026
  return e;
76899
77027
  }
76900
- function qI(e, t) {
77028
+ function $I(e, t) {
76901
77029
  return e[0] === t[0] && e[1] === t[1] && e[2] === t[2];
76902
77030
  }
76903
- function JI(e, t) {
77031
+ function eL(e, t) {
76904
77032
  let n;
76905
- if (qI(e, _n)) n = Zt;
76906
- else if (qI(e, mn)) n = 8;
76907
- else if (qI(e, vn)) throw Error("length of Z axis is undefined");
77033
+ if ($I(e, _n)) n = Zt;
77034
+ else if ($I(e, mn)) n = 8;
77035
+ else if ($I(e, vn)) throw Error("length of Z axis is undefined");
76908
77036
  else throw Error("Percent axis must be the X axis (RIGHT) or Y axis (UP)");
76909
77037
  return t / 100 * n;
76910
77038
  }
76911
77039
  //#endregion
76912
77040
  //#region src/utils/debug.ts
76913
- function YI(e, t = !1) {
77041
+ function tL(e, t = !1) {
76914
77042
  let n = [];
76915
77043
  for (let t of e) n.push(...t.getFamily());
76916
77044
  return t ? n.filter((e) => e instanceof I && e.hasOwnPoints()) : n;
76917
77045
  }
76918
- function XI(e, t) {
76919
- let n = [], r = new Set(YI(t)), i = (e, t) => {
77046
+ function nL(e, t) {
77047
+ let n = [], r = new Set(tL(t)), i = (e, t) => {
76920
77048
  for (let r of e) {
76921
77049
  if (t.has(r)) continue;
76922
77050
  let e = new Set(r.getFamily().filter((e) => t.has(e)));
@@ -76925,14 +77053,14 @@ function XI(e, t) {
76925
77053
  };
76926
77054
  return i(e, r), n;
76927
77055
  }
76928
- function ZI(e, t = {}) {
77056
+ function rL(e, t = {}) {
76929
77057
  let { labelHeight: n = .15 } = t, r = new L();
76930
77058
  return e.children.forEach((e, t) => {
76931
77059
  let i = new HS({ value: t });
76932
77060
  i.setHeight(n), i.moveTo(e), r.add(i);
76933
77061
  }), r;
76934
77062
  }
76935
- function QI(e, t = 0) {
77063
+ function iL(e, t = 0) {
76936
77064
  let n = [], r = (e, t) => {
76937
77065
  n.push(" ".repeat(t) + `${e.constructor.name} ${e.id}`);
76938
77066
  for (let n of e.children) r(n, t + 1);
@@ -76943,8 +77071,8 @@ function QI(e, t = 0) {
76943
77071
  }
76944
77072
  //#endregion
76945
77073
  //#region src/utils/spaceOps.ts
76946
- var $I = 2 * Math.PI;
76947
- function eL(e) {
77074
+ var aL = 2 * Math.PI;
77075
+ function oL(e) {
76948
77076
  let t = e.length, n = e[0].length, r = [];
76949
77077
  for (let i = 0; i < n; i++) {
76950
77078
  let n = [];
@@ -76953,20 +77081,20 @@ function eL(e) {
76953
77081
  }
76954
77082
  return r;
76955
77083
  }
76956
- function tL(e, t) {
77084
+ function sL(e, t) {
76957
77085
  return e.map((e) => e.reduce((e, n, r) => e + n * (t[r] ?? 0), 0));
76958
77086
  }
76959
- function nL(e) {
77087
+ function cL(e) {
76960
77088
  return e.reduce((e, t) => e + t * t, 0);
76961
77089
  }
76962
- function rL(e, t) {
77090
+ function lL(e, t) {
76963
77091
  return e[0] * t[1] - e[1] * t[0];
76964
77092
  }
76965
- function iL(e, t) {
76966
- let n = Math.sqrt(nL(e));
77093
+ function uL(e, t) {
77094
+ let n = Math.sqrt(cL(e));
76967
77095
  return n > 0 ? e.map((e) => e / n) : t ?? e.map(() => 0);
76968
77096
  }
76969
- function aL(...e) {
77097
+ function dL(...e) {
76970
77098
  if (e.length === 0) return [
76971
77099
  1,
76972
77100
  0,
@@ -76985,8 +77113,8 @@ function aL(...e) {
76985
77113
  }
76986
77114
  return t;
76987
77115
  }
76988
- function oL(e, t, n = !1) {
76989
- let r = n ? t : iL(t), i = Math.sin(e / 2);
77116
+ function fL(e, t, n = !1) {
77117
+ let r = n ? t : uL(t), i = Math.sin(e / 2);
76990
77118
  return [
76991
77119
  Math.cos(e / 2),
76992
77120
  i * (r[0] ?? 0),
@@ -76994,19 +77122,19 @@ function oL(e, t, n = !1) {
76994
77122
  i * (r[2] ?? 0)
76995
77123
  ];
76996
77124
  }
76997
- function sL(e) {
76998
- let t = iL(e.slice(1), [
77125
+ function pL(e) {
77126
+ let t = uL(e.slice(1), [
76999
77127
  1,
77000
77128
  0,
77001
77129
  0
77002
77130
  ]), n = 2 * Math.acos(e[0]);
77003
- return n > $I / 2 && (n = $I - n, t = [
77131
+ return n > aL / 2 && (n = aL - n, t = [
77004
77132
  -t[0],
77005
77133
  -t[1],
77006
77134
  -t[2]
77007
77135
  ]), [n, t];
77008
77136
  }
77009
- function cL(e) {
77137
+ function mL(e) {
77010
77138
  return [
77011
77139
  e[0],
77012
77140
  -e[1],
@@ -77014,7 +77142,7 @@ function cL(e) {
77014
77142
  -e[3]
77015
77143
  ];
77016
77144
  }
77017
- function lL(e, t, n = !1) {
77145
+ function hL(e, t, n = !1) {
77018
77146
  let [r, i, a] = Rn(t), o = Math.cos(e), s = Math.sin(e), c = 1 - o, l = [
77019
77147
  [
77020
77148
  o + r * r * c,
@@ -77044,7 +77172,7 @@ function lL(e, t, n = !1) {
77044
77172
  ]
77045
77173
  ] : l;
77046
77174
  }
77047
- function uL(e) {
77175
+ function gL(e) {
77048
77176
  let t = Math.cos(e), n = Math.sin(e);
77049
77177
  return [
77050
77178
  [
@@ -77064,23 +77192,23 @@ function uL(e) {
77064
77192
  ]
77065
77193
  ];
77066
77194
  }
77067
- function dL(e, t) {
77068
- return (t[0] ?? 0) === 0 && (t[1] ?? 0) === 0 ? eL(uL(e * Math.sign(t[2] ?? 0))) : eL(lL(e, t));
77195
+ function _L(e, t) {
77196
+ return (t[0] ?? 0) === 0 && (t[1] ?? 0) === 0 ? oL(gL(e * Math.sign(t[2] ?? 0))) : oL(hL(e, t));
77069
77197
  }
77070
- function fL(e, t, n = vn) {
77198
+ function vL(e, t, n = vn) {
77071
77199
  if (e.length > 3) throw Error("Vector must have the correct dimensions.");
77072
77200
  let r = e.length === 2 ? [
77073
77201
  e[0],
77074
77202
  e[1],
77075
77203
  0
77076
- ] : e, i = tL(lL(t, n), r);
77204
+ ] : e, i = sL(hL(t, n), r);
77077
77205
  return [
77078
77206
  i[0],
77079
77207
  i[1],
77080
77208
  i[2]
77081
77209
  ];
77082
77210
  }
77083
- function pL(e) {
77211
+ function yL(e) {
77084
77212
  let t = Rn(e), n = Rn(In(t, _n)), r = In(n, t);
77085
77213
  if (Ln(n) === 0) {
77086
77214
  r = Rn(In(mn, t));
@@ -77091,27 +77219,27 @@ function pL(e) {
77091
77219
  -e[2]
77092
77220
  ];
77093
77221
  }
77094
- return eL([
77222
+ return oL([
77095
77223
  r,
77096
77224
  n,
77097
77225
  t
77098
77226
  ]);
77099
77227
  }
77100
- function mL(e) {
77228
+ function bL(e) {
77101
77229
  return Math.atan2(e[1] ?? 0, e[0] ?? 0);
77102
77230
  }
77103
- function hL(e, t) {
77104
- let n = iL(e), r = iL(t), i = n.map((e, t) => e - r[t]), a = n.map((e, t) => e + r[t]);
77105
- return 2 * Math.atan2(Math.sqrt(nL(i)), Math.sqrt(nL(a)));
77231
+ function xL(e, t) {
77232
+ let n = uL(e), r = uL(t), i = n.map((e, t) => e - r[t]), a = n.map((e, t) => e + r[t]);
77233
+ return 2 * Math.atan2(Math.sqrt(cL(i)), Math.sqrt(cL(a)));
77106
77234
  }
77107
- function gL(e, t, n = 1e-6) {
77235
+ function SL(e, t, n = 1e-6) {
77108
77236
  let r = Math.max(...e.map(Math.abs)), i = Math.max(...t.map(Math.abs)), a;
77109
77237
  if (r === 0) {
77110
77238
  if (i === 0) return hn;
77111
77239
  a = t.map((e) => e / i);
77112
77240
  } else if (i === 0) a = e.map((e) => e / r);
77113
77241
  else {
77114
- let o = e.map((e) => e / r), s = In(o, t.map((e) => e / i)), c = Math.sqrt(nL(s));
77242
+ let o = e.map((e) => e / r), s = In(o, t.map((e) => e / i)), c = Math.sqrt(cL(s));
77115
77243
  if (c > n) return [
77116
77244
  s[0] / c,
77117
77245
  s[1] / c,
@@ -77124,43 +77252,43 @@ function gL(e, t, n = 1e-6) {
77124
77252
  -a[0] * a[2],
77125
77253
  -a[1] * a[2],
77126
77254
  a[0] * a[0] + a[1] * a[1]
77127
- ], s = Math.sqrt(nL(o));
77255
+ ], s = Math.sqrt(cL(o));
77128
77256
  return [
77129
77257
  o[0] / s,
77130
77258
  o[1] / s,
77131
77259
  o[2] / s
77132
77260
  ];
77133
77261
  }
77134
- function _L(e = 4, t = _n) {
77135
- let n = $I / e, r = [];
77136
- for (let i = 0; i < e; i++) r.push(fL(t, i * n));
77262
+ function CL(e = 4, t = _n) {
77263
+ let n = aL / e, r = [];
77264
+ for (let i = 0; i < e; i++) r.push(vL(t, i * n));
77137
77265
  return r;
77138
77266
  }
77139
- function vL(e, t = {}) {
77140
- let n = t.radius ?? 1, r = t.startAngle ?? (e % 2 == 0 ? 0 : $I / 4);
77141
- return [_L(e, fL([
77267
+ function wL(e, t = {}) {
77268
+ let n = t.radius ?? 1, r = t.startAngle ?? (e % 2 == 0 ? 0 : aL / 4);
77269
+ return [CL(e, vL([
77142
77270
  n,
77143
77271
  0,
77144
77272
  0
77145
77273
  ], r)), r];
77146
77274
  }
77147
- function yL(e) {
77275
+ function TL(e) {
77148
77276
  return [
77149
77277
  e.re,
77150
77278
  e.im,
77151
77279
  0
77152
77280
  ];
77153
77281
  }
77154
- function bL(e) {
77282
+ function EL(e) {
77155
77283
  return {
77156
77284
  re: e[0] ?? 0,
77157
77285
  im: e[1] ?? 0
77158
77286
  };
77159
77287
  }
77160
- function xL(e) {
77161
- return (t) => yL(e(bL(t)));
77288
+ function DL(e) {
77289
+ return (t) => TL(e(EL(t)));
77162
77290
  }
77163
- function SL(e) {
77291
+ function OL(e) {
77164
77292
  let t = [
77165
77293
  0,
77166
77294
  0,
@@ -77174,10 +77302,10 @@ function SL(e) {
77174
77302
  t[2] / n
77175
77303
  ];
77176
77304
  }
77177
- function CL(e, t) {
77178
- return SL([e, t]);
77305
+ function kL(e, t) {
77306
+ return OL([e, t]);
77179
77307
  }
77180
- function wL(e, t) {
77308
+ function AL(e, t) {
77181
77309
  for (let n of [e, t]) for (let e of n) if ((e[2] ?? 0) !== 0) throw Error("Coords must be in the xy-plane.");
77182
77310
  let n = (e) => In([
77183
77311
  e[0][0],
@@ -77195,7 +77323,7 @@ function wL(e, t) {
77195
77323
  0
77196
77324
  ];
77197
77325
  }
77198
- function TL(e, t, n, r, i = 1e-5) {
77326
+ function jL(e, t, n, r, i = 1e-5) {
77199
77327
  let a = [];
77200
77328
  for (let o = 0; o < e.length; o++) {
77201
77329
  let s = e[o], c = t[o], l = n[o], u = r[o], d = In(u, In(c, u)), f = c[0] * d[0] + c[1] * d[1] + c[2] * d[2], p = Math.max(f, i), m = [
@@ -77211,15 +77339,15 @@ function TL(e, t, n, r, i = 1e-5) {
77211
77339
  }
77212
77340
  return a;
77213
77341
  }
77214
- function EL(e) {
77342
+ function ML(e) {
77215
77343
  let t = 0;
77216
77344
  for (let n = 0; n < e.length - 1; n++) t += (e[n + 1][0] - e[n][0]) * (e[n][1] + e[n + 1][1]) / 2;
77217
77345
  return t;
77218
77346
  }
77219
- function DL(e) {
77220
- return EL(e) > 0 ? "CW" : "CCW";
77347
+ function NL(e) {
77348
+ return ML(e) > 0 ? "CW" : "CCW";
77221
77349
  }
77222
- function OL(e) {
77350
+ function PL(e) {
77223
77351
  let t = Ln(e);
77224
77352
  if (t === 0) return [
77225
77353
  0,
@@ -77233,7 +77361,7 @@ function OL(e) {
77233
77361
  n
77234
77362
  ];
77235
77363
  }
77236
- function kL(e) {
77364
+ function FL(e) {
77237
77365
  let [t, n, r] = e;
77238
77366
  return [
77239
77367
  t * Math.cos(n) * Math.sin(r),
@@ -77241,12 +77369,12 @@ function kL(e) {
77241
77369
  t * Math.cos(r)
77242
77370
  ];
77243
77371
  }
77244
- function AL(e, t = vn) {
77372
+ function IL(e, t = vn) {
77245
77373
  let n = e[0], r = e[1], i = In([
77246
77374
  n[0] - r[0],
77247
77375
  n[1] - r[1],
77248
77376
  n[2] - r[2]
77249
- ], t), a = CL(n, r);
77377
+ ], t), a = kL(n, r);
77250
77378
  return [[
77251
77379
  a[0] + i[0],
77252
77380
  a[1] + i[1],
@@ -77257,7 +77385,7 @@ function AL(e, t = vn) {
77257
77385
  a[2] - i[2]
77258
77386
  ]];
77259
77387
  }
77260
- function jL(e, t = 2) {
77388
+ function LL(e, t = 2) {
77261
77389
  let n = [];
77262
77390
  for (let r = 0; r < e; r++) {
77263
77391
  let i = [];
@@ -77266,41 +77394,41 @@ function jL(e, t = 2) {
77266
77394
  }
77267
77395
  return n;
77268
77396
  }
77269
- function ML(e) {
77397
+ function RL(e) {
77270
77398
  let t = 0;
77271
- for (let [n, r] of DI(e)) {
77272
- let e = ((mL(r) - mL(n) + Math.PI) % $I + $I) % $I - Math.PI;
77399
+ for (let [n, r] of NI(e)) {
77400
+ let e = ((bL(r) - bL(n) + Math.PI) % aL + aL) % aL - Math.PI;
77273
77401
  t += e;
77274
77402
  }
77275
- return t / $I;
77403
+ return t / aL;
77276
77404
  }
77277
77405
  //#endregion
77278
77406
  //#region src/utils/paths.ts
77279
- var NL = .01;
77280
- function PL(e, t, n) {
77407
+ var zL = .01;
77408
+ function BL(e, t, n) {
77281
77409
  return e.map((e, r) => e.map((e, i) => e + n * (t[r][i] - e)));
77282
77410
  }
77283
- function FL(e, t) {
77411
+ function VL(e, t) {
77284
77412
  return t.map((t) => t.reduce((t, n, r) => t + n * e[r], 0));
77285
77413
  }
77286
- function IL() {
77287
- return PL;
77414
+ function HL() {
77415
+ return BL;
77288
77416
  }
77289
- function LL(e, t, n = vn) {
77290
- let r = iL(n, vn), i = (e) => t[e] ?? t[0];
77417
+ function UL(e, t, n = vn) {
77418
+ let r = uL(n, vn), i = (e) => t[e] ?? t[0];
77291
77419
  return (t, n, a) => {
77292
- let o = lL(-e, r), s = lL(a * e, r);
77420
+ let o = hL(-e, r), s = hL(a * e, r);
77293
77421
  return t.map((e, t) => {
77294
- let r = i(t), c = FL(n[t].map((e, t) => e - r[t]), o).map((e, t) => e + r[t]);
77295
- return FL(e.map((e, t) => e + a * (c[t] - e)).map((e, t) => e - r[t]), s).map((e, t) => e + r[t]);
77422
+ let r = i(t), c = VL(n[t].map((e, t) => e - r[t]), o).map((e, t) => e + r[t]);
77423
+ return VL(e.map((e, t) => e + a * (c[t] - e)).map((e, t) => e - r[t]), s).map((e, t) => e + r[t]);
77296
77424
  });
77297
77425
  };
77298
77426
  }
77299
- function RL(e, t = vn) {
77300
- if (Math.abs(e) < NL) return IL();
77301
- let n = iL(t, vn);
77427
+ function WL(e, t = vn) {
77428
+ if (Math.abs(e) < zL) return HL();
77429
+ let n = uL(t, vn);
77302
77430
  return (t, r, i) => {
77303
- let a = lL(i * e, n);
77431
+ let a = hL(i * e, n);
77304
77432
  return t.map((t, i) => {
77305
77433
  let o = r[i].map((e, n) => e - t[n]), s = t.map((e, t) => e + .5 * o[t]);
77306
77434
  if (e !== Math.PI) {
@@ -77311,19 +77439,19 @@ function RL(e, t = vn) {
77311
77439
  ], i = 1 / Math.tan(e / 2);
77312
77440
  for (let e = 0; e < s.length; e++) s[e] += r[e] * i;
77313
77441
  }
77314
- return FL(t.map((e, t) => e - s[t]), a).map((e, t) => e + s[t]);
77442
+ return VL(t.map((e, t) => e - s[t]), a).map((e, t) => e + s[t]);
77315
77443
  });
77316
77444
  };
77317
77445
  }
77318
- function zL() {
77319
- return RL(-Math.PI);
77446
+ function GL() {
77447
+ return WL(-Math.PI);
77320
77448
  }
77321
- function BL() {
77322
- return RL(Math.PI);
77449
+ function KL() {
77450
+ return WL(Math.PI);
77323
77451
  }
77324
77452
  //#endregion
77325
77453
  //#region src/utils/simpleFunctions.ts
77326
- function VL(e, t, n, r, i = 1e-4) {
77454
+ function qL(e, t, n, r, i = 1e-4) {
77327
77455
  let a = n, o = r, s = (a + o) / 2;
77328
77456
  for (; Math.abs(o - a) > i;) {
77329
77457
  s = (a + o) / 2;
@@ -77336,7 +77464,7 @@ function VL(e, t, n, r, i = 1e-4) {
77336
77464
  }
77337
77465
  return s;
77338
77466
  }
77339
- function HL(e, t) {
77467
+ function JL(e, t) {
77340
77468
  if (t < 0 || t > e) return 0;
77341
77469
  let n = t;
77342
77470
  n > e - n && (n = e - n);
@@ -77344,30 +77472,30 @@ function HL(e, t) {
77344
77472
  for (let t = 0; t < n; t++) r = r * (e - t) / (t + 1);
77345
77473
  return Math.round(r);
77346
77474
  }
77347
- function UL(e, t, n) {
77475
+ function YL(e, t, n) {
77348
77476
  return e < t ? t : e > n ? n : e;
77349
77477
  }
77350
- function WL(e) {
77478
+ function XL(e) {
77351
77479
  return 1 / (1 + Math.exp(-e));
77352
77480
  }
77353
77481
  //#endregion
77354
77482
  //#region src/utils/bezier.ts
77355
- function GL(e, t, n) {
77483
+ function ZL(e, t, n) {
77356
77484
  if (Array.isArray(e) && Array.isArray(t)) return e.map((e, r) => (1 - n) * e + n * t[r]);
77357
77485
  if (typeof e == "number" && typeof t == "number") return (1 - n) * e + n * t;
77358
77486
  throw Error("interpolate: start and end must both be numbers or both be arrays");
77359
77487
  }
77360
- function KL(e, t) {
77488
+ function QL(e, t) {
77361
77489
  if (Array.isArray(e) && Array.isArray(t)) return e.map((e, n) => (e + t[n]) / 2);
77362
77490
  if (typeof e == "number" && typeof t == "number") return (e + t) / 2;
77363
77491
  throw Error("mid: start and end must both be numbers or both be arrays");
77364
77492
  }
77365
- function qL(e, t, n) {
77493
+ function $L(e, t, n) {
77366
77494
  if (Array.isArray(e) && Array.isArray(t) && Array.isArray(n)) return e.map((e, r) => (n[r] - e) / (t[r] - e));
77367
77495
  if (typeof e == "number" && typeof t == "number" && typeof n == "number") return (n - e) / (t - e);
77368
77496
  throw Error("inverse_interpolate: start, end and value must all be numbers or all be arrays");
77369
77497
  }
77370
- function JL(e, t, n, r, i) {
77498
+ function eR(e, t, n, r, i) {
77371
77499
  let a = r - n;
77372
77500
  if (Array.isArray(i)) return i.map((r) => {
77373
77501
  let i = (r - n) / a;
@@ -77376,7 +77504,7 @@ function JL(e, t, n, r, i) {
77376
77504
  let o = (i - n) / a;
77377
77505
  return (1 - o) * e + o * t;
77378
77506
  }
77379
- function YL(e, t) {
77507
+ function tR(e, t) {
77380
77508
  if (e.length === 0) return 0;
77381
77509
  let n = e.slice();
77382
77510
  for (; n.length > 1;) {
@@ -77386,7 +77514,7 @@ function YL(e, t) {
77386
77514
  }
77387
77515
  return n[0];
77388
77516
  }
77389
- function XL(e, t) {
77517
+ function nR(e, t) {
77390
77518
  if (e.length === 0) return [];
77391
77519
  let n = e.map((e) => e.slice());
77392
77520
  for (; n.length > 1;) {
@@ -77396,15 +77524,15 @@ function XL(e, t) {
77396
77524
  }
77397
77525
  return n[0];
77398
77526
  }
77399
- function ZL(e) {
77527
+ function rR(e) {
77400
77528
  if (e.length > 0 && Array.isArray(e[0])) {
77401
77529
  let t = e.filter((e) => Array.isArray(e));
77402
- return (e) => XL(t, e);
77530
+ return (e) => nR(t, e);
77403
77531
  }
77404
77532
  let t = e.filter((e) => typeof e == "number");
77405
- return (e) => YL(t, e);
77533
+ return (e) => tR(t, e);
77406
77534
  }
77407
- function QL(e, t) {
77535
+ function iR(e, t) {
77408
77536
  let n = e.length, r = e.map((e) => e.slice()), i = Array(n);
77409
77537
  i[0] = e[0].slice();
77410
77538
  for (let e = 1; e < n; e++) {
@@ -77413,7 +77541,7 @@ function QL(e, t) {
77413
77541
  }
77414
77542
  return [...i, ...r];
77415
77543
  }
77416
- function $L(e, t) {
77544
+ function aR(e, t) {
77417
77545
  if (t <= 1) return e.map((e) => e.slice());
77418
77546
  let n = [];
77419
77547
  for (let r = 0; r < t; r++) {
@@ -77422,7 +77550,7 @@ function $L(e, t) {
77422
77550
  }
77423
77551
  return n;
77424
77552
  }
77425
- function eR(e, t) {
77553
+ function oR(e, t) {
77426
77554
  let n = e.length;
77427
77555
  if (n === 0) return [];
77428
77556
  let r = e[0].length, i = [];
@@ -77433,12 +77561,12 @@ function eR(e, t) {
77433
77561
  for (let t = 0; t < n; t++) {
77434
77562
  let n = a[t];
77435
77563
  if (n <= 0) continue;
77436
- let i = $L(e[t], n);
77564
+ let i = aR(e[t], n);
77437
77565
  for (let e = 0; e < n; e++) o.push(i.slice(e * r, e * r + r));
77438
77566
  }
77439
77567
  return o;
77440
77568
  }
77441
- function tR(e) {
77569
+ function sR(e) {
77442
77570
  let t = e[0], n = e[e.length - 1];
77443
77571
  for (let e = 0; e < 3; e++) {
77444
77572
  let r = t[e] ?? 0, i = n[e] ?? 0, a = 1e-8 + 1e-5 * Math.abs(r);
@@ -77446,43 +77574,43 @@ function tR(e) {
77446
77574
  }
77447
77575
  return !0;
77448
77576
  }
77449
- function nR(e, t) {
77577
+ function cR(e, t) {
77450
77578
  return {
77451
77579
  re: e.re + t.re,
77452
77580
  im: e.im + t.im
77453
77581
  };
77454
77582
  }
77455
- function rR(e, t) {
77583
+ function lR(e, t) {
77456
77584
  return {
77457
77585
  re: e.re - t.re,
77458
77586
  im: e.im - t.im
77459
77587
  };
77460
77588
  }
77461
- function iR(e, t) {
77589
+ function uR(e, t) {
77462
77590
  return {
77463
77591
  re: e.re * t.re - e.im * t.im,
77464
77592
  im: e.re * t.im + e.im * t.re
77465
77593
  };
77466
77594
  }
77467
- function aR(e, t) {
77595
+ function dR(e, t) {
77468
77596
  let n = t.re * t.re + t.im * t.im;
77469
77597
  return {
77470
77598
  re: (e.re * t.re + e.im * t.im) / n,
77471
77599
  im: (e.im * t.re - e.re * t.im) / n
77472
77600
  };
77473
77601
  }
77474
- function oR(e, t) {
77602
+ function fR(e, t) {
77475
77603
  let n = {
77476
77604
  re: e[e.length - 1],
77477
77605
  im: 0
77478
77606
  };
77479
- for (let r = e.length - 2; r >= 0; r--) n = nR(iR(n, t), {
77607
+ for (let r = e.length - 2; r >= 0; r--) n = cR(uR(n, t), {
77480
77608
  re: e[r],
77481
77609
  im: 0
77482
77610
  });
77483
77611
  return n;
77484
77612
  }
77485
- function sR(e) {
77613
+ function pR(e) {
77486
77614
  let t = e.slice();
77487
77615
  for (; t.length > 1 && Math.abs(t[t.length - 1]) < 1e-14;) t.pop();
77488
77616
  let n = t.length - 1;
@@ -77497,17 +77625,17 @@ function sR(e) {
77497
77625
  for (let e = 0; e < n; e++) a.push({
77498
77626
  re: s.re,
77499
77627
  im: s.im
77500
- }), s = iR(s, o);
77628
+ }), s = uR(s, o);
77501
77629
  for (let e = 0; e < 200; e++) {
77502
77630
  let e = 0;
77503
77631
  for (let t = 0; t < n; t++) {
77504
- let r = oR(i, a[t]), o = {
77632
+ let r = fR(i, a[t]), o = {
77505
77633
  re: 1,
77506
77634
  im: 0
77507
77635
  };
77508
- for (let e = 0; e < n; e++) e !== t && (o = iR(o, rR(a[t], a[e])));
77509
- let s = aR(r, o);
77510
- a[t] = rR(a[t], s);
77636
+ for (let e = 0; e < n; e++) e !== t && (o = uR(o, lR(a[t], a[e])));
77637
+ let s = dR(r, o);
77638
+ a[t] = lR(a[t], s);
77511
77639
  let c = Math.hypot(s.re, s.im);
77512
77640
  c > e && (e = c);
77513
77641
  }
@@ -77515,98 +77643,98 @@ function sR(e) {
77515
77643
  }
77516
77644
  return a;
77517
77645
  }
77518
- function cR(e, t) {
77646
+ function mR(e, t) {
77519
77647
  if (t < 0 || t > e) return 0;
77520
77648
  let n = 1;
77521
77649
  for (let r = 0; r < t; r++) n = n * (e - r) / (r + 1);
77522
77650
  return Math.round(n);
77523
77651
  }
77524
- function lR(e, t) {
77652
+ function hR(e, t) {
77525
77653
  let n = 10 ** t;
77526
77654
  return Math.round(e * n) / n;
77527
77655
  }
77528
- function uR(e, t, n) {
77656
+ function gR(e, t, n) {
77529
77657
  let r = .5 * 10 ** -n, i = [];
77530
77658
  for (let n of e) t.some((e) => Math.abs(n - e) <= r) && !i.some((e) => Math.abs(n - e) <= r) && i.push(n);
77531
77659
  return i;
77532
77660
  }
77533
- function dR(e, t, n = 1e-6) {
77661
+ function _R(e, t, n = 1e-6) {
77534
77662
  for (let n of t) if (n.length !== e.length) throw Error("proportions_along_bezier_curve_for_point: point and control points have different shapes");
77535
77663
  let r = t.length - 1, i = Math.round(Math.log10(1 / n)), a = [];
77536
77664
  for (let n = 0; n < e.length; n++) {
77537
77665
  let o = e[n], s = t.map((e) => e[n]), c = [];
77538
77666
  for (let e = r; e >= 0; e--) {
77539
- let t = cR(r, e), n = 1, i = 0;
77667
+ let t = mR(r, e), n = 1, i = 0;
77540
77668
  for (let t = e; t >= 0; t--) {
77541
- let r = cR(e, t) * n * s[t];
77669
+ let r = mR(e, t) * n * s[t];
77542
77670
  e === 0 && (r -= o), i += r, n *= -1;
77543
77671
  }
77544
77672
  c.push(t * i);
77545
77673
  }
77546
77674
  if (c.every((e) => e === 0)) continue;
77547
- let l = sR(c.slice().reverse()).filter((e) => Math.abs(e.im) < 1e-9).map((e) => lR(e.re, i));
77675
+ let l = pR(c.slice().reverse()).filter((e) => Math.abs(e.im) < 1e-9).map((e) => hR(e.re, i));
77548
77676
  a.push(l);
77549
77677
  }
77550
77678
  if (a.length === 0) return [];
77551
77679
  let o = a[0];
77552
- for (let e = 1; e < a.length; e++) o = uR(o, a[e], i);
77680
+ for (let e = 1; e < a.length; e++) o = gR(o, a[e], i);
77553
77681
  return o.filter((e) => e >= 0 && e <= 1);
77554
77682
  }
77555
- function fR(e, t, n = 1e-6) {
77556
- return dR(e, t, n).length > 0;
77683
+ function vR(e, t, n = 1e-6) {
77684
+ return _R(e, t, n).length > 0;
77557
77685
  }
77558
77686
  //#endregion
77559
77687
  //#region src/mobjects/three-d/threeDVmobUtils.ts
77560
- function pR(e) {
77688
+ function yR(e) {
77561
77689
  return [
77562
77690
  e[0],
77563
77691
  e[1],
77564
77692
  e[2]
77565
77693
  ];
77566
77694
  }
77567
- function mR(e) {
77695
+ function bR(e) {
77568
77696
  return e.filter((e, t) => t % 3 == 0);
77569
77697
  }
77570
- function hR(e) {
77571
- return [vR(e), yR(e)];
77698
+ function xR(e) {
77699
+ return [wR(e), TR(e)];
77572
77700
  }
77573
- function gR(e) {
77701
+ function SR(e) {
77574
77702
  return 0;
77575
77703
  }
77576
- function _R(e) {
77704
+ function CR(e) {
77577
77705
  return Math.floor((e.getPoints().length - 1) / 6) * 3;
77578
77706
  }
77579
- function vR(e) {
77707
+ function wR(e) {
77580
77708
  let t = e.getPoints();
77581
- return t.length === 0 ? [...bn] : pR(t[gR(e)]);
77709
+ return t.length === 0 ? [...bn] : yR(t[SR(e)]);
77582
77710
  }
77583
- function yR(e) {
77711
+ function TR(e) {
77584
77712
  let t = e.getPoints();
77585
- return t.length === 0 ? [...bn] : pR(t[_R(e)]);
77713
+ return t.length === 0 ? [...bn] : yR(t[CR(e)]);
77586
77714
  }
77587
- function bR(e, t) {
77715
+ function ER(e, t) {
77588
77716
  let n = e.getPoints(), r = n.length;
77589
- if (mR(n).length <= 2) return [...mn];
77590
- let i = t, a = i > 2 ? i - 3 : r - 4, o = gL(n[i < r - 3 ? i + 3 : 3].map((e, t) => e - n[i][t]), n[a].map((e, t) => e - n[i][t]));
77717
+ if (bR(n).length <= 2) return [...mn];
77718
+ let i = t, a = i > 2 ? i - 3 : r - 4, o = SL(n[i < r - 3 ? i + 3 : 3].map((e, t) => e - n[i][t]), n[a].map((e, t) => e - n[i][t]));
77591
77719
  return Math.hypot(...o) === 0 ? [...mn] : o;
77592
77720
  }
77593
- function xR(e) {
77594
- return bR(e, gR(e));
77721
+ function DR(e) {
77722
+ return ER(e, SR(e));
77595
77723
  }
77596
- function SR(e) {
77597
- return bR(e, _R(e));
77724
+ function OR(e) {
77725
+ return ER(e, CR(e));
77598
77726
  }
77599
77727
  //#endregion
77600
77728
  //#region src/core/SpecialThreeDScene.ts
77601
- var CR = 70 * _t, wR = -110 * _t, TR = 2, ER = 48, DR = class extends c_ {
77729
+ var kR = 70 * _t, AR = -110 * _t, jR = 2, MR = 48, NR = class extends c_ {
77602
77730
  cutAxesAtRadius;
77603
77731
  _threeDAxesConfig;
77604
77732
  _sphereConfig;
77605
77733
  _defaultAngledCameraPosition;
77606
77734
  constructor(e, t = {}) {
77607
77735
  let { cutAxesAtRadius: n = !0, threeDAxesConfig: r = {}, sphereConfig: i = {}, defaultAngledCameraPosition: a = {
77608
- phi: CR,
77609
- theta: wR
77736
+ phi: kR,
77737
+ theta: AR
77610
77738
  }, phi: o = a.phi, theta: s = a.theta, ...c } = t;
77611
77739
  super(e, {
77612
77740
  ...c,
@@ -77636,8 +77764,8 @@ var CR = 70 * _t, wR = -110 * _t, TR = 2, ER = 48, DR = class extends c_ {
77636
77764
  }
77637
77765
  getDefaultSphereConfig() {
77638
77766
  return {
77639
- radius: TR,
77640
- resolution: ER
77767
+ radius: jR,
77768
+ resolution: MR
77641
77769
  };
77642
77770
  }
77643
77771
  getAxes() {
@@ -77663,73 +77791,73 @@ var CR = 70 * _t, wR = -110 * _t, TR = 2, ER = 48, DR = class extends c_ {
77663
77791
  };
77664
77792
  //#endregion
77665
77793
  //#region src/mobjects/text/registerFont.ts
77666
- function OR(e, t) {
77794
+ function PR(e, t) {
77667
77795
  if (typeof document > "u" || typeof FontFace > "u" || document.fonts === void 0) return !1;
77668
77796
  let n = typeof t == "string" && !/^\s*(url|local)\s*\(/i.test(t) ? `url("${t}")` : t, r = new FontFace(e, n);
77669
77797
  return document.fonts.add(r), !0;
77670
77798
  }
77671
77799
  //#endregion
77672
77800
  //#region src/serialization/registry.ts
77673
- var kR = /* @__PURE__ */ new Map();
77674
- function AR(e, t) {
77675
- kR.set(e, t);
77801
+ var FR = /* @__PURE__ */ new Map();
77802
+ function IR(e, t) {
77803
+ FR.set(e, t);
77676
77804
  }
77677
- function jR(e) {
77678
- kR.delete(e);
77805
+ function LR(e) {
77806
+ FR.delete(e);
77679
77807
  }
77680
- function MR(e) {
77681
- return kR.get(e);
77808
+ function RR(e) {
77809
+ return FR.get(e);
77682
77810
  }
77683
- function NR() {
77684
- return [...kR.keys()].sort();
77811
+ function zR() {
77812
+ return [...FR.keys()].sort();
77685
77813
  }
77686
77814
  //#endregion
77687
77815
  //#region src/serialization/props.ts
77688
- function PR(e, t) {
77816
+ function BR(e, t) {
77689
77817
  return typeof e == "number" && Number.isFinite(e) ? e : t;
77690
77818
  }
77691
- function FR(e, t) {
77819
+ function VR(e, t) {
77692
77820
  return typeof e == "string" ? e : t;
77693
77821
  }
77694
- function IR(e, t) {
77822
+ function HR(e, t) {
77695
77823
  return typeof e == "boolean" ? e : t;
77696
77824
  }
77697
- function LR(e) {
77825
+ function UR(e) {
77698
77826
  return typeof e == "string" ? e : void 0;
77699
77827
  }
77700
- function RR(e) {
77828
+ function WR(e) {
77701
77829
  return Array.isArray(e) && e.length === 3 && e.every((e) => typeof e == "number" && Number.isFinite(e));
77702
77830
  }
77703
- function zR(e, t) {
77704
- return RR(e) ? [
77831
+ function GR(e, t) {
77832
+ return WR(e) ? [
77705
77833
  e[0],
77706
77834
  e[1],
77707
77835
  e[2]
77708
77836
  ] : t;
77709
77837
  }
77710
- function BR(e) {
77838
+ function KR(e) {
77711
77839
  if (!Array.isArray(e)) return [];
77712
77840
  let t = [];
77713
- for (let n of e) RR(n) && t.push([
77841
+ for (let n of e) WR(n) && t.push([
77714
77842
  n[0],
77715
77843
  n[1],
77716
77844
  n[2]
77717
77845
  ]);
77718
77846
  return t;
77719
77847
  }
77720
- function VR(e) {
77848
+ function qR(e) {
77721
77849
  return typeof e == "object" && !!e && !Array.isArray(e);
77722
77850
  }
77723
77851
  //#endregion
77724
77852
  //#region src/serialization/defaults.ts
77725
- function HR(e) {
77726
- return typeof e == "number" && Number.isFinite(e) ? e : FR(e, "normal");
77853
+ function JR(e) {
77854
+ return typeof e == "number" && Number.isFinite(e) ? e : VR(e, "normal");
77727
77855
  }
77728
- function UR(e) {
77856
+ function YR(e) {
77729
77857
  return e === "left" || e === "right" ? e : "center";
77730
77858
  }
77731
- function WR() {
77732
- AR("Circle", {
77859
+ function XR() {
77860
+ IR("Circle", {
77733
77861
  serialize: (e) => {
77734
77862
  let t = e;
77735
77863
  return {
@@ -77738,10 +77866,10 @@ function WR() {
77738
77866
  };
77739
77867
  },
77740
77868
  deserialize: (e) => new Wv({
77741
- radius: PR(e.radius, 1),
77742
- numPoints: PR(e.numPoints, 64)
77869
+ radius: BR(e.radius, 1),
77870
+ numPoints: BR(e.numPoints, 64)
77743
77871
  })
77744
- }), AR("Rectangle", {
77872
+ }), IR("Rectangle", {
77745
77873
  serialize: (e) => {
77746
77874
  let t = e;
77747
77875
  return {
@@ -77750,13 +77878,13 @@ function WR() {
77750
77878
  };
77751
77879
  },
77752
77880
  deserialize: (e) => new l_({
77753
- width: PR(e.width, 2),
77754
- height: PR(e.height, 1)
77881
+ width: BR(e.width, 2),
77882
+ height: BR(e.height, 1)
77755
77883
  })
77756
- }), AR("Square", {
77884
+ }), IR("Square", {
77757
77885
  serialize: (e) => ({ sideLength: e._width }),
77758
- deserialize: (e) => new u_({ sideLength: PR(e.sideLength, 2) })
77759
- }), AR("Line", {
77886
+ deserialize: (e) => new u_({ sideLength: BR(e.sideLength, 2) })
77887
+ }), IR("Line", {
77760
77888
  serialize: (e) => {
77761
77889
  let t = e;
77762
77890
  return {
@@ -77765,27 +77893,27 @@ function WR() {
77765
77893
  };
77766
77894
  },
77767
77895
  deserialize: (e) => new x_({
77768
- start: zR(e.start, [
77896
+ start: GR(e.start, [
77769
77897
  0,
77770
77898
  0,
77771
77899
  0
77772
77900
  ]),
77773
- end: zR(e.end, [
77901
+ end: GR(e.end, [
77774
77902
  1,
77775
77903
  0,
77776
77904
  0
77777
77905
  ])
77778
77906
  })
77779
- }), AR("Dot", {
77907
+ }), IR("Dot", {
77780
77908
  serialize: (e) => ({ radius: e._radius }),
77781
- deserialize: (e) => new my({ radius: PR(e.radius, .08) })
77782
- }), AR("Polygon", {
77909
+ deserialize: (e) => new my({ radius: BR(e.radius, .08) })
77910
+ }), IR("Polygon", {
77783
77911
  serialize: (e) => ({
77784
77912
  vertices: e.getVertices().map((e) => [...e]),
77785
77913
  closed: e._closed
77786
77914
  }),
77787
77915
  deserialize: (e) => {
77788
- let t = BR(e.vertices);
77916
+ let t = KR(e.vertices);
77789
77917
  return new Gv({
77790
77918
  vertices: t.length >= 2 ? t : [[
77791
77919
  0,
@@ -77796,16 +77924,16 @@ function WR() {
77796
77924
  0,
77797
77925
  0
77798
77926
  ]],
77799
- closed: IR(e.closed, !0)
77927
+ closed: HR(e.closed, !0)
77800
77928
  });
77801
77929
  }
77802
- }), AR("Group", {
77930
+ }), IR("Group", {
77803
77931
  serialize: () => ({}),
77804
77932
  deserialize: () => new Qh()
77805
- }), AR("VGroup", {
77933
+ }), IR("VGroup", {
77806
77934
  serialize: () => ({}),
77807
77935
  deserialize: () => new L()
77808
- }), AR("Text", {
77936
+ }), IR("Text", {
77809
77937
  serialize: (e) => {
77810
77938
  let t = e;
77811
77939
  return {
@@ -77820,16 +77948,16 @@ function WR() {
77820
77948
  };
77821
77949
  },
77822
77950
  deserialize: (e) => new sh({
77823
- text: FR(e.text, ""),
77824
- fontSize: PR(e.fontSize, 48),
77825
- fontFamily: FR(e.fontFamily, "CMU Serif, Georgia, Times New Roman, serif"),
77826
- fontWeight: HR(e.fontWeight),
77827
- fontStyle: FR(e.fontStyle, "normal"),
77828
- lineHeight: PR(e.lineHeight, 1.2),
77829
- letterSpacing: PR(e.letterSpacing, 0),
77830
- textAlign: UR(e.textAlign)
77951
+ text: VR(e.text, ""),
77952
+ fontSize: BR(e.fontSize, 48),
77953
+ fontFamily: VR(e.fontFamily, "CMU Serif, Georgia, Times New Roman, serif"),
77954
+ fontWeight: JR(e.fontWeight),
77955
+ fontStyle: VR(e.fontStyle, "normal"),
77956
+ lineHeight: BR(e.lineHeight, 1.2),
77957
+ letterSpacing: BR(e.letterSpacing, 0),
77958
+ textAlign: YR(e.textAlign)
77831
77959
  })
77832
- }), AR("MathTex", {
77960
+ }), IR("MathTex", {
77833
77961
  serialize: (e) => {
77834
77962
  let t = e;
77835
77963
  return {
@@ -77839,15 +77967,15 @@ function WR() {
77839
77967
  };
77840
77968
  },
77841
77969
  deserialize: (e) => new wS({
77842
- latex: FR(e.latex, ""),
77843
- fontSize: PR(e.fontSize, 1),
77844
- displayMode: IR(e.displayMode, !0)
77970
+ latex: VR(e.latex, ""),
77971
+ fontSize: BR(e.fontSize, 1),
77972
+ displayMode: HR(e.displayMode, !0)
77845
77973
  })
77846
77974
  });
77847
77975
  }
77848
77976
  //#endregion
77849
77977
  //#region src/serialization/types.ts
77850
- var GR = "manim-web-scene", KR = {
77978
+ var ZR = "manim-web-scene", QR = {
77851
77979
  position: [
77852
77980
  0,
77853
77981
  0,
@@ -77864,7 +77992,7 @@ var GR = "manim-web-scene", KR = {
77864
77992
  1
77865
77993
  ]
77866
77994
  };
77867
- function qR(e) {
77995
+ function $R(e) {
77868
77996
  return {
77869
77997
  position: [
77870
77998
  e.position.x,
@@ -77883,98 +78011,98 @@ function qR(e) {
77883
78011
  ]
77884
78012
  };
77885
78013
  }
77886
- function JR(e) {
78014
+ function ez(e) {
77887
78015
  let t = {};
77888
78016
  return e.strokeColor !== void 0 && (t.strokeColor = e.strokeColor), e.fillColor !== void 0 && (t.fillColor = e.fillColor), typeof e.opacity == "number" && (t.strokeOpacity = e.opacity), typeof e.fillOpacity == "number" && (t.fillOpacity = e.fillOpacity), typeof e.strokeWidth == "number" && (t.strokeWidth = e.strokeWidth), t;
77889
78017
  }
77890
- function YR(e, t) {
77891
- let n = VR(t) ? t : {}, r = zR(n.position, KR.position), i = zR(n.rotation, KR.rotation), a = zR(n.scale, KR.scale);
78018
+ function tz(e, t) {
78019
+ let n = qR(t) ? t : {}, r = GR(n.position, QR.position), i = GR(n.rotation, QR.rotation), a = GR(n.scale, QR.scale);
77892
78020
  e.position.set(r[0], r[1], r[2]), e.rotation.set(i[0], i[1], i[2]), e.scaleVector.set(a[0], a[1], a[2]);
77893
78021
  }
77894
- function XR(e, t) {
77895
- let n = VR(t) ? t : {};
78022
+ function nz(e, t) {
78023
+ let n = qR(t) ? t : {};
77896
78024
  typeof n.strokeWidth == "number" && e.setStrokeWidth(n.strokeWidth), typeof n.strokeOpacity == "number" && e.setStrokeOpacity(n.strokeOpacity), typeof n.fillOpacity == "number" && e.setFillOpacity(n.fillOpacity);
77897
- let r = LR(n.strokeColor), i = LR(n.fillColor);
78025
+ let r = UR(n.strokeColor), i = UR(n.fillColor);
77898
78026
  r !== void 0 && (e.color = r), r !== void 0 && (e.strokeColor = r), i !== void 0 && (e.fillColor = i);
77899
78027
  }
77900
- function ZR(e) {
77901
- let t = e.constructor.name, n = MR(t), r = {
78028
+ function rz(e) {
78029
+ let t = e.constructor.name, n = RR(t), r = {
77902
78030
  type: t,
77903
78031
  props: n ? n.serialize(e) : {},
77904
- transform: qR(e),
77905
- style: JR(e),
77906
- children: e.children.map(ZR)
78032
+ transform: $R(e),
78033
+ style: ez(e),
78034
+ children: e.children.map(rz)
77907
78035
  };
77908
78036
  return n || (r.unknown = !0), r;
77909
78037
  }
77910
- function QR(e) {
77911
- if (!VR(e) || e.unknown === !0) return null;
77912
- let t = LR(e.type);
78038
+ function iz(e) {
78039
+ if (!qR(e) || e.unknown === !0) return null;
78040
+ let t = UR(e.type);
77913
78041
  if (t === void 0) return null;
77914
- let n = MR(t);
78042
+ let n = RR(t);
77915
78043
  if (!n) return null;
77916
- let r = VR(e.props) ? e.props : {}, i = n.deserialize(r);
77917
- if (YR(i, e.transform), XR(i, e.style), Array.isArray(e.children)) for (let t of e.children) {
77918
- let e = QR(t);
78044
+ let r = qR(e.props) ? e.props : {}, i = n.deserialize(r);
78045
+ if (tz(i, e.transform), nz(i, e.style), Array.isArray(e.children)) for (let t of e.children) {
78046
+ let e = iz(t);
77919
78047
  e && i.add(e);
77920
78048
  }
77921
78049
  return i;
77922
78050
  }
77923
- function $R(e) {
78051
+ function az(e) {
77924
78052
  let t = [];
77925
- for (let n of e.mobjects) t.push(ZR(n));
78053
+ for (let n of e.mobjects) t.push(rz(n));
77926
78054
  return {
77927
- format: GR,
78055
+ format: ZR,
77928
78056
  version: 1,
77929
78057
  mobjects: t
77930
78058
  };
77931
78059
  }
77932
- function ez(e, t) {
77933
- if (!VR(e) || !Array.isArray(e.mobjects)) return [];
78060
+ function oz(e, t) {
78061
+ if (!qR(e) || !Array.isArray(e.mobjects)) return [];
77934
78062
  let n = [];
77935
78063
  for (let r of e.mobjects) {
77936
- let e = QR(r);
78064
+ let e = iz(r);
77937
78065
  e && (t.add(e), n.push(e));
77938
78066
  }
77939
78067
  return n;
77940
78068
  }
77941
78069
  //#endregion
77942
78070
  //#region src/serialization/urlState.ts
77943
- var tz = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_", nz = (() => {
78071
+ var sz = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_", cz = (() => {
77944
78072
  let e = /* @__PURE__ */ new Map();
77945
- for (let t = 0; t < 64; t++) e.set(tz.charAt(t), t);
78073
+ for (let t = 0; t < 64; t++) e.set(sz.charAt(t), t);
77946
78074
  return e;
77947
78075
  })();
77948
- function rz(e) {
78076
+ function lz(e) {
77949
78077
  let t = "";
77950
78078
  for (let n = 0; n < e.length; n += 3) {
77951
78079
  let r = e[n], i = n + 1 < e.length, a = n + 2 < e.length, o = i ? e[n + 1] : 0, s = a ? e[n + 2] : 0, c = r << 16 | o << 8 | s;
77952
- t += tz.charAt(c >> 18 & 63), t += tz.charAt(c >> 12 & 63), i && (t += tz.charAt(c >> 6 & 63)), a && (t += tz.charAt(c & 63));
78080
+ t += sz.charAt(c >> 18 & 63), t += sz.charAt(c >> 12 & 63), i && (t += sz.charAt(c >> 6 & 63)), a && (t += sz.charAt(c & 63));
77953
78081
  }
77954
78082
  return t;
77955
78083
  }
77956
- function iz(e) {
78084
+ function uz(e) {
77957
78085
  let t = e.length;
77958
78086
  if (t % 4 == 1) return null;
77959
78087
  let n = [];
77960
78088
  for (let r = 0; r < t; r += 4) {
77961
- let i = Math.min(4, t - r), a = nz.get(e.charAt(r)), o = nz.get(e.charAt(r + 1));
78089
+ let i = Math.min(4, t - r), a = cz.get(e.charAt(r)), o = cz.get(e.charAt(r + 1));
77962
78090
  if (a === void 0 || o === void 0) return null;
77963
- let s = i > 2 ? nz.get(e.charAt(r + 2)) : 0, c = i > 3 ? nz.get(e.charAt(r + 3)) : 0;
78091
+ let s = i > 2 ? cz.get(e.charAt(r + 2)) : 0, c = i > 3 ? cz.get(e.charAt(r + 3)) : 0;
77964
78092
  if (s === void 0 || c === void 0) return null;
77965
78093
  let l = a << 18 | o << 12 | s << 6 | c;
77966
78094
  n.push(l >> 16 & 255), i > 2 && n.push(l >> 8 & 255), i > 3 && n.push(l & 255);
77967
78095
  }
77968
78096
  return Uint8Array.from(n);
77969
78097
  }
77970
- function az(e) {
78098
+ function dz(e) {
77971
78099
  let t = JSON.stringify(e), n = typeof t == "string" ? t : "null";
77972
- return rz(new TextEncoder().encode(n));
78100
+ return lz(new TextEncoder().encode(n));
77973
78101
  }
77974
- function oz(e) {
78102
+ function fz(e) {
77975
78103
  let t = e.startsWith("#") ? e.slice(1) : e;
77976
78104
  if (t.length === 0) return null;
77977
- let n = iz(t);
78105
+ let n = uz(t);
77978
78106
  if (n === null) return null;
77979
78107
  try {
77980
78108
  let e = new TextDecoder().decode(n);
@@ -77983,18 +78111,18 @@ function oz(e) {
77983
78111
  return null;
77984
78112
  }
77985
78113
  }
77986
- function sz() {
78114
+ function pz() {
77987
78115
  return typeof window < "u" && window.location ? window.location : null;
77988
78116
  }
77989
- function cz() {
78117
+ function mz() {
77990
78118
  return typeof window < "u" && window.history ? window.history : null;
77991
78119
  }
77992
- function lz(e, t = {}) {
77993
- let n = sz();
78120
+ function hz(e, t = {}) {
78121
+ let n = pz();
77994
78122
  if (!n) return;
77995
- let r = az(e), i = `#${r}`;
78123
+ let r = dz(e), i = `#${r}`;
77996
78124
  if (t.replace) {
77997
- let e = cz();
78125
+ let e = mz();
77998
78126
  if (e && typeof e.replaceState == "function") {
77999
78127
  e.replaceState(e.state ?? null, "", i);
78000
78128
  return;
@@ -78002,29 +78130,29 @@ function lz(e, t = {}) {
78002
78130
  }
78003
78131
  n.hash = r;
78004
78132
  }
78005
- function uz() {
78006
- let e = sz();
78007
- return e ? oz(e.hash) : null;
78133
+ function gz() {
78134
+ let e = pz();
78135
+ return e ? fz(e.hash) : null;
78008
78136
  }
78009
- function dz(e) {
78137
+ function _z(e) {
78010
78138
  if (typeof window > "u" || typeof window.addEventListener != "function") return () => void 0;
78011
- let t = () => e(uz());
78139
+ let t = () => e(gz());
78012
78140
  return window.addEventListener("hashchange", t), () => window.removeEventListener("hashchange", t);
78013
78141
  }
78014
- function fz(e) {
78142
+ function vz(e) {
78015
78143
  let t = {};
78016
78144
  for (let n of e) t[n.id] = n.get();
78017
78145
  return t;
78018
78146
  }
78019
- function pz(e, t) {
78147
+ function yz(e, t) {
78020
78148
  if (typeof t != "object" || !t || Array.isArray(t)) return !1;
78021
78149
  let n = t, r = !1;
78022
78150
  for (let t of e) Object.prototype.hasOwnProperty.call(n, t.id) && (t.set(n[t.id]), r = !0);
78023
78151
  return r;
78024
78152
  }
78025
- function mz(e, t = {}) {
78026
- let { replace: n = !0, restoreOnBind: r = !0, listen: i = !0 } = t, a = () => fz(e), o = () => lz(a(), { replace: n }), s = () => pz(e, uz()), c = null;
78027
- return r && s(), i && (c = dz((t) => pz(e, t))), {
78153
+ function bz(e, t = {}) {
78154
+ let { replace: n = !0, restoreOnBind: r = !0, listen: i = !0 } = t, a = () => vz(e), o = () => hz(a(), { replace: n }), s = () => yz(e, gz()), c = null;
78155
+ return r && s(), i && (c = _z((t) => yz(e, t))), {
78028
78156
  capture: a,
78029
78157
  save: o,
78030
78158
  restore: s,
@@ -78035,13 +78163,13 @@ function mz(e, t = {}) {
78035
78163
  }
78036
78164
  //#endregion
78037
78165
  //#region src/serialization/parametrized.ts
78038
- function hz(e) {
78166
+ function xz(e) {
78039
78167
  return Array.isArray(e) && e.length === 3 && e.every((e) => typeof e == "number" && Number.isFinite(e));
78040
78168
  }
78041
- function gz(e) {
78042
- return typeof e == "number" ? "number" : typeof e == "string" ? "string" : typeof e == "boolean" ? "boolean" : hz(e) ? "vec3" : Array.isArray(e) ? "array" : VR(e) ? "object" : null;
78169
+ function Sz(e) {
78170
+ return typeof e == "number" ? "number" : typeof e == "string" ? "string" : typeof e == "boolean" ? "boolean" : xz(e) ? "vec3" : Array.isArray(e) ? "array" : qR(e) ? "object" : null;
78043
78171
  }
78044
- function _z(e, t, n) {
78172
+ function Cz(e, t, n) {
78045
78173
  switch (t) {
78046
78174
  case "number":
78047
78175
  if (typeof e == "number" && Number.isFinite(e)) return e;
@@ -78052,46 +78180,46 @@ function _z(e, t, n) {
78052
78180
  return typeof e == "boolean" ? +!!e : n;
78053
78181
  case "string": return typeof e == "string" ? e : typeof e == "number" && Number.isFinite(e) || typeof e == "boolean" ? String(e) : n;
78054
78182
  case "boolean": return typeof e == "boolean" ? e : e === "true" ? !0 : e === "false" ? !1 : typeof e == "number" && Number.isFinite(e) ? e !== 0 : n;
78055
- case "vec3": return zR(e, hz(n) ? n : [
78183
+ case "vec3": return GR(e, xz(n) ? n : [
78056
78184
  0,
78057
78185
  0,
78058
78186
  0
78059
78187
  ]);
78060
78188
  case "array": return Array.isArray(e) ? e : n;
78061
- case "object": return VR(e) ? e : n;
78189
+ case "object": return qR(e) ? e : n;
78062
78190
  }
78063
78191
  }
78064
- function vz(e, t, n) {
78065
- let r = e.defaultProps[t], i = e.schema?.[t] ?? gz(r);
78066
- return i === null ? n === void 0 ? r : n : _z(n, i, r);
78192
+ function wz(e, t, n) {
78193
+ let r = e.defaultProps[t], i = e.schema?.[t] ?? Sz(r);
78194
+ return i === null ? n === void 0 ? r : n : Cz(n, i, r);
78067
78195
  }
78068
- function yz(e, t, n) {
78196
+ function Tz(e, t, n) {
78069
78197
  let r = { ...t };
78070
- if (n) for (let t of Object.keys(n)) Object.prototype.hasOwnProperty.call(e.defaultProps, t) && (r[t] = vz(e, t, n[t]));
78198
+ if (n) for (let t of Object.keys(n)) Object.prototype.hasOwnProperty.call(e.defaultProps, t) && (r[t] = wz(e, t, n[t]));
78071
78199
  return r;
78072
78200
  }
78073
- function bz(e) {
78201
+ function Ez(e) {
78074
78202
  return e;
78075
78203
  }
78076
- function xz(e, t) {
78077
- return yz(e, { ...e.defaultProps }, t);
78204
+ function Dz(e, t) {
78205
+ return Tz(e, { ...e.defaultProps }, t);
78078
78206
  }
78079
- function Sz(e) {
78080
- let t = uz();
78081
- return xz(e, VR(t) ? t : void 0);
78207
+ function Oz(e) {
78208
+ let t = gz();
78209
+ return Dz(e, qR(t) ? t : void 0);
78082
78210
  }
78083
- var Cz = async (e, t) => {
78211
+ var kz = async (e, t) => {
78084
78212
  if (typeof fetch != "function") throw Error("renderParametrized: no global fetch available. Pass options.fetch to inject one.");
78085
78213
  let n = await fetch(e, t);
78086
78214
  if (!n.ok) throw Error(`renderParametrized: fetch failed for ${e} (status ${n.status})`);
78087
78215
  return n.json();
78088
78216
  };
78089
- function wz(e, t) {
78217
+ function Az(e, t) {
78090
78218
  let n = t.width ?? e.renderer.width, r = t.height ?? e.renderer.height;
78091
78219
  (n !== e.renderer.width || r !== e.renderer.height) && e.resize(n, r), typeof t.fps == "number" && Number.isFinite(t.fps) && e.setTargetFps(t.fps);
78092
78220
  }
78093
- async function Tz(e, t, n = {}) {
78094
- let r = n.fetch ?? Cz, i = xz(e, t), a, o = {};
78221
+ async function jz(e, t, n = {}) {
78222
+ let r = n.fetch ?? kz, i = Dz(e, t), a, o = {};
78095
78223
  if (e.calculateMetadata) {
78096
78224
  let t = await e.calculateMetadata({
78097
78225
  props: i,
@@ -78102,7 +78230,7 @@ async function Tz(e, t, n = {}) {
78102
78230
  width: t.width,
78103
78231
  height: t.height,
78104
78232
  fps: t.fps
78105
- }, t.props && (i = yz(e, i, t.props));
78233
+ }, t.props && (i = Tz(e, i, t.props));
78106
78234
  }
78107
78235
  let s = n.scene;
78108
78236
  s ||= jg.createHeadless({
@@ -78110,9 +78238,9 @@ async function Tz(e, t, n = {}) {
78110
78238
  ...o.width === void 0 ? {} : { width: o.width },
78111
78239
  ...o.height === void 0 ? {} : { height: o.height },
78112
78240
  ...o.fps === void 0 ? {} : { targetFps: o.fps }
78113
- }), wz(s, o);
78114
- let c = az(i);
78115
- return n.writeUrl && lz(i, { replace: n.urlReplace ?? !0 }), await e.build(s, i, a), {
78241
+ }), Az(s, o);
78242
+ let c = dz(i);
78243
+ return n.writeUrl && hz(i, { replace: n.urlReplace ?? !0 }), await e.build(s, i, a), {
78116
78244
  scene: s,
78117
78245
  props: i,
78118
78246
  data: a,
@@ -78127,10 +78255,10 @@ async function Tz(e, t, n = {}) {
78127
78255
  }
78128
78256
  //#endregion
78129
78257
  //#region src/serialization/index.ts
78130
- WR();
78258
+ XR();
78131
78259
  //#endregion
78132
78260
  //#region src/mobjects/geo/geojson.ts
78133
- function Ez(e) {
78261
+ function Mz(e) {
78134
78262
  if (e.type === "Polygon") {
78135
78263
  let t = e.coordinates[0];
78136
78264
  return t ? [t] : [];
@@ -78144,26 +78272,26 @@ function Ez(e) {
78144
78272
  }
78145
78273
  //#endregion
78146
78274
  //#region src/mobjects/geo/projections.ts
78147
- var Dz = Math.PI / 180;
78148
- function Oz(e = {}) {
78149
- let { radius: t = 1, centerLon: n = 0, centerLat: r = 0, standardParallel: i = 0 } = e, a = Math.cos(i * Dz);
78150
- return ([e, i]) => [(e - n) * Dz * t * a, (i - r) * Dz * t];
78275
+ var Nz = Math.PI / 180;
78276
+ function Pz(e = {}) {
78277
+ let { radius: t = 1, centerLon: n = 0, centerLat: r = 0, standardParallel: i = 0 } = e, a = Math.cos(i * Nz);
78278
+ return ([e, i]) => [(e - n) * Nz * t * a, (i - r) * Nz * t];
78151
78279
  }
78152
- function kz(e = {}) {
78280
+ function Fz(e = {}) {
78153
78281
  let { radius: t = 1, centerLon: n = 0, maxLatitude: r = 85.05112878 } = e;
78154
78282
  return ([e, i]) => {
78155
- let a = Math.max(-r, Math.min(r, i)) * Dz;
78156
- return [(e - n) * Dz * t, t * Math.log(Math.tan(Math.PI / 4 + a / 2))];
78283
+ let a = Math.max(-r, Math.min(r, i)) * Nz;
78284
+ return [(e - n) * Nz * t, t * Math.log(Math.tan(Math.PI / 4 + a / 2))];
78157
78285
  };
78158
78286
  }
78159
78287
  //#endregion
78160
78288
  //#region src/mobjects/geo/colorScale.ts
78161
- var Az = ["#0d1b2a", "#4cc9f0"], jz = class {
78289
+ var Iz = ["#0d1b2a", "#4cc9f0"], Lz = class {
78162
78290
  _palette;
78163
78291
  _domain;
78164
78292
  constructor(e = {}) {
78165
- let { colors: t = Az, domain: n = [0, 1], samples: r = 256 } = e, i = Math.max(2, Math.floor(r));
78166
- this._palette = Ua(t.length > 0 ? t : Az, i), this._domain = [n[0], n[1]];
78293
+ let { colors: t = Iz, domain: n = [0, 1], samples: r = 256 } = e, i = Math.max(2, Math.floor(r));
78294
+ this._palette = Ua(t.length > 0 ? t : Iz, i), this._domain = [n[0], n[1]];
78167
78295
  }
78168
78296
  setDomainFromValues(e) {
78169
78297
  let t = Infinity, n = -Infinity;
@@ -78179,7 +78307,7 @@ var Az = ["#0d1b2a", "#4cc9f0"], jz = class {
78179
78307
  let a = Math.round(i * (this._palette.length - 1));
78180
78308
  return this._palette[a];
78181
78309
  }
78182
- }, Mz = class extends Qh {
78310
+ }, Rz = class extends Qh {
78183
78311
  _projection;
78184
78312
  _colorScale;
78185
78313
  _regions = [];
@@ -78187,10 +78315,10 @@ var Az = ["#0d1b2a", "#4cc9f0"], jz = class {
78187
78315
  _regionPolygons = [];
78188
78316
  constructor(e) {
78189
78317
  super();
78190
- let { geojson: t, value: n, colorScale: r = ["#0d1b2a", "#4cc9f0"], domain: i, fillOpacity: a = 1, noDataColor: o = pe, borderColor: s = "#1b263b", borderWidth: c = 1, projection: l = Oz() } = e;
78318
+ let { geojson: t, value: n, colorScale: r = ["#0d1b2a", "#4cc9f0"], domain: i, fillOpacity: a = 1, noDataColor: o = pe, borderColor: s = "#1b263b", borderWidth: c = 1, projection: l = Pz() } = e;
78191
78319
  this._projection = l;
78192
78320
  let u = t.features ?? [], d = u.map((e, t) => n(e, t));
78193
- this._colorScale = new jz({
78321
+ this._colorScale = new Lz({
78194
78322
  colors: r,
78195
78323
  domain: i
78196
78324
  }), i || this._colorScale.setDomainFromValues(d.filter((e) => typeof e == "number" && Number.isFinite(e))), u.forEach((e, t) => {
@@ -78203,7 +78331,7 @@ var Az = ["#0d1b2a", "#4cc9f0"], jz = class {
78203
78331
  });
78204
78332
  }
78205
78333
  _buildRegion(e, t, n) {
78206
- let r = typeof t == "number" && Number.isFinite(t) ? this._colorScale.colorFor(t) : n.noDataColor, i = Ez(e.geometry), a = [];
78334
+ let r = typeof t == "number" && Number.isFinite(t) ? this._colorScale.colorFor(t) : n.noDataColor, i = Mz(e.geometry), a = [];
78207
78335
  for (let e of i) {
78208
78336
  let t = this._buildPolygon(e, r, n);
78209
78337
  t && a.push(t);
@@ -78212,7 +78340,7 @@ var Az = ["#0d1b2a", "#4cc9f0"], jz = class {
78212
78340
  this.add(o), this._regions.push(o), this._regionColors.push(r), this._regionPolygons.push(a);
78213
78341
  }
78214
78342
  _buildPolygon(e, t, n) {
78215
- let r = Pz(e);
78343
+ let r = Bz(e);
78216
78344
  if (r.length < 3) return null;
78217
78345
  let i = new Gv({
78218
78346
  vertices: r.map((e) => {
@@ -78248,15 +78376,15 @@ var Az = ["#0d1b2a", "#4cc9f0"], jz = class {
78248
78376
  getColorScale() {
78249
78377
  return this._colorScale;
78250
78378
  }
78251
- }, Nz = Mz;
78252
- function Pz(e) {
78379
+ }, zz = Rz;
78380
+ function Bz(e) {
78253
78381
  if (e.length < 2) return e;
78254
78382
  let t = e[0], n = e[e.length - 1];
78255
78383
  return t[0] === n[0] && t[1] === n[1] ? e.slice(0, -1) : e;
78256
78384
  }
78257
78385
  //#endregion
78258
78386
  //#region src/mobjects/geo/Globe.ts
78259
- var Fz = Math.PI / 180, Iz = class extends Qh {
78387
+ var Vz = Math.PI / 180, Hz = class extends Qh {
78260
78388
  _radius;
78261
78389
  _center;
78262
78390
  _sphere;
@@ -78304,9 +78432,9 @@ var Fz = Math.PI / 180, Iz = class extends Qh {
78304
78432
  return [...this._plottedPoints];
78305
78433
  }
78306
78434
  arc(e, t, n = {}) {
78307
- let { segments: r = 64, color: i = "#ef476f", lineWidth: a = 2, altitude: o = 0 } = n, s = this._radius * (1 + o), c = Lz(e[0], e[1]), l = Lz(t[0], t[1]), u = Bz(c[0] * l[0] + c[1] * l[1] + c[2] * l[2], -1, 1), d = Math.acos(u), f = Math.sin(d), p = [];
78435
+ let { segments: r = 64, color: i = "#ef476f", lineWidth: a = 2, altitude: o = 0 } = n, s = this._radius * (1 + o), c = Uz(e[0], e[1]), l = Uz(t[0], t[1]), u = Kz(c[0] * l[0] + c[1] * l[1] + c[2] * l[2], -1, 1), d = Math.acos(u), f = Math.sin(d), p = [];
78308
78436
  for (let e = 0; e <= r; e++) {
78309
- let t = Rz(c, l, e / r, d, f);
78437
+ let t = Wz(c, l, e / r, d, f);
78310
78438
  p.push([
78311
78439
  this._center[0] + s * t[0],
78312
78440
  this._center[1] + s * t[1],
@@ -78323,8 +78451,8 @@ var Fz = Math.PI / 180, Iz = class extends Qh {
78323
78451
  }
78324
78452
  graticule(e = {}) {
78325
78453
  let { latStep: t = 30, lonStep: n = 30, segments: r = 48, color: i = "#8d99ae", lineWidth: a = 1 } = e, o = new Qh();
78326
- for (let e = -180; e < 180; e += n) o.add(this._gridLine(Vz(e, r), i, a));
78327
- for (let e = -90 + t; e < 90; e += t) o.add(this._gridLine(Hz(e, r), i, a));
78454
+ for (let e = -180; e < 180; e += n) o.add(this._gridLine(qz(e, r), i, a));
78455
+ for (let e = -90 + t; e < 90; e += t) o.add(this._gridLine(Jz(e, r), i, a));
78328
78456
  return this.add(o), o;
78329
78457
  }
78330
78458
  _gridLine(e, t, n) {
@@ -78336,7 +78464,7 @@ var Fz = Math.PI / 180, Iz = class extends Qh {
78336
78464
  });
78337
78465
  }
78338
78466
  _surfacePoint(e, t, n) {
78339
- let r = Lz(e, t);
78467
+ let r = Uz(e, t);
78340
78468
  return [
78341
78469
  this._center[0] + n * r[0],
78342
78470
  this._center[1] + n * r[1],
@@ -78344,16 +78472,16 @@ var Fz = Math.PI / 180, Iz = class extends Qh {
78344
78472
  ];
78345
78473
  }
78346
78474
  };
78347
- function Lz(e, t) {
78348
- let n = e * Fz, r = t * Fz, i = Math.cos(n);
78475
+ function Uz(e, t) {
78476
+ let n = e * Vz, r = t * Vz, i = Math.cos(n);
78349
78477
  return [
78350
78478
  i * Math.cos(r),
78351
78479
  i * Math.sin(r),
78352
78480
  Math.sin(n)
78353
78481
  ];
78354
78482
  }
78355
- function Rz(e, t, n, r, i) {
78356
- if (i < 1e-9) return zz([
78483
+ function Wz(e, t, n, r, i) {
78484
+ if (i < 1e-9) return Gz([
78357
78485
  e[0] + (t[0] - e[0]) * n,
78358
78486
  e[1] + (t[1] - e[1]) * n,
78359
78487
  e[2] + (t[2] - e[2]) * n
@@ -78365,7 +78493,7 @@ function Rz(e, t, n, r, i) {
78365
78493
  e[2] * a + t[2] * o
78366
78494
  ];
78367
78495
  }
78368
- function zz(e) {
78496
+ function Gz(e) {
78369
78497
  let t = Math.sqrt(e[0] * e[0] + e[1] * e[1] + e[2] * e[2]) || 1;
78370
78498
  return [
78371
78499
  e[0] / t,
@@ -78373,44 +78501,44 @@ function zz(e) {
78373
78501
  e[2] / t
78374
78502
  ];
78375
78503
  }
78376
- function Bz(e, t, n) {
78504
+ function Kz(e, t, n) {
78377
78505
  return Math.max(t, Math.min(n, e));
78378
78506
  }
78379
- function Vz(e, t) {
78507
+ function qz(e, t) {
78380
78508
  let n = [];
78381
78509
  for (let r = 0; r <= t; r++) n.push([-90 + 180 * r / t, e]);
78382
78510
  return n;
78383
78511
  }
78384
- function Hz(e, t) {
78512
+ function Jz(e, t) {
78385
78513
  let n = [];
78386
78514
  for (let r = 0; r <= t; r++) n.push([e, -180 + 360 * r / t]);
78387
78515
  return n;
78388
78516
  }
78389
78517
  //#endregion
78390
78518
  //#region src/mobjects/ml/mlStyles.ts
78391
- var Uz = {
78519
+ var Yz = {
78392
78520
  color: be,
78393
78521
  fillColor: be,
78394
78522
  fillOpacity: .3,
78395
78523
  strokeWidth: 2
78396
- }, Wz = {
78524
+ }, Xz = {
78397
78525
  color: pe,
78398
78526
  strokeWidth: 1.5,
78399
78527
  opacity: .35
78400
- }, Gz = E;
78401
- function Kz(e, t) {
78528
+ }, Zz = E;
78529
+ function Qz(e, t) {
78402
78530
  return {
78403
78531
  ...e,
78404
- ...Jz(t)
78532
+ ...eB(t)
78405
78533
  };
78406
78534
  }
78407
- function qz(e, t) {
78535
+ function $z(e, t) {
78408
78536
  return {
78409
78537
  ...e,
78410
- ...Jz(t)
78538
+ ...eB(t)
78411
78539
  };
78412
78540
  }
78413
- function Jz(e) {
78541
+ function eB(e) {
78414
78542
  if (!e) return {};
78415
78543
  let t = {};
78416
78544
  for (let n of Object.keys(e)) e[n] !== void 0 && (t[n] = e[n]);
@@ -78418,7 +78546,7 @@ function Jz(e) {
78418
78546
  }
78419
78547
  //#endregion
78420
78548
  //#region src/mobjects/ml/NeuralNetworkLayer.ts
78421
- var Yz = class extends L {
78549
+ var tB = class extends L {
78422
78550
  _nodes = [];
78423
78551
  normalizeTransform(e = this._ownMatrix()) {
78424
78552
  return this._flattenAsContainer(e);
@@ -78432,14 +78560,14 @@ var Yz = class extends L {
78432
78560
  nodeAnchors() {
78433
78561
  return this._nodes.map((e) => e.getCenter());
78434
78562
  }
78435
- }, Xz = class extends Yz {
78563
+ }, nB = class extends tB {
78436
78564
  _nodeRadius;
78437
78565
  _nodeSpacing;
78438
78566
  _nodeStyle;
78439
78567
  constructor(e = {}) {
78440
78568
  super();
78441
78569
  let t = e.numNodes ?? 3, n = Math.max(0, Math.floor(t));
78442
- this._nodeRadius = e.nodeRadius ?? .25, this._nodeSpacing = e.nodeSpacing ?? .7, this._nodeStyle = Kz(Uz, e.nodeStyle), this._buildNodes(n);
78570
+ this._nodeRadius = e.nodeRadius ?? .25, this._nodeSpacing = e.nodeSpacing ?? .7, this._nodeStyle = Qz(Yz, e.nodeStyle), this._buildNodes(n);
78443
78571
  }
78444
78572
  _buildNodes(e) {
78445
78573
  if (e === 0) return;
@@ -78468,7 +78596,7 @@ var Yz = class extends L {
78468
78596
  };
78469
78597
  //#endregion
78470
78598
  //#region src/mobjects/ml/featureMapStack.ts
78471
- function Zz(e) {
78599
+ function rB(e) {
78472
78600
  let { numFeatureMaps: t, mapSize: n, offset: r, style: i } = e, a = Math.max(0, Math.floor(t)), o = a > 0 ? (a - 1) * r : 0, s = n + o, c = [];
78473
78601
  for (let e = 0; e < a; e++) {
78474
78602
  let t = -o / 2 + e * r, a = o / 2 - e * r, s = new l_({
@@ -78492,15 +78620,15 @@ function Zz(e) {
78492
78620
  }
78493
78621
  //#endregion
78494
78622
  //#region src/mobjects/ml/ConvolutionalLayer.ts
78495
- var Qz = class extends Yz {
78623
+ var iB = class extends tB {
78496
78624
  _width;
78497
78625
  constructor(e = {}) {
78498
78626
  super();
78499
- let { nodes: t, width: n } = Zz({
78627
+ let { nodes: t, width: n } = rB({
78500
78628
  numFeatureMaps: e.numFeatureMaps ?? 3,
78501
78629
  mapSize: e.mapSize ?? .5,
78502
78630
  offset: e.offset ?? .15,
78503
- style: Kz(Uz, e.nodeStyle)
78631
+ style: Qz(Yz, e.nodeStyle)
78504
78632
  });
78505
78633
  this._width = n;
78506
78634
  for (let e of t) this._nodes.push(e), this.add(e);
@@ -78508,15 +78636,15 @@ var Qz = class extends Yz {
78508
78636
  layerWidth() {
78509
78637
  return this._width;
78510
78638
  }
78511
- }, $z = class extends Yz {
78639
+ }, aB = class extends tB {
78512
78640
  _width;
78513
78641
  constructor(e = {}) {
78514
78642
  super();
78515
- let { nodes: t, width: n } = Zz({
78643
+ let { nodes: t, width: n } = rB({
78516
78644
  numFeatureMaps: e.numFeatureMaps ?? 3,
78517
78645
  mapSize: e.mapSize ?? .3,
78518
78646
  offset: e.offset ?? .12,
78519
- style: Kz(Uz, e.nodeStyle)
78647
+ style: Qz(Yz, e.nodeStyle)
78520
78648
  });
78521
78649
  this._width = n;
78522
78650
  for (let e of t) this._nodes.push(e), this.add(e);
@@ -78524,7 +78652,7 @@ var Qz = class extends Yz {
78524
78652
  layerWidth() {
78525
78653
  return this._width;
78526
78654
  }
78527
- }, eB = class extends Yz {
78655
+ }, oB = class extends tB {
78528
78656
  _cols;
78529
78657
  _cellSize;
78530
78658
  _grid;
@@ -78532,7 +78660,7 @@ var Qz = class extends Yz {
78532
78660
  super();
78533
78661
  let t = Math.max(0, Math.floor(e.rows ?? 3));
78534
78662
  this._cols = Math.max(0, Math.floor(e.cols ?? 3)), this._cellSize = e.cellSize ?? .25;
78535
- let n = Kz(Uz, e.nodeStyle);
78663
+ let n = Qz(Yz, e.nodeStyle);
78536
78664
  this._grid = this._buildGrid(t, this._cols, n), this.add(this._grid), t > 0 && this._cols > 0 && this._nodes.push(this._grid);
78537
78665
  }
78538
78666
  _buildGrid(e, t, n) {
@@ -78557,13 +78685,13 @@ var Qz = class extends Yz {
78557
78685
  layerWidth() {
78558
78686
  return Math.max(this._cols, 1) * this._cellSize;
78559
78687
  }
78560
- }, tB = class extends L {
78688
+ }, sB = class extends L {
78561
78689
  _layers;
78562
78690
  _connections = [];
78563
78691
  _stages = [];
78564
78692
  _edgeStyle;
78565
78693
  constructor(e = [], t = {}) {
78566
- super(), this._layers = [...e], this._edgeStyle = qz(Wz, t.edgeStyle);
78694
+ super(), this._layers = [...e], this._edgeStyle = $z(Xz, t.edgeStyle);
78567
78695
  let n = t.layerSpacing ?? 1, r = t.connectAdjacent ?? !0;
78568
78696
  this._placeLayers(n), r && this._buildConnections();
78569
78697
  for (let e of this._connections) this.add(e);
@@ -78610,7 +78738,7 @@ var Qz = class extends Yz {
78610
78738
  getConnectionStages() {
78611
78739
  return this._stages.map((e) => [...e]);
78612
78740
  }
78613
- }, nB = class extends z {
78741
+ }, cB = class extends z {
78614
78742
  activation = 0;
78615
78743
  _activationColor;
78616
78744
  _peakOpacity;
@@ -78621,7 +78749,7 @@ var Qz = class extends Yz {
78621
78749
  super(e, {
78622
78750
  duration: t.duration ?? 1,
78623
78751
  rateFunc: t.rateFunc ?? (t.restore ? Fo : void 0)
78624
- }), this._activationColor = t.activationColor ?? Gz, this._peakOpacity = t.peakOpacity ?? 1, this._restore = t.restore ?? !1;
78752
+ }), this._activationColor = t.activationColor ?? Zz, this._peakOpacity = t.peakOpacity ?? 1, this._restore = t.restore ?? !1;
78625
78753
  }
78626
78754
  begin() {
78627
78755
  super.begin(), this._baseOpacity = this.mobject.opacity, this._baseColor = this.mobject.color, this.activation = 0;
@@ -78637,12 +78765,12 @@ var Qz = class extends Yz {
78637
78765
  this._restore ? (this.mobject.setStrokeOpacity(this._baseOpacity), this.mobject.setColor(this._baseColor), this.activation = 0) : this.activation = 1, this.mobject._markDirty(), super.finish();
78638
78766
  }
78639
78767
  };
78640
- function rB(e, t) {
78641
- return new nB(e, t);
78768
+ function lB(e, t) {
78769
+ return new cB(e, t);
78642
78770
  }
78643
78771
  //#endregion
78644
78772
  //#region src/mobjects/ml/forwardPass.ts
78645
- function iB(e, t, n) {
78773
+ function uB(e, t, n) {
78646
78774
  let r = e.getConnectionStages(), i = t ? [...r].reverse() : r, a = {
78647
78775
  duration: n.gapDuration ?? 1,
78648
78776
  activationColor: n.activationColor,
@@ -78650,13 +78778,13 @@ function iB(e, t, n) {
78650
78778
  restore: n.restore,
78651
78779
  rateFunc: n.rateFunc
78652
78780
  };
78653
- return i.map((e) => new og(e.map((e) => new nB(e, a)), { lagRatio: 0 }));
78781
+ return i.map((e) => new og(e.map((e) => new cB(e, a)), { lagRatio: 0 }));
78654
78782
  }
78655
- function aB(e, t = {}) {
78656
- return new jM(iB(e, !1, t), { lagRatio: t.lagRatio ?? 1 });
78783
+ function dB(e, t = {}) {
78784
+ return new jM(uB(e, !1, t), { lagRatio: t.lagRatio ?? 1 });
78657
78785
  }
78658
- function oB(e, t = {}) {
78659
- return new jM(iB(e, !0, t), { lagRatio: t.lagRatio ?? 1 });
78786
+ function fB(e, t = {}) {
78787
+ return new jM(uB(e, !0, t), { lagRatio: t.lagRatio ?? 1 });
78660
78788
  }
78661
78789
  //#endregion
78662
- export { eR as $, ft as $_, ij as $a, iT as $c, Fy as $d, Ev as $f, St as $g, yr as $h, kM as $i, xC as $l, ss as $m, YP as $n, xk as $o, ng as $p, LN as $r, mD as $s, GI as $t, px as $u, az as A, me as A_, Ej as Aa, TE as Ac, _b as Ad, $v as Af, Xt as Ag, zo as Ah, ZM as Ai, aw as Al, Jp as Am, WF as An, dA as Ao, jg as Ap, tP as Ar, zD as As, wL as At, Zx as Au, Te as Av, AR as B, pe as B_, Tj as Ba, PT as Bc, Xy as Bd, Uv as Bf, on as Bg, co as Bh, qM as Bi, FC as Bl, Do as Bm, DF as Bn, Kk as Bo, hg as Bp, WN as Br, vD as Bs, fL as Bt, Rx as Bu, Ez as C, de as C_, Wj as Ca, EE as Cc, Vb as Cd, cy as Cf, _n as Cg, Io as Ch, rN as Ci, _w as Cl, Im as Cm, TI as Cn, AA as Co, l_ as Cp, lP as Cr, mO as Cs, _L as Ct, AS as Cu, Je as Cv, xz as D, _e as D_, Ij as Da, bE as Dc, Ob as Dd, ny as Df, dn as Dg, $o as Dh, eN as Di, uw as Dl, cm as Dm, uI as Dn, SA as Do, Pg as Dp, aP as Dr, sO as Ds, TL as Dt, vS as Du, Se as Dv, Tz as E, ge as E_, Nj as Ea, wE as Ec, Db as Ed, ry as Ef, Sn as Eg, es as Eh, nN as Ei, pw as El, um as Em, dI as En, wA as Eo, a_ as Ep, iP as Er, cO as Es, rL as Et, TS as Eu, De as Ev, ez as F, Be as F_, wj as Fa, XT as Fc, fb as Fd, Yv as Ff, sn as Fg, yo as Fh, zM as Fi, GC as Fl, Os as Fm, VF as Fn, tA as Fo, kg as Fp, ZN as Fr, wD as Fs, cL as Ft, Wx as Fu, Ie as Fv, _R as G, ue as G_, cj as Ga, mT as Gc, Qy as Gd, Bv as Gf, Ft as Gg, Na as Gh, AM as Gi, CC as Gl, jo as Gm, mF as Gn, Bk as Go, mg as Gp, BN as Gr, sD as Gs, DL as Gt, jx as Gu, OR as H, ce as H_, lj as Ha, OT as Hc, qy as Hd, zv as Hf, rn as Hg, I as Hh, PM as Hi, DC as Hl, Po as Hm, TF as Hn, Wk as Ho, _g as Hp, HN as Hr, _D as Hs, lL as Ht, Px as Hu, ZR as I, Ve as I_, Cj as Ia, GT as Ic, ub as Id, Gv as If, cn as Ig, bo as Ih, XM as Ii, UC as Il, Es as Im, HF as In, nA as Io, Dg as Ip, JN as Ir, ED as Is, oL as It, Ux as Iu, Le as Iv, vR as J, ke as J_, fj as Ja, uT as Jc, Ly as Jd, jv as Jf, Ct as Jg, kr as Jh, EM as Ji, NC as Jl, Ts as Jm, sF as Jn, Vk as Jo, dg as Jp, IN as Jr, pD as Js, pL as Jt, Cx as Ju, SR as K, Pe as K_, uj as Ka, dT as Kc, Zy as Kd, Lv as Kf, qt as Kg, La as Kh, SM as Ki, jC as Kl, Eo as Km, uF as Kn, zk as Ko, pg as Kp, PN as Kr, lD as Ks, kL as Kt, Tx as Ku, $R as L, He as L_, xj as La, qT as Lc, mb as Ld, qv as Lf, en as Lg, So as Lh, MM as Li, RC as Ll, z as Lm, PF as Ln, eA as Lo, wg as Lp, YN as Lr, DD as Ls, aL as Lt, Ix as Lu, Re as Lv, uz as M, pt as M_, bj as Ma, oE as Mc, gb as Md, Zv as Mf, tn as Mg, Ko as Mh, GM as Mi, tw as Ml, Kp as Mm, RF as Mn, lA as Mo, Eg as Mp, QN as Mr, FD as Ms, nL as Mt, Jx as Mu, E as Mv, lz as N, A as N_, gj as Na, eE as Nc, pb as Nd, Xv as Nf, Qt as Ng, Jo as Nh, UM as Ni, YC as Nl, Wp as Nm, zF as Nn, uA as No, Tg as Np, $N as Nr, TD as Ns, iL as Nt, qx as Nu, ze as Nv, mz as O, ve as O_, Pj as Oa, xE as Oc, Eb as Od, ty as Of, ln as Og, Qo as Oh, $M as Oi, sw as Ol, lm as Om, oI as On, yA as Oo, Ng as Op, eP as Or, lO as Os, gL as Ot, nS as Ou, Ce as Ov, QR as P, Ge as P_, vj as Pa, $T as Pc, db as Pd, Jv as Pf, Zt as Pg, vo as Ph, FM as Pi, qC as Pl, Hp as Pm, LF as Pn, iA as Po, Cg as Pp, XN as Pr, CD as Ps, AL as Pt, Xx as Pu, Fe as Pv, ZL as Q, k as Q_, nj as Qa, rT as Qc, Iy as Qd, Tv as Qf, Vt as Qg, br as Qh, DM as Qi, bC as Ql, is as Qm, JP as Qn, Ek as Qo, rg as Qp, zN as Qr, fD as Qs, XI as Qt, ux as Qu, NR as R, Ue as R_, _j as Ra, HT as Rc, Uy as Rd, Kv as Rf, $t as Rg, xo as Rh, BM as Ri, LC as Rl, Vo as Rm, NF as Rn, Xk as Ro, Og as Rp, KN as Rr, xD as Rs, bL as Rt, Bx as Ru, M as Rv, kz as S, bt as S_, Uj as Sa, DE as Sc, Yb as Sd, ly as Sf, vn as Sg, Lo as Sh, aN as Si, Tw as Sl, Rm as Sm, wI as Sn, jA as So, m_ as Sp, cP as Sr, uO as Ss, SL as St, FS as Su, qe as Sv, Sz as T, he as T_, Vj as Ta, SE as Tc, kb as Td, sy as Tf, mn as Tg, To as Th, tN as Ti, hw as Tl, sm as Tm, lI as Tn, DA as To, c_ as Tp, sP as Tr, hO as Ts, yL as Tt, wS as Tu, Xe as Tv, DR as U, le as U_, mj as Ua, pT as Uc, $y as Ud, Iv as Uf, nn as Ug, Ua as Uh, WM as Ui, EC as Ul, fs as Um, hF as Un, Uk as Uo, gg as Up, UN as Ur, hD as Us, dL as Ut, Nx as Uu, jR as V, D as V_, sj as Va, NT as Vc, Jy as Vd, Vv as Vf, an as Vg, L as Vh, KM as Vi, AC as Vl, vs as Vm, EF as Vn, Gk as Vo, ug as Vp, GN as Vr, yD as Vs, uL as Vt, Lx as Vu, yR as W, O as W_, dj as Wa, fT as Wc, eb as Wd, Rv as Wf, Et as Wg, Pa as Wh, jM as Wi, PC as Wl, Cs as Wm, pF as Wn, Lk as Wo, lg as Wp, MN as Wr, aD as Ws, EL as Wt, Mx as Wu, xR as X, je as X_, rj as Xa, cT as Xc, zy as Xd, Dv as Xf, Bt as Xg, Tr as Xh, CM as Xi, SC as Xl, R as Xm, ZP as Xn, Ik as Xo, og as Xp, VN as Xr, cD as Xs, ZI as Xt, fx as Xu, gR as Y, Ae as Y_, tj as Ya, sT as Yc, By as Yd, Mv as Yf, xt as Yg, Cr as Yh, OM as Yi, wC as Yl, ms as Ym, lF as Yn, Hk as Yo, cg as Yp, NN as Yr, oD as Ys, YI as Yt, Sx as Yu, bR as Z, Me as Z_, aj as Za, oT as Zc, Py as Zd, Ov as Zf, Ht as Zg, wr as Zh, TM as Zi, yC as Zl, ds as Zm, QP as Zn, Pk as Zo, sg as Zp, FN as Zr, uD as Zs, QI as Zt, dx as Zu, Iz as _, It as __, Qj as _a, UE as _c, Hb as _d, hy as _f, hn as _g, wo as _h, pN as _i, jw as _l, Lh as _m, jI as _n, FA as _o, E_ as _p, vP as _r, FO as _s, IL as _t, HS as _u, at as _v, tB as a, Kt as a_, vM as aa, IE as ac, nx as ad, Dy as af, In as ag, ts as ah, jN as ai, Qw as al, Zh as am, II as an, XA as ao, ev as ap, BP as ar, YO as as, fR as at, pC as au, P as av, jz as b, vt as b_, Kj as ba, ME as bc, Bb as bd, dy as bf, gn as bg, Bo as bh, sN as bi, ww as bl, sh as bm, yI as bn, kA as bo, h_ as bp, pP as br, fO as bs, mL as bt, MS as bu, N as bv, Qz as c, Rt as c_, sM as ca, BE as cc, ix as cd, Sy as cf, Hn as cg, No as ch, SN as ci, Jw as cl, Uh as cm, kI as cn, QA as co, V_ as cp, IP as cr, HO as cs, $L as ct, lC as cu, tt as cv, Yz as d, At as d_, tM as da, qE as dc, zb as dd, _y as df, Bn as dg, Mo as dh, hN as di, Gw as dl, Bh as dm, MI as dn, HA as do, M_ as dp, kP as dr, zO as ds, UL as dt, YS as du, ye as dv, zt as e_, hM as ea, eD as ec, mx as ed, Vy as ef, xr as eg, us as eh, EN as ei, nT as el, tg as em, KI as en, oj as eo, xv as ep, UP as er, yk as es, GL as et, vC as eu, fe as ev, Gz as f, Pt as f_, iM as fa, LE as fc, Ib as fd, by as ff, Mn as fg, Ao as fh, vN as fi, zw as fl, zh as fm, BI as fn, UA as fo, L_ as fp, xP as fr, UO as fs, WL as ft, KS as fu, Ne as fv, Kz as g, Dt as g_, eM as ga, GE as gc, Ub as gd, gy as gf, Cn as gg, Zo as gh, mN as gi, Pw as gl, Mh as gm, NI as gn, LA as go, T_ as gp, _P as gr, IO as gs, LL as gt, VS as gu, it as gv, qz as h, gt as h_, Zj as ha, VE as hc, Jb as hd, my as hf, a as hg, ns as hh, dN as hi, Fw as hl, Ph as hm, zI as hn, IA as ho, O_ as hp, bP as hr, LO as hs, RL as ht, qS as hu, rt as hv, rB as i, Ot as i_, yM as ia, KE as ic, lx as id, jy as if, Nn as ig, cs as ih, AN as ii, Zw as il, Xh as im, DI as in, ZA as io, dv as ip, zP as ir, XO as is, KL as it, mC as iu, Qe as iv, dz as j, xe as j_, Sj as ja, CE as jc, hb as jd, Qv as jf, Yt as jg, Fo as jh, YM as ji, iw as jl, Qp as jm, UF as jn, fA as jo, Ag as jp, rP as jr, BD as js, CL as jt, Yx as ju, Ee as jv, oz as k, j as k_, Lj as ka, yE as kc, Tb as kd, ey as kf, fn as kg, Go as kh, QM as ki, ow as kl, im as km, nI as kn, hA as ko, Mg as kp, nP as kr, qD as ks, ML as kt, $x as ku, we as kv, Zz as l, ht as l_, cM as la, WE as lc, Wb as ld, Cy as lf, Rn as lg, ps as lh, bN as li, qw as ll, Vh as lm, AI as ln, WA as lo, P_ as lp, PP as lr, WO as ls, VL as lt, eC as lu, dt as lv, Uz as m, Gt as m_, $j as ma, YE as mc, Fb as md, yy as mf, zn as mg, ls as mh, fN as mi, Rw as ml, Ih as mm, OI as mn, zA as mo, k_ as mp, yP as mr, VO as ms, BL as mt, JS as mu, ct as mv, aB as n, jt as n_, _M as na, tD as nc, ax as nd, Ay as nf, Sr as ng, ko as nh, kN as ni, eT as nl, $h as nm, WI as nn, qA as no, yv as np, LP as nr, dk as ns, tR as nt, gC as nu, mt as nv, eB as o, kt as o_, xM as oa, RE as oc, rx as od, Ey as of, Fn as og, Oo as oh, xN as oi, Xw as ol, Yh as om, LI as on, JA as oo, Q_ as op, RP as or, qO as os, dR as ot, dC as ou, $e as ov, Wz as p, Wt as p_, nM as pa, zE as pc, Lb as pd, vy as pf, Pn as pg, os as ph, _N as pi, Ww as pl, Wh as pm, FI as pn, RA as po, j_ as pp, wP as pr, BO as ps, zL as pt, WS as pu, Ze as pv, hR as q, Oe as q_, hj as qa, lT as qc, Ry as qd, Fv as qf, wt as qg, Bi as qh, wM as qi, TC as ql, bs as qm, dF as qn, Rk as qo, fg as qp, RN as qr, dD as qs, jL as qt, wx as qu, nB as r, Lt as r_, gM as ra, rD as rc, cx as rd, ky as rf, vr as rg, as as rh, ON as ri, $w as rl, Qh as rm, EI as rn, $A as ro, mv as rp, VP as rr, ek as rs, JL as rt, fC as ru, nt as rv, $z as s, Tt as s_, bM as sa, JE as sc, ox as sd, Ty as sf, Ln as sg, ys as sh, yN as si, Yw as sl, Gh as sm, VI as sn, ej as so, H_ as sp, NP as sr, GO as ss, QL as st, uC as su, et as sv, oB as t, _t as t_, mM as ta, nD as tc, tx as td, Oy as tf, _r as tg, rs as th, DN as ti, tT as tl, eg as tm, JI as tn, YA as to, gv as tp, WP as tr, vk as ts, qL as tt, hC as tu, ut as tv, Xz as u, Ut as u_, rM as ua, HE as uc, Rb as ud, xy as uf, Vn as ug, ws as uh, gN as ui, Kw as ul, Hh as um, RI as un, GA as uo, R_ as up, DP as ur, RO as us, HL as ut, tC as uu, lt as uv, Mz as v, Mt as v_, Jj as va, AE as vc, qb as vd, py as vf, wn as vg, Xo as vh, cN as vi, kw as vl, Fh as vm, PI as vn, PA as vo, D_ as vp, hP as vr, TO as vs, sL as vt, RS as vu, ot as vv, bz as w, be as w_, Bj as wa, kE as wc, Ab as wd, iy as wf, xn as wg, Wo as wh, iN as wi, yw as wl, hm as wm, fI as wn, EA as wo, u_ as wp, oP as wr, pO as ws, xL as wt, ES as wu, Ye as wv, Oz as x, yt as x_, qj as xa, OE as xc, Pb as xd, uy as xf, bn as xg, qo as xh, oN as xi, Ew as xl, Hm as xm, bI as xn, OA as xo, p_ as xp, mP as xr, dO as xs, OL as xt, NS as xu, Ke as xv, Nz as y, Nt as y_, Yj as ya, jE as yc, Kb as yd, fy as yf, yn as yg, Yo as yh, lN as yi, Dw as yl, Nh as ym, xI as yn, NA as yo, x_ as yp, gP as yr, EO as ys, hL as yt, LS as yu, st as yv, MR as z, We as z_, yj as za, BT as zc, Yy as zd, Wv as zf, Jt as zg, Co as zh, HM as zi, IC as zl, Ro as zm, IF as zn, qk as zo, vg as zp, qN as zr, bD as zs, vL as zt, zx as zu };
78790
+ export { oR as $, je as $_, rj as $a, cT as $c, zy as $d, Dv as $f, Bt as $g, Tr as $h, CM as $i, SC as $l, R as $m, tF as $n, Ik as $o, og as $p, VN as $r, cD as $s, ZI as $t, fx as $u, dz as A, _e as A_, Ij as Aa, bE as Ac, Ob as Ad, ny as Af, dn as Ag, $o as Ah, eN as Ai, uw as Al, cm as Am, XF as An, SA as Ao, Pg as Ap, aP as Ar, sO as As, AL as At, vS as Au, Se as Av, IR as B, He as B_, xj as Ba, qT as Bc, mb as Bd, qv as Bf, en as Bg, So as Bh, MM as Bi, RC as Bl, z as Bm, NF as Bn, eA as Bo, wg as Bp, YN as Br, DD as Bs, vL as Bt, Ix as Bu, Re as Bv, Mz as C, vt as C_, Kj as Ca, ME as Cc, Bb as Cd, dy as Cf, gn as Cg, Bo as Ch, sN as Ci, ww as Cl, sh as Cm, jI as Cn, kA as Co, h_ as Cp, pP as Cr, fO as Cs, CL as Ct, MS as Cu, N as Cv, Dz as D, be as D_, Bj as Da, kE as Dc, Ab as Dd, iy as Df, xn as Dg, Wo as Dh, iN as Di, yw as Dl, hm as Dm, gI as Dn, EA as Do, u_ as Dp, oP as Dr, pO as Ds, jL as Dt, ES as Du, Ye as Dv, jz as E, de as E_, Wj as Ea, EE as Ec, Vb as Ed, cy as Ef, _n as Eg, Io as Eh, rN as Ei, _w as El, Im as Em, _I as En, AA as Eo, l_ as Ep, lP as Er, mO as Es, lL as Et, AS as Eu, Je as Ev, oz as F, pt as F_, bj as Fa, oE as Fc, gb as Fd, Zv as Ff, tn as Fg, Ko as Fh, GM as Fi, tw as Fl, Kp as Fm, qF as Fn, lA as Fo, Eg as Fp, QN as Fr, FD as Fs, mL as Ft, Jx as Fu, E as Fv, CR as G, ce as G_, lj as Ga, OT as Gc, qy as Gd, zv as Gf, rn as Gg, I as Gh, PM as Gi, DC as Gl, Po as Gm, bF as Gn, Wk as Go, _g as Gp, HN as Gr, _D as Gs, NL as Gt, Px as Gu, PR as H, We as H_, yj as Ha, BT as Hc, Yy as Hd, Wv as Hf, Jt as Hg, Co as Hh, HM as Hi, IC as Hl, Ro as Hm, jF as Hn, qk as Ho, vg as Hp, qN as Hr, bD as Hs, hL as Ht, zx as Hu, rz as I, A as I_, gj as Ia, eE as Ic, pb as Id, Xv as If, Qt as Ig, Jo as Ih, UM as Ii, YC as Il, Wp as Im, JF as In, uA as Io, Tg as Ip, $N as Ir, TD as Is, fL as It, qx as Iu, ze as Iv, wR as J, ue as J_, cj as Ja, mT as Jc, Qy as Jd, Bv as Jf, Ft as Jg, Na as Jh, AM as Ji, CC as Jl, jo as Jm, pF as Jn, Bk as Jo, mg as Jp, BN as Jr, sD as Js, yL as Jt, jx as Ju, OR as K, le as K_, mj as Ka, pT as Kc, $y as Kd, Iv as Kf, nn as Kg, Ua as Kh, WM as Ki, EC as Kl, fs as Km, gF as Kn, Uk as Ko, gg as Kp, UN as Kr, hD as Ks, FL as Kt, Nx as Ku, az as L, Ge as L_, vj as La, $T as Lc, db as Ld, Jv as Lf, Zt as Lg, vo as Lh, FM as Li, qC as Ll, Hp as Lm, BF as Ln, iA as Lo, Cg as Lp, XN as Lr, CD as Ls, dL as Lt, Xx as Lu, Fe as Lv, gz as M, j as M_, Lj as Ma, yE as Mc, Tb as Md, ey as Mf, fn as Mg, Go as Mh, QM as Mi, ow as Ml, im as Mm, WF as Mn, hA as Mo, Mg as Mp, nP as Mr, qD as Ms, cL as Mt, $x as Mu, we as Mv, hz as N, me as N_, Ej as Na, TE as Nc, _b as Nd, $v as Nf, Xt as Ng, zo as Nh, ZM as Ni, aw as Nl, Jp as Nm, GF as Nn, dA as No, jg as Np, tP as Nr, zD as Ns, uL as Nt, Zx as Nu, Te as Nv, bz as O, he as O_, Vj as Oa, SE as Oc, kb as Od, sy as Of, mn as Og, To as Oh, tN as Oi, hw as Ol, sm as Om, fI as On, DA as Oo, c_ as Op, sP as Or, hO as Os, SL as Ot, wS as Ou, Xe as Ov, iz as P, xe as P_, Sj as Pa, CE as Pc, hb as Pd, Qv as Pf, Yt as Pg, Fo as Ph, YM as Pi, iw as Pl, Qp as Pm, UF as Pn, fA as Po, Ag as Pp, rP as Pr, BD as Ps, IL as Pt, Yx as Pu, Ee as Pv, rR as Q, Ae as Q_, tj as Qa, sT as Qc, By as Qd, Mv as Qf, xt as Qg, Cr as Qh, OM as Qi, wC as Ql, ms as Qm, eF as Qn, Hk as Qo, cg as Qp, NN as Qr, oD as Qs, nL as Qt, Sx as Qu, zR as R, Be as R_, wj as Ra, XT as Rc, fb as Rd, Yv as Rf, sn as Rg, yo as Rh, zM as Ri, GC as Rl, Os as Rm, zF as Rn, tA as Ro, kg as Rp, ZN as Rr, wD as Rs, EL as Rt, Wx as Ru, Ie as Rv, Fz as S, Nt as S_, Yj as Sa, jE as Sc, Kb as Sd, fy as Sf, yn as Sg, Yo as Sh, lN as Si, Dw as Sl, Nh as Sm, AI as Sn, NA as So, x_ as Sp, gP as Sr, EO as Ss, OL as St, LS as Su, st as Sv, Oz as T, bt as T_, Uj as Ta, DE as Tc, Yb as Td, ly as Tf, vn as Tg, Lo as Th, aN as Ti, Tw as Tl, Rm as Tm, hI as Tn, jA as To, m_ as Tp, cP as Tr, uO as Ts, TL as Tt, FS as Tu, qe as Tv, NR as U, pe as U_, Tj as Ua, PT as Uc, Xy as Ud, Uv as Uf, on as Ug, co as Uh, qM as Ui, FC as Ul, Do as Um, xF as Un, Kk as Uo, hg as Up, WN as Ur, vD as Us, _L as Ut, Rx as Uu, LR as V, Ue as V_, _j as Va, HT as Vc, Uy as Vd, Kv as Vf, $t as Vg, xo as Vh, BM as Vi, LC as Vl, Vo as Vm, MF as Vn, Xk as Vo, Og as Vp, KN as Vr, xD as Vs, gL as Vt, Bx as Vu, M as Vv, TR as W, D as W_, sj as Wa, NT as Wc, Jy as Wd, Vv as Wf, an as Wg, L as Wh, KM as Wi, AC as Wl, vs as Wm, yF as Wn, Gk as Wo, ug as Wp, GN as Wr, yD as Ws, ML as Wt, Lx as Wu, DR as X, Oe as X_, hj as Xa, lT as Xc, Ry as Xd, Fv as Xf, wt as Xg, Bi as Xh, wM as Xi, TC as Xl, bs as Xm, rF as Xn, Rk as Xo, fg as Xp, RN as Xr, dD as Xs, rL as Xt, wx as Xu, SR as Y, Pe as Y_, uj as Ya, dT as Yc, Zy as Yd, Lv as Yf, qt as Yg, La as Yh, SM as Yi, jC as Yl, Eo as Ym, hF as Yn, zk as Yo, pg as Yp, PN as Yr, lD as Ys, tL as Yt, Tx as Yu, ER as Z, ke as Z_, fj as Za, uT as Zc, Ly as Zd, jv as Zf, Ct as Zg, kr as Zh, EM as Zi, NC as Zl, Ts as Zm, iF as Zn, Vk as Zo, dg as Zp, IN as Zr, pD as Zs, iL as Zt, Cx as Zu, Hz as _, Gt as __, $j as _a, YE as _c, Fb as _d, yy as _f, zn as _g, ls as _h, fN as _i, Rw as _l, Ih as _m, LI as _n, zA as _o, k_ as _p, yP as _r, VO as _s, HL as _t, JS as _u, ct as _v, sB as a, jt as a_, _M as aa, tD as ac, ax as ad, Ay as af, Sr as ag, ko as ah, kN as ai, eT as al, $h as am, HI as an, qA as ao, yv as ap, LP as ar, dk as as, vR as at, gC as au, mt as av, Lz as b, It as b_, Qj as ba, UE as bc, Hb as bd, hy as bf, hn as bg, wo as bh, pN as bi, jw as bl, Lh as bm, TI as bn, FA as bo, E_ as bp, vP as br, FO as bs, bL as bt, HS as bu, at as bv, iB as c, Kt as c_, vM as ca, IE as cc, nx as cd, Dy as cf, In as cg, ts as ch, jN as ci, Qw as cl, Zh as cm, FI as cn, XA as co, ev as cp, BP as cr, YO as cs, aR as ct, pC as cu, P as cv, tB as d, Rt as d_, sM as da, BE as dc, ix as dd, Sy as df, Hn as dg, No as dh, SN as di, Jw as dl, Uh as dm, RI as dn, QA as do, V_ as dp, IP as dr, HO as ds, YL as dt, lC as du, tt as dv, Ht as e_, TM as ea, uD as ec, dx as ed, Py as ef, wr as eg, ds as eh, FN as ei, oT as el, sg as em, QI as en, aj as eo, Ov as ep, YP as er, Pk as es, ZL as et, yC as eu, Me as ev, Zz as f, ht as f_, cM as fa, WE as fc, Wb as fd, Cy as ff, Rn as fg, ps as fh, bN as fi, qw as fl, Vh as fm, KI as fn, WA as fo, P_ as fp, PP as fr, WO as fs, XL as ft, eC as fu, dt as fv, Qz as g, Wt as g_, nM as ga, zE as gc, Lb as gd, vy as gf, Pn as gg, os as gh, _N as gi, Ww as gl, Wh as gm, zI as gn, RA as go, j_ as gp, wP as gr, BO as gs, UL as gt, WS as gu, Ze as gv, $z as h, Pt as h_, iM as ha, LE as hc, Ib as hd, by as hf, Mn as hg, Ao as hh, vN as hi, zw as hl, zh as hm, GI as hn, UA as ho, L_ as hp, xP as hr, UO as hs, WL as ht, KS as hu, Ne as hv, lB as i, _t as i_, mM as ia, nD as ic, tx as id, Oy as if, _r as ig, rs as ih, DN as ii, tT as il, eg as im, NI as in, YA as io, gv as ip, UP as ir, vk as is, QL as it, hC as iu, ut as iv, _z as j, ve as j_, Pj as ja, xE as jc, Eb as jd, ty as jf, ln as jg, Qo as jh, $M as ji, sw as jl, lm as jm, YF as jn, yA as jo, Ng as jp, eP as jr, lO as js, kL as jt, nS as ju, Ce as jv, fz as k, ge as k_, Nj as ka, wE as kc, Db as kd, ry as kf, Sn as kg, es as kh, nN as ki, pw as kl, um as km, cI as kn, wA as ko, a_ as kp, iP as kr, cO as ks, RL as kt, TS as ku, De as kv, rB as l, kt as l_, xM as la, RE as lc, rx as ld, Ey as lf, Fn as lg, Oo as lh, xN as li, Xw as ll, Yh as lm, II as ln, JA as lo, Q_ as lp, RP as lr, qO as ls, qL as lt, dC as lu, $e as lv, Yz as m, At as m_, tM as ma, qE as mc, zb as md, _y as mf, Bn as mg, Mo as mh, hN as mi, Gw as ml, Bh as mm, PI as mn, HA as mo, M_ as mp, kP as mr, zO as ms, KL as mt, YS as mu, ye as mv, dB as n, St as n_, kM as na, mD as nc, px as nd, Fy as nf, yr as ng, ss as nh, LN as ni, iT as nl, ng as nm, XI as nn, ij as no, Ev as np, KP as nr, xk as ns, sR as nt, xC as nu, ft as nv, oB as o, Lt as o_, gM as oa, rD as oc, cx as od, ky as of, vr as og, as as oh, ON as oi, $w as ol, Qh as om, UI as on, $A as oo, mv as op, VP as or, ek as os, _R as ot, fC as ou, nt as ov, Xz as p, Ut as p_, rM as pa, HE as pc, Rb as pd, xy as pf, Vn as pg, ws as ph, gN as pi, Kw as pl, Hh as pm, VI as pn, GA as po, R_ as pp, DP as pr, RO as ps, GL as pt, tC as pu, lt as pv, xR as q, O as q_, dj as qa, fT as qc, eb as qd, Rv as qf, Et as qg, Pa as qh, jM as qi, PC as ql, Cs as qm, _F as qn, Lk as qo, lg as qp, MN as qr, aD as qs, LL as qt, Mx as qu, cB as r, zt as r_, hM as ra, eD as rc, mx as rd, Vy as rf, xr as rg, us as rh, EN as ri, nT as rl, tg as rm, MI as rn, oj as ro, xv as rp, qP as rr, yk as rs, eR as rt, vC as ru, fe as rv, aB as s, Ot as s_, yM as sa, KE as sc, lx as sd, jy as sf, Nn as sg, cs as sh, AN as si, Zw as sl, Xh as sm, qI as sn, ZA as so, dv as sp, zP as sr, XO as ss, iR as st, mC as su, Qe as sv, fB as t, Vt as t_, DM as ta, fD as tc, ux as td, Iy as tf, br as tg, is as th, zN as ti, rT as tl, rg as tm, eL as tn, nj as to, Tv as tp, XP as tr, Ek as ts, $L as tt, bC as tu, k as tv, nB as u, Tt as u_, bM as ua, JE as uc, ox as ud, Ty as uf, Ln as ug, ys as uh, yN as ui, Yw as ul, Gh as um, WI as un, ej as uo, H_ as up, NP as ur, GO as us, JL as ut, uC as uu, et as uv, Rz as v, gt as v_, Zj as va, VE as vc, Jb as vd, my as vf, a as vg, ns as vh, dN as vi, Fw as vl, Ph as vm, BI as vn, IA as vo, O_ as vp, bP as vr, LO as vs, pL as vt, qS as vu, rt as vv, Ez as w, yt as w_, qj as wa, OE as wc, Pb as wd, uy as wf, bn as wg, qo as wh, oN as wi, Ew as wl, Hm as wm, vI as wn, OA as wo, p_ as wp, mP as wr, dO as ws, DL as wt, NS as wu, Ke as wv, Pz as x, Mt as x_, Jj as xa, AE as xc, qb as xd, py as xf, wn as xg, Xo as xh, cN as xi, kw as xl, Fh as xm, EI as xn, PA as xo, D_ as xp, hP as xr, TO as xs, PL as xt, RS as xu, ot as xv, zz as y, Dt as y_, eM as ya, GE as yc, Ub as yd, gy as yf, Cn as yg, Zo as yh, mN as yi, Pw as yl, Mh as ym, DI as yn, LA as yo, T_ as yp, _P as yr, IO as ys, xL as yt, VS as yu, it as yv, RR as z, Ve as z_, Cj as za, GT as zc, ub as zd, Gv as zf, cn as zg, bo as zh, XM as zi, UC as zl, Es as zm, HF as zn, nA as zo, Dg as zp, JN as zr, ED as zs, wL as zt, Ux as zu, Le as zv };