mirror of
https://github.com/CaiJimmy/hugo-theme-stack.git
synced 2025-03-30 13:15:57 +02:00
feat(widget): add search widget
This commit is contained in:
parent
e5f96c8762
commit
21f461ce78
1 changed files with 10 additions and 0 deletions
10
layouts/partials/widget/search.html
Normal file
10
layouts/partials/widget/search.html
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
<form action="/search" class="search-form widget" {{ with .OutputFormats.Get "json" -}}data-json="{{ .Permalink }}" {{- end }}>
|
||||||
|
<p>
|
||||||
|
<label>Search</label>
|
||||||
|
<input name="keyword" required placeholder="Type something..." />
|
||||||
|
|
||||||
|
<button title="Search">
|
||||||
|
{{ (resources.Get "icons/search.svg").Content | safeHTML }}
|
||||||
|
</button>
|
||||||
|
</p>
|
||||||
|
</form>
|
Loading…
Add table
Reference in a new issue