바이패스는 브라우저의 저장된 비밀번호를 제안합니다.
<input oninput="onInput(this)" type="text" value=""/>
var passwordReal = [];
function onInput(e) {
var value = Array.from(e.value);
// Allow copy
if (value.indexOf('●') < 0) {
this.passwordReal = value;
}
// If current array value is greater than temp array, get the last value just entered
// Otherwise, calculate to make 2 arrays equal
else if (value.length > this.passwordReal.length) {
passwordReal.push(value.pop());
} else {
passwordReal.splice(value.length, (passwordReal.length - value.length));
}
e.value = passwordReal.map(c => c.replace(/./gi, '●')).join('');
console.log(passwordReal.join(''));
}
데모: https://jsfiddle.net/vwp8q720/9/
Reference
이 문제에 관하여(바이패스는 브라우저의 저장된 비밀번호를 제안합니다.), 우리는 이곳에서 더 많은 자료를 발견하고 링크를 클릭하여 보았다 https://dev.to/maphim/bypass-suggest-saved-password-of-browser-26o6텍스트를 자유롭게 공유하거나 복사할 수 있습니다.하지만 이 문서의 URL은 참조 URL로 남겨 두십시오.
우수한 개발자 콘텐츠 발견에 전념 (Collection and Share based on the CC Protocol.)