refactor(database): migrate to new modular database layer and unify data access
- Remove legacy database.ts, LocalDataSource.ts, and MessageRepository.ts - Create new src/database/ module with messageRepository, userCacheRepository, conversationRepository, and groupCacheRepository - Update all consumers to import from @/database instead of services/database - Add web platform blur handling for modal components to fix focus issues - Flatten SystemMessageItem and NotificationsScreen styles for consistent design - Add draggable slider in ChatSettingsScreen and dynamic font size support - Introduce 9 new chat color themes - Add profile screens for about, terms, and privacy policy with navigation routes - Add policy links to login and registration screens - Fix post share URL format from /posts/ to /post/
This commit is contained in:
@@ -62,7 +62,6 @@ const SETTINGS_GROUPS_BASE = [
|
||||
icon: 'bell-outline',
|
||||
items: [
|
||||
{ key: 'notification_settings', title: '通知设置', icon: 'bell-cog-outline', showArrow: true, subtitle: '推送、震动、提示音' },
|
||||
{ key: 'language', title: '语言设置', icon: 'translate', showArrow: true, subtitle: '简体中文' },
|
||||
{ key: 'data_storage', title: '数据与存储', icon: 'database-outline', showArrow: true },
|
||||
],
|
||||
},
|
||||
@@ -72,8 +71,6 @@ const SETTINGS_GROUPS_BASE = [
|
||||
items: [
|
||||
{ key: 'about', title: '关于我们', icon: 'information-outline', showArrow: true, subtitle: `版本 ${APP_VERSION}` },
|
||||
{ key: 'help', title: '帮助与反馈', icon: 'help-circle-outline', showArrow: true },
|
||||
{ key: 'terms', title: '用户协议', icon: 'file-document-outline', showArrow: true },
|
||||
{ key: 'privacy_policy', title: '隐私政策', icon: 'shield-outline', showArrow: true },
|
||||
],
|
||||
},
|
||||
];
|
||||
@@ -240,31 +237,18 @@ export const SettingsScreen: React.FC = () => {
|
||||
);
|
||||
break;
|
||||
}
|
||||
case 'language': {
|
||||
Alert.alert(
|
||||
'语言设置',
|
||||
'选择应用显示语言',
|
||||
[
|
||||
{ text: '取消', style: 'cancel' },
|
||||
{ text: '简体中文', onPress: () => {} },
|
||||
{ text: '繁體中文', onPress: () => {} },
|
||||
{ text: 'English', onPress: () => {} },
|
||||
]
|
||||
);
|
||||
break;
|
||||
}
|
||||
|
||||
case 'data_storage': {
|
||||
Alert.alert('数据与存储', '缓存清理功能即将上线!');
|
||||
break;
|
||||
}
|
||||
case 'terms': {
|
||||
Alert.alert('用户协议', '用户协议页面即将上线!');
|
||||
case 'about':
|
||||
router.push(hrefs.hrefProfileAbout());
|
||||
break;
|
||||
}
|
||||
case 'privacy_policy': {
|
||||
Alert.alert('隐私政策', '隐私政策页面即将上线!');
|
||||
case 'help':
|
||||
Alert.alert('帮助与反馈', '帮助中心即将上线!');
|
||||
break;
|
||||
}
|
||||
|
||||
case 'edit_profile':
|
||||
router.push(hrefs.hrefProfileEdit());
|
||||
break;
|
||||
@@ -372,7 +356,7 @@ export const SettingsScreen: React.FC = () => {
|
||||
萝卜社区 v{APP_VERSION}
|
||||
</Text>
|
||||
<Text variant="caption" color={colors.text.hint} style={styles.copyright}>
|
||||
© 2024 Carrot BBS. All rights reserved.
|
||||
© 2026 青春之旅电子信息科技(威海)有限公司
|
||||
</Text>
|
||||
</View>
|
||||
</>
|
||||
|
||||
Reference in New Issue
Block a user