brainhubeu / react-carousel

A pure extendable React carousel, powered by Brainhub (craftsmen who ❤️ JS)
https://brainhub.eu/
MIT License
1.07k stars 164 forks source link

minDraggableOffset not working #540

Closed piotr-s-brainhub closed 4 years ago

piotr-s-brainhub commented 4 years ago

Issuehunt badges

It is: minDraggableOffset even if set to 0 or 1, still requires a large offset to change the slide.

It should be: it should require a move with at least the value of the minDraggableOffset

Code applicable in the clickable demo/ docs:

<Carousel
  slidesPerPage={2}
  infinite
  minDraggableOffset={0}
>
  <img src={imageOne} />
  <img src={imageTwo} />
  <img src={imageThree} />
</Carousel>

Desktop:

Mobile


IssueHunt Summary ### Backers (Total: $0.00) #### [Become a backer now!](https://issuehunt.io/r/brainhubeu/react-carousel/issues/540) #### [Or submit a pull request to get the deposits!](https://issuehunt.io/r/brainhubeu/react-carousel/issues/540) ### Tips - Checkout the [Issuehunt explorer](https://issuehunt.io/r/brainhubeu/react-carousel/) to discover more funded issues. - Need some help from other developers? [Add your repositories](https://issuehunt.io/r/new) on IssueHunt to raise funds.
issuehunt-oss[bot] commented 4 years ago

@piotr-s-brainhub has funded $7.00 to this issue.


issuehunt-oss[bot] commented 4 years ago

@piotr-s-brainhub has cancelled funding for this issue.(Cancelled amount: $7.00) See it on IssueHunt

RobertHebel commented 4 years ago

@piotr-s-brainhub distance to change slide equals 50% of slide width. To change that behavior you can use keepDirectionWhenDragging prop.

minDraggableOffset allows users to click on a slide that contains a link and its default value is sufficient for all cases. That's why it will be removed in the carousel v2

You can find more details about minDraggableOffset here: #131