ShapeSized constructor
ShapeSized({})
Implementation
ShapeSized({
required this.child,
this.extent,
this.flex = 1,
this.visibleWhen,
this.textHeightSlot,
this.contentHeightSlot,
}) {
if (extent != null && (!extent!.isFinite || extent! <= 0) ||
!flex.isFinite ||
flex <= 0 ||
(visibleWhen?.key.trim().isEmpty ?? false) ||
(textHeightSlot?.trim().isEmpty ?? false) ||
(textHeightSlot != null && extent != null) ||
(contentHeightSlot?.trim().isEmpty ?? false) ||
(contentHeightSlot != null &&
(extent != null || textHeightSlot != null))) {
throw ArgumentError('Extent and flex must be finite and positive');
}
}