Thumbs pour
Feedback thumbs that fill like a glass, with a meniscus that sloshes and settles, and reasons that unfurl after a thumbs down.
On this page
Rate the answer: ink pours into the thumb and settles; a thumbs down unfurls reasons beside it.
Pick a thumb and ink pours into its outline from the bottom. The surface is a meniscus, two sine waves that slosh hardest mid pour and settle flat as it reaches the top, while the thumb gives a small nod. Change your mind and it drains. A thumbs down then unfurls a few reasons beside it; picking one folds them into a short thanks.
Installation
Usage
import { ThumbsPour } from "@/components/ui/chatcn/thumbs-pour"
<ThumbsPour onValueChange={(v) => rate(message.id, v)} onReason={(r) => note(message.id, r)} />Props
| Prop | Type | Notes |
|---|---|---|
value / defaultValue | "up" | "down" | null | Pressing the chosen thumb again clears it |
onValueChange | (value) => void | |
reasons | string[] | Offered after a thumbs down. [] skips asking |
onReason | (reason: string) => void | |
thanks | string | Default "Thanks, noted" |
Accessibility
aria-pressedthumbs named "Good response" and "Bad response".- The reasons are a labelled group; the thanks is a polite status.
Motion
- The liquid is one clipped SVG path redrawn per frame for 760 ms (420 ms to drain).
- Reasons slide in from the thumb, 45 ms apart, 260 ms each.
Under reduced motion: the thumb fills at once and reasons fade in.