diff --git a/app/assets/stylesheets/common.scss b/app/assets/stylesheets/common.scss index ccd9fdfb8994dbfb2e08be293cb489f50d0d2c2a..12924d0b08c54dc1f7936cac43b5cefe8f75a34b 100644 --- a/app/assets/stylesheets/common.scss +++ b/app/assets/stylesheets/common.scss @@ -129,6 +129,9 @@ a:focus { .no-borders { border:none; } +.lborder { + border-left:1px solid #eee; +} table.no-borders { border:none; tr, td { border:none } @@ -855,25 +858,62 @@ p.time { .dashboard_category { margin-bottom:30px; + table.projects_row { + margin: 50px 0; + td { + border-top:none; + + &.more { + float:right; + width:90px; + h3 { + padding-right:20px; + } + } + &.new_project { + width:150px; + float:right; + h3 { + padding-right:20px; + } + } - h3 a { - color:#474D57; + a.project { + color:#ccc; + padding:0 20px; + + &:hover { + color:$style_color; + text-decoration:underline; + } + } + } + } + + h3 a { + color:$style_color; &:hover { text-decoration:underline; } } - .dashboard_block { - width:840px; - margin:auto; + .dashboard_block { .dash_project_item { margin-bottom:10px; border:none; + padding:0px 5px; + &:hover { - background:none; - h4 { color:#2FA0BB; } + background:$hover; + //border-left:4px solid $styled_border_color; + h4 { + color:#111; + .ico.project { + background-position:-209px -21px; + } + } } h4 { @@ -933,7 +973,6 @@ p.time { } .leftbar { - h5, .title { padding:5px 10px; } @@ -949,7 +988,7 @@ p.time { a:hover { h4 { color:#111; - border-right:4px solid $styled_border_color; + background:$hover; .ico.project { background-position:-209px -21px; } @@ -1073,7 +1112,8 @@ p.time { .arrow{ float: right; background: #E3E5EA; - padding: 10px; + padding: 5px; + margin-top:5px; border-radius: 5px; text-shadow: none; color: #999; diff --git a/app/views/dashboard/index.html.haml b/app/views/dashboard/index.html.haml index 3bd411da58c75b6d163366b8e96558c3dbf35c1a..d542725087ced51e097cb881b5d91c75289d9a81 100644 --- a/app/views/dashboard/index.html.haml +++ b/app/views/dashboard/index.html.haml @@ -7,48 +7,64 @@ to your profile %div.dashboard_category - %h3 - %span.ico.projects - = link_to "Projects" , "#projects", :id => "projects" - %small - (most recent) + %table.projects_row + %tr + -#%td + %h3.left + %span.ico.projects + = link_to "Projects:" , "#projects", :id => "projects" + + - @active_projects.first(4).each do |project| + %td + %h3 + = link_to project, :class => "project" do + = truncate project.name, :length => 18 + + - if @active_projects.count > 4 + %td.more + %h3.right + = link_to projects_path do + %small more → + - else + %td.new_project + %h3.right + = link_to new_project_path do + %small New project → + + - %strong.right - = link_to projects_path do - Projects list → %hr - .row - .dashboard_block - .row - .span4.right - %div.borders.ipadded - %h1 - = pluralize current_user.projects.count, "project", "projects" - - if current_user.can_create_project? - %hr - %div - You can create up to - = current_user.projects_limit - projects. Click on button below to add a new one - .link_holder - %br - = link_to new_project_path, :class => "btn" do - New Project » - - else - %hr - %div - You've reached project limit for your account. - You cannot create new projects. - .link_holder - %br - = link_to profile_path, :class => "btn" do - Your Profile » - .span10.left= render "dashboard/projects_feed", :projects => @active_projects - - if @last_push - .padded.prepend-top-20 - %h5 - %small Latest push was to the #{@last_push.branch_name} branch of #{@last_push.project.name}: - %ul.unstyled= render @last_push + .dashboard_block + .row + .span4.right + %div.ipadded.lborder + %h3 + = pluralize current_user.projects.count, "project", "projects" + - if current_user.can_create_project? + %hr + %p + You can create up to + = current_user.projects_limit + projects. Click on button below to add a new one + .link_holder + %br + = link_to new_project_path, :class => "btn" do + New Project » + - else + %hr + %p + You've reached project limit for your account. + You cannot create new projects. + .link_holder + %br + = link_to profile_path, :class => "btn" do + Your Profile » + .span12.left + - if @last_push + %div + %h5 + %small Latest push was to the #{@last_push.branch_name} branch of #{@last_push.project.name}: + %ul.unstyled= render @last_push - if @merge_requests.any? %div.dashboard_category @@ -60,8 +76,7 @@ = link_to dashboard_merge_requests_path do Visit merge requests page → %hr - .row - .dashboard_block= render "dashboard/merge_requests_feed" + .dashboard_block= render "dashboard/merge_requests_feed" - if @issues.any? %div.dashboard_category @@ -72,8 +87,7 @@ = link_to dashboard_issues_path do Visit issues page → %hr - .row - .dashboard_block= render "dashboard/issues_feed" + .dashboard_block= render "dashboard/issues_feed" - if @events.any? %div.dashboard_category @@ -82,5 +96,4 @@ = link_to "Activities" , "#activities", :id => "activities" %hr - .row - .dashboard_block= render @events + .dashboard_block= render @events