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

fix multi select error never shown #166

Closed
wants to merge 2 commits into from

Conversation

linchen2chris
Copy link

if a field is array of string/number, when submit formik will set its isTouched
to [], then formik-antd will set it to 'false' and its error will never shown.

@linchen2chris
Copy link
Author

hi @jannikbuschke , I fixed a small issue for multi select error not shown when submit, hope for your approval

@linchen2chris linchen2chris marked this pull request as draft November 19, 2020 02:23
@linchen2chris linchen2chris marked this pull request as ready for review November 19, 2020 02:23
@linchen2chris linchen2chris marked this pull request as draft November 19, 2020 02:23
@linchen2chris linchen2chris marked this pull request as ready for review November 19, 2020 02:27
@wbarcovsky
Copy link

Hi @jannikbuschke
Faced similar issue recently. Any updates about this pull request?
Happy to provide any help, if necessary

}
const hasError = error !== undefined && isTouched
const hasInitialError = initialError !== undefined
const isValid = !error && isTouched
const showHelp =
hasError ||
(hasInitialError && (!isTouched || showInitialErrorAfterTouched))
console.log('Line 36', showHelp, error, isTouched)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@linchen2chris Seems like debug code, that should be removed

@Maclay74
Copy link

@linchen2chris please update your merge request, this bug is annoying, let's get rid of this.

@jannikbuschke
Copy link
Owner

Ill try to close this this weekend

@jannikbuschke
Copy link
Owner

@allcontributors add linchen2chris for code

@allcontributors
Copy link
Contributor

@jannikbuschke

I've put up a pull request to add @linchen2chris! 🎉

@jannikbuschke
Copy link
Owner

I used the code here in commit 11269b2
Should be fixed in v2.0.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants