fix(app-selector): fix text overflow on small screen

This commit is contained in:
Aabed Khan 2023-07-13 00:14:47 +05:45
parent 2834e8b348
commit e64318c947
2 changed files with 20 additions and 12 deletions

View File

@ -84,12 +84,16 @@ class _InstalledAppItemState extends State<InstalledAppItem> {
}, },
), ),
const SizedBox(width: 4), const SizedBox(width: 4),
Text( Flexible(
widget.patchesCount == 1 child: Text(
? '${widget.patchesCount} patch' widget.patchesCount == 1
: '${widget.patchesCount} patches', ? '${widget.patchesCount} patch'
style: TextStyle( : '${widget.patchesCount} patches',
color: Theme.of(context).colorScheme.secondary, maxLines: 1,
overflow: TextOverflow.ellipsis,
style: TextStyle(
color: Theme.of(context).colorScheme.secondary,
),
), ),
), ),
], ],

View File

@ -78,12 +78,16 @@ class _NotInstalledAppItem extends State<NotInstalledAppItem> {
}, },
), ),
const SizedBox(width: 4), const SizedBox(width: 4),
Text( Flexible(
widget.patchesCount == 1 child: Text(
? '${widget.patchesCount} patch' widget.patchesCount == 1
: '${widget.patchesCount} patches', ? '${widget.patchesCount} patch'
style: TextStyle( : '${widget.patchesCount} patches',
color: Theme.of(context).colorScheme.secondary, maxLines: 1,
overflow: TextOverflow.ellipsis,
style: TextStyle(
color: Theme.of(context).colorScheme.secondary,
),
), ),
), ),
], ],