Hey this is super simple, I hope...
Can I use jQuery or JavaScript to change this:
.tint:hover:before {
background: rgba(0,0,255, 0.5);
}
To this:
.tint:hover:before {
background: rgba(255,0,0, 0.5);
}
Hey this is super simple, I hope...
Can I use jQuery or JavaScript to change this:
.tint:hover:before {
background: rgba(0,0,255, 0.5);
}
To this:
.tint:hover:before {
background: rgba(255,0,0, 0.5);
}
Why not have a separate class
.newTint:hover:before {
background: rgba(255,0,0, 0.5);
}
Then use jQuery to switch the classes
$('#myField').removeClass('tint').addClass('newTint');
No, Pseudo-elements are not part of the DOM (Document Object Model), so they can't be manipulated by jQuery or Javascript.
Yes you can by putting this in your script
$(document).ready(function(){
$('.tint:hover:before').css('background',' rgba(255,0,0, 0.5)');
});