From 52211095aab71f8b59b093b19ae34c222be9f390 Mon Sep 17 00:00:00 2001 From: Markus Hatvan Date: Thu, 14 Oct 2021 09:32:20 +0200 Subject: chore: convert various JS to TS (#2062) --- src/webview/darkmode/custom.js | 22 ---------------------- src/webview/darkmode/custom.ts | 22 ++++++++++++++++++++++ src/webview/darkmode/ignore.js | 3 --- src/webview/darkmode/ignore.ts | 1 + 4 files changed, 23 insertions(+), 25 deletions(-) delete mode 100644 src/webview/darkmode/custom.js create mode 100644 src/webview/darkmode/custom.ts delete mode 100644 src/webview/darkmode/ignore.js create mode 100644 src/webview/darkmode/ignore.ts (limited to 'src/webview/darkmode') diff --git a/src/webview/darkmode/custom.js b/src/webview/darkmode/custom.js deleted file mode 100644 index f767f5755..000000000 --- a/src/webview/darkmode/custom.js +++ /dev/null @@ -1,22 +0,0 @@ -// CSS for pages that need custom styles to work correctly in darkmode -export default { - 'web.whatsapp.com': ` - div.landing-window > div.landing-main { - background-color: #FFFFFF !important; - } - div.landing-window > div.landing-main * { - color: #212121 !important; - } - `, - 'web.threema.ch': ` - .scan { - background-color: #FFF; - } - .scan * { - color: #212121; - } - .scan input.md-input { - color: #212121; - } - `, -}; diff --git a/src/webview/darkmode/custom.ts b/src/webview/darkmode/custom.ts new file mode 100644 index 000000000..f767f5755 --- /dev/null +++ b/src/webview/darkmode/custom.ts @@ -0,0 +1,22 @@ +// CSS for pages that need custom styles to work correctly in darkmode +export default { + 'web.whatsapp.com': ` + div.landing-window > div.landing-main { + background-color: #FFFFFF !important; + } + div.landing-window > div.landing-main * { + color: #212121 !important; + } + `, + 'web.threema.ch': ` + .scan { + background-color: #FFF; + } + .scan * { + color: #212121; + } + .scan input.md-input { + color: #212121; + } + `, +}; diff --git a/src/webview/darkmode/ignore.js b/src/webview/darkmode/ignore.js deleted file mode 100644 index 110df364f..000000000 --- a/src/webview/darkmode/ignore.js +++ /dev/null @@ -1,3 +0,0 @@ -export default [ - 'discordapp.com', -]; diff --git a/src/webview/darkmode/ignore.ts b/src/webview/darkmode/ignore.ts new file mode 100644 index 000000000..daa25d10c --- /dev/null +++ b/src/webview/darkmode/ignore.ts @@ -0,0 +1 @@ +export default ['discordapp.com']; -- cgit v1.2.3-54-g00ecf