@sybilion/uilib 1.3.93 → 1.3.95

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 (233) hide show
  1. package/assets/globals.css +98 -0
  2. package/dist/esm/components/ui/Badge/Badge.styl.js +1 -1
  3. package/dist/esm/components/ui/BarChart/BarChart.js +32 -0
  4. package/dist/esm/components/ui/BarChart/BarChart.styl.js +7 -0
  5. package/dist/esm/components/ui/Button/Button.js +1 -1
  6. package/dist/esm/components/ui/Button/Button.styl.js +1 -1
  7. package/dist/esm/components/ui/Card/Card.styl.js +1 -1
  8. package/dist/esm/components/ui/Chart/Chart.helpers.js +15 -3
  9. package/dist/esm/components/ui/Chart/chartSeriesPalette.js +17 -0
  10. package/dist/esm/components/ui/Chat/ChatSheet/ChatSelector.js +2 -2
  11. package/dist/esm/components/ui/Checkbox/Checkbox.styl.js +1 -1
  12. package/dist/esm/components/ui/Chip/Chip.js +12 -0
  13. package/dist/esm/components/ui/Chip/Chip.styl.js +7 -0
  14. package/dist/esm/components/ui/DonutChart/DonutChart.js +35 -0
  15. package/dist/esm/components/ui/DonutChart/DonutChart.styl.js +7 -0
  16. package/dist/esm/components/ui/Input/Input.styl.js +1 -1
  17. package/dist/esm/components/ui/Kicker/Kicker.js +9 -0
  18. package/dist/esm/components/ui/Kicker/Kicker.styl.js +7 -0
  19. package/dist/esm/components/ui/LabeledInput/LabeledInput.styl.js +1 -1
  20. package/dist/esm/components/ui/PullQuote/PullQuote.js +9 -0
  21. package/dist/esm/components/ui/PullQuote/PullQuote.styl.js +7 -0
  22. package/dist/esm/components/ui/Select/Select.styl.js +1 -1
  23. package/dist/esm/components/ui/Sidebar/Sidebar.styl.js +1 -1
  24. package/dist/esm/components/ui/SignalCard/SignalCard.js +17 -0
  25. package/dist/esm/components/ui/SignalCard/SignalCard.styl.js +7 -0
  26. package/dist/esm/components/ui/Switch/Switch.styl.js +1 -1
  27. package/dist/esm/components/ui/Table/Table.js +4 -4
  28. package/dist/esm/components/ui/Table/Table.styl.js +2 -2
  29. package/dist/esm/components/ui/Tooltip/Tooltip.styl.js +1 -1
  30. package/dist/esm/index.js +6 -0
  31. package/dist/esm/types/src/components/ui/BarChart/BarChart.d.ts +3 -0
  32. package/dist/esm/types/src/components/ui/BarChart/BarChart.types.d.ts +28 -0
  33. package/dist/esm/types/src/components/ui/BarChart/index.d.ts +2 -0
  34. package/dist/esm/types/src/components/ui/Chart/chartSeriesPalette.d.ts +6 -0
  35. package/dist/esm/types/src/components/ui/Chip/Chip.d.ts +3 -0
  36. package/dist/esm/types/src/components/ui/Chip/Chip.types.d.ts +13 -0
  37. package/dist/esm/types/src/components/ui/Chip/index.d.ts +2 -0
  38. package/dist/esm/types/src/components/ui/DonutChart/DonutChart.d.ts +3 -0
  39. package/dist/esm/types/src/components/ui/DonutChart/DonutChart.types.d.ts +25 -0
  40. package/dist/esm/types/src/components/ui/DonutChart/index.d.ts +2 -0
  41. package/dist/esm/types/src/components/ui/Kicker/Kicker.d.ts +3 -0
  42. package/dist/esm/types/src/components/ui/Kicker/Kicker.types.d.ts +5 -0
  43. package/dist/esm/types/src/components/ui/Kicker/index.d.ts +2 -0
  44. package/dist/esm/types/src/components/ui/PullQuote/PullQuote.d.ts +3 -0
  45. package/dist/esm/types/src/components/ui/PullQuote/PullQuote.types.d.ts +7 -0
  46. package/dist/esm/types/src/components/ui/PullQuote/index.d.ts +2 -0
  47. package/dist/esm/types/src/components/ui/Select/Select.types.d.ts +1 -1
  48. package/dist/esm/types/src/components/ui/SignalCard/SignalCard.d.ts +3 -0
  49. package/dist/esm/types/src/components/ui/SignalCard/SignalCard.types.d.ts +23 -0
  50. package/dist/esm/types/src/components/ui/SignalCard/index.d.ts +2 -0
  51. package/dist/esm/types/src/components/ui/Table/Table.d.ts +2 -5
  52. package/dist/esm/types/src/components/ui/Table/Table.types.d.ts +4 -1
  53. package/dist/esm/types/src/components/ui/Table/index.d.ts +1 -1
  54. package/dist/esm/types/src/docs/components/DocsGuidance/DocsGuidance.d.ts +14 -0
  55. package/dist/esm/types/src/docs/pages/BarChartPage.d.ts +1 -0
  56. package/dist/esm/types/src/docs/pages/ChipPage.d.ts +1 -0
  57. package/dist/esm/types/src/docs/pages/ColorsPage.d.ts +1 -0
  58. package/dist/esm/types/src/docs/pages/DonutChartPage.d.ts +1 -0
  59. package/dist/esm/types/src/docs/pages/IconsPage.d.ts +1 -0
  60. package/dist/esm/types/src/docs/pages/KickerPage.d.ts +1 -0
  61. package/dist/esm/types/src/docs/pages/MotionPage.d.ts +1 -0
  62. package/dist/esm/types/src/docs/pages/PullQuotePage.d.ts +1 -0
  63. package/dist/esm/types/src/docs/pages/RadiiShadowsPage.d.ts +1 -0
  64. package/dist/esm/types/src/docs/pages/SignalCardPage.d.ts +1 -0
  65. package/dist/esm/types/src/docs/pages/SpacingPage.d.ts +1 -0
  66. package/dist/esm/types/src/docs/pages/TypographyPage.d.ts +1 -0
  67. package/dist/esm/types/src/docs/registry.d.ts +1 -1
  68. package/dist/esm/types/src/index.d.ts +6 -0
  69. package/dist/esm/types/tests/charts.test.d.ts +1 -0
  70. package/dist/esm/types/tests/chip.test.d.ts +1 -0
  71. package/dist/esm/types/tests/componentsSmoke.test.d.ts +1 -0
  72. package/dist/esm/types/tests/docsRegistry.test.d.ts +1 -0
  73. package/dist/esm/types/tests/iconsPageFilter.test.d.ts +1 -0
  74. package/dist/esm/types/tests/mocks/homecodeUiMock.d.ts +32 -1
  75. package/dist/esm/types/tests/mocks/lightweightChartsMock.d.ts +29 -0
  76. package/dist/esm/types/tests/pullQuoteKicker.test.d.ts +1 -0
  77. package/dist/esm/types/tests/signalCard.test.d.ts +1 -0
  78. package/dist/esm/types/tests/tokenSync.test.d.ts +1 -0
  79. package/package.json +1 -1
  80. package/src/components/ui/Badge/Badge.styl +4 -4
  81. package/src/components/ui/BarChart/BarChart.styl +2 -0
  82. package/src/components/ui/BarChart/BarChart.styl.d.ts +7 -0
  83. package/src/components/ui/BarChart/BarChart.tsx +142 -0
  84. package/src/components/ui/BarChart/BarChart.types.ts +36 -0
  85. package/src/components/ui/BarChart/index.ts +2 -0
  86. package/src/components/ui/Button/Button.styl +30 -28
  87. package/src/components/ui/Button/Button.tsx +2 -1
  88. package/src/components/ui/Card/Card.styl +4 -3
  89. package/src/components/ui/Chart/Chart.helpers.ts +17 -3
  90. package/src/components/ui/Chart/chartSeriesPalette.ts +16 -0
  91. package/src/components/ui/Chat/ChatSheet/ChatSelector.tsx +2 -2
  92. package/src/components/ui/Checkbox/Checkbox.styl +1 -1
  93. package/src/components/ui/Chip/Chip.styl +78 -0
  94. package/src/components/ui/Chip/Chip.styl.d.ts +16 -0
  95. package/src/components/ui/Chip/Chip.tsx +35 -0
  96. package/src/components/ui/Chip/Chip.types.ts +23 -0
  97. package/src/components/ui/Chip/index.ts +2 -0
  98. package/src/components/ui/DonutChart/DonutChart.styl +16 -0
  99. package/src/components/ui/DonutChart/DonutChart.styl.d.ts +10 -0
  100. package/src/components/ui/DonutChart/DonutChart.tsx +112 -0
  101. package/src/components/ui/DonutChart/DonutChart.types.ts +30 -0
  102. package/src/components/ui/DonutChart/index.ts +2 -0
  103. package/src/components/ui/Input/Input.styl +2 -2
  104. package/src/components/ui/Kicker/Kicker.styl +10 -0
  105. package/src/components/ui/Kicker/Kicker.styl.d.ts +7 -0
  106. package/src/components/ui/Kicker/Kicker.tsx +15 -0
  107. package/src/components/ui/Kicker/Kicker.types.ts +6 -0
  108. package/src/components/ui/Kicker/index.ts +2 -0
  109. package/src/components/ui/LabeledInput/LabeledInput.styl +4 -1
  110. package/src/components/ui/PullQuote/PullQuote.styl +32 -0
  111. package/src/components/ui/PullQuote/PullQuote.styl.d.ts +10 -0
  112. package/src/components/ui/PullQuote/PullQuote.tsx +31 -0
  113. package/src/components/ui/PullQuote/PullQuote.types.ts +8 -0
  114. package/src/components/ui/PullQuote/index.ts +2 -0
  115. package/src/components/ui/Select/Select.styl +21 -14
  116. package/src/components/ui/Select/Select.types.ts +1 -1
  117. package/src/components/ui/Sidebar/Sidebar.styl +1 -0
  118. package/src/components/ui/SignalCard/SignalCard.styl +104 -0
  119. package/src/components/ui/SignalCard/SignalCard.styl.d.ts +20 -0
  120. package/src/components/ui/SignalCard/SignalCard.tsx +87 -0
  121. package/src/components/ui/SignalCard/SignalCard.types.ts +24 -0
  122. package/src/components/ui/SignalCard/index.ts +2 -0
  123. package/src/components/ui/Switch/Switch.styl +7 -7
  124. package/src/components/ui/Table/Table.styl +26 -8
  125. package/src/components/ui/Table/Table.styl.d.ts +0 -1
  126. package/src/components/ui/Table/Table.tsx +5 -3
  127. package/src/components/ui/Table/Table.types.ts +8 -4
  128. package/src/components/ui/Table/index.ts +1 -1
  129. package/src/components/ui/Tooltip/Tooltip.styl +2 -2
  130. package/src/contexts/chatPersistence.test.ts +13 -2
  131. package/src/docs/components/DocsGuidance/DocsGuidance.styl +33 -0
  132. package/src/docs/components/DocsGuidance/DocsGuidance.styl.d.ts +11 -0
  133. package/src/docs/components/DocsGuidance/DocsGuidance.tsx +57 -0
  134. package/src/docs/pages/AnalysesSelectorPage.tsx +16 -0
  135. package/src/docs/pages/AnalysisLineIconPage.tsx +12 -0
  136. package/src/docs/pages/AvatarPage.tsx +15 -0
  137. package/src/docs/pages/BadgePage.tsx +16 -0
  138. package/src/docs/pages/BarChartPage.tsx +109 -0
  139. package/src/docs/pages/BreadcrumbPage.tsx +15 -0
  140. package/src/docs/pages/ButtonPage.tsx +17 -0
  141. package/src/docs/pages/CardPage.tsx +190 -17
  142. package/src/docs/pages/ChartAreaInteractivePage.tsx +24 -7
  143. package/src/docs/pages/ChartPage.tsx +14 -0
  144. package/src/docs/pages/ChatAttachmentsDropzonePage.tsx +15 -0
  145. package/src/docs/pages/ChatComposerPrefillPage.tsx +15 -0
  146. package/src/docs/pages/ChatPage.tsx +15 -0
  147. package/src/docs/pages/ChatSheetPage.tsx +14 -0
  148. package/src/docs/pages/ChatSlashCommandsPage.tsx +15 -0
  149. package/src/docs/pages/ChatUserCsvAttachmentPage.tsx +14 -0
  150. package/src/docs/pages/CheckboxPage.tsx +37 -4
  151. package/src/docs/pages/ChipPage.tsx +160 -0
  152. package/src/docs/pages/ColorsPage.styl +27 -0
  153. package/src/docs/pages/ColorsPage.styl.d.ts +12 -0
  154. package/src/docs/pages/ColorsPage.tsx +102 -0
  155. package/src/docs/pages/ConfirmPage.tsx +15 -0
  156. package/src/docs/pages/DialogPage.tsx +15 -0
  157. package/src/docs/pages/DonutChartPage.tsx +80 -0
  158. package/src/docs/pages/DrawerPage.tsx +17 -0
  159. package/src/docs/pages/DriverMapPage.tsx +17 -0
  160. package/src/docs/pages/DriversComparisonChartPage.tsx +17 -0
  161. package/src/docs/pages/DropZonePage.tsx +16 -0
  162. package/src/docs/pages/DropdownMenuPage.tsx +16 -0
  163. package/src/docs/pages/FileChipPage.tsx +17 -0
  164. package/src/docs/pages/FlickeringGridPage.tsx +15 -0
  165. package/src/docs/pages/FoldablePage.tsx +16 -0
  166. package/src/docs/pages/GridLayoutPage.tsx +16 -0
  167. package/src/docs/pages/IconsPage.styl +74 -0
  168. package/src/docs/pages/IconsPage.styl.d.ts +17 -0
  169. package/src/docs/pages/IconsPage.tsx +125 -0
  170. package/src/docs/pages/ImagePage.tsx +16 -0
  171. package/src/docs/pages/ImageWithFallbackPage.tsx +15 -0
  172. package/src/docs/pages/IncludeHiddenInYScalePage.tsx +14 -0
  173. package/src/docs/pages/InputPage.tsx +134 -19
  174. package/src/docs/pages/InteractiveContentPage.tsx +15 -0
  175. package/src/docs/pages/KickerPage.tsx +62 -0
  176. package/src/docs/pages/LabelPage.tsx +15 -0
  177. package/src/docs/pages/LabelWithIdPage.tsx +11 -0
  178. package/src/docs/pages/LabeledInputPage.tsx +12 -0
  179. package/src/docs/pages/LegacyPlatformLinkPage.tsx +15 -0
  180. package/src/docs/pages/LightweightChartPage.styl +0 -1
  181. package/src/docs/pages/LightweightChartPage.tsx +17 -0
  182. package/src/docs/pages/LogoPage.tsx +15 -0
  183. package/src/docs/pages/MobileAdaptiveSelectorPage.tsx +15 -0
  184. package/src/docs/pages/MotionPage.styl +71 -0
  185. package/src/docs/pages/MotionPage.styl.d.ts +17 -0
  186. package/src/docs/pages/MotionPage.tsx +176 -0
  187. package/src/docs/pages/NavUserHeaderPage.tsx +15 -0
  188. package/src/docs/pages/NumberControlPage.tsx +15 -0
  189. package/src/docs/pages/PageColumnsPage.tsx +15 -0
  190. package/src/docs/pages/PageFooterPage.tsx +15 -0
  191. package/src/docs/pages/PagePage.tsx +15 -0
  192. package/src/docs/pages/PageTabsPage.tsx +18 -0
  193. package/src/docs/pages/PerformanceChartPage.tsx +15 -0
  194. package/src/docs/pages/ProgressPage.tsx +66 -3
  195. package/src/docs/pages/PullQuotePage.tsx +59 -0
  196. package/src/docs/pages/RadiiShadowsPage.styl +47 -0
  197. package/src/docs/pages/RadiiShadowsPage.styl.d.ts +14 -0
  198. package/src/docs/pages/RadiiShadowsPage.tsx +109 -0
  199. package/src/docs/pages/RegionCoordsPage.tsx +12 -0
  200. package/src/docs/pages/RenamerPage.tsx +15 -0
  201. package/src/docs/pages/SelectPage.tsx +160 -6
  202. package/src/docs/pages/SeparatorPage.tsx +12 -0
  203. package/src/docs/pages/SheetPage.tsx +15 -0
  204. package/src/docs/pages/SidebarDatasetsItemsGroupedPage.tsx +12 -0
  205. package/src/docs/pages/SidebarPage.tsx +15 -0
  206. package/src/docs/pages/SignalCardPage.tsx +126 -0
  207. package/src/docs/pages/SkeletonPage.tsx +16 -0
  208. package/src/docs/pages/SliderPage.tsx +70 -4
  209. package/src/docs/pages/SmartTextTruncatePage.styl +13 -0
  210. package/src/docs/pages/SmartTextTruncatePage.styl.d.ts +8 -0
  211. package/src/docs/pages/SmartTextTruncatePage.tsx +17 -4
  212. package/src/docs/pages/SpacingPage.styl +31 -0
  213. package/src/docs/pages/SpacingPage.styl.d.ts +12 -0
  214. package/src/docs/pages/SpacingPage.tsx +50 -0
  215. package/src/docs/pages/SparklinePage.tsx +15 -0
  216. package/src/docs/pages/StandaloneAppLayoutPage/StandaloneAppLayoutPage.tsx +16 -0
  217. package/src/docs/pages/SwitchPage.tsx +147 -8
  218. package/src/docs/pages/SybilionAuthLayoutPage.tsx +15 -0
  219. package/src/docs/pages/TablePage.tsx +132 -20
  220. package/src/docs/pages/TabsPage.tsx +20 -0
  221. package/src/docs/pages/TextShimmerPage.tsx +12 -0
  222. package/src/docs/pages/TextWithDeferTooltipPage.tsx +15 -0
  223. package/src/docs/pages/TimeRangeControlsPage.tsx +15 -0
  224. package/src/docs/pages/ToggleGroupPage.tsx +15 -0
  225. package/src/docs/pages/TogglePage.tsx +13 -0
  226. package/src/docs/pages/TooltipPage.tsx +17 -0
  227. package/src/docs/pages/TypographyPage.styl +42 -0
  228. package/src/docs/pages/TypographyPage.styl.d.ts +12 -0
  229. package/src/docs/pages/TypographyPage.tsx +226 -0
  230. package/src/docs/pages/VimeoEmbedPage.tsx +12 -0
  231. package/src/docs/pages/WorldMapPage.tsx +12 -0
  232. package/src/docs/registry.ts +79 -0
  233. package/src/index.ts +6 -0
@@ -0,0 +1,30 @@
1
+ import { HTMLAttributes, ReactNode } from 'react';
2
+
3
+ export interface DonutChartDatum {
4
+ /** Unique slice key; used for tooltip/legend label lookups. */
5
+ key: string;
6
+ value: number;
7
+ /** Human-readable label; falls back to the key. */
8
+ label?: ReactNode;
9
+ /** CSS colour; falls back to the built-in series palette. */
10
+ color?: string;
11
+ }
12
+
13
+ export interface DonutChartProps extends Omit<
14
+ HTMLAttributes<HTMLDivElement>,
15
+ 'children'
16
+ > {
17
+ data: DonutChartDatum[];
18
+ /** Radius of the donut hole; px number or percentage string. */
19
+ innerRadius?: number | string;
20
+ /** Outer radius of the donut; px number or percentage string. */
21
+ outerRadius?: number | string;
22
+ /** Large figure rendered in the centre of the donut hole. */
23
+ centerValue?: string | number;
24
+ /** Small caption rendered under the centre value. */
25
+ centerCaption?: string;
26
+ showLegend?: boolean;
27
+ showTooltip?: boolean;
28
+ /** Fixed chart height in px; defaults to a square capped at 320px. */
29
+ height?: number;
30
+ }
@@ -0,0 +1,2 @@
1
+ export * from './DonutChart';
2
+ export * from './DonutChart.types';
@@ -8,8 +8,8 @@
8
8
  transition-duration 150ms
9
9
 
10
10
  &.variant-default
11
- padding 4px 12px
12
- border-radius var(--p-4)
11
+ padding 11px 14px
12
+ border-radius var(--radius-input)
13
13
  box-shadow 0 0 0 1px var(--border)
14
14
 
15
15
  &:focus
@@ -0,0 +1,10 @@
1
+ .root
2
+ font-family var(--font-family-body)
3
+ font-size var(--text-xs)
4
+ font-weight 500
5
+ line-height var(--lh-normal)
6
+ letter-spacing var(--tracking-body)
7
+ color var(--sb-slate-800)
8
+
9
+ :global(.dark) &
10
+ color var(--sb-cyan-400)
@@ -0,0 +1,7 @@
1
+ // This file is automatically generated.
2
+ // Please do not change this file!
3
+ interface CssExports {
4
+ 'root': string;
5
+ }
6
+ export const cssExports: CssExports;
7
+ export default cssExports;
@@ -0,0 +1,15 @@
1
+ import cn from 'classnames';
2
+
3
+ import S from './Kicker.styl';
4
+ import { KickerProps } from './Kicker.types';
5
+
6
+ function Kicker({ className, dash = false, children, ...props }: KickerProps) {
7
+ return (
8
+ <div data-slot="kicker" className={cn(S.root, className)} {...props}>
9
+ {dash && <span aria-hidden="true">{'\u2014 '}</span>}
10
+ {children}
11
+ </div>
12
+ );
13
+ }
14
+
15
+ export { Kicker };
@@ -0,0 +1,6 @@
1
+ import { type ComponentProps } from 'react';
2
+
3
+ export interface KickerProps extends ComponentProps<'div'> {
4
+ /** Render a leading em-dash before the label text. */
5
+ dash?: boolean;
6
+ }
@@ -0,0 +1,2 @@
1
+ export { Kicker } from './Kicker';
2
+ export type { KickerProps } from './Kicker.types';
@@ -3,7 +3,10 @@
3
3
 
4
4
  .label
5
5
  margin-bottom 0
6
- padding-bottom var(--p-1)
6
+ padding-bottom var(--spacing-xs)
7
+
8
+ .root &
9
+ font-size var(--text-2xs)
7
10
 
8
11
  .inputWrapper
9
12
  position relative
@@ -0,0 +1,32 @@
1
+ .root
2
+ border-left 2px solid var(--sb-cyan-400)
3
+ padding 6px 0 6px 20px
4
+
5
+ .body
6
+ font-family var(--font-family-heading)
7
+ font-size var(--text-2xl)
8
+ line-height 1.25
9
+ font-weight 400
10
+ letter-spacing var(--tracking-heading)
11
+ color var(--sb-slate-800)
12
+ text-wrap pretty
13
+
14
+ :global(.dark) &
15
+ color var(--sb-slate-200)
16
+
17
+ // Small text — Manrope, sentence case, zero tracking
18
+ .attribution
19
+ margin-top var(--p-4)
20
+ font-family var(--font-family-body)
21
+ font-size var(--text-xs)
22
+ font-weight 500
23
+ letter-spacing var(--tracking-body)
24
+ color var(--sb-slate-800)
25
+
26
+ :global(.dark) &
27
+ color var(--sb-slate-300)
28
+
29
+ .role
30
+ margin-left 6px
31
+ font-weight 400
32
+ color var(--sb-slate-500)
@@ -0,0 +1,10 @@
1
+ // This file is automatically generated.
2
+ // Please do not change this file!
3
+ interface CssExports {
4
+ 'attribution': string;
5
+ 'body': string;
6
+ 'role': string;
7
+ 'root': string;
8
+ }
9
+ export const cssExports: CssExports;
10
+ export default cssExports;
@@ -0,0 +1,31 @@
1
+ import cn from 'classnames';
2
+
3
+ import S from './PullQuote.styl';
4
+ import { PullQuoteProps } from './PullQuote.types';
5
+
6
+ function PullQuote({
7
+ className,
8
+ attribution,
9
+ attributionRole,
10
+ children,
11
+ ...props
12
+ }: PullQuoteProps) {
13
+ return (
14
+ <figure data-slot="pull-quote" className={cn(S.root, className)} {...props}>
15
+ <blockquote className={S.body}>{children}</blockquote>
16
+ {attribution != null && (
17
+ <figcaption className={S.attribution}>
18
+ {attribution}
19
+ {attributionRole != null && (
20
+ <span className={S.role}>
21
+ {'\u00b7 '}
22
+ {attributionRole}
23
+ </span>
24
+ )}
25
+ </figcaption>
26
+ )}
27
+ </figure>
28
+ );
29
+ }
30
+
31
+ export { PullQuote };
@@ -0,0 +1,8 @@
1
+ import { type ComponentProps, type ReactNode } from 'react';
2
+
3
+ export interface PullQuoteProps extends ComponentProps<'figure'> {
4
+ /** Name of the person quoted. */
5
+ attribution?: ReactNode;
6
+ /** Role or affiliation shown after the attribution, sentence case. */
7
+ attributionRole?: ReactNode;
8
+ }
@@ -0,0 +1,2 @@
1
+ export { PullQuote } from './PullQuote';
2
+ export type { PullQuoteProps } from './PullQuote.types';
@@ -10,8 +10,8 @@
10
10
  overflow hidden
11
11
 
12
12
  padding var(--p-1) var(--p-3)
13
- // Match ToggleGroup_item styling
14
- border-radius var(--p-4)
13
+ // Match Input styling
14
+ border-radius var(--radius-input)
15
15
  border none
16
16
  box-shadow none
17
17
  background-color var(--background)
@@ -46,26 +46,33 @@
46
46
  box-shadow 0 0 0 2px var(--background)
47
47
  // color var(--muted-foreground)
48
48
 
49
- &[data-size="sm"]
49
+ &[data-size="xs"]
50
50
  height auto
51
51
  min-height 28px
52
- padding 0 var(--p-4)
52
+ padding 0 10px
53
53
  border-radius var(--p-4)
54
54
  font-size var(--text-xs)
55
55
 
56
+ &[data-size="sm"]
57
+ height auto
58
+ min-height 32px
59
+ padding 0 14px
60
+ border-radius var(--radius-3)
61
+ font-size 13px
62
+
56
63
  &[data-size="md"]
57
64
  height auto
58
65
  min-height 40px
59
- padding var(--p-3) var(--p-4)
60
- border-radius var(--p-4)
66
+ padding 11px 14px
67
+ border-radius var(--radius-input)
61
68
  font-size var(--text-sm)
62
69
 
63
70
  &[data-size="lg"]
64
71
  height auto
65
- min-height auto
72
+ min-height 48px
66
73
  padding var(--p-4) var(--p-6)
67
- border-radius var(--p-4)
68
- font-size var(--text-sm)
74
+ border-radius var(--radius-4)
75
+ font-size var(--text-base)
69
76
 
70
77
  &[data-placeholder]
71
78
  color var(--muted-foreground)
@@ -128,7 +135,7 @@
128
135
  max-height var(--radix-select-content-available-height)
129
136
  // Match Tooltip tooltipContent styling
130
137
  background-color var(--popover)
131
- border-radius var(--p-4)
138
+ border-radius var(--radius-input)
132
139
  box-shadow 0 10px 15px -3px rgba(0, 0, 0, 0.1)
133
140
  border 1px solid var(--border)
134
141
  color var(--popover-foreground)
@@ -203,12 +210,12 @@
203
210
  background-color var(--accent)
204
211
 
205
212
  &:first-child
206
- border-top-left-radius var(--p-3)
207
- border-top-right-radius var(--p-3)
213
+ border-top-left-radius var(--radius-md)
214
+ border-top-right-radius var(--radius-md)
208
215
 
209
216
  &:last-child
210
- border-bottom-left-radius var(--p-3)
211
- border-bottom-right-radius var(--p-3)
217
+ border-bottom-left-radius var(--radius-md)
218
+ border-bottom-right-radius var(--radius-md)
212
219
 
213
220
  &:focus
214
221
  background-color var(--accent)
@@ -3,7 +3,7 @@ import * as SelectPrimitive from '@radix-ui/react-select';
3
3
  export interface SelectTriggerProps extends React.ComponentProps<
4
4
  typeof SelectPrimitive.Trigger
5
5
  > {
6
- size?: 'sm' | 'md' | 'lg';
6
+ size?: 'xs' | 'sm' | 'md' | 'lg';
7
7
  variant?: 'default' | 'clear';
8
8
  darker?: boolean;
9
9
  className?: string;
@@ -75,6 +75,7 @@
75
75
  .sidebarTrigger
76
76
  width var(--p-5)
77
77
  height var(--p-5)
78
+ margin-left calc(-1 * var(--p-4))
78
79
  cursor pointer
79
80
 
80
81
  svg
@@ -0,0 +1,104 @@
1
+ .root
2
+ gap 14px
3
+ padding var(--p-5)
4
+ box-shadow none
5
+ transition border-color var(--dur-base) var(--ease-standard), box-shadow var(--dur-base) var(--ease-standard)
6
+
7
+ &:hover
8
+ border-color var(--muted-border)
9
+ box-shadow var(--shadow-2)
10
+
11
+ .head
12
+ align-items center
13
+ gap 12px
14
+ justify-content flex-start
15
+
16
+ .headText
17
+ display flex
18
+ flex-direction column
19
+ gap 2px
20
+ min-width 0
21
+
22
+ .title
23
+ font-family var(--font-family-body)
24
+ font-size var(--text-base)
25
+ font-weight 600
26
+ line-height normal
27
+ color var(--sb-slate-900)
28
+
29
+ :global(.dark) &
30
+ color var(--sb-slate-100)
31
+
32
+ .subtitle
33
+ font-family var(--font-family-body)
34
+ font-size 13px
35
+ color var(--sb-slate-500)
36
+
37
+ :global(.dark) &
38
+ color var(--sb-slate-400)
39
+
40
+ .content
41
+ display flex
42
+ flex-direction column
43
+ gap 14px
44
+
45
+ // Numeric block — Manrope only, weight carries the emphasis
46
+ .figure
47
+ display flex
48
+ align-items baseline
49
+ gap 6px
50
+ font-family var(--font-family-body)
51
+ color var(--sb-slate-900)
52
+
53
+ :global(.dark) &
54
+ color var(--sb-slate-100)
55
+
56
+ .value
57
+ font-size var(--text-4xl)
58
+ font-weight 500
59
+ letter-spacing -0.05em
60
+ line-height 42px
61
+
62
+ .unit
63
+ font-size var(--text-base)
64
+ font-weight 500
65
+ letter-spacing var(--tracking-display)
66
+ color var(--sb-slate-800)
67
+
68
+ :global(.dark) &
69
+ color var(--sb-slate-300)
70
+
71
+ .tolerance
72
+ font-size var(--text-base)
73
+ font-weight 400
74
+ letter-spacing var(--tracking-display)
75
+ color var(--sb-slate-700)
76
+
77
+ :global(.dark) &
78
+ color var(--sb-slate-400)
79
+
80
+ .body
81
+ font-family var(--font-family-body)
82
+ font-size var(--text-sm)
83
+ line-height 1.5
84
+ color var(--sb-slate-800)
85
+
86
+ :global(.dark) &
87
+ color var(--sb-slate-300)
88
+
89
+ .sparkline
90
+ display flex
91
+ min-width 0
92
+
93
+ .foot
94
+ align-items baseline
95
+ justify-content flex-start
96
+ gap 12px
97
+ font-family var(--font-family-body)
98
+ font-size 13px
99
+
100
+ .dim
101
+ color var(--sb-slate-500)
102
+
103
+ :global(.dark) &
104
+ color var(--sb-slate-400)
@@ -0,0 +1,20 @@
1
+ // This file is automatically generated.
2
+ // Please do not change this file!
3
+ interface CssExports {
4
+ 'body': string;
5
+ 'content': string;
6
+ 'dim': string;
7
+ 'figure': string;
8
+ 'foot': string;
9
+ 'head': string;
10
+ 'headText': string;
11
+ 'root': string;
12
+ 'sparkline': string;
13
+ 'subtitle': string;
14
+ 'title': string;
15
+ 'tolerance': string;
16
+ 'unit': string;
17
+ 'value': string;
18
+ }
19
+ export const cssExports: CssExports;
20
+ export default cssExports;
@@ -0,0 +1,87 @@
1
+ import cn from 'classnames';
2
+
3
+ import {
4
+ Card,
5
+ CardContent,
6
+ CardFooter,
7
+ CardHeader,
8
+ } from '../Card';
9
+ import { Kicker } from '../Kicker';
10
+ import S from './SignalCard.styl';
11
+ import { SignalCardProps } from './SignalCard.types';
12
+
13
+ function SignalCard({
14
+ className,
15
+ kicker,
16
+ icon,
17
+ title,
18
+ subtitle,
19
+ value,
20
+ unit,
21
+ tolerance,
22
+ description,
23
+ delta,
24
+ meta,
25
+ sparkline,
26
+ children,
27
+ ...props
28
+ }: SignalCardProps) {
29
+ const hasHead = icon != null || title != null || subtitle != null;
30
+ const hasFooter = delta != null || (meta?.length ?? 0) > 0;
31
+ const hasContent =
32
+ value != null ||
33
+ description != null ||
34
+ sparkline != null ||
35
+ children != null;
36
+
37
+ return (
38
+ <Card
39
+ data-slot="signal-card"
40
+ paddingSize="s"
41
+ className={cn(S.root, className)}
42
+ {...props}
43
+ >
44
+ {kicker != null && <Kicker>{kicker}</Kicker>}
45
+ {hasHead && (
46
+ <CardHeader
47
+ className={S.head}
48
+ icon={icon}
49
+ iconWithBackground
50
+ title={title}
51
+ titleClassName={S.title}
52
+ description={subtitle}
53
+ descriptionClassName={S.subtitle}
54
+ textsClassName={S.headText}
55
+ />
56
+ )}
57
+ {hasContent && (
58
+ <CardContent noScroll className={S.content}>
59
+ {value != null && (
60
+ <div className={S.figure}>
61
+ <span className={S.value}>{value}</span>
62
+ {unit != null && <span className={S.unit}>{unit}</span>}
63
+ {tolerance != null && (
64
+ <span className={S.tolerance}>{tolerance}</span>
65
+ )}
66
+ </div>
67
+ )}
68
+ {description != null && <div className={S.body}>{description}</div>}
69
+ {sparkline != null && <div className={S.sparkline}>{sparkline}</div>}
70
+ {children}
71
+ </CardContent>
72
+ )}
73
+ {hasFooter && (
74
+ <CardFooter className={S.foot}>
75
+ {delta}
76
+ {meta?.map((item, index) => (
77
+ <span key={index} className={S.dim}>
78
+ {item}
79
+ </span>
80
+ ))}
81
+ </CardFooter>
82
+ )}
83
+ </Card>
84
+ );
85
+ }
86
+
87
+ export { SignalCard };
@@ -0,0 +1,24 @@
1
+ import { type ComponentProps, type ReactNode } from 'react';
2
+
3
+ export interface SignalCardProps extends Omit<ComponentProps<'div'>, 'title'> {
4
+ /** Eyebrow label rendered above the header. */
5
+ kicker?: ReactNode;
6
+ /** Icon rendered in the 40px square header badge. */
7
+ icon?: ReactNode;
8
+ title?: ReactNode;
9
+ subtitle?: ReactNode;
10
+ /** Large metric figure. */
11
+ value?: ReactNode;
12
+ /** Unit suffix rendered after the figure, e.g. "/t". */
13
+ unit?: ReactNode;
14
+ /** Tolerance suffix rendered after the unit, e.g. "± 0.001". */
15
+ tolerance?: ReactNode;
16
+ /** Body copy rendered under the figure. */
17
+ description?: ReactNode;
18
+ /** Delta indicator rendered in the footer, typically a Chip. */
19
+ delta?: ReactNode;
20
+ /** Muted footer meta items, e.g. horizon and confidence. */
21
+ meta?: ReactNode[];
22
+ /** Optional sparkline slot. */
23
+ sparkline?: ReactNode;
24
+ }
@@ -0,0 +1,2 @@
1
+ export { SignalCard } from './SignalCard';
2
+ export type { SignalCardProps } from './SignalCard.types';
@@ -1,7 +1,7 @@
1
1
  .switchRoot
2
2
  position relative
3
3
  display inline-flex
4
- padding 2px
4
+ padding 3px
5
5
  flex-shrink 0
6
6
  cursor pointer
7
7
  border-radius 9999px
@@ -34,8 +34,8 @@
34
34
  height 20px
35
35
 
36
36
  .switchThumb
37
- width 16px
38
- height 16px
37
+ width 14px
38
+ height 14px
39
39
 
40
40
  &[data-state=checked] .switchThumb
41
41
  transform translateX(16px)
@@ -45,8 +45,8 @@
45
45
  height 24px
46
46
 
47
47
  .switchThumb
48
- width 20px
49
- height 20px
48
+ width 18px
49
+ height 18px
50
50
 
51
51
  &[data-state=checked] .switchThumb
52
52
  transform translateX(20px)
@@ -56,8 +56,8 @@
56
56
  height 28px
57
57
 
58
58
  .switchThumb
59
- width 24px
60
- height 24px
59
+ width 22px
60
+ height 22px
61
61
 
62
62
  &[data-state=checked] .switchThumb
63
63
  transform translateX(24px)
@@ -20,9 +20,33 @@
20
20
  .table
21
21
  width 100%
22
22
  caption-side bottom
23
- font-size 14px
23
+ font-size var(--text-sm)
24
24
  overflow hidden
25
25
 
26
+ &[data-size="sm"]
27
+ font-size var(--text-xs)
28
+
29
+ .tableHead
30
+ .tableCell
31
+ padding var(--p-2) var(--p-3)
32
+ height auto
33
+
34
+ &[data-size="md"]
35
+ font-size var(--text-sm)
36
+
37
+ .tableHead
38
+ .tableCell
39
+ padding var(--p-4) var(--p-3)
40
+ height 65px
41
+
42
+ &[data-size="lg"]
43
+ font-size var(--text-base)
44
+
45
+ .tableHead
46
+ .tableCell
47
+ padding var(--p-5) var(--p-4)
48
+ height auto
49
+
26
50
  &.withPaddings
27
51
  .tableHead:first-child
28
52
  .tableCell:first-child
@@ -62,6 +86,7 @@
62
86
 
63
87
  .tableRow
64
88
  position relative
89
+ border-bottom 1px solid var(--border)
65
90
  transition-property background-color, color, border-color, text-decoration-color, fill, stroke
66
91
  transition-timing-function cubic-bezier(0.4, 0, 0.2, 1)
67
92
  transition-duration 150ms
@@ -94,11 +119,8 @@
94
119
  .tableCell
95
120
  position relative
96
121
  z-index 1
97
- padding-left var(--p-2)
98
- padding-right var(--p-2)
99
122
  vertical-align middle
100
123
  white-space nowrap
101
- height 65px
102
124
  min-width 0
103
125
 
104
126
  &:has([role="checkbox"])
@@ -107,10 +129,6 @@
107
129
  [role="checkbox"]
108
130
  transform translateY(2px)
109
131
 
110
- .compact
111
- height auto
112
-
113
-
114
132
  .cellValue
115
133
  display flex
116
134
  align-items center
@@ -2,7 +2,6 @@
2
2
  // Please do not change this file!
3
3
  interface CssExports {
4
4
  'cellValue': string;
5
- 'compact': string;
6
5
  'scrollContainer': string;
7
6
  'scrollInner': string;
8
7
  'scrollbar': string;
@@ -14,13 +14,15 @@ import type {
14
14
 
15
15
  function Table({
16
16
  className,
17
+ size = 'md',
17
18
  withBackground = false,
18
19
  withPaddings = false,
19
20
  ...props
20
- }: TableProps & { withBackground?: boolean; withPaddings?: boolean }) {
21
+ }: TableProps) {
21
22
  return (
22
23
  <table
23
24
  data-slot="table"
25
+ data-size={size}
24
26
  className={cn(
25
27
  S.table,
26
28
  className,
@@ -82,11 +84,11 @@ function TableHead({ className, ...props }: TableHeadProps) {
82
84
  );
83
85
  }
84
86
 
85
- function TableCell({ className, compact, ...props }: TableCellProps) {
87
+ function TableCell({ className, ...props }: TableCellProps) {
86
88
  return (
87
89
  <td
88
90
  data-slot="table-cell"
89
- className={cn(S.tableCell, compact && S.compact, className)}
91
+ className={cn(S.tableCell, className)}
90
92
  {...props}
91
93
  />
92
94
  );