New York state has enacted strong new legal protections for abortion rights. The new law, signed by Governor Andrew Cuomo on Tuesday, safeguards rights laid out in Roe v. Wade and other court rulings, including a provision permitting late-term abortions when a woman's health is endangered, The Associated Press reports. The state's previous law, which had been on the books for nearly 50 years, only permitted abortions after 24 weeks of pregnancy if a woman's life was at risk.

Governor Cuomo celebrated the passing of the bill in the Democrat-led Senate and Assembly on Tuesday, which happened to be the 46th anniversary of the Roe decision. "In the face of a federal government intent on rolling back Roe v. Wade and women's reproductive rights, I promised that we would enact this critical legislation within the first 30 days of the new session — and we got it done," Cuomo said in a statement. He directed state landmarks like the spire of One World Trade Center to be lit up in pink to "shine a bright light forward for the rest of the nation to follow."

"We're saying here in New York, women's lives matter. We're saying here in New York, women's decisions matter," Senate Majority Leader Andrea Stewart-Cousins said.

Get Breaking News Delivered to Your Inbox

Sarah Weddington, the Texas attorney who successfully argued Roe before Supreme Court, was at Cuomo's side when he signed the Reproductive Health Act into law.

"Thank you for what you've done for women," Weddington told the governor, lawmakers and advocates.

The Reproductive Health Act replaces a 1970 state abortion law that was passed three years before Roe legalized abortion nationwide.

The new law moves the section of state law dealing with abortion from the penal code to health statutes. It also authorizes midwives and physician assistants to perform some abortions, CBS New York reports.

Abortion rights supporters pushed for years to update the law. When Democrats gained control of the state Senate this year, the act became easier to pass in both chambers. Supporters said the election of President Donald Trump and the nomination of conservative justices helped galvanize efforts to pass this law.

Republicans who opposed the bill offered proposals to create new legal penalties for harming pregnant women. Some critics argued the bill could make it harder for prosecutors to bring charges when a woman is assaulted and loses her pregnancy, the AP reports, although Democrats disputed that. Some opponents also predicted the bill will lead to more late-term abortions.

According to the New York State Department of Health, 285,127 induced abortions occurred in the state between 2012 and 2014. The average number of live births for the same three years was 237,499. Nationwide, the vast majority of abortions take place in the first trimester.

The AP reports nine other states including California, Washington and Oregon have also put protections for abortion rights in their state statutes, to preserve legal access in those states if Roe is overturned.

Editor's note: The headline on this story has been changed to more accurately describe the new law.