The commitment of Japan to pay guaranteed long-term prices for the critical materials is the latest sign of the enduring impact of China’s supply squeeze.