Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WRQ-9559: Fix scrolling by holding pageup/down key #1602

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

vJIYEv
Copy link
Contributor

@vJIYEv vJIYEv commented Apr 26, 2024

Checklist

  • I have read and understand the contribution guide
  • A CHANGELOG entry is included
  • At least one test case is included for this feature or bug fix
  • Documentation was added or is not needed
  • This is an API breaking change

Issue Resolved / Feature Added

Scrolling by holding pageup/down key works / does not work case by case.

  • Pointer mode
    • holding pageup/down key works if pointer is out of the component.
    • holding pageup/down key does not work if pointer is in the component.
  • Key mode
    • holding pageup/down key does not work in macOS WebKIt (Safari). (It works in other environments)

We need to fix for all cases to show same behavior.

Resolution

Scrolling by holding pageup/down key occurs because of default behavior of browser.
But default behavior varies from browser to browser, so we can't make scroll works if default behavior is not to scroll.
To match scroll behavior of all cases, I prevented default behavior when pressed pageup/down key.

Additional Considerations

Links

WRQ-9559

Comments

Enact-DCO-1.0-Signed-off-by: Jiye Kim ([email protected])

Copy link

codecov bot commented Apr 26, 2024

Codecov Report

Attention: Patch coverage is 10.00000% with 9 lines in your changes are missing coverage. Please review.

Project coverage is 81.43%. Comparing base (e5a4a21) to head (a038026).

Files Patch % Lines
useScroll/useEvent.js 10.00% 5 Missing and 4 partials ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #1602      +/-   ##
===========================================
- Coverage    81.45%   81.43%   -0.02%     
===========================================
  Files          148      148              
  Lines         6631     6632       +1     
  Branches      1957     1958       +1     
===========================================
  Hits          5401     5401              
  Misses         936      936              
- Partials       294      295       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@@ -2,7 +2,7 @@ dist: focal
language: node_js
node_js:
- lts/*
- node
- 21
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's revert it back. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants