I want to claim some NFTs, but everytime I click to claim. The Metamask shows up and ask me for confirmations. I don't want to click confirmation everytime. :( Below are some code I get from google and paste it on my console chrome ( extension// page), but it doesn't work. Do you have any suggestion?
1,
if (confirm('Warning! This will auto approve ALL transactions until the page is refreshed, continue?')) {
setInterval(function () {
console.log("Scanning for new transactions...");
var a = document.getElementsByTagName("div");
var queue;
for (var i = 0; i < a.length; i++) {
if (a[i].classList.contains("transaction-list-item--unconfirmed")) {
queue = a[i];
break;
}
}
if (typeof queue !== 'undefined') {
if (queue.getElementsByTagName("h3")[0].getElementsByTagName("div")[0].textContent == "Unapproved") {
console.log("New transaction found");
queue.click();
}
}
var c = document.getElementsByTagName("button");
var btnConfirm;
for (var i = 0; i < c.length; i++) {
if (c[i].textContent == "Confirm") {
btnConfirm = c[i];
break;
}
}
var btnReject;
for (var j = 0; j < c.length; j++) {
if (c[j].textContent == "Reject") {
btnReject = c[j];
break;
}
}
if (typeof btnConfirm !== 'undefined' && typeof btnReject !== 'undefined') {
if (!btnConfirm.disabled) {
btnConfirm.click();
}
else {
btnReject.click();
}
}
}, 1000)
}
2,
var x = 111; var i = 0; while (i <x){ i++; $(".btn-primary").click(); $(".confirm-page-container-navigation__imageflip").click(); }
3,
let note = document.getElementsByClassName('confirm-page-container-navigation__navtext'); let data = [].map.call(note, item => item.textContent); console.log(data[0]); let vl = data[0].split(" ").pop(); var x = vl-1; var i = 0; while (i <x){ i++; $(".btn-primary").click(); $(".confirm-page-container-navigation__imageflip").click();}
4,
while (i <111){
i++;
$(".btn-primary").click();
$(".confirm-page-container-navigation__imageflip").click();
}```
Thank you.