Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to display error border without error text? #132

Closed
lee-40square opened this issue Sep 10, 2019 · 3 comments
Closed

How to display error border without error text? #132

lee-40square opened this issue Sep 10, 2019 · 3 comments
Labels
enhancement New feature or request

Comments

@lee-40square
Copy link

lee-40square commented Sep 10, 2019

I'd like to be able to show the error border without showing any error text. When I do something like

 validators: [
    FormBuilderValidators.required(errorText: null),
  ],

the error border no longer works.

@danvick
Copy link
Collaborator

danvick commented Sep 11, 2019

Hi @lee-40square,
I'm afraid that's not how Flutter's FormField works. A null value for errorText essentially means that validation is successful and a String means validation has failed.

I, however, get your point - currently, the feature to hide the validation error is not present. This may be considered in the next major version.

@danvick danvick added the enhancement New feature or request label Sep 11, 2019
@atiqsamtia
Copy link

@lee-40square, for now, you can use an empty string for the errorText

 validators: [
    FormBuilderValidators.required(errorText: ''),
  ],

@danvick
Copy link
Collaborator

danvick commented May 7, 2020

@lee-40square, for now, you can use an empty string for the errorText

 validators: [
    FormBuilderValidators.required(errorText: ''),
  ],

This will have to work for now.

@danvick danvick closed this as completed May 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants