diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 5b091b59..e2c93b86 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -3,7 +3,8 @@ module ApplicationHelper options = { badge: nil, badge_color: nil, - icon: nil + icon: nil, + class: '' }.merge(options) unless options[:icon].nil? @@ -17,7 +18,7 @@ module ApplicationHelper }"))}" end - content_tag(:li, link_to(body.html_safe, path), class: ('active' if current_page? path)) + content_tag(:li, link_to(body.html_safe, path), class: ("#{'active ' if current_page? path}#{options[:class]}")) end ##