import React from 'react'; interface Controls { animation: string; sep: string; windowSize: number; delayMultiplier: number; animationDuration: number; animationTimingFunction: string; simulateNetworkIssue: boolean; generationSpeed: number; } const Controls = ({ controls, setControls }: { controls: Controls, setControls: React.Dispatch> }) => { const { animation, sep, windowSize, delayMultiplier, animationDuration, animationTimingFunction } = controls; const handleAnimationChange = (e: React.ChangeEvent) => { setControls({ ...controls, animation: e.target.value }); }; const handleSepChange = (e: React.ChangeEvent) => { setControls({ ...controls, sep: e.target.value }); }; const handleWindowSizeChange = (e: React.ChangeEvent) => { setControls({ ...controls, windowSize: parseInt(e.target.value) }); }; const handleDelayMultiplierChange = (e: React.ChangeEvent) => { setControls({ ...controls, delayMultiplier: parseFloat(e.target.value) }); }; const handleAnimationDurationChange = (e: React.ChangeEvent) => { setControls({ ...controls, animationDuration: parseFloat(e.target.value) }); }; const handleAnimationTimingFunctionChange = (e: React.ChangeEvent) => { setControls({ ...controls, animationTimingFunction: e.target.value }); }; return (
); } export default Controls;