unify all classes to take "dimensions" param
add viewport class