@@ -853,6 +853,20 @@ class MessageWithPossibleSender extends StatelessWidget {
853
853
Widget build (BuildContext context) {
854
854
final message = item.message;
855
855
856
+ final Widget ? senderRow = item.showSender
857
+ ? GestureDetector (
858
+ onTap: () => Navigator .push (context,
859
+ ProfilePage .buildRoute (context: context,
860
+ userId: message.senderId)),
861
+ child: Text (message.senderFullName, // TODO get from user data
862
+ style: const TextStyle (
863
+ fontFamily: 'Source Sans 3' ,
864
+ fontSize: 18 ,
865
+ height: (22 / 18 ),
866
+ ).merge (weightVariableTextStyle (context, wght: 600 ,
867
+ wghtIfPlatformRequestsBold: 900 ))))
868
+ : null ;
869
+
856
870
return GestureDetector (
857
871
behavior: HitTestBehavior .translucent,
858
872
onLongPress: () => showMessageActionSheet (context: context, message: message),
@@ -875,17 +889,7 @@ class MessageWithPossibleSender extends StatelessWidget {
875
889
children: [
876
890
if (item.showSender) ...[
877
891
const SizedBox (height: 3 ),
878
- GestureDetector (
879
- onTap: () => Navigator .push (context,
880
- ProfilePage .buildRoute (context: context,
881
- userId: message.senderId)),
882
- child: Text (message.senderFullName, // TODO get from user data
883
- style: const TextStyle (
884
- fontFamily: 'Source Sans 3' ,
885
- fontSize: 18 ,
886
- height: (22 / 18 ),
887
- ).merge (weightVariableTextStyle (context, wght: 600 ,
888
- wghtIfPlatformRequestsBold: 900 )))),
892
+ senderRow! ,
889
893
const SizedBox (height: 4 ),
890
894
],
891
895
MessageContent (message: message, content: item.content),
0 commit comments