Select the first result of the filter automatically

... but only if isn't multiple selector or list. Also, this fixes a minor
bug that happens when the user clicks somewhere else with the dropdown
open, making the title different from the selected option in the select.