Capture "done" button click in iPhone's virtual keyboard with JavaScript
I was unable to track the 'done' button being clicked. It didn't register any click
s or keypress
es. I had to addEventListener
s for change
, focusout
and blur
using jquery
(because the project already was using jquery
).
You need to do some kind of this:
$('someElem').focusout(function(e) {
alert("Done key Pressed!!!!")
});
It worked for me, hope it will help you as well.
After searching and trying this solution basically is say:
document.addEventListener('focusout', e => {});
tested on IPhone 6s