motionary 10.5.0 → 10.6.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.
Files changed (100) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/README.md +60 -0
  3. package/dist/chunks/{anim-image-DuxvYhq6.cjs → anim-image-DECLkPH4.cjs} +2 -2
  4. package/dist/chunks/{anim-image-DuxvYhq6.cjs.map → anim-image-DECLkPH4.cjs.map} +1 -1
  5. package/dist/chunks/{anim-image-BlNPv4JG.js → anim-image-DNghy017.js} +2 -2
  6. package/dist/chunks/{anim-image-BlNPv4JG.js.map → anim-image-DNghy017.js.map} +1 -1
  7. package/dist/chunks/{keyframes-Ce1s05n3.cjs → keyframes-CbUZjD_5.cjs} +2 -2
  8. package/dist/chunks/{keyframes-Ce1s05n3.cjs.map → keyframes-CbUZjD_5.cjs.map} +1 -1
  9. package/dist/chunks/{keyframes-B8ITIAVa.js → keyframes-F6vp6tZZ.js} +2 -2
  10. package/dist/chunks/{keyframes-B8ITIAVa.js.map → keyframes-F6vp6tZZ.js.map} +1 -1
  11. package/dist/chunks/{registry-DXdFb2fJ.js → registry-D8LAoXI-.js} +2 -2
  12. package/dist/chunks/{registry-DXdFb2fJ.js.map → registry-D8LAoXI-.js.map} +1 -1
  13. package/dist/chunks/{registry-VhfPSI0v.cjs → registry-dr1CPTk1.cjs} +2 -2
  14. package/dist/chunks/{registry-VhfPSI0v.cjs.map → registry-dr1CPTk1.cjs.map} +1 -1
  15. package/dist/chunks/{ticker-DvmC6WLS.cjs → ticker-DaAlEyOd.cjs} +2 -2
  16. package/dist/chunks/{ticker-DvmC6WLS.cjs.map → ticker-DaAlEyOd.cjs.map} +1 -1
  17. package/dist/chunks/{ticker-C5RMHMW7.js → ticker-Do9bGsaV.js} +2 -2
  18. package/dist/chunks/{ticker-C5RMHMW7.js.map → ticker-Do9bGsaV.js.map} +1 -1
  19. package/dist/chunks/{tween-CPtm-EdT.js → tween-BzCGq_Ba.js} +2 -2
  20. package/dist/chunks/{tween-CPtm-EdT.js.map → tween-BzCGq_Ba.js.map} +1 -1
  21. package/dist/chunks/{tween-_BGIl6hK.cjs → tween-CmkdSyaC.cjs} +2 -2
  22. package/dist/chunks/{tween-_BGIl6hK.cjs.map → tween-CmkdSyaC.cjs.map} +1 -1
  23. package/dist/components/lite.cjs +179 -0
  24. package/dist/components/lite.cjs.map +1 -1
  25. package/dist/components/lite.js +176 -1
  26. package/dist/components/lite.js.map +1 -1
  27. package/dist/components/tokens.cjs +179 -0
  28. package/dist/components/tokens.cjs.map +1 -1
  29. package/dist/components/tokens.d.cts +36 -1
  30. package/dist/components/tokens.d.ts +36 -1
  31. package/dist/components/tokens.js +176 -1
  32. package/dist/components/tokens.js.map +1 -1
  33. package/dist/components/widgets.cjs +611 -219
  34. package/dist/components/widgets.cjs.map +1 -1
  35. package/dist/components/widgets.d.cts +201 -2
  36. package/dist/components/widgets.d.ts +201 -2
  37. package/dist/components/widgets.js +605 -220
  38. package/dist/components/widgets.js.map +1 -1
  39. package/dist/components.cjs +4 -0
  40. package/dist/components.cjs.map +1 -1
  41. package/dist/components.d.cts +36 -1
  42. package/dist/components.d.ts +36 -1
  43. package/dist/components.js +1 -1
  44. package/dist/components.umd.js +2 -2
  45. package/dist/components.umd.js.map +1 -1
  46. package/dist/index.umd.js.map +1 -1
  47. package/dist/llms-full.txt +124 -1
  48. package/dist/llms.txt +7 -2
  49. package/dist/manifest.json +343 -1
  50. package/dist/runtime/format-apng.cjs +4 -4
  51. package/dist/runtime/format-apng.js +4 -4
  52. package/dist/runtime/format-css.cjs +4 -4
  53. package/dist/runtime/format-css.js +4 -4
  54. package/dist/runtime/format-gif.cjs +4 -4
  55. package/dist/runtime/format-gif.js +4 -4
  56. package/dist/runtime/format-gltf.cjs +1 -1
  57. package/dist/runtime/format-gltf.js +1 -1
  58. package/dist/runtime/format-motion.cjs +4 -4
  59. package/dist/runtime/format-motion.js +4 -4
  60. package/dist/runtime/format-obj.cjs +1 -1
  61. package/dist/runtime/format-obj.js +1 -1
  62. package/dist/runtime/format-sprite.cjs +3 -3
  63. package/dist/runtime/format-sprite.js +3 -3
  64. package/dist/runtime/format-svg.cjs +3 -3
  65. package/dist/runtime/format-svg.js +3 -3
  66. package/dist/runtime/format-webp.cjs +4 -4
  67. package/dist/runtime/format-webp.js +4 -4
  68. package/dist/runtime/gl.cjs +1 -1
  69. package/dist/runtime/gl.js +1 -1
  70. package/dist/runtime/scroll.cjs +2 -2
  71. package/dist/runtime/scroll.js +2 -2
  72. package/dist/runtime/smooth.cjs +1 -1
  73. package/dist/runtime/smooth.js +1 -1
  74. package/dist/runtime/text.cjs +1 -1
  75. package/dist/runtime/text.js +1 -1
  76. package/dist/runtime/vector.cjs +704 -0
  77. package/dist/runtime/vector.cjs.map +1 -0
  78. package/dist/runtime/vector.d.cts +306 -0
  79. package/dist/runtime/vector.d.ts +306 -0
  80. package/dist/runtime/vector.iife.js +2 -0
  81. package/dist/runtime/vector.iife.js.map +1 -0
  82. package/dist/runtime/vector.js +692 -0
  83. package/dist/runtime/vector.js.map +1 -0
  84. package/dist/runtime.cjs +3 -3
  85. package/dist/runtime.d.cts +1 -1
  86. package/dist/runtime.d.ts +1 -1
  87. package/dist/runtime.iife.js +1 -1
  88. package/dist/runtime.iife.js.map +1 -1
  89. package/dist/runtime.js +5 -5
  90. package/dist/widgets.umd.js +1 -1
  91. package/dist/widgets.umd.js.map +1 -1
  92. package/docs/ROADMAP.md +1 -1
  93. package/docs/components/README.md +4 -1
  94. package/docs/components/usa-lottie-player.md +60 -0
  95. package/docs/components/usa-rive.md +57 -0
  96. package/docs/components/usa-token-editor.md +32 -0
  97. package/docs/components.md +72 -0
  98. package/docs/runtime/rive.md +55 -0
  99. package/docs/runtime/vector.md +67 -0
  100. package/package.json +16 -2
@@ -1,4 +1,4 @@
1
- # Motionary 10.5.0 — full component reference
1
+ # Motionary 10.6.0 — full component reference
2
2
 
3
3
  Generated from the source. Machine-readable version: https://harrisoncn.github.io/Motionary/components.json (schema https://harrisoncn.github.io/Motionary/components.schema.json).
4
4
 
@@ -319,6 +319,49 @@ const cube = await loadObj('/models/cube.obj'); // + cube.mtl + textures next to
319
319
  new Scene().add(cube);
320
320
  ```
321
321
 
322
+ ### motionary/runtime/vector — Lottie + dotLottie player
323
+
324
+ Plays Lottie (bodymovin JSON) and dotLottie (.lottie) files on Canvas 2D with Motionary’s own renderer (no lottie-web code): shapes, gradients, trim paths, masks, track mattes, precomps, images; a runtime timeline you can seek, reverse and scrub.
325
+
326
+ - Install: `npm i motionary`
327
+ - Import: `motionary/runtime/vector`
328
+ - Register: `use(vector);` — Register the core first, then the module: use(vector) also registers the core. CDN: load runtime.iife.js, then runtime/vector.iife.js (it registers itself).
329
+ - CDN:
330
+
331
+ ```html
332
+ <script src="https://cdn.jsdelivr.net/npm/motionary@10/dist/runtime.iife.js"></script>
333
+ <script src="https://cdn.jsdelivr.net/npm/motionary@10/dist/runtime/vector.iife.js"></script>
334
+ ```
335
+
336
+ ```js
337
+ import { use } from 'motionary/runtime';
338
+ import { vector, loadLottie, lottiePlayer } from 'motionary/runtime/vector';
339
+ use(vector);
340
+ const { animation } = await loadLottie('/anim/hero.lottie');
341
+ const player = lottiePlayer(canvas, animation, { loop: true });
342
+ player.play();
343
+ ```
344
+
345
+ ### @rive-app/canvas — Official Rive runtime
346
+
347
+ The official MIT-licensed Rive runtime, used by <usa-rive> to play .riv files (artboards, animations, state machines with inputs). Optional peer dependency: lazy-loaded on first use, never bundled into Motionary.
348
+
349
+ - Install: `npm i @rive-app/canvas`
350
+ - Import: `@rive-app/canvas`
351
+ - Register: `provideRiveRuntime(() => import('@rive-app/canvas')); // lazy: fetched when the first <usa-rive> mounts` — Install the official runtime next to motionary, then hand <usa-rive> a lazy loader with provideRiveRuntime(() => import('@rive-app/canvas')) before the element mounts — your bundler splits the runtime into its own chunk, fetched only when the first <usa-rive> appears. Without a bundler: load the official rive.js from a CDN before the component bundles (window.rive), use an import map, or set runtime-src on the element. Missing → a clear message in place + usa:runtime-missing.
352
+ - CDN:
353
+
354
+ ```html
355
+ <script src="https://unpkg.com/@rive-app/canvas@2.44.1/rive.js"></script>
356
+ ```
357
+
358
+ ```js
359
+ // npm i @rive-app/canvas
360
+ import { defineRive } from 'motionary/components/widgets';
361
+ defineRive();
362
+ // <usa-rive src="/anim/icon.riv" state-machine="State Machine 1" autoplay></usa-rive>
363
+ ```
364
+
322
365
  ## Components
323
366
 
324
367
  ### <usa-accordion> — Accordion
@@ -1660,6 +1703,40 @@ A slim NProgress-style bar for route changes and fetches: loadingBar.start() tri
1660
1703
  <usa-lottie-icon name="bell" trigger="hover"></usa-lottie-icon>
1661
1704
  ```
1662
1705
 
1706
+ ### <usa-lottie-player> — Lottie player (JSON + dotLottie)
1707
+
1708
+ 10.6: plays Lottie JSON and dotLottie (.lottie) files with Motionary’s own Canvas 2D renderer — shapes, gradients, trim paths, masks, track mattes, precomps and images; autoplay, loop, bounce, segments / markers, play on hover or scrub with scroll. Requires motionary/runtime/vector — npm i motionary, then use(vector) before it mounts.
1709
+
1710
+ - Import: `import { defineLottiePlayer } from 'motionary/components/widgets'; defineLottiePlayer();`
1711
+ - CDN: https://unpkg.com/motionary@10/dist/widgets.umd.js
1712
+ - Attributes: `src`, `animation`, `autoplay`, `loop`, `speed`, `mode`, `segment`, `hover`, `scrub`, `fit`, `background`, `label`
1713
+ - Events: `usa:complete`, `usa:load`, `usa:error`, `usa:runtime-missing`
1714
+ - Methods: `play()`, `pause()`, `stop()`, `seek()`
1715
+ - Requires: motionary/runtime/vector
1716
+ - Install: `npm i motionary`
1717
+ - Order: Register the core first, then the module: use(vector) also registers the core. CDN: load runtime.iife.js, then runtime/vector.iife.js (it registers itself).
1718
+
1719
+ ```js
1720
+ import { use } from 'motionary/runtime';
1721
+ import { vector } from 'motionary/runtime/vector';
1722
+ import { defineLottiePlayer } from 'motionary/components/widgets';
1723
+
1724
+ use(vector);
1725
+ defineLottiePlayer(); // registers <usa-lottie-player> — after the prerequisites
1726
+ ```
1727
+
1728
+ ```html
1729
+ <script src="https://cdn.jsdelivr.net/npm/motionary@10/dist/runtime.iife.js"></script>
1730
+ <script src="https://cdn.jsdelivr.net/npm/motionary@10/dist/runtime/vector.iife.js"></script>
1731
+ <!-- then the component bundles -->
1732
+ <script src="https://unpkg.com/motionary@10/dist/components.umd.js"></script>
1733
+ <script src="https://unpkg.com/motionary@10/dist/widgets.umd.js"></script>
1734
+ ```
1735
+
1736
+ ```html
1737
+ <usa-lottie-player src="/anim/hero.lottie" autoplay loop label="Hero animation"></usa-lottie-player>
1738
+ ```
1739
+
1663
1740
  ### <usa-lyrics> — Synced karaoke lyrics
1664
1741
 
1665
1742
  7.1: LRC or [data-t] lines; the active line glows, scrolls to the centre and a highlight sweeps across it while past lines dim. Follows an <audio>, <video> or <usa-music-player> via for.
@@ -2507,6 +2584,38 @@ Ink ripple from the pointer — or from the centre for Space/Enter — on any bu
2507
2584
  <usa-ripple><button>Click me</button></usa-ripple>
2508
2585
  ```
2509
2586
 
2587
+ ### <usa-rive> — Rive player (official runtime)
2588
+
2589
+ 10.6: plays Rive (.riv) files — artboards, animations and state machines with inputs — through the official Rive runtime @rive-app/canvas, an optional peer dependency that is lazy-loaded on first use (Motionary does not reimplement the proprietary .riv format). Requires @rive-app/canvas — npm i @rive-app/canvas, or load its CDN script first; missing → a clear message in place.
2590
+
2591
+ - Import: `import { defineRive } from 'motionary/components/widgets'; defineRive();`
2592
+ - CDN: https://unpkg.com/motionary@10/dist/widgets.umd.js
2593
+ - Attributes: `src`, `artboard`, `animation`, `state-machine`, `autoplay`, `fit`, `label`, `runtime-src`
2594
+ - Events: `usa:load`, `usa:error`, `usa:runtime-missing`
2595
+ - Methods: `play()`, `pause()`, `input()`
2596
+ - Requires: @rive-app/canvas
2597
+ - Install: `npm i @rive-app/canvas`
2598
+ - Order: Install the official runtime next to motionary, then hand <usa-rive> a lazy loader with provideRiveRuntime(() => import('@rive-app/canvas')) before the element mounts — your bundler splits the runtime into its own chunk, fetched only when the first <usa-rive> appears. Without a bundler: load the official rive.js from a CDN before the component bundles (window.rive), use an import map, or set runtime-src on the element. Missing → a clear message in place + usa:runtime-missing.
2599
+
2600
+ ```js
2601
+ import { provideRiveRuntime } from 'motionary/components/widgets';
2602
+ import { defineRive } from 'motionary/components/widgets';
2603
+
2604
+ provideRiveRuntime(() => import('@rive-app/canvas')); // lazy: fetched when the first <usa-rive> mounts
2605
+ defineRive(); // registers <usa-rive> — after the prerequisites
2606
+ ```
2607
+
2608
+ ```html
2609
+ <script src="https://unpkg.com/@rive-app/canvas@2.44.1/rive.js"></script>
2610
+ <!-- then the component bundles -->
2611
+ <script src="https://unpkg.com/motionary@10/dist/components.umd.js"></script>
2612
+ <script src="https://unpkg.com/motionary@10/dist/widgets.umd.js"></script>
2613
+ ```
2614
+
2615
+ ```html
2616
+ <usa-rive src="/anim/icon.riv" state-machine="State Machine 1" autoplay label="Icon"></usa-rive>
2617
+ ```
2618
+
2510
2619
  ### <usa-route-transition> — Route transition container
2511
2620
 
2512
2621
  10.3: View Transitions 2.0 — link clicks swap the container’s content with the target page (fetched) or an inline <template data-route>, animated with the View Transitions API (Web Animations fallback); data-shared elements morph between routes; cross-document enables native MPA transitions.
@@ -3356,6 +3465,20 @@ toast("Saved") slides a notification in; it pauses on hover, stacks with FLIP an
3356
3465
  </script>
3357
3466
  ```
3358
3467
 
3468
+ ### <usa-token-editor> — Motion token editor (W3C DTCG)
3469
+
3470
+ 10.6 (motion design tokens 2.0): edit duration and cubic-bézier easing tokens with a live preview per token, then export W3C Design Tokens (DTCG 2025.10 or the earlier draft) or import a DTCG file — aliases resolved, problems listed; apply writes the tokens to :root custom properties as you edit.
3471
+
3472
+ - Import: `import { defineTokenEditor } from 'motionary/components/widgets'; defineTokenEditor();`
3473
+ - CDN: https://unpkg.com/motionary@10/dist/widgets.umd.js
3474
+ - Attributes: `apply`, `format`, `groups`
3475
+ - Events: `usa:export`, `usa:import`, `usa:change`
3476
+ - Methods: `exportJSON()`, `importJSON()`
3477
+
3478
+ ```html
3479
+ <usa-token-editor apply format="2025.10"></usa-token-editor>
3480
+ ```
3481
+
3359
3482
  ### <usa-typewriter> — Typewriter
3360
3483
 
3361
3484
  Types text, or cycles through phrases with delete and pause. Full text stays available to screen readers.
package/dist/llms.txt CHANGED
@@ -1,6 +1,6 @@
1
- # Motionary 10.5.0
1
+ # Motionary 10.6.0
2
2
 
3
- > Motionary is a zero-dependency motion library: scroll animations, 200+ presets and 202 animated Web Components (<usa-*>) that work in plain HTML and every framework, plus motionary/runtime — its own tween/timeline engine and format loaders.
3
+ > Motionary is a zero-dependency motion library: scroll animations, 200+ presets and 205 animated Web Components (<usa-*>) that work in plain HTML and every framework, plus motionary/runtime — its own tween/timeline engine and format loaders.
4
4
 
5
5
  Install: `npm i motionary` · CDN: https://unpkg.com/motionary@10/dist/components.umd.js (+ https://unpkg.com/motionary@10/dist/widgets.umd.js for 6.x+ widgets) · Manifest: https://harrisoncn.github.io/Motionary/components.json · Full text: https://harrisoncn.github.io/Motionary/llms-full.txt
6
6
 
@@ -22,6 +22,8 @@ Rules for using a component: (1) import its define function from `import.path` a
22
22
  - [motionary/runtime/gl](https://github.com/HarrisonCN/Motionary/blob/main/docs/runtime/gl.md): A small WebGL2 renderer with its own API: scene graph, camera, lights, box / plane / sphere / torus, PBR-style materials, shader materials, image and video textures, orbit controls — not a Three.js clone.
23
23
  - [motionary/runtime/format-gltf](https://github.com/HarrisonCN/Motionary/blob/main/docs/runtime/format-gltf.md): Load glTF 2.0 (.gltf with external or data: buffers, .glb) into motionary/runtime/gl nodes: node hierarchy, meshes, PBR metallic-roughness materials, embedded / external images.
24
24
  - [motionary/runtime/format-obj](https://github.com/HarrisonCN/Motionary/blob/main/docs/runtime/format-obj.md): Load Wavefront OBJ (+ MTL materials and diffuse textures) into motionary/runtime/gl nodes: polygons triangulated, groups, per-material meshes.
25
+ - [motionary/runtime/vector](https://github.com/HarrisonCN/Motionary/blob/main/docs/runtime/vector.md): Plays Lottie (bodymovin JSON) and dotLottie (.lottie) files on Canvas 2D with Motionary’s own renderer (no lottie-web code): shapes, gradients, trim paths, masks, track mattes, precomps, images; a runtime timeline you can seek, reverse and scrub.
26
+ - [@rive-app/canvas](https://github.com/HarrisonCN/Motionary/blob/main/docs/runtime/rive.md): The official MIT-licensed Rive runtime, used by <usa-rive> to play .riv files (artboards, animations, state machines with inputs). Optional peer dependency: lazy-loaded on first use, never bundled into Motionary.
25
27
 
26
28
  ## Components
27
29
 
@@ -111,6 +113,7 @@ Rules for using a component: (1) import its define function from `import.path` a
111
113
  - `<usa-location-card>` (motionary/components/widgets): 7.6: a place card with a stylised mini map — the route from the origin draws itself, the pin drops in with a bounce and a ring pulses; distance computed with ha
112
114
  - `<usa-lottie>` (motionary/components/widgets): 9.2: plays Lottie (After Effects / bodymovin) files without lottie-web — vector layers render as SVG and their keyframes run as native animations on Motionary’s
113
115
  - `<usa-lottie-icon>` (motionary/components/widgets): 9.2: an animated icon set shipped as tiny Lottie files — heart beat, bell swing, check draw-in, spinner, star twinkle, bolt zap — on click, hover, enter or loop
116
+ - `<usa-lottie-player>` (motionary/components/widgets; requires motionary/runtime/vector): 10.6: plays Lottie JSON and dotLottie (.lottie) files with Motionary’s own Canvas 2D renderer — shapes, gradients, trim paths, masks, track mattes, precomps and
114
117
  - `<usa-lyrics>` (motionary/components/widgets): 7.1: LRC or [data-t] lines; the active line glows, scrolls to the centre and a highlight sweeps across it while past lines dim. Follows an <audio>, <video> or <
115
118
  - `<usa-magnetic>` (motionary/components/interaction): Content leans toward the pointer when it comes near and springs back. Fine pointers only; off under reduced motion.
116
119
  - `<usa-marquee>` (motionary/components/background): A seamless infinite ticker with constant speed, pause on hover, soft edges and vertical mode. Clones are hidden from AT.
@@ -166,6 +169,7 @@ Rules for using a component: (1) import its define function from `import.path` a
166
169
  - `<usa-retro-button>` (motionary/components/widgets): 8.2: buttons in four eras with matching press motion — 8-bit pixel (stepped press), CRT phosphor (flicker), Y2K chrome pill (bounce) and Windows 95 bevel (sink)
167
170
  - `<usa-reveal>` (motionary/components/reveal): Fade, slide, zoom, blur or flip content in as it enters the viewport. 12 effects, replay on re-entry with repeat.
168
171
  - `<usa-ripple>` (motionary/components/interaction): Ink ripple from the pointer — or from the centre for Space/Enter — on any button, list item or card.
172
+ - `<usa-rive>` (motionary/components/widgets; requires @rive-app/canvas): 10.6: plays Rive (.riv) files — artboards, animations and state machines with inputs — through the official Rive runtime @rive-app/canvas, an optional peer depe
169
173
  - `<usa-route-transition>` (motionary/components/widgets): 10.3: View Transitions 2.0 — link clicks swap the container’s content with the target page (fetched) or an inline <template data-route>, animated with the View
170
174
  - `<usa-scene>` (motionary/components/widgets): 9.1: a scroll-scrubbed cinematic shot — while the scene crosses the screen its image follows a camera move (dolly, pan, tilt, zoom, orbit) and captions fade in
171
175
  - `<usa-scramble>` (motionary/components/text): Decodes text out of random glyphs, left to right. Trigger on view, hover/focus or manually.
@@ -216,6 +220,7 @@ Rules for using a component: (1) import its define function from `import.path` a
216
220
  - `<usa-tip>` (motionary/components/widgets): 6.6: springs out of its trigger with an arrow, flips to stay inside the viewport and shifts along the edge; hover + keyboard focus (Esc closes) or click popover
217
221
  - `<usa-toast-stack>` (motionary/components/widgets): 6.3: toasts pile up into a collapsed stack (newest in front, older ones peeking behind), fan out on hover or focus, auto-dismiss (paused while hovered) and swip
218
222
  - `<usa-toaster>` (motionary/components/feedback): toast("Saved") slides a notification in; it pauses on hover, stacks with FLIP and announces politely (errors assertively).
223
+ - `<usa-token-editor>` (motionary/components/widgets): 10.6 (motion design tokens 2.0): edit duration and cubic-bézier easing tokens with a live preview per token, then export W3C Design Tokens (DTCG 2025.10 or the
219
224
  - `<usa-typewriter>` (motionary/components/text): Types text, or cycles through phrases with delete and pause. Full text stays available to screen readers.
220
225
  - `<usa-upload-progress>` (motionary/components/widgets): 7.7: a file row whose bar eases to value with a running shine; at 100 it turns into a check that draws itself, on error it shakes and offers Retry.
221
226
  - `<usa-video-card>` (motionary/components/widgets): 9.4: a video thumbnail card — hover or focus plays a muted preview with a progress line, a play badge and a duration chip; without a video the poster drifts (Ke
@@ -3,7 +3,7 @@
3
3
  "format": "motionary/components",
4
4
  "schemaVersion": 1,
5
5
  "package": "motionary",
6
- "version": "10.5.0",
6
+ "version": "10.6.0",
7
7
  "homepage": "https://harrisoncn.github.io/Motionary/",
8
8
  "llms": "https://harrisoncn.github.io/Motionary/llms.txt",
9
9
  "cdn": {
@@ -977,6 +977,174 @@
977
977
  ]
978
978
  ],
979
979
  "example": "import { use } from 'motionary/runtime';\nimport { gl, Scene } from 'motionary/runtime/gl';\nimport { formatObj, loadObj } from 'motionary/runtime/format-obj';\nuse(gl, formatObj);\nconst cube = await loadObj('/models/cube.obj'); // + cube.mtl + textures next to it\nnew Scene().add(cube);"
980
+ },
981
+ {
982
+ "kind": "runtime",
983
+ "id": "vector",
984
+ "label": "motionary/runtime/vector",
985
+ "title": "Lottie + dotLottie player",
986
+ "summary": "Plays Lottie (bodymovin JSON) and dotLottie (.lottie) files on Canvas 2D with Motionary’s own renderer (no lottie-web code): shapes, gradients, trim paths, masks, track mattes, precomps, images; a runtime timeline you can seek, reverse and scrub.",
987
+ "install": "npm i motionary",
988
+ "importPath": "motionary/runtime/vector",
989
+ "import": "import { use } from 'motionary/runtime';\nimport { vector } from 'motionary/runtime/vector';",
990
+ "register": "use(vector);",
991
+ "cdn": "<script src=\"https://cdn.jsdelivr.net/npm/motionary@10/dist/runtime.iife.js\"></script>\n<script src=\"https://cdn.jsdelivr.net/npm/motionary@10/dist/runtime/vector.iife.js\"></script>",
992
+ "cdnEsm": "https://cdn.jsdelivr.net/npm/motionary@10/dist/runtime/vector.js",
993
+ "order": "Register the core first, then the module: use(vector) also registers the core. CDN: load runtime.iife.js, then runtime/vector.iife.js (it registers itself).",
994
+ "docs": "docs/runtime/vector.md",
995
+ "budget": 12288,
996
+ "exports": [
997
+ "vector",
998
+ "loadLottie",
999
+ "parseDotLottie",
1000
+ "unzipEntries",
1001
+ "lottiePlayer",
1002
+ "renderLottieFrame",
1003
+ "inspectLottie",
1004
+ "propValue",
1005
+ "transformAt",
1006
+ "trimContours",
1007
+ "loadLottieImages"
1008
+ ],
1009
+ "compat": [
1010
+ [
1011
+ "shape, solid, null, image and precomp layers; parenting; in / out points",
1012
+ "yes",
1013
+ "precomp time stretch + time remap"
1014
+ ],
1015
+ [
1016
+ "transforms: anchor, position (split X / Y, spatial bezier), scale, rotation, skew, opacity",
1017
+ "yes",
1018
+ ""
1019
+ ],
1020
+ [
1021
+ "paths, rectangles (rounded), ellipses, stars / polygons, groups",
1022
+ "yes",
1023
+ ""
1024
+ ],
1025
+ [
1026
+ "fills (non-zero / even-odd), strokes (caps, joins, dashes)",
1027
+ "yes",
1028
+ ""
1029
+ ],
1030
+ [
1031
+ "linear + radial gradient fills / strokes",
1032
+ "yes",
1033
+ "highlight length / angle ignored"
1034
+ ],
1035
+ [
1036
+ "trim paths (individually / simultaneously)",
1037
+ "yes",
1038
+ ""
1039
+ ],
1040
+ [
1041
+ "masks: add, subtract, intersect, inverted, opacity",
1042
+ "yes",
1043
+ ""
1044
+ ],
1045
+ [
1046
+ "track mattes: alpha, alpha inverted",
1047
+ "yes",
1048
+ "luma mattes approximated by alpha"
1049
+ ],
1050
+ [
1051
+ "keyframes: per-dimension bezier easing, hold keyframes, v4 + v5 files",
1052
+ "yes",
1053
+ ""
1054
+ ],
1055
+ [
1056
+ "dotLottie (.lottie): stored + deflate entries, manifest v1 / v2, several animations, embedded images",
1057
+ "yes",
1058
+ "deflate needs the native DecompressionStream"
1059
+ ],
1060
+ [
1061
+ "markers → named segments",
1062
+ "yes",
1063
+ ""
1064
+ ],
1065
+ [
1066
+ "text layers, expressions",
1067
+ "no",
1068
+ "planned for 10.8 (subset)"
1069
+ ],
1070
+ [
1071
+ "3D layers, layer effects, merge paths, repeaters",
1072
+ "no",
1073
+ "listed by inspectLottie() / el.unsupported"
1074
+ ],
1075
+ [
1076
+ "dotLottie themes / state machines",
1077
+ "no",
1078
+ "planned for 10.9 (subset)"
1079
+ ],
1080
+ [
1081
+ "SSR / workers",
1082
+ "partial",
1083
+ "parsing + unzip are pure; rendering needs a 2D canvas (OffscreenCanvas works)"
1084
+ ]
1085
+ ],
1086
+ "example": "import { use } from 'motionary/runtime';\nimport { vector, loadLottie, lottiePlayer } from 'motionary/runtime/vector';\nuse(vector);\nconst { animation } = await loadLottie('/anim/hero.lottie');\nconst player = lottiePlayer(canvas, animation, { loop: true });\nplayer.play();"
1087
+ },
1088
+ {
1089
+ "kind": "peer",
1090
+ "id": "rive",
1091
+ "label": "@rive-app/canvas",
1092
+ "title": "Official Rive runtime",
1093
+ "summary": "The official MIT-licensed Rive runtime, used by <usa-rive> to play .riv files (artboards, animations, state machines with inputs). Optional peer dependency: lazy-loaded on first use, never bundled into Motionary.",
1094
+ "install": "npm i @rive-app/canvas",
1095
+ "importPath": "@rive-app/canvas",
1096
+ "import": "import { provideRiveRuntime } from 'motionary/components/widgets';",
1097
+ "register": "provideRiveRuntime(() => import('@rive-app/canvas')); // lazy: fetched when the first <usa-rive> mounts",
1098
+ "cdn": "<script src=\"https://unpkg.com/@rive-app/canvas@2.44.1/rive.js\"></script>",
1099
+ "cdnEsm": "https://cdn.jsdelivr.net/npm/@rive-app/canvas@2.44.1/+esm",
1100
+ "order": "Install the official runtime next to motionary, then hand <usa-rive> a lazy loader with provideRiveRuntime(() => import('@rive-app/canvas')) before the element mounts — your bundler splits the runtime into its own chunk, fetched only when the first <usa-rive> appears. Without a bundler: load the official rive.js from a CDN before the component bundles (window.rive), use an import map, or set runtime-src on the element. Missing → a clear message in place + usa:runtime-missing.",
1101
+ "why": ".riv is Rive’s proprietary binary format with a state-machine runtime; the official runtime is the only faithful player, so Motionary does not reimplement it",
1102
+ "docs": "docs/runtime/rive.md",
1103
+ "budget": 0,
1104
+ "exports": [
1105
+ "provideRiveRuntime",
1106
+ "loadRiveRuntime",
1107
+ "RIVE_PEER",
1108
+ "RIVE_CDN"
1109
+ ],
1110
+ "compat": [
1111
+ [
1112
+ ".riv files: artboards, linear animations",
1113
+ "yes",
1114
+ "played by the official runtime"
1115
+ ],
1116
+ [
1117
+ "state machines + inputs (boolean, number, trigger)",
1118
+ "yes",
1119
+ "el.input(name)"
1120
+ ],
1121
+ [
1122
+ "fit: contain, cover, fill, fitWidth, fitHeight, none",
1123
+ "yes",
1124
+ ""
1125
+ ],
1126
+ [
1127
+ "lazy loading, clear error when the runtime is missing",
1128
+ "yes",
1129
+ "usa:runtime-missing"
1130
+ ],
1131
+ [
1132
+ "reduced motion",
1133
+ "yes",
1134
+ "no autoplay (first frame)"
1135
+ ],
1136
+ [
1137
+ "WebGL2 renderer (@rive-app/webgl2)",
1138
+ "partial",
1139
+ "pass its URL as runtime-src or provideRiveRuntime(() => import('@rive-app/webgl2'))"
1140
+ ],
1141
+ [
1142
+ "SSR",
1143
+ "yes",
1144
+ "nothing loads until the element mounts in a browser"
1145
+ ]
1146
+ ],
1147
+ "example": "// npm i @rive-app/canvas\nimport { defineRive } from 'motionary/components/widgets';\ndefineRive();\n// <usa-rive src=\"/anim/icon.riv\" state-machine=\"State Machine 1\" autoplay></usa-rive>"
980
1148
  }
981
1149
  ],
982
1150
  "components": [
@@ -4612,6 +4780,75 @@
4612
4780
  "prerequisites": null,
4613
4781
  "source": "src/components/widgets/lottie-icon.ts"
4614
4782
  },
4783
+ {
4784
+ "id": "lottie-player",
4785
+ "tag": "usa-lottie-player",
4786
+ "title": "Lottie player (JSON + dotLottie)",
4787
+ "description": "10.6: plays Lottie JSON and dotLottie (.lottie) files with Motionary’s own Canvas 2D renderer — shapes, gradients, trim paths, masks, track mattes, precomps and images; autoplay, loop, bounce, segments / markers, play on hover or scrub with scroll. Requires motionary/runtime/vector — npm i motionary, then use(vector) before it mounts.",
4788
+ "category": "ui",
4789
+ "since": "10.6",
4790
+ "keywords": [
4791
+ "lottie",
4792
+ "dotlottie",
4793
+ "bodymovin",
4794
+ "vector animation",
4795
+ "player",
4796
+ "runtime"
4797
+ ],
4798
+ "import": {
4799
+ "path": "motionary/components/widgets",
4800
+ "define": "defineLottiePlayer",
4801
+ "register": "defineLottiePlayer();"
4802
+ },
4803
+ "cdn": "https://unpkg.com/motionary@10/dist/widgets.umd.js",
4804
+ "attributes": [
4805
+ "src",
4806
+ "animation",
4807
+ "autoplay",
4808
+ "loop",
4809
+ "speed",
4810
+ "mode",
4811
+ "segment",
4812
+ "hover",
4813
+ "scrub",
4814
+ "fit",
4815
+ "background",
4816
+ "label"
4817
+ ],
4818
+ "events": [
4819
+ "usa:complete",
4820
+ "usa:load",
4821
+ "usa:error",
4822
+ "usa:runtime-missing"
4823
+ ],
4824
+ "slots": [],
4825
+ "methods": [
4826
+ "play",
4827
+ "pause",
4828
+ "stop",
4829
+ "seek"
4830
+ ],
4831
+ "example": "<usa-lottie-player src=\"/anim/hero.lottie\" autoplay loop label=\"Hero animation\"></usa-lottie-player>",
4832
+ "esm": "import { use } from 'motionary/runtime';\nimport { vector } from 'motionary/runtime/vector';\n\nuse(vector);\nimport { defineLottiePlayer } from 'motionary/components/widgets';\n\ndefineLottiePlayer(); // registers <usa-lottie-player>\n\n/* then use it in your HTML:\n<usa-lottie-player src=\"/anim/hero.lottie\" autoplay loop label=\"Hero animation\"></usa-lottie-player>\n*/",
4833
+ "requires": [
4834
+ "vector"
4835
+ ],
4836
+ "prerequisites": {
4837
+ "badge": "Requires: motionary/runtime/vector",
4838
+ "modules": [
4839
+ "motionary/runtime/vector"
4840
+ ],
4841
+ "install": "npm i motionary",
4842
+ "importAndRegister": "import { use } from 'motionary/runtime';\nimport { vector } from 'motionary/runtime/vector';\nimport { defineLottiePlayer } from 'motionary/components/widgets';\n\nuse(vector);\ndefineLottiePlayer(); // registers <usa-lottie-player> — after the prerequisites",
4843
+ "order": "Register the core first, then the module: use(vector) also registers the core. CDN: load runtime.iife.js, then runtime/vector.iife.js (it registers itself).",
4844
+ "cdn": "<script src=\"https://cdn.jsdelivr.net/npm/motionary@10/dist/runtime.iife.js\"></script>\n<script src=\"https://cdn.jsdelivr.net/npm/motionary@10/dist/runtime/vector.iife.js\"></script>\n<!-- then the component bundles -->\n<script src=\"https://unpkg.com/motionary@10/dist/components.umd.js\"></script>\n<script src=\"https://unpkg.com/motionary@10/dist/widgets.umd.js\"></script>",
4845
+ "example": "<usa-lottie-player src=\"/anim/hero.lottie\" autoplay loop label=\"Hero animation\"></usa-lottie-player>",
4846
+ "docs": [
4847
+ "https://github.com/HarrisonCN/Motionary/blob/main/docs/runtime/vector.md"
4848
+ ]
4849
+ },
4850
+ "source": "src/components/widgets/lottie-player.ts"
4851
+ },
4615
4852
  {
4616
4853
  "id": "lyrics",
4617
4854
  "tag": "usa-lyrics",
@@ -6602,6 +6839,69 @@
6602
6839
  "prerequisites": null,
6603
6840
  "source": "src/components/interaction/ripple.ts"
6604
6841
  },
6842
+ {
6843
+ "id": "rive",
6844
+ "tag": "usa-rive",
6845
+ "title": "Rive player (official runtime)",
6846
+ "description": "10.6: plays Rive (.riv) files — artboards, animations and state machines with inputs — through the official Rive runtime @rive-app/canvas, an optional peer dependency that is lazy-loaded on first use (Motionary does not reimplement the proprietary .riv format). Requires @rive-app/canvas — npm i @rive-app/canvas, or load its CDN script first; missing → a clear message in place.",
6847
+ "category": "ui",
6848
+ "since": "10.6",
6849
+ "keywords": [
6850
+ "rive",
6851
+ "riv",
6852
+ "state machine",
6853
+ "interactive animation",
6854
+ "official runtime",
6855
+ "peer"
6856
+ ],
6857
+ "import": {
6858
+ "path": "motionary/components/widgets",
6859
+ "define": "defineRive",
6860
+ "register": "defineRive();"
6861
+ },
6862
+ "cdn": "https://unpkg.com/motionary@10/dist/widgets.umd.js",
6863
+ "attributes": [
6864
+ "src",
6865
+ "artboard",
6866
+ "animation",
6867
+ "state-machine",
6868
+ "autoplay",
6869
+ "fit",
6870
+ "label",
6871
+ "runtime-src"
6872
+ ],
6873
+ "events": [
6874
+ "usa:load",
6875
+ "usa:error",
6876
+ "usa:runtime-missing"
6877
+ ],
6878
+ "slots": [],
6879
+ "methods": [
6880
+ "play",
6881
+ "pause",
6882
+ "input"
6883
+ ],
6884
+ "example": "<usa-rive src=\"/anim/icon.riv\" state-machine=\"State Machine 1\" autoplay label=\"Icon\"></usa-rive>",
6885
+ "esm": "import { provideRiveRuntime } from 'motionary/components/widgets';\n\nprovideRiveRuntime(() => import('@rive-app/canvas')); // lazy: fetched when the first <usa-rive> mounts\nimport { defineRive } from 'motionary/components/widgets';\n\ndefineRive(); // registers <usa-rive>\n\n/* then use it in your HTML:\n<usa-rive src=\"/anim/icon.riv\" state-machine=\"State Machine 1\" autoplay label=\"Icon\"></usa-rive>\n*/",
6886
+ "requires": [
6887
+ "rive"
6888
+ ],
6889
+ "prerequisites": {
6890
+ "badge": "Requires: @rive-app/canvas",
6891
+ "modules": [
6892
+ "@rive-app/canvas"
6893
+ ],
6894
+ "install": "npm i @rive-app/canvas",
6895
+ "importAndRegister": "import { provideRiveRuntime } from 'motionary/components/widgets';\nimport { defineRive } from 'motionary/components/widgets';\n\nprovideRiveRuntime(() => import('@rive-app/canvas')); // lazy: fetched when the first <usa-rive> mounts\ndefineRive(); // registers <usa-rive> — after the prerequisites",
6896
+ "order": "Install the official runtime next to motionary, then hand <usa-rive> a lazy loader with provideRiveRuntime(() => import('@rive-app/canvas')) before the element mounts — your bundler splits the runtime into its own chunk, fetched only when the first <usa-rive> appears. Without a bundler: load the official rive.js from a CDN before the component bundles (window.rive), use an import map, or set runtime-src on the element. Missing → a clear message in place + usa:runtime-missing.",
6897
+ "cdn": "<script src=\"https://unpkg.com/@rive-app/canvas@2.44.1/rive.js\"></script>\n<!-- then the component bundles -->\n<script src=\"https://unpkg.com/motionary@10/dist/components.umd.js\"></script>\n<script src=\"https://unpkg.com/motionary@10/dist/widgets.umd.js\"></script>",
6898
+ "example": "<usa-rive src=\"/anim/icon.riv\" state-machine=\"State Machine 1\" autoplay label=\"Icon\"></usa-rive>",
6899
+ "docs": [
6900
+ "https://github.com/HarrisonCN/Motionary/blob/main/docs/runtime/rive.md"
6901
+ ]
6902
+ },
6903
+ "source": "src/components/widgets/rive.ts"
6904
+ },
6605
6905
  {
6606
6906
  "id": "route-transition",
6607
6907
  "tag": "usa-route-transition",
@@ -8469,6 +8769,48 @@
8469
8769
  "prerequisites": null,
8470
8770
  "source": "src/components/feedback/toast.ts"
8471
8771
  },
8772
+ {
8773
+ "id": "token-editor",
8774
+ "tag": "usa-token-editor",
8775
+ "title": "Motion token editor (W3C DTCG)",
8776
+ "description": "10.6 (motion design tokens 2.0): edit duration and cubic-bézier easing tokens with a live preview per token, then export W3C Design Tokens (DTCG 2025.10 or the earlier draft) or import a DTCG file — aliases resolved, problems listed; apply writes the tokens to :root custom properties as you edit.",
8777
+ "category": "ui",
8778
+ "since": "10.6",
8779
+ "keywords": [
8780
+ "design tokens",
8781
+ "dtcg",
8782
+ "w3c",
8783
+ "motion tokens",
8784
+ "easing",
8785
+ "duration"
8786
+ ],
8787
+ "import": {
8788
+ "path": "motionary/components/widgets",
8789
+ "define": "defineTokenEditor",
8790
+ "register": "defineTokenEditor();"
8791
+ },
8792
+ "cdn": "https://unpkg.com/motionary@10/dist/widgets.umd.js",
8793
+ "attributes": [
8794
+ "apply",
8795
+ "format",
8796
+ "groups"
8797
+ ],
8798
+ "events": [
8799
+ "usa:export",
8800
+ "usa:import",
8801
+ "usa:change"
8802
+ ],
8803
+ "slots": [],
8804
+ "methods": [
8805
+ "exportJSON",
8806
+ "importJSON"
8807
+ ],
8808
+ "example": "<usa-token-editor apply format=\"2025.10\"></usa-token-editor>",
8809
+ "esm": "import { defineTokenEditor } from 'motionary/components/widgets';\n\ndefineTokenEditor(); // registers <usa-token-editor>\n\n/* then use it in your HTML:\n<usa-token-editor apply format=\"2025.10\"></usa-token-editor>\n*/",
8810
+ "requires": [],
8811
+ "prerequisites": null,
8812
+ "source": "src/components/widgets/token-editor.ts"
8813
+ },
8472
8814
  {
8473
8815
  "id": "typewriter",
8474
8816
  "tag": "usa-typewriter",
@@ -1,9 +1,9 @@
1
1
  'use strict';
2
2
 
3
- var registry = require('../chunks/registry-VhfPSI0v.cjs');
4
- var animImage = require('../chunks/anim-image-DuxvYhq6.cjs');
5
- require('../chunks/tween-_BGIl6hK.cjs');
6
- require('../chunks/ticker-DvmC6WLS.cjs');
3
+ var registry = require('../chunks/registry-dr1CPTk1.cjs');
4
+ var animImage = require('../chunks/anim-image-DECLkPH4.cjs');
5
+ require('../chunks/tween-CmkdSyaC.cjs');
6
+ require('../chunks/ticker-DaAlEyOd.cjs');
7
7
  require('../chunks/ease-HwYZnZat.cjs');
8
8
 
9
9
  /**
@@ -1,7 +1,7 @@
1
- import { R as RUNTIME_VERSION } from '../chunks/registry-DXdFb2fJ.js';
2
- import { a as animatedImagePlayer, b as browserDecode, c as composeFrames, d as bytesOf, u as u8, f as fixDelay, e as crc32 } from '../chunks/anim-image-BlNPv4JG.js';
3
- import '../chunks/tween-CPtm-EdT.js';
4
- import '../chunks/ticker-C5RMHMW7.js';
1
+ import { R as RUNTIME_VERSION } from '../chunks/registry-D8LAoXI-.js';
2
+ import { a as animatedImagePlayer, b as browserDecode, c as composeFrames, d as bytesOf, u as u8, f as fixDelay, e as crc32 } from '../chunks/anim-image-DNghy017.js';
3
+ import '../chunks/tween-BzCGq_Ba.js';
4
+ import '../chunks/ticker-Do9bGsaV.js';
5
5
  import '../chunks/ease-XN8_0sXu.js';
6
6
 
7
7
  /**
@@ -1,9 +1,9 @@
1
1
  'use strict';
2
2
 
3
- var registry = require('../chunks/registry-VhfPSI0v.cjs');
4
- var keyframes = require('../chunks/keyframes-Ce1s05n3.cjs');
5
- require('../chunks/tween-_BGIl6hK.cjs');
6
- require('../chunks/ticker-DvmC6WLS.cjs');
3
+ var registry = require('../chunks/registry-dr1CPTk1.cjs');
4
+ var keyframes = require('../chunks/keyframes-CbUZjD_5.cjs');
5
+ require('../chunks/tween-CmkdSyaC.cjs');
6
+ require('../chunks/ticker-DaAlEyOd.cjs');
7
7
  require('../chunks/ease-HwYZnZat.cjs');
8
8
 
9
9
  /**
@@ -1,7 +1,7 @@
1
- import { R as RUNTIME_VERSION } from '../chunks/registry-DXdFb2fJ.js';
2
- import { f as framesToTimeline, d as distributeOffsets, c as camelProp } from '../chunks/keyframes-B8ITIAVa.js';
3
- import '../chunks/tween-CPtm-EdT.js';
4
- import '../chunks/ticker-C5RMHMW7.js';
1
+ import { R as RUNTIME_VERSION } from '../chunks/registry-D8LAoXI-.js';
2
+ import { f as framesToTimeline, d as distributeOffsets, c as camelProp } from '../chunks/keyframes-F6vp6tZZ.js';
3
+ import '../chunks/tween-BzCGq_Ba.js';
4
+ import '../chunks/ticker-Do9bGsaV.js';
5
5
  import '../chunks/ease-XN8_0sXu.js';
6
6
 
7
7
  /**
@@ -1,9 +1,9 @@
1
1
  'use strict';
2
2
 
3
- var registry = require('../chunks/registry-VhfPSI0v.cjs');
4
- var animImage = require('../chunks/anim-image-DuxvYhq6.cjs');
5
- require('../chunks/tween-_BGIl6hK.cjs');
6
- require('../chunks/ticker-DvmC6WLS.cjs');
3
+ var registry = require('../chunks/registry-dr1CPTk1.cjs');
4
+ var animImage = require('../chunks/anim-image-DECLkPH4.cjs');
5
+ require('../chunks/tween-CmkdSyaC.cjs');
6
+ require('../chunks/ticker-DaAlEyOd.cjs');
7
7
  require('../chunks/ease-HwYZnZat.cjs');
8
8
 
9
9
  /**