Why are we so willing to let go of people when they hurt us? Everyone is going through something. Sometimes it takes time to realize that we've crossed a line with someone we love. Sometimes we just need to work on ourselves and pull away from others for a little while.
But don't take titles for granted. If they are a "best friend" or a "loved one," treat them that way--even when they make it hard. Be somebody for them when they have no one else. If they push you away, give them time don't push back or give up. Good friends are those who stick around and want to be that light in someone else's life. Good friends sympathize and empathize. It may be hard, but we're all human. And when someone pushes away, find some understanding and give them their space, give them understanding. Let them grow and they will come back to you. Sometimes it takes a day, a week or a month. Sometimes it has taken me even longer. But if they're supposed to be in your life they will be.
And if the truly matter to you, then make sure they know it. Gently tell them that they matter. That's probably all they really need, anyway: A reminder that they are loved.