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

feat(ui5-time-picker): add required, accessibleName & accessibleNameRef

Open didip1000 opened this issue 1 month ago • 0 comments

With this change, users can now set required, accessible-name and accessible-name-ref properties for ui5-time-picker.

Required

This property defines if time pickers are required in forms. Time picker can be used in a form as follows:

<form>
    <ui5-time-picker required></ui5-time-picker>
    <ui5-button type="Submit">Submit</ui5-button>
</form>

Accessible Name

This property defines the aria-label for the time picker. In the following example, a screen reader will read out "Pick a time" when focused on the picker input:

<ui5-time-picker accessible-name="Pick a time"></ui5-time-picker>

Accessible Name Ref

Reference to other components that define the aria-label for the time picker. In the following example, a screen reader will read out "Pick a time" when focused on the picker input:

<ui5-label id="label">Pick a time</ui5-label>
<ui5-time-picker accessible-name-ref="label"></ui5-time-picker>

Closes: #5895

didip1000 avatar Jul 01 '24 14:07 didip1000