From 856d699fd782570366a01690422b6ba2b404f643 Mon Sep 17 00:00:00 2001 From: guozhigq Date: Sat, 14 Oct 2023 11:48:50 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=8E=86=E5=8F=B2=E8=AE=B0=E5=BD=95?= =?UTF-8?q?=E5=86=85=E5=AE=B9=E6=BA=A2=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/pages/history/widgets/item.dart | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/lib/pages/history/widgets/item.dart b/lib/pages/history/widgets/item.dart index f531a276..b80affc8 100644 --- a/lib/pages/history/widgets/item.dart +++ b/lib/pages/history/widgets/item.dart @@ -297,7 +297,8 @@ class VideoContent extends StatelessWidget { maxLines: videoItem.videos > 1 ? 1 : 2, overflow: TextOverflow.ellipsis, ), - if (videoItem.showTitle != null) + if (videoItem.showTitle != null) ...[ + const SizedBox(height: 2), Text( videoItem.showTitle, textAlign: TextAlign.start, @@ -305,21 +306,24 @@ class VideoContent extends StatelessWidget { fontSize: Theme.of(context).textTheme.labelMedium!.fontSize, fontWeight: FontWeight.w400, color: Theme.of(context).colorScheme.outline), - maxLines: 2, + maxLines: 1, overflow: TextOverflow.ellipsis, ), + ], const Spacer(), - Row( - children: [ - Text( - videoItem.authorName, - style: TextStyle( - fontSize: Theme.of(context).textTheme.labelMedium!.fontSize, - color: Theme.of(context).colorScheme.outline, + if (videoItem.authorName != '') + Row( + children: [ + Text( + videoItem.authorName, + style: TextStyle( + fontSize: + Theme.of(context).textTheme.labelMedium!.fontSize, + color: Theme.of(context).colorScheme.outline, + ), ), - ), - ], - ), + ], + ), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [