Skip to main content

Stat Ring

A circular progress ring component with gradient strokes, mount animations, glow effects, and optional end-cap markers. SVG-based with customizable size, thickness, and colors.

Installation

$ npx shadcn@latest add @orecus/stat-ring
Dependencies:
motion
Registry:
skeleton@orecus/color-utils@orecus/card

Component

Ring progress indicators in different sizes.

60%
Small
75%
Medium
90%
Large
2,847
Active Users
Out of 5,000 capacity
System Health
All systems operational

Props

PropTypeDefaultDescription
value*numberCurrent value (0 to max)
maxnumber100Maximum value
label*stringLabel text below the ring
colorThemeColor'primary'Ring color
size'sm' | 'md' | 'lg''md'Size variant
thicknessnumberCustom stroke width (overrides size default)
showValuebooleantrueShow value in center
formatValue(value: number, max: number) => stringCustom format function for displayed value
descriptionReactNodeAdditional content below the ring
loadingbooleanfalseShows skeleton loading state
cardPropsCardPropsProps to pass to the Card wrapper
classNamestringAdditional CSS classes
variant'default' | 'gradient''default'Ring style variant - 'gradient' uses SVG gradient for the stroke
animatedbooleanfalseAnimate the ring fill on mount
glowbooleanfalseAdd colored glow/shadow effect behind the ring
trackVariant'subtle' | 'dashed''subtle'Background track styling
iconReactNodeIcon to show in center instead of value
showMarkerbooleanfalseShow a marker dot at the ring progress tip
markerGlowbooleanfalseAdd animated pulse glow to the marker
thresholds{ value: number; color: ThemeColor; label?: string }[]Threshold breakpoints that change ring color based on value ranges