hugo-theme-fha/layouts/partials/style.html

195 lines
2.9 KiB
HTML
Raw Permalink Normal View History

2024-09-01 14:27:23 +00:00
<style>
body {
min-width: 300px;
min-height: 100%;
display: flex;
flex-direction: column;
}
.custom-navbar,
.custom-footer {
margin-bottom: 1em;
height: 60px;
flex-shrink: 0;
}
.custom-navbar a {
display: inline-block;
padding: 18px 0;
margin-right: 1em;
font-weight: bold;
}
.custom-navbar a:hover,
.custom-navbar a:focus {
text-decoration: none;
}
@media print {
.custom-navbar {
display: none;
}
}
table {width: 80%;}
tr {
padding-left: 5px;
padding-right: 5px;}
tr:nth-child(even){background-color: #f2f2f2;}
th {
padding-top: 12px;
padding-bottom: 12px;
padding-left: 5px;
padding-right: 5px;
text-align: middle;
background-color: #6c757d;
color: white;
}
article {
padding-bottom: 1em;
}
img {
max-width: 100%;
}
{{ with .Site.Params.contentBackgroundColor }}
body {
background-color: {{ . | safeCSS }};
}
{{ else }}
body {
background-color: #fff;
}
{{ end }}
{{ with .Site.Params.contentTextColor }}
body {
color: {{ . | safeCSS }};
}
{{ else }}
body {
color: #212529;
}
{{ end }}
{{ with .Site.Params.contentLinkColor }}
a {
color: {{ . | safeCSS }};
}
{{ else }}
a {
color: #007bff;
}
{{ end }}
{{ with .Site.Params.contentLinkHoverColor }}
a:hover,
a:focus {
color: {{ . | safeCSS }};
}
{{ else }}
a:hover,
a:focus {
color: #0056b3;
}
{{ end }}
{{ with .Site.Params.navbarBackgroundColor }}
.navbar,
.footer {
background-color: {{ . | safeCSS }};
}
{{ else }}
.navbar,
.footer {
background-color: #212529;
}
{{ end }}
{{ with .Site.Params.navbarForegroundColor }}
:root {
--bs-navbar-color: {{ . | safeCSS }};
}
{{ else }}
:root {
--bs-navbar-color: #5e807fff;
}
{{ end }}
{{ with .Site.Params.navbarLinkColor }}
.custom-navbar a {
color: {{ . | safeCSS }};
}
{{ else }}
.custom-navbar a {
color: rgba(255,255,255,.75);
}
{{ end }}
{{ with .Site.Params.navbarLinkHoverColor }}
.custom-navbar a:hover,
.custom-navbar a:focus {
color: {{ . | safeCSS }};
}
{{ else }}
.custom-navbar a:hover,
.custom-navbar a:focus {
color: rgba(255,255,255,1);
}
{{ end }}
{{ with .Site.Params.wrapperMaxWidth }}
.container {
max-width: {{ . | safeCSS }};
}
{{ else }}
.container {
max-width: 800px;
}
{{ end }}
{{ if eq .Site.Params.customCodeStyle true }}
pre {
display: block;
padding: 9.5px;
word-break: break-all;
word-wrap: break-word;
background-color: #f5f5f5;
border: 1px solid #ccc;
border-radius: 4px;
}
pre code {
padding: 0;
font-size: inherit;
color: inherit;
white-space: pre-wrap;
background-color: transparent;
border: none;
border-radius: 0;
}
code {
padding: 2px 4px;
color: inherit;
background-color: #f5f5f5;
border: 1px solid #ccc;
border-radius: 4px;
font-size: .9em;
}
{{ end }}
{{ if eq .Site.Params.customBlockquoteStyle true }}
blockquote,
.blockquote {
padding: 10px 20px;
margin: 0 0 20px;
font-size: 1em;
border-left: 5px solid #6c757d;
}
{{ end }}
</style>