feat: 로그인 화면 및 공통 속성 생성

This commit is contained in:
2025-12-31 18:40:46 +09:00
parent 822cd55c93
commit 7400363466
17 changed files with 689 additions and 17 deletions

View File

@@ -0,0 +1,27 @@
import React from "react";
import { Text, type TextProps, type TextStyle } from "react-native";
import { Theme } from "../../theme/theme";
type Variant = "logo" | "title" | "body" | "muted" | "error";
type Props = TextProps & {
variant?: Variant;
style?: TextStyle | TextStyle[];
};
export default function AppText({ variant = "body", style, ...props }: Props) {
const base: TextStyle = {
color: Theme.Colors.text,
fontSize: Theme.FontSize.md,
};
const variants: Record<Variant, TextStyle> = {
logo: { fontSize: Theme.FontSize.xxl, fontWeight: Theme.FontWeight.bold },
title: { fontSize: Theme.FontSize.xl, fontWeight: Theme.FontWeight.bold },
body: { fontSize: Theme.FontSize.md },
muted: { color: Theme.Colors.mutedText, fontSize: Theme.FontSize.sm },
error: { color: Theme.Colors.danger, fontSize: Theme.FontSize.sm },
};
return <Text {...props} style={[base, variants[variant], style]} />;
}