bug(mat-selection-list): Color attribute on (mat-list-option/mat-icon - matListItemIcon) is ignored on hover.
- 主要言語
- TypeScript
- スター
- 25k
- フォーク
- 6.8k
- 平均マージ
- 1日 8時間
- マージ済み PR(30日)
- 91
説明
### Is this a regression?
- [ ] Yes, this behavior used to work in the previous version
### The previous version in which this bug was not present was
_No response_
### Description
A mat-icon, located inside a mat-list-option, that has the matListItemIcon directive and has color="accent" (or other theming), loses its color when hovered.
Example:
```
play_arrow
{{pr.user.login}}
{{pr.title}}
```
### Reproduction
Steps to reproduce:
1. Add `color="accent"` to a mat-selection-list > mat-list-option > mat-icon (matListItemIcon)
2. Hover the icon.
3. Accent color goes away and is replaced by a default color.
### Expected Behavior
I would expect the accent color on mat-icon to stay when it is hovered. If the issue here is that for accessibility, hovered items need to visually identify, the background of the mat-list-option itself is already doing that.
### Actual Behavior
Theme colors are lost when the mat-list-option is hovered
### Environment
- Angular: 15
- CDK/Material: 15
- Browser(s): Chrome
- Operating System (e.g. Windows, macOS, Ubuntu): Windows
コントリビューションガイド
調査の方向性
Angular Material の mat-selection-list と mat-list-option の実装およびホバー時のスタイルから始め、Angular/Material 15 で提供されている mat-icon matListItemIcon の例を使って問題を再現します。どのホバールールがアイコンの color 属性を上書きしているかを追跡し、関連するコンポーネントテストが存在する場合は追加または更新します。ホバー中もアクセントカラーが表示されたままになれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- angular, typescript
- 領域
- frontend
- issue の種類
- バグ
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 35/100