@hideyukimori/nene2-ui 0.14.0 → 0.15.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.
@@ -50,7 +50,7 @@ export function ToastProvider({ regionLabel, dismissLabel, defaultDurationMs = 5
50
50
  const api = useMemo(() => ({ show, dismiss }), [show, dismiss]);
51
51
  const region = (tone, live) => (_jsx("div", { "aria-live": live, "aria-label": regionLabel, role: "region", className: "flex flex-col gap-x-slot-toast-gap", children: toasts
52
52
  .filter((toast) => toast.tone === tone)
53
- .map((toast) => (_jsxs("div", { className: cx('flex items-start gap-x-slot-toast-gap rounded-x-slot-toast border p-x-slot-toast-pad font-sans shadow-sm', TONE_CLASS[toast.tone]), children: [_jsx("span", { children: toast.message }), _jsx("button", { type: "button", "aria-label": dismissLabel, onClick: () => dismiss(toast.id), className: cx('rounded-x-slot-toast px-x-slot-toast-dismiss-pad-x', CLICKABLE_CLASS), children: dismissLabel })] }, toast.id))) }));
53
+ .map((toast) => (_jsxs("div", { className: cx('flex items-start gap-x-slot-toast-gap rounded-x-slot-toast border p-x-slot-toast-pad font-sans shadow-x-slot-toast', TONE_CLASS[toast.tone]), children: [_jsx("span", { children: toast.message }), _jsx("button", { type: "button", "aria-label": dismissLabel, onClick: () => dismiss(toast.id), className: cx('rounded-x-slot-toast px-x-slot-toast-dismiss-pad-x', CLICKABLE_CLASS), children: dismissLabel })] }, toast.id))) }));
54
54
  return (_jsxs(ToastContext.Provider, { value: api, children: [children, region('info', 'polite'), region('danger', 'assertive')] }));
55
55
  }
56
56
  //# sourceMappingURL=ToastProvider.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ToastProvider.js","sourceRoot":"","sources":["../../src/feedback/ToastProvider.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAkB,MAAM,OAAO,CAAC;AAC1F,OAAO,EAAE,EAAE,EAAE,MAAM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AAC,KAAK,EAAE,CAAC;QAClB,CAAC,CAAC;IACJ,CAAC,EAAE,EAAE,CAAC,CAAC;IAEP,MAAM,GAAG,GAAG,OAAO,CAAW,GAAG,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC,CAAC;IAE1E,MAAM,MAAM,GAAG,CAAC,IAAe,EAAE,IAA4B,EAAE,EAAE,CAAC,CAChE,2BACa,IAAI,gBACH,WAAW,EACvB,IAAI,EAAC,QAAQ,EACb,SAAS,EAAC,oCAAoC,YAE7C,MAAM;aACJ,MAAM,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,IAAI,KAAK,IAAI,CAAC;aACtC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,CACd,eAEE,SAAS,EAAE,EAAE,CACX,oHAAoH,EACpH,UAAU,CAAC,KAAK,CAAC,IAAI,CAAC,CACvB,aAED,yBAAO,KAAK,CAAC,OAAO,GAAQ,EAC5B,iBACE,IAAI,EAAC,QAAQ,gBACD,YAAY,EACxB,OAAO,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE,CAAC,EAChC,SAAS,EAAE,EAAE,CAAC,oDAAoD,EAAE,eAAe,CAAC,YAEnF,YAAY,GACN,KAdJ,KAAK,CAAC,EAAE,CAeT,CACP,CAAC,GACA,CACP,CAAC;IAEF,OAAO,CACL,MAAC,YAAY,CAAC,QAAQ,IAAC,KAAK,EAAE,GAAG,aAC9B,QAAQ,EACR,MAAM,CAAC,MAAM,EAAE,QAAQ,CAAC,EACxB,MAAM,CAAC,QAAQ,EAAE,WAAW,CAAC,IACR,CACzB,CAAC;AACJ,CAAC"}
@@ -8,6 +8,6 @@ import { GAP, PAD, resolve } from '../lib/spacing.js';
8
8
  * given its own colour would be a `div` with extra steps.
9
9
  */
10
10
  export function Card({ pad = 'sm', gap, raised = false, children, className, ...rest }) {
11
- return (_jsx("div", { className: cx('flex flex-col bg-x-slot-card-bg border border-x-slot-card-border rounded-x-slot-card', raised && 'shadow-sm', resolve(pad, PAD), resolve(gap, GAP), className), ...rest, children: children }));
11
+ return (_jsx("div", { className: cx('flex flex-col bg-x-slot-card-bg border border-x-slot-card-border rounded-x-slot-card', raised && 'shadow-x-slot-card-raised', resolve(pad, PAD), resolve(gap, GAP), className), ...rest, children: children }));
12
12
  }
13
13
  //# sourceMappingURL=Card.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Card.js","sourceRoot":"","sources":["../../src/layout/Card.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,EAAE,EAAE,MAAM,cAAc,CAAC;AAClC,OAAO,EAAE,GAAG,EAAE,GAAG,EAAE,OAAO,EAA+B,MAAM,mBAAmB,CAAC;AAUnF;;;;;GAKG;AACH,MAAM,UAAU,IAAI,CAAC,EAAE,GAAG,GAAG,IAAI,EAAE,GAAG,EAAE,MAAM,GAAG,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,GAAG,IAAI,EAAa;IAC/F,OAAO,CACL,cACE,SAAS,EAAE,EAAE,CACX,sFAAsF,EACtF,MAAM,IAAI,WAAW,EACrB,OAAO,CAAC,GAAG,EAAE,GAAG,CAAC,EACjB,OAAO,CAAC,GAAG,EAAE,GAAG,CAAC,EACjB,SAAS,CACV,KACG,IAAI,YAEP,QAAQ,GACL,CACP,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"Card.js","sourceRoot":"","sources":["../../src/layout/Card.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,EAAE,EAAE,MAAM,cAAc,CAAC;AAClC,OAAO,EAAE,GAAG,EAAE,GAAG,EAAE,OAAO,EAA+B,MAAM,mBAAmB,CAAC;AAUnF;;;;;GAKG;AACH,MAAM,UAAU,IAAI,CAAC,EAAE,GAAG,GAAG,IAAI,EAAE,GAAG,EAAE,MAAM,GAAG,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,GAAG,IAAI,EAAa;IAC/F,OAAO,CACL,cACE,SAAS,EAAE,EAAE,CACX,sFAAsF,EACtF,MAAM,IAAI,2BAA2B,EACrC,OAAO,CAAC,GAAG,EAAE,GAAG,CAAC,EACjB,OAAO,CAAC,GAAG,EAAE,GAAG,CAAC,EACjB,SAAS,CACV,KACG,IAAI,YAEP,QAAQ,GACL,CACP,CAAC;AACJ,CAAC"}
@@ -2,7 +2,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { cx } from '../lib/cx.js';
3
3
  import { CLICKABLE_CLASS, TOUCH_CLASS } from '../lib/states.js';
4
4
  const VARIANT_CLASS = {
5
- primary: 'bg-x-slot-button-primary-bg text-x-slot-button-primary-fg',
5
+ primary: 'bg-x-slot-button-primary-bg text-x-slot-button-primary-fg shadow-x-slot-button-primary',
6
6
  secondary: 'bg-x-slot-button-secondary-bg text-x-slot-button-secondary-fg border-x-slot-button-secondary-border',
7
7
  danger: 'bg-x-slot-button-danger-bg text-x-slot-button-danger-fg',
8
8
  // No fill and no border: for the third action in a row, where two framed buttons would
@@ -1 +1 @@
1
- {"version":3,"file":"Button.js","sourceRoot":"","sources":["../../src/primitives/Button.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,EAAE,EAAE,MAAM,cAAc,CAAC;AAClC,OAAO,EAAE,eAAe,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAchE,MAAM,aAAa,GAAwD;IACzE,OAAO,EAAE,2DAA2D;IACpE,SAAS,EACP,qGAAqG;IACvG,MAAM,EAAE,yDAAyD;IACjE,uFAAuF;IACvF,kEAAkE;IAClE,KAAK,EAAE,4CAA4C;CACpD,CAAC;AAEF,MAAM,UAAU,GAAqD;IACnE,EAAE,EAAE,uEAAuE;IAC3E,EAAE,EAAE,gFAAgF;CACrF,CAAC;AAEF,2FAA2F;AAC3F,4FAA4F;AAC5F,0FAA0F;AAC1F,wFAAwF;AACxF,6FAA6F;AAC7F,yFAAyF;AACzF,kCAAkC;AAClC,EAAE;AACF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4F;AAC5F,0FAA0F;AAC1F,wFAAwF;AACxF,6FAA6F;AAC7F,yFAAyF;AACzF,kCAAkC;AAClC,EAAE;AACF,0FAA0F;AAC1F,8FAA8F;AAC9F,8FAA8F;AAC9F,0FAA0F;AAC1F,EAAE;AACF,wFAAwF;AACxF,uFAAuF;AACvF,0FAA0F;AAC1F,6FAA6F;AAC7F,mDAAmD;AACnD,2FAA2F;AAC3F,6FAA6F;AAC7F,4FAA4F;AAC5F,yDAAyD;AACzD,EAAE;AACF,2FAA2F;AAC3F,0FAA0F;AAC1F,yFAAyF;AACzF,yFAAyF;AACzF,yCAAyC;AACzC,MAAM,SAAS,GAAG,mEAAmE,CAAC;AAEtF,MAAM,UAAU,GAAG,8IAA8I,SAAS,IAAI,WAAW,IAAI,eAAe,EAAE,CAAC;AAE/M,MAAM,UAAU,MAAM,CAAC,EACrB,OAAO,GAAG,SAAS,EACnB,IAAI,GAAG,IAAI,EACX,QAAQ,EACR,IAAI,GAAG,QAAQ,EACf,SAAS,EACT,GAAG,IAAI,EACK;IACZ,OAAO,CACL,iBACE,IAAI,EAAE,IAAI,EACV,SAAS,EAAE,EAAE,CAAC,UAAU,EAAE,UAAU,CAAC,IAAI,CAAC,EAAE,aAAa,CAAC,OAAO,CAAC,EAAE,SAAS,CAAC,KAC1E,IAAI,YAEP,QAAQ,GACF,CACV,CAAC;AACJ,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hideyukimori/nene2-ui",
3
- "version": "0.14.0",
3
+ "version": "0.15.0",
4
4
  "description": "NeNe fleet shared React UI kit — token-driven primitives on Tailwind v4 @theme. Components carry no design of their own; themes do.",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -12,7 +12,8 @@
12
12
  "default": "./dist/index.js"
13
13
  },
14
14
  "./themes/default.css": "./themes/default.css",
15
- "./package.json": "./package.json"
15
+ "./package.json": "./package.json",
16
+ "./themes/slot-pairs.json": "./themes/slot-pairs.json"
16
17
  },
17
18
  "files": [
18
19
  "dist",
@@ -43,7 +43,25 @@
43
43
  --color-on-warn: oklch(21% 0.04 75);
44
44
  --color-danger-soft: oklch(95% 0.03 30);
45
45
 
46
+ /* The shadow scale. Three steps, chosen the way the spacing and radius scales were —
47
+ * measured from what the fleet already ships, not invented here (#386).
48
+ *
49
+ * 🔴 Until 0.15.0 this namespace held one value, and #386 was about to point slots at it.
50
+ * That is the 0.7.0 radius defect exactly: eight slots, one value, every structural check
51
+ * green on a layer that cannot express a choice. The test that caught it is
52
+ * `readme.test.ts` — "every namespace that has slots offers more than one step".
53
+ *
54
+ * Measured 2026-08-24 across the fleet's own `--shadow-*` definitions (sm: 9 ships,
55
+ * md: 9, lg: 7). Each step is the median of each component — offset, blur, alpha —
56
+ * kept to a single layer like `sm`, though four ships stack two.
57
+ *
58
+ * ⚠️ `focus` is a contract key (`SHADOW_KEYS`) with no step here, deliberately: the kit
59
+ * draws focus with `outline`, not a box-shadow ring, because `ring-*` is a box-shadow and
60
+ * a parent with `overflow: hidden` clips it (see `lib/states.ts`). A `--shadow-focus`
61
+ * would be a value with no user. */
46
62
  --shadow-sm: 0 1px 2px oklch(0% 0 0 / 0.06);
63
+ --shadow-md: 0 4px 16px oklch(0% 0 0 / 0.09);
64
+ --shadow-lg: 0 16px 44px oklch(0% 0 0 / 0.16);
47
65
 
48
66
  /* Typography. Until 0.3.0 the kit had none of these and the components carried
49
67
  * `font-medium` and a colour choice inline — which is a design value living outside this
@@ -364,10 +382,29 @@
364
382
  * `--spacing-x-slot-button-{,sm-}pad-{x,y}` is four slots, the font was one. nene-vault
365
383
  * shipped md=13px and sm=12px, and on the kit both came out at the same size — its
366
384
  * pagination "Previous" measured 12px in production against 13px on the migrated build.
367
- * Defaults to `inherit` like its sibling, so nothing renders differently today. */
385
+ * Defaults to `inherit` like its sibling. That makes the two render alike ONLY while a
386
+ * consumer overrides both or neither: override `--text-x-slot-button-size` alone and `sm`
387
+ * keeps inheriting the surrounding body size, so `sm` comes out LARGER than `md` (#380).
388
+ * The pair is listed in `themes/slot-pairs.json` with `overrideTogether: true`. */
368
389
  --text-x-slot-button-sm-size: inherit;
369
390
  --text-x-slot-choice-size: inherit;
370
391
 
392
+ /* ── Shadow slots ─────────────────────────────────────────────────────────────
393
+ * 🔴 Shadow was the one dimension that never got slots (#386). 0.9.0 moved "colour, weight
394
+ * and the type scale" through slots and the enumeration in that sentence decided the
395
+ * scope — so `Card` and `Toast` kept writing `shadow-sm` inline, on the same line as
396
+ * `rounded-x-slot-*` and `p-x-slot-*`, and `Button` could not carry a shadow at all.
397
+ * nene-vault lost its primary button's shadow on migration because of it.
398
+ *
399
+ * 🔴 Every default here is a copy of what the component rendered before this release, not
400
+ * a value someone thought was nice. `Button` had no shadow, so its default is `none`;
401
+ * `Card` and `Toast` wrote `shadow-sm`, so theirs point at the scale. A default that is
402
+ * anything other than the current rendering changes how every product already looks —
403
+ * and "the default is harmless" only holds while the default is that copy. */
404
+ --shadow-x-slot-button-primary: none;
405
+ --shadow-x-slot-card-raised: var(--shadow-sm);
406
+ --shadow-x-slot-toast: var(--shadow-sm);
407
+
371
408
  /* Sentinel for the consumer's build (#316). Zero-width, so applying it does nothing.
372
409
  * Its only job is to exist: `p-x-source-probe` appears nowhere except this kit's `dist`,
373
410
  * so a build that generates it has the kit in its `@source`, and a build that does not
@@ -0,0 +1,28 @@
1
+ {
2
+ "$comment": [
3
+ "サイズ違いで対になっているスロットの一覧(#380)。",
4
+ "消費者のテーマ検査が『片側だけ上書きされていないか』を見るための配布データ。",
5
+ "手で書かない —— themes/default.css から導出され、src/lib/slot-pairs.test.ts が突合する。",
6
+ "overrideTogether が true の対は、既定が両方 inherit のため片側だけ上書きすると段が反転する。"
7
+ ],
8
+ "pairs": [
9
+ {
10
+ "base": "--spacing-x-slot-button-pad-x",
11
+ "sm": "--spacing-x-slot-button-sm-pad-x",
12
+ "defaults": { "base": "var(--spacing-x-sm)", "sm": "var(--spacing-x-xs)" },
13
+ "overrideTogether": false
14
+ },
15
+ {
16
+ "base": "--spacing-x-slot-button-pad-y",
17
+ "sm": "--spacing-x-slot-button-sm-pad-y",
18
+ "defaults": { "base": "var(--spacing-x-xs)", "sm": "var(--spacing-x-3xs)" },
19
+ "overrideTogether": false
20
+ },
21
+ {
22
+ "base": "--text-x-slot-button-size",
23
+ "sm": "--text-x-slot-button-sm-size",
24
+ "defaults": { "base": "inherit", "sm": "inherit" },
25
+ "overrideTogether": true
26
+ }
27
+ ]
28
+ }