Files
danbooru/app/views/uploads/_image.html.erb
2017-03-21 15:41:20 -07:00

20 lines
645 B
Plaintext

<% if params[:url] %>
<% if ImageProxy.needs_proxy?(@normalized_url) %>
<%= image_tag(image_proxy_uploads_path(:url => @normalized_url), :title => "Preview", :id => "image") %>
<% else %>
<%= image_tag(@normalized_url, :title => "Preview", :id => "image") %>
<% end %>
<ul>
<% if @remote_size %>
<li><strong>Size:</strong> <%= number_to_human_size(@remote_size) %></li>
<% end %>
<% if params[:ref] %>
<li><strong>Referrer:</strong> <%= params[:ref] %></li>
<% end %>
<li><span id="scale"></span> (<%= link_to "toggle size", "#", :id => "image-resize-to-window-link" %>)</li>
</ul>
<% end %>