Spaces:
Runtime error
Runtime error
File size: 561 Bytes
5c920e9 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | import React from "react";
interface TopProgressBarProps {
progress: number; // 0-100
className?: string;
}
export default function TopProgressBar({
progress,
className = "",
}: TopProgressBarProps) {
return (
<div
className={`w-full h-3 rounded-full bg-brand-gray-200 overflow-hidden ${className}`}
>
<div
className="h-full rounded-full bg-gradient-to-r from-brand-teal to-brand-green transition-all duration-500 ease-out"
style={{ width: `${Math.min(100, Math.max(0, progress))}%` }}
/>
</div>
);
}
|