resize element with window