You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

357 lines
7.1 KiB

10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
  1. /*
  2. * # Semantic - Progress Bar
  3. * http://github.com/semantic-org/semantic-ui/
  4. *
  5. *
  6. * Copyright 2014 Contributors
  7. * Released under the MIT license
  8. * http://opensource.org/licenses/MIT
  9. *
  10. */
  11. /*******************************
  12. Theme
  13. *******************************/
  14. @type : 'module';
  15. @element : 'progress';
  16. @import '../../semantic.config';
  17. .ui.progress {
  18. position: relative;
  19. display: block;
  20. max-width: 100%;
  21. border: @border;
  22. margin: @margin;
  23. box-shadow: @boxShadow;
  24. background: @background;
  25. padding: @padding;
  26. border-radius: @borderRadius;
  27. }
  28. .ui.progress:first-child {
  29. margin: @firstMargin;
  30. }
  31. .ui.progress:last-child {
  32. margin: @lastMargin;
  33. }
  34. /* Indicating */
  35. .ui.indicating.progress .bar[style^="width: 3"]{
  36. background-color: #D9A65C;
  37. }
  38. .ui.indicating.progress .bar[style^="width: 4"],
  39. .ui.indicating.progress .bar[style^="width: 5"] {
  40. background-color: #E6BB48;
  41. }
  42. .ui.indicating.progress .bar[style^="width: 6"] {
  43. background-color: #DDC928;
  44. }
  45. .ui.indicating.progress .bar[style^="width: 7"],
  46. .ui.indicating.progress .bar[style^="width: 8"] {
  47. background-color: #B4D95C;
  48. }
  49. .ui.indicating.progress .bar[style^="width: 9"],
  50. .ui.indicating.progress .bar[style^="width: 100"] {
  51. background-color: #66DA81;
  52. }
  53. /* Single Digits Last */
  54. .ui.indicating.progress .bar[style^="width: 1%"],
  55. .ui.indicating.progress .bar[style^="width: 2%"],
  56. .ui.indicating.progress .bar[style^="width: 3%"],
  57. .ui.indicating.progress .bar[style^="width: 4%"],
  58. .ui.indicating.progress .bar[style^="width: 5%"],
  59. .ui.indicating.progress .bar[style^="width: 6%"],
  60. .ui.indicating.progress .bar[style^="width: 7%"],
  61. .ui.indicating.progress .bar[style^="width: 8%"],
  62. .ui.indicating.progress .bar[style^="width: 9%"],
  63. .ui.indicating.progress .bar[style^="width: 1"],
  64. .ui.indicating.progress .bar[style^="width: 2"] {
  65. background-color: #D95C5C;
  66. }
  67. /*******************************
  68. Content
  69. *******************************/
  70. /* Activity Bar */
  71. .ui.progress .bar {
  72. display: block;
  73. line-height: 1;
  74. position: @barPosition;
  75. width: @barInitialWidth;
  76. min-width: @barMinWidth;
  77. height: @barHeight;
  78. background: @barBackground;
  79. border-radius: @barBorderRadius;
  80. transition: @barTransition;
  81. }
  82. /* Percent Complete */
  83. .ui.progress .bar > .progress {
  84. white-space: nowrap;
  85. position: absolute;
  86. width: @progressWidth;
  87. font-size: @progressSize;
  88. top: @progressTop;
  89. right: @progressRight;
  90. left: @progressLeft;
  91. bottom: @progressBottom;
  92. color: @progressColor;
  93. text-shadow: @progressTextShadow;
  94. margin-top: @progressOffset;
  95. font-weight: @progressFontWeight;
  96. text-align: @progressTextAlign;
  97. }
  98. /* Label */
  99. .ui.progress > .label {
  100. position: absolute;
  101. width: @labelWidth;
  102. font-size: @labelSize;
  103. top: @labelTop;
  104. right: @labelRight;
  105. left: @labelLeft;
  106. bottom: @labelBottom;
  107. color: @labelColor;
  108. font-weight: @labelFontWeight;
  109. text-shadow: @labelTextShadow;
  110. margin-top: @labelOffset;
  111. text-align: @labelTextAlign;
  112. transition: @labelTransition;
  113. }
  114. /*******************************
  115. States
  116. *******************************/
  117. /*--------------
  118. Success
  119. ---------------*/
  120. .ui.progress.success .bar {
  121. background-color: @successColor !important;
  122. }
  123. .ui.progress.success .bar,
  124. .ui.progress.success .bar::after {
  125. animation: none !important;
  126. }
  127. .ui.progress.success > .label {
  128. color: @successHeaderColor;
  129. }
  130. /*--------------
  131. Warning
  132. ---------------*/
  133. .ui.progress.warning .bar {
  134. background-color: @warningColor !important;
  135. }
  136. .ui.progress.warning .bar,
  137. .ui.progress.warning .bar::after {
  138. animation: none !important;
  139. }
  140. .ui.progress.warning > .label {
  141. color: @warningHeaderColor;
  142. }
  143. /*--------------
  144. Error
  145. ---------------*/
  146. .ui.progress.error .bar {
  147. background-color: @errorColor !important;
  148. }
  149. .ui.progress.error .bar,
  150. .ui.progress.error .bar::after {
  151. animation: none !important;
  152. }
  153. .ui.progress.error > .label {
  154. color: @errorHeaderColor;
  155. }
  156. /*--------------
  157. Active
  158. ---------------*/
  159. .ui.active.progress .bar {
  160. position: relative;
  161. }
  162. .ui.active.progress .bar::after {
  163. content: '';
  164. opacity: 0;
  165. position: absolute;
  166. top: 0px;
  167. left: 0px;
  168. right: 0px;
  169. bottom: 0px;
  170. background: @activePulseColor;
  171. border-radius: @barBorderRadius;
  172. animation: progress-active @activePulseDuration @defaultEasing infinite;
  173. }
  174. @keyframes progress-active {
  175. 0% {
  176. opacity: @activePulseMaxOpacity;
  177. width: 0;
  178. }
  179. 90% {
  180. }
  181. 100% {
  182. opacity: 0;
  183. width: 100%;
  184. }
  185. }
  186. /*--------------
  187. Disabled
  188. ---------------*/
  189. .ui.disabled.progress {
  190. opacity: 0.35;
  191. }
  192. .ui.disabled.progress .bar,
  193. .ui.disabled.progress .bar::after {
  194. animation: none !important;
  195. }
  196. /*******************************
  197. Variations
  198. *******************************/
  199. /*--------------
  200. Inverted
  201. ---------------*/
  202. /* bottom attached */
  203. .ui.inverted.progress {
  204. background: @invertedBackground;
  205. border: @invertedBorder;
  206. }
  207. .ui.inverted.progress .bar {
  208. background: @invertedBarBackground;
  209. }
  210. .ui.inverted.progress .bar > .progress {
  211. color: @invertedProgressColor;
  212. }
  213. .ui.inverted.progress > .label {
  214. color: @invertedLabelColor;
  215. }
  216. .ui.inverted.progress.success > .label {
  217. color: @successColor;
  218. }
  219. .ui.inverted.progress.warning > .label {
  220. color: @warningColor;
  221. }
  222. .ui.inverted.progress.error > .label {
  223. color: @errorColor;
  224. }
  225. /*--------------
  226. Attached
  227. ---------------*/
  228. /* bottom attached */
  229. .ui.progress.attached {
  230. background: none transparent;
  231. position: relative;
  232. border: none;
  233. margin: 0em;
  234. }
  235. .ui.progress.attached,
  236. .ui.progress.attached .bar {
  237. display: block;
  238. height: @attachedHeight;
  239. padding: 0px;
  240. overflow: hidden;
  241. border-radius: 0em 0em @attachedBorderRadius @attachedBorderRadius;
  242. }
  243. .ui.progress.attached .bar {
  244. border-radius: 0em;
  245. }
  246. /* top attached */
  247. .ui.progress.top.attached,
  248. .ui.progress.top.attached .bar {
  249. top: 0px;
  250. border-radius: @attachedBorderRadius @attachedBorderRadius 0em 0em;
  251. }
  252. .ui.progress.top.attached .bar {
  253. border-radius: 0em;
  254. }
  255. /*--------------
  256. Colors
  257. ---------------*/
  258. .ui.black.progress .bar {
  259. background-color: @black;
  260. }
  261. .ui.blue.progress .bar {
  262. background-color: @blue;
  263. }
  264. .ui.green.progress .bar {
  265. background-color: @green;
  266. }
  267. .ui.orange.progress .bar {
  268. background-color: @orange;
  269. }
  270. .ui.pink.progress .bar {
  271. background-color: @pink;
  272. }
  273. .ui.purple.progress .bar {
  274. background-color: @purple;
  275. }
  276. .ui.red.progress .bar {
  277. background-color: @red;
  278. }
  279. .ui.teal.progress .bar {
  280. background-color: @teal;
  281. }
  282. .ui.yellow.progress .bar {
  283. background-color: @yellow;
  284. }
  285. .ui.black.inverted.progress .bar {
  286. background-color: @lightBlack;
  287. }
  288. .ui.blue.inverted.progress .bar {
  289. background-color: @lightBlue;
  290. }
  291. .ui.green.inverted.progress .bar {
  292. background-color: @lightGreen;
  293. }
  294. .ui.orange.inverted.progress .bar {
  295. background-color: @lightOrange;
  296. }
  297. .ui.pink.inverted.progress .bar {
  298. background-color: @lightPink;
  299. }
  300. .ui.purple.inverted.progress .bar {
  301. background-color: @lightPurple;
  302. }
  303. .ui.red.inverted.progress .bar {
  304. background-color: @lightRed;
  305. }
  306. .ui.teal.inverted.progress .bar {
  307. background-color: @lightTeal;
  308. }
  309. .ui.yellow.inverted.progress .bar {
  310. background-color: @lightYellow;
  311. }
  312. /*--------------
  313. Sizes
  314. ---------------*/
  315. .ui.small.progress .bar {
  316. height: 14px;
  317. }