Commit dfb0b5de authored by Jacob Schatz's avatar Jacob Schatz

Merge branch 'projects-blank-state' into 'master'

Projects blank state

## What does this MR do?

Adds a designed blank state to dashboard/projects

## What are the relevant issue numbers?

Part of #18519 

## Screenshots (if relevant)

![Screen_Shot_2016-06-24_at_17.14.46](/uploads/593ea1c5efa2310a0f94b2d56d94cf3c/Screen_Shot_2016-06-24_at_17.14.46.png)

See merge request !4909
parents 7cdcb295 e26f8bf7
...@@ -20,9 +20,12 @@ ...@@ -20,9 +20,12 @@
.blank-state-icon { .blank-state-icon {
padding-bottom: 20px; padding-bottom: 20px;
color: $gray-darkest;
font-size: 56px;
path { path,
fill: $gray-darkest; polygon {
fill: currentColor;
} }
} }
...@@ -37,6 +40,10 @@ ...@@ -37,6 +40,10 @@
margin-top: 0; margin-top: 0;
margin-bottom: $gl-padding; margin-bottom: $gl-padding;
font-size: 15px; font-size: 15px;
> strong {
font-weight: 600;
}
} }
.blank-state-welcome-title { .blank-state-welcome-title {
......
...@@ -270,21 +270,6 @@ table { ...@@ -270,21 +270,6 @@ table {
} }
} }
.dashboard-intro-icon {
float: left;
text-align: center;
font-size: 32px;
color: #aaa;
width: 60px;
}
.dashboard-intro-text {
display: inline-block;
margin-left: -60px;
padding-left: 60px;
width: 100%;
}
.btn-sign-in { .btn-sign-in {
text-shadow: none; text-shadow: none;
......
- publicish_project_count = ProjectsFinder.new.execute(current_user).count - publicish_project_count = ProjectsFinder.new.execute(current_user).count
%h3.page-title Welcome to GitLab! .blank-state.blank-state-welcome
%p.light Self hosted Git management application. %h2.blank-state-welcome-title
%hr Welcome to GitLab
%div %p.blank-state-text
.dashboard-intro-icon Code, test, and deploy together
%i.fa.fa-bookmark-o .blank-state
.dashboard-intro-text .blank-state-icon
%p.slead = navbar_icon("project", size: 50)
You don't have access to any projects right now. %h3.blank-state-title
%br You don't have access to any projects right now
%p.blank-state-text
- if current_user.can_create_project? - if current_user.can_create_project?
You can create up to You can create up to
%strong= pluralize(number_with_delimiter(current_user.projects_limit), "project") + "." %strong= number_with_delimiter(current_user.projects_limit)
= succeed "." do
= "project".pluralize(current_user.projects_limit)
- else - else
If you are added to a project, it will be displayed here. If you are added to a project, it will be displayed here.
- if current_user.can_create_project? - if current_user.can_create_project?
.link_holder
= link_to new_project_path, class: "btn btn-new" do = link_to new_project_path, class: "btn btn-new" do
= icon('plus') New project
New Project
- if current_user.can_create_group? - if current_user.can_create_group?
%hr .blank-state
%div .blank-state-icon
.dashboard-intro-icon = navbar_icon("group", size: 50)
%i.fa.fa-users %h3.blank-state-title
.dashboard-intro-text
%p.slead
You can create a group for several dependent projects. You can create a group for several dependent projects.
%br %p.blank-state-text
Groups are the best way to manage projects and members. Groups are the best way to manage projects and members.
.link_holder
= link_to new_group_path, class: "btn btn-new" do = link_to new_group_path, class: "btn btn-new" do
%i.fa.fa-plus New group
New Group
-if publicish_project_count > 0 -if publicish_project_count > 0
%hr .blank-state
%div .blank-state-icon
.dashboard-intro-icon = icon("globe")
%i.fa.fa-globe %h3.blank-state-title
.dashboard-intro-text
%p.slead
There are There are
%strong= number_with_delimiter(publicish_project_count) = number_with_delimiter(publicish_project_count)
public projects on this server. public projects on this server.
%br %p.blank-state-text
Public projects are an easy way to allow everyone to have read-only access. Public projects are an easy way to allow everyone to have read-only access.
.link_holder
= link_to trending_explore_projects_path, class: "btn btn-new" do = link_to trending_explore_projects_path, class: "btn btn-new" do
Browse public projects Browse projects
...@@ -5,7 +5,8 @@ ...@@ -5,7 +5,8 @@
- page_title "Projects" - page_title "Projects"
- header_title "Projects", dashboard_projects_path - header_title "Projects", dashboard_projects_path
= render 'dashboard/projects_head' - if @projects.any? || params[:filter_projects]
= render 'dashboard/projects_head'
- if @last_push - if @last_push
= render "events/event_last_push", event: @last_push = render "events/event_last_push", event: @last_push
......
<?xml version="1.0" encoding="UTF-8" standalone="no"?> <svg width="<%= size %>" height="<%= size %>" viewBox="0 0 16 16">
<svg width="16px" height="16px" viewBox="0 0 16 16" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- Generator: Sketch 3.7.2 (28276) - http://www.bohemiancoding.com/sketch -->
<title>Group</title>
<desc>Created with Sketch.</desc>
<defs></defs>
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd"> <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
<g id="Group" fill="#303030"> <g id="Group" fill="#303030">
<path d="M15.6667,10.0105 L10.3337,10.0105 C10.1497,10.0105 9.9997,10.1775 9.9997,10.3845 L9.9997,15.6145 C9.9997,15.8215 10.1497,15.9885 10.3337,15.9885 L15.6667,15.9885 C15.8507,15.9885 15.9997,15.8215 15.9997,15.6145 L15.9997,10.3845 C15.9997,10.1775 15.8507,10.0105 15.6667,10.0105 L15.6667,10.0105 L15.6667,10.0105 Z M11.9997,14.0105 L13.9997,14.0105 L13.9997,12.0105 L11.9997,12.0105 L11.9997,14.0105 L11.9997,14.0105 Z" id="Fill-11"></path> <path d="M15.6667,10.0105 L10.3337,10.0105 C10.1497,10.0105 9.9997,10.1775 9.9997,10.3845 L9.9997,15.6145 C9.9997,15.8215 10.1497,15.9885 10.3337,15.9885 L15.6667,15.9885 C15.8507,15.9885 15.9997,15.8215 15.9997,15.6145 L15.9997,10.3845 C15.9997,10.1775 15.8507,10.0105 15.6667,10.0105 L15.6667,10.0105 L15.6667,10.0105 Z M11.9997,14.0105 L13.9997,14.0105 L13.9997,12.0105 L11.9997,12.0105 L11.9997,14.0105 L11.9997,14.0105 Z" id="Fill-11"></path>
......
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg width="16px" height="16px" viewBox="0 0 16 16" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<!-- Generator: Sketch 3.8.3 (29802) - http://www.bohemiancoding.com/sketch -->
<title>Page 1</title>
<desc>Created with Sketch.</desc>
<defs></defs>
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
<path d="M6,6 L12,6 L12,5 L6,5 L6,6 Z M6,8 L12,8 L12,7 L6,7 L6,8 Z M6,10 L12,10 L12,9 L6,9 L6,10 Z M6,12 L12,12 L12,11 L6,11 L6,12 Z M4,6 L5,6 L5,5 L4,5 L4,6 Z M4,8 L5,8 L5,7 L4,7 L4,8 Z M4,10 L5,10 L5,9 L4,9 L4,10 Z M4,12 L5,12 L5,11 L4,11 L4,12 Z M13,3 L10,3 L10,4 L6,4 L6,3 L3,3 L3,13 L13,13 L13,3 Z M2,14 L14,14 L14,2 L2,2 L2,14 Z M1,0 C0.448,0 0,0.448 0,1 L0,15 C0,15.552 0.448,16 1,16 L15,16 C15.552,16 16,15.552 16,15 L16,1 C16,0.448 15.552,0 15,0 L1,0 Z" fill="#7F7E7E"></path>
</g>
</svg>
\ No newline at end of file
<svg width="<%= size %>" height="<%= size %>" viewBox="0 0 16 16">
<path d="M6,6 L12,6 L12,5 L6,5 L6,6 Z M6,8 L12,8 L12,7 L6,7 L6,8 Z M6,10 L12,10 L12,9 L6,9 L6,10 Z M6,12 L12,12 L12,11 L6,11 L6,12 Z M4,6 L5,6 L5,5 L4,5 L4,6 Z M4,8 L5,8 L5,7 L4,7 L4,8 Z M4,10 L5,10 L5,9 L4,9 L4,10 Z M4,12 L5,12 L5,11 L4,11 L4,12 Z M13,3 L10,3 L10,4 L6,4 L6,3 L3,3 L3,13 L13,13 L13,3 Z M2,14 L14,14 L14,2 L2,2 L2,14 Z M1,0 C0.448,0 0,0.448 0,1 L0,15 C0,15.552 0.448,16 1,16 L15,16 C15.552,16 16,15.552 16,15 L16,1 C16,0.448 15.552,0 15,0 L1,0 Z" fill="#7F7E7E" fill-rule="evenodd"></path>
</svg>
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