Updated: 1/26/2014
More Seven Theme issues: #1986434: New visual style for Seven
Problem/Motivation
TheStyle Guide for Seven aims to bring a stronger consistency to the Drupal admin interface, allowing contrib module UI components instead of writing their own custom CSS.
One common tool conveying information heirachy is proper use of headers. Web UIs are often limited on how they can use HTML header elements because they must respect the order of the DOM tree for accessibility reasons. This forces modules to write their own CSS to style the header elements. We aim to introduce several header CSS classes that are completely separated from the html elements.
Another tool for conveying heirachy is whitespace. It common for modules to have to write their own CSS to insert spacing between elements. We aim to introduce reuseable utility classes that applies vertical spacing consistency and inline with the base line height of the admin theme, improving vertical rhythm.
Proposed resolution/Demonstration
http://drupalcode.org/sandbox/ry5n/1932040.git/blob_plain/refs/heads/mas...
Remaining tasks
None
User interface changes
None
API changes
None
| Comment | File | Size | Author |
|---|---|---|---|
| #39 | admin-samplepage-withoutpatch.png | 21.84 KB | rootwork |
| #39 | admin-samplepage-withpatch.png | 21.62 KB | rootwork |
| #39 | admin-updates-withoutpatch.png | 38.26 KB | rootwork |
| #39 | admin-updates-withpatch.png | 38.31 KB | rootwork |
| #37 | drupal-seven-typography-styles-2028053-37.patch | 2.88 KB | thamas |
Comments
Comment #1
lewisnymanComment #2
frankbaele commentedComment #2.0
frankbaele commentedUpdated issue summary.
Comment #3
lewisnymanNo implementation yet, a good example would be applying
.header-fto table headers and summary/legend elements.Comment #5
rootworkUpdated #3, which no longer applied.
Additionally, because Drupal 8 isn't supporting IE8, I don't think we need the pixel fallbacks for rems, so I didn't include them.
There might be more we want to do, but I at least wanted to get this applying to HEAD.
Comment #6
rootworkTagging with the global sprint.
Comment #7
oheller commentedI'm going to review this patch.
Comment #8
oheller commentedI'm not sure how to test this. I've updated the summary to include the template and included some possible follow up actions.
Comment #11
rootwork5: drupal-seven-type-2028053-5.patch queued for re-testing.
Comment #13
rootworkI don't understand why changing some CSS definitions would cause this test to fail -- it appears to be testing whether the CSS stylesheets exist and are in the right place. Maybe someone else could take a look.
Comment #14
lewisnymanIf you add a new stylesheet to Seven you need to add it to the array in the test in ThemeHandlerTest.php. Around line 292.
Comment #15
internetdevels commentedHm, let's see...
Comment #16
rootworkAh, of course. Thanks.
Comment #17
lewisnymanThere isn't much wrong with this apart from missing the uppercase from header-c
This is a bit tricky because the font size changes were made with Source Sans in mind. Maybe we should keep the font sizes of h1,h2,h3 the same for now and just copy them over into the header-x classes?
Comment #18
lewisnymanComment #19
dcam commentedUpdating in preparation for DrupalCon Austin sprints. See http://www.hook42.com/blog/prepping-drupalcon-austin-sprints-sprint-lead....
#15 does not apply to HEAD and needs a reroll.
Comment #20
dcam commentedForgot the status, sorry.
Comment #21
vegantriathleteWorking on this to re-roll.
Comment #22
vegantriathletererolled patch attached
Comment #23
kbasarab commentedReroll looks good. Great work vegantriathlete. Only remaining issue is adding the text-transform: uppercase from #17.
Comment #24
vegantriathleteWill add changes as requested.
Comment #25
vegantriathleteNew patch and interdiff attached.
Comment #26
lewisnymanHey, just noticed that the h1 and h2 font size is the same.
These should be set to 21px and 1.3125rem for both
The h1,h2,h3 etc value should be identical to .header-a, .header-b, .header-c, etc values. It feels like we should just move them together into the same selectors instead of having to maintain the properties in two places.
I've updated the issue summary with all the places in Seven and system.admin.css that we could optimised with these classes. I'm not sure if it's a good idea to do it all in this issue but let's find out.
Comment #27
lewisnymanI've just remembered that we already do this for a/.link selectors in seven.base.css. We should follow the same procedure here.
Comment #28
franxo commentedI had a look at that issue and I don't fully understand what you mean in the first part of #2028053-26: Add typographic styles, components, and utility classes:
The h1 and h2 tags have different sizes: 1.25 and 1.125. I think that's correct. Is there any issue here?
Comment #29
franxo commentedI think I fixed all the remaining reported problems from the issue summary. This is my first contribution, so be benevolent :)
Let me know if there is something wrong.
Comment #30
rootworkfranxo, thanks for contributing!
I think this happened further upthread, but the pixel fallback values seem to have reappeared. As I said in #5, as D8 isn't supporting IE8, I don't think these values are necessary any longer, and they should be removed. Lewis, what do you think?
Comment #31
rootworkComment #32
lewisnymanThat is correct! it feels weird, but we should go rem only! Lets document this #2298015: [policy] Document when we should use each CSS unit
Let's remove the px values and then get some below/after screenshots just to make sure we haven't messed up the header sizes by mistake.
I'd rather we deleted the CSS here and then added the correct class through the php/theme function, same with the CSS on admin/appearance
Comment #33
lewisnymanLooks like #2298015: [policy] Document when we should use each CSS unit is put to bed, so we do want the px + rem values here.
Two more things to update:
In #2307533: Insufficient space at page bottom we're adding an 80px value to page bottom, can we add trailer/leader triple and quadruple classes so we can replace it with a reusable class?
I think we need to maintain the same font sizes that we had before, to remove any potential for visual regressions from this issue.
Comment #34
lewisnymanI think this issue has gotten stuck on the CSS units problem when we don't have to change the units to implement what we need, what if we just add the header-x classes next to the equivalent h1, h2, h3, etc selectors and ignore the units until we have a final decision?
Comment #35
thamasComment #36
thamasComment #37
thamasHere is a new patch with a smaller scope. Unfortunately I can't provide an interdiff file, because the old patch cant be applied anymore and I was not able to make patchutils work on my machine…
I'm going to add screenshots a little bit later…
Comment #38
thamasComment #39
rootworkI'm not sure what kind of screenshots would be most helpful here, but from what I can tell this doesn't change the look of anything (which is the idea).
I had trouble finding admin pages with any header elements other than the title, but here's the available updates page, without the patch and with the patch:
And here's a sample page, with the theme set to Seven, without and with the patch:
Thamas are you still working on this? If not we should unassign it for the sprints tomorrow.
Leaving screenshots needed tag in case there's something more we want to see.
Comment #40
rootworkUnassigning so others can work on reviewing this today.
Comment #41
lewisnymanThanks a lot for the screenshots! It would be great to get this in.
Comment #42
alexpottThe issue summary and the patch do not match. Either the patch needs work to address everything listed in the summary or we need to update the summary.
Comment #43
lewisnymanAh sorry Alex, I forgot to change the issue summary after simplifying the issue. Much better to start switching out classes in individual issues, so it's easier to test.
Comment #44
wim leerss/applies/apply/
s/inline/in line/
Comment #45
alexpottCommitted 93c6556 and pushed to 8.0.x. Thanks!
Fixed #44 on commit and also the spelling of reusable.