diff options
author | Zarino Zappia <mail@zarino.co.uk> | 2018-09-25 14:10:07 +0100 |
---|---|---|
committer | Zarino Zappia <mail@zarino.co.uk> | 2018-10-08 15:51:16 +0100 |
commit | 8cdfbc7660fa5b30e3ea41f105f04b45634f024d (patch) | |
tree | 9a6d870c1936d722f3ca63dc9b6391fb63a33c44 /templates | |
parent | 2c24318939d310100559b0bc8aed663ff940ce22 (diff) |
[BANES] Branding for HTML emails
Diffstat (limited to 'templates')
-rw-r--r-- | templates/email/bathnes/_email_color_overrides.html | 35 | ||||
-rw-r--r-- | templates/email/bathnes/_email_setting_overrides.html | 11 | ||||
-rw-r--r-- | templates/email/bathnes/_email_top.html | 77 | ||||
-rw-r--r-- | templates/email/bathnes/_submit_footer.html | 1 |
4 files changed, 124 insertions, 0 deletions
diff --git a/templates/email/bathnes/_email_color_overrides.html b/templates/email/bathnes/_email_color_overrides.html new file mode 100644 index 000000000..0e7475fb0 --- /dev/null +++ b/templates/email/bathnes/_email_color_overrides.html @@ -0,0 +1,35 @@ +[% + +color_bathnes_blue = '#00AEEF' +color_bathnes_grey_1 = '#6F777B' +color_bathnes_grey_2 = '#BFC1C3' +color_bathnes_grey_3 = '#DEE0E2' +color_bathnes_grey_4 = '#F8F8F8' +color_bathnes_link = '#00728F' +color_bathnes_link_hover = '#009BC2' + +link_text_color = color_bathnes_link +link_hover_text_color = color_bathnes_link_hover + +body_background_color = color_bathnes_grey_4 +body_text_color = color_bathnes_grey_1 + +header_background_color = color_bathnes_blue +header_text_color = color_white + +button_background_color = color_bathnes_blue +button_text_color = color_white + +secondary_column_background_color = color_bathnes_grey_3 +secondary_column_text_color = color_black +column_divider_color = color_bathnes_grey_2 + +preview_photo_border = 'none' + +logo_width = '160' +logo_height = '60' + +header_background_color = body_background_color +header_padding = "0 0 20px 0" # a full CSS padding property (eg: top/right/bottom/left) + +%] diff --git a/templates/email/bathnes/_email_setting_overrides.html b/templates/email/bathnes/_email_setting_overrides.html new file mode 100644 index 000000000..47c438da2 --- /dev/null +++ b/templates/email/bathnes/_email_setting_overrides.html @@ -0,0 +1,11 @@ +[% + +site_name = 'Report it' + +header_style = "padding: $header_padding; background: $header_background_color; color: $header_text_color; border-bottom: 5px solid $color_bathnes_blue;" + +only_column_style = "padding: ${ column_padding }px; vertical-align: top; background-color: $primary_column_background_color; color: $primary_column_text_color; border: 1px solid $column_divider_color; border-width: 0 1px 1px 1px;" +primary_column_style = "vertical-align: top; width: 50%; background-color: $primary_column_background_color; color: $primary_column_text_color; border: 1px solid $column_divider_color; border-width: 0 0 1px 1px;" +secondary_column_style = "vertical-align: top; width: 50%; background-color: $secondary_column_background_color; color: $secondary_column_text_color; border: 1px solid $column_divider_color; border-width: 0 1px 1px 1px;" + +%] diff --git a/templates/email/bathnes/_email_top.html b/templates/email/bathnes/_email_top.html new file mode 100644 index 000000000..ec3c80ce2 --- /dev/null +++ b/templates/email/bathnes/_email_top.html @@ -0,0 +1,77 @@ +[% + # The cobrand might come to us a variety of ways + # Alert sets cobrand directly, questionnaire/submit have it in report, otherwise web + cobrand = cobrand.moniker OR report.cobrand OR c.cobrand.moniker; + + IF cobrand == 'fixmystreet'; + SET img_dir = 'fixmystreet.com'; + ELSE; + SET img_dir = cobrand; + END -%] +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title></title> + <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> + <style type="text/css"> + [%~ # Styles here will be applied by everything except Gmail.com %] + a { [% link_style %] } + a:hover { [% link_hover_style %] } + + body, table, td, th { + font-family: [% body_font_family %] !important; + } + + @media only screen and (max-width: [% wrapper_min_width - 1 %]px) { + #main, .hint { + min-width: 0 !important; + } + + #main table, #main tr, #main th { + display: block !important; + } + + #primary_column, + #secondary_column { + width: auto !important; + } + } + + @media only screen and (max-width: [% wrapper_max_width - 1 %]px) { + #header { + padding-left: 20px !important; + } + } + + @media only screen and (min-width: [% wrapper_max_width %]px) { + .spacer-cell { + background-color: [% body_background_color %]; + } + } + </style> +</head> +<body style="[% body_style %]"> + <table [% wrapper_table %] style="[% wrapper_style %]"> + <tr> + <th class="spacer-cell"></th> + <th width="[% wrapper_max_width %]" style="[% td_style %][% hint_style %]" class="hint"> + [% email_summary %] + </th> + <th class="spacer-cell"></th> + </tr> + </table> + <table [% wrapper_table %] style="[% wrapper_style %]"> + <tr> + <th class="spacer-cell"></th> + <th width="[% wrapper_max_width %]" style="[% td_style %] min-width: [% wrapper_min_width %]px;" id="main"> + <table [% table_reset %]> + <tr> + <th id="header" colspan="[% email_columns %]" style="[% td_style %][% header_style %]"> + [%~ IF file_exists("web/cobrands/${ img_dir }/images/email-logo.gif") ~%] + <img src="[% inline_image('web/cobrands/' _ img_dir _ '/images/email-logo.gif') %]" width="[% logo_width %]" height="[% logo_height %]" alt="[% site_name %]" style="[% logo_style %]"/> + [%~ ELSE ~%] + <span style="[% logo_style %]">[% site_name %]</span> + [%~ END %] + </th> + </tr> + <tr> diff --git a/templates/email/bathnes/_submit_footer.html b/templates/email/bathnes/_submit_footer.html new file mode 100644 index 000000000..2f280419f --- /dev/null +++ b/templates/email/bathnes/_submit_footer.html @@ -0,0 +1 @@ +Thank you for using FixMyStreet Pro! |