import React from "react"; import { Checkbox } from "./ui/checkbox"; import { Label } from "./ui/label"; import { Settings } from "@/settings"; import { TextTooltip } from "./text-tooltip"; interface SettingsMenuProps { settings: Settings; allowWasm64: boolean; onChange: (settings: Settings) => void; } interface SettingsLabelProps { htmlFor?: string | undefined; text: React.ReactNode; tooltip: React.ReactNode; } function SettingsLabel(props: SettingsLabelProps) { return ( ); } export class SettingsMenu extends React.Component { constructor(props: SettingsMenuProps) { super(props); this.getSettings = this.getSettings.bind(this); this.state = props.settings; } getSettings() { return this.state; } updateSettings(settings: Settings) { this.setState(() => settings); } componentDidUpdate(_: SettingsMenuProps, oldSettings: Settings) { if (JSON.stringify(oldSettings) !== JSON.stringify(this.state)) { this.props.onChange(this.state); } } render() { return (

Settings

Set the settings for the emulation.

{ this.setState({ verbose: checked }); }} />
{ this.setState({ concise: checked }); }} />
{ this.setState({ silent: checked }); }} />
{ this.setState({ bufferStdout: checked }); }} />
{ this.setState({ execAccess: checked }); }} />
{ this.setState({ persist: checked }); }} />
{ this.setState({ wasm64: checked }); }} />
); } }