javascript override of browser styles.
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
document.addEventListener('DOMContentLoaded', function() {
|
||||
let inputs = document.querySelectorAll('input');
|
||||
|
||||
inputs.forEach(input => {
|
||||
if (input.matches(':-webkit-autofill')) {
|
||||
input.classList.add('autofilled');
|
||||
}
|
||||
|
||||
function apply_hover(el) {
|
||||
input.classList.add('autofilled');
|
||||
}
|
||||
|
||||
input.addEventListener('hover', apply_hover);
|
||||
input.addEventListener('focus', apply_hover);
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user