mirror of
https://github.com/searxng/searxng.git
synced 2025-07-30 16:42:22 +02:00
simple theme update
- npm package update - apply #1226 - implement vim help dialog - display cookies and search URL with preferences - allow to enable / disable Open Access DOI rewrite - add a clear text button on the left of the search button - implement #1011 : the HTML title page is not set when using POST - remove searx/static/themes/simple/img/loader.gif - use full width when only there are only images as result
This commit is contained in:
parent
845ba79e75
commit
3ba0d0516e
39 changed files with 1755 additions and 1211 deletions
|
@ -52,9 +52,9 @@
|
|||
<p class="value">
|
||||
<select name="autocomplete">
|
||||
<option value=""> - </option>
|
||||
{% for backend in autocomplete_backends %}
|
||||
{%- for backend in autocomplete_backends -%}
|
||||
<option value="{{ backend }}" {% if backend == autocomplete %}selected="selected"{% endif %}>{{ backend }}</option>
|
||||
{% endfor %}
|
||||
{%- endfor -%}
|
||||
</select>
|
||||
</p>
|
||||
<div class="description">{{ _('Find stuff as you type') }}</div>
|
||||
|
@ -71,6 +71,19 @@
|
|||
<div class="description">{{ _('Filter content') }}</p>
|
||||
</fieldset>
|
||||
{{ plugin_preferences('general') }}
|
||||
<fieldset>
|
||||
<legend>{{ _('Open Access DOI resolver') }}</legend>
|
||||
<p class="value">
|
||||
<select id='doi_resolver' name='doi_resolver'>
|
||||
{%- for doi_resolver_name,doi_resolver_url in doi_resolvers.items() -%}
|
||||
<option value="{{ doi_resolver_name }}" {% if doi_resolver_name == current_doi_resolver %}selected="selected"{% endif %}>
|
||||
{{- doi_resolver_name }} - {{ doi_resolver_url -}}
|
||||
</option>
|
||||
{%- endfor -%}
|
||||
</select>
|
||||
</p>
|
||||
<div class="description"><!-- {{ _('Redirect to open-access versions of publications when available (plugin required)') }} --></div>
|
||||
</fieldset>
|
||||
{{ tab_footer() }}
|
||||
|
||||
{{ tab_header('maintab', 'engines', _('Engines')) }}
|
||||
|
@ -151,6 +164,38 @@
|
|||
{{ plugin_preferences('ui') }}
|
||||
{{ tab_footer() }}
|
||||
|
||||
{{ tab_header('maintab', 'cookies', _('Cookies')) }}
|
||||
|
||||
<p class="text-muted" style="margin:20px 0;">
|
||||
{{ _('This is the list of cookies and their values searx is storing on your computer.') }}<br />
|
||||
{{ _('With that list, you can assess searx transparency.') }}<br />
|
||||
</p>
|
||||
|
||||
{% if cookies %}
|
||||
<table class="cookies">
|
||||
<tr>
|
||||
<th>{{ _('Cookie name') }}</th>
|
||||
<th>{{ _('Value') }}</th>
|
||||
</tr>
|
||||
{% for cookie in cookies %}
|
||||
<tr>
|
||||
<td>{{ cookie }}</td>
|
||||
<td>{{ cookies[cookie] }}</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
{% else %}
|
||||
{% include 'oscar/messages/no_cookies.html' %}
|
||||
{% endif %}
|
||||
|
||||
<h4>{{ _('Search URL of the currently saved preferences') }} :</h4>
|
||||
<div class="selectable_url">
|
||||
<pre>{{ url_for('index', _external=True) }}?preferences={{ preferences_url_params|e }}{% raw %}&q=%s{% endraw %}</pre>
|
||||
</div>
|
||||
<p class="small_font">{{ _('Note: specifying custom settings in the search URL can reduce privacy by leaking data to the clicked result sites.') }}</p>
|
||||
|
||||
{{ tab_footer() }}
|
||||
|
||||
{{ tab_header('maintab', 'privacy', _('Privacy')) }}
|
||||
<fieldset>
|
||||
<legend>{{ _('Method') }}</legend>
|
||||
|
@ -173,6 +218,7 @@
|
|||
<div class="description">{{ _('Proxying image results through searx') }}</div>
|
||||
</fieldset>
|
||||
{{ plugin_preferences('privacy') }}
|
||||
|
||||
{{ tab_footer() }}
|
||||
|
||||
{{ tabs_close() }}
|
||||
|
@ -180,7 +226,7 @@
|
|||
<p class="small_font">{{ _('These settings are stored in your cookies, this allows us not to store this data about you.') }}
|
||||
<br />
|
||||
{{ _("These cookies serve your sole convenience, we don't use these cookies to track you.") }}
|
||||
</p>
|
||||
</p>
|
||||
|
||||
<input type="submit" value="{{ _('save') }}" />
|
||||
<div class="{% if rtl %}left{% else %}right{% endif %} preferences_back"><a href="{{ url_for('clear_cookies') }}">{{ _('Reset defaults') }}</a></div>
|
||||
|
|
|
@ -23,17 +23,17 @@
|
|||
{%- endif -%}
|
||||
{% if result.address.road -%}
|
||||
<span itemprop="streetAddress">
|
||||
{% if result.address.house_number %}{{ result.address.house_number }}, {% endif %}
|
||||
{{ result.address.road }}
|
||||
{%- if result.address.house_number -%}{{- result.address.house_number -}}, {% endif %}
|
||||
{{- result.address.road -}}
|
||||
</span><br/>
|
||||
{%- endif %}
|
||||
{%- if result.address.locality -%}
|
||||
<span itemprop="addressLocality">{{ result.address.locality }}</span>
|
||||
{% if result.address.postcode %}, <span itemprop="postalCode">{{ result.address.postcode }}</span>{% endif %}
|
||||
<span itemprop="addressLocality">{{- result.address.locality -}}</span>
|
||||
{%- if result.address.postcode -%}, <span itemprop="postalCode">{{- result.address.postcode -}}</span>{% endif %}
|
||||
<br/>
|
||||
{%- endif -%}
|
||||
{%- if result.address.country -%}
|
||||
<span itemprop="addressCountry">{{ result.address.country }}</span>
|
||||
<span itemprop="addressCountry">{{- result.address.country -}}</span>
|
||||
{%- endif -%}
|
||||
</p>
|
||||
{%- endif -%}
|
||||
|
@ -44,11 +44,8 @@
|
|||
|
||||
{% if result.osm and (result.osm.type and result.osm.id) -%}
|
||||
<div class="result-content invisible" id="result-overpass-{{ index }}"{% if rtl %} dir="ltr"{% endif %}>
|
||||
<div id="result-overpass-table-loading-{{ index }}"><img src="{{ url_for('static', filename='img/loader.gif') }}" alt="Loading ..."/></div>
|
||||
<div id="result-overpass-table-loading-{{ index }}"><div class="loader">{{ _('Loading...') }}</div></div>
|
||||
<table id="result-overpass-table-{{ index }}">
|
||||
<thead>
|
||||
<tr><th>key</th><th>value</th></tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
</tbody>
|
||||
</table>
|
||||
|
|
|
@ -1,18 +1,25 @@
|
|||
{% extends "simple/base.html" %}
|
||||
{% from 'simple/macros.html' import icon, icon_small %}
|
||||
{% block title %}{{ q|e }} - {% endblock %}
|
||||
{% block title %}{% if method == 'GET' %}{{- q|e -}} -{% endif %}{% endblock %}
|
||||
{% block meta %}<link rel="alternate" type="application/rss+xml" title="Searx search: {{ q|e }}" href="{{ url_for('index') }}?q={{ q|urlencode }}&categories={{ selected_categories|join(",") | replace(' ','+') }}&pageno={{ pageno }}&time_range={{ time_range }}&language={{ current_language }}&safesearch={{ safesearch }}&format=rss">{% endblock %}
|
||||
{% block content %}
|
||||
<nav id="linkto_preferences"><a href="{{ url_for('preferences') }}">{{ icon('navicon-round') }}</a></nav>
|
||||
{% include 'simple/search.html' %}
|
||||
<div id="results">
|
||||
{% if answers %}
|
||||
|
||||
{% if results and results|map(attribute='template')|unique|list|count == 1 %}
|
||||
{% set only_template = 'only_template_' + results[0]['template']|default('default')|replace('.html', '') %}
|
||||
{% else %}
|
||||
{% set unique_template = '' %}
|
||||
{% endif %}
|
||||
|
||||
<div id="results" class="{{ only_template }}">
|
||||
{% if answers -%}
|
||||
<div id="answers"><h4 class="title">{{ _('Answers') }} : </h4>
|
||||
{% for answer in answers -%}
|
||||
<div class="answer">{{ answer }}</div>
|
||||
{%- endfor %}
|
||||
{%- for answer in answers -%}
|
||||
<div class="answer">{{- answer -}}</div>
|
||||
{%- endfor -%}
|
||||
</div>
|
||||
{% endif %}
|
||||
{%- endif %}
|
||||
|
||||
<div id="sidebar">
|
||||
|
||||
|
@ -24,16 +31,16 @@
|
|||
<div class="dialog-error" role="alert">
|
||||
<p><strong>{{ _('Error!') }}</strong> {{ _('Engines cannot retrieve results') }}:</p>
|
||||
<p>{% for engine_name, error_type in unresponsive_engines %}
|
||||
{{ engine_name }} ({{ error_type }}){% if not loop.last %}, {% endif %}
|
||||
{{- engine_name }} ({{- error_type -}}){% if not loop.last %}, {% endif %}
|
||||
{% endfor %}</p>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% if infoboxes %}
|
||||
<div id="infoboxes">
|
||||
{% for infobox in infoboxes %}
|
||||
{% include 'simple/infobox.html' %}
|
||||
{% endfor %}
|
||||
{% for infobox in infoboxes -%}
|
||||
{% include 'simple/infobox.html' %}
|
||||
{%- endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
|
@ -56,7 +63,7 @@
|
|||
|
||||
<div id="search_url">
|
||||
<h4 class="title">{{ _('Search URL') }} :</h4>
|
||||
<div><pre>{{ base_url }}?q={{ q|urlencode }}&language={{ current_language }}&time_range={{ time_range }}&safesearch={{ safesearch }}{% if pageno > 1 %}&pageno={{ pageno }}{% endif %}{% if selected_categories %}&categories={{ selected_categories|join(",") | replace(' ','+') }}{% endif %}</pre></div>
|
||||
<div class="selectable_url"><pre>{{ base_url }}?q={{ q|urlencode }}&language={{ current_language }}&time_range={{ time_range }}&safesearch={{ safesearch }}{% if pageno > 1 %}&pageno={{ pageno }}{% endif %}{% if selected_categories %}&categories={{ selected_categories|join(",") | replace(' ','+') }}{% endif %}</pre></div>
|
||||
</div>
|
||||
<div id="apis">
|
||||
<h4 class="title">{{ _('Download results') }}</h4>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<div id="search_wrapper">
|
||||
<div class="search_box">
|
||||
<input id="q" name="q" type="text" placeholder="{{ _('Search for...') }}" tabindex="1" autocomplete="off" spellcheck="false" dir="auto" {% if q %}value="{{ q }}"{% endif %} >
|
||||
<button id="clear_search" type="button" tabindex="-1"><span class="hide_if_nojs">{{ icon('close') }}</span><span class="show_if_nojs">{{ _('Clear search') }}</span></button>
|
||||
<button id="send_search" type="submit" tabindex="-1"><span class="hide_if_nojs">{{ icon('search') }}</span><span class="show_if_nojs">{{ _('Start search') }}</span></button>
|
||||
</div>
|
||||
<div class="search_filters">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue