huge upgrade to theme and pagefind search bar.

This commit is contained in:
2026-04-17 13:28:48 -06:00
parent a6a38f7ea7
commit 235d40da0b
442 changed files with 18933 additions and 2893 deletions

View File

@@ -0,0 +1,17 @@
[
{{- $pages := where .Site.Pages "Kind" "in" (slice "page" "section") -}}
{{- $pages = where $pages "Params.bookSearchExclude" "!=" true -}}
{{/* Remove until we know why it does not work, see https://github.com/alex-shpak/hugo-book/issues/528 */}}
{{/*- $pages = where $pages "Content" "not in" (slice nil "") -*/}}
{{- $pages = where $pages "Content" "!=" "" -}}
{{ range $index, $page := $pages }}
{{ if gt $index 0}},{{end}} {
"id": {{ $index }},
"href": "{{ $page.RelPermalink }}",
"title": {{ (partial "docs/title" $page) | jsonify }},
"section": {{ (partial "docs/title" $page.Parent) | default $.Site.Title | jsonify }},
"content": {{ $page.Plain | jsonify }}
}
{{- end -}}
]