mirror of
https://github.com/searxng/searxng.git
synced 2024-12-11 20:06:28 +00: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.
13 lines
799 B
HTML
13 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>
|