I think China stands to gain from escalation of the war so its possible they approved. It makes Russia weaker and more dependant on them, distracts the US from the Pacific, and weakens Europe in many ways.
Similar to both Russia and China gaining from war and disruption in the Middle East.
There are many possibilities here.