@bobfrankston/rmfmail 1.2.300 → 1.2.301
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 +25 -37
- package/client/compose/compose.bundle.js +3 -3
- package/client/compose/compose.bundle.js.map +2 -2
- package/client/compose/compose.js +24 -6
- package/client/compose/compose.js.map +1 -1
- package/client/compose/compose.ts +22 -4
- package/npmchanges.md +44 -0
- package/package.json +5 -5
- /package/packages/mailx-imap/{node_modules.npmglobalize-stash-63828 → node_modules.npmglobalize-stash-69280}/.package-lock.json +0 -0
package/.commitmsg
CHANGED
|
@@ -1,41 +1,29 @@
|
|
|
1
|
-
|
|
1
|
+
Placing the caret in the body is the same act as taking focus
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
proved it sent this", and the "Stop warning about marketing@altishotels.com"
|
|
7
|
-
button underneath. What was wrong sat one element above: the score chip's
|
|
8
|
-
tooltip read "Scored by bulk-mail or blocklist rules; the sending domain passed
|
|
9
|
-
DMARC, so the sender is proved" — and then listed, on the next line of the same
|
|
10
|
-
tooltip, `3.2 KAM_ACCOUNTPHISH (Spam that tries to get account information)`,
|
|
11
|
-
which is 3.2 of the message's 8.3 and is neither a bulk-mail nor a blocklist
|
|
12
|
-
rule. A reader who reads both lines has been told two different things about
|
|
13
|
-
the same message by the same tooltip, and the app is the one that is wrong.
|
|
3
|
+
Ctrl+N opens compose with the cursor in the message body instead of the To
|
|
4
|
+
field (Bob 2026-09-03: "^n (and forward?) still start me in the body rather
|
|
5
|
+
than the to field" — and yes, forward too).
|
|
14
6
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
7
|
+
applyInit made the decision twice. First it seeded the body and called
|
|
8
|
+
`editor.setCursor(0)`; twenty lines later it picked the first empty field and
|
|
9
|
+
focused it. Reading top to bottom the second one wins, and it does not:
|
|
10
|
+
`setCursor` is not a caret-placement call, it is a focus call. rmf-tiny's
|
|
11
|
+
implementation ends with `editor.focus()` and then re-runs the whole placement
|
|
12
|
+
inside `requestAnimationFrame` — deliberately, to survive the nested-iframe
|
|
13
|
+
focus race that produced the old "have to click in and try again" symptom — so
|
|
14
|
+
it lands after anything applyInit does synchronously afterwards. Quill's
|
|
15
|
+
`setSelection` focuses as well. Whatever order the two lines were written in,
|
|
16
|
+
the editor was always going to win.
|
|
21
17
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
and
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
bulk verdict loses its "— nothing that scored tests who sent it" clause on the
|
|
29
|
-
same condition, since it was making the same unchecked claim.
|
|
18
|
+
So the two are now one decision, made once and up front: `focusTarget` is the
|
|
19
|
+
first field the user still has to fill, To → Subject → body, and `setCursor` is
|
|
20
|
+
asked for only when the answer is the body. On a reply that is still the body —
|
|
21
|
+
To and Subject are filled, and the call also scrolls the quote out of view so
|
|
22
|
+
the empty line is what's on screen, which is the behaviour it exists for. On a
|
|
23
|
+
forward and on new mail it is the To field, untouched.
|
|
30
24
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
Not changed, on purpose: KAM_ACCOUNTPHISH stays unclassified. Its description
|
|
38
|
-
says it tests what the message asks for, not who sent it, but "other" is the
|
|
39
|
-
honest answer for a rule this file has no basis to classify, and the cautious
|
|
40
|
-
default is what "other" is for. The fix is to stop asserting past it, not to
|
|
41
|
-
guess at it.
|
|
25
|
+
Forward has been doing this since it grew a quoted body. Ctrl+N joined it in
|
|
26
|
+
v1.2.298, three hours ago: before the account signature reached compose,
|
|
27
|
+
`bodyToRender` was empty for new mail and the branch holding `setCursor` never
|
|
28
|
+
ran at all. The first message anyone composed with a signature was also the
|
|
29
|
+
first one that opened with the cursor in the wrong place.
|
|
@@ -6191,9 +6191,10 @@ function applyInit(init) {
|
|
|
6191
6191
|
bodyToRender = isReplyForward ? `<br>${sigBlock}<br>${bodyToRender}` : `${bodyToRender}${sigBlock}`;
|
|
6192
6192
|
}
|
|
6193
6193
|
}
|
|
6194
|
+
const focusTarget = !toInput.value ? toInput : !subjectInput.value ? subjectInput : null;
|
|
6194
6195
|
if (bodyToRender) {
|
|
6195
6196
|
editor.setHtml(bodyToRender);
|
|
6196
|
-
editor.setCursor(0);
|
|
6197
|
+
if (!focusTarget) editor.setCursor(0);
|
|
6197
6198
|
}
|
|
6198
6199
|
if (init.draftUid) {
|
|
6199
6200
|
draftUid = init.draftUid;
|
|
@@ -6214,8 +6215,7 @@ function applyInit(init) {
|
|
|
6214
6215
|
renderAttachmentChips();
|
|
6215
6216
|
}
|
|
6216
6217
|
setComposeTitle(init.subject || "");
|
|
6217
|
-
if (
|
|
6218
|
-
else if (!subjectInput.value) subjectInput.focus();
|
|
6218
|
+
if (focusTarget) focusTarget.focus();
|
|
6219
6219
|
else editor.focus();
|
|
6220
6220
|
recordContentBaseline();
|
|
6221
6221
|
if (init.draftUid && init.draftId) {
|