2025-05-23 00:57:12 +01:00
|
|
|
/* Hugo template to derive CSS variables from site and page parameters */
|
|
|
|
|
|
|
|
/* Do not remove the following comment. It is used by Hugo to render CSS variables.
|
2025-08-14 23:12:23 +08:00
|
|
|
{{- $pageWidth := site.Params.page.width -}}
|
2025-05-23 00:57:12 +01:00
|
|
|
{{- $maxPageWidth := cond (eq $pageWidth "wide") "90rem" (cond (eq $pageWidth "full") "100%" "80rem") -}}
|
|
|
|
|
2025-08-14 23:12:23 +08:00
|
|
|
{{- $navbarWidth := site.Params.navbar.width -}}
|
2025-05-23 00:57:12 +01:00
|
|
|
{{- $maxNavbarWidth := cond (eq $navbarWidth "wide") "90rem" (cond (eq $navbarWidth "full") "100%" "80rem") -}}
|
|
|
|
|
2025-08-14 23:12:23 +08:00
|
|
|
{{- $footerWidth := site.Params.footer.width -}}
|
2025-05-23 00:57:12 +01:00
|
|
|
{{- $maxFooterWidth := cond (eq $footerWidth "wide") "90rem" (cond (eq $footerWidth "full") "100%" "80rem") -}}
|
|
|
|
*/
|
|
|
|
|
|
|
|
:root {
|
|
|
|
--hextra-max-page-width: {{ $maxPageWidth }};
|
|
|
|
--hextra-max-navbar-width: {{ $maxNavbarWidth }};
|
|
|
|
--hextra-max-footer-width: {{ $maxFooterWidth }};
|
|
|
|
}
|
|
|
|
|
|
|
|
.hextra-max-page-width {
|
|
|
|
max-width: var(--hextra-max-page-width);
|
|
|
|
}
|
|
|
|
|
|
|
|
.hextra-max-navbar-width {
|
|
|
|
max-width: var(--hextra-max-navbar-width);
|
|
|
|
}
|
|
|
|
|
|
|
|
.hextra-max-footer-width {
|
|
|
|
max-width: var(--hextra-max-footer-width);
|
|
|
|
}
|