Effects.core: Storing size and setting in createWrapper for applied to all effects.#326
Effects.core: Storing size and setting in createWrapper for applied to all effects.#326tomykaira wants to merge 12 commits intojquery:masterfrom
Conversation
…et distance before wrapping. #5245-Slide Effect Broken With Relative Width
…o force a px value instead of a % being carried over. Fixes #5245 - Slide Effect Broken With Relative Width
…o all effects. Fixed #5245 - Relative width elements break when wrapped for effects
tests/unit/effects/effects_core.js
Outdated
There was a problem hiding this comment.
Since this is now done in the createWrapper - perhaps we should change the unit test to just call createWrapper and then check the width?
Change the module("effects.core") test( "createWrapper recalculates relative widths" )
And rather than .slide() just wrap up the relative width element and test its width before/after?
|
As mentioned on the other pull - there are other effects that use createWrapper that we now need to make sure save/restore the width/height like you did for slide.... |
…ements break when wrapped for effects
|
Sure. I moved the test to Now all effects are tested with gnarf's code, and pass. |
|
And what about all the other effects, like |
… elements break when wrapped for effects
|
The unit test says that exactly all effects (including drop, fade, fold and others not yet mentioned) works correctly. I checked the behavior with eyes in https://gist.github.com/986073 . I forgot testing height, so added it. |
|
Here -- Maybe this commit will better illustrate the problem I'm talking about... All of those tests that are now failing will need to add Edited: Change my commit link, I had left a |
… all effects. Fixed #5245 - Relative width elements break when wrapped for effects
|
Okey, the point was "restoring". I added "width", "height" to all props, except "size". |
|
Thanks! Landed in 2c81518 |
Effects.core: Storing size and setting in createWrapper for applied to all effects. Fixed #5245 - Relative width elements break when wrapped for effects.
This is discussed in #314 . Since this size problem is common among effects, I modified
createWrapperand made it always store / set element size.Testcase is included.
Acknowledgement: gnarf37.