Showing date for only one of several events in widgets?

On the week view of our events calendar, only the first event per day shows the date. Like this:

  • Monday, March 23
    • event
    • event
    • event
  • Tuesday, March 24
    • event
    • event

This seems to be driven by the template for that page. However, we primarily use the widget embed feature to display events on pages we host through Drupal. I know I can pass the date with each event through the widget, but is there a way I can set it to only display the date for the first event of that day, like the events calendar?

I tried looking into using custom variables, so I could store a previous event’s date and compare it to the next one to get rendered, but it doesn’t seem LiveWhale supports that sort of thing. I’d like to avoid going for a JavaScript or CSS based solution if possible.

Is there anything else I can try? Thanks!

Caveat: We use LiveWhale CMS, and I don’t know if things are different for calendar users, or if any of this applies to external embeds.

In the CMS, widgets support the argument hide_date_headers. If that is set to false, it does what you are describing - it adds the date before each set of events in the list.
<arg id="hide_date_headers">false</arg>
In the widget editor it looks like this…

And then you would just exclude the date from each item.

1 Like

Thanks Jon! Yep, this works the same in LiveWhale Calendar, so our OCM friends you could try setting that hide_date_headers setting to false and that should do just what you described without any custom work needed.

Exactly what I needed, thank you so much!!

1 Like