Created
April 22, 2020 09:05
-
-
Save nnamdei/5bfcc85c64d47556b252d5c08146b47d to your computer and use it in GitHub Desktop.
custom_tabview_flutter
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
Container( | |
child: Column( | |
mainAxisSize: MainAxisSize.min, | |
crossAxisAlignment: CrossAxisAlignment.start, | |
children: <Widget>[ | |
DefaultTabController( | |
length: 2, | |
initialIndex: 0, | |
child: Expanded( | |
child: Column( | |
children: [ | |
Material( | |
color: Colors.grey, | |
child: TabBar( | |
indicatorColor: | |
Colors.yellow, | |
labelColor: Colors.blue, | |
unselectedLabelColor: | |
Colors.black, | |
tabs: [ | |
Tab( | |
child: Text( | |
'Text', | |
style: TextStyle( | |
fontSize: 14, | |
fontWeight: FontWeight.normal, | |
), | |
)), | |
Tab( | |
child: Text( | |
'Text', | |
style: TextStyle( | |
fontSize: 14, | |
fontWeight: FontWeight.normal, | |
), | |
)) | |
])), | |
Expanded( | |
child: TabBarView( | |
children: [ | |
Container( | |
child: ListView( | |
shrinkWrap: true, | |
scrollDirection: Axis.vertical, | |
children: <Widget>[ | |
], | |
), | |
), | |
Container( | |
child: ListView( | |
shrinkWrap: true, | |
scrollDirection: Axis.vertical, | |
children: <Widget>[ | |
], | |
), | |
), | |
], | |
), | |
) | |
], | |
), | |
)), | |
], | |
), | |
), |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment