mirror of https://github.com/layui/layui
修复 laydate 开启 `shade` 后,遮罩 `z-index` 未能正确计算的问题
parent
fab6f817fd
commit
012ae89104
|
@ -663,7 +663,7 @@
|
|||
,that.position() //定位
|
||||
);
|
||||
|
||||
var shade = options.shade ? ('<div class="'+ ELEM_SHADE +'" style="'+ ('z-index:'+ (elem.style.zIndex-1) +'; background-color: ' + (options.shade[1] || '#000') + '; opacity: ' + (options.shade[0] || options.shade)) +'"></div>') : '';
|
||||
var shade = options.shade ? ('<div class="'+ ELEM_SHADE +'" style="'+ ('z-index:'+ (parseInt(layui.getStyle(elem, 'z-index'))-1) +'; background-color: ' + (options.shade[1] || '#000') + '; opacity: ' + (options.shade[0] || options.shade)) +'"></div>') : '';
|
||||
elem.insertAdjacentHTML('beforebegin', shade);
|
||||
|
||||
that.checkDate().calendar(null, 0, 'init'); //初始校验
|
||||
|
|
Loading…
Reference in New Issue