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
2f87703c
Commit
2f87703c
authored
Dec 16, 2016
by
Annabel Dunstone Gray
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move all project buttons to header
parent
8c2297f0
Changes
9
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
29 additions
and
33 deletions
+29
-33
app/assets/stylesheets/framework/mobile.scss
app/assets/stylesheets/framework/mobile.scss
+1
-1
app/assets/stylesheets/pages/projects.scss
app/assets/stylesheets/pages/projects.scss
+8
-7
app/views/projects/_home_panel.html.haml
app/views/projects/_home_panel.html.haml
+12
-6
app/views/projects/buttons/_download.html.haml
app/views/projects/buttons/_download.html.haml
+1
-1
app/views/projects/buttons/_dropdown.html.haml
app/views/projects/buttons/_dropdown.html.haml
+1
-1
app/views/projects/buttons/_koding.html.haml
app/views/projects/buttons/_koding.html.haml
+3
-3
app/views/projects/show.html.haml
app/views/projects/show.html.haml
+1
-12
app/views/shared/members/_access_request_buttons.html.haml
app/views/shared/members/_access_request_buttons.html.haml
+1
-1
app/views/shared/notifications/_button.html.haml
app/views/shared/notifications/_button.html.haml
+1
-1
No files found.
app/assets/stylesheets/framework/mobile.scss
View file @
2f87703c
...
@@ -54,7 +54,7 @@
...
@@ -54,7 +54,7 @@
}
}
// Display Star and Fork buttons without counters on mobile.
// Display Star and Fork buttons without counters on mobile.
.project-
action
-buttons
{
.project-
repo
-buttons
{
display
:
block
;
display
:
block
;
.count-buttons
.btn
{
.count-buttons
.btn
{
...
...
app/assets/stylesheets/pages/projects.scss
View file @
2f87703c
...
@@ -143,10 +143,12 @@
...
@@ -143,10 +143,12 @@
margin-top
:
0
;
margin-top
:
0
;
}
}
.project-repo-buttons
,
.group-buttons
{
.group-buttons
{
margin-top
:
15px
;
margin-top
:
15px
;
}
.project-repo-buttons
,
.group-buttons
{
.btn
{
.btn
{
@include
btn-gray
;
@include
btn-gray
;
padding
:
3px
10px
;
padding
:
3px
10px
;
...
@@ -175,12 +177,8 @@
...
@@ -175,12 +177,8 @@
}
}
}
}
.download-button
,
.project-action-button
{
.dropdown-toggle
,
margin
:
15px
5px
0
5px
;
.notification-dropdown
,
.project-dropdown
,
.access-button
{
margin-left
:
10px
;
vertical-align
:
top
;
vertical-align
:
top
;
}
}
...
@@ -197,10 +195,12 @@
...
@@ -197,10 +195,12 @@
.count-buttons
{
.count-buttons
{
display
:
inline-block
;
display
:
inline-block
;
vertical-align
:
top
;
vertical-align
:
top
;
margin-top
:
15px
;
}
}
.project-clone-holder
{
.project-clone-holder
{
display
:
inline-block
;
display
:
inline-block
;
margin
:
15px
5px
0
0
;
input
{
input
{
height
:
28px
;
height
:
28px
;
...
@@ -494,6 +494,7 @@ a.deploy-project-label {
...
@@ -494,6 +494,7 @@ a.deploy-project-label {
.project-stats
{
.project-stats
{
font-size
:
0
;
font-size
:
0
;
text-align
:
center
;
border-bottom
:
1px
solid
$border-color
;
border-bottom
:
1px
solid
$border-color
;
.nav
{
.nav
{
...
...
app/views/projects/_home_panel.html.haml
View file @
2f87703c
...
@@ -18,14 +18,20 @@
...
@@ -18,14 +18,20 @@
=
link_to
project_path
(
forked_from_project
)
do
=
link_to
project_path
(
forked_from_project
)
do
=
forked_from_project
.
namespace
.
try
(
:name
)
=
forked_from_project
.
namespace
.
try
(
:name
)
.project-repo-buttons
.project-action-buttons
.project-repo-buttons
.count-buttons
.count-buttons
=
render
'projects/buttons/star'
=
render
'projects/buttons/star'
=
render
'projects/buttons/fork'
=
render
'projects/buttons/fork'
%span
.hidden-xs
-
if
@project
.
feature_available?
(
:repository
,
current_user
)
-
if
@project
.
feature_available?
(
:repository
,
current_user
)
.project-clone-holder
.project-clone-holder
=
render
"shared/clone_panel"
=
render
"shared/clone_panel"
=
render
'projects/buttons/download'
,
project:
@project
,
ref:
@ref
=
render
'projects/buttons/dropdown'
=
render
'shared/notifications/button'
,
notification_setting:
@notification_setting
-
if
current_user
-
if
current_user
=
render
"projects/buttons/koding"
=
render
'shared/members/access_request_buttons'
,
source:
@project
=
render
'shared/members/access_request_buttons'
,
source:
@project
app/views/projects/buttons/_download.html.haml
View file @
2f87703c
-
if
!
project
.
empty_repo?
&&
can?
(
current_user
,
:download_code
,
project
)
-
if
!
project
.
empty_repo?
&&
can?
(
current_user
,
:download_code
,
project
)
.
dropdown.inline.download-button
.
project-action-button.dropdown.inline
%button
.btn
{
'data-toggle'
=>
'dropdown'
}
%button
.btn
{
'data-toggle'
=>
'dropdown'
}
=
icon
(
'download'
)
=
icon
(
'download'
)
=
icon
(
"caret-down"
)
=
icon
(
"caret-down"
)
...
...
app/views/projects/buttons/_dropdown.html.haml
View file @
2f87703c
-
if
current_user
-
if
current_user
.dropdown.inline
.
project-action-button.
dropdown.inline
%a
.btn.dropdown-toggle
{
href:
'#'
,
"data-toggle"
=>
"dropdown"
}
%a
.btn.dropdown-toggle
{
href:
'#'
,
"data-toggle"
=>
"dropdown"
}
=
icon
(
'plus'
)
=
icon
(
'plus'
)
=
icon
(
"caret-down"
)
=
icon
(
"caret-down"
)
...
...
app/views/projects/buttons/_koding.html.haml
View file @
2f87703c
-
if
koding_enabled?
&&
current_user
&&
can_push_branch?
(
@project
,
@project
.
default_branch
)
-
if
koding_enabled?
&&
current_user
&&
can_push_branch?
(
@project
,
@project
.
default_branch
)
-
if
@repository
.
koding_yml
-
if
@repository
.
koding_yml
=
link_to
koding_project_url
(
@project
),
class:
'btn'
,
target:
'_blank'
do
=
link_to
koding_project_url
(
@project
),
class:
'btn
project-action-button inline
'
,
target:
'_blank'
do
Run in IDE (Koding)
Run in IDE (Koding)
-
else
-
else
=
link_to
add_koding_stack_path
(
@project
),
class:
'btn'
do
=
link_to
add_koding_stack_path
(
@project
),
class:
'btn
project-action-button inline
'
do
Set
U
p Koding
Set
u
p Koding
app/views/projects/show.html.haml
View file @
2f87703c
...
@@ -64,19 +64,8 @@
...
@@ -64,19 +64,8 @@
-
unless
@repository
.
gitlab_ci_yml
-
unless
@repository
.
gitlab_ci_yml
%li
.missing
%li
.missing
=
link_to
add_special_file_path
(
@project
,
file_name:
'.gitlab-ci.yml'
)
do
=
link_to
add_special_file_path
(
@project
,
file_name:
'.gitlab-ci.yml'
)
do
Set
U
p CI
Set
u
p CI
%li
.project-repo-buttons.right
.project-right-buttons
-
if
current_user
=
render
"projects/buttons/koding"
.btn-group.project-repo-btn-group
=
render
'projects/buttons/download'
,
project:
@project
,
ref:
@ref
=
render
'projects/buttons/dropdown'
.pull-right
=
render
'shared/notifications/button'
,
notification_setting:
@notification_setting
-
if
@repository
.
commit
-
if
@repository
.
commit
.project-last-commit
{
class:
container_class
}
.project-last-commit
{
class:
container_class
}
=
render
'projects/last_commit'
,
commit:
@repository
.
commit
,
ref:
current_ref
,
project:
@project
=
render
'projects/last_commit'
,
commit:
@repository
.
commit
,
ref:
current_ref
,
project:
@project
...
...
app/views/shared/members/_access_request_buttons.html.haml
View file @
2f87703c
-
model_name
=
source
.
model_name
.
to_s
.
downcase
-
model_name
=
source
.
model_name
.
to_s
.
downcase
.
access-button.inline.hidden-sm.hidden-xs
.
project-action-button.inline
-
if
can?
(
current_user
,
:"destroy_
#{
model_name
}
_member"
,
source
.
members
.
find_by
(
user_id:
current_user
.
id
))
-
if
can?
(
current_user
,
:"destroy_
#{
model_name
}
_member"
,
source
.
members
.
find_by
(
user_id:
current_user
.
id
))
=
link_to
"Leave
#{
model_name
}
"
,
polymorphic_path
([
:leave
,
source
,
:members
]),
=
link_to
"Leave
#{
model_name
}
"
,
polymorphic_path
([
:leave
,
source
,
:members
]),
method: :delete
,
method: :delete
,
...
...
app/views/shared/notifications/_button.html.haml
View file @
2f87703c
-
if
notification_setting
-
if
notification_setting
.
dropdown.notification-dropdown
.
project-action-button.dropdown.notification-dropdown.inline
=
form_for
notification_setting
,
remote:
true
,
html:
{
class:
"inline notification-form"
}
do
|
f
|
=
form_for
notification_setting
,
remote:
true
,
html:
{
class:
"inline notification-form"
}
do
|
f
|
=
hidden_setting_source_input
(
notification_setting
)
=
hidden_setting_source_input
(
notification_setting
)
=
f
.
hidden_field
:level
,
class:
"notification_setting_level"
=
f
.
hidden_field
:level
,
class:
"notification_setting_level"
...
...
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