US president pledges to sign law protecting reproductive rights if Democratic Party wins upcoming legislative elections.