Skip to content

Commit

Permalink
4.0.5 version bump & build
Browse files Browse the repository at this point in the history
  • Loading branch information
dimsemenov committed Jan 15, 2015
1 parent 6d281d6 commit 8acdf7f
Show file tree
Hide file tree
Showing 7 changed files with 23 additions and 9 deletions.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "photoswipe",
"version": "4.0.3",
"version": "4.0.5",
"homepage": "http://photoswipe.com",
"authors": [
"Dmitry Semenov <diiiimaaaa@gmail.com>"
Expand Down
18 changes: 16 additions & 2 deletions dist/photoswipe-ui-default.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! PhotoSwipe Default UI - 4.0.3 - 2015-01-03
/*! PhotoSwipe Default UI - 4.0.5 - 2015-01-15
* http://photoswipe.com
* Copyright (c) 2015 Dmitry Semenov; */
/**
Expand Down Expand Up @@ -74,6 +74,8 @@ var PhotoSwipeUI_Default =
tapToClose: false,
tapToToggleControls: true,

clickToCloseNonZoomable: true,

shareButtons: [
{id:'facebook', label:'Share on Facebook', url:'https://www.facebook.com/sharer/sharer.php?u={{url}}'},
{id:'twitter', label:'Tweet', url:'https://twitter.com/intent/tweet?text={{text}}&url={{url}}'},
Expand Down Expand Up @@ -107,6 +109,11 @@ var PhotoSwipeUI_Default =

e = e || window.event;

if(_options.timeToIdle && _options.mouseUsed && !_isIdle) {
// reset idle timer
_onIdleMouseMove();
}


var target = e.target || e.srcElement,
uiElement,
Expand Down Expand Up @@ -680,6 +687,10 @@ var PhotoSwipeUI_Default =
_overlayUIUpdated = false;
}

if(!_shareModalHidden) {
_toggleShareModal();
}

_countNumItems();
};

Expand Down Expand Up @@ -708,11 +719,14 @@ var PhotoSwipeUI_Default =
// close gallery if clicked outside of the image
if(_hasCloseClass(target)) {
pswp.close();
return;
}

if(framework.hasClass(target, 'pswp__img')) {
if(pswp.getZoomLevel() === 1 && pswp.getZoomLevel() <= pswp.currItem.fitRatio) {
pswp.close();
if(_options.clickToCloseNonZoomable) {
pswp.close();
}
} else {
pswp.toggleDesktopZoom(e.detail.releasePoint);
}
Expand Down
4 changes: 2 additions & 2 deletions dist/photoswipe-ui-default.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/photoswipe.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! PhotoSwipe - v4.0.3 - 2015-01-05
/*! PhotoSwipe - v4.0.5 - 2015-01-15
* http://photoswipe.com
* Copyright (c) 2015 Dmitry Semenov; */
(function (root, factory) {
Expand Down
2 changes: 1 addition & 1 deletion dist/photoswipe.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "photoswipe",
"version": "4.0.3",
"version": "4.0.5",
"engines": {
"node": ">= 0.8.0"
},
Expand Down
2 changes: 1 addition & 1 deletion photoswipe.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "PhotoSwipe",
"title": "Photoswipe",
"description": "",
"version": "4.0.3",
"version": "4.0.5",
"homepage": "http://photoswipe.com",
"demo": "http://photoswipe.com",
"docs": "http://photoswipe.com",
Expand Down

0 comments on commit 8acdf7f

Please sign in to comment.