Skip to content

Commit

Permalink
Merge pull request #561 from projecthydra-labs/no_turbolinks_on_links…
Browse files Browse the repository at this point in the history
…_to_tinymce_views

Prevent using TurboLinks on links to views that use TinyMCE
  • Loading branch information
mjgiarlo committed Dec 19, 2016
2 parents 6a8c5ec + dd29b8b commit 1c517bf
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions app/presenters/hyku/menu_presenter.rb
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ def user_activity_section?
end
end

def nav_link(href)
def nav_link(href, **link_options)
content_tag(:li, class: ('active' if current_page?(href))) do
link_to(href) do
link_to(href, link_options) do
yield
end
end
Expand Down
2 changes: 1 addition & 1 deletion app/views/hyrax/admin/_sidebar.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
<%= menu.nav_link(main_app.edit_site_appearances_path) do %>
<span class="fa fa-paint-brush"></span> <%= t('hyrax.admin.sidebar.appearance') %>
<% end %>
<%= menu.nav_link(main_app.edit_site_content_blocks_path) do %>
<%= menu.nav_link(main_app.edit_site_content_blocks_path, :'data-no-turbolink' => "true") do %>
<span class="fa fa-file-text-o"></span> <%= t('hyrax.admin.sidebar.content_blocks') %>
<% end %>
<% end %>
Expand Down

0 comments on commit 1c517bf

Please sign in to comment.