Exactly -- that's often referred to as a "72-hour hold," and it's not the same as involuntary commitment, which would be the next step in the process; that involves going before a judge and presenting evidence
(not just opinion) that the patient is an immediate danger to himself or others
. Such evidence might be a failed suicide attempt, or a violent act, or a credible threat of either, made in the presence of others; the evidence has to refer to the person's actual behavior, not merely what a doctor conceives his mental state to be.
So once those 72 hours are up, holding a patient against his will requires due process of law; otherwise it's a violation of his Fifth Amendment right to liberty.
Thomas Jefferson never said that.