@belonguniverseai/react-sdk 0.6.33 → 0.6.35

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 (120) hide show
  1. package/dist/api/account-connectors.d.ts +1 -1
  2. package/dist/api/agent-computer.d.ts +9 -0
  3. package/dist/api/client.d.ts +948 -91
  4. package/dist/api/computer.d.ts +60 -0
  5. package/dist/api/goals.d.ts +4 -4
  6. package/dist/api/guide.d.ts +11 -4
  7. package/dist/api/proactive.d.ts +47 -0
  8. package/dist/api/query-keys.d.ts +22 -1
  9. package/dist/api/quota-refusal.d.ts +1 -1
  10. package/dist/api/task-schedule-folders.d.ts +4 -4
  11. package/dist/api/task-schedule-projects.d.ts +7 -7
  12. package/dist/api/task-schedules.d.ts +125 -18
  13. package/dist/app/dock-story-data.d.ts +5 -5
  14. package/dist/component/{abnfDiagram-N423BO3Z-CK4wvzwz.js → abnfDiagram-N423BO3Z-CRZoFiVH.js} +4 -4
  15. package/dist/component/{architectureDiagram-T3A2C74G-DoljsqqO.js → architectureDiagram-T3A2C74G-CaRtqw4X.js} +6 -6
  16. package/dist/component/{blockDiagram-VBNYF7ZC-Ie7SErpH.js → blockDiagram-VBNYF7ZC-BK04msnb.js} +8 -8
  17. package/dist/component/{c4Diagram-5PPSVZJV-rfEof5mj.js → c4Diagram-5PPSVZJV-BMDcb-rm.js} +4 -4
  18. package/dist/component/{channel-C5ABP6lE.js → channel-Da7DEnT8.js} +2 -2
  19. package/dist/component/{chunk-2GRJ4B5K-CWOCv67u.js → chunk-2GRJ4B5K-CxwwCtK7.js} +2 -2
  20. package/dist/component/{chunk-3NCLNEKW-BJYANBvv.js → chunk-3NCLNEKW-C6R8qHlR.js} +2 -2
  21. package/dist/component/{chunk-4I5QYGJK-C29OfER5.js → chunk-4I5QYGJK-Ccf8L2Bk.js} +2 -2
  22. package/dist/component/{chunk-5RXB4S5H-D__NH4Op.js → chunk-5RXB4S5H-V2z-LyAY.js} +6 -6
  23. package/dist/component/{chunk-6Q2QTUOP-BgSQgII8.js → chunk-6Q2QTUOP-C6GL9-4r.js} +3 -3
  24. package/dist/component/{chunk-7Z6QIM7H-vNexNF_V.js → chunk-7Z6QIM7H-BV6R4sWE.js} +8 -8
  25. package/dist/component/{chunk-GF5L2VYU-D3vxqomE.js → chunk-GF5L2VYU-DAD1p6ak.js} +6 -6
  26. package/dist/component/{chunk-I66GZJ75-Dkw1ISGd.js → chunk-I66GZJ75-DEykrnbu.js} +2 -2
  27. package/dist/component/{chunk-J7OUQ5F2-dC67pJWg.js → chunk-J7OUQ5F2-CEWcOukY.js} +7 -7
  28. package/dist/component/{chunk-JQJVKLGR-Djj9TdhH.js → chunk-JQJVKLGR-DCAX80x3.js} +8 -8
  29. package/dist/component/{chunk-KBJHAD2P-dwIA6Vmi.js → chunk-KBJHAD2P-Bk8hJC_U.js} +2 -2
  30. package/dist/component/{chunk-NSK5VX7P-thQxjtNK.js → chunk-NSK5VX7P-D-saWvpt.js} +2 -2
  31. package/dist/component/{chunk-QR6OTTB3-OMd-rgNj.js → chunk-QR6OTTB3-CMv_Vw9A.js} +7 -7
  32. package/dist/component/{chunk-UBXNYLIW-D26S6zO6.js → chunk-UBXNYLIW-BfXPFCA1.js} +3 -3
  33. package/dist/component/{chunk-W5SLKNZC-DLV7M8by.js → chunk-W5SLKNZC-BL-VPYuH.js} +2 -2
  34. package/dist/component/{chunk-WRU74C26-13bvIAgD.js → chunk-WRU74C26-BXxIvhYq.js} +4 -4
  35. package/dist/component/{classDiagram-JCYQIIEL-BFQ72AZA.js → classDiagram-JCYQIIEL-CRKRQjr4.js} +13 -13
  36. package/dist/component/{classDiagram-v2-OCEON4UE-UFfArXpP.js → classDiagram-v2-OCEON4UE-ltwXlVlU.js} +13 -13
  37. package/dist/component/{component-Bhs6PFPY.js → component-BNq6d1iV.js} +23787 -20816
  38. package/dist/component/{cynefinDiagram-MW4NZA55-Bgfw8c41.js → cynefinDiagram-MW4NZA55-Bju0bDR1.js} +4 -4
  39. package/dist/component/{dagre-VZM6K2ZE-CQoUcF3S.js → dagre-VZM6K2ZE-fMS2g5Lt.js} +9 -9
  40. package/dist/component/{diagram-7IWD3JNH-C8-mvAEv.js → diagram-7IWD3JNH-CoDJAyv-.js} +5 -5
  41. package/dist/component/{diagram-B4RE2ZJO-BATqCIx3.js → diagram-B4RE2ZJO-nioVFGn5.js} +3 -3
  42. package/dist/component/{diagram-LBJQPF4R-DwRMRXWz.js → diagram-LBJQPF4R-BuBX2Dz0.js} +4 -4
  43. package/dist/component/{diagram-Q27KOJAE-D6gO0LTm.js → diagram-Q27KOJAE-D6amwUDE.js} +6 -6
  44. package/dist/component/{diagram-UB23O5K3-4nOrWHql.js → diagram-UB23O5K3-BfBhBu7Y.js} +4 -4
  45. package/dist/component/{ebnfDiagram-BXEA7PRR-DCO-Nj3k.js → ebnfDiagram-BXEA7PRR-Cy3CaiTX.js} +4 -4
  46. package/dist/component/{erDiagram-JOGREHBK-hWtImhPN.js → erDiagram-JOGREHBK-BUomkKWY.js} +12 -12
  47. package/dist/component/flowDiagram-UKHOOZJN-C0aiK5kF.js +19 -0
  48. package/dist/component/{ganttDiagram-PKOTCBZU-BE8Mqoej.js → ganttDiagram-PKOTCBZU-BWWeGylo.js} +3 -3
  49. package/dist/component/{gitGraphDiagram-DS77QQ5N-DURS7rAN.js → gitGraphDiagram-DS77QQ5N-BFNi8KrJ.js} +3 -3
  50. package/dist/component/index.js +2 -2
  51. package/dist/component/{infoDiagram-6WML65LV-BqBxR6YB.js → infoDiagram-6WML65LV-Ba4nVdwJ.js} +3 -3
  52. package/dist/component/{ishikawaDiagram-WSZJBQD7-CnYZd1Dq.js → ishikawaDiagram-WSZJBQD7-JBSR3acP.js} +4 -4
  53. package/dist/component/{journeyDiagram-NVQOT4AX-Cgkpx4Qx.js → journeyDiagram-NVQOT4AX-BAGUQhvd.js} +3 -3
  54. package/dist/component/{kanban-definition-27J2QSJJ-CJSdhT0i.js → kanban-definition-27J2QSJJ-CIBw8XVT.js} +9 -9
  55. package/dist/component/{line-BBEHlpsV.js → line-BPXxX2mb.js} +2 -2
  56. package/dist/component/{mindmap-definition-FAOFIHXS-DgHouLA-.js → mindmap-definition-FAOFIHXS-ZwmeO9Ju.js} +11 -11
  57. package/dist/component/{pegDiagram-VL7TDLO6-B_iGQ6sI.js → pegDiagram-VL7TDLO6-g6cHkKXH.js} +4 -4
  58. package/dist/component/{pieDiagram-7S7Q4E2Y-g7GxM0JA.js → pieDiagram-7S7Q4E2Y-6if4UZeA.js} +4 -4
  59. package/dist/component/{quadrantDiagram-CIZ2JOQS-Bp7z4raq.js → quadrantDiagram-CIZ2JOQS-DW9Wi1_3.js} +2 -2
  60. package/dist/component/{railroadDiagram-AXF67PYL-CYx3PP5o.js → railroadDiagram-AXF67PYL-DRKsvNWu.js} +4 -4
  61. package/dist/component/{requirementDiagram-LRYGKXZP-BJNRJceo.js → requirementDiagram-LRYGKXZP-CKtakT6g.js} +11 -11
  62. package/dist/component/{sankeyDiagram-W5VNT64P-Cf0tVHbW.js → sankeyDiagram-W5VNT64P-B-oejkos.js} +2 -2
  63. package/dist/component/{sequenceDiagram-SI44F4Z6-BsAsKMRH.js → sequenceDiagram-SI44F4Z6-3RmdhrrK.js} +4 -4
  64. package/dist/component/{stateDiagram-OKZ733FA-Bpk0vtTK.js → stateDiagram-OKZ733FA-ChwQeLFK.js} +14 -14
  65. package/dist/component/{stateDiagram-v2-UEYNNEHI-CJFoUvD2.js → stateDiagram-v2-UEYNNEHI-Cu0mGIbX.js} +13 -13
  66. package/dist/component/{swimlanes-SLNWSIFB-Be5A0lwq.js → swimlanes-SLNWSIFB-B1f2ZxW_.js} +9 -9
  67. package/dist/component/{swimlanesDiagram-ULZ7WXOC-J8VNaPhM.js → swimlanesDiagram-ULZ7WXOC-CspwK4RG.js} +13 -13
  68. package/dist/component/{timeline-definition-Z64GVDOM-CU9PEkPY.js → timeline-definition-Z64GVDOM-Bg9gKcBJ.js} +4 -4
  69. package/dist/component/{vennDiagram-T6HMQDX7-Cno78tFK.js → vennDiagram-T6HMQDX7-BS7jr5XD.js} +4 -4
  70. package/dist/component/{wardleyDiagram-T6FBY63Y-BEb1Rn5J.js → wardleyDiagram-T6FBY63Y-DVm3XZBO.js} +4 -4
  71. package/dist/component/{xychartDiagram-ELKLHX3M-BwjMczCl.js → xychartDiagram-ELKLHX3M-Cg8qYbc9.js} +7 -7
  72. package/dist/components/ai-elements/chat-link.d.ts +15 -0
  73. package/dist/components/connectors/ConnectorBrandLogo.d.ts +4 -0
  74. package/dist/components/embed/ComputerSettings.d.ts +7 -0
  75. package/dist/components/embed/EmbedConversation.d.ts +4 -1
  76. package/dist/components/embed/EmbedRail.d.ts +8 -2
  77. package/dist/components/embed/EmbedSessions.d.ts +22 -2
  78. package/dist/components/embed/MobileNavBar.d.ts +4 -2
  79. package/dist/components/embed/ProactiveChecksSetting.d.ts +8 -0
  80. package/dist/components/embed/use-settings-owner-key.d.ts +15 -0
  81. package/dist/components/pinned/AgentComputerSheet.d.ts +5 -0
  82. package/dist/components/pinned/AgentMessageNote.d.ts +12 -0
  83. package/dist/components/pinned/PinnedChatHeader.d.ts +15 -0
  84. package/dist/components/pinned/SentByAgentTag.d.ts +1 -0
  85. package/dist/components/pinned/agent-computer-open-state.d.ts +9 -0
  86. package/dist/components/pinned/character/AgentCharacter.d.ts +8 -0
  87. package/dist/components/pinned/character/agent-character-art.d.ts +12 -0
  88. package/dist/components/pinned/personal-agent.d.ts +43 -0
  89. package/dist/components/pinned/profile/AgentProfileSheet.d.ts +14 -0
  90. package/dist/components/pinned/profile/ProfileAboutTab.d.ts +4 -0
  91. package/dist/components/pinned/profile/ProfileActivityTab.d.ts +9 -0
  92. package/dist/components/pinned/profile/ProfileSourcesTab.d.ts +8 -0
  93. package/dist/components/pinned/profile/profile-activity.d.ts +52 -0
  94. package/dist/components/pinned/use-agent-name.d.ts +2 -0
  95. package/dist/components/scheduled/ScheduleFolderDialogs.d.ts +14 -0
  96. package/dist/components/scheduled/ScheduleFolderTree.d.ts +2 -1
  97. package/dist/components/scheduled/ScheduledListSurface.d.ts +7 -0
  98. package/dist/embed/goal-cap-notice.d.ts +0 -9
  99. package/dist/embed/pinned-chat.d.ts +52 -0
  100. package/dist/embed/voice/line-run-reader.d.ts +1 -1
  101. package/dist/embed/voice-call.d.ts +6 -0
  102. package/dist/i18n/messages/en.d.ts +168 -9
  103. package/dist/i18n/messages/surfaces/embedMisc.d.ts +4 -0
  104. package/dist/i18n/messages/surfaces/pinned.d.ts +328 -0
  105. package/dist/i18n/messages/surfaces/scheduled.d.ts +113 -5
  106. package/dist/i18n/messages/surfaces/sessions.d.ts +4 -0
  107. package/dist/i18n/messages/surfaces/settings.d.ts +152 -0
  108. package/dist/i18n/messages/surfaces/stream.d.ts +52 -4
  109. package/dist/i18n/messages/surfaces/vault.d.ts +1 -1
  110. package/dist/routes/chat/history-merge.d.ts +4 -1
  111. package/dist/routes/chat/session-api.d.ts +1 -1
  112. package/dist/routes/chat/use-next-step-suggestion.d.ts +4 -0
  113. package/dist/stream/belong-chat-transport.d.ts +19 -22
  114. package/dist/stream/message-metadata.d.ts +57 -0
  115. package/dist/stream/pause-notice-copy.d.ts +3 -0
  116. package/dist/stream/reconnect-backoff.d.ts +39 -0
  117. package/dist/stream/run-error-copy.d.ts +25 -0
  118. package/dist/stream/stream-notice.d.ts +9 -0
  119. package/package.json +1 -1
  120. package/dist/component/flowDiagram-UKHOOZJN-8qLgX2Wv.js +0 -19
@@ -1,8 +1,8 @@
1
+ import { PinnedChatRow, SessionSummary } from './EmbedSessions';
1
2
  import { ReactNode } from 'react';
2
3
  import { VoiceActionFlash } from '../../embed/closed-surface-voice-bus.ts';
3
4
  import { VoiceStatus } from '../../embed/voice-bus.ts';
4
5
  import { SpawnAgent } from '../../embed/voice/agent-spawn.ts';
5
- import { SessionSummary } from './EmbedSessions';
6
6
  import { PlanProgress } from '../../stream/plan-progress.ts';
7
7
  import { BelongTheme, BelongThemePalette, PresetName } from '../../types/public.ts';
8
8
  /** The rail's nav entries. TWIN of `DockView` in `embed/dock-state.ts` — the
@@ -16,7 +16,13 @@ export type EmbedView = "chat" | "goal" | "files" | "scheduled" | "prompts" | "c
16
16
  * Focus hides labels only; every destination remains available as an icon.
17
17
  * Active fill and brand colors come from the tenant palette.
18
18
  */
19
- export declare function EmbedRail({ view, collapsed, user, theme, palette, sessions, activeId, planProgress, speakEnabled, ttsSupported, voiceSupported, voiceStatus, pendingVoiceDraft, voiceActionFlash, accent, cssVars, presets, activePreset, onSelectView, onToggleMode, onToggleSide, onAccentChange, onAccentReset, onCssVarsChange, onApplyPreset, onLogout, onNewSession, onSelectSession, onSelectAgentLine, spawnAgent, pendingAgentLine, onCloseAgentLine, onDeleteSession, onRenameSession, onSessionsOpen, onViewStats, onToggleSpeak, fullscreen, navigationLabelsVisible, onToggleNavigationLabels, layoutControl, connectorsUnavailable, skillsUnavailable, artifactsUnavailable, goalPresent, goalNeedsYou, }: {
19
+ export declare function EmbedRail({ onAgentNameClick, pinnedActive, pinned, view, collapsed, user, theme, palette, sessions, activeId, planProgress, speakEnabled, ttsSupported, voiceSupported, voiceStatus, pendingVoiceDraft, voiceActionFlash, accent, cssVars, presets, activePreset, onSelectView, onToggleMode, onToggleSide, onAccentChange, onAccentReset, onCssVarsChange, onApplyPreset, onLogout, onNewSession, onSelectSession, onSelectAgentLine, spawnAgent, pendingAgentLine, onCloseAgentLine, onDeleteSession, onRenameSession, onSessionsOpen, onViewStats, onToggleSpeak, fullscreen, navigationLabelsVisible, onToggleNavigationLabels, layoutControl, connectorsUnavailable, skillsUnavailable, artifactsUnavailable, goalPresent, goalNeedsYou, }: {
20
+ /** Beside the logo in the labeled sidebar: the name goes where the logo goes (BEL-348). */
21
+ onAgentNameClick?: (() => void) | undefined;
22
+ /** The pinned chat is on screen: no chat entry is the current page. */
23
+ pinnedActive?: boolean;
24
+ /** Its row at the top of Chat history. */
25
+ pinned?: PinnedChatRow | undefined;
20
26
  view: EmbedView;
21
27
  collapsed: boolean;
22
28
  user: string | null;
@@ -1,11 +1,31 @@
1
1
  import { BelongTheme } from '../../types/public.ts';
2
+ import { AgentCharacterId, AgentCharacterState } from '../pinned/character/agent-character-art.ts';
2
3
  export interface SessionSummary {
3
4
  readonly sessionId: string;
4
5
  readonly title: string | null;
5
6
  readonly updatedAt: string;
6
7
  }
8
+ /** The pinned chat's row, always first (BEL-348). */
9
+ export interface PinnedChatRow {
10
+ readonly name: string;
11
+ readonly brand: {
12
+ readonly logo?: string;
13
+ readonly initials: string;
14
+ };
15
+ /** The personal agent's face, where the brand has one (Sima, Bel). */
16
+ readonly face?: {
17
+ readonly character: AgentCharacterId;
18
+ readonly state: AgentCharacterState;
19
+ } | undefined;
20
+ readonly unreadCount: number;
21
+ readonly lastMessage: string | null;
22
+ readonly refresh?: () => void;
23
+ readonly active: boolean;
24
+ readonly onOpen: () => void;
25
+ }
7
26
  type SessionsBodyProps = {
8
27
  sessions: readonly SessionSummary[];
28
+ pinned?: PinnedChatRow | undefined;
9
29
  activeId: string | null;
10
30
  onNew: () => void;
11
31
  onSelect: (id: string) => void;
@@ -27,7 +47,7 @@ type SessionsBodyProps = {
27
47
  /** Shared history behavior for the compact menu and fullscreen settings.
28
48
  * Panel rows use native buttons with sibling edit actions, so history does
29
49
  * not depend on a Radix menu context or nest interactive controls. */
30
- export declare function EmbedSessionsBody({ sessions, activeId, onNew, onSelect, onDelete, onRename, sessionAgentLine, onViewStats, presentation, }: SessionsBodyProps & {
50
+ export declare function EmbedSessionsBody({ sessions, pinned, activeId, onNew, onSelect, onDelete, onRename, sessionAgentLine, onViewStats, presentation, }: SessionsBodyProps & {
31
51
  presentation?: "menu" | "panel";
32
52
  }): import("react").JSX.Element;
33
53
  /**
@@ -35,7 +55,7 @@ export declare function EmbedSessionsBody({ sessions, activeId, onNew, onSelect,
35
55
  * an inline text edit, or delete one via an inline trash → confirm flow. Rename +
36
56
  * delete are per-row inline affordances that keep the menu open (BEL-120).
37
57
  */
38
- export declare function EmbedSessions({ sessions, activeId, theme, side, triggerClassName, triggerLabel, presentation, onNew, onSelect, onDelete, onRename, onOpen, sessionAgentLine, onViewStats, }: SessionsBodyProps & {
58
+ export declare function EmbedSessions({ sessions, pinned, activeId, theme, side, triggerClassName, triggerLabel, presentation, onNew, onSelect, onDelete, onRename, onOpen, sessionAgentLine, onViewStats, }: SessionsBodyProps & {
39
59
  theme: BelongTheme;
40
60
  /** Which way the menu opens — toward the panel from the rail edge, or
41
61
  * upward when the trigger lives in the mobile bottom nav bar. */
@@ -1,12 +1,14 @@
1
1
  import { ComponentProps } from 'react';
2
2
  import { EmbedAvatar } from './EmbedAvatar';
3
- import { SessionSummary } from './EmbedSessions';
3
+ import { PinnedChatRow, SessionSummary } from './EmbedSessions';
4
4
  import { EmbedView } from './EmbedRail';
5
5
  import { BelongTheme, BelongThemePalette, PresetName } from '../../types/public.ts';
6
6
  /** Four mobile destinations. Secondary tools and account controls live in
7
7
  * Tools; session switching lives above the conversation. Primary cells retain
8
8
  * 44px targets (56px with labels) and surface-scaled glyphs without horizontal scrolling. */
9
- export declare function MobileNavBar({ view, user, theme, palette, sessions, activeId, voiceSupported, readReplies, accent, cssVars, presets, activePreset, onSelectView, onClose, onToggleMode, onToggleSide, onAccentChange, onAccentReset, onCssVarsChange, onApplyPreset, onLogout, onNewSession, onSelectSession, onDeleteSession, onRenameSession, onSessionsOpen, onViewStats, navigationLabelsVisible, onToggleNavigationLabels, connectorsUnavailable, skillsUnavailable, artifactsUnavailable, goalPresent, }: {
9
+ export declare function MobileNavBar({ pinned, view, user, theme, palette, sessions, activeId, voiceSupported, readReplies, accent, cssVars, presets, activePreset, onSelectView, onClose, onToggleMode, onToggleSide, onAccentChange, onAccentReset, onCssVarsChange, onApplyPreset, onLogout, onNewSession, onSelectSession, onDeleteSession, onRenameSession, onSessionsOpen, onViewStats, navigationLabelsVisible, onToggleNavigationLabels, connectorsUnavailable, skillsUnavailable, artifactsUnavailable, goalPresent, }: {
10
+ /** The pinned chat's row at the top of Chat history (BEL-348). */
11
+ pinned?: PinnedChatRow | undefined;
10
12
  /** Focus changes navigation labels only; the icons always remain available. */
11
13
  navigationLabelsVisible?: boolean;
12
14
  onToggleNavigationLabels?: () => void;
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Settings → General: on/off for proactive checks (BEL-348). Renders nothing
3
+ * when the feature is not on for this user. It names the connected apps a check
4
+ * reads, so that's never a surprise. What a check finds shows up in the pinned
5
+ * chat and on Slack, not here, and by email for those who turn that on, which is
6
+ * offered only where email can reach them.
7
+ */
8
+ export declare const ProactiveChecksSetting: () => import("react").JSX.Element | null;
@@ -0,0 +1,15 @@
1
+ /**
2
+ * The signed-in user a settings section's cached data belongs to: the API
3
+ * base URL plus the token's issuer, tenant and user. Null until the host has
4
+ * handed the dock a token.
5
+ */
6
+ export declare const readSettingsOwnerKey: (baseUrl: string) => string | null;
7
+ /**
8
+ * Track the owner key so a section re-keys (and drops another user's cached
9
+ * data) the moment the host switches users. `authError` turns true when no
10
+ * token arrives at all, so the section can say so instead of loading forever.
11
+ */
12
+ export declare const useSettingsOwnerKey: () => {
13
+ readonly ownerKey: string | null;
14
+ readonly authError: boolean;
15
+ };
@@ -0,0 +1,5 @@
1
+ import { ReactElement } from 'react';
2
+ export declare const AgentComputerSheet: ({ name, onClose, }: {
3
+ readonly name: string;
4
+ readonly onClose: () => void;
5
+ }) => ReactElement;
@@ -0,0 +1,12 @@
1
+ import { ProactiveTurnNote, ProactiveTurnSource } from '../../stream/message-metadata.ts';
2
+ type Caption = {
3
+ /** Null when there's no logo of ours for it. */
4
+ readonly iconKey: string | null;
5
+ readonly name: string;
6
+ readonly place: string | null;
7
+ };
8
+ export declare const captionOf: (origin: ProactiveTurnSource["origin"], scheduledTask: string) => Caption;
9
+ export declare function AgentMessageNote({ note }: {
10
+ readonly note: ProactiveTurnNote;
11
+ }): import("react").JSX.Element;
12
+ export {};
@@ -0,0 +1,15 @@
1
+ import { ReactElement, ReactNode } from 'react';
2
+ import { Proactive } from '../../api/proactive.ts';
3
+ import { PersonalAgent } from './personal-agent.ts';
4
+ export declare const PinnedChatHeader: ({ proactive, name, agent, covered, onOpenProfile, onOpenComputer, layoutControl, }: {
5
+ readonly proactive: Proactive;
6
+ readonly name: string;
7
+ /** Sima or Bel, where the brand has one: their face replaces the status dot. */
8
+ readonly agent: PersonalAgent | null;
9
+ /** A sheet covers this header: it's out of reach until the sheet closes. */
10
+ readonly covered: boolean;
11
+ readonly onOpenProfile: () => void;
12
+ readonly onOpenComputer: () => void;
13
+ /** On a phone, where there's no rail: the logo, as every other header has it. */
14
+ readonly layoutControl?: ReactNode;
15
+ }) => ReactElement;
@@ -0,0 +1 @@
1
+ export declare function SentByAgentTag(): import("react").JSX.Element;
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Which pinned chat's computer is open, for a reload of this tab to come back to it
3
+ * (CLAUDE.md §41). Per tab: another tab of the host shouldn't open onto a terminal.
4
+ * By chat, not just a yes: signing in as someone else in this tab mustn't open their
5
+ * computer, and wake it, without a click. Best-effort like dock-state.ts: no storage
6
+ * just means no restore.
7
+ */
8
+ export declare const readAgentComputerOpen: () => string | null;
9
+ export declare const writeAgentComputerOpen: (sessionId: string | null) => void;
@@ -0,0 +1,8 @@
1
+ import { ReactElement } from 'react';
2
+ import { AgentCharacterId, AgentCharacterState } from './agent-character-art.ts';
3
+ export declare const AgentCharacter: ({ character, state, size, className, }: {
4
+ readonly character: AgentCharacterId;
5
+ readonly state: AgentCharacterState;
6
+ readonly size: number;
7
+ readonly className?: string;
8
+ }) => ReactElement;
@@ -0,0 +1,12 @@
1
+ /**
2
+ * The personal agent's character art: Sima (Simetrik) and Bel (Belong), one
3
+ * self-contained SVG per state. Each is drawn as an <img>, like the brand marks
4
+ * in brand-marks.ts, so its CSS animation (and its prefers-reduced-motion
5
+ * fallback) lives inside the image and never touches the host page's styles.
6
+ *
7
+ * Generated from the illustrators' and animators' files; edit those, not this.
8
+ */
9
+ export type AgentCharacterId = "sima" | "bel";
10
+ export type AgentCharacterState = "idle" | "working" | "needs" | "paused";
11
+ /** The state as an image source, with its animation inside it. */
12
+ export declare const agentCharacterSrc: (who: AgentCharacterId, state: AgentCharacterState) => string;
@@ -0,0 +1,43 @@
1
+ import { Proactive } from '../../api/proactive.ts';
2
+ import { AgentCharacterId, AgentCharacterState } from './character/agent-character-art.ts';
3
+ export type PersonalAgent = {
4
+ readonly character: AgentCharacterId;
5
+ readonly name: string;
6
+ };
7
+ /**
8
+ * Set by the chat route while the pinned chat is on screen, so the agent's
9
+ * messages there are signed by Sima or Bel; null everywhere else, where the
10
+ * regular chat keeps the brand's agent name.
11
+ */
12
+ export declare const PinnedAgentAuthorContext: import('react').Context<PersonalAgent | null>;
13
+ type TurnLike = {
14
+ readonly role: string;
15
+ readonly metadata?: {
16
+ readonly taskId?: string | undefined;
17
+ readonly proactive?: unknown;
18
+ } | undefined;
19
+ };
20
+ /**
21
+ * Whether the pinned chat's last turn is one the agent started, and its task once
22
+ * the cloud has said so. A check's own message is internal, so a turn that doesn't
23
+ * follow one of the user's isn't an answer to them, even before history is re-read.
24
+ */
25
+ export declare const agentStartedLastTurn: (messages: readonly TurnLike[]) => {
26
+ readonly wroteLast: boolean;
27
+ readonly turnId: string | null;
28
+ };
29
+ export declare const personalAgentFor: (brandName: string) => PersonalAgent | null;
30
+ export declare const isPinnedWorking: (proactive: Proactive) => boolean;
31
+ export declare const personalAgentState: (proactive: Proactive) => AgentCharacterState;
32
+ /**
33
+ * For where it's already in front of them, in its header and its profile. The "needs
34
+ * you" mark is for the rail, to bring them here; here the chat says what it needs.
35
+ */
36
+ export declare const calmAgentState: (proactive: Proactive) => AgentCharacterState;
37
+ /** A line saying what it's doing, for the header and the profile. */
38
+ export declare const usePinnedStatus: (proactive: Proactive) => string;
39
+ /** The personal agent for the brand on screen, or null for a tenant's own brand. */
40
+ export declare const usePersonalAgent: () => PersonalAgent | null;
41
+ /** What the pinned chat calls the agent: its own name, else the brand's agent name. */
42
+ export declare const usePinnedAgentName: () => string;
43
+ export {};
@@ -0,0 +1,14 @@
1
+ import { ReactElement } from 'react';
2
+ import { Proactive } from '../../../api/proactive.ts';
3
+ import { PersonalAgent } from '../personal-agent.ts';
4
+ export declare const AgentProfileSheet: ({ proactive, name, brandName, agent, onClose, onClear, onOpenSession, onOpenScheduled, onConnect, }: {
5
+ readonly proactive: Proactive;
6
+ readonly name: string;
7
+ readonly brandName: string;
8
+ readonly agent: PersonalAgent | null;
9
+ readonly onClose: () => void;
10
+ readonly onClear: () => void;
11
+ readonly onOpenSession: (sessionId: string) => void;
12
+ readonly onOpenScheduled: () => void;
13
+ readonly onConnect: (() => void) | null;
14
+ }) => ReactElement;
@@ -0,0 +1,4 @@
1
+ import { ReactElement } from 'react';
2
+ export declare const ProfileAboutTab: ({ name }: {
3
+ readonly name: string;
4
+ }) => ReactElement;
@@ -0,0 +1,9 @@
1
+ import { ReactElement } from 'react';
2
+ import { Proactive } from '../../../api/proactive.ts';
3
+ export declare const ProfileActivityTab: ({ proactive, name, onBackToChat, onOpenSession, onOpenScheduled, }: {
4
+ readonly proactive: Proactive;
5
+ readonly name: string;
6
+ readonly onBackToChat: () => void;
7
+ readonly onOpenSession: (sessionId: string) => void;
8
+ readonly onOpenScheduled: () => void;
9
+ }) => ReactElement;
@@ -0,0 +1,8 @@
1
+ import { ReactElement } from 'react';
2
+ import { Proactive } from '../../../api/proactive.ts';
3
+ export declare const ProfileSourcesTab: ({ proactive, name, onConnect, }: {
4
+ readonly proactive: Proactive;
5
+ readonly name: string;
6
+ /** Null where this dock has no Connectors view to send them to. */
7
+ readonly onConnect: (() => void) | null;
8
+ }) => ReactElement;
@@ -0,0 +1,52 @@
1
+ import { Proactive } from '../../../api/proactive.ts';
2
+ import { TaskScheduleListItem, TaskScheduleRun } from '../../../api/task-schedules.ts';
3
+ export type ActivityItem = {
4
+ readonly kind: "chat_waiting";
5
+ readonly unreadCount: number;
6
+ readonly lastMessage: string | null;
7
+ } | {
8
+ readonly kind: "run_waiting";
9
+ readonly taskScheduleId: string;
10
+ readonly title: string;
11
+ readonly sessionId: string | null;
12
+ } | {
13
+ readonly kind: "check_running";
14
+ } | {
15
+ readonly kind: "chat_running";
16
+ } | {
17
+ readonly kind: "run_running";
18
+ readonly taskScheduleId: string;
19
+ readonly title: string;
20
+ } | {
21
+ readonly kind: "next_check";
22
+ readonly at: string;
23
+ } | {
24
+ readonly kind: "run_next";
25
+ readonly taskScheduleId: string;
26
+ readonly title: string;
27
+ readonly at: string;
28
+ } | {
29
+ readonly kind: "check_done";
30
+ readonly at: string;
31
+ } | {
32
+ readonly kind: "run_done";
33
+ readonly taskScheduleId: string;
34
+ readonly title: string;
35
+ readonly at: string;
36
+ readonly outcome: "completed" | "not_finished";
37
+ };
38
+ export type ProfileActivity = {
39
+ readonly waiting: readonly ActivityItem[];
40
+ readonly inProgress: readonly ActivityItem[];
41
+ readonly comingUp: readonly ActivityItem[];
42
+ readonly doneToday: readonly ActivityItem[];
43
+ };
44
+ /** The schedules whose newest run says "running": it may really be waiting on the user. */
45
+ export declare const runningScheduleIds: (schedules: readonly TaskScheduleListItem[]) => readonly string[];
46
+ export declare const profileActivity: (input: {
47
+ readonly proactive: Proactive;
48
+ readonly schedules: readonly TaskScheduleListItem[];
49
+ /** What `runningScheduleIds` came back with. */
50
+ readonly latestRuns: ReadonlyMap<string, TaskScheduleRun>;
51
+ readonly now: Date;
52
+ }) => ProfileActivity;
@@ -0,0 +1,2 @@
1
+ /** What the dock calls the agent: "Belong agent", or the tenant's own brand as is. */
2
+ export declare const useAgentName: () => string;
@@ -36,6 +36,20 @@ export declare const DeleteFolderDialog: (props: {
36
36
  readonly busy: boolean;
37
37
  readonly onConfirm: () => void;
38
38
  }) => import("react").JSX.Element;
39
+ /**
40
+ * #851 — confirm pausing every task in a folder and its subfolders. `count`
41
+ * is every task there, paused or finished ones included, so the copy says
42
+ * "tasks in this folder" and never promises how many will change. It stays
43
+ * open while the pause runs; `busy` disables confirming again.
44
+ */
45
+ export declare const PauseFolderDialog: (props: {
46
+ readonly open: boolean;
47
+ readonly onOpenChange: (open: boolean) => void;
48
+ readonly folderName: string;
49
+ readonly count: number;
50
+ readonly busy: boolean;
51
+ readonly onConfirm: () => void;
52
+ }) => import("react").JSX.Element;
39
53
  type MoveDialogProps = {
40
54
  readonly open: boolean;
41
55
  readonly onOpenChange: (open: boolean) => void;
@@ -5,7 +5,8 @@ type TreeRowProps = {
5
5
  readonly expanded: ReadonlySet<string>;
6
6
  readonly onToggle: (id: string) => void;
7
7
  readonly renderTask: (item: TaskScheduleListItem) => ReactNode;
8
- readonly onNotice: (notice: string) => void;
8
+ /** `undoIds`: tasks an Undo beside the notice resumes (a folder pause's). */
9
+ readonly onNotice: (notice: string, undoIds?: readonly string[]) => void;
9
10
  };
10
11
  export declare const ProjectRow: (props: TreeRowProps & {
11
12
  readonly node: ProjectTreeNode;
@@ -8,4 +8,11 @@
8
8
  * Delete in place. Internal UUIDs never appear in copy (they live only in the
9
9
  * memory-router path).
10
10
  */
11
+ /**
12
+ * #851 — how long a folder pause's Undo stays offered. The dock has no other
13
+ * Undo to match, so this is a short, fixed window: later, another editor may
14
+ * have paused one of those tasks again on purpose, and the server would
15
+ * resume it regardless. The notice's text stays; only the Undo goes.
16
+ */
17
+ export declare const UNDO_WINDOW_MS = 30000;
11
18
  export declare const ScheduledListSurface: () => import("react").JSX.Element;
@@ -1,4 +1,3 @@
1
- import { PostMessageError } from '../stream/belong-chat-transport.ts';
2
1
  export type GoalRefusal = {
3
2
  readonly kind: "exists";
4
3
  } | {
@@ -26,11 +25,3 @@ export type GoalRefusal = {
26
25
  * chat's own generic error surface instead of being misread as a refusal.
27
26
  */
28
27
  export declare const goalRefusalFromError: (error: unknown) => GoalRefusal | null;
29
- /**
30
- * A refused POST, whatever the reason. `PostMessageError.message` embeds the
31
- * server's status AND its raw body (a wire enum, untranslated English prose,
32
- * or a Zod issue list) — never show that to a user: the dock renders its own
33
- * i18n'd fallback instead. The memory note "server prose isn't localized" is
34
- * exactly this failure, and §42's "reads as breakage" is the cost.
35
- */
36
- export declare const isPostMessageRefusal: (error: unknown) => error is PostMessageError;
@@ -0,0 +1,52 @@
1
+ /**
2
+ * Which Session is the user's pinned chat (BEL-348).
3
+ *
4
+ * A tiny external store because places that don't share props need it: BelongDock
5
+ * (header, presentation) and ChatRoute (it must never be adopted as "Agent 1",
6
+ * which it isn't, and its quiet check replies aren't rendered).
7
+ *
8
+ * Remembered across reloads: ChatRoute binds what's on screen to line 1 in the
9
+ * dock's first commit, before the dock has read anything, and binding the pinned
10
+ * chat would take that line from the user's regular chat. An id left by another
11
+ * account on this browser is harmless: it never matches a Session of theirs.
12
+ */
13
+ export declare const peekPinnedChatSessionId: () => string | null;
14
+ export declare const setPinnedChatSessionId: (sessionId: string | null) => void;
15
+ export declare const usePinnedChatSessionId: () => string | null;
16
+ /**
17
+ * An email from the personal agent links back with `?belongView=pinned` (the
18
+ * cloud's `pinnedChatDeepLinkUrl`). Stripped once acted on, so a reload doesn't pull
19
+ * the user back to it, and any other query is the host's and stays untouched.
20
+ */
21
+ export declare const consumePinnedChatLink: (location: {
22
+ readonly search: string;
23
+ readonly replaceSearch: (next: string) => void;
24
+ }) => boolean;
25
+ /** Whether this page was opened from that link, without acting on it. */
26
+ export declare const hasPinnedChatLink: (search: string) => boolean;
27
+ /**
28
+ * How long that link waits for the host to name the Workspace. The link has none
29
+ * in it, and its arrival resets the dock to a new chat, but a host may never name
30
+ * one: the link only stays worth clicking if the chat opens anyway.
31
+ */
32
+ export declare const PINNED_LINK_WORKSPACE_WAIT_MS = 10000;
33
+ type MessageLike = {
34
+ readonly role: string;
35
+ readonly parts: readonly {
36
+ readonly type: string;
37
+ readonly text?: unknown;
38
+ }[];
39
+ };
40
+ /**
41
+ * A quiet check reply. A reply to the user's own message never is, whatever it
42
+ * says: "NO" can be the answer they asked for. The check's own message is internal,
43
+ * so a check's reply never follows one of theirs. A prefix ("NO", "NO_UP"…) counts
44
+ * only while it streams in; the cloud stores the real thing internal, so this keeps
45
+ * the live render the same as the reload (§41). It's the last thing it wrote that
46
+ * counts, since an agent narrates between tool calls.
47
+ */
48
+ export declare const isQuietPinnedMessage: (message: MessageLike, context: {
49
+ readonly previousRole: string | undefined;
50
+ readonly streaming: boolean;
51
+ }) => boolean;
52
+ export {};
@@ -55,4 +55,4 @@ export type WatchLineRunInput = {
55
55
  */
56
56
  readonly onTick?: () => void;
57
57
  };
58
- export declare const watchLineRun: (input: WatchLineRunInput, fetchFn?: typeof fetch) => (() => void);
58
+ export declare const watchLineRun: (input: WatchLineRunInput, fetchFn?: typeof fetch, sleepMs?: (ms: number, signal: AbortSignal) => Promise<void>) => (() => void);
@@ -195,6 +195,12 @@ export declare const notifyCallProgress: (hint: string) => void;
195
195
  /** ChatRoute mirrors the run's current tool phase — the orb wears it as a
196
196
  * small work badge while the agent is busy. */
197
197
  export declare const setCallWorkPhase: (phase: CallState["workPhase"]) => void;
198
+ /**
199
+ * Clear a chat's visible history and refresh it if it's the one on screen. For
200
+ * what isn't ChatRoute and can't call `runClearCommand`: a call, the pinned chat's
201
+ * header. False when the server refused; nothing changed then.
202
+ */
203
+ export declare const clearChatOnScreen: (sessionId: string) => Promise<boolean>;
198
204
  /**
199
205
  * The lines strip chip on CallScreen calls this directly (no tool-call round
200
206
  * trip, no ack — there is no voice tool for it any more, which is why nothing