mirror of
https://github.com/searxng/searxng.git
synced 2024-11-19 10:50:09 +01:00
8e9ad1ccc2
Previously all categories were displayed as search engine tabs. This commit changes that so that only the categories listed under categories_as_tabs in settings.yml are displayed. This lets us introduce more categories without cluttering up the UI. Categories not displayed as tabs can still be searched with !bangs.
14 lines
799 B
HTML
14 lines
799 B
HTML
<div id="categories">
|
|
{%- if rtl -%}
|
|
{% for category in categories_as_tabs | reverse -%}
|
|
<input class="hidden" type="checkbox" id="checkbox_{{ category|replace(' ', '_') }}" name="category_{{ category }}" {% if category in selected_categories %}checked="checked"{% endif %} />{{- '' -}}
|
|
<label for="checkbox_{{ category|replace(' ', '_') }}">{{ _(category) }}</label>
|
|
{%- endfor %}
|
|
{%- else -%}
|
|
{% for category in categories_as_tabs -%}
|
|
<input class="hidden" type="checkbox" id="checkbox_{{ category|replace(' ', '_') }}" name="category_{{ category }}" {% if category in selected_categories %}checked="checked"{% endif %} />{{- '' -}}
|
|
<label for="checkbox_{{ category|replace(' ', '_') }}">{{ _(category) }}</label>
|
|
{%- endfor %}
|
|
{%- endif -%}
|
|
</div>
|