Human rights lawyer Amal Clooney has quit her role as Britain's special envoy on media freedom.
The move is in protest at the country's intention to breach international law over Brexit-related legislation.
The British government has drafted a bill that it acknowledges would violate its international legal obligations and undercut parts of the divorce deal it signed before Britain formally left the European Union in January.
British Prime Minister Boris Johnson has said the bill was essential to counter "absurd" threats from Brussels.
However, it has prompted resignations and the threat of a rebellion by MPs, which appears to have been averted after a compromise was reached.
"It is lamentable for the UK to be speaking of its intention to violate an international treaty signed by the Prime Minister less than a year ago," said Ms Clooney, who is married to actor George Clooney, in a letter to foreign minister Dominic Raab.
"It threatens to embolden autocratic regimes that violate international law with devastating consequences all over the world," she wrote.
She added: "When the Foreign & Commonwealth Office (as it then was) asked me to serve as Special Envoy on Media Freedom, the role was described as one in which I would assist the UK in championing the right to a free press around the world.
"My role was intended to help promote action that governments could take to ensure that existing international obligations relating to media freedom are enforced in accordance with international law.
"I accepted the role because I believe in the importance of the cause, and appreciate the significant role that the UK has played and can continue to play in promoting the international legal order.
"In these circumstances I have been dismayed to learn that the Government intends to pass legislation - the Internal Market Bill - which would, by the Government's own admission, 'break international law' if enacted.
"I was also concerned to note the position taken by the Government that although it is an 'established principle of international law that a state is obliged to discharge its treaty obligations in good faith', the UK's 'Parliament is sovereign as a matter of domestic law and can pass legislation which is in breach of the UK's Treaty obligations'.
"Out of respect for the professional working relationship I have developed with you and your senior colleagues working on human rights, I deferred writing this letter until I had had a chance to discuss this matter with you directly. But having now done so and received no assurance that any change of position is imminent, I have no alternative but to resign from my position."
Read more:
Britain will seek to use treaty breaching powers if EU acts in bad faith
Trump envoy warns UK against creating hard border
Biden: Good Friday Agreement cannot become a casualty of Brexit