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;
|
justify-content: space-between;
|
||||||
gap: var(--space-3);
|
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.Header>
|
||||||
|
|
||||||
<Dialog.Body>
|
<Dialog.Body>
|
||||||
<div className={styles.row}>
|
<div className={styles.rows}>
|
||||||
<Text>{strings.settings.language}</Text>
|
<div className={styles.row}>
|
||||||
<LocaleSelect options={localeOptions} />
|
<Text>{strings.settings.language}</Text>
|
||||||
</div>
|
<LocaleSelect options={localeOptions} />
|
||||||
|
</div>
|
||||||
|
|
||||||
<div className={styles.row}>
|
<div className={styles.row}>
|
||||||
<Text>{strings.settings.reduce_motion.title}</Text>
|
<Text>{strings.settings.reduce_motion.title}</Text>
|
||||||
|
|
||||||
<Select.Root
|
<Select.Root
|
||||||
value={`${reduceMotion}`}
|
value={`${reduceMotion}`}
|
||||||
onValueChange={(value) => {
|
onValueChange={(value) => {
|
||||||
App.mutate((draft) => {
|
App.mutate((draft) => {
|
||||||
draft.reduceMotion = Number(value);
|
draft.reduceMotion = Number(value);
|
||||||
});
|
});
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<Select.Trigger>
|
<Select.Trigger>
|
||||||
<Select.Value />
|
<Select.Value />
|
||||||
|
|
||||||
<Select.Icon>
|
<Select.Icon>
|
||||||
<CaretDownIcon />
|
<CaretDownIcon />
|
||||||
</Select.Icon>
|
</Select.Icon>
|
||||||
</Select.Trigger>
|
</Select.Trigger>
|
||||||
|
|
||||||
<Select.Portal>
|
<Select.Portal>
|
||||||
<Select.Content>
|
<Select.Content>
|
||||||
<Select.Viewport>
|
<Select.Viewport>
|
||||||
<Select.Item value={`${ReduceMotion.Device}`}>
|
<Select.Item value={`${ReduceMotion.Device}`}>
|
||||||
<Select.ItemIndicator>
|
<Select.ItemIndicator>
|
||||||
<DotFilledIcon />
|
<DotFilledIcon />
|
||||||
</Select.ItemIndicator>
|
</Select.ItemIndicator>
|
||||||
|
|
||||||
<Select.ItemText>
|
<Select.ItemText>
|
||||||
{strings.settings.device_preference}
|
{strings.settings.device_preference}
|
||||||
</Select.ItemText>
|
</Select.ItemText>
|
||||||
</Select.Item>
|
</Select.Item>
|
||||||
|
|
||||||
<Select.Separator />
|
<Select.Separator />
|
||||||
|
|
||||||
<Select.Item value={`${ReduceMotion.On}`}>
|
<Select.Item value={`${ReduceMotion.On}`}>
|
||||||
<Select.ItemIndicator>
|
<Select.ItemIndicator>
|
||||||
<DotFilledIcon />
|
<DotFilledIcon />
|
||||||
</Select.ItemIndicator>
|
</Select.ItemIndicator>
|
||||||
|
|
||||||
<Select.ItemText>
|
<Select.ItemText>
|
||||||
{strings.settings.reduce_motion.on}
|
{strings.settings.reduce_motion.on}
|
||||||
</Select.ItemText>
|
</Select.ItemText>
|
||||||
</Select.Item>
|
</Select.Item>
|
||||||
|
|
||||||
<Select.Item value={`${ReduceMotion.Off}`}>
|
<Select.Item value={`${ReduceMotion.Off}`}>
|
||||||
<Select.ItemIndicator>
|
<Select.ItemIndicator>
|
||||||
<DotFilledIcon />
|
<DotFilledIcon />
|
||||||
</Select.ItemIndicator>
|
</Select.ItemIndicator>
|
||||||
|
|
||||||
<Select.ItemText>
|
<Select.ItemText>
|
||||||
{strings.settings.reduce_motion.off}
|
{strings.settings.reduce_motion.off}
|
||||||
</Select.ItemText>
|
</Select.ItemText>
|
||||||
</Select.Item>
|
</Select.Item>
|
||||||
</Select.Viewport>
|
</Select.Viewport>
|
||||||
</Select.Content>
|
</Select.Content>
|
||||||
</Select.Portal>
|
</Select.Portal>
|
||||||
</Select.Root>
|
</Select.Root>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className={styles.row}>
|
<div className={styles.row}>
|
||||||
<Text>{strings.settings.auto_load_models}</Text>
|
<Text>{strings.settings.auto_load_models}</Text>
|
||||||
<Switch
|
<Switch
|
||||||
checked={autoLoadModels}
|
checked={autoLoadModels}
|
||||||
onCheckedChange={(checked) => {
|
onCheckedChange={(checked) => {
|
||||||
App.mutate((draft) => {
|
App.mutate((draft) => {
|
||||||
draft.autoLoadModels = checked;
|
draft.autoLoadModels = checked;
|
||||||
});
|
});
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className={styles.row}>
|
<div className={styles.row}>
|
||||||
<Text>{strings.settings.developer_mode}</Text>
|
<Text>{strings.settings.developer_mode}</Text>
|
||||||
<Switch
|
<Switch
|
||||||
checked={developerMode}
|
checked={developerMode}
|
||||||
onCheckedChange={(checked) => {
|
onCheckedChange={(checked) => {
|
||||||
App.mutate((draft) => {
|
App.mutate((draft) => {
|
||||||
draft.developerMode = checked;
|
draft.developerMode = checked;
|
||||||
});
|
});
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</Dialog.Body>
|
</Dialog.Body>
|
||||||
</Dialog.Content>
|
</Dialog.Content>
|
||||||
|
|||||||
Reference in new issue
Block a user