kuinetic 0.2.4 → 0.3.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 (74) hide show
  1. package/README.md +2 -2
  2. package/dist/esm/advanced/index.mjs +1 -1
  3. package/dist/esm/{chunk-EHS45PIK.mjs → chunk-4QKMEDM4.mjs} +4978 -832
  4. package/dist/esm/{chunk-FASAEQDR.mjs → chunk-7NW4OLOC.mjs} +506 -29
  5. package/dist/esm/{chunk-MZQG2VMG.mjs → chunk-DAVDOYOS.mjs} +92 -495
  6. package/dist/esm/{chunk-AEQGC2KM.mjs → chunk-EDFJTT5B.mjs} +2 -1
  7. package/dist/esm/core/index.mjs +3 -3
  8. package/dist/esm/effects/index.mjs +3 -3
  9. package/dist/esm/index.mjs +4 -4
  10. package/dist/esm/notes/index.mjs +276 -5
  11. package/dist/kuinetic.advanced.js +2 -1
  12. package/dist/kuinetic.advanced.min.js +1 -1
  13. package/dist/kuinetic.all.js +5047 -856
  14. package/dist/kuinetic.all.min.js +2 -2
  15. package/dist/kuinetic.css +1106 -61
  16. package/dist/kuinetic.js +5046 -855
  17. package/dist/kuinetic.min.css +1 -1
  18. package/dist/kuinetic.min.js +1 -1
  19. package/dist/kuinetic.notes.js +1 -1
  20. package/dist/types/advanced/shaders.d.ts +1 -1
  21. package/dist/types/core/channels.d.ts +1 -1
  22. package/dist/types/core/easing.d.ts +9 -0
  23. package/dist/types/core/effect-context.d.ts +5 -0
  24. package/dist/types/core/element-config.d.ts +2 -0
  25. package/dist/types/core/flip.d.ts +25 -1
  26. package/dist/types/core/gesture.d.ts +5 -0
  27. package/dist/types/core/image-flight.d.ts +23 -0
  28. package/dist/types/core/js-effect-preparer.d.ts +3 -1
  29. package/dist/types/core/owned-styles.d.ts +2 -1
  30. package/dist/types/core/params.d.ts +1 -1
  31. package/dist/types/core/parse.d.ts +1 -0
  32. package/dist/types/core/registry.d.ts +1 -1
  33. package/dist/types/core/types.d.ts +11 -1
  34. package/dist/types/effects/auto-motion.d.ts +8 -0
  35. package/dist/types/effects/carousel/archive.d.ts +18 -0
  36. package/dist/types/effects/carousel/coast.d.ts +7 -0
  37. package/dist/types/effects/carousel/deck.d.ts +26 -2
  38. package/dist/types/effects/carousel/drag.d.ts +19 -7
  39. package/dist/types/effects/carousel/glide.d.ts +89 -0
  40. package/dist/types/effects/carousel/line.d.ts +10 -0
  41. package/dist/types/effects/carousel/row-copies.d.ts +10 -0
  42. package/dist/types/effects/carousel/row.d.ts +3 -0
  43. package/dist/types/effects/carousel/shape-fit.d.ts +46 -0
  44. package/dist/types/effects/carousel/sources.d.ts +26 -0
  45. package/dist/types/effects/carousel/sphere.d.ts +23 -0
  46. package/dist/types/effects/carousel/stack.d.ts +2 -1
  47. package/dist/types/effects/catalog/confetti.d.ts +2 -0
  48. package/dist/types/effects/catalog/cursor-trail.d.ts +2 -0
  49. package/dist/types/effects/catalog/curtains.d.ts +2 -0
  50. package/dist/types/effects/catalog/image-flight.d.ts +2 -0
  51. package/dist/types/effects/catalog/line-boil.d.ts +2 -0
  52. package/dist/types/effects/catalog/number-tokens.d.ts +5 -0
  53. package/dist/types/effects/catalog/numbers-shared.d.ts +3 -4
  54. package/dist/types/effects/catalog/text-shared.d.ts +13 -6
  55. package/dist/types/effects/catalog/typewriter-scatter.d.ts +5 -0
  56. package/dist/types/effects/catalog/view-transitions.d.ts +32 -1
  57. package/dist/types/effects/catalog/wobble.d.ts +2 -0
  58. package/dist/types/effects/gestures/drag-options.d.ts +17 -0
  59. package/dist/types/effects/layout/departures.d.ts +21 -0
  60. package/dist/types/effects/motion-path/fit.d.ts +4 -0
  61. package/dist/types/effects/scroll-mechanics/progress-output.d.ts +9 -0
  62. package/dist/types/effects/step-marking.d.ts +7 -4
  63. package/dist/types/effects/svg/morph-loop.d.ts +5 -0
  64. package/dist/types/effects/svg/text-path.d.ts +2 -0
  65. package/dist/types/effects/three-d/cube.d.ts +2 -0
  66. package/dist/types/effects/tween/index.d.ts +2 -1
  67. package/dist/types/effects/tween/properties.d.ts +1 -1
  68. package/dist/types/effects/tween/toggle.d.ts +6 -0
  69. package/dist/types/notes/effects.d.ts +1 -0
  70. package/dist/types/notes/index.d.ts +11 -0
  71. package/dist/types/notes/showcase.d.ts +1 -0
  72. package/dist/types/showcase/lightbox-flight.d.ts +11 -0
  73. package/dist/types/showcase/modal-shell.d.ts +5 -0
  74. package/package.json +1 -1
@@ -0,0 +1,5 @@
1
+ import type { PrepareContext } from '../../core/effect-context.js';
2
+ import type { SetupResult } from '../../core/instances.js';
3
+ import type { EffectParams } from '../../core/types.js';
4
+ /** An opt-in loop; the interactive morph's listeners, timing and geometry remain separate. */
5
+ export declare function prepareMorphLoop(path: Element, params: EffectParams, ctx: PrepareContext): SetupResult;
@@ -0,0 +1,2 @@
1
+ import type { Primitive } from '../../core/types.js';
2
+ export declare const TEXT_PATH_PRIMITIVE: Primitive;
@@ -0,0 +1,2 @@
1
+ import type { Primitive } from '../../core/types.js';
2
+ export declare const cubeVariant: NonNullable<Primitive['variantFor']>;
@@ -18,7 +18,8 @@ export declare const TWEEN_PRIMITIVES: Primitive[];
18
18
  * 0) ...`, not a missing endpoint — so, per D1's correction #5, `animation-fill-mode: both` pins that
19
19
  * exact authored value on the channel forever once the animation finishes; it never resolves against
20
20
  * whatever the cascade underneath would otherwise say. That is precisely the shape `EffectPhase`'s
21
- * own doc calls out as the trap: fifteen of the catalog's fifty-four `cloak: true` entrances close
21
+ * own doc calls out as the trap: fifteen of the catalog's `cloak: true` entrances (ninety-six presets carry the flag in all,
22
+ * counted from the registry) close
22
23
  * their block the same way and are *deliberately* left unphased rather than marked `entrance`,
23
24
  * because `entrance` specifically means "plays once and releases the channel". `tween` is that same
24
25
  * closed shape by construction — every property group's `to` block closes, with no exception — so it
@@ -20,7 +20,7 @@ import type { Channel, ParamSpec, ParameterSchema } from '../../core/types.js';
20
20
  * fallbacks mean for an axis the author did not name.
21
21
  */
22
22
  /** One rendering unit: a single CSS property (or filter list) written by one keyframe block. */
23
- export type TweenGroup = 'translate' | 'rotate' | 'scale' | 'opacity' | 'filter' | 'color' | 'background';
23
+ export type TweenGroup = 'translate' | 'rotate' | 'scale' | 'opacity' | 'filter' | 'color' | 'background' | 'border-radius';
24
24
  /**
25
25
  * Declared in rendering order rather than derived from `TWEEN_PROPERTIES`'s key order, so
26
26
  * `tween opacity:0 x:100` and `tween x:100 opacity:0` compile to the same track order. Two
@@ -0,0 +1,6 @@
1
+ import type { PrepareContext } from '../../core/effect-context.js';
2
+ import type { Cleanup } from '../../core/types.js';
3
+ import type { TweenGroup } from './properties.js';
4
+ export declare function toggleProperty(group: TweenGroup): string;
5
+ /** Clicks write opted-in destinations or release to the current stylesheet; no style reads. */
6
+ export declare function prepareToggle(el: Element, groups: readonly TweenGroup[], ctx: PrepareContext): Cleanup;
@@ -0,0 +1 @@
1
+ export declare const EFFECT_NOTES: Readonly<Record<string, readonly string[]>>;
@@ -1,4 +1,5 @@
1
1
  import type { ParamNotes } from '../core/describe.js';
2
+ import { EFFECT_NOTES } from './effects.js';
2
3
  /**
3
4
  * The plain-words note for every parameter in the bundled catalog, read by `describe()`.
4
5
  *
@@ -11,3 +12,13 @@ import type { ParamNotes } from '../core/describe.js';
11
12
  * resolve a note, and every key here must name a parameter that exists.
12
13
  */
13
14
  export declare const PARAM_NOTES: ParamNotes;
15
+ /**
16
+ * Plain-words notes about whole effects, keyed by preset name, shown on the Notes tab of the
17
+ * "Show code" popover. Prose only documentation pages read, so it lives in this entry beside
18
+ * `PARAM_NOTES` rather than on each preset, for the same reason: inline, it would ship to every
19
+ * visitor of every site using the library.
20
+ *
21
+ * Kept in step with the registry by `test/param-notes.test.ts`: every key must name a registered
22
+ * preset. Not every preset needs an entry; the tab only appears for those that have one.
23
+ */
24
+ export { EFFECT_NOTES };
@@ -5,3 +5,4 @@ import type { ParamNotes } from '../core/describe.js';
5
5
  * step-progress).
6
6
  */
7
7
  export declare const SHOWCASE_NOTES: ParamNotes;
8
+ export declare const ROW_NOTES: ParamNotes;
@@ -0,0 +1,11 @@
1
+ import type { ModalMotion } from './modal-shell.js';
2
+ interface LightboxFlightOptions {
3
+ source: () => HTMLImageElement | null;
4
+ view: HTMLImageElement;
5
+ duration: number;
6
+ easing: string;
7
+ warn(message: string): void;
8
+ }
9
+ /** The shell owns this handle across decode, open, reverse, re-entry and release. */
10
+ export declare function lightboxFlight(dialog: HTMLElement, options: LightboxFlightOptions): ModalMotion;
11
+ export {};
@@ -1,3 +1,7 @@
1
+ export interface ModalMotion {
2
+ dismiss(): Promise<unknown> | undefined;
3
+ cancel(): void;
4
+ }
1
5
  export interface ModalContent {
2
6
  node: HTMLElement;
3
7
  label: string;
@@ -18,6 +22,7 @@ export interface ModalContent {
18
22
  * pauses its own motion for exactly as long as the viewer shows one of its cards.
19
23
  */
20
24
  opener?: Element;
25
+ motion?: (layer: HTMLElement) => ModalMotion;
21
26
  }
22
27
  export interface ModalShell {
23
28
  open(content: ModalContent): void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kuinetic",
3
- "version": "0.2.4",
3
+ "version": "0.3.0",
4
4
  "description": "Declarative web animation from HTML attributes. Native CSS where possible, JS only where necessary.",
5
5
  "type": "module",
6
6
  "license": "MIT",