element.scss 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282
  1. @import 'mixins/index.scss';
  2. // 更改按钮样式
  3. :root {
  4. //--el-color-danger: #909399; // 删除按钮
  5. }
  6. // 修复树形表格中 type index 的串行问题
  7. .el-table .cell:has(div) .el-table__placeholder {
  8. display: unset;
  9. }
  10. /* Button 按钮
  11. ------------------------------- */
  12. // 第三方字体图标大小
  13. .el-button i.el-icon,
  14. .el-button i.iconfont,
  15. .el-button i.fa,
  16. .el-button--default i.iconfont,
  17. .el-button--default i.fa {
  18. font-size: 14px !important;
  19. margin-right: 5px;
  20. }
  21. .el-button--small i.iconfont,
  22. .el-button--small i.fa {
  23. font-size: 12px !important;
  24. margin-right: 5px;
  25. }
  26. .el-image {
  27. vertical-align: top;
  28. }
  29. .image-slot {
  30. display: flex;
  31. flex-direction: column;
  32. justify-content: center;
  33. align-items: center;
  34. width: 100%;
  35. height: 100%;
  36. background: var(--el-fill-color-light);
  37. color: var(--el-text-color-secondary);
  38. font-size: 12px;
  39. gap: 2px;
  40. }
  41. .el-button.el-button--text.el-button--small {
  42. padding: 0;
  43. }
  44. .el-button.is-text.el-button--small {
  45. padding: 0;
  46. }
  47. /* Input 输入框、InputNumber 计数器
  48. ------------------------------- */
  49. // 菜单搜索
  50. .el-autocomplete-suggestion__wrap {
  51. max-height: 280px !important;
  52. }
  53. /* Alert 警告
  54. ------------------------------- */
  55. .el-alert {
  56. border: 1px solid;
  57. }
  58. .el-alert__title {
  59. word-break: break-all;
  60. }
  61. /* Message 消息提示
  62. ------------------------------- */
  63. .el-message {
  64. min-width: unset !important;
  65. padding: 15px !important;
  66. box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.02);
  67. }
  68. /* NavMenu 导航菜单
  69. ------------------------------- */
  70. // 鼠标 hover 时颜色
  71. .el-menu-hover-bg-color {
  72. background-color: var(--next-color-menu-hover-blue) !important;
  73. // background-color: var(--next-color-menu-hover) !important;
  74. }
  75. // 默认样式修改
  76. .el-menu {
  77. border-right: none !important;
  78. width: 220px;
  79. }
  80. // 修复点击左侧菜单折叠再展开时,宽度不跟随问题
  81. .el-menu--collapse {
  82. width: 64px !important;
  83. }
  84. .el-menu-item,
  85. .el-sub-menu__title {
  86. // color: var(--next-bg-menuBarColor);
  87. color: var(--next-bg-menuBar-black);
  88. }
  89. .el-menu.el-menu--horizontal {
  90. border-bottom: none !important;
  91. }
  92. .el-menu-item {
  93. height: 56px !important;
  94. line-height: 56px !important;
  95. }
  96. // 外部链接时
  97. .el-menu-item a,
  98. .el-menu-item a:hover,
  99. .el-menu-item i,
  100. .el-sub-menu__title i {
  101. color: inherit;
  102. text-decoration: none;
  103. }
  104. // 第三方图标字体间距/大小设置
  105. .el-menu-item .iconfont,
  106. .el-sub-menu .iconfont,
  107. .el-menu-item .fa,
  108. .el-sub-menu .fa {
  109. @include generalIcon;
  110. }
  111. .el-menu-item.is-active,
  112. .el-sub-menu.is-active .el-sub-menu__title {
  113. @extend .el-menu-hover-bg-color;
  114. i,
  115. span {
  116. color: var(--next-color-menu-text-blue) !important;
  117. }
  118. }
  119. .el-sub-menu.is-active.is-opened {
  120. .el-sub-menu__title {
  121. background-color: unset !important;
  122. }
  123. i,
  124. span {
  125. color: unset !important;
  126. }
  127. }
  128. // 高亮时
  129. .el-menu-item.is-active {
  130. color: var(--next-color-menu-text-blue) !important;
  131. }
  132. // 鼠标 hover 时
  133. .el-menu-item:hover,
  134. .el-sub-menu__title:hover {
  135. @extend .el-menu-hover-bg-color;
  136. }
  137. // 菜单收起时且时 a 链接
  138. .el-popper.is-dark a {
  139. color: var(--el-color-white) !important;
  140. text-decoration: none;
  141. }
  142. // 菜单收起时鼠标经过背景颜色/字体颜色
  143. .el-popper.is-light {
  144. .el-menu--vertical {
  145. .el-menu {
  146. background: var(--next-bg-menuBar);
  147. }
  148. }
  149. .el-menu--horizontal {
  150. background: var(--next-bg-topBar);
  151. .el-menu,
  152. .el-menu-item,
  153. .el-sub-menu__title {
  154. color: var(--next-bg-topBarColor);
  155. background: var(--next-bg-topBar);
  156. }
  157. }
  158. }
  159. /* Tabs 标签页
  160. ------------------------------- */
  161. .el-tabs__nav-wrap::after {
  162. height: 1px !important;
  163. }
  164. /* Dropdown 下拉菜单
  165. ------------------------------- */
  166. .el-dropdown-menu {
  167. list-style: none !important; /*修复 Dropdown 下拉菜单样式问题 2022.03.04*/
  168. }
  169. .el-dropdown-menu .el-dropdown-menu__item {
  170. white-space: nowrap;
  171. }
  172. /* Steps 步骤条
  173. ------------------------------- */
  174. .el-step__icon-inner {
  175. font-size: 30px !important;
  176. font-weight: 400 !important;
  177. }
  178. .el-step__title {
  179. font-size: 14px;
  180. }
  181. /* Dialog 对话框
  182. ------------------------------- */
  183. .el-overlay {
  184. overflow: hidden;
  185. .el-overlay-dialog {
  186. display: flex;
  187. align-items: center;
  188. justify-content: center;
  189. position: unset !important;
  190. width: 100%;
  191. height: 100%;
  192. .el-dialog {
  193. margin: 0 auto !important;
  194. position: absolute;
  195. .el-dialog__body {
  196. padding: 20px !important;
  197. }
  198. }
  199. }
  200. }
  201. .el-dialog__body {
  202. max-height: calc(90vh - 111px) !important;
  203. min-height: 200px !important;
  204. overflow-y: auto;
  205. overflow-x: hidden;
  206. }
  207. .custom-dialog .el-dialog__body {
  208. max-height: none !important;
  209. }
  210. .el-dialog.is-fullscreen {
  211. .el-dialog__body {
  212. max-height: 100vh !important;
  213. }
  214. }
  215. /* Card 卡片
  216. ------------------------------- */
  217. .el-card__header {
  218. padding: 15px 20px;
  219. }
  220. /* scrollbar
  221. ------------------------------- */
  222. .el-scrollbar__bar {
  223. z-index: 4;
  224. }
  225. .el-scrollbar__wrap {
  226. max-height: 100%; /*防止页面切换时,滚动条高度不变的问题(滚动条高度非滚动条滚动高度)*/
  227. }
  228. .el-select-dropdown .el-scrollbar__wrap {
  229. overflow-x: scroll !important;
  230. }
  231. .el-select-dropdown__wrap {
  232. max-height: 274px !important; /*修复Select 选择器高度问题*/
  233. }
  234. .el-cascader-menu__wrap.el-scrollbar__wrap {
  235. height: 204px !important; /*修复Cascader 级联选择器高度问题*/
  236. }
  237. /* Drawer 抽屉
  238. ------------------------------- */
  239. .el-drawer {
  240. --el-drawer-padding-primary: unset !important;
  241. .el-drawer__header {
  242. padding: 0 15px !important;
  243. height: 50px;
  244. display: flex;
  245. align-items: center;
  246. margin-bottom: 0 !important;
  247. border-bottom: 1px solid var(--el-border-color-base);
  248. color: var(--el-text-color-primary);
  249. }
  250. .el-drawer__body {
  251. width: 100%;
  252. height: 100%;
  253. overflow: auto;
  254. }
  255. }
  256. .el-tree-node__label,
  257. .custom-tree-node {
  258. overflow: hidden;
  259. text-overflow: ellipsis;
  260. }
  261. .el-popper {
  262. max-width: 50vw;
  263. }