Created
May 19, 2011 17:23
-
-
Save tomykaira/981270 to your computer and use it in GitHub Desktop.
test for jQuery UI Bug:#5245 Slide Effect Broken With Relative Width
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<script type="text/javascript" src="../../jquery-1.5.1.js"></script> | |
<script type="text/javascript" src="../../ui/jquery.ui.core.js"></script> | |
<script type="text/javascript" src="../../ui/jquery.ui.widget.js"></script> | |
<script type="text/javascript" src="../../ui/jquery.ui.mouse.js"></script> | |
<script type="text/javascript" src="../../ui/jquery.ui.draggable.js"></script> | |
<script type="text/javascript" src="../../ui/jquery.effects.core.js"></script> | |
<script type="text/javascript" src="../../ui/jquery.effects.scale.js"></script> | |
<script type="text/javascript" src="../../ui/jquery.effects.slide.js"></script> | |
<script type="text/javascript" src="../../ui/jquery.ui.droppable.js"></script> | |
<script type="text/javascript"> | |
$(document).ready( function() { | |
$("#wid").click(function(){ | |
$(".wid") | |
.hide("slide", {}, 2000).show("slide") | |
.hide("slide", {direction: "right"}, 2000).show("slide", {direction: "right"}) | |
.hide("slide", {direction: "up"}, 2000).show("slide", {direction: "up"}) | |
.hide("slide", {direction: "down"}, 2000).show("slide", {direction: "down"}); | |
}); | |
$("#hei").click(function(){ | |
$(".hei") | |
.hide("slide", {}, 2000).show("slide") | |
.hide("slide", {direction: "right"}, 2000).show("slide", {direction: "right"}) | |
.hide("slide", {direction: "up"}, 2000).show("slide", {direction: "up"}) | |
.hide("slide", {direction: "down"}, 2000).show("slide", {direction: "down"}); | |
}); | |
}); | |
</script> | |
<style type="text/css" media="screen"> | |
.obj1 { | |
height: 200px; | |
width: 100%; | |
} | |
.move { | |
background: red; | |
border: 3px dashed green; | |
} | |
.rel { position: relative; left: 300px; top: 30px } | |
.wid { height: 100px; } | |
.obj2 { | |
width: 50%; | |
} | |
.obj3 { | |
width: 631px; | |
} | |
.hei { width: 631px; } | |
.obj4 { | |
height: 50%; | |
} | |
.obj5 { | |
height: 100px; | |
} | |
</style> | |
</head> | |
<body> | |
<button id="wid">Click</button> | |
<div class="obj1"> | |
<div class="obj2 wid rel move">Wrong</div> | |
</div> | |
<div class="obj1"> | |
<div class="obj3 wid rel move">Correct</div> | |
</div> | |
<button id="hei">Click</button> | |
<div class="obj1"> | |
<div class="obj4 hei rel move">Wrong</div> | |
</div> | |
<div class="obj1"> | |
<div class="obj5 hei rel move">Correct</div> | |
</div> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment