@bobfrankston/rmfmail 1.2.136 → 1.2.137
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/bin/mailx.js +62 -6
- package/bin/mailx.js.map +1 -1
- package/bin/mailx.ts +58 -6
- package/client/app.bundle.js +40 -5
- package/client/app.bundle.js.map +3 -3
- package/client/app.js +31 -0
- package/client/app.js.map +1 -1
- package/client/app.ts +24 -0
- package/client/components/message-list.js +30 -4
- package/client/components/message-list.js.map +1 -1
- package/client/components/message-list.ts +30 -4
- package/client/compose/compose.bundle.js +4 -0
- package/client/compose/compose.bundle.js.map +2 -2
- package/client/lib/api-client.js +5 -0
- package/client/lib/api-client.js.map +1 -1
- package/client/lib/api-client.ts +6 -0
- package/client/lib/mailxapi.js +4 -0
- package/package.json +1 -1
- package/packages/mailx-service/jsonrpc.d.ts +1 -0
- package/packages/mailx-service/jsonrpc.d.ts.map +1 -1
- package/packages/mailx-service/jsonrpc.js +15 -0
- package/packages/mailx-service/jsonrpc.js.map +1 -1
- package/packages/mailx-service/jsonrpc.ts +17 -0
- package/packages/mailx-store/db.d.ts.map +1 -1
- package/packages/mailx-store/db.js +28 -2
- package/packages/mailx-store/db.js.map +1 -1
- package/packages/mailx-store/db.ts +27 -2
package/client/app.js
CHANGED
|
@@ -3671,6 +3671,37 @@ onWsEvent((event) => {
|
|
|
3671
3671
|
}).catch((e) => console.error("openComposeFromMailto failed:", e?.message || e));
|
|
3672
3672
|
break;
|
|
3673
3673
|
}
|
|
3674
|
+
case "debugEval": {
|
|
3675
|
+
// --debug-server /api/eval: the daemon pushes {id, code}; we
|
|
3676
|
+
// evaluate in the live page and answer via debugEvalResult. This
|
|
3677
|
+
// is the "drive the app yourself" hook — lets an agent inspect
|
|
3678
|
+
// the real DOM (elementFromPoint, computed styles, scroll state)
|
|
3679
|
+
// without devtools. Only the daemon can push events on this
|
|
3680
|
+
// channel, and only --debug-server exposes the endpoint.
|
|
3681
|
+
const { id, code } = event;
|
|
3682
|
+
if (!id || typeof code !== "string")
|
|
3683
|
+
break;
|
|
3684
|
+
(async () => {
|
|
3685
|
+
const { debugEvalResult } = await import("./lib/api-client.js");
|
|
3686
|
+
try {
|
|
3687
|
+
const fn = new Function(`return (async () => (${code}))();`);
|
|
3688
|
+
let v = await fn();
|
|
3689
|
+
// DOM nodes / circular structures can't ride JSON — fall
|
|
3690
|
+
// back to their string form rather than failing the call.
|
|
3691
|
+
try {
|
|
3692
|
+
JSON.stringify(v);
|
|
3693
|
+
}
|
|
3694
|
+
catch {
|
|
3695
|
+
v = String(v);
|
|
3696
|
+
}
|
|
3697
|
+
await debugEvalResult(id, v);
|
|
3698
|
+
}
|
|
3699
|
+
catch (e) {
|
|
3700
|
+
await debugEvalResult(id, undefined, e?.message || String(e));
|
|
3701
|
+
}
|
|
3702
|
+
})().catch((e) => console.error(`[debug-eval] reply failed: ${e?.message || e}`));
|
|
3703
|
+
break;
|
|
3704
|
+
}
|
|
3674
3705
|
case "popoutAction": {
|
|
3675
3706
|
// Toolbar click inside a NATIVE popout window (msger, spawned by
|
|
3676
3707
|
// the daemon). That window has no IPC bridge and can't host
|