A nurse who worked with Ebola patients in West Africa in 2014, only to wind up isolated in a tent behind a New Jersey hospital, ended her lawsuit against the state on Thursday with a settlement that spells out rights for people in quarantine.

The nurse, Kaci Hickox, arrived in the United States shortly after a doctor who had returned from Guinea became New York’s first Ebola case. After his diagnosis, the governors of New York and New Jersey said they would begin quarantining travelers who had been in contact with Ebola patients in West Africa.

Ms. Hickox flew into Newark Liberty International Airport on Oct. 24, 2014, and, although she later tested negative for the deadly virus, she was nonetheless forced into quarantine and initially prohibited from seeing a lawyer or receiving visitors. After three days, she was allowed to return to her home in Maine, but only with an escort and on the condition that she would remain in isolation.

Her case reflected both the hysteria stirred up by Ebola at the time and the haphazard, varying rules governing public health emergencies across the country.