Replace Markdown with Text component for tool execution

- Add background color support to Text component
- Replace Markdown component with Text in ToolExecutionComponent
- Use chalk.bold for formatting instead of markdown syntax
- Remove unnecessary markdown parsing overhead
This commit is contained in:
Mario Zechner 2025-11-11 21:27:23 +01:00
parent 10520a8c41
commit 5d7bc60cff
3 changed files with 58 additions and 23 deletions

View file

@ -1,4 +1,4 @@
import type { Agent, AgentState, ThinkingLevel } from "@mariozechner/pi-agent";
import type { Agent, AgentEvent, AgentState, ThinkingLevel } from "@mariozechner/pi-agent";
import type { AssistantMessage, Message } from "@mariozechner/pi-ai";
import type { SlashCommand } from "@mariozechner/pi-tui";
import {
@ -166,7 +166,7 @@ export class TuiRenderer {
this.isInitialized = true;
}
async handleEvent(event: import("@mariozechner/pi-agent").AgentEvent, state: AgentState): Promise<void> {
async handleEvent(event: AgentEvent, state: AgentState): Promise<void> {
if (!this.isInitialized) {
await this.init();
}