angular / angular/components

bug(list): list item with activated state miss background color

未关闭
#26,946 2 条评论 2 个 reaction 已指派 0 人 在 GitHub 查看
area: material/list material spec P3
主要语言
TypeScript
星标
25k
派生
6.8k
平均合并
1 天 8 小时
30 天内合并 PR
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

Hi there,
When using `mat-nav-list` with items that have an activated state, the primary color is applied on the activated item but the background color is missing.

### Reproduction

https://stackblitz.com/edit/angular-aovyvr

### Expected Behavior

Having same behavior than : https://material-components.github.io/material-components-web-catalog/#/component/list

(Scroll to "List with activated item" section and click on any list item)

### Actual Behavior

Only the font color is applied

### Environment

- Angular: 15.2.6
- CDK/Material: 15.2.6
- Browser(s): Chrome 112
- Operating System (e.g. Windows, macOS, Ubuntu): Any

贡献指南

打开贡献指南

调研方向

从链接的 StackBlitz 复现开始,检查 mat-nav-list 的激活状态样式。将其与链接的 Material Components 列表示例进行比较,然后验证激活的项目是否同时显示预期的背景色和主要文本颜色。

由索引模型根据 Issue 内容生成。

评估

技术栈
angular, typescript
领域
frontend
Issue 类型
缺陷
难度
3/5
预计耗时
1-2 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
45/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。