If the Indians launch a war on any massive scale in an attempt to overwhelm Chinese forces at the Ladakh side borders, they can stand to gain some ground due to overwhelming numbers advantage in this geography. They don't do it because that valve isn't opened yet by Modi but he's primed the press and set up every justification along the way. The only issue for him is China sure as fk won't be backing down and whatever ground the Indians gain won't be held for long.
The gap between China's military strength and India's is greater than the gap between the US and China's back in the 1990s. The economic and industrial gap is even greater than that. China will require shifting some key military strength towards India if such a thing were to happen and if so, the price for India needs to be set commensurately. If Pakistan will only sit on its hands if such a major war were to happen, that would be a failure on both China and Pakistan. After all, India poses an existential threat to Pakistan due to a more convincing dominance of escalation ladder and respective sizes. If India sees a major two front war opening up and China redirecting force towards it, it will see the end and may choose to threaten Pakistan just to stop invasions. China will not be able to afford an invasion to destroy or take over India but beating them back, securing claimed parts and then some is the least it could do as a "price" for India instigating any major war. China would be able to stretch itself no further and may need to deal with an incessantly annoying and provocative India if it does this. Lose lose in every way since China will have to deal with a more belligerent India if India were to lose land beyond Chinese claim lines. Pakistan cannot risk nuclear war with India, China cannot and honestly does not want to capture India. Ideally India gets split and balkanised with internal conflict along those divisions - Punjab, Kerala, Assam etc but this is easier said than done.
If India's internal turmoil turns even more dramatic, Modi may choose that path since he's little to lose. Wait to watch India continue slumming towards the bottom of the ladder or divide further along those lines of tension or redirect focus on a war with China he knows is counter to China's wishes for ascending further. It throws a massive spanner in the works and the Anglo allies would love to see the Indians fight with the Chinese while they sit back and provide lip service for the audiences.
To realise this is CCP's first job, to guard against this is its main job regarding relations with India. There is no solution. It's like living in wealth next to a violent, aggressive, and mentally retarded neighbour who deeply envies you and throws tantrums every once in a while. You can't kill him every time he makes a move on you because you'd go to prison but you don't have a solution.
If India commits to human and armour wave invasion on Tibet, China has lots of metal to meet those Indians and they need to be stocked up en masse and delivered quickly. Repelling an massive Indian invasion isn't hard since any mobilisation of that scale of force is visible and obvious for days if not weeks (for the Indians probably months to get their shit together). Not to mention lots more import of equipment and ammunition from Russia, France, and Israel. Once forces amassed, depending on size, mobilise counters. Indian warfare is infantry level tactics thinking. China needs to cripple Indian infrastructure, attack supply nodes, neutralise Indian air power with hypersonic weapons and ballistic missiles, infantry are soft targets once critical support is absent. Thermobaric weapons take out entire battalions in seconds and infantry are visible from space in real time.
India is a speed bump that China would much rather avoid having to deal with. And it also seems India itself is unwilling to throw itself towards China either. Hopefully this Ladakh border conflict is de-escalated for good. War is often a poor path to progress.