UNPKG

@codegouvfr/react-dsfr

Version:

French State Design System React integration library

14 lines (9 loc) 285 B
"use client"; import { useIsDark } from "./useIsDark"; import { getColors } from "./fr/colors"; import type { ColorTheme } from "./fr/colors"; export type { ColorTheme }; export function useColors(): ColorTheme { const { isDark } = useIsDark(); return getColors(isDark); }