jquery / jquery/jquery-ui

firefox and chrome checking onfocusin support not working anymore on recent versions

Open
#2,125 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Needs info
Dominant language
JavaScript
Stars
11.3k
Forks
5.2k
PR merge metrics
No merged PRs in 30d

Description

firefox 106.0.2 (64-bit)
chrome 107.0.5304.63 (64-Bit)

line 8615 in jquery 3.5.1 (8647 in jquery 3.6.1)
support.focusin = "onfocusin" in window; // this line is getting filled by false, therefore a fix would be applied starting at line 8813 in jquery 3.5.1 (8843 in jquery 3.6.1)

commenting out block: "if ( !support.focusin ) {" fixes issue at those browsers

i stumbled over this bug when suddenly all my jquery-ui dialogs with modal: true would not work anymore and threw error:
Uncaught TypeError: doc.addEventListener is not a function

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the jquery-ui modal dialog failure in the reported Firefox and Chrome versions, then inspect the jquery 3.5.1 and 3.6.1 lines where support.focusin is detected and where the fallback begins. Done means modal dialogs with modal: true work in those browsers without the reported doc.addEventListener error.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, jquery
Domain
frontend, web-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.