@vrplatform/email 1.0.2-40036690490 → 1.0.2-40297686442
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/main/components/ActionEmailTemplate.d.ts +3 -1
- package/build/main/components/ActionEmailTemplate.js +9 -11
- package/build/main/components/ActionEmailTemplate.js.map +1 -1
- package/build/main/components/EmailContainer.js +2 -1
- package/build/main/components/EmailContainer.js.map +1 -1
- package/build/main/components/EmailHeading.d.ts +8 -0
- package/build/main/components/EmailHeading.js +21 -0
- package/build/main/components/EmailHeading.js.map +1 -0
- package/build/main/components/index.d.ts +1 -0
- package/build/main/components/index.js +1 -0
- package/build/main/components/index.js.map +1 -1
- package/build/main/index.d.ts +1 -1
- package/build/main/index.js +2 -3
- package/build/main/index.js.map +1 -1
- package/build/main/render.d.ts +2 -0
- package/build/main/render.js +24 -0
- package/build/main/render.js.map +1 -0
- package/build/main/templates/BankAccountChangedEmailTemplate.d.ts +1 -0
- package/build/main/templates/BankAccountChangedEmailTemplate.js +3 -1
- package/build/main/templates/BankAccountChangedEmailTemplate.js.map +1 -1
- package/build/main/templates/BankAccountChangedTeamAdminEmailTemplate.d.ts +1 -0
- package/build/main/templates/BankAccountChangedTeamAdminEmailTemplate.js +1 -1
- package/build/main/templates/BankAccountChangedTeamAdminEmailTemplate.js.map +1 -1
- package/build/main/templates/BankDetailsRequestEmailTemplate.d.ts +2 -1
- package/build/main/templates/BankDetailsRequestEmailTemplate.js +1 -1
- package/build/main/templates/BankDetailsRequestEmailTemplate.js.map +1 -1
- package/build/main/templates/InviteOwnerEmailTemplate.js +1 -1
- package/build/main/templates/InviteOwnerEmailTemplate.js.map +1 -1
- package/build/main/templates/InvitePmEmailTemplate.js +1 -1
- package/build/main/templates/InvitePmEmailTemplate.js.map +1 -1
- package/build/main/templates/OwnerStatementEmailTemplate.d.ts +0 -2
- package/build/main/templates/OwnerStatementEmailTemplate.js +16 -37
- package/build/main/templates/OwnerStatementEmailTemplate.js.map +1 -1
- package/build/main/templates/TenantDeletionEmailTemplate.js +2 -6
- package/build/main/templates/TenantDeletionEmailTemplate.js.map +1 -1
- package/build/main/templates/TenantSuspensionEmailTemplate.js +2 -6
- package/build/main/templates/TenantSuspensionEmailTemplate.js.map +1 -1
- package/build/module/components/ActionEmailTemplate.d.ts +3 -1
- package/build/module/components/ActionEmailTemplate.js +9 -11
- package/build/module/components/ActionEmailTemplate.js.map +1 -1
- package/build/module/components/EmailContainer.js +2 -1
- package/build/module/components/EmailContainer.js.map +1 -1
- package/build/module/components/EmailHeading.d.ts +8 -0
- package/build/module/components/EmailHeading.js +17 -0
- package/build/module/components/EmailHeading.js.map +1 -0
- package/build/module/components/index.d.ts +1 -0
- package/build/module/components/index.js +1 -0
- package/build/module/components/index.js.map +1 -1
- package/build/module/index.d.ts +1 -1
- package/build/module/index.js +1 -1
- package/build/module/index.js.map +1 -1
- package/build/module/render.d.ts +2 -0
- package/build/module/render.js +20 -0
- package/build/module/render.js.map +1 -0
- package/build/module/templates/BankAccountChangedEmailTemplate.d.ts +1 -0
- package/build/module/templates/BankAccountChangedEmailTemplate.js +3 -1
- package/build/module/templates/BankAccountChangedEmailTemplate.js.map +1 -1
- package/build/module/templates/BankAccountChangedTeamAdminEmailTemplate.d.ts +1 -0
- package/build/module/templates/BankAccountChangedTeamAdminEmailTemplate.js +2 -2
- package/build/module/templates/BankAccountChangedTeamAdminEmailTemplate.js.map +1 -1
- package/build/module/templates/BankDetailsRequestEmailTemplate.d.ts +2 -1
- package/build/module/templates/BankDetailsRequestEmailTemplate.js +1 -1
- package/build/module/templates/BankDetailsRequestEmailTemplate.js.map +1 -1
- package/build/module/templates/InviteOwnerEmailTemplate.js +1 -1
- package/build/module/templates/InviteOwnerEmailTemplate.js.map +1 -1
- package/build/module/templates/InvitePmEmailTemplate.js +1 -1
- package/build/module/templates/InvitePmEmailTemplate.js.map +1 -1
- package/build/module/templates/OwnerStatementEmailTemplate.d.ts +0 -2
- package/build/module/templates/OwnerStatementEmailTemplate.js +16 -37
- package/build/module/templates/OwnerStatementEmailTemplate.js.map +1 -1
- package/build/module/templates/TenantDeletionEmailTemplate.js +3 -7
- package/build/module/templates/TenantDeletionEmailTemplate.js.map +1 -1
- package/build/module/templates/TenantSuspensionEmailTemplate.js +3 -7
- package/build/module/templates/TenantSuspensionEmailTemplate.js.map +1 -1
- package/package.json +1 -1
- package/src/components/ActionEmailTemplate.tsx +11 -13
- package/src/components/EmailContainer.tsx +2 -1
- package/src/components/EmailHeading.tsx +36 -0
- package/src/components/index.ts +1 -0
- package/src/index.ts +1 -1
- package/src/render.ts +24 -0
- package/src/templates/BankAccountChangedEmailTemplate.tsx +23 -9
- package/src/templates/BankAccountChangedTeamAdminEmailTemplate.tsx +11 -5
- package/src/templates/BankDetailsRequestEmailTemplate.tsx +5 -1
- package/src/templates/InviteOwnerEmailTemplate.tsx +1 -0
- package/src/templates/InvitePmEmailTemplate.tsx +1 -0
- package/src/templates/OwnerStatementEmailTemplate.tsx +19 -50
- package/src/templates/TenantDeletionEmailTemplate.tsx +9 -10
- package/src/templates/TenantSuspensionEmailTemplate.tsx +9 -10
|
@@ -12,4 +12,6 @@ export type ActionEmailData = {
|
|
|
12
12
|
export interface ActionEmailTemplateProps extends EmailBaseProps {
|
|
13
13
|
data: ActionEmailData;
|
|
14
14
|
}
|
|
15
|
-
export declare const ActionEmailTemplate: ({ data, tenant, themeColors, mode, user, listing, month, unsubscribeHref, }: ActionEmailTemplateProps
|
|
15
|
+
export declare const ActionEmailTemplate: ({ data, eyebrow, tenant, themeColors, mode, user, listing, month, unsubscribeHref, }: ActionEmailTemplateProps & {
|
|
16
|
+
eyebrow: string;
|
|
17
|
+
}) => import("react").JSX.Element;
|
|
@@ -2,21 +2,19 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ActionEmailTemplate = void 0;
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
-
const heading_1 = require("@react-email/heading");
|
|
6
5
|
const text_1 = require("@react-email/text");
|
|
7
6
|
const EmailContainer_1 = require("./EmailContainer");
|
|
7
|
+
const EmailHeading_1 = require("./EmailHeading");
|
|
8
8
|
const utils_1 = require("./utils");
|
|
9
9
|
const Button_1 = require("./Button");
|
|
10
|
-
const ActionEmailTemplate = ({ data, tenant, themeColors, mode, user, listing, month, unsubscribeHref, }) => {
|
|
11
|
-
return ((0, jsx_runtime_1.jsxs)(EmailContainer_1.EmailContainer, { title: data.subject, shortDescription: data.shortDescription, tenant: tenant, mode: mode, unsubscribeHref: unsubscribeHref, children: [(0, jsx_runtime_1.jsx)(
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}, children: data.header?.trim() || `Welcome to ${tenant.name}!` }), data.banner?.trim() && ((0, jsx_runtime_1.jsx)(text_1.Text, { style: {
|
|
16
|
-
padding: '24px',
|
|
17
|
-
backgroundColor: '#f2f3f3',
|
|
10
|
+
const ActionEmailTemplate = ({ data, eyebrow, tenant, themeColors, mode, user, listing, month, unsubscribeHref, }) => {
|
|
11
|
+
return ((0, jsx_runtime_1.jsxs)(EmailContainer_1.EmailContainer, { title: data.subject, shortDescription: data.shortDescription, tenant: tenant, mode: mode, unsubscribeHref: unsubscribeHref, children: [(0, jsx_runtime_1.jsx)(EmailHeading_1.EmailHeading, { eyebrow: eyebrow, themeColors: themeColors, children: data.header?.trim() || `Welcome to ${tenant.name}!` }), data.banner?.trim() && ((0, jsx_runtime_1.jsx)(text_1.Text, { style: {
|
|
12
|
+
padding: '16px 20px',
|
|
13
|
+
backgroundColor: '#f8f9fa',
|
|
14
|
+
borderLeft: `3px solid ${themeColors[8]}`,
|
|
18
15
|
borderRadius: '4px',
|
|
19
|
-
|
|
16
|
+
margin: '0 0 32px',
|
|
17
|
+
whiteSpace: 'pre-line',
|
|
20
18
|
}, children: data.banner.trim() })), (0, jsx_runtime_1.jsx)("div", {
|
|
21
19
|
// biome-ignore lint/security/noDangerouslySetInnerHtml: <explanation>
|
|
22
20
|
dangerouslySetInnerHTML: {
|
|
@@ -26,7 +24,7 @@ const ActionEmailTemplate = ({ data, tenant, themeColors, mode, user, listing, m
|
|
|
26
24
|
date: month || '',
|
|
27
25
|
listingName: listing || '',
|
|
28
26
|
}),
|
|
29
|
-
} }), (0, jsx_runtime_1.jsx)(Button_1.Button, { href: data.href, mode: mode, "data-testid": "accept-invite-button", label: data.buttonText?.trim() || 'Accept Invitation', themeColors: themeColors }), (0, jsx_runtime_1.jsx)("div", {
|
|
27
|
+
} }), (0, jsx_runtime_1.jsx)(Button_1.Button, { href: data.href, mode: mode, "data-testid": "accept-invite-button", label: data.buttonText?.trim() || 'Accept Invitation', themeColors: themeColors, style: { marginTop: '24px', marginBottom: '32px' } }), (0, jsx_runtime_1.jsx)("div", {
|
|
30
28
|
// biome-ignore lint/security/noDangerouslySetInnerHtml: <explanation>
|
|
31
29
|
dangerouslySetInnerHTML: {
|
|
32
30
|
__html: (0, utils_1.parseEmailHtml)(data.bodyTwo, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ActionEmailTemplate.js","sourceRoot":"src/","sources":["components/ActionEmailTemplate.tsx"],"names":[],"mappings":";;;;AAAA,
|
|
1
|
+
{"version":3,"file":"ActionEmailTemplate.js","sourceRoot":"src/","sources":["components/ActionEmailTemplate.tsx"],"names":[],"mappings":";;;;AAAA,4CAAyC;AACzC,qDAAkD;AAClD,iDAA8C;AAE9C,mCAAyC;AACzC,qCAAkC;AAiB3B,MAAM,mBAAmB,GAAG,CAAC,EAClC,IAAI,EACJ,OAAO,EACP,MAAM,EACN,WAAW,EACX,IAAI,EACJ,IAAI,EACJ,OAAO,EACP,KAAK,EACL,eAAe,GACgC,EAAE,EAAE;IACnD,OAAO,CACL,wBAAC,+BAAc,IACb,KAAK,EAAE,IAAI,CAAC,OAAO,EACnB,gBAAgB,EAAE,IAAI,CAAC,gBAAgB,EACvC,MAAM,EAAE,MAAM,EACd,IAAI,EA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CAAC,SAAS,IAAI,EAAE;wBAC9B,IAAI,EAAE,KAAK,IAAI,EAAE;wBACjB,WAAW,EAAE,OAAO,IAAI,EAAE;qBAC3B,CAAC;iBACH,GACD,IACa,CAClB,CAAC;AACJ,CAAC,CAAC;AAxEW,QAAA,mBAAmB,uBAwE9B","sourcesContent":["import { Text } from '@react-email/text';\nimport { EmailContainer } from './EmailContainer';\nimport { EmailHeading } from './EmailHeading';\nimport type { EmailBaseProps } from '../types';\nimport { parseEmailHtml } from './utils';\nimport { Button } from './Button';\n\nexport type ActionEmailData = {\n subject: string;\n shortDescription: string;\n banner?: string;\n header: string;\n bodyOne: string;\n bodyTwo: string;\n href: string;\n buttonText: string;\n};\n\nexport interface ActionEmailTemplateProps extends EmailBaseProps {\n data: ActionEmailData;\n}\n\nexport const ActionEmailTemplate = ({\n data,\n eyebrow,\n tenant,\n themeColors,\n mode,\n user,\n listing,\n month,\n unsubscribeHref,\n}: ActionEmailTemplateProps & { eyebrow: string }) => {\n return (\n <EmailContainer\n title={data.subject}\n shortDescription={data.shortDescription}\n tenant={tenant}\n mode={mode}\n unsubscribeHref={unsubscribeHref}\n >\n <EmailHeading eyebrow={eyebrow} themeColors={themeColors}>\n {data.header?.trim() || `Welcome to ${tenant.name}!`}\n </EmailHeading>\n\n {data.banner?.trim() && (\n <Text\n style={{\n padding: '16px 20px',\n backgroundColor: '#f8f9fa',\n borderLeft: `3px solid ${themeColors[8]}`,\n borderRadius: '4px',\n margin: '0 0 32px',\n whiteSpace: 'pre-line',\n }}\n >\n {data.banner.trim()}\n </Text>\n )}\n\n <div\n // biome-ignore lint/security/noDangerouslySetInnerHtml: <explanation>\n dangerouslySetInnerHTML={{\n __html: parseEmailHtml(data.bodyOne, {\n href: data.href,\n userName: user.firstName || '',\n date: month || '',\n listingName: listing || '',\n }),\n }}\n />\n\n <Button\n href={data.href}\n mode={mode}\n data-testid=\"accept-invite-button\"\n label={data.buttonText?.trim() || 'Accept Invitation'}\n themeColors={themeColors}\n style={{ marginTop: '24px', marginBottom: '32px' }}\n />\n\n <div\n // biome-ignore lint/security/noDangerouslySetInnerHtml: <explanation>\n dangerouslySetInnerHTML={{\n __html: parseEmailHtml(data.bodyTwo, {\n href: data.href,\n userName: user.firstName || '',\n date: month || '',\n listingName: listing || '',\n }),\n }}\n />\n </EmailContainer>\n );\n};\n"]}
|
|
@@ -11,6 +11,7 @@ const img_1 = require("@react-email/img");
|
|
|
11
11
|
const preview_1 = require("@react-email/preview");
|
|
12
12
|
const text_1 = require("@react-email/text");
|
|
13
13
|
const utils_1 = require("@vrplatform/utils");
|
|
14
|
+
const const_1 = require("../const");
|
|
14
15
|
const EmailContainer = (props) => {
|
|
15
16
|
const { children, shortDescription, title } = props;
|
|
16
17
|
const contentWrapperStyle = {
|
|
@@ -41,7 +42,7 @@ const Content = ({ children, tenant: { logo: tenantLogo, name, showPlatformBrand
|
|
|
41
42
|
display: 'flex',
|
|
42
43
|
justifyContent: 'center',
|
|
43
44
|
alignItems: 'center',
|
|
44
|
-
}, children: (0, jsx_runtime_1.jsx)(img_1.Img, { src: tenantLogo, alt: 'Logo', width: 70 }) })) : !showPlatformBranding ? ((0, jsx_runtime_1.jsx)(text_1.Text, { children: name })) : mode === 'send' ? ((0, jsx_runtime_1.jsx)(img_1.Img, { src:
|
|
45
|
+
}, children: (0, jsx_runtime_1.jsx)(img_1.Img, { src: tenantLogo, alt: 'Logo', width: 70 }) })) : !showPlatformBranding ? ((0, jsx_runtime_1.jsx)(text_1.Text, { children: name })) : mode === 'send' ? ((0, jsx_runtime_1.jsx)(img_1.Img, { src: `${const_1.VRP_PLATFORM.portal}/logo.png`, alt: 'Logo', width: 70, style: { marginBottom: '60px' } })) : ((0, jsx_runtime_1.jsx)("div", { style: {
|
|
45
46
|
width: '60px',
|
|
46
47
|
}, children: (0, jsx_runtime_1.jsx)(VrpLogo, {}) })), children, showPlatformBranding ? (0, jsx_runtime_1.jsx)(Footer, {}) : (0, jsx_runtime_1.jsx)(text_1.Text, { children: name }), unsubscribeHref && ((0, jsx_runtime_1.jsx)(text_1.Text, { style: { color: '#737373' }, children: (0, jsx_runtime_1.jsx)("a", { href: unsubscribeHref, style: { color: '#737373' }, children: "Unsubscribe from owner statement emails" }) }))] }));
|
|
47
48
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EmailContainer.js","sourceRoot":"src/","sources":["components/EmailContainer.tsx"],"names":[],"mappings":";;;;AAAA,4CAAyC;AACzC,4CAAyC;AACzC,4CAAyC;AACzC,wCAAqC;AACrC,4CAAyC;AACzC,0CAAuC;AACvC,kDAA+C;AAC/C,4CAAyC;AACzC,6CAAwC;AAYjC,MAAM,cAAc,GAAG,CAAC,KAAY,EAAE,EAAE;IAC7C,MAAM,EAAE,QAAQ,EAAE,gBAAgB,EAAE,KAAK,EAAE,GAAG,KAAK,CAAC;IAEpD,MAAM,mBAAmB,GAAG;QAC1B,aAAa,EAAE,MAAM;QACrB,YAAY,EAAE,MAAM;QACpB,QAAQ,EAAE,OAAO;QACjB,MAAM,EAAE,QAAQ;KACjB,CAAC;IAEF,IAAI,KAAK,CAAC,IAAI,KAAK,MAAM,EAAE,CAAC;QAC1B,OAAO,CACL,gCAAK,KAAK,EAAE,mBAAmB,YAC7B,uBAAC,OAAO,OAAK,KAAK,YAAG,QAAQ,GAAW,GACpC,CACP,CAAC;IACJ,CAAC;IAED,OAAO,CACL,wBAAC,WAAI,IAAC,IAAI,EAAC,IAAI,aACb,wBAAC,WAAI,eACH,4CAAQ,KAAK,GAAS,EACtB,uBAAC,WAAI,IACH,UAAU,EAAC,OAAO,EAClB,kBAAkB,EAAC,SAAS,EAC5B,OAAO,EAAE;4BACP,GAAG,EAAE,wFAAwF;4BAC7F,MAAM,EAAE,OAAO;yBAChB,EACD,UAAU,EAAE,GAAG,EACf,SAAS,EAAC,QAAQ,GAClB,EACF,uBAAC,WAAI,IACH,UAAU,EAAC,OAAO,EAClB,kBAAkB,EAAC,SAAS,EAC5B,OAAO,EA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AAE,EAAE,KAAK,EAAE,SAAS,EAAE,wDAEjD,GACC,CACR,IACA,CACJ,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,MAAM,GAAG,GAAG,EAAE,CAAC,CACnB,6DACE,uBAAC,OAAE,IACD,KAAK,EAAE;gBACL,SAAS,EAAE,MAAM;gBACjB,YAAY,EAAE,MAAM;aACrB,GACD,EAEF,wBAAC,WAAI,IACH,KAAK,EAAE;gBACL,KAAK,EAAE,SAAS;aACjB,wBAEE,IAAA,WAAG,GAAE,CAAC,IAAI,EAAE,8CACV,EACP,uBAAC,WAAI,IACH,KAAK,EAAE;gBACL,KAAK,EAAE,SAAS;aACjB,4IAII,IACN,CACJ,CAAC;AAEF,MAAM,OAAO,GAAG,GAAG,EAAE,CAAC,CACpB,iCACE,KAAK,EAAC,MAAM,EACZ,MAAM,EAAC,MAAM,EACb,OAAO,EAAC,WAAW,EACnB,IAAI,EAAC,MAAM,EACX,KAAK,EAAC,4BAA4B,aAElC,iCACE,CAAC,EAAC,mNAAmN,EACrN,IAAI,EAAC,SAAS,GACd,EACF,iCACE,CAAC,EAAC,gUAAgU,EAClU,IAAI,EAAC,SAAS,EACd,WAAW,EAAC,KAAK,GACjB,EACF,iCACE,CAAC,EAAC,4WAA4W,EAC9W,IAAI,EAAC,SAAS,GACd,IACE,CACP,CAAC","sourcesContent":["import { Body } from '@react-email/body';\nimport { Font } from '@react-email/font';\nimport { Head } from '@react-email/head';\nimport { Hr } from '@react-email/hr';\nimport { Html } from '@react-email/html';\nimport { Img } from '@react-email/img';\nimport { Preview } from '@react-email/preview';\nimport { Text } from '@react-email/text';\nimport { day } from '@vrplatform/utils';\nimport { VRP_PLATFORM } from '../const';\nimport type { EmailBaseProps } from '../types';\n\ntype Props = {\n children: React.ReactNode;\n title: string;\n tenant: Omit<EmailBaseProps['tenant'], 'name'> & { name?: string };\n mode: EmailBaseProps['mode'];\n shortDescription?: string;\n unsubscribeHref?: string;\n};\n\nexport const EmailContainer = (props: Props) => {\n const { children, shortDescription, title } = props;\n\n const contentWrapperStyle = {\n paddingInline: '20px',\n paddingBlock: '10px',\n maxWidth: '500px',\n margin: '0 auto',\n };\n\n if (props.mode !== 'send') {\n return (\n <div style={contentWrapperStyle}>\n <Content {...props}>{children}</Content>\n </div>\n );\n }\n\n return (\n <Html lang=\"en\">\n <Head>\n <title>{title}</title>\n <Font\n fontFamily=\"Inter\"\n fallbackFontFamily=\"Verdana\"\n webFont={{\n url: 'https://fonts.gstatic.com/s/inter/v13/UcC73FwrK3iLTeHuS_fvQtMwCp50KnMa1ZL7W0Q5nw.woff2',\n format: 'woff2',\n }}\n fontWeight={400}\n fontStyle=\"normal\"\n />\n <Font\n fontFamily=\"Inter\"\n fallbackFontFamily=\"Verdana\"\n webFont={{\n url: 'https://fonts.gstatic.com/s/inter/v13/UcC73FwrK3iLTeHuS_fvQtMwCp50KnMa1ZL7W0Q5nw.woff2',\n format: 'woff2',\n }}\n fontWeight={600}\n fontStyle=\"normal\"\n />\n </Head>\n {shortDescription && <Preview>{shortDescription}</Preview>}\n <Body style={contentWrapperStyle}>\n <Content {...props}>{children}</Content>\n </Body>\n </Html>\n );\n};\n\nconst Content = ({\n children,\n tenant: { logo: tenantLogo, name, showPlatformBranding = true },\n mode,\n unsubscribeHref,\n}: Props) => {\n return (\n <>\n {tenantLogo ? (\n <div\n style={{\n marginBottom: '60px',\n padding: '5px',\n // border: '1px solid rgb(233,236,239)',\n borderRadius: '5px',\n width: '80px',\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n }}\n >\n <Img src={tenantLogo} alt={'Logo'} width={70} />\n </div>\n ) : !showPlatformBranding ? (\n <Text>{name}</Text>\n ) : mode === 'send' ? (\n <Img\n src={`${VRP_PLATFORM.portal}/logo.png`}\n alt={'Logo'}\n width={70}\n style={{ marginBottom: '60px' }}\n />\n ) : (\n <div\n style={{\n width: '60px',\n }}\n >\n <VrpLogo />\n </div>\n )}\n\n {children}\n\n {showPlatformBranding ? <Footer /> : <Text>{name}</Text>}\n {unsubscribeHref && (\n <Text style={{ color: '#737373' }}>\n <a href={unsubscribeHref} style={{ color: '#737373' }}>\n Unsubscribe from owner statement emails\n </a>\n </Text>\n )}\n </>\n );\n};\n\nconst Footer = () => (\n <>\n <Hr\n style={{\n marginTop: '30px',\n marginBottom: '50px',\n }}\n />\n\n <Text\n style={{\n color: '#737373',\n }}\n >\n © {day().year()} VR Technologies. All rights reserved.\n </Text>\n <Text\n style={{\n color: '#737373',\n }}\n >\n VR Technologies, LLC, a company incorporated and registered in the United\n States of America with company number 20201965158\n </Text>\n </>\n);\n\nconst VrpLogo = () => (\n <svg\n width=\"100%\"\n height=\"100%\"\n viewBox=\"0 0 28 29\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path\n d=\"M18.2549 8.25161C18.2549 5.89704 20.1636 3.98828 22.5182 3.98828C24.8728 3.98828 26.7815 5.89704 26.7815 8.25161C26.7815 10.6062 24.8728 12.5149 22.5182 12.5149C20.1636 12.5149 18.2549 10.6062 18.2549 8.25161Z\"\n fill=\"#172554\"\n />\n <path\n d=\"M7.02441 8.46593C7.02441 6.01867 9.20858 3.99805 11.6558 3.99805C14.1031 3.99805 15.0558 5.59785 16.5612 7.52728C17.1957 8.34054 20.7921 13.3413 20.7921 13.3413C20.7921 13.3413 21.566 14.6863 21.566 15.7894C21.566 18.5287 17.1993 22.8381 17.1993 22.8381L7.66841 10.6799C7.66841 10.6799 7.02441 10.0502 7.02441 8.46593Z\"\n fill=\"#172554\"\n fillOpacity=\"0.8\"\n />\n <path\n d=\"M1.24707 8.42687C1.24707 5.97961 3.43123 3.95898 5.8785 3.95898C8.32576 3.95898 9.27845 5.55879 10.7839 7.48824C11.4184 8.30147 14.6041 12.4888 16.8247 15.5727C18.3585 17.703 18.474 17.705 18.474 20.3439C18.474 22.9827 15.1592 24.1379 14.1483 24.1914C12.0203 24.304 10.5418 22.4681 10.5418 22.4681L1.89106 10.6408C1.89106 10.6408 1.24707 10.0111 1.24707 8.42687Z\"\n fill=\"#172554\"\n />\n </svg>\n);\n"]}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { EmailBaseProps } from '../types';
|
|
2
|
+
type Props = {
|
|
3
|
+
eyebrow: string;
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
themeColors: EmailBaseProps['themeColors'];
|
|
6
|
+
};
|
|
7
|
+
export declare const EmailHeading: ({ eyebrow, children, themeColors }: Props) => import("react").JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.EmailHeading = void 0;
|
|
4
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
+
const heading_1 = require("@react-email/heading");
|
|
6
|
+
const text_1 = require("@react-email/text");
|
|
7
|
+
const EmailHeading = ({ eyebrow, children, themeColors }) => ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(text_1.Text, { style: {
|
|
8
|
+
color: themeColors[8],
|
|
9
|
+
fontSize: 12,
|
|
10
|
+
fontWeight: 600,
|
|
11
|
+
letterSpacing: '0.08em',
|
|
12
|
+
textTransform: 'uppercase',
|
|
13
|
+
margin: '0 0 8px',
|
|
14
|
+
}, children: eyebrow }), (0, jsx_runtime_1.jsx)(heading_1.Heading, { style: {
|
|
15
|
+
fontSize: 26,
|
|
16
|
+
fontWeight: 600,
|
|
17
|
+
lineHeight: '34px',
|
|
18
|
+
margin: '0 0 32px',
|
|
19
|
+
}, children: children })] }));
|
|
20
|
+
exports.EmailHeading = EmailHeading;
|
|
21
|
+
//# sourceMappingURL=EmailHeading.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"EmailHeading.js","sourceRoot":"src/","sources":["components/EmailHeading.tsx"],"names":[],"mappings":";;;;AAAA,kDAA+C;AAC/C,4CAAyC;AASlC,MAAM,YAAY,GAAG,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAS,EAAE,EAAE,CAAC,CACzE,6DACE,uBAAC,WAAI,IACH,KAAK,EAAE;gBACL,KAAK,EAAE,WAAW,CAAC,CAAC,CAAC;gBACrB,QAAQ,EAAE,EAAE;gBACZ,UAAU,EAAE,GAAG;gBACf,aAAa,EAAE,QAAQ;gBACvB,aAAa,EAAE,WAAW;gBAC1B,MAAM,EAAE,SAAS;aAClB,YAEA,OAAO,GACH,EACP,uBAAC,iBAAO,IACN,KAAK,EAAE;gBACL,QAAQ,EAAE,EAAE;gBACZ,UAAU,EAAE,GAAG;gBACf,UAAU,EAAE,MAAM;gBAClB,MAAM,EAAE,UAAU;aACnB,YAEA,QAAQ,GACD,IACT,CACJ,CAAC;AAzBW,QAAA,YAAY,gBAyBvB","sourcesContent":["import { Heading } from '@react-email/heading';\nimport { Text } from '@react-email/text';\nimport type { EmailBaseProps } from '../types';\n\ntype Props = {\n eyebrow: string;\n children: React.ReactNode;\n themeColors: EmailBaseProps['themeColors'];\n};\n\nexport const EmailHeading = ({ eyebrow, children, themeColors }: Props) => (\n <>\n <Text\n style={{\n color: themeColors[8],\n fontSize: 12,\n fontWeight: 600,\n letterSpacing: '0.08em',\n textTransform: 'uppercase',\n margin: '0 0 8px',\n }}\n >\n {eyebrow}\n </Text>\n <Heading\n style={{\n fontSize: 26,\n fontWeight: 600,\n lineHeight: '34px',\n margin: '0 0 32px',\n }}\n >\n {children}\n </Heading>\n </>\n);\n"]}
|
|
@@ -16,4 +16,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./EmailContainer"), exports);
|
|
18
18
|
__exportStar(require("./ActionEmailTemplate"), exports);
|
|
19
|
+
__exportStar(require("./EmailHeading"), exports);
|
|
19
20
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"src/","sources":["components/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,mDAAiC;AACjC,wDAAsC","sourcesContent":["export * from './EmailContainer';\nexport * from './ActionEmailTemplate';\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"src/","sources":["components/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,mDAAiC;AACjC,wDAAsC;AACtC,iDAA+B","sourcesContent":["export * from './EmailContainer';\nexport * from './ActionEmailTemplate';\nexport * from './EmailHeading';\n"]}
|
package/build/main/index.d.ts
CHANGED
package/build/main/index.js
CHANGED
|
@@ -14,13 +14,12 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
exports.
|
|
17
|
+
exports.VRP_PLATFORM = void 0;
|
|
18
18
|
__exportStar(require("./templates"), exports);
|
|
19
19
|
__exportStar(require("./utils"), exports); // send email utils
|
|
20
20
|
__exportStar(require("./theme"), exports);
|
|
21
21
|
__exportStar(require("./extensions"), exports);
|
|
22
22
|
var const_1 = require("./const");
|
|
23
23
|
Object.defineProperty(exports, "VRP_PLATFORM", { enumerable: true, get: function () { return const_1.VRP_PLATFORM; } });
|
|
24
|
-
|
|
25
|
-
Object.defineProperty(exports, "render", { enumerable: true, get: function () { return render_1.render; } });
|
|
24
|
+
__exportStar(require("./render"), exports);
|
|
26
25
|
//# sourceMappingURL=index.js.map
|
package/build/main/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"src/","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,8CAA4B;AAC5B,0CAAwB,CAAC,mBAAmB;AAC5C,0CAAwB;AACxB,+CAA6B;AAC7B,iCAAuC;AAA9B,qGAAA,YAAY,OAAA;AAGrB,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"src/","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,8CAA4B;AAC5B,0CAAwB,CAAC,mBAAmB;AAC5C,0CAAwB;AACxB,+CAA6B;AAC7B,iCAAuC;AAA9B,qGAAA,YAAY,OAAA;AAGrB,2CAAyB","sourcesContent":["export * from './templates';\nexport * from './utils'; // send email utils\nexport * from './theme';\nexport * from './extensions';\nexport { VRP_PLATFORM } from './const';\nexport type { ActionEmailData } from './components';\n\nexport * from './render';\n"]}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.render = void 0;
|
|
4
|
+
const render_1 = require("@react-email/render");
|
|
5
|
+
// html-to-text uppercases headings by default, so the plain-text part of an
|
|
6
|
+
// email opened "HI THERE," (PRO-19711). Headings keep their case.
|
|
7
|
+
const render = (component, options) => (0, render_1.render)(component, options?.plainText
|
|
8
|
+
? {
|
|
9
|
+
...options,
|
|
10
|
+
htmlToTextOptions: {
|
|
11
|
+
...options.htmlToTextOptions,
|
|
12
|
+
selectors: [
|
|
13
|
+
...render_1.plainTextSelectors,
|
|
14
|
+
...['h1', 'h2', 'h3', 'h4', 'h5', 'h6'].map((selector) => ({
|
|
15
|
+
selector,
|
|
16
|
+
options: { uppercase: false },
|
|
17
|
+
})),
|
|
18
|
+
...(options.htmlToTextOptions?.selectors ?? []),
|
|
19
|
+
],
|
|
20
|
+
},
|
|
21
|
+
}
|
|
22
|
+
: options);
|
|
23
|
+
exports.render = render;
|
|
24
|
+
//# sourceMappingURL=render.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"render.js","sourceRoot":"src/","sources":["render.ts"],"names":[],"mappings":";;;AAAA,gDAAgF;AAEhF,4EAA4E;AAC5E,kEAAkE;AAC3D,MAAM,MAAM,GAAuB,CAAC,SAAS,EAAE,OAAO,EAAE,EAAE,CAC/D,IAAA,eAAW,EACT,SAAS,EACT,OAAO,EAAE,SAAS;IAChB,CAAC,CAAC;QACE,GAAG,OAAO;QACV,iBAAiB,EAAE;YACjB,GAAG,OAAO,CAAC,iBAAiB;YAC5B,SAAS,EAAE;gBACT,GAAG,2BAAkB;gBACrB,GAAG,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,CAAC;oBACzD,QAAQ;oBACR,OAAO,EAAE,EAAE,SAAS,EAAE,KAAK,EAAE;iBAC9B,CAAC,CAAC;gBACH,GAAG,CAAC,OAAO,CAAC,iBAAiB,EAAE,SAAS,IAAI,EAAE,CAAC;aAChD;SACF;KACF;IACH,CAAC,CAAC,OAAO,CACZ,CAAC;AAnBS,QAAA,MAAM,UAmBf","sourcesContent":["import { plainTextSelectors, render as renderEmail } from '@react-email/render';\n\n// html-to-text uppercases headings by default, so the plain-text part of an\n// email opened \"HI THERE,\" (PRO-19711). Headings keep their case.\nexport const render: typeof renderEmail = (component, options) =>\n renderEmail(\n component,\n options?.plainText\n ? {\n ...options,\n htmlToTextOptions: {\n ...options.htmlToTextOptions,\n selectors: [\n ...plainTextSelectors,\n ...['h1', 'h2', 'h3', 'h4', 'h5', 'h6'].map((selector) => ({\n selector,\n options: { uppercase: false },\n })),\n ...(options.htmlToTextOptions?.selectors ?? []),\n ],\n },\n }\n : options\n );\n"]}
|
|
@@ -6,6 +6,7 @@ export type BankAccountChangedEmailTemplateProps = {
|
|
|
6
6
|
bankAccount: {
|
|
7
7
|
last4: string;
|
|
8
8
|
changedOn: string;
|
|
9
|
+
added: boolean;
|
|
9
10
|
};
|
|
10
11
|
};
|
|
11
12
|
export declare const BankAccountChangedEmailTemplate: ({ mode, user, tenant, bankAccount, }: BankAccountChangedEmailTemplateProps) => import("react").JSX.Element;
|
|
@@ -5,6 +5,8 @@ const jsx_runtime_1 = require("react/jsx-runtime");
|
|
|
5
5
|
const heading_1 = require("@react-email/heading");
|
|
6
6
|
const text_1 = require("@react-email/text");
|
|
7
7
|
const components_1 = require("../components");
|
|
8
|
-
const BankAccountChangedEmailTemplate = ({ mode, user, tenant, bankAccount, }) => ((0, jsx_runtime_1.jsxs)(components_1.EmailContainer, { title:
|
|
8
|
+
const BankAccountChangedEmailTemplate = ({ mode, user, tenant, bankAccount, }) => ((0, jsx_runtime_1.jsxs)(components_1.EmailContainer, { title: bankAccount.added
|
|
9
|
+
? 'Your bank account was added'
|
|
10
|
+
: 'Your bank account was changed', shortDescription: `${tenant.name} now pays you to the account ending in ${bankAccount.last4}.`, tenant: tenant, mode: mode, children: [(0, jsx_runtime_1.jsx)(heading_1.Heading, { style: { fontSize: 28, fontWeight: 600, marginBottom: '50px' }, children: user.firstName ? `Hi ${user.firstName},` : 'Hi there,' }), bankAccount.added ? ((0, jsx_runtime_1.jsxs)(text_1.Text, { children: ["A bank account for payments from ", (0, jsx_runtime_1.jsx)("b", { children: tenant.name }), " was added on", ' ', bankAccount.changedOn, ". Future payments go to the account ending in", ' ', (0, jsx_runtime_1.jsx)("b", { children: bankAccount.last4 }), "."] })) : ((0, jsx_runtime_1.jsxs)(text_1.Text, { children: ["The bank account ", (0, jsx_runtime_1.jsx)("b", { children: tenant.name }), " pays you to was changed on", ' ', bankAccount.changedOn, ". Future payments go to the account ending in", ' ', (0, jsx_runtime_1.jsx)("b", { children: bankAccount.last4 }), ". A payment already on its way still goes to the previous account."] })), (0, jsx_runtime_1.jsxs)(text_1.Text, { children: ["If you did not make or request this", ' ', bankAccount.added ? 'addition' : 'change', ", contact ", tenant.name, " right away."] })] }));
|
|
9
11
|
exports.BankAccountChangedEmailTemplate = BankAccountChangedEmailTemplate;
|
|
10
12
|
//# sourceMappingURL=BankAccountChangedEmailTemplate.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BankAccountChangedEmailTemplate.js","sourceRoot":"src/","sources":["templates/BankAccountChangedEmailTemplate.tsx"],"names":[],"mappings":";;;;AAAA,kDAA+C;AAC/C,4CAAyC;AACzC,8CAA+C;
|
|
1
|
+
{"version":3,"file":"BankAccountChangedEmailTemplate.js","sourceRoot":"src/","sources":["templates/BankAccountChangedEmailTemplate.tsx"],"names":[],"mappings":";;;;AAAA,kDAA+C;AAC/C,4CAAyC;AACzC,8CAA+C;AAWxC,MAAM,+BAA+B,GAAG,CAAC,EAC9C,IAAI,EACJ,IAAI,EACJ,MAAM,EACN,WAAW,GAC0B,EAAE,EAAE,CAAC,CAC1C,wBAAC,2BAAc,IACb,KAAK,EACH,WAAW,CAAC,KAAK;QACf,CAAC,CAAC,6BAA6B;QAC/B,CAAC,CAAC,+BAA+B,EAErC,gBAAgB,EAAE,GAAG,MAAM,CAAC,IAAI,0CAA0C,WAAW,CAAC,KAAK,GAAG,EAC9F,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,IAAI,aAEV,uBAAC,iBAAO,IAAC,KAAK,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE,UAAU,EAAE,GAAG,EAAE,YAAY,EAAE,MAAM,EAAE,YACpE,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,MAAM,IAAI,CAAC,SAAS,GAAG,CAAC,CAAC,CAAC,WAAW,GAC/C,EACT,WAAW,CAAC,KAAK,CAAC,CAAC,CAAC,CACnB,wBAAC,WAAI,oDAC8B,wCAAI,MAAM,CAAC,IAAI,GAAK,mBAAc,GAAG,EACrE,WAAW,CAAC,SAAS,mDAA+C,GAAG,EACxE,wCAAI,WAAW,CAAC,KAAK,GAAK,SACrB,CACR,CAAC,CAAC,CAAC,CACF,wBAAC,WAAI,oCACc,wCAAI,MAAM,CAAC,IAAI,GAAK,iCAA4B,GAAG,EACnE,WAAW,CAAC,SAAS,mDAA+C,GAAG,EACxE,wCAAI,WAAW,CAAC,KAAK,GAAK,0EAErB,CACR,EACD,wBAAC,WAAI,sDACiC,GAAG,EACtC,WAAW,CAAC,KAAK,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,QAAQ,gBAAY,MAAM,CAAC,IAAI,oBAE5D,IACQ,CAClB,CAAC;AAvCW,QAAA,+BAA+B,mCAuC1C","sourcesContent":["import { Heading } from '@react-email/heading';\nimport { Text } from '@react-email/text';\nimport { EmailContainer } from '../components';\nimport type { EmailBaseProps } from '../types';\n\nexport type BankAccountChangedEmailTemplateProps = {\n mode: EmailBaseProps['mode'];\n user: EmailBaseProps['user'];\n tenant: EmailBaseProps['tenant'];\n // Added: the payee had no bank account before.\n bankAccount: { last4: string; changedOn: string; added: boolean };\n};\n\nexport const BankAccountChangedEmailTemplate = ({\n mode,\n user,\n tenant,\n bankAccount,\n}: BankAccountChangedEmailTemplateProps) => (\n <EmailContainer\n title={\n bankAccount.added\n ? 'Your bank account was added'\n : 'Your bank account was changed'\n }\n shortDescription={`${tenant.name} now pays you to the account ending in ${bankAccount.last4}.`}\n tenant={tenant}\n mode={mode}\n >\n <Heading style={{ fontSize: 28, fontWeight: 600, marginBottom: '50px' }}>\n {user.firstName ? `Hi ${user.firstName},` : 'Hi there,'}\n </Heading>\n {bankAccount.added ? (\n <Text>\n A bank account for payments from <b>{tenant.name}</b> was added on{' '}\n {bankAccount.changedOn}. Future payments go to the account ending in{' '}\n <b>{bankAccount.last4}</b>.\n </Text>\n ) : (\n <Text>\n The bank account <b>{tenant.name}</b> pays you to was changed on{' '}\n {bankAccount.changedOn}. Future payments go to the account ending in{' '}\n <b>{bankAccount.last4}</b>. A payment already on its way still goes to\n the previous account.\n </Text>\n )}\n <Text>\n If you did not make or request this{' '}\n {bankAccount.added ? 'addition' : 'change'}, contact {tenant.name} right\n away.\n </Text>\n </EmailContainer>\n);\n"]}
|
|
@@ -7,6 +7,6 @@ const text_1 = require("@react-email/text");
|
|
|
7
7
|
const Button_1 = require("../components/Button");
|
|
8
8
|
const EmailContainer_1 = require("../components/EmailContainer");
|
|
9
9
|
const theme_1 = require("../theme");
|
|
10
|
-
const BankAccountChangedTeamAdminEmailTemplate = ({ mode, tenant, contact, bankAccount, href, }) => ((0, jsx_runtime_1.jsxs)(EmailContainer_1.EmailContainer, { title: `Bank details changed for ${contact.name}`, shortDescription: `Future payments to ${contact.name} go to the account ending in ${bankAccount.last4}.`, tenant: tenant, mode: mode, children: [(0, jsx_runtime_1.
|
|
10
|
+
const BankAccountChangedTeamAdminEmailTemplate = ({ mode, tenant, contact, bankAccount, href, }) => ((0, jsx_runtime_1.jsxs)(EmailContainer_1.EmailContainer, { title: `Bank details ${bankAccount.added ? 'added' : 'changed'} for ${contact.name}`, shortDescription: `Future payments to ${contact.name} go to the account ending in ${bankAccount.last4}.`, tenant: tenant, mode: mode, children: [(0, jsx_runtime_1.jsxs)(heading_1.Heading, { style: { fontSize: 28, fontWeight: 600, marginBottom: '50px' }, children: ["Bank details ", bankAccount.added ? 'added' : 'changed'] }), (0, jsx_runtime_1.jsxs)(text_1.Text, { children: ["The bank account of ", contact.type, " ", (0, jsx_runtime_1.jsx)("b", { children: contact.name }), " was", ' ', bankAccount.added ? 'added' : 'changed', " on ", bankAccount.changedOn, bankAccount.changedBy ? ` by ${bankAccount.changedBy}` : '', ". Future payments go to the account ending in ", (0, jsx_runtime_1.jsx)("b", { children: bankAccount.last4 }), "."] }), (0, jsx_runtime_1.jsxs)(text_1.Text, { children: ["If you did not expect this change, confirm it with ", contact.name, " by phone before the next payment."] }), (0, jsx_runtime_1.jsx)(Button_1.Button, { href: href, mode: mode, label: "Review payment setup", themeColors: theme_1.THEME_COLORS.vrplatform })] }));
|
|
11
11
|
exports.BankAccountChangedTeamAdminEmailTemplate = BankAccountChangedTeamAdminEmailTemplate;
|
|
12
12
|
//# sourceMappingURL=BankAccountChangedTeamAdminEmailTemplate.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BankAccountChangedTeamAdminEmailTemplate.js","sourceRoot":"src/","sources":["templates/BankAccountChangedTeamAdminEmailTemplate.tsx"],"names":[],"mappings":";;;;AAAA,kDAA+C;AAC/C,4CAAyC;AACzC,iDAA8C;AAC9C,iEAA8D;AAC9D,oCAAwC;
|
|
1
|
+
{"version":3,"file":"BankAccountChangedTeamAdminEmailTemplate.js","sourceRoot":"src/","sources":["templates/BankAccountChangedTeamAdminEmailTemplate.tsx"],"names":[],"mappings":";;;;AAAA,kDAA+C;AAC/C,4CAAyC;AACzC,iDAA8C;AAC9C,iEAA8D;AAC9D,oCAAwC;AAiBjC,MAAM,wCAAwC,GAAG,CAAC,EACvD,IAAI,EACJ,MAAM,EACN,OAAO,EACP,WAAW,EACX,IAAI,GAC0C,EAAE,EAAE,CAAC,CACnD,wBAAC,+BAAc,IACb,KAAK,EAAE,gBAAgB,WAAW,CAAC,KAAK,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,SAAS,QAAQ,OAAO,CAAC,IAAI,EAAE,EACpF,gBAAgB,EAAE,sBAAsB,OAAO,CAAC,IAAI,gCAAgC,WAAW,CAAC,KAAK,GAAG,EACxG,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,IAAI,aAEV,wBAAC,iBAAO,IAAC,KAAK,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE,UAAU,EAAE,GAAG,EAAE,YAAY,EAAE,MAAM,EAAE,8BACvD,WAAW,CAAC,KAAK,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,SAAS,IAC7C,EACV,wBAAC,WAAI,uCACkB,OAAO,CAAC,IAAI,OAAE,wCAAI,OAAO,CAAC,IAAI,GAAK,UAAK,GAAG,EAC/D,WAAW,CAAC,KAAK,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,SAAS,UAAM,WAAW,CAAC,SAAS,EAClE,WAAW,CAAC,SAAS,CAAC,CAAC,CAAC,OAAO,WAAW,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,EAAE,oDACvB,wCAAI,WAAW,CAAC,KAAK,GAAK,SAC1D,EACP,wBAAC,WAAI,sEACiD,OAAO,CAAC,IAAI,0CAE3D,EACP,uBAAC,eAAM,IACL,IAAI,EAAE,IAAI,EACV,IAAI,EAAE,IAAI,EACV,KAAK,EAAC,sBAAsB,EAC5B,WAAW,EAAE,oBAAY,CAAC,UAAW,GACrC,IACa,CAClB,CAAC;AAjCW,QAAA,wCAAwC,4CAiCnD","sourcesContent":["import { Heading } from '@react-email/heading';\nimport { Text } from '@react-email/text';\nimport { Button } from '../components/Button';\nimport { EmailContainer } from '../components/EmailContainer';\nimport { THEME_COLORS } from '../theme';\nimport type { EmailBaseProps } from '../types';\n\nexport type BankAccountChangedTeamAdminEmailTemplateProps = {\n mode: EmailBaseProps['mode'];\n tenant: EmailBaseProps['tenant'];\n contact: { name: string; type: 'owner' | 'vendor' };\n // Added: the contact had no bank account before.\n bankAccount: {\n last4: string;\n changedOn: string;\n changedBy: string | null;\n added: boolean;\n };\n href: string;\n};\n\nexport const BankAccountChangedTeamAdminEmailTemplate = ({\n mode,\n tenant,\n contact,\n bankAccount,\n href,\n}: BankAccountChangedTeamAdminEmailTemplateProps) => (\n <EmailContainer\n title={`Bank details ${bankAccount.added ? 'added' : 'changed'} for ${contact.name}`}\n shortDescription={`Future payments to ${contact.name} go to the account ending in ${bankAccount.last4}.`}\n tenant={tenant}\n mode={mode}\n >\n <Heading style={{ fontSize: 28, fontWeight: 600, marginBottom: '50px' }}>\n Bank details {bankAccount.added ? 'added' : 'changed'}\n </Heading>\n <Text>\n The bank account of {contact.type} <b>{contact.name}</b> was{' '}\n {bankAccount.added ? 'added' : 'changed'} on {bankAccount.changedOn}\n {bankAccount.changedBy ? ` by ${bankAccount.changedBy}` : ''}. Future\n payments go to the account ending in <b>{bankAccount.last4}</b>.\n </Text>\n <Text>\n If you did not expect this change, confirm it with {contact.name} by phone\n before the next payment.\n </Text>\n <Button\n href={href}\n mode={mode}\n label=\"Review payment setup\"\n themeColors={THEME_COLORS.vrplatform!}\n />\n </EmailContainer>\n);\n"]}
|
|
@@ -3,6 +3,7 @@ export type BankDetailsRequestEmailTemplateProps = {
|
|
|
3
3
|
mode: EmailBaseProps['mode'];
|
|
4
4
|
user: EmailBaseProps['user'];
|
|
5
5
|
tenant: EmailBaseProps['tenant'];
|
|
6
|
+
payeeName: string;
|
|
6
7
|
themeColors: EmailBaseProps['themeColors'];
|
|
7
8
|
href: string;
|
|
8
9
|
form: {
|
|
@@ -13,4 +14,4 @@ export type BankDetailsRequestEmailTemplateProps = {
|
|
|
13
14
|
expiresOn: string;
|
|
14
15
|
};
|
|
15
16
|
};
|
|
16
|
-
export declare const BankDetailsRequestEmailTemplate: ({ mode, user, tenant, themeColors, href, form, }: BankDetailsRequestEmailTemplateProps) => import("react").JSX.Element;
|
|
17
|
+
export declare const BankDetailsRequestEmailTemplate: ({ mode, user, tenant, payeeName, themeColors, href, form, }: BankDetailsRequestEmailTemplateProps) => import("react").JSX.Element;
|
|
@@ -6,7 +6,7 @@ const heading_1 = require("@react-email/heading");
|
|
|
6
6
|
const text_1 = require("@react-email/text");
|
|
7
7
|
const Button_1 = require("../components/Button");
|
|
8
8
|
const EmailContainer_1 = require("../components/EmailContainer");
|
|
9
|
-
const BankDetailsRequestEmailTemplate = ({ mode, user, tenant, themeColors, href, form, }) => ((0, jsx_runtime_1.jsxs)(EmailContainer_1.EmailContainer, { title: `${tenant.name} needs
|
|
9
|
+
const BankDetailsRequestEmailTemplate = ({ mode, user, tenant, payeeName, themeColors, href, form, }) => ((0, jsx_runtime_1.jsxs)(EmailContainer_1.EmailContainer, { title: `${tenant.name} needs payout details for ${payeeName}`, shortDescription: `Add the bank account ${tenant.name} pays you to.`, tenant: tenant, mode: mode, children: [(0, jsx_runtime_1.jsx)(heading_1.Heading, { style: { fontSize: 28, fontWeight: 600, marginBottom: '50px' }, children: user.firstName ? `Hi ${user.firstName},` : 'Hi there,' }), (0, jsx_runtime_1.jsxs)(text_1.Text, { children: [(0, jsx_runtime_1.jsx)("b", { children: tenant.name }), " needs the bank account to send your payments to. Use the button below to add it. Never send bank details by email."] }), (0, jsx_runtime_1.jsx)(text_1.Text, { children: form.type === 'oneTime'
|
|
10
10
|
? `The link works once and expires on ${form.expiresOn}.`
|
|
11
11
|
: form.setsUpLogin
|
|
12
12
|
? 'You will set up your owner portal login first, then add your bank details.'
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BankDetailsRequestEmailTemplate.js","sourceRoot":"src/","sources":["templates/BankDetailsRequestEmailTemplate.tsx"],"names":[],"mappings":";;;;AAAA,kDAA+C;AAC/C,4CAAyC;AACzC,iDAA8C;AAC9C,iEAA8D;
|
|
1
|
+
{"version":3,"file":"BankDetailsRequestEmailTemplate.js","sourceRoot":"src/","sources":["templates/BankDetailsRequestEmailTemplate.tsx"],"names":[],"mappings":";;;;AAAA,kDAA+C;AAC/C,4CAAyC;AACzC,iDAA8C;AAC9C,iEAA8D;AAmBvD,MAAM,+BAA+B,GAAG,CAAC,EAC9C,IAAI,EACJ,IAAI,EACJ,MAAM,EACN,SAAS,EACT,WAAW,EACX,IAAI,EACJ,IAAI,GACiC,EAAE,EAAE,CAAC,CAC1C,wBAAC,+BAAc,IACb,KAAK,EAAE,GAAG,MAAM,CAAC,IAAI,6BAA6B,SAAS,EAAE,EAC7D,gBAAgB,EAAE,wBAAwB,MAAM,CAAC,IAAI,eAAe,EACpE,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,IAAI,aAEV,uBAAC,iBAAO,IAAC,KAAK,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE,UAAU,EAAE,GAAG,EAAE,YAAY,EAAE,MAAM,EAAE,YACpE,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,MAAM,IAAI,CAAC,SAAS,GAAG,CAAC,CAAC,CAAC,WAAW,GAC/C,EACV,wBAAC,WAAI,eACH,wCAAI,MAAM,CAAC,IAAI,GAAK,2HAEf,EACP,uBAAC,WAAI,cACF,IAAI,CAAC,IAAI,KAAK,SAAS;gBACtB,CAAC,CAAC,sCAAsC,IAAI,CAAC,SAAS,GAAG;gBACzD,CAAC,CAAC,IAAI,CAAC,WAAW;oBAChB,CAAC,CAAC,4EAA4E;oBAC9E,CAAC,CAAC,wDAAwD,GACzD,EACP,uBAAC,eAAM,IACL,IAAI,EAAE,IAAI,EACV,IAAI,EAAE,IAAI,EACV,KAAK,EAAC,kBAAkB,EACxB,WAAW,EAAE,WAAW,GACxB,EACF,wBAAC,WAAI,+DAC0C,MAAM,CAAC,IAAI,sCAEnD,IACQ,CAClB,CAAC;AAxCW,QAAA,+BAA+B,mCAwC1C","sourcesContent":["import { Heading } from '@react-email/heading';\nimport { Text } from '@react-email/text';\nimport { Button } from '../components/Button';\nimport { EmailContainer } from '../components/EmailContainer';\nimport type { EmailBaseProps } from '../types';\n\nexport type BankDetailsRequestEmailTemplateProps = {\n mode: EmailBaseProps['mode'];\n user: EmailBaseProps['user'];\n tenant: EmailBaseProps['tenant'];\n // The owner or vendor asked, so requests to different payees do not thread\n // together.\n payeeName: string;\n themeColors: EmailBaseProps['themeColors'];\n href: string;\n // Owners enter their details in the owner portal; vendors in a one-time\n // form that expires.\n form:\n | { type: 'ownerPortal'; setsUpLogin: boolean }\n | { type: 'oneTime'; expiresOn: string };\n};\n\nexport const BankDetailsRequestEmailTemplate = ({\n mode,\n user,\n tenant,\n payeeName,\n themeColors,\n href,\n form,\n}: BankDetailsRequestEmailTemplateProps) => (\n <EmailContainer\n title={`${tenant.name} needs payout details for ${payeeName}`}\n shortDescription={`Add the bank account ${tenant.name} pays you to.`}\n tenant={tenant}\n mode={mode}\n >\n <Heading style={{ fontSize: 28, fontWeight: 600, marginBottom: '50px' }}>\n {user.firstName ? `Hi ${user.firstName},` : 'Hi there,'}\n </Heading>\n <Text>\n <b>{tenant.name}</b> needs the bank account to send your payments to. Use\n the button below to add it. Never send bank details by email.\n </Text>\n <Text>\n {form.type === 'oneTime'\n ? `The link works once and expires on ${form.expiresOn}.`\n : form.setsUpLogin\n ? 'You will set up your owner portal login first, then add your bank details.'\n : 'Sign in to your owner portal to add your bank details.'}\n </Text>\n <Button\n href={href}\n mode={mode}\n label=\"Add bank details\"\n themeColors={themeColors}\n />\n <Text>\n If you did not expect this request, contact {tenant.name} before you enter\n any details.\n </Text>\n </EmailContainer>\n);\n"]}
|
|
@@ -18,7 +18,7 @@ const getDefaultInviteOwnerEmailData = (mode, args) => {
|
|
|
18
18
|
};
|
|
19
19
|
exports.getDefaultInviteOwnerEmailData = getDefaultInviteOwnerEmailData;
|
|
20
20
|
const InviteOwnerEmailTemplate = ({ ownerAccessRole = 'admin', ...props }) => {
|
|
21
|
-
return ((0, jsx_runtime_1.jsx)(components_1.ActionEmailTemplate, { ...props, data: {
|
|
21
|
+
return ((0, jsx_runtime_1.jsx)(components_1.ActionEmailTemplate, { ...props, eyebrow: "Owner Portal invitation", data: {
|
|
22
22
|
...props.data,
|
|
23
23
|
// Add guidance at render time so saved custom templates receive it too.
|
|
24
24
|
bodyTwo: `${props.data.bodyTwo}<hr style="width:100%;border:none;border-top:1px solid #eaeaea;margin:24px 0" /><p>This invitation link is for one-time setup of your Owner Portal access and expires after 7 days. Sign up using the exact email address this invitation was sent to.</p><p>If your invitation expires before setup is complete, contact your property manager for a new invitation.</p><p>For questions about ${ownerAccessRole === 'viewer' ? 'portal access' : 'your statements or portal access'}, contact your property manager.</p>`,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InviteOwnerEmailTemplate.js","sourceRoot":"src/","sources":["templates/InviteOwnerEmailTemplate.tsx"],"names":[],"mappings":";;;;AAAA,8CAA4D;AAC5D,8CAIuB;AAEhB,MAAM,8BAA8B,GAAG,CAC5C,IAAoB,EACpB,IAGC,EACgB,EAAE;IACnB,MAAM,UAAU,GACd,IAAI,KAAK,KAAK,CAAC,CAAC,CAAC,wCAA2B,CAAC,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC;IAEjE,OAAO;QACL,OAAO,EAAE,qDAAqD,IAAI,CAAC,OAAO,gEAAg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AAO,eAAe;KAC/D,CAAC;AACJ,CAAC,CAAC;AAnBW,QAAA,8BAA8B,kCAmBzC;AAEK,MAAM,wBAAwB,GAAG,CAAC,EACvC,eAAe,GAAG,OAAO,EACzB,GAAG,KAAK,EAGT,EAAE,EAAE;IACH,OAAO,CACL,uBAAC,gCAAmB,OACd,KAAK,EACT,OAAO,EAAC,yBAAyB,EACjC,IAAI,EAAE;YACJ,GAAG,KAAK,CAAC,IAAI;YACb,wEAAwE;YACxE,OAAO,EAAE,GAAG,KAAK,CAAC,IAAI,CAAC,OAAO,mYAAmY,eAAe,KAAK,QAAQ,CAAC,CAAC,CAAC,eAAe,CAAC,CAAC,CAAC,kCAAkC,sCAAsC;SAC3hB,GACD,CACH,CAAC;AACJ,CAAC,CAAC;AAjBW,QAAA,wBAAwB,4BAiBnC","sourcesContent":["import { EMAIL_ACTION_LINK_COMPONENT } from '../extensions';\nimport {\n type ActionEmailData,\n ActionEmailTemplate,\n type ActionEmailTemplateProps,\n} from '../components';\n\nexport const getDefaultInviteOwnerEmailData = (\n mode: 'tag' | 'text',\n args: {\n appName: string;\n signInLink: string;\n }\n): ActionEmailData => {\n const signInLink =\n mode === 'tag' ? EMAIL_ACTION_LINK_COMPONENT : args.signInLink;\n\n return {\n bodyOne: `<p>You are invited to access your Owner Portal on ${args.appName}.</p><p>Accept the invitation below to set up your access.</p>`,\n bodyTwo: `<p>If you have any trouble with the button, you can copy and paste the link below into your browser: ${signInLink}</p>`,\n buttonText: 'Accept Invitation',\n header: 'Welcome to your Owner Portal!',\n shortDescription: 'Set up your Owner Portal access using your invitation.',\n href: args.signInLink,\n subject: `Your invitation to the ${args.appName} Owner Portal`,\n };\n};\n\nexport const InviteOwnerEmailTemplate = ({\n ownerAccessRole = 'admin',\n ...props\n}: ActionEmailTemplateProps & {\n ownerAccessRole?: 'admin' | 'viewer';\n}) => {\n return (\n <ActionEmailTemplate\n {...props}\n eyebrow=\"Owner Portal invitation\"\n data={{\n ...props.data,\n // Add guidance at render time so saved custom templates receive it too.\n bodyTwo: `${props.data.bodyTwo}<hr style=\"width:100%;border:none;border-top:1px solid #eaeaea;margin:24px 0\" /><p>This invitation link is for one-time setup of your Owner Portal access and expires after 7 days. Sign up using the exact email address this invitation was sent to.</p><p>If your invitation expires before setup is complete, contact your property manager for a new invitation.</p><p>For questions about ${ownerAccessRole === 'viewer' ? 'portal access' : 'your statements or portal access'}, contact your property manager.</p>`,\n }}\n />\n );\n};\n"]}
|
|
@@ -20,7 +20,7 @@ const getDefaultInvitePropertyManagerEmailData = (mode, args) => {
|
|
|
20
20
|
};
|
|
21
21
|
exports.getDefaultInvitePropertyManagerEmailData = getDefaultInvitePropertyManagerEmailData;
|
|
22
22
|
const InvitePmEmailTemplate = (props) => {
|
|
23
|
-
return ((0, jsx_runtime_1.jsx)(components_1.ActionEmailTemplate, { ...props, data: {
|
|
23
|
+
return ((0, jsx_runtime_1.jsx)(components_1.ActionEmailTemplate, { ...props, eyebrow: "Team invitation", data: {
|
|
24
24
|
...props.data,
|
|
25
25
|
// Add guidance at render time so saved custom templates receive it too.
|
|
26
26
|
bodyTwo: `${props.data.bodyTwo}<hr style="width:100%;border:none;border-top:1px solid #eaeaea;margin:24px 0" /><p>This invitation link is for one-time setup of your team access and expires after 7 days. Sign up using the exact email address this invitation was sent to.</p><p>If your invitation expires before setup is complete, contact your team administrator for a new invitation.</p><p>For questions about team access, contact your team administrator.</p>`,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InvitePmEmailTemplate.js","sourceRoot":"src/","sources":["templates/InvitePmEmailTemplate.tsx"],"names":[],"mappings":";;;;AAAA,8CAA4D;AAC5D,8CAIuB;AAEhB,MAAM,wCAAwC,GAAG,CACtD,IAAoB,EACpB,IAIC,EACgB,EAAE;IACnB,MAAM,UAAU,GACd,IAAI,KAAK,KAAK;QACZ,CAAC,CAAC,wCAA2B;QAC7B,CAAC,CAAC,YAAY,IAAI,CAAC,UAAU,qBAAqB,IAAI,CAAC,UAA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AE,sBAAsB;QAC9B,gBAAgB,EAAE,kCAAkC,IAAI,CAAC,QAAQ,OAAO,IAAI,CAAC,OAAO,GAAG;QACvF,IAAI,EAAE,IAAI,CAAC,UAAU;QACrB,OAAO,EAAE,2BAA2B,IAAI,CAAC,QAAQ,OAAO,IAAI,CAAC,OAAO,EAAE;KACvE,CAAC;AACJ,CAAC,CAAC;AAtBW,QAAA,wCAAwC,4CAsBnD;AAEK,MAAM,qBAAqB,GAAG,CAAC,KAA+B,EAAE,EAAE;IACvE,OAAO,CACL,uBAAC,gCAAmB,OACd,KAAK,EACT,OAAO,EAAC,iBAAiB,EACzB,IAAI,EAAE;YACJ,GAAG,KAAK,CAAC,IAAI;YACb,wEAAwE;YACxE,OAAO,EAAE,GAAG,KAAK,CAAC,IAAI,CAAC,OAAO,6aAA6a;SAC5c,GACD,CACH,CAAC;AACJ,CAAC,CAAC;AAZW,QAAA,qBAAqB,yBAYhC","sourcesContent":["import { EMAIL_ACTION_LINK_COMPONENT } from '../extensions';\nimport {\n type ActionEmailData,\n ActionEmailTemplate,\n type ActionEmailTemplateProps,\n} from '../components';\n\nexport const getDefaultInvitePropertyManagerEmailData = (\n mode: 'tag' | 'text',\n args: {\n appName: string;\n signInLink: string;\n teamName: string;\n }\n): ActionEmailData => {\n const signInLink =\n mode === 'tag'\n ? EMAIL_ACTION_LINK_COMPONENT\n : `<a href='${args.signInLink}' target='_blank'>${args.signInLink}</a>`;\n\n return {\n bodyOne: `<p>You are invited to join ${args.teamName} on ${args.appName}.</p><p>Accept the invitation below to set up your team access.</p>`,\n bodyTwo: `<p>If you have any trouble with the button, you can use the following link below: ${signInLink}</p>`,\n buttonText: 'Accept Invitation',\n header: 'Welcome to the team!',\n shortDescription: `Accept your invitation to join ${args.teamName} on ${args.appName}.`,\n href: args.signInLink,\n subject: `You are invited to join ${args.teamName} on ${args.appName}`,\n };\n};\n\nexport const InvitePmEmailTemplate = (props: ActionEmailTemplateProps) => {\n return (\n <ActionEmailTemplate\n {...props}\n eyebrow=\"Team invitation\"\n data={{\n ...props.data,\n // Add guidance at render time so saved custom templates receive it too.\n bodyTwo: `${props.data.bodyTwo}<hr style=\"width:100%;border:none;border-top:1px solid #eaeaea;margin:24px 0\" /><p>This invitation link is for one-time setup of your team access and expires after 7 days. Sign up using the exact email address this invitation was sent to.</p><p>If your invitation expires before setup is complete, contact your team administrator for a new invitation.</p><p>For questions about team access, contact your team administrator.</p>`,\n }}\n />\n );\n};\n"]}
|
|
@@ -5,8 +5,6 @@ export declare const getDefaultOwnerStatementEmailData: (mode: "tag" | "text", a
|
|
|
5
5
|
listingName: string;
|
|
6
6
|
userName: string;
|
|
7
7
|
month: string;
|
|
8
|
-
/** The owner opens the statement through an emailed link, without a login. */
|
|
9
|
-
noLogin?: boolean;
|
|
10
8
|
}) => ActionEmailData;
|
|
11
9
|
export declare const OwnerStatementEmailTemplate: ({ data, tenant, themeColors, mode, user, listing, month, unsubscribeHref, renewHref, }: ActionEmailTemplateProps & {
|
|
12
10
|
/** Requests a new no-login link once the emailed one has expired. */
|
|
@@ -2,41 +2,32 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.OwnerStatementEmailTemplate = exports.getDefaultOwnerStatementEmailData = void 0;
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
-
const heading_1 = require("@react-email/heading");
|
|
6
5
|
const text_1 = require("@react-email/text");
|
|
7
6
|
const extensions_1 = require("../extensions");
|
|
8
7
|
const Button_1 = require("../components/Button");
|
|
9
8
|
const EmailContainer_1 = require("../components/EmailContainer");
|
|
9
|
+
const EmailHeading_1 = require("../components/EmailHeading");
|
|
10
10
|
const utils_1 = require("../components/utils");
|
|
11
11
|
const getDefaultOwnerStatementEmailData = (mode, args) => {
|
|
12
12
|
const ownerStatementHref = mode === 'tag' ? extensions_1.EMAIL_ACTION_LINK_COMPONENT : args.ownerStatementHref;
|
|
13
13
|
const listingName = mode === 'tag' ? extensions_1.EMAIL_LISTING_COMPONENT : args.listingName;
|
|
14
14
|
const month = mode === 'tag' ? extensions_1.EMAIL_DATE_COMPONENT : args.month;
|
|
15
15
|
const userName = mode === 'tag' ? extensions_1.EMAIL_USER_NAME_COMPONENT : args.userName;
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
subject: mode === 'tag'
|
|
21
|
-
? 'Your owner statement is ready'
|
|
22
|
-
: `Your ${args.month} owner statement for ${args.listingName}`,
|
|
23
|
-
shortDescription: mode === 'tag'
|
|
24
|
-
? 'Your owner statement is ready. Open it with one click, no login needed.'
|
|
25
|
-
: `Your ${args.month} statement for ${args.listingName} is ready. Open it with one click, no login needed.`,
|
|
26
|
-
header: 'Your owner statement is ready',
|
|
27
|
-
bodyOne: `<p>Hi ${userName},</p><p>${args.appName} published your ${month} owner statement for ${listingName}. Open it with the button below. You don't need a login.</p>`,
|
|
28
|
-
buttonText: 'View statement',
|
|
29
|
-
bodyTwo: `<p style="color:#737373;font-size:13px">If the button doesn't work, copy this link into your browser: ${ownerStatementHref}</p>`,
|
|
30
|
-
href: args.ownerStatementHref,
|
|
31
|
-
};
|
|
32
|
-
}
|
|
16
|
+
// Owners open the statement by link without a login and viewers log in to
|
|
17
|
+
// the owner portal, so the text names neither. Subject and preview text are
|
|
18
|
+
// plain text without tokens, so a saved template must not keep the editor's
|
|
19
|
+
// sample month and listing.
|
|
33
20
|
return {
|
|
34
|
-
subject:
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
21
|
+
subject: mode === 'tag'
|
|
22
|
+
? 'Your owner statement is ready'
|
|
23
|
+
: `Your ${args.month} owner statement for ${args.listingName}`,
|
|
24
|
+
shortDescription: mode === 'tag'
|
|
25
|
+
? 'Your owner statement is ready to view.'
|
|
26
|
+
: `Your ${args.month} statement for ${args.listingName} is ready to view.`,
|
|
27
|
+
header: 'Your owner statement is ready',
|
|
28
|
+
bodyOne: `<p>Hi ${userName},</p><p>${args.appName} published your ${month} owner statement for ${listingName}. Open it with the button below.</p>`,
|
|
29
|
+
buttonText: 'View statement',
|
|
30
|
+
bodyTwo: `<p style="color:#737373;font-size:13px">If the button doesn't work, copy this link into your browser: ${ownerStatementHref}</p>`,
|
|
40
31
|
href: args.ownerStatementHref,
|
|
41
32
|
};
|
|
42
33
|
};
|
|
@@ -50,19 +41,7 @@ const OwnerStatementEmailTemplate = ({ data, tenant, themeColors, mode, user, li
|
|
|
50
41
|
date: month || '',
|
|
51
42
|
listingName: listing || '',
|
|
52
43
|
});
|
|
53
|
-
return ((0, jsx_runtime_1.jsxs)(EmailContainer_1.EmailContainer, { title: data.subject, shortDescription: data.shortDescription, tenant: tenant, mode: mode, unsubscribeHref: unsubscribeHref, children: [(0, jsx_runtime_1.jsx)(text_1.Text, { style: {
|
|
54
|
-
color: themeColors[8],
|
|
55
|
-
fontSize: 12,
|
|
56
|
-
fontWeight: 600,
|
|
57
|
-
letterSpacing: '0.08em',
|
|
58
|
-
textTransform: 'uppercase',
|
|
59
|
-
margin: '0 0 8px',
|
|
60
|
-
}, children: "Owner statement" }), (0, jsx_runtime_1.jsx)(heading_1.Heading, { style: {
|
|
61
|
-
fontSize: 26,
|
|
62
|
-
fontWeight: 600,
|
|
63
|
-
lineHeight: '34px',
|
|
64
|
-
margin: '0 0 32px',
|
|
65
|
-
}, children: data.header?.trim() || 'Your owner statement is ready' }), data.banner?.trim() && ((0, jsx_runtime_1.jsx)(text_1.Text, { style: {
|
|
44
|
+
return ((0, jsx_runtime_1.jsxs)(EmailContainer_1.EmailContainer, { title: data.subject, shortDescription: data.shortDescription, tenant: tenant, mode: mode, unsubscribeHref: unsubscribeHref, children: [(0, jsx_runtime_1.jsx)(EmailHeading_1.EmailHeading, { eyebrow: "Owner statement", themeColors: themeColors, children: data.header?.trim() || 'Your owner statement is ready' }), data.banner?.trim() && ((0, jsx_runtime_1.jsx)(text_1.Text, { style: {
|
|
66
45
|
padding: '16px 20px',
|
|
67
46
|
backgroundColor: '#f8f9fa',
|
|
68
47
|
borderLeft: `3px solid ${themeColors[8]}`,
|