Merge pull request 'refs #5475 redesign 2FA email' (!1657) from 5475_redesign_2FA_email into test
gitea/salix/pipeline/head This commit looks good Details

Reviewed-on: #1657
Reviewed-by: Vicent Llopis <vicent@verdnatura.es>
This commit is contained in:
Alex Moreno 2023-07-11 05:54:28 +00:00
commit 43bf7ce707
7 changed files with 54 additions and 35 deletions

View File

@ -1,5 +1,6 @@
.code { .code {
border: 2px dashed #8dba25; border: 2px dashed #8dba25;
border-radius: 3px; border-radius: 3px;
text-align: center text-align: center;
} font-size: 24px;
}

View File

@ -1,23 +1,45 @@
<email-body v-bind="$props"> <!DOCTYPE html>
<div class="grid-row"> <html v-bind:lang="$i18n.locale">
<div class="grid-block vn-pa-ml"> <head>
<h1>{{ $t('title') }}</h1> <meta name="viewport" content="width=device-width" />
<p>{{ $t('description') }}</p> <meta name="format-detection" content="telephone=no" />
<p> </head>
{{ $t('device') }}: <strong>{{ device }}</strong> <body>
</p> <table class="grid">
<p> <tbody>
{{$t('ip')}}: <strong>{{ ip }}</strong> <tr>
</p> <td>
</div> <div class="grid-row">
</div> <div class="grid-block empty"></div>
<div class="grid-row"> </div>
<div class="grid-block vn-pa-ml"> <div class="grid-row">
<p>{{ $t('Enter the following code to continue to your account') }}</p> <div class="grid-block">
<div class="code vn-pa-sm vn-m-md"> <email-header v-bind="$props"></email-header>
{{ code }} </div>
</div> </div>
<p>{{ $t('It expires in 5 minutes') }}</p> <div class="grid-row">
</div> <div class="grid-block vn-pa-md">
</div> <h1>{{ $t('title') }}</h1>
</email-body> <p>{{ $t('description') }}</p>
<p>
{{ $t('device') }}: <strong>{{ device }}</strong>
</p>
<p>
{{$t('ip')}}: <strong>{{ ip }}</strong>
</p>
</div>
</div>
<div class="grid-row">
<div class="grid-block vn-pa-sm">
<p>{{ $t('Enter the following code to continue to your account. It expires in 5 minutes.') }}</p>
<div class="code vn-pa-sm vn-m-md">
{{ code }}
</div>
</div>
</div>
</td>
</tr>
</tbody>
</table>
</body>
</html>

View File

@ -1,10 +1,10 @@
const Component = require(`vn-print/core/component`); const Component = require(`vn-print/core/component`);
const emailBody = new Component('email-body'); const emailHeader = new Component('email-header');
module.exports = { module.exports = {
name: 'auth-code', name: 'auth-code',
components: { components: {
'email-body': emailBody.build(), 'email-header': emailHeader.build(),
}, },
props: { props: {
code: { code: {

View File

@ -3,5 +3,4 @@ title: Verification code
description: Somebody did request a verification code for login. If you didn't request it, please ignore this email. description: Somebody did request a verification code for login. If you didn't request it, please ignore this email.
device: 'Device' device: 'Device'
ip: 'IP' ip: 'IP'
Enter the following code to continue to your account: Enter the following code to continue to your account Enter the following code to continue to your account. It expires in 5 minutes.: Enter the following code to continue to your account. It expires in 5 minutes.
It expires in 5 minutes: It expires in 5 minutes

View File

@ -3,5 +3,4 @@ title: Código de verificación
description: Alguien ha solicitado un código de verificación para poder iniciar sesión. Si no lo has solicitado tu, ignora este email. description: Alguien ha solicitado un código de verificación para poder iniciar sesión. Si no lo has solicitado tu, ignora este email.
device: 'Dispositivo' device: 'Dispositivo'
ip: 'IP' ip: 'IP'
Enter the following code to continue to your account: Introduce el siguiente código para poder continuar con tu cuenta Enter the following code to continue to your account. It expires in 5 minutes: Introduce el siguiente código para poder continuar con tu cuenta. Expira en 5 minutos.
It expires in 5 minutes: Expira en 5 minutos

View File

@ -3,5 +3,4 @@ title: Code de vérification
description: Quelqu'un a demandé un code de vérification pour se connecter. Si ce n'était pas toi, ignore cet email. description: Quelqu'un a demandé un code de vérification pour se connecter. Si ce n'était pas toi, ignore cet email.
device: 'Appareil' device: 'Appareil'
ip: 'IP' ip: 'IP'
Enter the following code to continue to your account: Entrez le code suivant pour continuer avec votre compte Enter the following code to continue to your account. It expires in 5 minutes.: Entrez le code suivant pour continuer avec votre compte. Il expire dans 5 minutes.
It expires in 5 minutes: Il expire dans 5 minutes.

View File

@ -3,5 +3,4 @@ title: Código de verificação
description: Alguém solicitou um código de verificação para entrar. Se você não fez essa solicitação, ignore este e-mail. description: Alguém solicitou um código de verificação para entrar. Se você não fez essa solicitação, ignore este e-mail.
device: 'Dispositivo' device: 'Dispositivo'
ip: 'IP' ip: 'IP'
Enter the following code to continue to your account: Insira o seguinte código para continuar com sua conta. Enter the following code to continue to your account. It expires in 5 minutes: Insira o seguinte código para continuar com sua conta. Expira em 5 minutos.
It expires in 5 minutes: Expira em 5 minutos.