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
Tatuya Kamada
gitlab-ce
Commits
2d2cdd64
Commit
2d2cdd64
authored
Feb 16, 2017
by
Robert Speicher
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch '27281-devicon' into 'master'
override favicon for development to find tabs more easily See merge request !9260
parents
3050082e
679ce9db
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
17 additions
and
1 deletion
+17
-1
app/assets/images/favicon-blue.ico
app/assets/images/favicon-blue.ico
+0
-0
app/helpers/page_layout_helper.rb
app/helpers/page_layout_helper.rb
+4
-0
app/views/layouts/_head.html.haml
app/views/layouts/_head.html.haml
+1
-1
spec/helpers/page_layout_helper_spec.rb
spec/helpers/page_layout_helper_spec.rb
+12
-0
No files found.
app/assets/images/favicon-blue.ico
0 → 100644
View file @
2d2cdd64
5.3 KB
app/helpers/page_layout_helper.rb
View file @
2d2cdd64
...
@@ -34,6 +34,10 @@ module PageLayoutHelper
...
@@ -34,6 +34,10 @@ module PageLayoutHelper
end
end
end
end
def
favicon
Rails
.
env
.
development?
?
'favicon-blue.ico'
:
'favicon.ico'
end
def
page_image
def
page_image
default
=
image_url
(
'gitlab_logo.png'
)
default
=
image_url
(
'gitlab_logo.png'
)
...
...
app/views/layouts/_head.html.haml
View file @
2d2cdd64
...
@@ -23,7 +23,7 @@
...
@@ -23,7 +23,7 @@
%title
=
page_title
(
site_name
)
%title
=
page_title
(
site_name
)
%meta
{
name:
"description"
,
content:
page_description
}
%meta
{
name:
"description"
,
content:
page_description
}
=
favicon_link_tag
'favicon.ico'
=
favicon_link_tag
favicon
=
stylesheet_link_tag
"application"
,
media:
"all"
=
stylesheet_link_tag
"application"
,
media:
"all"
=
stylesheet_link_tag
"print"
,
media:
"print"
=
stylesheet_link_tag
"print"
,
media:
"print"
...
...
spec/helpers/page_layout_helper_spec.rb
View file @
2d2cdd64
...
@@ -40,6 +40,18 @@ describe PageLayoutHelper do
...
@@ -40,6 +40,18 @@ describe PageLayoutHelper do
end
end
end
end
describe
'favicon'
do
it
'defaults to favicon.ico'
do
allow
(
Rails
).
to
receive
(
:env
).
and_return
(
ActiveSupport
::
StringInquirer
.
new
(
'production'
))
expect
(
helper
.
favicon
).
to
eq
'favicon.ico'
end
it
'has blue favicon for development'
do
allow
(
Rails
).
to
receive
(
:env
).
and_return
(
ActiveSupport
::
StringInquirer
.
new
(
'development'
))
expect
(
helper
.
favicon
).
to
eq
'favicon-blue.ico'
end
end
describe
'page_image'
do
describe
'page_image'
do
it
'defaults to the GitLab logo'
do
it
'defaults to the GitLab logo'
do
expect
(
helper
.
page_image
).
to
end_with
'assets/gitlab_logo.png'
expect
(
helper
.
page_image
).
to
end_with
'assets/gitlab_logo.png'
...
...
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