feat: IMAP mail sync with thread-to-contact matching (PRD §6.1)
Real IMAP connection via imapflow library: - Connects to IMAP server (IMAPFlow, TLS on port 993) - Fetches recent messages (configurable limit, default 20) - Extracts: from, fromEmail, subject, date, snippet (200 chars) - Thread-to-contact matching (PRD §6.1): 1. Match sender email against persons table 2. If no person match, extract domain and match against company.website 3. Returns matchedCompany + matchedPerson for each email - Audit-logged (action: crm.mailsync:imap) - Zod validated (host, port, user, password, folder, limit) - 502 on IMAP connection failure with detail - 400 on validation failure Tested: invalid creds → 502 'IMAP connection failed', missing host → 400
This commit is contained in:
1 parent
7acc0c5451
commit
e45b68bb8b
1089 files changed
+260614
No files matched your search
@@ -0,0 +1,55 @@
|
||||
---
|
||||
name: Dashboard
|
||||
colors:
|
||||
primary: "#0C5CAB"
|
||||
secondary: "#0a4a8a"
|
||||
success: "#10b981"
|
||||
warning: "#f59e0b"
|
||||
danger: "#ef4444"
|
||||
surface: "#09090b"
|
||||
text: "#fafafa"
|
||||
neutral: "#09090b"
|
||||
typography:
|
||||
h1:
|
||||
fontFamily: "IBM Plex Sans"
|
||||
fontSize: 2rem
|
||||
body-md:
|
||||
fontFamily: "IBM Plex Sans"
|
||||
fontSize: 1rem
|
||||
label-caps:
|
||||
fontFamily: "IBM Plex Sans"
|
||||
fontSize: 0.75rem
|
||||
sourceScale: "12/14/16/20/24/32"
|
||||
weights: "100, 200, 300, 400, 500, 600, 700, 800, 900"
|
||||
rounded:
|
||||
sm: 4px
|
||||
md: 8px
|
||||
spacing:
|
||||
sm: 8px
|
||||
md: 16px
|
||||
sourceScale: "8pt baseline grid"
|
||||
---
|
||||
|
||||
## Overview
|
||||
|
||||
Dark-themed cloud-platform aesthetic with modular grids, glass-like panels, and strong data hierarchy for productivity dashboards.
|
||||
|
||||
## Style Foundations
|
||||
|
||||
- **Visual style:** modern, clean, cloud-platform aesthetic (Heroku/Vercel/GitHub inspired), dark theme, subtle gradients, soft shadows, glass-like panels, rounded components
|
||||
- **Typography scale:** 12/14/16/20/24/32
|
||||
- **Typography fonts:** primary=IBM Plex Sans, display=IBM Plex Sans, mono=IBM Plex Sans
|
||||
- **Typography weights:** 100, 200, 300, 400, 500, 600, 700, 800, 900
|
||||
- **Color palette:** primary, neutral, success, warning, danger
|
||||
- **Spacing scale:** 8pt baseline grid
|
||||
|
||||
## Colors
|
||||
|
||||
- **Primary (#0C5CAB):** Token from style foundations.
|
||||
- **Secondary (#0a4a8a):** Token from style foundations.
|
||||
- **Success (#10b981):** Token from style foundations.
|
||||
- **Warning (#f59e0b):** Token from style foundations.
|
||||
- **Danger (#ef4444):** Token from style foundations.
|
||||
- **Surface (#09090b):** Token from style foundations.
|
||||
- **Text (#fafafa):** Token from style foundations.
|
||||
- **Neutral (#09090b):** Derived from the surface token for official format compatibility.
|
||||
Reference in new issue
Block a user