Created
June 9, 2021 11:08
-
-
Save luizmarcus/ac57bf8467362ee8b870f0e33947a0e5 to your computer and use it in GitHub Desktop.
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
Widget _getItem(IconData iconData, String name, String tag) => | |
GestureDetector( | |
child: Card( | |
child: Padding( | |
padding: const EdgeInsets.all(10.0), | |
child: Row( | |
children: [ | |
Icon(iconData), | |
Expanded( | |
child: Text( | |
name, | |
textAlign: TextAlign.center, | |
), | |
), | |
], | |
), | |
), | |
), | |
onTap: () => Navigator.push( | |
context, | |
MaterialPageRoute( | |
builder: (_) => SecondPage( | |
iconData: iconData, | |
tag: tag, | |
text: name, | |
), | |
), | |
), | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment