1
0
mirror of https://gitlab.com/comunic/comunicmobile synced 2025-06-19 08:15:16 +00:00

Start to display user groups

This commit is contained in:
2020-04-15 12:04:19 +02:00
parent 8300fc8ca9
commit 4bedbc4b25
9 changed files with 173 additions and 1 deletions

6
lib/utils/api_utils.dart Normal file
View File

@ -0,0 +1,6 @@
/// API utilities
///
/// @author Pierre Hubert
/// Casting helper
T cast<T>(dynamic val) => val is T ? val : null;

View File

@ -31,7 +31,11 @@ Widget buildLoadingPage({
}
/// Build and return an error card
Widget buildErrorCard(String message, {List<Widget> actions}) {
Widget buildErrorCard(String message, {List<Widget> actions, bool hide = false}) {
if(hide)
return Container();
return Card(
elevation: 2.0,
color: Colors.red,