Commit 72cc43df authored by Fatih Acet's avatar Fatih Acet

Merge branch '19751-branch-tag-icons' into 'master'

Resolve "Add icons for branch and tag in pipeline list"

## What does this MR do?
Adds branch or tag icon on pipeline ref

## What are the relevant issue numbers?
Closes #19751    
Part of #18920 

## Screenshots (if relevant)
![Screen_Shot_2016-07-13_at_1.42.54_PM](/uploads/d90706a76cf87a6cc8c25dca9a71affa/Screen_Shot_2016-07-13_at_1.42.54_PM.png)

With icons closer to tag/branch name/sha:   
![Screen_Shot_2016-07-15_at_11.23.48_AM](/uploads/411338f811bafbd314dbab5553fa46d4/Screen_Shot_2016-07-15_at_11.23.48_AM.png)

See merge request !5239
parents 1e81ab7c add3767d
.pipelines { .pipelines {
.stage { .stage {
max-width: 80px; max-width: 90px;
width: 80px; width: 90px;
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
white-space: nowrap; white-space: nowrap;
...@@ -30,13 +30,17 @@ ...@@ -30,13 +30,17 @@
} }
.table.builds { .table.builds {
min-width: 1100px; min-width: 1200px;
tr { tr {
th { th {
padding: 16px; padding: 16px 8px;
border: none; border: none;
} }
td {
padding: 10px 8px;
}
} }
tbody { tbody {
...@@ -53,9 +57,8 @@ ...@@ -53,9 +57,8 @@
.branch-commit { .branch-commit {
.branch-name { .branch-name {
margin-left: 8px;
font-weight: bold; font-weight: bold;
max-width: 180px; max-width: 150px;
overflow: hidden; overflow: hidden;
display: inline-block; display: inline-block;
white-space: nowrap; white-space: nowrap;
...@@ -64,10 +67,15 @@ ...@@ -64,10 +67,15 @@
} }
svg { svg {
margin: 0 6px;
height: 14px; height: 14px;
width: auto; width: auto;
vertical-align: middle; vertical-align: middle;
fill: $table-text-gray;
}
.fa {
font-size: 12px;
color: $table-text-gray;
} }
.commit-id { .commit-id {
...@@ -100,6 +108,22 @@ ...@@ -100,6 +108,22 @@
} }
} }
.icon-container {
display: inline-block;
text-align: right;
width: 20px;
.fa {
position: relative;
right: 3px;
}
svg {
position: relative;
right: 1px;
}
}
.duration, .duration,
.finished-at { .finished-at {
color: $table-text-gray; color: $table-text-gray;
...@@ -107,21 +131,19 @@ ...@@ -107,21 +131,19 @@
.fa { .fa {
font-size: 12px; font-size: 12px;
margin-right: 4px;
} }
svg { svg {
height: 12px; width: 12px;
width: auto; height: auto;
vertical-align: middle; vertical-align: middle;
} margin-right: 4px;
.fa,
svg {
margin-right: 5px;
} }
} }
.pipeline-actions { .pipeline-actions {
min-width: 140px;
.btn { .btn {
margin: 0; margin: 0;
......
...@@ -10,12 +10,13 @@ ...@@ -10,12 +10,13 @@
= link_to namespace_project_pipeline_path(@project.namespace, @project, pipeline.id) do = link_to namespace_project_pipeline_path(@project.namespace, @project, pipeline.id) do
%span ##{pipeline.id} %span ##{pipeline.id}
- if pipeline.ref - if pipeline.ref
.icon-container
= pipeline.tag? ? icon('tag') : icon('code-fork')
= link_to pipeline.ref, namespace_project_commits_path(@project.namespace, @project, pipeline.ref), class: "monospace branch-name" = link_to pipeline.ref, namespace_project_commits_path(@project.namespace, @project, pipeline.ref), class: "monospace branch-name"
.icon-container
= custom_icon("icon_commit") = custom_icon("icon_commit")
= link_to pipeline.short_sha, namespace_project_commit_path(@project.namespace, @project, pipeline.sha), class: "commit-id monospace" = link_to pipeline.short_sha, namespace_project_commit_path(@project.namespace, @project, pipeline.sha), class: "commit-id monospace"
- if pipeline.tag? - if pipeline.latest?
%span.label.label-primary tag
- elsif pipeline.latest?
%span.label.label-success.has-tooltip{ title: 'Latest build for this branch' } latest %span.label.label-success.has-tooltip{ title: 'Latest build for this branch' } latest
- if pipeline.triggered? - if pipeline.triggered?
%span.label.label-primary triggered %span.label.label-primary triggered
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment