you can check this
function hideKeyboard(element) {
element.attr('readonly', 'readonly'); // Force keyboard to hide on input field.
element.attr('disabled', 'true'); // Force keyboard to hide on textarea field.
setTimeout(function() {
element.blur(); //actually close the keyboard
// Remove readonly attribute after keyboard is hidden.
element.removeAttr('readonly');
element.removeAttr('disabled');
}, 100);
}
solved How to close mobile keyboard on (keyup.enter) – Angular 6