ui5-webcomponents icon indicating copy to clipboard operation
ui5-webcomponents copied to clipboard

[SF][A11y][TimePicker]: Ensures all ARIA attributes have valid values

Open lv-sap opened this issue 3 years ago • 6 comments

Describe the bug

TimePicker causes unit test failure due to A11y (AXE) violations:

  • "ARIA attributes must conform to valid values (aria-valid-attr-value)"

    Fix all of the following: Invalid ARIA attribute value: aria-controls="ui5wc_1-responsive-popover"

    ────────

  • "Form elements must have labels (label)"

    Fix any of the following: aria-label attribute does not exist or is empty aria-labelledby attribute does not exist, references elements that do not exist or references elements that are empty Form element does not have an implicit (wrapped)

    ────────

Screenshot 2023-04-18 at 12 06 31 PM

Isolated Example

No response

Reproduction steps

Prerequisite: To better identify the issues, you need the AXE Dev Tool extension installed in you Chrome browser.

  1. Open https://sap.github.io/ui5-webcomponents-react/?path=/docs/inputs-timepicker--docs
  2. Open the Axe Dev tool extension in Chrome Dev Tools and scan the page
  3. It should show some issues similar (but not exactly the same) to the following: Screenshot 2023-04-18 at 12 06 31 PM

Expected Behaviour

No response

Screenshots or Videos

No response

UI5 Web Components for React Version

^1.10.0

UI5 Web Components Version

^1.11.0

Browser

Chrome, Edge, Firefox, Safari

Operating System

No response

Additional Context

No response

Relevant log output

No response

Declaration

  • [X] I’m not disclosing any internal or sensitive information.

Related Jira ticket: https://jira.successfactors.com/browse/WEF-118178

lv-sap avatar Apr 18 '23 21:04 lv-sap

Thanks for reporting! I'll forward this issue to our UI5 Web Components Colleagues as the affected component is developed in their repository.

MarcusNotheis avatar Apr 19 '23 09:04 MarcusNotheis

Hello @lv-sap ,

  • I don't see this id "ui5wc_1-responsive-popover" on the provided sample. If you mean "ui5wc_9-responsive-popover" we have it set as "ui5wc_9-responsive-popover" and on one more place ad "id". So it looks valid.
  • "Form elements must have labels (label)" - which are those form elements?

Please check again and answer the questions. Thank you in advance!

Best Regards, Lidiya

LidiyaGeorgieva avatar Apr 19 '23 13:04 LidiyaGeorgieva

Hi Lidya,

I'm sorry. There was a wrong statement in the description, and I corrected it. What I meant is that those are the messages raised after running an AXE Dev Tool analyzing on my page, the page I was working on. I also run the AXE Dev Tool analysis for the same component on your WebCopmponent demo page https://sap.github.io/ui5-webcomponents-react/?path=/docs/inputs-timepicker--docs, and indeed, it reported similar issues. The screenshot shows the errors on my page. I don't post screenshots from the demo page, because on the demo page you can run the Axe tool yourself, and see the actual errors.

-- L

lv-sap avatar Apr 19 '23 17:04 lv-sap

Hello @lv-sap ,

Regarding the error: "Form elements must have labels (label)" On the test page you sent, this error is shown for select with id="control-valueState" This field is not part of the UI5 Web Components rather than the test page. I suggest you to check again your application and if needed to add labels.

Hello @SAP/ui5-webcomponents-topic-b ,

Regarding the error: "ARIA attributes must conform to valid values (aria-valid-attr-value)" - I checked the TimPicker test page and if the responsive popover is not opened its id is not in the HTML tree. I think this is the problem, that is reported. Example with id="ui5wc_11-responsive-popover"

image

Please give a statement is this an ACC issue?

Best Regards, Lidiya

LidiyaGeorgieva avatar Apr 20 '23 08:04 LidiyaGeorgieva

@LidiyaGeorgieva ,

Yes. The AXE dev tool reported the same error, "ARIA attributes must conform to valid values (aria-valid-attr-value)", for the TimePicker on both TimPicker test page and on my page.

lv-sap avatar Apr 26 '23 21:04 lv-sap

@lv-sap , Yes, this error can be seen for the TimPicker test page, but it is for the two helper inputs that count the "input" and "change" events on the ui5-time-picker. The error is not for the ui5-time-picker component. image

@unazko please add labels in the test page for the two inputs to avoid confusion in future.

LidiyaGeorgieva avatar Apr 27 '23 04:04 LidiyaGeorgieva