gradient property

Gradient? gradient
final

Customize the visual appearance of this Foil.

If isUnwrapped is true, this Foil's gradient will be deactivated, smoothly transitioning to an invisible state.

It is recommended to use a Gradient that starts and ends with the same Color.

  • LinearSteps or the other Steps gradients could handle this aspect.

This Gradient will intrinsically animate to any changed gradient value by Gradient.lerp over duration and curve.

Using a Roll of Foil

Optionally a Roll may be deployed higher up in the widget tree.

Declare a Roll.gradient to which any descendent Foil may fallback,
though this gradient will override any provided by a Roll.

Pre-rolled Foils

Consider some pre-rolled Foils that come with this package.

The default is Foils.linearLooping if this Foil is not given
a gradient and no ancestral Roll provides one either.

`sitAndSpin`, and `gymClassParachute`
four varieties of linear rainbow gradient `oilslick`
three new gradients called `Steps`
`Foils.rainbow`

Implementation

final Gradient? gradient;