2012-06-29 00:46:45 -04:00
|
|
|
//
|
|
|
|
// Progress bars
|
|
|
|
// --------------------------------------------------
|
2012-01-07 18:52:57 -05:00
|
|
|
|
|
|
|
|
2013-02-01 19:21:38 -05:00
|
|
|
// Bar animations
|
|
|
|
// -------------------------
|
2012-01-07 18:52:57 -05:00
|
|
|
|
|
|
|
// Webkit
|
2011-11-26 13:41:17 -05:00
|
|
|
@-webkit-keyframes progress-bar-stripes {
|
2012-03-15 13:11:17 -04:00
|
|
|
from { background-position: 40px 0; }
|
|
|
|
to { background-position: 0 0; }
|
2011-11-26 13:41:17 -05:00
|
|
|
}
|
|
|
|
|
2012-01-28 17:20:27 -05:00
|
|
|
// Firefox
|
2012-01-28 15:43:19 -05:00
|
|
|
@-moz-keyframes progress-bar-stripes {
|
2012-03-15 13:11:17 -04:00
|
|
|
from { background-position: 40px 0; }
|
|
|
|
to { background-position: 0 0; }
|
2012-01-28 15:43:19 -05:00
|
|
|
}
|
2011-11-26 13:41:17 -05:00
|
|
|
|
2012-03-10 21:03:59 -05:00
|
|
|
// IE9
|
|
|
|
@-ms-keyframes progress-bar-stripes {
|
2012-03-15 13:11:17 -04:00
|
|
|
from { background-position: 40px 0; }
|
|
|
|
to { background-position: 0 0; }
|
2012-03-10 21:03:59 -05:00
|
|
|
}
|
|
|
|
|
2012-03-24 13:53:27 -04:00
|
|
|
// Opera
|
|
|
|
@-o-keyframes progress-bar-stripes {
|
|
|
|
from { background-position: 0 0; }
|
|
|
|
to { background-position: 40px 0; }
|
|
|
|
}
|
|
|
|
|
2012-01-07 18:52:57 -05:00
|
|
|
// Spec
|
2011-11-26 13:41:17 -05:00
|
|
|
@keyframes progress-bar-stripes {
|
2012-03-15 13:11:17 -04:00
|
|
|
from { background-position: 40px 0; }
|
|
|
|
to { background-position: 0 0; }
|
2012-01-07 18:52:57 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-02-01 19:21:38 -05:00
|
|
|
// Bar itself
|
|
|
|
// -------------------------
|
2012-01-07 18:52:57 -05:00
|
|
|
|
|
|
|
// Outer container
|
2011-11-26 13:41:17 -05:00
|
|
|
.progress {
|
2012-01-27 23:17:03 -05:00
|
|
|
overflow: hidden;
|
2012-11-30 17:45:25 -05:00
|
|
|
height: @line-height-base;
|
|
|
|
margin-bottom: @line-height-base;
|
2013-02-01 19:21:38 -05:00
|
|
|
background-color: @progress-bg;
|
2012-11-30 17:45:25 -05:00
|
|
|
border-radius: @border-radius-base;
|
2013-01-16 18:19:55 -05:00
|
|
|
.box-shadow(inset 0 1px 2px rgba(0,0,0,.1));
|
2012-01-07 18:52:57 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
// Bar of progress
|
2013-02-01 19:21:38 -05:00
|
|
|
.progress-bar {
|
2013-01-16 18:19:55 -05:00
|
|
|
float: left;
|
2012-01-07 18:52:57 -05:00
|
|
|
width: 0%;
|
2012-07-02 17:21:26 -04:00
|
|
|
height: 100%;
|
2012-01-24 23:30:26 -05:00
|
|
|
font-size: 12px;
|
2013-01-16 18:19:55 -05:00
|
|
|
color: #fff;
|
2012-01-24 23:30:26 -05:00
|
|
|
text-align: center;
|
|
|
|
text-shadow: 0 -1px 0 rgba(0,0,0,.25);
|
2013-02-01 19:21:38 -05:00
|
|
|
background-color: @progress-bar-bg;
|
2012-01-07 18:52:57 -05:00
|
|
|
.box-shadow(inset 0 -1px 0 rgba(0,0,0,.15));
|
|
|
|
.box-sizing(border-box);
|
|
|
|
.transition(width .6s ease);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Striped bars
|
2013-02-01 19:21:38 -05:00
|
|
|
.progress-striped .progress-bar {
|
|
|
|
#gradient > .striped(@progress-bar-bg);
|
2012-01-18 02:52:49 -05:00
|
|
|
.background-size(40px 40px);
|
2012-01-07 18:52:57 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
// Call animation for the active one
|
2013-02-01 19:21:38 -05:00
|
|
|
.progress.active .progress-bar {
|
2012-01-07 18:52:57 -05:00
|
|
|
-webkit-animation: progress-bar-stripes 2s linear infinite;
|
|
|
|
-moz-animation: progress-bar-stripes 2s linear infinite;
|
2012-03-24 13:53:27 -04:00
|
|
|
-ms-animation: progress-bar-stripes 2s linear infinite;
|
|
|
|
-o-animation: progress-bar-stripes 2s linear infinite;
|
2012-01-07 18:52:57 -05:00
|
|
|
animation: progress-bar-stripes 2s linear infinite;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-02-01 19:21:38 -05:00
|
|
|
// Variations
|
|
|
|
// -------------------------
|
2012-01-07 18:52:57 -05:00
|
|
|
|
|
|
|
// Danger (red)
|
2013-02-01 19:21:38 -05:00
|
|
|
.progress-bar-danger {
|
|
|
|
background-color: @progress-bar-danger-bg;
|
|
|
|
.progress-striped & {
|
|
|
|
#gradient > .striped(@progress-bar-danger-bg);
|
|
|
|
}
|
2012-01-07 18:52:57 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
// Success (green)
|
2013-02-01 19:21:38 -05:00
|
|
|
.progress-bar-success {
|
|
|
|
background-color: @progress-bar-success-bg;
|
|
|
|
.progress-striped & {
|
|
|
|
#gradient > .striped(@progress-bar-success-bg);
|
|
|
|
}
|
2012-01-07 18:52:57 -05:00
|
|
|
}
|
2012-02-24 05:23:04 -05:00
|
|
|
|
|
|
|
// Warning (orange)
|
2013-02-01 19:21:38 -05:00
|
|
|
.progress-bar-warning {
|
|
|
|
background-color: @progress-bar-warning-bg;
|
|
|
|
.progress-striped & {
|
|
|
|
#gradient > .striped(@progress-bar-warning-bg);
|
|
|
|
}
|
2012-02-24 05:23:04 -05:00
|
|
|
}
|
2013-02-01 19:21:38 -05:00
|
|
|
|
|
|
|
// Info (teal)
|
|
|
|
.progress-bar-info {
|
|
|
|
background-color: @progress-bar-info-bg;
|
|
|
|
.progress-striped & {
|
|
|
|
#gradient > .striped(@progress-bar-info-bg);
|
|
|
|
}
|
2012-02-24 05:23:04 -05:00
|
|
|
}
|