Spaces:
Running
Running
File size: 468 Bytes
a62d4c5 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
interface ProgressProps {
percent: number
}
export default function Progress({ percent }: ProgressProps) {
return (
<div className="w-full flex items-center">
<div className="relative flex-1 bg-black/20 h-2 mr-4">
<div
className="absolute left-0 top-0 h-full bg-black duration-100"
style={{ width: `${percent}%` }}
/>
</div>
<span className="w-20 text-right">{percent.toFixed(2)}%</span>
</div>
)
}
|