@snacky/ui 0.3.8 → 0.4.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 (2) hide show
  1. package/README.md +11 -33
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -57,6 +57,17 @@ Callout, List (OrderListItem/NotificationListItem), Accordion, BottomSheet
57
57
  (the shared Modal shell), Section (the shared content-block shell), Avatar,
58
58
  Illustration, ProductImage, ProductCard.
59
59
 
60
+ Plus the icon set, as `SnackyIcons.outline.*` and `SnackyIcons.solid.*` (42
61
+ Outline, 10 Solid). Two things to know: they are **filled** shapes rather than
62
+ stroked paths, so there is no `strokeWidth` to set, and the set is **not
63
+ uniform** - each icon is authored at 16, 20 or 24px and defaults to its own
64
+ natural size, so pass `width`/`height` if you need them to match.
65
+
66
+ The design system documents ~9 Modal and ~13 Section "variants", but each is
67
+ the same shell with different `children`, so you get two components rather
68
+ than 22 near-duplicates. Their spacing varies per variant in Figma, so the
69
+ shells ship sensible defaults and expect `children` to override it.
70
+
60
71
  ## Verification status
61
72
 
62
73
  Every component is diffed against `index.html`'s own Live Preview
@@ -85,19 +96,6 @@ what is already in the bundle.
85
96
 
86
97
  ## Known gaps - read before relying on these
87
98
 
88
- - **Icons** (`SnackyIcons.outline.*` / `SnackyIcons.solid.*`): no longer a
89
- gap. The hand-drawn starter set has been replaced by the real thing - all
90
- 42 Outline + 10 Solid icons exported from Figma's own `Icon-outline` (node
91
- `55:2062`) and `Icon-solid` (`8772:5851`) component sets. `src/icons/outline.tsx` and
92
- `solid.tsx` are generated from `../../assets/icons/icons.json` by
93
- `../../scripts/generate-icons.js` (never hand-edit them), the same source
94
- that generates compose-ui's `SnackyIcons.kt`.
95
-
96
- Two things changed versus the old hand-drawn placeholder: the icons are
97
- **filled outline shapes**, not stroked paths (the weight is baked into each
98
- shape, there is no `strokeWidth` to set), and the set is **not uniform** -
99
- icons are authored at 16, 20 or 24px depending on use, so each carries its
100
- own viewBox and defaults to that natural size.
101
99
  - **Illustration** ships no artwork - you supply the image. This is
102
100
  deliberate and normal (Material, Radix and Chakra ship none either); the
103
101
  component owns the documented canvas size for each variant, which is the
@@ -126,23 +124,3 @@ what is already in the bundle.
126
124
  - **`NavBar` items use `flex: 1`** to fill the container, where the site's demo
127
125
  hardcodes `72x72` per item - that demo only ever renders at a fixed 360px
128
126
  frame, so this is a deliberate deviation rather than a mismatch.
129
- - **Modal/Section**: the design system documents ~9 Modal "variants" and ~13
130
- Section "variants", but each is really the *same* shell component
131
- (`BottomSheet` / `Section`) with different `children` - so that's what's
132
- exported, matching every `code.tsx` sample exactly, rather than 22 near-
133
- duplicate components. Their spacing is variant-dependent by design - Figma
134
- uses different gaps per variant, so the shells ship sensible defaults and
135
- expect `children` to override where a composition needs it.
136
-
137
- ## Keeping this in sync
138
-
139
- If `index.html`'s component data (the `C` object) changes:
140
-
141
- ```bash
142
- node ../../scripts/generate-agent-files.js # regenerates tokens.json / components.json
143
- node ../../scripts/generate-react-tokens.js # regenerates src/theme/tokens.css / tokens.ts
144
- ```
145
-
146
- Then re-check any component whose spec changed against its file here -
147
- token/color/spacing changes propagate automatically via the regenerated CSS
148
- variables, but structural changes (new variant, new prop) need a manual edit.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@snacky/ui",
3
- "version": "0.3.8",
3
+ "version": "0.4.0",
4
4
  "description": "Snacky App design system - React component library. Generated from the source-of-truth design system at ../../index.html (tokens.json / components.json), pixel-accurate to Figma.",
5
5
  "license": "MIT",
6
6
  "author": "rezatresnas",