Skip to content
This repository was archived by the owner on Feb 1, 2026. It is now read-only.

Commit add0b62

Browse files
committed
preparing for next release
1 parent aaa908a commit add0b62

5 files changed

Lines changed: 22 additions & 18 deletions

File tree

README.md

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,15 @@
11
# nprogress_rails
22

33
This is basically a ruby gem for asset pipeline which includes the version
4-
0.1.0 of the awesome rstacruz' [nprogress](https://github.com/rstacruz/nprogress)
5-
library.
4+
0.1.0 of the awesome [rstacruz][rstacruz]' [nprogress][lib] library.
5+
6+
- [**Original lib**][lib]
7+
- [**Demo**][demo]
8+
9+
10+
[rstacruz]: https://github.com/rstacruz
11+
[lib]: https://github.com/rstacruz/nprogress
12+
[demo]: http://ricostacruz.com/nprogress/
613

714
## Installation
815

nprogress_rails.gemspec

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
44

55
Gem::Specification.new do |spec|
66
spec.name = "nprogress_rails"
7-
spec.version = "0.1.0.1"
7+
spec.version = "0.1.1.1"
88
spec.authors = ["Carlos Alexandro Becker"]
99
spec.email = ["caarlos0@gmail.com"]
1010
spec.description = %q{This is a gem for the rstacruz' nprogress implementation. It's based on version nprogress 0.1.0.}
1111
spec.summary = %q{Slim progress bars for Ajax'y applications. Inspired by Google, YouTube, and Medium.}
12-
spec.homepage = "http://carlosbecker.com/about"
12+
spec.homepage = "https://github.com/caarlos0/nprogress_rails"
1313
spec.license = "MIT"
1414

1515
spec.files = `git ls-files`.split($/)

vendor/assets/javascripts/nprogress.js

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
})(function($) {
1313
var NProgress = {};
1414

15-
NProgress.version = '0.1.0';
15+
NProgress.version = '0.1.1';
1616

1717
var Settings = NProgress.settings = {
1818
minimum: 0.08,
@@ -23,7 +23,7 @@
2323
trickleRate: 0.02,
2424
trickleSpeed: 800,
2525
showSpinner: true,
26-
template: '<div class="bar" role="bar"><div class="peg"></div></div><div class="spinner"><div class="spinner-icon"></div></div>'
26+
template: '<div class="bar" role="bar"><div class="peg"></div></div><div class="spinner" role="spinner"><div class="spinner-icon"></div></div>'
2727
};
2828

2929
/**
@@ -66,7 +66,7 @@
6666

6767
$progress.queue(function(next) {
6868
// Set positionUsing if it hasn't already been set
69-
if (Settings.positionUsing == '') Settings.positionUsing = NProgress.getPositioningCSS();
69+
if (Settings.positionUsing === '') Settings.positionUsing = NProgress.getPositioningCSS();
7070

7171
// Add transition
7272
$bar.css(barPositionCSS(n, speed, ease));
@@ -178,7 +178,8 @@
178178
transform: 'translate3d('+perc+'%,0,0)'
179179
});
180180

181-
if(!Settings.showSpinner) $el.find('.spinner').hide();
181+
if (!Settings.showSpinner)
182+
$el.find('[role="spinner"]').remove();
182183

183184
$el.appendTo(document.body);
184185

@@ -205,6 +206,7 @@
205206
/**
206207
* Determine which positioning CSS rule to use.
207208
*/
209+
208210
NProgress.getPositioningCSS = function() {
209211
// Sniff on document.body.style
210212
var bodyStyle = document.body.style;
@@ -225,7 +227,7 @@
225227
// Browsers without translate() support, e.g. IE7-8
226228
return 'margin';
227229
}
228-
}
230+
};
229231

230232
/**
231233
* Helpers
@@ -255,9 +257,9 @@
255257
function barPositionCSS(n, speed, ease) {
256258
var barCSS;
257259

258-
if (Settings.positionUsing == 'translate3d') {
260+
if (Settings.positionUsing === 'translate3d') {
259261
barCSS = { transform: 'translate3d('+toBarPerc(n)+'%,0,0)' };
260-
} else if (Settings.positionUsing == 'translate') {
262+
} else if (Settings.positionUsing === 'translate') {
261263
barCSS = { transform: 'translate('+toBarPerc(n)+'%,0)' };
262264
} else {
263265
barCSS = { 'margin-left': toBarPerc(n)+'%' };
@@ -270,4 +272,3 @@
270272

271273
return NProgress;
272274
});
273-

vendor/assets/stylesheets/nprogress.css

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,6 @@
44
-webkit-pointer-events: none;
55
}
66

7-
/* Make the entire page show a busy cursor */
8-
.nprogress-busy body {
9-
cursor: wait;
10-
}
11-
127
#nprogress .bar {
138
background: #29d;
149

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1-
#nprogress .bar {
1+
#nprogress .bar,
2+
#nprogress .spinner {
23
z-index: 999999;
34
}

0 commit comments

Comments
 (0)