constrained method
Implementation
Widget constrained({double? height, double? width}) {
if (width != null && height != null) {
return ConstrainedBox(
constraints: BoxConstraints(
maxHeight: height,
maxWidth: width,
),
child: this,
);
} else {
return this;
}
}