@ai-matrx/design-system 0.1.1 → 0.3.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,106 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.3.0 — 2026-08-29
4
+
5
+ The second C18 growth wave: the three primitive families the associations
6
+ package's W4 faces are blocked on. Verbatim behavior ports from
7
+ matrx-frontend with only coupling seams inverted.
8
+
9
+ New components (origin file in matrx-frontend):
10
+
11
+ - `Command`, `CommandInput`, `CommandList`, `CommandItem`, `CommandGroup`,
12
+ `CommandEmpty`, `CommandSeparator`, `CommandShortcut`, `CommandDialog` —
13
+ `components/ui/command.tsx`. **`cmdk` is a sanctioned real dependency**
14
+ (the vaul ↔ BottomSheet precedent): its filtering/scoring/keyboard engine
15
+ IS the component's product; reimplementing it would twin a maintained
16
+ library. `CommandDialog` composed the host dialog module — those pieces
17
+ (modal context, overlay, desktop card / mobile bottom-sheet geometry,
18
+ close control) are inlined privately with identical behavior; the host's
19
+ popout-aware portal became the `PortalContainerProvider` seam plus an
20
+ explicit `container` prop; the host `useIsMobile` matchMedia hook (768px,
21
+ browser-generic) is inlined privately.
22
+ - `Select`, `SelectGroup`, `SelectValue`, `SelectTrigger`, `SelectContent`,
23
+ `SelectLabel`, `SelectItem`, `SelectSeparator`, `SelectScrollUpButton`,
24
+ `SelectScrollDownButton` (+ `selectTriggerVariants`, `SelectTriggerProps`)
25
+ — `components/ui/select.tsx`, with **`@radix-ui/react-select`** as a real
26
+ dependency (^2.3.1, the host's installed version). The host's
27
+ `useNestedPortalContainer` became the `PortalContainerProvider` seam;
28
+ the explicit `container` prop keeps top priority. The origin's dead
29
+ `CaretSortIcon` import was not carried along.
30
+ - `CreatablePicker` + `CreatableOption` / `CreatablePickerProps` /
31
+ `PickerIcon` — `components/ui/creatable-picker.tsx`, the P23 "every
32
+ picker takes new input" composite, ported complete (create flow,
33
+ `onCreateRequiresMore`, `createExtra` slot, P11 `lockedNote`/`lockedAction`,
34
+ the manage door, `footerActions`, `renderSelected`). It composes the
35
+ package's own Popover + Command; the host `LucideIcon` type became the
36
+ structural `PickerIcon`. It still never grows a write path of its own —
37
+ `onCreate` stays the caller's ONE canonical write path.
38
+
39
+ All icons the originals drew (radix `MagnifyingGlass`/`Check`/`ChevronUp`/
40
+ `ChevronDown`, lucide `check`/`chevrons-up-down`/`external-link`/`lock`/
41
+ `plus`/`x`) are shipped as package-inlined SVGs of the same glyphs (C19 —
42
+ no icon-library dependency, ever).
43
+
44
+ Tests: +18 (54 total) — cmdk filtering/keyboard-nav/disabled-skip,
45
+ CommandDialog modal + portal seam, Select pointer open/select + keyboard +
46
+ portal seam, CreatablePicker type-ahead/create/empty-add-guard/exact-match/
47
+ requires-more/P11-lock/doors, and SSR renders for all three families. The
48
+ tarball canary imports AND requires the new surface.
49
+
50
+ New dependencies: `cmdk` (^1.1.1), `@radix-ui/react-select` (^2.3.1).
51
+
52
+ ## 0.2.0 — 2026-08-29
53
+
54
+ The associations-W4 growth wave (ruling C18: the faces' chrome comes from
55
+ growing this package — never vendored twins) plus the small-package register
56
+ rows that ride design-system (S16–S21). Every component is a verbatim
57
+ behavior port from matrx-frontend with only its coupling seams inverted.
58
+
59
+ New components (origin file in matrx-frontend):
60
+
61
+ - `Input`, `EnterInput`, `BasicInput`, `InputWithPrefix` — `components/ui/input.tsx`.
62
+ The host's `MatrxVariant` became the structural `InputVariant` union. The
63
+ original file's `CopyInput`/`FancyInput`/`DeleteInput` are deliberately NOT
64
+ absorbed (C8): they carry a `motion/react` dependency plain-Input consumers
65
+ must not pay for.
66
+ - `Popover`, `PopoverTrigger`, `PopoverAnchor`, `PopoverContent` —
67
+ `components/ui/popover.tsx`. The host's `useNestedPortalContainer` hook
68
+ became the injected `PortalContainerProvider` / `usePortalContainer` seam;
69
+ the explicit `container` prop keeps top priority.
70
+ - `Sheet` family (+ `sheetVariants`) — `components/ui/sheet.tsx`. The host
71
+ dialog module's `DialogContentPrimitive` is inlined as a private equivalent;
72
+ `RadixDialogModalProvider`/`useRadixDialogModal` ported verbatim from
73
+ `components/ui/radix-dialog-modal-context.tsx`; `treeContainsComponent`
74
+ stays the one `@ai-matrx/kit/react-tree` implementation (new peer).
75
+ - `Skeleton` — `components/ui/skeleton.tsx`.
76
+ - `EditableLabel` (S16) — `components/official/item/EditableLabel.tsx`, with
77
+ its prop types carried along instead of the host item-system `types.ts`.
78
+ - `SegmentedControl` (S17) — `components/ui/segmented-control.tsx`.
79
+ - `ScoreRing` + `scoreRingColorClasses` / `scoreAccentBgClasses` /
80
+ `DEFAULT_SCORE_THRESHOLDS` (S18) — `components/official/ScoreRing.tsx`.
81
+ The score→color thresholds are the product and port unchanged.
82
+ - `BottomSheet` family + `TabbedBottomSheet` (S19) —
83
+ `components/official/bottom-sheet/`. `vaul` is a sanctioned real dependency
84
+ (see FEATURE.md); the host drawer wrappers it needed are inlined privately.
85
+ - `OverflowToolbar` (S20) — `components/official/toolbar/OverflowToolbar.tsx`.
86
+ `LucideIcon` became the structural `ToolbarIcon`; the host Tooltip and
87
+ ItemMenu became the injected `renderTooltip` / `renderOverflowMenu` seams.
88
+ - `useScrollFade` (S21) — `components/official/scroll-fade/useScrollFade.ts`.
89
+
90
+ All icons the originals drew through lucide-react / @radix-ui/react-icons are
91
+ shipped as package-inlined SVGs of the same glyphs (policy C19 — no
92
+ icon-library dependency, ever).
93
+
94
+ Packaging (2026-08-29 authoring rules):
95
+
96
+ - Dual ESM + CJS output with matching `.d.ts`/`.d.cts`; the packed-tarball
97
+ canary now imports AND requires the public surface.
98
+ - The `"use client"` boundary is stamped via the tsup banner (treeshake off so
99
+ it survives) and asserted on both built entries from the packed tarball.
100
+
101
+ New dependencies: `@radix-ui/react-dialog`, `@radix-ui/react-popover`,
102
+ `@radix-ui/react-visually-hidden`, `vaul`; new peer: `@ai-matrx/kit` (>=0.5.1).
103
+
3
104
  ## 0.1.1 — 2026-08-22
4
105
 
5
106
  - Preserved the package-level `"use client"` boundary in the built ESM entry so
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @ai-matrx/design-system
2
2
 
3
- The small, semantic UI foundation shared by AI Matrx React applications. Version 0.1 contains the first primitives whose behavior and variants are identical across Vite and Next.js hosts: Button, Badge, Label, Separator, and the `cn` utility.
3
+ The small, semantic UI foundation shared by AI Matrx React applications primitives whose behavior and variants are identical across Vite and Next.js hosts. Version 0.2 ships Button, Badge, Label, Separator, the Input family, Popover, Sheet, Skeleton, EditableLabel, SegmentedControl, ScoreRing, BottomSheet + TabbedBottomSheet, OverflowToolbar, the `useScrollFade` hook, and the `cn` utility.
4
4
 
5
5
  ```bash
6
6
  pnpm add @ai-matrx/design-system
@@ -13,7 +13,9 @@ import { Badge, Button } from "@ai-matrx/design-system";
13
13
  <Badge variant="success">Ready</Badge>
14
14
  ```
15
15
 
16
- The package intentionally does not ship product colors. Hosts define the normal Tailwind semantic tokens (`primary`, `background`, `border`, `muted`, `success`, and `warning`), so one component follows each product's theme without forking behavior.
16
+ The package intentionally does not ship product colors. Hosts define the normal Tailwind semantic tokens (`primary`, `background`, `border`, `muted`, `success`, and `warning`), so one component follows each product's theme without forking behavior. A few ported components additionally reference host-owned CSS contracts and degrade gracefully without them: the glass tokens/utilities used by the BottomSheet family, the `.matrx-scroll-fade` styling for `useScrollFade`, and the `shadow-input` utility.
17
+
18
+ Host-shaped systems are injected, never imported: wrap subtrees in `PortalContainerProvider` to point nested Popover portals at a dialog or popout body, and hand `OverflowToolbar` your menu and tooltip systems through its `renderOverflowMenu` / `renderTooltip` props. `@ai-matrx/kit` (>= 0.5.1) is a peer dependency.
17
19
 
18
20
  Tailwind CSS v4 ignores `node_modules` by default. Registry consumers must register the package build beside their Tailwind import:
19
21