fix reaction bubble ui

This commit is contained in:
Salvatore Giordano
2020-10-15 10:37:22 +02:00
parent 2780936de3
commit 069f1a8ee4
7 changed files with 313 additions and 239 deletions
+3 -3
View File
@@ -25,7 +25,7 @@ class ReactionPicker extends StatelessWidget {
Widget build(BuildContext context) {
final reactionAssets = StreamChatTheme.of(context).reactionAssets;
return Material(
color: messageTheme.reactionsBackgroundColor,
color: messageTheme.ownReactionsBackgroundColor,
clipBehavior: Clip.hardEdge,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(24),
@@ -35,7 +35,7 @@ class ReactionPicker extends StatelessWidget {
mainAxisAlignment: MainAxisAlignment.center,
mainAxisSize: MainAxisSize.min,
children: reactionAssets.map((reactionAsset) {
final ownReactionIndex = message.latestReactions?.indexWhere(
final ownReactionIndex = message.ownReactions?.indexWhere(
(reaction) => reaction.type == reactionAsset.type) ??
-1;
return IconButton(
@@ -45,7 +45,7 @@ class ReactionPicker extends StatelessWidget {
package: reactionAsset.package,
color: ownReactionIndex != -1
? StreamChatTheme.of(context).accentColor
: Colors.black,
: Theme.of(context).iconTheme.color,
),
onPressed: () {
if (ownReactionIndex != -1) {