Skip to content

[Bug]: Cookie consent bar doesn't capture user focus when appear. #785

@HannaHabr

Description

@HannaHabr

Expected Behavior

Cookie consent bar captures focus when appear.

Current Behavior

Cookie consent bar doesn't capture focus when appear.

Steps to reproduce

  1. Ensure consent is not made
  2. Set consent modal settings to
consentModal: {
    layout: 'bar inline',
    position: 'bottom',
    flipButtons: true
}
  1. Run the consent
  2. Open the page with the consent running (also add some focusable component on it, like button)
  3. Press F button (in Chrome or button which highlights the focus)
  4. Observer that the focus is not inside the consent bar

Proposed fix or additional info.

It worked in V2.9.2

Despite this fact focus capturing works ok in V3.1.0 when the user opens settings modal and close it with a keyboard.

Version

3.1.0

On which browser do you see the issue?

Chrome

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingtriageyet to be reviewed

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions