Skip to content

Bump focus-trap from 7.8.0 to 8.0.0#453

Merged
makermelissa merged 1 commit intomainfrom
dependabot/npm_and_yarn/focus-trap-8.0.0
Feb 3, 2026
Merged

Bump focus-trap from 7.8.0 to 8.0.0#453
makermelissa merged 1 commit intomainfrom
dependabot/npm_and_yarn/focus-trap-8.0.0

Conversation

@dependabot
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Feb 2, 2026

Bumps focus-trap from 7.8.0 to 8.0.0.

Release notes

Sourced from focus-trap's releases.

v8.0.0

Major Changes

  • b6ea4b5: Breaking: Fixed a long-standing bug where onPostActivate() would be called before the initial focus node was focused and the trap was fully activated. (#1747)
    • By default (and for many years now), a trap delays setting focus to the initial focus node to the next frame (setTimeout(0)) but wasn't delaying calling onPostActivate() until after that delay.
    • With the new isolateSubtrees='aria-hidden' option, the currently-focused node's container (a non-subtree being "disabled") would get hidden before the delay was up, resulting in Chrome preventing the effect of aria-hidden on that subtree with a warning in the console due to the container being hidden still containing focus (e.g. the "activate trap" button).
    • With the fix, subtree isolation and the call to onPostActivate() await the initial focus delay (if there is one, which is default behavior; remove it with delayInitialFocus=false) before being applied/called.
    • This may cause tests to fail, requiring the addition of slight delays before testing a given state (e.g. await waitFor(() => expect(initialFocusNode).toBeFocused()).
    • It may also disrupt current assumptions about the state of the initial focus node in code that runs in your onPostActivate() handler (prior to this change, that node would not be focused yet; after this change, it will be focused).
Changelog

Sourced from focus-trap's changelog.

8.0.0

Major Changes

  • b6ea4b5: Breaking: Fixed a long-standing bug where onPostActivate() would be called before the initial focus node was focused and the trap was fully activated. (#1747)
    • By default (and for many years now), a trap delays setting focus to the initial focus node to the next frame (setTimeout(0)) but wasn't delaying calling onPostActivate() until after that delay.
    • With the new isolateSubtrees='aria-hidden' option, the currently-focused node's container (a non-subtree being "disabled") would get hidden before the delay was up, resulting in Chrome preventing the effect of aria-hidden on that subtree with a warning in the console due to the container being hidden still containing focus (e.g. the "activate trap" button).
    • With the fix, subtree isolation and the call to onPostActivate() await the initial focus delay (if there is one, which is default behavior; remove it with delayInitialFocus=false) before being applied/called.
    • This may cause tests to fail, requiring the addition of slight delays before testing a given state (e.g. await waitFor(() => expect(initialFocusNode).toBeFocused()).
    • It may also disrupt current assumptions about the state of the initial focus node in code that runs in your onPostActivate() handler (prior to this change, that node would not be focused yet; after this change, it will be focused).
Commits
  • d9155b4 Version Packages (#1755)
  • b6ea4b5 #1747 Fix aria-hidden blocked when isolating subtrees due to initial focus ...
  • 186e6b4 [DEPENDABOT]: Bump @​types/node from 25.0.9 to 25.0.10 (#1750)
  • 42e838b [DEPENDABOT]: Bump rollup from 4.55.3 to 4.57.0 (#1752)
  • 29eba6b [DEPENDABOT]: Bump @​typescript-eslint/eslint-plugin from 8.53.1 to 8.54.0 (#1...
  • 0c94ec0 [DEPENDABOT]: Bump globals from 17.0.0 to 17.2.0 (#1753)
  • f274bf2 [DEPENDABOT]: Bump prettier from 3.8.0 to 3.8.1 (#1754)
  • a5d0048 [DEPENDABOT]: Bump lodash from 4.17.21 to 4.17.23 (#1746)
  • 9f5940b [DEPENDABOT]: Bump @​typescript-eslint/eslint-plugin from 8.53.0 to 8.53.1 (#1...
  • f936d43 [DEPENDABOT]: Bump rollup from 4.55.1 to 4.55.3 (#1741)
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [focus-trap](https://github.com/focus-trap/focus-trap) from 7.8.0 to 8.0.0.
- [Release notes](https://github.com/focus-trap/focus-trap/releases)
- [Changelog](https://github.com/focus-trap/focus-trap/blob/master/CHANGELOG.md)
- [Commits](focus-trap/focus-trap@v7.8.0...v8.0.0)

---
updated-dependencies:
- dependency-name: focus-trap
  dependency-version: 8.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot bot added dependencies Pull requests that update a dependency file javascript Pull requests that update Javascript code labels Feb 2, 2026
@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Feb 2, 2026

Deploying web-editor with  Cloudflare Pages  Cloudflare Pages

Latest commit: 21be60d
Status: ✅  Deploy successful!
Preview URL: https://2cc833ba.web-editor-2j8.pages.dev
Branch Preview URL: https://dependabot-npm-and-yarn-focu-hi2l.web-editor-2j8.pages.dev

View logs

@dependabot dependabot bot added dependencies Pull requests that update a dependency file javascript Pull requests that update Javascript code labels Feb 2, 2026
@makermelissa makermelissa merged commit e631f2a into main Feb 3, 2026
2 checks passed
@dependabot dependabot bot deleted the dependabot/npm_and_yarn/focus-trap-8.0.0 branch February 3, 2026 22:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file javascript Pull requests that update Javascript code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant