<meta charset="utf-8">
<title>jQuery UI Autocomplete - Categories</title>
<link rel="stylesheet" href="../../themes/base/all.css">
- <script src="../../external/jquery/jquery.js"></script>
- <script src="../../ui/core.js"></script>
- <script src="../../ui/widget.js"></script>
- <script src="../../ui/position.js"></script>
- <script src="../../ui/menu.js"></script>
- <script src="../../ui/autocomplete.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.ui-autocomplete-category {
line-height: 1.5;
}
</style>
- <script>
- $.widget( "custom.catcomplete", $.ui.autocomplete, {
- _create: function() {
- this._super();
- this.widget().menu( "option", "items", "> :not(.ui-autocomplete-category)" );
- },
- _renderMenu: function( ul, items ) {
- var that = this,
- currentCategory = "";
- $.each( items, function( index, item ) {
- var li;
- if ( item.category != currentCategory ) {
- ul.append( "<li class='ui-autocomplete-category'>" + item.category + "</li>" );
- currentCategory = item.category;
- }
- li = that._renderItemData( ul, item );
- if ( item.category ) {
- li.attr( "aria-label", item.category + " : " + item.label );
- }
- });
- }
- });
- </script>
- <script>
- $(function() {
+ <script src="../../external/requirejs/require.js"></script>
+ <script src="../bootstrap.js">
+ $.widget( "custom.catcomplete", $.ui.autocomplete, {
+ _create: function() {
+ this._super();
+ this.widget().menu( "option", "items", "> :not(.ui-autocomplete-category)" );
+ },
+ _renderMenu: function( ul, items ) {
+ var that = this,
+ currentCategory = "";
+ $.each( items, function( index, item ) {
+ var li;
+ if ( item.category != currentCategory ) {
+ ul.append( "<li class='ui-autocomplete-category'>" + item.category + "</li>" );
+ currentCategory = item.category;
+ }
+ li = that._renderItemData( ul, item );
+ if ( item.category ) {
+ li.attr( "aria-label", item.category + " : " + item.label );
+ }
+ });
+ }
+ });
var data = [
{ label: "anders", category: "" },
{ label: "andreas", category: "" },
delay: 0,
source: data
});
- });
</script>
</head>
<body>
<meta charset="utf-8">
<title>jQuery UI Autocomplete - Combobox</title>
<link rel="stylesheet" href="../../themes/base/all.css">
- <script src="../../external/jquery/jquery.js"></script>
- <script src="../../ui/core.js"></script>
- <script src="../../ui/widget.js"></script>
- <script src="../../ui/button.js"></script>
- <script src="../../ui/position.js"></script>
- <script src="../../ui/menu.js"></script>
- <script src="../../ui/autocomplete.js"></script>
- <script src="../../ui/tooltip.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.custom-combobox {
padding: 5px 10px;
}
</style>
- <script>
- (function( $ ) {
+ <script src="../../external/requirejs/require.js"></script>
+ <script src="../bootstrap.js" data-modules="tooltip button">
$.widget( "custom.combobox", {
_create: function() {
this.wrapper = $( "<span>" )
this.element.show();
}
});
- })( jQuery );
- $(function() {
$( "#combobox" ).combobox();
$( "#toggle" ).on( "click", function() {
$( "#combobox" ).toggle();
});
- });
</script>
</head>
<body>
<meta charset="utf-8">
<title>jQuery UI Autocomplete - Custom data and display</title>
<link rel="stylesheet" href="../../themes/base/all.css">
- <script src="../../external/jquery/jquery.js"></script>
- <script src="../../ui/core.js"></script>
- <script src="../../ui/widget.js"></script>
- <script src="../../ui/position.js"></script>
- <script src="../../ui/menu.js"></script>
- <script src="../../ui/autocomplete.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#project-label {
padding: 0;
}
</style>
- <script>
- $(function() {
+ <script src="../../external/requirejs/require.js"></script>
+ <script src="../bootstrap.js">
var projects = [
{
value: "jquery",
.append( "<div>" + item.label + "<br>" + item.desc + "</div>" )
.appendTo( ul );
};
- });
</script>
</head>
<body>
<meta charset="utf-8">
<title>jQuery UI Autocomplete - Default functionality</title>
<link rel="stylesheet" href="../../themes/base/all.css">
- <script src="../../external/jquery/jquery.js"></script>
- <script src="../../ui/core.js"></script>
- <script src="../../ui/widget.js"></script>
- <script src="../../ui/position.js"></script>
- <script src="../../ui/menu.js"></script>
- <script src="../../ui/autocomplete.js"></script>
<link rel="stylesheet" href="../demos.css">
- <script>
- $(function() {
+ <script src="../../external/requirejs/require.js"></script>
+ <script src="../bootstrap.js">
var availableTags = [
"ActionScript",
"AppleScript",
$( "#tags" ).autocomplete({
source: availableTags
});
- });
</script>
</head>
<body>
<meta charset="utf-8">
<title>jQuery UI Autocomplete - Accent folding</title>
<link rel="stylesheet" href="../../themes/base/all.css">
- <script src="../../external/jquery/jquery.js"></script>
- <script src="../../ui/core.js"></script>
- <script src="../../ui/widget.js"></script>
- <script src="../../ui/position.js"></script>
- <script src="../../ui/menu.js"></script>
- <script src="../../ui/autocomplete.js"></script>
<link rel="stylesheet" href="../demos.css">
- <script>
- $(function() {
+ <script src="../../external/requirejs/require.js"></script>
+ <script src="../bootstrap.js">
var names = [ "Jörn Zaefferer", "Scott González", "John Resig" ];
var accentMap = {
}) );
}
});
- });
</script>
</head>
<body>
<meta charset="utf-8">
<title>jQuery UI Autocomplete - Scrollable results</title>
<link rel="stylesheet" href="../../themes/base/all.css">
- <script src="../../external/jquery/jquery.js"></script>
- <script src="../../ui/core.js"></script>
- <script src="../../ui/widget.js"></script>
- <script src="../../ui/position.js"></script>
- <script src="../../ui/menu.js"></script>
- <script src="../../ui/autocomplete.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.ui-autocomplete {
height: 100px;
}
</style>
- <script>
- $(function() {
+ <script src="../../external/requirejs/require.js"></script>
+ <script src="../bootstrap.js">
var availableTags = [
"ActionScript",
"AppleScript",
$( "#tags" ).autocomplete({
source: availableTags
});
- });
</script>
</head>
<body>
<meta charset="utf-8">
<title>jQuery UI Autocomplete - Multiple, remote</title>
<link rel="stylesheet" href="../../themes/base/all.css">
- <script src="../../external/jquery/jquery.js"></script>
- <script src="../../ui/core.js"></script>
- <script src="../../ui/widget.js"></script>
- <script src="../../ui/position.js"></script>
- <script src="../../ui/menu.js"></script>
- <script src="../../ui/autocomplete.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.ui-autocomplete-loading {
background: white url("images/ui-anim_basic_16x16.gif") right center no-repeat;
}
</style>
- <script>
- $(function() {
+ <script src="../../external/requirejs/require.js"></script>
+ <script src="../bootstrap.js">
function split( val ) {
return val.split( /,\s*/ );
}
return false;
}
});
- });
</script>
</head>
<body>
<meta charset="utf-8">
<title>jQuery UI Autocomplete - Multiple values</title>
<link rel="stylesheet" href="../../themes/base/all.css">
- <script src="../../external/jquery/jquery.js"></script>
- <script src="../../ui/core.js"></script>
- <script src="../../ui/widget.js"></script>
- <script src="../../ui/position.js"></script>
- <script src="../../ui/menu.js"></script>
- <script src="../../ui/autocomplete.js"></script>
<link rel="stylesheet" href="../demos.css">
- <script>
- $(function() {
+ <script src="../../external/requirejs/require.js"></script>
+ <script src="../bootstrap.js">
var availableTags = [
"ActionScript",
"AppleScript",
return false;
}
});
- });
</script>
</head>
<body>
<meta charset="utf-8">
<title>jQuery UI Autocomplete - Remote JSONP datasource</title>
<link rel="stylesheet" href="../../themes/base/all.css">
- <script src="../../external/jquery/jquery.js"></script>
- <script src="../../ui/core.js"></script>
- <script src="../../ui/widget.js"></script>
- <script src="../../ui/position.js"></script>
- <script src="../../ui/menu.js"></script>
- <script src="../../ui/autocomplete.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.ui-autocomplete-loading {
}
#city { width: 25em; }
</style>
- <script>
- $(function() {
+ <script src="../../external/requirejs/require.js"></script>
+ <script src="../bootstrap.js">
function log( message ) {
$( "<div>" ).text( message ).prependTo( "#log" );
$( "#log" ).scrollTop( 0 );
log( "Selected: " + ui.item.label );
}
} );
- } );
</script>
</head>
<body>
<meta charset="utf-8">
<title>jQuery UI Autocomplete - Remote with caching</title>
<link rel="stylesheet" href="../../themes/base/all.css">
- <script src="../../external/jquery/jquery.js"></script>
- <script src="../../ui/core.js"></script>
- <script src="../../ui/widget.js"></script>
- <script src="../../ui/position.js"></script>
- <script src="../../ui/menu.js"></script>
- <script src="../../ui/autocomplete.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.ui-autocomplete-loading {
background: white url("images/ui-anim_basic_16x16.gif") right center no-repeat;
}
</style>
- <script>
- $(function() {
+ <script src="../../external/requirejs/require.js"></script>
+ <script src="../bootstrap.js">
var cache = {};
$( "#birds" ).autocomplete({
minLength: 2,
});
}
});
- });
</script>
</head>
<body>
<meta charset="utf-8">
<title>jQuery UI Autocomplete - Remote datasource</title>
<link rel="stylesheet" href="../../themes/base/all.css">
- <script src="../../external/jquery/jquery.js"></script>
- <script src="../../ui/core.js"></script>
- <script src="../../ui/widget.js"></script>
- <script src="../../ui/position.js"></script>
- <script src="../../ui/menu.js"></script>
- <script src="../../ui/autocomplete.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.ui-autocomplete-loading {
background: white url("images/ui-anim_basic_16x16.gif") right center no-repeat;
}
</style>
- <script>
- $(function() {
+ <script src="../../external/requirejs/require.js"></script>
+ <script src="../bootstrap.js">
function log( message ) {
$( "<div>" ).text( message ).prependTo( "#log" );
$( "#log" ).scrollTop( 0 );
"Nothing selected, input was " + this.value );
}
});
- });
</script>
</head>
<body>
<meta charset="utf-8">
<title>jQuery UI Autocomplete - XML data parsed once</title>
<link rel="stylesheet" href="../../themes/base/all.css">
- <script src="../../external/jquery/jquery.js"></script>
- <script src="../../ui/core.js"></script>
- <script src="../../ui/widget.js"></script>
- <script src="../../ui/position.js"></script>
- <script src="../../ui/menu.js"></script>
- <script src="../../ui/autocomplete.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.ui-autocomplete-loading {
background: white url("images/ui-anim_basic_16x16.gif") right center no-repeat;
}
</style>
- <script>
- $(function() {
+ <script src="../../external/requirejs/require.js"></script>
+ <script src="../bootstrap.js">
function log( message ) {
$( "<div/>" ).text( message ).prependTo( "#log" );
$( "#log" ).attr( "scrollTop", 0 );
});
}
});
- });
</script>
</head>
<body>