档案管理

This commit is contained in:
cwchen 2025-09-18 13:57:18 +08:00
parent b5cef522d8
commit 1784d8e92c
1 changed files with 38 additions and 17 deletions

View File

@ -270,12 +270,14 @@ export default {
width: 100%;
}
/* 自定义节点行:左右布局,左侧文本省略号 */
/* 自定义节点行:左右布局,支持多行文本 */
.custom-tree-node {
display: flex;
align-items: center;
justify-content: space-between;
width: 100%;
min-height: 20px;
padding: 1px 0;
}
.node-label {
@ -284,28 +286,32 @@ export default {
overflow: visible;
text-overflow: initial;
white-space: normal;
/* 允许换行 */
word-break: break-word;
/* 长词断行 */
line-height: 20px;
word-wrap: break-word;
line-height: 1.2;
padding-right: 4px;
}
/* 使行容器自适应高度并顶对齐,兼容多行文本 */
/* 使行容器自适应高度,单行文本居中对齐,多行文本顶部对齐 */
.left-tree-list .el-tree-node__content {
display: flex;
align-items: flex-start;
align-items: center;
height: auto;
min-height: 28px;
padding-top: 6px;
padding-bottom: 6px;
line-height: 20px;
min-height: 20px;
padding: 1px 4px;
line-height: 1.2;
}
/* 多行文本时改为顶部对齐 */
.left-tree-list .el-tree-node__content:has(.node-label[style*="height"]) {
align-items: flex-start;
}
/* 高亮选中状态同样自适应高度 */
.el-tree--highlight-current .el-tree-node.is-current>.el-tree-node__content {
height: auto !important;
align-items: flex-start;
line-height: 20px;
align-items: center;
line-height: 1.2;
}
/* 选中节点的背景色 */
@ -340,9 +346,13 @@ export default {
.btn-box {
margin-left: 10px;
margin-left: 4px;
opacity: 0;
transition: opacity 0.15s ease-in-out;
flex-shrink: 0;
display: flex;
align-items: center;
gap: 1px;
}
/* 悬浮到整行时显示操作按钮 */
@ -350,14 +360,25 @@ export default {
opacity: 1;
}
/* 确保树节点内容正确显示 */
::v-deep .el-tree-node__content {
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
cursor: pointer;
height: auto;
min-height: 38px;
padding: 1px 4px;
}
/* 树节点展开/收起图标 */
::v-deep .el-tree-node__expand-icon {
padding: 1px;
margin-right: 1px;
flex-shrink: 0;
}
/* 树节点图标容器 */
::v-deep .el-tree-node__content > .el-tree-node__expand-icon {
flex-shrink: 0;
}
</style>