I had a coworker who went through this. My bosses were very gracious. She was on leave for some time, purely for mental health reasons. And I’m sure returning to work with her job intact was a major comfort. Our direct boss at the time would meet with her for lunch occasionally until she felt well enough to come back. I’m willing to bet it was the best way it could have gone for her in light of what she experienced.
She has since had a healthy baby and is usually beaming.