collapsibleProgressOf static method

double? collapsibleProgressOf(
  1. BuildContext context
)

Returns the current collapsible progress of the surrounding collapsible sheet.

A value of 1.0 means that the sheet is fully collapsed, while a 0.0 means the sheet is fully expanded.

This creates a dependency between the given context and the ancestor sheet. The associated widget will rebuild when the progress changes, such as when the user drags the sheet.

Implementation

static double? collapsibleProgressOf(BuildContext context) {
  return context
      .dependOnInheritedWidgetOfExactType<_InheritedCollapsibleProgress>()
      ?.progress;
}