added feature to scale down inline images with respect to aspect ratio #508
This commit is contained in:
parent
a0223234a8
commit
6efe4756d8
2
init.rb
2
init.rb
@ -181,7 +181,7 @@ Redmine::Plugin.register :redmine_dmsf do
|
||||
end
|
||||
raise 'Not supported image format' unless file.image?
|
||||
url = url_for(:controller => :dmsf_files, :action => 'view', :id => file)
|
||||
if size.include? "%"
|
||||
if size && size.include?('%')
|
||||
image_tag(url, :alt => file.title, :width => size, :height => size)
|
||||
else
|
||||
image_tag(url, :alt => file.title, :size => size)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user