refactoring to put scripts and sheets in a partial