Commit 9daac084 authored by Frédéric Caplette's avatar Frédéric Caplette

Merge branch 'cngo-tidy-dashboard-projects-empty-state' into 'master'

Improve dashboard projects blank state code

See merge request gitlab-org/gitlab!79782
parents 458ee618 38fb3bbd
...@@ -12,10 +12,10 @@ export default { ...@@ -12,10 +12,10 @@ export default {
<template> <template>
<div class="empty-state"> <div class="empty-state">
<div class="text-content"> <div class="text-content">
<h4 class="blank-state-title js-blank-state-title"> <h4 class="js-blank-state-title">
{{ s__("Environments|You don't have any environments right now") }} {{ s__("Environments|You don't have any environments right now") }}
</h4> </h4>
<p class="blank-state-text"> <p>
{{ {{
s__(`Environments|Environments are places where s__(`Environments|Environments are places where
code gets deployed, such as staging or production.`) code gets deployed, such as staging or production.`)
......
...@@ -46,7 +46,6 @@ ...@@ -46,7 +46,6 @@
@import 'framework/toggle'; @import 'framework/toggle';
@import 'framework/typography'; @import 'framework/typography';
@import 'framework/zen'; @import 'framework/zen';
@import 'framework/blank';
@import 'framework/wells'; @import 'framework/wells';
@import 'framework/page_header'; @import 'framework/page_header';
@import 'framework/page_title'; @import 'framework/page_title';
......
.blank-state-parent-container {
.section-container {
padding: 10px;
}
.section-body {
width: 100%;
height: 100%;
padding-bottom: 25px;
border-radius: $border-radius-default;
}
}
.blank-state-row {
display: flex;
flex-wrap: wrap;
justify-content: space-between;
}
.blank-state-welcome {
text-align: center;
padding: $gl-padding 0 ($gl-padding * 2);
.blank-state-welcome-title {
font-size: 24px;
}
.blank-state-text {
margin-bottom: 0;
}
}
.blank-state-link {
color: $gl-text-color;
margin-bottom: 15px;
&:hover {
background-color: $gray-light;
text-decoration: none;
color: $gl-text-color;
}
}
.blank-state-center {
padding-top: 20px;
padding-bottom: 20px;
text-align: center;
}
.blank-state {
display: flex;
align-items: center;
padding: 20px 50px;
border: 1px solid $border-color;
border-radius: $border-radius-default;
min-height: 240px;
margin-bottom: $gl-padding;
width: calc(50% - #{$gl-padding-8});
@include media-breakpoint-down(sm) {
width: 100%;
flex-direction: column;
justify-content: center;
padding: 50px 20px;
.column-small & {
width: 100%;
}
}
}
.blank-state,
.blank-state-center {
.blank-state-icon {
svg {
display: block;
margin: auto;
}
}
.blank-state-title {
margin-top: 0;
font-size: 18px;
}
.blank-state-body {
@include media-breakpoint-down(sm) {
text-align: center;
margin-top: 20px;
}
@include media-breakpoint-up(sm) {
padding-left: 20px;
}
}
}
@include media-breakpoint-up(lg) {
.column-large {
flex: 2;
}
.column-small {
flex: 1;
margin-bottom: 15px;
.blank-state {
max-width: 400px;
flex-wrap: wrap;
margin-left: 15px;
}
.blank-state-icon {
margin-bottom: 30px;
}
}
}
@import 'mixins_and_variables_and_functions';
.blank-state {
padding: 20px 50px;
min-height: 240px;
width: calc(50% - #{$gl-padding-8});
@include media-breakpoint-down(sm) {
width: 100%;
flex-direction: column;
justify-content: center;
padding: 50px 20px;
}
}
.blank-state-link {
&:hover {
background-color: $gray-light;
text-decoration: none;
color: $gl-text-color;
}
}
.blank-state-icon {
svg {
display: block;
}
}
.blank-state-body {
@include media-breakpoint-down(sm) {
text-align: center;
margin-top: 20px;
}
}
.blank-state-row - link_classes = "blank-state blank-state-link gl-text-body gl-display-flex gl-align-items-center gl-border-1 gl-border-solid gl-border-gray-100 gl-rounded-base gl-mb-5"
.gl-display-flex.gl-flex-wrap.gl-justify-content-space-between
- if has_start_trial? - if has_start_trial?
= render_if_exists "dashboard/projects/blank_state_ee_trial" = render_if_exists "dashboard/projects/blank_state_ee_trial"
= link_to new_project_path, class: "blank-state blank-state-link" do = link_to new_project_path, class: link_classes do
.blank-state-icon .blank-state-icon
= custom_icon("add_new_project", size: 50) = custom_icon("add_new_project", size: 50)
.blank-state-body .blank-state-body.gl-sm-pl-0.gl-pl-6
%h3.blank-state-title %h3.gl-font-size-h2.gl-mt-0
Create a project = _('Create a project')
%p.blank-state-text %p
Projects are where you store your code, access issues, wiki and other features of GitLab. = _('Projects are where you store your code, access issues, wiki and other features of GitLab.')
- if current_user.can_create_group? - if current_user.can_create_group?
= link_to new_group_path, class: "blank-state blank-state-link" do = link_to new_group_path, class: link_classes do
.blank-state-icon .blank-state-icon
= custom_icon("add_new_group", size: 50) = custom_icon("add_new_group", size: 50)
.blank-state-body .blank-state-body.gl-sm-pl-0.gl-pl-6
%h3.blank-state-title %h3.gl-font-size-h2.gl-mt-0
Create a group = _('Create a group')
%p.blank-state-text %p
Groups are a great way to organize projects and people. = _('Groups are a great way to organize projects and people.')
= link_to new_admin_user_path, class: "blank-state blank-state-link" do = link_to new_admin_user_path, class: link_classes do
.blank-state-icon .blank-state-icon
= custom_icon("add_new_user", size: 50) = custom_icon("add_new_user", size: 50)
.blank-state-body .blank-state-body.gl-sm-pl-0.gl-pl-6
%h3.blank-state-title %h3.gl-font-size-h2.gl-mt-0
Add people = _('Add people')
%p.blank-state-text %p
Add your team members and others to GitLab. = _('Add your team members and others to GitLab.')
= link_to admin_root_path, class: "blank-state blank-state-link" do = link_to admin_root_path, class: link_classes do
.blank-state-icon .blank-state-icon
= custom_icon("configure_server", size: 50) = custom_icon("configure_server", size: 50)
.blank-state-body .blank-state-body.gl-sm-pl-0.gl-pl-6
%h3.blank-state-title %h3.gl-font-size-h2.gl-mt-0
Configure GitLab = _('Configure GitLab')
%p.blank-state-text %p
Make adjustments to how your GitLab instance is set up. = _('Make adjustments to how your GitLab instance is set up.')
.blank-state-row - link_classes = "blank-state blank-state-link gl-text-body gl-display-flex gl-align-items-center gl-border-1 gl-border-solid gl-border-gray-100 gl-rounded-base gl-mb-5"
.gl-display-flex.gl-flex-wrap.gl-justify-content-space-between
- if current_user.can_create_project? - if current_user.can_create_project?
= link_to new_project_path, class: "blank-state blank-state-link" do = link_to new_project_path, class: link_classes do
.blank-state-icon .blank-state-icon
= custom_icon("add_new_project", size: 50) = custom_icon("add_new_project", size: 50)
.blank-state-body .blank-state-body.gl-sm-pl-0.gl-pl-6
%h3.blank-state-title %h3.gl-font-size-h2.gl-mt-0
Create a project = _('Create a project')
%p.blank-state-text %p
Projects are where you store your code, access issues, wiki and other features of GitLab. = _('Projects are where you store your code, access issues, wiki and other features of GitLab.')
- else - else
.blank-state .blank-state.gl-display-flex.gl-align-items-center.gl-border-1.gl-border-solid.gl-border-gray-100.gl-rounded-base.gl-mb-5
.blank-state-icon .blank-state-icon
= custom_icon("add_new_project", size: 50) = custom_icon("add_new_project", size: 50)
.blank-state-body .blank-state-body.gl-sm-pl-0.gl-pl-6
%h3.blank-state-title %h3.gl-font-size-h2.gl-mt-0
Create a project = _('Create a project')
%p.blank-state-text %p
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_group? - if current_user.can_create_group?
= link_to new_group_path, class: "blank-state blank-state-link" do = link_to new_group_path, class: link_classes do
.blank-state-icon .blank-state-icon
= custom_icon("add_new_group", size: 50) = custom_icon("add_new_group", size: 50)
.blank-state-body .blank-state-body.gl-sm-pl-0.gl-pl-6
%h3.blank-state-title %h3.gl-font-size-h2.gl-mt-0
Create a group = _('Create a group')
%p.blank-state-text %p
Groups are the best way to manage projects and members. = _('Groups are the best way to manage projects and members.')
= link_to trending_explore_projects_path, class: "blank-state blank-state-link" do = link_to trending_explore_projects_path, class: link_classes do
.blank-state-icon .blank-state-icon
= custom_icon("globe", size: 50) = custom_icon("globe", size: 50)
.blank-state-body .blank-state-body.gl-sm-pl-0.gl-pl-6
%h3.blank-state-title %h3.gl-font-size-h2.gl-mt-0
Explore public projects = _('Explore public projects')
%p.blank-state-text %p
Public projects are an easy way to allow = _('Public projects are an easy way to allow everyone to have read-only access.')
everyone to have read-only access.
= link_to "https://docs.gitlab.com/", class: "blank-state blank-state-link" do = link_to "https://docs.gitlab.com/", class: link_classes do
.blank-state-icon .blank-state-icon
= custom_icon("lightbulb", size: 50) = custom_icon("lightbulb", size: 50)
.blank-state-body .blank-state-body.gl-sm-pl-0.gl-pl-6
%h3.blank-state-title %h3.gl-font-size-h2.gl-mt-0
Learn more about GitLab = _('Learn more about GitLab')
%p.blank-state-text %p
Take a look at the documentation to discover all of GitLab's capabilities. = _('Take a look at the documentation to discover all of GitLab’s capabilities.')
.blank-state-parent-container .container
.section-container.section-welcome{ class: "#{ 'section-admin-welcome' if current_user.admin? }" } .gl-text-center.gl-pt-6.gl-pb-7
.container.section-body %h2.gl-font-size-h1{ data: { qa_selector: 'welcome_title_content' } }
.row
.blank-state-welcome.w-100
%h2.blank-state-welcome-title{ data: { qa_selector: 'welcome_title_content' } }
= _('Welcome to GitLab') = _('Welcome to GitLab')
%p.blank-state-text %p.gl-m-0
= _('Faster releases. Better code. Less pain.') = _('Faster releases. Better code. Less pain.')
- if current_user.admin? - if current_user.admin?
= render "blank_state_admin_welcome" = render "blank_state_admin_welcome"
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
- page_title _("Projects") - page_title _("Projects")
- header_title _("Projects"), dashboard_projects_path - header_title _("Projects"), dashboard_projects_path
- add_page_specific_style 'page_bundles/dashboard_projects'
= render "projects/last_push" = render "projects/last_push"
- if show_projects?(@projects, params) - if show_projects?(@projects, params)
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
.text-content .text-content
%h4.state-title %h4.state-title
= _("You don't have any deployments right now.") = _("You don't have any deployments right now.")
%p.blank-state-text %p
= html_escape(_("Define environments in the deploy stage(s) in %{code_open}.gitlab-ci.yml%{code_close} to track deployments here.")) % { code_open: '<code>'.html_safe, code_close: '</code>'.html_safe } = html_escape(_("Define environments in the deploy stage(s) in %{code_open}.gitlab-ci.yml%{code_close} to track deployments here.")) % { code_open: '<code>'.html_safe, code_close: '</code>'.html_safe }
.text-center .text-center
= link_to _("Read more"), help_page_path("ci/environments/index.md"), class: "gl-button btn btn-confirm" = link_to _("Read more"), help_page_path("ci/environments/index.md"), class: "gl-button btn btn-confirm"
......
...@@ -257,6 +257,7 @@ module Gitlab ...@@ -257,6 +257,7 @@ module Gitlab
config.assets.precompile << "page_bundles/build.css" config.assets.precompile << "page_bundles/build.css"
config.assets.precompile << "page_bundles/ci_status.css" config.assets.precompile << "page_bundles/ci_status.css"
config.assets.precompile << "page_bundles/cycle_analytics.css" config.assets.precompile << "page_bundles/cycle_analytics.css"
config.assets.precompile << "page_bundles/dashboard_projects.css"
config.assets.precompile << "page_bundles/dev_ops_reports.css" config.assets.precompile << "page_bundles/dev_ops_reports.css"
config.assets.precompile << "page_bundles/environments.css" config.assets.precompile << "page_bundles/environments.css"
config.assets.precompile << "page_bundles/epics.css" config.assets.precompile << "page_bundles/epics.css"
......
-# EE:Self Managed -# EE:Self Managed
.blank-state .blank-state.gl-display-flex.gl-align-items-center.gl-border-1.gl-border-solid.gl-border-gray-100.gl-rounded-base.gl-mb-5
.blank-state-icon .blank-state-icon
= image_tag("illustrations/lock_promotion.svg", { lazy: false }) = image_tag("illustrations/lock_promotion.svg", { lazy: false })
.blank-state-body .blank-state-body.gl-sm-pl-0.gl-pl-6
%h3.blank-state-title %h3.gl-font-size-h2.gl-mt-0
Unlock more features with GitLab Ultimate = _('Unlock more features with GitLab Ultimate')
%p.blank-state-text %p
GitLab is free to use. = _('GitLab is free to use. Many features for larger teams are part of our %{link_start}paid products%{link_end}. You can try Ultimate for free without any obligation or payment details.').html_safe % { link_start: '<a href="https://about.gitlab.com/pricing/">'.html_safe, link_end: '</a>'.html_safe }
Many features for larger teams are part of
our
= succeed "." do
= link_to "paid products", "https://about.gitlab.com/pricing/", target: "_blank", rel: "noopener noreferrer nofollow"
You can try Ultimate for free without
any obligation or payment details.
= link_to new_trial_url, class: "gl-button btn btn-success" do = link_to new_trial_url, class: "gl-button btn btn-success" do
Start free trial = _('Start free trial')
...@@ -2200,6 +2200,9 @@ msgstr "" ...@@ -2200,6 +2200,9 @@ msgstr ""
msgid "Add or subtract spent time" msgid "Add or subtract spent time"
msgstr "" msgstr ""
msgid "Add people"
msgstr ""
msgid "Add previously merged commits" msgid "Add previously merged commits"
msgstr "" msgstr ""
...@@ -2266,6 +2269,9 @@ msgstr "" ...@@ -2266,6 +2269,9 @@ msgstr ""
msgid "Add webhook" msgid "Add webhook"
msgstr "" msgstr ""
msgid "Add your team members and others to GitLab."
msgstr ""
msgid "Add/remove" msgid "Add/remove"
msgstr "" msgstr ""
...@@ -9099,6 +9105,9 @@ msgstr "" ...@@ -9099,6 +9105,9 @@ msgstr ""
msgid "Configure Dependency Scanning in `.gitlab-ci.yml`, creating this file if it does not already exist" msgid "Configure Dependency Scanning in `.gitlab-ci.yml`, creating this file if it does not already exist"
msgstr "" msgstr ""
msgid "Configure GitLab"
msgstr ""
msgid "Configure GitLab runners to start using the Web Terminal. %{helpStart}Learn more.%{helpEnd}" msgid "Configure GitLab runners to start using the Web Terminal. %{helpStart}Learn more.%{helpEnd}"
msgstr "" msgstr ""
...@@ -10089,6 +10098,9 @@ msgstr "" ...@@ -10089,6 +10098,9 @@ msgstr ""
msgid "Create a Mattermost team for this group" msgid "Create a Mattermost team for this group"
msgstr "" msgstr ""
msgid "Create a group"
msgstr ""
msgid "Create a merge request" msgid "Create a merge request"
msgstr "" msgstr ""
...@@ -10113,6 +10125,9 @@ msgstr "" ...@@ -10113,6 +10125,9 @@ msgstr ""
msgid "Create a personal access token on your account to pull or push via %{protocol}." msgid "Create a personal access token on your account to pull or push via %{protocol}."
msgstr "" msgstr ""
msgid "Create a project"
msgstr ""
msgid "Create an account using:" msgid "Create an account using:"
msgstr "" msgstr ""
...@@ -14605,6 +14620,9 @@ msgstr "" ...@@ -14605,6 +14620,9 @@ msgstr ""
msgid "Explore public groups" msgid "Explore public groups"
msgstr "" msgstr ""
msgid "Explore public projects"
msgstr ""
msgid "Explore snippets" msgid "Explore snippets"
msgstr "" msgstr ""
...@@ -16349,6 +16367,9 @@ msgstr "" ...@@ -16349,6 +16367,9 @@ msgstr ""
msgid "GitLab is a single application for the entire software development lifecycle. From project planning and source code management to CI/CD, monitoring, and security." msgid "GitLab is a single application for the entire software development lifecycle. From project planning and source code management to CI/CD, monitoring, and security."
msgstr "" msgstr ""
msgid "GitLab is free to use. Many features for larger teams are part of our %{link_start}paid products%{link_end}. You can try Ultimate for free without any obligation or payment details."
msgstr ""
msgid "GitLab is obtaining a Let's Encrypt SSL certificate for this domain. This process can take some time. Please try again later." msgid "GitLab is obtaining a Let's Encrypt SSL certificate for this domain. This process can take some time. Please try again later."
msgstr "" msgstr ""
...@@ -17459,6 +17480,12 @@ msgstr "" ...@@ -17459,6 +17480,12 @@ msgstr ""
msgid "Groups and subgroups" msgid "Groups and subgroups"
msgstr "" msgstr ""
msgid "Groups are a great way to organize projects and people."
msgstr ""
msgid "Groups are the best way to manage projects and members."
msgstr ""
msgid "Groups to synchronize" msgid "Groups to synchronize"
msgstr "" msgstr ""
...@@ -18138,6 +18165,9 @@ msgstr "" ...@@ -18138,6 +18165,9 @@ msgstr ""
msgid "If you add %{codeStart}needs%{codeEnd} to jobs in your pipeline you'll be able to view the %{codeStart}needs%{codeEnd} relationships between jobs in this tab as a %{linkStart}Directed Acyclic Graph (DAG)%{linkEnd}." msgid "If you add %{codeStart}needs%{codeEnd} to jobs in your pipeline you'll be able to view the %{codeStart}needs%{codeEnd} relationships between jobs in this tab as a %{linkStart}Directed Acyclic Graph (DAG)%{linkEnd}."
msgstr "" msgstr ""
msgid "If you are added to a project, it will be displayed here."
msgstr ""
msgid "If you did not initiate these sign-in attempts, please reach out to your administrator or enable two-factor authentication (2FA) on your account." msgid "If you did not initiate these sign-in attempts, please reach out to your administrator or enable two-factor authentication (2FA) on your account."
msgstr "" msgstr ""
...@@ -21169,6 +21199,9 @@ msgstr "" ...@@ -21169,6 +21199,9 @@ msgstr ""
msgid "Learn more about Auto DevOps" msgid "Learn more about Auto DevOps"
msgstr "" msgstr ""
msgid "Learn more about GitLab"
msgstr ""
msgid "Learn more about Needs relationships" msgid "Learn more about Needs relationships"
msgstr "" msgstr ""
...@@ -21846,6 +21879,9 @@ msgstr "" ...@@ -21846,6 +21879,9 @@ msgstr ""
msgid "Maintenance mode" msgid "Maintenance mode"
msgstr "" msgstr ""
msgid "Make adjustments to how your GitLab instance is set up."
msgstr ""
msgid "Make and review changes in the browser with the Web IDE" msgid "Make and review changes in the browser with the Web IDE"
msgstr "" msgstr ""
...@@ -28594,6 +28630,9 @@ msgstr "" ...@@ -28594,6 +28630,9 @@ msgstr ""
msgid "Projects are organized into groups" msgid "Projects are organized into groups"
msgstr "" msgstr ""
msgid "Projects are where you store your code, access issues, wiki and other features of GitLab."
msgstr ""
msgid "Projects contributed to" msgid "Projects contributed to"
msgstr "" msgstr ""
...@@ -29245,6 +29284,9 @@ msgstr "" ...@@ -29245,6 +29284,9 @@ msgstr ""
msgid "Public projects Minutes cost factor" msgid "Public projects Minutes cost factor"
msgstr "" msgstr ""
msgid "Public projects are an easy way to allow everyone to have read-only access."
msgstr ""
msgid "Publish to status page" msgid "Publish to status page"
msgstr "" msgstr ""
...@@ -34242,6 +34284,9 @@ msgstr "" ...@@ -34242,6 +34284,9 @@ msgstr ""
msgid "Start date" msgid "Start date"
msgstr "" msgstr ""
msgid "Start free trial"
msgstr ""
msgid "Start merge train" msgid "Start merge train"
msgstr "" msgstr ""
...@@ -35316,6 +35361,9 @@ msgstr "" ...@@ -35316,6 +35361,9 @@ msgstr ""
msgid "TagsPage|protected" msgid "TagsPage|protected"
msgstr "" msgstr ""
msgid "Take a look at the documentation to discover all of GitLab’s capabilities."
msgstr ""
msgid "Target Branch" msgid "Target Branch"
msgstr "" msgstr ""
...@@ -38488,6 +38536,9 @@ msgstr "" ...@@ -38488,6 +38536,9 @@ msgstr ""
msgid "Unlock account" msgid "Unlock account"
msgstr "" msgstr ""
msgid "Unlock more features with GitLab Ultimate"
msgstr ""
msgid "Unlock the discussion" msgid "Unlock the discussion"
msgstr "" msgstr ""
......
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