Socket
Socket
Sign inDemoInstall

react-responsive-carousel

Package Overview
Dependencies
Maintainers
1
Versions
121
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-responsive-carousel - npm Package Compare versions

Comparing version 3.0.19 to 3.0.20

12

lib/components/Carousel.js

@@ -29,5 +29,6 @@ 'use strict';

onChange: React.PropTypes.func,
axis: React.PropTypes.string,
axis: React.PropTypes.oneOf(['horizontal', 'vertical']),
width: React.PropTypes.string,
useKeyboardArrows: React.PropTypes.bool
useKeyboardArrows: React.PropTypes.bool,
swipeScrollTolerance: React.PropTypes.oneOfType([React.PropTypes.number, React.PropTypes.string])
},

@@ -44,3 +45,4 @@

axis: 'horizontal',
useKeyboardArrows: false
useKeyboardArrows: false,
swipeScrollTolerance: 5
};

@@ -197,4 +199,4 @@ },

// should prevent default?
return axisDelta !== 0;
// allows scroll if the swipe was within the tolerance
return Math.abs(axisDelta) > this.props.swipeScrollTolerance;
},

@@ -201,0 +203,0 @@ decrement: function decrement(positions) {

{
"name": "react-responsive-carousel",
"version": "3.0.19",
"version": "3.0.20",
"description": "React Responsive Carousel",

@@ -5,0 +5,0 @@ "author": {

@@ -49,3 +49,3 @@ # React Responsive Carousel

| Attributes | Type | Default | Description |
| :--------- | :--: | :-----: | ----------- |
| :--------- | :--: | :-----: | :----------- |
| showArrows | `boolean` | `true` | show prev and next arrows |

@@ -62,3 +62,4 @@ | showStatus | `boolean` | `true` | show index of the current item. i.e: (1/8) |

| width | `string` | - | Allows to set a fixed width |
| useKeyboardArrows | `boolean` | false | Adds support to next and prev through keyboard arrows |
| useKeyboardArrows | `boolean` | `false` | Adds support to next and prev through keyboard arrows |
| swipeScrollTolerance | `number` | `5` | Allows scroll when the swipe movement occurs in a different direction than the carousel axis and within the tolerance - Increase for loose - Decrease for strict |

@@ -65,0 +66,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc