Maternity leave is calculated as up to 8 weeks before expected delivery + the number of weeks paid leave you are entitled to post-childbirth as per law.