Hi and welcome to beyond blue.
Sorry that I cannot answer your question, but it sounds like things must be really bad at work for you to feel the need to quit.
I obviously don't know the situation you are in... Can I ask whether you have spoken to anyone at work about the situation to find a way forward. There were times when I was really low that my psychologist challenged (?) to tell my boss "things", my mother gave similar advice as well. I cannot say it as easy but were able to find some way forward. That helped for me though I don't know whether it would be an option for you.
I do hope you come back and share more of your story.