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
14400224
Commit
14400224
authored
Nov 14, 2016
by
Annabel Dunstone Gray
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make pipeline page header responsive; add build counter; add short sha
parent
775c5aab
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
146 additions
and
164 deletions
+146
-164
app/assets/stylesheets/framework.scss
app/assets/stylesheets/framework.scss
+1
-0
app/assets/stylesheets/framework/page-header.scss
app/assets/stylesheets/framework/page-header.scss
+67
-0
app/assets/stylesheets/pages/commit.scss
app/assets/stylesheets/pages/commit.scss
+11
-85
app/views/projects/commit/_commit_box.html.haml
app/views/projects/commit/_commit_box.html.haml
+4
-3
app/views/projects/commit/_pipeline.html.haml
app/views/projects/commit/_pipeline.html.haml
+47
-64
app/views/projects/commits/_commit.html.haml
app/views/projects/commits/_commit.html.haml
+3
-4
app/views/projects/pipelines/_info.html.haml
app/views/projects/pipelines/_info.html.haml
+13
-8
No files found.
app/assets/stylesheets/framework.scss
View file @
14400224
...
@@ -40,3 +40,4 @@
...
@@ -40,3 +40,4 @@
@import
"framework/zen.scss"
;
@import
"framework/zen.scss"
;
@import
"framework/blank"
;
@import
"framework/blank"
;
@import
"framework/wells.scss"
;
@import
"framework/wells.scss"
;
@import
"framework/page-header.scss"
;
app/assets/stylesheets/framework/page-header.scss
0 → 100644
View file @
14400224
.page-content-header
{
line-height
:
34px
;
padding
:
10px
0
;
margin-bottom
:
0
;
@media
(
min-width
:
$screen-sm-min
)
{
display
:
flex
;
align-items
:
center
;
.header-main-content
{
flex
:
1
;
}
}
.header-action-buttons
{
i
{
color
:
$gl-icon-color
;
font-size
:
13px
;
margin-right
:
3px
;
}
@media
(
max-width
:
$screen-xs-max
)
{
.btn
{
width
:
100%
;
margin-top
:
10px
;
}
.dropdown
{
width
:
100%
;
}
}
}
.avatar
{
@extend
.avatar-inline
;
margin-left
:
0
;
@media
(
min-width
:
$screen-sm-min
)
{
margin-left
:
4px
;
}
}
.commit-committer-link
,
.commit-author-link
{
color
:
$gl-gray
;
font-weight
:
bold
;
}
.fa-clipboard
{
color
:
$dropdown-title-btn-color
;
}
.commit-info
{
&
.branches
{
margin-left
:
8px
;
}
}
.ci-status-link
{
svg
{
position
:
relative
;
top
:
2px
;
margin
:
0
2px
0
3px
;
}
}
}
app/assets/stylesheets/pages/commit.scss
View file @
14400224
...
@@ -26,91 +26,6 @@
...
@@ -26,91 +26,6 @@
white-space
:
pre-wrap
;
white-space
:
pre-wrap
;
}
}
.commit-info-row
{
margin-bottom
:
10px
;
line-height
:
24px
;
padding-top
:
6px
;
&
.commit-info-row-header
{
line-height
:
34px
;
padding
:
10px
0
;
margin-bottom
:
0
;
@media
(
min-width
:
$screen-sm-min
)
{
display
:
flex
;
align-items
:
center
;
.commit-meta
{
flex
:
1
;
}
}
.commit-hash-full
{
@media
(
max-width
:
$screen-sm-max
)
{
width
:
80px
;
white-space
:
nowrap
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
display
:
inline-block
;
vertical-align
:
bottom
;
}
}
.commit-action-buttons
{
i
{
color
:
$gl-icon-color
;
font-size
:
13px
;
margin-right
:
3px
;
}
@media
(
max-width
:
$screen-xs-max
)
{
.dropdown
{
width
:
100%
;
margin-top
:
10px
;
}
.dropdown-toggle
{
width
:
100%
;
}
}
}
}
.avatar
{
@extend
.avatar-inline
;
margin-left
:
0
;
@media
(
min-width
:
$screen-sm-min
)
{
margin-left
:
4px
;
}
}
.commit-committer-link
,
.commit-author-link
{
color
:
$gl-gray
;
font-weight
:
bold
;
}
.fa-clipboard
{
color
:
$dropdown-title-btn-color
;
}
.commit-info
{
&
.branches
{
margin-left
:
8px
;
}
}
.ci-status-link
{
svg
{
position
:
relative
;
top
:
2px
;
margin
:
0
2px
0
3px
;
}
}
}
.js-details-expand
{
.js-details-expand
{
&
:hover
{
&
:hover
{
text-decoration
:
none
;
text-decoration
:
none
;
...
@@ -138,6 +53,17 @@
...
@@ -138,6 +53,17 @@
}
}
}
}
.commit-hash-full
{
@media
(
max-width
:
$screen-sm-max
)
{
width
:
80px
;
white-space
:
nowrap
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
display
:
inline-block
;
vertical-align
:
bottom
;
}
}
.file-stats
{
.file-stats
{
ul
{
ul
{
list-style
:
none
;
list-style
:
none
;
...
...
app/views/projects/commit/_commit_box.html.haml
View file @
14400224
.
commit-info-row.commit-info-row
-header
.
page-content
-header
.
commit-meta
.
header-main-content
%strong
Commit
%strong
Commit
%strong
.monospace.js-details-short
=
@commit
.
short_id
%strong
.monospace.js-details-short
=
@commit
.
short_id
=
link_to
(
"#"
,
class:
"js-details-expand hidden-xs hidden-sm"
)
do
=
link_to
(
"#"
,
class:
"js-details-expand hidden-xs hidden-sm"
)
do
...
@@ -19,7 +19,8 @@
...
@@ -19,7 +19,8 @@
%strong
%strong
=
commit_committer_link
(
@commit
,
avatar:
true
,
size:
24
)
=
commit_committer_link
(
@commit
,
avatar:
true
,
size:
24
)
#{
time_ago_with_tooltip
(
@commit
.
committed_date
)
}
#{
time_ago_with_tooltip
(
@commit
.
committed_date
)
}
.commit-action-buttons
.header-action-buttons
-
if
defined?
(
@notes_count
)
&&
@notes_count
>
0
-
if
defined?
(
@notes_count
)
&&
@notes_count
>
0
%span
.btn.disabled.btn-grouped.hidden-xs.append-right-10
%span
.btn.disabled.btn-grouped.hidden-xs.append-right-10
=
icon
(
'comment'
)
=
icon
(
'comment'
)
...
...
app/views/projects/commit/_pipeline.html.haml
View file @
14400224
.pipeline-graph-container
.tabs-holder
.oneline.clearfix
-
if
defined?
(
pipeline_details
)
&&
pipeline_details
Pipeline
=
link_to
"#
#{
pipeline
.
id
}
"
,
namespace_project_pipeline_path
(
pipeline
.
project
.
namespace
,
pipeline
.
project
,
pipeline
.
id
),
class:
"monospace"
with
=
pluralize
pipeline
.
statuses
.
count
(
:id
),
"build"
-
if
pipeline
.
ref
for
=
link_to
pipeline
.
ref
,
namespace_project_commits_path
(
pipeline
.
project
.
namespace
,
pipeline
.
project
,
pipeline
.
ref
),
class:
"monospace"
-
if
defined?
(
link_to_commit
)
&&
link_to_commit
for commit
=
link_to
pipeline
.
short_sha
,
namespace_project_commit_path
(
pipeline
.
project
.
namespace
,
pipeline
.
project
,
pipeline
.
sha
),
class:
"monospace"
-
if
pipeline
.
duration
in
=
time_interval_in_words
pipeline
.
duration
.tabs-holder
%ul
.nav-links.no-top.no-bottom
%ul
.nav-links.no-top.no-bottom
%li
.active
%li
.active
=
link_to
"Pipeline"
,
"#js-tab-pipeline"
,
data:
{
target:
'#js-tab-pipeline'
,
action:
'pipeline'
,
toggle:
'tab'
}
=
link_to
"Pipeline"
,
"#js-tab-pipeline"
,
data:
{
target:
'#js-tab-pipeline'
,
action:
'pipeline'
,
toggle:
'tab'
}
%span
.badge
%li
%li
=
link_to
"Builds"
,
"#js-tab-builds"
,
data:
{
target:
'#js-tab-builds'
,
action:
'build'
,
toggle:
'tab'
}
=
link_to
"#js-tab-builds"
,
data:
{
target:
'#js-tab-builds'
,
action:
'build'
,
toggle:
'tab'
}
do
%span
.badge
Builds
%span
.badge
=
pipeline
.
statuses
.
count
.tab-content
.tab-content
#js-tab-pipeline
.tab-pane.active
#js-tab-pipeline
.tab-pane.active
.build-content.middle-block.pipeline-graph
.build-content.middle-block.pipeline-graph
.pipeline-visualization
.pipeline-visualization
...
...
app/views/projects/commits/_commit.html.haml
View file @
14400224
...
@@ -36,7 +36,6 @@
...
@@ -36,7 +36,6 @@
%pre
.commit-row-description.js-toggle-content
%pre
.commit-row-description.js-toggle-content
=
preserve
(
markdown
(
commit
.
description
,
pipeline: :single_line
,
author:
commit
.
author
))
=
preserve
(
markdown
(
commit
.
description
,
pipeline: :single_line
,
author:
commit
.
author
))
.commit-row-info
=
commit_author_link
(
commit
,
avatar:
false
,
size:
24
)
=
commit_author_link
(
commit
,
avatar:
false
,
size:
24
)
authored
authored
#{
time_ago_with_tooltip
(
commit
.
committed_date
)
}
#{
time_ago_with_tooltip
(
commit
.
committed_date
)
}
app/views/projects/pipelines/_info.html.haml
View file @
14400224
.
commit-info-row.commit-info-row
-header
.
page-content
-header
.
commit-meta
.
header-main-content
=
link_to
namespace_project_pipeline_path
(
@project
.
namespace
,
@project
,
@pipeline
),
class:
"ci-status ci-
#{
@pipeline
.
status
}
"
do
=
link_to
namespace_project_pipeline_path
(
@project
.
namespace
,
@project
,
@pipeline
),
class:
"ci-status ci-
#{
@pipeline
.
status
}
"
do
=
ci_icon_for_status
(
@pipeline
.
status
)
=
ci_icon_for_status
(
@pipeline
.
status
)
=
ci_label_for_status
(
@pipeline
.
status
)
=
ci_label_for_status
(
@pipeline
.
status
)
...
@@ -7,12 +7,12 @@
...
@@ -7,12 +7,12 @@
triggered
#{
time_ago_with_tooltip
(
@commit
.
authored_date
)
}
by
triggered
#{
time_ago_with_tooltip
(
@commit
.
authored_date
)
}
by
=
author_avatar
(
@commit
,
size:
24
)
=
author_avatar
(
@commit
,
size:
24
)
=
commit_author_link
(
@commit
)
=
commit_author_link
(
@commit
)
.
commit
-action-buttons
.
header
-action-buttons
-
if
can?
(
current_user
,
:update_pipeline
,
@pipeline
.
project
)
-
if
can?
(
current_user
,
:update_pipeline
,
@pipeline
.
project
)
-
if
@pipeline
.
builds
.
latest
.
failed
.
any?
(
&
:retryable?
)
-
if
@pipeline
.
builds
.
latest
.
failed
.
any?
(
&
:retryable?
)
=
link_to
"Retry failed"
,
retry_namespace_project_pipeline_path
(
@pipeline
.
project
.
namespace
,
@pipeline
.
project
,
@pipeline
.
id
),
class:
'btn
btn-grouped
retry-build-btn'
,
method: :post
=
link_to
"Retry failed"
,
retry_namespace_project_pipeline_path
(
@pipeline
.
project
.
namespace
,
@pipeline
.
project
,
@pipeline
.
id
),
class:
'btn retry-build-btn'
,
method: :post
-
if
@pipeline
.
builds
.
running_or_pending
.
any?
-
if
@pipeline
.
builds
.
running_or_pending
.
any?
=
link_to
"Cancel running"
,
cancel_namespace_project_pipeline_path
(
@pipeline
.
project
.
namespace
,
@pipeline
.
project
,
@pipeline
.
id
),
data:
{
confirm:
'Are you sure?'
},
class:
'btn btn-
grouped btn-
danger'
,
method: :post
=
link_to
"Cancel running"
,
cancel_namespace_project_pipeline_path
(
@pipeline
.
project
.
namespace
,
@pipeline
.
project
,
@pipeline
.
id
),
data:
{
confirm:
'Are you sure?'
},
class:
'btn btn-danger'
,
method: :post
-
if
@commit
-
if
@commit
.commit-box
.commit-box
...
@@ -29,7 +29,7 @@
...
@@ -29,7 +29,7 @@
=
ci_icon_for_status
(
@commit
.
status
)
=
ci_icon_for_status
(
@commit
.
status
)
=
pluralize
@pipeline
.
statuses
.
count
(
:id
),
"build"
=
pluralize
@pipeline
.
statuses
.
count
(
:id
),
"build"
-
if
@pipeline
.
ref
-
if
@pipeline
.
ref
f
or
f
rom
=
link_to
@pipeline
.
ref
,
namespace_project_commits_path
(
@project
.
namespace
,
@project
,
@pipeline
.
ref
),
class:
"monospace"
=
link_to
@pipeline
.
ref
,
namespace_project_commits_path
(
@project
.
namespace
,
@project
,
@pipeline
.
ref
),
class:
"monospace"
-
if
@pipeline
.
duration
-
if
@pipeline
.
duration
in
in
...
@@ -40,5 +40,10 @@
...
@@ -40,5 +40,10 @@
.well-segment.branch-info
.well-segment.branch-info
.icon-container.commit-icon
.icon-container.commit-icon
=
custom_icon
(
"icon_commit"
)
=
custom_icon
(
"icon_commit"
)
=
link_to
@pipeline
.
sha
,
namespace_project_commit_path
(
@project
.
namespace
,
@project
,
@pipeline
.
sha
),
class:
"monospace"
=
link_to
@commit
.
short_id
,
namespace_project_commit_path
(
@project
.
namespace
,
@project
,
@pipeline
.
sha
),
class:
"monospace js-details-short"
=
clipboard_button
(
clipboard_text:
@pipeline
.
sha
)
=
link_to
(
"#"
,
class:
"js-details-expand hidden-xs hidden-sm"
)
do
%span
.text-expander
\...
%span
.js-details-content.hide
=
link_to
@pipeline
.
sha
,
namespace_project_commit_path
(
@project
.
namespace
,
@project
,
@pipeline
.
sha
),
class:
"monospace commit-hash-full"
=
clipboard_button
(
clipboard_text:
@pipeline
.
sha
,
title:
"Copy commit SHA to clipboard"
)
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