creates conventions for opening and closing modals independent of which view they are on.