forked from jquery/api.jqueryui.com
/
transfer-effect.xml
39 lines (39 loc) · 1.39 KB
/
transfer-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
37
38
39
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="../entries2html.xsl" ?>
<entry name="transfer" namespace="effect" type="effect">
<desc>Transfers the outline of an element to another element</desc>
<longdesc>
Very useful when trying to visualize interaction between two elements.
<p>The transfer element iself has the class name "ui-effects-transfer", and needs to be styled by you, for example by adding a background or border.</p>
</longdesc>
<options>
<option name="className" type="String">
<desc>Optional class name the transfer element will receive.</desc>
</option>
<option name="to" type="String">
<desc>jQuery selector, the element to transfer to.</desc>
</option>
<option name="duration" type="Number" default="400">
<desc>The number of ms the animation will run for</desc>
</option>
<option name="easing" type="String" default="swing">
<desc>The easing function to use</desc>
</option>
<option name="complete" type="function">
<desc>A callback function, executed when the effect completes</desc>
</option>
</options>
<example>
<desc>Clicking on the green element transfers to the other.</desc>
<code><![CDATA[
$("div").click(function () {
var i = 1 - $("div").index(this);
$(this).effect("transfer", { to: $("div").eq(i) }, 1000);
});
]]></code>
<html><![CDATA[
<div></div>
]]></html>
</example>
<category slug="effects"/>
</entry>