import Constants from 'expo-constants'; import { StyleSheet, Text, View } from 'react-native'; import { useTranslation } from 'react-i18next'; export default function SettingsScreen() { const { t } = useTranslation(); const version = Constants.expoConfig?.version ?? // 兜底:部分环境下 expoConfig 可能为空 'unknown'; return ( {t('settings.version')} {version} {t('settings.widgetTitle')} {t('settings.widgetDesc')} ); } const styles = StyleSheet.create({ container: { flex: 1, padding: 16, gap: 16 }, section: { borderRadius: 14, padding: 16, backgroundColor: '#FFFFFF', borderWidth: StyleSheet.hairlineWidth, borderColor: '#E5E7EB', flexDirection: 'row', alignItems: 'center', justifyContent: 'space-between', }, label: { color: '#374151', fontSize: 16 }, value: { color: '#111827', fontSize: 16, fontWeight: '600' }, card: { borderRadius: 16, padding: 16, backgroundColor: '#111827', }, cardTitle: { color: 'white', fontSize: 16, fontWeight: '700', marginBottom: 8 }, cardText: { color: '#E5E7EB', fontSize: 14, lineHeight: 20 }, });