Installation
Usage
Props
| Prop | Type | Default | Description |
|---|---|---|---|
title | string | "Activity Rings" | Card title |
className | string | - | Additional CSS classes |
Features
- Three Activity Rings: Move, Exercise, Stand
- Progress Animation: Smooth SVG stroke animation
- Gradient Colors: Linear gradients for each ring
- Staggered Entrance: Sequential animation with delays
- Real-time Data: Current/target values displayed
- Responsive Layout: Adapts to container size
- Ring Sizing: Nested concentric circles
Activity Data
Default Activities
ActivityData Interface
Animation Configuration
Ring Animation
Entrance Animation
SVG Technical Details
Circle Calculation
Gradient Definition
Customization Example
Styling Details
Ring Colors
- Move: Pink (#FF2D55) → Light Pink (#FF6B8B)
- Exercise: Lime (#A3F900) → Yellow-Green (#C5FF4D)
- Stand: Cyan (#04C7DD) → Light Cyan (#4DDFED)
Ring Stroke
- Width: 16px
- Cap: Rounded
- Background: Semi-transparent gray
- Drop shadow on active ring
Layout
Ring Container
- Width: 180px
- Height: 180px
- Centered alignment
- Concentric positioning
Details Panel
- Positioned to right of rings
- Vertical stack layout
- Color-coded labels
- Current/Target ratio display
Dependencies
motion(Framer Motion)@/lib/utils(cn helper)
Accessibility
- ARIA labels on SVG elements
- Semantic heading structure
- Screen reader friendly values
- Reduced motion support