Skip to main content

Bug Tracker

Side navigation

#9598 closed enhancement (fixed)

Opened June 16, 2011 01:02AM UTC

Closed June 17, 2011 09:37PM UTC

width() does offsetWidth fallback unnecessarily if width=0 but padding or border > 0

Reported by: mikesherov Owned by:
Priority: undecided Milestone: 1.next
Component: unfiled Version: git
Keywords: Cc:
Blocked by: Blocking:
Description

In the latest updates, significant changes were made to cssHooks for width and height to address #9300 . However, it unnecessarily falls back from offsetWidth calculations when the width of the element is 0 and the padding or border is greater than 0.

The check if offsetWidth > 0 should happen before padding and border are stripped out.

Attachments (0)
Change History (2)

Changed June 16, 2011 12:29PM UTC by mikesherov comment:1

Changed June 17, 2011 09:37PM UTC by Mike Sherov comment:2

resolution: → fixed
status: newclosed

Landing pull request 413. Move border/padding checks to after width validation to avoid unnecessary fallbacks. Fixes #9598.

More Details:

Changeset: 124817e6684086ccf74e509309b73d4b4dd89932