mirror of
https://github.com/ACSPRI/queXS
synced 2024-04-02 12:12:16 +00:00
Added jquery
This commit is contained in:
977
include/jquery-ui/development-bundle/docs/accordion.html
Normal file
977
include/jquery-ui/development-bundle/docs/accordion.html
Normal file
@@ -0,0 +1,977 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Options</a></li>
|
||||
<li><a href="#events">Events</a></li>
|
||||
<li><a href="#methods">Methods</a></li>
|
||||
<li><a href="#theming">Theming</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI Accordion</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<p>Make the selected elements Accordion widgets. Semantic requirements:</p>
|
||||
<p>The markup of your accordion container needs pairs of headers and content panels:</p>
|
||||
<pre><div id="accordion">
|
||||
<h3><a href="#">First header</a></h3>
|
||||
<div>First content</div>
|
||||
<h3><a href="#">Second header</a></h3>
|
||||
<div>Second content</div>
|
||||
</div></pre>
|
||||
<p>If you use a different element for the header, specify the header-option with an appropriate selector, eg. header: 'a.header'. The content element must be always next to its header.</p>
|
||||
<p>If you have links inside the accordion content and use a-elements as headers, add a class to them and use that as the header, eg. header: 'a.header'.</p>
|
||||
<p>Use activate(Number) to change the active content programmatically.</p>
|
||||
<div class="editsection" style="float:right;margin-left:5px;">[<a href="http://docs.jquery.com/action/edit/UI/API/1.8/Accordion?section=1" title="Edit section: NOTE: If you want multiple sections open at once, don't use an accordion">edit</a>]</div><a name="NOTE:_If_you_want_multiple_sections_open_at_once.2C_don.27t_use_an_accordion"></a><h4>NOTE: If you want multiple sections open at once, don't use an accordion</h4>
|
||||
<p>An accordion doesn't allow more than one content panel to be open at the same time, and it takes a lot of effort to do that. If you are looking for a widget that allows more than one content panel to be open, don't use this. Usually it can be written with a few lines of jQuery instead, something like this:</p>
|
||||
<pre>jQuery(document).ready(function(){
|
||||
$('.accordion .head').click(function() {
|
||||
$(this).next().toggle();
|
||||
return false;
|
||||
}).next().hide();
|
||||
});</pre>
|
||||
<p>Or animated:</p>
|
||||
<pre>jQuery(document).ready(function(){
|
||||
$('.accordion .head').click(function() {
|
||||
$(this).next().toggle('slow');
|
||||
return false;
|
||||
}).next().hide();
|
||||
});</pre>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>UI Core</li>
|
||||
<li>UI Effects Core (Optional - only for non-default animations)</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="310">
|
||||
A simple jQuery UI Accordion.<br />
|
||||
</p>
|
||||
<pre>$("#accordion").accordion();
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("#accordion").accordion();
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<div id="accordion">
|
||||
<h3><a href="#">Section 1</a></h3>
|
||||
<div>
|
||||
<p>
|
||||
Mauris mauris ante, blandit et, ultrices a, suscipit eget, quam. Integer
|
||||
ut neque. Vivamus nisi metus, molestie vel, gravida in, condimentum sit
|
||||
amet, nunc. Nam a nibh. Donec suscipit eros. Nam mi. Proin viverra leo ut
|
||||
odio. Curabitur malesuada. Vestibulum a velit eu ante scelerisque vulputate.
|
||||
</p>
|
||||
</div>
|
||||
<h3><a href="#">Section 2</a></h3>
|
||||
<div>
|
||||
<p>
|
||||
Sed non urna. Donec et ante. Phasellus eu ligula. Vestibulum sit amet
|
||||
purus. Vivamus hendrerit, dolor at aliquet laoreet, mauris turpis porttitor
|
||||
velit, faucibus interdum tellus libero ac justo. Vivamus non quam. In
|
||||
suscipit faucibus urna.
|
||||
</p>
|
||||
</div>
|
||||
<h3><a href="#">Section 3</a></h3>
|
||||
<div>
|
||||
<p>
|
||||
Nam enim risus, molestie et, porta ac, aliquam ac, risus. Quisque lobortis.
|
||||
Phasellus pellentesque purus in massa. Aenean in pede. Phasellus ac libero
|
||||
ac tellus pellentesque semper. Sed ac felis. Sed commodo, magna quis
|
||||
lacinia ornare, quam ante aliquam nisi, eu iaculis leo purus venenatis dui.
|
||||
</p>
|
||||
<ul>
|
||||
<li>List item one</li>
|
||||
<li>List item two</li>
|
||||
<li>List item three</li>
|
||||
</ul>
|
||||
</div>
|
||||
<h3><a href="#">Section 4</a></h3>
|
||||
<div>
|
||||
<p>
|
||||
Cras dictum. Pellentesque habitant morbi tristique senectus et netus
|
||||
et malesuada fames ac turpis egestas. Vestibulum ante ipsum primis in
|
||||
faucibus orci luctus et ultrices posuere cubilia Curae; Aenean lacinia
|
||||
mauris vel est.
|
||||
</p>
|
||||
<p>
|
||||
Suspendisse eu nisl. Nullam ut libero. Integer dignissim consequat lectus.
|
||||
Class aptent taciti sociosqu ad litora torquent per conubia nostra, per
|
||||
inceptos himenaeos.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Options</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-disabled">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-disabled">disabled</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Disables (true) or enables (false) the accordion. Can be set when initialising (first creating) the accordion.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a accordion with the <code>disabled</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).accordion({ disabled: true });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>disabled</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var disabled = $( ".selector" ).accordion( "option", "disabled" );
|
||||
//setter
|
||||
$( ".selector" ).accordion( "option", "disabled", true );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-active">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-active">active</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Selector, Element, jQuery, Boolean, Number</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">first child</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Selector for the active element. Set to false to display none at start. Needs <code>collapsible: true</code>.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a accordion with the <code>active</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).accordion({ active: 2 });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>active</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var active = $( ".selector" ).accordion( "option", "active" );
|
||||
//setter
|
||||
$( ".selector" ).accordion( "option", "active", 2 );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-animated">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-animated">animated</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean, String</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">'slide'</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Choose your favorite animation, or disable them (set to false). In addition to the default, 'bounceslide' and all defined easing methods are supported ('bounceslide' requires UI Effects Core).</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a accordion with the <code>animated</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).accordion({ animated: 'bounceslide' });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>animated</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var animated = $( ".selector" ).accordion( "option", "animated" );
|
||||
//setter
|
||||
$( ".selector" ).accordion( "option", "animated", 'bounceslide' );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-autoHeight">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-autoHeight">autoHeight</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">true</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>If set, the highest content part is used as height reference for all other parts. Provides more consistent animations.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a accordion with the <code>autoHeight</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).accordion({ autoHeight: false });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>autoHeight</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var autoHeight = $( ".selector" ).accordion( "option", "autoHeight" );
|
||||
//setter
|
||||
$( ".selector" ).accordion( "option", "autoHeight", false );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-clearStyle">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-clearStyle">clearStyle</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>If set, clears height and overflow styles after finishing animations. This enables accordions to work with dynamic content. Won't work together with autoHeight.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a accordion with the <code>clearStyle</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).accordion({ clearStyle: true });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>clearStyle</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var clearStyle = $( ".selector" ).accordion( "option", "clearStyle" );
|
||||
//setter
|
||||
$( ".selector" ).accordion( "option", "clearStyle", true );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-collapsible">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-collapsible">collapsible</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Whether all the sections can be closed at once. Allows collapsing the active section by the triggering event (click is the default).</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a accordion with the <code>collapsible</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).accordion({ collapsible: true });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>collapsible</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var collapsible = $( ".selector" ).accordion( "option", "collapsible" );
|
||||
//setter
|
||||
$( ".selector" ).accordion( "option", "collapsible", true );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-event">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-event">event</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">'click'</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>The event on which to trigger the accordion.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a accordion with the <code>event</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).accordion({ event: 'mouseover' });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>event</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var event = $( ".selector" ).accordion( "option", "event" );
|
||||
//setter
|
||||
$( ".selector" ).accordion( "option", "event", 'mouseover' );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-fillSpace">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-fillSpace">fillSpace</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>If set, the accordion completely fills the height of the parent element. Overrides autoheight.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a accordion with the <code>fillSpace</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).accordion({ fillSpace: true });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>fillSpace</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var fillSpace = $( ".selector" ).accordion( "option", "fillSpace" );
|
||||
//setter
|
||||
$( ".selector" ).accordion( "option", "fillSpace", true );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-header">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-header">header</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Selector, jQuery</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">'> li > :first-child,> :not(li):even'</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Selector for the header element.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a accordion with the <code>header</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).accordion({ header: 'h3' });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>header</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var header = $( ".selector" ).accordion( "option", "header" );
|
||||
//setter
|
||||
$( ".selector" ).accordion( "option", "header", 'h3' );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-icons">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-icons">icons</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Object</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">{ 'header': 'ui-icon-triangle-1-e', 'headerSelected': 'ui-icon-triangle-1-s' }</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Icons to use for headers. Icons may be specified for 'header' and 'headerSelected', and we recommend using the icons native to the jQuery UI CSS Framework manipulated by <a href="http://www.themeroller.com" class="external text" title="http://www.themeroller.com">jQuery UI ThemeRoller</a></p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a accordion with the <code>icons</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).accordion({ icons: { 'header': 'ui-icon-plus', 'headerSelected': 'ui-icon-minus' } });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>icons</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var icons = $( ".selector" ).accordion( "option", "icons" );
|
||||
//setter
|
||||
$( ".selector" ).accordion( "option", "icons", { 'header': 'ui-icon-plus', 'headerSelected': 'ui-icon-minus' } );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-navigation">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-navigation">navigation</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>If set, looks for the anchor that matches location.href and activates it. Great for href-based state-saving. Use navigationFilter to implement your own matcher.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a accordion with the <code>navigation</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).accordion({ navigation: true });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>navigation</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var navigation = $( ".selector" ).accordion( "option", "navigation" );
|
||||
//setter
|
||||
$( ".selector" ).accordion( "option", "navigation", true );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-navigationFilter">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-navigationFilter">navigationFilter</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Function</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default"> </dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Overwrite the default location.href-matching with your own matcher.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a accordion with the <code>navigationFilter</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).accordion({ navigationFilter: function(){ ... } });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>navigationFilter</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var navigationFilter = $( ".selector" ).accordion( "option", "navigationFilter" );
|
||||
//setter
|
||||
$( ".selector" ).accordion( "option", "navigationFilter", function(){ ... } );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="events">
|
||||
<h2 class="top-header">Events</h2>
|
||||
<ul class="events-list">
|
||||
|
||||
<li class="event" id="event-change">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-change">change</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">accordionchange</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered every time the accordion changes. If the accordion is animated, the event will be triggered upon completion of the animation; otherwise, it is triggered immediately.
|
||||
</p>
|
||||
<pre>$('.ui-accordion').bind('accordionchange', function(event, ui) {
|
||||
ui.newHeader // jQuery object, activated header
|
||||
ui.oldHeader // jQuery object, previous header
|
||||
ui.newContent // jQuery object, activated content
|
||||
ui.oldContent // jQuery object, previous content
|
||||
});</pre></p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>change</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).accordion({
|
||||
change: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>change</code> event by type: <code>accordionchange</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "accordionchange", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
<p>
|
||||
<li class="event" id="event-changestart">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-changestart">changestart</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">accordionchangestart</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered every time the accordion starts to change.
|
||||
</p>
|
||||
<pre>$('.ui-accordion').bind('accordionchangestart', function(event, ui) {
|
||||
ui.newHeader // jQuery object, activated header
|
||||
ui.oldHeader // jQuery object, previous header
|
||||
ui.newContent // jQuery object, activated content
|
||||
ui.oldContent // jQuery object, previous content
|
||||
});</pre></p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>changestart</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).accordion({
|
||||
changestart: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>changestart</code> event by type: <code>accordionchangestart</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "accordionchangestart", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="methods">
|
||||
<h2 class="top-header">Methods</h2>
|
||||
<ul class="methods-list">
|
||||
|
||||
<li class="method" id="method-destroy">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-destroy">destroy</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.accordion( "destroy"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Remove the accordion functionality completely. This will return the element back to its pre-init state.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
<p>
|
||||
<li class="method" id="method-disable">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-disable">disable</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.accordion( "disable"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Disable the accordion.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-enable">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-enable">enable</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.accordion( "enable"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Enable the accordion.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-option">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-option">option</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.accordion( "option"
|
||||
|
||||
, optionName
|
||||
|
||||
, <span class="optional">[</span>value<span class="optional">] </span>
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Get or set any accordion option. If no value is specified, will act as a getter.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-option">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-option">option</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.accordion( "option"
|
||||
|
||||
, options
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Set multiple accordion options at once by providing an options object.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-widget">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-widget">widget</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.accordion( "widget"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Returns the .ui-accordion element.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-activate">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-activate">activate</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.accordion( "activate"
|
||||
|
||||
, index
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Activate a content part of the Accordion programmatically. The index can be a zero-indexed number to match the position of the header to close or a Selector matching an element. Pass <code>false</code> to close all (only possible with <code>collapsible:true</code>).</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-resize">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-resize">resize</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.accordion( "resize"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Recompute heights of the accordion contents when using the fillSpace option and the container height changed. For example, when the container is a resizable, this method should be called by its resize-event.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="theming">
|
||||
<h2 class="top-header">Theming</h2>
|
||||
<p>The jQuery UI Accordion plugin uses the jQuery UI CSS Framework to style its look and feel, including colors and background textures. We recommend using the ThemeRoller tool to create and download custom themes that are easy to build and maintain.
|
||||
</p>
|
||||
<p>If a deeper level of customization is needed, there are widget-specific classes referenced within the jquery.ui.accordion.css stylesheet that can be modified. These classes are highlighed in bold below.
|
||||
</p>
|
||||
|
||||
<h3>Sample markup with jQuery UI CSS Framework classes</h3>
|
||||
<div class="<strong>ui-accordion</strong> ui-widget ui-helper-reset"><br />
|
||||
<h3 class="<strong>ui-accordion-header</strong> ui-helper-reset ui-state-active ui-corner-top"><br />
|
||||
<span class="ui-icon ui-icon-triangle-1-s"/><br />
|
||||
<a href="#">Section 1</a><br />
|
||||
</h3><br />
|
||||
<div class="<strong>ui-accordion-content</strong> ui-helper-reset ui-widget-content ui-corner-bottom <strong>ui-accordion-content-active</strong>"><br />
|
||||
Section 1 content<br />
|
||||
</div><br />
|
||||
<h3 class="<strong>ui-accordion-header</strong> ui-helper-reset ui-state-default ui-corner-all"><br />
|
||||
<span class="ui-icon ui-icon-triangle-1-e"/><br />
|
||||
<a href="#">Section 2</a><br />
|
||||
</h3><br />
|
||||
<div class="<strong>ui-accordion-content</strong> ui-helper-reset ui-widget-content ui-corner-bottom"><br />
|
||||
Section 2 content<br />
|
||||
</div><br />
|
||||
<h3 class="<strong>ui-accordion-header</strong> ui-helper-reset ui-state-default ui-corner-all"><br />
|
||||
<span class="ui-icon ui-icon-triangle-1-e"/><br />
|
||||
<a href="#">Section 3</a><br />
|
||||
</h3><br />
|
||||
<div class="<strong>ui-accordion-content</strong> ui-helper-reset ui-widget-content ui-corner-bottom"><br />
|
||||
Section 3 content<br />
|
||||
</div><br />
|
||||
</div><br />
|
||||
<p class="theme-note">
|
||||
<strong>
|
||||
Note: This is a sample of markup generated by the accordion plugin, not markup you should use to create a accordion. The only markup needed for that is <br /><div><br />
|
||||
   <h3><a href="#">Section 1</a></h3><br />
|
||||
   <div><br />
|
||||
      Section 1 content<br />
|
||||
   </div><br />
|
||||
   <h3><a href="#">Section 2</a></h3><br />
|
||||
   <div><br />
|
||||
      Section 2 content<br />
|
||||
   </div><br />
|
||||
   <h3><a href="#">Section 3</a></h3><br />
|
||||
   <div><br />
|
||||
      Section 3 content<br />
|
||||
   </div><br />
|
||||
</div>.
|
||||
</strong>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 36551 bytes
|
||||
Post-expand include size: 61985 bytes
|
||||
Template argument size: 35253 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:3773-1!1!0!!en!2 and timestamp 20100520115459 -->
|
||||
109
include/jquery-ui/development-bundle/docs/addClass.html
Normal file
109
include/jquery-ui/development-bundle/docs/addClass.html
Normal file
@@ -0,0 +1,109 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Arguments</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI addClass</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<div class="editsection" style="float:right;margin-left:5px;">[<a href="http://docs.jquery.com/action/edit/UI/Effects/addClass?section=1" title="Edit section: addClass( class, [duration] )">edit</a>]</div><a name="addClass.28_class.2C_.5Bduration.5D_.29"></a><h3>addClass( class, <span class="optional">[</span>duration<span class="optional">]</span> )</h3>
|
||||
<p>Adds the specified class to each of the set of matched elements with an optional transition between the states.</p>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>Effects Core</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="100">
|
||||
Adds the class 'selected' to the matched elements with a one second transition.<br />
|
||||
</p>
|
||||
<pre>$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$(this).<strong class="selflink">addClass</strong>("selected", 1000);
|
||||
});
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
<script src="http://ui.jquery.com/latest/ui/effects.core.js"></script>
|
||||
<style type="text/css">
|
||||
p { cursor: pointer; font-size: 1.2em; }
|
||||
.selected { color:red; }
|
||||
</style>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$(this).<strong class="selflink">addClass</strong>("selected", 1000);
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
<p>Click me to add a 'selected' class.</p>
|
||||
<p>Click me to add a 'selected' class.</p>
|
||||
<p>Click me to add a 'selected' class.</p>
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Arguments</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-class">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-class">class</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>One CSS class to add to the elements.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-duration">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-duration">duration</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String, Number</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A string representing one of the three predefined speeds ("slow", "normal", or "fast") or the number of milliseconds to run the animation (e.g. 1000).</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 5228 bytes
|
||||
Post-expand include size: 6863 bytes
|
||||
Template argument size: 4285 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:2606-1!1!0!!en!2 and timestamp 20100519135738 -->
|
||||
77
include/jquery-ui/development-bundle/docs/animate.html
Normal file
77
include/jquery-ui/development-bundle/docs/animate.html
Normal file
@@ -0,0 +1,77 @@
|
||||
<p>The jQuery UI effects core extends the <a href="http://docs.jquery.com/Effects/animate" title="Effects/animate">animate</a> function to be able to animate colors as well. It's heavily used by the class transition feature and it's able to color animate the following properties:
|
||||
</p>
|
||||
<ul><li> <b>backgroundColor</b>
|
||||
</li><li> <b>borderBottomColor</b>
|
||||
</li><li> <b>borderLeftColor</b>
|
||||
</li><li> <b>borderRightColor</b>
|
||||
</li><li> <b>borderTopColor</b>
|
||||
</li><li> <b>color</b>
|
||||
</li><li> <b>outlineColor</b>
|
||||
</li></ul>
|
||||
<p>with one of the following combinations:
|
||||
</p>
|
||||
<ul><li> <b>hex (#FF0000)</b>
|
||||
</li><li> <b>rgb (rgb(255,255,255))</b>
|
||||
</li><li> <b>names ("black")</b>
|
||||
</li></ul>
|
||||
<p><br />
|
||||
</p><p><div class="options list"><table class="options examples" cellspacing="0"><thead><tr><th>Name</th><th>Type</th></tr></thead><tbody>
|
||||
</table><b class="options">Example:</b><table class="options examples" cellspacing="0"><thead><tr><th>Name</th><th>Type</th></tr></thead><tbody>
|
||||
<div class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<div id="demo" class="tabs-container" rel="125">
|
||||
A simple color animation.<br />
|
||||
</p>
|
||||
<pre>$(".block").<a href="http://docs.jquery.com/Events/toggle" title="Events/toggle">toggle</a>(function() {
|
||||
$(this).<a href="http://docs.jquery.com/Effects/animate" title="Effects/animate">animate</a>({ backgroundColor: "black" }, 1000);
|
||||
},function() {
|
||||
$(this).<a href="http://docs.jquery.com/Effects/animate" title="Effects/animate">animate</a>({ backgroundColor: "#68BFEF" }, 500);
|
||||
});
|
||||
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
||||
"<a href="http://www.w3.org/TR/html4/loose.dtd" class="external free" title="http://www.w3.org/TR/html4/loose.dtd">http://www.w3.org/TR/html4/loose.dtd</a>">
|
||||
<html>
|
||||
<head>
|
||||
<script src="<a href="http://code.jquery.com/jquery-latest.js" class="external free" title="http://code.jquery.com/jquery-latest.js">http://code.jquery.com/jquery-latest.js</a>"></script>
|
||||
|
||||
<script src="http://jqueryui.com/latest/ui/effects.core.js"></script>
|
||||
|
||||
<script>
|
||||
$(document).ready(function(){
|
||||
$(".block").<a href="http://docs.jquery.com/Events/toggle" title="Events/toggle">toggle</a>(function() {
|
||||
$(this).<a href="http://docs.jquery.com/Effects/animate" title="Effects/animate">animate</a>({ backgroundColor: "black" }, 1000);
|
||||
},function() {
|
||||
$(this).<a href="http://docs.jquery.com/Effects/animate" title="Effects/animate">animate</a>({ backgroundColor: "#68BFEF" }, 500);
|
||||
});
|
||||
|
||||
});
|
||||
</script>
|
||||
<style>
|
||||
.block {
|
||||
color: white;
|
||||
background-color: #68BFEF;
|
||||
width: 150px;
|
||||
height: 70px;
|
||||
margin: 10px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="block"> Click me</div>
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</p><p></tbody></table></div>
|
||||
</p><!--
|
||||
Pre-expand include size: 3711 bytes
|
||||
Post-expand include size: 5317 bytes
|
||||
Template argument size: 3405 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:3094-1!1!0!!en!2 and timestamp 20100520115504 -->
|
||||
710
include/jquery-ui/development-bundle/docs/autocomplete.html
Normal file
710
include/jquery-ui/development-bundle/docs/autocomplete.html
Normal file
@@ -0,0 +1,710 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Options</a></li>
|
||||
<li><a href="#events">Events</a></li>
|
||||
<li><a href="#methods">Methods</a></li>
|
||||
<li><a href="#theming">Theming</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI Autocomplete</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<p>Autocomplete, when added to an input field, enables users to quickly find and select from a pre-populated list of values as they type, leveraging searching and filtering.</p>
|
||||
<p>By giving an Autocomplete field focus or entering something into it, the plugin starts searching for entries that match and displays a list of values to choose from. By entering more characters, the user can filter down the list to better matches.</p>
|
||||
<p>This can be used to enter previous selected values, for example you could use Autocomplete for entering tags, to complete an address, you could enter a city name and get the zip code, or maybe enter email addresses from an address book.</p>
|
||||
<p>You can pull data in from a local and/or a remote source: Local is good for small data sets (like an address book with 50 entries), remote is necessary for big data sets, like a database with hundreds or millions of entries to select from.</p>
|
||||
<p>Autocomplete can be customized to work with various data sources, by just specifying the source option. A data source can be:</p>
|
||||
<ul>
|
||||
<li>an Array with local data</li>
|
||||
<li>a String, specifying a URL</li>
|
||||
<li>a Callback</li>
|
||||
</ul>
|
||||
<p>The local data can be a simple Array of Strings, or it contains Objects for each item in the array, with either a label or value property or both. The label property is displayed in the suggestion menu. The value will be inserted into the input element after the user selected something from the menu. If just one property is specified, it will be used for both, eg. if you provide only value-properties, the value will also be used as the label.</p>
|
||||
<p>When a String is used, the Autocomplete plugin expects that string to point to a URL resource that will return JSON data. It can be on the same host or on a different one (must provide JSONP). The request parameter "term" gets added to that URL. The data itself can be in the same format as the local data described above.</p>
|
||||
<p>The third variation, the callback, provides the most flexibility, and can be used to connect any data source to Autocomplete. The callback gets two arguments:</p>
|
||||
<ul>
|
||||
<li>A request object, with a single property called "term", which refers to the value currently in the text input. For example, when the user entered "new yo" in a city field, the Autocomplete term will equal "new yo".</li>
|
||||
<li>A response callback, which expects a single argument to contain the data to suggest to the user. This data should be filtered based on the provided term, and can be in any of the formats described above for simple local data (String-Array or Object-Array with label/value/both properties).</li>
|
||||
</ul>
|
||||
<p>The demos all focus on different variations of the source-option - look for the one that matches your use case, and take a look at the code.</p>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>UI Core</li>
|
||||
<li>UI Widget</li>
|
||||
<li>UI Position</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="300">
|
||||
A simple jQuery UI Autocomplete.<br />
|
||||
</p>
|
||||
<pre>$("input#autocomplete").autocomplete({
|
||||
source: ["c++", "java", "php", "coldfusion", "javascript", "asp", "ruby"]
|
||||
});
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("input#autocomplete").autocomplete({
|
||||
source: ["c++", "java", "php", "coldfusion", "javascript", "asp", "ruby"]
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<input id="autocomplete" />
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Options</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-disabled">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-disabled">disabled</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Disables (true) or enables (false) the autocomplete. Can be set when initialising (first creating) the autocomplete.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a autocomplete with the <code>disabled</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).autocomplete({ disabled: true });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>disabled</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var disabled = $( ".selector" ).autocomplete( "option", "disabled" );
|
||||
//setter
|
||||
$( ".selector" ).autocomplete( "option", "disabled", true );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-delay">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-delay">delay</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Integer</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">300</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>The delay in milliseconds the Autocomplete waits after a keystroke to activate itself. A zero-delay makes sense for local data (more responsive), but can produce a lot of load for remote data, while being less responsive.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a autocomplete with the <code>delay</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).autocomplete({ delay: 0 });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>delay</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var delay = $( ".selector" ).autocomplete( "option", "delay" );
|
||||
//setter
|
||||
$( ".selector" ).autocomplete( "option", "delay", 0 );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-minLength">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-minLength">minLength</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Integer</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">1</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>The minimum number of characters a user has to type before the Autocomplete activates. Zero is useful for local data with just a few items. Should be increased when there are a lot of items, where a single character would match a few thousand items.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a autocomplete with the <code>minLength</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).autocomplete({ minLength: 0 });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>minLength</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var minLength = $( ".selector" ).autocomplete( "option", "minLength" );
|
||||
//setter
|
||||
$( ".selector" ).autocomplete( "option", "minLength", 0 );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-source">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-source">source</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String, Array, Callback</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">none, must be specified</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Defines the data to use, must be specified. See Overview section for more details, and look at the various demos.
|
||||
</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a autocomplete with the <code>source</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).autocomplete({ source: ["c++", "java", "php", "coldfusion", "javascript", "asp", "ruby"] });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>source</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var source = $( ".selector" ).autocomplete( "option", "source" );
|
||||
//setter
|
||||
$( ".selector" ).autocomplete( "option", "source", ["c++", "java", "php", "coldfusion", "javascript", "asp", "ruby"] );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="events">
|
||||
<h2 class="top-header">Events</h2>
|
||||
<ul class="events-list">
|
||||
|
||||
<li class="event" id="event-search">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-search">search</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">autocompletesearch</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>Before a request (source-option) is started, after minLength and delay are met. Can be canceled (return false), then no request will be started and no items suggested.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>search</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).autocomplete({
|
||||
search: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>search</code> event by type: <code>autocompletesearch</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "autocompletesearch", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-open">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-open">open</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">autocompleteopen</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>Triggered when the suggestion menu is opened.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>open</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).autocomplete({
|
||||
open: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>open</code> event by type: <code>autocompleteopen</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "autocompleteopen", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-focus">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-focus">focus</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">autocompletefocus</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>Before focus is moved to an item (not selecting), ui.item refers to the focused item. The default action of focus is to replace the text field's value with the value of the focused item, though only if the focus event was triggered by a keyboard interaction. Canceling this event prevents the value from being updated, but does not prevent the menu item from being focused.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>focus</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).autocomplete({
|
||||
focus: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>focus</code> event by type: <code>autocompletefocus</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "autocompletefocus", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-select">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-select">select</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">autocompleteselect</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>Triggered when an item is selected from the menu; ui.item refers to the selected item. The default action of select is to replace the text field's value with the value of the selected item. Canceling this event prevents the value from being updated, but does not prevent the menu from closing.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>select</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).autocomplete({
|
||||
select: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>select</code> event by type: <code>autocompleteselect</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "autocompleteselect", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-close">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-close">close</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">autocompleteclose</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>When the list is hidden - doesn't have to occur together with a change.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>close</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).autocomplete({
|
||||
close: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>close</code> event by type: <code>autocompleteclose</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "autocompleteclose", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-change">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-change">change</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">autocompletechange</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>After an item was selected; ui.item refers to the selected item. Always triggered after the close event.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>change</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).autocomplete({
|
||||
change: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>change</code> event by type: <code>autocompletechange</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "autocompletechange", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="methods">
|
||||
<h2 class="top-header">Methods</h2>
|
||||
<ul class="methods-list">
|
||||
|
||||
<li class="method" id="method-destroy">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-destroy">destroy</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.autocomplete( "destroy"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Remove the autocomplete functionality completely. This will return the element back to its pre-init state.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-disable">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-disable">disable</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.autocomplete( "disable"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Disable the autocomplete.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-enable">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-enable">enable</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.autocomplete( "enable"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Enable the autocomplete.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-option">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-option">option</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.autocomplete( "option"
|
||||
|
||||
, optionName
|
||||
|
||||
, <span class="optional">[</span>value<span class="optional">] </span>
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Get or set any autocomplete option. If no value is specified, will act as a getter.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-option">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-option">option</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.autocomplete( "option"
|
||||
|
||||
, options
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Set multiple autocomplete options at once by providing an options object.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-widget">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-widget">widget</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.autocomplete( "widget"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Returns the .ui-autocomplete element.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-search">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-search">search</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.autocomplete( "search"
|
||||
|
||||
, <span class="optional">[</span>value<span class="optional">] </span>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Triggers a search event, which, when data is available, then will display the suggestions; can be used by a selectbox-like button to open the suggestions when clicked. If no value argument is specified, the current input's value is used. Can be called with an empty string and minLength: 0 to display all items.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-close">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-close">close</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.autocomplete( "close"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Close the Autocomplete menu. Useful in combination with the search method, to close the open menu.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="theming">
|
||||
<h2 class="top-header">Theming</h2>
|
||||
<p>The jQuery UI Autocomplete plugin uses the jQuery UI CSS Framework to style its look and feel, including colors and background textures. We recommend using the ThemeRoller tool to create and download custom themes that are easy to build and maintain.
|
||||
</p>
|
||||
<p>If a deeper level of customization is needed, there are widget-specific classes referenced within the jquery.ui.autocomplete.css stylesheet that can be modified. These classes are highlighed in bold below.
|
||||
</p>
|
||||
|
||||
<h3>Sample markup with jQuery UI CSS Framework classes</h3>
|
||||
<input class="ui-autocomplete-input"/><br />
|
||||
<ul class="ui-autocomplete ui-menu ui-widget ui-widget-content ui-corner-all"><br />
|
||||
<li class="ui-menu-item"><br />
|
||||
<a class="ui-corner-all">item 1</a><br />
|
||||
</li><br />
|
||||
<li class="ui-menu-item"><br />
|
||||
<a class="ui-corner-all">item 2</a><br />
|
||||
</li><br />
|
||||
<li class="ui-menu-item"><br />
|
||||
<a class="ui-corner-all">item 3</a><br />
|
||||
</li><br />
|
||||
</ul>
|
||||
<p class="theme-note">
|
||||
<strong>
|
||||
Note: This is a sample of markup generated by the autocomplete plugin, not markup you should use to create a autocomplete. The only markup needed for that is <input/>.
|
||||
</strong>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 29860 bytes
|
||||
Post-expand include size: 48463 bytes
|
||||
Template argument size: 26753 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:3766-1!1!0!!en!2 and timestamp 20100520115459 -->
|
||||
460
include/jquery-ui/development-bundle/docs/button.html
Normal file
460
include/jquery-ui/development-bundle/docs/button.html
Normal file
@@ -0,0 +1,460 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Options</a></li>
|
||||
<li><a href="#events">Events</a></li>
|
||||
<li><a href="#methods">Methods</a></li>
|
||||
<li><a href="#theming">Theming</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI Button</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<p>Button enhances standard form elements like button, input of type submit or reset or anchors to themable buttons with appropiate mouseover and active styles.</p>
|
||||
<p>In addition to basic push buttons, radio buttons and checkboxes (inputs of type radio and checkbox) can be converted to buttons: Their associated label is styled to appear as the button, while the underlying input is updated on click.</p>
|
||||
<p>In order to group radio buttons, Button also provides an additional widget-method, called Buttonset. Its used by selecting a container element (which contains the radio buttons) and calling buttonset(). Buttonset will also provide visual grouping, and therefore should be used whenever you have a group of buttons. It works by selecting all descendents and applying button() to them. You can enable and disable a buttonset, which will enable and disable all contained buttons. Destroying a buttonset also calls the button's destroy method.</p>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>UI Core</li>
|
||||
<li>UI Widget</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="300">
|
||||
A simple jQuery UI Button.<br />
|
||||
</p>
|
||||
<pre>$("button").button();
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("button").button();
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<button>Button label</button>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<div id="demo" class="tabs-container" rel="300">
|
||||
A simple jQuery UI Button.<br />
|
||||
</p>
|
||||
<pre>$("#radio1").buttonset();
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("#radio1").buttonset();
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<div id="radio1">
|
||||
<input type="radio" id="radio1" name="radio" /><label for="radio1">Choice 1</label>
|
||||
<input type="radio" id="radio2" name="radio" checked="checked" /><label for="radio2">Choice 2</label>
|
||||
<input type="radio" id="radio3" name="radio" /><label for="radio3">Choice 3</label>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Options</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-disabled">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-disabled">disabled</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Disables (true) or enables (false) the button. Can be set when initialising (first creating) the button.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a button with the <code>disabled</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).button({ disabled: true });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>disabled</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var disabled = $( ".selector" ).button( "option", "disabled" );
|
||||
//setter
|
||||
$( ".selector" ).button( "option", "disabled", true );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-text">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-text">text</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">true</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Whether to show any text - when set to false (display no text), icons (see icons option) must be enabled, otherwise it'll be ignored.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a button with the <code>text</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).button({ text: false });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>text</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var text = $( ".selector" ).button( "option", "text" );
|
||||
//setter
|
||||
$( ".selector" ).button( "option", "text", false );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-icons">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-icons">icons</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Options</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">{ primary: null, secondary: null }</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Icons to display, with or without text (see text option). The primary icon is displayed on the left of the label text, the secondary on the right. Value for the primary and secondary properties must be a classname (String), eg. "ui-icon-gear". For using only a primary icon: icons: {primary:'ui-icon-locked'}. For using both primary and secondary icon: icons: {primary:'ui-icon-gear',secondary:'ui-icon-triangle-1-s'}</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a button with the <code>icons</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).button({ icons: {primary:'ui-icon-gear',secondary:'ui-icon-triangle-1-s'} });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>icons</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var icons = $( ".selector" ).button( "option", "icons" );
|
||||
//setter
|
||||
$( ".selector" ).button( "option", "icons", {primary:'ui-icon-gear',secondary:'ui-icon-triangle-1-s'} );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-label">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-label">label</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">HTML content of the button, or value attribute</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Text to show on the button. When not specified (null), the element's html content is used, or its value attribute when it's an input element of type submit or reset; or the html content of the associated label element if its an input of type radio or checkbox</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a button with the <code>label</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).button({ label: "custom label" });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>label</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var label = $( ".selector" ).button( "option", "label" );
|
||||
//setter
|
||||
</p>
|
||||
$( ".selector" ).button( "option", "label", "custom label" );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="events">
|
||||
<h2 class="top-header">Events</h2>
|
||||
<ul class="events-list">
|
||||
<p>There are no events for this plugin.</p>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="methods">
|
||||
<h2 class="top-header">Methods</h2>
|
||||
<ul class="methods-list">
|
||||
|
||||
<li class="method" id="method-destroy">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-destroy">destroy</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.button( "destroy"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Remove the button functionality completely. This will return the element back to its pre-init state.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
<p>
|
||||
<li class="method" id="method-disable">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-disable">disable</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.button( "disable"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Disable the button.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-enable">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-enable">enable</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.button( "enable"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Enable the button.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-option">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-option">option</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.button( "option"
|
||||
|
||||
, optionName
|
||||
|
||||
, <span class="optional">[</span>value<span class="optional">] </span>
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Get or set any button option. If no value is specified, will act as a getter.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-option">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-option">option</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.button( "option"
|
||||
|
||||
, options
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Set multiple button options at once by providing an options object.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-widget">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-widget">widget</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.button( "widget"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Returns the .ui-button element.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-refresh">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-refresh">refresh</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.button( "refresh"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Refreshes the visual state of the button. Useful for updating button state after the native element's checked or disabled state is changed programatically.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="theming">
|
||||
<h2 class="top-header">Theming</h2>
|
||||
<p>The jQuery UI Button plugin uses the jQuery UI CSS Framework to style its look and feel, including colors and background textures. We recommend using the ThemeRoller tool to create and download custom themes that are easy to build and maintain.
|
||||
</p>
|
||||
<p>If a deeper level of customization is needed, there are widget-specific classes referenced within the jquery.ui.button.css stylesheet that can be modified. These classes are highlighed in bold below.
|
||||
</p>
|
||||
|
||||
<h3>Sample markup with jQuery UI CSS Framework classes</h3>
|
||||
<button class="<strong>ui-button ui-button-text-only</strong> ui-widget ui-state-default ui-corner-all"><br />
|
||||
<span class="<strong>ui-button-text</strong>">Button Label</span><br /></button>
|
||||
<p class="theme-note">
|
||||
<strong>
|
||||
Note: This is a sample of markup generated by the button plugin, not markup you should use to create a button. The only markup needed for that is <button>Button Label</button>.
|
||||
</strong>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 23021 bytes
|
||||
Post-expand include size: 28995 bytes
|
||||
Template argument size: 13372 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:3767-1!1!0!!en!2 and timestamp 20100520115500 -->
|
||||
2530
include/jquery-ui/development-bundle/docs/datepicker.html
Normal file
2530
include/jquery-ui/development-bundle/docs/datepicker.html
Normal file
File diff suppressed because it is too large
Load Diff
1603
include/jquery-ui/development-bundle/docs/dialog.html
Normal file
1603
include/jquery-ui/development-bundle/docs/dialog.html
Normal file
File diff suppressed because it is too large
Load Diff
1536
include/jquery-ui/development-bundle/docs/draggable.html
Normal file
1536
include/jquery-ui/development-bundle/docs/draggable.html
Normal file
File diff suppressed because it is too large
Load Diff
788
include/jquery-ui/development-bundle/docs/droppable.html
Normal file
788
include/jquery-ui/development-bundle/docs/droppable.html
Normal file
@@ -0,0 +1,788 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Options</a></li>
|
||||
<li><a href="#events">Events</a></li>
|
||||
<li><a href="#methods">Methods</a></li>
|
||||
<li><a href="#theming">Theming</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI Droppable</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<p>The jQuery UI Droppable plugin makes selected elements droppable (meaning they accept being dropped on by draggables). You can specify which (individually) or which kind of draggables each will accept.</p>
|
||||
<p>All callbacks receive two arguments: The original browser event and a prepared ui object, view below for a documentation of this object (if you name your second argument 'ui'):</p>
|
||||
<ul>
|
||||
<li> <b>ui.draggable</b> - current draggable element, a jQuery object.</li>
|
||||
<li> <b>ui.helper</b> - current draggable helper, a jQuery object</li>
|
||||
<li> <b>ui.position</b> - current position of the draggable helper { top: , left: }</li>
|
||||
<li> <b>ui.offset</b> - current absolute position of the draggable helper { top: , left: }</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>UI Core</li>
|
||||
<li><a href="http://docs.jquery.com/UI/Draggable" title="UI/Draggable">UI Draggable</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="100">
|
||||
Makes the div droppable (a drop target for a draggable).<br />
|
||||
</p>
|
||||
<pre>$("#draggable").draggable();
|
||||
$("#droppable").droppable({
|
||||
drop: function() { alert('dropped'); }
|
||||
});
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
<style type="text/css">
|
||||
#draggable { width: 75px; height: 25px; background: silver; padding: 10px; }
|
||||
#droppable { position: absolute; left: 250px; top: 0; width: 125px; height: 75px; background: gray; color: white; padding: 10px; }
|
||||
</style>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("#draggable").draggable();
|
||||
$("#droppable").droppable({
|
||||
drop: function() { alert('dropped'); }
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<div id="droppable">Drop here</div>
|
||||
<div id="draggable">Drag me</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Options</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-disabled">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-disabled">disabled</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Disables (true) or enables (false) the droppable. Can be set when initialising (first creating) the droppable.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a droppable with the <code>disabled</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).droppable({ disabled: true });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>disabled</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var disabled = $( ".selector" ).droppable( "option", "disabled" );
|
||||
//setter
|
||||
$( ".selector" ).droppable( "option", "disabled", true );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-accept">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-accept">accept</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Selector, Function</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">'*'</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>All draggables that match the selector will be accepted. If a function is specified, the function will be called for each draggable on the page (passed as the first argument to the function), to provide a custom filter. The function should return true if the draggable should be accepted.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a droppable with the <code>accept</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).droppable({ accept: '.special' });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>accept</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var accept = $( ".selector" ).droppable( "option", "accept" );
|
||||
//setter
|
||||
$( ".selector" ).droppable( "option", "accept", '.special' );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-activeClass">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-activeClass">activeClass</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>If specified, the class will be added to the droppable while an acceptable draggable is being dragged.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a droppable with the <code>activeClass</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).droppable({ activeClass: 'ui-state-highlight' });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>activeClass</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var activeClass = $( ".selector" ).droppable( "option", "activeClass" );
|
||||
//setter
|
||||
$( ".selector" ).droppable( "option", "activeClass", 'ui-state-highlight' );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-addClasses">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-addClasses">addClasses</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">true</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>If set to false, will prevent the ui-droppable class from being added. This may be desired as a performance optimization when calling .droppable() init on many hundreds of elements.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a droppable with the <code>addClasses</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).droppable({ addClasses: false });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>addClasses</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var addClasses = $( ".selector" ).droppable( "option", "addClasses" );
|
||||
//setter
|
||||
$( ".selector" ).droppable( "option", "addClasses", false );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-greedy">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-greedy">greedy</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>If true, will prevent event propagation on nested droppables.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a droppable with the <code>greedy</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).droppable({ greedy: true });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>greedy</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var greedy = $( ".selector" ).droppable( "option", "greedy" );
|
||||
//setter
|
||||
$( ".selector" ).droppable( "option", "greedy", true );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-hoverClass">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-hoverClass">hoverClass</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>If specified, the class will be added to the droppable while an acceptable draggable is being hovered.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a droppable with the <code>hoverClass</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).droppable({ hoverClass: 'drophover' });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>hoverClass</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var hoverClass = $( ".selector" ).droppable( "option", "hoverClass" );
|
||||
//setter
|
||||
$( ".selector" ).droppable( "option", "hoverClass", 'drophover' );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-scope">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-scope">scope</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">'default'</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Used to group sets of draggable and droppable items, in addition to droppable's accept option. A draggable with the same scope value as a droppable will be accepted.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a droppable with the <code>scope</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).droppable({ scope: 'tasks' });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>scope</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var scope = $( ".selector" ).droppable( "option", "scope" );
|
||||
//setter
|
||||
$( ".selector" ).droppable( "option", "scope", 'tasks' );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-tolerance">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-tolerance">tolerance</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">'intersect'</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Specifies which mode to use for testing whether a draggable is 'over' a droppable. Possible values: 'fit', 'intersect', 'pointer', 'touch'.
|
||||
</p>
|
||||
<ul>
|
||||
<li><b>fit</b>: draggable overlaps the droppable entirely</li>
|
||||
<li><b>intersect</b>: draggable overlaps the droppable at least 50%</li>
|
||||
<li><b>pointer</b>: mouse pointer overlaps the droppable</li>
|
||||
<li><b>touch</b>: draggable overlaps the droppable any amount</li>
|
||||
</ul>
|
||||
<p></p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a droppable with the <code>tolerance</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).droppable({ tolerance: 'fit' });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>tolerance</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var tolerance = $( ".selector" ).droppable( "option", "tolerance" );
|
||||
//setter
|
||||
$( ".selector" ).droppable( "option", "tolerance", 'fit' );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="events">
|
||||
<h2 class="top-header">Events</h2>
|
||||
<ul class="events-list">
|
||||
|
||||
<li class="event" id="event-activate">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-activate">activate</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">dropactivate</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered any time an accepted draggable starts dragging. This can be useful if you want to make the droppable 'light up' when it can be dropped on.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>activate</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).droppable({
|
||||
activate: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>activate</code> event by type: <code>dropactivate</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "dropactivate", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-deactivate">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-deactivate">deactivate</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">dropdeactivate</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered any time an accepted draggable stops dragging.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>deactivate</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).droppable({
|
||||
deactivate: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>deactivate</code> event by type: <code>dropdeactivate</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "dropdeactivate", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-over">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-over">over</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">dropover</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered as an accepted draggable is dragged 'over' (within the tolerance of) this droppable.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>over</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).droppable({
|
||||
over: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>over</code> event by type: <code>dropover</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "dropover", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-out">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-out">out</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">dropout</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered when an accepted draggable is dragged out (within the tolerance of) this droppable.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>out</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).droppable({
|
||||
out: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>out</code> event by type: <code>dropout</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "dropout", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-drop">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-drop">drop</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">drop</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered when an accepted draggable is dropped 'over' (within the tolerance of) this droppable. In the callback, $(this) represents the droppable the draggable is dropped on.
|
||||
ui.draggable represents the draggable.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>drop</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).droppable({
|
||||
drop: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>drop</code> event by type: <code>drop</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "drop", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="methods">
|
||||
<h2 class="top-header">Methods</h2>
|
||||
<ul class="methods-list">
|
||||
|
||||
<li class="method" id="method-destroy">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-destroy">destroy</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.droppable( "destroy"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Remove the droppable functionality completely. This will return the element back to its pre-init state.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-disable">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-disable">disable</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.droppable( "disable"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Disable the droppable.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-enable">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-enable">enable</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.droppable( "enable"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Enable the droppable.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-option">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-option">option</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.droppable( "option"
|
||||
|
||||
, optionName
|
||||
|
||||
, <span class="optional">[</span>value<span class="optional">] </span>
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Get or set any droppable option. If no value is specified, will act as a getter.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-option">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-option">option</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.droppable( "option"
|
||||
|
||||
, options
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Set multiple droppable options at once by providing an options object.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-widget">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-widget">widget</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.droppable( "widget"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Returns the .ui-droppable element.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="theming">
|
||||
<h2 class="top-header">Theming</h2>
|
||||
<p>The jQuery UI Droppable plugin uses the jQuery UI CSS Framework to style its look and feel, including colors and background textures. We recommend using the ThemeRoller tool to create and download custom themes that are easy to build and maintain.
|
||||
</p>
|
||||
<p>If a deeper level of customization is needed, there are widget-specific classes referenced within the jquery.ui.droppable.css stylesheet that can be modified. These classes are highlighed in bold below.
|
||||
</p>
|
||||
|
||||
<h3>Sample markup with jQuery UI CSS Framework classes</h3>
|
||||
<div class="<strong>ui-droppable</strong>"></div>
|
||||
<p class="theme-note">
|
||||
<strong>
|
||||
Note: This is a sample of markup generated by the droppable plugin, not markup you should use to create a droppable. The only markup needed for that is <div></div>.
|
||||
</strong>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 32197 bytes
|
||||
Post-expand include size: 50778 bytes
|
||||
Template argument size: 26267 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:3769-1!1!0!!en!2 and timestamp 20100520115456 -->
|
||||
143
include/jquery-ui/development-bundle/docs/effect.html
Normal file
143
include/jquery-ui/development-bundle/docs/effect.html
Normal file
@@ -0,0 +1,143 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Arguments</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI effect</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<div class="editsection" style="float:right;margin-left:5px;">[<a href="http://docs.jquery.com/action/edit/UI/Effects/effect?section=1" title="Edit section: effect( effect, [options], [speed], [callback] )">edit</a>]</div><a name="effect.28_effect.2C_.5Boptions.5D.2C_.5Bspeed.5D.2C_.5Bcallback.5D_.29"></a><h3>effect( effect, <span class="optional">[</span>options<span class="optional">]</span>, <span class="optional">[</span>speed<span class="optional">]</span>, <span class="optional">[</span>callback<span class="optional">]</span> )</h3>
|
||||
<p>Uses a specific effect on an element (without the show/hide logic).</p>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>Effects Core</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="170">
|
||||
Apply the effect explode if you click on the element.<br />
|
||||
</p>
|
||||
<pre>$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$("div").<strong class="selflink">effect</strong>("explode");
|
||||
});
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
<script src="http://ui.jquery.com/latest/ui/effects.core.js"></script>
|
||||
<script src="http://ui.jquery.com/latest/ui/effects.explode.js"></script>
|
||||
<style type="text/css">
|
||||
div { margin: 0 auto; width: 100px; height: 80px; background: blue; position: relative; }
|
||||
</style>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$("div").<strong class="selflink">effect</strong>("explode");
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<p>Click me</p><div></div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Arguments</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-effect">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-effect">effect</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>The effect to be used. Possible values: 'blind', 'bounce', 'clip', 'drop', 'explode', 'fold', 'highlight', 'puff', 'pulsate', 'scale', 'shake', 'size', 'slide', 'transfer'.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-options">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-options">options</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Hash</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A object/hash including specific options for the effect.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-speed">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-speed">speed</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String, Number</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A string representing one of the three predefined speeds ("slow", "normal", or "fast") or the number of milliseconds to run the animation (e.g. 1000).</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-callback">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-callback">callback</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Function</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A function that is called after the effect is completed.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 6342 bytes
|
||||
Post-expand include size: 8648 bytes
|
||||
Template argument size: 5428 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:2612-1!1!0!!en!2 and timestamp 20100519131045 -->
|
||||
144
include/jquery-ui/development-bundle/docs/hide.html
Normal file
144
include/jquery-ui/development-bundle/docs/hide.html
Normal file
@@ -0,0 +1,144 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Arguments</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI hide</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<div class="editsection" style="float:right;margin-left:5px;">[<a href="http://docs.jquery.com/action/edit/UI/Effects/hide?section=1" title="Edit section: hide( effect, [options], [speed], [callback] )">edit</a>]</div><a name="hide.28_effect.2C_.5Boptions.5D.2C_.5Bspeed.5D.2C_.5Bcallback.5D_.29"></a><h3>hide( effect, <span class="optional">[</span>options<span class="optional">]</span>, <span class="optional">[</span>speed<span class="optional">]</span>, <span class="optional">[</span>callback<span class="optional">]</span> )</h3>
|
||||
<p>The enhanced hide method optionally accepts jQuery UI advanced effects.</p>
|
||||
<p>Uses a specific effect on an element to hide the element if the first argument is an effect string.</p>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>Effects Core</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="170">
|
||||
Apply the effect slide if you click on the p to hide a div.<br />
|
||||
</p>
|
||||
<pre>$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$("div").<strong class="selflink">hide</strong>("slide", {}, 1000);
|
||||
});
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
<script src="http://ui.jquery.com/latest/ui/effects.core.js"></script>
|
||||
<script src="http://ui.jquery.com/latest/ui/effects.slide.js"></script>
|
||||
<style type="text/css">
|
||||
div { margin: 0px; width: 100px; height: 80px; background: blue; position: relative; }
|
||||
</style>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$("div").<strong class="selflink">hide</strong>("slide", {}, 1000);
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<p>Click me</p><div></div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Arguments</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-effect">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-effect">effect</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>The effect to be used. Possible values: 'blind', 'clip', 'drop', 'explode', 'fold', 'puff', 'slide', 'scale', 'size', 'pulsate'.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-options">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-options">options</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Hash</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A object/hash including specific options for the effect.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-speed">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-speed">speed</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String, Number</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A string representing one of the three predefined speeds ("slow", "normal", or "fast") or the number of milliseconds to run the animation (e.g. 1000).</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-callback">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-callback">callback</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Function</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A function that is called after the effect is completed.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 6332 bytes
|
||||
Post-expand include size: 8629 bytes
|
||||
Template argument size: 5417 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:2614-1!1!0!!en!2 and timestamp 20100520040645 -->
|
||||
226
include/jquery-ui/development-bundle/docs/position.html
Normal file
226
include/jquery-ui/development-bundle/docs/position.html
Normal file
@@ -0,0 +1,226 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Arguments</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI Position Utility</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<p>Utility script for absolutely positioning any widget relative to the window, document, a particular element, or the cursor/mouse.</p>
|
||||
<p>Do not need ui.core.js or effects.core.js.</p>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li><i>none (only jQuery core)</i></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="300">
|
||||
Clicking on the green element transfers to the other.<br />
|
||||
</p>
|
||||
<pre>
|
||||
$("#position1").position({
|
||||
my: "center",
|
||||
at: "center",
|
||||
of: "#targetElement"
|
||||
});
|
||||
$("#position2").position({
|
||||
my: "left top",
|
||||
at: "left top",
|
||||
of: "#targetElement"
|
||||
});
|
||||
$("#position3").position({
|
||||
my: "right center",
|
||||
at: "right bottom",
|
||||
of: "#targetElement"
|
||||
});
|
||||
$(document).mousemove(function(ev){
|
||||
$("#position4").position({
|
||||
my: "left bottom",
|
||||
of: ev,
|
||||
offset: "3 -3",
|
||||
collision: "fit"
|
||||
});
|
||||
});
|
||||
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
<style type="text/css">
|
||||
#targetElement { width:240px;height:200px;background-color:#999;margin:30px auto; }
|
||||
.positionDiv { width:50px;height:50px;opacity:0.6; }
|
||||
#position1 {background-color:#F00;}
|
||||
#position2 {background-color:#0F0;}
|
||||
#position3 {background-color:#00F;}
|
||||
#position4 {background-color:#FF0;}
|
||||
</style>
|
||||
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
|
||||
$("#position1").position({
|
||||
my: "center",
|
||||
at: "center",
|
||||
of: "#targetElement"
|
||||
});
|
||||
$("#position2").position({
|
||||
my: "left top",
|
||||
at: "left top",
|
||||
of: "#targetElement"
|
||||
});
|
||||
$("#position3").position({
|
||||
my: "right center",
|
||||
at: "right bottom",
|
||||
of: "#targetElement"
|
||||
});
|
||||
$(document).mousemove(function(ev){
|
||||
$("#position4").position({
|
||||
my: "left bottom",
|
||||
of: ev,
|
||||
offset: "3 -3",
|
||||
collision: "fit"
|
||||
});
|
||||
});
|
||||
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<div id="targetElement">
|
||||
<div class="positionDiv" id="position1"></div>
|
||||
<div class="positionDiv" id="position2"></div>
|
||||
<div class="positionDiv" id="position3"></div>
|
||||
<div class="positionDiv" id="position4"></div>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Arguments</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-my">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-my">my</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Defines which position on <b>the element being positioned</b> to align with the target element: "horizontal vertical" alignment. A single value such as "right" will default to "right center", "top" will default to "center top" (following CSS convention). Acceptable values: "top", "center", "bottom", "left", "right". Example: "left top" or "center center"</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-at">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-at">at</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Defines which position on <b>the target element</b> to align the positioned element against: "horizontal vertical" alignment. A single value such as "right" will default to "right center", "top" will default to "center top" (following CSS convention). Acceptable values: "top", "center", "bottom", "left", "right". Example: "left top" or "center center"</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-of">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-of">of</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Selector</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Element to position against. You can use a browser event object contains pageX and pageY values. Example: "#top-menu"</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-offset">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-offset">offset</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Add these left-top values to the calculated position, eg. "50 50" (left top) A single value such as "50" will apply to both.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-collision">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-collision">collision</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>When the positioned element overflows the window in some direction, move it to an alternative position. Similar to my and at, this accepts a single value or a pair for horizontal/vertical, eg. "flip", "fit", "fit flip", "fit none".
|
||||
</p>
|
||||
<ul><li> <b>flip</b>: to the opposite side and the collision detection is run again to see if it will fit. If it won't fit in either position, the center option should be used as a fall back.
|
||||
</li><li> <b>fit</b>: so the element keeps in the desired direction, but is re-positioned so it fits.
|
||||
</li><li> <b>none</b>: not do collision detection.
|
||||
</li></ul>
|
||||
<p></p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-using">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-using">using</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Function</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>When specified the actual property setting is delegated to this callback. Receives a single parameter which is a hash of top and left values for the position that should be set.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 7124 bytes
|
||||
Post-expand include size: 10613 bytes
|
||||
Template argument size: 7243 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:3784-1!1!0!!en!2 and timestamp 20100520115504 -->
|
||||
381
include/jquery-ui/development-bundle/docs/progressbar.html
Normal file
381
include/jquery-ui/development-bundle/docs/progressbar.html
Normal file
@@ -0,0 +1,381 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Options</a></li>
|
||||
<li><a href="#events">Events</a></li>
|
||||
<li><a href="#methods">Methods</a></li>
|
||||
<li><a href="#theming">Theming</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI Progressbar</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<p>
|
||||
The progress bar is designed to simply display the current % complete for a process. The bar is coded to be flexibly sized through CSS and will scale to fit inside it's parent container by default.
|
||||
</p>
|
||||
<p>
|
||||
This is a determinate progress bar, meaning that it should only be used in situations where the system can accurately update the current status complete. A determinate progress bar should never fill from left to right, then loop back to empty for a single process -- if the actual percent complete status cannot be calculated, an indeterminate progress bar (coming soon) or spinner animation is a better way to provide user feedback.
|
||||
</p>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>UI Core</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="100">
|
||||
A simple jQuery UI Progressbar.<br />
|
||||
</p>
|
||||
<pre>$("#progressbar").progressbar({ value: 37 });
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("#progressbar").progressbar({ value: 37 });
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<div id="progressbar"></div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Options</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-disabled">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-disabled">disabled</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Disables (true) or enables (false) the progressbar. Can be set when initialising (first creating) the progressbar.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a progressbar with the <code>disabled</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).progressbar({ disabled: true });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>disabled</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var disabled = $( ".selector" ).progressbar( "option", "disabled" );
|
||||
//setter
|
||||
$( ".selector" ).progressbar( "option", "disabled", true );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-value">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-value">value</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Number</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">0</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>The value of the progressbar.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a progressbar with the <code>value</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).progressbar({ value: 37 });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>value</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var value = $( ".selector" ).progressbar( "option", "value" );
|
||||
//setter
|
||||
$( ".selector" ).progressbar( "option", "value", 37 );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="events">
|
||||
<h2 class="top-header">Events</h2>
|
||||
<ul class="events-list">
|
||||
|
||||
<li class="event" id="event-change">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-change">change</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">progressbarchange</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered when the value of the progressbar changes.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>change</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).progressbar({
|
||||
change: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>change</code> event by type: <code>progressbarchange</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "progressbarchange", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="methods">
|
||||
<h2 class="top-header">Methods</h2>
|
||||
<ul class="methods-list">
|
||||
|
||||
<li class="method" id="method-destroy">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-destroy">destroy</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.progressbar( "destroy"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Remove the progressbar functionality completely. This will return the element back to its pre-init state.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-disable">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-disable">disable</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.progressbar( "disable"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Disable the progressbar.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-enable">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-enable">enable</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.progressbar( "enable"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Enable the progressbar.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-option">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-option">option</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.progressbar( "option"
|
||||
|
||||
, optionName
|
||||
|
||||
, <span class="optional">[</span>value<span class="optional">] </span>
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Get or set any progressbar option. If no value is specified, will act as a getter.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-option">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-option">option</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.progressbar( "option"
|
||||
|
||||
, options
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Set multiple progressbar options at once by providing an options object.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-widget">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-widget">widget</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.progressbar( "widget"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Returns the .ui-progressbar element.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-value">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-value">value</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.progressbar( "value"
|
||||
|
||||
, <span class="optional">[</span>value<span class="optional">] </span>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>This method gets or sets the current value of the progressbar.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="theming">
|
||||
<h2 class="top-header">Theming</h2>
|
||||
<p>The jQuery UI Progressbar plugin uses the jQuery UI CSS Framework to style its look and feel, including colors and background textures. We recommend using the ThemeRoller tool to create and download custom themes that are easy to build and maintain.
|
||||
</p>
|
||||
<p>If a deeper level of customization is needed, there are widget-specific classes referenced within the jquery.ui.progressbar.css stylesheet that can be modified. These classes are highlighed in bold below.
|
||||
</p>
|
||||
|
||||
<h3>Sample markup with jQuery UI CSS Framework classes</h3>
|
||||
<div class="<strong>ui-progressbar </strong>ui-widget ui-widget-content ui-corner-all"><br />
|
||||
<div style="width: 37%;" class="<strong>ui-progressbar-value</strong> ui-widget-header ui-corner-left"></div><br />
|
||||
</div>
|
||||
<p class="theme-note">
|
||||
<strong>
|
||||
Note: This is a sample of markup generated by the progressbar plugin, not markup you should use to create a progressbar. The only markup needed for that is <div></div>.
|
||||
</strong>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 18800 bytes
|
||||
Post-expand include size: 21667 bytes
|
||||
Template argument size: 8533 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:3780-1!1!0!!en!2 and timestamp 20100520101523 -->
|
||||
113
include/jquery-ui/development-bundle/docs/removeClass.html
Normal file
113
include/jquery-ui/development-bundle/docs/removeClass.html
Normal file
@@ -0,0 +1,113 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Arguments</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI removeClass</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<div class="editsection" style="float:right;margin-left:5px;">[<a href="http://docs.jquery.com/action/edit/UI/Effects/removeClass?section=1" title="Edit section: removeClass( [class], [duration] )">edit</a>]</div><a name="removeClass.28_.5Bclass.5D.2C_.5Bduration.5D_.29"></a><h3>removeClass( <span class="optional">[</span>class<span class="optional">]</span>, <span class="optional">[</span>duration<span class="optional">]</span> )</h3>
|
||||
<p>Removes all or specified class from each of the set of matched elements with an optional transition between the states.</p>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>Effects Core</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="100">
|
||||
Removes the class 'selected' from the matched elements with a one second transition.<br />
|
||||
</p>
|
||||
<pre>$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$(this).<strong class="selflink">removeClass</strong>("selected", 1000);
|
||||
});
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
<script src="http://ui.jquery.com/latest/ui/effects.core.js"></script>
|
||||
<style type="text/css">
|
||||
p { cursor: pointer; font-size: 1.2em; }
|
||||
.selected { color:red; }
|
||||
</style>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$(this).<strong class="selflink">removeClass</strong>("selected", 1000);
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<p class="selected">Click me to remove 'selected' class.</p>
|
||||
<p class="selected">Click me to remove 'selected' class.</p>
|
||||
<p class="selected">Click me to remove 'selected' class.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Arguments</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-class">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-class">class</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>CSS classes to remove from the elements.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-duration">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-duration">duration</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String, Number</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A string representing one of the three predefined speeds ("slow", "normal", or "fast") or the number of milliseconds to run the animation (e.g. 1000).</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 5276 bytes
|
||||
Post-expand include size: 7063 bytes
|
||||
Template argument size: 4443 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:2607-1!1!0!!en!2 and timestamp 20100519165547 -->
|
||||
1160
include/jquery-ui/development-bundle/docs/resizable.html
Normal file
1160
include/jquery-ui/development-bundle/docs/resizable.html
Normal file
File diff suppressed because it is too large
Load Diff
807
include/jquery-ui/development-bundle/docs/selectable.html
Normal file
807
include/jquery-ui/development-bundle/docs/selectable.html
Normal file
@@ -0,0 +1,807 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Options</a></li>
|
||||
<li><a href="#events">Events</a></li>
|
||||
<li><a href="#methods">Methods</a></li>
|
||||
<li><a href="#theming">Theming</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI Selectable</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<p>The jQuery UI Selectable plugin allows for elements to be selected by dragging a box (sometimes called a lasso) with the mouse over the elements. Also, elements can be selected by click or drag while holding the Ctrl/Meta key, allowing for multiple (non-contiguous) selections.</p>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>UI Core</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="">
|
||||
A simple jQuery UI Selectable.<br />
|
||||
</p>
|
||||
<pre>$("#selectable").selectable();
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
<style type="text/css">
|
||||
#selectable .ui-selecting {
|
||||
background: silver;
|
||||
}
|
||||
#selectable .ui-selected {
|
||||
background: gray;
|
||||
}
|
||||
</style>
|
||||
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("#selectable").selectable();
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<ul id="selectable">
|
||||
<li>Item 1</li>
|
||||
<li>Item 2</li>
|
||||
<li>Item 3</li>
|
||||
<li>Item 4</li>
|
||||
<li>Item 5</li>
|
||||
</ul>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Options</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-disabled">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-disabled">disabled</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Disables (true) or enables (false) the selectable. Can be set when initialising (first creating) the selectable.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a selectable with the <code>disabled</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).selectable({ disabled: true });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>disabled</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var disabled = $( ".selector" ).selectable( "option", "disabled" );
|
||||
//setter
|
||||
$( ".selector" ).selectable( "option", "disabled", true );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-autoRefresh">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-autoRefresh">autoRefresh</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">true</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>This determines whether to refresh (recalculate) the position and size of each selectee at the beginning of each select operation. If you have many many items, you may want to set this to false and call the refresh method manually.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a selectable with the <code>autoRefresh</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).selectable({ autoRefresh: false });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>autoRefresh</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var autoRefresh = $( ".selector" ).selectable( "option", "autoRefresh" );
|
||||
//setter
|
||||
$( ".selector" ).selectable( "option", "autoRefresh", false );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-cancel">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-cancel">cancel</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Selector</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">':input,option'</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Prevents selecting if you start on elements matching the selector.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a selectable with the <code>cancel</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).selectable({ cancel: ':input,option' });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>cancel</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var cancel = $( ".selector" ).selectable( "option", "cancel" );
|
||||
//setter
|
||||
$( ".selector" ).selectable( "option", "cancel", ':input,option' );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-delay">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-delay">delay</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Integer</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">0</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Time in milliseconds to define when the selecting should start. It helps preventing unwanted selections when clicking on an element.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a selectable with the <code>delay</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).selectable({ delay: 20 });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>delay</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var delay = $( ".selector" ).selectable( "option", "delay" );
|
||||
//setter
|
||||
$( ".selector" ).selectable( "option", "delay", 20 );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-distance">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-distance">distance</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Integer</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">0</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Tolerance, in pixels, for when selecting should start. If specified, selecting will not start until after mouse is dragged beyond distance.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a selectable with the <code>distance</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).selectable({ distance: 20 });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>distance</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var distance = $( ".selector" ).selectable( "option", "distance" );
|
||||
//setter
|
||||
$( ".selector" ).selectable( "option", "distance", 20 );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-filter">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-filter">filter</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Selector</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">'*'</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>The matching child elements will be made selectees (able to be selected).</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a selectable with the <code>filter</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).selectable({ filter: 'li' });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>filter</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var filter = $( ".selector" ).selectable( "option", "filter" );
|
||||
//setter
|
||||
$( ".selector" ).selectable( "option", "filter", 'li' );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-tolerance">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-tolerance">tolerance</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">'touch'</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Possible values: 'touch', 'fit'.
|
||||
</p>
|
||||
<ul>
|
||||
<li><b>fit</b>: draggable overlaps the droppable entirely</li>
|
||||
<li><b>touch</b>: draggable overlaps the droppable any amount</li>
|
||||
</ul>
|
||||
<p></p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a selectable with the <code>tolerance</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).selectable({ tolerance: 'fit' });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>tolerance</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var tolerance = $( ".selector" ).selectable( "option", "tolerance" );
|
||||
//setter
|
||||
$( ".selector" ).selectable( "option", "tolerance", 'fit' );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="events">
|
||||
<h2 class="top-header">Events</h2>
|
||||
<ul class="events-list">
|
||||
|
||||
<li class="event" id="event-selected">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-selected">selected</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">selectableselected</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered at the end of the select operation, on each element added to the selection.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>selected</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).selectable({
|
||||
selected: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>selected</code> event by type: <code>selectableselected</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "selectableselected", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-selecting">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-selecting">selecting</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">selectableselecting</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered during the select operation, on each element added to the selection.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>selecting</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).selectable({
|
||||
selecting: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>selecting</code> event by type: <code>selectableselecting</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "selectableselecting", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-start">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-start">start</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">selectablestart</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered at the beginning of the select operation.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>start</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).selectable({
|
||||
start: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>start</code> event by type: <code>selectablestart</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "selectablestart", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-stop">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-stop">stop</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">selectablestop</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered at the end of the select operation.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>stop</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).selectable({
|
||||
stop: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>stop</code> event by type: <code>selectablestop</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "selectablestop", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-unselected">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-unselected">unselected</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">selectableunselected</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered at the end of the select operation, on each element removed from the selection.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>unselected</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).selectable({
|
||||
unselected: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>unselected</code> event by type: <code>selectableunselected</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "selectableunselected", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-unselecting">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-unselecting">unselecting</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">selectableunselecting</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered during the select operation, on each element removed from the selection.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>unselecting</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).selectable({
|
||||
unselecting: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>unselecting</code> event by type: <code>selectableunselecting</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "selectableunselecting", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="methods">
|
||||
<h2 class="top-header">Methods</h2>
|
||||
<ul class="methods-list">
|
||||
|
||||
<li class="method" id="method-destroy">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-destroy">destroy</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.selectable( "destroy"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Remove the selectable functionality completely. This will return the element back to its pre-init state.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-disable">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-disable">disable</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.selectable( "disable"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Disable the selectable.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-enable">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-enable">enable</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.selectable( "enable"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Enable the selectable.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-option">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-option">option</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.selectable( "option"
|
||||
|
||||
, optionName
|
||||
|
||||
, <span class="optional">[</span>value<span class="optional">] </span>
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Get or set any selectable option. If no value is specified, will act as a getter.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-option">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-option">option</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.selectable( "option"
|
||||
|
||||
, options
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Set multiple selectable options at once by providing an options object.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-widget">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-widget">widget</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.selectable( "widget"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Returns the .ui-selectable element.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-refresh">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-refresh">refresh</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.selectable( "refresh"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Refresh the position and size of each selectee element. This method can be used to manually recalculate the position and size of each selectee element. Very useful if autoRefresh is set to false.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="theming">
|
||||
<h2 class="top-header">Theming</h2>
|
||||
<p>The jQuery UI Selectable plugin uses the jQuery UI CSS Framework to style its look and feel, including colors and background textures. We recommend using the ThemeRoller tool to create and download custom themes that are easy to build and maintain.
|
||||
</p>
|
||||
<p>If a deeper level of customization is needed, there are widget-specific classes referenced within the jquery.ui.selectable.css stylesheet that can be modified. These classes are highlighed in bold below.
|
||||
</p>
|
||||
|
||||
<h3>Sample markup with jQuery UI CSS Framework classes</h3>
|
||||
<ul class="<strong>ui-selectable</strong>"><br />
|
||||
   <li class="<strong>ui-selectee</strong>"></li><br />
|
||||
   <li class="<strong>ui-selectee</strong>"></li><br />
|
||||
   <li class="<strong>ui-selectee</strong>"></li><br />
|
||||
</ul>
|
||||
<p class="theme-note">
|
||||
<strong>
|
||||
Note: This is a sample of markup generated by the selectable plugin, not markup you should use to create a selectable. The only markup needed for that is <br /><ul><br />
|
||||
   <li></li><br />
|
||||
   <li></li><br />
|
||||
   <li></li><br />
|
||||
</ul>.
|
||||
</strong>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 33182 bytes
|
||||
Post-expand include size: 51437 bytes
|
||||
Template argument size: 26605 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:3771-1!1!0!!en!2 and timestamp 20100520115458 -->
|
||||
144
include/jquery-ui/development-bundle/docs/show.html
Normal file
144
include/jquery-ui/development-bundle/docs/show.html
Normal file
@@ -0,0 +1,144 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Arguments</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI show</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<div class="editsection" style="float:right;margin-left:5px;">[<a href="http://docs.jquery.com/action/edit/UI/Effects/show?section=1" title="Edit section: show( effect, [options], [speed], [callback] )">edit</a>]</div><a name="show.28_effect.2C_.5Boptions.5D.2C_.5Bspeed.5D.2C_.5Bcallback.5D_.29"></a><h3>show( effect, <span class="optional">[</span>options<span class="optional">]</span>, <span class="optional">[</span>speed<span class="optional">]</span>, <span class="optional">[</span>callback<span class="optional">]</span> )</h3>
|
||||
<p>The enhanced show method optionally accepts jQuery UI advanced effects.</p>
|
||||
<p>Uses a specific effect on an element to show the element if the first argument is a effect string.</p>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>Effects Core</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="170">
|
||||
Apply the effect slide if you click on the p to show a div.<br />
|
||||
</p>
|
||||
<pre>$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$("div").<strong class="selflink">show</strong>("slide", {}, 1000);
|
||||
});
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
<script src="http://ui.jquery.com/latest/ui/effects.core.js"></script>
|
||||
<script src="http://ui.jquery.com/latest/ui/effects.slide.js"></script>
|
||||
<style type="text/css">
|
||||
div { display: none; margin: 0px; width: 100px; height: 80px; background: blue; position: relative; }
|
||||
</style>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$("div").<strong class="selflink">show</strong>("slide", {}, 1000);
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<p>Click me</p><div></div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Arguments</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-effect">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-effect">effect</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>The effect to be used. Possible values: 'blind', 'clip', 'drop', 'explode', 'fold', 'puff', 'slide', 'scale', 'size', 'pulsate'.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-options">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-options">options</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Hash</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A object/hash including specific options for the effect.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-speed">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-speed">speed</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String, Number</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A string representing one of the three predefined speeds ("slow", "normal", or "fast") or the number of milliseconds to run the animation (e.g. 1000).</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-callback">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-callback">callback</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Function</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A function that is called after the effect is completed.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 6354 bytes
|
||||
Post-expand include size: 8760 bytes
|
||||
Template argument size: 5486 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:2613-1!1!0!!en!2 and timestamp 20100519132310 -->
|
||||
821
include/jquery-ui/development-bundle/docs/slider.html
Normal file
821
include/jquery-ui/development-bundle/docs/slider.html
Normal file
@@ -0,0 +1,821 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Options</a></li>
|
||||
<li><a href="#events">Events</a></li>
|
||||
<li><a href="#methods">Methods</a></li>
|
||||
<li><a href="#theming">Theming</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI Slider</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<p>The jQuery UI Slider plugin makes selected elements into sliders. There are various options such as multiple handles, and ranges. The handle can be moved with the mouse or the arrow keys.</p>
|
||||
<p>All callbacks receive two arguments: The original browser event and a prepared ui object, view below for a documentation of this object (if you name your second argument 'ui'):
|
||||
</p><p>The slider widget will create handle elements with the class 'ui-slider-handle' on initialization. You can specify custom handle elements by creating and appending the elements and adding the 'ui-slider-handle' class before init. It will only create the number of handles needed to match the length of value/values. For example, if you specify 'values: [1, 5, 18]' and create one custom handle, the plugin will create the other two.
|
||||
</p>
|
||||
<ul>
|
||||
<li><b>ui.handle</b>: DOMElement - the current focused handle
|
||||
<li><b>ui.value</b>: Integer - the current handle's value
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>UI Core</li>
|
||||
<li>UI Widget</li>
|
||||
<li>UI Mouse</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="">
|
||||
A simple jQuery UI Slider.<br />
|
||||
</p>
|
||||
<pre>$("#slider").slider();
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
<style type="text/css">
|
||||
#slider { margin: 10px; }
|
||||
</style>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("#slider").slider();
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<div id="slider"></div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Options</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-disabled">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-disabled">disabled</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Disables (true) or enables (false) the slider. Can be set when initialising (first creating) the slider.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a slider with the <code>disabled</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).slider({ disabled: true });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>disabled</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var disabled = $( ".selector" ).slider( "option", "disabled" );
|
||||
//setter
|
||||
$( ".selector" ).slider( "option", "disabled", true );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-animate">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-animate">animate</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean, String, Number</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Whether to slide handle smoothly when user click outside handle on the bar. Will also accept a string representing one of the three predefined speeds ("slow", "normal", or "fast") or the number of milliseconds to run the animation (e.g. 1000).</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a slider with the <code>animate</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).slider({ animate: true });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>animate</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var animate = $( ".selector" ).slider( "option", "animate" );
|
||||
//setter
|
||||
$( ".selector" ).slider( "option", "animate", true );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-max">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-max">max</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Number</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">100</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>The maximum value of the slider.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a slider with the <code>max</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).slider({ max: 7 });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>max</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var max = $( ".selector" ).slider( "option", "max" );
|
||||
//setter
|
||||
$( ".selector" ).slider( "option", "max", 7 );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-min">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-min">min</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Number</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">0</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>The minimum value of the slider.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a slider with the <code>min</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).slider({ min: -7 });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>min</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var min = $( ".selector" ).slider( "option", "min" );
|
||||
//setter
|
||||
$( ".selector" ).slider( "option", "min", -7 );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-orientation">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-orientation">orientation</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">'horizontal'</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>This option determines whether the slider has the min at the left, the max at the right or the min at the bottom, the max at the top. Possible values: 'horizontal', 'vertical'.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a slider with the <code>orientation</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).slider({ orientation: 'vertical' });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>orientation</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var orientation = $( ".selector" ).slider( "option", "orientation" );
|
||||
//setter
|
||||
$( ".selector" ).slider( "option", "orientation", 'vertical' );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-range">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-range">range</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Boolean, String</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">false</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>If set to true, the slider will detect if you have two handles and create a stylable range element between these two. Two other possible values are 'min' and 'max'. A min range goes from the slider min to one handle. A max range goes from one handle to the slider max.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a slider with the <code>range</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).slider({ range: 'min' });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>range</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var range = $( ".selector" ).slider( "option", "range" );
|
||||
//setter
|
||||
$( ".selector" ).slider( "option", "range", 'min' );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-step">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-step">step</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Number</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">1</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Determines the size or amount of each interval or step the slider takes between min and max. The full specified value range of the slider (max - min) needs to be evenly divisible by the step.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a slider with the <code>step</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).slider({ step: 5 });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>step</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var step = $( ".selector" ).slider( "option", "step" );
|
||||
//setter
|
||||
$( ".selector" ).slider( "option", "step", 5 );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-value">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-value">value</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Number</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">0</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Determines the value of the slider, if there's only one handle. If there is more than one handle, determines the value of the first handle.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a slider with the <code>value</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).slider({ value: 37 });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>value</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var value = $( ".selector" ).slider( "option", "value" );
|
||||
//setter
|
||||
$( ".selector" ).slider( "option", "value", 37 );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-values">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-values">values</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Array</dd>
|
||||
|
||||
<dt class="option-default-label">Default:</dt>
|
||||
<dd class="option-default">null</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>This option can be used to specify multiple handles. If range is set to true, the length of 'values' should be 2.</p>
|
||||
</div>
|
||||
<div class="option-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="option-examples-list">
|
||||
|
||||
<dt>
|
||||
Initialize a slider with the <code>values</code> option specified.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).slider({ values: [1,5,9] });</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Get or set the <code>values</code> option, after init.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>//getter
|
||||
var values = $( ".selector" ).slider( "option", "values" );
|
||||
//setter
|
||||
$( ".selector" ).slider( "option", "values", [1,5,9] );</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="events">
|
||||
<h2 class="top-header">Events</h2>
|
||||
<ul class="events-list">
|
||||
|
||||
<li class="event" id="event-start">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-start">start</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">slidestart</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered when the user starts sliding.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>start</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).slider({
|
||||
start: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>start</code> event by type: <code>slidestart</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "slidestart", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-slide">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-slide">slide</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">slide</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered on every mouse move during slide. Use ui.value (single-handled sliders) to obtain the value of the current handle, $(..).slider('value', index) to get another handles' value.
|
||||
</p><p>Return false in order to prevent a slide, based on ui.value.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>slide</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).slider({
|
||||
slide: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>slide</code> event by type: <code>slide</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "slide", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-change">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-change">change</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">slidechange</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered on slide stop, or if the value is changed programmatically (by the <code>value</code> method). Takes arguments event and ui. Use event.orginalEvent to detect whether the value changed by mouse, keyboard, or programmatically. Use ui.value (single-handled sliders) to obtain the value of the current handle, $(this).slider('values', index) to get another handle's value.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>change</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).slider({
|
||||
change: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>change</code> event by type: <code>slidechange</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "slidechange", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="event" id="event-stop">
|
||||
<div class="event-header">
|
||||
<h3 class="event-name"><a href="#event-stop">stop</a></h3>
|
||||
<dl>
|
||||
<dt class="event-type-label">Type:</dt>
|
||||
<dd class="event-type">slidestop</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="event-description">
|
||||
<p>This event is triggered when the user stops sliding.</p>
|
||||
</div>
|
||||
<div class="event-examples">
|
||||
<h4>Code examples</h4>
|
||||
<dl class="event-examples-list">
|
||||
|
||||
<dt>
|
||||
Supply a callback function to handle the <code>stop</code> event as an init option.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).slider({
|
||||
stop: function(event, ui) { ... }
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
|
||||
<dt>
|
||||
Bind to the <code>stop</code> event by type: <code>slidestop</code>.
|
||||
</dt>
|
||||
<dd>
|
||||
<pre><code>$( ".selector" ).bind( "slidestop", function(event, ui) {
|
||||
...
|
||||
});</code></pre>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="methods">
|
||||
<h2 class="top-header">Methods</h2>
|
||||
<ul class="methods-list">
|
||||
|
||||
<li class="method" id="method-destroy">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-destroy">destroy</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.slider( "destroy"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Remove the slider functionality completely. This will return the element back to its pre-init state.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-disable">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-disable">disable</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.slider( "disable"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Disable the slider.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-enable">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-enable">enable</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.slider( "enable"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Enable the slider.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-option">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-option">option</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.slider( "option"
|
||||
|
||||
, optionName
|
||||
|
||||
, <span class="optional">[</span>value<span class="optional">] </span>
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Get or set any slider option. If no value is specified, will act as a getter.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-option">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-option">option</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.slider( "option"
|
||||
|
||||
, options
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Set multiple slider options at once by providing an options object.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-widget">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-widget">widget</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.slider( "widget"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Returns the .ui-slider element.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-value">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-value">value</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.slider( "value"
|
||||
|
||||
, <span class="optional">[</span>value<span class="optional">] </span>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Gets or sets the value of the slider. For single handle sliders.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="method" id="method-values">
|
||||
<div class="method-header">
|
||||
<h3 class="method-name"><a href="#method-values">values</a></h3>
|
||||
<dl>
|
||||
<dt class="method-signature-label">Signature:</dt>
|
||||
<dd class="method-signature">.slider( "values"
|
||||
|
||||
, index
|
||||
|
||||
, <span class="optional">[</span>value<span class="optional">] </span>
|
||||
|
||||
|
||||
|
||||
)</dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="method-description">
|
||||
<p>Gets or sets the values of the slider. For multiple handle or range sliders.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
<div id="theming">
|
||||
<h2 class="top-header">Theming</h2>
|
||||
<p>The jQuery UI Slider plugin uses the jQuery UI CSS Framework to style its look and feel, including colors and background textures. We recommend using the ThemeRoller tool to create and download custom themes that are easy to build and maintain.
|
||||
</p>
|
||||
<p>If a deeper level of customization is needed, there are widget-specific classes referenced within the jquery.ui.slider.css stylesheet that can be modified. These classes are highlighed in bold below.
|
||||
</p>
|
||||
|
||||
<h3>Sample markup with jQuery UI CSS Framework classes</h3>
|
||||
<div class="ui-slider<strong> ui-slider-horizontal</strong> ui-widget ui-widget-content ui-corner-all"><br />
|
||||
<a style="left: 0%;" class="<strong>ui-slider-handle</strong> ui-state-default ui-corner-all" href="#"></a><br />
|
||||
</div><br />
|
||||
<p class="theme-note">
|
||||
<strong>
|
||||
Note: This is a sample of markup generated by the slider plugin, not markup you should use to create a slider. The only markup needed for that is <div><div>.
|
||||
</strong>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 34930 bytes
|
||||
Post-expand include size: 52896 bytes
|
||||
Template argument size: 27114 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:3776-1!1!0!!en!2 and timestamp 20100520115503 -->
|
||||
1910
include/jquery-ui/development-bundle/docs/sortable.html
Normal file
1910
include/jquery-ui/development-bundle/docs/sortable.html
Normal file
File diff suppressed because it is too large
Load Diff
129
include/jquery-ui/development-bundle/docs/switchClass.html
Normal file
129
include/jquery-ui/development-bundle/docs/switchClass.html
Normal file
@@ -0,0 +1,129 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Arguments</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI switchClass</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<div class="editsection" style="float:right;margin-left:5px;">[<a href="http://docs.jquery.com/action/edit/UI/Effects/switchClass?section=1" title="Edit section: switchClass( remove, add, [duration] )">edit</a>]</div><a name="switchClass.28_remove.2C_add.2C_.5Bduration.5D_.29"></a><h3>switchClass( remove, add, <span class="optional">[</span>duration<span class="optional">]</span> )</h3>
|
||||
<p>Switches from the class defined in the first argument to the class defined as second argument, using an optional transition.</p>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>Effects Core</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="170">
|
||||
Switch the class 'highlight' to 'blue' when a paragraph is clicked with a one second transition.<br />
|
||||
</p>
|
||||
<pre>$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$(this).<strong class="selflink">switchClass</strong>("highlight", "blue", 1000);
|
||||
});
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
<script src="http://ui.jquery.com/latest/ui/effects.core.js"></script>
|
||||
<style type="text/css">
|
||||
p { margin: 4px; font-size:16px; font-weight:bolder;
|
||||
cursor:pointer; }
|
||||
.blue { background: blue; }
|
||||
.highlight { background:yellow; }
|
||||
</style>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$(this).<strong class="selflink">switchClass</strong>("highlight", "blue", 1000);
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<p class="highlight">Click to switch</p>
|
||||
<p class="highlight">to blue</p>
|
||||
<p class="highlight">on these</p>
|
||||
<p class="highlight">paragraphs</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Arguments</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-remove">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-remove">remove</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>The CSS class that will be removed.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-add">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-add">add</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>The CSS class that will be added.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-duration">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-duration">duration</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String, Number</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A string representing one of the three predefined speeds ("slow", "normal", or "fast") or the number of milliseconds to run the animation (e.g. 1000).</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 5818 bytes
|
||||
Post-expand include size: 7682 bytes
|
||||
Template argument size: 4812 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:2609-1!1!0!!en!2 and timestamp 20100519143320 -->
|
||||
1512
include/jquery-ui/development-bundle/docs/tabs.html
Normal file
1512
include/jquery-ui/development-bundle/docs/tabs.html
Normal file
File diff suppressed because it is too large
Load Diff
144
include/jquery-ui/development-bundle/docs/toggle.html
Normal file
144
include/jquery-ui/development-bundle/docs/toggle.html
Normal file
@@ -0,0 +1,144 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Arguments</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI toggle</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<div class="editsection" style="float:right;margin-left:5px;">[<a href="http://docs.jquery.com/action/edit/UI/Effects/toggle?section=1" title="Edit section: toggle( effect, [options], [speed], [callback] )">edit</a>]</div><a name="toggle.28_effect.2C_.5Boptions.5D.2C_.5Bspeed.5D.2C_.5Bcallback.5D_.29"></a><h3>toggle( effect, <span class="optional">[</span>options<span class="optional">]</span>, <span class="optional">[</span>speed<span class="optional">]</span>, <span class="optional">[</span>callback<span class="optional">]</span> )</h3>
|
||||
<p>The enhanced toggle method optionally accepts jQuery UI advanced effects.</p>
|
||||
<p>Uses a specific effect on an element to toggle the element if the first argument is an effect string.</p>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>Effects Core</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="170">
|
||||
Apply the effect slide if you click on the p to toggle a div.<br />
|
||||
</p>
|
||||
<pre>$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$("div").<strong class="selflink">toggle</strong>("slide", {}, 1000);
|
||||
});
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
<script src="http://ui.jquery.com/latest/ui/effects.core.js"></script>
|
||||
<script src="http://ui.jquery.com/latest/ui/effects.slide.js"></script>
|
||||
<style type="text/css">
|
||||
div { display: none; margin: 0px; width: 100px; height: 80px; background: blue; position: relative; }
|
||||
</style>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$("div").<strong class="selflink">toggle</strong>("slide", {}, 1000);
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<p>Click me</p><div></div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Arguments</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-effect">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-effect">effect</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>The effect to be used. Possible values: 'blind', 'clip', 'drop', 'explode', 'fold', 'puff', 'slide', 'scale', 'size', 'pulsate'.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-options">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-options">options</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Hash</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A object/hash including specific options for the effect.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-speed">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-speed">speed</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String, Number</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>Durations are given in milliseconds; higher values indicate slower animations, not faster ones. The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 milliseconds, respectively.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-callback">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-callback">callback</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">Function</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A function that is called after the effect is completed.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 6372 bytes
|
||||
Post-expand include size: 8945 bytes
|
||||
Template argument size: 5663 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:2615-1!1!0!!en!2 and timestamp 20100519142327 -->
|
||||
111
include/jquery-ui/development-bundle/docs/toggleClass.html
Normal file
111
include/jquery-ui/development-bundle/docs/toggleClass.html
Normal file
@@ -0,0 +1,111 @@
|
||||
|
||||
<ul class="UIAPIPlugin-toc">
|
||||
<li><a href="#overview">Overview</a></li>
|
||||
<li><a href="#options">Arguments</a></li>
|
||||
</ul>
|
||||
<div class="UIAPIPlugin">
|
||||
<h1>jQuery UI toggleClass</h1>
|
||||
<div id="overview">
|
||||
<h2 class="top-header">Overview</h2>
|
||||
<div id="overview-main">
|
||||
<div class="editsection" style="float:right;margin-left:5px;">[<a href="http://docs.jquery.com/action/edit/UI/Effects/toggleClass?section=1" title="Edit section: toggleClass( class, [duration] )">edit</a>]</div><a name="toggleClass.28_class.2C_.5Bduration.5D_.29"></a><h3>toggleClass( class, <span class="optional">[</span>duration<span class="optional">]</span> )</h3>
|
||||
<p>Adds the specified class if it is not present, and removes the specified class if it is present, using an optional transition.</p>
|
||||
</div>
|
||||
<div id="overview-dependencies">
|
||||
<h3>Dependencies</h3>
|
||||
<ul>
|
||||
<li>Effects Core</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="overview-example">
|
||||
<h3>Example</h3>
|
||||
<div id="overview-example" class="example">
|
||||
<ul><li><a href="#demo"><span>Demo</span></a></li><li><a href="#source"><span>View Source</span></a></li></ul>
|
||||
<p><div id="demo" class="tabs-container" rel="100">
|
||||
Adds the 'selected' class if it is not present, and removes the 'selected' class if it is present.<br />
|
||||
</p>
|
||||
<pre>$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$(this).<strong class="selflink">toggleClass</strong>("selected", 1000);
|
||||
});
|
||||
</pre>
|
||||
<p></div><div id="source" class="tabs-container">
|
||||
</p>
|
||||
<pre><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
|
||||
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
|
||||
<script src="http://ui.jquery.com/latest/ui/effects.core.js"></script>
|
||||
<style type="text/css">
|
||||
p { cursor: pointer; font-size: 1.2em; }
|
||||
.selected { color:red; }
|
||||
</style>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("p").<a href="http://docs.jquery.com/Events/click" title="Events/click">click</a>(function () {
|
||||
$(this).<strong class="selflink">toggleClass</strong>("selected", 1000);
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body style="font-size:62.5%;">
|
||||
|
||||
<p>Click me to toggle 'selected' class.</p>
|
||||
<p class="selected">Click me to toggle 'selected' class.</p>
|
||||
<p>Click me to toggle 'selected' class.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</pre>
|
||||
<p></div>
|
||||
</p><p></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="options">
|
||||
<h2 class="top-header">Arguments</h2>
|
||||
<ul class="options-list">
|
||||
|
||||
<li class="option" id="option-class">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-class">class</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A CSS class to toggle on the elements.</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="option" id="option-duration">
|
||||
<div class="option-header">
|
||||
<h3 class="option-name"><a href="#option-duration">duration</a></h3>
|
||||
<dl>
|
||||
<dt class="option-type-label">Type:</dt>
|
||||
<dd class="option-type">String, Number</dd>
|
||||
|
||||
<dt class="option-optional-label">Optional</dt>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
<div class="option-description">
|
||||
<p>A string representing one of the three predefined speeds ("slow", "normal", or "fast") or the number of milliseconds to run the animation (e.g. 1000).</p>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</p><!--
|
||||
Pre-expand include size: 5231 bytes
|
||||
Post-expand include size: 6831 bytes
|
||||
Template argument size: 4329 bytes
|
||||
Maximum: 2097152 bytes
|
||||
-->
|
||||
|
||||
<!-- Saved in parser cache with key jqdocs_docs:pcache:idhash:2608-1!1!0!!en!2 and timestamp 20100519142041 -->
|
||||
Reference in New Issue
Block a user