优化 layer 移动端定位 (#1376)

* 优化 layer 移动端定位

* update code
This commit is contained in:
morning-star
2023-09-19 00:59:22 +08:00
committed by GitHub
parent c7d6cf90c9
commit 6aa349b640
2 changed files with 31 additions and 0 deletions

View File

@@ -24,6 +24,7 @@
<button class="layui-btn" lay-on="test7">Prompt</button>
<button class="layui-btn" lay-on="test8">Tab</button>
<button class="layui-btn" lay-on="test9">Photo</button>
<button class="layui-btn" lay-on="test10">Drawer</button>
<button class="layui-btn" lay-on="testTime">自动关闭</button>
<a href="https://layui.dev/docs/2.8/layer/" target="_blank" class="layui-btn">更多例子</a>
</div>
@@ -215,6 +216,19 @@ layui.use(['layer', 'util'], function(layer, util){
}
});
}
,test10: function(){
layer.open({
title:'drawer',
type: 1,
offset: 'b',
anim: 'slideUp', // 从下往上
area: ['100%', '160px'],
shade: 0.1,
shadeClose: true,
content: $('#test11111'),
maxmin: true,
});
}
});
// 相册层