Edited common reaction emojis, display user avatar in reaction overview
This commit is contained in:
@ -1,6 +1,7 @@
|
||||
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:marianum_mobile/widget/userAvatar.dart';
|
||||
|
||||
import '../../../api/marianumcloud/talk/getReactions/getReactions.dart';
|
||||
import '../../../api/marianumcloud/talk/getReactions/getReactionsResponse.dart';
|
||||
@ -54,16 +55,20 @@ class _MessageReactionsState extends State<MessageReactions> {
|
||||
children: entry.value.map((e) {
|
||||
bool isSelf = AccountData().getUsername() == e.actorId;
|
||||
return ListTile(
|
||||
leading: const CenteredLeading(Icon(Icons.person)),
|
||||
leading: UserAvatar(username: e.actorId, isGroup: false),
|
||||
title: Text(e.actorDisplayName),
|
||||
subtitle: isSelf ? const Text("Du") : e.actorType == GetReactionsResponseObjectActorType.guests ? const Text("Gast") : null,
|
||||
trailing: isSelf ? null : Visibility(
|
||||
visible: kReleaseMode,
|
||||
child: IconButton(
|
||||
onPressed: () => UnimplementedDialog.show(context),
|
||||
icon: const Icon(Icons.textsms_outlined),
|
||||
subtitle: isSelf
|
||||
? const Text("Du")
|
||||
: e.actorType == GetReactionsResponseObjectActorType.guests ? const Text("Gast") : null,
|
||||
trailing: isSelf
|
||||
? null
|
||||
: Visibility(
|
||||
visible: kReleaseMode,
|
||||
child: IconButton(
|
||||
onPressed: () => UnimplementedDialog.show(context),
|
||||
icon: const Icon(Icons.textsms_outlined),
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}).toList(),
|
||||
);
|
||||
|
Reference in New Issue
Block a user