From 67b0b68b407b6080dd3b9e424eb2cfefbda87e13 Mon Sep 17 00:00:00 2001 From: Alexandre Flament Date: Sat, 30 Oct 2021 10:01:58 +0200 Subject: [fix] simple theme: /preferences: dark theme version for the response time bar charts --- searx/static/themes/simple/src/less/definitions.less | 2 ++ 1 file changed, 2 insertions(+) (limited to 'searx/static/themes/simple/src/less/definitions.less') diff --git a/searx/static/themes/simple/src/less/definitions.less b/searx/static/themes/simple/src/less/definitions.less index 9df9019f2..244bd817d 100644 --- a/searx/static/themes/simple/src/less/definitions.less +++ b/searx/static/themes/simple/src/less/definitions.less @@ -8,6 +8,7 @@ html { /// Base Colors --color-base-font: #444; + --color-base-font-rgb: 68, 68, 68; --color-base-background: #fff; --color-url-font: #29314d; --color-url-visited-font: #80b; @@ -108,6 +109,7 @@ html { html { /// Base Colors --color-base-font: #bbb; + --color-base-font-rgb: 187, 187, 187; --color-base-background: #222; --color-url-font: #8af; --color-url-visited-font: #96b; -- cgit v1.2.3 From d0a31645145aa34dc41e0f4defcdf8c909b10416 Mon Sep 17 00:00:00 2001 From: Alexandre Flament Date: Sat, 30 Oct 2021 11:51:52 +0200 Subject: [fix] simple theme: /preferences: dark theme version for select widgets It is not possible to use CSS variable in a SVG when this is in a background. This commit adds two .svg files, less converts them into data URL. The two files are indentical except the fill color. --- searx/static/themes/simple/src/less/definitions.less | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'searx/static/themes/simple/src/less/definitions.less') diff --git a/searx/static/themes/simple/src/less/definitions.less b/searx/static/themes/simple/src/less/definitions.less index 244bd817d..d99cca713 100644 --- a/searx/static/themes/simple/src/less/definitions.less +++ b/searx/static/themes/simple/src/less/definitions.less @@ -232,3 +232,7 @@ html { @icon-font-name: "glyphicons-halflings-regular"; //** Element ID within SVG icon file. @icon-font-svg-id: "glyphicons_halflingsregular"; + +// decoration of the select HTML elements +@select-light-svg-path: "../svg/select-light.svg"; +@select-dark-svg-path: "../svg/select-dark.svg"; -- cgit v1.2.3 From 60d595ea528cd5c63543a6ed5f4f102c23b33090 Mon Sep 17 00:00:00 2001 From: Alexandre Flament Date: Sat, 30 Oct 2021 11:54:31 +0200 Subject: [mod] simple theme: use :root instead of html to define CSS variables This allows to use the CSS variables in inline svg. --- searx/static/themes/simple/src/less/definitions.less | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'searx/static/themes/simple/src/less/definitions.less') diff --git a/searx/static/themes/simple/src/less/definitions.less b/searx/static/themes/simple/src/less/definitions.less index d99cca713..d2e91f1c3 100644 --- a/searx/static/themes/simple/src/less/definitions.less +++ b/searx/static/themes/simple/src/less/definitions.less @@ -5,7 +5,7 @@ */ /// Light Theme -html { +:root { /// Base Colors --color-base-font: #444; --color-base-font-rgb: 68, 68, 68; @@ -106,7 +106,7 @@ html { /// Dark Theme (autoswitch based on device pref) @media (prefers-color-scheme: dark) { - html { + :root { /// Base Colors --color-base-font: #bbb; --color-base-font-rgb: 187, 187, 187; -- cgit v1.2.3