Transgender teens Juliet Evancho, left and Elissa Ridenour have settled a lawsuit with their Pennsylvania school district, with officials agreeing to repeal a rule barring them from the girls’ bathroom. (Courtesy of Lambda Legal)

A Pennsylvania school district has settled a lawsuit with three transgender teens, moving to allow all transgender students to use bathrooms in accordance with the gender they identify with and scrapping a rule that required students to use bathrooms that corresponded to their “biological sex.”

Transgender teen Juliet Evancho, whose sister Jackie sang at President Trump’s inauguration and later pleaded to meet the president on behalf of transgender students, sued the Pine-Richland School District after the board passed a resolution barring her from the girls’ bathroom last fall. She was joined by two transgender classmates: Elissa Ridenour and a boy identified as A.S.

The lawsuit was one of several across the nation filed by transgender students challenging school policies that kept them from the bathrooms where they felt most comfortable. Parents and school officials supporting those policies say they are necessary to safeguard privacy and traditional values. But transgender students say the policies are discriminatory and make them feel ostracized.

The U.S. Supreme Court was set this year to hear the case of Gavin Grimm, a transgender teen from Gloucester, Va., who sued his school board after it barred him from the boys’ bathroom. But after the Trump administration withdrew guidance that directed schools to allow transgender student to use bathrooms that match their gender identity, the high court sent the case to a lower court.

The three teen plaintiffs graduated from Pine-Richland High School on June 2, but the settlement will apply to all students. As part of the agreement, the school board repealed the bathroom restrictions, extended nondiscrimination protections to transgender students and directed schools to give them access to the bathrooms of the gender they live as. The board cleared the policies on July 17 with a 6-to-2 vote.

“As a result, any student across the District may access restrooms based upon his or her consistently and uniformly asserted gender identity. Any student may also access a single-user restroom,” the school district said in a statement.

The students have been able to use their preferred bathrooms since February, when a federal judge granted a preliminary injunction that barred the school district from enforcing the bathroom restrictions while the case proceeded. In granting the injunction, Judge Mark Hornak of the U.S. District Court of Western Pennsylvania concluded that the teens would probably prevail in their argument that the bathroom restrictions violated the equal-protection clause of the Constitution.

Omar Gonzalez-Pagan, the Lambda Legal lawyer who represented the students, said the ruling set an important precedent.

Although the teens have graduated, he said, “they have opened the doors not just for current and future students in their school, but really elsewhere.”