Commit f34b1be28102dc77d4659f3113e258afb9dc4951
1 parent
822c0a50
Exists in
master
and in
4 other branches
dashboard tabs
Showing
8 changed files
with
38 additions
and
31 deletions
Show diff stats
app/assets/stylesheets/projects.css.scss
... | ... | @@ -507,3 +507,25 @@ body.project-page table.no-borders td{ |
507 | 507 | right: 5px; |
508 | 508 | } |
509 | 509 | .box-arrow{float: right; background: #E3E5EA; padding: 10px; border-radius: 5px; margin-top: 2px; text-shadow: none; color: #999; margin: 1.5em 0;} |
510 | + | |
511 | +h4.dash-tabs { | |
512 | + margin: 0; | |
513 | + border-bottom: 1px solid #ccc; | |
514 | + padding: 10px 10px; | |
515 | + font-size: 11px; | |
516 | + padding-left:20px; | |
517 | + font-weight: bold; text-transform: uppercase; | |
518 | + background: #F7F7F7; | |
519 | + margin-bottom:20px; | |
520 | +} | |
521 | + | |
522 | +.dash-button { | |
523 | + margin-right:5px; | |
524 | + @include round-borders-all(4px); | |
525 | + border: 1px solid #ddd; | |
526 | + background:none; | |
527 | + | |
528 | + &.active { | |
529 | + background: #eaeaea; | |
530 | + } | |
531 | +} | ... | ... |
app/views/dashboard/_issues_feed.html.haml
1 | -%div | |
2 | - = link_to dashboard_path, :remote => true, :class => "left" do | |
3 | - .box-arrow | |
4 | - ← | |
5 | - %h2{:style => "width:86%; text-align:center"} | |
6 | - Issues | |
7 | - = link_to dashboard_merge_requests_path, :remote => true, :class => "right" do | |
8 | - .box-arrow | |
9 | - → | |
10 | - | |
11 | - | |
12 | 1 | #feeds_content_holder |
13 | 2 | .project-box.project-updates.ui-box.ui-box-small.ui-box-big |
14 | 3 | .data | ... | ... |
... | ... | @@ -0,0 +1,13 @@ |
1 | +%h4.dash-tabs | |
2 | + = link_to "Activities", dashboard_path, :remote => true, :class => "button-small dash-button #{"active" if current_page?(dashboard_path) || current_page?(root_path) }", :id => "activities_slide" | |
3 | + = link_to "Issues", dashboard_issues_path, :remote => true, :class => "button-small dash-button #{"active" if current_page?(dashboard_issues_path)}", :id => "issues_slide" | |
4 | + = link_to "Merge Requests", dashboard_merge_requests_path, :remote => true, :class => "button-small dash-button #{"active" if current_page?(dashboard_merge_requests_path)}", :id => "merge_requests_slide" | |
5 | + | |
6 | + | |
7 | +:javascript | |
8 | + $(function(){ | |
9 | + $(".dash-button").live("click", function() { | |
10 | + $(".dash-button").removeClass("active"); | |
11 | + $(this).addClass("active"); | |
12 | + }) | |
13 | + }); | ... | ... |
app/views/dashboard/_merge_requests_feed.html.haml
1 | -%div | |
2 | - = link_to dashboard_issues_path, :remote => true, :class => "left" do | |
3 | - .box-arrow | |
4 | - ← | |
5 | - %h2{:style => "width:86%; text-align:center"} | |
6 | - Merge Requests | |
7 | - = link_to dashboard_path, :remote => true, :class => "right" do | |
8 | - .box-arrow | |
9 | - → | |
10 | - | |
11 | 1 | #feeds_content_holder |
12 | 2 | .project-box.project-updates.ui-box.ui-box-small.ui-box-big |
13 | 3 | .data | ... | ... |
app/views/dashboard/_projects_feed.html.haml
1 | -%div | |
2 | - = link_to dashboard_merge_requests_path, :remote => true, :class => "left", :id => "merge_requests_slide" do | |
3 | - .box-arrow | |
4 | - ← | |
5 | - %h2{:style => "width:86%; text-align:center"} | |
6 | - Activities | |
7 | - = link_to dashboard_issues_path, :remote => true, :class => "right", :id => "issues_slide" do | |
8 | - .box-arrow | |
9 | - → | |
10 | - | |
11 | 1 | #feeds_content_holder |
12 | 2 | - @active_projects.first(3).each do |project| |
13 | 3 | .project-box.project-updates.ui-box.ui-box-small.ui-box-big | ... | ... |
app/views/dashboard/index.html.haml
app/views/dashboard/issues.html.haml