Added some logic to prevent the dropdown from being closed when clicked.