fix(extension): support Google Drive video frames

This commit is contained in:
Timo
2026-07-26 03:52:05 +02:00
parent 90a58eb507
commit 213d2867fc
13 changed files with 852 additions and 112 deletions
+12
View File
@@ -150,6 +150,18 @@ export function requestOriginPermission(chromeApi, originPattern) {
).catch(() => false);
}
export function containsOriginPermission(chromeApi, originPattern) {
if (typeof originPattern !== 'string' || !originPattern) {
return Promise.resolve(null);
}
return callBooleanPermissionMethod(
chromeApi,
'contains',
{ origins: [originPattern] },
{ timeoutMs: 1000 }
).catch(() => null);
}
export function isHostAccessError(error) {
const message = typeof error?.message === 'string' ? error.message : String(error || '');
return /host permission|permission to access (?:this|the|respective) host|cannot access contents of/i.test(message);