ente/lib/ui/common/loading_widget.dart

26 lines
681 B
Dart
Raw Normal View History

2022-10-19 12:17:45 +00:00
import 'package:flutter/material.dart';
import 'package:photos/theme/ente_theme.dart';
2020-03-24 19:59:36 +00:00
class EnteLoadingWidget extends StatelessWidget {
2022-10-19 12:17:45 +00:00
final Color? color;
final bool is20pts;
const EnteLoadingWidget({this.is20pts = false, this.color, Key? key})
: super(key: key);
@override
Widget build(BuildContext context) {
return Center(
2022-10-19 12:17:45 +00:00
child: Padding(
padding: EdgeInsets.all(is20pts ? 3 : 5),
2022-10-19 12:17:45 +00:00
child: SizedBox.fromSize(
size: const Size.square(14),
2022-10-19 12:17:45 +00:00
child: CircularProgressIndicator(
strokeWidth: 2,
color: color ?? getEnteColorScheme(context).strokeBase,
),
),
),
);
}
}