Skip to content

Commit

Permalink
enh(spu-ui): update Console component layout and add loading indicator
Browse files Browse the repository at this point in the history
  • Loading branch information
matyson committed Jan 9, 2025
1 parent eff8909 commit e14a091
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions apps/spu-ui/src/app/_components/console.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -52,15 +52,13 @@ export function Console({ className }: { className?: string }) {
onExport={handleExport}
/>

<ScrollArea className="h-full w-full p-2 font-mono text-sm" ref={ref}>
{(!messages || messages.length === 0) && (
<span className="text-muted-foreground">
Waiting for new messages...
</span>
)}
<ScrollArea className="h-[94%] w-full p-2 font-mono text-sm" ref={ref}>
{messages?.map((message, i) => (
<ConsoleMessage key={i} message={message} />
))}
<span className="text-center text-muted-foreground">
$<span className="animate-pulse">{" \u2588"}</span>
</span>
</ScrollArea>
</div>
);
Expand Down

0 comments on commit e14a091

Please sign in to comment.