Fix overload match
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { Slider, Typography, Box, useTheme } from "@mui/material";
|
||||
import { useState, useEffect } from "react";
|
||||
import { useState, useEffect, SyntheticEvent } from "react";
|
||||
import { useTranslation } from "react-i18next";
|
||||
|
||||
type PriceSliderProps = {
|
||||
@@ -25,7 +25,7 @@ export default function PriceSlider({ min = 0, max = 10000, onChange }: PriceSli
|
||||
}
|
||||
};
|
||||
|
||||
const handleCommitted = (_: Event, newValue: number | number[]) => {
|
||||
const handleCommitted = (_: Event | SyntheticEvent<Element, Event>, newValue: number | number[]) => {
|
||||
if (Array.isArray(newValue)) {
|
||||
onChange?.([newValue[0], newValue[1]]);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user