(event: ChangeEvent<HTMLInputElement>)
| 23 | const [mayPlay, setMayPlay] = useState(true); |
| 24 | |
| 25 | function handleVolumeChange(event: ChangeEvent<HTMLInputElement>) { |
| 26 | const inputValue = Number(event.target.value); |
| 27 | |
| 28 | store.set('soundVolume', inputValue); |
| 29 | |
| 30 | setVolumeDisplay((store.get('soundVolume') as number) ?? 50); |
| 31 | |
| 32 | if (mayPlay) { |
| 33 | void playTone('tests-completed'); |
| 34 | setMayPlay(false); |
| 35 | setTimeout(() => { |
| 36 | setMayPlay(true); |
| 37 | }, 200); |
| 38 | } |
| 39 | } |
| 40 | |
| 41 | return ( |
| 42 | <> |
nothing calls this directly
no test coverage detected