feat: add brand_color variable for the email templates (#33421)
* feat: add brand_color variable for the email templates * test: fix tests assertations --------- Co-authored-by: Eugene Dyudyunov <evgen.dyudyunov@raccoongang.com>
This commit is contained in:
@@ -29,6 +29,7 @@
|
||||
|
||||
{% google_analytics_tracking_pixel %}
|
||||
|
||||
{% with brand_color="#005686" logo_max_height="65px" %}
|
||||
<div bgcolor="#f5f5f5" lang="{{ LANGUAGE_CODE|default:"en" }}" dir="{{ LANGUAGE_BIDI|yesno:"rtl,ltr" }}" style="
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
@@ -79,7 +80,7 @@
|
||||
<tr>
|
||||
<td align="left" valign="top">
|
||||
<a href="{% with_link_tracking homepage_url %}">
|
||||
<img src="{{ logo_url }}" style="max-height: 65px;" height="auto" alt="{% filter force_escape %}{% blocktrans %}Go to {{ platform_name }} Home Page{% endblocktrans %}{% endfilter %}"/></a>
|
||||
<img src="{{ logo_url }}" style="max-height: {{ logo_max_height }};" height="auto" alt="{% filter force_escape %}{% blocktrans %}Go to {{ platform_name }} Home Page{% endblocktrans %}{% endfilter %}"/></a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
@@ -218,8 +219,8 @@
|
||||
{% get_action_links channel omit_unsubscribe_link=omit_unsubscribe_link as action_links %}
|
||||
{% for action_link_url, action_link_text in action_links %}
|
||||
<p>
|
||||
<a href="{{ action_link_url }}" style="color: #005686">
|
||||
<font color="#005686"><b>{{ action_link_text }}</b></font>
|
||||
<a href="{{ action_link_url }}" style="color: {{ brand_color }};">
|
||||
<font color="{{ brand_color }}"><b>{{ action_link_text }}</b></font>
|
||||
</a>
|
||||
</p>
|
||||
{% endfor %}
|
||||
@@ -253,6 +254,7 @@
|
||||
<![endif]-->
|
||||
|
||||
</div>
|
||||
{% endwith %}
|
||||
|
||||
{# Debug info that is not user-visible #}
|
||||
<span id="ace-message-id" style="display:none;">{{ message.log_id }}</span>
|
||||
|
||||
@@ -21,11 +21,11 @@
|
||||
border-radius: 4px;
|
||||
-webkit-border-radius: 4px;
|
||||
-moz-border-radius: 4px;
|
||||
background-color: #005686;
|
||||
border-top: 12px solid #005686;
|
||||
border-bottom: 12px solid #005686;
|
||||
border-right: 50px solid #005686;
|
||||
border-left: 50px solid #005686;
|
||||
background-color: {{ brand_color }};
|
||||
border-top: 12px solid {{ brand_color }};
|
||||
border-bottom: 12px solid {{ brand_color }};
|
||||
border-right: 50px solid {{ brand_color }};
|
||||
border-left: 50px solid {{ brand_color }};
|
||||
display: inline-block;
|
||||
">
|
||||
{# old email clients require the use of the font tag :( #}
|
||||
|
||||
@@ -101,11 +101,11 @@
|
||||
border-radius: 4px;
|
||||
-webkit-border-radius: 4px;
|
||||
-moz-border-radius: 4px;
|
||||
background-color: #005686;
|
||||
border-top: 10px solid #005686;
|
||||
border-bottom: 10px solid #005686;
|
||||
border-right: 16px solid #005686;
|
||||
border-left: 16px solid #005686;
|
||||
background-color: {{ brand_color }};
|
||||
border-top: 10px solid {{ brand_color }};
|
||||
border-bottom: 10px solid {{ brand_color }};
|
||||
border-right: 16px solid {{ brand_color }};
|
||||
border-left: 16px solid {{ brand_color }};
|
||||
display: inline-block;
|
||||
">
|
||||
{# old email clients require the use of the font tag :( #}
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
{% load i18n %}
|
||||
|
||||
{% block content %}
|
||||
{% with contact_email='<a href="'|add:contact_email|add:'" style="color: '|add:brand_color|add:';">'|safe|add:contact_email|add:'</a>'|safe %}
|
||||
<table width="100%" align="left" border="0" cellpadding="0" cellspacing="0" role="presentation">
|
||||
<tr>
|
||||
<td>
|
||||
@@ -44,4 +45,5 @@
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
{% endwith %}
|
||||
{% endblock %}
|
||||
|
||||
Reference in New Issue
Block a user