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

[PAY-2810] Purchase/Sale email fix text for albums #8310

Merged
merged 1 commit into from
May 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
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
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
import { capitalize } from 'lodash'
Copy link
Contributor

Choose a reason for hiding this comment

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

Just asking since this is the only one. Are we allowed to import packages here?

I assume it's fine cause this is just a discovery-provider plugin

Copy link
Contributor Author

Choose a reason for hiding this comment

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

it is just a ts file so i would assume it's ok..

Copy link
Member

@raymondjacobson raymondjacobson May 2, 2024

Choose a reason for hiding this comment

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

should be fine if it's in the package.json


export const email = ({
purchaserName,
contentType,
contentTitle,
contentLink,
contentImage,
Expand All @@ -9,6 +12,7 @@ export const email = ({
total
}: {
purchaserName: string
contentType: string
contentTitle: string
contentLink: string
contentImage: string
Expand Down Expand Up @@ -154,7 +158,7 @@ export const email = ({
</div>
<div style="height: 16px; line-height: 16px; font-size: 14px;">&nbsp;</div>
<div style="line-height: 24px;">
<span style="font-family: 'Avenir Next LT Pro', sans-serif; font-size: 18px; color: #858199;">Congratulations! You're now the proud owner of a new track on Audius.<br><br>This isn't just a purchase. It's a show of support to an artist you love, and it goes a long way. You can now enjoy your newly purchased track anytime from your Audius Library!</span>
<span style="font-family: 'Avenir Next LT Pro', sans-serif; font-size: 18px; color: #858199;">Congratulations! You're now the proud owner of a new ${contentType} on Audius.<br><br>This isn't just a purchase. It's a show of support to an artist you love, and it goes a long way. You can now enjoy your newly purchased ${contentType} anytime from your Audius Library!</span>
</div>
</div>
</td></tr>
Expand Down Expand Up @@ -212,7 +216,8 @@ export const email = ({
<tr><td align="left" valign="middle" style="padding: 8px 0px;">
<div>
<div style="line-height: 24px;">
<span style="font-family: 'Avenir Next LT Pro', sans-serif; font-size: 18px; color: #7e1bcc;">${contentTitle}<br>${artistName}</span>
<span style="font-family: 'Avenir Next LT Pro', sans-serif; font-size: 18px; color: #7e1bcc; font-weight: bold">${contentTitle}</span><br>
<span style="font-family: 'Avenir Next LT Pro', sans-serif; font-size: 18px; color: #7e1bcc;">${artistName}</span>
</div>
</div>
</td></tr>
Expand Down Expand Up @@ -270,7 +275,9 @@ export const email = ({
<tr><td align="left" valign="middle" style="padding: 0px 8px 0px 0px;">
<div>
<div style="line-height: 20px;">
<span style="font-family: 'Avenir Next LT Pro', sans-serif; font-size: 16px; color: #858199;">Premium Track</span>
<span style="font-family: 'Avenir Next LT Pro', sans-serif; font-size: 16px; color: #858199;">Premium ${capitalize(
contentType
)}</span>
</div>
</div>
</td></tr>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
import { capitalize } from 'lodash'

export const email = ({
purchaserName,
purchaserLink,
contentType,
contentTitle,
contentLink,
contentImage,
Expand All @@ -11,6 +14,7 @@ export const email = ({
}: {
purchaserName: string
purchaserLink: string
contentType: string
contentTitle: string
contentLink: string
contentImage: string
Expand Down Expand Up @@ -116,7 +120,9 @@ export const email = ({
</div>
<div style="height: 8px; line-height: 8px; font-size: 6px;">&nbsp;</div>
<div style="line-height: 24px;">
<span style="font-family: Inter, sans-serif; font-weight: bold; font-size: 18px; color: #ffffff;">Your Track Has Been Purchased</span>
<span style="font-family: Inter, sans-serif; font-weight: bold; font-size: 18px; color: #ffffff;">Your ${capitalize(
contentType
)} Has Been Purchased</span>
</div>
</div>
<!--[if (gte mso 9)|(IE)]>
Expand Down Expand Up @@ -156,7 +162,7 @@ export const email = ({
</div>
<div style="height: 16px; line-height: 16px; font-size: 14px;">&nbsp;</div>
<div style="line-height: 24px;">
<span style="font-family: 'Avenir Next LT Pro', sans-serif; font-size: 18px; color: #858199;"><span style="text-decoration: none;">Congratulations! </span><a href="${purchaserLink}" style="color: #7e1bcc; text-decoration: none;" target="_blank"><span style="color: #7e1bcc; text-decoration: none;">${purchaserName} </span></a><span style="text-decoration: none;">just bought your track on Audius!</span></span>
<span style="font-family: 'Avenir Next LT Pro', sans-serif; font-size: 18px; color: #858199;"><span style="text-decoration: none;">Congratulations! </span><a href="${purchaserLink}" style="color: #7e1bcc; text-decoration: none;" target="_blank"><span style="color: #7e1bcc; text-decoration: none;">${purchaserName} </span></a><span style="text-decoration: none;">just bought your ${contentType} on Audius!</span></span>
</div>
</div>
</td></tr>
Expand Down Expand Up @@ -214,7 +220,8 @@ export const email = ({
<tr><td align="left" valign="middle" style="padding: 8px 0px;">
<div>
<div style="line-height: 24px;">
<span style="font-family: 'Avenir Next LT Pro', sans-serif; font-size: 18px; color: #7e1bcc;">${contentTitle}<br>${artistName}</span>
<span style="font-family: 'Avenir Next LT Pro', sans-serif; font-size: 18px; color: #7e1bcc; font-weight: bold">${contentTitle}</span><br>
<span style="font-family: 'Avenir Next LT Pro', sans-serif; font-size: 18px; color: #7e1bcc;">${artistName}</span>
</div>
</div>
</td></tr>
Expand Down Expand Up @@ -272,7 +279,9 @@ export const email = ({
<tr><td align="left" valign="middle" style="padding: 0px 8px 0px 0px;">
<div>
<div style="line-height: 20px;">
<span style="font-family: 'Avenir Next LT Pro', sans-serif; font-size: 16px; color: #858199;">Premium Track</span>
<span style="font-family: 'Avenir Next LT Pro', sans-serif; font-size: 16px; color: #858199;">Premium ${capitalize(
contentType
)}</span>
</div>
</div>
</td></tr>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,7 @@ export class USDCPurchaseBuyer extends BaseNotification<USDCPurchaseBuyerRow> {
html: email({
purchaserName: purchaserUsername,
artistName: sellerUsername,
contentType: this.contentType,
contentTitle: purchasedContentName,
contentLink: `${getHostname()}/${sellerHandle}/${slug}`,
contentImage: `${getContentNode()}/content/${cover_art_sizes}/480x480.jpg`,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,7 @@ export class USDCPurchaseSeller extends BaseNotification<USDCPurchaseSellerRow>
purchaserName: buyerUsername,
purchaserLink: `${getHostname()}/${buyerHandle}`,
artistName: sellerUsername,
contentType: this.contentType,
contentTitle: purchasedContentName,
contentLink: `${getHostname()}/${sellerHandle}/${slug}`,
contentImage: `${getContentNode()}/content/${cover_art_sizes}/480x480.jpg`,
Expand Down