bug(button): overriding not working as expected.
- Lingua principale
- TypeScript
- Stelle
- 25k
- Fork
- 6.8k
- Merge medio
- 1g 8h
- PR unite (30g)
- 91
Descrizione
### 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
To override the background color for a button to a particular hex value provided, the state layer needs to be given an opacity of value 1. However, in doing so, the outline is no longer clearly visible. It appears to get hidden behind the state layer/ ::before pseudo element created.
### Reproduction
StackBlitz link: https://stackblitz.com/edit/wwtmsk43?file=src%2Fexample%2Fbutton-overview-example.css
Hover over the outline button to notice the outline no longer being visible.
### Expected Behavior
When opacity for the state layer is set to 1, the state layer for an outlined button should not hide the outline for the button. The outline should still be visible.
### Actual Behavior
The background's stacking context is higher than the button's stacking context which is hiding the border/ outline.
### Environment
- Angular: 20
- CDK/Material: 20
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Inizia dalla riproduzione StackBlitz collegata e dal relativo src/example/button-overview-example.css, quindi esamina il comportamento di stacking di state-layer e ::before del pulsante. Il lavoro è completato quando, passando il cursore su un pulsante outlined con opacità di state-layer pari a 1, il suo contorno rimane chiaramente visibile e l’override dello sfondo esadecimale fornito continua a funzionare.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- angular, css, typescript
- Ambito
- design, frontend
- Tipo di issue
- Bug
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 45/100