mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2024-12-22 19:39:22 +00:00
chans loading screen animated asset update
This commit is contained in:
parent
bf4c44ad1b
commit
3c345f2668
4 changed files with 22 additions and 5 deletions
BIN
assets/gif/stacy-plain.gif
Normal file
BIN
assets/gif/stacy-plain.gif
Normal file
Binary file not shown.
After Width: | Height: | Size: 2.7 MiB |
|
@ -16,6 +16,12 @@ class LoadingView extends StatelessWidget {
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
final size = MediaQuery.of(context).size;
|
final size = MediaQuery.of(context).size;
|
||||||
final width = min(size.width, size.height) * 0.5;
|
final width = min(size.width, size.height) * 0.5;
|
||||||
|
|
||||||
|
final isChan = Theme.of(context).extension<StackColors>()!.themeType ==
|
||||||
|
ThemeType.chan ||
|
||||||
|
Theme.of(context).extension<StackColors>()!.themeType ==
|
||||||
|
ThemeType.darkChans;
|
||||||
|
|
||||||
return Background(
|
return Background(
|
||||||
child: Scaffold(
|
child: Scaffold(
|
||||||
backgroundColor: Theme.of(context).extension<StackColors>()!.background,
|
backgroundColor: Theme.of(context).extension<StackColors>()!.background,
|
||||||
|
@ -35,11 +41,17 @@ class LoadingView extends StatelessWidget {
|
||||||
),
|
),
|
||||||
child: SizedBox(
|
child: SizedBox(
|
||||||
width: width,
|
width: width,
|
||||||
child: Lottie.asset(
|
child: isChan
|
||||||
Assets.lottie.test2,
|
? Image(
|
||||||
animate: true,
|
image: AssetImage(
|
||||||
repeat: true,
|
Assets.gif.stacyPlain,
|
||||||
),
|
),
|
||||||
|
)
|
||||||
|
: Lottie.asset(
|
||||||
|
Assets.lottie.test2,
|
||||||
|
animate: true,
|
||||||
|
repeat: true,
|
||||||
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
// child: Image(
|
// child: Image(
|
||||||
|
|
|
@ -401,6 +401,8 @@ class _ANIMATIONS {
|
||||||
class _GIF {
|
class _GIF {
|
||||||
const _GIF();
|
const _GIF();
|
||||||
|
|
||||||
|
String get stacyPlain => "assets/gif/stacy-plain.gif";
|
||||||
|
|
||||||
String plain(Coin coin) {
|
String plain(Coin coin) {
|
||||||
return "assets/gif/coins/${coin.mainNetVersion.name}/plain.gif";
|
return "assets/gif/coins/${coin.mainNetVersion.name}/plain.gif";
|
||||||
}
|
}
|
||||||
|
|
|
@ -364,6 +364,9 @@ flutter:
|
||||||
# basic
|
# basic
|
||||||
- assets/lottie/test2.json
|
- assets/lottie/test2.json
|
||||||
|
|
||||||
|
# gifs
|
||||||
|
- assets/gif/
|
||||||
|
|
||||||
# coin gifs
|
# coin gifs
|
||||||
- assets/gif/coins/bitcoin/
|
- assets/gif/coins/bitcoin/
|
||||||
- assets/gif/coins/bitcoincash/
|
- assets/gif/coins/bitcoincash/
|
||||||
|
|
Loading…
Reference in a new issue