promethee 1.7.12 → 1.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/promethee/rails/version.rb +1 -1
- data/node_modules/@fancyapps/fancybox/README.md +1 -1
- data/node_modules/@fancyapps/fancybox/dist/jquery.fancybox.css +162 -161
- data/node_modules/@fancyapps/fancybox/dist/jquery.fancybox.js +1281 -790
- data/node_modules/@fancyapps/fancybox/dist/jquery.fancybox.min.css +1 -1
- data/node_modules/@fancyapps/fancybox/dist/jquery.fancybox.min.js +4 -3
- data/node_modules/@fancyapps/fancybox/docs/index.html +1398 -1321
- data/node_modules/@fancyapps/fancybox/package.json +52 -43
- data/node_modules/@fancyapps/fancybox/src/css/core.css +144 -142
- data/node_modules/@fancyapps/fancybox/src/css/thumbs.css +20 -23
- data/node_modules/@fancyapps/fancybox/src/js/core.js +883 -536
- data/node_modules/@fancyapps/fancybox/src/js/fullscreen.js +67 -64
- data/node_modules/@fancyapps/fancybox/src/js/guestures.js +114 -78
- data/node_modules/@fancyapps/fancybox/src/js/hash.js +13 -18
- data/node_modules/@fancyapps/fancybox/src/js/media.js +118 -29
- data/node_modules/@fancyapps/fancybox/src/js/share.js +8 -6
- data/node_modules/@fancyapps/fancybox/src/js/slideshow.js +55 -32
- data/node_modules/@fancyapps/fancybox/src/js/thumbs.js +22 -26
- data/node_modules/@fancyapps/fancybox/src/js/wheel.js +1 -1
- metadata +2 -46
- data/node_modules/fancybox/CHANGELOG.md +0 -125
- data/node_modules/fancybox/README.md +0 -249
- data/node_modules/fancybox/bower.json +0 -24
- data/node_modules/fancybox/demo/1_b.jpg +0 -0
- data/node_modules/fancybox/demo/1_s.jpg +0 -0
- data/node_modules/fancybox/demo/2_b.jpg +0 -0
- data/node_modules/fancybox/demo/2_s.jpg +0 -0
- data/node_modules/fancybox/demo/3_b.jpg +0 -0
- data/node_modules/fancybox/demo/3_s.jpg +0 -0
- data/node_modules/fancybox/demo/4_b.jpg +0 -0
- data/node_modules/fancybox/demo/4_s.jpg +0 -0
- data/node_modules/fancybox/demo/5_b.jpg +0 -0
- data/node_modules/fancybox/demo/5_s.jpg +0 -0
- data/node_modules/fancybox/demo/ajax.txt +0 -15
- data/node_modules/fancybox/demo/iframe.html +0 -26
- data/node_modules/fancybox/demo/index.html +0 -312
- data/node_modules/fancybox/dist/css/jquery.fancybox.css +0 -222
- data/node_modules/fancybox/dist/helpers/css/jquery.fancybox-buttons.css +0 -82
- data/node_modules/fancybox/dist/helpers/css/jquery.fancybox-thumbs.css +0 -46
- data/node_modules/fancybox/dist/helpers/img/fancybox_buttons.png +0 -0
- data/node_modules/fancybox/dist/helpers/js/jquery.fancybox-buttons.cjs.js +0 -121
- data/node_modules/fancybox/dist/helpers/js/jquery.fancybox-buttons.js +0 -122
- data/node_modules/fancybox/dist/helpers/js/jquery.fancybox-media.cjs.js +0 -199
- data/node_modules/fancybox/dist/helpers/js/jquery.fancybox-media.js +0 -199
- data/node_modules/fancybox/dist/helpers/js/jquery.fancybox-thumbs.cjs.js +0 -164
- data/node_modules/fancybox/dist/helpers/js/jquery.fancybox-thumbs.js +0 -165
- data/node_modules/fancybox/dist/helpers/scss/jquery.fancybox-buttons.scss +0 -100
- data/node_modules/fancybox/dist/helpers/scss/jquery.fancybox-thumbs.scss +0 -55
- data/node_modules/fancybox/dist/img/blank.gif +0 -0
- data/node_modules/fancybox/dist/img/fancybox_loading.gif +0 -0
- data/node_modules/fancybox/dist/img/fancybox_loading@2x.gif +0 -0
- data/node_modules/fancybox/dist/img/fancybox_overlay.png +0 -0
- data/node_modules/fancybox/dist/img/fancybox_sprite.png +0 -0
- data/node_modules/fancybox/dist/img/fancybox_sprite@2x.png +0 -0
- data/node_modules/fancybox/dist/js/jquery.fancybox.cjs.js +0 -2027
- data/node_modules/fancybox/dist/js/jquery.fancybox.js +0 -2018
- data/node_modules/fancybox/dist/js/jquery.fancybox.pack.js +0 -46
- data/node_modules/fancybox/dist/scss/jquery.fancybox.scss +0 -276
- data/node_modules/fancybox/fancybox.jquery.json +0 -31
- data/node_modules/fancybox/lib/jquery-1.10.2.min.js +0 -6
- data/node_modules/fancybox/lib/jquery.mousewheel.pack.js +0 -14
- data/node_modules/fancybox/package.json +0 -32
- data/node_modules/fancybox/sprite.psd +0 -0
- data/node_modules/fancybox/test.js +0 -10
@@ -4,7 +4,7 @@
|
|
4
4
|
// Enables linking to each modal
|
5
5
|
//
|
6
6
|
// ==========================================================================
|
7
|
-
(function(
|
7
|
+
(function(window, document, $) {
|
8
8
|
"use strict";
|
9
9
|
|
10
10
|
// Simple $.escapeSelector polyfill (for jQuery prior v3)
|
@@ -47,13 +47,12 @@
|
|
47
47
|
|
48
48
|
// Trigger click evnt on links to open new fancyBox instance
|
49
49
|
function triggerFromUrl(url) {
|
50
|
-
var $el;
|
51
|
-
|
52
50
|
if (url.gallery !== "") {
|
53
|
-
// If we can find element matching 'data-fancybox' atribute,
|
54
|
-
//
|
55
|
-
$
|
51
|
+
// If we can find element matching 'data-fancybox' atribute,
|
52
|
+
// then triggering click event should start fancyBox
|
53
|
+
$("[data-fancybox='" + $.escapeSelector(url.gallery) + "']")
|
56
54
|
.eq(url.index - 1)
|
55
|
+
.focus()
|
57
56
|
.trigger("click.fb-start");
|
58
57
|
}
|
59
58
|
}
|
@@ -67,7 +66,7 @@
|
|
67
66
|
}
|
68
67
|
|
69
68
|
opts = instance.current ? instance.current.opts : instance.opts;
|
70
|
-
ret = opts.hash || (opts.$orig ? opts.$orig.data("fancybox") : "");
|
69
|
+
ret = opts.hash || (opts.$orig ? opts.$orig.data("fancybox") || opts.$orig.data("fancybox-trigger") : "");
|
71
70
|
|
72
71
|
return ret === "" ? false : ret;
|
73
72
|
}
|
@@ -120,7 +119,7 @@
|
|
120
119
|
return;
|
121
120
|
}
|
122
121
|
|
123
|
-
if (!instance.origHash) {
|
122
|
+
if (firstRun && !instance.origHash) {
|
124
123
|
instance.origHash = window.location.hash;
|
125
124
|
}
|
126
125
|
|
@@ -149,13 +148,11 @@
|
|
149
148
|
},
|
150
149
|
|
151
150
|
"beforeClose.fb": function(e, instance, current) {
|
152
|
-
var gallery;
|
153
|
-
|
154
151
|
if (current.opts.hash === false) {
|
155
152
|
return;
|
156
153
|
}
|
157
154
|
|
158
|
-
|
155
|
+
clearTimeout(instance.hashTimer);
|
159
156
|
|
160
157
|
// Goto previous history entry
|
161
158
|
if (instance.currentHash && instance.hasCreatedHistory) {
|
@@ -169,15 +166,13 @@
|
|
169
166
|
}
|
170
167
|
|
171
168
|
instance.currentHash = null;
|
172
|
-
|
173
|
-
clearTimeout(instance.hashTimer);
|
174
169
|
}
|
175
170
|
});
|
176
171
|
|
177
172
|
// Check if need to start/close after url has changed
|
178
173
|
$(window).on("hashchange.fb", function() {
|
179
174
|
var url = parseUrl(),
|
180
|
-
fb;
|
175
|
+
fb = null;
|
181
176
|
|
182
177
|
// Find last fancyBox instance that has "hash"
|
183
178
|
$.each(
|
@@ -186,8 +181,8 @@
|
|
186
181
|
.reverse(),
|
187
182
|
function(index, value) {
|
188
183
|
var tmp = $(value).data("FancyBox");
|
189
|
-
|
190
|
-
if (tmp.currentHash) {
|
184
|
+
|
185
|
+
if (tmp && tmp.currentHash) {
|
191
186
|
fb = tmp;
|
192
187
|
return false;
|
193
188
|
}
|
@@ -196,7 +191,7 @@
|
|
196
191
|
|
197
192
|
if (fb) {
|
198
193
|
// Now, compare hash values
|
199
|
-
if (fb.currentHash
|
194
|
+
if (fb.currentHash !== url.gallery + "-" + url.index && !(url.index === 1 && fb.currentHash == url.gallery)) {
|
200
195
|
fb.currentHash = null;
|
201
196
|
|
202
197
|
fb.close();
|
@@ -213,4 +208,4 @@
|
|
213
208
|
}
|
214
209
|
}, 50);
|
215
210
|
});
|
216
|
-
})(
|
211
|
+
})(window, document, jQuery);
|
@@ -7,32 +7,7 @@
|
|
7
7
|
(function($) {
|
8
8
|
"use strict";
|
9
9
|
|
10
|
-
// Formats matching url to final form
|
11
|
-
|
12
|
-
var format = function(url, rez, params) {
|
13
|
-
if (!url) {
|
14
|
-
return;
|
15
|
-
}
|
16
|
-
|
17
|
-
params = params || "";
|
18
|
-
|
19
|
-
if ($.type(params) === "object") {
|
20
|
-
params = $.param(params, true);
|
21
|
-
}
|
22
|
-
|
23
|
-
$.each(rez, function(key, value) {
|
24
|
-
url = url.replace("$" + key, value || "");
|
25
|
-
});
|
26
|
-
|
27
|
-
if (params.length) {
|
28
|
-
url += (url.indexOf("?") > 0 ? "&" : "?") + params;
|
29
|
-
}
|
30
|
-
|
31
|
-
return url;
|
32
|
-
};
|
33
|
-
|
34
10
|
// Object containing properties for each media type
|
35
|
-
|
36
11
|
var defaults = {
|
37
12
|
youtube: {
|
38
13
|
matcher: /(youtube\.com|youtu\.be|youtube\-nocookie\.com)\/(watch\?(.*&)?v=|v\/|u\/|embed\/?)?(videoseries\?list=(.*)|[\w-]{11}|\?listType=(.*)&list=(.*))(.*)/i,
|
@@ -48,7 +23,7 @@
|
|
48
23
|
},
|
49
24
|
paramPlace: 8,
|
50
25
|
type: "iframe",
|
51
|
-
url: "//www.youtube.com/embed/$4",
|
26
|
+
url: "//www.youtube-nocookie.com/embed/$4",
|
52
27
|
thumb: "//img.youtube.com/vi/$4/hqdefault.jpg"
|
53
28
|
},
|
54
29
|
|
@@ -60,8 +35,7 @@
|
|
60
35
|
show_title: 1,
|
61
36
|
show_byline: 1,
|
62
37
|
show_portrait: 0,
|
63
|
-
fullscreen: 1
|
64
|
-
api: 1
|
38
|
+
fullscreen: 1
|
65
39
|
},
|
66
40
|
paramPlace: 3,
|
67
41
|
type: "iframe",
|
@@ -107,6 +81,29 @@
|
|
107
81
|
}
|
108
82
|
};
|
109
83
|
|
84
|
+
// Formats matching url to final form
|
85
|
+
var format = function(url, rez, params) {
|
86
|
+
if (!url) {
|
87
|
+
return;
|
88
|
+
}
|
89
|
+
|
90
|
+
params = params || "";
|
91
|
+
|
92
|
+
if ($.type(params) === "object") {
|
93
|
+
params = $.param(params, true);
|
94
|
+
}
|
95
|
+
|
96
|
+
$.each(rez, function(key, value) {
|
97
|
+
url = url.replace("$" + key, value || "");
|
98
|
+
});
|
99
|
+
|
100
|
+
if (params.length) {
|
101
|
+
url += (url.indexOf("?") > 0 ? "&" : "?") + params;
|
102
|
+
}
|
103
|
+
|
104
|
+
return url;
|
105
|
+
};
|
106
|
+
|
110
107
|
$(document).on("objectNeedsType.fb", function(e, instance, item) {
|
111
108
|
var url = item.src || "",
|
112
109
|
type = false,
|
@@ -198,4 +195,96 @@
|
|
198
195
|
item.type = item.opts.defaultType;
|
199
196
|
}
|
200
197
|
});
|
201
|
-
|
198
|
+
|
199
|
+
// Load YouTube/Video API on request to detect when video finished playing
|
200
|
+
var VideoAPILoader = {
|
201
|
+
youtube: {
|
202
|
+
src: "https://www.youtube.com/iframe_api",
|
203
|
+
class: "YT",
|
204
|
+
loading: false,
|
205
|
+
loaded: false
|
206
|
+
},
|
207
|
+
|
208
|
+
vimeo: {
|
209
|
+
src: "https://player.vimeo.com/api/player.js",
|
210
|
+
class: "Vimeo",
|
211
|
+
loading: false,
|
212
|
+
loaded: false
|
213
|
+
},
|
214
|
+
|
215
|
+
load: function(vendor) {
|
216
|
+
var _this = this,
|
217
|
+
script;
|
218
|
+
|
219
|
+
if (this[vendor].loaded) {
|
220
|
+
setTimeout(function() {
|
221
|
+
_this.done(vendor);
|
222
|
+
});
|
223
|
+
return;
|
224
|
+
}
|
225
|
+
|
226
|
+
if (this[vendor].loading) {
|
227
|
+
return;
|
228
|
+
}
|
229
|
+
|
230
|
+
this[vendor].loading = true;
|
231
|
+
|
232
|
+
script = document.createElement("script");
|
233
|
+
script.type = "text/javascript";
|
234
|
+
script.src = this[vendor].src;
|
235
|
+
|
236
|
+
if (vendor === "youtube") {
|
237
|
+
window.onYouTubeIframeAPIReady = function() {
|
238
|
+
_this[vendor].loaded = true;
|
239
|
+
_this.done(vendor);
|
240
|
+
};
|
241
|
+
} else {
|
242
|
+
script.onload = function() {
|
243
|
+
_this[vendor].loaded = true;
|
244
|
+
_this.done(vendor);
|
245
|
+
};
|
246
|
+
}
|
247
|
+
|
248
|
+
document.body.appendChild(script);
|
249
|
+
},
|
250
|
+
done: function(vendor) {
|
251
|
+
var instance, $el, player;
|
252
|
+
|
253
|
+
if (vendor === "youtube") {
|
254
|
+
delete window.onYouTubeIframeAPIReady;
|
255
|
+
}
|
256
|
+
|
257
|
+
instance = $.fancybox.getInstance();
|
258
|
+
|
259
|
+
if (instance) {
|
260
|
+
$el = instance.current.$content.find("iframe");
|
261
|
+
|
262
|
+
if (vendor === "youtube" && YT !== undefined && YT) {
|
263
|
+
player = new YT.Player($el.attr("id"), {
|
264
|
+
events: {
|
265
|
+
onStateChange: function(e) {
|
266
|
+
if (e.data == 0) {
|
267
|
+
instance.next();
|
268
|
+
}
|
269
|
+
}
|
270
|
+
}
|
271
|
+
});
|
272
|
+
} else if (vendor === "vimeo" && Vimeo !== undefined && Vimeo) {
|
273
|
+
player = new Vimeo.Player($el);
|
274
|
+
|
275
|
+
player.on("ended", function() {
|
276
|
+
instance.next();
|
277
|
+
});
|
278
|
+
}
|
279
|
+
}
|
280
|
+
}
|
281
|
+
};
|
282
|
+
|
283
|
+
$(document).on({
|
284
|
+
"afterShow.fb": function(e, instance, current) {
|
285
|
+
if (instance.group.length > 1 && (current.contentSource === "youtube" || current.contentSource === "vimeo")) {
|
286
|
+
VideoAPILoader.load(current.contentSource);
|
287
|
+
}
|
288
|
+
}
|
289
|
+
});
|
290
|
+
})(jQuery);
|
@@ -11,9 +11,7 @@
|
|
11
11
|
btnTpl: {
|
12
12
|
share:
|
13
13
|
'<button data-fancybox-share class="fancybox-button fancybox-button--share" title="{{SHARE}}">' +
|
14
|
-
'<svg viewBox="0 0
|
15
|
-
'<path d="M6,30 C8,18 19,16 23,16 L23,16 L23,10 L33,20 L23,29 L23,24 C19,24 8,27 6,30 Z">' +
|
16
|
-
"</svg>" +
|
14
|
+
'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M2.55 19c1.4-8.4 9.1-9.8 11.9-9.8V5l7 7-7 6.3v-3.5c-2.8 0-10.5 2.1-11.9 4.2z"/></svg>' +
|
17
15
|
"</button>"
|
18
16
|
},
|
19
17
|
share: {
|
@@ -39,7 +37,7 @@
|
|
39
37
|
"<span>Pinterest</span>" +
|
40
38
|
"</a>" +
|
41
39
|
"</p>" +
|
42
|
-
'<p><input class="fancybox-share__input" type="text" value="{{url_raw}}" /></p>' +
|
40
|
+
'<p><input class="fancybox-share__input" type="text" value="{{url_raw}}" onclick="select()" /></p>' +
|
43
41
|
"</div>"
|
44
42
|
}
|
45
43
|
});
|
@@ -85,6 +83,7 @@
|
|
85
83
|
src: instance.translate(instance, tpl),
|
86
84
|
type: "html",
|
87
85
|
opts: {
|
86
|
+
touch: false,
|
88
87
|
animationEffect: false,
|
89
88
|
afterLoad: function(shareInstance, shareCurrent) {
|
90
89
|
// Close self if parent instance is closing
|
@@ -93,12 +92,15 @@
|
|
93
92
|
});
|
94
93
|
|
95
94
|
// Opening links in a popup window
|
96
|
-
shareCurrent.$content.find(".fancybox-
|
95
|
+
shareCurrent.$content.find(".fancybox-share__button").click(function() {
|
97
96
|
window.open(this.href, "Share", "width=550, height=450");
|
98
97
|
return false;
|
99
98
|
});
|
99
|
+
},
|
100
|
+
mobile: {
|
101
|
+
autoFocus: false
|
100
102
|
}
|
101
103
|
}
|
102
104
|
});
|
103
105
|
});
|
104
|
-
})(document,
|
106
|
+
})(document, jQuery);
|
@@ -14,15 +14,14 @@
|
|
14
14
|
btnTpl: {
|
15
15
|
slideShow:
|
16
16
|
'<button data-fancybox-play class="fancybox-button fancybox-button--play" title="{{PLAY_START}}">' +
|
17
|
-
'<svg viewBox="0 0
|
18
|
-
'<path d="
|
19
|
-
'<path d="M15,10 v19 M23,10 v19" />' +
|
20
|
-
"</svg>" +
|
17
|
+
'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M6.5 5.4v13.2l11-6.6z"/></svg>' +
|
18
|
+
'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M8.33 5.75h2.2v12.5h-2.2V5.75zm5.15 0h2.2v12.5h-2.2V5.75z"/></svg>' +
|
21
19
|
"</button>"
|
22
20
|
},
|
23
21
|
slideShow: {
|
24
22
|
autoStart: false,
|
25
|
-
speed: 3000
|
23
|
+
speed: 3000,
|
24
|
+
progress: true
|
26
25
|
}
|
27
26
|
});
|
28
27
|
|
@@ -37,35 +36,45 @@
|
|
37
36
|
$button: null,
|
38
37
|
|
39
38
|
init: function() {
|
40
|
-
var self = this
|
39
|
+
var self = this,
|
40
|
+
instance = self.instance,
|
41
|
+
opts = instance.group[instance.currIndex].opts.slideShow;
|
41
42
|
|
42
|
-
self.$button =
|
43
|
+
self.$button = instance.$refs.toolbar.find("[data-fancybox-play]").on("click", function() {
|
43
44
|
self.toggle();
|
44
45
|
});
|
45
46
|
|
46
|
-
if (
|
47
|
+
if (instance.group.length < 2 || !opts) {
|
47
48
|
self.$button.hide();
|
49
|
+
} else if (opts.progress) {
|
50
|
+
self.$progress = $('<div class="fancybox-progress"></div>').appendTo(instance.$refs.inner);
|
48
51
|
}
|
49
52
|
},
|
50
53
|
|
51
54
|
set: function(force) {
|
52
|
-
var self = this
|
55
|
+
var self = this,
|
56
|
+
instance = self.instance,
|
57
|
+
current = instance.current;
|
53
58
|
|
54
59
|
// Check if reached last element
|
55
|
-
if (
|
56
|
-
self.
|
57
|
-
|
58
|
-
|
59
|
-
) {
|
60
|
-
self.timer = setTimeout(function() {
|
61
|
-
if (self.isActive) {
|
62
|
-
self.instance.jumpTo((self.instance.currIndex + 1) % self.instance.group.length);
|
60
|
+
if (current && (force === true || current.opts.loop || instance.currIndex < instance.group.length - 1)) {
|
61
|
+
if (self.isActive && current.contentType !== "video") {
|
62
|
+
if (self.$progress) {
|
63
|
+
$.fancybox.animate(self.$progress.show(), {scaleX: 1}, current.opts.slideShow.speed);
|
63
64
|
}
|
64
|
-
|
65
|
+
|
66
|
+
self.timer = setTimeout(function() {
|
67
|
+
if (!instance.current.opts.loop && instance.current.index == instance.group.length - 1) {
|
68
|
+
instance.jumpTo(0);
|
69
|
+
} else {
|
70
|
+
instance.next();
|
71
|
+
}
|
72
|
+
}, current.opts.slideShow.speed);
|
73
|
+
}
|
65
74
|
} else {
|
66
75
|
self.stop();
|
67
|
-
|
68
|
-
|
76
|
+
instance.idleSecondsCounter = 0;
|
77
|
+
instance.showControls();
|
69
78
|
}
|
70
79
|
},
|
71
80
|
|
@@ -75,36 +84,50 @@
|
|
75
84
|
clearTimeout(self.timer);
|
76
85
|
|
77
86
|
self.timer = null;
|
87
|
+
|
88
|
+
if (self.$progress) {
|
89
|
+
self.$progress.removeAttr("style").hide();
|
90
|
+
}
|
78
91
|
},
|
79
92
|
|
80
93
|
start: function() {
|
81
|
-
var self = this
|
82
|
-
|
94
|
+
var self = this,
|
95
|
+
current = self.instance.current;
|
83
96
|
|
84
97
|
if (current) {
|
85
|
-
self.isActive = true;
|
86
|
-
|
87
98
|
self.$button
|
88
|
-
.attr("title", current.opts.i18n[current.opts.lang].PLAY_STOP)
|
99
|
+
.attr("title", (current.opts.i18n[current.opts.lang] || current.opts.i18n.en).PLAY_STOP)
|
89
100
|
.removeClass("fancybox-button--play")
|
90
101
|
.addClass("fancybox-button--pause");
|
91
102
|
|
92
|
-
self.
|
103
|
+
self.isActive = true;
|
104
|
+
|
105
|
+
if (current.isComplete) {
|
106
|
+
self.set(true);
|
107
|
+
}
|
108
|
+
|
109
|
+
self.instance.trigger("onSlideShowChange", true);
|
93
110
|
}
|
94
111
|
},
|
95
112
|
|
96
113
|
stop: function() {
|
97
|
-
var self = this
|
98
|
-
|
114
|
+
var self = this,
|
115
|
+
current = self.instance.current;
|
99
116
|
|
100
117
|
self.clear();
|
101
118
|
|
102
119
|
self.$button
|
103
|
-
.attr("title", current.opts.i18n[current.opts.lang].PLAY_START)
|
120
|
+
.attr("title", (current.opts.i18n[current.opts.lang] || current.opts.i18n.en).PLAY_START)
|
104
121
|
.removeClass("fancybox-button--pause")
|
105
122
|
.addClass("fancybox-button--play");
|
106
123
|
|
107
124
|
self.isActive = false;
|
125
|
+
|
126
|
+
self.instance.trigger("onSlideShowChange", false);
|
127
|
+
|
128
|
+
if (self.$progress) {
|
129
|
+
self.$progress.removeAttr("style").hide();
|
130
|
+
}
|
108
131
|
},
|
109
132
|
|
110
133
|
toggle: function() {
|
@@ -167,8 +190,8 @@
|
|
167
190
|
|
168
191
|
// Page Visibility API to pause slideshow when window is not active
|
169
192
|
$(document).on("visibilitychange", function() {
|
170
|
-
var instance = $.fancybox.getInstance()
|
171
|
-
|
193
|
+
var instance = $.fancybox.getInstance(),
|
194
|
+
SlideShow = instance && instance.SlideShow;
|
172
195
|
|
173
196
|
if (SlideShow && SlideShow.isActive) {
|
174
197
|
if (document.hidden) {
|
@@ -178,4 +201,4 @@
|
|
178
201
|
}
|
179
202
|
}
|
180
203
|
});
|
181
|
-
})(document,
|
204
|
+
})(document, jQuery);
|