diff --git a/lib/src/easy_loading.dart b/lib/src/easy_loading.dart index 1193f48..4014d1e 100644 --- a/lib/src/easy_loading.dart +++ b/lib/src/easy_loading.dart @@ -92,6 +92,7 @@ enum EasyLoadingIndicatorType { ripple, spinningCircle, squareCircle, + cupertino, } /// loading status diff --git a/lib/src/widgets/indicator.dart b/lib/src/widgets/indicator.dart index 0ac3f99..9fbfcdf 100644 --- a/lib/src/widgets/indicator.dart +++ b/lib/src/widgets/indicator.dart @@ -22,6 +22,7 @@ import 'package:flutter/material.dart'; import 'package:flutter_spinkit/flutter_spinkit.dart'; +import 'package:flutter/cupertino.dart'; import '../easy_loading.dart'; import '../theme.dart'; @@ -199,6 +200,12 @@ class _LoadingIndicatorState extends State { size: _size, ); break; + case EasyLoadingIndicatorType.cupertino: + _indicator = CupertinoActivityIndicator( + color: _indicatorColor, + radius: _size, + ); + break; default: _indicator = SpinKitFadingCircle( color: _indicatorColor, diff --git a/pubspec.yaml b/pubspec.yaml index e31e2ff..784dde5 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,5 +1,5 @@ name: flutter_easyloading -description: A clean and lightweight loading/toast widget for Flutter, Easy to use without context, Support iOS、Android and Web +description: Easy loading without context version: 3.0.5 homepage: https://github.com/nslogx/flutter_easyloading @@ -11,6 +11,7 @@ dependencies: sdk: flutter flutter_spinkit: ^5.1.0 + cupertino_icons: ^1.0.8 dev_dependencies: flutter_test: