IITC-CE / ingress-intel-total-conversion

intel.ingress.com total conversion user script with some new features. Should allow easier extension of the intel map.
https://iitc.app
ISC License
279 stars 105 forks source link

FR: Clear field `(X)` button for `Search location` #742

Open nexushoratio opened 2 weeks ago

nexushoratio commented 2 weeks ago

It is a common feature to have a button to clear a field.

As an X Window's user, I am used to its standard double-click to select/middle-click to paste (and the last time I used anything else, I configured it to do the same).

Since the search text sticks around, to do a second search (assuming the next search is already selected), left-click the field, use Control+A to select all the text, then Delete to erase the text, finally middle-click pasting. It would be faster if I could left-click on a button to clear the field, then paste.

Related. there is no "clear results" button. To accomplish the same, one has to erase the current search text then hit Enter to erase the results. Against, a clear field button would make that process easier (either click button followed by Enter or having the click button clear the results).

None of the plugins that I have installed offer a clear-field feature, so I don't know if there is any prior-art in the code base or not (in particular, whether is is some simple thing that jQuery offers out of the box).