fix: pixel overflow

This commit is contained in:
2026-05-25 12:55:36 +02:00
parent efd1097d5a
commit b9710ed851

View File

@@ -21,32 +21,35 @@ class GameLabel extends StatelessWidget {
? Colors.black ? Colors.black
: Colors.white; : Colors.white;
return IntrinsicHeight( return Row(
child: Row( mainAxisSize: MainAxisSize.min,
mainAxisSize: MainAxisSize.min, children: [
children: [ // Title
// Title Container(
Container( decoration: BoxDecoration(
decoration: BoxDecoration( color: backgroundColor.withAlpha(230),
color: backgroundColor.withAlpha(230), borderRadius: const BorderRadius.only(
borderRadius: const BorderRadius.only( topLeft: Radius.circular(8),
topLeft: Radius.circular(8), bottomLeft: Radius.circular(8),
bottomLeft: Radius.circular(8),
),
),
padding: const EdgeInsets.symmetric(vertical: 4, horizontal: 8),
child: Text(
title,
style: TextStyle(
fontSize: 12,
color: fontColor,
fontWeight: FontWeight.bold,
),
), ),
), ),
padding: const EdgeInsets.symmetric(vertical: 4, horizontal: 8),
child: Text(
title,
maxLines: 1,
overflow: TextOverflow.ellipsis,
softWrap: false,
style: TextStyle(
fontSize: 12,
color: fontColor,
fontWeight: FontWeight.bold,
),
),
),
// Description // Description
Container( Flexible(
child: Container(
decoration: BoxDecoration( decoration: BoxDecoration(
color: backgroundColor.withAlpha(140), color: backgroundColor.withAlpha(140),
borderRadius: const BorderRadius.only( borderRadius: const BorderRadius.only(
@@ -57,6 +60,9 @@ class GameLabel extends StatelessWidget {
padding: const EdgeInsets.symmetric(vertical: 4, horizontal: 8), padding: const EdgeInsets.symmetric(vertical: 4, horizontal: 8),
child: Text( child: Text(
description, description,
maxLines: 1,
overflow: TextOverflow.ellipsis,
softWrap: false,
style: TextStyle( style: TextStyle(
fontSize: 12, fontSize: 12,
color: fontColor, color: fontColor,
@@ -64,8 +70,8 @@ class GameLabel extends StatelessWidget {
), ),
), ),
), ),
], ),
), ],
); );
} }
} }