@opengeni/react 7.1.0 → 7.1.2-canary.36199476632001

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 (78) hide show
  1. package/dist/artifacts-document.js +2 -2
  2. package/dist/artifacts-presentation.js +2 -2
  3. package/dist/artifacts-spreadsheet.js +2 -2
  4. package/dist/artifacts.js +4 -4
  5. package/dist/{browser-viewer-MN7MOYQT.js → browser-viewer-K2H3SLIW.js} +2 -2
  6. package/dist/{chunk-KCGXPP5V.js → chunk-6P7T4RPE.js} +7 -3
  7. package/dist/chunk-6P7T4RPE.js.map +1 -0
  8. package/dist/{chunk-SHRCATV6.js → chunk-7J4DUR3E.js} +12 -5
  9. package/dist/chunk-7J4DUR3E.js.map +1 -0
  10. package/dist/{chunk-UQS7BGNQ.js → chunk-ETA37UZ7.js} +82 -11
  11. package/dist/chunk-ETA37UZ7.js.map +1 -0
  12. package/dist/{chunk-VR4Z73EU.js → chunk-G2SCXNXW.js} +9 -2
  13. package/dist/chunk-G2SCXNXW.js.map +1 -0
  14. package/dist/{chunk-5UONOQ3Y.js → chunk-K3MQZO7R.js} +150 -67
  15. package/dist/chunk-K3MQZO7R.js.map +1 -0
  16. package/dist/{chunk-OWHPKAOV.js → chunk-L6MYP3QU.js} +4 -2
  17. package/dist/{chunk-OWHPKAOV.js.map → chunk-L6MYP3QU.js.map} +1 -1
  18. package/dist/{chunk-ZC2DK5SC.js → chunk-RSFCYKA7.js} +88 -7
  19. package/dist/chunk-RSFCYKA7.js.map +1 -0
  20. package/dist/{chunk-VI7HELBI.js → chunk-SJ5HE4ZA.js} +21 -2
  21. package/dist/chunk-SJ5HE4ZA.js.map +1 -0
  22. package/dist/{chunk-4ACTWOOW.js → chunk-VDSZ3AVO.js} +41 -18
  23. package/dist/chunk-VDSZ3AVO.js.map +1 -0
  24. package/dist/{chunk-XMXRI5JK.js → chunk-ZZ4744OZ.js} +128 -71
  25. package/dist/chunk-ZZ4744OZ.js.map +1 -0
  26. package/dist/components/artifacts/artifact-surface.d.ts +3 -1
  27. package/dist/components/artifacts/document-editor.d.ts +4 -2
  28. package/dist/components/artifacts/editable-document.d.ts +1 -1
  29. package/dist/components/artifacts/editable-presentation.d.ts +1 -1
  30. package/dist/components/artifacts/editable-spreadsheet.d.ts +2 -1
  31. package/dist/components/artifacts/presentation-editor.d.ts +4 -2
  32. package/dist/components/browser-viewer.d.ts +4 -1
  33. package/dist/components/markdown.d.ts +2 -0
  34. package/dist/components/session-capability-frame.d.ts +5 -1
  35. package/dist/composer.js +1 -1
  36. package/dist/connect.js +2 -2
  37. package/dist/hooks/use-browser-session.d.ts +3 -0
  38. package/dist/index.js +7 -6
  39. package/dist/index.js.map +1 -1
  40. package/dist/interaction.js +1 -1
  41. package/dist/session-ui.js +4 -4
  42. package/dist/session.js +1 -1
  43. package/dist/timeline/types.d.ts +2 -0
  44. package/package.json +5 -5
  45. package/src/components/artifacts/artifact-surface.tsx +39 -19
  46. package/src/components/artifacts/document-editor.tsx +77 -9
  47. package/src/components/artifacts/editable-document.tsx +3 -0
  48. package/src/components/artifacts/editable-presentation.tsx +3 -0
  49. package/src/components/artifacts/editable-spreadsheet.tsx +3 -0
  50. package/src/components/artifacts/presentation-editor.tsx +6 -0
  51. package/src/components/browser-viewer.tsx +11 -5
  52. package/src/components/composer-transcription-control.tsx +4 -2
  53. package/src/components/composer.tsx +45 -20
  54. package/src/components/markdown.tsx +9 -2
  55. package/src/components/sandbox-workspace.tsx +1 -0
  56. package/src/components/session-capability-frame.tsx +11 -3
  57. package/src/components/session-mcp-capability-card.tsx +174 -70
  58. package/src/hooks/use-browser-frame-stream.ts +3 -1
  59. package/src/hooks/use-browser-session.ts +107 -3
  60. package/src/hooks/use-voice-input.ts +12 -1
  61. package/src/timeline/compaction-copy.ts +2 -0
  62. package/src/timeline/parsers.ts +2 -2
  63. package/src/timeline/projection.ts +31 -5
  64. package/src/timeline/tool-renderers.tsx +105 -16
  65. package/src/timeline/turn-summary.tsx +10 -2
  66. package/src/timeline/types.ts +2 -0
  67. package/styles/compiled.css +6 -0
  68. package/styles/session-capability.css +2 -0
  69. package/dist/chunk-4ACTWOOW.js.map +0 -1
  70. package/dist/chunk-5UONOQ3Y.js.map +0 -1
  71. package/dist/chunk-KCGXPP5V.js.map +0 -1
  72. package/dist/chunk-SHRCATV6.js.map +0 -1
  73. package/dist/chunk-UQS7BGNQ.js.map +0 -1
  74. package/dist/chunk-VI7HELBI.js.map +0 -1
  75. package/dist/chunk-VR4Z73EU.js.map +0 -1
  76. package/dist/chunk-XMXRI5JK.js.map +0 -1
  77. package/dist/chunk-ZC2DK5SC.js.map +0 -1
  78. /package/dist/{browser-viewer-MN7MOYQT.js.map → browser-viewer-K2H3SLIW.js.map} +0 -0
@@ -23,7 +23,7 @@ import {
23
23
  useSession,
24
24
  useSessionEvents,
25
25
  useTurnQueue
26
- } from "./chunk-VI7HELBI.js";
26
+ } from "./chunk-SJ5HE4ZA.js";
27
27
  import {
28
28
  Actions,
29
29
  AttachButton,
@@ -46,7 +46,7 @@ import {
46
46
  Status,
47
47
  Surface,
48
48
  useChatComposerController
49
- } from "./chunk-4ACTWOOW.js";
49
+ } from "./chunk-VDSZ3AVO.js";
50
50
  import {
51
51
  ModelPolicyPicker
52
52
  } from "./chunk-3LL47F4U.js";
@@ -85,7 +85,7 @@ import {
85
85
  useForcedDefaultOpen,
86
86
  useTimelineSearchNavigation,
87
87
  useTimelineSearchReveal
88
- } from "./chunk-SHRCATV6.js";
88
+ } from "./chunk-7J4DUR3E.js";
89
89
  import {
90
90
  LightboxProvider,
91
91
  Tooltip,
@@ -1480,7 +1480,7 @@ function retainedScreenshotMetadata(out) {
1480
1480
  if (!value.available) {
1481
1481
  return typeof value.reason === "string" ? value : null;
1482
1482
  }
1483
- return value.kind === "computer_screenshot" && value.contentType === "image/png" && typeof value.originalBytes === "number" && typeof value.sha256 === "string" && value.dimensions !== null && typeof value.dimensions === "object" && value.retention !== null && typeof value.retention === "object" && value.retention.policy === "session_screenshot" ? value : null;
1483
+ return (value.kind === "computer_screenshot" || value.kind === "browser_screenshot") && ["image/png", "image/jpeg", "image/webp"].includes(String(value.contentType)) && typeof value.originalBytes === "number" && typeof value.sha256 === "string" && value.dimensions !== null && typeof value.dimensions === "object" && value.retention !== null && typeof value.retention === "object" && value.retention.policy === "session_screenshot" ? value : null;
1484
1484
  }
1485
1485
  function generatedImageReceipt(out) {
1486
1486
  return parseGeneratedImageReceipt(out);
@@ -2402,7 +2402,82 @@ function ComputerCallRenderer({ item, loadRetainedScreenshot }) {
2402
2402
  }
2403
2403
  );
2404
2404
  }
2405
- function RetainedSessionImageDisclosure({
2405
+ function BrowserScreenshotRenderer(props) {
2406
+ const { item, loadRetainedScreenshot } = props;
2407
+ const leaf = mcpToolLeaf(item.name);
2408
+ const title = leaf === "browser_observe" ? "Observed browser" : leaf === "browser_act" ? "Used browser" : "Browser screenshot";
2409
+ const retained = retainedScreenshotMetadata(item.output);
2410
+ const isFailed = item.status === "failed";
2411
+ const isCancelled = item.status === "cancelled";
2412
+ if (item.status === "running" && leaf === "browser_screenshot") {
2413
+ return /* @__PURE__ */ jsx7(
2414
+ ActivityDisclosure,
2415
+ {
2416
+ icon: /* @__PURE__ */ jsx7(CameraIcon, { className: ICON_SIZE }),
2417
+ iconTone: "running",
2418
+ title,
2419
+ running: true,
2420
+ media: /* @__PURE__ */ jsx7(MediaSkeleton, {}),
2421
+ children: /* @__PURE__ */ jsx7(BodyNote, { children: "capturing frame\u2026" })
2422
+ }
2423
+ );
2424
+ }
2425
+ if (!retained) return /* @__PURE__ */ jsx7(GenericRenderer, { ...props });
2426
+ if (!retained.available) {
2427
+ const state = retained.reason === "expired" || retained.reason === "deleted" ? retained.reason : "unavailable";
2428
+ return /* @__PURE__ */ jsx7(
2429
+ ActivityDisclosure,
2430
+ {
2431
+ icon: /* @__PURE__ */ jsx7(CameraOffIcon, { className: ICON_SIZE }),
2432
+ iconTone: isFailed ? "failed" : "muted",
2433
+ title: `${title} \xB7 ${state}`,
2434
+ failed: isFailed,
2435
+ cancelled: isCancelled,
2436
+ preview: `screenshot ${state}`,
2437
+ media: /* @__PURE__ */ jsx7(MediaEmpty, {}),
2438
+ children: /* @__PURE__ */ jsxs5(BodyNote, { tone: isFailed ? "error" : void 0, children: [
2439
+ "Screenshot ",
2440
+ state,
2441
+ ": ",
2442
+ retained.reason.replaceAll("_", " "),
2443
+ "."
2444
+ ] })
2445
+ }
2446
+ );
2447
+ }
2448
+ return /* @__PURE__ */ jsx7(
2449
+ RetainedSessionImageDisclosure,
2450
+ {
2451
+ artifact: retained,
2452
+ load: loadRetainedScreenshot,
2453
+ title,
2454
+ caption: title,
2455
+ noun: "screenshot",
2456
+ icon: /* @__PURE__ */ jsx7(CameraIcon, { className: ICON_SIZE }),
2457
+ lightboxLabel: "Browser screenshot",
2458
+ batched: null,
2459
+ failed: isFailed,
2460
+ cancelled: isCancelled
2461
+ }
2462
+ );
2463
+ }
2464
+ function RetainedSessionImageDisclosure(props) {
2465
+ const compact = useContext3(CompactActivityContext);
2466
+ if (compact) {
2467
+ return /* @__PURE__ */ jsx7(
2468
+ ActivityDisclosure,
2469
+ {
2470
+ icon: props.icon,
2471
+ title: props.title,
2472
+ compactPreview: null,
2473
+ failed: props.failed,
2474
+ cancelled: props.cancelled
2475
+ }
2476
+ );
2477
+ }
2478
+ return /* @__PURE__ */ jsx7(LoadedRetainedSessionImageDisclosure, { ...props });
2479
+ }
2480
+ function LoadedRetainedSessionImageDisclosure({
2406
2481
  artifact,
2407
2482
  load,
2408
2483
  title,
@@ -3675,6 +3750,9 @@ var BASE_ENTRIES = [
3675
3750
  { match: "name", name: "apply_patch_call", render: ApplyPatchRenderer },
3676
3751
  { match: "name", name: "apply_patch", render: ApplyPatchRenderer },
3677
3752
  { match: "name", name: "computer_call", render: ComputerCallRenderer },
3753
+ { match: "name", name: "browser_screenshot", render: BrowserScreenshotRenderer },
3754
+ { match: "name", name: "browser_observe", render: BrowserScreenshotRenderer },
3755
+ { match: "name", name: "browser_act", render: BrowserScreenshotRenderer },
3678
3756
  // Function-mode computer tools (codex / chat-wire transports).
3679
3757
  { match: "name", name: "computer_screenshot", render: ComputerCallRenderer },
3680
3758
  { match: "name", name: "computer_click", render: ComputerCallRenderer },
@@ -4944,7 +5022,8 @@ var BUILT_IN_TURN_SUMMARY_FACETS = Object.freeze([
4944
5022
  summarize: ({ toolCalls }) => {
4945
5023
  let screenshots = 0;
4946
5024
  for (const item of toolCalls) {
4947
- if ((rawTypeOf(item) === "computer_call" || item.name === "computer_call" || item.name === "computer_screenshot") && (screenshotDataUrl(item.output) !== null || mediaPreviewFact(item.output) !== null)) {
5025
+ const leaf = mcpToolLeaf(item.name);
5026
+ if ((rawTypeOf(item) === "computer_call" || item.name === "computer_call" || item.name === "computer_screenshot" || leaf === "browser_screenshot" || leaf === "browser_observe" || leaf === "browser_act") && (retainedScreenshotMetadata(item.output) !== null || screenshotDataUrl(item.output) !== null || mediaPreviewFact(item.output) !== null)) {
4948
5027
  screenshots += 1;
4949
5028
  }
4950
5029
  }
@@ -5287,6 +5366,8 @@ function compactionSkipSubtitle(reason, providerRejection = null) {
5287
5366
  return "No active history to compact";
5288
5367
  case "replacement_not_smaller":
5289
5368
  return "Checkpoint would not reduce memory size";
5369
+ case "replacement_exceeds_model_budget":
5370
+ return "Checkpoint exceeds this model's context budget. Chat history is unchanged.";
5290
5371
  case "replacement_unchanged":
5291
5372
  return "Checkpoint made no progress";
5292
5373
  case "summarization_failed":
@@ -10644,4 +10725,4 @@ export {
10644
10725
  SessionCommands,
10645
10726
  StartupTimings
10646
10727
  };
10647
- //# sourceMappingURL=chunk-ZC2DK5SC.js.map
10728
+ //# sourceMappingURL=chunk-RSFCYKA7.js.map