Since the lawyers haven't chimed in yet and others have brought up the PLCAA I'm going to insert the "why I believe" the justices ruled that way.
Under 15 USC 7902 (a) the plaintiff would normally have no case. However, they can have a case IF they can prove a defect in design. 15 USC 7903 (5) (A) (v)
Applicable Code . However, that same section can be used against the plaintiff because the use of the gun was the result of a criminal act.
I'm no lawyer but I see the eye of the needle that the justices threaded assuming that they took 15 USC 7901-7903 into account.