fix(form-select): 修复 lay-append-to 属性开启时在 dropdown 中点击 select 面板导致 dropdown 面板被关闭的问题 (#2138)

* fix(form-select): 开启 `lay-append-to` 时,在 dropdown 中点击 select 面板,会导致 dropdown 面板意外关闭

* update
This commit is contained in:
morning-star
2024-08-02 14:31:28 +08:00
committed by GitHub
parent 130533e967
commit af792a8452

View File

@@ -746,6 +746,11 @@ layui.define(['lay', 'layer', 'util'], function(exports){
return false;
});
// 用于开启 lay-append-to 时兼容 dropdown
dl.on('mousedown pointerdown touchstart', function(e){
return false;
})
reElem.find('dl>dt').on('click', function(e){
return false;
});