@getvitops/create 0.3.1 → 0.3.3

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 CHANGED
@@ -1,5 +1,94 @@
1
1
  # @getvitops/create
2
2
 
3
+ ## 0.3.3
4
+
5
+ ### Patch Changes
6
+
7
+ - **Fixed: `vitops init` and `vp create` scaffolded configs referencing tokens that no longer
8
+ exist.** `defaultConfig()` and the EmDash template still pointed at `--color-surface-xl` and
9
+ `--color-surface-xxl`, aliases from the named-step colour scale removed in 0.6. A scaffolded
10
+ project therefore got a `card` with no background and an invalid default border colour, with
11
+ nothing reporting it. Both now use `--surface-bg` / `--surface-bg-muted`. The EmDash template
12
+ also dropped its `patterns.radii.card` key, which collided with the `card` pattern on
13
+ `--br-card` — the collision `validate()` has been warning about (the `panel` group already
14
+ supplies the same radius, so nothing changes visually).
15
+
16
+ **Fixed: `.text-reveal` rendered invisible text.** Its gradient consumed
17
+ `--text-reveal-color-from`/`-to` with no defaults, so unless a consumer set both, the `var()`
18
+ substitution failed, `background` became invalid at computed-value time, and the accompanying
19
+ `color: transparent` left the text with no way to render. Both tones now default to the
20
+ functional text tokens.
21
+
22
+ **Fixed: `.bordered` fell back to `currentColor`** via a reference to `--color-surface-xl`,
23
+ which the generator never emitted. It now resolves `--surface-border`.
24
+
25
+ **New: `validate()` warns when a required role is missing.** `colors.roles` is an open map —
26
+ any name works and generates a full token set — but the shipped component CSS references
27
+ `brand-primary`, `danger`, `neutral`, `surface`, `ui-primary` and `warning` with no fallback,
28
+ so omitting one leaves those components uncoloured. This is a warning, not an error; the
29
+ required list is re-derived from the CSS partials by a test so it cannot drift.
30
+
31
+ `vitops docs` and `vitops agents` now surface config warnings (on stderr, so piping `docs` is
32
+ unaffected). They previously discarded them, unlike `generate` and `validate`.
33
+
34
+ Docs corrections, all in the generated bundle:
35
+ - **Raw scale classes are frozen and do not remap in dark mode** — stated explicitly for the
36
+ first time, with a migration table to the role equivalents. The dark-mode guarantee only ever
37
+ applied to functional role tokens, and nothing said so.
38
+ - **Roles are extensible over a required core** — the schema description and class reference
39
+ read as a closed enumeration, which is why a consumer forked their own colour layer rather
40
+ than adding a role.
41
+ - **The `md:` / `@md:` / `md-` distinction** in the tailwind format: `@md:` uses the framework's
42
+ breakpoints, `md:` works but uses Tailwind's (which differ — `sm:` is 40rem, `@sm:` is 30rem),
43
+ and `md-` is silently inert. Plus a note that registering `--container-*` also re-points
44
+ Tailwind's `max-w-*` scale.
45
+ - The css and bricks bundles now carry a `/*!` banner pointing at `npx vitops docs classes`
46
+ (the previous plain comment was stripped by the minifier, so it never reached the file).
47
+
48
+ Contrast checking now covers **every** background plane a role emits (`bg`, `bg-muted`, and
49
+ `bg-bold`), not just `bg` — body text on a `card` was previously unguaranteed.
50
+
51
+ ## 0.3.2
52
+
53
+ ### Patch Changes
54
+
55
+ - a334049: Make the semantic icon mapping reachable, and fail the build on unresolvable names.
56
+
57
+ `generateIconInclude()` — declare the semantic icon names a site needs plus which sets to draw
58
+ them from, get back the `include` map that keeps the bundle to just those glyphs — already existed
59
+ but was unreachable: it lived in `@getvitops/core/src/utils/`, which the package doesn't export.
60
+ It has moved to `@getvitops/utils` (a build-time concern, in the build-time utilities package),
61
+ which `@getvitops/astro` re-exports wholesale. So from `astro.config.mjs`:
62
+
63
+ ```js
64
+ import { generateIconInclude } from '@getvitops/astro';
65
+ import icon from 'astro-icon';
66
+
67
+ integrations: [
68
+ icon({
69
+ include: generateIconInclude({
70
+ ui: 'fa7-solid',
71
+ brand: 'simple-icons',
72
+ semantic: ['menu', 'close', 'search', 'github'],
73
+ }),
74
+ }),
75
+ ];
76
+ // → { "fa7-solid": ["bars","xmark","magnifying-glass"], "simple-icons": ["github"] }
77
+ ```
78
+
79
+ Swapping `ui` to `'lucide'` yields `{ lucide: ["menu","x","search"] }` from the same declaration —
80
+ which is the point: the semantic names are what your markup commits to, and the set is a config
81
+ choice. The output shape is the `include` both `astro-icon` and `astro-iconset` accept, so the
82
+ mapping doesn't tie you to either.
83
+
84
+ **Unresolvable names are now a build error.** Previously they were skipped silently, so swapping
85
+ sets appeared to succeed and the gaps surfaced as missing glyphs in production. The error names
86
+ every offender; an unknown set name throws too, listing the known sets.
87
+
88
+ Also fixes `@getvitops/create`'s emdash template, which pinned `@getvitops/astro: ^0.4.0` — a range
89
+ that stopped resolving when astro joined the fixed group at 0.7.0, so scaffolded projects were
90
+ stuck on the old line.
91
+
3
92
  ## 0.3.1
4
93
 
5
94
  ### Patch Changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@getvitops/create",
3
- "version": "0.3.1",
3
+ "version": "0.3.3",
4
4
  "description": "Project templates for the Vitops design system — scaffold wired-up sites with `vp create @getvitops`.",
5
5
  "license": "MIT",
6
6
  "files": [
@@ -49,12 +49,12 @@
49
49
  "patterns": {
50
50
  "defaults": {
51
51
  "ds": "none",
52
- "b": "1px solid var(--color-surface-xl)",
52
+ "b": "1px solid var(--surface-bg-muted)",
53
53
  "br": "0.375rem",
54
54
  "p": "1rem",
55
55
  "fs": "1rem"
56
56
  },
57
- "radii": { "pill": "999px", "circle": "50%", "card": "0.5rem" },
57
+ "radii": { "pill": "999px", "circle": "50%" },
58
58
  "groups": {
59
59
  "control": {
60
60
  "ds": "var(--ds-default)",
@@ -99,7 +99,7 @@
99
99
  "base": {
100
100
  "border-radius": "var(--br-card-group)",
101
101
  "padding": "1.5rem",
102
- "background": "var(--color-surface-xxl)",
102
+ "background": "var(--surface-bg)",
103
103
  "border": "var(--b-card-group)",
104
104
  "box-shadow": "var(--ds-card-group)"
105
105
  },
@@ -19,8 +19,8 @@
19
19
  "@astrojs/cloudflare": "^14.0.0",
20
20
  "@astrojs/react": "^6.0.0",
21
21
  "@emdash-cms/cloudflare": "^0.31.0",
22
- "@getvitops/astro": "^0.4.0",
23
- "@getvitops/emdash": "^0.2.0",
22
+ "@getvitops/astro": "^0.7.0",
23
+ "@getvitops/emdash": "^0.2.1",
24
24
  "astro": "^7.1.2",
25
25
  "emdash": "^0.31.0",
26
26
  "react": "^19.2.4",