Loading preview
Analog Clock
Data displayA station clock whose needle waits at twelve; drag the minute hand to set it by hand.
A speedometer-style gauge whose needle sweeps to a score, with colored rating bands.
npx shadcn@latest add @venusui/score-gaugeRun this in a project set up with shadcn. If you haven’t set it up yet, run npx shadcn@latest init first.
Paths use the default shadcn aliases. The CLI follows the aliases in your components.json.
@/components/ui/score-gauge.tsxThe code behind the preview above.
score-gauge-demo.tsx
import { ScoreGauge } from "@/components/ui/score-gauge"
export default function ScoreGaugeDemo() {
return <ScoreGauge className="w-[min(18rem,calc(100vw-3rem))]" value={742} label="Credit score" caption="Updated 2 Nov · +12 this month" />
}
| Prop | Type | Default | Description |
|---|---|---|---|
| value | number | — | The score. |
| min, max | number | 300, 850 | Range of the dial. |
| label | string | — | Accessible name and caption, e.g. “Credit score”. |
| bands | { upTo: number; label: string; color: string }[] | — | Colored ranges; defaults to credit-score bands (Poor to Excellent). |
| caption | string | — | Small text under the rating. |
All <div> props.
bands for other scores, e.g. 0–100 with Poor, Needs work and Great.meter whose value text includes the rating (“742, Very good”).Unknown registry "@venusui"npx shadcn@latest), install by URL, or register it with its address: npx shadcn@latest registry add @venusui=https://venusui.com/r/{name}.json.No components.json foundnpx shadcn@latest init in your project first.A station clock whose needle waits at twelve; drag the minute hand to set it by hand.
Overlapping avatars with a +N counter that spread apart on hover.
Books on a wooden shelf whose spines lift on hover and pull out when selected, with a matching cover.