Skip to content

Commit

Permalink
Ensure the wrapper element created in place of the original input has…
Browse files Browse the repository at this point in the history
… the table-cell display property if needed
  • Loading branch information
redox committed Sep 9, 2015
1 parent a3b8b9b commit 95a496e
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 3 deletions.
6 changes: 6 additions & 0 deletions dist/autocomplete.angular.js
Original file line number Diff line number Diff line change
Expand Up @@ -5180,6 +5180,12 @@ function buildDom(options) {

$input = $(options.input);
$wrapper = $(html.wrapper).css(css.wrapper);
// override the display property with the table-cell value
// if the parent element is a table and the original input was a block
// -> https://github.com/algolia/autocomplete.js/issues/16
if ($input.css('display') === 'block' && $input.parent().css('display') === 'table') {
$wrapper.css('display', 'table-cell');
}
$dropdown = $(html.dropdown).css(css.dropdown);
if (options.templates && options.templates.dropdownMenu) {
$dropdown.html(_.templatify(options.templates.dropdownMenu)());
Expand Down
2 changes: 1 addition & 1 deletion dist/autocomplete.angular.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 95a496e

Please sign in to comment.