The Trump administration has faced a raft of legal challenges as it seeks to radically restrict immigration to the US.