Listing depression and bipolar disorder to explain some ups and downs in grade?

I was recently diagnosed with depression and bipolar disorder and was hospitalized. I was unaware of this and this kinda explained why in high school I has so many ups and downs in my grade. I had some ups and downs in my grade in college as well but for transfer should I mention this or will it just look bad if I talk about it?

I would absolutely mention it. Showing how you dealt with a serious mental condition and your ability to overcome it is a tremendous feat.