import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; import { defineMessages, useIntl } from 'react-intl'; const messages = defineMessages({ notificationsettings: 'Notification Settings', notificationsettingsDescription: 'Here you can pick and choose what types of notifications to send and through what types of services.', }); interface SettingsRoute { text: string; route: string; regex: RegExp; } const settingsRoutes: SettingsRoute[] = [ { text: 'Email', route: '/settings/notifications/email', regex: /^\/settings\/notifications\/email/, }, { text: 'Discord', route: '/settings/notifications/discord', regex: /^\/settings\/notifications\/discord/, }, ]; const SettingsNotifications: React.FC = ({ children }) => { const router = useRouter(); const intl = useIntl(); const activeLinkColor = 'bg-gray-700'; const inactiveLinkColor = ''; const SettingsLink: React.FC<{ route: string; regex: RegExp; isMobile?: boolean; }> = ({ children, route, regex, isMobile = false }) => { if (isMobile) { return ; } return ( {children} ); }; return ( <>

{intl.formatMessage(messages.notificationsettings)}

{intl.formatMessage(messages.notificationsettingsDescription)}

{children}
); }; export default SettingsNotifications;