1// SPDX-License-Identifier: GPL-2.0-only
2// Copyright (c) 2025-present FERS Contributors (see AUTHORS.md).
12} from '@mui/material';
13import { useScenarioStore } from '@/stores/scenarioStore';
14import { NumberField } from './inspectors/InspectorControls';
15import LogLevelSelect from './LogLevelSelect';
17interface SettingsDialogProps {
22export default function SettingsDialog({ open, onClose }: SettingsDialogProps) {
23 const targetPlaybackDuration = useScenarioStore(
24 (s) => s.targetPlaybackDuration
26 const setTargetPlaybackDuration = useScenarioStore(
27 (s) => s.setTargetPlaybackDuration
30 <Dialog open={open} onClose={onClose} maxWidth="xs" fullWidth>
31 <DialogTitle>Application Settings</DialogTitle>
36 flexDirection: 'column',
42 Global application settings. Scenario parameters are
43 edited in the Property Inspector.
45 <LogLevelSelect id="settings-log-level" />
47 label="Target Preview Playback Duration (s)"
48 value={targetPlaybackDuration}
49 onChange={(val) => setTargetPlaybackDuration(val)}
51 <Typography variant="caption">
52 Set a fixed real-world duration for the simulation
53 preview. Leave blank for default behavior (real-time
54 playback, with a minimum of 5 seconds for short
60 <Button onClick={onClose}>Close</Button>