Contacts, thread animation and image preview control improvements.

This commit is contained in:
Burak Kaan Köse
2026-02-09 22:39:30 +01:00
parent e559a79506
commit 0999c71578
26 changed files with 1636 additions and 756 deletions
@@ -3,6 +3,7 @@ using System.Linq;
using System.Threading.Tasks;
using MimeKit;
using Wino.Core.Domain.Entities.Shared;
using Wino.Core.Domain.Models.Contacts;
namespace Wino.Core.Domain.Interfaces;
@@ -11,11 +12,13 @@ public interface IContactService
Task<List<AccountContact>> GetAddressInformationAsync(string queryText);
Task<AccountContact> GetAddressInformationByAddressAsync(string address);
Task SaveAddressInformationAsync(MimeMessage message);
Task SaveAddressInformationAsync(IEnumerable<AccountContact> contacts);
Task<AccountContact> CreateNewContactAsync(string address, string displayName);
// New methods for ContactsPage
Task<List<AccountContact>> GetAllContactsAsync();
Task<List<AccountContact>> SearchContactsAsync(string searchQuery);
Task<PagedContactsResult> GetContactsPageAsync(int offset, int pageSize, string searchQuery = null, bool excludeRootContacts = false);
Task<AccountContact> UpdateContactAsync(AccountContact contact);
Task DeleteContactAsync(string address);
Task DeleteContactsAsync(IEnumerable<string> addresses);
@@ -0,0 +1,27 @@
using System;
using System.ComponentModel;
using Wino.Core.Domain.Entities.Shared;
namespace Wino.Core.Domain.Interfaces;
/// <summary>
/// Shared display contract for mail list item rendering.
/// Implemented by both single mail and thread mail view models.
/// </summary>
public interface IMailItemDisplayInformation : INotifyPropertyChanged
{
string Subject { get; }
string FromName { get; }
string FromAddress { get; }
string PreviewText { get; }
bool IsRead { get; }
bool IsDraft { get; }
bool HasAttachments { get; }
bool IsFlagged { get; }
DateTime CreationDate { get; }
string Base64ContactPicture { get; }
bool ThumbnailUpdatedEvent { get; }
bool IsBusy { get; }
bool IsThreadExpanded { get; }
AccountContact SenderContact { get; }
}
@@ -0,0 +1,11 @@
using System.Collections.Generic;
using Wino.Core.Domain.Entities.Shared;
namespace Wino.Core.Domain.Models.Contacts;
public record PagedContactsResult(
IReadOnlyList<AccountContact> Contacts,
int TotalCount,
bool HasMore,
int Offset,
int PageSize);
@@ -1,6 +1,12 @@
using MimeKit;
using System.Collections.Generic;
using MimeKit;
using Wino.Core.Domain.Entities.Mail;
using Wino.Core.Domain.Entities.Shared;
namespace Wino.Core.Domain.Models.MailItem;
public record NewMailItemPackage(MailCopy Copy, MimeMessage Mime, string AssignedRemoteFolderId);
public record NewMailItemPackage(
MailCopy Copy,
MimeMessage Mime,
string AssignedRemoteFolderId,
IReadOnlyList<AccountContact> ExtractedContacts = null);
@@ -137,13 +137,6 @@
"CalendarShowAs_Busy": "Busy",
"CalendarShowAs_OutOfOffice": "Out of Office",
"CalendarShowAs_WorkingElsewhere": "Working Elsewhere",
"CalendarEventResponse_Accept": "Accept",
"CalendarEventResponse_AcceptedResponse": "Accepted",
"CalendarEventResponse_Decline": "Decline",
"CalendarEventResponse_DeclinedResponse": "Declined",
"CalendarEventResponse_NotResponded": "Not Responded",
"CalendarEventResponse_Tentative": "Tentative",
"CalendarEventResponse_TentativeResponse": "Tentatively Accepted",
"CalendarItem_DetailsPopup_JoinOnline": "Join online",
"CalendarItem_DetailsPopup_ViewEventButton": "View event",
"CalendarItem_DetailsPopup_ViewSeriesButton": "View series",
@@ -153,6 +146,9 @@
"ClipboardTextCopied_Message": "{0} copied to clipboard.",
"ClipboardTextCopied_Title": "Copied",
"ClipboardTextCopyFailed_Message": "Failed to copy {0} to clipboard.",
"ContactInfoBar_ErrorTitle": "Failed to load contact information",
"ContactInfoBar_SuccessTitle": "Contact information loaded",
"ContactInfoBar_WarningTitle": "Contact information might be incomplete",
"ComingSoon": "Coming soon...",
"ComposerAttachmentsDragDropAttach_Message": "Attach",
"ComposerAttachmentsDropZone_Message": "Drop your files here",
@@ -833,6 +829,7 @@
"Smime_CertificatePassword_Placeholder": "Certificate password for {0} (optional)",
"Smime_Confirm_Title": "Confirm",
"Buttons_OK": "OK",
"Buttons_Refresh": "Refresh",
"SettingsSignatureAndEncryption_Title": "Signature and Encryption",
"SettingsSignatureAndEncryption_Description": "Manage S/MIME certificates for signing and encrypting emails.",
"SettingsSignatureAndEncryption_MyCertificatesHeader": "My certificates",
@@ -909,6 +906,22 @@
"ContactSelection_Clear": "Clear Selection",
"ContactsPage_EmptyState": "No contacts to display",
"ContactsPage_AddFirstContact": "Add your first contact",
"ContactsPage_ContactsCountSuffix": "contacts",
"ContactEditDialog_AddTitle": "Add Contact",
"ContactInfoBar_ContactAdded": "Contact added successfully.",
"ContactInfoBar_ContactUpdated": "Contact updated successfully.",
"ContactInfoBar_ContactsDeleted": "Contacts deleted successfully.",
"ContactInfoBar_ContactPhotoUpdated": "Contact photo updated successfully.",
"ContactInfoBar_FailedToLoadContacts": "Failed to load contacts: {0}",
"ContactInfoBar_FailedToAddContact": "Failed to add contact: {0}",
"ContactInfoBar_FailedToUpdateContact": "Failed to update contact: {0}",
"ContactInfoBar_FailedToDeleteContacts": "Failed to delete contacts: {0}",
"ContactInfoBar_FailedToUpdatePhoto": "Failed to update photo: {0}",
"ContactInfoBar_CannotDeleteRoot": "Root contacts cannot be deleted.",
"ContactConfirmDialog_DeleteTitle": "Delete Contact",
"ContactConfirmDialog_DeleteMessage": "Are you sure you want to delete the contact '{0}'?",
"ContactConfirmDialog_DeleteMultipleMessage": "Are you sure you want to delete {0} contact(s)?",
"ContactConfirmDialog_DeleteButton": "Delete",
"CalendarAccountSettings_Title": "Calendar Account Settings",
"CalendarAccountSettings_Description": "Manage calendar settings for {0}",
"CalendarAccountSettings_AccountColor": "Account Color",