text: /*
  
   @Name：pop 移动端弹层组件
   @Author：Vincent Tsui
   @version：0.1
   @Date：2016-01-13
          
   */
  
  function popOffset(a){var b=a.height(),c=a.width();a.css({"margin-top":-b/2,"margin-left":-c/2})}function getElementOffset(a){return[a.offset().left,a.offset().top]}function showPop(a,b,c){var d=$('<div class="shadow"></div>'),e=$("body");c&&d.appendTo(e).show().addClass("animated fadeIn"),a.appendTo(e).show(),popOffset(a),a.addClass(b)}window.pop={alert:function(a,b,c,d){var g,i,j,k,l;$("body"),$('<div class="shadow"></div>'),g=$('<div class="pop-wrap"></div>'),$('<div class="pop-content"></div>').html('<p class="pop-title">'+a+'</p><p class="pop-describe">'+b+"</p>").appendTo(g),i=$('<div class="pop-button-box"></div>'),j="好的",k="animated bounceIn","object"==typeof c&&(j=c.btnName?c.btnName:j,k=c.className?c.className:k),l="function"==typeof j?j:"function"==typeof d?d:"",$('<span class="pop-button pop-button-close pop-button-single">'+j+"</span>").on("click",function(){pop.clear(),l&&l()}).appendTo(i),i.appendTo(g),showPop(g,k,1)},confirm:function(a,b,c,d){var g,h,i,j,e=$('<div class="pop-wrap"></div>');$('<div class="pop-content"></div>').html('<p class="pop-title">'+a+'</p><p class="pop-describe">'+b+"</p>").appendTo(e),g=$('<div class="pop-button-box"></div>'),h=["确认","取消"],i="animated bounceIn","object"==typeof c&&(h=c.btnName?c.btnName:h,i=c.className?c.className:i),j="function"==typeof c?c:"function"==typeof d?d:"",$('<span class="pop-button pop-button-close pop-button-double">'+h[0]+"</span>").on("click",function(){pop.clear(),j&&j(!0)}).appendTo(g),$('<span class="pop-button pop-button-close pop-button-double">'+h[1]+"</span>").on("click",function(){pop.clear(),j&&j(!1)}).appendTo(g),g.appendTo(e),showPop(e,i,1)},error:function(a,b,c){var e,f,g,h;$("body"),e=$('<div class="pop-wrap-error">'+a+"</div>"),$(".pop-wrap-error").remove(),f=3,g="animated flipInX","object"==typeof b&&(f=b.sec?b.sec:f,g=b.className?b.className:g),h="function"==typeof b?b:"function"==typeof c?c:"",showPop(e,g),setTimeout(function(){e.remove(),h&&h()},1e3*f)},loading:function(a,b){var d,e,f,g;$("body"),d=$('<div class="pop-loading"></div>'),e=$("<p>"+a+"</p>"),f=$('<div class="pop-loading-effect"><i class="bounce1"></i><i class="bounce2"></i><i class="bounce3"></i><i class="bounce4"></i><i class="bounce5"></i><i class="bounce6"></i></div>'),g="animated flipInX","object"==typeof b&&(g=b.className?b.className:g),d.append(e).append(f),showPop(d,g)},clear:function(){$(".shadow, .pop-wrap, .pop-wrap-error, .pop-loading").remove()}};