event-editor: Extract attendee summary row into a separate widget

Make the summary row reusable and filterable based on the attendee type.
This gives us the possibility to have separate summaries for
people/groups and resources/rooms.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-calendar/-/merge_requests/671>
This commit is contained in:
mindonwarp
2026-01-21 19:37:55 +00:00
committed by Marge Bot
parent bf31a02a80
commit e7d10964e8
11 changed files with 457 additions and 248 deletions
@@ -23,30 +23,16 @@ template $GcalAttendeesSection: Gtk.Box {
]
}
Adw.ActionRow summary_row {
$GcalAttendeeSummaryRow summary_row {
title: _("Participants");
activatable-widget: open_details;
activated => $on_participant_summary_row_activated_cb(template) not-swapped;
attendees: bind template.attendees;
filter-flags: GCAL_EVENT_ATTENDEE_TYPE_FILTER_PERSON;
}
styles [
"property",
]
[suffix]
Label {
valign: center;
label: bind template.num-participants as <string>;
tooltip-text: _("Number of participants");
styles [
"participants-count-label",
]
}
[suffix]
Image open_details {
icon-name: "go-next-symbolic";
}
$GcalAttendeeSummaryRow {
title: _("Resources");
attendees: bind template.attendees;
filter-flags: GCAL_EVENT_ATTENDEE_TYPE_FILTER_RESOURCE;
}
}
}