import React from 'react'; import { useAtomValue, useSetAtom } from 'jotai'; import { Box, Button, Text, IconButton, Icon, Icons, IconSrc, Scroll, config, toRem } from 'folds'; import { Page, PageContent, PageHeader } from '../../../components/page'; import { SystemNotification } from './SystemNotification'; import { AllMessagesNotifications } from './AllMessages'; import { SpecialMessagesNotifications } from './SpecialMessages'; import { KeywordMessagesNotifications } from './KeywordMessages'; import { PushRuleEditor } from './PushRuleEditor'; import { SequenceCard } from '../../../components/sequence-card'; import { SequenceCardStyle } from '../styles.css'; import { SettingTile } from '../../../components/setting-tile'; import { settingsAtom, Settings } from '../../../state/settings'; const PRESETS: Array<{ label: string; icon: IconSrc; description: string; patch: Partial; }> = [ { label: 'Gaming', icon: Icons.Ball, description: 'Notifications on, sounds off', patch: { showNotifications: true, isNotificationSounds: false, messageSoundId: 'none', inviteSoundId: 'none', quietHoursEnabled: false, }, }, { label: 'Work', icon: Icons.Monitor, description: 'All notifications and sounds on', patch: { showNotifications: true, isNotificationSounds: true, messageSoundId: 'notification', inviteSoundId: 'invite', quietHoursEnabled: false, }, }, { label: 'Sleep', icon: Icons.BellMute, description: 'All notifications off', patch: { showNotifications: false, isNotificationSounds: false, quietHoursEnabled: false, }, }, ]; function NotificationPresets() { const settings = useAtomValue(settingsAtom); const setSettings = useSetAtom(settingsAtom); const applyPreset = (patch: Partial) => { setSettings({ ...settings, ...patch }); }; return ( Quick Presets {PRESETS.map((preset) => ( ))} ); } type NotificationsProps = { requestClose: () => void; }; export function Notifications({ requestClose }: NotificationsProps) { return ( Notifications Block Messages ); }