Untitled
3 hours ago in Plain Text
(async()=>{
const wait = ms=>new Promise(res=>setTimeout(res,ms));
// 1) email/member-ID field
const el = document.querySelector('[placeholder*="Enter your email"]');
if(el){
el.focus();
for(const ch of '[email protected]'){
el.value += ch;
el.dispatchEvent(new InputEvent('input',{bubbles:true,inputType:'insertText',data:ch}));
await wait(150); // adjust delay (ms) here
}
el.dispatchEvent(new Event('change',{bubbles:true}));
}
// 2) password field
const pw = document.querySelector('input[type="password"]');
if(pw){
pw.focus();
for(const ch of 'amin@321'){
pw.value += ch;
pw.dispatchEvent(new InputEvent('input',{bubbles:true,inputType:'insertText',data:ch}));
await wait(150);
}
pw.dispatchEvent(new Event('change',{bubbles:true}));
}
// 3) click Sign In
const btn = Array.from(document.querySelectorAll('button'))
.find(b=>b.innerText.trim()==='Sign in');
btn && btn.click();
})();