Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
diboune committed Oct 23, 2024
1 parent 4f7c228 commit 9783f7b
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 8 deletions.
7 changes: 4 additions & 3 deletions backend/src/api/store/email/_templates/order-confirmation.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { BigNumberValue, OrderDTO } from "@medusajs/framework/types";
import { Heading, Section } from "@react-email/components";
import { Heading, Img, Section } from "@react-email/components";
import Cart from "./components/cart";
import EmailBody from "./components/email-body";
import Layout from "./components/layout";
Expand All @@ -18,8 +18,9 @@ export default function OrderConfirmation({ order }: { order: OrderDTO }) {

return (
<Layout preview="Order confirmation">
<Section className="w-full px-5 mt-32 mb-10" align="left">
<Heading className="pb-3" style={title}>
<Section className="w-full px-5 mb-12" align="left">
<Img src="https://cdn.sanity.io/images/1wtf7iqx/production/e04b80a29759293982d74afcde82a169505a3aaa-1166x112.png" />
<Heading className="mb-3 mt-20" style={title}>
Thank you for your order!
</Heading>
<EmailBody
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
import { Heading, Section } from "@react-email/components";
import { Heading, Img, Section } from "@react-email/components";
import EmailBody from "./components/email-body";
import Layout from "./components/layout";
import { title } from "./components/style";

export default function ShippingConfirmation() {
return (
<Layout preview="Shipping confirmation">
<Section className="w-full max-w-[565px] px-5 my-20" align="left">
<Heading className="pb-3" style={title}>
<Section className="w-full max-w-[565px] mb-16 px-5" align="left">
<Img src="https://cdn.sanity.io/images/1wtf7iqx/production/e04b80a29759293982d74afcde82a169505a3aaa-1166x112.png" />
<Heading className="mb-3 mt-16" style={title}>
Your order is on its way!
</Heading>
<EmailBody
Expand Down
8 changes: 6 additions & 2 deletions backend/src/api/store/email/_templates/welcome.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ProductDTO } from "@medusajs/framework/types";
import { Heading, Section } from "@react-email/components";
import { Heading, Img, Section } from "@react-email/components";
import EmailBody from "./components/email-body";
import Layout from "./components/layout";
import ProductsList from "./components/products-list";
Expand All @@ -8,7 +8,11 @@ import { title } from "./components/style";
export default function Welcome({ products }: { products: ProductDTO[] }) {
return (
<Layout preview="Welcome to Munchies!">
<Section className="w-full max-w-[565px] px-5 my-20" align="left">
<Section className="w-full px-5 my-20" align="left">
<Img
src="https://cdn.sanity.io/images/1wtf7iqx/production/0ebbdf446bb2d4e4287c722fb82fe385d13d6dea-2400x1260.png"
className="rounded-lg mb-8"
/>
<Heading className="pb-3" style={title}>
Get ready for some sweet! 🍪
</Heading>
Expand Down
2 changes: 2 additions & 0 deletions storefront/actions/newsletter/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ export async function newsletterForm(
}),
headers: {
"Content-Type": "application/json",
"X-Publishable-Api-Key":
process.env.NEXT_PUBLIC_MEDUSA_PUBLISHABLE_KEY!,
},
method: "post",
},
Expand Down

0 comments on commit 9783f7b

Please sign in to comment.