mirror of
https://gitlab.com/veilid/veilidchat.git
synced 2025-06-07 22:22:42 -04:00
home layout
This commit is contained in:
parent
f754f7d5ed
commit
ca6b00e021
45 changed files with 2168 additions and 561 deletions
|
@ -1,6 +1,7 @@
|
|||
import 'package:blurry_modal_progress_hud/blurry_modal_progress_hud.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_spinkit/flutter_spinkit.dart';
|
||||
import 'package:quickalert/quickalert.dart';
|
||||
|
||||
extension BorderExt on Widget {
|
||||
DecoratedBox debugBorder() => DecoratedBox(
|
||||
|
@ -13,10 +14,29 @@ extension ModalProgressExt on Widget {
|
|||
BlurryModalProgressHUD(
|
||||
inAsyncCall: isLoading,
|
||||
blurEffectIntensity: 4,
|
||||
progressIndicator: SpinKitFoldingCube(
|
||||
color: Theme.of(context).highlightColor,
|
||||
size: 90,
|
||||
),
|
||||
progressIndicator: buildProgressIndicator(context),
|
||||
color: Theme.of(context).shadowColor,
|
||||
child: this);
|
||||
}
|
||||
|
||||
Widget buildProgressIndicator(BuildContext context) => SpinKitFoldingCube(
|
||||
color: Theme.of(context).highlightColor,
|
||||
size: 90,
|
||||
);
|
||||
|
||||
Widget waitingPage(BuildContext context) => ColoredBox(
|
||||
color: Theme.of(context).scaffoldBackgroundColor,
|
||||
child: Center(child: buildProgressIndicator(context)));
|
||||
|
||||
Future<void> showErrorModal(
|
||||
BuildContext context, String title, String text) async {
|
||||
await QuickAlert.show(
|
||||
context: context,
|
||||
type: QuickAlertType.error,
|
||||
title: title,
|
||||
text: text,
|
||||
//backgroundColor: Colors.black,
|
||||
//titleColor: Colors.white,
|
||||
//textColor: Colors.white,
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue