Template:Centered headers/styles.css: Difference between revisions
Template page
More actions
Content deleted Content added
Tesinormed (talk | contribs) No edit summary |
Tesinormed (talk | contribs) No edit summary |
||
| Line 9: | Line 9: | ||
display: flex; |
display: flex; |
||
flex-wrap: nowrap; |
flex-wrap: nowrap; |
||
justify- |
justify-items: center; |
||
align-items: center; |
align-items: center; |
||
gap: var(--space-md); |
gap: var(--space-md); |
||
| Line 19: | Line 19: | ||
text-align: center; |
text-align: center; |
||
font-weight: bold; |
font-weight: bold; |
||
/* |
/* no changes */ |
||
flex: |
flex: none; |
||
} |
} |
||
| Line 52: | Line 52: | ||
/* only grow, minimum 2rem */ |
/* only grow, minimum 2rem */ |
||
flex: 1 0 2rem; |
flex: 1 0 2rem; |
||
} |
|||
h2::before, |
|||
h3::before { |
|||
justify-self: start; |
|||
} |
|||
h2::after, |
|||
h3::after { |
|||
justify-self: end; |
|||
} |
} |
||
Revision as of 21:40, December 9, 2024
/* hide the edit section button */
h2 .mw-editsection,
h3 .mw-editsection {
display: none;
}
/* flex container to allow for the lines on each side */
h2, h3 {
display: flex;
flex-wrap: nowrap;
justify-items: center;
align-items: center;
gap: var(--space-md);
}
h2 .mw-headline,
h3 .mw-headline {
/* typography for header */
text-align: center;
font-weight: bold;
/* no changes */
flex: none;
}
/* solid line around h2 */
h2::before,
h2::after {
content: '';
border-top: 1px solid var(--color-base--emphasized);
}
/* dashed line around h3 */
h3::before,
h3::after {
content: '';
border-top: 1px dashed var(--color-base--emphasized);
}
h2 .mw-headline {
font-size: var(--font-size-xxx-large);
}
h3 .mw-headline {
font-size: var(--font-size-x-large);
}
/* lines around h2, h3 */
h2::before,
h2::after,
h3::before,
h3::after {
/* only grow, minimum 2rem */
flex: 1 0 2rem;
}
h2::before,
h3::before {
justify-self: start;
}
h2::after,
h3::after {
justify-self: end;
}