@siyahi/ui 0.1.9-next.21 → 0.1.9-next.23

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 (93) hide show
  1. package/DESIGN.md +16 -3
  2. package/agents/examples/accordion.tsx +7 -7
  3. package/agents/examples/alert.tsx +16 -15
  4. package/agents/examples/app-sidebar.tsx +3 -1
  5. package/agents/examples/badge.tsx +20 -12
  6. package/agents/examples/bar-list-labels.tsx +6 -6
  7. package/agents/examples/bar-list-sides.tsx +18 -16
  8. package/agents/examples/bar-list.tsx +8 -8
  9. package/agents/examples/breadcrumb.tsx +3 -3
  10. package/agents/examples/calendar.tsx +3 -7
  11. package/agents/examples/callout.tsx +15 -15
  12. package/agents/examples/card.tsx +5 -3
  13. package/agents/examples/change-bar.tsx +21 -21
  14. package/agents/examples/chart-area.tsx +11 -11
  15. package/agents/examples/chart-bar-flows.tsx +1 -1
  16. package/agents/examples/chart-bar-hourly.tsx +1 -1
  17. package/agents/examples/chart-bar-losses.tsx +3 -3
  18. package/agents/examples/chart-bar-teams.tsx +72 -0
  19. package/agents/examples/chart-bar-years.tsx +5 -5
  20. package/agents/examples/chart-bar.tsx +10 -10
  21. package/agents/examples/chart-category-ticks.tsx +6 -6
  22. package/agents/examples/chart-line.tsx +17 -17
  23. package/agents/examples/collapsible.tsx +5 -3
  24. package/agents/examples/command.tsx +23 -21
  25. package/agents/examples/context-menu.tsx +6 -4
  26. package/agents/examples/data-bar.tsx +32 -45
  27. package/agents/examples/data-table-compact.tsx +31 -30
  28. package/agents/examples/data-table-filters.tsx +20 -20
  29. package/agents/examples/data-table.tsx +31 -30
  30. package/agents/examples/dialog.tsx +3 -3
  31. package/agents/examples/distribution-bar-tug.tsx +36 -34
  32. package/agents/examples/dropdown-menu.tsx +2 -2
  33. package/agents/examples/heatmap-calendar.tsx +12 -10
  34. package/agents/examples/heatmap-status.tsx +11 -9
  35. package/agents/examples/heatmap-weekday.tsx +27 -30
  36. package/agents/examples/input-states.tsx +9 -9
  37. package/agents/examples/input.tsx +3 -3
  38. package/agents/examples/local-time.tsx +1 -1
  39. package/agents/examples/metric-strip.tsx +8 -8
  40. package/agents/examples/page-hero.tsx +2 -2
  41. package/agents/examples/popover.tsx +3 -3
  42. package/agents/examples/price-chart.tsx +5 -5
  43. package/agents/examples/progress-tone.tsx +10 -9
  44. package/agents/examples/progress.tsx +1 -1
  45. package/agents/examples/range-position-table.tsx +31 -31
  46. package/agents/examples/range-position.tsx +31 -29
  47. package/agents/examples/scroll-area.tsx +12 -10
  48. package/agents/examples/section-cards-select.tsx +11 -10
  49. package/agents/examples/section-cards-trend.tsx +4 -4
  50. package/agents/examples/section-cards.tsx +13 -13
  51. package/agents/examples/select.tsx +9 -9
  52. package/agents/examples/separator.tsx +3 -3
  53. package/agents/examples/sheet.tsx +1 -1
  54. package/agents/examples/slider.tsx +1 -1
  55. package/agents/examples/surfaces.tsx +16 -16
  56. package/agents/examples/tabs.tsx +7 -7
  57. package/agents/examples/target-rows.tsx +31 -27
  58. package/agents/examples/tooltip.tsx +2 -2
  59. package/agents/examples/treemap.tsx +38 -33
  60. package/agents/manifest.json +15 -15
  61. package/dist/components/registry/charts/bar-chart-card.d.ts +1 -1
  62. package/dist/components/registry/charts/bar-chart-card.js +6 -2
  63. package/dist/components/registry/charts/line-chart-card.d.ts +1 -1
  64. package/dist/components/registry/charts/line-chart-card.js +1 -1
  65. package/dist/components/registry/dashboard-01/section-cards.js +1 -1
  66. package/dist/components/registry/dashboardcn/distribution-bar.js +5 -3
  67. package/dist/components/registry/heatmap/status-heatmap.js +1 -1
  68. package/dist/components/siyahi/callout.d.ts +5 -12
  69. package/dist/components/siyahi/callout.js +5 -11
  70. package/dist/components/siyahi/delta.d.ts +5 -1
  71. package/dist/components/siyahi/delta.js +14 -9
  72. package/dist/components/siyahi/status-alert.d.ts +15 -0
  73. package/dist/components/siyahi/status-alert.js +29 -0
  74. package/dist/components/siyahi/status-badge.d.ts +15 -0
  75. package/dist/components/siyahi/status-badge.js +24 -0
  76. package/dist/components/siyahi/tone-progress.d.ts +1 -1
  77. package/dist/components/siyahi/tone-progress.js +1 -1
  78. package/dist/components/siyahi/treemap.d.ts +4 -4
  79. package/dist/components/siyahi/treemap.js +5 -5
  80. package/dist/index.d.ts +5 -4
  81. package/dist/index.js +3 -2
  82. package/dist/lib/chart-frame.js +1 -1
  83. package/dist/lib/chart-series.d.ts +1 -1
  84. package/dist/lib/format.d.ts +1 -1
  85. package/dist/lib/format.js +1 -1
  86. package/dist/lib/tone.d.ts +36 -0
  87. package/dist/lib/tone.js +35 -0
  88. package/package.json +1 -1
  89. package/report.css +14 -14
  90. package/styles/siyahi.css +92 -20
  91. package/agents/examples/chart-bar-sectors.tsx +0 -72
  92. package/dist/components/siyahi/warning-alert.d.ts +0 -10
  93. package/dist/components/siyahi/warning-alert.js +0 -20
package/dist/index.d.ts CHANGED
@@ -70,15 +70,16 @@ import { Quote, QuoteProps } from "./components/siyahi/quote.js";
70
70
  import { RangePosition, RangePositionProps } from "./components/siyahi/range-position.js";
71
71
  import { SiyahiLocale, defaultLocale } from "./lib/locale.js";
72
72
  import { SiyahiProvider, SiyahiProviderProps, Surface, useLocale, useSurface } from "./components/siyahi/siyahi-provider.js";
73
+ import { Alert, AlertAction, AlertDescription, AlertTitle } from "./components/ui/alert.js";
74
+ import { StatusAlert, StatusAlertProps } from "./components/siyahi/status-alert.js";
75
+ import { Badge, badgeVariants } from "./components/ui/badge.js";
76
+ import { StatusBadge, StatusBadgeProps } from "./components/siyahi/status-badge.js";
73
77
  import { TargetRow, TargetRows, TargetRowsProps, TargetStatus } from "./components/siyahi/target-rows.js";
74
78
  import { Progress, ProgressIndicator, ProgressLabel, ProgressTrack, ProgressValue } from "./components/ui/progress.js";
75
79
  import { ToneProgress, ToneProgressProps } from "./components/siyahi/tone-progress.js";
76
80
  import { Treemap, TreemapItem, TreemapLegend, TreemapLegendProps, TreemapProps } from "./components/siyahi/treemap.js";
77
- import { Alert, AlertAction, AlertDescription, AlertTitle } from "./components/ui/alert.js";
78
- import { WarningAlert } from "./components/siyahi/warning-alert.js";
79
81
  import { Accordion, AccordionContent, AccordionItem, AccordionTrigger } from "./components/ui/accordion.js";
80
82
  import { Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage } from "./components/ui/avatar.js";
81
- import { Badge, badgeVariants } from "./components/ui/badge.js";
82
83
  import { Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator } from "./components/ui/breadcrumb.js";
83
84
  import { Calendar, CalendarDayButton } from "./components/ui/calendar.js";
84
85
  import { ChartConfig, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent } from "./components/ui/chart.js";
@@ -100,4 +101,4 @@ import { Textarea } from "./components/ui/textarea.js";
100
101
  import { Toggle, toggleVariants } from "./components/ui/toggle.js";
101
102
  import { ToggleGroup, ToggleGroupItem } from "./components/ui/toggle-group.js";
102
103
  import { Formatters, TimeOptions, count, money, moneyCompact, pct, time, useFormat } from "./lib/format.js";
103
- export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, ActiveCell, ActiveSelection, Activity, Alert, AlertAction, AlertDescription, AlertTitle, AppSidebar, AppSidebarProps, AreaChartCard, AreaChartCardProps, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage, Badge, BarChartCard, BarChartCardProps, BarList, BarListItem, BarListProps, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button, Calendar, CalendarDayButton, CalendarHeatmap, CalendarHeatmapBlock, CalendarHeatmapBlockProps, CalendarHeatmapBody, CalendarHeatmapBodyProps, CalendarHeatmapFooter, CalendarHeatmapFooterProps, CalendarHeatmapLegend, CalendarHeatmapLegendProps, CalendarHeatmapProps, CalendarHeatmapStat, CalendarHeatmapStatProps, Callout, CalloutProps, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, ChangeBar, ChangeBarProps, ChartColor, ChartConfig, ChartContainer, ChartCurve, ChartLegend, ChartLegendContent, ChartReferenceLine, ChartSeries, ChartSeriesItem, ChartStyle, ChartTooltip, ChartTooltipContent, CodeBlock, CodeBlockActions, CodeBlockContent, CodeBlockCopyButton, CodeBlockFooter, CodeBlockHeader, CodeBlockLine, CodeBlockTitle, Collapsible, CollapsibleContent, CollapsibleTrigger, ColorConfig, ColumnResizeInfo, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, CompactColumns, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, CopyButton, DataBar, DataBarProps, DataList, DataListItem, DataListItemProps, DataTable, DataTableActions, DataTableBody, DataTableBodyProps, type DataTableCell, type DataTableColumn, DataTableColumnActions, type DataTableColumnDef, DataTableColumnFilter, DataTableColumnHeader, DataTableColumnHeaderProps, DataTableColumnHeaderRoot, DataTableColumnSortMenu, DataTableColumnSortOptions, DataTableColumnTitle, type DataTableColumns, DataTableCompactColumnsToggle, DataTableConfig, DataTableContainerProps, DataTableContext, DataTableContextState, DataTableEmptyActions, DataTableEmptyActionsProps, DataTableEmptyBody, DataTableEmptyBodyProps, DataTableEmptyDescription, DataTableEmptyDescriptionProps, DataTableEmptyFilteredMessage, DataTableEmptyFilteredMessageProps, DataTableEmptyIcon, DataTableEmptyIconProps, DataTableEmptyMessage, DataTableEmptyMessageProps, DataTableEmptyState, DataTableEmptyStateProps, DataTableEmptyTitle, DataTableEmptyTitleProps, DataTableErrorBoundary, DataTableErrorBoundaryProps, DataTableFacetedFilter, DataTableFacetedFilterContent, DataTableFootnote, DataTableFootnoteProps, DataTableGroupRowContextValue, DataTableGroupRowProvider, DataTableGroupedRowCells, DataTableGroupedRows, DataTableGroupedRowsProps, DataTableHeader, type DataTableHeader$1 as DataTableHeaderCell, DataTableHeaderProps, type DataTableInstance, DataTableLoading, DataTableLoadingMore, DataTableLoadingMoreProps, DataTableLoadingProps, DataTableProvider, DataTableRoot, type DataTableRow, DataTableRowContextMenu, DataTableRowContextMenuProps, DataTableRowContextMenuSlot, DataTableRowContextMenuSlotProps, DataTableRowCount, DataTableRowCountProps, DataTableRowMenuScope, DataTableSearchFilter, DataTableSkeleton, DataTableSkeletonProps, DataTableSortHeader, DataTableToolbarSection, DataTableToolbarSectionProps, Delta, DeltaProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DistributionBar, DistributionBarProps, DistributionMarker, DistributionSegment, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, type ExtendedColumnFilter, type ExtendedColumnSort, type FilterOperator, type FilterOperatorValues, type FilterVariant, type FilterVariantValues, FlashCellRef, FlashCells, FlashRows, FlashRowsOptions, Formatters, type GlobalFilter, GroupedBodyRow, GroupedBodyRowProps, InlineCode, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, type JoinOperator, type JoinOperatorValues, Labels, LineChartCard, LineChartCardProps, LocalTime, LocalTimeProps, MetricStrip, MetricStripItem, MetricStripProps, NavMain, NavProjects, NavUser, NumericXProps, type Option, PageHero, PageHeroProps, PageSection, PageSectionProps, PageSubheading, PageToc, PageTocItem, PageTocProps, PanelGrid, PanelGridProps, Popover, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, PriceChart, PriceChartProps, Progress, ProgressIndicator, ProgressLabel, ProgressTrack, ProgressValue, type QueryKeys, Quote, QuoteProps, RangePosition, RangePositionProps, RowMenuGroup, RowMenuItem, RowMenuLabel, RowMenuSeparator, RowMenuSub, RowMenuSubContent, RowMenuSubTrigger, ScrollAlign, ScrollArea, ScrollBar, type ScrollEvent, ScrollRowIntoView, SectionCard, SectionCards, SectionCardsProps, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, SeriesChartProps, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, SiyahiLocale, SiyahiProvider, SiyahiProviderProps, Skeleton, Slider, Sparkline, SparklineProps, StatusActivity, StatusColorConfig, StatusHeatmap, StatusHeatmapBlock, StatusHeatmapBlockProps, StatusHeatmapBody, StatusHeatmapBodyProps, StatusHeatmapFooter, StatusHeatmapFooterProps, StatusHeatmapLabels, StatusHeatmapLegend, StatusHeatmapLegendProps, StatusHeatmapProps, StatusHeatmapStat, StatusHeatmapStatProps, StatusValue, Surface, Table, TableBody, TableCaption, TableCell, TableColumnActions, TableColumnActionsProps, TableColumnSortMenu, TableColumnSortOptions, TableColumnTitle, TableFacetedFilter, TableFacetedFilterContent, TableFacetedFilterProps, TableFooter, TableHead, TableHeader, TableRow, TableSearchFilter, TableSearchFilterProps, Tabs, TabsContent, TabsList, TabsTrigger, TargetRow, TargetRows, TargetRowsProps, TargetStatus, TeamSwitcher, Textarea, TimeOptions, Toggle, ToggleGroup, ToggleGroupItem, ToneProgress, ToneProgressProps, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, Treemap, TreemapItem, TreemapLegend, TreemapLegendProps, TreemapProps, type ValueOf, WarningAlert, type ColorConfig$1 as WeekdayColorConfig, type WeekdayExtraColumnSpec, type WeekdayExtraRowSpec, WeekdayHeatmap, WeekdayHeatmapBlock, type WeekdayHeatmapBlockProps, WeekdayHeatmapBody, type WeekdayHeatmapBodyProps, WeekdayHeatmapFooter, type WeekdayHeatmapFooterProps, type WeekdayHeatmapLabels, WeekdayHeatmapLegend, type WeekdayHeatmapLegendProps, type WeekdayHeatmapProps, WeekdayHeatmapStat, type WeekdayHeatmapStatProps, type WeekdayHour, type WeekdayHourlyActivity, type WeekdayIndex, badgeVariants, buttonVariants, count, defaultLocale, defaultSidebarOpen, flashCellKey, money, moneyCompact, pct, resolveGroupedRowsSlot, resolveRowContextMenuRenderer, tabsListVariants, time, toggleVariants, useColumnHeaderContext, useColumnResizeInfo, useDataTable, useDataTableActiveCell, useDataTableActiveCellSetter, useDataTableGroupRow, useDataTableRow, useFormat, useLocale, useResolvedRowContextMenuRenderer, useSidebar, useSurface, useTableFacetedFilter };
104
+ export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, ActiveCell, ActiveSelection, Activity, Alert, AlertAction, AlertDescription, AlertTitle, AppSidebar, AppSidebarProps, AreaChartCard, AreaChartCardProps, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage, Badge, BarChartCard, BarChartCardProps, BarList, BarListItem, BarListProps, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button, Calendar, CalendarDayButton, CalendarHeatmap, CalendarHeatmapBlock, CalendarHeatmapBlockProps, CalendarHeatmapBody, CalendarHeatmapBodyProps, CalendarHeatmapFooter, CalendarHeatmapFooterProps, CalendarHeatmapLegend, CalendarHeatmapLegendProps, CalendarHeatmapProps, CalendarHeatmapStat, CalendarHeatmapStatProps, Callout, CalloutProps, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, ChangeBar, ChangeBarProps, ChartColor, ChartConfig, ChartContainer, ChartCurve, ChartLegend, ChartLegendContent, ChartReferenceLine, ChartSeries, ChartSeriesItem, ChartStyle, ChartTooltip, ChartTooltipContent, CodeBlock, CodeBlockActions, CodeBlockContent, CodeBlockCopyButton, CodeBlockFooter, CodeBlockHeader, CodeBlockLine, CodeBlockTitle, Collapsible, CollapsibleContent, CollapsibleTrigger, ColorConfig, ColumnResizeInfo, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, CompactColumns, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, CopyButton, DataBar, DataBarProps, DataList, DataListItem, DataListItemProps, DataTable, DataTableActions, DataTableBody, DataTableBodyProps, type DataTableCell, type DataTableColumn, DataTableColumnActions, type DataTableColumnDef, DataTableColumnFilter, DataTableColumnHeader, DataTableColumnHeaderProps, DataTableColumnHeaderRoot, DataTableColumnSortMenu, DataTableColumnSortOptions, DataTableColumnTitle, type DataTableColumns, DataTableCompactColumnsToggle, DataTableConfig, DataTableContainerProps, DataTableContext, DataTableContextState, DataTableEmptyActions, DataTableEmptyActionsProps, DataTableEmptyBody, DataTableEmptyBodyProps, DataTableEmptyDescription, DataTableEmptyDescriptionProps, DataTableEmptyFilteredMessage, DataTableEmptyFilteredMessageProps, DataTableEmptyIcon, DataTableEmptyIconProps, DataTableEmptyMessage, DataTableEmptyMessageProps, DataTableEmptyState, DataTableEmptyStateProps, DataTableEmptyTitle, DataTableEmptyTitleProps, DataTableErrorBoundary, DataTableErrorBoundaryProps, DataTableFacetedFilter, DataTableFacetedFilterContent, DataTableFootnote, DataTableFootnoteProps, DataTableGroupRowContextValue, DataTableGroupRowProvider, DataTableGroupedRowCells, DataTableGroupedRows, DataTableGroupedRowsProps, DataTableHeader, type DataTableHeader$1 as DataTableHeaderCell, DataTableHeaderProps, type DataTableInstance, DataTableLoading, DataTableLoadingMore, DataTableLoadingMoreProps, DataTableLoadingProps, DataTableProvider, DataTableRoot, type DataTableRow, DataTableRowContextMenu, DataTableRowContextMenuProps, DataTableRowContextMenuSlot, DataTableRowContextMenuSlotProps, DataTableRowCount, DataTableRowCountProps, DataTableRowMenuScope, DataTableSearchFilter, DataTableSkeleton, DataTableSkeletonProps, DataTableSortHeader, DataTableToolbarSection, DataTableToolbarSectionProps, Delta, DeltaProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DistributionBar, DistributionBarProps, DistributionMarker, DistributionSegment, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, type ExtendedColumnFilter, type ExtendedColumnSort, type FilterOperator, type FilterOperatorValues, type FilterVariant, type FilterVariantValues, FlashCellRef, FlashCells, FlashRows, FlashRowsOptions, Formatters, type GlobalFilter, GroupedBodyRow, GroupedBodyRowProps, InlineCode, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, type JoinOperator, type JoinOperatorValues, Labels, LineChartCard, LineChartCardProps, LocalTime, LocalTimeProps, MetricStrip, MetricStripItem, MetricStripProps, NavMain, NavProjects, NavUser, NumericXProps, type Option, PageHero, PageHeroProps, PageSection, PageSectionProps, PageSubheading, PageToc, PageTocItem, PageTocProps, PanelGrid, PanelGridProps, Popover, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, PriceChart, PriceChartProps, Progress, ProgressIndicator, ProgressLabel, ProgressTrack, ProgressValue, type QueryKeys, Quote, QuoteProps, RangePosition, RangePositionProps, RowMenuGroup, RowMenuItem, RowMenuLabel, RowMenuSeparator, RowMenuSub, RowMenuSubContent, RowMenuSubTrigger, ScrollAlign, ScrollArea, ScrollBar, type ScrollEvent, ScrollRowIntoView, SectionCard, SectionCards, SectionCardsProps, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, SeriesChartProps, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, SiyahiLocale, SiyahiProvider, SiyahiProviderProps, Skeleton, Slider, Sparkline, SparklineProps, StatusActivity, StatusAlert, StatusAlertProps, StatusBadge, StatusBadgeProps, StatusColorConfig, StatusHeatmap, StatusHeatmapBlock, StatusHeatmapBlockProps, StatusHeatmapBody, StatusHeatmapBodyProps, StatusHeatmapFooter, StatusHeatmapFooterProps, StatusHeatmapLabels, StatusHeatmapLegend, StatusHeatmapLegendProps, StatusHeatmapProps, StatusHeatmapStat, StatusHeatmapStatProps, StatusValue, Surface, Table, TableBody, TableCaption, TableCell, TableColumnActions, TableColumnActionsProps, TableColumnSortMenu, TableColumnSortOptions, TableColumnTitle, TableFacetedFilter, TableFacetedFilterContent, TableFacetedFilterProps, TableFooter, TableHead, TableHeader, TableRow, TableSearchFilter, TableSearchFilterProps, Tabs, TabsContent, TabsList, TabsTrigger, TargetRow, TargetRows, TargetRowsProps, TargetStatus, TeamSwitcher, Textarea, TimeOptions, Toggle, ToggleGroup, ToggleGroupItem, ToneProgress, ToneProgressProps, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, Treemap, TreemapItem, TreemapLegend, TreemapLegendProps, TreemapProps, type ValueOf, type ColorConfig$1 as WeekdayColorConfig, type WeekdayExtraColumnSpec, type WeekdayExtraRowSpec, WeekdayHeatmap, WeekdayHeatmapBlock, type WeekdayHeatmapBlockProps, WeekdayHeatmapBody, type WeekdayHeatmapBodyProps, WeekdayHeatmapFooter, type WeekdayHeatmapFooterProps, type WeekdayHeatmapLabels, WeekdayHeatmapLegend, type WeekdayHeatmapLegendProps, type WeekdayHeatmapProps, WeekdayHeatmapStat, type WeekdayHeatmapStatProps, type WeekdayHour, type WeekdayHourlyActivity, type WeekdayIndex, badgeVariants, buttonVariants, count, defaultLocale, defaultSidebarOpen, flashCellKey, money, moneyCompact, pct, resolveGroupedRowsSlot, resolveRowContextMenuRenderer, tabsListVariants, time, toggleVariants, useColumnHeaderContext, useColumnResizeInfo, useDataTable, useDataTableActiveCell, useDataTableActiveCellSetter, useDataTableGroupRow, useDataTableRow, useFormat, useLocale, useResolvedRowContextMenuRenderer, useSidebar, useSurface, useTableFacetedFilter };
package/dist/index.js CHANGED
@@ -93,8 +93,9 @@ import { PanelGrid } from "./components/siyahi/panel-grid.js";
93
93
  import { PriceChart } from "./components/siyahi/price-chart.js";
94
94
  import { Quote } from "./components/siyahi/quote.js";
95
95
  import { RangePosition } from "./components/siyahi/range-position.js";
96
+ import { StatusAlert } from "./components/siyahi/status-alert.js";
97
+ import { StatusBadge } from "./components/siyahi/status-badge.js";
96
98
  import { TargetRows } from "./components/siyahi/target-rows.js";
97
99
  import { ToneProgress } from "./components/siyahi/tone-progress.js";
98
100
  import { Treemap, TreemapLegend } from "./components/siyahi/treemap.js";
99
- import { WarningAlert } from "./components/siyahi/warning-alert.js";
100
- export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertAction, AlertDescription, AlertTitle, AppSidebar, AreaChartCard, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage, Badge, BarChartCard, BarList, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button, Calendar, CalendarDayButton, CalendarHeatmap, CalendarHeatmapBlock, CalendarHeatmapBody, CalendarHeatmapFooter, CalendarHeatmapLegend, CalendarHeatmapStat, Callout, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, ChangeBar, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, CodeBlock, CodeBlockActions, CodeBlockContent, CodeBlockCopyButton, CodeBlockFooter, CodeBlockHeader, CodeBlockLine, CodeBlockTitle, Collapsible, CollapsibleContent, CollapsibleTrigger, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, CopyButton, DataBar, DataList, DataListItem, DataTable, DataTableActions, DataTableBody, DataTableColumnActions, DataTableColumnFilter, DataTableColumnHeader, DataTableColumnHeaderRoot, DataTableColumnSortMenu, DataTableColumnSortOptions, DataTableColumnTitle, DataTableCompactColumnsToggle, DataTableContext, DataTableEmptyActions, DataTableEmptyBody, DataTableEmptyDescription, DataTableEmptyFilteredMessage, DataTableEmptyIcon, DataTableEmptyMessage, DataTableEmptyState, DataTableEmptyTitle, DataTableErrorBoundary, DataTableFacetedFilter, DataTableFacetedFilterContent, DataTableFootnote, DataTableGroupRowProvider, DataTableGroupedRowCells, DataTableGroupedRows, DataTableHeader, DataTableLoading, DataTableLoadingMore, DataTableProvider, DataTableRoot, DataTableRowContextMenu, DataTableRowContextMenuSlot, DataTableRowCount, DataTableRowMenuScope, DataTableSearchFilter, DataTableSkeleton, DataTableSortHeader, DataTableToolbarSection, Delta, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DistributionBar, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, GroupedBodyRow, InlineCode, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, LineChartCard, LocalTime, MetricStrip, NavMain, NavProjects, NavUser, PageHero, PageSection, PageSubheading, PageToc, PanelGrid, Popover, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, PriceChart, Progress, ProgressIndicator, ProgressLabel, ProgressTrack, ProgressValue, Quote, RangePosition, RowMenuGroup, RowMenuItem, RowMenuLabel, RowMenuSeparator, RowMenuSub, RowMenuSubContent, RowMenuSubTrigger, ScrollArea, ScrollBar, SectionCards, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, SiyahiProvider, Skeleton, Slider, Sparkline, StatusHeatmap, StatusHeatmapBlock, StatusHeatmapBody, StatusHeatmapFooter, StatusHeatmapLegend, StatusHeatmapStat, Table, TableBody, TableCaption, TableCell, TableColumnActions, TableColumnSortMenu, TableColumnSortOptions, TableColumnTitle, TableFacetedFilter, TableFacetedFilterContent, TableFooter, TableHead, TableHeader, TableRow, TableSearchFilter, Tabs, TabsContent, TabsList, TabsTrigger, TargetRows, TeamSwitcher, Textarea, Toggle, ToggleGroup, ToggleGroupItem, ToneProgress, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, Treemap, TreemapLegend, WarningAlert, WeekdayHeatmap, WeekdayHeatmapBlock, WeekdayHeatmapBody, WeekdayHeatmapFooter, WeekdayHeatmapLegend, WeekdayHeatmapStat, badgeVariants, buttonVariants, count, defaultLocale, defaultSidebarOpen, flashCellKey, money, moneyCompact, pct, resolveGroupedRowsSlot, resolveRowContextMenuRenderer, tabsListVariants, time, toggleVariants, useColumnHeaderContext, useColumnResizeInfo, useDataTable, useDataTableActiveCell, useDataTableActiveCellSetter, useDataTableGroupRow, useDataTableRow, useFormat, useLocale, useResolvedRowContextMenuRenderer, useSidebar, useSurface, useTableFacetedFilter };
101
+ export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertAction, AlertDescription, AlertTitle, AppSidebar, AreaChartCard, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage, Badge, BarChartCard, BarList, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button, Calendar, CalendarDayButton, CalendarHeatmap, CalendarHeatmapBlock, CalendarHeatmapBody, CalendarHeatmapFooter, CalendarHeatmapLegend, CalendarHeatmapStat, Callout, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, ChangeBar, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, CodeBlock, CodeBlockActions, CodeBlockContent, CodeBlockCopyButton, CodeBlockFooter, CodeBlockHeader, CodeBlockLine, CodeBlockTitle, Collapsible, CollapsibleContent, CollapsibleTrigger, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, CopyButton, DataBar, DataList, DataListItem, DataTable, DataTableActions, DataTableBody, DataTableColumnActions, DataTableColumnFilter, DataTableColumnHeader, DataTableColumnHeaderRoot, DataTableColumnSortMenu, DataTableColumnSortOptions, DataTableColumnTitle, DataTableCompactColumnsToggle, DataTableContext, DataTableEmptyActions, DataTableEmptyBody, DataTableEmptyDescription, DataTableEmptyFilteredMessage, DataTableEmptyIcon, DataTableEmptyMessage, DataTableEmptyState, DataTableEmptyTitle, DataTableErrorBoundary, DataTableFacetedFilter, DataTableFacetedFilterContent, DataTableFootnote, DataTableGroupRowProvider, DataTableGroupedRowCells, DataTableGroupedRows, DataTableHeader, DataTableLoading, DataTableLoadingMore, DataTableProvider, DataTableRoot, DataTableRowContextMenu, DataTableRowContextMenuSlot, DataTableRowCount, DataTableRowMenuScope, DataTableSearchFilter, DataTableSkeleton, DataTableSortHeader, DataTableToolbarSection, Delta, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DistributionBar, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, GroupedBodyRow, InlineCode, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, LineChartCard, LocalTime, MetricStrip, NavMain, NavProjects, NavUser, PageHero, PageSection, PageSubheading, PageToc, PanelGrid, Popover, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, PriceChart, Progress, ProgressIndicator, ProgressLabel, ProgressTrack, ProgressValue, Quote, RangePosition, RowMenuGroup, RowMenuItem, RowMenuLabel, RowMenuSeparator, RowMenuSub, RowMenuSubContent, RowMenuSubTrigger, ScrollArea, ScrollBar, SectionCards, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, SiyahiProvider, Skeleton, Slider, Sparkline, StatusAlert, StatusBadge, StatusHeatmap, StatusHeatmapBlock, StatusHeatmapBody, StatusHeatmapFooter, StatusHeatmapLegend, StatusHeatmapStat, Table, TableBody, TableCaption, TableCell, TableColumnActions, TableColumnSortMenu, TableColumnSortOptions, TableColumnTitle, TableFacetedFilter, TableFacetedFilterContent, TableFooter, TableHead, TableHeader, TableRow, TableSearchFilter, Tabs, TabsContent, TabsList, TabsTrigger, TargetRows, TeamSwitcher, Textarea, Toggle, ToggleGroup, ToggleGroupItem, ToneProgress, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, Treemap, TreemapLegend, WeekdayHeatmap, WeekdayHeatmapBlock, WeekdayHeatmapBody, WeekdayHeatmapFooter, WeekdayHeatmapLegend, WeekdayHeatmapStat, badgeVariants, buttonVariants, count, defaultLocale, defaultSidebarOpen, flashCellKey, money, moneyCompact, pct, resolveGroupedRowsSlot, resolveRowContextMenuRenderer, tabsListVariants, time, toggleVariants, useColumnHeaderContext, useColumnResizeInfo, useDataTable, useDataTableActiveCell, useDataTableActiveCellSetter, useDataTableGroupRow, useDataTableRow, useFormat, useLocale, useResolvedRowContextMenuRenderer, useSidebar, useSurface, useTableFacetedFilter };
@@ -82,7 +82,7 @@ function endRoom(xFormatter, xTicks) {
82
82
  * own ticks would rather drop a label than let it run into the next. With a detail, the second line comes from the
83
83
  * tick's row; under a column the lines hang below the axis, and beside a horizontal bar they straddle its middle.
84
84
  * A two-line tick is set in Geist, not Mono: a name with a figure under it reads as a label, as in BarList, and
85
- * sector names in Mono would take most of a phone's width.
85
+ * category names in Mono would take most of a phone's width.
86
86
  */
87
87
  function fittedTick(data, xKey, xFormatter, detailOf, beside, labelWidth) {
88
88
  const rows = /* @__PURE__ */ new Map();
@@ -71,7 +71,7 @@ export interface SeriesChartProps<T extends object, K extends keyof T> {
71
71
  yTicks?: readonly number[];
72
72
  /** Height of the plot and legend, in pixels. Sideways bars grow when wrapped tick details need more room. */
73
73
  height: number;
74
- /** A second line under each x tick, so a row's figure reads without a hover: "FY24" then "▲₹1.2L". */
74
+ /** A second line under each x tick, so a row's figure reads without a hover: "FY24" then "+₹1.2L". */
75
75
  xTickDetail?: (row: T) => string;
76
76
  /** A title under the x axis, such as "Hour of day (IST)". Not drawn on sideways bars. */
77
77
  xLabel?: string;
@@ -6,7 +6,7 @@ export declare function money(value: number, locale?: SiyahiLocale, fractionDigi
6
6
  * A short amount: ₹2.4L and ₹40Cr in en-IN, $2.4M in en-US. Indian readers
7
7
  * count in thousands up to a lakh, so in an Indian-region locale amounts under
8
8
  * one lakh print in full (₹99,999), never as ₹99.9K. Signed figures belong in
9
- * `Delta`, which adds the arrow.
9
+ * `Delta`, which adds the sign and a trend icon.
10
10
  *
11
11
  * Give `scale`, the largest amount on the same axis, and every tick takes that
12
12
  * amount's unit, to two decimals so close ticks stay apart: ₹1.5L, ₹0.75L,
@@ -34,7 +34,7 @@ const NUMBER = /* @__PURE__ */ new Set([
34
34
  * A short amount: ₹2.4L and ₹40Cr in en-IN, $2.4M in en-US. Indian readers
35
35
  * count in thousands up to a lakh, so in an Indian-region locale amounts under
36
36
  * one lakh print in full (₹99,999), never as ₹99.9K. Signed figures belong in
37
- * `Delta`, which adds the arrow.
37
+ * `Delta`, which adds the sign and a trend icon.
38
38
  *
39
39
  * Give `scale`, the largest amount on the same axis, and every tick takes that
40
40
  * amount's unit, to two decimals so close ticks stay apart: ₹1.5L, ₹0.75L,
@@ -0,0 +1,36 @@
1
+ //#region src/lib/tone.d.ts
2
+ /**
3
+ * The tones a box can take: a faint wash of the colour inside a full border of it, with the colour itself kept for
4
+ * an icon or a dot. Text inside stays in the text colours: small coloured text on its own wash falls under 4.5:1.
5
+ * Callout, StatusAlert and StatusBadge share these, so a warning looks the same wherever it appears.
6
+ */
7
+ export declare const TONES: {
8
+ readonly neutral: {
9
+ readonly box: "border-border bg-muted/50";
10
+ readonly ink: "text-muted-foreground!";
11
+ readonly dot: "bg-muted-foreground";
12
+ };
13
+ readonly accent: {
14
+ readonly box: "border-chart-1/35 bg-chart-1/8";
15
+ readonly ink: "text-link!";
16
+ readonly dot: "bg-link";
17
+ };
18
+ readonly warning: {
19
+ readonly box: "border-warning/45 bg-warning/10";
20
+ readonly ink: "text-warning!";
21
+ readonly dot: "bg-warning";
22
+ };
23
+ readonly positive: {
24
+ readonly box: "border-positive/40 bg-positive/8";
25
+ readonly ink: "text-positive!";
26
+ readonly dot: "bg-positive";
27
+ };
28
+ readonly negative: {
29
+ readonly box: "border-negative/40 bg-negative/8";
30
+ readonly ink: "text-negative!";
31
+ readonly dot: "bg-negative";
32
+ };
33
+ };
34
+ /** neutral for information, accent for a key point, warning for a caution, positive and negative for good and bad. */
35
+ export type Tone = keyof typeof TONES;
36
+ //#endregion
@@ -0,0 +1,35 @@
1
+ //#region src/lib/tone.ts
2
+ /**
3
+ * The tones a box can take: a faint wash of the colour inside a full border of it, with the colour itself kept for
4
+ * an icon or a dot. Text inside stays in the text colours: small coloured text on its own wash falls under 4.5:1.
5
+ * Callout, StatusAlert and StatusBadge share these, so a warning looks the same wherever it appears.
6
+ */
7
+ const TONES = {
8
+ neutral: {
9
+ box: "border-border bg-muted/50",
10
+ ink: "text-muted-foreground!",
11
+ dot: "bg-muted-foreground"
12
+ },
13
+ accent: {
14
+ box: "border-chart-1/35 bg-chart-1/8",
15
+ ink: "text-link!",
16
+ dot: "bg-link"
17
+ },
18
+ warning: {
19
+ box: "border-warning/45 bg-warning/10",
20
+ ink: "text-warning!",
21
+ dot: "bg-warning"
22
+ },
23
+ positive: {
24
+ box: "border-positive/40 bg-positive/8",
25
+ ink: "text-positive!",
26
+ dot: "bg-positive"
27
+ },
28
+ negative: {
29
+ box: "border-negative/40 bg-negative/8",
30
+ ink: "text-negative!",
31
+ dot: "bg-negative"
32
+ }
33
+ };
34
+ //#endregion
35
+ export { TONES };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@siyahi/ui",
3
- "version": "0.1.9-next.21",
3
+ "version": "0.1.9-next.23",
4
4
  "description": "Stock shadcn/ui on Base UI and Tailwind v4, a finance theme, a few compositions and formatters.",
5
5
  "keywords": [
6
6
  "base-ui",
package/report.css CHANGED
@@ -5,7 +5,7 @@
5
5
  */
6
6
  :root {
7
7
  color-scheme: light dark;
8
- --radius: 0.625rem;
8
+ --radius: 0.45rem;
9
9
  --background: oklch(0.985 0 0);
10
10
  --foreground: oklch(0.145 0 0);
11
11
  --card: oklch(1 0 0);
@@ -17,24 +17,24 @@
17
17
  --secondary: oklch(0.97 0 0);
18
18
  --secondary-foreground: oklch(0.205 0 0);
19
19
  --muted: oklch(0.97 0 0);
20
- --muted-foreground: oklch(0.556 0 0);
20
+ --muted-foreground: oklch(0.51 0 0);
21
21
  --accent: oklch(0.97 0 0);
22
22
  --accent-foreground: oklch(0.205 0 0);
23
- --destructive: oklch(0.577 0.245 27.325);
23
+ --destructive: oklch(0.49 0.19 27.325);
24
24
  --border: oklch(0.922 0 0);
25
- --input: oklch(0.922 0 0);
25
+ --input: oklch(0.64 0 0);
26
26
  --ring: oklch(0.62 0.16 275);
27
- --positive: oklch(0.527 0.154 150.069);
27
+ --positive: oklch(0.527 0.145 150.069);
28
28
  --positive-foreground: oklch(0.985 0 0);
29
- --negative: oklch(0.577 0.245 27.325);
29
+ --negative: oklch(0.577 0.235 27.325);
30
30
  --negative-foreground: oklch(0.985 0 0);
31
- --warning: oklch(0.555 0.163 48.998);
31
+ --warning: oklch(0.555 0.149 48.998);
32
32
  --warning-foreground: oklch(0.985 0 0);
33
33
  --link: oklch(0.51 0.2 275);
34
34
  --chart-1: oklch(0.4 0.17 275);
35
35
  --chart-2: oklch(0.66 0.13 70);
36
36
  --chart-3: oklch(0.38 0.13 335);
37
- --chart-4: oklch(0.66 0.11 235);
37
+ --chart-4: oklch(0.65 0.11 235);
38
38
  --chart-5: oklch(0.36 0.06 205);
39
39
  --sidebar: oklch(0.985 0 0);
40
40
  --sidebar-foreground: oklch(0.145 0 0);
@@ -62,17 +62,17 @@
62
62
  --muted-foreground: oklch(0.74 0 0);
63
63
  --accent: oklch(0.269 0 0);
64
64
  --accent-foreground: oklch(0.922 0 0);
65
- --destructive: oklch(0.704 0.191 22.216);
65
+ --destructive: oklch(0.8 0.1 22.216);
66
66
  --border: oklch(1 0 0 / 10%);
67
- --input: oklch(1 0 0 / 15%);
67
+ --input: oklch(0.62 0 0);
68
68
  --ring: oklch(0.6 0.14 275);
69
- --positive: oklch(0.74 0.16 151.711);
69
+ --positive: oklch(0.69 0.16 151.711);
70
70
  --positive-foreground: oklch(0.145 0 0);
71
- --negative: oklch(0.704 0.191 22.216);
71
+ --negative: oklch(0.704 0.187 22.216);
72
72
  --negative-foreground: oklch(0.145 0 0);
73
- --warning: oklch(0.828 0.189 84.429);
73
+ --warning: oklch(0.828 0.169 84.429);
74
74
  --warning-foreground: oklch(0.145 0 0);
75
- --link: oklch(0.75 0.13 275);
75
+ --link: oklch(0.75 0.128 275);
76
76
  --chart-1: oklch(0.58 0.2 275);
77
77
  --chart-2: oklch(0.88 0.08 75);
78
78
  --chart-3: oklch(0.58 0.16 335);
package/styles/siyahi.css CHANGED
@@ -83,7 +83,8 @@
83
83
 
84
84
  :root {
85
85
  color-scheme: light dark;
86
- --radius: 0.625rem;
86
+ /* shadcn's "small": crisper than its 0.625rem default, still not square. Cards 10px, buttons 7px. */
87
+ --radius: 0.45rem;
87
88
  --background: oklch(0.985 0 0);
88
89
  --foreground: oklch(0.145 0 0);
89
90
  --card: oklch(1 0 0);
@@ -95,24 +96,27 @@
95
96
  --secondary: oklch(0.97 0 0);
96
97
  --secondary-foreground: oklch(0.205 0 0);
97
98
  --muted: oklch(0.97 0 0);
98
- --muted-foreground: oklch(0.556 0 0);
99
+ /* Below shadcn's 0.556, so muted text keeps 4.5:1 on the muted fill and on every Callout's tint. */
100
+ --muted-foreground: oklch(0.51 0 0);
99
101
  --accent: oklch(0.97 0 0);
100
102
  --accent-foreground: oklch(0.205 0 0);
101
- --destructive: oklch(0.577 0.245 27.325);
103
+ /* Deeper than the loss red, so a destructive button's label reads on its own red tint, hovered too. */
104
+ --destructive: oklch(0.49 0.19 27.325);
102
105
  --border: oklch(0.922 0 0);
103
- --input: oklch(0.922 0 0);
106
+ /* The edge of a field (input, textarea, select, input group) at 3:1: --border stays faint for dividers. */
107
+ --input: oklch(0.64 0 0);
104
108
  --ring: oklch(0.62 0.16 275);
105
- /* Tailwind green-700, red-600, amber-700, blue-600. */
106
- --positive: oklch(0.527 0.154 150.069);
109
+ /* Tailwind green-700, red-600, amber-700, with their chroma lowered to the sRGB edge. */
110
+ --positive: oklch(0.527 0.145 150.069);
107
111
  --positive-foreground: oklch(0.985 0 0);
108
- --negative: oklch(0.577 0.245 27.325);
112
+ --negative: oklch(0.577 0.235 27.325);
109
113
  --negative-foreground: oklch(0.985 0 0);
110
- --warning: oklch(0.555 0.163 48.998);
114
+ --warning: oklch(0.555 0.149 48.998);
111
115
  --warning-foreground: oklch(0.985 0 0);
112
116
  --link: oklch(0.51 0.2 275);
113
117
  /*
114
118
  * Indigo, amber, plum, sky, teal: no green or red, so no series reads as a
115
- * gain or a loss. Each slot reaches 3:1 against the card and against the
119
+ * gain or a loss. Each slot reaches 3:1 against the canvas, the card and the
116
120
  * slots next to it, which only lightness can give, so indigo, plum and teal
117
121
  * are the deep members and amber and sky the pale ones, in both schemes: a
118
122
  * pale indigo in dark read as lavender and lost the accent. Slots two apart
@@ -123,7 +127,7 @@
123
127
  --chart-1: oklch(0.4 0.17 275);
124
128
  --chart-2: oklch(0.66 0.13 70);
125
129
  --chart-3: oklch(0.38 0.13 335);
126
- --chart-4: oklch(0.66 0.11 235);
130
+ --chart-4: oklch(0.65 0.11 235);
127
131
  --chart-5: oklch(0.36 0.06 205);
128
132
  --sidebar: oklch(0.985 0 0);
129
133
  --sidebar-foreground: oklch(0.145 0 0);
@@ -159,18 +163,23 @@
159
163
  --muted-foreground: oklch(0.74 0 0);
160
164
  --accent: oklch(0.269 0 0);
161
165
  --accent-foreground: oklch(0.922 0 0);
162
- --destructive: oklch(0.704 0.191 22.216);
166
+ /* Paler and calmer than the loss red, so a destructive label reads on its red tint over the card, hovered too. */
167
+ --destructive: oklch(0.8 0.1 22.216);
163
168
  --border: oklch(1 0 0 / 10%);
164
- --input: oklch(1 0 0 / 15%);
169
+ --input: oklch(0.62 0 0);
165
170
  --ring: oklch(0.6 0.14 275);
166
- /* Green toned down from Tailwind green-400 to the lightness and calm of red-400 beside it, so gains do not shout; amber-400. */
167
- --positive: oklch(0.74 0.16 151.711);
171
+ /*
172
+ * Green toned down from Tailwind green-400, below red-400's lightness so a
173
+ * treemap's deepest green tile keeps its light label at 4.5:1; amber-400.
174
+ * Red, amber and the link sit at the sRGB edge.
175
+ */
176
+ --positive: oklch(0.69 0.16 151.711);
168
177
  --positive-foreground: oklch(0.145 0 0);
169
- --negative: oklch(0.704 0.191 22.216);
178
+ --negative: oklch(0.704 0.187 22.216);
170
179
  --negative-foreground: oklch(0.145 0 0);
171
- --warning: oklch(0.828 0.189 84.429);
180
+ --warning: oklch(0.828 0.169 84.429);
172
181
  --warning-foreground: oklch(0.145 0 0);
173
- --link: oklch(0.75 0.13 275);
182
+ --link: oklch(0.75 0.128 275);
174
183
  --chart-1: oklch(0.58 0.2 275);
175
184
  --chart-2: oklch(0.88 0.08 75);
176
185
  --chart-3: oklch(0.58 0.16 335);
@@ -213,15 +222,78 @@
213
222
  /*
214
223
  * Every selected toggle, a view switch or a filter chip alike, fills with the
215
224
  * foreground, black on white and white on black, so the reader sees at once
216
- * what is on; stock shadcn marks it with a faint grey. Unlayered, to outrank
217
- * the stock aria-pressed:bg-muted.
225
+ * what is on; stock shadcn marks it with a faint grey. A default (pill) tab
226
+ * selects the same way: stock fills it with the canvas colour, 1.05:1 against
227
+ * its grey list. Unlayered, to outrank the stock aria-pressed:bg-muted.
218
228
  */
219
- :is([data-slot="toggle"], [data-slot="toggle-group-item"]):is([aria-pressed="true"], [data-pressed]) {
229
+ :is([data-slot="toggle"], [data-slot="toggle-group-item"]):is([aria-pressed="true"], [data-pressed]),
230
+ [data-slot="tabs-list"][data-variant="default"] [data-slot="tabs-trigger"][data-active] {
220
231
  background-color: var(--foreground);
221
232
  color: var(--background);
222
233
  border-color: var(--foreground);
223
234
  }
224
235
 
236
+ /*
237
+ * --input is the edge of a field, where the reader types or picks. A button,
238
+ * a toggle and a code block are framed by their label or their content, so
239
+ * their outline stays the faint divider colour; scoping the variable keeps
240
+ * the fill each derives from it faint too.
241
+ */
242
+ :is([data-slot="button"], [data-slot="toggle"], [data-slot="toggle-group-item"], [data-slot="code-block"]) {
243
+ --input: var(--border);
244
+ }
245
+
246
+ /*
247
+ * The command palette's search field is a field: the --input edge on a muted
248
+ * fill, and the muted placeholder every other field uses (stock leaves it at
249
+ * Tailwind's half-strength text, 3.7:1).
250
+ */
251
+ [data-slot="command-input-wrapper"] > [data-slot="input-group"] {
252
+ border-color: var(--input);
253
+ background-color: color-mix(in oklab, var(--muted) 50%, transparent);
254
+ }
255
+ [data-slot="command-input"]::placeholder {
256
+ color: var(--muted-foreground);
257
+ }
258
+
259
+ /*
260
+ * Focus is opaque wherever the ring is the only sign of it: stock draws the
261
+ * ring at half strength (under 2:1 on the canvas) and relies on an opaque
262
+ * border these controls do not have. The slider's thumb is a div around a
263
+ * hidden range input, so it shows the input's focus.
264
+ */
265
+ :is([data-slot="toggle"], [data-slot="toggle-group-item"], [data-slot="scroll-area-viewport"]):focus-visible,
266
+ [data-slot="button"][data-day]:focus-visible {
267
+ --tw-ring-color: var(--ring);
268
+ }
269
+ [data-slot="slider-thumb"]:has(input:focus-visible) {
270
+ box-shadow: 0 0 0 3px var(--ring);
271
+ }
272
+
273
+ /*
274
+ * A destructive control focuses, and an invalid field is edged, in the full
275
+ * destructive colour; stock fades both to 40-50%, under 3:1.
276
+ */
277
+ [data-slot="button"][class~="text-destructive"]:focus-visible,
278
+ [data-slot="code-block"][data-variant="destructive"]:has(> [data-slot="code-block-content"]:focus-visible),
279
+ :is(
280
+ [data-slot="input"],
281
+ [data-slot="textarea"],
282
+ [data-slot="select-trigger"],
283
+ [data-slot="button"]
284
+ )[aria-invalid="true"],
285
+ [data-slot="input-group"]:has([data-slot][aria-invalid="true"]) {
286
+ border-color: var(--destructive);
287
+ }
288
+
289
+ /*
290
+ * A slider's unfilled track is outlined in the field edge, so its extent reads
291
+ * at 3:1; the muted track alone is 1.05:1 on the canvas.
292
+ */
293
+ [data-slot="slider-track"] {
294
+ box-shadow: inset 0 0 0 1px var(--input);
295
+ }
296
+
225
297
  /*
226
298
  * A number column (meta.variant "number") right-aligns its head and cells, so
227
299
  * figures line up by their units down the column, as a ledger reads.
@@ -1,72 +0,0 @@
1
- import { useState } from "react";
2
- import { BarChartCard, ToggleGroup, ToggleGroupItem, useFormat, type ChartSeries } from "@siyahi/ui";
3
-
4
- // Share of equity by sector against an index's weights; made-up figures.
5
- const WEIGHTS = {
6
- "Nifty 50": [
7
- { sector: "Financial Services", you: 0.34, index: 0.37 },
8
- { sector: "Information Technology", you: 0.21, index: 0.13 },
9
- { sector: "Oil, Gas & Consumable Fuels", you: 0.06, index: 0.1 },
10
- { sector: "Fast Moving Consumer Goods", you: 0.12, index: 0.08 },
11
- { sector: "Automobile and Auto Components", you: 0.09, index: 0.07 },
12
- { sector: "Healthcare", you: 0.08, index: 0.04 },
13
- ],
14
- "Nifty 500": [
15
- { sector: "Financial Services", you: 0.34, index: 0.31 },
16
- { sector: "Information Technology", you: 0.21, index: 0.1 },
17
- { sector: "Oil, Gas & Consumable Fuels", you: 0.06, index: 0.08 },
18
- { sector: "Fast Moving Consumer Goods", you: 0.12, index: 0.07 },
19
- { sector: "Automobile and Auto Components", you: 0.09, index: 0.07 },
20
- { sector: "Healthcare", you: 0.08, index: 0.06 },
21
- ],
22
- };
23
- type Index = keyof typeof WEIGHTS;
24
- type Row = (typeof WEIGHTS)[Index][number];
25
-
26
- export default function ChartBarSectorsExample() {
27
- const { pct } = useFormat();
28
- const [index, setIndex] = useState<Index>("Nifty 50");
29
- const rows = WEIGHTS[index];
30
- const series: ChartSeries<Row> = [
31
- { key: "you", label: "You", color: "var(--chart-1)" },
32
- { key: "index", label: index, color: "var(--chart-2)" },
33
- ];
34
- const gap = (row: Row) => {
35
- const points = Math.abs(row.you - row.index) * 100;
36
- return row.you >= row.index ? `▲${points.toFixed(1)} pts over` : `▼${points.toFixed(1)} pts under`;
37
- };
38
- return (
39
- <BarChartCard
40
- title="Sectors against the index"
41
- description="Share of your equity and of the index, by sector"
42
- action={
43
- <ToggleGroup
44
- value={[index]}
45
- onValueChange={([next]) => {
46
- // Pressing the selected index again would leave none selected; keep it.
47
- if (next) setIndex(next as Index);
48
- }}
49
- variant="outline"
50
- size="sm"
51
- aria-label="Index"
52
- >
53
- <ToggleGroupItem value="Nifty 50">Nifty 50</ToggleGroupItem>
54
- <ToggleGroupItem value="Nifty 500">Nifty 500</ToggleGroupItem>
55
- </ToggleGroup>
56
- }
57
- horizontal
58
- data={rows}
59
- xKey="sector"
60
- xTickDetail={(row) => `${pct(row.you)} vs ${pct(row.index)} · ${gap(row)}`}
61
- series={series}
62
- valueFormatter={(v) => pct(v)}
63
- // A tick format puts the value axis along the bottom of the sideways bars.
64
- yTickFormatter={(v) => pct(v, 0)}
65
- // Sideways, y is still the value: the axis runs 0 to 40% and the cap is a value level.
66
- yDomain={[0, 0.4]}
67
- referenceLines={[{ y: 0.3, label: "cap 30%", labelPosition: "insideBottomRight" }]}
68
- height={rows.length * 56 + 48}
69
- footer={<p className="text-muted-foreground">Company shares only; ETFs and funds are left out.</p>}
70
- />
71
- );
72
- }
@@ -1,10 +0,0 @@
1
- import { Alert } from "../ui/alert.js";
2
- import { ComponentProps } from "react";
3
- //#region src/components/siyahi/warning-alert.d.ts
4
- /**
5
- * An Alert for a caution the reader must not miss, such as withdrawn results or incomplete data: the whole card
6
- * takes a faint amber wash inside an amber border, with the warning triangle. Never mark a warning with a single
7
- * coloured edge; the tint is the card. Put an AlertTitle and an AlertDescription inside.
8
- */
9
- export declare function WarningAlert({ className, children, ...props }: ComponentProps<typeof Alert>): import("react").JSX.Element;
10
- //#endregion
@@ -1,20 +0,0 @@
1
- import { Alert } from "../ui/alert.js";
2
- import { cn } from "cn";
3
- import { TriangleAlertIcon } from "lucide-react";
4
- import { jsx, jsxs } from "react/jsx-runtime";
5
- //#region src/components/siyahi/warning-alert.tsx
6
- /**
7
- * An Alert for a caution the reader must not miss, such as withdrawn results or incomplete data: the whole card
8
- * takes a faint amber wash inside an amber border, with the warning triangle. Never mark a warning with a single
9
- * coloured edge; the tint is the card. Put an AlertTitle and an AlertDescription inside.
10
- */
11
- function WarningAlert({ className, children, ...props }) {
12
- return /* @__PURE__ */ jsxs(Alert, {
13
- "data-tone": "warning",
14
- className: cn("gap-x-3 border-warning/45 bg-warning/10 px-4 py-3 [&>svg]:text-warning!", className),
15
- ...props,
16
- children: [/* @__PURE__ */ jsx(TriangleAlertIcon, {}), children]
17
- });
18
- }
19
- //#endregion
20
- export { WarningAlert };