Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
By jrockowitz on
Change record status:
Published (View all published change records)
Project:
Introduced in branch:
8.x-5.x
Introduced in version:
8.x-5.0-rc1
Issue links:
Description:
Summary
Not everyone knows that * mean required. Sometimes it helps to include "* Indicated required fields" at the beginning of a webform. It all depends on the targeted audience.
- Required indicator can be customized via form configuration (/admin/structure/webform/config)
- Required indicator is only displayed if there are required elements.
Screenshots
Configuration
Form
Impacts:
Site builders, administrators, editors
Comments
add required indicator to webforms
This is a great feature. I solved the problem so far with an error message in red.
but I would have a suggestion. could it be placed beside the first required field and not on top. So it would be more consistent, logic. See picture but i can't place it in this case.
Adjust position in settings
Thanks for this feature Jacob! This is something I need pretty much in every form.
Nevertheless, I would also vote for a solution, where it could be moved to another position than before the form. Maybe just by overriding a twig template or even a new settings value.
I imagine this could be very extensive, thinking of the use cases … In my case, I would place it below the form, but before the form-actions.
Maybe you have something in mind.