mirror of https://git.lenooby09.tech/LeNooby09/social-app.git
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

at offline-detection 13 lines 372 B view raw
1import React from 'react' 2import {useTheme} from 'lib/ThemeContext' 3import {choose} from 'lib/functions' 4 5export function useCustomPalette<T>({light, dark}: {light: T; dark: T}) { 6 const theme = useTheme() 7 return React.useMemo(() => { 8 return choose<T, Record<string, T>>(theme.colorScheme, { 9 dark, 10 light, 11 }) 12 }, [theme.colorScheme, dark, light]) 13}