Mercurial > rsstweet
view app/views/tweets/_tweet.html.erb @ 130:faae69155f90
Improved wording?
author | nanaya <me@nanaya.pro> |
---|---|
date | Sun, 01 Oct 2017 03:55:01 +0900 |
parents | d4b2bd9e23f5 |
children | 4b5568b4a533 |
line wrap: on
line source
<% if tweet.retweeted_status.present? %> <p> <em>Retweeted:</em> <br><small>(Originally tweeted at <%= tweet.retweeted_status.created_at.to_s :rfc822 %>)</small> </p> <%= render "tweet", :tweet => tweet.retweeted_status %> <% else%> <p> <%# FIXME: Twitter gem doesn't support extended mode when writing this %> <%= auto_link(expand_url( tweet.attrs[:full_text].printable, tweet.attrs[:entities][:urls], tweet.attrs[:entities][:media] )) .gsub("\n", "<br>") .html_safe %> </p> <p> <%= link_to "https://twitter.com/#{tweet.user.screen_name}" do %> <%= image_tag tweet.user.profile_image_url_https, :alt => "profile image for #{tweet.user.name.printable}" %> <%= tweet.user.name.printable -%> <% end %> </p> <p> <% tweet.media.each_with_index do |media, i| %> <% if media.is_a? Twitter::Media::Photo %> <%= link_to "#{media.media_url_https}:orig" do %> <%= image_tag "#{media.media_url_https}:small", :alt => "attachment #{i + 1}" -%> <% end %> <% end %> <% end %> </p> <% if tweet.quoted_status.present? %> <blockquote> <%= render "tweet", :tweet => tweet.quoted_status %> </blockquote> <% end %> <% end %>