Refactored layout definitions to router