@bobfrankston/rmfmail 1.0.507 → 1.0.512
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 +12 -0
- package/client/app.js.map +1 -1
- package/client/app.ts +12 -0
- package/client/compose/compose.js +20 -0
- package/client/compose/compose.js.map +1 -1
- package/client/compose/compose.ts +20 -0
- package/package.json +5 -5
- package/packages/mailx-host/package.json +2 -10
- package/packages/mailx-settings/cloud.d.ts +11 -0
- package/packages/mailx-settings/cloud.d.ts.map +1 -1
- package/packages/mailx-settings/cloud.js +42 -0
- package/packages/mailx-settings/cloud.js.map +1 -1
- package/packages/mailx-settings/cloud.ts +42 -0
- package/packages/mailx-settings/index.d.ts.map +1 -1
- package/packages/mailx-settings/index.js +28 -1
- package/packages/mailx-settings/index.js.map +1 -1
- package/packages/mailx-settings/index.ts +29 -1
- package/packages/mailx-store-web/android-bootstrap.d.ts.map +1 -1
- package/packages/mailx-store-web/android-bootstrap.js +130 -1
- package/packages/mailx-store-web/android-bootstrap.js.map +1 -1
- package/packages/mailx-store-web/android-bootstrap.ts +128 -1
- package/packages/mailx-store-web/db.d.ts +10 -0
- package/packages/mailx-store-web/db.d.ts.map +1 -1
- package/packages/mailx-store-web/db.js +20 -0
- package/packages/mailx-store-web/db.js.map +1 -1
- package/packages/mailx-store-web/db.ts +22 -0
|
@@ -588,6 +588,28 @@ export class WebMailxDB {
|
|
|
588
588
|
|
|
589
589
|
// ── Contacts ──
|
|
590
590
|
|
|
591
|
+
/** Delete every contact row tied to a single Google contact identity
|
|
592
|
+
* (resourceName like "people/c12345"). Used by the People-API
|
|
593
|
+
* incremental sync when Google flags a contact as deleted. A single
|
|
594
|
+
* Google contact can have multiple email-rows; remove them all. */
|
|
595
|
+
deleteContactByGoogleId(googleId: string): number {
|
|
596
|
+
if (!googleId) return 0;
|
|
597
|
+
const before = (this.get("SELECT COUNT(*) as c FROM contacts WHERE google_id = ?", [googleId]) as any)?.c || 0;
|
|
598
|
+
this.run("DELETE FROM contacts WHERE google_id = ?", [googleId]);
|
|
599
|
+
return before;
|
|
600
|
+
}
|
|
601
|
+
|
|
602
|
+
/** Stamp the google_id + organization on an already-recorded contact row.
|
|
603
|
+
* Web side mirrors mailx-store/db.ts — the Google sync calls
|
|
604
|
+
* `recordSentAddress` first to upsert, then this to attach the
|
|
605
|
+
* Google identity for incremental delete tracking. */
|
|
606
|
+
setContactGoogleId(email: string, googleId: string, organization: string): void {
|
|
607
|
+
if (!email) return;
|
|
608
|
+
this.run(
|
|
609
|
+
"UPDATE contacts SET source = 'google', google_id = ?, organization = ?, updated_at = ? WHERE email = ?",
|
|
610
|
+
[googleId, organization || "", Date.now(), email]);
|
|
611
|
+
}
|
|
612
|
+
|
|
591
613
|
recordSentAddress(name: string, email: string): void {
|
|
592
614
|
if (isJunkContact(email, name)) return;
|
|
593
615
|
const now = Date.now();
|