X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/ae0177fbe61d7d02e3c6b441bd395fff6fd96a18..6294e9ae59d553278e733d0923e06160b3ae51c2:/app/helpers/application_helper.rb?ds=inline diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 4765cb35b..5d61e8c63 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -94,6 +94,14 @@ module ApplicationHelper end def body_class - [params[:controller], "#{params[:controller]}-#{params[:action]}", @extra_body_class].compact.join(" ") + if content_for? :body_class + content_for :body_class + else + "#{params[:controller]} #{params[:controller]}-#{params[:action]}" + end + end + + def current_page_class(path) + :current if current_page?(path) end end