Chrome is trying to validate required fields that are hidden because they are conditional. See http://stackoverflow.com/a/7264966/1177774 for more details. This patch fixes it.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

larowlan’s picture

+1

jsst’s picture

Status: Needs review » Reviewed & tested by the community

I can confirm this patch works as expected.

I don't see how this module is usable with required conditional fields without it.

A required but hidden input field causes this error in chrome: "An invalid form control with name='' is not focusable.".

jsst’s picture

Status: Reviewed & tested by the community » Needs work

RTBC -> needs work: there's an edge-case where all components in the same fieldgroup are erroneously set required. Will provide details later.

jsst’s picture

Status: Needs work » Reviewed & tested by the community
FileSize
2.99 KB

The edge-case I mentioned in my previous comment was a dependent fieldset. All components in a dependent fieldset were marked required in the original patch. I've updated the patch to solve this issue.

jsst’s picture

FileSize
1.28 KB

Added interdiff to show the difference between the original patch and the #4 patch.