Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Provide a swipe navigation distance setting for users to config along with swipe indicator #9617

Merged
merged 1 commit into from
Jul 2, 2017

Conversation

darkdh
Copy link
Member

@darkdh darkdh commented Jun 20, 2017

fixes #9615

Auditors: @cezaraugusto, @bbondy, @bradleyrichter

Test Plan:

  1. Adjust swipe navigation sesitivity setting in
    about:preferences#advanced
  2. And swipe to navigate by different settings

It shouldn't show up on linux and window

Submitter Checklist:

  • Submitted a ticket for my issue if one did not already exist.
  • Used Github auto-closing keywords in the commit message.
  • Added/updated tests for this change (for new code or code which already has tests).
  • Ran git rebase -i to squash commits (if needed).
  • Tagged reviewers and labelled the pull request as needed.

Reviewer Checklist:

Tests

  • Adequate test coverage exists to prevent regressions
  • Tests should be independent and work correctly when run individually or as a suite ref
  • New files have MPL2 license header

screen shot 2017-06-29 at 11 05 22 am

Also add swipe indicator

kapture 2017-06-29 at 11 06 41

@bradleyrichter
Copy link
Contributor

@darkdh I think the slowest setting greatly improves on the accidental swipe issue we are having now. It felt natural as well. So I don't think the slider is necessary right now but keep it for other future needs?

@darkdh
Copy link
Member Author

darkdh commented Jun 21, 2017

@bradleyrichter, we can make the slowest setting default but some users like swiping faster or even slower. We can't satisfy all users with one setting so we allow them to customize.
I'm a fast swiper and I believe @diracdeltas is even faster.

@darkdh darkdh force-pushed the swipe_nav_sensitivity branch 3 times, most recently from 361fe7b to 76e3f20 Compare June 21, 2017 19:23
@darkdh
Copy link
Member Author

darkdh commented Jun 23, 2017

also fix #2477

@cezaraugusto
Copy link
Contributor

feature works but sometimes instead of swiping to the next/previous page it opens the context menu. I don't have proper str

@cezaraugusto
Copy link
Contributor

which is tricky given it also happens with Chrome

@cezaraugusto
Copy link
Contributor

btw what's the take on #9617 (comment) @bradleyrichter @darkdh ?

with swipe progress indicator

fixes #9615 #2477

Auditors: @cezaraugusto, @bbondy, @bradleyrichter

Test Plan:
1. Adjust swipe navigation distance setting in
about:preferences#advanced
2. And swipe to navigate by different settings

It shouldn't show up on linux and window
@darkdh
Copy link
Member Author

darkdh commented Jun 29, 2017

@cezaraugusto it is addressed per discussion I had with @bradleyrichter yesterday
�This PR is ready for review again.

@darkdh darkdh requested a review from bsclifton June 29, 2017 18:09
@darkdh darkdh changed the title Provide a swipe navigation sensitivity setting for users to config Provide a swipe navigation distance setting for users to config along with swipe indicator Jun 29, 2017
@cezaraugusto cezaraugusto added this to the 0.20.x (Nightly Channel) milestone Jul 2, 2017
props.swipeLeftPercent = swipeLeftPercent ? (swipeLeftPercent + 1) * 1.2 : 1
props.swipeRightPercent = swipeRightPercent ? (swipeRightPercent + 1) * 1.2 : 1
// 0.85 is the default button opacity in less/navigationBar.less
// Remove this magic number once we migrate to Aphrodite
Copy link
Contributor

Choose a reason for hiding this comment

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

thanks for the comment

Copy link
Member

Choose a reason for hiding this comment

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

++

<input type='range' min='1' max='201' step='50' list='swipeDistance'
value={getSetting(settings.SWIPE_NAV_DISTANCE, this.props.settings)}
onChange={changeSetting.bind(null, this.props.onChangeSetting, settings.SWIPE_NAV_DISTANCE)} />
<datalist id='swipeDistance'>
Copy link
Contributor

@cezaraugusto cezaraugusto Jul 2, 2017

Choose a reason for hiding this comment

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

the front-end gods salute you for this great element 😜


swipeNavigation__longLabel: {
marginLeft: '5px'
},
Copy link
Contributor

Choose a reason for hiding this comment

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

super cool

Copy link
Contributor

@cezaraugusto cezaraugusto left a comment

Choose a reason for hiding this comment

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

can't wait to start using it, great work +++++++

@cezaraugusto cezaraugusto merged commit 8503998 into master Jul 2, 2017
@cezaraugusto cezaraugusto deleted the swipe_nav_sensitivity branch July 2, 2017 03:23
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Swipe Navigation Sensitivity Setting
4 participants