Skip to content

Commit

Permalink
fix(playbutton_card): title text overflow
Browse files Browse the repository at this point in the history
  • Loading branch information
KRTirtho committed Mar 7, 2023
1 parent b327ffb commit 39ee0a9
Showing 1 changed file with 34 additions and 21 deletions.
55 changes: 34 additions & 21 deletions lib/components/shared/playbutton_card.dart
Original file line number Diff line number Diff line change
Expand Up @@ -190,32 +190,45 @@ class PlaybuttonCard extends HookWidget {
);

final list = Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
// thumbnail of the playlist
image,
const SizedBox(width: 10),
Column(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisAlignment: MainAxisAlignment.center,
children: [
PlatformText(
title,
style: const TextStyle(fontWeight: FontWeight.bold),
),
const SizedBox(height: 5),
if (description != null)
PlatformText(
description!,
overflow: TextOverflow.fade,
style: PlatformTextTheme.of(context).caption,
Flexible(
child: Row(
children: [
image,
const SizedBox(width: 10),
Flexible(
child: RichText(
overflow: TextOverflow.ellipsis,
text: TextSpan(
children: [
TextSpan(
text: title,
style: PlatformTextTheme.of(context)
.body
?.copyWith(fontWeight: FontWeight.bold),
),
if (description != null)
TextSpan(
text: '\n$description',
style: PlatformTextTheme.of(context).caption,
),
],
),
),
),
],
),
),
Row(
children: [
addToQueueButton,
const SizedBox(width: 10),
playButton,
const SizedBox(width: 10),
],
),
const Spacer(),
addToQueueButton,
const SizedBox(width: 10),
playButton,
const SizedBox(width: 10),
],
);

Expand Down

0 comments on commit 39ee0a9

Please sign in to comment.