Skip to content

Commit 9a5322a

Browse files
Jeffrey Lauwersclaude
andcommitted
Update documentation to reflect current state (v4.3.0)
README changes: - Test count: 628 → 613 (tests removed for deleted API surface) - Component count: 21 → 22 form components - Fixed component composition examples to use new FormFieldset API instead of removed FormField isGroup / CheckboxGroup legend props Changelog v4.3.0: - Documents CI/CD test fixes for FormField, CheckboxGroup, RadioGroup - Explains architecture clarification (FormField vs FormFieldset) - Documents new interactive TokenControls component with Theme/Mode/Project Type selectors - Corrects v4.0.0 descriptions of CheckboxGroup/RadioGroup/FormField/FormFieldset Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
1 parent 5023aa3 commit 9a5322a

2 files changed

Lines changed: 57 additions & 19 deletions

File tree

README.md

Lines changed: 15 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ pnpm --filter @dsn/design-tokens watch
6565
# Start Storybook in development mode
6666
pnpm dev
6767

68-
# Run tests (628 tests across 35 test suites)
68+
# Run tests (613 tests across 35 test suites)
6969
pnpm test
7070

7171
# Run tests in watch mode
@@ -174,7 +174,7 @@ All components are fully typed with TypeScript and include comprehensive JSDoc d
174174
| **Paragraph** | Yes | Yes | Yes |
175175
| **UnorderedList** | Yes | Yes | Yes |
176176

177-
**Form Components (21 total)**
177+
**Form Components (22 total)**
178178

179179
| Component | HTML/CSS | React | Web Component |
180180
| ------------------------- | -------- | ----- | ------------- |
@@ -253,25 +253,24 @@ Components are designed to compose together:
253253
</FormField>
254254

255255
// React — Checkbox group with fieldset/legend
256-
<FormField
257-
label="Notification preferences"
258-
isGroup
256+
<FormFieldset
257+
legend="Notification preferences"
259258
description="Choose how you want to be notified"
260259
>
261-
<CheckboxGroup legend="Notification preferences">
262-
<CheckboxOption label="Email notifications" />
263-
<CheckboxOption label="SMS notifications" />
264-
<CheckboxOption label="Push notifications" />
260+
<CheckboxGroup>
261+
<CheckboxOption label="Email notifications" value="email" />
262+
<CheckboxOption label="SMS notifications" value="sms" />
263+
<CheckboxOption label="Push notifications" value="push" />
265264
</CheckboxGroup>
266-
</FormField>
265+
</FormFieldset>
267266

268267
// React — Radio group
269-
<FormField label="Delivery method" isGroup>
270-
<RadioGroup legend="Delivery method">
271-
<RadioOption label="Standard shipping" name="delivery" />
272-
<RadioOption label="Express shipping" name="delivery" />
268+
<FormFieldset legend="Delivery method">
269+
<RadioGroup>
270+
<RadioOption label="Standard shipping" name="delivery" value="standard" />
271+
<RadioOption label="Express shipping" name="delivery" value="express" />
273272
</RadioGroup>
274-
</FormField>
273+
</FormFieldset>
275274
```
276275

277276
## Accessibility
@@ -324,7 +323,7 @@ Comprehensive documentation is available in the `/docs` folder:
324323

325324
- **Pre-commit hooks** via Husky + lint-staged (ESLint + Prettier)
326325
- **Type checking** across all packages (`pnpm type-check`)
327-
- **396 tests** covering React components, Web Components, and utilities
326+
- **613 tests** covering React components, Web Components, and utilities
328327
- **CI/CD** via GitHub Actions (lint, type-check, test, build)
329328

330329
## Tech Stack

docs/changelog.md

Lines changed: 42 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,44 @@ All notable changes to this project are documented in this file.
66

77
---
88

9+
## Version 4.3.0 (February 17, 2025)
10+
11+
### CI/CD Fixes & Interactive Design Token Explorer
12+
13+
**CI/CD Test Fixes**
14+
15+
- **FormField tests rewritten** — Tests updated to match refactored architecture: `FormField` always renders div/label, removed all `isGroup` test cases
16+
- **CheckboxGroup tests rewritten** — Tests updated to match refactored component: renders div container (not fieldset), removed `legend`/`hideLegend` prop tests
17+
- **RadioGroup tests rewritten** — Tests updated to match refactored component: renders div container (not fieldset), removed `legend`/`hideLegend` prop tests
18+
- **All 613 tests passing** across 35 test suites (down from 628 due to removed tests for deleted API surface)
19+
20+
**Architecture Clarification (documented in tests)**
21+
22+
The component architecture was refactored in v4.2.0 but tests weren't updated:
23+
24+
| Component | Old API (removed) | New API |
25+
| --------------- | ---------------------------- | ----------------------------------------------- |
26+
| `FormField` | `isGroup`, `hideLabel` props | Always div/label; use `FormFieldset` for groups |
27+
| `CheckboxGroup` | `legend`, `hideLegend` props | Simple div container only |
28+
| `RadioGroup` | `legend`, `hideLegend` props | Simple div container only |
29+
30+
**Interactive Design Token Explorer**
31+
32+
- **TokenControls component** added to Design Tokens documentation page
33+
- **Three selectors** for live token exploration: Theme, Mode, and Project Type
34+
- **Theme options**: Start, Wireframe (matches actual available token files)
35+
- **Mode options**: Light, Dark
36+
- **Project Type options**: Default, Information Dense (from `project-types/` folder)
37+
- **Live updates**: Selecting a configuration dynamically loads the corresponding CSS file and refreshes all TokenTable values on the page
38+
- All 8 configurations available: 2 themes × 2 modes × 2 project types
39+
40+
**Documentation Updates**
41+
42+
- README component composition examples updated to use new `FormFieldset` API
43+
- Test counts updated to 613
44+
45+
---
46+
947
## Version 4.2.0 (February 16, 2025)
1048

1149
### GitHub Pages Deployment & Storybook Improvements
@@ -125,9 +163,10 @@ import './Button.css';
125163
- **Radio component** — Complete (HTML/CSS, React) with checked, disabled states
126164
- **CheckboxOption component** — Complete (HTML/CSS, React) combines Checkbox + Label with accessible touch targets
127165
- **RadioOption component** — Complete (HTML/CSS, React) combines Radio + Label with accessible touch targets
128-
- **CheckboxGroup component** — Complete (HTML/CSS, React) uses fieldset/legend for accessible grouping
129-
- **RadioGroup component** — Complete (HTML/CSS, React) uses fieldset/legend for accessible grouping
130-
- **FormField component** — Complete (HTML/CSS, React) intelligent container with automatic fieldset/legend vs div/label rendering
166+
- **CheckboxGroup component** — Complete (HTML/CSS, React) div container for CheckboxOption items; pair with FormFieldset for accessible grouping
167+
- **RadioGroup component** — Complete (HTML/CSS, React) div container for RadioOption items; pair with FormFieldset for accessible grouping
168+
- **FormField component** — Complete (HTML/CSS, React) div/label container for single-value inputs (TextInput, TextArea, etc.)
169+
- **FormFieldset component** — Complete (HTML/CSS, React) fieldset/legend container for group controls (CheckboxGroup, RadioGroup)
131170
- **FormFieldLabel component** — Complete (HTML/CSS, React) with required indicator and suffix support
132171
- **FormFieldDescription component** — Complete (HTML/CSS, React) for help text
133172
- **FormFieldErrorMessage component** — Complete (HTML/CSS, React) for validation errors

0 commit comments

Comments
 (0)