diff --git a/docs/plans/PROGRESS.md b/docs/plans/PROGRESS.md index 6f90aee..7147d33 100644 --- a/docs/plans/PROGRESS.md +++ b/docs/plans/PROGRESS.md @@ -1115,5 +1115,5 @@ $ flutter test - 四类卡片去底板/描边,封面 8 圆角、行距 10、封底标题间距 6;热剧/新剧/漫剧角标为右上角 16 高紧凑异形丝带。 - 标题下方恢复左对齐题材文字,使用 `|` 分隔、灰色小字,与封面状态角标保持独立。 - 首页搜索栏到一级、一级到二级、二级到网格间距为 8/8/10;非精选 tab 直接以 10 衔接网格。 -- 播放量回到封面右下角,使用 spark 图标与 12/w400 纯文字、`w` 格式,并加极淡底部渐变;四类列表共用。 +- 播放量贴封面右下角(底 2、右 6),火焰图标 11 + 12/w400 纯文字,间距 4,并保留极淡底部渐变。 - 全部短剧的地区、字幕、配音筛选 UI 已占位;以下接口待补:地区、字幕/配音筛选数据。 diff --git a/lib/core/theme/app_dimens.dart b/lib/core/theme/app_dimens.dart index cec1b67..d60bb05 100644 --- a/lib/core/theme/app_dimens.dart +++ b/lib/core/theme/app_dimens.dart @@ -88,8 +88,9 @@ abstract final class AppDimens { static const double cardViewsFont = 11; static const double cardViewsIcon = 11; static const double cardPlayCountFont = 12; - static const double cardPlayCountGap = 2; - static const double cardPlayCountBottom = 6; + static const double cardPlayCountGap = 4; + static const double cardPlayCountBottom = 2; + static const double cardPlayCountRight = 6; static const double cardPlayCountScrimHeight = 32; static const double cardGenreRibbonHeight = 16; static const double cardGenreRibbonLeftInset = 4; diff --git a/lib/core/widgets/cover_play_count.dart b/lib/core/widgets/cover_play_count.dart index 73205b1..622fb37 100644 --- a/lib/core/widgets/cover_play_count.dart +++ b/lib/core/widgets/cover_play_count.dart @@ -18,7 +18,7 @@ class CoverPlayCount extends StatelessWidget { crossAxisAlignment: CrossAxisAlignment.center, children: [ const Icon( - Icons.auto_awesome_rounded, + Icons.local_fire_department_rounded, color: AppColors.textPrimary, size: AppDimens.cardViewsIcon, ), diff --git a/lib/pages/following/following_grid_card.dart b/lib/pages/following/following_grid_card.dart index c5f43fd..c1a433a 100644 --- a/lib/pages/following/following_grid_card.dart +++ b/lib/pages/following/following_grid_card.dart @@ -87,7 +87,7 @@ class FollowingGridCard extends StatelessWidget { child: CoverBottomScrim(), ), Positioned( - right: 0, + right: AppDimens.cardPlayCountRight, bottom: AppDimens.cardPlayCountBottom, child: CoverPlayCount( key: Key('following-views-$dramaId'), diff --git a/lib/pages/home/widgets/home_feed_card.dart b/lib/pages/home/widgets/home_feed_card.dart index 6a4c58f..a5ad5bd 100644 --- a/lib/pages/home/widgets/home_feed_card.dart +++ b/lib/pages/home/widgets/home_feed_card.dart @@ -109,7 +109,7 @@ class HomeFeedCard extends StatelessWidget { child: CoverBottomScrim(), ), Positioned( - right: 0, + right: AppDimens.cardPlayCountRight, bottom: AppDimens.cardPlayCountBottom, child: CoverPlayCount( key: Key('home-feed-views-${drama.id}'), diff --git a/lib/pages/recommend/widgets/recommend_section_card.dart b/lib/pages/recommend/widgets/recommend_section_card.dart index c10894c..8a0d477 100644 --- a/lib/pages/recommend/widgets/recommend_section_card.dart +++ b/lib/pages/recommend/widgets/recommend_section_card.dart @@ -69,7 +69,7 @@ class RecommendSectionCard extends StatelessWidget { child: CoverBottomScrim(), ), Positioned( - right: 0, + right: AppDimens.cardPlayCountRight, bottom: AppDimens.cardPlayCountBottom, child: CoverPlayCount( key: Key('recommend-views-$sectionKey-${drama.id}'), diff --git a/test/following/following_page_test.dart b/test/following/following_page_test.dart index 1c0adc7..b178d7b 100644 --- a/test/following/following_page_test.dart +++ b/test/following/following_page_test.dart @@ -101,7 +101,7 @@ void main() { expect( find.descendant( of: find.byKey(const Key('following-views-the-signal-demo')), - matching: find.byIcon(Icons.auto_awesome_rounded), + matching: find.byIcon(Icons.local_fire_department_rounded), ), findsOneWidget, ); diff --git a/test/home/home_card_style_test.dart b/test/home/home_card_style_test.dart index 4721472..9dd5902 100644 --- a/test/home/home_card_style_test.dart +++ b/test/home/home_card_style_test.dart @@ -82,8 +82,8 @@ void main() { findsOneWidget, ); expect( - tester.getTopRight(views).dx, - closeTo(tester.getTopRight(cover).dx, 1), + tester.getTopRight(cover).dx - tester.getTopRight(views).dx, + AppDimens.cardPlayCountRight, ); expect( tester.getBottomLeft(cover).dy - tester.getBottomLeft(views).dy, @@ -96,7 +96,7 @@ void main() { expect( find.descendant( of: views, - matching: find.byIcon(Icons.auto_awesome_rounded), + matching: find.byIcon(Icons.local_fire_department_rounded), ), findsOneWidget, ); diff --git a/test/recommend/recommend_sections_test.dart b/test/recommend/recommend_sections_test.dart index 0aaa7e6..e2b372c 100644 --- a/test/recommend/recommend_sections_test.dart +++ b/test/recommend/recommend_sections_test.dart @@ -122,7 +122,7 @@ void main() { expect(views.style?.color, AppColors.textPrimary); final viewIcon = find.descendant( of: find.byKey(const Key('recommend-views-hits-the-signal-demo')), - matching: find.byIcon(Icons.auto_awesome_rounded), + matching: find.byIcon(Icons.local_fire_department_rounded), ); expect(viewIcon, findsOneWidget); final badge = find.byKey(