Sha256: 5ac72178b6b29af5bf1594a95d4ac50e54f90e206a369cc9e3d66ce9c2416ec3

Contents?: true

Size: 1.43 KB

Versions: 82

Compression:

Stored size: 1.43 KB

Contents

- featured = local_assigns.has_key?(:featured) ? featured : false
- skip_author_info = local_assigns.has_key?(:skip_author_info) ? skip_author_info : false

- cache post do
  .post.post-short{data: {uri: expanded_post_url(post)}, class: ('featured-post' if featured)}
    - if post.thumb_image.present?
      = link_to "", expanded_post_url(post), class: 'post-short-img', style: "background-image: url('#{post.thumb_image.try(:image).try(:url, :med_thumb)}');"

    .post-headline= link_to post.headline, expanded_post_url(post)

    - unless skip_author_info
      .author-info
        - if post.author.avatar.present?
          = link_to user_path(post.author), class: 'author-avatar' do
            = image_tag post.author.avatar.url(:thumb), class: 'post-author-avatar-img img-circle'
        %span.muted by
        = link_to post.author.byline, user_path(post.author), class: 'post-author-link'
        %span.muted.slash= '/'
        %span.muted.pub-date= local_time (post.publish_at || post.created_at), post_time_format
        - if post.post? && post.comments_enabled?
          = link_to expanded_post_url(post, anchor: 'disqus_thread'), class: 'muted comment-info' do
            %span.disqus-comment-count{data: {disqus_identifier: post.disqus_identifier}}

    - if post.excerpt.present? && post.show_excerpt?
      .post-body.post-excerpt
        = post.excerpt
    - else
      .post-body
        = truncate_post_to_read_more(post, length: 240)

Version data entries

82 entries across 42 versions & 1 rubygems

Version Path
virgo-0.3.17 spec/dummy/app/views/virgo/posts/_post_short.haml
virgo-0.3.17 app/views/virgo/posts/_post_short.haml
virgo-0.3.16 app/views/virgo/posts/_post_short.haml
virgo-0.3.16 spec/dummy/app/views/virgo/posts/_post_short.haml
virgo-0.3.15 spec/dummy/app/views/virgo/posts/_post_short.haml
virgo-0.3.15 app/views/virgo/posts/_post_short.haml
virgo-0.3.14 spec/dummy/app/views/virgo/posts/_post_short.haml
virgo-0.3.14 app/views/virgo/posts/_post_short.haml
virgo-0.3.13 app/views/virgo/posts/_post_short.haml
virgo-0.3.13 spec/dummy/app/views/virgo/posts/_post_short.haml
virgo-0.3.12 app/views/virgo/posts/_post_short.haml
virgo-0.3.12 spec/dummy/app/views/virgo/posts/_post_short.haml
virgo-0.3.11 spec/dummy/app/views/virgo/posts/_post_short.haml
virgo-0.3.11 app/views/virgo/posts/_post_short.haml
virgo-0.3.10 spec/dummy/app/views/virgo/posts/_post_short.haml
virgo-0.3.10 app/views/virgo/posts/_post_short.haml
virgo-0.3.9 app/views/virgo/posts/_post_short.haml
virgo-0.3.9 spec/dummy/app/views/virgo/posts/_post_short.haml
virgo-0.3.8 app/views/virgo/posts/_post_short.haml
virgo-0.3.8 spec/dummy/app/views/virgo/posts/_post_short.haml