The Gallery is deprecated. No new Gallery components may be submitted, and modifying existing components is disabled. For more information please read the Gallery Deprecation blog post. This is a static snapshot of the Gallery for archive purposes.
See 14 more by this user. Created: 01/17/11
Last CDN Push: 02/2/11
Build Tag: gallery-2011.02.02-21-07
Project: YUI 3
License: YUI BSD
YUI Version: 3.3.0
Free for use.
This plugin for Autocomplete checks to see if the list of values is too large for the viewport and resizes it to fit if necessary, with a scrollbar.
<script src="http://yui.yahooapis.com/3.3.0/build/yui/yui-min.js"></script>
YUI({
//Last Gallery Build of this module
gallery: 'gallery-2011.02.02-21-07'
}).use('gallery-ac-list-scaler', function(Y) {
var ipt = Y.one ('#complete'),
values = ['foo', 'bar', 'bazz', 'boo'];
ipt.plug({fn : Y.Plugin.AutoComplete, cfg : {
source : values,
resultFilters : [
Y.AutoCompleteFilters.startsWith
],
resultHighlighter : Y.AutoCompleteHighlighters.startsWidth,
plugins : [
{fn : Y.ACListScaler}
]
}});
});
Subject | Author | Date |
---|---|---|
Define the Max view item. | vysun | 04/13/11 |
All code on this site is licensed under the BSD License unless stated otherwise.