manim-web 0.13.0 → 0.15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +35 -19
- package/dist/animation/transform/MovementTransforms.d.ts.map +1 -1
- package/dist/export/chooseExporter.d.ts +19 -0
- package/dist/export/chooseExporter.d.ts.map +1 -0
- package/dist/export/index.d.ts +1 -0
- package/dist/export/index.d.ts.map +1 -1
- package/dist/index.d.ts +5 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -3
- package/dist/integrations/react.js +16 -16
- package/dist/integrations/vue.js +13 -13
- package/dist/interaction/DynamicMatrix.d.ts +164 -0
- package/dist/interaction/DynamicMatrix.d.ts.map +1 -0
- package/dist/interaction/index.d.ts +1 -0
- package/dist/interaction/index.d.ts.map +1 -1
- package/dist/manim-web.browser.js +1499 -624
- package/dist/mobjects/geo/ChoroplethMap.d.ts +72 -0
- package/dist/mobjects/geo/ChoroplethMap.d.ts.map +1 -0
- package/dist/mobjects/geo/Globe.d.ts +122 -0
- package/dist/mobjects/geo/Globe.d.ts.map +1 -0
- package/dist/mobjects/geo/colorScale.d.ts +45 -0
- package/dist/mobjects/geo/colorScale.d.ts.map +1 -0
- package/dist/mobjects/geo/geojson.d.ts +54 -0
- package/dist/mobjects/geo/geojson.d.ts.map +1 -0
- package/dist/mobjects/geo/index.d.ts +13 -0
- package/dist/mobjects/geo/index.d.ts.map +1 -0
- package/dist/mobjects/geo/projections.d.ts +53 -0
- package/dist/mobjects/geo/projections.d.ts.map +1 -0
- package/dist/mobjects/three-d/Line3D.d.ts.map +1 -1
- package/dist/player/ExportSettingsUI.d.ts +82 -0
- package/dist/player/ExportSettingsUI.d.ts.map +1 -0
- package/dist/player/Player.d.ts +50 -2
- package/dist/player/Player.d.ts.map +1 -1
- package/dist/player/PlayerUI.d.ts +15 -1
- package/dist/player/PlayerUI.d.ts.map +1 -1
- package/dist/player/SlideInteractionRenderer.d.ts +32 -0
- package/dist/player/SlideInteractionRenderer.d.ts.map +1 -0
- package/dist/player/index.d.ts +1 -0
- package/dist/player/index.d.ts.map +1 -1
- package/dist/rate-functions/spring.d.ts.map +1 -1
- package/dist/serialization/defaults.d.ts +13 -0
- package/dist/serialization/defaults.d.ts.map +1 -0
- package/dist/serialization/index.d.ts +15 -0
- package/dist/serialization/index.d.ts.map +1 -0
- package/dist/serialization/props.d.ts +16 -0
- package/dist/serialization/props.d.ts.map +1 -0
- package/dist/serialization/registry.d.ts +17 -0
- package/dist/serialization/registry.d.ts.map +1 -0
- package/dist/serialization/serialize.d.ts +24 -0
- package/dist/serialization/serialize.d.ts.map +1 -0
- package/dist/serialization/types.d.ts +70 -0
- package/dist/serialization/types.d.ts.map +1 -0
- package/dist/{src-BcBBUMTP.js → src-Da4luuzD.js} +1481 -606
- package/dist/test-setup/TestMobject.d.ts +23 -0
- package/dist/test-setup/TestMobject.d.ts.map +1 -0
- package/dist/utils/axis.d.ts +0 -1
- package/dist/utils/axis.d.ts.map +1 -1
- package/package.json +3 -1
|
@@ -10219,7 +10219,7 @@ var V = class e extends jm {
|
|
|
10219
10219
|
let t = e.stiffness ?? Ph, n = e.damping ?? Fh, r = e.mass ?? Ih;
|
|
10220
10220
|
return {
|
|
10221
10221
|
omega0: Math.sqrt(t / r),
|
|
10222
|
-
zeta: n / (2 * Math.sqrt(t * r))
|
|
10222
|
+
zeta: Math.max(n / (2 * Math.sqrt(t * r)), .001)
|
|
10223
10223
|
};
|
|
10224
10224
|
}, Bh = (e, t) => {
|
|
10225
10225
|
if (t < .999999) {
|
|
@@ -46926,7 +46926,7 @@ var $T = class e {
|
|
|
46926
46926
|
if (this.isHeadless) throw Error("export() is not available in headless mode. Create a Scene with a container for rendering and exporting.");
|
|
46927
46927
|
let n = e.slice(e.lastIndexOf(".")).toLowerCase(), r;
|
|
46928
46928
|
if (n === ".gif") {
|
|
46929
|
-
let { GifExporter: n } = await Promise.resolve().then(() =>
|
|
46929
|
+
let { GifExporter: n } = await Promise.resolve().then(() => LL);
|
|
46930
46930
|
r = await new n(this, {
|
|
46931
46931
|
fps: t?.fps,
|
|
46932
46932
|
quality: t?.quality,
|
|
@@ -46938,7 +46938,7 @@ var $T = class e {
|
|
|
46938
46938
|
workers: t?.workers
|
|
46939
46939
|
}).exportTimeline(t?.duration), n.download(r, e);
|
|
46940
46940
|
} else if (n === ".webm" || n === ".mp4" || n === ".mov") {
|
|
46941
|
-
let { VideoExporter: i } = await Promise.resolve().then(() =>
|
|
46941
|
+
let { VideoExporter: i } = await Promise.resolve().then(() => VL), a = n === ".mp4" ? "mp4" : n === ".mov" ? "mov" : "webm";
|
|
46942
46942
|
r = await new i(this, {
|
|
46943
46943
|
fps: t?.fps,
|
|
46944
46944
|
quality: t?.quality,
|
|
@@ -62133,7 +62133,10 @@ var FA = class e extends kA {
|
|
|
62133
62133
|
transparent: this._opacity < 1,
|
|
62134
62134
|
linewidth: this.strokeWidth,
|
|
62135
62135
|
worldUnits: !1,
|
|
62136
|
-
resolution: new a(this._resolutionWidth, this._resolutionHeight)
|
|
62136
|
+
resolution: new a(this._resolutionWidth, this._resolutionHeight),
|
|
62137
|
+
polygonOffset: !0,
|
|
62138
|
+
polygonOffsetFactor: -1,
|
|
62139
|
+
polygonOffsetUnits: -1
|
|
62137
62140
|
}));
|
|
62138
62141
|
return t.frustumCulled = !1, t.computeLineDistances(), t;
|
|
62139
62142
|
}
|
|
@@ -69657,7 +69660,18 @@ var DP = class extends o_ {
|
|
|
69657
69660
|
function OP(e, t, n) {
|
|
69658
69661
|
return new DP(e, t, n);
|
|
69659
69662
|
}
|
|
69660
|
-
|
|
69663
|
+
function kP(e, t, n, r) {
|
|
69664
|
+
let i = 1e-6;
|
|
69665
|
+
if (Math.abs(r) < i) return new L().lerpVectors(e, t, n);
|
|
69666
|
+
let a = new L().subVectors(t, e), o = new L().addVectors(e, a.clone().multiplyScalar(.5));
|
|
69667
|
+
if (Math.abs(r - Math.PI) > i) {
|
|
69668
|
+
let e = new L(-a.y, a.x, 0);
|
|
69669
|
+
o.add(e.multiplyScalar(1 / (2 * Math.tan(r / 2))));
|
|
69670
|
+
}
|
|
69671
|
+
let s = new L().subVectors(e, o), c = n * r, l = Math.cos(c), u = Math.sin(c);
|
|
69672
|
+
return new L(o.x + s.x * l - s.y * u, o.y + s.x * u + s.y * l, o.z + s.z);
|
|
69673
|
+
}
|
|
69674
|
+
var AP = class extends o_ {
|
|
69661
69675
|
mobjects;
|
|
69662
69676
|
pathArc;
|
|
69663
69677
|
autoCenter;
|
|
@@ -69678,10 +69692,9 @@ var kP = class extends o_ {
|
|
|
69678
69692
|
});
|
|
69679
69693
|
}
|
|
69680
69694
|
interpolate(e) {
|
|
69681
|
-
let t =
|
|
69682
|
-
|
|
69683
|
-
|
|
69684
|
-
i.y += t * (n % 2 == 0 ? .5 : -.5), r.position.copy(i), r._markDirty();
|
|
69695
|
+
for (let t = 0; t < this.mobjects.length; t++) {
|
|
69696
|
+
let n = this.mobjects[t], r = kP(this._startPositions[t], this._targetPositions[t], e, this.pathArc);
|
|
69697
|
+
n.position.copy(r), n._markDirty();
|
|
69685
69698
|
}
|
|
69686
69699
|
}
|
|
69687
69700
|
finish() {
|
|
@@ -69689,12 +69702,12 @@ var kP = class extends o_ {
|
|
|
69689
69702
|
super.finish();
|
|
69690
69703
|
}
|
|
69691
69704
|
};
|
|
69692
|
-
function
|
|
69693
|
-
return new
|
|
69705
|
+
function jP(e, t) {
|
|
69706
|
+
return new AP(e, t);
|
|
69694
69707
|
}
|
|
69695
69708
|
//#endregion
|
|
69696
69709
|
//#region src/animation/transform/SpecialTransforms.ts
|
|
69697
|
-
var
|
|
69710
|
+
var MP = class extends o_ {
|
|
69698
69711
|
scaleFactor;
|
|
69699
69712
|
_initialScale = new L();
|
|
69700
69713
|
_targetScale = new L();
|
|
@@ -69722,13 +69735,13 @@ var jP = class extends o_ {
|
|
|
69722
69735
|
this.interpolate(1), super.finish();
|
|
69723
69736
|
}
|
|
69724
69737
|
};
|
|
69725
|
-
function
|
|
69726
|
-
return new
|
|
69738
|
+
function NP(e, t, n) {
|
|
69739
|
+
return new MP(e, {
|
|
69727
69740
|
...n,
|
|
69728
69741
|
scaleFactor: t
|
|
69729
69742
|
});
|
|
69730
69743
|
}
|
|
69731
|
-
var
|
|
69744
|
+
var PP = class extends o_ {
|
|
69732
69745
|
_initialScale = new L();
|
|
69733
69746
|
constructor(e, t = {}) {
|
|
69734
69747
|
super(e, t);
|
|
@@ -69744,19 +69757,19 @@ var NP = class extends o_ {
|
|
|
69744
69757
|
this.mobject.scaleVector.set(0, 0, 0), this.mobject._markDirty(), super.finish();
|
|
69745
69758
|
}
|
|
69746
69759
|
};
|
|
69747
|
-
function
|
|
69748
|
-
return new
|
|
69760
|
+
function FP(e, t) {
|
|
69761
|
+
return new PP(e, t);
|
|
69749
69762
|
}
|
|
69750
|
-
var
|
|
69763
|
+
var IP = class extends dT {
|
|
69751
69764
|
constructor(e, t = {}) {
|
|
69752
69765
|
if (!e.savedState) throw Error("Restore requires mobject.savedState to be set. Use mobject.saveState() first.");
|
|
69753
69766
|
super(e, e.savedState, t);
|
|
69754
69767
|
}
|
|
69755
69768
|
};
|
|
69756
|
-
function
|
|
69757
|
-
return new
|
|
69769
|
+
function LP(e, t) {
|
|
69770
|
+
return new IP(e, t);
|
|
69758
69771
|
}
|
|
69759
|
-
var
|
|
69772
|
+
var RP = class extends o_ {
|
|
69760
69773
|
targetColor;
|
|
69761
69774
|
_startColor = new Wt();
|
|
69762
69775
|
_targetColorObj = new Wt();
|
|
@@ -69774,13 +69787,13 @@ var LP = class extends o_ {
|
|
|
69774
69787
|
this.mobject.color = this.targetColor, this.mobject._markDirty(), super.finish();
|
|
69775
69788
|
}
|
|
69776
69789
|
};
|
|
69777
|
-
function
|
|
69778
|
-
return new
|
|
69790
|
+
function zP(e, t, n) {
|
|
69791
|
+
return new RP(e, {
|
|
69779
69792
|
...n,
|
|
69780
69793
|
color: t
|
|
69781
69794
|
});
|
|
69782
69795
|
}
|
|
69783
|
-
var
|
|
69796
|
+
var BP = class extends o_ {
|
|
69784
69797
|
animation1;
|
|
69785
69798
|
animation2;
|
|
69786
69799
|
transformRateFunc;
|
|
@@ -69813,12 +69826,12 @@ var zP = class extends o_ {
|
|
|
69813
69826
|
e.setPoints(this._anim2EndPoints), e.opacity = t.opacity, this.animation1.finish(), this.animation2.finish(), super.finish();
|
|
69814
69827
|
}
|
|
69815
69828
|
};
|
|
69816
|
-
function
|
|
69817
|
-
return new
|
|
69829
|
+
function VP(e, t, n) {
|
|
69830
|
+
return new BP(e, t, n);
|
|
69818
69831
|
}
|
|
69819
69832
|
//#endregion
|
|
69820
69833
|
//#region src/animation/transform/TransformMatchingBase.ts
|
|
69821
|
-
var
|
|
69834
|
+
var HP = class extends o_ {
|
|
69822
69835
|
target;
|
|
69823
69836
|
keyFunc;
|
|
69824
69837
|
fadeRatio;
|
|
@@ -69913,7 +69926,7 @@ var VP = class extends o_ {
|
|
|
69913
69926
|
};
|
|
69914
69927
|
//#endregion
|
|
69915
69928
|
//#region src/utils/hungarian.ts
|
|
69916
|
-
function
|
|
69929
|
+
function UP(e) {
|
|
69917
69930
|
let t = e.length;
|
|
69918
69931
|
if (t === 0) return {
|
|
69919
69932
|
assignments: [],
|
|
@@ -69931,7 +69944,7 @@ function HP(e) {
|
|
|
69931
69944
|
let r = 0;
|
|
69932
69945
|
for (let i = 0; i < t; i++) for (let t = 0; t < n; t++) e[i][t] > r && (r = e[i][t]);
|
|
69933
69946
|
let i = r * 10 + 1, a = Math.max(t, n), o = Array.from({ length: a }, (r, o) => Array.from({ length: a }, (r, a) => o < t && a < n ? e[o][a] : i)), s = new Float64Array(a + 1), c = new Float64Array(a + 1), l = new Int32Array(a + 1).fill(0), u = new Int32Array(a + 1).fill(0);
|
|
69934
|
-
for (let e = 1; e <= a; e++)
|
|
69947
|
+
for (let e = 1; e <= a; e++) WP(e, a, o, s, c, l, u);
|
|
69935
69948
|
let d = Array(t).fill(-1), f = /* @__PURE__ */ new Set(), p = /* @__PURE__ */ new Set(), m = 0;
|
|
69936
69949
|
for (let r = 1; r <= a; r++) {
|
|
69937
69950
|
let i = l[r] - 1, a = r - 1;
|
|
@@ -69944,7 +69957,7 @@ function HP(e) {
|
|
|
69944
69957
|
assignedCols: p
|
|
69945
69958
|
};
|
|
69946
69959
|
}
|
|
69947
|
-
function
|
|
69960
|
+
function WP(e, t, n, r, i, a, o) {
|
|
69948
69961
|
a[0] = e;
|
|
69949
69962
|
let s = 0, c = new Float64Array(t + 1).fill(Infinity), l = new Uint8Array(t + 1);
|
|
69950
69963
|
do {
|
|
@@ -69963,7 +69976,7 @@ function UP(e, t, n, r, i, a, o) {
|
|
|
69963
69976
|
a[s] = a[e], s = e;
|
|
69964
69977
|
} while (s !== 0);
|
|
69965
69978
|
}
|
|
69966
|
-
function
|
|
69979
|
+
function GP(e, t = 0) {
|
|
69967
69980
|
let n = e.length;
|
|
69968
69981
|
if (n === 0) return {
|
|
69969
69982
|
assignments: [],
|
|
@@ -69980,7 +69993,7 @@ function WP(e, t = 0) {
|
|
|
69980
69993
|
};
|
|
69981
69994
|
let i = 0;
|
|
69982
69995
|
for (let t = 0; t < n; t++) for (let n = 0; n < r; n++) e[t][n] > i && (i = e[t][n]);
|
|
69983
|
-
let a = i * 10 + 1, o =
|
|
69996
|
+
let a = i * 10 + 1, o = UP(Array.from({ length: n }, (n, o) => Array.from({ length: r }, (n, r) => e[o][r] >= t ? i - e[o][r] : a)));
|
|
69984
69997
|
for (let r = 0; r < n; r++) {
|
|
69985
69998
|
let n = o.assignments[r];
|
|
69986
69999
|
n >= 0 && e[r][n] < t && (o.assignments[r] = -1, o.assignedRows.delete(r), o.assignedCols.delete(n));
|
|
@@ -69989,7 +70002,7 @@ function WP(e, t = 0) {
|
|
|
69989
70002
|
}
|
|
69990
70003
|
//#endregion
|
|
69991
70004
|
//#region src/animation/transform/TransformMatchingShared.ts
|
|
69992
|
-
function
|
|
70005
|
+
function KP(e) {
|
|
69993
70006
|
let t = e.getLocalPoints();
|
|
69994
70007
|
if (t.length === 0) {
|
|
69995
70008
|
let t = e.getCenter();
|
|
@@ -70029,17 +70042,17 @@ function GP(e) {
|
|
|
70029
70042
|
]
|
|
70030
70043
|
};
|
|
70031
70044
|
}
|
|
70032
|
-
function
|
|
70033
|
-
let n =
|
|
70045
|
+
function qP(e, t) {
|
|
70046
|
+
let n = KP(e), r = KP(t), i = Math.sqrt(n.size[0] ** 2 + n.size[1] ** 2), a = Math.sqrt(r.size[0] ** 2 + r.size[1] ** 2), o = Math.max(i, a, .001), s = 1 - Math.abs(i - a) / o, c = n.size[1] === 0 ? 1 : n.size[0] / n.size[1], l = r.size[1] === 0 ? 1 : r.size[0] / r.size[1], u = Math.max(c, l, .001), d = 1 - Math.abs(c - l) / u, f = e.getLocalPoints().length, p = t.getLocalPoints().length, m = Math.max(f, p, 1), h = 1 - Math.abs(f - p) / m;
|
|
70034
70047
|
return s * .4 + d * .3 + h * .3;
|
|
70035
70048
|
}
|
|
70036
|
-
function
|
|
70037
|
-
let n =
|
|
70049
|
+
function JP(e, t) {
|
|
70050
|
+
let n = KP(e).center, r = KP(t).center;
|
|
70038
70051
|
return Math.sqrt((n[0] - r[0]) ** 2 + (n[1] - r[1]) ** 2 + (n[2] - r[2]) ** 2);
|
|
70039
70052
|
}
|
|
70040
70053
|
//#endregion
|
|
70041
70054
|
//#region src/animation/transform/TransformMatching.ts
|
|
70042
|
-
var
|
|
70055
|
+
var YP = class extends o_ {
|
|
70043
70056
|
target;
|
|
70044
70057
|
matchThreshold;
|
|
70045
70058
|
keyFunc;
|
|
@@ -70082,7 +70095,7 @@ var JP = class extends o_ {
|
|
|
70082
70095
|
}
|
|
70083
70096
|
}
|
|
70084
70097
|
} else {
|
|
70085
|
-
let i =
|
|
70098
|
+
let i = GP(Array.from({ length: e.length }, (n, r) => Array.from({ length: t.length }, (n, i) => qP(e[r], t[i]))), this.matchThreshold);
|
|
70086
70099
|
for (let a = 0; a < e.length; a++) {
|
|
70087
70100
|
let o = i.assignments[a];
|
|
70088
70101
|
o >= 0 && (this._addMatchedPart(e[a], t[o]), n.add(a), r.add(o));
|
|
@@ -70140,16 +70153,16 @@ var JP = class extends o_ {
|
|
|
70140
70153
|
super.finish();
|
|
70141
70154
|
}
|
|
70142
70155
|
};
|
|
70143
|
-
function
|
|
70144
|
-
return new
|
|
70156
|
+
function XP(e, t, n) {
|
|
70157
|
+
return new YP(e, t, n);
|
|
70145
70158
|
}
|
|
70146
|
-
function
|
|
70159
|
+
function ZP(e) {
|
|
70147
70160
|
let t = e;
|
|
70148
70161
|
if (typeof t.getLatex == "function") return t.getLatex();
|
|
70149
|
-
let n =
|
|
70162
|
+
let n = KP(e);
|
|
70150
70163
|
return `shape_${`${n.size[0].toFixed(2)}_${n.size[1].toFixed(2)}`}_${e.getLocalPoints().length}`;
|
|
70151
70164
|
}
|
|
70152
|
-
var
|
|
70165
|
+
var QP = class extends o_ {
|
|
70153
70166
|
target;
|
|
70154
70167
|
keyFunc;
|
|
70155
70168
|
fadeRatio;
|
|
@@ -70159,7 +70172,7 @@ var ZP = class extends o_ {
|
|
|
70159
70172
|
_fadeInParts = [];
|
|
70160
70173
|
_mismatchedPairs = [];
|
|
70161
70174
|
constructor(e, t, n = {}) {
|
|
70162
|
-
super(e, n), this.target = t, this.keyFunc = n.keyFunc ??
|
|
70175
|
+
super(e, n), this.target = t, this.keyFunc = n.keyFunc ?? ZP, this.fadeRatio = Math.min(.5, Math.max(0, n.fadeRatio ?? .25)), this.transformMismatches = n.transformMismatches ?? !1;
|
|
70163
70176
|
}
|
|
70164
70177
|
_getTexParts(e) {
|
|
70165
70178
|
let t = e.children.filter((e) => e instanceof V);
|
|
@@ -70202,7 +70215,7 @@ var ZP = class extends o_ {
|
|
|
70202
70215
|
for (let t = 0; t < e.length; t++) n.has(t) || o.push(t);
|
|
70203
70216
|
for (let e = 0; e < t.length; e++) r.has(e) || s.push(e);
|
|
70204
70217
|
if (this.transformMismatches && o.length > 0 && s.length > 0) {
|
|
70205
|
-
let n = o.map((t) => e[t]), r = s.map((e) => t[e]), i =
|
|
70218
|
+
let n = o.map((t) => e[t]), r = s.map((e) => t[e]), i = UP(Array.from({ length: n.length }, (e, t) => Array.from({ length: r.length }, (e, i) => JP(n[t], r[i])))), a = /* @__PURE__ */ new Set(), c = /* @__PURE__ */ new Set();
|
|
70206
70219
|
for (let e = 0; e < n.length; e++) {
|
|
70207
70220
|
let t = i.assignments[e];
|
|
70208
70221
|
t >= 0 && t < r.length && (this._addMismatchedPair(n[e], r[t]), a.add(e), c.add(t));
|
|
@@ -70307,12 +70320,12 @@ var ZP = class extends o_ {
|
|
|
70307
70320
|
super.finish();
|
|
70308
70321
|
}
|
|
70309
70322
|
};
|
|
70310
|
-
function
|
|
70311
|
-
return new
|
|
70323
|
+
function $P(e, t, n) {
|
|
70324
|
+
return new QP(e, t, n);
|
|
70312
70325
|
}
|
|
70313
70326
|
//#endregion
|
|
70314
70327
|
//#region src/animation/transform/TransformMatchingCode.ts
|
|
70315
|
-
var
|
|
70328
|
+
var eF = .25, tF = 1, nF = class extends o_ {
|
|
70316
70329
|
target;
|
|
70317
70330
|
keyFunc;
|
|
70318
70331
|
fadeRatio;
|
|
@@ -70324,7 +70337,7 @@ var $P = .25, eF = 1, tF = class extends o_ {
|
|
|
70324
70337
|
_fadeOutParts = [];
|
|
70325
70338
|
_fadeInParts = [];
|
|
70326
70339
|
constructor(e, t, n = {}) {
|
|
70327
|
-
super(e, n), this.target = t, this.keyFunc = n.keyFunc, this.fadeRatio = Math.min(.5, Math.max(0, n.fadeRatio ??
|
|
70340
|
+
super(e, n), this.target = t, this.keyFunc = n.keyFunc, this.fadeRatio = Math.min(.5, Math.max(0, n.fadeRatio ?? eF)), this.matchBy = n.matchBy ?? "token", this.transformMismatches = n.transformMismatches ?? !1, this.fadeTransformMismatches = n.fadeTransformMismatches ?? !1;
|
|
70328
70341
|
}
|
|
70329
70342
|
get matchedParts() {
|
|
70330
70343
|
return this._matchedParts;
|
|
@@ -70400,19 +70413,19 @@ var $P = .25, eF = 1, tF = class extends o_ {
|
|
|
70400
70413
|
}
|
|
70401
70414
|
_addMatchedPart(e, t, n) {
|
|
70402
70415
|
let r = this.mobject.makeTokenMobject(e.text, e.type);
|
|
70403
|
-
this._place(r, e.position), r.opacity =
|
|
70416
|
+
this._place(r, e.position), r.opacity = tF, this._parentAdd(r), n.push({
|
|
70404
70417
|
mobject: r,
|
|
70405
70418
|
startPosition: e.position,
|
|
70406
70419
|
targetPosition: t.position,
|
|
70407
|
-
startOpacity:
|
|
70408
|
-
targetOpacity:
|
|
70420
|
+
startOpacity: tF,
|
|
70421
|
+
targetOpacity: tF
|
|
70409
70422
|
});
|
|
70410
70423
|
}
|
|
70411
70424
|
_addFadeOutPart(e) {
|
|
70412
70425
|
let t = this.mobject.makeTokenMobject(e.text, e.type);
|
|
70413
|
-
this._place(t, e.position), t.opacity =
|
|
70426
|
+
this._place(t, e.position), t.opacity = tF, this._parentAdd(t), this._fadeOutParts.push({
|
|
70414
70427
|
mobject: t,
|
|
70415
|
-
startOpacity:
|
|
70428
|
+
startOpacity: tF,
|
|
70416
70429
|
targetOpacity: 0,
|
|
70417
70430
|
fadeIn: !1
|
|
70418
70431
|
});
|
|
@@ -70422,7 +70435,7 @@ var $P = .25, eF = 1, tF = class extends o_ {
|
|
|
70422
70435
|
this._place(t, e.position), t.opacity = 0, this._parentAdd(t), this._fadeInParts.push({
|
|
70423
70436
|
mobject: t,
|
|
70424
70437
|
startOpacity: 0,
|
|
70425
|
-
targetOpacity:
|
|
70438
|
+
targetOpacity: tF,
|
|
70426
70439
|
fadeIn: !0
|
|
70427
70440
|
});
|
|
70428
70441
|
}
|
|
@@ -70447,16 +70460,16 @@ var $P = .25, eF = 1, tF = class extends o_ {
|
|
|
70447
70460
|
super.finish();
|
|
70448
70461
|
}
|
|
70449
70462
|
};
|
|
70450
|
-
function
|
|
70451
|
-
return new
|
|
70463
|
+
function rF(e, t, n) {
|
|
70464
|
+
return new nF(e, t, n);
|
|
70452
70465
|
}
|
|
70453
70466
|
//#endregion
|
|
70454
70467
|
//#region src/animation/transform/ApplyPointwiseFunction.ts
|
|
70455
|
-
function
|
|
70468
|
+
function iF(e) {
|
|
70456
70469
|
let t = e;
|
|
70457
70470
|
return typeof t.getLocalPoints == "function" && typeof t.setPoints == "function";
|
|
70458
70471
|
}
|
|
70459
|
-
var
|
|
70472
|
+
var aF = class extends o_ {
|
|
70460
70473
|
func;
|
|
70461
70474
|
_snapshots = [];
|
|
70462
70475
|
constructor(e, t, n) {
|
|
@@ -70465,7 +70478,7 @@ var iF = class extends o_ {
|
|
|
70465
70478
|
begin() {
|
|
70466
70479
|
super.begin(), this._snapshots = [];
|
|
70467
70480
|
let e = new L();
|
|
70468
|
-
for (let t of this.mobject.getFamily()) if (
|
|
70481
|
+
for (let t of this.mobject.getFamily()) if (iF(t)) {
|
|
70469
70482
|
let n = t.getLocalPoints();
|
|
70470
70483
|
if (n.length === 0) continue;
|
|
70471
70484
|
let r = t._worldMatrix(), i = r.clone().invert(), a = n.map((t) => {
|
|
@@ -70501,16 +70514,16 @@ var iF = class extends o_ {
|
|
|
70501
70514
|
this.mobject._markDirtyUpward(), super.finish();
|
|
70502
70515
|
}
|
|
70503
70516
|
};
|
|
70504
|
-
function
|
|
70505
|
-
return new
|
|
70517
|
+
function oF(e, t, n) {
|
|
70518
|
+
return new aF(e, t, n);
|
|
70506
70519
|
}
|
|
70507
70520
|
//#endregion
|
|
70508
70521
|
//#region src/animation/transform/ApplyPointwiseFunctionToCenter.ts
|
|
70509
|
-
function
|
|
70522
|
+
function sF(e) {
|
|
70510
70523
|
let t = e;
|
|
70511
70524
|
return typeof t.getLocalPoints == "function" && typeof t.setPoints == "function";
|
|
70512
70525
|
}
|
|
70513
|
-
var
|
|
70526
|
+
var cF = class extends o_ {
|
|
70514
70527
|
func;
|
|
70515
70528
|
_snapshots = [];
|
|
70516
70529
|
constructor(e, t, n) {
|
|
@@ -70519,7 +70532,7 @@ var sF = class extends o_ {
|
|
|
70519
70532
|
begin() {
|
|
70520
70533
|
super.begin(), this._snapshots = [];
|
|
70521
70534
|
let e = new L();
|
|
70522
|
-
for (let t of this.mobject.getFamily()) if (
|
|
70535
|
+
for (let t of this.mobject.getFamily()) if (sF(t)) {
|
|
70523
70536
|
let n = t.getLocalPoints();
|
|
70524
70537
|
if (n.length === 0) continue;
|
|
70525
70538
|
let r = t, i = r._threeObject, a = null, o = null;
|
|
@@ -70568,12 +70581,12 @@ var sF = class extends o_ {
|
|
|
70568
70581
|
this.mobject._markDirtyUpward(), super.finish();
|
|
70569
70582
|
}
|
|
70570
70583
|
};
|
|
70571
|
-
function
|
|
70572
|
-
return new
|
|
70584
|
+
function lF(e, t, n) {
|
|
70585
|
+
return new cF(e, t, n);
|
|
70573
70586
|
}
|
|
70574
70587
|
//#endregion
|
|
70575
70588
|
//#region src/animation/movement/Rotate.ts
|
|
70576
|
-
var
|
|
70589
|
+
var uF = class extends o_ {
|
|
70577
70590
|
angle;
|
|
70578
70591
|
axis;
|
|
70579
70592
|
aboutPoint;
|
|
@@ -70754,7 +70767,7 @@ var lF = class extends o_ {
|
|
|
70754
70767
|
this.interpolate(1), super.finish();
|
|
70755
70768
|
}
|
|
70756
70769
|
};
|
|
70757
|
-
function
|
|
70770
|
+
function dF(e, t, n) {
|
|
70758
70771
|
if (typeof t != "number") throw TypeError("rotate(): angle must be a number");
|
|
70759
70772
|
return n && (() => {
|
|
70760
70773
|
let e = (e) => (e.duration === void 0 || typeof e.duration == "number") && (e.rateFunc === void 0 || !0) && (e.shift === void 0 || Array.isArray(e.shift) && e.shift.length === 3 && typeof e.shift[0] == "number" && typeof e.shift[1] == "number" && typeof e.shift[2] == "number") && (e.axis === void 0 || Array.isArray(e.axis) && e.axis.length === 3 && typeof e.axis[0] == "number" && typeof e.axis[1] == "number" && typeof e.axis[2] == "number") && (e.aboutPoint === void 0 || Array.isArray(e.aboutPoint) && e.aboutPoint.length === 3 && typeof e.aboutPoint[0] == "number" && typeof e.aboutPoint[1] == "number" && typeof e.aboutPoint[2] == "number") && (e.aboutEdge === void 0 || Array.isArray(e.aboutEdge) && e.aboutEdge.length === 3 && typeof e.aboutEdge[0] == "number" && typeof e.aboutEdge[1] == "number" && typeof e.aboutEdge[2] == "number"), t = (e, t, n = !0) => (e.duration === void 0 || typeof e.duration == "number" || B(n, {
|
|
@@ -70894,17 +70907,17 @@ function uF(e, t, n) {
|
|
|
70894
70907
|
expected: "Omit<RotateOptions, \"angle\">",
|
|
70895
70908
|
value: e
|
|
70896
70909
|
}, r))(e, "$input", !0)), e);
|
|
70897
|
-
})()(n), new
|
|
70910
|
+
})()(n), new uF(e, {
|
|
70898
70911
|
...n,
|
|
70899
70912
|
angle: t
|
|
70900
70913
|
});
|
|
70901
70914
|
}
|
|
70902
70915
|
//#endregion
|
|
70903
70916
|
//#region src/animation/movement/Scale.ts
|
|
70904
|
-
function
|
|
70917
|
+
function fF(e, t, n) {
|
|
70905
70918
|
return new L(e.x + (t.x - e.x) * n, e.y + (t.y - e.y) * n, e.z + (t.z - e.z) * n);
|
|
70906
70919
|
}
|
|
70907
|
-
var
|
|
70920
|
+
var pF = class extends o_ {
|
|
70908
70921
|
scaleFactor;
|
|
70909
70922
|
aboutPoint;
|
|
70910
70923
|
_initialScale = new L();
|
|
@@ -70929,7 +70942,7 @@ var fF = class extends o_ {
|
|
|
70929
70942
|
}
|
|
70930
70943
|
}
|
|
70931
70944
|
interpolate(e) {
|
|
70932
|
-
let t =
|
|
70945
|
+
let t = fF(this._initialScale, this._targetScale, e);
|
|
70933
70946
|
if (this.mobject.scaleVector.copy(t), this._aboutPointVector) {
|
|
70934
70947
|
let e = new L(t.x / this._initialScale.x, t.y / this._initialScale.y, t.z / this._initialScale.z), n = new L().copy(this._initialPosition).sub(this._aboutPointVector);
|
|
70935
70948
|
n.multiply(e);
|
|
@@ -70942,13 +70955,13 @@ var fF = class extends o_ {
|
|
|
70942
70955
|
this.interpolate(1), super.finish();
|
|
70943
70956
|
}
|
|
70944
70957
|
};
|
|
70945
|
-
function
|
|
70946
|
-
return new
|
|
70958
|
+
function mF(e, t, n) {
|
|
70959
|
+
return new pF(e, {
|
|
70947
70960
|
...n,
|
|
70948
70961
|
scaleFactor: t
|
|
70949
70962
|
});
|
|
70950
70963
|
}
|
|
70951
|
-
var
|
|
70964
|
+
var hF = class extends o_ {
|
|
70952
70965
|
_targetScale = new L();
|
|
70953
70966
|
constructor(e, t = {}) {
|
|
70954
70967
|
super(e, t);
|
|
@@ -70963,12 +70976,12 @@ var mF = class extends o_ {
|
|
|
70963
70976
|
this.mobject.scaleVector.copy(this._targetScale), this.mobject._markDirty(), super.finish();
|
|
70964
70977
|
}
|
|
70965
70978
|
};
|
|
70966
|
-
function
|
|
70967
|
-
return new
|
|
70979
|
+
function gF(e, t) {
|
|
70980
|
+
return new hF(e, t);
|
|
70968
70981
|
}
|
|
70969
70982
|
//#endregion
|
|
70970
70983
|
//#region src/animation/movement/Shift.ts
|
|
70971
|
-
var
|
|
70984
|
+
var _F = class extends o_ {
|
|
70972
70985
|
direction;
|
|
70973
70986
|
_initialPosition = new L();
|
|
70974
70987
|
_targetPosition = new L();
|
|
@@ -70986,13 +70999,13 @@ var gF = class extends o_ {
|
|
|
70986
70999
|
this.mobject.position.set(this._initialPosition.x + this.direction[0] * e, this._initialPosition.y + this.direction[1] * e, this._initialPosition.z + this.direction[2] * e), this.mobject._markDirty(), super.finish();
|
|
70987
71000
|
}
|
|
70988
71001
|
};
|
|
70989
|
-
function
|
|
70990
|
-
return new
|
|
71002
|
+
function vF(e, t, n) {
|
|
71003
|
+
return new _F(e, {
|
|
70991
71004
|
...n,
|
|
70992
71005
|
direction: t
|
|
70993
71006
|
});
|
|
70994
71007
|
}
|
|
70995
|
-
var
|
|
71008
|
+
var yF = class extends o_ {
|
|
70996
71009
|
_initialPosition = new L();
|
|
70997
71010
|
_targetPosition = new L();
|
|
70998
71011
|
constructor(e, t = {}) {
|
|
@@ -71010,12 +71023,12 @@ var vF = class extends o_ {
|
|
|
71010
71023
|
this.mobject.position.copy(this._targetPosition), this.mobject._markDirty(), super.finish();
|
|
71011
71024
|
}
|
|
71012
71025
|
};
|
|
71013
|
-
function
|
|
71014
|
-
return new
|
|
71026
|
+
function bF(e, t) {
|
|
71027
|
+
return new yF(e, t);
|
|
71015
71028
|
}
|
|
71016
71029
|
//#endregion
|
|
71017
71030
|
//#region src/animation/movement/MoveAlongPath.ts
|
|
71018
|
-
function
|
|
71031
|
+
function xF(e, t, n, r, i) {
|
|
71019
71032
|
let a = 1 - i, o = a * a, s = o * a, c = i * i, l = c * i;
|
|
71020
71033
|
return [
|
|
71021
71034
|
s * e[0] + 3 * o * i * t[0] + 3 * a * c * n[0] + l * r[0],
|
|
@@ -71023,7 +71036,7 @@ function bF(e, t, n, r, i) {
|
|
|
71023
71036
|
s * e[2] + 3 * o * i * t[2] + 3 * a * c * n[2] + l * r[2]
|
|
71024
71037
|
];
|
|
71025
71038
|
}
|
|
71026
|
-
function
|
|
71039
|
+
function SF(e, t, n, r, i) {
|
|
71027
71040
|
let a = 1 - i, o = a * a, s = i * i;
|
|
71028
71041
|
return [
|
|
71029
71042
|
3 * o * (t[0] - e[0]) + 6 * a * i * (n[0] - t[0]) + 3 * s * (r[0] - n[0]),
|
|
@@ -71031,7 +71044,7 @@ function xF(e, t, n, r, i) {
|
|
|
71031
71044
|
3 * o * (t[2] - e[2]) + 6 * a * i * (n[2] - t[2]) + 3 * s * (r[2] - n[2])
|
|
71032
71045
|
];
|
|
71033
71046
|
}
|
|
71034
|
-
var
|
|
71047
|
+
var CF = class extends o_ {
|
|
71035
71048
|
path;
|
|
71036
71049
|
rotateAlongPath;
|
|
71037
71050
|
_pathPoints = [];
|
|
@@ -71073,8 +71086,8 @@ var SF = class extends o_ {
|
|
|
71073
71086
|
e = Math.max(0, Math.min(1, e));
|
|
71074
71087
|
let t = e * this._numSegments, n = Math.min(Math.floor(t), this._numSegments - 1), r = t - n, i = n * 3, a = this._pathPoints[i], o = this._pathPoints[i + 1], s = this._pathPoints[i + 2], c = this._pathPoints[i + 3];
|
|
71075
71088
|
return {
|
|
71076
|
-
position:
|
|
71077
|
-
tangent:
|
|
71089
|
+
position: xF(a, o, s, c, r),
|
|
71090
|
+
tangent: SF(a, o, s, c, r)
|
|
71078
71091
|
};
|
|
71079
71092
|
}
|
|
71080
71093
|
interpolate(e) {
|
|
@@ -71093,15 +71106,15 @@ var SF = class extends o_ {
|
|
|
71093
71106
|
this.interpolate(1), super.finish();
|
|
71094
71107
|
}
|
|
71095
71108
|
};
|
|
71096
|
-
function
|
|
71097
|
-
return new
|
|
71109
|
+
function wF(e, t, n) {
|
|
71110
|
+
return new CF(e, {
|
|
71098
71111
|
...n,
|
|
71099
71112
|
path: t
|
|
71100
71113
|
});
|
|
71101
71114
|
}
|
|
71102
71115
|
//#endregion
|
|
71103
71116
|
//#region src/utils/ode.ts
|
|
71104
|
-
function
|
|
71117
|
+
function TF(e, t, n, r) {
|
|
71105
71118
|
let i = n.length, a = e(t, n), o = Array(i);
|
|
71106
71119
|
for (let e = 0; e < i; e++) o[e] = n[e] + .5 * r * a[e];
|
|
71107
71120
|
let s = e(t + .5 * r, o), c = Array(i);
|
|
@@ -71112,7 +71125,7 @@ function wF(e, t, n, r) {
|
|
|
71112
71125
|
for (let e = 0; e < i; e++) f[e] = n[e] + r / 6 * (a[e] + 2 * s[e] + 2 * l[e] + d[e]);
|
|
71113
71126
|
return f;
|
|
71114
71127
|
}
|
|
71115
|
-
function
|
|
71128
|
+
function EF(e, t, n, r, i = {}) {
|
|
71116
71129
|
let { recordTrajectory: a = !1 } = i, o, s;
|
|
71117
71130
|
i.stepSize === void 0 ? (o = i.numSteps ?? 100, s = (r - t) / o) : (s = i.stepSize, o = Math.max(1, Math.ceil(Math.abs(r - t) / Math.abs(s))), s = (r - t) / o);
|
|
71118
71131
|
let c = [], l = t, u = [...n];
|
|
@@ -71120,7 +71133,7 @@ function TF(e, t, n, r, i = {}) {
|
|
|
71120
71133
|
t: l,
|
|
71121
71134
|
y: [...u]
|
|
71122
71135
|
});
|
|
71123
|
-
for (let n = 0; n < o; n++) u =
|
|
71136
|
+
for (let n = 0; n < o; n++) u = TF(e, l, u, s), l = t + (n + 1) * s, a && c.push({
|
|
71124
71137
|
t: l,
|
|
71125
71138
|
y: [...u]
|
|
71126
71139
|
});
|
|
@@ -71130,9 +71143,9 @@ function TF(e, t, n, r, i = {}) {
|
|
|
71130
71143
|
trajectory: c
|
|
71131
71144
|
};
|
|
71132
71145
|
}
|
|
71133
|
-
function
|
|
71146
|
+
function DF(e, t, n, r = 100) {
|
|
71134
71147
|
if (n === 0) return [...t];
|
|
71135
|
-
let i =
|
|
71148
|
+
let i = EF((t, n) => {
|
|
71136
71149
|
let r = e([
|
|
71137
71150
|
n[0],
|
|
71138
71151
|
n[1],
|
|
@@ -71152,14 +71165,14 @@ function EF(e, t, n, r = 100) {
|
|
|
71152
71165
|
}
|
|
71153
71166
|
//#endregion
|
|
71154
71167
|
//#region src/animation/movement/Homotopy.ts
|
|
71155
|
-
function
|
|
71168
|
+
function OF(e) {
|
|
71156
71169
|
let t = e._worldMatrix();
|
|
71157
71170
|
return {
|
|
71158
71171
|
worldMatrix: t,
|
|
71159
71172
|
inverseWorld: t.clone().invert()
|
|
71160
71173
|
};
|
|
71161
71174
|
}
|
|
71162
|
-
function
|
|
71175
|
+
function kF(e, t) {
|
|
71163
71176
|
let n = new L(t[0], t[1], t[2]).applyMatrix4(e);
|
|
71164
71177
|
return [
|
|
71165
71178
|
n.x,
|
|
@@ -71167,7 +71180,7 @@ function OF(e, t) {
|
|
|
71167
71180
|
n.z
|
|
71168
71181
|
];
|
|
71169
71182
|
}
|
|
71170
|
-
var
|
|
71183
|
+
var AF = class extends o_ {
|
|
71171
71184
|
homotopyFunc;
|
|
71172
71185
|
_originalPoints = null;
|
|
71173
71186
|
_frame = null;
|
|
@@ -71176,7 +71189,7 @@ var kF = class extends o_ {
|
|
|
71176
71189
|
super(e, t), this.homotopyFunc = t.homotopyFunc;
|
|
71177
71190
|
}
|
|
71178
71191
|
begin() {
|
|
71179
|
-
super.begin(), this.mobject instanceof V ? (this._isVMobject = !0, this._originalPoints = this.mobject.getLocalPoints(), this._frame =
|
|
71192
|
+
super.begin(), this.mobject instanceof V ? (this._isVMobject = !0, this._originalPoints = this.mobject.getLocalPoints(), this._frame = OF(this.mobject)) : (this._isVMobject = !1, this._originalPoints = null, this._frame = null);
|
|
71180
71193
|
}
|
|
71181
71194
|
interpolate(e) {
|
|
71182
71195
|
if (!this._isVMobject || !this._originalPoints || !this._frame) {
|
|
@@ -71186,15 +71199,15 @@ var kF = class extends o_ {
|
|
|
71186
71199
|
}
|
|
71187
71200
|
let t = this.mobject, { worldMatrix: n, inverseWorld: r } = this._frame, i = [];
|
|
71188
71201
|
for (let t of this._originalPoints) {
|
|
71189
|
-
let [a, o, s] =
|
|
71190
|
-
i.push(
|
|
71202
|
+
let [a, o, s] = kF(n, t), c = this.homotopyFunc(a, o, s, e);
|
|
71203
|
+
i.push(kF(r, c));
|
|
71191
71204
|
}
|
|
71192
71205
|
t.setPoints3D(i);
|
|
71193
71206
|
}
|
|
71194
71207
|
finish() {
|
|
71195
71208
|
this.interpolate(1), super.finish();
|
|
71196
71209
|
}
|
|
71197
|
-
},
|
|
71210
|
+
}, jF = class extends o_ {
|
|
71198
71211
|
complexFunc;
|
|
71199
71212
|
_originalPoints = null;
|
|
71200
71213
|
_frame = null;
|
|
@@ -71203,7 +71216,7 @@ var kF = class extends o_ {
|
|
|
71203
71216
|
super(e, t), this.complexFunc = t.complexFunc;
|
|
71204
71217
|
}
|
|
71205
71218
|
begin() {
|
|
71206
|
-
super.begin(), this.mobject instanceof V ? (this._isVMobject = !0, this._originalPoints = this.mobject.getLocalPoints(), this._frame =
|
|
71219
|
+
super.begin(), this.mobject instanceof V ? (this._isVMobject = !0, this._originalPoints = this.mobject.getLocalPoints(), this._frame = OF(this.mobject)) : (this._isVMobject = !1, this._originalPoints = null, this._frame = null);
|
|
71207
71220
|
}
|
|
71208
71221
|
interpolate(e) {
|
|
71209
71222
|
if (!this._isVMobject || !this._originalPoints || !this._frame) {
|
|
@@ -71216,11 +71229,11 @@ var kF = class extends o_ {
|
|
|
71216
71229
|
}
|
|
71217
71230
|
let t = this.mobject, { worldMatrix: n, inverseWorld: r } = this._frame, i = [];
|
|
71218
71231
|
for (let t of this._originalPoints) {
|
|
71219
|
-
let [a, o, s] =
|
|
71232
|
+
let [a, o, s] = kF(n, t), c = this.complexFunc({
|
|
71220
71233
|
re: a,
|
|
71221
71234
|
im: o
|
|
71222
71235
|
}, e);
|
|
71223
|
-
i.push(
|
|
71236
|
+
i.push(kF(r, [
|
|
71224
71237
|
c.re,
|
|
71225
71238
|
c.im,
|
|
71226
71239
|
s
|
|
@@ -71231,7 +71244,7 @@ var kF = class extends o_ {
|
|
|
71231
71244
|
finish() {
|
|
71232
71245
|
this.interpolate(1), super.finish();
|
|
71233
71246
|
}
|
|
71234
|
-
},
|
|
71247
|
+
}, MF = class extends o_ {
|
|
71235
71248
|
homotopyFunc;
|
|
71236
71249
|
_originalPoints = null;
|
|
71237
71250
|
_frame = null;
|
|
@@ -71242,9 +71255,9 @@ var kF = class extends o_ {
|
|
|
71242
71255
|
begin() {
|
|
71243
71256
|
super.begin();
|
|
71244
71257
|
let e = this.mobject;
|
|
71245
|
-
this._frame =
|
|
71258
|
+
this._frame = OF(e);
|
|
71246
71259
|
let { worldMatrix: t } = this._frame;
|
|
71247
|
-
this._originalPoints = e.getLocalPoints().map((e) =>
|
|
71260
|
+
this._originalPoints = e.getLocalPoints().map((e) => kF(t, e)), this._anchorIndices = [];
|
|
71248
71261
|
for (let e = 0; e < this._originalPoints.length; e += 3) this._anchorIndices.push(e);
|
|
71249
71262
|
let n = this._originalPoints.length - 1;
|
|
71250
71263
|
n >= 0 && !this._anchorIndices.includes(n) && this._anchorIndices.push(n);
|
|
@@ -71261,7 +71274,7 @@ var kF = class extends o_ {
|
|
|
71261
71274
|
}
|
|
71262
71275
|
for (let t = 0; t < n; t++) i.has(t) || (r[t] = this._transformHandle(t, e, i));
|
|
71263
71276
|
let { inverseWorld: a } = this._frame;
|
|
71264
|
-
t.setPoints3D(r.map((e) =>
|
|
71277
|
+
t.setPoints3D(r.map((e) => kF(a, e)));
|
|
71265
71278
|
}
|
|
71266
71279
|
_transformHandle(e, t, n) {
|
|
71267
71280
|
let r = this._originalPoints[e], i = -1, a = -1;
|
|
@@ -71295,7 +71308,7 @@ var kF = class extends o_ {
|
|
|
71295
71308
|
finish() {
|
|
71296
71309
|
this.interpolate(1), super.finish();
|
|
71297
71310
|
}
|
|
71298
|
-
},
|
|
71311
|
+
}, NF = class extends o_ {
|
|
71299
71312
|
vectorField;
|
|
71300
71313
|
virtualTime;
|
|
71301
71314
|
_originalPoints = null;
|
|
@@ -71307,7 +71320,7 @@ var kF = class extends o_ {
|
|
|
71307
71320
|
super(e, t), this.vectorField = t.vectorField, this.virtualTime = t.virtualTime ?? 1, this._integrationSteps = t.integrationSteps ?? 100;
|
|
71308
71321
|
}
|
|
71309
71322
|
begin() {
|
|
71310
|
-
if (super.begin(), this.mobject instanceof V) this._isVMobject = !0, this._originalPoints = this.mobject.getLocalPoints(), this._frame =
|
|
71323
|
+
if (super.begin(), this.mobject instanceof V) this._isVMobject = !0, this._originalPoints = this.mobject.getLocalPoints(), this._frame = OF(this.mobject);
|
|
71311
71324
|
else {
|
|
71312
71325
|
this._isVMobject = !1, this._originalPoints = null, this._frame = null;
|
|
71313
71326
|
let e = this.mobject.position;
|
|
@@ -71325,14 +71338,14 @@ var kF = class extends o_ {
|
|
|
71325
71338
|
this.mobject.position.x,
|
|
71326
71339
|
this.mobject.position.y,
|
|
71327
71340
|
this.mobject.position.z
|
|
71328
|
-
], [n, r, i] =
|
|
71341
|
+
], [n, r, i] = DF(this.vectorField, e, t, this._integrationSteps);
|
|
71329
71342
|
this.mobject.position.set(n, r, i), this.mobject._markDirty();
|
|
71330
71343
|
return;
|
|
71331
71344
|
}
|
|
71332
71345
|
let n = this.mobject, { worldMatrix: r, inverseWorld: i } = this._frame, a = [];
|
|
71333
71346
|
for (let e of this._originalPoints) {
|
|
71334
|
-
let n =
|
|
71335
|
-
a.push(
|
|
71347
|
+
let n = DF(this.vectorField, kF(r, e), t, this._integrationSteps);
|
|
71348
|
+
a.push(kF(i, n));
|
|
71336
71349
|
}
|
|
71337
71350
|
n.setPoints3D(a);
|
|
71338
71351
|
}
|
|
@@ -71340,33 +71353,33 @@ var kF = class extends o_ {
|
|
|
71340
71353
|
this.interpolate(1), super.finish();
|
|
71341
71354
|
}
|
|
71342
71355
|
};
|
|
71343
|
-
function NF(e, t, n) {
|
|
71344
|
-
return new kF(e, {
|
|
71345
|
-
...n,
|
|
71346
|
-
homotopyFunc: t
|
|
71347
|
-
});
|
|
71348
|
-
}
|
|
71349
71356
|
function PF(e, t, n) {
|
|
71350
71357
|
return new AF(e, {
|
|
71351
71358
|
...n,
|
|
71352
|
-
|
|
71359
|
+
homotopyFunc: t
|
|
71353
71360
|
});
|
|
71354
71361
|
}
|
|
71355
71362
|
function FF(e, t, n) {
|
|
71356
71363
|
return new jF(e, {
|
|
71357
71364
|
...n,
|
|
71358
|
-
|
|
71365
|
+
complexFunc: t
|
|
71359
71366
|
});
|
|
71360
71367
|
}
|
|
71361
71368
|
function IF(e, t, n) {
|
|
71362
71369
|
return new MF(e, {
|
|
71370
|
+
...n,
|
|
71371
|
+
homotopyFunc: t
|
|
71372
|
+
});
|
|
71373
|
+
}
|
|
71374
|
+
function LF(e, t, n) {
|
|
71375
|
+
return new NF(e, {
|
|
71363
71376
|
...n,
|
|
71364
71377
|
vectorField: t
|
|
71365
71378
|
});
|
|
71366
71379
|
}
|
|
71367
71380
|
//#endregion
|
|
71368
71381
|
//#region src/animation/growing/index.ts
|
|
71369
|
-
var
|
|
71382
|
+
var RF = class extends o_ {
|
|
71370
71383
|
_start = new L();
|
|
71371
71384
|
_endShaftPos = new L();
|
|
71372
71385
|
_endTipPos = new L();
|
|
@@ -71424,10 +71437,10 @@ var LF = class extends o_ {
|
|
|
71424
71437
|
t.position.copy(this._endShaftPos), n.position.copy(this._endTipPos), t.scaleVector.copy(this._endShaftScale), n.scaleVector.copy(this._endTipScale), t._markDirty(), n._markDirty(), this.mobject._markDirty(), super.finish();
|
|
71425
71438
|
}
|
|
71426
71439
|
};
|
|
71427
|
-
function
|
|
71428
|
-
return new
|
|
71440
|
+
function zF(e, t) {
|
|
71441
|
+
return new RF(e, t);
|
|
71429
71442
|
}
|
|
71430
|
-
var
|
|
71443
|
+
var BF = class extends o_ {
|
|
71431
71444
|
edge;
|
|
71432
71445
|
_targetScale = new L();
|
|
71433
71446
|
_targetPosition = new L();
|
|
@@ -71448,13 +71461,13 @@ var zF = class extends o_ {
|
|
|
71448
71461
|
this.mobject.scaleVector.copy(this._targetScale), this.mobject.position.copy(this._targetPosition), this.mobject._markDirty(), super.finish();
|
|
71449
71462
|
}
|
|
71450
71463
|
};
|
|
71451
|
-
function
|
|
71452
|
-
return new
|
|
71464
|
+
function VF(e, t, n) {
|
|
71465
|
+
return new BF(e, {
|
|
71453
71466
|
...n,
|
|
71454
71467
|
edge: t
|
|
71455
71468
|
});
|
|
71456
71469
|
}
|
|
71457
|
-
var
|
|
71470
|
+
var HF = class extends o_ {
|
|
71458
71471
|
point;
|
|
71459
71472
|
_targetScale = new L();
|
|
71460
71473
|
_targetPosition = new L();
|
|
@@ -71473,13 +71486,13 @@ var VF = class extends o_ {
|
|
|
71473
71486
|
this.mobject.scaleVector.copy(this._targetScale), this.mobject.position.copy(this._targetPosition), this.mobject._markDirty(), super.finish();
|
|
71474
71487
|
}
|
|
71475
71488
|
};
|
|
71476
|
-
function
|
|
71477
|
-
return new
|
|
71489
|
+
function UF(e, t, n) {
|
|
71490
|
+
return new HF(e, {
|
|
71478
71491
|
...n,
|
|
71479
71492
|
point: t
|
|
71480
71493
|
});
|
|
71481
71494
|
}
|
|
71482
|
-
var
|
|
71495
|
+
var WF = class extends o_ {
|
|
71483
71496
|
angle;
|
|
71484
71497
|
axis;
|
|
71485
71498
|
_targetScale = new L();
|
|
@@ -71507,18 +71520,18 @@ var UF = class extends o_ {
|
|
|
71507
71520
|
this.mobject.scaleVector.copy(this._targetScale), this.mobject.rotation.copy(this._initialRotation), this.mobject._markDirty(), super.finish();
|
|
71508
71521
|
}
|
|
71509
71522
|
};
|
|
71510
|
-
function
|
|
71511
|
-
return new
|
|
71523
|
+
function GF(e, t) {
|
|
71524
|
+
return new WF(e, t);
|
|
71512
71525
|
}
|
|
71513
71526
|
//#endregion
|
|
71514
71527
|
//#region src/animation/LaggedStart.ts
|
|
71515
|
-
function
|
|
71528
|
+
function KF(e, t) {
|
|
71516
71529
|
return new zT(e, {
|
|
71517
71530
|
...t,
|
|
71518
71531
|
lagRatio: t?.lagRatio ?? .2
|
|
71519
71532
|
});
|
|
71520
71533
|
}
|
|
71521
|
-
var
|
|
71534
|
+
var qF = class extends zT {
|
|
71522
71535
|
constructor(e, t = {}) {
|
|
71523
71536
|
super(e, {
|
|
71524
71537
|
...t,
|
|
@@ -71528,13 +71541,13 @@ var KF = class extends zT {
|
|
|
71528
71541
|
};
|
|
71529
71542
|
//#endregion
|
|
71530
71543
|
//#region src/animation/Succession.ts
|
|
71531
|
-
function
|
|
71544
|
+
function JF(e, t) {
|
|
71532
71545
|
return new zT(e, {
|
|
71533
71546
|
...t,
|
|
71534
71547
|
lagRatio: 1
|
|
71535
71548
|
});
|
|
71536
71549
|
}
|
|
71537
|
-
var
|
|
71550
|
+
var YF = class extends zT {
|
|
71538
71551
|
constructor(e, t = {}) {
|
|
71539
71552
|
super(e, {
|
|
71540
71553
|
...t,
|
|
@@ -71544,14 +71557,14 @@ var JF = class extends zT {
|
|
|
71544
71557
|
};
|
|
71545
71558
|
//#endregion
|
|
71546
71559
|
//#region src/animation/composition/LaggedStartMap.ts
|
|
71547
|
-
function
|
|
71560
|
+
function XF(e, t, n) {
|
|
71548
71561
|
let { lagRatio: r = .2, animOptions: i, ...a } = n ?? {};
|
|
71549
71562
|
return new zT(t.map((t) => new e(t, i)), {
|
|
71550
71563
|
...a,
|
|
71551
71564
|
lagRatio: r
|
|
71552
71565
|
});
|
|
71553
71566
|
}
|
|
71554
|
-
var
|
|
71567
|
+
var ZF = class extends zT {
|
|
71555
71568
|
constructor(e, t, n = {}) {
|
|
71556
71569
|
let { lagRatio: r = .2, animOptions: i, ...a } = n, o = t.map((t) => new e(t, i));
|
|
71557
71570
|
super(o, {
|
|
@@ -71559,7 +71572,7 @@ var XF = class extends zT {
|
|
|
71559
71572
|
lagRatio: r
|
|
71560
71573
|
});
|
|
71561
71574
|
}
|
|
71562
|
-
},
|
|
71575
|
+
}, QF = class extends o_ {
|
|
71563
71576
|
_func;
|
|
71564
71577
|
constructor(e, t, n) {
|
|
71565
71578
|
super(e, n), this._func = t;
|
|
@@ -71568,18 +71581,18 @@ var XF = class extends zT {
|
|
|
71568
71581
|
this._func(this.mobject, e);
|
|
71569
71582
|
}
|
|
71570
71583
|
};
|
|
71571
|
-
function
|
|
71572
|
-
return new
|
|
71584
|
+
function $F(e, t, n) {
|
|
71585
|
+
return new QF(e, t, n);
|
|
71573
71586
|
}
|
|
71574
71587
|
//#endregion
|
|
71575
71588
|
//#region src/animation/UpdateFromAlphaFunc.ts
|
|
71576
|
-
var
|
|
71577
|
-
function
|
|
71578
|
-
return new
|
|
71589
|
+
var eI = class extends QF {};
|
|
71590
|
+
function tI(e, t, n) {
|
|
71591
|
+
return new eI(e, t, n);
|
|
71579
71592
|
}
|
|
71580
71593
|
//#endregion
|
|
71581
71594
|
//#region src/animation/MaintainPositionRelativeTo.ts
|
|
71582
|
-
function
|
|
71595
|
+
function nI(e, t) {
|
|
71583
71596
|
let n = [
|
|
71584
71597
|
e.position.x - t.position.x,
|
|
71585
71598
|
e.position.y - t.position.y,
|
|
@@ -71595,7 +71608,7 @@ function tI(e, t) {
|
|
|
71595
71608
|
}
|
|
71596
71609
|
//#endregion
|
|
71597
71610
|
//#region src/animation/AlwaysRedraw.ts
|
|
71598
|
-
function
|
|
71611
|
+
function rI(e) {
|
|
71599
71612
|
let t = e();
|
|
71600
71613
|
return t.addUpdater((t) => {
|
|
71601
71614
|
t.become(e());
|
|
@@ -71603,24 +71616,24 @@ function nI(e) {
|
|
|
71603
71616
|
}
|
|
71604
71617
|
//#endregion
|
|
71605
71618
|
//#region src/animation/Always.ts
|
|
71606
|
-
function
|
|
71619
|
+
function iI(e, t, ...n) {
|
|
71607
71620
|
return e.addUpdater(() => {
|
|
71608
71621
|
e[t].apply(e, n.map((e) => e()));
|
|
71609
71622
|
}), e;
|
|
71610
71623
|
}
|
|
71611
|
-
function
|
|
71624
|
+
function aI(e, t, ...n) {
|
|
71612
71625
|
return e.addUpdater(() => {
|
|
71613
71626
|
e[t].apply(e, n);
|
|
71614
71627
|
}), e;
|
|
71615
71628
|
}
|
|
71616
|
-
function
|
|
71629
|
+
function oI(e, t) {
|
|
71617
71630
|
if (!(e instanceof cp)) throw Error(`assertIsMobjectMethod: expected a Mobject, got ${e === null ? "null" : typeof e}`);
|
|
71618
71631
|
if (typeof e[t] != "function") throw Error(`assertIsMobjectMethod: "${t}" is not a method of ${e.constructor.name}`);
|
|
71619
71632
|
}
|
|
71620
71633
|
//#endregion
|
|
71621
71634
|
//#region src/animation/updaters.ts
|
|
71622
|
-
var
|
|
71623
|
-
function
|
|
71635
|
+
var sI = 20 * Math.PI / 180;
|
|
71636
|
+
function cI(e, t = Ad, n = .1) {
|
|
71624
71637
|
let r = Zd(t);
|
|
71625
71638
|
return e.addUpdater((e, t) => {
|
|
71626
71639
|
e.shift([
|
|
@@ -71630,12 +71643,12 @@ function sI(e, t = Ad, n = .1) {
|
|
|
71630
71643
|
]);
|
|
71631
71644
|
}), e;
|
|
71632
71645
|
}
|
|
71633
|
-
function
|
|
71646
|
+
function lI(e, t = sI, n) {
|
|
71634
71647
|
return e.addUpdater((e, r) => {
|
|
71635
71648
|
e.rotate(r * t, n);
|
|
71636
71649
|
}), e;
|
|
71637
71650
|
}
|
|
71638
|
-
function
|
|
71651
|
+
function uI(e, t = !1, n = 0) {
|
|
71639
71652
|
let r = e.mobject;
|
|
71640
71653
|
e.begin();
|
|
71641
71654
|
let i = -n, a = (n, r) => {
|
|
@@ -71657,12 +71670,12 @@ function lI(e, t = !1, n = 0) {
|
|
|
71657
71670
|
};
|
|
71658
71671
|
return r.addUpdater(a), r;
|
|
71659
71672
|
}
|
|
71660
|
-
function
|
|
71661
|
-
return
|
|
71673
|
+
function dI(e, t = 0) {
|
|
71674
|
+
return uI(e, !0, t);
|
|
71662
71675
|
}
|
|
71663
71676
|
//#endregion
|
|
71664
71677
|
//#region src/animation/numbers/index.ts
|
|
71665
|
-
var
|
|
71678
|
+
var fI = class extends o_ {
|
|
71666
71679
|
decimalNumber;
|
|
71667
71680
|
_startValue;
|
|
71668
71681
|
_endValue;
|
|
@@ -71684,7 +71697,7 @@ var dI = class extends o_ {
|
|
|
71684
71697
|
getEndValue() {
|
|
71685
71698
|
return this._endValue;
|
|
71686
71699
|
}
|
|
71687
|
-
},
|
|
71700
|
+
}, pI = class extends o_ {
|
|
71688
71701
|
decimalNumber;
|
|
71689
71702
|
_startValue;
|
|
71690
71703
|
_targetValue;
|
|
@@ -71710,15 +71723,15 @@ var dI = class extends o_ {
|
|
|
71710
71723
|
return this._targetValue;
|
|
71711
71724
|
}
|
|
71712
71725
|
};
|
|
71713
|
-
function pI(e, t) {
|
|
71714
|
-
return new dI(e, t);
|
|
71715
|
-
}
|
|
71716
71726
|
function mI(e, t) {
|
|
71717
71727
|
return new fI(e, t);
|
|
71718
71728
|
}
|
|
71729
|
+
function hI(e, t) {
|
|
71730
|
+
return new pI(e, t);
|
|
71731
|
+
}
|
|
71719
71732
|
//#endregion
|
|
71720
71733
|
//#region src/animation/changing/index.ts
|
|
71721
|
-
var
|
|
71734
|
+
var gI = class e extends V {
|
|
71722
71735
|
_trackedMobject;
|
|
71723
71736
|
_dissipatingTime;
|
|
71724
71737
|
_minDistanceToNewPoint;
|
|
@@ -71801,10 +71814,10 @@ var hI = class e extends V {
|
|
|
71801
71814
|
})), t._elapsedTime = this._elapsedTime, t._lastPosition = this._lastPosition ? [...this._lastPosition] : null, t;
|
|
71802
71815
|
}
|
|
71803
71816
|
};
|
|
71804
|
-
function
|
|
71805
|
-
return new
|
|
71817
|
+
function _I(e, t) {
|
|
71818
|
+
return new gI(e, t);
|
|
71806
71819
|
}
|
|
71807
|
-
var
|
|
71820
|
+
var vI = class e extends V {
|
|
71808
71821
|
_boundedMobject;
|
|
71809
71822
|
_colors;
|
|
71810
71823
|
_numDashes;
|
|
@@ -71928,12 +71941,12 @@ var _I = class e extends V {
|
|
|
71928
71941
|
this._dashes = [], super.dispose();
|
|
71929
71942
|
}
|
|
71930
71943
|
};
|
|
71931
|
-
function
|
|
71932
|
-
return new
|
|
71944
|
+
function yI(e, t) {
|
|
71945
|
+
return new vI(e, t);
|
|
71933
71946
|
}
|
|
71934
71947
|
//#endregion
|
|
71935
71948
|
//#region src/animation/speed/index.ts
|
|
71936
|
-
var
|
|
71949
|
+
var bI = class e extends cp {
|
|
71937
71950
|
normalizeTransform(e = this._ownMatrix()) {
|
|
71938
71951
|
return this._flattenAsContainer(e);
|
|
71939
71952
|
}
|
|
@@ -71944,7 +71957,7 @@ var yI = class e extends cp {
|
|
|
71944
71957
|
return new e();
|
|
71945
71958
|
}
|
|
71946
71959
|
};
|
|
71947
|
-
function
|
|
71960
|
+
function xI(e, t, n = 100) {
|
|
71948
71961
|
let r = 0, i = 1 / n;
|
|
71949
71962
|
for (let e = 0; e < n; e++) {
|
|
71950
71963
|
let a = e / n, o = (e + 1) / n, s = Math.max(.001, t(a)), c = Math.max(.001, t(o));
|
|
@@ -71952,7 +71965,7 @@ function bI(e, t, n = 100) {
|
|
|
71952
71965
|
}
|
|
71953
71966
|
return e * r;
|
|
71954
71967
|
}
|
|
71955
|
-
function
|
|
71968
|
+
function SI(e, t, n = 100) {
|
|
71956
71969
|
let r = 0, i = 1 / n, a = [0];
|
|
71957
71970
|
for (let e = 0; e < n; e++) {
|
|
71958
71971
|
let o = e / n, s = (e + 1) / n, c = Math.max(.001, t(o)), l = Math.max(.001, t(s));
|
|
@@ -71966,12 +71979,12 @@ function xI(e, t, n = 100) {
|
|
|
71966
71979
|
let l = a[s], u = a[Math.min(c, n)], d = u > l ? (o - l) / (u - l) : 0;
|
|
71967
71980
|
return Math.min(1, Math.max(0, (s + d) / n));
|
|
71968
71981
|
}
|
|
71969
|
-
var
|
|
71982
|
+
var CI = class extends o_ {
|
|
71970
71983
|
animation;
|
|
71971
71984
|
speedFunc;
|
|
71972
71985
|
_numSamples = 200;
|
|
71973
71986
|
constructor(e, t, n = {}) {
|
|
71974
|
-
let r = new
|
|
71987
|
+
let r = new bI(), i = xI(e.duration, t);
|
|
71975
71988
|
super(r, {
|
|
71976
71989
|
duration: i,
|
|
71977
71990
|
rateFunc: n.rateFunc ?? rg
|
|
@@ -71981,7 +71994,7 @@ var SI = class extends o_ {
|
|
|
71981
71994
|
super.begin(), this.animation.begin();
|
|
71982
71995
|
}
|
|
71983
71996
|
interpolate(e) {
|
|
71984
|
-
let t =
|
|
71997
|
+
let t = SI(e, this.speedFunc, this._numSamples), n = this.animation.rateFunc(t);
|
|
71985
71998
|
this.animation.interpolate(n);
|
|
71986
71999
|
}
|
|
71987
72000
|
finish() {
|
|
@@ -71991,19 +72004,19 @@ var SI = class extends o_ {
|
|
|
71991
72004
|
super.reset(), this.animation.reset();
|
|
71992
72005
|
}
|
|
71993
72006
|
};
|
|
71994
|
-
function
|
|
71995
|
-
return new
|
|
72007
|
+
function wI(e, t, n) {
|
|
72008
|
+
return new CI(e, t, n);
|
|
71996
72009
|
}
|
|
71997
|
-
function
|
|
72010
|
+
function TI(e, t) {
|
|
71998
72011
|
return (n) => e + (t - e) * n;
|
|
71999
72012
|
}
|
|
72000
|
-
function
|
|
72013
|
+
function EI(e, t, n = 2, r = .5) {
|
|
72001
72014
|
return (i) => i >= e && i <= t ? r : n;
|
|
72002
72015
|
}
|
|
72003
|
-
function
|
|
72016
|
+
function DI(e, t, n = 1, r = 3) {
|
|
72004
72017
|
return (i) => i >= e && i <= t ? r : n;
|
|
72005
72018
|
}
|
|
72006
|
-
function
|
|
72019
|
+
function OI(e, t) {
|
|
72007
72020
|
return (n) => {
|
|
72008
72021
|
let r = (1 + Math.cos(2 * Math.PI * n)) / 2;
|
|
72009
72022
|
return e + (t - e) * r;
|
|
@@ -72011,7 +72024,7 @@ function DI(e, t) {
|
|
|
72011
72024
|
}
|
|
72012
72025
|
//#endregion
|
|
72013
72026
|
//#region src/animation/utility/index.ts
|
|
72014
|
-
var
|
|
72027
|
+
var kI = class extends o_ {
|
|
72015
72028
|
constructor(e, t = {}) {
|
|
72016
72029
|
super(e, {
|
|
72017
72030
|
...t,
|
|
@@ -72023,10 +72036,10 @@ var OI = class extends o_ {
|
|
|
72023
72036
|
}
|
|
72024
72037
|
interpolate(e) {}
|
|
72025
72038
|
};
|
|
72026
|
-
function
|
|
72027
|
-
return new
|
|
72039
|
+
function AI(e, t) {
|
|
72040
|
+
return new kI(e, t);
|
|
72028
72041
|
}
|
|
72029
|
-
var
|
|
72042
|
+
var jI = class extends o_ {
|
|
72030
72043
|
constructor(e, t = {}) {
|
|
72031
72044
|
super(e, {
|
|
72032
72045
|
...t,
|
|
@@ -72038,10 +72051,10 @@ var AI = class extends o_ {
|
|
|
72038
72051
|
}
|
|
72039
72052
|
interpolate(e) {}
|
|
72040
72053
|
};
|
|
72041
|
-
function
|
|
72042
|
-
return new
|
|
72054
|
+
function MI(e, t) {
|
|
72055
|
+
return new jI(e, t);
|
|
72043
72056
|
}
|
|
72044
|
-
var
|
|
72057
|
+
var NI = class extends o_ {
|
|
72045
72058
|
constructor(e, t = {}) {
|
|
72046
72059
|
super(e, {
|
|
72047
72060
|
duration: t.duration ?? 1,
|
|
@@ -72050,13 +72063,13 @@ var MI = class extends o_ {
|
|
|
72050
72063
|
}
|
|
72051
72064
|
interpolate(e) {}
|
|
72052
72065
|
};
|
|
72053
|
-
function
|
|
72054
|
-
return new
|
|
72066
|
+
function PI(e, t, n) {
|
|
72067
|
+
return new NI(e, {
|
|
72055
72068
|
...n,
|
|
72056
72069
|
duration: t
|
|
72057
72070
|
});
|
|
72058
72071
|
}
|
|
72059
|
-
var
|
|
72072
|
+
var FI = class extends o_ {
|
|
72060
72073
|
angle;
|
|
72061
72074
|
axis;
|
|
72062
72075
|
aboutPoint;
|
|
@@ -72094,10 +72107,10 @@ var PI = class extends o_ {
|
|
|
72094
72107
|
this.mobject._markDirty();
|
|
72095
72108
|
}
|
|
72096
72109
|
};
|
|
72097
|
-
function
|
|
72098
|
-
return new
|
|
72110
|
+
function II(e, t) {
|
|
72111
|
+
return new FI(e, t);
|
|
72099
72112
|
}
|
|
72100
|
-
var
|
|
72113
|
+
var LI = class extends o_ {
|
|
72101
72114
|
focalPoint;
|
|
72102
72115
|
nMobs;
|
|
72103
72116
|
initialOpacity;
|
|
@@ -72156,12 +72169,12 @@ var II = class extends o_ {
|
|
|
72156
72169
|
this._copies = [], this._parentObject = null, super.finish();
|
|
72157
72170
|
}
|
|
72158
72171
|
};
|
|
72159
|
-
function
|
|
72160
|
-
return new
|
|
72172
|
+
function RI(e, t) {
|
|
72173
|
+
return new LI(e, t);
|
|
72161
72174
|
}
|
|
72162
72175
|
//#endregion
|
|
72163
72176
|
//#region src/animation/indication/Indicate.ts
|
|
72164
|
-
var
|
|
72177
|
+
var zI = class extends o_ {
|
|
72165
72178
|
scaleFactor;
|
|
72166
72179
|
indicateColor;
|
|
72167
72180
|
_originalScale = new L();
|
|
@@ -72185,12 +72198,12 @@ var RI = class extends o_ {
|
|
|
72185
72198
|
this.mobject.scaleVector.copy(this._originalScale), this.mobject.setColor(this._originalColor), this.mobject._markDirty(), super.finish();
|
|
72186
72199
|
}
|
|
72187
72200
|
};
|
|
72188
|
-
function
|
|
72189
|
-
return new
|
|
72201
|
+
function BI(e, t) {
|
|
72202
|
+
return new zI(e, t);
|
|
72190
72203
|
}
|
|
72191
72204
|
//#endregion
|
|
72192
72205
|
//#region src/animation/indication/Flash.ts
|
|
72193
|
-
var
|
|
72206
|
+
var VI = class extends o_ {
|
|
72194
72207
|
flashColor;
|
|
72195
72208
|
numLines;
|
|
72196
72209
|
flashRadius;
|
|
@@ -72263,12 +72276,12 @@ var BI = class extends o_ {
|
|
|
72263
72276
|
}), this._flashGroup = null), super.finish();
|
|
72264
72277
|
}
|
|
72265
72278
|
};
|
|
72266
|
-
function
|
|
72267
|
-
return new
|
|
72279
|
+
function HI(e, t) {
|
|
72280
|
+
return new VI(e, t);
|
|
72268
72281
|
}
|
|
72269
72282
|
//#endregion
|
|
72270
72283
|
//#region src/animation/indication/Circumscribe.ts
|
|
72271
|
-
var
|
|
72284
|
+
var UI = class extends o_ {
|
|
72272
72285
|
shapeType;
|
|
72273
72286
|
shapeColor;
|
|
72274
72287
|
buff;
|
|
@@ -72358,12 +72371,12 @@ var HI = class extends o_ {
|
|
|
72358
72371
|
}), this._shapeGroup = null), super.finish();
|
|
72359
72372
|
}
|
|
72360
72373
|
};
|
|
72361
|
-
function
|
|
72362
|
-
return new
|
|
72374
|
+
function WI(e, t) {
|
|
72375
|
+
return new UI(e, t);
|
|
72363
72376
|
}
|
|
72364
72377
|
//#endregion
|
|
72365
72378
|
//#region src/animation/indication/Wiggle.ts
|
|
72366
|
-
var
|
|
72379
|
+
var GI = class extends o_ {
|
|
72367
72380
|
rotationAngle;
|
|
72368
72381
|
nWiggles;
|
|
72369
72382
|
scaleFactor;
|
|
@@ -72407,12 +72420,12 @@ var WI = class extends o_ {
|
|
|
72407
72420
|
this.mobject.rotation.setFromQuaternion(this._initialQuaternion), this.mobject.scaleVector.copy(this._initialScale), this.mobject.position.copy(this._initialPosition), this.mobject._markDirty(), super.finish();
|
|
72408
72421
|
}
|
|
72409
72422
|
};
|
|
72410
|
-
function
|
|
72411
|
-
return new
|
|
72423
|
+
function KI(e, t) {
|
|
72424
|
+
return new GI(e, t);
|
|
72412
72425
|
}
|
|
72413
72426
|
//#endregion
|
|
72414
72427
|
//#region src/animation/indication/ShowPassingFlash.ts
|
|
72415
|
-
var
|
|
72428
|
+
var qI = class extends o_ {
|
|
72416
72429
|
flashColor;
|
|
72417
72430
|
timeWidth;
|
|
72418
72431
|
flashStrokeWidth;
|
|
@@ -72513,12 +72526,12 @@ var KI = class extends o_ {
|
|
|
72513
72526
|
}), this._flashGroup = null), super.finish();
|
|
72514
72527
|
}
|
|
72515
72528
|
};
|
|
72516
|
-
function
|
|
72517
|
-
return new
|
|
72529
|
+
function JI(e, t) {
|
|
72530
|
+
return new qI(e, t);
|
|
72518
72531
|
}
|
|
72519
72532
|
//#endregion
|
|
72520
72533
|
//#region src/animation/indication/ApplyWave.ts
|
|
72521
|
-
var
|
|
72534
|
+
var YI = class extends o_ {
|
|
72522
72535
|
direction;
|
|
72523
72536
|
amplitude;
|
|
72524
72537
|
wavelength;
|
|
@@ -72604,12 +72617,12 @@ var JI = class extends o_ {
|
|
|
72604
72617
|
this._isVMobject && this.mobject.setPoints(this._originalPoints), this.mobject.position.copy(this._originalPosition), this.mobject._markDirty(), super.finish();
|
|
72605
72618
|
}
|
|
72606
72619
|
};
|
|
72607
|
-
function
|
|
72608
|
-
return new
|
|
72620
|
+
function XI(e, t) {
|
|
72621
|
+
return new YI(e, t);
|
|
72609
72622
|
}
|
|
72610
72623
|
//#endregion
|
|
72611
72624
|
//#region src/animation/indication/FocusOn.ts
|
|
72612
|
-
var
|
|
72625
|
+
var ZI = class extends o_ {
|
|
72613
72626
|
focusColor;
|
|
72614
72627
|
startRadius;
|
|
72615
72628
|
endRadius;
|
|
@@ -72681,10 +72694,10 @@ var XI = class extends o_ {
|
|
|
72681
72694
|
}), this._ringsGroup = null), super.finish();
|
|
72682
72695
|
}
|
|
72683
72696
|
};
|
|
72684
|
-
function
|
|
72685
|
-
return new
|
|
72697
|
+
function QI(e, t) {
|
|
72698
|
+
return new ZI(e, t);
|
|
72686
72699
|
}
|
|
72687
|
-
var
|
|
72700
|
+
var $I = class extends o_ {
|
|
72688
72701
|
scaleFactor;
|
|
72689
72702
|
nPulses;
|
|
72690
72703
|
_originalScale = new L();
|
|
@@ -72705,12 +72718,12 @@ var QI = class extends o_ {
|
|
|
72705
72718
|
this.mobject.scaleVector.copy(this._originalScale), this.mobject._markDirty(), super.finish();
|
|
72706
72719
|
}
|
|
72707
72720
|
};
|
|
72708
|
-
function
|
|
72709
|
-
return new
|
|
72721
|
+
function eL(e, t) {
|
|
72722
|
+
return new $I(e, t);
|
|
72710
72723
|
}
|
|
72711
72724
|
//#endregion
|
|
72712
72725
|
//#region src/animation/indication/ShowPassingFlashWithThinningStrokeWidth.ts
|
|
72713
|
-
var
|
|
72726
|
+
var tL = class extends qI {
|
|
72714
72727
|
minStrokeWidthRatio;
|
|
72715
72728
|
constructor(e, t = {}) {
|
|
72716
72729
|
super(e, t), this.minStrokeWidthRatio = t.minStrokeWidthRatio ?? .1;
|
|
@@ -72751,12 +72764,12 @@ var eL = class extends KI {
|
|
|
72751
72764
|
}
|
|
72752
72765
|
}
|
|
72753
72766
|
};
|
|
72754
|
-
function
|
|
72755
|
-
return new
|
|
72767
|
+
function nL(e, t) {
|
|
72768
|
+
return new tL(e, t);
|
|
72756
72769
|
}
|
|
72757
72770
|
//#endregion
|
|
72758
72771
|
//#region src/animation/indication/Blink.ts
|
|
72759
|
-
var
|
|
72772
|
+
var rL = class extends o_ {
|
|
72760
72773
|
nBlinks;
|
|
72761
72774
|
minOpacity;
|
|
72762
72775
|
blinkDuration;
|
|
@@ -72797,12 +72810,12 @@ var nL = class extends o_ {
|
|
|
72797
72810
|
this.mobject._markDirty(), super.finish();
|
|
72798
72811
|
}
|
|
72799
72812
|
};
|
|
72800
|
-
function
|
|
72801
|
-
return new
|
|
72813
|
+
function iL(e, t) {
|
|
72814
|
+
return new rL(e, t);
|
|
72802
72815
|
}
|
|
72803
72816
|
//#endregion
|
|
72804
72817
|
//#region src/animation/indication/ShowCreationThenDestruction.ts
|
|
72805
|
-
var
|
|
72818
|
+
var aL = class extends o_ {
|
|
72806
72819
|
_totalLength = 0;
|
|
72807
72820
|
_useDashReveal = !1;
|
|
72808
72821
|
constructor(e, t = {}) {
|
|
@@ -72837,19 +72850,19 @@ var iL = class extends o_ {
|
|
|
72837
72850
|
}) : this.mobject.setStrokeOpacity(0), super.finish();
|
|
72838
72851
|
}
|
|
72839
72852
|
};
|
|
72840
|
-
function
|
|
72841
|
-
return new
|
|
72853
|
+
function oL(e, t) {
|
|
72854
|
+
return new aL(e, t);
|
|
72842
72855
|
}
|
|
72843
72856
|
//#endregion
|
|
72844
72857
|
//#region src/animation/indication/WiggleOutThenIn.ts
|
|
72845
|
-
var
|
|
72846
|
-
function
|
|
72858
|
+
var sL = 2 * Math.PI;
|
|
72859
|
+
function cL(e) {
|
|
72847
72860
|
return of(e < .5 ? 2 * e : 2 * (1 - e));
|
|
72848
72861
|
}
|
|
72849
|
-
function
|
|
72850
|
-
return Math.sin(t *
|
|
72862
|
+
function lL(e, t) {
|
|
72863
|
+
return Math.sin(t * sL * e) * cL(e);
|
|
72851
72864
|
}
|
|
72852
|
-
var
|
|
72865
|
+
var uL = class extends o_ {
|
|
72853
72866
|
scaleValue;
|
|
72854
72867
|
rotationAngle;
|
|
72855
72868
|
nWiggles;
|
|
@@ -72863,7 +72876,7 @@ var lL = class extends o_ {
|
|
|
72863
72876
|
super(e, {
|
|
72864
72877
|
duration: t.duration ?? 2,
|
|
72865
72878
|
rateFunc: t.rateFunc ?? rg
|
|
72866
|
-
}), this.scaleValue = t.scaleValue ?? 1.1, this.rotationAngle = t.rotationAngle ?? .01 *
|
|
72879
|
+
}), this.scaleValue = t.scaleValue ?? 1.1, this.rotationAngle = t.rotationAngle ?? .01 * sL, this.nWiggles = t.nWiggles ?? 6, this.rotationAxis = t.rotationAxis ?? [
|
|
72867
72880
|
0,
|
|
72868
72881
|
0,
|
|
72869
72882
|
1
|
|
@@ -72875,9 +72888,9 @@ var lL = class extends o_ {
|
|
|
72875
72888
|
this._aboutPoint.set(e[0], e[1], e[2]);
|
|
72876
72889
|
}
|
|
72877
72890
|
interpolate(e) {
|
|
72878
|
-
let t =
|
|
72891
|
+
let t = cL(e), n = nf(1, this.scaleValue, t);
|
|
72879
72892
|
this.mobject.scaleVector.set(this._initialScale.x * n, this._initialScale.y * n, this._initialScale.z * n);
|
|
72880
|
-
let r =
|
|
72893
|
+
let r = lL(e, this.nWiggles) * this.rotationAngle, i = new Jt().setFromAxisAngle(this._axisVector, r), a = new Jt().copy(this._initialQuaternion);
|
|
72881
72894
|
a.premultiply(i), this.mobject.rotation.setFromQuaternion(a);
|
|
72882
72895
|
let o = new L().copy(this._initialPosition).sub(this._aboutPoint);
|
|
72883
72896
|
o.applyQuaternion(i);
|
|
@@ -72888,12 +72901,12 @@ var lL = class extends o_ {
|
|
|
72888
72901
|
this.mobject.rotation.setFromQuaternion(this._initialQuaternion), this.mobject.scaleVector.copy(this._initialScale), this.mobject.position.copy(this._initialPosition), this.mobject._markDirty(), super.finish();
|
|
72889
72902
|
}
|
|
72890
72903
|
};
|
|
72891
|
-
function
|
|
72892
|
-
return new
|
|
72904
|
+
function dL(e, t) {
|
|
72905
|
+
return new uL(e, t);
|
|
72893
72906
|
}
|
|
72894
72907
|
//#endregion
|
|
72895
72908
|
//#region src/interaction/Controls.ts
|
|
72896
|
-
var
|
|
72909
|
+
var fL = class {
|
|
72897
72910
|
_scene;
|
|
72898
72911
|
_panel;
|
|
72899
72912
|
_options;
|
|
@@ -73141,7 +73154,7 @@ var dL = class {
|
|
|
73141
73154
|
dispose() {
|
|
73142
73155
|
this._panel.remove();
|
|
73143
73156
|
}
|
|
73144
|
-
},
|
|
73157
|
+
}, pL = class extends fL {
|
|
73145
73158
|
_timeline = null;
|
|
73146
73159
|
_playPauseBtn = null;
|
|
73147
73160
|
_speedSelect = null;
|
|
@@ -73351,7 +73364,7 @@ var dL = class {
|
|
|
73351
73364
|
dispose() {
|
|
73352
73365
|
this._updateInterval !== null && (cancelAnimationFrame(this._updateInterval), this._updateInterval = null), super.dispose();
|
|
73353
73366
|
}
|
|
73354
|
-
},
|
|
73367
|
+
}, mL = class {
|
|
73355
73368
|
_mobject;
|
|
73356
73369
|
_scene;
|
|
73357
73370
|
_options;
|
|
@@ -73484,12 +73497,12 @@ var dL = class {
|
|
|
73484
73497
|
e.removeEventListener("mousedown", this._onMouseDown), window.removeEventListener("mousemove", this._onMouseMove), window.removeEventListener("mouseup", this._onMouseUp), e.removeEventListener("touchstart", this._onTouchStart), window.removeEventListener("touchmove", this._onTouchMove), window.removeEventListener("touchend", this._onTouchEnd);
|
|
73485
73498
|
}
|
|
73486
73499
|
};
|
|
73487
|
-
function
|
|
73488
|
-
return new
|
|
73500
|
+
function hL(e, t, n) {
|
|
73501
|
+
return new mL(e, t, n);
|
|
73489
73502
|
}
|
|
73490
73503
|
//#endregion
|
|
73491
73504
|
//#region src/interaction/Hoverable.ts
|
|
73492
|
-
var
|
|
73505
|
+
var gL = class {
|
|
73493
73506
|
_mobject;
|
|
73494
73507
|
_scene;
|
|
73495
73508
|
_options;
|
|
@@ -73572,12 +73585,12 @@ var hL = class {
|
|
|
73572
73585
|
e.removeEventListener("mousemove", this._onMouseMove), e.removeEventListener("mouseleave", this._onMouseLeave), this._isHovering && this._endHover();
|
|
73573
73586
|
}
|
|
73574
73587
|
};
|
|
73575
|
-
function
|
|
73576
|
-
return new
|
|
73588
|
+
function _L(e, t, n) {
|
|
73589
|
+
return new gL(e, t, n);
|
|
73577
73590
|
}
|
|
73578
73591
|
//#endregion
|
|
73579
73592
|
//#region src/interaction/Clickable.ts
|
|
73580
|
-
var
|
|
73593
|
+
var vL = class {
|
|
73581
73594
|
_mobject;
|
|
73582
73595
|
_scene;
|
|
73583
73596
|
_options;
|
|
@@ -73673,12 +73686,12 @@ var _L = class {
|
|
|
73673
73686
|
e.removeEventListener("click", this._onClick), e.removeEventListener("dblclick", this._onDblClick), e.removeEventListener("touchstart", this._onTouchStart), e.removeEventListener("touchend", this._onTouchEnd);
|
|
73674
73687
|
}
|
|
73675
73688
|
};
|
|
73676
|
-
function
|
|
73677
|
-
return new
|
|
73689
|
+
function yL(e, t, n) {
|
|
73690
|
+
return new vL(e, t, n);
|
|
73678
73691
|
}
|
|
73679
73692
|
//#endregion
|
|
73680
73693
|
//#region src/interaction/MovablePoint.ts
|
|
73681
|
-
var
|
|
73694
|
+
var bL = class extends UD {
|
|
73682
73695
|
_draggable;
|
|
73683
73696
|
_onChange;
|
|
73684
73697
|
_xTracker;
|
|
@@ -73695,7 +73708,7 @@ var yL = class extends UD {
|
|
|
73695
73708
|
point: n,
|
|
73696
73709
|
color: r,
|
|
73697
73710
|
radius: i
|
|
73698
|
-
}), this._onChange = a, this._xTracker = o, this._yTracker = s, this._draggable = new
|
|
73711
|
+
}), this._onChange = a, this._xTracker = o, this._yTracker = s, this._draggable = new mL(this, e, {
|
|
73699
73712
|
autoRender: c,
|
|
73700
73713
|
onDrag: (e, t) => this._commit(t, !0)
|
|
73701
73714
|
}), this._syncTrackers(this.getPoint());
|
|
@@ -73713,7 +73726,7 @@ var yL = class extends UD {
|
|
|
73713
73726
|
constrainToParametric(e, t) {
|
|
73714
73727
|
let n = t[0], r = t[1], i = t.length > 2 ? Math.max(2, Math.floor(t[2])) : 256;
|
|
73715
73728
|
return this._constraint = ([t, a, o]) => {
|
|
73716
|
-
let s =
|
|
73729
|
+
let s = SL(e, n, r, i, t, a);
|
|
73717
73730
|
this._parameter = s;
|
|
73718
73731
|
let [c, l] = e(s);
|
|
73719
73732
|
return [
|
|
@@ -73724,10 +73737,10 @@ var yL = class extends UD {
|
|
|
73724
73737
|
}, this._reproject(), this;
|
|
73725
73738
|
}
|
|
73726
73739
|
constrainToLine(e, t) {
|
|
73727
|
-
return this._constraint = (n) =>
|
|
73740
|
+
return this._constraint = (n) => xL(e, t, n, !1), this._reproject(), this;
|
|
73728
73741
|
}
|
|
73729
73742
|
constrainToSegment(e, t) {
|
|
73730
|
-
return this._constraint = (n) =>
|
|
73743
|
+
return this._constraint = (n) => xL(e, t, n, !0), this._reproject(), this;
|
|
73731
73744
|
}
|
|
73732
73745
|
clearConstraint() {
|
|
73733
73746
|
return this._constraint = null, this._parameter = null, this;
|
|
@@ -73752,7 +73765,7 @@ var yL = class extends UD {
|
|
|
73752
73765
|
this._xTracker?.setValue(e[0]), this._yTracker?.setValue(e[1]);
|
|
73753
73766
|
}
|
|
73754
73767
|
};
|
|
73755
|
-
function
|
|
73768
|
+
function xL(e, t, n, r) {
|
|
73756
73769
|
let i = t[0] - e[0], a = t[1] - e[1], o = i * i + a * a, s = o === 0 ? 0 : ((n[0] - e[0]) * i + (n[1] - e[1]) * a) / o;
|
|
73757
73770
|
return r && (s = Math.max(0, Math.min(1, s))), [
|
|
73758
73771
|
e[0] + s * i,
|
|
@@ -73760,7 +73773,7 @@ function bL(e, t, n, r) {
|
|
|
73760
73773
|
n[2]
|
|
73761
73774
|
];
|
|
73762
73775
|
}
|
|
73763
|
-
function
|
|
73776
|
+
function SL(e, t, n, r, i, a) {
|
|
73764
73777
|
let o = (t) => {
|
|
73765
73778
|
let [n, r] = e(t), o = n - i, s = r - a;
|
|
73766
73779
|
return o * o + s * s;
|
|
@@ -73776,12 +73789,12 @@ function xL(e, t, n, r, i, a) {
|
|
|
73776
73789
|
}
|
|
73777
73790
|
return (u + d) / 2;
|
|
73778
73791
|
}
|
|
73779
|
-
function
|
|
73780
|
-
return new
|
|
73792
|
+
function CL(e, t) {
|
|
73793
|
+
return new bL(e, t);
|
|
73781
73794
|
}
|
|
73782
73795
|
//#endregion
|
|
73783
73796
|
//#region src/interaction/Slider.ts
|
|
73784
|
-
var
|
|
73797
|
+
var wL = 28, TL = .35, EL = class extends jT {
|
|
73785
73798
|
_min;
|
|
73786
73799
|
_max;
|
|
73787
73800
|
_step;
|
|
@@ -73797,7 +73810,7 @@ var CL = 28, wL = .35, TL = class extends jT {
|
|
|
73797
73810
|
_draggable;
|
|
73798
73811
|
constructor(e, t = {}) {
|
|
73799
73812
|
super();
|
|
73800
|
-
let n =
|
|
73813
|
+
let n = DL(t), { center: r, color: i } = n;
|
|
73801
73814
|
this._min = n.min, this._max = n.max, this._step = n.step, this._length = n.length, this._center = [...r], this._trackY = r[1], this._tracker = n.tracker ?? new Qk(n.value), this._onChange = n.onChange, this._value = this._clampAndStep(n.value);
|
|
73802
73815
|
let a = r[0] - n.length / 2;
|
|
73803
73816
|
this._track = new UE({
|
|
@@ -73820,7 +73833,7 @@ var CL = 28, wL = .35, TL = class extends jT {
|
|
|
73820
73833
|
],
|
|
73821
73834
|
color: i,
|
|
73822
73835
|
radius: n.handleRadius
|
|
73823
|
-
}), this.add(this._track), this.add(this._handle), n.showLabel && this._createLabel(n.numDecimalPlaces, i), this._tracker.setValue(this._value), this._draggable = new
|
|
73836
|
+
}), this.add(this._track), this.add(this._handle), n.showLabel && this._createLabel(n.numDecimalPlaces, i), this._tracker.setValue(this._value), this._draggable = new mL(this._handle, e, {
|
|
73824
73837
|
autoRender: n.autoRender,
|
|
73825
73838
|
onDrag: (e, t) => this.setValue(this._xToValue(t[0]))
|
|
73826
73839
|
});
|
|
@@ -73858,7 +73871,7 @@ var CL = 28, wL = .35, TL = class extends jT {
|
|
|
73858
73871
|
this._label = new Yk({
|
|
73859
73872
|
value: this._value,
|
|
73860
73873
|
numDecimalPlaces: e,
|
|
73861
|
-
fontSize:
|
|
73874
|
+
fontSize: wL,
|
|
73862
73875
|
color: t
|
|
73863
73876
|
}), this.add(this._label), this._positionLabel();
|
|
73864
73877
|
}
|
|
@@ -73867,7 +73880,7 @@ var CL = 28, wL = .35, TL = class extends jT {
|
|
|
73867
73880
|
let e = this._valueToX(this._value);
|
|
73868
73881
|
this._label.moveTo([
|
|
73869
73882
|
e,
|
|
73870
|
-
this._trackY +
|
|
73883
|
+
this._trackY + TL,
|
|
73871
73884
|
this._center[2]
|
|
73872
73885
|
]);
|
|
73873
73886
|
}
|
|
@@ -73884,7 +73897,7 @@ var CL = 28, wL = .35, TL = class extends jT {
|
|
|
73884
73897
|
return this._step > 0 && (t = this._min + Math.round((e - this._min) / this._step) * this._step), Math.max(this._min, Math.min(this._max, t));
|
|
73885
73898
|
}
|
|
73886
73899
|
};
|
|
73887
|
-
function
|
|
73900
|
+
function DL(e) {
|
|
73888
73901
|
let t = e.min ?? 0;
|
|
73889
73902
|
return {
|
|
73890
73903
|
min: t,
|
|
@@ -73907,12 +73920,107 @@ function EL(e) {
|
|
|
73907
73920
|
autoRender: e.autoRender
|
|
73908
73921
|
};
|
|
73909
73922
|
}
|
|
73910
|
-
function
|
|
73911
|
-
return new
|
|
73923
|
+
function OL(e, t) {
|
|
73924
|
+
return new EL(e, t);
|
|
73925
|
+
}
|
|
73926
|
+
//#endregion
|
|
73927
|
+
//#region src/interaction/DynamicMatrix.ts
|
|
73928
|
+
function kL() {
|
|
73929
|
+
return [[1, 0], [0, 1]];
|
|
73930
|
+
}
|
|
73931
|
+
function AL(e) {
|
|
73932
|
+
return [[e[0][0], e[0][1]], [e[1][0], e[1][1]]];
|
|
73933
|
+
}
|
|
73934
|
+
function jL(e) {
|
|
73935
|
+
if (typeof e == "function") {
|
|
73936
|
+
let t = e();
|
|
73937
|
+
return [t[0], t[1]];
|
|
73938
|
+
}
|
|
73939
|
+
let t = e.getPoint();
|
|
73940
|
+
return [t[0], t[1]];
|
|
73941
|
+
}
|
|
73942
|
+
var ML = class e {
|
|
73943
|
+
_matrix;
|
|
73944
|
+
_compute;
|
|
73945
|
+
constructor(e = kL()) {
|
|
73946
|
+
this._matrix = AL(e), this._compute = null;
|
|
73947
|
+
}
|
|
73948
|
+
getMatrix() {
|
|
73949
|
+
return AL(this._compute ? this._compute() : this._matrix);
|
|
73950
|
+
}
|
|
73951
|
+
setMatrix(e) {
|
|
73952
|
+
return this._compute = null, this._matrix = AL(e), this;
|
|
73953
|
+
}
|
|
73954
|
+
setColumns(e, t) {
|
|
73955
|
+
return this.setMatrix([[e[0], t[0]], [e[1], t[1]]]);
|
|
73956
|
+
}
|
|
73957
|
+
getColumns() {
|
|
73958
|
+
let e = this.getMatrix();
|
|
73959
|
+
return [[e[0][0], e[1][0]], [e[0][1], e[1][1]]];
|
|
73960
|
+
}
|
|
73961
|
+
transformPoint(e) {
|
|
73962
|
+
let t = this.getMatrix();
|
|
73963
|
+
return [t[0][0] * e[0] + t[0][1] * e[1], t[1][0] * e[0] + t[1][1] * e[1]];
|
|
73964
|
+
}
|
|
73965
|
+
static fromGetter(t) {
|
|
73966
|
+
let n = new e();
|
|
73967
|
+
return n._compute = t, n;
|
|
73968
|
+
}
|
|
73969
|
+
static fromBasisVectors(t, n) {
|
|
73970
|
+
return e.fromGetter(() => {
|
|
73971
|
+
let e = jL(t), r = jL(n);
|
|
73972
|
+
return [[e[0], r[0]], [e[1], r[1]]];
|
|
73973
|
+
});
|
|
73974
|
+
}
|
|
73975
|
+
};
|
|
73976
|
+
function NL(e) {
|
|
73977
|
+
return new ML(e);
|
|
73978
|
+
}
|
|
73979
|
+
function PL(e) {
|
|
73980
|
+
return e instanceof ML ? e : typeof e == "function" ? ML.fromGetter(e) : new ML(e);
|
|
73981
|
+
}
|
|
73982
|
+
function FL(e, t, n = {}) {
|
|
73983
|
+
let r = PL(t), i = n.aboutPoint ?? [
|
|
73984
|
+
0,
|
|
73985
|
+
0,
|
|
73986
|
+
0
|
|
73987
|
+
], a = n.onChange, o = n.dependents ? [...n.dependents] : [], s = [];
|
|
73988
|
+
for (let t of e.getFamily()) t instanceof V && t.hasOwnPoints() && s.push({
|
|
73989
|
+
node: t,
|
|
73990
|
+
points: t.getLocalPoints()
|
|
73991
|
+
});
|
|
73992
|
+
let c = () => {
|
|
73993
|
+
let e = r.getMatrix();
|
|
73994
|
+
for (let t of s) t.node.setPoints(t.points.map((t) => lf(t, e, i)));
|
|
73995
|
+
for (let t of o) {
|
|
73996
|
+
let n = lf([...t.base], e, i);
|
|
73997
|
+
t.mobject.moveTo([
|
|
73998
|
+
n[0],
|
|
73999
|
+
n[1],
|
|
74000
|
+
n[2]
|
|
74001
|
+
]);
|
|
74002
|
+
}
|
|
74003
|
+
a?.(e);
|
|
74004
|
+
}, l = () => c();
|
|
74005
|
+
e.addUpdater(l), c();
|
|
74006
|
+
let u = {
|
|
74007
|
+
tracker: r,
|
|
74008
|
+
getMatrix: () => r.getMatrix(),
|
|
74009
|
+
setMatrix: (e) => (r.setMatrix(e), c(), u),
|
|
74010
|
+
addDependentPoint: (e, t) => (o.push({
|
|
74011
|
+
mobject: e,
|
|
74012
|
+
base: t
|
|
74013
|
+
}), u),
|
|
74014
|
+
update: () => (c(), u),
|
|
74015
|
+
remove: () => {
|
|
74016
|
+
e.removeUpdater(l);
|
|
74017
|
+
}
|
|
74018
|
+
};
|
|
74019
|
+
return u;
|
|
73912
74020
|
}
|
|
73913
74021
|
//#endregion
|
|
73914
74022
|
//#region node_modules/gif.js/dist/gif.js
|
|
73915
|
-
var
|
|
74023
|
+
var IL = /* @__PURE__ */ r(((e, t) => {
|
|
73916
74024
|
(function(n) {
|
|
73917
74025
|
if (typeof e == "object" && t !== void 0) t.exports = n();
|
|
73918
74026
|
else if (typeof define == "function" && define.amd) define([], n);
|
|
@@ -74166,10 +74274,10 @@ var OL = /* @__PURE__ */ r(((e, t) => {
|
|
|
74166
74274
|
}]
|
|
74167
74275
|
}, {}, [3])(3);
|
|
74168
74276
|
});
|
|
74169
|
-
})),
|
|
74170
|
-
GifExporter: () =>
|
|
74171
|
-
createGifExporter: () =>
|
|
74172
|
-
}),
|
|
74277
|
+
})), LL = /* @__PURE__ */ t({
|
|
74278
|
+
GifExporter: () => zL,
|
|
74279
|
+
createGifExporter: () => BL
|
|
74280
|
+
}), RL = /* @__PURE__ */ e(IL(), 1), zL = class e {
|
|
74173
74281
|
_scene;
|
|
74174
74282
|
_options;
|
|
74175
74283
|
constructor(e, t) {
|
|
@@ -74187,7 +74295,7 @@ var OL = /* @__PURE__ */ r(((e, t) => {
|
|
|
74187
74295
|
};
|
|
74188
74296
|
}
|
|
74189
74297
|
async exportTimeline(e) {
|
|
74190
|
-
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
|
|
74298
|
+
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 RL.default({
|
|
74191
74299
|
workers: this._options.workers,
|
|
74192
74300
|
quality: this._options.quality,
|
|
74193
74301
|
width: this._options.width,
|
|
@@ -74246,15 +74354,15 @@ var OL = /* @__PURE__ */ r(((e, t) => {
|
|
|
74246
74354
|
e.download(r, t);
|
|
74247
74355
|
}
|
|
74248
74356
|
};
|
|
74249
|
-
function
|
|
74250
|
-
return new
|
|
74357
|
+
function BL(e, t) {
|
|
74358
|
+
return new zL(e, t);
|
|
74251
74359
|
}
|
|
74252
74360
|
//#endregion
|
|
74253
74361
|
//#region src/export/VideoExporter.ts
|
|
74254
|
-
var
|
|
74255
|
-
VideoExporter: () =>
|
|
74256
|
-
createVideoExporter: () =>
|
|
74257
|
-
}),
|
|
74362
|
+
var VL = /* @__PURE__ */ t({
|
|
74363
|
+
VideoExporter: () => HL,
|
|
74364
|
+
createVideoExporter: () => UL
|
|
74365
|
+
}), HL = class e {
|
|
74258
74366
|
_scene;
|
|
74259
74367
|
_options;
|
|
74260
74368
|
_mediaRecorder = null;
|
|
@@ -74346,12 +74454,12 @@ var NL = /* @__PURE__ */ t({
|
|
|
74346
74454
|
return { ...this._options };
|
|
74347
74455
|
}
|
|
74348
74456
|
};
|
|
74349
|
-
function
|
|
74350
|
-
return new
|
|
74457
|
+
function UL(e, t) {
|
|
74458
|
+
return new HL(e, t);
|
|
74351
74459
|
}
|
|
74352
74460
|
//#endregion
|
|
74353
74461
|
//#region src/export/FrameExporter.ts
|
|
74354
|
-
function
|
|
74462
|
+
function WL(e, t, n) {
|
|
74355
74463
|
return new Promise((r, i) => {
|
|
74356
74464
|
if (typeof e.toBlob == "function") {
|
|
74357
74465
|
e.toBlob((e) => {
|
|
@@ -74360,40 +74468,40 @@ function IL(e, t, n) {
|
|
|
74360
74468
|
return;
|
|
74361
74469
|
}
|
|
74362
74470
|
try {
|
|
74363
|
-
r(
|
|
74471
|
+
r(GL(e.toDataURL(t, n)));
|
|
74364
74472
|
} catch (e) {
|
|
74365
74473
|
i(e instanceof Error ? e : Error(String(e)));
|
|
74366
74474
|
}
|
|
74367
74475
|
});
|
|
74368
74476
|
}
|
|
74369
|
-
function
|
|
74477
|
+
function GL(e) {
|
|
74370
74478
|
let [t, n] = e.split(","), r = t.match(/data:([^;]+)/), i = r ? r[1] : "image/png", a = atob(n), o = new Uint8Array(a.length);
|
|
74371
74479
|
for (let e = 0; e < a.length; e++) o[e] = a.charCodeAt(e);
|
|
74372
74480
|
return new Blob([o], { type: i });
|
|
74373
74481
|
}
|
|
74374
|
-
async function
|
|
74375
|
-
return t?.time !== void 0 && e.seek(t.time),
|
|
74482
|
+
async function KL(e, t) {
|
|
74483
|
+
return t?.time !== void 0 && e.seek(t.time), WL(e.getCanvas(), t?.type ?? "image/png", t?.quality);
|
|
74376
74484
|
}
|
|
74377
|
-
async function
|
|
74485
|
+
async function qL(e, t) {
|
|
74378
74486
|
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 = [];
|
|
74379
74487
|
for (let n = 0; n < c; n++) {
|
|
74380
74488
|
let i = r + n * l;
|
|
74381
74489
|
e.seek(i);
|
|
74382
74490
|
let s = e.getCanvas();
|
|
74383
|
-
u.push(await
|
|
74491
|
+
u.push(await WL(s, a, t.quality)), o((n + 1) / c);
|
|
74384
74492
|
}
|
|
74385
74493
|
return u;
|
|
74386
74494
|
}
|
|
74387
|
-
function
|
|
74495
|
+
function JL(e, t) {
|
|
74388
74496
|
let n = URL.createObjectURL(e), r = document.createElement("a");
|
|
74389
74497
|
r.href = n, r.download = t, document.body.appendChild(r), r.click(), document.body.removeChild(r), URL.revokeObjectURL(n);
|
|
74390
74498
|
}
|
|
74391
|
-
async function
|
|
74392
|
-
|
|
74499
|
+
async function YL(e, t = "frame.png", n) {
|
|
74500
|
+
JL(await KL(e, n), t);
|
|
74393
74501
|
}
|
|
74394
74502
|
//#endregion
|
|
74395
74503
|
//#region src/export/WebCodecsExporter.ts
|
|
74396
|
-
var
|
|
74504
|
+
var XL = {
|
|
74397
74505
|
avc: {
|
|
74398
74506
|
encoderCodec: "avc1.42001f",
|
|
74399
74507
|
mp4Codec: "avc",
|
|
@@ -74414,7 +74522,7 @@ var HL = {
|
|
|
74414
74522
|
mp4Codec: "av1",
|
|
74415
74523
|
webmCodec: "V_AV1"
|
|
74416
74524
|
}
|
|
74417
|
-
},
|
|
74525
|
+
}, ZL = class e {
|
|
74418
74526
|
_scene;
|
|
74419
74527
|
_options;
|
|
74420
74528
|
constructor(e, t) {
|
|
@@ -74437,7 +74545,7 @@ var HL = {
|
|
|
74437
74545
|
}
|
|
74438
74546
|
async export() {
|
|
74439
74547
|
if (!e.isSupported()) throw Error("WebCodecs VideoEncoder is not available in this environment. Use VideoExporter (MediaRecorder) instead to export video.");
|
|
74440
|
-
let t = this._options, n = t.duration || this._scene.getTimelineDuration() || 5, r = Math.ceil(n * t.fps), i =
|
|
74548
|
+
let t = this._options, n = t.duration || this._scene.getTimelineDuration() || 5, r = Math.ceil(n * t.fps), i = XL[t.codec], a = await this._createMuxer(i), o = new window.VideoEncoder({
|
|
74441
74549
|
output: (e, t) => a.addVideoChunk(e, t),
|
|
74442
74550
|
error: (e) => Gf.error("WebCodecs encoder error:", e)
|
|
74443
74551
|
}), s = {
|
|
@@ -74498,12 +74606,156 @@ var HL = {
|
|
|
74498
74606
|
return { ...this._options };
|
|
74499
74607
|
}
|
|
74500
74608
|
};
|
|
74501
|
-
function
|
|
74502
|
-
return new
|
|
74609
|
+
function QL(e, t) {
|
|
74610
|
+
return new ZL(e, t);
|
|
74611
|
+
}
|
|
74612
|
+
//#endregion
|
|
74613
|
+
//#region src/export/chooseExporter.ts
|
|
74614
|
+
function $L(e = ZL.isSupported()) {
|
|
74615
|
+
return e ? "webcodecs" : "mediarecorder";
|
|
74503
74616
|
}
|
|
74504
74617
|
//#endregion
|
|
74505
|
-
//#region src/player/
|
|
74506
|
-
var
|
|
74618
|
+
//#region src/player/ExportSettingsUI.ts
|
|
74619
|
+
var eR = [
|
|
74620
|
+
{
|
|
74621
|
+
id: "current",
|
|
74622
|
+
label: "Current",
|
|
74623
|
+
width: null,
|
|
74624
|
+
height: null
|
|
74625
|
+
},
|
|
74626
|
+
{
|
|
74627
|
+
id: "480p",
|
|
74628
|
+
label: "480p",
|
|
74629
|
+
width: 854,
|
|
74630
|
+
height: 480
|
|
74631
|
+
},
|
|
74632
|
+
{
|
|
74633
|
+
id: "720p",
|
|
74634
|
+
label: "720p",
|
|
74635
|
+
width: 1280,
|
|
74636
|
+
height: 720
|
|
74637
|
+
},
|
|
74638
|
+
{
|
|
74639
|
+
id: "1080p",
|
|
74640
|
+
label: "1080p",
|
|
74641
|
+
width: 1920,
|
|
74642
|
+
height: 1080
|
|
74643
|
+
},
|
|
74644
|
+
{
|
|
74645
|
+
id: "1440p",
|
|
74646
|
+
label: "1440p",
|
|
74647
|
+
width: 2560,
|
|
74648
|
+
height: 1440
|
|
74649
|
+
},
|
|
74650
|
+
{
|
|
74651
|
+
id: "4k",
|
|
74652
|
+
label: "4K",
|
|
74653
|
+
width: 3840,
|
|
74654
|
+
height: 2160
|
|
74655
|
+
}
|
|
74656
|
+
], tR = [
|
|
74657
|
+
24,
|
|
74658
|
+
30,
|
|
74659
|
+
60
|
|
74660
|
+
], nR = [
|
|
74661
|
+
{
|
|
74662
|
+
id: "low",
|
|
74663
|
+
label: "Low",
|
|
74664
|
+
value: .5
|
|
74665
|
+
},
|
|
74666
|
+
{
|
|
74667
|
+
id: "medium",
|
|
74668
|
+
label: "Medium",
|
|
74669
|
+
value: .75
|
|
74670
|
+
},
|
|
74671
|
+
{
|
|
74672
|
+
id: "high",
|
|
74673
|
+
label: "High",
|
|
74674
|
+
value: .9
|
|
74675
|
+
}
|
|
74676
|
+
], rR = 1e7;
|
|
74677
|
+
function iR(e) {
|
|
74678
|
+
return Math.round(Math.max(0, Math.min(1, e)) * rR);
|
|
74679
|
+
}
|
|
74680
|
+
function aR(e, t, n) {
|
|
74681
|
+
let r = eR.find((t) => t.id === e);
|
|
74682
|
+
return !r || r.width === null || r.height === null ? {
|
|
74683
|
+
width: t,
|
|
74684
|
+
height: n
|
|
74685
|
+
} : {
|
|
74686
|
+
width: r.width,
|
|
74687
|
+
height: r.height
|
|
74688
|
+
};
|
|
74689
|
+
}
|
|
74690
|
+
var oR = class {
|
|
74691
|
+
_element;
|
|
74692
|
+
_fpsSelect;
|
|
74693
|
+
_resolutionSelect;
|
|
74694
|
+
_qualitySelect;
|
|
74695
|
+
_defaults;
|
|
74696
|
+
constructor(e) {
|
|
74697
|
+
this._defaults = e, this._element = document.createElement("div"), Object.assign(this._element.style, {
|
|
74698
|
+
padding: "8px 14px",
|
|
74699
|
+
borderBottom: "1px solid rgba(255,255,255,0.12)",
|
|
74700
|
+
display: "flex",
|
|
74701
|
+
flexDirection: "column",
|
|
74702
|
+
gap: "6px"
|
|
74703
|
+
}), this._element.setAttribute("data-export-settings", ""), this._fpsSelect = this._buildSelect("FPS", tR.map((e) => ({
|
|
74704
|
+
value: String(e),
|
|
74705
|
+
label: `${e} fps`
|
|
74706
|
+
})), String(this._nearestFps(e.fps))), this._resolutionSelect = this._buildSelect("Resolution", eR.map((e) => ({
|
|
74707
|
+
value: e.id,
|
|
74708
|
+
label: e.label
|
|
74709
|
+
})), "current"), this._qualitySelect = this._buildSelect("Quality", nR.map((e) => ({
|
|
74710
|
+
value: String(e.value),
|
|
74711
|
+
label: e.label
|
|
74712
|
+
})), String(nR[nR.length - 1].value));
|
|
74713
|
+
}
|
|
74714
|
+
get element() {
|
|
74715
|
+
return this._element;
|
|
74716
|
+
}
|
|
74717
|
+
getSettings() {
|
|
74718
|
+
let e = parseInt(this._fpsSelect.value, 10), { width: t, height: n } = aR(this._resolutionSelect.value, this._defaults.width, this._defaults.height);
|
|
74719
|
+
return {
|
|
74720
|
+
fps: e,
|
|
74721
|
+
width: t,
|
|
74722
|
+
height: n,
|
|
74723
|
+
quality: parseFloat(this._qualitySelect.value)
|
|
74724
|
+
};
|
|
74725
|
+
}
|
|
74726
|
+
_nearestFps(e) {
|
|
74727
|
+
return tR.reduce((t, n) => Math.abs(n - e) < Math.abs(t - e) ? n : t);
|
|
74728
|
+
}
|
|
74729
|
+
_buildSelect(e, t, n) {
|
|
74730
|
+
let r = document.createElement("label");
|
|
74731
|
+
Object.assign(r.style, {
|
|
74732
|
+
display: "flex",
|
|
74733
|
+
justifyContent: "space-between",
|
|
74734
|
+
alignItems: "center",
|
|
74735
|
+
gap: "10px",
|
|
74736
|
+
fontSize: "12px"
|
|
74737
|
+
});
|
|
74738
|
+
let i = document.createElement("span");
|
|
74739
|
+
i.textContent = e, i.style.opacity = "0.7";
|
|
74740
|
+
let a = document.createElement("select");
|
|
74741
|
+
Object.assign(a.style, {
|
|
74742
|
+
background: "rgba(255,255,255,0.1)",
|
|
74743
|
+
color: "#fff",
|
|
74744
|
+
border: "1px solid rgba(255,255,255,0.2)",
|
|
74745
|
+
borderRadius: "4px",
|
|
74746
|
+
padding: "2px 6px",
|
|
74747
|
+
fontSize: "12px",
|
|
74748
|
+
fontFamily: "inherit",
|
|
74749
|
+
cursor: "pointer",
|
|
74750
|
+
outline: "none"
|
|
74751
|
+
});
|
|
74752
|
+
for (let e of t) {
|
|
74753
|
+
let t = document.createElement("option");
|
|
74754
|
+
t.value = e.value, t.textContent = e.label, t.style.background = "#222", t.style.color = "#fff", a.appendChild(t);
|
|
74755
|
+
}
|
|
74756
|
+
return a.value = n, a.addEventListener("click", (e) => e.stopPropagation()), r.appendChild(i), r.appendChild(a), this._element.appendChild(r), a;
|
|
74757
|
+
}
|
|
74758
|
+
}, sR = class {
|
|
74507
74759
|
_container;
|
|
74508
74760
|
_bar;
|
|
74509
74761
|
_playBtn;
|
|
@@ -74523,6 +74775,8 @@ var GL = class {
|
|
|
74523
74775
|
_exportBtnWrapper = null;
|
|
74524
74776
|
_callbacks;
|
|
74525
74777
|
_autoHideMs;
|
|
74778
|
+
_exportControls;
|
|
74779
|
+
_exportPanel = null;
|
|
74526
74780
|
_hideTimeout = null;
|
|
74527
74781
|
_isVisible = !0;
|
|
74528
74782
|
_isDragging = !1;
|
|
@@ -74534,22 +74788,22 @@ var GL = class {
|
|
|
74534
74788
|
_onProgressMove;
|
|
74535
74789
|
_onProgressUp;
|
|
74536
74790
|
constructor(e, t, n = {}) {
|
|
74537
|
-
this._container = e, this._callbacks = t, this._autoHideMs = n.autoHideMs ?? 2500, 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");
|
|
74791
|
+
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");
|
|
74538
74792
|
let r = this._createProgressBar();
|
|
74539
74793
|
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();
|
|
74540
|
-
let i =
|
|
74794
|
+
let i = cR("div", {
|
|
74541
74795
|
display: "flex",
|
|
74542
74796
|
alignItems: "center",
|
|
74543
74797
|
gap: "4px"
|
|
74544
74798
|
});
|
|
74545
74799
|
i.appendChild(this._prevBtn), i.appendChild(this._playBtn), i.appendChild(this._nextBtn);
|
|
74546
|
-
let a =
|
|
74800
|
+
let a = cR("div", {
|
|
74547
74801
|
display: "flex",
|
|
74548
74802
|
alignItems: "center",
|
|
74549
74803
|
gap: "8px"
|
|
74550
74804
|
});
|
|
74551
74805
|
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);
|
|
74552
|
-
let o =
|
|
74806
|
+
let o = cR("div", {
|
|
74553
74807
|
display: "flex",
|
|
74554
74808
|
alignItems: "center",
|
|
74555
74809
|
justifyContent: "space-between",
|
|
@@ -74564,10 +74818,10 @@ var GL = class {
|
|
|
74564
74818
|
let n = e / t * 100;
|
|
74565
74819
|
this._progressFill.style.width = `${n}%`;
|
|
74566
74820
|
}
|
|
74567
|
-
this._timeDisplay.textContent = `${
|
|
74821
|
+
this._timeDisplay.textContent = `${uR(e)} / ${uR(t)}`;
|
|
74568
74822
|
}
|
|
74569
74823
|
setPlaying(e, t = !1) {
|
|
74570
|
-
this._isPlaying = e, t ? (this._playBtn.innerHTML =
|
|
74824
|
+
this._isPlaying = e, t ? (this._playBtn.innerHTML = pR, this._playBtn.title = "Replay (Space)") : (this._playBtn.innerHTML = e ? fR : dR, this._playBtn.title = e ? "Pause (Space)" : "Play (Space)"), e && this._scheduleHide();
|
|
74571
74825
|
}
|
|
74572
74826
|
setSlidesMode(e) {
|
|
74573
74827
|
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)`;
|
|
@@ -74577,7 +74831,7 @@ var GL = class {
|
|
|
74577
74831
|
let t = e.getSlides(), n = e.getDuration();
|
|
74578
74832
|
if (!(n <= 0)) for (let e of t) {
|
|
74579
74833
|
if (e.index === 0) continue;
|
|
74580
|
-
let t =
|
|
74834
|
+
let t = cR("div", {
|
|
74581
74835
|
position: "absolute",
|
|
74582
74836
|
left: `${e.startTime / n * 100}%`,
|
|
74583
74837
|
top: "50%",
|
|
@@ -74592,7 +74846,7 @@ var GL = class {
|
|
|
74592
74846
|
}
|
|
74593
74847
|
}
|
|
74594
74848
|
_createBar() {
|
|
74595
|
-
let e =
|
|
74849
|
+
let e = cR("div", {
|
|
74596
74850
|
position: "absolute",
|
|
74597
74851
|
bottom: "0",
|
|
74598
74852
|
left: "0",
|
|
@@ -74610,21 +74864,21 @@ var GL = class {
|
|
|
74610
74864
|
}
|
|
74611
74865
|
_createPlayBtn() {
|
|
74612
74866
|
let e = document.createElement("button");
|
|
74613
|
-
return e.innerHTML =
|
|
74867
|
+
return e.innerHTML = dR, e.title = "Play (Space)", lR(e, "36px", "36px"), e.addEventListener("click", () => this._callbacks.onPlayPause()), e;
|
|
74614
74868
|
}
|
|
74615
74869
|
_createNavBtn(e) {
|
|
74616
74870
|
let t = document.createElement("button");
|
|
74617
|
-
return t.innerHTML = e === "prev" ?
|
|
74871
|
+
return t.innerHTML = e === "prev" ? mR : hR, t.title = e === "prev" ? "Previous (Left arrow)" : "Next (Right arrow)", lR(t, "28px", "28px"), t.addEventListener("click", () => {
|
|
74618
74872
|
e === "prev" ? this._callbacks.onPrev() : this._callbacks.onNext();
|
|
74619
74873
|
}), t;
|
|
74620
74874
|
}
|
|
74621
74875
|
_createProgressBar() {
|
|
74622
|
-
let e =
|
|
74876
|
+
let e = cR("div", {
|
|
74623
74877
|
position: "relative",
|
|
74624
74878
|
height: "16px",
|
|
74625
74879
|
padding: "6px 12px",
|
|
74626
74880
|
cursor: "pointer"
|
|
74627
|
-
}), t =
|
|
74881
|
+
}), t = cR("div", {
|
|
74628
74882
|
position: "absolute",
|
|
74629
74883
|
left: "12px",
|
|
74630
74884
|
right: "12px",
|
|
@@ -74634,14 +74888,14 @@ var GL = class {
|
|
|
74634
74888
|
background: "rgba(255,255,255,0.2)",
|
|
74635
74889
|
borderRadius: "2px",
|
|
74636
74890
|
overflow: "visible"
|
|
74637
|
-
}), n =
|
|
74891
|
+
}), n = cR("div", {
|
|
74638
74892
|
width: "0%",
|
|
74639
74893
|
height: "100%",
|
|
74640
74894
|
background: "#4a9eff",
|
|
74641
74895
|
borderRadius: "2px",
|
|
74642
74896
|
transition: "none",
|
|
74643
74897
|
position: "relative"
|
|
74644
|
-
}), r =
|
|
74898
|
+
}), r = cR("div", {
|
|
74645
74899
|
position: "absolute",
|
|
74646
74900
|
right: "-5px",
|
|
74647
74901
|
top: "50%",
|
|
@@ -74654,7 +74908,7 @@ var GL = class {
|
|
|
74654
74908
|
transition: "transform 0.1s"
|
|
74655
74909
|
});
|
|
74656
74910
|
n.appendChild(r);
|
|
74657
|
-
let i =
|
|
74911
|
+
let i = cR("div", {
|
|
74658
74912
|
width: "0%",
|
|
74659
74913
|
height: "100%",
|
|
74660
74914
|
background: "rgba(255,255,255,0.1)",
|
|
@@ -74663,7 +74917,7 @@ var GL = class {
|
|
|
74663
74917
|
top: "0",
|
|
74664
74918
|
left: "0",
|
|
74665
74919
|
pointerEvents: "none"
|
|
74666
|
-
}), a =
|
|
74920
|
+
}), a = cR("div", {
|
|
74667
74921
|
position: "absolute",
|
|
74668
74922
|
top: "0",
|
|
74669
74923
|
left: "0",
|
|
@@ -74688,7 +74942,7 @@ var GL = class {
|
|
|
74688
74942
|
};
|
|
74689
74943
|
}
|
|
74690
74944
|
_createTimeDisplay() {
|
|
74691
|
-
let e =
|
|
74945
|
+
let e = cR("span", {
|
|
74692
74946
|
fontFamily: "\"SF Mono\", Monaco, Consolas, monospace",
|
|
74693
74947
|
fontSize: "12px",
|
|
74694
74948
|
opacity: "0.8",
|
|
@@ -74730,16 +74984,16 @@ var GL = class {
|
|
|
74730
74984
|
}), e;
|
|
74731
74985
|
}
|
|
74732
74986
|
_createExportBtn() {
|
|
74733
|
-
let e =
|
|
74987
|
+
let e = cR("div", {
|
|
74734
74988
|
position: "relative",
|
|
74735
74989
|
display: "inline-block"
|
|
74736
74990
|
}), t = document.createElement("button");
|
|
74737
|
-
return t.innerHTML =
|
|
74991
|
+
return t.innerHTML = gR, t.title = "Export animation", lR(t, "28px", "28px"), t.addEventListener("click", (e) => {
|
|
74738
74992
|
e.stopPropagation(), this._exportMenu ? this._closeExportMenu() : this._showExportMenu();
|
|
74739
74993
|
}), e.appendChild(t), this._exportBtnWrapper = e, t;
|
|
74740
74994
|
}
|
|
74741
74995
|
_showExportMenu() {
|
|
74742
|
-
let e = this._exportBtn.getBoundingClientRect(), t =
|
|
74996
|
+
let e = this._exportBtn.getBoundingClientRect(), t = cR("div", {
|
|
74743
74997
|
position: "fixed",
|
|
74744
74998
|
top: "0",
|
|
74745
74999
|
left: "0",
|
|
@@ -74750,7 +75004,7 @@ var GL = class {
|
|
|
74750
75004
|
t.setAttribute("data-player-bar", ""), t.addEventListener("mousedown", (e) => {
|
|
74751
75005
|
e.stopPropagation(), e.preventDefault(), this._closeExportMenu();
|
|
74752
75006
|
});
|
|
74753
|
-
let n =
|
|
75007
|
+
let n = cR("div", {
|
|
74754
75008
|
position: "fixed",
|
|
74755
75009
|
bottom: `${window.innerHeight - e.top + 6}px`,
|
|
74756
75010
|
left: `${e.left - 60}px`,
|
|
@@ -74765,7 +75019,14 @@ var GL = class {
|
|
|
74765
75019
|
fontFamily: "-apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif",
|
|
74766
75020
|
fontSize: "13px"
|
|
74767
75021
|
});
|
|
74768
|
-
n.setAttribute("data-player-bar", "")
|
|
75022
|
+
if (n.setAttribute("data-player-bar", ""), this._exportControls) {
|
|
75023
|
+
let e = this._callbacks.getExportDefaults?.() ?? {
|
|
75024
|
+
width: 1920,
|
|
75025
|
+
height: 1080,
|
|
75026
|
+
fps: 60
|
|
75027
|
+
};
|
|
75028
|
+
this._exportPanel = new oR(e), n.appendChild(this._exportPanel.element);
|
|
75029
|
+
}
|
|
74769
75030
|
for (let e of [
|
|
74770
75031
|
{
|
|
74771
75032
|
ext: "gif",
|
|
@@ -74783,7 +75044,7 @@ var GL = class {
|
|
|
74783
75044
|
desc: "Video file"
|
|
74784
75045
|
}
|
|
74785
75046
|
]) {
|
|
74786
|
-
let t =
|
|
75047
|
+
let t = cR("div", {
|
|
74787
75048
|
padding: "8px 14px",
|
|
74788
75049
|
cursor: "pointer",
|
|
74789
75050
|
fontSize: "13px",
|
|
@@ -74797,16 +75058,18 @@ var GL = class {
|
|
|
74797
75058
|
}), t.addEventListener("mouseleave", () => {
|
|
74798
75059
|
t.style.background = "none";
|
|
74799
75060
|
}), t.addEventListener("click", (t) => {
|
|
74800
|
-
t.stopPropagation()
|
|
75061
|
+
t.stopPropagation();
|
|
75062
|
+
let n = this._exportPanel?.getSettings();
|
|
75063
|
+
this._closeExportMenu(), n ? this._callbacks.onExport(e.ext, n) : this._callbacks.onExport(e.ext);
|
|
74801
75064
|
}), n.appendChild(t);
|
|
74802
75065
|
}
|
|
74803
75066
|
this._exportMenu = n, this._exportMenuBackdrop = t, document.body.appendChild(t), document.body.appendChild(n);
|
|
74804
75067
|
}
|
|
74805
75068
|
_closeExportMenu() {
|
|
74806
|
-
this._exportMenu
|
|
75069
|
+
this._exportMenu && (this._exportMenuBackdrop?.remove(), this._exportMenuBackdrop = null, this._exportMenu.remove(), this._exportMenu = null, this._exportPanel = null);
|
|
74807
75070
|
}
|
|
74808
75071
|
setExportProgress(e) {
|
|
74809
|
-
if (e === null) this._exportBtn.innerHTML =
|
|
75072
|
+
if (e === null) this._exportBtn.innerHTML = gR, this._exportBtn.disabled = !1, this._exportBtn.title = "Export animation";
|
|
74810
75073
|
else {
|
|
74811
75074
|
let t = Math.round(e * 100);
|
|
74812
75075
|
this._exportBtn.innerHTML = `<span style="font-size:10px;font-weight:600">${t}%</span>`, this._exportBtn.disabled = !0, this._exportBtn.title = `Exporting... ${t}%`;
|
|
@@ -74814,7 +75077,7 @@ var GL = class {
|
|
|
74814
75077
|
}
|
|
74815
75078
|
_createSlidesBtn() {
|
|
74816
75079
|
let e = document.createElement("button");
|
|
74817
|
-
return e.innerHTML =
|
|
75080
|
+
return e.innerHTML = _R, e.title = "Slides mode off (S)", lR(e, "28px", "28px"), e.style.opacity = "0.4", e.addEventListener("click", () => {
|
|
74818
75081
|
this._slidesActive = !this._slidesActive, this.setSlidesMode(this._slidesActive), this._callbacks.onSlidesToggle(this._slidesActive);
|
|
74819
75082
|
}), e.addEventListener("mouseenter", () => {
|
|
74820
75083
|
e.style.background = this._slidesActive ? "rgba(74,158,255,0.35)" : "rgba(255,255,255,0.15)";
|
|
@@ -74824,7 +75087,7 @@ var GL = class {
|
|
|
74824
75087
|
}
|
|
74825
75088
|
_createFullscreenBtn() {
|
|
74826
75089
|
let e = document.createElement("button");
|
|
74827
|
-
return e.innerHTML =
|
|
75090
|
+
return e.innerHTML = vR, e.title = "Fullscreen (F)", lR(e, "28px", "28px"), e.addEventListener("click", () => this._callbacks.onFullscreen()), e;
|
|
74828
75091
|
}
|
|
74829
75092
|
_showControls() {
|
|
74830
75093
|
this._isVisible ||= (this._bar.style.opacity = "1", this._bar.style.transform = "translateY(0)", !0), this._scheduleHide();
|
|
@@ -74879,11 +75142,11 @@ var GL = class {
|
|
|
74879
75142
|
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();
|
|
74880
75143
|
}
|
|
74881
75144
|
};
|
|
74882
|
-
function
|
|
75145
|
+
function cR(e, t) {
|
|
74883
75146
|
let n = document.createElement(e);
|
|
74884
75147
|
return Object.assign(n.style, t), n;
|
|
74885
75148
|
}
|
|
74886
|
-
function
|
|
75149
|
+
function lR(e, t, n) {
|
|
74887
75150
|
Object.assign(e.style, {
|
|
74888
75151
|
width: t,
|
|
74889
75152
|
height: n,
|
|
@@ -74904,11 +75167,11 @@ function qL(e, t, n) {
|
|
|
74904
75167
|
e.style.background = "none";
|
|
74905
75168
|
});
|
|
74906
75169
|
}
|
|
74907
|
-
function
|
|
75170
|
+
function uR(e) {
|
|
74908
75171
|
let t = Math.floor(e / 60), n = Math.floor(e % 60);
|
|
74909
75172
|
return `${t}:${String(n).padStart(2, "0")}`;
|
|
74910
75173
|
}
|
|
74911
|
-
var
|
|
75174
|
+
var dR = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentColor\"><path d=\"M5 3l10 6-10 6V3z\"/></svg>", fR = "<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>", pR = "<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>", mR = "<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>", hR = "<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>", gR = "<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>", _R = "<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>", vR = "<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>", yR = class {
|
|
74912
75175
|
_container;
|
|
74913
75176
|
_callbacks;
|
|
74914
75177
|
_onKeyDown;
|
|
@@ -74938,7 +75201,7 @@ var YL = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
|
|
|
74938
75201
|
dispose() {
|
|
74939
75202
|
this._container.removeEventListener("keydown", this._onKeyDown);
|
|
74940
75203
|
}
|
|
74941
|
-
},
|
|
75204
|
+
}, bR = class {
|
|
74942
75205
|
_realScene;
|
|
74943
75206
|
_masterTimeline;
|
|
74944
75207
|
constructor(e, t) {
|
|
@@ -74975,7 +75238,52 @@ var YL = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
|
|
|
74975
75238
|
for (let n of e) t.push(n), n instanceof zT && t.push(...this._collectAll(n.animations));
|
|
74976
75239
|
return t;
|
|
74977
75240
|
}
|
|
74978
|
-
},
|
|
75241
|
+
}, xR = [
|
|
75242
|
+
"mousedown",
|
|
75243
|
+
"mousemove",
|
|
75244
|
+
"mouseup",
|
|
75245
|
+
"click",
|
|
75246
|
+
"touchstart",
|
|
75247
|
+
"touchmove",
|
|
75248
|
+
"touchend"
|
|
75249
|
+
], SR = class {
|
|
75250
|
+
_target;
|
|
75251
|
+
_scene;
|
|
75252
|
+
_isIdle;
|
|
75253
|
+
_onEvent;
|
|
75254
|
+
_attached = !1;
|
|
75255
|
+
_renderScheduled = !1;
|
|
75256
|
+
_renderCount = 0;
|
|
75257
|
+
constructor(e, t, n) {
|
|
75258
|
+
this._target = e, this._scene = t, this._isIdle = n, this._onEvent = () => this._handleEvent();
|
|
75259
|
+
}
|
|
75260
|
+
get isAttached() {
|
|
75261
|
+
return this._attached;
|
|
75262
|
+
}
|
|
75263
|
+
get renderCount() {
|
|
75264
|
+
return this._renderCount;
|
|
75265
|
+
}
|
|
75266
|
+
attach() {
|
|
75267
|
+
if (!this._attached) {
|
|
75268
|
+
for (let e of xR) this._target.addEventListener(e, this._onEvent);
|
|
75269
|
+
this._attached = !0;
|
|
75270
|
+
}
|
|
75271
|
+
}
|
|
75272
|
+
dispose() {
|
|
75273
|
+
if (this._attached) {
|
|
75274
|
+
for (let e of xR) this._target.removeEventListener(e, this._onEvent);
|
|
75275
|
+
this._attached = !1, this._renderScheduled = !1;
|
|
75276
|
+
}
|
|
75277
|
+
}
|
|
75278
|
+
_handleEvent() {
|
|
75279
|
+
this._isIdle() && this._scheduleRender();
|
|
75280
|
+
}
|
|
75281
|
+
_scheduleRender() {
|
|
75282
|
+
this._renderScheduled || (this._renderScheduled = !0, queueMicrotask(() => {
|
|
75283
|
+
this._renderScheduled = !1, !(!this._attached || !this._isIdle()) && (this._scene.render(), this._renderCount++);
|
|
75284
|
+
}));
|
|
75285
|
+
}
|
|
75286
|
+
}, CR = class {
|
|
74979
75287
|
_scene;
|
|
74980
75288
|
_masterTimeline;
|
|
74981
75289
|
_ui;
|
|
@@ -74988,22 +75296,34 @@ var YL = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
|
|
|
74988
75296
|
_loop;
|
|
74989
75297
|
_autoPlay;
|
|
74990
75298
|
_slidesMode;
|
|
75299
|
+
_interactiveSlides;
|
|
75300
|
+
_slideInteraction = null;
|
|
75301
|
+
_exportControls;
|
|
75302
|
+
_exportFps;
|
|
74991
75303
|
_slidesTargetSlideIndex = -1;
|
|
74992
75304
|
_activeLoopSlideIndex = null;
|
|
74993
75305
|
_origWidth = 0;
|
|
74994
75306
|
_origHeight = 0;
|
|
74995
75307
|
_onFullscreenChange;
|
|
74996
75308
|
constructor(e, t = {}) {
|
|
74997
|
-
this._container = e, this._loop = t.loop ?? !1, this._autoPlay = t.autoPlay ?? !1, this._slidesMode = t.slidesMode ?? !1, this._scene = new $T(e, t), this._masterTimeline = new eP(), this._ui = new
|
|
75309
|
+
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 $T(e, t), this._masterTimeline = new eP(), this._ui = new sR(e, {
|
|
74998
75310
|
onPlayPause: () => this.togglePlayPause(),
|
|
74999
75311
|
onSeek: (e) => this.seek(e),
|
|
75000
75312
|
onPrev: () => this.prevSegment(),
|
|
75001
75313
|
onNext: () => this.nextSegment(),
|
|
75002
75314
|
onSpeedChange: (e) => this.setPlaybackRate(e),
|
|
75003
75315
|
onFullscreen: () => this.toggleFullscreen(),
|
|
75004
|
-
onExport: (e) => this.exportAs(e),
|
|
75005
|
-
onSlidesToggle: (e) => this.setSlidesMode(e)
|
|
75006
|
-
|
|
75316
|
+
onExport: (e, t) => this.exportAs(e, t),
|
|
75317
|
+
onSlidesToggle: (e) => this.setSlidesMode(e),
|
|
75318
|
+
getExportDefaults: () => ({
|
|
75319
|
+
width: this._scene.getWidth(),
|
|
75320
|
+
height: this._scene.getHeight(),
|
|
75321
|
+
fps: this._exportFps
|
|
75322
|
+
})
|
|
75323
|
+
}, {
|
|
75324
|
+
autoHideMs: t.autoHideMs,
|
|
75325
|
+
exportControls: this._exportControls
|
|
75326
|
+
}), this._ui.setSlidesMode(this._slidesMode), this._ui.enableScrollScrub(() => this._masterTimeline.getCurrentTime()), this._controller = new yR(e, {
|
|
75007
75327
|
onPlayPause: () => this.togglePlayPause(),
|
|
75008
75328
|
onPrev: () => this.prevSegment(),
|
|
75009
75329
|
onNext: () => this.nextSegment(),
|
|
@@ -75014,10 +75334,13 @@ var YL = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
|
|
|
75014
75334
|
getDuration: () => this._masterTimeline.getDuration()
|
|
75015
75335
|
}), this._onFullscreenChange = () => {
|
|
75016
75336
|
document.fullscreenElement === this._container ? this._scene.resize(window.innerWidth, window.innerHeight) : this._origWidth > 0 && this._origHeight > 0 && this._scene.resize(this._origWidth, this._origHeight), this._scene.render();
|
|
75017
|
-
}, document.addEventListener("fullscreenchange", this._onFullscreenChange);
|
|
75337
|
+
}, document.addEventListener("fullscreenchange", this._onFullscreenChange), this._interactiveSlides && this._enableSlideInteraction();
|
|
75338
|
+
}
|
|
75339
|
+
_enableSlideInteraction() {
|
|
75340
|
+
this._slideInteraction || (this._slideInteraction = new SR(this._container, this._scene, () => !this._isPlaying), this._slideInteraction.attach());
|
|
75018
75341
|
}
|
|
75019
75342
|
async sequence(e) {
|
|
75020
|
-
this._masterTimeline = new eP(), this._activeLoopSlideIndex = null, this._slidesTargetSlideIndex = -1, await e(new
|
|
75343
|
+
this._masterTimeline = new eP(), this._activeLoopSlideIndex = null, this._slidesTargetSlideIndex = -1, await e(new bR(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();
|
|
75021
75344
|
}
|
|
75022
75345
|
get scene() {
|
|
75023
75346
|
return this._scene;
|
|
@@ -75116,23 +75439,44 @@ var YL = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
|
|
|
75116
75439
|
setSlidesMode(e) {
|
|
75117
75440
|
this._slidesMode = e, this._ui.setSlidesMode(e), e || (this._activeLoopSlideIndex = null, this._slidesTargetSlideIndex = -1);
|
|
75118
75441
|
}
|
|
75119
|
-
|
|
75120
|
-
|
|
75121
|
-
|
|
75122
|
-
|
|
75442
|
+
get interactiveSlides() {
|
|
75443
|
+
return this._interactiveSlides;
|
|
75444
|
+
}
|
|
75445
|
+
setInteractiveSlides(e) {
|
|
75446
|
+
this._interactiveSlides = e, e ? this._enableSlideInteraction() : this._slideInteraction &&= (this._slideInteraction.dispose(), null);
|
|
75447
|
+
}
|
|
75448
|
+
async exportAs(e, t) {
|
|
75449
|
+
let n = this._isPlaying, r = this._masterTimeline.getCurrentTime();
|
|
75450
|
+
n && this.pause();
|
|
75451
|
+
let i = `animation.${e}`, a = this._masterTimeline.getDuration(), o = (e) => this._ui.setExportProgress(e);
|
|
75123
75452
|
this._ui.setExportProgress(0);
|
|
75124
75453
|
try {
|
|
75125
|
-
await this._scene.export(
|
|
75126
|
-
duration: this._masterTimeline.getDuration(),
|
|
75127
|
-
width: this._scene.getWidth(),
|
|
75128
|
-
height: this._scene.getHeight(),
|
|
75129
|
-
onProgress: (e) => this._ui.setExportProgress(e)
|
|
75130
|
-
});
|
|
75454
|
+
(e === "webm" || e === "mp4") && $L() === "webcodecs" ? await this._exportWithWebCodecs(e === "mp4" ? "mp4" : "webm", t, a, o, i) : await this._scene.export(i, this._buildSceneExportOptions(e, t, a, o));
|
|
75131
75455
|
} catch (e) {
|
|
75132
75456
|
Gf.error("Export failed:", e), this._ui.showError(`Export failed: ${e instanceof Error ? e.message : "Unknown error"}`);
|
|
75133
75457
|
} finally {
|
|
75134
|
-
this._ui.setExportProgress(null), this.seek(
|
|
75135
|
-
}
|
|
75458
|
+
this._ui.setExportProgress(null), this.seek(r), n && this.play();
|
|
75459
|
+
}
|
|
75460
|
+
}
|
|
75461
|
+
async _exportWithWebCodecs(e, t, n, r, i) {
|
|
75462
|
+
JL(await new ZL(this._scene, {
|
|
75463
|
+
format: e,
|
|
75464
|
+
fps: t?.fps ?? this._exportFps,
|
|
75465
|
+
width: t?.width ?? this._scene.getWidth(),
|
|
75466
|
+
height: t?.height ?? this._scene.getHeight(),
|
|
75467
|
+
bitrate: iR(t?.quality ?? .9),
|
|
75468
|
+
duration: n,
|
|
75469
|
+
onProgress: r
|
|
75470
|
+
}).export(), i);
|
|
75471
|
+
}
|
|
75472
|
+
_buildSceneExportOptions(e, t, n, r) {
|
|
75473
|
+
let i = {
|
|
75474
|
+
duration: n,
|
|
75475
|
+
width: this._scene.getWidth(),
|
|
75476
|
+
height: this._scene.getHeight(),
|
|
75477
|
+
onProgress: r
|
|
75478
|
+
};
|
|
75479
|
+
return t ? (i.width = t.width, i.height = t.height, i.fps = t.fps, e !== "gif" && (i.quality = t.quality), i) : i;
|
|
75136
75480
|
}
|
|
75137
75481
|
toggleFullscreen() {
|
|
75138
75482
|
document.fullscreenElement === this._container ? document.exitFullscreen() : (this._origWidth = this._scene.getWidth(), this._origHeight = this._scene.getHeight(), this._container.requestFullscreen().catch(() => {
|
|
@@ -75140,7 +75484,7 @@ var YL = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
|
|
|
75140
75484
|
}));
|
|
75141
75485
|
}
|
|
75142
75486
|
dispose() {
|
|
75143
|
-
this._stopLoop(), document.removeEventListener("fullscreenchange", this._onFullscreenChange), this._ui.dispose(), this._controller.dispose(), this._scene.dispose();
|
|
75487
|
+
this._stopLoop(), this._slideInteraction?.dispose(), this._slideInteraction = null, document.removeEventListener("fullscreenchange", this._onFullscreenChange), this._ui.dispose(), this._controller.dispose(), this._scene.dispose();
|
|
75144
75488
|
}
|
|
75145
75489
|
_startLoop() {
|
|
75146
75490
|
if (this._animFrameId !== null) return;
|
|
@@ -75181,31 +75525,31 @@ var YL = "<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" fill=\"currentCo
|
|
|
75181
75525
|
_stopLoop() {
|
|
75182
75526
|
this._animFrameId !== null && (cancelAnimationFrame(this._animFrameId), this._animFrameId = null);
|
|
75183
75527
|
}
|
|
75184
|
-
},
|
|
75528
|
+
}, wR = {
|
|
75185
75529
|
EXPERIMENTAL_3D_LIGHTING: !1,
|
|
75186
75530
|
WEBGPU_RENDERER: !1,
|
|
75187
75531
|
ADVANCED_TEXT_LAYOUT: !1
|
|
75188
|
-
},
|
|
75189
|
-
function
|
|
75190
|
-
return
|
|
75532
|
+
}, TR = { ...wR };
|
|
75533
|
+
function ER(e) {
|
|
75534
|
+
return TR[e] ?? !1;
|
|
75191
75535
|
}
|
|
75192
|
-
function
|
|
75193
|
-
|
|
75194
|
-
...
|
|
75536
|
+
function DR(e) {
|
|
75537
|
+
TR = {
|
|
75538
|
+
...TR,
|
|
75195
75539
|
...e
|
|
75196
75540
|
};
|
|
75197
75541
|
}
|
|
75198
|
-
function
|
|
75199
|
-
|
|
75542
|
+
function OR() {
|
|
75543
|
+
TR = { ...wR };
|
|
75200
75544
|
}
|
|
75201
|
-
function
|
|
75202
|
-
return { ...
|
|
75545
|
+
function kR() {
|
|
75546
|
+
return { ...TR };
|
|
75203
75547
|
}
|
|
75204
75548
|
//#endregion
|
|
75205
75549
|
//#region src/utils/color.ts
|
|
75206
|
-
var
|
|
75207
|
-
function
|
|
75208
|
-
let t =
|
|
75550
|
+
var AR = /(?:#|0[xX])([A-Fa-f0-9]{3,8})/;
|
|
75551
|
+
function jR(e) {
|
|
75552
|
+
let t = AR.exec(e);
|
|
75209
75553
|
if (t === null) throw Error(`Failed to parse a color from "${e}"`);
|
|
75210
75554
|
let n = t[1];
|
|
75211
75555
|
if ((n.length === 3 || n.length === 4) && (n = n.split("").map((e) => e + e).join("")), n.length === 6) n += "FF";
|
|
@@ -75217,26 +75561,26 @@ function pR(e) {
|
|
|
75217
75561
|
parseInt(n.slice(6, 8), 16) / 255
|
|
75218
75562
|
];
|
|
75219
75563
|
}
|
|
75220
|
-
function
|
|
75564
|
+
function MR(e) {
|
|
75221
75565
|
let t = Math.trunc(e * 255);
|
|
75222
75566
|
return Math.min(255, Math.max(0, t)).toString(16).toUpperCase().padStart(2, "0");
|
|
75223
75567
|
}
|
|
75224
|
-
function
|
|
75225
|
-
return `#${
|
|
75568
|
+
function NR(e) {
|
|
75569
|
+
return `#${MR(e[0])}${MR(e[1])}${MR(e[2])}`;
|
|
75226
75570
|
}
|
|
75227
|
-
function
|
|
75228
|
-
let [t, n, r] =
|
|
75571
|
+
function PR(e) {
|
|
75572
|
+
let [t, n, r] = jR(e);
|
|
75229
75573
|
return [
|
|
75230
75574
|
t,
|
|
75231
75575
|
n,
|
|
75232
75576
|
r
|
|
75233
75577
|
];
|
|
75234
75578
|
}
|
|
75235
|
-
function
|
|
75236
|
-
return
|
|
75579
|
+
function FR(e) {
|
|
75580
|
+
return PR(e);
|
|
75237
75581
|
}
|
|
75238
|
-
function
|
|
75239
|
-
let [n, r, i] =
|
|
75582
|
+
function IR(e, t = 1) {
|
|
75583
|
+
let [n, r, i] = FR(e);
|
|
75240
75584
|
return [
|
|
75241
75585
|
n,
|
|
75242
75586
|
r,
|
|
@@ -75244,16 +75588,16 @@ function vR(e, t = 1) {
|
|
|
75244
75588
|
t
|
|
75245
75589
|
];
|
|
75246
75590
|
}
|
|
75247
|
-
function
|
|
75248
|
-
let [t, n, r] =
|
|
75591
|
+
function LR(e) {
|
|
75592
|
+
let [t, n, r] = FR(e);
|
|
75249
75593
|
return [
|
|
75250
75594
|
Math.trunc(t * 255),
|
|
75251
75595
|
Math.trunc(n * 255),
|
|
75252
75596
|
Math.trunc(r * 255)
|
|
75253
75597
|
];
|
|
75254
75598
|
}
|
|
75255
|
-
function
|
|
75256
|
-
let [n, r, i] =
|
|
75599
|
+
function RR(e, t = 1) {
|
|
75600
|
+
let [n, r, i] = LR(e);
|
|
75257
75601
|
return [
|
|
75258
75602
|
n,
|
|
75259
75603
|
r,
|
|
@@ -75261,33 +75605,33 @@ function bR(e, t = 1) {
|
|
|
75261
75605
|
Math.trunc(t * 255)
|
|
75262
75606
|
];
|
|
75263
75607
|
}
|
|
75264
|
-
function
|
|
75265
|
-
return
|
|
75608
|
+
function zR(e) {
|
|
75609
|
+
return NR(e);
|
|
75266
75610
|
}
|
|
75267
|
-
function
|
|
75268
|
-
return
|
|
75611
|
+
function BR(e) {
|
|
75612
|
+
return NR([
|
|
75269
75613
|
e[0],
|
|
75270
75614
|
e[1],
|
|
75271
75615
|
e[2]
|
|
75272
75616
|
]);
|
|
75273
75617
|
}
|
|
75274
|
-
function
|
|
75275
|
-
let [t, n, r] =
|
|
75276
|
-
return
|
|
75618
|
+
function VR(e) {
|
|
75619
|
+
let [t, n, r] = FR(e);
|
|
75620
|
+
return NR([
|
|
75277
75621
|
1 - t,
|
|
75278
75622
|
1 - n,
|
|
75279
75623
|
1 - r
|
|
75280
75624
|
]);
|
|
75281
75625
|
}
|
|
75282
|
-
function
|
|
75283
|
-
let r =
|
|
75284
|
-
return
|
|
75626
|
+
function HR(e, t, n) {
|
|
75627
|
+
let r = FR(e), i = FR(t);
|
|
75628
|
+
return NR([
|
|
75285
75629
|
r[0] * (1 - n) + i[0] * n,
|
|
75286
75630
|
r[1] * (1 - n) + i[1] * n,
|
|
75287
75631
|
r[2] * (1 - n) + i[2] * n
|
|
75288
75632
|
]);
|
|
75289
75633
|
}
|
|
75290
|
-
function
|
|
75634
|
+
function UR(...e) {
|
|
75291
75635
|
if (e.length === 0) throw Error("Expected 1 or more colors. Got 0 colors.");
|
|
75292
75636
|
let t = [
|
|
75293
75637
|
0,
|
|
@@ -75295,29 +75639,29 @@ function TR(...e) {
|
|
|
75295
75639
|
0
|
|
75296
75640
|
];
|
|
75297
75641
|
for (let n of e) {
|
|
75298
|
-
let [e, r, i] =
|
|
75642
|
+
let [e, r, i] = FR(n);
|
|
75299
75643
|
t[0] += e, t[1] += r, t[2] += i;
|
|
75300
75644
|
}
|
|
75301
75645
|
let n = e.length;
|
|
75302
|
-
return
|
|
75646
|
+
return NR([
|
|
75303
75647
|
t[0] / n,
|
|
75304
75648
|
t[1] / n,
|
|
75305
75649
|
t[2] / n
|
|
75306
75650
|
]);
|
|
75307
75651
|
}
|
|
75308
|
-
var
|
|
75309
|
-
function
|
|
75310
|
-
return
|
|
75652
|
+
var WR = Array.from(new Set(Object.values(fl)));
|
|
75653
|
+
function GR() {
|
|
75654
|
+
return WR[Math.floor(Math.random() * WR.length)];
|
|
75311
75655
|
}
|
|
75312
|
-
function
|
|
75313
|
-
let [e, t, n] =
|
|
75314
|
-
return
|
|
75656
|
+
function KR() {
|
|
75657
|
+
let [e, t, n] = FR(GR());
|
|
75658
|
+
return NR([
|
|
75315
75659
|
.5 * (e + 1),
|
|
75316
75660
|
.5 * (t + 1),
|
|
75317
75661
|
.5 * (n + 1)
|
|
75318
75662
|
]);
|
|
75319
75663
|
}
|
|
75320
|
-
function
|
|
75664
|
+
function qR(e) {
|
|
75321
75665
|
let [t, n, r] = e;
|
|
75322
75666
|
if (n === 0) return [
|
|
75323
75667
|
r,
|
|
@@ -75358,7 +75702,7 @@ function kR(e) {
|
|
|
75358
75702
|
];
|
|
75359
75703
|
}
|
|
75360
75704
|
}
|
|
75361
|
-
function
|
|
75705
|
+
function JR(e) {
|
|
75362
75706
|
let [t, n, r] = e, i = Math.max(t, n, r), a = Math.min(t, n, r), o = i;
|
|
75363
75707
|
if (a === i) return [
|
|
75364
75708
|
0,
|
|
@@ -75374,14 +75718,14 @@ function AR(e) {
|
|
|
75374
75718
|
}
|
|
75375
75719
|
//#endregion
|
|
75376
75720
|
//#region src/utils/ManimColor.ts
|
|
75377
|
-
var
|
|
75378
|
-
function
|
|
75721
|
+
var YR = /(?:#|0[xX])([A-Fa-f0-9]{3,8})/;
|
|
75722
|
+
function XR(e) {
|
|
75379
75723
|
return Math.min(255, Math.max(0, Math.trunc(e * 255)));
|
|
75380
75724
|
}
|
|
75381
|
-
function
|
|
75382
|
-
return
|
|
75725
|
+
function ZR(e) {
|
|
75726
|
+
return XR(e).toString(16).toUpperCase().padStart(2, "0");
|
|
75383
75727
|
}
|
|
75384
|
-
function
|
|
75728
|
+
function QR(e, t) {
|
|
75385
75729
|
let n = e;
|
|
75386
75730
|
(n.length === 3 || n.length === 4) && (n = n.split("").map((e) => e + e).join(""));
|
|
75387
75731
|
let r = t;
|
|
@@ -75394,14 +75738,14 @@ function PR(e, t) {
|
|
|
75394
75738
|
r
|
|
75395
75739
|
];
|
|
75396
75740
|
}
|
|
75397
|
-
function
|
|
75398
|
-
let n =
|
|
75399
|
-
if (n !== null) return
|
|
75741
|
+
function $R(e, t) {
|
|
75742
|
+
let n = YR.exec(e);
|
|
75743
|
+
if (n !== null) return QR(n[1], t);
|
|
75400
75744
|
let r = fl[e.toUpperCase()];
|
|
75401
|
-
if (typeof r == "string") return
|
|
75745
|
+
if (typeof r == "string") return $R(r, t);
|
|
75402
75746
|
throw Error(`Failed to parse a color from "${e}"`);
|
|
75403
75747
|
}
|
|
75404
|
-
function
|
|
75748
|
+
function ez(e, t) {
|
|
75405
75749
|
return [
|
|
75406
75750
|
(e >> 16 & 255) / 255,
|
|
75407
75751
|
(e >> 8 & 255) / 255,
|
|
@@ -75409,7 +75753,7 @@ function IR(e, t) {
|
|
|
75409
75753
|
t
|
|
75410
75754
|
];
|
|
75411
75755
|
}
|
|
75412
|
-
var
|
|
75756
|
+
var tz = class e {
|
|
75413
75757
|
value;
|
|
75414
75758
|
constructor(t, n = 1) {
|
|
75415
75759
|
if (t === null) this.value = [
|
|
@@ -75426,8 +75770,8 @@ var LR = class e {
|
|
|
75426
75770
|
e[2],
|
|
75427
75771
|
e[3]
|
|
75428
75772
|
];
|
|
75429
|
-
} else if (typeof t == "number") this.value =
|
|
75430
|
-
else if (typeof t == "string") this.value =
|
|
75773
|
+
} else if (typeof t == "number") this.value = ez(t, n);
|
|
75774
|
+
else if (typeof t == "string") this.value = $R(t, n);
|
|
75431
75775
|
else if (t.length === 3) this.value = [
|
|
75432
75776
|
t[0],
|
|
75433
75777
|
t[1],
|
|
@@ -75485,30 +75829,30 @@ var LR = class e {
|
|
|
75485
75829
|
toIntRgb() {
|
|
75486
75830
|
let e = this.internalRgba();
|
|
75487
75831
|
return [
|
|
75488
|
-
|
|
75489
|
-
|
|
75490
|
-
|
|
75832
|
+
XR(e[0]),
|
|
75833
|
+
XR(e[1]),
|
|
75834
|
+
XR(e[2])
|
|
75491
75835
|
];
|
|
75492
75836
|
}
|
|
75493
75837
|
toIntRgba() {
|
|
75494
75838
|
let e = this.internalRgba();
|
|
75495
75839
|
return [
|
|
75496
|
-
|
|
75497
|
-
|
|
75498
|
-
|
|
75499
|
-
|
|
75840
|
+
XR(e[0]),
|
|
75841
|
+
XR(e[1]),
|
|
75842
|
+
XR(e[2]),
|
|
75843
|
+
XR(e[3])
|
|
75500
75844
|
];
|
|
75501
75845
|
}
|
|
75502
75846
|
toHex(e = !1) {
|
|
75503
|
-
let t = this.internalRgba(), n =
|
|
75847
|
+
let t = this.internalRgba(), n = NR([
|
|
75504
75848
|
t[0],
|
|
75505
75849
|
t[1],
|
|
75506
75850
|
t[2]
|
|
75507
75851
|
]);
|
|
75508
|
-
return e ? n +
|
|
75852
|
+
return e ? n + ZR(t[3]) : n;
|
|
75509
75853
|
}
|
|
75510
75854
|
toHsv() {
|
|
75511
|
-
return
|
|
75855
|
+
return JR(this.toRgb());
|
|
75512
75856
|
}
|
|
75513
75857
|
interpolate(e, t) {
|
|
75514
75858
|
let n = this.getSpace(), r = e.getSpace();
|
|
@@ -75560,12 +75904,12 @@ var LR = class e {
|
|
|
75560
75904
|
return new e(t, n);
|
|
75561
75905
|
}
|
|
75562
75906
|
static fromHsv(t, n = 1) {
|
|
75563
|
-
return new e(
|
|
75907
|
+
return new e(qR(t), n);
|
|
75564
75908
|
}
|
|
75565
75909
|
static parse(t, n = 1) {
|
|
75566
75910
|
return Array.isArray(t) && t.some((e) => typeof e != "number") ? t.map((t) => new e(t, n)) : new e(t, n);
|
|
75567
75911
|
}
|
|
75568
|
-
},
|
|
75912
|
+
}, nz = tz, rz = class e extends tz {
|
|
75569
75913
|
hsva;
|
|
75570
75914
|
constructor(e, t = 1) {
|
|
75571
75915
|
if (super(null), e.length === 3) this.hsva = [
|
|
@@ -75583,7 +75927,7 @@ var LR = class e {
|
|
|
75583
75927
|
else throw Error("HSV color must be an array of 3 or 4 values");
|
|
75584
75928
|
}
|
|
75585
75929
|
internalRgba() {
|
|
75586
|
-
let e =
|
|
75930
|
+
let e = qR([
|
|
75587
75931
|
this.hsva[0],
|
|
75588
75932
|
this.hsva[1],
|
|
75589
75933
|
this.hsva[2]
|
|
@@ -75612,7 +75956,7 @@ var LR = class e {
|
|
|
75612
75956
|
]);
|
|
75613
75957
|
}
|
|
75614
75958
|
fromInternal(t) {
|
|
75615
|
-
let n =
|
|
75959
|
+
let n = JR([
|
|
75616
75960
|
t[0],
|
|
75617
75961
|
t[1],
|
|
75618
75962
|
t[2]
|
|
@@ -75634,7 +75978,7 @@ var LR = class e {
|
|
|
75634
75978
|
return this.hsva[2];
|
|
75635
75979
|
}
|
|
75636
75980
|
};
|
|
75637
|
-
function
|
|
75981
|
+
function iz(e) {
|
|
75638
75982
|
let t = e >>> 0;
|
|
75639
75983
|
return () => {
|
|
75640
75984
|
t = t + 1831565813 | 0;
|
|
@@ -75642,18 +75986,18 @@ function BR(e) {
|
|
|
75642
75986
|
return e = e + Math.imul(e ^ e >>> 7, 61 | e) ^ e, ((e ^ e >>> 14) >>> 0) / 4294967296;
|
|
75643
75987
|
};
|
|
75644
75988
|
}
|
|
75645
|
-
var
|
|
75989
|
+
var az = Array.from(new Set(Object.values(fl))).map((e) => new tz(e)), oz = class {
|
|
75646
75990
|
rng;
|
|
75647
75991
|
colors;
|
|
75648
75992
|
constructor(e, t) {
|
|
75649
|
-
this.rng = e === void 0 ? Math.random :
|
|
75993
|
+
this.rng = e === void 0 ? Math.random : iz(e), this.colors = t === void 0 ? az : t.map((e) => e instanceof tz ? e : new tz(e));
|
|
75650
75994
|
}
|
|
75651
75995
|
next() {
|
|
75652
75996
|
let e = Math.floor(this.rng() * this.colors.length);
|
|
75653
75997
|
return this.colors[e];
|
|
75654
75998
|
}
|
|
75655
75999
|
};
|
|
75656
|
-
function
|
|
76000
|
+
function sz(e, t, n, r) {
|
|
75657
76001
|
let i = .5 * Jd(n, Zd([
|
|
75658
76002
|
r[0] - t[0],
|
|
75659
76003
|
r[1] - t[1],
|
|
@@ -75667,7 +76011,7 @@ function UR(e, t, n, r) {
|
|
|
75667
76011
|
}
|
|
75668
76012
|
//#endregion
|
|
75669
76013
|
//#region src/utils/iterables.ts
|
|
75670
|
-
function
|
|
76014
|
+
function cz(e, t) {
|
|
75671
76015
|
let n = e.length;
|
|
75672
76016
|
if (n === 0) return [];
|
|
75673
76017
|
let r = [];
|
|
@@ -75678,10 +76022,10 @@ function WR(e, t) {
|
|
|
75678
76022
|
}
|
|
75679
76023
|
return r;
|
|
75680
76024
|
}
|
|
75681
|
-
function
|
|
75682
|
-
return
|
|
76025
|
+
function lz(e) {
|
|
76026
|
+
return cz(e, 2);
|
|
75683
76027
|
}
|
|
75684
|
-
function
|
|
76028
|
+
function uz(e) {
|
|
75685
76029
|
let t = [], n = /* @__PURE__ */ new Set();
|
|
75686
76030
|
for (let r = e.length - 1; r >= 0; r--) {
|
|
75687
76031
|
let i = e[r];
|
|
@@ -75689,7 +76033,7 @@ function KR(e) {
|
|
|
75689
76033
|
}
|
|
75690
76034
|
return t.reverse(), t;
|
|
75691
76035
|
}
|
|
75692
|
-
function
|
|
76036
|
+
function dz(e, t, n) {
|
|
75693
76037
|
if (n === void 0) {
|
|
75694
76038
|
let n = new Set(t);
|
|
75695
76039
|
return e.filter((e) => !n.has(e));
|
|
@@ -75697,29 +76041,29 @@ function qR(e, t, n) {
|
|
|
75697
76041
|
let r = new Set(t.map((e) => n(e)));
|
|
75698
76042
|
return e.filter((e) => !r.has(n(e)));
|
|
75699
76043
|
}
|
|
75700
|
-
function
|
|
75701
|
-
return
|
|
76044
|
+
function fz(e, t, n) {
|
|
76045
|
+
return dz(e, t, n).concat(t);
|
|
75702
76046
|
}
|
|
75703
|
-
function
|
|
76047
|
+
function pz(e) {
|
|
75704
76048
|
return typeof e == "string" ? [e] : typeof e == "object" && e && Symbol.iterator in e ? [...e] : [e];
|
|
75705
76049
|
}
|
|
75706
|
-
function
|
|
76050
|
+
function mz(e, t) {
|
|
75707
76051
|
let n = e.length, r = t.length, i = Math.max(n, r), a = [], o = [];
|
|
75708
76052
|
for (let s = 0; s < i; s++) a.push(e[Math.floor(s * n / i)]), o.push(t[Math.floor(s * r / i)]);
|
|
75709
76053
|
return [a, o];
|
|
75710
76054
|
}
|
|
75711
|
-
function
|
|
76055
|
+
function hz(e, t) {
|
|
75712
76056
|
let n = e.length;
|
|
75713
76057
|
if (n > t) throw Error("Trying to stretch array to a length shorter than its own");
|
|
75714
76058
|
let r = [];
|
|
75715
76059
|
for (let i = 0; i < t; i++) r.push(e[Math.floor(i / t * n)]);
|
|
75716
76060
|
return r;
|
|
75717
76061
|
}
|
|
75718
|
-
function*
|
|
76062
|
+
function* gz(...e) {
|
|
75719
76063
|
let t = /* @__PURE__ */ new Set();
|
|
75720
76064
|
for (let n of e) for (let e of n) t.has(e) || (t.add(e), yield e);
|
|
75721
76065
|
}
|
|
75722
|
-
function
|
|
76066
|
+
function _z(e) {
|
|
75723
76067
|
let t = [[]];
|
|
75724
76068
|
for (let n of e) {
|
|
75725
76069
|
let e = t.length;
|
|
@@ -75727,82 +76071,82 @@ function $R(e) {
|
|
|
75727
76071
|
}
|
|
75728
76072
|
return t;
|
|
75729
76073
|
}
|
|
75730
|
-
function
|
|
76074
|
+
function vz(e, t) {
|
|
75731
76075
|
for (let n of e) if (!(n instanceof t)) return !1;
|
|
75732
76076
|
return !0;
|
|
75733
76077
|
}
|
|
75734
|
-
function
|
|
76078
|
+
function yz(...e) {
|
|
75735
76079
|
let t = [];
|
|
75736
76080
|
for (let n of e) for (let e of n) t.push(e);
|
|
75737
76081
|
return t;
|
|
75738
76082
|
}
|
|
75739
|
-
function
|
|
76083
|
+
function bz(e) {
|
|
75740
76084
|
return typeof e == "string" ? [e] : typeof e == "object" && e && Symbol.iterator in e ? [...e] : [e];
|
|
75741
76085
|
}
|
|
75742
|
-
function
|
|
76086
|
+
function xz(e) {
|
|
75743
76087
|
let t = [];
|
|
75744
76088
|
for (let n of e) n && t.push(n);
|
|
75745
76089
|
return t;
|
|
75746
76090
|
}
|
|
75747
|
-
function
|
|
76091
|
+
function Sz(e, t) {
|
|
75748
76092
|
let n = Math.max(e.length, t.length), r = [], i = [];
|
|
75749
76093
|
for (let a = 0; a < n; a++) r.push(e[a % e.length]), i.push(t[a % t.length]);
|
|
75750
76094
|
return [r, i];
|
|
75751
76095
|
}
|
|
75752
|
-
function
|
|
75753
|
-
return
|
|
76096
|
+
function Cz(e) {
|
|
76097
|
+
return Tz(wz(e));
|
|
75754
76098
|
}
|
|
75755
|
-
function
|
|
76099
|
+
function wz(e) {
|
|
75756
76100
|
if (e === null) return "null";
|
|
75757
76101
|
if (e === void 0) return "undefined";
|
|
75758
76102
|
let t = typeof e;
|
|
75759
76103
|
if (t === "string") return `s:${e}`;
|
|
75760
76104
|
if (t === "number" || t === "boolean" || t === "bigint") return `${t[0]}:${String(e)}`;
|
|
75761
|
-
if (e instanceof Set) return `set:[${[...e].map(
|
|
75762
|
-
if (e instanceof Map) return `map:{${[...e.entries()].map(([e, t]) => `${
|
|
75763
|
-
if (Array.isArray(e)) return `arr:[${e.map(
|
|
76105
|
+
if (e instanceof Set) return `set:[${[...e].map(wz).sort().join(",")}]`;
|
|
76106
|
+
if (e instanceof Map) return `map:{${[...e.entries()].map(([e, t]) => `${wz(e)}=${wz(t)}`).sort().join(",")}}`;
|
|
76107
|
+
if (Array.isArray(e)) return `arr:[${e.map(wz).join(",")}]`;
|
|
75764
76108
|
if (t === "object") {
|
|
75765
76109
|
let t = e;
|
|
75766
|
-
return `obj:{${Object.keys(t).sort().map((e) => `${e}=${
|
|
76110
|
+
return `obj:{${Object.keys(t).sort().map((e) => `${e}=${wz(t[e])}`).join(",")}}`;
|
|
75767
76111
|
}
|
|
75768
76112
|
return `${t}:${String(e)}`;
|
|
75769
76113
|
}
|
|
75770
|
-
function
|
|
76114
|
+
function Tz(e) {
|
|
75771
76115
|
let t = 2166136261;
|
|
75772
76116
|
for (let n = 0; n < e.length; n++) t ^= e.charCodeAt(n), t = Math.imul(t, 16777619);
|
|
75773
76117
|
return t >>> 0;
|
|
75774
76118
|
}
|
|
75775
76119
|
//#endregion
|
|
75776
76120
|
//#region src/utils/unit.ts
|
|
75777
|
-
function
|
|
76121
|
+
function Ez(e) {
|
|
75778
76122
|
return e * dd / pd;
|
|
75779
76123
|
}
|
|
75780
|
-
function
|
|
76124
|
+
function Dz(e) {
|
|
75781
76125
|
return e * Math.PI / 180;
|
|
75782
76126
|
}
|
|
75783
|
-
function
|
|
76127
|
+
function Oz(e) {
|
|
75784
76128
|
return e;
|
|
75785
76129
|
}
|
|
75786
|
-
function
|
|
76130
|
+
function kz(e, t) {
|
|
75787
76131
|
return e[0] === t[0] && e[1] === t[1] && e[2] === t[2];
|
|
75788
76132
|
}
|
|
75789
|
-
function
|
|
76133
|
+
function Az(e, t) {
|
|
75790
76134
|
let n;
|
|
75791
|
-
if (
|
|
75792
|
-
else if (
|
|
75793
|
-
else if (
|
|
76135
|
+
if (kz(e, Ad)) n = dd;
|
|
76136
|
+
else if (kz(e, Dd)) n = 8;
|
|
76137
|
+
else if (kz(e, jd)) throw Error("length of Z axis is undefined");
|
|
75794
76138
|
else throw Error("Percent axis must be the X axis (RIGHT) or Y axis (UP)");
|
|
75795
76139
|
return t / 100 * n;
|
|
75796
76140
|
}
|
|
75797
76141
|
//#endregion
|
|
75798
76142
|
//#region src/utils/debug.ts
|
|
75799
|
-
function
|
|
76143
|
+
function jz(e, t = !1) {
|
|
75800
76144
|
let n = [];
|
|
75801
76145
|
for (let t of e) n.push(...t.getFamily());
|
|
75802
76146
|
return t ? n.filter((e) => e instanceof V && e.hasOwnPoints()) : n;
|
|
75803
76147
|
}
|
|
75804
|
-
function
|
|
75805
|
-
let n = [], r = new Set(
|
|
76148
|
+
function Mz(e, t) {
|
|
76149
|
+
let n = [], r = new Set(jz(t)), i = (e, t) => {
|
|
75806
76150
|
for (let r of e) {
|
|
75807
76151
|
if (t.has(r)) continue;
|
|
75808
76152
|
let e = new Set(r.getFamily().filter((e) => t.has(e)));
|
|
@@ -75811,14 +76155,14 @@ function mz(e, t) {
|
|
|
75811
76155
|
};
|
|
75812
76156
|
return i(e, r), n;
|
|
75813
76157
|
}
|
|
75814
|
-
function
|
|
76158
|
+
function Nz(e, t = {}) {
|
|
75815
76159
|
let { labelHeight: n = .15 } = t, r = new Nh();
|
|
75816
76160
|
return e.children.forEach((e, t) => {
|
|
75817
76161
|
let i = new Xk({ value: t });
|
|
75818
76162
|
i.setHeight(n), i.moveTo(e), r.add(i);
|
|
75819
76163
|
}), r;
|
|
75820
76164
|
}
|
|
75821
|
-
function
|
|
76165
|
+
function Pz(e, t = 0) {
|
|
75822
76166
|
let n = [], r = (e, t) => {
|
|
75823
76167
|
n.push(" ".repeat(t) + `${e.constructor.name} ${e.id}`);
|
|
75824
76168
|
for (let n of e.children) r(n, t + 1);
|
|
@@ -75829,8 +76173,8 @@ function gz(e, t = 0) {
|
|
|
75829
76173
|
}
|
|
75830
76174
|
//#endregion
|
|
75831
76175
|
//#region src/utils/spaceOps.ts
|
|
75832
|
-
var
|
|
75833
|
-
function
|
|
76176
|
+
var Fz = 2 * Math.PI;
|
|
76177
|
+
function Iz(e) {
|
|
75834
76178
|
let t = e.length, n = e[0].length, r = [];
|
|
75835
76179
|
for (let i = 0; i < n; i++) {
|
|
75836
76180
|
let n = [];
|
|
@@ -75839,20 +76183,20 @@ function vz(e) {
|
|
|
75839
76183
|
}
|
|
75840
76184
|
return r;
|
|
75841
76185
|
}
|
|
75842
|
-
function
|
|
76186
|
+
function Lz(e, t) {
|
|
75843
76187
|
return e.map((e) => e.reduce((e, n, r) => e + n * (t[r] ?? 0), 0));
|
|
75844
76188
|
}
|
|
75845
|
-
function
|
|
76189
|
+
function Rz(e) {
|
|
75846
76190
|
return e.reduce((e, t) => e + t * t, 0);
|
|
75847
76191
|
}
|
|
75848
|
-
function
|
|
76192
|
+
function zz(e, t) {
|
|
75849
76193
|
return e[0] * t[1] - e[1] * t[0];
|
|
75850
76194
|
}
|
|
75851
|
-
function
|
|
75852
|
-
let n = Math.sqrt(
|
|
76195
|
+
function Bz(e, t) {
|
|
76196
|
+
let n = Math.sqrt(Rz(e));
|
|
75853
76197
|
return n > 0 ? e.map((e) => e / n) : t ?? e.map(() => 0);
|
|
75854
76198
|
}
|
|
75855
|
-
function
|
|
76199
|
+
function Vz(...e) {
|
|
75856
76200
|
if (e.length === 0) return [
|
|
75857
76201
|
1,
|
|
75858
76202
|
0,
|
|
@@ -75871,8 +76215,8 @@ function Cz(...e) {
|
|
|
75871
76215
|
}
|
|
75872
76216
|
return t;
|
|
75873
76217
|
}
|
|
75874
|
-
function
|
|
75875
|
-
let r = n ? t :
|
|
76218
|
+
function Hz(e, t, n = !1) {
|
|
76219
|
+
let r = n ? t : Bz(t), i = Math.sin(e / 2);
|
|
75876
76220
|
return [
|
|
75877
76221
|
Math.cos(e / 2),
|
|
75878
76222
|
i * (r[0] ?? 0),
|
|
@@ -75880,19 +76224,19 @@ function wz(e, t, n = !1) {
|
|
|
75880
76224
|
i * (r[2] ?? 0)
|
|
75881
76225
|
];
|
|
75882
76226
|
}
|
|
75883
|
-
function
|
|
75884
|
-
let t =
|
|
76227
|
+
function Uz(e) {
|
|
76228
|
+
let t = Bz(e.slice(1), [
|
|
75885
76229
|
1,
|
|
75886
76230
|
0,
|
|
75887
76231
|
0
|
|
75888
76232
|
]), n = 2 * Math.acos(e[0]);
|
|
75889
|
-
return n >
|
|
76233
|
+
return n > Fz / 2 && (n = Fz - n, t = [
|
|
75890
76234
|
-t[0],
|
|
75891
76235
|
-t[1],
|
|
75892
76236
|
-t[2]
|
|
75893
76237
|
]), [n, t];
|
|
75894
76238
|
}
|
|
75895
|
-
function
|
|
76239
|
+
function Wz(e) {
|
|
75896
76240
|
return [
|
|
75897
76241
|
e[0],
|
|
75898
76242
|
-e[1],
|
|
@@ -75900,7 +76244,7 @@ function Ez(e) {
|
|
|
75900
76244
|
-e[3]
|
|
75901
76245
|
];
|
|
75902
76246
|
}
|
|
75903
|
-
function
|
|
76247
|
+
function Gz(e, t, n = !1) {
|
|
75904
76248
|
let [r, i, a] = Zd(t), o = Math.cos(e), s = Math.sin(e), c = 1 - o, l = [
|
|
75905
76249
|
[
|
|
75906
76250
|
o + r * r * c,
|
|
@@ -75930,7 +76274,7 @@ function Dz(e, t, n = !1) {
|
|
|
75930
76274
|
]
|
|
75931
76275
|
] : l;
|
|
75932
76276
|
}
|
|
75933
|
-
function
|
|
76277
|
+
function Kz(e) {
|
|
75934
76278
|
let t = Math.cos(e), n = Math.sin(e);
|
|
75935
76279
|
return [
|
|
75936
76280
|
[
|
|
@@ -75950,23 +76294,23 @@ function Oz(e) {
|
|
|
75950
76294
|
]
|
|
75951
76295
|
];
|
|
75952
76296
|
}
|
|
75953
|
-
function
|
|
75954
|
-
return (t[0] ?? 0) === 0 && (t[1] ?? 0) === 0 ?
|
|
76297
|
+
function qz(e, t) {
|
|
76298
|
+
return (t[0] ?? 0) === 0 && (t[1] ?? 0) === 0 ? Iz(Kz(e * Math.sign(t[2] ?? 0))) : Iz(Gz(e, t));
|
|
75955
76299
|
}
|
|
75956
|
-
function
|
|
76300
|
+
function Jz(e, t, n = jd) {
|
|
75957
76301
|
if (e.length > 3) throw Error("Vector must have the correct dimensions.");
|
|
75958
76302
|
let r = e.length === 2 ? [
|
|
75959
76303
|
e[0],
|
|
75960
76304
|
e[1],
|
|
75961
76305
|
0
|
|
75962
|
-
] : e, i =
|
|
76306
|
+
] : e, i = Lz(Gz(t, n), r);
|
|
75963
76307
|
return [
|
|
75964
76308
|
i[0],
|
|
75965
76309
|
i[1],
|
|
75966
76310
|
i[2]
|
|
75967
76311
|
];
|
|
75968
76312
|
}
|
|
75969
|
-
function
|
|
76313
|
+
function Yz(e) {
|
|
75970
76314
|
let t = Zd(e), n = Zd(Yd(t, Ad)), r = Yd(n, t);
|
|
75971
76315
|
if (Xd(n) === 0) {
|
|
75972
76316
|
r = Zd(Yd(Dd, t));
|
|
@@ -75977,27 +76321,27 @@ function jz(e) {
|
|
|
75977
76321
|
-e[2]
|
|
75978
76322
|
];
|
|
75979
76323
|
}
|
|
75980
|
-
return
|
|
76324
|
+
return Iz([
|
|
75981
76325
|
r,
|
|
75982
76326
|
n,
|
|
75983
76327
|
t
|
|
75984
76328
|
]);
|
|
75985
76329
|
}
|
|
75986
|
-
function
|
|
76330
|
+
function Xz(e) {
|
|
75987
76331
|
return Math.atan2(e[1] ?? 0, e[0] ?? 0);
|
|
75988
76332
|
}
|
|
75989
|
-
function
|
|
75990
|
-
let n =
|
|
75991
|
-
return 2 * Math.atan2(Math.sqrt(
|
|
76333
|
+
function Zz(e, t) {
|
|
76334
|
+
let n = Bz(e), r = Bz(t), i = n.map((e, t) => e - r[t]), a = n.map((e, t) => e + r[t]);
|
|
76335
|
+
return 2 * Math.atan2(Math.sqrt(Rz(i)), Math.sqrt(Rz(a)));
|
|
75992
76336
|
}
|
|
75993
|
-
function
|
|
76337
|
+
function Qz(e, t, n = 1e-6) {
|
|
75994
76338
|
let r = Math.max(...e.map(Math.abs)), i = Math.max(...t.map(Math.abs)), a;
|
|
75995
76339
|
if (r === 0) {
|
|
75996
76340
|
if (i === 0) return Od;
|
|
75997
76341
|
a = t.map((e) => e / i);
|
|
75998
76342
|
} else if (i === 0) a = e.map((e) => e / r);
|
|
75999
76343
|
else {
|
|
76000
|
-
let o = e.map((e) => e / r), s = Yd(o, t.map((e) => e / i)), c = Math.sqrt(
|
|
76344
|
+
let o = e.map((e) => e / r), s = Yd(o, t.map((e) => e / i)), c = Math.sqrt(Rz(s));
|
|
76001
76345
|
if (c > n) return [
|
|
76002
76346
|
s[0] / c,
|
|
76003
76347
|
s[1] / c,
|
|
@@ -76010,43 +76354,43 @@ function Pz(e, t, n = 1e-6) {
|
|
|
76010
76354
|
-a[0] * a[2],
|
|
76011
76355
|
-a[1] * a[2],
|
|
76012
76356
|
a[0] * a[0] + a[1] * a[1]
|
|
76013
|
-
], s = Math.sqrt(
|
|
76357
|
+
], s = Math.sqrt(Rz(o));
|
|
76014
76358
|
return [
|
|
76015
76359
|
o[0] / s,
|
|
76016
76360
|
o[1] / s,
|
|
76017
76361
|
o[2] / s
|
|
76018
76362
|
];
|
|
76019
76363
|
}
|
|
76020
|
-
function
|
|
76021
|
-
let n =
|
|
76022
|
-
for (let i = 0; i < e; i++) r.push(
|
|
76364
|
+
function $z(e = 4, t = Ad) {
|
|
76365
|
+
let n = Fz / e, r = [];
|
|
76366
|
+
for (let i = 0; i < e; i++) r.push(Jz(t, i * n));
|
|
76023
76367
|
return r;
|
|
76024
76368
|
}
|
|
76025
|
-
function
|
|
76026
|
-
let n = t.radius ?? 1, r = t.startAngle ?? (e % 2 == 0 ? 0 :
|
|
76027
|
-
return [
|
|
76369
|
+
function eB(e, t = {}) {
|
|
76370
|
+
let n = t.radius ?? 1, r = t.startAngle ?? (e % 2 == 0 ? 0 : Fz / 4);
|
|
76371
|
+
return [$z(e, Jz([
|
|
76028
76372
|
n,
|
|
76029
76373
|
0,
|
|
76030
76374
|
0
|
|
76031
76375
|
], r)), r];
|
|
76032
76376
|
}
|
|
76033
|
-
function
|
|
76377
|
+
function tB(e) {
|
|
76034
76378
|
return [
|
|
76035
76379
|
e.re,
|
|
76036
76380
|
e.im,
|
|
76037
76381
|
0
|
|
76038
76382
|
];
|
|
76039
76383
|
}
|
|
76040
|
-
function
|
|
76384
|
+
function nB(e) {
|
|
76041
76385
|
return {
|
|
76042
76386
|
re: e[0] ?? 0,
|
|
76043
76387
|
im: e[1] ?? 0
|
|
76044
76388
|
};
|
|
76045
76389
|
}
|
|
76046
|
-
function
|
|
76047
|
-
return (t) =>
|
|
76390
|
+
function rB(e) {
|
|
76391
|
+
return (t) => tB(e(nB(t)));
|
|
76048
76392
|
}
|
|
76049
|
-
function
|
|
76393
|
+
function iB(e) {
|
|
76050
76394
|
let t = [
|
|
76051
76395
|
0,
|
|
76052
76396
|
0,
|
|
@@ -76060,10 +76404,10 @@ function Bz(e) {
|
|
|
76060
76404
|
t[2] / n
|
|
76061
76405
|
];
|
|
76062
76406
|
}
|
|
76063
|
-
function
|
|
76064
|
-
return
|
|
76407
|
+
function aB(e, t) {
|
|
76408
|
+
return iB([e, t]);
|
|
76065
76409
|
}
|
|
76066
|
-
function
|
|
76410
|
+
function oB(e, t) {
|
|
76067
76411
|
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.");
|
|
76068
76412
|
let n = (e) => Yd([
|
|
76069
76413
|
e[0][0],
|
|
@@ -76081,7 +76425,7 @@ function Hz(e, t) {
|
|
|
76081
76425
|
0
|
|
76082
76426
|
];
|
|
76083
76427
|
}
|
|
76084
|
-
function
|
|
76428
|
+
function sB(e, t, n, r, i = 1e-5) {
|
|
76085
76429
|
let a = [];
|
|
76086
76430
|
for (let o = 0; o < e.length; o++) {
|
|
76087
76431
|
let s = e[o], c = t[o], l = n[o], u = r[o], d = Yd(u, Yd(c, u)), f = c[0] * d[0] + c[1] * d[1] + c[2] * d[2], p = Math.max(f, i), m = [
|
|
@@ -76097,15 +76441,15 @@ function Uz(e, t, n, r, i = 1e-5) {
|
|
|
76097
76441
|
}
|
|
76098
76442
|
return a;
|
|
76099
76443
|
}
|
|
76100
|
-
function
|
|
76444
|
+
function cB(e) {
|
|
76101
76445
|
let t = 0;
|
|
76102
76446
|
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;
|
|
76103
76447
|
return t;
|
|
76104
76448
|
}
|
|
76105
|
-
function
|
|
76106
|
-
return
|
|
76449
|
+
function lB(e) {
|
|
76450
|
+
return cB(e) > 0 ? "CW" : "CCW";
|
|
76107
76451
|
}
|
|
76108
|
-
function
|
|
76452
|
+
function uB(e) {
|
|
76109
76453
|
let t = Xd(e);
|
|
76110
76454
|
if (t === 0) return [
|
|
76111
76455
|
0,
|
|
@@ -76119,7 +76463,7 @@ function Kz(e) {
|
|
|
76119
76463
|
n
|
|
76120
76464
|
];
|
|
76121
76465
|
}
|
|
76122
|
-
function
|
|
76466
|
+
function dB(e) {
|
|
76123
76467
|
let [t, n, r] = e;
|
|
76124
76468
|
return [
|
|
76125
76469
|
t * Math.cos(n) * Math.sin(r),
|
|
@@ -76127,12 +76471,12 @@ function qz(e) {
|
|
|
76127
76471
|
t * Math.cos(r)
|
|
76128
76472
|
];
|
|
76129
76473
|
}
|
|
76130
|
-
function
|
|
76474
|
+
function fB(e, t = jd) {
|
|
76131
76475
|
let n = e[0], r = e[1], i = Yd([
|
|
76132
76476
|
n[0] - r[0],
|
|
76133
76477
|
n[1] - r[1],
|
|
76134
76478
|
n[2] - r[2]
|
|
76135
|
-
], t), a =
|
|
76479
|
+
], t), a = aB(n, r);
|
|
76136
76480
|
return [[
|
|
76137
76481
|
a[0] + i[0],
|
|
76138
76482
|
a[1] + i[1],
|
|
@@ -76143,7 +76487,7 @@ function Jz(e, t = jd) {
|
|
|
76143
76487
|
a[2] - i[2]
|
|
76144
76488
|
]];
|
|
76145
76489
|
}
|
|
76146
|
-
function
|
|
76490
|
+
function pB(e, t = 2) {
|
|
76147
76491
|
let n = [];
|
|
76148
76492
|
for (let r = 0; r < e; r++) {
|
|
76149
76493
|
let i = [];
|
|
@@ -76152,41 +76496,41 @@ function Yz(e, t = 2) {
|
|
|
76152
76496
|
}
|
|
76153
76497
|
return n;
|
|
76154
76498
|
}
|
|
76155
|
-
function
|
|
76499
|
+
function mB(e) {
|
|
76156
76500
|
let t = 0;
|
|
76157
|
-
for (let [n, r] of
|
|
76158
|
-
let e = ((
|
|
76501
|
+
for (let [n, r] of lz(e)) {
|
|
76502
|
+
let e = ((Xz(r) - Xz(n) + Math.PI) % Fz + Fz) % Fz - Math.PI;
|
|
76159
76503
|
t += e;
|
|
76160
76504
|
}
|
|
76161
|
-
return t /
|
|
76505
|
+
return t / Fz;
|
|
76162
76506
|
}
|
|
76163
76507
|
//#endregion
|
|
76164
76508
|
//#region src/utils/paths.ts
|
|
76165
|
-
var
|
|
76166
|
-
function
|
|
76509
|
+
var hB = .01;
|
|
76510
|
+
function gB(e, t, n) {
|
|
76167
76511
|
return e.map((e, r) => e.map((e, i) => e + n * (t[r][i] - e)));
|
|
76168
76512
|
}
|
|
76169
|
-
function
|
|
76513
|
+
function _B(e, t) {
|
|
76170
76514
|
return t.map((t) => t.reduce((t, n, r) => t + n * e[r], 0));
|
|
76171
76515
|
}
|
|
76172
|
-
function
|
|
76173
|
-
return
|
|
76516
|
+
function vB() {
|
|
76517
|
+
return gB;
|
|
76174
76518
|
}
|
|
76175
|
-
function
|
|
76176
|
-
let r =
|
|
76519
|
+
function yB(e, t, n = jd) {
|
|
76520
|
+
let r = Bz(n, jd), i = (e) => t[e] ?? t[0];
|
|
76177
76521
|
return (t, n, a) => {
|
|
76178
|
-
let o =
|
|
76522
|
+
let o = Gz(-e, r), s = Gz(a * e, r);
|
|
76179
76523
|
return t.map((e, t) => {
|
|
76180
|
-
let r = i(t), c =
|
|
76181
|
-
return
|
|
76524
|
+
let r = i(t), c = _B(n[t].map((e, t) => e - r[t]), o).map((e, t) => e + r[t]);
|
|
76525
|
+
return _B(e.map((e, t) => e + a * (c[t] - e)).map((e, t) => e - r[t]), s).map((e, t) => e + r[t]);
|
|
76182
76526
|
});
|
|
76183
76527
|
};
|
|
76184
76528
|
}
|
|
76185
|
-
function
|
|
76186
|
-
if (Math.abs(e) <
|
|
76187
|
-
let n =
|
|
76529
|
+
function bB(e, t = jd) {
|
|
76530
|
+
if (Math.abs(e) < hB) return vB();
|
|
76531
|
+
let n = Bz(t, jd);
|
|
76188
76532
|
return (t, r, i) => {
|
|
76189
|
-
let a =
|
|
76533
|
+
let a = Gz(i * e, n);
|
|
76190
76534
|
return t.map((t, i) => {
|
|
76191
76535
|
let o = r[i].map((e, n) => e - t[n]), s = t.map((e, t) => e + .5 * o[t]);
|
|
76192
76536
|
if (e !== Math.PI) {
|
|
@@ -76197,19 +76541,19 @@ function nB(e, t = jd) {
|
|
|
76197
76541
|
], i = 1 / Math.tan(e / 2);
|
|
76198
76542
|
for (let e = 0; e < s.length; e++) s[e] += r[e] * i;
|
|
76199
76543
|
}
|
|
76200
|
-
return
|
|
76544
|
+
return _B(t.map((e, t) => e - s[t]), a).map((e, t) => e + s[t]);
|
|
76201
76545
|
});
|
|
76202
76546
|
};
|
|
76203
76547
|
}
|
|
76204
|
-
function
|
|
76205
|
-
return
|
|
76548
|
+
function xB() {
|
|
76549
|
+
return bB(-Math.PI);
|
|
76206
76550
|
}
|
|
76207
|
-
function
|
|
76208
|
-
return
|
|
76551
|
+
function SB() {
|
|
76552
|
+
return bB(Math.PI);
|
|
76209
76553
|
}
|
|
76210
76554
|
//#endregion
|
|
76211
76555
|
//#region src/utils/simpleFunctions.ts
|
|
76212
|
-
function
|
|
76556
|
+
function CB(e, t, n, r, i = 1e-4) {
|
|
76213
76557
|
let a = n, o = r, s = (a + o) / 2;
|
|
76214
76558
|
for (; Math.abs(o - a) > i;) {
|
|
76215
76559
|
s = (a + o) / 2;
|
|
@@ -76222,7 +76566,7 @@ function aB(e, t, n, r, i = 1e-4) {
|
|
|
76222
76566
|
}
|
|
76223
76567
|
return s;
|
|
76224
76568
|
}
|
|
76225
|
-
function
|
|
76569
|
+
function wB(e, t) {
|
|
76226
76570
|
if (t < 0 || t > e) return 0;
|
|
76227
76571
|
let n = t;
|
|
76228
76572
|
n > e - n && (n = e - n);
|
|
@@ -76230,30 +76574,30 @@ function oB(e, t) {
|
|
|
76230
76574
|
for (let t = 0; t < n; t++) r = r * (e - t) / (t + 1);
|
|
76231
76575
|
return Math.round(r);
|
|
76232
76576
|
}
|
|
76233
|
-
function
|
|
76577
|
+
function TB(e, t, n) {
|
|
76234
76578
|
return e < t ? t : e > n ? n : e;
|
|
76235
76579
|
}
|
|
76236
|
-
function
|
|
76580
|
+
function EB(e) {
|
|
76237
76581
|
return 1 / (1 + Math.exp(-e));
|
|
76238
76582
|
}
|
|
76239
76583
|
//#endregion
|
|
76240
76584
|
//#region src/utils/bezier.ts
|
|
76241
|
-
function
|
|
76585
|
+
function DB(e, t, n) {
|
|
76242
76586
|
if (Array.isArray(e) && Array.isArray(t)) return e.map((e, r) => (1 - n) * e + n * t[r]);
|
|
76243
76587
|
if (typeof e == "number" && typeof t == "number") return (1 - n) * e + n * t;
|
|
76244
76588
|
throw Error("interpolate: start and end must both be numbers or both be arrays");
|
|
76245
76589
|
}
|
|
76246
|
-
function
|
|
76590
|
+
function OB(e, t) {
|
|
76247
76591
|
if (Array.isArray(e) && Array.isArray(t)) return e.map((e, n) => (e + t[n]) / 2);
|
|
76248
76592
|
if (typeof e == "number" && typeof t == "number") return (e + t) / 2;
|
|
76249
76593
|
throw Error("mid: start and end must both be numbers or both be arrays");
|
|
76250
76594
|
}
|
|
76251
|
-
function
|
|
76595
|
+
function kB(e, t, n) {
|
|
76252
76596
|
if (Array.isArray(e) && Array.isArray(t) && Array.isArray(n)) return e.map((e, r) => (n[r] - e) / (t[r] - e));
|
|
76253
76597
|
if (typeof e == "number" && typeof t == "number" && typeof n == "number") return (n - e) / (t - e);
|
|
76254
76598
|
throw Error("inverse_interpolate: start, end and value must all be numbers or all be arrays");
|
|
76255
76599
|
}
|
|
76256
|
-
function
|
|
76600
|
+
function AB(e, t, n, r, i) {
|
|
76257
76601
|
let a = r - n;
|
|
76258
76602
|
if (Array.isArray(i)) return i.map((r) => {
|
|
76259
76603
|
let i = (r - n) / a;
|
|
@@ -76262,7 +76606,7 @@ function fB(e, t, n, r, i) {
|
|
|
76262
76606
|
let o = (i - n) / a;
|
|
76263
76607
|
return (1 - o) * e + o * t;
|
|
76264
76608
|
}
|
|
76265
|
-
function
|
|
76609
|
+
function jB(e, t) {
|
|
76266
76610
|
if (e.length === 0) return 0;
|
|
76267
76611
|
let n = e.slice();
|
|
76268
76612
|
for (; n.length > 1;) {
|
|
@@ -76272,7 +76616,7 @@ function pB(e, t) {
|
|
|
76272
76616
|
}
|
|
76273
76617
|
return n[0];
|
|
76274
76618
|
}
|
|
76275
|
-
function
|
|
76619
|
+
function MB(e, t) {
|
|
76276
76620
|
if (e.length === 0) return [];
|
|
76277
76621
|
let n = e.map((e) => e.slice());
|
|
76278
76622
|
for (; n.length > 1;) {
|
|
@@ -76282,15 +76626,15 @@ function mB(e, t) {
|
|
|
76282
76626
|
}
|
|
76283
76627
|
return n[0];
|
|
76284
76628
|
}
|
|
76285
|
-
function
|
|
76629
|
+
function NB(e) {
|
|
76286
76630
|
if (e.length > 0 && Array.isArray(e[0])) {
|
|
76287
76631
|
let t = e.filter((e) => Array.isArray(e));
|
|
76288
|
-
return (e) =>
|
|
76632
|
+
return (e) => MB(t, e);
|
|
76289
76633
|
}
|
|
76290
76634
|
let t = e.filter((e) => typeof e == "number");
|
|
76291
|
-
return (e) =>
|
|
76635
|
+
return (e) => jB(t, e);
|
|
76292
76636
|
}
|
|
76293
|
-
function
|
|
76637
|
+
function PB(e, t) {
|
|
76294
76638
|
let n = e.length, r = e.map((e) => e.slice()), i = Array(n);
|
|
76295
76639
|
i[0] = e[0].slice();
|
|
76296
76640
|
for (let e = 1; e < n; e++) {
|
|
@@ -76299,7 +76643,7 @@ function gB(e, t) {
|
|
|
76299
76643
|
}
|
|
76300
76644
|
return [...i, ...r];
|
|
76301
76645
|
}
|
|
76302
|
-
function
|
|
76646
|
+
function FB(e, t) {
|
|
76303
76647
|
if (t <= 1) return e.map((e) => e.slice());
|
|
76304
76648
|
let n = [];
|
|
76305
76649
|
for (let r = 0; r < t; r++) {
|
|
@@ -76308,7 +76652,7 @@ function _B(e, t) {
|
|
|
76308
76652
|
}
|
|
76309
76653
|
return n;
|
|
76310
76654
|
}
|
|
76311
|
-
function
|
|
76655
|
+
function IB(e, t) {
|
|
76312
76656
|
let n = e.length;
|
|
76313
76657
|
if (n === 0) return [];
|
|
76314
76658
|
let r = e[0].length, i = [];
|
|
@@ -76319,12 +76663,12 @@ function vB(e, t) {
|
|
|
76319
76663
|
for (let t = 0; t < n; t++) {
|
|
76320
76664
|
let n = a[t];
|
|
76321
76665
|
if (n <= 0) continue;
|
|
76322
|
-
let i =
|
|
76666
|
+
let i = FB(e[t], n);
|
|
76323
76667
|
for (let e = 0; e < n; e++) o.push(i.slice(e * r, e * r + r));
|
|
76324
76668
|
}
|
|
76325
76669
|
return o;
|
|
76326
76670
|
}
|
|
76327
|
-
function
|
|
76671
|
+
function LB(e) {
|
|
76328
76672
|
let t = e[0], n = e[e.length - 1];
|
|
76329
76673
|
for (let e = 0; e < 3; e++) {
|
|
76330
76674
|
let r = t[e] ?? 0, i = n[e] ?? 0, a = 1e-8 + 1e-5 * Math.abs(r);
|
|
@@ -76332,43 +76676,43 @@ function yB(e) {
|
|
|
76332
76676
|
}
|
|
76333
76677
|
return !0;
|
|
76334
76678
|
}
|
|
76335
|
-
function
|
|
76679
|
+
function RB(e, t) {
|
|
76336
76680
|
return {
|
|
76337
76681
|
re: e.re + t.re,
|
|
76338
76682
|
im: e.im + t.im
|
|
76339
76683
|
};
|
|
76340
76684
|
}
|
|
76341
|
-
function
|
|
76685
|
+
function zB(e, t) {
|
|
76342
76686
|
return {
|
|
76343
76687
|
re: e.re - t.re,
|
|
76344
76688
|
im: e.im - t.im
|
|
76345
76689
|
};
|
|
76346
76690
|
}
|
|
76347
|
-
function
|
|
76691
|
+
function BB(e, t) {
|
|
76348
76692
|
return {
|
|
76349
76693
|
re: e.re * t.re - e.im * t.im,
|
|
76350
76694
|
im: e.re * t.im + e.im * t.re
|
|
76351
76695
|
};
|
|
76352
76696
|
}
|
|
76353
|
-
function
|
|
76697
|
+
function VB(e, t) {
|
|
76354
76698
|
let n = t.re * t.re + t.im * t.im;
|
|
76355
76699
|
return {
|
|
76356
76700
|
re: (e.re * t.re + e.im * t.im) / n,
|
|
76357
76701
|
im: (e.im * t.re - e.re * t.im) / n
|
|
76358
76702
|
};
|
|
76359
76703
|
}
|
|
76360
|
-
function
|
|
76704
|
+
function HB(e, t) {
|
|
76361
76705
|
let n = {
|
|
76362
76706
|
re: e[e.length - 1],
|
|
76363
76707
|
im: 0
|
|
76364
76708
|
};
|
|
76365
|
-
for (let r = e.length - 2; r >= 0; r--) n =
|
|
76709
|
+
for (let r = e.length - 2; r >= 0; r--) n = RB(BB(n, t), {
|
|
76366
76710
|
re: e[r],
|
|
76367
76711
|
im: 0
|
|
76368
76712
|
});
|
|
76369
76713
|
return n;
|
|
76370
76714
|
}
|
|
76371
|
-
function
|
|
76715
|
+
function UB(e) {
|
|
76372
76716
|
let t = e.slice();
|
|
76373
76717
|
for (; t.length > 1 && Math.abs(t[t.length - 1]) < 1e-14;) t.pop();
|
|
76374
76718
|
let n = t.length - 1;
|
|
@@ -76383,17 +76727,17 @@ function TB(e) {
|
|
|
76383
76727
|
for (let e = 0; e < n; e++) a.push({
|
|
76384
76728
|
re: s.re,
|
|
76385
76729
|
im: s.im
|
|
76386
|
-
}), s =
|
|
76730
|
+
}), s = BB(s, o);
|
|
76387
76731
|
for (let e = 0; e < 200; e++) {
|
|
76388
76732
|
let e = 0;
|
|
76389
76733
|
for (let t = 0; t < n; t++) {
|
|
76390
|
-
let r =
|
|
76734
|
+
let r = HB(i, a[t]), o = {
|
|
76391
76735
|
re: 1,
|
|
76392
76736
|
im: 0
|
|
76393
76737
|
};
|
|
76394
|
-
for (let e = 0; e < n; e++) e !== t && (o =
|
|
76395
|
-
let s =
|
|
76396
|
-
a[t] =
|
|
76738
|
+
for (let e = 0; e < n; e++) e !== t && (o = BB(o, zB(a[t], a[e])));
|
|
76739
|
+
let s = VB(r, o);
|
|
76740
|
+
a[t] = zB(a[t], s);
|
|
76397
76741
|
let c = Math.hypot(s.re, s.im);
|
|
76398
76742
|
c > e && (e = c);
|
|
76399
76743
|
}
|
|
@@ -76401,98 +76745,98 @@ function TB(e) {
|
|
|
76401
76745
|
}
|
|
76402
76746
|
return a;
|
|
76403
76747
|
}
|
|
76404
|
-
function
|
|
76748
|
+
function WB(e, t) {
|
|
76405
76749
|
if (t < 0 || t > e) return 0;
|
|
76406
76750
|
let n = 1;
|
|
76407
76751
|
for (let r = 0; r < t; r++) n = n * (e - r) / (r + 1);
|
|
76408
76752
|
return Math.round(n);
|
|
76409
76753
|
}
|
|
76410
|
-
function
|
|
76754
|
+
function GB(e, t) {
|
|
76411
76755
|
let n = 10 ** t;
|
|
76412
76756
|
return Math.round(e * n) / n;
|
|
76413
76757
|
}
|
|
76414
|
-
function
|
|
76758
|
+
function KB(e, t, n) {
|
|
76415
76759
|
let r = .5 * 10 ** -n, i = [];
|
|
76416
76760
|
for (let n of e) t.some((e) => Math.abs(n - e) <= r) && !i.some((e) => Math.abs(n - e) <= r) && i.push(n);
|
|
76417
76761
|
return i;
|
|
76418
76762
|
}
|
|
76419
|
-
function
|
|
76763
|
+
function qB(e, t, n = 1e-6) {
|
|
76420
76764
|
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");
|
|
76421
76765
|
let r = t.length - 1, i = Math.round(Math.log10(1 / n)), a = [];
|
|
76422
76766
|
for (let n = 0; n < e.length; n++) {
|
|
76423
76767
|
let o = e[n], s = t.map((e) => e[n]), c = [];
|
|
76424
76768
|
for (let e = r; e >= 0; e--) {
|
|
76425
|
-
let t =
|
|
76769
|
+
let t = WB(r, e), n = 1, i = 0;
|
|
76426
76770
|
for (let t = e; t >= 0; t--) {
|
|
76427
|
-
let r =
|
|
76771
|
+
let r = WB(e, t) * n * s[t];
|
|
76428
76772
|
e === 0 && (r -= o), i += r, n *= -1;
|
|
76429
76773
|
}
|
|
76430
76774
|
c.push(t * i);
|
|
76431
76775
|
}
|
|
76432
76776
|
if (c.every((e) => e === 0)) continue;
|
|
76433
|
-
let l =
|
|
76777
|
+
let l = UB(c.slice().reverse()).filter((e) => Math.abs(e.im) < 1e-9).map((e) => GB(e.re, i));
|
|
76434
76778
|
a.push(l);
|
|
76435
76779
|
}
|
|
76436
76780
|
if (a.length === 0) return [];
|
|
76437
76781
|
let o = a[0];
|
|
76438
|
-
for (let e = 1; e < a.length; e++) o =
|
|
76782
|
+
for (let e = 1; e < a.length; e++) o = KB(o, a[e], i);
|
|
76439
76783
|
return o.filter((e) => e >= 0 && e <= 1);
|
|
76440
76784
|
}
|
|
76441
|
-
function
|
|
76442
|
-
return
|
|
76785
|
+
function JB(e, t, n = 1e-6) {
|
|
76786
|
+
return qB(e, t, n).length > 0;
|
|
76443
76787
|
}
|
|
76444
76788
|
//#endregion
|
|
76445
76789
|
//#region src/mobjects/three-d/threeDVmobUtils.ts
|
|
76446
|
-
function
|
|
76790
|
+
function YB(e) {
|
|
76447
76791
|
return [
|
|
76448
76792
|
e[0],
|
|
76449
76793
|
e[1],
|
|
76450
76794
|
e[2]
|
|
76451
76795
|
];
|
|
76452
76796
|
}
|
|
76453
|
-
function
|
|
76797
|
+
function XB(e) {
|
|
76454
76798
|
return e.filter((e, t) => t % 3 == 0);
|
|
76455
76799
|
}
|
|
76456
|
-
function
|
|
76457
|
-
return [
|
|
76800
|
+
function ZB(e) {
|
|
76801
|
+
return [eV(e), tV(e)];
|
|
76458
76802
|
}
|
|
76459
|
-
function
|
|
76803
|
+
function QB(e) {
|
|
76460
76804
|
return 0;
|
|
76461
76805
|
}
|
|
76462
|
-
function
|
|
76806
|
+
function $B(e) {
|
|
76463
76807
|
return Math.floor((e.getPoints().length - 1) / 6) * 3;
|
|
76464
76808
|
}
|
|
76465
|
-
function
|
|
76809
|
+
function eV(e) {
|
|
76466
76810
|
let t = e.getPoints();
|
|
76467
|
-
return t.length === 0 ? [...Nd] :
|
|
76811
|
+
return t.length === 0 ? [...Nd] : YB(t[QB(e)]);
|
|
76468
76812
|
}
|
|
76469
|
-
function
|
|
76813
|
+
function tV(e) {
|
|
76470
76814
|
let t = e.getPoints();
|
|
76471
|
-
return t.length === 0 ? [...Nd] :
|
|
76815
|
+
return t.length === 0 ? [...Nd] : YB(t[$B(e)]);
|
|
76472
76816
|
}
|
|
76473
|
-
function
|
|
76817
|
+
function nV(e, t) {
|
|
76474
76818
|
let n = e.getPoints(), r = n.length;
|
|
76475
|
-
if (
|
|
76476
|
-
let i = t, a = i > 2 ? i - 3 : r - 4, o =
|
|
76819
|
+
if (XB(n).length <= 2) return [...Dd];
|
|
76820
|
+
let i = t, a = i > 2 ? i - 3 : r - 4, o = Qz(n[i < r - 3 ? i + 3 : 3].map((e, t) => e - n[i][t]), n[a].map((e, t) => e - n[i][t]));
|
|
76477
76821
|
return Math.hypot(...o) === 0 ? [...Dd] : o;
|
|
76478
76822
|
}
|
|
76479
|
-
function
|
|
76480
|
-
return
|
|
76823
|
+
function rV(e) {
|
|
76824
|
+
return nV(e, QB(e));
|
|
76481
76825
|
}
|
|
76482
|
-
function
|
|
76483
|
-
return
|
|
76826
|
+
function iV(e) {
|
|
76827
|
+
return nV(e, $B(e));
|
|
76484
76828
|
}
|
|
76485
76829
|
//#endregion
|
|
76486
76830
|
//#region src/core/SpecialThreeDScene.ts
|
|
76487
|
-
var
|
|
76831
|
+
var aV = 70 * ju, oV = -110 * ju, sV = 2, cV = 48, lV = class extends AE {
|
|
76488
76832
|
cutAxesAtRadius;
|
|
76489
76833
|
_threeDAxesConfig;
|
|
76490
76834
|
_sphereConfig;
|
|
76491
76835
|
_defaultAngledCameraPosition;
|
|
76492
76836
|
constructor(e, t = {}) {
|
|
76493
76837
|
let { cutAxesAtRadius: n = !0, threeDAxesConfig: r = {}, sphereConfig: i = {}, defaultAngledCameraPosition: a = {
|
|
76494
|
-
phi:
|
|
76495
|
-
theta:
|
|
76838
|
+
phi: aV,
|
|
76839
|
+
theta: oV
|
|
76496
76840
|
}, phi: o = a.phi, theta: s = a.theta, ...c } = t;
|
|
76497
76841
|
super(e, {
|
|
76498
76842
|
...c,
|
|
@@ -76522,8 +76866,8 @@ var VB = 70 * ju, HB = -110 * ju, UB = 2, WB = 48, GB = class extends AE {
|
|
|
76522
76866
|
}
|
|
76523
76867
|
getDefaultSphereConfig() {
|
|
76524
76868
|
return {
|
|
76525
|
-
radius:
|
|
76526
|
-
resolution:
|
|
76869
|
+
radius: sV,
|
|
76870
|
+
resolution: cV
|
|
76527
76871
|
};
|
|
76528
76872
|
}
|
|
76529
76873
|
getAxes() {
|
|
@@ -76549,36 +76893,36 @@ var VB = 70 * ju, HB = -110 * ju, UB = 2, WB = 48, GB = class extends AE {
|
|
|
76549
76893
|
};
|
|
76550
76894
|
//#endregion
|
|
76551
76895
|
//#region src/mobjects/text/registerFont.ts
|
|
76552
|
-
function
|
|
76896
|
+
function uV(e, t) {
|
|
76553
76897
|
if (typeof document > "u" || typeof FontFace > "u" || document.fonts === void 0) return !1;
|
|
76554
76898
|
let n = typeof t == "string" && !/^\s*(url|local)\s*\(/i.test(t) ? `url("${t}")` : t, r = new FontFace(e, n);
|
|
76555
76899
|
return document.fonts.add(r), !0;
|
|
76556
76900
|
}
|
|
76557
76901
|
//#endregion
|
|
76558
76902
|
//#region src/integrations/webcomponent.ts
|
|
76559
|
-
var
|
|
76903
|
+
var dV = 800, fV = 450, pV = { importModule: (e) => import(
|
|
76560
76904
|
/* @vite-ignore */
|
|
76561
76905
|
e
|
|
76562
76906
|
) };
|
|
76563
|
-
function
|
|
76907
|
+
function mV(e) {
|
|
76564
76908
|
return typeof e.togglePlayPause == "function";
|
|
76565
76909
|
}
|
|
76566
|
-
function
|
|
76910
|
+
function hV(e) {
|
|
76567
76911
|
try {
|
|
76568
76912
|
e.dispose();
|
|
76569
76913
|
} catch (e) {
|
|
76570
76914
|
Gf.error("<manim-scene> failed to dispose instance:", e);
|
|
76571
76915
|
}
|
|
76572
76916
|
}
|
|
76573
|
-
function
|
|
76917
|
+
function gV(e, t) {
|
|
76574
76918
|
let n = e?.trim();
|
|
76575
76919
|
return n ? /^\d+(\.\d+)?$/.test(n) ? `${n}px` : n : `${t}px`;
|
|
76576
76920
|
}
|
|
76577
|
-
function
|
|
76921
|
+
function _V(e) {
|
|
76578
76922
|
let t = e?.trim();
|
|
76579
76923
|
return !t || !/^\d+(\.\d+)?$/.test(t) ? null : Number(t);
|
|
76580
76924
|
}
|
|
76581
|
-
var
|
|
76925
|
+
var vV = typeof HTMLElement < "u" ? HTMLElement : class {}, yV = class extends vV {
|
|
76582
76926
|
static get observedAttributes() {
|
|
76583
76927
|
return [
|
|
76584
76928
|
"width",
|
|
@@ -76624,7 +76968,7 @@ var eV = typeof HTMLElement < "u" ? HTMLElement : class {}, tV = class extends e
|
|
|
76624
76968
|
}
|
|
76625
76969
|
_applyContainerStyle() {
|
|
76626
76970
|
let e = this._container;
|
|
76627
|
-
e && (e.style.width =
|
|
76971
|
+
e && (e.style.width = gV(this.getAttribute("width"), dV), e.style.height = gV(this.getAttribute("height"), fV), e.style.position = "relative", e.style.overflow = "hidden", e.style.background = this.getAttribute("background") ?? "");
|
|
76628
76972
|
}
|
|
76629
76973
|
_mount() {
|
|
76630
76974
|
return this._mountPromise = this._doMount(), this._mountPromise;
|
|
@@ -76643,7 +76987,7 @@ var eV = typeof HTMLElement < "u" ? HTMLElement : class {}, tV = class extends e
|
|
|
76643
76987
|
return;
|
|
76644
76988
|
}
|
|
76645
76989
|
if (e !== this._loadToken) {
|
|
76646
|
-
|
|
76990
|
+
hV(r);
|
|
76647
76991
|
return;
|
|
76648
76992
|
}
|
|
76649
76993
|
this._instance = r, this._applyPlaybackOptions();
|
|
@@ -76652,7 +76996,7 @@ var eV = typeof HTMLElement < "u" ? HTMLElement : class {}, tV = class extends e
|
|
|
76652
76996
|
if (this._sceneFactory) return this._sceneFactory;
|
|
76653
76997
|
let t = this.getAttribute("src");
|
|
76654
76998
|
if (!t) return null;
|
|
76655
|
-
let n = await
|
|
76999
|
+
let n = await pV.importModule(t);
|
|
76656
77000
|
if (e !== this._loadToken) return null;
|
|
76657
77001
|
let r = n.default;
|
|
76658
77002
|
return typeof r == "function" ? r : (Gf.error(`<manim-scene> module "${t}" has no default-export factory function.`), null);
|
|
@@ -76660,19 +77004,19 @@ var eV = typeof HTMLElement < "u" ? HTMLElement : class {}, tV = class extends e
|
|
|
76660
77004
|
_applyPlaybackOptions() {
|
|
76661
77005
|
let e = this._instance;
|
|
76662
77006
|
if (!e) return;
|
|
76663
|
-
let t =
|
|
77007
|
+
let t = mV(e);
|
|
76664
77008
|
t && (e.loop = this.hasAttribute("loop")), t || this._syncSceneControls(e), this.hasAttribute("autoplay") && !e.isPlaying && (t ? e.play() : e.resume());
|
|
76665
77009
|
}
|
|
76666
77010
|
_syncSceneControls(e) {
|
|
76667
77011
|
let t = this.hasAttribute("controls");
|
|
76668
|
-
t && !this._controls ? this._controls = new
|
|
77012
|
+
t && !this._controls ? this._controls = new pL(e) : !t && this._controls && (this._controls.dispose(), this._controls = null);
|
|
76669
77013
|
}
|
|
76670
77014
|
_resizeInstance() {
|
|
76671
77015
|
let e = this._instance;
|
|
76672
77016
|
if (!e) return;
|
|
76673
|
-
let t =
|
|
77017
|
+
let t = _V(this.getAttribute("width")), n = _V(this.getAttribute("height"));
|
|
76674
77018
|
if (t === null || n === null) return;
|
|
76675
|
-
let r =
|
|
77019
|
+
let r = mV(e) ? e.scene : e;
|
|
76676
77020
|
try {
|
|
76677
77021
|
r.resize(t, n);
|
|
76678
77022
|
} catch (e) {
|
|
@@ -76688,15 +77032,546 @@ var eV = typeof HTMLElement < "u" ? HTMLElement : class {}, tV = class extends e
|
|
|
76688
77032
|
}
|
|
76689
77033
|
this._controls = null;
|
|
76690
77034
|
}
|
|
76691
|
-
this._instance &&= (
|
|
77035
|
+
this._instance &&= (hV(this._instance), null);
|
|
76692
77036
|
}
|
|
76693
77037
|
_clearContainerChildren() {
|
|
76694
77038
|
let e = this._container;
|
|
76695
77039
|
if (e) for (; e.firstChild;) e.removeChild(e.firstChild);
|
|
76696
77040
|
}
|
|
76697
77041
|
};
|
|
76698
|
-
function
|
|
76699
|
-
typeof customElements > "u" || typeof HTMLElement > "u" || customElements.get(e) || customElements.define(e,
|
|
77042
|
+
function bV(e = "manim-scene") {
|
|
77043
|
+
typeof customElements > "u" || typeof HTMLElement > "u" || customElements.get(e) || customElements.define(e, yV);
|
|
77044
|
+
}
|
|
77045
|
+
//#endregion
|
|
77046
|
+
//#region src/serialization/registry.ts
|
|
77047
|
+
var xV = /* @__PURE__ */ new Map();
|
|
77048
|
+
function SV(e, t) {
|
|
77049
|
+
xV.set(e, t);
|
|
77050
|
+
}
|
|
77051
|
+
function CV(e) {
|
|
77052
|
+
xV.delete(e);
|
|
77053
|
+
}
|
|
77054
|
+
function wV(e) {
|
|
77055
|
+
return xV.get(e);
|
|
77056
|
+
}
|
|
77057
|
+
function TV() {
|
|
77058
|
+
return [...xV.keys()].sort();
|
|
77059
|
+
}
|
|
77060
|
+
//#endregion
|
|
77061
|
+
//#region src/serialization/props.ts
|
|
77062
|
+
function EV(e, t) {
|
|
77063
|
+
return typeof e == "number" && Number.isFinite(e) ? e : t;
|
|
77064
|
+
}
|
|
77065
|
+
function DV(e, t) {
|
|
77066
|
+
return typeof e == "string" ? e : t;
|
|
77067
|
+
}
|
|
77068
|
+
function OV(e, t) {
|
|
77069
|
+
return typeof e == "boolean" ? e : t;
|
|
77070
|
+
}
|
|
77071
|
+
function kV(e) {
|
|
77072
|
+
return typeof e == "string" ? e : void 0;
|
|
77073
|
+
}
|
|
77074
|
+
function AV(e) {
|
|
77075
|
+
return Array.isArray(e) && e.length === 3 && e.every((e) => typeof e == "number" && Number.isFinite(e));
|
|
77076
|
+
}
|
|
77077
|
+
function jV(e, t) {
|
|
77078
|
+
return AV(e) ? [
|
|
77079
|
+
e[0],
|
|
77080
|
+
e[1],
|
|
77081
|
+
e[2]
|
|
77082
|
+
] : t;
|
|
77083
|
+
}
|
|
77084
|
+
function MV(e) {
|
|
77085
|
+
if (!Array.isArray(e)) return [];
|
|
77086
|
+
let t = [];
|
|
77087
|
+
for (let n of e) AV(n) && t.push([
|
|
77088
|
+
n[0],
|
|
77089
|
+
n[1],
|
|
77090
|
+
n[2]
|
|
77091
|
+
]);
|
|
77092
|
+
return t;
|
|
77093
|
+
}
|
|
77094
|
+
function NV(e) {
|
|
77095
|
+
return typeof e == "object" && !!e && !Array.isArray(e);
|
|
77096
|
+
}
|
|
77097
|
+
//#endregion
|
|
77098
|
+
//#region src/serialization/defaults.ts
|
|
77099
|
+
function PV(e) {
|
|
77100
|
+
return typeof e == "number" && Number.isFinite(e) ? e : DV(e, "normal");
|
|
77101
|
+
}
|
|
77102
|
+
function FV(e) {
|
|
77103
|
+
return e === "left" || e === "right" ? e : "center";
|
|
77104
|
+
}
|
|
77105
|
+
function IV() {
|
|
77106
|
+
SV("Circle", {
|
|
77107
|
+
serialize: (e) => {
|
|
77108
|
+
let t = e;
|
|
77109
|
+
return {
|
|
77110
|
+
radius: t._radius,
|
|
77111
|
+
numPoints: t._numPoints
|
|
77112
|
+
};
|
|
77113
|
+
},
|
|
77114
|
+
deserialize: (e) => new yD({
|
|
77115
|
+
radius: EV(e.radius, 1),
|
|
77116
|
+
numPoints: EV(e.numPoints, 64)
|
|
77117
|
+
})
|
|
77118
|
+
}), SV("Rectangle", {
|
|
77119
|
+
serialize: (e) => {
|
|
77120
|
+
let t = e;
|
|
77121
|
+
return {
|
|
77122
|
+
width: t._width,
|
|
77123
|
+
height: t._height
|
|
77124
|
+
};
|
|
77125
|
+
},
|
|
77126
|
+
deserialize: (e) => new jE({
|
|
77127
|
+
width: EV(e.width, 2),
|
|
77128
|
+
height: EV(e.height, 1)
|
|
77129
|
+
})
|
|
77130
|
+
}), SV("Square", {
|
|
77131
|
+
serialize: (e) => ({ sideLength: e._width }),
|
|
77132
|
+
deserialize: (e) => new ME({ sideLength: EV(e.sideLength, 2) })
|
|
77133
|
+
}), SV("Line", {
|
|
77134
|
+
serialize: (e) => {
|
|
77135
|
+
let t = e;
|
|
77136
|
+
return {
|
|
77137
|
+
start: [...t._start],
|
|
77138
|
+
end: [...t._end]
|
|
77139
|
+
};
|
|
77140
|
+
},
|
|
77141
|
+
deserialize: (e) => new UE({
|
|
77142
|
+
start: jV(e.start, [
|
|
77143
|
+
0,
|
|
77144
|
+
0,
|
|
77145
|
+
0
|
|
77146
|
+
]),
|
|
77147
|
+
end: jV(e.end, [
|
|
77148
|
+
1,
|
|
77149
|
+
0,
|
|
77150
|
+
0
|
|
77151
|
+
])
|
|
77152
|
+
})
|
|
77153
|
+
}), SV("Dot", {
|
|
77154
|
+
serialize: (e) => ({ radius: e._radius }),
|
|
77155
|
+
deserialize: (e) => new UD({ radius: EV(e.radius, .08) })
|
|
77156
|
+
}), SV("Polygon", {
|
|
77157
|
+
serialize: (e) => ({
|
|
77158
|
+
vertices: e.getVertices().map((e) => [...e]),
|
|
77159
|
+
closed: e._closed
|
|
77160
|
+
}),
|
|
77161
|
+
deserialize: (e) => {
|
|
77162
|
+
let t = MV(e.vertices);
|
|
77163
|
+
return new bD({
|
|
77164
|
+
vertices: t.length >= 2 ? t : [[
|
|
77165
|
+
0,
|
|
77166
|
+
0,
|
|
77167
|
+
0
|
|
77168
|
+
], [
|
|
77169
|
+
1,
|
|
77170
|
+
0,
|
|
77171
|
+
0
|
|
77172
|
+
]],
|
|
77173
|
+
closed: OV(e.closed, !0)
|
|
77174
|
+
});
|
|
77175
|
+
}
|
|
77176
|
+
}), SV("Group", {
|
|
77177
|
+
serialize: () => ({}),
|
|
77178
|
+
deserialize: () => new jT()
|
|
77179
|
+
}), SV("VGroup", {
|
|
77180
|
+
serialize: () => ({}),
|
|
77181
|
+
deserialize: () => new Nh()
|
|
77182
|
+
}), SV("Text", {
|
|
77183
|
+
serialize: (e) => {
|
|
77184
|
+
let t = e;
|
|
77185
|
+
return {
|
|
77186
|
+
text: e.getText(),
|
|
77187
|
+
fontSize: e.getFontSize(),
|
|
77188
|
+
fontFamily: e.getFontFamily(),
|
|
77189
|
+
fontWeight: t._fontWeight,
|
|
77190
|
+
fontStyle: t._fontStyle,
|
|
77191
|
+
lineHeight: t._lineHeight,
|
|
77192
|
+
letterSpacing: t._letterSpacing,
|
|
77193
|
+
textAlign: t._textAlign
|
|
77194
|
+
};
|
|
77195
|
+
},
|
|
77196
|
+
deserialize: (e) => new Bw({
|
|
77197
|
+
text: DV(e.text, ""),
|
|
77198
|
+
fontSize: EV(e.fontSize, 48),
|
|
77199
|
+
fontFamily: DV(e.fontFamily, "CMU Serif, Georgia, Times New Roman, serif"),
|
|
77200
|
+
fontWeight: PV(e.fontWeight),
|
|
77201
|
+
fontStyle: DV(e.fontStyle, "normal"),
|
|
77202
|
+
lineHeight: EV(e.lineHeight, 1.2),
|
|
77203
|
+
letterSpacing: EV(e.letterSpacing, 0),
|
|
77204
|
+
textAlign: FV(e.textAlign)
|
|
77205
|
+
})
|
|
77206
|
+
}), SV("MathTex", {
|
|
77207
|
+
serialize: (e) => {
|
|
77208
|
+
let t = e;
|
|
77209
|
+
return {
|
|
77210
|
+
latex: e.getLatex(),
|
|
77211
|
+
fontSize: t._fontSize,
|
|
77212
|
+
displayMode: t._displayMode
|
|
77213
|
+
};
|
|
77214
|
+
},
|
|
77215
|
+
deserialize: (e) => new Mk({
|
|
77216
|
+
latex: DV(e.latex, ""),
|
|
77217
|
+
fontSize: EV(e.fontSize, 1),
|
|
77218
|
+
displayMode: OV(e.displayMode, !0)
|
|
77219
|
+
})
|
|
77220
|
+
});
|
|
77221
|
+
}
|
|
77222
|
+
//#endregion
|
|
77223
|
+
//#region src/serialization/types.ts
|
|
77224
|
+
var LV = "manim-web-scene", RV = {
|
|
77225
|
+
position: [
|
|
77226
|
+
0,
|
|
77227
|
+
0,
|
|
77228
|
+
0
|
|
77229
|
+
],
|
|
77230
|
+
rotation: [
|
|
77231
|
+
0,
|
|
77232
|
+
0,
|
|
77233
|
+
0
|
|
77234
|
+
],
|
|
77235
|
+
scale: [
|
|
77236
|
+
1,
|
|
77237
|
+
1,
|
|
77238
|
+
1
|
|
77239
|
+
]
|
|
77240
|
+
};
|
|
77241
|
+
function zV(e) {
|
|
77242
|
+
return {
|
|
77243
|
+
position: [
|
|
77244
|
+
e.position.x,
|
|
77245
|
+
e.position.y,
|
|
77246
|
+
e.position.z
|
|
77247
|
+
],
|
|
77248
|
+
rotation: [
|
|
77249
|
+
e.rotation.x,
|
|
77250
|
+
e.rotation.y,
|
|
77251
|
+
e.rotation.z
|
|
77252
|
+
],
|
|
77253
|
+
scale: [
|
|
77254
|
+
e.scaleVector.x,
|
|
77255
|
+
e.scaleVector.y,
|
|
77256
|
+
e.scaleVector.z
|
|
77257
|
+
]
|
|
77258
|
+
};
|
|
77259
|
+
}
|
|
77260
|
+
function BV(e) {
|
|
77261
|
+
let t = {};
|
|
77262
|
+
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;
|
|
77263
|
+
}
|
|
77264
|
+
function VV(e, t) {
|
|
77265
|
+
let n = NV(t) ? t : {}, r = jV(n.position, RV.position), i = jV(n.rotation, RV.rotation), a = jV(n.scale, RV.scale);
|
|
77266
|
+
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]);
|
|
77267
|
+
}
|
|
77268
|
+
function HV(e, t) {
|
|
77269
|
+
let n = NV(t) ? t : {};
|
|
77270
|
+
typeof n.strokeWidth == "number" && e.setStrokeWidth(n.strokeWidth), typeof n.strokeOpacity == "number" && e.setStrokeOpacity(n.strokeOpacity), typeof n.fillOpacity == "number" && e.setFillOpacity(n.fillOpacity);
|
|
77271
|
+
let r = kV(n.strokeColor), i = kV(n.fillColor);
|
|
77272
|
+
r !== void 0 && (e.color = r), r !== void 0 && (e.strokeColor = r), i !== void 0 && (e.fillColor = i);
|
|
77273
|
+
}
|
|
77274
|
+
function UV(e) {
|
|
77275
|
+
let t = e.constructor.name, n = wV(t), r = {
|
|
77276
|
+
type: t,
|
|
77277
|
+
props: n ? n.serialize(e) : {},
|
|
77278
|
+
transform: zV(e),
|
|
77279
|
+
style: BV(e),
|
|
77280
|
+
children: e.children.map(UV)
|
|
77281
|
+
};
|
|
77282
|
+
return n || (r.unknown = !0), r;
|
|
77283
|
+
}
|
|
77284
|
+
function WV(e) {
|
|
77285
|
+
if (!NV(e) || e.unknown === !0) return null;
|
|
77286
|
+
let t = kV(e.type);
|
|
77287
|
+
if (t === void 0) return null;
|
|
77288
|
+
let n = wV(t);
|
|
77289
|
+
if (!n) return null;
|
|
77290
|
+
let r = NV(e.props) ? e.props : {}, i = n.deserialize(r);
|
|
77291
|
+
if (VV(i, e.transform), HV(i, e.style), Array.isArray(e.children)) for (let t of e.children) {
|
|
77292
|
+
let e = WV(t);
|
|
77293
|
+
e && i.add(e);
|
|
77294
|
+
}
|
|
77295
|
+
return i;
|
|
77296
|
+
}
|
|
77297
|
+
function GV(e) {
|
|
77298
|
+
let t = [];
|
|
77299
|
+
for (let n of e.mobjects) t.push(UV(n));
|
|
77300
|
+
return {
|
|
77301
|
+
format: LV,
|
|
77302
|
+
version: 1,
|
|
77303
|
+
mobjects: t
|
|
77304
|
+
};
|
|
77305
|
+
}
|
|
77306
|
+
function KV(e, t) {
|
|
77307
|
+
if (!NV(e) || !Array.isArray(e.mobjects)) return [];
|
|
77308
|
+
let n = [];
|
|
77309
|
+
for (let r of e.mobjects) {
|
|
77310
|
+
let e = WV(r);
|
|
77311
|
+
e && (t.add(e), n.push(e));
|
|
77312
|
+
}
|
|
77313
|
+
return n;
|
|
77314
|
+
}
|
|
77315
|
+
//#endregion
|
|
77316
|
+
//#region src/serialization/index.ts
|
|
77317
|
+
IV();
|
|
77318
|
+
//#endregion
|
|
77319
|
+
//#region src/mobjects/geo/geojson.ts
|
|
77320
|
+
function qV(e) {
|
|
77321
|
+
if (e.type === "Polygon") {
|
|
77322
|
+
let t = e.coordinates[0];
|
|
77323
|
+
return t ? [t] : [];
|
|
77324
|
+
}
|
|
77325
|
+
let t = [];
|
|
77326
|
+
for (let n of e.coordinates) {
|
|
77327
|
+
let e = n[0];
|
|
77328
|
+
e && t.push(e);
|
|
77329
|
+
}
|
|
77330
|
+
return t;
|
|
77331
|
+
}
|
|
77332
|
+
//#endregion
|
|
77333
|
+
//#region src/mobjects/geo/projections.ts
|
|
77334
|
+
var JV = Math.PI / 180;
|
|
77335
|
+
function YV(e = {}) {
|
|
77336
|
+
let { radius: t = 1, centerLon: n = 0, centerLat: r = 0, standardParallel: i = 0 } = e, a = Math.cos(i * JV);
|
|
77337
|
+
return ([e, i]) => [(e - n) * JV * t * a, (i - r) * JV * t];
|
|
77338
|
+
}
|
|
77339
|
+
function XV(e = {}) {
|
|
77340
|
+
let { radius: t = 1, centerLon: n = 0, maxLatitude: r = 85.05112878 } = e;
|
|
77341
|
+
return ([e, i]) => {
|
|
77342
|
+
let a = Math.max(-r, Math.min(r, i)) * JV;
|
|
77343
|
+
return [(e - n) * JV * t, t * Math.log(Math.tan(Math.PI / 4 + a / 2))];
|
|
77344
|
+
};
|
|
77345
|
+
}
|
|
77346
|
+
//#endregion
|
|
77347
|
+
//#region src/mobjects/geo/colorScale.ts
|
|
77348
|
+
var ZV = ["#0d1b2a", "#4cc9f0"], QV = class {
|
|
77349
|
+
_palette;
|
|
77350
|
+
_domain;
|
|
77351
|
+
constructor(e = {}) {
|
|
77352
|
+
let { colors: t = ZV, domain: n = [0, 1], samples: r = 256 } = e, i = Math.max(2, Math.floor(r));
|
|
77353
|
+
this._palette = Sh(t.length > 0 ? t : ZV, i), this._domain = [n[0], n[1]];
|
|
77354
|
+
}
|
|
77355
|
+
setDomainFromValues(e) {
|
|
77356
|
+
let t = Infinity, n = -Infinity;
|
|
77357
|
+
for (let r of e) Number.isFinite(r) && (r < t && (t = r), r > n && (n = r));
|
|
77358
|
+
return Number.isFinite(t) && Number.isFinite(n) && (this._domain = [t, n]), this;
|
|
77359
|
+
}
|
|
77360
|
+
getDomain() {
|
|
77361
|
+
return [this._domain[0], this._domain[1]];
|
|
77362
|
+
}
|
|
77363
|
+
colorFor(e) {
|
|
77364
|
+
let [t, n] = this._domain, r = n - t, i = r === 0 || !Number.isFinite(e) ? 0 : (e - t) / r;
|
|
77365
|
+
i = Math.max(0, Math.min(1, i));
|
|
77366
|
+
let a = Math.round(i * (this._palette.length - 1));
|
|
77367
|
+
return this._palette[a];
|
|
77368
|
+
}
|
|
77369
|
+
}, $V = class extends jT {
|
|
77370
|
+
_projection;
|
|
77371
|
+
_colorScale;
|
|
77372
|
+
_regions = [];
|
|
77373
|
+
_regionColors = [];
|
|
77374
|
+
_regionPolygons = [];
|
|
77375
|
+
constructor(e) {
|
|
77376
|
+
super();
|
|
77377
|
+
let { geojson: t, value: n, colorScale: r = ["#0d1b2a", "#4cc9f0"], domain: i, fillOpacity: a = 1, noDataColor: o = Sl, borderColor: s = "#1b263b", borderWidth: c = 1, projection: l = YV() } = e;
|
|
77378
|
+
this._projection = l;
|
|
77379
|
+
let u = t.features ?? [], d = u.map((e, t) => n(e, t));
|
|
77380
|
+
this._colorScale = new QV({
|
|
77381
|
+
colors: r,
|
|
77382
|
+
domain: i
|
|
77383
|
+
}), i || this._colorScale.setDomainFromValues(d.filter((e) => typeof e == "number" && Number.isFinite(e))), u.forEach((e, t) => {
|
|
77384
|
+
this._buildRegion(e, d[t], {
|
|
77385
|
+
fillOpacity: a,
|
|
77386
|
+
noDataColor: o,
|
|
77387
|
+
borderColor: s,
|
|
77388
|
+
borderWidth: c
|
|
77389
|
+
});
|
|
77390
|
+
});
|
|
77391
|
+
}
|
|
77392
|
+
_buildRegion(e, t, n) {
|
|
77393
|
+
let r = typeof t == "number" && Number.isFinite(t) ? this._colorScale.colorFor(t) : n.noDataColor, i = qV(e.geometry), a = [];
|
|
77394
|
+
for (let e of i) {
|
|
77395
|
+
let t = this._buildPolygon(e, r, n);
|
|
77396
|
+
t && a.push(t);
|
|
77397
|
+
}
|
|
77398
|
+
let o = a.length === 1 ? a[0] : new jT(...a);
|
|
77399
|
+
this.add(o), this._regions.push(o), this._regionColors.push(r), this._regionPolygons.push(a);
|
|
77400
|
+
}
|
|
77401
|
+
_buildPolygon(e, t, n) {
|
|
77402
|
+
let r = tH(e);
|
|
77403
|
+
if (r.length < 3) return null;
|
|
77404
|
+
let i = new bD({
|
|
77405
|
+
vertices: r.map((e) => {
|
|
77406
|
+
let [t, n] = this._projection(e);
|
|
77407
|
+
return [
|
|
77408
|
+
t,
|
|
77409
|
+
n,
|
|
77410
|
+
0
|
|
77411
|
+
];
|
|
77412
|
+
}),
|
|
77413
|
+
color: n.borderColor,
|
|
77414
|
+
strokeWidth: n.borderWidth,
|
|
77415
|
+
fillOpacity: n.fillOpacity,
|
|
77416
|
+
closed: !0
|
|
77417
|
+
});
|
|
77418
|
+
return i.setFill(t, n.fillOpacity), i;
|
|
77419
|
+
}
|
|
77420
|
+
getRegions() {
|
|
77421
|
+
return [...this._regions];
|
|
77422
|
+
}
|
|
77423
|
+
getRegionCount() {
|
|
77424
|
+
return this._regions.length;
|
|
77425
|
+
}
|
|
77426
|
+
getRegionColor(e) {
|
|
77427
|
+
return this._regionColors[e];
|
|
77428
|
+
}
|
|
77429
|
+
getRegionPolygons(e) {
|
|
77430
|
+
return [...this._regionPolygons[e] ?? []];
|
|
77431
|
+
}
|
|
77432
|
+
getProjection() {
|
|
77433
|
+
return this._projection;
|
|
77434
|
+
}
|
|
77435
|
+
getColorScale() {
|
|
77436
|
+
return this._colorScale;
|
|
77437
|
+
}
|
|
77438
|
+
}, eH = $V;
|
|
77439
|
+
function tH(e) {
|
|
77440
|
+
if (e.length < 2) return e;
|
|
77441
|
+
let t = e[0], n = e[e.length - 1];
|
|
77442
|
+
return t[0] === n[0] && t[1] === n[1] ? e.slice(0, -1) : e;
|
|
77443
|
+
}
|
|
77444
|
+
//#endregion
|
|
77445
|
+
//#region src/mobjects/geo/Globe.ts
|
|
77446
|
+
var nH = Math.PI / 180, rH = class extends jT {
|
|
77447
|
+
_radius;
|
|
77448
|
+
_center;
|
|
77449
|
+
_sphere;
|
|
77450
|
+
_plottedPoints = [];
|
|
77451
|
+
constructor(e = {}) {
|
|
77452
|
+
super();
|
|
77453
|
+
let { radius: t = 1, center: n = [
|
|
77454
|
+
0,
|
|
77455
|
+
0,
|
|
77456
|
+
0
|
|
77457
|
+
], textureUrl: r, darkTextureUrl: i, color: a = "#2a6f97", opacity: o = 1, resolution: s = 64 } = e;
|
|
77458
|
+
this._radius = t, this._center = [...n], r ? this._sphere = nj({
|
|
77459
|
+
textureUrl: r,
|
|
77460
|
+
darkTextureUrl: i,
|
|
77461
|
+
radius: t,
|
|
77462
|
+
center: n,
|
|
77463
|
+
resolution: s,
|
|
77464
|
+
opacity: o
|
|
77465
|
+
}) : this._sphere = new LA({
|
|
77466
|
+
radius: t,
|
|
77467
|
+
center: n,
|
|
77468
|
+
color: a,
|
|
77469
|
+
opacity: o,
|
|
77470
|
+
resolution: s
|
|
77471
|
+
}), this.add(this._sphere);
|
|
77472
|
+
}
|
|
77473
|
+
getSphere() {
|
|
77474
|
+
return this._sphere;
|
|
77475
|
+
}
|
|
77476
|
+
getRadius() {
|
|
77477
|
+
return this._radius;
|
|
77478
|
+
}
|
|
77479
|
+
latLonToPoint(e, t) {
|
|
77480
|
+
return this._surfacePoint(e, t, this._radius);
|
|
77481
|
+
}
|
|
77482
|
+
plotPoint(e, t, n = {}) {
|
|
77483
|
+
let { size: r = this._radius * .03, color: i = "#ffd166" } = n, a = new aj({
|
|
77484
|
+
point: this.latLonToPoint(e, t),
|
|
77485
|
+
radius: r,
|
|
77486
|
+
color: i
|
|
77487
|
+
});
|
|
77488
|
+
return this.add(a), this._plottedPoints.push(a), a;
|
|
77489
|
+
}
|
|
77490
|
+
getPlottedPoints() {
|
|
77491
|
+
return [...this._plottedPoints];
|
|
77492
|
+
}
|
|
77493
|
+
arc(e, t, n = {}) {
|
|
77494
|
+
let { segments: r = 64, color: i = "#ef476f", lineWidth: a = 2, altitude: o = 0 } = n, s = this._radius * (1 + o), c = iH(e[0], e[1]), l = iH(t[0], t[1]), u = sH(c[0] * l[0] + c[1] * l[1] + c[2] * l[2], -1, 1), d = Math.acos(u), f = Math.sin(d), p = [];
|
|
77495
|
+
for (let e = 0; e <= r; e++) {
|
|
77496
|
+
let t = aH(c, l, e / r, d, f);
|
|
77497
|
+
p.push([
|
|
77498
|
+
this._center[0] + s * t[0],
|
|
77499
|
+
this._center[1] + s * t[1],
|
|
77500
|
+
this._center[2] + s * t[2]
|
|
77501
|
+
]);
|
|
77502
|
+
}
|
|
77503
|
+
let m = new bD({
|
|
77504
|
+
vertices: p,
|
|
77505
|
+
color: i,
|
|
77506
|
+
strokeWidth: a,
|
|
77507
|
+
closed: !1
|
|
77508
|
+
});
|
|
77509
|
+
return this.add(m), m;
|
|
77510
|
+
}
|
|
77511
|
+
graticule(e = {}) {
|
|
77512
|
+
let { latStep: t = 30, lonStep: n = 30, segments: r = 48, color: i = "#8d99ae", lineWidth: a = 1 } = e, o = new jT();
|
|
77513
|
+
for (let e = -180; e < 180; e += n) o.add(this._gridLine(cH(e, r), i, a));
|
|
77514
|
+
for (let e = -90 + t; e < 90; e += t) o.add(this._gridLine(lH(e, r), i, a));
|
|
77515
|
+
return this.add(o), o;
|
|
77516
|
+
}
|
|
77517
|
+
_gridLine(e, t, n) {
|
|
77518
|
+
return new bD({
|
|
77519
|
+
vertices: e.map(([e, t]) => this.latLonToPoint(e, t)),
|
|
77520
|
+
color: t,
|
|
77521
|
+
strokeWidth: n,
|
|
77522
|
+
closed: !1
|
|
77523
|
+
});
|
|
77524
|
+
}
|
|
77525
|
+
_surfacePoint(e, t, n) {
|
|
77526
|
+
let r = iH(e, t);
|
|
77527
|
+
return [
|
|
77528
|
+
this._center[0] + n * r[0],
|
|
77529
|
+
this._center[1] + n * r[1],
|
|
77530
|
+
this._center[2] + n * r[2]
|
|
77531
|
+
];
|
|
77532
|
+
}
|
|
77533
|
+
};
|
|
77534
|
+
function iH(e, t) {
|
|
77535
|
+
let n = e * nH, r = t * nH, i = Math.cos(n);
|
|
77536
|
+
return [
|
|
77537
|
+
i * Math.cos(r),
|
|
77538
|
+
i * Math.sin(r),
|
|
77539
|
+
Math.sin(n)
|
|
77540
|
+
];
|
|
77541
|
+
}
|
|
77542
|
+
function aH(e, t, n, r, i) {
|
|
77543
|
+
if (i < 1e-9) return oH([
|
|
77544
|
+
e[0] + (t[0] - e[0]) * n,
|
|
77545
|
+
e[1] + (t[1] - e[1]) * n,
|
|
77546
|
+
e[2] + (t[2] - e[2]) * n
|
|
77547
|
+
]);
|
|
77548
|
+
let a = Math.sin((1 - n) * r) / i, o = Math.sin(n * r) / i;
|
|
77549
|
+
return [
|
|
77550
|
+
e[0] * a + t[0] * o,
|
|
77551
|
+
e[1] * a + t[1] * o,
|
|
77552
|
+
e[2] * a + t[2] * o
|
|
77553
|
+
];
|
|
77554
|
+
}
|
|
77555
|
+
function oH(e) {
|
|
77556
|
+
let t = Math.sqrt(e[0] * e[0] + e[1] * e[1] + e[2] * e[2]) || 1;
|
|
77557
|
+
return [
|
|
77558
|
+
e[0] / t,
|
|
77559
|
+
e[1] / t,
|
|
77560
|
+
e[2] / t
|
|
77561
|
+
];
|
|
77562
|
+
}
|
|
77563
|
+
function sH(e, t, n) {
|
|
77564
|
+
return Math.max(t, Math.min(n, e));
|
|
77565
|
+
}
|
|
77566
|
+
function cH(e, t) {
|
|
77567
|
+
let n = [];
|
|
77568
|
+
for (let r = 0; r <= t; r++) n.push([-90 + 180 * r / t, e]);
|
|
77569
|
+
return n;
|
|
77570
|
+
}
|
|
77571
|
+
function lH(e, t) {
|
|
77572
|
+
let n = [];
|
|
77573
|
+
for (let r = 0; r <= t; r++) n.push([e, -180 + 360 * r / t]);
|
|
77574
|
+
return n;
|
|
76700
77575
|
}
|
|
76701
77576
|
//#endregion
|
|
76702
|
-
export { OI as Add, Zj as AddTextLetterByLetter, uM as AddTextWordByWord, rO as Angle, wT as AnimateProxy, _I as AnimatedBoundary, AN as AnimatedImageMobject, o_ as Animation, zT as AnimationGroup, HO as AnnotationDot, jD as AnnularSector, AD as Annulus, dP as ApplyComplexFunction, lP as ApplyFunction, hP as ApplyMatrix, pP as ApplyMethod, iF as ApplyPointwiseFunction, sF as ApplyPointwiseFunctionToCenter, JI as ApplyWave, DD as Arc, OD as ArcBetweenPoints, AM as ArcBrace, ND as ArcPolygon, ID as ArcPolygonFromArcs, qE as Arrow, YA as Arrow3D, pO as ArrowCircleFilledTip, fO as ArrowCircleTip, hO as ArrowSquareFilledTip, mO as ArrowSquareTip, lO as ArrowTip, dO as ArrowTriangleFilledTip, uO as ArrowTriangleTip, AA as ArrowVectorField, ZT as AudioManager, ek as Axes, yl as BLACK, np as BLEND_MODES, jl as BLUE, Tl as BLUE_A, El as BLUE_B, Dl as BLUE_C, Ol as BLUE_D, kl as BLUE_E, Bu as BOLD, Yu as BOOK, KD as BackgroundRectangle, EA as BarChart, nL as Blink, vO as BooleanResult, zA as Box3D, OM as Brace, kM as BraceBetweenPoints, jM as BraceLabel, MM as BraceText, II as Broadcast, bA as BulletedList, IT as Camera2D, PT as Camera2DFrame, FT as Camera3D, vD as CameraAnimateProxy, gD as CameraFrame, sd as CapStyleType, fI as ChangeDecimalToValue, SI as ChangeSpeed, dI as ChangingDecimal, yD as Circle, HI as Circumscribe, _L as Clickable, CP as ClockwiseTransform, _A as Code, AF as ComplexHomotopy, CA as ComplexPlane, eA as ComplexValueTracker, VA as Cone, dL as Controls, nO as ConvexHull, bj as ConvexHull3D, TP as CounterclockwiseTransform, Vj as Create, YD as Cross, RA as Cube, HD as CubicBezier, LD as CurvedArrow, RD as CurvedDoubleArrow, OT as CurvesAsSubmobjects, tO as Cutout, kP as CyclicReplace, BA as Cylinder, wl as DARKER_GRAY, Ml as DARK_BLUE, Du as DARK_BROWN, Cl as DARK_GRAY, ud as DEFAULT_ANIMATION_DURATION, Ru as DEFAULT_ARROW_TIP_LENGTH, jN as DEFAULT_ASPECT_RATIO, cA as DEFAULT_COLOR_SCHEME, Lu as DEFAULT_DASH_LENGTH, Fu as DEFAULT_DOT_RADIUS, ld as DEFAULT_FONT_SIZE, hd as DEFAULT_FPS, fd as DEFAULT_FRAME_HEIGHT, dd as DEFAULT_FRAME_WIDTH, bd as DEFAULT_MOBJECT_TO_EDGE_BUFFER, xd as DEFAULT_MOBJECT_TO_MOBJECT_BUFFER, md as DEFAULT_PIXEL_HEIGHT, pd as DEFAULT_PIXEL_WIDTH, ed as DEFAULT_POINTWISE_FUNCTION_RUN_TIME, nd as DEFAULT_POINT_DENSITY_1D, td as DEFAULT_POINT_DENSITY_2D, Iu as DEFAULT_SMALL_DOT_RADIUS, cd as DEFAULT_STROKE_WIDTH, $u as DEFAULT_WAIT_TIME, ju as DEGREES, Id as DL, Od as DOWN, Ld as DR, BD as DashedLine, VD as DashedVMobject, Nj as DecimalMatrix, Yk as DecimalNumber, EM as DecimalTable, lz as Degrees, fN as DiGraph, QN as DiceFace, wO as Difference, qA as Dodecahedron, UD as Dot, aj as Dot3D, JE as DoubleArrow, pL as Draggable, Uj as DrawBorderThenFill, aO as Elbow, kD as Ellipse, TO as Exclusion, iP as FadeIn, oP as FadeOut, LP as FadeToColor, _P as FadeTransform, yP as FadeTransformPieces, BI as Flash, XI as FocusOn, PN as FullScreenFadeRectangle, NN as FullScreenRectangle, KO as FunctionGraph, ru as GOLD, Ql as GOLD_A, $l as GOLD_B, eu as GOLD_C, tu as GOLD_D, nu as GOLD_E, Sl as GRAY, ml as GRAY_A, hl as GRAY_B, gl as GRAY_C, _l as GRAY_D, vl as GRAY_E, Gl as GREEN, zl as GREEN_A, Bl as GREEN_B, Vl as GREEN_C, Hl as GREEN_D, Ul as GREEN_E, uN as GenericGraph, jL as GifExporter, vw as GlyphVMobject, BM as GradientVMobject, dN as Graph, jT as Group, LF as GrowArrow, mF as GrowFromCenter, zF as GrowFromEdge, VF as GrowFromPoint, Gu as HEAVY, zR as HSV, CD as Hexagon, kF as Homotopy, hL as Hoverable, Md as IN, Zu as ITALIC, KA as Icosahedron, l_ as ImageMobject, ak as ImplicitFunction, RI as Indicate, Xk as Integer, Mj as IntegerMatrix, TM as IntegerTable, tE as InteractiveScene, CO as Intersection, yd as LARGE_BUFF, kd as LEFT, Hu as LIGHT, bl as LIGHTER_GRAY, Eu as LIGHT_BROWN, xl as LIGHT_GRAY, wu as LIGHT_PINK, XD as Label, BO as LabeledArrow, VO as LabeledDot, zO as LabeledLine, UO as LabeledPolygram, KF as LaggedStart, XF as LaggedStartMap, GD as LargeDot, nE as Lighting, UE as Line, JA as Line3D, od as LineJointType, nk as LinearBase, ZE as LinearTransformationScene, rk as LogBase, Ou as MANIM_BACKGROUND, gu as MAROON, du as MAROON_A, fu as MAROON_B, pu as MAROON_C, mu as MAROON_D, hu as MAROON_E, Uu as MEDIUM, vd as MED_LARGE_BUFF, _d as MED_SMALL_BUFF, lA as MONOKAI_COLOR_SCHEME, WN as MandelbrotSet, bM as ManimBanner, LR as ManimColor, tV as ManimSceneElement, mD as MappingCamera, SA as MarkdownText, Ek as MarkupText, eP as MasterTimeline, CM as MathTable, Mk as MathTex, ZC as MathTexImage, yA as MathTexPart, Nk as MathTexSVG, Kk as MathTypst, jj as Matrix, cp as Mobject, BN as Mobject1D, VN as Mobject2D, IA as Mobject3D, Pj as MobjectMatrix, wM as MobjectTable, Aj as ModelMobject, yL as MovablePoint, SF as MoveAlongPath, hT as MoveToTarget, vF as MoveToTargetPosition, dD as MovingCamera, LE as MovingCameraScene, pD as MultiCamera, uz as Munits, zu as NORMAL, JN as NewtonFractal, NT as NullRenderer, WO as NumberLine, ik as NumberPlane, Qu as OBLIQUE, Tu as ORANGE, Nd as ORIGIN, jd as OUT, GA as Octahedron, DE as OrbitControls, LN as PGroup, ku as PI, Cu as PINK, s_ as PMobject, Al as PURE_BLUE, Wl as PURE_GREEN, lu as PURE_RED, Su as PURPLE, _u as PURPLE_A, vu as PURPLE_B, yu as PURPLE_C, bu as PURPLE_D, xu as PURPLE_E, uk as Paragraph, ok as ParametricFunction, $A as ParametricSurface, wD as Pentagon, fz as Percent, MF as PhaseFlow, cz as Pixels, fL as PlaybackControls, aR as Player, rR as PlayerController, GL as PlayerUI, zN as PointCloudDot, RN as PointMobject, wA as PolarPlane, bD as Polygon, TD as Polygram, UA as Polyhedron, ij as Prism, QI as Pulse, uu as RED, iu as RED_A, au as RED_B, ou as RED_C, su as RED_D, cu as RED_E, RR as RGBA, Ad as RIGHT, HR as RandomColorGenerator, jE as Rectangle, SD as RegularPolygon, eO as RegularPolygram, AI as Remove, $j as RemoveTextLetterByLetter, MT as Renderer, pT as ReplacementTransform, FP as Restore, iO as RightAngle, lF as Rotate, PI as Rotating, ZD as RoundedRectangle, rd as SCALE_FACTOR_PER_FONT_POINT, Wu as SEMIBOLD, Ju as SEMILIGHT, gd as SMALL_BUFF, id as START_X, ad as START_Y, $M as SVGMobject, XN as SampleSpace, fF as Scale, tk as ScaleBase, jP as ScaleInPlace, $T as Scene, JT as SceneStateManager, MN as ScreenRectangle, MD as Sector, eE as SelectionManager, gF as Shift, iL as ShowCreationThenDestruction, fM as ShowIncreasingSubsets, mM as ShowPartial, KI as ShowPassingFlash, eL as ShowPassingFlashWithThinningStrokeWidth, gM as ShowSubmobjectsOneByOne, NP as ShrinkToCenter, vA as SingleStringMathTex, TL as Slider, WD as SmallDot, jF as SmoothedVectorizedHomotopy, GB as SpecialThreeDScene, LA as Sphere, UF as SpinInFromNothing, vM as SpiralIn, hD as SplitScreenCamera, ME as Square, QD as Star, gO as StealthTip, FA as StreamLines, JF as Succession, QA as Surface, QA as Surface3D, ej as SurfacePresets, qD as SurroundingRectangle, DP as Swap, Au as TAU, Rl as TEAL, Nl as TEAL_A, Pl as TEAL_B, Fl as TEAL_C, Il as TEAL_D, Ll as TEAL_E, Vu as THIN, qa as THREE, SM as Table, oO as TangentLine, zD as TangentialArc, WA as Tetrahedron, Pk as Tex, wd as TexFontTemplates, Sd as TexTemplate, Td as TexTemplateLibrary, Bw as Text, bw as TextGlyphGroup, tj as TexturedSurface, rj as ThreeDAxes, fD as ThreeDCamera, AE as ThreeDScene, oj as ThreeDVMobject, VT as Timeline, ED as TipableVMobject, xA as Title, HA as Torus, hI as TracedPath, dT as Transform, zP as TransformAnimations, xP as TransformFromCopy, VP as TransformMatchingAbstractBase, tF as TransformMatchingCode, JP as TransformMatchingShapes, ZP as TransformMatchingTex, xD as Triangle, aM as TypeWithCursor, Gk as Typst, Pd as UL, Xu as ULTRABOLD, Ku as ULTRAHEAVY, qu as ULTRALIGHT, Dd as UP, Fd as UR, Gj as Uncreate, JD as Underline, SO as Union, GO as UnitInterval, sM as UntypeWithCursor, Yj as Unwrite, $F as UpdateFromAlphaFunc, ZF as UpdateFromFunc, kT as VDict, Nh as VGroup, V as VMobject, QM as VMobjectFromSVGPath, Qk as ValueTracker, rA as Variable, YE as Vector, XA as Vector3D, kA as VectorField, sk as VectorFieldVector, XE as VectorScene, AT as VectorizedPoint, PL as VideoExporter, bN as VideoMobject, lD as Voiceover, uD as VoiceoverScene, pl as WHITE, MI as Wait, UL as WebCodecsExporter, nD as WebSpeechSynthesizer, WI as Wiggle, lL as WiggleOutThenIn, qj as Write, Mu as X_AXIS, Zl as YELLOW, Kl as YELLOW_A, ql as YELLOW_B, Jl as YELLOW_C, Yl as YELLOW_D, Xl as YELLOW_E, Nu as Y_AXIS, Pu as Z_AXIS, FE as ZoomDisplayPopOut, IE as ZoomedScene, kI as add, Qj as addTextLetterByLetter, dM as addTextWordByWord, Kd as addVec, WR as adjacentNTuples, GR as adjacentPairs, ez as allElementsAreInstances, iI as always, nI as alwaysRedraw, cI as alwaysRotate, sI as alwaysShift, Tz as angleAxisFromQuaternion, Nz as angleBetweenVectors, Mz as angleOfVector, vI as animatedBoundary, BT as animationGroup, ip as applyBlendMode, fP as applyComplexFunction, uP as applyFunction, gP as applyMatrix, mP as applyMethod, aF as applyPointwiseFunction, cF as applyPointwiseFunctionToCenter, YI as applyWave, OC as areKatexStylesLoaded, aI as assertIsMobjectMethod, TR as averageColor, hB as bezier, vB as bezierRemap, aB as binarySearch, _N as binaryTree, yN as bipartiteGraph, rp as blendModeToThree, rL as blink, LI as broadcast, ww as buildStyledTextLines, Kz as cartesianToSpherical, Bz as centerOfMass, mI as changeDecimalToValue, CI as changeSpeed, pI as changingDecimal, oB as choose, UI as circumscribe, ST as clearAnimationOverrides, sB as clip, rB as clockwisePath, wP as clockwiseTransform, Sh as colorGradient, yR as colorToIntRgb, bR as colorToIntRgba, _R as colorToRgb, vR as colorToRgba, Fz as compassDirections, pN as completeGraph, zz as complexFuncToR3Func, PF as complexHomotopy, Lz as complexToR3, nA as complexValueTracker, bg as compose, nN as computeCircularLayout, tN as computeLayout, tz as concatenateLists, iB as counterclockwisePath, EP as counterclockwiseTransform, Hj as create, $N as createDiceRow, FN as createFadeToBlack, IN as createFadeToWhite, ML as createGifExporter, FL as createVideoExporter, WL as createWebCodecsExporter, Yd as cross, Yd as crossVec, xz as cross2d, Zh as cubicBezier, uI as cycleAnimation, mN as cycleGraph, AP as cyclicReplace, UT as deserializeMobject, wj as detectModelFormat, OO as difference, Jd as dotVec, _g as doubleSmooth, BL as downloadBlob, Wj as drawBorderThenFill, ym as earclipTriangulation, Qh as ease, og as easeIn, og as easeInCubic, Zg as easeInBack, $h as easeInBezier, pg as easeInBounce, Gg as easeInCirc, n_ as easeInElastic, ug as easeInExpo, ag as easeInOut, ag as easeInOutCubic, $g as easeInOutBack, tg as easeInOutBezier, a_ as easeInOutBounce, qg as easeInOutCirc, i_ as easeInOutElastic, Wg as easeInOutExpo, Lg as easeInOutQuad, Bg as easeInOutQuart, Ug as easeInOutQuint, Ig as easeInOutSine, cg as easeInQuad, Rg as easeInQuart, Vg as easeInQuint, Pg as easeInSine, sg as easeOut, sg as easeOutCubic, Qg as easeOutBack, eg as easeOutBezier, fg as easeOutBounce, Kg as easeOutCirc, r_ as easeOutElastic, dg as easeOutExpo, lg as easeOutQuad, zg as easeOutQuart, Hg as easeOutQuint, Fg as easeOutSine, TI as emphasizeRegion, EC as ensureKatexStyles, kO as exclusion, Ag as exponentialDecay, VL as exportAndDownloadPNG, RL as exportFramePNG, zL as exportPNGSequence, pz as extractMobjectFamilyMembers, rI as fAlways, aP as fadeIn, sP as fadeOut, RP as fadeToColor, vP as fadeTransform, bP as fadeTransformPieces, Uz as findIntersection, VI as flash, ZI as focusOn, LB as get3dVmobEndCorner, FB as get3dVmobEndCornerIndex, BB as get3dVmobEndCornerUnitNormal, NB as get3dVmobGradientStartAndEndPoints, IB as get3dVmobStartCorner, PB as get3dVmobStartCornerIndex, zB as get3dVmobStartCornerUnitNormal, RB as get3dVmobUnitNormal, $f as getActiveTheme, bT as getAnimationOverride, Fj as getDetText, dR as getFeatureFlags, UR as getShadedRgb, gh as getSmoothCubicBezierHandlePoints, oD as getSpeechSynthesizer, Qf as getTheme, ep as getThemeNames, Pz as getUnitNormal, Xz as getWindingNumber, vN as gridGraph, RF as growArrow, hF as growFromCenter, BF as growFromEdge, HF as growFromPoint, xT as hasAnimationOverride, az as hashObj, gR as hexToRgb, NF as homotopy, kR as hsvToRgb, hz as indexLabels, zI as indicate, ph as integerInterpolate, lB as interpolate, wR as interpolateColor, DO as intersection, dB as inverseInterpolate, CR as invertColor, yB as isClosed, cR as isFeatureEnabled, UC as isMathJaxLoaded, eD as isSpeechSupported, Bk as isTypstLoaded, KC as katexCanRender, GF as laggedStart, YF as laggedStartMap, Xd as lengthVec, Hz as lineIntersection, rg as linear, wI as linearSpeedRamp, kg as lingering, tf as linspace, qR as listDifferenceUpdate, JR as listUpdate, nz as listify, Gf as logger, tI as maintainPositionRelativeTo, vL as makeClickable, mL as makeDraggable, XR as makeEven, iz as makeEvenByCycling, gL as makeHoverable, SL as makeMovablePoint, DL as makeSlider, YB as manimElementInternals, tP as masterTimeline, fB as matchInterpolate, Ij as matrixToMobject, Lj as matrixToTexString, uB as mid, Vz as midpoint, CF as moveAlongPath, gT as moveToTarget, yF as moveToTargetPosition, bz as normSquared, Sz as normalize, Zd as normalizeVec, Og as notQuiteThere, Hf as onLog, ef as orientation2D, $d as orthonormalFrame, yT as overrideAnimate, vT as overrideAnimation, $E as parseBookmarks, AC as parseSVGPathData, fh as partialBezierPoints, nB as pathAlongArc, tB as pathAlongCircles, hN as pathGraph, Jz as perpendicularBisector, IF as phaseFlow, AB as pointLiesOnBezier, $R as powerset, WC as preloadMathJax, Vk as preloadTypst, CT as prepareAnimation, gz as printFamily, kB as proportionsAlongBezierCurveForPoint, $I as pulse, Ez as quaternionConjugate, wz as quaternionFromAngleAxis, Cz as quaternionMult, Rz as r3ToComplex, OR as randomBrightColor, DR as randomColor, KB as registerFont, nV as registerManimElement, Xf as registerTheme, Iz as regularVertices, jI as remove, KR as removeListRedundancies, rz as removeNones, eM as removeTextLetterByLetter, GC as renderLatexToSVG, Uk as renderTypstToSVG, mT as replacementTransform, uR as resetFeatureFlags, tp as resetThemes, IP as restore, XT as restoreMobjectState, mz as restructureListToExcludeCertainFamilyMembers, yg as reverse, xR as rgbToColor, hR as rgbToHex, AR as rgbToHsv, SR as rgbaToColor, uF as rotate, Az as rotateVector, FI as rotating, Oz as rotationAboutZ, Dz as rotationMatrix, kz as rotationMatrixTranspose, Eg as runningStart, gg as rushFrom, hg as rushInto, EI as rushRegion, YT as saveMobjectState, pF as scale, MP as scaleInPlace, Gd as scaleVec, HT as serializeMobject, lR as setFeatureFlags, ON as setGifDecoder, wC as setKatexStylesheetUrl, BC as setMathJaxScriptUrl, Cj as setModelLoaderFactory, aD as setSpeechSynthesizer, Zf as setTheme, Rk as setTypstCompiler, _F as shift, Wz as shoelace, Gz as shoelaceDirection, aL as showCreationThenDestruction, pM as showIncreasingSubsets, hM as showPartial, qI as showPassingFlash, tL as showPassingFlashWithThinningStrokeWidth, _M as showSubmobjectsOneByOne, PP as shrinkToCenter, cB as sigmoid, Cg as slowInto, ig as smooth, DI as smoothSpeedCurve, FF as smoothedVectorizedHomotopy, Ng as smoothererstep, Mg as smootherstep, jg as smoothstep, qT as snapshotFromJSON, KT as snapshotToJSON, qz as sphericalToCartesian, WF as spinInFromNothing, yM as spiralIn, gB as splitBezier, Hh as spring, wg as squishRateFunc, gN as starGraph, GT as stateFromJSON, WT as stateToJSON, vg as stepFunction, ng as steps, eB as straightPath, ZR as stretchArrayToLength, qd as subVec, _B as subdivideBezier, qF as succession, eN as svgMobject, PC as svgToVMobjects, OP as swap, nj as texturedSphere, mg as thereAndBack, Tg as thereAndBackWithPause, Yz as thickDiagonal, gI as tracedPath, fT as transform, BP as transformAnimations, SP as transformFromCopy, nF as transformMatchingCode, YP as transformMatchingShapes, QP as transformMatchingTex, YR as tuplify, lI as turnAnimationIntoUpdater, oM as typeWithCursor, Kj as uncreate, EO as union, QR as uniqChain, Qd as unitPerpendicularTo, cM as untypeWithCursor, Xj as unwrite, eI as updateFromAlphaFunc, QF as updateFromFunc, tA as valueTracker, NI as wait, GI as wiggle, uL as wiggleOutThenIn, Dg as wiggleRate, Jj as write, jz as zToVector };
|
|
77577
|
+
export { kI as Add, Zj as AddTextLetterByLetter, uM as AddTextWordByWord, rO as Angle, wT as AnimateProxy, vI as AnimatedBoundary, AN as AnimatedImageMobject, o_ as Animation, zT as AnimationGroup, HO as AnnotationDot, jD as AnnularSector, AD as Annulus, dP as ApplyComplexFunction, lP as ApplyFunction, hP as ApplyMatrix, pP as ApplyMethod, aF as ApplyPointwiseFunction, cF as ApplyPointwiseFunctionToCenter, YI as ApplyWave, DD as Arc, OD as ArcBetweenPoints, AM as ArcBrace, ND as ArcPolygon, ID as ArcPolygonFromArcs, qE as Arrow, YA as Arrow3D, pO as ArrowCircleFilledTip, fO as ArrowCircleTip, hO as ArrowSquareFilledTip, mO as ArrowSquareTip, lO as ArrowTip, dO as ArrowTriangleFilledTip, uO as ArrowTriangleTip, AA as ArrowVectorField, ZT as AudioManager, ek as Axes, yl as BLACK, np as BLEND_MODES, jl as BLUE, Tl as BLUE_A, El as BLUE_B, Dl as BLUE_C, Ol as BLUE_D, kl as BLUE_E, Bu as BOLD, Yu as BOOK, KD as BackgroundRectangle, EA as BarChart, rL as Blink, vO as BooleanResult, zA as Box3D, OM as Brace, kM as BraceBetweenPoints, jM as BraceLabel, MM as BraceText, LI as Broadcast, bA as BulletedList, IT as Camera2D, PT as Camera2DFrame, FT as Camera3D, vD as CameraAnimateProxy, gD as CameraFrame, sd as CapStyleType, pI as ChangeDecimalToValue, CI as ChangeSpeed, fI as ChangingDecimal, $V as ChoroplethMap, yD as Circle, UI as Circumscribe, vL as Clickable, CP as ClockwiseTransform, _A as Code, QV as ColorScale, jF as ComplexHomotopy, CA as ComplexPlane, eA as ComplexValueTracker, VA as Cone, fL as Controls, nO as ConvexHull, bj as ConvexHull3D, TP as CounterclockwiseTransform, Vj as Create, YD as Cross, RA as Cube, HD as CubicBezier, LD as CurvedArrow, RD as CurvedDoubleArrow, OT as CurvesAsSubmobjects, tO as Cutout, AP as CyclicReplace, BA as Cylinder, wl as DARKER_GRAY, Ml as DARK_BLUE, Du as DARK_BROWN, Cl as DARK_GRAY, ud as DEFAULT_ANIMATION_DURATION, Ru as DEFAULT_ARROW_TIP_LENGTH, jN as DEFAULT_ASPECT_RATIO, cA as DEFAULT_COLOR_SCHEME, Lu as DEFAULT_DASH_LENGTH, Fu as DEFAULT_DOT_RADIUS, ld as DEFAULT_FONT_SIZE, hd as DEFAULT_FPS, fd as DEFAULT_FRAME_HEIGHT, dd as DEFAULT_FRAME_WIDTH, bd as DEFAULT_MOBJECT_TO_EDGE_BUFFER, xd as DEFAULT_MOBJECT_TO_MOBJECT_BUFFER, md as DEFAULT_PIXEL_HEIGHT, pd as DEFAULT_PIXEL_WIDTH, ed as DEFAULT_POINTWISE_FUNCTION_RUN_TIME, nd as DEFAULT_POINT_DENSITY_1D, td as DEFAULT_POINT_DENSITY_2D, Iu as DEFAULT_SMALL_DOT_RADIUS, cd as DEFAULT_STROKE_WIDTH, $u as DEFAULT_WAIT_TIME, ju as DEGREES, Id as DL, Od as DOWN, Ld as DR, BD as DashedLine, VD as DashedVMobject, Nj as DecimalMatrix, Yk as DecimalNumber, EM as DecimalTable, Dz as Degrees, fN as DiGraph, QN as DiceFace, wO as Difference, qA as Dodecahedron, UD as Dot, aj as Dot3D, JE as DoubleArrow, mL as Draggable, Uj as DrawBorderThenFill, aO as Elbow, kD as Ellipse, TO as Exclusion, oR as ExportSettingsPanel, tR as FPS_PRESETS, iP as FadeIn, oP as FadeOut, RP as FadeToColor, _P as FadeTransform, yP as FadeTransformPieces, VI as Flash, ZI as FocusOn, PN as FullScreenFadeRectangle, NN as FullScreenRectangle, KO as FunctionGraph, ru as GOLD, Ql as GOLD_A, $l as GOLD_B, eu as GOLD_C, tu as GOLD_D, nu as GOLD_E, Sl as GRAY, ml as GRAY_A, hl as GRAY_B, gl as GRAY_C, _l as GRAY_D, vl as GRAY_E, Gl as GREEN, zl as GREEN_A, Bl as GREEN_B, Vl as GREEN_C, Hl as GREEN_D, Ul as GREEN_E, uN as GenericGraph, eH as GeoMap, zL as GifExporter, rH as Globe, vw as GlyphVMobject, BM as GradientVMobject, dN as Graph, jT as Group, RF as GrowArrow, hF as GrowFromCenter, BF as GrowFromEdge, HF as GrowFromPoint, Gu as HEAVY, rz as HSV, CD as Hexagon, AF as Homotopy, gL as Hoverable, Md as IN, Zu as ITALIC, KA as Icosahedron, l_ as ImageMobject, ak as ImplicitFunction, zI as Indicate, Xk as Integer, Mj as IntegerMatrix, TM as IntegerTable, tE as InteractiveScene, CO as Intersection, yd as LARGE_BUFF, kd as LEFT, Hu as LIGHT, bl as LIGHTER_GRAY, Eu as LIGHT_BROWN, xl as LIGHT_GRAY, wu as LIGHT_PINK, XD as Label, BO as LabeledArrow, VO as LabeledDot, zO as LabeledLine, UO as LabeledPolygram, qF as LaggedStart, ZF as LaggedStartMap, GD as LargeDot, nE as Lighting, UE as Line, JA as Line3D, od as LineJointType, nk as LinearBase, ZE as LinearTransformationScene, rk as LogBase, Ou as MANIM_BACKGROUND, gu as MAROON, du as MAROON_A, fu as MAROON_B, pu as MAROON_C, mu as MAROON_D, hu as MAROON_E, Uu as MEDIUM, vd as MED_LARGE_BUFF, _d as MED_SMALL_BUFF, lA as MONOKAI_COLOR_SCHEME, WN as MandelbrotSet, bM as ManimBanner, tz as ManimColor, yV as ManimSceneElement, mD as MappingCamera, SA as MarkdownText, Ek as MarkupText, eP as MasterTimeline, CM as MathTable, Mk as MathTex, ZC as MathTexImage, yA as MathTexPart, Nk as MathTexSVG, Kk as MathTypst, jj as Matrix, ML as MatrixTracker, cp as Mobject, BN as Mobject1D, VN as Mobject2D, IA as Mobject3D, Pj as MobjectMatrix, wM as MobjectTable, Aj as ModelMobject, bL as MovablePoint, CF as MoveAlongPath, hT as MoveToTarget, yF as MoveToTargetPosition, dD as MovingCamera, LE as MovingCameraScene, pD as MultiCamera, Oz as Munits, zu as NORMAL, JN as NewtonFractal, NT as NullRenderer, WO as NumberLine, ik as NumberPlane, Qu as OBLIQUE, Tu as ORANGE, Nd as ORIGIN, jd as OUT, GA as Octahedron, DE as OrbitControls, LN as PGroup, ku as PI, Cu as PINK, s_ as PMobject, Al as PURE_BLUE, Wl as PURE_GREEN, lu as PURE_RED, Su as PURPLE, _u as PURPLE_A, vu as PURPLE_B, yu as PURPLE_C, bu as PURPLE_D, xu as PURPLE_E, uk as Paragraph, ok as ParametricFunction, $A as ParametricSurface, wD as Pentagon, Az as Percent, NF as PhaseFlow, Ez as Pixels, pL as PlaybackControls, CR as Player, yR as PlayerController, sR as PlayerUI, zN as PointCloudDot, RN as PointMobject, wA as PolarPlane, bD as Polygon, TD as Polygram, UA as Polyhedron, ij as Prism, $I as Pulse, nR as QUALITY_PRESETS, uu as RED, iu as RED_A, au as RED_B, ou as RED_C, su as RED_D, cu as RED_E, eR as RESOLUTION_PRESETS, nz as RGBA, Ad as RIGHT, oz as RandomColorGenerator, jE as Rectangle, SD as RegularPolygon, eO as RegularPolygram, jI as Remove, $j as RemoveTextLetterByLetter, MT as Renderer, pT as ReplacementTransform, IP as Restore, iO as RightAngle, uF as Rotate, FI as Rotating, ZD as RoundedRectangle, rd as SCALE_FACTOR_PER_FONT_POINT, Wu as SEMIBOLD, Ju as SEMILIGHT, gd as SMALL_BUFF, id as START_X, ad as START_Y, $M as SVGMobject, XN as SampleSpace, pF as Scale, tk as ScaleBase, MP as ScaleInPlace, $T as Scene, JT as SceneStateManager, MN as ScreenRectangle, MD as Sector, eE as SelectionManager, _F as Shift, aL as ShowCreationThenDestruction, fM as ShowIncreasingSubsets, mM as ShowPartial, qI as ShowPassingFlash, tL as ShowPassingFlashWithThinningStrokeWidth, gM as ShowSubmobjectsOneByOne, PP as ShrinkToCenter, vA as SingleStringMathTex, EL as Slider, WD as SmallDot, MF as SmoothedVectorizedHomotopy, lV as SpecialThreeDScene, LA as Sphere, WF as SpinInFromNothing, vM as SpiralIn, hD as SplitScreenCamera, ME as Square, QD as Star, gO as StealthTip, FA as StreamLines, YF as Succession, QA as Surface, QA as Surface3D, ej as SurfacePresets, qD as SurroundingRectangle, DP as Swap, Au as TAU, Rl as TEAL, Nl as TEAL_A, Pl as TEAL_B, Fl as TEAL_C, Il as TEAL_D, Ll as TEAL_E, Vu as THIN, qa as THREE, SM as Table, oO as TangentLine, zD as TangentialArc, WA as Tetrahedron, Pk as Tex, wd as TexFontTemplates, Sd as TexTemplate, Td as TexTemplateLibrary, Bw as Text, bw as TextGlyphGroup, tj as TexturedSurface, rj as ThreeDAxes, fD as ThreeDCamera, AE as ThreeDScene, oj as ThreeDVMobject, VT as Timeline, ED as TipableVMobject, xA as Title, HA as Torus, gI as TracedPath, dT as Transform, BP as TransformAnimations, xP as TransformFromCopy, HP as TransformMatchingAbstractBase, nF as TransformMatchingCode, YP as TransformMatchingShapes, QP as TransformMatchingTex, xD as Triangle, aM as TypeWithCursor, Gk as Typst, Pd as UL, Xu as ULTRABOLD, Ku as ULTRAHEAVY, qu as ULTRALIGHT, Dd as UP, Fd as UR, Gj as Uncreate, JD as Underline, SO as Union, GO as UnitInterval, sM as UntypeWithCursor, Yj as Unwrite, eI as UpdateFromAlphaFunc, QF as UpdateFromFunc, kT as VDict, Nh as VGroup, V as VMobject, QM as VMobjectFromSVGPath, Qk as ValueTracker, rA as Variable, YE as Vector, XA as Vector3D, kA as VectorField, sk as VectorFieldVector, XE as VectorScene, AT as VectorizedPoint, HL as VideoExporter, bN as VideoMobject, lD as Voiceover, uD as VoiceoverScene, pl as WHITE, NI as Wait, ZL as WebCodecsExporter, nD as WebSpeechSynthesizer, GI as Wiggle, uL as WiggleOutThenIn, qj as Write, Mu as X_AXIS, Zl as YELLOW, Kl as YELLOW_A, ql as YELLOW_B, Jl as YELLOW_C, Yl as YELLOW_D, Xl as YELLOW_E, Nu as Y_AXIS, Pu as Z_AXIS, FE as ZoomDisplayPopOut, IE as ZoomedScene, AI as add, Qj as addTextLetterByLetter, dM as addTextWordByWord, Kd as addVec, cz as adjacentNTuples, lz as adjacentPairs, vz as allElementsAreInstances, aI as always, rI as alwaysRedraw, lI as alwaysRotate, cI as alwaysShift, Uz as angleAxisFromQuaternion, Zz as angleBetweenVectors, Xz as angleOfVector, yI as animatedBoundary, BT as animationGroup, ip as applyBlendMode, fP as applyComplexFunction, uP as applyFunction, gP as applyMatrix, FL as applyMatrixLive, mP as applyMethod, oF as applyPointwiseFunction, lF as applyPointwiseFunctionToCenter, XI as applyWave, OC as areKatexStylesLoaded, oI as assertIsMobjectMethod, UR as averageColor, NB as bezier, IB as bezierRemap, CB as binarySearch, _N as binaryTree, yN as bipartiteGraph, rp as blendModeToThree, iL as blink, RI as broadcast, ww as buildStyledTextLines, uB as cartesianToSpherical, iB as centerOfMass, hI as changeDecimalToValue, wI as changeSpeed, mI as changingDecimal, wB as choose, $L as chooseVideoExporterStrategy, WI as circumscribe, ST as clearAnimationOverrides, TB as clip, xB as clockwisePath, wP as clockwiseTransform, Sh as colorGradient, LR as colorToIntRgb, RR as colorToIntRgba, FR as colorToRgb, IR as colorToRgba, $z as compassDirections, pN as completeGraph, rB as complexFuncToR3Func, FF as complexHomotopy, tB as complexToR3, nA as complexValueTracker, bg as compose, nN as computeCircularLayout, tN as computeLayout, yz as concatenateLists, SB as counterclockwisePath, EP as counterclockwiseTransform, Hj as create, $N as createDiceRow, FN as createFadeToBlack, IN as createFadeToWhite, BL as createGifExporter, UL as createVideoExporter, QL as createWebCodecsExporter, Yd as cross, Yd as crossVec, zz as cross2d, Zh as cubicBezier, dI as cycleAnimation, mN as cycleGraph, jP as cyclicReplace, UT as deserializeMobject, KV as deserializeScene, WV as deserializeSceneMobject, wj as detectModelFormat, OO as difference, Jd as dotVec, _g as doubleSmooth, JL as downloadBlob, Wj as drawBorderThenFill, ym as earclipTriangulation, Qh as ease, og as easeIn, og as easeInCubic, Zg as easeInBack, $h as easeInBezier, pg as easeInBounce, Gg as easeInCirc, n_ as easeInElastic, ug as easeInExpo, ag as easeInOut, ag as easeInOutCubic, $g as easeInOutBack, tg as easeInOutBezier, a_ as easeInOutBounce, qg as easeInOutCirc, i_ as easeInOutElastic, Wg as easeInOutExpo, Lg as easeInOutQuad, Bg as easeInOutQuart, Ug as easeInOutQuint, Ig as easeInOutSine, cg as easeInQuad, Rg as easeInQuart, Vg as easeInQuint, Pg as easeInSine, sg as easeOut, sg as easeOutCubic, Qg as easeOutBack, eg as easeOutBezier, fg as easeOutBounce, Kg as easeOutCirc, r_ as easeOutElastic, dg as easeOutExpo, lg as easeOutQuad, zg as easeOutQuart, Hg as easeOutQuint, Fg as easeOutSine, EI as emphasizeRegion, EC as ensureKatexStyles, YV as equirectangular, kO as exclusion, Ag as exponentialDecay, YL as exportAndDownloadPNG, KL as exportFramePNG, qL as exportPNGSequence, qV as exteriorRings, jz as extractMobjectFamilyMembers, iI as fAlways, aP as fadeIn, sP as fadeOut, zP as fadeToColor, vP as fadeTransform, bP as fadeTransformPieces, sB as findIntersection, HI as flash, QI as focusOn, tV as get3dVmobEndCorner, $B as get3dVmobEndCornerIndex, iV as get3dVmobEndCornerUnitNormal, ZB as get3dVmobGradientStartAndEndPoints, eV as get3dVmobStartCorner, QB as get3dVmobStartCornerIndex, rV as get3dVmobStartCornerUnitNormal, nV as get3dVmobUnitNormal, $f as getActiveTheme, bT as getAnimationOverride, Fj as getDetText, kR as getFeatureFlags, TV as getSerializableTypes, wV as getSerializer, sz as getShadedRgb, gh as getSmoothCubicBezierHandlePoints, oD as getSpeechSynthesizer, Qf as getTheme, ep as getThemeNames, Qz as getUnitNormal, mB as getWindingNumber, vN as gridGraph, zF as growArrow, gF as growFromCenter, VF as growFromEdge, UF as growFromPoint, xT as hasAnimationOverride, Cz as hashObj, PR as hexToRgb, PF as homotopy, qR as hsvToRgb, Nz as indexLabels, BI as indicate, ph as integerInterpolate, DB as interpolate, HR as interpolateColor, DO as intersection, kB as inverseInterpolate, VR as invertColor, LB as isClosed, ER as isFeatureEnabled, UC as isMathJaxLoaded, eD as isSpeechSupported, Bk as isTypstLoaded, KC as katexCanRender, KF as laggedStart, XF as laggedStartMap, Xd as lengthVec, oB as lineIntersection, rg as linear, TI as linearSpeedRamp, kg as lingering, tf as linspace, dz as listDifferenceUpdate, fz as listUpdate, bz as listify, Gf as logger, nI as maintainPositionRelativeTo, yL as makeClickable, hL as makeDraggable, mz as makeEven, Sz as makeEvenByCycling, _L as makeHoverable, NL as makeMatrixTracker, CL as makeMovablePoint, OL as makeSlider, pV as manimElementInternals, tP as masterTimeline, AB as matchInterpolate, Ij as matrixToMobject, Lj as matrixToTexString, XV as mercator, OB as mid, aB as midpoint, wF as moveAlongPath, gT as moveToTarget, bF as moveToTargetPosition, Rz as normSquared, Bz as normalize, Zd as normalizeVec, Og as notQuiteThere, Hf as onLog, ef as orientation2D, $d as orthonormalFrame, yT as overrideAnimate, vT as overrideAnimation, $E as parseBookmarks, AC as parseSVGPathData, fh as partialBezierPoints, bB as pathAlongArc, yB as pathAlongCircles, hN as pathGraph, fB as perpendicularBisector, LF as phaseFlow, JB as pointLiesOnBezier, _z as powerset, WC as preloadMathJax, Vk as preloadTypst, CT as prepareAnimation, Pz as printFamily, qB as proportionsAlongBezierCurveForPoint, eL as pulse, iR as qualityToBitrate, Wz as quaternionConjugate, Hz as quaternionFromAngleAxis, Vz as quaternionMult, nB as r3ToComplex, KR as randomBrightColor, GR as randomColor, uV as registerFont, bV as registerManimElement, SV as registerSerializableMobject, Xf as registerTheme, eB as regularVertices, MI as remove, uz as removeListRedundancies, xz as removeNones, eM as removeTextLetterByLetter, GC as renderLatexToSVG, Uk as renderTypstToSVG, mT as replacementTransform, OR as resetFeatureFlags, tp as resetThemes, aR as resolveResolution, LP as restore, XT as restoreMobjectState, Mz as restructureListToExcludeCertainFamilyMembers, yg as reverse, zR as rgbToColor, NR as rgbToHex, JR as rgbToHsv, BR as rgbaToColor, dF as rotate, Jz as rotateVector, II as rotating, Kz as rotationAboutZ, Gz as rotationMatrix, qz as rotationMatrixTranspose, Eg as runningStart, gg as rushFrom, hg as rushInto, DI as rushRegion, YT as saveMobjectState, mF as scale, NP as scaleInPlace, Gd as scaleVec, HT as serializeMobject, GV as serializeScene, UV as serializeSceneMobject, DR as setFeatureFlags, ON as setGifDecoder, wC as setKatexStylesheetUrl, BC as setMathJaxScriptUrl, Cj as setModelLoaderFactory, aD as setSpeechSynthesizer, Zf as setTheme, Rk as setTypstCompiler, vF as shift, cB as shoelace, lB as shoelaceDirection, oL as showCreationThenDestruction, pM as showIncreasingSubsets, hM as showPartial, JI as showPassingFlash, nL as showPassingFlashWithThinningStrokeWidth, _M as showSubmobjectsOneByOne, FP as shrinkToCenter, EB as sigmoid, Cg as slowInto, ig as smooth, OI as smoothSpeedCurve, IF as smoothedVectorizedHomotopy, Ng as smoothererstep, Mg as smootherstep, jg as smoothstep, qT as snapshotFromJSON, KT as snapshotToJSON, dB as sphericalToCartesian, GF as spinInFromNothing, yM as spiralIn, PB as splitBezier, Hh as spring, wg as squishRateFunc, gN as starGraph, GT as stateFromJSON, WT as stateToJSON, vg as stepFunction, ng as steps, vB as straightPath, hz as stretchArrayToLength, qd as subVec, FB as subdivideBezier, JF as succession, eN as svgMobject, PC as svgToVMobjects, OP as swap, nj as texturedSphere, mg as thereAndBack, Tg as thereAndBackWithPause, pB as thickDiagonal, _I as tracedPath, fT as transform, VP as transformAnimations, SP as transformFromCopy, rF as transformMatchingCode, XP as transformMatchingShapes, $P as transformMatchingTex, pz as tuplify, uI as turnAnimationIntoUpdater, oM as typeWithCursor, Kj as uncreate, EO as union, gz as uniqChain, Qd as unitPerpendicularTo, CV as unregisterSerializableMobject, cM as untypeWithCursor, Xj as unwrite, tI as updateFromAlphaFunc, $F as updateFromFunc, tA as valueTracker, PI as wait, KI as wiggle, dL as wiggleOutThenIn, Dg as wiggleRate, Jj as write, Yz as zToVector };
|