SAP / ui5-webcomponents

UI5 Web Components - the enterprise-flavored sugar on top of native APIs! Build SAP Fiori user interfaces with the technology of your choice.
https://sap.github.io/ui5-webcomponents/
Apache License 2.0
1.47k stars 254 forks source link

[UI5 Web Components 2.0] General guidance for API revision from accessibility perspective #8353

Open nikolay-kolarov opened 4 months ago

nikolay-kolarov commented 4 months ago

Motivation and Goal

The goal is to create a central general guidance for the accessibility API in order to achieve consistency across the components and clean-up differences

Expected Output

  1. Make the analysis and create documentation with general guidance and recommendation how the accessibility related API needs to be implemented (which can be used also for future reference).
  2. Prepare and create the follow-up issues for team execution in order to have clarity and clear guidance.

Initial analysis

General topics

  1. title – must be renamed to tooltip and made public, where relevant
  2. ariaHasPopup & ariaHaspopup – we have inconsistencies in the naming that needs to be solved. Can be moved to accessibleAttributes.
  3. accessibleName, accessibleNameRef, accessibleAttributes & accessibleRoleDescription - inconsistencies in default values and types needs to be solved

Component specific info

  1. Avatar & AvatarGroup - ariaHasPopup (protected) - see ariaHaspopup section above
  2. Icon - ariaHidden (private) – remove the property, add an internal method (to be used by our components) to apply the aria-hidden attribute in the shadow dom only
  3. Label - for – we need to rename it, as this an attribute relevant for the native HTML element label
  4. Link - title – see title section above
  5. ListItem title – see title section above role & accessibleRole – only accessibleRole should remain. Maybe think of a enum as a type ariaHasPopup – see ariaHaspopup section above
  6. SideNavigationItemBase title – see title section above
ilhan007 commented 4 months ago

Related to: https://github.com/SAP/ui5-webcomponents/issues/4460

hristop commented 4 months ago

Internal BLI created: BGSOFUIRILA-3820