searxng/searx/templates/oscar
Markus Heiser 4a28a5e6f6 [fix] replace language_support by a language/region view
Most engines response best results if a region is selected, most often a
language is also in the properties of a engine and sometimes the language
argument is just the language of the UI.  Most often choosing a language has a
minor effect on the result list.

To summarize:

Some engines have language codes (e.g. `ca`) in their properties, some have
region codes (e.g. `ca-ES`), some have regions and languages in their properties
and other engine do not have any language or region support.

In the past we generalized *language* over all kind of engines without taking
into mind that most engines gave best result when there is a region selected.

  This *language-centric* view in SearXNG is misleading when we need
  region-codes to parameterize engine request!

This patch replaces the *language-centric* view by a "language / region" view.

Conclusions:

With regions we can't say any longer that a engine supports *this or that*
language, by example: when the user selects 'zh' and a engine supports only
region codes like 'zh-TW' or 'zh-CN' we do not what results the user expects /
similar with 'en' or 'fr when the engine needs a region tag.

- Since it is unclear what the user expects by his language selection, we can't
  assert a property that says: "supports_selected_language"

  The feature is replaced in the UI by the wider sense of "language_support",
  what stands for:

    The engine has some kind of language support, either
    by a region tag or by a language tag.

- A list of "supported_languages" does not make sense when there are regions
  responsible for the result of an engine.

  The "supported_languages" has been removed from the /config URL

- The `has_language` test in the `searx/search/checker/impl.py` has been removed
  since it does not cover engines with region support.

  If there is a need for such a test we can implement new tests after all
  engines with language (region) support has been moved to the *supported
  properites* scheme (see searxng_extra/update/update_languages.py)

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2022-04-19 14:35:02 +02:00
..
messages [fix] templates: remove unneeded escape \' of single quotation mark 2021-11-24 17:40:03 +01:00
result_templates [mod] templates: rename field for <iframe> URL to iframe_src 2022-02-18 19:00:49 +01:00
404.html Drop Python 2 (2/n): templates 2020-09-10 10:39:04 +02:00
advanced.html [fix] make "Advanced settings" openable and usable with keyboard - #350 2020-06-25 19:50:26 +02:00
base.html [fix] merge fake "plugins" endpoint back to "static" 2022-03-29 13:02:21 -04:00
categories.html [enh] introduce categories_as_tabs 2022-01-03 07:01:49 +01:00
index.html [oscar theme] center search on index and use logo with ponthi 2021-11-26 20:52:07 +01:00
info.html Info: code refactoring & bug fixes 2022-03-16 22:26:36 +01:00
infobox.html [mod] duckduckgo_definitions: display only user friendly attributes / URL 2020-10-28 08:09:25 +01:00
languages.html [mod] add flags to the languages filter 2022-03-19 15:09:13 +01:00
macros.html Revert "[fix] return correct favicon path" 2022-04-07 17:56:28 +00:00
navbar.html Various change on PR 930 2022-03-13 22:22:02 +01:00
preferences.html [fix] replace language_support by a language/region view 2022-04-19 14:35:02 +02:00
results.html [fix] query_in_title: add missing space in title 2021-11-29 11:08:21 +01:00
search.html [fix] fix the reset button in the oscar theme (#2306) 2020-11-30 16:30:21 +01:00
search_full.html [mod] separate index and search routes 2020-11-02 20:04:03 -07:00
stats.html [theme] make engine stats clickable 2021-09-12 10:52:15 +02:00
time-range.html fix selects in preferences so they look consistent (#2150) 2020-08-27 21:55:47 +02:00