fix: 修复推荐码文字颜色并统一恢复账号页面为龙虎榜风格
向导页修复: - 推荐码输入框文字改为黑色,确保可见性 恢复账号页面重构: - 背景改为与龙虎榜一致的渐变色(浅米色到浅橙色) - 所有文字颜色改为棕色系,与背景协调 - 边框颜色改为金棕色(#D4A574) - 登录按钮改为深棕色(#8B5A2B) - 移除 AppBar,使用自定义顶部导航栏 - 保持 100% Flutter 兼容性和最佳实践 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
6bbd4a6c78
commit
9e26b2750f
|
|
@ -610,7 +610,7 @@ class _WelcomePageContentState extends ConsumerState<_WelcomePageContent> {
|
|||
),
|
||||
style: TextStyle(
|
||||
fontSize: 17.sp,
|
||||
color: const Color(0xFFFFD700),
|
||||
color: Colors.black,
|
||||
fontWeight: FontWeight.w600,
|
||||
letterSpacing: 0.5,
|
||||
),
|
||||
|
|
|
|||
|
|
@ -128,30 +128,29 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
backgroundColor: Colors.white,
|
||||
appBar: AppBar(
|
||||
backgroundColor: Colors.white,
|
||||
elevation: 0,
|
||||
leading: IconButton(
|
||||
icon: const Icon(Icons.arrow_back_ios, color: Color(0xFF333333)),
|
||||
onPressed: () => context.pop(),
|
||||
),
|
||||
title: Text(
|
||||
'恢复账号',
|
||||
style: TextStyle(
|
||||
fontSize: 18.sp,
|
||||
fontWeight: FontWeight.w600,
|
||||
color: const Color(0xFF333333),
|
||||
body: Container(
|
||||
decoration: const BoxDecoration(
|
||||
gradient: LinearGradient(
|
||||
begin: Alignment.topCenter,
|
||||
end: Alignment.bottomCenter,
|
||||
colors: [
|
||||
Color(0xFFFFF5E6), // 浅米色
|
||||
Color(0xFFEAE0C8), // 浅橙色
|
||||
],
|
||||
),
|
||||
),
|
||||
centerTitle: true,
|
||||
),
|
||||
body: GestureDetector(
|
||||
onTap: () => FocusScope.of(context).unfocus(),
|
||||
child: SafeArea(
|
||||
child: SingleChildScrollView(
|
||||
padding: EdgeInsets.symmetric(horizontal: 24.w),
|
||||
child: Column(
|
||||
child: Column(
|
||||
children: [
|
||||
// 顶部导航栏
|
||||
_buildAppBar(),
|
||||
// 内容区域
|
||||
Expanded(
|
||||
child: GestureDetector(
|
||||
onTap: () => FocusScope.of(context).unfocus(),
|
||||
child: SingleChildScrollView(
|
||||
padding: EdgeInsets.symmetric(horizontal: 24.w),
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
SizedBox(height: 32.h),
|
||||
|
|
@ -161,7 +160,7 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
style: TextStyle(
|
||||
fontSize: 24.sp,
|
||||
fontWeight: FontWeight.w700,
|
||||
color: const Color(0xFF333333),
|
||||
color: const Color(0xFF5D4037),
|
||||
),
|
||||
),
|
||||
SizedBox(height: 8.h),
|
||||
|
|
@ -169,7 +168,7 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
'输入您的手机号和密码',
|
||||
style: TextStyle(
|
||||
fontSize: 14.sp,
|
||||
color: const Color(0xFF999999),
|
||||
color: const Color(0xFF8B6F47),
|
||||
),
|
||||
),
|
||||
SizedBox(height: 32.h),
|
||||
|
|
@ -192,11 +191,43 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
SizedBox(height: 24.h),
|
||||
// 注册提示
|
||||
_buildRegisterHint(),
|
||||
SizedBox(height: 32.h),
|
||||
],
|
||||
SizedBox(height: 32.h),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
/// 构建顶部导航栏
|
||||
Widget _buildAppBar() {
|
||||
return Container(
|
||||
height: 56.h,
|
||||
padding: EdgeInsets.symmetric(horizontal: 8.w),
|
||||
child: Row(
|
||||
children: [
|
||||
IconButton(
|
||||
icon: const Icon(Icons.arrow_back_ios, color: Color(0xFF5D4037)),
|
||||
onPressed: () => context.pop(),
|
||||
),
|
||||
Expanded(
|
||||
child: Text(
|
||||
'恢复账号',
|
||||
style: TextStyle(
|
||||
fontSize: 18.sp,
|
||||
fontWeight: FontWeight.w600,
|
||||
color: const Color(0xFF5D4037),
|
||||
),
|
||||
textAlign: TextAlign.center,
|
||||
),
|
||||
),
|
||||
),
|
||||
SizedBox(width: 48.w), // 平衡左侧返回按钮的宽度
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
|
@ -210,7 +241,7 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
'手机号',
|
||||
style: TextStyle(
|
||||
fontSize: 14.sp,
|
||||
color: const Color(0xFF666666),
|
||||
color: const Color(0xFF5D4037),
|
||||
fontWeight: FontWeight.w600,
|
||||
),
|
||||
),
|
||||
|
|
@ -220,7 +251,7 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
decoration: BoxDecoration(
|
||||
border: Border(
|
||||
bottom: BorderSide(
|
||||
color: const Color(0xFFE0E0E0),
|
||||
color: const Color(0xFFD4A574),
|
||||
width: 1,
|
||||
),
|
||||
),
|
||||
|
|
@ -235,14 +266,14 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
],
|
||||
style: TextStyle(
|
||||
fontSize: 16.sp,
|
||||
color: const Color(0xFF333333),
|
||||
color: const Color(0xFF5D4037),
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
decoration: InputDecoration(
|
||||
hintText: '请输入手机号',
|
||||
hintStyle: TextStyle(
|
||||
fontSize: 16.sp,
|
||||
color: const Color(0xFFCCCCCC),
|
||||
color: const Color(0xFFB8956A),
|
||||
),
|
||||
border: InputBorder.none,
|
||||
isDense: false,
|
||||
|
|
@ -268,7 +299,7 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
'密码',
|
||||
style: TextStyle(
|
||||
fontSize: 14.sp,
|
||||
color: const Color(0xFF666666),
|
||||
color: const Color(0xFF5D4037),
|
||||
fontWeight: FontWeight.w600,
|
||||
),
|
||||
),
|
||||
|
|
@ -278,7 +309,7 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
decoration: BoxDecoration(
|
||||
border: Border(
|
||||
bottom: BorderSide(
|
||||
color: const Color(0xFFE0E0E0),
|
||||
color: const Color(0xFFD4A574),
|
||||
width: 1,
|
||||
),
|
||||
),
|
||||
|
|
@ -292,14 +323,14 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
obscureText: _obscurePassword,
|
||||
style: TextStyle(
|
||||
fontSize: 16.sp,
|
||||
color: const Color(0xFF333333),
|
||||
color: const Color(0xFF5D4037),
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
decoration: InputDecoration(
|
||||
hintText: '请输入密码',
|
||||
hintStyle: TextStyle(
|
||||
fontSize: 16.sp,
|
||||
color: const Color(0xFFCCCCCC),
|
||||
color: const Color(0xFFB8956A),
|
||||
),
|
||||
border: InputBorder.none,
|
||||
isDense: false,
|
||||
|
|
@ -322,7 +353,7 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
},
|
||||
child: Icon(
|
||||
_obscurePassword ? Icons.visibility_off : Icons.visibility,
|
||||
color: const Color(0xFF999999),
|
||||
color: const Color(0xFF8B6F47),
|
||||
size: 20.sp,
|
||||
),
|
||||
),
|
||||
|
|
@ -380,9 +411,9 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
onPressed: canLogin ? _login : null,
|
||||
style: ElevatedButton.styleFrom(
|
||||
backgroundColor: canLogin
|
||||
? const Color(0xFFD4A84B)
|
||||
: const Color(0xFFE0E0E0),
|
||||
disabledBackgroundColor: const Color(0xFFE0E0E0),
|
||||
? const Color(0xFF8B5A2B)
|
||||
: const Color(0xFFD4C4B0),
|
||||
disabledBackgroundColor: const Color(0xFFD4C4B0),
|
||||
shape: RoundedRectangleBorder(
|
||||
borderRadius: BorderRadius.circular(12.r),
|
||||
),
|
||||
|
|
@ -402,7 +433,7 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
style: TextStyle(
|
||||
fontSize: 16.sp,
|
||||
fontWeight: FontWeight.w700,
|
||||
color: canLogin ? Colors.white : const Color(0xFFCCCCCC),
|
||||
color: canLogin ? Colors.white : const Color(0xFFB8956A),
|
||||
),
|
||||
),
|
||||
),
|
||||
|
|
@ -415,7 +446,7 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
children: [
|
||||
Expanded(
|
||||
child: Divider(
|
||||
color: const Color(0xFFE0E0E0),
|
||||
color: const Color(0xFFD4A574),
|
||||
thickness: 1,
|
||||
),
|
||||
),
|
||||
|
|
@ -425,14 +456,14 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
'或',
|
||||
style: TextStyle(
|
||||
fontSize: 14.sp,
|
||||
color: const Color(0xFF999999),
|
||||
color: const Color(0xFF8B6F47),
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
),
|
||||
),
|
||||
Expanded(
|
||||
child: Divider(
|
||||
color: const Color(0xFFE0E0E0),
|
||||
color: const Color(0xFFD4A574),
|
||||
thickness: 1,
|
||||
),
|
||||
),
|
||||
|
|
@ -450,7 +481,7 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
'还没有账号?',
|
||||
style: TextStyle(
|
||||
fontSize: 14.sp,
|
||||
color: const Color(0xFF999999),
|
||||
color: const Color(0xFF8B6F47),
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
),
|
||||
|
|
@ -464,7 +495,7 @@ class _PhoneLoginPageState extends ConsumerState<PhoneLoginPage> {
|
|||
'立即注册',
|
||||
style: TextStyle(
|
||||
fontSize: 14.sp,
|
||||
color: const Color(0xFFD4A84B),
|
||||
color: const Color(0xFF8B5A2B),
|
||||
fontWeight: FontWeight.w700,
|
||||
),
|
||||
),
|
||||
|
|
|
|||
Loading…
Reference in New Issue