manim-web 0.11.0 → 0.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/animation/transform/TransformMatchingCode.d.ts +108 -0
- package/dist/animation/transform/TransformMatchingCode.d.ts.map +1 -0
- package/dist/animation/transform/index.d.ts +1 -0
- package/dist/animation/transform/index.d.ts.map +1 -1
- package/dist/audio/Voiceover.d.ts +95 -0
- package/dist/audio/Voiceover.d.ts.map +1 -0
- package/dist/audio/VoiceoverScene.d.ts +28 -0
- package/dist/audio/VoiceoverScene.d.ts.map +1 -0
- package/dist/audio/bookmarks.d.ts +40 -0
- package/dist/audio/bookmarks.d.ts.map +1 -0
- package/dist/audio/speechSynthesizer.d.ts +95 -0
- package/dist/audio/speechSynthesizer.d.ts.map +1 -0
- package/dist/core/Mobject.d.ts +31 -0
- package/dist/core/Mobject.d.ts.map +1 -1
- package/dist/core/Scene.d.ts +9 -0
- package/dist/core/Scene.d.ts.map +1 -1
- package/dist/index.d.ts +12 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -3
- package/dist/integrations/react.js +17 -17
- package/dist/integrations/vue.js +16 -16
- package/dist/interaction/MovablePoint.d.ts +127 -0
- package/dist/interaction/MovablePoint.d.ts.map +1 -0
- package/dist/interaction/Slider.d.ts +125 -0
- package/dist/interaction/Slider.d.ts.map +1 -0
- package/dist/interaction/index.d.ts +2 -0
- package/dist/interaction/index.d.ts.map +1 -1
- package/dist/lib-Bh3UXyYs.js +302 -0
- package/dist/manim-web.browser.js +7107 -5848
- package/dist/mobjects/image/AnimatedImageMobject.d.ts +141 -0
- package/dist/mobjects/image/AnimatedImageMobject.d.ts.map +1 -0
- package/dist/mobjects/image/gifDecoder.d.ts +46 -0
- package/dist/mobjects/image/gifDecoder.d.ts.map +1 -0
- package/dist/mobjects/svg/SVGMobject.d.ts +29 -0
- package/dist/mobjects/svg/SVGMobject.d.ts.map +1 -1
- package/dist/mobjects/svg/index.d.ts +3 -1
- package/dist/mobjects/svg/index.d.ts.map +1 -1
- package/dist/mobjects/svg/svgFill.d.ts +42 -0
- package/dist/mobjects/svg/svgFill.d.ts.map +1 -0
- package/dist/mobjects/svg/svgGradients.d.ts +68 -0
- package/dist/mobjects/svg/svgGradients.d.ts.map +1 -0
- package/dist/mobjects/svg/svgImage.d.ts +9 -0
- package/dist/mobjects/svg/svgImage.d.ts.map +1 -0
- package/dist/mobjects/svg/svgLoader.d.ts +35 -0
- package/dist/mobjects/svg/svgLoader.d.ts.map +1 -0
- package/dist/mobjects/svg/svgText.d.ts +15 -0
- package/dist/mobjects/svg/svgText.d.ts.map +1 -0
- package/dist/mobjects/text/Code.d.ts +23 -1
- package/dist/mobjects/text/Code.d.ts.map +1 -1
- package/dist/mobjects/text/CodeTokenLayout.d.ts +44 -0
- package/dist/mobjects/text/CodeTokenLayout.d.ts.map +1 -0
- package/dist/mobjects/text/index.d.ts +1 -0
- package/dist/mobjects/text/index.d.ts.map +1 -1
- package/dist/rate-functions/customEase.d.ts +39 -0
- package/dist/rate-functions/customEase.d.ts.map +1 -0
- package/dist/rate-functions/index.d.ts +4 -0
- package/dist/rate-functions/index.d.ts.map +1 -1
- package/dist/rate-functions/spring.d.ts +38 -0
- package/dist/rate-functions/spring.d.ts.map +1 -0
- package/dist/rendering/blendModes.d.ts +38 -0
- package/dist/rendering/blendModes.d.ts.map +1 -0
- package/dist/rolldown-runtime-CWhphoD1.js +23 -0
- package/dist/{src-C817VR8M.js → src-BcBBUMTP.js} +8676 -7417
- package/dist/utils/ThemeManager.d.ts +79 -0
- package/dist/utils/ThemeManager.d.ts.map +1 -0
- package/package.json +8 -1
package/dist/integrations/vue.js
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import { $ as e, $a as t, $c as n, $d as r, $f as i, $i as a, $l as
|
|
2
|
-
import { a as
|
|
3
|
-
import { defineComponent as
|
|
1
|
+
import { $ as e, $a as t, $c as n, $d as r, $f as i, $i as a, $l as ee, $n as te, $o as ne, $p as re, $r as ie, $s as ae, $t as oe, $u as se, A as ce, Aa as le, Ac as ue, Ad as de, Af as fe, Ai as pe, Al as o, Am as s, An as c, Ao as l, Ap as u, Ar as d, As as f, At as p, Au as m, B as h, Ba as g, Bc as _, Bd as v, Bf as y, Bi as b, Bl as x, Bn as S, Bo as C, Bp as w, Br as T, Bs as E, Bt as D, Bu as O, C as k, Ca as A, Cc as j, Cd as M, Cf as N, Ci as P, Cl as F, Cm as I, Cn as L, Co as R, Cp as z, Cr as B, Cs as me, Ct as he, Cu as ge, D as _e, Da as ve, Dc as ye, Dd as be, Df as xe, Di as Se, Dl as Ce, Dm as we, Dn as Te, Do as Ee, Dp as De, Dr as Oe, Ds as ke, Dt as Ae, Du as je, E as Me, Ea as Ne, Ec as Pe, Ed as Fe, Ef as Ie, Ei as Le, El as Re, Em as ze, En as Be, Eo as Ve, Ep as He, Er as Ue, Es as We, Et as Ge, Eu as Ke, F as qe, Fa as Je, Fc as Ye, Fd as Xe, Ff as Ze, Fi as Qe, Fl as $e, Fn as et, Fo as tt, Fp as nt, Fr as rt, Fs as it, Ft as at, Fu as ot, G as st, Ga as ct, Gc as lt, Gd as ut, Gf as dt, Gi as ft, Gl as pt, Gn as mt, Go as ht, Gp as gt, Gr as _t, Gs as vt, Gt as yt, Gu as bt, H as xt, Ha as St, Hc as Ct, Hd as wt, Hf as Tt, Hi as Et, Hl as Dt, Hn as Ot, Ho as kt, Hp as At, Hr as jt, Hs as Mt, Ht as Nt, Hu as V, I as Pt, Ia as Ft, Ic as It, Id as Lt, If as Rt, Ii as zt, Il as Bt, In as Vt, Io as Ht, Ip as Ut, Ir as Wt, Is as Gt, It as Kt, Iu as H, J as qt, Ja as Jt, Jc as Yt, Jd as Xt, Jf as Zt, Ji as Qt, Jl as $t, Jn as en, Jo as tn, Jp as nn, Jr as rn, Js as an, Jt as on, Ju as sn, K as cn, Ka as ln, Kc as un, Kd as dn, Kf as fn, Ki as pn, Kl as mn, Kn as hn, Ko as U, Kp as gn, Kr as _n, Ks as vn, Kt as yn, Ku as bn, L as xn, La as Sn, Lc as Cn, Ld as wn, Lf as Tn, Li as En, Ll as Dn, Ln as On, Lo as kn, Lp as An, Lr as jn, Ls as Mn, Lt as Nn, Lu as Pn, M as Fn, Ma as In, Mc as Ln, Md as Rn, Mf as zn, Mi as Bn, Ml as Vn, Mm as Hn, Mn as Un, Mo as Wn, Mp as Gn, Mr as Kn, Ms as qn, Mt as Jn, Mu as Yn, N as Xn, Na as Zn, Nc as Qn, Nd as $n, Nf as er, Ni as tr, Nl as nr, Nm as rr, Nn as ir, No as ar, Np as or, Nr as sr, Ns as cr, Nt as lr, Nu as ur, O as dr, Oa as fr, Oc as pr, Od as mr, Of as hr, Oi as gr, Ol as _r, Om as vr, On as yr, Oo as br, Op as xr, Or as Sr, Os as Cr, Ot as wr, Ou as Tr, P as Er, Pa as Dr, Pc as Or, Pd as kr, Pf as Ar, Pi as jr, Pl as W, Pm as Mr, Pn as Nr, Po as Pr, Pp as Fr, Pr as Ir, Ps as Lr, Pt as Rr, Pu as zr, Q as Br, Qa as Vr, Qc as Hr, Qd as Ur, Qf as Wr, Qi as Gr, Ql as Kr, Qn as qr, Qo as Jr, Qp as Yr, Qr as Xr, Qs as Zr, Qt as Qr, Qu as $r, R as ei, Ra as ti, Rc as ni, Rd as ri, Rf as ii, Ri as ai, Rl as oi, Rn as si, Ro as ci, Rp as li, Rr as ui, Rs as di, Rt as fi, Ru as pi, S as mi, Sa as hi, Sc as gi, Sd as _i, Sf as vi, Si as yi, Sl as bi, Sm as xi, Sn as Si, So as Ci, Sp as wi, Sr as Ti, Ss as Ei, St as Di, Su as Oi, T as ki, Ta as Ai, Tc as ji, Td as Mi, Tf as Ni, Ti as Pi, Tl as Fi, Tm as Ii, Tn as Li, To as Ri, Tp as zi, Tr as Bi, Ts as Vi, Tt as Hi, Tu as Ui, U as Wi, Ua as Gi, Uc as Ki, Ud as qi, Uf as Ji, Ui as Yi, Ul as Xi, Un as Zi, Uo as Qi, Up as $i, Ur as ea, Us as ta, Ut as na, Uu as ra, V as ia, Va as aa, Vc as oa, Vd as sa, Vf as ca, Vi as la, Vl as ua, Vn as da, Vo as fa, Vp as pa, Vr as ma, Vs as ha, Vt as ga, Vu as _a, W as va, Wa as ya, Wc as ba, Wd as xa, Wf as Sa, Wi as Ca, Wl as wa, Wn as Ta, Wo as Ea, Wp as Da, Wr as Oa, Ws as ka, Wt as Aa, Wu as ja, X as Ma, Xa as Na, Xc as Pa, Xd as Fa, Xf as Ia, Xi as La, Xl as Ra, Xn as za, Xo as Ba, Xp as Va, Xr as Ha, Xs as Ua, Xt as Wa, Xu as Ga, Y as Ka, Ya as qa, Yc as Ja, Yd as Ya, Yf as Xa, Yi as Za, Yl as Qa, Yn as $a, Yo as eo, Yp as to, Yr as no, Ys as ro, Yt as io, Yu as ao, Z as oo, Za as so, Zc as co, Zd as lo, Zf as uo, Zi as fo, Zl as po, Zn as mo, Zo as ho, Zp as go, Zr as _o, Zs as vo, Zt as yo, Zu as bo, _ as xo, _a as So, _c as Co, _d as wo, _f as To, _i as Eo, _l as Do, _m as Oo, _n as ko, _o as Ao, _p as jo, _r as Mo, _s as No, _t as Po, _u as Fo, a as Io, aa as Lo, ac as Ro, ad as zo, af as Bo, ai as Vo, al as Ho, am as Uo, an as Wo, ao as Go, ap as Ko, ar as qo, as as Jo, at as Yo, au as Xo, b as Zo, ba as Qo, bc as $o, bd as es, bf as ts, bi as ns, bl as rs, bm as is, bn as as, bo as os, bp as ss, br as cs, bs as ls, bt as us, bu as ds, c as fs, ca as ps, cc as ms, cd as hs, cf as gs, ci as _s, cl as vs, cm as ys, cn as bs, co as xs, cp as Ss, cr as Cs, cs as ws, ct as Ts, cu as Es, d as Ds, da as Os, dc as ks, dd as As, df as js, di as Ms, dl as Ns, dm as Ps, dn as G, do as Fs, dp as Is, dr as Ls, ds as Rs, dt as zs, du as Bs, ea as Vs, ec as Hs, ed as Us, ef as Ws, ei as Gs, el as Ks, em as qs, en as Js, eo as Ys, ep as Xs, er as Zs, es as Qs, et as $s, eu as ec, f as tc, fa as nc, fc as rc, fd as ic, ff as ac, fi as oc, fl as sc, fm as cc, fn as lc, fo as uc, fp as dc, fr as fc, fs as pc, ft as mc, fu as hc, g as gc, ga as _c, gc as vc, gd as yc, gf as bc, gi as xc, gl as Sc, gm as Cc, gn as wc, go as Tc, gp as Ec, gr as Dc, gs as Oc, gt as kc, gu as Ac, h as jc, ha as Mc, hc as Nc, hd as Pc, hf as Fc, hi as Ic, hl as Lc, hm as Rc, hn as zc, ho as Bc, hp as Vc, hr as Hc, hs as Uc, ht as Wc, hu as Gc, i as Kc, ia as qc, ic as Jc, id as Yc, if as Xc, ii as Zc, il as Qc, im as $c, in as el, io as tl, ip as nl, ir as rl, is as il, it as al, iu as ol, j as sl, ja as cl, jc as ll, jd as ul, jf as dl, ji as fl, jl as pl, jm as ml, jn as hl, jo as gl, jp as _l, jr as vl, js as yl, jt as bl, ju as xl, k as Sl, ka as Cl, kc as wl, kd as Tl, kf as El, ki as Dl, kl as Ol, km as kl, kn as Al, ko as jl, kp as Ml, kr as Nl, ks as Pl, kt as Fl, ku as Il, l as Ll, la as Rl, lc as zl, ld as Bl, lf as Vl, li as Hl, ll as Ul, lm as Wl, ln as Gl, lo as Kl, lp as ql, lr as Jl, ls as Yl, lt as Xl, lu as Zl, m as Ql, ma as $l, mc as eu, md as tu, mf as nu, mi as ru, ml as iu, mm as au, mn as ou, mo as su, mp as cu, mr as lu, ms as uu, mt as du, mu as fu, n as pu, na as mu, nc as hu, nd as K, nf as gu, ni as _u, nl as vu, nm as yu, nn as bu, no as xu, np as Su, nr as Cu, ns as wu, nt as Tu, nu as Eu, o as Du, oa as Ou, oc as ku, od as Au, of as ju, oi as Mu, ol as Nu, om as Pu, on as Fu, oo as Iu, op as Lu, or as Ru, os as zu, ot as Bu, ou as Vu, p as Hu, pa as Uu, pc as Wu, pd as Gu, pf as Ku, pi as qu, pl as Ju, pm as Yu, pn as Xu, po as Zu, pp as Qu, pr as $u, ps as ed, pt as td, pu as nd, q as rd, qa as id, qc as ad, qd as od, qf as sd, qi as cd, ql as ld, qn as ud, qo as dd, qp as fd, qr as pd, qs as md, qt as hd, qu as gd, r as _d, ra as vd, rc as yd, rd as bd, rf as xd, ri as Sd, rl as Cd, rm as wd, rn as Td, ro as Ed, rp as Dd, rr as Od, rs as kd, rt as Ad, ru as jd, s as Md, sa as Nd, sc as Pd, sd as Fd, sf as Id, si as Ld, sl as Rd, sm as zd, sn as Bd, so as Vd, sp as Hd, sr as Ud, ss as Wd, st as Gd, su as Kd, t as qd, ta as Jd, tc as Yd, td as Xd, tf as q, ti as Zd, tl as Qd, tm as $d, tn as ef, to as tf, tp as nf, tr as rf, ts as af, tt as of, tu as sf, u as cf, ua as lf, uc as uf, ud as df, uf as ff, ui as pf, ul as mf, um as hf, un as gf, uo as _f, up as vf, ur as yf, us as bf, ut as xf, uu as Sf, v as Cf, va as wf, vc as Tf, vd as Ef, vf as Df, vi as Of, vl as kf, vm as Af, vn as jf, vo as Mf, vp as Nf, vr as Pf, vs as Ff, vt as If, vu as Lf, w as Rf, wa as zf, wc as Bf, wd as Vf, wf as Hf, wi as Uf, wl as Wf, wm as Gf, wn as Kf, wo as qf, wp as Jf, wr as Yf, ws as Xf, wt as Zf, wu as Qf, x as $f, xa as ep, xc as tp, xd as np, xf as rp, xi as ip, xl as ap, xm as op, xn as sp, xo as cp, xp as lp, xr as up, xs as dp, xt as fp, xu as pp, y as mp, ya as hp, yc as gp, yd as _p, yf as vp, yi as yp, yl as bp, ym as xp, yn as Sp, yo as Cp, yp as wp, yr as Tp, ys as Ep, yt as Dp, yu as Op, z as kp, za as Ap, zc as jp, zd as Mp, zf as Np, zi as Pp, zl as Fp, zn as Ip, zo as Lp, zp as Rp, zr as zp, zs as Bp, zt as Vp, zu as Hp } from "../src-BcBBUMTP.js";
|
|
2
|
+
import { a as Up, i as Wp, n as Gp, o as Kp, r as qp, s as Jp, t as Yp } from "../webcomponent-BS5WnkDO.js";
|
|
3
|
+
import { defineComponent as Xp, h as Zp, inject as Qp, onMounted as $p, onUnmounted as J, provide as em, ref as Y, shallowRef as X, watch as Z } from "vue";
|
|
4
4
|
//#region src/integrations/vue.ts
|
|
5
5
|
function Q(e, t) {
|
|
6
6
|
let n = X(null), r = Y(!1);
|
|
7
|
-
return
|
|
8
|
-
e.value && (n.value = new
|
|
7
|
+
return $p(() => {
|
|
8
|
+
e.value && (n.value = new W(e.value, t), r.value = !0);
|
|
9
9
|
}), J(() => {
|
|
10
10
|
n.value && (n.value.dispose(), n.value = null, r.value = !1);
|
|
11
11
|
}), Z(e, (e, i) => {
|
|
12
|
-
i && n.value && (n.value.dispose(), n.value = null, r.value = !1), e && (n.value = new
|
|
12
|
+
i && n.value && (n.value.dispose(), n.value = null, r.value = !1), e && (n.value = new W(e, t), r.value = !0);
|
|
13
13
|
}), {
|
|
14
14
|
scene: n,
|
|
15
15
|
isReady: r
|
|
16
16
|
};
|
|
17
17
|
}
|
|
18
|
-
function
|
|
18
|
+
function tm(e, t) {
|
|
19
19
|
let n = X(null);
|
|
20
20
|
return Z(e, (e, r) => {
|
|
21
21
|
r && n.value && r.remove(n.value), e && (n.value ||= t(), e.add(n.value));
|
|
@@ -23,7 +23,7 @@ function Cp(e, t) {
|
|
|
23
23
|
e.value && n.value && e.value.remove(n.value), n.value = null;
|
|
24
24
|
}), n;
|
|
25
25
|
}
|
|
26
|
-
function
|
|
26
|
+
function nm(e) {
|
|
27
27
|
let t = Y(!1);
|
|
28
28
|
return {
|
|
29
29
|
play: async (...n) => {
|
|
@@ -49,14 +49,14 @@ function wp(e) {
|
|
|
49
49
|
isPlaying: t
|
|
50
50
|
};
|
|
51
51
|
}
|
|
52
|
-
function
|
|
52
|
+
function rm(e, t) {
|
|
53
53
|
Z(e, (e, n) => {
|
|
54
54
|
n && n.removeUpdater(t), e && e.addUpdater(t);
|
|
55
55
|
}, { immediate: !0 }), J(() => {
|
|
56
56
|
e.value && e.value.removeUpdater(t);
|
|
57
57
|
});
|
|
58
58
|
}
|
|
59
|
-
var $ = Symbol("manimweb-scene"),
|
|
59
|
+
var $ = Symbol("manimweb-scene"), im = Xp({
|
|
60
60
|
name: "ManimScene",
|
|
61
61
|
props: {
|
|
62
62
|
width: {
|
|
@@ -84,7 +84,7 @@ var $ = Symbol("manimweb-scene"), Ep = vp({
|
|
|
84
84
|
default: void 0
|
|
85
85
|
}
|
|
86
86
|
},
|
|
87
|
-
emits: { ready: (e) => e instanceof
|
|
87
|
+
emits: { ready: (e) => e instanceof W },
|
|
88
88
|
setup(e, { emit: t, slots: n }) {
|
|
89
89
|
let r = Y(null), { scene: i, isReady: a } = Q(r, {
|
|
90
90
|
width: e.width,
|
|
@@ -96,7 +96,7 @@ var $ = Symbol("manimweb-scene"), Ep = vp({
|
|
|
96
96
|
});
|
|
97
97
|
return Z(a, (e) => {
|
|
98
98
|
e && i.value && t("ready", i.value);
|
|
99
|
-
}),
|
|
99
|
+
}), em($, i), () => Zp("div", {
|
|
100
100
|
ref: r,
|
|
101
101
|
style: {
|
|
102
102
|
width: `${e.width}px`,
|
|
@@ -106,9 +106,9 @@ var $ = Symbol("manimweb-scene"), Ep = vp({
|
|
|
106
106
|
}, n.default?.());
|
|
107
107
|
}
|
|
108
108
|
});
|
|
109
|
-
function
|
|
110
|
-
return
|
|
109
|
+
function am() {
|
|
110
|
+
return Qp($, Y(null));
|
|
111
111
|
}
|
|
112
|
-
var
|
|
112
|
+
var om = { install(e) {} };
|
|
113
113
|
//#endregion
|
|
114
|
-
export { st as Add, Fc as AddTextLetterByLetter, la as AddTextWordByWord, Ld as Angle, ea as AnimateProxy, gd as AnimatedBoundary, wo as Animation, c as AnimationGroup, Tt as AnnotationDot, At as AnnularSector, yn as Annulus, $i as ApplyComplexFunction, yt as ApplyFunction, zi as ApplyMatrix, pa as ApplyMethod, Bd as ApplyPointwiseFunction, rs as ApplyPointwiseFunctionToCenter, Zn as ApplyWave, v as Arc, $f as ArcBetweenPoints, Gn as ArcBrace, Kn as ArcPolygon, br as ArcPolygonFromArcs, Nc as Arrow, ei as Arrow3D, Gl as ArrowCircleFilledTip, Ju as ArrowCircleTip, kc as ArrowSquareFilledTip, Do as ArrowSquareTip, ou as ArrowTip, cd as ArrowTriangleFilledTip, es as ArrowTriangleTip, ee as ArrowVectorField, Uf as AudioManager, ri as Axes, Qi as BLACK, vt as BLUE, Ri as BLUE_A, fa as BLUE_B, it as BLUE_C, sn as BLUE_D, Iu as BLUE_E, ns as BOLD, yl as BOOK, Vo as BackgroundRectangle, tu as BarChart, Di as Blink, Uu as BooleanResult, Wa as Box3D, yr as Brace, Ve as BraceBetweenPoints, kt as BraceLabel, vn as BraceText, un as Broadcast, Io as BulletedList, In as Camera2D, wr as Camera2DFrame, Xn as Camera3D, Ra as CameraAnimateProxy, wa as CameraFrame, zd as CapStyleType, xs as ChangeDecimalToValue, jd as ChangeSpeed, Ys as ChangingDecimal, Wt as Circle, ip as Circumscribe, bc as Clickable, ve as ClockwiseTransform, Kd as Code, wt as ComplexHomotopy, rd as ComplexPlane, Bl as ComplexValueTracker, Bu as Cone, dp as Controls, jl as ConvexHull, fr as ConvexHull3D, lr as CounterclockwiseTransform, No as Create, Tf as Cross, Aa as Cube, he as CubicBezier, Mn as CurvedArrow, Uc as CurvedDoubleArrow, S as CurvesAsSubmobjects, hc as Cutout, ol as CyclicReplace, Xt as Cylinder, Kt as DARKER_GRAY, Ba as DARK_BLUE, Ea as DARK_BROWN, eo as DARK_GRAY, Gt as DEFAULT_ANIMATION_DURATION, gs as DEFAULT_ARROW_TIP_LENGTH, ps as DEFAULT_ASPECT_RATIO, Ss as DEFAULT_COLOR_SCHEME, Us as DEFAULT_DASH_LENGTH, Su as DEFAULT_DOT_RADIUS, za as DEFAULT_FONT_SIZE, Ta as DEFAULT_FPS, $a as DEFAULT_FRAME_HEIGHT, Fr as DEFAULT_FRAME_WIDTH, r as DEFAULT_MOBJECT_TO_EDGE_BUFFER, Os as DEFAULT_MOBJECT_TO_MOBJECT_BUFFER, wd as DEFAULT_PIXEL_HEIGHT, ql as DEFAULT_PIXEL_WIDTH, Nl as DEFAULT_POINTWISE_FUNCTION_RUN_TIME, _c as DEFAULT_POINT_DENSITY_1D, rc as DEFAULT_POINT_DENSITY_2D, ho as DEFAULT_SMALL_DOT_RADIUS, Xu as DEFAULT_STROKE_WIDTH, $d as DEFAULT_WAIT_TIME, Vf as DEGREES, xr as DL, Ue as DOWN, jt as DR, rl as DashedLine, or as DashedVMobject, jf as DecimalMatrix, of as DecimalNumber, qr as DecimalTable, Zs as Degrees, xi as DiGraph, xd as DiceFace, $t as Difference, na as Dodecahedron, df as Dot, ll as Dot3D, jo as DoubleArrow, Wf as Draggable, fu as DrawBorderThenFill, ms as Elbow, Jr as Ellipse, qa as Exclusion, to as FadeIn, Va as FadeOut, go as FadeToColor, Ge as FadeTransform, Nt as FadeTransformPieces, ta as Flash, cl as FocusOn, Bs as FullScreenFadeRectangle, yu as FullScreenRectangle, cp as FunctionGraph, Ir as GOLD, i as GOLD_A, Ps as GOLD_B, Ad as GOLD_C, $l as GOLD_D, td as GOLD_E, Ic as GRAY, Po as GRAY_A, pu as GRAY_B, hd as GRAY_C, ss as GRAY_D, wl as GRAY_E, Wd as GREEN, bs as GREEN_A, Js as GREEN_B, Du as GREEN_C, Rl as GREEN_D, Sc as GREEN_E, me as GenericGraph, Tu as GifExporter, ad as GlyphVMobject, Oe as Graph, Cn as Group, Or as GrowArrow, Jl as GrowFromCenter, Xe as GrowFromEdge, Rt as GrowFromPoint, Uo as HEAVY, Hn as HSV, Ii as Hexagon, Wi as Homotopy, vo as Hoverable, bn as IN, Df as ITALIC, St as Icosahedron, Ec as ImageMobject, tr as ImplicitFunction, Vi as Indicate, Jf as Integer, mi as IntegerMatrix, Qf as IntegerTable, ac as InteractiveScene, Na as Intersection, jc as LARGE_BUFF, Yr as LEFT, ui as LIGHT, cc as LIGHTER_GRAY, bo as LIGHT_BROWN, rf as LIGHT_GRAY, Kf as LIGHT_PINK, zf as Label, Gi as LabeledArrow, ya as LabeledDot, dt as LabeledLine, mn as LabeledPolygram, Bn as LaggedStart, mr as LaggedStartMap, Si as LargeDot, yc as Lighting, fd as Line, w as Line3D, P as LineJointType, Ze as LinearBase, Yl as LinearTransformationScene, zt as LogBase, Jo as MANIM_BACKGROUND, Mf as MAROON, hi as MAROON_A, z as MAROON_B, vf as MAROON_C, ki as MAROON_D, Ie as MAROON_E, pf as MEDIUM, ko as MED_LARGE_BUFF, cu as MED_SMALL_BUFF, Xs as MONOKAI_COLOR_SCHEME, Eo as MandelbrotSet, Fi as ManimBanner, nr as ManimColor, Ep as ManimScene, _p as ManimSceneElement, Op as ManimWebPlugin, Qa as MappingCamera, hu as MarkdownText, fl as MarkupText, a as MasterTimeline, _ as MathTable, we as MathTex, Bc as MathTexImage, ls as MathTexPart, hr as MathTexSVG, Xo as MathTypst, R as Matrix, Ef as Mobject, sd as Mobject1D, au as Mobject2D, Br as Mobject3D, _f as MobjectMatrix, Yi as MobjectTable, Oi as ModelMobject, Ma as MoveAlongPath, Jt as MoveToTarget, Hr as MoveToTargetPosition, Pr as MovingCamera, is as MovingCameraScene, n as MultiCamera, Au as Munits, wi as NORMAL, Oc as NewtonFractal, Ke as NullRenderer, D as NumberLine, kr as NumberPlane, je as OBLIQUE, Se as ORANGE, ep as ORIGIN, y as OUT, Hi as Octahedron, Fl as OrbitControls, Id as PGroup, _e as PI, pr as PINK, fc as PMobject, ul as PURE_BLUE, d as PURE_GREEN, Xc as PURE_RED, zn as PURPLE, $n as PURPLE_A, Dr as PURPLE_B, Ye as PURPLE_C, Lt as PURPLE_D, Tn as PURPLE_E, p as Paragraph, Vn as ParametricFunction, Je as ParametricSurface, ua as Pentagon, Vl as Percent, va as PhaseFlow, Tc as Pixels, fp as PlaybackControls, Zl as Player, $u as PlayerController, Pc as PlayerUI, $o as PointCloudDot, gl as PointMobject, Rc as PolarPlane, nt as Polygon, gt as Polygram, ga as Polyhedron, u as Prism, l as Pulse, ti as RED, op as RED_A, T as RED_B, ra as RED_C, Ct as RED_D, Ui as RED_E, Ar as RGBA, Zi as RIGHT, Qe as RandomColorGenerator, K as Rectangle, an as RegularPolygon, tc as RegularPolygram, zu as Remove, md as RemoveTextLetterByLetter, Pt as Renderer, Ha as ReplacementTransform, ef as Restore, Vs as RightAngle, lu as Rotate, Yt as Rotating, po as RoundedRectangle, cr as SCALE_FACTOR_PER_FONT_POINT, al as SEMIBOLD, ue as SEMILIGHT, ud as SMALL_BUFF, Gc as START_X, Pn as START_Y, se as SVGMobject, qu as SampleSpace, Zu as Scale, Dn as ScaleBase, Hf as ScaleInPlace, q as Scene, Go as SceneStateManager, Al as ScreenRectangle, He as Sector, _o as SelectionManager, ne as Shift, L as ShowCreationThenDestruction, tt as ShowIncreasingSubsets, rn as ShowPartial, qe as ShowPassingFlash, be as ShowPassingFlashWithThinningStrokeWidth, Nu as ShowSubmobjectsOneByOne, Wo as ShrinkToCenter, El as SingleStringMathTex, ke as SmallDot, ut as SmoothedVectorizedHomotopy, Ul as SpecialThreeDScene, io as Sphere, En as SpinInFromNothing, Ut as SpiralIn, As as SplitScreenCamera, Gs as Square, Zd as Star, _l as StealthTip, Is as StreamLines, f as Succession, W as Surface, W as Surface3D, It as SurfacePresets, ci as SurroundingRectangle, de as Swap, Jn as TAU, _a as TEAL, lt as TEAL_A, fn as TEAL_B, Vu as TEAL_C, Zt as TEAL_D, Ga as TEAL_E, Sr as THIN, qn as THREE, ht as Table, bu as TangentLine, ce as TangentialArc, ct as Tetrahedron, Re as Tex, rt as TexFontTemplates, on as TexTemplate, Fu as TexTemplateLibrary, Rs as Text, ru as TextGlyphGroup, Qn as TexturedSurface, Rn as ThreeDAxes, Ed as ThreeDCamera, wu as ThreeDScene, Yc as ThreeDVMobject, sl as Timeline, Xi as TipableVMobject, _d as Title, dn as Torus, cs as TracedPath, Oa as Transform, Of as TransformAnimations, Sn as TransformFromCopy, ic as TransformMatchingAbstractBase, Ws as TransformMatchingShapes, Cu as TransformMatchingTex, Pu as Triangle, Ns as TypeWithCursor, Pf as Typst, _t as UL, We as ULTRABOLD, Mt as ULTRAHEAVY, xn as ULTRALIGHT, Li as UP, da as UR, os as Uncreate, M as Underline, so as Union, aa as UnitInterval, kd as UntypeWithCursor, Cl as Unwrite, yf as UpdateFromAlphaFunc, Le as UpdateFromFunc, Qr as VDict, Ml as VGroup, gc as VMobject, Hc as VMobjectFromSVGPath, wc as ValueTracker, ku as Variable, uu as Vector, ap as Vector3D, Md as VectorField, Qc as VectorFieldVector, Qu as VectorScene, rp as VectorizedPoint, vs as VideoExporter, fo as VideoMobject, ja as WHITE, Ua as Wait, Mo as WebCodecsExporter, wn as Wiggle, Af as WiggleOutThenIn, Ud as Write, Xr as X_AXIS, ao as YELLOW, Vr as YELLOW_A, te as YELLOW_B, js as YELLOW_C, Dd as YELLOW_D, Xl as YELLOW_E, tp as Y_AXIS, b as Z_AXIS, xl as ZoomDisplayPopOut, Vd as ZoomedScene, ka as add, ys as addTextLetterByLetter, La as addTextWordByWord, li as addVec, dc as adjacentNTuples, Co as adjacentPairs, sf as allElementsAreInstances, qf as always, gi as alwaysRedraw, Cc as alwaysRotate, lc as alwaysShift, Vc as angleAxisFromQuaternion, An as angleBetweenVectors, Wn as angleOfVector, Tl as animatedBoundary, qc as animationGroup, at as applyComplexFunction, cn as applyFunction, Lu as applyMatrix, qt as applyMethod, _s as applyPointwiseFunction, bl as applyPointwiseFunctionToCenter, Tr as applyWave, Qs as areKatexStylesLoaded, Yo as assertIsMobjectMethod, On as averageColor, fs as bezier, zs as bezierRemap, oi as binarySearch, Xd as binaryTree, Rf as bipartiteGraph, Pe as blink, ro as broadcast, Pd as buildStyledTextLines, vr as cartesianToSpherical, Be as centerOfMass, Ou as changeDecimalToValue, eu as changeSpeed, zl as changingDecimal, A as choose, C as circumscribe, bt as clearAnimationOverrides, lf as clip, De as clockwisePath, Kc as clockwiseTransform, nc as colorGradient, ii as colorToIntRgb, lp as colorToIntRgba, O as colorToRgb, oa as colorToRgba, Ot as compassDirections, Bo as completeGraph, _n as complexFuncToR3Func, pn as complexHomotopy, Kr as complexToR3, uc as complexValueTracker, cf as compose, ar as computeCircularLayout, nl as computeLayout, Yf as concatenateLists, pe as counterclockwisePath, Fn as counterclockwiseTransform, qs as create, Wl as createDiceRow, mc as createFadeToBlack, ec as createFadeToWhite, Il as createGifExporter, Ks as createVideoExporter, du as createWebCodecsExporter, N as cross, N as crossVec, Zf as cross2d, xo as cycleAnimation, wf as cycleGraph, Yn as cyclicReplace, kf as deserializeMobject, Fe as detectModelFormat, Ur as difference, ff as dotVec, Xf as doubleSmooth, pd as downloadBlob, Eu as drawBorderThenFill, Ho as earclipTriangulation, G as easeIn, G as easeInCubic, If as easeInBack, yi as easeInBounce, fe as easeInCirc, Sf as easeInElastic, Ni as easeInExpo, U as easeInOut, U as easeInOutCubic, Ee as easeInOutBack, _r as easeInOutBounce, ml as easeInOutCirc, h as easeInOutElastic, el as easeInOutExpo, Un as easeInOutQuad, rr as easeInOutQuart, jr as easeInOutQuint, $e as easeInOutSine, Vt as easeInQuad, kn as easeInQuart, ai as easeInQuint, up as easeInSine, k as easeOut, k as easeOutCubic, sa as easeOutBack, Dt as easeOutBounce, qi as easeOutCirc, xa as easeOutElastic, pt as easeOutExpo, gn as easeOutQuad, Gu as easeOutQuart, tn as easeOutQuint, Ya as easeOutSine, nd as emphasizeRegion, ju as ensureKatexStyles, re as exclusion, Fa as exponentialDecay, as as exportAndDownloadPNG, Sl as exportFramePNG, Hd as exportPNGSequence, us as extractMobjectFamilyMembers, Nf as fAlways, Lr as fadeIn, Da as fadeOut, di as fadeToColor, Zr as fadeTransform, np as fadeTransformPieces, g as findIntersection, xt as flash, Jc as focusOn, Ku as get3dVmobEndCorner, Dc as get3dVmobEndCornerIndex, To as get3dVmobEndCornerUnitNormal, iu as get3dVmobGradientStartAndEndPoints, od as get3dVmobStartCorner, Qo as get3dVmobStartCornerIndex, hl as get3dVmobStartCornerUnitNormal, Fd as get3dVmobUnitNormal, Bi as getAnimationOverride, nf as getDetText, Wr as getFeatureFlags, Bt as getShadedRgb, Bf as getSmoothCubicBezierHandlePoints, Ji as getUnitNormal, mt as getWindingNumber, si as gridGraph, ni as growArrow, Mc as growFromCenter, sp as growFromEdge, E as growFromPoint, ma as hasAnimationOverride, Zo as hashObj, Et as hexToRgb, Hu as homotopy, Ki as hsvToRgb, Dl as indexLabels, ha as indicate, mo as integerInterpolate, vu as interpolate, ba as interpolateColor, Es as intersection, kl as inverseInterpolate, ft as invertColor, pc as isClosed, ie as isFeatureEnabled, Ro as isMathJaxLoaded, _i as isTypstLoaded, _u as katexCanRender, er as laggedStart, dl as laggedStartMap, Ci as lengthVec, Pi as lineIntersection, lo as linear, Lc as linearSpeedRamp, Gr as lingering, Ae as linspace, Ff as listDifferenceUpdate, vi as listUpdate, H as listify, mp as logger, B as maintainPositionRelativeTo, oc as makeClickable, Ko as makeDraggable, xf as makeEven, Mi as makeEvenByCycling, tf as makeHoverable, pp as manimElementInternals, Ts as masterTimeline, $s as matchInterpolate, Gf as matrixToMobject, qo as matrixToTexString, uo as mid, ca as midpoint, oo as moveAlongPath, no as moveToTarget, ks as moveToTargetPosition, et as normSquared, nn as normalize, ge as normalizeVec, ae as notQuiteThere, gp as onLog, sr as orientation2D, il as orthonormalFrame, ot as overrideAnimate, ln as overrideAnimation, Jd as parseSVGPathData, Qd as partialBezierPoints, ir as pathAlongArc, tl as pathAlongCircles, j as pathGraph, Mu as perpendicularBisector, Qt as phaseFlow, Yd as pointLiesOnBezier, ze as powerset, yd as preloadMathJax, V as preloadTypst, Ru as prepareAnimation, qd as printFamily, Lf as proportionsAlongBezierCurveForPoint, Ln as pulse, Ht as quaternionConjugate, Ia as quaternionFromAngleAxis, Sa as quaternionMult, Xa as r3ToComplex, hn as randomBrightColor, Wu as randomColor, bd as registerFont, hp as registerManimElement, Mr as regularVertices, zr as remove, Te as removeListRedundancies, gr as removeNones, Ll as removeTextLetterByLetter, ds as renderLatexToSVG, bf as renderTypstToSVG, Rr as replacementTransform, Ms as resetFeatureFlags, F as restore, fi as restoreMobjectState, Cs as restructureListToExcludeCertainFamilyMembers, Ds as reverse, en as rgbToColor, Ja as rgbToHex, Pa as rgbToHsv, co as rgbaToColor, dd as rotate, e as rotateVector, s as rotating, Ls as rotationAboutZ, Nd as rotationMatrix, nu as rotationMatrixTranspose, Cd as runningStart, Kl as rushFrom, Yu as rushInto, Fo as rushRegion, I as saveMobjectState, Ao as scale, mf as scaleInPlace, le as scaleVec, hf as serializeMobject, Od as setFeatureFlags, Hl as setKatexStylesheetUrl, Ol as setMathJaxScriptUrl, xe as setModelLoaderFactory, ji as setTypstCompiler, Td as shift, id as shoelace, zc as shoelaceDirection, gf as showCreationThenDestruction, Ca as showIncreasingSubsets, Za as showPartial, Ft as showPassingFlash, dr as showPassingFlashWithThinningStrokeWidth, Nr as showSubmobjectsOneByOne, Ti as shrinkToCenter, bi as sigmoid, Ac as slowInto, Oo as smooth, mu as smoothSpeedCurve, Ka as smoothedVectorizedHomotopy, su as smoothererstep, ld as smootherstep, ts as smoothstep, Ei as snapshotFromJSON, Ne as snapshotToJSON, Lo as sphericalToCartesian, ia as spinInFromNothing, t as spiralIn, zo as splitBezier, vl as squishRateFunc, uf as starGraph, ye as stateFromJSON, ur as stateToJSON, Rd as stepFunction, oe as straightPath, pl as stretchArrayToLength, Wc as subVec, Cf as subdivideBezier, Zc as succession, jn as svgMobject, ws as svgToVMobjects, Cr as swap, Er as texturedSphere, hs as thereAndBack, Hs as thereAndBackWithPause, gu as thickDiagonal, Gd as tracedPath, o as transform, Me as transformAnimations, x as transformFromCopy, Pl as transformMatchingShapes, vc as transformMatchingTex, m as tuplify, af as turnAnimationIntoUpdater, Ql as typeWithCursor, xc as uncreate, Sd as union, $c as uniqChain, Nn as unitPerpendicularTo, ed as untypeWithCursor, sc as unwrite, Ai as updateFromAlphaFunc, Ce as updateFromFunc, wp as useAnimation, Dp as useInjectedScene, Cp as useMobject, Q as useScene, Tp as useUpdater, So as valueTracker, Fs as wait, $r as wiggle, pi as wiggleOutThenIn, xu as wiggleRate, yo as write, vd as zToVector };
|
|
114
|
+
export { $a as Add, Zu as AddTextLetterByLetter, t as AddTextWordByWord, gp as Angle, jd as AnimateProxy, Ls as AnimatedBoundary, A as AnimatedImageMobject, ur as Animation, mn as AnimationGroup, vo as AnnotationDot, lt as AnnularSector, un as Annulus, cd as ApplyComplexFunction, Qt as ApplyFunction, Za as ApplyMatrix, La as ApplyMethod, ru as ApplyPointwiseFunction, oc as ApplyPointwiseFunctionToCenter, On as ApplyWave, Ja as Arc, Yt as ArcBetweenPoints, St as ArcBrace, Ct as ArcPolygon, Ki as ArcPolygonFromArcs, rs as Arrow, dd as Arrow3D, ks as ArrowCircleFilledTip, rc as ArrowCircleTip, Wu as ArrowSquareFilledTip, eu as ArrowSquareTip, Nc as ArrowTip, vc as ArrowTriangleFilledTip, Co as ArrowTriangleTip, ws as ArrowVectorField, $e as AudioManager, md as Axes, wp as BLACK, ut as BLEND_MODES, ss as BLUE, lp as BLUE_A, wi as BLUE_B, z as BLUE_C, Jf as BLUE_D, zi as BLUE_E, y as BOLD, ca as BOOK, wl as BackgroundRectangle, Rs as BarChart, Al as Blink, hu as BooleanResult, il as Box3D, Gi as Brace, ya as BraceBetweenPoints, ct as BraceLabel, ln as BraceText, za as Broadcast, uu as BulletedList, $t as Camera2D, Ra as Camera2DFrame, Qa as Camera3D, Qc as CameraAnimateProxy, Ho as CameraFrame, Tt as CapStyleType, Hc as ChangeDecimalToValue, qo as ChangeSpeed, Dc as ChangingDecimal, Cd as Circle, Zi as Circumscribe, Sp as Clickable, tr as ClockwiseTransform, Ep as Code, _n as ComplexHomotopy, pc as ComplexPlane, me as ComplexValueTracker, wu as Cone, Up as Controls, j as ConvexHull, kn as ConvexHull3D, jr as CounterclockwiseTransform, su as Create, ue as Cross, Jo as Cube, It as CubicBezier, oa as CurvedArrow, _ as CurvedDoubleArrow, Eu as CurvesAsSubmobjects, Bf as Cutout, Qe as CyclicReplace, kd as Cylinder, He as DARKER_GRAY, De as DARK_BLUE, xr as DARK_BROWN, Ml as DARK_GRAY, Ie as DEFAULT_ANIMATION_DURATION, Ji as DEFAULT_ARROW_TIP_LENGTH, So as DEFAULT_ASPECT_RATIO, ls as DEFAULT_COLOR_SCHEME, Sa as DEFAULT_DASH_LENGTH, dt as DEFAULT_DOT_RADIUS, xe as DEFAULT_FONT_SIZE, hr as DEFAULT_FPS, El as DEFAULT_FRAME_HEIGHT, fe as DEFAULT_FRAME_WIDTH, dl as DEFAULT_MOBJECT_TO_EDGE_BUFFER, zn as DEFAULT_MOBJECT_TO_MOBJECT_BUFFER, er as DEFAULT_PIXEL_HEIGHT, Ar as DEFAULT_PIXEL_WIDTH, fn as DEFAULT_POINTWISE_FUNCTION_RUN_TIME, sd as DEFAULT_POINT_DENSITY_1D, Zt as DEFAULT_POINT_DENSITY_2D, Xa as DEFAULT_SMALL_DOT_RADIUS, Ze as DEFAULT_STROKE_WIDTH, Ia as DEFAULT_WAIT_TIME, uo as DEGREES, ac as DL, Ku as DOWN, nu as DR, ni as DashedLine, Cn as DashedVMobject, l as DecimalMatrix, ke as DecimalNumber, id as DecimalTable, mc as Degrees, Zn as DiGraph, Nd as DiceFace, yd as Difference, Ba as Dodecahedron, Qn as Dot, ci as Dot3D, ap as DoubleArrow, L as Draggable, Bc as DrawBorderThenFill, $o as Elbow, ad as Ellipse, Jc as Exclusion, vd as FadeIn, Jd as FadeOut, P as FadeToColor, la as FadeTransform, Et as FadeTransformPieces, mt as Flash, ir as FocusOn, wf as FullScreenFadeRectangle, hp as FullScreenRectangle, an as FunctionGraph, u as GOLD, _l as GOLD_A, Gn as GOLD_B, or as GOLD_C, Fr as GOLD_D, nt as GOLD_E, Ut as GRAY, An as GRAY_A, li as GRAY_B, Rp as GRAY_C, w as GRAY_D, pa as GRAY_E, At as GREEN, $i as GREEN_A, Da as GREEN_B, gt as GREEN_C, gn as GREEN_D, fd as GREEN_E, Je as GenericGraph, Xu as GifExporter, Op as GlyphVMobject, aa as GradientVMobject, Dr as Graph, ee as Group, ui as GrowArrow, Mu as GrowFromCenter, zp as GrowFromEdge, T as GrowFromPoint, Wr as HEAVY, Jn as HSV, Hr as Hexagon, pd as Homotopy, sp as Hoverable, Fc as IN, i as ITALIC, ho as Icosahedron, xl as ImageMobject, Mt as ImplicitFunction, ud as Indicate, Cr as Integer, gl as IntegerMatrix, Jt as IntegerTable, Vn as InteractiveScene, Ro as Intersection, Rt as LARGE_BUFF, bc as LEFT, Xs as LIGHT, nn as LIGHTER_GRAY, to as LIGHT_BROWN, Va as LIGHT_GRAY, go as LIGHT_PINK, pr as Label, Zr as LabeledArrow, ae as LabeledDot, Hs as LabeledLine, Yd as LabeledPolygram, Wt as LaggedStart, Kn as LaggedStartMap, Or as LargeDot, pl as Lighting, F as Line, eo as Line3D, nf as LineJointType, ka as LinearBase, kf as LinearTransformationScene, vt as LogBase, Yr as MANIM_BACKGROUND, re as MAROON, qs as MAROON_A, $d as MAROON_B, yu as MAROON_C, wd as MAROON_D, $c as MAROON_E, Su as MEDIUM, Tn as MED_LARGE_BUFF, ii as MED_SMALL_BUFF, dp as MONOKAI_COLOR_SCHEME, Os as MandelbrotSet, Vr as ManimBanner, lr as ManimColor, im as ManimScene, Yp as ManimSceneElement, om as ManimWebPlugin, Nu as MappingCamera, Uc as MarkdownText, di as MarkupText, Lo as MasterTimeline, qa as MathTable, Gt as MathTex, ds as MathTexImage, No as MathTexPart, Mn as MathTexSVG, Pl as MathTypst, Wn as Matrix, xa as Mobject, Uu as Mobject1D, nc as Mobject2D, Wd as Mobject3D, ar as MobjectMatrix, Na as MobjectTable, Pr as ModelMobject, ko as MovablePoint, Gs as MoveAlongPath, Sf as MoveToTarget, _u as MoveToTargetPosition, Rd as MovingCamera, Wf as MovingCameraScene, vs as MultiCamera, td as Munits, Dd as NORMAL, lf as NewtonFractal, po as NullRenderer, ro as NumberLine, ta as NumberPlane, nl as OBLIQUE, Uo as ORANGE, To as ORIGIN, Df as OUT, Jr as Octahedron, o as OrbitControls, _c as PGroup, Ko as PI, Pu as PINK, Yn as PMobject, zd as PURE_BLUE, ys as PURE_GREEN, Wl as PURE_RED, hf as PURPLE, Ps as PURPLE_A, cc as PURPLE_B, Yu as PURPLE_C, au as PURPLE_D, Rc as PURPLE_E, Bp as Paragraph, ha as ParametricFunction, Ea as ParametricSurface, n as Pentagon, du as Percent, rn as PhaseFlow, Wc as Pixels, Wp as PlaybackControls, bu as Player, Td as PlayerController, el as PlayerUI, $l as PointCloudDot, Mc as PointMobject, ed as PolarPlane, Ks as Polygon, co as Polygram, ne as Polyhedron, Lp as Prism, Nr as Pulse, Cc as RED, Oo as RED_A, Af as RED_B, xp as RED_C, is as RED_D, op as RED_E, Rr as RGBA, vp as RIGHT, at as RandomColorGenerator, Ce as Rectangle, Qd as RegularPolygon, ji as RegularPolygram, mo as Remove, Tc as RemoveTextLetterByLetter, Kr as Renderer, Bs as ReplacementTransform, Uf as Restore, tp as RightAngle, pf as Rotate, qr as Rotating, Pe as RoundedRectangle, Lu as SCALE_FACTOR_PER_FONT_POINT, Hd as SEMIBOLD, Ss as SEMILIGHT, Np as SMALL_BUFF, ql as START_X, vf as START_Y, ti as SVGMobject, Rl as SampleSpace, Ld as Scale, vn as ScaleBase, Pi as ScaleInPlace, W as Scene, Bt as SceneStateManager, Qo as ScreenRectangle, ba as Sector, nr as SelectionManager, Sd as Shift, Te as ShowCreationThenDestruction, Ys as ShowIncreasingSubsets, tf as ShowPartial, Ip as ShowPassingFlash, hl as ShowPassingFlashWithThinningStrokeWidth, xu as ShowSubmobjectsOneByOne, Le as ShrinkToCenter, Ff as SingleStringMathTex, zc as Slider, Ye as SmallDot, no as SmoothedVectorizedHomotopy, pu as SpecialThreeDScene, zu as Sphere, ma as SpinInFromNothing, Ed as SpiralIn, Ul as SplitScreenCamera, _r as Square, ye as Star, Tf as StealthTip, Yl as StreamLines, Ir as Succession, U as Surface, U as Surface3D, ht as SurfacePresets, ll as SurroundingRectangle, zt as Swap, Is as TAU, xi as TEAL, I as TEAL_A, Gf as TEAL_B, Ii as TEAL_C, ze as TEAL_D, we as TEAL_E, dc as THIN, js as THREE, so as Table, gi as TangentLine, jp as TangentialArc, Qs as Tetrahedron, it as Tex, N as TexFontTemplates, Hf as TexTemplate, Ni as TexTemplateLibrary, Ac as Text, Lf as TextGlyphGroup, kt as TexturedSurface, fa as ThreeDAxes, mf as ThreeDCamera, Ol as ThreeDScene, C as ThreeDVMobject, pt as Timeline, Pa as TipableVMobject, Oc as Title, af as Torus, fc as TracedPath, hc as Transform, Se as TransformAnimations, Yi as TransformFromCopy, yi as TransformMatchingAbstractBase, xc as TransformMatchingCode, Of as TransformMatchingShapes, yp as TransformMatchingTex, vu as Triangle, Kl as TypeWithCursor, f as Typst, ts as UL, Qu as ULTRABOLD, cu as ULTRAHEAVY, Vc as ULTRALIGHT, rp as UP, vi as UR, Ao as Uncreate, Ln as Underline, ku as Union, Ua as UnitInterval, _f as UntypeWithCursor, Mf as Unwrite, Sr as UpdateFromAlphaFunc, d as UpdateFromFunc, ec as VDict, wn as VGroup, ri as VMobject, Ap as VMobjectFromSVGPath, Xf as ValueTracker, Ei as Variable, bi as Vector, tn as Vector3D, bf as VectorField, E as VectorFieldVector, bp as VectorScene, sf as VectorizedPoint, G as VideoExporter, Ai as VideoMobject, sc as Voiceover, Ns as VoiceoverScene, vr as WHITE, te as Wait, Wo as WebCodecsExporter, Ju as WebSpeechSynthesizer, da as Wiggle, Li as WiggleOutThenIn, Cp as Write, Ec as X_AXIS, kl as YELLOW, s as YELLOW_A, ml as YELLOW_B, Hn as YELLOW_C, rr as YELLOW_D, Mr as YELLOW_E, jo as Y_AXIS, Nf as Z_AXIS, Fi as ZoomDisplayPopOut, Re as ZoomedScene, Zs as add, os as addTextLetterByLetter, tl as addTextWordByWord, Ws as addVec, kc as adjacentNTuples, Po as adjacentPairs, If as allElementsAreInstances, B as always, Ue as alwaysRedraw, Tp as alwaysRotate, cs as alwaysShift, sl as angleAxisFromQuaternion, Fn as angleBetweenVectors, Xn as angleOfVector, $u as animatedBoundary, ld as animationGroup, dn as applyBlendMode, fo as applyComplexFunction, Gr as applyFunction, a as applyMatrix, Vs as applyMethod, Ic as applyPointwiseFunction, qu as applyPointwiseFunctionToCenter, si as applyWave, Tr as areKatexStylesLoaded, Yf as assertIsMobjectMethod, Nn as averageColor, Ds as bezier, tc as bezierRemap, mi as binarySearch, Ne as binaryTree, ve as bipartiteGraph, od as blendModeToThree, c as blink, rf as broadcast, Fo as buildStyledTextLines, Er as cartesianToSpherical, qe as centerOfMass, Mo as changeDecimalToValue, Ru as changeSpeed, Pf as changingDecimal, k as choose, Ta as circumscribe, ol as clearAnimationOverrides, Rf as clip, Me as clockwisePath, En as clockwiseTransform, Mp as colorGradient, fi as colorToIntRgb, Vp as colorToIntRgba, D as colorToRgb, ga as colorToRgba, Pt as compassDirections, fr as completeGraph, xn as complexFuncToR3Func, Ha as complexHomotopy, ei as complexToR3, Vi as complexValueTracker, zr as compose, Ft as computeCircularLayout, Sn as computeLayout, Dp as concatenateLists, _e as counterclockwisePath, ai as counterclockwiseTransform, cp as create, ps as createDiceRow, ep as createFadeToBlack, hi as createFadeToWhite, ou as createGifExporter, lc as createVideoExporter, Fu as createWebCodecsExporter, q as cross, q as crossVec, kp as cross2d, de as cubicBezier, up as cycleAnimation, Cl as cycleGraph, Pp as cyclicReplace, Dn as deserializeMobject, tt as detectModelFormat, Pd as difference, gu as dotVec, ot as doubleSmooth, Bd as downloadBlob, Ci as drawBorderThenFill, qi as earclipTriangulation, ul as ease, H as easeIn, H as easeInCubic, Pn as easeInBack, Rn as easeInBezier, pi as easeInBounce, Hp as easeInCirc, O as easeInElastic, _a as easeInExpo, V as easeInOut, V as easeInOutCubic, ra as easeInOutBack, $n as easeInOutBezier, ja as easeInOutBounce, bt as easeInOutCirc, bn as easeInOutElastic, gd as easeInOutExpo, sn as easeInOutQuad, ao as easeInOutQuart, Ga as easeInOutQuint, bo as easeInOutSine, $r as easeInQuad, se as easeInQuart, Us as easeInQuint, Xd as easeInSine, K as easeOut, K as easeOutCubic, bd as easeOutBack, kr as easeOutBezier, Yc as easeOutBounce, zo as easeOutCirc, Au as easeOutElastic, Fd as easeOutExpo, hs as easeOutQuad, Bl as easeOutQuart, df as easeOutQuint, As as easeOutSine, Ud as emphasizeRegion, Il as ensureKatexStyles, ms as exclusion, ic as exponentialDecay, bs as exportAndDownloadPNG, Gl as exportFramePNG, gf as exportPNGSequence, Ts as extractMobjectFamilyMembers, Bi as fAlways, qc as fadeIn, mu as fadeOut, gr as fadeToColor, Ca as fadeTransform, ft as fadeTransformPieces, h as findIntersection, hn as flash, et as focusOn, _d as get3dVmobEndCorner, Kc as get3dVmobEndCornerIndex, Io as get3dVmobEndCornerUnitNormal, Du as get3dVmobGradientStartAndEndPoints, Md as get3dVmobStartCorner, fs as get3dVmobStartCornerIndex, Ll as get3dVmobStartCornerUnitNormal, cf as get3dVmobUnitNormal, Xt as getActiveTheme, Xo as getAnimationOverride, Ee as getDetText, Qr as getFeatureFlags, Kt as getShadedRgb, wt as getSmoothCubicBezierHandlePoints, iu as getSpeechSynthesizer, Ya as getTheme, Fa as getThemeNames, ia as getUnitNormal, xt as getWindingNumber, le as gridGraph, jt as growArrow, _s as growFromCenter, ea as growFromEdge, Oa as growFromPoint, Vu as hasAnimationOverride, us as hashObj, Nt as hexToRgb, _o as homotopy, na as hsvToRgb, Xl as indexLabels, en as indicate, v as integerInterpolate, Hu as interpolate, Aa as interpolateColor, zl as intersection, Ql as inverseInterpolate, yt as invertColor, jc as isClosed, oe as isFeatureEnabled, pp as isMathJaxLoaded, Lc as isSpeechSupported, yl as isTypstLoaded, Oi as katexCanRender, jn as laggedStart, sr as laggedStartMap, xd as lengthVec, Wi as lineIntersection, Gu as linear, Cs as linearSpeedRamp, tu as lingering, Xc as linspace, fp as listDifferenceUpdate, Di as listUpdate, he as listify, Kp as logger, Oe as maintainPositionRelativeTo, as as makeClickable, Kf as makeDraggable, Zf as makeEven, Hi as makeEvenByCycling, Si as makeHoverable, jf as makeMovablePoint, wc as makeSlider, Gp as manimElementInternals, Ou as masterTimeline, gc as matchInterpolate, br as matrixToMobject, jl as matrixToTexString, xo as mid, va as midpoint, Zd as moveAlongPath, nd as moveToTarget, Zc as moveToTargetPosition, st as normSquared, cn as normalize, Bo as normalizeVec, Pc as notQuiteThere, Jp as onLog, ju as orientation2D, Id as orthonormalFrame, Kd as overrideAnimate, Es as overrideAnimation, Do as parseBookmarks, Ke as parseSVGPathData, sa as partialBezierPoints, dr as pathAlongArc, Sl as pathAlongCircles, cl as pathGraph, rd as perpendicularBisector, Xr as phaseFlow, Cf as pointLiesOnBezier, Ge as powerset, ge as preloadMathJax, qn as preloadTypst, Zl as prepareAnimation, xf as printFamily, mp as proportionsAlongBezierCurveForPoint, Vt as pulse, qt as quaternionConjugate, Ka as quaternionFromAngleAxis, Ma as quaternionMult, oo as r3ToComplex, yn as randomBrightColor, hd as randomColor, qd as registerFont, qp as registerManimElement, lo as registerTheme, Br as regularVertices, Cu as remove, Ae as removeListRedundancies, wr as removeNones, R as removeTextLetterByLetter, Qf as renderLatexToSVG, cr as renderTypstToSVG, fu as replacementTransform, Js as resetFeatureFlags, Ur as resetThemes, Dl as restore, oi as restoreMobjectState, zs as restructureListToExcludeCertainFamilyMembers, yc as reverse, on as rgbToColor, io as rgbToHex, Wa as rgbToHsv, yo as rgbaToColor, Ms as rotate, e as rotateVector, Od as rotating, $s as rotationAboutZ, of as rotationMatrix, Tu as rotationMatrixTranspose, wo as runningStart, Ef as rushFrom, _p as rushInto, Jl as rushRegion, Fp as saveMobjectState, Hl as scale, pe as scaleInPlace, gs as scaleVec, x as serializeMobject, ef as setFeatureFlags, zf as setGifDecoder, m as setKatexStylesheetUrl, Ui as setMathJaxScriptUrl, Ht as setModelLoaderFactory, Sc as setSpeechSynthesizer, r as setTheme, Lr as setTypstCompiler, Vo as shift, Ad as shoelace, al as shoelaceDirection, yr as showCreationThenDestruction, Go as showIncreasingSubsets, Iu as showPartial, S as showPassingFlash, Un as showPassingFlashWithThinningStrokeWidth, Vd as showSubmobjectsOneByOne, fl as shrinkToCenter, ki as sigmoid, es as slowInto, np as smooth, yf as smoothSpeedCurve, ie as smoothedVectorizedHomotopy, _i as smoothererstep, M as smootherstep, Vf as smoothstep, ua as snapshotFromJSON, Dt as snapshotToJSON, Yo as sphericalToCartesian, _t as spinInFromNothing, xs as spiralIn, Zo as splitBezier, Lt as spring, Mi as squishRateFunc, In as starGraph, Xi as stateFromJSON, wa as stateToJSON, Fe as stepFunction, Xe as steps, ce as straightPath, Fl as stretchArrayToLength, Vl as subVec, $f as subdivideBezier, rt as succession, g as svgMobject, je as svgToVMobjects, b as swap, Qi as texturedSphere, be as thereAndBack, mr as thereAndBackWithPause, Bu as thickDiagonal, lu as tracedPath, Gc as transform, Bn as transformAnimations, pn as transformFromCopy, Eo as transformMatchingCode, ns as transformMatchingShapes, ip as transformMatchingTex, p as tuplify, Ti as turnAnimationIntoUpdater, Fs as typeWithCursor, qf as uncreate, uf as union, bl as uniqChain, ff as unitPerpendicularTo, uc as untypeWithCursor, Ri as unwrite, Nl as updateFromAlphaFunc, vl as updateFromFunc, nm as useAnimation, am as useInjectedScene, tm as useMobject, Q as useScene, rm as useUpdater, We as valueTracker, rl as wait, Ot as wiggle, Be as wiggleOutThenIn, Tl as wiggleRate, Ve as write, Gd as zToVector };
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
import { Dot } from '../mobjects/geometry/Dot';
|
|
2
|
+
import { Vector3Tuple } from '../core/Mobject';
|
|
3
|
+
import { Scene } from '../core/Scene';
|
|
4
|
+
import { ValueTracker } from '../mobjects/value-tracker/ValueTracker';
|
|
5
|
+
import { Draggable } from './Draggable';
|
|
6
|
+
/**
|
|
7
|
+
* Options for creating a {@link MovablePoint}.
|
|
8
|
+
*/
|
|
9
|
+
export interface MovablePointOptions {
|
|
10
|
+
/** Initial position. Default: [0, 0, 0]. */
|
|
11
|
+
point?: Vector3Tuple;
|
|
12
|
+
/** Fill color as a CSS color string. Default: YELLOW. */
|
|
13
|
+
color?: string;
|
|
14
|
+
/** Radius of the dot. Default: 0.1. */
|
|
15
|
+
radius?: number;
|
|
16
|
+
/** Called with the new position whenever the point moves. */
|
|
17
|
+
onChange?: (position: Vector3Tuple) => void;
|
|
18
|
+
/** ValueTracker that receives the point's x coordinate. */
|
|
19
|
+
xTracker?: ValueTracker;
|
|
20
|
+
/** ValueTracker that receives the point's y coordinate. */
|
|
21
|
+
yTracker?: ValueTracker;
|
|
22
|
+
/**
|
|
23
|
+
* Re-render the scene after each drag update. Default: true. Set false when
|
|
24
|
+
* a render loop (play(), wait() with updaters) is already running.
|
|
25
|
+
*/
|
|
26
|
+
autoRender?: boolean;
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* MovablePoint — a draggable in-scene point whose position drives bound values.
|
|
30
|
+
*
|
|
31
|
+
* It is a {@link Dot} the reader can drag with the mouse or a finger. Each move
|
|
32
|
+
* writes the new x and y into the bound {@link ValueTracker}s and calls
|
|
33
|
+
* `onChange`, so dependent mobjects update live through the normal updater or
|
|
34
|
+
* `alwaysRedraw` path. This is the Desmos-style interactivity that drives an
|
|
35
|
+
* explorable explanation.
|
|
36
|
+
*
|
|
37
|
+
* The point can be constrained to stay on a graph (`constrainToFunction`), a
|
|
38
|
+
* parametric curve (`constrainToParametric`), an infinite line
|
|
39
|
+
* (`constrainToLine`) or a finite segment (`constrainToSegment`).
|
|
40
|
+
*
|
|
41
|
+
* @example
|
|
42
|
+
* ```typescript
|
|
43
|
+
* const xT = new ValueTracker(1);
|
|
44
|
+
* const p = new MovablePoint(scene, { point: [1, 1, 0], xTracker: xT });
|
|
45
|
+
* p.constrainToFunction((x) => Math.sin(x));
|
|
46
|
+
* scene.add(p);
|
|
47
|
+
*
|
|
48
|
+
* // A label that always reads the live x value.
|
|
49
|
+
* const label = alwaysRedraw(() => new DecimalNumber({ value: xT.getValue() }));
|
|
50
|
+
* scene.add(label);
|
|
51
|
+
* ```
|
|
52
|
+
*/
|
|
53
|
+
export declare class MovablePoint extends Dot {
|
|
54
|
+
private _draggable;
|
|
55
|
+
private _onChange?;
|
|
56
|
+
private _xTracker?;
|
|
57
|
+
private _yTracker?;
|
|
58
|
+
private _constraint;
|
|
59
|
+
private _parameter;
|
|
60
|
+
/**
|
|
61
|
+
* Create a MovablePoint.
|
|
62
|
+
* @param scene - The scene the point lives in (needed for pointer events).
|
|
63
|
+
* @param options - Appearance, bound trackers and the change callback.
|
|
64
|
+
*/
|
|
65
|
+
constructor(scene: Scene, options?: MovablePointOptions);
|
|
66
|
+
/**
|
|
67
|
+
* Move the point to a position, applying any active constraint, syncing the
|
|
68
|
+
* bound trackers and firing `onChange`.
|
|
69
|
+
* @param point - The requested position (before constraint projection).
|
|
70
|
+
* @returns this for chaining.
|
|
71
|
+
*/
|
|
72
|
+
setPoint(point: Vector3Tuple): this;
|
|
73
|
+
/**
|
|
74
|
+
* Keep the point on the graph y = f(x) while dragging.
|
|
75
|
+
* @param fn - The graph function.
|
|
76
|
+
* @returns this for chaining.
|
|
77
|
+
*/
|
|
78
|
+
constrainToFunction(fn: (x: number) => number): this;
|
|
79
|
+
/**
|
|
80
|
+
* Keep the point on a parametric curve, projecting the drag to the nearest
|
|
81
|
+
* point on the curve.
|
|
82
|
+
* @param fn - Maps a parameter t to a point [x, y].
|
|
83
|
+
* @param tRange - [tMin, tMax] and an optional sample count (default 256).
|
|
84
|
+
* @returns this for chaining.
|
|
85
|
+
*/
|
|
86
|
+
constrainToParametric(fn: (t: number) => [number, number], tRange: [number, number] | [number, number, number]): this;
|
|
87
|
+
/**
|
|
88
|
+
* Keep the point on the infinite line through p1 and p2.
|
|
89
|
+
* @param p1 - A point on the line.
|
|
90
|
+
* @param p2 - A second point on the line.
|
|
91
|
+
* @returns this for chaining.
|
|
92
|
+
*/
|
|
93
|
+
constrainToLine(p1: Vector3Tuple, p2: Vector3Tuple): this;
|
|
94
|
+
/**
|
|
95
|
+
* Keep the point on the finite segment from p1 to p2 (clamped to the ends).
|
|
96
|
+
* @param p1 - The start of the segment.
|
|
97
|
+
* @param p2 - The end of the segment.
|
|
98
|
+
* @returns this for chaining.
|
|
99
|
+
*/
|
|
100
|
+
constrainToSegment(p1: Vector3Tuple, p2: Vector3Tuple): this;
|
|
101
|
+
/**
|
|
102
|
+
* Remove any active constraint so the point drags freely again.
|
|
103
|
+
* @returns this for chaining.
|
|
104
|
+
*/
|
|
105
|
+
clearConstraint(): this;
|
|
106
|
+
/**
|
|
107
|
+
* Get the current parameter t from the last parametric projection, or null
|
|
108
|
+
* when no parametric constraint is active.
|
|
109
|
+
*/
|
|
110
|
+
getParameter(): number | null;
|
|
111
|
+
/** Get the underlying {@link Draggable} behavior. */
|
|
112
|
+
getDraggable(): Draggable;
|
|
113
|
+
/** Remove pointer-event listeners. Call when the point is no longer used. */
|
|
114
|
+
dispose(): void;
|
|
115
|
+
/** Apply the current constraint to the current position without firing onChange. */
|
|
116
|
+
private _reproject;
|
|
117
|
+
private _commit;
|
|
118
|
+
private _syncTrackers;
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* Factory function to create a {@link MovablePoint}.
|
|
122
|
+
* @param scene - The scene the point lives in.
|
|
123
|
+
* @param options - Appearance, bound trackers and the change callback.
|
|
124
|
+
* @returns A new MovablePoint.
|
|
125
|
+
*/
|
|
126
|
+
export declare function makeMovablePoint(scene: Scene, options?: MovablePointOptions): MovablePoint;
|
|
127
|
+
//# sourceMappingURL=MovablePoint.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MovablePoint.d.ts","sourceRoot":"","sources":["../../src/interaction/MovablePoint.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,0BAA0B,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACtC,OAAO,EAAE,YAAY,EAAE,MAAM,wCAAwC,CAAC;AAEtE,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAQxC;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC,4CAA4C;IAC5C,KAAK,CAAC,EAAE,YAAY,CAAC;IACrB,yDAAyD;IACzD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,uCAAuC;IACvC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,6DAA6D;IAC7D,QAAQ,CAAC,EAAE,CAAC,QAAQ,EAAE,YAAY,KAAK,IAAI,CAAC;IAC5C,2DAA2D;IAC3D,QAAQ,CAAC,EAAE,YAAY,CAAC;IACxB,2DAA2D;IAC3D,QAAQ,CAAC,EAAE,YAAY,CAAC;IACxB;;;OAGG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,qBAAa,YAAa,SAAQ,GAAG;IACnC,OAAO,CAAC,UAAU,CAAY;IAC9B,OAAO,CAAC,SAAS,CAAC,CAAmC;IACrD,OAAO,CAAC,SAAS,CAAC,CAAe;IACjC,OAAO,CAAC,SAAS,CAAC,CAAe;IACjC,OAAO,CAAC,WAAW,CAAgC;IACnD,OAAO,CAAC,UAAU,CAAuB;IAEzC;;;;OAIG;gBACS,KAAK,EAAE,KAAK,EAAE,OAAO,GAAE,mBAAwB;IA0B3D;;;;;OAKG;IACM,QAAQ,CAAC,KAAK,EAAE,YAAY,GAAG,IAAI;IAK5C;;;;OAIG;IACH,mBAAmB,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,MAAM,GAAG,IAAI;IAMpD;;;;;;OAMG;IACH,qBAAqB,CACnB,EAAE,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,CAAC,MAAM,EAAE,MAAM,CAAC,EACnC,MAAM,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,GAClD,IAAI;IAcP;;;;;OAKG;IACH,eAAe,CAAC,EAAE,EAAE,YAAY,EAAE,EAAE,EAAE,YAAY,GAAG,IAAI;IAMzD;;;;;OAKG;IACH,kBAAkB,CAAC,EAAE,EAAE,YAAY,EAAE,EAAE,EAAE,YAAY,GAAG,IAAI;IAM5D;;;OAGG;IACH,eAAe,IAAI,IAAI;IAMvB;;;OAGG;IACH,YAAY,IAAI,MAAM,GAAG,IAAI;IAI7B,qDAAqD;IACrD,YAAY,IAAI,SAAS;IAIzB,6EAA6E;IAC7E,OAAO,IAAI,IAAI;IAIf,oFAAoF;IACpF,OAAO,CAAC,UAAU;IAIlB,OAAO,CAAC,OAAO;IAOf,OAAO,CAAC,aAAa;CAItB;AAkED;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,KAAK,EAAE,OAAO,CAAC,EAAE,mBAAmB,GAAG,YAAY,CAE1F"}
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
import { Group } from '../core/Group';
|
|
2
|
+
import { Vector3Tuple } from '../core/Mobject';
|
|
3
|
+
import { Scene } from '../core/Scene';
|
|
4
|
+
import { Dot } from '../mobjects/geometry/Dot';
|
|
5
|
+
import { Line } from '../mobjects/geometry/Line';
|
|
6
|
+
import { DecimalNumber } from '../mobjects/text/DecimalNumber';
|
|
7
|
+
import { ValueTracker } from '../mobjects/value-tracker/ValueTracker';
|
|
8
|
+
import { Draggable } from './Draggable';
|
|
9
|
+
/**
|
|
10
|
+
* Options for creating a {@link Slider}.
|
|
11
|
+
*/
|
|
12
|
+
export interface SliderOptions {
|
|
13
|
+
/** Minimum value at the left end of the track. Default: 0. */
|
|
14
|
+
min?: number;
|
|
15
|
+
/** Maximum value at the right end of the track. Default: 1. */
|
|
16
|
+
max?: number;
|
|
17
|
+
/** Step to snap values to. 0 means continuous. Default: 0. */
|
|
18
|
+
step?: number;
|
|
19
|
+
/** Initial value. Default: min. */
|
|
20
|
+
value?: number;
|
|
21
|
+
/** Track length in world units. Default: 4. */
|
|
22
|
+
length?: number;
|
|
23
|
+
/** World position of the track center. Default: [0, 0, 0]. */
|
|
24
|
+
center?: Vector3Tuple;
|
|
25
|
+
/** Handle color as a CSS color string. Default: BLUE. */
|
|
26
|
+
color?: string;
|
|
27
|
+
/** Track color as a CSS color string. Default: GRAY. */
|
|
28
|
+
trackColor?: string;
|
|
29
|
+
/** Handle radius. Default: 0.12. */
|
|
30
|
+
handleRadius?: number;
|
|
31
|
+
/** ValueTracker to bind the slider value to. One is created when omitted. */
|
|
32
|
+
tracker?: ValueTracker;
|
|
33
|
+
/** Show a numeric label above the handle. Default: false. */
|
|
34
|
+
showLabel?: boolean;
|
|
35
|
+
/** Decimal places for the label. Default: 2. */
|
|
36
|
+
numDecimalPlaces?: number;
|
|
37
|
+
/** Called with the new value whenever the slider moves. */
|
|
38
|
+
onChange?: (value: number) => void;
|
|
39
|
+
/**
|
|
40
|
+
* Re-render the scene after each drag update. Default: true. Set false when
|
|
41
|
+
* a render loop (play(), wait() with updaters) is already running.
|
|
42
|
+
*/
|
|
43
|
+
autoRender?: boolean;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Slider — an in-scene slider mobject bound to a {@link ValueTracker}.
|
|
47
|
+
*
|
|
48
|
+
* Unlike the DOM `Controls.addSlider` widget, this slider is drawn from
|
|
49
|
+
* mobjects (a track {@link Line} and a draggable handle {@link Dot}), so it
|
|
50
|
+
* lives in animation world space and exports and records with the scene.
|
|
51
|
+
* Dragging the handle maps its position to a value with min, max and step,
|
|
52
|
+
* writes the value into the bound tracker and calls `onChange`, so dependent
|
|
53
|
+
* mobjects update live through the normal updater or `alwaysRedraw` path.
|
|
54
|
+
*
|
|
55
|
+
* Position the slider with the `center` option rather than by moving the
|
|
56
|
+
* group, so the drag mapping stays aligned with the track.
|
|
57
|
+
*
|
|
58
|
+
* @example
|
|
59
|
+
* ```typescript
|
|
60
|
+
* const t = new ValueTracker(0);
|
|
61
|
+
* const slider = new Slider(scene, { min: -3, max: 3, step: 0.1, tracker: t });
|
|
62
|
+
* scene.add(slider);
|
|
63
|
+
* // A curve that redraws from the live slider value.
|
|
64
|
+
* scene.add(alwaysRedraw(() => axes.plot((x) => t.getValue() * x * x)));
|
|
65
|
+
* ```
|
|
66
|
+
*/
|
|
67
|
+
export declare class Slider extends Group {
|
|
68
|
+
private _min;
|
|
69
|
+
private _max;
|
|
70
|
+
private _step;
|
|
71
|
+
private _length;
|
|
72
|
+
private _center;
|
|
73
|
+
private _trackY;
|
|
74
|
+
private _value;
|
|
75
|
+
private _tracker;
|
|
76
|
+
private _onChange?;
|
|
77
|
+
private _track;
|
|
78
|
+
private _handle;
|
|
79
|
+
private _label;
|
|
80
|
+
private _draggable;
|
|
81
|
+
/**
|
|
82
|
+
* Create a Slider.
|
|
83
|
+
* @param scene - The scene the slider lives in (needed for pointer events).
|
|
84
|
+
* @param options - Range, step, appearance and the bound tracker.
|
|
85
|
+
*/
|
|
86
|
+
constructor(scene: Scene, options?: SliderOptions);
|
|
87
|
+
/** Get the current slider value. */
|
|
88
|
+
getValue(): number;
|
|
89
|
+
/**
|
|
90
|
+
* Set the slider value, clamping to [min, max] and snapping to the step.
|
|
91
|
+
* Updates the handle position, the bound tracker, the label and fires
|
|
92
|
+
* `onChange`.
|
|
93
|
+
* @param value - The requested value.
|
|
94
|
+
* @returns this for chaining.
|
|
95
|
+
*/
|
|
96
|
+
setValue(value: number): this;
|
|
97
|
+
/** Get the bound {@link ValueTracker}. */
|
|
98
|
+
getValueTracker(): ValueTracker;
|
|
99
|
+
/** Get the track {@link Line} mobject. */
|
|
100
|
+
getTrack(): Line;
|
|
101
|
+
/** Get the draggable handle {@link Dot} mobject. */
|
|
102
|
+
getHandle(): Dot;
|
|
103
|
+
/** Get the value label, or null when `showLabel` was not set. */
|
|
104
|
+
getLabel(): DecimalNumber | null;
|
|
105
|
+
/** Get the underlying {@link Draggable} behavior for the handle. */
|
|
106
|
+
getDraggable(): Draggable;
|
|
107
|
+
/** Remove pointer-event listeners. Call when the slider is no longer used. */
|
|
108
|
+
dispose(): void;
|
|
109
|
+
private _createLabel;
|
|
110
|
+
private _positionLabel;
|
|
111
|
+
/** Map a value to the handle's x coordinate along the track. */
|
|
112
|
+
private _valueToX;
|
|
113
|
+
/** Map a handle x coordinate to a clamped, stepped value. */
|
|
114
|
+
private _xToValue;
|
|
115
|
+
/** Clamp a value to [min, max] and snap it to the step. */
|
|
116
|
+
private _clampAndStep;
|
|
117
|
+
}
|
|
118
|
+
/**
|
|
119
|
+
* Factory function to create a {@link Slider}.
|
|
120
|
+
* @param scene - The scene the slider lives in.
|
|
121
|
+
* @param options - Range, step, appearance and the bound tracker.
|
|
122
|
+
* @returns A new Slider.
|
|
123
|
+
*/
|
|
124
|
+
export declare function makeSlider(scene: Scene, options?: SliderOptions): Slider;
|
|
125
|
+
//# sourceMappingURL=Slider.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Slider.d.ts","sourceRoot":"","sources":["../../src/interaction/Slider.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACtC,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACtC,OAAO,EAAE,GAAG,EAAE,MAAM,0BAA0B,CAAC;AAC/C,OAAO,EAAE,IAAI,EAAE,MAAM,2BAA2B,CAAC;AACjD,OAAO,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AAC/D,OAAO,EAAE,YAAY,EAAE,MAAM,wCAAwC,CAAC;AAEtE,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAExC;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,8DAA8D;IAC9D,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,+DAA+D;IAC/D,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,8DAA8D;IAC9D,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,mCAAmC;IACnC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,+CAA+C;IAC/C,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,8DAA8D;IAC9D,MAAM,CAAC,EAAE,YAAY,CAAC;IACtB,yDAAyD;IACzD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,wDAAwD;IACxD,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,oCAAoC;IACpC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,6EAA6E;IAC7E,OAAO,CAAC,EAAE,YAAY,CAAC;IACvB,6DAA6D;IAC7D,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,gDAAgD;IAChD,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,2DAA2D;IAC3D,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACnC;;;OAGG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAKD;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,qBAAa,MAAO,SAAQ,KAAK;IAC/B,OAAO,CAAC,IAAI,CAAS;IACrB,OAAO,CAAC,IAAI,CAAS;IACrB,OAAO,CAAC,KAAK,CAAS;IACtB,OAAO,CAAC,OAAO,CAAS;IACxB,OAAO,CAAC,OAAO,CAAe;IAC9B,OAAO,CAAC,OAAO,CAAS;IACxB,OAAO,CAAC,MAAM,CAAS;IACvB,OAAO,CAAC,QAAQ,CAAe;IAC/B,OAAO,CAAC,SAAS,CAAC,CAA0B;IAE5C,OAAO,CAAC,MAAM,CAAO;IACrB,OAAO,CAAC,OAAO,CAAM;IACrB,OAAO,CAAC,MAAM,CAA8B;IAC5C,OAAO,CAAC,UAAU,CAAY;IAE9B;;;;OAIG;gBACS,KAAK,EAAE,KAAK,EAAE,OAAO,GAAE,aAAkB;IAyCrD,oCAAoC;IACpC,QAAQ,IAAI,MAAM;IAIlB;;;;;;OAMG;IACH,QAAQ,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI;IAa7B,0CAA0C;IAC1C,eAAe,IAAI,YAAY;IAI/B,0CAA0C;IAC1C,QAAQ,IAAI,IAAI;IAIhB,oDAAoD;IACpD,SAAS,IAAI,GAAG;IAIhB,iEAAiE;IACjE,QAAQ,IAAI,aAAa,GAAG,IAAI;IAIhC,oEAAoE;IACpE,YAAY,IAAI,SAAS;IAIzB,8EAA8E;IAC9E,OAAO,IAAI,IAAI;IAIf,OAAO,CAAC,YAAY;IAWpB,OAAO,CAAC,cAAc;IAMtB,gEAAgE;IAChE,OAAO,CAAC,SAAS;IAOjB,6DAA6D;IAC7D,OAAO,CAAC,SAAS;IAQjB,2DAA2D;IAC3D,OAAO,CAAC,aAAa;CAOtB;AAyCD;;;;;GAKG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,KAAK,EAAE,OAAO,CAAC,EAAE,aAAa,GAAG,MAAM,CAExE"}
|
|
@@ -7,6 +7,8 @@ export { PlaybackControls, type PlaybackControlsOptions, type TimeUpdateCallback
|
|
|
7
7
|
export { Draggable, makeDraggable, type DraggableOptions } from './Draggable';
|
|
8
8
|
export { Hoverable, makeHoverable, type HoverableOptions } from './Hoverable';
|
|
9
9
|
export { Clickable, makeClickable, type ClickableOptions } from './Clickable';
|
|
10
|
+
export { MovablePoint, makeMovablePoint, type MovablePointOptions } from './MovablePoint';
|
|
11
|
+
export { Slider, makeSlider, type SliderOptions } from './Slider';
|
|
10
12
|
export { SelectionManager, type SelectionManagerOptions } from './SelectionManager';
|
|
11
13
|
export { OrbitControls, type OrbitControlsOptions } from './OrbitControls';
|
|
12
14
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/interaction/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EACL,QAAQ,EACR,KAAK,eAAe,EACpB,KAAK,gBAAgB,EACrB,KAAK,aAAa,EAClB,KAAK,YAAY,EACjB,KAAK,YAAY,EACjB,KAAK,cAAc,EACnB,KAAK,iBAAiB,GACvB,MAAM,YAAY,CAAC;AAEpB,OAAO,EACL,gBAAgB,EAChB,KAAK,uBAAuB,EAC5B,KAAK,kBAAkB,GACxB,MAAM,oBAAoB,CAAC;AAG5B,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,KAAK,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC9E,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,KAAK,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC9E,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,KAAK,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAG9E,OAAO,EAAE,gBAAgB,EAAE,KAAK,uBAAuB,EAAE,MAAM,oBAAoB,CAAC;AAGpF,OAAO,EAAE,aAAa,EAAE,KAAK,oBAAoB,EAAE,MAAM,iBAAiB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/interaction/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EACL,QAAQ,EACR,KAAK,eAAe,EACpB,KAAK,gBAAgB,EACrB,KAAK,aAAa,EAClB,KAAK,YAAY,EACjB,KAAK,YAAY,EACjB,KAAK,cAAc,EACnB,KAAK,iBAAiB,GACvB,MAAM,YAAY,CAAC;AAEpB,OAAO,EACL,gBAAgB,EAChB,KAAK,uBAAuB,EAC5B,KAAK,kBAAkB,GACxB,MAAM,oBAAoB,CAAC;AAG5B,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,KAAK,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC9E,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,KAAK,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC9E,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,KAAK,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAG9E,OAAO,EAAE,YAAY,EAAE,gBAAgB,EAAE,KAAK,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;AAC1F,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,KAAK,aAAa,EAAE,MAAM,UAAU,CAAC;AAGlE,OAAO,EAAE,gBAAgB,EAAE,KAAK,uBAAuB,EAAE,MAAM,oBAAoB,CAAC;AAGpF,OAAO,EAAE,aAAa,EAAE,KAAK,oBAAoB,EAAE,MAAM,iBAAiB,CAAC"}
|