It should be noted that the question of maternal health was something the Church pondered for a very long time too.
One of the most quoted of early Christian writers on abortion is Tertullian. He has two passages from his treatise on the soul that is standard fare on almost every Catholic pro-life leaning web site. But what can get missed is that the passages are connected. In between them is a gruesome description of a primitive partial birth abortion for medicinal reasons which he describes as an “inarguably just” “necessary cruelty”.
As recently as 1869, the Vatican refused to express an opinion on the matter, passing the question on to theologians. The matter was finally settled by Papal Bull in 1889, but Rome was still clarifying well into the 20th century. For example, Pope Pius XII addressed midwives on the question of medicinal abortions in 1951.
The teaching on direct abortions always being a grave moral disorder became infallible in 1995, by virtue of the universal agreement of the magisterium. Blessed John Paul noted this in the Encyclical Letter Evangelium Vitae.
My point is not that the Church is wrong, my point is that the Church has only been teaching clearly on the matter of abortions for maternal health for a short time. And it is still morally very difficult. It is easy to say ‘she shouldn’t have gotten pregnant’ or ‘she should just die’ when, say, it isn’t a loved one dear to us.
So, when Catholics do disregard this teaching, and they do a fairly high percentage of the time in medically high risk situations, we should answer with love and compassion, not self rightous disapproval.
Also, we need to be aware of possibilties for double effect. Take a more charitable hypothetical than some above. Say that the heart defect was found via the normal pregnancy medical process or that pregnancy occured in spite of NFP. At this point there are two patients in mortal peril.
Even if there is a desire to save the baby at any cost (and this occurs often as well), some of the treatments for a severe heart patient can have life threatening risks for the developing fetus. Again, if the worst occurs, it isn’t really our place to say ‘she shouldn’t have had the surgery…’, etc. Our place is prayers, compassion, and love.
Pax Christi