Hide dropdown when open and empty.
Prevent extra request from being sent on selection. Fixes #188.
Make duplicate checking configurable. Closes #293.
Add back custom events.