The Obama administration had backed some of those cases in federal court. But under Trump, the Justice and Education departments have reversed transgender student guidance, and indicated that investigators would back away from transgender restroom complaints.

The complaint filed on Wednesday is unusual in part because of Shah-Brar’s young age, and also because the case is being brought in state court against a private, secular school. Most high-profile transgender student lawsuits in recent years were brought by teenagers alleging their public schools violated federal civil rights law and the Constitution.

By imposing those conditions, the suit alleges, Heritage Oak Private Education and its parent company, Nobel Learning Communities, illegally discriminated against the girl on the basis of gender identity in a business, engaged in fraudulent business practices, and intentionally inflicted emotional harm.

“They said that we could grow her hair out,” Brar told BuzzFeed News, recounting the school's rules for his daughter in third grade. “But they said no girls bathroom, no female pronouns, no girls name, and no girls uniform.”

But the family confronted roadblocks that winter when administrators said they would still treat her as a boy the following school year, according to a lawsuit the family filed in Orange County Superior Court in California on Wednesday.

That announcement kicked off a journey for her and her parents, Priya Shah and Jaspret Brar, to let their child express her gender identity and come out as a transgender girl at school.

Just before Nikki Shah-Brar’s seventh birthday, in June 2016, she was watching her mom get ready in front of the bathroom mirror when Nikki said, “I’m a girl. I want to be called a girl.”

"We had to stand up for our child who was standing up for who she was."

Shah said her daughter, who is now eight years old, supports suing the school — which she quit in February after being bullied by other students.

“We would not have done it if she didn’t support it,” Shah said. “This was a family decision. We thought we had to stand up for our child who was standing up for who she was. This is not something we do lightly.”

Lawyers for Shah-Brar say they want to show that transgender students still have recourse, whether or not the federal government is involved.

“Given that Trump and the Justice Department have turned their back on the discrimination of transgender individuals, it’s important to put the word out there that this sort of discrimination is actionable in every state in the nation,” Mark Rosenbaum, one of Shah-Brar’s lawyers at the legal support organization Public Counsel, told BuzzFeed News.

The crux of the suit rests on California’s Unruh Civil Rights Act, which bars businesses from discriminating based on a person’s gender identity. The complaint also claims the school violated portions of the California Business and Professions Code, which bans fraudulent practices and misleading advertisements — the complaint alleges the school falsely claims to offer a program that educates the “whole child” and give students “a sense of self-worth.”

In failing to accommodate Shah-Brar as a transgender girl, the suit continues, “Heritage Oak and Nobel Learning Communities exhibited reckless disregard for the emotional distress it would cause her, and engaged in the intentional infliction of emotional distress in violation of California common law.”

Asked to respond to the allegations, Heritage Oak and Nobel Learning Communities emailed a statement to BuzzFeed News saying they wanted to "support not just this 7-year-old, but other young children."

"Due to the sensitivity of the issue and age of the child, we believed we needed expert guidance regarding timing," the statement said, including preparing other students for changes in Shah-Brar and "age-appropriate communication."

The school's statement continued: "We told the family we had decided to retain an outside consultant to assist us, and we were communicating with the family on a consistent basis to discuss potential experts and specific accommodations (in addition to the other accommodations we had already offered, such as use of the single-unit staff bathroom, specific options as to girl's uniform clothing and girl's hairstyle, as well as ceasing to use gender groupings in physical education activities)."

"Unfortunately, these accommodations were rejected and the parents withdrew their child," the statement concludes.

Heritage Oak calls itself a "traditional school" for students from preschool to middle school, and uses the motto "Developing the Whole Child." Its website explains, "This is accomplished by providing a positive, safe, nurturing climate that enhances learning by establishing and maintaining a high level of academic and behavioral standards."

After Shah-Brar came out to her parents in mid-2016, her parents told school officials that she was gender-nonconforming before the school year began. When Shah-Brar started second grade that fall, she still presented at school as a boy, wearing a boy’s uniform and using the boys' restroom. As the year went on, however, she was increasingly insistent in her female gender identity, and her parents sought to prepare for a full transition in third grade.

School officials had been open to discussing Shah-Brar’s gender, the parents said in an interview, but in January 2017, school officials said she would not be allowed to transition.

Phyllis Cygan, the executive director of Heritage Oak, said “Nikki would have to wear the boy’s uniform, use a boy’s name and pronouns, and use the staff restroom,” the complaint says. “She said that Heritage Oak is a ‘conservative institution’ that focuses on ‘character education’ and that allowing Nikki to transition would ‘create an imbalance in our environment.’”

Shah reflected in an interview, “It just felt like a punch in the gut — up to that point, I really did believe they were going to work with us.”

In the previous months, the suit says, other students had been taunting Shah-Brar by saying, “You just don’t know you’re a boy,” “You can’t change being a boy,” and “You’re a loser.”

Shah calls these taunts on her daughter “devastating. She asked us about suicide. She talked about harming herself and hating herself. She refused to go to an open house because she couldn’t handle putting on a male uniform.”

“This is not a trend, it’s not a fad, it’s not a phase,” Shah added. “This is who she is at her very core, and if you can’t learn and grow at school, then you can’t be who you are. We stand with Nikki and we want to do our small part to make sure other transgender kids don’t have the same trauma.”