Webpack -> Hugo Pipes

This commit is contained in:
panr
2020-07-16 23:56:01 +02:00
parent 73373847d8
commit 0759309c59
42 changed files with 67 additions and 322 deletions

View File

@ -8,11 +8,15 @@
{{ template "_internal/google_analytics.html" . }}
<!-- Theme CSS -->
<link rel="stylesheet" href="{{ "assets/style.css" | absURL }}">
{{ if (isset .Params "color") }}
<link rel="stylesheet" href="{{ (printf "assets/%s.css" .Params.color) | absURL }}">
{{ else if (ne $.Site.Params.ThemeColor "orange") }}
<link rel="stylesheet" href="{{ (printf "assets/%s.css" $.Site.Params.ThemeColor) | absURL }}">
{{ $css := resources.Get "css/style.css" }}
{{ $opts := dict "inlineImports" true }}
{{ $style := $css | resources.PostCSS $opts | minify }}
<link rel="stylesheet" href="{{ $style.Permalink }}">
{{ if (or (isset .Params "color") (ne $.Site.Params.ThemeColor "orange")) }}
{{ $colorCss := resources.Get (printf "css/color/%s.css" (or .Params.color $.Site.Params.ThemeColor)) }}
{{ $color := $colorCss | resources.PostCSS $opts | minify }}
<link rel="stylesheet" href="{{ $color.Permalink }}">
{{ end }}
<!-- Custom CSS to override theme properties (/static/style.css) -->