mirror of
https://github.com/chyzy/RSystem-MVC
synced 2024-11-29 08:55:27 +01:00
20 lines
452 B
JavaScript
20 lines
452 B
JavaScript
$('#user-input').keyup(function (e) {
|
|
|
|
switch (e.keyCode) {
|
|
case 8: {
|
|
if ($(this).val().length === 0) {
|
|
$(this).css("font-weight", "300");
|
|
}
|
|
break;
|
|
}
|
|
default:{
|
|
$(this).css("font-weight", "400");
|
|
}
|
|
}
|
|
});
|
|
|
|
$(document).ready(function () {
|
|
if ($('#user-input').val().length > 0) {
|
|
$('#user-input').css("font-weight", "400");
|
|
}
|
|
}) |