Problem/Motivation
Using ID selectors as styling hooks are bad practice according to our CSS coding standards. We should use classes.
As mentioned in #2321121-13: Remove #console we have some id-s in page.html.twig such as #branding, #content, #help, #footer and some styling applied in the related css files to #branding and #help.
Proposed resolution
We should switch from id-s to class-es both in twig and in the related css files.
Branding is managed in #2337379: Rename 'branding' to 'content-header' but we have three other id-s
Remaining tasks
Wait until we get #2307533: Insufficient space at page bottom in.
Contributor tasks needed
| Task |
Novice task? |
Contributor instructions |
Complete? |
| Create a patch |
|
Instructions |
Complete |
| Manually test the patch |
Novice |
Instructions |
|
| Embed before and after screenshots in the issue summary |
Novice |
Instructions |
|
User interface changes
None
API changes
None
Comments
Comment #1
thamasComment #2
thamasComment #3
rpayanmComment #4
rpayanmComment #5
Palashvijay4O commentedsubmitting a patch .
Comment #6
rpayanm@Palashvijay4
Here:
and here:
There is two instance of class.
Comment #7
Palashvijay4O commentedSome minor changes as shown to me by @rpayanm . Thank you
Comment #8
thamasComment #9
thamasComment #10
Palashvijay4O commented@thamas : Do we need to post the screenshot of home page before and after we apply the patch ?
Comment #11
sqndr commented@Palashvijay4: Yes. That would be great. Please also tell which browser the screenshots are from, and make sure to test in multiple browsers. Screenshots from one browser is fine though.
Comment #12
Palashvijay4O commentedScreenshots as taken in Chrome and Firefox respectively.
Comment #13
lewisnymanI made a quick sanity check to make sure we didn't break anything. Everything seems good!
Comment #14
alexpottAre we sure we want to change
#contentto.content? This will break #2307533: Insufficient space at page bottomComment #15
rpayanm@alexpott here I fix that ;)
Comment #16
lewisnymanAh yes, unfortunately we are still using the .content class in blocks and comments. I guess we should change .content into .page-content so it's more specific.
Comment #17
rpayanm@LewisNyman here the patch :)
Comment #18
lewisnymanExcellent thanks. I manually tested the patch just to make sure.
Comment #19
alexpottCommitted 17461de and pushed to 8.0.x. Thanks!
Comment #22
rpayanm