Looking after yourself is vital to your child’s wellbeing. Not only will they see you modelling healthy approaches to mental health, but you’ll also be in a better position to help them, should they ever need it.
Mind has a good guide on Parenting with a Mental Health Problem.