Skip to content
Snippets Groups Projects
Unverified Commit 57a39ebb authored by Sébastien Gaya's avatar Sébastien Gaya
Browse files

width 800 for images in action text

parent 17f18ac5
No related branches found
No related tags found
No related merge requests found
<figure class="attachment attachment--<%= blob.representable? ? "preview" : "file" %> attachment--<%= blob.filename.extension %>">
<% if blob.image? %>
<%= image_tag blob.representation(resize_to_limit: local_assigns[:in_gallery] ? [ 800, 600 ] : [ 1024, 768 ]) %>
<%= image_tag blob.representation(resize_to_limit: '800x') %>
<% elsif blob.video? %>
<video>
<source src="<%= rails_blob_path(blob) %>" type="<%= blob.content_type %>">
</video>
<% else %>
<%= link_to blob, target: :blank do %>
<%= link_to polymorphic_url(blob), target: :blank do %>
<% if blob.representable? %>
<%= image_tag blob.representation(resize_to_limit: local_assigns[:in_gallery] ? [ 800, 600 ] : [ 1024, 768 ]) %>
<%= image_tag blob.representation(resize_to_limit: '800x') %>
<% else %>
<p>
<span class="attachment__name"><%= blob.filename %></span>
......
......@@ -3,6 +3,9 @@ title: "<%= @page.title %>"
permalink: "<%= @page.path %>"
identifier: "<%= @page.id %>"
parent: "<%= @page.parent_id %>"
<% if @page.featured_image.attached? %>
image: "<%= @page.featured_image.blob.id %>"
<% end %>
description: >
<%= prepare_for_github @page.description %>
text: >
......
......@@ -3,7 +3,7 @@ title: "<%= @post.title %>"
date: <%= @post.published_at %> UTC
slug: "<%= @post.slug %>"
<% if @post.featured_image.attached? %>
image: "<%= @post.featured_image.blob.url %>"
image: "<%= @post.featured_image.blob.id %>"
<% end %>
description: >
<%= prepare_for_github @post.description %>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment