Commit Graph
69 Commits
Author SHA1 Message Date
Linus Rath 71aaadef50 fix: run plugins' compose check in quick compose, keep a composer with one owner, and bring it back after a crash
The first version of quick compose skipped `onBeforeCompose`, a composer
moved back could end up open in both windows, a reply moved back under
Pro flagged the selected message, and a crashed pop-out came back blank.

- A new message in a pop-out runs `onBeforeCompose` with the same result
  as the main window: a plugin that stops it closes the window.
- The way back has two steps, so a pop-out that gave up can't leave a
  second owner. A handoff behind a plugin's gate makes it say busy.
- A Pro tab made from a composer moved back answers its own message.
- Each save writes `draft`, `account` and `owner` into the pop-out's
  address, which a reload after a crash starts from. What was typed since
  the last save, up to the 2 s autosave delay, is still lost.
- The recorder refuses keys that type a character on this keyboard, and
  what the shell refuses from a page, and says why.
2026-11-04 01:31:43 +01:00
Linus Rath 529d334496 Merge branch 'fix/ui-bug-hunt' 2026-11-03 19:44:46 +01:00
Linus Rath d09e400d04 fix: keep the tab bar on the mail list on a phone held sideways, hiding it only over what fills the window 2026-11-03 16:11:16 +01:00
Linus Rath f51d6ac9ac fix: let c compose from any Pro tab again except Calendar, whose c is New event 2026-11-03 15:55:06 +01:00
Linus Rath c1e0e5e340 fix: stop a Mountain View list cursor marking the row under it as read 2026-11-03 15:36:55 +01:00
Linus Rath 404d1acdc6 fix: stop an old message reopening by itself on a phone and keep a Mountain View cursor closed when the window narrows 2026-11-03 15:33:35 +01:00
Linus Rath cc9aa64eb7 fix: flag the mail a reply answers when it crosses between a Pro tab and the standard composer 2026-11-03 14:57:35 +01:00
Linus Rath fcfae58a70 fix: keep the open message when / focuses Mountain View's search field in the top bar 2026-11-03 14:47:08 +01:00
Linus Rath 0f799454e4 fix: keep text typed after a clean Mountain View composer move and ask before dropping handed-over edits 2026-11-03 14:42:41 +01:00
Linus Rath 4d244aad0a fix: stop mail keys acting on the hidden mail tab from other Pro tabs 2026-11-03 13:49:01 +01:00
Linus Rath 4f4660723e fix: close the phone and tablet drawer when something in it opens a composer 2026-11-03 13:47:44 +01:00
Linus Rath 4ccec4c850 test: drop an unused import from the composer move test 2026-11-03 08:30:13 +01:00
Linus Rath 3ccb2582c2 fix: keep typed text when the Mountain View composer moves between window, card and pane 2026-11-03 08:22:32 +01:00
Linus Rath 590edb943f fix: keep an open composer or message in view when the window narrows to phone size 2026-11-03 06:58:03 +01:00
Linus Rath 51c09a1a69 fix: never let a notification's buttons go round plugins, session limits or Trash
Review of the notification actions. With a plugin that may stop a move
or read change, or a silent tab holding the login, the message now
opens instead of the route acting. The route answers 401 under a
session limit, and neither path touches a message since moved to Trash
or Junk. A tab that thawed declines an old click, Archive follows the
gate of the notification's login and files into a shared-out Archive
as the app's button does, Reply opens a composer in the Pro shell, the
route retries once when another client made the folder first and
leaves no empty folder behind, and logins match however the server
address is written.

Two assertions of this feature's own tests change: the route answers
401, not 403, when a login's scopes can't be worked out, since that now
also covers session limits; a tab's message to the page now carries
`at`.

The Pro shell's mail surface now reads a parked link's query from the
handoff: the address bar may have none by its first render, which lost
`?slot=` and `?owner=` there too.
2026-11-03 06:28:04 +01:00
Linus Rath b0f540f482 fix: show the results after a filter search on a phone and dim the compose button behind the drawer 2026-11-03 05:42:36 +01:00
Linus Rath 64184d23f8 fix: keep Tab and the / shortcut out of a message list hidden by the open message 2026-11-03 05:26:39 +01:00
Linus Rath 45c1d9b3d6 Merge pull request #1499 from Schrobo/fix/shared-mailbox-push-target 2026-11-02 20:23:56 +01:00
Linus Rath 0c421f5557 test: cover opening the shared inbox from a grouped notification #1499 2026-11-02 20:15:33 +01:00
Szymon Chroboczek 62906e45dc fix: preserve mailbox owner in push notification links 2026-11-02 12:47:44 +01:00
Linus Rath 3b99ce26ae feat: draw the reader's toolbar and a phone's conversation view while a linked message loads 2026-11-01 19:52:36 +01:00
Linus Rath cdf661d320 feat: keep the mail skeleton's shapes until the folders, list and linked message arrive 2026-11-01 19:40:20 +01:00
Linus Rath e80f5ade81 feat: let admins turn off downloads, export, printing and the install prompt, and add a watermark
Organisation > Devices now sets policy.json `organisation.devices`, each
switch off by default and scoped per domain or group:

- No downloads: attachments and files only preview (reader, conversation
  view, Pro tab, list chips, .eml previews, the Files app). Download,
  Download all, Open in new tab, Save to Files, drag-out, the browser's
  PDF viewer (pdf.js instead) and media download controls go away.
- No export: no .eml export, View source, message drag-out, or folder and
  account export; a running export stops and its file is deleted when
  the switch turns on. Import stays.
- No printing: no Print buttons in mail, calendar and contacts; Ctrl+P
  prints a note; the reader frame prints blank.
- No install prompt: no card, and the browser's own banner is held back.
- Watermark: the user's address and the date over the reader,
  previews and every printout (mail, calendar, contacts, plugins).

A message follows its own account's policy; what isn't about one message
follows the strictest signed-in account. Every user path hides its
button, and the anchor and new-tab helpers refuse as a backstop
(lib/download-guard.ts), never the blob readers. The plugin APIs
`ui.downloadFile` and `ui.print` refuse too, and the office editor frame
loses `allow-downloads`.

Two assertions in components/mail/__tests__/blob-routing.test.tsx now
expect `{ kind: 'export' }` as the fifth argument of downloadBlob for an
.eml export: the export says what it is, so the backstop checks "No
export" rather than "No downloads" for it.
2026-11-01 08:52:34 +01:00
Linus Rath 391f22cf7d test: open attachments through the bar's tile button in the blob routing tests 2026-11-01 00:51:10 +01:00
Linus Rath b8223a4492 Merge pull request #1466 from HOLOEYE-JZ/feat/plugin-open-email
feat(plugins): api.ui.openEmail opens a message in the reader
2026-10-31 16:25:05 +01:00
Linus Rath e5ed50dc92 Merge pull request #1467 from HOLOEYE-JZ/feat/plugin-hooks-account-and-composer
feat(plugins): star and after-send hooks name the mail's account
2026-10-31 16:25:00 +01:00
Linus Rath a0da9eb6c2 fix: show the results when searching with a message open in mountain view #1468 2026-10-31 16:15:57 +01:00
Jacob Zeitz d5cd3c6e40 feat(plugins): star and after-send hooks name the mail's account
Message ids repeat across accounts, so a hook payload naming only an
emailId could not tell a plugin which mailbox the message lies in when
it is a shared or group account's.

onBeforeEmailStarToggle and onEmailStarToggle now carry accountId when
the starred message is not in the user's own account, as the
message-row-actions click context does. Every star (the row's button,
the reader's star, the key, the menu) goes through toggleStar, one
message at a time, so one accountId names it; the account is resolved
before the plugins are asked. An own message's payload is unchanged.

onAfterEmailSend now carries accountId, the JMAP account the sent
message lies in (a mail sent from a shared or group identity lies in
that account), so api.email.get finds it. sendEmail returns that account
as emailAccountId, the S/MIME send too. The hook also carries
composerId, the id the sending composer's slots and actions gave
plugins, so a plugin can act on what the user chose in that composer.
2026-10-31 14:15:06 +01:00
Jacob Zeitz 54ad6390b3 feat(plugins): api.ui.openEmail opens a message in the reader
A plugin opens a message as a click on a list row or on a search result
entry naming one does, also a message of a shared or group account,
reached through the login that reads it. On the mail page it opens in
place, in the Pro shell in an email tab as a message link does there;
elsewhere the tab loads the message's link, at most five times a minute.
A message no login reads, or one its account does not have, is refused
with an error the plugin sees, as is one the mail page could not open.
Needs email:read.
2026-10-31 14:14:48 +01:00
Linus Rath 9af0304616 fix: return to the list after moving or reporting the open message as spam #1458 2026-10-31 01:03:08 +01:00
Linus Rath 3406580a3f fix: return to the list after archiving the open message #1458 2026-10-31 00:56:03 +01:00
Linus Rath ed988a2aae ci: keep the a11y guard out of lint and vitest and mock narrowerThan in attachment tests 2026-10-29 21:08:59 +01:00
Linus Rath b4483b8739 test: give the mail app tests the category tab panel props 2026-10-29 18:03:01 +01:00
Linus Rath 863806fc65 fix: translate system folder names in the advanced search folder list #1429 2026-10-29 14:24:07 +01:00
Linus Rath 4406a6435e Merge pull request #1426 from VasilisNtovolos/fix/attachment-download-error-feedback 2026-10-29 14:10:42 +01:00
Linus Rath 764ee97692 test: bring the main test suite back to green after the vitest 5 upgrade and header rework 2026-10-29 14:07:40 +01:00
VasilisNtovolos 35064316ad fix: show errors when attachment downloads fail 2026-10-29 13:19:29 +02:00
Linus Rath 96797597c5 Merge branch 'main' into feat/org-features 2026-10-28 15:14:34 +01:00
Linus Rath 2bb63f648b fix: keep the phone conversation's reply buttons readable and count its messages with each language's plural forms 2026-10-28 12:46:18 +01:00
Linus Rath 8597858865 fix: bring mail back to its list after the tour on phones instead of an empty reading pane 2026-10-28 12:34:27 +01:00
Linus Rath e654eadd37 Merge branch 'main' into ux/mail3 2026-10-28 11:10:56 +01:00
Linus Rath 768f3fe19b fix: make Undo after Report spam put the message back and say Moved back, and name the Spam folder as the sidebar shows it 2026-10-28 10:40:17 +01:00
Linus Rath f1c209beaa fix: name the account or parent folder in the palette's go to folder entries 2026-10-28 10:26:55 +01:00
Linus Rath 9304557819 fix: look up another signed-in account for the external mail checks only when an admin turned them on 2026-10-28 08:07:55 +01:00
Linus Rath af6deee047 feat: add Mail's commands to the command palette: reply, archive, delete, move, read state, spam and go to a folder 2026-10-28 05:27:17 +01:00
Linus Rath 6c5aead20b feat: undo a delete to Trash, archive, move, spam report or remove from folder from its toast 2026-10-28 03:11:43 +01:00
Linus Rath 7a93b0e6c8 fix: follow the Delete action setting when deleting a message, and delete for good when it says so 2026-10-28 02:37:18 +01:00
Linus Rath 272fc5e1f4 fix: reuse a group account's year and month archive folders instead of creating them again or in the own account 2026-10-26 16:14:19 +01:00
Linus Rath 34ad859ce4 fix: refuse Undo and Send now for a delayed send of a signed-out account instead of acting through the active one 2026-10-26 16:11:53 +01:00
Linus Rath 54b197080c fix: keep a discarded draft of a signed-out account instead of deleting another account's message with its id 2026-10-26 16:11:52 +01:00