I created this function which animates label when input has focus.
$("input").on("focus", function () {
$(this).siblings().animate({
top: "-20",
}, 70, function() {
});
});
I would like animate it back if input stays unfilled.
Here is my codepen
Aucun commentaire:
Enregistrer un commentaire