## P0 - 简繁体中文混用(6个文件) - chart_page.dart: 6处简体→繁体(暂无数据、买入、卖出、加载失败等) - mine_page.dart: 确定 → 確定 - menu_group1.dart: 确定 → 確定 - deposit_page.dart: 单笔最低充值 → 單筆最低充值、网络 → 網絡 ## P1 - 图标库不一致(1个文件) - register_page.dart: Material Icons 统一为 Lucide Icons - Icons.chevron_left → LucideIcons.arrowLeft - Icons.check → LucideIcons.check - Icons.shield → LucideIcons.shieldCheck - Icons.lock → LucideIcons.lock - Icons.close → LucideIcons.x - Icons.camera_alt → LucideIcons.camera ## P2 - hintText 重复(2个文件) - register_page.dart: 推廣碼(選填) → 請輸入推廣碼(選填) - asset_dialogs.dart: 聯繫方式 → 方便客服與您聯繫 ## 检查结论 ✅ 所有图标与功能语义完全匹配 ✅ 所有简繁混用问题已修复 ✅ 所有图标库统一为 Lucide Icons
91 lines
2.5 KiB
Dart
91 lines
2.5 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:lucide_icons_flutter/lucide_icons.dart';
|
|
import '../kyc_page.dart';
|
|
import '../welfare_center_page.dart';
|
|
import 'menu_group_container.dart';
|
|
import 'menu_row.dart';
|
|
import 'menu_trailing_widgets.dart';
|
|
|
|
/// 菜单分组1 - 福利中心 / 实名认证 / 安全设置 / 消息通知
|
|
class MenuGroup1 extends StatelessWidget {
|
|
final int kycStatus;
|
|
final void Function(String) onShowComingSoon;
|
|
|
|
const MenuGroup1({
|
|
super.key,
|
|
required this.kycStatus,
|
|
required this.onShowComingSoon,
|
|
});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
final colorScheme = Theme.of(context).colorScheme;
|
|
|
|
return MenuGroupContainer(
|
|
child: Column(
|
|
children: [
|
|
MenuRow(
|
|
icon: LucideIcons.gift,
|
|
iconColor: colorScheme.secondary,
|
|
title: '福利中心',
|
|
onTap: () {
|
|
Navigator.push(
|
|
context,
|
|
MaterialPageRoute(builder: (_) => const WelfareCenterPage()),
|
|
);
|
|
},
|
|
),
|
|
const Divider(height: 1),
|
|
MenuRow(
|
|
icon: LucideIcons.shieldCheck,
|
|
iconColor: colorScheme.secondary,
|
|
title: '實名認證',
|
|
trailing: KycBadge(kycStatus: kycStatus),
|
|
onTap: () {
|
|
if (kycStatus == 2) {
|
|
_showKycStatusDialog(context);
|
|
} else {
|
|
Navigator.push(
|
|
context,
|
|
MaterialPageRoute(builder: (_) => const KycPage()),
|
|
);
|
|
}
|
|
},
|
|
),
|
|
const Divider(height: 1),
|
|
MenuRow(
|
|
icon: LucideIcons.lock,
|
|
iconColor: colorScheme.onSurfaceVariant,
|
|
title: '安全設置',
|
|
onTap: () => onShowComingSoon('安全設置'),
|
|
),
|
|
const Divider(height: 1),
|
|
MenuRow(
|
|
icon: LucideIcons.bell,
|
|
iconColor: colorScheme.onSurfaceVariant,
|
|
title: '消息通知',
|
|
trailing: const RedDotIndicator(),
|
|
onTap: () => onShowComingSoon('消息通知'),
|
|
),
|
|
],
|
|
),
|
|
);
|
|
}
|
|
}
|
|
|
|
void _showKycStatusDialog(BuildContext context) {
|
|
showDialog(
|
|
context: context,
|
|
builder: (ctx) => AlertDialog(
|
|
title: const Text('實名認證'),
|
|
content: const Text('您的實名認證已通過'),
|
|
actions: [
|
|
TextButton(
|
|
onPressed: () => Navigator.of(ctx).pop(),
|
|
child: const Text('確定'),
|
|
),
|
|
],
|
|
),
|
|
);
|
|
}
|