summaryrefslogtreecommitdiff
path: root/searx/templates/courgette/result_templates
diff options
context:
space:
mode:
Diffstat (limited to 'searx/templates/courgette/result_templates')
-rw-r--r--searx/templates/courgette/result_templates/code.html11
-rw-r--r--searx/templates/courgette/result_templates/default.html13
-rw-r--r--searx/templates/courgette/result_templates/images.html6
-rw-r--r--searx/templates/courgette/result_templates/key-value.html13
-rw-r--r--searx/templates/courgette/result_templates/map.html13
-rw-r--r--searx/templates/courgette/result_templates/torrent.html13
-rw-r--r--searx/templates/courgette/result_templates/videos.html10
7 files changed, 79 insertions, 0 deletions
diff --git a/searx/templates/courgette/result_templates/code.html b/searx/templates/courgette/result_templates/code.html
new file mode 100644
index 000000000..d6dbd5ed7
--- /dev/null
+++ b/searx/templates/courgette/result_templates/code.html
@@ -0,0 +1,11 @@
+<div class="result {{ result.class }}">
+ <h3 class="result_title"><a href="{{ result.url }}" {% if results_on_new_tab %}target="_blank" rel="noopener noreferrer"{% else %}rel="noreferrer"{% endif %}>{{ result.title|safe }}</a></h3>
+ {% if result.publishedDate %}<span class="published_date">{{ result.publishedDate }}</span>{% endif %}
+ <p class="content">{% if result.img_src %}<img src="{{ image_proxify(result.img_src) }}" class="image" />{% endif %}{% if result.content %}{{ result.content|safe }}<br class="last"/>{% endif %}</p>
+ {% if result.repository %}<p class="content"><a href="{{ result.repository|safe }}" {% if results_on_new_tab %}target="_blank" rel="noopener noreferrer"{% else %}rel="noreferrer"{% endif %}>{{ result.repository }}</a></p>{% endif %}
+ <div dir="ltr">
+ {{ result.codelines|code_highlighter(result.code_language)|safe }}
+ </div>
+
+ <p class="url">{{ result.pretty_url }}&lrm;</p>
+</div>
diff --git a/searx/templates/courgette/result_templates/default.html b/searx/templates/courgette/result_templates/default.html
new file mode 100644
index 000000000..5f2ead63f
--- /dev/null
+++ b/searx/templates/courgette/result_templates/default.html
@@ -0,0 +1,13 @@
+<div class="result {{ result.class }}">
+
+ {% if "icon_"~result.engine~".ico" in favicons %}
+ <img width="14" height="14" class="favicon" src="{{ url_for('static', filename='img/icons/icon_'+result.engine+'.ico') }}" alt="{{result.engine}}" />
+ {% endif %}
+
+ <div>
+ <h3 class="result_title"><a href="{{ result.url }}" {% if results_on_new_tab %}target="_blank" rel="noopener noreferrer"{% else %}rel="noreferrer"{% endif %}>{{ result.title|safe }}</a></h3>
+ {% if result.publishedDate %}<span class="published_date">{{ result.publishedDate }}</span>{% endif %}
+ <p class="content">{% if result.content %}{{ result.content|safe }}<br />{% endif %}</p>
+ <p class="url">{{ result.pretty_url }}&lrm;</p>
+ </div>
+</div>
diff --git a/searx/templates/courgette/result_templates/images.html b/searx/templates/courgette/result_templates/images.html
new file mode 100644
index 000000000..49acb3b61
--- /dev/null
+++ b/searx/templates/courgette/result_templates/images.html
@@ -0,0 +1,6 @@
+<div class="image_result">
+ <p>
+ <a href="{{ result.img_src }}" {% if results_on_new_tab %}target="_blank" rel="noopener noreferrer"{% else %}rel="noreferrer"{% endif %}><img src="{% if result.thumbnail_src %}{{ image_proxify(result.thumbnail_src) }}{% else %}{{ image_proxify(result.img_src) }}{% endif %}" title="{{ result.title|striptags }}" alt="{{ result.title|striptags }}"/></a>
+ <span class="url"><a href="{{ result.url }}" {% if results_on_new_tab %}target="_blank" rel="noopener noreferrer"{% else %}rel="noreferrer"{% endif %} class="small_font">{{ _('original context') }}</a></span>
+ </p>
+</div>
diff --git a/searx/templates/courgette/result_templates/key-value.html b/searx/templates/courgette/result_templates/key-value.html
new file mode 100644
index 000000000..789e8de92
--- /dev/null
+++ b/searx/templates/courgette/result_templates/key-value.html
@@ -0,0 +1,13 @@
+<div class="result">
+<table>
+ {% for key, value in result.items() %}
+ {% if key in ['engine', 'engines', 'template', 'score', 'category', 'positions'] %}
+ {% continue %}
+ {% endif %}
+ <tr>
+ <td><b>{{ key|upper }}</b>: {{ value|safe }}</td>
+ </tr>
+ {% endfor %}
+</table>
+<p class="engines">{{ result.engines|join(', ') }}</p>
+</div>
diff --git a/searx/templates/courgette/result_templates/map.html b/searx/templates/courgette/result_templates/map.html
new file mode 100644
index 000000000..5f2ead63f
--- /dev/null
+++ b/searx/templates/courgette/result_templates/map.html
@@ -0,0 +1,13 @@
+<div class="result {{ result.class }}">
+
+ {% if "icon_"~result.engine~".ico" in favicons %}
+ <img width="14" height="14" class="favicon" src="{{ url_for('static', filename='img/icons/icon_'+result.engine+'.ico') }}" alt="{{result.engine}}" />
+ {% endif %}
+
+ <div>
+ <h3 class="result_title"><a href="{{ result.url }}" {% if results_on_new_tab %}target="_blank" rel="noopener noreferrer"{% else %}rel="noreferrer"{% endif %}>{{ result.title|safe }}</a></h3>
+ {% if result.publishedDate %}<span class="published_date">{{ result.publishedDate }}</span>{% endif %}
+ <p class="content">{% if result.content %}{{ result.content|safe }}<br />{% endif %}</p>
+ <p class="url">{{ result.pretty_url }}&lrm;</p>
+ </div>
+</div>
diff --git a/searx/templates/courgette/result_templates/torrent.html b/searx/templates/courgette/result_templates/torrent.html
new file mode 100644
index 000000000..7f94a221e
--- /dev/null
+++ b/searx/templates/courgette/result_templates/torrent.html
@@ -0,0 +1,13 @@
+<div class="result torrent_result">
+ {% if "icon_"~result.engine~".ico" in favicons %}
+ <img width="14" height="14" class="favicon" src="{{ url_for('static', filename='img/icons/icon_'+result.engine+'.ico') }}" alt="{{result.engine}}" />
+ {% endif %}
+ <h3 class="result_title"><a href="{{ result.url }}" {% if results_on_new_tab %}target="_blank" rel="noopener noreferrer"{% else %}rel="noreferrer"{% endif %}>{{ result.title|safe }}</a></h3>
+ {% if result.content %}<span class="content">{{ result.content|safe }}</span><br />{% endif %}
+ {% if result.seed is defined %}<span class="stats">{{ _('Seeder') }} : {{ result.seed }}, {{ _('Leecher') }} : {{ result.leech }}</span><br />{% endif %}
+ <span>
+ {% if result.magnetlink %}<a href="{{ result.magnetlink }}" class="magnetlink">{{ _('magnet link') }}</a>{% endif %}
+ {% if result.torrentfile %}<a href="{{ result.torrentfile }}" class="torrentfile" {% if results_on_new_tab %}target="_blank" rel="noopener noreferrer"{% else %}rel="noreferrer"{% endif %}>{{ _('torrent file') }}</a>{% endif %}
+ </span>
+ <p class="url">{{ result.pretty_url }}&lrm;</p>
+</div>
diff --git a/searx/templates/courgette/result_templates/videos.html b/searx/templates/courgette/result_templates/videos.html
new file mode 100644
index 000000000..b3e19e024
--- /dev/null
+++ b/searx/templates/courgette/result_templates/videos.html
@@ -0,0 +1,10 @@
+<div class="result">
+ {% if "icon_"~result.engine~".ico" in favicons %}
+ <img width="14" height="14" class="favicon" src="{{ url_for('static', filename='img/icons/icon_'+result.engine+'.ico') }}" alt="{{result.engine}}" />
+ {% endif %}
+
+ <h3 class="result_title"><a href="{{ result.url }}" {% if results_on_new_tab %}target="_blank" rel="noopener noreferrer"{% else %}rel="noreferrer"{% endif %}>{{ result.title|safe }}</a></h3>
+ {% if result.publishedDate %}<span class="published_date">{{ result.publishedDate }}</span><br />{% endif %}
+ <a href="{{ result.url }}" {% if results_on_new_tab %}target="_blank" rel="noopener noreferrer"{% else %}rel="noreferrer"{% endif %}><img width="400" src="{{ image_proxify(result.thumbnail) }}" title="{{ result.title|striptags }}" alt="{{ result.title|striptags }}"/></a>
+ <p class="url">{{ result.pretty_url }}&lrm;</p>
+</div>