parseImageSize function

BoxFit? parseImageSize(
  1. String? position
)

Implementation

BoxFit? parseImageSize(String? position) {
  if (position == null) return null;

  switch (position) {
    case "cover":
      return BoxFit.cover;
    case "fill":
      return BoxFit.fill;
    case "contain":
      return BoxFit.contain;
    case "cover":
      return BoxFit.cover;
    case "none":
      return BoxFit.none;
    default:
      return BoxFit.fill;
  }
}