Commit 32ecb02784a25feb2f264f47b883de3a0cb5f8fd
1 parent
f92b1f3d
Exists in
spb-stable
and in
3 other branches
Refactor scss
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Showing
36 changed files
with
175 additions
and
195 deletions
Show diff stats
app/assets/stylesheets/application.scss
| @@ -37,6 +37,7 @@ | @@ -37,6 +37,7 @@ | ||
| 37 | @import "generic/issue_box.scss"; | 37 | @import "generic/issue_box.scss"; |
| 38 | @import "generic/files.scss"; | 38 | @import "generic/files.scss"; |
| 39 | @import "generic/lists.scss"; | 39 | @import "generic/lists.scss"; |
| 40 | +@import "generic/flash.scss"; | ||
| 40 | @import "generic/forms.scss"; | 41 | @import "generic/forms.scss"; |
| 41 | @import "generic/selects.scss"; | 42 | @import "generic/selects.scss"; |
| 42 | @import "generic/highlight.scss"; | 43 | @import "generic/highlight.scss"; |
app/assets/stylesheets/generic/blocks.scss
| @@ -2,3 +2,18 @@ | @@ -2,3 +2,18 @@ | ||
| 2 | background: #f9f9f9; | 2 | background: #f9f9f9; |
| 3 | padding: 15px; | 3 | padding: 15px; |
| 4 | } | 4 | } |
| 5 | + | ||
| 6 | +.centered-light-block { | ||
| 7 | + text-align: center; | ||
| 8 | + color: #888; | ||
| 9 | + margin: 20px; | ||
| 10 | +} | ||
| 11 | + | ||
| 12 | +.nothing-here-block { | ||
| 13 | + text-align: center; | ||
| 14 | + padding: 20px; | ||
| 15 | + color: #666; | ||
| 16 | + font-weight: normal; | ||
| 17 | + font-size: 16px; | ||
| 18 | + line-height: 36px; | ||
| 19 | +} |
app/assets/stylesheets/generic/common.scss
| @@ -11,8 +11,6 @@ | @@ -11,8 +11,6 @@ | ||
| 11 | .bgred { background: #F2DEDE!important } | 11 | .bgred { background: #F2DEDE!important } |
| 12 | 12 | ||
| 13 | /** COMMON CLASSES **/ | 13 | /** COMMON CLASSES **/ |
| 14 | -.left { float:left } | ||
| 15 | - | ||
| 16 | .prepend-top-10 { margin-top:10px } | 14 | .prepend-top-10 { margin-top:10px } |
| 17 | .prepend-top-20 { margin-top:20px } | 15 | .prepend-top-20 { margin-top:20px } |
| 18 | .prepend-left-10 { margin-left:10px } | 16 | .prepend-left-10 { margin-left:10px } |
| @@ -24,32 +22,9 @@ | @@ -24,32 +22,9 @@ | ||
| 24 | .append-bottom-20 { margin-bottom:20px } | 22 | .append-bottom-20 { margin-bottom:20px } |
| 25 | .inline { display: inline-block } | 23 | .inline { display: inline-block } |
| 26 | 24 | ||
| 27 | -.padded { padding:20px } | ||
| 28 | -.ipadded { padding:20px!important } | ||
| 29 | -.lborder { border-left:1px solid #eee } | ||
| 30 | -.underlined_link { text-decoration: underline; } | 25 | +.underlined-link { text-decoration: underline; } |
| 31 | .hint { font-style: italic; color: #999; } | 26 | .hint { font-style: italic; color: #999; } |
| 32 | .light { color: #888 } | 27 | .light { color: #888 } |
| 33 | -.tiny { font-weight: normal } | ||
| 34 | -.vtop { vertical-align: top !important; } | ||
| 35 | - | ||
| 36 | - | ||
| 37 | -/** ALERT MESSAGES **/ | ||
| 38 | -.alert.alert-disabled { | ||
| 39 | - background: #EEE; | ||
| 40 | - color: #777; | ||
| 41 | - border-color: #DDD; | ||
| 42 | -} | ||
| 43 | - | ||
| 44 | -/** HELPERS **/ | ||
| 45 | -.nothing_here_message { | ||
| 46 | - text-align: center; | ||
| 47 | - padding: 20px; | ||
| 48 | - color: #666; | ||
| 49 | - font-weight: normal; | ||
| 50 | - font-size: 16px; | ||
| 51 | - line-height: 36px; | ||
| 52 | -} | ||
| 53 | 28 | ||
| 54 | .slead { | 29 | .slead { |
| 55 | color: #666; | 30 | color: #666; |
| @@ -59,53 +34,23 @@ | @@ -59,53 +34,23 @@ | ||
| 59 | line-height: 24px; | 34 | line-height: 24px; |
| 60 | } | 35 | } |
| 61 | 36 | ||
| 62 | - | ||
| 63 | .tab-content { | 37 | .tab-content { |
| 64 | overflow: visible; | 38 | overflow: visible; |
| 65 | } | 39 | } |
| 66 | 40 | ||
| 67 | -@media (max-width: 1200px) { | ||
| 68 | - .only-wide { | ||
| 69 | - display: none; | ||
| 70 | - } | ||
| 71 | -} | ||
| 72 | - | ||
| 73 | -pre.well-pre { | ||
| 74 | - border: 1px solid #EEE; | ||
| 75 | - background: #f9f9f9; | ||
| 76 | - border-radius: 0; | ||
| 77 | - color: #555; | ||
| 78 | -} | ||
| 79 | - | ||
| 80 | -.input-append .btn.active, .input-prepend .btn.active { | ||
| 81 | - background: #CCC; | ||
| 82 | - border-color: #BBB; | ||
| 83 | - text-shadow: 0 1px 1px #fff; | ||
| 84 | - font-weight: bold; | ||
| 85 | - @include box-shadow(inset 0 2px 4px rgba(0,0,0,.15)); | ||
| 86 | -} | ||
| 87 | - | ||
| 88 | -/** Big Labels **/ | ||
| 89 | -.state-label { | ||
| 90 | - font-size: 14px; | ||
| 91 | - padding: 9px 25px; | ||
| 92 | - text-align: center; | ||
| 93 | - text-shadow: none; | ||
| 94 | - margin-right: 20px; | ||
| 95 | - | ||
| 96 | - &.state-label-blue { | ||
| 97 | - background: #31708f; | ||
| 98 | - color: #FFF; | ||
| 99 | - } | ||
| 100 | - | ||
| 101 | - &.state-label-green { | ||
| 102 | - background: #4A4; | ||
| 103 | - color: #FFF; | 41 | +pre { |
| 42 | + &.clean { | ||
| 43 | + background: none; | ||
| 44 | + border: none; | ||
| 45 | + margin: 0; | ||
| 46 | + padding: 0; | ||
| 104 | } | 47 | } |
| 105 | 48 | ||
| 106 | - &.state-label-red { | ||
| 107 | - background: #DA4E49; | ||
| 108 | - color: #FFF; | 49 | + &.well-pre { |
| 50 | + border: 1px solid #EEE; | ||
| 51 | + background: #f9f9f9; | ||
| 52 | + border-radius: 0; | ||
| 53 | + color: #555; | ||
| 109 | } | 54 | } |
| 110 | } | 55 | } |
| 111 | 56 | ||
| @@ -135,31 +80,6 @@ pre.well-pre { | @@ -135,31 +80,6 @@ pre.well-pre { | ||
| 135 | } | 80 | } |
| 136 | 81 | ||
| 137 | /** FLASH message **/ | 82 | /** FLASH message **/ |
| 138 | -.flash-container { | ||
| 139 | - display: none; | ||
| 140 | - cursor: pointer; | ||
| 141 | - margin: 0; | ||
| 142 | - text-align: center; | ||
| 143 | - color: #fff; | ||
| 144 | - font-size: 14px; | ||
| 145 | - position: fixed; | ||
| 146 | - bottom: 0; | ||
| 147 | - width: 100%; | ||
| 148 | - opacity: 0.8; | ||
| 149 | - z-index: 100; | ||
| 150 | - | ||
| 151 | - .flash-notice { | ||
| 152 | - background: #49C; | ||
| 153 | - padding: 10px; | ||
| 154 | - text-shadow: 0 1px 1px #178; | ||
| 155 | - } | ||
| 156 | - | ||
| 157 | - .flash-alert { | ||
| 158 | - background: #C67; | ||
| 159 | - text-shadow: 0 1px 1px #945; | ||
| 160 | - padding: 10px; | ||
| 161 | - } | ||
| 162 | -} | ||
| 163 | .author_link { | 83 | .author_link { |
| 164 | color: $link_color; | 84 | color: $link_color; |
| 165 | } | 85 | } |
| @@ -279,22 +199,6 @@ li.note { | @@ -279,22 +199,6 @@ li.note { | ||
| 279 | cursor: pointer; | 199 | cursor: pointer; |
| 280 | } | 200 | } |
| 281 | 201 | ||
| 282 | -.merge-request, | ||
| 283 | -.issue { | ||
| 284 | - &.today{ | ||
| 285 | - background: #EFE; | ||
| 286 | - border-color: #CEC; | ||
| 287 | - } | ||
| 288 | - &.closed { | ||
| 289 | - background: #F5f5f5; | ||
| 290 | - border-color: #E5E5E5; | ||
| 291 | - } | ||
| 292 | - &.merged { | ||
| 293 | - background: #F5f5f5; | ||
| 294 | - border-color: #E5E5E5; | ||
| 295 | - } | ||
| 296 | -} | ||
| 297 | - | ||
| 298 | .git_error_tips { | 202 | .git_error_tips { |
| 299 | @extend .col-md-6; | 203 | @extend .col-md-6; |
| 300 | text-align: left; | 204 | text-align: left; |
| @@ -358,15 +262,6 @@ li.note { | @@ -358,15 +262,6 @@ li.note { | ||
| 358 | } | 262 | } |
| 359 | } | 263 | } |
| 360 | 264 | ||
| 361 | -pre { | ||
| 362 | - &.clean { | ||
| 363 | - background: none; | ||
| 364 | - border: none; | ||
| 365 | - margin: 0; | ||
| 366 | - padding: 0; | ||
| 367 | - } | ||
| 368 | -} | ||
| 369 | - | ||
| 370 | .milestone { | 265 | .milestone { |
| 371 | &.milestone-closed { | 266 | &.milestone-closed { |
| 372 | background: #eee; | 267 | background: #eee; |
| @@ -450,40 +345,6 @@ table { | @@ -450,40 +345,6 @@ table { | ||
| 450 | margin-bottom: 20px; | 345 | margin-bottom: 20px; |
| 451 | } | 346 | } |
| 452 | 347 | ||
| 453 | -.ajax-users-select { | ||
| 454 | - width: 400px; | ||
| 455 | - | ||
| 456 | - &.input-large { | ||
| 457 | - width: 210px; | ||
| 458 | - } | ||
| 459 | - | ||
| 460 | - &.input-clamp { | ||
| 461 | - max-width: 100%; | ||
| 462 | - } | ||
| 463 | -} | ||
| 464 | - | ||
| 465 | -.user-result { | ||
| 466 | - .user-image { | ||
| 467 | - float: left; | ||
| 468 | - } | ||
| 469 | - .user-name { | ||
| 470 | - } | ||
| 471 | - .user-username { | ||
| 472 | - color: #999; | ||
| 473 | - } | ||
| 474 | -} | ||
| 475 | - | ||
| 476 | -.namespace-result { | ||
| 477 | - .namespace-kind { | ||
| 478 | - color: #AAA; | ||
| 479 | - font-weight: normal; | ||
| 480 | - } | ||
| 481 | - .namespace-path { | ||
| 482 | - margin-left: 10px; | ||
| 483 | - font-weight: bolder; | ||
| 484 | - } | ||
| 485 | -} | ||
| 486 | - | ||
| 487 | .btn-sign-in { | 348 | .btn-sign-in { |
| 488 | margin-top: 7px; | 349 | margin-top: 7px; |
| 489 | text-shadow: none; | 350 | text-shadow: none; |
| @@ -0,0 +1,25 @@ | @@ -0,0 +1,25 @@ | ||
| 1 | +.flash-container { | ||
| 2 | + display: none; | ||
| 3 | + cursor: pointer; | ||
| 4 | + margin: 0; | ||
| 5 | + text-align: center; | ||
| 6 | + color: #fff; | ||
| 7 | + font-size: 14px; | ||
| 8 | + position: fixed; | ||
| 9 | + bottom: 0; | ||
| 10 | + width: 100%; | ||
| 11 | + opacity: 0.8; | ||
| 12 | + z-index: 100; | ||
| 13 | + | ||
| 14 | + .flash-notice { | ||
| 15 | + background: #49C; | ||
| 16 | + padding: 10px; | ||
| 17 | + text-shadow: 0 1px 1px #178; | ||
| 18 | + } | ||
| 19 | + | ||
| 20 | + .flash-alert { | ||
| 21 | + background: #C67; | ||
| 22 | + text-shadow: 0 1px 1px #945; | ||
| 23 | + padding: 10px; | ||
| 24 | + } | ||
| 25 | +} |
app/assets/stylesheets/generic/issue_box.scss
| @@ -48,4 +48,27 @@ | @@ -48,4 +48,27 @@ | ||
| 48 | margin: 0; | 48 | margin: 0; |
| 49 | } | 49 | } |
| 50 | } | 50 | } |
| 51 | + | ||
| 52 | + .state-label { | ||
| 53 | + font-size: 14px; | ||
| 54 | + padding: 9px 25px; | ||
| 55 | + text-align: center; | ||
| 56 | + text-shadow: none; | ||
| 57 | + margin-right: 20px; | ||
| 58 | + | ||
| 59 | + &.state-label-blue { | ||
| 60 | + background: #31708f; | ||
| 61 | + color: #FFF; | ||
| 62 | + } | ||
| 63 | + | ||
| 64 | + &.state-label-green { | ||
| 65 | + background: #4A4; | ||
| 66 | + color: #FFF; | ||
| 67 | + } | ||
| 68 | + | ||
| 69 | + &.state-label-red { | ||
| 70 | + background: #DA4E49; | ||
| 71 | + color: #FFF; | ||
| 72 | + } | ||
| 73 | + } | ||
| 51 | } | 74 | } |
app/assets/stylesheets/generic/selects.scss
| @@ -87,3 +87,37 @@ select { | @@ -87,3 +87,37 @@ select { | ||
| 87 | padding-top: 4px; | 87 | padding-top: 4px; |
| 88 | } | 88 | } |
| 89 | } | 89 | } |
| 90 | + | ||
| 91 | +.ajax-users-select { | ||
| 92 | + width: 400px; | ||
| 93 | + | ||
| 94 | + &.input-large { | ||
| 95 | + width: 210px; | ||
| 96 | + } | ||
| 97 | + | ||
| 98 | + &.input-clamp { | ||
| 99 | + max-width: 100%; | ||
| 100 | + } | ||
| 101 | +} | ||
| 102 | + | ||
| 103 | +.user-result { | ||
| 104 | + .user-image { | ||
| 105 | + float: left; | ||
| 106 | + } | ||
| 107 | + .user-name { | ||
| 108 | + } | ||
| 109 | + .user-username { | ||
| 110 | + color: #999; | ||
| 111 | + } | ||
| 112 | +} | ||
| 113 | + | ||
| 114 | +.namespace-result { | ||
| 115 | + .namespace-kind { | ||
| 116 | + color: #AAA; | ||
| 117 | + font-weight: normal; | ||
| 118 | + } | ||
| 119 | + .namespace-path { | ||
| 120 | + margin-left: 10px; | ||
| 121 | + font-weight: bolder; | ||
| 122 | + } | ||
| 123 | +} |
app/assets/stylesheets/sections/issues.scss
| @@ -125,3 +125,21 @@ | @@ -125,3 +125,21 @@ | ||
| 125 | form.edit-issue { | 125 | form.edit-issue { |
| 126 | margin: 0; | 126 | margin: 0; |
| 127 | } | 127 | } |
| 128 | + | ||
| 129 | +.merge-request, | ||
| 130 | +.issue { | ||
| 131 | + &.today { | ||
| 132 | + background: #EFE; | ||
| 133 | + border-color: #CEC; | ||
| 134 | + } | ||
| 135 | + | ||
| 136 | + &.closed { | ||
| 137 | + background: #F5f5f5; | ||
| 138 | + border-color: #E5E5E5; | ||
| 139 | + } | ||
| 140 | + | ||
| 141 | + &.merged { | ||
| 142 | + background: #F5f5f5; | ||
| 143 | + border-color: #E5E5E5; | ||
| 144 | + } | ||
| 145 | +} |
app/views/admin/projects/index.html.haml
| @@ -53,5 +53,5 @@ | @@ -53,5 +53,5 @@ | ||
| 53 | = link_to 'Edit', edit_project_path(project), id: "edit_#{dom_id(project)}", class: "btn btn-small" | 53 | = link_to 'Edit', edit_project_path(project), id: "edit_#{dom_id(project)}", class: "btn btn-small" |
| 54 | = link_to 'Destroy', [project], data: { confirm: remove_project_message(project) }, method: :delete, class: "btn btn-small btn-remove" | 54 | = link_to 'Destroy', [project], data: { confirm: remove_project_message(project) }, method: :delete, class: "btn btn-small btn-remove" |
| 55 | - if @projects.blank? | 55 | - if @projects.blank? |
| 56 | - %p.nothing_here_message 0 projects matches | 56 | + .nothing-here-block 0 projects matches |
| 57 | = paginate @projects, theme: "gitlab" | 57 | = paginate @projects, theme: "gitlab" |
app/views/dashboard/_activities.html.haml
app/views/dashboard/_groups.html.haml
app/views/dashboard/_projects.html.haml
| @@ -14,7 +14,7 @@ | @@ -14,7 +14,7 @@ | ||
| 14 | 14 | ||
| 15 | - if projects.blank? | 15 | - if projects.blank? |
| 16 | %li | 16 | %li |
| 17 | - %h3.nothing_here_message There are no projects here. | 17 | + .nothing-here-block There are no projects here. |
| 18 | - if @projects_count > @projects_limit | 18 | - if @projects_count > @projects_limit |
| 19 | %li.bottom | 19 | %li.bottom |
| 20 | %span.light | 20 | %span.light |
app/views/dashboard/projects.html.haml
| @@ -67,7 +67,7 @@ | @@ -67,7 +67,7 @@ | ||
| 67 | 67 | ||
| 68 | - if @projects.blank? | 68 | - if @projects.blank? |
| 69 | %li | 69 | %li |
| 70 | - %h3.nothing_here_message There are no projects here. | 70 | + .nothing-here-block There are no projects here. |
| 71 | .bottom | 71 | .bottom |
| 72 | = paginate @projects, theme: "gitlab" | 72 | = paginate @projects, theme: "gitlab" |
| 73 | 73 |
app/views/groups/_filter.html.haml
| @@ -21,7 +21,7 @@ | @@ -21,7 +21,7 @@ | ||
| 21 | = project.name_with_namespace | 21 | = project.name_with_namespace |
| 22 | %small.pull-right= entities_per_project(project, entity) | 22 | %small.pull-right= entities_per_project(project, entity) |
| 23 | - if @projects.blank? | 23 | - if @projects.blank? |
| 24 | - %p.nothing_here_message This group has no projects yet | 24 | + .nothing-here-block This group has no projects yet |
| 25 | 25 | ||
| 26 | %fieldset | 26 | %fieldset |
| 27 | %hr | 27 | %hr |
app/views/groups/_projects.html.haml
| @@ -8,7 +8,7 @@ | @@ -8,7 +8,7 @@ | ||
| 8 | New project | 8 | New project |
| 9 | %ul.well-list | 9 | %ul.well-list |
| 10 | - if projects.blank? | 10 | - if projects.blank? |
| 11 | - %p.nothing_here_message This groups has no projects yet | 11 | + .nothing-here-block This groups has no projects yet |
| 12 | - projects.each do |project| | 12 | - projects.each do |project| |
| 13 | %li.project-row | 13 | %li.project-row |
| 14 | = link_to project_path(project), class: dom_class(project) do | 14 | = link_to project_path(project), class: dom_class(project) do |
app/views/groups/edit.html.haml
| @@ -80,7 +80,7 @@ | @@ -80,7 +80,7 @@ | ||
| 80 | = link_to 'Edit', edit_project_path(project), id: "edit_#{dom_id(project)}", class: "btn btn-small" | 80 | = link_to 'Edit', edit_project_path(project), id: "edit_#{dom_id(project)}", class: "btn btn-small" |
| 81 | = link_to 'Remove', project, data: { confirm: remove_project_message(project)}, method: :delete, class: "btn btn-small btn-remove" | 81 | = link_to 'Remove', project, data: { confirm: remove_project_message(project)}, method: :delete, class: "btn btn-small btn-remove" |
| 82 | - if @group.projects.blank? | 82 | - if @group.projects.blank? |
| 83 | - %p.nothing_here_message This group has no projects yet | 83 | + .nothing-here-block This group has no projects yet |
| 84 | 84 | ||
| 85 | .tab-pane#tab-remove | 85 | .tab-pane#tab-remove |
| 86 | .ui-box.ui-box-danger | 86 | .ui-box.ui-box-danger |
app/views/groups/show.html.haml
| @@ -10,7 +10,7 @@ | @@ -10,7 +10,7 @@ | ||
| 10 | - if @events.any? | 10 | - if @events.any? |
| 11 | .content_list | 11 | .content_list |
| 12 | - else | 12 | - else |
| 13 | - %p.nothing_here_message Project activity will be displayed here | 13 | + .nothing-here-block Project activity will be displayed here |
| 14 | = spinner | 14 | = spinner |
| 15 | .side.col-md-4 | 15 | .side.col-md-4 |
| 16 | .light-well.append-bottom-20 | 16 | .light-well.append-bottom-20 |
app/views/profiles/keys/index.html.haml
app/views/projects/blob/_text.html.haml
app/views/projects/commits/_diffs.html.haml
| @@ -8,18 +8,18 @@ | @@ -8,18 +8,18 @@ | ||
| 8 | - if current_controller?(:commit) or current_controller?(:merge_requests) | 8 | - if current_controller?(:commit) or current_controller?(:merge_requests) |
| 9 | Please, download the diff as | 9 | Please, download the diff as |
| 10 | - if current_controller?(:commit) | 10 | - if current_controller?(:commit) |
| 11 | - = link_to "plain diff", project_commit_path(@project, @commit, format: :diff), class: "underlined_link" | 11 | + = link_to "plain diff", project_commit_path(@project, @commit, format: :diff), class: "underlined-link" |
| 12 | or | 12 | or |
| 13 | - = link_to "email patch", project_commit_path(@project, @commit, format: :patch), class: "underlined_link" | 13 | + = link_to "email patch", project_commit_path(@project, @commit, format: :patch), class: "underlined-link" |
| 14 | - else | 14 | - else |
| 15 | - = link_to "plain diff", project_merge_request_path(@project, @merge_request, format: :diff), class: "underlined_link" | 15 | + = link_to "plain diff", project_merge_request_path(@project, @merge_request, format: :diff), class: "underlined-link" |
| 16 | or | 16 | or |
| 17 | - = link_to "email patch", project_merge_request_path(@project, @merge_request, format: :patch), class: "underlined_link" | 17 | + = link_to "email patch", project_merge_request_path(@project, @merge_request, format: :patch), class: "underlined-link" |
| 18 | instead. | 18 | instead. |
| 19 | - unless @force_suppress_diff | 19 | - unless @force_suppress_diff |
| 20 | %p | 20 | %p |
| 21 | If you still want to see the diff | 21 | If you still want to see the diff |
| 22 | - = link_to "click this link", url_for(force_show_diff: true), class: "underlined_link" | 22 | + = link_to "click this link", url_for(force_show_diff: true), class: "underlined-link" |
| 23 | 23 | ||
| 24 | %p.commit-stat-summary | 24 | %p.commit-stat-summary |
| 25 | Showing | 25 | Showing |
| @@ -74,4 +74,4 @@ | @@ -74,4 +74,4 @@ | ||
| 74 | - old_file = project.repository.blob_at(@commit.parent_id, diff.old_path) if @commit.parent_id | 74 | - old_file = project.repository.blob_at(@commit.parent_id, diff.old_path) if @commit.parent_id |
| 75 | = render "projects/commits/image", diff: diff, old_file: old_file, file: file, index: i | 75 | = render "projects/commits/image", diff: diff, old_file: old_file, file: file, index: i |
| 76 | - else | 76 | - else |
| 77 | - %p.nothing_here_message No preview for this file type | 77 | + .nothing-here-block No preview for this file type |
app/views/projects/deploy_keys/index.html.haml
| @@ -20,7 +20,7 @@ | @@ -20,7 +20,7 @@ | ||
| 20 | = render @enabled_keys | 20 | = render @enabled_keys |
| 21 | - if @enabled_keys.blank? | 21 | - if @enabled_keys.blank? |
| 22 | .light-well | 22 | .light-well |
| 23 | - %p.nothing_here_message Create a #{link_to 'new deploy key', new_project_deploy_key_path(@project)} or add an existing one | 23 | + .nothing-here-block Create a #{link_to 'new deploy key', new_project_deploy_key_path(@project)} or add an existing one |
| 24 | .col-md-6.available-keys | 24 | .col-md-6.available-keys |
| 25 | %h5 | 25 | %h5 |
| 26 | %strong Deploy keys | 26 | %strong Deploy keys |
| @@ -29,4 +29,4 @@ | @@ -29,4 +29,4 @@ | ||
| 29 | = render @available_keys | 29 | = render @available_keys |
| 30 | - if @available_keys.blank? | 30 | - if @available_keys.blank? |
| 31 | .light-well | 31 | .light-well |
| 32 | - %p.nothing_here_message Deploy keys from projects you have access to will be displayed here | 32 | + .nothing-here-block Deploy keys from projects you have access to will be displayed here |
app/views/projects/edit.html.haml
| @@ -93,10 +93,11 @@ | @@ -93,10 +93,11 @@ | ||
| 93 | 93 | ||
| 94 | 94 | ||
| 95 | 95 | ||
| 96 | - %center.light.prepend-top-20.padded | 96 | + .centered-light-block |
| 97 | %h3 | 97 | %h3 |
| 98 | %i.icon-warning-sign | 98 | %i.icon-warning-sign |
| 99 | Dangerous settings | 99 | Dangerous settings |
| 100 | + | ||
| 100 | %p Project settings below may result in data loss! | 101 | %p Project settings below may result in data loss! |
| 101 | = link_to '#', class: 'btn js-toggle-visibility-link' do | 102 | = link_to '#', class: 'btn js-toggle-visibility-link' do |
| 102 | Show it to me | 103 | Show it to me |
| @@ -132,7 +133,7 @@ | @@ -132,7 +133,7 @@ | ||
| 132 | data: { confirm: "Are you sure that you want to archive this project?\nAn archived project cannot be committed to." }, | 133 | data: { confirm: "Are you sure that you want to archive this project?\nAn archived project cannot be committed to." }, |
| 133 | method: :post, class: "btn btn-remove" | 134 | method: :post, class: "btn btn-remove" |
| 134 | - else | 135 | - else |
| 135 | - %p.nothing_here_message Only the project owner can archive a project | 136 | + .nothing-here-block Only the project owner can archive a project |
| 136 | 137 | ||
| 137 | - if can?(current_user, :change_namespace, @project) | 138 | - if can?(current_user, :change_namespace, @project) |
| 138 | .ui-box.ui-box-danger | 139 | .ui-box.ui-box-danger |
| @@ -153,7 +154,7 @@ | @@ -153,7 +154,7 @@ | ||
| 153 | .form-actions | 154 | .form-actions |
| 154 | = f.submit 'Transfer', class: "btn btn-remove" | 155 | = f.submit 'Transfer', class: "btn btn-remove" |
| 155 | - else | 156 | - else |
| 156 | - %p.nothing_here_message Only the project owner can transfer a project | 157 | + .nothing-here-block Only the project owner can transfer a project |
| 157 | 158 | ||
| 158 | .ui-box.ui-box-danger | 159 | .ui-box.ui-box-danger |
| 159 | .title Rename repository | 160 | .title Rename repository |
| @@ -185,7 +186,7 @@ | @@ -185,7 +186,7 @@ | ||
| 185 | 186 | ||
| 186 | = link_to 'Remove project', @project, data: { confirm: remove_project_message(@project) }, method: :delete, class: "btn btn-remove" | 187 | = link_to 'Remove project', @project, data: { confirm: remove_project_message(@project) }, method: :delete, class: "btn btn-remove" |
| 187 | - else | 188 | - else |
| 188 | - %p.nothing_here_message Only project owner can remove a project | 189 | + .nothing-here-block Only project owner can remove a project |
| 189 | 190 | ||
| 190 | .save-project-loader.hide | 191 | .save-project-loader.hide |
| 191 | %center | 192 | %center |
app/views/projects/issues/_issues.html.haml
| @@ -66,7 +66,7 @@ | @@ -66,7 +66,7 @@ | ||
| 66 | = render @issues | 66 | = render @issues |
| 67 | - if @issues.blank? | 67 | - if @issues.blank? |
| 68 | %li | 68 | %li |
| 69 | - %h4.nothing_here_message No issues to show | 69 | + .nothing-here-block No issues to show |
| 70 | 70 | ||
| 71 | - if @issues.present? | 71 | - if @issues.present? |
| 72 | .pull-right | 72 | .pull-right |
app/views/projects/labels/index.html.haml
| @@ -7,4 +7,4 @@ | @@ -7,4 +7,4 @@ | ||
| 7 | 7 | ||
| 8 | - else | 8 | - else |
| 9 | .light-well | 9 | .light-well |
| 10 | - %h3.nothing_here_message Add first label to your issues or #{link_to 'generate', generate_project_labels_path(@project), method: :post} default set of labels | 10 | + .nothing-here-block Add first label to your issues or #{link_to 'generate', generate_project_labels_path(@project), method: :post} default set of labels |
app/views/projects/merge_requests/index.html.haml
| @@ -65,7 +65,7 @@ | @@ -65,7 +65,7 @@ | ||
| 65 | = render @merge_requests | 65 | = render @merge_requests |
| 66 | - if @merge_requests.blank? | 66 | - if @merge_requests.blank? |
| 67 | %li | 67 | %li |
| 68 | - %h4.nothing_here_message No merge requests to show | 68 | + .nothing-here-block No merge requests to show |
| 69 | - if @merge_requests.present? | 69 | - if @merge_requests.present? |
| 70 | .pull-right | 70 | .pull-right |
| 71 | %span.cgray.pull-right #{@merge_requests.total_count} merge requests for this filter | 71 | %span.cgray.pull-right #{@merge_requests.total_count} merge requests for this filter |
app/views/projects/merge_requests/show/_commits.html.haml
| @@ -29,7 +29,7 @@ | @@ -29,7 +29,7 @@ | ||
| 29 | = render "projects/commits/commit", commit: commit, project: @merge_request.source_project | 29 | = render "projects/commits/commit", commit: commit, project: @merge_request.source_project |
| 30 | 30 | ||
| 31 | - else | 31 | - else |
| 32 | - %h4.nothing_here_message | 32 | + .nothing-here-block |
| 33 | Nothing to merge from | 33 | Nothing to merge from |
| 34 | %span.label-branch #{@merge_request.source_branch} | 34 | %span.label-branch #{@merge_request.source_branch} |
| 35 | to | 35 | to |
app/views/projects/merge_requests/show/_diffs.html.haml
| 1 | - if @merge_request_diff.collected? | 1 | - if @merge_request_diff.collected? |
| 2 | = render "projects/commits/diffs", diffs: @merge_request.diffs, project: @merge_request.source_project | 2 | = render "projects/commits/diffs", diffs: @merge_request.diffs, project: @merge_request.source_project |
| 3 | - elsif @merge_request_diff.empty? | 3 | - elsif @merge_request_diff.empty? |
| 4 | - %h4.nothing_here_message Nothing to merge from #{@merge_request.source_branch} into #{@merge_request.target_branch} | 4 | + .nothing-here-block Nothing to merge from #{@merge_request.source_branch} into #{@merge_request.target_branch} |
| 5 | - else | 5 | - else |
| 6 | .bs-callout.bs-callout-warning | 6 | .bs-callout.bs-callout-warning |
| 7 | %h4 | 7 | %h4 |
app/views/projects/milestones/index.html.haml
| @@ -26,6 +26,6 @@ | @@ -26,6 +26,6 @@ | ||
| 26 | 26 | ||
| 27 | - if @milestones.blank? | 27 | - if @milestones.blank? |
| 28 | %li | 28 | %li |
| 29 | - %h3.nothing_here_message No milestones to show | 29 | + .nothing-here-block No milestones to show |
| 30 | 30 | ||
| 31 | = paginate @milestones, theme: "gitlab" | 31 | = paginate @milestones, theme: "gitlab" |
app/views/projects/milestones/show.html.haml
| @@ -3,19 +3,13 @@ | @@ -3,19 +3,13 @@ | ||
| 3 | Milestone ##{@milestone.iid} | 3 | Milestone ##{@milestone.iid} |
| 4 | %small | 4 | %small |
| 5 | = @milestone.expires_at | 5 | = @milestone.expires_at |
| 6 | - - if @milestone.closed? | ||
| 7 | - %span.state-label.state-label-red Closed | ||
| 8 | - - elsif @milestone.expired? | ||
| 9 | - %span.state-label.state-label-red Expired | ||
| 10 | - - else | ||
| 11 | - %span.state-label.state-label-green Open | ||
| 12 | .pull-right | 6 | .pull-right |
| 13 | - if can?(current_user, :admin_milestone, @project) | 7 | - if can?(current_user, :admin_milestone, @project) |
| 14 | = link_to edit_project_milestone_path(@project, @milestone), class: "btn btn-grouped" do | 8 | = link_to edit_project_milestone_path(@project, @milestone), class: "btn btn-grouped" do |
| 15 | %i.icon-edit | 9 | %i.icon-edit |
| 16 | Edit | 10 | Edit |
| 17 | - if @milestone.active? | 11 | - if @milestone.active? |
| 18 | - = link_to 'Close Milestone', project_milestone_path(@project, @milestone, milestone: {state_event: :close }), method: :put, class: "btn btn-remove grouped" | 12 | + = link_to 'Close Milestone', project_milestone_path(@project, @milestone, milestone: {state_event: :close }), method: :put, class: "btn btn-remove btn-grouped" |
| 19 | - else | 13 | - else |
| 20 | = link_to 'Reopen Milestone', project_milestone_path(@project, @milestone, milestone: {state_event: :activate }), method: :put, class: "btn btn-grouped" | 14 | = link_to 'Reopen Milestone', project_milestone_path(@project, @milestone, milestone: {state_event: :activate }), method: :put, class: "btn btn-grouped" |
| 21 | 15 | ||
| @@ -29,6 +23,14 @@ | @@ -29,6 +23,14 @@ | ||
| 29 | 23 | ||
| 30 | 24 | ||
| 31 | .issue-box | 25 | .issue-box |
| 26 | + .state | ||
| 27 | + - if @milestone.closed? | ||
| 28 | + %span.state-label.state-label-red Closed | ||
| 29 | + - elsif @milestone.expired? | ||
| 30 | + %span.state-label.state-label-red Expired | ||
| 31 | + - else | ||
| 32 | + %span.state-label.state-label-green Open | ||
| 33 | + | ||
| 32 | %h4.title | 34 | %h4.title |
| 33 | = gfm escape_once(@milestone.title) | 35 | = gfm escape_once(@milestone.title) |
| 34 | 36 |
app/views/projects/protected_branches/index.html.haml
| @@ -9,7 +9,7 @@ | @@ -9,7 +9,7 @@ | ||
| 9 | %ul | 9 | %ul |
| 10 | %li keep stable branches secured | 10 | %li keep stable branches secured |
| 11 | %li forced code review before merge to protected branches | 11 | %li forced code review before merge to protected branches |
| 12 | - %p Read more about project permissions #{link_to "here", help_permissions_path, class: "underlined_link"} | 12 | + %p Read more about project permissions #{link_to "here", help_permissions_path, class: "underlined-link"} |
| 13 | 13 | ||
| 14 | - if can? current_user, :admin_project, @project | 14 | - if can? current_user, :admin_project, @project |
| 15 | = form_for [@project, @protected_branch], html: { class: 'form-horizontal' } do |f| | 15 | = form_for [@project, @protected_branch], html: { class: 'form-horizontal' } do |f| |
app/views/projects/snippets/index.html.haml
| @@ -12,4 +12,4 @@ | @@ -12,4 +12,4 @@ | ||
| 12 | = render partial: "projects/snippets/snippet", collection: @snippets | 12 | = render partial: "projects/snippets/snippet", collection: @snippets |
| 13 | - if @snippets.empty? | 13 | - if @snippets.empty? |
| 14 | %li | 14 | %li |
| 15 | - %h3.nothing_here_message Nothing here. | 15 | + .nothing-here-block Nothing here. |
app/views/projects/tags/index.html.haml
app/views/public/projects/index.html.haml
| @@ -63,6 +63,6 @@ | @@ -63,6 +63,6 @@ | ||
| 63 | %i.icon-warning-sign | 63 | %i.icon-warning-sign |
| 64 | Empty repository | 64 | Empty repository |
| 65 | - unless @projects.present? | 65 | - unless @projects.present? |
| 66 | - %h3.nothing_here_message No public projects | 66 | + .nothing-here-block No public projects |
| 67 | 67 | ||
| 68 | = paginate @projects, theme: "gitlab" | 68 | = paginate @projects, theme: "gitlab" |
app/views/shared/_issues.html.haml
| @@ -11,5 +11,5 @@ | @@ -11,5 +11,5 @@ | ||
| 11 | = render 'projects/issues/issue', issue: issue | 11 | = render 'projects/issues/issue', issue: issue |
| 12 | = paginate @issues, theme: "gitlab" | 12 | = paginate @issues, theme: "gitlab" |
| 13 | - else | 13 | - else |
| 14 | - %p.nothing_here_message No issues to show | 14 | + .nothing-here-block No issues to show |
| 15 | 15 |
app/views/shared/_merge_requests.html.haml
app/views/snippets/_blob_content.html.haml
app/views/snippets/_snippets.html.haml
| @@ -2,6 +2,6 @@ | @@ -2,6 +2,6 @@ | ||
| 2 | = render partial: 'snippet', collection: @snippets | 2 | = render partial: 'snippet', collection: @snippets |
| 3 | - if @snippets.empty? | 3 | - if @snippets.empty? |
| 4 | %li | 4 | %li |
| 5 | - %h3.nothing_here_message Nothing here. | 5 | + .nothing-here-block Nothing here. |
| 6 | 6 | ||
| 7 | = paginate @snippets, theme: 'gitlab' | 7 | = paginate @snippets, theme: 'gitlab' |