import React, { useState } from 'react' import styles from './RangeFilter.module.scss' import TextInput from '../Form/TextInput' import { c } from '../../translations/LibraryTranslationService' export type MinMaxRange = { min?: number max?: number } export type RangeProps = { /** Selected min-max values */ selectedValues: MinMaxRange /** Function to update filter values */ onChangeCallout?: (value: MinMaxRange) => void /** Optional label for min input */ labelTextMin?: string /** Optional label for max input */ labelTextMax?: string /** Optional placeholder for min input */ placeholderMin?: string /** Optional placeholder for max input */ placeholderMax?: string } const RangeFilter = (filterValues: RangeProps): React.JSX.Element => { const { selectedValues, onChangeCallout, labelTextMin, labelTextMax, placeholderMin, placeholderMax, } = filterValues const [error, setError] = useState(false) return (