instagram Default Volume

Set your Instagram videos default volumes

< 脚本 instagram Default Volume 的反馈

提问 / 留言

§
发布于:2025-08-03

Patch: Replace line 27 const targetElement = document.querySelector('.x1iyjqo2.xh8yej3');
with const targetElement = document.querySelector('video').parentElement.parentElement.parentElement.parentElement;

I also replaced the load event with a wait function because it did not always apply.

function updateVolume() {
  ...
}

var retry = 0;
function wait() {
    if(retry++ > 100) {
        console.log("Failed to find video control after 100 attempts");
        return;
    }
    if(document.getElementsByTagName("video").length == 0) {
        setTimeout(wait,100);
    }
    else {
        updateVolume();
    }
}
wait();

发布留言

登录以发布留言。