refactor: cleanup display options layout

This commit is contained in:
Carlos Valente
2025-06-20 21:18:31 +02:00
committed by Carlos Valente
parent a21fdc8481
commit 4827b295fa
@@ -29,6 +29,7 @@ interface EventEditorTimesProps {
type HandledActions = 'countToEnd' | 'timerType' | 'endAction' | 'timeWarning' | 'timeDanger'; type HandledActions = 'countToEnd' | 'timerType' | 'endAction' | 'timeWarning' | 'timeDanger';
export default memo(EventEditorTimes);
function EventEditorTimes(props: EventEditorTimesProps) { function EventEditorTimes(props: EventEditorTimesProps) {
const { const {
eventId, eventId,
@@ -153,34 +154,31 @@ function EventEditorTimes(props: EventEditorTimesProps) {
<option value={TimerType.None}>None</option> <option value={TimerType.None}>None</option>
</Select> </Select>
</div> </div>
<div>
{/* TODO: rearrange this grid */}
</div>
<div>
<Editor.Label htmlFor='timeWarning'>Warning Time</Editor.Label>
<TimeInput
id='timeWarning'
name='timeWarning'
submitHandler={handleSubmit}
time={timeWarning}
placeholder='Duration'
/>
</div>
<div> <div className={style.inline}>
<Editor.Label htmlFor='timeDanger'>Danger Time</Editor.Label> <div>
<TimeInput <Editor.Label htmlFor='timeWarning'>Warning Time</Editor.Label>
id='timeDanger' <TimeInput
name='timeDanger' id='timeWarning'
submitHandler={handleSubmit} name='timeWarning'
time={timeDanger} submitHandler={handleSubmit}
placeholder='Duration' time={timeWarning}
/> placeholder='Duration'
/>
</div>
<div>
<Editor.Label htmlFor='timeDanger'>Danger Time</Editor.Label>
<TimeInput
id='timeDanger'
name='timeDanger'
submitHandler={handleSubmit}
time={timeDanger}
placeholder='Duration'
/>
</div>
</div> </div>
</div> </div>
</div> </div>
</> </>
); );
} }
export default memo(EventEditorTimes);