Skip to content

Removing pageSize from sliderProps #2917

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

Merged
merged 10 commits into from
Mar 4, 2022
Merged

Removing pageSize from sliderProps #2917

merged 10 commits into from
Mar 4, 2022

Conversation

LFDanLu
Copy link
Member

@LFDanLu LFDanLu commented Mar 3, 2022

For release audit
Also forcing pageSize to be a multiple of step

✅ Pull Request Checklist:

  • Included link to corresponding React Spectrum GitHub Issue.
  • Added/updated unit tests and storybook for this change (for new code or code which already has tests).
  • Filled out test instructions.
  • Updated documentation (if it already exists for this component).
  • Looked at the Accessibility Practices for this feature - Aria Practices

📝 Test Instructions:

Unit test should cover the behavior
The slider "step" story should also display a page step of 10
The slider "minMax" story should display a page step of 4

🧢 Your Project:

RSP

@adobe-bot
Copy link

Build successful! 🎉

snowystinger
snowystinger previously approved these changes Mar 3, 2022
Copy link
Member

@snowystinger snowystinger left a comment

Choose a reason for hiding this comment

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

Works well

snowystinger
snowystinger previously approved these changes Mar 3, 2022
@adobe-bot
Copy link

Build successful! 🎉

@adobe-bot
Copy link

Build successful! 🎉

@adobe-bot
Copy link

Build successful! 🎉

@adobe-bot
Copy link

Build successful! 🎉

snowystinger
snowystinger previously approved these changes Mar 4, 2022
Copy link
Member

@snowystinger snowystinger left a comment

Choose a reason for hiding this comment

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

ok, looks good again :) thanks for checking more on that math

LFDanLu added a commit that referenced this pull request Mar 4, 2022
#2917 removes the pageSize prop from useSliderState so we need to manually override the page size on pageup pagedown
devongovett
devongovett previously approved these changes Mar 4, 2022
memoizing step calc in useSliderState as well. Exposing pageSize and step from useColorSliderState allows us to remove extraneous useKeyboard from useColorSlider that was previously needed for pageUp/Down handling
@LFDanLu LFDanLu dismissed stale reviews from devongovett and snowystinger via 7977055 March 4, 2022 18:30
@adobe-bot
Copy link

Build successful! 🎉

@adobe-bot
Copy link

Build successful! 🎉

@adobe-bot
Copy link

Build successful! 🎉

@adobe-bot
Copy link

Build successful! 🎉

@dannify dannify merged commit 0f255bb into main Mar 4, 2022
@dannify dannify deleted the removing_page_size_slider branch March 4, 2022 21:16
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.

5 participants