ASCII art preview

ASCII art

Animated text-mode pictures for quiet, terminal-style pages: a spinning donut, twelve spinners, progress bars, a CI pipeline, a boot log, a 404, a loading skeleton, sparklines, uptime bars, falling glyphs, plasma and a typewriter. Every frame is plain text in the current colour, so it follows the theme.

  • Group
    Text-mode art
  • Origin
    Copied · ascii.rest (bas3line) · source
  • License
    MIT
  • Added
    Oct 23
npx shadcn@latest add @deank/ascii-art

The registry stays private. Install from the repo with a GitHub token — see the README.

Usage

import { AsciiArt } from "@/registry/components/ascii-art/ascii-art";

<AsciiArt piece={/* … */} />

Props

PropTypeDefaultDescription
pieceAsciiPieceName | PieceA bundled piece by name ("donut", "spinners", "pipeline"…) or any ascii.rest piece module.
options?MountOptionsThe piece's own options (e.g. { phrases: [...] } for typewriter, { code, title, message } for not-found) and fps.
tone?AsciiArtTone"default"Ink colour from my tokens. Default default (the foreground).
size?number12Font size of one cell in px. Ignored when fit is set. Default 12.
fit?booleanfalseScale the cells so the piece fills its container's width (between 6px and maxSize).
maxSize?number18Upper bound for the cell size with fit. Default 18.
paused?booleanfalseHold the first frame (or the piece's chosen still frame). Reduced motion does this on its own.
framed?booleanfalsePut it on a muted, bordered panel.
center?booleanfalseCenter the art in its box.
label?stringWhat the picture shows, for screen readers. Default the piece's own note.

When to use

A bit of quiet motion on a minimal, monospace or developer-facing page: a hero or empty state (`donut`, `plasma`), a 404 page (`not-found`), a loading or install screen (`spinners`, `progress-bar`, `boot-log`, `skeleton`), a status or CI page (`pipeline`, `uptime-bar`, `sparkline`), or a typed tagline (`typewriter`).

When not to use

Real data or real progress (bar-chart, line-chart, progress-tracker: the pieces animate made-up values); a small inline spinner beside text (bars-spinner, dot-matrix-loader); highlighted source code (code-block); colourful illustration (hairline-figure, the card illustrations).

Related

Dot matrix loader · Scramble text · Code block · Hairline figure · Empty state