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.5k stars 260 forks source link

[Feature Request][SF][1.28.4][List][A11y][Expected Fixed Time: ASAP] Cannot change the title heading level #9652

Closed wilson-xu-sap closed 1 month ago

wilson-xu-sap commented 1 month ago

Feature Request Description

Cannot change title heading level when use titleText, which violates the a11y standard.

Proposed Solution

Add a new prop for setting and calculating the heading level.

Proposed Alternatives

No response

Organization

SF

Additional Context

No response

Priority

Medium

Privacy Policy

ilhan007 commented 1 month ago

@wilson-xu-sap which component, is the List?

ilhan007 commented 1 month ago

@wilson-xu-sap can you give us more information about the urgency matter described as "Expected Fixed Time: ASAP". I hope it is not like application is breaking and not working

wilson-xu-sap commented 1 month ago

@wilson-xu-sap which component, is the List?

  • The List has headerText property, not titleText?
  • Do I get the request correctly that you need a new property in the List to define the heading level?

Correct. Your understanding is perfect. No heading level can violate a11y standard.

wilson-xu-sap commented 1 month ago

@wilson-xu-sap can you give us more information about the urgency matter described as "Expected Fixed Time: ASAP". I hope it is not like application is breaking and not working

I have received a ticket about this. This will not break the application but the ticket may be hung up for long.

ilhan007 commented 1 month ago

Hi @wilson-xu-sap for this use-case we provide header slot, in the header slot you can pass your own custom markup as in this example

The first list uses the header slot, the second list - the headerText. The header slot solution requires some minimal styling as well. But as you can see you can define your heading level there. In the example I am using the ui5-title web component with some level that can be changed to your needs. Would that resolve the issue?

wilson-xu-sap commented 1 month ago

Ah, really really sorry. I have raised the PR in the wrong repo. I have re-raised an issue in ui5-webcomponent-react. Thanks for your patience and solution. Your answer will be great help for them!

Lukas742 commented 1 month ago

Hi @wilson-xu-sap

this was actually the correct repo as the List component is a ui5-webcomponent. We've added a note in our documentation for each component that we're just wrapping, so it's easier for developers to identify which component is a ui5-webcomponent:

Note: This is a UI5 Web Component! Repository | Documentation

I'm going to reopen this issue now and close the one you opened in our repo.

wilson-xu-sap commented 1 month ago

OK. It seems that I have to create a customized header for headerText. Thanks.