I'm trying to create this layout for an app, I've used an expansion tile inside a Card and a listView below , but when I open expansionTile, hitting the bottom of the screen would this and if the listView has many tiles happens this , I can not solve this problem in any way.
Here is my code below:
class HomeState extends State<Teste>{
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text (""),
),
body: Container(
padding: EdgeInsets.all(15.0),
child: Column(
children: <Widget>[
CardList(),
MyList()
],
),
),
);
}
}
Widget CardList(){
return new Flexible(
child: Card(
elevation: 5,
color: Color.fromARGB(255, 0xC8, 0xF4, 0xF2),
child: ExpansionTile(
title: Text("Periodo",
style: new TextStyle(
),textAlign: TextAlign.center,
),
children: <Widget>[
ListaPeriodos(10)
],
),
)
);
}
Widget MyList(){
return new ListView.builder(
padding: EdgeInsets.all(10.0),
shrinkWrap: true,
itemBuilder: (BuildContext context, int index) {
return new ListTile(
title: new Text(
"Texto",
textAlign: TextAlign.center,
style: new TextStyle(
fontWeight: FontWeight.normal,
color: Colors.black45
),
),
);
},
itemCount: 15,
);
}