File size: 790 Bytes
fdc8b59 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | import React from 'react'
import { MessageResponse } from '../../components/MessageResponse.js'
import { Text } from '../../ink.js'
import type { Output } from './GoalGetTool.js'
export function renderToolUseMessage(): React.ReactNode {
return <Text dimColor>getting current goal...</Text>
}
export function renderToolResultMessage(output: Output): React.ReactNode {
if (!output.goal) {
return (
<MessageResponse>
<Text dimColor>No active goal.</Text>
</MessageResponse>
)
}
const g = output.goal
return (
<MessageResponse>
<Text>
Goal: {g.objective}{'\n'}
Status: {g.status}{'\n'}
Elapsed: {g.elapsed_formatted}
{'\n'}
Continuations: {g.continuation_count}
</Text>
</MessageResponse>
)
} |