From 58140a56cf7a2d98745b86e504ecc197b425bb93 Mon Sep 17 00:00:00 2001 From: tophf Date: Tue, 15 Feb 2022 19:21:10 +0300 Subject: [PATCH] add 'auto' to extension icon option, fix typo --- _locales/en/messages.json | 3 +++ js/dom.js | 3 +-- js/prefs.js | 1 + options.html | 11 +++++++++-- 4 files changed, 14 insertions(+), 4 deletions(-) diff --git a/_locales/en/messages.json b/_locales/en/messages.json index f3cb29de..77fa7fbb 100644 --- a/_locales/en/messages.json +++ b/_locales/en/messages.json @@ -1138,6 +1138,9 @@ "message": "Options", "description": "Heading for options section on manage page." }, + "optionsIconAuto": { + "message": "Match the Dark/Light mode automatically" + }, "optionsIconDark": { "message": "Dark browser themes" }, diff --git a/js/dom.js b/js/dom.js index 947ce7fb..80cc2ca8 100644 --- a/js/dom.js +++ b/js/dom.js @@ -500,11 +500,10 @@ const dom = {}; } // add favicon in FF if (FIREFOX) { - const iconset = ['', 'light/'][prefs.get('iconset')] || ''; for (const size of [38, 32, 19, 16]) { document.head.appendChild($create('link', { rel: 'icon', - href: `/images/icon/${iconset}${size}.png`, + href: `/images/icon/${size}.png`, sizes: size + 'x' + size, })); } diff --git a/js/prefs.js b/js/prefs.js index 15fc9755..9c593715 100644 --- a/js/prefs.js +++ b/js/prefs.js @@ -120,6 +120,7 @@ 'sync.enabled': 'none', + 'iconsetAuto': true, 'iconset': 0, // 0 = dark-themed icon // 1 = light-themed icon diff --git a/options.html b/options.html index 28eb8f25..54d0925e 100644 --- a/options.html +++ b/options.html @@ -53,10 +53,10 @@