control-sidebar.less 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162
  1. /*
  2. * Component: Control sidebar. By deafult, this is the right sidebar.
  3. */
  4. //The sidebar's backhround control class
  5. //This is a hack to make the background visible while scrolling
  6. .control-sidebar-bg {
  7. position: fixed;
  8. z-index: 900;
  9. top: 0;
  10. right: 0;
  11. bottom: 0;
  12. width: @control-sidebar-width;
  13. background: @sidebar-dark-bg;
  14. }
  15. //Transitions
  16. .control-sidebar-bg,
  17. .control-sidebar {
  18. .translate(@control-sidebar-width, 0);
  19. .transition-transform(@transition-speed ease-in-out);
  20. }
  21. .control-sidebar {
  22. position: absolute;
  23. top: @navbar-height;
  24. right: 0;
  25. width: @control-sidebar-width;
  26. z-index: 1010;
  27. color: @sidebar-dark-color;
  28. //Fix position after header collapse
  29. @media (max-width: @screen-sm) {
  30. top: @navbar-height + 50;
  31. }
  32. //Tab panes
  33. > .tab-content {
  34. padding: 10px 15px;
  35. }
  36. //Open state with slide over content effect
  37. &.control-sidebar-open {
  38. &,
  39. + .control-sidebar-bg {
  40. .translate(0, 0);
  41. }
  42. }
  43. }
  44. //Open without silde over content
  45. .control-sidebar-open {
  46. .control-sidebar-bg,
  47. .control-sidebar {
  48. .translate(0,0);
  49. }
  50. .content-wrapper,
  51. .right-side,
  52. .main-footer {
  53. margin-right: @control-sidebar-width;
  54. }
  55. }
  56. //Control sidebar tabs
  57. .control-sidebar-tabs {
  58. border-bottom: darken(@sidebar-dark-bg, 3%);
  59. > li {
  60. > a {
  61. .border-radius(0)!important;
  62. background: darken(@sidebar-dark-bg, 5%);
  63. color: @sidebar-dark-color;
  64. //Hover and active states
  65. &,
  66. &:hover {
  67. border-top: none;
  68. border-right: none;
  69. border-left: 1px solid darken(@sidebar-dark-bg, 7%)!important;
  70. border-bottom: 1px solid darken(@sidebar-dark-bg, 7%)!important;
  71. }
  72. &:hover,
  73. &:focus,
  74. &:active {
  75. background: darken(@sidebar-dark-bg, 3%);
  76. }
  77. .icon {
  78. font-size: 16px;
  79. }
  80. }
  81. //Active state
  82. &.active {
  83. > a {
  84. &,
  85. &:hover,
  86. &:focus,
  87. &:active {
  88. border-top: none!important;
  89. border-right: none!important;
  90. border-bottom: none!important;
  91. background: @sidebar-dark-bg;
  92. color: #fff;
  93. }
  94. }
  95. }
  96. }
  97. //Remove resposiveness on small screens
  98. @media(max-width: @screen-sm) {
  99. display: table;
  100. >li {
  101. display: table-cell!important;
  102. }
  103. }
  104. }
  105. //Headings in the sidebar content
  106. .control-sidebar-heading {
  107. color: #fff;
  108. font-weight: 400;
  109. font-size: 16px;
  110. padding: 10px 0;
  111. margin-bottom: 10px;
  112. }
  113. //Subheadings
  114. .control-sidebar-subheading {
  115. display: block;
  116. color: #fff;
  117. font-weight: 400;
  118. font-size: 14px;
  119. }
  120. //Control Sidebar Menu
  121. .control-sidebar-menu {
  122. list-style: none;
  123. padding: 0;
  124. margin: 0 -15px;
  125. > li > a {
  126. .clearfix();
  127. display: block;
  128. padding: 10px 15px;
  129. &:hover {
  130. background: @sidebar-dark-hover-bg;
  131. }
  132. > .control-sidebar-subheading {
  133. margin-top: 0;
  134. }
  135. }
  136. .menu-icon {
  137. float: left;
  138. width: 35px;
  139. height: 35px;
  140. border-radius: 50%;
  141. text-align: center;
  142. line-height: 35px;
  143. }
  144. .menu-info {
  145. margin-left: 45px;
  146. margin-top: 3px;
  147. > .control-sidebar-subheading {
  148. margin: 0;
  149. }
  150. > p {
  151. margin: 0;
  152. color: @sidebar-dark-color;
  153. font-size: 11px;
  154. }
  155. }
  156. .progress {
  157. margin: 0;
  158. }
  159. }