import React from "react"; import { View, Text, TextInput, StyleSheet, TextInputProps, } from "react-native"; import { useTheme } from "../contexts/ThemeContext"; interface InputProps extends TextInputProps { label: string; error?: string; } export function Input({ label, error, style, ...props }: InputProps) { const { colors, typography } = useTheme(); return ( {label} {error && ( {error} )} ); } const styles = StyleSheet.create({ container: { marginBottom: 16, }, label: { marginBottom: 8, }, input: { borderWidth: 1, borderRadius: 12, paddingHorizontal: 16, paddingVertical: 14, fontSize: 16, }, errorText: { marginTop: 4, }, });