@wahack/pi-coding-agent 15.11.3 → 15.11.5

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 (185) hide show
  1. package/package.json +28 -5
  2. package/src/autoresearch/dashboard.ts +1 -1
  3. package/src/autoresearch/index.ts +1 -1
  4. package/src/autoresearch/tools/init-experiment.ts +1 -1
  5. package/src/autoresearch/tools/log-experiment.ts +1 -1
  6. package/src/autoresearch/tools/run-experiment.ts +1 -1
  7. package/src/autoresearch/tools/update-notes.ts +1 -1
  8. package/src/cli/claude-trace-cli.ts +1 -1
  9. package/src/cli/dry-balance-cli.ts +1 -1
  10. package/src/cli/gallery-cli.ts +1 -1
  11. package/src/cli/gallery-fixtures/shell.ts +1 -1
  12. package/src/cli/grep-cli.ts +1 -1
  13. package/src/cli/list-models.ts +1 -1
  14. package/src/cli/session-picker.ts +1 -1
  15. package/src/cli/shell-cli.ts +1 -1
  16. package/src/cli/update-cli.ts +1 -1
  17. package/src/commands/grep.ts +1 -1
  18. package/src/commit/agentic/agent.ts +1 -1
  19. package/src/config/keybindings.ts +2 -2
  20. package/src/config/model-resolver.ts +1 -1
  21. package/src/config/resolve-config-value.ts +1 -1
  22. package/src/debug/index.ts +2 -2
  23. package/src/debug/log-viewer.ts +1 -1
  24. package/src/debug/protocol-probe.ts +1 -1
  25. package/src/debug/raw-sse.ts +1 -1
  26. package/src/debug/report-bundle.ts +1 -1
  27. package/src/debug/terminal-info.ts +1 -1
  28. package/src/discovery/helpers.ts +1 -1
  29. package/src/edit/hashline/block-resolver.ts +1 -1
  30. package/src/edit/normalize.ts +1 -1
  31. package/src/edit/renderer.ts +2 -2
  32. package/src/exec/bash-executor.ts +1 -1
  33. package/src/export/ttsr.ts +1 -1
  34. package/src/extensibility/custom-commands/loader.ts +1 -1
  35. package/src/extensibility/custom-tools/loader.ts +2 -2
  36. package/src/extensibility/custom-tools/types.ts +1 -1
  37. package/src/extensibility/extensions/loader.ts +2 -2
  38. package/src/extensibility/extensions/runner.ts +1 -1
  39. package/src/extensibility/extensions/types.ts +2 -2
  40. package/src/extensibility/hooks/loader.ts +1 -1
  41. package/src/extensibility/hooks/types.ts +1 -1
  42. package/src/extensibility/plugins/legacy-pi-compat.ts +1 -1
  43. package/src/extensibility/slash-commands.ts +1 -1
  44. package/src/goals/tools/goal-tool.ts +2 -2
  45. package/src/index.ts +1 -1
  46. package/src/lite.ts +10 -0
  47. package/src/lsp/render.ts +2 -2
  48. package/src/mcp/render.ts +2 -2
  49. package/src/modes/components/agent-dashboard.ts +1 -1
  50. package/src/modes/components/agent-hub.ts +1 -1
  51. package/src/modes/components/assistant-message.ts +1 -1
  52. package/src/modes/components/bash-execution.ts +1 -1
  53. package/src/modes/components/bordered-loader.ts +1 -1
  54. package/src/modes/components/branch-summary-message.ts +1 -1
  55. package/src/modes/components/btw-panel.ts +1 -1
  56. package/src/modes/components/chat-block.ts +1 -1
  57. package/src/modes/components/compaction-summary-message.ts +1 -1
  58. package/src/modes/components/copy-selector.ts +1 -1
  59. package/src/modes/components/countdown-timer.ts +1 -1
  60. package/src/modes/components/custom-editor.ts +1 -1
  61. package/src/modes/components/custom-message.ts +2 -2
  62. package/src/modes/components/dynamic-border.ts +1 -1
  63. package/src/modes/components/error-banner.ts +1 -1
  64. package/src/modes/components/eval-execution.ts +1 -1
  65. package/src/modes/components/execution-shared.ts +1 -1
  66. package/src/modes/components/extensions/extension-dashboard.ts +1 -1
  67. package/src/modes/components/extensions/extension-list.ts +1 -1
  68. package/src/modes/components/extensions/inspector-panel.ts +1 -1
  69. package/src/modes/components/extensions/state-manager.ts +1 -1
  70. package/src/modes/components/footer.ts +1 -1
  71. package/src/modes/components/history-search.ts +1 -1
  72. package/src/modes/components/hook-editor.ts +1 -1
  73. package/src/modes/components/hook-input.ts +1 -1
  74. package/src/modes/components/hook-message.ts +2 -2
  75. package/src/modes/components/hook-selector.ts +1 -1
  76. package/src/modes/components/keybinding-hints.ts +1 -1
  77. package/src/modes/components/late-diagnostics-message.ts +1 -1
  78. package/src/modes/components/login-dialog.ts +1 -1
  79. package/src/modes/components/mcp-add-wizard.ts +1 -1
  80. package/src/modes/components/message-frame.ts +2 -2
  81. package/src/modes/components/model-selector.ts +1 -1
  82. package/src/modes/components/oauth-selector.ts +1 -1
  83. package/src/modes/components/omfg-panel.ts +1 -1
  84. package/src/modes/components/overlay-box.ts +1 -1
  85. package/src/modes/components/plan-review-overlay.ts +1 -1
  86. package/src/modes/components/plugin-selector.ts +1 -1
  87. package/src/modes/components/plugin-settings.ts +1 -1
  88. package/src/modes/components/queue-mode-selector.ts +1 -1
  89. package/src/modes/components/read-tool-group.ts +2 -2
  90. package/src/modes/components/session-selector.ts +1 -1
  91. package/src/modes/components/settings-defs.ts +1 -1
  92. package/src/modes/components/settings-selector.ts +1 -1
  93. package/src/modes/components/show-images-selector.ts +1 -1
  94. package/src/modes/components/skill-message.ts +2 -2
  95. package/src/modes/components/status-line/component.ts +1 -1
  96. package/src/modes/components/status-line/segments.ts +1 -1
  97. package/src/modes/components/theme-selector.ts +1 -1
  98. package/src/modes/components/thinking-selector.ts +1 -1
  99. package/src/modes/components/tiny-title-download-progress.ts +1 -1
  100. package/src/modes/components/todo-reminder.ts +1 -1
  101. package/src/modes/components/tool-execution.ts +1 -1
  102. package/src/modes/components/transcript-container.ts +1 -1
  103. package/src/modes/components/tree-selector.ts +1 -1
  104. package/src/modes/components/ttsr-notification.ts +1 -1
  105. package/src/modes/components/user-message-selector.ts +1 -1
  106. package/src/modes/components/user-message.ts +1 -1
  107. package/src/modes/components/visual-truncate.ts +1 -1
  108. package/src/modes/components/welcome.ts +1 -1
  109. package/src/modes/controllers/command-controller-shared.ts +1 -1
  110. package/src/modes/controllers/command-controller.ts +1 -1
  111. package/src/modes/controllers/event-controller.ts +1 -1
  112. package/src/modes/controllers/extension-ui-controller.ts +2 -2
  113. package/src/modes/controllers/input-controller.ts +1 -1
  114. package/src/modes/controllers/mcp-command-controller.ts +1 -1
  115. package/src/modes/controllers/selector-controller.ts +2 -2
  116. package/src/modes/controllers/streaming-reveal.ts +1 -1
  117. package/src/modes/emoji-autocomplete.ts +1 -1
  118. package/src/modes/index.ts +1 -1
  119. package/src/modes/interactive-mode.ts +2 -2
  120. package/src/modes/internal-url-autocomplete.ts +1 -1
  121. package/src/modes/prompt-action-autocomplete.ts +1 -1
  122. package/src/modes/setup-wizard/scenes/glyph.ts +1 -1
  123. package/src/modes/setup-wizard/scenes/outro.ts +1 -1
  124. package/src/modes/setup-wizard/scenes/providers.ts +1 -1
  125. package/src/modes/setup-wizard/scenes/sign-in.ts +1 -1
  126. package/src/modes/setup-wizard/scenes/splash.ts +1 -1
  127. package/src/modes/setup-wizard/scenes/theme.ts +1 -1
  128. package/src/modes/setup-wizard/scenes/types.ts +1 -1
  129. package/src/modes/setup-wizard/scenes/web-search.ts +1 -1
  130. package/src/modes/setup-wizard/wizard-overlay.ts +1 -1
  131. package/src/modes/shared.ts +1 -1
  132. package/src/modes/theme/theme.ts +3 -3
  133. package/src/modes/types.ts +1 -1
  134. package/src/modes/utils/context-usage.ts +1 -1
  135. package/src/modes/utils/keybinding-matchers.ts +1 -1
  136. package/src/modes/utils/ui-helpers.ts +1 -1
  137. package/src/sdk.ts +1 -1
  138. package/src/session/agent-session.ts +1 -1
  139. package/src/session/session-manager.ts +1 -1
  140. package/src/task/render.ts +2 -2
  141. package/src/task/subprocess-tool-registry.ts +1 -1
  142. package/src/task/worktree.ts +1 -1
  143. package/src/tools/ask.ts +1 -1
  144. package/src/tools/ast-edit.ts +3 -3
  145. package/src/tools/ast-grep.ts +3 -3
  146. package/src/tools/bash-command-fixup.ts +1 -1
  147. package/src/tools/bash-interactive.ts +2 -2
  148. package/src/tools/bash.ts +2 -2
  149. package/src/tools/browser/attach.ts +1 -1
  150. package/src/tools/browser/render.ts +2 -2
  151. package/src/tools/debug.ts +1 -1
  152. package/src/tools/eval-render.ts +2 -2
  153. package/src/tools/fetch.ts +2 -2
  154. package/src/tools/find.ts +3 -3
  155. package/src/tools/fs-cache-invalidation.ts +1 -1
  156. package/src/tools/gh-renderer.ts +1 -1
  157. package/src/tools/inspect-image-renderer.ts +2 -2
  158. package/src/tools/irc.ts +1 -1
  159. package/src/tools/job.ts +2 -2
  160. package/src/tools/memory-render.ts +2 -2
  161. package/src/tools/read.ts +3 -3
  162. package/src/tools/render-utils.ts +5 -5
  163. package/src/tools/renderers.ts +1 -1
  164. package/src/tools/resolve.ts +2 -2
  165. package/src/tools/review.ts +2 -2
  166. package/src/tools/search-tool-bm25.ts +2 -2
  167. package/src/tools/search.ts +3 -3
  168. package/src/tools/ssh.ts +1 -1
  169. package/src/tools/todo.ts +2 -2
  170. package/src/tools/write.ts +1 -1
  171. package/src/tui/code-cell.ts +1 -1
  172. package/src/tui/hyperlink.ts +1 -1
  173. package/src/tui/output-block.ts +2 -2
  174. package/src/tui/tree-list.ts +1 -1
  175. package/src/tui/utils.ts +2 -2
  176. package/src/utils/block-context.ts +1 -1
  177. package/src/utils/clipboard.ts +2 -2
  178. package/src/web/search/render.ts +2 -2
  179. package/src/workspace-tree.ts +1 -1
  180. package/stubs/natives/index.ts +50 -2
  181. package/stubs/tui/index.ts +51 -4
  182. package/src/stubs/natives/index.ts +0 -814
  183. package/src/stubs/natives/package.json +0 -7
  184. package/src/stubs/tui/index.ts +0 -282
  185. package/src/stubs/tui/package.json +0 -7
@@ -1,4 +1,4 @@
1
- import { Box, Markdown, Spacer, Text } from '../../stubs/tui/index.ts'
1
+ import { Box, Markdown, Spacer, Text } from '#stubs/tui'
2
2
  import { getMarkdownTheme, theme } from "../../modes/theme/theme";
3
3
  import type { BranchSummaryMessage } from "../../session/messages";
4
4
 
@@ -1,4 +1,4 @@
1
- import { type Component, Container, Markdown, Spacer, Text, type TUI } from '../../stubs/tui/index.ts'
1
+ import { type Component, Container, Markdown, Spacer, Text, type TUI } from '#stubs/tui'
2
2
  import { replaceTabs } from "../../tools/render-utils";
3
3
  import { getMarkdownTheme, theme } from "../theme/theme";
4
4
  import { DynamicBorder } from "./dynamic-border";
@@ -1,4 +1,4 @@
1
- import { Container } from '../../stubs/tui/index.ts'
1
+ import { Container } from '#stubs/tui'
2
2
 
3
3
  /**
4
4
  * Capabilities a mounted {@link ChatBlock} may use against its host transcript.
@@ -1,4 +1,4 @@
1
- import { Box, type Component, Markdown } from '../../stubs/tui/index.ts'
1
+ import { Box, type Component, Markdown } from '#stubs/tui'
2
2
  import { getMarkdownTheme, theme } from "../../modes/theme/theme";
3
3
  import type { CompactionSummaryMessage } from "../../session/messages";
4
4
 
@@ -1,4 +1,4 @@
1
- import { type Component, matchesKey, padding, Text, truncateToWidth, visibleWidth } from '../../stubs/tui/index.ts'
1
+ import { type Component, matchesKey, padding, Text, truncateToWidth, visibleWidth } from '#stubs/tui'
2
2
  import { replaceTabs } from "../../tools/render-utils";
3
3
  import { highlightCode, theme } from "../theme/theme";
4
4
  import type { CopyTarget } from "../utils/copy-targets";
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Reusable countdown timer for dialog components.
3
3
  */
4
- import type { TUI } from '../../stubs/tui/index.ts'
4
+ import type { TUI } from '#stubs/tui'
5
5
 
6
6
  export class CountdownTimer {
7
7
  #intervalId: NodeJS.Timeout | undefined;
@@ -1,4 +1,4 @@
1
- import { addKeyAliases, canonicalKeyId, Editor, type KeyId, parseKey, parseKittySequence } from '../../stubs/tui/index.ts'
1
+ import { addKeyAliases, canonicalKeyId, Editor, type KeyId, parseKey, parseKittySequence } from '#stubs/tui'
2
2
  import type { AppKeybinding } from "../../config/keybindings";
3
3
  import { imageReferenceHyperlink, PLACEHOLDER_REGEX, renderPlaceholders } from "../image-references";
4
4
  import { highlightMagicKeywords } from "../magic-keywords";
@@ -1,5 +1,5 @@
1
- import type { Component } from '../../stubs/tui/index.ts'
2
- import { Box, Container } from '../../stubs/tui/index.ts'
1
+ import type { Component } from '#stubs/tui'
2
+ import { Box, Container } from '#stubs/tui'
3
3
  import type { MessageRenderer } from "../../extensibility/extensions/types";
4
4
  import { theme } from "../../modes/theme/theme";
5
5
  import type { CustomMessage } from "../../session/messages";
@@ -1,4 +1,4 @@
1
- import type { Component } from '../../stubs/tui/index.ts'
1
+ import type { Component } from '#stubs/tui'
2
2
  import { theme } from "../../modes/theme/theme";
3
3
 
4
4
  /**
@@ -1,4 +1,4 @@
1
- import { Container, Spacer, Text } from '../../stubs/tui/index.ts'
1
+ import { Container, Spacer, Text } from '#stubs/tui'
2
2
  import { getPreviewLines, TRUNCATE_LENGTHS } from "../../tools/render-utils";
3
3
  import { theme } from "../theme/theme";
4
4
  import { DynamicBorder } from "./dynamic-border";
@@ -3,7 +3,7 @@
3
3
  * Shares the same kernel session as the agent's eval tool.
4
4
  */
5
5
 
6
- import { Container, type Loader, Text, type TUI } from '../../stubs/tui/index.ts'
6
+ import { Container, type Loader, Text, type TUI } from '#stubs/tui'
7
7
  import { sanitizeText } from "@oh-my-pi/pi-utils";
8
8
  import { highlightCode, theme } from "../../modes/theme/theme";
9
9
  import type { TruncationMeta } from "../../tools/output-meta";
@@ -7,7 +7,7 @@
7
7
  * stay in their respective files.
8
8
  */
9
9
 
10
- import { type Component, Container, Loader, Text, type TUI } from '../../stubs/tui/index.ts'
10
+ import { type Component, Container, Loader, Text, type TUI } from '#stubs/tui'
11
11
  import { getSymbolTheme, theme } from "../../modes/theme/theme";
12
12
  import { formatTruncationMetaNotice, type TruncationMeta } from "../../tools/output-meta";
13
13
  import { DynamicBorder } from "./dynamic-border";
@@ -19,7 +19,7 @@ import { type Component,
19
19
  Text,
20
20
  truncateToWidth,
21
21
  visibleWidth,
22
- wrapTextWithAnsi, } from '../../stubs/tui/index.ts'
22
+ wrapTextWithAnsi, } from '#stubs/tui'
23
23
  import { Settings } from "../../../config/settings";
24
24
  import { DynamicBorder } from "../../../modes/components/dynamic-border";
25
25
  import { theme } from "../../../modes/theme/theme";
@@ -11,7 +11,7 @@ import { type Component,
11
11
  padding,
12
12
  ScrollView,
13
13
  truncateToWidth,
14
- visibleWidth, } from '../../stubs/tui/index.ts'
14
+ visibleWidth, } from '#stubs/tui'
15
15
  import { isProviderEnabled } from "../../../discovery";
16
16
  import { theme } from "../../../modes/theme/theme";
17
17
  import { matchesSelectDown, matchesSelectUp } from "../../utils/keybinding-matchers";
@@ -4,7 +4,7 @@
4
4
  * Shows name, description, origin, status, and kind-specific preview.
5
5
  */
6
6
  import * as os from "node:os";
7
- import { type Component, truncateToWidth, wrapTextWithAnsi } from '../../stubs/tui/index.ts'
7
+ import { type Component, truncateToWidth, wrapTextWithAnsi } from '#stubs/tui'
8
8
  import { theme } from "../../../modes/theme/theme";
9
9
  import { shortenPath } from "../../../tools/render-utils";
10
10
  import type { Extension, ExtensionState } from "./types";
@@ -3,7 +3,7 @@
3
3
  * Handles data loading, tree building, filtering, and toggle persistence.
4
4
  */
5
5
  import * as path from "node:path";
6
- import { fuzzyMatch } from '../../stubs/tui/index.ts'
6
+ import { fuzzyMatch } from '#stubs/tui'
7
7
  import { logger } from "@oh-my-pi/pi-utils";
8
8
  import type { ContextFile } from "../../../capability/context-file";
9
9
  import type { ExtensionModule } from "../../../capability/extension-module";
@@ -2,7 +2,7 @@ import * as fs from "node:fs";
2
2
  import * as path from "node:path";
3
3
  import { stripVTControlCharacters } from "node:util";
4
4
  import { ThinkingLevel } from "@oh-my-pi/pi-agent-core";
5
- import { type Component, padding, truncateToWidth, visibleWidth } from '../../stubs/tui/index.ts'
5
+ import { type Component, padding, truncateToWidth, visibleWidth } from '#stubs/tui'
6
6
  import { formatNumber, getProjectDir } from "@oh-my-pi/pi-utils";
7
7
  import { theme } from "../../modes/theme/theme";
8
8
  import type { AgentSession } from "../../session/agent-session";
@@ -8,7 +8,7 @@ import { type Component,
8
8
  Spacer,
9
9
  Text,
10
10
  truncateToWidth,
11
- visibleWidth, } from '../../stubs/tui/index.ts'
11
+ visibleWidth, } from '#stubs/tui'
12
12
  import { theme } from "../../modes/theme/theme";
13
13
  import {
14
14
  matchesAppInterrupt,
@@ -6,7 +6,7 @@
6
6
  * - Default (hook): Enter inserts newline, Ctrl+Enter submits, bordered popup
7
7
  * - Prompt-style (ask): Enter submits, Shift+Enter inserts newline, legacy ask chrome
8
8
  */
9
- import { Container, Editor, matchesKey, Spacer, Text, type TUI } from '../../stubs/tui/index.ts'
9
+ import { Container, Editor, matchesKey, Spacer, Text, type TUI } from '#stubs/tui'
10
10
  import { getEditorTheme, theme } from "../../modes/theme/theme";
11
11
  import { matchesAppExternalEditor, matchesAppInterrupt } from "../../modes/utils/keybinding-matchers";
12
12
  import { getEditorCommand, openInEditor } from "../../utils/external-editor";
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Simple text input component for hooks.
3
3
  */
4
- import { Container, Input, Markdown, matchesKey, Spacer, Text, type TUI } from '../../stubs/tui/index.ts'
4
+ import { Container, Input, Markdown, matchesKey, Spacer, Text, type TUI } from '#stubs/tui'
5
5
  import { getMarkdownTheme, theme } from "../../modes/theme/theme";
6
6
  import { matchesAppInterrupt } from "../../modes/utils/keybinding-matchers";
7
7
  import { CountdownTimer } from "./countdown-timer";
@@ -1,5 +1,5 @@
1
- import type { Component } from '../../stubs/tui/index.ts'
2
- import { Box, Container } from '../../stubs/tui/index.ts'
1
+ import type { Component } from '#stubs/tui'
2
+ import { Box, Container } from '#stubs/tui'
3
3
  import type { HookMessageRenderer } from "../../extensibility/hooks/types";
4
4
  import { theme } from "../../modes/theme/theme";
5
5
  import type { HookMessage } from "../../session/messages";
@@ -17,7 +17,7 @@ import { Container,
17
17
  type TUI,
18
18
  truncateToWidth,
19
19
  visibleWidth,
20
- wrapTextWithAnsi, } from '../../stubs/tui/index.ts'
20
+ wrapTextWithAnsi, } from '#stubs/tui'
21
21
  import { getMarkdownTheme, type ThemeColor, theme } from "../../modes/theme/theme";
22
22
  import {
23
23
  matchesAppExternalEditor,
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Utilities for formatting keybinding hints in the UI.
3
3
  */
4
- import { getKeybindings, type Keybinding, type KeyId } from '../../stubs/tui/index.ts'
4
+ import { getKeybindings, type Keybinding, type KeyId } from '#stubs/tui'
5
5
  import type { AppKeybinding, KeybindingsManager } from "../../config/keybindings";
6
6
  import { theme } from "../../modes/theme/theme";
7
7
 
@@ -1,4 +1,4 @@
1
- import { Container, Text } from '../../stubs/tui/index.ts'
1
+ import { Container, Text } from '#stubs/tui'
2
2
  import { formatDiagnostics } from "../../tools/render-utils";
3
3
  import { getLanguageFromPath, theme } from "../theme/theme";
4
4
 
@@ -1,5 +1,5 @@
1
1
  import { getOAuthProviders } from "@oh-my-pi/pi-ai/oauth";
2
- import { Container, getKeybindings, Input, Spacer, Text, type TUI } from '../../stubs/tui/index.ts'
2
+ import { Container, getKeybindings, Input, Spacer, Text, type TUI } from '#stubs/tui'
3
3
  import { theme } from "../../modes/theme/theme";
4
4
  import { openPath } from "../../utils/open";
5
5
  import { DynamicBorder } from "./dynamic-border";
@@ -10,7 +10,7 @@ import { Container,
10
10
  Spacer,
11
11
  Text,
12
12
  TruncatedText,
13
- truncateToWidth, } from '../../stubs/tui/index.ts'
13
+ truncateToWidth, } from '#stubs/tui'
14
14
  import { getMCPConfigPath, getProjectDir } from "@oh-my-pi/pi-utils";
15
15
  import { validateServerName } from "../../mcp/config-writer";
16
16
  import { analyzeAuthError, discoverOAuthEndpoints } from "../../mcp/oauth-discovery";
@@ -9,8 +9,8 @@
9
9
  */
10
10
 
11
11
  import type { TextContent } from "@oh-my-pi/pi-ai";
12
- import type { Box, Component } from '../../stubs/tui/index.ts'
13
- import { Markdown, Spacer, Text } from '../../stubs/tui/index.ts'
12
+ import type { Box, Component } from '#stubs/tui'
13
+ import { Markdown, Spacer, Text } from '#stubs/tui'
14
14
  import { getMarkdownTheme, type Theme, theme } from "../../modes/theme/theme";
15
15
 
16
16
  /** Message shape consumed by the shared frame. */
@@ -13,7 +13,7 @@ import { Container,
13
13
  TabBar,
14
14
  Text,
15
15
  type TUI,
16
- visibleWidth, } from '../../stubs/tui/index.ts'
16
+ visibleWidth, } from '#stubs/tui'
17
17
  import { formatNumber } from "@oh-my-pi/pi-utils";
18
18
  import type { ModelRegistry } from "../../config/model-registry";
19
19
  import { getModelMatchPreferences, resolveModelRoleValue } from "../../config/model-resolver";
@@ -6,7 +6,7 @@ import { Container,
6
6
  matchesKey,
7
7
  ScrollView,
8
8
  Spacer,
9
- TruncatedText, } from '../../stubs/tui/index.ts'
9
+ TruncatedText, } from '#stubs/tui'
10
10
  import { theme } from "../../modes/theme/theme";
11
11
  import { matchesSelectCancel, matchesSelectDown, matchesSelectUp } from "../../modes/utils/keybinding-matchers";
12
12
  import type { AuthStorage, CredentialOriginKind } from "../../session/auth-storage";
@@ -1,4 +1,4 @@
1
- import { type Component, Container, Markdown, Spacer, Text, type TUI } from '../../stubs/tui/index.ts'
1
+ import { type Component, Container, Markdown, Spacer, Text, type TUI } from '#stubs/tui'
2
2
  import { replaceTabs } from "../../tools/render-utils";
3
3
  import { getMarkdownTheme, theme } from "../theme/theme";
4
4
  import { DynamicBorder } from "./dynamic-border";
@@ -3,7 +3,7 @@
3
3
  * plan-review overlay, …). Every helper paints with `theme.boxSharp` glyphs and
4
4
  * the `border`/`accent` theme colors so all outlined overlays read identically.
5
5
  */
6
- import { padding, truncateToWidth, visibleWidth } from '../../stubs/tui/index.ts'
6
+ import { padding, truncateToWidth, visibleWidth } from '#stubs/tui'
7
7
  import { theme } from "../theme/theme";
8
8
 
9
9
  /** Pad or truncate a (possibly ANSI-styled) string to exactly `width` columns. */
@@ -24,7 +24,7 @@ import { type Component,
24
24
  matchesKey,
25
25
  ScrollView,
26
26
  truncateToWidth,
27
- visibleWidth, } from '../../stubs/tui/index.ts'
27
+ visibleWidth, } from '#stubs/tui'
28
28
  import { getMarkdownTheme, theme } from "../theme/theme";
29
29
  import {
30
30
  matchesAppExternalEditor,
@@ -4,7 +4,7 @@
4
4
  * Shows available plugins from all configured marketplaces in a SelectList.
5
5
  * Selecting a plugin triggers installation. Esc cancels.
6
6
  */
7
- import { Container, type SelectItem, SelectList } from '../../stubs/tui/index.ts'
7
+ import { Container, type SelectItem, SelectList } from '#stubs/tui'
8
8
  import { getSelectListTheme } from "../theme/theme";
9
9
  import { DynamicBorder } from "./dynamic-border";
10
10
 
@@ -15,7 +15,7 @@ import { Container,
15
15
  type SettingItem,
16
16
  SettingsList,
17
17
  Spacer,
18
- Text, } from '../../stubs/tui/index.ts'
18
+ Text, } from '#stubs/tui'
19
19
  import { logger } from "@oh-my-pi/pi-utils";
20
20
  import { clearPluginRootsAndCaches, resolveOrDefaultProjectRegistryPath } from "../../discovery/helpers";
21
21
  import { PluginManager } from "../../extensibility/plugins/manager";
@@ -1,4 +1,4 @@
1
- import { Container, type SelectItem, SelectList } from '../../stubs/tui/index.ts'
1
+ import { Container, type SelectItem, SelectList } from '#stubs/tui'
2
2
  import { getSelectListTheme } from "../../modes/theme/theme";
3
3
  import { DynamicBorder } from "./dynamic-border";
4
4
 
@@ -1,6 +1,6 @@
1
1
  import * as path from "node:path";
2
- import type { Component } from '../../stubs/tui/index.ts'
3
- import { Container, Text } from '../../stubs/tui/index.ts'
2
+ import type { Component } from '#stubs/tui'
3
+ import { Container, Text } from '#stubs/tui'
4
4
  import { InternalUrlRouter } from "../../internal-urls";
5
5
  import { getLanguageFromPath, theme } from "../../modes/theme/theme";
6
6
  import { parseLineRanges, selectorLineRanges, splitPathAndSel } from "../../tools/path-utils";
@@ -9,7 +9,7 @@ import { type Component,
9
9
  Spacer,
10
10
  Text,
11
11
  truncateToWidth,
12
- visibleWidth, } from '../../stubs/tui/index.ts'
12
+ visibleWidth, } from '#stubs/tui'
13
13
  import { formatBytes } from "@oh-my-pi/pi-utils";
14
14
  import { theme } from "../../modes/theme/theme";
15
15
  import { matchesAppInterrupt, matchesSelectDown, matchesSelectUp } from "../../modes/utils/keybinding-matchers";
@@ -8,7 +8,7 @@
8
8
  * (or `options: "runtime"` for runtime-injected lists like themes).
9
9
  */
10
10
 
11
- import { TERMINAL } from '../../stubs/tui/index.ts'
11
+ import { TERMINAL } from '#stubs/tui'
12
12
  import { Settings } from "../../config/settings";
13
13
  import {
14
14
  type AnyUiMetadata,
@@ -10,7 +10,7 @@ import { Container,
10
10
  Spacer,
11
11
  type Tab,
12
12
  TabBar,
13
- Text, } from '../../stubs/tui/index.ts'
13
+ Text, } from '#stubs/tui'
14
14
  import { getDefault, type SettingPath, settings } from "../../config/settings";
15
15
  import type {
16
16
  SettingTab,
@@ -1,4 +1,4 @@
1
- import { Container, type SelectItem, SelectList } from '../../stubs/tui/index.ts'
1
+ import { Container, type SelectItem, SelectList } from '#stubs/tui'
2
2
  import { getSelectListTheme } from "../../modes/theme/theme";
3
3
  import { DynamicBorder } from "./dynamic-border";
4
4
 
@@ -1,6 +1,6 @@
1
1
  import type { TextContent } from "@oh-my-pi/pi-ai";
2
- import type { Component } from '../../stubs/tui/index.ts'
3
- import { Box, Container, Markdown, Spacer, Text } from '../../stubs/tui/index.ts'
2
+ import type { Component } from '#stubs/tui'
3
+ import { Box, Container, Markdown, Spacer, Text } from '#stubs/tui'
4
4
  import { getMarkdownTheme, theme } from "../../modes/theme/theme";
5
5
  import type { CustomMessage, SkillPromptDetails } from "../../session/messages";
6
6
 
@@ -2,7 +2,7 @@ import * as fs from "node:fs";
2
2
  import * as path from "node:path";
3
3
  import type { AgentMessage } from "@oh-my-pi/pi-agent-core";
4
4
  import { estimateTokens } from "@oh-my-pi/pi-agent-core/compaction";
5
- import { type Component, truncateToWidth, visibleWidth } from '../../stubs/tui/index.ts'
5
+ import { type Component, truncateToWidth, visibleWidth } from '#stubs/tui'
6
6
  import { formatCount, getProjectDir } from "@oh-my-pi/pi-utils";
7
7
  import { $ } from "bun";
8
8
  import { settings } from "../../../config/settings";
@@ -1,7 +1,7 @@
1
1
  import * as os from "node:os";
2
2
  import * as path from "node:path";
3
3
  import { ThinkingLevel } from "@oh-my-pi/pi-agent-core";
4
- import { TERMINAL } from '../../stubs/tui/index.ts'
4
+ import { TERMINAL } from '#stubs/tui'
5
5
  import { formatDuration, formatNumber, getProjectDir, pathIsWithin, relativePathWithinRoot } from "@oh-my-pi/pi-utils";
6
6
  import { type ThemeColor, theme } from "../../../modes/theme/theme";
7
7
  import { shortenPath } from "../../../tools/render-utils";
@@ -1,4 +1,4 @@
1
- import { Container, type SelectItem, SelectList } from '../../stubs/tui/index.ts'
1
+ import { Container, type SelectItem, SelectList } from '#stubs/tui'
2
2
  import { getSelectListTheme } from "../../modes/theme/theme";
3
3
  import { DynamicBorder } from "./dynamic-border";
4
4
 
@@ -1,5 +1,5 @@
1
1
  import type { Effort } from "@oh-my-pi/pi-ai";
2
- import { Container, type SelectItem, SelectList } from '../../stubs/tui/index.ts'
2
+ import { Container, type SelectItem, SelectList } from '#stubs/tui'
3
3
  import { getSelectListTheme } from "../../modes/theme/theme";
4
4
  import { getThinkingLevelMetadata } from "../../thinking";
5
5
  import { DynamicBorder } from "./dynamic-border";
@@ -1,4 +1,4 @@
1
- import { type Component, truncateToWidth, visibleWidth } from '../../stubs/tui/index.ts'
1
+ import { type Component, truncateToWidth, visibleWidth } from '#stubs/tui'
2
2
  import { formatBytes } from "@oh-my-pi/pi-utils";
3
3
  import { getTinyTitleModelSpec, type TinyTitleLocalModelKey } from "../../tiny/models";
4
4
  import type { TinyTitleProgressEvent } from "../../tiny/title-protocol";
@@ -1,4 +1,4 @@
1
- import { Box, Container, Spacer, Text } from '../../stubs/tui/index.ts'
1
+ import { Box, Container, Spacer, Text } from '#stubs/tui'
2
2
  import { theme } from "../../modes/theme/theme";
3
3
  import type { TodoItem } from "../../tools/todo";
4
4
 
@@ -10,7 +10,7 @@ import { Box,
10
10
  Spacer,
11
11
  TERMINAL,
12
12
  Text,
13
- type TUI, } from '../../stubs/tui/index.ts'
13
+ type TUI, } from '#stubs/tui'
14
14
  import { getProjectDir, logger, sanitizeText } from "@oh-my-pi/pi-utils";
15
15
  import { EDIT_MODE_STRATEGIES, type EditMode, type PerFileDiffPreview } from "../../edit";
16
16
  import type { Theme } from "../../modes/theme/theme";
@@ -1,4 +1,4 @@
1
- import { type Component, Container, type NativeScrollbackLiveRegion, type RenderStablePrefix } from '../../stubs/tui/index.ts'
1
+ import { type Component, Container, type NativeScrollbackLiveRegion, type RenderStablePrefix } from '#stubs/tui'
2
2
 
3
3
  const kSnapshot = Symbol("transcript.liveDiffSnapshot");
4
4
 
@@ -9,7 +9,7 @@ import { type Component,
9
9
  Spacer,
10
10
  Text,
11
11
  TruncatedText,
12
- truncateToWidth, } from '../../stubs/tui/index.ts'
12
+ truncateToWidth, } from '#stubs/tui'
13
13
  import type { TreeFilterMode } from "../../config/settings-schema";
14
14
  import { theme } from "../../modes/theme/theme";
15
15
  import { matchesAppInterrupt, matchesSelectDown, matchesSelectUp } from "../../modes/utils/keybinding-matchers";
@@ -1,4 +1,4 @@
1
- import { Box, Container, Spacer, Text } from '../../stubs/tui/index.ts'
1
+ import { Box, Container, Spacer, Text } from '#stubs/tui'
2
2
  import type { Rule } from "../../capability/rule";
3
3
  import { theme } from "../../modes/theme/theme";
4
4
 
@@ -6,7 +6,7 @@ import { type Component,
6
6
  ScrollView,
7
7
  Spacer,
8
8
  Text,
9
- truncateToWidth, } from '../../stubs/tui/index.ts'
9
+ truncateToWidth, } from '#stubs/tui'
10
10
  import { theme } from "../../modes/theme/theme";
11
11
  import { matchesSelectCancel, matchesSelectDown, matchesSelectUp } from "../../modes/utils/keybinding-matchers";
12
12
  import { DynamicBorder } from "./dynamic-border";
@@ -1,4 +1,4 @@
1
- import { Container, Markdown } from '../../stubs/tui/index.ts'
1
+ import { Container, Markdown } from '#stubs/tui'
2
2
  import { getMarkdownTheme, theme } from "../../modes/theme/theme";
3
3
  import { imageReferenceHyperlink, renderPlaceholders } from "../image-references";
4
4
  import { highlightMagicKeywords } from "../magic-keywords";
@@ -2,7 +2,7 @@
2
2
  * Shared utility for truncating text to visual lines (accounting for line wrapping).
3
3
  * Used by both tool-execution.ts and bash-execution.ts for consistent behavior.
4
4
  */
5
- import { Text } from '../../stubs/tui/index.ts'
5
+ import { Text } from '#stubs/tui'
6
6
 
7
7
  export interface VisualTruncateResult {
8
8
  /** The visual lines to display */
@@ -4,7 +4,7 @@ import { type Component,
4
4
  TERMINAL,
5
5
  truncateToWidth,
6
6
  visibleWidth,
7
- wrapTextWithAnsi, } from '../../stubs/tui/index.ts'
7
+ wrapTextWithAnsi, } from '#stubs/tui'
8
8
  import { APP_NAME } from "@oh-my-pi/pi-utils";
9
9
  import { theme } from "../../modes/theme/theme";
10
10
  import tipsText from "./tips.txt" with { type: "text" };
@@ -7,7 +7,7 @@
7
7
  * wording, and add-flow logic stay in the per-controller files because they
8
8
  * diverge in workflow.
9
9
  */
10
- import { Text } from '../../stubs/tui/index.ts'
10
+ import { Text } from '#stubs/tui'
11
11
  import type { SourceMeta } from "../../capability/types";
12
12
  import { shortenPath } from "../../tools/render-utils";
13
13
  import { DynamicBorder } from "../components/dynamic-border";
@@ -9,7 +9,7 @@ import {
9
9
  type UsageLimit,
10
10
  type UsageReport,
11
11
  } from "@oh-my-pi/pi-ai";
12
- import { Loader, Markdown, padding, Spacer, Text, visibleWidth } from '../../stubs/tui/index.ts'
12
+ import { Loader, Markdown, padding, Spacer, Text, visibleWidth } from '#stubs/tui'
13
13
  import { formatDuration, Snowflake } from "@oh-my-pi/pi-utils";
14
14
  import { $ } from "bun";
15
15
  import { shouldEnableAppendOnlyContext } from "../../config/append-only-context-mode";
@@ -1,7 +1,7 @@
1
1
  import { INTENT_FIELD } from "@oh-my-pi/pi-agent-core";
2
2
  import { calculatePromptTokens } from "@oh-my-pi/pi-agent-core/compaction/compaction";
3
3
  import type { AssistantMessage, ImageContent } from "@oh-my-pi/pi-ai";
4
- import { type Component, Loader, TERMINAL } from '../../stubs/tui/index.ts'
4
+ import { type Component, Loader, TERMINAL } from '#stubs/tui'
5
5
  import { settings } from "../../config/settings";
6
6
  import { getFileSnapshotStore } from "../../edit/file-snapshot-store";
7
7
  import { AssistantMessageComponent } from "../../modes/components/assistant-message";
@@ -1,5 +1,5 @@
1
- import type { Component, OverlayHandle, TUI } from '../../stubs/tui/index.ts'
2
- import { Container, Spacer, Text } from '../../stubs/tui/index.ts'
1
+ import type { Component, OverlayHandle, TUI } from '#stubs/tui'
2
+ import { Container, Spacer, Text } from '#stubs/tui'
3
3
  import { KeybindingsManager } from "../../config/keybindings";
4
4
  import type {
5
5
  CompactOptions,
@@ -1,6 +1,6 @@
1
1
  import * as fs from "node:fs/promises";
2
2
  import type { ImageContent } from "@oh-my-pi/pi-ai";
3
- import type { AutocompleteProvider, SlashCommand } from '../../stubs/tui/index.ts'
3
+ import type { AutocompleteProvider, SlashCommand } from '#stubs/tui'
4
4
  import { $env, logger, sanitizeText } from "@oh-my-pi/pi-utils";
5
5
  import { getRoleInfo } from "../../config/model-roles";
6
6
  import { isSettingsInitialized, settings } from "../../config/settings";
@@ -4,7 +4,7 @@
4
4
  * Handles /mcp subcommands for managing MCP servers.
5
5
  */
6
6
  import * as path from "node:path";
7
- import { type Component, replaceTabs, Spacer, Text } from '../../stubs/tui/index.ts'
7
+ import { type Component, replaceTabs, Spacer, Text } from '#stubs/tui'
8
8
  import { getMCPConfigPath, getProjectDir } from "@oh-my-pi/pi-utils";
9
9
  import type { SourceMeta } from "../../capability/types";
10
10
  import { analyzeAuthError, discoverOAuthEndpoints, MCPManager } from "../../mcp";
@@ -2,8 +2,8 @@ import { ThinkingLevel } from "@oh-my-pi/pi-agent-core";
2
2
  import { PASTE_CODE_LOGIN_PROVIDERS } from "@oh-my-pi/pi-ai";
3
3
  import { getOAuthProviders } from "@oh-my-pi/pi-ai/oauth";
4
4
  import type { OAuthProvider } from "@oh-my-pi/pi-ai/oauth/types";
5
- import type { Component, OverlayHandle } from '../../stubs/tui/index.ts'
6
- import { Input, Loader, Spacer, Text } from '../../stubs/tui/index.ts'
5
+ import type { Component, OverlayHandle } from '#stubs/tui'
6
+ import { Input, Loader, Spacer, Text } from '#stubs/tui'
7
7
  import { getAgentDbPath, getProjectDir, normalizePathForComparison } from "@oh-my-pi/pi-utils";
8
8
  import { formatModelSelectorValue } from "../../config/model-resolver";
9
9
  import { getRoleInfo } from "../../config/model-roles";
@@ -1,5 +1,5 @@
1
1
  import type { AssistantMessage } from "@oh-my-pi/pi-ai";
2
- import { getSegmenter } from '../../stubs/tui/index.ts'
2
+ import { getSegmenter } from '#stubs/tui'
3
3
  import type { AssistantMessageComponent } from "../components/assistant-message";
4
4
 
5
5
  export const STREAMING_REVEAL_FRAME_MS = 1000 / 30;
@@ -1,4 +1,4 @@
1
- import type { AutocompleteItem } from '../../stubs/tui/index.ts'
1
+ import type { AutocompleteItem } from '#stubs/tui'
2
2
  import buckets from "./data/emojis.json" with { type: "json" };
3
3
 
4
4
  // Bucket layout: `{ "<first-char>": [["<name>", "<emoji>"], ...] }`, with each