Merge pull request #4377 from timhoffm/searchbar-style

Improved sidebar search field style
This commit is contained in:
Takeshi KOMIYA 2018-01-05 14:12:07 +09:00 committed by GitHub
commit ff61fb80c5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 21 additions and 13 deletions

View File

@ -10,12 +10,14 @@
{%- if pagename != "search" and builder != "singlehtml" %}
<div id="searchbox" style="display: none" role="search">
<h3>{{ _('Quick search') }}</h3>
<div class="searchformwrapper">
<form class="search" action="{{ pathto('search') }}" method="get">
<div><input type="text" name="q" /></div>
<div><input type="submit" value="{{ _('Go') }}" /></div>
<input type="text" name="q" />
<input type="submit" value="{{ _('Go') }}" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
{%- endif %}

View File

@ -82,9 +82,21 @@ div.sphinxsidebar input {
}
div.sphinxsidebar #searchbox input[type="text"] {
width: 170px;
float: left;
width: 80%;
padding: 0.25em;
box-sizing: border-box;
}
div.sphinxsidebar #searchbox input[type="submit"] {
float: left;
width: 20%;
border-left: none;
padding: 0.25em;
box-sizing: border-box;
}
img {
border: 0;
max-width: 100%;

View File

@ -125,12 +125,9 @@ div.sphinxsidebar input {
font-size: 1em;
}
div.sphinxsidebar input[type=text]{
margin-left: 20px;
}
div.sphinxsidebar input[type=submit]{
div.sphinxsidebar .searchformwrapper {
margin-left: 20px;
margin-right: 20px;
}
/* -- body styles ----------------------------------------------------------- */

View File

@ -148,12 +148,9 @@ div.sphinxsidebar input {
font-size: 1em;
}
div.sphinxsidebar input[type=text]{
margin-left: 20px;
}
div.sphinxsidebar input[type=submit]{
div.sphinxsidebar .searchformwrapper {
margin-left: 20px;
margin-right: 20px;
}
/* -- sidebars -------------------------------------------------------------- */