Skip to content

Commit a57b035

Browse files
committed
formatting
1 parent 4b4ed89 commit a57b035

17 files changed

+928
-895
lines changed

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
PACE
22
====
3-
[![Latest Release](https://img.shields.io/github/tag/CodeByZach/pace.svg?label=version)](https://github.com/CodeByZach/pace/releases)
3+
[![Latest Release](https://img.shields.io/github/tag/CodeByZach/pace.svg?label=version)](https://github.com/CodeByZach/pace/releases/latest)
44

55
An automatic web page progress bar.
66

@@ -22,8 +22,8 @@ Example
2222

2323
```html
2424
<head>
25-
<script src="/pace/pace.js"></script>
26-
<link href="/pace/themes/pace-theme-barber-shop.css" rel="stylesheet" />
25+
<script src="https://cdnjs.cloudflare.com/ajax/libs/pace/1.2.3/pace.min.js"></script>
26+
<link href="https://cdnjs.cloudflare.com/ajax/libs/pace/1.2.3/pace-theme-default.min.css" rel="stylesheet" />
2727
</head>
2828
```
2929

@@ -130,7 +130,7 @@ may never appear:
130130
```javascript
131131
paceOptions = {
132132
elements: {
133-
selectors: ['.timeline,.timeline-error', '.user-profile,.profile-error']
133+
selectors: ['.timeline, .timeline-error', '.user-profile, .profile-error']
134134
}
135135
}
136136
```
@@ -222,15 +222,15 @@ Pace.options = {
222222
You can manually disable tracking for a specific request or requests by triggering them within a `Pace.ignore` callback:
223223

224224
```javascript
225-
Pace.ignore(function(){
225+
Pace.ignore(function() {
226226
$.ajax(...)
227227
});
228228
```
229229

230230
You can force the progress bar to be shown for a specific request by triggering them within a `Pace.track` callback:
231231

232232
```javascript
233-
Pace.track(function(){
233+
Pace.track(function() {
234234
$.ajax(...)
235235
});
236236
```

package.json

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
{
2+
"name": "pace",
3+
"version": "1.2.3",
4+
"description": "Automatically add a progress bar to your site.",
5+
"homepage": "https://codebyzach.github.io/pace/",
6+
"authors": [
7+
"CodeByZach <[email protected]>",
8+
],
9+
"keywords": [
10+
"pace",
11+
"pace-js",
12+
"pace.js",
13+
"progress-bar",
14+
"loading-bar",
15+
"loading-indicator",
16+
"loading-animation"
17+
],
18+
"license": "MIT",
19+
"main": "pace.js",
20+
"repository": {
21+
"type": "git",
22+
"url": "https://github.com/CodeByZach/pace/"
23+
},
24+
"devDependencies": {
25+
"grunt-contrib-coffee": "~0.7.0",
26+
"coffee-script": "~1.6.3",
27+
"grunt-contrib-uglify": "~0.2.4",
28+
"grunt-cli": "~0.1.9",
29+
"grunt": "~0.4.1",
30+
"grunt-contrib-watch": "~0.5.3",
31+
"color": "~0.4.4"
32+
}
33+
}
Lines changed: 58 additions & 58 deletions
Original file line numberDiff line numberDiff line change
@@ -1,84 +1,84 @@
11
.pace {
2-
-webkit-pointer-events: none;
3-
pointer-events: none;
2+
-webkit-pointer-events: none;
3+
pointer-events: none;
44

5-
-webkit-user-select: none;
6-
-moz-user-select: none;
7-
user-select: none;
5+
-webkit-user-select: none;
6+
-moz-user-select: none;
7+
user-select: none;
88

9-
overflow: hidden;
10-
position: fixed;
11-
top: 0;
12-
left: 0;
13-
z-index: 2000;
14-
width: 100%;
15-
height: 12px;
16-
background: #fff;
9+
overflow: hidden;
10+
position: fixed;
11+
top: 0;
12+
left: 0;
13+
z-index: 2000;
14+
width: 100%;
15+
height: 12px;
16+
background: #fff;
1717
}
1818

1919
.pace-inactive {
20-
display: none;
20+
display: none;
2121
}
2222

2323
.pace .pace-progress {
24-
background-color: `args.color || "#29d"`;
25-
position: fixed;
26-
top: 0;
27-
bottom: 0;
28-
right: 100%;
29-
width: 100%;
30-
overflow: hidden;
31-
height: 12px;
24+
background-color: `args.color || "#29d"`;
25+
position: fixed;
26+
top: 0;
27+
bottom: 0;
28+
right: 100%;
29+
width: 100%;
30+
overflow: hidden;
31+
height: 12px;
3232
}
3333

3434
.pace .pace-activity {
35-
position: fixed;
36-
top: 0;
37-
right: -32px;
38-
bottom: 0;
39-
left: 0;
40-
height: 12px;
35+
position: fixed;
36+
top: 0;
37+
right: -32px;
38+
bottom: 0;
39+
left: 0;
40+
height: 12px;
4141

42-
-webkit-transform: translate3d(0, 0, 0);
43-
-moz-transform: translate3d(0, 0, 0);
44-
-ms-transform: translate3d(0, 0, 0);
45-
-o-transform: translate3d(0, 0, 0);
46-
transform: translate3d(0, 0, 0);
42+
-webkit-transform: translate3d(0, 0, 0);
43+
-moz-transform: translate3d(0, 0, 0);
44+
-ms-transform: translate3d(0, 0, 0);
45+
-o-transform: translate3d(0, 0, 0);
46+
transform: translate3d(0, 0, 0);
4747

48-
background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.2)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.2)), color-stop(0.75, rgba(255, 255, 255, 0.2)), color-stop(0.75, transparent), to(transparent));
49-
background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.2) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.2) 50%, rgba(255, 255, 255, 0.2) 75%, transparent 75%, transparent);
50-
background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.2) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.2) 50%, rgba(255, 255, 255, 0.2) 75%, transparent 75%, transparent);
51-
background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.2) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.2) 50%, rgba(255, 255, 255, 0.2) 75%, transparent 75%, transparent);
52-
background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.2) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.2) 50%, rgba(255, 255, 255, 0.2) 75%, transparent 75%, transparent);
53-
-webkit-background-size: 32px 32px;
54-
-moz-background-size: 32px 32px;
55-
-o-background-size: 32px 32px;
56-
background-size: 32px 32px;
48+
background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.2)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.2)), color-stop(0.75, rgba(255, 255, 255, 0.2)), color-stop(0.75, transparent), to(transparent));
49+
background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.2) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.2) 50%, rgba(255, 255, 255, 0.2) 75%, transparent 75%, transparent);
50+
background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.2) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.2) 50%, rgba(255, 255, 255, 0.2) 75%, transparent 75%, transparent);
51+
background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.2) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.2) 50%, rgba(255, 255, 255, 0.2) 75%, transparent 75%, transparent);
52+
background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.2) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.2) 50%, rgba(255, 255, 255, 0.2) 75%, transparent 75%, transparent);
53+
-webkit-background-size: 32px 32px;
54+
-moz-background-size: 32px 32px;
55+
-o-background-size: 32px 32px;
56+
background-size: 32px 32px;
5757

58-
-webkit-animation: pace-theme-barber-shop-motion 500ms linear infinite;
59-
-moz-animation: pace-theme-barber-shop-motion 500ms linear infinite;
60-
-ms-animation: pace-theme-barber-shop-motion 500ms linear infinite;
61-
-o-animation: pace-theme-barber-shop-motion 500ms linear infinite;
62-
animation: pace-theme-barber-shop-motion 500ms linear infinite;
58+
-webkit-animation: pace-theme-barber-shop-motion 500ms linear infinite;
59+
-moz-animation: pace-theme-barber-shop-motion 500ms linear infinite;
60+
-ms-animation: pace-theme-barber-shop-motion 500ms linear infinite;
61+
-o-animation: pace-theme-barber-shop-motion 500ms linear infinite;
62+
animation: pace-theme-barber-shop-motion 500ms linear infinite;
6363
}
6464

6565
@-webkit-keyframes pace-theme-barber-shop-motion {
66-
0% { -webkit-transform: none; transform: none; }
67-
100% { -webkit-transform: translate(-32px, 0); transform: translate(-32px, 0); }
66+
0% { -webkit-transform: none; transform: none; }
67+
100% { -webkit-transform: translate(-32px, 0); transform: translate(-32px, 0); }
6868
}
6969
@-moz-keyframes pace-theme-barber-shop-motion {
70-
0% { -moz-transform: none; transform: none; }
71-
100% { -moz-transform: translate(-32px, 0); transform: translate(-32px, 0); }
70+
0% { -moz-transform: none; transform: none; }
71+
100% { -moz-transform: translate(-32px, 0); transform: translate(-32px, 0); }
7272
}
7373
@-o-keyframes pace-theme-barber-shop-motion {
74-
0% { -o-transform: none; transform: none; }
75-
100% { -o-transform: translate(-32px, 0); transform: translate(-32px, 0); }
74+
0% { -o-transform: none; transform: none; }
75+
100% { -o-transform: translate(-32px, 0); transform: translate(-32px, 0); }
7676
}
7777
@-ms-keyframes pace-theme-barber-shop-motion {
78-
0% { -ms-transform: none; transform: none; }
79-
100% { -ms-transform: translate(-32px, 0); transform: translate(-32px, 0); }
78+
0% { -ms-transform: none; transform: none; }
79+
100% { -ms-transform: translate(-32px, 0); transform: translate(-32px, 0); }
8080
}
8181
@keyframes pace-theme-barber-shop-motion {
82-
0% { transform: none; transform: none; }
83-
100% { transform: translate(-32px, 0); transform: translate(-32px, 0); }
84-
}
82+
0% { transform: none; transform: none; }
83+
100% { transform: translate(-32px, 0); transform: translate(-32px, 0); }
84+
}
Lines changed: 27 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,39 @@
11
.pace {
2-
-webkit-pointer-events: none;
3-
pointer-events: none;
2+
-webkit-pointer-events: none;
3+
pointer-events: none;
44

5-
-webkit-user-select: none;
6-
-moz-user-select: none;
7-
user-select: none;
5+
-webkit-user-select: none;
6+
-moz-user-select: none;
7+
user-select: none;
88
}
99

1010
.pace.pace-inactive .pace-progress {
11-
display: none;
11+
display: none;
1212
}
1313

1414
.pace .pace-progress {
15-
position: fixed;
16-
z-index: 2000;
17-
top: 0;
18-
right: 0;
19-
height: 5rem;
20-
width: 5rem;
15+
position: fixed;
16+
z-index: 2000;
17+
top: 0;
18+
right: 0;
19+
height: 5rem;
20+
width: 5rem;
2121

22-
-webkit-transform: translate3d(0, 0, 0) !important;
23-
-ms-transform: translate3d(0, 0, 0) !important;
24-
transform: translate3d(0, 0, 0) !important;
22+
-webkit-transform: translate3d(0, 0, 0) !important;
23+
-ms-transform: translate3d(0, 0, 0) !important;
24+
transform: translate3d(0, 0, 0) !important;
2525
}
2626

2727
.pace .pace-progress:after {
28-
display: block;
29-
position: absolute;
30-
top: 0;
31-
right: .5rem;
32-
content: attr(data-progress-text);
33-
font-family: "Helvetica Neue", sans-serif;
34-
font-weight: 100;
35-
font-size: 5rem;
36-
line-height: 1;
37-
text-align: right;
38-
color: `Color(args.color || '#000').clearer(0.8).rgbString()`;
39-
}
28+
display: block;
29+
position: absolute;
30+
top: 0;
31+
right: .5rem;
32+
content: attr(data-progress-text);
33+
font-family: "Helvetica Neue", sans-serif;
34+
font-weight: 100;
35+
font-size: 5rem;
36+
line-height: 1;
37+
text-align: right;
38+
color: `Color(args.color || '#000').clearer(0.8).rgbString()`;
39+
}

0 commit comments

Comments
 (0)