cr fixes: formatting, moving elements to separate class