jquery-colorbox-rails 0.0.7 → 0.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 79930c768e466651d77e00307e60609c41fddd75
4
- data.tar.gz: aaf3cfe530c55ed42500a114b911ac98f40496d9
3
+ metadata.gz: 8b1cbb113169ded1c863bd449b1a257e4c2c43c9
4
+ data.tar.gz: a88d24971a9dc0a5c90ac402ef318e55958bd252
5
5
  SHA512:
6
- metadata.gz: 02cf81354ce9f02d19416bf258ed0ed6372acd3cb0bdcd6b0fed85f289a4844e65d978a704292011e2da8f2f54b71447e2b63f675230c072de7b95f0714d634d
7
- data.tar.gz: 7cb7f7d4e676cf3dd491081efaa09cc33f36467ce6da7d7bf9f4ccf9f433b38f56a75656ab0eaf0f976e3da24749de6e07f5d471757b8041ec4b66d21fb34daf
6
+ metadata.gz: 3ecd0516eef25ae9101e3ef1d35f0740bbc5ed8ce154497c218eb921f85b92a84f6b46c29be037230dd784c00061a89defe47b07e374a59794c6bd0033e569f8
7
+ data.tar.gz: 0f16084911f78e4992fbd2e4b3cb5e13878e8aa0b76100027db22e267dd11e39dbeb7ba9a45cddcf62bda0bdfbef69d7a8f8e90bffc0d5e5c98cd4fc499e3000
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.24</b>
5
+ Integrated colorbox version: <b id="colorbox-version">1.4.26</b>
6
6
 
7
7
  ### Installation
8
8
 
data/Rakefile CHANGED
@@ -9,6 +9,7 @@ task :update do
9
9
  [js_dir, css_dir, img_dir].each do |dir|
10
10
  FileUtils.rm_r(dir)
11
11
  FileUtils.mkdir(dir)
12
+ FileUtils.touch(File.join(dir, '.gitkeep'))
12
13
  end
13
14
 
14
15
  puts 'Updating source files...'
@@ -1,3 +1,3 @@
1
1
  module JqueryColorboxRails
2
- VERSION = "0.0.7"
3
- end
2
+ VERSION = "0.0.8"
3
+ end
@@ -0,0 +1,15 @@
1
+ /*
2
+ jQuery Colorbox language configuration
3
+ language: Estonian (et)
4
+ translated by: keevitaja
5
+ */
6
+ jQuery.extend(jQuery.colorbox.settings, {
7
+ current: "{current}/{total}",
8
+ previous: "eelmine",
9
+ next: "järgmine",
10
+ close: "sulge",
11
+ xhrError: "Sisu ei õnnestunud laadida.",
12
+ imgError: "Pilti ei õnnestunud laadida.",
13
+ slideshowStart: "Käivita slaidid",
14
+ slideshowStop: "Peata slaidid"
15
+ });
@@ -1,5 +1,5 @@
1
1
  /*!
2
- Colorbox v1.4.24 - 2013-06-24
2
+ Colorbox v1.4.26 - 2013-06-30
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
@@ -130,6 +130,7 @@
130
130
  div = "div",
131
131
  className,
132
132
  requests = 0,
133
+ previousCSS = {},
133
134
  init;
134
135
 
135
136
  // ****************
@@ -607,29 +608,41 @@
607
608
  }
608
609
 
609
610
  $box.css({top: offset.top, left: offset.left, visibility:'visible'});
610
-
611
- // setting the speed to 0 to reduce the delay between same-sized content.
612
- speed = ($box.width() === settings.w + loadedWidth && $box.height() === settings.h + loadedHeight) ? 0 : speed || 0;
613
611
 
614
612
  // this gives the wrapper plenty of breathing room so it's floated contents can move around smoothly,
615
613
  // but it has to be shrank down around the size of div#colorbox when it's done. If not,
616
614
  // it can invoke an obscure IE bug when using iframes.
617
615
  $wrap[0].style.width = $wrap[0].style.height = "9999px";
618
616
 
619
- function modalDimensions(that) {
620
- $topBorder[0].style.width = $bottomBorder[0].style.width = $content[0].style.width = (parseInt(that.style.width,10) - interfaceWidth)+'px';
621
- $content[0].style.height = $leftBorder[0].style.height = $rightBorder[0].style.height = (parseInt(that.style.height,10) - interfaceHeight)+'px';
617
+ function modalDimensions() {
618
+ $topBorder[0].style.width = $bottomBorder[0].style.width = $content[0].style.width = (parseInt($box[0].style.width,10) - interfaceWidth)+'px';
619
+ $content[0].style.height = $leftBorder[0].style.height = $rightBorder[0].style.height = (parseInt($box[0].style.height,10) - interfaceHeight)+'px';
622
620
  }
623
621
 
624
622
  css = {width: settings.w + loadedWidth + interfaceWidth, height: settings.h + loadedHeight + interfaceHeight, top: top, left: left};
625
623
 
626
- if(speed===0){ // temporary workaround to side-step jQuery-UI 1.8 bug (http://bugs.jquery.com/ticket/12273)
624
+ // setting the speed to 0 if the content hasn't changed size or position
625
+ if (speed) {
626
+ var tempSpeed = 0;
627
+ $.each(css, function(i){
628
+ if (css[i] !== previousCSS[i]) {
629
+ tempSpeed = speed;
630
+ return;
631
+ }
632
+ });
633
+ speed = tempSpeed;
634
+ }
635
+
636
+ previousCSS = css;
637
+
638
+ if (!speed) {
627
639
  $box.css(css);
628
640
  }
641
+
629
642
  $box.dequeue().animate(css, {
630
- duration: speed,
643
+ duration: speed || 0,
631
644
  complete: function () {
632
- modalDimensions(this);
645
+ modalDimensions();
633
646
 
634
647
  active = false;
635
648
 
@@ -647,9 +660,7 @@
647
660
  loadedCallback();
648
661
  }
649
662
  },
650
- step: function () {
651
- modalDimensions(this);
652
- }
663
+ step: modalDimensions
653
664
  });
654
665
  };
655
666
 
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.0.7
4
+ version: 0.0.8
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-06-25 00:00:00.000000000 Z
11
+ date: 2013-07-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: railties
@@ -54,6 +54,7 @@ files:
54
54
  - vendor/assets/javascripts/jquery.colorbox-da.js
55
55
  - vendor/assets/javascripts/jquery.colorbox-de.js
56
56
  - vendor/assets/javascripts/jquery.colorbox-es.js
57
+ - vendor/assets/javascripts/jquery.colorbox-et.js
57
58
  - vendor/assets/javascripts/jquery.colorbox-fa.js
58
59
  - vendor/assets/javascripts/jquery.colorbox-fi.js
59
60
  - vendor/assets/javascripts/jquery.colorbox-fr.js