var _____WB$wombat$assign$function_____ = function(name) {return (self._wb_wombat && self._wb_wombat.local_init && self._wb_wombat.local_init(name)) || self[name]; };
if (!self.__WB_pmw) { self.__WB_pmw = function(obj) { this.__WB_source = obj; return this; } }
{
let window = _____WB$wombat$assign$function_____("window");
let self = _____WB$wombat$assign$function_____("self");
let document = _____WB$wombat$assign$function_____("document");
let location = _____WB$wombat$assign$function_____("location");
let top = _____WB$wombat$assign$function_____("top");
let parent = _____WB$wombat$assign$function_____("parent");
let frames = _____WB$wombat$assign$function_____("frames");
let opener = _____WB$wombat$assign$function_____("opener");
function isInteger(s)
{
return (s.toString().search(/^-?[0-9]+$/) == 0);
}
function isUnsignedInteger(s)
{
return (s.toString().search(/^[0-9]+$/) == 0);
}
(function( $ )
{
$.fn.cloneLight = function()
{
if ($(this).get(0).tagName=="IMG")
{
clone = $("");
return clone;
}
else
{
return $(this).clone();
}
}
$.fn.stvSlider = function(method)
{
// system variables
var vars =
{
hoverZindex: 1010,
currentSlicesZindex: 1004,
currentZindex: 1003,
lastZindex: 1002,
lastSlicesZindex: 1001,
inactiveZindex: 1000,
lastSliderIndex: 0,
currentSliderIndex: 0,
oldSliderIndex: 0,
olderSliderIndex: 0,
slides: [],
containerSelector: "",
clickEnabled: true,
mouseOver: false,
slideShowPaused: false,
slideShowStoped: false,
slideShowStartedAt: 0,
slideShowRemaining: 0,
slideShowTimeout:'',
currentDirectionNext: true,
currentChangeAutomatic: true,
slicesShouldBeFinished: false,
captionBoxEnabled: true,
captionBoxVisible: false,
prevnextOriginalStyle: "",
slideshowCounter: -1
}
// default variables
// don't edit them, you can overwrite all of them as a parameter
var defaults =
{
/////////////////////////////////////////////////////////////////////////////////
// width&height must be set either as parameters for the plugin, or in the style
// attribute of the container div or in an outer style block
/////////////////////////////////////////////////////////////////////////////////
width: "", // width of the slider // any valid css size
height: "", // height of the slider // any valid css size
/////////////////////////////////////////////////////////////////////////////////
// all the other parameters are optional, you can use the embedded default values
// or you can overwrite them as a parameter given to the jQuery plugin
/////////////////////////////////////////////////////////////////////////////////
slideSelector: ".stvSliderSlide", // selector of the slide element // any valid jQuery selector
animationSpeed: 2000, // transition time // numeric
effect: "random", // "random"|effect name // string
pace: "smooth", // "smooth"|"harsh"|"tremor"|"bounce"
randomEffects: [["fade","smooth"],["puffInOut","smooth"],["slideThruHorizontal","smooth"],["slideInVertical","harsh"],["slideInOutHorizontal","tremor"],["slideThruVertical","bounce"],["scaleTC","harsh"],["blocksDrop","harsh"],["blocksStairs","harsh"],["curtainsWide","harsh"],["zigzagBlanket","harsh"],["zigzagWaves","harsh"]], // if effect is random, the effect will be selected from this array // array
slideshowEffects: [["fade","smooth"],["puffInOut","smooth"],["slideThruHorizontal","smooth"],["slideInVertical","harsh"],["slideInOutHorizontal","tremor"],["slideThruVertical","bounce"],["scaleTC","harsh"],["blocksDrop","harsh"],["blocksStairs","harsh"],["curtainsWide","harsh"],["zigzagBlanket","harsh"],["zigzagWaves","harsh"]], // if effect is slideshow, the effect will be selected from this array // array
minDelayTime: 1, // time for the manual nextprev are disabled after every transition // numeric|"auto"
slideShowStart: true, // does automatic slideshow start on load? // true|false
slideShowButton: false, // does it have a start/stop slideshow button? // true|false
slideShowStartButtonLabel: "start slideshow", // label of the prev button // string
slideShowStopButtonLabel: "stop slideshow", // label of the next button // string
slideShowButtonCss: "", // CSS of the prev/next button boxes // any css
slideShowButtonClass: "startstopButton", // class of the prev/next button boxes // any css class
slideShowButtonCss: "", // CSS of the stop/start button box // any css
slideShowTime: 3000, // pause time // numeric
slideShowPauseAtHover: true, // does it pause if the mouse is over the image? // true/false
prevnextButton: true, // does it have prev/next buttons in the box? // true|false
prevButtonLabel: "< prev", // label of the prev button // string
nextButtonLabel: "next >", // label of the next button // string
prevnextButtonCss: "width: 100px;", // CSS of the prev/next button boxes // any css
prevnextButtonClass: "prevnextButtonNormal", // class of the prev/next button boxes // any css class
prevnextButtonActiveCss: "", // CSS of the prev/next button boxes on hover // any css
prevnextButtonActiveClass: "prevnextButtonActive", // class of the prev/next button boxes on hover // any css class
prevnextShadowCss: "", // CSS of the prev/next shadows // any css
prevnextShadowClass: "prevnextShadowNormal", // class of the prev/next shadows // any css class
prevnextShadowActiveCss: "", // CSS of the prev/next shadows on hover // any css
prevnextShadowActiveClass: "prevnextShadowActive", // class of the prev/next shadows on hover // any css class
outerPrevLinkSelector: "#outerPrevLink", // originally for testing purposes, selector of a link // any valid jQuery selector
outerNextLinkSelector: "#outerNextLink", // originally for testing purposes, selector of a link // any valid jQuery selector
captionBox: true, // does it have a caption box? // true|false
captionBoxHide: true, // does it show the caption box only on mouseover? // true|false
captionBoxHeight: "auto", // height of the caption box // numeric or "auto"
captionBoxShadowCss: "", // CSS of the caption box (you can use external css for #captionBoxShadow instead) // any css
captionBoxCss: "", // CSS of the caption box (you can use external css for #captionBoxInner instead) // any css
captionContentFrom: "title", // name of attribute of slideSelector element that should be used as caption // any valid attribute
removeCaptionAttr: true, // should the source attribute of the caption content be removed? // true|false
redirectLink: true, // do the slides have links? // true|false
redirectLinkFrom: "href", // name of attribute of slideSelector element that should be used as link // any valid attribute
redirectTargetFrom: "target", // name of attribute of slideSelector element that should be used as link // any valid attribute
removeLinkAttr: true, // should the source attributes of the link and target be removed? // true|false
}
var settings = {};
var effects =
{
fade:
{
run: function()
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex}); // delete // .css(vars.slides[vars.currentSliderIndex].originalCss)
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).fadeIn(settings.animationSpeed,effects[currentEffect]["paces"][currentPace]);
$(vars.slides[vars.oldSliderIndex].selector).delay(settings.animationSpeed).queue(function()
{
$(this).fadeOut(0).dequeue();
});
},
paces:
{
smooth: "swing",
harsh: "easeInQuint",
tremor: "easeInOutBounce",
bounce: "easeInBounce",
}
},
puffIn:
{
run: function()
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("puff",{"percent":300,"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
puffOut:
{
run: function()
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("puff",{"percent":300,"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
},
paces:
{
smooth: "swing",
harsh: "easeOutQuart",
tremor: "easeInOutBounce",
bounce: "easeInBounce",
}
},
puffInOut:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("puff",{"percent":300,"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
else
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("puff",{"percent":300,"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
},
paces:
{
smooth: "swing",
harsh: "easeOutQuart",
tremor: "easeInOutBounce",
bounce: "easeInBounce",
}
},
slideInHorizontal:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"right","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"left","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
slideOutHorizontal:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"left","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
else
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"right","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
slideInRight:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"right","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"right","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
slideOutRight:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"left","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
else
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"left","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
slideInOutHorizontal:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"right","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"right","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
},
paces:
{
smooth: "swing",
harsh: "easeOutQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
slideThruHorizontal:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"right","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"left","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
else
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"left","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"right","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
},
paces:
{
smooth: "linear",
harsh: "linear",
tremor: "linear",
bounce: "linear",
}
},
slideInVertical:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"up","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"down","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
slideOutVertical:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"down","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
else
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"up","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
slideInUp:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"up","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"up","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
slideInDown:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"down","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"down","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
slideOutUp:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"up","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
else
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"up","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
slideOutDown:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"down","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
else
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"down","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
slideInOutUp:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"up","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"up","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
slideInOutDown:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"down","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"down","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
slideThruVertical:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"down","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"up","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.currentZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.oldSliderIndex].selector).hide("slide",{"direction":"up","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed);
$(vars.slides[vars.currentSliderIndex].selector).show("slide",{"direction":"down","easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
},
paces:
{
smooth: "linear",
harsh: "easeOutQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
scaleTC:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("scale",{"origin":["top","center"],"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("scale",{"origin":["bottom","center"],"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
scaleTR:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("scale",{"origin":["top","right"],"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("scale",{"origin":["bottom","left"],"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
scaleMC:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("scale",{"origin":["middle","center"],"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("scale",{"origin":["middle","center"],"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
scaleMR:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("scale",{"origin":["middle","right"],"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("scale",{"origin":["middle","left"],"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
scaleBC:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("scale",{"origin":["bottom","center"],"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("scale",{"origin":["top","center"],"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
scaleBR:
{
run: function()
{
if (vars.currentDirectionNext)
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("scale",{"origin":["bottom","right"],"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
else
{
$(vars.slides[vars.currentSliderIndex].selector).css({"z-index":vars.currentZindex});
$(vars.slides[vars.oldSliderIndex].selector).css({"z-index":vars.lastZindex,"display":"block","opacity":1});
$(vars.slides[vars.currentSliderIndex].selector).show("scale",{"origin":["top","left"],"easing":effects[currentEffect]["paces"][currentPace]},settings.animationSpeed,function(){
$(vars.slides[vars.oldSliderIndex].selector).css({"display":"none"});
});
}
},
paces:
{
smooth: "swing",
harsh: "easeInQuart",
tremor: "easeInOutBounce",
bounce: "easeOutBounce",
}
},
zigzagBlanket:
{
run: function()
{
methods.animateSlices2.apply(this,[30,40,{"height":"0px","opacity":0},{"height":$(vars.containerSelector).height()+"px","opacity":1}]);
},
paces:
{
smooth: "easeOutQuint",
harsh: "easeOutQuint",
tremor: "easeOutQuint",
bounce: "easeOutQuint"
}
},
zigzagFalls:
{
run: function()
{
methods.animateSlices2.apply(this,[50,70,{"height":"0px","opacity":1},{"height":$(vars.containerSelector).height()+"px","opacity":1}]);
},
paces:
{
smooth: "easeInQuint",
harsh: "easeInQuint",
tremor: "easeInQuint",
bounce: "easeInQuint"
}
},
zigzagWaves:
{
run: function()
{
methods.animateSlices2.apply(this,[30,40,{"height":"0px","opacity":1},{"height":$(vars.containerSelector).height()+"px","opacity":1}]);
},
paces:
{
smooth: "easeInBounce",
harsh: "easeInBounce",
tremor: "easeInBounce",
bounce: "easeInBounce"
}
},
zigzagWave:
{
run: function()
{
methods.animateSlices2.apply(this,[50,70,{"height":"0px","opacity":1},{"height":$(vars.containerSelector).height()+"px","opacity":1}]);
},
paces:
{
smooth: "easeInOutBack",
harsh: "easeInOutBack",
tremor: "easeInOutBack",
bounce: "easeInOutBack"
}
},
blocksDrop:
{
run: function()
{
methods.animateSlices2.apply(this,[10,2,{"height":"0px","opacity":0},{"height":$(vars.containerSelector).height()+"px","opacity":1}]);
},
paces:
{
smooth: "linear",
harsh: "linear",
tremor: "linear",
bounce: "linear",
}
},
blocksStairs:
{
run: function()
{
methods.animateSlices2.apply(this,[10,6,{"height":"0px","opacity":0},{"height":$(vars.containerSelector).height()+"px","opacity":1}]);
},
paces:
{
smooth: "linear",
harsh: "linear",
tremor: "linear",
bounce: "linear"
}
},
columns10:
{
run: function()
{
methods.animateSlices2.apply(this,[10,0.1,{"height":"0px","opacity":1},{"height":$(vars.containerSelector).height()+"px","opacity":1}]);
},
paces:
{
smooth: "linear",
harsh: "linear",
tremor: "linear",
bounce: "linear"
}
},
columns4:
{
run: function()
{
methods.animateSlices2.apply(this,[4,0.1,{"height":"0px","opacity":1},{"height":$(vars.containerSelector).height()+"px","opacity":1}]);
},
paces:
{
smooth: "linear",
harsh: "linear",
tremor: "linear",
bounce: "linear"
}
},
columns3:
{
run: function()
{
methods.animateSlices2.apply(this,[3,0.1,{"height":"0px","opacity":1},{"height":$(vars.containerSelector).height()+"px","opacity":1}]);
},
paces:
{
smooth: "linear",
harsh: "linear",
tremor: "linear",
bounce: "linear"
}
},
columns2:
{
run: function()
{
methods.animateSlices2.apply(this,[2,0.1,{"height":"0px","opacity":1},{"height":$(vars.containerSelector).height()+"px","opacity":1}]);
},
paces:
{
smooth: "linear",
harsh: "linear",
tremor: "linear",
bounce: "linear"
}
},
curtainsWide:
{
run: function()
{
methods.animateSlices2.apply(this,[10,100,{"height":$(vars.containerSelector).height()+"px","opacity":0,"width":"0px"},{"width":"sliceWidth","opacity":1}]);
},
paces:
{
smooth: "swing",
harsh: "easeOutQuart",
tremor: "easeInOutBounce",
bounce: "easeInBounce",
}
},
curtainsThin:
{
run: function()
{
methods.animateSlices2.apply(this,[20,100,{"height":$(vars.containerSelector).height()+"px","opacity":1,"width":"0px"},{"width":"sliceWidth","opacity":1}]);
},
paces:
{
smooth: "swing",
harsh: "easeOutQuart",
tremor: "easeInOutBounce",
bounce: "easeInBounce",
}
}
}
var methods =
{
// start of INIT function
init: function(options)
{
//methods.echo.apply(this, ["init started"]);
vars.containerSelector = this.selector;
$container = $(vars.containerSelector);
$.each(options,
function(key, value)
{
//methods.echo.apply(this, ["options."+key+":"+value]);
}
);
settings = $.extend(true,{}, defaults, options);
if ((settings.width=="") && ($container.width()!=0))
{
settings.width = $container.width()+"px";
}
if ((settings.height=="") && ($container.height()!=0))
{
settings.height = $container.height()+"px";
}
settings.oldSlideSelector = settings.slideSelector;
settings.slideSelector = vars.containerSelector + " " + settings.slideSelector;
$.each(settings,
function(key, value)
{
//methods.echo.apply(this, ["settings."+key+":"+value]);
}
);
$.each(vars,
function(key, value)
{
//methods.echo.apply(this, ["vars."+key+":"+value]);
}
);
if (settings.minDelayTime=="auto")
{
settings.minDelayTime = settings.animationSpeed;
}
if ((!settings.randomEffects.length) || (settings.randomEffects.length==0))
{
settings.randomEffects = ["none","smooth"];
}
if (!settings.slideShowStart)
{
vars.slideShowStoped = true;
}
$slides = $(settings.slideSelector);
$slides.css({"position":"absolute","top":"0px","left":"0px"});
$container.css({"position":"relative","width":settings.width,"height":settings.height,"overflow":"hidden"});
$outerPrevLink = $(settings.outerPrevLinkSelector);
if ($outerPrevLink.length)
{
$outerPrevLink.unbind("click").click(function(event)
{
methods.prevnextClick.apply(this, ["prev"]);
event.preventDefault();
});
}
$outerNextLink = $(settings.outerNextLinkSelector);
if ($outerNextLink.length)
{
$outerNextLink.unbind("click").click(function(event)
{
methods.prevnextClick.apply(this, ["next"]);
event.preventDefault();
});
}
$(settings.slideSelector).each(function (index, domEle)
{
$(this).attr("stvSliderIndex",index);
if (settings.captionBox)
{
$(this).attr("data-stvslider-caption",$(this).attr(settings.captionContentFrom));
if (settings.removeCaptionAttr)
{
$(this).removeAttr(settings.captionContentFrom);
}
}
if ((settings.redirectLink) && ($(this).attr(settings.redirectLinkFrom)!==undefined))
{
$(this).attr("data-stvslider-link",$(this).attr(settings.redirectLinkFrom));
if (settings.removeLinkAttr)
{
$(this).removeAttr(settings.redirectLinkFrom);
}
}
if ((settings.redirectLink))
{
if ($(this).attr(settings.redirectTargetFrom)!==undefined)
{
$(this).attr("data-stvslider-target",$(this).attr(settings.redirectTargetFrom));
}
else
{
$(this).attr("data-stvslider-target","");
}
if (settings.removeLinkAttr)
{
$(this).removeAttr(settings.redirectTargetFrom);
}
}
if (!$(this).attr("id"))
{
$(this).attr("id", "stvSliderSlide"+index);
}
vars.slides[index] = {"id":$(this).attr("id"),"selector":vars.containerSelector + " #"+$(this).attr("id")}; // delete // "originalCss":{width:$(this).css("width"), height:$(this).css("height"), "top":$(this).css("top"),"left":$(this).css("left")}
if (index == 0)
{
$(this).css({"z-index":vars.currentZindex});
vars.currentSliderIndex = index;
}
else
{
$(this).css({"z-index":vars.inactiveZindex});
$(this).css({"display":"none"});
}
vars.olderSliderIndex = vars.oldSliderIndex = vars.lastSliderIndex = index;
});
$(vars.containerSelector).mouseenter(function ()
{
//methods.echo.apply(this, ["mouseenter"]);
if (!vars.slideShowStoped)
{
window.clearTimeout(vars.slideShowTimeout);
}
if (settings.captionBoxHide)
{
vars.captionBoxVisible = true;
$("#captionBox:hidden").show("slide",{"direction":"down"},100);
}
});
$(vars.containerSelector).mouseleave(function ()
{
//methods.echo.apply(this, ["mouseleave"]);
if (!vars.slideShowStoped)
{
window.clearTimeout(vars.slideShowTimeout);
methods.slideShowStart.apply(this,[settings.slideShowTime]);
//vars.mouseOver = false;
}
if (settings.captionBoxHide)
{
vars.captionBoxVisible = false;
$("#captionBox").hide("slide",{"direction":"down"},100);
}
});
if (settings.captionBox)
{
$(vars.containerSelector).append("