'use client'; import { cn } from '@/lib/utils'; import type { ProjectStatus } from '@/types/database'; interface ProgressRingProps { progress: number; status: ProjectStatus; size?: number; strokeWidth?: number; showPercentage?: boolean; className?: string; } export function ProgressRing({ progress, status, size = 64, strokeWidth = 4, showPercentage = true, className, }: ProgressRingProps) { const radius = (size - strokeWidth) / 2; const circumference = radius * 2 * Math.PI; const normalizedProgress = Math.min(Math.max(progress, 0), 1); const strokeDashoffset = circumference - normalizedProgress * circumference; const strokeColor = status === 'green' ? 'stroke-emerald-500' : status === 'yellow' ? 'stroke-amber-500' : 'stroke-rose-500'; const textColor = status === 'green' ? 'text-emerald-600' : status === 'yellow' ? 'text-amber-600' : 'text-rose-600'; return (