motionary 9.9.0 → 10.1.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/CHANGELOG.md +41 -0
- package/README.md +45 -0
- package/bin/create-motionary-plugin.mjs +124 -0
- package/dist/chunks/{audio-C1uFaOKQ.js → audio-D95jwlOh.js} +3 -3
- package/dist/chunks/{audio-C1uFaOKQ.js.map → audio-D95jwlOh.js.map} +1 -1
- package/dist/chunks/{base-DWYNLg6P.js → base-BnRyfuyM.js} +2 -2
- package/dist/chunks/{base-DWYNLg6P.js.map → base-BnRyfuyM.js.map} +1 -1
- package/dist/chunks/{builtins-DoCY96r9.js → builtins-CqIq1zBv.js} +3 -3
- package/dist/chunks/{builtins-DoCY96r9.js.map → builtins-CqIq1zBv.js.map} +1 -1
- package/dist/chunks/{core-DoR4w-E4.js → core-DsGoL9EY.js} +2 -2
- package/dist/chunks/{core-DoR4w-E4.js.map → core-DsGoL9EY.js.map} +1 -1
- package/dist/chunks/{core-BhuojMcL.js → core-XA2yhn1b.js} +2 -2
- package/dist/chunks/{core-BhuojMcL.js.map → core-XA2yhn1b.js.map} +1 -1
- package/dist/chunks/{fx-XBDr7-dH.js → fx-CtnrFEg9.js} +2 -2
- package/dist/chunks/{fx-XBDr7-dH.js.map → fx-CtnrFEg9.js.map} +1 -1
- package/dist/chunks/{gpu-DvLHwLxy.js → gpu-CDcXiNA8.js} +2 -2
- package/dist/chunks/{gpu-DvLHwLxy.js.map → gpu-CDcXiNA8.js.map} +1 -1
- package/dist/chunks/keyframes-CyH_abhI.js +183 -0
- package/dist/chunks/keyframes-CyH_abhI.js.map +1 -0
- package/dist/chunks/keyframes-cUdsXSXQ.cjs +187 -0
- package/dist/chunks/keyframes-cUdsXSXQ.cjs.map +1 -0
- package/dist/chunks/{manifest-BDpbuI-9.js → manifest-D58HXVY-.js} +2 -2
- package/dist/chunks/{manifest-BDpbuI-9.js.map → manifest-D58HXVY-.js.map} +1 -1
- package/dist/chunks/{player-CYGvna09.js → player-48Zy_NBG.js} +4 -4
- package/dist/chunks/{player-CYGvna09.js.map → player-48Zy_NBG.js.map} +1 -1
- package/dist/chunks/registry-C0xLNq3-.cjs +81 -0
- package/dist/chunks/registry-C0xLNq3-.cjs.map +1 -0
- package/dist/chunks/{registry-BRM2BRRY.js → registry-gFJRpPES.js} +2 -2
- package/dist/chunks/{registry-BRM2BRRY.js.map → registry-gFJRpPES.js.map} +1 -1
- package/dist/chunks/registry-jF8VIA_9.js +69 -0
- package/dist/chunks/registry-jF8VIA_9.js.map +1 -0
- package/dist/chunks/{spring-CAlkc1co.js → spring-CZDNyqWp.js} +2 -2
- package/dist/chunks/{spring-CAlkc1co.js.map → spring-CZDNyqWp.js.map} +1 -1
- package/dist/chunks/tween-DDObu9iA.js +542 -0
- package/dist/chunks/tween-DDObu9iA.js.map +1 -0
- package/dist/chunks/tween-JEthWrjo.cjs +554 -0
- package/dist/chunks/tween-JEthWrjo.cjs.map +1 -0
- package/dist/chunks/{variants-BBfyVPYm.js → variants-GU3yIL4F.js} +2 -2
- package/dist/chunks/{variants-BBfyVPYm.js.map → variants-GU3yIL4F.js.map} +1 -1
- package/dist/components/a11y.js +2 -2
- package/dist/components/angular.js +8 -8
- package/dist/components/background.js +2 -2
- package/dist/components/bridge.js +1 -1
- package/dist/components/cards.js +2 -2
- package/dist/components/click.js +3 -3
- package/dist/components/core.cjs +219 -0
- package/dist/components/core.cjs.map +1 -0
- package/dist/components/core.d.cts +81 -0
- package/dist/components/core.d.ts +81 -0
- package/dist/components/core.js +214 -0
- package/dist/components/core.js.map +1 -0
- package/dist/components/depth.js +3 -3
- package/dist/components/design.js +3 -3
- package/dist/components/dsl.js +2 -2
- package/dist/components/effects.js +9 -9
- package/dist/components/engine.js +2 -2
- package/dist/components/feedback.js +1 -1
- package/dist/components/fx-3d.js +2 -2
- package/dist/components/fx-ai.js +2 -2
- package/dist/components/fx-chart.js +2 -2
- package/dist/components/fx-cinema.js +2 -2
- package/dist/components/fx-cyber.js +2 -2
- package/dist/components/fx-festival.js +2 -2
- package/dist/components/fx-focus.js +2 -2
- package/dist/components/fx-form.js +2 -2
- package/dist/components/fx-game.js +2 -2
- package/dist/components/fx-genart.js +2 -2
- package/dist/components/fx-geo.js +2 -2
- package/dist/components/fx-gesture.js +2 -2
- package/dist/components/fx-gpu.js +3 -3
- package/dist/components/fx-light.js +2 -2
- package/dist/components/fx-lottie.js +2 -2
- package/dist/components/fx-morph.js +2 -2
- package/dist/components/fx-music.js +3 -3
- package/dist/components/fx-organic.js +2 -2
- package/dist/components/fx-paper.js +2 -2
- package/dist/components/fx-perf.js +2 -2
- package/dist/components/fx-physics.js +2 -2
- package/dist/components/fx-retro.js +2 -2
- package/dist/components/fx-safe.js +2 -2
- package/dist/components/fx-shop.js +2 -2
- package/dist/components/fx-social.js +2 -2
- package/dist/components/fx-spatial.js +2 -2
- package/dist/components/fx-surface.js +2 -2
- package/dist/components/fx-text.js +2 -2
- package/dist/components/fx-transitions.js +3 -3
- package/dist/components/fx-video.js +2 -2
- package/dist/components/fx-weather.js +2 -2
- package/dist/components/fx.js +6 -6
- package/dist/components/fx2.cjs +1 -10
- package/dist/components/fx2.cjs.map +1 -1
- package/dist/components/fx2.d.cts +1 -6
- package/dist/components/fx2.d.ts +1 -6
- package/dist/components/fx2.js +7 -15
- package/dist/components/fx2.js.map +1 -1
- package/dist/components/gesture.js +4 -4
- package/dist/components/interaction.js +1 -1
- package/dist/components/layout.js +1 -1
- package/dist/components/marketplace.cjs +104 -0
- package/dist/components/marketplace.cjs.map +1 -1
- package/dist/components/marketplace.d.cts +33 -2
- package/dist/components/marketplace.d.ts +33 -2
- package/dist/components/marketplace.js +105 -5
- package/dist/components/marketplace.js.map +1 -1
- package/dist/components/native.js +3 -3
- package/dist/components/packs.js +1 -1
- package/dist/components/page.js +3 -3
- package/dist/components/perf.js +2 -2
- package/dist/components/physics.js +3 -3
- package/dist/components/plugins.cjs +138 -0
- package/dist/components/plugins.cjs.map +1 -0
- package/dist/components/plugins.d.cts +120 -0
- package/dist/components/plugins.d.ts +120 -0
- package/dist/components/plugins.js +105 -0
- package/dist/components/plugins.js.map +1 -0
- package/dist/components/reveal.js +1 -1
- package/dist/components/solid.js +8 -8
- package/dist/components/svelte.js +8 -8
- package/dist/components/svg.js +1 -1
- package/dist/components/text.js +2 -2
- package/dist/components/timeline.js +3 -3
- package/dist/components/transitions.js +1 -1
- package/dist/components/ui.js +4 -4
- package/dist/components/vue.js +8 -8
- package/dist/components/webgl.js +1 -1
- package/dist/components/widgets.cjs +420 -199
- package/dist/components/widgets.cjs.map +1 -1
- package/dist/components/widgets.d.cts +42 -2
- package/dist/components/widgets.d.ts +42 -2
- package/dist/components/widgets.js +428 -209
- package/dist/components/widgets.js.map +1 -1
- package/dist/components.js +10 -10
- package/dist/index.js +2 -2
- package/dist/llms-full.txt +3018 -0
- package/dist/llms.txt +207 -0
- package/dist/manifest.json +7562 -0
- package/dist/manifest.schema.json +85 -0
- package/dist/runtime/format-css.cjs +184 -0
- package/dist/runtime/format-css.cjs.map +1 -0
- package/dist/runtime/format-css.d.cts +174 -0
- package/dist/runtime/format-css.d.ts +174 -0
- package/dist/runtime/format-css.iife.js +2 -0
- package/dist/runtime/format-css.iife.js.map +1 -0
- package/dist/runtime/format-css.js +176 -0
- package/dist/runtime/format-css.js.map +1 -0
- package/dist/runtime/format-motion.cjs +138 -0
- package/dist/runtime/format-motion.cjs.map +1 -0
- package/dist/runtime/format-motion.d.cts +208 -0
- package/dist/runtime/format-motion.d.ts +208 -0
- package/dist/runtime/format-motion.iife.js +2 -0
- package/dist/runtime/format-motion.iife.js.map +1 -0
- package/dist/runtime/format-motion.js +132 -0
- package/dist/runtime/format-motion.js.map +1 -0
- package/dist/runtime.cjs +78 -0
- package/dist/runtime.cjs.map +1 -0
- package/dist/runtime.d.cts +236 -0
- package/dist/runtime.d.ts +236 -0
- package/dist/runtime.iife.js +2 -0
- package/dist/runtime.iife.js.map +1 -0
- package/dist/runtime.js +54 -0
- package/dist/runtime.js.map +1 -0
- package/dist/widgets.umd.js +1 -1
- package/dist/widgets.umd.js.map +1 -1
- package/docs/ROADMAP.md +85 -14
- package/docs/components.md +66 -0
- package/docs/core.md +47 -0
- package/docs/deprecations.md +1 -1
- package/docs/runtime/core.md +55 -0
- package/docs/runtime/format-css.md +59 -0
- package/docs/runtime/format-motion.md +56 -0
- package/docs/upgrading-10.md +1 -1
- package/package.json +88 -6
package/dist/runtime.js
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { R as RUNTIME_VERSION, r as register } from './chunks/registry-jF8VIA_9.js';
|
|
2
|
+
export { a as RUNTIME_CDN, b as RuntimeModuleError, h as hasModule, m as missingMessage, c as moduleCdn, d as modulePath, e as registeredModules, f as registry, g as requireModule } from './chunks/registry-jF8VIA_9.js';
|
|
3
|
+
import { s as steps, c as cubicBezier, p as parseEase, E as EASES, T as Timeline, a as Tween, t as timeline, g as getTicker, b as tween$1 } from './chunks/tween-DDObu9iA.js';
|
|
4
|
+
export { P as Playable, d as parseValue } from './chunks/tween-DDObu9iA.js';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* `motionary/runtime` (10.1) — Motionary's own zero-dependency animation
|
|
8
|
+
* runtime, the one prerequisite for runtime-powered components:
|
|
9
|
+
*
|
|
10
|
+
* - shared **ticker** (`getTicker()`): one rAF loop for everything;
|
|
11
|
+
* - **tween + timeline** engine with easing (`tween()`, `timeline()`, `EASES`, `cubicBezier()`);
|
|
12
|
+
* - **module registry** (`use()`, `requireModule()`, `hasModule()`) with a
|
|
13
|
+
* clear `RuntimeModuleError` (install / import / CDN instructions) when a
|
|
14
|
+
* component needs a module that was not registered.
|
|
15
|
+
*
|
|
16
|
+
* Every other module lives at its own subpath (`motionary/runtime/format-css`,
|
|
17
|
+
* `motionary/runtime/format-motion`, …) so you only pay for what you import.
|
|
18
|
+
* SSR-safe (no `window` access at import) and usable in Web Workers.
|
|
19
|
+
*
|
|
20
|
+
* ```ts
|
|
21
|
+
* import { use, tween } from 'motionary/runtime';
|
|
22
|
+
* use(); // registers the core (components can now find it)
|
|
23
|
+
* tween('.box', { to: { x: 120, opacity: 1 }, duration: 500, ease: 'back-out' });
|
|
24
|
+
* ```
|
|
25
|
+
*/
|
|
26
|
+
/** The core as a module object. */
|
|
27
|
+
const core = {
|
|
28
|
+
id: 'core',
|
|
29
|
+
version: RUNTIME_VERSION,
|
|
30
|
+
api: { version: RUNTIME_VERSION, getTicker, tween, timeline, Tween, Timeline, EASES, parseEase, cubicBezier, steps },
|
|
31
|
+
};
|
|
32
|
+
/** Tween targets (objects, elements, lists or a CSS selector). See `TweenOptions`. */
|
|
33
|
+
function tween(target, o) {
|
|
34
|
+
return tween$1(resolveTargets(target), o);
|
|
35
|
+
}
|
|
36
|
+
/** Selector strings become element lists (only where `document` exists). */
|
|
37
|
+
function resolveTargets(t) {
|
|
38
|
+
if (typeof t === 'string') {
|
|
39
|
+
if (typeof document === 'undefined')
|
|
40
|
+
throw new Error('[motionary] selector targets need a document — pass objects or elements instead');
|
|
41
|
+
return Array.from(document.querySelectorAll(t));
|
|
42
|
+
}
|
|
43
|
+
return t;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Register the core plus any modules (`use(formatCss, formatMotion)`).
|
|
47
|
+
* Call once at start-up, before runtime-powered components mount.
|
|
48
|
+
*/
|
|
49
|
+
function use(...mods) {
|
|
50
|
+
return register(core, ...mods);
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export { EASES, RUNTIME_VERSION, Timeline, Tween, core, cubicBezier, getTicker, parseEase, register, resolveTargets, steps, timeline, tween, use };
|
|
54
|
+
//# sourceMappingURL=runtime.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"runtime.js","sources":["../src/runtime/index.ts"],"sourcesContent":["/**\n * `motionary/runtime` (10.1) — Motionary's own zero-dependency animation\n * runtime, the one prerequisite for runtime-powered components:\n *\n * - shared **ticker** (`getTicker()`): one rAF loop for everything;\n * - **tween + timeline** engine with easing (`tween()`, `timeline()`, `EASES`, `cubicBezier()`);\n * - **module registry** (`use()`, `requireModule()`, `hasModule()`) with a\n * clear `RuntimeModuleError` (install / import / CDN instructions) when a\n * component needs a module that was not registered.\n *\n * Every other module lives at its own subpath (`motionary/runtime/format-css`,\n * `motionary/runtime/format-motion`, …) so you only pay for what you import.\n * SSR-safe (no `window` access at import) and usable in Web Workers.\n *\n * ```ts\n * import { use, tween } from 'motionary/runtime';\n * use(); // registers the core (components can now find it)\n * tween('.box', { to: { x: 120, opacity: 1 }, duration: 500, ease: 'back-out' });\n * ```\n */\nimport { register, RUNTIME_VERSION, type RuntimeModule, type RuntimeRegistry } from './registry';\nimport { getTicker } from './ticker';\nimport { tween as rawTween, timeline, Tween, Timeline, type TweenOptions, type Playable } from './tween';\nimport { EASES, parseEase, cubicBezier, steps } from './ease';\n\nexport { registry, register, requireModule, hasModule, registeredModules, missingMessage, modulePath, moduleCdn, RuntimeModuleError, RUNTIME_VERSION, RUNTIME_CDN } from './registry';\nexport type { RuntimeModule, RuntimeRegistry } from './registry';\nexport { getTicker } from './ticker';\nexport type { Ticker, TickFn } from './ticker';\nexport { timeline, Tween, Timeline, Playable, parseValue } from './tween';\nexport type { TweenOptions, TimelineOptions, PlayOptions, Props, Target, Position } from './tween';\nexport { EASES, parseEase, cubicBezier, steps } from './ease';\nexport type { Ease } from './ease';\n\n/** The core module's API (what `requireModule('core')` returns). */\nexport interface CoreApi {\n version: string;\n getTicker: typeof getTicker;\n tween: (target: any, o: import('./tween').TweenOptions) => import('./tween').Playable;\n timeline: typeof timeline;\n Tween: typeof Tween;\n Timeline: typeof Timeline;\n EASES: typeof EASES;\n parseEase: typeof parseEase;\n cubicBezier: typeof cubicBezier;\n steps: typeof steps;\n}\n\n/** The core as a module object. */\nexport const core: RuntimeModule<CoreApi> = {\n id: 'core',\n version: RUNTIME_VERSION,\n api: { version: RUNTIME_VERSION, getTicker, tween, timeline, Tween, Timeline, EASES, parseEase, cubicBezier, steps },\n};\n\n/** Tween targets (objects, elements, lists or a CSS selector). See `TweenOptions`. */\nexport function tween(target: any, o: TweenOptions): Playable {\n return rawTween(resolveTargets(target), o);\n}\n\n/** Selector strings become element lists (only where `document` exists). */\nexport function resolveTargets(t: any): any {\n if (typeof t === 'string') {\n if (typeof document === 'undefined') throw new Error('[motionary] selector targets need a document — pass objects or elements instead');\n return Array.from(document.querySelectorAll(t));\n }\n return t;\n}\n\n/**\n * Register the core plus any modules (`use(formatCss, formatMotion)`).\n * Call once at start-up, before runtime-powered components mount.\n */\nexport function use(...mods: RuntimeModule[]): RuntimeRegistry {\n return register(core as RuntimeModule, ...mods);\n}\n"],"names":["rawTween"],"mappings":";;;;;AAAA;;;;;;;;;;;;;;;;;;;AAmBG;AA6BH;AACO,MAAM,IAAI,GAA2B;AAC1C,IAAA,EAAE,EAAE,MAAM;AACV,IAAA,OAAO,EAAE,eAAe;IACxB,GAAG,EAAE,EAAE,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,KAAK,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,KAAK,EAAE;;AAGtH;AACM,SAAU,KAAK,CAAC,MAAW,EAAE,CAAe,EAAA;IAChD,OAAOA,OAAQ,CAAC,cAAc,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC;AAC5C;AAEA;AACM,SAAU,cAAc,CAAC,CAAM,EAAA;AACnC,IAAA,IAAI,OAAO,CAAC,KAAK,QAAQ,EAAE;QACzB,IAAI,OAAO,QAAQ,KAAK,WAAW;AAAE,YAAA,MAAM,IAAI,KAAK,CAAC,iFAAiF,CAAC;QACvI,OAAO,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,gBAAgB,CAAC,CAAC,CAAC,CAAC;IACjD;AACA,IAAA,OAAO,CAAC;AACV;AAEA;;;AAGG;AACG,SAAU,GAAG,CAAC,GAAG,IAAqB,EAAA;AAC1C,IAAA,OAAO,QAAQ,CAAC,IAAqB,EAAE,GAAG,IAAI,CAAC;AACjD;;;;"}
|