@handled-ai/design-system 0.18.5 → 0.18.7

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 (41) hide show
  1. package/dist/components/badge.d.ts +1 -1
  2. package/dist/components/button.d.ts +1 -1
  3. package/dist/components/feedback-primitives.d.ts +41 -2
  4. package/dist/components/feedback-primitives.js +241 -6
  5. package/dist/components/feedback-primitives.js.map +1 -1
  6. package/dist/components/pill.d.ts +1 -1
  7. package/dist/components/score-why-chips.d.ts +1 -1
  8. package/dist/components/score-why-chips.js +26 -5
  9. package/dist/components/score-why-chips.js.map +1 -1
  10. package/dist/components/signal-priority-popover.d.ts +1 -1
  11. package/dist/components/signal-priority-popover.js +32 -6
  12. package/dist/components/signal-priority-popover.js.map +1 -1
  13. package/dist/components/tabs.d.ts +1 -1
  14. package/dist/components/timeline-activity.d.ts +16 -1
  15. package/dist/components/timeline-activity.js +69 -1
  16. package/dist/components/timeline-activity.js.map +1 -1
  17. package/dist/index.d.ts +3 -3
  18. package/dist/index.js +2 -1
  19. package/dist/index.js.map +1 -1
  20. package/dist/prototype/index.d.ts +1 -1
  21. package/dist/prototype/prototype-accounts-view.d.ts +1 -1
  22. package/dist/prototype/prototype-admin-view.d.ts +1 -1
  23. package/dist/prototype/prototype-config.d.ts +1 -1
  24. package/dist/prototype/prototype-inbox-view.d.ts +15 -3
  25. package/dist/prototype/prototype-inbox-view.js +160 -37
  26. package/dist/prototype/prototype-inbox-view.js.map +1 -1
  27. package/dist/prototype/prototype-insights-view.d.ts +1 -1
  28. package/dist/prototype/prototype-shell.d.ts +1 -1
  29. package/dist/{signal-priority-popover-DQ_VuHac.d.ts → signal-priority-popover-BT6CPYNs.d.ts} +43 -3
  30. package/package.json +2 -1
  31. package/src/components/__tests__/timeline-activity.test.tsx +152 -0
  32. package/src/components/__tests__/wit-636-feedback-states.test.tsx +546 -0
  33. package/src/components/feedback-primitives.tsx +333 -26
  34. package/src/components/score-why-chips.tsx +28 -2
  35. package/src/components/signal-priority-popover.tsx +44 -4
  36. package/src/components/timeline-activity.tsx +112 -1
  37. package/src/index.ts +2 -2
  38. package/src/prototype/__tests__/detail-view-attention.test.tsx +2 -2
  39. package/src/prototype/__tests__/detail-view-timeline-system-events.test.tsx +409 -0
  40. package/src/prototype/prototype-config.ts +32 -1
  41. package/src/prototype/prototype-inbox-view.tsx +230 -30
package/dist/index.js CHANGED
@@ -28,7 +28,7 @@ export * from "./components/dialog.js";
28
28
  export * from "./components/dropdown-menu.js";
29
29
  export * from "./components/empty-state.js";
30
30
  export * from "./components/entity-panel.js";
31
- import { FeedbackFooter, FeedbackChipGroup, FeedbackInput, FeedbackActions } from "./components/feedback-primitives.js";
31
+ import { FeedbackFooter, FeedbackChipGroup, FeedbackInput, FeedbackActions, InlineFeedbackControl } from "./components/feedback-primitives.js";
32
32
  import { SignalPriorityPopover } from "./components/signal-priority-popover.js";
33
33
  export * from "./components/filter-chip.js";
34
34
  export * from "./components/inbox-row.js";
@@ -108,6 +108,7 @@ export {
108
108
  FeedbackChipGroup,
109
109
  FeedbackFooter,
110
110
  FeedbackInput,
111
+ InlineFeedbackControl,
111
112
  QuickActionModal,
112
113
  SignalPriorityPopover,
113
114
  cn,
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/index.ts"],"sourcesContent":["/**\n * @handled-ai/design-system\n * UI components and utilities (shadcn-style, New York)\n */\n\n// Utilities\nexport { cn } from \"./lib/utils\"\nexport { BRAND_ICONS, BRAND_GRAPHICS } from \"./lib/icons\"\nexport { displayName, getInitials, shortName, type ProfileLike } from \"./lib/user-display\"\n\n// Hooks\nexport { useIsMobile } from \"./hooks/use-mobile\"\n\n// Components (light — no recharts/nivo/three transitive deps)\nexport * from \"./components/activity-detail\"\nexport * from \"./components/activity-log\"\nexport * from \"./components/agent-popover\"\nexport * from \"./components/agent-widget\"\nexport * from \"./components/avatar\"\nexport * from \"./components/badge\"\nexport * from \"./components/button\"\nexport * from \"./components/card\"\nexport { CollapsibleSection, type CollapsibleSectionProps } from \"./components/collapsible-section\"\nexport * from \"./components/compliance-badge\"\nexport * from \"./components/contact-chip\"\nexport * from \"./components/contact-list\"\nexport * from \"./components/contextual-quick-action-launcher\"\nexport * from \"./components/dashboard-cards\"\nexport * from \"./components/data-table\"\nexport * from \"./components/data-table-condition-filter\"\nexport * from \"./components/data-table-display\"\nexport * from \"./components/data-table-filter\"\nexport * from \"./components/data-table-quick-views\"\nexport * from \"./components/data-table-toolbar\"\nexport * from \"./components/detail-view\"\nexport * from \"./components/detail-drawer\"\nexport * from \"./components/dialog\"\nexport * from \"./components/dropdown-menu\"\nexport * from \"./components/empty-state\"\nexport * from \"./components/entity-panel\"\nexport { FeedbackFooter, FeedbackChipGroup, FeedbackInput, FeedbackActions } from \"./components/feedback-primitives\"\nexport type { FeedbackFooterProps, FeedbackChipTree, FeedbackChipGroupProps, FeedbackInputProps, FeedbackActionsProps, FeedbackSubmitData } from \"./components/feedback-primitives\"\nexport { SignalPriorityPopover } from \"./components/signal-priority-popover\"\nexport type { SignalPriorityPopoverProps, PriorityFactor } from \"./components/signal-priority-popover\"\nexport * from \"./components/filter-chip\"\nexport * from \"./components/inbox-row\"\nexport * from \"./components/inbox-toolbar\"\nexport * from \"./components/inline-banner\"\nexport * from \"./components/input\"\nexport * from \"./components/insights-filter-bar\"\nexport * from \"./components/days-open-cell\"\nexport * from \"./components/linked-entity-cell\"\nexport * from \"./components/item-list\"\nexport * from \"./components/item-list-display\"\nexport * from \"./components/item-list-filter\"\nexport * from \"./components/item-list-toolbar\"\nexport * from \"./components/kbd-hint\"\nexport * from \"./components/label\"\nexport * from \"./components/message\"\nexport * from \"./components/metric-card\"\nexport * from \"./components/performance-metrics-table\"\nexport * from \"./components/pill\"\nexport * from \"./components/preview-list\"\nexport * from \"./components/progress\"\nexport * from \"./components/quick-action-chat-area\"\nexport * from \"./components/quick-segment\"\nexport {\n QuickActionModal,\n type QuickActionPriority,\n type QuickActionTaskDraft,\n type QuickActionTemplate,\n} from \"./components/quick-action-modal\"\nexport * from \"./components/quick-action-sidebar-nav\"\nexport * from \"./components/recommended-actions-section\"\nexport * from \"./components/report-card\"\nexport * from \"./components/rich-text-toolbar\"\nexport * from \"./components/score-analysis-modal\"\nexport * from \"./components/score-breakdown\"\nexport * from \"./components/score-feedback\"\nexport * from \"./components/score-why-chips\"\nexport * from \"./components/score-ring\"\nexport * from \"./components/scroll-area\"\nexport * from \"./components/select\"\nexport * from \"./components/separator\"\nexport * from \"./components/sheet\"\nexport * from \"./components/sidebar\"\nexport * from \"./components/signal-feedback-inline\"\nexport * from \"./components/simple-data-table\"\nexport * from \"./components/skeleton\"\nexport * from \"./components/status-badge\"\nexport * from \"./components/step-timeline\"\nexport * from \"./components/sticky-action-bar\"\nexport * from \"./components/styled-bar-list\"\nexport { DraftFeedbackInline } from \"./components/draft-feedback-inline\"\nexport type { DraftFeedbackInlineProps } from \"./components/draft-feedback-inline\"\nexport { AccountContactsPopover, BrandIcon } from \"./components/account-contacts-popover\"\nexport type { AccountContactsPopoverProps } from \"./components/account-contacts-popover\"\nexport * from \"./components/suggested-actions\"\nexport * from \"./components/switch\"\nexport * from \"./components/table\"\nexport * from \"./components/tabs\"\nexport * from \"./components/textarea\"\nexport * from \"./components/timeline-activity\"\nexport * from \"./components/tooltip\"\nexport * from \"./components/user-display\"\nexport * from \"./components/variable-autocomplete\"\nexport * from \"./components/view-mode-toggle\"\nexport * from \"./components/virtualized-data-table\"\nexport type { ColumnSizingState } from \"@tanstack/react-table\"\n\n// Charts (re-exported for backward compatibility with root imports)\nexport * from \"./charts/index\"\n\n// Prototype template system (re-exported for backward compatibility)\nexport * from \"./prototype/prototype-config\"\nexport * from \"./prototype/prototype-shell\"\nexport * from \"./prototype/prototype-inbox-view\"\nexport * from \"./prototype/prototype-insights-view\"\nexport * from \"./prototype/prototype-accounts-view\"\nexport * from \"./prototype/prototype-admin-view\"\nexport * from \"./prototype/prototype-work-queue-view\"\n"],"mappings":"AAMA,SAAS,UAAU;AACnB,SAAS,aAAa,sBAAsB;AAC5C,SAAS,aAAa,aAAa,iBAAmC;AAGtE,SAAS,mBAAmB;AAG5B,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,SAAS,0BAAwD;AACjE,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,SAAS,gBAAgB,mBAAmB,eAAe,uBAAuB;AAElF,SAAS,6BAA6B;AAEtC,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd;AAAA,EACE;AAAA,OAIK;AACP,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,SAAS,2BAA2B;AAEpC,SAAS,wBAAwB,iBAAiB;AAElD,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AAId,cAAc;AAGd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;","names":[]}
1
+ {"version":3,"sources":["../src/index.ts"],"sourcesContent":["/**\n * @handled-ai/design-system\n * UI components and utilities (shadcn-style, New York)\n */\n\n// Utilities\nexport { cn } from \"./lib/utils\"\nexport { BRAND_ICONS, BRAND_GRAPHICS } from \"./lib/icons\"\nexport { displayName, getInitials, shortName, type ProfileLike } from \"./lib/user-display\"\n\n// Hooks\nexport { useIsMobile } from \"./hooks/use-mobile\"\n\n// Components (light — no recharts/nivo/three transitive deps)\nexport * from \"./components/activity-detail\"\nexport * from \"./components/activity-log\"\nexport * from \"./components/agent-popover\"\nexport * from \"./components/agent-widget\"\nexport * from \"./components/avatar\"\nexport * from \"./components/badge\"\nexport * from \"./components/button\"\nexport * from \"./components/card\"\nexport { CollapsibleSection, type CollapsibleSectionProps } from \"./components/collapsible-section\"\nexport * from \"./components/compliance-badge\"\nexport * from \"./components/contact-chip\"\nexport * from \"./components/contact-list\"\nexport * from \"./components/contextual-quick-action-launcher\"\nexport * from \"./components/dashboard-cards\"\nexport * from \"./components/data-table\"\nexport * from \"./components/data-table-condition-filter\"\nexport * from \"./components/data-table-display\"\nexport * from \"./components/data-table-filter\"\nexport * from \"./components/data-table-quick-views\"\nexport * from \"./components/data-table-toolbar\"\nexport * from \"./components/detail-view\"\nexport * from \"./components/detail-drawer\"\nexport * from \"./components/dialog\"\nexport * from \"./components/dropdown-menu\"\nexport * from \"./components/empty-state\"\nexport * from \"./components/entity-panel\"\nexport { FeedbackFooter, FeedbackChipGroup, FeedbackInput, FeedbackActions, InlineFeedbackControl } from \"./components/feedback-primitives\"\nexport type { FeedbackFooterProps, FeedbackChipTree, FeedbackChipGroupProps, FeedbackInputProps, FeedbackActionsProps, FeedbackSubmitData, PersistedFeedbackData, InlineFeedbackControlProps } from \"./components/feedback-primitives\"\nexport { SignalPriorityPopover } from \"./components/signal-priority-popover\"\nexport type { SignalPriorityPopoverProps, PriorityFactor } from \"./components/signal-priority-popover\"\nexport * from \"./components/filter-chip\"\nexport * from \"./components/inbox-row\"\nexport * from \"./components/inbox-toolbar\"\nexport * from \"./components/inline-banner\"\nexport * from \"./components/input\"\nexport * from \"./components/insights-filter-bar\"\nexport * from \"./components/days-open-cell\"\nexport * from \"./components/linked-entity-cell\"\nexport * from \"./components/item-list\"\nexport * from \"./components/item-list-display\"\nexport * from \"./components/item-list-filter\"\nexport * from \"./components/item-list-toolbar\"\nexport * from \"./components/kbd-hint\"\nexport * from \"./components/label\"\nexport * from \"./components/message\"\nexport * from \"./components/metric-card\"\nexport * from \"./components/performance-metrics-table\"\nexport * from \"./components/pill\"\nexport * from \"./components/preview-list\"\nexport * from \"./components/progress\"\nexport * from \"./components/quick-action-chat-area\"\nexport * from \"./components/quick-segment\"\nexport {\n QuickActionModal,\n type QuickActionPriority,\n type QuickActionTaskDraft,\n type QuickActionTemplate,\n} from \"./components/quick-action-modal\"\nexport * from \"./components/quick-action-sidebar-nav\"\nexport * from \"./components/recommended-actions-section\"\nexport * from \"./components/report-card\"\nexport * from \"./components/rich-text-toolbar\"\nexport * from \"./components/score-analysis-modal\"\nexport * from \"./components/score-breakdown\"\nexport * from \"./components/score-feedback\"\nexport * from \"./components/score-why-chips\"\nexport * from \"./components/score-ring\"\nexport * from \"./components/scroll-area\"\nexport * from \"./components/select\"\nexport * from \"./components/separator\"\nexport * from \"./components/sheet\"\nexport * from \"./components/sidebar\"\nexport * from \"./components/signal-feedback-inline\"\nexport * from \"./components/simple-data-table\"\nexport * from \"./components/skeleton\"\nexport * from \"./components/status-badge\"\nexport * from \"./components/step-timeline\"\nexport * from \"./components/sticky-action-bar\"\nexport * from \"./components/styled-bar-list\"\nexport { DraftFeedbackInline } from \"./components/draft-feedback-inline\"\nexport type { DraftFeedbackInlineProps } from \"./components/draft-feedback-inline\"\nexport { AccountContactsPopover, BrandIcon } from \"./components/account-contacts-popover\"\nexport type { AccountContactsPopoverProps } from \"./components/account-contacts-popover\"\nexport * from \"./components/suggested-actions\"\nexport * from \"./components/switch\"\nexport * from \"./components/table\"\nexport * from \"./components/tabs\"\nexport * from \"./components/textarea\"\nexport * from \"./components/timeline-activity\"\nexport * from \"./components/tooltip\"\nexport * from \"./components/user-display\"\nexport * from \"./components/variable-autocomplete\"\nexport * from \"./components/view-mode-toggle\"\nexport * from \"./components/virtualized-data-table\"\nexport type { ColumnSizingState } from \"@tanstack/react-table\"\n\n// Charts (re-exported for backward compatibility with root imports)\nexport * from \"./charts/index\"\n\n// Prototype template system (re-exported for backward compatibility)\nexport * from \"./prototype/prototype-config\"\nexport * from \"./prototype/prototype-shell\"\nexport * from \"./prototype/prototype-inbox-view\"\nexport * from \"./prototype/prototype-insights-view\"\nexport * from \"./prototype/prototype-accounts-view\"\nexport * from \"./prototype/prototype-admin-view\"\nexport * from \"./prototype/prototype-work-queue-view\"\n"],"mappings":"AAMA,SAAS,UAAU;AACnB,SAAS,aAAa,sBAAsB;AAC5C,SAAS,aAAa,aAAa,iBAAmC;AAGtE,SAAS,mBAAmB;AAG5B,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,SAAS,0BAAwD;AACjE,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,SAAS,gBAAgB,mBAAmB,eAAe,iBAAiB,6BAA6B;AAEzG,SAAS,6BAA6B;AAEtC,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd;AAAA,EACE;AAAA,OAIK;AACP,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,SAAS,2BAA2B;AAEpC,SAAS,wBAAwB,iBAAiB;AAElD,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AAId,cAAc;AAGd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;","names":[]}
@@ -1,4 +1,4 @@
1
- export { A as AccountFilterTab, a as AccountsViewConfig, b as AdminTab, c as AdminViewConfig, B as BriefStyleVariant, E as EntityPanelConfig, d as EntityPanelSection, I as InboxDetailSections, e as InboxSortOption, f as InboxViewConfig, g as InsightsCustomTab, h as InsightsViewConfig, i as PrototypeBrandConfig, j as PrototypeConfig, Q as QueueItem, l as SignalScoreData, m as SignalScoreExplanationBucket, n as SignalScoreExplanationSignal, o as SignalScoreUrgencyLabel, W as WorkQueueViewConfig } from '../signal-priority-popover-DQ_VuHac.js';
1
+ export { A as AccountFilterTab, a as AccountsViewConfig, b as AdminTab, c as AdminViewConfig, B as BriefStyleVariant, E as EntityPanelConfig, d as EntityPanelSection, I as InboxDetailSections, e as InboxSortOption, f as InboxViewConfig, g as InsightsCustomTab, h as InsightsViewConfig, i as PrototypeBrandConfig, j as PrototypeConfig, Q as QueueItem, l as SignalScoreData, m as SignalScoreExplanationBucket, n as SignalScoreExplanationSignal, o as SignalScoreUrgencyLabel, T as TimelineSystemEventsConfig, W as WorkQueueViewConfig } from '../signal-priority-popover-BT6CPYNs.js';
2
2
  export { PrototypeShell, PrototypeShellProps } from './prototype-shell.js';
3
3
  export { DetailView, DetailViewProps, PrototypeInboxView, PrototypeInboxViewProps } from './prototype-inbox-view.js';
4
4
  export { PrototypeInsightsView, PrototypeInsightsViewProps } from './prototype-insights-view.js';
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import { a as AccountsViewConfig } from '../signal-priority-popover-DQ_VuHac.js';
2
+ import { a as AccountsViewConfig } from '../signal-priority-popover-BT6CPYNs.js';
3
3
  import { DataRow } from '../components/data-table.js';
4
4
  import '../components/feedback-primitives.js';
5
5
  import '../components/quick-action-sidebar-nav.js';
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import { c as AdminViewConfig } from '../signal-priority-popover-DQ_VuHac.js';
2
+ import { c as AdminViewConfig } from '../signal-priority-popover-BT6CPYNs.js';
3
3
  import '../components/feedback-primitives.js';
4
4
  import '../components/quick-action-sidebar-nav.js';
5
5
  import '../components/quick-action-modal.js';
@@ -11,7 +11,7 @@ import '../charts/pipeline-overview.js';
11
11
  import '../components/timeline-activity.js';
12
12
  import '../components/signal-feedback-inline.js';
13
13
  import 'lucide-react';
14
- export { A as AccountFilterTab, a as AccountsViewConfig, b as AdminTab, c as AdminViewConfig, B as BriefStyleVariant, E as EntityPanelConfig, d as EntityPanelSection, I as InboxDetailSections, e as InboxSortOption, f as InboxViewConfig, g as InsightsCustomTab, h as InsightsViewConfig, i as PrototypeBrandConfig, j as PrototypeConfig, Q as QueueItem, l as SignalScoreData, m as SignalScoreExplanationBucket, n as SignalScoreExplanationSignal, o as SignalScoreUrgencyLabel, W as WorkQueueViewConfig } from '../signal-priority-popover-DQ_VuHac.js';
14
+ export { A as AccountFilterTab, a as AccountsViewConfig, b as AdminTab, c as AdminViewConfig, B as BriefStyleVariant, E as EntityPanelConfig, d as EntityPanelSection, I as InboxDetailSections, e as InboxSortOption, f as InboxViewConfig, g as InsightsCustomTab, h as InsightsViewConfig, i as PrototypeBrandConfig, j as PrototypeConfig, Q as QueueItem, l as SignalScoreData, m as SignalScoreExplanationBucket, n as SignalScoreExplanationSignal, o as SignalScoreUrgencyLabel, T as TimelineSystemEventsConfig, W as WorkQueueViewConfig } from '../signal-priority-popover-BT6CPYNs.js';
15
15
  import '../components/feedback-primitives.js';
16
16
  import '../components/quick-action-modal.js';
17
17
  import '../components/data-table-condition-filter.js';
@@ -3,7 +3,7 @@ import { ApprovalState, OpportunityPreview } from '../components/signal-feedback
3
3
  import { SourceDef } from '../components/detail-view.js';
4
4
  import { SuggestedAction, SuggestedContact } from '../components/suggested-actions.js';
5
5
  import { TimelineEvent } from '../components/timeline-activity.js';
6
- import { Q as QueueItem, I as InboxDetailSections, l as SignalScoreData, f as InboxViewConfig, B as BriefStyleVariant } from '../signal-priority-popover-DQ_VuHac.js';
6
+ import { Q as QueueItem, I as InboxDetailSections, l as SignalScoreData, f as InboxViewConfig, B as BriefStyleVariant, T as TimelineSystemEventsConfig } from '../signal-priority-popover-BT6CPYNs.js';
7
7
  import '../components/feedback-primitives.js';
8
8
  import '../components/quick-action-sidebar-nav.js';
9
9
  import '../components/quick-action-modal.js';
@@ -68,8 +68,20 @@ interface DetailViewProps {
68
68
  onRequestApproval?: () => Promise<void>;
69
69
  /** Number of important/attention-worthy events to highlight on the collapsed timeline header. */
70
70
  attentionCount?: number;
71
+ /** Configuration for the system-noise events toggle (score changes, etc.). */
72
+ timelineSystemEventsConfig?: TimelineSystemEventsConfig;
73
+ /** @deprecated Use `timelineSystemEventsConfig.toggleLabel`. */
74
+ timelineSystemEventsToggleLabel?: string;
75
+ /** @deprecated Use `timelineSystemEventsConfig.storageKey`. */
76
+ timelineSystemEventsStorageKey?: string;
77
+ /** @deprecated Use `timelineSystemEventsConfig.defaultVisible`. */
78
+ timelineSystemEventsDefaultVisible?: boolean;
79
+ /** @deprecated Use `timelineSystemEventsConfig.hiddenHint`. */
80
+ timelineSystemEventsHiddenHint?: string;
81
+ /** @deprecated Use `timelineSystemEventsConfig.visibleHint`. */
82
+ timelineSystemEventsVisibleHint?: string;
71
83
  }
72
- declare function DetailView({ item, sections, getSignalScore, buildSuggestedActions, buildSourceItems: _buildSourceItems, getTimelineEvents, accountContacts, emailSignature, iconMap, onOpenEntityPanel, onOpenRecentActivity, onSuggestedActionFeedback: _onSuggestedActionFeedback, onScoreFeedback: _onScoreFeedback, onSignalApprove, getSignalApprovalState, signalLabels, hideApproveButton, signalBriefCopy, briefStyleVariant, renderDetailExtra, renderBeforeScore, renderAfterScore, lastActivityTime, renderTitleExtra, renderTitleSubtext, renderMetadataExtra, onOpenSignalBucket, approveButtonIconUrl, opportunityPreview, onRequestApproval, attentionCount, }: DetailViewProps): React.JSX.Element;
73
- declare function PrototypeInboxView({ items, filterCategories, detailSections, accountContacts, buildAccountContacts, emailSignature, buildSuggestedActions: buildSuggestedActionsProp, buildSourceItems: buildSourceItemsProp, getSignalScore: getSignalScoreProp, getTimelineEvents, iconMap, hideToolbarActions, hideHoverActions, onSuggestedActionFeedback, onScoreFeedback, onOpenSignalBucket, headerActions, onOpenEntityPanel, onOpenRecentActivity, onItemSelect, defaultViewMode, buildEntityChips, quickFilterTabs, hideAccountsButton, accountDetailsLabel, onSignalApprove, getSignalApprovalState, signalLabels, hideApproveButton, signalBriefCopy, briefStyleVariant, renderDetailExtra, renderBeforeScore, renderAfterScore, lastActivityTime, renderTitleExtra, renderTitleSubtext, sortOptions, activeSortId, onSortChange, }: PrototypeInboxViewProps): React.JSX.Element;
84
+ declare function DetailView({ item, sections, getSignalScore, buildSuggestedActions, buildSourceItems: _buildSourceItems, getTimelineEvents, accountContacts, emailSignature, iconMap, onOpenEntityPanel, onOpenRecentActivity, onSuggestedActionFeedback: _onSuggestedActionFeedback, onScoreFeedback: _onScoreFeedback, onSignalApprove, getSignalApprovalState, signalLabels, hideApproveButton, signalBriefCopy, briefStyleVariant, renderDetailExtra, renderBeforeScore, renderAfterScore, lastActivityTime, renderTitleExtra, renderTitleSubtext, renderMetadataExtra, onOpenSignalBucket, approveButtonIconUrl, opportunityPreview, onRequestApproval, attentionCount, timelineSystemEventsConfig: configProp, timelineSystemEventsToggleLabel, timelineSystemEventsStorageKey, timelineSystemEventsDefaultVisible, timelineSystemEventsHiddenHint, timelineSystemEventsVisibleHint, }: DetailViewProps): React.JSX.Element;
85
+ declare function PrototypeInboxView({ items, filterCategories, detailSections, accountContacts, buildAccountContacts, emailSignature, buildSuggestedActions: buildSuggestedActionsProp, buildSourceItems: buildSourceItemsProp, getSignalScore: getSignalScoreProp, getTimelineEvents, iconMap, hideToolbarActions, hideHoverActions, onSuggestedActionFeedback, onScoreFeedback, onOpenSignalBucket, headerActions, onOpenEntityPanel, onOpenRecentActivity, onItemSelect, defaultViewMode, buildEntityChips, quickFilterTabs, hideAccountsButton, accountDetailsLabel, onSignalApprove, getSignalApprovalState, signalLabels, hideApproveButton, signalBriefCopy, briefStyleVariant, renderDetailExtra, renderBeforeScore, renderAfterScore, lastActivityTime, timelineSystemEventsConfig, attentionCount, renderTitleExtra, renderTitleSubtext, sortOptions, activeSortId, onSortChange, }: PrototypeInboxViewProps): React.JSX.Element;
74
86
 
75
87
  export { DetailView, type DetailViewProps, PrototypeInboxView, type PrototypeInboxViewProps };
@@ -86,6 +86,88 @@ const DEFAULT_SIGNAL_SCORE = {
86
86
  ],
87
87
  confidence: 72
88
88
  };
89
+ function TimelineSection({
90
+ timelineEvents,
91
+ showTimeline,
92
+ setShowTimeline,
93
+ showSystemEvents,
94
+ setShowSystemEvents,
95
+ attentionCount,
96
+ sysEvtConfig,
97
+ lastActivityTime
98
+ }) {
99
+ var _a;
100
+ const visibleEvents = [];
101
+ let hiddenCount = 0;
102
+ for (const e of timelineEvents) {
103
+ if (e.isSystemNoise) hiddenCount++;
104
+ if (!e.isSystemNoise || showSystemEvents) visibleEvents.push(e);
105
+ }
106
+ const hasSystemNoise = hiddenCount > 0;
107
+ const toggleLabel = (_a = sysEvtConfig == null ? void 0 : sysEvtConfig.toggleLabel) != null ? _a : "System events";
108
+ const firstVisibleTime = (!hasSystemNoise || showSystemEvents) && lastActivityTime ? lastActivityTime : visibleEvents.length > 0 ? visibleEvents[0].time : "";
109
+ const visibleCount = visibleEvents.length;
110
+ const eventCountLabel = `${visibleCount} ${visibleCount === 1 ? "event" : "events"}`;
111
+ return /* @__PURE__ */ jsxs("div", { className: "mb-8", children: [
112
+ /* @__PURE__ */ jsxs(
113
+ "div",
114
+ {
115
+ className: "group/timeline flex w-full items-center justify-between gap-2 py-2 rounded-md transition-colors hover:bg-muted/40 -mx-2 px-2",
116
+ "data-testid": "timeline-header",
117
+ children: [
118
+ /* @__PURE__ */ jsxs(
119
+ "button",
120
+ {
121
+ type: "button",
122
+ onClick: () => setShowTimeline((prev) => !prev),
123
+ className: "flex items-center gap-2 cursor-pointer bg-transparent border-0 p-0",
124
+ "data-testid": "timeline-collapse-btn",
125
+ children: [
126
+ /* @__PURE__ */ jsx("h3", { className: "text-xs font-bold text-muted-foreground uppercase tracking-wider group-hover/timeline:text-foreground transition-colors", children: "Activity timeline" }),
127
+ !showTimeline && attentionCount != null && attentionCount > 0 && /* @__PURE__ */ jsxs("span", { className: "inline-flex items-center gap-1 rounded-full bg-destructive/10 px-1.5 py-0.5 text-[10px] font-semibold text-destructive border border-destructive/20", children: [
128
+ attentionCount,
129
+ " new"
130
+ ] }),
131
+ !showTimeline && firstVisibleTime && /* @__PURE__ */ jsxs("span", { className: "text-[11px] text-muted-foreground/60", "data-testid": "last-activity-hint", children: [
132
+ "\xB7 Last activity ",
133
+ firstVisibleTime
134
+ ] }),
135
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1.5", children: [
136
+ /* @__PURE__ */ jsx("span", { className: "text-[11px] font-medium text-muted-foreground", "data-testid": "event-count", children: eventCountLabel }),
137
+ /* @__PURE__ */ jsx(ChevronDown, { className: `h-3.5 w-3.5 text-muted-foreground transition-transform duration-200 ${showTimeline ? "rotate-180" : ""}` })
138
+ ] })
139
+ ]
140
+ }
141
+ ),
142
+ hasSystemNoise && /* @__PURE__ */ jsxs(
143
+ "button",
144
+ {
145
+ type: "button",
146
+ onClick: () => setShowSystemEvents((prev) => !prev),
147
+ className: "flex shrink-0 items-center gap-1.5 rounded-full border border-border bg-background px-2.5 py-1 text-[11px] font-medium text-muted-foreground transition-colors hover:bg-muted/40 hover:text-foreground cursor-pointer",
148
+ "aria-pressed": showSystemEvents,
149
+ "data-testid": "system-events-toggle",
150
+ children: [
151
+ toggleLabel,
152
+ /* @__PURE__ */ jsx(
153
+ "span",
154
+ {
155
+ className: "inline-flex items-center justify-center rounded-full bg-muted px-1.5 text-[10px] font-semibold min-w-[18px] tabular-nums",
156
+ "data-testid": "hidden-count-badge",
157
+ children: hiddenCount
158
+ }
159
+ )
160
+ ]
161
+ }
162
+ )
163
+ ]
164
+ }
165
+ ),
166
+ showTimeline && visibleEvents.length > 0 && /* @__PURE__ */ jsx("div", { className: "mt-3", children: /* @__PURE__ */ jsx(TimelineActivity, { events: visibleEvents }) }),
167
+ showTimeline && !showSystemEvents && (sysEvtConfig == null ? void 0 : sysEvtConfig.hiddenHint) && hasSystemNoise && /* @__PURE__ */ jsx("p", { className: "mt-2 text-[11px] text-muted-foreground/60 border-t border-dashed border-border pt-2", "data-testid": "timeline-footer-hint", children: sysEvtConfig.hiddenHint }),
168
+ showTimeline && showSystemEvents && (sysEvtConfig == null ? void 0 : sysEvtConfig.visibleHint) && hasSystemNoise && /* @__PURE__ */ jsx("p", { className: "mt-2 text-[11px] text-muted-foreground/60 border-t border-dashed border-border pt-2", "data-testid": "timeline-footer-hint", children: sysEvtConfig.visibleHint.replace("{count}", String(hiddenCount)) })
169
+ ] });
170
+ }
89
171
  function DetailView({
90
172
  item,
91
173
  sections,
@@ -117,11 +199,63 @@ function DetailView({
117
199
  approveButtonIconUrl,
118
200
  opportunityPreview,
119
201
  onRequestApproval,
120
- attentionCount
202
+ attentionCount,
203
+ timelineSystemEventsConfig: configProp,
204
+ timelineSystemEventsToggleLabel,
205
+ timelineSystemEventsStorageKey,
206
+ timelineSystemEventsDefaultVisible,
207
+ timelineSystemEventsHiddenHint,
208
+ timelineSystemEventsVisibleHint
121
209
  }) {
122
- var _a, _b, _c, _d, _e;
210
+ var _a, _b, _c, _d;
211
+ const sysEvtConfig = React.useMemo(() => {
212
+ if (configProp) return configProp;
213
+ if (timelineSystemEventsToggleLabel || timelineSystemEventsStorageKey || timelineSystemEventsDefaultVisible !== void 0 || timelineSystemEventsHiddenHint || timelineSystemEventsVisibleHint) {
214
+ return {
215
+ toggleLabel: timelineSystemEventsToggleLabel,
216
+ storageKey: timelineSystemEventsStorageKey,
217
+ defaultVisible: timelineSystemEventsDefaultVisible,
218
+ hiddenHint: timelineSystemEventsHiddenHint,
219
+ visibleHint: timelineSystemEventsVisibleHint
220
+ };
221
+ }
222
+ return void 0;
223
+ }, [
224
+ configProp,
225
+ timelineSystemEventsToggleLabel,
226
+ timelineSystemEventsStorageKey,
227
+ timelineSystemEventsDefaultVisible,
228
+ timelineSystemEventsHiddenHint,
229
+ timelineSystemEventsVisibleHint
230
+ ]);
123
231
  const [showTimeline, setShowTimeline] = React.useState(false);
124
232
  const [extraActions, setExtraActions] = React.useState([]);
233
+ const sysEvtDefaultVisible = (_a = sysEvtConfig == null ? void 0 : sysEvtConfig.defaultVisible) != null ? _a : false;
234
+ const sysEvtStorageKey = sysEvtConfig == null ? void 0 : sysEvtConfig.storageKey;
235
+ const [showSystemEvents, setShowSystemEvents] = React.useState(sysEvtDefaultVisible);
236
+ const initialReadDoneRef = React.useRef(false);
237
+ React.useEffect(() => {
238
+ if (!sysEvtStorageKey) {
239
+ initialReadDoneRef.current = true;
240
+ return;
241
+ }
242
+ try {
243
+ const stored = localStorage.getItem(sysEvtStorageKey);
244
+ if (stored !== null) {
245
+ setShowSystemEvents(stored === "true");
246
+ }
247
+ } catch (e) {
248
+ }
249
+ initialReadDoneRef.current = true;
250
+ }, [sysEvtStorageKey]);
251
+ React.useEffect(() => {
252
+ if (!sysEvtStorageKey) return;
253
+ if (!initialReadDoneRef.current) return;
254
+ try {
255
+ localStorage.setItem(sysEvtStorageKey, String(showSystemEvents));
256
+ } catch (e) {
257
+ }
258
+ }, [showSystemEvents, sysEvtStorageKey]);
125
259
  React.useEffect(() => {
126
260
  setShowTimeline(false);
127
261
  setExtraActions([]);
@@ -203,14 +337,17 @@ function DetailView({
203
337
  {
204
338
  score: signalData.score,
205
339
  urgencyLabel: signalData.urgencyLabel,
206
- urgencyExplanation: (_a = signalData.urgencyExplanation) != null ? _a : signalData.signalBrief,
207
- factors: (_b = signalData.priorityFactors) != null ? _b : [],
340
+ urgencyExplanation: (_b = signalData.urgencyExplanation) != null ? _b : signalData.signalBrief,
341
+ factors: (_c = signalData.priorityFactors) != null ? _c : [],
208
342
  metaText: void 0,
209
343
  feedbackChips: signalData.priorityFeedbackChips,
210
- onFeedbackSubmit: signalData.onPriorityFeedback
344
+ onFeedbackSubmit: signalData.onPriorityFeedback,
345
+ initialFactorFeedback: signalData.initialFactorPopoverFeedback,
346
+ onFactorFeedback: signalData.onFactorFeedback,
347
+ initialPriorityFeedback: signalData.initialPriorityFeedback
211
348
  }
212
349
  ),
213
- signalData.timeChipLabel && /* @__PURE__ */ jsx(Badge, { variant: "outline", title: (_c = signalData.timeChipDetail) != null ? _c : void 0, children: signalData.timeChipLabel }),
350
+ signalData.timeChipLabel && /* @__PURE__ */ jsx(Badge, { variant: "outline", title: (_d = signalData.timeChipDetail) != null ? _d : void 0, children: signalData.timeChipLabel }),
214
351
  /* @__PURE__ */ jsxs(
215
352
  "button",
216
353
  {
@@ -249,37 +386,19 @@ function DetailView({
249
386
  ] });
250
387
  })(),
251
388
  renderAfterScore == null ? void 0 : renderAfterScore(item),
252
- sections.timeline && timelineEvents.length > 0 && /* @__PURE__ */ jsxs("div", { className: "mb-8", children: [
253
- /* @__PURE__ */ jsxs(
254
- "button",
255
- {
256
- type: "button",
257
- onClick: () => setShowTimeline((prev) => !prev),
258
- className: "group/timeline flex w-full items-center justify-between gap-2 py-2 rounded-md transition-colors hover:bg-muted/40 -mx-2 px-2 cursor-pointer",
259
- children: [
260
- /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
261
- /* @__PURE__ */ jsx("h3", { className: "text-xs font-bold text-muted-foreground uppercase tracking-wider group-hover/timeline:text-foreground transition-colors", children: "Activity timeline" }),
262
- !showTimeline && attentionCount != null && attentionCount > 0 && /* @__PURE__ */ jsxs("span", { className: "inline-flex items-center gap-1 rounded-full bg-destructive/10 px-1.5 py-0.5 text-[10px] font-semibold text-destructive border border-destructive/20", children: [
263
- attentionCount,
264
- " new"
265
- ] }),
266
- !showTimeline && (lastActivityTime || timelineEvents.length > 0 && timelineEvents[0].time) && /* @__PURE__ */ jsxs("span", { className: "text-[11px] text-muted-foreground/60", children: [
267
- "\xB7 Last activity ",
268
- (_e = lastActivityTime != null ? lastActivityTime : (_d = timelineEvents[0]) == null ? void 0 : _d.time) != null ? _e : ""
269
- ] })
270
- ] }),
271
- /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1.5", children: [
272
- /* @__PURE__ */ jsxs("span", { className: "text-[11px] font-medium text-muted-foreground", children: [
273
- timelineEvents.length,
274
- " events"
275
- ] }),
276
- /* @__PURE__ */ jsx(ChevronDown, { className: `h-3.5 w-3.5 text-muted-foreground transition-transform duration-200 ${showTimeline ? "rotate-180" : ""}` })
277
- ] })
278
- ]
279
- }
280
- ),
281
- showTimeline && /* @__PURE__ */ jsx("div", { className: "mt-3", children: /* @__PURE__ */ jsx(TimelineActivity, { events: timelineEvents }) })
282
- ] })
389
+ sections.timeline && timelineEvents.length > 0 && /* @__PURE__ */ jsx(
390
+ TimelineSection,
391
+ {
392
+ timelineEvents,
393
+ showTimeline,
394
+ setShowTimeline,
395
+ showSystemEvents,
396
+ setShowSystemEvents,
397
+ attentionCount,
398
+ sysEvtConfig,
399
+ lastActivityTime
400
+ }
401
+ )
283
402
  ] }),
284
403
  sections.suggestedActions && /* @__PURE__ */ jsx(SignalApproval.Gate, { children: /* @__PURE__ */ jsx(
285
404
  SuggestedActions,
@@ -340,6 +459,8 @@ function PrototypeInboxView({
340
459
  renderBeforeScore,
341
460
  renderAfterScore,
342
461
  lastActivityTime,
462
+ timelineSystemEventsConfig,
463
+ attentionCount,
343
464
  renderTitleExtra,
344
465
  renderTitleSubtext,
345
466
  sortOptions,
@@ -537,6 +658,8 @@ function PrototypeInboxView({
537
658
  renderBeforeScore,
538
659
  renderAfterScore,
539
660
  lastActivityTime,
661
+ timelineSystemEventsConfig,
662
+ attentionCount,
540
663
  renderTitleExtra,
541
664
  renderTitleSubtext,
542
665
  onOpenSignalBucket