Make WordPress Core

Opened 5 years ago

Closed 5 years ago

#46493 closed defect (bug) (fixed)

CSS line-height values should be unitless - common.css

Reported by: ianbelanger's profile ianbelanger Owned by: ianbelanger's profile ianbelanger
Milestone: 5.2 Priority: normal
Severity: normal Version:
Component: General Keywords: has-patch commit
Focuses: ui, administration, coding-standards Cc:


As outlined in #44643, CSS line-height values should be unitless unless necessary to be defined as a specific pixel value. It was suggested that we break up 44643 by stylesheet in order to better track them.

This ticket covers much of wp-admin/css/common.css, see patch notes below

Note: The patch was tested only on a Windows machine in Chrome, Firefox, IE11 and Edge. As per it should probably be tested on other OS's and supported browsers

Patch Notes:

Unchanged line-height values that use units (I could not find a good unitless solution that would work across all browsers and admin pages)

line 222 - body
line 509 - .widefat td, .widefat td p, .widefat td ol, .widefat td ul
line 516 - .widefat th, .widefat thead td, .widefat tfoot td
line 759 - .widget .widget-top, .postbox .hndle, .stuffbox .hndle, .control-section .accordion-section-title, .sidebar-name, #nav-menu-header, #nav-menu-footer, .menu-item-handle, .checkbox, .side-info, #your-profile #rich_editing, .widefat thead th, .widefat thead td, .widefat tfoot th, .widefat tfoot td

Unable to find these selectors anywhere in the DOM

line 838 - .key-labels label
line 1739 - .toggle-arrow
line 1769 - #number-of-columns
line 3040 - .bulk-action-notice .toggle-indicator:before

Attachments (1)

46493.diff (4.6 KB) - added by ianbelanger 5 years ago.

Download all attachments as: .zip

Change History (7)

5 years ago

#1 @netweb
5 years ago

  • Keywords good-first-bug removed
  • Milestone changed from Awaiting Review to 5.2

#2 @desrosj
5 years ago

#38239 was marked as a duplicate.

This ticket was mentioned in Slack in #core by audrasjb. View the logs.

5 years ago

This ticket was mentioned in Slack in #core by jeffpaul. View the logs.

5 years ago

#5 @talldanwp
5 years ago

  • Keywords commit added; needs-testing removed

Thanks for your work on this @ianbelanger. I've given this a thorough test and also double-checked the calculations and everything looks good from my point of view.

#6 @pento
5 years ago

  • Resolution set to fixed
  • Status changed from assigned to closed

In 45243:

CSS: Remove the units from line-height properties in common.css.

Props ianbelanger, talldanwp.
Fixes #46493.

Note: See TracTickets for help on using tickets.