Tool chipsPro
Code edits and tool calls as compact chips: “4 tool calls, 2 messages”, a live state per chip, then file-diff chips whose diff opens on hover or focus.
oxyn add tool-chipsThe preview stays free for everyone. Pro opens the code of every Pro component, screen, agent-app template, block and kit, plus the Pro CLI.
Rendered from Rust at build time · goes live when visible
When to use
- Code edits and tool calls as compact chips: a header “4 tool calls, 2 messages” that folds; each call as a row with its kind icon, a verb and an inline chip (mono for files and commands), a live state per chip (spinner, failed, needs approval) and details that open per row; then file-diff chips (+18 −4) whose diff previews on hover or focus and pins on click.
- Density rows, chips (chips only, wrapped) or cards.
When not to use
- An agent asks before it acts: use Approval Card instead.
- Several open requests in one card: use Approval pager instead.
- An agent's question in its own card above the composer: use Decision Card instead.
Installation
Tool chips is part of Oxyn Pro; the preview is free. Pro items install with the oxyn CLI once your licence is signed in; until then Pro members copy the code from this page.
oxyn add tool-chipsUsage
The preview is free. Pro opens the code of every Pro component, screen and template.
Examples
Rows
Rows with inline chips, diff chips that preview on hover.
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
Chips
Only the chips, wrapped.
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
Cards
Each call in a card.
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
Live
A test run in progress.
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
API reference
ToolChips
| Prop | Type | Default | Description |
|---|---|---|---|
stepsrequired | Vec<ChipStep> | — | Steps. |
diffsrequired | Vec<DiffChip> | — | Diffs. |
messages | usize | Default::default() | Messages in the run (header count). |
density | String | "rows" | `rows` · `chips` · `cards`. |
open | bool | true | Start open. |
Read from the Rust signature and doc comments.
Keyboard interactions
| Key | Action |
|---|---|
| Tab | Header, each call, each diff chip |
| EnterorSpace | Open a call's details; pin a diff |
| Focus | A focused diff chip previews its diff |
Accessibility
- Diff chips are toggle buttons (aria-pressed) whose preview is a labelled region.
From the spec
- Diff chips are toggle buttons (aria-pressed, aria-expanded) and the preview is a labelled region.
Motion & interaction
Timing
- Reduced motion: no entrance rise or row stagger, no shimmer (static muted text), chevrons and the card morph jump to their end state.
Responsive behaviour
- Chips wrap; the diff preview scrolls sideways.
Edge cases (spec)
- Chips wrap; the preview scrolls sideways.
Notes for AI
- Import
ToolChipsfromoxyn_dioxusand includeSTATUS_INDICATOR_CSSplus the token stylesheet once. - A GPUI version exists:
ToolChipsElinoxyn_gpui. - Props to set first:
steps,diffs. - Keep its states and timings as they ship; restyle it through the CSS variables rather than by hand.