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
Léo-Paul Géneau
gitlab-ce
Commits
4a5a130a
Commit
4a5a130a
authored
Oct 21, 2013
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'improve/ui' of /home/git/repositories/gitlab/gitlabhq
parents
1a923fe0
cf1416fa
Changes
14
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
216 additions
and
161 deletions
+216
-161
app/assets/javascripts/project.js.coffee
app/assets/javascripts/project.js.coffee
+3
-3
app/assets/stylesheets/common.scss
app/assets/stylesheets/common.scss
+0
-7
app/assets/stylesheets/gitlab_bootstrap/buttons.scss
app/assets/stylesheets/gitlab_bootstrap/buttons.scss
+7
-0
app/assets/stylesheets/gitlab_bootstrap/common.scss
app/assets/stylesheets/gitlab_bootstrap/common.scss
+7
-0
app/assets/stylesheets/sections/projects.scss
app/assets/stylesheets/sections/projects.scss
+67
-16
app/views/dashboard/projects.html.haml
app/views/dashboard/projects.html.haml
+5
-6
app/views/projects/_clone_panel.html.haml
app/views/projects/_clone_panel.html.haml
+0
-56
app/views/projects/_dropdown.html.haml
app/views/projects/_dropdown.html.haml
+34
-0
app/views/projects/empty.html.haml
app/views/projects/empty.html.haml
+4
-1
app/views/projects/labels/_label.html.haml
app/views/projects/labels/_label.html.haml
+8
-10
app/views/projects/show.html.haml
app/views/projects/show.html.haml
+51
-23
app/views/projects/wikis/git_access.html.haml
app/views/projects/wikis/git_access.html.haml
+25
-29
app/views/shared/_clone_panel.html.haml
app/views/shared/_clone_panel.html.haml
+2
-9
features/steps/public/projects_feature.rb
features/steps/public/projects_feature.rb
+3
-1
No files found.
app/assets/javascripts/project.js.coffee
View file @
4a5a130a
...
@@ -29,7 +29,7 @@ class Project
...
@@ -29,7 +29,7 @@ class Project
$
->
$
->
# Git clone panel switcher
# Git clone panel switcher
scope
=
$
'.
project_clone_
holder'
scope
=
$
'.
git-clone-
holder'
if
scope
.
length
>
0
if
scope
.
length
>
0
$
(
'a, button'
,
scope
).
click
->
$
(
'a, button'
,
scope
).
click
->
$
(
'a, button'
,
scope
).
removeClass
'active'
$
(
'a, button'
,
scope
).
removeClass
'active'
...
...
app/assets/stylesheets/common.scss
View file @
4a5a130a
...
@@ -86,13 +86,6 @@ span.update-author {
...
@@ -86,13 +86,6 @@ span.update-author {
font-weight
:
bold
;
font-weight
:
bold
;
}
}
.label
{
padding
:
1px
4px
;
font-size
:
12px
;
font-style
:
normal
;
font-weight
:
normal
;
}
.field_with_errors
{
.field_with_errors
{
display
:
inline
;
display
:
inline
;
}
}
...
...
app/assets/stylesheets/gitlab_bootstrap/buttons.scss
View file @
4a5a130a
...
@@ -138,4 +138,11 @@
...
@@ -138,4 +138,11 @@
margin-right
:
7px
;
margin-right
:
7px
;
float
:
left
;
float
:
left
;
}
}
&
.btn-block
{
width
:
100%
;
margin
:
0
;
padding
:
6px
0
;
margin-bottom
:
15px
;
}
}
}
app/assets/stylesheets/gitlab_bootstrap/common.scss
View file @
4a5a130a
...
@@ -88,6 +88,13 @@ pre.well-pre {
...
@@ -88,6 +88,13 @@ pre.well-pre {
@include
box-shadow
(
inset
0
2px
4px
rgba
(
0
,
0
,
0
,.
15
));
@include
box-shadow
(
inset
0
2px
4px
rgba
(
0
,
0
,
0
,.
15
));
}
}
.label
{
padding
:
2px
4px
;
font-size
:
12px
;
font-style
:
normal
;
font-weight
:
normal
;
}
/** Big Labels **/
/** Big Labels **/
.state-label
{
.state-label
{
font-size
:
14px
;
font-size
:
14px
;
...
...
app/assets/stylesheets/sections/projects.scss
View file @
4a5a130a
...
@@ -14,25 +14,76 @@
...
@@ -14,25 +14,76 @@
}
}
}
}
.project_clone_panel
{
.project-home-panel
{
border-bottom
:
1px
solid
#DDD
;
padding-bottom
:
30px
;
margin-bottom
:
30px
;
.project-home-title
{
font-size
:
18px
;
color
:
#777
;
margin
:
0
;
line-height
:
2
;
}
.project-home-dropdown
{
margin-left
:
10px
;
float
:
right
;
}
.project-home-extra
{
margin-top
:
15px
;
.project-home-desc
{
float
:
left
;
color
:
#999
;
}
.project-home-links
{
float
:
right
;
a
{
margin-left
:
10px
;
}
}
}
.public-label
{
font-size
:
14px
;
background
:
#f1f1f1
;
padding
:
6px
10px
;
border-radius
:
4px
;
margin-left
:
10px
;
color
:
#888
;
text-shadow
:
0
1px
1px
#FFF
;
}
}
.git-clone-holder
{
float
:
right
;
border
:
1px
solid
#E1E1E1
;
@include
border-radius
(
4px
);
@include
border-radius
(
4px
);
@include
bg-gray-gradient
;
padding
:
4px
7px
;
border
:
1px
solid
#CCC
;
margin-bottom
:
20px
;
.btn
{
.btn
{
padding
:
4px
12px
;
margin-left
:
3px
;
border
:
none
;
background
:
none
;
box-shadow
:
none
;
color
:
#29b
;
padding
:
6px
;
&
.active
{
color
:
#333
;
font-weight
:
bold
;
}
}
}
}
.project_clone_holder
{
input
[
type
=
"text"
]
{
input
[
type
=
"text"
]
{
margin-left
:
2px
;
border
:
none
;
border-radius
:
0
;
border-left
:
1px
solid
#E1E1E1
;
@extend
.monospace
;
@extend
.monospace
;
border
:
1px
solid
#BBB
;
box-shadow
:
none
;
box-shadow
:
none
;
margin-left
:
-1px
;
background
:
#FAFAFA
;
background
:
#FFF
;
padding
:
6px
10px
;
}
}
}
}
...
@@ -81,18 +132,18 @@ ul.nav.nav-projects-tabs {
...
@@ -81,18 +132,18 @@ ul.nav.nav-projects-tabs {
.my-projects
{
.my-projects
{
li
{
li
{
.project-title
{
font-size
:
14px
;
}
.project-info
{
.project-info
{
margin-bottom
:
10px
;
margin-bottom
:
10px
;
}
}
.access-icon
i
{
.access-icon
{
color
:
#AAA
;
margin-left
:
10px
;
i
{
color
:
#AAA
;
color
:
#AAA
;
}
}
}
}
}
}
}
.public-clone
{
.public-clone
{
...
...
app/views/dashboard/projects.html.haml
View file @
4a5a130a
...
@@ -56,13 +56,12 @@
...
@@ -56,13 +56,12 @@
-
@projects
.
each
do
|
project
|
-
@projects
.
each
do
|
project
|
%li
%li
%h4
.project-title
%h4
.project-title
%span
.access-icon
=
link_to
project_path
(
project
),
class:
dom_class
(
project
)
do
=
project
.
name_with_namespace
-
if
project
.
public
-
if
project
.
public
%small
.access-icon
=
public_icon
=
public_icon
-
else
Public
=
private_icon
=
link_to
project_path
(
project
),
class:
dom_class
(
project
)
do
%strong
=
project
.
name_with_namespace
-
if
project
.
forked_from_project
-
if
project
.
forked_from_project
%small
.pull-right
%small
.pull-right
...
...
app/views/projects/_clone_panel.html.haml
deleted
100644 → 0
View file @
1a923fe0
.project_clone_panel
.row
.span8
.form-horizontal
=
render
"shared/clone_panel"
.span3.pull-right
.pull-right
-
unless
@project
.
empty_repo?
-
if
current_user
&&
can?
(
current_user
,
:fork_project
,
@project
)
&&
@project
.
namespace
!=
current_user
.
namespace
-
if
current_user
.
already_forked?
(
@project
)
=
link_to
project_path
(
current_user
.
fork_of
(
@project
)),
class:
'btn grouped disabled'
do
%i
.icon-code-fork
Forked
-
else
=
link_to
fork_project_path
(
@project
),
title:
"Fork"
,
class:
"btn grouped"
,
method:
"POST"
do
%i
.icon-code-fork
Fork
-
if
can?
current_user
,
:download_code
,
@project
=
link_to
archive_project_repository_path
(
@project
),
class:
"btn grouped"
do
%i
.icon-download-alt
%span
.only-wide
Download
-
if
current_user
.dropdown.pull-right
%a
.dropdown-toggle.btn
{
href:
'#'
,
"data-toggle"
=>
"dropdown"
}
%i
.icon-plus-sign-alt
%span
.only-wide
New
%b
.caret
%ul
.dropdown-menu
-
if
@project
.
issues_enabled
&&
can?
(
current_user
,
:write_issue
,
@project
)
%li
=
link_to
url_for_new_issue
,
title:
"New Issue"
do
Issue
-
if
@project
.
merge_requests_enabled
&&
can?
(
current_user
,
:write_merge_request
,
@project
)
%li
=
link_to
new_project_merge_request_path
(
@project
),
title:
"New Merge Request"
do
Merge Request
-
if
@project
.
snippets_enabled
&&
can?
(
current_user
,
:write_snippet
,
@project
)
%li
=
link_to
new_project_snippet_path
(
@project
),
title:
"New Snippet"
do
Snippet
-
if
can?
current_user
,
:push_code
,
@project
%li
.divider
%li
=
link_to
new_project_branch_path
(
@project
)
do
%i
.icon-code-fork
Git branch
%li
=
link_to
new_project_tag_path
(
@project
)
do
%i
.icon-tag
Git tag
-
if
can?
(
current_user
,
:admin_team_member
,
@project
)
%li
.divider
%li
=
link_to
new_project_team_member_path
(
@project
),
title:
"New project member"
do
Project member
app/views/projects/_dropdown.html.haml
0 → 100644
View file @
4a5a130a
-
if
current_user
.dropdown.pull-right
%a
.dropdown-toggle.btn.btn-new
{
href:
'#'
,
"data-toggle"
=>
"dropdown"
}
%i
.icon-reorder
%ul
.dropdown-menu
-
if
@project
.
issues_enabled
&&
can?
(
current_user
,
:write_issue
,
@project
)
%li
=
link_to
url_for_new_issue
,
title:
"New Issue"
do
Issue
-
if
@project
.
merge_requests_enabled
&&
can?
(
current_user
,
:write_merge_request
,
@project
)
%li
=
link_to
new_project_merge_request_path
(
@project
),
title:
"New Merge Request"
do
Merge Request
-
if
@project
.
snippets_enabled
&&
can?
(
current_user
,
:write_snippet
,
@project
)
%li
=
link_to
new_project_snippet_path
(
@project
),
title:
"New Snippet"
do
Snippet
-
if
can?
current_user
,
:push_code
,
@project
%li
.divider
%li
=
link_to
new_project_branch_path
(
@project
)
do
%i
.icon-code-fork
Git branch
%li
=
link_to
new_project_tag_path
(
@project
)
do
%i
.icon-tag
Git tag
-
if
can?
(
current_user
,
:admin_team_member
,
@project
)
%li
.divider
%li
=
link_to
new_project_team_member_path
(
@project
),
title:
"New project member"
do
Project member
app/views/projects/empty.html.haml
View file @
4a5a130a
=
render
'clone_panel'
%h3
.page-title
=
@project
.
name_with_namespace
.form-horizontal.pull-right
=
render
"shared/clone_panel"
-
if
@project
.
import?
&&
!
@project
.
imported
-
if
@project
.
import?
&&
!
@project
.
imported
.save-project-loader
.save-project-loader
...
...
app/views/projects/labels/_label.html.haml
View file @
4a5a130a
-
frequency
=
@project
.
issues
.
tagged_with
(
label
.
name
).
count
-
frequency
=
@project
.
issues
.
tagged_with
(
label
.
name
).
count
%li
%li
%strong
%span
{
class:
"label #{label_css_class(label.name)}"
}
%span
{
class:
"label #{label_css_class(label.name)}"
}
%i
.icon-tag
%i
.icon-tag
-
if
frequency
.
zero?
-
if
frequency
.
zero?
...
@@ -10,6 +9,5 @@
...
@@ -10,6 +9,5 @@
.pull-right
.pull-right
-
unless
frequency
.
zero?
-
unless
frequency
.
zero?
=
link_to
project_issues_path
(
label_name:
label
.
name
)
do
=
link_to
project_issues_path
(
label_name:
label
.
name
)
do
%strong
=
pluralize
(
frequency
,
'issue'
)
=
pluralize
(
frequency
,
'issue'
)
=
"»"
=
"»"
app/views/projects/show.html.haml
View file @
4a5a130a
=
render
'clone_panel'
.project-home-panel
.row
.span4
%h4
.project-home-title
=
@project
.
name_with_namespace
-
if
@project
.
public
%span
.public-label
Public
-
else
%span
.public-label
Private
.span8
.project-home-dropdown
=
render
"dropdown"
.form-horizontal
=
render
"shared/clone_panel"
.project-home-extra.clearfix
.project-home-desc
-
if
@project
.
description
.
present?
=
@project
.
description
-
if
can?
(
current_user
,
:admin_project
,
@project
)
–
%strong
=
link_to
'Edit'
,
edit_project_path
.project-home-links
=
link_to
pluralize
(
@repository
.
round_commit_count
,
'commit'
),
project_commits_path
(
@project
,
@ref
||
@repository
.
root_ref
)
=
link_to
pluralize
(
@repository
.
branch_names
.
count
,
'branch'
),
project_branches_path
(
@project
)
=
link_to
pluralize
(
@repository
.
tag_names
.
count
,
'tag'
),
project_tags_path
(
@project
)
%span
.light.prepend-left-20
=
repository_size
.row
.row
.span9
.span9
...
@@ -7,17 +35,29 @@
...
@@ -7,17 +35,29 @@
.content_list
.content_list
.loading.hide
.loading.hide
.span3
.span3
.light-well
.clearfix
%h3
.page-title
-
if
@project
.
forked_from_project
=
@project
.
name
.alert.alert-success
-
if
@project
.
description
.
present?
%i
.icon-code-fork
%p
.light
=
@project
.
description
Forked from:
=
link_to
@project
.
forked_from_project
.
name_with_namespace
,
project_path
(
@project
.
forked_from_project
)
-
unless
@project
.
empty_repo?
-
if
current_user
&&
can?
(
current_user
,
:fork_project
,
@project
)
&&
@project
.
namespace
!=
current_user
.
namespace
-
if
current_user
.
already_forked?
(
@project
)
=
link_to
project_path
(
current_user
.
fork_of
(
@project
)),
class:
'btn btn-block'
do
%i
.icon-ok
Already forked
-
else
=
link_to
fork_project_path
(
@project
),
title:
"Fork"
,
class:
"btn btn-block"
,
method:
"POST"
do
%i
.icon-code-fork
Fork repository
%hr
-
if
can?
current_user
,
:download_code
,
@project
%p
=
link_to
archive_project_repository_path
(
@project
),
class:
"btn btn-block"
do
%p
%i
.icon-download-alt
%span
.light
Repo size is
%span
Download
=
repository_size
%br
.light-well
%p
%p
%span
.light
Created at
%span
.light
Created at
#{
@project
.
created_at
.
stamp
(
'Aug 22, 2013'
)
}
#{
@project
.
created_at
.
stamp
(
'Aug 22, 2013'
)
}
...
@@ -27,19 +67,7 @@
...
@@ -27,19 +67,7 @@
#{
link_to
@project
.
group
.
name
,
@project
.
group
}
Group
#{
link_to
@project
.
group
.
name
,
@project
.
group
}
Group
-
else
-
else
#{
link_to
@project
.
owner_name
,
@project
.
owner
}
#{
link_to
@project
.
owner_name
,
@project
.
owner
}
-
if
@project
.
forked_from_project
%p
%i
.icon-code-fork
Forked from:
=
link_to
@project
.
forked_from_project
.
name_with_namespace
,
project_path
(
@project
.
forked_from_project
)
%hr
%p
=
link_to
pluralize
(
@repository
.
round_commit_count
,
'commit'
),
project_commits_path
(
@project
,
@ref
||
@repository
.
root_ref
)
%p
=
link_to
pluralize
(
@repository
.
branch_names
.
count
,
'branch'
),
project_branches_path
(
@project
)
%p
=
link_to
pluralize
(
@repository
.
tag_names
.
count
,
'tag'
),
project_tags_path
(
@project
)
-
if
@project
.
gitlab_ci?
-
if
@project
.
gitlab_ci?
%hr
%hr
...
...
app/views/projects/wikis/git_access.html.haml
View file @
4a5a130a
...
@@ -2,18 +2,14 @@
...
@@ -2,18 +2,14 @@
%h3
.page-title
%h3
.page-title
Git access for
Git access for
%strong
=
@gollum_wiki
.
path_with_namespace
%strong
=
@gollum_wiki
.
path_with_namespace
=
render
'main_links'
.content
.form-horizontal.pull-right
.project_clone_panel
.git-clone-holder
.row
.span7
.form-horizontal
.input-prepend.project_clone_holder
%button
{
class:
"btn active"
,
:"data-clone"
=>
@gollum_wiki
.
ssh_url_to_repo
}
SSH
%button
{
class:
"btn active"
,
:"data-clone"
=>
@gollum_wiki
.
ssh_url_to_repo
}
SSH
%button
{
class:
"btn"
,
:"data-clone"
=>
@gollum_wiki
.
http_url_to_repo
}=
gitlab_config
.
protocol
.
upcase
%button
{
class:
"btn"
,
:"data-clone"
=>
@gollum_wiki
.
http_url_to_repo
}=
gitlab_config
.
protocol
.
upcase
=
text_field_tag
:project_clone
,
@gollum_wiki
.
url_to_repo
,
class:
"one_click_select input-xxlarge"
,
readonly:
true
=
text_field_tag
:project_clone
,
@gollum_wiki
.
url_to_repo
,
class:
"one_click_select input-xxlarge"
,
readonly:
true
.git-empty
.git-empty
%fieldset
%fieldset
%legend
Install Gollum:
%legend
Install Gollum:
%pre
.dark
%pre
.dark
...
...
app/views/shared/_clone_panel.html.haml
View file @
4a5a130a
.
input-prepend.input-append.project_clone_
holder
.
git-clone-
holder
%button
{
class:
"btn active"
,
:"data-clone"
=>
@project
.
ssh_url_to_repo
}
SSH
%button
{
class:
"btn active"
,
:"data-clone"
=>
@project
.
ssh_url_to_repo
}
SSH
%button
{
class:
"btn"
,
:"data-clone"
=>
@project
.
http_url_to_repo
}=
gitlab_config
.
protocol
.
upcase
%button
{
class:
"btn"
,
:"data-clone"
=>
@project
.
http_url_to_repo
}=
gitlab_config
.
protocol
.
upcase
=
text_field_tag
:project_clone
,
@project
.
url_to_repo
,
class:
"one_click_select span7"
,
readonly:
true
=
text_field_tag
:project_clone
,
@project
.
url_to_repo
,
class:
"one_click_select span5"
,
readonly:
true
%span
.add-on
-
if
@project
.
public
=
public_icon
%span
.cblue
public
-
else
=
private_icon
%span
.cgreen
private
features/steps/public/projects_feature.rb
View file @
4a5a130a
...
@@ -49,7 +49,9 @@ class Spinach::Features::PublicProjectsFeature < Spinach::FeatureSteps
...
@@ -49,7 +49,9 @@ class Spinach::Features::PublicProjectsFeature < Spinach::FeatureSteps
end
end
step
'I should see project "Community" home page'
do
step
'I should see project "Community" home page'
do
page
.
should
have_content
'Repo size is'
within
'.project-home-title'
do
page
.
should
have_content
'Community'
end
end
end
private
private
...
...
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