Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.7k
[TwigBridge] render errors as part of the label only#29207
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
| {%blockform_errors -%} | ||
| {%-iferrors|length>0 -%} | ||
| {%-ifrender_errors|default(false)anderrors|length>0 -%} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
im not sure i get it.. this makesform_errors practically a no-op by default right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Yes, and that's also why I am not convinced that we should make the change in core. It might break custom form themes. I rather tend to fix the documentation instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
it could work like form_rest is working maybe; only render errors inform_errors if not already rendered
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
either way, 👍 for better docs: customizing form errors inside the label vs. outside the label.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
or maybe make the current feature more explicit:form_label_with_errors? so if you start customizing based on core files you'll understand you need to pick form_label+form_errors vs. form_label_with_errors
nicolas-grekas commentedDec 12, 2018
What's the status here? |
alternative to#29188