getBorder method
Implementation
Border? getBorder(Map? spec) {
if (spec == null || spec.isEmpty) return null;
final type = spec["type"] ?? "all";
final border = getBorderSide(spec)!;
switch (type) {
case "vertical":
return Border.symmetric(vertical: border);
case "horizontal":
return Border.symmetric(horizontal: border);
case "left":
return Border(left: border);
case "top":
return Border(top: border);
case "right":
return Border(right: border);
case "bottom":
return Border(bottom: border);
default:
return Border.fromBorderSide(border);
}
}