A Santa Rosa family celebrated a first special day of school Monday because, thanks to a judge’s order, their 5-year-old child will be able to attend kindergarten and bring her medical marijuana products on campus.

When Brooke Adams walked onto campus Monday morning she was setting a legal precedent.

While medical and recreation marijuana became legal in the state of California, it's still illegal to have marijuana products on public school campuses. Brooke will be one of the first children in the state and country to be legally allowed to be given medical marijuana at school.

When she was just an infant, Brook was diagnosed with a rare form of epilepsy called Dravet Syndrome.

“It gives her seizures that don’t stop very easily, or don’t stop at all,” her father Jon Adams told NBC Bay Area.

Her seizures would last for half an hour — or longer — and paramedics would often have to be called.

Doctors tried a number of powerful drugs to control and prevent them. But none seemed effective — and they all had powerful side effects.

“Behavioral problems, sleep deprived, different things that not good for her,” her mother Jana Adams said.

When Brooke was a little more than a year old, she was issued a medical marijuana card. Her parents say the two products she uses — daily CBD oil and emergency THC oil — are very effective.

CBD is a chemical found in marijuana plants that doesn't produce psychoactive activity the same way THC does. THC is the psychoactive constituent of cannabis that produces the "high" effect.

Brooke now has fewer seizures and they only last three to four minutes after the administration of the oil, according to her family.

“With the emergency THC medicine, she pretty much just like, takes a nap, and she’s back to normal,” her father said.

Lawmakers didn’t take into account that maybe students would be on cannabis and need it at school, Adams said, so the family went to court.

A judge is still weighing their case but he did issue a temporary stay, allowing brook to attend class at least until his decision.

The school district issued this statement about brook’s situation saying: "The Rincon valley unified school district is happy to have the opportunity to serve brook and now has direction from the court to be able to do so.”

The Adams have already met with the school nurse to teach her how to administer the emergency THC oil.

The judge is expected to issue his final decision on this case in late September or early October.

CORRECTION (Aug. 16, 2018. 8:39 a.m.): An earlier version of this story incorrectly reported the first name of Jana Adams.