Moved dynamic resize out of viewport size conditional on resize.