modify icon command following a13702e0c2

This commit is contained in:
buzz-lightsnack-2007 2024-04-27 09:49:25 +08:00
parent a13702e0c2
commit 4af1cc8e15

View file

@ -1,14 +1,21 @@
import BrowserIcon from '/scripts/GUI/extensionIcon.js'; import BrowserIcon from '/scripts/GUI/extensionIcon.js';
import Image from '/scripts/mapping/image.js'; import Image from '/scripts/mapping/image.js';
import {session} from '/scripts/secretariat.js';
class IconIndicator { class IconIndicator {
/*
Indicate that the website is supported through icon change.
*/
static async enable() { static async enable() {
// WIP. Make sure to determine if the product is bad / good // Set default enabled icon.
BrowserIcon.set(await Image.get('default')); BrowserIcon.set({"Icon": await Image.get('default')});
} }
/*
Indicate that the website isn't supported through icon change.
*/
static async disable() { static async disable() {
BrowserIcon.set(await Image.get('disabled')); BrowserIcon.setIcon({"Icon": await Image.get('disabled')});
} }
} }