From 1d74fb3399b815f98f6acd86d570224b9a8fe699 Mon Sep 17 00:00:00 2001 From: Alexander Danilov Date: Fri, 2 Feb 2024 21:38:30 +0600 Subject: [PATCH] For some reason webextension-polyfill stopped connecting automatically. So I manually added the import --- src/background/background.js | 1 + src/background/injector.js | 1 + src/background/intel.js | 1 + src/background/requests.js | 1 + src/content-scripts/bridge.js | 1 + src/content-scripts/loader.js | 2 ++ src/content-scripts/utils.js | 1 + src/i18n.js | 1 + src/jsview/Header.vue | 1 + src/popup/components/ElementPlugin.vue | 1 + src/popup/components/InputCustomServer.vue | 1 + src/popup/components/SectionOptions.vue | 1 + src/popup/components/Title.vue | 1 + src/popup/components/ToggleIITC.vue | 2 ++ src/popup/components/UpdateCheckIntervalSelector.vue | 1 + src/popup/components/mixins.js | 1 + src/popup/data.js | 3 +++ src/popup/search.js | 2 ++ src/settings/add/BlockDrop.vue | 1 + src/settings/add/BlockURL.vue | 1 + src/settings/backup/Main.vue | 1 + src/settings/debug/Main.vue | 1 + 22 files changed, 27 insertions(+) diff --git a/src/background/background.js b/src/background/background.js index 1d153c4..fda284f 100644 --- a/src/background/background.js +++ b/src/background/background.js @@ -1,5 +1,6 @@ //@license magnet:?xt=urn:btih:1f739d935676111cfff4b4693e3816e664797050&dn=gpl-3.0.txt GPL-v3 import { Manager } from "lib-iitc-manager"; +import browser from "webextension-polyfill"; import { _ } from "@/i18n"; import { inject_plugin } from "./injector"; import { diff --git a/src/background/injector.js b/src/background/injector.js index 271db12..be9ec30 100644 --- a/src/background/injector.js +++ b/src/background/injector.js @@ -1,5 +1,6 @@ //@license magnet:?xt=urn:btih:1f739d935676111cfff4b4693e3816e664797050&dn=gpl-3.0.txt GPL-v3 +import browser from "webextension-polyfill"; import { check_matching } from "lib-iitc-manager"; export async function inject_plugin(plugin) { diff --git a/src/background/intel.js b/src/background/intel.js index 1b761cd..49a6fd9 100644 --- a/src/background/intel.js +++ b/src/background/intel.js @@ -1,4 +1,5 @@ //@license magnet:?xt=urn:btih:1f739d935676111cfff4b4693e3816e664797050&dn=gpl-3.0.txt GPL-v3 +import browser from "webextension-polyfill"; import { getTabsToInject } from "./injector"; let lastIITCTab = null; diff --git a/src/background/requests.js b/src/background/requests.js index 91e9898..d2ccb64 100644 --- a/src/background/requests.js +++ b/src/background/requests.js @@ -1,5 +1,6 @@ //@license magnet:?xt=urn:btih:1f739d935676111cfff4b4693e3816e664797050&dn=gpl-3.0.txt GPL-v3 +import browser from "webextension-polyfill"; import { parseMeta, ajaxGet, getUniqId } from "lib-iitc-manager"; const IS_CHROME = !!global.chrome.app; diff --git a/src/content-scripts/bridge.js b/src/content-scripts/bridge.js index ab6fd36..8d2e5dc 100644 --- a/src/content-scripts/bridge.js +++ b/src/content-scripts/bridge.js @@ -1,5 +1,6 @@ //@license magnet:?xt=urn:btih:1f739d935676111cfff4b4693e3816e664797050&dn=gpl-3.0.txt GPL-v3 +import browser from "webextension-polyfill"; import { inject } from "@/content-scripts/utils"; import { strToBase64 } from "@/strToBase64"; diff --git a/src/content-scripts/loader.js b/src/content-scripts/loader.js index a1dbbb7..67c75f4 100644 --- a/src/content-scripts/loader.js +++ b/src/content-scripts/loader.js @@ -1,4 +1,6 @@ //@license magnet:?xt=urn:btih:1f739d935676111cfff4b4693e3816e664797050&dn=gpl-3.0.txt GPL-v3 + +import browser from "webextension-polyfill"; import { GM } from "./gm-api"; import { inject, IITCButtonInitJS } from "./utils"; import { bridgeAction } from "@/content-scripts/bridge"; diff --git a/src/content-scripts/utils.js b/src/content-scripts/utils.js index 8ef61cd..bbdb6e6 100644 --- a/src/content-scripts/utils.js +++ b/src/content-scripts/utils.js @@ -1,5 +1,6 @@ //@license magnet:?xt=urn:btih:1f739d935676111cfff4b4693e3816e664797050&dn=gpl-3.0.txt GPL-v3 +import browser from "webextension-polyfill"; import { getUID } from "lib-iitc-manager"; import { strToBase64 } from "@/strToBase64"; diff --git a/src/i18n.js b/src/i18n.js index 9957bfa..059a2e3 100644 --- a/src/i18n.js +++ b/src/i18n.js @@ -1,4 +1,5 @@ //@license magnet:?xt=urn:btih:1f739d935676111cfff4b4693e3816e664797050&dn=gpl-3.0.txt GPL-v3 +import browser from "webextension-polyfill"; export function _(msg, arg) { return browser.i18n.getMessage(msg, arg); diff --git a/src/jsview/Header.vue b/src/jsview/Header.vue index 73b19d7..872fcf5 100644 --- a/src/jsview/Header.vue +++ b/src/jsview/Header.vue @@ -60,6 +60,7 @@