Add autofocus property to search widget
This commit is contained in:
parent
9bda88edbd
commit
5a62a8afe9
3 changed files with 6 additions and 1 deletions
|
|
@ -16,7 +16,7 @@
|
|||
</svg>
|
||||
</div>
|
||||
|
||||
<input class="search-input" type="text" placeholder="Type here to search…" autocomplete="off">
|
||||
<input class="search-input" type="text" placeholder="Type here to search…" autocomplete="off"{{ if .Autofocus }} autofocus{{ end }}>
|
||||
|
||||
<div class="search-bang"></div>
|
||||
<kbd class="hide-on-mobile" title="Press [S] to focus the search input">S</kbd>
|
||||
|
|
|
|||
|
|
@ -20,6 +20,7 @@ type Search struct {
|
|||
SearchEngine string `yaml:"search-engine"`
|
||||
Bangs []SearchBang `yaml:"bangs"`
|
||||
NewTab bool `yaml:"new-tab"`
|
||||
Autofocus bool `yaml:"autofocus"`
|
||||
}
|
||||
|
||||
func convertSearchUrl(url string) string {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue