2022-11-13 10:55:17 +01:00
|
|
|
{{- $page := .page }}
|
|
|
|
{{- $outputFormat := .outputFormat }}
|
|
|
|
{{- if not $page }}
|
|
|
|
{{- $page = . }}
|
|
|
|
{{- $outputFormat = partial "output-format.hugo" $page }}
|
|
|
|
{{- end }}
|
|
|
|
{{- with $page }}
|
2022-02-06 13:51:54 +01:00
|
|
|
{{- $assetBusting := not .Site.Params.disableAssetsBusting }}
|
2024-04-24 23:05:13 +02:00
|
|
|
{{- /* https://github.com/filamentgroup/loadCSS/blob/master/README.md#how-to-use */}}
|
2022-07-18 01:17:25 +02:00
|
|
|
<link href="{{"css/fontawesome-all.min.css" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}" rel="stylesheet" media="print" onload="this.media='all';this.onload=null;"><noscript><link href="{{"css/fontawesome-all.min.css" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}" rel="stylesheet"></noscript>
|
2023-02-10 00:34:47 +01:00
|
|
|
<link href="{{"css/nucleus.css" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}" rel="stylesheet">
|
2022-07-18 01:17:25 +02:00
|
|
|
<link href="{{"css/auto-complete.css" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}" rel="stylesheet" media="print" onload="this.media='all';this.onload=null;"><noscript><link href="{{"css/auto-complete.css" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}" rel="stylesheet"></noscript>
|
2022-02-06 13:51:54 +01:00
|
|
|
<link href="{{"css/perfect-scrollbar.min.css" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}" rel="stylesheet">
|
2022-07-18 01:17:25 +02:00
|
|
|
<link href="{{"css/fonts.css" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}" rel="stylesheet" media="print" onload="this.media='all';this.onload=null;"><noscript><link href="{{"css/fonts.css" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}" rel="stylesheet"></noscript>
|
2022-02-06 13:51:54 +01:00
|
|
|
<link href="{{"css/theme.css" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}" rel="stylesheet">
|
2023-11-26 18:11:56 +01:00
|
|
|
{{- $themevariants := partialCached "get-theme-variants.hugo" . }}
|
2022-02-13 01:53:23 +01:00
|
|
|
{{- with index $themevariants 0 }}
|
2024-04-19 00:03:45 +02:00
|
|
|
<link href="{{(printf "css/theme-%s.css" .identifier) | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}" rel="stylesheet" id="R-variant-style">
|
2023-11-26 20:34:08 +01:00
|
|
|
<link href="{{(printf "css/chroma-%s.css" .chroma) | safeHTML | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}" rel="stylesheet" id="R-variant-chroma-style">
|
2022-02-06 13:51:54 +01:00
|
|
|
{{- end }}
|
2022-02-21 00:35:50 +01:00
|
|
|
<link href="{{"css/variant.css" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}" rel="stylesheet">
|
2022-07-09 18:42:20 +02:00
|
|
|
<link href="{{"css/print.css" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}" rel="stylesheet" media="print">
|
2022-11-12 23:21:21 +01:00
|
|
|
{{- $f := printf "/static/css/format-%s.css" $outputFormat }}
|
2023-11-25 14:23:58 +01:00
|
|
|
{{- if or (partialCached "fileExists.hugo" $f $f) (resources.Get (printf "/css/format-%s.css" $outputFormat)) }}
|
2022-11-12 23:21:21 +01:00
|
|
|
<link href="{{(printf "css/format-%s.css" $outputFormat) | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}" rel="stylesheet">
|
2022-07-09 18:42:20 +02:00
|
|
|
{{- end }}
|
2022-02-20 23:58:16 +01:00
|
|
|
<script src="{{"js/variant.js" | relURL}}{{ if not .Site.Params.disableAssetsBusting }}?{{ now.Unix }}{{ end }}"></script>
|
2024-03-16 14:43:57 +01:00
|
|
|
<script>
|
2024-03-16 13:39:30 +01:00
|
|
|
window.relearn = window.relearn || {};
|
2024-03-18 21:56:21 +01:00
|
|
|
window.relearn.relBasePath='{{ partial "relBasePath.hugo" $page | safeJS }}';
|
2024-03-18 21:58:53 +01:00
|
|
|
window.relearn.relBaseUri='{{ partial "relBaseUri.hugo" $page | safeJS }}';
|
2024-03-18 21:58:26 +01:00
|
|
|
window.relearn.absBaseUri='{{ replaceRE "/*$" "" .Site.BaseURL | safeJS }}';
|
2024-02-10 23:22:35 +01:00
|
|
|
{{- with .Site.Home.OutputFormats.Get "search" }}
|
2022-11-02 00:14:19 +01:00
|
|
|
window.index_js_url={{ "index.search.js" | relLangURL }};
|
|
|
|
{{- end }}
|
2023-11-16 23:53:06 +01:00
|
|
|
{{ "// variant stuff" | safeJS }}
|
2022-02-20 23:58:16 +01:00
|
|
|
{{- $quotedthemevariants := slice }}
|
|
|
|
{{- range $themevariants }}
|
2023-11-20 09:39:40 +01:00
|
|
|
{{- $quotedthemevariants = $quotedthemevariants | append (printf "'%s'" .identifier) }}
|
2022-02-20 23:58:16 +01:00
|
|
|
{{- end }}
|
2022-07-09 19:46:39 +02:00
|
|
|
window.variants && variants.init( [ {{ delimit $quotedthemevariants ", " | safeJS }} ] );
|
2023-11-16 23:53:06 +01:00
|
|
|
{{ "// translations" | safeJS }}
|
|
|
|
{{ printf "window.T_Copy_to_clipboard = `%s`;" (T `Copy-to-clipboard`) | safeJS }}
|
|
|
|
{{ printf "window.T_Copied_to_clipboard = `%s`;" (T `Copied-to-clipboard`) | safeJS }}
|
|
|
|
{{ printf "window.T_Copy_link_to_clipboard = `%s`;" (T `Copy-link-to-clipboard`) | safeJS }}
|
|
|
|
{{ printf "window.T_Link_copied_to_clipboard = `%s`;" (T `Link-copied-to-clipboard`) | safeJS }}
|
|
|
|
{{ printf "window.T_Reset_view = `%s`;" (T `Reset-view`) | safeJS }}
|
|
|
|
{{ printf "window.T_View_reset = `%s`;" (T `View-reset`) | safeJS }}
|
|
|
|
{{ printf "window.T_No_results_found = `%s`;" (T "No-results-found") | safeJS }}
|
|
|
|
{{ printf "window.T_N_results_found = `%s`;" (T "N-results-found") | safeJS }}
|
2022-02-13 02:11:27 +01:00
|
|
|
</script>
|
2022-11-13 10:55:17 +01:00
|
|
|
{{- end }}
|