Creating a Timeline

Hello,

I’m building a timeline to display historical events. For ease of maintenance and editing, I would like to use collections for events.

I created a collection for “Events” and another collection for “Years”. The “Events” collection has a reference field to “Years”. Creating events and tagging a year feels natural and organized, but I don’t know how to display it like the screenshot below.

I tested nesting collections and using filters and conditions, but that’s not quite right. Is there a way to do this?

Thank you,
Matthew