Switch $(elem).width(-val) from no-op to $(elem).width(0)
|Reported by:||dmethvin||Owned by:|
To simplify things and make them more consistent, it would be nice to have .css() limit any values to 0 that can't go negative, so it doesn't have to be handled different ways in two places.
This is a change in behavior and something with a unit test in dimensions, but since negative values are actually outside the range of valid inputs I think it's within our rights to change this. Our main goal was to avoid an error in IE (for example in animations that undershoot), and the proposed change still does that.
Change History (7)
comment:1 Changed 5 years ago by dmethvin
- Component changed from unfiled to dimensions
- Milestone changed from None to 1.8
- Priority changed from undecided to low
- Status changed from new to open
- Version changed from 1.7.1 to 1.7.2