add code for widow resize