Improve project fork page
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
This commit is contained in:
parent
6933da1ee0
commit
df51b029ab
2 changed files with 20 additions and 27 deletions
|
@ -203,26 +203,18 @@ ul.nav.nav-projects-tabs {
|
|||
}
|
||||
|
||||
.fork-namespaces {
|
||||
.thumbnail {
|
||||
|
||||
&.fork-exists-thumbnail {
|
||||
border-color: #EEE;
|
||||
.fork-thumbnail {
|
||||
text-align: center;
|
||||
margin-bottom: $gl-padding;
|
||||
|
||||
.caption {
|
||||
color: #999;
|
||||
}
|
||||
padding: $gl-padding 0;
|
||||
min-height: 30px;
|
||||
}
|
||||
|
||||
&.fork-thumbnail {
|
||||
border-color: #AAA;
|
||||
|
||||
&:hover {
|
||||
background-color: $hover;
|
||||
}
|
||||
}
|
||||
|
||||
a {
|
||||
text-decoration: none;
|
||||
img {
|
||||
@include border-radius(50%);
|
||||
max-width: 100px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -10,21 +10,22 @@
|
|||
- group.each do |namespace|
|
||||
.col-md-2.col-sm-3
|
||||
- if fork = namespace.find_fork_of(@project)
|
||||
.thumbnail.fork-exists-thumbnail
|
||||
.fork-thumbnail
|
||||
= link_to project_path(fork), title: "Visit project fork", class: 'has_tooltip' do
|
||||
= image_tag namespace_icon(namespace, 200)
|
||||
= image_tag namespace_icon(namespace, 100)
|
||||
.caption
|
||||
%h4=namespace.human_name
|
||||
%p
|
||||
= namespace.path
|
||||
%strong
|
||||
= namespace.human_name
|
||||
%div.text-primary
|
||||
Already forked
|
||||
|
||||
- else
|
||||
.thumbnail.fork-thumbnail
|
||||
.fork-thumbnail
|
||||
= link_to namespace_project_fork_path(@project.namespace, @project, namespace_key: namespace.id), title: "Fork here", method: "POST", class: 'has_tooltip' do
|
||||
= image_tag namespace_icon(namespace, 200)
|
||||
= image_tag namespace_icon(namespace, 100)
|
||||
.caption
|
||||
%h4=namespace.human_name
|
||||
%p
|
||||
= namespace.path
|
||||
%strong
|
||||
= namespace.human_name
|
||||
|
||||
%p.light
|
||||
Fork is a copy of a project repository.
|
||||
|
|
Loading…
Reference in a new issue