Open Bug 1696646 Opened 5 years ago Updated 2 years ago

[Compose API] Expose template type in ComposeDetails as well

Categories

(Thunderbird :: Add-Ons: Extensions API, enhancement)

enhancement

Tracking

(Not tracked)

ASSIGNED

People

(Reporter: john, Assigned: john)

Details

(Whiteboard: [PrioESR128])

Attachments

(1 external file, 1 obsolete file)

In bug Bug 1677062 the types new, reply, forward and draft have been added. The template type seems to be useful as well.

No longer blocks: 1691253
No longer depends on: 1677062

Should the redirect type be added also?

redirect is used in the following add-ons:

https://github.com/thundernest/webext-docs/issues/51

Thank you

Add least my add-on (Simple Mail Redirection) never opens a message in a compose window. So there is no need to add a 'redirect' type.

I'm going for an experiment at the moment, but I think redirect as a message type might help for future development or integration in core.

Can the title please be updated from
[Compose API] Expose template type in ComposeDetails as well
to
[Compose API] Expose template and redirect types in ComposeDetails as well

Thank you

Flags: needinfo?(john)

We will add template and redirect as new types. This also means we have to support opening such compose windows.

The template type indicates that a mail is opened via "Edit Template" (this mode does not support sending an email, but just editing the template). So we need a dedicates function for that, aligned with our other functions this could be beginTemplate(), but in this case editTemplate() is probably a better choice. (beginNew() can already be used to create a new email from a template, a composer window opened that way will be of type "new").

For the redirect type, we currently do not support to trigger that from the UI, at least this is what Magnus told me. Magnus does want to allow using redirect from within Thunderbird in the future. How should we trigger a redirect from our WebExtension APIs? Suggestions:

  • beginRedirect(id, details)
  • beginForward(id, "forwardAsRedirect", details)

Or should we wait with implementing the redirect type until it is usable from within Thunderbird and we know if it is conceptionally added as a forward type or not?

Flags: needinfo?(john)

Probably needs its own function, but yes, may be good to see it in action within Thunderbird core first.

I haven't checked it myself, but I think Redirect is integrated in Postbox, so you might want to check out how they did it.
I think the redirect type can be most compared to forwardAsAttachments, only with different UI, because there's only the messages that you want to redirect and the addressing widget and no editor for the body. I would be happy to help or advise on implementing this in Thunderbird core though, and I think the over 50000 (known) active daily users would also like to see that.

The backend fully supports it, we just never hooked up a button or menu for it.
The history is that it got implemented for the Penelope project ("Eudora meets Thunderbird").

Assignee: nobody → john
Status: NEW → ASSIGNED
Attachment #9215757 - Attachment description: Bug 1696646 - Add support for template type to compose API. r=darktrojan → WIP: Bug 1696646 - Add support for template type to compose API. r=darktrojan
Attachment #9215757 - Attachment is obsolete: true
Whiteboard: webextension-api-request → [Prio2023]
Whiteboard: [Prio2023] → [PrioESR128]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: