Interface: EmailComposeProps
Props for EmailComposeView.
Properties
Section titled “Properties”allowAttachments?
Section titled “allowAttachments?”
optionalallowAttachments?:boolean
Show the attachment control. Defaults to true.
defaultFrom?
Section titled “defaultFrom?”
optionaldefaultFrom?:string
Preselected From. Defaults to the first senders entry.
defaultValue?
Section titled “defaultValue?”
optionaldefaultValue?:Partial<{attachments?:object[];bcc?:string[];body:string;cc?:string[];subject:string;to:string[]; }>
Initial draft to seed the form (uncontrolled thereafter).
disabled?
Section titled “disabled?”
optionaldisabled?:boolean
Disable all actions regardless of pending state.
onCancel?
Section titled “onCancel?”
optionalonCancel?: () =>void
Called when the user cancels. Omit to hide the Cancel button.
Returns
Section titled “Returns”void
onChange?
Section titled “onChange?”
optionalonChange?: (message) =>void
Called on every edit with the current assembled message.
Parameters
Section titled “Parameters”message
Section titled “message”attachments?
Section titled “attachments?”object[] = ...
string[] = ...
string = ...
string[] = ...
subject
Section titled “subject”string = ...
string[] = ...
Returns
Section titled “Returns”void
onSend?
Section titled “onSend?”
optionalonSend?: (message,from?) =>void|Promise<void>
Called when the user submits; receives the message and chosen From.
Parameters
Section titled “Parameters”message
Section titled “message”attachments?
Section titled “attachments?”object[] = ...
string[] = ...
string = ...
string[] = ...
subject
Section titled “subject”string = ...
string[] = ...
string
Returns
Section titled “Returns”void | Promise<void>
pending?
Section titled “pending?”
optionalpending?:boolean
Disable actions while a send is in flight.
senders?
Section titled “senders?”
optionalsenders?:string[]
Permitted From addresses (e.g. from the plugin’s GET /senders).
When non-empty a From dropdown is shown and its value is passed to
onSend; omit for a server-resolved sender (no dropdown).
sendLabel?
Section titled “sendLabel?”
optionalsendLabel?:string
Submit button label. Defaults to “Send”.
title?
Section titled “title?”
optionaltitle?:string
Card header label. Defaults to “New message”.