X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/8dc16bd8dbd362a0e823f8abd989d871ce5de32f..9029e47ce9e41a220710d117868e14d8cd1c719a:/app/helpers/application_helper.rb 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