forked from jlong/css-spinners
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy paththrobber.scss
45 lines (39 loc) · 1.39 KB
/
throbber.scss
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
@import "compass/css3";
$throbber-loader-color: #dde2e7 !default;
$throbber-loader-highlight-color: #6b9dc8 !default;
$throbber-loader-height: 1.5em !default;
$throbber-loader-segment-width: 0.9em !default;
$throbber-loader-spacing: 0.7em !default;
@include keyframes(throbber-loader) {
0% { background: $throbber-loader-color }
10% { background: $throbber-loader-highlight-color }
40% { background: $throbber-loader-color }
}
/* :not(:required) hides these rules from IE9 and below */
.throbber-loader:not(:required) {
@include animation(throbber-loader 2000ms 300ms infinite ease-out);
background: $throbber-loader-color;
display: inline-block;
position: relative;
text-indent: -9999px;
width: $throbber-loader-segment-width;
height: $throbber-loader-height;
margin: 0 ($throbber-loader-segment-width + $throbber-loader-spacing);
&:before, &:after {
background: $throbber-loader-color;
content: '\x200B';
display: inline-block;
width: $throbber-loader-segment-width;
height: $throbber-loader-height;
position: absolute;
top: 0;
}
&:before {
@include animation(throbber-loader 2000ms 150ms infinite ease-out);
left: -($throbber-loader-segment-width + $throbber-loader-spacing);
}
&:after {
@include animation(throbber-loader 2000ms 450ms infinite ease-out);
right: -($throbber-loader-segment-width + $throbber-loader-spacing);
}
}