slider.css 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178
  1. /*!
  2. * Slider for Bootstrap
  3. *
  4. * Copyright 2012 Stefan Petre
  5. * Licensed under the Apache License v2.0
  6. * http://www.apache.org/licenses/LICENSE-2.0
  7. *
  8. */
  9. .slider {
  10. display: inline-block;
  11. vertical-align: middle;
  12. position: relative;
  13. margin-bottom: 10px
  14. }
  15. .slider[class*="span"] {
  16. float: none;
  17. margin-left: 0;
  18. }
  19. .slider-horizontal {
  20. width: 210px;
  21. height: 20px;
  22. }
  23. .slider-horizontal .slider-handle-container,
  24. .slider-horizontal .slider-track {
  25. height: 10px;
  26. margin-top: -5px;
  27. top: 50%;
  28. }
  29. .slider-horizontal .slider-track {
  30. left: 0;
  31. right: 0;
  32. }
  33. .slider-horizontal .slider-handle-container {
  34. left: 10px;
  35. right: 10px;
  36. }
  37. .slider-horizontal .slider-selection {
  38. height: 100%;
  39. top: 0;
  40. bottom: 0;
  41. }
  42. .slider-horizontal .slider-handle {
  43. margin-left: -10px;
  44. margin-top: -5px;
  45. }
  46. .slider-vertical {
  47. height: 210px;
  48. width: 20px;
  49. }
  50. .slider-vertical .slider-handle-container,
  51. .slider-vertical .slider-track {
  52. width: 10px;
  53. margin-left: -5px;
  54. left: 50%;
  55. }
  56. .slider-vertical .slider-track {
  57. top: 0;
  58. bottom: 0;
  59. }
  60. .slider-vertical .slider-handle-container {
  61. top: 10px;
  62. bottom: 10px;
  63. }
  64. .slider-vertical .slider-selection {
  65. width: 100%;
  66. left: 0;
  67. top: 0;
  68. bottom: 0;
  69. }
  70. .slider-vertical .slider-handle {
  71. margin-left: -5px;
  72. margin-top: -10px;
  73. }
  74. .slider input,
  75. .slider input[class*="span"] {
  76. display: none;
  77. }
  78. .slider .tooltip-inner {
  79. white-space: nowrap;
  80. }
  81. .slider-handle-container {
  82. position: absolute;
  83. }
  84. .slider-track {
  85. position: absolute;
  86. cursor: pointer;
  87. background-color: #f7f7f7;
  88. background-image: -moz-linear-gradient(top, #f5f5f5, #f9f9f9);
  89. background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#f5f5f5), to(#f9f9f9));
  90. background-image: -webkit-linear-gradient(top, #f5f5f5, #f9f9f9);
  91. background-image: -o-linear-gradient(top, #f5f5f5, #f9f9f9);
  92. background-image: linear-gradient(to bottom, #f5f5f5, #f9f9f9);
  93. background-repeat: repeat-x;
  94. -webkit-border-radius: 4px;
  95. -moz-border-radius: 4px;
  96. border-radius: 4px;
  97. filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#fff9f9f9', GradientType=0);
  98. -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
  99. -moz-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
  100. box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
  101. }
  102. .slider-selection {
  103. position: absolute;
  104. background-color: #e6e6e6;
  105. background-image: -moz-linear-gradient(top, #f0f0f0, #e0e0e0);
  106. background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#f0f0f0), to(#e0e0e0));
  107. background-image: -webkit-linear-gradient(top, #f0f0f0, #e0e0e0);
  108. background-image: -o-linear-gradient(top, #f0f0f0, #e0e0e0);
  109. background-image: linear-gradient(to bottom, #f0f0f0, #e0e0e0);
  110. background-repeat: repeat-x;
  111. -webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15);
  112. -moz-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15);
  113. box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15);
  114. -webkit-box-sizing: border-box;
  115. -moz-box-sizing: border-box;
  116. box-sizing: border-box;
  117. -webkit-border-radius: 20px;
  118. -moz-border-radius: 20px;
  119. border-radius: 20px;
  120. }
  121. .slider-handle {
  122. position: absolute;
  123. width: 20px;
  124. height: 20px;
  125. cursor: pointer;
  126. }
  127. .slider-knob {
  128. width: 20px;
  129. height: 20px;
  130. background-color: #f5f5f5;
  131. background-image: -moz-linear-gradient(top, #e6e6e6, #ffffff);
  132. background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#e6e6e6), to(#ffffff));
  133. background-image: -webkit-linear-gradient(top, #e6e6e6, #ffffff);
  134. background-image: -o-linear-gradient(top, #e6e6e6, #ffffff);
  135. background-image: linear-gradient(to bottom, #e6e6e6, #ffffff);
  136. background-repeat: repeat-x;
  137. border: 1px solid #bbbbbb;
  138. border-color: #e6e6e6 #e6e6e6 #bfbfbf;
  139. border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
  140. border-bottom-color: #a2a2a2;
  141. filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe6e6e6', GradientType=0);
  142. filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
  143. -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05);
  144. -moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05);
  145. box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05);
  146. -webkit-border-radius: 20px;
  147. -moz-border-radius: 20px;
  148. border-radius: 20px;
  149. }
  150. .slider-handle:active .slider-knob,
  151. .slider-handle:hover .slider-knob {
  152. background-color: #e6e6e6;
  153. background-position: 0 5px;
  154. -webkit-transition: background-position 0.1s linear;
  155. -moz-transition: background-position 0.1s linear;
  156. -o-transition: background-position 0.1s linear;
  157. transition: background-position 0.1s linear;
  158. }