import { Table, TBody, TR, TD } from "oy-vey";
import * as React from "react";
import theme from "@shared/styles/theme";
const EmailLayout: React.FC<{
bgcolor?: string;
previewText: string;
goToAction?: { url: string; name: string };
}> = ({ previewText, bgcolor = "#FFFFFF", goToAction, children }) => {
let markup;
if (goToAction) {
markup = JSON.stringify({
"@context": "http://schema.org",
"@type": "EmailMessage",
potentialAction: {
"@type": "ViewAction",
url: goToAction.url,
name: goToAction.name,
},
});
}
return (
<>
{markup ? (
) : null}
>
);
};
export default EmailLayout;
export const baseStyles = `
#__bodyTable__ {
font-family: ${theme.fontFamily};
font-size: 16px;
line-height: 1.5;
}
`;