@bobfrankston/rmfmail 1.2.103 → 1.2.105

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.js CHANGED
@@ -3566,6 +3566,23 @@ onWsEvent((event) => {
3566
3566
  }).catch((e) => console.error("openComposeFromMailto failed:", e?.message || e));
3567
3567
  break;
3568
3568
  }
3569
+ case "popoutAction": {
3570
+ // Toolbar click inside a NATIVE popout window (msger, spawned by
3571
+ // the daemon). That window has no IPC bridge and can't host
3572
+ // compose, so the daemon forwards the action here; we load the
3573
+ // message locally and reuse the overlay-popout action path —
3574
+ // reply/replyAll/forward/editAsNew open the real editable
3575
+ // compose, flag/delete act directly.
3576
+ const { action, accountId, uid, folderId } = event;
3577
+ if (!action || !accountId || !uid)
3578
+ break;
3579
+ (async () => {
3580
+ const { getMessage } = await import("./lib/api-client.js");
3581
+ const msg = await getMessage(accountId, uid, false, folderId);
3582
+ document.dispatchEvent(new CustomEvent("mailx-popout-action", { detail: { action, msg, accountId } }));
3583
+ })().catch((e) => console.error(`[popout-window] ${action} failed: ${e?.message || e}`));
3584
+ break;
3585
+ }
3569
3586
  }
3570
3587
  });
3571
3588
  // Store-bus consumers (post-refactor). The list's mailx-remove-stale
@@ -5889,11 +5906,11 @@ function renderDiagnosticsBadge(snapshot) {
5889
5906
  }).join("\n");
5890
5907
  host.title = `Connection issues — ${summary}\n\n${detail}`;
5891
5908
  }
5892
- // Q64: pop-out a message into a floating overlay (real-OS-window pending C44).
5893
- // Action buttons on the message pop-out window Reply / Reply All / Forward
5894
- // act on the popped-out message specifically (not the main viewer's), Delete
5895
- // removes it. The pop-out lives in message-viewer.ts and can't import
5896
- // openCompose directly, so it fires this event.
5909
+ // Q64/C44: pop-out message actions. Fired by the floating-overlay popout's
5910
+ // toolbar (message-viewer.ts can't import openCompose directly) AND by the
5911
+ // native popout window via the `popoutAction` daemon event above. Reply /
5912
+ // Reply All / Forward act on the popped-out message specifically (not the
5913
+ // main viewer's), Delete removes it.
5897
5914
  document.addEventListener("mailx-popout-action", ((e) => {
5898
5915
  const { action, msg, accountId } = e.detail || {};
5899
5916
  if (!msg)