crossAxisConstraints method

BoxConstraints crossAxisConstraints(
  1. Axis axis
)

Returns box constraints with the same cross axis constraints but with an unconstrained main axis.

Implementation

BoxConstraints crossAxisConstraints(Axis axis) {
  return axis == Axis.vertical ? widthConstraints() : heightConstraints();
}