(error: string, chatUrl: string)
| 296 | } |
| 297 | |
| 298 | async function renderErrorHtml(error: string, chatUrl: string): Promise<string> { |
| 299 | const html = await render( |
| 300 | createElement( |
| 301 | InboxResponseEmail, |
| 302 | { chatUrl, linkLabel: 'View details' }, |
| 303 | createElement( |
| 304 | Text, |
| 305 | { key: 'message', style: markdownStyles.p }, |
| 306 | "I wasn't able to complete this task." |
| 307 | ), |
| 308 | createElement( |
| 309 | Text, |
| 310 | { key: 'error', style: { ...markdownStyles.p, color: '#6b7280' } }, |
| 311 | `Error: ${error}` |
| 312 | ) |
| 313 | ) |
| 314 | ) |
| 315 | |
| 316 | return stripUnsafeUrls(html) |
| 317 | } |
no test coverage detected