mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-12-04 23:32:54 +01:00
balanced setting layout
This commit is contained in:
2 files changed
+83
-74
No files matched your search
@@ -9,3 +9,10 @@
|
||||
justify-content: space-between;
|
||||
gap: var(--space-3);
|
||||
}
|
||||
|
||||
/* Every row matches the tallest one, so switch rows line up with select rows */
|
||||
.rows {
|
||||
display: grid;
|
||||
grid-auto-rows: 1fr;
|
||||
gap: var(--space-3);
|
||||
}
|
||||
@@ -44,92 +44,94 @@ export const SettingsDialog = withLocale(
|
||||
</Dialog.Header>
|
||||
|
||||
<Dialog.Body>
|
||||
<div className={styles.row}>
|
||||
<Text>{strings.settings.language}</Text>
|
||||
<LocaleSelect options={localeOptions} />
|
||||
</div>
|
||||
<div className={styles.rows}>
|
||||
<div className={styles.row}>
|
||||
<Text>{strings.settings.language}</Text>
|
||||
<LocaleSelect options={localeOptions} />
|
||||
</div>
|
||||
|
||||
<div className={styles.row}>
|
||||
<Text>{strings.settings.reduce_motion.title}</Text>
|
||||
<div className={styles.row}>
|
||||
<Text>{strings.settings.reduce_motion.title}</Text>
|
||||
|
||||
<Select.Root
|
||||
value={`${reduceMotion}`}
|
||||
onValueChange={(value) => {
|
||||
App.mutate((draft) => {
|
||||
draft.reduceMotion = Number(value);
|
||||
});
|
||||
}}
|
||||
>
|
||||
<Select.Trigger>
|
||||
<Select.Value />
|
||||
<Select.Root
|
||||
value={`${reduceMotion}`}
|
||||
onValueChange={(value) => {
|
||||
App.mutate((draft) => {
|
||||
draft.reduceMotion = Number(value);
|
||||
});
|
||||
}}
|
||||
>
|
||||
<Select.Trigger>
|
||||
<Select.Value />
|
||||
|
||||
<Select.Icon>
|
||||
<CaretDownIcon />
|
||||
</Select.Icon>
|
||||
</Select.Trigger>
|
||||
<Select.Icon>
|
||||
<CaretDownIcon />
|
||||
</Select.Icon>
|
||||
</Select.Trigger>
|
||||
|
||||
<Select.Portal>
|
||||
<Select.Content>
|
||||
<Select.Viewport>
|
||||
<Select.Item value={`${ReduceMotion.Device}`}>
|
||||
<Select.ItemIndicator>
|
||||
<DotFilledIcon />
|
||||
</Select.ItemIndicator>
|
||||
<Select.Portal>
|
||||
<Select.Content>
|
||||
<Select.Viewport>
|
||||
<Select.Item value={`${ReduceMotion.Device}`}>
|
||||
<Select.ItemIndicator>
|
||||
<DotFilledIcon />
|
||||
</Select.ItemIndicator>
|
||||
|
||||
<Select.ItemText>
|
||||
{strings.settings.device_preference}
|
||||
</Select.ItemText>
|
||||
</Select.Item>
|
||||
<Select.ItemText>
|
||||
{strings.settings.device_preference}
|
||||
</Select.ItemText>
|
||||
</Select.Item>
|
||||
|
||||
<Select.Separator />
|
||||
<Select.Separator />
|
||||
|
||||
<Select.Item value={`${ReduceMotion.On}`}>
|
||||
<Select.ItemIndicator>
|
||||
<DotFilledIcon />
|
||||
</Select.ItemIndicator>
|
||||
<Select.Item value={`${ReduceMotion.On}`}>
|
||||
<Select.ItemIndicator>
|
||||
<DotFilledIcon />
|
||||
</Select.ItemIndicator>
|
||||
|
||||
<Select.ItemText>
|
||||
{strings.settings.reduce_motion.on}
|
||||
</Select.ItemText>
|
||||
</Select.Item>
|
||||
<Select.ItemText>
|
||||
{strings.settings.reduce_motion.on}
|
||||
</Select.ItemText>
|
||||
</Select.Item>
|
||||
|
||||
<Select.Item value={`${ReduceMotion.Off}`}>
|
||||
<Select.ItemIndicator>
|
||||
<DotFilledIcon />
|
||||
</Select.ItemIndicator>
|
||||
<Select.Item value={`${ReduceMotion.Off}`}>
|
||||
<Select.ItemIndicator>
|
||||
<DotFilledIcon />
|
||||
</Select.ItemIndicator>
|
||||
|
||||
<Select.ItemText>
|
||||
{strings.settings.reduce_motion.off}
|
||||
</Select.ItemText>
|
||||
</Select.Item>
|
||||
</Select.Viewport>
|
||||
</Select.Content>
|
||||
</Select.Portal>
|
||||
</Select.Root>
|
||||
</div>
|
||||
<Select.ItemText>
|
||||
{strings.settings.reduce_motion.off}
|
||||
</Select.ItemText>
|
||||
</Select.Item>
|
||||
</Select.Viewport>
|
||||
</Select.Content>
|
||||
</Select.Portal>
|
||||
</Select.Root>
|
||||
</div>
|
||||
|
||||
<div className={styles.row}>
|
||||
<Text>{strings.settings.auto_load_models}</Text>
|
||||
<Switch
|
||||
checked={autoLoadModels}
|
||||
onCheckedChange={(checked) => {
|
||||
App.mutate((draft) => {
|
||||
draft.autoLoadModels = checked;
|
||||
});
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
<div className={styles.row}>
|
||||
<Text>{strings.settings.auto_load_models}</Text>
|
||||
<Switch
|
||||
checked={autoLoadModels}
|
||||
onCheckedChange={(checked) => {
|
||||
App.mutate((draft) => {
|
||||
draft.autoLoadModels = checked;
|
||||
});
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div className={styles.row}>
|
||||
<Text>{strings.settings.developer_mode}</Text>
|
||||
<Switch
|
||||
checked={developerMode}
|
||||
onCheckedChange={(checked) => {
|
||||
App.mutate((draft) => {
|
||||
draft.developerMode = checked;
|
||||
});
|
||||
}}
|
||||
/>
|
||||
<div className={styles.row}>
|
||||
<Text>{strings.settings.developer_mode}</Text>
|
||||
<Switch
|
||||
checked={developerMode}
|
||||
onCheckedChange={(checked) => {
|
||||
App.mutate((draft) => {
|
||||
draft.developerMode = checked;
|
||||
});
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</Dialog.Body>
|
||||
</Dialog.Content>
|
||||
|
||||
Reference in new issue
Block a user