fix unread indicator

This commit is contained in:
Salvatore Giordano
2020-10-21 10:39:50 +02:00
parent 71a80286f7
commit 00e9e796e4
+12 -6
View File
@@ -12,12 +12,17 @@ class UnreadIndicator extends StatelessWidget {
@override
Widget build(BuildContext context) {
return Padding(
padding: const EdgeInsets.only(left: 8.0),
child: CircleAvatar(
backgroundColor:
StreamChatTheme.of(context).channelPreviewTheme.unreadCounterColor,
radius: 8,
return Material(
borderRadius: BorderRadius.circular(8),
color: StreamChatTheme.of(context).channelPreviewTheme.unreadCounterColor,
child: Padding(
padding: const EdgeInsets.only(
left: 5.0,
right: 5.0,
top: 2,
bottom: 1,
),
child: Center(
child: Text(
'${channel.state.unreadCount}',
style: TextStyle(
@@ -26,6 +31,7 @@ class UnreadIndicator extends StatelessWidget {
),
),
),
),
);
}
}