I am a 'gentle' parent (in quotation marks because the word means different things to different people) and I have yelled at my dc.
I always talk about it later with them. I take responsibility for my yelling, and tell them it's not their fault I have used my 'scary' voice.
When I feel like all is good (we have a strong connection again), I try and understand why they did/ said what they did before I lost it and suggest better ways for them to react next time I.e. correct their behaviour that way, with calm authority.
Posting this as often when a parent says 'I yelled at dc' they're being attacked on here.
We are all human and there's often many things going on for us. As long as we try and fix things as we go, think how to do things differently next time, we are doing parenting right.