
META-INF.resources.org.richfaces.optimized.5.0.0.Alpha3.PackedCompressed.com.jqueryui.jquery.ui.effect-scale.min.js Maven / Gradle / Ivy
/* jQuery UI - v1.9.2 - 2012-11-23
* http://jqueryui.com
* Includes: jquery.ui.effect-scale.js
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
(function(B,A){B.effects.effect.puff=function(F,J){var H=B(this),E=B.effects.setMode(H,F.mode||"hide"),G=E==="hide",I=parseInt(F.percent,10)||150,D=I/100,C={height:H.height(),width:H.width(),outerHeight:H.outerHeight(),outerWidth:H.outerWidth()};
B.extend(F,{effect:"scale",queue:!1,fade:!0,mode:E,complete:J,percent:G?I:100,from:G?C:{height:C.height*D,width:C.width*D,outerHeight:C.outerHeight*D,outerWidth:C.outerWidth*D}}),H.effect(F)
},B.effects.effect.scale=function(K,E){var C=B(this),G=B.extend(!0,{},K),L=B.effects.setMode(C,K.mode||"effect"),D=parseInt(K.percent,10)||(parseInt(K.percent,10)===0?0:L==="hide"?0:100),J=K.direction||"both",I=K.origin,H={height:C.height(),width:C.width(),outerHeight:C.outerHeight(),outerWidth:C.outerWidth()},F={y:J!=="horizontal"?D/100:1,x:J!=="vertical"?D/100:1};
G.effect="size",G.queue=!1,G.complete=E,L!=="effect"&&(G.origin=I||["middle","center"],G.restore=!0),G.from=K.from||(L==="show"?{height:0,width:0,outerHeight:0,outerWidth:0}:H),G.to={height:H.height*F.y,width:H.width*F.x,outerHeight:H.outerHeight*F.y,outerWidth:H.outerWidth*F.x},G.fade&&(L==="show"&&(G.from.opacity=0,G.to.opacity=1),L==="hide"&&(G.from.opacity=1,G.to.opacity=0)),C.effect(G)
},B.effects.effect.size=function(F,K){var H,N,G,J=B(this),E=["position","top","bottom","left","right","width","height","overflow","opacity"],U=["position","top","bottom","left","right","overflow","opacity"],Q=["width","height","overflow"],M=["fontSize"],S=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],O=["borderLeftWidth","borderRightWidth","paddingLeft","paddingRight"],I=B.effects.setMode(J,F.mode||"effect"),R=F.restore||I!=="effect",D=F.scale||"both",L=F.origin||["middle","center"],P=J.css("position"),C=R?E:U,T={height:0,width:0,outerHeight:0,outerWidth:0};
I==="show"&&J.show(),H={height:J.height(),width:J.width(),outerHeight:J.outerHeight(),outerWidth:J.outerWidth()},F.mode==="toggle"&&I==="show"?(J.from=F.to||T,J.to=F.from||H):(J.from=F.from||(I==="show"?T:H),J.to=F.to||(I==="hide"?T:H)),G={from:{y:J.from.height/H.height,x:J.from.width/H.width},to:{y:J.to.height/H.height,x:J.to.width/H.width}};
if(D==="box"||D==="both"){G.from.y!==G.to.y&&(C=C.concat(S),J.from=B.effects.setTransition(J,S,G.from.y,J.from),J.to=B.effects.setTransition(J,S,G.to.y,J.to)),G.from.x!==G.to.x&&(C=C.concat(O),J.from=B.effects.setTransition(J,O,G.from.x,J.from),J.to=B.effects.setTransition(J,O,G.to.x,J.to))
}(D==="content"||D==="both")&&G.from.y!==G.to.y&&(C=C.concat(M).concat(Q),J.from=B.effects.setTransition(J,M,G.from.y,J.from),J.to=B.effects.setTransition(J,M,G.to.y,J.to)),B.effects.save(J,C),J.show(),B.effects.createWrapper(J),J.css("overflow","hidden").css(J.from),L&&(N=B.effects.getBaseline(L,H),J.from.top=(H.outerHeight-J.outerHeight())*N.y,J.from.left=(H.outerWidth-J.outerWidth())*N.x,J.to.top=(H.outerHeight-J.to.outerHeight)*N.y,J.to.left=(H.outerWidth-J.to.outerWidth)*N.x),J.css(J.from);
if(D==="content"||D==="both"){S=S.concat(["marginTop","marginBottom"]).concat(M),O=O.concat(["marginLeft","marginRight"]),Q=E.concat(S).concat(O),J.find("*[width]").each(function(){var W=B(this),V={height:W.height(),width:W.width(),outerHeight:W.outerHeight(),outerWidth:W.outerWidth()};
R&&B.effects.save(W,Q),W.from={height:V.height*G.from.y,width:V.width*G.from.x,outerHeight:V.outerHeight*G.from.y,outerWidth:V.outerWidth*G.from.x},W.to={height:V.height*G.to.y,width:V.width*G.to.x,outerHeight:V.height*G.to.y,outerWidth:V.width*G.to.x},G.from.y!==G.to.y&&(W.from=B.effects.setTransition(W,S,G.from.y,W.from),W.to=B.effects.setTransition(W,S,G.to.y,W.to)),G.from.x!==G.to.x&&(W.from=B.effects.setTransition(W,O,G.from.x,W.from),W.to=B.effects.setTransition(W,O,G.to.x,W.to)),W.css(W.from),W.animate(W.to,F.duration,F.easing,function(){R&&B.effects.restore(W,Q)
})
})
}J.animate(J.to,{queue:!1,duration:F.duration,easing:F.easing,complete:function(){J.to.opacity===0&&J.css("opacity",J.from.opacity),I==="hide"&&J.hide(),B.effects.restore(J,C),R||(P==="static"?J.css({position:"relative",top:J.to.top,left:J.to.left}):B.each(["top","left"],function(W,V){J.css(V,function(Y,a){var Z=parseInt(a,10),X=W?J.to.left:J.to.top;
return a==="auto"?X+"px":Z+X+"px"
})
})),B.effects.removeWrapper(J),K()
}})
}
})(jQuery);
© 2015 - 2025 Weber Informatics LLC | Privacy Policy