fix broken modals, move up template to index.html