@milesroxas/design-hub 0.9.0 → 0.10.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.
@@ -83,10 +83,43 @@ Is it a value CSS consumes (duration, distance, scale, colour)?
83
83
  ```
84
84
 
85
85
  - Every dial carries a hint: one sentence, the unit named. A reviewer never guesses what a slider does.
86
- - Panels register in the order a reviewer reaches for them: Review (fixtures, role, scenarios) first, then the feature's own numbers, then Motion. View is mounted by the shell.
86
+ - Panels register in the order a reviewer reaches for them: Review (fixtures, role, scenarios) first, then the feature's own numbers, then Motion. View is mounted by what the prototype stands on (see View tools).
87
87
  - Slider defaults are the comp's values. The decision is the number the user settles on; copy it into the README's Decision with the rejected range.
88
+ - Every dial is internal: a client's panel has the View tools and nothing else until a dial is marked client-facing. `client(...)` from `@kit/dials` marks one where it is declared (`density: client({ type: 'select', ... })`, or around a folder for every dial in it); use it only when the user asks for clients to have that dial. Studio can also mark any dial with the eye beside its row, per deployed site, and that overrules the code. Fixtures, roles and scenarios stay internal.
89
+ - A client reads an internal dial at its default, so the default is the value to present, not a test value.
90
+ - The picker is Studio's until marked: a client gets the first variant and no picker, unless Studio marks variants with the picker's eye. Put the direction to present first.
88
91
  - Never a control inside the product chrome. A sidebar item or a sheet that switches fixtures is a testing aid wearing the product's clothes.
89
92
 
93
+ ## View tools
94
+
95
+ ### View tools fit what the prototype is
96
+
97
+ The **View** panel holds only what changes something on the prototype in front of the reviewer. What a prototype stands on decides it; you never mount `ViewTools` yourself (the guard blocks it).
98
+
99
+ | It stands on | View holds | Why |
100
+ | --- | --- | --- |
101
+ | `AppShell`, `SiteShell` | Theme, Reduce motion, Speed | A product or a site has themes and things that move. |
102
+ | `Space` | Theme, Reduce motion, Speed, unless narrowed | One thing alone may have neither. |
103
+ | `Board` (brand collateral) | Nothing: no View panel | A still file has no motion to slow, and one look. Zoom and Guides are its viewing tools. |
104
+
105
+ Narrow a `Space` when a tool would do nothing there:
106
+
107
+ ```
108
+ Does anything in it move (a transition, an animation, a hover or press response)?
109
+ ├── No → drop motion: <Space tools={['theme']}>
110
+ └── Yes → keep it
111
+ Does it have a light and a dark look (the project's tokens do, unless DESIGN.md says one theme)?
112
+ ├── No → drop theme: <Space tools={['motion']}>
113
+ └── Yes → keep it
114
+ Neither → <Space tools={false}>
115
+ ```
116
+
117
+ - Decide from what is on the page now, and change `tools` when that changes: adding the first transition to a Space that had `['theme']` puts motion back.
118
+ - A kit component that animates counts as motion: a toast, a menu, a dialog, a press response on a `Button`.
119
+ - A project with one theme narrows it once, in its own `kit/AppShell.tsx` and `kit/SiteShell.tsx` (`<ViewTools tools={['motion']} />`), not in each prototype.
120
+ - A person's own reduced-motion setting is still honoured everywhere, whatever View holds. Removing the dial removes a test control, not the behaviour: `:root[data-motion="reduce"]` rules stay in every prototype that moves.
121
+ - Never add a reduce-motion or speed control of your own to a prototype that has none in View. If you think it needs one, it stands on the wrong thing.
122
+
90
123
  ## Motion, accessibility, performance
91
124
 
92
125
  The references beside this skill (`references/motion.md`, `references/accessibility.md`, `references/performance.md`) are binding; the short rules: transform and opacity only, ease-out in and ease-in out, nothing over 300ms, nothing animates on a keyboard action, reduced motion keeps the fades, every control has a name, 40px targets, no state per frame.