You said B had a sister who is local; I would make contact with her (if possible) and say that you’re concerned for B’s health based on what you’ve heard from A. I expect that having a family member checking up on B would be the easiest way to relieve the pressure/stress on A.
If A feels obliged to give B a lift to the house she’s doing up, could she offer to give B a lift every fortnight/month due to “other regular plans” (family engagements etc). Again this would reduce the stress on A whilst not isolating B.
If B is due out of hospital in the next few days would it be possible for A to stay with you for a few days, if you’re off work? It would help A relax a little more and give her time to think.
The last thing you want to do is completely isolate B, both for her health and A’s; if A thinks a downturn in B’s health is due to her ‘shunning’ B she’ll feel dreadful. If the care/comforting of B is spread across more people then B will feel more valued and see more options to discuss her loneliness than just with A.
Apologies for the essay.