jQuery UI have the great widgets but the the very basic UI, textbox is not consider as a widget.
It could be a simple but it is good to have a textbox to make jquery UI widget rich.
not only will add class ui-widget ui-widget-content ui-corner-all and ui-state-default but also ui-state-focus and ui-state-hover added in events also ui-state-disabled for disabled.
Some basic form element to go:
textbox <input type="text">
password <input type="password">
upload file <input type="file">
multiline textbox <textarea>
Another one is <fieldset><legend></legend></fieldset> but i think this is not recently used.
I am trying to extend the Autocomplete widget to be use as Combobox with additional button next to the textbox. I found no Combobox development and I think this widget would be useful event just a little bit modification from Autocomplete. I am jQuery UI lover and freely to contribute to design this plus some more widget that not in your development right now.
This Combobox not only modified from html select option as shown in the Autocomplete example but also can be used by html input text with json source just like Autocomplete source options.
The interesting about this Combobox compare to the Autocomplete example are textbox, button and menu item has fix the width and height problem and user no need to extend the Autocomplete.
so $(".selector").combobox() will have Menu items + combobox Button.
From my thought, user may use the autocomplete in three different way:
Using keyboard - Focus on textbox, type search keyword, press Down Arrow, and press Enter to select the item.
Using keyboard and mouse - Focus on textbox, type search keyword, press Down Arrow, and click on the item.
Using mouse - Click an object that trigger opening the autocomplete, click on the item.
The third one, autocomplete menu opened by input.autocomplete("search", "") code might performed by clicking an other object like combobox down arrow image button.
Here is the result shown in P tag based on the both three condition:
Here is the result for (1) and (2) when no keyword entered: (the (3) not applicable for keyword since it trigger from another object that mainly to show all items)
autocompleteselect compared to autocompleteclose event in (2) and (3) does not give correct textbox value.
Only textbox change event happened in (1).
autocompletechange event only happen when textbox lost focus.
seems that only autocompleteclose is a useful event for user to get textbox value whenever the value selected or changed, autocompletechange is too late to trigger after lost focus.
The we can get the correct selected value in autocompleteselect event by parameter ui.item.label or ui.item.value but it not properly documented and I only get it by using Firebug.
Actually we need an event that can be used to indicate an item selected with selected value by keyboard and mouse and changed textbox value without waiting for lost focus in case user can only type a keyword without selecting in autocomplete items. This events useful to update another object or perform an ajax request.
I can conclude that there is a glitch in autocompleteselect event that developer think it a suitable trigger to get selected value and the event documentation not clearly tell which event is suitable for it and confusion to use the events.
Hi, Visual Studio IntelliSense for jquery cannot be working when I put the jQuery UI script tag. Note the jquery-1.4.2.min.js and jquery-1.4.1-vsdoc.js was renamed to jquery.min.js and jquery.min-vsdoc.js files. Visual Studio show warning "jquery.min-vsdoc.js: 'chileNodes' is null or not an object @ 5814:4" Try to remove the jQuery UI script tag and $... can be shown in IntelliSense menu.