Skip to content

Commit 834ca67

Browse files
committed
Read an unknown textCapitalization as none
The Meridian branch's enum read unknown values as none; master's field only had a default, so a stray value failed the whole text field. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019VxYXXsxhYd3bYhrw4WpZy
1 parent 65fcd2b commit 834ca67

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

‎lib/src/api/nodes/text_field_node.dart‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,10 @@ class TextFieldProperties extends CustomProperties with FieldsHolder {
216216

217217
/// Which letters the on-screen keyboard capitalizes by default: none,
218218
/// the first of each word (names), of each sentence, or every letter.
219-
@JsonKey(defaultValue: TextCapitalizationC.none)
219+
@JsonKey(
220+
defaultValue: TextCapitalizationC.none,
221+
unknownEnumValue: TextCapitalizationC.none,
222+
)
220223
TextCapitalizationC textCapitalization;
221224

222225
/// A ring drawn around the field while it has focus, [focusRingWidth]

‎lib/src/api/nodes/text_field_node.g.dart‎

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)