migrate chatty

This commit is contained in:
Salvatore Giordano
2021-05-18 17:15:37 +02:00
parent 33622093e0
commit bc655e0dc4
27 changed files with 181 additions and 159 deletions
@@ -143,9 +143,9 @@ class FriendsSelectionView extends StatelessWidget {
CircleAvatar(
radius: 30,
backgroundImage: NetworkImage(
chatUserState.chatUser.image),
chatUserState.chatUser.image!),
),
Text(chatUserState.chatUser.name),
Text(chatUserState.chatUser.name!),
],
),
Positioned(
@@ -178,9 +178,9 @@ class FriendsSelectionView extends StatelessWidget {
},
leading: CircleAvatar(
backgroundImage:
NetworkImage(chatUserState.chatUser.image),
NetworkImage(chatUserState.chatUser.image!),
),
title: Text(chatUserState.chatUser.name),
title: Text(chatUserState.chatUser.name!),
trailing: isGroup
? Checkbox(
value: chatUserState.selected,
@@ -13,8 +13,8 @@ class GroupSelectionState {
this.channel,
this.isLoading = false,
});
final File file;
final Channel channel;
final File? file;
final Channel? channel;
final bool isLoading;
}
@@ -28,7 +28,7 @@ class GroupSelectionView extends StatelessWidget {
context,
Scaffold(
body: StreamChannel(
channel: snapshot.channel,
channel: snapshot.channel!,
child: ChannelPage(),
),
),
@@ -60,9 +60,9 @@ class GroupSelectionView extends StatelessWidget {
children: [
AvatarImageView(
onTap: context.read<GroupSelectionCubit>().pickImage,
child: snapshot?.file != null
child: snapshot.file != null
? Image.file(
snapshot?.file,
snapshot.file!,
fit: BoxFit.cover,
)
: Icon(
@@ -104,9 +104,9 @@ class GroupSelectionView extends StatelessWidget {
CircleAvatar(
radius: 30,
backgroundImage:
NetworkImage(chatUserState.chatUser.image),
NetworkImage(chatUserState.chatUser.image!),
),
Text(chatUserState.chatUser.name),
Text(chatUserState.chatUser.name!),
],
),
);