Apply inline styling to all <p> tags

Solved the problem of <p> tags being given different padding or color by different clients, without having to copy-paste a string of CSS into every <p> tag in the templates.
This commit is contained in:
Herve Saint-Amand 2017-01-25 22:50:52 +00:00
parent 25d80789dd
commit cf11913d58
3 changed files with 17 additions and 18 deletions

View file

@ -18,4 +18,8 @@ module NotifierHelper
:locals => { :body => capture(&block) }
)
end
def apply_inline_css(html)
html.gsub /<p>/, '<p style="color: black; margin: 0.75em 0">'
end
end