Components
Arc Gauge 360
Full-circle radial tick gauge with SVG-centered value text. The full-rotation companion to Arc Gauge.
Arc Gauge 360
Full-circle radial gauge. Ticks are distributed evenly around 360° (no overlap between first and last), and the value is rendered as an SVG <text> element anchored to the arc's geometric center (0, 0) — no matter the size.
Use this variant when you need a complete rotation; use arc-gauge for half-moon or partial sweeps where the value anchors to the arc's chord.
Preview
Loading preview...
Installation
Terminal
$npx shadcn@latest add @vandoko/arc-gauge-360Usage
import { ArcGauge360 } from "@/components/arc-gauge-360";
export default function Page() {
return <ArcGauge360 value={72} ticks={72} showValue />;
}Formatted Value
<ArcGauge360
value={0.86}
max={1}
ticks={60}
showValue
valueFormatter={(v) => `${Math.round(v * 100)}%`}
/>Props
| Prop | Type | Default | Notes |
|---|---|---|---|
value | number | — | Current value (required) |
max | number | 100 | Max value |
ticks | number | 72 | Total tick count (≥ 2). Evenly spaced around 360° |
startAngle | number | -90 | Angle of first tick in degrees — -90 = 12 o'clock |
radius | number | 140 | Arc radius (SVG units) |
tickLength | number | 18 | Filled tick length |
tickWidth | number | 2 | Tick stroke width |
fillColor / emptyColor | string | theme tokens | Override tick colors |
showValue | boolean | false | Render centered numeric readout |
valueFormatter | (v, m) => string | — | Format the readout + ARIA text |
valueClassName | string | — | Extra classes on the centered <text> |
valueFontSize | number | radius * 0.42 | SVG font size for the readout |
Features
- Full-circle distribution — Ticks divide
360 / ticksso the last tick never overlaps the first - SVG-centered value —
<text>at(0, 0)withtextAnchor="middle"/dominantBaseline="central" - Theme-driven — Tick colors come from
var(--foreground)/var(--muted-foreground) - Scalable value text —
valueFontSizedefaults toradius * 0.42, override as needed - Accessible —
role="meter"witharia-valuemin/max/now/text
Lineage
| Property | Value |
|---|---|
| Source | @vandoko/arc-gauge-360 |
| Curated | 2026-04-21 |
| License | MIT |
| Dependencies | None |