chore: redesign start first chat

This commit is contained in:
Christian Pauly 2021-01-16 16:03:25 +01:00
parent cf07eed211
commit e13a732688
2 changed files with 21 additions and 17 deletions

View File

@ -1609,7 +1609,7 @@
"type": "text",
"placeholders": {}
},
"startYourFirstChat": "Start your first chat :-)",
"startYourFirstChat": "Start your first chat right now! 🙂\n- Tap on "+"\n- Enter the username of a friend\n- Have fun chatting",
"@startYourFirstChat": {
"type": "text",
"placeholders": {}

View File

@ -283,23 +283,27 @@ class _ChatListState extends State<ChatList> {
searchController.text.toLowerCase() ??
'')));
if (rooms.isEmpty && (!searchMode)) {
return Center(
child: Column(
mainAxisSize: MainAxisSize.min,
children: <Widget>[
Icon(
searchMode
? Icons.search_outlined
: Icons.chat_bubble_outline,
size: 80,
color: Colors.grey,
),
Text(searchMode
return Column(
mainAxisAlignment: MainAxisAlignment.center,
mainAxisSize: MainAxisSize.min,
children: <Widget>[
Icon(
searchMode
? Icons.search_outlined
: Icons.maps_ugc_outlined,
size: 80,
color: Colors.grey,
),
Text(
searchMode
? L10n.of(context).noRoomsFound
: L10n.of(context)
.startYourFirstChat),
],
),
: L10n.of(context).startYourFirstChat,
style: TextStyle(
color: Colors.grey,
fontSize: 16,
),
),
],
);
}
final totalCount = rooms.length;