diff --git a/src/components/menu/items/index.ts b/src/components/menu/items/index.ts index dda2e17..b1f4d9f 100644 --- a/src/components/menu/items/index.ts +++ b/src/components/menu/items/index.ts @@ -5,3 +5,4 @@ export { Source as SourceItem } from './source'; export { Presets as PresetsItem } from './presets'; export { Shortcuts as ShortcutsItem } from './shortcuts'; export { SleepTimer as SleepTimerItem } from './sleep-timer'; +export { Lofi as LofiItem } from './lofi'; diff --git a/src/components/menu/items/lofi.tsx b/src/components/menu/items/lofi.tsx new file mode 100644 index 0000000..6a231f0 --- /dev/null +++ b/src/components/menu/items/lofi.tsx @@ -0,0 +1,18 @@ +import { IoIosMusicalNotes } from 'react-icons/io/index'; + +import { Item } from '../item'; + +interface LofiProps { + open: () => void; +} + +export function Lofi({ open }: LofiProps) { + return ( + } + label="Lofi Radios" + shortcut="Shift + L" + onClick={open} + /> + ); +} diff --git a/src/components/menu/menu.tsx b/src/components/menu/menu.tsx index 64c741a..f5291b9 100644 --- a/src/components/menu/menu.tsx +++ b/src/components/menu/menu.tsx @@ -12,12 +12,14 @@ import { PresetsItem, ShortcutsItem, SleepTimerItem, + LofiItem, } from './items'; import { Divider } from './divider'; import { ShareLinkModal } from '@/components/modals/share-link'; import { PresetsModal } from '@/components/modals/presets'; import { ShortcutsModal } from '@/components/modals/shortcuts'; import { SleepTimerModal } from '@/components/modals/sleep-timer'; +import { LofiModal } from '../modals/lofi'; import { fade, mix, slideY } from '@/lib/motion'; import { useSoundStore } from '@/stores/sound'; @@ -32,6 +34,7 @@ export function Menu() { const initial = useMemo( () => ({ + lofi: false, presets: false, shareLink: false, shortcuts: false, @@ -63,6 +66,7 @@ export function Menu() { useHotkeys('shift+h', () => open('shortcuts')); useHotkeys('shift+s', () => open('shareLink'), { enabled: !noSelected }); useHotkeys('shift+t', () => open('sleepTimer')); + useHotkeys('shift+l', () => open('lofi')); useCloseListener(closeAll); @@ -99,6 +103,7 @@ export function Menu() { open('shareLink')} /> open('sleepTimer')} /> + open('lofi')} /> open('shortcuts')} /> @@ -122,6 +127,7 @@ export function Menu() { show={modals.shortcuts} onClose={() => close('shortcuts')} /> + close('lofi')} /> close('presets')} /> void; + show: boolean; +} + +export function LofiModal({ onClose, show }: LofiModalProps) { + const radios = [ + { + src: 'https://www.youtube.com/embed/jfKfPfyJRdk?si=UiaAY0C8Rk6iBIsd', + }, + { + src: 'https://www.youtube.com/embed/4xDzrJKXOOY?si=zyZlOXnoMKr_MWfW', + }, + { + src: 'https://www.youtube.com/embed/S_MOd40zlYU?si=rf1_S-MMiAEIKJoi', + }, + ]; + + return ( + + Lofi Radios + A curated list of Lofi radios. + + + {radios.map((radio, index) => ( + + Radio {padNumber(index + 1)} + + + ))} + + + ); +}
A curated list of Lofi radios.