recalculate $dropdown height after drop-above class added
This commit is contained in:
parent
4e19d87927
commit
a83ae7858a
@ -1325,10 +1325,11 @@ the specific language governing permissions and limitations under the Apache Lic
|
|||||||
};
|
};
|
||||||
|
|
||||||
if (above) {
|
if (above) {
|
||||||
css.top = offset.top - dropHeight;
|
|
||||||
css.bottom = 'auto';
|
|
||||||
this.container.addClass("select2-drop-above");
|
this.container.addClass("select2-drop-above");
|
||||||
$dropdown.addClass("select2-drop-above");
|
$dropdown.addClass("select2-drop-above");
|
||||||
|
dropHeight = $dropdown.outerHeight(false);
|
||||||
|
css.top = offset.top - dropHeight;
|
||||||
|
css.bottom = 'auto';
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
css.top = dropTop;
|
css.top = dropTop;
|
||||||
|
Loading…
Reference in New Issue
Block a user