revert(extension): drop post-3.1.2 frame-targeting band-aids

Restores extension/ to the state directly after webNavigation was removed
(4d78970). The six follow-up commits layered heuristics on an unverified
premise (frame-ID sweeps, multi-phase probes, retry loops) without fixing
the underlying resolver. They are removed so the real fix can be built on
a known state.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
Timo
2026-08-17 23:53:10 +02:00
parent 804c36c694
commit 04694d4439
23 changed files with 245 additions and 744 deletions
+17 -29
View File
@@ -867,30 +867,19 @@
if (wasDesynced) {
runtimeMessage({ type: 'HCM_DESYNC_STATE', desynced: false }).catch(() => {});
}
// Resync to the host's current position (retries if host state not yet known).
hcmRequestHostSyncWithRetry();
reportLog('Host-only: resynced with the host', 'info');
}
}
// Resync to the host's current position (retries if host state not yet known).
hcmRequestHostSyncWithRetry();
reportLog('Host-only: resynced with the host', 'info');
}
if (hcmBadgeHost) return;
if (!document.body) {
// Body not ready yet (very early injection). Defer until DOMReady,
// otherwise the desynced user silently never sees the badge (L-4).
if (!hcmBadgePending) {
function hcmShowBadge() {
if (hcmBadgeHost) return;
@@ -918,9 +907,8 @@
}
}
b.append(hcmEl('span', null, '● ' + hcmStrings.badge), hcmEl('span', 'text-decoration:underline', hcmStrings.resync));
b.addEventListener('click', hcmExitDesync);
return;
}
@@ -1250,7 +1238,7 @@
let bestRank = null;
for (const video of candidates) {
if (!video || video.tagName !== 'VIDEO' || !isVideoRendered(video)) continue;
const rank = VIDEO_RANKING_SIGNALS.map(signal => signal(video));
@@ -2074,7 +2062,7 @@
// host commands. Only ACK FORCE_SYNC_PREPARE — that's the one the host's
runtimeMessage({ type: 'FORCE_SYNC_ACK' }).catch(() => {});
// force-sync flow actually waits on. Skipping CMD_ACKs for PLAY/PAUSE/SEEK
// is intentional so the host's UI honestly reflects that we didn't apply
@@ -2129,7 +2117,7 @@
return;
}
tryMediaAction(EVENTS.PAUSE);
}