2 lines
22 KiB
JavaScript
2 lines
22 KiB
JavaScript
![]() |
/** layui-v2.5.5 MIT License By https://www.layui.com */
|
||
|
!function(i,d){var e=i.layui&&layui.define,f,h,j={getPath:function(){var l=document.currentScript?document.currentScript.src:function(){var o=document.scripts,n=o.length-1,p;for(var m=n;m>0;m--){if(o[m].readyState==="interactive"){p=o[m].src;break}}return p||o[n].src}();return l.substring(0,l.lastIndexOf("/")+1)}(),config:{},end:{},minIndex:0,minLeft:[],btn:["确定","取消"],type:["dialog","page","iframe","loading","tips"],getStyle:function(n,l){var m=n.currentStyle?n.currentStyle:i.getComputedStyle(n,null);return m[m.getPropertyValue?"getPropertyValue":"getAttribute"](l)},link:function(l,s,m){if(!g.path){return}var t=document.getElementsByTagName("head")[0],r=document.createElement("link");if(typeof s==="string"){m=s}var o=(m||l).replace(/\.|\//g,"");var n="layuicss-"+o,q=0;r.rel="stylesheet";r.href=g.path+l;r.id=n;if(!document.getElementById(n)){t.appendChild(r)}if(typeof s!=="function"){return}(function p(){if(++q>8*1000/100){return i.console&&console.error("layer.css: Invalid")}parseInt(j.getStyle(document.getElementById(n),"width"))===1989?s():setTimeout(p,100)}())}};var g={v:"3.1.1",ie:function(){var l=navigator.userAgent.toLowerCase();return(!!i.ActiveXObject||"ActiveXObject" in i)?((l.match(/msie\s(\d+)/)||[])[1]||"11"):false}(),index:(i.layer&&i.layer.v)?100000:0,path:j.getPath,config:function(l,m){l=l||{};g.cache=j.config=f.extend({},j.config,l);g.path=j.config.path||g.path;typeof l.extend==="string"&&(l.extend=[l.extend]);if(j.config.path){g.ready()}if(!l.extend){return this}e?layui.addcss("modules/layer/"+l.extend):j.link("theme/"+l.extend);return this},ready:function(o){var m="layer",l="",n=(e?"modules/layer/":"theme/")+"default/layer.css?v="+g.v+l;e?layui.addcss(n,o,m):j.link(n,o,m);return this},alert:function(n,l,o){var m=typeof l==="function";if(m){o=l}return g.open(f.extend({content:n,yes:o},m?{}:l))},confirm:function(o,l,p,n){var m=typeof l==="function";if(m){n=p;p=l}return g.open(f.extend({content:o,btn:j.btn,yes:p,btn2:n},m?{}:l))},msg:function(o,m,l){var n=typeof m==="function",r=j.config.skin;var q=(r?r+" "+r+"-msg":"")||"layui-layer-msg";var p=c.anim.length-1;if(n){l=m}return g.open(f.extend({content:o,time:3000,shade:false,skin:q,title:false,closeBtn:false,btn:false,resize:false,end:l},(n&&!j.config.skin)?{skin:q+" layui-layer-hui",anim:p}:function(){m=m||{};if(m.icon===-1||m.icon===d&&!j.config.skin){m.skin=q+" "+(m.skin||"layui-layer-hui")}return m}()))},load:function(m,l){return g.open(f.extend({type:3,icon:m||0,resize:false,shade:0.01},l))},tips:function(n,l,m){return g.open(f.extend({type:4,content:[n,l],closeBtn:false,time:3000,shade:false,resize:false,fixed:false,maxWidth:210},m))}};var b=function(l){var m=this;m.index=++g.index;m.config=f.extend({},m.config,j.config,l);document.body?m.creat():setTimeout(function(){m.creat()},30)};b.pt=b.prototype;var c=["layui-layer",".layui-layer-title",".layui-layer-main",".layui-layer-dialog","layui-layer-iframe","layui-layer-content","layui-layer-btn","layui-layer-close"];c.anim=["layer-anim-00","layer-anim-01","layer-anim-02","layer-anim-03","layer-anim-04","layer-anim-05","layer-anim-06"];b.pt.config={type:0,shade:0.3,fixed:true,move:c[1],title:"信息",offset:"auto",area:"auto",closeBtn:1,time:0,zIndex:19891014,maxWidth:360,anim:0,isOutAnim:true,icon:-1,moveType:1,resize:true,scrollbar:true,tips:2};b.pt.vessel=function(p,t){var q=this,l=q.index,o=q.config;var s=o.zIndex+l,n=typeof o.title==="object";var r=o.maxmin&&(o.type===1||o.type===2);var m=(o.title?'<div class="layui-layer-title" style="'+(n?o.title[1]:"")+'">'+(n?o.title[0]:o.title)+"</div>":"");o.zIndex=s;t([o.shade?('<div class="layui-layer-shade" id="layui-layer-shade'+l+'" times="'+l+'" style="'+("z-index:"+(s-1)+"; ")+'"></div>'):"",'<div class="'+c[0]+(" layui-layer-"+j.type[o.type])+(((o.type==0||o.type==2)&&!o.shade)?" layui-layer-border":"")+" "+(o.skin||"")+'" id="'+c[0]+l+'" type="'+j.type[o.type]+'" times="'+l+'" showtime="'+o.time+'" conType="'+(p?"object":"string")+'" style="z-index: '+s+"; width:"+o.area[0]+";height:"+o.area[1]+(o.fixed?"":";pos
|