mirror of
https://github.com/AppFlowy-IO/AppFlowy-Cloud.git
synced 2025-04-19 03:24:42 -04:00
feat: template for magic link with otp token
This commit is contained in:
parent
ef40f8faa4
commit
cd8dbca04b
3 changed files with 269 additions and 10 deletions
|
@ -21,16 +21,6 @@
|
|||
<![endif]-->
|
||||
<title>Workspace Import Failed</title>
|
||||
<style>
|
||||
.p-4 {
|
||||
padding: 16px
|
||||
}
|
||||
.py-4 {
|
||||
padding-top: 16px;
|
||||
padding-bottom: 16px
|
||||
}
|
||||
.text-white {
|
||||
color: #fff
|
||||
}
|
||||
@media (max-width: 600px) {
|
||||
.sm-px-4 {
|
||||
padding-left: 16px !important;
|
||||
|
|
138
assets/mailer_templates/build_production/magic_link.html
Normal file
138
assets/mailer_templates/build_production/magic_link.html
Normal file
|
@ -0,0 +1,138 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en" xmlns:v="urn:schemas-microsoft-com:vml">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="x-apple-disable-message-reformatting">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<meta name="format-detection" content="telephone=no, date=no, address=no, email=no, url=no">
|
||||
<meta name="color-scheme" content="light dark">
|
||||
<meta name="supported-color-schemes" content="light dark">
|
||||
<!--[if mso]>
|
||||
<noscript>
|
||||
<xml>
|
||||
<o:OfficeDocumentSettings xmlns:o="urn:schemas-microsoft-com:office:office">
|
||||
<o:PixelsPerInch>96</o:PixelsPerInch>
|
||||
</o:OfficeDocumentSettings>
|
||||
</xml>
|
||||
</noscript>
|
||||
<style>
|
||||
td,th,div,p,a,h1,h2,h3,h4,h5,h6 {font-family: "Segoe UI", sans-serif; mso-line-height-rule: exactly;}
|
||||
</style>
|
||||
<![endif]-->
|
||||
<title>Magic Link</title>
|
||||
<style>
|
||||
.border-spacing-4 {
|
||||
--tw-border-spacing-x: 16px;
|
||||
--tw-border-spacing-y: 16px;
|
||||
border-spacing: var(--tw-border-spacing-x) var(--tw-border-spacing-y)
|
||||
}
|
||||
.border-spacing-6 {
|
||||
--tw-border-spacing-x: 24px;
|
||||
--tw-border-spacing-y: 24px;
|
||||
border-spacing: var(--tw-border-spacing-x) var(--tw-border-spacing-y)
|
||||
}
|
||||
.hover-opacity-90:hover {
|
||||
opacity: 0.9 !important
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body style="margin: 0; width: 100%; background-color: #faf5ff; padding: 0; -webkit-font-smoothing: antialiased; word-break: break-word">
|
||||
<div style="display: none">
|
||||
Sign in using magic link or OTP.
|
||||
 ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏  ͏
|
||||
</div>
|
||||
<div role="article" aria-roledescription="email" aria-label="Magic Link" lang="en">
|
||||
<div style="display: flex; flex-direction: column; justify-content: center; background-color: #faf5ff; padding: 24px; font-family: Helvetica, ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif; color: #000">
|
||||
<table align="center" class="border-spacing-4" style="display: flex; width: 700px; border-spacing: 16px; flex-direction: column; align-items: center; justify-content: flex-start; background-color: #fff; padding: 32px" cellpadding="0" cellspacing="0" role="none">
|
||||
<tr>
|
||||
<td style="text-align: center">
|
||||
<img src="https://raw.githubusercontent.com/AppFlowy-IO/AppFlowy-Cloud/main/assets/mailer_templates/build_production/images/appflowy.png" style="max-width: 100%; vertical-align: middle; line-height: 1; height: 56px; width: 56px; overflow: hidden; object-fit: cover" alt="">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<table align="center" class="border-spacing-6" style="display: flex; border-spacing: 24px; flex-direction: column; align-items: center; padding: 0" cellpadding="0" cellspacing="0" role="none">
|
||||
<tr>
|
||||
<td>
|
||||
<p style="margin: 0; text-align: center; font-size: 30px; font-weight: 700">
|
||||
Your login code for AppFlowy
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p style="margin: 0; text-align: center; font-size: 18px">
|
||||
This link and code will be expire in 5 minutes for security reasons.
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<div style="text-align: center;">
|
||||
<a href="{{ .ConfirmationUrl }}" class="hover-opacity-90" style="margin: 0; display: inline-block; cursor: pointer; border-radius: 16px; padding: 16px 24px; font-size: 16px; font-weight: 600; line-height: 1; color: #f8fafc; text-decoration: none; background-color: #9327ff">
|
||||
<!--[if mso]>
|
||||
<i style="mso-font-width: 150%; mso-text-raise: 30px" hidden> </i>
|
||||
<![endif]-->
|
||||
<span style="mso-text-raise: 16px">
|
||||
<div style="font-size: 16px; font-weight: 700">Login to AppFlowy</div>
|
||||
</span>
|
||||
<!--[if mso]>
|
||||
<i hidden style="mso-font-width: 150%;"> ​</i>
|
||||
<![endif]-->
|
||||
</a>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<div style="margin-left: auto; margin-right: auto; text-align: center; font-size: 16px; line-height: 18px">
|
||||
If the link does not work, you can use the verification code
|
||||
directly:
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: center;">
|
||||
<p style="margin: 0; display: inline-block; border-radius: 4px; background-color: #e5e7eb; padding: 8px; text-align: center; font-size: 18px; font-weight: 700; color: #000">{{ .Token }}</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<div role="separator" style="background-color: #cbd5e1; height: 1px; line-height: 1px; margin: 24px 10%">‍</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p style="margin: 0; text-align: center; font-size: 14px; font-weight: 500; color: #4b5563">
|
||||
Bring projects, knowledge, and teams together with the power of AI.
|
||||
</p>
|
||||
<p style="cursor: default; text-align: center">
|
||||
<a href="https://twitter.com/appflowy" style="margin-right: 16px; text-decoration: none">
|
||||
<img src="https://raw.githubusercontent.com/AppFlowy-IO/AppFlowy-Cloud/main/assets/mailer_templates/build_production/images/twitter.png" width="20" alt="Maizzle" style="max-width: 100%; vertical-align: middle; line-height: 1;">
|
||||
</a>
|
||||
<a href="https://www.reddit.com/r/AppFlowy" style="margin-right: 16px; text-decoration: none;">
|
||||
<img src="https://raw.githubusercontent.com/AppFlowy-IO/AppFlowy-Cloud/main/assets/mailer_templates/build_production/images/reddit.png" width="20" alt="Maizzle" style="max-width: 100%; vertical-align: middle; line-height: 1;">
|
||||
</a>
|
||||
<a href="https://github.com/AppFlowy-IO/AppFlowy" style="margin-right: 16px; text-decoration: none;">
|
||||
<img src="https://raw.githubusercontent.com/AppFlowy-IO/AppFlowy-Cloud/main/assets/mailer_templates/build_production/images/github.png" width="20" alt="Maizzle" style="max-width: 100%; vertical-align: middle; line-height: 1;">
|
||||
</a>
|
||||
<a href="https://discord.gg/9Q2xaN37tV" style="margin-right: 16px; text-decoration: none;">
|
||||
<img src="https://raw.githubusercontent.com/AppFlowy-IO/AppFlowy-Cloud/main/assets/mailer_templates/build_production/images/discord.png" width="20" alt="Maizzle" style="max-width: 100%; vertical-align: middle; line-height: 1;">
|
||||
</a>
|
||||
</p>
|
||||
<p style="margin: 0; text-align: center; font-size: 14px; font-weight: 500; color: #4b5563;">
|
||||
Copyright © 2025, AppFlowy Inc.
|
||||
</p>
|
||||
<p style="text-align: center; font-size: 14px; font-weight: 500; color: #4b5563;">
|
||||
Need Help? <a href="mailto:support@appflowy.io" style="color: #4b5563;">support@appflowy.io</a>
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
131
email_template/src/templates/magic_link.html
Normal file
131
email_template/src/templates/magic_link.html
Normal file
|
@ -0,0 +1,131 @@
|
|||
---
|
||||
title: "Magic Link"
|
||||
preheader: "Sign in using magic link or OTP."
|
||||
bodyClass: bg-purple-50
|
||||
---
|
||||
|
||||
<x-main>
|
||||
<div
|
||||
class="bg-purple-50 font-helvetica p-[24px] text-black flex flex-col justify-center"
|
||||
>
|
||||
<table align="center" class="bg-white w-[700px] p-[32px] flex flex-col justify-start items-center border-spacing-4">
|
||||
<tr>
|
||||
<td class="text-center">
|
||||
<img
|
||||
src="{{ cdnBaseUrl }}images/appflowy.png"
|
||||
class="overflow-hidden object-cover w-[56px] h-[56px]"
|
||||
/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<table align="center" class="p-0 flex flex-col items-center border-spacing-6">
|
||||
<tr>
|
||||
<td>
|
||||
<p
|
||||
class="text-center text-3xl font-bold m-0"
|
||||
>
|
||||
Your login code for AppFlowy
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p
|
||||
class="text-center text-lg m-0"
|
||||
>
|
||||
This link and code will be expire in 5 minutes for security reasons.
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<x-button
|
||||
align="center"
|
||||
class="hover:opacity-90 cursor-pointer !bg-[#9327ff] m-0 rounded-2xl"
|
||||
href="@{{ .ConfirmationUrl }}"
|
||||
>
|
||||
<div class="font-bold text-[16px]">Login to AppFlowy</div>
|
||||
</x-button>
|
||||
</td>
|
||||
</tr>
|
||||
</table
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<div class="mx-auto leading-4.5 text-base text-center">
|
||||
If the link does not work, you can use the verification code
|
||||
directly:
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="text-center">
|
||||
<p class="bg-gray-200 p-2 rounded text-center text-black text-lg font-bold inline-block m-0">@{{ .Token }}</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<x-divider space-x="10%" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<p class="m-0 text-sm text-gray-600 font-medium text-center">
|
||||
Bring projects, knowledge, and teams together with the power of AI.
|
||||
</p>
|
||||
|
||||
<p class="cursor-default text-center">
|
||||
<a
|
||||
href="https://twitter.com/appflowy"
|
||||
class="[text-decoration:none] mr-4"
|
||||
>
|
||||
<img
|
||||
src="{{ cdnBaseUrl }}images/twitter.png"
|
||||
width="20"
|
||||
alt="Maizzle"
|
||||
/>
|
||||
</a>
|
||||
<a
|
||||
href="https://www.reddit.com/r/AppFlowy"
|
||||
class="[text-decoration:none] mr-4"
|
||||
>
|
||||
<img
|
||||
src="{{ cdnBaseUrl }}images/reddit.png"
|
||||
width="20"
|
||||
alt="Maizzle"
|
||||
/>
|
||||
</a>
|
||||
<a
|
||||
href="https://github.com/AppFlowy-IO/AppFlowy"
|
||||
class="[text-decoration:none] mr-4"
|
||||
>
|
||||
<img
|
||||
src="{{ cdnBaseUrl }}images/github.png"
|
||||
width="20"
|
||||
alt="Maizzle"
|
||||
/>
|
||||
</a>
|
||||
<a
|
||||
href="https://discord.gg/9Q2xaN37tV"
|
||||
class="[text-decoration:none] mr-4"
|
||||
>
|
||||
<img
|
||||
src="{{ cdnBaseUrl }}images/discord.png"
|
||||
width="20"
|
||||
alt="Maizzle"
|
||||
/>
|
||||
</a>
|
||||
</p>
|
||||
<p class="m-0 text-sm text-gray-600 font-medium text-center">
|
||||
Copyright © 2025, AppFlowy Inc.
|
||||
</p>
|
||||
<p class="text-sm text-gray-600 font-medium text-center">
|
||||
Need Help? <a href="mailto:support@appflowy.io" class="text-gray-600">support@appflowy.io</a>
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</x-main>
|
Loading…
Add table
Reference in a new issue