aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/utils/compatibility.ts
blob: a139ee046060dc44a5ea6047f3d892d756197964 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
import Config from "../config";

export function runCompatibilityChecks() {
    if (Config.config.showZoomToFillError2 && document.URL.includes("watch?v=")) {
        setTimeout(() => {
            const zoomToFill = document.querySelector(".zoomtofillBtn");
    
            if (zoomToFill) {
                alert(chrome.i18n.getMessage("zoomToFillUnsupported"));
            }

            Config.config.showZoomToFillError2 = false;
        }, 10000);
    }
}

export function isVorapisInstalled() {
    return document.querySelector(`.v3`);
}