@bobfrankston/rmfmail 1.1.96 → 1.1.98
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/.commitmsg +6 -14
- package/client/app.bundle.js +4 -1
- package/client/app.bundle.js.map +2 -2
- package/client/app.js +10 -1
- package/client/app.js.map +1 -1
- package/client/app.ts +9 -1
- package/client/compose/compose.bundle.js +15 -7
- package/client/compose/compose.bundle.js.map +2 -2
- package/client/compose/compose.js +21 -13
- package/client/compose/compose.js.map +1 -1
- package/client/compose/compose.ts +20 -12
- package/client/lib/rmf-tiny.js +9 -0
- package/docs/rmf-tiny.md +31 -2
- package/npmchanges.md +36 -0
- package/package.json +3 -3
- /package/packages/mailx-imap/{node_modules.npmglobalize-stash-89052 → node_modules.npmglobalize-stash-82308}/.package-lock.json +0 -0
package/client/app.ts
CHANGED
|
@@ -2885,8 +2885,16 @@ document.addEventListener("keydown", (e) => {
|
|
|
2885
2885
|
}
|
|
2886
2886
|
// Ctrl+A = Select all visible messages
|
|
2887
2887
|
if (e.ctrlKey && e.key === "a") {
|
|
2888
|
+
const t = e.target as HTMLElement | null;
|
|
2889
|
+
const tag = t?.tagName;
|
|
2890
|
+
// In a text field / editor, Ctrl+A means "select the text" — never
|
|
2891
|
+
// hijack it to select-all-messages. The old guard's `.closest(...,
|
|
2892
|
+
// body)` always matched (everything is inside <body>), so Ctrl+A in
|
|
2893
|
+
// the search box selected every message instead of the box's text,
|
|
2894
|
+
// and the field couldn't be selected+cleared (Bob 2026-05-18).
|
|
2895
|
+
if (tag === "INPUT" || tag === "TEXTAREA" || tag === "SELECT" || t?.isContentEditable) return;
|
|
2888
2896
|
const mlBody = document.getElementById("ml-body");
|
|
2889
|
-
if (mlBody
|
|
2897
|
+
if (mlBody) {
|
|
2890
2898
|
e.preventDefault();
|
|
2891
2899
|
mlBody.querySelectorAll(".ml-row").forEach(r => r.classList.add("selected"));
|
|
2892
2900
|
}
|
|
@@ -831,6 +831,10 @@ async function createTinyMceEditor(container2, opts = {}) {
|
|
|
831
831
|
/* true = start */
|
|
832
832
|
);
|
|
833
833
|
editor2.focus();
|
|
834
|
+
if (pos === 0)
|
|
835
|
+
editor2.getWin()?.scrollTo(0, 0);
|
|
836
|
+
else
|
|
837
|
+
editor2.selection.scrollIntoView();
|
|
834
838
|
} catch {
|
|
835
839
|
}
|
|
836
840
|
},
|
|
@@ -4002,14 +4006,18 @@ function applyInit(init) {
|
|
|
4002
4006
|
(_match, attrs, inner) => `<pre${attrs}>${inner.replace(/\r\n|\r|\n/g, "<br>")}</pre>`
|
|
4003
4007
|
);
|
|
4004
4008
|
const acct = init.accounts.find((a) => a.id === init.accountId);
|
|
4005
|
-
const isNew = init.mode !== "reply" && init.mode !== "replyAll" && init.mode !== "forward" && init.mode !== "draft" && !init.draftUid;
|
|
4006
4009
|
const isReplyForward = init.mode === "reply" || init.mode === "replyAll" || init.mode === "forward";
|
|
4007
|
-
if (
|
|
4008
|
-
|
|
4009
|
-
|
|
4010
|
-
|
|
4011
|
-
|
|
4012
|
-
|
|
4010
|
+
if (init.mode !== "draft" && !init.draftUid) {
|
|
4011
|
+
let sigHtml = "";
|
|
4012
|
+
if (acct?.sig?.text) {
|
|
4013
|
+
sigHtml = acct.sig.html ? acct.sig.text : escapeHtml(acct.sig.text).replace(/\n/g, "<br>");
|
|
4014
|
+
} else if (acct?.signature) {
|
|
4015
|
+
sigHtml = acct.signature;
|
|
4016
|
+
}
|
|
4017
|
+
if (sigHtml) {
|
|
4018
|
+
const sigBlock = `<br><br>-- <br>${sigHtml}`;
|
|
4019
|
+
bodyToRender = isReplyForward ? `<br>${sigBlock}<br>${bodyToRender}` : `${bodyToRender}${sigBlock}`;
|
|
4020
|
+
}
|
|
4013
4021
|
}
|
|
4014
4022
|
if (bodyToRender) {
|
|
4015
4023
|
editor.setHtml(bodyToRender);
|