Home >
Article > Web Front-end > In-depth analysis of jQuery's selection component_Basic knowledge
In-depth analysis of jQuery's selection component_Basic knowledge
WBOYOriginal
2016-05-16 17:32:011032browse
1: The Selectable component can make some elements on the user page selectable . The user can select them by clicking on the elements or dragging them, or they can Hold Ctrl key to select non-contiguous elements $('.selector').selectable(options); But in jQuery UI library The ui-selecting and ui-selected class styles are not provided in the theme package, so when using the selection component, you need to create these styles yourself
Open online banking, Baifu Bao will escort you all the way
Look for the logo and select powerful sellers for you to choose
< li class="ui-widget-content">Collect the shopping cart to make shopping and searching for stores more convenient
Inspect the goods first and then pay, and make the transaction More secure
Honest and reliable, quality guaranteed
2: Filter selection item can filter sub-elements, and has specified which sub-elements are optional. For this purpose, You can set the filter attribute to a jQuery selector when calling the selectable() method. At this time, only elements that match the selector can become selection items
3: Select event callback function The selection event provides 6 events selected, the event type is selectableseleted, it is triggered when an element is added to the selection and the selection operation is completed selecting: The event type is selectableselecting, it is triggered when an element is selected during the selection process start: The event type is selectablestart, which is triggered when the selection operation starts. stop: The event type is selectablestop, which is triggered when the selection operation ends. unselected: The event type is selectableunselected, when each element is removed from the selected item. , and is triggered after the selection operation is completed unselecting: The event type is selectableunselecting, which is triggered when each element is removed from the selected item during the selection process
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn