Japan before the "lost decades" and China of today really can't compare. For one, Japan didn't grow 5-6% a year but around 1%.
Japan before that prolonged stagnation reached its maximum human and economic developmental potential.
They spread high education to the entirety of their population and achieved maximum technological innovation by that time.
What I'm trying to say is that they reached the maximum potential for their entire population overall, that's why they stagnated.
They didn't stagnate because of deflation, you can have both deflation and high growth rates, it is not correlated, but they stagnated because they simply reached their maximum as a country.
Then they tried to do perma low-interest rates, and money printing to stimulate some growth but that also stopped working over time.
Despite there being similarities in terms of sharp declining birth rates and an aging population (that won't take effect for at least another 10 years for China today based on the time when it started happening), China currently is still nowhere near reaching its full potential.
There are hundreds of millions of people more to urbanize, give better education, technological innovations are not stopping, etc...
In my opinion, China has around two more decades before it also reaches its maximum economic potential as a country like Japan.
China clearly broke past the so-called "middle-income trap", and defeated it with its amazing innovation and high tech, and it is still far behind the "developmental trap" stage of Japan back in the 90s. I think that China can at least double its current GDP before stopping.