Rap 原分销系统代码Web
25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

210 lines
3.6KB

  1. #app {
  2. .main-container {
  3. min-height: 100%;
  4. transition: margin-left .28s;
  5. margin-left: $sideBarWidth;
  6. position: relative;
  7. }
  8. .sidebar-container {
  9. transition: width 0.28s;
  10. width: $sideBarWidth !important;
  11. background-color: $menuBg;
  12. height: 100%;
  13. position: fixed;
  14. font-size: 0;
  15. top: 0;
  16. bottom: 0;
  17. left: 0;
  18. z-index: 1001;
  19. overflow: hidden;
  20. // reset element-ui css
  21. .horizontal-collapse-transition {
  22. transition: 0s width ease-in-out, 0s padding-left ease-in-out, 0s padding-right ease-in-out;
  23. }
  24. .scrollbar-wrapper {
  25. overflow-x: hidden !important;
  26. }
  27. .el-scrollbar__bar.is-vertical {
  28. right: 0;
  29. }
  30. .el-scrollbar {
  31. height: 100%;
  32. }
  33. &.has-logo {
  34. .el-scrollbar {
  35. height: calc(100% - 50px);
  36. }
  37. }
  38. .is-horizontal {
  39. display: none;
  40. }
  41. a {
  42. display: inline-block;
  43. width: 100%;
  44. overflow: hidden;
  45. }
  46. .svg-icon {
  47. margin-right: 16px;
  48. }
  49. .el-menu {
  50. border: none;
  51. height: 100%;
  52. width: 100% !important;
  53. }
  54. // menu hover
  55. .submenu-title-noDropdown,
  56. .el-submenu__title {
  57. &:hover {
  58. background-color: $menuHover !important;
  59. }
  60. }
  61. .is-active>.el-submenu__title {
  62. color: $subMenuActiveText !important;
  63. }
  64. & .nest-menu .el-submenu>.el-submenu__title,
  65. & .el-submenu .el-menu-item {
  66. min-width: $sideBarWidth !important;
  67. background-color: $subMenuBg !important;
  68. &:hover {
  69. background-color: $subMenuHover !important;
  70. }
  71. }
  72. }
  73. .hideSidebar {
  74. .sidebar-container {
  75. width: 54px !important;
  76. }
  77. .main-container {
  78. margin-left: 54px;
  79. }
  80. .submenu-title-noDropdown {
  81. padding: 0 !important;
  82. position: relative;
  83. .el-tooltip {
  84. padding: 0 !important;
  85. .svg-icon {
  86. margin-left: 20px;
  87. }
  88. }
  89. }
  90. .el-submenu {
  91. overflow: hidden;
  92. &>.el-submenu__title {
  93. padding: 0 !important;
  94. .svg-icon {
  95. margin-left: 20px;
  96. }
  97. .el-submenu__icon-arrow {
  98. display: none;
  99. }
  100. }
  101. }
  102. .el-menu--collapse {
  103. .el-submenu {
  104. &>.el-submenu__title {
  105. &>span {
  106. height: 0;
  107. width: 0;
  108. overflow: hidden;
  109. visibility: hidden;
  110. display: inline-block;
  111. }
  112. }
  113. }
  114. }
  115. }
  116. .el-menu--collapse .el-menu .el-submenu {
  117. min-width: $sideBarWidth !important;
  118. }
  119. // mobile responsive
  120. .mobile {
  121. .main-container {
  122. margin-left: 0;
  123. }
  124. .sidebar-container {
  125. transition: transform .28s;
  126. width: $sideBarWidth !important;
  127. }
  128. &.hideSidebar {
  129. .sidebar-container {
  130. pointer-events: none;
  131. transition-duration: 0.3s;
  132. transform: translate3d(-$sideBarWidth, 0, 0);
  133. }
  134. }
  135. }
  136. .withoutAnimation {
  137. .main-container,
  138. .sidebar-container {
  139. transition: none;
  140. }
  141. }
  142. }
  143. // when menu collapsed
  144. .el-menu--vertical {
  145. &>.el-menu {
  146. .svg-icon {
  147. margin-right: 16px;
  148. }
  149. }
  150. .nest-menu .el-submenu>.el-submenu__title,
  151. .el-menu-item {
  152. &:hover {
  153. // you can use $subMenuHover
  154. background-color: $menuHover !important;
  155. }
  156. }
  157. // the scroll bar appears when the subMenu is too long
  158. >.el-menu--popup {
  159. max-height: 100vh;
  160. overflow-y: auto;
  161. &::-webkit-scrollbar-track-piece {
  162. background: #d3dce6;
  163. }
  164. &::-webkit-scrollbar {
  165. width: 6px;
  166. }
  167. &::-webkit-scrollbar-thumb {
  168. background: #99a9bf;
  169. border-radius: 20px;
  170. }
  171. }
  172. }