pi-readseek 0.5.1 → 0.5.2
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.
- package/package.json +1 -1
- package/src/hover.ts +2 -2
- package/src/rename.ts +2 -2
package/package.json
CHANGED
package/src/hover.ts
CHANGED
|
@@ -11,7 +11,7 @@ import { formatFsError } from "./fs-error.js";
|
|
|
11
11
|
import { classifyReadSeekFailure, readSeekIdentify } from "./readseek-client.js";
|
|
12
12
|
import { filePathParam, registerReadSeekTool } from "./register-tool.js";
|
|
13
13
|
|
|
14
|
-
import { clampLinesToWidth, linkToolPath, renderPendingResult, resolveRenderResultContext, summaryLine } from "./tui-render-utils.js";
|
|
14
|
+
import { clampLineToWidth, clampLinesToWidth, linkToolPath, renderPendingResult, resolveRenderResultContext, summaryLine } from "./tui-render-utils.js";
|
|
15
15
|
|
|
16
16
|
const HOVER_PROMPT_METADATA = defineToolPromptMetadata({
|
|
17
17
|
promptUrl: new URL("../prompts/hover.md", import.meta.url),
|
|
@@ -109,7 +109,7 @@ export function registerHoverTool(pi: ExtensionAPI) {
|
|
|
109
109
|
let text = theme.fg("toolTitle", theme.bold("hover"));
|
|
110
110
|
text += ` ${linkToolPath(theme.fg("accent", displayPath), displayPath, cwd)}`;
|
|
111
111
|
if (args?.line) text += theme.fg("dim", `:${args.line}`);
|
|
112
|
-
return text;
|
|
112
|
+
return new Text(clampLineToWidth(text, context.width), 0, 0);
|
|
113
113
|
},
|
|
114
114
|
renderResult(result: any, options: ToolRenderResultOptions, theme: any, ...rest: any[]) {
|
|
115
115
|
const { isPartial, isError, width } = resolveRenderResultContext(options, rest);
|
package/src/rename.ts
CHANGED
|
@@ -9,7 +9,7 @@ import { resolveToCwd } from "./path-utils.js";
|
|
|
9
9
|
import { classifyReadSeekFailure, readSeekRename, type RenameOutput } from "./readseek-client.js";
|
|
10
10
|
import { filePathParam, registerReadSeekTool } from "./register-tool.js";
|
|
11
11
|
|
|
12
|
-
import { clampLinesToWidth, linkToolPath, renderPendingResult, resolveRenderResultContext, summaryLine } from "./tui-render-utils.js";
|
|
12
|
+
import { clampLineToWidth, clampLinesToWidth, linkToolPath, renderPendingResult, resolveRenderResultContext, summaryLine } from "./tui-render-utils.js";
|
|
13
13
|
|
|
14
14
|
const RENAME_PROMPT_METADATA = defineToolPromptMetadata({
|
|
15
15
|
promptUrl: new URL("../prompts/rename.md", import.meta.url),
|
|
@@ -125,7 +125,7 @@ export function registerRenameTool(pi: ExtensionAPI) {
|
|
|
125
125
|
let text = theme.fg("toolTitle", theme.bold("rename"));
|
|
126
126
|
text += ` ${linkToolPath(theme.fg("accent", displayPath), displayPath, cwd)}`;
|
|
127
127
|
if (args?.to) text += theme.fg("dim", ` → ${args.to}`);
|
|
128
|
-
return text;
|
|
128
|
+
return new Text(clampLineToWidth(text, context.width), 0, 0);
|
|
129
129
|
},
|
|
130
130
|
renderResult(result: any, options: ToolRenderResultOptions, theme: any, ...rest: any[]) {
|
|
131
131
|
const { isPartial, isError, expanded, width } = resolveRenderResultContext(options, rest);
|