@tutti-os/agent-gui 0.0.33 → 0.0.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 (46) hide show
  1. package/README.md +5 -0
  2. package/dist/{AgentMessageMarkdown-Cp70W-Z2.d.ts → AgentMessageMarkdown-0sV8Biv3.d.ts} +53 -5
  3. package/dist/agent-conversation/index.d.ts +4 -4
  4. package/dist/agent-conversation/index.js +5 -5
  5. package/dist/agent-message-center/index.d.ts +2 -2
  6. package/dist/agent-message-center/index.js +29 -8
  7. package/dist/agent-message-center/index.js.map +1 -1
  8. package/dist/{agentConversationVM-BElW2LNR.d.ts → agentConversationVM-xuzmD5IL.d.ts} +2 -0
  9. package/dist/app/renderer/agentactivity.css +54 -128
  10. package/dist/{chunk-SGQ4C7JE.js → chunk-2ADVHCST.js} +2 -1
  11. package/dist/chunk-2ADVHCST.js.map +1 -0
  12. package/dist/{chunk-WPWZKKKV.js → chunk-3LEUGNCT.js} +2 -2
  13. package/dist/{chunk-AFTAFV2C.js → chunk-CMXRLF64.js} +85 -13
  14. package/dist/chunk-CMXRLF64.js.map +1 -0
  15. package/dist/{chunk-RDCBACWR.js → chunk-JYH2ITNL.js} +5 -5
  16. package/dist/{chunk-RQ3HEF42.js → chunk-KFMD33UD.js} +36 -12
  17. package/dist/chunk-KFMD33UD.js.map +1 -0
  18. package/dist/{chunk-ZWYHKGQ7.js → chunk-NCS7X3XY.js} +11 -9
  19. package/dist/{chunk-ZWYHKGQ7.js.map → chunk-NCS7X3XY.js.map} +1 -1
  20. package/dist/{chunk-GSZPMKFW.js → chunk-O56P2KSZ.js} +237 -26
  21. package/dist/chunk-O56P2KSZ.js.map +1 -0
  22. package/dist/{chunk-ERRANBGS.js → chunk-U3D7YI47.js} +7 -11
  23. package/dist/chunk-U3D7YI47.js.map +1 -0
  24. package/dist/{chunk-OOQIJXCA.js → chunk-UN4XGHLQ.js} +3 -2
  25. package/dist/{chunk-A4KUAXE5.js → chunk-VPC55T7P.js} +2 -2
  26. package/dist/context-mention-palette/index.js +6 -6
  27. package/dist/i18n/index.d.ts +34 -10
  28. package/dist/i18n/index.js +1 -1
  29. package/dist/index.d.ts +5 -4
  30. package/dist/index.js +1012 -477
  31. package/dist/index.js.map +1 -1
  32. package/dist/plan-decision-ops.d.ts +1 -1
  33. package/dist/workbench/contribution.js +1 -1
  34. package/dist/workbench/index.js +1 -1
  35. package/dist/workspace-agent-generated-files.js +2 -2
  36. package/dist/{workspaceLinkActions-CqWZaCY4.d.ts → workspaceLinkActions-C6POH38D.d.ts} +7 -1
  37. package/package.json +12 -12
  38. package/dist/chunk-AFTAFV2C.js.map +0 -1
  39. package/dist/chunk-ERRANBGS.js.map +0 -1
  40. package/dist/chunk-GSZPMKFW.js.map +0 -1
  41. package/dist/chunk-RQ3HEF42.js.map +0 -1
  42. package/dist/chunk-SGQ4C7JE.js.map +0 -1
  43. /package/dist/{chunk-WPWZKKKV.js.map → chunk-3LEUGNCT.js.map} +0 -0
  44. /package/dist/{chunk-RDCBACWR.js.map → chunk-JYH2ITNL.js.map} +0 -0
  45. /package/dist/{chunk-OOQIJXCA.js.map → chunk-UN4XGHLQ.js.map} +0 -0
  46. /package/dist/{chunk-A4KUAXE5.js.map → chunk-VPC55T7P.js.map} +0 -0
@@ -10,14 +10,14 @@ import {
10
10
  resolveWorkspaceFileLinkAction,
11
11
  resolveWorkspaceFilePathCandidate,
12
12
  resolveWorkspaceLinkAction
13
- } from "./chunk-AFTAFV2C.js";
13
+ } from "./chunk-CMXRLF64.js";
14
14
  import {
15
15
  attrsToMentionItem,
16
16
  createAgentFileMentionExtension,
17
17
  formatAgentMentionMarkdown,
18
18
  mentionItemToAttrs,
19
19
  parseAgentMentionMarkdown
20
- } from "./chunk-A4KUAXE5.js";
20
+ } from "./chunk-VPC55T7P.js";
21
21
  import {
22
22
  fileChangeCountFromChanges,
23
23
  fileChangeEntriesFromChanges,
@@ -27,13 +27,13 @@ import {
27
27
  import {
28
28
  getOptionalAgentActivityRuntime,
29
29
  useOptionalAgentHostApi
30
- } from "./chunk-SGQ4C7JE.js";
30
+ } from "./chunk-2ADVHCST.js";
31
31
  import {
32
32
  workspaceAgentProviderLabel
33
33
  } from "./chunk-TYGL25EL.js";
34
34
  import {
35
35
  translate
36
- } from "./chunk-RQ3HEF42.js";
36
+ } from "./chunk-KFMD33UD.js";
37
37
 
38
38
  // shared/imageGenerationTool.ts
39
39
  var KNOWN_IMAGE_GENERATION_TOOL_NAMES = /* @__PURE__ */ new Set([
@@ -2158,9 +2158,11 @@ function systemNoticeFromPayload(payload) {
2158
2158
  if (stringRecordValue5(payload, "kind") !== "agent_system_notice") {
2159
2159
  return null;
2160
2160
  }
2161
+ const source = stringRecordValue5(payload, "source");
2161
2162
  return {
2162
2163
  noticeKind: stringRecordValue5(payload, "noticeKind"),
2163
2164
  severity: stringRecordValue5(payload, "severity"),
2165
+ ...source ? { source } : {},
2164
2166
  title: stringRecordValue5(payload, "title"),
2165
2167
  detail: stringRecordValue5(payload, "detail"),
2166
2168
  retryable: booleanRecordValue(payload, "retryable")
@@ -4095,6 +4097,7 @@ function firstNonEmptyString(...values) {
4095
4097
 
4096
4098
  // shared/agentConversation/projection/agentConversationProjection.ts
4097
4099
  var RENDER_IRRELEVANT_TRANSCRIPT_ROW_FIELDS = /* @__PURE__ */ new Set(["occurredAtUnixMs"]);
4100
+ var CODEX_SKILLS_CONTEXT_BUDGET_NOTICE_FRAGMENT = "skill descriptions were shortened to fit the 2% skills context budget";
4098
4101
  function projectAgentConversationVM(detail, options = {}) {
4099
4102
  const rows = [];
4100
4103
  const turns = detail.turns;
@@ -4125,9 +4128,11 @@ function projectAgentConversationVM(detail, options = {}) {
4125
4128
  rows.push(processing);
4126
4129
  }
4127
4130
  const normalizedRows = projectMessageCopyText(
4128
- dropRedundantErrorWarningNotices(
4129
- mergeAdjacentAssistantMessageRows(
4130
- mergeAdjacentTransportRetryNoticeRows(rows)
4131
+ dropCodexRuntimeDiagnosticNotices(
4132
+ dropRedundantErrorWarningNotices(
4133
+ mergeAdjacentAssistantMessageRows(
4134
+ mergeAdjacentTransportRetryNoticeRows(rows)
4135
+ )
4131
4136
  )
4132
4137
  ),
4133
4138
  {
@@ -4255,6 +4260,38 @@ function mergeAdjacentAssistantMessageRows(rows) {
4255
4260
  }
4256
4261
  return merged;
4257
4262
  }
4263
+ function dropCodexRuntimeDiagnosticNotices(rows) {
4264
+ const filteredRows = [];
4265
+ for (const row of rows) {
4266
+ if (row.kind !== "message" || row.speaker !== "assistant") {
4267
+ filteredRows.push(row);
4268
+ continue;
4269
+ }
4270
+ const messages = row.messages.filter(
4271
+ (message) => !isCodexSkillsContextBudgetNotice(message)
4272
+ );
4273
+ if (messages.length === 0 && row.thinking.length === 0) {
4274
+ continue;
4275
+ }
4276
+ if (messages.length === row.messages.length) {
4277
+ filteredRows.push(row);
4278
+ continue;
4279
+ }
4280
+ filteredRows.push({ ...row, messages });
4281
+ }
4282
+ return filteredRows;
4283
+ }
4284
+ function isCodexSkillsContextBudgetNotice(message) {
4285
+ const notice = message.systemNotice;
4286
+ if (!notice || notice.noticeKind !== "warning") {
4287
+ return false;
4288
+ }
4289
+ if (notice.source !== "runtime") {
4290
+ return false;
4291
+ }
4292
+ const text = [notice.title, notice.detail, message.body].filter(Boolean).join("\n").toLowerCase();
4293
+ return text.includes(CODEX_SKILLS_CONTEXT_BUDGET_NOTICE_FRAGMENT);
4294
+ }
4258
4295
  function dropRedundantErrorWarningNotices(rows) {
4259
4296
  const turnsWithVisibleError = /* @__PURE__ */ new Set();
4260
4297
  for (const row of rows) {
@@ -5563,6 +5600,133 @@ function resolveWorkspaceAppIconUrl(input) {
5563
5600
  return exactMatch?.iconUrl?.trim() || fallbackMatch?.iconUrl?.trim() || void 0;
5564
5601
  }
5565
5602
 
5603
+ // shared/agentEnv/agentEnvPanelStore.ts
5604
+ import { useSnapshot } from "valtio";
5605
+ import { proxy } from "valtio/vanilla";
5606
+ var agentEnvPanelStore = proxy({
5607
+ open: false,
5608
+ provider: null,
5609
+ focus: null,
5610
+ requestSequence: 0
5611
+ });
5612
+ function openAgentEnvPanel(input) {
5613
+ agentEnvPanelStore.open = true;
5614
+ agentEnvPanelStore.provider = input?.provider ?? null;
5615
+ agentEnvPanelStore.focus = input?.focus ?? null;
5616
+ agentEnvPanelStore.requestSequence += 1;
5617
+ }
5618
+
5619
+ // shared/agentEnv/agentErrorPresentation.ts
5620
+ var NO_CTA = { focus: null, actionKey: null };
5621
+ var SELF_DETECT = {
5622
+ messageKey: null,
5623
+ focus: "detect",
5624
+ actionKey: "agentHost.agentGui.visibleErrorActionDetect"
5625
+ };
5626
+ var PRESENTATIONS = {
5627
+ // Environment problems the wizard can detect or repair → route to its step.
5628
+ auth_required: {
5629
+ messageKey: "agentHost.agentGui.visibleErrorAuthRequired",
5630
+ focus: "auth",
5631
+ actionKey: "agentHost.agentGui.visibleErrorActionRelogin"
5632
+ },
5633
+ cli_not_found: {
5634
+ messageKey: "agentHost.agentGui.visibleErrorCliNotFound",
5635
+ focus: "install",
5636
+ actionKey: "agentHost.agentGui.visibleErrorActionInstall"
5637
+ },
5638
+ cli_version_unsupported: {
5639
+ messageKey: "agentHost.agentGui.visibleErrorVersionUnsupported",
5640
+ focus: "upgrade",
5641
+ actionKey: "agentHost.agentGui.visibleErrorActionUpgrade"
5642
+ },
5643
+ network_error: {
5644
+ messageKey: "agentHost.agentGui.visibleErrorNetwork",
5645
+ focus: "network",
5646
+ actionKey: "agentHost.agentGui.visibleErrorActionCheckNetwork"
5647
+ },
5648
+ runtime_unavailable: {
5649
+ messageKey: "agentHost.agentGui.visibleErrorRuntimeUnavailable",
5650
+ focus: "detect",
5651
+ actionKey: "agentHost.agentGui.visibleErrorActionDetect"
5652
+ },
5653
+ // Transient / server-side failures: accurate copy, but no wizard CTA — it
5654
+ // cannot fix a rate limit or a dropped stream.
5655
+ request_timed_out: {
5656
+ messageKey: "agentHost.agentGui.visibleErrorRequestTimedOut",
5657
+ ...NO_CTA
5658
+ },
5659
+ provider_config_timeout: {
5660
+ messageKey: "agentHost.agentGui.visibleErrorConfigTimeout",
5661
+ ...NO_CTA
5662
+ },
5663
+ provider_stream_disconnected: {
5664
+ messageKey: "agentHost.agentGui.visibleErrorStreamDisconnected",
5665
+ ...NO_CTA
5666
+ },
5667
+ provider_concurrency_limit: {
5668
+ messageKey: "agentHost.agentGui.visibleErrorConcurrencyLimit",
5669
+ ...NO_CTA
5670
+ },
5671
+ quota_or_rate_limit: {
5672
+ messageKey: "agentHost.agentGui.visibleErrorQuotaOrRateLimit",
5673
+ ...NO_CTA
5674
+ },
5675
+ // Ambiguous hard failures → generic message + self-detect escape hatch.
5676
+ process_exited: SELF_DETECT,
5677
+ provider_error: SELF_DETECT,
5678
+ unknown: SELF_DETECT
5679
+ };
5680
+ function resolveAgentErrorPresentation(code) {
5681
+ if (!code) {
5682
+ return null;
5683
+ }
5684
+ return PRESENTATIONS[code] ?? null;
5685
+ }
5686
+ var FAILED_MESSAGE_CODE_MARKERS = [
5687
+ [
5688
+ "auth_required",
5689
+ [
5690
+ "authentication_failed",
5691
+ "invalid authentication credentials",
5692
+ "401 invalid authentication",
5693
+ "unauthorized",
5694
+ "not logged in",
5695
+ "please run /login",
5696
+ "invalid api key"
5697
+ ]
5698
+ ],
5699
+ [
5700
+ "cli_version_unsupported",
5701
+ ["requires a newer version", "version is too old", "unsupported version"]
5702
+ ],
5703
+ [
5704
+ "cli_not_found",
5705
+ [
5706
+ "no such file or directory",
5707
+ "command not found",
5708
+ "enoent",
5709
+ "executable file not found"
5710
+ ]
5711
+ ],
5712
+ [
5713
+ "network_error",
5714
+ ["enotfound", "econnrefused", "econnreset", "getaddrinfo", "socket hang up"]
5715
+ ]
5716
+ ];
5717
+ function classifyFailedAgentMessage(body) {
5718
+ if (!body) {
5719
+ return null;
5720
+ }
5721
+ const lower = body.toLowerCase();
5722
+ for (const [code, markers] of FAILED_MESSAGE_CODE_MARKERS) {
5723
+ if (markers.some((marker) => lower.includes(marker))) {
5724
+ return code;
5725
+ }
5726
+ }
5727
+ return null;
5728
+ }
5729
+
5566
5730
  // shared/agentConversation/components/CollapsibleReveal.tsx
5567
5731
  import {
5568
5732
  useCallback as useCallback2,
@@ -6408,7 +6572,7 @@ var CanvasNodeGhostIconButton = forwardRef3(function CanvasNodeGhostIconButton2(
6408
6572
  ...rest,
6409
6573
  type: "button",
6410
6574
  className: cn(
6411
- "nodrag inline-flex h-7 min-h-7 w-7 min-w-7 shrink-0 items-center justify-center rounded-[4px] border border-transparent bg-transparent p-0 text-[var(--cove-canvas-control-text)] transition-[background-color,color,border-color,opacity] duration-200 ease-in-out [-webkit-app-region:no-drag] hover:border-transparent hover:bg-[var(--transparency-block)] hover:text-[var(--cove-canvas-control-text-hover)] active:bg-[var(--transparency-block-active)] active:text-[var(--cove-canvas-control-text-hover)] disabled:cursor-not-allowed disabled:opacity-45 focus-visible:outline-2 focus-visible:outline-[color:color-mix(in_srgb,var(--tsh-shell-accent)_80%,white)] focus-visible:outline-offset-2 [&_svg]:block [&_svg]:h-4 [&_svg]:w-4 [&_svg]:shrink-0 [&_svg:not([data-nexight-chrome-glyph=fill]):not([data-tutti-chrome-glyph=fill])]:fill-none [&_svg:not([data-nexight-chrome-glyph=fill]):not([data-tutti-chrome-glyph=fill])]:stroke-current data-[menu-open=true]:border-transparent data-[menu-open=true]:bg-[var(--transparency-block)] data-[menu-open=true]:text-[var(--cove-canvas-control-text-hover)] data-[menu-open=true]:hover:bg-[var(--transparency-block-active)]",
6575
+ "nodrag inline-flex h-7 min-h-7 w-7 min-w-7 shrink-0 items-center justify-center rounded-[4px] border border-transparent bg-transparent p-0 text-[var(--text-secondary)] transition-[background-color,color,border-color,opacity] duration-200 ease-in-out [-webkit-app-region:no-drag] hover:border-transparent hover:bg-[var(--transparency-block)] hover:text-[var(--text-primary)] active:bg-[var(--transparency-block-active)] active:text-[var(--text-primary)] disabled:cursor-not-allowed disabled:opacity-45 focus-visible:outline-2 focus-visible:outline-[color:color-mix(in_srgb,var(--tsh-shell-accent)_80%,white)] focus-visible:outline-offset-2 [&_svg]:block [&_svg]:h-3.5 [&_svg]:w-3.5 [&_svg]:shrink-0 [&_svg:not([data-nexight-chrome-glyph=fill]):not([data-tutti-chrome-glyph=fill])]:fill-none [&_svg:not([data-nexight-chrome-glyph=fill]):not([data-tutti-chrome-glyph=fill])]:stroke-current data-[menu-open=true]:border-transparent data-[menu-open=true]:bg-[var(--transparency-block)] data-[menu-open=true]:text-[var(--text-primary)] data-[menu-open=true]:hover:bg-[var(--transparency-block-active)]",
6412
6576
  className
6413
6577
  ),
6414
6578
  onPointerDown: (event) => {
@@ -6446,6 +6610,7 @@ function AgentMessageBlock({
6446
6610
  onLinkAction,
6447
6611
  thinkingLabel,
6448
6612
  onAuthLogin,
6613
+ provider,
6449
6614
  availableSkills,
6450
6615
  workspaceAppIcons,
6451
6616
  previewMode = false,
@@ -6517,6 +6682,7 @@ function AgentMessageBlock({
6517
6682
  label: rawTimelineJsonLabel
6518
6683
  }
6519
6684
  ) : null;
6685
+ const recoveredError = !isUser && !message.visibleError && message.statusKind === "failed" ? recoverVisibleErrorFromFailedMessage(message, provider) : null;
6520
6686
  const content = isUser && message.contentKind === "image-grid" ? /* @__PURE__ */ jsx12(AgentUserImageGrid, { message }) : isUser ? /* @__PURE__ */ jsx12(
6521
6687
  AgentRichTextReadonly,
6522
6688
  {
@@ -6533,6 +6699,12 @@ function AgentMessageBlock({
6533
6699
  message,
6534
6700
  onAuthLogin
6535
6701
  }
6702
+ ) : recoveredError ? /* @__PURE__ */ jsx12(
6703
+ AgentVisibleErrorMessage,
6704
+ {
6705
+ message: recoveredError,
6706
+ onAuthLogin
6707
+ }
6536
6708
  ) : message.systemNotice ? /* @__PURE__ */ jsx12(AgentSystemNoticeMessage, { message }) : message.contentKind === "plan" ? /* @__PURE__ */ jsx12(
6537
6709
  AgentPlanCardMessage,
6538
6710
  {
@@ -6652,30 +6824,33 @@ function AgentUserImageGrid({
6652
6824
  const images = message.images ?? [];
6653
6825
  const { loadingIds, sources: loadedImages } = useAgentMessageImageSources(images);
6654
6826
  const columnCount = Math.min(Math.max(images.length, 1), 4);
6827
+ const thumbnailWidth = images.length === 1 ? "160px" : "80px";
6655
6828
  return /* @__PURE__ */ jsx12(
6656
6829
  "div",
6657
6830
  {
6658
6831
  className: "grid justify-self-end gap-2",
6659
- style: { gridTemplateColumns: `repeat(${columnCount}, 80px)` },
6832
+ style: {
6833
+ gridTemplateColumns: `repeat(${columnCount}, ${thumbnailWidth})`
6834
+ },
6660
6835
  children: images.map((image) => {
6661
6836
  const src = loadedImages.get(image.id) ?? imageDataUrl(image);
6662
6837
  const loading = !src && loadingIds.has(image.id);
6663
6838
  return /* @__PURE__ */ jsx12(
6664
6839
  "div",
6665
6840
  {
6666
- className: "size-20 min-w-0 overflow-hidden rounded-[6px]",
6841
+ className: "max-h-20 min-w-0 overflow-hidden rounded-[6px]",
6667
6842
  children: src ? /* @__PURE__ */ jsx12(
6668
6843
  ZoomableImage,
6669
6844
  {
6670
6845
  src,
6671
6846
  alt: image.name?.trim() || "image",
6672
- className: "size-full object-cover",
6847
+ className: "block max-h-20 w-full rounded-[6px] object-contain",
6673
6848
  draggable: false
6674
6849
  }
6675
6850
  ) : loading ? /* @__PURE__ */ jsx12(
6676
6851
  "div",
6677
6852
  {
6678
- className: "flex size-full items-center justify-center bg-[color-mix(in_srgb,var(--text-primary)_6%,transparent)]",
6853
+ className: "flex h-20 w-full items-center justify-center bg-[color-mix(in_srgb,var(--text-primary)_6%,transparent)]",
6679
6854
  "data-testid": "agent-gui-message-image-loading",
6680
6855
  children: /* @__PURE__ */ jsx12(
6681
6856
  LoaderCircle,
@@ -6686,7 +6861,7 @@ function AgentUserImageGrid({
6686
6861
  }
6687
6862
  )
6688
6863
  }
6689
- ) : /* @__PURE__ */ jsx12("div", { className: "size-full animate-pulse bg-[color-mix(in_srgb,var(--text-primary)_8%,transparent)]" })
6864
+ ) : /* @__PURE__ */ jsx12("div", { className: "h-20 w-full animate-pulse bg-[color-mix(in_srgb,var(--text-primary)_8%,transparent)]" })
6690
6865
  },
6691
6866
  image.id
6692
6867
  );
@@ -6890,16 +7065,36 @@ function systemNoticeTitle(message) {
6890
7065
  return notice?.title || message.body || translate("agentHost.agentGui.systemNoticeDefault");
6891
7066
  }
6892
7067
  }
7068
+ function recoverVisibleErrorFromFailedMessage(message, provider) {
7069
+ const code = classifyFailedAgentMessage(message.body);
7070
+ if (!code) {
7071
+ return null;
7072
+ }
7073
+ return {
7074
+ ...message,
7075
+ visibleError: {
7076
+ code,
7077
+ phase: null,
7078
+ provider: provider ?? null,
7079
+ detail: message.body,
7080
+ retryable: null
7081
+ }
7082
+ };
7083
+ }
6893
7084
  function AgentVisibleErrorMessage({
6894
- message,
6895
- onAuthLogin
7085
+ message
6896
7086
  }) {
6897
7087
  "use memo";
6898
7088
  const error = message.visibleError;
6899
- const title = visibleErrorTitle(message);
6900
- const hint = visibleErrorHint(message);
6901
7089
  const detail = error?.detail?.trim() ?? "";
6902
- const showAuthLogin = error?.code === "auth_required" && onAuthLogin;
7090
+ const providerLabel = workspaceAgentProviderLabel(
7091
+ error?.provider ?? "unknown"
7092
+ );
7093
+ const presentation = resolveAgentErrorPresentation(error?.code);
7094
+ const headline = presentation?.messageKey ? translate(presentation.messageKey, { provider: providerLabel }) : visibleErrorTitle(message);
7095
+ const focus = presentation?.focus ?? null;
7096
+ const actionKey = presentation?.actionKey ?? null;
7097
+ const hint = visibleErrorHint(message);
6903
7098
  return /* @__PURE__ */ jsx12(
6904
7099
  "section",
6905
7100
  {
@@ -6907,19 +7102,29 @@ function AgentVisibleErrorMessage({
6907
7102
  className: "box-border w-full min-w-0 rounded-[8px] border border-[var(--on-danger-hover)] bg-[var(--on-danger)] p-3 text-[13px] leading-5 text-[var(--state-danger)]",
6908
7103
  children: /* @__PURE__ */ jsxs7("div", { className: "flex min-w-0 items-start gap-3", children: [
6909
7104
  /* @__PURE__ */ jsxs7("div", { className: "min-w-0 flex-1", children: [
6910
- /* @__PURE__ */ jsx12("div", { className: "font-medium text-[var(--text-primary)]", children: title }),
7105
+ /* @__PURE__ */ jsx12("div", { className: "font-medium text-[var(--text-primary)]", children: headline }),
6911
7106
  hint ? /* @__PURE__ */ jsx12("div", { className: "mt-1 text-[11px] text-[var(--text-secondary)]", children: hint }) : null,
6912
- detail ? /* @__PURE__ */ jsx12(AgentMessageDetailsDisclosure, { detail, className: "mt-1" }) : null
7107
+ detail ? /* @__PURE__ */ jsx12(
7108
+ AgentMessageDetailsDisclosure,
7109
+ {
7110
+ detail,
7111
+ className: "mt-1",
7112
+ label: translate("agentHost.agentGui.visibleErrorRawDetails")
7113
+ }
7114
+ ) : null
6913
7115
  ] }),
6914
- showAuthLogin ? /* @__PURE__ */ jsx12(
7116
+ focus && actionKey ? /* @__PURE__ */ jsx12(
6915
7117
  Button,
6916
7118
  {
6917
7119
  type: "button",
6918
7120
  variant: "ghost",
6919
7121
  size: "sm",
6920
7122
  className: "mt-0.5 shrink-0",
6921
- onClick: () => onAuthLogin(error?.provider ?? null),
6922
- children: translate("agentHost.agentGui.authLogin")
7123
+ onClick: () => openAgentEnvPanel({
7124
+ provider: error?.provider ?? "codex",
7125
+ focus
7126
+ }),
7127
+ children: translate(actionKey)
6923
7128
  }
6924
7129
  ) : null
6925
7130
  ] })
@@ -6928,7 +7133,8 @@ function AgentVisibleErrorMessage({
6928
7133
  }
6929
7134
  function AgentMessageDetailsDisclosure({
6930
7135
  detail,
6931
- className = ""
7136
+ className = "",
7137
+ label
6932
7138
  }) {
6933
7139
  "use memo";
6934
7140
  const [expanded, setExpanded] = useState5(false);
@@ -6941,7 +7147,7 @@ function AgentMessageDetailsDisclosure({
6941
7147
  "aria-expanded": expanded,
6942
7148
  onClick: () => setExpanded((value) => !value),
6943
7149
  children: [
6944
- translate("agentHost.agentGui.visibleErrorDetails"),
7150
+ label ?? translate("agentHost.agentGui.visibleErrorDetails"),
6945
7151
  /* @__PURE__ */ jsx12(
6946
7152
  ChevronRight3,
6947
7153
  {
@@ -11958,6 +12164,7 @@ var AgentTranscriptItemView = memo2(function AgentTranscriptItemView2({
11958
12164
  labels,
11959
12165
  onLinkAction,
11960
12166
  onAuthLogin,
12167
+ provider,
11961
12168
  availableSkills,
11962
12169
  workspaceAppIcons,
11963
12170
  previewMode = false,
@@ -11991,6 +12198,7 @@ var AgentTranscriptItemView = memo2(function AgentTranscriptItemView2({
11991
12198
  row,
11992
12199
  onLinkAction,
11993
12200
  onAuthLogin,
12201
+ provider,
11994
12202
  availableSkills,
11995
12203
  workspaceAppIcons,
11996
12204
  previewMode,
@@ -12220,6 +12428,7 @@ var AgentTranscriptView = memo3(function AgentTranscriptView2({
12220
12428
  );
12221
12429
  const basePath = conversation.sourceDetail.cwd;
12222
12430
  const workspaceRoot = conversation.workspaceRoot;
12431
+ const provider = conversation.activity.agentProvider;
12223
12432
  const shouldVirtualize = useMemo6(
12224
12433
  () => assessAgentTranscriptComplexity(turnGroups).shouldVirtualize,
12225
12434
  [turnGroups]
@@ -12267,6 +12476,7 @@ var AgentTranscriptView = memo3(function AgentTranscriptView2({
12267
12476
  labels,
12268
12477
  onLinkAction,
12269
12478
  onAuthLogin,
12479
+ provider,
12270
12480
  availableSkills,
12271
12481
  workspaceAppIcons,
12272
12482
  previewMode,
@@ -12458,6 +12668,7 @@ export {
12458
12668
  labelForProviderSkill,
12459
12669
  promptForProviderSkills,
12460
12670
  skillDescriptionForDisplay,
12671
+ openAgentEnvPanel,
12461
12672
  AgentTranscriptSkeleton,
12462
12673
  plainTextToAgentRichTextDoc,
12463
12674
  plainTextToAgentRichTextInlineContent,
@@ -12467,4 +12678,4 @@ export {
12467
12678
  AgentConversationFlow,
12468
12679
  useProjectedAgentConversation
12469
12680
  };
12470
- //# sourceMappingURL=chunk-GSZPMKFW.js.map
12681
+ //# sourceMappingURL=chunk-O56P2KSZ.js.map