@uipath/apollo-vertex 2.0.0 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -2,12 +2,11 @@
|
|
|
2
2
|
name: use-vertex-components
|
|
3
3
|
description: >
|
|
4
4
|
Build all new UI from @uipath/apollo-vertex components instead of writing
|
|
5
|
-
new ones. Covers
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
Vertex.
|
|
5
|
+
new ones. Covers how to adapt them with variants, className and
|
|
6
|
+
composition, and what not to do: hand-rolled primitives, raw Radix or other
|
|
7
|
+
UI libraries, or copied shadcn code. Load before building or changing any
|
|
8
|
+
UI in an app that uses Apollo Vertex, together with
|
|
9
|
+
vertex-component-catalog to pick the component.
|
|
11
10
|
metadata:
|
|
12
11
|
type: core
|
|
13
12
|
library: '@uipath/apollo-vertex'
|
|
@@ -41,23 +40,9 @@ components.
|
|
|
41
40
|
|
|
42
41
|
## Pick the component
|
|
43
42
|
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
| Text and choice inputs | `Input`, `InputGroup`, `Textarea`, `Select`, `Combobox`, `Checkbox`, `RadioGroup`, `Switch`, `Slider`, `InputOTP` |
|
|
48
|
-
| Dates | `DatePicker`, `Calendar` |
|
|
49
|
-
| Form layout, labels and errors | `Field`, `FieldGroup`, `FieldLabel`, `FieldDescription`, `FieldError`, `Label` |
|
|
50
|
-
| Multi-step forms | `FormWizard`, `Stepper` |
|
|
51
|
-
| Overlays | `Dialog`, `AlertDialog`, `Sheet`, `Drawer`, `Popover`, `HoverCard`, `Tooltip` |
|
|
52
|
-
| Menus | `DropdownMenu`, `ContextMenu`, `Menubar`, `Command`, `NavigationMenu` |
|
|
53
|
-
| Page structure | `PageHeader`, `Breadcrumb`, `Tabs`, `Card`, `Separator`, `ResizablePanelGroup`, `ScrollArea`, `Sidebar` |
|
|
54
|
-
| Lists and tables | `DataTable` with `useDataTable`, `Table`, `Item`, `Pagination` |
|
|
55
|
-
| Status and feedback | `Badge`, `Alert`, `Toaster`, `Progress`, `Spinner`, `Skeleton`, `Empty` |
|
|
56
|
-
| Metrics and charts | `MetricCard`, plus `BarChart`, `LineChart`, `KpiChart` and the other charts |
|
|
57
|
-
| AI content | `AiMark`, `AiGlow`, `AiCaveat`, `ConfidenceSignal`, `FeedbackVoteWidget` |
|
|
58
|
-
| Misc | `Avatar`, `Accordion`, `Collapsible`, `Carousel`, `TimelineRowLayout`, `Kbd`, `AspectRatio` |
|
|
59
|
-
|
|
60
|
-
Import all of them from `@uipath/apollo-vertex`.
|
|
43
|
+
Load the `vertex-component-catalog` skill to choose the component. It lists
|
|
44
|
+
every documented Vertex component by need, with its exports, when to use it
|
|
45
|
+
and what to use instead. Import all of them from `@uipath/apollo-vertex`.
|
|
61
46
|
|
|
62
47
|
## Adapting a component
|
|
63
48
|
|
|
@@ -0,0 +1,213 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: vertex-component-catalog
|
|
3
|
+
description: >
|
|
4
|
+
Catalog of every documented @uipath/apollo-vertex component and pattern,
|
|
5
|
+
grouped by need (actions, inputs, forms, overlays, menus, layout, data
|
|
6
|
+
display, feedback, charts), with the names to import, when to use each one
|
|
7
|
+
and which component to use instead. Load when choosing which Vertex
|
|
8
|
+
component to build a screen, form, dialog, table or state from.
|
|
9
|
+
metadata:
|
|
10
|
+
type: core
|
|
11
|
+
library: '@uipath/apollo-vertex'
|
|
12
|
+
sources:
|
|
13
|
+
- 'UiPath/apollo-ui:apps/apollo-vertex/content/docs/components/*.mdx'
|
|
14
|
+
- 'UiPath/apollo-ui:apps/apollo-vertex/content/docs/components/meta.json'
|
|
15
|
+
- 'UiPath/apollo-ui:apps/apollo-vertex/content/docs/patterns/*.mdx'
|
|
16
|
+
- 'UiPath/apollo-ui:apps/apollo-vertex/content/docs/patterns/meta.json'
|
|
17
|
+
- 'UiPath/apollo-ui:packages/apollo-vertex/entries/index.ts'
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
<!-- Generated by apps/apollo-vertex/scripts/generate-component-skill.ts from the
|
|
21
|
+
docs pages. Do not edit by hand. -->
|
|
22
|
+
|
|
23
|
+
# Apollo Vertex component catalog
|
|
24
|
+
|
|
25
|
+
Import every name below from `@uipath/apollo-vertex`. Follow the
|
|
26
|
+
`use-vertex-components` skill for how to use and adapt them.
|
|
27
|
+
|
|
28
|
+
## Actions
|
|
29
|
+
|
|
30
|
+
- **Button**: Displays a button or a component that looks like a button. Exports: `Button`, `buttonVariants`.
|
|
31
|
+
- Use when the user triggers an action, such as submitting a form, saving or opening a dialog.
|
|
32
|
+
- Avoid when the control turns a setting on or off. Use **Switch** instead.
|
|
33
|
+
- Avoid when the user picks one of a few modes or views. Use **Toggle Group** instead.
|
|
34
|
+
- **Button Group**: Groups multiple buttons together with proper styling and spacing. Exports: `ButtonGroup`, `ButtonGroupSeparator`, `ButtonGroupText`, `buttonGroupVariants`.
|
|
35
|
+
- **Toggle**: A two-state button that can be either on or off. Exports: `Toggle`, `toggleVariants`.
|
|
36
|
+
- **Toggle Group**: A set of two-state buttons that can be toggled on or off. Exports: `ToggleGroup`, `ToggleGroupItem`.
|
|
37
|
+
|
|
38
|
+
## Inputs
|
|
39
|
+
|
|
40
|
+
- **Input**: Displays a form input field or a component that looks like an input field. Exports: `Input`.
|
|
41
|
+
- **Input Group**: Groups input elements with addons and buttons. Exports: `InputGroup`, `InputGroupAddon`, `InputGroupButton`, `InputGroupInput`, `InputGroupText`, `InputGroupTextarea`.
|
|
42
|
+
- **Textarea**: Displays a form textarea or a component that looks like a textarea. Exports: `Textarea`.
|
|
43
|
+
- **Select**: Displays a list of options for the user to pick from—triggered by a button. Exports: `Select`, `SelectContent`, `SelectGroup`, `SelectItem`, `SelectLabel`, `SelectScrollDownButton`, `SelectScrollUpButton`, `SelectSeparator`, `SelectTrigger`, `SelectValue`.
|
|
44
|
+
- **Combobox**: An autocomplete input with a filterable list, supporting single and multi-select with badges. Exports: `Combobox`, `ComboboxBadge`, `ComboboxBadgeList`, `ComboboxContent`, `ComboboxEmpty`, `ComboboxGroup`, `ComboboxInput`, `ComboboxItem`, `ComboboxList`, `ComboboxTrigger`.
|
|
45
|
+
- **Checkbox**: A control that allows the user to toggle between checked and not checked. Exports: `Checkbox`.
|
|
46
|
+
- **Radio Group**: A set of checkable buttons—known as radio buttons—where no more than one can be checked. Exports: `RadioGroup`, `RadioGroupItem`.
|
|
47
|
+
- **Switch**: A control that allows the user to toggle between on and off. Exports: `Switch`.
|
|
48
|
+
- **Slider**: An input where the user selects a value from within a given range. Exports: `Slider`.
|
|
49
|
+
- **Input OTP**: Accessible one-time password component with copy paste functionality. Exports: `InputOTP`, `InputOTPGroup`, `InputOTPSeparator`, `InputOTPSlot`.
|
|
50
|
+
- **Calendar**: A date field component that allows users to enter and edit dates. Exports: `Calendar`, `CalendarDayButton`.
|
|
51
|
+
- **Date Picker**: A date picker component that allows users to select a date from a calendar popover. Exports: `DatePicker`.
|
|
52
|
+
- **Filter Dropdown**: A versatile filter dropdown supporting multi-select, single-select, built-in search, and optional TanStack Table column integration. Use it in data table toolbars or as a standalone page-level filter. Exports: `FilterDropdown`.
|
|
53
|
+
|
|
54
|
+
## Forms
|
|
55
|
+
|
|
56
|
+
- **Form**: Exports: `CheckboxField`, `FormFieldError`, `RadioGroupField`, `SelectField`, `SubmitButton`, `SwitchField`, `TextareaField`, `TextField`, `useAppForm`, `useFieldContext`, `useFormContext`, `useTranslatedErrors`, `withForm`.
|
|
57
|
+
- **Field**: A form field component with label, input, and description. Exports: `Field`, `FieldContent`, `FieldDescription`, `FieldError`, `FieldGroup`, `FieldLabel`, `FieldLegend`, `FieldSeparator`, `FieldSet`, `FieldTitle`.
|
|
58
|
+
- **Label**: Renders an accessible label associated with controls. Exports: `Label`.
|
|
59
|
+
- **Form Wizard**: Exports: `FormWizard`, `FormWizardNav`, `FormWizardStep`, `FormWizardSteps`, `getVisibleSteps`, `useFormWizard`, `useFormWizardContext`.
|
|
60
|
+
|
|
61
|
+
## Overlays
|
|
62
|
+
|
|
63
|
+
- **Dialog**: A modal dialog that appears in front of app content to provide critical information. Exports: `Dialog`, `DialogClose`, `DialogContent`, `DialogDescription`, `DialogFooter`, `DialogHeader`, `DialogOverlay`, `DialogPortal`, `DialogTitle`, `DialogTrigger`.
|
|
64
|
+
- Use when the user must finish or dismiss a short, focused task before returning to the page, such as a small form or a single choice.
|
|
65
|
+
- Avoid when the content is a long form or a record's details, or the user needs to keep the page in view. Use **Sheet** instead.
|
|
66
|
+
- Avoid when the user confirms a destructive or irreversible action. Use **Alert Dialog** instead.
|
|
67
|
+
- Avoid when the content is a few extra controls or details anchored to a trigger. Use **Popover** instead.
|
|
68
|
+
|
|
69
|
+
```tsx
|
|
70
|
+
import {
|
|
71
|
+
Button,
|
|
72
|
+
Dialog,
|
|
73
|
+
DialogContent,
|
|
74
|
+
DialogDescription,
|
|
75
|
+
DialogFooter,
|
|
76
|
+
DialogHeader,
|
|
77
|
+
DialogTitle,
|
|
78
|
+
DialogTrigger,
|
|
79
|
+
} from "@uipath/apollo-vertex";
|
|
80
|
+
|
|
81
|
+
<Dialog>
|
|
82
|
+
<DialogTrigger asChild>
|
|
83
|
+
<Button variant="outline">Rename</Button>
|
|
84
|
+
</DialogTrigger>
|
|
85
|
+
<DialogContent>
|
|
86
|
+
<DialogHeader>
|
|
87
|
+
<DialogTitle>Rename invoice</DialogTitle>
|
|
88
|
+
<DialogDescription>Everyone in the workspace sees the new name.</DialogDescription>
|
|
89
|
+
</DialogHeader>
|
|
90
|
+
{/* form fields */}
|
|
91
|
+
<DialogFooter>
|
|
92
|
+
<Button type="submit">Save</Button>
|
|
93
|
+
</DialogFooter>
|
|
94
|
+
</DialogContent>
|
|
95
|
+
</Dialog>
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
- **Alert Dialog**: A modal dialog that interrupts the user with important content and expects a response. Exports: `AlertDialog`, `AlertDialogAction`, `AlertDialogCancel`, `AlertDialogContent`, `AlertDialogDescription`, `AlertDialogFooter`, `AlertDialogHeader`, `AlertDialogOverlay`, `AlertDialogPortal`, `AlertDialogTitle`, `AlertDialogTrigger`.
|
|
99
|
+
- Use when the user must confirm or cancel an action that is destructive or cannot be undone, such as deleting a record.
|
|
100
|
+
- Avoid when the dialog holds a form or other content beyond a confirm or cancel choice. Use **Dialog** instead.
|
|
101
|
+
- **Sheet**: Extends the Dialog component to display content that complements the main content. Exports: `Sheet`, `SheetClose`, `SheetContent`, `SheetDescription`, `SheetFooter`, `SheetHeader`, `SheetTitle`, `SheetTrigger`.
|
|
102
|
+
- Use when the user views or edits a record, a long form, filters or settings in a side panel while the page stays in context.
|
|
103
|
+
- Avoid when the task is short and needs the user's full attention. Use **Dialog** instead.
|
|
104
|
+
- Avoid when the panel is for small screens and should slide up from the bottom and be dismissed with a swipe. Use **Drawer** instead.
|
|
105
|
+
- **Drawer**: A drawer component that slides in from the edge of the screen. Exports: `Drawer`, `DrawerClose`, `DrawerContent`, `DrawerDescription`, `DrawerFooter`, `DrawerHeader`, `DrawerOverlay`, `DrawerPortal`, `DrawerTitle`, `DrawerTrigger`.
|
|
106
|
+
- Use when the screen is small and the panel should slide up from the bottom edge and close with a swipe.
|
|
107
|
+
- Avoid when the layout is for desktop and needs a side panel for details or a form. Use **Sheet** instead.
|
|
108
|
+
- **Popover**: Displays rich content in a portal, triggered by a button. Exports: `Popover`, `PopoverAnchor`, `PopoverContent`, `PopoverTrigger`.
|
|
109
|
+
- **Hover Card**: For sighted users to preview content available behind a link. Exports: `HoverCard`, `HoverCardContent`, `HoverCardTrigger`.
|
|
110
|
+
- **Tooltip**: A popup that displays information related to an element when the element receives keyboard focus or the mouse hovers over it. Exports: `Tooltip`, `TooltipContent`, `TooltipProvider`, `TooltipTrigger`.
|
|
111
|
+
|
|
112
|
+
## Menus
|
|
113
|
+
|
|
114
|
+
- **Dropdown Menu**: Displays a menu to the user triggered by a button. Exports: `DropdownMenu`, `DropdownMenuCheckboxItem`, `DropdownMenuContent`, `DropdownMenuGroup`, `DropdownMenuItem`, `DropdownMenuLabel`, `DropdownMenuPortal`, `DropdownMenuRadioGroup`, `DropdownMenuRadioItem`, `DropdownMenuSeparator`, `DropdownMenuShortcut`, `DropdownMenuSub`, `DropdownMenuSubContent`, `DropdownMenuSubTrigger`, `DropdownMenuTrigger`.
|
|
115
|
+
- **Context Menu**: Displays a menu to the user triggered by a right-click or long-press. Exports: `ContextMenu`, `ContextMenuCheckboxItem`, `ContextMenuContent`, `ContextMenuGroup`, `ContextMenuItem`, `ContextMenuLabel`, `ContextMenuPortal`, `ContextMenuRadioGroup`, `ContextMenuRadioItem`, `ContextMenuSeparator`, `ContextMenuShortcut`, `ContextMenuSub`, `ContextMenuSubContent`, `ContextMenuSubTrigger`, `ContextMenuTrigger`.
|
|
116
|
+
- **Menubar**: A visually persistent menu common in desktop applications. Exports: `Menubar`, `MenubarCheckboxItem`, `MenubarContent`, `MenubarGroup`, `MenubarItem`, `MenubarLabel`, `MenubarMenu`, `MenubarPortal`, `MenubarRadioGroup`, `MenubarRadioItem`, `MenubarSeparator`, `MenubarShortcut`, `MenubarSub`, `MenubarSubContent`, `MenubarSubTrigger`, `MenubarTrigger`.
|
|
117
|
+
- **Command**: Fast, composable, unstyled command menu for React. Exports: `Command`, `CommandDialog`, `CommandEmpty`, `CommandGroup`, `CommandInput`, `CommandItem`, `CommandList`, `CommandSeparator`, `CommandShortcut`.
|
|
118
|
+
- **Navigation Menu**: A collection of links for navigating websites. Exports: `NavigationMenu`, `NavigationMenuContent`, `NavigationMenuIndicator`, `NavigationMenuItem`, `NavigationMenuLink`, `NavigationMenuList`, `NavigationMenuTrigger`, `navigationMenuTriggerStyle`, `NavigationMenuViewport`.
|
|
119
|
+
|
|
120
|
+
## Layout and navigation
|
|
121
|
+
|
|
122
|
+
- **Card**: Exports: `Card`, `CardAction`, `CardContent`, `CardDescription`, `CardFooter`, `CardHeader`, `CardTitle`, `cardVariants`, `GLASS_CLASSES`.
|
|
123
|
+
- **Tabs**: A set of layered sections of content—known as tab panels—that are displayed one at a time. Exports: `Tabs`, `TabsContent`, `TabsList`, `TabsTrigger`.
|
|
124
|
+
- **Breadcrumb**: Displays the path to the current resource using a hierarchy of links. Exports: `Breadcrumb`, `BreadcrumbEllipsis`, `BreadcrumbItem`, `BreadcrumbLink`, `BreadcrumbList`, `BreadcrumbPage`, `BreadcrumbSeparator`.
|
|
125
|
+
- **Sidebar**: A composable, themeable and customizable sidebar component. Exports: `Sidebar`, `SidebarContent`, `SidebarFooter`, `SidebarGroup`, `SidebarGroupAction`, `SidebarGroupContent`, `SidebarGroupLabel`, `SidebarHeader`, `SidebarInput`, `SidebarInset`, `SidebarMenu`, `SidebarMenuAction`, `SidebarMenuBadge`, `SidebarMenuButton`, `sidebarMenuButtonVariants`, `SidebarMenuItem`, `SidebarMenuSkeleton`, `SidebarMenuSub`, `SidebarMenuSubButton`, `SidebarMenuSubItem`, `SidebarProvider`, `SidebarRail`, `SidebarSeparator`, `SidebarTrigger`, `useSidebar`.
|
|
126
|
+
- **Accordion**: A vertically stacked set of interactive headings that each reveal a section of content. Exports: `Accordion`, `AccordionContent`, `AccordionItem`, `AccordionTrigger`.
|
|
127
|
+
- **Collapsible**: An interactive component which expands/collapses a panel. Exports: `Collapsible`, `CollapsibleContent`, `CollapsibleTrigger`.
|
|
128
|
+
- **Separator**: Visually or semantically separates content. Exports: `Separator`.
|
|
129
|
+
- **Resizable**: Accessible resizable panel groups and layouts with keyboard support. Exports: `ResizableHandle`, `ResizablePanel`, `ResizablePanelGroup`.
|
|
130
|
+
- **Scroll Area**: Augments native scroll functionality for custom, cross-browser styling. Exports: `ScrollArea`, `ScrollBar`.
|
|
131
|
+
- **Aspect Ratio**: Displays content within a desired ratio. Exports: `AspectRatio`.
|
|
132
|
+
|
|
133
|
+
## Data display
|
|
134
|
+
|
|
135
|
+
- **Data Table**: A data table built on TanStack Table with sorting, filtering, pagination and row selection. Exports: `DataTable`, `DataTableCell`, `DataTableColumnHeader`, `dataTableFacetedFilterFn`, `dataTableGlobalFilterFn`, `DataTablePagination`, `DataTableRow`, `DataTableSearch`, `DataTableSkeleton`, `DataTableToolbar`, `DataTableViewOptions`, `useDataTable`, `useEntityColumns`, `useEntityDataTable`.
|
|
136
|
+
- Use when a list of records needs sorting, filtering, search, pagination, row selection or column visibility.
|
|
137
|
+
- Avoid when the data is a small, static table with no interaction. Use **Table** instead.
|
|
138
|
+
|
|
139
|
+
```tsx
|
|
140
|
+
import { type ColumnDef, DataTable, useDataTable } from "@uipath/apollo-vertex";
|
|
141
|
+
|
|
142
|
+
const columns: ColumnDef<Invoice>[] = [
|
|
143
|
+
{ accessorKey: "number", header: "Number" },
|
|
144
|
+
{ accessorKey: "amount", header: "Amount" },
|
|
145
|
+
];
|
|
146
|
+
|
|
147
|
+
function InvoicesTable({ data }: { data: Invoice[] }) {
|
|
148
|
+
const tableState = useDataTable({ data, columns, storageKey: "invoices" });
|
|
149
|
+
return <DataTable {...tableState} />;
|
|
150
|
+
}
|
|
151
|
+
```
|
|
152
|
+
|
|
153
|
+
- **Table**: A responsive table component for displaying data. Exports: `Table`, `TableBody`, `TableCaption`, `TableCell`, `TableFooter`, `TableHead`, `TableHeader`, `TableRow`.
|
|
154
|
+
- Use when the data is small and static, such as a summary or a comparison, and needs no sorting, filtering or pagination.
|
|
155
|
+
- Avoid when users sort, filter, search, page through or select rows. Use **Data Table** instead.
|
|
156
|
+
- **Pagination**: Pagination with page navigation, next and previous links. Exports: `Pagination`, `PaginationContent`, `PaginationEllipsis`, `PaginationItem`, `PaginationLink`, `PaginationNext`, `PaginationPrevious`.
|
|
157
|
+
- **Item**: A versatile list item component for displaying content in lists. Exports: `Item`, `ItemActions`, `ItemContent`, `ItemDescription`, `ItemFooter`, `ItemGroup`, `ItemHeader`, `ItemMedia`, `ItemSeparator`, `ItemTitle`.
|
|
158
|
+
- **Timeline**: Primitives for building an activity timeline: a status marker (the dot) and the row layout (the connecting line and dot slot a row sits in). Together they render a mixed trail of human and agent steps, without knowing anything about your domain. Exports: `TimelineMarker`, `TimelineRowLayout`.
|
|
159
|
+
- **Avatar**: An image element with a fallback for representing the user. Exports: `Avatar`, `AvatarFallback`, `AvatarImage`.
|
|
160
|
+
- **Badge**: Displays a badge or a component that looks like a badge. Exports: `Badge`, `badgeVariants`.
|
|
161
|
+
- **Kbd**: The keyboard key component is used to display keyboard shortcuts. Exports: `Kbd`, `KbdGroup`.
|
|
162
|
+
- **Carousel**: A carousel with motion and swipe built using Embla. Exports: `Carousel`, `CarouselContent`, `CarouselItem`, `CarouselNext`, `CarouselPrevious`.
|
|
163
|
+
|
|
164
|
+
## Feedback
|
|
165
|
+
|
|
166
|
+
- **Alert**: Displays a callout for user attention. Exports: `Alert`, `AlertDescription`, `AlertTitle`, `alertVariants`.
|
|
167
|
+
- Use when feedback must stay visible in context, such as validation errors, warnings or a blocking error.
|
|
168
|
+
- Use when the user must act on the message, or the system raised it without a user action. With no related UI to anchor it to, show it as a persistent full-width banner below the main header.
|
|
169
|
+
- Avoid when the message only confirms that an action the user just took succeeded. Use **Sonner** instead.
|
|
170
|
+
- **Sonner**: An opinionated toast component for React. Exports: `apolloToastClassNames`, `Toaster`.
|
|
171
|
+
- Use when the message briefly confirms an action the user just took and asks nothing of them, such as "Changes saved".
|
|
172
|
+
- Avoid when the message is a blocking error or a validation error, needs user input, or was raised by the system without a user action. Use **Alert** instead.
|
|
173
|
+
|
|
174
|
+
```tsx
|
|
175
|
+
// Render <Toaster /> once in the root layout. toast comes from the sonner package.
|
|
176
|
+
import { Toaster } from "@uipath/apollo-vertex";
|
|
177
|
+
import { toast } from "sonner";
|
|
178
|
+
|
|
179
|
+
<Toaster />
|
|
180
|
+
|
|
181
|
+
toast.success("Changes saved", { description: "Your updates have been applied." });
|
|
182
|
+
```
|
|
183
|
+
|
|
184
|
+
- **Empty**: An empty state component for when there is no data to display. Exports: `Empty`, `EmptyContent`, `EmptyDescription`, `EmptyHeader`, `EmptyMedia`, `EmptyTitle`.
|
|
185
|
+
- Use when a list, table, search result or page has nothing to show. Say why it is empty and offer the next action when there is one.
|
|
186
|
+
- Avoid when the content is still loading. Use **Skeleton** instead.
|
|
187
|
+
- Avoid when loading the content failed. Use **Alert** instead.
|
|
188
|
+
- **Skeleton**: Use to show a placeholder while content is loading. Exports: `Skeleton`.
|
|
189
|
+
- **Spinner**: A loading spinner component to indicate loading state. Exports: `Spinner`.
|
|
190
|
+
- **Progress**: Displays an indicator showing the completion progress of a task. Exports: `Progress`.
|
|
191
|
+
- **Confidence Signal**: A single chip for communicating AI confidence — used everywhere the system needs to say "can you act on this, or should you pause?" Exports: `ConfidenceSignal`, `SignalBars`.
|
|
192
|
+
|
|
193
|
+
## Charts
|
|
194
|
+
|
|
195
|
+
- **Chart**: Beautiful charts using Recharts with consistent theming and styling. Exports: `ChartContainer`, `ChartLegend`, `ChartLegendContent`, `ChartStyle`, `ChartTooltip`, `ChartTooltipContent`.
|
|
196
|
+
- **Line Chart**: A time-series line chart over a datetime dimension. Exports: `LineChart`, `LineChartWithAdapter`.
|
|
197
|
+
- **Multi-Line Chart**: Two metrics on a shared datetime axis with independent left and right Y axes. Exports: `MultiLineChart`, `MultiLineChartWithAdapter`.
|
|
198
|
+
- **Bar Chart**: A metric broken down by a categorical dimension. Exports: `BarChart`, `BarChartWithAdapter`.
|
|
199
|
+
- **Distribution Chart**: A histogram over a numeric or datetime dimension. Bins are computed by the adapter and rendered as bars. Exports: `DistributionChart`, `DistributionChartWithAdapter`.
|
|
200
|
+
- **KPI Chart**: A single scalar metric. No dimension, no breakdown — just a label and a formatted value. Exports: `KpiChart`, `KpiChartWithAdapter`.
|
|
201
|
+
- **Table Chart**: A sortable table of entity rows. Use for record-level views — no aggregation, just listing. Exports: `TableChart`, `TableChartWithAdapter`.
|
|
202
|
+
|
|
203
|
+
## Utilities
|
|
204
|
+
|
|
205
|
+
- **Feature Flags**: A generic feature flag system with a provider pattern, reactive hook, and guard components. Designed for Proteus SDK integration but supports any backend via adapters. Exports: `createProteusProvider`, `FeatureFlagContext`, `FeatureFlagGuard`, `FeatureFlagProvider`, `ProtectedFeatureRoute`, `useFeatureFlag`, `useFeatureFlagProvider`.
|
|
206
|
+
|
|
207
|
+
## Patterns
|
|
208
|
+
|
|
209
|
+
- **AI Chat**: Exports: `AiChat`, `AiChatEmptyState`, `AutopilotGradientIcon`, `CHOICES_TOOL_PROMPT`, `createAgentHubConnection`, `createConversationalAgentConnection`, `createDataFabricBarTool`, `createDataFabricDistributionTool`, `createDataFabricKpiTool`, `createDataFabricLineTool`, `createDataFabricMultiLineTool`, `createDataFabricTableTool`, `dataFabricBarClient`, `dataFabricDistributionClient`, `dataFabricKpiClient`, `dataFabricLineClient`, `dataFabricMultiLineClient`, `dataFabricTableClient`, `generateEntityFieldsDocs`, `NoDataMessage`, `presentChoicesClient`, `renderChoices`.
|
|
210
|
+
- **Feedback Vote Widget**: Exports: `FeedbackVoteWidget`.
|
|
211
|
+
- **Metric Card**: Displays a labeled metric with a value, optional trend direction, and percentage change badge. Includes a skeleton loading state for consistent UX during data fetches. Exports: `MetricCard`, `MetricCardSkeleton`.
|
|
212
|
+
- **Page Header**: A compound page header with back navigation, title, metadata fields, and collapsible action buttons that automatically overflow into a dropdown when space is tight. Exports: `PageHeader`, `PageHeaderActions`, `PageHeaderActionsOverflow`, `PageHeaderBackButton`, `PageHeaderCollapsibleActions`, `PageHeaderContent`, `PageHeaderDescription`, `PageHeaderField`, `PageHeaderFieldLabel`, `PageHeaderFieldValue`, `PageHeaderNav`, `PageHeaderTitle`, `PageHeaderTitleGroup`, `pageHeaderTitleVariants`, `pageHeaderVariants`.
|
|
213
|
+
- **Shell**: A component with a collapsible sidebar, theme and language toggles, and optional OAuth2 authentication. Exports: `ApolloShell`, `AuthContext`, `GroupMembershipGuard`, `LocaleProvider`, `MembershipDenied`, `Role`, `ShellAuthProvider`, `ShellLayout`, `ShellLogin`, `ShellSidebar`, `ShellUserProvider`, `STALE_TIME_MS`, `ThemeProvider`, `useAccessToken`, `useAuth`, `useGroupId`, `useGroupMembers`, `useIsGroupMember`, `useTheme`, `useUser`, `VerifyingMembership`.
|