fix(ui): 修复多个UI样式问题

1. 修复 Light Mode 卡片背景色(surfaceCard: #FFFFFF)
2. 修复首页充值按钮颜色(使用主色实心背景+白色文字)
3. 修复'更多'和'资产详情'文字颜色(使用 text-muted)
4. 修复邀请码卡片背景色(使用琥珀色渐变)
5. 修复'复制邀请码'按钮文字颜色(使用 onPrimary)
This commit is contained in:
2026-04-06 03:40:45 +08:00
parent 8b512de7a6
commit fabce57657
6 changed files with 1871 additions and 1856 deletions

View File

@@ -37,6 +37,6 @@ _flutter.buildConfig = {"engineRevision":"e4b8dca3f1b4ede4c30371002441c88c12187e
_flutter.loader.load({
serviceWorkerSettings: {
serviceWorkerVersion: "759579798" /* Flutter's service worker is deprecated and will be removed in a future Flutter release. */
serviceWorkerVersion: "3968745925" /* Flutter's service worker is deprecated and will be removed in a future Flutter release. */
}
});

File diff suppressed because one or more lines are too long

View File

@@ -92,8 +92,8 @@ class AppThemeColors extends ThemeExtension<AppThemeColors> {
/// 浅色主题工厂
factory AppThemeColors.light() => AppThemeColors(
surfaceCard: AppColorScheme.lightSurfaceContainerHigh,
surfaceCardHigh: AppColorScheme.lightSurfaceContainerHigh,
surfaceCard: AppColorScheme.lightSurfaceLowest,
surfaceCardHigh: AppColorScheme.lightSurfaceContainer,
onSurfaceMuted: AppColorScheme.lightOnSurfaceMuted,
up: AppColorScheme.lightTertiary,
upBackground: AppColorScheme.lightTertiary.withValues(alpha: 0.15),

View File

@@ -544,19 +544,18 @@ class _AssetCardState extends State<_AssetCard> {
vertical: AppSpacing.xs + 2,
),
decoration: BoxDecoration(
color: context.colors.primary.withValues(alpha: 0.1),
color: context.colors.primary,
borderRadius: BorderRadius.circular(AppRadius.full),
border: Border.all(color: context.colors.primary.withValues(alpha: 0.2)),
),
child: Row(
mainAxisSize: MainAxisSize.min,
children: [
Icon(Icons.add, size: 14, color: context.colors.primary),
Icon(Icons.add, size: 14, color: context.colors.onPrimary),
SizedBox(width: AppSpacing.xs),
Text(
'充值',
style: AppTextStyles.labelLarge(context).copyWith(
color: context.colors.primary,
color: context.colors.onPrimary,
),
),
],
@@ -957,7 +956,7 @@ class _HoldingsSection extends StatelessWidget {
TextButton(
onPressed: () {},
style: TextButton.styleFrom(
foregroundColor: context.colors.primary,
foregroundColor: context.appColors.onSurfaceMuted,
padding: const EdgeInsets.symmetric(horizontal: AppSpacing.sm),
),
child: Row(
@@ -968,7 +967,7 @@ class _HoldingsSection extends StatelessWidget {
)),
const SizedBox(width: AppSpacing.xs),
Icon(LucideIcons.chevronRight,
size: 16, color: context.colors.primary),
size: 16, color: context.appColors.onSurfaceMuted),
],
),
),

View File

@@ -24,7 +24,9 @@ class HotCoinsSection extends StatelessWidget {
),
Text(
'更多',
style: AppTextStyles.bodyMedium(context),
style: AppTextStyles.bodyMedium(context).copyWith(
color: context.appColors.onSurfaceMuted,
),
),
],
),

View File

@@ -61,19 +61,30 @@ class _WelfareCenterPageState extends State<WelfareCenterPage> {
/// 金色渐变卡片容器
BoxDecoration _goldGradientDecoration() {
final goldAccent = context.appColors.accentPrimary;
final isDark = context.isDark;
// Light Mode: 琥珀色渐变(从 amber 15% 到深灰 5%
// Dark Mode: 金色渐变
final gradientColors = isDark
? [
context.appColors.accentPrimary.withValues(alpha: 0.15),
context.appColors.surfaceCard,
]
: [
const Color(0xFFF59E0B).withValues(alpha: 0.15), // amber-500 with 15% opacity
const Color(0xFF1F2937).withValues(alpha: 0.05), // gray-800 with 5% opacity
];
return BoxDecoration(
borderRadius: BorderRadius.circular(AppRadius.xl),
gradient: LinearGradient(
begin: Alignment.topCenter,
end: Alignment.bottomCenter,
colors: [
goldAccent.withValues(alpha: 0.15),
context.appColors.surfaceCard,
],
colors: gradientColors,
),
border: Border.all(
color: goldAccent.withValues(alpha: 0.3),
color: isDark
? context.appColors.accentPrimary.withValues(alpha: 0.3)
: const Color(0xFFF59E0B).withValues(alpha: 0.3),
width: 1,
),
);
@@ -230,7 +241,7 @@ class _WelfareCenterPageState extends State<WelfareCenterPage> {
},
style: ElevatedButton.styleFrom(
backgroundColor: goldAccent,
foregroundColor: context.colors.onSurface,
foregroundColor: context.colors.onPrimary,
elevation: 0,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(AppRadius.lg),
@@ -239,7 +250,7 @@ class _WelfareCenterPageState extends State<WelfareCenterPage> {
),
child: Text(
'复制邀请码',
style: AppTextStyles.headlineMedium(context).copyWith(color: context.colors.onSurface),
style: AppTextStyles.headlineMedium(context).copyWith(color: context.colors.onPrimary),
),
),
),