Commit 99b49d6e545471340ef0f7c09e515663c81b19df

Authored by Larissa Reis
1 parent 1de55ac6

[media-panel-improvements] Fixes article form css

Showing 1 changed file with 4 additions and 2 deletions   Show diff stats
app/views/cms/edit.html.erb
1 1 <%= error_messages_for 'article' %>
2 2  
3   -<div class='<%= (environment.enabled?('media_panel') ? 'with_media_panel' : 'no_media_panel') %>'>
  3 +<% show_media_panel = environment.enabled?('media_panel') && [TinyMceArticle, TextileArticle, Event, EnterpriseHomepage].any?{|klass| @article.kind_of?(klass)} %>
  4 +
  5 +<div class='<%= (show_media_panel ? 'with_media_panel' : 'no_media_panel') %>'>
4 6 <%= labelled_form_for 'article', :html => { :multipart => true, :class => @type } do |f| %>
5 7  
6 8 <%= hidden_field_tag("type", @type) if @type %>
... ... @@ -66,7 +68,7 @@
66 68 <% end %>
67 69 </div>
68 70  
69   -<% if environment.enabled?('media_panel') && [TinyMceArticle, TextileArticle, Event, EnterpriseHomepage].any?{|klass| @article.kind_of?(klass)} %>
  71 +<% if show_media_panel %>
70 72 <%= render :partial => 'text_editor_sidebar' %>
71 73 <% end %>
72 74  
... ...