Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/admin/dashboard')
-rw-r--r--app/views/admin/dashboard/_security_newsletter_callout.html.haml10
-rw-r--r--app/views/admin/dashboard/index.html.haml48
2 files changed, 30 insertions, 28 deletions
diff --git a/app/views/admin/dashboard/_security_newsletter_callout.html.haml b/app/views/admin/dashboard/_security_newsletter_callout.html.haml
index 4b1303cc97c..76bfa347480 100644
--- a/app/views/admin/dashboard/_security_newsletter_callout.html.haml
+++ b/app/views/admin/dashboard/_security_newsletter_callout.html.haml
@@ -2,11 +2,11 @@
= render Pajamas::AlertComponent.new(variant: :tip,
title: s_('AdminArea|Get security updates from GitLab and stay up to date'),
- alert_class: 'js-security-newsletter-callout',
- alert_data: { feature_id: Users::CalloutsHelper::SECURITY_NEWSLETTER_CALLOUT,
- dismiss_endpoint: callouts_path,
- defer_links: 'true' },
- close_button_data: { testid: 'close-security-newsletter-callout' }) do |c|
+ alert_options: { class: 'js-security-newsletter-callout',
+ data: { feature_id: Users::CalloutsHelper::SECURITY_NEWSLETTER_CALLOUT,
+ dismiss_endpoint: callouts_path,
+ defer_links: 'true' }},
+ close_button_options: { data: { testid: 'close-security-newsletter-callout' }}) do |c|
= c.body do
= s_('AdminArea|Sign up for the GitLab Security Newsletter to get notified for security updates.')
= c.actions do
diff --git a/app/views/admin/dashboard/index.html.haml b/app/views/admin/dashboard/index.html.haml
index 69033d274a2..88fbbb28201 100644
--- a/app/views/admin/dashboard/index.html.haml
+++ b/app/views/admin/dashboard/index.html.haml
@@ -3,8 +3,8 @@
- billable_users_url = help_page_path('subscriptions/self_managed/index', anchor: 'billable-users')
- billable_users_link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer nofollow">'.html_safe % { url: billable_users_url }
-= render_if_exists 'shared/manual_renewal_banner'
= render_if_exists 'shared/manual_quarterly_reconciliation_banner'
+= render_if_exists 'shared/submit_license_usage_data_banner'
= render_if_exists 'shared/qrtly_reconciliation_alert'
= render 'admin/dashboard/security_newsletter_callout'
@@ -22,22 +22,24 @@
.admin-dashboard.gl-mt-3
.h3.gl-mb-5.gl-mt-0= _('Instance overview')
.row
+ - component_params = { body_options: { class: 'gl-display-flex gl-justify-content-space-between gl-align-items-center gl-p-6' },
+ footer_options: { class: 'gl-bg-transparent'} }
.col-md-4.gl-mb-6
- .gl-card
- .gl-card-body.d-flex.justify-content-between.align-items-center.gl-p-6
+ = render Pajamas::CardComponent.new(**component_params) do |c|
+ = c.body do
%span
.d-flex.align-items-center
= sprite_icon('project', size: 16, css_class: 'gl-text-gray-700')
%h3.gl-m-0.gl-ml-3= approximate_count_with_delimiters(@counts, Project)
.gl-mt-3.text-uppercase= s_('AdminArea|Projects')
= link_to(s_('AdminArea|New project'), new_project_path, class: "btn gl-button btn-default")
- .gl-card-footer.gl-bg-transparent
+ = c.footer do
.d-flex.align-items-center
= link_to(s_('AdminArea|View latest projects'), admin_projects_path)
- = sprite_icon('angle-right', size: 12, css_class: 'gl-text-gray-700 gl-ml-2')
+ = sprite_icon('chevron-right', size: 12, css_class: 'gl-text-gray-700 gl-ml-2')
.col-md-4.gl-mb-6
- .gl-card
- .gl-card-body.d-flex.justify-content-between.align-items-center.gl-p-6
+ = render Pajamas::CardComponent.new(**component_params) do |c|
+ = c.body do
%span
.d-flex.align-items-center
= sprite_icon('users', size: 16, css_class: 'gl-text-gray-700')
@@ -54,29 +56,29 @@
= s_('AdminArea|Users')
= link_to(s_('AdminArea|Users statistics'), admin_dashboard_stats_path, class: "text-capitalize gl-ml-2")
= link_to(s_('AdminArea|New user'), new_admin_user_path, class: "btn gl-button btn-default")
- .gl-card-footer.gl-bg-transparent
+ = c.footer do
.d-flex.align-items-center
= link_to(s_('AdminArea|View latest users'), admin_users_path)
- = sprite_icon('angle-right', size: 12, css_class: 'gl-text-gray-700 gl-ml-2')
+ = sprite_icon('chevron-right', size: 12, css_class: 'gl-text-gray-700 gl-ml-2')
.col-md-4.gl-mb-6
- .gl-card
- .gl-card-body.d-flex.justify-content-between.align-items-center.gl-p-6
+ = render Pajamas::CardComponent.new(**component_params) do |c|
+ = c.body do
%span
.d-flex.align-items-center
= sprite_icon('group', size: 16, css_class: 'gl-text-gray-700')
%h3.gl-m-0.gl-ml-3= approximate_count_with_delimiters(@counts, Group)
.gl-mt-3.text-uppercase= s_('AdminArea|Groups')
= link_to(s_('AdminArea|New group'), new_admin_group_path, class: "btn gl-button btn-default")
- .gl-card-footer.gl-bg-transparent
+ = c.footer do
.d-flex.align-items-center
= link_to(s_('AdminArea|View latest groups'), admin_groups_path)
- = sprite_icon('angle-right', size: 12, css_class: 'gl-text-gray-700 gl-ml-2')
+ = sprite_icon('chevron-right', size: 12, css_class: 'gl-text-gray-700 gl-ml-2')
.row
.col-md-4.gl-mb-6
#js-admin-statistics-container
.col-md-4.gl-mb-6
- .gl-card
- .gl-card-body
+ = render Pajamas::CardComponent.new do |c|
+ = c.body do
%h4= s_('AdminArea|Features')
= feature_entry(_('Sign up'),
href: general_admin_application_settings_path(anchor: 'js-signup-settings'),
@@ -114,8 +116,8 @@
href: admin_runners_path,
enabled: Gitlab.config.gitlab_ci.shared_runners_enabled)
.col-md-4.gl-mb-6
- .gl-card
- .gl-card-body
+ = render Pajamas::CardComponent.new do |c|
+ = c.body do
%h4
= s_('AdminArea|Components')
- if show_version_check?
@@ -171,8 +173,8 @@
= link_to _("Gitaly Servers"), admin_gitaly_servers_path
.row
.col-md-4.gl-mb-6
- .gl-card
- .gl-card-body
+ = render Pajamas::CardComponent.new do |c|
+ = c.body do
%h4= s_('AdminArea|Latest projects')
- @projects.each do |project|
.gl-display-flex.gl-py-3
@@ -181,8 +183,8 @@
%span.gl-white-space-nowrap.gl-text-right
#{time_ago_with_tooltip(project.created_at)}
.col-md-4.gl-mb-6
- .gl-card
- .gl-card-body
+ = render Pajamas::CardComponent.new do |c|
+ = c.body do
%h4= s_('AdminArea|Latest users')
- @users.each do |user|
.gl-display-flex.gl-py-3
@@ -192,8 +194,8 @@
%span.gl-white-space-nowrap.gl-text-right
#{time_ago_with_tooltip(user.created_at)}
.col-md-4.gl-mb-6
- .gl-card
- .gl-card-body
+ = render Pajamas::CardComponent.new do |c|
+ = c.body do
%h4= s_('AdminArea|Latest groups')
- @groups.each do |group|
.gl-display-flex.gl-py-3