Clean up login page
This commit is contained in:
@@ -7,23 +7,29 @@ export type ThemedViewProps = ViewProps & {
|
||||
darkColor?: string;
|
||||
};
|
||||
export type ThemedTextProps = TextProps & {
|
||||
fontSize?: number;
|
||||
fontWeight?: 'normal' | 'semibold' | 'bold' | '100' | '200' | '300' | '400' | '500' | '600' | '700' | '800' | '900';
|
||||
lightColor?: string;
|
||||
darkColor?: string;
|
||||
type?: 'default' | 'title' | 'defaultSemiBold' | 'subtitle' | 'link';
|
||||
type?: 'custom' | 'default' | 'title' | 'defaultSemiBold' | 'subtitle' | 'link';
|
||||
};
|
||||
|
||||
const ThemedText = ({
|
||||
fontSize = 16,
|
||||
fontWeight = 'normal',
|
||||
style,
|
||||
lightColor,
|
||||
darkColor,
|
||||
type = 'default',
|
||||
type='default',
|
||||
...rest
|
||||
}: ThemedTextProps) => {
|
||||
const color = useThemeColor({ light: lightColor, dark: darkColor }, 'text');
|
||||
if (fontWeight === 'semibold') fontWeight = '600';
|
||||
return (
|
||||
<Text
|
||||
style={[
|
||||
{ color },
|
||||
type === 'custom' ? { fontSize, lineHeight: fontSize * 1.5, fontWeight } : undefined,
|
||||
type === 'default' ? styles.default : undefined,
|
||||
type === 'title' ? styles.title : undefined,
|
||||
type === 'defaultSemiBold' ? styles.defaultSemiBold : undefined,
|
||||
|
Reference in New Issue
Block a user