visibility property
HidableVisibility?
visibility
final
This parameter allows you to define a custom visibility behavior for the child widget
based on scrolling actions. You can provide a function of type HidableVisibility
to determine when and how the widget should be hidden or revealed during scrolling.
Example usage:
Hidable(
child: MyWidget(),
controller: scrollController,
visibility: (position, currentVisibility) {
// Custom visibility logic here.
// Return the updated visibility value.
},
)
If not provided, the default visibility behavior will be used.
Implementation
final HidableVisibility? visibility;