variables.less 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335
  1. //
  2. // Variables
  3. // --------------------------------------------------
  4. // Global values
  5. // --------------------------------------------------
  6. // Grays
  7. // -------------------------
  8. @black: #000;
  9. @grayDarker: #222;
  10. @grayDark: #333;
  11. @gray: #555;
  12. @grayLight: #999;
  13. @grayLighter: #eee;
  14. @white: #fff;
  15. // Accent colors
  16. // -------------------------
  17. @blue: #049cdb;
  18. @bluePale: #3c85a3;
  19. @blueDark: #0064cd;
  20. @green: #46a546;
  21. @red: #cf402e;
  22. @yellow: #ffc40d;
  23. @orange: #f89406;
  24. @pink: #c3325f;
  25. @purple: #7a43b6;
  26. // Scaffolding
  27. // -------------------------
  28. @bodyBackground: #FBFBFB;
  29. @textColor: @grayDark;
  30. // Links
  31. // -------------------------
  32. @linkColor: #08c;
  33. @linkColorHover: darken(@linkColor, 15%);
  34. // Typography
  35. // -------------------------
  36. @sansFontFamily: "Helvetica Neue", Helvetica, Arial, sans-serif;
  37. @serifFontFamily: Georgia, "Times New Roman", Times, serif;
  38. @monoFontFamily: Monaco, Menlo, Consolas, "Courier New", monospace;
  39. @baseFontSize: 14px;
  40. @baseFontFamily: @sansFontFamily;
  41. @baseLineHeight: 20px;
  42. @altFontFamily: @serifFontFamily;
  43. @headingsFontFamily: inherit; // empty to use BS default, @baseFontFamily
  44. @headingsFontWeight: bold; // instead of browser default, bold
  45. @headingsColor: inherit; // empty to use BS default, @textColor
  46. // Component sizing
  47. // -------------------------
  48. // Based on 14px font-size and 20px line-height
  49. @fontSizeLarge: @baseFontSize * 1.25; // ~18px
  50. @fontSizeSmall: @baseFontSize * 0.85; // ~12px
  51. @fontSizeMini: @baseFontSize * 0.75; // ~11px
  52. @paddingLarge: 11px 19px; // 44px
  53. @paddingSmall: 2px 10px; // 26px
  54. @paddingMini: 0 6px; // 22px
  55. @baseBorderRadius: 3px;
  56. @borderRadiusLarge: 5px;
  57. @borderRadiusSmall: 2px;
  58. // Page header
  59. // -------------------------
  60. @pageHeaderBackground: darken(@bodyBackground, 8%);
  61. @pageHeaderBorder: darken(@bodyBackground, 14%);
  62. // Items styles
  63. // -------------------------
  64. @itemOldColor: darken(@grayLight, 5%);
  65. @itemNewColor: @linkColor;
  66. @itemMovedColor: lighten(@purple, 10%);
  67. // Board index forums list
  68. // -------------------------
  69. @categoryBackground: lighten(@bodyBackground, 5%);
  70. @categoryBorder: darken(@bodyBackground, 15%);
  71. @categoryHeader: @bluePale;
  72. @categoryShadow: darken(@bodyBackground, 5%);
  73. @forumIconSize: 4px;
  74. // Tables
  75. // -------------------------
  76. @tableBackground: transparent; // overall background-color
  77. @tableBackgroundAccent: #f9f9f9; // for striping
  78. @tableBackgroundHover: #f5f5f5; // for hover
  79. @tableBorder: #ddd; // table and cell border
  80. // Buttons
  81. // -------------------------
  82. @btnBackground: @white;
  83. @btnBackgroundHighlight: darken(@white, 10%);
  84. @btnBorder: #ccc;
  85. @btnPrimaryBackground: @linkColor;
  86. @btnPrimaryBackgroundHighlight: spin(@btnPrimaryBackground, 20%);
  87. @btnInfoBackground: #5bc0de;
  88. @btnInfoBackgroundHighlight: #2f96b4;
  89. @btnSuccessBackground: #62c462;
  90. @btnSuccessBackgroundHighlight: #51a351;
  91. @btnWarningBackground: lighten(@orange, 15%);
  92. @btnWarningBackgroundHighlight: @orange;
  93. @btnDangerBackground: #ee5f5b;
  94. @btnDangerBackgroundHighlight: #bd362f;
  95. @btnInverseBackground: #444;
  96. @btnInverseBackgroundHighlight: @grayDarker;
  97. // Forms
  98. // -------------------------
  99. @inputBackground: @white;
  100. @inputBorder: #ccc;
  101. @inputBorderRadius: @baseBorderRadius;
  102. @inputDisabledBackground: @grayLighter;
  103. @formActionsBackground: #f5f5f5;
  104. @inputHeight: @baseLineHeight + 10px; // base line-height + 8px vertical padding + 2px top/bottom border
  105. // Editor
  106. // -------------------------
  107. @editorBackground: @grayLighter;
  108. @editorPadding: @baseFontSize * 0.75;
  109. // Dropdowns
  110. // -------------------------
  111. @dropdownBackground: @white;
  112. @dropdownBorder: rgba(0,0,0,.2);
  113. @dropdownDividerTop: #e5e5e5;
  114. @dropdownDividerBottom: @white;
  115. @dropdownLinkColor: @grayDark;
  116. @dropdownLinkColorHover: @white;
  117. @dropdownLinkColorActive: @white;
  118. @dropdownLinkBackgroundActive: @linkColor;
  119. @dropdownLinkBackgroundHover: @dropdownLinkBackgroundActive;
  120. // COMPONENT VARIABLES
  121. // --------------------------------------------------
  122. // Z-index master list
  123. // -------------------------
  124. // Used for a bird's eye view of components dependent on the z-axis
  125. // Try to avoid customizing these :)
  126. @zindexDropdown: 1000;
  127. @zindexPopover: 1010;
  128. @zindexTooltip: 1030;
  129. @zindexFixedNavbar: 1030;
  130. @zindexModalBackdrop: 1040;
  131. @zindexModal: 1050;
  132. // Sprite icons path
  133. // -------------------------
  134. @iconSpritePath: "../img/glyphicons-halflings.png";
  135. @iconWhiteSpritePath: "../img/glyphicons-halflings-white.png";
  136. // Input placeholder text color
  137. // -------------------------
  138. @placeholderText: @grayLight;
  139. // Hr border color
  140. // -------------------------
  141. @hrBorder: @grayLighter;
  142. // Horizontal forms & lists
  143. // -------------------------
  144. @horizontalComponentOffset: 180px;
  145. // Wells
  146. // -------------------------
  147. @wellBackground: #f5f5f5;
  148. // Navbar
  149. // -------------------------
  150. @navbarCollapseWidth: 979px;
  151. @navbarCollapseDesktopWidth: @navbarCollapseWidth + 1;
  152. @navbarHeight: 50px;
  153. @navbarBackgroundHighlight: #ffffff;
  154. @navbarBackground: darken(@bodyBackground, 3%);
  155. @navbarBorder: darken(@navbarBackground, 8%);
  156. @navbarText: #777;
  157. @navbarLinkColor: #777;
  158. @navbarLinkColorHover: @grayDark;
  159. @navbarLinkColorActive: @gray;
  160. @navbarLinkBackgroundHover: transparent;
  161. @navbarLinkBackgroundActive: darken(@navbarBackground, 5%);
  162. @navbarLogoImage: "../img/logo.png";
  163. @navbarLogoWidth: 20px;
  164. @navbarBrandColor: desaturate(@red, 10%);
  165. @navbarMottoColor: darken(@navbarBackground, 20%);
  166. // Inverted navbar
  167. @navbarInverseBackground: #111111;
  168. @navbarInverseBackgroundHighlight: #222222;
  169. @navbarInverseBorder: #252525;
  170. @navbarInverseText: @grayLight;
  171. @navbarInverseLinkColor: @grayLight;
  172. @navbarInverseLinkColorHover: @white;
  173. @navbarInverseLinkColorActive: @navbarInverseLinkColorHover;
  174. @navbarInverseLinkBackgroundHover: transparent;
  175. @navbarInverseLinkBackgroundActive: @navbarInverseBackground;
  176. @navbarInverseSearchBackground: lighten(@navbarInverseBackground, 25%);
  177. @navbarInverseSearchBackgroundFocus: @white;
  178. @navbarInverseSearchBorder: @navbarInverseBackground;
  179. @navbarInverseSearchPlaceholderColor: #ccc;
  180. @navbarInverseBrandColor: @navbarInverseLinkColor;
  181. // Footer
  182. // -------------------------
  183. @footerHeight: 80px;
  184. @footerBackground: darken(@bodyBackground, 5%);
  185. @footerBorder: darken(@footerBackground, 8%);
  186. // Pagination
  187. // -------------------------
  188. @paginationBackground: @white;
  189. @paginationBorder: darken(@paginationBackground, 6%);
  190. @paginationActiveBackground: @grayLight;
  191. // Hero unit
  192. // -------------------------
  193. @heroUnitBackground: @grayLighter;
  194. @heroUnitHeadingColor: inherit;
  195. @heroUnitLeadColor: inherit;
  196. // Form states and alerts
  197. // -------------------------
  198. @warningText: #FFF;
  199. @warningBackground: #fcf8e3;
  200. @warningBorder: darken(spin(@warningBackground, -10), 3%);
  201. @errorText: @red;
  202. @errorBackground: desaturate(@red, 10%);
  203. @errorBorder: darken(@errorBackground, 10%);
  204. @successText: @green;
  205. @successBackground: desaturate(@green, 10%);
  206. @successBorder: darken(@successBackground, 10%);
  207. @infoText: @blue;
  208. @infoBackground: desaturate(@blue, 15%);
  209. @infoBorder: darken(@infoBackground, 10%);
  210. // Tooltips and popovers
  211. // -------------------------
  212. @tooltipColor: #fff;
  213. @tooltipBackground: #000;
  214. @tooltipArrowWidth: 5px;
  215. @tooltipArrowColor: @tooltipBackground;
  216. @popoverBackground: #fff;
  217. @popoverArrowWidth: 10px;
  218. @popoverArrowColor: #fff;
  219. @popoverTitleBackground: darken(@popoverBackground, 3%);
  220. // Special enhancement for popovers
  221. @popoverArrowOuterWidth: @popoverArrowWidth + 1;
  222. @popoverArrowOuterColor: rgba(0,0,0,.25);
  223. // GRID
  224. // --------------------------------------------------
  225. // Default 940px grid
  226. // -------------------------
  227. @gridColumns: 12;
  228. @gridColumnWidth: 60px;
  229. @gridGutterWidth: 20px;
  230. @gridRowWidth: (@gridColumns * @gridColumnWidth) + (@gridGutterWidth * (@gridColumns - 1));
  231. // 1200px min
  232. @gridColumnWidth1200: 70px;
  233. @gridGutterWidth1200: 30px;
  234. @gridRowWidth1200: (@gridColumns * @gridColumnWidth1200) + (@gridGutterWidth1200 * (@gridColumns - 1));
  235. // 768px-979px
  236. @gridColumnWidth768: 42px;
  237. @gridGutterWidth768: 20px;
  238. @gridRowWidth768: (@gridColumns * @gridColumnWidth768) + (@gridGutterWidth768 * (@gridColumns - 1));
  239. // Fluid grid
  240. // -------------------------
  241. @fluidGridColumnWidth: percentage(@gridColumnWidth/@gridRowWidth);
  242. @fluidGridGutterWidth: percentage(@gridGutterWidth/@gridRowWidth);
  243. // 1200px min
  244. @fluidGridColumnWidth1200: percentage(@gridColumnWidth1200/@gridRowWidth1200);
  245. @fluidGridGutterWidth1200: percentage(@gridGutterWidth1200/@gridRowWidth1200);
  246. // 768px-979px
  247. @fluidGridColumnWidth768: percentage(@gridColumnWidth768/@gridRowWidth768);
  248. @fluidGridGutterWidth768: percentage(@gridGutterWidth768/@gridRowWidth768);