Merge branch '2.x' into feat/touch

pull/1446/head
sight 2023-12-14 18:09:06 +08:00
commit 62f5abdd9b
2 changed files with 7 additions and 2 deletions

View File

@ -626,7 +626,12 @@ layui.define(['lay', 'layer', 'util'], function(exports){
};
if(isSearch){
input.on('input propertychange', search).on('blur', function(e){
// #1449: IE10 和 11 中,带有占位符的 input 元素获得/失去焦点时,会触发 input 事件
var eventsType = 'input propertychange';
if(lay.ie && (lay.ie === '10' || lay.ie === '11') && input.attr('placeholder')){
eventsType = 'keyup';
}
input.on(eventsType, search).on('blur', function(e){
var selectedIndex = select[0].selectedIndex;
thatInput = input; // 当前的 select 中的 input 元素

View File

@ -82,7 +82,7 @@ layui.define(['lay', 'laytpl', 'laypage', 'form', 'util'], function(exports){
var resolveTplStr = function(templet){
try{
return lay(templet).html();
}catch{
}catch(err){
return templet;
}
}