mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-05-01 01:51:44 +00:00
feat: cute spinners
This commit is contained in:
parent
b50d81f212
commit
af0f4a52fe
11 changed files with 1429 additions and 240 deletions
26
ui-tui/src/components/activityLane.tsx
Normal file
26
ui-tui/src/components/activityLane.tsx
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
import { Box, Text } from 'ink'
|
||||
|
||||
import type { Theme } from '../theme.js'
|
||||
import type { ActivityItem } from '../types.js'
|
||||
|
||||
export function ActivityLane({ items, t }: { items: ActivityItem[]; t: Theme }) {
|
||||
if (!items.length) {
|
||||
return null
|
||||
}
|
||||
|
||||
const visible = items.slice(-4)
|
||||
|
||||
return (
|
||||
<Box flexDirection="column" marginTop={1}>
|
||||
{visible.map(item => {
|
||||
const color = item.tone === 'error' ? t.color.error : item.tone === 'warn' ? t.color.warn : t.color.dim
|
||||
|
||||
return (
|
||||
<Text color={color} dimColor={item.tone === 'info'} key={item.id}>
|
||||
{t.brand.tool} {item.text}
|
||||
</Text>
|
||||
)
|
||||
})}
|
||||
</Box>
|
||||
)
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue