Fix autocomplete with mouse (click, double click)

That is the fix for bug in CodeMirror that we should propagate to
upstream. The problem is that CodeMirror expects hits to be LI elements without
children nodes i.e. without any custom markup otherwise click/dblclick
event handlers can't properly utilize event delegation that is not fully
implemented actually.