@Whambam2023
My 2nd daughter was born missing her hand below the elbow. It's very easy to start wondering if you'd done something, even accidentally, to cause it.
I had a sickness bug in early pregnancy, and my first reaction was to think of that and wonder if it was that. Then I remembered a very rattly bus I'd been on... well you can see from that how determined I was to find it was something I'd done. Even when the specialists (kindly) told me there was nothing I'd done I was still wondering.
Even the scientists have no idea why this happens to around 60 children a year in the UK.
The reality is though that the vast majority of things like that are just "one of those things".
What I was told though, is that for the missing arm, is that if something had been done that had caused it, it typically causes more than just one problem. For example a drug (like thalidomide) always effected both arms (that's not saying if it effects both sides then it is something you've done, it can also be genetic, and also unknown).
So if it's only her heart effected then there's a good chance it's just "one of those things".
Let's say it was Covid though. If it's a rare condition, then there's been enough people round the world with Covid when pregnant for scientists to be saying "hmm, there's a bit of a blip here, let's take a look, why have we got 12 children in the Uk with it in a time scale we'd expect to only see 6". Yes, it would take time, but people were on high alert during Covid for looking out for such things, so I think there would have been something picked up.
I hope she's better now and the surgery is successful to a point she won't need more.