Shimmer.listTile constructor
Shimmer.listTile({})
A shimmer effect widget.
Inspired by: https://github.com/hnvn/flutter_shimmer/blob/master/lib/shimmer.dart
Implementation
Shimmer.listTile({
super.key,
Color backgroundColor = _defaultBackgroundColor,
double borderRadius = _defaultBorderRadius,
Gradient? gradient,
this.period = _defaultPeriod,
}) : gradient = gradient ?? _getDefaultGradient(backgroundColor),
child = ListTile(
contentPadding: EdgeInsets.zero,
leading: CircleAvatar(
backgroundColor: backgroundColor,
),
title: _Container(
borderRadius: borderRadius,
color: backgroundColor,
),
subtitle: Column(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisSize: MainAxisSize.min,
children: <Widget>[
_Container(
borderRadius: borderRadius,
color: backgroundColor,
width: 50.0,
),
],
),
);