@usefragments/ui 1.6.0 → 1.7.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 (457) hide show
  1. package/README.md +4 -4
  2. package/dist/assets/fragments-wordmark.cjs +2 -2
  3. package/dist/assets/fragments-wordmark.d.ts.map +1 -1
  4. package/dist/assets/fragments-wordmark.js +2 -2
  5. package/dist/assets/ui.css +4720 -4159
  6. package/dist/chart.cjs +24 -6
  7. package/dist/chart.js +24 -6
  8. package/dist/codeblock.cjs +55 -29
  9. package/dist/codeblock.js +55 -29
  10. package/dist/colorpicker.cjs +3 -1
  11. package/dist/colorpicker.js +3 -1
  12. package/dist/components/Accordion/Accordion.module.scss.cjs +8 -8
  13. package/dist/components/Accordion/Accordion.module.scss.js +8 -8
  14. package/dist/components/Alert/Alert.module.scss.cjs +15 -12
  15. package/dist/components/Alert/Alert.module.scss.js +15 -12
  16. package/dist/components/Alert/index.cjs +7 -1
  17. package/dist/components/Alert/index.d.ts +12 -6
  18. package/dist/components/Alert/index.d.ts.map +1 -1
  19. package/dist/components/Alert/index.js +7 -1
  20. package/dist/components/AppShell/AppShell.module.scss.cjs +14 -14
  21. package/dist/components/AppShell/AppShell.module.scss.js +14 -14
  22. package/dist/components/Avatar/Avatar.module.scss.cjs +14 -14
  23. package/dist/components/Avatar/Avatar.module.scss.js +14 -14
  24. package/dist/components/Badge/Badge.module.scss.cjs +19 -19
  25. package/dist/components/Badge/Badge.module.scss.js +19 -19
  26. package/dist/components/BentoGrid/BentoGrid.module.scss.cjs +14 -14
  27. package/dist/components/BentoGrid/BentoGrid.module.scss.js +14 -14
  28. package/dist/components/Box/Box.module.scss.cjs +152 -152
  29. package/dist/components/Box/Box.module.scss.js +152 -152
  30. package/dist/components/Box/index.cjs +64 -75
  31. package/dist/components/Box/index.d.ts +16 -16
  32. package/dist/components/Box/index.d.ts.map +1 -1
  33. package/dist/components/Box/index.js +64 -75
  34. package/dist/components/Breadcrumbs/Breadcrumbs.module.scss.cjs +8 -8
  35. package/dist/components/Breadcrumbs/Breadcrumbs.module.scss.js +8 -8
  36. package/dist/components/Button/Button.module.scss.cjs +14 -14
  37. package/dist/components/Button/Button.module.scss.js +14 -14
  38. package/dist/components/Card/Card.module.scss.cjs +29 -17
  39. package/dist/components/Card/Card.module.scss.js +30 -18
  40. package/dist/components/Card/index.cjs +8 -0
  41. package/dist/components/Card/index.d.ts +12 -2
  42. package/dist/components/Card/index.d.ts.map +1 -1
  43. package/dist/components/Card/index.js +8 -0
  44. package/dist/components/Chart/Chart.module.scss.cjs +15 -15
  45. package/dist/components/Chart/Chart.module.scss.js +15 -15
  46. package/dist/components/Chart/index.d.ts.map +1 -1
  47. package/dist/components/Checkbox/Checkbox.module.scss.cjs +9 -9
  48. package/dist/components/Checkbox/Checkbox.module.scss.js +9 -9
  49. package/dist/components/Checkbox/index.cjs +2 -2
  50. package/dist/components/Checkbox/index.d.ts.map +1 -1
  51. package/dist/components/Checkbox/index.js +2 -2
  52. package/dist/components/Chip/Chip.module.scss.cjs +15 -15
  53. package/dist/components/Chip/Chip.module.scss.js +15 -15
  54. package/dist/components/Chip/index.cjs +2 -1
  55. package/dist/components/Chip/index.d.ts.map +1 -1
  56. package/dist/components/Chip/index.js +2 -1
  57. package/dist/components/CodeBlock/CodeBlock.module.scss.cjs +26 -23
  58. package/dist/components/CodeBlock/CodeBlock.module.scss.js +26 -23
  59. package/dist/components/CodeBlock/css-variables-theme.cjs +98 -0
  60. package/dist/components/CodeBlock/css-variables-theme.d.ts +27 -0
  61. package/dist/components/CodeBlock/css-variables-theme.d.ts.map +1 -0
  62. package/dist/components/CodeBlock/css-variables-theme.js +98 -0
  63. package/dist/components/CodeBlock/index.d.ts +17 -3
  64. package/dist/components/CodeBlock/index.d.ts.map +1 -1
  65. package/dist/components/Collapsible/Collapsible.module.scss.cjs +9 -9
  66. package/dist/components/Collapsible/Collapsible.module.scss.js +9 -9
  67. package/dist/components/ColorPicker/ColorPicker.module.scss.cjs +14 -14
  68. package/dist/components/ColorPicker/ColorPicker.module.scss.js +14 -14
  69. package/dist/components/ColorPicker/index.d.ts.map +1 -1
  70. package/dist/components/Combobox/Combobox.module.scss.cjs +21 -21
  71. package/dist/components/Combobox/Combobox.module.scss.js +21 -21
  72. package/dist/components/Combobox/index.cjs +17 -1
  73. package/dist/components/Combobox/index.d.ts.map +1 -1
  74. package/dist/components/Combobox/index.js +17 -1
  75. package/dist/components/Command/Command.module.scss.cjs +11 -11
  76. package/dist/components/Command/Command.module.scss.js +11 -11
  77. package/dist/components/Command/index.cjs +26 -15
  78. package/dist/components/Command/index.d.ts +2 -2
  79. package/dist/components/Command/index.d.ts.map +1 -1
  80. package/dist/components/Command/index.js +26 -15
  81. package/dist/components/ConversationList/ConversationList.module.scss.cjs +10 -10
  82. package/dist/components/ConversationList/ConversationList.module.scss.js +10 -10
  83. package/dist/components/DataTable/DataTable.icons.cjs +6 -33
  84. package/dist/components/DataTable/DataTable.icons.d.ts.map +1 -1
  85. package/dist/components/DataTable/DataTable.icons.js +6 -33
  86. package/dist/components/DataTable/DataTable.module.scss.cjs +27 -27
  87. package/dist/components/DataTable/DataTable.module.scss.js +27 -27
  88. package/dist/components/DataTable/index.d.ts.map +1 -1
  89. package/dist/components/DatePicker/DatePicker.module.scss.cjs +33 -33
  90. package/dist/components/DatePicker/DatePicker.module.scss.js +33 -33
  91. package/dist/components/DatePicker/index.d.ts.map +1 -1
  92. package/dist/components/Dialog/Dialog.module.scss.cjs +14 -14
  93. package/dist/components/Dialog/Dialog.module.scss.js +14 -14
  94. package/dist/components/Dialog/index.cjs +11 -14
  95. package/dist/components/Dialog/index.d.ts +7 -7
  96. package/dist/components/Dialog/index.d.ts.map +1 -1
  97. package/dist/components/Dialog/index.js +11 -14
  98. package/dist/components/Drawer/Drawer.module.scss.cjs +29 -29
  99. package/dist/components/Drawer/Drawer.module.scss.js +29 -29
  100. package/dist/components/Editor/Editor.module.scss.cjs +17 -17
  101. package/dist/components/Editor/Editor.module.scss.js +17 -17
  102. package/dist/components/Editor/index.d.ts +10 -10
  103. package/dist/components/Editor/index.d.ts.map +1 -1
  104. package/dist/components/EmptyState/EmptyState.module.scss.cjs +11 -8
  105. package/dist/components/EmptyState/EmptyState.module.scss.js +11 -8
  106. package/dist/components/EmptyState/index.cjs +8 -6
  107. package/dist/components/EmptyState/index.d.ts +9 -4
  108. package/dist/components/EmptyState/index.d.ts.map +1 -1
  109. package/dist/components/EmptyState/index.js +8 -6
  110. package/dist/components/Field/Field.module.scss.cjs +5 -5
  111. package/dist/components/Field/Field.module.scss.js +5 -5
  112. package/dist/components/Field/index.cjs +9 -1
  113. package/dist/components/Field/index.d.ts.map +1 -1
  114. package/dist/components/Field/index.js +9 -1
  115. package/dist/components/Fieldset/Fieldset.module.scss.cjs +3 -3
  116. package/dist/components/Fieldset/Fieldset.module.scss.js +3 -3
  117. package/dist/components/Grid/index.cjs +1 -1
  118. package/dist/components/Grid/index.js +1 -1
  119. package/dist/components/Header/Header.module.scss.cjs +33 -33
  120. package/dist/components/Header/Header.module.scss.js +33 -33
  121. package/dist/components/Header/index.cjs +17 -38
  122. package/dist/components/Header/index.d.ts +15 -11
  123. package/dist/components/Header/index.d.ts.map +1 -1
  124. package/dist/components/Header/index.js +17 -38
  125. package/dist/components/Icon/Icon.module.scss.cjs +15 -15
  126. package/dist/components/Icon/Icon.module.scss.js +15 -15
  127. package/dist/components/IconButton/IconButton.module.scss.cjs +8 -8
  128. package/dist/components/IconButton/IconButton.module.scss.js +8 -8
  129. package/dist/components/IconButton/index.cjs +2 -1
  130. package/dist/components/IconButton/index.d.ts.map +1 -1
  131. package/dist/components/IconButton/index.js +2 -1
  132. package/dist/components/Image/Image.module.scss.cjs +27 -27
  133. package/dist/components/Image/Image.module.scss.js +27 -27
  134. package/dist/components/Input/Input.module.scss.cjs +17 -17
  135. package/dist/components/Input/Input.module.scss.js +17 -17
  136. package/dist/components/Link/Link.module.scss.cjs +14 -10
  137. package/dist/components/Link/Link.module.scss.js +14 -10
  138. package/dist/components/Link/index.d.ts +1 -1
  139. package/dist/components/Link/index.d.ts.map +1 -1
  140. package/dist/components/List/List.module.scss.cjs +19 -19
  141. package/dist/components/List/List.module.scss.js +19 -19
  142. package/dist/components/Listbox/Listbox.module.scss.cjs +8 -8
  143. package/dist/components/Listbox/Listbox.module.scss.js +8 -8
  144. package/dist/components/Loading/Loading.module.scss.cjs +34 -34
  145. package/dist/components/Loading/Loading.module.scss.js +34 -34
  146. package/dist/components/Loading/index.cjs +1 -1
  147. package/dist/components/Loading/index.js +1 -1
  148. package/dist/components/Markdown/Markdown.module.scss.cjs +1 -1
  149. package/dist/components/Markdown/Markdown.module.scss.js +1 -1
  150. package/dist/components/Markdown/index.d.ts +2 -2
  151. package/dist/components/Markdown/index.d.ts.map +1 -1
  152. package/dist/components/Menu/Menu.module.scss.cjs +14 -14
  153. package/dist/components/Menu/Menu.module.scss.js +14 -14
  154. package/dist/components/Message/Message.module.scss.cjs +18 -18
  155. package/dist/components/Message/Message.module.scss.js +18 -18
  156. package/dist/components/NavigationMenu/NavigationMenu.module.scss.cjs +34 -31
  157. package/dist/components/NavigationMenu/NavigationMenu.module.scss.js +34 -31
  158. package/dist/components/NavigationMenu/index.cjs +32 -15
  159. package/dist/components/NavigationMenu/index.d.ts +12 -6
  160. package/dist/components/NavigationMenu/index.d.ts.map +1 -1
  161. package/dist/components/NavigationMenu/index.js +32 -15
  162. package/dist/components/Pagination/Pagination.module.scss.cjs +10 -10
  163. package/dist/components/Pagination/Pagination.module.scss.js +10 -10
  164. package/dist/components/Popover/Popover.module.scss.cjs +10 -10
  165. package/dist/components/Popover/Popover.module.scss.js +10 -10
  166. package/dist/components/Progress/Progress.module.scss.cjs +25 -25
  167. package/dist/components/Progress/Progress.module.scss.js +25 -25
  168. package/dist/components/Prompt/Prompt.module.scss.cjs +28 -28
  169. package/dist/components/Prompt/Prompt.module.scss.js +28 -28
  170. package/dist/components/RadioGroup/RadioGroup.module.scss.cjs +15 -15
  171. package/dist/components/RadioGroup/RadioGroup.module.scss.js +15 -15
  172. package/dist/components/ScrollArea/ScrollArea.module.scss.cjs +5 -5
  173. package/dist/components/ScrollArea/ScrollArea.module.scss.js +5 -5
  174. package/dist/components/ScrollArea/index.d.ts +4 -4
  175. package/dist/components/ScrollArea/index.d.ts.map +1 -1
  176. package/dist/components/ScrollArea/scroll-state.d.ts +5 -5
  177. package/dist/components/Select/Select.module.scss.cjs +21 -21
  178. package/dist/components/Select/Select.module.scss.js +21 -21
  179. package/dist/components/Separator/Separator.module.scss.cjs +11 -11
  180. package/dist/components/Separator/Separator.module.scss.js +11 -11
  181. package/dist/components/Sidebar/Sidebar.module.scss.cjs +43 -43
  182. package/dist/components/Sidebar/Sidebar.module.scss.js +43 -43
  183. package/dist/components/Sidebar/index.cjs +12 -35
  184. package/dist/components/Sidebar/index.d.ts +19 -19
  185. package/dist/components/Sidebar/index.d.ts.map +1 -1
  186. package/dist/components/Sidebar/index.js +12 -35
  187. package/dist/components/Skeleton/Skeleton.module.scss.cjs +50 -46
  188. package/dist/components/Skeleton/Skeleton.module.scss.js +50 -46
  189. package/dist/components/Slider/Slider.module.scss.cjs +12 -12
  190. package/dist/components/Slider/Slider.module.scss.js +12 -12
  191. package/dist/components/Stack/Stack.module.scss.cjs +25 -25
  192. package/dist/components/Stack/Stack.module.scss.js +25 -25
  193. package/dist/components/Stack/index.cjs +1 -1
  194. package/dist/components/Stack/index.js +1 -1
  195. package/dist/components/Switch/Switch.module.scss.cjs +9 -9
  196. package/dist/components/Switch/Switch.module.scss.js +9 -9
  197. package/dist/components/Table/Table.module.scss.cjs +19 -19
  198. package/dist/components/Table/Table.module.scss.js +19 -19
  199. package/dist/components/TableOfContents/TableOfContents.module.scss.cjs +15 -15
  200. package/dist/components/TableOfContents/TableOfContents.module.scss.js +15 -15
  201. package/dist/components/TableOfContents/index.cjs +13 -9
  202. package/dist/components/TableOfContents/index.d.ts +5 -3
  203. package/dist/components/TableOfContents/index.d.ts.map +1 -1
  204. package/dist/components/TableOfContents/index.js +13 -9
  205. package/dist/components/Tabs/Tabs.module.scss.cjs +12 -12
  206. package/dist/components/Tabs/Tabs.module.scss.js +12 -12
  207. package/dist/components/Tabs/index.cjs +26 -6
  208. package/dist/components/Tabs/index.d.ts.map +1 -1
  209. package/dist/components/Tabs/index.js +26 -6
  210. package/dist/components/Text/Text.module.scss.cjs +87 -75
  211. package/dist/components/Text/Text.module.scss.js +87 -75
  212. package/dist/components/Text/index.cjs +49 -41
  213. package/dist/components/Text/index.d.ts +12 -11
  214. package/dist/components/Text/index.d.ts.map +1 -1
  215. package/dist/components/Text/index.js +49 -41
  216. package/dist/components/Textarea/Textarea.module.scss.cjs +24 -24
  217. package/dist/components/Textarea/Textarea.module.scss.js +24 -24
  218. package/dist/components/Theme/index.cjs +2 -1
  219. package/dist/components/Theme/index.d.ts.map +1 -1
  220. package/dist/components/Theme/index.js +2 -1
  221. package/dist/components/ThemeToggle/ThemeToggle.module.scss.cjs +9 -6
  222. package/dist/components/ThemeToggle/ThemeToggle.module.scss.js +9 -6
  223. package/dist/components/ThemeToggle/index.cjs +31 -6
  224. package/dist/components/ThemeToggle/index.d.ts +7 -2
  225. package/dist/components/ThemeToggle/index.d.ts.map +1 -1
  226. package/dist/components/ThemeToggle/index.js +32 -7
  227. package/dist/components/ThinkingIndicator/ThinkingIndicator.module.scss.cjs +13 -13
  228. package/dist/components/ThinkingIndicator/ThinkingIndicator.module.scss.js +13 -13
  229. package/dist/components/Toast/Toast.module.scss.cjs +20 -20
  230. package/dist/components/Toast/Toast.module.scss.js +20 -20
  231. package/dist/components/ToggleGroup/ToggleGroup.module.scss.cjs +17 -17
  232. package/dist/components/ToggleGroup/ToggleGroup.module.scss.js +17 -17
  233. package/dist/components/Tooltip/Tooltip.module.scss.cjs +3 -3
  234. package/dist/components/Tooltip/Tooltip.module.scss.js +3 -3
  235. package/dist/components/Tooltip/index.cjs +24 -40
  236. package/dist/components/Tooltip/index.d.ts +4 -4
  237. package/dist/components/Tooltip/index.d.ts.map +1 -1
  238. package/dist/components/Tooltip/index.js +24 -40
  239. package/dist/components/VisuallyHidden/index.d.ts +2 -2
  240. package/dist/data-table.cjs +2 -1
  241. package/dist/data-table.js +2 -1
  242. package/dist/datepicker.cjs +3 -2
  243. package/dist/datepicker.js +3 -2
  244. package/dist/editor.cjs +68 -28
  245. package/dist/editor.js +68 -28
  246. package/dist/index.cjs +1 -1
  247. package/dist/index.d.ts +1 -1
  248. package/dist/index.d.ts.map +1 -1
  249. package/dist/index.js +2 -2
  250. package/dist/markdown.cjs +21 -29
  251. package/dist/markdown.js +21 -29
  252. package/dist/measurements/generated.cjs +9 -1
  253. package/dist/measurements/generated.d.ts +7 -0
  254. package/dist/measurements/generated.d.ts.map +1 -1
  255. package/dist/measurements/generated.js +9 -1
  256. package/dist/utils/a11y.cjs +5 -2
  257. package/dist/utils/a11y.d.ts +5 -5
  258. package/dist/utils/a11y.d.ts.map +1 -1
  259. package/dist/utils/a11y.js +5 -2
  260. package/dist/utils/canonical-stamp.cjs +2 -8
  261. package/dist/utils/canonical-stamp.d.ts.map +1 -1
  262. package/dist/utils/canonical-stamp.js +1 -7
  263. package/dist/utils/css-warning.cjs +1 -1
  264. package/dist/utils/css-warning.js +1 -1
  265. package/dist/utils/env.cjs +17 -0
  266. package/dist/utils/env.d.ts +3 -0
  267. package/dist/utils/env.d.ts.map +1 -0
  268. package/dist/utils/env.js +17 -0
  269. package/dist/utils/keyboard-shortcuts.cjs +3 -10
  270. package/dist/utils/keyboard-shortcuts.d.ts +4 -4
  271. package/dist/utils/keyboard-shortcuts.d.ts.map +1 -1
  272. package/dist/utils/keyboard-shortcuts.js +3 -10
  273. package/dist/utils/seed-derivation.cjs +10 -6
  274. package/dist/utils/seed-derivation.d.ts.map +1 -1
  275. package/dist/utils/seed-derivation.js +10 -6
  276. package/fragments.json +1 -1
  277. package/package.json +6 -4
  278. package/src/assets/fragments-logo.tsx +2 -2
  279. package/src/assets/fragments-wordmark.tsx +4 -2
  280. package/src/components/Accordion/Accordion.contract.json +24 -48
  281. package/src/components/Alert/Alert.contract.json +37 -53
  282. package/src/components/Alert/Alert.module.scss +24 -0
  283. package/src/components/Alert/index.tsx +55 -29
  284. package/src/components/AppShell/AppShell.contract.json +34 -51
  285. package/src/components/AppShell/AppShell.module.scss +53 -40
  286. package/src/components/Avatar/Avatar.contract.json +31 -48
  287. package/src/components/Avatar/Avatar.module.scss +4 -1
  288. package/src/components/Badge/Badge.contract.json +37 -42
  289. package/src/components/Badge/Badge.module.scss +9 -2
  290. package/src/components/BentoGrid/BentoGrid.contract.json +21 -45
  291. package/src/components/Box/Box.contract.json +40 -148
  292. package/src/components/Box/index.tsx +92 -99
  293. package/src/components/Breadcrumbs/Breadcrumbs.contract.json +21 -34
  294. package/src/components/Breadcrumbs/Breadcrumbs.module.scss +12 -7
  295. package/src/components/Button/Button.module.scss +8 -7
  296. package/src/components/ButtonGroup/ButtonGroup.contract.json +32 -47
  297. package/src/components/Card/Card.module.scss +82 -1
  298. package/src/components/Card/index.tsx +21 -2
  299. package/src/components/Chart/Chart.contract.json +21 -29
  300. package/src/components/Chart/index.tsx +36 -6
  301. package/src/components/Checkbox/Checkbox.contract.json +24 -24
  302. package/src/components/Checkbox/Checkbox.module.scss +32 -23
  303. package/src/components/Checkbox/index.tsx +4 -2
  304. package/src/components/Chip/Chip.contract.json +33 -40
  305. package/src/components/Chip/Chip.module.scss +2 -2
  306. package/src/components/Chip/index.tsx +2 -1
  307. package/src/components/CodeBlock/CodeBlock.contract.json +46 -76
  308. package/src/components/CodeBlock/CodeBlock.module.scss +40 -15
  309. package/src/components/CodeBlock/css-variables-theme.ts +102 -0
  310. package/src/components/CodeBlock/index.tsx +91 -35
  311. package/src/components/Collapsible/Collapsible.contract.json +21 -36
  312. package/src/components/ColorPicker/ColorPicker.contract.json +29 -48
  313. package/src/components/ColorPicker/ColorPicker.module.scss +15 -12
  314. package/src/components/ColorPicker/index.tsx +5 -1
  315. package/src/components/Combobox/Combobox.contract.json +36 -37
  316. package/src/components/Combobox/Combobox.module.scss +1 -1
  317. package/src/components/Combobox/index.tsx +31 -5
  318. package/src/components/Command/Command.contract.json +21 -43
  319. package/src/components/Command/index.tsx +58 -47
  320. package/src/components/ConversationList/ConversationList.contract.json +27 -32
  321. package/src/components/DataTable/DataTable.icons.tsx +4 -21
  322. package/src/components/DataTable/DataTable.module.scss +12 -8
  323. package/src/components/DataTable/index.tsx +8 -7
  324. package/src/components/DatePicker/DatePicker.contract.json +27 -28
  325. package/src/components/DatePicker/DatePicker.module.scss +12 -5
  326. package/src/components/DatePicker/index.tsx +5 -2
  327. package/src/components/Dialog/Dialog.module.scss +3 -3
  328. package/src/components/Dialog/index.tsx +47 -37
  329. package/src/components/Drawer/Drawer.contract.json +22 -36
  330. package/src/components/Editor/Editor.contract.json +31 -48
  331. package/src/components/Editor/Editor.module.scss +36 -14
  332. package/src/components/Editor/index.tsx +240 -179
  333. package/src/components/EmptyState/EmptyState.contract.json +31 -43
  334. package/src/components/EmptyState/EmptyState.module.scss +8 -0
  335. package/src/components/EmptyState/index.tsx +48 -23
  336. package/src/components/Field/Field.contract.json +28 -46
  337. package/src/components/Field/index.tsx +5 -1
  338. package/src/components/Fieldset/Fieldset.contract.json +21 -38
  339. package/src/components/Fieldset/Fieldset.module.scss +10 -3
  340. package/src/components/Form/Form.contract.json +20 -20
  341. package/src/components/Grid/Grid.contract.json +28 -64
  342. package/src/components/Grid/index.tsx +10 -10
  343. package/src/components/Header/Header.contract.json +31 -67
  344. package/src/components/Header/Header.module.scss +36 -21
  345. package/src/components/Header/index.tsx +134 -122
  346. package/src/components/Icon/Icon.contract.json +22 -62
  347. package/src/components/IconButton/IconButton.contract.json +34 -18
  348. package/src/components/IconButton/IconButton.module.scss +6 -7
  349. package/src/components/IconButton/index.tsx +2 -1
  350. package/src/components/Image/Image.contract.json +23 -56
  351. package/src/components/Input/Input.contract.json +26 -32
  352. package/src/components/Input/Input.module.scss +3 -2
  353. package/src/components/Link/Link.contract.json +32 -52
  354. package/src/components/Link/Link.module.scss +23 -6
  355. package/src/components/Link/index.tsx +1 -1
  356. package/src/components/List/List.contract.json +23 -52
  357. package/src/components/List/List.module.scss +1 -1
  358. package/src/components/Listbox/Listbox.contract.json +21 -37
  359. package/src/components/Loading/Loading.contract.json +37 -61
  360. package/src/components/Loading/Loading.module.scss +10 -7
  361. package/src/components/Loading/index.tsx +2 -2
  362. package/src/components/Main/Main.contract.json +17 -9
  363. package/src/components/Markdown/Markdown.contract.json +22 -43
  364. package/src/components/Markdown/Markdown.module.scss +43 -5
  365. package/src/components/Markdown/index.tsx +48 -49
  366. package/src/components/Menu/Menu.contract.json +25 -41
  367. package/src/components/Menu/Menu.module.scss +23 -8
  368. package/src/components/Message/Message.contract.json +29 -52
  369. package/src/components/Message/Message.module.scss +12 -5
  370. package/src/components/NavigationMenu/NavigationMenu.contract.json +36 -45
  371. package/src/components/NavigationMenu/NavigationMenu.module.scss +64 -19
  372. package/src/components/NavigationMenu/index.tsx +105 -81
  373. package/src/components/Pagination/Pagination.contract.json +22 -40
  374. package/src/components/Pagination/Pagination.module.scss +2 -2
  375. package/src/components/Popover/Popover.contract.json +24 -46
  376. package/src/components/Popover/Popover.module.scss +6 -5
  377. package/src/components/Progress/Progress.contract.json +32 -28
  378. package/src/components/Progress/Progress.module.scss +3 -2
  379. package/src/components/Prompt/Prompt.contract.json +31 -47
  380. package/src/components/Prompt/Prompt.module.scss +13 -5
  381. package/src/components/RadioGroup/RadioGroup.contract.json +23 -24
  382. package/src/components/RadioGroup/RadioGroup.module.scss +13 -14
  383. package/src/components/ScrollArea/ScrollArea.contract.json +18 -19
  384. package/src/components/ScrollArea/ScrollArea.module.scss +15 -15
  385. package/src/components/ScrollArea/index.tsx +16 -16
  386. package/src/components/ScrollArea/scroll-state.ts +24 -24
  387. package/src/components/Select/Select.module.scss +2 -2
  388. package/src/components/Separator/Separator.contract.json +24 -48
  389. package/src/components/Sidebar/Sidebar.contract.json +35 -67
  390. package/src/components/Sidebar/Sidebar.module.scss +22 -13
  391. package/src/components/Sidebar/index.tsx +164 -164
  392. package/src/components/Skeleton/Skeleton.contract.json +28 -54
  393. package/src/components/Skeleton/Skeleton.module.scss +27 -10
  394. package/src/components/Slider/Slider.contract.json +27 -39
  395. package/src/components/Slider/Slider.module.scss +3 -3
  396. package/src/components/Stack/Stack.contract.json +29 -56
  397. package/src/components/Stack/Stack.module.scss +13 -12
  398. package/src/components/Stack/index.tsx +3 -3
  399. package/src/components/Switch/Switch.contract.json +33 -46
  400. package/src/components/Switch/Switch.module.scss +64 -26
  401. package/src/components/Table/Table.contract.json +28 -46
  402. package/src/components/Table/Table.module.scss +15 -3
  403. package/src/components/TableOfContents/TableOfContents.contract.json +34 -21
  404. package/src/components/TableOfContents/TableOfContents.module.scss +15 -5
  405. package/src/components/TableOfContents/index.tsx +26 -9
  406. package/src/components/Tabs/Tabs.contract.json +24 -45
  407. package/src/components/Tabs/Tabs.module.scss +1 -1
  408. package/src/components/Tabs/index.tsx +15 -3
  409. package/src/components/Text/Text.contract.json +30 -72
  410. package/src/components/Text/Text.module.scss +21 -4
  411. package/src/components/Text/index.tsx +113 -75
  412. package/src/components/Textarea/Textarea.contract.json +25 -43
  413. package/src/components/Textarea/Textarea.module.scss +2 -4
  414. package/src/components/Theme/Theme.contract.json +32 -51
  415. package/src/components/Theme/index.tsx +2 -1
  416. package/src/components/ThemeToggle/ThemeToggle.module.scss +23 -7
  417. package/src/components/ThemeToggle/index.tsx +43 -7
  418. package/src/components/ThinkingIndicator/ThinkingIndicator.contract.json +23 -40
  419. package/src/components/Toast/Toast.contract.json +30 -40
  420. package/src/components/Toast/Toast.module.scss +1 -1
  421. package/src/components/ToggleGroup/ToggleGroup.contract.json +29 -30
  422. package/src/components/ToggleGroup/ToggleGroup.module.scss +38 -5
  423. package/src/components/Tooltip/Tooltip.contract.json +31 -52
  424. package/src/components/Tooltip/index.tsx +19 -24
  425. package/src/components/VisuallyHidden/VisuallyHidden.contract.json +22 -44
  426. package/src/components/VisuallyHidden/index.tsx +5 -5
  427. package/src/index.ts +2 -2
  428. package/src/measurements/generated.ts +9 -2
  429. package/src/measurements/measurements.json +7 -0
  430. package/src/recipes/_boolean-range.scss +3 -11
  431. package/src/recipes/_field.scss +5 -1
  432. package/src/recipes/_layout.scss +14 -7
  433. package/src/recipes/_popup.scss +12 -2
  434. package/src/recipes/_prose.scss +13 -5
  435. package/src/recipes/_table-chrome.scss +16 -2
  436. package/src/scss.d.ts +1 -1
  437. package/src/styles/globals.scss +20 -19
  438. package/src/tokens/_computed.scss +5 -16
  439. package/src/tokens/_derive.scss +112 -210
  440. package/src/tokens/_measurements.catalog.generated.css +6 -1
  441. package/src/tokens/_measurements.generated.scss +14 -1
  442. package/src/tokens/_mixins.scss +7 -8
  443. package/src/tokens/_palettes.scss +39 -167
  444. package/src/tokens/_seeds.scss +20 -20
  445. package/src/tokens/_variables.scss +183 -38
  446. package/src/utils/a11y.tsx +69 -69
  447. package/src/utils/aria.ts +3 -3
  448. package/src/utils/canonical-stamp.ts +2 -12
  449. package/src/utils/css-warning.ts +7 -7
  450. package/src/utils/env.ts +25 -0
  451. package/src/utils/keyboard-shortcuts.ts +131 -126
  452. package/src/utils/seed-derivation.ts +10 -6
  453. package/src/components/Button/Button.contract.json +0 -218
  454. package/src/components/Card/Card.contract.json +0 -175
  455. package/src/components/DataTable/DataTable.contract.json +0 -302
  456. package/src/components/Dialog/Dialog.contract.json +0 -159
  457. package/src/components/Select/Select.contract.json +0 -259
@@ -9,8 +9,13 @@
9
9
  --fui-table-cell-inline-inset-regular: var(--fui-raw-space-12, #{measurements.raw-space(12)});
10
10
  --fui-table-cell-inline-inset-relaxed: var(--fui-raw-space-16, #{measurements.raw-space(16)});
11
11
  --fui-table-cell-block-inset-compact: var(--fui-raw-space-4, #{measurements.raw-space(4)});
12
- --fui-table-cell-block-inset-regular: var(--fui-raw-space-8, #{measurements.raw-space(8)});
12
+ --fui-table-cell-block-inset-regular: var(--fui-raw-space-10, #{measurements.raw-space(10)});
13
13
  --fui-table-cell-block-inset-relaxed: var(--fui-raw-space-12, #{measurements.raw-space(12)});
14
+ // The header sits tighter than the rows it labels: a column head is chrome,
15
+ // not a record, so it keeps the pre-ledger inset while cells breathe.
16
+ --fui-table-header-block-inset-compact: var(--fui-raw-space-4, #{measurements.raw-space(4)});
17
+ --fui-table-header-block-inset-regular: var(--fui-raw-space-8, #{measurements.raw-space(8)});
18
+ --fui-table-header-block-inset-relaxed: var(--fui-raw-space-12, #{measurements.raw-space(12)});
14
19
  --fui-table-tree-indent-step: var(--fui-raw-space-24, #{measurements.raw-space(24)});
15
20
  --fui-table-divider-size: var(
16
21
  --fui-stroke-hairline,
@@ -42,6 +47,14 @@
42
47
  @error "Unknown table density '#{$density}'. Expected compact, regular, or relaxed.";
43
48
  }
44
49
 
50
+ @function header-block-inset($density) {
51
+ @if $density == "compact" or $density == "regular" or $density == "relaxed" {
52
+ @return var(--fui-table-header-block-inset-#{$density});
53
+ }
54
+
55
+ @error "Unknown table density '#{$density}'. Expected compact, regular, or relaxed.";
56
+ }
57
+
45
58
  @mixin density($density) {
46
59
  @if $density != "compact" and $density != "regular" and $density != "relaxed" {
47
60
  @error "Unknown table density '#{$density}'. Expected compact, regular, or relaxed.";
@@ -50,6 +63,7 @@
50
63
  --_fui-table-row-track: #{row-track($density)};
51
64
  --_fui-table-cell-inline-inset: #{cell-inline-inset($density)};
52
65
  --_fui-table-cell-block-inset: #{cell-block-inset($density)};
66
+ --_fui-table-header-block-inset: #{header-block-inset($density)};
53
67
 
54
68
  @if $density == "compact" {
55
69
  @include typography.role("ui-compact");
@@ -78,7 +92,7 @@
78
92
  @mixin header-cell {
79
93
  @include typography.role("ui-compact");
80
94
 
81
- padding-block: var(--_fui-table-cell-block-inset);
95
+ padding-block: var(--_fui-table-header-block-inset, var(--_fui-table-cell-block-inset));
82
96
  padding-inline: var(--_fui-table-cell-inline-inset);
83
97
  color: var(--fui-text-secondary);
84
98
  text-align: start;
package/src/scss.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- declare module '*.module.scss' {
1
+ declare module "*.module.scss" {
2
2
  const classes: { [key: string]: string };
3
3
  export default classes;
4
4
  }
@@ -7,7 +7,6 @@
7
7
  // Usage in SCSS (recommended):
8
8
  // @use '@usefragments/ui/styles' with (
9
9
  // $fui-brand: #6366f1,
10
- // $fui-neutral: "earth",
11
10
  // $fui-radius-style: "rounded"
12
11
  // );
13
12
  //
@@ -24,17 +23,16 @@
24
23
  // Consumers set these via @use ... with().
25
24
  // Values are forwarded to the seed/token chain below.
26
25
 
27
- $fui-brand: #006b57 !default;
28
- $fui-neutral: "carbon" !default;
26
+ $fui-brand: #f56138 !default;
27
+ $fui-neutral: "paper" !default;
29
28
  $fui-density: "default" !default;
30
29
  $fui-radius-style: "default" !default;
31
- // Status seeds tuned to sit in one family with the sage brand (see
32
- // tokens/_seeds.scss): danger is sage's warm complement, warning its
33
- // split-complement, info a cool teal-adjacent slate — all muted to match.
34
- $fui-danger: #a54f46 !default;
35
- $fui-success: #7fc9b3 !default;
36
- $fui-warning: #e0aa5c !default;
37
- $fui-info: #7fa6c4 !default;
30
+ // Status seeds (see tokens/_seeds.scss): Cloud Surfaces rust / forest /
31
+ // amber / slate-blue. Washes derive from these.
32
+ $fui-danger: #c44732 !default;
33
+ $fui-success: #2c8c5f !default;
34
+ $fui-warning: #c4922a !default;
35
+ $fui-info: #3d7aa8 !default;
38
36
 
39
37
  // Configure seeds BEFORE loading variables.
40
38
  // Sass module singleton: once configured here, every subsequent
@@ -98,7 +96,7 @@ $fui-info: #7fa6c4 !default;
98
96
  font-size: inherit;
99
97
  font-family: var(
100
98
  --fui-font-sans,
101
- Inter,
99
+ "Onest",
102
100
  system-ui,
103
101
  -apple-system,
104
102
  BlinkMacSystemFont,
@@ -126,21 +124,24 @@ $fui-info: #7fa6c4 !default;
126
124
  color: inherit;
127
125
  }
128
126
 
127
+ // Classless prose anchors take the link ink (≥ 4.5:1 on every surface in
128
+ // both themes); the accent stays for actions. Hover strengthens the rule.
129
129
  :where(a:not([class]):not([style])) {
130
- color: var(--fui-color-accent, #{$fui-color-accent});
130
+ color: var(--fui-link-ink, #{$fui-link-ink});
131
131
  text-decoration: underline;
132
- text-underline-offset: 2px;
133
- transition: color 0.15s ease;
132
+ text-decoration-color: color-mix(in srgb, currentColor 55%, transparent);
133
+ text-underline-offset: 0.2em;
134
+ transition: text-decoration-color 0.15s ease;
134
135
 
135
136
  &:hover {
136
- color: var(--fui-color-accent-hover, #{$fui-color-accent-hover});
137
+ text-decoration-color: currentColor;
137
138
  }
138
139
  }
139
140
 
140
141
  ::selection {
141
142
  background-color: var(
142
143
  --fui-selection-bg,
143
- color-mix(in srgb, var(--fui-color-accent, #7fc9b3) 18%, transparent)
144
+ color-mix(in srgb, var(--fui-color-accent, #f56138) 18%, transparent)
144
145
  );
145
146
  color: var(--fui-selection-color, var(--fui-text-primary, #171717));
146
147
  }
@@ -200,11 +201,11 @@ $fui-info: #7fa6c4 !default;
200
201
  }
201
202
 
202
203
  :where(:focus-visible) {
203
- outline: 1px solid color-mix(in srgb, var(--fui-focus-ring-color, #006b57) 24%, transparent);
204
+ outline: 1px solid color-mix(in srgb, var(--fui-focus-ring-color, #f56138) 24%, transparent);
204
205
  outline-offset: var(--fui-focus-ring-offset, 2px);
205
206
  box-shadow:
206
207
  0 0 0 calc(var(--fui-focus-ring-width, 2px) + 1px)
207
- color-mix(in srgb, var(--fui-focus-ring-color, #006b57) 10%, transparent),
208
- 0 10px 24px -16px color-mix(in srgb, var(--fui-focus-ring-color, #006b57) 18%, transparent);
208
+ color-mix(in srgb, var(--fui-focus-ring-color, #f56138) 10%, transparent),
209
+ 0 10px 24px -16px color-mix(in srgb, var(--fui-focus-ring-color, #f56138) 18%, transparent);
209
210
  }
210
211
  }
@@ -27,10 +27,10 @@ $_radius: radius.get-radius-style(seeds.$fui-radius-style);
27
27
  // Derive spacing from density
28
28
  $_spacing: density.derive-spacing($_density);
29
29
 
30
- // True when the brand seed is the Fragments default (pine). Lets the default
31
- // theme emit exact Flight Recorder accents (sage dark / pine light) while any
32
- // consumer-supplied $fui-brand keeps the full seed→accent derivation.
33
- $brand-is-fragments-default: seeds.$fui-brand == #006b57;
30
+ // True when the brand seed is the Fragments default (coral). The default
31
+ // theme uses the exact SCSS-computed accents; any consumer-supplied
32
+ // $fui-brand keeps the full seed→accent derivation reactive at runtime.
33
+ $brand-is-fragments-default: seeds.$fui-brand == #f56138;
34
34
 
35
35
  // --------------------------------------------
36
36
  // Computed: Base Configuration
@@ -95,9 +95,6 @@ $computed-color-accent: seeds.$fui-brand;
95
95
  // Default (pine) fill needs white text; contrast-color mis-scores mid-dark
96
96
  // brands, so pin on-accent to white for the Fragments default.
97
97
  $computed-color-on-accent: derive.contrast-color(seeds.$fui-brand);
98
- @if $brand-is-fragments-default {
99
- $computed-color-on-accent: #ffffff;
100
- }
101
98
  $computed-color-accent-hover: derive.derive-accent-hover(seeds.$fui-brand, false);
102
99
  $computed-color-accent-active: derive.derive-accent-active(seeds.$fui-brand, false);
103
100
 
@@ -171,11 +168,7 @@ $computed-backdrop: derive.derive-backdrop(false);
171
168
  // --------------------------------------------
172
169
 
173
170
  // Accent colors — dark brands lightened for visibility; on-accent handles text contrast.
174
- // The Fragments default resolves to exact sage; overrides keep the chroma-aware lift.
175
171
  $computed-dark-color-accent: derive.derive-dark-accent(seeds.$fui-brand);
176
- @if $brand-is-fragments-default {
177
- $computed-dark-color-accent: #7fc9b3;
178
- }
179
172
  $computed-dark-color-on-accent: derive.contrast-color($computed-dark-color-accent);
180
173
  $computed-dark-color-accent-hover: derive.derive-accent-hover($computed-dark-color-accent, true);
181
174
  $computed-dark-color-accent-active: derive.derive-accent-active($computed-dark-color-accent, true);
@@ -226,12 +219,8 @@ $computed-dark-shadow-sm: map.get($_shadows-dark, sm);
226
219
  $computed-dark-shadow-md: map.get($_shadows-dark, md);
227
220
  $computed-dark-shadow-lg: map.get($_shadows-dark, lg);
228
221
 
229
- // Focus ring (dark mode) — follows the dark accent. Pinned to sage for the
230
- // Fragments default (derive-focus-ring mis-scores the mid-dark pine brand).
222
+ // Focus ring (dark mode) — follows the dark accent.
231
223
  $computed-dark-focus-ring-color: derive.derive-focus-ring(seeds.$fui-brand, true);
232
- @if $brand-is-fragments-default {
233
- $computed-dark-focus-ring-color: #7fc9b3;
234
- }
235
224
 
236
225
  // Scrollbar (dark mode)
237
226
  $_scrollbar-dark: derive.derive-scrollbar($_palette, true, seeds.$fui-neutral);
@@ -8,9 +8,9 @@
8
8
  //
9
9
  // ============================================
10
10
 
11
- @use 'sass:color';
12
- @use 'sass:math';
13
- @use 'palettes' as *;
11
+ @use "sass:color";
12
+ @use "sass:math";
13
+ @use "palettes" as *;
14
14
 
15
15
  // --------------------------------------------
16
16
  // Color Utility Functions
@@ -21,7 +21,7 @@
21
21
  /// @return {Boolean} True if dark
22
22
  @function is-dark-color($color) {
23
23
  // oklch lightness is perceptually uniform (0-1 range)
24
- @return color.channel($color, 'lightness', $space: oklch) < 0.5;
24
+ @return color.channel($color, "lightness", $space: oklch) < 0.5;
25
25
  }
26
26
 
27
27
  /// Get appropriate contrast color (black or white)
@@ -46,7 +46,7 @@
46
46
  /// @param {Boolean} $is-dark - Whether in dark mode
47
47
  /// @return {Color} Hover state color
48
48
  @function derive-accent-hover($base, $is-dark: false) {
49
- $l: color.channel($base, 'lightness', $space: oklch);
49
+ $l: color.channel($base, "lightness", $space: oklch);
50
50
 
51
51
  @if $is-dark {
52
52
  @if $l > 0.85 {
@@ -72,7 +72,7 @@
72
72
  /// @param {Boolean} $is-dark - Whether in dark mode
73
73
  /// @return {Color} Active state color
74
74
  @function derive-accent-active($base, $is-dark: false) {
75
- $l: color.channel($base, 'lightness', $space: oklch);
75
+ $l: color.channel($base, "lightness", $space: oklch);
76
76
 
77
77
  @if $is-dark {
78
78
  @if $l > 0.85 {
@@ -102,8 +102,8 @@
102
102
  /// @param {Color} $brand - Brand color
103
103
  /// @return {Color} Dark-mode accent
104
104
  @function derive-dark-accent($brand) {
105
- $l: color.channel($brand, 'lightness', $space: oklch);
106
- $c: color.channel($brand, 'chroma', $space: oklch);
105
+ $l: color.channel($brand, "lightness", $space: oklch);
106
+ $c: color.channel($brand, "chroma", $space: oklch);
107
107
  // color.channel returns lightness as a percentage; normalize to a unitless 0–1
108
108
  // ratio so the comparisons below share a scale with the 0.55/0.85 bounds.
109
109
  $l-num: $l;
@@ -113,7 +113,7 @@
113
113
  // grey-lift only kicks in for low-chroma brands; vibrant brands keep their own L.
114
114
  $target-l: math.max($l-num, 0.95 - 2 * $c);
115
115
  $clamped-l: math.max(0.55, math.min($target-l, 0.85));
116
- @return oklch($clamped-l $c color.channel($brand, 'hue', $space: oklch));
116
+ @return oklch($clamped-l $c color.channel($brand, "hue", $space: oklch));
117
117
  }
118
118
 
119
119
  // --------------------------------------------
@@ -146,185 +146,103 @@
146
146
  // Surface/Background Derivation
147
147
  // --------------------------------------------
148
148
 
149
- /// Derive surface/background tokens from a neutral palette
149
+ /// Derive surface/background tokens for the paper ramp.
150
150
  /// Maps shade levels to semantic surface tokens for visual depth layering.
151
- /// For colorful palettes (ice, earth, sand, fire), light mode uses tinted backgrounds.
152
151
  /// @param {Map} $palette - Neutral palette map
153
152
  /// @param {Boolean} $is-dark - Whether in dark mode
154
- /// @param {String} $palette-name - Palette name for colorful detection (default: 'stone')
155
153
  /// @return {Map} Surface token values
156
- @function derive-surfaces($palette, $is-dark: false, $palette-name: 'stone') {
154
+ @function derive-surfaces($palette, $is-dark: false, $palette-name: "paper") {
157
155
  @if $is-dark {
158
- // Carbon (Fragments default) charcoal material surfaces, not voids.
159
- @if $palette-name == 'carbon' {
160
- @return (
161
- primary: #212121, // page / body background
162
- secondary: #171717, // sidebar, recessed panels, surface
163
- tertiary: #2f2f2f, // raised / hover / active row (surface-2)
164
- elevated: #2f2f2f, // cards float above the page tone
165
- subtle: #171717, // recessed (code wells, insets)
166
- hover: rgba(255, 255, 255, 0.055),
167
- active: rgba(255, 255, 255, 0.085)
168
- );
169
- }
170
-
171
- @if $palette-name == 'stone' or $palette-name == 'mono' {
172
- @return (
173
- primary: #000000,
174
- secondary: #050505,
175
- tertiary: #111111,
176
- elevated: #151515,
177
- subtle: #080808,
178
- hover: rgba(255, 255, 255, 0.055),
179
- active: rgba(255, 255, 255, 0.085)
180
- );
181
- }
182
-
183
- // Dark mode: darker = more recessed, lighter = elevated
184
- // Hover/active opacities tuned for subdued dense-UI aesthetic: hairlines and
185
- // alpha overlays do most of the depth work rather than heavy color shifts.
156
+ // The cream canvas moved onto a warm charcoal plane with a real elevation
157
+ // ladder: bands step up from the page, cards step up from bands — the
158
+ // dark mirror of canvas / tinted band / white card in light mode.
186
159
  @return (
187
- primary: get-shade($palette, 950), // Page background (darkest)
188
- secondary: get-shade($palette, 900), // Sidebar, panels
189
- tertiary: get-shade($palette, 800), // Content areas (lighter)
190
- elevated: interpolate-shade($palette, 875), // Cards (distinct from secondary)
191
- subtle: interpolate-shade($palette, 925), // Between primary and secondary
192
- hover: rgba(255, 255, 255, 0.035), // Interactive hover
193
- active: rgba(255, 255, 255, 0.06) // Interactive active
160
+ primary: #171614,
161
+ // page background
162
+ secondary: #171614,
163
+ // shell/sidebar on the same plane
164
+ tertiary: #1e1c19,
165
+ // tinted section band, raised chrome
166
+ elevated: #262421,
167
+ // cards and overlays float clearly above bands
168
+ subtle: #1b1a17,
169
+ // barely-raised wells
170
+ hover: #2a2723,
171
+ // transient interaction
172
+ active: #322e29 // transient pressed interaction
194
173
  );
195
174
  }
196
175
 
197
- // Light mode: colorful palettes get tinted backgrounds. Carbon is a neutral
198
- // (like stone) white surfaces in light mode.
199
- $is-colorful: $palette-name != 'stone' and $palette-name != 'carbon';
200
- @if $is-colorful {
201
- @return (
202
- primary: get-shade($palette, 50), // Tinted page background
203
- secondary: get-shade($palette, 100), // Tinted secondary panels
204
- tertiary: get-shade($palette, 200), // Deeper tint for nested sections
205
- elevated: #ffffff, // Cards, modals (floats above)
206
- subtle: get-shade($palette, 50), // Very subtle tinted background
207
- hover: rgba(0, 0, 0, 0.04), // Interactive hover
208
- active: rgba(0, 0, 0, 0.06) // Interactive active
209
- );
210
- }
211
-
212
- // Stone palette: neutral white backgrounds
176
+ // Light mode the warm gallery scheme: a cream page canvas, white cards
177
+ // floating above it, and a deeper cream band for nested sections.
178
+ // Hover/active are warm alpha tints so interaction chrome never goes cold
179
+ // grey on the warm canvas.
213
180
  @return (
214
- primary: #ffffff, // Page background (white)
215
- secondary: get-shade($palette, 100), // Sidebar, secondary panels
216
- tertiary: get-shade($palette, 100), // Nested sections
217
- elevated: #ffffff, // Cards, modals (floats above)
218
- subtle: get-shade($palette, 50), // Very subtle backgrounds
219
- hover: rgba(0, 0, 0, 0.04), // Interactive hover
220
- active: rgba(0, 0, 0, 0.06) // Interactive active
181
+ primary: #faf8f5,
182
+ // page canvas (cream)
183
+ secondary: #faf8f5,
184
+ // shell/sidebar on the same plane
185
+ tertiary: #f2ede7,
186
+ // tinted section band, hover-on-paper
187
+ elevated: #ffffff,
188
+ // cards and overlays float white
189
+ subtle: #fdfcfa,
190
+ // barely-raised wells
191
+ hover: rgba(96, 48, 16, 0.06),
192
+ // warm transient interaction
193
+ active: rgba(96, 48, 16, 0.1) // warm pressed interaction
221
194
  );
222
195
  }
223
196
 
224
197
  /// Derive document/application canvas tokens used by base body styles and
225
- /// large layout containers. The defaults intentionally separate the page
226
- /// canvas from the primary main surface so app shells can expose chrome around
227
- /// the focused content region.
198
+ /// large layout containers. Body and main share the paper canvas so app
199
+ /// shells sit on one plane; raised component roles provide the contrast.
228
200
  /// @param {Map} $palette - Neutral palette map
229
201
  /// @param {Boolean} $is-dark - Whether in dark mode
230
- /// @param {String} $palette-name - Palette name for colorful detection
231
202
  /// @return {Map} Body and main background values
232
- @function derive-app-surfaces($palette, $is-dark: false, $palette-name: 'stone') {
203
+ @function derive-app-surfaces($palette, $is-dark: false, $palette-name: "paper") {
233
204
  @if $is-dark {
234
- // Carbon (Fragments default) flat page canvas at #212121.
235
- @if $palette-name == 'carbon' {
236
- @return (
237
- body: #212121,
238
- main: #212121
239
- );
240
- }
241
-
242
- @if $palette-name == 'stone' or $palette-name == 'mono' or $palette-name == 'wind' {
243
- @return (
244
- body: #000000,
245
- main: #050505
246
- );
247
- }
248
-
249
- @return (
250
- body: get-shade($palette, 800),
251
- main: get-shade($palette, 900)
252
- );
205
+ @return (body: #171614, main: #171614);
253
206
  }
254
-
255
- @if $palette-name == 'stone' or $palette-name == 'carbon' or $palette-name == 'wind' {
256
- @return (
257
- body: get-shade($palette, 100),
258
- main: #ffffff
259
- );
260
- }
261
-
262
- @return (
263
- body: get-shade($palette, 100),
264
- main: get-shade($palette, 50)
265
- );
207
+ @return (body: #faf8f5, main: #faf8f5);
266
208
  }
267
209
 
268
210
  // --------------------------------------------
269
211
  // Text Color Derivation
270
212
  // --------------------------------------------
271
213
 
272
- /// Derive text tokens from a neutral palette.
273
- /// For colorful palettes in light mode, applies ensure-contrast() to meet
274
- /// WCAG AAA (7:1) against tinted backgrounds (palette[50]).
214
+ /// Derive text tokens for the paper ramp.
215
+ /// Light mode applies ensure-contrast() to meet WCAG AAA (7:1) against the
216
+ /// cream canvas; dark mode uses warm ink tiers so text keeps the scheme's
217
+ /// warmth instead of snapping to pure white.
275
218
  /// @param {Map} $palette - Neutral palette map
276
219
  /// @param {Boolean} $is-dark - Whether in dark mode
277
- /// @param {String} $palette-name - Palette name for background detection (default: 'stone')
278
220
  /// @return {Map} Text token values
279
- @function derive-text($palette, $is-dark: false, $palette-name: 'stone') {
221
+ @function derive-text($palette, $is-dark: false, $palette-name: "paper") {
280
222
  @if $is-dark {
281
- // Carbon (Fragments default) — ink / muted / faint text tiers.
282
- @if $palette-name == 'carbon' {
283
- @return (
284
- primary: #ececec, // ink
285
- secondary: #b4b4b4, // muted
286
- tertiary: #8f8f8f, // faint / placeholder
287
- inverse: #212121 // text on light (sage) accents
288
- );
289
- }
290
-
291
- @if $palette-name == 'stone' or $palette-name == 'mono' {
292
- @return (
293
- primary: #ededed,
294
- secondary: #a1a1a1,
295
- tertiary: #7a7a7a,
296
- inverse: #000000
297
- );
298
- }
299
-
300
- // Dark mode: neutral white text on all palettes.
301
- // Palette-tinted text (e.g. green-on-green-dark) looks muddy and reduces
302
- // readability. Major polished dark themes use neutral white text regardless
303
- // of background tint.
304
- // Opacity ladder tuned for a subdued, product-chrome aesthetic — secondary
305
- // and tertiary are lifted closer to primary so dense UI reads cleanly
306
- // without needing to bump to primary for every chrome label.
307
223
  @return (
308
- primary: #ffffff,
309
- secondary: rgba(255, 255, 255, 0.72),
310
- tertiary: rgba(255, 255, 255, 0.5),
311
- inverse: get-shade($palette, 900) // Text on light accents
224
+ primary: #f0ede9,
225
+ // warm ink
226
+ secondary: #b6b0a8,
227
+ // muted
228
+ tertiary: #8d8780,
229
+ // faint / placeholder
230
+ inverse: #171614 // text on light (cream) accents
312
231
  );
313
232
  }
314
233
 
315
- // Light mode background — stone/carbon use white, colorful palettes use palette[50]
316
- $bg: #ffffff;
317
- @if $palette-name != 'stone' and $palette-name != 'carbon' {
318
- $bg: get-shade($palette, 50);
319
- }
234
+ $bg: get-shade($palette, 50);
320
235
 
321
236
  @return (
322
- primary: get-shade($palette, 900), // Main text (high contrast)
237
+ primary: get-shade($palette, 900),
238
+ // Main text (high contrast)
323
239
  secondary: ensure-contrast(get-shade($palette, 600), $bg, 7),
324
240
  tertiary: ensure-contrast(
325
- color.mix(get-shade($palette, 600), get-shade($palette, 500), 20%), $bg, 7
326
- ),
327
- inverse: get-shade($palette, 100) // Text on dark accents
241
+ color.mix(get-shade($palette, 600), get-shade($palette, 500), 20%),
242
+ $bg,
243
+ 7
244
+ ),
245
+ inverse: get-shade($palette, 100) // Text on dark accents
328
246
  );
329
247
  }
330
248
 
@@ -332,41 +250,22 @@
332
250
  // Border Color Derivation
333
251
  // --------------------------------------------
334
252
 
335
- /// Derive border tokens from a neutral palette
253
+ /// Derive border tokens for the paper ramp
336
254
  /// @param {Map} $palette - Neutral palette map
337
255
  /// @param {Boolean} $is-dark - Whether in dark mode
338
256
  /// @return {Map} Border token values
339
- @function derive-borders($palette, $is-dark: false, $palette-name: 'stone') {
257
+ @function derive-borders($palette, $is-dark: false, $palette-name: "paper") {
340
258
  @if $is-dark {
341
- // Carbon (Fragments default) — solid hairline + strong border.
342
- @if $palette-name == 'carbon' {
343
- @return (
344
- default: #323232, // hairline
345
- strong: #4b4b4b // strong border
346
- );
347
- }
348
-
349
- @if $palette-name == 'stone' or $palette-name == 'mono' {
350
- @return (
351
- default: rgba(255, 255, 255, 0.075),
352
- strong: rgba(255, 255, 255, 0.14)
353
- );
354
- }
355
-
356
- // Dark mode: subtle white-alpha hairlines. Tight opacities keep panel
357
- // edges barely-there so borders define structure without adding visual
358
- // weight — matches the dense dashboard aesthetic.
259
+ // Solid warm hairline + strong border on the charcoal plane.
359
260
  @return (
360
- default: rgba(255, 255, 255, 0.055),
361
- strong: rgba(255, 255, 255, 0.085)
362
- );
363
- } @else {
364
- // Light mode: reduced opacity (ChatGPT --border-light ~5%)
365
- @return (
366
- default: rgba(0, 0, 0, 0.05),
367
- strong: rgba(0, 0, 0, 0.10)
261
+ default: #343029,
262
+ // hairline
263
+ strong: #4a4641 // strong border
368
264
  );
369
265
  }
266
+ // Warm-tinted hairlines so edges on the cream canvas never read as cold
267
+ // grey lines cutting through a warm scheme.
268
+ @return (default: rgba(60, 45, 30, 0.1), strong: rgba(60, 45, 30, 0.18));
370
269
  }
371
270
 
372
271
  // --------------------------------------------
@@ -381,17 +280,33 @@
381
280
  // Dark mode: near-zero shadows — hairlines and alpha overlays carry
382
281
  // elevation instead, matching dense product-chrome aesthetics.
383
282
  @return (
384
- sm: (0 1px 2px 0 rgba(0, 0, 0, 0.15)),
385
- md: (0 2px 4px -1px rgba(0, 0, 0, 0.2), 0 1px 3px -2px rgba(0, 0, 0, 0.15)),
386
- lg: (0 8px 12px -3px rgba(0, 0, 0, 0.25), 0 3px 5px -4px rgba(0, 0, 0, 0.18))
283
+ sm: (
284
+ 0 1px 2px 0 rgba(0, 0, 0, 0.15),
285
+ ),
286
+ md: (
287
+ 0 2px 4px -1px rgba(0, 0, 0, 0.2),
288
+ 0 1px 3px -2px rgba(0, 0, 0, 0.15),
289
+ ),
290
+ lg: (
291
+ 0 8px 12px -3px rgba(0, 0, 0, 0.25),
292
+ 0 3px 5px -4px rgba(0, 0, 0, 0.18),
293
+ )
387
294
  );
388
295
  } @else {
389
296
  // Light mode: flatter aesthetic — near-zero shadows so layout reads
390
297
  // as structure rather than floating chrome.
391
298
  @return (
392
- sm: (0 1px 2px 0 rgba(0, 0, 0, 0.02)),
393
- md: (0 2px 4px -1px rgba(0, 0, 0, 0.04), 0 1px 3px -2px rgba(0, 0, 0, 0.03)),
394
- lg: (0 8px 12px -3px rgba(0, 0, 0, 0.06), 0 3px 5px -4px rgba(0, 0, 0, 0.04))
299
+ sm: (
300
+ 0 1px 2px 0 rgba(0, 0, 0, 0.02),
301
+ ),
302
+ md: (
303
+ 0 2px 4px -1px rgba(0, 0, 0, 0.04),
304
+ 0 1px 3px -2px rgba(0, 0, 0, 0.03),
305
+ ),
306
+ lg: (
307
+ 0 8px 12px -3px rgba(0, 0, 0, 0.06),
308
+ 0 3px 5px -4px rgba(0, 0, 0, 0.04),
309
+ )
395
310
  );
396
311
  }
397
312
  }
@@ -400,33 +315,20 @@
400
315
  // Scrollbar Derivation
401
316
  // --------------------------------------------
402
317
 
403
- /// Derive scrollbar tokens from a neutral palette
318
+ /// Derive scrollbar tokens for the paper ramp
404
319
  /// @param {Map} $palette - Neutral palette map
405
320
  /// @param {Boolean} $is-dark - Whether in dark mode
406
321
  /// @return {Map} Scrollbar token values
407
- @function derive-scrollbar($palette, $is-dark: false, $palette-name: 'stone') {
322
+ @function derive-scrollbar($palette, $is-dark: false, $palette-name: "paper") {
408
323
  @if $is-dark {
409
- // Carbon (Fragments default) — transparent track, strong-border thumb.
410
- @if $palette-name == 'carbon' {
411
- @return (
412
- track: transparent,
413
- thumb: #4b4b4b,
414
- thumb-hover: #b4b4b4
415
- );
416
- }
417
-
418
- @return (
419
- track: get-shade($palette, 800),
420
- thumb: get-shade($palette, 600),
421
- thumb-hover: get-shade($palette, 500)
422
- );
423
- } @else {
424
- @return (
425
- track: get-shade($palette, 100),
426
- thumb: get-shade($palette, 300),
427
- thumb-hover: get-shade($palette, 400)
428
- );
324
+ // Transparent track, strong-border thumb on the warm charcoal plane.
325
+ @return (track: transparent, thumb: #4a4641, thumb-hover: #b6b0a8);
429
326
  }
327
+ @return (
328
+ track: get-shade($palette, 100),
329
+ thumb: get-shade($palette, 300),
330
+ thumb-hover: get-shade($palette, 400)
331
+ );
430
332
  }
431
333
 
432
334
  // --------------------------------------------
@@ -510,9 +412,9 @@
510
412
  /// @param {Color} $color - Color to measure
511
413
  /// @return {Number} Relative luminance 0-1
512
414
  @function _wcag-luminance($color) {
513
- $r: _srgb-linearize(color.channel($color, 'red', $space: rgb));
514
- $g: _srgb-linearize(color.channel($color, 'green', $space: rgb));
515
- $b: _srgb-linearize(color.channel($color, 'blue', $space: rgb));
415
+ $r: _srgb-linearize(color.channel($color, "red", $space: rgb));
416
+ $g: _srgb-linearize(color.channel($color, "green", $space: rgb));
417
+ $b: _srgb-linearize(color.channel($color, "blue", $space: rgb));
516
418
  @return 0.2126 * $r + 0.7152 * $g + 0.0722 * $b;
517
419
  }
518
420