@zakkster/lite-ui-fx 1.6.0 → 1.8.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 +79 -0
- package/README.md +288 -212
- package/UIFX-RECIPE-GUIDE.md +32 -0
- package/UIFXController.d.ts +42 -2
- package/UIFXController.js +165 -26
- package/UIFXRecipes.js +51 -24
- package/llms.txt +36 -7
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,85 @@ All notable changes to `@zakkster/lite-ui-fx` are documented here.
|
|
|
5
5
|
The format follows Keep a Changelog; this project adheres to Semantic
|
|
6
6
|
Versioning.
|
|
7
7
|
|
|
8
|
+
## [1.8.0] -- 2026-09-07
|
|
9
|
+
|
|
10
|
+
Documentation and demo (roadmap U6). No API, recipe, or behaviour change: the
|
|
11
|
+
module code (`UIFXController.js`, `UIFXRecipes.js`) is byte-identical to 1.7.0.
|
|
12
|
+
Closes finding U-12 (demos that reimplemented the library inline).
|
|
13
|
+
|
|
14
|
+
### Added
|
|
15
|
+
|
|
16
|
+
- `README.md` rewritten on the LiteSepforge blueprint spine: positioning H2 with
|
|
17
|
+
a runnable quick-start, table of contents, why/what-you-get, a mount-modes
|
|
18
|
+
deep-dive, an API reference with UIType/state/`RECIPE_META` constant tables, a
|
|
19
|
+
composability example, a zero-GC allocation table carrying the gated torture
|
|
20
|
+
GATE line, design-decision links, testing, what-this-is-not, ecosystem. Size
|
|
21
|
+
claims are measured (controller ~5.2 KB min+gzip, catalog of 56 recipes ~24 KB).
|
|
22
|
+
- `demo/index.html`: one demo that consumes the package. It imports only the
|
|
23
|
+
public `.` and `./recipes` entry points and generates the gallery from
|
|
24
|
+
`RECIPE_META`, mounting each recipe by its declared type. Includes a theme
|
|
25
|
+
switcher, a reduced-motion toggle, and a `#profile` forced-reflow hook
|
|
26
|
+
(dev-only, dormant unless the URL carries `#profile`; a full drive of the hot
|
|
27
|
+
paths reports `violationCount 0`).
|
|
28
|
+
- `test/docs.test.mjs`: an executable doc gate. It extracts every fenced js block
|
|
29
|
+
in `README.md`, rewrites the package specifiers to the local files, and imports
|
|
30
|
+
each under the DOM stub, so a drifted example fails CI; a control block with a
|
|
31
|
+
bad import name proves the gate can fail. The suite is now 205 node:test cases
|
|
32
|
+
across 18 suites.
|
|
33
|
+
- `decisions/0006-docs-and-demo.md`.
|
|
34
|
+
|
|
35
|
+
### Removed
|
|
36
|
+
|
|
37
|
+
- The three inline demo pages (`demo/demo-lite-ui-fx.html`,
|
|
38
|
+
`demo/demo-lite-uifx-vol2.html`, `demo/demo-lite-uifx-vol3.html`) that
|
|
39
|
+
reimplemented the controller and recipes inline (U-12), replaced by the single
|
|
40
|
+
consuming `demo/index.html`.
|
|
41
|
+
- The README's three CodePen "Live Demo" links and the competitor-size comparison
|
|
42
|
+
table (unmeasured claims; the shipped demo is the showcase).
|
|
43
|
+
|
|
44
|
+
## [1.7.0] -- 2026-09-07
|
|
45
|
+
|
|
46
|
+
Host integration (roadmap U5). Two host-clock modes plus reduced-motion and a
|
|
47
|
+
frame-budget signal, applied to BOTH mount modes (`mountUIFX` and `decorateUIFX`).
|
|
48
|
+
Additive: a default mount is byte-identical to 1.6.0.
|
|
49
|
+
|
|
50
|
+
### Added
|
|
51
|
+
|
|
52
|
+
- `{ ticker }` mount option (both modes): a caller-supplied ticker
|
|
53
|
+
(`{ add(fn) -> removeFn }`, e.g. `@zakkster/lite-ticker`) drives the component
|
|
54
|
+
instead of the shared ref-counted ticker. `destroy()` unregisters the
|
|
55
|
+
component's frame but never destroys the caller's ticker (ownership stays with
|
|
56
|
+
the caller).
|
|
57
|
+
- `{ driven: true }` mount option (both modes): no ticker and no RAF; the host
|
|
58
|
+
drives each frame via `instance.tick(dtMs)`. `instance.tick` is the internal
|
|
59
|
+
frame body in driven mode and throws otherwise. `{ ticker }` and `{ driven }`
|
|
60
|
+
are mutually exclusive; a non-boolean `driven` or a ticker without `.add()`
|
|
61
|
+
throws at mount.
|
|
62
|
+
- `state.reducedMotion` (both modes): read from
|
|
63
|
+
`matchMedia('(prefers-reduced-motion: reduce)')` before `recipe.init` and
|
|
64
|
+
watched via the AbortController; absent `matchMedia` is a no-op (stays `false`).
|
|
65
|
+
Calm paths for six recipes -- `SwarmToggle`, `PasswordStrength`,
|
|
66
|
+
`TypewriterField`, `FocusHalo`, `ErrorShake`, `SuccessBloom`: under reduced
|
|
67
|
+
motion `ErrorShake` stops displacing, `SuccessBloom` spawns no particles, and
|
|
68
|
+
`SwarmToggle` rests its particles at formation.
|
|
69
|
+
- `state.budget` (0..1, both modes): a per-frame frame-budget number (1 at
|
|
70
|
+
~60fps, lower as frames lengthen), computed in place with no allocation, for
|
|
71
|
+
budget-aware recipes to shed work.
|
|
72
|
+
- `mountRecipe` emits a `console.warn` (not a throw) when mounting a
|
|
73
|
+
`motionSafe:false` recipe while the user prefers reduced motion.
|
|
74
|
+
- TypeScript: `HostTicker`, `HostClockOptions`, `state.reducedMotion` /
|
|
75
|
+
`state.budget`, and `instance.tick(dtMs)` on both instance types.
|
|
76
|
+
- `decisions/0005-host-clock.md`. U5 coverage: t5 caller-ticker ownership +
|
|
77
|
+
driven determinism, t3 reduced-motion churn, and two t9 controls (`fake-calm`,
|
|
78
|
+
`ticker-ownership`). 177 -> 196 node:test tests; 5 -> 7 torture controls.
|
|
79
|
+
|
|
80
|
+
### Changed
|
|
81
|
+
|
|
82
|
+
- The per-mount frame loop is one named function shared by all three clock modes;
|
|
83
|
+
the default (shared-ticker) path is byte-identical to 1.6.0.
|
|
84
|
+
- `RECIPE_META.motionSafe` is now `true` for six recipes (previously `false` for
|
|
85
|
+
all 56): it marks exactly the recipes that ship a reduced-motion calm path.
|
|
86
|
+
|
|
8
87
|
## [1.6.0] -- 2026-09-07
|
|
9
88
|
|
|
10
89
|
Decorate mode (U4b, the second half of roadmap U4). A second public mount mode
|