main.less 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233
  1. //主布局
  2. .main-layout {
  3. overflow: hidden;
  4. width: 100%;
  5. height: 100%;
  6. &.hide-side{
  7. .main-layout-side{
  8. left: -200px;
  9. }
  10. .main-layout-container{
  11. left: 0;
  12. }
  13. }
  14. }
  15. //左侧布局
  16. .main-layout-side {
  17. width: 200px;
  18. height: 100%;
  19. background: @sideColor;
  20. position: absolute;
  21. left: 0;
  22. top: 0;
  23. bottom: 0;
  24. overflow: auto;
  25. z-index: 1;
  26. .transition(left .3s);
  27. .m-logo {
  28. width: 100%;
  29. height: 60px;
  30. background: #00b5f9 url(../images/logo.png) center center no-repeat;
  31. }
  32. .layui-nav{
  33. background: @sideColor;
  34. .iconfont{
  35. padding-right: 10px;
  36. font-size: 18px;
  37. color: #8f94a1;
  38. position: relative;
  39. top: 2px;
  40. }
  41. }
  42. .layui-nav-itemed>a{
  43. background: @sideColor!important;
  44. }
  45. .layui-nav-tree .layui-nav-child a {
  46. height: 40px;
  47. line-height: 40px;
  48. color: #77829f;
  49. &:hover{
  50. color: #00b5f9;
  51. }
  52. .l-line {
  53. width: 12px;
  54. display: inline-block;
  55. line-height: 40px;
  56. height: 40px;
  57. float: left;
  58. margin-right: 10px;
  59. margin-left: 30px;
  60. background: url("../images/l-line.png") left center no-repeat;
  61. }
  62. }
  63. .layui-nav-tree .layui-nav-child dd.layui-this, .layui-nav-tree .layui-this{
  64. background-color: @sideColor;
  65. }
  66. .layui-nav-tree .layui-nav-child .layui-this>a{
  67. background-color: @sideColor;
  68. color: @blue;
  69. // .l-line {
  70. // background: url("../images/l-line-white.png") left center no-repeat;
  71. // }
  72. }
  73. .layui-nav-tree .layui-this>a{
  74. background-color: rgba(0, 181, 249, 0.8);
  75. color: #fff;
  76. .iconfont{color: #fff;}
  77. }
  78. .layui-nav-tree .layui-nav-bar{
  79. background-color: rgba(0,181,245,0.8);
  80. }
  81. }
  82. //右侧内容
  83. .main-layout-container{
  84. position: absolute;
  85. left: 200px;
  86. right: 0;
  87. top: 0;
  88. bottom: 0;
  89. background: #f5f5f5;
  90. .transition(left .3s);
  91. }
  92. //头部
  93. .main-layout-header{
  94. @num: 60px;
  95. height: @num;
  96. border-bottom: 1px solid #f0f0f0;
  97. background: #fff;
  98. a {
  99. text-decoration: none;
  100. }
  101. .menu-btn {
  102. float: left;
  103. width: @num;
  104. height: @num;
  105. line-height: @num;
  106. text-align: center;
  107. .iconfont {
  108. font-size: 20px;
  109. color: @sideColor;
  110. }
  111. }
  112. .layui-nav{
  113. float: right;
  114. padding: 0;
  115. background: transparent;
  116. li{
  117. border-left: 1px solid #f2f3f5;
  118. }
  119. .layui-nav-item > a:hover{
  120. color: #999;
  121. }
  122. &>.layui-this a{
  123. color: #00b5f9;
  124. }
  125. .layui-nav-bar{
  126. display: none;
  127. }
  128. .layui-this:after{
  129. height: 0;
  130. }
  131. .layui-nav-child dd.layui-this a{
  132. color: #333;
  133. }
  134. .layui-nav-child dd.layui-this{
  135. color: #333;
  136. background: rgb(242,242,242);
  137. }
  138. }
  139. }
  140. .main-layout-body{
  141. position: absolute;
  142. left: 0;
  143. right: 0;
  144. bottom: 0;
  145. top: 61px;
  146. overflow: hidden;
  147. }
  148. //tab
  149. .main-layout-tab{
  150. margin-top: 0;
  151. .layui-tab-title{
  152. border-bottom: 1px solid #f0f0f0;
  153. z-index: 98;
  154. background: #fff;
  155. }
  156. &.layui-tab-brief>.layui-tab-title .layui-this{
  157. color: #00b5f9;
  158. }
  159. &.layui-tab-brief>.layui-tab-more li.layui-this:after, &.layui-tab-brief>.layui-tab-title .layui-this:after {
  160. border: none;
  161. border-radius: 0;
  162. border-bottom: 3px solid #00b5f9;
  163. }
  164. //去掉后台主页tab的关闭按钮
  165. .welcome{
  166. .layui-tab-close{
  167. display: none;
  168. }
  169. }
  170. .layui-tab-content{
  171. position: absolute;
  172. right: 0;
  173. left: 0;
  174. bottom: 0;
  175. top: 41px;
  176. padding: 0;
  177. z-index: 97;
  178. background: #f5f5f5;
  179. padding: 0px;
  180. box-sizing: border-box;
  181. .layui-tab-item{
  182. width: 100%;
  183. height: 100%;
  184. background: #fff;
  185. }
  186. }
  187. }
  188. //页面主容器
  189. .wrap-container {
  190. width: 100%;
  191. height: 100%;
  192. overflow-x: hidden;
  193. overflow-y: auto;
  194. .box-sizing(border-box);
  195. }
  196. .iframe{
  197. border:0;
  198. }
  199. .main-mask{
  200. display: none;
  201. position: fixed;
  202. z-index: 99;
  203. left: 0;
  204. right: 0;
  205. top: 0;
  206. bottom: 0;
  207. background: rgba(0,0,0,0.3);
  208. }
  209. @media (max-width: 768px) {
  210. .main-layout-side{
  211. position: fixed;
  212. left: -200px;
  213. overflow: auto;
  214. overflow-x: hidden;
  215. z-index: 100;
  216. }
  217. .main-layout-container{
  218. position: absolute;
  219. left:0px;
  220. right: 0;
  221. top: 0;
  222. bottom: 0;
  223. }
  224. .main-layout.hide-side {
  225. .main-layout-side{
  226. left: 0;
  227. }
  228. .main-mask{
  229. display: block;
  230. }
  231. }
  232. ::-webkit-scrollbar{width:2px;height:10px}
  233. }