-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Bug in error validation error message #11260
Comments
@Arctomachine thank you for the solid reproduction! I am looking into this now. |
Can't reproduce this on my system / browser combination. What browser are you using when you get this behavior? Screen.Recording.2025-02-20.at.11.58.43.AM.mov |
You reproduced everything right.
|
Wow my brain must not have been turned on - I see the issue now, working on it! Thanks for the patience 😂 |
Here is what I've found:
So the fixable issue here is those parent path labels, it should show labels instead of field names when possible. I have a fix in progress and will get a PR open shortly after adding tests. |
Hiding error message may be good for default validation. But what about custom validation? How can user know what is wrong with data in field? |
@Arctomachine I definitely understand the potential need but as this is intended behavior it won't be fixed as a bug. I'll get a feature request open regarding full error message output on smaller screens - it would be nice to have this available as opt-in behavior or something similar. |
Describe the Bug
Two issues:
Link to the code that reproduces this issue
https://github.com/Arctomachine/payload-nested-field-validation-message-bug.git
Reproduction Steps
For provided reproduction:
Observe toast message giving field names instead of labels.
Make screen wider and see error message for field working as expected.
Which area(s) are affected? (Select all that apply)
area: ui
Environment Info
The text was updated successfully, but these errors were encountered: