inner method

Rect inner(
  1. Rect area
)

Implementation

Rect inner(Rect area) {
  final hasT = sides.hasTop ? 1 : 0;
  final hasB = sides.hasBottom ? 1 : 0;
  final hasL = sides.hasLeft ? 1 : 0;
  final hasR = sides.hasRight ? 1 : 0;
  return area.inset(top: hasT, bottom: hasB, left: hasL, right: hasR);
}