-
Notifications
You must be signed in to change notification settings - Fork 98
Expand file tree
/
Copy pathmenu.jsx
More file actions
21 lines (18 loc) · 757 Bytes
/
menu.jsx
File metadata and controls
21 lines (18 loc) · 757 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
import { Button } from '@/components/ui/button';
import PropTypes from 'prop-types';
export default function Menu({ onStart, onStop, onClear }) {
return (
<div className="w-64 bg-gray-100 p-4 space-y-6">
<h2 className="text-lg font-semibold">Settings</h2>
{/* <Button className="m-1" >Clear Path</Button> */}
<Button className="m-1" onClick={onClear}>Clear Board</Button>
<Button className="w-full" onClick={onStop} >Stop Simulation</Button>
<Button className="w-full" onClick={onStart} >Start Simulation</Button>
</div>
);
}
Menu.propTypes = {
onStart: PropTypes.func.isRequired,
onStop: PropTypes.func.isRequired,
onClear: PropTypes.func.isRequired,
};