Skip to content
This repository was archived by the owner on Sep 5, 2024. It is now read-only.
This repository was archived by the owner on Sep 5, 2024. It is now read-only.

select: md-focused not removed from options on panel close #11927

@ccn974

Description

@ccn974

Bug, enhancement request, or proposal

"md-focused" class is not cleanup after select close. So when reopen select all previously selected options are highlighted

Demo and steps to reproduce the issue

This blank StackBlitz demo can be used to create a reproduction that demonstrates your issue.

Demo URL (required)*: https://material.angularjs.org/latest/demo/select

Detailed Reproduction Steps

  1. Open "State" select ("Basic usage" section) : "None" (first) option is highlighted(md-selected class)
  2. Select "AL" option
  3. Reopen "State" select : "None" and "AL" options are highlighted (md-selected class)
  4. Select "AZ" option
  5. Reopen "State" select : "None", "AL", "AZ" options are highlighted (md-selected class)

Explain the expected behavior

Only last selected option (first option if none) is highlighted

Explain the current behavior

All previously selected options are highlighted

Discuss the use-case or motivation for changing the existing behavior

List the affected versions of AngularJS, Material, OS, and browsers

  • AngularJS: 1.7.9
  • AngularJS Material: 1.1.22
  • OS: All
  • Browsers: All

Add anything else we should know

Commit 928c71d : fix(select): overhaul screen reader support

Stack Trace


Screenshots

image

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions