fix(player): playback element placement

This commit is contained in:
Kingkor Roy Tirtho 2023-04-10 21:14:47 +06:00
parent cb916d4861
commit 5e47faa606

View File

@ -93,6 +93,7 @@ class PlayerView extends HookConsumerWidget {
(palette.darkMutedColor ?? palette.lightMutedColor)?.color ?? (palette.darkMutedColor ?? palette.lightMutedColor)?.color ??
theme.colorScheme.secondaryContainer, theme.colorScheme.secondaryContainer,
], ],
child: SingleChildScrollView(
child: Container( child: Container(
alignment: Alignment.center, alignment: Alignment.center,
width: double.infinity, width: double.infinity,
@ -103,9 +104,11 @@ class PlayerView extends HookConsumerWidget {
padding: const EdgeInsets.all(8.0), padding: const EdgeInsets.all(8.0),
child: Column( child: Column(
children: [ children: [
Container( Padding(
constraints: padding: const EdgeInsets.all(8.0),
const BoxConstraints(maxHeight: 300, maxWidth: 300), child: Container(
constraints: const BoxConstraints(
maxHeight: 300, maxWidth: 300),
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(20), borderRadius: BorderRadius.circular(20),
boxShadow: const [ boxShadow: const [
@ -126,7 +129,8 @@ class PlayerView extends HookConsumerWidget {
), ),
), ),
), ),
const SizedBox(height: 10), ),
const SizedBox(height: 60),
Container( Container(
padding: const EdgeInsets.symmetric(horizontal: 16), padding: const EdgeInsets.symmetric(horizontal: 16),
alignment: Alignment.centerLeft, alignment: Alignment.centerLeft,
@ -136,9 +140,10 @@ class PlayerView extends HookConsumerWidget {
AutoSizeText( AutoSizeText(
currentTrack?.name ?? "Not playing", currentTrack?.name ?? "Not playing",
style: TextStyle( style: TextStyle(
fontSize: 20,
color: titleTextColor, color: titleTextColor,
fontSize: 22,
), ),
maxFontSize: 22,
maxLines: 1, maxLines: 1,
textAlign: TextAlign.start, textAlign: TextAlign.start,
), ),
@ -155,7 +160,8 @@ class PlayerView extends HookConsumerWidget {
else else
TypeConversionUtils.artists_X_ClickableArtists( TypeConversionUtils.artists_X_ClickableArtists(
currentTrack?.artists ?? [], currentTrack?.artists ?? [],
textStyle: theme.textTheme.bodyMedium!.copyWith( textStyle:
theme.textTheme.bodyMedium!.copyWith(
fontWeight: FontWeight.bold, fontWeight: FontWeight.bold,
color: bodyTextColor, color: bodyTextColor,
), ),
@ -167,9 +173,9 @@ class PlayerView extends HookConsumerWidget {
], ],
), ),
), ),
const SizedBox(height: 40), const SizedBox(height: 10),
PlayerControls(palette: palette), PlayerControls(palette: palette),
const Spacer(), const SizedBox(height: 25),
PlayerActions( PlayerActions(
mainAxisAlignment: MainAxisAlignment.spaceEvenly, mainAxisAlignment: MainAxisAlignment.spaceEvenly,
floatingQueue: false, floatingQueue: false,
@ -204,6 +210,7 @@ class PlayerView extends HookConsumerWidget {
) )
], ],
), ),
const SizedBox(height: 25)
], ],
), ),
), ),
@ -212,6 +219,7 @@ class PlayerView extends HookConsumerWidget {
), ),
), ),
), ),
),
); );
} }
} }