I Am Trying to Customize Progress Bar Color. So What is the good Way to Do that #1581
clevermiraz
started this conversation in
General
Replies: 1 comment
-
I added the fill prop to the Progress component. const Progress = React.forwardRef<
React.ElementRef<typeof ProgressPrimitive.Root>,
React.ComponentPropsWithoutRef<typeof ProgressPrimitive.Root> & {
fill?: "primary" | "secondary" | "accent" | "warning" | "destructive";
}
>(({ className, value, fill = "primary", ...props }, ref) => (
// ...
<ProgressPrimitive.Indicator
className={`h-full w-full flex-1 bg-${fill} transition-all`}
/>
// ... There's probably a better way to type the <Progress fill="destructive"/> |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
https://ui.shadcn.com/docs/components/progress
This is the progress bar.
Beta Was this translation helpful? Give feedback.
All reactions