Sha256: d4cab67c57db30b81de3ada7c5f78a56ad8c66d80d31077b0b94464d16fca5e3

Contents?: true

Size: 470 Bytes

Versions: 2

Compression:

Stored size: 470 Bytes

Contents

<%= breadcrumb %>

<% unless @blob.binary? %>
  <div class="blob highlight">
    <%= raw highlight_blob @blob_hash[:name], @blob.content.force_encoding(Encoding::UTF_8) %>
  </div>
<% else %>
  <div class="blob">
    <% match = @blob_hash[:name].match(/\.(jpg|jpeg|png|gif)$/) %>
    <% if match %>
      <img src="data:image/<%= match[1] %>;base64,<%= Base64.strict_encode64(@blob.content) %>">
    <% else %>
      Nothing to display.
    <% end %>
  </div>
<% end %>

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
bulb-0.5.0 app/views/bulb/blob/show.html.erb
bulb-0.4.0 app/views/bulb/blob/show.html.erb