Comment types and some frontend fixes.

Now comments can have types. This information can be used for all kinds of things. Refer issue ajkl/researchorum#18.