@mkbabb/keyframes.js 4.2.0 → 4.4.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.
@@ -0,0 +1,179 @@
1
+ import { f as e, i as t } from "./timeline-B7SV3T_E.js";
2
+ import { COMPUTED_UNITS as n, unflattenObjectToString as r } from "@mkbabb/value.js";
3
+ //#region src/animation/waapi.ts
4
+ var i = new Set([
5
+ ...n,
6
+ "%",
7
+ "vh",
8
+ "vw",
9
+ "vmin",
10
+ "vmax",
11
+ "vi",
12
+ "vb",
13
+ "svh",
14
+ "svw",
15
+ "svmin",
16
+ "svmax",
17
+ "svi",
18
+ "svb",
19
+ "lvh",
20
+ "lvw",
21
+ "lvmin",
22
+ "lvmax",
23
+ "lvi",
24
+ "lvb",
25
+ "dvh",
26
+ "dvw",
27
+ "dvmin",
28
+ "dvmax",
29
+ "dvi",
30
+ "dvb",
31
+ "cqw",
32
+ "cqh",
33
+ "cqi",
34
+ "cqb",
35
+ "cqmin",
36
+ "cqmax"
37
+ ]), a = (e) => typeof e == "string" && i.has(e), o = new Set(["offset-distance"]), s = (e) => o.has(e) || o.has(e.split(".").pop() ?? e), c = () => typeof globalThis.webkitConvertPointFromNodeToPage == "function";
38
+ function l(e) {
39
+ if (!e.targets || e.targets.length === 0) return {
40
+ eligible: !1,
41
+ reason: "no DOM targets"
42
+ };
43
+ if (typeof e.targets[0]?.animate != "function") return {
44
+ eligible: !1,
45
+ reason: "target does not implement Element.animate()"
46
+ };
47
+ for (let t of e.frames) if (!e.usesDefaultRenderer(t.transform)) return {
48
+ eligible: !1,
49
+ reason: "custom transform function (not the default DOM renderer)"
50
+ };
51
+ let t = e.frames[0]?.timingFunction;
52
+ if (t && e.frames.length > 1) {
53
+ for (let n = 1; n < e.frames.length; n++) if (e.frames[n].timingFunction.fn !== t.fn) return {
54
+ eligible: !1,
55
+ reason: "non-uniform per-frame timing function (WAAPI supports one easing per animation)"
56
+ };
57
+ if (t.css !== void 0) return {
58
+ eligible: !1,
59
+ reason: "CSS-twinned easing across multiple segments (WAAPI restarts the curve per segment)"
60
+ };
61
+ }
62
+ if (t && t.css === void 0) return {
63
+ eligible: !1,
64
+ reason: "easing has no faithful CSS twin (would run bare linear on the compositor)"
65
+ };
66
+ if (t?.css?.startsWith("linear(") && c()) return {
67
+ eligible: !1,
68
+ reason: "WebKit refuses HW-accel for linear() easing — the spring twin stays on the rAF path (CE-1.0)"
69
+ };
70
+ for (let t of e.frames) for (let [e, n] of Object.entries(t.interpVars)) {
71
+ let t = s(e);
72
+ for (let e of n) {
73
+ let n = a(e.start?.unit) && !(t && e.start?.unit === "%"), r = a(e.stop?.unit) && !(t && e.stop?.unit === "%");
74
+ if (n || r) return {
75
+ eligible: !1,
76
+ reason: `layout-dependent unit (${String(e.start?.unit ?? e.stop?.unit)}) would freeze to px under WAAPI`
77
+ };
78
+ if (e.start?.unit === "color" || e.stop?.unit === "color") return {
79
+ eligible: !1,
80
+ reason: "color interpolation requires perceptual lerp"
81
+ };
82
+ }
83
+ }
84
+ return { eligible: !0 };
85
+ }
86
+ var u = 8;
87
+ function d(t) {
88
+ let n = t.options.duration, i = [], a = /* @__PURE__ */ new Set();
89
+ for (let e of t.frames) a.add(e.time.start), a.add(e.time.stop);
90
+ let o = [...a].sort((e, t) => e - t), s = new Set(o);
91
+ if (n > 0) for (let e = 1; e < o.length; e++) {
92
+ let t = o[e - 1], n = o[e] - t;
93
+ if (!(n <= 0)) for (let e = 1; e <= u; e++) s.add(t + n * e / 9);
94
+ }
95
+ for (let a of [...s].sort((e, t) => e - t)) {
96
+ let o = t.interpFrames(a, !1);
97
+ if (Object.keys(o).length === 0) continue;
98
+ let s = r(o);
99
+ i.push({
100
+ offset: e(a / n, 0, 1),
101
+ ...s
102
+ });
103
+ }
104
+ return i;
105
+ }
106
+ var f = {
107
+ normal: "normal",
108
+ reverse: "reverse",
109
+ alternate: "alternate",
110
+ "alternate-reverse": "alternate-reverse"
111
+ }, p = {
112
+ none: "none",
113
+ forwards: "forwards",
114
+ backwards: "backwards",
115
+ both: "both"
116
+ }, m = {
117
+ replace: "replace",
118
+ add: "add",
119
+ accumulate: "accumulate"
120
+ }, h = (e) => {
121
+ for (let t of e.frames) {
122
+ let e = t.composition;
123
+ if (e != null && e !== "replace") return m[e] ?? "replace";
124
+ }
125
+ return "replace";
126
+ };
127
+ function g(e) {
128
+ let t = e.options, n = f[t.direction], r = p[t.fillMode];
129
+ if (n == null) throw TypeError(`Unrecognised animation direction "${t.direction}".`);
130
+ if (r == null) throw TypeError(`Unrecognised animation fill mode "${t.fillMode}".`);
131
+ let i = (e.frames[0]?.timingFunction ?? e.options.timingFunction).css ?? "linear", a = h(e), o = {
132
+ duration: t.duration,
133
+ delay: t.delay,
134
+ iterations: t.iterationCount === Infinity ? Infinity : t.iterationCount,
135
+ direction: n,
136
+ fill: r,
137
+ easing: i
138
+ };
139
+ return a !== "replace" && (o.composite = a), o;
140
+ }
141
+ async function _(e) {
142
+ let t = d(e), n = g(e), r = e.targets.map((e) => e.animate(t, n));
143
+ e._waAnimations = r, e.playback.loop(async (t) => {
144
+ if (e.done) return !1;
145
+ if (await e.advanceTo(t), e.paused) for (let e of r) e.pause();
146
+ else for (let e of r) e.playState === "paused" && e.play();
147
+ return !e.done;
148
+ });
149
+ try {
150
+ await Promise.all(r.map((e) => e.finished));
151
+ for (let t of r) try {
152
+ e.restPosition === "final" && typeof t.commitStyles == "function" && t.commitStyles(), t.cancel();
153
+ } catch {}
154
+ } catch {} finally {
155
+ e.playback.stop(), e._waAnimations = [];
156
+ }
157
+ }
158
+ function v(e, n) {
159
+ let r = l(e);
160
+ if (!r.eligible) return {
161
+ attached: !1,
162
+ reason: r.reason
163
+ };
164
+ let i = t(n);
165
+ if (i == null) return {
166
+ attached: !1,
167
+ reason: "native scroll/view timeline unavailable (feature absent)"
168
+ };
169
+ let a = d(e), o = {
170
+ ...g(e),
171
+ timeline: i
172
+ }, s = e.targets.map((e) => e.animate(a, o));
173
+ return e._waAnimations = s, {
174
+ attached: !0,
175
+ animations: s
176
+ };
177
+ }
178
+ //#endregion
179
+ export { l as n, _ as r, v as t };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mkbabb/keyframes.js",
3
- "version": "4.2.0",
3
+ "version": "4.4.0",
4
4
  "description": "Create keyframe animations for anything in JavaScript; specify your keyframes in standards-complaint CSS.",
5
5
  "license": "MIT",
6
6
  "keywords": [
@@ -42,6 +42,10 @@
42
42
  "gh-pages": "vite build --mode gh-pages",
43
43
  "proof:boundary": "node scripts/proof-boundary.mjs",
44
44
  "proof:published-surface": "node scripts/proof-published-surface.mjs",
45
+ "proof:agent-surface": "node scripts/proof-agent-surface.mjs",
46
+ "proof:agent-validate": "node scripts/proof-agent-validate.mjs && vitest run test/agent-validate.test.ts",
47
+ "proof:demo-on-published-surface": "node scripts/proof-demo-on-published-surface.mjs",
48
+ "proof:color-fidelity": "node scripts/proof-color-fidelity.mjs && vitest run test/color-fidelity.test.ts",
45
49
  "proof:readme-runs": "node scripts/proof-readme-runs.mjs",
46
50
  "proof:deps-current": "node scripts/proof-deps-current.mjs",
47
51
  "proof:repin-witness": "node scripts/proof-repin-witness.mjs",
@@ -58,20 +62,33 @@
58
62
  "proof:engine-correctness": "vitest run test/engine-correctness.test.ts",
59
63
  "proof:standalone-zero-alloc": "vitest run test/standalone-zero-alloc.test.ts",
60
64
  "proof:compile-deterministic": "vitest run test/compile-deterministic.test.ts",
65
+ "proof:compile-replay": "node scripts/proof-compile-replay.mjs && vitest run test/compile-roundtrip.test.ts",
66
+ "proof:replay-equality": "node scripts/proof-replay-equality.mjs && vitest run test/replay-equality.test.ts",
61
67
  "proof:bench-runs": "node scripts/proof-bench-runs.mjs",
68
+ "proof:bench-taxonomy": "node scripts/proof-bench-taxonomy.mjs",
69
+ "proof:scheduler-posttask": "node scripts/proof-scheduler-posttask.mjs",
70
+ "proof:epf1-measure": "node scripts/proof-epf1-measure.mjs",
71
+ "proof:spring-vector": "node scripts/proof-spring-vector.mjs",
62
72
  "proof:orchestration": "node scripts/proof-orchestration.mjs",
73
+ "proof:animate-orchestration": "vitest run test/animate-orchestration.test.ts",
74
+ "proof:transport-events": "node scripts/proof-transport-events.mjs",
63
75
  "proof:interp-fastprops": "node --allow-natives-syntax scripts/proof-interp-fastprops.mjs && vitest run test/interp-fastprops.test.ts",
64
76
  "proof:sync-step": "vitest run test/sync-step.test.ts",
65
77
  "proof:event-ordering": "vitest run test/event-ordering.test.ts",
66
78
  "proof:roundtrip-easing": "vitest run test/roundtrip-easing.test.ts",
67
79
  "proof:adapter-capture": "vitest run test/adapter-capture.test.ts",
80
+ "proof:composition-honored": "node scripts/proof-composition-honored.mjs && vitest run test/composition-honored.test.ts",
81
+ "proof:diagnostics-channel": "node scripts/proof-diagnostics-channel.mjs && vitest run test/diagnostics-channel.test.ts",
82
+ "proof:scroll-roundtrip": "node scripts/proof-scroll-roundtrip.mjs && vitest run test/scroll-scene.test.ts",
68
83
  "proof:motion-path": "node scripts/proof-motion-path.mjs && vitest run test/motion-path.test.ts",
69
84
  "proof:blend": "node scripts/proof-blend.mjs && vitest run test/blend.test.ts",
85
+ "proof:spring-blend-weight": "node scripts/proof-spring-blend-weight.mjs && vitest run test/spring-blend-weight.test.ts",
70
86
  "proof:drawsvg": "node scripts/proof-drawsvg.mjs && vitest run test/draw-svg.test.ts",
71
87
  "proof:finished": "node scripts/proof-finished.mjs && vitest run test/finished.test.ts",
72
88
  "proof:adopt-compiled": "node scripts/proof-adopt-compiled.mjs && vitest run test/adopt-compiled.test.ts",
73
89
  "proof:interpolate-anything": "node scripts/proof-interpolate-anything.mjs && vitest run test/interpolate-anything.test.ts",
74
90
  "proof:roundtrip-fidelity": "node scripts/proof-roundtrip-fidelity.mjs && vitest run test/roundtrip-fidelity.test.ts",
91
+ "proof:ingest-replay": "node scripts/proof-ingest-replay.mjs && vitest run test/ingest.test.ts",
75
92
  "proof:orbital-rotate3d": "node scripts/proof-orbital-rotate3d.mjs && vitest run test/orbital-rotate3d.test.ts",
76
93
  "proof:asset-store-singleton": "vitest run test/asset-store-singleton.test.ts",
77
94
  "proof:scene-raf-leak": "vitest run test/scene-raf-leak.test.ts",
@@ -89,10 +106,12 @@
89
106
  "proof:gate-is-runtime": "node scripts/proof-gate-is-runtime.mjs",
90
107
  "proof:engine-no-throw-on-play": "node scripts/proof-engine-no-throw-on-play.mjs",
91
108
  "proof:subject-animates": "node scripts/proof-subject-animates.mjs",
109
+ "proof:cold-entry": "node scripts/proof-cold-entry.mjs",
92
110
  "proof:amiga-subject-is-pivot": "node scripts/proof-amiga-subject-is-pivot.mjs",
93
111
  "proof:icon-paint-live": "node scripts/proof-icon-paint-live.mjs",
94
112
  "proof:specular-absent-at-rest": "node scripts/proof-specular-absent-at-rest.mjs",
95
113
  "proof:demo-fonts": "node scripts/proof-demo-fonts.mjs",
114
+ "proof:font-census": "node scripts/proof-font-census.mjs",
96
115
  "proof:drag-gesture": "node scripts/proof-drag-gesture.mjs",
97
116
  "proof:perf-frame-budget": "node scripts/proof-perf-frame-budget.mjs",
98
117
  "proof:easing-editor-live": "node scripts/proof-easing-editor-live.mjs",
@@ -112,6 +131,7 @@
112
131
  "proof:timeline-rail-width": "node scripts/proof-timeline-rail-width.mjs",
113
132
  "proof:demo-shell-grid": "node scripts/proof-demo-shell-grid.mjs",
114
133
  "proof:stage-not-clipped": "node scripts/proof-stage-not-clipped.mjs",
134
+ "proof:layout-cluster": "node scripts/proof-layout-cluster.mjs",
115
135
  "proof:cartoon-shadow-unclipped": "node scripts/proof-cartoon-shadow-unclipped.mjs",
116
136
  "proof:no-deprecated-guard": "node scripts/proof-no-deprecated-guard.mjs",
117
137
  "proof:single-writer": "node scripts/proof-single-writer.mjs",
@@ -153,14 +173,36 @@
153
173
  "proof:motion-path-editable": "node scripts/proof-motion-path-editable.mjs",
154
174
  "proof:motion-path-copy": "node scripts/proof-motion-path-copy.mjs",
155
175
  "proof:easter-egg": "node scripts/proof-easter-egg.mjs",
176
+ "proof:crayon-preserved": "node scripts/proof-crayon-preserved.mjs",
177
+ "proof:design-refinement": "node scripts/proof-design-refinement.mjs",
178
+ "proof:spring-slider-continuous": "node scripts/proof-spring-slider-continuous.mjs",
179
+ "proof:taste-packet": "node scripts/proof-taste-packet.mjs",
156
180
  "proof:ci-coverage": "node scripts/proof-ci-coverage.mjs",
181
+ "proof:report-all": "node scripts/proof-report-all.mjs",
182
+ "proof:no-single-option-select": "node scripts/proof-no-single-option-select.mjs",
183
+ "proof:peer-satisfied": "node scripts/proof-peer-satisfied.mjs",
184
+ "proof:css-parity": "node scripts/proof-css-parity.mjs",
185
+ "proof:packrat-sound": "node scripts/proof-packrat-sound.mjs",
186
+ "proof:consume-bundle": "node scripts/proof-consume-bundle.mjs",
187
+ "proof:keyframes-vue-published": "node scripts/proof-keyframes-vue-published.mjs",
188
+ "proof:workaround-deletion": "node scripts/proof-workaround-deletion.mjs",
189
+ "proof:control-point-live": "node scripts/proof-control-point-live.mjs",
190
+ "proof:settle-is-predicate": "node scripts/proof-settle-is-predicate.mjs",
157
191
  "proof:manifest-sourced": "node scripts/proof-manifest-sourced.mjs",
158
192
  "proof:chronic-closure": "node scripts/proof-chronic-closure.mjs",
159
- "proof:correctness": "npm run proof:engine-no-throw-on-play && npm run proof:subject-animates && npm run proof:fsm-suspend-resume-live && npm run proof:easing-editor-live && npm run proof:amiga-subject-is-pivot && npm run proof:drag-gesture && npm run proof:control-surface-single-writer && npm run proof:sheet-reopen-scroll && npm run proof:perf-frame-budget && npm run proof:icon-paint-live && npm run proof:specular-absent-at-rest && npm run proof:demo-fonts && npm run proof:live-session && npm run proof:live-session-mobile && npm run proof:appearance-suffusion",
160
- "proof:hygiene": "npm run proof:deps-current && npm run proof:repin-witness && npm run proof:boundary && npm run proof:dogfood && npm run proof:engine && npm run proof:decomposition && npm run proof:no-deprecated-guard && npm run proof:single-writer && npm run proof:composable-encapsulation && npm run proof:demo-no-oversize && npm run proof:no-brittle-selector && npm run proof:no-dup-utility && npm run proof:demo-smoke && npm run proof:occlusion && npm run proof:cartoon-is-panel-depth && npm run proof:glass-and-cartoon && npm run proof:dock-popover-opens && npm run proof:single-toggle && npm run proof:darkmode-row-toggle && npm run proof:idle-fade && npm run proof:single-column-pack && npm run proof:label-subgrid && npm run proof:timeline-rail-width && npm run proof:demo-shell-grid && npm run proof:stage-not-clipped && npm run proof:cartoon-shadow-unclipped && npm run proof:scene-machine-irrefragable && npm run proof:scene-control-dfa && npm run proof:scene-transition-perf && npm run proof:dock-zorder && npm run proof:drawer-spring && npm run proof:idioms && npm run proof:phi-leaf-zero && npm run proof:icon-idiom && npm run proof:styling-idioms && npm run proof:scene-parity && npm run proof:sequence-rows-draggable && npm run proof:motion-path-editable && npm run proof:motion-path-copy && npm run proof:easter-egg && npm run proof:typing-dots && npm run proof:dogfood-hero && npm run proof:easing-canvas-bounded && npm run proof:scene-uses-standard-ribbon && npm run proof:easing-sidebar-normalized && npm run proof:easing-sidebar-minimal && npm run proof:easing-stage-is-ball && npm run proof:scene-card-rounded && npm run proof:stage-glass-card && npm run proof:card-rounded-primitive && npm run proof:stage-within-docks && npm run proof:mobile-single-page && npm run proof:bezier-no-scroll && npm run proof:bezier-single-card && npm run proof:bezier-grown && npm run proof:pp-logo-svg && npm run proof:scene-perf-budget && npm run proof:hero-rung && npm run proof:hero-balance && npm run proof:hero-cls && npm run proof:brittleness && npm run proof:demo-elevate && npm run proof:modern-web && npm run proof:zero-alloc && npm run proof:engine-correctness && npm run proof:standalone-zero-alloc && npm run proof:compile-deterministic && npm run proof:platform-adopt && npm run proof:orchestration && npm run proof:interp-fastprops && npm run proof:sync-step && npm run proof:roundtrip-easing && npm run proof:adapter-capture && npm run proof:motion-path && npm run proof:blend && npm run proof:drawsvg && npm run proof:finished && npm run proof:adopt-compiled && npm run proof:interpolate-anything && npm run proof:roundtrip-fidelity && npm run proof:orbital-rotate3d && npm run proof:asset-store-singleton && npm run proof:scene-raf-leak && npm run proof:scene-contract-identity && npm run proof:group-snapshot-identity && npm run proof:resize-tracks && npm run proof:cohesion && npm run proof:visual-lock && npm run proof:demo-usability && npm run proof:computed-real-dom && npm run proof:lighthouse-a11y && npm run proof:lighthouse-mobile && npm run proof:published-surface && npm run proof:readme-runs && npm run proof:event-ordering && npm run proof:manifest-sourced && npm run proof:bench-runs && npm run proof:gate-is-runtime && npm run proof:chronic-closure && npm run proof:ci-coverage && vitest run",
161
- "proof:all": "npm run proof:correctness && npm run proof:hygiene",
193
+ "proof:no-foreign-symbol-stamp": "node scripts/proof-no-foreign-symbol-stamp.mjs",
194
+ "proof:soa-composite": "node scripts/proof-soa-composite.mjs && npm run proof:blend",
195
+ "proof:emerging-css-resolve-now": "node scripts/proof-emerging-css-resolve-now.mjs && vitest run test/emerging-css-resolve-now.test.ts",
196
+ "proof:morphsvg-consume": "node scripts/proof-morphsvg-consume.mjs && vitest run test/morph-svg.test.ts",
197
+ "proof:portable-perf": "node scripts/proof-portable-perf.mjs",
198
+ "proof:correctness": "npm run proof:engine-no-throw-on-play && npm run proof:subject-animates && npm run proof:cold-entry && npm run proof:fsm-suspend-resume-live && npm run proof:easing-editor-live && npm run proof:amiga-subject-is-pivot && npm run proof:drag-gesture && npm run proof:control-surface-single-writer && npm run proof:sheet-reopen-scroll && npm run proof:perf-frame-budget && npm run proof:icon-paint-live && npm run proof:specular-absent-at-rest && npm run proof:demo-fonts && npm run proof:font-census && npm run proof:live-session && npm run proof:live-session-mobile && npm run proof:appearance-suffusion && npm run proof:spring-slider-continuous && npm run proof:emerging-css-resolve-now",
199
+ "proof:hygiene": "npm run proof:deps-current && npm run proof:repin-witness && npm run proof:boundary && npm run proof:consume-bundle && npm run proof:css-parity && npm run proof:packrat-sound && npm run proof:workaround-deletion && npm run proof:dogfood && npm run proof:engine && npm run proof:decomposition && npm run proof:no-deprecated-guard && npm run proof:single-writer && npm run proof:composable-encapsulation && npm run proof:demo-no-oversize && npm run proof:no-brittle-selector && npm run proof:no-dup-utility && npm run proof:no-single-option-select && npm run proof:settle-is-predicate && npm run proof:demo-smoke && npm run proof:occlusion && npm run proof:cartoon-is-panel-depth && npm run proof:glass-and-cartoon && npm run proof:dock-popover-opens && npm run proof:single-toggle && npm run proof:darkmode-row-toggle && npm run proof:idle-fade && npm run proof:single-column-pack && npm run proof:label-subgrid && npm run proof:timeline-rail-width && npm run proof:demo-shell-grid && npm run proof:layout-cluster && npm run proof:stage-not-clipped && npm run proof:cartoon-shadow-unclipped && npm run proof:scene-machine-irrefragable && npm run proof:scene-control-dfa && npm run proof:scene-transition-perf && npm run proof:dock-zorder && npm run proof:drawer-spring && npm run proof:idioms && npm run proof:phi-leaf-zero && npm run proof:icon-idiom && npm run proof:styling-idioms && npm run proof:scene-parity && npm run proof:sequence-rows-draggable && npm run proof:motion-path-editable && npm run proof:motion-path-copy && npm run proof:easter-egg && npm run proof:crayon-preserved && npm run proof:design-refinement && npm run proof:typing-dots && npm run proof:dogfood-hero && npm run proof:easing-canvas-bounded && npm run proof:scene-uses-standard-ribbon && npm run proof:easing-sidebar-normalized && npm run proof:easing-sidebar-minimal && npm run proof:easing-stage-is-ball && npm run proof:scene-card-rounded && npm run proof:stage-glass-card && npm run proof:card-rounded-primitive && npm run proof:stage-within-docks && npm run proof:mobile-single-page && npm run proof:bezier-no-scroll && npm run proof:bezier-single-card && npm run proof:bezier-grown && npm run proof:pp-logo-svg && npm run proof:scene-perf-budget && npm run proof:hero-rung && npm run proof:hero-balance && npm run proof:hero-cls && npm run proof:brittleness && npm run proof:demo-elevate && npm run proof:modern-web && npm run proof:zero-alloc && npm run proof:engine-correctness && npm run proof:standalone-zero-alloc && npm run proof:compile-deterministic && npm run proof:compile-replay && npm run proof:replay-equality && npm run proof:platform-adopt && npm run proof:orchestration && npm run proof:transport-events && npm run proof:animate-orchestration && npm run proof:interp-fastprops && npm run proof:sync-step && npm run proof:roundtrip-easing && npm run proof:adapter-capture && npm run proof:composition-honored && npm run proof:diagnostics-channel && npm run proof:scroll-roundtrip && npm run proof:motion-path && npm run proof:blend && npm run proof:spring-blend-weight && npm run proof:drawsvg && npm run proof:finished && npm run proof:adopt-compiled && npm run proof:interpolate-anything && npm run proof:roundtrip-fidelity && npm run proof:ingest-replay && npm run proof:orbital-rotate3d && npm run proof:asset-store-singleton && npm run proof:scene-raf-leak && npm run proof:scene-contract-identity && npm run proof:group-snapshot-identity && npm run proof:resize-tracks && npm run proof:cohesion && npm run proof:visual-lock && npm run proof:demo-usability && npm run proof:computed-real-dom && npm run proof:lighthouse-a11y && npm run proof:lighthouse-mobile && npm run proof:published-surface && npm run proof:agent-surface && npm run proof:agent-validate && npm run proof:demo-on-published-surface && npm run proof:color-fidelity && npm run proof:readme-runs && npm run proof:event-ordering && npm run proof:manifest-sourced && npm run proof:bench-runs && npm run proof:bench-taxonomy && npm run proof:scheduler-posttask && npm run proof:epf1-measure && npm run proof:spring-vector && npm run proof:gate-is-runtime && npm run proof:chronic-closure && npm run proof:taste-packet && npm run proof:ci-coverage && npm run proof:no-foreign-symbol-stamp && npm run proof:soa-composite && npm run proof:morphsvg-consume && npm run proof:portable-perf && npm run proof:report-all && vitest run",
200
+ "proof:all": "node scripts/run-all.mjs --all",
201
+ "proof:all:demo": "npm run proof:demo-smoke && npm run proof:occlusion && npm run proof:peer-satisfied",
162
202
  "test": "vitest",
163
- "bench": "vitest bench"
203
+ "bench": "vitest bench",
204
+ "bench:color-fidelity": "vitest run test/color-fidelity.test.ts && node scripts/color-fidelity-harness.mjs",
205
+ "gen:agent-surface": "node scripts/gen-agent-surface.mjs"
164
206
  },
165
207
  "repository": {
166
208
  "type": "git",
@@ -175,11 +217,10 @@
175
217
  },
176
218
  "homepage": "https://github.com/mkbabb/keyframes.js#readme",
177
219
  "dependencies": {
178
- "@mkbabb/parse-that": "^0.9.0",
179
- "@mkbabb/value.js": "^0.11.2"
220
+ "@mkbabb/value.js": "^1.1.0"
180
221
  },
181
222
  "optionalDependencies": {
182
- "@mkbabb/glass-ui": "~3.11.2"
223
+ "@mkbabb/glass-ui": "~4.0.0"
183
224
  },
184
225
  "devDependencies": {
185
226
  "@iconify-json/radix-icons": "^1.2.6",
@@ -1,21 +0,0 @@
1
- import { CSSKeyframesAnimation as e } from "./engine-Gk4Q7ltr.js";
2
- import { fromMotionPath as t } from "./motion-path-DQ73oD2j.js";
3
- //#region src/animation/animate.ts
4
- var n = (e) => typeof e == "object" && !!e && !Array.isArray(e) && !(e instanceof Map) && typeof e.path == "string", r = (e) => e instanceof Map || typeof e == "object" && !!e && !Array.isArray(e);
5
- function i(i, a, o) {
6
- let { transform: s, autoPlay: c = !0, ...l } = o ?? {};
7
- if (n(a)) return t(i, {
8
- ...a,
9
- ...l,
10
- autoPlay: c
11
- });
12
- let u = new e(l);
13
- if (typeof a == "string") u.fromString(a, s);
14
- else if (Array.isArray(a)) u.fromVars(a, s);
15
- else if (r(a)) u.fromKeyframes(a, s);
16
- else throw Error("animate(): unrecognized input — pass a CSS @keyframes string, a keyframe map ({ \"0%\": {...} }), a vars array ([from, to]), or a MotionPath spec ({ path }).");
17
- let d = Array.isArray(i) ? i : [i];
18
- return u.setTargets(...d), c && u.play(), u;
19
- }
20
- //#endregion
21
- export { i as animate };