Created
January 18, 2021 20:20
-
-
Save encikpulasan/c856571e25a54e4225018f4a23ffef90 to your computer and use it in GitHub Desktop.
expanded card
This file contains hidden or 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
AnimatedPadding( | |
duration: Duration(milliseconds: 300), | |
padding: EdgeInsets.only(top: 80), | |
child: GestureDetector( | |
onTap: this.onTap, | |
child: Padding( | |
padding: EdgeInsets.symmetric(horizontal: 16.0), | |
child: Container( | |
width: double.infinity, | |
height: double.infinity, | |
decoration: BoxDecoration( | |
color: this.bgColor, | |
borderRadius: BorderRadius.vertical(top: Radius.circular(12)), | |
), | |
child: Column( | |
children: [ | |
Container( | |
height: 50, | |
child: Stack( | |
children: [ | |
Container( | |
width: MediaQuery.of(context).size.width * this.progress, | |
color: Color(0xffFAFAFA).withAlpha(102), | |
), | |
ListTile( | |
contentPadding: EdgeInsets.symmetric(horizontal: 16.0), | |
leading: Icon(OutlineIcons.down), | |
title: Transform( | |
transform: Matrix4.translationValues(-16, 0.0, 0.0), | |
child: ScaledText( | |
this.title, | |
style: Theme.of(context).textTheme.bodyText2.copyWith(color: this.color, fontWeight: FontWeight.w600), | |
), | |
), | |
trailing: ScaledText( | |
this.amount, | |
style: Theme.of(context).textTheme.bodyText2.copyWith(color: this.color, fontWeight: FontWeight.w600), | |
), | |
) | |
], | |
), | |
), | |
SizedBox(height: 8), | |
Expanded(flex: 1, child: this.widget ?? Container()), | |
], | |
), | |
), | |
), | |
}, | |
), |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment