The right to take time off to grieve a miscarriage will be included in a new law