Name form field always mandatory (and a11y with labels)

  • Pablo
  • Pablo's Avatar Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
2 years 6 months ago #1 by Pablo
Hi!

In subscription module options, when you choose Name as Optional, it continues being mandatory. If you don't fill it, you obtain the message "Please fill-in all required details and try again".

Accessibility suggestion: Form fields need labels. It's not enough with placeholders.

A reference: https://www.a11yproject.com/posts/how-to-write-accessible-forms/

Thank you for your great work!

Regards

Please Log in or Create an account to join the conversation.

  • Christopher Mavros
  • Christopher Mavros's Avatar
  • Offline
  • Administrator
  • Administrator
More
2 years 6 months ago #2 by Christopher Mavros
Replied by Christopher Mavros on topic Name form field always mandatory (and a11y with labels)
Hi Pablo and thank you for posting!

You are correct.
I have fixed the name issue and I have added some hidden labels for accessibility.
These will be included in the next release.

Let me know if you need them earlier.
Thanks again.

Christopher Mavros
me@mavxr.com
If you like our extensions, please rate us on the JED!

Please Log in or Create an account to join the conversation.

  • Pablo
  • Pablo's Avatar Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
2 years 6 months ago #3 by Pablo
Great news, Chistopher!

One question, why hidden labels?

They can be visible. Or have an option to show/hide them.

Please Log in or Create an account to join the conversation.

  • Christopher Mavros
  • Christopher Mavros's Avatar
  • Offline
  • Administrator
  • Administrator
More
2 years 6 months ago #4 by Christopher Mavros
Replied by Christopher Mavros on topic Name form field always mandatory (and a11y with labels)
Adding an option is a possibility.
I made them hidden because updates must not affect the way existing installations look.
If I push an update with visible labels, they will change all existing NS Pro forms.
For the moment, you can use the following CSS to make them visible:
Code:
.nspro_a11y_label { display: block !important; }

Christopher Mavros
me@mavxr.com
If you like our extensions, please rate us on the JED!

Please Log in or Create an account to join the conversation.

  • Pablo
  • Pablo's Avatar Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
2 years 6 months ago #5 by Pablo
Ok, perfect, thank you very much!

Please Log in or Create an account to join the conversation.

  • Christopher Mavros
  • Christopher Mavros's Avatar
  • Offline
  • Administrator
  • Administrator
More
2 years 6 months ago #6 by Christopher Mavros
Replied by Christopher Mavros on topic Name form field always mandatory (and a11y with labels)
You are welcome!

Christopher Mavros
me@mavxr.com
If you like our extensions, please rate us on the JED!

Please Log in or Create an account to join the conversation.

Moderators: Christopher Mavros