From 1bdcbd38ab96f6a7537c36cb7d61d9e8db2144e7 Mon Sep 17 00:00:00 2001 From: Elizabeth Mitchell Date: Tue, 15 Oct 2024 06:36:52 -0700 Subject: [PATCH] fix(select): missing accessible label PiperOrigin-RevId: 686083729 --- select/internal/select.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/select/internal/select.ts b/select/internal/select.ts index 8beed383a8..bc310793c6 100644 --- a/select/internal/select.ts +++ b/select/internal/select.ts @@ -386,6 +386,7 @@ export abstract class Select extends selectBaseClass { } private renderField() { + const ariaLabel = (this as ARIAMixinStrict).ariaLabel || this.label; return staticHtml` <${this.fieldTag} aria-haspopup="listbox" @@ -393,7 +394,7 @@ export abstract class Select extends selectBaseClass { part="field" id="field" tabindex=${this.disabled ? '-1' : '0'} - aria-label=${(this as ARIAMixinStrict).ariaLabel || nothing} + aria-label=${ariaLabel || nothing} aria-describedby="description" aria-expanded=${this.open ? 'true' : 'false'} aria-controls="listbox"