fix: prompt to create or pick folder when archive is missing (#286) #290

Merged
guettlibot merged 2 commits from issue-286-fix into main 2026-05-27 17:06:40 +00:00
guettlibot commented 2026-05-27 17:01:46 +00:00 (Migrated from codeberg.org)

Summary

  • When archiving selected emails and no archive folder is found, show a dialog asking the user to either choose an existing folder or create a new Archive folder
  • When creating, the JMAP role: archive is sent to the server and the role is stored in the local DB; for IMAP the folder is created and tagged in the local DB
  • Preserve manually-set roles across IMAP syncs: if the IMAP server doesn't expose a \Archive special-use attribute, the locally-assigned role is retained between syncs
  • Same dialog is shown for the spam/junk case

Test plan

  • Unit tests: createMailboxWithRole (IMAP + JMAP), role-preservation across sync
  • Widget tests: dialog shown when archive missing, Create path, Choose existing path
  • All 472 tests pass, no analyzer warnings

🤖 Generated with Claude Code

## Summary - When archiving selected emails and no archive folder is found, show a dialog asking the user to either choose an existing folder or create a new `Archive` folder - When creating, the JMAP `role: archive` is sent to the server and the role is stored in the local DB; for IMAP the folder is created and tagged in the local DB - Preserve manually-set roles across IMAP syncs: if the IMAP server doesn't expose a `\Archive` special-use attribute, the locally-assigned role is retained between syncs - Same dialog is shown for the spam/junk case ## Test plan - [ ] Unit tests: `createMailboxWithRole` (IMAP + JMAP), role-preservation across sync - [ ] Widget tests: dialog shown when archive missing, Create path, Choose existing path - All 472 tests pass, no analyzer warnings 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Sign in to join this conversation.