bug(mat-button): mat-button should be changed to disabled appearance when the parent `<fieldset>` is disabled
- Vorherrschende Sprache
- TypeScript
- Sterne
- 25k
- Forks
- 6.8k
- Ø Merge
- 1 T. 8 Std.
- Gemergte PRs (30 T.)
- 91
Beschreibung
### 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
The same issue #3033 was closed by angular/angular#35309. But it only fixes form controls not buttons.
The CSS selector for disabled appearance only selects `[disabled]` but it should also select `:disabled` to make the parent `` work.
### Reproduction
StackBlitz link: https://stackblitz.com/edit/components-issue-starter-ck6fmjkd
Steps to reproduce:
1. Put both `mat-button` and **disabled**-`mat-button` in ``.
### Expected Behavior
Both `mat-button` should show the same appearance.
### Actual Behavior
They are different.
### Environment
- Angular: 20.0.6
- CDK/Material: 20.0.5
- Browser(s): Google Chrome
- Operating System (e.g. Windows, macOS, Ubuntu): Windows
Beitragsleitfaden
Rechercherichtung
Beginne mit den mat-button-Stilen für das deaktivierte Erscheinungsbild und dem CSS-Selektor, der derzeit nur [disabled] prüft. Reproduziere das Problem mit dem verknüpften StackBlitz und Buttons innerhalb von ; fertig ist es, wenn beide Buttons dasselbe deaktivierte Erscheinungsbild haben, einschließlich des Falls mit dem explizit deaktivierten Button.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- angular, css
- Bereich
- frontend
- Issue-Typ
- Bug
- Schwierigkeit
- 2/5
- Geschätzter Aufwand
- 1-3 Stunden
- Aktivitätsstatus
- Veraltet
- Klarheit
- Klar beschrieben
- Anfängerfreundlichkeit
- 55/100