Skip to content

Commit

Permalink
formtastic: do not show the image preview for file type pickers
Browse files Browse the repository at this point in the history
  • Loading branch information
bastiaanterhorst committed Oct 20, 2012
1 parent 74b95d7 commit 5497fe6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/inputs/rich_picker_input.rb
Expand Up @@ -68,6 +68,8 @@ def javascript
end

def preview
return unless editor_options[:type] != 'file'

path = preview_image_path
klass = "class='rich-image-preview'"
style = "style='max-width:#{editor_options[:preview_size]}; max-height:#{editor_options[:preview_size]};'"
Expand Down

0 comments on commit 5497fe6

Please sign in to comment.