This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import * as React from "react"; | |
import { ColorValue } from "react-native"; | |
import colors from "./colors"; | |
export interface Theme { | |
primary: ColorValue; | |
secondary: ColorValue; | |
// The color for the main background of your interface. | |
background: ColorValue; | |
} | |
export const defaultTheme: Theme = { | |
primary: colors.brand.blue, | |
secondary: colors.blue.secondary1, | |
background: colors.mono.white, | |
}; | |
export const ThemeContext = React.createContext(defaultTheme); | |
export function useTheme() { | |
const theme = React.useContext(ThemeContext); | |
return theme; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment