@handled-ai/design-system 0.4.2 → 0.5.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/dist/index.d.ts CHANGED
@@ -529,6 +529,24 @@ declare function InboxGroupHeader({ title, count }: {
529
529
  count: number;
530
530
  }): React$1.JSX.Element;
531
531
 
532
+ interface FilterDefinition {
533
+ id: string;
534
+ label: string;
535
+ options: string[];
536
+ defaultValue?: string;
537
+ icon?: "calendar" | React$1.ComponentType<{
538
+ className?: string;
539
+ }>;
540
+ }
541
+ interface InsightsFilterBarProps {
542
+ filters: FilterDefinition[];
543
+ values: Record<string, string>;
544
+ onChange: (filterId: string, value: string) => void;
545
+ onClearAll?: () => void;
546
+ className?: string;
547
+ }
548
+ declare function InsightsFilterBar({ filters, values, onChange, onClearAll, className, }: InsightsFilterBarProps): React$1.JSX.Element;
549
+
532
550
  type AssigneeFilter = "me" | "team" | "all";
533
551
  interface InboxFilterCategory {
534
552
  id: string;
@@ -722,10 +740,31 @@ interface PipelineOverviewProps {
722
740
  value: number;
723
741
  }[];
724
742
  totalReceived?: number;
743
+ /** Dollar amounts to display on terminal node labels: { "Retained": "$18.2M" } */
744
+ nodeAmounts?: Record<string, string>;
745
+ /** Unit noun for standard node/link tooltips (e.g. "signals", "accounts"). */
746
+ unitLabel?: string;
747
+ /** Unit noun for terminal/drop-off node tooltips (e.g. "opportunities"). Defaults to unitLabel. */
748
+ terminalUnitLabel?: string;
749
+ /** Node IDs that should use terminalUnitLabel. Defaults to keys of dropOffDistribution. */
750
+ terminalNodeIds?: string[];
751
+ /** Sankey chart margins, merged with defaults { top: 20, right: 120, bottom: 20, left: 140 }. */
752
+ sankeyMargin?: {
753
+ top?: number;
754
+ right?: number;
755
+ bottom?: number;
756
+ left?: number;
757
+ };
758
+ /** Gap between Sankey node bar and its outside label. */
759
+ sankeyLabelPadding?: number;
760
+ /** When true, conversion badges use `flex`; when false, `hidden xl:flex`. */
761
+ alwaysShowConversionBadges?: boolean;
762
+ /** Color for dynamically generated drop-off nodes. */
763
+ dropOffNodeColor?: string;
725
764
  onViewInWorkQueue?: (stageId: string) => void;
726
765
  className?: string;
727
766
  }
728
- declare function PipelineOverview({ title, stages, stageMetrics, stageTimings, filterOptions, filterBreakdowns, countingModes, countingModeTooltip, flowNodes, dropOffDistribution, flowLinks, totalReceived, onViewInWorkQueue, className, }: PipelineOverviewProps): React$1.JSX.Element;
767
+ declare function PipelineOverview({ title, stages, stageMetrics, stageTimings, filterOptions, filterBreakdowns, countingModes, countingModeTooltip, flowNodes, dropOffDistribution, flowLinks, totalReceived, nodeAmounts, unitLabel, terminalUnitLabel, terminalNodeIds, sankeyMargin, sankeyLabelPadding, alwaysShowConversionBadges, dropOffNodeColor, onViewInWorkQueue, className, }: PipelineOverviewProps): React$1.JSX.Element;
729
768
 
730
769
  declare function PreviewList({ children, className, ...props }: React$1.HTMLAttributes<HTMLDivElement>): React$1.JSX.Element;
731
770
  interface PreviewListItemProps extends Omit<React$1.HTMLAttributes<HTMLDivElement>, 'title'> {
@@ -1363,6 +1402,7 @@ interface InboxViewConfig {
1363
1402
  filterCategories?: InboxFilterCategory[];
1364
1403
  detailSections?: InboxDetailSections;
1365
1404
  accountContacts?: SuggestedContact[];
1405
+ buildAccountContacts?: (item: QueueItem) => SuggestedContact[];
1366
1406
  emailSignature?: string;
1367
1407
  buildSuggestedActions?: (item: QueueItem) => SuggestedAction[];
1368
1408
  buildSourceItems?: (item: QueueItem) => SourceDef[];
@@ -1452,6 +1492,25 @@ interface AccountsViewConfig {
1452
1492
  interface WorkQueueViewConfig {
1453
1493
  [key: string]: unknown;
1454
1494
  }
1495
+ interface AdminTab {
1496
+ id: string;
1497
+ label: string;
1498
+ icon?: React$1.ComponentType<{
1499
+ className?: string;
1500
+ }>;
1501
+ content: React$1.ReactNode;
1502
+ }
1503
+ interface AdminViewConfig {
1504
+ /** View title displayed in the header. Defaults to "Admin". */
1505
+ title?: string;
1506
+ /** Icon displayed next to the title. */
1507
+ icon?: React$1.ComponentType<{
1508
+ className?: string;
1509
+ }>;
1510
+ tabs: AdminTab[];
1511
+ /** Which tab is active initially. Defaults to first tab's id. */
1512
+ defaultTab?: string;
1513
+ }
1455
1514
  interface EntityPanelSection {
1456
1515
  type: "details" | "contacts" | "recentActivity" | "connectedApps" | "systemActivity";
1457
1516
  props?: Record<string, unknown>;
@@ -1468,6 +1527,7 @@ interface PrototypeConfig {
1468
1527
  insights?: InsightsViewConfig;
1469
1528
  accounts?: AccountsViewConfig;
1470
1529
  workQueue?: WorkQueueViewConfig;
1530
+ admin?: AdminViewConfig;
1471
1531
  };
1472
1532
  defaultView: string;
1473
1533
  entityPanel?: EntityPanelConfig;
@@ -1506,7 +1566,7 @@ interface PrototypeInboxViewProps extends InboxViewConfig {
1506
1566
  onOpenRecentActivity?: () => void;
1507
1567
  onNavigateToInbox?: () => void;
1508
1568
  }
1509
- declare function PrototypeInboxView({ items, filterCategories, detailSections, accountContacts, emailSignature, buildSuggestedActions: buildSuggestedActionsProp, buildSourceItems: buildSourceItemsProp, getSignalScore: getSignalScoreProp, getTimelineEvents, iconMap, headerActions, onOpenEntityPanel, onOpenRecentActivity, }: PrototypeInboxViewProps): React$1.JSX.Element;
1569
+ declare function PrototypeInboxView({ items, filterCategories, detailSections, accountContacts, buildAccountContacts, emailSignature, buildSuggestedActions: buildSuggestedActionsProp, buildSourceItems: buildSourceItemsProp, getSignalScore: getSignalScoreProp, getTimelineEvents, iconMap, headerActions, onOpenEntityPanel, onOpenRecentActivity, }: PrototypeInboxViewProps): React$1.JSX.Element;
1510
1570
 
1511
1571
  interface PrototypeInsightsViewProps extends InsightsViewConfig {
1512
1572
  assistantName?: string;
@@ -1521,6 +1581,11 @@ interface PrototypeAccountsViewProps extends AccountsViewConfig {
1521
1581
  }
1522
1582
  declare function PrototypeAccountsView({ filterTabs, headerActions, onRowClick, }: PrototypeAccountsViewProps): React$1.JSX.Element;
1523
1583
 
1584
+ interface PrototypeAdminViewProps extends AdminViewConfig {
1585
+ headerActions?: React$1.ReactNode;
1586
+ }
1587
+ declare function PrototypeAdminView({ title, icon: Icon, tabs, defaultTab, headerActions, }: PrototypeAdminViewProps): React$1.JSX.Element | null;
1588
+
1524
1589
  interface PrototypeWorkQueueViewProps {
1525
1590
  headerActions?: React$1.ReactNode;
1526
1591
  }
@@ -1683,4 +1748,4 @@ interface AgentPopoverChatProps {
1683
1748
  }
1684
1749
  declare function AgentPopoverChat({ messages, onSendMessage, onEndSession, inputMode, visualSlot, assistantAvatarSlot, status, mode, className, }: AgentPopoverChatProps): React$1.JSX.Element;
1685
1750
 
1686
- export { type AccountFilterTab, type AccountsViewConfig, type ActiveVariant, ActivityDetail, type ActivityDetailData, type ActivityDetailProps, type ActivityItem, ActivityLog, type ActivityLogItem, type ActivityLogProps, type ActivityParticipant, ActivityRow, type ActivityThreadMessage, AgentOrb, AgentOrbCanvas, type AgentOrbProps, type AgentOrbState, AgentPopover, AgentPopoverBranding, type AgentPopoverBrandingProps, AgentPopoverChat, type AgentPopoverChatProps, type AgentPopoverContextValue, AgentPopoverForm, type AgentPopoverFormField, type AgentPopoverFormProps, AgentPopoverOverview, type AgentPopoverOverviewProps, type AgentPopoverProps, type AgentPopoverStep, AgentPopoverStepContent, type AgentPopoverStepContentProps, AgentWidget, type AgentWidgetMessage, type AgentWidgetMode, type AgentWidgetProps, type AgentWidgetStatus, type AssigneeFilter, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage, Badge, BarChartComponent, type BarChartComponentProps, type BarSeries, Button, CHART_CURSOR_STYLE, CHART_TOOLTIP_STYLE, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, type ChartConfig, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, type ChartTooltipEntry, CheckInsCard, Citation, ConnectedApps, type ConnectionStatus, type ContactChannel, type ContactItem, ContactList, type ContactListProps, DataTable, DataTableDisplay, type DataTableDisplayColumn, DataTableFilter, type DataTableFilterCategory, type DataTableQuickViewValue, DataTableQuickViews, DataTableToolbar, DetailViewHeader, DetailViewSummary, DetailViewThread, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DonutChart, type DonutChartProps, type DonutSegment, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, EntityActivityItem, EntityDetails, type EntityMetadataField, EntityMetadataGrid, EntityPanel, type EntityPanelBrandIcons, type EntityPanelConfig, EntityPanelHeader, type EntityPanelSection, EntityPanelTabs, EntitySection, type GroupedListGroup, GroupedListView, type GroupedListViewProps, type InboxDetailSections, type InboxFilterCategory, InboxGroupHeader, InboxRow, type InboxRowProps, InboxToolbar, type InboxToolbarProps, type InboxViewConfig, Input, type InsightsViewConfig, ItemList, ItemListDisplay, type ItemListDisplayState, ItemListFilter, type ItemListFilterCategory, type ItemListGrouping, type ItemListQuickView, ItemListToolbar, type ItemListViewMode, Label, Message, MessageAvatar, type MessageAvatarProps, MessageContent, type MessageContentProps, type MessageProps, MetricCard, type MetricCardData, type MetricCardProps, type MetricDataPoint, PerformanceMetricsTable, type PerformanceMetricsTableRow, type PerformanceMetricsTableSortOption, type PipelineFilterBreakdown, PipelineOverview, type PipelineOverviewProps, type PipelineStage, type PipelineStageMetrics, type PipelineStageTiming, PotentialContacts, PreviewList, PreviewListItem, type PreviewListItemProps, Progress, PrototypeAccountsView, type PrototypeAccountsViewProps, type PrototypeBrandConfig, type PrototypeConfig, PrototypeInboxView, type PrototypeInboxViewProps, PrototypeInsightsView, type PrototypeInsightsViewProps, PrototypeShell, type PrototypeShellProps, PrototypeWorkQueueView, type PrototypeWorkQueueViewProps, type QueueItem, QuickActionChatArea, QuickActionModal, type QuickActionPriority$1 as QuickActionPriority, QuickActionSidebarNav, type QuickActionSubmitPayload, type QuickActionTaskDraft, type QuickActionTemplate, RecentActivity, RecentlyCompletedCard, type RecommendedAction, RecommendedActionsSection, ReportCard, type ReportCardProps, SankeyChart, type SankeyData, type SankeyDropOff, type SankeyHoverCardData, type SankeyLink, type SankeyNode, type SankeyStageMetrics, ScoreAnalysisModal, type ScoreAnalysisModalProps, ScoreAnalysisPanel, ScoreBreakdown, type ScoreBreakdownProps, type ScoreFactor, ScoreFeedback, ScoreRing, type ScoreRingProps, ScrollArea, ScrollBar, 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, type SidebarNavItem, type SidebarNavSection, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, type SidebarUserProfile, SignalApproval, Actions as SignalApprovalActions, Gate as SignalApprovalGate, Root as SignalApprovalRoot, type SignalScoreData, SimpleChartTooltip, type SimpleChartTooltipProps, SimpleDataTable, type SimpleDataTableProps, Skeleton, type SourceDef, SourceList, StatusBadge, type StatusBadgeProps, type StatusType, type StyledBarItem, StyledBarList, type StyledBarListProps, type SuggestedAction, type SuggestedActionCallMeta, type SuggestedActionEmailMeta, type SuggestedActionFollowUp, type SuggestedActionReplyTo, type SuggestedActionThreadMessage, type SuggestedActionTicket, SuggestedActions, type SuggestedActionsIconMap, type SuggestedActionsProps, type SuggestedContact, SystemActivity, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, ThreadMessage, TimelineActivity, type TimelineActivityProps, type TimelineEvent, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, TopLineMetrics, type TopLineMetricsProps, TopTasksCard, TrendAreaChart, type TrendAreaChartProps, type TrendSeries, UpcomingMeetingsCard, type UserMenuItem, type ViewMode, ViewModeToggle, type ViewModeToggleProps, VolumeAnalysisChart, type VolumeAnalysisChartProps, type VolumeDataKey, type WorkQueueViewConfig, badgeVariants, buttonVariants, cn, getScoreColor, tabsListVariants, useAgentPopover, useIsMobile, useScoreFeedback, useSidebar, useSignalApproval };
1751
+ export { type AccountFilterTab, type AccountsViewConfig, type ActiveVariant, ActivityDetail, type ActivityDetailData, type ActivityDetailProps, type ActivityItem, ActivityLog, type ActivityLogItem, type ActivityLogProps, type ActivityParticipant, ActivityRow, type ActivityThreadMessage, type AdminTab, type AdminViewConfig, AgentOrb, AgentOrbCanvas, type AgentOrbProps, type AgentOrbState, AgentPopover, AgentPopoverBranding, type AgentPopoverBrandingProps, AgentPopoverChat, type AgentPopoverChatProps, type AgentPopoverContextValue, AgentPopoverForm, type AgentPopoverFormField, type AgentPopoverFormProps, AgentPopoverOverview, type AgentPopoverOverviewProps, type AgentPopoverProps, type AgentPopoverStep, AgentPopoverStepContent, type AgentPopoverStepContentProps, AgentWidget, type AgentWidgetMessage, type AgentWidgetMode, type AgentWidgetProps, type AgentWidgetStatus, type AssigneeFilter, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage, Badge, BarChartComponent, type BarChartComponentProps, type BarSeries, Button, CHART_CURSOR_STYLE, CHART_TOOLTIP_STYLE, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, type ChartConfig, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, type ChartTooltipEntry, CheckInsCard, Citation, ConnectedApps, type ConnectionStatus, type ContactChannel, type ContactItem, ContactList, type ContactListProps, DataTable, DataTableDisplay, type DataTableDisplayColumn, DataTableFilter, type DataTableFilterCategory, type DataTableQuickViewValue, DataTableQuickViews, DataTableToolbar, DetailViewHeader, DetailViewSummary, DetailViewThread, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DonutChart, type DonutChartProps, type DonutSegment, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, EntityActivityItem, EntityDetails, type EntityMetadataField, EntityMetadataGrid, EntityPanel, type EntityPanelBrandIcons, type EntityPanelConfig, EntityPanelHeader, type EntityPanelSection, EntityPanelTabs, EntitySection, type FilterDefinition, type GroupedListGroup, GroupedListView, type GroupedListViewProps, type InboxDetailSections, type InboxFilterCategory, InboxGroupHeader, InboxRow, type InboxRowProps, InboxToolbar, type InboxToolbarProps, type InboxViewConfig, Input, InsightsFilterBar, type InsightsFilterBarProps, type InsightsViewConfig, ItemList, ItemListDisplay, type ItemListDisplayState, ItemListFilter, type ItemListFilterCategory, type ItemListGrouping, type ItemListQuickView, ItemListToolbar, type ItemListViewMode, Label, Message, MessageAvatar, type MessageAvatarProps, MessageContent, type MessageContentProps, type MessageProps, MetricCard, type MetricCardData, type MetricCardProps, type MetricDataPoint, PerformanceMetricsTable, type PerformanceMetricsTableRow, type PerformanceMetricsTableSortOption, type PipelineFilterBreakdown, PipelineOverview, type PipelineOverviewProps, type PipelineStage, type PipelineStageMetrics, type PipelineStageTiming, PotentialContacts, PreviewList, PreviewListItem, type PreviewListItemProps, Progress, PrototypeAccountsView, type PrototypeAccountsViewProps, PrototypeAdminView, type PrototypeAdminViewProps, type PrototypeBrandConfig, type PrototypeConfig, PrototypeInboxView, type PrototypeInboxViewProps, PrototypeInsightsView, type PrototypeInsightsViewProps, PrototypeShell, type PrototypeShellProps, PrototypeWorkQueueView, type PrototypeWorkQueueViewProps, type QueueItem, QuickActionChatArea, QuickActionModal, type QuickActionPriority$1 as QuickActionPriority, QuickActionSidebarNav, type QuickActionSubmitPayload, type QuickActionTaskDraft, type QuickActionTemplate, RecentActivity, RecentlyCompletedCard, type RecommendedAction, RecommendedActionsSection, ReportCard, type ReportCardProps, SankeyChart, type SankeyData, type SankeyDropOff, type SankeyHoverCardData, type SankeyLink, type SankeyNode, type SankeyStageMetrics, ScoreAnalysisModal, type ScoreAnalysisModalProps, ScoreAnalysisPanel, ScoreBreakdown, type ScoreBreakdownProps, type ScoreFactor, ScoreFeedback, ScoreRing, type ScoreRingProps, ScrollArea, ScrollBar, 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, type SidebarNavItem, type SidebarNavSection, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, type SidebarUserProfile, SignalApproval, Actions as SignalApprovalActions, Gate as SignalApprovalGate, Root as SignalApprovalRoot, type SignalScoreData, SimpleChartTooltip, type SimpleChartTooltipProps, SimpleDataTable, type SimpleDataTableProps, Skeleton, type SourceDef, SourceList, StatusBadge, type StatusBadgeProps, type StatusType, type StyledBarItem, StyledBarList, type StyledBarListProps, type SuggestedAction, type SuggestedActionCallMeta, type SuggestedActionEmailMeta, type SuggestedActionFollowUp, type SuggestedActionReplyTo, type SuggestedActionThreadMessage, type SuggestedActionTicket, SuggestedActions, type SuggestedActionsIconMap, type SuggestedActionsProps, type SuggestedContact, SystemActivity, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, ThreadMessage, TimelineActivity, type TimelineActivityProps, type TimelineEvent, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, TopLineMetrics, type TopLineMetricsProps, TopTasksCard, TrendAreaChart, type TrendAreaChartProps, type TrendSeries, UpcomingMeetingsCard, type UserMenuItem, type ViewMode, ViewModeToggle, type ViewModeToggleProps, VolumeAnalysisChart, type VolumeAnalysisChartProps, type VolumeDataKey, type WorkQueueViewConfig, badgeVariants, buttonVariants, cn, getScoreColor, tabsListVariants, useAgentPopover, useIsMobile, useScoreFeedback, useSidebar, useSignalApproval };