I've visited China nearly every year for the past 6 years and never had any sort of issues. I thought all the security personnel I encountered at the airport, immigration, subway stations etc in China were very professional and respectful. In contrast to one of the last times I was returning from China to the U.S. and witnessed a highly unprofessional U.S. CBP officer who was yelling and berating incoming international visitors because they couldn't understand his English, which was infuriating. All this to say that if you want to visit China recreationally (outside of pandemics), you'll almost certainly be fine and treated well.
*Edit: I'm just offering my personal experience here for others to consider amongst other sources of information.