@keenmate/web-components-devkit 1.0.0-rc03 → 1.0.0-rc04

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,26 @@
1
1
  # Changelog
2
2
 
3
+ ## [1.0.0-rc04] - 2026-11-01 [PUBLISHED]
4
+
5
+ ### Fixed
6
+
7
+ - **A wide `<pre>` or table in a `.grid` / `.grid-2` / `.card-grid` item no longer widens the
8
+ page on a phone** — grid items kept `min-width: auto` (their min-content), so the single
9
+ `1fr` column grew past the screen instead of letting the content scroll. Items now get
10
+ `min-width: 0`. Reported from web-components-core's page migration.
11
+ - **Long `<code>` in a `.controls` button wraps** — rc03 only wrapped code inside
12
+ `.controls` labels; it now covers any `.controls code`, and a `.controls` button is
13
+ capped at the row width.
14
+ - **The playground's form-controls page now links `examples-local.css`** — FC08's
15
+ `.fc-player` row was unstyled; the e2e spec now checks it.
16
+
17
+ ### Added
18
+
19
+ - **Playground: a Widgets page** (`examples-widgets.html`, WG01–WG04) showing the kit's
20
+ opt-in helpers as they are today — light and dark `.log-panel`, the legacy `.event-log`,
21
+ `.pill` / `.status-dot` tones, `.display-sliders` with a live `.css-readout` — the base for
22
+ the coming log-tone work. With an e2e spec.
23
+
3
24
  ## [1.0.0-rc03] - 2026-11-01 [PUBLISHED]
4
25
 
5
26
  ### Fixed
package/README.md CHANGED
@@ -19,6 +19,12 @@ them in the same shape: `@keenmate/web-components-devkit`.
19
19
  > positioning) lives in [`@keenmate/web-components-core`](../web-components-core).
20
20
  > Nothing here ships inside a component's bundle.
21
21
 
22
+ ## What's New in v1.0.0-rc04
23
+
24
+ - **Example-page grids — wide content scrolls instead of widening the page** — A `<pre>` or table inside a `.grid`, `.grid-2` or `.card-grid` item still pushed the page wider than a phone: grid items default to `min-width: auto` (their min-content), so the single `1fr` column at ≤ 768 px grew to fit the content instead of letting it scroll. Every item of the three grids now gets `min-width: 0`, the same rule pure-css puts on its `.pc-col-*` columns. Found by two agents migrating web-components-core's example pages, which drop their page-local workaround with this release.
25
+ - **`.controls` — long `<code>` in a button wraps on a phone** — rc03 wrapped `<code>` only inside `.controls` labels, so a button whose label was an unbroken API name (`setAttribute("…")`) still overflowed the row. The wrap rule (`overflow-wrap: anywhere`) now covers any `<code>` in a `.controls` row, and a `.controls` button is capped at the row width. An e2e spec injects both cases at 390 px and checks that the page stays inside the screen.
26
+ - **Playground — a Widgets page for the kit's opt-in helpers** — `.log-panel` (light and `--dark`), the legacy `.event-log`, `.pill` / `.status-dot` tones, `.display-sliders` and `.css-readout` had no demo, so their look was only checked on component pages. The new `examples-widgets.html` (WG01–WG04) shows them as they are today, including the gaps the coming log-tone work fixes (no line tones, leading spaces collapsing in a log line), and gets its own e2e spec.
27
+
22
28
  ## What's New in v1.0.0-rc03
23
29
 
24
30
  - **Spotlight — Ctrl/⌘+K chapter search across every example page** — Example sites grew to dozens of chapters over several pages, and the per-page chapter nav only knew its own page. The Vite plugin now builds an index of every page's `<h2>`s (`virtual:kmwc-chapters`), coded and uncoded, and Ctrl/⌘+K opens a search that matches the section code or the heading text (`th7` finds `TH07`), grouped by page with the current one first. Enter jumps, Ctrl/⌘+Enter opens a new tab. It mirrors web-commandpalette's markup, matching, keyboard map and CSS without depending on it; `npm run check:spotlight-mirror` lists what changed there since the last alignment. Turn it off with `kmwc.examples.isSpotlightEnabled: false`.
@@ -28,13 +34,6 @@ them in the same shape: `@keenmate/web-components-devkit`.
28
34
  - **Example pages — short chapter links, phones and the example-pages suite** — `#th07`, `#th7` or an uncoded heading's slug now scroll to that chapter on arrival. On a phone, example pages no longer grow wider than the screen, which made mobile browsers report a wrong viewport to pages that demo breakpoints. `kmwc doctor` runs the rulebook's new `example-pages` suite: every example `<h2>` carries a permanent section code.
29
35
  - **`make dev` at the devkit root** — the standard `dev` / `kill-port` / `build-examples` / `preview-examples` targets, run against the playground.
30
36
 
31
- ## What's New in v1.0.0-rc02
32
-
33
- - **Theming — kit and scaffolds follow base-css-variables 2.0** — base-css-variables 2.0 dropped `--base-accent-color*`, `--base-text-color-on-accent` and `--base-input-color`, so a theme's primary colour silently stopped reaching the example pages and every newly scaffolded component. The `--kmwc-*` tokens in `src/examples/css/tokens.css` and the `templates/new*` `variables.css` now read `--base-primary-color` (with `-hover` / `-active` / `-bg-subtle`), `--base-on-primary-text-color` and `--base-input-text-color`, and the theming pages, docs and manifests set the new names. Standalone fallbacks are now the contract's own values, so a page looks the same with or without the contract loaded: a blue-500 primary instead of the old purple, slate surfaces, and on-colours computed from their fill. Re-run `kmwc new` output or diff your `variables.css` if you scaffolded on rc01.
34
- - **`npm run check:contract` — fallbacks can't drift from the contract** — `base-contract-check` from `@keenmate/base-css-variables` now runs over the kit, the scaffold templates and the playground. It fails when a `--base-*` read doesn't exist in the contract, when an input's fallback differs from the contract default, or when a derived token's fallback isn't the contract formula. Deliberate differences, such as the scaffolds inheriting the page font, are listed with a reason in `contract-check.json`. It's part of the gate before every kit or template change.
35
- - **`kmwc new --adopt` — migrate a component that's already registered** — Brings an existing repo onto the devkit with the same rulebook-shaped scaffold, using the registry entry's port block and CSS prefix, skipping the npm-name check (the package already exists) and leaving `components.json` untouched. Scaffold into a scratch `--dir` and move the component's code in. web-editor's one-package monorepo was flattened this way.
36
- - **`kmwc doctor` — rulebook suites run from an npm install** — With the devkit installed from npm instead of linked, doctor looked for the BlissFramework rulebook at a path relative to the devkit, which ended up inside `node_modules`, and silently skipped every suite. It now uses the nearest `BlissFramework/guidelines/web-components` above the component (then above the devkit), and `kmwc.rulebook.path` resolves against the component root.
37
-
38
37
  ## Catalogue
39
38
 
40
39
  <!-- kmwc:catalogue:start — generated by `npm run readme`, do not edit inside -->
@@ -286,6 +285,9 @@ doctor` lists the ones still repeating the head/header boilerplate.
286
285
  (tighter cells; the controls in it shrink via `--kmwc-control-height`) — plus
287
286
  `tr.is-highlight` and a `.num` cell (right-aligned, tabular figures). On a phone
288
287
  a wide table scrolls inside its card. See the playground's `examples-tables.html`.
288
+ - **Widgets** (`.log-panel` / `--dark`, `.event-log`, `.pill`, `.status-dot`,
289
+ `.display-sliders`, `.css-readout`) are shown in the playground's
290
+ `examples-widgets.html`.
289
291
  - **Theme switch** (top right) cycles light → dark → auto and sets
290
292
  `data-theme` on `<html>` — the same signal components react to via
291
293
  `:host-context([data-theme])`, so every example page is a dark-mode smoke
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@keenmate/web-components-devkit",
3
- "version": "1.0.0-rc03",
3
+ "version": "1.0.0-rc04",
4
4
  "description": "Shared dev, example-site and build infrastructure for Keenmate web components: Vite preset, examples kit (chapter nav, copy-link, controls store, shared styles), Playwright preset and the `kmwc` CLI (sync, doctor, check-vars, new, readme).",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -177,6 +177,13 @@
177
177
  gap: var(--grid-gap, 2rem);
178
178
  }
179
179
 
180
+ /* A grid item's min-width defaults to its min-content, so a wide <pre> or
181
+ table would widen the column (and the page on a phone) instead of
182
+ scrolling inside the item. */
183
+ :is(.grid, .grid-2, .card-grid) > * {
184
+ min-width: 0;
185
+ }
186
+
180
187
  .grid-2 {
181
188
  --grid-min: 400px;
182
189
  }
@@ -67,11 +67,16 @@
67
67
  max-width: 100%;
68
68
  }
69
69
 
70
- .controls label code,
70
+ /* Long code in a label or button breaks instead of widening the row. */
71
+ .controls code,
71
72
  .toggle-label code {
72
73
  overflow-wrap: anywhere;
73
74
  }
74
75
 
76
+ .controls button {
77
+ max-width: 100%;
78
+ }
79
+
75
80
  /* A select is as wide as its longest option — cap it at the row. */
76
81
  .controls select {
77
82
  max-width: 100%;