From 222031e975bc428b77a00878776744f3de884ca9 Mon Sep 17 00:00:00 2001 From: Markus Heiser Date: Tue, 7 Sep 2021 08:12:46 +0200 Subject: [PATCH] [fix] make oscar theme more CSP compliant - col-checkbox Add col-checkbox in:: searx/static/themes/oscar/src/less/preferences.less Replaced style in file:: searx/templates/oscar/preferences.html Reported-by: https://github.com/searxng/searxng/issues/57 Signed-off-by: Markus Heiser --- .../themes/oscar/src/less/logicodev-dark/oscar.less | 1 + .../static/themes/oscar/src/less/logicodev/oscar.less | 1 + searx/static/themes/oscar/src/less/pointhi/oscar.less | 1 + searx/static/themes/oscar/src/less/preferences.less | 3 +++ searx/templates/oscar/preferences.html | 10 +++++----- 5 files changed, 11 insertions(+), 5 deletions(-) create mode 100644 searx/static/themes/oscar/src/less/preferences.less diff --git a/searx/static/themes/oscar/src/less/logicodev-dark/oscar.less b/searx/static/themes/oscar/src/less/logicodev-dark/oscar.less index 199d76e08..e0d61aac9 100644 --- a/searx/static/themes/oscar/src/less/logicodev-dark/oscar.less +++ b/searx/static/themes/oscar/src/less/logicodev-dark/oscar.less @@ -3,6 +3,7 @@ @import "../../../../__common__/less/stats.less"; @import "../../../../__common__/less/result_templates.less"; @import "../../less/result_templates.less"; +@import "../../less/preferences.less"; @import "../../generated/pygments-logicodev.less"; @stacked-bar-chart: rgb(213, 216, 215, 1); diff --git a/searx/static/themes/oscar/src/less/logicodev/oscar.less b/searx/static/themes/oscar/src/less/logicodev/oscar.less index e9dc1f532..7b2274ddc 100644 --- a/searx/static/themes/oscar/src/less/logicodev/oscar.less +++ b/searx/static/themes/oscar/src/less/logicodev/oscar.less @@ -3,6 +3,7 @@ @import "../../../../__common__/less/stats.less"; @import "../../../../__common__/less/result_templates.less"; @import "../../less/result_templates.less"; +@import "../../less/preferences.less"; @import "../../generated/pygments-logicodev.less"; @import "navbar.less"; diff --git a/searx/static/themes/oscar/src/less/pointhi/oscar.less b/searx/static/themes/oscar/src/less/pointhi/oscar.less index e7ea08b18..827b77ffc 100644 --- a/searx/static/themes/oscar/src/less/pointhi/oscar.less +++ b/searx/static/themes/oscar/src/less/pointhi/oscar.less @@ -3,6 +3,7 @@ @import "../../../../__common__/less/stats.less"; @import "../../../../__common__/less/result_templates.less"; @import "../../less/result_templates.less"; +@import "../../less/preferences.less"; @import "../../generated/pygments-pointhi.less"; @import "footer.less"; diff --git a/searx/static/themes/oscar/src/less/preferences.less b/searx/static/themes/oscar/src/less/preferences.less new file mode 100644 index 000000000..1b44a63eb --- /dev/null +++ b/searx/static/themes/oscar/src/less/preferences.less @@ -0,0 +1,3 @@ +.col-checkbox { + width: 10rem; +} diff --git a/searx/templates/oscar/preferences.html b/searx/templates/oscar/preferences.html index e7163e027..e5743e116 100644 --- a/searx/templates/oscar/preferences.html +++ b/searx/templates/oscar/preferences.html @@ -318,12 +318,12 @@ {{ _("Allow") }} {{ _("Engine name") }} {{ _("Shortcut") }} - {{ _("Selected language") }} - {{ _("SafeSearch") }} - {{ _("Time range") }} + {{ _("Selected language") }} + {{ _("SafeSearch") }} + {{ _("Time range") }} {{ _("Response time") }} - {{ _("Max time") }} - {{ _("Reliablity") }} + {{ _("Max time") }} + {{ _("Reliablity") }} {% else %} {{ _("Reliablity") }} {{ _("Max time") }}