Add CSS to better match egw. Fix chosen sizes using new width attribute. Not perfect, but at least never too small.

This commit is contained in:
Nathan Gray
2013-07-25 20:28:32 +00:00
parent 15ad58522f
commit f65680a7ae
3 changed files with 49 additions and 1 deletions

View File

@ -777,6 +777,11 @@
this.form_field_jq.trigger("liszt:showing_dropdown", {
chosen: this
});
var windowHeight = $(window).height(),
dropdownTop = this.container.offset().top + this.container.height() - $(window).scrollTop()
totalHeight = this.dropdown.height() + dropdownTop
this.dropdown.toggleClass('chzn-above', totalHeight > windowHeight);
this.results_showing = true;
this.search_field.focus();
this.search_field.val(this.search_field.val());