8 lines
294 B
TypeScript
8 lines
294 B
TypeScript
import { useMantineTheme } from "@mantine/core";
|
|
import { useColorScheme } from "@mantine/hooks";
|
|
|
|
export function useMainColor () {
|
|
const colorScheme = useColorScheme();
|
|
const theme = useMantineTheme();
|
|
return colorScheme == "light" ? theme.colors.gray[1] : theme.colors.dark[8];
|
|
} |