Skip to content

Support aria-labelledby as a replacement for checkboxes and radio buttons

Warren Gifford requested to merge tr/support-aria-labelled-by into main

Created by: umpox

Description

We enforce that all AccessibleFieldType components are provided with either aria-label (hidden) or label (visible) to make them accessible.

This can be problematic when migrating, as in some cases we need an external label for custom styling reasons. This PR allows support for aria-labelledby as an alternative option to ensure components can still support this.

Test plan

  • Using a screen reader with aria-labelledby examples using both span and a label element
  • Unit tests

App preview:

Merge request reports

Loading