mirror of
https://gitea.invidious.io/iv-org/invidious-copy-2022-03-16.git
synced 2024-08-15 00:53:18 +00:00
Fix the search box
Fix #277 : autoselect search field Fix #1107: no spell checking/auto-correct on search field
This commit is contained in:
parent
4f219362fe
commit
68cbc11810
4 changed files with 25 additions and 30 deletions
9
src/invidious/views/components/search_box.ecr
Normal file
9
src/invidious/views/components/search_box.ecr
Normal file
|
@ -0,0 +1,9 @@
|
|||
<form class="pure-form" action="/search" method="get">
|
||||
<fieldset>
|
||||
<input type="search" id="searchbox" autocomplete="off" autocorrect="off"
|
||||
autocapitalize="none" spellcheck="false" autofocus name="q"
|
||||
placeholder="<%= translate(locale, "search") %>"
|
||||
title="<%= translate(locale, "search") %>"
|
||||
value="<%= env.get?("search").try {|x| HTML.escape(x.as(String)) } %>">
|
||||
</fieldset>
|
||||
</form>
|
|
@ -14,11 +14,7 @@
|
|||
</div>
|
||||
<div class="pure-u-1-4"></div>
|
||||
<div class="pure-u-1 pure-u-md-12-24 searchbar">
|
||||
<form class="pure-form" action="/search" method="get">
|
||||
<fieldset>
|
||||
<input autofocus type="search" style="width:100%" name="q" placeholder="<%= translate(locale, "search") %>" value="<%= env.get?("search").try {|x| HTML.escape(x.as(String)) } %>">
|
||||
</fieldset>
|
||||
</form>
|
||||
<%= rendered "components/search_box" %>
|
||||
</div>
|
||||
<div class="pure-u-1-4"></div>
|
||||
</div>
|
||||
|
|
|
@ -35,11 +35,7 @@
|
|||
<a href="/" class="index-link pure-menu-heading">Invidious</a>
|
||||
</div>
|
||||
<div class="pure-u-1 pure-u-md-12-24 searchbar">
|
||||
<form class="pure-form" action="/search" method="get">
|
||||
<fieldset>
|
||||
<input type="search" style="width:100%" name="q" placeholder="<%= translate(locale, "search") %>" value="<%= env.get?("search").try {|x| HTML.escape(x.as(String)) } %>">
|
||||
</fieldset>
|
||||
</form>
|
||||
<%= rendered "components/search_box" %>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue