Skip to content

Commit

Permalink
fix index overflow, improve index scaling
Browse files Browse the repository at this point in the history
- fixes #960
  • Loading branch information
Chaphasilor committed Nov 22, 2024
1 parent 7af9869 commit 70d2834
Showing 1 changed file with 18 additions and 13 deletions.
31 changes: 18 additions & 13 deletions lib/components/AlbumScreen/track_list_tile.dart
Original file line number Diff line number Diff line change
Expand Up @@ -652,20 +652,25 @@ class TrackListItemTile extends StatelessWidget {
if (showIndex && actualIndex != null)
Padding(
padding: showCover
? const EdgeInsets.only(left: 2.0, right: 6.0)
? const EdgeInsets.only(left: 2.0, right: 8.0)
: const EdgeInsets.only(left: 6.0, right: 0.0),
child: SizedBox.fromSize(
size: const Size(22.0, defaultTileHeight),
child: Center(
child: Text(
actualIndex.toString(),
textAlign: TextAlign.end,
style: TextStyle(
color: Theme.of(context).textTheme.bodyMedium?.color,
fontSize: 16,
fontWeight: FontWeight.w500,
),
))),
child: Container(
constraints: const BoxConstraints(
minWidth: 22.0,
),
child: Text(
actualIndex.toString(),
textAlign: TextAlign.center,
maxLines: 1,
softWrap: false,
overflow: TextOverflow.clip,
style: TextStyle(
color: Theme.of(context).textTheme.bodyMedium?.color,
fontSize: 16,
fontWeight: FontWeight.w500,
),
),
),
),
if (showCover)
AlbumImage(
Expand Down

0 comments on commit 70d2834

Please sign in to comment.