style(ui): 播放页内容下移 + 收藏移到标题右侧 + 底部改播放模式

按草图调整:
- 主播放页顶部留 16px,封面与指示器拉开距离
- 收藏心从底部控制行移到标题右侧(空心/实心红随收藏状态)
- 底部控制行第四位改为播放模式按钮(循环图标),队列保持在第五位
This commit is contained in:
2026-10-31 23:17:01 +08:00
parent 6351ef1395
commit 1c57d59d73
+37 -19
View File
@@ -307,7 +307,8 @@ class _PlayerPageState extends BaseState<PlayerPage> {
Widget _buildMainPage(AudioService service, Song song, bool isPlaying) {
return Padding(
padding: const EdgeInsets.symmetric(horizontal: 24),
// 顶部留 16:与 AppBar/指示器拉开距离,避免封面贴着顶部
padding: const EdgeInsets.fromLTRB(24, 16, 24, 0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
@@ -334,19 +335,38 @@ class _PlayerPageState extends BaseState<PlayerPage> {
),
const SizedBox(height: 28),
// ---- 标题 / 艺术家 ----
Text(
song.title,
style: const TextStyle(
fontSize: 24,
fontWeight: FontWeight.w600,
color: Colors.white,
height: 1.25,
),
maxLines: 2,
overflow: TextOverflow.ellipsis,
// ---- 标题 / 艺术家(收藏心在标题右侧)----
Row(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Expanded(
child: Text(
song.title,
style: const TextStyle(
fontSize: 24,
fontWeight: FontWeight.w600,
color: Colors.white,
height: 1.25,
),
maxLines: 2,
overflow: TextOverflow.ellipsis,
),
),
const SizedBox(width: 8),
IconButton(
onPressed: () => _toggleFavorite(song),
tooltip: '收藏',
icon: Icon(
_isFavorite ? Icons.favorite : Icons.favorite_border,
color: _isFavorite
? const Color(0xFFE05C5C)
: Colors.white54,
size: 26,
),
),
],
),
const SizedBox(height: 6),
const SizedBox(height: 2),
Text(
song.artist,
style: TextStyle(fontSize: 14, color: Colors.grey[400]),
@@ -641,15 +661,13 @@ class _PlayerPageState extends BaseState<PlayerPage> {
color: service.hasQueue ? Colors.white70 : Colors.grey[700],
),
IconButton(
onPressed: () => _toggleFavorite(song),
onPressed: service.togglePlayMode,
icon: Icon(
_isFavorite ? Icons.favorite : Icons.favorite_border,
color: _isFavorite
? const Color(0xFFE05C5C)
: Colors.white54,
service.playModeIcon,
color: const Color(0xFFB8D4D0),
size: 26,
),
tooltip: '收藏',
tooltip: '播放模式',
),
IconButton(
onPressed: _openPlaylist,