gradient property

GradientGetterCallback? gradient
final

Get the gradient of the shimmer effect if gradient is null the it will use this its important to use transform passed in the callback

LinearGradient(
  colors: [
    Theme.of(context).cardColor,
    Theme.of(context).backgroundColor,
    Theme.of(context).cardColor,
  ],
  stops: const [0.1, 0.3, 0.4],
  begin: const Alignment(-1.0, -0.3),
  end: const Alignment(1.0, 0.3),
  tileMode: TileMode.clamp,
  transform: transform,
)

Implementation

final GradientGetterCallback? gradient;