Skip to content

Open-source status page, incident response and uptime monitoring

fix: email

Maximilian Kaskebde046350c75
diff --git a/packages/emails/emails/monitor-alert.tsx b/packages/emails/emails/monitor-alert.tsx
index 90e204661..1541da5eb 100644
--- a/packages/emails/emails/monitor-alert.tsx
+++ b/packages/emails/emails/monitor-alert.tsx
@@ -2,14 +2,11 @@
import {
Body,
- Button,
CodeInline,
Column,
- Container,
Head,
Heading,
Html,
- Img,
Link,
Preview,
Row,
@@ -62,19 +59,6 @@ const MonitorAlertEmail = (props: MonitorAlertProps) => (
<Preview>Your monitor's status is: {props.type}</Preview>
<Body style={styles.main}>
<Layout>
- <Container
- style={{
- backgroundColor: getIcon(props.type).color,
- display: "flex",
- alignItems: "center",
- justifyContent: "center",
- width: "40px",
- height: "40px",
- borderRadius: "50%",
- }}
- >
- <Img src={getIcon(props.type).src} width="24" height="24" />
- </Container>
<Row>
<Column>
<Heading as="h4">{props.name}</Heading>
@@ -126,6 +110,16 @@ const MonitorAlertEmail = (props: MonitorAlertProps) => (
<Text>{props.region}</Text>
</Column>
</Row>
+ {props.latency ? (
+ <Row style={styles.row}>
+ <Column>
+ <Text style={styles.bold}>Latency</Text>
+ </Column>
+ <Column style={{ textAlign: "right" }}>
+ <Text>{props.latency}</Text>
+ </Column>
+ </Row>
+ ) : null}
<Row style={styles.row}>
<Column>
<Text style={styles.bold}>Timestamp</Text>
diff --git a/packages/emails/src/client.tsx b/packages/emails/src/client.tsx
index 07a0ae57c..0363e8cc9 100644
--- a/packages/emails/src/client.tsx
+++ b/packages/emails/src/client.tsx
@@ -51,7 +51,7 @@ export class EmailClient {
const html = await render(<StatusReportEmail {...req} />);
const result = await this.client.batch.send(
req.to.map((subscriber) => ({
- from: `${req.pageTitle} <[email protected]>`,
+ from: `${req.pageTitle} <[email protected]>`,
subject: req.reportTitle,
to: subscriber,
html,
@@ -78,7 +78,7 @@ export class EmailClient {
try {
const html = await render(<TeamInvitationEmail {...req} />);
const result = await this.client.emails.send({
- from: `${req.workspaceName ?? "OpenStatus"} <[email protected]>`,
+ from: `${req.workspaceName ?? "OpenStatus"} <[email protected]>`,
subject: `You've been invited to join ${req.workspaceName ?? "OpenStatus"}`,
to: req.to,
html,
@@ -101,7 +101,7 @@ export class EmailClient {
try {
const html = await render(<MonitorAlertEmail {...req} />);
const result = await this.client.emails.send({
- from: "OpenStatus <[email protected]>",
+ from: "OpenStatus <[email protected]>",
subject: `${req.name}: ${req.type.toUpperCase()}`,
to: req.to,
html,
@@ -126,8 +126,8 @@ export class EmailClient {
try {
const html = await render(<PageSubscriptionEmail {...req} />);
const result = await this.client.emails.send({
- from: `${req.page} <[email protected]>`,
- subject: "Status page subscription",
+ from: "Status Page <[email protected]>",
+ subject: `Confirm your subscription to ${req.page}`,
to: req.to,
html,
});