@bobfrankston/rmfmail 1.2.12 → 1.2.14
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 +21 -16
- package/client/app.bundle.js.map +2 -2
- package/client/app.js +33 -20
- package/client/app.js.map +1 -1
- package/client/app.ts +31 -18
- package/package.json +3 -3
package/client/app.ts
CHANGED
|
@@ -1472,21 +1472,17 @@ async function deleteSelectedMessages(): Promise<void> {
|
|
|
1472
1472
|
// confirms (even a single message) and can't be undone (Bob 2026-06-12).
|
|
1473
1473
|
const inTrash = currentFolderSpecialUse === "trash";
|
|
1474
1474
|
|
|
1475
|
-
// SAFETY GATE.
|
|
1476
|
-
// - In Trash:
|
|
1477
|
-
// - Elsewhere:
|
|
1478
|
-
//
|
|
1479
|
-
//
|
|
1480
|
-
//
|
|
1475
|
+
// SAFETY GATE — only for the IRREVERSIBLE action.
|
|
1476
|
+
// - In Trash: delete is permanent → confirm (Bob explicitly wanted this).
|
|
1477
|
+
// - Elsewhere: move to Trash with NO prompt, single or bulk. It's
|
|
1478
|
+
// undoable (Ctrl+Z restores the whole batch) and matches Outlook /
|
|
1479
|
+
// Thunderbird, which don't nag on a move-to-trash. Bob 2026-06-15:
|
|
1480
|
+
// "stop giving me the trash warning message. It is annoying."
|
|
1481
1481
|
const n = selected.length;
|
|
1482
1482
|
if (inTrash) {
|
|
1483
1483
|
if (!confirm(`Permanently delete ${n} message${n === 1 ? "" : "s"} from Trash?\n\nThis cannot be undone.`)) {
|
|
1484
1484
|
return;
|
|
1485
1485
|
}
|
|
1486
|
-
} else if (n > 1) {
|
|
1487
|
-
if (!confirm(`Move ${n} messages to Trash?\n\n(Ctrl+Z restores them if this was a mistake.)`)) {
|
|
1488
|
-
return;
|
|
1489
|
-
}
|
|
1490
1486
|
}
|
|
1491
1487
|
|
|
1492
1488
|
const statusSync = document.getElementById("status-sync");
|
|
@@ -3433,16 +3429,33 @@ document.addEventListener("keydown", (e) => {
|
|
|
3433
3429
|
// Bare R yields to text inputs; Ctrl+Q overrides them so it's reachable
|
|
3434
3430
|
// from the search box or compose draft list.
|
|
3435
3431
|
if (!e.ctrlKey && inText) return;
|
|
3432
|
+
e.preventDefault();
|
|
3433
|
+
const applySeen = (m: NonNullable<ReturnType<typeof getCurrentFocused>>, seen: boolean): void => {
|
|
3434
|
+
setSeen(m, seen);
|
|
3435
|
+
updateFlags(m.accountId, m.uid, m.flags).then(() => {
|
|
3436
|
+
messageState.updateMessageFlags(m.accountId, m.uid, m.flags);
|
|
3437
|
+
const row = document.querySelector(`.ml-row[data-uid="${m.uid}"][data-account-id="${CSS.escape(m.accountId)}"]`) as HTMLElement | null;
|
|
3438
|
+
if (row) row.classList.toggle("unread", !seen);
|
|
3439
|
+
}).catch(() => { setSeen(m, !seen); });
|
|
3440
|
+
};
|
|
3441
|
+
// getSelectedMessages returns only id tuples — resolve to the full
|
|
3442
|
+
// message objects (with flags) from the list state.
|
|
3443
|
+
const selectedIds = getSelectedMessages();
|
|
3444
|
+
if (selectedIds.length > 1) {
|
|
3445
|
+
// Multi-select → mark every selected message READ (not a toggle):
|
|
3446
|
+
// a triage sweep is "I've dealt with these," not "flip each one"
|
|
3447
|
+
// (Bob 2026-06-15). Skip those already read.
|
|
3448
|
+
const all = messageState.getMessages();
|
|
3449
|
+
for (const id of selectedIds) {
|
|
3450
|
+
const m = all.find(x => x.accountId === id.accountId && x.uid === id.uid && x.folderId === id.folderId);
|
|
3451
|
+
if (m && !seenOf(m)) applySeen(m, true);
|
|
3452
|
+
}
|
|
3453
|
+
return;
|
|
3454
|
+
}
|
|
3455
|
+
// Single → toggle read/unread.
|
|
3436
3456
|
const sel = getCurrentFocused();
|
|
3437
3457
|
if (!sel) return;
|
|
3438
|
-
|
|
3439
|
-
const wasSeen = seenOf(sel);
|
|
3440
|
-
setSeen(sel, !wasSeen);
|
|
3441
|
-
updateFlags(sel.accountId, sel.uid, sel.flags).then(() => {
|
|
3442
|
-
messageState.updateMessageFlags(sel.accountId, sel.uid, sel.flags);
|
|
3443
|
-
const row = document.querySelector(`.ml-row[data-uid="${sel.uid}"][data-account-id="${sel.accountId}"]`) as HTMLElement;
|
|
3444
|
-
if (row) row.classList.toggle("unread", wasSeen);
|
|
3445
|
-
}).catch(() => { setSeen(sel, wasSeen); });
|
|
3458
|
+
applySeen(sel, !seenOf(sel));
|
|
3446
3459
|
}
|
|
3447
3460
|
// Z = locate the focused row in the list (scroll-to-selected). After
|
|
3448
3461
|
// scrolling the list out of sync with the preview, this snaps back.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bobfrankston/rmfmail",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.14",
|
|
4
4
|
"description": "Local-first email client with IMAP sync and standalone native app",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "bin/mailx.js",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"dependencies": {
|
|
39
39
|
"@bobfrankston/iflow-direct": "^0.1.53",
|
|
40
40
|
"@bobfrankston/mailx-host": "^0.1.13",
|
|
41
|
-
"@bobfrankston/mailx-imap": "^0.1.
|
|
41
|
+
"@bobfrankston/mailx-imap": "^0.1.96",
|
|
42
42
|
"@bobfrankston/mailx-store-web": "^0.1.27",
|
|
43
43
|
"@bobfrankston/mailx-sync": "^0.1.22",
|
|
44
44
|
"@bobfrankston/miscinfo": "^1.0.13",
|
|
@@ -118,7 +118,7 @@
|
|
|
118
118
|
"dependencies": {
|
|
119
119
|
"@bobfrankston/iflow-direct": "^0.1.53",
|
|
120
120
|
"@bobfrankston/mailx-host": "^0.1.13",
|
|
121
|
-
"@bobfrankston/mailx-imap": "^0.1.
|
|
121
|
+
"@bobfrankston/mailx-imap": "^0.1.96",
|
|
122
122
|
"@bobfrankston/mailx-store-web": "^0.1.27",
|
|
123
123
|
"@bobfrankston/mailx-sync": "^0.1.22",
|
|
124
124
|
"@bobfrankston/miscinfo": "^1.0.13",
|