design: Nicer loading screen and empty page
This commit is contained in:
parent
bc9b5507b4
commit
572ca42d62
4 changed files with 31 additions and 5 deletions
|
|
@ -1,3 +1,4 @@
|
|||
import 'package:fluffychat/pages/views/empty_page_view.dart';
|
||||
import 'package:matrix/matrix.dart';
|
||||
import 'package:vrouter/vrouter.dart';
|
||||
import 'package:fluffychat/widgets/matrix.dart';
|
||||
|
|
@ -16,6 +17,6 @@ class LoadingView extends StatelessWidget {
|
|||
),
|
||||
);
|
||||
}
|
||||
return Scaffold(body: Center(child: CircularProgressIndicator()));
|
||||
return EmptyPage(loading: true);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
import 'package:fluffychat/pages/views/empty_page_view.dart';
|
||||
import 'package:matrix/matrix.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
|
|
@ -14,7 +15,7 @@ class WaitForInitPage extends StatelessWidget {
|
|||
stream: Matrix.of(context).client.onLoginStateChanged.stream,
|
||||
builder: (context, snapshot) {
|
||||
if (!snapshot.hasData) {
|
||||
return Scaffold(body: Center(child: CircularProgressIndicator()));
|
||||
return EmptyPage(loading: true);
|
||||
}
|
||||
return page;
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue