From c6a8472de2425a544945321739f5500baf8ebdec Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Fri, 6 Sep 2024 12:46:55 -0400 Subject: [PATCH] Move shares/modal body class to layout (#31789) --- app/controllers/shares_controller.rb | 7 ------- app/views/layouts/modal.html.haml | 2 ++ 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/app/controllers/shares_controller.rb b/app/controllers/shares_controller.rb index 6546b8497808c4..1aa0ce5a0d4ff4 100644 --- a/app/controllers/shares_controller.rb +++ b/app/controllers/shares_controller.rb @@ -4,13 +4,6 @@ class SharesController < ApplicationController layout 'modal' before_action :authenticate_user! - before_action :set_body_classes def show; end - - private - - def set_body_classes - @body_classes = 'modal-layout compose-standalone' - end end diff --git a/app/views/layouts/modal.html.haml b/app/views/layouts/modal.html.haml index bbc9185f5b3506..91bcb7c422d25b 100644 --- a/app/views/layouts/modal.html.haml +++ b/app/views/layouts/modal.html.haml @@ -1,6 +1,8 @@ - content_for :header_tags do = javascript_pack_tag 'public', crossorigin: 'anonymous' +- content_for :body_classes, 'modal-layout compose-standalone' + - content_for :content do - if user_signed_in? && !@hide_header .account-header