Files
federated-calendar/src/gui/event-editor/gcal-event-editor-dialog.blp
T
Zoey Ahmed 2300ed29cd notes: Add placeholder text if notes section empty
Move the textview box into an overlay, with a label as the overlay
child,
that appears only when the textview is empty, and remove the "Notes"
title for the preference group with the notes row in the event dialog.

This better indicates the notes is an input field to the user, compared
to the design before.

Closes: https://gitlab.gnome.org/GNOME/gnome-calendar/-/issues/1081
Part-of: <https://gitlab.gnome.org/GNOME/gnome-calendar/-/merge_requests/714>
2026-03-23 18:25:12 +00:00

119 lines
2.8 KiB
Plaintext

using Gtk 4.0;
using Adw 1;
template $GcalEventEditorDialog: Adw.Dialog {
content-width: 700;
content-height: 1000;
Adw.NavigationView nav_view {
Adw.NavigationPage main_page {
Adw.ToolbarView {
[top]
Adw.HeaderBar {
show-start-title-buttons: false;
show-end-title-buttons: false;
Button cancel_button {
use-underline: true;
label: _("_Cancel");
clicked => $on_cancel_button_clicked_cb(template) not-swapped;
}
[end]
Button done_button {
use-underline: true;
label: _("_Done");
action-name: "event-editor.save";
styles [
"suggested-action",
]
}
}
content: Box {
orientation: vertical;
Adw.Banner {
title: _("This event is in a read-only calendar. It cannot be edited or deleted.");
revealed: bind template.writable inverted;
}
Adw.PreferencesPage {
vexpand: true;
Adw.PreferencesGroup {
$GcalSummarySection summary_section {
sensitive: bind template.writable;
}
}
Adw.PreferencesGroup {
$GcalCalendarComboRow calendar_combo_row {
sensitive: bind template.writable;
}
}
Adw.PreferencesGroup {
$GcalScheduleSection schedule_section {
sensitive: bind template.writable;
}
}
Adw.PreferencesGroup participants_group {
$GcalAttendeesSection attendees_section {
sensitive: bind template.writable;
}
}
Adw.PreferencesGroup {
title: _("Reminders");
$GcalRemindersSection reminders_section {
sensitive: bind template.writable;
}
}
Adw.PreferencesGroup {
$GcalNotesSection notes_section {
sensitive: bind template.writable;
vexpand: true;
}
}
Adw.PreferencesGroup delete_group {
Adw.ButtonRow {
activated => $on_delete_row_activated_cb(template) not-swapped;
title: _("_Delete Event");
use-underline: true;
styles [
"destructive-action",
]
}
}
}
};
}
}
$GcalAttendeeDetailsPage attendee_details_page {}
}
ShortcutController {
Shortcut {
trigger: "<Control>s";
action: "action(event-editor.save)";
}
}
}
SizeGroup {
mode: vertical;
widgets [
cancel_button,
done_button,
]
}