angular / angular/components

bug(badge): Badge doesn't react to the browser font size

オープン
#27,828 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る
Accessibility area: material/badge P3
主要言語
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

When you change the size of the font through the browser settings. The badges remain the same size.

Comparison images:
small
![image](https://github.com/angular/components/assets/3356843/68ca940f-049e-40c7-8a8e-a69e115ba2e1)
large
![image](https://github.com/angular/components/assets/3356843/1381910a-5658-4626-b995-767a6c5f7db1)
chrome option
![image](https://github.com/angular/components/assets/3356843/1b3f7e7d-b571-4fc4-82f2-f028b1858d7d)

### Reproduction

Steps to reproduce:
1. Go in the Chrome options
2. Search for "Font size"
3. Set to "Very small"
4. Go on https://material.angular.io/components/badge/overview
5. Now change to "Very large"
6. Compare again on the doc page

### Expected Behavior

I have a feeling the badges should follow the size of the font.

### Actual Behavior

Badges font remain unchanged between very small or very large font option.

### Environment

- Angular: 16.2.5
- CDK/Material: 16.2.5
- Browser(s): Chrome 116.0.5845.187
- Operating System (e.g. Windows, macOS, Ubuntu): macOS 13.5.2

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

まず、Chrome のフォントサイズ設定を使い、「非常に小さい」と「非常に大きい」を比較して、material.angular.io/components/badge/overview の Material badge overview で問題を再現してください。ブラウザーのフォントサイズを変更したときに badge のフォントとサイズが一貫して変化し、両方の設定で動作を確認できれば完了です。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
angular, typescript
領域
accessibility, frontend
issue の種類
バグ
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
35/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。