Skip to content

Commit 8b21957

Browse files
committed
Exposed spell check configuration from text field
1 parent 4f58141 commit 8b21957

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

lib/src/fields/form_builder_text_field.dart

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -288,6 +288,12 @@ class FormBuilderTextField extends FormBuilderFieldDecoration<String> {
288288
/// {@macro flutter.widgets.editableText.contentInsertionConfiguration}
289289
final ContentInsertionConfiguration? contentInsertionConfiguration;
290290

291+
/// {@macro flutter.widgets.EditableText.spellCheckConfiguration}
292+
///
293+
/// If [SpellCheckConfiguration.misspelledTextStyle] is not specified in this
294+
/// configuration, then [materialMisspelledTextStyle] is used by default.
295+
final SpellCheckConfiguration? spellCheckConfiguration;
296+
291297
/// Creates a Material Design text field input.
292298
FormBuilderTextField({
293299
super.key,
@@ -349,6 +355,7 @@ class FormBuilderTextField extends FormBuilderFieldDecoration<String> {
349355
this.contextMenuBuilder = _defaultContextMenuBuilder,
350356
this.magnifierConfiguration,
351357
this.contentInsertionConfiguration,
358+
this.spellCheckConfiguration,
352359
}) : assert(initialValue == null || controller == null),
353360
assert(minLines == null || minLines > 0),
354361
assert(maxLines == null || maxLines > 0),
@@ -419,6 +426,7 @@ class FormBuilderTextField extends FormBuilderFieldDecoration<String> {
419426
autofillHints: autofillHints,
420427
magnifierConfiguration: magnifierConfiguration,
421428
contentInsertionConfiguration: contentInsertionConfiguration,
429+
spellCheckConfiguration: spellCheckConfiguration,
422430
);
423431
},
424432
);

0 commit comments

Comments
 (0)