import type { ComponentProps } from 'react';
import { Slider as ShadSlider } from '@/components/ui/slider';
import { cn } from 'helpers/cn';
import './slider.css';

type SliderProps = {
  small?: boolean;
} & ComponentProps<typeof ShadSlider>;

export const Slider = ({ className, disabled, small, value, ...props }: SliderProps) => {
  return (
    <ShadSlider
      disabled={disabled}
      value={value}
      className={cn('shad-slider', disabled && 'disabled', small && 'small', className)}
      {...props}
    />
  );
};
