Skip to content

Instantly share code, notes, and snippets.

@luizmarcus
Created October 3, 2020 12:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save luizmarcus/63ed250bbe14ac556222cace8f0aaea4 to your computer and use it in GitHub Desktop.
Save luizmarcus/63ed250bbe14ac556222cace8f0aaea4 to your computer and use it in GitHub Desktop.
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text("Chat App"),
),
body: DashChat(
inverted: false,
onSend: onSend,
sendOnEnter: true,
textInputAction: TextInputAction.send,
user: user,
inputDecoration:
InputDecoration.collapsed(hintText: "Digite a mensagem aqui..."),
dateFormat: DateFormat('dd-MMM-yyyy'),
timeFormat: DateFormat('HH:mm'),
messages: messages,
showUserAvatar: false,
showAvatarForEveryMessage: false,
scrollToBottom: true,
inputMaxLines: 5,
messageContainerPadding: EdgeInsets.only(left: 5.0, right: 5.0),
alwaysShowSend: true,
inputTextStyle: TextStyle(fontSize: 16.0),
inputContainerStyle: BoxDecoration(
border: Border.all(width: 0.0),
color: Colors.white,
),
));
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment