angular / angular/components

feat(MatTooltip): Mimic native tooltip behaviour

Abierto
#20,091 5 comentarios 0 reacciones 0 asignados Ver en GitHub
area: material/tooltip feature P4
Lenguaje dominante
TypeScript
Estrellas
25k
Forks
6.8k
Merge medio
1 d 8 h
PR fusionados (30 d)
91

Descripción

#### Feature Description

##### If nested elements have `MatTooltip`s applied on them, show the innermost tooltip.

Suppose we have a `button` with a `span` inside it.

```html

Mat Tooltip

Native Tooltip

```

If both of these elements have the `title` attribute applied to them and we hover the `span`, the browser shows `title` text of the span.
However, if we use the `MatTooltip` directive, both tooltips are shown to the user.

[Minimal Reproduction on StackBlitz](https://mat-tooltip-vs-native-tooltip.stackblitz.io)

#### Use Case

Whenever you need to show different tooltips for parent and child elements.

Guía de contribución

Abrir la guía de contribución

Línea de trabajo

Comienza con la reproducción vinculada de StackBlitz e inspecciona el comportamiento de MatTooltip para elementos anidados. Se considera completado cuando al pasar el cursor sobre el span anidado se muestra únicamente su tooltip, mientras que el tooltip del botón principal sigue apareciendo al pasar el cursor sobre el propio botó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
Nueva funcionalidad
Dificultad
3/5
Tiempo estimado
1-2 días
Estado de actividad
Estancado
Claridad
Bastante claro
Aptitud para principiantes
45/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.