aightbox-rails 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/aightbox/rails/version.rb +1 -1
- data/vendor/assets/javascripts/aightbox.js +16 -5
- data/vendor/assets/stylesheets/aightbox.css +7 -7
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 02b13015f94d98263eaa1827c93f4023db4bb4d8
|
4
|
+
data.tar.gz: bfc0fc7b73d8ec34675aa440576740eeb4777b7c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e1cbab2ae68e83c193c3b26d15da909426716649176d6c143a508e750c562aec4595d571cc3b96734807901625e09318903a0b0594af57452938c506dcdcdd39
|
7
|
+
data.tar.gz: 48460191a96109b192535db6d44068d0f64681c73c007d27e32126f120fc95c10f774f5e2e057b375f8eb58844113adfefe66e1d45516afbb3d29da2bcb71dad
|
data/README.md
CHANGED
@@ -16,6 +16,7 @@
|
|
16
16
|
$wrapper,
|
17
17
|
$container,
|
18
18
|
$currentImage,
|
19
|
+
$spinner,
|
19
20
|
bindEvents,
|
20
21
|
bindControls,
|
21
22
|
createImageContainer,
|
@@ -32,12 +33,14 @@
|
|
32
33
|
closeButton: 'aight-close',
|
33
34
|
carousel: false,
|
34
35
|
carouselGroup: true,
|
36
|
+
closeCharacter: 'x',
|
35
37
|
imageContainer: 'aight-container',
|
36
38
|
imageDescription: 'aight-description',
|
37
39
|
nextButton: 'aight-next',
|
38
40
|
nextCharacter: '>',
|
39
41
|
prevCharacter: '<',
|
40
42
|
prevButton: 'aight-prev',
|
43
|
+
spinnerClass: 'aight-progress small',
|
41
44
|
wrapper: 'aight-wrapper'
|
42
45
|
|
43
46
|
}, options);
|
@@ -49,11 +52,18 @@
|
|
49
52
|
template = '<div id="' + config.backdrop + '"></div>'+
|
50
53
|
'<div id="' + config.wrapper + '">'+
|
51
54
|
'<div id="' + config.imageContainer + '">' +
|
52
|
-
'<
|
53
|
-
'<a
|
54
|
-
'
|
55
|
+
'<div id="' + config.nextButton + '" >' +
|
56
|
+
'<a href="#">'+ config.nextCharacter +'</a>'+
|
57
|
+
'</div>' +
|
58
|
+
'<div id="' + config.prevButton + '">' +
|
59
|
+
'<a href="#">' + config.prevCharacter +'</a>'+
|
60
|
+
'</div>' +
|
61
|
+
'<div id="' + config.closeButton + '">' +
|
62
|
+
'<a href="#">' + config.closeCharacter + '</a>'+
|
63
|
+
'</div>' +
|
55
64
|
'<img src="" alt=""/>' +
|
56
65
|
'<p id="' + config.imageDescription + '"></p>'+
|
66
|
+
'<div class="' + config.spinnerClass +'" style="display: none;"><div>Loading…</div></div>' +
|
57
67
|
'</div>' +
|
58
68
|
'</div>';
|
59
69
|
|
@@ -177,6 +187,7 @@
|
|
177
187
|
$wrapper = $('#' + config.wrapper);
|
178
188
|
$container = $('#' + config.imageContainer);
|
179
189
|
$imageDesc = $('#' + config.imageDescription);
|
190
|
+
$spinner = $('#' + config.imageContainer + ' .' + config.spinnerClass.split(' ')[0] );
|
180
191
|
|
181
192
|
if($imageLinks.length === 1) {
|
182
193
|
$('#' + config.prevButton).hide();
|
@@ -250,11 +261,11 @@
|
|
250
261
|
|
251
262
|
$containerImage.hide();
|
252
263
|
$wrapper.fadeIn('slow');
|
253
|
-
$
|
264
|
+
$spinner.show();
|
254
265
|
|
255
266
|
$containerImage.one('load',function(){
|
256
267
|
|
257
|
-
$
|
268
|
+
$spinner.hide();
|
258
269
|
$containerImage.show();
|
259
270
|
|
260
271
|
if(imgDescription !== ''){
|
@@ -36,33 +36,33 @@
|
|
36
36
|
margin: 10px 0 0 0;
|
37
37
|
padding: 0; }
|
38
38
|
|
39
|
-
#aight-next, #aight-prev, #aight-close {
|
39
|
+
#aight-next a, #aight-prev a, #aight-close a {
|
40
40
|
position: absolute;
|
41
41
|
font-family: 'Helvetica';
|
42
42
|
font-weight: bold;
|
43
43
|
color: #ddd;
|
44
44
|
text-decoration: none; }
|
45
|
-
#aight-next:hover, #aight-prev:hover, #aight-close:hover {
|
45
|
+
#aight-next a:hover, #aight-prev a:hover, #aight-close a:hover {
|
46
46
|
color: #fff; }
|
47
47
|
|
48
|
-
#aight-next, #aight-prev {
|
48
|
+
#aight-next a, #aight-prev a {
|
49
49
|
font-size: 35px;
|
50
50
|
margin-top: -25px; }
|
51
51
|
|
52
|
-
#aight-close {
|
52
|
+
#aight-close a {
|
53
53
|
font-size: 25px; }
|
54
54
|
|
55
|
-
#aight-next {
|
55
|
+
#aight-next a {
|
56
56
|
top: 50%;
|
57
57
|
right: 0;
|
58
58
|
margin-right: -35px; }
|
59
59
|
|
60
|
-
#aight-prev {
|
60
|
+
#aight-prev a {
|
61
61
|
top: 50%;
|
62
62
|
left: 0;
|
63
63
|
margin-left: -35px; }
|
64
64
|
|
65
|
-
#aight-close {
|
65
|
+
#aight-close a {
|
66
66
|
top: 0;
|
67
67
|
right: 0;
|
68
68
|
margin-right: -25px;
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aightbox-rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Markus Waitl
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-03-
|
11
|
+
date: 2014-03-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -80,7 +80,7 @@ dependencies:
|
|
80
80
|
- - ~>
|
81
81
|
- !ruby/object:Gem::Version
|
82
82
|
version: '4.0'
|
83
|
-
description: Display single or group images.
|
83
|
+
description: Display single or group images in a lightbox.
|
84
84
|
email:
|
85
85
|
- axlwaii@gmail.com
|
86
86
|
executables: []
|
@@ -95,7 +95,7 @@ files:
|
|
95
95
|
- lib/aightbox/rails/version.rb
|
96
96
|
- vendor/assets/javascripts/aightbox.js
|
97
97
|
- vendor/assets/stylesheets/aightbox.css
|
98
|
-
homepage:
|
98
|
+
homepage: https://github.com/axlwaii/aightbox-rails
|
99
99
|
licenses:
|
100
100
|
- BEERWARE
|
101
101
|
metadata: {}
|