theme refactoring