From b55d8bd2a82eb501740a05f357b9d89e57f3668e Mon Sep 17 00:00:00 2001 From: Sahil Kumar Date: Wed, 6 Jan 2021 16:41:03 +0530 Subject: [PATCH] [UserItem] Fix selected check icon Signed-off-by: Sahil Kumar --- lib/src/stream_svg_icon.dart | 12 ++++++++++++ lib/src/user_item.dart | 10 ++-------- 2 files changed, 14 insertions(+), 8 deletions(-) diff --git a/lib/src/stream_svg_icon.dart b/lib/src/stream_svg_icon.dart index e7ef46c3..edf1a697 100644 --- a/lib/src/stream_svg_icon.dart +++ b/lib/src/stream_svg_icon.dart @@ -194,6 +194,18 @@ class StreamSvgIcon extends StatelessWidget { ); } + factory StreamSvgIcon.checkSend({ + double size, + Color color, + }) { + return StreamSvgIcon( + assetName: 'Icon_check_send.svg', + color: color, + width: size, + height: size, + ); + } + factory StreamSvgIcon.penWrite({ double size, Color color, diff --git a/lib/src/user_item.dart b/lib/src/user_item.dart index 50a8b7a7..58a354fc 100644 --- a/lib/src/user_item.dart +++ b/lib/src/user_item.dart @@ -73,14 +73,8 @@ class UserItem extends StatelessWidget { ), ), trailing: selected - ? CircleAvatar( - backgroundColor: - StreamChatTheme.of(context).colorTheme.accentBlue, - child: StreamSvgIcon.check( - size: 20, - color: StreamChatTheme.of(context).colorTheme.white, - ), - radius: 10, + ? StreamSvgIcon.checkSend( + color: StreamChatTheme.of(context).colorTheme.accentBlue, ) : null, title: Text(