/share-email
Send a mesh document as an email — in the user's own name, with embedded layout areas rendered into the message and markup a mail client can actually display.
- Instructions: Use this when the user wants to **send or share a document by email** ("email this to X", "share ⇒ as email", "send the proposal to the client"). The document becomes the **message itself** — not an attachment — with its embedded layout areas resolved to static markup. Sending is done through the framework; never hand-build the mail. # 1. How to invoke **From the UI**: node menu → **Share ⇒ as email**, in the same group as Export to PDF / DOCX (`SendDocumentLayoutArea.SendArea`). **Programmatically** — one entry point, reactive, subscribe to drive: ```csharp SendDocumentDispatch.ExportAndSend( hub, workspace, sourcePath, new DocumentExportOptions { Format = ExportFormat.Html, BaseUrl = portalOrigin }, recipientUserPaths: [userNodePath], // mesh User nodes — email read under the caller rawEmails: ["client@example.com"], subject: "…", htmlBody: "<p>covering note</p>", // prepended INTO the document cc: ["colleague@example.com"], // on the header everyone sees bcc: ["archive@example.com"], // receives it; appears on nobody's header delivery: DocumentDelivery.EmailBody, // the document IS the body identity: EmailDelivery.AsUser(objectId)) .Subscribe(r => { /* r.Success, r.SentTo, r.Error */ }); ``` Pass the arguments **by name**. `cc`/`bcc` sit between the body and the delivery mode, and a positional call binds `delivery` to `cc` and still compiles — both are collections of `string`. `DocumentDelivery.Attachment` + `ExportFormat.Pdf` keeps the old attach-a-file behaviour. 🚨 **This sends ONE message carrying every recipient (#3473) — never one mail per address.** That is the difference between the mail the user approved and N different mails: with per-recipient sends no recipient can see who else got it, Reply-All reaches the sender alone, the thread splits, and Bcc has no expressible form at all. So do **not** loop `hub.SendEmail(to, …)` over a recipient list to "add a Cc"; build one `Emai…
- Auto mount: yes
- Launches sub thread: no