updates
This commit is contained in:
parent
6af87aa69c
commit
c464724bc8
@ -12,7 +12,7 @@ class ContactDetailsConversation extends StatelessWidget {
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
centerTitle: true,
|
||||
title: Text(contact.name),
|
||||
title: Text(contact.name!),
|
||||
),
|
||||
body: Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 20.0, vertical: 12.0),
|
||||
@ -26,7 +26,7 @@ class ContactDetailsConversation extends StatelessWidget {
|
||||
),
|
||||
const SizedBox(height: 15.0),
|
||||
const Text('Display Name', style: kMediumHeadingStyle),
|
||||
Text(contact.name),
|
||||
Text(contact.name!),
|
||||
],
|
||||
),
|
||||
),
|
||||
|
@ -104,7 +104,14 @@ class _ConversationViewState extends State<ConversationView> {
|
||||
_chatMessages.add(MessageBubble(
|
||||
isUser: false,
|
||||
// ignore: avoid_dynamic_calls
|
||||
sender: widget.data.name,
|
||||
sender: widget.data.isGroup
|
||||
// ignore: avoid_dynamic_calls
|
||||
? widget.data.members.length == 0
|
||||
? 'some person'
|
||||
// ignore: avoid_dynamic_calls
|
||||
: widget.data.members[0]
|
||||
// ignore: avoid_dynamic_calls
|
||||
: widget.data.name,
|
||||
text: 'Hey there! How is it going?',
|
||||
));
|
||||
});
|
||||
@ -137,6 +144,7 @@ class _ConversationViewState extends State<ConversationView> {
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
const SizedBox(width: 10.0),
|
||||
Expanded(
|
||||
child: SizedBox(
|
||||
height: 45.0,
|
||||
@ -155,16 +163,19 @@ class _ConversationViewState extends State<ConversationView> {
|
||||
hintStyle: Theme.of(context).textTheme.caption,
|
||||
fillColor: Colors.grey[200],
|
||||
filled: true,
|
||||
enabledBorder: const OutlineInputBorder(
|
||||
borderSide: BorderSide(color: Colors.transparent),
|
||||
enabledBorder: OutlineInputBorder(
|
||||
borderRadius: BorderRadius.circular(360),
|
||||
borderSide:
|
||||
const BorderSide(color: Colors.transparent),
|
||||
),
|
||||
focusedBorder: const OutlineInputBorder(
|
||||
borderSide: BorderSide(color: Colors.transparent),
|
||||
focusedBorder: OutlineInputBorder(
|
||||
borderRadius: BorderRadius.circular(360),
|
||||
borderSide:
|
||||
const BorderSide(color: Colors.transparent),
|
||||
),
|
||||
),
|
||||
),
|
||||
)),
|
||||
const SizedBox(width: 4.0),
|
||||
IconButton(
|
||||
onPressed: () {
|
||||
if (_messageFieldController.text.isNotEmpty) {
|
||||
@ -185,6 +196,9 @@ class _ConversationViewState extends State<ConversationView> {
|
||||
],
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
height: MediaQuery.of(context).size.height * 0.02,
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
|
@ -27,7 +27,7 @@ class _GroupDetailsConversationState extends State<GroupDetailsConversation> {
|
||||
// getting all members of group
|
||||
void _getMembers() {
|
||||
setState(() {
|
||||
_members = List.from(widget.group.members);
|
||||
_members = List.from(widget.group.members!);
|
||||
});
|
||||
}
|
||||
|
||||
@ -64,7 +64,7 @@ class _GroupDetailsConversationState extends State<GroupDetailsConversation> {
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
centerTitle: true,
|
||||
title: Text(widget.group.name),
|
||||
title: Text(widget.group.name!),
|
||||
),
|
||||
body: SingleChildScrollView(
|
||||
child: Padding(
|
||||
@ -77,12 +77,12 @@ class _GroupDetailsConversationState extends State<GroupDetailsConversation> {
|
||||
radius: 70,
|
||||
backgroundImage: widget.group.photo == ''
|
||||
? const AssetImage('assets/dp.png') as ImageProvider
|
||||
: FileImage(File(widget.group.photo)),
|
||||
: FileImage(File(widget.group.photo!)),
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 25.0),
|
||||
const Text('Group Name', style: kMediumHeadingStyle),
|
||||
Text(widget.group.name),
|
||||
Text(widget.group.name!),
|
||||
const Divider(),
|
||||
ListTile(
|
||||
leading: const Icon(Icons.person_add),
|
||||
@ -137,7 +137,7 @@ class _GroupDetailsConversationState extends State<GroupDetailsConversation> {
|
||||
leading: const CircleAvatar(
|
||||
backgroundImage: AssetImage('assets/dp.png'),
|
||||
),
|
||||
title: Text(_contactsList[index].name),
|
||||
title: Text(_contactsList[index].name!),
|
||||
onTap: () {
|
||||
setState(() {
|
||||
_newMembers.add(_contactsList[index].name);
|
||||
|
Loading…
Reference in New Issue
Block a user