关怀模式

This commit is contained in:
Developer
2026-04-02 22:30:49 +08:00
parent 09fee0694c
commit 7872f2e78a
70 changed files with 4884 additions and 2752 deletions

View File

@@ -158,7 +158,7 @@ class _VotePageState extends State<VotePage> {
),
backgroundColor: isDark
? const Color(0xFF2A2A2A)
: AppConstants.primaryColor,
: _themeController.currentThemeColor,
elevation: 0,
actions: [
if (_isLoggedIn)
@@ -216,7 +216,7 @@ class _VotePageState extends State<VotePage> {
onPressed: _loadVoteList,
style: ElevatedButton.styleFrom(
backgroundColor:
AppConstants.primaryColor,
_themeController.currentThemeColor,
),
child: const Text('刷新'),
),
@@ -321,14 +321,14 @@ class _VotePageState extends State<VotePage> {
Container(
padding: const EdgeInsets.all(8),
decoration: BoxDecoration(
color: AppConstants.primaryColor.withValues(alpha: 0.1),
color: _themeController.currentThemeColor.withValues(alpha: 0.1),
borderRadius: BorderRadius.circular(8),
),
child: Icon(
vote.isSingleChoice
? Icons.radio_button_checked
: Icons.check_box,
color: AppConstants.primaryColor,
color: _themeController.currentThemeColor,
size: 20,
),
),
@@ -805,7 +805,7 @@ class _VoteDetailPageState extends State<VoteDetailPage> {
),
backgroundColor: isDark
? const Color(0xFF2A2A2A)
: AppConstants.primaryColor,
: _themeController.currentThemeColor,
elevation: 0,
),
body: _isLoading
@@ -821,10 +821,10 @@ class _VoteDetailPageState extends State<VoteDetailPage> {
decoration: BoxDecoration(
gradient: LinearGradient(
colors: [
AppConstants.primaryColor.withValues(
_themeController.currentThemeColor.withValues(
alpha: isDark ? 0.3 : 0.1,
),
AppConstants.primaryColor.withValues(
_themeController.currentThemeColor.withValues(
alpha: isDark ? 0.15 : 0.05,
),
],
@@ -841,7 +841,7 @@ class _VoteDetailPageState extends State<VoteDetailPage> {
Container(
padding: const EdgeInsets.all(10),
decoration: BoxDecoration(
color: AppConstants.primaryColor.withValues(
color: _themeController.currentThemeColor.withValues(
alpha: 0.15,
),
borderRadius: BorderRadius.circular(10),
@@ -850,7 +850,7 @@ class _VoteDetailPageState extends State<VoteDetailPage> {
widget.vote.isSingleChoice
? Icons.radio_button_checked
: Icons.check_box,
color: AppConstants.primaryColor,
color: _themeController.currentThemeColor,
size: 24,
),
),
@@ -1134,13 +1134,13 @@ class _VoteDetailPageState extends State<VoteDetailPage> {
decoration: BoxDecoration(
border: Border.all(
color: isSelected
? AppConstants.primaryColor
? _themeController.currentThemeColor
: (isDark ? Colors.grey[600]! : Colors.grey[300]!),
width: 2,
),
borderRadius: BorderRadius.circular(12),
color: isSelected
? AppConstants.primaryColor.withValues(alpha: 0.05)
? _themeController.currentThemeColor.withValues(alpha: 0.05)
: (isDark ? const Color(0xFF2A2A2A) : Colors.white),
),
child: InkWell(
@@ -1159,7 +1159,7 @@ class _VoteDetailPageState extends State<VoteDetailPage> {
? Icons.check_box
: Icons.check_box_outline_blank),
color: isSelected
? AppConstants.primaryColor
? _themeController.currentThemeColor
: (isDark ? Colors.grey[400] : Colors.grey),
),
const SizedBox(width: 12),
@@ -1175,7 +1175,7 @@ class _VoteDetailPageState extends State<VoteDetailPage> {
? FontWeight.bold
: FontWeight.normal,
color: isSelected
? AppConstants.primaryColor
? _themeController.currentThemeColor
: (isDark ? Colors.white : Colors.black),
),
),
@@ -1207,7 +1207,7 @@ class _VoteDetailPageState extends State<VoteDetailPage> {
child: ElevatedButton(
onPressed: _isSubmitting ? null : _submitVote,
style: ElevatedButton.styleFrom(
backgroundColor: AppConstants.primaryColor,
backgroundColor: _themeController.currentThemeColor,
padding: const EdgeInsets.symmetric(vertical: 14),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(8),
@@ -1309,7 +1309,7 @@ class _VoteDetailPageState extends State<VoteDetailPage> {
icon: Icons.poll,
label: '总票数',
value: '${_voteResult!.totalVotes}',
color: AppConstants.primaryColor,
color: _themeController.currentThemeColor,
isDark: isDark,
),
Container(
@@ -1446,7 +1446,7 @@ class _VoteDetailPageState extends State<VoteDetailPage> {
decoration: BoxDecoration(
color: isVoted
? AppConstants.successColor.withValues(alpha: 0.1)
: AppConstants.primaryColor.withValues(alpha: 0.1),
: _themeController.currentThemeColor.withValues(alpha: 0.1),
borderRadius: BorderRadius.circular(12),
),
child: Text(
@@ -1454,7 +1454,7 @@ class _VoteDetailPageState extends State<VoteDetailPage> {
style: TextStyle(
color: isVoted
? AppConstants.successColor
: AppConstants.primaryColor,
: _themeController.currentThemeColor,
fontSize: 14,
fontWeight: FontWeight.bold,
),
@@ -1476,7 +1476,7 @@ class _VoteDetailPageState extends State<VoteDetailPage> {
valueColor: AlwaysStoppedAnimation<Color>(
isVoted
? AppConstants.successColor
: AppConstants.primaryColor,
: _themeController.currentThemeColor,
),
minHeight: 8,
),