diff options
author | Thomas Pointhuber <thomas.pointhuber@gmx.at> | 2014-09-26 21:43:12 +0200 |
---|---|---|
committer | Thomas Pointhuber <thomas.pointhuber@gmx.at> | 2014-10-05 14:40:46 +0200 |
commit | 5568fbd89d9c0f8c7f6530c6f0826a35d01c83a8 (patch) | |
tree | 97295e596da374be1b2d12eed1a67e058bdb51f6 | |
parent | afcfa04e30af048c63d12bdbe3e281582a917b91 (diff) | |
download | searxng-5568fbd89d9c0f8c7f6530c6f0826a35d01c83a8.tar.gz searxng-5568fbd89d9c0f8c7f6530c6f0826a35d01c83a8.zip |
oscar template: using tab to seperate engines in preferences
-rw-r--r-- | searx/templates/oscar/preferences.html | 49 |
1 files changed, 31 insertions, 18 deletions
diff --git a/searx/templates/oscar/preferences.html b/searx/templates/oscar/preferences.html index 38f874e51..6803a02e5 100644 --- a/searx/templates/oscar/preferences.html +++ b/searx/templates/oscar/preferences.html @@ -87,27 +87,40 @@ </fieldset> </div> <div class="tab-pane" id="tab_engine"> - <fieldset> - {% for (categ,search_engines) in categs %} - <legend>{{ _(categ) }}</legend> - <div class="container-fluid"> - {% for search_engine in search_engines %} - {% if not search_engine.private %} - <div class="row"> - <div class="col-sm-4 col-md-4">{{ search_engine.name }} ({{ shortcuts[search_engine.name] }})</div> - <div class="col-sm-4 col-md-4"> - <div class="checkbox"> - <input class="hidden" type="checkbox" id="engine_{{ categ }}_{{ search_engine.name|replace(' ', '_') }}" name="engine_{{ search_engine.name }}"{% if search_engine.name in blocked_engines %} checked="checked"{% endif %} /> - <label class="btn btn-success label_hide_if_checked" for="engine_{{ categ }}_{{ search_engine.name|replace(' ', '_') }}">{{ _('Block') }}</label> - <label class="btn btn-danger label_hide_if_not_checked" for="engine_{{ categ }}_{{ search_engine.name|replace(' ', '_') }}">{{ _('Allow') }}</label> + + <!-- Nav tabs --> + <ul class="nav nav-tabs" role="tablist" style="margin-bottom:20px;"> + {% for (categ,search_engines) in categs %} + <li{% if loop.first %} class="active"{% endif %}><a href="#tab_engine_{{ categ|replace(' ', '') }}" role="tab" data-toggle="tab">{{ _(categ) }}</a></li> + {% endfor %} + </ul> + + + <!-- Tab panes --> + <div class="tab-content"> + {% for (categ,search_engines) in categs %} + <div class="tab-pane{% if loop.first %} active{% endif %}" id="tab_engine_{{ categ|replace(' ', '') }}"> + <div class="container-fluid"> + <fieldset> + {% for search_engine in search_engines %} + {% if not search_engine.private %} + <div class="row"> + <div class="col-xs-6 col-sm-4 col-md-4">{{ search_engine.name }} ({{ shortcuts[search_engine.name] }})</div> + <div class="col-xs-6 col-sm-4 col-md-4"> + <div class="checkbox"> + <input class="hidden" type="checkbox" id="engine_{{ categ }}_{{ search_engine.name|replace(' ', '_') }}" name="engine_{{ search_engine.name }}"{% if search_engine.name in blocked_engines %} checked="checked"{% endif %} /> + <label class="btn btn-success label_hide_if_checked" for="engine_{{ categ }}_{{ search_engine.name|replace(' ', '_') }}">{{ _('Block') }}</label> + <label class="btn btn-danger label_hide_if_not_checked" for="engine_{{ categ }}_{{ search_engine.name|replace(' ', '_') }}">{{ _('Allow') }}</label> + </div> </div> </div> - </div> - {% endif %} - {% endfor %} + {% endif %} + {% endfor %} + </fieldset> + </div> </div> - {% endfor %} - </fieldset> + {% endfor %} + </div> </div> </div> |