| Current Path : /home/happyrenas/old/happy-r.fr/transfere_pro/js/nivo-slider/ |
Linux webd005.cluster105.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64 |
| Current File : /home/happyrenas/old/happy-r.fr/transfere_pro/js/nivo-slider/jquery.nivo.slider.js |
(function(b){var v=function(p,w){var g=b.extend({},b.fn.nivoSlider.defaults,w),a={currentSlide:0,currentImage:"",totalSlides:0,running:!1,paused:!1,stop:!1,controlNavEl:!1},l=b(p);l.data("nivo:vars",a).addClass("nivoSlider");var m=l.children();m.each(function(){var c=b(this),e="";c.is("img")||(c.is("a")&&(c.addClass("nivo-imageLink"),e=c),c=c.find("img:first"));var d=0===d?c.attr("width"):c.width(),g=0===g?c.attr("height"):c.height();""!==e&&e.css("display","none");c.css("display","none");a.totalSlides++}); g.randomStart&&(g.startSlide=Math.floor(Math.random()*a.totalSlides));0<g.startSlide&&(g.startSlide>=a.totalSlides&&(g.startSlide=a.totalSlides-1),a.currentSlide=g.startSlide);b(m[a.currentSlide]).is("img")?a.currentImage=b(m[a.currentSlide]):a.currentImage=b(m[a.currentSlide]).find("img:first");b(m[a.currentSlide]).is("a")&&b(m[a.currentSlide]).css("display","block");var q=b("<img/>").addClass("nivo-main-image");q.attr("src",a.currentImage.attr("src")).show();l.append(q);b(window).resize(function(){l.children("img").width(l.width()); q.attr("src",a.currentImage.attr("src"));q.stop().height("auto");b(".nivo-slice").remove();b(".nivo-box").remove()});l.append(b('<div class="nivo-caption"></div>'));var x=function(c){var e=b(".nivo-caption",l);if(""!=a.currentImage.attr("title")&&void 0!=a.currentImage.attr("title")){var d=a.currentImage.attr("title");"#"==d.substr(0,1)&&(d=b(d).html());"block"==e.css("display")?setTimeout(function(){e.html(d)},c.animSpeed):(e.html(d),e.stop().fadeIn(c.animSpeed))}else e.stop().fadeOut(c.animSpeed)}; x(g);var n=0;!g.manualAdvance&&1<m.length&&(n=setInterval(function(){r(l,m,g,!1)},g.pauseTime));g.directionNav&&(l.append('<div class="nivo-directionNav"><a class="nivo-prevNav">'+g.prevText+'</a><a class="nivo-nextNav">'+g.nextText+"</a></div>"),b(l).on("click","a.nivo-prevNav",function(){if(a.running)return!1;clearInterval(n);n="";a.currentSlide-=2;r(l,m,g,"prev")}),b(l).on("click","a.nivo-nextNav",function(){if(a.running)return!1;clearInterval(n);n="";r(l,m,g,"next")}));if(g.controlNav){a.controlNavEl= b('<div class="nivo-controlNav"></div>');l.after(a.controlNavEl);for(var s=0;s<m.length;s++)if(g.controlNavThumbs){a.controlNavEl.addClass("nivo-thumbs-enabled");var u=m.eq(s);u.is("img")||(u=u.find("img:first"));u.attr("data-thumb")&&a.controlNavEl.append('<a class="nivo-control" rel="'+s+'"><img src="'+u.attr("data-thumb")+'" alt="" /></a>')}else a.controlNavEl.append('<a class="nivo-control" rel="'+s+'">'+(s+1)+"</a>");b("a:eq("+a.currentSlide+")",a.controlNavEl).addClass("active");b("a",a.controlNavEl).bind("click", function(){if(a.running||b(this).hasClass("active"))return!1;clearInterval(n);n="";q.attr("src",a.currentImage.attr("src"));a.currentSlide=b(this).attr("rel")-1;r(l,m,g,"control")})}g.pauseOnHover&&l.hover(function(){a.paused=!0;clearInterval(n);n=""},function(){a.paused=!1;""!==n||g.manualAdvance||(n=setInterval(function(){r(l,m,g,!1)},g.pauseTime))});l.bind("nivo:animFinished",function(){q.attr("src",a.currentImage.attr("src"));a.running=!1;b(m).each(function(){b(this).is("a")&&b(this).css("display", "none")});b(m[a.currentSlide]).is("a")&&b(m[a.currentSlide]).css("display","block");""!==n||a.paused||g.manualAdvance||(n=setInterval(function(){r(l,m,g,!1)},g.pauseTime));g.afterChange.call(this)});var t=function(c,e,d){b(d.currentImage).parent().is("a")&&b(d.currentImage).parent().css("display","block");b('img[src="'+d.currentImage.attr("src")+'"]',c).not(".nivo-main-image,.nivo-control img").width(c.width()).css("visibility","hidden").show();for(var a=b('img[src="'+d.currentImage.attr("src")+'"]', c).not(".nivo-main-image,.nivo-control img").parent().is("a")?b('img[src="'+d.currentImage.attr("src")+'"]',c).not(".nivo-main-image,.nivo-control img").parent().height():b('img[src="'+d.currentImage.attr("src")+'"]',c).not(".nivo-main-image,.nivo-control img").height(),f=0;f<e.slices;f++){var h=Math.round(c.width()/e.slices);f===e.slices-1?c.append(b('<div class="nivo-slice" name="'+f+'"><img src="'+d.currentImage.attr("src")+'" style="position:absolute; width:'+c.width()+"px; height:auto; display:block !important; top:0; left:-"+ (h+f*h-h)+'px;" /></div>').css({left:h*f+"px",width:c.width()-h*f+"px",height:a+"px",opacity:"0",overflow:"hidden"})):c.append(b('<div class="nivo-slice" name="'+f+'"><img src="'+d.currentImage.attr("src")+'" style="position:absolute; width:'+c.width()+"px; height:auto; display:block !important; top:0; left:-"+(h+f*h-h)+'px;" /></div>').css({left:h*f+"px",width:h+"px",height:a+"px",opacity:"0",overflow:"hidden"}))}b(".nivo-slice",c).height(a);q.stop().animate({height:b(d.currentImage).height()},e.animSpeed)}, y=function(c,e,d){b(d.currentImage).parent().is("a")&&b(d.currentImage).parent().css("display","block");b('img[src="'+d.currentImage.attr("src")+'"]',c).not(".nivo-main-image,.nivo-control img").width(c.width()).css("visibility","hidden").show();for(var a=Math.round(c.width()/e.boxCols),f=Math.round(b('img[src="'+d.currentImage.attr("src")+'"]',c).not(".nivo-main-image,.nivo-control img").height()/e.boxRows),h=0;h<e.boxRows;h++)for(var k=0;k<e.boxCols;k++)k===e.boxCols-1?c.append(b('<div class="nivo-box" name="'+ k+'" rel="'+h+'"><img src="'+d.currentImage.attr("src")+'" style="position:absolute; width:'+c.width()+"px; height:auto; display:block; top:-"+f*h+"px; left:-"+a*k+'px;" /></div>').css({opacity:0,left:a*k+"px",top:f*h+"px",width:c.width()-a*k+"px"})):c.append(b('<div class="nivo-box" name="'+k+'" rel="'+h+'"><img src="'+d.currentImage.attr("src")+'" style="position:absolute; width:'+c.width()+"px; height:auto; display:block; top:-"+f*h+"px; left:-"+a*k+'px;" /></div>').css({opacity:0,left:a*k+"px", top:f*h+"px",width:a+"px"})),b('.nivo-box[name="'+k+'"]',c).height(b('.nivo-box[name="'+k+'"] img',c).height()+"px");q.stop().animate({height:b(d.currentImage).height()},e.animSpeed)},r=function(c,e,d,a){var f=c.data("nivo:vars");f&&f.currentSlide===f.totalSlides-1&&d.lastSlide.call(this);if((!f||f.stop)&&!a)return!1;d.beforeChange.call(this);a?("prev"===a&&q.attr("src",f.currentImage.attr("src")),"next"===a&&q.attr("src",f.currentImage.attr("src"))):q.attr("src",f.currentImage.attr("src"));f.currentSlide++; f.currentSlide===f.totalSlides&&(f.currentSlide=0,d.slideshowEnd.call(this));0>f.currentSlide&&(f.currentSlide=f.totalSlides-1);b(e[f.currentSlide]).is("img")?f.currentImage=b(e[f.currentSlide]):f.currentImage=b(e[f.currentSlide]).find("img:first");d.controlNav&&(b("a",f.controlNavEl).removeClass("active"),b("a:eq("+f.currentSlide+")",f.controlNavEl).addClass("active"));x(d);b(".nivo-slice",c).remove();b(".nivo-box",c).remove();var h=d.effect;e="";"random"===d.effect&&(e="sliceDownRight sliceDownLeft sliceUpRight sliceUpLeft sliceUpDown sliceUpDownLeft fold fade boxRandom boxRain boxRainReverse boxRainGrow boxRainGrowReverse".split(" "), h=e[Math.floor(Math.random()*(e.length+1))],void 0===h&&(h="fade"));-1!==d.effect.indexOf(",")&&(e=d.effect.split(","),h=e[Math.floor(Math.random()*e.length)],void 0===h&&(h="fade"));f.currentImage.attr("data-transition")&&(h=f.currentImage.attr("data-transition"));f.running=!0;var k=0,g=0,l=e="",m="";e="";if("sliceDown"===h||"sliceDownRight"===h||"sliceDownLeft"===h)t(c,d,f),g=k=0,e=b(".nivo-slice",c),"sliceDownLeft"===h&&(e=b(".nivo-slice",c)._reverse()),e.each(function(){var a=b(this);a.css({top:"0px"}); g===d.slices-1?setTimeout(function(){a.animate({opacity:"1.0"},d.animSpeed,"",function(){c.trigger("nivo:animFinished")})},100+k):setTimeout(function(){a.animate({opacity:"1.0"},d.animSpeed)},100+k);k+=50;g++});else if("sliceUp"===h||"sliceUpRight"===h||"sliceUpLeft"===h)t(c,d,f),g=k=0,e=b(".nivo-slice",c),"sliceUpLeft"===h&&(e=b(".nivo-slice",c)._reverse()),e.each(function(){var a=b(this);a.css({bottom:"0px"});g===d.slices-1?setTimeout(function(){a.animate({opacity:"1.0"},d.animSpeed,"",function(){c.trigger("nivo:animFinished")})}, 100+k):setTimeout(function(){a.animate({opacity:"1.0"},d.animSpeed)},100+k);k+=50;g++});else if("sliceUpDown"===h||"sliceUpDownRight"===h||"sliceUpDownLeft"===h){t(c,d,f);var n=g=k=0;e=b(".nivo-slice",c);"sliceUpDownLeft"===h&&(e=b(".nivo-slice",c)._reverse());e.each(function(){var a=b(this);0===g?(a.css("top","0px"),g++):(a.css("bottom","0px"),g=0);n===d.slices-1?setTimeout(function(){a.animate({opacity:"1.0"},d.animSpeed,"",function(){c.trigger("nivo:animFinished")})},100+k):setTimeout(function(){a.animate({opacity:"1.0"}, d.animSpeed)},100+k);k+=50;n++})}else if("fold"===h)t(c,d,f),g=k=0,b(".nivo-slice",c).each(function(){var a=b(this),e=a.width();a.css({top:"0px",width:"0px"});g===d.slices-1?setTimeout(function(){a.animate({width:e,opacity:"1.0"},d.animSpeed,"",function(){c.trigger("nivo:animFinished")})},100+k):setTimeout(function(){a.animate({width:e,opacity:"1.0"},d.animSpeed)},100+k);k+=50;g++});else if("fade"===h)t(c,d,f),l=b(".nivo-slice:first",c),l.css({width:c.width()+"px"}),l.animate({opacity:"1.0"},2*d.animSpeed, "",function(){c.trigger("nivo:animFinished")});else if("slideInRight"===h)t(c,d,f),l=b(".nivo-slice:first",c),l.css({width:"0px",opacity:"1"}),l.animate({width:c.width()+"px"},2*d.animSpeed,"",function(){c.trigger("nivo:animFinished")});else if("slideInLeft"===h)t(c,d,f),l=b(".nivo-slice:first",c),l.css({width:"0px",opacity:"1",left:"",right:"0px"}),l.animate({width:c.width()+"px"},2*d.animSpeed,"",function(){l.css({left:"0px",right:""});c.trigger("nivo:animFinished")});else if("boxRandom"===h)y(c, d,f),m=d.boxCols*d.boxRows,k=g=0,e=v(b(".nivo-box",c)),e.each(function(){var a=b(this);g===m-1?setTimeout(function(){a.animate({opacity:"1"},d.animSpeed,"",function(){c.trigger("nivo:animFinished")})},100+k):setTimeout(function(){a.animate({opacity:"1"},d.animSpeed)},100+k);k+=20;g++});else if("boxRain"===h||"boxRainReverse"===h||"boxRainGrow"===h||"boxRainGrowReverse"===h){y(c,d,f);var m=d.boxCols*d.boxRows,p=k=g=0,r=0,s=[];s[p]=[];e=b(".nivo-box",c);if("boxRainReverse"===h||"boxRainGrowReverse"=== h)e=b(".nivo-box",c)._reverse();e.each(function(){s[p][r]=b(this);r++;r===d.boxCols&&(p++,r=0,s[p]=[])});for(f=0;f<2*d.boxCols;f++){e=f;for(a=0;a<d.boxRows;a++)0<=e&&e<d.boxCols&&(function(a,e,f,g,k){var l=b(s[a][e]),m=l.width(),n=l.height();"boxRainGrow"!==h&&"boxRainGrowReverse"!==h||l.width(0).height(0);g===k-1?setTimeout(function(){l.animate({opacity:"1",width:m,height:n},d.animSpeed/1.3,"",function(){c.trigger("nivo:animFinished")})},100+f):setTimeout(function(){l.animate({opacity:"1",width:m, height:n},d.animSpeed/1.3)},100+f)}(a,e,k,g,m),g++),e--;k+=100}}},v=function(a){for(var b,d,g=a.length;g;b=parseInt(Math.random()*g,10),d=a[--g],a[g]=a[b],a[b]=d);return a},z=function(a){this.console&&"undefined"!==typeof console.log&&console.log(a)};this.stop=function(){b(p).data("nivo:vars").stop||(b(p).data("nivo:vars").stop=!0,z("Stop Slider"))};this.start=function(){b(p).data("nivo:vars").stop&&(b(p).data("nivo:vars").stop=!1,z("Start Slider"))};g.afterLoad.call(this);return this};b.fn.nivoSlider= function(p){return this.each(function(w,g){var a=b(this);if(a.data("nivoslider"))return a.data("nivoslider");var l=new v(this,p);a.data("nivoslider",l)})};b.fn.nivoSlider.defaults={effect:"random",slices:15,boxCols:8,boxRows:4,animSpeed:500,pauseTime:3E3,startSlide:0,directionNav:!0,controlNav:!0,controlNavThumbs:!1,pauseOnHover:!0,manualAdvance:!1,prevText:"Prev",nextText:"Next",randomStart:!1,beforeChange:function(){},afterChange:function(){},slideshowEnd:function(){},lastSlide:function(){},afterLoad:function(){}}; b.fn._reverse=[].reverse})(jQuery);