To make a webapp using js, you need to implement a search function. After entering the search content on ios, there is a completion key and an enter key. What I am monitoring now is the enter key, which means clicking the enter key on the ios keyboard. Search will be performed, but the product says that you have to click the completion button to search. How can I detect this completion button using js?
Listen to the blur event, because clicking the
Complete button
will blur the input boxBy the way, I will add a picture upstairs, the red circle is the
Complete button
<input type="search"> Maybe this? ? ?
Use your completion key to trigger the function of the Enter key
Monitor keyCode
Put it in a form and listen for the submit event.