huge upgrade to theme and pagefind search bar.
This commit is contained in:
10
themes/hugo-book.backup/layouts/_partials/docs/search.html
Normal file
10
themes/hugo-book.backup/layouts/_partials/docs/search.html
Normal file
@@ -0,0 +1,10 @@
|
||||
{{ if default true .Site.Params.BookSearch }}
|
||||
<link href="/pagefind/pagefind-ui.css" rel="stylesheet">
|
||||
<script src="/pagefind/pagefind-ui.js"></script>
|
||||
<div id="search"></div>
|
||||
<script>
|
||||
window.addEventListener('DOMContentLoaded', (event) => {
|
||||
new PagefindUI({ element: "#search", showSubResults: true });
|
||||
});
|
||||
</script>
|
||||
{{ end }}
|
||||
Reference in New Issue
Block a user