ConstrainedBox
Overview
Set minimum and maximum width and height constraints on a child widget. For example, cap the maximum width so a button doesn't stretch endlessly as the screen gets wider.
Properties
| Property | Description | Value | Default |
|---|---|---|---|
constraints | Limits the child widget's size to the minimum and maximum width and height set in this value. | Minimum width, maximum width, minimum height, and maximum height (minWidth, maxWidth, minHeight, maxHeight) | Minimum width and height 0, maximum width and height unlimited (infi) |