Who it is forA developer building a list of agents or bots, such as a sidebar of chat assistants, where each row needs a small avatar.
The problemA full-size robot with an antenna wastes space in a small avatar slot, and list layouts can clip animations.
The outcomeCompact robot avatars in each row that fill their box, with a clear accessible label for screen readers.
What you need first
- A React project on React 18 or newer, since React is a peer dependency
- Node.js with npm, or pnpm if you plan to work on the library source
- A way to map your agent's status values to the nine states the library supports
Steps
- Run
npm install robot-headsin the project. - Render RobotHead in each list row with antenna={false} and a small size.
- Pass your own aria-label if the default state label does not describe the bot.
- Check that the row container does not use overflow: hidden around the avatar, since hops would be cut off.
- Scroll the list and confirm the avatars sit flush with the text in each row.
Prompt for your agent
In the React project at <project path>, install robot-heads and render a list of agent avatars using RobotHead with antenna={false} and a small size. Expected output: a list component where each avatar keeps its state and has an aria-label. Verify that no parent element in the list uses overflow: hidden around the avatar.
Caveat. The README notes that antenna={false} only drops the stem and light, so the bot still needs the default knob on top and the square or circle shape will look best at small sizes.
Get 5 new use cases every morning. Free, one short email, unsubscribe anytime.
Get them freeShare: X LinkedIn Hacker News Email Copy link
Disclaimer
Deduped lists open-source repositories that belong to other people. We do not own, maintain, audit, or vouch for any of them, and a repo appearing here is not an endorsement or a safety check. The use cases, steps, and prompts are written by AI and may be incomplete, outdated, or just wrong. Where a use case is marked "Seen in the wild", we link to public posts where someone described something similar, but we have not verified those posts and the use case itself is still our AI's own write-up. Use all of this at your own risk. Only run code, commands, or agents on systems and accounts you are authorized to use, and read the code and every command before you run it, especially anything that touches credentials, files, or the network. Nothing here is professional, security, legal, or financial advice. All trademarks and project names belong to their respective owners, and their use here does not imply affiliation. Content is provided as is, without warranties of any kind. Found a mistake, a safety problem, or something you want removed? Email [email protected] and we will look at it promptly. Full disclaimer page