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