@heliyos/heliyos-api-core 1.0.58 → 1.0.60

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.
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
@@ -61,93 +61,98 @@
61
61
  }
62
62
 
63
63
  .section {
64
- margin: 24px 0;
65
- padding: 20px;
66
- background-color: #f5f2e9;
67
- border-radius: 8px;
68
- border-left: 4px solid #7c3aed;
64
+ margin: 20px 0;
65
+ padding: 0;
66
+ background-color: transparent;
67
+ border-radius: 0;
68
+ border-left: none;
69
69
  }
70
70
 
71
71
  .section-header {
72
72
  display: flex;
73
73
  justify-content: space-between;
74
74
  align-items: center;
75
- margin-bottom: 16px;
75
+ margin-bottom: 12px;
76
+ padding-bottom: 8px;
77
+ border-bottom: 1px solid #e5e7eb;
76
78
  }
77
79
 
78
80
  .section-title {
79
- font-size: 18px;
81
+ font-size: 16px;
80
82
  font-weight: bold;
81
- color: #0e0d0c;
83
+ color: #111827;
82
84
  margin: 0;
83
85
  }
84
86
 
85
87
  .section-count {
86
- background-color: #7c3aed;
87
- color: #ffffff;
88
- padding: 4px 12px;
89
- border-radius: 12px;
90
- font-size: 12px;
88
+ background-color: #f3f0ff;
89
+ color: #7c3aed;
90
+ padding: 2px 8px;
91
+ border-radius: 4px;
92
+ font-size: 11px;
91
93
  font-weight: bold;
92
94
  }
93
95
 
94
96
  .section-content {
95
- color: #2c2721;
96
- line-height: 1.8;
97
+ color: #374151;
97
98
  }
98
99
 
99
100
  .item {
100
- margin: 12px 0;
101
- padding: 12px;
102
- background-color: #ffffff;
103
- border-radius: 6px;
104
- border: 1px solid #7c3aed;
101
+ margin: 0;
102
+ padding: 12px 0;
103
+ background-color: transparent;
104
+ border-radius: 0;
105
+ border: none;
106
+ border-bottom: 1px solid #f3f4f6;
105
107
  }
106
108
 
107
- .item-summary {
108
- margin-top: 8px;
109
- color: #2c2721;
109
+ .item:last-child {
110
+ border-bottom: none;
111
+ }
112
+
113
+ .item-title {
114
+ font-weight: 600;
115
+ color: #111827;
110
116
  font-size: 14px;
111
- line-height: 1.6;
117
+ margin-bottom: 2px;
112
118
  }
113
119
 
114
- .item-details {
115
- margin-top: 10px;
116
- background-color: #f8f5ff;
117
- border-radius: 6px;
118
- padding: 10px;
120
+ .item-meta {
121
+ font-size: 12px;
122
+ color: #6b7280;
119
123
  }
120
124
 
121
- .detail-row {
122
- font-size: 13px;
123
- color: #3f2d63;
124
- margin: 4px 0;
125
+ .item-details {
126
+ margin-top: 8px;
127
+ background-color: #f9fafb;
128
+ border-radius: 6px;
129
+ padding: 8px 12px;
125
130
  }
126
131
 
127
- .detail-row strong {
128
- color: #2b1d4d;
132
+ .detail-table {
133
+ width: 100%;
134
+ border-collapse: collapse;
129
135
  }
130
136
 
131
- .item-link {
132
- margin-top: 10px;
137
+ .detail-cell {
138
+ padding-right: 12px;
139
+ vertical-align: top;
133
140
  }
134
141
 
135
- .item-link a {
136
- color: #7c3aed;
137
- text-decoration: none;
142
+ .detail-label {
143
+ font-size: 10px;
144
+ color: #6b7280;
145
+ text-transform: uppercase;
138
146
  font-weight: bold;
139
- font-size: 13px;
140
147
  }
141
148
 
142
- .item-title {
143
- font-weight: bold;
144
- color: #0e0d0c;
145
- margin-bottom: 4px;
149
+ .detail-value {
150
+ font-size: 12px;
151
+ color: #374151;
146
152
  }
147
153
 
148
- .item-meta {
149
- font-size: 13px;
150
- color: #5c5545;
154
+ .item-link {
155
+ margin-top: 10px;
151
156
  }
152
157
 
153
158
  .org-summary-box {
@@ -226,7 +231,7 @@
226
231
  </div>
227
232
  <div class="content">
228
233
  <div class="greeting">
229
- Hello,<br>
234
+ Hello {{first_name}},<br>
230
235
  Here's your daily summary of activities in your Heliyos workspace.
231
236
  </div>
232
237
 
@@ -246,21 +251,36 @@
246
251
  <div class="section-content">
247
252
  {{#each tasks}}
248
253
  <div class="item">
249
- <div class="item-title">{{this.title}}</div>
250
- <div class="item-meta">{{this.type}} • {{this.actor}} • {{this.time}}</div>
251
- {{#if this.summary}}
252
- <div class="item-summary">{{this.summary}}</div>
253
- {{/if}}
254
+ <table style="width: 100%; border-collapse: collapse;">
255
+ <tr>
256
+ <td>
257
+ <div class="item-title">{{this.title}}</div>
258
+ <div class="item-meta">
259
+ <span style="color: #7c3aed; font-weight: 600;">{{this.type}}</span> • {{this.actor}}
260
+ </div>
261
+ </td>
262
+ <td style="text-align: right; vertical-align: top; font-size: 11px; color: #9ca3af;">
263
+ {{this.time}}
264
+ </td>
265
+ </tr>
266
+ </table>
254
267
  {{#if this.details}}
255
268
  <div class="item-details">
256
- {{#each this.details}}
257
- <div class="detail-row"><strong>{{this.label}}:</strong> {{this.value}}</div>
258
- {{/each}}
269
+ <table class="detail-table">
270
+ <tr>
271
+ {{#each this.details}}
272
+ <td class="detail-cell">
273
+ <div class="detail-label">{{this.label}}</div>
274
+ <div class="detail-value">{{this.value}}</div>
275
+ </td>
276
+ {{/each}}
277
+ </tr>
278
+ </table>
259
279
  </div>
260
280
  {{/if}}
261
281
  {{#if this.view_url}}
262
- <div class="item-link">
263
- <a href="{{this.view_url}}">View in App →</a>
282
+ <div style="margin-top: 6px;">
283
+ <a href="{{this.view_url}}" style="font-size: 11px; color: #7c3aed; text-decoration: none; font-weight: bold;">View Details →</a>
264
284
  </div>
265
285
  {{/if}}
266
286
  </div>
@@ -281,21 +301,36 @@
281
301
  <div class="section-content">
282
302
  {{#each deals}}
283
303
  <div class="item">
284
- <div class="item-title">{{this.title}}</div>
285
- <div class="item-meta">{{this.type}} • {{this.actor}} • {{this.time}}</div>
286
- {{#if this.summary}}
287
- <div class="item-summary">{{this.summary}}</div>
288
- {{/if}}
304
+ <table style="width: 100%; border-collapse: collapse;">
305
+ <tr>
306
+ <td>
307
+ <div class="item-title">{{this.title}}</div>
308
+ <div class="item-meta">
309
+ <span style="color: #7c3aed; font-weight: 600;">{{this.type}}</span> • {{this.actor}}
310
+ </div>
311
+ </td>
312
+ <td style="text-align: right; vertical-align: top; font-size: 11px; color: #9ca3af;">
313
+ {{this.time}}
314
+ </td>
315
+ </tr>
316
+ </table>
289
317
  {{#if this.details}}
290
318
  <div class="item-details">
291
- {{#each this.details}}
292
- <div class="detail-row"><strong>{{this.label}}:</strong> {{this.value}}</div>
293
- {{/each}}
319
+ <table class="detail-table">
320
+ <tr>
321
+ {{#each this.details}}
322
+ <td class="detail-cell">
323
+ <div class="detail-label">{{this.label}}</div>
324
+ <div class="detail-value">{{this.value}}</div>
325
+ </td>
326
+ {{/each}}
327
+ </tr>
328
+ </table>
294
329
  </div>
295
330
  {{/if}}
296
331
  {{#if this.view_url}}
297
- <div class="item-link">
298
- <a href="{{this.view_url}}">View in App →</a>
332
+ <div style="margin-top: 6px;">
333
+ <a href="{{this.view_url}}" style="font-size: 11px; color: #7c3aed; text-decoration: none; font-weight: bold;">View Details →</a>
299
334
  </div>
300
335
  {{/if}}
301
336
  </div>
@@ -316,21 +351,36 @@
316
351
  <div class="section-content">
317
352
  {{#each approvals}}
318
353
  <div class="item">
319
- <div class="item-title">{{this.title}}</div>
320
- <div class="item-meta">{{this.status}} • {{this.actor}} • {{this.time}}</div>
321
- {{#if this.summary}}
322
- <div class="item-summary">{{this.summary}}</div>
323
- {{/if}}
354
+ <table style="width: 100%; border-collapse: collapse;">
355
+ <tr>
356
+ <td>
357
+ <div class="item-title">{{this.title}}</div>
358
+ <div class="item-meta">
359
+ <span style="color: #7c3aed; font-weight: 600;">{{this.status}}</span> • {{this.actor}}
360
+ </div>
361
+ </td>
362
+ <td style="text-align: right; vertical-align: top; font-size: 11px; color: #9ca3af;">
363
+ {{this.time}}
364
+ </td>
365
+ </tr>
366
+ </table>
324
367
  {{#if this.details}}
325
368
  <div class="item-details">
326
- {{#each this.details}}
327
- <div class="detail-row"><strong>{{this.label}}:</strong> {{this.value}}</div>
328
- {{/each}}
369
+ <table class="detail-table">
370
+ <tr>
371
+ {{#each this.details}}
372
+ <td class="detail-cell">
373
+ <div class="detail-label">{{this.label}}</div>
374
+ <div class="detail-value">{{this.value}}</div>
375
+ </td>
376
+ {{/each}}
377
+ </tr>
378
+ </table>
329
379
  </div>
330
380
  {{/if}}
331
381
  {{#if this.view_url}}
332
- <div class="item-link">
333
- <a href="{{this.view_url}}">View in App →</a>
382
+ <div style="margin-top: 6px;">
383
+ <a href="{{this.view_url}}" style="font-size: 11px; color: #7c3aed; text-decoration: none; font-weight: bold;">View Details →</a>
334
384
  </div>
335
385
  {{/if}}
336
386
  </div>
@@ -351,21 +401,33 @@
351
401
  <div class="section-content">
352
402
  {{#each leadsets}}
353
403
  <div class="item">
354
- <div class="item-title">{{this.title}}</div>
355
- <div class="item-meta">{{this.records_count}} records available • {{this.time}}</div>
356
- {{#if this.summary}}
357
- <div class="item-summary">{{this.summary}}</div>
358
- {{/if}}
404
+ <table style="width: 100%; border-collapse: collapse;">
405
+ <tr>
406
+ <td>
407
+ <div class="item-title">{{this.title}}</div>
408
+ <div class="item-meta">
409
+ <span style="color: #7c3aed; font-weight: 600;">{{this.records_count}} records</span> • {{this.time}}
410
+ </div>
411
+ </td>
412
+ </tr>
413
+ </table>
359
414
  {{#if this.details}}
360
415
  <div class="item-details">
361
- {{#each this.details}}
362
- <div class="detail-row"><strong>{{this.label}}:</strong> {{this.value}}</div>
363
- {{/each}}
416
+ <table class="detail-table">
417
+ <tr>
418
+ {{#each this.details}}
419
+ <td class="detail-cell">
420
+ <div class="detail-label">{{this.label}}</div>
421
+ <div class="detail-value">{{this.value}}</div>
422
+ </td>
423
+ {{/each}}
424
+ </tr>
425
+ </table>
364
426
  </div>
365
427
  {{/if}}
366
428
  {{#if this.view_url}}
367
- <div class="item-link">
368
- <a href="{{this.view_url}}">View in App →</a>
429
+ <div style="margin-top: 6px;">
430
+ <a href="{{this.view_url}}" style="font-size: 11px; color: #7c3aed; text-decoration: none; font-weight: bold;">View Details →</a>
369
431
  </div>
370
432
  {{/if}}
371
433
  </div>
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
@@ -41,61 +41,68 @@
41
41
  }
42
42
 
43
43
  .event-card {
44
- background-color: #f5f2e9;
45
- border: 1px solid #7c3aed;
44
+ background-color: #ffffff;
45
+ border: 1px solid #e5e7eb;
46
46
  border-radius: 8px;
47
- padding: 20px;
48
- margin: 20px 0;
47
+ padding: 16px;
48
+ margin: 16px 0;
49
49
  }
50
50
 
51
51
  .event-badge {
52
52
  display: inline-block;
53
- background-color: #7c3aed;
54
- color: #ffffff;
55
- padding: 6px 12px;
56
- border-radius: 20px;
57
- font-size: 12px;
53
+ background-color: #f3f0ff;
54
+ color: #7c3aed;
55
+ padding: 4px 8px;
56
+ border-radius: 4px;
57
+ font-size: 11px;
58
58
  font-weight: bold;
59
59
  text-transform: uppercase;
60
- margin-bottom: 12px;
60
+ margin-bottom: 8px;
61
61
  }
62
62
 
63
63
  .event-title {
64
- font-size: 20px;
64
+ font-size: 18px;
65
65
  font-weight: bold;
66
- color: #0e0d0c;
67
- margin: 10px 0;
68
- }
69
-
70
- .event-summary {
71
- color: #2c2721;
72
- margin: 12px 0;
73
- line-height: 1.6;
66
+ color: #111827;
67
+ margin: 0 0 12px 0;
74
68
  }
75
69
 
76
70
  .event-details {
77
71
  margin-top: 12px;
78
- background-color: #f8f5ff;
72
+ background-color: #f9fafb;
79
73
  border-radius: 6px;
80
74
  padding: 12px;
81
75
  }
82
76
 
83
- .detail-row {
84
- font-size: 14px;
85
- color: #3f2d63;
86
- margin: 6px 0;
77
+ .detail-table {
78
+ width: 100%;
79
+ border-collapse: collapse;
80
+ }
81
+
82
+ .detail-label {
83
+ font-size: 11px;
84
+ color: #6b7280;
85
+ text-transform: uppercase;
86
+ font-weight: bold;
87
+ margin-bottom: 2px;
88
+ }
89
+
90
+ .detail-value {
91
+ font-size: 13px;
92
+ color: #111827;
87
93
  }
88
94
 
89
- .detail-row strong {
90
- color: #2b1d4d;
95
+ .detail-cell {
96
+ padding-right: 16px;
97
+ vertical-align: top;
91
98
  }
92
99
 
93
100
  .event-meta {
94
101
  margin-top: 16px;
95
- padding-top: 16px;
96
- border-top: 1px solid #ebe7db;
97
- font-size: 14px;
98
- color: #5c5545;
102
+ padding-top: 12px;
103
+ border-top: 1px solid #f3f4f6;
104
+ font-size: 12px;
105
+ color: #6b7280;
99
106
  }
100
107
 
101
108
  .event-meta strong {
@@ -144,23 +151,28 @@
144
151
  <img src="https://assets.heliyos.ai/heliyos-logo-white.png" alt="Heliyos AI">
145
152
  </div>
146
153
  <div class="content">
147
- <p>Hello,</p>
154
+ <p>Hello {{first_name}},</p>
148
155
  <p>You have a new update in your Heliyos workspace:</p>
149
156
 
150
157
  <div class="event-card">
151
158
  <div class="event-badge">{{event_type_label}}</div>
152
159
  <div class="event-title">{{object_name}}</div>
153
- <div class="event-summary">{{summary}}</div>
154
160
  {{#if details}}
155
161
  <div class="event-details">
156
- {{#each details}}
157
- <div class="detail-row"><strong>{{this.label}}:</strong> {{this.value}}</div>
158
- {{/each}}
162
+ <table class="detail-table">
163
+ <tr>
164
+ {{#each details}}
165
+ <td class="detail-cell">
166
+ <div class="detail-label">{{this.label}}</div>
167
+ <div class="detail-value">{{this.value}}</div>
168
+ </td>
169
+ {{/each}}
170
+ </tr>
171
+ </table>
159
172
  </div>
160
173
  {{/if}}
161
174
  <div class="event-meta">
162
- <strong>By:</strong> {{actor_name}}<br>
163
- <strong>When:</strong> {{timestamp}}
175
+ <strong>By:</strong> {{actor_name}}<strong>When:</strong> {{timestamp}}
164
176
  </div>
165
177
  </div>
166
178
 
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
@@ -80,7 +80,7 @@
80
80
  </div>
81
81
  <div class="content">
82
82
  <h2 style="margin-top: 0; color: #0e0d0c;">Confirm Your Email Address</h2>
83
- <p>Hello,</p>
83
+ <p>Hello {{first_name}},</p>
84
84
  <p>Thank you for signing up for Heliyos AI! To complete your registration and verify your email address, please click the
85
85
  button below:</p>
86
86
  <p style="text-align: center;">
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
package/dist/resend.d.ts CHANGED
@@ -1 +1,4 @@
1
- export declare const resendSendEmail: (to: string[], templateId: string, dynamicTemplateData: object, subject: string) => Promise<import("resend").CreateEmailResponse>;
1
+ export declare const resendSendEmail: (to: string[], templateId: string, dynamicTemplateData: object, subject: string) => Promise<import("resend").CreateEmailResponse | {
2
+ data: any;
3
+ error: Error;
4
+ }>;
package/dist/resend.js CHANGED
@@ -12,17 +12,69 @@ Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.resendSendEmail = void 0;
13
13
  const resend_1 = require("resend");
14
14
  const email_1 = require("./email");
15
+ const mongoose_1 = require("./mongoose");
16
+ const logger_1 = require("./logger");
15
17
  // eslint-disable-next-line import/prefer-default-export
16
18
  const resendSendEmail = (to, templateId, dynamicTemplateData, subject) => __awaiter(void 0, void 0, void 0, function* () {
17
19
  const resend = new resend_1.Resend(process.env.RESEND_API_KEY);
18
20
  const from = process.env.RESEND_FROM_RECIPIENT || "";
19
- const message = {
20
- to,
21
- from,
22
- subject,
23
- html: (0, email_1.getEmailTemplate)(templateId, dynamicTemplateData),
24
- };
25
- const response = yield resend.emails.send(message);
26
- return response;
21
+ // If there are multiple recipients, we send individual emails to ensure personalized salutations
22
+ const sendIndividualEmail = (email) => __awaiter(void 0, void 0, void 0, function* () {
23
+ let firstName = dynamicTemplateData.first_name ||
24
+ dynamicTemplateData.firstName;
25
+ // Try to extract from fullName if available in data but firstName isn't
26
+ if (!firstName && dynamicTemplateData.fullName) {
27
+ firstName = dynamicTemplateData.fullName.split(" ")[0];
28
+ }
29
+ else if (!firstName && dynamicTemplateData.name) {
30
+ firstName = dynamicTemplateData.name.split(" ")[0];
31
+ }
32
+ if (!firstName) {
33
+ try {
34
+ // Access the User model if it's already registered on the connection
35
+ const UserModel = mongoose_1.mongooseConnection.models.User;
36
+ if (UserModel) {
37
+ const user = yield UserModel.findOne({ email })
38
+ .select("firstName")
39
+ .lean();
40
+ if (user && user.firstName) {
41
+ firstName = user.firstName;
42
+ }
43
+ }
44
+ // If still no firstName, use the part before @ as requested
45
+ if (!firstName) {
46
+ firstName = email.split("@")[0];
47
+ }
48
+ }
49
+ catch (error) {
50
+ // Fallback to email prefix on any error
51
+ firstName = email.split("@")[0];
52
+ }
53
+ }
54
+ const message = {
55
+ to: [email],
56
+ from,
57
+ subject,
58
+ html: (0, email_1.getEmailTemplate)(templateId, Object.assign(Object.assign({}, dynamicTemplateData), { first_name: firstName,
59
+ // For templates that might still use fullName or name
60
+ fullName: dynamicTemplateData.fullName || firstName, name: dynamicTemplateData.name || firstName })),
61
+ };
62
+ return resend.emails.send(message);
63
+ });
64
+ try {
65
+ if (to.length > 1) {
66
+ // Send emails in parallel but return the first response or a combined summary
67
+ const responses = yield Promise.all(to.map(sendIndividualEmail));
68
+ return responses[0];
69
+ }
70
+ else if (to.length === 1) {
71
+ return yield sendIndividualEmail(to[0]);
72
+ }
73
+ return { data: null, error: new Error("No recipients provided") };
74
+ }
75
+ catch (error) {
76
+ logger_1.logger.error("Error in resendSendEmail:", error);
77
+ throw error;
78
+ }
27
79
  });
28
80
  exports.resendSendEmail = resendSendEmail;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@heliyos/heliyos-api-core",
3
- "version": "1.0.58",
3
+ "version": "1.0.60",
4
4
  "description": "Heliyos's core api functions and middlewares. Its a private package hosted on npm.",
5
5
  "main": "./dist/index.js",
6
6
  "scripts": {
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
@@ -61,93 +61,98 @@
61
61
  }
62
62
 
63
63
  .section {
64
- margin: 24px 0;
65
- padding: 20px;
66
- background-color: #f5f2e9;
67
- border-radius: 8px;
68
- border-left: 4px solid #7c3aed;
64
+ margin: 20px 0;
65
+ padding: 0;
66
+ background-color: transparent;
67
+ border-radius: 0;
68
+ border-left: none;
69
69
  }
70
70
 
71
71
  .section-header {
72
72
  display: flex;
73
73
  justify-content: space-between;
74
74
  align-items: center;
75
- margin-bottom: 16px;
75
+ margin-bottom: 12px;
76
+ padding-bottom: 8px;
77
+ border-bottom: 1px solid #e5e7eb;
76
78
  }
77
79
 
78
80
  .section-title {
79
- font-size: 18px;
81
+ font-size: 16px;
80
82
  font-weight: bold;
81
- color: #0e0d0c;
83
+ color: #111827;
82
84
  margin: 0;
83
85
  }
84
86
 
85
87
  .section-count {
86
- background-color: #7c3aed;
87
- color: #ffffff;
88
- padding: 4px 12px;
89
- border-radius: 12px;
90
- font-size: 12px;
88
+ background-color: #f3f0ff;
89
+ color: #7c3aed;
90
+ padding: 2px 8px;
91
+ border-radius: 4px;
92
+ font-size: 11px;
91
93
  font-weight: bold;
92
94
  }
93
95
 
94
96
  .section-content {
95
- color: #2c2721;
96
- line-height: 1.8;
97
+ color: #374151;
97
98
  }
98
99
 
99
100
  .item {
100
- margin: 12px 0;
101
- padding: 12px;
102
- background-color: #ffffff;
103
- border-radius: 6px;
104
- border: 1px solid #7c3aed;
101
+ margin: 0;
102
+ padding: 12px 0;
103
+ background-color: transparent;
104
+ border-radius: 0;
105
+ border: none;
106
+ border-bottom: 1px solid #f3f4f6;
105
107
  }
106
108
 
107
- .item-summary {
108
- margin-top: 8px;
109
- color: #2c2721;
109
+ .item:last-child {
110
+ border-bottom: none;
111
+ }
112
+
113
+ .item-title {
114
+ font-weight: 600;
115
+ color: #111827;
110
116
  font-size: 14px;
111
- line-height: 1.6;
117
+ margin-bottom: 2px;
112
118
  }
113
119
 
114
- .item-details {
115
- margin-top: 10px;
116
- background-color: #f8f5ff;
117
- border-radius: 6px;
118
- padding: 10px;
120
+ .item-meta {
121
+ font-size: 12px;
122
+ color: #6b7280;
119
123
  }
120
124
 
121
- .detail-row {
122
- font-size: 13px;
123
- color: #3f2d63;
124
- margin: 4px 0;
125
+ .item-details {
126
+ margin-top: 8px;
127
+ background-color: #f9fafb;
128
+ border-radius: 6px;
129
+ padding: 8px 12px;
125
130
  }
126
131
 
127
- .detail-row strong {
128
- color: #2b1d4d;
132
+ .detail-table {
133
+ width: 100%;
134
+ border-collapse: collapse;
129
135
  }
130
136
 
131
- .item-link {
132
- margin-top: 10px;
137
+ .detail-cell {
138
+ padding-right: 12px;
139
+ vertical-align: top;
133
140
  }
134
141
 
135
- .item-link a {
136
- color: #7c3aed;
137
- text-decoration: none;
142
+ .detail-label {
143
+ font-size: 10px;
144
+ color: #6b7280;
145
+ text-transform: uppercase;
138
146
  font-weight: bold;
139
- font-size: 13px;
140
147
  }
141
148
 
142
- .item-title {
143
- font-weight: bold;
144
- color: #0e0d0c;
145
- margin-bottom: 4px;
149
+ .detail-value {
150
+ font-size: 12px;
151
+ color: #374151;
146
152
  }
147
153
 
148
- .item-meta {
149
- font-size: 13px;
150
- color: #5c5545;
154
+ .item-link {
155
+ margin-top: 10px;
151
156
  }
152
157
 
153
158
  .org-summary-box {
@@ -226,7 +231,7 @@
226
231
  </div>
227
232
  <div class="content">
228
233
  <div class="greeting">
229
- Hello,<br>
234
+ Hello {{first_name}},<br>
230
235
  Here's your daily summary of activities in your Heliyos workspace.
231
236
  </div>
232
237
 
@@ -246,21 +251,36 @@
246
251
  <div class="section-content">
247
252
  {{#each tasks}}
248
253
  <div class="item">
249
- <div class="item-title">{{this.title}}</div>
250
- <div class="item-meta">{{this.type}} • {{this.actor}} • {{this.time}}</div>
251
- {{#if this.summary}}
252
- <div class="item-summary">{{this.summary}}</div>
253
- {{/if}}
254
+ <table style="width: 100%; border-collapse: collapse;">
255
+ <tr>
256
+ <td>
257
+ <div class="item-title">{{this.title}}</div>
258
+ <div class="item-meta">
259
+ <span style="color: #7c3aed; font-weight: 600;">{{this.type}}</span> • {{this.actor}}
260
+ </div>
261
+ </td>
262
+ <td style="text-align: right; vertical-align: top; font-size: 11px; color: #9ca3af;">
263
+ {{this.time}}
264
+ </td>
265
+ </tr>
266
+ </table>
254
267
  {{#if this.details}}
255
268
  <div class="item-details">
256
- {{#each this.details}}
257
- <div class="detail-row"><strong>{{this.label}}:</strong> {{this.value}}</div>
258
- {{/each}}
269
+ <table class="detail-table">
270
+ <tr>
271
+ {{#each this.details}}
272
+ <td class="detail-cell">
273
+ <div class="detail-label">{{this.label}}</div>
274
+ <div class="detail-value">{{this.value}}</div>
275
+ </td>
276
+ {{/each}}
277
+ </tr>
278
+ </table>
259
279
  </div>
260
280
  {{/if}}
261
281
  {{#if this.view_url}}
262
- <div class="item-link">
263
- <a href="{{this.view_url}}">View in App →</a>
282
+ <div style="margin-top: 6px;">
283
+ <a href="{{this.view_url}}" style="font-size: 11px; color: #7c3aed; text-decoration: none; font-weight: bold;">View Details →</a>
264
284
  </div>
265
285
  {{/if}}
266
286
  </div>
@@ -281,21 +301,36 @@
281
301
  <div class="section-content">
282
302
  {{#each deals}}
283
303
  <div class="item">
284
- <div class="item-title">{{this.title}}</div>
285
- <div class="item-meta">{{this.type}} • {{this.actor}} • {{this.time}}</div>
286
- {{#if this.summary}}
287
- <div class="item-summary">{{this.summary}}</div>
288
- {{/if}}
304
+ <table style="width: 100%; border-collapse: collapse;">
305
+ <tr>
306
+ <td>
307
+ <div class="item-title">{{this.title}}</div>
308
+ <div class="item-meta">
309
+ <span style="color: #7c3aed; font-weight: 600;">{{this.type}}</span> • {{this.actor}}
310
+ </div>
311
+ </td>
312
+ <td style="text-align: right; vertical-align: top; font-size: 11px; color: #9ca3af;">
313
+ {{this.time}}
314
+ </td>
315
+ </tr>
316
+ </table>
289
317
  {{#if this.details}}
290
318
  <div class="item-details">
291
- {{#each this.details}}
292
- <div class="detail-row"><strong>{{this.label}}:</strong> {{this.value}}</div>
293
- {{/each}}
319
+ <table class="detail-table">
320
+ <tr>
321
+ {{#each this.details}}
322
+ <td class="detail-cell">
323
+ <div class="detail-label">{{this.label}}</div>
324
+ <div class="detail-value">{{this.value}}</div>
325
+ </td>
326
+ {{/each}}
327
+ </tr>
328
+ </table>
294
329
  </div>
295
330
  {{/if}}
296
331
  {{#if this.view_url}}
297
- <div class="item-link">
298
- <a href="{{this.view_url}}">View in App →</a>
332
+ <div style="margin-top: 6px;">
333
+ <a href="{{this.view_url}}" style="font-size: 11px; color: #7c3aed; text-decoration: none; font-weight: bold;">View Details →</a>
299
334
  </div>
300
335
  {{/if}}
301
336
  </div>
@@ -316,21 +351,36 @@
316
351
  <div class="section-content">
317
352
  {{#each approvals}}
318
353
  <div class="item">
319
- <div class="item-title">{{this.title}}</div>
320
- <div class="item-meta">{{this.status}} • {{this.actor}} • {{this.time}}</div>
321
- {{#if this.summary}}
322
- <div class="item-summary">{{this.summary}}</div>
323
- {{/if}}
354
+ <table style="width: 100%; border-collapse: collapse;">
355
+ <tr>
356
+ <td>
357
+ <div class="item-title">{{this.title}}</div>
358
+ <div class="item-meta">
359
+ <span style="color: #7c3aed; font-weight: 600;">{{this.status}}</span> • {{this.actor}}
360
+ </div>
361
+ </td>
362
+ <td style="text-align: right; vertical-align: top; font-size: 11px; color: #9ca3af;">
363
+ {{this.time}}
364
+ </td>
365
+ </tr>
366
+ </table>
324
367
  {{#if this.details}}
325
368
  <div class="item-details">
326
- {{#each this.details}}
327
- <div class="detail-row"><strong>{{this.label}}:</strong> {{this.value}}</div>
328
- {{/each}}
369
+ <table class="detail-table">
370
+ <tr>
371
+ {{#each this.details}}
372
+ <td class="detail-cell">
373
+ <div class="detail-label">{{this.label}}</div>
374
+ <div class="detail-value">{{this.value}}</div>
375
+ </td>
376
+ {{/each}}
377
+ </tr>
378
+ </table>
329
379
  </div>
330
380
  {{/if}}
331
381
  {{#if this.view_url}}
332
- <div class="item-link">
333
- <a href="{{this.view_url}}">View in App →</a>
382
+ <div style="margin-top: 6px;">
383
+ <a href="{{this.view_url}}" style="font-size: 11px; color: #7c3aed; text-decoration: none; font-weight: bold;">View Details →</a>
334
384
  </div>
335
385
  {{/if}}
336
386
  </div>
@@ -351,21 +401,33 @@
351
401
  <div class="section-content">
352
402
  {{#each leadsets}}
353
403
  <div class="item">
354
- <div class="item-title">{{this.title}}</div>
355
- <div class="item-meta">{{this.records_count}} records available • {{this.time}}</div>
356
- {{#if this.summary}}
357
- <div class="item-summary">{{this.summary}}</div>
358
- {{/if}}
404
+ <table style="width: 100%; border-collapse: collapse;">
405
+ <tr>
406
+ <td>
407
+ <div class="item-title">{{this.title}}</div>
408
+ <div class="item-meta">
409
+ <span style="color: #7c3aed; font-weight: 600;">{{this.records_count}} records</span> • {{this.time}}
410
+ </div>
411
+ </td>
412
+ </tr>
413
+ </table>
359
414
  {{#if this.details}}
360
415
  <div class="item-details">
361
- {{#each this.details}}
362
- <div class="detail-row"><strong>{{this.label}}:</strong> {{this.value}}</div>
363
- {{/each}}
416
+ <table class="detail-table">
417
+ <tr>
418
+ {{#each this.details}}
419
+ <td class="detail-cell">
420
+ <div class="detail-label">{{this.label}}</div>
421
+ <div class="detail-value">{{this.value}}</div>
422
+ </td>
423
+ {{/each}}
424
+ </tr>
425
+ </table>
364
426
  </div>
365
427
  {{/if}}
366
428
  {{#if this.view_url}}
367
- <div class="item-link">
368
- <a href="{{this.view_url}}">View in App →</a>
429
+ <div style="margin-top: 6px;">
430
+ <a href="{{this.view_url}}" style="font-size: 11px; color: #7c3aed; text-decoration: none; font-weight: bold;">View Details →</a>
369
431
  </div>
370
432
  {{/if}}
371
433
  </div>
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
@@ -41,61 +41,68 @@
41
41
  }
42
42
 
43
43
  .event-card {
44
- background-color: #f5f2e9;
45
- border: 1px solid #7c3aed;
44
+ background-color: #ffffff;
45
+ border: 1px solid #e5e7eb;
46
46
  border-radius: 8px;
47
- padding: 20px;
48
- margin: 20px 0;
47
+ padding: 16px;
48
+ margin: 16px 0;
49
49
  }
50
50
 
51
51
  .event-badge {
52
52
  display: inline-block;
53
- background-color: #7c3aed;
54
- color: #ffffff;
55
- padding: 6px 12px;
56
- border-radius: 20px;
57
- font-size: 12px;
53
+ background-color: #f3f0ff;
54
+ color: #7c3aed;
55
+ padding: 4px 8px;
56
+ border-radius: 4px;
57
+ font-size: 11px;
58
58
  font-weight: bold;
59
59
  text-transform: uppercase;
60
- margin-bottom: 12px;
60
+ margin-bottom: 8px;
61
61
  }
62
62
 
63
63
  .event-title {
64
- font-size: 20px;
64
+ font-size: 18px;
65
65
  font-weight: bold;
66
- color: #0e0d0c;
67
- margin: 10px 0;
68
- }
69
-
70
- .event-summary {
71
- color: #2c2721;
72
- margin: 12px 0;
73
- line-height: 1.6;
66
+ color: #111827;
67
+ margin: 0 0 12px 0;
74
68
  }
75
69
 
76
70
  .event-details {
77
71
  margin-top: 12px;
78
- background-color: #f8f5ff;
72
+ background-color: #f9fafb;
79
73
  border-radius: 6px;
80
74
  padding: 12px;
81
75
  }
82
76
 
83
- .detail-row {
84
- font-size: 14px;
85
- color: #3f2d63;
86
- margin: 6px 0;
77
+ .detail-table {
78
+ width: 100%;
79
+ border-collapse: collapse;
80
+ }
81
+
82
+ .detail-label {
83
+ font-size: 11px;
84
+ color: #6b7280;
85
+ text-transform: uppercase;
86
+ font-weight: bold;
87
+ margin-bottom: 2px;
88
+ }
89
+
90
+ .detail-value {
91
+ font-size: 13px;
92
+ color: #111827;
87
93
  }
88
94
 
89
- .detail-row strong {
90
- color: #2b1d4d;
95
+ .detail-cell {
96
+ padding-right: 16px;
97
+ vertical-align: top;
91
98
  }
92
99
 
93
100
  .event-meta {
94
101
  margin-top: 16px;
95
- padding-top: 16px;
96
- border-top: 1px solid #ebe7db;
97
- font-size: 14px;
98
- color: #5c5545;
102
+ padding-top: 12px;
103
+ border-top: 1px solid #f3f4f6;
104
+ font-size: 12px;
105
+ color: #6b7280;
99
106
  }
100
107
 
101
108
  .event-meta strong {
@@ -144,23 +151,28 @@
144
151
  <img src="https://assets.heliyos.ai/heliyos-logo-white.png" alt="Heliyos AI">
145
152
  </div>
146
153
  <div class="content">
147
- <p>Hello,</p>
154
+ <p>Hello {{first_name}},</p>
148
155
  <p>You have a new update in your Heliyos workspace:</p>
149
156
 
150
157
  <div class="event-card">
151
158
  <div class="event-badge">{{event_type_label}}</div>
152
159
  <div class="event-title">{{object_name}}</div>
153
- <div class="event-summary">{{summary}}</div>
154
160
  {{#if details}}
155
161
  <div class="event-details">
156
- {{#each details}}
157
- <div class="detail-row"><strong>{{this.label}}:</strong> {{this.value}}</div>
158
- {{/each}}
162
+ <table class="detail-table">
163
+ <tr>
164
+ {{#each details}}
165
+ <td class="detail-cell">
166
+ <div class="detail-label">{{this.label}}</div>
167
+ <div class="detail-value">{{this.value}}</div>
168
+ </td>
169
+ {{/each}}
170
+ </tr>
171
+ </table>
159
172
  </div>
160
173
  {{/if}}
161
174
  <div class="event-meta">
162
- <strong>By:</strong> {{actor_name}}<br>
163
- <strong>When:</strong> {{timestamp}}
175
+ <strong>By:</strong> {{actor_name}}<strong>When:</strong> {{timestamp}}
164
176
  </div>
165
177
  </div>
166
178
 
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {
@@ -80,7 +80,7 @@
80
80
  </div>
81
81
  <div class="content">
82
82
  <h2 style="margin-top: 0; color: #0e0d0c;">Confirm Your Email Address</h2>
83
- <p>Hello,</p>
83
+ <p>Hello {{first_name}},</p>
84
84
  <p>Thank you for signing up for Heliyos AI! To complete your registration and verify your email address, please click the
85
85
  button below:</p>
86
86
  <p style="text-align: center;">
@@ -19,9 +19,9 @@
19
19
  max-width: 600px;
20
20
  margin: 20px auto;
21
21
  background-color: #ffffff;
22
+ border: 2px solid #7c3aed;
22
23
  border-radius: 12px;
23
24
  overflow: hidden;
24
- box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
25
25
  }
26
26
 
27
27
  .header {