Skip to content

Focus not trapped in detached mode #588

Open
@stefanprobst

Description

@stefanprobst

Description

when in detached mode (fullscreen or modal), focus should be trapped.

Reproduction

Steps

  1. Go to https://www.algolia.com/doc/ui-libraries/autocomplete/introduction/what-is-autocomplete/
  2. Reduce viewport width to 500px to switch to detached mode.
  3. Click on the first autocomplete.
  4. Press Tab a couple of times (or Shift+Tab)
  5. Some hidden element is focused, and modal can't be closed with Esc anymore

Expected behavior

focus should be trapped.

Environment

  • OS: [e.g. Windows / Linux / macOS / iOS / Android]
  • Browser: [e.g. Chrome, Safari] Firefox 88
  • Autocomplete version: [e.g. 1.0.0] 1.0.1

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions