소스 검색

Added zindex options to dropdown so we can make sure it presents itself on top of whatever is existing in the DOM

Pier-Olivier Thibault 13 년 전
부모
커밋
277ae4ff5a
1개의 변경된 파일3개의 추가작업 그리고 1개의 파일을 삭제
  1. 3 1
      select2.js

+ 3 - 1
select2.js

@@ -539,6 +539,7 @@
                 formatInputTooShort: function (input, min) { return "Please enter " + (min - input.length) + " more characters"; },
                 minimumResultsForSearch: 0,
                 minimumInputLength: 0,
+                zIndex: 2000,
                 id: function (e) { return e.id; },
                 matcher: function(term, text) {
                     return text.toUpperCase().indexOf(term.toUpperCase()) >= 0;
@@ -653,7 +654,8 @@
             this.dropdown.css({
                 top: offset.top + height,
                 left: offset.left,
-                width: width
+                width: width,
+                "z-index": this.opts.zIndex
             });
         },