@idyeah/diya 0.0.0 → 1.0.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.
Files changed (190) hide show
  1. package/CHANGELOG.md +317 -0
  2. package/NOTICE +29 -0
  3. package/README.md +596 -5
  4. package/dist/DiyaProvider.d.ts +79 -0
  5. package/dist/DiyaProvider.js +77 -0
  6. package/dist/Icon.d.ts +10 -0
  7. package/dist/Icon.js +27 -0
  8. package/dist/accordion/Accordion.d.ts +34 -0
  9. package/dist/accordion/Accordion.js +15 -0
  10. package/dist/alert/Alert.d.ts +49 -0
  11. package/dist/alert/Alert.js +11 -0
  12. package/dist/alert/messages.d.ts +9 -0
  13. package/dist/alert/messages.js +2 -0
  14. package/dist/api.json +7277 -0
  15. package/dist/api.schema.json +214 -0
  16. package/dist/application-patterns/Chatbot.d.ts +114 -0
  17. package/dist/application-patterns/Chatbot.js +110 -0
  18. package/dist/application-patterns/SideNavigation.d.ts +74 -0
  19. package/dist/application-patterns/SideNavigation.js +31 -0
  20. package/dist/application-patterns/chatbot-messages.d.ts +20 -0
  21. package/dist/application-patterns/chatbot-messages.js +2 -0
  22. package/dist/application-patterns/side-navigation-messages.d.ts +5 -0
  23. package/dist/application-patterns/side-navigation-messages.js +2 -0
  24. package/dist/avatar/Avatar.d.ts +32 -0
  25. package/dist/avatar/Avatar.js +19 -0
  26. package/dist/avatar/messages.d.ts +7 -0
  27. package/dist/avatar/messages.js +2 -0
  28. package/dist/badge/Badge.d.ts +42 -0
  29. package/dist/badge/Badge.js +16 -0
  30. package/dist/badge/badge-utils.d.ts +6 -0
  31. package/dist/badge/badge-utils.js +24 -0
  32. package/dist/badge/messages.d.ts +4 -0
  33. package/dist/badge/messages.js +2 -0
  34. package/dist/breadcrumbs/Breadcrumbs.d.ts +34 -0
  35. package/dist/breadcrumbs/Breadcrumbs.js +19 -0
  36. package/dist/breadcrumbs/messages.d.ts +5 -0
  37. package/dist/breadcrumbs/messages.js +2 -0
  38. package/dist/button/Button.d.ts +46 -0
  39. package/dist/button/Button.js +44 -0
  40. package/dist/calendar/Calendar.d.ts +55 -0
  41. package/dist/calendar/Calendar.js +61 -0
  42. package/dist/calendar/messages.d.ts +8 -0
  43. package/dist/calendar/messages.js +2 -0
  44. package/dist/calendar/month.d.ts +61 -0
  45. package/dist/calendar/month.js +134 -0
  46. package/dist/card/Card.d.ts +46 -0
  47. package/dist/card/Card.js +8 -0
  48. package/dist/choice/Choice.d.ts +72 -0
  49. package/dist/choice/Choice.js +68 -0
  50. package/dist/choice/messages.d.ts +4 -0
  51. package/dist/choice/messages.js +2 -0
  52. package/dist/code-block/CodeBlock.d.ts +20 -0
  53. package/dist/code-block/CodeBlock.js +49 -0
  54. package/dist/code-block/messages.d.ts +8 -0
  55. package/dist/code-block/messages.js +2 -0
  56. package/dist/combobox/Combobox.d.ts +60 -0
  57. package/dist/combobox/Combobox.js +160 -0
  58. package/dist/combobox/messages.d.ts +9 -0
  59. package/dist/combobox/messages.js +2 -0
  60. package/dist/combobox/useAnchoredPopover.d.ts +5 -0
  61. package/dist/combobox/useAnchoredPopover.js +100 -0
  62. package/dist/data-viz/DataViz.d.ts +140 -0
  63. package/dist/data-viz/DataViz.js +469 -0
  64. package/dist/data-viz/index.d.ts +2 -0
  65. package/dist/data-viz/index.js +1 -0
  66. package/dist/data-viz/messages.d.ts +11 -0
  67. package/dist/data-viz/messages.js +2 -0
  68. package/dist/date-picker/DatePicker.d.ts +57 -0
  69. package/dist/date-picker/DatePicker.js +146 -0
  70. package/dist/date-picker/messages.d.ts +13 -0
  71. package/dist/date-picker/messages.js +2 -0
  72. package/dist/dialog/Dialog.d.ts +84 -0
  73. package/dist/dialog/Dialog.js +107 -0
  74. package/dist/dialog/messages.d.ts +9 -0
  75. package/dist/dialog/messages.js +2 -0
  76. package/dist/fonts/DIYASans-Italic.woff2 +0 -0
  77. package/dist/fonts/DIYASans.woff2 +0 -0
  78. package/dist/fonts/OFL.txt +94 -0
  79. package/dist/index.d.ts +50 -0
  80. package/dist/index.js +46 -0
  81. package/dist/internal/brand.d.ts +33 -0
  82. package/dist/internal/brand.js +57 -0
  83. package/dist/internal/cx.d.ts +2 -0
  84. package/dist/internal/cx.js +4 -0
  85. package/dist/internal/link.d.ts +14 -0
  86. package/dist/internal/link.js +7 -0
  87. package/dist/internal/slot.d.ts +15 -0
  88. package/dist/internal/slot.js +67 -0
  89. package/dist/layout/Inline.d.ts +4 -0
  90. package/dist/layout/Inline.js +7 -0
  91. package/dist/layout/Stack.d.ts +4 -0
  92. package/dist/layout/Stack.js +7 -0
  93. package/dist/layout/layout.d.ts +32 -0
  94. package/dist/layout/layout.js +12 -0
  95. package/dist/link/TextLink.d.ts +23 -0
  96. package/dist/link/TextLink.js +17 -0
  97. package/dist/list/List.d.ts +48 -0
  98. package/dist/list/List.js +17 -0
  99. package/dist/list/messages.d.ts +4 -0
  100. package/dist/list/messages.js +2 -0
  101. package/dist/menu/Menu.d.ts +49 -0
  102. package/dist/menu/Menu.js +54 -0
  103. package/dist/messages-defaults.d.ts +201 -0
  104. package/dist/messages-defaults.js +61 -0
  105. package/dist/messages.d.ts +12 -0
  106. package/dist/messages.js +1 -0
  107. package/dist/metric/Metric.d.ts +42 -0
  108. package/dist/metric/Metric.js +11 -0
  109. package/dist/metric/messages.d.ts +9 -0
  110. package/dist/metric/messages.js +2 -0
  111. package/dist/overlay/FloatingSurface.d.ts +29 -0
  112. package/dist/overlay/FloatingSurface.js +254 -0
  113. package/dist/page-header/PageHeader.d.ts +38 -0
  114. package/dist/page-header/PageHeader.js +10 -0
  115. package/dist/pagination/Pagination.d.ts +44 -0
  116. package/dist/pagination/Pagination.js +26 -0
  117. package/dist/pagination/messages.d.ts +11 -0
  118. package/dist/pagination/messages.js +2 -0
  119. package/dist/popover/Popover.d.ts +23 -0
  120. package/dist/popover/Popover.js +8 -0
  121. package/dist/progress/Progress.d.ts +33 -0
  122. package/dist/progress/Progress.js +14 -0
  123. package/dist/progress/messages.d.ts +4 -0
  124. package/dist/progress/messages.js +2 -0
  125. package/dist/prose/Prose.d.ts +14 -0
  126. package/dist/prose/Prose.js +7 -0
  127. package/dist/rating/Rating.d.ts +32 -0
  128. package/dist/rating/Rating.js +27 -0
  129. package/dist/rating/messages.d.ts +6 -0
  130. package/dist/rating/messages.js +2 -0
  131. package/dist/search/Search.d.ts +11 -0
  132. package/dist/search/Search.js +9 -0
  133. package/dist/select/Select.d.ts +65 -0
  134. package/dist/select/Select.js +19 -0
  135. package/dist/select/messages.d.ts +4 -0
  136. package/dist/select/messages.js +2 -0
  137. package/dist/site-header/SiteHeader.d.ts +88 -0
  138. package/dist/site-header/SiteHeader.js +211 -0
  139. package/dist/site-header/messages.d.ts +8 -0
  140. package/dist/site-header/messages.js +2 -0
  141. package/dist/slider/Slider.d.ts +54 -0
  142. package/dist/slider/Slider.js +89 -0
  143. package/dist/slider/messages.d.ts +5 -0
  144. package/dist/slider/messages.js +2 -0
  145. package/dist/styles.css +3379 -0
  146. package/dist/switch/Switch.d.ts +47 -0
  147. package/dist/switch/Switch.js +18 -0
  148. package/dist/table/Table.d.ts +99 -0
  149. package/dist/table/Table.js +158 -0
  150. package/dist/table/messages.d.ts +23 -0
  151. package/dist/table/messages.js +2 -0
  152. package/dist/tabs/Tabs.d.ts +49 -0
  153. package/dist/tabs/Tabs.js +26 -0
  154. package/dist/tag/Tag.d.ts +37 -0
  155. package/dist/tag/Tag.js +20 -0
  156. package/dist/tag/messages.d.ts +4 -0
  157. package/dist/tag/messages.js +2 -0
  158. package/dist/text-area/TextArea.d.ts +47 -0
  159. package/dist/text-area/TextArea.js +19 -0
  160. package/dist/text-input/TextInput.d.ts +53 -0
  161. package/dist/text-input/TextInput.js +35 -0
  162. package/dist/text-input/messages.d.ts +4 -0
  163. package/dist/text-input/messages.js +3 -0
  164. package/dist/text-input/native-field.d.ts +15 -0
  165. package/dist/text-input/native-field.js +56 -0
  166. package/dist/toast/Toast.d.ts +24 -0
  167. package/dist/toast/Toast.js +79 -0
  168. package/dist/toast/messages.d.ts +4 -0
  169. package/dist/toast/messages.js +2 -0
  170. package/dist/tooltip/Tooltip.d.ts +22 -0
  171. package/dist/tooltip/Tooltip.js +92 -0
  172. package/dist/workflow/ContentState.d.ts +44 -0
  173. package/dist/workflow/ContentState.js +11 -0
  174. package/dist/workflow/Drawer.d.ts +48 -0
  175. package/dist/workflow/Drawer.js +51 -0
  176. package/dist/workflow/FileUpload.d.ts +67 -0
  177. package/dist/workflow/FileUpload.js +47 -0
  178. package/dist/workflow/Form.d.ts +52 -0
  179. package/dist/workflow/Form.js +16 -0
  180. package/dist/workflow/Wizard.d.ts +76 -0
  181. package/dist/workflow/Wizard.js +31 -0
  182. package/dist/workflow/drawer-messages.d.ts +4 -0
  183. package/dist/workflow/drawer-messages.js +2 -0
  184. package/dist/workflow/file-upload-messages.d.ts +11 -0
  185. package/dist/workflow/file-upload-messages.js +2 -0
  186. package/dist/workflow/form-messages.d.ts +5 -0
  187. package/dist/workflow/form-messages.js +2 -0
  188. package/dist/workflow/wizard-messages.d.ts +9 -0
  189. package/dist/workflow/wizard-messages.js +2 -0
  190. package/package.json +82 -7
package/CHANGELOG.md ADDED
@@ -0,0 +1,317 @@
1
+ # Changelog
2
+
3
+ All notable changes to `@idyeah/diya` are documented here. The format is based
4
+ on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project
5
+ adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
+
7
+ ## [1.0.0] - 2026-11-07
8
+
9
+ First public release, under the MIT License.
10
+
11
+ ### Added
12
+
13
+ - 30 React components and 13 patterns. `Chart` and `DataViz` are exported from
14
+ `@idyeah/diya/charts` and render with the optional `echarts` peer dependency;
15
+ everything else is exported from `@idyeah/diya`.
16
+ - `DiyaProvider` with Light, Dark and Glass appearances, brand color, font,
17
+ locale and built-in text (`messages`, `defaultMessages`).
18
+ - `@idyeah/diya/styles.css`, with public `--diya-*` theme tokens and the DIYA
19
+ Sans font (SIL Open Font License 1.1).
20
+ - `@idyeah/diya/api.json`, a machine-readable map of exports, props and tokens.
21
+ - api.json names the uncontrolled default (`defaultValue`, Switch `defaultChecked`) for every field that has one: Text Input, Text Area, Select, Combobox, Date Picker, Calendar, Choice, Switch, Slider and Search.
22
+ - Support for React 18.3 and React 19, including Next.js App Router: the root
23
+ entry has no `'use client'` directive, so `defaultMessages` and types can be
24
+ imported in Server Components, and each interactive component carries its own
25
+ directive.
26
+ - `Prose` sets your own long-form HTML (articles, docs pages, changelogs and
27
+ legal pages) in DIYA's type and rhythm, at three sizes, and leaves DIYA
28
+ components inside it as they are. `CodeBlock` shows code with a Copy button
29
+ that announces its result, and long lines scroll in a region the keyboard
30
+ can reach.
31
+ - `Stack` and `Inline` layout primitives, with `gap` on a public spacing scale
32
+ (`--diya-space-1` to `--diya-space-8`), `align`, `justify`, `wrap` and `as`.
33
+ - Every component takes `className`, `style` and its root element's other
34
+ attributes, and forwards its ref: fields to their native control, Menu,
35
+ Popover and Tooltip to the trigger, everything else to the root.
36
+ - `DiyaProvider`:
37
+ - `theme="system"`, now the default, follows the OS Light or Dark setting in
38
+ CSS, with no flash and nothing to run on the server;
39
+ - it paints its own background and text color; `surface={false}` opts out;
40
+ - `brandColor` is one brand color, or `{ light, dark }`, that sets the
41
+ accent tokens: the main Button, selected pill Tabs, an on Switch, Slider
42
+ and Progress; a colored brand also leads chart series 1, and a neutral one
43
+ leaves the charts to DIYA's Vivid palette. Text on it is white whenever that reaches
44
+ 4.5:1, otherwise near-black;
45
+ - `linkComponent` renders every `href` through your router's link, such as
46
+ Next.js `Link`;
47
+ - `useDiyaAppearance()` reports the theme in effect, Glass, the font and the
48
+ brand's accent colors.
49
+ - Links: Button takes `href` and `asChild`, TextLink takes `asChild`, and Side
50
+ Navigation, Breadcrumbs, Site Header and Menu items with an `href` are real
51
+ links (`aria-current="page"` on the current one).
52
+ - Button `variant="destructive"`, and Dialog `confirmVariant="destructive"`.
53
+ - A loading Button keeps focus: it is `aria-disabled="true"` and `aria-busy`
54
+ rather than natively disabled, and ignores clicks, Enter and Space, so a
55
+ focused Save or Send stays focused while it works and still can't submit
56
+ twice. Form's Submit, Dialog's confirm and Wizard's Continue follow.
57
+ `disabled` is still the native attribute.
58
+ - Menu and Popover take your own `trigger` element and a controlled `open`
59
+ with `onOpenChange`; Popover content can be a plain node. Dialog takes a
60
+ `trigger`. Tooltip wraps your own trigger, such as an icon-only Button.
61
+ - Forms: fields forward refs to their native controls, work uncontrolled
62
+ (`defaultValue`, `defaultChecked`) and reset with their form, and pass native
63
+ `name`, `onChange` and `onBlur` through, so react-hook-form's `register()`
64
+ works without a `Controller`. Combobox and DatePicker take `name`.
65
+ - A Choice option's `label` takes a node, not only a string: a consent box
66
+ with real Terms and Privacy Policy links (a link opens without toggling the
67
+ box), or a color swatch beside a color's name.
68
+ - Slider takes `formatValue`, such as `(value) => '$' + value`: it formats the
69
+ values and marks it shows and sets each handle's `aria-valuetext`, both
70
+ handles in range mode.
71
+ - Slider takes `min`, `max` and `step`. DatePicker takes `min` and `max`, keeps
72
+ one Tab stop in its calendar (arrows, Home/End and PageUp/PageDown move), and
73
+ starts weeks on the locale's first day.
74
+ - `Calendar`, the month grid DatePicker opens, kept on the page: for screens
75
+ like booking a time or a day's agenda. It shares DatePicker's code, keyboard,
76
+ `value` and `range` shapes, `min` and `max`, and adds a controlled `month`
77
+ (`YYYY-MM`) with `onMonthChange`. Calendar and DatePicker take
78
+ `isDateUnavailable` to mark days that can't be chosen, such as days with no
79
+ open slots. Both follow the ARIA date grid pattern: a grid named by its
80
+ month, weekday column headers, gridcells with `aria-selected` on chosen days
81
+ and `aria-current="date"` on today. Each day's name includes its weekday
82
+ ("Thursday, November 12, 2026"), and an unavailable day says so in words,
83
+ through the `unavailableDay` message.
84
+ - `headingLevel` on every pattern that renders a heading; Form's `title` is
85
+ optional.
86
+ - Pagination fits at 320 to 390px.
87
+ - DIYA's appearance: Dark sits on a near-black ground (`#111113`) with surfaces
88
+ lifted only slightly; Light is white all the way down, with hairlines,
89
+ spacing and type carrying the hierarchy. Status colors come from the Vivid
90
+ family, each label at 4.5:1 or more on its tint. In-page surfaces lift with
91
+ a soft shadow and a faint edge, and their titles are a quiet 15px.
92
+ - Glass is see-through frosted glass on every surface. Cards, chart cards,
93
+ tables (clear rows on the card's glass) and inline alerts are the clearest
94
+ pane, so the backdrop's light and shade pass visibly behind them; side
95
+ navigation, headers, controls, menus, popovers, dialogs, drawers and toasts
96
+ are denser, so text on them always reads. The material is neutral: its blur
97
+ lifts saturation by 1.15 at most, so a backdrop arrives as soft light, never
98
+ as a color wash. Each pane has a top-lit inner rim, a faint sheen across its
99
+ top and a soft shadow, deeper for floating layers. To hold 4.5:1 over what
100
+ the glass lets through, Light Glass's muted text is a step deeper, status
101
+ tags and Metric changes keep a solid base under their tint, and pagination
102
+ labels that sit on the backdrop get a soft frosted lift. Dialogs and drawers
103
+ sit over a dimming layer. `prefers-reduced-transparency` and
104
+ `prefers-contrast: more` get solid surfaces. A pill Tabs track is a capsule
105
+ like its thumb.
106
+ - `--diya-color-scrim` is set in Light and Dark (`#00000088`), not only under
107
+ Glass, so an overlay or shadow built on it works everywhere. Dialog and
108
+ Drawer share it, so a Drawer dims the page as much as a Dialog.
109
+ - Button is a pill by default; `shape="rounded"` keeps the control corner.
110
+ Pattern actions, Menu and Popover triggers and Table filters follow.
111
+ - `--diya-radius-surface`, the one corner Card, chart cards, Page Header, Form
112
+ and Table share.
113
+ - `PageHeader` takes `surface={false}` to sit straight on the page.
114
+ - Figures are tabular: Metric, Table numbers, chart data and Progress line up
115
+ digit for digit, in DIYA Sans's own 0 and 1. A positive or negative
116
+ `Metric` change shows as a tinted chip.
117
+ - `Rating`, read-only stars for products, places and reviews. The stars fill
118
+ to the nearest half of `value` (out of `max`, 5 by default); `count` adds
119
+ the number of reviews and `showValue` the rating as a number. Screen readers
120
+ hear one phrase, such as "Rated 4.3 out of 5, 128 reviews".
121
+ - `DataViz`'s `formatValue` labels the value axis too, and grid lines run
122
+ along the value axis only.
123
+ - A `List` inside a `Card` or `Drawer` lines up with its title.
124
+ - `Form`, `Card`, `Drawer`, `Dialog`, `Wizard`, `Accordion`, `Table` and
125
+ `Chatbot` style their own parts and your plain elements, never a DIYA
126
+ component placed inside them: an `Alert` in a sign-in `Form` keeps its title
127
+ color and spacing, a `Card` or `Form` in a `Drawer` or `Dialog` keeps its own
128
+ header and footer, and a `Switch` in a `Table` cell stays a switch.
129
+ - `List` items take `current`, for the open item (`aria-current="true"` and a
130
+ selected background), and `unread`: a heavier label, a dot at the row's end,
131
+ and "unread" after the label for screen readers (`messages.list.unread`).
132
+ - Side Navigation items take `count`, a quiet number after the label. Above 99
133
+ it shows `99+`; collapsed, a dot on the icon stands in for it. The item's
134
+ accessible name keeps the real count, "Inbox, 12"
135
+ (`messages.sideNavigation.count`).
136
+ - Side Navigation takes `footer`, for an account or workspace Menu pinned to
137
+ the bottom of a full-height navigation, and `collapsedFooter` for the rail
138
+ (it defaults to `footer`), following `brand` and `collapsedBrand`. A Menu,
139
+ Avatar or Button in either slot keeps its own look.
140
+ - A `layout="full-page"` Chatbot fills its container's height: the header and
141
+ composer stay put and the thread scrolls between them, following the latest
142
+ message. A height set on any Chatbot is filled the same way; without one,
143
+ the thread keeps its 280px (380px full-page).
144
+ - Chatbot `showHeader={false}` hides its header for a screen that has its own
145
+ heading; `title` still names the chat region and its message log.
146
+ - A streaming Chatbot reply replaces "Preparing a response…": the line shows
147
+ only until the reply's first words arrive. The reply gets its Copy button
148
+ once it is complete or stopped.
149
+ - A person's Chatbot message is as wide as its text, up to 90% of the thread,
150
+ in every layout.
151
+ - A tall Chatbot `welcome` stays at its top on a short screen; the thread
152
+ follows the conversation from the first message. `diya-chat-welcome-title`
153
+ styles the welcome's heading at any level, as a plain `h3` is styled.
154
+ - `npm create diya@latest` (the `create-diya` package, released with this one
155
+ on the same version) starts a Next.js or Vite app with the provider, styles
156
+ and agent notes in place, from Minimal or from Oriel, a four-screen
157
+ invoicing app.
158
+ - [Oriel](https://oriel.diya13.ai), a demo app made only from DIYA, in
159
+ `examples/oriel`.
160
+ - `bench/`: the bundle-size measurement, rerunnable with
161
+ `node bench/measure.mjs`. One Button with `DiyaProvider` adds 2.3 KB of
162
+ gzipped JavaScript to a Vite build.
163
+ - Charts use DIYA's Vivid palette (bright blue, orange, pink, green, violet,
164
+ teal, indigo, red) with a fine gradient: bars soften toward their base,
165
+ donut segments catch a highlight, and one or two lines glow into the plot.
166
+ Legend dots stay solid, and every chart keeps its data table.
167
+
168
+ ### Renamed since the preview
169
+
170
+ The 0.1.0 preview builds shipped as <code>&#64;diya/ui</code>. The
171
+ package is now `@idyeah/diya`, and the names below changed before 1.0. There
172
+ are no aliases for the old names; TypeScript reports each one.
173
+
174
+ **Values and callbacks**
175
+
176
+ - One change pattern, `value` with `onValueChange`:
177
+ - `DatePicker`: `onChange` → `onValueChange`.
178
+ - `Combobox`: `onChange` → `onValueChange`.
179
+ - `SiteHeader`: `onNavigate` → `onValueChange`, paired with its `value`.
180
+ - `Select` gains `onValueChange(value)`; the native `onChange(event)` still
181
+ works.
182
+ - `Choice`: `mode: 'single' | 'multiple'` → `multiple`. Single gives
183
+ `value: string`; `multiple` gives `value: string[]`. `selectAll` is
184
+ available only with `multiple`.
185
+ - `Combobox`: single gives `value: string` (`''` for none); `multiple` gives
186
+ `value: string[]`.
187
+ - `Slider`: single gives `value: number`; `range` gives
188
+ `value: [number, number]`.
189
+ - `DatePicker`: single gives an ISO date string (`''` for none); `range` gives
190
+ `value: DateRange` (`{ start, end }`). `label` is now required.
191
+
192
+ **Props**
193
+
194
+ | Component | Before | 1.0 |
195
+ | --- | --- | --- |
196
+ | TextInput, TextArea, Select, Search | `fieldSize` | `size` |
197
+ | Form, Wizard | `pending` | `loading` |
198
+ | Chatbot | `busy` | `loading` |
199
+ | Chatbot | `type` | `layout` (`'embedded' \| 'floating' \| 'full-page'`) |
200
+ | Chatbot | `timestamps` | `showTimestamps` |
201
+ | Toast | `onClose` | `onDismiss` |
202
+ | Toast | `dismissible` | `showClose` |
203
+ | Card, Dialog | `divider` | `divided` |
204
+ | Card | `menu` | `actions` |
205
+ | Card | `tag` | `tags` |
206
+ | Button | `shape: 'rectangle'` | `shape: 'rounded'`; the default is now `'pill'` |
207
+ | ContentState | `role: 'status' \| 'alert'` | `urgent` (`true` announces it as an alert) |
208
+ | Badge | `type` | `variant` (`'count' \| 'dot'`) |
209
+ | Badge | `maximum` | `max` |
210
+ | Badge, Tag | `color` | `tone` |
211
+ | Slider | `labels` | `showValues` |
212
+ | Slider | `marks` | `showMarks` |
213
+ | Progress | `percentage` | `showValue` |
214
+ | Progress | `type` | `variant` (`'linear' \| 'circular'`) |
215
+ | Wizard | `summary` | `showStepCount` |
216
+ | Breadcrumbs | `homeIcon` | `showHomeIcon` |
217
+ | Tabs | `variant: 'pills'` | `variant: 'pill'` |
218
+ | Switch | `description` | `helperText` (Switch also gains `error`) |
219
+ | SideNavigationItem | `id` | `value` (`SideNavigationGroup` keeps `id`) |
220
+ | Table | `selection` | `selectable` |
221
+ | Table | `filter` (`{ label, values, value }`) | `filterOptions` (`TableFilter`: `{ key, label, options, getValue }`) |
222
+
223
+ Option values are lowercase: Wizard `orientation` (`'horizontal' | 'vertical'`),
224
+ Drawer `side` (`'left' | 'right'`), and Chart and DataViz `type` and
225
+ `variant`.
226
+
227
+ **Types**
228
+
229
+ | Before | 1.0 |
230
+ | --- | --- |
231
+ | `ComboOption` | `ComboboxOption` |
232
+ | `SiteNavigationItem` | `SiteHeaderItem` |
233
+ | `DateValue` | `DateRange` |
234
+ | `BadgeColor` | `Tone`, shared by Badge, Tag, Alert and Toast (`AlertTone` is `Tone` without `'neutral'`) |
235
+
236
+ **Removed**
237
+
238
+ - Dialog: `label` (the built-in trigger) and `inline`. Pass your own
239
+ `trigger`, or control `open`.
240
+ - `brandColor` on Tag, Badge, Alert and Switch. Set it once on `DiyaProvider`.
241
+ - Table: `renderExpanded`, `onArchive`, `archiveLabel`, `onInspect` and
242
+ `inspectLabel`. Use `bulkActions` for actions on selected rows (each also
243
+ appears in a row's own menu) and `onRowOpen` (with `openLabel`) to open a
244
+ row's details.
245
+ - Table: the `filters` and `actions` switches. The filter menus show when
246
+ `filterOptions` has entries, and the row menu shows when `rowActions`,
247
+ `bulkActions` or `onRowOpen` is given.
248
+ - Choice: `descriptions`. An option's `description` shows whenever it has one.
249
+
250
+ **Defaults**
251
+
252
+ - `DiyaProvider`: `theme` is `'system'` and the provider paints its surface.
253
+ DIYA's own accent is a neutral ink: `#262626` with `#FAFAFA` text in Light,
254
+ `#E8E8E8` with `#1C1C1C` text in Dark. The grays keep a slight cool cast in
255
+ both themes.
256
+ - Switch is a native checkbox with `role="switch"`; its ref is the input.
257
+ - Search is `rounded` by default, like the other fields.
258
+ - `--diya-text-caption` is 14px (was 13px), so small print reads more easily.
259
+ - Table: row checkboxes are opt-in. They show when you pass `bulkActions`,
260
+ `onSelectionChange` or `selectedIds`, or set `selectable`. The search field
261
+ shows when `searchText` is given. Tables show 10 rows a page
262
+ (`defaultPageSize`, `pageSizeOptions`).
263
+ - Progress with no `value` is indeterminate.
264
+ - FileUpload: `multiple` defaults to `false`.
265
+ - Slider shows its label; `hideLabel` hides it visually.
266
+ - TextInput, TextArea, Select and Search put `className` and `style` on the
267
+ outer field wrapper; every other attribute goes on the control.
268
+ - A nested `DiyaProvider` inherits `locale` and `messages` from the provider
269
+ around it and overrides only what it sets.
270
+
271
+ **Tokens**
272
+
273
+ The `--library-*` custom properties are gone. The public ones were renamed:
274
+
275
+ | Before | 1.0 |
276
+ | --- | --- |
277
+ | `--library-text`, `--library-muted` | `--diya-color-text`, `--diya-color-muted` |
278
+ | `--library-surface`, `--library-recessed`, `--library-raised` | `--diya-color-surface`, `--diya-color-recessed`, `--diya-color-raised` |
279
+ | `--library-line` | `--diya-color-line` |
280
+ | `--library-active`, `--library-active-text` | `--diya-color-accent`, `--diya-color-accent-text` |
281
+ | `--library-hover`, `--library-selected` | `--diya-color-hover`, `--diya-color-selected` |
282
+ | `--library-destructive`, `--library-error` | `--diya-color-destructive`, `--diya-color-error` |
283
+ | `--library-glass` | `--diya-color-glass` |
284
+ | `--library-depth` | `--diya-shadow-raised` |
285
+ | `--diya-scrim` | `--diya-color-scrim` |
286
+ | `--library-tag-{status}-tone`, `--library-tag-{status}-surface` | `--diya-color-{status}`, `--diya-color-{status}-surface` |
287
+ | `--library-badge-{status}-fill`, `--library-badge-{status}-ink` | `--diya-color-{status}-fill`, `--diya-color-{status}-on-fill` |
288
+
289
+ New public tokens: `--diya-color-accent-soft` and `--diya-color-accent-ink`
290
+ (set by `brandColor`), `--diya-radius-control`, the corner every control
291
+ shares, and the spacing scale `--diya-space-1` to `--diya-space-8`.
292
+ `--diya-brand` is gone; use `brandColor`.
293
+
294
+ `{status}` is `success`, `warning`, `error` or `info`; the neutral badge pair
295
+ is `--diya-color-neutral-fill` and `--diya-color-neutral-on-fill`. Every other
296
+ `--library-*` property is now `--diya-internal-*`, which is private and may
297
+ change in any release. The README lists the public tokens.
298
+
299
+ **Styles**
300
+
301
+ - `styles.css` is wrapped in the `diya` cascade layer, so your own CSS and
302
+ Tailwind's utilities win over DIYA's rules. DIYA's base styles reach only
303
+ its own elements, never your markup elsewhere in the provider.
304
+ - Every class DIYA renders starts with `diya-`; for example,
305
+ `.app-pattern-surface` is `.diya-app-pattern-surface`, `.text-input-sr-only`
306
+ is `.diya-sr-only` and `.atom-description` is `.diya-switch-description`.
307
+ Class names aren't covered by semver.
308
+
309
+ **api.json**
310
+
311
+ - Item ids are their first export's name in kebab-case: `link` is
312
+ `text-link`, and `empty-state` is `content-state`. `stack` and `inline` are
313
+ new, with `kind: "layout"`.
314
+ - Chatbot and Data Viz (`DataViz`, `Chart`) are `experimental`: outside semver
315
+ until their API settles.
316
+
317
+ [1.0.0]: https://github.com/idyeah-studio/diya/releases/tag/v1.0.0
package/NOTICE ADDED
@@ -0,0 +1,29 @@
1
+ DIYA
2
+ Copyright 2026 IDYeah Studio LLC
3
+
4
+ The DIYA source code is licensed under the MIT License (see LICENSE).
5
+
6
+ Fonts
7
+ -----
8
+ DIYA Sans (src/fonts in the repository, dist/fonts in the npm package) is a
9
+ modified version of Mona Sans, licensed under the SIL Open Font License,
10
+ Version 1.1. The full licence text ships beside the font files as OFL.txt.
11
+ The MIT License does not apply to the font files.
12
+
13
+ Designer: Deni Anggara (Mona Sans); modifications IDYeah Studio
14
+ Original: Copyright 2022 The Mona Sans Project Authors
15
+ (https://github.com/github/mona-sans), with Reserved Font Name "Mona"
16
+
17
+ As the Open Font License requires, the modified font does not use the Reserved
18
+ Font Name "Mona". It is distributed as DIYA Sans and must not be sold on its own.
19
+
20
+ Third-party software
21
+ --------------------
22
+ React and React DOM are MIT-licensed peer dependencies and are not bundled.
23
+
24
+ Apache ECharts is an optional peer dependency, licensed under the Apache
25
+ License 2.0. It is used only by the @idyeah/diya/charts entry point and is not
26
+ bundled: no ECharts code is included in this repository or the npm package.
27
+
28
+ Development tools (TypeScript, Vite, Vitest, Next.js and testing helpers) keep
29
+ their own licences and are not distributed with the package.