refactored editor layout to nested class