The US Supreme Court has ruled against Donald Trump’s decision to impose a raft of global tariffs.