mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2025-12-07 12:07:11 +03:00
Add auto-config import to clickbait extension, move more funcs to shared lib
Also fix a isSafari call
This commit is contained in:
@@ -16,6 +16,7 @@ import { showDonationLink } from "./utils/configUtils";
|
||||
import { localizeHtmlPage } from "./utils/pageUtils";
|
||||
import { StorageChangesObject } from "@ajayyy/maze-utils/lib/config";
|
||||
import { getHash } from "@ajayyy/maze-utils/lib/hash";
|
||||
import { isFirefoxOrSafari } from "@ajayyy/maze-utils";
|
||||
const utils = new Utils();
|
||||
let embed = false;
|
||||
|
||||
@@ -186,7 +187,7 @@ async function init() {
|
||||
}
|
||||
|
||||
// Permission needed on Firefox
|
||||
if (utils.isFirefox()) {
|
||||
if (isFirefoxOrSafari()) {
|
||||
const permissionSuccess = await new Promise((resolve) => {
|
||||
chrome.permissions.request({
|
||||
origins: [textChangeInput.value + "/"],
|
||||
|
||||
Reference in New Issue
Block a user