angular / angular/components

bug(theming): There is no way to read density scale from theme

オープン
#30,236 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
area: theming P3
主要言語
TypeScript
スター
25k
フォーク
6.8k
平均マージ
1日 8時間
マージ済み PR(30日)
91

説明

### Is this a regression?

- [x] Yes, this behavior used to work in the previous version

### The previous version in which this bug was not present was

18

### Description

In Angular Material 18, developers could use Angular Material's theme's density scale, so that their custom components aligns with other Angular Material components.

In v18, developers could use `mat.get-theme-density($theme);` to get the scale. [Link to docs](https://v18.material.angular.io/guide/theming-your-components#reading-the-density-scale).

In v19, it's not clear how to get density scale from theme.

### Reproduction

Not needed.

### Expected Behavior

Developers should be able to read density scale in Angular Material 19.

### Actual Behavior

Developers are not able to read density scale in Angular Material 19.

### Environment

- Angular: 19
- CDK/Material: 19
- Browser(s): Edge
- Operating System (e.g. Windows, macOS, Ubuntu): Windows

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

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

調査の方向性

まず、Angular Material v18 のテーマ設定ガイドにある「reading the density scale」のエントリポイントと、v19 のテーマ設定 API を比較します。v19 のテーマで密度スケールがどのように表現されているかを確認し、カスタムコンポーネントからそれを読み取るための同等の方法を公開します。Angular Material 19 で開発者がテーマの密度スケールを取得できれば完了です。

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

評価

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

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

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