Components
Loading preview...
An input where the user selects a value from within a given range.
npx shadcn@latest add https://21st.dev/r/shadcn/sliderimport { cn } from "@/lib/utils"
import { Slider } from "@/components/ui/slider"
type SliderProps = React.ComponentProps<typeof Slider>
export function SliderDemo({ className, ...props }: SliderProps) {
return (
<Slider
defaultValue={[50]}
max={100}
step={1}
className={cn("w-[60%]", className)}
{...props}
/>
)
}