Open wyxcoder opened 1 year ago
@wyxcoder
class Tile extends StatelessWidget {
const Tile({
Key? key,
required this.index,
this.extent,
this.backgroundColor,
this.bottomSpace,
}) : super(key: key);
final int index;
final double? extent;
final double? bottomSpace;
final Color? backgroundColor;
@override
Widget build(BuildContext context) {
final child = Container(
color: backgroundColor,
height: extent,
child: Center(
child: CircleAvatar(
minRadius: 20,
maxRadius: 20,
backgroundColor: Colors.white,
foregroundColor: Colors.black,
child: Text('$index', style: const TextStyle(fontSize: 20)),
),
),
);
if (bottomSpace == null) {
return child;
}
return Column(
children: [
Expanded(child: child),
Container(
height: bottomSpace,
color: Colors.green,
)
],
);
}
}
I cannot locate the widget Title?