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
1ef8be76
Commit
1ef8be76
authored
Sep 07, 2016
by
Annabel Dunstone Gray
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Style grouped builds dropdown
parent
d392f147
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
99 additions
and
15 deletions
+99
-15
app/assets/stylesheets/pages/pipelines.scss
app/assets/stylesheets/pages/pipelines.scss
+75
-6
app/views/projects/ci/builds/_build_pipeline.html.haml
app/views/projects/ci/builds/_build_pipeline.html.haml
+2
-2
app/views/projects/commit/_pipeline_grouped_status.html.haml
app/views/projects/commit/_pipeline_grouped_status.html.haml
+22
-7
No files found.
app/assets/stylesheets/pages/pipelines.scss
View file @
1ef8be76
...
@@ -318,9 +318,17 @@
...
@@ -318,9 +318,17 @@
.build-content
{
.build-content
{
width
:
130px
;
width
:
130px
;
white-space
:
nowrap
;
overflow
:
hidden
;
.ci-status-text
{
text-overflow
:
ellipsis
;
width
:
110px
;
white-space
:
nowrap
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
vertical-align
:
middle
;
display
:
inline-block
;
position
:
relative
;
top
:
-1px
;
}
a
{
a
{
color
:
$layout-link-gray
;
color
:
$layout-link-gray
;
...
@@ -331,13 +339,74 @@
...
@@ -331,13 +339,74 @@
text-decoration
:
underline
;
text-decoration
:
underline
;
}
}
}
}
}
.dropdown-menu-toggle
{
border
:
none
;
width
:
auto
;
padding
:
0
;
color
:
$layout-link-gray
;
.ci-status-text
{
width
:
80px
;
}
}
.grouped-pipeline-dropdown
{
padding
:
8px
0
;
width
:
200px
;
left
:
auto
;
right
:
-214px
;
top
:
-9px
;
a
:hover
{
.ci-status-text
{
text-decoration
:
none
;
}
}
.ci-status-text
{
width
:
145px
;
}
.arrow
{
&
:before
,
&
:after
{
content
:
''
;
display
:
inline-block
;
position
:
absolute
;
width
:
0
;
height
:
0
;
border-color
:
transparent
;
border-style
:
solid
;
top
:
18px
;
}
&
:before
{
left
:
-5px
;
margin-top
:
-6px
;
border-width
:
7px
5px
7px
0
;
border-right-color
:
$border-color
;
}
&
:after
{
left
:
-4px
;
margin-top
:
-9px
;
border-width
:
10px
7px
10px
0
;
border-right-color
:
$white-light
;
}
}
}
.badge
{
background-color
:
$gray-dark
;
color
:
$layout-link-gray
;
font-weight
:
normal
;
}
}
}
}
svg
{
svg
{
position
:
relative
;
vertical-align
:
middle
;
top
:
2px
;
margin-right
:
5px
;
margin-right
:
5px
;
}
}
...
@@ -442,7 +511,7 @@
...
@@ -442,7 +511,7 @@
width
:
21px
;
width
:
21px
;
height
:
25px
;
height
:
25px
;
position
:
absolute
;
position
:
absolute
;
top
:
-2
8
.5
px
;
top
:
-2
9
px
;
border-top
:
2px
solid
$border-color
;
border-top
:
2px
solid
$border-color
;
}
}
...
...
app/views/projects/ci/builds/_build_pipeline.html.haml
View file @
1ef8be76
...
@@ -5,11 +5,11 @@
...
@@ -5,11 +5,11 @@
-
if
is_playable
-
if
is_playable
=
link_to
play_namespace_project_build_path
(
subject
.
project
.
namespace
,
subject
.
project
,
subject
,
return_to:
request
.
original_url
),
method: :post
,
title:
'Play'
do
=
link_to
play_namespace_project_build_path
(
subject
.
project
.
namespace
,
subject
.
project
,
subject
,
return_to:
request
.
original_url
),
method: :post
,
title:
'Play'
do
=
render_status_with_link
(
'build'
,
'play'
)
=
render_status_with_link
(
'build'
,
'play'
)
%span
.ci-status-text
=
subject
.
name
.ci-status-text
=
subject
.
name
-
elsif
can?
(
current_user
,
:read_build
,
@project
)
-
elsif
can?
(
current_user
,
:read_build
,
@project
)
=
link_to
namespace_project_build_path
(
subject
.
project
.
namespace
,
subject
.
project
,
subject
)
do
=
link_to
namespace_project_build_path
(
subject
.
project
.
namespace
,
subject
.
project
,
subject
)
do
=
render_status_with_link
(
'build'
,
subject
.
status
)
=
render_status_with_link
(
'build'
,
subject
.
status
)
%span
.ci-status-text
=
subject
.
name
.ci-status-text
=
subject
.
name
-
else
-
else
=
render_status_with_link
(
'build'
,
subject
.
status
)
=
render_status_with_link
(
'build'
,
subject
.
status
)
=
ci_icon_for_status
(
subject
.
status
)
=
ci_icon_for_status
(
subject
.
status
)
app/views/projects/commit/_pipeline_grouped_status.html.haml
View file @
1ef8be76
...
@@ -3,10 +3,25 @@
...
@@ -3,10 +3,25 @@
.build-content
.build-content
-
group_status
=
CommitStatus
.
where
(
id:
subject
).
status
-
group_status
=
CommitStatus
.
where
(
id:
subject
).
status
=
render_status_with_link
(
'build'
,
group_status
)
=
render_status_with_link
(
'build'
,
group_status
)
%span
.ci-status-text
.dropdown.inline
=
name
%button
.dropdown-menu-toggle
{
type:
'button'
,
data:
{
toggle:
'dropdown'
}}
=
subject
.
length
%span
.ci-status-text
=
name
// Access all other grouped statuses
%span
.badge
=
subject
.
length
//- subject.each do |status|
%ul
.dropdown-menu.grouped-pipeline-dropdown
// = render "projects/#{status.to_partial_path}_pipeline", subject: status
.arrow
-
subject
.
each
do
|
status
|
-# = render "projects/#{status.to_partial_path}_pipeline", subject: status
-
is_playable
=
status
.
playable?
&&
can?
(
current_user
,
:update_build
,
@project
)
%li
-
if
is_playable
=
link_to
play_namespace_project_build_path
(
status
.
project
.
namespace
,
status
.
project
,
status
,
return_to:
request
.
original_url
),
method: :post
,
title:
'Play'
do
=
render_status_with_link
(
'build'
,
'play'
)
.ci-status-text
=
status
.
name
-
elsif
can?
(
current_user
,
:read_build
,
@project
)
=
link_to
namespace_project_build_path
(
status
.
project
.
namespace
,
status
.
project
,
status
)
do
=
render_status_with_link
(
'build'
,
status
.
status
)
.ci-status-text
=
status
.
name
-
else
=
render_status_with_link
(
'build'
,
status
.
status
)
=
ci_icon_for_status
(
status
.
status
)
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