MCPcopy Create free account
hub / github.com/codeaashu/claude-code / renderToolUseMessage

Function renderToolUseMessage

src/tools/GrepTool/UI.tsx:127–146  ·  view source on GitHub ↗
({
  pattern,
  path
}: Partial<{
  pattern: string;
  path?: string;
}>, {
  verbose
}: {
  verbose: boolean;
})

Source from the content-addressed store, hash-verified

125 numMatches?: number; // For count mode
126};
127export function renderToolUseMessage({
128 pattern,
129 path
130}: Partial<{
131 pattern: string;
132 path?: string;
133}>, {
134 verbose
135}: {
136 verbose: boolean;
137}): React.ReactNode {
138 if (!pattern) {
139 return null;
140 }
141 const parts = [`pattern: "${pattern}"`];
142 if (path) {
143 parts.push(`path: "${verbose ? path : getDisplayPath(path)}"`);
144 }
145 return parts.join(', ');
146}
147export function renderToolUseErrorMessage(result: ToolResultBlockParam['content'], {
148 verbose
149}: {

Callers

nothing calls this directly

Calls 2

getDisplayPathFunction · 0.85
pushMethod · 0.45

Tested by

no test coverage detected