Add search functionality

This commit is contained in:
ChaoticByte 2024-08-28 19:49:23 +02:00
parent 149841bdd1
commit 85470a277e
No known key found for this signature in database
8 changed files with 138 additions and 24 deletions

View file

@ -17,11 +17,16 @@
</div>
</div>
{{- else -}}
<div class="toc">
<div class="home-main">
<input type="text" id="search-box" placeholder="search">
<div id="search-results" class="hidden"></div>
<div class="toc" id="toc">
{{- range .TOC -}}
<div><a href="{{ . }}">{{ . }}</a></div>
{{- end -}}
</div>
</div>
<script src="/static/search.js"></script>
{{- end}}
</body>
</html>