-
Notifications
You must be signed in to change notification settings - Fork 48.5k
Adding and then removing "background" from style attribute creates unwanted styles #2407
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
👍 For posterity, this is probably the IE8 workaround that back-fires, but haven't actually verified. EDIT: This is really weird, the IE8 workaround should actually fix this it seems, but doesn't for some reason... |
Interestingly, doesn't happen in safari, but FF is affected (however different values for CSS properties): <div style="background-attachment: scroll; background-clip: border-box; background-origin: padding-box; background-size: auto auto;"></div> |
Highlights the problem without diving into the markup: http://jsfiddle.net/wc95h405/ |
The issue here is that we only unset background image, position, repeat, and color and not attachment, clip, origin, or size. Not sure where I came up with that original list. I think the best course of action here is to make sure we unset all the properties that IE8 supports, then take your #1953. These shorthand properties are kind of a pain. :) |
In conjunction with facebook#1953, fixes facebook#2407. This seems to be all of the shorthand style properties that IE8 supports, excluding a few nonstandard ones.
Ensure IE8 style expansion list is up to date
I have an element and depending on some condition, may set it's background. If the condition is first true, and later false the element is left with some "residual" styles that were never set in code.
Output looks like:
These styles were never set by user code, and are interfering with styles in my CSS.
Here's a fiddle showing the issue: http://jsfiddle.net/tfKYJ/78/
The text was updated successfully, but these errors were encountered: