NEW YORK — Amy Krouse Rosenthal, a popular author, filmmaker and speaker who brightened lives with her wide-eyed and generous spirit – and broke hearts when she wrote of being terminally ill and leaving behind her husband, Jason – died Monday. She was 51.

Rosenthal had been diagnosed in 2015 with ovarian cancer. Her longtime literary agent, Amy Rennert, confirmed her death, saying that Rosenthal “was the most life-affirming person, and love-affirming person.” Fellow author John Green tweeted: “She was a brilliant writer, and an even better friend.”

A Chicago native and longtime resident, Rosenthal wrote more than 30 books, including journals, memoirs and the best-selling picture stories “Uni the Unicorn” and “Duck! Rabbit!” She made short films and YouTube videos, gave TED talks and provided radio commentary for NPR, among others.

She also raised three children and had a flair for random acts of kindness, whether hanging dollar bills from a tree or leaving notes on ATMs.

“I do what feels right to me. If it resonates or plants some seeds, great,” she told Chicago magazine in 2010.

While her books were noted for their exuberant tone, she started a very different conversation early this month with a widely read “Modern Love” column she wrote for The New York Times.

Rosenthal told of learning about her fatal diagnosis, and, in the form of a dating profile, offered tribute to Jason Brian Rosenthal. The essay was titled, “You May Want to Marry My Husband.”

“If you’re looking for a dreamy, let’s-go-for-it travel companion, Jason is your man. He also has an affinity for tiny things: taster spoons, little jars, a mini-sculpture of a couple sitting on a bench, which he presented to me as a reminder of how our family began,” she wrote.

“Here is the kind of man Jason is: He showed up at our first pregnancy ultrasound with flowers. This is a man who, because he is always up early, surprises me every Sunday morning by making some kind of oddball smiley face out of items near the coffeepot: a spoon, a mug, a banana.

“I am wrapping this up on Valentine’s Day, and the most genuine, non-vase-oriented gift I can hope for is that the right person reads this, finds Jason, and another love story begins,” she added.

Rosenthal was a Tufts University graduate who worked in advertising for several years before she had what she called a “McEpiphany”: She was with her kids at McDonald’s when she promised herself that she would leave advertising and become a writer.

Rosenthal more than kept her word.

Starting in the late 1990s, she regularly published at least a book a year, and sometimes three or four.

Rennert said Monday that she had completed seven more picture books before her death, including a collaboration with her daughter Paris, called “Dear Girl.”

Rosenthal loved experimenting with different media, and blending the virtual and physical worlds. One of her favorite projects began with a YouTube video, “17 Things I Made,” featuring everything from books she had written to her three children to a peanut butter and jelly sandwich.

At the end of the video, she welcomed fans to join her at Chicago’s Millennium Park, on August 8, 2008, at 8:08 p.m. The goal was to make a “cool” 18th thing.

Hundreds turned out to “make” things – a grand entrance, a new friend, a splash, or something pretty.