need advice on how to help my girlfriend

recently she’s started isolating herself from everyone besides me and her parents and this is worrying me a lot. she’s always said she’s not suicidal just apathetic to death, that if she got the option to die without anyone remembering/grieving her she would. and now that she’s started isolating herself to make “everyone forget her” i’m pretty worried. anyone who dealt with this before know what to do? do i need to convince her to not isolate herself or should i just let it be. sorry if this is the wrong subreddit i’m just at a loss rn. she has a lot of mental problems but for the sake of privacy i won’t mention them all