From 6b4584e91bd4f4aee0c56e48a7aec7015c7c418b Mon Sep 17 00:00:00 2001 From: Kingkor Roy Tirtho Date: Wed, 28 Jun 2023 16:50:05 +0600 Subject: [PATCH] fix: lyrics page blur in player and cut off text when line too big --- lib/pages/lyrics/lyrics.dart | 20 ++++++++++---------- lib/pages/lyrics/synced_lyrics.dart | 5 ++--- 2 files changed, 12 insertions(+), 13 deletions(-) diff --git a/lib/pages/lyrics/lyrics.dart b/lib/pages/lyrics/lyrics.dart index 0e62f3b7..c97649d7 100644 --- a/lib/pages/lyrics/lyrics.dart +++ b/lib/pages/lyrics/lyrics.dart @@ -64,17 +64,17 @@ class LyricsPage extends HookConsumerWidget { return DefaultTabController( length: 2, child: SafeArea( - child: Container( - clipBehavior: Clip.hardEdge, - decoration: BoxDecoration( - color: Theme.of(context).colorScheme.background.withOpacity(.4), - borderRadius: const BorderRadius.only( - topLeft: Radius.circular(10), - topRight: Radius.circular(10), + child: BackdropFilter( + filter: ImageFilter.blur(sigmaX: 15, sigmaY: 15), + child: Container( + clipBehavior: Clip.hardEdge, + decoration: BoxDecoration( + color: Theme.of(context).colorScheme.background.withOpacity(.4), + borderRadius: const BorderRadius.only( + topLeft: Radius.circular(10), + topRight: Radius.circular(10), + ), ), - ), - child: BackdropFilter( - filter: ImageFilter.blur(sigmaX: 15, sigmaY: 15), child: Column( children: [ const SizedBox(height: 5), diff --git a/lib/pages/lyrics/synced_lyrics.dart b/lib/pages/lyrics/synced_lyrics.dart index eb49270f..4992ad75 100644 --- a/lib/pages/lyrics/synced_lyrics.dart +++ b/lib/pages/lyrics/synced_lyrics.dart @@ -134,14 +134,13 @@ class SyncedLyrics extends HookConsumerWidget { ? Colors.white : palette.bodyTextColor, fontWeight: isActive - ? FontWeight.bold + ? FontWeight.w500 : FontWeight.normal, - fontSize: (isActive ? 30 : 26) * + fontSize: (isActive ? 28 : 26) * (textZoomLevel.value / 100), ), child: Text( lyricSlice.text, - maxLines: 2, textAlign: TextAlign.center, ), ),