Auto-collapse when item is selected.

On touch devices, when an item in the collapse is clicked, the menu stays. This change makes it hide