Skip to content

Migrate admin emails to Pajamas ViewComponent

What does this MR do and why?

Migrate admin emails to Pajamas ViewComponent

Related to Migrate to Pajamas::AlertComponent ViewComponen... (#325396 - closed)

Screenshots or screen recordings

Before After
image image

Snapshot before

<div class="gl-alert gl-alert-danger" role="alert">
  <svg class="s16 gl-icon s16 gl-alert-icon gl-alert-icon-no-title" data-testid="warning-icon"><use href="/assets/icons-f305926186cfc3bb530f27269d545937c385578ba62adb0088d74f0d2d02cb56.svg#warning"></use></svg>
  <div class="gl-alert-body">
    Some error
  </div>
</div>

Snapshot after

<div class="gl-alert gl-alert-danger gl-alert-not-dismissible" role="alert">
  <svg class="s16 gl-alert-icon gl-alert-icon-no-title" data-testid="error-icon"><use href="/assets/icons-f305926186cfc3bb530f27269d545937c385578ba62adb0088d74f0d2d02cb56.svg#error"></use></svg>
  <div class="gl-alert-content" role="alert">
    <div class="gl-alert-body">
      Some error

    </div>
  </div>
</div>

How to set up and validate locally

To make this work without extensive setup

  1. On an EE instance
  2. Go to http://gdk.test:3000/admin/email
  3. (Add a license in case step 2 doesn't work)
+ if true # admin_emails_are_currently_rate_limited?
..
+      = 'Some error' #admin_emails_rate_limited_alert

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Alper Akgun

Merge request reports