Codependency Support Group
Codependency is defined as someone who exhibits too much, and often inappropriate, caring for another person's struggles. A codependent person may try to change, or feel shame about their most private thoughts and feelings if they conflict with the other person's struggles. If you are on a journey towards self-love, this support group is for you. Join us and find others...

If you stop taking her behaviour personally and stop taking responsibility for her behaviour (I think your friend was probably like this WAY before you came along!), then what are you left with? You are left with realising that this is just the way she is. If this is the way she is, and if you can't change her, then how much time do want to spend with her? Do you still want to be friends with her? This gives you your power back. You can then decide how much time you want to spend with her. It is great to realise that we actually have choices in these situations!
Just remember, her behaviour is NOT a reflection of your self-worth, this is just the way she is. She may well end up being a 'pop in and out every now and then' friend or someone you speak to mostly on the phone, or you might end up deciding that you don't want to be friends with her at all. This is a decision for you to make.
It is typical codependent behaviour to take all the responsibility for other people's behaviour, we blame ourselves instead of allowing ourselves to see the other person as they really are- a habit we learned growing up, no doubt. Like hbg says, it's not your fault. Take care and I hope you feel better soon :)