Merge pull request #19581 from ksuderman/anvil-theme

Support setting masthead height in a theme
This commit is contained in:
Dannon
2025-05-15 14:41:56 -04:00
committed by GitHub
4 changed files with 27 additions and 5 deletions
+6 -5
View File
@@ -178,9 +178,9 @@ onMounted(() => {
padding: 0;
margin-bottom: 0;
background: var(--masthead-color);
height: $masthead-height;
height: var(--masthead-height);
&:deep(.navbar-nav) {
height: $masthead-height;
height: var(--masthead-height);
& > li {
// This allows the background color to fill the full height of the
// masthead, while still keeping the contents centered (using flex)
@@ -226,12 +226,13 @@ onMounted(() => {
}
.navbar-brand {
cursor: pointer;
line-height: $masthead-height;
line-height: var(--masthead-height);
img {
filter: $text-shadow;
display: inline;
border: none;
height: 2rem;
height: var(--masthead-logo-height);
padding: inherit;
}
}
.navbar-text {
@@ -239,7 +240,7 @@ onMounted(() => {
font-weight: bold;
font-family: Verdana, sans-serif;
font-size: 1rem;
line-height: $masthead-height;
line-height: var(--masthead-height);
color: var(--masthead-text-color);
}
}
@@ -82,6 +82,9 @@ html,
--font-size-large: 1rem;
// masthead specific
--masthead-height: #{$masthead-height};
--masthead-logo-height: calc(var(--masthead-height) * 0.6);
--masthead-color: #{$masthead-color};
--masthead-text-color: #{$masthead-text-color};
--masthead-text-hover: #{$masthead-text-hover};
+1
View File
@@ -114,6 +114,7 @@ $body-bg: $white;
// Masthead
$masthead-height: 2.5rem;
$masthead-logo-height: $masthead-height * 0.6;
// Side panels
$panel-bg-color: $brand-light;
@@ -74,3 +74,20 @@ smoky:
active: "#FF206E"
logo:
img: "/static/favicon.svg"
anvil:
masthead:
color: "#012840"
height: "3rem"
text:
color: "#f6f7f4"
hover: "#e0dd10"
active: "#ffff"
link:
color: transparent
hover: transparent
active: "#00090e"
logo:
height: "1.8rem"
img: "/static/images/galaxy_project_logo_white_square.png"
img-secondary: "/static/images/anvilwhite.png"