Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Sub-issue of #1190252: [573] Use csslint as a weapon to beat the crappy CSS out of Drupal core
Inline with the CSS cleanup efforts of the HTML5 initiative, using CSSLint at http://csslint.net provides a quick way to code-sniff our css and tweak styles.
- Copy and paste the the stylesheet(s) below into the css lint tool at http://csslint.net and test.
- Fix any warnings or errors the tool finds.
- Patch Drupal 8 locally and make sure the css changes have not broken anything visually.
- Create patch and upload for the testbot.
Files: modules/field/theme/field.css (and field-rtl.css)
Comment | File | Size | Author |
---|---|---|---|
#8 | field-css-clean-up-1662976-8.patch | 1.12 KB | mjonesdinero |
#4 | field-css-clean-up-1662976.patch | 1002 bytes | mjonesdinero |
#2 | field-css-clean-up-1662976.patch | 555 bytes | mjonesdinero |
Comments
Comment #1
ZenDoodles CreditAttribution: ZenDoodles commentedComment #2
mjonesdinero CreditAttribution: mjonesdinero commentedtest in http://csslint.net found two warnings attach is the patch i have created and tested locally, nothing was broken.
Comment #3
mjonesdinero CreditAttribution: mjonesdinero commentedopsss ignore the patch attach, i attached a wrong patch it is for the file..sorry with that
Comment #4
mjonesdinero CreditAttribution: mjonesdinero commentedhere is the latest file.. the first one is a mistake..
found out two warnings one on each css files
Comment #5
droplet CreditAttribution: droplet commentedcsslint should warning this too
Comment #6
mjonesdinero CreditAttribution: mjonesdinero commentedbut css lint give me a no warning on this..
Comment #7
droplet CreditAttribution: droplet commentedDisallow overqualified elements Element (td.field-multiple-drag) is overqualified, just use .field-multiple-drag without element name.
form .field-multiple-table td.field-multiple-drag .tabledrag-handl
Comment #8
mjonesdinero CreditAttribution: mjonesdinero commentedsorry about that droplet.. attach updated patch now..
Comment #9
droplet CreditAttribution: droplet commentedThanks.
For this issue purpose it is enough. But we can also remove starting "form". If we want to tell its inside a form. I'd suggest ".form-item" or ".form-wrapper"
Comment #10
barraponto CreditAttribution: barraponto commentedWhat about .tabledrag-processed? I mean, these styles are only meant for when there's javascript enabled.
Comment #11
barraponto CreditAttribution: barraponto commentedAnyway, that's enough for this issue. We should probably create a new issue on unifying tabledrag css.
Comment #12
catchCommitted/pushed to 8.x, thanks!