indent wrapped todo items properly

This commit is contained in:
Sebastian Herrlinger
2025-12-23 15:44:45 +01:00
parent c81721e9fc
commit 1d9e181da0
3 changed files with 36 additions and 12 deletions
@@ -48,6 +48,7 @@ import { useKeybind } from "@tui/context/keybind"
import { Header } from "./header"
import { parsePatch } from "diff"
import { useDialog } from "../../ui/dialog"
import { TodoItem } from "../../component/todo-item"
import { DialogMessage } from "./dialog-message"
import type { PromptInfo } from "../../component/prompt/history"
import { iife } from "@/util/iife"
@@ -1849,11 +1850,7 @@ ToolRegistry.register<typeof TodoWriteTool>({
<Show when={props.metadata.todos?.length}>
<box>
<For each={props.input.todos ?? []}>
{(todo) => (
<text style={{ fg: todo.status === "in_progress" ? theme.success : theme.textMuted }}>
[{todo.status === "completed" ? "✓" : " "}] {todo.content}
</text>
)}
{(todo) => <TodoItem status={todo.status} content={todo.content} />}
</For>
</box>
</Show>