Files
pqs-9100_client/frontend/src/styles/element.scss

606 lines
11 KiB
SCSS
Raw Normal View History

2024-08-22 11:27:06 +08:00
/* 设置 notification、message 层级在 loading 之上 */
.el-message,
.el-notification {
z-index: 2058 !important;
}
/* el-alert */
.el-alert {
border: 1px solid;
}
/* 当前页面最大化 css */
.main-maximize {
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.aside-split,
.el-aside,
.el-header,
.el-footer,
.tabs-box {
display: none !important;
}
}
/* mask image */
.mask-image {
padding-right: 50px;
2024-10-21 13:37:27 +08:00
mask-image: linear-gradient(90deg,
2024-10-28 13:25:45 +08:00
#000000 0%,
#000000 calc(100% - 50px),
transparent);
2024-08-22 11:27:06 +08:00
}
/* custom card */
.card {
box-sizing: border-box;
padding: 20px;
overflow-x: hidden;
background-color: var(--el-bg-color);
border: 1px solid var(--el-border-color-light);
border-radius: 6px;
box-shadow: 0 0 12px rgb(0 0 0 / 5%);
}
/* ProTable 不需要 card 样式(在组件内使用 ProTable 会使用到) */
.no-card {
.card {
padding: 0;
background-color: transparent;
border: none;
border-radius: 0;
box-shadow: none;
}
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.table-search {
padding: 18px 0 0 !important;
margin-bottom: 0 !important;
}
}
/* content-box (常用内容盒子) */
.content-box {
display: flex;
flex-direction: column;
align-items: center;
height: 100%;
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.text {
margin: 20px 0 30px;
font-size: 23px;
font-weight: bold;
color: var(--el-text-color-regular);
}
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.el-descriptions {
width: 100%;
padding: 40px 0 0;
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.el-descriptions__title {
font-size: 18px;
}
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.el-descriptions__label {
width: 200px;
}
}
}
/* main-box (树形表格 treeFilter 页面会使用,左右布局 flex) */
.main-box {
display: flex;
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.table-box {
// 这里减去的 230px 是 treeFilter 组件宽度
width: calc(100% - 230px);
}
}
/* proTable */
.table-box,
.table-main {
display: flex;
flex: 1;
flex-direction: column;
width: 100%;
height: 100%;
// table-search 表格搜索样式
.table-search {
padding: 18px 18px 0;
margin-bottom: 10px;
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.el-form {
2024-10-28 13:25:45 +08:00
.el-form-item__content > * {
2024-08-22 11:27:06 +08:00
width: 100%;
}
// 去除时间选择器上下 padding
.el-range-editor.el-input__wrapper {
padding: 0 10px;
}
}
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.operation {
display: flex;
align-items: center;
justify-content: flex-end;
margin-bottom: 18px;
}
}
// 表格 header 样式
.table-header {
.header-button-lf {
float: left;
}
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.header-button-ri {
float: right;
}
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.el-button {
margin-bottom: 15px;
}
}
2024-12-06 09:18:13 +08:00
.el-table__body {
// border-left: 1px solid var(--el-table-border-color)
}
2024-08-22 11:27:06 +08:00
// el-table 表格样式
.el-table {
2024-12-05 18:14:43 +08:00
// border: 1px solid var(--el-table-border-color);
2024-10-10 17:47:55 +08:00
// flex: 1;
width: 100%;
height: 100%;
2024-12-06 09:18:13 +08:00
border-left: 1px solid var(--el-table-border-color) // 修复 safari 浏览器表格错位 https://github.com/HalseySpicy/Geeker-Admin/issues/83
2024-08-22 11:27:06 +08:00
table {
width: 100%;
}
2024-10-21 13:37:27 +08:00
2024-08-27 18:37:46 +08:00
.el-table__header th,
.el-table-fixed-column--left th,
.el-table-fixed-column--right th {
// height: 45px;
2024-08-22 11:27:06 +08:00
font-size: 15px;
font-weight: bold;
2024-08-27 18:37:46 +08:00
// color: var(--el-text-color-primary);
// background: var(--el-fill-color-light);
height: 40px;
background: var(--el-color-primary) !important;
color: #fff;
2024-08-22 11:27:06 +08:00
}
2024-08-27 18:37:46 +08:00
2024-08-22 11:27:06 +08:00
.el-table__row {
2024-08-27 18:37:46 +08:00
// height: 45px;
height: 40px;
2024-08-22 11:27:06 +08:00
font-size: 14px;
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.move {
cursor: move;
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.el-icon {
cursor: move;
}
}
}
// 设置 el-table 中 header 文字不换行,并省略
2024-10-28 13:25:45 +08:00
.el-table__header .el-table__cell > .cell {
2024-08-22 11:27:06 +08:00
// white-space: nowrap;
white-space: wrap;
}
// 解决表格数据为空时样式不居中问题(仅在element-plus中)
.el-table__empty-block {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.table-empty {
line-height: 30px;
}
}
// table 中 image 图片样式
.table-image {
width: 50px;
height: 50px;
border-radius: 50%;
}
}
// 表格 pagination 样式
.el-pagination {
display: flex;
justify-content: flex-end;
margin-top: 20px;
}
}
/* el-table 组件大小 */
.el-table--small {
.el-table__header th {
height: 40px !important;
font-size: 14px !important;
}
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.el-table__row {
height: 40px !important;
font-size: 13px !important;
}
}
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.el-table--large {
.el-table__header th {
height: 50px !important;
font-size: 16px !important;
}
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.el-table__row {
height: 50px !important;
font-size: 15px !important;
}
}
/* el-drawer */
.el-drawer {
.el-drawer__header {
padding: 16px 20px;
margin-bottom: 0;
border-bottom: 1px solid var(--el-border-color-lighter);
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
span {
font-size: 17px;
line-height: 17px;
color: var(--el-text-color-primary) !important;
}
}
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.el-drawer__footer {
border-top: 1px solid var(--el-border-color-lighter);
}
// select 样式
.el-select {
width: 100%;
}
2024-10-21 13:37:27 +08:00
2024-08-27 18:37:46 +08:00
.el-select-dropdown__item:hover {
background: red !important;
}
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
// drawer-form 中存在两列 form-item 样式
.drawer-multiColumn-form {
display: flex;
flex-wrap: wrap;
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.el-form-item {
width: 47%;
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
&:nth-child(2n-1) {
margin-right: 5%;
}
}
}
}
/* el-dialog */
2024-08-28 15:39:08 +08:00
// .el-dialog {
// .el-dialog__header {
// padding: 15px 20px;
// margin: 0;
// border-bottom: 1px solid var(--el-border-color-lighter);
// .el-dialog__title {
// font-size: 17px;
// }
// }
// }
//全局dialog修改
2024-08-22 11:27:06 +08:00
.el-dialog {
2024-08-28 15:39:08 +08:00
padding: 0px !important;
2024-10-21 14:43:37 +08:00
border: 0 solid #3665a0;
2024-10-21 13:37:27 +08:00
2024-08-22 11:27:06 +08:00
.el-dialog__header {
2024-08-28 15:39:08 +08:00
background: var(--el-color-primary);
2024-10-21 13:37:27 +08:00
padding: 10px;
2024-08-28 15:39:08 +08:00
margin-right: 0px;
// font-family:;
.el-dialog__headerbtn {
.el-icon {
color: var(--el-color-white);
}
}
2024-10-21 13:37:27 +08:00
2024-08-28 15:39:08 +08:00
.el-dialog__headerbtn:hover {
.el-icon {
color: #409eff;
}
}
2024-08-22 11:27:06 +08:00
.el-dialog__title {
2024-08-28 15:39:08 +08:00
color: var(--el-color-white);
}
.el-dialog__footer .el-button {
margin-left: 10px !important;
2024-08-22 11:27:06 +08:00
}
}
2024-10-21 13:37:27 +08:00
2024-10-28 13:25:45 +08:00
.el-overlay {
position: absolute;
}
2024-08-28 15:39:08 +08:00
.el-dialog__body {
2024-10-21 13:37:27 +08:00
// height: 200px;
// max-height: 60vh;
2024-10-23 19:16:36 +08:00
//min-height: 200px;
2024-08-28 15:39:08 +08:00
overflow-y: auto;
padding: 10px 15px;
2024-08-28 15:39:08 +08:00
//设置dialog内部form样式
.el-form {
.el-form-item {
margin-bottom: 20px;
2024-10-21 13:37:27 +08:00
2024-08-28 15:39:08 +08:00
.el-select,
.el-input,
.el-date-picker {
width: 100%;
height: 32px;
}
}
}
}
2024-10-21 13:37:27 +08:00
2024-08-28 15:39:08 +08:00
.el-dialog__footer {
2024-10-21 13:37:27 +08:00
padding: 8px 10px;
2024-08-28 15:39:08 +08:00
box-shadow: var(--el-box-shadow);
border-top: 1px solid #cccccc;
width: 100%;
bottom: 0;
2024-10-28 13:25:45 +08:00
.el-button {
font-size: 12px;
padding: 5px 11px;
height: 24px;
2024-10-21 13:37:27 +08:00
}
2024-10-28 13:25:45 +08:00
.el-button + .el-button {
margin-left: 10px;
2024-10-21 13:37:27 +08:00
}
2024-10-28 13:25:45 +08:00
}
2024-08-28 15:39:08 +08:00
}
2024-10-21 13:37:27 +08:00
2024-08-28 15:39:08 +08:00
//全局el-form-item间距
2024-08-27 18:37:46 +08:00
.el-form-item {
margin-right: 10px !important;
2024-08-28 15:39:08 +08:00
margin-bottom: 20px !important;
2024-08-27 18:37:46 +08:00
}
2024-10-21 13:37:27 +08:00
2024-09-02 16:10:33 +08:00
.el-tree-node__content:hover {
2024-10-10 17:47:55 +08:00
// background-color: var(--el-color-primary) !important;
// color: #fff;
}
2024-10-21 13:37:27 +08:00
.el-tree-node is-expanded is-current is-focusable is-checked {
2024-09-02 16:10:33 +08:00
background-color: var(--el-color-primary) !important;
color: #fff;
}
2024-10-21 13:37:27 +08:00
2024-10-10 17:47:55 +08:00
.el-table__body-wrapper,
.el-scrollbar {
2024-09-02 18:54:03 +08:00
/* scroll bar */
z-index: 2001;
2024-10-21 13:37:27 +08:00
2024-09-02 18:54:03 +08:00
&::-webkit-scrollbar {
width: 8px !important;
2024-12-05 18:14:43 +08:00
height: 8px !important;
2024-09-02 18:54:03 +08:00
// background-color: var(--el-color-primary);
2024-10-10 17:47:55 +08:00
z-index: 3001;
2024-09-02 18:54:03 +08:00
}
2024-10-21 13:37:27 +08:00
2024-09-02 18:54:03 +08:00
/* 滚动条实际可拖动部分的颜色 */
::-webkit-scrollbar-thumb {
width: 8px;
height: 100px;
background-color: var(--el-border-color-darker) !important;
// background-color: var(--el-color-primary);
border-radius: 20px;
background-color: var(--el-color-primary) !important;
cursor: pointer;
z-index: 3001;
}
}
/* ---el-table滚动条公共样式--- */
.el-scrollbar {
2024-10-21 13:37:27 +08:00
2024-09-02 18:54:03 +08:00
// 横向滚动条
.el-scrollbar__bar.is-horizontal .el-scrollbar__thumb {
opacity: 1; // 默认滚动条自带透明度
height: 20px; // 横向滑块的宽度
border-radius: 4px; // 圆角度数
background-color: var(--el-color-primary); // 滑块背景色
box-shadow: 0 0 6px rgba(0, 0, 0, 0.15); // 滑块阴影
}
2024-10-21 13:37:27 +08:00
2024-09-02 18:54:03 +08:00
// 纵向滚动条
.el-scrollbar__bar.is-vertical .el-scrollbar__thumb {
opacity: 1;
width: 6px; // 纵向滑块的宽度
border-radius: 4px;
background-color: var(--el-color-primary);
box-shadow: 0 0 6px rgba(0, 0, 0, 0.15);
}
2024-10-10 17:47:55 +08:00
}
2024-10-21 13:37:27 +08:00
2024-10-28 13:25:45 +08:00
.dialog-small {
.el-dialog__body {
max-height: 350px;
2024-10-21 13:37:27 +08:00
}
}
2024-10-28 13:25:45 +08:00
.dialog-middle {
.el-dialog__body {
2024-10-21 13:37:27 +08:00
max-height: 400px;
}
}
2024-10-28 13:25:45 +08:00
.dialog-big {
.el-dialog__body {
2024-10-21 13:37:27 +08:00
max-height: 620px;
}
2024-10-21 14:43:37 +08:00
}
.cn-render-buttons {
cursor: pointer;
display: inline-block;
margin-left: 13px;
line-height: 18px;
padding: 2px;
2024-12-06 09:18:13 +08:00
.icon {
font-size: 12px !important;
// color: var(--ba-bg-color-overlay) !important;
}
2024-12-05 11:07:54 +08:00
}
2024-12-06 09:18:13 +08:00
.el-message-box {
2024-12-05 11:07:54 +08:00
padding: 0px !important;
2024-12-06 09:18:13 +08:00
.el-message-box__header {
background-color: var(--el-color-primary);
.el-message-box__title {
2024-12-05 11:07:54 +08:00
color: #fff;
padding: 10px 10px 0;
}
2024-12-06 09:18:13 +08:00
2024-12-05 11:07:54 +08:00
}
2024-12-05 15:22:46 +08:00
2024-12-06 09:18:13 +08:00
.el-message-box__headerbtn {
2024-12-05 15:22:46 +08:00
top: 5px;
}
2024-12-06 09:18:13 +08:00
.el-message-box__close {
svg {
2024-12-05 15:22:46 +08:00
color: #fff;
}
2024-12-06 09:18:13 +08:00
:hover {
2024-12-05 15:22:46 +08:00
color: #409eff;
}
}
2024-12-06 09:18:13 +08:00
.el-message-box__content {
padding: 10px;
2024-12-05 11:07:54 +08:00
border-bottom: 1px solid #cccccc;
}
2024-12-06 09:18:13 +08:00
2024-12-05 11:07:54 +08:00
.el-message-box__btns {
2024-12-06 09:18:13 +08:00
padding: 10px;
2024-12-05 15:22:46 +08:00
}
2024-12-06 09:18:13 +08:00
}
.form-one {
display: flex;
flex-wrap: wrap;
justify-content: space-between;
2024-12-05 15:22:46 +08:00
2024-12-06 09:18:13 +08:00
.el-form-item {
2024-12-05 15:22:46 +08:00
display: flex;
2024-12-06 09:18:13 +08:00
width: 98%;
margin-bottom: 15px !important;
.el-form-item__content {
flex: 1;
.el-select,
.el-cascader,
.el-input__inner,
.el-date-editor {
width: 100%;
}
2024-12-05 15:22:46 +08:00
}
2024-12-06 09:18:13 +08:00
}
2024-12-05 15:22:46 +08:00
}
2024-12-06 09:18:13 +08:00
2024-12-05 15:22:46 +08:00
.form-two {
2024-12-06 09:18:13 +08:00
display: flex;
flex-wrap: wrap;
justify-content: space-between;
.el-form-item {
2024-12-05 15:22:46 +08:00
display: flex;
2024-12-06 09:18:13 +08:00
width: 48%;
.el-form-item__content {
flex: 1;
.el-select,
.el-cascader,
.el-input__inner,
.el-date-editor {
width: 100%;
}
2024-12-05 15:22:46 +08:00
}
2024-12-06 09:18:13 +08:00
}
2024-12-05 15:22:46 +08:00
}
2024-12-06 09:18:13 +08:00
2024-12-05 15:22:46 +08:00
.form-three {
2024-12-06 09:18:13 +08:00
display: flex;
flex-wrap: wrap;
// justify-content: space-between;
.el-form-item {
2024-12-05 15:22:46 +08:00
display: flex;
2024-12-06 09:18:13 +08:00
width: 32.3%;
.el-form-item__content {
flex: 1;
.el-select,
.el-cascader,
.el-input__inner,
.el-date-editor {
width: 100%;
}
2024-12-05 15:22:46 +08:00
}
2024-12-06 09:18:13 +08:00
}
}
.form-four {
display: flex;
flex-wrap: wrap;
// justify-content: space-between;
.el-form-item {
display: flex;
width: 24%;
.el-form-item__content {
flex: 1;
.el-select,
.el-cascader,
.el-input__inner,
.el-date-editor {
width: 100%;
}
}
}
}
2024-12-06 09:18:13 +08:00
.el-table__cell {
border-right: 1px solid #ebeef5 !important;
border-left: 1px solid #ebeef5 !important;
}