Closed
Description
Reproduction
https://stackblitz.com/edit/angular-e7d8vq
(or use my fork of the reproduction from #19133, with an *ngIf condition wrapped around the component)
I found #19133, which looks like it was fixed in 9.2.4. But I'm still seeing the issue when the components are inside an element with *ngIf.
Steps to reproduce:
- Create a component that uses ShadowDom
- Create some mat-buttons, inside an element with *ngIf
- Click one, and press tab
- The next button doesn't receive the tab focus style
Expected Behavior
Buttons and other elements should use tab focus style (background color).
Actual Behavior
Focus styles not applied. Removing the *ngIf condition around the buttons makes it work.
Environment
- Angular: 9.2.4
- CDK/Material: 9.2.4
- Browser(s): Chrome latest
- Operating System (e.g. Windows, macOS, Ubuntu): MacOS