perf: 优化消息样式

This commit is contained in:
kuaifan 2024-11-22 23:11:27 +08:00
parent cee2458370
commit fe8deb98a2

View File

@ -818,23 +818,19 @@
ol, ol,
ul { ul {
padding-left: 1.5em;
list-style-type: none;
li { li {
display: flex;
list-style-type: none;
&::before { &::before {
flex-shrink: 0; position: absolute;
white-space: nowrap; left: 0;
width: 1.2em; width: 1.5em;
color: #0088ff; color: #0088ff;
text-align: left; display: flex;
margin-right: 0.2em; justify-content: center;
} align-items: center;
&[data-list=unchecked] {
&::before {
color: #777;
}
} }
.mention { .mention {
@ -843,54 +839,52 @@
} }
} }
ul {
li {
&::before {
content: '\2022';
font-weight: 900;
}
}
}
ol { ol {
li { li {
counter-reset: list-1 list-2 list-3 list-4 list-5 list-6 list-7 list-8 list-9; counter-reset: list-1 list-2 list-3 list-4 list-5 list-6 list-7 list-8 list-9;
counter-increment: list-0; counter-increment: list-0;
&:before { &::before {
width: auto; content: counter(list-0, decimal) ".";
min-width: 1.2em;
content: counter(list-0, decimal) '. ';
} }
&[data-list=bullet] { &[data-list=bullet] {
&:before { &::before {
content: '\2022'; content: '\2022';
font-weight: 900; font-weight: 900;
text-align: center; transform: scale(1.12);
} }
} }
&[data-list=checked], &[data-list=checked],
&[data-list=unchecked] { &[data-list=unchecked] {
&:before { &::before {
font-family: "taskfont", "serif" !important; font-family: "taskfont", "serif" !important;
font-size: 14px; font-size: 14px;
content: "\e6ed"; content: "\e6ed";
font-weight: normal;
transform: scale(1.12); transform: scale(1.12);
transform-origin: left top;
} }
} }
&[data-list=unchecked] { &[data-list=unchecked] {
&:before { &::before {
content: "\e6f1"; content: "\e6f1";
color: #777;
} }
} }
} }
} }
ul {
li {
&::before {
content: '\2022';
font-weight: 900;
transform: scale(1.12);
}
}
}
blockquote { blockquote {
border-left: 4px solid #ccc; border-left: 4px solid #ccc;
margin-bottom: 5px; margin-bottom: 5px;