diff --git a/packages/main/src/Select.ts b/packages/main/src/Select.ts index fe7d4616cf22..fef1f5bb15e7 100644 --- a/packages/main/src/Select.ts +++ b/packages/main/src/Select.ts @@ -1050,6 +1050,14 @@ class Select extends UI5Element implements IFormInputElement { && this.responsivePopover.open) ? -1 : 0; } + get activeDescendant() { + return this._isPickerOpen ? this.activeDescendantId : ""; + } + + get activeDescendantId() { + return `${this.id}-activeDescendant`; + } + /** * This method is relevant for sap_horizon theme only */ diff --git a/packages/main/src/SelectTemplate.tsx b/packages/main/src/SelectTemplate.tsx index c0ed1fb24c7c..035327905395 100644 --- a/packages/main/src/SelectTemplate.tsx +++ b/packages/main/src/SelectTemplate.tsx @@ -43,10 +43,11 @@ export default function SelectTemplate(this: Select) { onFocusIn={this._onfocusin} onFocusOut={this._onfocusout} aria-controls={this.responsivePopoverId} + aria-activedescendant={this.activeDescendant} > {this.hasCustomLabel ? - : this.text + : {this.text} }