Skip to content

Commit c92a729

Browse files
committed
Emails template
1 parent 046a1c5 commit c92a729

File tree

9 files changed

+216
-14
lines changed

9 files changed

+216
-14
lines changed
Loading
Lines changed: 3 additions & 0 deletions
Loading
Loading
Lines changed: 3 additions & 0 deletions
Loading
Loading
Lines changed: 82 additions & 0 deletions
Loading
Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,24 @@
1-
{%- block from -%}
2-
{%- endblock from -%}
1+
{% extends '@ibexadesign/ui/mail/base_mail_template.html.twig' %}
32

43
{%- block subject -%}
54
{{ 'ezplatform.forgot_user_password.reset_your_password'|trans|desc('Reset your password') }}
65
{%- endblock subject -%}
76

8-
{%- block body -%}
9-
<p>
10-
{{ 'ezplatform.forgot_user_password.message'|trans({ '%reset_password%': url('ibexa.user.reset_password', {'hashKey': hash_key}) })|raw
11-
|desc('Hi,
12-
<br /><br />
13-
We have received a request to reset the password for your Ibexa DXP account. Click “reset password” below to choose a new password:
14-
<br /><br />
15-
<a href="%reset_password%">Reset password</a>
16-
<br /><br />
17-
If you did not request a password reset, please ignore this email, and your password will remain the same.') }}
18-
</p>
19-
{%- endblock body -%}
7+
{% block message_title %}
8+
{{ 'ezplatform.forgot_user_password.body_title'|trans()|desc('Hello,') }}
9+
{% endblock %}
10+
11+
{% block message %}
12+
{{ 'ezplatform.forgot_user_password.body_msg'|trans()|desc('We have received a request to reset the password for your account. Click "reset password" below to choose a new password:') }}
13+
{% endblock %}
14+
15+
{% block message_actions %}
16+
{% include '@ibexadesign/ui/mail/action_btn.html.twig' with {
17+
url: url('ibexa.user.reset_password', {'hashKey': hash_key}),
18+
label: 'ezplatform.forgot_user_password.reset_password'|trans()|desc('Reset password')
19+
} %}
20+
{% endblock %}
21+
22+
{%- block message_footer -%}
23+
{{ 'ezplatform.forgot_user_password.footer_msg'|trans()|desc('If you did not request a password reset, please ignore this email, and your password will remain the same.') }}
24+
{%- endblock -%}
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
{% set link_width = label|length * 10 %}
2+
{% set btn_width = link_width + 32 %}
3+
4+
{% macro button_side_img(base64, width_px = 16, height_px = 48) %}
5+
<td width="{{ width_px }}" height="{{ height_px }}">
6+
<img style="display: block;" src="data:image/png;base64,{{ base64 }}" >
7+
</td>
8+
{% endmacro %}
9+
10+
<table
11+
role="presentation"
12+
cellspacing="0"
13+
cellpadding="0"
14+
border="0"
15+
width="{{ btn_width }}"
16+
>
17+
<tr>
18+
{{ _self.button_side_img("iVBORw0KGgoAAAANSUhEUgAAABAAAAAwCAMAAAAvgQplAAAAVFBMVEUAAACAAICqAFWZAGaqAFWvEGOuEGSvEmWuEmOvEmWtEmSuEWSuEWWvEGSuEWSuEWSuEWOuEWSuEWSuEGSuEmOtEWSuEWSuEWSuEWStEWSuEWT///9GZI3tAAAAGnRSTlMAAgMFBlBSU1VWV4qLjKSmp9fY2drb3N3z9PxLL8wAAAABYktHRBsCYNSkAAAAXUlEQVQoz+3RNw6EQABD0U+OS46+/0Fp0EpjboBw51dZMgCkdT+dkiQBUOz6B4h/UgBBFxQKId0MahkMDovD4aAPXguPs2eH3qFySFYDcgdah6gxgGw1ICm78V54ARoVSXMDmUd2AAAAAElFTkSuQmCC") }}
19+
<td width="{{ link_width }}" height="48">
20+
<a
21+
style="
22+
display: table-cell;
23+
width: {{ link_width }}px;
24+
height: 48px;
25+
color: #ffffff;
26+
text-align: center;
27+
text-decoration: none;
28+
vertical-align: middle;
29+
background: #AE1164;
30+
"
31+
href="{{ url }}"
32+
>
33+
{{ label }}
34+
</a>
35+
</td>
36+
{{ _self.button_side_img("iVBORw0KGgoAAAANSUhEUgAAABAAAAAwCAMAAAAvgQplAAAAUVBMVEUAAACAAICZAGaqAFWuEGSvEGOuEGStEmSuEmOvEmWuEWOtEWWuEWWuEWSuEWSuEWSuEWSuEWStEWSuEWSuEWStEWSuEWWuEWStEWSuEWT///9DylPAAAAAGXRSTlMAAgUGT1BSVFVWiImLo6Sm19jb3N3e8fP0bGRbwQAAAAFiS0dEGnVn5DIAAABZSURBVCjP7dK3EYBAAMTAw5vHu+f6b5SMAZXAoHBjybbtcx6bTJIk360lwO4SgAPBBWHPAK4JA2EmRIJ/+CwchInQEyrAxulybNli3PBee8kf88dpqFJJ0gWYFEaC3ipVGgAAAABJRU5ErkJggg==") }}
37+
</tr>
38+
</table>

0 commit comments

Comments
 (0)