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
Jérome Perrin
gitlab-ce
Commits
55795b7c
Commit
55795b7c
authored
Jun 14, 2014
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improve breadcrumbs
Signed-off-by:
Dmitriy Zaporozhets
<
dmitriy.zaporozhets@gmail.com
>
parent
1555146a
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
37 additions
and
48 deletions
+37
-48
app/assets/stylesheets/generic/common.scss
app/assets/stylesheets/generic/common.scss
+0
-6
app/assets/stylesheets/gl_bootstrap.scss
app/assets/stylesheets/gl_bootstrap.scss
+0
-14
app/assets/stylesheets/sections/commits.scss
app/assets/stylesheets/sections/commits.scss
+7
-4
app/assets/stylesheets/sections/projects.scss
app/assets/stylesheets/sections/projects.scss
+12
-0
app/assets/stylesheets/sections/tree.scss
app/assets/stylesheets/sections/tree.scss
+0
-4
app/helpers/commits_helper.rb
app/helpers/commits_helper.rb
+3
-5
app/views/projects/commits/_head.html.haml
app/views/projects/commits/_head.html.haml
+0
-8
app/views/projects/commits/show.html.haml
app/views/projects/commits/show.html.haml
+13
-5
app/views/projects/tree/_tree.html.haml
app/views/projects/tree/_tree.html.haml
+1
-1
app/views/projects/tree/show.html.haml
app/views/projects/tree/show.html.haml
+1
-1
No files found.
app/assets/stylesheets/generic/common.scss
View file @
55795b7c
...
@@ -59,12 +59,6 @@ pre {
...
@@ -59,12 +59,6 @@ pre {
color
:
#FFF
color
:
#FFF
}
}
.breadcrumb
>
li
+
li
:before
{
content
:
"/"
;
padding
:
0
;
color
:
#666
;
}
.str-truncated
{
.str-truncated
{
@include
str-truncated
;
@include
str-truncated
;
}
}
...
...
app/assets/stylesheets/gl_bootstrap.scss
View file @
55795b7c
...
@@ -199,20 +199,6 @@ $list-group-active-bg: $bg_style_color;
...
@@ -199,20 +199,6 @@ $list-group-active-bg: $bg_style_color;
color
:
#3c763d
;
color
:
#3c763d
;
}
}
// Breadcrumb
ul
.breadcrumb
{
background
:
white
;
border
:
none
;
li
{
display
:
inline
;
text-shadow
:
0
1px
0
white
}
a
{
font-size
:
16px
;
}
}
/**
/**
* fix to keep tooltips position in top navigation bar
* fix to keep tooltips position in top navigation bar
*
*
...
...
app/assets/stylesheets/sections/commits.scss
View file @
55795b7c
...
@@ -115,10 +115,6 @@
...
@@ -115,10 +115,6 @@
line-height
:
2
;
line-height
:
2
;
}
}
.commit-breadcrumb
{
padding
:
0
;
}
.commit-info-row
{
.commit-info-row
{
margin-bottom
:
10px
;
margin-bottom
:
10px
;
.avatar
{
.avatar
{
...
@@ -210,3 +206,10 @@ li.commit {
...
@@ -210,3 +206,10 @@ li.commit {
}
}
}
}
}
}
.commits-feed-holder
{
float
:
right
;
.btn
{
padding
:
4px
12px
;
}
}
app/assets/stylesheets/sections/projects.scss
View file @
55795b7c
...
@@ -239,3 +239,15 @@ ul.nav.nav-projects-tabs {
...
@@ -239,3 +239,15 @@ ul.nav.nav-projects-tabs {
.vs-private
{
.vs-private
{
color
:
$bg_success
;
color
:
$bg_success
;
}
}
.breadcrumb.repo-breadcrumb
{
padding
:
2px
0
;
background
:
white
;
border
:
none
;
font-size
:
16px
;
>
li
+
li
:before
{
padding
:
0
3px
;
color
:
#999
;
}
}
app/assets/stylesheets/sections/tree.scss
View file @
55795b7c
...
@@ -4,10 +4,6 @@
...
@@ -4,10 +4,6 @@
width
:
100%
;
width
:
100%
;
}
}
.breadcrumb
{
padding
:
2px
0
;
}
.tree_progress
{
.tree_progress
{
display
:
none
;
display
:
none
;
margin
:
20px
;
margin
:
20px
;
...
...
app/helpers/commits_helper.rb
View file @
55795b7c
...
@@ -76,15 +76,13 @@ module CommitsHelper
...
@@ -76,15 +76,13 @@ module CommitsHelper
# Add the root project link and the arrow icon
# Add the root project link and the arrow icon
crumbs
=
content_tag
(
:li
)
do
crumbs
=
content_tag
(
:li
)
do
content_tag
(
:span
,
nil
,
class:
'arrow'
)
+
link_to
(
@project
.
path
,
project_commits_path
(
@project
,
@ref
))
link_to
(
@project
.
name
,
project_commits_path
(
@project
,
@ref
))
end
end
if
@path
if
@path
parts
=
@path
.
split
(
'/'
)
parts
=
@path
.
split
(
'/'
)
parts
.
each_with_index
do
|
part
,
i
|
parts
.
each_with_index
do
|
part
,
i
|
crumbs
+=
content_tag
(
:span
,
' / '
,
class:
'divider'
)
crumbs
+=
content_tag
(
:li
)
do
crumbs
+=
content_tag
(
:li
)
do
# The text is just the individual part, but the link needs all the parts before it
# The text is just the individual part, but the link needs all the parts before it
link_to
part
,
project_commits_path
(
@project
,
tree_join
(
@ref
,
parts
[
0
..
i
].
join
(
'/'
)))
link_to
part
,
project_commits_path
(
@project
,
tree_join
(
@ref
,
parts
[
0
..
i
].
join
(
'/'
)))
...
@@ -195,11 +193,11 @@ module CommitsHelper
...
@@ -195,11 +193,11 @@ module CommitsHelper
def
commit_person_link
(
commit
,
options
=
{})
def
commit_person_link
(
commit
,
options
=
{})
source_name
=
commit
.
send
"
#{
options
[
:source
]
}
_name"
.
to_sym
source_name
=
commit
.
send
"
#{
options
[
:source
]
}
_name"
.
to_sym
source_email
=
commit
.
send
"
#{
options
[
:source
]
}
_email"
.
to_sym
source_email
=
commit
.
send
"
#{
options
[
:source
]
}
_email"
.
to_sym
user
=
User
.
find_for_commit
(
source_email
,
source_name
)
user
=
User
.
find_for_commit
(
source_email
,
source_name
)
person_name
=
user
.
nil?
?
source_name
:
user
.
name
person_name
=
user
.
nil?
?
source_name
:
user
.
name
person_email
=
user
.
nil?
?
source_email
:
user
.
email
person_email
=
user
.
nil?
?
source_email
:
user
.
email
text
=
if
options
[
:avatar
]
text
=
if
options
[
:avatar
]
avatar
=
image_tag
(
avatar_icon
(
person_email
,
options
[
:size
]),
class:
"avatar
#{
"s
#{
options
[
:size
]
}
"
if
options
[
:size
]
}
"
,
width:
options
[
:size
],
alt:
""
)
avatar
=
image_tag
(
avatar_icon
(
person_email
,
options
[
:size
]),
class:
"avatar
#{
"s
#{
options
[
:size
]
}
"
if
options
[
:size
]
}
"
,
width:
options
[
:size
],
alt:
""
)
%Q{
#{
avatar
}
<span class="commit-
#{
options
[
:source
]
}
-name">
#{
person_name
}
</span>}
%Q{
#{
avatar
}
<span class="commit-
#{
options
[
:source
]
}
-name">
#{
person_name
}
</span>}
...
...
app/views/projects/commits/_head.html.haml
View file @
55795b7c
%ul
.nav.nav-tabs
%ul
.nav.nav-tabs
%li
=
render
partial:
'shared/ref_switcher'
,
locals:
{
destination:
'commits'
}
=
nav_link
(
controller:
[
:commit
,
:commits
])
do
=
nav_link
(
controller:
[
:commit
,
:commits
])
do
=
link_to
'Commits'
,
project_commits_path
(
@project
,
@repository
.
root_ref
)
=
link_to
'Commits'
,
project_commits_path
(
@project
,
@repository
.
root_ref
)
=
nav_link
(
controller: :compare
)
do
=
nav_link
(
controller: :compare
)
do
...
@@ -19,9 +17,3 @@
...
@@ -19,9 +17,3 @@
=
nav_link
(
controller: :repositories
,
action: :stats
)
do
=
nav_link
(
controller: :repositories
,
action: :stats
)
do
=
link_to
stats_project_repository_path
(
@project
)
do
=
link_to
stats_project_repository_path
(
@project
)
do
Stats
Stats
-
if
current_user
&&
current_controller?
(
:commits
)
&&
current_user
.
private_token
%li
.pull-right.hidden-sm
=
link_to
project_commits_path
(
@project
,
@ref
,
{
format: :atom
,
private_token:
current_user
.
private_token
}),
title:
"Feed"
do
%i
.icon-rss
app/views/projects/commits/show.html.haml
View file @
55795b7c
=
render
"head"
=
render
"head"
-
if
@path
.
present?
.tree-ref-holder
%ul
.breadcrumb.commit-breadcrumb
=
render
'shared/ref_switcher'
,
destination:
'commits'
%li
.light
History for
-
if
current_user
&&
current_user
.
private_token
=
commits_breadcrumbs
.commits-feed-holder.hidden-xs.hidden-sm
=
link_to
project_commits_path
(
@project
,
@ref
,
{
format: :atom
,
private_token:
current_user
.
private_token
}),
title:
"Feed"
,
class:
'btn'
do
%i
.icon-rss
Commits feed
%ul
.breadcrumb.repo-breadcrumb
=
commits_breadcrumbs
%li
.active
commits
%div
{
id:
dom_id
(
@project
)}
%div
{
id:
dom_id
(
@project
)}
#commits-list
=
render
"commits"
#commits-list
=
render
"commits"
...
...
app/views/projects/tree/_tree.html.haml
View file @
55795b7c
%ul
.breadcrumb
%ul
.breadcrumb
.repo-breadcrumb
%li
%li
=
link_to
project_tree_path
(
@project
,
@ref
)
do
=
link_to
project_tree_path
(
@project
,
@ref
)
do
=
@project
.
path
=
@project
.
path
...
...
app/views/projects/tree/show.html.haml
View file @
55795b7c
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
-
if
can?
current_user
,
:download_code
,
@project
-
if
can?
current_user
,
:download_code
,
@project
.tree-download-holder
.tree-download-holder
=
render
'projects/repositories/download_archive'
,
ref:
@ref
,
btn_class:
'btn-group-small pull-right hidden-xs'
,
split_button:
true
=
render
'projects/repositories/download_archive'
,
ref:
@ref
,
btn_class:
'btn-group-small pull-right hidden-xs
hidden-sm
'
,
split_button:
true
#tree-holder
.tree-holder.clearfix
#tree-holder
.tree-holder.clearfix
=
render
"tree"
,
tree:
@tree
=
render
"tree"
,
tree:
@tree
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