@sybilion/uilib 1.3.93 → 1.3.96
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.
- package/assets/globals.css +98 -0
- package/dist/esm/components/ui/Badge/Badge.styl.js +1 -1
- package/dist/esm/components/ui/BarChart/BarChart.js +32 -0
- package/dist/esm/components/ui/BarChart/BarChart.styl.js +7 -0
- package/dist/esm/components/ui/Button/Button.js +1 -1
- package/dist/esm/components/ui/Button/Button.styl.js +1 -1
- package/dist/esm/components/ui/Card/Card.styl.js +1 -1
- package/dist/esm/components/ui/Chart/Chart.helpers.js +15 -3
- package/dist/esm/components/ui/Chart/chartSeriesPalette.js +17 -0
- package/dist/esm/components/ui/Chat/ChatSheet/ChatSelector.js +2 -2
- package/dist/esm/components/ui/Checkbox/Checkbox.styl.js +1 -1
- package/dist/esm/components/ui/Chip/Chip.js +12 -0
- package/dist/esm/components/ui/Chip/Chip.styl.js +7 -0
- package/dist/esm/components/ui/DonutChart/DonutChart.js +35 -0
- package/dist/esm/components/ui/DonutChart/DonutChart.styl.js +7 -0
- package/dist/esm/components/ui/Input/Input.styl.js +1 -1
- package/dist/esm/components/ui/Kicker/Kicker.js +9 -0
- package/dist/esm/components/ui/Kicker/Kicker.styl.js +7 -0
- package/dist/esm/components/ui/LabeledInput/LabeledInput.styl.js +1 -1
- package/dist/esm/components/ui/PullQuote/PullQuote.js +9 -0
- package/dist/esm/components/ui/PullQuote/PullQuote.styl.js +7 -0
- package/dist/esm/components/ui/Select/Select.styl.js +1 -1
- package/dist/esm/components/ui/Sidebar/Sidebar.styl.js +1 -1
- package/dist/esm/components/ui/SignalCard/SignalCard.js +17 -0
- package/dist/esm/components/ui/SignalCard/SignalCard.styl.js +7 -0
- package/dist/esm/components/ui/Switch/Switch.styl.js +1 -1
- package/dist/esm/components/ui/Table/Table.js +4 -4
- package/dist/esm/components/ui/Table/Table.styl.js +2 -2
- package/dist/esm/components/ui/Tooltip/Tooltip.styl.js +1 -1
- package/dist/esm/components/widgets/PerformanceChart/PerformanceChart.styl.js +2 -2
- package/dist/esm/components/widgets/PerformanceChart/PerformanceTable.js +5 -5
- package/dist/esm/index.js +6 -0
- package/dist/esm/types/src/components/ui/BarChart/BarChart.d.ts +3 -0
- package/dist/esm/types/src/components/ui/BarChart/BarChart.types.d.ts +28 -0
- package/dist/esm/types/src/components/ui/BarChart/index.d.ts +2 -0
- package/dist/esm/types/src/components/ui/Chart/chartSeriesPalette.d.ts +6 -0
- package/dist/esm/types/src/components/ui/Chip/Chip.d.ts +3 -0
- package/dist/esm/types/src/components/ui/Chip/Chip.types.d.ts +13 -0
- package/dist/esm/types/src/components/ui/Chip/index.d.ts +2 -0
- package/dist/esm/types/src/components/ui/DonutChart/DonutChart.d.ts +3 -0
- package/dist/esm/types/src/components/ui/DonutChart/DonutChart.types.d.ts +25 -0
- package/dist/esm/types/src/components/ui/DonutChart/index.d.ts +2 -0
- package/dist/esm/types/src/components/ui/Kicker/Kicker.d.ts +3 -0
- package/dist/esm/types/src/components/ui/Kicker/Kicker.types.d.ts +5 -0
- package/dist/esm/types/src/components/ui/Kicker/index.d.ts +2 -0
- package/dist/esm/types/src/components/ui/PullQuote/PullQuote.d.ts +3 -0
- package/dist/esm/types/src/components/ui/PullQuote/PullQuote.types.d.ts +7 -0
- package/dist/esm/types/src/components/ui/PullQuote/index.d.ts +2 -0
- package/dist/esm/types/src/components/ui/Select/Select.types.d.ts +1 -1
- package/dist/esm/types/src/components/ui/SignalCard/SignalCard.d.ts +3 -0
- package/dist/esm/types/src/components/ui/SignalCard/SignalCard.types.d.ts +23 -0
- package/dist/esm/types/src/components/ui/SignalCard/index.d.ts +2 -0
- package/dist/esm/types/src/components/ui/Table/Table.d.ts +2 -5
- package/dist/esm/types/src/components/ui/Table/Table.types.d.ts +4 -1
- package/dist/esm/types/src/components/ui/Table/index.d.ts +1 -1
- package/dist/esm/types/src/docs/components/DocsGuidance/DocsGuidance.d.ts +14 -0
- package/dist/esm/types/src/docs/pages/BarChartPage.d.ts +1 -0
- package/dist/esm/types/src/docs/pages/ChipPage.d.ts +1 -0
- package/dist/esm/types/src/docs/pages/ColorsPage.d.ts +1 -0
- package/dist/esm/types/src/docs/pages/DonutChartPage.d.ts +1 -0
- package/dist/esm/types/src/docs/pages/IconsPage.d.ts +1 -0
- package/dist/esm/types/src/docs/pages/KickerPage.d.ts +1 -0
- package/dist/esm/types/src/docs/pages/MotionPage.d.ts +1 -0
- package/dist/esm/types/src/docs/pages/PullQuotePage.d.ts +1 -0
- package/dist/esm/types/src/docs/pages/RadiiShadowsPage.d.ts +1 -0
- package/dist/esm/types/src/docs/pages/SignalCardPage.d.ts +1 -0
- package/dist/esm/types/src/docs/pages/SpacingPage.d.ts +1 -0
- package/dist/esm/types/src/docs/pages/TypographyPage.d.ts +1 -0
- package/dist/esm/types/src/docs/registry.d.ts +1 -1
- package/dist/esm/types/src/index.d.ts +6 -0
- package/dist/esm/types/tests/charts.test.d.ts +1 -0
- package/dist/esm/types/tests/chip.test.d.ts +1 -0
- package/dist/esm/types/tests/componentsSmoke.test.d.ts +1 -0
- package/dist/esm/types/tests/docsRegistry.test.d.ts +1 -0
- package/dist/esm/types/tests/iconsPageFilter.test.d.ts +1 -0
- package/dist/esm/types/tests/mocks/homecodeUiMock.d.ts +32 -1
- package/dist/esm/types/tests/mocks/lightweightChartsMock.d.ts +29 -0
- package/dist/esm/types/tests/pullQuoteKicker.test.d.ts +1 -0
- package/dist/esm/types/tests/signalCard.test.d.ts +1 -0
- package/dist/esm/types/tests/tokenSync.test.d.ts +1 -0
- package/package.json +1 -1
- package/src/components/ui/Badge/Badge.styl +4 -4
- package/src/components/ui/BarChart/BarChart.styl +2 -0
- package/src/components/ui/BarChart/BarChart.styl.d.ts +7 -0
- package/src/components/ui/BarChart/BarChart.tsx +142 -0
- package/src/components/ui/BarChart/BarChart.types.ts +36 -0
- package/src/components/ui/BarChart/index.ts +2 -0
- package/src/components/ui/Button/Button.styl +30 -28
- package/src/components/ui/Button/Button.tsx +2 -1
- package/src/components/ui/Card/Card.styl +4 -3
- package/src/components/ui/Chart/Chart.helpers.ts +17 -3
- package/src/components/ui/Chart/chartSeriesPalette.ts +16 -0
- package/src/components/ui/Chat/ChatSheet/ChatSelector.tsx +2 -2
- package/src/components/ui/Checkbox/Checkbox.styl +1 -1
- package/src/components/ui/Chip/Chip.styl +78 -0
- package/src/components/ui/Chip/Chip.styl.d.ts +16 -0
- package/src/components/ui/Chip/Chip.tsx +35 -0
- package/src/components/ui/Chip/Chip.types.ts +23 -0
- package/src/components/ui/Chip/index.ts +2 -0
- package/src/components/ui/DonutChart/DonutChart.styl +16 -0
- package/src/components/ui/DonutChart/DonutChart.styl.d.ts +10 -0
- package/src/components/ui/DonutChart/DonutChart.tsx +112 -0
- package/src/components/ui/DonutChart/DonutChart.types.ts +30 -0
- package/src/components/ui/DonutChart/index.ts +2 -0
- package/src/components/ui/Input/Input.styl +2 -2
- package/src/components/ui/Kicker/Kicker.styl +10 -0
- package/src/components/ui/Kicker/Kicker.styl.d.ts +7 -0
- package/src/components/ui/Kicker/Kicker.tsx +15 -0
- package/src/components/ui/Kicker/Kicker.types.ts +6 -0
- package/src/components/ui/Kicker/index.ts +2 -0
- package/src/components/ui/LabeledInput/LabeledInput.styl +4 -1
- package/src/components/ui/PullQuote/PullQuote.styl +32 -0
- package/src/components/ui/PullQuote/PullQuote.styl.d.ts +10 -0
- package/src/components/ui/PullQuote/PullQuote.tsx +31 -0
- package/src/components/ui/PullQuote/PullQuote.types.ts +8 -0
- package/src/components/ui/PullQuote/index.ts +2 -0
- package/src/components/ui/Select/Select.styl +21 -14
- package/src/components/ui/Select/Select.types.ts +1 -1
- package/src/components/ui/Sidebar/Sidebar.styl +1 -0
- package/src/components/ui/SignalCard/SignalCard.styl +104 -0
- package/src/components/ui/SignalCard/SignalCard.styl.d.ts +20 -0
- package/src/components/ui/SignalCard/SignalCard.tsx +87 -0
- package/src/components/ui/SignalCard/SignalCard.types.ts +24 -0
- package/src/components/ui/SignalCard/index.ts +2 -0
- package/src/components/ui/Switch/Switch.styl +7 -7
- package/src/components/ui/Table/Table.styl +37 -19
- package/src/components/ui/Table/Table.styl.d.ts +0 -1
- package/src/components/ui/Table/Table.tsx +5 -3
- package/src/components/ui/Table/Table.types.ts +8 -4
- package/src/components/ui/Table/index.ts +1 -1
- package/src/components/ui/Tooltip/Tooltip.styl +2 -2
- package/src/components/widgets/PerformanceChart/PerformanceChart.styl +3 -0
- package/src/components/widgets/PerformanceChart/PerformanceChart.styl.d.ts +1 -0
- package/src/components/widgets/PerformanceChart/PerformanceTable.tsx +8 -8
- package/src/contexts/chatPersistence.test.ts +13 -2
- package/src/docs/components/DocsGuidance/DocsGuidance.styl +33 -0
- package/src/docs/components/DocsGuidance/DocsGuidance.styl.d.ts +11 -0
- package/src/docs/components/DocsGuidance/DocsGuidance.tsx +57 -0
- package/src/docs/pages/AnalysesSelectorPage.tsx +16 -0
- package/src/docs/pages/AnalysisLineIconPage.tsx +12 -0
- package/src/docs/pages/AvatarPage.tsx +15 -0
- package/src/docs/pages/BadgePage.tsx +16 -0
- package/src/docs/pages/BarChartPage.tsx +109 -0
- package/src/docs/pages/BreadcrumbPage.tsx +15 -0
- package/src/docs/pages/ButtonPage.tsx +17 -0
- package/src/docs/pages/CardPage.tsx +190 -17
- package/src/docs/pages/ChartAreaInteractivePage.tsx +24 -7
- package/src/docs/pages/ChartPage.tsx +14 -0
- package/src/docs/pages/ChatAttachmentsDropzonePage.tsx +15 -0
- package/src/docs/pages/ChatComposerPrefillPage.tsx +15 -0
- package/src/docs/pages/ChatPage.tsx +15 -0
- package/src/docs/pages/ChatSheetPage.tsx +14 -0
- package/src/docs/pages/ChatSlashCommandsPage.tsx +15 -0
- package/src/docs/pages/ChatUserCsvAttachmentPage.tsx +14 -0
- package/src/docs/pages/CheckboxPage.tsx +37 -4
- package/src/docs/pages/ChipPage.tsx +160 -0
- package/src/docs/pages/ColorsPage.styl +27 -0
- package/src/docs/pages/ColorsPage.styl.d.ts +12 -0
- package/src/docs/pages/ColorsPage.tsx +102 -0
- package/src/docs/pages/ConfirmPage.tsx +15 -0
- package/src/docs/pages/DialogPage.tsx +15 -0
- package/src/docs/pages/DonutChartPage.tsx +80 -0
- package/src/docs/pages/DrawerPage.tsx +17 -0
- package/src/docs/pages/DriverMapPage.tsx +17 -0
- package/src/docs/pages/DriversComparisonChartPage.tsx +17 -0
- package/src/docs/pages/DropZonePage.tsx +16 -0
- package/src/docs/pages/DropdownMenuPage.tsx +16 -0
- package/src/docs/pages/FileChipPage.tsx +17 -0
- package/src/docs/pages/FlickeringGridPage.tsx +15 -0
- package/src/docs/pages/FoldablePage.tsx +16 -0
- package/src/docs/pages/GridLayoutPage.tsx +16 -0
- package/src/docs/pages/IconsPage.styl +74 -0
- package/src/docs/pages/IconsPage.styl.d.ts +17 -0
- package/src/docs/pages/IconsPage.tsx +125 -0
- package/src/docs/pages/ImagePage.tsx +16 -0
- package/src/docs/pages/ImageWithFallbackPage.tsx +15 -0
- package/src/docs/pages/IncludeHiddenInYScalePage.tsx +14 -0
- package/src/docs/pages/InputPage.tsx +134 -19
- package/src/docs/pages/InteractiveContentPage.tsx +15 -0
- package/src/docs/pages/KickerPage.tsx +62 -0
- package/src/docs/pages/LabelPage.tsx +15 -0
- package/src/docs/pages/LabelWithIdPage.tsx +11 -0
- package/src/docs/pages/LabeledInputPage.tsx +12 -0
- package/src/docs/pages/LegacyPlatformLinkPage.tsx +15 -0
- package/src/docs/pages/LightweightChartPage.styl +0 -1
- package/src/docs/pages/LightweightChartPage.tsx +17 -0
- package/src/docs/pages/LogoPage.tsx +15 -0
- package/src/docs/pages/MobileAdaptiveSelectorPage.tsx +15 -0
- package/src/docs/pages/MotionPage.styl +71 -0
- package/src/docs/pages/MotionPage.styl.d.ts +17 -0
- package/src/docs/pages/MotionPage.tsx +176 -0
- package/src/docs/pages/NavUserHeaderPage.tsx +15 -0
- package/src/docs/pages/NumberControlPage.tsx +15 -0
- package/src/docs/pages/PageColumnsPage.tsx +15 -0
- package/src/docs/pages/PageFooterPage.tsx +15 -0
- package/src/docs/pages/PagePage.tsx +15 -0
- package/src/docs/pages/PageTabsPage.tsx +18 -0
- package/src/docs/pages/PerformanceChartPage.tsx +15 -0
- package/src/docs/pages/ProgressPage.tsx +66 -3
- package/src/docs/pages/PullQuotePage.tsx +59 -0
- package/src/docs/pages/RadiiShadowsPage.styl +47 -0
- package/src/docs/pages/RadiiShadowsPage.styl.d.ts +14 -0
- package/src/docs/pages/RadiiShadowsPage.tsx +109 -0
- package/src/docs/pages/RegionCoordsPage.tsx +12 -0
- package/src/docs/pages/RenamerPage.tsx +15 -0
- package/src/docs/pages/SelectPage.tsx +160 -6
- package/src/docs/pages/SeparatorPage.tsx +12 -0
- package/src/docs/pages/SheetPage.tsx +15 -0
- package/src/docs/pages/SidebarDatasetsItemsGroupedPage.tsx +12 -0
- package/src/docs/pages/SidebarPage.tsx +15 -0
- package/src/docs/pages/SignalCardPage.tsx +126 -0
- package/src/docs/pages/SkeletonPage.tsx +16 -0
- package/src/docs/pages/SliderPage.tsx +70 -4
- package/src/docs/pages/SmartTextTruncatePage.styl +13 -0
- package/src/docs/pages/SmartTextTruncatePage.styl.d.ts +8 -0
- package/src/docs/pages/SmartTextTruncatePage.tsx +17 -4
- package/src/docs/pages/SpacingPage.styl +31 -0
- package/src/docs/pages/SpacingPage.styl.d.ts +12 -0
- package/src/docs/pages/SpacingPage.tsx +50 -0
- package/src/docs/pages/SparklinePage.tsx +15 -0
- package/src/docs/pages/StandaloneAppLayoutPage/StandaloneAppLayoutPage.tsx +16 -0
- package/src/docs/pages/SwitchPage.tsx +147 -8
- package/src/docs/pages/SybilionAuthLayoutPage.tsx +15 -0
- package/src/docs/pages/TablePage.tsx +134 -22
- package/src/docs/pages/TabsPage.tsx +20 -0
- package/src/docs/pages/TextShimmerPage.tsx +12 -0
- package/src/docs/pages/TextWithDeferTooltipPage.tsx +15 -0
- package/src/docs/pages/TimeRangeControlsPage.tsx +15 -0
- package/src/docs/pages/ToggleGroupPage.tsx +15 -0
- package/src/docs/pages/TogglePage.tsx +13 -0
- package/src/docs/pages/TooltipPage.tsx +17 -0
- package/src/docs/pages/TypographyPage.styl +42 -0
- package/src/docs/pages/TypographyPage.styl.d.ts +12 -0
- package/src/docs/pages/TypographyPage.tsx +226 -0
- package/src/docs/pages/VimeoEmbedPage.tsx +12 -0
- package/src/docs/pages/WorldMapPage.tsx +12 -0
- package/src/docs/registry.ts +79 -0
- package/src/index.ts +6 -0
|
@@ -2,19 +2,82 @@ import { PageContentSection } from '#uilib/components/ui/Page';
|
|
|
2
2
|
import { Progress } from '#uilib/components/ui/Progress';
|
|
3
3
|
|
|
4
4
|
import { AppPageHeader } from '../components/AppPageHeader/AppPageHeader';
|
|
5
|
+
import { DocsGuidance } from '../components/DocsGuidance/DocsGuidance';
|
|
5
6
|
import { DocsHeaderActions } from '../docsHeaderActions';
|
|
6
7
|
|
|
8
|
+
const VALUES = [0, 25, 50, 75, 100] as const;
|
|
9
|
+
|
|
10
|
+
const PROGRESS_WIDTH = 320;
|
|
11
|
+
|
|
7
12
|
export default function ProgressPage() {
|
|
8
13
|
return (
|
|
9
14
|
<>
|
|
10
15
|
<AppPageHeader
|
|
11
16
|
breadcrumbs={[{ label: 'Progress' }]}
|
|
12
17
|
title="Progress"
|
|
13
|
-
subheader="
|
|
18
|
+
subheader="Determinate fill at different completion values."
|
|
14
19
|
actions={<DocsHeaderActions />}
|
|
15
20
|
/>
|
|
16
|
-
<
|
|
17
|
-
|
|
21
|
+
<DocsGuidance
|
|
22
|
+
overview="Progress is a horizontal bar that communicates how much of a process has completed. Pass a value between 0 and 100 to fill the bar proportionally."
|
|
23
|
+
whenToUse={[
|
|
24
|
+
'To show determinate progress for an operation with a known duration or step count, such as an upload or import.',
|
|
25
|
+
'To visualise completion of a quota or capacity, such as storage used.',
|
|
26
|
+
]}
|
|
27
|
+
whenNotToUse={[
|
|
28
|
+
'When the duration is unknown; use a spinner or skeleton instead.',
|
|
29
|
+
'For navigation through steps; use a stepper or wizard pattern.',
|
|
30
|
+
]}
|
|
31
|
+
/>
|
|
32
|
+
<PageContentSection
|
|
33
|
+
style={{ display: 'flex', flexDirection: 'column', gap: '2rem' }}
|
|
34
|
+
>
|
|
35
|
+
<section>
|
|
36
|
+
<h3 style={{ marginBottom: '1rem' }}>Values</h3>
|
|
37
|
+
<div style={{ overflowX: 'auto' }}>
|
|
38
|
+
<table style={{ borderCollapse: 'collapse', width: '100%' }}>
|
|
39
|
+
<thead>
|
|
40
|
+
<tr>
|
|
41
|
+
<th style={{ textAlign: 'left', padding: '0.5rem' }}>
|
|
42
|
+
value
|
|
43
|
+
</th>
|
|
44
|
+
<th style={{ padding: '0.5rem' }}>bar</th>
|
|
45
|
+
</tr>
|
|
46
|
+
</thead>
|
|
47
|
+
<tbody>
|
|
48
|
+
{VALUES.map(val => (
|
|
49
|
+
<tr key={val}>
|
|
50
|
+
<td
|
|
51
|
+
style={{
|
|
52
|
+
padding: '0.5rem',
|
|
53
|
+
fontWeight: 600,
|
|
54
|
+
whiteSpace: 'nowrap',
|
|
55
|
+
}}
|
|
56
|
+
>
|
|
57
|
+
{val}%
|
|
58
|
+
</td>
|
|
59
|
+
<td style={{ padding: '0.5rem' }}>
|
|
60
|
+
<Progress value={val} style={{ width: PROGRESS_WIDTH }} />
|
|
61
|
+
</td>
|
|
62
|
+
</tr>
|
|
63
|
+
))}
|
|
64
|
+
</tbody>
|
|
65
|
+
</table>
|
|
66
|
+
</div>
|
|
67
|
+
</section>
|
|
68
|
+
<section>
|
|
69
|
+
<h3 style={{ marginBottom: '1rem' }}>Indeterminate</h3>
|
|
70
|
+
<p
|
|
71
|
+
style={{
|
|
72
|
+
marginBottom: '0.75rem',
|
|
73
|
+
color: 'var(--muted-foreground)',
|
|
74
|
+
}}
|
|
75
|
+
>
|
|
76
|
+
Omit <code>value</code> or pass <code>0</code> for an empty track
|
|
77
|
+
before progress is known.
|
|
78
|
+
</p>
|
|
79
|
+
<Progress style={{ width: PROGRESS_WIDTH }} />
|
|
80
|
+
</section>
|
|
18
81
|
</PageContentSection>
|
|
19
82
|
</>
|
|
20
83
|
);
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { PageContentSection } from '#uilib/components/ui/Page';
|
|
2
|
+
import { PullQuote } from '#uilib/components/ui/PullQuote';
|
|
3
|
+
|
|
4
|
+
import { AppPageHeader } from '../components/AppPageHeader/AppPageHeader';
|
|
5
|
+
import { DocsGuidance } from '../components/DocsGuidance/DocsGuidance';
|
|
6
|
+
import { DocsHeaderActions } from '../docsHeaderActions';
|
|
7
|
+
|
|
8
|
+
export default function PullQuotePage() {
|
|
9
|
+
return (
|
|
10
|
+
<>
|
|
11
|
+
<AppPageHeader
|
|
12
|
+
breadcrumbs={[{ label: 'PullQuote' }]}
|
|
13
|
+
title="PullQuote"
|
|
14
|
+
subheader="Editorial quote with accent rule and sentence-case attribution."
|
|
15
|
+
actions={<DocsHeaderActions />}
|
|
16
|
+
/>
|
|
17
|
+
<DocsGuidance
|
|
18
|
+
overview="PullQuote presents an editorial quote with a 2px accent rule on the left, display-face body text, and a small Manrope attribution line. Attribution stays in sentence case with zero tracking; the optional role renders muted after a middle dot."
|
|
19
|
+
whenToUse={[
|
|
20
|
+
'To highlight a customer or stakeholder quote in marketing or report content.',
|
|
21
|
+
'To lift a key sentence out of long-form copy as an editorial emphasis.',
|
|
22
|
+
]}
|
|
23
|
+
whenNotToUse={[
|
|
24
|
+
'For inline quotations within body text; use standard quotation marks.',
|
|
25
|
+
'For callouts, warnings, or notes; use a card or alert pattern instead.',
|
|
26
|
+
]}
|
|
27
|
+
dontNotes={[
|
|
28
|
+
'Do not set the attribution in uppercase; small text keeps sentence case.',
|
|
29
|
+
]}
|
|
30
|
+
/>
|
|
31
|
+
<PageContentSection
|
|
32
|
+
style={{ display: 'flex', flexDirection: 'column', gap: '2rem' }}
|
|
33
|
+
>
|
|
34
|
+
<section>
|
|
35
|
+
<h3 style={{ marginBottom: '1rem' }}>Default</h3>
|
|
36
|
+
<PullQuote
|
|
37
|
+
attribution="Marta Linden"
|
|
38
|
+
attributionRole="Head of procurement, KD Feddersen"
|
|
39
|
+
>
|
|
40
|
+
Sybilion moved our procurement committee's confidence earlier —
|
|
41
|
+
we locked a propylene contract 11 days before the market caught up.
|
|
42
|
+
</PullQuote>
|
|
43
|
+
</section>
|
|
44
|
+
<section>
|
|
45
|
+
<h3 style={{ marginBottom: '1rem' }}>Without attribution</h3>
|
|
46
|
+
<PullQuote>
|
|
47
|
+
Forecasts are only useful when they arrive before the decision.
|
|
48
|
+
</PullQuote>
|
|
49
|
+
</section>
|
|
50
|
+
<section>
|
|
51
|
+
<h3 style={{ marginBottom: '1rem' }}>Attribution only</h3>
|
|
52
|
+
<PullQuote attribution="Procurement weekly, May 2026">
|
|
53
|
+
Signal quality beats signal quantity in every committee we surveyed.
|
|
54
|
+
</PullQuote>
|
|
55
|
+
</section>
|
|
56
|
+
</PageContentSection>
|
|
57
|
+
</>
|
|
58
|
+
);
|
|
59
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
.row
|
|
2
|
+
display flex
|
|
3
|
+
flex-wrap wrap
|
|
4
|
+
gap var(--p-6)
|
|
5
|
+
align-items flex-end
|
|
6
|
+
|
|
7
|
+
.item
|
|
8
|
+
display flex
|
|
9
|
+
flex-direction column
|
|
10
|
+
align-items center
|
|
11
|
+
gap var(--p-2)
|
|
12
|
+
|
|
13
|
+
.radiusBox
|
|
14
|
+
width 64px
|
|
15
|
+
height 64px
|
|
16
|
+
background var(--background)
|
|
17
|
+
border 1px solid var(--border)
|
|
18
|
+
|
|
19
|
+
.pillBox
|
|
20
|
+
width 128px
|
|
21
|
+
height 36px
|
|
22
|
+
background var(--background)
|
|
23
|
+
border 1px solid var(--border)
|
|
24
|
+
|
|
25
|
+
.shadowCard
|
|
26
|
+
width 200px
|
|
27
|
+
height 80px
|
|
28
|
+
display flex
|
|
29
|
+
align-items center
|
|
30
|
+
justify-content center
|
|
31
|
+
background var(--background)
|
|
32
|
+
border 1px solid var(--border)
|
|
33
|
+
border-radius var(--radius-2)
|
|
34
|
+
|
|
35
|
+
.token
|
|
36
|
+
font-family monospace
|
|
37
|
+
font-size var(--text-xs)
|
|
38
|
+
color var(--muted-foreground)
|
|
39
|
+
user-select text
|
|
40
|
+
|
|
41
|
+
.value
|
|
42
|
+
font-size var(--text-2xs)
|
|
43
|
+
color var(--muted-foreground)
|
|
44
|
+
|
|
45
|
+
.sectionNote
|
|
46
|
+
margin-bottom var(--p-3)
|
|
47
|
+
color var(--muted-foreground)
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
// This file is automatically generated.
|
|
2
|
+
// Please do not change this file!
|
|
3
|
+
interface CssExports {
|
|
4
|
+
'item': string;
|
|
5
|
+
'pillBox': string;
|
|
6
|
+
'radiusBox': string;
|
|
7
|
+
'row': string;
|
|
8
|
+
'sectionNote': string;
|
|
9
|
+
'shadowCard': string;
|
|
10
|
+
'token': string;
|
|
11
|
+
'value': string;
|
|
12
|
+
}
|
|
13
|
+
export const cssExports: CssExports;
|
|
14
|
+
export default cssExports;
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
import { PageContentSection } from '#uilib/components/ui/Page';
|
|
2
|
+
|
|
3
|
+
import { AppPageHeader } from '../components/AppPageHeader/AppPageHeader';
|
|
4
|
+
import { DocsGuidance } from '../components/DocsGuidance/DocsGuidance';
|
|
5
|
+
import { DocsHeaderActions } from '../docsHeaderActions';
|
|
6
|
+
import S from './RadiiShadowsPage.styl';
|
|
7
|
+
|
|
8
|
+
const RADIUS_SCALE = [
|
|
9
|
+
{ token: '--radius-0', px: '0px' },
|
|
10
|
+
{ token: '--radius-1', px: '2px' },
|
|
11
|
+
{ token: '--radius-2', px: '4px' },
|
|
12
|
+
{ token: '--radius-3', px: '8px' },
|
|
13
|
+
{ token: '--radius-4', px: '12px' },
|
|
14
|
+
];
|
|
15
|
+
|
|
16
|
+
const RADIUS_ALIASES = [
|
|
17
|
+
{ token: '--radius-sm', px: '4px' },
|
|
18
|
+
{ token: '--radius-md', px: '6px' },
|
|
19
|
+
{ token: '--radius-lg', px: '8px' },
|
|
20
|
+
];
|
|
21
|
+
|
|
22
|
+
const RADIUS_SEMANTIC = [
|
|
23
|
+
{ token: '--radius-button', px: '10px' },
|
|
24
|
+
{ token: '--radius-card', px: '12px' },
|
|
25
|
+
{ token: '--radius-input', px: '10px' },
|
|
26
|
+
];
|
|
27
|
+
|
|
28
|
+
const SHADOWS = [
|
|
29
|
+
{ token: '--shadow-0', value: 'none' },
|
|
30
|
+
{ token: '--shadow-1', value: '0 1px 0' },
|
|
31
|
+
{ token: '--shadow-2', value: '0 2px 8px' },
|
|
32
|
+
{ token: '--shadow-3', value: '0 12px 32px' },
|
|
33
|
+
];
|
|
34
|
+
|
|
35
|
+
function RadiusItem({ token, px }: { token: string; px: string }) {
|
|
36
|
+
return (
|
|
37
|
+
<div className={S.item}>
|
|
38
|
+
<div className={S.radiusBox} style={{ borderRadius: `var(${token})` }} />
|
|
39
|
+
<span className={S.token}>{token}</span>
|
|
40
|
+
<span className={S.value}>{px}</span>
|
|
41
|
+
</div>
|
|
42
|
+
);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export default function RadiiShadowsPage() {
|
|
46
|
+
return (
|
|
47
|
+
<>
|
|
48
|
+
<AppPageHeader
|
|
49
|
+
breadcrumbs={[{ label: 'Radii and shadows' }]}
|
|
50
|
+
title="Radii and shadows"
|
|
51
|
+
subheader="Square-biased corner radii and three restrained elevation levels."
|
|
52
|
+
actions={<DocsHeaderActions />}
|
|
53
|
+
/>
|
|
54
|
+
<DocsGuidance
|
|
55
|
+
overview="Corners are small and square-biased: the scale runs from 0 to 12px, with semantic aliases for buttons, cards, and inputs. Elevation is restrained — three slate-tinted shadows that separate surfaces without floating them."
|
|
56
|
+
whenToUse={[
|
|
57
|
+
'Semantic radii (--radius-button/card/input) on the controls they are named after.',
|
|
58
|
+
'--shadow-1 or --shadow-2 for cards and popovers; --shadow-3 only for dialogs and other top-level surfaces.',
|
|
59
|
+
]}
|
|
60
|
+
whenNotToUse={[
|
|
61
|
+
'Heavy or coloured drop shadows; elevation stays subtle in this system.',
|
|
62
|
+
]}
|
|
63
|
+
/>
|
|
64
|
+
<PageContentSection>
|
|
65
|
+
<h3>Radius scale</h3>
|
|
66
|
+
<div className={S.row}>
|
|
67
|
+
{RADIUS_SCALE.map(item => (
|
|
68
|
+
<RadiusItem key={item.token} {...item} />
|
|
69
|
+
))}
|
|
70
|
+
<div className={S.item}>
|
|
71
|
+
<div
|
|
72
|
+
className={S.pillBox}
|
|
73
|
+
style={{ borderRadius: 'var(--radius-pill)' }}
|
|
74
|
+
/>
|
|
75
|
+
<span className={S.token}>--radius-pill</span>
|
|
76
|
+
<span className={S.value}>999px</span>
|
|
77
|
+
</div>
|
|
78
|
+
</div>
|
|
79
|
+
</PageContentSection>
|
|
80
|
+
<PageContentSection>
|
|
81
|
+
<h3>Aliases and semantic radii</h3>
|
|
82
|
+
<p className={S.sectionNote}>
|
|
83
|
+
Size aliases used across styles, and per-control semantic tokens.
|
|
84
|
+
</p>
|
|
85
|
+
<div className={S.row}>
|
|
86
|
+
{[...RADIUS_ALIASES, ...RADIUS_SEMANTIC].map(item => (
|
|
87
|
+
<RadiusItem key={item.token} {...item} />
|
|
88
|
+
))}
|
|
89
|
+
</div>
|
|
90
|
+
</PageContentSection>
|
|
91
|
+
<PageContentSection>
|
|
92
|
+
<h3>Shadows</h3>
|
|
93
|
+
<div className={S.row}>
|
|
94
|
+
{SHADOWS.map(({ token, value }) => (
|
|
95
|
+
<div key={token} className={S.item}>
|
|
96
|
+
<div
|
|
97
|
+
className={S.shadowCard}
|
|
98
|
+
style={{ boxShadow: `var(${token})` }}
|
|
99
|
+
>
|
|
100
|
+
<span className={S.token}>{token}</span>
|
|
101
|
+
</div>
|
|
102
|
+
<span className={S.value}>{value}</span>
|
|
103
|
+
</div>
|
|
104
|
+
))}
|
|
105
|
+
</div>
|
|
106
|
+
</PageContentSection>
|
|
107
|
+
</>
|
|
108
|
+
);
|
|
109
|
+
}
|
|
@@ -4,6 +4,7 @@ import { PageContentSection } from '#uilib/components/ui/Page';
|
|
|
4
4
|
import { RegionSelector } from '#uilib/components/ui/RegionCoords';
|
|
5
5
|
|
|
6
6
|
import { AppPageHeader } from '../components/AppPageHeader/AppPageHeader';
|
|
7
|
+
import { DocsGuidance } from '../components/DocsGuidance/DocsGuidance';
|
|
7
8
|
import { DocsHeaderActions } from '../docsHeaderActions';
|
|
8
9
|
|
|
9
10
|
const REGIONS = {
|
|
@@ -22,6 +23,17 @@ export default function RegionCoordsPage() {
|
|
|
22
23
|
subheader="RegionSelector — pick a region from map coordinates."
|
|
23
24
|
actions={<DocsHeaderActions />}
|
|
24
25
|
/>
|
|
26
|
+
<DocsGuidance
|
|
27
|
+
overview="RegionSelector lets the user pick a named region from a map of geographic coordinates. Pass a record of region names to longitude and latitude pairs, and receive the chosen name and coordinates in onSelect."
|
|
28
|
+
whenToUse={[
|
|
29
|
+
'To attach a geographic region to a dataset or record from a predefined list.',
|
|
30
|
+
'When the selection needs to resolve to concrete coordinates rather than just a label.',
|
|
31
|
+
]}
|
|
32
|
+
whenNotToUse={[
|
|
33
|
+
'For free-form location search or address entry; use a geocoding input instead.',
|
|
34
|
+
'For plain single-choice lists without geographic meaning; use Select.',
|
|
35
|
+
]}
|
|
36
|
+
/>
|
|
25
37
|
<PageContentSection>
|
|
26
38
|
<RegionSelector
|
|
27
39
|
regions={REGIONS}
|
|
@@ -4,6 +4,7 @@ import { PageContentSection } from '#uilib/components/ui/Page';
|
|
|
4
4
|
import { Renamer } from '#uilib/components/ui/Renamer';
|
|
5
5
|
|
|
6
6
|
import { AppPageHeader } from '../components/AppPageHeader/AppPageHeader';
|
|
7
|
+
import { DocsGuidance } from '../components/DocsGuidance/DocsGuidance';
|
|
7
8
|
import { DocsHeaderActions } from '../docsHeaderActions';
|
|
8
9
|
|
|
9
10
|
export default function RenamerPage() {
|
|
@@ -17,6 +18,20 @@ export default function RenamerPage() {
|
|
|
17
18
|
subheader="Inline rename with pencil control."
|
|
18
19
|
actions={<DocsHeaderActions />}
|
|
19
20
|
/>
|
|
21
|
+
<DocsGuidance
|
|
22
|
+
overview="Renamer wraps a displayed name with an inline rename affordance: a pencil control switches the text into an editable field and commits the new value through onChange. The children render the current display state."
|
|
23
|
+
whenToUse={[
|
|
24
|
+
'To let users rename an entity, such as a dataset or report, in place without a dialog.',
|
|
25
|
+
'In headers or list rows where the name is the primary editable property.',
|
|
26
|
+
]}
|
|
27
|
+
whenNotToUse={[
|
|
28
|
+
'For multi-field editing; open a form or dialog instead.',
|
|
29
|
+
'When renaming requires validation feedback or confirmation before saving.',
|
|
30
|
+
]}
|
|
31
|
+
doNotes={[
|
|
32
|
+
'Persist the new name in onChange and reflect it back in value so the display stays in sync.',
|
|
33
|
+
]}
|
|
34
|
+
/>
|
|
20
35
|
<PageContentSection>
|
|
21
36
|
<Renamer value={name} onChange={setName}>
|
|
22
37
|
{name}
|
|
@@ -8,10 +8,11 @@ import {
|
|
|
8
8
|
} from '#uilib/components/ui/Select';
|
|
9
9
|
|
|
10
10
|
import { AppPageHeader } from '../components/AppPageHeader/AppPageHeader';
|
|
11
|
+
import { DocsGuidance } from '../components/DocsGuidance/DocsGuidance';
|
|
11
12
|
import { DocsHeaderActions } from '../docsHeaderActions';
|
|
12
13
|
|
|
13
14
|
const VARIANTS = ['default', 'clear'] as const;
|
|
14
|
-
const SIZES = ['sm', 'md', 'lg'] as const;
|
|
15
|
+
const SIZES = ['xs', 'sm', 'md', 'lg'] as const;
|
|
15
16
|
|
|
16
17
|
const FRUIT_OPTIONS = [
|
|
17
18
|
{ value: 'apple', label: 'Apple' },
|
|
@@ -22,14 +23,28 @@ const FRUIT_OPTIONS = [
|
|
|
22
23
|
function DemoSelect({
|
|
23
24
|
variant,
|
|
24
25
|
size,
|
|
26
|
+
disabled = false,
|
|
27
|
+
placeholder,
|
|
28
|
+
defaultValue,
|
|
29
|
+
darker = false,
|
|
25
30
|
}: {
|
|
26
31
|
variant: (typeof VARIANTS)[number];
|
|
27
32
|
size: (typeof SIZES)[number];
|
|
33
|
+
disabled?: boolean;
|
|
34
|
+
placeholder?: string;
|
|
35
|
+
defaultValue?: string;
|
|
36
|
+
darker?: boolean;
|
|
28
37
|
}) {
|
|
29
38
|
return (
|
|
30
|
-
<Select defaultValue=
|
|
31
|
-
<SelectTrigger
|
|
32
|
-
|
|
39
|
+
<Select defaultValue={defaultValue}>
|
|
40
|
+
<SelectTrigger
|
|
41
|
+
variant={variant}
|
|
42
|
+
size={size}
|
|
43
|
+
disabled={disabled}
|
|
44
|
+
darker={darker}
|
|
45
|
+
style={{ width: 200 }}
|
|
46
|
+
>
|
|
47
|
+
<SelectValue placeholder={placeholder ?? 'Pick fruit'} />
|
|
33
48
|
</SelectTrigger>
|
|
34
49
|
<SelectContent>
|
|
35
50
|
{FRUIT_OPTIONS.map(o => (
|
|
@@ -48,9 +63,23 @@ export default function SelectPage() {
|
|
|
48
63
|
<AppPageHeader
|
|
49
64
|
breadcrumbs={[{ label: 'Select' }]}
|
|
50
65
|
title="Select"
|
|
51
|
-
subheader="
|
|
66
|
+
subheader="Variants, sizes, placeholder, darker trigger, and disabled state."
|
|
52
67
|
actions={<DocsHeaderActions />}
|
|
53
68
|
/>
|
|
69
|
+
<DocsGuidance
|
|
70
|
+
overview="Select is a Radix-based dropdown for choosing a single option from a list. Compose it from Select, SelectTrigger, SelectValue, SelectContent, and SelectItem, and pick a trigger variant and size to match the surrounding controls."
|
|
71
|
+
whenToUse={[
|
|
72
|
+
'To choose one option from a list of roughly five or more items.',
|
|
73
|
+
'In forms, toolbars, and filters where space is limited and options collapse behind a trigger.',
|
|
74
|
+
]}
|
|
75
|
+
whenNotToUse={[
|
|
76
|
+
'For two to four options that benefit from being visible at once; use ToggleGroup or radio buttons.',
|
|
77
|
+
'For multi-select or searchable lists; use a combobox or multi-select component.',
|
|
78
|
+
]}
|
|
79
|
+
doNotes={[
|
|
80
|
+
'Use the clear variant for low-emphasis, inline selects embedded in text or toolbars.',
|
|
81
|
+
]}
|
|
82
|
+
/>
|
|
54
83
|
<PageContentSection
|
|
55
84
|
style={{ display: 'flex', flexDirection: 'column', gap: '2rem' }}
|
|
56
85
|
>
|
|
@@ -82,7 +111,132 @@ export default function SelectPage() {
|
|
|
82
111
|
</td>
|
|
83
112
|
{SIZES.map(s => (
|
|
84
113
|
<td key={s} style={{ padding: '0.5rem' }}>
|
|
85
|
-
<DemoSelect variant={v} size={s} />
|
|
114
|
+
<DemoSelect variant={v} size={s} defaultValue="apple" />
|
|
115
|
+
</td>
|
|
116
|
+
))}
|
|
117
|
+
</tr>
|
|
118
|
+
))}
|
|
119
|
+
</tbody>
|
|
120
|
+
</table>
|
|
121
|
+
</div>
|
|
122
|
+
</section>
|
|
123
|
+
<section>
|
|
124
|
+
<h3 style={{ marginBottom: '1rem' }}>Placeholder</h3>
|
|
125
|
+
<p
|
|
126
|
+
style={{
|
|
127
|
+
marginBottom: '0.75rem',
|
|
128
|
+
color: 'var(--muted-foreground)',
|
|
129
|
+
}}
|
|
130
|
+
>
|
|
131
|
+
No <code>defaultValue</code> — the trigger shows the placeholder
|
|
132
|
+
until a value is chosen.
|
|
133
|
+
</p>
|
|
134
|
+
<div style={{ overflowX: 'auto' }}>
|
|
135
|
+
<table style={{ borderCollapse: 'collapse', width: '100%' }}>
|
|
136
|
+
<thead>
|
|
137
|
+
<tr>
|
|
138
|
+
<th style={{ textAlign: 'left', padding: '0.5rem' }} />
|
|
139
|
+
{SIZES.map(s => (
|
|
140
|
+
<th key={s} style={{ padding: '0.5rem' }}>
|
|
141
|
+
{s}
|
|
142
|
+
</th>
|
|
143
|
+
))}
|
|
144
|
+
</tr>
|
|
145
|
+
</thead>
|
|
146
|
+
<tbody>
|
|
147
|
+
{VARIANTS.map(v => (
|
|
148
|
+
<tr key={v}>
|
|
149
|
+
<td
|
|
150
|
+
style={{
|
|
151
|
+
padding: '0.5rem',
|
|
152
|
+
fontWeight: 600,
|
|
153
|
+
whiteSpace: 'nowrap',
|
|
154
|
+
}}
|
|
155
|
+
>
|
|
156
|
+
{v}
|
|
157
|
+
</td>
|
|
158
|
+
{SIZES.map(s => (
|
|
159
|
+
<td key={s} style={{ padding: '0.5rem' }}>
|
|
160
|
+
<DemoSelect
|
|
161
|
+
variant={v}
|
|
162
|
+
size={s}
|
|
163
|
+
placeholder="Pick fruit"
|
|
164
|
+
/>
|
|
165
|
+
</td>
|
|
166
|
+
))}
|
|
167
|
+
</tr>
|
|
168
|
+
))}
|
|
169
|
+
</tbody>
|
|
170
|
+
</table>
|
|
171
|
+
</div>
|
|
172
|
+
</section>
|
|
173
|
+
<section>
|
|
174
|
+
<h3 style={{ marginBottom: '1rem' }}>Darker trigger</h3>
|
|
175
|
+
<p
|
|
176
|
+
style={{
|
|
177
|
+
marginBottom: '0.75rem',
|
|
178
|
+
color: 'var(--muted-foreground)',
|
|
179
|
+
}}
|
|
180
|
+
>
|
|
181
|
+
Pass <code>darker</code> on <code>SelectTrigger</code> for a
|
|
182
|
+
higher-contrast background.
|
|
183
|
+
</p>
|
|
184
|
+
<div
|
|
185
|
+
style={{
|
|
186
|
+
display: 'flex',
|
|
187
|
+
flexWrap: 'wrap',
|
|
188
|
+
gap: '0.75rem',
|
|
189
|
+
alignItems: 'center',
|
|
190
|
+
backgroundColor: 'var(--background)',
|
|
191
|
+
padding: '0.75rem',
|
|
192
|
+
borderRadius: 'var(--p-3)',
|
|
193
|
+
}}
|
|
194
|
+
>
|
|
195
|
+
{SIZES.map(s => (
|
|
196
|
+
<DemoSelect
|
|
197
|
+
key={s}
|
|
198
|
+
variant="default"
|
|
199
|
+
size={s}
|
|
200
|
+
defaultValue="orange"
|
|
201
|
+
darker
|
|
202
|
+
/>
|
|
203
|
+
))}
|
|
204
|
+
</div>
|
|
205
|
+
</section>
|
|
206
|
+
<section>
|
|
207
|
+
<h3 style={{ marginBottom: '1rem' }}>Disabled</h3>
|
|
208
|
+
<div style={{ overflowX: 'auto' }}>
|
|
209
|
+
<table style={{ borderCollapse: 'collapse', width: '100%' }}>
|
|
210
|
+
<thead>
|
|
211
|
+
<tr>
|
|
212
|
+
<th style={{ textAlign: 'left', padding: '0.5rem' }} />
|
|
213
|
+
{SIZES.map(s => (
|
|
214
|
+
<th key={s} style={{ padding: '0.5rem' }}>
|
|
215
|
+
{s}
|
|
216
|
+
</th>
|
|
217
|
+
))}
|
|
218
|
+
</tr>
|
|
219
|
+
</thead>
|
|
220
|
+
<tbody>
|
|
221
|
+
{VARIANTS.map(v => (
|
|
222
|
+
<tr key={v}>
|
|
223
|
+
<td
|
|
224
|
+
style={{
|
|
225
|
+
padding: '0.5rem',
|
|
226
|
+
fontWeight: 600,
|
|
227
|
+
whiteSpace: 'nowrap',
|
|
228
|
+
}}
|
|
229
|
+
>
|
|
230
|
+
{v}
|
|
231
|
+
</td>
|
|
232
|
+
{SIZES.map(s => (
|
|
233
|
+
<td key={s} style={{ padding: '0.5rem' }}>
|
|
234
|
+
<DemoSelect
|
|
235
|
+
variant={v}
|
|
236
|
+
size={s}
|
|
237
|
+
defaultValue="banana"
|
|
238
|
+
disabled
|
|
239
|
+
/>
|
|
86
240
|
</td>
|
|
87
241
|
))}
|
|
88
242
|
</tr>
|
|
@@ -2,6 +2,7 @@ import { PageContentSection } from '#uilib/components/ui/Page';
|
|
|
2
2
|
import { Separator } from '#uilib/components/ui/Separator';
|
|
3
3
|
|
|
4
4
|
import { AppPageHeader } from '../components/AppPageHeader/AppPageHeader';
|
|
5
|
+
import { DocsGuidance } from '../components/DocsGuidance/DocsGuidance';
|
|
5
6
|
import { DocsHeaderActions } from '../docsHeaderActions';
|
|
6
7
|
|
|
7
8
|
export default function SeparatorPage() {
|
|
@@ -13,6 +14,17 @@ export default function SeparatorPage() {
|
|
|
13
14
|
subheader="Horizontal rule."
|
|
14
15
|
actions={<DocsHeaderActions />}
|
|
15
16
|
/>
|
|
17
|
+
<DocsGuidance
|
|
18
|
+
overview="Separator draws a thin horizontal rule that visually divides adjacent content. It is purely presentational and carries no semantics of its own."
|
|
19
|
+
whenToUse={[
|
|
20
|
+
'To divide groups of related content within a card, menu, or panel.',
|
|
21
|
+
'Between repeated rows or sections where whitespace alone is not enough.',
|
|
22
|
+
]}
|
|
23
|
+
whenNotToUse={[
|
|
24
|
+
'Between top-level page sections; rely on PageContentSection spacing instead.',
|
|
25
|
+
'When grouping can be expressed with headings or spacing alone; avoid unnecessary lines.',
|
|
26
|
+
]}
|
|
27
|
+
/>
|
|
16
28
|
<PageContentSection>
|
|
17
29
|
<p style={{ margin: 0 }}>Above</p>
|
|
18
30
|
<Separator style={{ margin: '12px 0' }} />
|
|
@@ -10,6 +10,7 @@ import {
|
|
|
10
10
|
} from '#uilib/components/ui/Sheet';
|
|
11
11
|
|
|
12
12
|
import { AppPageHeader } from '../components/AppPageHeader/AppPageHeader';
|
|
13
|
+
import { DocsGuidance } from '../components/DocsGuidance/DocsGuidance';
|
|
13
14
|
import { DocsHeaderActions } from '../docsHeaderActions';
|
|
14
15
|
|
|
15
16
|
export default function SheetPage() {
|
|
@@ -21,6 +22,20 @@ export default function SheetPage() {
|
|
|
21
22
|
subheader="Slide-over panel (Radix dialog)."
|
|
22
23
|
actions={<DocsHeaderActions />}
|
|
23
24
|
/>
|
|
25
|
+
<DocsGuidance
|
|
26
|
+
overview="Sheet is a slide-over panel built on the Radix dialog primitive. It opens from a screen edge over the current page and is composed from SheetTrigger, SheetContent, SheetHeader, SheetTitle, and SheetDescription."
|
|
27
|
+
whenToUse={[
|
|
28
|
+
'For supplementary tasks that keep the underlying page in context, such as editing details or filters.',
|
|
29
|
+
'On smaller screens where a full dialog would feel cramped and an edge panel works better.',
|
|
30
|
+
]}
|
|
31
|
+
whenNotToUse={[
|
|
32
|
+
'For short confirmations or alerts; use Dialog or AlertDialog.',
|
|
33
|
+
'For content that deserves its own page or persistent layout region.',
|
|
34
|
+
]}
|
|
35
|
+
doNotes={[
|
|
36
|
+
'Always include SheetTitle and SheetDescription so the panel is announced correctly to screen readers.',
|
|
37
|
+
]}
|
|
38
|
+
/>
|
|
24
39
|
<PageContentSection>
|
|
25
40
|
<Sheet>
|
|
26
41
|
<SheetTrigger asChild>
|
|
@@ -9,6 +9,7 @@ import {
|
|
|
9
9
|
} from '#uilib/components/widgets/SidebarDatasetsItemsGrouped';
|
|
10
10
|
|
|
11
11
|
import { AppPageHeader } from '../components/AppPageHeader/AppPageHeader';
|
|
12
|
+
import { DocsGuidance } from '../components/DocsGuidance/DocsGuidance';
|
|
12
13
|
import { DocsHeaderActions } from '../docsHeaderActions';
|
|
13
14
|
|
|
14
15
|
const MOCK_DATASETS: SidebarDatasetsItemsGroupedDataset[] = [
|
|
@@ -100,6 +101,17 @@ export default function SidebarDatasetsItemsGroupedPage() {
|
|
|
100
101
|
subheader="Datasets sidebar: collapsible groups and nested rows."
|
|
101
102
|
actions={<DocsHeaderActions />}
|
|
102
103
|
/>
|
|
104
|
+
<DocsGuidance
|
|
105
|
+
overview="SidebarDatasetsItemsGrouped renders a dataset list for the application sidebar, organised into collapsible groups with nested rows. The groupBy prop switches grouping between target type, regions, and categories, and selection is controlled through selectedDatasetId and onDatasetClick."
|
|
106
|
+
whenToUse={[
|
|
107
|
+
'In a sidebar that lists many datasets which benefit from grouping by a shared attribute.',
|
|
108
|
+
'When the user needs to switch between grouping dimensions without losing their selection.',
|
|
109
|
+
]}
|
|
110
|
+
whenNotToUse={[
|
|
111
|
+
'For short, flat lists; plain Sidebar menu items are simpler.',
|
|
112
|
+
'Outside a sidebar surface; the widget assumes sidebar colours and spacing.',
|
|
113
|
+
]}
|
|
114
|
+
/>
|
|
103
115
|
<PageContentSection>
|
|
104
116
|
<ToggleGroup
|
|
105
117
|
type="single"
|