getConstraintsForChild method
The constraints for the child given the incoming constraints.
During layout, the child is given the layout constraints returned by this function. The child is required to pick a size for itself that satisfies these constraints.
Defaults to the given constraints.
Implementation
@override
BoxConstraints getConstraintsForChild(BoxConstraints constraints) {
var width = constraints.maxWidth;
var height = constraints.maxHeight;
// if (slideTransitionFrom == SlideTransitionFrom.center) {
// width = constraints.maxWidth * progress;
// height = constraints.maxHeight * progress;
// }
return BoxConstraints(maxWidth: width, maxHeight: height);
}