Skip to content

Commit

Permalink
removed defaultValue prop from slider
Browse files Browse the repository at this point in the history
  • Loading branch information
rohitmalhotra1420 committed Sep 11, 2024
1 parent 822d60d commit 52b9b3f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 10 deletions.
11 changes: 2 additions & 9 deletions src/blocks/slider/Slider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,17 +39,10 @@ const StyledSlider = styled(ReactSlider)<{ range?: boolean }>`
`}
`;

const Slider = <T extends number | [number, number]>({
min,
max,
onChange,
value,
step,
defaultValue,
}: SliderProps<T>) => {
const Slider = <T extends number | [number, number]>({ min, max, onChange, value, step }: SliderProps<T>) => {
return (
<StyledSlider
{...{ min, max, value, step, defaultValue }}
{...{ min, max, value, step }}
className="horizontal-slider"
thumbClassName="horizontal-slider-thumb"
trackClassName="horizontal-slider-track"
Expand Down
1 change: 0 additions & 1 deletion src/blocks/slider/Slider.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,4 @@ export type SliderBaseProps = {
export type SliderProps<T> = SliderBaseProps & {
value?: T;
onChange: (value: T) => void;
defaultValue?: T;
};

0 comments on commit 52b9b3f

Please sign in to comment.