From 189dd0155df60c98b5d7de73b873c8ad444ff931 Mon Sep 17 00:00:00 2001 From: Markus Heiser Date: Tue, 4 Feb 2025 15:59:02 +0100 Subject: [web-client] simple theme: refactor jinja_svg_catalog and cleanup icon names This patch implements the template generation of the template: searx/templates/simple/icons.html by the way the icon set (the icon names) has been normalized: film-outline --> film magnet-outline --> magnet .. warning --> alert Some missing (categorie) icons had been added. Some of the ionicons are not suitable for a dark theme, we fixed the svg manually in src/svg/ionicons: - https://github.com/searxng/searxng/pull/4284#issuecomment-2680550342 Signed-off-by: Markus Heiser --- searx/templates/simple/result_templates/files.html | 4 ++-- .../templates/simple/result_templates/images.html | 4 ++-- searx/templates/simple/result_templates/map.html | 2 +- .../templates/simple/result_templates/torrent.html | 26 +++++++++++++--------- .../templates/simple/result_templates/videos.html | 2 +- 5 files changed, 22 insertions(+), 16 deletions(-) (limited to 'searx/templates/simple/result_templates') diff --git a/searx/templates/simple/result_templates/files.html b/searx/templates/simple/result_templates/files.html index 01dfc3535..13a425f31 100644 --- a/searx/templates/simple/result_templates/files.html +++ b/searx/templates/simple/result_templates/files.html @@ -6,8 +6,8 @@ {%- if result.embedded -%} {%- endif -%} diff --git a/searx/templates/simple/result_templates/images.html b/searx/templates/simple/result_templates/images.html index 617834705..12c2e8194 100644 --- a/searx/templates/simple/result_templates/images.html +++ b/searx/templates/simple/result_templates/images.html @@ -7,8 +7,8 @@ {{- "" -}}
{{- "" -}} {{ icon('close') }}{{- "" -}} - {{ icon('chevron-left') }}{{- "" -}} - {{ icon('chevron-right') }}{{- "" -}} + {{ icon('navigate-left') }}{{- "" -}} + {{ icon('navigate-right') }}{{- "" -}} {{ result.title|striptags }}{{- "" -}} {{- "" -}} diff --git a/searx/templates/simple/result_templates/map.html b/searx/templates/simple/result_templates/map.html index d123137cb..dc1f06dce 100644 --- a/searx/templates/simple/result_templates/map.html +++ b/searx/templates/simple/result_templates/map.html @@ -40,7 +40,7 @@ {%- if (result.latitude and result.longitude) or result.boundingbox -%} - + {%- endif -%} {{- result_sub_footer(result, proxify) -}} diff --git a/searx/templates/simple/result_templates/torrent.html b/searx/templates/simple/result_templates/torrent.html index befad2c89..0c870ae11 100644 --- a/searx/templates/simple/result_templates/torrent.html +++ b/searx/templates/simple/result_templates/torrent.html @@ -3,15 +3,21 @@ {{ result_header(result, favicons, image_proxify) -}} {{- result_sub_header(result) -}} -{% if result.magnetlink %}{% endif %} -{% if result.torrentfile %}{% endif %} + -{% if result.seed is defined %}

• {{ icon_big('arrow-swap') }} {{ _('Seeder') }} {{ result.seed }} • {{ _('Leecher') }} {{ result.leech }}

{% endif %} - -{%- if result.filesize %}

{{ icon_big('floppy-disk') }} {{ _('Filesize') }}{{ result.filesize }}

{%- endif -%} - -{%- if result.files %}

{{ icon_big('file') }} {{ _('Number of Files') }} {{ result.files }}

{% endif -%} - -{%- if result.content %}

{{ result.content|safe }}

{% endif -%} +

+ {%- if result.seed is defined %} + {{ icon_big('seeder') }} {{ result.seed }} {{ _('Seeder') }} + {{ icon_big('leecher') }} {{ result.leech }} {{ _('Leecher') }} + {% endif %} +

+

+ {%- if result.filesize %}{{ icon_big('save') }} {{ result.filesize }} {{ _('Filesize') }}{%- endif -%} + {%- if result.files %}{{ icon_big('file') }} {{ result.files }} {{ _('Number of Files') }}{%- endif -%} +

+{%- if result.content %}

{{ result.content|safe }}

{%- endif -%} {{- result_sub_footer(result, proxify) -}} -{{- result_footer(result) }} +{{- result_footer(result) -}} diff --git a/searx/templates/simple/result_templates/videos.html b/searx/templates/simple/result_templates/videos.html index 969f87a4d..40a05698f 100644 --- a/searx/templates/simple/result_templates/videos.html +++ b/searx/templates/simple/result_templates/videos.html @@ -3,7 +3,7 @@ {{ result_header(result, favicons, image_proxify) }} {{ result_sub_header(result) }} {% if result.iframe_src -%} - + {%- endif %} {%- if result.content %}

-- cgit v1.2.3