Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
gitlab-ce
Commits
eb80edd3
Commit
eb80edd3
authored
Jun 09, 2015
by
Douwe Maan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move page-specific JS out of head and into body.
parent
4d6a338c
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
4 deletions
+5
-4
app/views/layouts/_head.html.haml
app/views/layouts/_head.html.haml
+0
-2
app/views/layouts/application.html.haml
app/views/layouts/application.html.haml
+3
-0
app/views/layouts/project.html.haml
app/views/layouts/project.html.haml
+2
-2
No files found.
app/views/layouts/_head.html.haml
View file @
eb80edd3
...
...
@@ -20,5 +20,3 @@
=
render
'layouts/google_analytics'
if
extra_config
.
has_key?
(
'google_analytics_id'
)
=
render
'layouts/piwik'
if
extra_config
.
has_key?
(
'piwik_url'
)
&&
extra_config
.
has_key?
(
'piwik_site_id'
)
=
render
'layouts/bootlint'
if
Rails
.
env
.
development?
=
yield
:scripts_head
app/views/layouts/application.html.haml
View file @
eb80edd3
...
...
@@ -2,6 +2,9 @@
%html
{
lang:
"en"
}
=
render
"layouts/head"
%body
{
class:
"#{app_theme}"
,
:'data-page'
=>
body_data_page
}
/ Ideally this would be inside the head, but turbolinks only evaluates page-specific JS in the body.
=
yield
:scripts_body_top
-
if
current_user
=
render
"layouts/header/default"
,
title:
header_title
-
else
...
...
app/views/layouts/project.html.haml
View file @
eb80edd3
...
...
@@ -2,8 +2,8 @@
-
header_title
project_title
(
@project
)
-
sidebar
"project"
unless
sidebar
-
content_for
:scripts_
head
do
-
if
current_user
-
content_for
:scripts_
body_top
do
-
if
current_user
:javascript
window
.
project_uploads_path
=
"
#{
namespace_project_uploads_path
@project
.
namespace
,
@project
}
"
;
window
.
markdown_preview_path
=
"
#{
markdown_preview_namespace_project_path
(
@project
.
namespace
,
@project
)
}
"
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment