Skip to content

[Snyk] Upgrade react-focus-on from 3.9.1 to 3.9.2#7624

Closed
JasonStoltz wants to merge 3 commits intomainfrom
snyk-upgrade-40e2ac99f778c5b50e840329f4af2c5d
Closed

[Snyk] Upgrade react-focus-on from 3.9.1 to 3.9.2#7624
JasonStoltz wants to merge 3 commits intomainfrom
snyk-upgrade-40e2ac99f778c5b50e840329f4af2c5d

Conversation

@JasonStoltz
Copy link
Member

This PR was automatically created by Snyk using the credentials of a real user.


Snyk has created this PR to upgrade react-focus-on from 3.9.1 to 3.9.2.

ℹ️ Keep your dependencies up-to-date. This makes it easier to fix existing vulnerabilities and to more quickly identify and fix newly disclosed vulnerabilities when they affect your project.


  • The recommended version is 1 version ahead of your current version.
  • The recommended version was released 23 days ago, on 2024-03-03.

Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open upgrade PRs.

For more information:

🧐 View latest project report

🛠 Adjust upgrade PR settings

🔕 Ignore this dependency or unsubscribe from future upgrade PRs

Snyk has created this PR to upgrade react-focus-on from 3.9.1 to 3.9.2.

See this package in npm:


See this project in Snyk:
https://app.snyk.io/org/eui/project/782ac3a8-8bb4-4658-baa9-190d6cb035f1?utm_source=github-enterprise&utm_medium=referral&page=upgrade-pr
@JasonStoltz JasonStoltz requested a review from a team as a code owner March 26, 2024 18:58
@mgadewoll mgadewoll self-assigned this Mar 28, 2024
@mgadewoll
Copy link
Contributor

This upgrade updates internal dependencies only, see the changes here.

Dependencies updated:

  • react-focus-lock: ^2.9.4 -> ^2.11.2, (changes)
  • react-remove-scroll: ^2.5.6 -> ^2.5.7 (changes)
  • react-style-singleton: ^2.2.0 -> ^2.2.1 (changes)

ℹ️ Affected components:

  • EuiFocusTrap - used in:
    • EuiOverlayMask
    • EuiFlyout
    • EuiCustomFlyout
    • EuiCodeBlock (fullscreen)
    • EuiDataGrid (fullscreen)
    • EuiImage (fullscreen)
    • EuiModal
    • EuiInputPopover
    • EuiPopover

✅ There were no regression issues found for EuiFocusTrap through manual testing.

@cee-chen
Copy link
Contributor

FYI, this is a potentially high risk/high impact set of dependency / subdependency updates - we semi-frequently contribute back to react-focus-on and it's many sub-dependencies to get the fixes/functionality we need. We have "react-focus-lock": "^2.9.5" pinned in our package.json for one of those fixes, and we should go ahead and remove that now

@elasticmachine
Copy link
Collaborator

elasticmachine commented Mar 28, 2024

💔 Build Failed

Failed CI Steps

History

cc @mgadewoll

@kibanamachine
Copy link

Preview staging links for this PR:

@mgadewoll
Copy link
Contributor

mgadewoll commented Apr 2, 2024

FYI, this is a potentially high risk/high impact set of dependency / subdependency updates - we semi-frequently contribute back to react-focus-on and it's many sub-dependencies to get the fixes/functionality we need. We have "react-focus-lock": "^2.9.5" pinned in our package.json for one of those fixes, and we should go ahead and remove that now

⚠️ After removing the fixed resolution for react-focus-lock some tests for focus_utils.spec.tsx started failing.
After opening the actions popover of a cell, the tests expect focus to return to the cell (button) when pressing ESCAPE on the opened actions popover. Instead it moves to the first focusable item in the grid toolbar.

current

Screenshot 2024-04-02 at 17 39 36

expected

Screenshot 2024-04-02 at 17 39 59

It seems that with react-focus-on version 2.11.0 there where underlying changes to returning focus that change the behavior.

🔍 It might be related to this change:

  • The activeElement passed to captureFocusRestore is the cell button that previously was focused on returned focus
  • The newly returned element that comes back from restoreFocusTo called inside captureFocusRestore is now the toolbar action button

📦 Some dependency update info on when it starts breaking:

  • the dependency focus-lock added the returnFocusTo functionality in version 1.2.0 which react-focus-lock added in version 2.10.1 (version comparison here)
  • react-focus-lock started using captureFocusRestore in version 2.11.0 (version comparison here)

@mgadewoll mgadewoll mentioned this pull request May 10, 2024
10 tasks
@JasonStoltz JasonStoltz mentioned this pull request Aug 19, 2024
2 tasks
@github-actions
Copy link

👋 Hey there. This PR hasn't had any activity for 90 days. We'll automatically close it if that trend continues for another week. If you feel this issue is still valid and needs attention please let us know with a comment.

@github-actions github-actions bot added the stale-pr (Don't delete - used for automation) label Sep 19, 2024
@github-actions
Copy link

❌ We're automatically closing this PR due to lack of activity. Please comment if you feel this was done in error.

@github-actions github-actions bot added the stale-pr-closed (Don't delete - used for automation) label Sep 27, 2024
@github-actions github-actions bot closed this Sep 27, 2024
@cee-chen
Copy link
Contributor

FYI - I tried upgrading to latest 3.9.4 with latest main, but still ran into 1 Cypress failure with focus not properly returning as expected within EuiDataGridHeaderCell focus traps.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

stale-pr (Don't delete - used for automation) stale-pr-closed (Don't delete - used for automation)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants