Autocomplete: If the `appendTo` option is an empty jQuery object, it skips the check for `.ui-front`
|Reported by:||MoonScript||Owned by:||scottgonzalez|
If you pass an empty jQuery collection for the "appendTo" option in the autocomplete widget, it will skip the check for the closest "ui-front" element. I think it should do an extra check to handle that case, so it will be consistent in how it looks for elements to append the autocomplete menu to.
So it should check the following:
- If "appendTo" element (node) is supplied, use it and don't check anything else.
- If "appendTo" jQuery collection is supplied, make sure that its length is > 0. If not, go to #4. (this is where the bug exists today)
- If "appendTo" selector (string) is supplied, look for that element. If not found, go to #4.
- Look for closest element with a class of "ui-front". If not found, go to #5.
- Append to the <body>.
Change History (3)
comment:2 Changed 3 years ago by scottgonzalez
- Milestone changed from none to 1.11.0
- Owner set to scott.gonzalez
- Status changed from new to assigned
- Summary changed from When autocomplete appendTo option is an empty jQuery collection, it skips the check for "ui-front" to Autocomplete: If the `appendTo` option is an empty jQuery object, it skips the check for `.ui-front`