React component for shadcn/ui
Scribbled Text
Mark inline text with colorful hand-drawn annotations.
Scribbled Text is a free, source-available React annotation component for shadcn/ui that marks inline text with twelve hand-drawn SVG underlines, highlights, enclosures, and strikeouts that draw in on scroll. Install it with npx shadcn@latest add @tentui/scribbled-text.
Playground
Features
- Includes twelve underline, highlight, enclosure, and cancellation marks.
- Inherits typography and text color from the surrounding content.
- Draws each annotation once when it enters the viewport.
Installation
pnpm dlx shadcn@latest add @tentui/scribbled-text
Usage
import { ScribbledText } from "@/components/scribbled-text";<p>
This detail is <ScribbledText variant="circle">important</ScribbledText>.
</p>Each phrase stays on one line so its mark remains aligned. Keep annotated phrases short enough to fit their container.
Customize the mark without changing the surrounding text styles.
<ScribbledText variant="arrowUnderline" scribbleClassName="text-rose-400">
Read the announcement
</ScribbledText>Render a complete mark without the drawing animation.
<ScribbledText variant="box" animated={false}>
Always visible
</ScribbledText>Accessibility
Scribble graphics are hidden from assistive technology, leaving the wrapped text
unchanged. The component is visual-only; use semantic elements such as mark or
del when the annotation conveys meaning.
With reduced motion enabled, every annotation renders complete without its drawing animation.
API reference
Examples
Use the variant prop to choose a hand-drawn mark.
Wavy underline
Circle
Highlight
Underline
Straight underline
Dotted underline
Double underline
Strikethrough
Cross out
Arrow underline
Bracket
Box
FAQ
How do I install the Scribbled Text with shadcn?
Run npx shadcn@latest add @tentui/scribbled-text after adding the @tentui
registry to components.json (installation guide), or run
npx shadcn@latest add https://tentui.com/r/scribbled-text.json without it.
The CLI copies scribbled-text.tsx into your project and installs motion.
Which hand-drawn annotations are included, and can I change their color?
Twelve variant values: wavyUnderline (the default), underline,
straightUnderline, dottedUnderline, doubleUnderline, arrowUnderline,
highlight, circle, box, bracket, strikethrough, and crossOut. Each
has its own default color; pass a text color class to scribbleClassName, such
as text-rose-400, to recolor only the mark.
When does the scribble animation play?
Once, when the text scrolls into view, and it doesn't replay after that. Set
animated={false} to render the mark already drawn; it also renders complete
when the user prefers reduced motion.
Why doesn't the annotated phrase wrap onto a second line?
The component keeps the phrase on one line so the mark stays aligned with it. Wrap a short phrase rather than a whole sentence, and it inherits the surrounding font size, weight, and color.
Is Scribbled Text accessible?
The marks are decorative SVGs hidden from screen readers, so the text reads as
it would without them. When an annotation carries meaning, wrap the text in a
semantic element such as mark or del as well.
Is Scribbled Text free to use?
Yes. Scribbled Text is free and source-available: the shadcn CLI copies its source into your project, and you can use it in unlimited personal and client projects under the TentUI License. The license doesn't allow redistributing or reselling the component itself.
Related components
All text and visual effects- Text Scramble
Letters scramble in place through optical-width-matched glyphs and decelerate cleanly onto the final word with zero layout shift while keeping the real text selectable and readable.
- Tile Field
Render a theme-aware wordmark with moving tiles, a color wave, and pointer glow.
- Variable Font Hover
Typography whose weight, width, or custom OpenType axes swell smoothly toward the pointer on per-glyph springs, then ease back to rest with zero layout shift while keeping the text real and selectable.
- ASCII Decode Text
A headline that first appears as ASCII art of its own letter shapes, then a decode front sweeps across and condenses the art into real, crisp, selectable type. After decoding, a pointer lens re-encodes the text under it and heals behind.
Related guides
All guides- How to Add Animations to shadcn Components
Build accessible shadcn animations with source-owned code, shared-layout transitions, async feedback, and reduced-motion support.
- Best Animated shadcn/ui Components in 2026
A guide to TentUI's animated shadcn/ui components by job, from async buttons and pickers to charts, overlays, text effects, and AI thinking UI.