The Trump Administration's failed attempt to detain migrant families together indefinitely ran into a formidable obstacle in a judge whose upbringing was shaped as the daughter of immigrants.

Judge Dolly Gee had also previously rejected requests to allow the US Government to lock up children with their parents.

Gee, the first Chinese-American woman appointed to the US District Court, has joked that her mother was her first pro bono client because she had to translate for her at medical appointments and help her apply for jobs as a seamstress when she was just a girl.

"She in many ways inspired my desire to go to law school," Gee said in a video produced by the National Asian Pacific American Bar Association.


"I saw first hand the difficulties she encountered as a non-English speaker and also as a garment worker. And I saw many of the abuses that take place in the workplace, and I decided at a fairly early age that I wanted to do some type of work that would address some of the inequities I saw as a child."

On Tuesday, Gee rejected the Trump Administration's efforts to detain immigrant families in long-term facilities, calling it a "cynical attempt" to undo a longstanding court settlement.

Gee referred to President Donald Trump's "ill-considered" action and Congress' failure to address the issue for over 20 years. She said it was "procedurally improper and wholly without merit." The US Justice Department said it disagreed with the ruling and was reviewing it further.

Gee, 59, worked for years as a labour lawyer and arbitrator. President Bill Clinton nominated her as a judge in 1999, but the Republican-controlled Senate dragged its feet and Gee never received a hearing. President Barack Obama nominated her a decade later, and she was confirmed.

Although Gee has handled hundreds of cases, she is best known for a series of decisions on immigration. Overseeing a longstanding settlement over the detention of minors, Gee ruled in 2015 that immigrant children should not be held for long periods — generally no longer than 20 days — even with their parents.

Gee scolded the Obama Administration for holding children in "widespread and deplorable conditions." She dismissed a request to reconsider a decision at one point, noting the Government had "reheated and repackaged" its arguments.

Gee made a landmark ruling in another case in 2013 that gave mentally disabled immigrants the right to legal representation if they were detained and facing deportation.

Jean Reisz, a law professor at the University of Southern California, said Gee has waded into the thorny topic of immigration, where the Government has broad authority.

"Her strong language was kind of a welcome reprieve in a climate where discretion's largely left to the attorney-general and not reviewed by the judiciary. Most judges weren't taking those positions."

Before she became a judge, Gee investigated workplace and racial discrimination and sexual harassment and worked on behalf of labour unions, though she also represented employers in some cases.

Gee said she was often underestimated because she looked much younger than she was and stood only 1.50m.

Her first assignment as a law firm associate sent her to a butcher's union hall where the president was a "huge guy". "He said, 'So you're the lawyer?"' she recalled. "I said, 'I sure as hell am." Once they got down to business, she said his "perceptions melted away."