♻️ Improved code structure for layout, remove most settings components

This commit is contained in:
Meier Lukas
2023-08-01 15:23:31 +02:00
parent 6b8d94b6b5
commit 65d0b31a1a
48 changed files with 103 additions and 1575 deletions

View File

@@ -0,0 +1,25 @@
import { Stack, Switch } from '@mantine/core';
import { useTranslation } from 'react-i18next';
import { useFormContext } from '~/pages/user/preferences';
export const AccessibilitySettings = () => {
const { t } = useTranslation('user/preferences');
const form = useFormContext();
return (
<Stack>
<Switch
label={t('disablePulse.label')}
description={t('disablePulse.description')}
{...form.getInputProps('disablePingPulse', { type: 'checkbox' })}
/>
<Switch
label={t('replaceIconsWithDots.label')}
description={t('replaceIconsWithDots.description')}
{...form.getInputProps('replaceDotsWithIcons', { type: 'checkbox' })}
/>
</Stack>
);
};