toStackedAvatars method
Stacks widgets with horizontal overlap — like a group of circle avatars.
Implementation
Widget toStackedAvatars({
double overlap = 16.0,
Alignment alignment = Alignment.centerLeft,
double height = 40.0,
}) {
return SizedBox(
height: height,
child: Stack(
alignment: alignment,
children: List.generate(length, (index) {
return Positioned(left: index * overlap, child: this[index]);
}),
),
);
}