mirror of
https://github.com/searxng/searxng.git
synced 2025-08-02 10:02:20 +02:00
[enh] change categories_as_tabs from a list to a dict
The tab icon names are currently hard coded in the templates. This commit lets us introduce an icon property in the future, e.g: categories_as_tabs: general: icon: search-outline
This commit is contained in:
parent
b38036d519
commit
a4c2cfb837
7 changed files with 40 additions and 38 deletions
|
@ -439,7 +439,7 @@ def render(template_name, override_theme=None, **kwargs):
|
|||
kwargs['query_in_title'] = request.preferences.get_value('query_in_title')
|
||||
kwargs['safesearch'] = str(request.preferences.get_value('safesearch'))
|
||||
kwargs['theme'] = get_current_theme_name(override=override_theme)
|
||||
kwargs['categories_as_tabs'] = settings['categories_as_tabs']
|
||||
kwargs['categories_as_tabs'] = list(settings['categories_as_tabs'].keys())
|
||||
kwargs['categories'] = _get_enable_categories(categories.keys())
|
||||
kwargs['OTHER_CATEGORY'] = OTHER_CATEGORY
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue