resize functionality complete