Sha256: c29fee57900ef598438b86bc52a65480379aa1e32f85b1e5e1d114a21646b5a2

Contents?: true

Size: 1.8 KB

Versions: 1

Compression:

Stored size: 1.8 KB

Contents

<p id="notice"><%= notice %></p>

<div>
  <div class="information">
    <table class="key-value">  
      <tr>
        <th colspan="2">General</th>
      </tr>
      <tr>
        <td class="key">Name</td>
        <td class="value"><%= @file_item.name %></td>
      </tr>
      <tr>
        <td class="key">Tags</td>
        <td class="value"><%= @file_item.tag_list %></td>
      </tr>
    <% if @file_item.dynamic_attributes %>
      <tr>
        <th colspan="2">Additional</th>
      </tr>
      <% @file_item.dynamic_attributes.each do |key, value| %>
      <tr>
        <td class="key"><%= t key, :scope => 'saphira.dynamic_attributes' %></td>
        <td class="value"><%= value %></td>
      </tr>
      <% end %>
    <% end %>
    <% if @file_item.file.image? and Saphira::ImageVariant.exists? %>
      <tr>
        <th colspan="2">Image variants</th>
      </tr>
      <tr class="image_variant default">
        <td class="key"><%= t 'saphira.general.default', :default => 'Default' %></td>
        <td class="value"><%= link_to 'show', file_item_path(@file_item) %></td>
      </tr>
      <% Saphira::ImageVariant.all.each do |variant| %>
      <tr class="image_variant <%= variant.name.gsub(/[^a-zA-Z_]+/, '_') %>">
        <td class="key"><%= variant.name %></td>
        <td class="value"><%= link_to 'show', file_item_image_variant_setting_path(@file_item, variant) unless @image_variant==variant %></td>
      </tr>
      <% end %>
    <% end %>
    </table>
  </div>

  <% if @file_item.file_uid and @file_item.file.image? %>
  <div id="saphira-file-preview" class="file preview image">
    <%= image_tag @file_item.image_variant(params[:id]).thumb('300x300').url %>
  </div>
  <% end %>
  
  <div style="clear: both;"></div>
</div>

<%= link_to 'Edit', edit_file_item_image_variant_setting_path(@file_item, @image_variant) %>

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
saphira-0.1.1.beta1 app/views/saphira/image_variant_settings/show.html.erb