rift-ds 1.34.0 → 1.36.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 (269) hide show
  1. package/README.md +4 -3
  2. package/behaviors/chat-card.css +6 -0
  3. package/behaviors/direction.css +6 -0
  4. package/behaviors/locale.d.ts +9 -0
  5. package/behaviors/locale.js +2 -0
  6. package/behaviors/shell.css +6 -0
  7. package/behaviors/shortcuts.js +2 -2
  8. package/behaviors/visually-hidden.css +6 -0
  9. package/bin/templates/blocks/app/dashboard/page.tsx +1 -1
  10. package/bin/templates/blocks/app/settings/ProfileForm.tsx +1 -1
  11. package/bin/templates/blocks/app/sign-in/page.tsx +3 -3
  12. package/bin/templates/blocks/components/blocks/AppShell.module.css +10 -6
  13. package/chat/ChatAgentPane.css +6 -0
  14. package/chat/ChatTabs.js +1 -1
  15. package/chat/ChatWidget.css +6 -0
  16. package/chat/ChatWidget.d.ts +2 -2
  17. package/chat/ChatWidget.js +1 -1
  18. package/chat/DemoWelcome.js +2 -2
  19. package/chat/FollowupSuggestions.js +1 -1
  20. package/chat/demo.css +6 -0
  21. package/chat/queries.js +1 -1
  22. package/chat/selection.css +6 -0
  23. package/components/Accordion/Accordion.css +6 -0
  24. package/components/ActionBar/ActionBar.css +84 -0
  25. package/components/ActionBar/ActionBar.d.ts +40 -0
  26. package/components/ActionBar/ActionBar.js +29 -0
  27. package/components/ActionCard/ActionCard.css +6 -0
  28. package/components/ActionReadout/ActionReadout.css +6 -0
  29. package/components/AgentPlan/AgentPlan.css +6 -0
  30. package/components/AgentRail/AgentRail.css +6 -0
  31. package/components/AgentStatus/AgentStatus.css +12 -7
  32. package/components/AiButton/AiButton.css +17 -11
  33. package/components/AiButton/AiButton.js +1 -1
  34. package/components/Alert/Alert.css +22 -0
  35. package/components/Alert/Alert.d.ts +2 -2
  36. package/components/Alert/Alert.js +3 -1
  37. package/components/AlertDialog/AlertDialog.css +6 -0
  38. package/components/AnchorNav/AnchorNav.css +6 -0
  39. package/components/AnimatedNumber/AnimatedNumber.css +5 -0
  40. package/components/AppLayout/AppLayout.css +6 -0
  41. package/components/AppSidebar/AppSidebar.css +159 -5
  42. package/components/AppSidebar/AppSidebar.d.ts +13 -1
  43. package/components/AppSidebar/AppSidebar.js +17 -7
  44. package/components/ArtifactCard/ArtifactCard.css +6 -0
  45. package/components/ArtifactPanel/ArtifactPanel.css +6 -0
  46. package/components/Attachment/Attachment.css +6 -0
  47. package/components/Attachment/AttachmentGroup.js +4 -1
  48. package/components/Avatar/Avatar.css +6 -0
  49. package/components/AvatarGroup/AvatarGroup.css +6 -0
  50. package/components/BackToTop/BackToTop.css +6 -0
  51. package/components/Badge/Badge.css +6 -0
  52. package/components/Banner/Banner.css +6 -0
  53. package/components/BentoTile/BentoTile.css +6 -0
  54. package/components/BottomNav/BottomNav.css +6 -0
  55. package/components/Breadcrumb/Breadcrumb.css +6 -0
  56. package/components/Button/Button.css +6 -0
  57. package/components/Button/Button.d.ts +7 -1
  58. package/components/Button/Button.js +2 -1
  59. package/components/ButtonGroup/ButtonGroup.css +6 -0
  60. package/components/Card/Card.css +6 -0
  61. package/components/CardStack/CardStack.css +5 -0
  62. package/components/Carousel/Carousel.css +6 -0
  63. package/components/Chart/Chart.css +9 -1
  64. package/components/ChatHeader/ChatHeader.css +6 -0
  65. package/components/ChatMarker/ChatMarker.css +6 -0
  66. package/components/ChatMessage/ChatMessage.css +6 -0
  67. package/components/ChatThread/ChatThread.css +6 -0
  68. package/components/ChatThread/ChatThread.d.ts +5 -1
  69. package/components/ChatThread/ChatThread.js +1 -1
  70. package/components/Checkbox/Checkbox.css +6 -0
  71. package/components/Checkbox/Checkbox.js +1 -1
  72. package/components/Checklist/Checklist.css +6 -0
  73. package/components/Chip/Chip.css +6 -0
  74. package/components/CodeBlock/CodeBlock.css +6 -0
  75. package/components/CodeDiff/CodeDiff.css +5 -0
  76. package/components/ColorPicker/ColorPicker.css +6 -0
  77. package/components/ColourSwatch/ColourSwatch.css +6 -0
  78. package/components/Combobox/Combobox.css +6 -0
  79. package/components/CommandPalette/CommandPalette.css +6 -0
  80. package/components/CommandPaletteTrigger/CommandPaletteTrigger.css +6 -0
  81. package/components/Composer/Composer.css +6 -0
  82. package/components/ContactCard/ContactCard.css +6 -0
  83. package/components/ContextMenu/ContextMenu.css +6 -0
  84. package/components/ContextMenu/ContextMenu.d.ts +5 -1
  85. package/components/ContextMenu/ContextMenu.js +2 -1
  86. package/components/ContributionGraph/ContributionGraph.css +6 -0
  87. package/components/ContributionGraph/ContributionGraph.d.ts +7 -1
  88. package/components/ContributionGraph/ContributionGraph.js +4 -18
  89. package/components/ContributionGraph/weeks.d.ts +8 -0
  90. package/components/ContributionGraph/weeks.js +25 -0
  91. package/components/CurrencyInput/CurrencyInput.css +6 -0
  92. package/components/DataTable/DataTable.css +6 -0
  93. package/components/DataTable/DataTable.js +7 -3
  94. package/components/DateInput/DateInput.css +6 -0
  95. package/components/DatePicker/DatePicker.css +6 -0
  96. package/components/DateRangePicker/DateRangePicker.css +6 -0
  97. package/components/Deadline/Deadline.css +6 -0
  98. package/components/DecisionRow/DecisionRow.css +6 -0
  99. package/components/DescriptionList/DescriptionList.css +6 -0
  100. package/components/Dialog/Dialog.css +6 -0
  101. package/components/Divider/Divider.css +6 -0
  102. package/components/DocumentChip/DocumentChip.css +6 -0
  103. package/components/DocumentChip/DocumentChip.js +1 -1
  104. package/components/DocumentViewer/DocumentViewer.css +6 -0
  105. package/components/Drawer/Drawer.css +6 -0
  106. package/components/Dropdown/ChosenMark.css +6 -0
  107. package/components/Dropdown/Dropdown.css +6 -0
  108. package/components/Dropdown/Dropdown.js +1 -1
  109. package/components/DropdownMenu/DropdownMenu.css +6 -0
  110. package/components/EmptyState/EmptyState.css +6 -0
  111. package/components/EntityCard/EntityCard.css +6 -0
  112. package/components/EntitySwitcher/EntitySwitcher.css +17 -3
  113. package/components/EntitySwitcher/EntitySwitcher.js +1 -1
  114. package/components/ErrorSummary/ErrorSummary.css +6 -0
  115. package/components/ErrorSummary/ErrorSummary.js +3 -1
  116. package/components/EventCalendar/EventCalendar.css +158 -0
  117. package/components/EventCalendar/EventCalendar.d.ts +50 -4
  118. package/components/EventCalendar/EventCalendar.js +154 -23
  119. package/components/EventCalendar/eventTime.d.ts +31 -0
  120. package/components/EventCalendar/eventTime.js +42 -0
  121. package/components/Field/Field.css +6 -0
  122. package/components/Figure/Figure.css +6 -0
  123. package/components/FileInput/FileInput.css +6 -0
  124. package/components/FileInput/FileInput.d.ts +12 -4
  125. package/components/FileInput/FileInput.js +27 -4
  126. package/components/FilterBar/FilterBar.css +9 -1
  127. package/components/FormSection/FormSection.css +6 -0
  128. package/components/FunnelChart/FunnelChart.css +6 -0
  129. package/components/GanttChart/GanttChart.css +6 -0
  130. package/components/Gauge/Gauge.css +6 -0
  131. package/components/Globe/Globe.css +6 -0
  132. package/components/Grid/Grid.css +6 -0
  133. package/components/Heading/Heading.css +6 -0
  134. package/components/HoverCard/HoverCard.css +6 -0
  135. package/components/Icon/Icon.css +6 -0
  136. package/components/IconButton/IconButton.css +6 -0
  137. package/components/IconButton/IconButton.d.ts +7 -1
  138. package/components/IconButton/IconButton.js +2 -1
  139. package/components/ImageCompare/ImageCompare.css +6 -0
  140. package/components/Input/Input.css +52 -4
  141. package/components/Input/Input.d.ts +8 -0
  142. package/components/Input/Input.js +3 -0
  143. package/components/Inspector/Inspector.css +6 -0
  144. package/components/Instructions/Instructions.css +6 -0
  145. package/components/InterruptCard/InterruptCard.css +6 -0
  146. package/components/Kbd/Kbd.css +6 -0
  147. package/components/LegendTile/LegendTile.css +6 -0
  148. package/components/Lightbox/Lightbox.css +6 -0
  149. package/components/Link/Link.css +9 -1
  150. package/components/LinkList/LinkList.css +6 -0
  151. package/components/List/List.css +6 -0
  152. package/components/MapCallout/MapCallout.css +6 -0
  153. package/components/MapLegend/MapLegend.css +6 -0
  154. package/components/MaskedInput/MaskedInput.css +6 -0
  155. package/components/MegaMenu/MegaMenu.css +6 -0
  156. package/components/Mention/Mention.css +6 -0
  157. package/components/Mention/Mention.js +1 -1
  158. package/components/Menubar/Menubar.css +6 -0
  159. package/components/MessageActions/MessageActions.css +6 -0
  160. package/components/MessageCard/MessageCard.css +6 -0
  161. package/components/Meter/Meter.css +6 -0
  162. package/components/ModelPicker/ModelPicker.css +6 -0
  163. package/components/MotionSwatch/MotionSwatch.css +6 -0
  164. package/components/Nav/Nav.css +6 -0
  165. package/components/NavList/NavList.css +6 -0
  166. package/components/NotificationCenter/NotificationCenter.css +6 -0
  167. package/components/NumberInput/NumberInput.css +6 -0
  168. package/components/OrgChart/OrgChart.css +6 -0
  169. package/components/PageHeader/PageHeader.css +6 -0
  170. package/components/Pagination/Pagination.css +6 -0
  171. package/components/Panel/Panel.css +6 -0
  172. package/components/PinInput/PinInput.css +6 -0
  173. package/components/PixelAvatar/PixelAvatar.css +6 -0
  174. package/components/Popover/Popover.css +6 -0
  175. package/components/Popover/Popover.d.ts +5 -1
  176. package/components/Popover/Popover.js +3 -1
  177. package/components/ProgressBar/ProgressBar.css +6 -0
  178. package/components/ProgressBar/ProgressBar.d.ts +5 -1
  179. package/components/ProgressBar/ProgressBar.js +1 -1
  180. package/components/ProgressiveBlur/ProgressiveBlur.css +6 -0
  181. package/components/PromptSuggestions/PromptSuggestions.css +5 -0
  182. package/components/PromptSuggestions/PromptSuggestions.d.ts +5 -1
  183. package/components/PromptSuggestions/PromptSuggestions.js +1 -1
  184. package/components/Prose/Prose.css +6 -0
  185. package/components/QuestionCard/QuestionCard.css +5 -0
  186. package/components/Quote/Quote.css +6 -0
  187. package/components/RadioButton/RadioButton.css +6 -0
  188. package/components/Rating/Rating.css +6 -0
  189. package/components/Reasoning/Reasoning.css +6 -0
  190. package/components/ResourceTimeline/ResourceTimeline.css +6 -0
  191. package/components/ResourceTimeline/ResourceTimeline.js +2 -2
  192. package/components/RichDropdown/RichDropdown.css +6 -0
  193. package/components/SectionTitle/SectionTitle.css +6 -0
  194. package/components/SegmentedControl/SegmentedControl.css +126 -3
  195. package/components/SegmentedControl/SegmentedControl.d.ts +9 -0
  196. package/components/SegmentedControl/SegmentedControl.js +11 -1
  197. package/components/SelectionCard/SelectionCard.css +6 -0
  198. package/components/ShaderField/ShaderField.css +6 -0
  199. package/components/ShaderField/ShaderField.js +2 -0
  200. package/components/ShaderScene/ShaderScene.css +6 -0
  201. package/components/ShaderScene/ShaderScene.d.ts +3 -3
  202. package/components/ShaderScene/scenes.d.ts +17 -0
  203. package/components/ShaderScene/scenes.js +175 -1
  204. package/components/SidebarPanel/SidebarPanel.css +6 -0
  205. package/components/SignaturePad/SignaturePad.css +6 -0
  206. package/components/SiteFooter/SiteFooter.css +6 -0
  207. package/components/SiteHeader/SiteHeader.css +6 -0
  208. package/components/SiteLayout/SiteLayout.css +6 -0
  209. package/components/Skeleton/Skeleton.css +6 -0
  210. package/components/Slider/Slider.css +6 -0
  211. package/components/SourceChip/SourceChip.css +6 -0
  212. package/components/SourceTrail/SourceTrail.css +6 -0
  213. package/components/SpacingSwatch/SpacingSwatch.css +6 -0
  214. package/components/Sparkline/Sparkline.css +6 -0
  215. package/components/Spinner/Spinner.css +6 -0
  216. package/components/SplitButton/SplitButton.css +6 -0
  217. package/components/SplitButton/SplitButton.d.ts +7 -1
  218. package/components/SplitButton/SplitButton.js +3 -1
  219. package/components/SplitPane/SplitPane.css +6 -0
  220. package/components/Stack/Stack.css +6 -0
  221. package/components/Stat/Stat.css +25 -1
  222. package/components/Stat/Stat.d.ts +5 -0
  223. package/components/Stat/Stat.js +9 -3
  224. package/components/StatusDot/StatusDot.css +6 -0
  225. package/components/Stepper/Stepper.css +6 -0
  226. package/components/StreamingText/StreamingText.css +6 -0
  227. package/components/Swatch/Swatch.css +6 -0
  228. package/components/Table/Table.css +15 -1
  229. package/components/TableToolbar/TableToolbar.css +6 -0
  230. package/components/TableToolbar/TableToolbar.js +2 -2
  231. package/components/Tabs/Tabs.css +6 -0
  232. package/components/TagInput/TagInput.css +6 -0
  233. package/components/Text/Text.css +6 -0
  234. package/components/Textarea/Textarea.css +5 -0
  235. package/components/ThemePicker/ThemePicker.css +6 -0
  236. package/components/ThemeToggle/ThemeToggle.css +6 -0
  237. package/components/ThemeToggle/ThemeToggle.d.ts +1 -1
  238. package/components/ThreadPanel/ThreadPanel.css +6 -0
  239. package/components/ThreadTabs/ThreadTabs.css +6 -0
  240. package/components/ThreadTabs/ThreadTabs.d.ts +5 -1
  241. package/components/ThreadTabs/ThreadTabs.js +2 -1
  242. package/components/TimePicker/TimePicker.css +6 -0
  243. package/components/Timeline/Timeline.css +18 -18
  244. package/components/Toast/Toast.css +6 -0
  245. package/components/Toast/Toast.js +1 -1
  246. package/components/ToggleGroup/ToggleGroup.css +6 -0
  247. package/components/ToggleGroup/ToggleGroup.d.ts +5 -1
  248. package/components/ToggleSwitch/ToggleSwitch.css +21 -3
  249. package/components/ToggleSwitch/ToggleSwitch.d.ts +1 -1
  250. package/components/ToggleSwitch/ToggleSwitch.js +2 -2
  251. package/components/ToolCall/ToolCall.css +6 -0
  252. package/components/Toolbar/Toolbar.css +6 -0
  253. package/components/Tooltip/Tooltip.css +6 -0
  254. package/components/TopAppBar/TopAppBar.css +6 -0
  255. package/components/TreeView/TreeView.css +6 -0
  256. package/components/TypographySwatch/TypographySwatch.css +6 -0
  257. package/components/UsageCard/UsageCard.css +6 -0
  258. package/components/Waveform/Waveform.css +6 -0
  259. package/components/Widget/Widget.css +6 -0
  260. package/components/Wizard/Wizard.css +6 -0
  261. package/components/WorldMap/WorldMap.css +6 -0
  262. package/components/registry.json +21 -4
  263. package/components/registry.json.d.ts +21 -4
  264. package/components/registry.json.js +1 -1
  265. package/fonts/material-symbols.css +10 -0
  266. package/index.d.ts +1 -0
  267. package/index.js +2 -0
  268. package/package.json +1 -1
  269. package/tokens/base.css +11 -2
@@ -4,6 +4,10 @@
4
4
  Vertical timeline or horizontal stepper.
5
5
  ============================================ */
6
6
 
7
+ @layer rift.tokens, rift.preset, rift.components;
8
+
9
+ @layer rift.components {
10
+
7
11
  .ds-timeline {
8
12
  margin: 0;
9
13
  padding: 0;
@@ -124,12 +128,14 @@
124
128
  margin-top: 0;
125
129
  }
126
130
 
127
- /* Connector line — from this marker down to the next item */
131
+ /* Connector line: runs from the bottom edge of this marker to the top edge
132
+ of the next, so it always touches both points and never passes behind a
133
+ marker (a translucent fill would let it show through). */
128
134
  .ds-timeline--vertical .ds-timeline__item::before {
129
135
  content: '';
130
136
  position: absolute;
131
- top: 0;
132
- bottom: calc(-1 * var(--gap-500));
137
+ top: 18px; /* ds-allow(spacing): the 6px offset plus the 12px dot */
138
+ bottom: calc(-1 * var(--gap-500) - 6px); /* ds-allow(spacing): down to the next dot's 6px offset */
133
139
  inset-inline-start: 5px; /* centre of the 12px dot */
134
140
  width: var(--border-050);
135
141
  background-color: var(--color-divider);
@@ -138,15 +144,11 @@
138
144
  .ds-timeline--vertical.ds-timeline--numbered .ds-timeline__item::before,
139
145
  .ds-timeline--vertical .ds-timeline__item:has(.ds-timeline__marker--badge)::before,
140
146
  .ds-timeline--vertical .ds-timeline__item:has(.ds-timeline__marker--icon)::before {
147
+ top: 28px; /* the 28px badge/icon box */
148
+ bottom: calc(-1 * var(--gap-500));
141
149
  inset-inline-start: 13px; /* centre of the 28px badge/icon box */
142
150
  }
143
151
 
144
- /* Bare icons have no opaque fill to cover the line —
145
- start it just below the icon box instead */
146
- .ds-timeline--vertical .ds-timeline__item:has(.ds-timeline__marker--icon)::before {
147
- top: 32px;
148
- }
149
-
150
152
  .ds-timeline--vertical .ds-timeline__item:last-child::before {
151
153
  display: none;
152
154
  }
@@ -169,13 +171,14 @@
169
171
  padding-inline-end: var(--padding-400);
170
172
  }
171
173
 
172
- /* Connector line — from this marker across to the next */
174
+ /* Connector line: from the end edge of this marker to the start edge of the
175
+ next (the next item's own start), touching both and never behind either. */
173
176
  .ds-timeline--horizontal .ds-timeline__item::before {
174
177
  content: '';
175
178
  position: absolute;
176
179
  top: 5px; /* centre of the 12px dot */
177
- left: 0;
178
- right: 0;
180
+ inset-inline-start: 12px; /* the 12px dot */
181
+ inset-inline-end: 0;
179
182
  height: var(--border-050);
180
183
  background-color: var(--color-divider);
181
184
  }
@@ -184,12 +187,7 @@
184
187
  .ds-timeline--horizontal .ds-timeline__item:has(.ds-timeline__marker--badge)::before,
185
188
  .ds-timeline--horizontal .ds-timeline__item:has(.ds-timeline__marker--icon)::before {
186
189
  top: 13px; /* centre of the 28px badge/icon box */
187
- }
188
-
189
- /* Bare icons have no opaque fill to cover the line —
190
- start it just after the icon box instead */
191
- .ds-timeline--horizontal .ds-timeline__item:has(.ds-timeline__marker--icon)::before {
192
- inset-inline-start: 32px;
190
+ inset-inline-start: 28px; /* the 28px badge/icon box */
193
191
  }
194
192
 
195
193
  .ds-timeline--horizontal .ds-timeline__item:last-child::before {
@@ -377,3 +375,5 @@
377
375
  .ds-timeline--horizontal .ds-timeline__description {
378
376
  overflow-wrap: break-word;
379
377
  }
378
+
379
+ } /* @layer rift.components */
@@ -15,6 +15,10 @@
15
15
  --ds-toast-inset-right gap from the right edge for *-right placements
16
16
  ============================================ */
17
17
 
18
+ @layer rift.tokens, rift.preset, rift.components;
19
+
20
+ @layer rift.components {
21
+
18
22
  .ds-toast-container {
19
23
  position: fixed;
20
24
  z-index: var(--ds-toast-z, var(--layer-toast));
@@ -365,3 +369,5 @@
365
369
  .ds-toast__action {
366
370
  margin-block-start: var(--gap-200);
367
371
  }
372
+
373
+ } /* @layer rift.components */
@@ -1,6 +1,6 @@
1
1
  "use client";
2
2
  import { jsxs, jsx } from "react/jsx-runtime";
3
- import React, { useState, useSyncExternalStore, useCallback, useContext, createContext, useRef, useEffect } from "react";
3
+ import React, { createContext, useContext, useState, useSyncExternalStore, useCallback, useRef, useEffect } from "react";
4
4
  import { MOTION_AUTO_DISMISS_MS, MOTION_EXIT_SYNC_MS } from "../../tokens/motion.js";
5
5
  import ReactDOM from "react-dom";
6
6
  import "./Toast.css";
@@ -3,6 +3,10 @@
3
3
  A set of two-state buttons
4
4
  ============================================ */
5
5
 
6
+ @layer rift.tokens, rift.preset, rift.components;
7
+
8
+ @layer rift.components {
9
+
6
10
  /* A control strip on the input radius, filled like SegmentedControl's
7
11
  track, so the group reads as one control rather than a hairline. */
8
12
  .ds-toggle-group {
@@ -126,3 +130,5 @@
126
130
  .ds-toggle-group .material-symbols-rounded {
127
131
  color: inherit;
128
132
  }
133
+
134
+ } /* @layer rift.components */
@@ -4,7 +4,11 @@ export interface ToggleGroupItem {
4
4
  value: string;
5
5
  /** Display label or icon name (Material Symbols) */
6
6
  label: string;
7
- /** Use Material Symbol icon instead of text */
7
+ /**
8
+ * Draw `label` as a Material Symbol icon instead of text. An item is an
9
+ * icon or a label, never both: for icon-plus-label options, use
10
+ * SegmentedControl, whose segments take an `icon` beside their `label`.
11
+ */
8
12
  icon?: boolean;
9
13
  }
10
14
  /** Props owned by ToggleGroup itself — everything else falls through to the wrapper. */
@@ -8,6 +8,10 @@
8
8
  keyed on the track's own modifiers.
9
9
  ============================================ */
10
10
 
11
+ @layer rift.tokens, rift.preset, rift.components;
12
+
13
+ @layer rift.components {
14
+
11
15
  .ds-toggle-switch {
12
16
  /* Layout */
13
17
  display: inline-flex;
@@ -54,7 +58,9 @@
54
58
  align-items: center;
55
59
  justify-content: center;
56
60
  overflow: hidden;
57
- transition: transform var(--motion-duration-slow) var(--motion-ease-spring);
61
+ transition:
62
+ transform var(--motion-duration-slow) var(--motion-ease-spring),
63
+ background-color var(--motion-duration-slow) var(--motion-ease-standard);
58
64
  }
59
65
 
60
66
  /* The same SVG check Checkbox draws, so the two controls show one tick.
@@ -65,6 +71,7 @@
65
71
  width: 14px;
66
72
  height: 14px;
67
73
  color: var(--color-action-primary-bg);
74
+ transition: opacity var(--motion-duration-base) var(--motion-ease-standard);
68
75
  }
69
76
 
70
77
  /* ============================================
@@ -88,15 +95,24 @@
88
95
  another host shows the same states.
89
96
  ============================================ */
90
97
 
91
- /* Off / Unchecked state — thumb moves to the left */
98
+ /* Off: nothing about it reads as on. The track takes the unchecked
99
+ control's ring colour (Checkbox's and RadioButton's), which clears 3:1
100
+ against the page and the card in every theme; the thumb takes the input
101
+ surface instead of the action tint; the tick goes; and the thumb moves to
102
+ the start. */
92
103
  .ds-toggle-switch__track--off {
93
- background: var(--color-text-secondary);
104
+ background: var(--color-input-indicator-border);
94
105
  }
95
106
 
96
107
  .ds-toggle-switch__track--off .ds-toggle-switch__thumb {
108
+ background: var(--color-input-bg-primary);
97
109
  transform: translateX(calc(-18px * var(--ds-inline-sign, 1)));
98
110
  }
99
111
 
112
+ .ds-toggle-switch__track--off .ds-toggle-switch__thumb-icon {
113
+ opacity: 0;
114
+ }
115
+
100
116
  /* ============================================
101
117
  FOCUS
102
118
  The same ring as Checkbox and RadioButton, on
@@ -176,3 +192,5 @@
176
192
  .ds-toggle-switch--error .ds-toggle-switch__helper {
177
193
  color: var(--color-status-error-border);
178
194
  }
195
+
196
+ } /* @layer rift.components */
@@ -6,7 +6,7 @@ type ToggleSwitchOwnProps = {
6
6
  * keep its own state, seeded from `defaultChecked`.
7
7
  */
8
8
  checked?: boolean;
9
- /** Whether the toggle starts on when uncontrolled (`checked` undefined). Defaults to true, so an uncontrolled switch starts on unless this is false. */
9
+ /** Whether the toggle starts on when uncontrolled (`checked` undefined). Defaults to false, as every checkable control does, so a switch left uncontrolled never turns a setting on by itself. */
10
10
  defaultChecked?: boolean;
11
11
  /** Label text displayed next to the toggle */
12
12
  label?: string;
@@ -1,5 +1,5 @@
1
1
  "use client";
2
- import { jsx, jsxs } from "react/jsx-runtime";
2
+ import { jsxs, jsx } from "react/jsx-runtime";
3
3
  import React, { useState, useId } from "react";
4
4
  import { CheckIcon } from "../Checkbox/Checkbox.js";
5
5
  import "./ToggleSwitch.css";
@@ -7,7 +7,7 @@ import "../../behaviors/direction.css";
7
7
  const ToggleSwitch = React.forwardRef(
8
8
  ({
9
9
  checked: checkedProp,
10
- defaultChecked = true,
10
+ defaultChecked = false,
11
11
  label = "Toggle",
12
12
  showLabel = true,
13
13
  helperText,
@@ -12,6 +12,10 @@
12
12
  the status word and icon carry the state.
13
13
  ============================================ */
14
14
 
15
+ @layer rift.tokens, rift.preset, rift.components;
16
+
17
+ @layer rift.components {
18
+
15
19
  .ds-tool-call {
16
20
  /* Two colour channels per status: -text for the status word (tuned for
17
21
  text contrast) and -icon for the indicator glyph, which needs a hue
@@ -315,3 +319,5 @@
315
319
  .ds-tool-call__header:has(.ds-tool-call__chevron) {
316
320
  padding-inline-end: calc(var(--ds-chat-card-inset) - var(--padding-100));
317
321
  }
322
+
323
+ } /* @layer rift.components */
@@ -3,6 +3,10 @@
3
3
  Grouped strip of controls in one shell
4
4
  ============================================ */
5
5
 
6
+ @layer rift.tokens, rift.preset, rift.components;
7
+
8
+ @layer rift.components {
9
+
6
10
  /* Base — a pill shell on the container fill. Padding clears the focus
7
11
  ring's full reach (2px offset + 2px outline), so a focused control's
8
12
  ring seats inside the shell instead of slicing its border. */
@@ -54,3 +58,5 @@
54
58
  margin-block: var(--gap-050);
55
59
  margin-inline: var(--gap-050);
56
60
  }
61
+
62
+ } /* @layer rift.components */
@@ -1,3 +1,7 @@
1
+ @layer rift.tokens, rift.preset, rift.components;
2
+
3
+ @layer rift.components {
4
+
1
5
  /* ds-allow-file(physical): the arrow and the entrance nudge point at the side the anchored behaviour placed the tooltip on, a screen side */
2
6
  /* ============================================
3
7
  TOOLTIP COMPONENT
@@ -175,3 +179,5 @@
175
179
  border-bottom: var(--border-025) solid var(--color-bg-container-border);
176
180
  border-left: var(--border-025) solid var(--color-bg-container-border);
177
181
  }
182
+
183
+ } /* @layer rift.components */
@@ -9,6 +9,10 @@
9
9
  expanded title that collapses on scroll.
10
10
  ============================================ */
11
11
 
12
+ @layer rift.tokens, rift.preset, rift.components;
13
+
14
+ @layer rift.components {
15
+
12
16
  /* ============================================
13
17
  BASE (shared by every platform)
14
18
  ============================================ */
@@ -464,3 +468,5 @@
464
468
  line-height: 24px;
465
469
  letter-spacing: 0.15px;
466
470
  }
471
+
472
+ } /* @layer rift.components */
@@ -4,6 +4,10 @@
4
4
  and nested structures
5
5
  ============================================ */
6
6
 
7
+ @layer rift.tokens, rift.preset, rift.components;
8
+
9
+ @layer rift.components {
10
+
7
11
  /* Base */
8
12
 
9
13
  .ds-treeview {
@@ -117,3 +121,5 @@
117
121
  padding: 0;
118
122
  list-style: none;
119
123
  }
124
+
125
+ } /* @layer rift.components */
@@ -4,6 +4,10 @@
4
4
  preview and four value columns.
5
5
  ============================================ */
6
6
 
7
+ @layer rift.tokens, rift.preset, rift.components;
8
+
9
+ @layer rift.components {
10
+
7
11
  .ds-typography-swatch {
8
12
  /* Layout */
9
13
  display: flex;
@@ -81,3 +85,5 @@
81
85
  line-height: var(--font-paragraph-line-height);
82
86
  color: var(--color-text-secondary);
83
87
  }
88
+
89
+ } /* @layer rift.components */
@@ -4,6 +4,10 @@
4
4
  with reset captions, in the chart card chrome
5
5
  ============================================ */
6
6
 
7
+ @layer rift.tokens, rift.preset, rift.components;
8
+
9
+ @layer rift.components {
10
+
7
11
  /* Base — the card chrome itself comes from ds-chart. In a chat it is one
8
12
  of the chat cards, so it takes their padding, title and rhythm: the
9
13
  recipe's edge above and below inside its inset at the sides, a
@@ -56,3 +60,5 @@
56
60
  line-height: var(--font-caption-line-height);
57
61
  color: var(--color-text-secondary);
58
62
  }
63
+
64
+ } /* @layer rift.components */
@@ -4,6 +4,10 @@
4
4
  the shared twelve-slot cycle
5
5
  ============================================ */
6
6
 
7
+ @layer rift.tokens, rift.preset, rift.components;
8
+
9
+ @layer rift.components {
10
+
7
11
  /* Base — height rides the icon scale, bar width derives from it, and the
8
12
  colour routes through one custom property so a consumer can tint the wave. */
9
13
 
@@ -84,3 +88,5 @@
84
88
  transform: scaleY(calc(var(--ds-waveform-amp, 1) * 0.6));
85
89
  }
86
90
  }
91
+
92
+ } /* @layer rift.components */
@@ -5,6 +5,10 @@
5
5
  packs tiles into columns
6
6
  ============================================ */
7
7
 
8
+ @layer rift.tokens, rift.preset, rift.components;
9
+
10
+ @layer rift.components {
11
+
8
12
  /* Tile — the translucent container behind a hairline, blurred so the body
9
13
  stays on a calm field when the tile sits over an ambient background. The
10
14
  navigation-tile radius, per the radius scale. */
@@ -339,3 +343,5 @@
339
343
  break-inside: avoid;
340
344
  margin-bottom: var(--gap-400);
341
345
  }
346
+
347
+ } /* @layer rift.components */
@@ -5,6 +5,10 @@
5
5
  and Continue at the end, above a rule.
6
6
  ============================================ */
7
7
 
8
+ @layer rift.tokens, rift.preset, rift.components;
9
+
10
+ @layer rift.components {
11
+
8
12
  /* Base */
9
13
  .ds-wizard {
10
14
  display: flex;
@@ -65,3 +69,5 @@
65
69
  gap: var(--gap-200);
66
70
  margin-inline-start: auto;
67
71
  }
72
+
73
+ } /* @layer rift.components */
@@ -1,3 +1,7 @@
1
+ @layer rift.tokens, rift.preset, rift.components;
2
+
3
+ @layer rift.components {
4
+
1
5
  /* ds-allow-file(physical): a map is geography: west is on the left in every reading direction */
2
6
  /* ============================================
3
7
  WORLD MAP COMPONENT
@@ -248,3 +252,5 @@ button.ds-world-map__marker:hover .ds-world-map__dot {
248
252
  .ds-world-map__callout[data-side='left'] {
249
253
  transform: translate(-100%, -100%);
250
254
  }
255
+
256
+ } /* @layer rift.components */
@@ -77,6 +77,19 @@
77
77
  "client": true,
78
78
  "pattern": "accordion"
79
79
  },
80
+ {
81
+ "name": "ActionBar",
82
+ "label": "Action bar",
83
+ "slug": "action-bar",
84
+ "description": "A bar docked to the bottom of a long list or form, with a summary line and the primary actions over a progressive blur.",
85
+ "category": "actions",
86
+ "client": false,
87
+ "keys": { "by": "platform", "note": "The bar adds no keys of its own: its actions are buttons, and the browser owns Tab, Enter and Space." },
88
+ "alternatives": [
89
+ { "name": "Toolbar", "when": "the controls act on a canvas or a view and sit together in one pill, rather than closing out a list" },
90
+ { "name": "TableToolbar", "when": "the bar sits over a table and holds its search, filters and view settings" }
91
+ ]
92
+ },
80
93
  {
81
94
  "name": "ActionCard",
82
95
  "label": "Action card",
@@ -826,7 +839,7 @@
826
839
  "name": "FileInput",
827
840
  "label": "File input",
828
841
  "slug": "file-input",
829
- "description": "A click-or-drop upload zone paired with a controlled file list showing size, progress, and per-file errors.",
842
+ "description": "A click-or-drop upload zone paired with a file list showing size, progress, and per-file errors.",
830
843
  "category": "forms",
831
844
  "client": true,
832
845
  "pattern": "button"
@@ -1745,7 +1758,7 @@
1745
1758
  "client": false,
1746
1759
  "keys": { "by": "none" },
1747
1760
  "alternatives": [
1748
- { "name": "DataTable", "when": "the rows need sorting, filtering, editing or loading from a server" }
1761
+ { "name": "DataTable", "when": "the rows need sorting, filtering, paging, editing or loading from a server" }
1749
1762
  ]
1750
1763
  },
1751
1764
  {
@@ -1755,7 +1768,10 @@
1755
1768
  "description": "The control bar over a table: search, filter chips, sort, group, columns, density, saved views and a bulk bar, wired to a DataTable in its toolbar slot.",
1756
1769
  "category": "data-display",
1757
1770
  "client": true,
1758
- "keys": { "by": "component", "note": "Alt and the up or down arrow reorder a column or a sort row, and Escape closes a panel." }
1771
+ "keys": { "by": "component", "note": "Alt and the up or down arrow reorder a column or a sort row, and Escape closes a panel." },
1772
+ "alternatives": [
1773
+ { "name": "ActionBar", "when": "the actions finish the work on a long list or form, docked below it rather than over a table" }
1774
+ ]
1759
1775
  },
1760
1776
  {
1761
1777
  "name": "Tabs",
@@ -1901,7 +1917,8 @@
1901
1917
  "client": true,
1902
1918
  "pattern": "toolbar",
1903
1919
  "alternatives": [
1904
- { "name": "Menubar", "when": "the controls are named menus of commands, like an app's File and Edit" }
1920
+ { "name": "Menubar", "when": "the controls are named menus of commands, like an app's File and Edit" },
1921
+ { "name": "ActionBar", "when": "a summary and the primary actions close out a long list or form, docked to its bottom" }
1905
1922
  ]
1906
1923
  },
1907
1924
  {
@@ -77,6 +77,19 @@ declare const _default: {
77
77
  "client": true,
78
78
  "pattern": "accordion"
79
79
  },
80
+ {
81
+ "name": "ActionBar",
82
+ "label": "Action bar",
83
+ "slug": "action-bar",
84
+ "description": "A bar docked to the bottom of a long list or form, with a summary line and the primary actions over a progressive blur.",
85
+ "category": "actions",
86
+ "client": false,
87
+ "keys": { "by": "platform", "note": "The bar adds no keys of its own: its actions are buttons, and the browser owns Tab, Enter and Space." },
88
+ "alternatives": [
89
+ { "name": "Toolbar", "when": "the controls act on a canvas or a view and sit together in one pill, rather than closing out a list" },
90
+ { "name": "TableToolbar", "when": "the bar sits over a table and holds its search, filters and view settings" }
91
+ ]
92
+ },
80
93
  {
81
94
  "name": "ActionCard",
82
95
  "label": "Action card",
@@ -826,7 +839,7 @@ declare const _default: {
826
839
  "name": "FileInput",
827
840
  "label": "File input",
828
841
  "slug": "file-input",
829
- "description": "A click-or-drop upload zone paired with a controlled file list showing size, progress, and per-file errors.",
842
+ "description": "A click-or-drop upload zone paired with a file list showing size, progress, and per-file errors.",
830
843
  "category": "forms",
831
844
  "client": true,
832
845
  "pattern": "button"
@@ -1745,7 +1758,7 @@ declare const _default: {
1745
1758
  "client": false,
1746
1759
  "keys": { "by": "none" },
1747
1760
  "alternatives": [
1748
- { "name": "DataTable", "when": "the rows need sorting, filtering, editing or loading from a server" }
1761
+ { "name": "DataTable", "when": "the rows need sorting, filtering, paging, editing or loading from a server" }
1749
1762
  ]
1750
1763
  },
1751
1764
  {
@@ -1755,7 +1768,10 @@ declare const _default: {
1755
1768
  "description": "The control bar over a table: search, filter chips, sort, group, columns, density, saved views and a bulk bar, wired to a DataTable in its toolbar slot.",
1756
1769
  "category": "data-display",
1757
1770
  "client": true,
1758
- "keys": { "by": "component", "note": "Alt and the up or down arrow reorder a column or a sort row, and Escape closes a panel." }
1771
+ "keys": { "by": "component", "note": "Alt and the up or down arrow reorder a column or a sort row, and Escape closes a panel." },
1772
+ "alternatives": [
1773
+ { "name": "ActionBar", "when": "the actions finish the work on a long list or form, docked below it rather than over a table" }
1774
+ ]
1759
1775
  },
1760
1776
  {
1761
1777
  "name": "Tabs",
@@ -1901,7 +1917,8 @@ declare const _default: {
1901
1917
  "client": true,
1902
1918
  "pattern": "toolbar",
1903
1919
  "alternatives": [
1904
- { "name": "Menubar", "when": "the controls are named menus of commands, like an app's File and Edit" }
1920
+ { "name": "Menubar", "when": "the controls are named menus of commands, like an app's File and Edit" },
1921
+ { "name": "ActionBar", "when": "a summary and the primary actions close out a long list or form, docked to its bottom" }
1905
1922
  ]
1906
1923
  },
1907
1924
  {