China has agreed to ease curbs on rare earth exports in a new trade deal with the US, although Beijing left room to resurrect the restrictions if trade tensions escalate.