chore: vendor client into main repo
This commit is contained in:
50
client/app/(app)/settings.tsx
Normal file
50
client/app/(app)/settings.tsx
Normal file
@@ -0,0 +1,50 @@
|
||||
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 (
|
||||
<View style={styles.container}>
|
||||
<View style={styles.section}>
|
||||
<Text style={styles.label}>{t('settings.version')}</Text>
|
||||
<Text style={styles.value}>{version}</Text>
|
||||
</View>
|
||||
|
||||
<View style={styles.card}>
|
||||
<Text style={styles.cardTitle}>{t('settings.widgetTitle')}</Text>
|
||||
<Text style={styles.cardText}>{t('settings.widgetDesc')}</Text>
|
||||
</View>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
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 },
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user