1
0
mirror of synced 2026-04-05 07:48:35 +08:00

refactor(editor): 重构右键菜单

This commit is contained in:
roymondchen
2022-05-05 20:22:50 +08:00
committed by jia000
parent 34eb57b37a
commit 56375b0fb0
8 changed files with 425 additions and 290 deletions

View File

@@ -2,38 +2,45 @@
position: fixed;
font-size: 12px;
background: #fff;
color: #333;
box-shadow: 0 2px 8px 2px rgba(68, 73, 77, 0.16);
z-index: 9999;
transform-origin: 0% 0%;
font-weight: 600;
padding: 4px 0px;
overflow: auto;
max-height: 100%;
.separation {
width: 100%;
height: 0;
border-color: rgba(155, 155, 155, 0.1);
}
.subMenu {
position: absolute;
right: 0;
transform: translate(100%, 0);
background-color: #fff;
.menu-item {
color: #333;
box-shadow: 0 2px 8px 2px rgba(68, 73, 77, 0.16);
top: 0;
height: 223px;
display: flex;
-webkit-box-align: center;
align-items: center;
cursor: pointer;
min-width: 140px;
transition: all 0.2s ease 0s;
padding: 5px 14px;
border-left: 2px solid transparent;
.el-button {
width: 100%;
justify-content: flex-start;
}
.el-button--text,
i {
color: $--font-color;
}
&.divider {
padding: 0 14px;
.el-divider {
margin: 0;
}
}
&:hover {
background-color: #f3f5f9;
}
}
}
.magic-editor-content-menu-item {
display: flex;
-webkit-box-align: center;
align-items: center;
cursor: pointer;
min-width: 140px;
transition: all 0.2s ease 0s;
padding: 10px 14px;
border-left: 2px solid transparent;
}