theme.less 8.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297
  1. // stylelint-disable selector-no-qualifying-type, selector-max-compound-selectors
  2. /*!
  3. * Bootstrap v3.4.1 (https://getbootstrap.com/)
  4. * Copyright 2011-2019 Twitter, Inc.
  5. * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
  6. */
  7. //
  8. // Load core variables and mixins
  9. // --------------------------------------------------
  10. @import "variables.less";
  11. @import "mixins.less";
  12. //
  13. // Buttons
  14. // --------------------------------------------------
  15. // Common styles
  16. .btn-default,
  17. .btn-primary,
  18. .btn-success,
  19. .btn-info,
  20. .btn-warning,
  21. .btn-danger {
  22. text-shadow: 0 -1px 0 rgba(0, 0, 0, .2);
  23. @shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 1px rgba(0, 0, 0, .075);
  24. .box-shadow(@shadow);
  25. // Reset the shadow
  26. &:active,
  27. &.active {
  28. .box-shadow(inset 0 3px 5px rgba(0, 0, 0, .125));
  29. }
  30. &.disabled,
  31. &[disabled],
  32. fieldset[disabled] & {
  33. .box-shadow(none);
  34. }
  35. .badge {
  36. text-shadow: none;
  37. }
  38. }
  39. // Mixin for generating new styles
  40. .btn-styles(@btn-color: #555) {
  41. #gradient > .vertical(@start-color: @btn-color; @end-color: darken(@btn-color, 12%));
  42. .reset-filter(); // Disable gradients for IE9 because filter bleeds through rounded corners; see https://github.com/twbs/bootstrap/issues/10620
  43. background-repeat: repeat-x;
  44. border-color: darken(@btn-color, 14%);
  45. &:hover,
  46. &:focus {
  47. background-color: darken(@btn-color, 12%);
  48. background-position: 0 -15px;
  49. }
  50. &:active,
  51. &.active {
  52. background-color: darken(@btn-color, 12%);
  53. border-color: darken(@btn-color, 14%);
  54. }
  55. &.disabled,
  56. &[disabled],
  57. fieldset[disabled] & {
  58. &,
  59. &:hover,
  60. &:focus,
  61. &.focus,
  62. &:active,
  63. &.active {
  64. background-color: darken(@btn-color, 12%);
  65. background-image: none;
  66. }
  67. }
  68. }
  69. // Common styles
  70. .btn {
  71. // Remove the gradient for the pressed/active state
  72. &:active,
  73. &.active {
  74. background-image: none;
  75. }
  76. }
  77. // Apply the mixin to the buttons
  78. .btn-default {
  79. .btn-styles(@btn-default-bg);
  80. text-shadow: 0 1px 0 #fff;
  81. border-color: #ccc;
  82. }
  83. .btn-primary { .btn-styles(@btn-primary-bg); }
  84. .btn-success { .btn-styles(@btn-success-bg); }
  85. .btn-info { .btn-styles(@btn-info-bg); }
  86. .btn-warning { .btn-styles(@btn-warning-bg); }
  87. .btn-danger { .btn-styles(@btn-danger-bg); }
  88. //
  89. // Images
  90. // --------------------------------------------------
  91. .thumbnail,
  92. .img-thumbnail {
  93. .box-shadow(0 1px 2px rgba(0, 0, 0, .075));
  94. }
  95. //
  96. // Dropdowns
  97. // --------------------------------------------------
  98. .dropdown-menu > li > a:hover,
  99. .dropdown-menu > li > a:focus {
  100. #gradient > .vertical(@start-color: @dropdown-link-hover-bg; @end-color: darken(@dropdown-link-hover-bg, 5%));
  101. background-color: darken(@dropdown-link-hover-bg, 5%);
  102. }
  103. .dropdown-menu > .active > a,
  104. .dropdown-menu > .active > a:hover,
  105. .dropdown-menu > .active > a:focus {
  106. #gradient > .vertical(@start-color: @dropdown-link-active-bg; @end-color: darken(@dropdown-link-active-bg, 5%));
  107. background-color: darken(@dropdown-link-active-bg, 5%);
  108. }
  109. //
  110. // Navbar
  111. // --------------------------------------------------
  112. // Default navbar
  113. .navbar-default {
  114. #gradient > .vertical(@start-color: lighten(@navbar-default-bg, 10%); @end-color: @navbar-default-bg);
  115. .reset-filter(); // Remove gradient in IE<10 to fix bug where dropdowns don't get triggered
  116. border-radius: @navbar-border-radius;
  117. @shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 5px rgba(0, 0, 0, .075);
  118. .box-shadow(@shadow);
  119. .navbar-nav > .open > a,
  120. .navbar-nav > .active > a {
  121. #gradient > .vertical(@start-color: darken(@navbar-default-link-active-bg, 5%); @end-color: darken(@navbar-default-link-active-bg, 2%));
  122. .box-shadow(inset 0 3px 9px rgba(0, 0, 0, .075));
  123. }
  124. }
  125. .navbar-brand,
  126. .navbar-nav > li > a {
  127. text-shadow: 0 1px 0 rgba(255, 255, 255, .25);
  128. }
  129. // Inverted navbar
  130. .navbar-inverse {
  131. #gradient > .vertical(@start-color: lighten(@navbar-inverse-bg, 10%); @end-color: @navbar-inverse-bg);
  132. .reset-filter(); // Remove gradient in IE<10 to fix bug where dropdowns don't get triggered; see https://github.com/twbs/bootstrap/issues/10257
  133. border-radius: @navbar-border-radius;
  134. .navbar-nav > .open > a,
  135. .navbar-nav > .active > a {
  136. #gradient > .vertical(@start-color: @navbar-inverse-link-active-bg; @end-color: lighten(@navbar-inverse-link-active-bg, 2.5%));
  137. .box-shadow(inset 0 3px 9px rgba(0, 0, 0, .25));
  138. }
  139. .navbar-brand,
  140. .navbar-nav > li > a {
  141. text-shadow: 0 -1px 0 rgba(0, 0, 0, .25);
  142. }
  143. }
  144. // Undo rounded corners in static and fixed navbars
  145. .navbar-static-top,
  146. .navbar-fixed-top,
  147. .navbar-fixed-bottom {
  148. border-radius: 0;
  149. }
  150. // Fix active state of dropdown items in collapsed mode
  151. @media (max-width: @grid-float-breakpoint-max) {
  152. .navbar .navbar-nav .open .dropdown-menu > .active > a {
  153. &,
  154. &:hover,
  155. &:focus {
  156. color: #fff;
  157. #gradient > .vertical(@start-color: @dropdown-link-active-bg; @end-color: darken(@dropdown-link-active-bg, 5%));
  158. }
  159. }
  160. }
  161. //
  162. // Alerts
  163. // --------------------------------------------------
  164. // Common styles
  165. .alert {
  166. text-shadow: 0 1px 0 rgba(255, 255, 255, .2);
  167. @shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 1px 2px rgba(0, 0, 0, .05);
  168. .box-shadow(@shadow);
  169. }
  170. // Mixin for generating new styles
  171. .alert-styles(@color) {
  172. #gradient > .vertical(@start-color: @color; @end-color: darken(@color, 7.5%));
  173. border-color: darken(@color, 15%);
  174. }
  175. // Apply the mixin to the alerts
  176. .alert-success { .alert-styles(@alert-success-bg); }
  177. .alert-info { .alert-styles(@alert-info-bg); }
  178. .alert-warning { .alert-styles(@alert-warning-bg); }
  179. .alert-danger { .alert-styles(@alert-danger-bg); }
  180. //
  181. // Progress bars
  182. // --------------------------------------------------
  183. // Give the progress background some depth
  184. .progress {
  185. #gradient > .vertical(@start-color: darken(@progress-bg, 4%); @end-color: @progress-bg)
  186. }
  187. // Mixin for generating new styles
  188. .progress-bar-styles(@color) {
  189. #gradient > .vertical(@start-color: @color; @end-color: darken(@color, 10%));
  190. }
  191. // Apply the mixin to the progress bars
  192. .progress-bar { .progress-bar-styles(@progress-bar-bg); }
  193. .progress-bar-success { .progress-bar-styles(@progress-bar-success-bg); }
  194. .progress-bar-info { .progress-bar-styles(@progress-bar-info-bg); }
  195. .progress-bar-warning { .progress-bar-styles(@progress-bar-warning-bg); }
  196. .progress-bar-danger { .progress-bar-styles(@progress-bar-danger-bg); }
  197. // Reset the striped class because our mixins don't do multiple gradients and
  198. // the above custom styles override the new `.progress-bar-striped` in v3.2.0.
  199. .progress-bar-striped {
  200. #gradient > .striped();
  201. }
  202. //
  203. // List groups
  204. // --------------------------------------------------
  205. .list-group {
  206. border-radius: @border-radius-base;
  207. .box-shadow(0 1px 2px rgba(0, 0, 0, .075));
  208. }
  209. .list-group-item.active,
  210. .list-group-item.active:hover,
  211. .list-group-item.active:focus {
  212. text-shadow: 0 -1px 0 darken(@list-group-active-bg, 10%);
  213. #gradient > .vertical(@start-color: @list-group-active-bg; @end-color: darken(@list-group-active-bg, 7.5%));
  214. border-color: darken(@list-group-active-border, 7.5%);
  215. .badge {
  216. text-shadow: none;
  217. }
  218. }
  219. //
  220. // Panels
  221. // --------------------------------------------------
  222. // Common styles
  223. .panel {
  224. .box-shadow(0 1px 2px rgba(0, 0, 0, .05));
  225. }
  226. // Mixin for generating new styles
  227. .panel-heading-styles(@color) {
  228. #gradient > .vertical(@start-color: @color; @end-color: darken(@color, 5%));
  229. }
  230. // Apply the mixin to the panel headings only
  231. .panel-default > .panel-heading { .panel-heading-styles(@panel-default-heading-bg); }
  232. .panel-primary > .panel-heading { .panel-heading-styles(@panel-primary-heading-bg); }
  233. .panel-success > .panel-heading { .panel-heading-styles(@panel-success-heading-bg); }
  234. .panel-info > .panel-heading { .panel-heading-styles(@panel-info-heading-bg); }
  235. .panel-warning > .panel-heading { .panel-heading-styles(@panel-warning-heading-bg); }
  236. .panel-danger > .panel-heading { .panel-heading-styles(@panel-danger-heading-bg); }
  237. //
  238. // Wells
  239. // --------------------------------------------------
  240. .well {
  241. #gradient > .vertical(@start-color: darken(@well-bg, 5%); @end-color: @well-bg);
  242. border-color: darken(@well-bg, 10%);
  243. @shadow: inset 0 1px 3px rgba(0, 0, 0, .05), 0 1px 0 rgba(255, 255, 255, .1);
  244. .box-shadow(@shadow);
  245. }