make figures full width instead of images

This commit is contained in:
Lorin Werthen 2018-04-10 11:36:45 +02:00
parent 0cf8f51b40
commit e6fb03960d
No known key found for this signature in database
GPG key ID: F11FFC921E0E08E0

View file

@ -17,9 +17,9 @@ module BlogHelper
def figure(img_url, caption, alt = nil, img_class: nil) def figure(img_url, caption, alt = nil, img_class: nil)
alt ||= caption alt ||= caption
<<~HTML <<~HTML
<figure class="image"> <figure class="image" class="#{img_class}">
<a href="#{img_url}"> <a href="#{img_url}">
<img src="#{img_url}" alt="#{alt}" class="#{img_class}"> <img src="#{img_url}" alt="#{alt}">
</a> </a>
<figcaption>#{caption}</figcaption> <figcaption>#{caption}</figcaption>
</figure> </figure>