@opengeni/react 7.4.0-canary.36855269964001 → 7.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (157) hide show
  1. package/README.md +3 -48
  2. package/dist/artifacts-document.js +2 -3
  3. package/dist/artifacts-presentation.js +2 -3
  4. package/dist/artifacts-spreadsheet.js +2 -2
  5. package/dist/artifacts.d.ts +0 -1
  6. package/dist/artifacts.js +1402 -505
  7. package/dist/artifacts.js.map +1 -1
  8. package/dist/{browser-viewer-R6KK5VKR.js → browser-viewer-2E6R2Y4W.js} +4 -4
  9. package/dist/{chunk-WUISZ3WU.js → chunk-3E2AITTZ.js} +28 -32
  10. package/dist/{chunk-WUISZ3WU.js.map → chunk-3E2AITTZ.js.map} +1 -1
  11. package/dist/{chunk-PWUILT2U.js → chunk-5AZSK6MV.js} +2 -2
  12. package/dist/{chunk-Y2PRMYLC.js → chunk-DUEBTL3N.js} +3 -4
  13. package/dist/{chunk-Y2PRMYLC.js.map → chunk-DUEBTL3N.js.map} +1 -1
  14. package/dist/{chunk-7UAMYXJY.js → chunk-KNDIXZN6.js} +18 -25
  15. package/dist/{chunk-7UAMYXJY.js.map → chunk-KNDIXZN6.js.map} +1 -1
  16. package/dist/{chunk-P4G6K2E2.js → chunk-L4OSXQ6H.js} +884 -1119
  17. package/dist/chunk-L4OSXQ6H.js.map +1 -0
  18. package/dist/{chunk-LLIH7Q4B.js → chunk-S5JQ4R22.js} +19 -47
  19. package/dist/chunk-S5JQ4R22.js.map +1 -0
  20. package/dist/{chunk-A4UJB2MM.js → chunk-SEEVCT36.js} +2 -2
  21. package/dist/{chunk-UXJCQ5GH.js → chunk-UDD6DLLT.js} +1 -6
  22. package/dist/chunk-UDD6DLLT.js.map +1 -0
  23. package/dist/chunk-UGMKPUEM.js +299 -0
  24. package/dist/chunk-UGMKPUEM.js.map +1 -0
  25. package/dist/{chunk-ZCZHKJKZ.js → chunk-USXVQACU.js} +3 -3
  26. package/dist/{chunk-VABBF52G.js → chunk-V2ABIVYJ.js} +6 -70
  27. package/dist/chunk-V2ABIVYJ.js.map +1 -0
  28. package/dist/{chunk-TVO6GXR6.js → chunk-X4HIN6TV.js} +162 -71
  29. package/dist/chunk-X4HIN6TV.js.map +1 -0
  30. package/dist/{chunk-IIDEIBMC.js → chunk-XEJEOAOV.js} +38 -49
  31. package/dist/chunk-XEJEOAOV.js.map +1 -0
  32. package/dist/{chunk-ZKLCPBWN.js → chunk-Y3QTZN2F.js} +5 -5
  33. package/dist/{chunk-73BUNGLF.js → chunk-YZ3YYMOM.js} +1 -1
  34. package/dist/components/artifacts/editable-artifact-ui.d.ts +1 -2
  35. package/dist/components/artifacts/index.d.ts +0 -7
  36. package/dist/components/browser-select-control.d.ts +1 -3
  37. package/dist/components/message-timeline.d.ts +1 -18
  38. package/dist/components/open-geni-links.d.ts +0 -16
  39. package/dist/components/session-conversation.d.ts +1 -20
  40. package/dist/composer.js +3 -3
  41. package/dist/{computer-viewer-DJHPSP2J.js → computer-viewer-WMJE6OA3.js} +3 -3
  42. package/dist/connect.js +6 -7
  43. package/dist/connect.js.map +1 -1
  44. package/dist/hooks/latest-question.d.ts +1 -1
  45. package/dist/index.d.ts +2 -5
  46. package/dist/index.js +28 -39
  47. package/dist/index.js.map +1 -1
  48. package/dist/interaction.js +4 -4
  49. package/dist/{latest-question-KGCDK3XX.js → latest-question-QB4EUCW5.js} +3 -3
  50. package/dist/lib/format.d.ts +0 -3
  51. package/dist/machines.js +2 -2
  52. package/dist/{markdown-table-layout-QXSLK4BY.js → markdown-table-layout-PFUEZ2U4.js} +5 -37
  53. package/dist/markdown-table-layout-PFUEZ2U4.js.map +1 -0
  54. package/dist/{sandbox-files-4PMXDSDV.js → sandbox-files-PXPIZAFG.js} +2 -2
  55. package/dist/session-ui.d.ts +2 -5
  56. package/dist/session-ui.js +13 -23
  57. package/dist/session-ui.js.map +1 -1
  58. package/dist/session.js +3 -3
  59. package/dist/sites.js +289 -4
  60. package/dist/sites.js.map +1 -1
  61. package/dist/timeline/types.d.ts +1 -7
  62. package/dist/{timeline-annotation-selection-DMLMM2TX.js → timeline-annotation-selection-ODLVF4OI.js} +1 -6
  63. package/dist/timeline-annotation-selection-ODLVF4OI.js.map +1 -0
  64. package/package.json +3 -7
  65. package/src/artifacts.ts +0 -37
  66. package/src/components/artifacts/editable-artifact-ui.tsx +1 -3
  67. package/src/components/artifacts/editable-artifact-workbench.tsx +2 -5
  68. package/src/components/artifacts/editable-document.tsx +36 -34
  69. package/src/components/artifacts/editable-presentation.tsx +16 -21
  70. package/src/components/artifacts/index.ts +0 -41
  71. package/src/components/browser-select-control.tsx +1 -4
  72. package/src/components/browser-viewer.tsx +22 -81
  73. package/src/components/computer-viewer.tsx +23 -51
  74. package/src/components/markdown-table-layout.ts +5 -49
  75. package/src/components/markdown.tsx +2 -5
  76. package/src/components/message-timeline.tsx +434 -515
  77. package/src/components/open-geni-links.tsx +0 -24
  78. package/src/components/session-conversation.tsx +20 -131
  79. package/src/components/timeline-annotation-selection.tsx +0 -7
  80. package/src/hooks/use-available-models.ts +1 -1
  81. package/src/index.ts +0 -9
  82. package/src/lib/format.ts +0 -13
  83. package/src/session-ui.ts +0 -9
  84. package/src/timeline/projection.ts +4 -78
  85. package/src/timeline/types.ts +0 -7
  86. package/styles/compiled.css +0 -325
  87. package/dist/chat-interactive-block-VAGABN7J.js +0 -11
  88. package/dist/chunk-5CVXZA3Y.js +0 -292
  89. package/dist/chunk-5CVXZA3Y.js.map +0 -1
  90. package/dist/chunk-B3V6TG77.js +0 -41
  91. package/dist/chunk-B3V6TG77.js.map +0 -1
  92. package/dist/chunk-IIDEIBMC.js.map +0 -1
  93. package/dist/chunk-LLIH7Q4B.js.map +0 -1
  94. package/dist/chunk-P4G6K2E2.js.map +0 -1
  95. package/dist/chunk-RAIQYITC.js +0 -1772
  96. package/dist/chunk-RAIQYITC.js.map +0 -1
  97. package/dist/chunk-SCOTPE2I.js +0 -589
  98. package/dist/chunk-SCOTPE2I.js.map +0 -1
  99. package/dist/chunk-TVO6GXR6.js.map +0 -1
  100. package/dist/chunk-UXJCQ5GH.js.map +0 -1
  101. package/dist/chunk-VABBF52G.js.map +0 -1
  102. package/dist/chunk-WEHMPOXK.js +0 -39
  103. package/dist/chunk-WEHMPOXK.js.map +0 -1
  104. package/dist/chunk-XCHWDJ22.js +0 -107
  105. package/dist/chunk-XCHWDJ22.js.map +0 -1
  106. package/dist/components/artifacts/artifact-chrome.d.ts +0 -120
  107. package/dist/components/artifacts/artifact-sandbox.d.ts +0 -27
  108. package/dist/components/artifacts/chat-interactive-block.d.ts +0 -29
  109. package/dist/components/artifacts/deferred-chat-media.d.ts +0 -15
  110. package/dist/components/artifacts/editable-artifact-view.d.ts +0 -46
  111. package/dist/components/artifacts/latest-task-runner.d.ts +0 -15
  112. package/dist/components/artifacts/session-artifact-viewer.d.ts +0 -39
  113. package/dist/components/artifacts/site-view.d.ts +0 -23
  114. package/dist/components/timeline-pill-geometry.d.ts +0 -6
  115. package/dist/components/timeline-pill-placement.d.ts +0 -18
  116. package/dist/components/usage-limit-notice.d.ts +0 -49
  117. package/dist/components/usage-member-list.d.ts +0 -91
  118. package/dist/components/usage-meter.d.ts +0 -73
  119. package/dist/hooks/use-usage.d.ts +0 -40
  120. package/dist/markdown-table-layout-QXSLK4BY.js.map +0 -1
  121. package/dist/sandbox-files-4PMXDSDV.js.map +0 -1
  122. package/dist/timeline/allowance-exhausted-row.d.ts +0 -24
  123. package/dist/timeline-annotation-selection-DMLMM2TX.js.map +0 -1
  124. package/dist/timeline-pill-geometry-2G6EK47V.js +0 -73
  125. package/dist/timeline-pill-geometry-2G6EK47V.js.map +0 -1
  126. package/dist/usage/allowance-copy.d.ts +0 -25
  127. package/dist/usage/summary.d.ts +0 -35
  128. package/dist/usage.d.ts +0 -13
  129. package/dist/usage.js +0 -1073
  130. package/dist/usage.js.map +0 -1
  131. package/src/components/artifacts/artifact-chrome.tsx +0 -413
  132. package/src/components/artifacts/artifact-sandbox.tsx +0 -185
  133. package/src/components/artifacts/chat-interactive-block.tsx +0 -260
  134. package/src/components/artifacts/deferred-chat-media.tsx +0 -67
  135. package/src/components/artifacts/editable-artifact-view.tsx +0 -187
  136. package/src/components/artifacts/latest-task-runner.ts +0 -49
  137. package/src/components/artifacts/session-artifact-viewer.tsx +0 -376
  138. package/src/components/artifacts/site-view.tsx +0 -116
  139. package/src/components/timeline-pill-geometry.ts +0 -112
  140. package/src/components/timeline-pill-placement.ts +0 -81
  141. package/src/components/usage-limit-notice.tsx +0 -179
  142. package/src/components/usage-member-list.tsx +0 -792
  143. package/src/components/usage-meter.tsx +0 -382
  144. package/src/hooks/use-usage.ts +0 -100
  145. package/src/timeline/allowance-exhausted-row.tsx +0 -86
  146. package/src/usage/allowance-copy.ts +0 -64
  147. package/src/usage/summary.ts +0 -93
  148. package/src/usage.ts +0 -50
  149. /package/dist/{browser-viewer-R6KK5VKR.js.map → browser-viewer-2E6R2Y4W.js.map} +0 -0
  150. /package/dist/{chunk-PWUILT2U.js.map → chunk-5AZSK6MV.js.map} +0 -0
  151. /package/dist/{chunk-A4UJB2MM.js.map → chunk-SEEVCT36.js.map} +0 -0
  152. /package/dist/{chunk-ZCZHKJKZ.js.map → chunk-USXVQACU.js.map} +0 -0
  153. /package/dist/{chunk-ZKLCPBWN.js.map → chunk-Y3QTZN2F.js.map} +0 -0
  154. /package/dist/{chunk-73BUNGLF.js.map → chunk-YZ3YYMOM.js.map} +0 -0
  155. /package/dist/{chat-interactive-block-VAGABN7J.js.map → computer-viewer-WMJE6OA3.js.map} +0 -0
  156. /package/dist/{latest-question-KGCDK3XX.js.map → latest-question-QB4EUCW5.js.map} +0 -0
  157. /package/dist/{computer-viewer-DJHPSP2J.js.map → sandbox-files-PXPIZAFG.js.map} +0 -0
@@ -21,15 +21,15 @@ import {
21
21
  import {
22
22
  useEmbeddedBrowserInteraction
23
23
  } from "./chunk-NEXLLTP4.js";
24
- import {
25
- copyTextToClipboard
26
- } from "./chunk-JVYQRRC4.js";
27
24
  import {
28
25
  formatBytes
29
- } from "./chunk-UXJCQ5GH.js";
26
+ } from "./chunk-UDD6DLLT.js";
30
27
  import {
31
28
  cn
32
29
  } from "./chunk-22KP6LR5.js";
30
+ import {
31
+ copyTextToClipboard
32
+ } from "./chunk-JVYQRRC4.js";
33
33
 
34
34
  // src/components/browser-viewer.tsx
35
35
  import { interactionControlFailureFromError } from "@opengeni/sdk/interaction";
@@ -1881,7 +1881,6 @@ function BrowserSelectControl(props) {
1881
1881
  if (current === request.current) setBusy(false);
1882
1882
  }
1883
1883
  };
1884
- if (props.manualFallback === false && !open) return null;
1885
1884
  return /* @__PURE__ */ jsxs(
1886
1885
  "div",
1887
1886
  {
@@ -1892,7 +1891,7 @@ function BrowserSelectControl(props) {
1892
1891
  top: position?.y ?? anchor.y
1893
1892
  } : { bottom: 12, left: 12 },
1894
1893
  children: [
1895
- props.manualFallback !== false && (!anchor || !open) || error ? /* @__PURE__ */ jsx(
1894
+ !anchor || !open || error ? /* @__PURE__ */ jsx(
1896
1895
  "button",
1897
1896
  {
1898
1897
  type: "button",
@@ -2079,8 +2078,6 @@ function BrowserViewer({
2079
2078
  () => registry.relevantSessions.filter((session) => isLiveBrowser2(session)),
2080
2079
  [registry.relevantSessions]
2081
2080
  );
2082
- const latestRelevantBrowser = registry.relevantSessions[0];
2083
- const unavailableBrowser = latestRelevantBrowser?.lifecycle === "lost" || latestRelevantBrowser?.lifecycle === "failed" ? latestRelevantBrowser : void 0;
2084
2081
  const [selection, setSelection] = useState9(
2085
2082
  () => initialBrowserSessionId ? { sessionId: initialBrowserSessionId, pinned: true } : null
2086
2083
  );
@@ -2524,18 +2521,15 @@ function BrowserViewer({
2524
2521
  );
2525
2522
  }
2526
2523
  if (liveSessions.length === 0) {
2527
- if (renderEmpty && !unavailableBrowser)
2528
- return /* @__PURE__ */ jsx2(Fragment2, { children: renderEmpty(() => createBrowser(), creating) });
2524
+ if (renderEmpty) return /* @__PURE__ */ jsx2(Fragment2, { children: renderEmpty(() => createBrowser(), creating) });
2529
2525
  return /* @__PURE__ */ jsx2(
2530
2526
  "div",
2531
2527
  {
2532
2528
  className: cn("flex h-full min-h-0 items-center justify-center bg-og-bg p-6", className),
2533
2529
  children: /* @__PURE__ */ jsxs2("div", { className: "max-w-sm text-center", children: [
2534
2530
  /* @__PURE__ */ jsx2("span", { className: "mx-auto grid size-10 place-items-center rounded-og-md border border-og-border bg-og-surface-1 text-og-fg-muted", children: /* @__PURE__ */ jsx2(Globe2Icon, { className: "size-4.5" }) }),
2535
- unavailableBrowser && !attachedGenerationLoss ? /* @__PURE__ */ jsx2(BrowserUnavailableNotice, { session: unavailableBrowser }) : /* @__PURE__ */ jsxs2(Fragment2, { children: [
2536
- /* @__PURE__ */ jsx2("p", { className: "mt-3 text-og-menu font-medium text-og-fg", children: attachedGenerationLoss ? "Chrome reconnected\u2014open a fresh browser/desktop." : "No browser open" }),
2537
- /* @__PURE__ */ jsx2("p", { className: "mt-1 text-og-control leading-5 text-og-fg-muted", children: attachedGenerationLoss ? "This Chrome profile is live again, but the previous browser cannot move to the new connection. Use Browser \u2192 New browser \u2192 Connected Chrome." : "A browser appears here when this agent\u2014or another agent in the workspace\u2014opens one." })
2538
- ] }),
2531
+ /* @__PURE__ */ jsx2("p", { className: "mt-3 text-og-menu font-medium text-og-fg", children: attachedGenerationLoss ? "Chrome reconnected\u2014open a fresh browser/desktop." : "No browser open" }),
2532
+ /* @__PURE__ */ jsx2("p", { className: "mt-1 text-og-control leading-5 text-og-fg-muted", children: attachedGenerationLoss ? "This Chrome profile is live again, but the previous browser cannot move to the new connection. Use Browser \u2192 New browser \u2192 Connected Chrome." : "A browser appears here when this agent\u2014or another agent in the workspace\u2014opens one." }),
2539
2533
  /* @__PURE__ */ jsx2(
2540
2534
  BrowserLaunchMenu,
2541
2535
  {
@@ -2603,7 +2597,6 @@ function BrowserViewer({
2603
2597
  !selectedRegistrySession ? /* @__PURE__ */ jsx2(
2604
2598
  BrowserUnselectedPanel,
2605
2599
  {
2606
- unavailableBrowser,
2607
2600
  peerCount: liveSessions.length,
2608
2601
  creating,
2609
2602
  onCreate: () => createBrowser()
@@ -2854,7 +2847,7 @@ function BrowserToolbar(props) {
2854
2847
  function BrowserUnselectedPanel(props) {
2855
2848
  return /* @__PURE__ */ jsx2("div", { className: "grid min-h-0 flex-1 place-items-center bg-og-bg p-6 text-center", children: /* @__PURE__ */ jsxs2("div", { className: "max-w-sm", children: [
2856
2849
  /* @__PURE__ */ jsx2("span", { className: "mx-auto grid size-10 place-items-center rounded-og-md border border-og-border bg-og-surface-1 text-og-fg-muted", children: /* @__PURE__ */ jsx2(Globe2Icon, { className: "size-4.5" }) }),
2857
- props.unavailableBrowser ? /* @__PURE__ */ jsx2(BrowserUnavailableNotice, { session: props.unavailableBrowser }) : /* @__PURE__ */ jsx2("p", { className: "mt-3 text-og-menu font-medium text-og-fg", children: "No browser for this agent" }),
2850
+ /* @__PURE__ */ jsx2("p", { className: "mt-3 text-og-menu font-medium text-og-fg", children: "No browser for this agent" }),
2858
2851
  /* @__PURE__ */ jsx2("p", { className: "mt-1 text-og-control leading-5 text-og-fg-muted", children: props.peerCount === 1 ? "One workspace browser is available from the browser menu." : `${props.peerCount} workspace browsers are available from the browser menu.` }),
2859
2852
  /* @__PURE__ */ jsxs2(
2860
2853
  "button",
@@ -2871,18 +2864,6 @@ function BrowserUnselectedPanel(props) {
2871
2864
  )
2872
2865
  ] }) });
2873
2866
  }
2874
- function BrowserUnavailableNotice({ session }) {
2875
- const reason = session.failureCode === "provider_deadline_rotation" ? "The computer running it reached its time limit." : session.failureCode === "source_placement_changed" ? "This chat moved to another computer." : session.lifecycle === "failed" ? "It stopped unexpectedly." : "The connection to it was lost.";
2876
- return /* @__PURE__ */ jsxs2("div", { role: "status", children: [
2877
- /* @__PURE__ */ jsx2("p", { className: "mt-3 text-og-menu font-medium text-og-fg", children: "Browser unavailable" }),
2878
- /* @__PURE__ */ jsxs2("p", { className: "mt-1 break-words text-og-control leading-5 text-og-fg-muted", children: [
2879
- session.name,
2880
- ". ",
2881
- reason,
2882
- " Open a new browser to continue."
2883
- ] })
2884
- ] });
2885
- }
2886
2867
  function BrowserSessionGroup(props) {
2887
2868
  if (props.sessions.length === 0) return null;
2888
2869
  return /* @__PURE__ */ jsxs2("div", { className: "py-1", children: [
@@ -3266,7 +3247,7 @@ function BrowserProfileMenu(props) {
3266
3247
  ]
3267
3248
  }
3268
3249
  ) : null,
3269
- canSave ? /* @__PURE__ */ jsx2("p", { className: "mt-2 text-[10px] leading-4 text-og-fg-subtle", children: "Saving restarts this browser. Save unfinished work on its pages first; unsaved form entries may be lost. Other open browsers are unchanged." }) : null
3250
+ canSave ? /* @__PURE__ */ jsx2("p", { className: "mt-2 text-[10px] leading-4 text-og-fg-subtle", children: "Saving briefly restarts this browser. Other open browsers are unchanged." }) : null
3270
3251
  ] })
3271
3252
  ] });
3272
3253
  }
@@ -3437,7 +3418,6 @@ function BrowserViewport(props) {
3437
3418
  const pendingTextRef = useRef10(null);
3438
3419
  const actionRef = useRef10(props.onAction);
3439
3420
  const readClipboardRef = useRef10(props.onReadClipboard);
3440
- const observeInputRef = useRef10(props.onObserveForInput);
3441
3421
  const errorRef = useRef10(props.onError);
3442
3422
  const actionTailRef = useRef10(Promise.resolve());
3443
3423
  const actionQueueEpochRef = useRef10(0);
@@ -3450,7 +3430,6 @@ function BrowserViewport(props) {
3450
3430
  const mountedRef = useRef10(true);
3451
3431
  actionRef.current = props.onAction;
3452
3432
  readClipboardRef.current = props.onReadClipboard;
3453
- observeInputRef.current = props.onObserveForInput;
3454
3433
  errorRef.current = props.onError;
3455
3434
  const clearBufferedInput = useCallback8(() => {
3456
3435
  dismissSelectPopup();
@@ -3574,12 +3553,8 @@ function BrowserViewport(props) {
3574
3553
  const dispatchedAction = typing && typing.actions.length > 1 ? { type: "batch", actions: typing.actions, fenceEachAction: true } : action;
3575
3554
  const receipt = await actionRef.current(dispatchedAction, frame);
3576
3555
  if (!mountedRef.current || epoch !== actionQueueEpochRef.current) return;
3577
- const keyboardSelect = dispatchedAction.type === "press" && dispatchedAction.key === "Alt+ArrowDown";
3578
- if ((selectAnchor || keyboardSelect) && inputSequence === inputSequenceRef.current) {
3579
- const observation = keyboardSelect ? await observeInputRef.current() : receipt.observation;
3580
- if (mountedRef.current && epoch === actionQueueEpochRef.current && inputSequence === inputSequenceRef.current && observation) {
3581
- setSelectPopup({ observation, anchor: selectAnchor ?? null });
3582
- }
3556
+ if (selectAnchor && receipt.observation && inputSequence === inputSequenceRef.current) {
3557
+ setSelectPopup({ observation: receipt.observation, anchor: selectAnchor });
3583
3558
  }
3584
3559
  await after?.(receipt);
3585
3560
  }).catch((cause) => {
@@ -3821,7 +3796,6 @@ function BrowserViewport(props) {
3821
3796
  onPaste: paste,
3822
3797
  className: "pointer-events-none absolute left-1/2 top-1/2 size-px resize-none overflow-hidden opacity-0",
3823
3798
  "aria-label": "Browser keyboard input",
3824
- "aria-keyshortcuts": "Alt+ArrowDown",
3825
3799
  autoCapitalize: "off",
3826
3800
  autoCorrect: "off",
3827
3801
  spellCheck: false
@@ -3844,7 +3818,6 @@ function BrowserViewport(props) {
3844
3818
  showCanvas ? /* @__PURE__ */ jsx2(
3845
3819
  BrowserSelectControl,
3846
3820
  {
3847
- manualFallback: props.inputBatchAttachment?.focusedInputObservations !== true,
3848
3821
  activation: selectPopup,
3849
3822
  onDismiss: () => inputRef.current?.focus({ preventScroll: true }),
3850
3823
  observe: async () => {
@@ -4038,15 +4011,14 @@ function BrowserDiagnosticsDrawer(props) {
4038
4011
  {
4039
4012
  id: "browser-page-title",
4040
4013
  className: "text-[10px] font-semibold uppercase tracking-[0.14em] text-og-fg-subtle",
4041
- children: "Tab diagnostics"
4014
+ children: "Current page"
4042
4015
  }
4043
4016
  ),
4044
- /* @__PURE__ */ jsx2("p", { className: "mt-1 text-og-xs text-og-fg-subtle", children: "Includes earlier pages in this tab." }),
4045
4017
  /* @__PURE__ */ jsxs2("dl", { className: "mt-2 grid grid-cols-2 gap-2", children: [
4046
- /* @__PURE__ */ jsx2(DiagnosticCount, { label: "Console errors", value: diagnostics?.consoleErrorCount }),
4047
- /* @__PURE__ */ jsx2(DiagnosticCount, { label: "Page errors", value: diagnostics?.pageErrorCount }),
4048
- /* @__PURE__ */ jsx2(DiagnosticCount, { label: "Failed requests", value: diagnostics?.failedRequestCount }),
4049
- /* @__PURE__ */ jsx2(DiagnosticCount, { label: "Downloads", value: diagnostics?.downloadCount })
4018
+ /* @__PURE__ */ jsx2(DiagnosticCount, { label: "Console errors", value: diagnostics?.consoleErrorCount ?? 0 }),
4019
+ /* @__PURE__ */ jsx2(DiagnosticCount, { label: "Page errors", value: diagnostics?.pageErrorCount ?? 0 }),
4020
+ /* @__PURE__ */ jsx2(DiagnosticCount, { label: "Failed requests", value: diagnostics?.failedRequestCount ?? 0 }),
4021
+ /* @__PURE__ */ jsx2(DiagnosticCount, { label: "Downloads", value: diagnostics?.downloadCount ?? 0 })
4050
4022
  ] }),
4051
4023
  session?.failureCode ? /* @__PURE__ */ jsxs2("p", { className: "mt-2 rounded-og-sm border border-og-status-error/30 bg-og-status-error/5 px-2.5 py-2 text-og-xs text-og-danger", children: [
4052
4024
  "Browser state: ",
@@ -4286,7 +4258,7 @@ function DiagnosticCount(props) {
4286
4258
  "mt-0.5 text-og-sm font-semibold",
4287
4259
  props.value ? "text-og-fg" : "text-og-fg-muted"
4288
4260
  ),
4289
- children: props.value ?? "Unavailable"
4261
+ children: props.value
4290
4262
  }
4291
4263
  )
4292
4264
  ] });
@@ -4469,4 +4441,4 @@ export {
4469
4441
  useBrowserFrameStream,
4470
4442
  BrowserViewer
4471
4443
  };
4472
- //# sourceMappingURL=chunk-LLIH7Q4B.js.map
4444
+ //# sourceMappingURL=chunk-S5JQ4R22.js.map