parseWrapCrossAlignment function

WrapCrossAlignment? parseWrapCrossAlignment(
  1. String? alignment, [
  2. WrapCrossAlignment? defValue
])

Implementation

WrapCrossAlignment? parseWrapCrossAlignment(String? alignment,
    [WrapCrossAlignment? defValue]) {
  if (alignment == null) {
    return defValue;
  }
  return WrapCrossAlignment.values.firstWhereOrNull(
          (e) => e.name.toLowerCase() == alignment.toLowerCase()) ??
      defValue;
}