Moved loading GFM source into zen.html.haml

This commit is contained in:
Phil Hughes 2016-09-16 10:52:41 +01:00
parent 9c5638fb5b
commit b66a8203ca
2 changed files with 3 additions and 2 deletions

View file

@ -10,5 +10,4 @@
= render "layouts/header/default", title: header_title
= render 'layouts/page', sidebar: sidebar, nav: nav
= render "layouts/init_auto_complete" if current_user && @load_gfm
= yield :scripts_body

View file

@ -1,4 +1,3 @@
- @load_gfm = !(@target_project || @project).nil?
- supports_slash_commands = local_assigns.fetch(:supports_slash_commands, false)
.zen-backdrop
- classes << ' js-gfm-input js-autosize markdown-area'
@ -8,3 +7,6 @@
= text_area_tag attr, nil, class: classes, placeholder: placeholder
%a.zen-control.zen-control-leave.js-zen-leave{ href: "#" }
= icon('compress')
- content_for :scripts_body do
= render "layouts/init_auto_complete" if current_user && (@target_project || @project)