//=========================================== // THIS FILE IS AUTO-GENERATED FROM TEMPLATE. DO NOT EDIT IT DIRECTLY UNLESS YOU ALSO EDIT THE CORRESPONDING FILE IN packages/template //=========================================== import { useUser } from "../../../lib/hooks"; import { useTranslation } from "../../../lib/translations"; import { PageLayout } from "../page-layout"; import { Switch } from "@hexclave/ui"; import { Separator, Typography } from "@hexclave/ui"; export function NotificationsPage() { const { t } = useTranslation(); const user = useUser({ or: 'redirect' }); const notificationCategories = user.useNotificationCategories(); return (
{t('Choose which emails you want to receive')}
{notificationCategories.map((category) => (
void category.setEnabled(value)} disabled={!category.canDisable} /> {category.name} {!category.canDisable && ( (cannot be disabled) )}
))}
); }