We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f596121 commit 7d02b42Copy full SHA for 7d02b42
scripts/changeAudioOutput.js
@@ -75,10 +75,14 @@ export default {
75
76
submitButton.onclick = async function (e) {
77
if (submitButton.disabled) return;
78
+ let audio_video = Array.from(document.querySelectorAll("audio,video"));
79
+
80
+ if (!audio_video.length)
81
+ return alert("Không tìm thấy âm thanh/video nào trong trang web");
82
83
submitButton.innerText = "Setting...";
84
disableBtn(submitButton);
- for (let el of Array.from(document.querySelectorAll("audio,video"))) {
85
+ for (let el of audio_video) {
86
await el.setSinkId(deviceSelector.value);
87
}
88
submitButton.innerText = "Set Device";
0 commit comments