payloadEnum function
Wire value for any enumName-based field (e.g. Axis, Clip, FlexFit).
The built-in codecs encode these enums by their Dart Enum.name, so this is
the canonical producer-side counterpart.
Implementation
String payloadEnum(Enum value) => value.name;