patternfly / patternfly-react

A set of React components for the PatternFly project.
https://react-staging.patternfly.org/
MIT License
774 stars 352 forks source link

Fixes 11053: focus event causing jumpy scroll effect #11056

Open Andrewgdewar opened 4 days ago

Andrewgdewar commented 4 days ago

Closes #11053

Prevents inconsistent scrolling behaviour on a number of select/menu components.

This also removes the timeout, which appears is no longer needed. (Slightly snappier without, with/without barely noticeable).

What: Closes 11053

Additional issues: Associated External issue from Red Hat Insights team

patternfly-build commented 4 days ago

Preview: https://patternfly-react-pr-11056.surge.sh

A11y report: https://patternfly-react-pr-11056-a11y.surge.sh

Andrewgdewar commented 2 days ago

Someone please point me to the documentation to run the linter. 🙄

Andrewgdewar commented 1 day ago

Updated:

I suggest either making preventScroll > true and including the timeout without the new paramater, or removing setTimeout and including the preventScrollOnItemFocus paramater.