]> git.openstreetmap.org Git - rails.git/blobdiff - app/views/notifier/_message_body.html.erb
Refactored the code to invoke the message body partial layout, as suggested in the PR
[rails.git] / app / views / notifier / _message_body.html.erb
diff --git a/app/views/notifier/_message_body.html.erb b/app/views/notifier/_message_body.html.erb
new file mode 100644 (file)
index 0000000..29ecf9e
--- /dev/null
@@ -0,0 +1,18 @@
+<table style="font-size: 15px; font-style: italic; margin: 15px; background-color: #eee; width: 520px">
+  <tr>
+    <td style="width: 50px; vertical-align: top; padding: 15px">
+      <%= link_to(
+          image_tag(
+            attachments["avatar.png"].url,
+            alt: @author,
+            title: @author
+          ),
+          user_url(@author, :host => SERVER_URL),
+          :target => "_blank"
+      ) %>
+    </td>
+    <td style="text-align: left; vertical-align: top; padding-right: 10px">
+      <%= body %>
+    </td>
+  </tr>
+</table>