Skip to content

i18n support for Email or SMS content  #462

@think-in-universe

Description

@think-in-universe

Description

To make the email or SMS messages more user friendly, add i18n support for the messages.

With the detected or selected language in Wallet, send email or SMS messages in corresponding languages.

e.g. Create new accounts with email:

const getNewAccountEmail = (accountId, recoverUrl, securityCode) => template({
title: 'Welcome to NEAR Wallet',
contentPreview: `This message contains your account activation code and recovery link for ${accountId}.`,
content: [{
html: `This message contains your account activation code and recovery link for <b>${accountId}</b>. Keep this Email safe, and <strong>DO NOT SHARE IT!</strong> <span style="color:#DF2626;">We cannot resend this Email.</span>`
},
{
html: '1. Confirm your activation code to finish creating your account:'
},
{
blockquote: true,
html: securityCode
},
{
html: `2. In the event that you need to recover your account, click the link below, and follow the directions in NEAR Wallet.
`
}, {
html: `<a href="${recoverUrl}">Recover my Account</a>`
}],
});

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions