@bobfrankston/mailx 1.0.374 → 1.0.376

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.
@@ -788,15 +788,14 @@ button.tb-menu-item { background: none; border: none; color: inherit; width: 100
788
788
  opacity: 0.5;
789
789
  }
790
790
 
791
- /* S1 slice C — pink row when a local action (move/flag/delete) is queued
792
- but the server hasn't ACK'd. Visible reconciliation state: "we did your
793
- thing locally, the server hasn't agreed yet." Selection still wins
794
- visually so the active row is identifiable. */
795
- .ml-row.pending-reconcile {
796
- background: oklch(0.96 0.04 350); /* pale pink */
797
- }
798
- .ml-row.pending-reconcile.selected {
799
- background: oklch(0.85 0.10 350); /* deeper pink when selected */
791
+ /* S1 slice C — local action (move/flag/delete) queued but server hasn't
792
+ ACK'd. Reuses the same date-column dot as the download indicator so
793
+ "still on client, not yet on server" sits in the same visual slot as
794
+ "body downloaded". Color, not row background the row keeps the
795
+ normal/unread/selected styling so the blue accent isn't fighting pink. */
796
+ .ml-row.pending-reconcile .ml-date::before {
797
+ color: oklch(0.65 0.22 350); /* pink dot */
798
+ opacity: 0.9;
800
799
  }
801
800
 
802
801
  /* S51 — calendar sidebar (Thunderbird Lightning Events & Tasks pane).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bobfrankston/mailx",
3
- "version": "1.0.374",
3
+ "version": "1.0.376",
4
4
  "description": "Local-first email client with IMAP sync and standalone native app",
5
5
  "type": "module",
6
6
  "main": "bin/mailx.js",
@@ -573,7 +573,12 @@ export class MailxDB {
573
573
  const placeholders = inboxRows.map(() => "?").join(",");
574
574
  const folderIds = inboxRows.map((r) => r.id);
575
575
  const total = this.db.prepare(`SELECT COUNT(*) as cnt FROM messages WHERE folder_id IN (${placeholders})`).get(...folderIds).cnt;
576
- const rows = this.db.prepare(`SELECT * FROM messages WHERE folder_id IN (${placeholders}) ORDER BY date DESC LIMIT ? OFFSET ?`).all(...folderIds, pageSize, offset);
576
+ const rows = this.db.prepare(`SELECT m.*, EXISTS(
577
+ SELECT 1 FROM sync_actions sa
578
+ WHERE sa.account_id = m.account_id AND sa.uid = m.uid
579
+ ) AS pending
580
+ FROM messages m WHERE m.folder_id IN (${placeholders})
581
+ ORDER BY m.date DESC LIMIT ? OFFSET ?`).all(...folderIds, pageSize, offset);
577
582
  const items = rows.map(r => ({
578
583
  id: r.id,
579
584
  accountId: r.account_id,
@@ -592,7 +597,8 @@ export class MailxDB {
592
597
  size: r.size,
593
598
  hasAttachments: !!r.has_attachments,
594
599
  preview: r.preview,
595
- bodyPath: r.body_path || ""
600
+ bodyPath: r.body_path || "",
601
+ pending: !!r.pending,
596
602
  }));
597
603
  return { items, total, page, pageSize };
598
604
  }