During a puppy’s early training I make sure it has been desensitised to any noise.
Your problem may be attributable to fireworks, but she should have been made confident about noise during training to the point where the sound, or even sight, of a gun becomes a cue for pleasure not fear.
I have cured several adult dogs which showed fear of bangs through a careful desensitisation process.
I cured another dog, a six-year-old labrador bitch, which was terrified of fireworks, by flooding its senses and using food as a diversion.
I stood about 500 yards from a large public firework display and during an hour of unrelenting noise she consumed her evening meal by being fed a nugget of food every time there was a loud bang.
The result was remarkable and her fear vanished for good. Before starting any retraining programme, it would be worth having her ears checked by a vet to make sure there is no infection that could cause pain when loud noises are heard.