summaryrefslogtreecommitdiffstats
path: root/app/helpers/icons_helper.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/helpers/icons_helper.rb')
-rw-r--r--app/helpers/icons_helper.rb14
1 files changed, 7 insertions, 7 deletions
diff --git a/app/helpers/icons_helper.rb b/app/helpers/icons_helper.rb
index 5654f3a2f..f423a2898 100644
--- a/app/helpers/icons_helper.rb
+++ b/app/helpers/icons_helper.rb
@@ -36,20 +36,20 @@ module IconsHelper
end
end
- def file_icon(entry, name, size: DEFAULT_ICON_SIZE, css_class: nil)
+ def file_icon(entry, name, **options)
if entry.is_dir?
- sprite_icon("folder", name, size: size, css_class: css_class)
+ sprite_icon("folder", name, **options)
else
icon_name = icon_for_mime_type(Redmine::MimeType.css_class_of(name))
- sprite_icon(icon_name, name, size: size, css_class: css_class)
+ sprite_icon(icon_name, name, **options)
end
end
- def principal_icon(principal_class, size: DEFAULT_ICON_SIZE, css_class: nil)
- sprite_icon('group', size: size, css_class: css_class) if ['groupanonymous', 'groupnonmember', 'group'].include?(principal_class)
+ def principal_icon(principal_class, **options)
+ sprite_icon('group', **options) if ['groupanonymous', 'groupnonmember', 'group'].include?(principal_class)
end
- def activity_event_type_icon(event_type, size: DEFAULT_ICON_SIZE, css_class: nil)
+ def activity_event_type_icon(event_type, **options)
icon_name = case event_type
when 'reply'
'comments'
@@ -61,7 +61,7 @@ module IconsHelper
event_type
end
- sprite_icon(icon_name, size: size, css_class: css_class)
+ sprite_icon(icon_name, **options)
end
private