@@ -10,6 +10,8 @@ import 'package:zhiying_base_widget/pages/main_page/notifier/main_page_bg_notifi | |||||
import 'package:zhiying_base_widget/pages/main_page/notifier/main_page_notifier.dart'; | import 'package:zhiying_base_widget/pages/main_page/notifier/main_page_notifier.dart'; | ||||
import 'package:zhiying_base_widget/utils/contants.dart'; | import 'package:zhiying_base_widget/utils/contants.dart'; | ||||
import 'package:zhiying_base_widget/widgets/others/mine_header_bg_widget.dart'; | import 'package:zhiying_base_widget/widgets/others/mine_header_bg_widget.dart'; | ||||
import 'package:zhiying_base_widget/widgets/wallet/wallet_detail/wallet_detail_sk.dart'; | |||||
import 'package:zhiying_base_widget/widgets/wallet_bil_detail/wallet_bil_sk.dart'; | |||||
import 'package:zhiying_comm/zhiying_comm.dart'; | import 'package:zhiying_comm/zhiying_comm.dart'; | ||||
import 'package:zhiying_comm/util/base_bloc.dart'; | import 'package:zhiying_comm/util/base_bloc.dart'; | ||||
import 'package:zhiying_comm/util/custom_sliver_persistent_header_delegate.dart'; | import 'package:zhiying_comm/util/custom_sliver_persistent_header_delegate.dart'; | ||||
@@ -73,7 +75,7 @@ class _BilDetailPageContainerState extends State<BilDetailPageContainer> { | |||||
stream: _bloc.outData, | stream: _bloc.outData, | ||||
builder: (context, sny) { | builder: (context, sny) { | ||||
if (sny.data == null) { | if (sny.data == null) { | ||||
return Container(); | |||||
return WalletBilDetailSkeleton(); | |||||
} | } | ||||
var model = sny.data; | var model = sny.data; | ||||
return Scaffold( | return Scaffold( | ||||
@@ -0,0 +1,211 @@ | |||||
import 'package:flutter/material.dart'; | |||||
import 'package:shimmer/shimmer.dart'; | |||||
class WalletBilDetailSkeleton extends StatelessWidget { | |||||
@override | |||||
Widget build(BuildContext context) { | |||||
return Container( | |||||
child: Shimmer.fromColors( | |||||
baseColor: Colors.grey[300], | |||||
highlightColor: Colors.grey[100], | |||||
child: Column( | |||||
children: <Widget>[ | |||||
Container( | |||||
color: Colors.white, | |||||
height: 80, | |||||
), | |||||
SizedBox( | |||||
height: 32, | |||||
), | |||||
Row( | |||||
mainAxisAlignment: MainAxisAlignment.spaceEvenly, | |||||
children: <Widget>[ | |||||
Container( | |||||
color: Colors.white, | |||||
height: 40, | |||||
width: 100, | |||||
), | |||||
Container( | |||||
color: Colors.white, | |||||
height: 40, | |||||
width: 100, | |||||
) | |||||
], | |||||
), | |||||
SizedBox( | |||||
height: 16, | |||||
), | |||||
Row( | |||||
mainAxisAlignment: MainAxisAlignment.start, | |||||
children: <Widget>[ | |||||
SizedBox( | |||||
width: 16, | |||||
), | |||||
Container( | |||||
color: Colors.white, | |||||
height: 40, | |||||
width: 80, | |||||
), | |||||
SizedBox( | |||||
width: 16, | |||||
), | |||||
Container( | |||||
color: Colors.white, | |||||
height: 40, | |||||
width: 80, | |||||
), | |||||
SizedBox( | |||||
width: 16, | |||||
), | |||||
Container( | |||||
color: Colors.white, | |||||
height: 40, | |||||
width: 80, | |||||
), | |||||
SizedBox( | |||||
width: 16, | |||||
), | |||||
Container( | |||||
color: Colors.white, | |||||
height: 40, | |||||
width: 80, | |||||
) | |||||
], | |||||
), | |||||
Expanded( | |||||
child: ListView.builder( | |||||
itemCount: 3, | |||||
itemBuilder: _buildItem, | |||||
)) | |||||
], | |||||
)), | |||||
); | |||||
} | |||||
Widget _buildItem(BuildContext context, int index) { | |||||
return Container( | |||||
margin: EdgeInsets.all(16), | |||||
child: Column( | |||||
children: <Widget>[ | |||||
Row( | |||||
children: <Widget>[ | |||||
Container( | |||||
color: Colors.white, | |||||
height: 20, | |||||
width: 40, | |||||
), | |||||
SizedBox( | |||||
width: 16, | |||||
), | |||||
Container( | |||||
color: Colors.white, | |||||
height: 20, | |||||
width: 100, | |||||
) | |||||
], | |||||
), | |||||
SizedBox( | |||||
height: 8, | |||||
), | |||||
Row( | |||||
children: <Widget>[ | |||||
Container( | |||||
color: Colors.white, | |||||
height: 20, | |||||
width: 40, | |||||
), | |||||
SizedBox( | |||||
width: 16, | |||||
), | |||||
Container( | |||||
color: Colors.white, | |||||
height: 20, | |||||
width: 120, | |||||
), | |||||
SizedBox( | |||||
width: 16, | |||||
), | |||||
Container( | |||||
color: Colors.white, | |||||
height: 20, | |||||
width: 40, | |||||
) | |||||
], | |||||
), | |||||
SizedBox( | |||||
height: 8, | |||||
), | |||||
Row( | |||||
children: <Widget>[ | |||||
Container( | |||||
color: Colors.white, | |||||
height: 20, | |||||
width: 40, | |||||
), | |||||
SizedBox( | |||||
width: 16, | |||||
), | |||||
Container( | |||||
color: Colors.white, | |||||
height: 20, | |||||
width: 100, | |||||
), | |||||
SizedBox( | |||||
width: 16, | |||||
), | |||||
Container( | |||||
color: Colors.white, | |||||
height: 20, | |||||
width: 40, | |||||
), | |||||
SizedBox( | |||||
width: 16, | |||||
), | |||||
Container( | |||||
color: Colors.white, | |||||
height: 20, | |||||
width: 100, | |||||
), | |||||
], | |||||
), | |||||
SizedBox( | |||||
height: 8, | |||||
), | |||||
Row( | |||||
children: <Widget>[ | |||||
Container( | |||||
color: Colors.white, | |||||
height: 20, | |||||
width: 40, | |||||
), | |||||
SizedBox( | |||||
width: 16, | |||||
), | |||||
Container( | |||||
color: Colors.white, | |||||
height: 20, | |||||
width: 100, | |||||
), | |||||
SizedBox( | |||||
width: 16, | |||||
), | |||||
Container( | |||||
color: Colors.white, | |||||
height: 20, | |||||
width: 40, | |||||
), | |||||
SizedBox( | |||||
width: 16, | |||||
), | |||||
Container( | |||||
color: Colors.white, | |||||
height: 20, | |||||
width: 100, | |||||
), | |||||
], | |||||
) | |||||
], | |||||
), | |||||
); | |||||
} | |||||
} |