@opengeni/react 7.6.1 → 7.7.0-canary.37090756480001

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 (142) hide show
  1. package/README.md +19 -2
  2. package/dist/{browser-viewer-5X47I6T2.js → browser-viewer-63TXMINB.js} +6 -5
  3. package/dist/{chunk-UINDK6C3.js → chunk-2QUSQVF2.js} +3 -3
  4. package/dist/{chunk-CHPKSLPN.js → chunk-6ZSWSH4I.js} +3 -1
  5. package/dist/chunk-6ZSWSH4I.js.map +1 -0
  6. package/dist/{chunk-KGENSZKS.js → chunk-AAG4R3QN.js} +4 -3
  7. package/dist/chunk-AAG4R3QN.js.map +1 -0
  8. package/dist/{chunk-Z3DISEQN.js → chunk-CWWKTNKK.js} +35 -18
  9. package/dist/chunk-CWWKTNKK.js.map +1 -0
  10. package/dist/{chunk-5EXGU7UF.js → chunk-DOJWJQ3F.js} +3 -3
  11. package/dist/{chunk-WZ55DVGK.js → chunk-ELCE5SXV.js} +8 -4
  12. package/dist/chunk-ELCE5SXV.js.map +1 -0
  13. package/dist/{chunk-YSMMDOOE.js → chunk-GISEVGS6.js} +10 -2
  14. package/dist/chunk-GISEVGS6.js.map +1 -0
  15. package/dist/{chunk-YRYF2GLG.js → chunk-HNFCAQ5R.js} +39 -31
  16. package/dist/chunk-HNFCAQ5R.js.map +1 -0
  17. package/dist/{chunk-BI57CQUV.js → chunk-I7IWRQLN.js} +2 -2
  18. package/dist/{chunk-XA6R7DJQ.js → chunk-IQUCRAT7.js} +3 -3
  19. package/dist/{chunk-DV2DBNPQ.js → chunk-Q5QBEZIQ.js} +48 -29
  20. package/dist/chunk-Q5QBEZIQ.js.map +1 -0
  21. package/dist/{chunk-FGBCYQOT.js → chunk-RDKBXMWX.js} +120 -74
  22. package/dist/chunk-RDKBXMWX.js.map +1 -0
  23. package/dist/{chunk-45GE35O7.js → chunk-TKB4SB44.js} +10 -2
  24. package/dist/chunk-TKB4SB44.js.map +1 -0
  25. package/dist/{chunk-YCGBREUV.js → chunk-TOAH2BKA.js} +6 -2
  26. package/dist/{chunk-YCGBREUV.js.map → chunk-TOAH2BKA.js.map} +1 -1
  27. package/dist/chunk-UGLEYEMP.js +33 -0
  28. package/dist/chunk-UGLEYEMP.js.map +1 -0
  29. package/dist/{chunk-UJRYEWZI.js → chunk-UTRTG6LH.js} +48 -8
  30. package/dist/chunk-UTRTG6LH.js.map +1 -0
  31. package/dist/{chunk-VGIKFIO2.js → chunk-XOAMRDDK.js} +6 -3
  32. package/dist/chunk-XOAMRDDK.js.map +1 -0
  33. package/dist/{chunk-6NEZPF53.js → chunk-YN7I3STW.js} +153 -32
  34. package/dist/chunk-YN7I3STW.js.map +1 -0
  35. package/dist/{chunk-KZ73RL76.js → chunk-YQEAA6LT.js} +7 -3
  36. package/dist/chunk-YQEAA6LT.js.map +1 -0
  37. package/dist/{chunk-LZ3KHA55.js → chunk-ZYALTAEQ.js} +329 -339
  38. package/dist/chunk-ZYALTAEQ.js.map +1 -0
  39. package/dist/client.d.ts +4 -1
  40. package/dist/commands/types.d.ts +2 -0
  41. package/dist/components/approval-surface.d.ts +15 -0
  42. package/dist/composer.js +8 -7
  43. package/dist/{computer-viewer-7GF35SNY.js → computer-viewer-X2MBRZY4.js} +5 -4
  44. package/dist/connect.js +3 -3
  45. package/dist/hooks/use-browser-session.d.ts +4 -0
  46. package/dist/hooks/use-composer.d.ts +2 -0
  47. package/dist/hooks/use-computer-session.d.ts +2 -0
  48. package/dist/hooks/use-file-attachments.d.ts +2 -0
  49. package/dist/hooks/use-session-events.d.ts +1 -1
  50. package/dist/hooks/use-workspace-sessions.d.ts +15 -5
  51. package/dist/index.d.ts +2 -2
  52. package/dist/index.js +28 -21
  53. package/dist/index.js.map +1 -1
  54. package/dist/interaction.d.ts +1 -1
  55. package/dist/interaction.js +6 -5
  56. package/dist/interaction.js.map +1 -1
  57. package/dist/{latest-question-3BJGKQQ6.js → latest-question-CNEZ5KAN.js} +3 -3
  58. package/dist/lib/error-message.d.ts +7 -0
  59. package/dist/lib/format.d.ts +27 -3
  60. package/dist/lib/interaction-errors.d.ts +3 -0
  61. package/dist/machines.js +5 -4
  62. package/dist/{model-policy-picker-menu-PUTA5JOB.js → model-policy-picker-menu-JSA64TNN.js} +4 -4
  63. package/dist/model-policy.js +1 -1
  64. package/dist/provider.d.ts +5 -1
  65. package/dist/{queue-surface-implementation-2CAQAIHM.js → queue-surface-implementation-HENWYFWA.js} +3 -2
  66. package/dist/{queue-surface-implementation-2CAQAIHM.js.map → queue-surface-implementation-HENWYFWA.js.map} +1 -1
  67. package/dist/realtime.js +2 -2
  68. package/dist/{sandbox-files-AEJTWGT4.js → sandbox-files-BBC47SLD.js} +4 -3
  69. package/dist/session-ui.d.ts +1 -1
  70. package/dist/session-ui.js +13 -12
  71. package/dist/session-ui.js.map +1 -1
  72. package/dist/session.js +7 -6
  73. package/dist/usage.js +2 -1
  74. package/dist/usage.js.map +1 -1
  75. package/package.json +3 -3
  76. package/src/client.ts +5 -1
  77. package/src/commands/registry.ts +18 -15
  78. package/src/commands/types.ts +2 -0
  79. package/src/components/approval-surface.tsx +166 -42
  80. package/src/components/browser-viewer.tsx +38 -9
  81. package/src/components/composer.tsx +9 -2
  82. package/src/components/computer-viewer.tsx +160 -30
  83. package/src/components/generated-video-player.tsx +4 -2
  84. package/src/components/human-input-form.tsx +18 -5
  85. package/src/components/message-timeline.tsx +120 -168
  86. package/src/components/open-geni-chat.tsx +11 -4
  87. package/src/components/queue-surface-state.tsx +3 -1
  88. package/src/components/session-chrome.tsx +5 -2
  89. package/src/components/session-commands-panel.tsx +3 -1
  90. package/src/components/session-conversation.tsx +4 -2
  91. package/src/components/session-list.tsx +7 -5
  92. package/src/components/session-mcp-capability-card.tsx +11 -1
  93. package/src/hooks/internal.ts +3 -2
  94. package/src/hooks/use-browser-session.ts +115 -79
  95. package/src/hooks/use-composer.ts +70 -31
  96. package/src/hooks/use-computer-session.ts +57 -6
  97. package/src/hooks/use-file-attachments.ts +16 -3
  98. package/src/hooks/use-goal.ts +2 -1
  99. package/src/hooks/use-session-capabilities.ts +3 -2
  100. package/src/hooks/use-session-events.ts +15 -8
  101. package/src/hooks/use-slash-commands.ts +6 -11
  102. package/src/hooks/use-turn-queue.ts +2 -1
  103. package/src/hooks/use-workspace-sessions.ts +40 -7
  104. package/src/index.ts +7 -2
  105. package/src/interaction.ts +1 -0
  106. package/src/lib/error-message.ts +37 -0
  107. package/src/lib/format.ts +73 -9
  108. package/src/lib/interaction-errors.ts +15 -0
  109. package/src/model-policy.ts +5 -0
  110. package/src/provider.tsx +12 -4
  111. package/src/session-ui.ts +1 -1
  112. package/src/timeline/projection.ts +12 -1
  113. package/styles/compiled.css +14 -30
  114. package/dist/chunk-45GE35O7.js.map +0 -1
  115. package/dist/chunk-6NEZPF53.js.map +0 -1
  116. package/dist/chunk-CHPKSLPN.js.map +0 -1
  117. package/dist/chunk-DV2DBNPQ.js.map +0 -1
  118. package/dist/chunk-FGBCYQOT.js.map +0 -1
  119. package/dist/chunk-KGENSZKS.js.map +0 -1
  120. package/dist/chunk-KZ73RL76.js.map +0 -1
  121. package/dist/chunk-LZ3KHA55.js.map +0 -1
  122. package/dist/chunk-UJRYEWZI.js.map +0 -1
  123. package/dist/chunk-VGIKFIO2.js.map +0 -1
  124. package/dist/chunk-WZ55DVGK.js.map +0 -1
  125. package/dist/chunk-YRYF2GLG.js.map +0 -1
  126. package/dist/chunk-YSMMDOOE.js.map +0 -1
  127. package/dist/chunk-Z3DISEQN.js.map +0 -1
  128. package/dist/components/timeline-pill-geometry.d.ts +0 -8
  129. package/dist/components/timeline-pill-placement.d.ts +0 -24
  130. package/dist/timeline-pill-geometry-Z23V243M.js +0 -110
  131. package/dist/timeline-pill-geometry-Z23V243M.js.map +0 -1
  132. package/src/components/timeline-pill-geometry.ts +0 -169
  133. package/src/components/timeline-pill-placement.ts +0 -99
  134. /package/dist/{browser-viewer-5X47I6T2.js.map → browser-viewer-63TXMINB.js.map} +0 -0
  135. /package/dist/{chunk-UINDK6C3.js.map → chunk-2QUSQVF2.js.map} +0 -0
  136. /package/dist/{chunk-5EXGU7UF.js.map → chunk-DOJWJQ3F.js.map} +0 -0
  137. /package/dist/{chunk-BI57CQUV.js.map → chunk-I7IWRQLN.js.map} +0 -0
  138. /package/dist/{chunk-XA6R7DJQ.js.map → chunk-IQUCRAT7.js.map} +0 -0
  139. /package/dist/{computer-viewer-7GF35SNY.js.map → computer-viewer-X2MBRZY4.js.map} +0 -0
  140. /package/dist/{latest-question-3BJGKQQ6.js.map → latest-question-CNEZ5KAN.js.map} +0 -0
  141. /package/dist/{model-policy-picker-menu-PUTA5JOB.js.map → model-policy-picker-menu-JSA64TNN.js.map} +0 -0
  142. /package/dist/{sandbox-files-AEJTWGT4.js.map → sandbox-files-BBC47SLD.js.map} +0 -0
package/dist/client.d.ts CHANGED
@@ -4,7 +4,9 @@ import type { OpenGeniClient } from "@opengeni/sdk";
4
4
  * pass the real SDK client, a proxy-backed client that routes through their
5
5
  * own API, or a scripted client in tests/demos.
6
6
  */
7
- export type SessionClientLike = Pick<OpenGeniClient, "getClientConfig" | "getSession" | "getSessionLineage" | "updateSession" | "updateSessionPin" | "listSessions" | "listSessionPage" | "sendMessage" | "steerMessage" | "pauseSession" | "resumeSession" | "sendApprovalDecision" | "listHumanInputRequests" | "getHumanInputRequest" | "submitHumanInputResponse" | "listEvents" | "streamEvents" | "getQueue" | "moveQueueItem" | "editQueueItem" | "steerQueueItem" | "deleteQueueItem" | "getComposerDraft" | "saveComposerDraft" | "submitComposerDraft" | "listTurns" | "getGoal" | "updateGoal" | "deleteGoal" | "clearSessionContext" | "compactSessionContext" | "listScheduledTasks" | "uploadFile" | "getFile" | "createFileDownloadUrl" | "listVariableSets" | "getVariableSetVariable" | "createVariableSet" | "updateVariableSet" | "deleteVariableSet" | "setVariableSetVariable" | "deleteVariableSetVariable" | "listEnvironments" | "createEnvironment" | "updateEnvironment" | "deleteEnvironment" | "setEnvironmentVariable" | "deleteEnvironmentVariable" | "listChannels" | "createChannel" | "updateChannel" | "reorderChannels" | "deleteChannel" | "updateSessionChannel" | "listRigs" | "createRig" | "getRig" | "updateRig" | "deleteRig" | "listRigVersions" | "activateRigVersion" | "listRigChanges" | "proposeRigChange" | "getRigChange" | "verifyRigChange" | "promoteRigChange" | "verifyRig" | "listWorkspaces" | "createWorkspace" | "updateWorkspace" | "setWorkspaceInferenceState" | "getWorkspace" | "getWorkspaceModelCatalog" | "listWorkspaceControlEvents" | "streamWorkspaceControlEvents" | "streamWorkspaceInteractionRevisions" | "getBillingUsage" | "getClientConfig" | "getStreamCapabilities" | "acknowledgeStream" | "attachViewer" | "heartbeatViewer" | "detachViewer" | "listNetworkRoutes" | "getNetworkRoute" | "createNetworkRoute" | "updateNetworkRoute" | "listSiteAuthConnections" | "getSiteAuthConnection" | "createSiteAuthConnection" | "updateSiteAuthConnection" | "listAuthRuns" | "getAuthRun" | "startBrowserAuthRun" | "reportBrowserAuthRun" | "protectedBrowserAuthFill" | "verifyBrowserAuthRun" | "listInteractionInterventions" | "getInteractionIntervention" | "createInteractionIntervention" | "resolveInteractionIntervention" | "listAttachedBrowsers" | "getAttachedBrowser" | "listBrowserIdentities" | "getBrowserIdentity" | "createBrowserIdentity" | "updateBrowserIdentity" | "listBrowserRevisions" | "listBrowserSessions" | "getBrowserSession" | "readBrowserClipboard" | "listBrowserDownloads" | "getBrowserDownload" | "saveBrowserDownload" | "createBrowserSession" | "listBrowserTargets" | "openBrowserTarget" | "selectBrowserTarget" | "closeBrowserTarget" | "observeBrowserTarget" | "actInBrowser" | "getBrowserActionReceipt" | "listBrowserDiagnostics" | "attachBrowserSession" | "heartbeatBrowserSession" | "publishBrowserRevision" | "suspendBrowserSession" | "resumeBrowserSession" | "endBrowserSession" | "listComputerSessions" | "getComputerSession" | "readComputerClipboard" | "createComputerSession" | "listComputerTargets" | "observeComputerTarget" | "actInComputer" | "getComputerActionReceipt" | "attachComputerSession" | "heartbeatComputerSession" | "endComputerSession" | "fsList" | "fsListBatch" | "fsRead" | "fsWrite" | "fsDelete" | "fsMove" | "fsMkdir" | "gitStatus" | "gitDiff" | "gitReadBatch" | "getWorkspaceCapture" | "getWorkspaceCaptureFile" | "terminalExec" | "terminalPtyOpen" | "terminalPtyWrite" | "terminalPtyResize" | "terminalPtyClose"> & Partial<Pick<OpenGeniClient, "createVideoArtifactPlaybackSource" | "streamWorkspaceLiveEvents" | "listSessionBackgroundCommands" | "cancelSessionBackgroundCommand">>;
7
+ type SessionClientMethods = Pick<OpenGeniClient, "getClientConfig" | "getSession" | "getSessionLineage" | "updateSession" | "updateSessionPin" | "listSessions" | "listSessionPage" | "sendMessage" | "steerMessage" | "pauseSession" | "resumeSession" | "sendApprovalDecision" | "listHumanInputRequests" | "getHumanInputRequest" | "submitHumanInputResponse" | "listEvents" | "streamEvents" | "getQueue" | "moveQueueItem" | "editQueueItem" | "steerQueueItem" | "deleteQueueItem" | "getComposerDraft" | "saveComposerDraft" | "submitComposerDraft" | "listTurns" | "getGoal" | "updateGoal" | "deleteGoal" | "clearSessionContext" | "compactSessionContext" | "listScheduledTasks" | "uploadFile" | "getFile" | "createFileDownloadUrl" | "listVariableSets" | "getVariableSetVariable" | "createVariableSet" | "updateVariableSet" | "deleteVariableSet" | "setVariableSetVariable" | "deleteVariableSetVariable" | "listEnvironments" | "createEnvironment" | "updateEnvironment" | "deleteEnvironment" | "setEnvironmentVariable" | "deleteEnvironmentVariable" | "listChannels" | "createChannel" | "updateChannel" | "reorderChannels" | "deleteChannel" | "updateSessionChannel" | "listRigs" | "createRig" | "getRig" | "updateRig" | "deleteRig" | "listRigVersions" | "activateRigVersion" | "listRigChanges" | "proposeRigChange" | "getRigChange" | "verifyRigChange" | "promoteRigChange" | "verifyRig" | "listWorkspaces" | "createWorkspace" | "updateWorkspace" | "setWorkspaceInferenceState" | "getWorkspace" | "getWorkspaceModelCatalog" | "listWorkspaceControlEvents" | "streamWorkspaceControlEvents" | "streamWorkspaceInteractionRevisions" | "getBillingUsage" | "getClientConfig" | "getStreamCapabilities" | "acknowledgeStream" | "attachViewer" | "heartbeatViewer" | "detachViewer" | "listNetworkRoutes" | "getNetworkRoute" | "createNetworkRoute" | "updateNetworkRoute" | "listSiteAuthConnections" | "getSiteAuthConnection" | "createSiteAuthConnection" | "updateSiteAuthConnection" | "listAuthRuns" | "getAuthRun" | "startBrowserAuthRun" | "reportBrowserAuthRun" | "protectedBrowserAuthFill" | "verifyBrowserAuthRun" | "listInteractionInterventions" | "getInteractionIntervention" | "createInteractionIntervention" | "resolveInteractionIntervention" | "listAttachedBrowsers" | "getAttachedBrowser" | "listBrowserIdentities" | "getBrowserIdentity" | "createBrowserIdentity" | "updateBrowserIdentity" | "listBrowserRevisions" | "listBrowserSessions" | "getBrowserSession" | "readBrowserClipboard" | "listBrowserDownloads" | "getBrowserDownload" | "saveBrowserDownload" | "createBrowserSession" | "listBrowserTargets" | "openBrowserTarget" | "selectBrowserTarget" | "closeBrowserTarget" | "observeBrowserTarget" | "actInBrowser" | "getBrowserActionReceipt" | "listBrowserDiagnostics" | "attachBrowserSession" | "heartbeatBrowserSession" | "publishBrowserRevision" | "suspendBrowserSession" | "resumeBrowserSession" | "endBrowserSession" | "listComputerSessions" | "getComputerSession" | "readComputerClipboard" | "createComputerSession" | "listComputerTargets" | "observeComputerTarget" | "actInComputer" | "getComputerActionReceipt" | "attachComputerSession" | "heartbeatComputerSession" | "endComputerSession" | "fsList" | "fsListBatch" | "fsRead" | "fsWrite" | "fsDelete" | "fsMove" | "fsMkdir" | "gitStatus" | "gitDiff" | "gitReadBatch" | "getWorkspaceCapture" | "getWorkspaceCaptureFile" | "terminalExec" | "terminalPtyOpen" | "terminalPtyWrite" | "terminalPtyResize" | "terminalPtyClose"> & Partial<Pick<OpenGeniClient, "createVideoArtifactPlaybackSource" | "streamWorkspaceLiveEvents" | "listSessionBackgroundCommands" | "cancelSessionBackgroundCommand">>;
8
+ /** Compact list transport is optional for scripted and older clients. */
9
+ export type SessionClientLike = SessionClientMethods & Partial<Pick<OpenGeniClient, "listSessionSummaryPage">>;
8
10
  /**
9
11
  * Tenant-safe client surface required by the session-only React entry.
10
12
  *
@@ -41,3 +43,4 @@ export type EmbeddedBrowserInteractionClientLike = Pick<OpenGeniClient, "streamW
41
43
  export type EmbeddedComputerInteractionClientLike = Pick<OpenGeniClient, "streamWorkspaceInteractionRevisions" | "listComputerSessions" | "getComputerSession" | "readComputerClipboard" | "createComputerSession" | "listComputerTargets" | "observeComputerTarget" | "actInComputer" | "getComputerActionReceipt" | "attachComputerSession" | "heartbeatComputerSession" | "endComputerSession"> & EmbeddedInterventionClientLike;
42
44
  /** Complete public Browser + Computer interaction surface. */
43
45
  export type EmbeddedInteractionClientLike = EmbeddedBrowserInteractionClientLike & EmbeddedComputerInteractionClientLike;
46
+ export {};
@@ -40,6 +40,8 @@ export type CommandContext = {
40
40
  permissions: Permission[];
41
41
  /** Surface a transient ok/error notice in the composer. */
42
42
  notice: (notice: Notice) => void;
43
+ /** Optional presentation hook for native command failures; never rewrites command content. */
44
+ formatError?: ((error: unknown, defaultMessage: string) => string) | undefined;
43
45
  /** Open the in-composer /help panel (rendered from the registry). */
44
46
  openHelp: () => void;
45
47
  /**
@@ -2,12 +2,16 @@ import { type ReactNode } from "react";
2
2
  import type { PendingApproval } from "../approvals.js";
3
3
  export type ApprovalSurfaceMessages = {
4
4
  title: string;
5
+ /** Screen-reader context for the decision; not shown visually. */
5
6
  description: string;
6
7
  approve: string;
7
8
  reject: string;
8
9
  approving: string;
9
10
  rejecting: string;
10
11
  formatToolName: (name: string) => string;
12
+ /** Toggle for the exact arguments when they are shown as readable fields. */
13
+ showDetails?: string | undefined;
14
+ hideDetails?: string | undefined;
11
15
  };
12
16
  export declare const defaultApprovalSurfaceMessages: ApprovalSurfaceMessages;
13
17
  export type ApprovalSurfaceProps = {
@@ -20,6 +24,17 @@ export type ApprovalSurfaceProps = {
20
24
  renderApproval?: ((approval: PendingApproval) => ReactNode) | undefined;
21
25
  className?: string | undefined;
22
26
  };
27
+ export type ApprovalField = {
28
+ key: string;
29
+ label: string;
30
+ value: string;
31
+ };
32
+ /**
33
+ * Readable fields for a flat argument object (scalars and short scalar lists).
34
+ * Returns null when the arguments are nested, large, or not an object, so the
35
+ * caller shows the exact JSON instead of a lossy summary.
36
+ */
37
+ export declare function approvalArgumentFields(value: unknown): ApprovalField[] | null;
23
38
  /**
24
39
  * Host-neutral approval presentation backed by the native pending-approval
25
40
  * projection and control callbacks. It owns only presentation and duplicate
package/dist/composer.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  ModelPolicyPickerMenu
3
- } from "./chunk-5EXGU7UF.js";
3
+ } from "./chunk-DOJWJQ3F.js";
4
4
  import {
5
5
  Actions,
6
6
  AttachButton,
@@ -40,8 +40,8 @@ import {
40
40
  useChatComposer,
41
41
  useChatComposerController,
42
42
  useVoiceInput
43
- } from "./chunk-YRYF2GLG.js";
44
- import "./chunk-DV2DBNPQ.js";
43
+ } from "./chunk-HNFCAQ5R.js";
44
+ import "./chunk-Q5QBEZIQ.js";
45
45
  import "./chunk-BRM6FVZA.js";
46
46
  import {
47
47
  BillingClassMark,
@@ -50,12 +50,13 @@ import {
50
50
  PickerBackHeader,
51
51
  PickerNavRow,
52
52
  defaultModelPolicyPickerMessages
53
- } from "./chunk-UINDK6C3.js";
53
+ } from "./chunk-2QUSQVF2.js";
54
54
  import "./chunk-K3HQAKQX.js";
55
- import "./chunk-CHPKSLPN.js";
55
+ import "./chunk-6ZSWSH4I.js";
56
56
  import "./chunk-VZTQ73XT.js";
57
- import "./chunk-UJRYEWZI.js";
58
- import "./chunk-KZ73RL76.js";
57
+ import "./chunk-UTRTG6LH.js";
58
+ import "./chunk-YQEAA6LT.js";
59
+ import "./chunk-UGLEYEMP.js";
59
60
  import "./chunk-NEXLLTP4.js";
60
61
  import "./chunk-22KP6LR5.js";
61
62
  export {
@@ -1,13 +1,14 @@
1
1
  import {
2
2
  ComputerViewer,
3
3
  computerKey
4
- } from "./chunk-6NEZPF53.js";
5
- import "./chunk-YSMMDOOE.js";
4
+ } from "./chunk-YN7I3STW.js";
5
+ import "./chunk-GISEVGS6.js";
6
6
  import "./chunk-JVYQRRC4.js";
7
7
  import "./chunk-DYWBUX5Q.js";
8
8
  import "./chunk-RHREZ7BO.js";
9
9
  import "./chunk-5J4FOW6Q.js";
10
- import "./chunk-KZ73RL76.js";
10
+ import "./chunk-YQEAA6LT.js";
11
+ import "./chunk-UGLEYEMP.js";
11
12
  import "./chunk-NEXLLTP4.js";
12
13
  import "./chunk-JT4JW7BC.js";
13
14
  import "./chunk-22KP6LR5.js";
@@ -15,4 +16,4 @@ export {
15
16
  ComputerViewer,
16
17
  computerKey
17
18
  };
18
- //# sourceMappingURL=computer-viewer-7GF35SNY.js.map
19
+ //# sourceMappingURL=computer-viewer-X2MBRZY4.js.map
package/dist/connect.js CHANGED
@@ -3,10 +3,10 @@ import {
3
3
  McpConnectionCard,
4
4
  mcpConnectionDiscoveryState,
5
5
  useConnect
6
- } from "./chunk-45GE35O7.js";
6
+ } from "./chunk-TKB4SB44.js";
7
7
  import {
8
8
  Markdown
9
- } from "./chunk-BI57CQUV.js";
9
+ } from "./chunk-I7IWRQLN.js";
10
10
  import "./chunk-GIMRELBW.js";
11
11
  import "./chunk-447JLCBU.js";
12
12
  import "./chunk-XCHWDJ22.js";
@@ -15,7 +15,7 @@ import {
15
15
  } from "./chunk-JVYQRRC4.js";
16
16
  import "./chunk-BRM6FVZA.js";
17
17
  import "./chunk-VZTQ73XT.js";
18
- import "./chunk-UJRYEWZI.js";
18
+ import "./chunk-UTRTG6LH.js";
19
19
  import "./chunk-22KP6LR5.js";
20
20
 
21
21
  // src/capability-catalog-row.tsx
@@ -2,6 +2,9 @@ import type { BrowserAction, BrowserActionBatch, BrowserActionReceipt, BrowserCl
2
2
  import { type EmbeddedBrowserInteractionClientOverride } from "../session-context.js";
3
3
  /** Immutable input fence; queued actions never need the encoded screenshot. */
4
4
  export type BrowserFrameInputFence = Pick<BrowserFrame, "browserSessionId" | "controllerGeneration" | "targetId" | "targetGeneration" | "documentGeneration" | "frameId">;
5
+ export type BrowserInputFailure = Pick<BrowserActionReceipt, "operationId" | "error"> & {
6
+ state: Exclude<BrowserActionReceipt["state"], "completed">;
7
+ };
5
8
  export type UseBrowserSessionOptions = EmbeddedBrowserInteractionClientOverride & {
6
9
  browserSessionId: string | null;
7
10
  enabled?: boolean | undefined;
@@ -18,6 +21,7 @@ export type UseBrowserSessionResult = {
18
21
  loading: boolean;
19
22
  mutating: boolean;
20
23
  error: Error | null;
24
+ inputFailure: BrowserInputFailure | null;
21
25
  refresh: () => Promise<void>;
22
26
  observeForInput: () => Promise<BrowserObservation>;
23
27
  actFromObservation: (action: BrowserAction, observation: BrowserObservation) => Promise<BrowserActionReceipt>;
@@ -47,6 +47,8 @@ export type ComposerOptimisticMessage = {
47
47
  triggerEventId?: string | null | undefined;
48
48
  appliedQueueVersion?: number | null | undefined;
49
49
  error?: string | undefined;
50
+ /** Bounded support reference retained independently of display copy across remounts. */
51
+ correlationId?: string | undefined;
50
52
  /** False for a definitive refusal that requires changing payment or allowance settings. */
51
53
  retryable?: boolean | undefined;
52
54
  outcomeUnknown?: boolean | undefined;
@@ -13,6 +13,8 @@ export type UseComputerSessionResult = {
13
13
  loading: boolean;
14
14
  mutating: boolean;
15
15
  error: Error | null;
16
+ /** Control service loss, independent of target accessibility inspection and media. */
17
+ controlError: Error | null;
16
18
  refresh: () => Promise<void>;
17
19
  readClipboard: () => Promise<ComputerClipboard>;
18
20
  /** Changes only this viewer's target cursor; it never takes ownership or
@@ -25,6 +25,8 @@ export type FileAttachment = {
25
25
  /** Stable SDK failure code for UI behavior that must not parse error copy. */
26
26
  errorCode?: "secure_context_required" | undefined;
27
27
  error?: string | undefined;
28
+ /** Original diagnostic failure; presentation copy is kept separately in `error`. */
29
+ errorCause?: unknown;
28
30
  };
29
31
  export type UseFileAttachmentsResult = {
30
32
  attachments: FileAttachment[];
@@ -78,7 +78,7 @@ export type UseSessionEventsResult = {
78
78
  error: Error | null;
79
79
  };
80
80
  export declare const SESSION_EVENT_BROWSER_MAX_BYTES: number;
81
- export declare const SESSION_EVENT_BROWSER_MAX_COUNT = 200000;
81
+ export declare const SESSION_EVENT_BROWSER_MAX_COUNT = 20000;
82
82
  export declare const SESSION_EVENT_BROWSER_PENDING_MAX_BYTES: number;
83
83
  export declare const SESSION_EVENT_BROWSER_PENDING_MAX_COUNT = 256;
84
84
  export type BrowserSessionEventWindow = {
@@ -1,12 +1,16 @@
1
- import type { Session } from "@opengeni/sdk";
1
+ import type { Session, SessionListEntry } from "@opengeni/sdk";
2
2
  import { type ClientOverride } from "../provider.js";
3
3
  export type UseWorkspaceSessionsOptions = ClientOverride & {
4
+ /** Compact list records; detail reads remain full sessions. */
5
+ projection?: "summary" | undefined;
4
6
  limit?: number | undefined;
5
7
  parentSessionId?: string | null | undefined;
6
8
  cursor?: string | undefined;
7
9
  search?: string | undefined;
8
10
  /** Return only the complete personal pinned projection. */
9
11
  pinsOnly?: boolean | undefined;
12
+ /** Skip pinned details when the pinned section is loaded separately. */
13
+ includePinned?: boolean | undefined;
10
14
  archivedOnly?: boolean | undefined;
11
15
  sortBy?: "updatedAt" | "createdAt" | "name" | undefined;
12
16
  archiveStatus?: "active" | "archived" | "all" | undefined;
@@ -16,14 +20,14 @@ export type UseWorkspaceSessionsOptions = ClientOverride & {
16
20
  /** Optional shared causal clock invoked when each network read starts. */
17
21
  beginRead?: (() => number) | undefined;
18
22
  };
19
- export type UseWorkspaceSessionsResult = {
23
+ export type UseWorkspaceSessionsResult<T extends Session | SessionListEntry = Session> = {
20
24
  /**
21
25
  * All visible rows, with pins first. This preserves the pre-pinning hook
22
26
  * contract for consumers that only read `sessions`.
23
27
  */
24
- sessions: Session[];
28
+ sessions: T[];
25
29
  /** The complete personal pinned section, also present in `sessions`. */
26
- pinned: Session[];
30
+ pinned: T[];
27
31
  /** True when the server omitted older pins from its bounded pinned section. */
28
32
  pinnedTruncated: boolean;
29
33
  nextCursor: string | null;
@@ -36,4 +40,10 @@ export type UseWorkspaceSessionsResult = {
36
40
  refresh: () => Promise<void>;
37
41
  };
38
42
  /** List the workspace's sessions — the data behind fleet and manager views. */
39
- export declare function useWorkspaceSessions(options?: UseWorkspaceSessionsOptions): UseWorkspaceSessionsResult;
43
+ export declare function useWorkspaceSessions(options: UseWorkspaceSessionsOptions & {
44
+ projection: "summary";
45
+ }): UseWorkspaceSessionsResult<SessionListEntry>;
46
+ export declare function useWorkspaceSessions(options?: UseWorkspaceSessionsOptions & {
47
+ projection?: undefined;
48
+ }): UseWorkspaceSessionsResult;
49
+ export declare function useWorkspaceSessions(options: UseWorkspaceSessionsOptions): UseWorkspaceSessionsResult<Session | SessionListEntry>;
package/dist/index.d.ts CHANGED
@@ -6,7 +6,7 @@ export { attachSessionCapability, completeSessionCapabilityOAuth, } from "./sess
6
6
  export { retainedImageId } from "./components/markdown.js";
7
7
  export type { EmbeddedBrowserInteractionClientLike, EmbeddedComputerInteractionClientLike, EmbeddedFileAttachmentClientLike, EmbeddedGoalClientLike, EmbeddedHumanInputSessionClientLike, EmbeddedInteractionClientLike, EmbeddedSessionEventClientLike, EmbeddedSessionLineageClientLike, EmbeddedSessionMcpApprovalPolicyClientLike, EmbeddedSessionReadClientLike, EmbeddedSessionClientLike, SessionClientLike, } from "./client.js";
8
8
  export { OpenGeniProvider } from "./provider.js";
9
- export type { OpenGeniProviderProps } from "./provider.js";
9
+ export type { OpenGeniProviderProps, ErrorMessageFormatter } from "./provider.js";
10
10
  export { useOpenGeni, useOpenGeniClient } from "./session-context.js";
11
11
  export { useVideoArtifactPlaybackLoader } from "./hooks/use-video-artifact-playback.js";
12
12
  export type { ClientOverride, OpenGeniContextValue } from "./session-context.js";
@@ -27,7 +27,7 @@ export { VOICE_RECORDING_CLIENT_MAX_DURATION_SECONDS, VOICE_RECORDING_OWNER_HEAR
27
27
  export type { UseVoiceInputOptions, UseVoiceInputResult, VoiceInputStatus, } from "./hooks/use-voice-input.js";
28
28
  export { IndexedDbVoiceRecordingStore, VoiceRecordingChunkConflictError, VoiceRecordingChunkSequenceError, VoiceRecordingNotFoundError, VoiceRecordingOwnedError, VoiceRecordingStorageUnavailableError, createVoiceRecordingManifest, planVoiceRecordingChunkCommit, prepareVoiceRecordingChunk, } from "./voice-recording-store.js";
29
29
  export type { PersistVoiceRecordingChunkInput, PersistVoiceRecordingChunkResult, VoiceRecordingCaptureState, VoiceRecordingChunk, VoiceRecordingChunkUploadState, VoiceRecordingFinalizationState, VoiceRecordingHandoffMode, VoiceRecordingManifest, VoiceRecordingRecoveryMode, VoiceRecordingStore, VoiceRecordingTranscriptionState, VoiceRecordingUploadState, } from "./voice-recording-store.js";
30
- export { COMPOSER_PAYMENT_REQUIRED_MESSAGE, composerSubmissionErrorMessage } from "./lib/format.js";
30
+ export { COMPOSER_MODEL_UNAVAILABLE_MESSAGE, COMPOSER_PAYMENT_REQUIRED_MESSAGE, composerSubmissionErrorMessage, isModelUnavailableSubmissionError, } from "./lib/format.js";
31
31
  export { INITIAL_TRANSCRIPTION_CONTROL_STATE, appendFinalTranscript, transitionTranscriptionControl, useTranscription, } from "./hooks/use-transcription.js";
32
32
  export type { TranscriptionControlAction, TranscriptionControlState, TranscriptionControlTransition, UseTranscriptionOptions, UseTranscriptionResult, } from "./hooks/use-transcription.js";
33
33
  export { useFileAttachments } from "./hooks/use-file-attachments.js";
package/dist/index.js CHANGED
@@ -17,7 +17,7 @@ import {
17
17
  useGoal,
18
18
  useSessionLineage,
19
19
  useSessionMcpApprovalPolicy
20
- } from "./chunk-VGIKFIO2.js";
20
+ } from "./chunk-XOAMRDDK.js";
21
21
  import {
22
22
  CONNECTION_STATUS_META,
23
23
  ConnectionDot,
@@ -48,7 +48,7 @@ import {
48
48
  healthPulses,
49
49
  pointsFor,
50
50
  useMachines
51
- } from "./chunk-XA6R7DJQ.js";
51
+ } from "./chunk-IQUCRAT7.js";
52
52
  import {
53
53
  ActivityRail,
54
54
  ApprovalSurface,
@@ -107,11 +107,11 @@ import {
107
107
  useWorkspaceSessions,
108
108
  userMessageLikelyNeedsDisclosure,
109
109
  v4aToGitFileDiff
110
- } from "./chunk-LZ3KHA55.js";
110
+ } from "./chunk-ZYALTAEQ.js";
111
111
  import {
112
112
  useThemeType
113
113
  } from "./chunk-UK4TINKT.js";
114
- import "./chunk-YCGBREUV.js";
114
+ import "./chunk-TOAH2BKA.js";
115
115
  import "./chunk-5QHL6BLH.js";
116
116
  import "./chunk-ZYRGEKWS.js";
117
117
  import "./chunk-FZCP527Y.js";
@@ -140,27 +140,27 @@ import {
140
140
  useSessionControl,
141
141
  useSessionEvents,
142
142
  useTurnQueue
143
- } from "./chunk-Z3DISEQN.js";
143
+ } from "./chunk-CWWKTNKK.js";
144
144
  import {
145
145
  buildTimeline,
146
146
  creditExhaustedFromEvents,
147
147
  extractSessionRef,
148
148
  groupTimeline,
149
149
  sessionStatusFromEvents
150
- } from "./chunk-KGENSZKS.js";
150
+ } from "./chunk-AAG4R3QN.js";
151
151
  import {
152
152
  toolDisplayName
153
153
  } from "./chunk-ERGYJIBB.js";
154
154
  import {
155
155
  OpenGeniProvider
156
- } from "./chunk-WZ55DVGK.js";
156
+ } from "./chunk-ELCE5SXV.js";
157
157
  import {
158
158
  McpConnectionCard,
159
159
  SessionCapabilityFrame,
160
160
  SessionMcpCapabilityCard,
161
161
  attachSessionCapability,
162
162
  completeSessionCapabilityOAuth
163
- } from "./chunk-45GE35O7.js";
163
+ } from "./chunk-TKB4SB44.js";
164
164
  import {
165
165
  ActivityDisclosure,
166
166
  BodyNote,
@@ -177,7 +177,7 @@ import {
177
177
  retainedImageId,
178
178
  sandboxFileLocationFromHref,
179
179
  sandboxFilePathFromHref
180
- } from "./chunk-BI57CQUV.js";
180
+ } from "./chunk-I7IWRQLN.js";
181
181
  import "./chunk-GIMRELBW.js";
182
182
  import "./chunk-447JLCBU.js";
183
183
  import {
@@ -202,7 +202,7 @@ import {
202
202
  import "./chunk-RHREZ7BO.js";
203
203
  import {
204
204
  ModelPolicyPickerMenu
205
- } from "./chunk-5EXGU7UF.js";
205
+ } from "./chunk-DOJWJQ3F.js";
206
206
  import {
207
207
  CommandPalette,
208
208
  ComposerTranscriptionControl,
@@ -235,14 +235,14 @@ import {
235
235
  useSlashCommands,
236
236
  useTranscription,
237
237
  useVoiceInput
238
- } from "./chunk-YRYF2GLG.js";
238
+ } from "./chunk-HNFCAQ5R.js";
239
239
  import {
240
240
  FILE_ONLY_MESSAGE_TEXT,
241
241
  composeSendInput,
242
242
  shouldSteerOnKey,
243
243
  shouldSubmitOnKey,
244
244
  useComposer
245
- } from "./chunk-DV2DBNPQ.js";
245
+ } from "./chunk-Q5QBEZIQ.js";
246
246
  import {
247
247
  LightboxProvider,
248
248
  Tooltip,
@@ -261,7 +261,7 @@ import {
261
261
  PickerBackHeader,
262
262
  PickerNavRow,
263
263
  defaultModelPolicyPickerMessages
264
- } from "./chunk-UINDK6C3.js";
264
+ } from "./chunk-2QUSQVF2.js";
265
265
  import "./chunk-K3HQAKQX.js";
266
266
  import {
267
267
  advancedSourceSummary,
@@ -281,9 +281,10 @@ import {
281
281
  projectPickerRows,
282
282
  runnableLatencyModesForModel,
283
283
  sortPickerRows
284
- } from "./chunk-CHPKSLPN.js";
284
+ } from "./chunk-6ZSWSH4I.js";
285
285
  import "./chunk-VZTQ73XT.js";
286
286
  import {
287
+ COMPOSER_MODEL_UNAVAILABLE_MESSAGE,
287
288
  COMPOSER_PAYMENT_REQUIRED_MESSAGE,
288
289
  CREDIT_EXHAUSTION_MESSAGE,
289
290
  composerSubmissionErrorMessage,
@@ -292,11 +293,12 @@ import {
292
293
  formatRelativeTime,
293
294
  humanizeFailureReason,
294
295
  isCreditExhaustion,
296
+ isModelUnavailableSubmissionError,
295
297
  presentFailure,
296
298
  stringifyPayload,
297
299
  truncate,
298
300
  tryParseJson
299
- } from "./chunk-UJRYEWZI.js";
301
+ } from "./chunk-UTRTG6LH.js";
300
302
  import {
301
303
  SandboxTerminal,
302
304
  terminalCanAcquirePty,
@@ -313,7 +315,10 @@ import {
313
315
  usePageLiveActivity,
314
316
  usePolledValue,
315
317
  useSessionEventTrigger
316
- } from "./chunk-KZ73RL76.js";
318
+ } from "./chunk-YQEAA6LT.js";
319
+ import {
320
+ normalizeError
321
+ } from "./chunk-UGLEYEMP.js";
317
322
  import {
318
323
  useOpenGeni,
319
324
  useOpenGeniClient
@@ -1214,7 +1219,7 @@ function useSessionCapabilities(sessionId, options = {}) {
1214
1219
  return;
1215
1220
  }
1216
1221
  setState("error");
1217
- setError(cause instanceof Error ? cause : new Error(String(cause)));
1222
+ setError(normalizeError(cause));
1218
1223
  }
1219
1224
  });
1220
1225
  }, warmingPollMs);
@@ -1326,7 +1331,7 @@ function useSessionCapabilities(sessionId, options = {}) {
1326
1331
  return;
1327
1332
  }
1328
1333
  setState("error");
1329
- setError(cause instanceof Error ? cause : new Error(String(cause)));
1334
+ setError(normalizeError(cause));
1330
1335
  }
1331
1336
  })();
1332
1337
  return () => {
@@ -3741,7 +3746,7 @@ import {
3741
3746
  } from "lucide-react";
3742
3747
  import { jsx as jsx6, jsxs as jsxs5 } from "react/jsx-runtime";
3743
3748
  var LazySandboxFiles = lazy(
3744
- () => import("./sandbox-files-AEJTWGT4.js").then(({ SandboxFiles: SandboxFiles2 }) => ({ default: SandboxFiles2 })).catch(() => ({ default: FilesLoadFailed }))
3749
+ () => import("./sandbox-files-BBC47SLD.js").then(({ SandboxFiles: SandboxFiles2 }) => ({ default: SandboxFiles2 })).catch(() => ({ default: FilesLoadFailed }))
3745
3750
  );
3746
3751
  function FilesLoadFailed() {
3747
3752
  return /* @__PURE__ */ jsxs5(CenteredState, { tone: "danger", icon: /* @__PURE__ */ jsx6(TriangleAlertIcon, { className: "size-5", "aria-hidden": true }), children: [
@@ -3756,11 +3761,11 @@ function FilesTabBody(props) {
3756
3761
  return /* @__PURE__ */ jsx6(Suspense, { fallback: /* @__PURE__ */ jsx6(WorkbenchSurfaceLoading, { name: "Files" }), children: /* @__PURE__ */ jsx6(LazySandboxFiles, { ...props }) });
3757
3762
  }
3758
3763
  var LazyBrowserViewer = lazy(async () => {
3759
- const { BrowserViewer } = await import("./browser-viewer-5X47I6T2.js");
3764
+ const { BrowserViewer } = await import("./browser-viewer-63TXMINB.js");
3760
3765
  return { default: BrowserViewer };
3761
3766
  });
3762
3767
  var LazyComputerViewer = lazy(async () => {
3763
- const { ComputerViewer } = await import("./computer-viewer-7GF35SNY.js");
3768
+ const { ComputerViewer } = await import("./computer-viewer-X2MBRZY4.js");
3764
3769
  return { default: ComputerViewer };
3765
3770
  });
3766
3771
  var WORKBENCH_TAB_CHANGES = "changes";
@@ -4906,6 +4911,7 @@ export {
4906
4911
  BUILT_IN_TURN_SUMMARY_FACET_IDS,
4907
4912
  BillingClassMark,
4908
4913
  BodyNote,
4914
+ COMPOSER_MODEL_UNAVAILABLE_MESSAGE,
4909
4915
  COMPOSER_PAYMENT_REQUIRED_MESSAGE,
4910
4916
  CONNECTION_STATUS_META,
4911
4917
  CREDIT_EXHAUSTION_MESSAGE,
@@ -5087,6 +5093,7 @@ export {
5087
5093
  isHumanInputEvent,
5088
5094
  isLastStartedTurnPolicyEvent,
5089
5095
  isLineageRefreshEvent,
5096
+ isModelUnavailableSubmissionError,
5090
5097
  isSessionMcpApprovalPolicyEvent,
5091
5098
  isTitleEvent,
5092
5099
  isTurnQueueEvent,