You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: packages/react/src/calendar/index.md
+12-1Lines changed: 12 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,6 +27,17 @@ Display a full calendar view with date selection. Useful for scheduling, event m
27
27
import { Calendar } from'tiny-design';
28
28
```
29
29
30
+
## Design Tokens
31
+
32
+
`Calendar` follows the same semantic token structure as `DatePicker`, but keeps its own component namespace:
33
+
34
+
-`calendar.header-*`: header spacing, navigation actions, caption labels, and focus states
35
+
-`calendar.cell-*`: month grid cells, weekday headers, week numbers, selected dates, and range states
36
+
-`calendar.panel-item-*`: year and decade panel items for hover and selected states
37
+
-`calendar.today-*`: footer "Today" action typography and interaction states
38
+
39
+
This alignment is intentional: `Calendar` and `DatePicker` should feel related, but token keys stay separate so product teams can tune them independently.
40
+
30
41
## Examples
31
42
32
43
<Layout>
@@ -160,4 +171,4 @@ Compact card calendar with keyboard navigation. Use arrow keys, Enter, and Escap
Copy file name to clipboardExpand all lines: packages/react/src/date-picker/index.md
+11Lines changed: 11 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -25,6 +25,17 @@ To select or input a date.
25
25
import { DatePicker } from'tiny-design';
26
26
```
27
27
28
+
## Design Tokens
29
+
30
+
`DatePicker` uses component-scoped tokens with a small set of stable semantic groups:
31
+
32
+
-`date-picker.header-*`: header layout, navigation buttons, caption spacing, and interactive header states
33
+
-`date-picker.cell-*`: date grid cells, selected dates, muted dates, and range states
34
+
-`date-picker.panel-item-*`: month/year panel items for hover, current item, and selected item styling
35
+
-`date-picker.today-*`: footer "Today" action typography and interaction states
36
+
37
+
`DatePicker` intentionally does not share token keys with `Calendar`. The two components align on token semantics, but keep separate namespaces so each component can evolve independently.
0 commit comments