setAnimatedPanelPosition method

Future<Null> setAnimatedPanelPosition(
  1. double value
)

Set panel position WITH animation.

Returned future is completed when the panel is animated.

Given value is clamped between PanelSize.closedHeight and PanelSize.expandedHeight.

Implementation

Future<Null> setAnimatedPanelPosition(double value) async => controlling
    ? _setPanelPosition(panel!,
        duration:
            _getDuration(from: panel!._metadata.currentHeight, to: value),
        to: value)
    : Future.error('Missing Controller');