Introduce SCSS plugins: dark mode and numbered headings

This commit is contained in:
Alex Shpak
2019-10-08 17:03:40 +02:00
parent 1cd5040d84
commit 007bc10c07
18 changed files with 428 additions and 409 deletions
+3 -5
View File
@@ -3,9 +3,10 @@
{{- template "_internal/opengraph.html" . -}}
<title>{{ partial "docs/title" . }} | {{ .Site.Title -}}</title>
<link rel="icon" href="{{ "favicon.png" | relURL }}" type="image/x-icon">
<!-- Theme stylesheet, you can customize scss by creating `assets/custom.scss` in your website -->
{{- $styles := resources.Get "book.scss" | resources.ToCSS | resources.Minify | resources.Fingerprint }}
{{- $styles := resources.Get "book.scss" | resources.ExecuteAsTemplate "book.scss" . | resources.ToCSS | resources.Minify | resources.Fingerprint }}
<link rel="stylesheet" href="{{ $styles.RelPermalink }}" integrity="{{ $styles.Data.Integrity }}">
{{ if default true .Site.Params.BookSearch }}
@@ -13,8 +14,7 @@
<script defer src="{{ $searchJS.RelPermalink }}" integrity="{{ $searchJS.Data.Integrity }}"></script>
{{ end }}
<!-- Favicon -->
<link rel="icon" href="{{ "favicon.png" | relURL }}" type="image/x-icon">
{{- template "_internal/google_analytics_async.html" . -}}
<!-- RSS -->
{{ with .OutputFormats.Get "rss" -}}
@@ -25,5 +25,3 @@
Made with Book Theme
https://github.com/alex-shpak/hugo-book
{{ "-->" | safeHTML }}
{{ template "_internal/google_analytics_async.html" . }}
+1 -1
View File
@@ -13,7 +13,7 @@
<style>
nav ul a[href{{ $attrEq }}"{{ $attrVal }}"] {
color: {{ default "#004ed0" .Site.Params.BookMenuBundleActiveLinkColor }};
color: {{ default "#004ed0" .Site.Params.BookMenuBundleActiveLinkColor }};
}
</style>
{{ end }}