mirror of
https://gh.wpcy.net/https://github.com/discourse/discourse.git
synced 2026-05-27 15:41:10 +08:00
Using `last-of-type` means the margin is removed from the last paragraph, even if there are other elements that fall at the end of the banner... so we lose some needed space here: <img width="977" height="258" alt="image" src="https://github.com/user-attachments/assets/48195d9f-37b7-4a36-8ea6-96849d248b1e" /> if we use `last-child` it will ensure the `p` is actually the last node, so space is retained <img width="973" height="269" alt="image" src="https://github.com/user-attachments/assets/763975d3-d184-4c22-ad8b-393aac9b5ee4" />
57 lines
909 B
SCSS
Vendored
57 lines
909 B
SCSS
Vendored
// --------------------------------------------------
|
|
// Banner
|
|
// --------------------------------------------------
|
|
#banner {
|
|
padding: 1em;
|
|
background: var(--tertiary-low);
|
|
color: var(--primary);
|
|
z-index: z("base") + 1;
|
|
margin-bottom: 1em;
|
|
max-height: 20vh;
|
|
overflow: auto;
|
|
|
|
.floated-buttons {
|
|
float: right;
|
|
display: flex;
|
|
|
|
> .btn {
|
|
padding-top: 0;
|
|
padding-bottom: 0;
|
|
color: var(--primary-high);
|
|
|
|
.d-icon {
|
|
color: var(--primary-medium);
|
|
}
|
|
|
|
&:hover {
|
|
color: var(--primary);
|
|
|
|
.d-icon {
|
|
color: var(--primary-high);
|
|
}
|
|
}
|
|
}
|
|
|
|
.desktop-view & .btn.close {
|
|
margin-left: 0.25em;
|
|
}
|
|
}
|
|
}
|
|
|
|
#banner-content {
|
|
hr {
|
|
border-color: var(--primary-medium);
|
|
}
|
|
|
|
> p:first-child {
|
|
margin-top: 0;
|
|
}
|
|
|
|
> p:last-child {
|
|
margin-bottom: 0;
|
|
}
|
|
|
|
a.anchor {
|
|
display: none;
|
|
}
|
|
}
|