Xzero UI
Pro library

Pixel mascotPro

A pixel-art robot that shows what an AI assistant is doing. It idles, thinks, types, celebrates and errors in frame-stepped sprite animations, and stays crisp at every integer size from 24px to 192px.

$ pnpm dlx shadcn@4.23.0 add @xzero-ui-pro/pixel-mascot
Live · keyboard ready

When to use

When not to use

Installation

Register both Xzero UI namespaces in your project's components.json:

{
  "registries": {
    "@xzero-ui": "https://mcp.xzero.co.uk/r/{name}.json",
    "@xzero-ui-pro": "https://mcp.xzero.co.uk/r/pro/{name}.json"
  }
}
npx shadcn@4.23.0 add @xzero-ui-pro/pixel-mascot

Install xzero-foundation once, and import @/components/xzero/foundation.css in your app root. No Xzero token is used by this snapshot. For sample portraits, photos, fonts, or logos, download https://mcp.xzero.co.uk/install-assets.mjs and run node xzero-install-assets.mjs <receiving-project>.

Usage

import { PixelMascot } from "@/components/xzero/pixel-mascot/pixel-mascot";

// Inline next to a streaming reply
<PixelMascot status={isStreaming ? "writing" : "thinking"} size={2} name="Claude Sonnet 5.5" announce={false} />

// Empty state or composer, self playing
<PixelMascot size={6} />

API reference

PixelMascot

A pixel art robot on a 24 by 24 grid that shows what an assistant is doing. Every state is a frame based sprite animation on a fixed 40ms clock, and status changes morph from the current pose one pixel at a time.

PropTypeDefaultDescription
status"idle" | "thinking" | "writing" | "done" | "error"–What the assistant is doing. Leave it out to play the built in loop through every state.
sizenumber4Integer pixel scale from 1 to 8. Each sprite pixel is this many CSS pixels: 1 renders 24px, 2 renders 48px, 4 renders 96px, 8 renders 192px. Other values round and clamp.
namestring"Assistant"Who the mascot stands for, used in the accessible label ("Xzero is thinking").
labelstring–Replaces the generated accessible label.
announceboolean–Announces status changes in a polite live region. Defaults to true when status is controlled and false for the built in loop. Turn it off when nearby text already announces progress.
pausedbooleanfalseFreezes the animation on the current frame. The mascot also pauses by itself while off screen.
classNamestring–Class for the inline wrapper.
styleCSSProperties–Style for the inline wrapper, for example a custom --accent.

usePixelMascotLoop

Hook that returns the built in status loop (idle, thinking, writing, done, idle, thinking, error). Use it to keep several mascots in step.

PropTypeDefaultDescription
enabledbooleantruePass false to hold the current status.

Accessibility

Motion

Responsive behavior

Performance

Notes for AI

Also in ai

Guidance for AI tools

Pixel mascot: A pixel-art robot that shows what an AI assistant is doing. It idles, thinks, types, celebrates and errors in frame-stepped sprite animations, and stays crisp at every integer size from 24px to 192px. Follow the declared prop types and do not invent props. Keep keyboard access, reduced motion support, and both light and dark themes intact when adapting it.

Full library index: https://ui.xzero.co.uk/llms.txt

Browse all components