Skip to content

Tooltip of detached view won't go away #6634

Closed
@HarelM

Description

@HarelM

Bug

When detaching a view using keyboard while hovering to see a tooltip, the tooltip stays while the parent is removed. (I think there was a bug in the past on this but couldn't find it).

What is the expected behavior?

Tooltip won't stay when its parent was removed.

What is the current behavior?

Tooltip stays.

What are the steps to reproduce?

The below plunker should show the issue if you follow these steps:

  1. Click the click me button to create a dynamically attached component.
  2. Hover the new component to get the tooltip.
  3. Click the ESC button to remove the newly added component.
    https://plnkr.co/edit/TTPxE2b7kDV3dNgNsb8V?p=preview

Tooltip stays. I couldn't make it fully work on plunker as I see errors in the console log and I'm not sure what's wrong with my code, but In my site I have the exact same issue without console log errors.

What is the use-case or motivation for changing an existing behavior?

There is no way to make the tooltip go away, a timeout for tooltips would also work in this case but I don't see it in the documentation.

Which versions of Angular, Material, OS, TypeScript, browsers are affected?

Plunker is spawned from the documentation, so which ever version is used there, all browsers.

Is there anything else we should know?

a tooltip close timeout would also be a good addition to the tooltip API.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions