fix: #1484 autoValidateMode breaks invalidate method#1506
Merged
deandreamatias merged 6 commits intoflutter-form-builder-ecosystem:mainfrom Apr 20, 2026
Merged
fix: #1484 autoValidateMode breaks invalidate method#1506deandreamatias merged 6 commits intoflutter-form-builder-ecosystem:mainfrom
deandreamatias merged 6 commits intoflutter-form-builder-ecosystem:mainfrom
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1506 +/- ##
==========================================
- Coverage 91.06% 90.85% -0.22%
==========================================
Files 21 21
Lines 851 853 +2
==========================================
Hits 775 775
- Misses 76 78 +2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Collaborator
deandreamatias
left a comment
There was a problem hiding this comment.
On issue related, had this steps to reproduce, but I can't see this flow in your video
tap Signup button once to set autovalidateMode = onUserInteraction. and then fill the form tap signup button again.
Please can create a video following this steps? Thanks!
majumdersubhanu
commented
Apr 14, 2026
38a24f6
into
flutter-form-builder-ecosystem:main
7 of 8 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Connection with issue(s)
Close #1484
Close #1485
Solution description
Fixes an issue where
invalidate()calls were being cleared by framework validation whenautovalidateModewas active. It also introduces support for the new FlutterforceErrorTextproperty across the core library.Key Changes:
FormBuilderFieldStatePersistence Logic:clearCustomErrorinvalidate()fromtruetofalse. This prevents framework-triggered validation calls (which pass no arguments) from clearing manual errors.didChange()to explicitly clear_customErrorText. This ensures that manual errors are removed as soon as the user interacts with the field, maintaining a logical UX.forceErrorTextIntegration:forceErrorTexttoFormBuilderField,FormBuilderFieldDecoration, and core field constructors.FormFieldAPI (introduced in v3.24), allowing for declarative external error management.validate()andinvalidate()to reflect the updated behavior regarding custom error clearing.Code used for the demo
Screenshots or Videos
Screen.Recording.2026-04-15.004656.mp4
To Do