Hi OP, I think it's a relevant and thoughtful question and very wise to be considering it.
I've had severe anxiety most of my life, with some OCD and depression, and I always knew I wanted children but I did worry. I worried more in my 20s; as I got to my 30s I felt that I was a bit more experienced with my own MH, if that makes sense. I do not think that having MH issues means you shouldn't have children, if they are not really debilitatingly severe, but I do think being aware of it and ready for it can make a big difference.
I agree with PPs preparation is everything - letting all the medical staff you are involved with know about your history, having support lined up, knowing what your triggers or main worries are and having that on your notes, having a plan for what you'll do if you start to feel bad.
I had a traumatic and abusive childhood involving sexual abuse; this was put on my notes along with info about my anxiety and fears about various things. All the staff who helped me give birth, and did the follow-up support afterwards, were understanding and sensitive about it and that really helped. My HV knew from the start I was a worrier and my GP has been on board the whole way too. Being prepared to take meds is also a big plus IME. It is meds that control my anxiety and make it possible for me to have a normal life and be a good mum.
I don't think I'm mum of the year, but I am caring and compassionate, warm and affectionate, set firm boundaries and enjoy being with my DC and they seem to like me. I don't think I'm disastrous.
Also I think MH issues can have a silver lining - they can make you more empathetic and tolerant, more willing to discuss things like this if your DC ever need to, more self-aware which I think can be good things in a parent.
Remember things can get worse after the birth, sometimes because they just do (PND) and sometimes, if your problems stem from a dysfunctional childhood, because having your own child can bring it all back. But if you've got supportive HCPs and are ready to ask for help if you need it, you can get through it.
What you don't want is to be plastering a grin on your face and soldiering on without help when you're actually falling apart. But you don't sound like you are like that.