Files
halo_theme_terminal/src/styles/post.scss
T
2025-08-08 00:38:02 +08:00

169 lines
3.4 KiB
SCSS

@use "variables" as *;
.index-content {
margin: calc(var(--font-theme-size) * 1.5625) 0;
}
.framed {
border: calc(var(--font-theme-size) * 0.0625) solid var(--color-theme-framed);
padding: calc(var(--font-theme-size) * 1.25);
}
.framed *:first-child {
margin-top: 0;
}
.framed *:last-child {
margin-bottom: 0;
}
.posts {
width: 100%;
}
.post {
width: 100%;
text-align: left;
padding: calc(var(--font-theme-size) * 1.875) 0;
}
.post:not(:last-of-type) {
border-bottom: calc(var(--font-theme-size) * 0.0625) solid color-mix(in srgb, var(--color-theme-foreground) 10%, transparent);
}
.post-meta {
font-size: calc(var(--font-theme-size) * 0.96);
margin-bottom: calc(var(--font-theme-size) * 0.3125);
color: color-mix(in srgb, var(--color-theme-meta) 65%, transparent);
}
.post-meta > *:not(:first-child)::before {
content: "::";
display: inline-block;
margin-right: 1ch;
}
.post-title {
position: relative;
color: var(--color-theme-title);
margin-top: 0 !important;
margin-bottom: calc(var(--font-theme-size) * 0.9375) !important;
padding-bottom: calc(var(--font-theme-size) * 0.9375) !important;
border-bottom: calc(var(--font-theme-size) * 0.1875) dotted var(--color-theme-accent);
text-decoration: none !important;
}
.post-title::after {
content: "";
position: absolute;
bottom: calc(var(--font-theme-size) * 0.125);
display: block;
width: 100%;
border-bottom: calc(var(--font-theme-size) * 0.1875) dotted var(--color-theme-accent);
}
.post-title a {
text-decoration: none;
color: var(--color-theme-title);
}
.post-tags {
display: block;
margin-bottom: calc(var(--font-theme-size) * 0.3125);
font-size: inherit;
}
.post-tag {
color: var(--color-theme-tag);
a {
color: inherit;
}
}
.post-meta .post-tags {
font-size: calc(var(--font-theme-size) * 0.95);
}
.table-of-contents {
margin: calc(var(--font-theme-size) * 0.5) 0;
}
.post-excerpt {
font-size: calc(var(--font-theme-size) * 0.98);
margin-bottom: calc(var(--font-theme-size) * 0.625);
}
.post-content {
margin-top: calc(var(--font-theme-size) * 1.5625);
}
.post-cover {
margin: calc(var(--font-theme-size) * 1.5625) 0;
}
.post ul {
list-style: none;
}
.post ul li:not(:empty)::before {
content: var(--list-theme-marker);
position: absolute;
left: calc(var(--font-theme-size) * -1.25);
color: var(--color-theme-foreground);
}
.post--regulation h1 {
justify-content: center;
}
.post--regulation h2 {
justify-content: center;
margin-bottom: calc(var(--font-theme-size) * -0.625);
}
.post--regulation h2 + h2 {
margin-top: calc(var(--font-theme-size) * -0.625);
margin-bottom: calc(var(--font-theme-size) * 1.25);
}
.hanchor {
position: absolute;
color: var(--color-theme-accent);
text-decoration: none;
margin-left: calc(var(--font-theme-size) * 0.625);
visibility: hidden;
}
h1:hover .hanchor,
h2:hover .hanchor,
h3:hover .hanchor,
h4:hover .hanchor,
h5:hover .hanchor,
h6:hover .hanchor {
visibility: visible;
}
.footnotes {
color: color-mix(in srgb, var(--color-theme-foreground) 50%, transparent);
}
.footnotes hr {
background: color-mix(in srgb, var(--color-theme-foreground) 50%, transparent);
}
.post-list {
padding: calc(var(--font-theme-size) * 0.25) 0;
a {
text-decoration: none;
}
}
@media (max-width: $phone-max-width) {
.post-cover {
padding: calc(var(--font-theme-size) * 0.625);
border-width: calc(var(--font-theme-size) * 0.625);
}
}