/
bounce-effect.xml
36 lines (36 loc) · 1.02 KB
/
bounce-effect.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
<?xml version="1.0"?>
<entry name="bounce" type="effect">
<title>Bounce Effect</title>
<desc>
The bounce effect bounces an element. When used with hide or show, the last or first bounce will also fade in/out.
</desc>
<arguments>
<argument name="distance" type="Number" default="20">
<desc>The distance of the largest "bounce" in pixels.</desc>
</argument>
<argument name="times" type="Integer" default="5">
<desc>The number of times the element will bounce. When used with hide or show, there is an extra "half" bounce for the fade in/out.</desc>
</argument>
</arguments>
<example>
<height>200</height>
<desc>Toggle a div using the bounce effect.</desc>
<css><![CDATA[
#toggle {
width: 100px;
height: 100px;
background: #ccc;
}
]]></css>
<code><![CDATA[
$( document ).click(function() {
$( "#toggle" ).toggle( "bounce", { times: 3 }, "slow" );
});
]]></code>
<html><![CDATA[
<p>Click anywhere to toggle the box.</p>
<div id="toggle"></div>
]]></html>
</example>
<category slug="effects"/>
</entry>