element.scss 7.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349
  1. @import 'mixins/index.scss';
  2. /* Button 按钮
  3. ------------------------------- */
  4. // 第三方字体图标大小
  5. // 第三方字体图标大小
  6. // .el-button i.el-icon,
  7. // .el-button i.iconfont,
  8. // .el-button i.fa,
  9. // .el-button--default i.iconfont,
  10. // .el-button--default i.fa {
  11. // font-size: 14px !important;
  12. // margin-right: 5px;
  13. // }
  14. // .el-button--small i.iconfont,
  15. // .el-button--small i.fa {
  16. // font-size: 12px !important;
  17. // margin-right: 5px;
  18. // }
  19. /* Input 输入框、InputNumber 计数器
  20. ------------------------------- */
  21. // .el-input {
  22. // height: 100%;
  23. // }
  24. // 菜单搜索
  25. .el-autocomplete-suggestion__wrap {
  26. max-height: 280px !important;
  27. }
  28. /* Alert 警告
  29. ------------------------------- */
  30. .el-alert {
  31. border: 1px solid;
  32. }
  33. .el-alert__title {
  34. word-break: break-all;
  35. }
  36. /* Message 消息提示
  37. ------------------------------- */
  38. .el-message {
  39. min-width: unset !important;
  40. padding: 15px !important;
  41. box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.02);
  42. }
  43. /* NavMenu 导航菜单
  44. ------------------------------- */
  45. // 鼠标 hover 时颜色
  46. .el-menu-hover-bg-color {
  47. //background-color: var(--hotline-color-menu-hover) !important;
  48. }
  49. // 默认样式修改
  50. .el-menu {
  51. border-right: none !important;
  52. width: 220px;
  53. }
  54. .el-menu-item {
  55. height: 56px !important;
  56. line-height: 56px !important;
  57. }
  58. .el-menu-item,
  59. .el-sub-menu__title {
  60. color: var(--hotline-bg-menuBarColor);
  61. }
  62. // 修复点击左侧菜单折叠再展开时,宽度不跟随问题
  63. .el-menu--collapse {
  64. width: 64px !important;
  65. }
  66. // 外部链接时
  67. .el-menu-item a,
  68. .el-menu-item a:hover,
  69. .el-menu-item i,
  70. .el-sub-menu__title i {
  71. color: inherit;
  72. text-decoration: none;
  73. }
  74. // 第三方图标字体间距/大小设置
  75. .el-menu-item .iconfont,
  76. .el-sub-menu .iconfont,
  77. .el-menu-item .fa,
  78. .el-sub-menu .fa {
  79. @include generalIcon;
  80. flex-shrink: 0;
  81. }
  82. // 水平菜单、横向菜单高亮 背景色,鼠标 hover 时,有子级菜单的背景色
  83. .el-menu-item.is-active,
  84. .el-sub-menu.is-active .el-sub-menu__title,
  85. .el-sub-menu:not(.is-opened):hover .el-sub-menu__title {
  86. @extend .el-menu-hover-bg-color;
  87. }
  88. .el-menu-item.is-active{
  89. //color: var(--hotline-color-white);
  90. color: var(--el-menu-active-color);
  91. }
  92. .el-sub-menu.is-active.is-opened .el-sub-menu__title {
  93. background-color: unset !important;
  94. }
  95. // 子级菜单背景颜色
  96. // .el-menu--inline {
  97. // background: var(--hotline-bg-menuBar-light-1);
  98. // }
  99. // 水平菜单、横向菜单折叠 a 标签
  100. .el-popper.is-dark a {
  101. color: var(--el-color-white) !important;
  102. text-decoration: none;
  103. }
  104. // 水平菜单、横向菜单折叠背景色
  105. .el-popper.is-pure.is-light {
  106. // 水平菜单
  107. .el-menu--vertical {
  108. background: var(--hotline-bg-menuBar);
  109. .el-sub-menu.is-active .el-sub-menu__title {
  110. color: var(--el-menu-active-color);
  111. }
  112. .el-popper.is-pure.is-light {
  113. .el-menu--vertical {
  114. .el-sub-menu .el-sub-menu__title {
  115. background-color: unset !important;
  116. color: var(--hotline-bg-menuBarColor);
  117. }
  118. .el-sub-menu.is-active .el-sub-menu__title {
  119. color: var(--el-menu-active-color);
  120. }
  121. }
  122. }
  123. }
  124. // 横向菜单
  125. .el-menu--horizontal {
  126. background: var(--hotline-bg-topBar);
  127. .el-menu-item,
  128. .el-sub-menu {
  129. height: 50px !important;
  130. line-height: 50px !important;
  131. color: var(--hotline-bg-topBarColor);
  132. .el-sub-menu__title {
  133. height: 50px !important;
  134. line-height: 50px !important;
  135. color: var(--hotline-bg-topBarColor);
  136. }
  137. .el-popper.is-pure.is-light {
  138. .el-menu--horizontal {
  139. .el-sub-menu .el-sub-menu__title {
  140. background-color: unset !important;
  141. color: var(--hotline-bg-topBarColor);
  142. }
  143. .el-sub-menu.is-active .el-sub-menu__title {
  144. color: var(--hotline-color-white);
  145. }
  146. }
  147. }
  148. }
  149. .el-menu-item.is-active,
  150. .el-sub-menu.is-active .el-sub-menu__title {
  151. //color: var(--hotline-color-white);
  152. color: var(--el-menu-active-color);
  153. }
  154. }
  155. }
  156. // 横向菜单(经典、横向)布局
  157. .el-menu.el-menu--horizontal {
  158. border-bottom: none !important;
  159. width: 100% !important;
  160. .el-menu-item,
  161. .el-sub-menu__title {
  162. height: 50px !important;
  163. color: var(--hotline-bg-topBarColor);
  164. }
  165. .el-menu-item:not(.is-active):hover,
  166. .el-sub-menu:not(.is-active):hover .el-sub-menu__title {
  167. color: var(--hotline-bg-topBarColor);
  168. }
  169. }
  170. /* Tabs 标签页
  171. ------------------------------- */
  172. .el-tabs__nav-wrap::after {
  173. height: 1px !important;
  174. }
  175. /* Dropdown 下拉菜单
  176. ------------------------------- */
  177. .el-dropdown-menu {
  178. list-style: none !important; /*修复 Dropdown 下拉菜单样式问题 2022.03.04*/
  179. }
  180. .el-dropdown-menu .el-dropdown-menu__item {
  181. white-space: nowrap;
  182. &:not(.is-disabled):hover {
  183. background-color: var(--el-dropdown-menuItem-hover-fill);
  184. color: var(--el-dropdown-menuItem-hover-color);
  185. }
  186. }
  187. /* Steps 步骤条
  188. ------------------------------- */
  189. .el-step__title {
  190. font-size: 14px;
  191. }
  192. /* Dialog 对话框
  193. ------------------------------- */
  194. .el-overlay {
  195. overflow: hidden;
  196. background-color: var(--hotline-overlay-color-lighter-4);
  197. .el-overlay-dialog {
  198. display: flex;
  199. align-items: center;
  200. justify-content: center;
  201. position: unset !important;
  202. width: 100%;
  203. height: 100%;
  204. }
  205. }
  206. .el-dialog {
  207. margin: 0 auto !important;
  208. position: absolute;
  209. border-radius: var(--el-border-radius-base);
  210. .el-dialog__title{
  211. font-size: 18px;
  212. font-weight: bold;
  213. }
  214. .el-dialog__header{
  215. border-bottom: 1px solid var(--el-border-color);
  216. margin-right:0 !important;
  217. padding: var(--el-dialog-padding-primary);
  218. }
  219. .el-dialog__body {
  220. max-height: calc(90vh - 111px) !important;
  221. padding: 20px 30px !important;
  222. overflow-y: auto;
  223. overflow-x: hidden;
  224. }
  225. }
  226. /* el-drawer 抽屉
  227. ------------------------------- */
  228. .el-drawer{
  229. .el-drawer__title{
  230. font-size: 18px;
  231. font-weight: bold;
  232. }
  233. }
  234. /* Card 卡片
  235. ------------------------------- */
  236. .el-card{
  237. margin-bottom: 10px;
  238. --el-card-border-radius: 8px;
  239. border: 0;
  240. &:last-child{
  241. margin: 0;
  242. }
  243. }
  244. .el-card__header {
  245. padding: 15px 20px;
  246. }
  247. /* Table 表格 element plus 2.2.0 版本
  248. ------------------------------- */
  249. .el-table {
  250. .el-button.is-text {
  251. padding: 0;
  252. }
  253. thead{
  254. height: 50px !important;
  255. color: var(--hotline-color-text-main);
  256. }
  257. th.el-table__cell{
  258. background-color: var(--hotline-bg-main-color) !important;
  259. }
  260. }
  261. .el-table-v2__header-row{
  262. background-color: var(--hotline-bg-main-color) !important;
  263. }
  264. .el-table-v2__header-cell{
  265. background-color: var(--hotline-bg-main-color) !important;
  266. color: var(--hotline-color-text-main);
  267. }
  268. /* scrollbar
  269. ------------------------------- */
  270. /*防止页面切换时,滚动条高度不变的问题(滚动条高度非滚动条滚动高度)*/
  271. .el-scrollbar__wrap {
  272. max-height: 100%;
  273. }
  274. .el-select-dropdown .el-scrollbar__wrap {
  275. overflow-x: scroll !important;
  276. }
  277. /*修复Select 选择器高度问题*/
  278. .el-select-dropdown__wrap {
  279. max-height: 274px !important;
  280. }
  281. /*修复Cascader 级联选择器高度问题*/
  282. .el-cascader-menu__wrap.el-scrollbar__wrap {
  283. height: 204px !important;
  284. }
  285. /*用于界面高度自适应(main.vue),区分 scrollbar__view,防止其它使用 scrollbar 的地方出现滚动条消失*/
  286. .layout-container-view .el-scrollbar__view {
  287. height: 100%;
  288. }
  289. /* Drawer 抽屉
  290. ------------------------------- */
  291. .el-drawer {
  292. // --el-drawer-padding-primary: unset !important;
  293. .el-drawer__header {
  294. padding: 0 15px !important;
  295. height: 50px;
  296. display: flex;
  297. align-items: center;
  298. margin-bottom: 0 !important;
  299. border-bottom: 1px solid var(--el-border-color);
  300. color: var(--el-text-color-primary);
  301. }
  302. .el-drawer__body {
  303. width: 100%;
  304. height: 100%;
  305. overflow: auto;
  306. }
  307. }
  308. /* 穿梭框宽度
  309. ------------------------------- */
  310. .el-transfer-panel{
  311. width: auto;
  312. }
  313. // 下拉框的字体大小
  314. .el-select-dropdown__option-item{
  315. font-size: var(--el-font-size-base);
  316. }
  317. // 分割线的margin
  318. .el-divider--horizontal{
  319. margin: 15px 0;
  320. }
  321. //这个应该是隐藏小时的代码
  322. .noneMinute {
  323. .el-scrollbar:nth-of-type(1) {
  324. display: none;
  325. }
  326. //调整样式
  327. .el-time-spinner {
  328. width: 150%;
  329. white-space: nowrap;
  330. }
  331. }
  332. /* 字体颜色
  333. ------------------------------- */
  334. //.el-text{
  335. // color: var(--el-text-color-primary);
  336. //}