body-sub table, new row for each action

Fixes styling issues when more than one button is included in the body of the email by moving each button alternative link to a new row.
This commit is contained in:
Danny Brewster authored and GitHub committed 2017-04-02 18:06:37 +01:00
1 parent 4396ae87e6
commit b3465f76a2
1 file changed
+6 -6
+6 -6
View File
@@ -343,14 +343,14 @@ func (dt *Default) HTMLTemplate() string {
{{ with .Email.Body.Actions }}
<table class="body-sub">
<tbody>
<tr>
{{ range $action := . }}
<td>
<p class="sub">If you’re having trouble with the button '{{ $action.Button.Text }}', copy and paste the URL below into your web browser.</p>
<p class="sub"><a href="{{ $action.Button.Link }}">{{ $action.Button.Link }}</a></p>
</td>
<tr>
<td>
<p class="sub">If you’re having trouble with the button '{{ $action.Button.Text }}', copy and paste the URL below into your web browser.</p>
<p class="sub"><a href="{{ $action.Button.Link }}">{{ $action.Button.Link }}</a></p>
</td>
</tr>
{{ end }}
</tr>
</tbody>
</table>
{{ end }}