I am so very sorry... I've actually been in this similar situation on the opposite end. last year I had 3 miscarriages while all of my best friends around me kept announcing another beautiful pregnancy. I'll be honest, it wasn't easy...
I think the most important thing to realize is that every woman handles it differently & needs something different as time progresses so it will be hard to know what to do. After my first miscarriage, one of my good friends announced she was pregnant a week later (she knew about me although many others did not). I wanted her to be excited and feel comfortable and to be able to partake in it all...but when I saw her a few weeks later during the holidays, she was going through morning sickness & did not seem grateful to be pregnant. I knew she realized a few comments she made were very insensitive. I wanted to shake her and tell her I'd give anything to have morning sickness so quit having a pity party.
She got a little bit better for a while and I remained excited for her, even though I continued to have more miscarriages (she did not know about these). She started complaining about gaining weight, honestly seemed a bit aloof about having a baby, was kind of annoyed she wasn't having a girl when everyone else was, etc. Honestly, I had to distance myself for a while. she did not know about the other miscarriages, but the first should have been enough ... another friend complained about having to have to a C section ... myself and another friend who was having difficulty getting pregnant were like, who cares??? at least you will have a baby.
Honestly, some thoughts she will have will still be excitement for you if you are close, but she will most likely be extremely touchy and may have some irrational thoughts at times towards your pregnancy or be insensitive to what you are going through. Make sure you don't "complain" about the things you experience..find someone else for that because she will find it insensitive even if it is justified. for first month or so, make sure you acknowledge their loss and how sorry you are, but keep conversation regarding your own pregnancy light around them. beyond that, you will will need to feel her out. a lot will depend on how quickly they get pregnant again, if they have other losses, etc. good luck.