angular / angular/components

bug(FabButton): `matFab` shows hover and focus styling with `disabledInteractive`

Abierto
#32,146 0 comentarios 0 reacciones 0 asignados Ver en GitHub
area: material/button P3
Lenguaje dominante
TypeScript
Estrellas
25k
Forks
6.8k
Merge medio
1 d 8 h
PR fusionados (30 d)
91

Descripción

### 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 `matFab` button behaves differently from `matButton` with the `disabledInteractive` property. When hovering or clicking the FAB button, it will animate the box shadow such that it looks interactive even if its not.

https://github.com/user-attachments/assets/e71708ff-e0f7-4ce1-944b-fcfa41a9645b

https://github.com/user-attachments/assets/b268dea9-627b-435f-8898-e427b0b379e7

### Reproduction

StackBlitz link: https://stackblitz.com/edit/rfnrrfrf?file=src%2Fexample%2Fbutton-disabled-interactive-example.css
Steps to reproduce:
1. Create a `matFab` with `disabled` + `disabledInteractive`
2. Hover the button
3. Click the button

### Expected Behavior

1. No hover box-shadow changes
2. No mousedown changes

### Actual Behavior

1. Hover will "raise" the button (increase box-shadow)
2. Clicking the button animates it

### Environment

- Angular: 20.2.9
- CDK/Material: 20.2.2
- Browser(s): Chrome/Edge (probably all)
- Operating System (e.g. Windows, macOS, Ubuntu): Windows

Guía de contribución

Abrir la guía de contribución

Línea de trabajo

Comienza con la reproducción enlazada de StackBlitz, especialmente con src/example/button-disabled-interactive-example.css, y compara matFab con matButton cuando disabledInteractive está establecido. Confirma que hover y mousedown ya no cambian la sombra de caja del FAB deshabilitado y, después, verifica ambos comportamientos en la reproducción.

Escrito por el modelo de indexación a partir del texto del issue.

Evaluación

Stack tecnológico
angular, typescript
Área
frontend
Tipo de issue
Error
Dificultad
3/5
Tiempo estimado
1-2 días
Estado de actividad
Estancado
Claridad
Bastante claro
Aptitud para principiantes
50/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.