Don't leave... but do contact the school counselor and ask for "accommodations"!!! You might need to cut back on the number of classes (without being penalized) ... you might need someone to take notes for you (if you aren't able to attend or if your mind is too muddled to think and take notes too)... actually the counselor should have a list of accommodations that generally help people with your disorders (and there are plenty of students that suffer as well).
Don't give up. Graduate school is no walk in the park for anyone, and the desire to excel can deepen the depression. Been there, done that.