💃🏻 Settings menu styling

This commit is contained in:
ajnart
2022-08-02 02:21:04 +02:00
parent 847e0855d8
commit 12c13de1bd
4 changed files with 10 additions and 10 deletions

View File

@@ -1,4 +1,4 @@
import { Checkbox, Group, SimpleGrid, Title } from '@mantine/core';
import { Checkbox, Group, SimpleGrid, Stack, Title } from '@mantine/core';
import * as Modules from '../../modules';
import { useConfig } from '../../tools/state';
@@ -6,13 +6,13 @@ export default function ModuleEnabler(props: any) {
const { config, setConfig } = useConfig();
const modules = Object.values(Modules).map((module) => module);
return (
<Group direction="column">
<Stack>
<Title order={4}>Module enabler</Title>
<SimpleGrid cols={2} spacing="md">
<SimpleGrid cols={3} spacing="xs">
{modules.map((module) => (
<Checkbox
key={module.title}
size="md"
size="sm"
checked={config.modules?.[module.title]?.enabled ?? false}
label={`${module.title}`}
onChange={(e) => {
@@ -30,6 +30,6 @@ export default function ModuleEnabler(props: any) {
/>
))}
</SimpleGrid>
</Group>
</Stack>
);
}