diff --git a/emails/blog-update.tsx b/emails/blog-update.tsx index 8e92f09..674bcbe 100644 --- a/emails/blog-update.tsx +++ b/emails/blog-update.tsx @@ -11,7 +11,7 @@ import { getAsset, registerAsset, WATcloudURI } from "../utils/watcloud-uri"; import { WATcloudEmail } from "./_common/watcloud-email"; const WATcloudBlogUpdateEmailProps = z.object({ - path: z.string(), + url: z.string().url(), title: z.string(), author: z.string(), date: z.string(), @@ -26,7 +26,7 @@ export function init({ image }: WATcloudBlogUpdateEmailProps) { } export function WATcloudBlogUpdateEmail(props: WATcloudBlogUpdateEmailProps) { - const { path, title, author, date, abstract, image } = WATcloudBlogUpdateEmailProps.parse(props); + const { url, title, author, date, abstract, image } = WATcloudBlogUpdateEmailProps.parse(props); if (process.env.NODE_ENV === "development") { init(props); @@ -34,8 +34,6 @@ export function WATcloudBlogUpdateEmail(props: WATcloudBlogUpdateEmailProps) { const previewText = `New WATcloud Blog Post: ${title}`; - const link = `https://cloud.watonomous.ca/blog/${path}`; - const imageSrc = getAsset(image).resolveFromCache(); return ( @@ -43,14 +41,14 @@ export function WATcloudBlogUpdateEmail(props: WATcloudBlogUpdateEmailProps) { Hello! WATcloud has published a new blog post.
{title} - + {title} By {author} on {date} {abstract} - Read more → + Read more →
You are receiving this email because you are subscribed to the WATcloud blog. @@ -58,7 +56,7 @@ export function WATcloudBlogUpdateEmail(props: WATcloudBlogUpdateEmailProps) { }; WATcloudBlogUpdateEmail.PreviewProps = { - path: "what-is-watcloud", + url: "https://cloud.watonomous.ca/blog/what-is-watcloud", title: "Under the Hood: What is WATcloud?", author: "Ben Zhang", date: "Sunday, September 22, 2024",