Taking a sabbatical from Starfleet or other job to raise a child would not be a problem.
A couple in Starfleet went on sabbatical in Brothers. They ditched their children on the Enterprise. Don't people usually take sabbaticals to spend time with family or something? They were dumped on Riker, one kid nearly killed himself, and the other was told it was all his fault. Parenting fail.
I think you'd be surprised at how often parents want to take a vacation and leave the kids behind with their grandparents/uncles/aunts/executive officers. Sometimes you need some time away to relax and not worry about having to manage the kids as well. It's just that normally you expect the temporary guardians will be a little more... competent.