@within-7/minto 0.3.6 → 0.3.9

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 (153) hide show
  1. package/{cli.js → cli.cjs} +25 -23
  2. package/dist/commands/language.js +137 -0
  3. package/dist/commands/language.js.map +7 -0
  4. package/dist/commands/new.js +56 -0
  5. package/dist/commands/new.js.map +7 -0
  6. package/dist/commands/resume.js +251 -16
  7. package/dist/commands/resume.js.map +2 -2
  8. package/dist/commands/sessions.js +224 -0
  9. package/dist/commands/sessions.js.map +7 -0
  10. package/dist/commands/setup.js +3 -2
  11. package/dist/commands/setup.js.map +2 -2
  12. package/dist/commands/stats.js +235 -0
  13. package/dist/commands/stats.js.map +7 -0
  14. package/dist/commands/status.js +11 -5
  15. package/dist/commands/status.js.map +2 -2
  16. package/dist/commands/undo.js +26 -16
  17. package/dist/commands/undo.js.map +2 -2
  18. package/dist/commands.js +6 -0
  19. package/dist/commands.js.map +2 -2
  20. package/dist/components/AskUserQuestionDialog/AskUserQuestionDialog.js +3 -2
  21. package/dist/components/AskUserQuestionDialog/AskUserQuestionDialog.js.map +2 -2
  22. package/dist/components/Config.js +9 -8
  23. package/dist/components/Config.js.map +2 -2
  24. package/dist/components/HeaderBar.js +2 -1
  25. package/dist/components/HeaderBar.js.map +2 -2
  26. package/dist/components/Help.js +2 -1
  27. package/dist/components/Help.js.map +2 -2
  28. package/dist/components/HotkeyHelpPanel.js +46 -44
  29. package/dist/components/HotkeyHelpPanel.js.map +2 -2
  30. package/dist/components/Logo.js +5 -2
  31. package/dist/components/Logo.js.map +2 -2
  32. package/dist/components/MCPServerApprovalDialog.js +6 -5
  33. package/dist/components/MCPServerApprovalDialog.js.map +2 -2
  34. package/dist/components/MCPServerMultiselectDialog.js +5 -4
  35. package/dist/components/MCPServerMultiselectDialog.js.map +2 -2
  36. package/dist/components/MessageSelector.js +4 -3
  37. package/dist/components/MessageSelector.js.map +2 -2
  38. package/dist/components/ModelConfig.js +13 -12
  39. package/dist/components/ModelConfig.js.map +2 -2
  40. package/dist/components/ModelListManager.js +4 -3
  41. package/dist/components/ModelListManager.js.map +2 -2
  42. package/dist/components/PromptInput.js +72 -39
  43. package/dist/components/PromptInput.js.map +2 -2
  44. package/dist/components/SensitiveFileWarning.js +12 -8
  45. package/dist/components/SensitiveFileWarning.js.map +2 -2
  46. package/dist/components/TabbedListView/ScrollableList.js +91 -0
  47. package/dist/components/TabbedListView/ScrollableList.js.map +7 -0
  48. package/dist/components/TabbedListView/SearchInput.js +23 -0
  49. package/dist/components/TabbedListView/SearchInput.js.map +7 -0
  50. package/dist/components/TabbedListView/TabBar.js +20 -0
  51. package/dist/components/TabbedListView/TabBar.js.map +7 -0
  52. package/dist/components/TabbedListView/TabbedListView.js +171 -0
  53. package/dist/components/TabbedListView/TabbedListView.js.map +7 -0
  54. package/dist/components/TabbedListView/index.js +11 -0
  55. package/dist/components/TabbedListView/index.js.map +7 -0
  56. package/dist/components/TabbedListView/types.js +1 -0
  57. package/dist/components/TabbedListView/types.js.map +7 -0
  58. package/dist/components/TodoChangeBlock.js +6 -5
  59. package/dist/components/TodoChangeBlock.js.map +3 -3
  60. package/dist/components/TodoPanel.js +6 -3
  61. package/dist/components/TodoPanel.js.map +3 -3
  62. package/dist/components/TrustDialog.js +6 -5
  63. package/dist/components/TrustDialog.js.map +2 -2
  64. package/dist/components/messages/UserToolResultMessage/UserToolCanceledMessage.js +2 -1
  65. package/dist/components/messages/UserToolResultMessage/UserToolCanceledMessage.js.map +2 -2
  66. package/dist/constants/macros.js +1 -1
  67. package/dist/constants/macros.js.map +1 -1
  68. package/dist/constants/product.js +2 -2
  69. package/dist/constants/product.js.map +1 -1
  70. package/dist/constants/prompts.js +17 -0
  71. package/dist/constants/prompts.js.map +2 -2
  72. package/dist/constants/toolInputExamples.js +5 -1
  73. package/dist/constants/toolInputExamples.js.map +2 -2
  74. package/dist/core/tokenStatsManager.js +5 -0
  75. package/dist/core/tokenStatsManager.js.map +2 -2
  76. package/dist/entrypoints/bootstrap.js +54 -0
  77. package/dist/entrypoints/bootstrap.js.map +7 -0
  78. package/dist/entrypoints/cli.js +132 -23
  79. package/dist/entrypoints/cli.js.map +3 -3
  80. package/dist/history.js +75 -15
  81. package/dist/history.js.map +2 -2
  82. package/dist/i18n/index.js +2 -2
  83. package/dist/i18n/index.js.map +2 -2
  84. package/dist/i18n/locales/en.js +283 -1
  85. package/dist/i18n/locales/en.js.map +2 -2
  86. package/dist/i18n/locales/zh-CN.js +283 -1
  87. package/dist/i18n/locales/zh-CN.js.map +2 -2
  88. package/dist/i18n/types.js.map +1 -1
  89. package/dist/index.js +1 -1
  90. package/dist/index.js.map +2 -2
  91. package/dist/messages.js +11 -0
  92. package/dist/messages.js.map +2 -2
  93. package/dist/permissions.js.map +2 -2
  94. package/dist/query.js +9 -0
  95. package/dist/query.js.map +2 -2
  96. package/dist/screens/REPL.js +45 -7
  97. package/dist/screens/REPL.js.map +2 -2
  98. package/dist/services/customCommands.js +14 -8
  99. package/dist/services/customCommands.js.map +2 -2
  100. package/dist/tools/TaskTool/TaskTool.js +176 -1
  101. package/dist/tools/TaskTool/TaskTool.js.map +2 -2
  102. package/dist/tools/TodoWriteTool/prompt.js +21 -0
  103. package/dist/tools/TodoWriteTool/prompt.js.map +2 -2
  104. package/dist/tools/URLFetcherTool/prompt.js +14 -9
  105. package/dist/tools/URLFetcherTool/prompt.js.map +2 -2
  106. package/dist/tools/WebSearchTool/prompt.js +12 -6
  107. package/dist/tools/WebSearchTool/prompt.js.map +2 -2
  108. package/dist/types/PermissionMode.js +30 -1
  109. package/dist/types/PermissionMode.js.map +2 -2
  110. package/dist/types/plugin.js.map +2 -2
  111. package/dist/utils/agentHookExecutor.js +106 -0
  112. package/dist/utils/agentHookExecutor.js.map +7 -0
  113. package/dist/utils/agentLoader.js +212 -26
  114. package/dist/utils/agentLoader.js.map +2 -2
  115. package/dist/utils/agentMemory.js +134 -0
  116. package/dist/utils/agentMemory.js.map +7 -0
  117. package/dist/utils/config.js +51 -1
  118. package/dist/utils/config.js.map +2 -2
  119. package/dist/utils/configPaths.js +199 -0
  120. package/dist/utils/configPaths.js.map +7 -0
  121. package/dist/utils/historyManager.js +234 -0
  122. package/dist/utils/historyManager.js.map +7 -0
  123. package/dist/utils/messages.js +13 -8
  124. package/dist/utils/messages.js.map +2 -2
  125. package/dist/utils/migration/index.js +37 -0
  126. package/dist/utils/migration/index.js.map +7 -0
  127. package/dist/utils/migration/migrateHistory.js +273 -0
  128. package/dist/utils/migration/migrateHistory.js.map +7 -0
  129. package/dist/utils/migration/migrateTodos.js +323 -0
  130. package/dist/utils/migration/migrateTodos.js.map +7 -0
  131. package/dist/utils/pasteCache.js +309 -0
  132. package/dist/utils/pasteCache.js.map +7 -0
  133. package/dist/utils/pluginLoader.js +6 -3
  134. package/dist/utils/pluginLoader.js.map +2 -2
  135. package/dist/utils/sessionIndex.js +192 -0
  136. package/dist/utils/sessionIndex.js.map +7 -0
  137. package/dist/utils/sessionTracker.js +170 -0
  138. package/dist/utils/sessionTracker.js.map +7 -0
  139. package/dist/utils/skillLoader.js +91 -5
  140. package/dist/utils/skillLoader.js.map +2 -2
  141. package/dist/utils/stats.js +417 -0
  142. package/dist/utils/stats.js.map +7 -0
  143. package/dist/utils/stringSubstitution.js +107 -0
  144. package/dist/utils/stringSubstitution.js.map +7 -0
  145. package/dist/utils/teamConfig.js +3 -1
  146. package/dist/utils/teamConfig.js.map +2 -2
  147. package/dist/utils/todoStorage.js +51 -19
  148. package/dist/utils/todoStorage.js.map +2 -2
  149. package/dist/utils/tooling/safeRender.js.map +2 -2
  150. package/dist/version.js +2 -2
  151. package/dist/version.js.map +1 -1
  152. package/package.json +71 -28
  153. package/scripts/{postinstall.js → postinstall.cjs} +1 -1
@@ -5,6 +5,10 @@ import { useArrowKeyHistory } from "../hooks/useArrowKeyHistory.js";
5
5
  import { useUnifiedCompletion } from "../hooks/useUnifiedCompletion.js";
6
6
  import { useHistorySearch } from "../hooks/useHistorySearch.js";
7
7
  import { addToHistory, getHistory } from "../history.js";
8
+ import {
9
+ cachePaste,
10
+ createPlaceholder
11
+ } from "../utils/pasteCache.js";
8
12
  import TextInput from "./TextInput.js";
9
13
  import { HistorySearchOverlay } from "./HistorySearchOverlay.js";
10
14
  import {
@@ -33,6 +37,7 @@ import { usePermissionContext } from "../context/PermissionContext.js";
33
37
  import { getHookManager } from "../utils/hookManager.js";
34
38
  import { debug as debugLogger } from "../utils/debugLogger.js";
35
39
  import { PROJECT_FILE } from "../constants/product.js";
40
+ import { t } from "../i18n/index.js";
36
41
  async function interpretHashCommand(input) {
37
42
  try {
38
43
  const { queryQuick } = await import("../services/claude.js");
@@ -101,7 +106,9 @@ function PromptInput({
101
106
  queuedPrompts = [],
102
107
  onQueuePrompt,
103
108
  onPopQueuedPrompt,
104
- onInterrupt
109
+ onInterrupt,
110
+ isOverlayActive = false,
111
+ unmount
105
112
  }) {
106
113
  const [exitMessage, setExitMessage] = useState({ show: false });
107
114
  const [message, setMessage] = useState({
@@ -338,7 +345,9 @@ function PromptInput({
338
345
  abortController: abortController || new AbortController(),
339
346
  // Temporary controller, actual one created in onQuery
340
347
  readFileTimestamps,
341
- setForkConvoWithMessagesOnTheNextRender
348
+ setForkConvoWithMessagesOnTheNextRender,
349
+ unmount: unmount || (() => {
350
+ })
342
351
  },
343
352
  pastedImage ?? null
344
353
  );
@@ -427,7 +436,9 @@ function PromptInput({
427
436
  messageId: void 0,
428
437
  abortController: newAbortController,
429
438
  readFileTimestamps,
430
- setForkConvoWithMessagesOnTheNextRender
439
+ setForkConvoWithMessagesOnTheNextRender,
440
+ unmount: unmount || (() => {
441
+ })
431
442
  },
432
443
  pastedImage ?? null
433
444
  );
@@ -452,7 +463,17 @@ function PromptInput({
452
463
  }
453
464
  function onTextPaste(rawText) {
454
465
  const text = rawText.replace(/\r/g, "\n");
455
- const pastedPrompt = getPastedTextPrompt(text);
466
+ const cacheEntry = cachePaste(text);
467
+ let pastedPrompt;
468
+ if (cacheEntry) {
469
+ pastedPrompt = createPlaceholder(cacheEntry);
470
+ debugLogger.trace("PASTE_CACHED", {
471
+ length: text.length,
472
+ hash: cacheEntry.hash.slice(0, 8)
473
+ });
474
+ } else {
475
+ pastedPrompt = getPastedTextPrompt(text);
476
+ }
456
477
  const newInput = input.slice(0, cursorOffset) + pastedPrompt + input.slice(cursorOffset);
457
478
  onInputChange(newInput);
458
479
  setCursorOffset(cursorOffset + pastedPrompt.length);
@@ -469,15 +490,18 @@ function PromptInput({
469
490
  setIsLoading(false);
470
491
  setHotkeyMessage({
471
492
  show: true,
472
- text: "Interrupted by user (Ctrl-C)"
493
+ text: t("prompts.interruptedCtrlC")
473
494
  });
474
495
  setTimeout(() => setHotkeyMessage({ show: false }), 2e3);
475
496
  } else if (input.length > 0) {
476
497
  onInputChange("");
477
- setHotkeyMessage({ show: true, text: "Input cleared" });
498
+ setHotkeyMessage({ show: true, text: t("prompts.inputCleared") });
478
499
  setTimeout(() => setHotkeyMessage({ show: false }), 1e3);
479
500
  } else {
480
- setHotkeyMessage({ show: true, text: "Press Ctrl-D to exit" });
501
+ setHotkeyMessage({
502
+ show: true,
503
+ text: t("prompts.pressCtrlDToExit")
504
+ });
481
505
  setTimeout(() => setHotkeyMessage({ show: false }), 2e3);
482
506
  }
483
507
  return true;
@@ -485,7 +509,10 @@ function PromptInput({
485
509
  if (key.ctrl && inputChar === "d") {
486
510
  if (input.length > 0) {
487
511
  onInputChange("");
488
- setHotkeyMessage({ show: true, text: "Input cleared (Ctrl-D)" });
512
+ setHotkeyMessage({
513
+ show: true,
514
+ text: t("prompts.inputClearedCtrlD")
515
+ });
489
516
  setTimeout(() => setHotkeyMessage({ show: false }), 1e3);
490
517
  return true;
491
518
  }
@@ -494,12 +521,15 @@ function PromptInput({
494
521
  const timer = setTimeout(() => setCtrlDCount(0), 1e3);
495
522
  setCtrlDTimer(timer);
496
523
  if (ctrlDCount >= 1) {
497
- setHotkeyMessage({ show: true, text: "Exiting gracefully..." });
524
+ setHotkeyMessage({
525
+ show: true,
526
+ text: t("prompts.exitingGracefully")
527
+ });
498
528
  setTimeout(() => exit(), 500);
499
529
  } else {
500
530
  setHotkeyMessage({
501
531
  show: true,
502
- text: "Press Ctrl-D again to exit"
532
+ text: t("prompts.pressCtrlDAgain")
503
533
  });
504
534
  setTimeout(() => setHotkeyMessage({ show: false }), 2e3);
505
535
  }
@@ -507,7 +537,7 @@ function PromptInput({
507
537
  }
508
538
  if (key.ctrl && inputChar === "l") {
509
539
  clearScreen();
510
- setHotkeyMessage({ show: true, text: "Screen cleared (Ctrl-L)" });
540
+ setHotkeyMessage({ show: true, text: t("prompts.screenCleared") });
511
541
  setTimeout(() => setHotkeyMessage({ show: false }), 1e3);
512
542
  return true;
513
543
  }
@@ -533,7 +563,7 @@ function PromptInput({
533
563
  onToggleTodoPanel();
534
564
  setHotkeyMessage({
535
565
  show: true,
536
- text: "TodoPanel toggled (Ctrl-T)"
566
+ text: t("prompts.todoPanelToggled")
537
567
  });
538
568
  setTimeout(() => setHotkeyMessage({ show: false }), 2e3);
539
569
  }
@@ -543,7 +573,7 @@ function PromptInput({
543
573
  if (!input || input.trim().length === 0) {
544
574
  setHotkeyMessage({
545
575
  show: true,
546
- text: "Type a command first, then press Ctrl-B"
576
+ text: t("prompts.typeCommandFirst")
547
577
  });
548
578
  setTimeout(() => setHotkeyMessage({ show: false }), 2e3);
549
579
  return true;
@@ -551,7 +581,7 @@ function PromptInput({
551
581
  if (mode === "bash") {
552
582
  setHotkeyMessage({
553
583
  show: true,
554
- text: "Executing bash command... (Ctrl-B)"
584
+ text: t("prompts.executingBash")
555
585
  });
556
586
  setTimeout(() => setHotkeyMessage({ show: false }), 1e3);
557
587
  onSubmit(input);
@@ -659,7 +689,7 @@ function PromptInput({
659
689
  });
660
690
  setMessage({
661
691
  show: true,
662
- text: `Thinking mode ${newThinking ? "enabled" : "disabled"} (Tab)`
692
+ text: newThinking ? t("prompts.thinkingModeEnabled") : t("prompts.thinkingModeDisabled")
663
693
  });
664
694
  setTimeout(() => setMessage({ show: false }), 2e3);
665
695
  return true;
@@ -688,14 +718,17 @@ function PromptInput({
688
718
  setEscCount(0);
689
719
  if (input.length > 0) {
690
720
  onInputChange("");
691
- setHotkeyMessage({ show: true, text: "Input cleared (Esc Esc)" });
721
+ setHotkeyMessage({
722
+ show: true,
723
+ text: t("prompts.inputClearedEscEsc")
724
+ });
692
725
  setTimeout(() => setHotkeyMessage({ show: false }), 1e3);
693
726
  return true;
694
727
  } else if (isLoading && onInterrupt) {
695
728
  onInterrupt();
696
729
  setHotkeyMessage({
697
730
  show: true,
698
- text: "Interrupted by user (Esc Esc)"
731
+ text: t("prompts.interruptedEscEsc")
699
732
  });
700
733
  setTimeout(() => setHotkeyMessage({ show: false }), 2e3);
701
734
  return true;
@@ -704,12 +737,12 @@ function PromptInput({
704
737
  if (input.length > 0) {
705
738
  setHotkeyMessage({
706
739
  show: true,
707
- text: "Press Esc again to clear input"
740
+ text: t("prompts.pressEscAgainClear")
708
741
  });
709
742
  } else if (isLoading) {
710
743
  setHotkeyMessage({
711
744
  show: true,
712
- text: "Press Esc again to interrupt"
745
+ text: t("prompts.pressEscAgainInterrupt")
713
746
  });
714
747
  }
715
748
  setTimeout(() => setHotkeyMessage({ show: false }), 1500);
@@ -748,7 +781,7 @@ function PromptInput({
748
781
  currentTokens: tokenUsage
749
782
  };
750
783
  }, [tokenUsage, modelSwitchMessage.show, submitCount, currentModelId]);
751
- return /* @__PURE__ */ React.createElement(Box, { flexDirection: "column" }, fallbackMode && /* @__PURE__ */ React.createElement(Box, { marginBottom: 1 }, /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.running }, "\u26A0\uFE0F Limited input mode"), /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, " ", "(Advanced keyboard shortcuts unavailable - raw mode not supported)")), showHotkeyHelp && /* @__PURE__ */ React.createElement(
784
+ return /* @__PURE__ */ React.createElement(Box, { flexDirection: "column" }, fallbackMode && /* @__PURE__ */ React.createElement(Box, { marginBottom: 1 }, /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.running }, t("prompts.limitedInputMode")), /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, " ", "(", t("prompts.limitedInputModeDetail"), ")")), showHotkeyHelp && /* @__PURE__ */ React.createElement(
752
785
  HotkeyHelpPanel,
753
786
  {
754
787
  isVisible: showHotkeyHelp,
@@ -761,7 +794,7 @@ function PromptInput({
761
794
  results: historySearch.filteredResults,
762
795
  selectedIndex: historySearch.selectedIndex
763
796
  }
764
- ), modelInfo && /* @__PURE__ */ React.createElement(Box, { justifyContent: "flex-end", marginBottom: 1 }, /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, /* @__PURE__ */ React.createElement(Text, { color: BRAND_GRADIENT.START }, "\u25C6"), " ", /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.secondary }, modelInfo.name), /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, " ", "\xB7 ", Math.round(modelInfo.currentTokens / 1e3), "k /", " ", Math.round(modelInfo.contextLength / 1e3), "k"))), queuedPrompts.length > 0 && /* @__PURE__ */ React.createElement(Box, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React.createElement(Box, { paddingLeft: 2 }, /* @__PURE__ */ React.createElement(Text, { color: BRAND_GRADIENT.MIDDLE }, "\u2500\u2500 Queued (", queuedPrompts.length, ")"), /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, " ", "\xB7 will run after current task \xB7", " ", /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.secondary }, "\u2191"), " to edit \u2500\u2500")), queuedPrompts.map((prompt, index) => /* @__PURE__ */ React.createElement(Box, { key: index, paddingLeft: 2 }, /* @__PURE__ */ React.createElement(Text, { color: BRAND_GRADIENT.START }, "\u25C7 "), /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.secondary }, prompt.length > 60 ? prompt.slice(0, 60) + "..." : prompt)))), /* @__PURE__ */ React.createElement(
797
+ ), modelInfo && /* @__PURE__ */ React.createElement(Box, { justifyContent: "flex-end", marginBottom: 1 }, /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, /* @__PURE__ */ React.createElement(Text, { color: BRAND_GRADIENT.START }, "\u25C6"), " ", /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.secondary }, modelInfo.name), /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, " ", "\xB7 ", Math.round(modelInfo.currentTokens / 1e3), "k /", " ", Math.round(modelInfo.contextLength / 1e3), "k"))), queuedPrompts.length > 0 && /* @__PURE__ */ React.createElement(Box, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React.createElement(Box, { paddingLeft: 2 }, /* @__PURE__ */ React.createElement(Text, { color: BRAND_GRADIENT.MIDDLE }, "\u2500\u2500 ", t("ui.hints.queued"), " (", queuedPrompts.length, ")"), /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, " ", "\xB7 ", t("ui.hints.willRunAfter"), " \xB7", " ", /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.secondary }, "\u2191"), " ", t("ui.hints.toEdit"), " \u2500\u2500")), queuedPrompts.map((prompt, index) => /* @__PURE__ */ React.createElement(Box, { key: index, paddingLeft: 2 }, /* @__PURE__ */ React.createElement(Text, { color: BRAND_GRADIENT.START }, "\u25C7 "), /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.secondary }, prompt.length > 60 ? prompt.slice(0, 60) + "..." : prompt)))), /* @__PURE__ */ React.createElement(
765
798
  Box,
766
799
  {
767
800
  alignItems: "flex-start",
@@ -798,7 +831,7 @@ function PromptInput({
798
831
  TextInput,
799
832
  {
800
833
  multiline: true,
801
- focus: !isBackgroundPanelOpen && (!isLoading || !!onQueuePrompt),
834
+ focus: !isBackgroundPanelOpen && !isOverlayActive && (!isLoading || !!onQueuePrompt),
802
835
  onSubmit,
803
836
  onChange,
804
837
  value: input,
@@ -827,7 +860,7 @@ function PromptInput({
827
860
  paddingX: 2,
828
861
  paddingY: 0
829
862
  },
830
- /* @__PURE__ */ React.createElement(Box, { justifyContent: "flex-start", gap: 1 }, exitMessage.show ? /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, "Press", " ", /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.secondary }, exitMessage.key), " ", "again to exit") : message.show ? /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, message.text) : hotkeyMessage.show ? /* @__PURE__ */ React.createElement(Text, { color: BRAND_GRADIENT.START }, hotkeyMessage.text) : modelSwitchMessage.show ? /* @__PURE__ */ React.createElement(Text, { color: BRAND_GRADIENT.START }, modelSwitchMessage.text) : verbose ? (
863
+ /* @__PURE__ */ React.createElement(Box, { justifyContent: "flex-start", gap: 1 }, exitMessage.show ? /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, t("prompts.pressCtrlDAgain")) : message.show ? /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, message.text) : hotkeyMessage.show ? /* @__PURE__ */ React.createElement(Text, { color: BRAND_GRADIENT.START }, hotkeyMessage.text) : modelSwitchMessage.show ? /* @__PURE__ */ React.createElement(Text, { color: BRAND_GRADIENT.START }, modelSwitchMessage.text) : verbose ? (
831
864
  // Verbose mode: full static hints (商务用户友好) - 使用品牌配色
832
865
  /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
833
866
  Text,
@@ -842,7 +875,7 @@ function PromptInput({
842
875
  "!"
843
876
  ),
844
877
  " ",
845
- "\u6267\u884C\u547D\u4EE4"
878
+ t("ui.hints.executeCommand")
846
879
  ), /* @__PURE__ */ React.createElement(
847
880
  Text,
848
881
  {
@@ -858,8 +891,8 @@ function PromptInput({
858
891
  "#"
859
892
  ),
860
893
  " ",
861
- "\u8BB0\u5F55\u7B14\u8BB0"
862
- ), /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, "\xB7 ", /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.secondary }, "/"), " \u529F\u80FD\u83DC\u5355 \xB7", " ", /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.secondary }, "ctrl+?"), " \u5E2E\u52A9"), backgroundShellCount > 0 && /* @__PURE__ */ React.createElement(
894
+ t("ui.hints.recordNote")
895
+ ), /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, "\xB7 ", /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.secondary }, "/"), " ", t("ui.hints.featureMenu"), " \xB7", " ", /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.secondary }, "ctrl+?"), " ", t("common.help")), backgroundShellCount > 0 && /* @__PURE__ */ React.createElement(
863
896
  Text,
864
897
  {
865
898
  color: backgroundIndicatorFocused ? BRAND_GRADIENT.START : BRAND_GRADIENT.MIDDLE,
@@ -867,10 +900,10 @@ function PromptInput({
867
900
  },
868
901
  "\xB7 ",
869
902
  backgroundIndicatorFocused ? "\u25BA " : "",
870
- backgroundShellCount,
871
- " background task",
872
- backgroundShellCount > 1 ? "s" : ""
873
- ), queuedPrompts.length > 0 && /* @__PURE__ */ React.createElement(Text, { color: BRAND_GRADIENT.MIDDLE }, "\xB7 \u{1F4CB} ", queuedPrompts.length, " queued"))
903
+ t("ui.hints.backgroundTasks", {
904
+ count: backgroundShellCount
905
+ })
906
+ ), queuedPrompts.length > 0 && /* @__PURE__ */ React.createElement(Text, { color: BRAND_GRADIENT.MIDDLE }, "\xB7 \u{1F4CB} ", queuedPrompts.length, " ", t("ui.hints.queued")))
874
907
  ) : (
875
908
  // Normal mode: context-aware hints with 0.1.7 style
876
909
  /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(ContextAwareHints, { context: inputContext, compact: true }), backgroundShellCount > 0 && /* @__PURE__ */ React.createElement(
@@ -881,15 +914,15 @@ function PromptInput({
881
914
  },
882
915
  "\u2502 ",
883
916
  backgroundIndicatorFocused ? "\u25BA " : "",
884
- backgroundShellCount,
885
- " task",
886
- backgroundShellCount > 1 ? "s" : ""
887
- ), queuedPrompts.length > 0 && /* @__PURE__ */ React.createElement(Text, { color: BRAND_GRADIENT.MIDDLE }, "\u2502 \u{1F4CB} ", queuedPrompts.length, " queued"), isLoading && onQueuePrompt && queuedPrompts.length === 0 && /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, "\u2502 Type to queue next prompt"))
917
+ t("ui.hints.backgroundTasks", {
918
+ count: backgroundShellCount
919
+ })
920
+ ), queuedPrompts.length > 0 && /* @__PURE__ */ React.createElement(Text, { color: BRAND_GRADIENT.MIDDLE }, "\u2502 \u{1F4CB} ", queuedPrompts.length, " ", t("ui.hints.queued")), isLoading && onQueuePrompt && queuedPrompts.length === 0 && /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, "\u2502 ", t("ui.hints.typeToQueue")))
888
921
  )),
889
922
  /* @__PURE__ */ React.createElement(
890
923
  SentryErrorBoundary,
891
924
  {
892
- children: /* @__PURE__ */ React.createElement(Box, { justifyContent: "flex-end", gap: 1 }, !debug && tokenUsage < WARNING_THRESHOLD && /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.secondary }, terminalSetup.isEnabled && isShiftEnterKeyBindingInstalled() ? "shift + \u23CE" : "\\\u23CE"), " ", "for newline"), /* @__PURE__ */ React.createElement(TokenWarning, { tokenUsage }))
925
+ children: /* @__PURE__ */ React.createElement(Box, { justifyContent: "flex-end", gap: 1 }, !debug && tokenUsage < WARNING_THRESHOLD && /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.dim }, /* @__PURE__ */ React.createElement(Text, { color: SEMANTIC_COLORS.secondary }, terminalSetup.isEnabled && isShiftEnterKeyBindingInstalled() ? "shift + \u23CE" : "\\\u23CE"), " ", t("ui.hints.forNewline")), /* @__PURE__ */ React.createElement(TokenWarning, { tokenUsage }))
893
926
  }
894
927
  )
895
928
  ), suggestions.length > 0 && /* @__PURE__ */ React.createElement(
@@ -917,14 +950,14 @@ function PromptInput({
917
950
  const selected = suggestions[selectedIndex];
918
951
  const positionInfo = suggestions.length > 1 ? `[${selectedIndex + 1}/${suggestions.length}] ` : "";
919
952
  if (!selected) {
920
- return `${positionInfo}\u2191\u2193 navigate \u2022 \u2192 accept \u2022 Tab cycle \u2022 Esc close`;
953
+ return `${positionInfo}${t("ui.hints.completion.navigate")}`;
921
954
  }
922
955
  if (selected?.value.endsWith("/")) {
923
- return `${positionInfo}\u2192 enter directory \u2022 \u2191\u2193 navigate \u2022 Tab cycle \u2022 Esc close`;
956
+ return `${positionInfo}${t("ui.hints.completion.enterDirectory")}`;
924
957
  } else if (selected?.type === "agent") {
925
- return `${positionInfo}\u2192 select agent \u2022 \u2191\u2193 navigate \u2022 Tab cycle \u2022 Esc close`;
958
+ return `${positionInfo}${t("ui.hints.completion.selectAgent")}`;
926
959
  } else {
927
- return `${positionInfo}\u2192 insert reference \u2022 \u2191\u2193 navigate \u2022 Tab cycle \u2022 Esc close`;
960
+ return `${positionInfo}${t("ui.hints.completion.insertReference")}`;
928
961
  }
929
962
  })()
930
963
  )