Using dropdownZIndex as opts. Dropping default value so use can set it via css.
This commit is contained in:
parent
277ae4ff5a
commit
5941fcea25
13
select2.js
13
select2.js
@ -539,7 +539,6 @@
|
|||||||
formatInputTooShort: function (input, min) { return "Please enter " + (min - input.length) + " more characters"; },
|
formatInputTooShort: function (input, min) { return "Please enter " + (min - input.length) + " more characters"; },
|
||||||
minimumResultsForSearch: 0,
|
minimumResultsForSearch: 0,
|
||||||
minimumInputLength: 0,
|
minimumInputLength: 0,
|
||||||
zIndex: 2000,
|
|
||||||
id: function (e) { return e.id; },
|
id: function (e) { return e.id; },
|
||||||
matcher: function(term, text) {
|
matcher: function(term, text) {
|
||||||
return text.toUpperCase().indexOf(term.toUpperCase()) >= 0;
|
return text.toUpperCase().indexOf(term.toUpperCase()) >= 0;
|
||||||
@ -650,13 +649,15 @@
|
|||||||
var offset = this.container.offset();
|
var offset = this.container.offset();
|
||||||
var height = this.container.outerHeight();
|
var height = this.container.outerHeight();
|
||||||
var width = this.container.outerWidth();
|
var width = this.container.outerWidth();
|
||||||
|
var css = {
|
||||||
this.dropdown.css({
|
|
||||||
top: offset.top + height,
|
top: offset.top + height,
|
||||||
left: offset.left,
|
left: offset.left,
|
||||||
width: width,
|
width: width
|
||||||
"z-index": this.opts.zIndex
|
}
|
||||||
});
|
if (this.opts.dropdownZIndex !== undefined) {
|
||||||
|
css["z-index"] = this.opts.dropdownZIndex
|
||||||
|
}
|
||||||
|
this.dropdown.css(css);
|
||||||
},
|
},
|
||||||
|
|
||||||
open: function () {
|
open: function () {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user