feat(web/claw): render the reply, not the tool calls or the thinking
android / debug (push) Successful in 2m17s
android / release (push) Successful in 2m5s
ci / checks (push) Successful in 1m0s
ci / test (push) Successful in 37s
ci / chart (push) Successful in 5s
ci / docker (push) Successful in 1m21s
ci / web (push) Successful in 13s
ci / publish-edge-images (deploy/docker/claw.Dockerfile, rhema-claw) (push) Successful in 1m23s
ci / publish-edge-images (deploy/docker/ui.Dockerfile, rhema-claw-ui) (push) Successful in 13s
ci / publish-edge-chart (push) Successful in 3s
android / debug (push) Successful in 2m17s
android / release (push) Successful in 2m5s
ci / checks (push) Successful in 1m0s
ci / test (push) Successful in 37s
ci / chart (push) Successful in 5s
ci / docker (push) Successful in 1m21s
ci / web (push) Successful in 13s
ci / publish-edge-images (deploy/docker/claw.Dockerfile, rhema-claw) (push) Successful in 1m23s
ci / publish-edge-images (deploy/docker/ui.Dockerfile, rhema-claw-ui) (push) Successful in 13s
ci / publish-edge-chart (push) Successful in 3s
The web transcript was built to mirror the TUI: every tool call as a shell line or a glyph row, the thinking trace between them, each at the position the stream delivered it. That is the right shape for a terminal session you sit and watch. On the web it reads as machinery in front of the answer, and the answer is what the page is for. `TurnEntries` now keeps only the two entries the reader must handle: a consent card (the agent is waiting on an answer, so hiding it would stall the turn) and an attachment card (the file it handed over). Everything else in the turn renders as the reply, through `AppMarkdown`. The mirror in `useTranscript` still folds tool and thinking events; only the render ignores them. Replay, the pending-echo dedupe and consent placement keep working unchanged, and the bottom-pin watch loses the thinking-length term it only needed while that block took height. `TurnToolRow` had no other caller and goes with it.
This commit is contained in:
1 parent
268917646e
commit
c56f544993
4 files changed
+30
-159
No files matched your search
@@ -136,20 +136,12 @@ watch(
|
||||
},
|
||||
)
|
||||
|
||||
// Thinking grows inside the trailing entry without changing the
|
||||
// entries length, so its total length joins the watch to keep the
|
||||
// stream pinned at the bottom.
|
||||
function liveThinkingLength(): number {
|
||||
return (
|
||||
props.live?.entries.reduce(
|
||||
(count, entry) => (entry.kind === 'thinking' ? count + entry.text.length : count),
|
||||
0,
|
||||
) ?? 0
|
||||
)
|
||||
}
|
||||
|
||||
// A consent or attachment card opening inside the trailing turn
|
||||
// changes the rendered height, so the reply length and the entries
|
||||
// length both join the watch that keeps the stream pinned at the
|
||||
// bottom.
|
||||
watch(
|
||||
() => [props.items.length, props.live?.reply.length, liveThinkingLength(), props.live?.entries.length],
|
||||
() => [props.items.length, props.live?.reply.length, props.live?.entries.length],
|
||||
async () => {
|
||||
if (!pinned.value) return
|
||||
await nextTick()
|
||||
@@ -498,7 +490,6 @@ function streamTone(status: StreamStatus): 'ok' | 'warn' | 'error' {
|
||||
<div class="who">{{ agentName }}</div>
|
||||
<TurnEntries
|
||||
:entries="live.entries"
|
||||
:open-thinking="true"
|
||||
@consent-answer="(id, answer) => emit('consentAnswer', id, answer)"
|
||||
@consent-deny="(id) => emit('consentDeny', id)"
|
||||
@download-attachment="(id, name) => emit('downloadAttachment', id, name)"
|
||||
|
||||
Reference in new issue
Block a user