The world didn't tell Russia to get fked when they occupied Crimea and started a shadow war with Ukraine.
There is a very simple way of telling a country to revert course: deem their passports no longer valid. Fundamentally, the right to move between countries is provided by the International Covenant on Civil and Political Rights Article 12 which says "Everyone shall be free to leave any country, including his own" but then continues "The above-mentioned rights shall not be subject to any restrictions except those which are
provided by law, are necessary to protect national security, public order (ordre public), public health
or morals or the rights and freedoms of others, and are consistent with the other rights recognized in
the present Covenant".
For China, it'd be even easier since they signed but didn't ratify this treaty despite it has been signed in 1966 and in force since 1976.