nprogress-rails 0.1.6.8 → 0.2.0.0

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: 3ea59164160674c8e4fcfb89c9918025dec6ca0d
4
- data.tar.gz: 8eb7d6f1fe0816f0bc49010eac404a9fcb9936ad
3
+ metadata.gz: e798aac8702558cc874502a85556b400bf844ca7
4
+ data.tar.gz: 1e81cd0e412cb615363bdc059b49b3bbb5a9408f
5
5
  SHA512:
6
- metadata.gz: e306e7c60ef9bd64edf285f12c0f4df10c3334f469de9b0d6d6cec9e2f6ea969b13088c4512f3ebac022032461c8439de76c8d7a3fb140109954eb3621c53f7b
7
- data.tar.gz: 1fc1dd9d039ee898d7f773a07ebd4a3a3f3cbf96fd4ab346bf46dc06cfd68ce88f0f480ca90915d0d7ccfe52d1dd702f4ac99634e17d7d4d5891fee1fc5ce30e
6
+ metadata.gz: fa14ed602490855b02e26057c3c96a9b23ce88bc0a35cd918d7c19a08794a84fb5e09a59db89d36006a225c6c2a0a8cee5da8c5298d74af29519e1cbbfff2366
7
+ data.tar.gz: 065a6cf69c429e95dc7568b2696061f2bd55fa441d202df37d4fd67c9032b290b08c25b849b5f654aa296761da735bc2e05479f4d049e1004e4be1baa1582803
@@ -14,7 +14,7 @@
14
14
  })(this, function() {
15
15
  var NProgress = {};
16
16
 
17
- NProgress.version = '0.1.6';
17
+ NProgress.version = '0.2.0';
18
18
 
19
19
  var Settings = NProgress.settings = {
20
20
  minimum: 0.08,
@@ -83,16 +83,16 @@
83
83
 
84
84
  if (n === 1) {
85
85
  // Fade out
86
- css(progress, {
87
- transition: 'none',
88
- opacity: 1
86
+ css(progress, {
87
+ transition: 'none',
88
+ opacity: 1
89
89
  });
90
90
  progress.offsetWidth; /* Repaint */
91
91
 
92
92
  setTimeout(function() {
93
- css(progress, {
94
- transition: 'all ' + speed + 'ms linear',
95
- opacity: 0
93
+ css(progress, {
94
+ transition: 'all ' + speed + 'ms linear',
95
+ opacity: 0
96
96
  });
97
97
  setTimeout(function() {
98
98
  NProgress.remove();
@@ -178,37 +178,37 @@
178
178
  /**
179
179
  * Waits for all supplied jQuery promises and
180
180
  * increases the progress as the promises resolve.
181
- *
181
+ *
182
182
  * @param $promise jQUery Promise
183
183
  */
184
184
  (function() {
185
185
  var initial = 0, current = 0;
186
-
186
+
187
187
  NProgress.promise = function($promise) {
188
- if (!$promise || $promise.state() == "resolved") {
188
+ if (!$promise || $promise.state() === "resolved") {
189
189
  return this;
190
190
  }
191
-
192
- if (current == 0) {
191
+
192
+ if (current === 0) {
193
193
  NProgress.start();
194
194
  }
195
-
195
+
196
196
  initial++;
197
197
  current++;
198
-
198
+
199
199
  $promise.always(function() {
200
200
  current--;
201
- if (current == 0) {
201
+ if (current === 0) {
202
202
  initial = 0;
203
203
  NProgress.done();
204
204
  } else {
205
205
  NProgress.set((initial - current) / initial);
206
206
  }
207
207
  });
208
-
208
+
209
209
  return this;
210
210
  };
211
-
211
+
212
212
  })();
213
213
 
214
214
  /**
@@ -220,7 +220,7 @@
220
220
  if (NProgress.isRendered()) return document.getElementById('nprogress');
221
221
 
222
222
  addClass(document.documentElement, 'nprogress-busy');
223
-
223
+
224
224
  var progress = document.createElement('div');
225
225
  progress.id = 'nprogress';
226
226
  progress.innerHTML = Settings.template;
@@ -229,7 +229,7 @@
229
229
  perc = fromStart ? '-100' : toBarPerc(NProgress.status || 0),
230
230
  parent = document.querySelector(Settings.parent),
231
231
  spinner;
232
-
232
+
233
233
  css(bar, {
234
234
  transition: 'all 0 linear',
235
235
  transform: 'translate3d(' + perc + '%,0,0)'
@@ -254,7 +254,7 @@
254
254
 
255
255
  NProgress.remove = function() {
256
256
  removeClass(document.documentElement, 'nprogress-busy');
257
- removeClass(document.querySelector(Settings.parent), 'nprogress-custom-parent')
257
+ removeClass(document.querySelector(Settings.parent), 'nprogress-custom-parent');
258
258
  var progress = document.getElementById('nprogress');
259
259
  progress && removeElement(progress);
260
260
  };
@@ -340,7 +340,7 @@
340
340
 
341
341
  var queue = (function() {
342
342
  var pending = [];
343
-
343
+
344
344
  function next() {
345
345
  var fn = pending.shift();
346
346
  if (fn) {
@@ -355,10 +355,10 @@
355
355
  })();
356
356
 
357
357
  /**
358
- * (Internal) Applies css properties to an element, similar to the jQuery
358
+ * (Internal) Applies css properties to an element, similar to the jQuery
359
359
  * css method.
360
360
  *
361
- * While this helper does assist with vendor prefixed property names, it
361
+ * While this helper does assist with vendor prefixed property names, it
362
362
  * does not perform any manipulation of values prior to setting styles.
363
363
  */
364
364
 
@@ -399,7 +399,7 @@
399
399
 
400
400
  return function(element, properties) {
401
401
  var args = arguments,
402
- prop,
402
+ prop,
403
403
  value;
404
404
 
405
405
  if (args.length == 2) {
@@ -430,7 +430,7 @@
430
430
  var oldList = classList(element),
431
431
  newList = oldList + name;
432
432
 
433
- if (hasClass(oldList, name)) return;
433
+ if (hasClass(oldList, name)) return;
434
434
 
435
435
  // Trim the opening space.
436
436
  element.className = newList.substring(1);
@@ -454,8 +454,8 @@
454
454
  }
455
455
 
456
456
  /**
457
- * (Internal) Gets a space separated list of the class names on the element.
458
- * The list is wrapped with a single space on each end to facilitate finding
457
+ * (Internal) Gets a space separated list of the class names on the element.
458
+ * The list is wrapped with a single space on each end to facilitate finding
459
459
  * matches within the list.
460
460
  */
461
461
 
@@ -472,4 +472,4 @@
472
472
  }
473
473
 
474
474
  return NProgress;
475
- });
475
+ });
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
4
 
5
5
  Gem::Specification.new do |spec|
6
6
  spec.name = 'nprogress-rails'
7
- spec.version = '0.1.6.8'
7
+ spec.version = '0.2.0.0'
8
8
  spec.authors = ['Carlos Alexandro Becker']
9
9
  spec.email = ['caarlos0@gmail.com']
10
10
  spec.description = %q{This is a gem for the rstacruz' nprogress implementation. It's based on version nprogress 0.1.6.}
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nprogress-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.6.8
4
+ version: 0.2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Carlos Alexandro Becker