header.less 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236
  1. /*
  2. * Component: Main Header
  3. * ----------------------
  4. */
  5. .main-header {
  6. position: relative;
  7. max-height: 100px;
  8. z-index: 1030;
  9. //Navbar
  10. > .navbar {
  11. .transition(margin-left @transition-speed @transition-fn);
  12. margin-bottom: 0;
  13. margin-left: @sidebar-width;
  14. border: none;
  15. min-height: @navbar-height;
  16. border-radius: 0;
  17. .layout-top-nav & {
  18. margin-left: 0!important;
  19. }
  20. }
  21. //Navbar search text input
  22. #navbar-search-input {
  23. background: rgba(255,255,255,.2);
  24. border-color: transparent;
  25. &:focus,
  26. &:active {
  27. border-color: rgba(0,0,0,.1)!important;
  28. background: rgba(255,255,255,.9);
  29. }
  30. &::-moz-placeholder {
  31. color: #ccc;
  32. opacity: 1;
  33. }
  34. &:-ms-input-placeholder {
  35. color: #ccc;
  36. }
  37. &::-webkit-input-placeholder {
  38. color: #ccc;
  39. }
  40. }
  41. //Navbar Right Menu
  42. .navbar-custom-menu,
  43. .navbar-right {
  44. float: right;
  45. @media (max-width: @screen-sm-max) {
  46. a {
  47. color: inherit;
  48. background: transparent;
  49. }
  50. }
  51. }
  52. .navbar-right {
  53. @media (max-width: @screen-header-collapse) {
  54. float: none;
  55. .navbar-collapse & {
  56. margin: 7.5px -15px;
  57. }
  58. > li {
  59. color: inherit;
  60. border: 0;
  61. }
  62. }
  63. }
  64. //Navbar toggle button
  65. .sidebar-toggle {
  66. float: left;
  67. background-color: transparent;
  68. background-image: none;
  69. padding: @navbar-padding-vertical @navbar-padding-horizontal;
  70. //Add the fontawesome bars icon
  71. font-family: fontAwesome;
  72. &:before {
  73. content: "\f0c9";
  74. }
  75. &:hover {
  76. color: #fff;
  77. }
  78. &:focus,
  79. &:active {
  80. background: transparent;
  81. }
  82. }
  83. .sidebar-toggle .icon-bar {
  84. display: none;
  85. }
  86. //Navbar User Menu
  87. .navbar .nav > li.user > a {
  88. > .fa,
  89. > .glyphicon,
  90. > .ion {
  91. margin-right: 5px;
  92. }
  93. }
  94. //Labels in navbar
  95. .navbar .nav > li > a > .label {
  96. position: absolute;
  97. top: 9px;
  98. right: 7px;
  99. text-align: center;
  100. font-size: 9px;
  101. padding: 2px 3px;
  102. line-height: .9;
  103. }
  104. //Logo bar
  105. .logo {
  106. .transition(width @transition-speed @transition-fn);
  107. display: block;
  108. float: left;
  109. height: @navbar-height;
  110. font-size: 20px;
  111. line-height: 50px;
  112. text-align: center;
  113. width: @sidebar-width;
  114. font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  115. padding: 0 15px;
  116. font-weight: 300;
  117. //Add support to sidebar mini by allowing the user to create
  118. //2 logo designs. mini and lg
  119. .logo-lg {
  120. //should be visibile when sidebar isn't collapsed
  121. display: block;
  122. }
  123. .logo-mini {
  124. display: none;
  125. }
  126. }
  127. //Navbar Brand. Alternative logo with layout-top-nav
  128. .navbar-brand {
  129. color: #fff;
  130. }
  131. }
  132. // Content Header
  133. .content-header {
  134. position: relative;
  135. padding: 15px 15px 0 15px;
  136. // Header Text
  137. > h1 {
  138. margin: 0;
  139. font-size: 24px;
  140. > small {
  141. font-size: 15px;
  142. display: inline-block;
  143. padding-left: 4px;
  144. font-weight: 300;
  145. }
  146. }
  147. > .breadcrumb {
  148. float: right;
  149. background: transparent;
  150. margin-top: 0px;
  151. margin-bottom: 0;
  152. font-size: 12px;
  153. padding: 7px 5px;
  154. position: absolute;
  155. top: 15px;
  156. right: 10px;
  157. .border-radius(2px);
  158. > li > a {
  159. color: #444;
  160. text-decoration: none;
  161. display: inline-block;
  162. > .fa, > .glyphicon, > .ion {
  163. margin-right: 5px;
  164. }
  165. }
  166. > li + li:before {
  167. content: '>\00a0';
  168. }
  169. }
  170. @media (max-width: @screen-sm-max) {
  171. > .breadcrumb {
  172. position: relative;
  173. margin-top: 5px;
  174. top: 0;
  175. right: 0;
  176. float: none;
  177. background: @gray;
  178. padding-left: 10px;
  179. li:before {
  180. color: darken(@gray, 20%);
  181. }
  182. }
  183. }
  184. }
  185. .navbar-toggle {
  186. color: #fff;
  187. border: 0;
  188. margin: 0;
  189. padding: @navbar-padding-vertical @navbar-padding-horizontal;
  190. }
  191. //Control navbar scaffolding on x-small screens
  192. @media (max-width: @screen-sm-max) {
  193. .navbar-custom-menu .navbar-nav > li {
  194. float: left;
  195. }
  196. //Dont't let links get full width
  197. .navbar-custom-menu .navbar-nav {
  198. margin: 0;
  199. float: left;
  200. }
  201. .navbar-custom-menu .navbar-nav > li > a {
  202. padding-top: 15px;
  203. padding-bottom: 15px;
  204. line-height: 20px;
  205. }
  206. }
  207. // Collapse header
  208. @media (max-width: @screen-header-collapse) {
  209. .main-header {
  210. position: relative;
  211. .logo,
  212. .navbar {
  213. width: 100%;
  214. float: none;
  215. position: relative!important;
  216. }
  217. .navbar {
  218. margin: 0;
  219. }
  220. .navbar-custom-menu {
  221. float: right;
  222. }
  223. }
  224. .main-sidebar,
  225. .left-side {
  226. padding-top: 100px!important;
  227. }
  228. }