This commit is contained in:
Neil.X.Zhang
2025-06-27 16:16:14 +08:00
commit 3b79d06b7d
111 changed files with 20915 additions and 0 deletions

30
constants/Colors.ts Normal file
View File

@@ -0,0 +1,30 @@
/**
* Below are the colors that are used in the app. The colors are defined in the light and dark mode.
* There are many other ways to style your app. For example, [Nativewind](https://www.nativewind.dev/), [Tamagui](https://tamagui.dev/), [unistyles](https://reactnativeunistyles.vercel.app), etc.
*/
const tintColorLight = "#0a7ea4";
const tintColorDark = "#aaa";
export const Colors = {
light: {
text: "#11181C",
background: "#fff",
tint: tintColorLight,
icon: "#687076",
tabIconDefault: "#687076",
tabIconSelected: tintColorLight,
link: "#0a7ea4",
border: "#E5E5E5",
},
dark: {
text: "#ECEDEE",
background: "#151718",
tint: tintColorDark,
icon: "#9BA1A6",
tabIconDefault: "#9BA1A6",
tabIconSelected: tintColorDark,
link: "#0a7ea4",
border: "#333",
},
};

39
constants/TextStyles.ts Normal file
View File

@@ -0,0 +1,39 @@
/**
* Below are text styles used in the app, primarily in the ThemedText component.
*/
import {TextStyle} from 'react-native';
export const textStyles = function (
scale: number,
linkColor: string,
): {
[key: string]: TextStyle & {fontSize: number; lineHeight: number};
} {
return {
default: {
fontSize: 16 * scale,
lineHeight: 24 * scale,
},
defaultSemiBold: {
fontSize: 16 * scale,
lineHeight: 24 * scale,
fontWeight: '600',
},
title: {
fontSize: 32 * scale,
fontWeight: 'bold',
lineHeight: 32 * scale,
},
subtitle: {
fontSize: 20 * scale,
lineHeight: 20 * scale,
fontWeight: 'bold',
},
link: {
lineHeight: 30 * scale,
fontSize: 16 * scale,
color: linkColor,
},
};
};