Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 10 additions & 3 deletions dist/flickity.pkgd.js
Original file line number Diff line number Diff line change
Expand Up @@ -1998,6 +1998,11 @@ if ( jQuery && jQuery.bridget ) {
jQuery.bridget( 'flickity', Flickity );
}

// set internal jQuery, for Webpack + jQuery v3, #478
Flickity.setJQuery = function( jq ) {
jQuery = jq;
};

Flickity.Cell = Cell;

return Flickity;
Expand Down Expand Up @@ -2632,7 +2637,10 @@ return Unidragger;

utils.extend( Flickity.defaults, {
draggable: true,
dragThreshold: 3,
dragThreshold: {
x: 3,
y: 3
}
});

// ----- create ----- //
Expand Down Expand Up @@ -2776,7 +2784,7 @@ proto.canPreventDefaultOnPointerDown = function( event ) {
// ----- move ----- //

proto.hasDragStarted = function( moveVector ) {
return Math.abs( moveVector.x ) > this.options.dragThreshold;
return Math.abs( moveVector.x ) > this.options.dragThreshold.x && Math.abs( moveVector.y ) < this.options.dragThreshold.y;
};

// ----- up ----- //
Expand Down Expand Up @@ -2809,7 +2817,6 @@ proto.pointerMove = function( event, pointer ) {
};

proto.dragMove = function( event, pointer, moveVector ) {
event.preventDefault();

this.previousDragX = this.dragX;
// reverse if right-to-left
Expand Down
Loading