computeSizeFromChild method
Expands the child size by adding the padding.
Implementation
@override
Size computeSizeFromChild(BoxConstraints constraints, Size childSize) {
return Size(
childSize.width + padding.horizontal,
childSize.height + padding.vertical,
);
}