Agent Orb

One living shape for a voice assistant: idle, listening, thinking, speaking.

PROGet Agent Orb and 168 other Pro components with pro lifetime — Get Pro

Category
Creative
Access
Pro
Source
306 lines · one file
States
6 drawn

The decision inside it

Each state moves differently, not just in a different colour

Someone glancing at it knows the state without a label, and a label is still announced to screen readers when it changes. Every amplitude glides to its new target, so changing state looks like one creature changing its mind. Off screen it stops; reduced motion draws each state still.

When to use it

Use Agent Orb as the face of a voice assistant: one shape that shows idle, listening, thinking and speaking. Drive state from your audio pipeline; pass level for real input volume.

Installation

How you get it

Paste this into Claude Code, Cursor, Codex or any coding agent. It installs the file and uses it as it is, instead of writing a new one.

Use Liro's Agent Orb for this.
Install it: npx shadcn@latest add @liro/agent-orb
(the @liro registry is set up in components.json, with LIRO_KEY in .env.local)
Import it from @/components/ui/agent-orb.
Do not rewrite or restyle it. Pass my data through its props
and keep its built-in states.

For the full brief with every prop and the mistakes assistants usually make, use Copy prompt above. Pro components install through the @liro registry with your CLI token: see the Namespaced tab.

Usage

components/voice-orb.tsx
import { AgentOrb, type AgentOrbState } from "@/components/ui/agent-orb";

export function VoiceOrb({ state, level }: { state: AgentOrbState; level?: number }) {
  return <AgentOrb state={state} level={level} size={180} />;
}

API reference

“Copy prompt” above puts a full brief on your clipboard, install command, dependencies, props, and the mistakes an assistant usually makes with this component.

Props

Read from the component’s own TypeScript interface when the site is built, so this table cannot drift from the file you install.

TypeNotes
stateAgentOrbState NoWhat the assistant is doing. Default `idle`.
levelnumber NoAudio level, 0 to 1. Generated when left out.
sizenumber NoDiameter of the orb, in px. Default 168.
colorClassNamestring NoMain colour class, read as `color`. Default blue.
accentClassNamestring NoSecond colour class, read as `color`. Default sky.
labelsPartial<Record<AgentOrbState, string>> NoWords announced for each state.
look"soft" | "glass" No–

Dependencies

npm packages

clsxframer-motiontailwind-merge

Liro foundations, installed alongside it

liro-theme

States

All of them are drawn by the component. None is left for you to design.

  • Idle
  • Listening
  • Thinking
  • Speaking
  • Live audio level
  • Reduced motion

Accessibility

  • Keyboard reachable throughout, in visual order
  • Focus trapped in overlays, Escape closes them
  • Focus returns to whatever opened it
  • Live regions announce what changed, not that something did
  • Honours prefers-reduced-motion

Responsive behavior

  • Sizes to its container, not the viewport
  • Usable from 320px up
  • Pointer-based interaction, so trackpad and touch both work
  • No hover-only affordances