Refactor/modularize views a bit