136 lines
5.7 KiB
JavaScript
136 lines
5.7 KiB
JavaScript
/**
|
|
* KROW design system — the single import surface for building pages.
|
|
*
|
|
* import { PageHeader, KpiCard, DataTable, StatusBadge } from '@/components/ds';
|
|
*
|
|
* Two layers sit underneath:
|
|
*
|
|
* - `components/ui/*` — Radix-based primitives (the mechanics: focus traps,
|
|
* portals, keyboard handling). Restyled to the KROW tokens, not re-wrapped.
|
|
* - `components/ds/*` — the app's own composites, built from those primitives.
|
|
*
|
|
* Primitives that need no composition are re-exported here rather than
|
|
* duplicated, so there is exactly one Tooltip, one Popover and one Checkbox in
|
|
* the codebase and pages never need to know which layer a component came from.
|
|
*/
|
|
|
|
/* ── Foundation ─────────────────────────────────────────────────────────── */
|
|
export { Surface, surfaceVariants } from './Surface';
|
|
export { PageHeader, HeroHeader } from './PageHeader';
|
|
export { SectionHeader } from './SectionHeader';
|
|
|
|
/* ── Actions ────────────────────────────────────────────────────────────── */
|
|
export { Button, buttonVariants } from '@/components/ui/button';
|
|
export { IconButton } from './IconButton';
|
|
|
|
/* ── Forms & controls ───────────────────────────────────────────────────── */
|
|
export { Field } from './Field';
|
|
export { Input, inputVariants } from '@/components/ui/input';
|
|
export { Textarea } from '@/components/ui/textarea';
|
|
export { Label } from '@/components/ui/label';
|
|
export { SearchInput } from './SearchInput';
|
|
export { MultiSelect } from './MultiSelect';
|
|
export { Toggle, SegmentedToggle } from './Toggle';
|
|
export { Checkbox } from '@/components/ui/checkbox';
|
|
export { RadioGroup, RadioGroupItem } from '@/components/ui/radio-group';
|
|
export { Switch } from '@/components/ui/switch';
|
|
export { Slider } from '@/components/ui/slider';
|
|
export {
|
|
Select,
|
|
SelectContent,
|
|
SelectGroup,
|
|
SelectItem,
|
|
SelectLabel,
|
|
SelectSeparator,
|
|
SelectTrigger,
|
|
SelectValue,
|
|
} from '@/components/ui/select';
|
|
|
|
/* ── Identity & status ──────────────────────────────────────────────────── */
|
|
export { Avatar, AvatarGroup, initialsFrom } from './Avatar';
|
|
export { Badge, badgeVariants } from '@/components/ui/badge';
|
|
export { StatusBadge, STATUS_MAP } from './StatusBadge';
|
|
|
|
/* ── Navigation ─────────────────────────────────────────────────────────── */
|
|
export { Tabs } from './Tabs';
|
|
export { Pagination, buildPageRange } from './Pagination';
|
|
export {
|
|
Breadcrumb,
|
|
BreadcrumbEllipsis,
|
|
BreadcrumbItem,
|
|
BreadcrumbLink,
|
|
BreadcrumbList,
|
|
BreadcrumbPage,
|
|
BreadcrumbSeparator,
|
|
} from '@/components/ui/breadcrumb';
|
|
|
|
/* ── Overlays ───────────────────────────────────────────────────────────── */
|
|
export { Modal, ConfirmModal } from './Modal';
|
|
export { Drawer } from './Drawer';
|
|
export {
|
|
DropdownMenu,
|
|
DropdownMenuContent,
|
|
DropdownMenuGroup,
|
|
DropdownMenuItem,
|
|
DropdownMenuLabel,
|
|
DropdownMenuSeparator,
|
|
DropdownMenuSub,
|
|
DropdownMenuSubContent,
|
|
DropdownMenuSubTrigger,
|
|
DropdownMenuTrigger,
|
|
} from '@/components/ui/dropdown-menu';
|
|
export { Popover, PopoverContent, PopoverTrigger } from '@/components/ui/popover';
|
|
/* Radix Collapsible, already present and previously unexported. The agent
|
|
configuration screen is a stack of long sections, and a page that opened all
|
|
of them at once would bury the one being edited. */
|
|
export {
|
|
Collapsible,
|
|
CollapsibleContent,
|
|
CollapsibleTrigger,
|
|
} from '@/components/ui/collapsible';
|
|
export { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from '@/components/ui/tooltip';
|
|
export { HoverCard, HoverCardContent, HoverCardTrigger } from '@/components/ui/hover-card';
|
|
|
|
/* ── Feedback ───────────────────────────────────────────────────────────── */
|
|
export { Alert } from './Alert';
|
|
export { toast } from './toast';
|
|
export { EmptyState } from './EmptyState';
|
|
export { LoadingState, LoadingOverlay, InlineLoading, Spinner } from './LoadingState';
|
|
export {
|
|
Skeleton,
|
|
SkeletonCard,
|
|
SkeletonChart,
|
|
SkeletonKpi,
|
|
SkeletonList,
|
|
SkeletonRow,
|
|
SkeletonTable,
|
|
SkeletonText,
|
|
} from './Skeleton';
|
|
|
|
/* ── Data display ───────────────────────────────────────────────────────── */
|
|
export { KpiCard, MetricCard } from './KpiCard';
|
|
export { MetricStrip } from './MetricStrip';
|
|
export { InsightList, InsightRow } from './InsightRow';
|
|
export { DataTable } from './DataTable';
|
|
export { FilterBar } from './FilterBar';
|
|
export { Timeline } from './Timeline';
|
|
export { ActivityCard } from './ActivityCard';
|
|
export {
|
|
AXIS_PROPS,
|
|
CHART_COLORS,
|
|
CHART_TONES,
|
|
ChartContainer,
|
|
ChartLegend,
|
|
ChartTooltip,
|
|
} from './ChartContainer';
|
|
export {
|
|
ProgressBar,
|
|
ProgressRing,
|
|
ProgressSteps,
|
|
ScoreMeter,
|
|
toneForScore,
|
|
} from './Progress';
|
|
|
|
/* ── Layout helpers ─────────────────────────────────────────────────────── */
|
|
export { Grid, PageSection, Stack } from './Layout';
|