@bobfrankston/rmfmail 1.0.697 → 1.0.699
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/client/app.bundle.js +16 -3
- package/client/app.bundle.js.map +2 -2
- package/client/components/message-list.ts +15 -4
- package/client/components/message-viewer.js +32 -3
- package/client/components/message-viewer.js.map +1 -1
- package/client/components/message-viewer.ts +29 -3
- package/package.json +5 -5
- package/packages/mailx-imap/index.d.ts.map +1 -1
- package/packages/mailx-imap/index.js +158 -16
- package/packages/mailx-imap/index.js.map +1 -1
- package/packages/mailx-imap/index.ts +162 -16
- package/packages/mailx-imap/package-lock.json +2 -2
- package/packages/mailx-imap/package.json +1 -1
- package/packages/mailx-service/index.d.ts.map +1 -1
- package/packages/mailx-service/index.js +26 -11
- package/packages/mailx-service/index.js.map +1 -1
- package/packages/mailx-service/index.ts +25 -9
- package/packages/mailx-store/db.d.ts +38 -7
- package/packages/mailx-store/db.d.ts.map +1 -1
- package/packages/mailx-store/db.js +96 -8
- package/packages/mailx-store/db.js.map +1 -1
- package/packages/mailx-store/db.ts +104 -8
- package/packages/mailx-store/package.json +1 -1
- package/packages/mailx-store/parse-serial.d.ts +4 -3
- package/packages/mailx-store/parse-serial.d.ts.map +1 -1
- package/packages/mailx-store/parse-serial.js +37 -7
- package/packages/mailx-store/parse-serial.js.map +1 -1
- package/packages/mailx-store/parse-serial.ts +48 -7
- package/packages/mailx-imap/node_modules.npmglobalize-stash-43676/.package-lock.json +0 -116
package/client/app.bundle.js
CHANGED
|
@@ -1198,15 +1198,28 @@ async function showMessage(accountId, uid, folderId, specialUse, isRetry = false
|
|
|
1198
1198
|
const m = mailUrl.match(/^mailto:([^?]*)(?:\?(.*))?$/i);
|
|
1199
1199
|
const to = m?.[1] ? decodeURIComponent(m[1]) : "";
|
|
1200
1200
|
const qs = new URLSearchParams(m?.[2] || "");
|
|
1201
|
-
const
|
|
1202
|
-
const
|
|
1201
|
+
const origFrom = msg.from ? msg.from.name ? `${msg.from.name} <${msg.from.address}>` : msg.from.address : "";
|
|
1202
|
+
const origSubject = msg.subject || "";
|
|
1203
|
+
const origDate = msg.date ? new Date(msg.date).toLocaleString(void 0, { year: "numeric", month: "short", day: "numeric", hour: "2-digit", minute: "2-digit", hour12: false }) : "";
|
|
1204
|
+
const subject = qs.get("subject") || (origSubject ? `Unsubscribe: ${origSubject}` : "Unsubscribe");
|
|
1205
|
+
const inlineBody = qs.get("body") || "";
|
|
1206
|
+
const escape = (s) => s.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">");
|
|
1207
|
+
const contextLines = [];
|
|
1208
|
+
if (origFrom)
|
|
1209
|
+
contextLines.push(`From: ${escape(origFrom)}`);
|
|
1210
|
+
if (origSubject)
|
|
1211
|
+
contextLines.push(`Subject: ${escape(origSubject)}`);
|
|
1212
|
+
if (origDate)
|
|
1213
|
+
contextLines.push(`Date: ${escape(origDate)}`);
|
|
1214
|
+
const contextBlock = contextLines.length ? `<p>\u2014<br>${contextLines.join("<br>")}</p>` : "";
|
|
1215
|
+
const bodyHtml = inlineBody ? `<p>${escape(inlineBody)}</p>${contextBlock}` : `<p>Please unsubscribe me from this list.</p>${contextBlock}`;
|
|
1203
1216
|
const init = {
|
|
1204
1217
|
mode: "new",
|
|
1205
1218
|
accountId: currentAccountId,
|
|
1206
1219
|
to: to ? [{ name: "", address: to }] : [],
|
|
1207
1220
|
cc: [],
|
|
1208
1221
|
subject,
|
|
1209
|
-
bodyHtml
|
|
1222
|
+
bodyHtml,
|
|
1210
1223
|
inReplyTo: "",
|
|
1211
1224
|
references: [],
|
|
1212
1225
|
accounts: []
|