-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: dialog added loading indicators, loading indicator added color
- Loading branch information
1 parent
4ffd6b8
commit 0b9053b
Showing
7 changed files
with
108 additions
and
70 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import 'dart:async'; | ||
|
||
typedef AsyncOrCallback = FutureOr<void> Function(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
// ignore_for_file: prefer_function_declarations_over_variables, unnecessary_type_check | ||
|
||
import 'package:flutter/foundation.dart'; | ||
import 'package:flutter_test/flutter_test.dart'; | ||
import 'package:impaktfull_ui/src/util/future/async_or_callback.dart'; | ||
|
||
void main() { | ||
test('AsyncCallback', () { | ||
final AsyncOrCallback callback = () async {}; | ||
expect(callback is Future<void> Function(), true); | ||
expect(callback is AsyncCallback, true); | ||
}); | ||
test('VoidCallback', () { | ||
final AsyncOrCallback callback = () {}; | ||
expect(callback is Future<void> Function(), false); | ||
expect(callback is AsyncCallback, false); | ||
expect(callback is void Function(), true); | ||
expect(callback is VoidCallback, true); | ||
}); | ||
} |