🐯美化模态框,解决关闭后模态框无法删除的bug

This commit is contained in:
2024-09-07 10:32:07 +08:00
parent dfd83fa548
commit 126c7f88f0
2 changed files with 38 additions and 12 deletions

View File

@ -133,7 +133,7 @@ body {
}
.modal-content {
position: absolute;
position: relative;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
@ -143,11 +143,17 @@ body {
border: 1px solid var(--border-color);
z-index: 1000;
max-height: 90%;
overflow-y: auto;
overflow: hidden;
border-radius: 20px;
transition: opacity 0.3s;
}
.modal-content:hover {
#modal-bg-avatar {
transform: scale(1.1);
}
}
@media screen and (max-width: 440px) {
.modal-content {
width: 80%;
@ -156,13 +162,27 @@ body {
#modal-author-avatar {
display: block;
margin: 0 auto;
border-radius: 50%;
width: 100px;
height: 100px;
margin: 5px auto !important;
border-radius: 50% !important;
width: 110px;
height: 110px;
object-fit: cover;
}
#modal-bg-avatar {
position: absolute;
filter: blur(5px);
z-index: 0;
border-radius: 125px 125px 12px 125px !important;
margin: 0 !important;
width: 250px;
height: 250px;
right: -20px;
bottom: -20px;
opacity: 0.2;
transition: transform 0.6s ease, bottom 0.3s ease, right 0.3s ease !important; /* 0.3秒的平滑过渡效果 */
}
#modal-author-name-link {
display: block;
text-align: center;
@ -181,6 +201,8 @@ body {
}
#modal-articles-container {
position: relative;
z-index: 1;
border-top: var(--hover-color) double 2px;
margin-top: 20px;
padding-top: 10px;
@ -278,7 +300,7 @@ body {
font-size: 12px;
color: var(--author-color);
padding: 5px;
transition: box-shadow 0.2s;
height: 25px;
}
.card-author:hover {
@ -293,8 +315,8 @@ body {
display: flex;
padding-right: 10px;
width: fit-content;
height: 26px;
align-items: center;
transition: box-shadow 0.2s;
}
#friend-circle-lite-root .card-author img {
@ -308,7 +330,7 @@ body {
.card-date {
position: absolute;
z-index: 1;
bottom: 5px;
bottom: 10px;
cursor: default;
right: 10px;
display: flex;