Refactoring of panels