agentic-ds-kit 0.1.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 (345) hide show
  1. package/AGENTS.md +10 -0
  2. package/CLAUDE.md +1 -0
  3. package/LICENSE +21 -0
  4. package/README.md +38 -0
  5. package/contracts/accordion.json +38 -0
  6. package/contracts/alert.json +57 -0
  7. package/contracts/alertdialog.json +89 -0
  8. package/contracts/appheader.json +140 -0
  9. package/contracts/appnav.json +72 -0
  10. package/contracts/avatar.json +63 -0
  11. package/contracts/avatargroup.json +83 -0
  12. package/contracts/badge.json +92 -0
  13. package/contracts/barchart.json +55 -0
  14. package/contracts/breadcrumb.json +76 -0
  15. package/contracts/button.json +120 -0
  16. package/contracts/buttongroup.json +48 -0
  17. package/contracts/calendar.json +93 -0
  18. package/contracts/card.json +123 -0
  19. package/contracts/carousel.json +98 -0
  20. package/contracts/cell.json +203 -0
  21. package/contracts/chat.json +131 -0
  22. package/contracts/checkbox.json +101 -0
  23. package/contracts/collapsible.json +66 -0
  24. package/contracts/command.json +84 -0
  25. package/contracts/datatable.json +126 -0
  26. package/contracts/datepicker.json +102 -0
  27. package/contracts/drawer.json +93 -0
  28. package/contracts/dropdownmenu.json +190 -0
  29. package/contracts/empty.json +79 -0
  30. package/contracts/field.json +49 -0
  31. package/contracts/fieldset.json +29 -0
  32. package/contracts/headercell.json +107 -0
  33. package/contracts/index.json +478 -0
  34. package/contracts/input.json +119 -0
  35. package/contracts/inputotp.json +119 -0
  36. package/contracts/insightcard.json +130 -0
  37. package/contracts/linechart.json +51 -0
  38. package/contracts/loadinganimation.json +33 -0
  39. package/contracts/modal.json +100 -0
  40. package/contracts/modalcard.json +88 -0
  41. package/contracts/navigationmenu.json +65 -0
  42. package/contracts/numbertransition.json +33 -0
  43. package/contracts/pageheader.json +101 -0
  44. package/contracts/pagination.json +85 -0
  45. package/contracts/patterns/activity.json +30 -0
  46. package/contracts/patterns/assistant-workspace.json +16 -0
  47. package/contracts/patterns/dashboard.json +12 -0
  48. package/contracts/patterns/empty-first-run.json +15 -0
  49. package/contracts/patterns/inbox.json +32 -0
  50. package/contracts/patterns/invite-members.json +14 -0
  51. package/contracts/patterns/list-detail.json +13 -0
  52. package/contracts/patterns/settings-form.json +13 -0
  53. package/contracts/piechart.json +68 -0
  54. package/contracts/progress.json +124 -0
  55. package/contracts/progresssteps.json +91 -0
  56. package/contracts/radiogroup.json +132 -0
  57. package/contracts/scoreboard.json +46 -0
  58. package/contracts/scorecard.json +124 -0
  59. package/contracts/section.json +97 -0
  60. package/contracts/select.json +130 -0
  61. package/contracts/shimmertext.json +33 -0
  62. package/contracts/sidenav.json +133 -0
  63. package/contracts/slider.json +81 -0
  64. package/contracts/spinner.json +52 -0
  65. package/contracts/switch.json +94 -0
  66. package/contracts/table.json +92 -0
  67. package/contracts/tabs.json +90 -0
  68. package/contracts/textarea.json +54 -0
  69. package/contracts/thinkinganimation.json +32 -0
  70. package/contracts/timeline.json +49 -0
  71. package/contracts/toast.json +104 -0
  72. package/contracts/tooltip.json +66 -0
  73. package/lib/tokens.css +637 -0
  74. package/package.json +60 -0
  75. package/skills/prototype-from-kit/SKILL.md +29 -0
  76. package/src/index.ts +71 -0
  77. package/tokens/tokens.json +725 -0
  78. package/ui/Accordion/Accordion.module.css +68 -0
  79. package/ui/Accordion/Accordion.tsx +51 -0
  80. package/ui/Accordion/Accordion.types.ts +10 -0
  81. package/ui/Accordion/index.ts +2 -0
  82. package/ui/Alert/Alert.module.css +62 -0
  83. package/ui/Alert/Alert.tsx +27 -0
  84. package/ui/Alert/Alert.types.ts +7 -0
  85. package/ui/Alert/index.ts +2 -0
  86. package/ui/AlertDialog/AlertDialog.module.css +71 -0
  87. package/ui/AlertDialog/AlertDialog.tsx +109 -0
  88. package/ui/AlertDialog/AlertDialog.types.ts +14 -0
  89. package/ui/AlertDialog/index.ts +6 -0
  90. package/ui/AppHeader/AppHeader.module.css +120 -0
  91. package/ui/AppHeader/AppHeader.tsx +70 -0
  92. package/ui/AppHeader/AppHeader.types.ts +28 -0
  93. package/ui/AppHeader/index.ts +2 -0
  94. package/ui/AppNav/AppNav.module.css +168 -0
  95. package/ui/AppNav/AppNav.tsx +137 -0
  96. package/ui/AppNav/AppNav.types.ts +24 -0
  97. package/ui/AppNav/index.ts +2 -0
  98. package/ui/Avatar/Avatar.module.css +52 -0
  99. package/ui/Avatar/Avatar.tsx +62 -0
  100. package/ui/Avatar/Avatar.types.ts +8 -0
  101. package/ui/Avatar/index.ts +2 -0
  102. package/ui/AvatarGroup/AvatarGroup.module.css +49 -0
  103. package/ui/AvatarGroup/AvatarGroup.tsx +29 -0
  104. package/ui/AvatarGroup/AvatarGroup.types.ts +16 -0
  105. package/ui/AvatarGroup/index.ts +2 -0
  106. package/ui/Badge/Badge.module.css +92 -0
  107. package/ui/Badge/Badge.tsx +43 -0
  108. package/ui/Badge/Badge.types.ts +11 -0
  109. package/ui/Badge/index.ts +2 -0
  110. package/ui/BarChart/BarChart.module.css +56 -0
  111. package/ui/BarChart/BarChart.tsx +380 -0
  112. package/ui/BarChart/BarChart.types.ts +18 -0
  113. package/ui/BarChart/index.ts +2 -0
  114. package/ui/Breadcrumb/Breadcrumb.module.css +64 -0
  115. package/ui/Breadcrumb/Breadcrumb.tsx +89 -0
  116. package/ui/Breadcrumb/Breadcrumb.types.ts +14 -0
  117. package/ui/Breadcrumb/index.ts +2 -0
  118. package/ui/Button/Button.module.css +101 -0
  119. package/ui/Button/Button.tsx +49 -0
  120. package/ui/Button/Button.types.ts +18 -0
  121. package/ui/Button/index.ts +2 -0
  122. package/ui/Button/lucideName.tsx +188 -0
  123. package/ui/ButtonGroup/ButtonGroup.module.css +31 -0
  124. package/ui/ButtonGroup/ButtonGroup.tsx +12 -0
  125. package/ui/ButtonGroup/ButtonGroup.types.ts +6 -0
  126. package/ui/ButtonGroup/index.ts +2 -0
  127. package/ui/Calendar/Calendar.module.css +146 -0
  128. package/ui/Calendar/Calendar.tsx +296 -0
  129. package/ui/Calendar/Calendar.types.ts +11 -0
  130. package/ui/Calendar/index.ts +2 -0
  131. package/ui/Card/Card.module.css +95 -0
  132. package/ui/Card/Card.tsx +69 -0
  133. package/ui/Card/Card.types.ts +23 -0
  134. package/ui/Card/index.ts +2 -0
  135. package/ui/Carousel/Carousel.module.css +114 -0
  136. package/ui/Carousel/Carousel.tsx +152 -0
  137. package/ui/Carousel/Carousel.types.ts +17 -0
  138. package/ui/Carousel/index.ts +7 -0
  139. package/ui/Cell/Cell.module.css +133 -0
  140. package/ui/Cell/Cell.tsx +300 -0
  141. package/ui/Cell/Cell.types.ts +69 -0
  142. package/ui/Cell/index.ts +11 -0
  143. package/ui/Chat/Chat.module.css +149 -0
  144. package/ui/Chat/Chat.tsx +175 -0
  145. package/ui/Chat/Chat.types.ts +39 -0
  146. package/ui/Chat/index.ts +2 -0
  147. package/ui/Checkbox/Checkbox.module.css +135 -0
  148. package/ui/Checkbox/Checkbox.tsx +70 -0
  149. package/ui/Checkbox/Checkbox.types.ts +15 -0
  150. package/ui/Checkbox/index.ts +2 -0
  151. package/ui/Collapsible/Collapsible.module.css +68 -0
  152. package/ui/Collapsible/Collapsible.tsx +59 -0
  153. package/ui/Collapsible/Collapsible.types.ts +9 -0
  154. package/ui/Collapsible/index.ts +2 -0
  155. package/ui/Command/Command.module.css +138 -0
  156. package/ui/Command/Command.tsx +152 -0
  157. package/ui/Command/Command.types.ts +20 -0
  158. package/ui/Command/index.ts +2 -0
  159. package/ui/DataTable/DataTable.module.css +211 -0
  160. package/ui/DataTable/DataTable.tsx +429 -0
  161. package/ui/DataTable/DataTable.types.ts +35 -0
  162. package/ui/DataTable/index.ts +8 -0
  163. package/ui/DatePicker/DatePicker.module.css +44 -0
  164. package/ui/DatePicker/DatePicker.tsx +123 -0
  165. package/ui/DatePicker/DatePicker.types.ts +15 -0
  166. package/ui/DatePicker/index.ts +2 -0
  167. package/ui/Drawer/Drawer.module.css +204 -0
  168. package/ui/Drawer/Drawer.tsx +112 -0
  169. package/ui/Drawer/Drawer.types.ts +14 -0
  170. package/ui/Drawer/index.ts +2 -0
  171. package/ui/DropdownMenu/DropdownMenu.module.css +319 -0
  172. package/ui/DropdownMenu/DropdownMenu.tsx +580 -0
  173. package/ui/DropdownMenu/DropdownMenu.types.ts +48 -0
  174. package/ui/DropdownMenu/index.ts +8 -0
  175. package/ui/Empty/Empty.module.css +68 -0
  176. package/ui/Empty/Empty.tsx +35 -0
  177. package/ui/Empty/Empty.types.ts +10 -0
  178. package/ui/Empty/index.ts +2 -0
  179. package/ui/Field/Field.module.css +66 -0
  180. package/ui/Field/Field.tsx +46 -0
  181. package/ui/Field/Field.types.ts +12 -0
  182. package/ui/Field/index.ts +2 -0
  183. package/ui/FieldSet/FieldSet.module.css +30 -0
  184. package/ui/FieldSet/FieldSet.tsx +14 -0
  185. package/ui/FieldSet/FieldSet.types.ts +7 -0
  186. package/ui/FieldSet/index.ts +2 -0
  187. package/ui/HeaderCell/HeaderCell.module.css +85 -0
  188. package/ui/HeaderCell/HeaderCell.tsx +71 -0
  189. package/ui/HeaderCell/HeaderCell.types.ts +18 -0
  190. package/ui/HeaderCell/index.ts +2 -0
  191. package/ui/Input/Input.module.css +59 -0
  192. package/ui/Input/Input.tsx +65 -0
  193. package/ui/Input/Input.types.ts +22 -0
  194. package/ui/Input/index.ts +2 -0
  195. package/ui/InputOTP/InputOTP.module.css +139 -0
  196. package/ui/InputOTP/InputOTP.tsx +136 -0
  197. package/ui/InputOTP/InputOTP.types.ts +19 -0
  198. package/ui/InputOTP/index.ts +2 -0
  199. package/ui/InsightCard/InsightCard.module.css +166 -0
  200. package/ui/InsightCard/InsightCard.tsx +90 -0
  201. package/ui/InsightCard/InsightCard.types.ts +20 -0
  202. package/ui/InsightCard/index.ts +7 -0
  203. package/ui/LineChart/LineChart.module.css +93 -0
  204. package/ui/LineChart/LineChart.tsx +424 -0
  205. package/ui/LineChart/LineChart.types.ts +19 -0
  206. package/ui/LineChart/index.ts +2 -0
  207. package/ui/LoadingAnimation/LoadingAnimation.module.css +66 -0
  208. package/ui/LoadingAnimation/LoadingAnimation.tsx +41 -0
  209. package/ui/LoadingAnimation/LoadingAnimation.types.ts +9 -0
  210. package/ui/LoadingAnimation/index.ts +6 -0
  211. package/ui/Modal/Modal.module.css +48 -0
  212. package/ui/Modal/Modal.tsx +114 -0
  213. package/ui/Modal/Modal.types.ts +15 -0
  214. package/ui/Modal/index.ts +2 -0
  215. package/ui/ModalCard/ModalCard.module.css +137 -0
  216. package/ui/ModalCard/ModalCard.tsx +58 -0
  217. package/ui/ModalCard/ModalCard.types.ts +15 -0
  218. package/ui/ModalCard/index.ts +2 -0
  219. package/ui/NavigationMenu/NavigationMenu.module.css +31 -0
  220. package/ui/NavigationMenu/NavigationMenu.tsx +57 -0
  221. package/ui/NavigationMenu/NavigationMenu.types.ts +22 -0
  222. package/ui/NavigationMenu/index.ts +7 -0
  223. package/ui/NumberTransition/NumberTransition.module.css +110 -0
  224. package/ui/NumberTransition/NumberTransition.tsx +78 -0
  225. package/ui/NumberTransition/NumberTransition.types.ts +9 -0
  226. package/ui/NumberTransition/index.ts +2 -0
  227. package/ui/PageHeader/PageHeader.module.css +57 -0
  228. package/ui/PageHeader/PageHeader.tsx +39 -0
  229. package/ui/PageHeader/PageHeader.types.ts +12 -0
  230. package/ui/PageHeader/index.ts +2 -0
  231. package/ui/Pagination/Pagination.module.css +19 -0
  232. package/ui/Pagination/Pagination.tsx +147 -0
  233. package/ui/Pagination/Pagination.types.ts +12 -0
  234. package/ui/Pagination/index.ts +2 -0
  235. package/ui/PieChart/PieChart.module.css +116 -0
  236. package/ui/PieChart/PieChart.tsx +293 -0
  237. package/ui/PieChart/PieChart.types.ts +22 -0
  238. package/ui/PieChart/index.ts +2 -0
  239. package/ui/Progress/Progress.module.css +226 -0
  240. package/ui/Progress/Progress.tsx +167 -0
  241. package/ui/Progress/Progress.types.ts +15 -0
  242. package/ui/Progress/index.ts +8 -0
  243. package/ui/ProgressSteps/ProgressSteps.module.css +210 -0
  244. package/ui/ProgressSteps/ProgressSteps.tsx +105 -0
  245. package/ui/ProgressSteps/ProgressSteps.types.ts +19 -0
  246. package/ui/ProgressSteps/index.ts +8 -0
  247. package/ui/RadioGroup/RadioGroup.module.css +284 -0
  248. package/ui/RadioGroup/RadioGroup.tsx +116 -0
  249. package/ui/RadioGroup/RadioGroup.types.ts +30 -0
  250. package/ui/RadioGroup/index.ts +8 -0
  251. package/ui/Scoreboard/Scoreboard.module.css +53 -0
  252. package/ui/Scoreboard/Scoreboard.tsx +41 -0
  253. package/ui/Scoreboard/Scoreboard.types.ts +7 -0
  254. package/ui/Scoreboard/index.ts +2 -0
  255. package/ui/Scorecard/Scorecard.module.css +150 -0
  256. package/ui/Scorecard/Scorecard.tsx +92 -0
  257. package/ui/Scorecard/Scorecard.types.ts +18 -0
  258. package/ui/Scorecard/index.ts +2 -0
  259. package/ui/Section/Section.module.css +104 -0
  260. package/ui/Section/Section.tsx +75 -0
  261. package/ui/Section/Section.types.ts +15 -0
  262. package/ui/Section/index.ts +2 -0
  263. package/ui/Select/Select.module.css +7 -0
  264. package/ui/Select/Select.tsx +113 -0
  265. package/ui/Select/Select.types.ts +26 -0
  266. package/ui/Select/index.ts +2 -0
  267. package/ui/ShimmerText/ShimmerText.module.css +46 -0
  268. package/ui/ShimmerText/ShimmerText.tsx +48 -0
  269. package/ui/ShimmerText/ShimmerText.types.ts +12 -0
  270. package/ui/ShimmerText/index.ts +2 -0
  271. package/ui/SideNav/SideNav.module.css +347 -0
  272. package/ui/SideNav/SideNav.tsx +222 -0
  273. package/ui/SideNav/SideNav.types.ts +42 -0
  274. package/ui/SideNav/index.ts +8 -0
  275. package/ui/Slider/Slider.module.css +105 -0
  276. package/ui/Slider/Slider.tsx +187 -0
  277. package/ui/Slider/Slider.types.ts +11 -0
  278. package/ui/Slider/index.ts +2 -0
  279. package/ui/Spinner/Spinner.module.css +58 -0
  280. package/ui/Spinner/Spinner.tsx +19 -0
  281. package/ui/Spinner/Spinner.types.ts +6 -0
  282. package/ui/Spinner/index.ts +2 -0
  283. package/ui/Switch/Switch.module.css +189 -0
  284. package/ui/Switch/Switch.tsx +65 -0
  285. package/ui/Switch/Switch.types.ts +12 -0
  286. package/ui/Switch/index.ts +2 -0
  287. package/ui/Table/Table.module.css +132 -0
  288. package/ui/Table/Table.tsx +108 -0
  289. package/ui/Table/Table.types.ts +26 -0
  290. package/ui/Table/index.ts +8 -0
  291. package/ui/Tabs/Tabs.module.css +162 -0
  292. package/ui/Tabs/Tabs.tsx +150 -0
  293. package/ui/Tabs/Tabs.types.ts +21 -0
  294. package/ui/Tabs/index.ts +2 -0
  295. package/ui/Textarea/Textarea.module.css +74 -0
  296. package/ui/Textarea/Textarea.tsx +38 -0
  297. package/ui/Textarea/Textarea.types.ts +14 -0
  298. package/ui/Textarea/index.ts +2 -0
  299. package/ui/ThinkingAnimation/ThinkingAnimation.module.css +75 -0
  300. package/ui/ThinkingAnimation/ThinkingAnimation.tsx +31 -0
  301. package/ui/ThinkingAnimation/ThinkingAnimation.types.ts +8 -0
  302. package/ui/ThinkingAnimation/index.ts +2 -0
  303. package/ui/Timeline/Timeline.module.css +99 -0
  304. package/ui/Timeline/Timeline.tsx +47 -0
  305. package/ui/Timeline/Timeline.types.ts +16 -0
  306. package/ui/Timeline/index.ts +2 -0
  307. package/ui/Toast/Toast.module.css +133 -0
  308. package/ui/Toast/Toast.tsx +89 -0
  309. package/ui/Toast/Toast.types.ts +17 -0
  310. package/ui/Toast/index.ts +2 -0
  311. package/ui/Tooltip/Tooltip.module.css +111 -0
  312. package/ui/Tooltip/Tooltip.tsx +101 -0
  313. package/ui/Tooltip/index.ts +2 -0
  314. package/ui/patterns/ActivityPattern/ActivityFeed.tsx +77 -0
  315. package/ui/patterns/ActivityPattern/ActivityPattern.tsx +120 -0
  316. package/ui/patterns/ActivityPattern/ActivityTasks.tsx +86 -0
  317. package/ui/patterns/ActivityPattern/TaskDrawer.module.css +39 -0
  318. package/ui/patterns/ActivityPattern/TaskDrawer.tsx +186 -0
  319. package/ui/patterns/ActivityPattern/index.ts +2 -0
  320. package/ui/patterns/AssistantWorkspacePattern/AssistantWorkspacePattern.module.css +16 -0
  321. package/ui/patterns/AssistantWorkspacePattern/AssistantWorkspacePattern.tsx +159 -0
  322. package/ui/patterns/AssistantWorkspacePattern/index.ts +2 -0
  323. package/ui/patterns/DashboardPattern/DashboardPattern.tsx +102 -0
  324. package/ui/patterns/DashboardPattern/index.ts +1 -0
  325. package/ui/patterns/DashboardPattern/patterns.module.css +6 -0
  326. package/ui/patterns/EmptyFirstRunPattern/EmptyFirstRunPattern.tsx +125 -0
  327. package/ui/patterns/EmptyFirstRunPattern/index.ts +2 -0
  328. package/ui/patterns/InboxPattern/InboxPattern.module.css +40 -0
  329. package/ui/patterns/InboxPattern/InboxPattern.tsx +192 -0
  330. package/ui/patterns/InboxPattern/InboxReplyDrawer.tsx +97 -0
  331. package/ui/patterns/InboxPattern/inbox-data.ts +101 -0
  332. package/ui/patterns/InboxPattern/index.ts +2 -0
  333. package/ui/patterns/InviteMembersPattern/InviteMembersPattern.tsx +148 -0
  334. package/ui/patterns/InviteMembersPattern/index.ts +2 -0
  335. package/ui/patterns/ListDetailPattern/ListDetailPattern.module.css +34 -0
  336. package/ui/patterns/ListDetailPattern/ListDetailPattern.tsx +145 -0
  337. package/ui/patterns/ListDetailPattern/index.ts +2 -0
  338. package/ui/patterns/SettingsFormPattern/SettingsFormPattern.module.css +12 -0
  339. package/ui/patterns/SettingsFormPattern/SettingsFormPattern.tsx +89 -0
  340. package/ui/patterns/SettingsFormPattern/index.ts +3 -0
  341. package/ui/shared/ChartFrame.module.css +295 -0
  342. package/ui/shared/ChartFrame.tsx +87 -0
  343. package/ui/shared/chartMath.ts +228 -0
  344. package/ui/shared/controls.module.css +48 -0
  345. package/ui/shared/useChartSize.ts +22 -0
package/AGENTS.md ADDED
@@ -0,0 +1,10 @@
1
+ # Kit rules
2
+
3
+ Before writing UI, read this package's `contracts/index.json`, then only the matching contract file(s).
4
+ If a contract exists, import the kit component from `agentic-ds-kit`. Never invent a local cousin.
5
+ If a pattern in `contracts/patterns/` matches the screen, import it from `agentic-ds-kit`.
6
+ If something is missing from the index, stop and ask — do not add a one-off.
7
+ Never put hex in components; use semantic tokens from `agentic-ds-kit/tokens.css` (not primitive `--color-*` ramps).
8
+ One `variant="primary"` Button per view.
9
+
10
+ Copy this file to your app root as `AGENTS.md` (and `CLAUDE.md` with `@AGENTS.md`) so Cursor and Claude Code load it.
package/CLAUDE.md ADDED
@@ -0,0 +1 @@
1
+ @AGENTS.md
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Boris Jovanovic
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,38 @@
1
+ # agentic-ds-kit
2
+
3
+ React components, JSON contracts, and tokens for agent-built UI. This is the **installable kit**, not the docs playground.
4
+
5
+ ## Install
6
+
7
+ ```bash
8
+ npm install agentic-ds-kit
9
+ ```
10
+
11
+ Peer: React 19. Your bundler must compile this package (it ships TypeScript and CSS modules). Next.js:
12
+
13
+ ```ts
14
+ const nextConfig = {
15
+ transpilePackages: ["agentic-ds-kit"],
16
+ };
17
+ ```
18
+
19
+ ## Use
20
+
21
+ ```tsx
22
+ import "agentic-ds-kit/tokens.css";
23
+ import { Button, Scoreboard } from "agentic-ds-kit";
24
+ ```
25
+
26
+ ```tsx
27
+ import { ActivityPattern } from "agentic-ds-kit";
28
+ ```
29
+
30
+ Contracts live in the package: `agentic-ds-kit/contracts/index.json`. Copy `AGENTS.md` (and `CLAUDE.md`) from this package into your app so Cursor and Claude Code follow the kit.
31
+
32
+ ## Tokens
33
+
34
+ `lib/tokens.css` is generated from `tokens/tokens.json`:
35
+
36
+ ```bash
37
+ npm run generate:tokens -w agentic-ds-kit
38
+ ```
@@ -0,0 +1,38 @@
1
+ {
2
+ "id": "accordion",
3
+ "status": "stable",
4
+ "intent": "One-open disclosure list for short related sections.",
5
+ "useWhen": [
6
+ "FAQ or help copy grouped under short titles",
7
+ "Settings or detail blocks the user opens one at a time"
8
+ ],
9
+ "doNotUseWhen": [
10
+ "In-page peer views — use Tabs",
11
+ "Sidebar catalog groups — use AppNav",
12
+ "A single show/hide block — use Collapsible"
13
+ ],
14
+ "props": {
15
+ "items": {
16
+ "type": "array",
17
+ "itemShape": { "id": "string", "title": "string", "content": "string" },
18
+ "required": true,
19
+ "minItems": 2
20
+ },
21
+ "defaultOpen": { "type": "string", "required": false, "note": "Item id that starts open. Omit to start all closed." }
22
+ },
23
+ "tokens": ["text.primary", "text.secondary", "surface.card", "border.faint", "icon.muted", "icon.default"],
24
+ "a11y": {
25
+ "element": "div",
26
+ "requirements": [
27
+ "Each header is a button with aria-expanded",
28
+ "Button aria-controls the matching panel",
29
+ "Closed panels are hidden from AT"
30
+ ]
31
+ },
32
+ "doNot": [
33
+ "Do not invent local Accordion or Collapse — use Collapsible for one block",
34
+ "Do not use raw hex",
35
+ "Do not open more than one item at a time"
36
+ ],
37
+ "snippet": "<Accordion items={[{ id: 'hours', title: 'Hours', content: 'Weekdays 9–5.' }, { id: 'address', title: 'Address', content: 'Knez Mihailova 1.' }]} defaultOpen=\"hours\" />"
38
+ }
@@ -0,0 +1,57 @@
1
+ {
2
+ "id": "alert",
3
+ "status": "stable",
4
+ "intent": "Inline status banner that stays on the page.",
5
+ "useWhen": [
6
+ "Page or form feedback the user should still see after it appears",
7
+ "Success, warning, or danger copy tied to the current view"
8
+ ],
9
+ "doNotUseWhen": [
10
+ "Transient confirmations that disappear — not a toast; ask before adding one",
11
+ "Compact status chips — use Badge",
12
+ "Dismissible overlay — use Modal",
13
+ "Must-choose overlay confirm — use AlertDialog",
14
+ "A dismissible insight tile — use InsightCard"
15
+ ],
16
+ "props": {
17
+ "variant": {
18
+ "type": "enum",
19
+ "values": [
20
+ "info",
21
+ "success",
22
+ "warning",
23
+ "danger"
24
+ ],
25
+ "default": "info"
26
+ },
27
+ "title": {
28
+ "type": "string",
29
+ "required": false
30
+ },
31
+ "children": {
32
+ "type": "string",
33
+ "required": true
34
+ }
35
+ },
36
+ "tokens": [
37
+ "text.primary",
38
+ "status.info",
39
+ "status.success",
40
+ "status.warning",
41
+ "status.danger"
42
+ ],
43
+ "a11y": {
44
+ "element": "div",
45
+ "requirements": [
46
+ "info and success use role=status",
47
+ "warning and danger use role=alert",
48
+ "Title and body are readable text"
49
+ ]
50
+ },
51
+ "doNot": [
52
+ "Do not invent local Alert, Banner, or Callout",
53
+ "Do not use raw hex",
54
+ "Do not use Alert for toast-style popups"
55
+ ],
56
+ "snippet": "<Alert variant=\"success\" title=\"Saved\">Your changes are live.</Alert>"
57
+ }
@@ -0,0 +1,89 @@
1
+ {
2
+ "id": "alertdialog",
3
+ "status": "stable",
4
+ "intent": "Must-choose overlay that interrupts until the user cancels or confirms.",
5
+ "useWhen": [
6
+ "Confirming a destructive or irreversible action",
7
+ "A decision that must be answered before the page continues"
8
+ ],
9
+ "doNotUseWhen": [
10
+ "Inline status on the page \u2014 use Alert",
11
+ "Dismissible short tasks or forms \u2014 use Modal",
12
+ "Passive help \u2014 use Tooltip"
13
+ ],
14
+ "props": {
15
+ "open": {
16
+ "type": "boolean",
17
+ "required": true
18
+ },
19
+ "title": {
20
+ "type": "string",
21
+ "required": true
22
+ },
23
+ "description": {
24
+ "type": "string",
25
+ "required": true
26
+ },
27
+ "cancelLabel": {
28
+ "type": "string",
29
+ "required": false,
30
+ "default": "Cancel"
31
+ },
32
+ "actionLabel": {
33
+ "type": "string",
34
+ "required": true
35
+ },
36
+ "actionVariant": {
37
+ "type": "enum",
38
+ "values": [
39
+ "primary",
40
+ "danger"
41
+ ],
42
+ "default": "primary"
43
+ },
44
+ "size": {
45
+ "type": "enum",
46
+ "values": [
47
+ "sm",
48
+ "md"
49
+ ],
50
+ "default": "md"
51
+ },
52
+ "onCancel": {
53
+ "type": "function",
54
+ "required": true
55
+ },
56
+ "onAction": {
57
+ "type": "function",
58
+ "required": true
59
+ }
60
+ },
61
+ "tokens": [
62
+ "text.primary",
63
+ "text.muted",
64
+ "surface.overlay",
65
+ "surface.elevated",
66
+ "shadow.md",
67
+ "border.faint",
68
+ "motion.overlay"
69
+ ],
70
+ "a11y": {
71
+ "element": "alertdialog",
72
+ "requirements": [
73
+ "role=alertdialog and aria-modal",
74
+ "Title is the accessible name, description is aria-describedby",
75
+ "Focus moves to Cancel when opened",
76
+ "Focus is trapped while open",
77
+ "Escape cancels",
78
+ "Overlay click does not dismiss"
79
+ ]
80
+ },
81
+ "doNot": [
82
+ "Do not invent a local confirm dialog or use window.confirm",
83
+ "Do not use raw hex",
84
+ "Do not put forms, tables, or extra actions in AlertDialog \u2014 use Modal",
85
+ "Do not add a close X or dismiss on overlay",
86
+ "Do not use more than one primary/danger action (the action button is the one)"
87
+ ],
88
+ "snippet": "<AlertDialog open={open} title=\"Delete project?\" description=\"This cannot be undone.\" actionLabel=\"Delete\" actionVariant=\"danger\" onCancel={close} onAction={remove} />"
89
+ }
@@ -0,0 +1,140 @@
1
+ {
2
+ "id": "appheader",
3
+ "status": "stable",
4
+ "intent": "Product top chrome: brand mark on the start, centered kit Input search, trailing actions. Not a page title. Not a sidebar.",
5
+ "useWhen": [
6
+ "Persistent product shell top bar with logo, global search, and utility actions",
7
+ "A full-bleed header above the page, not the page’s title block"
8
+ ],
9
+ "doNotUseWhen": [
10
+ "Page title, subtitle, Breadcrumb, or in-page actions — use PageHeader",
11
+ "Vertical sidebar catalog — use AppNav",
12
+ "Closeable product side nav — use SideNav",
13
+ "Horizontal site destinations and dropdowns — use NavigationMenu",
14
+ "Command palette overlay — use Command; AppHeader search is a kit Input"
15
+ ],
16
+ "contains": [
17
+ "input",
18
+ "button"
19
+ ],
20
+ "props": {
21
+ "title": {
22
+ "type": "string",
23
+ "required": false,
24
+ "note": "Product name next to the mark. Not an h1. Page titles belong on PageHeader."
25
+ },
26
+ "mark": {
27
+ "type": "string",
28
+ "required": false,
29
+ "note": "Brand letter. Defaults to the first character of title. Same idea as SideNav mark. Not a branded SVG."
30
+ },
31
+ "logo": {
32
+ "type": "slot",
33
+ "required": false,
34
+ "note": "Custom mark or wordmark ReactNode. Replaces the default letter mark. Consumers pass their own logo. Do not copy a file-specific brand mark into the kit."
35
+ },
36
+ "search": {
37
+ "type": "boolean",
38
+ "default": true,
39
+ "note": "Renders a centered kit Input. Hide only when the shell has no global search."
40
+ },
41
+ "searchPlaceholder": {
42
+ "type": "string",
43
+ "default": "Search"
44
+ },
45
+ "searchValue": {
46
+ "type": "string",
47
+ "required": false,
48
+ "note": "controlled. When set, pair with onSearch."
49
+ },
50
+ "defaultSearchValue": {
51
+ "type": "string",
52
+ "required": false
53
+ },
54
+ "onSearch": {
55
+ "type": "function",
56
+ "required": false,
57
+ "note": "(value: string) => void. Input onChange."
58
+ },
59
+ "searchShortcut": {
60
+ "type": "string",
61
+ "required": false,
62
+ "note": "Decorative Input end slot, e.g. ⌘K. Not a keybinding."
63
+ },
64
+ "searchId": {
65
+ "type": "string",
66
+ "required": false,
67
+ "note": "Passed to kit Input. Generated when omitted."
68
+ },
69
+ "actions": {
70
+ "type": "slot",
71
+ "allowedContracts": [
72
+ "button"
73
+ ],
74
+ "required": false,
75
+ "note": "kit Buttons. At most one primary. Do not put an assistant/Copilot CTA in the kit."
76
+ },
77
+ "className": {
78
+ "type": "string",
79
+ "required": false
80
+ },
81
+ "ariaLabel": {
82
+ "type": "string",
83
+ "required": false,
84
+ "note": "header label. Defaults to title, then Application."
85
+ },
86
+ "radius": {
87
+ "type": "enum",
88
+ "values": [
89
+ "md",
90
+ "none"
91
+ ],
92
+ "default": "none",
93
+ "note": "Bar corners. none is a flush full-bleed bar. md is radius-surface-md for an inset floating bar."
94
+ }
95
+ },
96
+ "tokens": [
97
+ "surface.card",
98
+ "text.primary",
99
+ "fill.brand",
100
+ "brand.onBrand",
101
+ "border.faint",
102
+ "border.divider",
103
+ "radius.control.md",
104
+ "radius.surfaceMd",
105
+ "radius.0",
106
+ "space.1",
107
+ "space.2",
108
+ "space.3",
109
+ "space.4",
110
+ "space.5",
111
+ "space.8",
112
+ "space.10",
113
+ "layout.rail",
114
+ "type.size.heading",
115
+ "type.size.label",
116
+ "type.weight.heading",
117
+ "type.weight.label"
118
+ ],
119
+ "a11y": {
120
+ "element": "header",
121
+ "requirements": [
122
+ "header has aria-label from ariaLabel, title, or Application",
123
+ "Search is kit Input type=search with aria-label from searchPlaceholder",
124
+ "Default letter mark is aria-hidden",
125
+ "Actions remain keyboard accessible",
126
+ "Do not use h1 — page titles belong on PageHeader"
127
+ ]
128
+ },
129
+ "doNot": [
130
+ "Do not invent TopBar, SearchBar, Logo, Masthead, or AppBar cousins",
131
+ "Do not use PageHeader for product chrome",
132
+ "Do not use AppNav, SideNav, or NavigationMenu as a top bar with search",
133
+ "Do not bake a product logo SVG into the kit — use logo or mark",
134
+ "Do not add a Copilot, assistant, or sparkle CTA",
135
+ "Do not restyle kit Input internals",
136
+ "Do not put more than one primary Button in actions",
137
+ "Do not use raw hex"
138
+ ],
139
+ "snippet": "<AppHeader title=\"Acme\" mark=\"A\" searchPlaceholder=\"Search\" searchShortcut=\"⌘K\" onSearch={setQuery} actions={<><Button variant=\"tertiary\" size=\"sm\" iconStart=\"Bell\" ariaLabel=\"Notifications\" /></>} />"
140
+ }
@@ -0,0 +1,72 @@
1
+ {
2
+ "id": "appnav",
3
+ "status": "stable",
4
+ "intent": "Vertical sidebar navigation with title, optional grouped catalog, and active item state.",
5
+ "useWhen": [
6
+ "Playground or product shells with a persistent left sidebar",
7
+ "Grouped docs/catalog IA (foundations, components, patterns)",
8
+ "List-detail layouts with a small flat list of section links"
9
+ ],
10
+ "doNotUseWhen": [
11
+ "In-page panel switching \u2014 use Tabs",
12
+ "Horizontal site nav \u2014 use NavigationMenu",
13
+ "Breadcrumb trails \u2014 not supported",
14
+ "Closeable product chrome \u2014 use SideNav",
15
+ "Product top bar with logo and search \u2014 use AppHeader"
16
+ ],
17
+ "props": {
18
+ "title": {
19
+ "type": "string",
20
+ "required": false
21
+ },
22
+ "items": {
23
+ "type": "array",
24
+ "itemShape": {
25
+ "href": "string",
26
+ "label": "string",
27
+ "active": "boolean",
28
+ "items": "optional array of leaf links (one subgroup level)"
29
+ },
30
+ "required": false,
31
+ "note": "Flat list for simple shells. Ignored when groups is provided."
32
+ },
33
+ "groups": {
34
+ "type": "array",
35
+ "itemShape": {
36
+ "label": "string",
37
+ "defaultOpen": "boolean",
38
+ "items": "array of AppNavItem"
39
+ },
40
+ "required": false,
41
+ "note": "Grouped catalog nav. Takes precedence over items when present. Groups collapse; only one is open at a time. defaultOpen sets the initial group when no leaf is active."
42
+ }
43
+ },
44
+ "precedence": "When both items and groups are passed, groups wins; items is ignored.",
45
+ "tokens": [
46
+ "text.primary",
47
+ "text.secondary",
48
+ "text.muted",
49
+ "surface.card",
50
+ "surface.muted",
51
+ "border.faint",
52
+ "action.primary"
53
+ ],
54
+ "a11y": {
55
+ "element": "nav",
56
+ "requirements": [
57
+ "nav has aria-label",
58
+ "Group labels are disclosure buttons with aria-expanded",
59
+ "Closed group lists are aria-hidden and inert",
60
+ "Active leaf uses aria-current=page",
61
+ "All leaves are keyboard-focusable links"
62
+ ]
63
+ },
64
+ "doNot": [
65
+ "Do not invent local Sidebar or AppNav",
66
+ "Do not invent Sidebar, SidebarProvider, or local nav chrome \u2014 use SideNav",
67
+ "Do not use raw hex",
68
+ "Do not use AppNav for tab panels \u2014 use Tabs",
69
+ "Do not nest more than one subgroup level"
70
+ ],
71
+ "snippet": "<AppNav title=\"Agentic DS Kit\" groups={[{ label: 'Components', items: [{ href: '/components#button', label: 'Button', active: true }] }]} />"
72
+ }
@@ -0,0 +1,63 @@
1
+ {
2
+ "id": "avatar",
3
+ "status": "stable",
4
+ "intent": "Face or initials for a person. Not a status chip and not a button.",
5
+ "useWhen": [
6
+ "user menus",
7
+ "table assignee",
8
+ "comment authors",
9
+ "profile headers"
10
+ ],
11
+ "doNotUseWhen": [
12
+ "status or category chips — use Badge",
13
+ "actions — use Button",
14
+ "logos/brands — ask first"
15
+ ],
16
+ "props": {
17
+ "name": {
18
+ "type": "string",
19
+ "required": true
20
+ },
21
+ "src": {
22
+ "type": "string",
23
+ "required": false
24
+ },
25
+ "initials": {
26
+ "type": "string",
27
+ "required": false
28
+ },
29
+ "size": {
30
+ "type": "enum",
31
+ "values": [
32
+ "sm",
33
+ "md",
34
+ "lg"
35
+ ],
36
+ "default": "md"
37
+ }
38
+ },
39
+ "tokens": [
40
+ "surface.muted",
41
+ "text.primary",
42
+ "radius.full",
43
+ "space.8",
44
+ "space.10",
45
+ "space.12"
46
+ ],
47
+ "a11y": {
48
+ "element": "span",
49
+ "requirements": [
50
+ "when image shows, img alt=name",
51
+ "when fallback, role=img and aria-label=name",
52
+ "Decorative User icon is aria-hidden"
53
+ ]
54
+ },
55
+ "doNot": [
56
+ "do not invent local Avatar",
57
+ "do not use raw hex",
58
+ "do not make Avatar clickable without a new contract",
59
+ "do not add AvatarGroup or a status badge on Avatar in this contract",
60
+ "do not use Badge for people"
61
+ ],
62
+ "snippet": "<Avatar name=\"Boris Jovanovic\" src=\"/faces/boris.jpg\" size=\"md\" />"
63
+ }
@@ -0,0 +1,83 @@
1
+ {
2
+ "id": "avatargroup",
3
+ "status": "stable",
4
+ "intent": "Overlapping row of kit Avatars with an optional leftover count.",
5
+ "useWhen": [
6
+ "several people on a row, card, or table cell"
7
+ ],
8
+ "doNotUseWhen": [
9
+ "one person — use Avatar",
10
+ "status chips — use Badge",
11
+ "actions — use Button"
12
+ ],
13
+ "contains": [
14
+ "avatar"
15
+ ],
16
+ "props": {
17
+ "items": {
18
+ "type": "array",
19
+ "required": true,
20
+ "minItems": 2,
21
+ "itemShape": {
22
+ "name": {
23
+ "type": "string",
24
+ "required": true
25
+ },
26
+ "src": {
27
+ "type": "string",
28
+ "required": false
29
+ },
30
+ "initials": {
31
+ "type": "string",
32
+ "required": false
33
+ }
34
+ }
35
+ },
36
+ "size": {
37
+ "type": "enum",
38
+ "values": [
39
+ "sm",
40
+ "md",
41
+ "lg"
42
+ ],
43
+ "default": "md"
44
+ },
45
+ "max": {
46
+ "type": "number",
47
+ "default": 3,
48
+ "note": "how many Avatars to show before +N. If items.length <= max, no count."
49
+ },
50
+ "ariaLabel": {
51
+ "type": "string",
52
+ "required": false,
53
+ "note": "names the group, e.g. Assignees"
54
+ }
55
+ },
56
+ "tokens": [
57
+ "surface.muted",
58
+ "text.secondary",
59
+ "surface.page",
60
+ "radius.full",
61
+ "space.px",
62
+ "space.2",
63
+ "space.8",
64
+ "space.10",
65
+ "space.12"
66
+ ],
67
+ "a11y": {
68
+ "element": "div",
69
+ "requirements": [
70
+ "role=group",
71
+ "optional aria-label names the group",
72
+ "leftover count uses aria-label like \"3 more\""
73
+ ]
74
+ },
75
+ "doNot": [
76
+ "Do not invent a local avatar stack",
77
+ "Do not wrap non-Avatar content",
78
+ "Do not use raw hex",
79
+ "Do not put a status badge on faces",
80
+ "Do not make the group a button"
81
+ ],
82
+ "snippet": "<AvatarGroup size=\"md\" max={3} ariaLabel=\"Assignees\" items={[{ name: \"Boris Jovanovic\" }, { name: \"Ada Jones\" }, { name: \"Mira\" }, { name: \"Leo\" }]} />"
83
+ }