2021-08-27 21:08:11 +03:00
|
|
|
<div id="search-container">
|
2022-07-31 20:54:23 +03:00
|
|
|
<div id="search-space">
|
2022-08-24 06:32:40 +03:00
|
|
|
<input autocomplete="off" id="search-bar" name="search" type="text" aria-label="{{ i18n "search" }}"
|
|
|
|
placeholder="{{ i18n "search_for_something" }}" dir="{{ $.Site.Language.LanguageDirection }}">
|
2022-07-31 20:54:23 +03:00
|
|
|
<div id="results-container">
|
2021-08-27 21:08:11 +03:00
|
|
|
</div>
|
2022-07-31 20:54:23 +03:00
|
|
|
</div>
|
2021-08-27 21:08:11 +03:00
|
|
|
</div>
|
2022-07-31 22:16:36 +03:00
|
|
|
{{if $.Site.Data.config.enableSemanticSearch}}
|
|
|
|
{{ $js := resources.Get "js/semantic-search.js" | resources.ExecuteAsTemplate "js/semantic-search.js" . | resources.Fingerprint "md5" | resources.Minify }}
|
|
|
|
<script defer src="{{ $js.Permalink }}"></script>
|
|
|
|
{{else}}
|
2022-07-31 20:54:23 +03:00
|
|
|
<script src="https://cdn.jsdelivr.net/npm/flexsearch@0.7.21/dist/flexsearch.bundle.js"
|
|
|
|
integrity="sha256-i3A0NZGkhsKjVMzFxv3ksk0DZh3aXqu0l49Bbh0MdjE=" crossorigin="anonymous" defer></script>
|
2022-07-31 22:16:36 +03:00
|
|
|
{{ $js := resources.Get "js/full-text-search.js" | resources.Fingerprint "md5" | resources.Minify }}
|
2022-03-04 05:07:51 +03:00
|
|
|
<script defer src="{{ $js.Permalink }}"></script>
|
2022-07-31 22:16:36 +03:00
|
|
|
{{end}}
|
|
|
|
|