Convereted to haml, added states