I tried to make a horizontal list inside content of vertical list but I ended up expanding my height of row, I don't want to use container and height as it can be different result in different phone screen(my assumption). here is what I tried to achieve and here is what I I've done so far
here is my code:
class _TestingScreenState extends State<TestingScreen> {
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text("Testing Screen"),
),
body: Column(
children: [
Expanded(
child: Row(
children: [
CircleAvatar(
radius: 30,
child: Text("HE"),
),
Expanded(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
// ignore: prefer_const_literals_to_create_immutables
children: [
Text(
"Title",
style: TextStyle(fontWeight: FontWeight.bold),
),
Text(
'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.',
// overflow: TextOverflow.ellipsis,
),
Expanded(
child: ListView(
scrollDirection: Axis.horizontal,
children: List.generate(10, (i) {
final hashTag = 'Hello';
return buildHashTag(i, hashTag, context);
})),
)
],
),
),
Container(
width: 30,
color: Colors.amber,
)
],
),
),
],
),
);
}
Padding buildHashTag(int i, String hashTag, BuildContext context) {
return Padding(
padding: EdgeInsets.only(right: 5),
child: Text(
"#Hello",
style: TextStyle(),
),
);
}
}