A federal judge on Thursday said U.S. President Donald Trump's firing of a Democratic member of the National Labor Relations Board was illegal and ordered that she be reinstated to her post.