Extract date rendering into per-feature Date components

This commit is contained in:
tleininger committed 2026-09-25 08:49:44 +02:00
1 parent d95bf0dcbe
commit 455b603299
16 files changed
+168 -71

No files matched your search

@@ -25,7 +25,7 @@ public partial class EventsEmbed
[CascadingParameter]
private HttpContext? HttpContext { get; set; }
private IReadOnlyList<Event> _upcoming = [];
private IReadOnlyList<Event> _upcomingEvents = [];
protected override async Task OnInitializedAsync()
{
@@ -45,7 +45,7 @@ public partial class EventsEmbed
// Teaser: the soonest upcoming events, earliest first. An event earlier
// today still counts as upcoming.
var today = DateOnly.FromDateTime(DateTime.Today);
_upcoming =
_upcomingEvents =
[
.. events
.Where(@event => DateOnly.FromDateTime(@event.Start) >= today)