Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

6658 workflows add a first twenty piece email sender #6965

Merged
merged 24 commits into from
Sep 12, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Remove logo from workflow email
  • Loading branch information
martmull committed Sep 10, 2024
commit 452824286b5da4cc6652e77b81bd994cbbadb8e5
9 changes: 7 additions & 2 deletions packages/twenty-emails/src/components/BaseEmail.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,19 @@ import { Logo } from 'src/components/Logo';

type BaseEmailProps = PropsWithChildren<{
width?: number;
withLogo?: boolean;
}>;

export const BaseEmail = ({ children, width }: BaseEmailProps) => {
export const BaseEmail = ({
children,
width,
withLogo = true,
}: BaseEmailProps) => {
return (
<Html lang="en">
<BaseHead />
<Container width={width || 290}>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

style: Consider making default width a named constant for better maintainability

<Logo />
{withLogo && <Logo />}
{children}
</Container>
</Html>
Expand Down
2 changes: 1 addition & 1 deletion packages/twenty-emails/src/components/BaseHead.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { emailTheme } from 'src/common-style';
export const BaseHead = () => {
return (
<Head>
<title>Twenty email</title>
<title>An email from Twenty</title>
<Font
fontFamily={emailTheme.font.family}
fallbackFontFamily="sans-serif"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export const WorkflowActionEmail = ({
callToAction,
}: WorkflowActionEmailProps) => {
return (
<BaseEmail>
<BaseEmail withLogo={false}>
{title && <Title value={title} />}
{mainText && <MainText>{mainText}</MainText>}
{callToAction && (
Expand Down
Loading