UNPKG

rn-phone-input-field

Version:

A React Native phone number input component built from scratch, featuring a text input for number entry, a custom dropdown for selecting country codes, and validation logic using regex or country-specific rules. It supports formatting, localization, and s

25 lines (23 loc) 714 B
import { StyleSheet } from 'react-native'; import Styles from './styles.d'; const styles: Styles = (isDark: boolean) => StyleSheet.create({ container: { flexDirection: 'row', alignItems: 'center', gap: 16, borderWidth: 1, borderColor: isDark ? '#DDDDDE' : '#323436', borderRadius: 10, paddingVertical: 8, paddingHorizontal: 22, flexShrink: 1, backgroundColor: isDark ? '#1B1D20' : '#FAFAFB', }, flexRow: { flexDirection: 'row', alignItems: 'center', gap: 8 }, gap10: { gap: 10 }, ft28: { fontSize: 28 }, ft16: { fontSize: 16, color: isDark ? '#FFFFFF' : '#000000' }, width75: { width: '75%' }, }); export default styles;