并 并
layui.use(['popover', 'jquery', 'layer', 'code'], function() { var popover = layui.popover; popover.show('#el1'); popover.hide('#el1'); //或 $('#el1').webuiPopover('hide'); })
layui.use(['toast', 'jquery', 'layer', 'code'], function() { var popover = layui.popover; popover.create('#el1',{title:' hello popover-manual',content:'这里显示内容',trigger:'manual',placement:'auto', animation:'pop', closeable:true, delay: { //show and hide delay time of the popover, works only when trigger is 'hover',the value can be number or object show: null, hide: 100 }, opacity:0.98, type:'html',//content type, values:'html','iframe','async' }); })
layui.use(['popover', 'jquery', 'layer', 'code'], function() { var popover = layui.popover; popover.hideAll(); })