It is not without precedent. Courts have upheld government's power to enforce curfews, which limit gatherings of adults, to protect public safety and property. I would like to see a court weigh in the constitutionality of a curfew for the narrow purpose of protecting the public from a pandemic. You may end up being right. I don't think the SCOTUS has weighed in on curfews yet.