Problem/Motivation

#665790: Redesign the status report page cleaned up the visual output of the Status report page (and the requirements page in the Drupal installer).

Briefly discussing this with @jacine, it turns out that:

  • We should use TH elements instead of TD.status-title.
  • The icon can possibly be merged into the heading column by using some more fancy CSS (which ensures that a heading [which doesn't fit into the cell and wraps] continues below the heading instead of below the icon).
  • It's debatable whether Stark should contain the base styling that ensures a sane width for the heading column and also the background on the heading column. The switch to TH might make this obsolete (for Stark).

Potentially more.

Proposed resolution

Remaining tasks

Contributor tasks needed
Task Novice task? Contributor instructions Complete?
Embed before and after screenshots in the issue summary Novice Instructions Yes
Review patch to ensure that it fixes the issue, stays within scope, is properly documented, and follows coding standards Instructions Tes

User interface changes

None

API changes

None

Beta phase evaluation

Reference: https://www.drupal.org/core/beta-changes
Issue category Task because coding standards
Issue priority Not critical because coding standards
Unfrozen changes Unfrozen because it only changes CSS and markup

CommentFileSizeAuthor
#71 Screenshot 2015-09-10 12.37.14.jpg681.43 KBLewisNyman
#69 interdiff-1591744-63-69.txt749 bytesmansspams
#69 clean_up_css_and_markup-1591744-69.patch3.52 KBmansspams
#63 Screenshot#63.png129.26 KBpguillard
#63 interdiff-1591744-61-63.txt1.32 KBpguillard
#63 clean_up_css_and_markup-1591744-63.patch3.5 KBpguillard
#61 interdiff-1591744-56-61.txt1.63 KBrudraram
#61 clean_up_css_and_markup-1591744-61.patch3.5 KBrudraram
#58 Screen Shot 2015-08-30 at 12.25.34 pm.png229.46 KBrudraram
#58 interdiff-1591744-56-58.txt1.63 KBrudraram
#58 clean_up_css_and_markup-1591744-58.patch1.63 KBrudraram
#56 screenshoit-1591744-after.png106.62 KBpguillard
#56 interdiiff-1591744-50-56.txt1.19 KBpguillard
#56 clean_up_css_and_markup-1591744-56.patch3.48 KBpguillard
#51 Screen Shot 2015-08-01 at 20.20.24.png150.42 KBlauriii
#51 Screen Shot 2015-08-01 at 20.20.21.png161.31 KBlauriii
#50 clean_up_css_and_markup-1591744-50.patch3.48 KBLewisNyman
#50 interdiff.txt1.88 KBLewisNyman
#46 before-patch.png69.28 KBcchanana
#46 after-patch.png54.87 KBcchanana
#44 clean_up_css_and_markup-1591744-44.patch3.6 KBpguillard
#42 Screen Shot 2015-06-10 at 20.57.28.png3.06 MBMathieuSpil
#42 Screen Shot 2015-06-10 at 20.57.57.png3.07 MBMathieuSpil
#42 Screen Shot 2015-06-10 at 20.59.44.png663.66 KBMathieuSpil
#42 Screen Shot 2015-06-10 at 20.58.53.png674.93 KBMathieuSpil
#42 clean_up_css_and_markup-1591744-42.patch3.68 KBMathieuSpil
#42 interdiff-1591744-32-42.txt1.97 KBMathieuSpil
#38 status report - rtl.png310.17 KBMathieuSpil
#36 interdiff-1591744-32-34.txt407 bytesMathieuSpil
#34 clean_up_css_and_markup-1591744-34.patch3.57 KBManjit.Singh
#33 Screenshot 2015-06-05 15.02.06.jpg585.59 KBLewisNyman
#32 interdiff-1591744-29-32.txt2.91 KBMathieuSpil
#32 clean_up_css_and_markup-1591744-32.patch3.59 KBMathieuSpil
#29 interdiff-1591744-25-29.txt2.77 KBMathieuSpil
#29 clean_up_css_and_markup-1591744-29.patch3.44 KBMathieuSpil
#26 status report RTL.png342.1 KBDeeLay
#26 status report.png340.79 KBDeeLay
#25 interdiff-1591744-20-25-do-not-test.diff472 bytesDeeLay
#25 clean_up_css_and_markup-1591744-25.patch2.7 KBDeeLay
#20 status-report-css-1591744-20.patch2.71 KBMathieuSpil
#17 system.admin_.css_.txt765 bytesLewisNyman
#15 sc.jpg379.43 KBAleksandar_P
#11 status-report-css-1591744-11.patch3.24 KBAleksandar_P
#4 1591744-status_report.patch3.23 KBdroplet
#4 bartik.png79.8 KBdroplet
#4 seven.png81.35 KBdroplet
#4 stark.png112.21 KBdroplet
#2 status_report-do-not-test.patch12.78 KBdroplet
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Jacine’s picture

Issue tags: -html5

In an effort to get a better picture of issues remaining in the HTML5 Initiative, we're removing issues that are not directly HTML5-related. Note: Any issues assigned to the "Markup, CSS and JavaScript" components will still be broadcast on the HTML5 Twitter feed so that interested parties can participate. It might be more accurate to put this in the Markup component. I'll leave that up to you. :)

droplet’s picture

Assigned: Unassigned » droplet
Status: Active » Needs work
FileSize
12.78 KB

No reviews please :) I will reroll it after related issue got committed.

Also seems like I can downgrade this patch to D7 now: #1001932: Clean up Status report CSS (and IE fix)

sun’s picture

droplet’s picture

Status: Needs work » Needs review
FileSize
112.21 KB
81.35 KB
79.8 KB
3.23 KB
droplet’s picture

myself expatiation and further suggestions :)

+++ b/core/modules/system/system.admin.cssundefined
@@ -97,30 +97,35 @@ a.module-link-configure {
-  background-color: rgba(0, 0, 0, 0.04);

remove bg color in stark theme

+++ b/core/modules/system/system.admin.cssundefined
@@ -97,30 +97,35 @@ a.module-link-configure {
+  border-bottom: none;

created an issue to see if it possible to get rid of border from global.
#1601196: remove TH border from base.css

+++ b/core/themes/seven/style.cssundefined
@@ -500,18 +500,18 @@ table tr.selected td {
+.system-status-report tr.ok {
...
+.system-status-report tr.warning {
...
+.system-status-report tr.error {

I preferred to remove TR. looking for your comments.

Also, there's one good thing I suggested in #1001932: Clean up Status report CSS (and IE fix) to optimize table rendering performance. (Maybe a new issue to apply it to all possible tables in Drupal)

+table.system-status-report{
+  table-layout: fixed;
+}

ref:
http://msdn.microsoft.com/en-us/library/ie/ms531161(v=vs.85).aspx

sun’s picture

Status: Needs review » Needs work

@droplet: Your explanations in #5 are way too sparse for someone like me. ;) It also seems like you forgot to link to that new issue to "get rid of border from global" (whatever that means ;)).

Also, you didn't actually implement any of the suggestions from the OP, or did I miss something? :P ;)

droplet’s picture

no ? or anything I'm missing too ?

We should use TH elements instead of TD.status-title.

It's using TH now

The icon can possibly be merged into the heading column by using some more fancy CSS (which ensures that a heading [which doesn't fit into the cell and wraps] continues below the heading instead of below the icon).

Usability issue, "CSS only" isn't the good way. But I merged it into one column

It's debatable whether Stark should contain the base styling that ensures a sane width for the heading column and also the background on the heading column. The switch to TH might make this obsolete (for Stark).

some css fixes.

mgifford’s picture

Issue summary: View changes
Related issues: +#665790: Redesign the status report page

Just adding a related issue.

droplet’s picture

Assigned: droplet » Unassigned
YesCT’s picture

Issue tags: -Front end +frontend

correcting the tag to the more common one.

Aleksandar_P’s picture

Icon is merged into the heading column, and the heading is continuing under heading instead of under the icon.

Aleksandar_P’s picture

Status: Needs work » Needs review
YesCT’s picture

Issue summary: View changes
Issue tags: -#frontend +Needs screenshots
YesCT’s picture

Issue summary: View changes
Aleksandar_P’s picture

FileSize
379.43 KB

Here is the requested screenshot.

mgifford’s picture

Issue tags: -Needs screenshots

Removing tag. Adding image provided by @Aleksandar_P

LewisNyman’s picture

Status: Needs review » Needs work
Issue tags: -css3, -TX (Themer Experience) +CSS
FileSize
765 bytes

This patch is very out of date. I think it's better to start again and see what we can improve. I've uploaded the CSS so it can be reviewed in Dreditor

LewisNyman’s picture

  1. .system-status-report td {
    ...
    .system-status-report .status-icon {
    ...
    [dir="rtl"] .system-status-report .status-icon {
    ...
    .system-status-report .status-icon div {
    ...
    .system-status-report .error .status-icon div {
    ...
    .system-status-report .warning .status-icon div {
    ...
    .system-status-report .status-title {
    

    We need to SMACSS up these classes, see: https://www.drupal.org/node/2408617

  2. .system-status-report td:nth-child(-n+2) {
      background-color: rgba(0, 0, 0, 0.04);
    }
    

    I think we can remove this styling because it is overidden by Seven's table.css. Can we also remove the override in Seven here?

MathieuSpil’s picture

Assigned: Unassigned » MathieuSpil

Looking into this, what of the old changes we can still implement and if the smacss'ing should be in a follow-up ticket for clarity purposes...

MathieuSpil’s picture

Issue tags: +Screenshot
FileSize
2.71 KB

As expected, the last patch (#11) no longer applied, so I re-implemented all the needed changes following the new semantics (so no interdiff needed).

So merged the first 2 td's in one th as suggested, and adjusted the css accordingly. (What will we need for RTL?)

The smacss'ing up of the css has apparently been solved in another ticket? The only thing I should change is the div with class description, but I am not sure if this is something we use frequently?

Please review! (The use of th now causes a font-weight bold, but not really a fan of resetting this to a normal font weight because it looks better..)

MathieuSpil’s picture

Assigned: MathieuSpil » Unassigned
MathieuSpil’s picture

Status: Needs work » Needs review
Issue tags: -Screenshot +Needs screenshots
LewisNyman’s picture

Status: Needs review » Needs work

This is looking good, but now we have a row of <th>'s and a column of <th>'s. Is that valid markup? I ran it through the W3C markup validator and it did complain a little:

A table row was 2 columns wide, which is less than the column count established by the first row (3).

  1. +++ b/core/modules/system/css/system.admin.css
    @@ -188,24 +188,27 @@ small .admin-link:after {
    -.system-status-report td {
    +.system-status-report th {
    

    Can we create a class to apply this to the correct cells instead of the th elements?

  2. +++ b/core/modules/system/css/system.admin.css
    @@ -188,24 +188,27 @@ small .admin-link:after {
    +  /*
    +  padding-right: 0;
    +  padding-left: 6px;
    +  */
    

    These properties are commented out

DeeLay’s picture

I'm at DrupalCon LA and I can update the patch to reinstate the commented out code

DeeLay’s picture

The .admin-link css wasn't added in this patch, so I'm guessing best to create a new issue for that?

Un-commented out the rtl css lines and checked the pages look good in LTR and RTL. Attaching new patch and interdiff

DeeLay’s picture

FileSize
340.79 KB
342.1 KB

Adding screenshots

LewisNyman’s picture

Status: Needs work » Needs review
droplet’s picture

1 suggestion:
- Adding a class to right column (td)

MathieuSpil’s picture

Apparently, the status report-page is the only page that uses hidden headers as the only thead, so we should remove it's <thead>-tag. or not hide it.
I am keen on removing it because the table itself speaks for itself and the labels in the thead don't add anything for anyone in any situation I can think of.

@Lewis: the error the W3C-validator threw was because we had 3 table-elements inside a tr inside the thead and we had 2 table-elements inside a tr inside the tbody.
So the easy fix would be to remove the this: <th>{{ 'Status'|t }}</th>

But the better solution for me would be to remove the thead altogether and therefor the tbody-tag is also no longer needed. (the th-elements provide more than enough context & information)

Extras:
1) The RTL-styling was in comments because I wasn't sure how this should be on rtl-installs, but the screenshots made this more clear.

2) I was bothered by the fact that tr's without icons also had padding for the icon, so I fixed this. => This causes some wanted visual changes, so any opniion on this would be great.

3) Added a extra if statement to status-report.html.twig so the div with the status information is not printed for th's that don't need it.

4) @Droplet, wasn't sure why we should add a class on the td?

LewisNyman’s picture

Ok cool, this is looking good. I'm not sure what the effects of removing the th's will have on screenreaders, so tagging this for accessibility review.

+++ b/core/modules/system/templates/status-report.html.twig
@@ -18,24 +18,20 @@
+      <tr class="system-status-report__entry system-status-report__entry--colored color-{{ requirement.severity_status }}">

I wonder if there is another class we could use instead of colored? I know that there is a color class being added but it would nice to keep the other classes logical, instead of presentational.

LewisNyman’s picture

Status: Needs review » Needs work
MathieuSpil’s picture

Status: Needs work » Needs review
Issue tags: +Needs accessibility review
FileSize
3.59 KB
2.91 KB

@LewisNyman not really sure if this is the tag you wanted?

Every <tr> now has the classes: system-status-report__entry--{{ requirement.severity_status }} This way, the classes are more consistent and more readable. The tr with the class system-status-report__entry--info is now the exception instead of the other 2 posiibilities in warnings.

Adjusted the css so nothing visually changes in comparison with last patch.

The interdiff is a bit chaotic because of tab-indents being altered :)

LewisNyman’s picture

Issue summary: View changes
Status: Needs review » Needs work
Issue tags: -Needs screenshots
FileSize
585.59 KB

Ok thanks. This looks great I found one suggestion:

+++ b/core/modules/system/css/system.admin.css
@@ -188,24 +188,32 @@ small .admin-link:after {
+  padding: 10px 6px 10px 40px; /* LTR */
...
+[dir="rtl"] .system-status-report__status-title {
+  padding-left: 6px;
+  padding-right: 40px;

If we just set padding-left here then we don't have to override the vertical padding, which is nice.

Screenshot and bet eval added. I'll ping someone who can review the accessibility.

Manjit.Singh’s picture

Status: Needs work » Needs review
Issue tags: +SrijanSprintNight
FileSize
3.57 KB
RavindraSingh’s picture

Status: Needs review » Reviewed & tested by the community

Good Work all, #34 looks good.
it is removing + padding-right: 40px; as it was suggested by @LewisNyman
Moving this to RTBC as of now.

MathieuSpil’s picture

Status: Reviewed & tested by the community » Needs review
FileSize
407 bytes

Supplied a interdiff for #34.
This will still need some accessibility-review before it can go on rtbc.

idebr’s picture

Status: Needs review » Needs work
+++ b/core/modules/system/css/system.admin.css
@@ -188,24 +188,31 @@ small .admin-link:after {
+  padding: 10px 6px 10px 40px; /* LTR */
...
+[dir="rtl"] .system-status-report__status-title {
+  padding-left: 6px;
 }

The padding-left is not applied for RTL. This results in the icon being displayed op top of the title.

Re: #35

it is removing + padding-right: 40px; as it was suggested by @LewisNyman
Moving this to RTBC as of now.

Lewis was suggesting only styling the padding-left instead of all the padding. The padding-right still needs to be applied for RTL.

MathieuSpil’s picture

Status: Needs work » Needs review
FileSize
310.17 KB

@LewisNyman:
Not sure why you suggested to not override padding-right on RTL?
As screenshot shows, the padding stays necessary:

So everything inside #32 Is ok and there should the accessibility review should happen?

MathieuSpil’s picture

Extra: is the same interface being used on the install guide of Drupal? If so, it would be great if we can have some screenshots on those install pages, so we are sure everything looks ok there.

LewisNyman’s picture

Status: Needs review » Needs work
Issue tags: +Needs screenshots

Not sure why you suggested to not override padding-right on RTL?
As screenshot shows, the padding stays necessary:

@MathieuSpil We should override the padding on RTL. I guess I worded it badly.

+.system-status-report__status-title {
...
+  padding: 10px 6px 10px 40px; /* LTR */
 }

We only need to set padding-left here, we don't need to set padding on the right, top, and bottom.

is the same interface being used on the install guide of Drupal? If so, it would be great if we can have some screenshots on those install pages, so we are sure everything looks ok there.

Ah good point, we should.

MathieuSpil’s picture

Assigned: Unassigned » MathieuSpil
MathieuSpil’s picture

Updated css based upon #32, so it now only overrides padding-left on LTR and padding-right on RTL.

Tested it on the install steps, and it broke indeed.
I assumes there were 3 possible classes of the tr's:
- .system-status-report__status-icon--error => red
- .system-status-report__status-icon--warning => yellow
- .system-status-report__status-icon--error => default
But appareantly there is one more:
- .system-status-report__status-icon--ok => only used on the install pages as far as I can see.
As defined in:

/**
 * Prepares variables for status report template.
 *
 * Default template: status-report.html.twig.
 *
 * This theme function is dependent on install.inc being loaded, because
 * that's where the constants are defined.
 *
 * @param $variables
 *   An associative array containing:
 *   - requirements: An array of requirements/status items. Each requirement
 *     is an associative array containing the following elements:
 *     - title: The name of the requirement.
 *     - value: (optional) The current value (version, time, level, etc).
 *     - description: (optional) The description of the requirement.
 *     - severity: (optional) The requirement's result/severity level, one of:
 *       - REQUIREMENT_INFO: Status information.
 *       - REQUIREMENT_OK: The requirement is satisfied.
 *       - REQUIREMENT_WARNING: The requirement failed with a warning.
 *       - REQUIREMENT_ERROR: The requirement failed with an error.
 */
function template_preprocess_status_report(&$variables) {
  $severities = array(
    REQUIREMENT_INFO => array(
      'title' => t('Info'),
      'status' => 'info',
    ),
    REQUIREMENT_OK => array(
      'title' => t('OK'),
      'status' => 'ok',
    ),
    REQUIREMENT_WARNING => array(
      'title' => t('Warning'),
      'status' => 'warning',
    ),
    REQUIREMENT_ERROR => array(
      'title' => t('Error'),
      'status' => 'error',
    ),
  );

  foreach ($variables['requirements'] as $i => $requirement) {
    // Always use the explicit requirement severity, if defined. Otherwise,
    // default to REQUIREMENT_OK in the installer to visually confirm that
    // installation requirements are met. And default to REQUIREMENT_INFO to
    // denote neutral information without special visualization.
    if (isset($requirement['severity'])) {
      $severity = $severities[(int) $requirement['severity']];
    }
    elseif (defined('MAINTENANCE_MODE') && MAINTENANCE_MODE == 'install') {
      $severity = $severities[REQUIREMENT_OK];
    }
    else {
      $severity = $severities[REQUIREMENT_INFO];
    }
    $variables['requirements'][$i]['severity_title'] = $severity['title'];
    $variables['requirements'][$i]['severity_status'] = $severity['status'];
  }
}

So tweaked the patch so now the warning and error are the exception. => CSS looks now more logical, while the twig looks a bit more complex (moved the if-statement one line higher)

After that took some screenshots, who do we address for accessibility?

LewisNyman’s picture

Status: Needs review » Needs work
Issue tags: +Needs reroll

Ah sorry. Needs a reroll

pguillard’s picture

Status: Needs work » Needs review
FileSize
3.6 KB

Just rerolled patch #42

cchanana’s picture

Assigned: Unassigned » cchanana
cchanana’s picture

Assigned: cchanana » Unassigned
FileSize
54.87 KB
69.28 KB

After applying patch, design is looking same. Please find the attach below and after patch screenshots.

googletorp’s picture

Issue summary: View changes
Issue tags: -Needs reroll
googletorp’s picture

Issue summary: View changes
Status: Needs review » Reviewed & tested by the community

This patch looks good to me. Since it only changes CSS and HTML it's an unfrozen change, so should be fine for beta.

Before and after pics located in #46

alexpott’s picture

Status: Reviewed & tested by the community » Needs work
+++ b/core/modules/system/templates/status-report.html.twig
@@ -18,29 +18,25 @@
+      {% if requirement.severity_status in ['warning', 'error'] %}

I don't think this if is the way to go here. The whole --has-icon looks like something we could do without.

LewisNyman’s picture

Nice! Alex is right, we can just add icon classes to the th. One less div! I removed the requirement for the accessibiltiy review because the elements used haven't changed.

lauriii’s picture

Is this visual change approved?

Before:

After:

LewisNyman’s picture

Status: Needs review » Needs work
pguillard’s picture

@LewisNyman : What is the remaining work to do, as you pushed Needs Work ?

pguillard’s picture

Status: Needs work » Needs review

I don't see any visual change, so I try Needs Review again

LewisNyman’s picture

Status: Needs review » Needs work

@pguillard Sorry, the first column of the messages when warning or error are now bold, they weren't bold before. We shouldn't make any visual changes in this issue.

pguillard’s picture

Thanks @LewisNyman
I replaced back <th> with the original <td>

LewisNyman’s picture

Status: Needs review » Needs work

@pguillard Thanks, I think we're close with this. I think we need to keep the <th> for accessibility reasons. Is there a way we could just style the th so it doesn't include the bold styling?

rudraram’s picture

@LewisNyman Just re-rolled #56 as per your suggestion. Please see if that is correct. Attaching screenshot.

1591744-58

rudraram’s picture

Status: Needs work » Needs review

Status: Needs review » Needs work

The last submitted patch, 58: clean_up_css_and_markup-1591744-58.patch, failed testing.

rudraram’s picture

Ohk. My patch in #58 didn't capture everything properly. I updated the patch. Apologies for that. Screenshot remains the same as #58 though.

rudraram’s picture

Status: Needs work » Needs review
pguillard’s picture

Checking #61 in order to set it to RTBC, I discovered the patch was not applying anymore, just rerolled it.
Screenshot remains the same as #58.

LewisNyman’s picture

Status: Needs review » Reviewed & tested by the community

Great, thanks.

alexpott’s picture

Status: Reviewed & tested by the community » Needs work

The alignment of the text and icons has changed - the icons used to be in a "column" of their own.

alexpott’s picture

To see what I mean look at #51 thanks @lauriii and @emma

mansspams’s picture

Assigned: Unassigned » mansspams

Ok, will do.

emma.maria’s picture

I can help to visually test the solution when it is ready also :-)

mansspams’s picture

mansspams’s picture

Status: Needs work » Needs review
LewisNyman’s picture

Assigned: mansspams » Unassigned
Issue summary: View changes
Status: Needs review » Reviewed & tested by the community
FileSize
681.43 KB

Thanks, this looks better.

alexpott’s picture

+++ b/core/modules/system/css/system.admin.css
@@ -192,16 +192,12 @@ small .admin-link:after {
+  padding: 10px 6px 10px 40px;

Needs LTR thingy. Will add on commit.

mansspams’s picture

There is one already.

alexpott’s picture

Status: Reviewed & tested by the community » Fixed

CSS and Twig only - permitted in beta. Committed eb6330d and pushed to 8.0.x. Thanks!

@mansspams this is what I meant...

diff --git a/core/modules/system/css/system.admin.css b/core/modules/system/css/system.admin.css
index db8bb09..b01e405 100644
--- a/core/modules/system/css/system.admin.css
+++ b/core/modules/system/css/system.admin.css
@@ -192,7 +192,7 @@ small .admin-link:after {
   position: relative;
   vertical-align: top;
   width: 25%;
-  padding: 10px 6px 10px 40px;
+  padding: 10px 6px 10px 40px; /* LTR */
   box-sizing: border-box;
   font-weight: normal;
 }

Fixed on commit.

  • alexpott committed eb6330d on 8.0.x
    Issue #1591744 by MathieuSpil, pguillard, droplet, rudraram, DeeLay,...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.