Losing a job during or shortly after maternity or parental leave can create significant financial uncertainty.