getFieldValue method

dynamic getFieldValue(
  1. String id
)

Gets a value from the nested map value map using fieldIdSeparator.

This method is public so that form fields can access it to get their values from the nested structure.

Implementation

dynamic getFieldValue(String id) {
  // If no separator, just use the ID directly
  if (widget.fieldIdSeparator == null) return rawValue[id];
  // Otherwise, use getByPath to navigate the nested structure
  return rawValue.getByPath(id, separator: widget.fieldIdSeparator!);
}