fix navbar highlighting for templates detail view