[ABANDONED] React/Redux front end for the Flexor social network.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

22 lines
500 B

4 years ago
  1. import React, { FC } from 'react'
  2. import { useTheme } from '../hooks'
  3. interface Props {
  4. value: number
  5. onChange: (value: number) => void
  6. }
  7. const Slider: FC<Props> = ({ value, onChange }) => {
  8. const theme = useTheme()
  9. return (
  10. <input
  11. type="range"
  12. min="0"
  13. max="100"
  14. style={{ backgroundColor: '#ccc' }}
  15. value={value}
  16. onChange={e => onChange(parseInt(e.target.value, 10))} />
  17. )
  18. }
  19. export default Slider