jquery-colorbox-rails 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ba8f0f2324beef0f3c0da1fc30c5e1abb9c347dd
|
4
|
+
data.tar.gz: c22c6d648901f35bea1dce57137f29e99504863b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 93e2b7417ffbb0f509c972a323899c33d5b614ce7dff498dcc3c91c8fd478e3dc98541d2b9886b73b2d3c70e0202b5b77b37de48ed045ba05c1cae4de56712ee
|
7
|
+
data.tar.gz: bc2701e14bf11676eb2cec7f81c237159b0c97ba5f2f1b3fffc22db89230e62140e4518b697df815e95e1ef2cf0c59e6ccef064ff7dad83819d0ba849e77c954
|
data/README.md
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
jquery-colorbox-rails integrates [jquery.colorbox](https://github.com/jackmoore/colorbox) with rails 3.1+ asset pipeline.
|
4
4
|
|
5
|
-
Integrated colorbox version: <b id="colorbox-version">1.4.
|
5
|
+
Integrated colorbox version: <b id="colorbox-version">1.4.31</b>
|
6
6
|
|
7
7
|
### Installation
|
8
8
|
|
@@ -0,0 +1,13 @@
|
|
1
|
+
/*
|
2
|
+
jQuery Colorbox language configuration
|
3
|
+
language: Galician (gl)
|
4
|
+
translated by: donatorouco
|
5
|
+
*/
|
6
|
+
jQuery.extend(jQuery.colorbox.settings, {
|
7
|
+
current: "Imaxe {current} de {total}",
|
8
|
+
previous: "Anterior",
|
9
|
+
next: "Seguinte",
|
10
|
+
close: "Pechar",
|
11
|
+
xhrError: "Erro na carga do contido.",
|
12
|
+
imgError: "Erro na carga da imaxe."
|
13
|
+
});
|
@@ -0,0 +1,16 @@
|
|
1
|
+
/*
|
2
|
+
jQuery ColorBox language configuration
|
3
|
+
language: Ukrainian (uk)
|
4
|
+
translated by: Andrew
|
5
|
+
http://acisoftware.com.ua
|
6
|
+
*/
|
7
|
+
jQuery.extend(jQuery.colorbox.settings, {
|
8
|
+
current: "зображення {current} з {total}",
|
9
|
+
previous: "попереднє",
|
10
|
+
next: "наступне",
|
11
|
+
close: "закрити",
|
12
|
+
xhrError: "Не вдалося завантажити вміст.",
|
13
|
+
imgError: "Не вдалося завантажити зображення.",
|
14
|
+
slideshowStart: "почати слайд-шоу",
|
15
|
+
slideshowStop: "зупинити слайд-шоу"
|
16
|
+
});
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/*!
|
2
|
-
Colorbox v1.4.
|
2
|
+
Colorbox v1.4.31 - 2013-09-25
|
3
3
|
jQuery lightbox and modal window plugin
|
4
4
|
(c) 2013 Jack Moore - http://www.jacklmoore.com/colorbox
|
5
5
|
license: http://www.opensource.org/licenses/mit-license.php
|
@@ -9,6 +9,13 @@
|
|
9
9
|
// Default settings object.
|
10
10
|
// See http://jacklmoore.com/colorbox for details.
|
11
11
|
defaults = {
|
12
|
+
// data sources
|
13
|
+
html: false,
|
14
|
+
photo: false,
|
15
|
+
iframe: false,
|
16
|
+
inline: false,
|
17
|
+
|
18
|
+
// behavior and appearance
|
12
19
|
transition: "elastic",
|
13
20
|
speed: 300,
|
14
21
|
fadeOut: 300,
|
@@ -22,17 +29,32 @@
|
|
22
29
|
maxHeight: false,
|
23
30
|
scalePhotos: true,
|
24
31
|
scrolling: true,
|
25
|
-
inline: false,
|
26
|
-
html: false,
|
27
|
-
iframe: false,
|
28
|
-
fastIframe: true,
|
29
|
-
photo: false,
|
30
32
|
href: false,
|
31
33
|
title: false,
|
32
34
|
rel: false,
|
33
35
|
opacity: 0.9,
|
34
36
|
preloading: true,
|
35
37
|
className: false,
|
38
|
+
overlayClose: true,
|
39
|
+
escKey: true,
|
40
|
+
arrowKey: true,
|
41
|
+
top: false,
|
42
|
+
bottom: false,
|
43
|
+
left: false,
|
44
|
+
right: false,
|
45
|
+
fixed: false,
|
46
|
+
data: undefined,
|
47
|
+
closeButton: true,
|
48
|
+
fastIframe: true,
|
49
|
+
open: false,
|
50
|
+
reposition: true,
|
51
|
+
loop: true,
|
52
|
+
slideshow: false,
|
53
|
+
slideshowAuto: true,
|
54
|
+
slideshowSpeed: 2500,
|
55
|
+
slideshowStart: "start slideshow",
|
56
|
+
slideshowStop: "stop slideshow",
|
57
|
+
photoRegex: /\.(gif|png|jp(e|g|eg)|bmp|ico|webp)((#|\?).*)?$/i,
|
36
58
|
|
37
59
|
// alternate image paths for high-res displays
|
38
60
|
retinaImage: false,
|
@@ -47,34 +69,16 @@
|
|
47
69
|
xhrError: "This content failed to load.",
|
48
70
|
imgError: "This image failed to load.",
|
49
71
|
|
50
|
-
|
72
|
+
// accessbility
|
51
73
|
returnFocus: true,
|
52
74
|
trapFocus: true,
|
53
|
-
reposition: true,
|
54
|
-
loop: true,
|
55
|
-
slideshow: false,
|
56
|
-
slideshowAuto: true,
|
57
|
-
slideshowSpeed: 2500,
|
58
|
-
slideshowStart: "start slideshow",
|
59
|
-
slideshowStop: "stop slideshow",
|
60
|
-
photoRegex: /\.(gif|png|jp(e|g|eg)|bmp|ico|webp)((#|\?).*)?$/i,
|
61
75
|
|
76
|
+
// callbacks
|
62
77
|
onOpen: false,
|
63
78
|
onLoad: false,
|
64
79
|
onComplete: false,
|
65
80
|
onCleanup: false,
|
66
|
-
onClosed: false
|
67
|
-
|
68
|
-
overlayClose: true,
|
69
|
-
escKey: true,
|
70
|
-
arrowKey: true,
|
71
|
-
top: false,
|
72
|
-
bottom: false,
|
73
|
-
left: false,
|
74
|
-
right: false,
|
75
|
-
fixed: false,
|
76
|
-
data: undefined,
|
77
|
-
closeButton: true
|
81
|
+
onClosed: false
|
78
82
|
},
|
79
83
|
|
80
84
|
// Abstracting the HTML and event identifiers for easy rebranding
|
@@ -230,13 +234,12 @@
|
|
230
234
|
}
|
231
235
|
}
|
232
236
|
|
233
|
-
|
237
|
+
|
234
238
|
var slideshow = (function(){
|
235
|
-
var
|
236
|
-
|
237
|
-
|
238
|
-
|
239
|
-
timeOut;
|
239
|
+
var active,
|
240
|
+
className = prefix + "Slideshow_",
|
241
|
+
click = "click." + prefix,
|
242
|
+
timeOut;
|
240
243
|
|
241
244
|
function clear () {
|
242
245
|
clearTimeout(timeOut);
|
@@ -257,20 +260,18 @@
|
|
257
260
|
|
258
261
|
$events
|
259
262
|
.bind(event_complete, set)
|
260
|
-
.bind(event_load, clear)
|
261
|
-
.bind(event_cleanup, stop);
|
263
|
+
.bind(event_load, clear);
|
262
264
|
|
263
265
|
$box.removeClass(className + "off").addClass(className + "on");
|
264
266
|
}
|
265
|
-
|
267
|
+
|
266
268
|
function stop() {
|
267
269
|
clear();
|
268
270
|
|
269
271
|
$events
|
270
272
|
.unbind(event_complete, set)
|
271
|
-
.unbind(event_load, clear)
|
272
|
-
|
273
|
-
|
273
|
+
.unbind(event_load, clear);
|
274
|
+
|
274
275
|
$slideshow
|
275
276
|
.html(settings.slideshowStart)
|
276
277
|
.unbind(click)
|
@@ -282,32 +283,36 @@
|
|
282
283
|
$box.removeClass(className + "on").addClass(className + "off");
|
283
284
|
}
|
284
285
|
|
285
|
-
|
286
|
-
|
287
|
-
|
288
|
-
|
289
|
-
|
290
|
-
|
291
|
-
|
292
|
-
|
293
|
-
|
294
|
-
.unbind(event_complete, set)
|
295
|
-
.unbind(event_load, clear)
|
296
|
-
.unbind(event_cleanup, stop);
|
297
|
-
$box.removeClass(className + "off " + className + "on");
|
298
|
-
}
|
299
|
-
} else if (settings.slideshow && $related[1]) {
|
300
|
-
ssActive = true;
|
286
|
+
function reset() {
|
287
|
+
active = false;
|
288
|
+
$slideshow.hide();
|
289
|
+
clear();
|
290
|
+
$events
|
291
|
+
.unbind(event_complete, set)
|
292
|
+
.unbind(event_load, clear);
|
293
|
+
$box.removeClass(className + "off " + className + "on");
|
294
|
+
}
|
301
295
|
|
302
|
-
|
303
|
-
|
304
|
-
|
305
|
-
|
296
|
+
return function(){
|
297
|
+
if (active) {
|
298
|
+
if (!settings.slideshow) {
|
299
|
+
$events.unbind(event_cleanup, reset);
|
300
|
+
reset();
|
301
|
+
}
|
302
|
+
} else {
|
303
|
+
if (settings.slideshow && $related[1]) {
|
304
|
+
active = true;
|
305
|
+
$events.one(event_cleanup, reset);
|
306
|
+
if (settings.slideshowAuto) {
|
307
|
+
start();
|
308
|
+
} else {
|
309
|
+
stop();
|
310
|
+
}
|
311
|
+
$slideshow.show();
|
306
312
|
}
|
307
|
-
|
308
|
-
$slideshow.show();
|
309
313
|
}
|
310
314
|
};
|
315
|
+
|
311
316
|
}());
|
312
317
|
|
313
318
|
|
@@ -377,10 +382,11 @@
|
|
377
382
|
interfaceWidth = $leftBorder.width() + $rightBorder.width() + $content.outerWidth(true) - $content.width();
|
378
383
|
loadedHeight = $loaded.outerHeight(true);
|
379
384
|
loadedWidth = $loaded.outerWidth(true);
|
380
|
-
|
385
|
+
|
381
386
|
// Opens inital empty Colorbox prior to content being loaded.
|
382
387
|
settings.w = setSize(settings.initialWidth, 'x');
|
383
388
|
settings.h = setSize(settings.initialHeight, 'y');
|
389
|
+
$loaded.css({width:'', height:settings.h});
|
384
390
|
publicMethod.position();
|
385
391
|
|
386
392
|
trigger(event_open, settings.onOpen);
|
@@ -409,7 +415,6 @@
|
|
409
415
|
});
|
410
416
|
}
|
411
417
|
}
|
412
|
-
|
413
418
|
load();
|
414
419
|
}
|
415
420
|
}
|
@@ -948,7 +953,12 @@
|
|
948
953
|
return;
|
949
954
|
}
|
950
955
|
|
951
|
-
|
956
|
+
$.each(['alt', 'longdesc', 'aria-describedby'], function(i,val){
|
957
|
+
var attr = $(element).attr(val) || $(element).attr('data-'+val);
|
958
|
+
if (attr) {
|
959
|
+
photo.setAttribute(val, attr);
|
960
|
+
}
|
961
|
+
});
|
952
962
|
|
953
963
|
if (settings.retinaImage && window.devicePixelRatio > 1) {
|
954
964
|
photo.height = photo.height / window.devicePixelRatio;
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jquery-colorbox-rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Krzysztof Knapik
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-
|
11
|
+
date: 2013-10-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: railties
|
@@ -58,6 +58,7 @@ files:
|
|
58
58
|
- vendor/assets/javascripts/jquery.colorbox-fa.js
|
59
59
|
- vendor/assets/javascripts/jquery.colorbox-fi.js
|
60
60
|
- vendor/assets/javascripts/jquery.colorbox-fr.js
|
61
|
+
- vendor/assets/javascripts/jquery.colorbox-gl.js
|
61
62
|
- vendor/assets/javascripts/jquery.colorbox-he.js
|
62
63
|
- vendor/assets/javascripts/jquery.colorbox-hr.js
|
63
64
|
- vendor/assets/javascripts/jquery.colorbox-hu.js
|
@@ -76,6 +77,7 @@ files:
|
|
76
77
|
- vendor/assets/javascripts/jquery.colorbox-sk.js
|
77
78
|
- vendor/assets/javascripts/jquery.colorbox-sv.js
|
78
79
|
- vendor/assets/javascripts/jquery.colorbox-tr.js
|
80
|
+
- vendor/assets/javascripts/jquery.colorbox-uk.js
|
79
81
|
- vendor/assets/javascripts/jquery.colorbox-zh-CN.js
|
80
82
|
- vendor/assets/javascripts/jquery.colorbox.js
|
81
83
|
- vendor/assets/stylesheets/jquery.colorbox-example1.css.scss
|