Tariffs and the unpredictability they signal have pushed traditional allies to seek deals elsewhere, and China has been eager to oblige.