|
1 | 1 | import { extendTheme } from "native-base"; |
2 | 2 | import colors from "native-base/src/theme/base/colors"; |
| 3 | + |
| 4 | +export const getNativeBaseTheme = (colorMode) => { |
| 5 | + return extendTheme({ |
| 6 | + colors: { |
| 7 | + backgroundLight: colors.coolGray[100], |
| 8 | + backgroundDark: colors.blueGray[900], |
| 9 | + |
| 10 | + primaryTextDark: colors.cyan[200], |
| 11 | + primaryTextLight: colors.cyan[700], |
| 12 | + |
| 13 | + borderColorDark: colors.coolGray[800], |
| 14 | + borderColorLight: "#dfe3e6", |
| 15 | + |
| 16 | + // -------------------------------------------------- TOC ------------------------------------------- |
| 17 | + |
| 18 | + tocActiveTextLightColor: colors.coolGray[900], |
| 19 | + tocActiveTextDarkColor: colors.coolGray[50], |
| 20 | + |
| 21 | + tocTextLightColor: colors.coolGray[400], |
| 22 | + tocTextDarkColor: colors.coolGray[500], |
| 23 | + |
| 24 | + tocLeftDarkBorder: colors.coolGray[700], |
| 25 | + tocLeftLightBorder: colors.coolGray[300], |
| 26 | + |
| 27 | + tocLeftDarkBorderBall: colors.coolGray[800], |
| 28 | + tocLeftLightBorderBall: colors.coolGray[300], |
| 29 | + |
| 30 | + tocLeftDarkBorderActiveBall: colors.coolGray[400], |
| 31 | + tocLeftLightBorderActiveBall: colors.coolGray[600], |
| 32 | + |
| 33 | + // -------------------------------------------------- SideBar ------------------------------------------- |
| 34 | + |
| 35 | + sidebarBackgroundLight: colors.coolGray[100], |
| 36 | + sidebarBackgroundDark: colors.blueGray[900], |
| 37 | + sidebarItemHeadingTextDark: colors.coolGray[50], |
| 38 | + sidebarItemHeadingTextLight: colors.blueGray[900], |
| 39 | + sidebarItemTextDark: colors.coolGray[200], |
| 40 | + sidebarItemTextLight: "#11181c", |
| 41 | + |
| 42 | + activeSidebarItemBackgroundLight: colors.cyan[200], |
| 43 | + activeSidebarItemBackgroundDark: colors.cyan[700], |
| 44 | + activeSidebarItemHoverBackgroundLight: colors.cyan[200], |
| 45 | + activeSidebarItemHoverBackgroundDark: colors.cyan[600], |
| 46 | + |
| 47 | + inactiveSidebarItemHoverBackgroundLight: colors.blueGray[200], |
| 48 | + inactiveSidebarItemHoverBackgroundDark: colors.blueGray[800], |
| 49 | + |
| 50 | + // -------------------------------------------------- Link ------------------------------------------- |
| 51 | + |
| 52 | + inactiveLinkTextColorLight: "#687076", |
| 53 | + inactiveLinkTextColorDark: "#9ba1a6", |
| 54 | + inactiveHoverBorderBottomLinkColorDark: "#26292b", |
| 55 | + inactiveHoverBorderBottomLinkColorLight: "#eceef0", |
| 56 | + |
| 57 | + activeLinkTextColorLight: "#11181c", |
| 58 | + activeLinkTextColorDark: "#ecedee", |
| 59 | + activeBorderBottomLinkColorLight: "#eceef0", |
| 60 | + activeBorderBottomLinkColorDark: "#eceef0", |
| 61 | + activeHoverBorderBottomLinkColorDark: "#26292b", |
| 62 | + activeHoverBorderBottomLinkColorLight: "#eceef0", |
| 63 | + |
| 64 | + // -------------------------------------------------- Page Navs ------------------------------------------- |
| 65 | + |
| 66 | + pageNavigationHeadingLight: "#687076", |
| 67 | + pageNavigationHeadingDark: "#9ba1a6", |
| 68 | + pageNavigationMainTitleLight: "#006adc", |
| 69 | + pageNavigationMainTitleDark: "#52a9ff", |
| 70 | + |
| 71 | + // -------------------------------------------------- Tabs ------------------------------------------- |
| 72 | + |
| 73 | + SelectedTabTextColor: "#52a9ff", |
| 74 | + SelectedTabBorderColor: "#52a9ff", |
| 75 | + |
| 76 | + // -------------------------------------------------- CodeBlock ------------------------------------------- |
| 77 | + |
| 78 | + codeBlockBackgroundColor: "#171E2E", |
| 79 | + |
| 80 | + // -------------------------------------------------- Admonitions ------------------------------------------- |
| 81 | + tipBackgroundColorDark: colors.coolGray[300], |
| 82 | + tipBackgroundColorLight: colors.coolGray[900], |
| 83 | + }, |
| 84 | + config: { |
| 85 | + initialColorMode: colorMode, |
| 86 | + }, |
| 87 | + }); |
| 88 | +}; |
| 89 | + |
3 | 90 | export const theme = extendTheme({ |
4 | 91 | colors: { |
5 | 92 | backgroundLight: colors.coolGray[100], |
|
0 commit comments