From 676a5069dca71e54384a965bb46d82139077a87c Mon Sep 17 00:00:00 2001 From: Krille Fear Date: Mon, 22 Nov 2021 15:35:51 +0100 Subject: [PATCH] chore: Minor design changes --- lib/pages/chat/events/message_reactions.dart | 18 +++++++++--------- lib/pages/chat/typing_indicators.dart | 8 ++++---- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/lib/pages/chat/events/message_reactions.dart b/lib/pages/chat/events/message_reactions.dart index 9ac5ac57..a2a3e065 100644 --- a/lib/pages/chat/events/message_reactions.dart +++ b/lib/pages/chat/events/message_reactions.dart @@ -44,15 +44,6 @@ class MessageReactions extends StatelessWidget { final reactionList = reactionMap.values.toList(); reactionList.sort((a, b) => b.count - a.count > 0 ? 1 : -1); return Wrap(spacing: 4.0, runSpacing: 4.0, children: [ - if (allReactionEvents.any((e) => e.status.isSending)) - const SizedBox( - width: 28, - height: 28, - child: Padding( - padding: EdgeInsets.all(4.0), - child: CircularProgressIndicator.adaptive(strokeWidth: 1), - ), - ), ...reactionList .map( (r) => _Reaction( @@ -86,6 +77,15 @@ class MessageReactions extends StatelessWidget { ), ) .toList(), + if (allReactionEvents.any((e) => e.status.isSending)) + const SizedBox( + width: 28, + height: 28, + child: Padding( + padding: EdgeInsets.all(4.0), + child: CircularProgressIndicator.adaptive(strokeWidth: 1), + ), + ), ]); } } diff --git a/lib/pages/chat/typing_indicators.dart b/lib/pages/chat/typing_indicators.dart index 1ab3f335..f63a1479 100644 --- a/lib/pages/chat/typing_indicators.dart +++ b/lib/pages/chat/typing_indicators.dart @@ -33,8 +33,8 @@ class TypingIndicators extends StatelessWidget { : Alignment.topLeft, clipBehavior: Clip.hardEdge, decoration: const BoxDecoration(), - padding: EdgeInsets.only( - left: typingUsers.length < 2 ? 8 : 0, + padding: const EdgeInsets.only( + left: 8.0, bottom: bottomPadding, ), child: Row( @@ -43,7 +43,7 @@ class TypingIndicators extends StatelessWidget { height: Avatar.defaultSize, width: typingUsers.length < 2 ? Avatar.defaultSize - : Avatar.defaultSize + 8, + : Avatar.defaultSize + 16, child: Stack( children: [ if (typingUsers.isNotEmpty) @@ -53,7 +53,7 @@ class TypingIndicators extends StatelessWidget { ), if (typingUsers.length == 2) Padding( - padding: const EdgeInsets.only(left: 8), + padding: const EdgeInsets.only(left: 16), child: Avatar( mxContent: typingUsers.length == 2 ? typingUsers.last.avatarUrl