@tutti-os/agent-gui 0.0.212 → 0.0.214

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 (56) hide show
  1. package/README.md +19 -13
  2. package/dist/{AgentRichTextReadonly-WWU4ZF7W.js → AgentRichTextReadonly-TASIMIK4.js} +5 -5
  3. package/dist/agent-conversation/index.js +8 -8
  4. package/dist/agent-env/index.d.ts +1 -8
  5. package/dist/agent-env/index.js +1 -1
  6. package/dist/agent-gui.d.ts +19 -49
  7. package/dist/agent-gui.js +15 -15
  8. package/dist/agent-message-center/index.js +6 -6
  9. package/dist/app/renderer/agentactivity.css +0 -30
  10. package/dist/{chunk-POU5WZNH.js → chunk-2HYADTQP.js} +2 -2
  11. package/dist/{chunk-JVVLKTLR.js → chunk-7SSORDQY.js} +4 -4
  12. package/dist/{chunk-BGNYUYLP.js → chunk-AD2RTSMS.js} +2 -2
  13. package/dist/{chunk-GXXPUEX6.js → chunk-BYHNJQYH.js} +2 -2
  14. package/dist/{chunk-RNBZBBI7.js → chunk-FEUU4YMY.js} +24 -25
  15. package/dist/chunk-FEUU4YMY.js.map +1 -0
  16. package/dist/{chunk-7LSLB7CN.js → chunk-G2QO6HPB.js} +2 -2
  17. package/dist/{chunk-FRSV66P3.js → chunk-ISC67YBJ.js} +4 -4
  18. package/dist/{chunk-YJ27WHM3.js → chunk-L4E2Y52A.js} +2 -2
  19. package/dist/{chunk-WSIGQG7C.js → chunk-LQKLBDBK.js} +3 -3
  20. package/dist/{chunk-JZ6KUUDY.js → chunk-N4HLBSMJ.js} +2 -32
  21. package/dist/chunk-N4HLBSMJ.js.map +1 -0
  22. package/dist/{chunk-62LWOH3P.js → chunk-QVLEP54U.js} +1 -49
  23. package/dist/chunk-QVLEP54U.js.map +1 -0
  24. package/dist/{chunk-4IJYTGS2.js → chunk-RLFO3NJV.js} +1535 -1976
  25. package/dist/chunk-RLFO3NJV.js.map +1 -0
  26. package/dist/{chunk-4DAJ5SVX.js → chunk-XERDRMSF.js} +4 -4
  27. package/dist/{chunk-JUL7J4VN.js → chunk-YBIT37P5.js} +2 -2
  28. package/dist/{chunk-5UOJCDLE.js → chunk-ZNHMWCO4.js} +3 -3
  29. package/dist/context-mention-palette/index.js +7 -7
  30. package/dist/i18n/index.d.ts +0 -48
  31. package/dist/i18n/index.js +2 -2
  32. package/dist/index.d.ts +33 -617
  33. package/dist/index.js +15 -23
  34. package/dist/index.js.map +1 -1
  35. package/dist/mention-search.js +5 -5
  36. package/dist/workbench/contribution.js +3 -3
  37. package/dist/workbench/index.js +3 -3
  38. package/dist/workbench/sessionTitle.js +2 -2
  39. package/package.json +15 -15
  40. package/dist/app/renderer/assets/commercial/registration-credits-bg.png +0 -0
  41. package/dist/chunk-4IJYTGS2.js.map +0 -1
  42. package/dist/chunk-62LWOH3P.js.map +0 -1
  43. package/dist/chunk-JZ6KUUDY.js.map +0 -1
  44. package/dist/chunk-RNBZBBI7.js.map +0 -1
  45. /package/dist/{AgentRichTextReadonly-WWU4ZF7W.js.map → AgentRichTextReadonly-TASIMIK4.js.map} +0 -0
  46. /package/dist/{chunk-POU5WZNH.js.map → chunk-2HYADTQP.js.map} +0 -0
  47. /package/dist/{chunk-JVVLKTLR.js.map → chunk-7SSORDQY.js.map} +0 -0
  48. /package/dist/{chunk-BGNYUYLP.js.map → chunk-AD2RTSMS.js.map} +0 -0
  49. /package/dist/{chunk-GXXPUEX6.js.map → chunk-BYHNJQYH.js.map} +0 -0
  50. /package/dist/{chunk-7LSLB7CN.js.map → chunk-G2QO6HPB.js.map} +0 -0
  51. /package/dist/{chunk-FRSV66P3.js.map → chunk-ISC67YBJ.js.map} +0 -0
  52. /package/dist/{chunk-YJ27WHM3.js.map → chunk-L4E2Y52A.js.map} +0 -0
  53. /package/dist/{chunk-WSIGQG7C.js.map → chunk-LQKLBDBK.js.map} +0 -0
  54. /package/dist/{chunk-4DAJ5SVX.js.map → chunk-XERDRMSF.js.map} +0 -0
  55. /package/dist/{chunk-JUL7J4VN.js.map → chunk-YBIT37P5.js.map} +0 -0
  56. /package/dist/{chunk-5UOJCDLE.js.map → chunk-ZNHMWCO4.js.map} +0 -0
@@ -6,7 +6,7 @@ import {
6
6
  setCurrentAgentGuiI18nRuntime,
7
7
  translate,
8
8
  translateInUiLanguage
9
- } from "./chunk-62LWOH3P.js";
9
+ } from "./chunk-QVLEP54U.js";
10
10
 
11
11
  // i18n/index.ts
12
12
  import React, {
@@ -68,4 +68,4 @@ export {
68
68
  AgentGuiI18nProvider,
69
69
  useTranslation
70
70
  };
71
- //# sourceMappingURL=chunk-GXXPUEX6.js.map
71
+ //# sourceMappingURL=chunk-BYHNJQYH.js.map
@@ -2,12 +2,12 @@ import {
2
2
  AgentRichTextReadonly,
3
3
  promptForProviderSkills,
4
4
  skillTriggerForPrefix
5
- } from "./chunk-7LSLB7CN.js";
5
+ } from "./chunk-G2QO6HPB.js";
6
6
  import {
7
7
  classifyRecoverableAgentMessage,
8
8
  resolveAgentErrorPresentation,
9
9
  useOpenAgentEnvPanel
10
- } from "./chunk-JZ6KUUDY.js";
10
+ } from "./chunk-N4HLBSMJ.js";
11
11
  import {
12
12
  isWorkspaceAgentSyntheticControlMessage
13
13
  } from "./chunk-XJ34OIEQ.js";
@@ -18,7 +18,7 @@ import {
18
18
  agentPromptFileBlocks,
19
19
  agentPromptPastedTextBlocks,
20
20
  materializeAgentComposerFileMentions
21
- } from "./chunk-POU5WZNH.js";
21
+ } from "./chunk-2HYADTQP.js";
22
22
  import {
23
23
  extractImageGenerationPreview,
24
24
  isImageGenerationToolCall,
@@ -46,7 +46,7 @@ import {
46
46
  resolveWorkspaceFileLinkAction,
47
47
  resolveWorkspaceFilePathCandidate,
48
48
  resolveWorkspaceLinkAction
49
- } from "./chunk-WSIGQG7C.js";
49
+ } from "./chunk-LQKLBDBK.js";
50
50
  import {
51
51
  cn
52
52
  } from "./chunk-ZVYUTXQJ.js";
@@ -54,7 +54,7 @@ import {
54
54
  useOptionalAgentActivityRuntime,
55
55
  useOptionalAgentHostApi,
56
56
  workspaceAgentProviderLabel
57
- } from "./chunk-JUL7J4VN.js";
57
+ } from "./chunk-YBIT37P5.js";
58
58
  import {
59
59
  fileChangeCountFromChanges,
60
60
  fileChangeEntriesFromChanges,
@@ -64,7 +64,7 @@ import {
64
64
  getActiveUiLanguage,
65
65
  translate,
66
66
  useTranslation
67
- } from "./chunk-GXXPUEX6.js";
67
+ } from "./chunk-BYHNJQYH.js";
68
68
  import {
69
69
  normalizeAgentTitleText
70
70
  } from "./chunk-MIJXEELH.js";
@@ -5582,21 +5582,21 @@ function AgentTranscriptSkeleton({
5582
5582
  );
5583
5583
  }
5584
5584
 
5585
- // shared/commerce/AgentCommercePresentationContext.tsx
5585
+ // shared/visibleError/AgentVisibleErrorPresentationContext.tsx
5586
5586
  import {
5587
5587
  createContext,
5588
5588
  useContext
5589
5589
  } from "react";
5590
5590
  import { jsx as jsx2 } from "react/jsx-runtime";
5591
- var AgentCommercePresentationContext = createContext(null);
5592
- function AgentCommercePresentationProvider({
5591
+ var AgentVisibleErrorPresentationContext = createContext(null);
5592
+ function AgentVisibleErrorPresentationProvider({
5593
5593
  children,
5594
5594
  value
5595
5595
  }) {
5596
- return /* @__PURE__ */ jsx2(AgentCommercePresentationContext.Provider, { value: value ?? null, children });
5596
+ return /* @__PURE__ */ jsx2(AgentVisibleErrorPresentationContext.Provider, { value: value ?? null, children });
5597
5597
  }
5598
- function useAgentCommercePresentation() {
5599
- return useContext(AgentCommercePresentationContext);
5598
+ function useAgentVisibleErrorPresentationOverrides() {
5599
+ return useContext(AgentVisibleErrorPresentationContext);
5600
5600
  }
5601
5601
 
5602
5602
  // shared/agentConversation/components/AgentTranscriptView.tsx
@@ -6671,19 +6671,18 @@ function AgentVisibleErrorMessage({
6671
6671
  }) {
6672
6672
  "use memo";
6673
6673
  const openAgentEnvPanel = useOpenAgentEnvPanel();
6674
- const commercePresentation = useAgentCommercePresentation();
6674
+ const presentationOverrides = useAgentVisibleErrorPresentationOverrides();
6675
6675
  const error = message.visibleError;
6676
6676
  const providerLabel = workspaceAgentProviderLabel(
6677
6677
  error?.provider ?? "unknown"
6678
6678
  );
6679
- const presentation = resolveAgentErrorPresentation(
6680
- error?.code,
6681
- commercePresentation
6682
- );
6683
- const headline = presentation?.messageKey ? translate(presentation.messageKey, { provider: providerLabel }) : visibleErrorTitle(message);
6679
+ const presentation = resolveAgentErrorPresentation(error?.code);
6680
+ const insufficientCreditsOverride = presentationOverrides?.insufficient_credits;
6681
+ const presentationOverride = error?.code === "insufficient_credits" && insufficientCreditsOverride?.providers.includes(error.provider ?? "") ? insufficientCreditsOverride : void 0;
6682
+ const headline = presentationOverride?.message || (presentation?.messageKey ? translate(presentation.messageKey, { provider: providerLabel }) : visibleErrorTitle(message));
6684
6683
  const focus = presentation?.focus ?? null;
6685
6684
  const actionKey = presentation?.actionKey ?? null;
6686
- const externalUrl = presentation?.externalUrl ?? null;
6685
+ const externalAction = presentationOverride?.action ?? null;
6687
6686
  const hint = visibleErrorHint(message);
6688
6687
  const isPlanOrQuotaLimit = error?.code === "quota_or_rate_limit" || error?.code === "insufficient_credits";
6689
6688
  return /* @__PURE__ */ jsx11(
@@ -6696,7 +6695,7 @@ function AgentVisibleErrorMessage({
6696
6695
  /* @__PURE__ */ jsx11("div", { className: "font-medium text-[var(--text-primary)]", children: headline }),
6697
6696
  hint ? /* @__PURE__ */ jsx11("div", { className: "mt-1 text-[11px] text-[var(--text-secondary)]", children: hint }) : null
6698
6697
  ] }),
6699
- actionKey && (focus && openAgentEnvPanel || externalUrl && onExternalLink) ? /* @__PURE__ */ jsx11(
6698
+ externalAction?.url && onExternalLink || actionKey && focus && openAgentEnvPanel ? /* @__PURE__ */ jsx11(
6700
6699
  Button,
6701
6700
  {
6702
6701
  type: "button",
@@ -6704,8 +6703,8 @@ function AgentVisibleErrorMessage({
6704
6703
  size: "sm",
6705
6704
  className: "mt-0.5 shrink-0",
6706
6705
  onClick: () => {
6707
- if (externalUrl) {
6708
- onExternalLink?.(externalUrl);
6706
+ if (externalAction?.url) {
6707
+ onExternalLink?.(externalAction.url);
6709
6708
  return;
6710
6709
  }
6711
6710
  if (focus && openAgentEnvPanel) {
@@ -6715,7 +6714,7 @@ function AgentVisibleErrorMessage({
6715
6714
  });
6716
6715
  }
6717
6716
  },
6718
- children: translate(actionKey)
6717
+ children: externalAction?.label || (actionKey ? translate(actionKey) : null)
6719
6718
  }
6720
6719
  ) : null
6721
6720
  ] })
@@ -15797,9 +15796,9 @@ export {
15797
15796
  loadCompleteAgentConversationMessages,
15798
15797
  serializeAgentConversationForClipboard,
15799
15798
  AgentTranscriptSkeleton,
15800
- AgentCommercePresentationProvider,
15799
+ AgentVisibleErrorPresentationProvider,
15801
15800
  AgentTranscriptView,
15802
15801
  AgentConversationFlow,
15803
15802
  useProjectedAgentConversation
15804
15803
  };
15805
- //# sourceMappingURL=chunk-RNBZBBI7.js.map
15804
+ //# sourceMappingURL=chunk-FEUU4YMY.js.map