established smooth resizing, and reduced codebase