Skip to content

Closing dropdown does not set focus back to dropdown trigger element #28914

@patrickhlauke

Description

@patrickhlauke

Discovered while working on #28751

To reproduce:

Expected:

  • dropdown is closed and focus is reset to the dropdown trigger button

Actual:

  • dropdown is closed, but focus is lost (querying document.activeElement shows focus went back to body, and the dropdown trigger doesn't have any visible focus outline/indication)

This is a regression from v4, where this worked correctly (see https://getbootstrap.com/docs/4.3/components/dropdowns/)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions