Fix selecting types in the UI

This PR adds support for selecting the index type when uploading files. Also, it works around a minor issue with firefox where it tries to upload a file when the project view is opened for the first time.