Initial event composing.
This commit is contained in:
@@ -33,6 +33,7 @@ public enum WinoPage
|
||||
CalendarSettingsPage,
|
||||
CalendarAccountSettingsPage,
|
||||
EventDetailsPage,
|
||||
CalendarEventComposePage,
|
||||
SignatureAndEncryptionPage,
|
||||
StoragePage,
|
||||
WelcomePageV2,
|
||||
|
||||
@@ -29,6 +29,7 @@ public interface IDialogServiceBase
|
||||
Task<AccountCreationDialogResult> ShowAccountProviderSelectionDialogAsync(List<IProviderDetail> availableProviders);
|
||||
IAccountCreationDialog GetAccountCreationDialog(AccountCreationDialogResult accountCreationDialogResult);
|
||||
Task<List<SharedFile>> PickFilesAsync(params object[] typeFilters);
|
||||
Task<List<PickedFileMetadata>> PickFilesMetadataAsync(params object[] typeFilters);
|
||||
Task<string> PickFilePathAsync(string saveFileName);
|
||||
Task<WebView2PrintSettingsModel> ShowPrintDialogAsync(WebView2PrintSettingsModel initialSettings = null);
|
||||
|
||||
|
||||
@@ -2,10 +2,12 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.ObjectModel;
|
||||
using System.Threading.Tasks;
|
||||
using Wino.Core.Domain.Entities.Calendar;
|
||||
using Wino.Core.Domain.Entities.Mail;
|
||||
using Wino.Core.Domain.Entities.Shared;
|
||||
using Wino.Core.Domain.Enums;
|
||||
using Wino.Core.Domain.Models;
|
||||
using Wino.Core.Domain.Models.Calendar;
|
||||
using Wino.Core.Domain.Models.Folders;
|
||||
|
||||
namespace Wino.Core.Domain.Interfaces;
|
||||
@@ -18,6 +20,7 @@ public interface IMailDialogService : IDialogServiceBase
|
||||
// Custom dialogs
|
||||
Task<IMailItemFolder> ShowMoveMailFolderDialogAsync(List<IMailItemFolder> availableFolders);
|
||||
Task<MailAccount> ShowAccountPickerDialogAsync(List<MailAccount> availableAccounts);
|
||||
Task<AccountCalendar> ShowSingleCalendarPickerDialogAsync(List<CalendarPickerAccountGroup> availableCalendarGroups);
|
||||
|
||||
/// <summary>
|
||||
/// Displays a dialog to the user for reordering accounts.
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
using System;
|
||||
|
||||
namespace Wino.Core.Domain.Models.Calendar;
|
||||
|
||||
public class CalendarEventComposeAttachmentDraft
|
||||
{
|
||||
public Guid Id { get; set; }
|
||||
public string FileName { get; set; } = string.Empty;
|
||||
public string FilePath { get; set; } = string.Empty;
|
||||
public string FileExtension { get; set; } = string.Empty;
|
||||
public long Size { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
using System;
|
||||
|
||||
namespace Wino.Core.Domain.Models.Calendar;
|
||||
|
||||
public class CalendarEventComposeNavigationArgs
|
||||
{
|
||||
public Guid? SelectedCalendarId { get; set; }
|
||||
public string Title { get; set; } = string.Empty;
|
||||
public string Location { get; set; } = string.Empty;
|
||||
public bool IsAllDay { get; set; }
|
||||
public DateTime StartDate { get; set; }
|
||||
public DateTime EndDate { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Wino.Core.Domain.Entities.Calendar;
|
||||
using Wino.Core.Domain.Enums;
|
||||
|
||||
namespace Wino.Core.Domain.Models.Calendar;
|
||||
|
||||
public class CalendarEventComposeResult
|
||||
{
|
||||
public Guid CalendarId { get; set; }
|
||||
public Guid AccountId { get; set; }
|
||||
public string Title { get; set; } = string.Empty;
|
||||
public string Location { get; set; } = string.Empty;
|
||||
public string HtmlNotes { get; set; } = string.Empty;
|
||||
public DateTime StartDate { get; set; }
|
||||
public DateTime EndDate { get; set; }
|
||||
public bool IsAllDay { get; set; }
|
||||
public string TimeZoneId { get; set; } = string.Empty;
|
||||
public CalendarItemShowAs ShowAs { get; set; }
|
||||
public List<Reminder> SelectedReminders { get; set; } = [];
|
||||
public List<CalendarEventAttendee> Attendees { get; set; } = [];
|
||||
public List<CalendarEventComposeAttachmentDraft> Attachments { get; set; } = [];
|
||||
public string Recurrence { get; set; } = string.Empty;
|
||||
public string RecurrenceSummary { get; set; } = string.Empty;
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
using System.Collections.Generic;
|
||||
using Wino.Core.Domain.Entities.Calendar;
|
||||
using Wino.Core.Domain.Entities.Shared;
|
||||
|
||||
namespace Wino.Core.Domain.Models.Calendar;
|
||||
|
||||
public class CalendarPickerAccountGroup
|
||||
{
|
||||
public MailAccount Account { get; set; } = null!;
|
||||
public List<AccountCalendar> Calendars { get; set; } = [];
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using System.IO;
|
||||
|
||||
namespace Wino.Core.Domain.Models.Common;
|
||||
|
||||
public record PickedFileMetadata(string FullFilePath, long Size)
|
||||
{
|
||||
public string FileName => Path.GetFileName(FullFilePath);
|
||||
public string FileExtension => Path.GetExtension(FullFilePath)?.ToLowerInvariant() ?? string.Empty;
|
||||
}
|
||||
@@ -124,6 +124,56 @@
|
||||
"CalendarAttendeeStatus_NeedsAction": "Needs Action",
|
||||
"CalendarAttendeeStatus_Tentative": "Tentative",
|
||||
"CalendarEventDetails_Attachments": "Attachments",
|
||||
"CalendarEventCompose_AddAttachment": "Add attachment",
|
||||
"CalendarEventCompose_AllDay": "All Day",
|
||||
"CalendarEventCompose_EndDate": "End date",
|
||||
"CalendarEventCompose_EndTime": "End time",
|
||||
"CalendarEventCompose_Every": "every",
|
||||
"CalendarEventCompose_ForWeekdays": "for",
|
||||
"CalendarEventCompose_FrequencyDay": "day",
|
||||
"CalendarEventCompose_FrequencyDayPlural": "days",
|
||||
"CalendarEventCompose_FrequencyMonth": "month",
|
||||
"CalendarEventCompose_FrequencyMonthPlural": "months",
|
||||
"CalendarEventCompose_FrequencyWeek": "week",
|
||||
"CalendarEventCompose_FrequencyWeekPlural": "weeks",
|
||||
"CalendarEventCompose_FrequencyYear": "year",
|
||||
"CalendarEventCompose_FrequencyYearPlural": "years",
|
||||
"CalendarEventCompose_Location": "Location",
|
||||
"CalendarEventCompose_LocationPlaceholder": "Add a location",
|
||||
"CalendarEventCompose_NewEventButton": "New Event",
|
||||
"CalendarEventCompose_NoCalendarsMessage": "There are no calendars available for event creation yet.",
|
||||
"CalendarEventCompose_NoCalendarsTitle": "No calendars available",
|
||||
"CalendarEventCompose_NoEndDate": "No end date",
|
||||
"CalendarEventCompose_Notes": "Notes",
|
||||
"CalendarEventCompose_PickCalendarTitle": "Pick a calendar",
|
||||
"CalendarEventCompose_Recurring": "Recurring",
|
||||
"CalendarEventCompose_RecurringSummary": "Occurs every {0} {1}{2} {3} effective {4}{5}",
|
||||
"CalendarEventCompose_RepeatEvery": "Repeat every",
|
||||
"CalendarEventCompose_SelectCalendar": "Select calendar",
|
||||
"CalendarEventCompose_SingleOccurrenceSummary": "Occurs on {0} {1}",
|
||||
"CalendarEventCompose_StartDate": "Start date",
|
||||
"CalendarEventCompose_StartTime": "Start time",
|
||||
"CalendarEventCompose_TimeRangeSummary": "from {0} to {1}",
|
||||
"CalendarEventCompose_Title": "Event title",
|
||||
"CalendarEventCompose_TitlePlaceholder": "Add a title",
|
||||
"CalendarEventCompose_Until": "until",
|
||||
"CalendarEventCompose_UntilSummary": " until {0}",
|
||||
"CalendarEventCompose_ValidationInvalidAllDayRange": "The all-day end date must be after the start date.",
|
||||
"CalendarEventCompose_ValidationInvalidAttendee": "One or more attendees have an invalid email address.",
|
||||
"CalendarEventCompose_ValidationInvalidRecurrenceEnd": "The recurrence end date must be on or after the event start date.",
|
||||
"CalendarEventCompose_ValidationInvalidTimeRange": "The end time must be later than the start time.",
|
||||
"CalendarEventCompose_ValidationMissingAttachment": "One or more attachments are no longer available: {0}",
|
||||
"CalendarEventCompose_ValidationMissingCalendar": "Select a calendar before creating the event.",
|
||||
"CalendarEventCompose_ValidationMissingTitle": "Enter an event title before creating the event.",
|
||||
"CalendarEventCompose_ValidationTitle": "Event validation failed",
|
||||
"CalendarEventCompose_WeekdaySummary": " on {0}",
|
||||
"CalendarEventCompose_Weekday_Friday": "F",
|
||||
"CalendarEventCompose_Weekday_Monday": "M",
|
||||
"CalendarEventCompose_Weekday_Saturday": "S",
|
||||
"CalendarEventCompose_Weekday_Sunday": "S",
|
||||
"CalendarEventCompose_Weekday_Thursday": "T",
|
||||
"CalendarEventCompose_Weekday_Tuesday": "T",
|
||||
"CalendarEventCompose_Weekday_Wednesday": "W",
|
||||
"CalendarEventDetails_Details": "Details",
|
||||
"CalendarEventDetails_EditSeries": "Edit Series",
|
||||
"CalendarEventDetails_Editing": "Editing",
|
||||
|
||||
Reference in New Issue
Block a user