Skip to content

Commit

Permalink
Merge pull request #190 from Demizo/fix_username_overflow
Browse files Browse the repository at this point in the history
[FIX] Fade Long Usernames on Sidebar
  • Loading branch information
KRTirtho authored Sep 2, 2022
2 parents c3bf511 + 0ae0e19 commit 3b24018
Showing 1 changed file with 24 additions and 13 deletions.
37 changes: 24 additions & 13 deletions lib/components/Home/Sidebar.dart
Original file line number Diff line number Diff line change
Expand Up @@ -148,20 +148,31 @@ class Sidebar extends HookConsumerWidget {
child: CircularProgressIndicator(),
)
else if (data != null)
Row(
children: [
CircleAvatar(
backgroundImage:
CachedNetworkImageProvider(avatarImg),
),
const SizedBox(width: 10),
Text(
data.displayName ?? "Guest",
style: const TextStyle(
fontWeight: FontWeight.bold,
Flexible(
child: Row(
mainAxisAlignment:
MainAxisAlignment.spaceEvenly,
children: [
CircleAvatar(
backgroundImage:
CachedNetworkImageProvider(avatarImg),
),
),
],
const SizedBox(
width: 10,
),
Flexible(
child: Text(
data.displayName ?? "Guest",
maxLines: 1,
softWrap: false,
overflow: TextOverflow.fade,
style: const TextStyle(
fontWeight: FontWeight.bold,
),
),
),
],
),
),
IconButton(
icon: const Icon(Icons.settings_outlined),
Expand Down

0 comments on commit 3b24018

Please sign in to comment.