feat(apps): 新增 ErrorRetrySurface 和 FullScreenLoading 通用组件
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import 'app_loading_indicator.dart';
|
||||
|
||||
class FullScreenLoading extends StatelessWidget {
|
||||
const FullScreenLoading({super.key, this.safeArea = false});
|
||||
|
||||
final bool safeArea;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final content = const Center(child: AppLoadingIndicator(size: 22));
|
||||
if (!safeArea) {
|
||||
return content;
|
||||
}
|
||||
return const SafeArea(child: Center(child: AppLoadingIndicator(size: 22)));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user