put own reaction to the right

This commit is contained in:
Salvatore Giordano
2020-10-27 16:56:51 +01:00
parent e8411d3aa4
commit e9572d48b9
3 changed files with 129 additions and 136 deletions
+3 -1
View File
@@ -392,6 +392,8 @@ class _MessageWidgetState extends State<MessageWidget> {
reactionsMap[element.type] = element;
}
});
final reactionsList = reactionsMap.values.toList()
..sort((a, b) => a.user.id == ownId ? 1 : -1);
return AnimatedSwitcher(
duration: Duration(milliseconds: 300),
@@ -406,7 +408,7 @@ class _MessageWidgetState extends State<MessageWidget> {
flipTail: widget.reverse,
backgroundColor: widget.messageTheme.reactionsBackgroundColor,
borderColor: widget.messageTheme.reactionsBorderColor,
reactions: reactionsMap.values.toList(),
reactions: reactionsList,
),
)
: SizedBox(),