Adjust mail templates for registration code
Signed-off-by: Fred Boniface <fred@fjla.uk>
This commit is contained in:
parent
70c9aa2b1e
commit
5904ee37cd
@ -2,11 +2,14 @@
|
|||||||
<head>
|
<head>
|
||||||
<title>OwlBoard - Register</title>
|
<title>OwlBoard - Register</title>
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||||
<meta name="key" content=">>ACCESSCODE<<" />
|
|
||||||
<style>
|
<style>
|
||||||
html {
|
html {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
background-color: #404c55;
|
||||||
|
background-image: radial-gradient(#2b343c, #404c55);
|
||||||
}
|
}
|
||||||
body {
|
body {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
@ -26,6 +29,10 @@
|
|||||||
background-color: #404c55;
|
background-color: #404c55;
|
||||||
background-image: radial-gradient(#2b343c, #404c55);
|
background-image: radial-gradient(#2b343c, #404c55);
|
||||||
}
|
}
|
||||||
|
p {
|
||||||
|
margin-left: 40px;
|
||||||
|
margin-right: 40px;
|
||||||
|
}
|
||||||
#title {
|
#title {
|
||||||
height: 100px;
|
height: 100px;
|
||||||
padding-top: 0px;
|
padding-top: 0px;
|
||||||
@ -44,16 +51,24 @@
|
|||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
border-radius: 14px;
|
border-radius: 14px;
|
||||||
}
|
}
|
||||||
|
.digits {
|
||||||
|
color: azure;
|
||||||
|
font-size: xx-large;
|
||||||
|
font-weight: bolder;
|
||||||
|
letter-spacing: 0.75ch;
|
||||||
|
margin-left: 0.75ch;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<br /><br />
|
<br><br>
|
||||||
<table>
|
<table>
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
<img
|
<img
|
||||||
src="https://owlboard.info/images/logo/wide_logo.svg"
|
src="https://owlboard.info/images/logo/wide_logo.svg"
|
||||||
id="title"
|
id="title"
|
||||||
|
alt="OwlBoard Logo"
|
||||||
/>
|
/>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@ -62,27 +77,25 @@
|
|||||||
<h1>Register for OwlBoard</h1>
|
<h1>Register for OwlBoard</h1>
|
||||||
<br />
|
<br />
|
||||||
<p>
|
<p>
|
||||||
Tap the button to register this device, or scan the barcode with
|
You'll need to type your registration code in to the OwlBoard app
|
||||||
another device.
|
|
||||||
</p>
|
</p>
|
||||||
<br />
|
<br />
|
||||||
|
<h2>Your Code:</h2>
|
||||||
|
<span class="digits">987654</span>
|
||||||
|
<br><br>
|
||||||
<a
|
<a
|
||||||
href="https://owlboard.info/more/reg/submit?key=>>ACCESSCODE<<"
|
href="https://owlboard.info/more/reg/submit"
|
||||||
id="button"
|
id="button"
|
||||||
>Register this device</a
|
>Go to Registration Page</a
|
||||||
>
|
>
|
||||||
<br /><br /><br />
|
<br /><br /><br />
|
||||||
<p>Or scan with the device you want to register</p>
|
<p>Scan to visit the Registration Page</p>
|
||||||
<br />
|
|
||||||
<img
|
<img
|
||||||
src="https://barcodes.fjla.uk/generate?type=qr&text=https%3A%2F%2Fowlboard.info%2Fmore%2Freg%2Fsubmit%3Fkey%3D>>ACCESSCODE<<"
|
src="https://barcodes.fjla.uk/generate?type=qr&text=https%3A%2F%2Fowlboard.info%2Fmore%2Freg%2Fsubmit"
|
||||||
alt="Scan barcode to register on another device"
|
alt="Scan barcode to register on another device, alternatively use the link above"
|
||||||
title="Scan to register on another device"
|
title="Scan to register on another device"
|
||||||
/>
|
/>
|
||||||
<br /><br /><br />
|
<br /><br /><br />
|
||||||
<p>
|
|
||||||
Alternatively copy and paste the link:<br />https://owlboard.info/more/reg/submit?key=>>ACCESSCODE<<
|
|
||||||
</p>
|
|
||||||
<p>
|
<p>
|
||||||
This registration is for one device only, you can register again
|
This registration is for one device only, you can register again
|
||||||
using the same email address for other devices and access OwlBoard
|
using the same email address for other devices and access OwlBoard
|
||||||
@ -96,7 +109,7 @@
|
|||||||
can safely ignore this email. Your email address has not been stored
|
can safely ignore this email. Your email address has not been stored
|
||||||
by us.
|
by us.
|
||||||
</p>
|
</p>
|
||||||
<p>The registration link will expire after 4 hours.</p>
|
<p>The registration link will expire after 1 hour.</p>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
Complete your OwlBoard (Staff) Registration by entering your six digit code.
|
Complete your OwlBoard (Staff) Registration by entering your six digit code.
|
||||||
|
|
||||||
>>ACCESSCODE<<
|
987654
|
||||||
|
|
||||||
Use the same browser you wish to use OwlBoard with
|
Use the same browser you wish to use OwlBoard with
|
||||||
|
|
||||||
|
@ -47,13 +47,13 @@ export function generateCode(): string {
|
|||||||
async function generateConfirmationEmail(eml: string, uuid: string) {
|
async function generateConfirmationEmail(eml: string, uuid: string) {
|
||||||
try {
|
try {
|
||||||
const htmlTpl = await fs.readFile("mail-templates/register.html", "utf-8");
|
const htmlTpl = await fs.readFile("mail-templates/register.html", "utf-8");
|
||||||
const htmlStr = htmlTpl.replace(/>>ACCESSCODE<</g, uuid);
|
const htmlStr = htmlTpl.replace(/987654/g, uuid);
|
||||||
const htmlMin = await minifyMail(htmlStr);
|
const htmlMin = await minifyMail(htmlStr);
|
||||||
const txtTpl = fs.readFile("mail-templates/register.txt", "utf-8");
|
const txtTpl = fs.readFile("mail-templates/register.txt", "utf-8");
|
||||||
return {
|
return {
|
||||||
to: eml,
|
to: eml,
|
||||||
subject: "OwlBoard Registration",
|
subject: "OwlBoard Registration",
|
||||||
text: (await txtTpl).replace(/>>ACCESSCODE<</g, uuid),
|
text: (await txtTpl).replace(/987654/g, uuid),
|
||||||
html: htmlMin,
|
html: htmlMin,
|
||||||
};
|
};
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
|
Loading…
Reference in New Issue
Block a user