feat: Added show in chat

This commit is contained in:
Deven Joshi
2021-01-04 16:00:20 +05:30
parent 43446713c8
commit 95d91f3959
12 changed files with 123 additions and 6 deletions
+6
View File
@@ -119,6 +119,8 @@ class MessageWidget extends StatefulWidget {
final List<Read> readList;
final ShowMessageCallback onShowMessage;
/// If true show the users username next to the timestamp of the message
final bool showUsername;
final bool showTimestamp;
@@ -157,6 +159,7 @@ class MessageWidget extends StatefulWidget {
this.onUserAvatarTap,
this.onLinkTap,
this.onMessageActions,
this.onShowMessage,
this.editMessageInputBuilder,
this.textBuilder,
Map<String, AttachmentBuilder> customAttachmentBuilders,
@@ -179,6 +182,7 @@ class MessageWidget extends StatefulWidget {
MediaQuery.of(context).size.width * 0.8,
MediaQuery.of(context).size.height * 0.3,
),
onShowMessage: onShowMessage,
);
},
'video': (context, message, attachment) {
@@ -190,6 +194,7 @@ class MessageWidget extends StatefulWidget {
MediaQuery.of(context).size.height * 0.3,
),
message: message,
onShowMessage: onShowMessage,
);
},
'giphy': (context, message, attachment) {
@@ -201,6 +206,7 @@ class MessageWidget extends StatefulWidget {
MediaQuery.of(context).size.width * 0.8,
MediaQuery.of(context).size.height * 0.3,
),
onShowMessage: onShowMessage,
);
},
'file': (context, message, attachment) {