previousFieldName method

String? previousFieldName(
  1. String currentName
)

Get the previous field in definition order.

Implementation

String? previousFieldName(String currentName) {
  final index = _fieldOrder.indexOf(currentName);
  if (index <= 0) return null;
  return _fieldOrder[index - 1];
}