import { SectionCard } from '@/components/profile/SectionCard'; import { SettingItem } from '@/components/profile/SettingItem'; import { AppColors } from '@/constants/theme'; import { mockUserProfile, settingsSections } from '@/data/mockData'; import { Ionicons } from '@expo/vector-icons'; import React, { useState } from 'react'; import { Alert, ScrollView, StyleSheet, Text, View } from 'react-native'; import { SafeAreaView } from 'react-native-safe-area-context'; export default function ProfileScreen() { const [settings, setSettings] = useState({ largeFont: false, darkMode: false, reminder: true, }); const handleToggle = (key: keyof typeof settings) => (value: boolean) => { setSettings(prev => ({ ...prev, [key]: value })); }; const showToast = (message: string) => { Alert.alert('提示', message); }; return ( {/* Profile Header */} {mockUserProfile.nickname} {mockUserProfile.planLabel} {/* Payment Section */} {settingsSections.payment.items.map((item, index) => ( showToast('功能开发中...')} /> ))} {/* Privacy Section */} {/* {settingsSections.privacy.items.map((item, index) => ( showToast('数据导出中...')} /> ))} */} {/* Settings Section */} {/* showToast('功能开发中...')} /> */} {/* Help Section */} {settingsSections.help.items.map((item, index) => ( showToast('功能开发中...')} /> ))} {/* Version Info */} 版本 1.0.0 ); } const styles = StyleSheet.create({ container: { flex: 1, backgroundColor: AppColors.cream, }, content: { flex: 1, }, contentContainer: { padding: 20, paddingTop: 28, paddingBottom: 40, }, profileHeader: { alignItems: 'center', paddingVertical: 20, marginBottom: 4, }, avatar: { width: 72, height: 72, borderRadius: 36, backgroundColor: AppColors.lavender, alignItems: 'center', justifyContent: 'center', marginBottom: 12, }, profileName: { fontSize: 18, fontWeight: '600', color: AppColors.deepPurple, marginBottom: 4, }, planBadge: { flexDirection: 'row', alignItems: 'center', }, planDot: { width: 6, height: 6, borderRadius: 3, backgroundColor: AppColors.mediumPurple, marginRight: 4, }, planText: { fontSize: 13, color: AppColors.mediumPurple, }, version: { textAlign: 'center', fontSize: 12, color: AppColors.slatePurple, marginTop: 20, }, });