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 useless changes
  • Loading branch information
martmull committed Sep 11, 2024
commit 2f4a6dec681e4bbbf190855c1ee11d0178a26d2b
9 changes: 2 additions & 7 deletions packages/twenty-emails/src/components/BaseEmail.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,14 @@ import { Logo } from 'src/components/Logo';

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

export const BaseEmail = ({
children,
width,
withLogo = true,
}: BaseEmailProps) => {
export const BaseEmail = ({ children, width }: 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

{withLogo && <Logo />}
<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>An email from Twenty</title>
<title>Twenty email</title>
<Font
fontFamily={emailTheme.font.family}
fallbackFontFamily="sans-serif"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export const WorkflowActionEmail = ({
callToAction,
}: WorkflowActionEmailProps) => {
return (
<BaseEmail withLogo={false}>
<BaseEmail>
{title && <Title value={title} />}
{dangerousHTML && (
<div dangerouslySetInnerHTML={{ __html: dangerousHTML }} />
Expand Down
Loading