mirror of
https://github.com/jquery/jquery-ui.git
synced 2024-10-05 01:44:18 +00:00
Autocomplete: Resize menu on every suggestion.
This commit is contained in:
parent
493e0395c1
commit
c2ed8ffc07
7
ui/jquery.ui.autocomplete.js
vendored
7
ui/jquery.ui.autocomplete.js
vendored
@ -246,9 +246,10 @@ $.widget( "ui.autocomplete", {
|
|||||||
of: this.element,
|
of: this.element,
|
||||||
collision: "none"
|
collision: "none"
|
||||||
});
|
});
|
||||||
if ( ul.width() <= this.element.width() ) {
|
|
||||||
ul.width( this.element.width() );
|
var menuWidth = ul.width( "" ).width(),
|
||||||
}
|
textWidth = this.element.width();
|
||||||
|
ul.width( Math.max( menuWidth, textWidth ) );
|
||||||
},
|
},
|
||||||
|
|
||||||
_renderMenu: function( ul, items ) {
|
_renderMenu: function( ul, items ) {
|
||||||
|
Loading…
Reference in New Issue
Block a user